From 3db1180579bd14d877ecd1f81a49495665ed279f Mon Sep 17 00:00:00 2001 From: Daniel Cottone Date: Mon, 15 Apr 2019 17:40:08 -0500 Subject: [PATCH 001/146] fix(*): Upgrade natives, lodash, and remove nsp --- gulpfile.js | 2 +- lib/client.js | 2 +- package.json | 2 +- yarn.lock | 16 ++++++++-------- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/gulpfile.js b/gulpfile.js index 4a3432ed..2fb187e0 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -51,5 +51,5 @@ gulp.task('babel', function () { .pipe(gulp.dest('dist')); }); -gulp.task('prepublish', ['nsp', 'babel']); +gulp.task('prepublish', ['babel']); gulp.task('default', ['static', 'test']); diff --git a/lib/client.js b/lib/client.js index 0fc4933e..157884c1 100644 --- a/lib/client.js +++ b/lib/client.js @@ -1,7 +1,7 @@ import { deprecate } from 'util'; import request from 'request'; import Bluebird from 'bluebird'; -import merge from 'lodash.merge'; +import merge from 'lodash/merge'; import User from './user'; import Event from './event'; import Company from './company'; diff --git a/package.json b/package.json index 62a37d32..fdb6e68f 100644 --- a/package.json +++ b/package.json @@ -20,7 +20,7 @@ "dependencies": { "bluebird": "^3.3.4", "htmlencode": "^0.0.4", - "lodash.merge": "^4.6.1", + "lodash": "^4.17.11", "request": "^2.83.0" }, "devDependencies": { diff --git a/yarn.lock b/yarn.lock index 804b8108..5c1ad114 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2688,11 +2688,6 @@ lodash.keysin@^3.0.0: lodash.isarguments "^3.0.0" lodash.isarray "^3.0.0" -lodash.merge@^4.6.1: - version "4.6.1" - resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.1.tgz#adc25d9cb99b9391c59624f379fbba60d7111d54" - integrity sha512-AOYza4+Hf5z1/0Hztxpm2/xiPZgi/cjMqdnKTUWTBSKchJlxXXuUSxCCl8rJlf4g6yww/j6mA8nC8Hw/EZWxKQ== - lodash.pick@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/lodash.pick/-/lodash.pick-3.1.0.tgz#f252a855b2046b61bcd3904b26f76bd2efc65550" @@ -2747,6 +2742,11 @@ lodash@^4.0.0, lodash@^4.17.4: resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.4.tgz#78203a4d1c328ae1d86dca6460e369b57f4055ae" integrity sha1-eCA6TRwyiuHYbcpkYONptX9AVa4= +lodash@^4.17.11: + version "4.17.11" + resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.11.tgz#b39ea6229ef607ecd89e2c8df12536891cac9b8d" + integrity sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg== + lodash@~1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/lodash/-/lodash-1.0.2.tgz#8f57560c83b59fc270bd3d561b690043430e2551" @@ -2956,9 +2956,9 @@ nanomatch@^1.2.9: to-regex "^3.0.1" natives@^1.1.0: - version "1.1.3" - resolved "https://registry.yarnpkg.com/natives/-/natives-1.1.3.tgz#44a579be64507ea2d6ed1ca04a9415915cf75558" - integrity sha512-BZGSYV4YOLxzoTK73l0/s/0sH9l8SHs2ocReMH1f8JYSh5FUWu4ZrKCpJdRkWXV6HFR/pZDz7bwWOVAY07q77g== + version "1.1.6" + resolved "https://registry.yarnpkg.com/natives/-/natives-1.1.6.tgz#a603b4a498ab77173612b9ea1acdec4d980f00bb" + integrity sha512-6+TDFewD4yxY14ptjKaS63GVdtKiES1pTPyxn9Jb0rBqPMZ7VcCiooEhPNsr+mqHtMGxa/5c/HhcC4uPEUw/nA== nise@^1.4.5: version "1.4.6" From cc647bae89e7c08cc7c97ca58260483bea18f2fc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Thu, 6 Jun 2019 03:50:12 +0000 Subject: [PATCH 002/146] Bump js-yaml from 3.10.0 to 3.13.1 Bumps [js-yaml](https://github.com/nodeca/js-yaml) from 3.10.0 to 3.13.1. - [Release notes](https://github.com/nodeca/js-yaml/releases) - [Changelog](https://github.com/nodeca/js-yaml/blob/master/CHANGELOG.md) - [Commits](https://github.com/nodeca/js-yaml/compare/3.10.0...3.13.1) Signed-off-by: dependabot[bot] --- yarn.lock | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/yarn.lock b/yarn.lock index 5c1ad114..d2b1c3cf 100644 --- a/yarn.lock +++ b/yarn.lock @@ -96,9 +96,9 @@ archy@^1.0.0: integrity sha1-+cjBN1fMHde8N5rHeyxipcKGjEA= argparse@^1.0.7: - version "1.0.9" - resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.9.tgz#73d83bc263f86e97f8cc4f6bae1b0e90a7d22c86" - integrity sha1-c9g7wmP4bpf4zE9rrhsOkKfSLIY= + version "1.0.10" + resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.10.tgz#bcd6791ea5ae09725e17e5ad988134cd40b3d911" + integrity sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg== dependencies: sprintf-js "~1.0.2" @@ -1436,9 +1436,9 @@ esprima@^1.2.2: integrity sha1-CZNQL+r2aBODJXVvMPmlH+7sEek= esprima@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.0.tgz#4499eddcd1110e0b218bacf2fa7f7f59f55ca804" - integrity sha512-oftTcaMu/EGrEIu904mWteKIv8vMuOgGYo7EhVJJN00R/EED9DCua/xxHRdYnKtcECzVg7xOWhflvJMnqcFZjw== + version "4.0.1" + resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" + integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== esrecurse@^4.1.0: version "4.2.0" @@ -2414,9 +2414,9 @@ js-tokens@^3.0.0, js-tokens@^3.0.2: integrity sha1-mGbfOVECEw449/mWvOtlRDIJwls= js-yaml@3.x, js-yaml@^3.2.5: - version "3.10.0" - resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.10.0.tgz#2e78441646bd4682e963f22b6e92823c309c62dc" - integrity sha512-O2v52ffjLa9VeM43J4XocZE//WT9N0IiwDa3KSHH7Tu8CtH+1qM8SIZvnsTh6v+4yFy5KUY3BHUVwjpfAWsjIA== + version "3.13.1" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.13.1.tgz#aff151b30bfdfa8e49e05da22e7415e9dfa37847" + integrity sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw== dependencies: argparse "^1.0.7" esprima "^4.0.0" From c3c1639c6fe5ef51c9b0ff497b3a82d5bfff4605 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Thu, 6 Jun 2019 09:27:13 +0000 Subject: [PATCH 003/146] Bump handlebars from 4.0.10 to 4.1.2 Bumps [handlebars](https://github.com/wycats/handlebars.js) from 4.0.10 to 4.1.2. - [Release notes](https://github.com/wycats/handlebars.js/releases) - [Changelog](https://github.com/wycats/handlebars.js/blob/master/release-notes.md) - [Commits](https://github.com/wycats/handlebars.js/compare/v4.0.10...v4.1.2) Signed-off-by: dependabot[bot] --- yarn.lock | 132 +++++++++++++----------------------------------------- 1 file changed, 30 insertions(+), 102 deletions(-) diff --git a/yarn.lock b/yarn.lock index 5c1ad114..6f205d44 100644 --- a/yarn.lock +++ b/yarn.lock @@ -61,15 +61,6 @@ ajv@^5.1.0: json-schema-traverse "^0.3.0" json-stable-stringify "^1.0.1" -align-text@^0.1.1, align-text@^0.1.3: - version "0.1.4" - resolved "https://registry.yarnpkg.com/align-text/-/align-text-0.1.4.tgz#0cd90a561093f35d0a99256c22b7069433fad117" - integrity sha1-DNkKVhCT810KmSVsIrcGlDP60Rc= - dependencies: - kind-of "^3.0.2" - longest "^1.0.1" - repeat-string "^1.5.2" - amdefine@>=0.0.4: version "1.0.1" resolved "https://registry.yarnpkg.com/amdefine/-/amdefine-1.0.1.tgz#4a5282ac164729e93619bcfd3ad151f817ce91f5" @@ -167,7 +158,7 @@ assign-symbols@^1.0.0: resolved "https://registry.yarnpkg.com/assign-symbols/-/assign-symbols-1.0.0.tgz#59667f41fadd4f20ccbc2bb96b8d4f7f78ec0367" integrity sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c= -async@1.x, async@^1.4.0: +async@1.x: version "1.5.2" resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a" integrity sha1-7GphrlZIDAw8skHJVhjiCJL5Zyo= @@ -950,24 +941,11 @@ cache-base@^1.0.1: union-value "^1.0.0" unset-value "^1.0.0" -camelcase@^1.0.2: - version "1.2.1" - resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-1.2.1.tgz#9bb5304d2e0b56698b2c758b08a3eaa9daa58a39" - integrity sha1-m7UwTS4LVmmLLHWLCKPqqdqlijk= - caseless@~0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" integrity sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw= -center-align@^0.1.1: - version "0.1.3" - resolved "https://registry.yarnpkg.com/center-align/-/center-align-0.1.3.tgz#aa0d32629b6ee972200411cbd4461c907bc2b7ad" - integrity sha1-qg0yYptu6XIgBBHL1EYckHvCt60= - dependencies: - align-text "^0.1.3" - lazy-cache "^1.0.3" - "chai@>=1.9.2 <4.0.0": version "3.5.0" resolved "https://registry.yarnpkg.com/chai/-/chai-3.5.0.tgz#4d02637b067fe958bdbfdd3a40ec56fef7373247" @@ -1015,15 +993,6 @@ cliclopts@^1.1.0: resolved "https://registry.yarnpkg.com/cliclopts/-/cliclopts-1.1.1.tgz#69431c7cb5af723774b0d3911b4c37512431910f" integrity sha1-aUMcfLWvcjd0sNORG0w3USQxkQ8= -cliui@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/cliui/-/cliui-2.1.0.tgz#4b475760ff80264c762c3a1719032e91c7fea0d1" - integrity sha1-S0dXYP+AJkx2LDoXGQMukcf+oNE= - dependencies: - center-align "^0.1.1" - right-align "^0.1.1" - wordwrap "0.0.2" - clone-stats@^0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/clone-stats/-/clone-stats-0.0.1.tgz#b88f94a82cf38b8791d58046ea4029ad88ca99d1" @@ -1079,6 +1048,11 @@ commander@2.3.0: resolved "https://registry.yarnpkg.com/commander/-/commander-2.3.0.tgz#fd430e889832ec353b9acd1de217c11cb3eef873" integrity sha1-/UMOiJgy7DU7ms0d4hfBHLPu+HM= +commander@~2.20.0: + version "2.20.0" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.0.tgz#d58bb2b5c1ee8f87b0d340027e9e94e222c5a422" + integrity sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ== + component-emitter@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.2.1.tgz#137918d6d78283f7df7a6b7c5a63e140e69425e6" @@ -1163,11 +1137,6 @@ debug@2.2.0: dependencies: ms "0.7.1" -decamelize@^1.0.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" - integrity sha1-9lNNFRSCabIDUue+4m9QH5oZEpA= - decode-uri-component@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545" @@ -1950,15 +1919,15 @@ gulplog@^1.0.0: glogg "^1.0.0" handlebars@^4.0.1: - version "4.0.10" - resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.0.10.tgz#3d30c718b09a3d96f23ea4cc1f403c4d3ba9ff4f" - integrity sha1-PTDHGLCaPZbyPqTMH0A8TTup/08= + version "4.1.2" + resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.1.2.tgz#b6b37c1ced0306b221e094fc7aca3ec23b131b67" + integrity sha512-nvfrjqvt9xQ8Z/w0ijewdD/vvWDTOweBUm96NTr66Wfvo1mJenBLwcYmPs3TIBP5ruzYGD7Hx/DaM9RmhroGPw== dependencies: - async "^1.4.0" + neo-async "^2.6.0" optimist "^0.6.1" - source-map "^0.4.4" + source-map "^0.6.1" optionalDependencies: - uglify-js "^2.6" + uglify-js "^3.1.4" har-schema@^2.0.0: version "2.0.0" @@ -2512,11 +2481,6 @@ kind-of@^6.0.0, kind-of@^6.0.2: resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.2.tgz#01146b36a6218e64e58f3a8d66de5d7fc6f6d051" integrity sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA== -lazy-cache@^1.0.3: - version "1.0.4" - resolved "https://registry.yarnpkg.com/lazy-cache/-/lazy-cache-1.0.4.tgz#a1d78fc3a50474cb80845d3b3b6e1da49a446e8e" - integrity sha1-odePw6UEdMuAhF07O24dpJpEbo4= - levn@~0.2.5: version "0.2.5" resolved "https://registry.yarnpkg.com/levn/-/levn-0.2.5.tgz#ba8d339d0ca4a610e3a3f145b9caf48807155054" @@ -2762,11 +2726,6 @@ lolex@^2.7.5: resolved "https://registry.yarnpkg.com/lolex/-/lolex-2.7.5.tgz#113001d56bfc7e02d56e36291cc5c413d1aa0733" integrity sha512-l9x0+1offnKKIzYVjyXU2SiwhXDLekRzKyhnbyldPHvC7BvLPVpdNUNR2KeMAiCN2D/kLNttZgQD5WjSxuBx3Q== -longest@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/longest/-/longest-1.0.1.tgz#30a0b2da38f73770e8294a0d22e6625ed77d0097" - integrity sha1-MKCy2jj3N3DoKUoNIuZiXtd9AJc= - loose-envify@^1.0.0: version "1.3.1" resolved "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.3.1.tgz#d1a8ad33fa9ce0e713d65fdd0ac8b748d478c848" @@ -2960,6 +2919,11 @@ natives@^1.1.0: resolved "https://registry.yarnpkg.com/natives/-/natives-1.1.6.tgz#a603b4a498ab77173612b9ea1acdec4d980f00bb" integrity sha512-6+TDFewD4yxY14ptjKaS63GVdtKiES1pTPyxn9Jb0rBqPMZ7VcCiooEhPNsr+mqHtMGxa/5c/HhcC4uPEUw/nA== +neo-async@^2.6.0: + version "2.6.1" + resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.1.tgz#ac27ada66167fa8849a6addd837f6b189ad2081c" + integrity sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw== + nise@^1.4.5: version "1.4.6" resolved "https://registry.yarnpkg.com/nise/-/nise-1.4.6.tgz#76cc3915925056ae6c405dd8ad5d12bde570c19f" @@ -3361,7 +3325,7 @@ repeat-element@^1.1.2: resolved "https://registry.yarnpkg.com/repeat-element/-/repeat-element-1.1.2.tgz#ef089a178d1483baae4d93eb98b4f9e4e11d990a" integrity sha1-7wiaF40Ug7quTZPrmLT55OEdmQo= -repeat-string@^1.5.2, repeat-string@^1.6.1: +repeat-string@^1.6.1: version "1.6.1" resolved "https://registry.yarnpkg.com/repeat-string/-/repeat-string-1.6.1.tgz#8dcae470e1c88abc2d600fff4a776286da75e637" integrity sha1-jcrkcOHIirwtYA//Sndihtp15jc= @@ -3441,13 +3405,6 @@ ret@~0.1.10: resolved "https://registry.yarnpkg.com/ret/-/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc" integrity sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg== -right-align@^0.1.1: - version "0.1.3" - resolved "https://registry.yarnpkg.com/right-align/-/right-align-0.1.3.tgz#61339b722fe6a3515689210d24e14c96148613ef" - integrity sha1-YTObci/mo1FWiSENJOFMlhSGE+8= - dependencies: - align-text "^0.1.1" - rimraf@~2.2.6: version "2.2.8" resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.2.8.tgz#e439be2aaee327321952730f99a8929e4fc50582" @@ -3595,18 +3552,16 @@ source-map-url@^0.4.0: resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.0.tgz#3e935d7ddd73631b97659956d55128e87b5084a3" integrity sha1-PpNdfd1zYxuXZZlW1VEo6HtQhKM= -source-map@^0.4.4: - version "0.4.4" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.4.4.tgz#eba4f5da9c0dc999de68032d8b4f76173652036b" - integrity sha1-66T12pwNyZneaAMti092FzZSA2s= - dependencies: - amdefine ">=0.0.4" - -source-map@^0.5.1, source-map@^0.5.6, source-map@~0.5.1: +source-map@^0.5.1, source-map@^0.5.6: version "0.5.7" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" integrity sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w= +source-map@^0.6.1, source-map@~0.6.1: + version "0.6.1" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" + integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== + source-map@~0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.2.0.tgz#dab73fbcfc2ba819b4de03bd6f6eaa48164b3f9d" @@ -3886,20 +3841,13 @@ typedarray@^0.0.6: resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c= -uglify-js@^2.6: - version "2.8.29" - resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-2.8.29.tgz#29c5733148057bb4e1f75df35b7a9cb72e6a59dd" - integrity sha1-KcVzMUgFe7Th913zW3qcty5qWd0= +uglify-js@^3.1.4: + version "3.6.0" + resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.6.0.tgz#704681345c53a8b2079fb6cec294b05ead242ff5" + integrity sha512-W+jrUHJr3DXKhrsS7NUVxn3zqMOFn0hL/Ei6v0anCIMoKC93TjcflTagwIHLW7SfMFfiQuktQyFVCFHGUE0+yg== dependencies: - source-map "~0.5.1" - yargs "~3.10.0" - optionalDependencies: - uglify-to-browserify "~1.0.0" - -uglify-to-browserify@~1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/uglify-to-browserify/-/uglify-to-browserify-1.0.2.tgz#6e0924d6bda6b5afe349e39a6d632850a0f882b7" - integrity sha1-bgkk1r2mta/jSeOabWMoUKD4grc= + commander "~2.20.0" + source-map "~0.6.1" unc-path-regex@^0.1.2: version "0.1.2" @@ -4017,16 +3965,6 @@ which@^1.1.1, which@^1.2.14: dependencies: isexe "^2.0.0" -window-size@0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/window-size/-/window-size-0.1.0.tgz#5438cd2ea93b202efa3a19fe8887aee7c94f9c9d" - integrity sha1-VDjNLqk7IC76Ohn+iIeu58lPnJ0= - -wordwrap@0.0.2: - version "0.0.2" - resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.2.tgz#b79669bb42ecb409f83d583cad52ca17eaa1643f" - integrity sha1-t5Zpu0LstAn4PVg8rVLKF+qhZD8= - wordwrap@^1.0.0, wordwrap@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" @@ -4059,13 +3997,3 @@ xml-escape@~1.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.1.tgz#a5c6d532be656e23db820efb943a1f04998d63af" integrity sha1-pcbVMr5lbiPbgg77lDofBJmNY68= - -yargs@~3.10.0: - version "3.10.0" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-3.10.0.tgz#f7ee7bd857dd7c1d2d38c0e74efbd681d1431fd1" - integrity sha1-9+572FfdfB0tOMDnTvvWgdFDH9E= - dependencies: - camelcase "^1.0.2" - cliui "^2.1.0" - decamelize "^1.0.0" - window-size "0.1.0" From 0d9c3473c6412560c28a8f2bf364d0158e3ed2f9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" Date: Mon, 10 Jun 2019 13:54:31 +0000 Subject: [PATCH 004/146] Bump sshpk from 1.13.1 to 1.16.1 Bumps [sshpk](https://github.com/joyent/node-sshpk) from 1.13.1 to 1.16.1. - [Release notes](https://github.com/joyent/node-sshpk/releases) - [Commits](https://github.com/joyent/node-sshpk/compare/v1.13.1...v1.16.1) Signed-off-by: dependabot[bot] --- yarn.lock | 38 +++++++++++++++++++++++--------------- 1 file changed, 23 insertions(+), 15 deletions(-) diff --git a/yarn.lock b/yarn.lock index d2b1c3cf..ef31a280 100644 --- a/yarn.lock +++ b/yarn.lock @@ -148,9 +148,11 @@ array-unique@^0.3.2: integrity sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg= asn1@~0.2.3: - version "0.2.3" - resolved "https://registry.yarnpkg.com/asn1/-/asn1-0.2.3.tgz#dac8787713c9966849fc8180777ebe9c1ddf3b86" - integrity sha1-2sh4dxPJlmhJ/IGAd36+nB3fO4Y= + version "0.2.4" + resolved "https://registry.yarnpkg.com/asn1/-/asn1-0.2.4.tgz#8d2475dfab553bb33e77b54e59e880bb8ce23136" + integrity sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg== + dependencies: + safer-buffer "~2.1.0" assert-plus@1.0.0, assert-plus@^1.0.0: version "1.0.0" @@ -867,9 +869,9 @@ base@^0.11.1: pascalcase "^0.1.1" bcrypt-pbkdf@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.1.tgz#63bc5dcb61331b92bc05fd528953c33462a06f8d" - integrity sha1-Y7xdy2EzG5K8Bf1SiVPDNGKgb40= + version "1.0.2" + resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz#a4301d389b6a43f9b67ff3ca11a3f6637e360e9e" + integrity sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4= dependencies: tweetnacl "^0.14.3" @@ -1272,11 +1274,12 @@ duplexer2@0.0.2: readable-stream "~1.1.9" ecc-jsbn@~0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.1.tgz#0fc73a9ed5f0d53c38193398523ef7e543777505" - integrity sha1-D8c6ntXw1Tw4GTOYUj735UN3dQU= + version "0.1.2" + resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz#3a83a904e54353287874c564b7549386849a98c9" + integrity sha1-OoOpBOVDUyh4dMVkt1SThoSamMk= dependencies: jsbn "~0.1.0" + safer-buffer "^2.1.0" end-of-stream@~0.1.5: version "0.1.5" @@ -3470,6 +3473,11 @@ safe-regex@^1.1.0: dependencies: ret "~0.1.10" +safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: + version "2.1.2" + resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" + integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== + semver@^4.1.0: version "4.3.6" resolved "https://registry.yarnpkg.com/semver/-/semver-4.3.6.tgz#300bc6e0e86374f7ba61068b5b1ecd57fc6532da" @@ -3632,18 +3640,18 @@ sprintf-js@~1.0.2: integrity sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw= sshpk@^1.7.0: - version "1.13.1" - resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.13.1.tgz#512df6da6287144316dc4c18fe1cf1d940739be3" - integrity sha1-US322mKHFEMW3EwY/hzx2UBzm+M= + version "1.16.1" + resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.16.1.tgz#fb661c0bef29b39db40769ee39fa70093d6f6877" + integrity sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg== dependencies: asn1 "~0.2.3" assert-plus "^1.0.0" - dashdash "^1.12.0" - getpass "^0.1.1" - optionalDependencies: bcrypt-pbkdf "^1.0.0" + dashdash "^1.12.0" ecc-jsbn "~0.1.1" + getpass "^0.1.1" jsbn "~0.1.0" + safer-buffer "^2.0.2" tweetnacl "~0.14.0" static-extend@^0.1.1: From 3afbbf456816634649e5b06523be43ce24a43128 Mon Sep 17 00:00:00 2001 From: Alexandre Passant Date: Mon, 10 Jun 2019 17:51:46 +0100 Subject: [PATCH 005/146] Remove gulp-nsp --- gulpfile.js | 6 -- package.json | 1 - yarn.lock | 179 +++------------------------------------------------ 3 files changed, 9 insertions(+), 177 deletions(-) diff --git a/gulpfile.js b/gulpfile.js index 2fb187e0..33e8ee05 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -1,10 +1,8 @@ var gulp = require('gulp'); -var path = require('path'); var eslint = require('gulp-eslint'); var excludeGitignore = require('gulp-exclude-gitignore'); var mocha = require('gulp-mocha'); var istanbul = require('gulp-istanbul'); -var nsp = require('gulp-nsp'); var plumber = require('gulp-plumber'); var babel = require('gulp-babel'); @@ -20,10 +18,6 @@ gulp.task('static', function () { .pipe(eslint.failAfterError()); }); -gulp.task('nsp', function (cb) { - nsp({ package: path.resolve(__dirname, 'package.json') }, cb); -}); - gulp.task('pre-test', function () { return gulp.src('lib/**/*.js') .pipe(babel()) diff --git a/package.json b/package.json index fdb6e68f..019f8582 100644 --- a/package.json +++ b/package.json @@ -34,7 +34,6 @@ "gulp-exclude-gitignore": "^1.0.0", "gulp-istanbul": "^0.10.3", "gulp-mocha": "^2.0.0", - "gulp-nsp": "^2.4.2", "gulp-plumber": "^1.1.0", "nock": "7.5.0", "sinon": "^6.1.4" diff --git a/yarn.lock b/yarn.lock index 242cd2d6..b0f0dac5 100644 --- a/yarn.lock +++ b/yarn.lock @@ -43,14 +43,6 @@ acorn-to-esprima@^2.0.4: resolved "https://registry.yarnpkg.com/acorn-to-esprima/-/acorn-to-esprima-2.0.8.tgz#003f0c642eb92132f417d3708f14ada82adf2eb1" integrity sha1-AD8MZC65ITL0F9NwjxStqCrfLrE= -agent-base@2: - version "2.1.1" - resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-2.1.1.tgz#d6de10d5af6132d5bd692427d46fc538539094c7" - integrity sha1-1t4Q1a9hMtW9aSQn1G/FOFOQlMc= - dependencies: - extend "~3.0.0" - semver "~5.0.1" - ajv@^5.1.0: version "5.2.3" resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.2.3.tgz#c06f598778c44c6b161abafe3466b81ad1814ed2" @@ -876,13 +868,6 @@ bluebird@^3.3.4: resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.5.1.tgz#d9551f9de98f1fcda1e683d17ee91a0602ee2eb9" integrity sha512-MKiLiV+I1AA596t9w1sQJ8jkiSr5+ZKi0WKrYGUn6d1Fx+Ij4tIj+m2WMQSGczs5jZVxV339chE8iwk6F64wjA== -boom@2.x.x: - version "2.10.1" - resolved "https://registry.yarnpkg.com/boom/-/boom-2.10.1.tgz#39c8918ceff5799f83f9492a848f625add0c766f" - integrity sha1-OciRjO/1eZ+D+UkqhI9iWt0Mdm8= - dependencies: - hoek "2.x.x" - boom@4.x.x: version "4.3.1" resolved "https://registry.yarnpkg.com/boom/-/boom-4.3.1.tgz#4f8a3005cb4a7e3889f749030fd25b96e01d2e31" @@ -978,23 +963,11 @@ class-utils@^0.3.5: isobject "^3.0.0" static-extend "^0.1.1" -cli-table@^0.3.1: - version "0.3.1" - resolved "https://registry.yarnpkg.com/cli-table/-/cli-table-0.3.1.tgz#f53b05266a8b1a0b934b3d0821e6e2dc5914ae23" - integrity sha1-9TsFJmqLGguTSz0IIebi3FkUriM= - dependencies: - colors "1.0.3" - cli-width@^1.0.1: version "1.1.1" resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-1.1.1.tgz#a4d293ef67ebb7b88d4a4d42c0ccf00c4d1e366d" integrity sha1-pNKT72frt7iNSk1CwMzwDE0eNm0= -cliclopts@^1.1.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/cliclopts/-/cliclopts-1.1.1.tgz#69431c7cb5af723774b0d3911b4c37512431910f" - integrity sha1-aUMcfLWvcjd0sNORG0w3USQxkQ8= - clone-stats@^0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/clone-stats/-/clone-stats-0.0.1.tgz#b88f94a82cf38b8791d58046ea4029ad88ca99d1" @@ -1028,11 +1001,6 @@ collection-visit@^1.0.0: map-visit "^1.0.0" object-visit "^1.0.0" -colors@1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/colors/-/colors-1.0.3.tgz#0433f44d809680fdeb60ed260f1b0c262e82a40b" - integrity sha1-BDP0TYCWgP3rYO0mDxsMJi6CpAs= - combined-stream@^1.0.5, combined-stream@~1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.5.tgz#938370a57b4a51dea2c77c15d5c5fdf895164009" @@ -1101,11 +1069,6 @@ cryptiles@3.x.x: dependencies: boom "5.x.x" -cvss@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/cvss/-/cvss-1.0.2.tgz#df67e92bf12a796f49e928799c8db3ba74b9fcd6" - integrity sha1-32fpK/EqeW9J6Sh5nI2zunS5/NY= - d@1: version "1.0.0" resolved "https://registry.yarnpkg.com/d/-/d-1.0.0.tgz#754bb5bfe55451da69a58b94d45f4c5b0462d58f" @@ -1125,13 +1088,6 @@ dateformat@^2.0.0: resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-2.2.0.tgz#4065e2013cf9fb916ddfd82efb506ad4c6769062" integrity sha1-QGXiATz5+5Ft39gu+1Bq1MZ2kGI= -debug@2, debug@^2.1.1, debug@^2.1.3, debug@^2.2.0, debug@^2.3.3, debug@^2.6.8: - version "2.6.9" - resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" - integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== - dependencies: - ms "2.0.0" - debug@2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/debug/-/debug-2.2.0.tgz#f87057e995b1a1f6ae6a4960664137bc56f039da" @@ -1139,6 +1095,13 @@ debug@2.2.0: dependencies: ms "0.7.1" +debug@^2.1.1, debug@^2.2.0, debug@^2.3.3, debug@^2.6.8: + version "2.6.9" + resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" + integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== + dependencies: + ms "2.0.0" + decode-uri-component@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545" @@ -1156,11 +1119,6 @@ deep-equal@^1.0.0: resolved "https://registry.yarnpkg.com/deep-equal/-/deep-equal-1.0.1.tgz#f5d260292b660e084eff4cdbc9f08ad3247448b5" integrity sha1-9dJgKStmDghO/0zbyfCK0yR0SLU= -deep-extend@~0.4.0: - version "0.4.2" - resolved "https://registry.yarnpkg.com/deep-extend/-/deep-extend-0.4.2.tgz#48b699c27e334bf89f10892be432f6e4c7d34a7f" - integrity sha1-SLaZwn4zS/ifEIkr5DL25MfTSn8= - deep-is@~0.1.2, deep-is@~0.1.3: version "0.1.3" resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34" @@ -1488,7 +1446,7 @@ extend-shallow@^3.0.0, extend-shallow@^3.0.2: assign-symbols "^1.0.0" is-extendable "^1.0.1" -extend@3, extend@^3.0.0, extend@~3.0.0, extend@~3.0.1: +extend@^3.0.0, extend@~3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444" integrity sha1-p1Xqe8Gt/MWjHOfnYtuq3F5jZEQ= @@ -1855,14 +1813,6 @@ gulp-mocha@^2.0.0: temp "^0.8.3" through "^2.3.4" -gulp-nsp@^2.4.2: - version "2.4.2" - resolved "https://registry.yarnpkg.com/gulp-nsp/-/gulp-nsp-2.4.2.tgz#9ea6c091b8fadf2792aa4b0bd3af01cdde150ef2" - integrity sha1-nqbAkbj63yeSqksL068Bzd4VDvI= - dependencies: - gulp-util "^3.0.6" - nsp "^2.0.0" - gulp-plumber@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/gulp-plumber/-/gulp-plumber-1.1.0.tgz#f12176c2d0422f60306c242fff6a01a394faba09" @@ -2010,11 +1960,6 @@ hawk@~6.0.2: hoek "4.x.x" sntp "2.x.x" -hoek@2.x.x: - version "2.16.3" - resolved "https://registry.yarnpkg.com/hoek/-/hoek-2.16.3.tgz#20bb7403d3cea398e91dc4710a8ff1b8274a25ed" - integrity sha1-ILt0A9POo5jpHcRxCo/xuCdKJe0= - hoek@4.x.x: version "4.2.0" resolved "https://registry.yarnpkg.com/hoek/-/hoek-4.2.0.tgz#72d9d0754f7fe25ca2d01ad8f8f9a9449a89526d" @@ -2049,15 +1994,6 @@ http-signature@~1.2.0: jsprim "^1.2.2" sshpk "^1.7.0" -https-proxy-agent@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-1.0.0.tgz#35f7da6c48ce4ddbfa264891ac593ee5ff8671e6" - integrity sha1-NffabEjOTdv6JkiRrFk+5f+GceY= - dependencies: - agent-base "2" - debug "2" - extend "3" - inflight@^1.0.4: version "1.0.6" resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" @@ -2081,11 +2017,6 @@ ini@^1.3.4: resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.5.tgz#eee25f56db1c9ec6085e0c22778083f596abf927" integrity sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw== -ini@~1.3.0: - version "1.3.4" - resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.4.tgz#0537cb79daf59b59a1a517dff706c86ec039162e" - integrity sha1-BTfLedr1m1mhpRff9wbIbsA5Fi4= - inquirer@^0.8.2: version "0.8.5" resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-0.8.5.tgz#dbd740cf6ca3b731296a63ce6f6d961851f336df" @@ -2287,11 +2218,6 @@ isarray@1.0.0, isarray@~1.0.0: resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" integrity sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE= -isemail@1.x.x: - version "1.2.0" - resolved "https://registry.yarnpkg.com/isemail/-/isemail-1.2.0.tgz#be03df8cc3e29de4d2c5df6501263f1fa4595e9a" - integrity sha1-vgPfjMPineTSxd9lASY/H6RZXpo= - isexe@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" @@ -2370,16 +2296,6 @@ jade@0.26.3: commander "0.6.1" mkdirp "0.3.0" -joi@^6.9.1: - version "6.10.1" - resolved "https://registry.yarnpkg.com/joi/-/joi-6.10.1.tgz#4d50c318079122000fe5f16af1ff8e1917b77e06" - integrity sha1-TVDDGAeRIgAP5fFq8f+OGRe3fgY= - dependencies: - hoek "2.x.x" - isemail "1.x.x" - moment "2.x.x" - topo "1.x.x" - js-tokens@^3.0.0, js-tokens@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b" @@ -2826,7 +2742,7 @@ minimist@0.0.8: resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d" integrity sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0= -minimist@^1.1.0, minimist@^1.2.0: +minimist@^1.1.0: version "1.2.0" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284" integrity sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ= @@ -2872,11 +2788,6 @@ mocha@^2.0.1: supports-color "1.2.0" to-iso-string "0.0.2" -moment@2.x.x: - version "2.19.1" - resolved "https://registry.yarnpkg.com/moment/-/moment-2.19.1.tgz#56da1a2d1cbf01d38b7e1afc31c10bcfa1929167" - integrity sha1-VtoaLRy/AdOLfhr8McELz6GSkWc= - ms@0.7.1: version "0.7.1" resolved "https://registry.yarnpkg.com/ms/-/ms-0.7.1.tgz#9cd13c03adbff25b65effde7ce864ee952017098" @@ -2952,11 +2863,6 @@ nock@7.5.0: propagate "0.3.x" qs "^6.0.2" -nodesecurity-npm-utils@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/nodesecurity-npm-utils/-/nodesecurity-npm-utils-5.0.0.tgz#05aa30de30ca8c845c4048e94fd78e5e08b55ed9" - integrity sha1-Baow3jDKjIRcQEjpT9eOXgi1Xtk= - nopt@3.x: version "3.0.6" resolved "https://registry.yarnpkg.com/nopt/-/nopt-3.0.6.tgz#c6465dbf08abcd4db359317f79ac68a646b28ff9" @@ -2964,23 +2870,6 @@ nopt@3.x: dependencies: abbrev "1" -nsp@^2.0.0: - version "2.8.1" - resolved "https://registry.yarnpkg.com/nsp/-/nsp-2.8.1.tgz#436e3f13869e0610d3a38f59d55f9b353cc32817" - integrity sha512-jvjDg2Gsw4coD/iZ5eQddsDlkvnwMCNnpG05BproSnuG+Gr1bSQMwWMcQeYje+qdDl3XznmhblMPLpZLecTORQ== - dependencies: - chalk "^1.1.1" - cli-table "^0.3.1" - cvss "^1.0.0" - https-proxy-agent "^1.0.0" - joi "^6.9.1" - nodesecurity-npm-utils "^5.0.0" - path-is-absolute "^1.0.0" - rc "^1.1.2" - semver "^5.0.3" - subcommand "^2.0.3" - wreck "^6.3.0" - number-is-nan@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" @@ -3217,16 +3106,6 @@ qs@^6.0.2, qs@~6.5.1: resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8" integrity sha512-eRzhrN1WSINYCDCbrz796z37LOe3m5tmW7RQf6oBntukAG1nmovJvhnwHHRMAfeoItc1m2Hk02WER2aQ/iqs+A== -rc@^1.1.2: - version "1.2.2" - resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.2.tgz#d8ce9cb57e8d64d9c7badd9876c7c34cbe3c7077" - integrity sha1-2M6ctX6NZNnHut2YdsfDTL48cHc= - dependencies: - deep-extend "~0.4.0" - ini "~1.3.0" - minimist "^1.2.0" - strip-json-comments "~2.0.1" - "readable-stream@>=1.0.33-1 <1.1.0-0": version "1.0.34" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.0.34.tgz#125820e34bc842d2f2aaafafe4c2916ee32c157c" @@ -3440,16 +3319,6 @@ semver@^4.1.0: resolved "https://registry.yarnpkg.com/semver/-/semver-4.3.6.tgz#300bc6e0e86374f7ba61068b5b1ecd57fc6532da" integrity sha1-MAvG4OhjdPe6YQaLWx7NV/xlMto= -semver@^5.0.3: - version "5.4.1" - resolved "https://registry.yarnpkg.com/semver/-/semver-5.4.1.tgz#e059c09d8571f0540823733433505d3a2f00b18e" - integrity sha512-WfG/X9+oATh81XtllIo/I8gOiY9EXRdv1cQdyykeXK17YcUW3EXUAi2To4pcH6nZtJPr7ZOpM5OMyWJZm+8Rsg== - -semver@~5.0.1: - version "5.0.3" - resolved "https://registry.yarnpkg.com/semver/-/semver-5.0.3.tgz#77466de589cd5d3c95f138aa78bc569a3cb5d27a" - integrity sha1-d0Zt5YnNXTyV8TiqeLxWmjy10no= - sequencify@~0.0.7: version "0.0.7" resolved "https://registry.yarnpkg.com/sequencify/-/sequencify-0.0.7.tgz#90cff19d02e07027fd767f5ead3e7b95d1e7380c" @@ -3666,21 +3535,6 @@ strip-json-comments@~1.0.1: resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-1.0.4.tgz#1e15fbcac97d3ee99bf2d73b4c656b082bbafb91" integrity sha1-HhX7ysl9Pumb8tc7TGVrCCu6+5E= -strip-json-comments@~2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" - integrity sha1-PFMZQukIwml8DsNEhYwobHygpgo= - -subcommand@^2.0.3: - version "2.1.0" - resolved "https://registry.yarnpkg.com/subcommand/-/subcommand-2.1.0.tgz#5e4ceca5a3779e3365b1511e05f866877302f760" - integrity sha1-XkzspaN3njNlsVEeBfhmh3MC92A= - dependencies: - cliclopts "^1.1.0" - debug "^2.1.3" - minimist "^1.2.0" - xtend "^4.0.0" - supports-color@1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-1.2.0.tgz#ff1ed1e61169d06b3cf2d588e188b18d8847e17e" @@ -3791,13 +3645,6 @@ to-regex@^3.0.1, to-regex@^3.0.2: regex-not "^1.0.2" safe-regex "^1.1.0" -topo@1.x.x: - version "1.1.0" - resolved "https://registry.yarnpkg.com/topo/-/topo-1.1.0.tgz#e9d751615d1bb87dc865db182fa1ca0a5ef536d5" - integrity sha1-6ddRYV0buH3IZdsYL6HKCl71NtU= - dependencies: - hoek "2.x.x" - tough-cookie@~2.3.3: version "2.3.3" resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.3.tgz#0b618a5565b6dea90bf3425d04d55edc475a7561" @@ -3988,14 +3835,6 @@ wrappy@1: resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= -wreck@^6.3.0: - version "6.3.0" - resolved "https://registry.yarnpkg.com/wreck/-/wreck-6.3.0.tgz#a1369769f07bbb62d6a378336a7871fc773c740b" - integrity sha1-oTaXafB7u2LWo3gzanhx/Hc8dAs= - dependencies: - boom "2.x.x" - hoek "2.x.x" - xml-escape@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/xml-escape/-/xml-escape-1.0.0.tgz#00963d697b2adf0c185c4e04e73174ba9b288eb2" From 49d9877728bb7a4d589cee05ca45917466c491c1 Mon Sep 17 00:00:00 2001 From: Alexandre Passant Date: Tue, 11 Jun 2019 09:37:57 +0100 Subject: [PATCH 006/146] 2.10.5 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 019f8582..0159fec4 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "2.10.4", + "version": "2.10.5", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", From 39a445f731d6146e1fe6ba82dbe0d890955573ac Mon Sep 17 00:00:00 2001 From: Alexandre Passant Date: Tue, 11 Jun 2019 10:09:28 +0100 Subject: [PATCH 007/146] Ap/2 10 6 (#241) * 2.10.6 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 0159fec4..3e7305ee 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "2.10.5", + "version": "2.10.6", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", From ba19772ee1496bdb27c13806c0258c1adafe783f Mon Sep 17 00:00:00 2001 From: Raph Estrada Date: Sun, 30 Jun 2019 16:22:07 +0100 Subject: [PATCH 008/146] bump stringstream from 0.0.5 to 0.0.6 --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index b0f0dac5..2932afd2 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3504,9 +3504,9 @@ string_decoder@~1.0.3: safe-buffer "~5.1.0" stringstream@~0.0.5: - version "0.0.5" - resolved "https://registry.yarnpkg.com/stringstream/-/stringstream-0.0.5.tgz#4e484cd4de5a0bbbee18e46307710a8a81621878" - integrity sha1-TkhM1N5aC7vuGORjB3EKioFiGHg= + version "0.0.6" + resolved "https://registry.yarnpkg.com/stringstream/-/stringstream-0.0.6.tgz#7880225b0d4ad10e30927d167a1d6f2fd3b33a72" + integrity sha512-87GEBAkegbBcweToUrdzf3eLhWNg06FJTebl4BVJz/JgWy8CvEr9dRtX5qWphiynMSQlxxi+QqN0z5T32SLlhA== strip-ansi@^2.0.1: version "2.0.1" From bee71875300eac5954438db03fb131be18f9305d Mon Sep 17 00:00:00 2001 From: Matt Donnelly Date: Wed, 3 Jul 2019 17:49:02 +0100 Subject: [PATCH 009/146] Update deps --- .babelrc | 2 +- .eslintrc | 14 +- gulpfile.js | 48 +- lib/contact.js | 2 +- lib/index.js | 13 +- lib/scroll.js | 2 +- lib/tag.js | 8 +- lib/user.js | 10 +- lib/visitor.js | 2 +- package.json | 13 +- yarn.lock | 3811 ++++++++++++++++++++++++++++++++---------------- 11 files changed, 2582 insertions(+), 1343 deletions(-) diff --git a/.babelrc b/.babelrc index 36ef793b..1320b9a3 100644 --- a/.babelrc +++ b/.babelrc @@ -1,3 +1,3 @@ { - "presets": ["es2015", "stage-1"] + "presets": ["@babel/preset-env"] } diff --git a/.eslintrc b/.eslintrc index 2f8e19ca..ead4b94d 100644 --- a/.eslintrc +++ b/.eslintrc @@ -29,10 +29,7 @@ "named": "never" } ], - "space-after-keywords": [ - 2, - "always" - ], + "keyword-spacing": 2, "array-bracket-spacing": [ 2, "never" @@ -109,7 +106,6 @@ "eqeqeq": 2, "no-alert": 2, "no-caller": 2, - "no-empty-label": 2, "no-extend-native": 2, "no-extra-bind": 2, "no-fallthrough": 2, @@ -159,7 +155,7 @@ "no-spaced-func": 2, "no-trailing-spaces": 2, "no-underscore-dangle": 2, - "no-wrap-func": 2, + "no-extra-parens": 2, "semi-spacing": [ 2, { @@ -167,15 +163,11 @@ "after": true } ], - "semi": 2, - "space-return-throw-case": 2 + "semi": 2 }, "env": { "node": true, "mocha": true, "es6": true - }, - "ecmaFeatures": { - "modules": true } } diff --git a/gulpfile.js b/gulpfile.js index 33e8ee05..5e58e58f 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -6,12 +6,9 @@ var istanbul = require('gulp-istanbul'); var plumber = require('gulp-plumber'); var babel = require('gulp-babel'); -// Initialize the babel transpiler so ES2015 files gets compiled -// when they're loaded -require('babel-core/register'); - gulp.task('static', function () { - return gulp.src('**/*.js') + return gulp + .src('**/*.js') .pipe(excludeGitignore()) .pipe(eslint()) .pipe(eslint.format()) @@ -19,31 +16,36 @@ gulp.task('static', function () { }); gulp.task('pre-test', function () { - return gulp.src('lib/**/*.js') + return gulp + .src('lib/**/*.js') .pipe(babel()) - .pipe(istanbul({includeUntested: true})) + .pipe(istanbul({ includeUntested: true })) .pipe(istanbul.hookRequire()); }); -gulp.task('test', ['pre-test'], function (cb) { - var mochaErr; - - gulp.src('test/**/*.js') - .pipe(plumber()) - .pipe(mocha({reporter: 'spec'})) - .on('error', function (err) { - mochaErr = err; - }) - .on('end', function () { - cb(mochaErr); - }); -}); +gulp.task( + 'test', + gulp.series('pre-test', function (done) { + var mochaErr; + gulp + .src('test/**/*.js') + .pipe(plumber()) + .pipe(mocha({ reporter: 'spec' })) + .on('error', function (err) { + mochaErr = err; + }) + .on('end', function () { + done(mochaErr); + }); + }) +); gulp.task('babel', function () { - return gulp.src('lib/**/*.js') + return gulp + .src('lib/**/*.js') .pipe(babel()) .pipe(gulp.dest('dist')); }); -gulp.task('prepublish', ['babel']); -gulp.task('default', ['static', 'test']); +gulp.task('prepublish', gulp.series('babel')); +gulp.task('default', gulp.series('static', 'test')); diff --git a/lib/contact.js b/lib/contact.js index 930cc36f..7d257f50 100644 --- a/lib/contact.js +++ b/lib/contact.js @@ -28,7 +28,7 @@ export default class Contact { if (params.id) { return this.client.get(`/contacts/${params.id}`, {}, f); } else if (params.user_id) { - return this.client.get(`/contacts`, { user_id: params.user_id }, f); + return this.client.get('/contacts', { user_id: params.user_id }, f); } } delete(params, f) { diff --git a/lib/index.js b/lib/index.js index 74b9221c..25873704 100644 --- a/lib/index.js +++ b/lib/index.js @@ -1,7 +1,7 @@ -export Client from './client'; -export User from './user'; -export Snippet from './snippet'; -export UserData from './user-data'; +export { default as Client } from './client'; +export { default as User } from './user'; +export { default as Snippet } from './snippet'; +export { default as UserData } from './user-data'; import crypto from 'crypto'; @@ -15,6 +15,9 @@ export class IdentityVerification { if (!identifier) { throw new Error('identifier must be provided'); } - return crypto.createHmac('sha256', secretKey).update(identifier).digest('hex'); + return crypto + .createHmac('sha256', secretKey) + .update(identifier) + .digest('hex'); } } diff --git a/lib/scroll.js b/lib/scroll.js index 4f4b6e19..75c3e06b 100644 --- a/lib/scroll.js +++ b/lib/scroll.js @@ -20,7 +20,7 @@ export default class Scroll { var result = f(response); if (response.body[`${self.dataType}s`].length > 0) { self.scroll_param = response.body.scroll_param; - if (result && ('then' in result) && typeof result.then === 'function') { + if (result && 'then' in result && typeof result.then === 'function') { result.then(function () { self.eachInternal(params, f, promise); }, function (error) { diff --git a/lib/tag.js b/lib/tag.js index 717e7043..640ef8b8 100644 --- a/lib/tag.js +++ b/lib/tag.js @@ -9,8 +9,12 @@ export default class Tag { return this.client.post('/tags', data, f); } untag(data, f) { - (data.users || []).forEach(user => user.untag = true); - (data.companies || []).forEach(company => company.untag = true); + (data.users || []).forEach(user => { + user.untag = true; + }); + (data.companies || []).forEach(company => { + company.untag = true; + }); return this.client.post('/tags', data, f); } delete(params, f) { diff --git a/lib/user.js b/lib/user.js index 6539c46f..0cf0c233 100644 --- a/lib/user.js +++ b/lib/user.js @@ -26,22 +26,22 @@ export default class User { if (params.id) { return this.client.get(`/users/${params.id}`, {}, f); } else if (params.user_id) { - return this.client.get(`/users`, { user_id: params.user_id }, f); + return this.client.get('/users', { user_id: params.user_id }, f); } else if (params.email) { - return this.client.get(`/users`, { email: params.email }, f); + return this.client.get('/users', { email: params.email }, f); } } archive(params, f) { if (params.id) { return this.client.delete(`/users/${params.id}`, {}, f); } else if (params.user_id) { - return this.client.delete(`/users`, { user_id: params.user_id }, f); + return this.client.delete('/users', { user_id: params.user_id }, f); } else if (params.email) { - return this.client.delete(`/users`, { email: params.email }, f); + return this.client.delete('/users', { email: params.email }, f); } } bulk(params, f) { - return (new Bulk(this.client, 'user').bulk(params, f)); + return new Bulk(this.client, 'user').bulk(params, f); } requestPermanentDeletion(intercom_user_id, f) { return this.client.post('/user_delete_requests', { intercom_user_id }, f); diff --git a/lib/visitor.js b/lib/visitor.js index bc3cd554..9ab6e538 100644 --- a/lib/visitor.js +++ b/lib/visitor.js @@ -9,7 +9,7 @@ export default class Visitor { if (params.id) { return this.client.get(`/visitors/${params.id}`, {}, f); } else if (params.user_id) { - return this.client.get(`/visitors`, { user_id: params.user_id }, f); + return this.client.get('/visitors', { user_id: params.user_id }, f); } } delete(params, f) { diff --git a/package.json b/package.json index 3e7305ee..10c2e863 100644 --- a/package.json +++ b/package.json @@ -24,13 +24,12 @@ "request": "^2.83.0" }, "devDependencies": { - "babel-core": "^6.7.4", - "babel-eslint": "^5.0.0", - "babel-preset-es2015": "^6.6.0", - "babel-preset-stage-1": "^6.5.0", - "gulp": "^3.9.1", - "gulp-babel": "^6.1.2", - "gulp-eslint": "^0.15.0", + "@babel/core": "^7.4.5", + "@babel/preset-env": "^7.4.5", + "babel-eslint": "^10.0.2", + "gulp": "^4.0.2", + "gulp-babel": "^8.0.0", + "gulp-eslint": "4.0.2", "gulp-exclude-gitignore": "^1.0.0", "gulp-istanbul": "^0.10.3", "gulp-mocha": "^2.0.0", diff --git a/yarn.lock b/yarn.lock index 2932afd2..b4564d73 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,6 +2,622 @@ # yarn lockfile v1 +"@babel/code-frame@^7.0.0": + version "7.0.0" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0.tgz#06e2ab19bdb535385559aabb5ba59729482800f8" + integrity sha512-OfC2uemaknXr87bdLUkWog7nYuliM9Ij5HUcajsVcMCpQrcLmtxRbVFTIqmcSkSeYRBFBRxs2FiUqFJDLdiebA== + dependencies: + "@babel/highlight" "^7.0.0" + +"@babel/core@^7.4.5": + version "7.4.5" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.4.5.tgz#081f97e8ffca65a9b4b0fdc7e274e703f000c06a" + integrity sha512-OvjIh6aqXtlsA8ujtGKfC7LYWksYSX8yQcM8Ay3LuvVeQ63lcOKgoZWVqcpFwkd29aYU9rVx7jxhfhiEDV9MZA== + dependencies: + "@babel/code-frame" "^7.0.0" + "@babel/generator" "^7.4.4" + "@babel/helpers" "^7.4.4" + "@babel/parser" "^7.4.5" + "@babel/template" "^7.4.4" + "@babel/traverse" "^7.4.5" + "@babel/types" "^7.4.4" + convert-source-map "^1.1.0" + debug "^4.1.0" + json5 "^2.1.0" + lodash "^4.17.11" + resolve "^1.3.2" + semver "^5.4.1" + source-map "^0.5.0" + +"@babel/generator@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.4.4.tgz#174a215eb843fc392c7edcaabeaa873de6e8f041" + integrity sha512-53UOLK6TVNqKxf7RUh8NE851EHRxOOeVXKbK2bivdb+iziMyk03Sr4eaE9OELCbyZAAafAKPDwF2TPUES5QbxQ== + dependencies: + "@babel/types" "^7.4.4" + jsesc "^2.5.1" + lodash "^4.17.11" + source-map "^0.5.0" + trim-right "^1.0.1" + +"@babel/helper-annotate-as-pure@^7.0.0": + version "7.0.0" + resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.0.0.tgz#323d39dd0b50e10c7c06ca7d7638e6864d8c5c32" + integrity sha512-3UYcJUj9kvSLbLbUIfQTqzcy5VX7GRZ/CCDrnOaZorFFM01aXp1+GJwuFGV4NDDoAS+mOUyHcO6UD/RfqOks3Q== + dependencies: + "@babel/types" "^7.0.0" + +"@babel/helper-builder-binary-assignment-operator-visitor@^7.1.0": + version "7.1.0" + resolved "https://registry.yarnpkg.com/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.1.0.tgz#6b69628dfe4087798e0c4ed98e3d4a6b2fbd2f5f" + integrity sha512-qNSR4jrmJ8M1VMM9tibvyRAHXQs2PmaksQF7c1CGJNipfe3D8p+wgNwgso/P2A2r2mdgBWAXljNWR0QRZAMW8w== + dependencies: + "@babel/helper-explode-assignable-expression" "^7.1.0" + "@babel/types" "^7.0.0" + +"@babel/helper-call-delegate@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/helper-call-delegate/-/helper-call-delegate-7.4.4.tgz#87c1f8ca19ad552a736a7a27b1c1fcf8b1ff1f43" + integrity sha512-l79boDFJ8S1c5hvQvG+rc+wHw6IuH7YldmRKsYtpbawsxURu/paVy57FZMomGK22/JckepaikOkY0MoAmdyOlQ== + dependencies: + "@babel/helper-hoist-variables" "^7.4.4" + "@babel/traverse" "^7.4.4" + "@babel/types" "^7.4.4" + +"@babel/helper-define-map@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/helper-define-map/-/helper-define-map-7.4.4.tgz#6969d1f570b46bdc900d1eba8e5d59c48ba2c12a" + integrity sha512-IX3Ln8gLhZpSuqHJSnTNBWGDE9kdkTEWl21A/K7PQ00tseBwbqCHTvNLHSBd9M0R5rER4h5Rsvj9vw0R5SieBg== + dependencies: + "@babel/helper-function-name" "^7.1.0" + "@babel/types" "^7.4.4" + lodash "^4.17.11" + +"@babel/helper-explode-assignable-expression@^7.1.0": + version "7.1.0" + resolved "https://registry.yarnpkg.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.1.0.tgz#537fa13f6f1674df745b0c00ec8fe4e99681c8f6" + integrity sha512-NRQpfHrJ1msCHtKjbzs9YcMmJZOg6mQMmGRB+hbamEdG5PNpaSm95275VD92DvJKuyl0s2sFiDmMZ+EnnvufqA== + dependencies: + "@babel/traverse" "^7.1.0" + "@babel/types" "^7.0.0" + +"@babel/helper-function-name@^7.1.0": + version "7.1.0" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.1.0.tgz#a0ceb01685f73355d4360c1247f582bfafc8ff53" + integrity sha512-A95XEoCpb3TO+KZzJ4S/5uW5fNe26DjBGqf1o9ucyLyCmi1dXq/B3c8iaWTfBk3VvetUxl16e8tIrd5teOCfGw== + dependencies: + "@babel/helper-get-function-arity" "^7.0.0" + "@babel/template" "^7.1.0" + "@babel/types" "^7.0.0" + +"@babel/helper-get-function-arity@^7.0.0": + version "7.0.0" + resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0.tgz#83572d4320e2a4657263734113c42868b64e49c3" + integrity sha512-r2DbJeg4svYvt3HOS74U4eWKsUAMRH01Z1ds1zx8KNTPtpTL5JAsdFv8BNyOpVqdFhHkkRDIg5B4AsxmkjAlmQ== + dependencies: + "@babel/types" "^7.0.0" + +"@babel/helper-hoist-variables@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.4.4.tgz#0298b5f25c8c09c53102d52ac4a98f773eb2850a" + integrity sha512-VYk2/H/BnYbZDDg39hr3t2kKyifAm1W6zHRfhx8jGjIHpQEBv9dry7oQ2f3+J703TLu69nYdxsovl0XYfcnK4w== + dependencies: + "@babel/types" "^7.4.4" + +"@babel/helper-member-expression-to-functions@^7.0.0": + version "7.0.0" + resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.0.0.tgz#8cd14b0a0df7ff00f009e7d7a436945f47c7a16f" + integrity sha512-avo+lm/QmZlv27Zsi0xEor2fKcqWG56D5ae9dzklpIaY7cQMK5N8VSpaNVPPagiqmy7LrEjK1IWdGMOqPu5csg== + dependencies: + "@babel/types" "^7.0.0" + +"@babel/helper-module-imports@^7.0.0": + version "7.0.0" + resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.0.0.tgz#96081b7111e486da4d2cd971ad1a4fe216cc2e3d" + integrity sha512-aP/hlLq01DWNEiDg4Jn23i+CXxW/owM4WpDLFUbpjxe4NS3BhLVZQ5i7E0ZrxuQ/vwekIeciyamgB1UIYxxM6A== + dependencies: + "@babel/types" "^7.0.0" + +"@babel/helper-module-transforms@^7.1.0", "@babel/helper-module-transforms@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.4.4.tgz#96115ea42a2f139e619e98ed46df6019b94414b8" + integrity sha512-3Z1yp8TVQf+B4ynN7WoHPKS8EkdTbgAEy0nU0rs/1Kw4pDgmvYH3rz3aI11KgxKCba2cn7N+tqzV1mY2HMN96w== + dependencies: + "@babel/helper-module-imports" "^7.0.0" + "@babel/helper-simple-access" "^7.1.0" + "@babel/helper-split-export-declaration" "^7.4.4" + "@babel/template" "^7.4.4" + "@babel/types" "^7.4.4" + lodash "^4.17.11" + +"@babel/helper-optimise-call-expression@^7.0.0": + version "7.0.0" + resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.0.0.tgz#a2920c5702b073c15de51106200aa8cad20497d5" + integrity sha512-u8nd9NQePYNQV8iPWu/pLLYBqZBa4ZaY1YWRFMuxrid94wKI1QNt67NEZ7GAe5Kc/0LLScbim05xZFWkAdrj9g== + dependencies: + "@babel/types" "^7.0.0" + +"@babel/helper-plugin-utils@^7.0.0": + version "7.0.0" + resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.0.0.tgz#bbb3fbee98661c569034237cc03967ba99b4f250" + integrity sha512-CYAOUCARwExnEixLdB6sDm2dIJ/YgEAKDM1MOeMeZu9Ld/bDgVo8aiWrXwcY7OBh+1Ea2uUcVRcxKk0GJvW7QA== + +"@babel/helper-regex@^7.0.0", "@babel/helper-regex@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/helper-regex/-/helper-regex-7.4.4.tgz#a47e02bc91fb259d2e6727c2a30013e3ac13c4a2" + integrity sha512-Y5nuB/kESmR3tKjU8Nkn1wMGEx1tjJX076HBMeL3XLQCu6vA/YRzuTW0bbb+qRnXvQGn+d6Rx953yffl8vEy7Q== + dependencies: + lodash "^4.17.11" + +"@babel/helper-remap-async-to-generator@^7.1.0": + version "7.1.0" + resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.1.0.tgz#361d80821b6f38da75bd3f0785ece20a88c5fe7f" + integrity sha512-3fOK0L+Fdlg8S5al8u/hWE6vhufGSn0bN09xm2LXMy//REAF8kDCrYoOBKYmA8m5Nom+sV9LyLCwrFynA8/slg== + dependencies: + "@babel/helper-annotate-as-pure" "^7.0.0" + "@babel/helper-wrap-function" "^7.1.0" + "@babel/template" "^7.1.0" + "@babel/traverse" "^7.1.0" + "@babel/types" "^7.0.0" + +"@babel/helper-replace-supers@^7.1.0", "@babel/helper-replace-supers@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.4.4.tgz#aee41783ebe4f2d3ab3ae775e1cc6f1a90cefa27" + integrity sha512-04xGEnd+s01nY1l15EuMS1rfKktNF+1CkKmHoErDppjAAZL+IUBZpzT748x262HF7fibaQPhbvWUl5HeSt1EXg== + dependencies: + "@babel/helper-member-expression-to-functions" "^7.0.0" + "@babel/helper-optimise-call-expression" "^7.0.0" + "@babel/traverse" "^7.4.4" + "@babel/types" "^7.4.4" + +"@babel/helper-simple-access@^7.1.0": + version "7.1.0" + resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.1.0.tgz#65eeb954c8c245beaa4e859da6188f39d71e585c" + integrity sha512-Vk+78hNjRbsiu49zAPALxTb+JUQCz1aolpd8osOF16BGnLtseD21nbHgLPGUwrXEurZgiCOUmvs3ExTu4F5x6w== + dependencies: + "@babel/template" "^7.1.0" + "@babel/types" "^7.0.0" + +"@babel/helper-split-export-declaration@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.4.4.tgz#ff94894a340be78f53f06af038b205c49d993677" + integrity sha512-Ro/XkzLf3JFITkW6b+hNxzZ1n5OQ80NvIUdmHspih1XAhtN3vPTuUFT4eQnela+2MaZ5ulH+iyP513KJrxbN7Q== + dependencies: + "@babel/types" "^7.4.4" + +"@babel/helper-wrap-function@^7.1.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/helper-wrap-function/-/helper-wrap-function-7.2.0.tgz#c4e0012445769e2815b55296ead43a958549f6fa" + integrity sha512-o9fP1BZLLSrYlxYEYyl2aS+Flun5gtjTIG8iln+XuEzQTs0PLagAGSXUcqruJwD5fM48jzIEggCKpIfWTcR7pQ== + dependencies: + "@babel/helper-function-name" "^7.1.0" + "@babel/template" "^7.1.0" + "@babel/traverse" "^7.1.0" + "@babel/types" "^7.2.0" + +"@babel/helpers@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.4.4.tgz#868b0ef59c1dd4e78744562d5ce1b59c89f2f2a5" + integrity sha512-igczbR/0SeuPR8RFfC7tGrbdTbFL3QTvH6D+Z6zNxnTe//GyqmtHmDkzrqDmyZ3eSwPqB/LhyKoU5DXsp+Vp2A== + dependencies: + "@babel/template" "^7.4.4" + "@babel/traverse" "^7.4.4" + "@babel/types" "^7.4.4" + +"@babel/highlight@^7.0.0": + version "7.0.0" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.0.0.tgz#f710c38c8d458e6dd9a201afb637fcb781ce99e4" + integrity sha512-UFMC4ZeFC48Tpvj7C8UgLvtkaUuovQX+5xNWrsIoMG8o2z+XFKjKaN9iVmS84dPwVN00W4wPmqvYoZF3EGAsfw== + dependencies: + chalk "^2.0.0" + esutils "^2.0.2" + js-tokens "^4.0.0" + +"@babel/parser@^7.0.0", "@babel/parser@^7.4.4", "@babel/parser@^7.4.5": + version "7.4.5" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.4.5.tgz#04af8d5d5a2b044a2a1bffacc1e5e6673544e872" + integrity sha512-9mUqkL1FF5T7f0WDFfAoDdiMVPWsdD1gZYzSnaXsxUCUqzuch/8of9G3VUSNiZmMBoRxT3neyVsqeiL/ZPcjew== + +"@babel/plugin-proposal-async-generator-functions@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.2.0.tgz#b289b306669dce4ad20b0252889a15768c9d417e" + integrity sha512-+Dfo/SCQqrwx48ptLVGLdE39YtWRuKc/Y9I5Fy0P1DDBB9lsAHpjcEJQt+4IifuSOSTLBKJObJqMvaO1pIE8LQ== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-remap-async-to-generator" "^7.1.0" + "@babel/plugin-syntax-async-generators" "^7.2.0" + +"@babel/plugin-proposal-json-strings@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.2.0.tgz#568ecc446c6148ae6b267f02551130891e29f317" + integrity sha512-MAFV1CA/YVmYwZG0fBQyXhmj0BHCB5egZHCKWIFVv/XCxAeVGIHfos3SwDck4LvCllENIAg7xMKOG5kH0dzyUg== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/plugin-syntax-json-strings" "^7.2.0" + +"@babel/plugin-proposal-object-rest-spread@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.4.4.tgz#1ef173fcf24b3e2df92a678f027673b55e7e3005" + integrity sha512-dMBG6cSPBbHeEBdFXeQ2QLc5gUpg4Vkaz8octD4aoW/ISO+jBOcsuxYL7bsb5WSu8RLP6boxrBIALEHgoHtO9g== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/plugin-syntax-object-rest-spread" "^7.2.0" + +"@babel/plugin-proposal-optional-catch-binding@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.2.0.tgz#135d81edb68a081e55e56ec48541ece8065c38f5" + integrity sha512-mgYj3jCcxug6KUcX4OBoOJz3CMrwRfQELPQ5560F70YQUBZB7uac9fqaWamKR1iWUzGiK2t0ygzjTScZnVz75g== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/plugin-syntax-optional-catch-binding" "^7.2.0" + +"@babel/plugin-proposal-unicode-property-regex@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.4.4.tgz#501ffd9826c0b91da22690720722ac7cb1ca9c78" + integrity sha512-j1NwnOqMG9mFUOH58JTFsA/+ZYzQLUZ/drqWUqxCYLGeu2JFZL8YrNC9hBxKmWtAuOCHPcRpgv7fhap09Fb4kA== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-regex" "^7.4.4" + regexpu-core "^4.5.4" + +"@babel/plugin-syntax-async-generators@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.2.0.tgz#69e1f0db34c6f5a0cf7e2b3323bf159a76c8cb7f" + integrity sha512-1ZrIRBv2t0GSlcwVoQ6VgSLpLgiN/FVQUzt9znxo7v2Ov4jJrs8RY8tv0wvDmFN3qIdMKWrmMMW6yZ0G19MfGg== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-syntax-json-strings@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.2.0.tgz#72bd13f6ffe1d25938129d2a186b11fd62951470" + integrity sha512-5UGYnMSLRE1dqqZwug+1LISpA403HzlSfsg6P9VXU6TBjcSHeNlw4DxDx7LgpF+iKZoOG/+uzqoRHTdcUpiZNg== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-syntax-object-rest-spread@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.2.0.tgz#3b7a3e733510c57e820b9142a6579ac8b0dfad2e" + integrity sha512-t0JKGgqk2We+9may3t0xDdmneaXmyxq0xieYcKHxIsrJO64n1OiMWNUtc5gQK1PA0NpdCRrtZp4z+IUaKugrSA== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-syntax-optional-catch-binding@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.2.0.tgz#a94013d6eda8908dfe6a477e7f9eda85656ecf5c" + integrity sha512-bDe4xKNhb0LI7IvZHiA13kff0KEfaGX/Hv4lMA9+7TEc63hMNvfKo6ZFpXhKuEp+II/q35Gc4NoMeDZyaUbj9w== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-arrow-functions@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.2.0.tgz#9aeafbe4d6ffc6563bf8f8372091628f00779550" + integrity sha512-ER77Cax1+8/8jCB9fo4Ud161OZzWN5qawi4GusDuRLcDbDG+bIGYY20zb2dfAFdTRGzrfq2xZPvF0R64EHnimg== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-async-to-generator@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.4.4.tgz#a3f1d01f2f21cadab20b33a82133116f14fb5894" + integrity sha512-YiqW2Li8TXmzgbXw+STsSqPBPFnGviiaSp6CYOq55X8GQ2SGVLrXB6pNid8HkqkZAzOH6knbai3snhP7v0fNwA== + dependencies: + "@babel/helper-module-imports" "^7.0.0" + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-remap-async-to-generator" "^7.1.0" + +"@babel/plugin-transform-block-scoped-functions@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.2.0.tgz#5d3cc11e8d5ddd752aa64c9148d0db6cb79fd190" + integrity sha512-ntQPR6q1/NKuphly49+QiQiTN0O63uOwjdD6dhIjSWBI5xlrbUFh720TIpzBhpnrLfv2tNH/BXvLIab1+BAI0w== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-block-scoping@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.4.4.tgz#c13279fabf6b916661531841a23c4b7dae29646d" + integrity sha512-jkTUyWZcTrwxu5DD4rWz6rDB5Cjdmgz6z7M7RLXOJyCUkFBawssDGcGh8M/0FTSB87avyJI1HsTwUXp9nKA1PA== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + lodash "^4.17.11" + +"@babel/plugin-transform-classes@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.4.4.tgz#0ce4094cdafd709721076d3b9c38ad31ca715eb6" + integrity sha512-/e44eFLImEGIpL9qPxSRat13I5QNRgBLu2hOQJCF7VLy/otSM/sypV1+XaIw5+502RX/+6YaSAPmldk+nhHDPw== + dependencies: + "@babel/helper-annotate-as-pure" "^7.0.0" + "@babel/helper-define-map" "^7.4.4" + "@babel/helper-function-name" "^7.1.0" + "@babel/helper-optimise-call-expression" "^7.0.0" + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-replace-supers" "^7.4.4" + "@babel/helper-split-export-declaration" "^7.4.4" + globals "^11.1.0" + +"@babel/plugin-transform-computed-properties@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.2.0.tgz#83a7df6a658865b1c8f641d510c6f3af220216da" + integrity sha512-kP/drqTxY6Xt3NNpKiMomfgkNn4o7+vKxK2DDKcBG9sHj51vHqMBGy8wbDS/J4lMxnqs153/T3+DmCEAkC5cpA== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-destructuring@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.4.4.tgz#9d964717829cc9e4b601fc82a26a71a4d8faf20f" + integrity sha512-/aOx+nW0w8eHiEHm+BTERB2oJn5D127iye/SUQl7NjHy0lf+j7h4MKMMSOwdazGq9OxgiNADncE+SRJkCxjZpQ== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-dotall-regex@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.4.4.tgz#361a148bc951444312c69446d76ed1ea8e4450c3" + integrity sha512-P05YEhRc2h53lZDjRPk/OektxCVevFzZs2Gfjd545Wde3k+yFDbXORgl2e0xpbq8mLcKJ7Idss4fAg0zORN/zg== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-regex" "^7.4.4" + regexpu-core "^4.5.4" + +"@babel/plugin-transform-duplicate-keys@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.2.0.tgz#d952c4930f312a4dbfff18f0b2914e60c35530b3" + integrity sha512-q+yuxW4DsTjNceUiTzK0L+AfQ0zD9rWaTLiUqHA8p0gxx7lu1EylenfzjeIWNkPy6e/0VG/Wjw9uf9LueQwLOw== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-exponentiation-operator@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.2.0.tgz#a63868289e5b4007f7054d46491af51435766008" + integrity sha512-umh4hR6N7mu4Elq9GG8TOu9M0bakvlsREEC+ialrQN6ABS4oDQ69qJv1VtR3uxlKMCQMCvzk7vr17RHKcjx68A== + dependencies: + "@babel/helper-builder-binary-assignment-operator-visitor" "^7.1.0" + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-for-of@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.4.4.tgz#0267fc735e24c808ba173866c6c4d1440fc3c556" + integrity sha512-9T/5Dlr14Z9TIEXLXkt8T1DU7F24cbhwhMNUziN3hB1AXoZcdzPcTiKGRn/6iOymDqtTKWnr/BtRKN9JwbKtdQ== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-function-name@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.4.4.tgz#e1436116abb0610c2259094848754ac5230922ad" + integrity sha512-iU9pv7U+2jC9ANQkKeNF6DrPy4GBa4NWQtl6dHB4Pb3izX2JOEvDTFarlNsBj/63ZEzNNIAMs3Qw4fNCcSOXJA== + dependencies: + "@babel/helper-function-name" "^7.1.0" + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-literals@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-literals/-/plugin-transform-literals-7.2.0.tgz#690353e81f9267dad4fd8cfd77eafa86aba53ea1" + integrity sha512-2ThDhm4lI4oV7fVQ6pNNK+sx+c/GM5/SaML0w/r4ZB7sAneD/piDJtwdKlNckXeyGK7wlwg2E2w33C/Hh+VFCg== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-member-expression-literals@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.2.0.tgz#fa10aa5c58a2cb6afcf2c9ffa8cb4d8b3d489a2d" + integrity sha512-HiU3zKkSU6scTidmnFJ0bMX8hz5ixC93b4MHMiYebmk2lUVNGOboPsqQvx5LzooihijUoLR/v7Nc1rbBtnc7FA== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-modules-amd@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.2.0.tgz#82a9bce45b95441f617a24011dc89d12da7f4ee6" + integrity sha512-mK2A8ucqz1qhrdqjS9VMIDfIvvT2thrEsIQzbaTdc5QFzhDjQv2CkJJ5f6BXIkgbmaoax3zBr2RyvV/8zeoUZw== + dependencies: + "@babel/helper-module-transforms" "^7.1.0" + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-modules-commonjs@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.4.4.tgz#0bef4713d30f1d78c2e59b3d6db40e60192cac1e" + integrity sha512-4sfBOJt58sEo9a2BQXnZq+Q3ZTSAUXyK3E30o36BOGnJ+tvJ6YSxF0PG6kERvbeISgProodWuI9UVG3/FMY6iw== + dependencies: + "@babel/helper-module-transforms" "^7.4.4" + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-simple-access" "^7.1.0" + +"@babel/plugin-transform-modules-systemjs@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.4.4.tgz#dc83c5665b07d6c2a7b224c00ac63659ea36a405" + integrity sha512-MSiModfILQc3/oqnG7NrP1jHaSPryO6tA2kOMmAQApz5dayPxWiHqmq4sWH2xF5LcQK56LlbKByCd8Aah/OIkQ== + dependencies: + "@babel/helper-hoist-variables" "^7.4.4" + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-modules-umd@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.2.0.tgz#7678ce75169f0877b8eb2235538c074268dd01ae" + integrity sha512-BV3bw6MyUH1iIsGhXlOK6sXhmSarZjtJ/vMiD9dNmpY8QXFFQTj+6v92pcfy1iqa8DeAfJFwoxcrS/TUZda6sw== + dependencies: + "@babel/helper-module-transforms" "^7.1.0" + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-named-capturing-groups-regex@^7.4.5": + version "7.4.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.4.5.tgz#9d269fd28a370258199b4294736813a60bbdd106" + integrity sha512-z7+2IsWafTBbjNsOxU/Iv5CvTJlr5w4+HGu1HovKYTtgJ362f7kBcQglkfmlspKKZ3bgrbSGvLfNx++ZJgCWsg== + dependencies: + regexp-tree "^0.1.6" + +"@babel/plugin-transform-new-target@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.4.4.tgz#18d120438b0cc9ee95a47f2c72bc9768fbed60a5" + integrity sha512-r1z3T2DNGQwwe2vPGZMBNjioT2scgWzK9BCnDEh+46z8EEwXBq24uRzd65I7pjtugzPSj921aM15RpESgzsSuA== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-object-super@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.2.0.tgz#b35d4c10f56bab5d650047dad0f1d8e8814b6598" + integrity sha512-VMyhPYZISFZAqAPVkiYb7dUe2AsVi2/wCT5+wZdsNO31FojQJa9ns40hzZ6U9f50Jlq4w6qwzdBB2uwqZ00ebg== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-replace-supers" "^7.1.0" + +"@babel/plugin-transform-parameters@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.4.4.tgz#7556cf03f318bd2719fe4c922d2d808be5571e16" + integrity sha512-oMh5DUO1V63nZcu/ZVLQFqiihBGo4OpxJxR1otF50GMeCLiRx5nUdtokd+u9SuVJrvvuIh9OosRFPP4pIPnwmw== + dependencies: + "@babel/helper-call-delegate" "^7.4.4" + "@babel/helper-get-function-arity" "^7.0.0" + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-property-literals@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.2.0.tgz#03e33f653f5b25c4eb572c98b9485055b389e905" + integrity sha512-9q7Dbk4RhgcLp8ebduOpCbtjh7C0itoLYHXd9ueASKAG/is5PQtMR5VJGka9NKqGhYEGn5ITahd4h9QeBMylWQ== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-regenerator@^7.4.5": + version "7.4.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.4.5.tgz#629dc82512c55cee01341fb27bdfcb210354680f" + integrity sha512-gBKRh5qAaCWntnd09S8QC7r3auLCqq5DI6O0DlfoyDjslSBVqBibrMdsqO+Uhmx3+BlOmE/Kw1HFxmGbv0N9dA== + dependencies: + regenerator-transform "^0.14.0" + +"@babel/plugin-transform-reserved-words@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.2.0.tgz#4792af87c998a49367597d07fedf02636d2e1634" + integrity sha512-fz43fqW8E1tAB3DKF19/vxbpib1fuyCwSPE418ge5ZxILnBhWyhtPgz8eh1RCGGJlwvksHkyxMxh0eenFi+kFw== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-shorthand-properties@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.2.0.tgz#6333aee2f8d6ee7e28615457298934a3b46198f0" + integrity sha512-QP4eUM83ha9zmYtpbnyjTLAGKQritA5XW/iG9cjtuOI8s1RuL/3V6a3DeSHfKutJQ+ayUfeZJPcnCYEQzaPQqg== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-spread@^7.2.0": + version "7.2.2" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-spread/-/plugin-transform-spread-7.2.2.tgz#3103a9abe22f742b6d406ecd3cd49b774919b406" + integrity sha512-KWfky/58vubwtS0hLqEnrWJjsMGaOeSBn90Ezn5Jeg9Z8KKHmELbP1yGylMlm5N6TPKeY9A2+UaSYLdxahg01w== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-sticky-regex@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.2.0.tgz#a1e454b5995560a9c1e0d537dfc15061fd2687e1" + integrity sha512-KKYCoGaRAf+ckH8gEL3JHUaFVyNHKe3ASNsZ+AlktgHevvxGigoIttrEJb8iKN03Q7Eazlv1s6cx2B2cQ3Jabw== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-regex" "^7.0.0" + +"@babel/plugin-transform-template-literals@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.4.4.tgz#9d28fea7bbce637fb7612a0750989d8321d4bcb0" + integrity sha512-mQrEC4TWkhLN0z8ygIvEL9ZEToPhG5K7KDW3pzGqOfIGZ28Jb0POUkeWcoz8HnHvhFy6dwAT1j8OzqN8s804+g== + dependencies: + "@babel/helper-annotate-as-pure" "^7.0.0" + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-typeof-symbol@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.2.0.tgz#117d2bcec2fbf64b4b59d1f9819894682d29f2b2" + integrity sha512-2LNhETWYxiYysBtrBTqL8+La0jIoQQnIScUJc74OYvUGRmkskNY4EzLCnjHBzdmb38wqtTaixpo1NctEcvMDZw== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + +"@babel/plugin-transform-unicode-regex@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.4.4.tgz#ab4634bb4f14d36728bf5978322b35587787970f" + integrity sha512-il+/XdNw01i93+M9J9u4T7/e/Ue/vWfNZE4IRUQjplu2Mqb/AFTDimkw2tdEdSH50wuQXZAbXSql0UphQke+vA== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-regex" "^7.4.4" + regexpu-core "^4.5.4" + +"@babel/preset-env@^7.4.5": + version "7.4.5" + resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.4.5.tgz#2fad7f62983d5af563b5f3139242755884998a58" + integrity sha512-f2yNVXM+FsR5V8UwcFeIHzHWgnhXg3NpRmy0ADvALpnhB0SLbCvrCRr4BLOUYbQNLS+Z0Yer46x9dJXpXewI7w== + dependencies: + "@babel/helper-module-imports" "^7.0.0" + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/plugin-proposal-async-generator-functions" "^7.2.0" + "@babel/plugin-proposal-json-strings" "^7.2.0" + "@babel/plugin-proposal-object-rest-spread" "^7.4.4" + "@babel/plugin-proposal-optional-catch-binding" "^7.2.0" + "@babel/plugin-proposal-unicode-property-regex" "^7.4.4" + "@babel/plugin-syntax-async-generators" "^7.2.0" + "@babel/plugin-syntax-json-strings" "^7.2.0" + "@babel/plugin-syntax-object-rest-spread" "^7.2.0" + "@babel/plugin-syntax-optional-catch-binding" "^7.2.0" + "@babel/plugin-transform-arrow-functions" "^7.2.0" + "@babel/plugin-transform-async-to-generator" "^7.4.4" + "@babel/plugin-transform-block-scoped-functions" "^7.2.0" + "@babel/plugin-transform-block-scoping" "^7.4.4" + "@babel/plugin-transform-classes" "^7.4.4" + "@babel/plugin-transform-computed-properties" "^7.2.0" + "@babel/plugin-transform-destructuring" "^7.4.4" + "@babel/plugin-transform-dotall-regex" "^7.4.4" + "@babel/plugin-transform-duplicate-keys" "^7.2.0" + "@babel/plugin-transform-exponentiation-operator" "^7.2.0" + "@babel/plugin-transform-for-of" "^7.4.4" + "@babel/plugin-transform-function-name" "^7.4.4" + "@babel/plugin-transform-literals" "^7.2.0" + "@babel/plugin-transform-member-expression-literals" "^7.2.0" + "@babel/plugin-transform-modules-amd" "^7.2.0" + "@babel/plugin-transform-modules-commonjs" "^7.4.4" + "@babel/plugin-transform-modules-systemjs" "^7.4.4" + "@babel/plugin-transform-modules-umd" "^7.2.0" + "@babel/plugin-transform-named-capturing-groups-regex" "^7.4.5" + "@babel/plugin-transform-new-target" "^7.4.4" + "@babel/plugin-transform-object-super" "^7.2.0" + "@babel/plugin-transform-parameters" "^7.4.4" + "@babel/plugin-transform-property-literals" "^7.2.0" + "@babel/plugin-transform-regenerator" "^7.4.5" + "@babel/plugin-transform-reserved-words" "^7.2.0" + "@babel/plugin-transform-shorthand-properties" "^7.2.0" + "@babel/plugin-transform-spread" "^7.2.0" + "@babel/plugin-transform-sticky-regex" "^7.2.0" + "@babel/plugin-transform-template-literals" "^7.4.4" + "@babel/plugin-transform-typeof-symbol" "^7.2.0" + "@babel/plugin-transform-unicode-regex" "^7.4.4" + "@babel/types" "^7.4.4" + browserslist "^4.6.0" + core-js-compat "^3.1.1" + invariant "^2.2.2" + js-levenshtein "^1.1.3" + semver "^5.5.0" + +"@babel/template@^7.1.0", "@babel/template@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.4.4.tgz#f4b88d1225689a08f5bc3a17483545be9e4ed237" + integrity sha512-CiGzLN9KgAvgZsnivND7rkA+AeJ9JB0ciPOD4U59GKbQP2iQl+olF1l76kJOupqidozfZ32ghwBEJDhnk9MEcw== + dependencies: + "@babel/code-frame" "^7.0.0" + "@babel/parser" "^7.4.4" + "@babel/types" "^7.4.4" + +"@babel/traverse@^7.0.0", "@babel/traverse@^7.1.0", "@babel/traverse@^7.4.4", "@babel/traverse@^7.4.5": + version "7.4.5" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.4.5.tgz#4e92d1728fd2f1897dafdd321efbff92156c3216" + integrity sha512-Vc+qjynwkjRmIFGxy0KYoPj4FdVDxLej89kMHFsWScq999uX+pwcX4v9mWRjW0KcAYTPAuVQl2LKP1wEVLsp+A== + dependencies: + "@babel/code-frame" "^7.0.0" + "@babel/generator" "^7.4.4" + "@babel/helper-function-name" "^7.1.0" + "@babel/helper-split-export-declaration" "^7.4.4" + "@babel/parser" "^7.4.5" + "@babel/types" "^7.4.4" + debug "^4.1.0" + globals "^11.1.0" + lodash "^4.17.11" + +"@babel/types@^7.0.0", "@babel/types@^7.2.0", "@babel/types@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.4.4.tgz#8db9e9a629bb7c29370009b4b779ed93fe57d5f0" + integrity sha512-dOllgYdnEFOebhkKCjzSVFqw/PmmB8pH6RGOWkY4GsboQNd47b1fBThBSwlHAq9alF9vc1M3+6oqR47R50L0tQ== + dependencies: + esutils "^2.0.2" + lodash "^4.17.11" + to-fast-properties "^2.0.0" + "@sinonjs/commons@^1.0.2": version "1.3.0" resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-1.3.0.tgz#50a2754016b6f30a994ceda6d9a0a8c36adda849" @@ -38,10 +654,27 @@ abbrev@1.0.x: resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.0.9.tgz#91b4792588a7738c25f35dd6f63752a2f8776135" integrity sha1-kbR5JYinc4wl813W9jdSovh3YTU= -acorn-to-esprima@^2.0.4: - version "2.0.8" - resolved "https://registry.yarnpkg.com/acorn-to-esprima/-/acorn-to-esprima-2.0.8.tgz#003f0c642eb92132f417d3708f14ada82adf2eb1" - integrity sha1-AD8MZC65ITL0F9NwjxStqCrfLrE= +acorn-jsx@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-3.0.1.tgz#afdf9488fb1ecefc8348f6fb22f464e32a58b36b" + integrity sha1-r9+UiPsezvyDSPb7IvRk4ypYs2s= + dependencies: + acorn "^3.0.4" + +acorn@^3.0.4: + version "3.3.0" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-3.3.0.tgz#45e37fb39e8da3f25baee3ff5369e2bb5f22017a" + integrity sha1-ReN/s56No/JbruP/U2niu18iAXo= + +acorn@^5.5.0: + version "5.7.3" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.3.tgz#67aa231bf8812974b85235a96771eb6bd07ea279" + integrity sha512-T/zvzYRfbVojPWahDsE5evJdHb3oJoQfFbsrKM7w5Zcs++Tr257tia3BmMP8XYVjp1S9RZXQMh7gao96BlqZOw== + +ajv-keywords@^2.1.0: + version "2.1.1" + resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-2.1.1.tgz#617997fc5f60576894c435f940d819e135b80762" + integrity sha1-YXmX/F9gV2iUxDX5QNgZ4TW4B2I= ajv@^5.1.0: version "5.2.3" @@ -53,31 +686,100 @@ ajv@^5.1.0: json-schema-traverse "^0.3.0" json-stable-stringify "^1.0.1" +ajv@^5.2.3, ajv@^5.3.0: + version "5.5.2" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.2.tgz#73b5eeca3fab653e3d3f9422b341ad42205dc965" + integrity sha1-c7Xuyj+rZT49P5Qis0GtQiBdyWU= + dependencies: + co "^4.6.0" + fast-deep-equal "^1.0.0" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.3.0" + amdefine@>=0.0.4: version "1.0.1" resolved "https://registry.yarnpkg.com/amdefine/-/amdefine-1.0.1.tgz#4a5282ac164729e93619bcfd3ad151f817ce91f5" integrity sha1-SlKCrBZHKek2Gbz9OtFR+BfOkfU= -ansi-regex@^1.0.0, ansi-regex@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-1.1.1.tgz#41c847194646375e6a1a5d10c3ca054ef9fc980d" - integrity sha1-QchHGUZGN15qGl0Qw8oFTvn8mA0= +ansi-colors@^1.0.1: + version "1.1.0" + resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-1.1.0.tgz#6374b4dd5d4718ff3ce27a671a3b1cad077132a9" + integrity sha512-SFKX67auSNoVR38N3L+nvsPjOE0bybKTYbkf5tRvushrAPQ9V75huw0ZxBkKVeRU9kqH3d6HA4xTckbwZ4ixmA== + dependencies: + ansi-wrap "^0.1.0" + +ansi-escapes@^3.0.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.2.0.tgz#8780b98ff9dbf5638152d1f1fe5c1d7b4442976b" + integrity sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ== + +ansi-gray@^0.1.1: + version "0.1.1" + resolved "https://registry.yarnpkg.com/ansi-gray/-/ansi-gray-0.1.1.tgz#2962cf54ec9792c48510a3deb524436861ef7251" + integrity sha1-KWLPVOyXksSFEKPetSRDaGHvclE= + dependencies: + ansi-wrap "0.1.0" ansi-regex@^2.0.0: version "2.1.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" integrity sha1-w7M6te42DYbg5ijwRorn7yfWVN8= +ansi-regex@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.0.tgz#ed0317c322064f79466c02966bddb605ab37d998" + integrity sha1-7QMXwyIGT3lGbAKWa922Bas32Zg= + ansi-styles@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" integrity sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4= +ansi-styles@^3.2.1: + version "3.2.1" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" + integrity sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA== + dependencies: + color-convert "^1.9.0" + +ansi-wrap@0.1.0, ansi-wrap@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/ansi-wrap/-/ansi-wrap-0.1.0.tgz#a82250ddb0015e9a27ca82e82ea603bbfa45efaf" + integrity sha1-qCJQ3bABXponyoLoLqYDu/pF768= + +anymatch@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-2.0.0.tgz#bcb24b4f37934d9aa7ac17b4adaf89e7c76ef2eb" + integrity sha512-5teOsQWABXHHBFP9y3skS5P3d/WfWXpv3FUpy+LorMrNYaT9pI4oLMQX7jzQ2KklNpGpWHzdCXTDT2Y3XGlZBw== + dependencies: + micromatch "^3.1.4" + normalize-path "^2.1.1" + +append-buffer@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/append-buffer/-/append-buffer-1.0.2.tgz#d8220cf466081525efea50614f3de6514dfa58f1" + integrity sha1-2CIM9GYIFSXv6lBhTz3mUU36WPE= + dependencies: + buffer-equal "^1.0.0" + +aproba@^1.0.3: + version "1.2.0" + resolved "https://registry.yarnpkg.com/aproba/-/aproba-1.2.0.tgz#6802e6264efd18c790a1b0d517f0f2627bf2c94a" + integrity sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw== + archy@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/archy/-/archy-1.0.0.tgz#f9c8c13757cc1dd7bc379ac77b2c62a5c2868c40" integrity sha1-+cjBN1fMHde8N5rHeyxipcKGjEA= +are-we-there-yet@~1.1.2: + version "1.1.5" + resolved "https://registry.yarnpkg.com/are-we-there-yet/-/are-we-there-yet-1.1.5.tgz#4b35c2944f062a8bfcda66410760350fe9ddfc21" + integrity sha512-5hYdAkZlcG8tOLujVDTgCT+uPX0VnpAH28gWsLfzpXYm7wP6mp5Q/gYyR7YQ0cKVJcXJnl3j2kpBan13PtQf6w== + dependencies: + delegates "^1.0.0" + readable-stream "^2.0.6" + argparse@^1.0.7: version "1.0.10" resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.10.tgz#bcd6791ea5ae09725e17e5ad988134cd40b3d911" @@ -90,11 +792,25 @@ arr-diff@^4.0.0: resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-4.0.0.tgz#d6461074febfec71e7e15235761a329a5dc7c520" integrity sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA= -arr-flatten@^1.1.0: +arr-filter@^1.1.1: + version "1.1.2" + resolved "https://registry.yarnpkg.com/arr-filter/-/arr-filter-1.1.2.tgz#43fdddd091e8ef11aa4c45d9cdc18e2dff1711ee" + integrity sha1-Q/3d0JHo7xGqTEXZzcGOLf8XEe4= + dependencies: + make-iterator "^1.0.0" + +arr-flatten@^1.0.1, arr-flatten@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/arr-flatten/-/arr-flatten-1.1.0.tgz#36048bbff4e7b47e136644316c99669ea5ae91f1" integrity sha512-L3hKV5R/p5o81R7O02IGnwpDmkp6E982XhtbuwSe3O4qOtMMMtodicASA1Cny2U+aCXcNpml+m4dPsvsJ3jatg== +arr-map@^2.0.0, arr-map@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/arr-map/-/arr-map-2.0.2.tgz#3a77345ffc1cf35e2a91825601f9e58f2e24cac4" + integrity sha1-Onc0X/wc814qkYJWAfnljy4kysQ= + dependencies: + make-iterator "^1.0.0" + arr-union@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/arr-union/-/arr-union-3.1.0.tgz#e39b09aea9def866a8f206e288af63919bae39c4" @@ -105,7 +821,7 @@ array-differ@^1.0.0: resolved "https://registry.yarnpkg.com/array-differ/-/array-differ-1.0.0.tgz#eff52e3758249d33be402b8bb8e564bb2b5d4031" integrity sha1-7/UuN1gknTO+QCuLuOVkuytdQDE= -array-each@^1.0.1: +array-each@^1.0.0, array-each@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/array-each/-/array-each-1.0.1.tgz#a794af0c05ab1752846ee753a1f211a05ba0c44f" integrity sha1-p5SvDAWrF1KEbudTofIRoFugxE8= @@ -115,11 +831,35 @@ array-from@^2.1.1: resolved "https://registry.yarnpkg.com/array-from/-/array-from-2.1.1.tgz#cfe9d8c26628b9dc5aecc62a9f5d8f1f352c1195" integrity sha1-z+nYwmYoudxa7MYqn12PHzUsEZU= +array-initial@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/array-initial/-/array-initial-1.1.0.tgz#2fa74b26739371c3947bd7a7adc73be334b3d795" + integrity sha1-L6dLJnOTccOUe9enrcc74zSz15U= + dependencies: + array-slice "^1.0.0" + is-number "^4.0.0" + +array-last@^1.1.1: + version "1.3.0" + resolved "https://registry.yarnpkg.com/array-last/-/array-last-1.3.0.tgz#7aa77073fec565ddab2493f5f88185f404a9d336" + integrity sha512-eOCut5rXlI6aCOS7Z7kCplKRKyiFQ6dHFBem4PwlwKeNFk2/XxTrhRh5T9PyaEWGy/NHTZWbY+nsZlNFJu9rYg== + dependencies: + is-number "^4.0.0" + array-slice@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/array-slice/-/array-slice-1.1.0.tgz#e368ea15f89bc7069f7ffb89aec3a6c7d4ac22d4" integrity sha512-B1qMD3RBP7O8o0H2KbrXDyB0IccejMF15+87Lvlor12ONPRHP6gTjXMNkt/d3ZuOGbAe66hFmaCfECI24Ufp6w== +array-sort@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/array-sort/-/array-sort-1.0.0.tgz#e4c05356453f56f53512a7d1d6123f2c54c0a88a" + integrity sha512-ihLeJkonmdiAsD7vpgN3CRcx2J2S0TiYW+IS/5zHBI7mKUq3ySvBdzzBfD236ubDBQFiiyG3SWCPc+msQ9KoYg== + dependencies: + default-compare "^1.0.0" + get-value "^2.0.6" + kind-of "^5.0.2" + array-uniq@^1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/array-uniq/-/array-uniq-1.0.3.tgz#af6ac877a25cc7f74e058894753858dfdb24fdb6" @@ -152,6 +892,28 @@ assign-symbols@^1.0.0: resolved "https://registry.yarnpkg.com/assign-symbols/-/assign-symbols-1.0.0.tgz#59667f41fadd4f20ccbc2bb96b8d4f7f78ec0367" integrity sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c= +async-done@^1.2.0, async-done@^1.2.2: + version "1.3.2" + resolved "https://registry.yarnpkg.com/async-done/-/async-done-1.3.2.tgz#5e15aa729962a4b07414f528a88cdf18e0b290a2" + integrity sha512-uYkTP8dw2og1tu1nmza1n1CMW0qb8gWWlwqMmLb7MhBVs4BXrFziT6HXUd+/RlRA/i4H9AkofYloUbs1fwMqlw== + dependencies: + end-of-stream "^1.1.0" + once "^1.3.2" + process-nextick-args "^2.0.0" + stream-exhaust "^1.0.1" + +async-each@^1.0.1: + version "1.0.3" + resolved "https://registry.yarnpkg.com/async-each/-/async-each-1.0.3.tgz#b727dbf87d7651602f06f4d4ac387f47d91b0cbf" + integrity sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ== + +async-settle@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/async-settle/-/async-settle-1.0.0.tgz#1d0a914bb02575bec8a8f3a74e5080f72b2c0c6b" + integrity sha1-HQqRS7Aldb7IqPOnTlCA9yssDGs= + dependencies: + async-done "^1.2.2" + async@1.x: version "1.5.2" resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a" @@ -177,7 +939,7 @@ aws4@^1.6.0: resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.6.0.tgz#83ef5ca860b2b32e4a0deedee8c771b9db57471e" integrity sha1-g+9cqGCysy5KDe7e6MdxudtXRx4= -babel-code-frame@^6.26.0: +babel-code-frame@^6.22.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.26.0.tgz#63fd43f7dc1e3bb7ce35947db8fe369a3f58c74b" integrity sha1-Y/1D99weO7fONZR9uP42mj9Yx0s= @@ -186,652 +948,32 @@ babel-code-frame@^6.26.0: esutils "^2.0.2" js-tokens "^3.0.2" -babel-core@^6.0.2, babel-core@^6.26.0, babel-core@^6.7.4: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-core/-/babel-core-6.26.0.tgz#af32f78b31a6fcef119c87b0fd8d9753f03a0bb8" - integrity sha1-rzL3izGm/O8RnIew/Y2XU/A6C7g= - dependencies: - babel-code-frame "^6.26.0" - babel-generator "^6.26.0" - babel-helpers "^6.24.1" - babel-messages "^6.23.0" - babel-register "^6.26.0" - babel-runtime "^6.26.0" - babel-template "^6.26.0" - babel-traverse "^6.26.0" - babel-types "^6.26.0" - babylon "^6.18.0" - convert-source-map "^1.5.0" - debug "^2.6.8" - json5 "^0.5.1" - lodash "^4.17.4" - minimatch "^3.0.4" - path-is-absolute "^1.0.1" - private "^0.1.7" - slash "^1.0.0" - source-map "^0.5.6" - -babel-eslint@^5.0.0: - version "5.0.4" - resolved "https://registry.yarnpkg.com/babel-eslint/-/babel-eslint-5.0.4.tgz#a6ba51ae582a1d4e25adfddbc2a61f8d5a9040b9" - integrity sha1-prpRrlgqHU4lrf3bwqYfjVqQQLk= - dependencies: - acorn-to-esprima "^2.0.4" - babel-traverse "^6.0.20" - babel-types "^6.0.19" - babylon "^6.0.18" - lodash.assign "^3.2.0" - lodash.pick "^3.1.0" - -babel-generator@^6.26.0: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-generator/-/babel-generator-6.26.0.tgz#ac1ae20070b79f6e3ca1d3269613053774f20dc5" - integrity sha1-rBriAHC3n248odMmlhMFN3TyDcU= - dependencies: - babel-messages "^6.23.0" - babel-runtime "^6.26.0" - babel-types "^6.26.0" - detect-indent "^4.0.0" - jsesc "^1.3.0" - lodash "^4.17.4" - source-map "^0.5.6" - trim-right "^1.0.1" - -babel-helper-bindify-decorators@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-helper-bindify-decorators/-/babel-helper-bindify-decorators-6.24.1.tgz#14c19e5f142d7b47f19a52431e52b1ccbc40a330" - integrity sha1-FMGeXxQte0fxmlJDHlKxzLxAozA= - dependencies: - babel-runtime "^6.22.0" - babel-traverse "^6.24.1" - babel-types "^6.24.1" - -babel-helper-builder-binary-assignment-operator-visitor@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-helper-builder-binary-assignment-operator-visitor/-/babel-helper-builder-binary-assignment-operator-visitor-6.24.1.tgz#cce4517ada356f4220bcae8a02c2b346f9a56664" - integrity sha1-zORReto1b0IgvK6KAsKzRvmlZmQ= - dependencies: - babel-helper-explode-assignable-expression "^6.24.1" - babel-runtime "^6.22.0" - babel-types "^6.24.1" - -babel-helper-call-delegate@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-helper-call-delegate/-/babel-helper-call-delegate-6.24.1.tgz#ece6aacddc76e41c3461f88bfc575bd0daa2df8d" - integrity sha1-7Oaqzdx25Bw0YfiL/Fdb0Nqi340= - dependencies: - babel-helper-hoist-variables "^6.24.1" - babel-runtime "^6.22.0" - babel-traverse "^6.24.1" - babel-types "^6.24.1" - -babel-helper-define-map@^6.24.1: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-helper-define-map/-/babel-helper-define-map-6.26.0.tgz#a5f56dab41a25f97ecb498c7ebaca9819f95be5f" - integrity sha1-pfVtq0GiX5fstJjH66ypgZ+Vvl8= - dependencies: - babel-helper-function-name "^6.24.1" - babel-runtime "^6.26.0" - babel-types "^6.26.0" - lodash "^4.17.4" - -babel-helper-explode-assignable-expression@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-helper-explode-assignable-expression/-/babel-helper-explode-assignable-expression-6.24.1.tgz#f25b82cf7dc10433c55f70592d5746400ac22caa" - integrity sha1-8luCz33BBDPFX3BZLVdGQArCLKo= - dependencies: - babel-runtime "^6.22.0" - babel-traverse "^6.24.1" - babel-types "^6.24.1" - -babel-helper-explode-class@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-helper-explode-class/-/babel-helper-explode-class-6.24.1.tgz#7dc2a3910dee007056e1e31d640ced3d54eaa9eb" - integrity sha1-fcKjkQ3uAHBW4eMdZAztPVTqqes= - dependencies: - babel-helper-bindify-decorators "^6.24.1" - babel-runtime "^6.22.0" - babel-traverse "^6.24.1" - babel-types "^6.24.1" - -babel-helper-function-name@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-helper-function-name/-/babel-helper-function-name-6.24.1.tgz#d3475b8c03ed98242a25b48351ab18399d3580a9" - integrity sha1-00dbjAPtmCQqJbSDUasYOZ01gKk= - dependencies: - babel-helper-get-function-arity "^6.24.1" - babel-runtime "^6.22.0" - babel-template "^6.24.1" - babel-traverse "^6.24.1" - babel-types "^6.24.1" - -babel-helper-get-function-arity@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-helper-get-function-arity/-/babel-helper-get-function-arity-6.24.1.tgz#8f7782aa93407c41d3aa50908f89b031b1b6853d" - integrity sha1-j3eCqpNAfEHTqlCQj4mwMbG2hT0= - dependencies: - babel-runtime "^6.22.0" - babel-types "^6.24.1" - -babel-helper-hoist-variables@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-helper-hoist-variables/-/babel-helper-hoist-variables-6.24.1.tgz#1ecb27689c9d25513eadbc9914a73f5408be7a76" - integrity sha1-HssnaJydJVE+rbyZFKc/VAi+enY= - dependencies: - babel-runtime "^6.22.0" - babel-types "^6.24.1" - -babel-helper-optimise-call-expression@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-helper-optimise-call-expression/-/babel-helper-optimise-call-expression-6.24.1.tgz#f7a13427ba9f73f8f4fa993c54a97882d1244257" - integrity sha1-96E0J7qfc/j0+pk8VKl4gtEkQlc= - dependencies: - babel-runtime "^6.22.0" - babel-types "^6.24.1" - -babel-helper-regex@^6.24.1: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-helper-regex/-/babel-helper-regex-6.26.0.tgz#325c59f902f82f24b74faceed0363954f6495e72" - integrity sha1-MlxZ+QL4LyS3T6zu0DY5VPZJXnI= - dependencies: - babel-runtime "^6.26.0" - babel-types "^6.26.0" - lodash "^4.17.4" - -babel-helper-remap-async-to-generator@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-helper-remap-async-to-generator/-/babel-helper-remap-async-to-generator-6.24.1.tgz#5ec581827ad723fecdd381f1c928390676e4551b" - integrity sha1-XsWBgnrXI/7N04HxySg5BnbkVRs= - dependencies: - babel-helper-function-name "^6.24.1" - babel-runtime "^6.22.0" - babel-template "^6.24.1" - babel-traverse "^6.24.1" - babel-types "^6.24.1" - -babel-helper-replace-supers@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-helper-replace-supers/-/babel-helper-replace-supers-6.24.1.tgz#bf6dbfe43938d17369a213ca8a8bf74b6a90ab1a" - integrity sha1-v22/5Dk40XNpohPKiov3S2qQqxo= - dependencies: - babel-helper-optimise-call-expression "^6.24.1" - babel-messages "^6.23.0" - babel-runtime "^6.22.0" - babel-template "^6.24.1" - babel-traverse "^6.24.1" - babel-types "^6.24.1" - -babel-helpers@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-helpers/-/babel-helpers-6.24.1.tgz#3471de9caec388e5c850e597e58a26ddf37602b2" - integrity sha1-NHHenK7DiOXIUOWX5Yom3fN2ArI= - dependencies: - babel-runtime "^6.22.0" - babel-template "^6.24.1" - -babel-messages@^6.23.0: - version "6.23.0" - resolved "https://registry.yarnpkg.com/babel-messages/-/babel-messages-6.23.0.tgz#f3cdf4703858035b2a2951c6ec5edf6c62f2630e" - integrity sha1-8830cDhYA1sqKVHG7F7fbGLyYw4= - dependencies: - babel-runtime "^6.22.0" - -babel-plugin-check-es2015-constants@^6.22.0: - version "6.22.0" - resolved "https://registry.yarnpkg.com/babel-plugin-check-es2015-constants/-/babel-plugin-check-es2015-constants-6.22.0.tgz#35157b101426fd2ffd3da3f75c7d1e91835bbf8a" - integrity sha1-NRV7EBQm/S/9PaP3XH0ekYNbv4o= - dependencies: - babel-runtime "^6.22.0" - -babel-plugin-syntax-async-functions@^6.8.0: - version "6.13.0" - resolved "https://registry.yarnpkg.com/babel-plugin-syntax-async-functions/-/babel-plugin-syntax-async-functions-6.13.0.tgz#cad9cad1191b5ad634bf30ae0872391e0647be95" - integrity sha1-ytnK0RkbWtY0vzCuCHI5HgZHvpU= - -babel-plugin-syntax-async-generators@^6.5.0: - version "6.13.0" - resolved "https://registry.yarnpkg.com/babel-plugin-syntax-async-generators/-/babel-plugin-syntax-async-generators-6.13.0.tgz#6bc963ebb16eccbae6b92b596eb7f35c342a8b9a" - integrity sha1-a8lj67FuzLrmuStZbrfzXDQqi5o= - -babel-plugin-syntax-class-constructor-call@^6.18.0: - version "6.18.0" - resolved "https://registry.yarnpkg.com/babel-plugin-syntax-class-constructor-call/-/babel-plugin-syntax-class-constructor-call-6.18.0.tgz#9cb9d39fe43c8600bec8146456ddcbd4e1a76416" - integrity sha1-nLnTn+Q8hgC+yBRkVt3L1OGnZBY= - -babel-plugin-syntax-class-properties@^6.8.0: - version "6.13.0" - resolved "https://registry.yarnpkg.com/babel-plugin-syntax-class-properties/-/babel-plugin-syntax-class-properties-6.13.0.tgz#d7eb23b79a317f8543962c505b827c7d6cac27de" - integrity sha1-1+sjt5oxf4VDlixQW4J8fWysJ94= - -babel-plugin-syntax-decorators@^6.13.0: - version "6.13.0" - resolved "https://registry.yarnpkg.com/babel-plugin-syntax-decorators/-/babel-plugin-syntax-decorators-6.13.0.tgz#312563b4dbde3cc806cee3e416cceeaddd11ac0b" - integrity sha1-MSVjtNvePMgGzuPkFszurd0RrAs= - -babel-plugin-syntax-dynamic-import@^6.18.0: - version "6.18.0" - resolved "https://registry.yarnpkg.com/babel-plugin-syntax-dynamic-import/-/babel-plugin-syntax-dynamic-import-6.18.0.tgz#8d6a26229c83745a9982a441051572caa179b1da" - integrity sha1-jWomIpyDdFqZgqRBBRVyyqF5sdo= - -babel-plugin-syntax-exponentiation-operator@^6.8.0: - version "6.13.0" - resolved "https://registry.yarnpkg.com/babel-plugin-syntax-exponentiation-operator/-/babel-plugin-syntax-exponentiation-operator-6.13.0.tgz#9ee7e8337290da95288201a6a57f4170317830de" - integrity sha1-nufoM3KQ2pUoggGmpX9BcDF4MN4= - -babel-plugin-syntax-export-extensions@^6.8.0: - version "6.13.0" - resolved "https://registry.yarnpkg.com/babel-plugin-syntax-export-extensions/-/babel-plugin-syntax-export-extensions-6.13.0.tgz#70a1484f0f9089a4e84ad44bac353c95b9b12721" - integrity sha1-cKFITw+QiaToStRLrDU8lbmxJyE= - -babel-plugin-syntax-object-rest-spread@^6.8.0: - version "6.13.0" - resolved "https://registry.yarnpkg.com/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz#fd6536f2bce13836ffa3a5458c4903a597bb3bf5" - integrity sha1-/WU28rzhODb/o6VFjEkDpZe7O/U= - -babel-plugin-syntax-trailing-function-commas@^6.22.0: - version "6.22.0" - resolved "https://registry.yarnpkg.com/babel-plugin-syntax-trailing-function-commas/-/babel-plugin-syntax-trailing-function-commas-6.22.0.tgz#ba0360937f8d06e40180a43fe0d5616fff532cf3" - integrity sha1-ugNgk3+NBuQBgKQ/4NVhb/9TLPM= - -babel-plugin-transform-async-generator-functions@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-async-generator-functions/-/babel-plugin-transform-async-generator-functions-6.24.1.tgz#f058900145fd3e9907a6ddf28da59f215258a5db" - integrity sha1-8FiQAUX9PpkHpt3yjaWfIVJYpds= - dependencies: - babel-helper-remap-async-to-generator "^6.24.1" - babel-plugin-syntax-async-generators "^6.5.0" - babel-runtime "^6.22.0" - -babel-plugin-transform-async-to-generator@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-async-to-generator/-/babel-plugin-transform-async-to-generator-6.24.1.tgz#6536e378aff6cb1d5517ac0e40eb3e9fc8d08761" - integrity sha1-ZTbjeK/2yx1VF6wOQOs+n8jQh2E= - dependencies: - babel-helper-remap-async-to-generator "^6.24.1" - babel-plugin-syntax-async-functions "^6.8.0" - babel-runtime "^6.22.0" - -babel-plugin-transform-class-constructor-call@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-class-constructor-call/-/babel-plugin-transform-class-constructor-call-6.24.1.tgz#80dc285505ac067dcb8d6c65e2f6f11ab7765ef9" - integrity sha1-gNwoVQWsBn3LjWxl4vbxGrd2Xvk= - dependencies: - babel-plugin-syntax-class-constructor-call "^6.18.0" - babel-runtime "^6.22.0" - babel-template "^6.24.1" - -babel-plugin-transform-class-properties@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-class-properties/-/babel-plugin-transform-class-properties-6.24.1.tgz#6a79763ea61d33d36f37b611aa9def81a81b46ac" - integrity sha1-anl2PqYdM9NvN7YRqp3vgagbRqw= - dependencies: - babel-helper-function-name "^6.24.1" - babel-plugin-syntax-class-properties "^6.8.0" - babel-runtime "^6.22.0" - babel-template "^6.24.1" - -babel-plugin-transform-decorators@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-decorators/-/babel-plugin-transform-decorators-6.24.1.tgz#788013d8f8c6b5222bdf7b344390dfd77569e24d" - integrity sha1-eIAT2PjGtSIr33s0Q5Df13Vp4k0= - dependencies: - babel-helper-explode-class "^6.24.1" - babel-plugin-syntax-decorators "^6.13.0" - babel-runtime "^6.22.0" - babel-template "^6.24.1" - babel-types "^6.24.1" - -babel-plugin-transform-es2015-arrow-functions@^6.22.0: - version "6.22.0" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-arrow-functions/-/babel-plugin-transform-es2015-arrow-functions-6.22.0.tgz#452692cb711d5f79dc7f85e440ce41b9f244d221" - integrity sha1-RSaSy3EdX3ncf4XkQM5BufJE0iE= - dependencies: - babel-runtime "^6.22.0" - -babel-plugin-transform-es2015-block-scoped-functions@^6.22.0: - version "6.22.0" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-block-scoped-functions/-/babel-plugin-transform-es2015-block-scoped-functions-6.22.0.tgz#bbc51b49f964d70cb8d8e0b94e820246ce3a6141" - integrity sha1-u8UbSflk1wy42OC5ToICRs46YUE= - dependencies: - babel-runtime "^6.22.0" - -babel-plugin-transform-es2015-block-scoping@^6.24.1: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-block-scoping/-/babel-plugin-transform-es2015-block-scoping-6.26.0.tgz#d70f5299c1308d05c12f463813b0a09e73b1895f" - integrity sha1-1w9SmcEwjQXBL0Y4E7CgnnOxiV8= - dependencies: - babel-runtime "^6.26.0" - babel-template "^6.26.0" - babel-traverse "^6.26.0" - babel-types "^6.26.0" - lodash "^4.17.4" - -babel-plugin-transform-es2015-classes@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-classes/-/babel-plugin-transform-es2015-classes-6.24.1.tgz#5a4c58a50c9c9461e564b4b2a3bfabc97a2584db" - integrity sha1-WkxYpQyclGHlZLSyo7+ryXolhNs= - dependencies: - babel-helper-define-map "^6.24.1" - babel-helper-function-name "^6.24.1" - babel-helper-optimise-call-expression "^6.24.1" - babel-helper-replace-supers "^6.24.1" - babel-messages "^6.23.0" - babel-runtime "^6.22.0" - babel-template "^6.24.1" - babel-traverse "^6.24.1" - babel-types "^6.24.1" - -babel-plugin-transform-es2015-computed-properties@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-computed-properties/-/babel-plugin-transform-es2015-computed-properties-6.24.1.tgz#6fe2a8d16895d5634f4cd999b6d3480a308159b3" - integrity sha1-b+Ko0WiV1WNPTNmZttNICjCBWbM= - dependencies: - babel-runtime "^6.22.0" - babel-template "^6.24.1" - -babel-plugin-transform-es2015-destructuring@^6.22.0: - version "6.23.0" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-destructuring/-/babel-plugin-transform-es2015-destructuring-6.23.0.tgz#997bb1f1ab967f682d2b0876fe358d60e765c56d" - integrity sha1-mXux8auWf2gtKwh2/jWNYOdlxW0= - dependencies: - babel-runtime "^6.22.0" - -babel-plugin-transform-es2015-duplicate-keys@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-duplicate-keys/-/babel-plugin-transform-es2015-duplicate-keys-6.24.1.tgz#73eb3d310ca969e3ef9ec91c53741a6f1576423e" - integrity sha1-c+s9MQypaePvnskcU3QabxV2Qj4= - dependencies: - babel-runtime "^6.22.0" - babel-types "^6.24.1" - -babel-plugin-transform-es2015-for-of@^6.22.0: - version "6.23.0" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-for-of/-/babel-plugin-transform-es2015-for-of-6.23.0.tgz#f47c95b2b613df1d3ecc2fdb7573623c75248691" - integrity sha1-9HyVsrYT3x0+zC/bdXNiPHUkhpE= - dependencies: - babel-runtime "^6.22.0" - -babel-plugin-transform-es2015-function-name@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-function-name/-/babel-plugin-transform-es2015-function-name-6.24.1.tgz#834c89853bc36b1af0f3a4c5dbaa94fd8eacaa8b" - integrity sha1-g0yJhTvDaxrw86TF26qU/Y6sqos= - dependencies: - babel-helper-function-name "^6.24.1" - babel-runtime "^6.22.0" - babel-types "^6.24.1" - -babel-plugin-transform-es2015-literals@^6.22.0: - version "6.22.0" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-literals/-/babel-plugin-transform-es2015-literals-6.22.0.tgz#4f54a02d6cd66cf915280019a31d31925377ca2e" - integrity sha1-T1SgLWzWbPkVKAAZox0xklN3yi4= - dependencies: - babel-runtime "^6.22.0" - -babel-plugin-transform-es2015-modules-amd@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-modules-amd/-/babel-plugin-transform-es2015-modules-amd-6.24.1.tgz#3b3e54017239842d6d19c3011c4bd2f00a00d154" - integrity sha1-Oz5UAXI5hC1tGcMBHEvS8AoA0VQ= - dependencies: - babel-plugin-transform-es2015-modules-commonjs "^6.24.1" - babel-runtime "^6.22.0" - babel-template "^6.24.1" - -babel-plugin-transform-es2015-modules-commonjs@^6.24.1: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-modules-commonjs/-/babel-plugin-transform-es2015-modules-commonjs-6.26.0.tgz#0d8394029b7dc6abe1a97ef181e00758dd2e5d8a" - integrity sha1-DYOUApt9xqvhqX7xgeAHWN0uXYo= - dependencies: - babel-plugin-transform-strict-mode "^6.24.1" - babel-runtime "^6.26.0" - babel-template "^6.26.0" - babel-types "^6.26.0" - -babel-plugin-transform-es2015-modules-systemjs@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-modules-systemjs/-/babel-plugin-transform-es2015-modules-systemjs-6.24.1.tgz#ff89a142b9119a906195f5f106ecf305d9407d23" - integrity sha1-/4mhQrkRmpBhlfXxBuzzBdlAfSM= - dependencies: - babel-helper-hoist-variables "^6.24.1" - babel-runtime "^6.22.0" - babel-template "^6.24.1" - -babel-plugin-transform-es2015-modules-umd@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-modules-umd/-/babel-plugin-transform-es2015-modules-umd-6.24.1.tgz#ac997e6285cd18ed6176adb607d602344ad38468" - integrity sha1-rJl+YoXNGO1hdq22B9YCNErThGg= - dependencies: - babel-plugin-transform-es2015-modules-amd "^6.24.1" - babel-runtime "^6.22.0" - babel-template "^6.24.1" - -babel-plugin-transform-es2015-object-super@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-object-super/-/babel-plugin-transform-es2015-object-super-6.24.1.tgz#24cef69ae21cb83a7f8603dad021f572eb278f8d" - integrity sha1-JM72muIcuDp/hgPa0CH1cusnj40= - dependencies: - babel-helper-replace-supers "^6.24.1" - babel-runtime "^6.22.0" - -babel-plugin-transform-es2015-parameters@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-parameters/-/babel-plugin-transform-es2015-parameters-6.24.1.tgz#57ac351ab49caf14a97cd13b09f66fdf0a625f2b" - integrity sha1-V6w1GrScrxSpfNE7CfZv3wpiXys= - dependencies: - babel-helper-call-delegate "^6.24.1" - babel-helper-get-function-arity "^6.24.1" - babel-runtime "^6.22.0" - babel-template "^6.24.1" - babel-traverse "^6.24.1" - babel-types "^6.24.1" - -babel-plugin-transform-es2015-shorthand-properties@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-shorthand-properties/-/babel-plugin-transform-es2015-shorthand-properties-6.24.1.tgz#24f875d6721c87661bbd99a4622e51f14de38aa0" - integrity sha1-JPh11nIch2YbvZmkYi5R8U3jiqA= - dependencies: - babel-runtime "^6.22.0" - babel-types "^6.24.1" - -babel-plugin-transform-es2015-spread@^6.22.0: - version "6.22.0" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-spread/-/babel-plugin-transform-es2015-spread-6.22.0.tgz#d6d68a99f89aedc4536c81a542e8dd9f1746f8d1" - integrity sha1-1taKmfia7cRTbIGlQujdnxdG+NE= - dependencies: - babel-runtime "^6.22.0" - -babel-plugin-transform-es2015-sticky-regex@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-sticky-regex/-/babel-plugin-transform-es2015-sticky-regex-6.24.1.tgz#00c1cdb1aca71112cdf0cf6126c2ed6b457ccdbc" - integrity sha1-AMHNsaynERLN8M9hJsLta0V8zbw= - dependencies: - babel-helper-regex "^6.24.1" - babel-runtime "^6.22.0" - babel-types "^6.24.1" - -babel-plugin-transform-es2015-template-literals@^6.22.0: - version "6.22.0" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-template-literals/-/babel-plugin-transform-es2015-template-literals-6.22.0.tgz#a84b3450f7e9f8f1f6839d6d687da84bb1236d8d" - integrity sha1-qEs0UPfp+PH2g51taH2oS7EjbY0= - dependencies: - babel-runtime "^6.22.0" - -babel-plugin-transform-es2015-typeof-symbol@^6.22.0: - version "6.23.0" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-typeof-symbol/-/babel-plugin-transform-es2015-typeof-symbol-6.23.0.tgz#dec09f1cddff94b52ac73d505c84df59dcceb372" - integrity sha1-3sCfHN3/lLUqxz1QXITfWdzOs3I= - dependencies: - babel-runtime "^6.22.0" - -babel-plugin-transform-es2015-unicode-regex@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-es2015-unicode-regex/-/babel-plugin-transform-es2015-unicode-regex-6.24.1.tgz#d38b12f42ea7323f729387f18a7c5ae1faeb35e9" - integrity sha1-04sS9C6nMj9yk4fxinxa4frrNek= - dependencies: - babel-helper-regex "^6.24.1" - babel-runtime "^6.22.0" - regexpu-core "^2.0.0" - -babel-plugin-transform-exponentiation-operator@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-exponentiation-operator/-/babel-plugin-transform-exponentiation-operator-6.24.1.tgz#2ab0c9c7f3098fa48907772bb813fe41e8de3a0e" - integrity sha1-KrDJx/MJj6SJB3cruBP+QejeOg4= - dependencies: - babel-helper-builder-binary-assignment-operator-visitor "^6.24.1" - babel-plugin-syntax-exponentiation-operator "^6.8.0" - babel-runtime "^6.22.0" - -babel-plugin-transform-export-extensions@^6.22.0: - version "6.22.0" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-export-extensions/-/babel-plugin-transform-export-extensions-6.22.0.tgz#53738b47e75e8218589eea946cbbd39109bbe653" - integrity sha1-U3OLR+deghhYnuqUbLvTkQm75lM= - dependencies: - babel-plugin-syntax-export-extensions "^6.8.0" - babel-runtime "^6.22.0" - -babel-plugin-transform-object-rest-spread@^6.22.0: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-object-rest-spread/-/babel-plugin-transform-object-rest-spread-6.26.0.tgz#0f36692d50fef6b7e2d4b3ac1478137a963b7b06" - integrity sha1-DzZpLVD+9rfi1LOsFHgTepY7ewY= - dependencies: - babel-plugin-syntax-object-rest-spread "^6.8.0" - babel-runtime "^6.26.0" - -babel-plugin-transform-regenerator@^6.24.1: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-regenerator/-/babel-plugin-transform-regenerator-6.26.0.tgz#e0703696fbde27f0a3efcacf8b4dca2f7b3a8f2f" - integrity sha1-4HA2lvveJ/Cj78rPi03KL3s6jy8= - dependencies: - regenerator-transform "^0.10.0" - -babel-plugin-transform-strict-mode@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-plugin-transform-strict-mode/-/babel-plugin-transform-strict-mode-6.24.1.tgz#d5faf7aa578a65bbe591cf5edae04a0c67020758" - integrity sha1-1fr3qleKZbvlkc9e2uBKDGcCB1g= - dependencies: - babel-runtime "^6.22.0" - babel-types "^6.24.1" - -babel-preset-es2015@^6.6.0: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-preset-es2015/-/babel-preset-es2015-6.24.1.tgz#d44050d6bc2c9feea702aaf38d727a0210538939" - integrity sha1-1EBQ1rwsn+6nAqrzjXJ6AhBTiTk= - dependencies: - babel-plugin-check-es2015-constants "^6.22.0" - babel-plugin-transform-es2015-arrow-functions "^6.22.0" - babel-plugin-transform-es2015-block-scoped-functions "^6.22.0" - babel-plugin-transform-es2015-block-scoping "^6.24.1" - babel-plugin-transform-es2015-classes "^6.24.1" - babel-plugin-transform-es2015-computed-properties "^6.24.1" - babel-plugin-transform-es2015-destructuring "^6.22.0" - babel-plugin-transform-es2015-duplicate-keys "^6.24.1" - babel-plugin-transform-es2015-for-of "^6.22.0" - babel-plugin-transform-es2015-function-name "^6.24.1" - babel-plugin-transform-es2015-literals "^6.22.0" - babel-plugin-transform-es2015-modules-amd "^6.24.1" - babel-plugin-transform-es2015-modules-commonjs "^6.24.1" - babel-plugin-transform-es2015-modules-systemjs "^6.24.1" - babel-plugin-transform-es2015-modules-umd "^6.24.1" - babel-plugin-transform-es2015-object-super "^6.24.1" - babel-plugin-transform-es2015-parameters "^6.24.1" - babel-plugin-transform-es2015-shorthand-properties "^6.24.1" - babel-plugin-transform-es2015-spread "^6.22.0" - babel-plugin-transform-es2015-sticky-regex "^6.24.1" - babel-plugin-transform-es2015-template-literals "^6.22.0" - babel-plugin-transform-es2015-typeof-symbol "^6.22.0" - babel-plugin-transform-es2015-unicode-regex "^6.24.1" - babel-plugin-transform-regenerator "^6.24.1" - -babel-preset-stage-1@^6.5.0: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-preset-stage-1/-/babel-preset-stage-1-6.24.1.tgz#7692cd7dcd6849907e6ae4a0a85589cfb9e2bfb0" - integrity sha1-dpLNfc1oSZB+auSgqFWJz7niv7A= - dependencies: - babel-plugin-transform-class-constructor-call "^6.24.1" - babel-plugin-transform-export-extensions "^6.22.0" - babel-preset-stage-2 "^6.24.1" - -babel-preset-stage-2@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-preset-stage-2/-/babel-preset-stage-2-6.24.1.tgz#d9e2960fb3d71187f0e64eec62bc07767219bdc1" - integrity sha1-2eKWD7PXEYfw5k7sYrwHdnIZvcE= - dependencies: - babel-plugin-syntax-dynamic-import "^6.18.0" - babel-plugin-transform-class-properties "^6.24.1" - babel-plugin-transform-decorators "^6.24.1" - babel-preset-stage-3 "^6.24.1" - -babel-preset-stage-3@^6.24.1: - version "6.24.1" - resolved "https://registry.yarnpkg.com/babel-preset-stage-3/-/babel-preset-stage-3-6.24.1.tgz#836ada0a9e7a7fa37cb138fb9326f87934a48395" - integrity sha1-g2raCp56f6N8sTj7kyb4eTSkg5U= - dependencies: - babel-plugin-syntax-trailing-function-commas "^6.22.0" - babel-plugin-transform-async-generator-functions "^6.24.1" - babel-plugin-transform-async-to-generator "^6.24.1" - babel-plugin-transform-exponentiation-operator "^6.24.1" - babel-plugin-transform-object-rest-spread "^6.22.0" - -babel-register@^6.26.0: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-register/-/babel-register-6.26.0.tgz#6ed021173e2fcb486d7acb45c6009a856f647071" - integrity sha1-btAhFz4vy0htestFxgCahW9kcHE= - dependencies: - babel-core "^6.26.0" - babel-runtime "^6.26.0" - core-js "^2.5.0" - home-or-tmp "^2.0.0" - lodash "^4.17.4" - mkdirp "^0.5.1" - source-map-support "^0.4.15" - -babel-runtime@^6.18.0, babel-runtime@^6.22.0, babel-runtime@^6.26.0: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-runtime/-/babel-runtime-6.26.0.tgz#965c7058668e82b55d7bfe04ff2337bc8b5647fe" - integrity sha1-llxwWGaOgrVde/4E/yM3vItWR/4= - dependencies: - core-js "^2.4.0" - regenerator-runtime "^0.11.0" - -babel-template@^6.24.1, babel-template@^6.26.0: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-template/-/babel-template-6.26.0.tgz#de03e2d16396b069f46dd9fff8521fb1a0e35e02" - integrity sha1-3gPi0WOWsGn0bdn/+FIfsaDjXgI= - dependencies: - babel-runtime "^6.26.0" - babel-traverse "^6.26.0" - babel-types "^6.26.0" - babylon "^6.18.0" - lodash "^4.17.4" - -babel-traverse@^6.0.20, babel-traverse@^6.24.1, babel-traverse@^6.26.0: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-traverse/-/babel-traverse-6.26.0.tgz#46a9cbd7edcc62c8e5c064e2d2d8d0f4035766ee" - integrity sha1-RqnL1+3MYsjlwGTi0tjQ9ANXZu4= - dependencies: - babel-code-frame "^6.26.0" - babel-messages "^6.23.0" - babel-runtime "^6.26.0" - babel-types "^6.26.0" - babylon "^6.18.0" - debug "^2.6.8" - globals "^9.18.0" - invariant "^2.2.2" - lodash "^4.17.4" - -babel-types@^6.0.19, babel-types@^6.19.0, babel-types@^6.24.1, babel-types@^6.26.0: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-types/-/babel-types-6.26.0.tgz#a3b073f94ab49eb6fa55cd65227a334380632497" - integrity sha1-o7Bz+Uq0nrb6Vc1lInozQ4BjJJc= +babel-eslint@^10.0.2: + version "10.0.2" + resolved "https://registry.yarnpkg.com/babel-eslint/-/babel-eslint-10.0.2.tgz#182d5ac204579ff0881684b040560fdcc1558456" + integrity sha512-UdsurWPtgiPgpJ06ryUnuaSXC2s0WoSZnQmEpbAH65XZSdwowgN5MvyP7e88nW07FYXv72erVtpBkxyDVKhH1Q== dependencies: - babel-runtime "^6.26.0" - esutils "^2.0.2" - lodash "^4.17.4" - to-fast-properties "^1.0.3" + "@babel/code-frame" "^7.0.0" + "@babel/parser" "^7.0.0" + "@babel/traverse" "^7.0.0" + "@babel/types" "^7.0.0" + eslint-scope "3.7.1" + eslint-visitor-keys "^1.0.0" -babylon@^6.0.18, babylon@^6.18.0: - version "6.18.0" - resolved "https://registry.yarnpkg.com/babylon/-/babylon-6.18.0.tgz#af2f3b88fa6f5c1e4c634d1a0f8eac4f55b395e3" - integrity sha512-q/UEjfGJ2Cm3oKV71DJz9d25TPnq5rhBVL2Q4fA5wcC3jcrdn7+SssEybFIxwAvvP+YCsCYNKughoF33GxgycQ== +bach@^1.0.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/bach/-/bach-1.2.0.tgz#4b3ce96bf27134f79a1b414a51c14e34c3bd9880" + integrity sha1-Szzpa/JxNPeaG0FKUcFONMO9mIA= + dependencies: + arr-filter "^1.1.1" + arr-flatten "^1.0.1" + arr-map "^2.0.0" + array-each "^1.0.0" + array-initial "^1.0.0" + array-last "^1.1.1" + async-done "^1.2.2" + async-settle "^1.0.0" + now-and-later "^2.0.0" balanced-match@^1.0.0: version "1.0.0" @@ -863,6 +1005,11 @@ beeper@^1.0.0: resolved "https://registry.yarnpkg.com/beeper/-/beeper-1.1.1.tgz#e6d5ea8c5dad001304a70b22638447f69cb2f809" integrity sha1-5tXqjF2tABMEpwsiY4RH9pyy+Ak= +binary-extensions@^1.0.0: + version "1.13.1" + resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-1.13.1.tgz#598afe54755b2868a5330d2aff9d4ebb53209b65" + integrity sha512-Un7MIEDdUC5gNpcGDV97op1Ywk748MpHcFTHoYs6qnj1Z3j7I53VG3nwZhKzoBZmbdRNnb6WRdFlwl7tSDuZGw== + bluebird@^3.3.4: version "3.5.1" resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.5.1.tgz#d9551f9de98f1fcda1e683d17ee91a0602ee2eb9" @@ -890,7 +1037,7 @@ brace-expansion@^1.0.0, brace-expansion@^1.1.7: balanced-match "^1.0.0" concat-map "0.0.1" -braces@^2.3.1: +braces@^2.3.1, braces@^2.3.2: version "2.3.2" resolved "https://registry.yarnpkg.com/braces/-/braces-2.3.2.tgz#5979fd3f14cd531565e5fa2df1abfff1dfaee729" integrity sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w== @@ -906,12 +1053,24 @@ braces@^2.3.1: split-string "^3.0.2" to-regex "^3.0.1" -bufferstreams@1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/bufferstreams/-/bufferstreams-1.0.2.tgz#37643de45f8f84875503111284e7c38b56b8d54f" - integrity sha1-N2Q95F+PhIdVAxEShOfDi1a41U8= +browserslist@^4.6.0, browserslist@^4.6.2: + version "4.6.3" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.6.3.tgz#0530cbc6ab0c1f3fc8c819c72377ba55cf647f05" + integrity sha512-CNBqTCq22RKM8wKJNowcqihHJ4SkI8CGeK7KOR9tPboXUuS5Zk5lQgzzTbs4oxD8x+6HUshZUa2OyNI9lR93bQ== dependencies: - readable-stream "^2.0.0" + caniuse-lite "^1.0.30000975" + electron-to-chromium "^1.3.164" + node-releases "^1.1.23" + +buffer-equal@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/buffer-equal/-/buffer-equal-1.0.0.tgz#59616b498304d556abd466966b22eeda3eca5fbe" + integrity sha1-WWFrSYME1Var1GaWayLu2j7KX74= + +buffer-from@^1.0.0: + version "1.1.1" + resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.1.tgz#32713bc028f75c02fdb710d7c7bcec1f2c6070ef" + integrity sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A== cache-base@^1.0.1: version "1.0.1" @@ -928,6 +1087,28 @@ cache-base@^1.0.1: union-value "^1.0.0" unset-value "^1.0.0" +caller-path@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/caller-path/-/caller-path-0.1.0.tgz#94085ef63581ecd3daa92444a8fe94e82577751f" + integrity sha1-lAhe9jWB7NPaqSREqP6U6CV3dR8= + dependencies: + callsites "^0.2.0" + +callsites@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/callsites/-/callsites-0.2.0.tgz#afab96262910a7f33c19a5775825c69f34e350ca" + integrity sha1-r6uWJikQp/M8GaV3WCXGnzTjUMo= + +camelcase@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-3.0.0.tgz#32fc4b9fcdaf845fcdf7e73bb97cac2261f0ab0a" + integrity sha1-MvxLn82vhF/N9+c7uXysImHwqwo= + +caniuse-lite@^1.0.30000975: + version "1.0.30000979" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000979.tgz#92f16d00186a6cf20d6c5711bb6e042a3d667029" + integrity sha512-gcu45yfq3B7Y+WB05fOMfr0EiSlq+1u+m6rPHyJli/Wy3PVQNGaU7VA4bZE5qw+AU2UVOBR/N5g1bzADUqdvFw== + caseless@~0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" @@ -953,6 +1134,49 @@ chalk@^1.0.0, chalk@^1.1.1, chalk@^1.1.3: strip-ansi "^3.0.0" supports-color "^2.0.0" +chalk@^2.0.0, chalk@^2.1.0: + version "2.4.2" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" + integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== + dependencies: + ansi-styles "^3.2.1" + escape-string-regexp "^1.0.5" + supports-color "^5.3.0" + +chardet@^0.4.0: + version "0.4.2" + resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.4.2.tgz#b5473b33dc97c424e5d98dc87d55d4d8a29c8bf2" + integrity sha1-tUc7M9yXxCTl2Y3IfVXU2KKci/I= + +chokidar@^2.0.0: + version "2.1.6" + resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-2.1.6.tgz#b6cad653a929e244ce8a834244164d241fa954c5" + integrity sha512-V2jUo67OKkc6ySiRpJrjlpJKl9kDuG+Xb8VgsGzb+aEouhgS1D0weyPU4lEzdAcsCAvrih2J2BqyXqHWvVLw5g== + dependencies: + anymatch "^2.0.0" + async-each "^1.0.1" + braces "^2.3.2" + glob-parent "^3.1.0" + inherits "^2.0.3" + is-binary-path "^1.0.0" + is-glob "^4.0.0" + normalize-path "^3.0.0" + path-is-absolute "^1.0.0" + readdirp "^2.2.1" + upath "^1.1.1" + optionalDependencies: + fsevents "^1.2.7" + +chownr@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/chownr/-/chownr-1.1.1.tgz#54726b8b8fff4df053c42187e801fb4412df1494" + integrity sha512-j38EvO5+LHX84jlo6h4UzmOwi0UgW61WRyPtJz4qaadK5eY3BTS5TY/S1Stc3Uk2lIM6TPevAlULiEJwie860g== + +circular-json@^0.3.1: + version "0.3.3" + resolved "https://registry.yarnpkg.com/circular-json/-/circular-json-0.3.3.tgz#815c99ea84f6809529d2f45791bdf82711352d66" + integrity sha512-UZK3NBx2Mca+b5LsG7bY183pHWt5Y1xts4P3Pz7ENTwGVnJOUWbRb3ocjvX7hx9tq/yTAdclXm9sZ38gNuem4A== + class-utils@^0.3.5: version "0.3.6" resolved "https://registry.yarnpkg.com/class-utils/-/class-utils-0.3.6.tgz#f93369ae8b9a7ce02fd41faad0ca83033190c463" @@ -963,36 +1187,80 @@ class-utils@^0.3.5: isobject "^3.0.0" static-extend "^0.1.1" -cli-width@^1.0.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-1.1.1.tgz#a4d293ef67ebb7b88d4a4d42c0ccf00c4d1e366d" - integrity sha1-pNKT72frt7iNSk1CwMzwDE0eNm0= +cli-cursor@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-2.1.0.tgz#b35dac376479facc3e94747d41d0d0f5238ffcb5" + integrity sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU= + dependencies: + restore-cursor "^2.0.0" + +cli-width@^2.0.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-2.2.0.tgz#ff19ede8a9a5e579324147b0c11f0fbcbabed639" + integrity sha1-/xnt6Kml5XkyQUewwR8PvLq+1jk= + +cliui@^3.2.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-3.2.0.tgz#120601537a916d29940f934da3b48d585a39213d" + integrity sha1-EgYBU3qRbSmUD5NNo7SNWFo5IT0= + dependencies: + string-width "^1.0.1" + strip-ansi "^3.0.1" + wrap-ansi "^2.0.0" + +clone-buffer@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/clone-buffer/-/clone-buffer-1.0.0.tgz#e3e25b207ac4e701af721e2cb5a16792cac3dc58" + integrity sha1-4+JbIHrE5wGvch4staFnksrD3Fg= clone-stats@^0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/clone-stats/-/clone-stats-0.0.1.tgz#b88f94a82cf38b8791d58046ea4029ad88ca99d1" integrity sha1-uI+UqCzzi4eR1YBG6kAprYjKmdE= -clone@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/clone/-/clone-0.2.0.tgz#c6126a90ad4f72dbf5acdb243cc37724fe93fc1f" - integrity sha1-xhJqkK1Pctv1rNskPMN3JP6T/B8= +clone-stats@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/clone-stats/-/clone-stats-1.0.0.tgz#b3782dff8bb5474e18b9b6bf0fdfe782f8777680" + integrity sha1-s3gt/4u1R04Yuba/D9/ngvh3doA= clone@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/clone/-/clone-1.0.2.tgz#260b7a99ebb1edfe247538175f783243cb19d149" integrity sha1-Jgt6meux7f4kdTgXX3gyQ8sZ0Uk= -clone@^1.0.2: - version "1.0.4" - resolved "https://registry.yarnpkg.com/clone/-/clone-1.0.4.tgz#da309cc263df15994c688ca902179ca3c7cd7c7e" - integrity sha1-2jCcwmPfFZlMaIypAheco8fNfH4= +clone@^2.1.1: + version "2.1.2" + resolved "https://registry.yarnpkg.com/clone/-/clone-2.1.2.tgz#1b7f4b9f591f1e8f83670401600345a02887435f" + integrity sha1-G39Ln1kfHo+DZwQBYANFoCiHQ18= + +cloneable-readable@^1.0.0: + version "1.1.3" + resolved "https://registry.yarnpkg.com/cloneable-readable/-/cloneable-readable-1.1.3.tgz#120a00cb053bfb63a222e709f9683ea2e11d8cec" + integrity sha512-2EF8zTQOxYq70Y4XKtorQupqF0m49MBz2/yf5Bj+MHjvpG3Hy7sImifnqD6UA+TKYxeSV+u6qqQPawN5UvnpKQ== + dependencies: + inherits "^2.0.1" + process-nextick-args "^2.0.0" + readable-stream "^2.3.5" co@^4.6.0: version "4.6.0" resolved "https://registry.yarnpkg.com/co/-/co-4.6.0.tgz#6ea6bdf3d853ae54ccb8e47bfa0bf3f9031fb184" integrity sha1-bqa989hTrlTMuOR7+gvz+QMfsYQ= +code-point-at@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77" + integrity sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c= + +collection-map@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/collection-map/-/collection-map-1.0.0.tgz#aea0f06f8d26c780c2b75494385544b2255af18c" + integrity sha1-rqDwb40mx4DCt1SUOFVEsiVa8Yw= + dependencies: + arr-map "^2.0.2" + for-own "^1.0.0" + make-iterator "^1.0.0" + collection-visit@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/collection-visit/-/collection-visit-1.0.0.tgz#4bc0373c164bc3291b4d368c829cf1a80a59dca0" @@ -1001,6 +1269,23 @@ collection-visit@^1.0.0: map-visit "^1.0.0" object-visit "^1.0.0" +color-convert@^1.9.0: + version "1.9.3" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.3.tgz#bb71850690e1f136567de629d2d5471deda4c1e8" + integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== + dependencies: + color-name "1.1.3" + +color-name@1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" + integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= + +color-support@^1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/color-support/-/color-support-1.1.3.tgz#93834379a1cc9a0c61f82f52f0d04322251bd5a2" + integrity sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg== + combined-stream@^1.0.5, combined-stream@~1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.5.tgz#938370a57b4a51dea2c77c15d5c5fdf895164009" @@ -1033,15 +1318,28 @@ concat-map@0.0.1: resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= -concat-stream@^1.4.6: - version "1.6.0" - resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.0.tgz#0aac662fd52be78964d5532f694784e70110acf7" - integrity sha1-CqxmL9Ur54lk1VMvaUeE5wEQrPc= +concat-stream@^1.6.0: + version "1.6.2" + resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34" + integrity sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw== dependencies: + buffer-from "^1.0.0" inherits "^2.0.3" readable-stream "^2.2.2" typedarray "^0.0.6" +console-control-strings@^1.0.0, console-control-strings@~1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/console-control-strings/-/console-control-strings-1.1.0.tgz#3d7cf4464db6446ea644bf4b39507f9851008e8e" + integrity sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4= + +convert-source-map@^1.1.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.6.0.tgz#51b537a8c43e0f04dec1993bffcdd504e758ac20" + integrity sha512-eFu7XigvxdZ1ETfbgPBohgyQ/Z++C0eEhTor0qRwBw9unw+L0/6V8wkSuGgzdThkiS5lSpdptOQPD8Ak40a+7A== + dependencies: + safe-buffer "~5.1.1" + convert-source-map@^1.5.0: version "1.5.0" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.5.0.tgz#9acd70851c6d5dfdd93d9282e5edf94a03ff46b5" @@ -1052,16 +1350,42 @@ copy-descriptor@^0.1.0: resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" integrity sha1-Z29us8OZl8LuGsOpJP1hJHSPV40= -core-js@^2.4.0, core-js@^2.5.0: - version "2.5.1" - resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.5.1.tgz#ae6874dc66937789b80754ff5428df66819ca50b" - integrity sha1-rmh03GaTd4m4B1T/VCjfZoGcpQs= +copy-props@^2.0.1: + version "2.0.4" + resolved "https://registry.yarnpkg.com/copy-props/-/copy-props-2.0.4.tgz#93bb1cadfafd31da5bb8a9d4b41f471ec3a72dfe" + integrity sha512-7cjuUME+p+S3HZlbllgsn2CDwS+5eCCX16qBgNC4jgSTf49qR1VKy/Zhl400m0IQXl/bPGEVqncgUUMjrr4s8A== + dependencies: + each-props "^1.3.0" + is-plain-object "^2.0.1" + +core-js-compat@^3.1.1: + version "3.1.4" + resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.1.4.tgz#e4d0c40fbd01e65b1d457980fe4112d4358a7408" + integrity sha512-Z5zbO9f1d0YrJdoaQhphVAnKPimX92D6z8lCGphH89MNRxlL1prI9ExJPqVwP0/kgkQCv8c4GJGT8X16yUncOg== + dependencies: + browserslist "^4.6.2" + core-js-pure "3.1.4" + semver "^6.1.1" + +core-js-pure@3.1.4: + version "3.1.4" + resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.1.4.tgz#5fa17dc77002a169a3566cc48dc774d2e13e3769" + integrity sha512-uJ4Z7iPNwiu1foygbcZYJsJs1jiXrTTCvxfLDXNhI/I+NHbSIEyr548y4fcsCEyWY0XgfAG/qqaunJ1SThHenA== core-util-is@1.0.2, core-util-is@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac= +cross-spawn@^5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-5.1.0.tgz#e8bd0efee58fcff6f8f94510a0a554bbfa235449" + integrity sha1-6L0O/uWPz/b4+UUQoKVUu/ojVEk= + dependencies: + lru-cache "^4.0.1" + shebang-command "^1.2.0" + which "^1.2.9" + cryptiles@3.x.x: version "3.1.2" resolved "https://registry.yarnpkg.com/cryptiles/-/cryptiles-3.1.2.tgz#a89fbb220f5ce25ec56e8c4aa8a4fd7b5b0d29fe" @@ -1070,11 +1394,12 @@ cryptiles@3.x.x: boom "5.x.x" d@1: - version "1.0.0" - resolved "https://registry.yarnpkg.com/d/-/d-1.0.0.tgz#754bb5bfe55451da69a58b94d45f4c5b0462d58f" - integrity sha1-dUu1v+VUUdpppYuU1F9MWwRi1Y8= + version "1.0.1" + resolved "https://registry.yarnpkg.com/d/-/d-1.0.1.tgz#8698095372d58dbee346ffd0c7093f99f8f9eb5a" + integrity sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA== dependencies: - es5-ext "^0.10.9" + es5-ext "^0.10.50" + type "^1.0.1" dashdash@^1.12.0: version "1.14.1" @@ -1095,13 +1420,32 @@ debug@2.2.0: dependencies: ms "0.7.1" -debug@^2.1.1, debug@^2.2.0, debug@^2.3.3, debug@^2.6.8: +debug@^2.2.0, debug@^2.3.3: version "2.6.9" resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== dependencies: ms "2.0.0" +debug@^3.1.0, debug@^3.2.6: + version "3.2.6" + resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.6.tgz#e83d17de16d8a7efb7717edbe5fb10135eee629b" + integrity sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ== + dependencies: + ms "^2.1.1" + +debug@^4.1.0: + version "4.1.1" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.1.1.tgz#3b72260255109c6b589cee050f1d516139664791" + integrity sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw== + dependencies: + ms "^2.1.1" + +decamelize@^1.1.1: + version "1.2.0" + resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" + integrity sha1-9lNNFRSCabIDUue+4m9QH5oZEpA= + decode-uri-component@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545" @@ -1119,17 +1463,34 @@ deep-equal@^1.0.0: resolved "https://registry.yarnpkg.com/deep-equal/-/deep-equal-1.0.1.tgz#f5d260292b660e084eff4cdbc9f08ad3247448b5" integrity sha1-9dJgKStmDghO/0zbyfCK0yR0SLU= +deep-extend@^0.6.0: + version "0.6.0" + resolved "https://registry.yarnpkg.com/deep-extend/-/deep-extend-0.6.0.tgz#c4fa7c95404a17a9c3e8ca7e1537312b736330ac" + integrity sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA== + deep-is@~0.1.2, deep-is@~0.1.3: version "0.1.3" resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34" integrity sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ= -defaults@^1.0.0: - version "1.0.3" - resolved "https://registry.yarnpkg.com/defaults/-/defaults-1.0.3.tgz#c656051e9817d9ff08ed881477f3fe4019f3ef7d" - integrity sha1-xlYFHpgX2f8I7YgUd/P+QBnz730= +default-compare@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/default-compare/-/default-compare-1.0.0.tgz#cb61131844ad84d84788fb68fd01681ca7781a2f" + integrity sha512-QWfXlM0EkAbqOCbD/6HjdwT19j7WCkMyiRhWilc4H9/5h/RzTF9gv5LYh1+CmDV5d1rki6KAWLtQale0xt20eQ== + dependencies: + kind-of "^5.0.2" + +default-resolution@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/default-resolution/-/default-resolution-2.0.0.tgz#bcb82baa72ad79b426a76732f1a81ad6df26d684" + integrity sha1-vLgrqnKtebQmp2cy8aga1t8m1oQ= + +define-properties@^1.1.2: + version "1.1.3" + resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.3.tgz#cf88da6cbee26fe6db7094f61d870cbd84cee9f1" + integrity sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ== dependencies: - clone "^1.0.2" + object-keys "^1.0.12" define-property@^0.2.5: version "0.2.5" @@ -1158,22 +1519,20 @@ delayed-stream@~1.0.0: resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" integrity sha1-3zrhmayt+31ECqrgsp4icrJOxhk= -deprecated@^0.0.1: - version "0.0.1" - resolved "https://registry.yarnpkg.com/deprecated/-/deprecated-0.0.1.tgz#f9c9af5464afa1e7a971458a8bdef2aa94d5bb19" - integrity sha1-+cmvVGSvoeepcUWKi97yqpTVuxk= +delegates@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/delegates/-/delegates-1.0.0.tgz#84c6e159b81904fdca59a0ef44cd870d31250f9a" + integrity sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o= detect-file@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/detect-file/-/detect-file-1.0.0.tgz#f0d66d03672a825cb1b73bdb3fe62310c8e552b7" integrity sha1-8NZtA2cqglyxtzvbP+YjEMjlUrc= -detect-indent@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/detect-indent/-/detect-indent-4.0.0.tgz#f76d064352cdf43a1cb6ce619c4ee3a9475de208" - integrity sha1-920GQ1LN9Docts5hnE7jqUdd4gg= - dependencies: - repeating "^2.0.0" +detect-libc@^1.0.2: + version "1.0.3" + resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-1.0.3.tgz#fa137c4bd698edf55cd5cd02ac559f91a4c4ba9b" + integrity sha1-+hN8S9aY7fVc1c0CrFWfkaTEups= diff@1.4.0: version "1.4.0" @@ -1185,13 +1544,12 @@ diff@^3.5.0: resolved "https://registry.yarnpkg.com/diff/-/diff-3.5.0.tgz#800c0dd1e0a8bfbc95835c202ad220fe317e5a12" integrity sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA== -doctrine@^0.6.2: - version "0.6.4" - resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-0.6.4.tgz#81428491a942ef18b0492056eda3800eee57d61d" - integrity sha1-gUKEkalC7xiwSSBW7aOADu5X1h0= +doctrine@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.1.0.tgz#5cd01fc101621b42c4cd7f5d1a66243716d3f39d" + integrity sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw== dependencies: - esutils "^1.1.6" - isarray "0.0.1" + esutils "^2.0.2" duplexer2@0.0.2: version "0.0.2" @@ -1200,6 +1558,24 @@ duplexer2@0.0.2: dependencies: readable-stream "~1.1.9" +duplexify@^3.6.0: + version "3.7.1" + resolved "https://registry.yarnpkg.com/duplexify/-/duplexify-3.7.1.tgz#2a4df5317f6ccfd91f86d6fd25d8d8a103b88309" + integrity sha512-07z8uv2wMyS51kKhD1KsdXJg5WQ6t93RneqRxUHnskXVtlYYkLqM0gqStQZ3pj073g687jPCHrqNfCzawLYh5g== + dependencies: + end-of-stream "^1.0.0" + inherits "^2.0.1" + readable-stream "^2.0.0" + stream-shift "^1.0.0" + +each-props@^1.3.0: + version "1.3.2" + resolved "https://registry.yarnpkg.com/each-props/-/each-props-1.3.2.tgz#ea45a414d16dd5cfa419b1a81720d5ca06892333" + integrity sha512-vV0Hem3zAGkJAyU7JSjixeU66rwdynTAa1vofCrSA5fEln+m67Az9CcnkVD776/fsN/UjIWmBDoNRS6t6G9RfA== + dependencies: + is-plain-object "^2.0.1" + object.defaults "^1.1.0" + ecc-jsbn@~0.1.1: version "0.1.2" resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz#3a83a904e54353287874c564b7549386849a98c9" @@ -1208,54 +1584,44 @@ ecc-jsbn@~0.1.1: jsbn "~0.1.0" safer-buffer "^2.1.0" -end-of-stream@~0.1.5: - version "0.1.5" - resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-0.1.5.tgz#8e177206c3c80837d85632e8b9359dfe8b2f6eaf" - integrity sha1-jhdyBsPICDfYVjLouTWd/osvbq8= - dependencies: - once "~1.3.0" +electron-to-chromium@^1.3.164: + version "1.3.185" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.185.tgz#36368514eb719632a91435f3c9f57c98b47d81de" + integrity sha512-h2iW0AHIwix8ifNJg/RkXhQjUDqBME8TvX8qQQMvvF2Tb6F2KnO6febvI+JqI9CdZOWnl90CPxdBRWGDrdk9UA== -es5-ext@^0.10.14, es5-ext@^0.10.9, es5-ext@~0.10.14: - version "0.10.35" - resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.35.tgz#18ee858ce6a3c45c7d79e91c15fcca9ec568494f" - integrity sha1-GO6FjOajxFx9eekcFfzKnsVoSU8= +end-of-stream@^1.0.0, end-of-stream@^1.1.0: + version "1.4.1" + resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.1.tgz#ed29634d19baba463b6ce6b80a37213eab71ec43" + integrity sha512-1MkrZNvWTKCaigbn+W15elq2BB/L22nqrSY5DKlo3X6+vclJm8Bb5djXJBmEX6fS3+zCh/F4VBK5Z2KxJt4s2Q== dependencies: - es6-iterator "~2.0.1" - es6-symbol "~3.1.1" + once "^1.4.0" -es6-iterator@^2.0.1, es6-iterator@~2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/es6-iterator/-/es6-iterator-2.0.1.tgz#8e319c9f0453bf575d374940a655920e59ca5512" - integrity sha1-jjGcnwRTv1ddN0lAplWSDlnKVRI= +error-ex@^1.2.0: + version "1.3.2" + resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" + integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== dependencies: - d "1" - es5-ext "^0.10.14" - es6-symbol "^3.1" + is-arrayish "^0.2.1" -es6-map@^0.1.3: - version "0.1.5" - resolved "https://registry.yarnpkg.com/es6-map/-/es6-map-0.1.5.tgz#9136e0503dcc06a301690f0bb14ff4e364e949f0" - integrity sha1-kTbgUD3MBqMBaQ8LsU/042TpSfA= +es5-ext@^0.10.35, es5-ext@^0.10.46, es5-ext@^0.10.50, es5-ext@~0.10.14: + version "0.10.50" + resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.50.tgz#6d0e23a0abdb27018e5ac4fd09b412bc5517a778" + integrity sha512-KMzZTPBkeQV/JcSQhI5/z6d9VWJ3EnQ194USTUwIYZ2ZbpN8+SGXQKt1h68EX44+qt+Fzr8DO17vnxrw7c3agw== dependencies: - d "1" - es5-ext "~0.10.14" - es6-iterator "~2.0.1" - es6-set "~0.1.5" + es6-iterator "~2.0.3" es6-symbol "~3.1.1" - event-emitter "~0.3.5" + next-tick "^1.0.0" -es6-set@~0.1.5: - version "0.1.5" - resolved "https://registry.yarnpkg.com/es6-set/-/es6-set-0.1.5.tgz#d2b3ec5d4d800ced818db538d28974db0a73ccb1" - integrity sha1-0rPsXU2ADO2BjbU40ol02wpzzLE= +es6-iterator@^2.0.1, es6-iterator@^2.0.3, es6-iterator@~2.0.3: + version "2.0.3" + resolved "https://registry.yarnpkg.com/es6-iterator/-/es6-iterator-2.0.3.tgz#a7de889141a05a94b0854403b2d0a0fbfa98f3b7" + integrity sha1-p96IkUGgWpSwhUQDstCg+/qY87c= dependencies: d "1" - es5-ext "~0.10.14" - es6-iterator "~2.0.1" - es6-symbol "3.1.1" - event-emitter "~0.3.5" + es5-ext "^0.10.35" + es6-symbol "^3.1.1" -es6-symbol@3.1.1, es6-symbol@^3.1, es6-symbol@^3.1.1, es6-symbol@~3.1.1: +es6-symbol@^3.1.1, es6-symbol@~3.1.1: version "3.1.1" resolved "https://registry.yarnpkg.com/es6-symbol/-/es6-symbol-3.1.1.tgz#bf00ef4fdab6ba1b46ecb7b629b4c7ed5715cc77" integrity sha1-vwDvT9q2uhtG7Le2KbTH7VcVzHc= @@ -1264,13 +1630,13 @@ es6-symbol@3.1.1, es6-symbol@^3.1, es6-symbol@^3.1.1, es6-symbol@~3.1.1: es5-ext "~0.10.14" es6-weak-map@^2.0.1: - version "2.0.2" - resolved "https://registry.yarnpkg.com/es6-weak-map/-/es6-weak-map-2.0.2.tgz#5e3ab32251ffd1538a1f8e5ffa1357772f92d96f" - integrity sha1-XjqzIlH/0VOKH45f+hNXdy+S2W8= + version "2.0.3" + resolved "https://registry.yarnpkg.com/es6-weak-map/-/es6-weak-map-2.0.3.tgz#b6da1f16cc2cc0d9be43e6bdbfc5e7dfcdf31d53" + integrity sha512-p5um32HOTO1kP+w7PRnB+5lQ43Z6muuMuIMffvDN8ZB4GcnjLBV6zGStpbASIMk4DCAvEaamhe2zhyCb/QXXsA== dependencies: d "1" - es5-ext "^0.10.14" - es6-iterator "^2.0.1" + es5-ext "^0.10.46" + es6-iterator "^2.0.3" es6-symbol "^3.1.1" escape-string-regexp@1.0.2: @@ -1307,48 +1673,78 @@ escodegen@1.8.x: optionalDependencies: source-map "~0.2.0" -escope@^3.1.0: - version "3.6.0" - resolved "https://registry.yarnpkg.com/escope/-/escope-3.6.0.tgz#e01975e812781a163a6dadfdd80398dc64c889c3" - integrity sha1-4Bl16BJ4GhY6ba392AOY3GTIicM= +eslint-scope@3.7.1: + version "3.7.1" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-3.7.1.tgz#3d63c3edfda02e06e01a452ad88caacc7cdcb6e8" + integrity sha1-PWPD7f2gLgbgGkUq2IyqzHzctug= dependencies: - es6-map "^0.1.3" - es6-weak-map "^2.0.1" esrecurse "^4.1.0" estraverse "^4.1.1" -eslint@^0.24.0: - version "0.24.1" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-0.24.1.tgz#54a50809855b9655721c6f2ee57b351edce28101" - integrity sha1-VKUICYVbllVyHG8u5Xs1HtzigQE= +eslint-scope@^3.7.1: + version "3.7.3" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-3.7.3.tgz#bb507200d3d17f60247636160b4826284b108535" + integrity sha512-W+B0SvF4gamyCTmUc+uITPY0989iXVfKvhwtmJocTaYoc/3khEHmEmvfY/Gn9HA9VV75jrQECsHizkNw1b68FA== dependencies: - chalk "^1.0.0" - concat-stream "^1.4.6" - debug "^2.1.1" - doctrine "^0.6.2" - escape-string-regexp "^1.0.2" - escope "^3.1.0" - espree "^2.0.1" - estraverse "^4.1.0" - estraverse-fb "^1.3.1" - globals "^8.0.0" - inquirer "^0.8.2" - is-my-json-valid "^2.10.0" - js-yaml "^3.2.5" - minimatch "^2.0.1" - mkdirp "^0.5.0" - object-assign "^2.0.0" - optionator "^0.5.0" - path-is-absolute "^1.0.0" - strip-json-comments "~1.0.1" + esrecurse "^4.1.0" + estraverse "^4.1.1" + +eslint-visitor-keys@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" + integrity sha512-qzm/XxIbxm/FHyH341ZrbnMUpe+5Bocte9xkmFMzPMjRaZMcXww+MpBptFvtU+79L362nqiLhekCxCxDPaUMBQ== + +eslint@^4.0.0: + version "4.19.1" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.19.1.tgz#32d1d653e1d90408854bfb296f076ec7e186a300" + integrity sha512-bT3/1x1EbZB7phzYu7vCr1v3ONuzDtX8WjuM9c0iYxe+cq+pwcKEoQjl7zd3RpC6YOLgnSy3cTN58M2jcoPDIQ== + dependencies: + ajv "^5.3.0" + babel-code-frame "^6.22.0" + chalk "^2.1.0" + concat-stream "^1.6.0" + cross-spawn "^5.1.0" + debug "^3.1.0" + doctrine "^2.1.0" + eslint-scope "^3.7.1" + eslint-visitor-keys "^1.0.0" + espree "^3.5.4" + esquery "^1.0.0" + esutils "^2.0.2" + file-entry-cache "^2.0.0" + functional-red-black-tree "^1.0.1" + glob "^7.1.2" + globals "^11.0.1" + ignore "^3.3.3" + imurmurhash "^0.1.4" + inquirer "^3.0.6" + is-resolvable "^1.0.0" + js-yaml "^3.9.1" + json-stable-stringify-without-jsonify "^1.0.1" + levn "^0.3.0" + lodash "^4.17.4" + minimatch "^3.0.2" + mkdirp "^0.5.1" + natural-compare "^1.4.0" + optionator "^0.8.2" + path-is-inside "^1.0.2" + pluralize "^7.0.0" + progress "^2.0.0" + regexpp "^1.0.1" + require-uncached "^1.0.3" + semver "^5.3.0" + strip-ansi "^4.0.0" + strip-json-comments "~2.0.1" + table "4.0.2" text-table "~0.2.0" - user-home "^1.0.0" - xml-escape "~1.0.0" -espree@^2.0.1: - version "2.2.5" - resolved "https://registry.yarnpkg.com/espree/-/espree-2.2.5.tgz#df691b9310889402aeb29cc066708c56690b854b" - integrity sha1-32kbkxCIlAKuspzAZnCMVmkLhUs= +espree@^3.5.4: + version "3.5.4" + resolved "https://registry.yarnpkg.com/espree/-/espree-3.5.4.tgz#b0f447187c8a8bed944b815a660bddf5deb5d1a7" + integrity sha512-yAcIQxtmMiB/jL32dzEp2enBeidsB7xWPLNiw3IIkpVds1P+h7qF9YwJq1yUNzp2OKXgAprs4F61ih66UsoD1A== + dependencies: + acorn "^5.5.0" + acorn-jsx "^3.0.0" esprima@2.5.x: version "2.5.0" @@ -1370,6 +1766,13 @@ esprima@^4.0.0: resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== +esquery@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.1.tgz#406c51658b1f5991a5f9b62b1dc25b00e3e5c708" + integrity sha512-SmiyZ5zIWH9VM+SRUReLS5Q8a7GxtRdxEBVZpm98rJM7Sb+A9DVCndXfkeFUd3byderg+EbDkfnevfCwynWaNA== + dependencies: + estraverse "^4.0.0" + esrecurse@^4.1.0: version "4.2.0" resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.2.0.tgz#fa9568d98d3823f9a41d91e902dcab9ea6e5b163" @@ -1378,39 +1781,21 @@ esrecurse@^4.1.0: estraverse "^4.1.0" object-assign "^4.0.1" -estraverse-fb@^1.3.1: - version "1.3.2" - resolved "https://registry.yarnpkg.com/estraverse-fb/-/estraverse-fb-1.3.2.tgz#d323a4cb5e5ac331cea033413a9253e1643e07c4" - integrity sha1-0yOky15awzHOoDNBOpJT4WQ+B8Q= - estraverse@^1.9.1: version "1.9.3" resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-1.9.3.tgz#af67f2dc922582415950926091a4005d29c9bb44" integrity sha1-r2fy3JIlgkFZUJJgkaQAXSnJu0Q= -estraverse@^4.1.0, estraverse@^4.1.1: +estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1: version "4.2.0" resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.2.0.tgz#0dee3fed31fcd469618ce7342099fc1afa0bdb13" integrity sha1-De4/7TH81GlhjOc0IJn8GvoL2xM= -esutils@^1.1.6: - version "1.1.6" - resolved "https://registry.yarnpkg.com/esutils/-/esutils-1.1.6.tgz#c01ccaa9ae4b897c6d0c3e210ae52f3c7a844375" - integrity sha1-wBzKqa5LiXxtDD4hCuUvPHqEQ3U= - esutils@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.2.tgz#0abf4f1caa5bcb1f7a9d8acc6dea4faaa04bac9b" integrity sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs= -event-emitter@~0.3.5: - version "0.3.5" - resolved "https://registry.yarnpkg.com/event-emitter/-/event-emitter-0.3.5.tgz#df8c69eef1647923c7157b9ce83840610b02cc39" - integrity sha1-34xp7vFkeSPHFXuc6DhAYQsCzDk= - dependencies: - d "1" - es5-ext "~0.10.14" - expand-brackets@^2.1.4: version "2.1.4" resolved "https://registry.yarnpkg.com/expand-brackets/-/expand-brackets-2.1.4.tgz#b77735e315ce30f6b6eff0f83b04151a22449622" @@ -1451,6 +1836,15 @@ extend@^3.0.0, extend@~3.0.1: resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444" integrity sha1-p1Xqe8Gt/MWjHOfnYtuq3F5jZEQ= +external-editor@^2.0.4: + version "2.2.0" + resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-2.2.0.tgz#045511cfd8d133f3846673d1047c154e214ad3d5" + integrity sha512-bSn6gvGxKt+b7+6TKEv1ZycHleA7aHhRHyAqJyp5pbUFuYYNIzpZnQDk7AsYckyWdEnTeAnay0aCy2aV6iTk9A== + dependencies: + chardet "^0.4.0" + iconv-lite "^0.4.17" + tmp "^0.0.33" + extglob@^2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/extglob/-/extglob-2.0.4.tgz#ad00fe4dc612a9232e8718711dc5cb5ab0285543" @@ -1478,11 +1872,26 @@ fancy-log@^1.1.0: chalk "^1.1.1" time-stamp "^1.0.0" +fancy-log@^1.3.2: + version "1.3.3" + resolved "https://registry.yarnpkg.com/fancy-log/-/fancy-log-1.3.3.tgz#dbc19154f558690150a23953a0adbd035be45fc7" + integrity sha512-k9oEhlyc0FrVh25qYuSELjr8oxsCoc4/LEZfg2iJJrfEk/tZL9bCoJE47gqAvI2m/AUjluCS4+3I0eTx8n3AEw== + dependencies: + ansi-gray "^0.1.1" + color-support "^1.1.3" + parse-node-version "^1.0.0" + time-stamp "^1.0.0" + fast-deep-equal@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-1.0.0.tgz#96256a3bc975595eb36d82e9929d060d893439ff" integrity sha1-liVqO8l1WV6zbYLpkp0GDYk0Of8= +fast-json-stable-stringify@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" + integrity sha1-1RQsDK7msRifh9OnYREGT4bIu/I= + fast-levenshtein@~1.0.0: version "1.0.7" resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-1.0.7.tgz#0178dcdee023b92905193af0959e8a7639cfdcb9" @@ -1493,13 +1902,20 @@ fast-levenshtein@~2.0.4: resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc= -figures@^1.3.5: - version "1.7.0" - resolved "https://registry.yarnpkg.com/figures/-/figures-1.7.0.tgz#cbe1e3affcf1cd44b80cadfed28dc793a9701d2e" - integrity sha1-y+Hjr/zxzUS4DK3+0o3Hk6lwHS4= +figures@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/figures/-/figures-2.0.0.tgz#3ab1a2d2a62c8bfb431a0c94cb797a2fce27c962" + integrity sha1-OrGi0qYsi/tDGgyUy3l6L84nyWI= dependencies: escape-string-regexp "^1.0.5" - object-assign "^4.1.0" + +file-entry-cache@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-2.0.0.tgz#c392990c3e684783d838b8c84a45d8a048458361" + integrity sha1-w5KZDD5oR4PYOLjISkXYoEhFg2E= + dependencies: + flat-cache "^1.2.1" + object-assign "^4.0.1" fileset@0.2.x: version "0.2.1" @@ -1519,10 +1935,13 @@ fill-range@^4.0.0: repeat-string "^1.6.1" to-regex-range "^2.1.0" -find-index@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/find-index/-/find-index-0.1.1.tgz#675d358b2ca3892d795a1ab47232f8b6e2e0dde4" - integrity sha1-Z101iyyjiS15Whq0cjL4tuLg3eQ= +find-up@^1.0.0: + version "1.1.2" + resolved "https://registry.yarnpkg.com/find-up/-/find-up-1.1.2.tgz#6b2e9822b1a2ce0a60ab64d610eccad53cb24d0f" + integrity sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8= + dependencies: + path-exists "^2.0.0" + pinkie-promise "^2.0.0" findup-sync@^2.0.0: version "2.0.0" @@ -1534,6 +1953,16 @@ findup-sync@^2.0.0: micromatch "^3.0.4" resolve-dir "^1.0.1" +findup-sync@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/findup-sync/-/findup-sync-3.0.0.tgz#17b108f9ee512dfb7a5c7f3c8b27ea9e1a9c08d1" + integrity sha512-YbffarhcicEhOrm4CtrwdKBdCuz576RLdhJDsIfvNtxUuhdRet1qZcsMjqbePtAseKdAnDyM/IyXbu7PRPRLYg== + dependencies: + detect-file "^1.0.0" + is-glob "^4.0.0" + micromatch "^3.0.4" + resolve-dir "^1.0.1" + fined@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/fined/-/fined-1.1.0.tgz#b37dc844b76a2f5e7081e884f7c0ae344f153476" @@ -1545,16 +1974,29 @@ fined@^1.0.1: object.pick "^1.2.0" parse-filepath "^1.0.1" -first-chunk-stream@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/first-chunk-stream/-/first-chunk-stream-1.0.0.tgz#59bfb50cd905f60d7c394cd3d9acaab4e6ad934e" - integrity sha1-Wb+1DNkF9g18OUzT2ayqtOatk04= - flagged-respawn@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/flagged-respawn/-/flagged-respawn-1.0.0.tgz#4e79ae9b2eb38bf86b3bb56bf3e0a56aa5fcabd7" integrity sha1-Tnmumy6zi/hrO7Vr8+ClaqX8q9c= +flat-cache@^1.2.1: + version "1.3.4" + resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-1.3.4.tgz#2c2ef77525cc2929007dfffa1dd314aa9c9dee6f" + integrity sha512-VwyB3Lkgacfik2vhqR4uv2rvebqmDvFu4jlN/C1RzWoJEo8I7z4Q404oiqYCkq41mni8EzQnm95emU9seckwtg== + dependencies: + circular-json "^0.3.1" + graceful-fs "^4.1.2" + rimraf "~2.6.2" + write "^0.2.1" + +flush-write-stream@^1.0.2: + version "1.1.1" + resolved "https://registry.yarnpkg.com/flush-write-stream/-/flush-write-stream-1.1.1.tgz#8dd7d873a1babc207d94ead0c2e0e44276ebf2e8" + integrity sha512-3Z4XhFZ3992uIq0XOqb9AreonueSYphE6oYbpt5+3u06JWklbsPkNv3ZKkP9Bz/r+1MWCaMoSQ28P85+1Yc77w== + dependencies: + inherits "^2.0.3" + readable-stream "^2.3.6" + for-in@^1.0.1, for-in@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80" @@ -1588,24 +2030,62 @@ fragment-cache@^0.2.1: dependencies: map-cache "^0.2.2" -gaze@^0.5.1: - version "0.5.2" - resolved "https://registry.yarnpkg.com/gaze/-/gaze-0.5.2.tgz#40b709537d24d1d45767db5a908689dfe69ac44f" - integrity sha1-QLcJU30k0dRXZ9takIaJ3+aaxE8= +fs-minipass@^1.2.5: + version "1.2.6" + resolved "https://registry.yarnpkg.com/fs-minipass/-/fs-minipass-1.2.6.tgz#2c5cc30ded81282bfe8a0d7c7c1853ddeb102c07" + integrity sha512-crhvyXcMejjv3Z5d2Fa9sf5xLYVCF5O1c71QxbVnbLsmYMBEvDAftewesN/HhY03YRoA7zOMxjNGrF5svGaaeQ== dependencies: - globule "~0.1.0" + minipass "^2.2.1" -generate-function@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/generate-function/-/generate-function-2.0.0.tgz#6858fe7c0969b7d4e9093337647ac79f60dfbe74" - integrity sha1-aFj+fAlpt9TpCTM3ZHrHn2DfvnQ= +fs-mkdirp-stream@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/fs-mkdirp-stream/-/fs-mkdirp-stream-1.0.0.tgz#0b7815fc3201c6a69e14db98ce098c16935259eb" + integrity sha1-C3gV/DIBxqaeFNuYzgmMFpNSWes= + dependencies: + graceful-fs "^4.1.11" + through2 "^2.0.3" + +fs.realpath@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" + integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= + +fsevents@^1.2.7: + version "1.2.9" + resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.2.9.tgz#3f5ed66583ccd6f400b5a00db6f7e861363e388f" + integrity sha512-oeyj2H3EjjonWcFjD5NvZNE9Rqe4UW+nQBU2HNeKw0koVLEFIhtyETyAakeAM3de7Z/SW5kcA+fZUait9EApnw== + dependencies: + nan "^2.12.1" + node-pre-gyp "^0.12.0" + +function-bind@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" + integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== + +functional-red-black-tree@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" + integrity sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc= -generate-object-property@^1.1.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/generate-object-property/-/generate-object-property-1.2.0.tgz#9c0e1c40308ce804f4783618b937fa88f99d50d0" - integrity sha1-nA4cQDCM6AT0eDYYuTf6iPmdUNA= +gauge@~2.7.3: + version "2.7.4" + resolved "https://registry.yarnpkg.com/gauge/-/gauge-2.7.4.tgz#2c03405c7538c39d7eb37b317022e325fb018bf7" + integrity sha1-LANAXHU4w51+s3sxcCLjJfsBi/c= dependencies: - is-property "^1.0.0" + aproba "^1.0.3" + console-control-strings "^1.0.0" + has-unicode "^2.0.0" + object-assign "^4.1.0" + signal-exit "^3.0.0" + string-width "^1.0.1" + strip-ansi "^3.0.1" + wide-align "^1.1.0" + +get-caller-file@^1.0.1: + version "1.0.3" + resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.3.tgz#f978fa4c90d1dfe7ff2d6beda2a515e713bdcf4a" + integrity sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w== get-value@^2.0.3, get-value@^2.0.6: version "2.0.6" @@ -1619,31 +2099,41 @@ getpass@^0.1.1: dependencies: assert-plus "^1.0.0" -glob-stream@^3.1.5: - version "3.1.18" - resolved "https://registry.yarnpkg.com/glob-stream/-/glob-stream-3.1.18.tgz#9170a5f12b790306fdfe598f313f8f7954fd143b" - integrity sha1-kXCl8St5Awb9/lmPMT+PeVT9FDs= +glob-parent@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-3.1.0.tgz#9e6af6299d8d3bd2bd40430832bd113df906c5ae" + integrity sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4= dependencies: - glob "^4.3.1" - glob2base "^0.0.12" - minimatch "^2.0.1" - ordered-read-streams "^0.1.0" - through2 "^0.6.1" - unique-stream "^1.0.0" + is-glob "^3.1.0" + path-dirname "^1.0.0" -glob-watcher@^0.0.6: - version "0.0.6" - resolved "https://registry.yarnpkg.com/glob-watcher/-/glob-watcher-0.0.6.tgz#b95b4a8df74b39c83298b0c05c978b4d9a3b710b" - integrity sha1-uVtKjfdLOcgymLDAXJeLTZo7cQs= +glob-stream@^6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/glob-stream/-/glob-stream-6.1.0.tgz#7045c99413b3eb94888d83ab46d0b404cc7bdde4" + integrity sha1-cEXJlBOz65SIjYOrRtC0BMx73eQ= dependencies: - gaze "^0.5.1" + extend "^3.0.0" + glob "^7.1.1" + glob-parent "^3.1.0" + is-negated-glob "^1.0.0" + ordered-read-streams "^1.0.0" + pumpify "^1.3.5" + readable-stream "^2.1.5" + remove-trailing-separator "^1.0.1" + to-absolute-glob "^2.0.0" + unique-stream "^2.0.2" -glob2base@^0.0.12: - version "0.0.12" - resolved "https://registry.yarnpkg.com/glob2base/-/glob2base-0.0.12.tgz#9d419b3e28f12e83a362164a277055922c9c0d56" - integrity sha1-nUGbPijxLoOjYhZKJ3BVkiycDVY= - dependencies: - find-index "^0.1.1" +glob-watcher@^5.0.3: + version "5.0.3" + resolved "https://registry.yarnpkg.com/glob-watcher/-/glob-watcher-5.0.3.tgz#88a8abf1c4d131eb93928994bc4a593c2e5dd626" + integrity sha512-8tWsULNEPHKQ2MR4zXuzSmqbdyV5PtwwCaWSGQ1WwHsJ07ilNeN1JB8ntxhckbnpSHaf9dXFUHzIWvm1I13dsg== + dependencies: + anymatch "^2.0.0" + async-done "^1.2.0" + chokidar "^2.0.0" + is-negated-glob "^1.0.0" + just-debounce "^1.0.0" + object.defaults "^1.1.0" glob@3.2.11: version "3.2.11" @@ -1664,24 +2154,17 @@ glob@5.x, glob@^5.0.15: once "^1.3.0" path-is-absolute "^1.0.0" -glob@^4.3.1: - version "4.5.3" - resolved "https://registry.yarnpkg.com/glob/-/glob-4.5.3.tgz#c6cb73d3226c1efef04de3c56d012f03377ee15f" - integrity sha1-xstz0yJsHv7wTePFbQEvAzd+4V8= +glob@^7.1.1, glob@^7.1.2, glob@^7.1.3: + version "7.1.4" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.4.tgz#aa608a2f6c577ad357e1ae5a5c26d9a8d1969255" + integrity sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A== dependencies: + fs.realpath "^1.0.0" inflight "^1.0.4" inherits "2" - minimatch "^2.0.1" + minimatch "^3.0.4" once "^1.3.0" - -glob@~3.1.21: - version "3.1.21" - resolved "https://registry.yarnpkg.com/glob/-/glob-3.1.21.tgz#d29e0a055dea5138f4d07ed40e8982e83c2066cd" - integrity sha1-0p4KBV3qUTj00H7UDomC6DwgZs0= - dependencies: - graceful-fs "~1.2.0" - inherits "1" - minimatch "~0.2.11" + path-is-absolute "^1.0.0" global-modules@^1.0.0: version "1.0.0" @@ -1703,24 +2186,10 @@ global-prefix@^1.0.1: is-windows "^1.0.1" which "^1.2.14" -globals@^8.0.0: - version "8.18.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-8.18.0.tgz#93d4a62bdcac38cfafafc47d6b034768cb0ffcb4" - integrity sha1-k9SmK9ysOM+vr8R9awNHaMsP/LQ= - -globals@^9.18.0: - version "9.18.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-9.18.0.tgz#aa3896b3e69b487f17e31ed2143d69a8e30c2d8a" - integrity sha512-S0nG3CLEQiY/ILxqtztTWH/3iRRdyBLw6KMDxnKMchrtbj2OFmehVh0WUCfW3DUrIgx/qFrJPICrq4Z4sTR9UQ== - -globule@~0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/globule/-/globule-0.1.0.tgz#d9c8edde1da79d125a151b79533b978676346ae5" - integrity sha1-2cjt3h2nnRJaFRt5UzuXhnY0auU= - dependencies: - glob "~3.1.21" - lodash "~1.0.1" - minimatch "~0.2.11" +globals@^11.0.1, globals@^11.1.0: + version "11.12.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" + integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== glogg@^1.0.0: version "1.0.0" @@ -1729,44 +2198,58 @@ glogg@^1.0.0: dependencies: sparkles "^1.0.0" -graceful-fs@^3.0.0: - version "3.0.11" - resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-3.0.11.tgz#7613c778a1afea62f25c630a086d7f3acbbdd818" - integrity sha1-dhPHeKGv6mLyXGMKCG1/Osu92Bg= - dependencies: - natives "^1.1.0" - -graceful-fs@~1.2.0: - version "1.2.3" - resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-1.2.3.tgz#15a4806a57547cb2d2dbf27f42e89a8c3451b364" - integrity sha1-FaSAaldUfLLS2/J/QuiajDRRs2Q= +graceful-fs@^4.0.0, graceful-fs@^4.1.11, graceful-fs@^4.1.2, graceful-fs@^4.1.6: + version "4.2.0" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.0.tgz#8d8fdc73977cb04104721cb53666c1ca64cd328b" + integrity sha512-jpSvDPV4Cq/bgtpndIWbI5hmYxhQGHPC4d4cqBPb4DLniCfhJokdXhwhaDuLBGLQdvvRum/UiX6ECVIPvDXqdg== growl@1.9.2: version "1.9.2" resolved "https://registry.yarnpkg.com/growl/-/growl-1.9.2.tgz#0ea7743715db8d8de2c5ede1775e1b45ac85c02f" integrity sha1-Dqd0NxXbjY3ixe3hd14bRayFwC8= -gulp-babel@^6.1.2: - version "6.1.2" - resolved "https://registry.yarnpkg.com/gulp-babel/-/gulp-babel-6.1.2.tgz#7c0176e4ba3f244c60588a0c4b320a45d1adefce" - integrity sha1-fAF25Lo/JExgWIoMSzIKRdGt784= +gulp-babel@^8.0.0: + version "8.0.0" + resolved "https://registry.yarnpkg.com/gulp-babel/-/gulp-babel-8.0.0.tgz#e0da96f4f2ec4a88dd3a3030f476e38ab2126d87" + integrity sha512-oomaIqDXxFkg7lbpBou/gnUkX51/Y/M2ZfSjL2hdqXTAlSWZcgZtd2o0cOH0r/eE8LWD0+Q/PsLsr2DKOoqToQ== dependencies: - babel-core "^6.0.2" - gulp-util "^3.0.0" - object-assign "^4.0.1" - replace-ext "0.0.1" + plugin-error "^1.0.1" + replace-ext "^1.0.0" through2 "^2.0.0" vinyl-sourcemaps-apply "^0.2.0" -gulp-eslint@^0.15.0: - version "0.15.0" - resolved "https://registry.yarnpkg.com/gulp-eslint/-/gulp-eslint-0.15.0.tgz#bce6ac74822f0b0ed41e816f959b2aee16df00bc" - integrity sha1-vOasdIIvCw7UHoFvlZsq7hbfALw= +gulp-cli@^2.2.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/gulp-cli/-/gulp-cli-2.2.0.tgz#5533126eeb7fe415a7e3e84a297d334d5cf70ebc" + integrity sha512-rGs3bVYHdyJpLqR0TUBnlcZ1O5O++Zs4bA0ajm+zr3WFCfiSLjGwoCBqFs18wzN+ZxahT9DkOK5nDf26iDsWjA== dependencies: - bufferstreams "1.0.2" - eslint "^0.24.0" - gulp-util "^3.0.6" - object-assign "^3.0.0" + ansi-colors "^1.0.1" + archy "^1.0.0" + array-sort "^1.0.0" + color-support "^1.1.3" + concat-stream "^1.6.0" + copy-props "^2.0.1" + fancy-log "^1.3.2" + gulplog "^1.0.0" + interpret "^1.1.0" + isobject "^3.0.1" + liftoff "^3.1.0" + matchdep "^2.0.0" + mute-stdout "^1.0.0" + pretty-hrtime "^1.0.0" + replace-homedir "^1.0.0" + semver-greatest-satisfied-range "^1.1.0" + v8flags "^3.0.1" + yargs "^7.1.0" + +gulp-eslint@4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/gulp-eslint/-/gulp-eslint-4.0.2.tgz#18a2a6768e4404cbf3e203239cb57474168fa606" + integrity sha512-fcFUQzFsN6dJ6KZlG+qPOEkqfcevRUXgztkYCvhNvJeSvOicC8ucutN4qR/ID8LmNZx9YPIkBzazTNnVvbh8wg== + dependencies: + eslint "^4.0.0" + fancy-log "^1.3.2" + plugin-error "^1.0.0" gulp-exclude-gitignore@^1.0.0: version "1.2.0" @@ -1821,7 +2304,7 @@ gulp-plumber@^1.1.0: gulp-util "^3" through2 "^2" -gulp-util@^3, gulp-util@^3.0.0, gulp-util@^3.0.1, gulp-util@^3.0.6: +gulp-util@^3, gulp-util@^3.0.0, gulp-util@^3.0.1: version "3.0.8" resolved "https://registry.yarnpkg.com/gulp-util/-/gulp-util-3.0.8.tgz#0054e1e744502e27c04c187c3ecc505dd54bbb4f" integrity sha1-AFTh50RQLifATBh8PsxQXdVLu08= @@ -1845,24 +2328,15 @@ gulp-util@^3, gulp-util@^3.0.0, gulp-util@^3.0.1, gulp-util@^3.0.6: through2 "^2.0.0" vinyl "^0.5.0" -gulp@^3.9.1: - version "3.9.1" - resolved "https://registry.yarnpkg.com/gulp/-/gulp-3.9.1.tgz#571ce45928dd40af6514fc4011866016c13845b4" - integrity sha1-VxzkWSjdQK9lFPxAEYZgFsE4RbQ= +gulp@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/gulp/-/gulp-4.0.2.tgz#543651070fd0f6ab0a0650c6a3e6ff5a7cb09caa" + integrity sha512-dvEs27SCZt2ibF29xYgmnwwCYZxdxhQ/+LFWlbAW8y7jt68L/65402Lz3+CKy0Ov4rOs+NERmDq7YlZaDqUIfA== dependencies: - archy "^1.0.0" - chalk "^1.0.0" - deprecated "^0.0.1" - gulp-util "^3.0.0" - interpret "^1.0.0" - liftoff "^2.1.0" - minimist "^1.1.0" - orchestrator "^0.3.0" - pretty-hrtime "^1.0.0" - semver "^4.1.0" - tildify "^1.0.0" - v8flags "^2.0.2" - vinyl-fs "^0.3.0" + glob-watcher "^5.0.3" + gulp-cli "^2.2.0" + undertaker "^1.2.1" + vinyl-fs "^3.0.0" gulplog@^1.0.0: version "1.0.0" @@ -1919,6 +2393,16 @@ has-gulplog@^0.1.0: dependencies: sparkles "^1.0.0" +has-symbols@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.0.tgz#ba1a8f1af2a0fc39650f5c850367704122063b44" + integrity sha1-uhqPGvKg/DllD1yFA2dwQSIGO0Q= + +has-unicode@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/has-unicode/-/has-unicode-2.0.1.tgz#e0e6fe6a28cf51138855e086d1691e771de2a8b9" + integrity sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk= + has-value@^0.3.1: version "0.3.1" resolved "https://registry.yarnpkg.com/has-value/-/has-value-0.3.1.tgz#7b1f58bada62ca827ec0a2078025654845995e1f" @@ -1965,14 +2449,6 @@ hoek@4.x.x: resolved "https://registry.yarnpkg.com/hoek/-/hoek-4.2.0.tgz#72d9d0754f7fe25ca2d01ad8f8f9a9449a89526d" integrity sha512-v0XCLxICi9nPfYrS9RL8HbYnXi9obYAeLbSP00BmnZwCK9+Ih9WOjoZ8YoHCoav2csqn4FOz4Orldsy2dmDwmQ== -home-or-tmp@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/home-or-tmp/-/home-or-tmp-2.0.0.tgz#e36c3f2d2cae7d746a857e38d18d5f32a7882db8" - integrity sha1-42w/LSyufXRqhX440Y1fMqeILbg= - dependencies: - os-homedir "^1.0.0" - os-tmpdir "^1.0.1" - homedir-polyfill@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/homedir-polyfill/-/homedir-polyfill-1.0.1.tgz#4c2bbc8a758998feebf5ed68580f76d46768b4bc" @@ -1980,6 +2456,11 @@ homedir-polyfill@^1.0.1: dependencies: parse-passwd "^1.0.0" +hosted-git-info@^2.1.4: + version "2.7.1" + resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.7.1.tgz#97f236977bd6e125408930ff6de3eec6281ec047" + integrity sha512-7T/BxH19zbcCTa8XkMlbK5lTo1WtgkFi3GvdWEyNuc4Vex7/9Dqbnpsf4JMydcfj9HCg4zUWFTL3Za6lapg5/w== + htmlencode@^0.0.4: version "0.0.4" resolved "https://registry.yarnpkg.com/htmlencode/-/htmlencode-0.0.4.tgz#f7e2d6afbe18a87a78e63ba3308e753766740e3f" @@ -1994,6 +2475,30 @@ http-signature@~1.2.0: jsprim "^1.2.2" sshpk "^1.7.0" +iconv-lite@^0.4.17, iconv-lite@^0.4.4: + version "0.4.24" + resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" + integrity sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA== + dependencies: + safer-buffer ">= 2.1.2 < 3" + +ignore-walk@^3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/ignore-walk/-/ignore-walk-3.0.1.tgz#a83e62e7d272ac0e3b551aaa82831a19b69f82f8" + integrity sha512-DTVlMx3IYPe0/JJcYP7Gxg7ttZZu3IInhuEhbchuqneY9wWe5Ojy2mXLBaQFUQmo0AW2r3qG7m1mg86js+gnlQ== + dependencies: + minimatch "^3.0.4" + +ignore@^3.3.3: + version "3.3.10" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.10.tgz#0a97fb876986e8081c631160f8f9f389157f0043" + integrity sha512-Pgs951kaMm5GXP7MOvxERINe3gsaVjUWFm+UZPSq9xYriQAksyhg0csnS0KXSNRD5NmNdapXEpjxG49+AKh/ug== + +imurmurhash@^0.1.4: + version "0.1.4" + resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" + integrity sha1-khi5srkoojixPcT7a21XbyMUU+o= + inflight@^1.0.4: version "1.0.6" resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" @@ -2002,39 +2507,45 @@ inflight@^1.0.4: once "^1.3.0" wrappy "1" -inherits@1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/inherits/-/inherits-1.0.2.tgz#ca4309dadee6b54cc0b8d247e8d7c7a0975bdc9b" - integrity sha1-ykMJ2t7mtUzAuNJH6NfHoJdb3Js= - inherits@2, inherits@^2.0.3, inherits@~2.0.1, inherits@~2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de" integrity sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4= -ini@^1.3.4: +inherits@^2.0.1: + version "2.0.4" + resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" + integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== + +ini@^1.3.4, ini@~1.3.0: version "1.3.5" resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.5.tgz#eee25f56db1c9ec6085e0c22778083f596abf927" integrity sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw== -inquirer@^0.8.2: - version "0.8.5" - resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-0.8.5.tgz#dbd740cf6ca3b731296a63ce6f6d961851f336df" - integrity sha1-29dAz2yjtzEpamPOb22WGFHzNt8= - dependencies: - ansi-regex "^1.1.1" - chalk "^1.0.0" - cli-width "^1.0.1" - figures "^1.3.5" - lodash "^3.3.1" - readline2 "^0.1.1" - rx "^2.4.3" +inquirer@^3.0.6: + version "3.3.0" + resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-3.3.0.tgz#9dd2f2ad765dcab1ff0443b491442a20ba227dc9" + integrity sha512-h+xtnyk4EwKvFWHrUYsWErEVR+igKtLdchu+o0Z1RL7VU/jVMFbYir2bp6bAj8efFNxWqHX0dIss6fJQ+/+qeQ== + dependencies: + ansi-escapes "^3.0.0" + chalk "^2.0.0" + cli-cursor "^2.1.0" + cli-width "^2.0.0" + external-editor "^2.0.4" + figures "^2.0.0" + lodash "^4.3.0" + mute-stream "0.0.7" + run-async "^2.2.0" + rx-lite "^4.0.8" + rx-lite-aggregates "^4.0.8" + string-width "^2.1.0" + strip-ansi "^4.0.0" through "^2.3.6" -interpret@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.1.0.tgz#7ed1b1410c6a0e0f78cf95d3b8440c63f78b8614" - integrity sha1-ftGxQQxqDg94z5XTuEQMY/eLhhQ= +interpret@^1.1.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.2.0.tgz#d5061a6224be58e8083985f5014d844359576296" + integrity sha512-mT34yGKMNceBQUoVn7iCDKDntA7SC6gycMAWzGx1z/CMCTV7b2AAtXlo3nRyHZ1FelRkQbQjprHSYGwzLtkVbw== invariant@^2.2.2: version "2.2.2" @@ -2043,6 +2554,11 @@ invariant@^2.2.2: dependencies: loose-envify "^1.0.0" +invert-kv@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-1.0.0.tgz#104a8e4aaca6d3d8cd157a8ef8bfab2d7a3ffdb6" + integrity sha1-EEqOSqym09jNFXqO+L+rLXo//bY= + irregular-plurals@^1.0.0: version "1.4.0" resolved "https://registry.yarnpkg.com/irregular-plurals/-/irregular-plurals-1.4.0.tgz#2ca9b033651111855412f16be5d77c62a458a766" @@ -2070,6 +2586,18 @@ is-accessor-descriptor@^1.0.0: dependencies: kind-of "^6.0.0" +is-arrayish@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" + integrity sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0= + +is-binary-path@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/is-binary-path/-/is-binary-path-1.0.1.tgz#75f16642b480f187a711c814161fd3a4a7655898" + integrity sha1-dfFmQrSA8YenEcgUFh/TpKdlWJg= + dependencies: + binary-extensions "^1.0.0" + is-buffer@^1.1.5: version "1.1.5" resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.5.tgz#1f3b26ef613b214b88cbca23cc6c01d87961eecc" @@ -2119,18 +2647,23 @@ is-extendable@^1.0.1: dependencies: is-plain-object "^2.0.4" -is-extglob@^2.1.0: +is-extglob@^2.1.0, is-extglob@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" integrity sha1-qIwCU1eR8C7TfHahueqXc8gz+MI= -is-finite@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-finite/-/is-finite-1.0.2.tgz#cc6677695602be550ef11e8b4aa6305342b6d0aa" - integrity sha1-zGZ3aVYCvlUO8R6LSqYwU0K20Ko= +is-fullwidth-code-point@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz#ef9e31386f031a7f0d643af82fde50c457ef00cb" + integrity sha1-754xOG8DGn8NZDr4L95QxFfvAMs= dependencies: number-is-nan "^1.0.0" +is-fullwidth-code-point@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" + integrity sha1-o7MKXE8ZkYMWeqq5O+764937ZU8= + is-glob@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-3.1.0.tgz#7ba5ae24217804ac70707b96922567486cc3e84a" @@ -2138,15 +2671,17 @@ is-glob@^3.1.0: dependencies: is-extglob "^2.1.0" -is-my-json-valid@^2.10.0: - version "2.16.1" - resolved "https://registry.yarnpkg.com/is-my-json-valid/-/is-my-json-valid-2.16.1.tgz#5a846777e2c2620d1e69104e5d3a03b1f6088f11" - integrity sha512-ochPsqWS1WXj8ZnMIV0vnNXooaMhp7cyL4FMSIPKTtnV0Ha/T19G2b9kkhcNsabV9bxYkze7/aLZJb/bYuFduQ== +is-glob@^4.0.0: + version "4.0.1" + resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.1.tgz#7567dbe9f2f5e2467bc77ab83c4a29482407a5dc" + integrity sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg== dependencies: - generate-function "^2.0.0" - generate-object-property "^1.1.0" - jsonpointer "^4.0.0" - xtend "^4.0.0" + is-extglob "^2.1.1" + +is-negated-glob@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-negated-glob/-/is-negated-glob-1.0.0.tgz#6910bca5da8c95e784b5751b976cf5a10fee36d2" + integrity sha1-aRC8pdqMleeEtXUbl2z1oQ/uNtI= is-number@^3.0.0: version "3.0.0" @@ -2174,10 +2709,10 @@ is-plain-object@^2.0.1, is-plain-object@^2.0.3, is-plain-object@^2.0.4: dependencies: isobject "^3.0.1" -is-property@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-property/-/is-property-1.0.2.tgz#57fe1c4e48474edd65b09911f26b1cd4095dda84" - integrity sha1-V/4cTkhHTt1lsJkR8msc1Ald2oQ= +is-promise@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.1.0.tgz#79a2a9ece7f096e80f36d2b2f3bc16c1ff4bf3fa" + integrity sha1-eaKp7OfwlugPNtKy87wWwf9L8/o= is-relative@^1.0.0: version "1.0.0" @@ -2186,6 +2721,11 @@ is-relative@^1.0.0: dependencies: is-unc-path "^1.0.0" +is-resolvable@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/is-resolvable/-/is-resolvable-1.1.0.tgz#fb18f87ce1feb925169c9a407c19318a3206ed88" + integrity sha512-qgDYXFSR5WvEfuS5dMj6oTMEbrrSaM0CrFk2Yiq/gXnBvD9pMa2jGXxyhGLfvhZpuMZe18CJpFxAt3CRs42NMg== + is-typedarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" @@ -2198,11 +2738,16 @@ is-unc-path@^1.0.0: dependencies: unc-path-regex "^0.1.2" -is-utf8@^0.2.0: +is-utf8@^0.2.0, is-utf8@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/is-utf8/-/is-utf8-0.2.1.tgz#4b0da1442104d1b336340e80797e865cf39f7d72" integrity sha1-Sw2hRCEE0bM2NA6AeX6GXPOffXI= +is-valid-glob@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-valid-glob/-/is-valid-glob-1.0.0.tgz#29bf3eff701be2d4d315dbacc39bc39fe8f601aa" + integrity sha1-Kb8+/3Ab4tTTFdusw5vDn+j2Aao= + is-windows@^1.0.1, is-windows@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/is-windows/-/is-windows-1.0.2.tgz#d1850eb9791ecd18e6182ce12a30f396634bb19d" @@ -2296,12 +2841,22 @@ jade@0.26.3: commander "0.6.1" mkdirp "0.3.0" +js-levenshtein@^1.1.3: + version "1.1.6" + resolved "https://registry.yarnpkg.com/js-levenshtein/-/js-levenshtein-1.1.6.tgz#c6cee58eb3550372df8deb85fad5ce66ce01d59d" + integrity sha512-X2BB11YZtrRqY4EnQcLX5Rh373zbK4alC1FW7D7MBhL2gtcC17cTnr6DmfHZeS0s2rTHjUTMMHfG7gO8SSdw+g== + js-tokens@^3.0.0, js-tokens@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b" integrity sha1-mGbfOVECEw449/mWvOtlRDIJwls= -js-yaml@3.x, js-yaml@^3.2.5: +js-tokens@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" + integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== + +js-yaml@3.x, js-yaml@^3.9.1: version "3.13.1" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.13.1.tgz#aff151b30bfdfa8e49e05da22e7415e9dfa37847" integrity sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw== @@ -2314,10 +2869,10 @@ jsbn@~0.1.0: resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513" integrity sha1-peZUwuWi3rXyAdls77yoDA7y9RM= -jsesc@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-1.3.0.tgz#46c3fec8c1892b12b0833db9bc7622176dbab34b" - integrity sha1-RsP+yMGJKxKwgz25vHYiF226s0s= +jsesc@^2.5.1: + version "2.5.2" + resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.2.tgz#80564d2e483dacf6e8ef209650a67df3f0c283a4" + integrity sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA== jsesc@~0.5.0: version "0.5.0" @@ -2334,6 +2889,11 @@ json-schema@0.2.3: resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" integrity sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM= +json-stable-stringify-without-jsonify@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" + integrity sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE= + json-stable-stringify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz#9a759d39c5f2ff503fd5300646ed445f88c4f9af" @@ -2346,21 +2906,18 @@ json-stringify-safe@^5.0.1, json-stringify-safe@~5.0.1: resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" integrity sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus= -json5@^0.5.1: - version "0.5.1" - resolved "https://registry.yarnpkg.com/json5/-/json5-0.5.1.tgz#1eade7acc012034ad84e2396767ead9fa5495821" - integrity sha1-Hq3nrMASA0rYTiOWdn6tn6VJWCE= +json5@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/json5/-/json5-2.1.0.tgz#e7a0c62c48285c628d20a10b85c89bb807c32850" + integrity sha512-8Mh9h6xViijj36g7Dxi+Y4S6hNGV96vcJZr/SrlHh1LR/pEn/8j/+qIBbs44YKl69Lrfctp4QD+AdWLTMqEZAQ== + dependencies: + minimist "^1.2.0" jsonify@~0.0.0: version "0.0.0" resolved "https://registry.yarnpkg.com/jsonify/-/jsonify-0.0.0.tgz#2c74b6ee41d93ca51b7b5aaee8f503631d252a73" integrity sha1-LHS27kHZPKUbe1qu6PUDYx0lKnM= -jsonpointer@^4.0.0: - version "4.0.1" - resolved "https://registry.yarnpkg.com/jsonpointer/-/jsonpointer-4.0.1.tgz#4fd92cb34e0e9db3c89c8622ecf51f9b978c6cb9" - integrity sha1-T9kss04OnbPInIYi7PUfm5eMbLk= - jsprim@^1.2.2: version "1.4.1" resolved "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.1.tgz#313e66bc1e5cc06e438bc1b7499c2e5c56acb6a2" @@ -2371,6 +2928,11 @@ jsprim@^1.2.2: json-schema "0.2.3" verror "1.10.0" +just-debounce@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/just-debounce/-/just-debounce-1.0.0.tgz#87fccfaeffc0b68cd19d55f6722943f929ea35ea" + integrity sha1-h/zPrv/AtozRnVX2cilD+SnqNeo= + just-extend@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/just-extend/-/just-extend-3.0.0.tgz#cee004031eaabf6406da03a7b84e4fe9d78ef288" @@ -2390,7 +2952,7 @@ kind-of@^4.0.0: dependencies: is-buffer "^1.1.5" -kind-of@^5.0.0: +kind-of@^5.0.0, kind-of@^5.0.2: version "5.1.0" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-5.1.0.tgz#729c91e2d857b7a419a1f9aa65685c4c33f5845d" integrity sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw== @@ -2400,15 +2962,36 @@ kind-of@^6.0.0, kind-of@^6.0.2: resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.2.tgz#01146b36a6218e64e58f3a8d66de5d7fc6f6d051" integrity sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA== -levn@~0.2.5: - version "0.2.5" - resolved "https://registry.yarnpkg.com/levn/-/levn-0.2.5.tgz#ba8d339d0ca4a610e3a3f145b9caf48807155054" - integrity sha1-uo0znQykphDjo/FFucr0iAcVUFQ= +last-run@^1.1.0: + version "1.1.1" + resolved "https://registry.yarnpkg.com/last-run/-/last-run-1.1.1.tgz#45b96942c17b1c79c772198259ba943bebf8ca5b" + integrity sha1-RblpQsF7HHnHchmCWbqUO+v4yls= dependencies: - prelude-ls "~1.1.0" - type-check "~0.3.1" + default-resolution "^2.0.0" + es6-weak-map "^2.0.1" + +lazystream@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/lazystream/-/lazystream-1.0.0.tgz#f6995fe0f820392f61396be89462407bb77168e4" + integrity sha1-9plf4PggOS9hOWvolGJAe7dxaOQ= + dependencies: + readable-stream "^2.0.5" -levn@~0.3.0: +lcid@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/lcid/-/lcid-1.0.0.tgz#308accafa0bc483a3867b4b6f2b9506251d1b835" + integrity sha1-MIrMr6C8SDo4Z7S28rlQYlHRuDU= + dependencies: + invert-kv "^1.0.0" + +lead@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/lead/-/lead-1.0.0.tgz#6f14f99a37be3a9dd784f5495690e5903466ee42" + integrity sha1-bxT5mje+Op3XhPVJVpDlkDRm7kI= + dependencies: + flush-write-stream "^1.0.2" + +levn@^0.3.0, levn@~0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/levn/-/levn-0.3.0.tgz#3b09924edf9f083c0490fdd4c0bc4421e04764ee" integrity sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4= @@ -2416,13 +2999,21 @@ levn@~0.3.0: prelude-ls "~1.1.2" type-check "~0.3.2" -liftoff@^2.1.0: - version "2.5.0" - resolved "https://registry.yarnpkg.com/liftoff/-/liftoff-2.5.0.tgz#2009291bb31cea861bbf10a7c15a28caf75c31ec" - integrity sha1-IAkpG7Mc6oYbvxCnwVooyvdcMew= +levn@~0.2.5: + version "0.2.5" + resolved "https://registry.yarnpkg.com/levn/-/levn-0.2.5.tgz#ba8d339d0ca4a610e3a3f145b9caf48807155054" + integrity sha1-uo0znQykphDjo/FFucr0iAcVUFQ= + dependencies: + prelude-ls "~1.1.0" + type-check "~0.3.1" + +liftoff@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/liftoff/-/liftoff-3.1.0.tgz#c9ba6081f908670607ee79062d700df062c52ed3" + integrity sha512-DlIPlJUkCV0Ips2zf2pJP0unEoT1kwYhiiPUGF3s/jtxTCjziNLoiVVh+jqWOWeFi6mmwQ5fNxvAUyPad4Dfog== dependencies: extend "^3.0.0" - findup-sync "^2.0.0" + findup-sync "^3.0.0" fined "^1.0.1" flagged-respawn "^1.0.0" is-plain-object "^2.0.4" @@ -2430,32 +3021,22 @@ liftoff@^2.1.0: rechoir "^0.6.2" resolve "^1.1.7" -lodash._baseassign@^3.0.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/lodash._baseassign/-/lodash._baseassign-3.2.0.tgz#8c38a099500f215ad09e59f1722fd0c52bfe0a4e" - integrity sha1-jDigmVAPIVrQnlnxci/QxSv+Ck4= +load-json-file@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-1.1.0.tgz#956905708d58b4bab4c2261b04f59f31c99374c0" + integrity sha1-lWkFcI1YtLq0wiYbBPWfMcmTdMA= dependencies: - lodash._basecopy "^3.0.0" - lodash.keys "^3.0.0" + graceful-fs "^4.1.2" + parse-json "^2.2.0" + pify "^2.0.0" + pinkie-promise "^2.0.0" + strip-bom "^2.0.0" lodash._basecopy@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/lodash._basecopy/-/lodash._basecopy-3.0.1.tgz#8da0e6a876cf344c0ad8a54882111dd3c5c7ca36" integrity sha1-jaDmqHbPNEwK2KVIghEd08XHyjY= -lodash._baseflatten@^3.0.0: - version "3.1.4" - resolved "https://registry.yarnpkg.com/lodash._baseflatten/-/lodash._baseflatten-3.1.4.tgz#0770ff80131af6e34f3b511796a7ba5214e65ff7" - integrity sha1-B3D/gBMa9uNPO1EXlqe6UhTmX/c= - dependencies: - lodash.isarguments "^3.0.0" - lodash.isarray "^3.0.0" - -lodash._basefor@^3.0.0: - version "3.0.3" - resolved "https://registry.yarnpkg.com/lodash._basefor/-/lodash._basefor-3.0.3.tgz#7550b4e9218ef09fad24343b612021c79b4c20c2" - integrity sha1-dVC06SGO8J+tJDQ7YSAhx5tMIMI= - lodash._basetostring@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/lodash._basetostring/-/lodash._basetostring-3.0.1.tgz#d1861d877f824a52f669832dcaf3ee15566a07d5" @@ -2466,20 +3047,6 @@ lodash._basevalues@^3.0.0: resolved "https://registry.yarnpkg.com/lodash._basevalues/-/lodash._basevalues-3.0.0.tgz#5b775762802bde3d3297503e26300820fdf661b7" integrity sha1-W3dXYoAr3j0yl1A+JjAIIP32Ybc= -lodash._bindcallback@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/lodash._bindcallback/-/lodash._bindcallback-3.0.1.tgz#e531c27644cf8b57a99e17ed95b35c748789392e" - integrity sha1-5THCdkTPi1epnhftlbNcdIeJOS4= - -lodash._createassigner@^3.0.0: - version "3.1.1" - resolved "https://registry.yarnpkg.com/lodash._createassigner/-/lodash._createassigner-3.1.1.tgz#838a5bae2fdaca63ac22dee8e19fa4e6d6970b11" - integrity sha1-g4pbri/aymOsIt7o4Z+k5taXCxE= - dependencies: - lodash._bindcallback "^3.0.0" - lodash._isiterateecall "^3.0.0" - lodash.restparam "^3.0.0" - lodash._getnative@^3.0.0: version "3.9.1" resolved "https://registry.yarnpkg.com/lodash._getnative/-/lodash._getnative-3.9.1.tgz#570bc7dede46d61cdcde687d65d3eecbaa3aaff5" @@ -2490,19 +3057,6 @@ lodash._isiterateecall@^3.0.0: resolved "https://registry.yarnpkg.com/lodash._isiterateecall/-/lodash._isiterateecall-3.0.9.tgz#5203ad7ba425fae842460e696db9cf3e6aac057c" integrity sha1-UgOte6Ql+uhCRg5pbbnPPmqsBXw= -lodash._pickbyarray@^3.0.0: - version "3.0.2" - resolved "https://registry.yarnpkg.com/lodash._pickbyarray/-/lodash._pickbyarray-3.0.2.tgz#1f898d9607eb560b0e167384b77c7c6d108aa4c5" - integrity sha1-H4mNlgfrVgsOFnOEt3x8bRCKpMU= - -lodash._pickbycallback@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/lodash._pickbycallback/-/lodash._pickbycallback-3.0.0.tgz#ff61b9a017a7b3af7d30e6c53de28afa19b8750a" - integrity sha1-/2G5oBens699MObFPeKK+hm4dQo= - dependencies: - lodash._basefor "^3.0.0" - lodash.keysin "^3.0.0" - lodash._reescape@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/lodash._reescape/-/lodash._reescape-3.0.0.tgz#2b1d6f5dfe07c8a355753e5f27fac7f1cde1616a" @@ -2523,15 +3077,6 @@ lodash._root@^3.0.0: resolved "https://registry.yarnpkg.com/lodash._root/-/lodash._root-3.0.1.tgz#fba1c4524c19ee9a5f8136b4609f017cf4ded692" integrity sha1-+6HEUkwZ7ppfgTa0YJ8BfPTe1pI= -lodash.assign@^3.2.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/lodash.assign/-/lodash.assign-3.2.0.tgz#3ce9f0234b4b2223e296b8fa0ac1fee8ebca64fa" - integrity sha1-POnwI0tLIiPilrj6CsH+6OvKZPo= - dependencies: - lodash._baseassign "^3.0.0" - lodash._createassigner "^3.0.0" - lodash.keys "^3.0.0" - lodash.escape@^3.0.0: version "3.2.0" resolved "https://registry.yarnpkg.com/lodash.escape/-/lodash.escape-3.2.0.tgz#995ee0dc18c1b48cc92effae71a10aab5b487698" @@ -2563,25 +3108,6 @@ lodash.keys@^3.0.0: lodash.isarguments "^3.0.0" lodash.isarray "^3.0.0" -lodash.keysin@^3.0.0: - version "3.0.8" - resolved "https://registry.yarnpkg.com/lodash.keysin/-/lodash.keysin-3.0.8.tgz#22c4493ebbedb1427962a54b445b2c8a767fb47f" - integrity sha1-IsRJPrvtsUJ5YqVLRFssinZ/tH8= - dependencies: - lodash.isarguments "^3.0.0" - lodash.isarray "^3.0.0" - -lodash.pick@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/lodash.pick/-/lodash.pick-3.1.0.tgz#f252a855b2046b61bcd3904b26f76bd2efc65550" - integrity sha1-8lKoVbIEa2G805BLJvdr0u/GVVA= - dependencies: - lodash._baseflatten "^3.0.0" - lodash._bindcallback "^3.0.0" - lodash._pickbyarray "^3.0.0" - lodash._pickbycallback "^3.0.0" - lodash.restparam "^3.0.0" - lodash.restparam@^3.0.0: version "3.6.1" resolved "https://registry.yarnpkg.com/lodash.restparam/-/lodash.restparam-3.6.1.tgz#936a4e309ef330a7645ed4145986c85ae5b20805" @@ -2615,7 +3141,7 @@ lodash@3.6.*: resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.6.0.tgz#5266a8f49dd989be4f9f681b6f2a0c55285d0d9a" integrity sha1-Umao9J3Zib5Pn2gbbyoMVShdDZo= -lodash@^3.10.1, lodash@^3.3.1: +lodash@^3.10.1: version "3.10.1" resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.10.1.tgz#5bf45e8e49ba4189e17d482789dfd15bd140b7b6" integrity sha1-W/Rejkm6QYnhfUgnid/RW9FAt7Y= @@ -2625,16 +3151,11 @@ lodash@^4.0.0, lodash@^4.17.4: resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.4.tgz#78203a4d1c328ae1d86dca6460e369b57f4055ae" integrity sha1-eCA6TRwyiuHYbcpkYONptX9AVa4= -lodash@^4.17.11: +lodash@^4.17.11, lodash@^4.3.0: version "4.17.11" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.11.tgz#b39ea6229ef607ecd89e2c8df12536891cac9b8d" integrity sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg== -lodash@~1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-1.0.2.tgz#8f57560c83b59fc270bd3d561b690043430e2551" - integrity sha1-j1dWDIO1n8JwvT1WG2kAQ0MOJVE= - lolex@^2.3.2: version "2.3.2" resolved "https://registry.yarnpkg.com/lolex/-/lolex-2.3.2.tgz#85f9450425103bf9e7a60668ea25dc43274ca807" @@ -2657,6 +3178,14 @@ lru-cache@2: resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-2.7.3.tgz#6d4524e8b955f95d4f5b58851ce21dd72fb4e952" integrity sha1-bUUk6LlV+V1PW1iFHOId1y+06VI= +lru-cache@^4.0.1: + version "4.1.5" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.5.tgz#8bbe50ea85bed59bc9e33dcab8235ee9bcf443cd" + integrity sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g== + dependencies: + pseudomap "^1.0.2" + yallist "^2.1.2" + make-iterator@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/make-iterator/-/make-iterator-1.0.1.tgz#29b33f312aa8f547c4a5e490f56afcec99133ad6" @@ -2676,7 +3205,17 @@ map-visit@^1.0.0: dependencies: object-visit "^1.0.0" -micromatch@^3.0.4: +matchdep@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/matchdep/-/matchdep-2.0.0.tgz#c6f34834a0d8dbc3b37c27ee8bbcb27c7775582e" + integrity sha1-xvNINKDY28OzfCfui7yyfHd1WC4= + dependencies: + findup-sync "^2.0.0" + micromatch "^3.0.4" + resolve "^1.4.0" + stack-trace "0.0.10" + +micromatch@^3.0.4, micromatch@^3.1.10, micromatch@^3.1.4: version "3.1.10" resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-3.1.10.tgz#70859bc95c9840952f359a068a3fc49f9ecfac23" integrity sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg== @@ -2707,6 +3246,11 @@ mime-types@^2.1.12, mime-types@~2.1.17: dependencies: mime-db "~1.30.0" +mimic-fn@^1.0.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" + integrity sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ== + minimatch@0.3: version "0.3.0" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-0.3.0.tgz#275d8edaac4f1bb3326472089e7949c8394699dd" @@ -2715,34 +3259,26 @@ minimatch@0.3: lru-cache "2" sigmund "~1.0.0" -"minimatch@2 || 3", minimatch@^3.0.3, minimatch@^3.0.4: +"minimatch@2 || 3", minimatch@^3.0.2, minimatch@^3.0.3, minimatch@^3.0.4: version "3.0.4" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== dependencies: brace-expansion "^1.1.7" -minimatch@2.x, minimatch@^2.0.1: +minimatch@2.x: version "2.0.10" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-2.0.10.tgz#8d087c39c6b38c001b97fca7ce6d0e1e80afbac7" integrity sha1-jQh8OcazjAAbl/ynzm0OHoCvusc= dependencies: brace-expansion "^1.0.0" -minimatch@~0.2.11: - version "0.2.14" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-0.2.14.tgz#c74e780574f63c6f9a090e90efbe6ef53a6a756a" - integrity sha1-x054BXT2PG+aCQ6Q775u9TpqdWo= - dependencies: - lru-cache "2" - sigmund "~1.0.0" - minimist@0.0.8: version "0.0.8" resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d" integrity sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0= -minimist@^1.1.0: +minimist@^1.1.0, minimist@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284" integrity sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ= @@ -2752,6 +3288,21 @@ minimist@~0.0.1: resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.10.tgz#de3f98543dbf96082be48ad1a0c7cda836301dcf" integrity sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8= +minipass@^2.2.1, minipass@^2.3.5: + version "2.3.5" + resolved "https://registry.yarnpkg.com/minipass/-/minipass-2.3.5.tgz#cacebe492022497f656b0f0f51e2682a9ed2d848" + integrity sha512-Gi1W4k059gyRbyVUZQ4mEqLm0YIUiGYfvxhF6SIlk3ui1WVxMTGfGdQ2SInh3PDrRTVvPKgULkpJtT4RH10+VA== + dependencies: + safe-buffer "^5.1.2" + yallist "^3.0.0" + +minizlib@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/minizlib/-/minizlib-1.2.1.tgz#dd27ea6136243c7c880684e8672bb3a45fd9b614" + integrity sha512-7+4oTUOWKg7AuL3vloEWekXY2/D20cevzsrNT2kGWm+39J9hGTCBv8VI5Pm5lXZ/o3/mdR4f8rflAPhnQb8mPA== + dependencies: + minipass "^2.2.1" + mixin-deep@^1.2.0: version "1.3.1" resolved "https://registry.yarnpkg.com/mixin-deep/-/mixin-deep-1.3.1.tgz#a49e7268dce1a0d9698e45326c5626df3543d0fe" @@ -2798,6 +3349,11 @@ ms@2.0.0: resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g= +ms@^2.1.1: + version "2.1.2" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" + integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== + multipipe@^0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/multipipe/-/multipipe-0.1.2.tgz#2a8f2ddf70eed564dff2d57f1e1a137d9f05078b" @@ -2805,10 +3361,20 @@ multipipe@^0.1.2: dependencies: duplexer2 "0.0.2" -mute-stream@0.0.4: - version "0.0.4" - resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.4.tgz#a9219960a6d5d5d046597aee51252c6655f7177e" - integrity sha1-qSGZYKbV1dBGWXruUSUsZlX3F34= +mute-stdout@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/mute-stdout/-/mute-stdout-1.0.1.tgz#acb0300eb4de23a7ddeec014e3e96044b3472331" + integrity sha512-kDcwXR4PS7caBpuRYYBUz9iVixUk3anO3f5OYFiIPwK/20vCzKCHyKoulbiDY1S53zD2bxUpxN/IJ+TnXjfvxg== + +mute-stream@0.0.7: + version "0.0.7" + resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.7.tgz#3075ce93bc21b8fab43e1bc4da7e8115ed1e7bab" + integrity sha1-MHXOk7whuPq0PhvE2n6BFe0ee6s= + +nan@^2.12.1: + version "2.14.0" + resolved "https://registry.yarnpkg.com/nan/-/nan-2.14.0.tgz#7818f722027b2459a86f0295d434d1fc2336c52c" + integrity sha512-INOFj37C7k3AfaNTtX8RhsTw7qRy7eLET14cROi9+5HAVbbHuIWUHEauBv5qT4Av2tWasiTY1Jw6puUNqRJXQg== nanomatch@^1.2.9: version "1.2.9" @@ -2828,16 +3394,30 @@ nanomatch@^1.2.9: snapdragon "^0.8.1" to-regex "^3.0.1" -natives@^1.1.0: - version "1.1.6" - resolved "https://registry.yarnpkg.com/natives/-/natives-1.1.6.tgz#a603b4a498ab77173612b9ea1acdec4d980f00bb" - integrity sha512-6+TDFewD4yxY14ptjKaS63GVdtKiES1pTPyxn9Jb0rBqPMZ7VcCiooEhPNsr+mqHtMGxa/5c/HhcC4uPEUw/nA== +natural-compare@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" + integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= + +needle@^2.2.1: + version "2.4.0" + resolved "https://registry.yarnpkg.com/needle/-/needle-2.4.0.tgz#6833e74975c444642590e15a750288c5f939b57c" + integrity sha512-4Hnwzr3mi5L97hMYeNl8wRW/Onhy4nUKR/lVemJ8gJedxxUyBLm9kkrDColJvoSfwi0jCNhD+xCdOtiGDQiRZg== + dependencies: + debug "^3.2.6" + iconv-lite "^0.4.4" + sax "^1.2.4" neo-async@^2.6.0: version "2.6.1" resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.1.tgz#ac27ada66167fa8849a6addd837f6b189ad2081c" integrity sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw== +next-tick@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/next-tick/-/next-tick-1.0.0.tgz#ca86d1fe8828169b0120208e3dc8424b9db8342c" + integrity sha1-yobR/ogoFpsBICCOPchCS524NCw= + nise@^1.4.5: version "1.4.6" resolved "https://registry.yarnpkg.com/nise/-/nise-1.4.6.tgz#76cc3915925056ae6c405dd8ad5d12bde570c19f" @@ -2863,6 +3443,29 @@ nock@7.5.0: propagate "0.3.x" qs "^6.0.2" +node-pre-gyp@^0.12.0: + version "0.12.0" + resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.12.0.tgz#39ba4bb1439da030295f899e3b520b7785766149" + integrity sha512-4KghwV8vH5k+g2ylT+sLTjy5wmUOb9vPhnM8NHvRf9dHmnW/CndrFXy2aRPaPST6dugXSdHXfeaHQm77PIz/1A== + dependencies: + detect-libc "^1.0.2" + mkdirp "^0.5.1" + needle "^2.2.1" + nopt "^4.0.1" + npm-packlist "^1.1.6" + npmlog "^4.0.2" + rc "^1.2.7" + rimraf "^2.6.1" + semver "^5.3.0" + tar "^4" + +node-releases@^1.1.23: + version "1.1.25" + resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-1.1.25.tgz#0c2d7dbc7fed30fbe02a9ee3007b8c90bf0133d3" + integrity sha512-fI5BXuk83lKEoZDdH3gRhtsNgh05/wZacuXkgbiYkceE7+QIMXOg98n9ZV7mz27B+kFHnqHcUpscZZlGRSmTpQ== + dependencies: + semver "^5.3.0" + nopt@3.x: version "3.0.6" resolved "https://registry.yarnpkg.com/nopt/-/nopt-3.0.6.tgz#c6465dbf08abcd4db359317f79ac68a646b28ff9" @@ -2870,6 +3473,66 @@ nopt@3.x: dependencies: abbrev "1" +nopt@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/nopt/-/nopt-4.0.1.tgz#d0d4685afd5415193c8c7505602d0d17cd64474d" + integrity sha1-0NRoWv1UFRk8jHUFYC0NF81kR00= + dependencies: + abbrev "1" + osenv "^0.1.4" + +normalize-package-data@^2.3.2: + version "2.5.0" + resolved "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-2.5.0.tgz#e66db1838b200c1dfc233225d12cb36520e234a8" + integrity sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA== + dependencies: + hosted-git-info "^2.1.4" + resolve "^1.10.0" + semver "2 || 3 || 4 || 5" + validate-npm-package-license "^3.0.1" + +normalize-path@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-2.1.1.tgz#1ab28b556e198363a8c1a6f7e6fa20137fe6aed9" + integrity sha1-GrKLVW4Zg2Oowab35vogE3/mrtk= + dependencies: + remove-trailing-separator "^1.0.1" + +normalize-path@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" + integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== + +now-and-later@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/now-and-later/-/now-and-later-2.0.1.tgz#8e579c8685764a7cc02cb680380e94f43ccb1f7c" + integrity sha512-KGvQ0cB70AQfg107Xvs/Fbu+dGmZoTRJp2TaPwcwQm3/7PteUyN2BCgk8KBMPGBUXZdVwyWS8fDCGFygBm19UQ== + dependencies: + once "^1.3.2" + +npm-bundled@^1.0.1: + version "1.0.6" + resolved "https://registry.yarnpkg.com/npm-bundled/-/npm-bundled-1.0.6.tgz#e7ba9aadcef962bb61248f91721cd932b3fe6bdd" + integrity sha512-8/JCaftHwbd//k6y2rEWp6k1wxVfpFzB6t1p825+cUb7Ym2XQfhwIC5KwhrvzZRJu+LtDE585zVaS32+CGtf0g== + +npm-packlist@^1.1.6: + version "1.4.4" + resolved "https://registry.yarnpkg.com/npm-packlist/-/npm-packlist-1.4.4.tgz#866224233850ac534b63d1a6e76050092b5d2f44" + integrity sha512-zTLo8UcVYtDU3gdeaFu2Xu0n0EvelfHDGuqtNIn5RO7yQj4H1TqNdBc/yZjxnWA0PVB8D3Woyp0i5B43JwQ6Vw== + dependencies: + ignore-walk "^3.0.1" + npm-bundled "^1.0.1" + +npmlog@^4.0.2: + version "4.1.2" + resolved "https://registry.yarnpkg.com/npmlog/-/npmlog-4.1.2.tgz#08a7f2a8bf734604779a9efa4ad5cc717abb954b" + integrity sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg== + dependencies: + are-we-there-yet "~1.1.2" + console-control-strings "~1.1.0" + gauge "~2.7.3" + set-blocking "~2.0.0" + number-is-nan@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" @@ -2880,11 +3543,6 @@ oauth-sign@~0.8.2: resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.8.2.tgz#46a6ab7f0aead8deae9ec0565780b7d4efeb9d43" integrity sha1-Rqarfwrq2N6unsBWV4C31O/rnUM= -object-assign@^2.0.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-2.1.1.tgz#43c36e5d569ff8e4816c4efa8be02d26967c18aa" - integrity sha1-Q8NuXVaf+OSBbE76i+AtJpZ8GKo= - object-assign@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-3.0.0.tgz#9bedd5ca0897949bca47e7ff408062d549f587f2" @@ -2904,6 +3562,11 @@ object-copy@^0.1.0: define-property "^0.2.5" kind-of "^3.0.3" +object-keys@^1.0.11, object-keys@^1.0.12: + version "1.1.1" + resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.1.1.tgz#1c47f272df277f3b1daf061677d9c82e2322c60e" + integrity sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA== + object-visit@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/object-visit/-/object-visit-1.0.1.tgz#f79c4493af0c5377b59fe39d395e41042dd045bb" @@ -2911,7 +3574,17 @@ object-visit@^1.0.0: dependencies: isobject "^3.0.0" -object.defaults@^1.1.0: +object.assign@^4.0.4: + version "4.1.0" + resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.1.0.tgz#968bf1100d7956bb3ca086f006f846b3bc4008da" + integrity sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w== + dependencies: + define-properties "^1.1.2" + function-bind "^1.1.1" + has-symbols "^1.0.0" + object-keys "^1.0.11" + +object.defaults@^1.0.0, object.defaults@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/object.defaults/-/object.defaults-1.1.0.tgz#3a7f868334b407dea06da16d88d5cd29e435fecf" integrity sha1-On+GgzS0B96gbaFtiNXNKeQ1/s8= @@ -2936,19 +3609,27 @@ object.pick@^1.2.0, object.pick@^1.3.0: dependencies: isobject "^3.0.1" -once@1.x, once@^1.3.0: +object.reduce@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/object.reduce/-/object.reduce-1.0.1.tgz#6fe348f2ac7fa0f95ca621226599096825bb03ad" + integrity sha1-b+NI8qx/oPlcpiEiZZkJaCW7A60= + dependencies: + for-own "^1.0.0" + make-iterator "^1.0.0" + +once@1.x, once@^1.3.0, once@^1.3.1, once@^1.3.2, once@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" integrity sha1-WDsap3WWHUsROsF9nFC6753Xa9E= dependencies: wrappy "1" -once@~1.3.0: - version "1.3.3" - resolved "https://registry.yarnpkg.com/once/-/once-1.3.3.tgz#b2e261557ce4c314ec8304f3fa82663e4297ca20" - integrity sha1-suJhVXzkwxTsgwTz+oJmPkKXyiA= +onetime@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/onetime/-/onetime-2.0.1.tgz#067428230fd67443b2794b22bba528b6867962d4" + integrity sha1-BnQoIw/WdEOyeUsiu6UotoZ5YtQ= dependencies: - wrappy "1" + mimic-fn "^1.0.0" optimist@^0.6.1: version "0.6.1" @@ -2970,7 +3651,7 @@ optionator@^0.5.0: type-check "~0.3.1" wordwrap "~0.0.2" -optionator@^0.8.1: +optionator@^0.8.1, optionator@^0.8.2: version "0.8.2" resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.2.tgz#364c5e409d3f4d6301d6c0b4c05bba50180aeb64" integrity sha1-NkxeQJ0/TWMB1sC0wFu6UBgK62Q= @@ -2982,30 +3663,38 @@ optionator@^0.8.1: type-check "~0.3.2" wordwrap "~1.0.0" -orchestrator@^0.3.0: - version "0.3.8" - resolved "https://registry.yarnpkg.com/orchestrator/-/orchestrator-0.3.8.tgz#14e7e9e2764f7315fbac184e506c7aa6df94ad7e" - integrity sha1-FOfp4nZPcxX7rBhOUGx6pt+UrX4= +ordered-read-streams@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/ordered-read-streams/-/ordered-read-streams-1.0.1.tgz#77c0cb37c41525d64166d990ffad7ec6a0e1363e" + integrity sha1-d8DLN8QVJdZBZtmQ/61+xqDhNj4= dependencies: - end-of-stream "~0.1.5" - sequencify "~0.0.7" - stream-consume "~0.1.0" - -ordered-read-streams@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/ordered-read-streams/-/ordered-read-streams-0.1.0.tgz#fd565a9af8eb4473ba69b6ed8a34352cb552f126" - integrity sha1-/VZamvjrRHO6abbtijQ1LLVS8SY= + readable-stream "^2.0.1" os-homedir@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/os-homedir/-/os-homedir-1.0.2.tgz#ffbc4988336e0e833de0c168c7ef152121aa7fb3" integrity sha1-/7xJiDNuDoM94MFox+8VISGqf7M= -os-tmpdir@^1.0.0, os-tmpdir@^1.0.1: +os-locale@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/os-locale/-/os-locale-1.4.0.tgz#20f9f17ae29ed345e8bde583b13d2009803c14d9" + integrity sha1-IPnxeuKe00XoveWDsT0gCYA8FNk= + dependencies: + lcid "^1.0.0" + +os-tmpdir@^1.0.0, os-tmpdir@~1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" integrity sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ= +osenv@^0.1.4: + version "0.1.5" + resolved "https://registry.yarnpkg.com/osenv/-/osenv-0.1.5.tgz#85cdfafaeb28e8677f416e287592b5f3f49ea410" + integrity sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g== + dependencies: + os-homedir "^1.0.0" + os-tmpdir "^1.0.0" + parse-filepath@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/parse-filepath/-/parse-filepath-1.0.2.tgz#a632127f53aaf3d15876f5872f3ffac763d6c891" @@ -3015,6 +3704,18 @@ parse-filepath@^1.0.1: map-cache "^0.2.0" path-root "^0.1.1" +parse-json@^2.2.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-2.2.0.tgz#f480f40434ef80741f8469099f8dea18f55a4dc9" + integrity sha1-9ID0BDTvgHQfhGkJn43qGPVaTck= + dependencies: + error-ex "^1.2.0" + +parse-node-version@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/parse-node-version/-/parse-node-version-1.0.1.tgz#e2b5dbede00e7fa9bc363607f53327e8b073189b" + integrity sha512-3YHlOa/JgH6Mnpr05jP9eDG254US9ek25LyIxZlDItp2iJtwyaXQb57lBYLdT3MowkUFYEV2XXNAYIPlESvJlA== + parse-passwd@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/parse-passwd/-/parse-passwd-1.0.0.tgz#6d5b934a456993b23d37f40a382d6f1666a8e5c6" @@ -3025,16 +3726,38 @@ pascalcase@^0.1.1: resolved "https://registry.yarnpkg.com/pascalcase/-/pascalcase-0.1.1.tgz#b363e55e8006ca6fe21784d2db22bd15d7917f14" integrity sha1-s2PlXoAGym/iF4TS2yK9FdeRfxQ= -path-is-absolute@^1.0.0, path-is-absolute@^1.0.1: +path-dirname@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/path-dirname/-/path-dirname-1.0.2.tgz#cc33d24d525e099a5388c0336c6e32b9160609e0" + integrity sha1-zDPSTVJeCZpTiMAzbG4yuRYGCeA= + +path-exists@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-2.1.0.tgz#0feb6c64f0fc518d9a754dd5efb62c7022761f4b" + integrity sha1-D+tsZPD8UY2adU3V77YscCJ2H0s= + dependencies: + pinkie-promise "^2.0.0" + +path-is-absolute@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" integrity sha1-F0uSaHNVNP+8es5r9TpanhtcX18= +path-is-inside@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/path-is-inside/-/path-is-inside-1.0.2.tgz#365417dede44430d1c11af61027facf074bdfc53" + integrity sha1-NlQX3t5EQw0cEa9hAn+s8HS9/FM= + path-parse@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.5.tgz#3c1adf871ea9cd6c9431b6ea2bd74a0ff055c4c1" integrity sha1-PBrfhx6pzWyUMbbqK9dKD/BVxME= +path-parse@^1.0.6: + version "1.0.6" + resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.6.tgz#d62dbb5679405d72c4737ec58600e9ddcf06d24c" + integrity sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw== + path-root-regex@^0.1.0: version "0.1.2" resolved "https://registry.yarnpkg.com/path-root-regex/-/path-root-regex-0.1.2.tgz#bfccdc8df5b12dc52c8b43ec38d18d72c04ba96d" @@ -3054,11 +3777,47 @@ path-to-regexp@^1.7.0: dependencies: isarray "0.0.1" +path-type@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/path-type/-/path-type-1.1.0.tgz#59c44f7ee491da704da415da5a4070ba4f8fe441" + integrity sha1-WcRPfuSR2nBNpBXaWkBwuk+P5EE= + dependencies: + graceful-fs "^4.1.2" + pify "^2.0.0" + pinkie-promise "^2.0.0" + performance-now@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" integrity sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns= +pify@^2.0.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/pify/-/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c" + integrity sha1-7RQaasBDqEnqWISY59yosVMw6Qw= + +pinkie-promise@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/pinkie-promise/-/pinkie-promise-2.0.1.tgz#2135d6dfa7a358c069ac9b178776288228450ffa" + integrity sha1-ITXW36ejWMBprJsXh3YogihFD/o= + dependencies: + pinkie "^2.0.0" + +pinkie@^2.0.0: + version "2.0.4" + resolved "https://registry.yarnpkg.com/pinkie/-/pinkie-2.0.4.tgz#72556b80cfa0d48a974e80e77248e80ed4f7f870" + integrity sha1-clVrgM+g1IqXToDnckjoDtT3+HA= + +plugin-error@^1.0.0, plugin-error@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/plugin-error/-/plugin-error-1.0.1.tgz#77016bd8919d0ac377fdcdd0322328953ca5781c" + integrity sha512-L1zP0dk7vGweZME2i+EeakvUNqSrdiI3F91TwEoYiGrAfUXmVv6fJIq4g82PAXxNsWOp0J7ZqQy/3Szz0ajTxA== + dependencies: + ansi-colors "^1.0.1" + arr-diff "^4.0.0" + arr-union "^3.1.0" + extend-shallow "^3.0.2" + plur@^2.1.0: version "2.1.2" resolved "https://registry.yarnpkg.com/plur/-/plur-2.1.2.tgz#7482452c1a0f508e3e344eaec312c91c29dc655a" @@ -3066,6 +3825,11 @@ plur@^2.1.0: dependencies: irregular-plurals "^1.0.0" +pluralize@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-7.0.0.tgz#298b89df8b93b0221dbf421ad2b1b1ea23fc6777" + integrity sha512-ARhBOdzS3e41FbkW/XWrTEtukqqLoK5+Z/4UeDaLuSW+39JPeFgs4gCGqsrJHVZX0fUrx//4OF0K1CUGwlIFow== + posix-character-classes@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/posix-character-classes/-/posix-character-classes-0.1.1.tgz#01eac0fe3b5af71a2a6c02feabb8c1fef7e00eab" @@ -3081,21 +3845,53 @@ pretty-hrtime@^1.0.0: resolved "https://registry.yarnpkg.com/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz#b7e3ea42435a4c9b2759d99e0f201eb195802ee1" integrity sha1-t+PqQkNaTJsnWdmeDyAesZWALuE= -private@^0.1.6, private@^0.1.7: +private@^0.1.6: version "0.1.8" resolved "https://registry.yarnpkg.com/private/-/private-0.1.8.tgz#2381edb3689f7a53d653190060fcf822d2f368ff" integrity sha512-VvivMrbvd2nKkiG38qjULzlc+4Vx4wm/whI9pQD35YrARNnhxeiRktSOhSukRLFNlzg6Br/cJPet5J/u19r/mg== +process-nextick-args@^2.0.0, process-nextick-args@~2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2" + integrity sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag== + process-nextick-args@~1.0.6: version "1.0.7" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-1.0.7.tgz#150e20b756590ad3f91093f25a4f2ad8bff30ba3" integrity sha1-FQ4gt1ZZCtP5EJPyWk8q2L/zC6M= +progress@^2.0.0: + version "2.0.3" + resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.3.tgz#7e8cf8d8f5b8f239c1bc68beb4eb78567d572ef8" + integrity sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA== + propagate@0.3.x: version "0.3.1" resolved "https://registry.yarnpkg.com/propagate/-/propagate-0.3.1.tgz#e3a84404a7ece820dd6bbea9f6d924e3135ae09c" integrity sha1-46hEBKfs6CDda76p9tkk4xNa4Jw= +pseudomap@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3" + integrity sha1-8FKijacOYYkX7wqKw0wa5aaChrM= + +pump@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/pump/-/pump-2.0.1.tgz#12399add6e4cf7526d973cbc8b5ce2e2908b3909" + integrity sha512-ruPMNRkN3MHP1cWJc9OWr+T/xDP0jhXYCLfJcBuX54hhfIBnaQmAUMfDcG4DM5UMWByBbJY69QSphm3jtDKIkA== + dependencies: + end-of-stream "^1.1.0" + once "^1.3.1" + +pumpify@^1.3.5: + version "1.5.1" + resolved "https://registry.yarnpkg.com/pumpify/-/pumpify-1.5.1.tgz#36513be246ab27570b1a374a5ce278bfd74370ce" + integrity sha512-oClZI37HvuUJJxSKKrC17bZ9Cu0ZYhEAGPsPUy9KlMUmv9dKX2o77RUmq7f3XjIxbwyGwYzbzQ1L2Ks8sIradQ== + dependencies: + duplexify "^3.6.0" + inherits "^2.0.3" + pump "^2.0.0" + punycode@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" @@ -3106,17 +3902,47 @@ qs@^6.0.2, qs@~6.5.1: resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8" integrity sha512-eRzhrN1WSINYCDCbrz796z37LOe3m5tmW7RQf6oBntukAG1nmovJvhnwHHRMAfeoItc1m2Hk02WER2aQ/iqs+A== -"readable-stream@>=1.0.33-1 <1.1.0-0": - version "1.0.34" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.0.34.tgz#125820e34bc842d2f2aaafafe4c2916ee32c157c" - integrity sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw= +rc@^1.2.7: + version "1.2.8" + resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.8.tgz#cd924bf5200a075b83c188cd6b9e211b7fc0d3ed" + integrity sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw== + dependencies: + deep-extend "^0.6.0" + ini "~1.3.0" + minimist "^1.2.0" + strip-json-comments "~2.0.1" + +read-pkg-up@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-1.0.1.tgz#9d63c13276c065918d57f002a57f40a1b643fb02" + integrity sha1-nWPBMnbAZZGNV/ACpX9AobZD+wI= + dependencies: + find-up "^1.0.0" + read-pkg "^1.0.0" + +read-pkg@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-1.1.0.tgz#f5ffaa5ecd29cb31c0474bca7d756b6bb29e3f28" + integrity sha1-9f+qXs0pyzHAR0vKfXVra7KePyg= + dependencies: + load-json-file "^1.0.0" + normalize-package-data "^2.3.2" + path-type "^1.0.0" + +readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.5, readable-stream@^2.0.6, readable-stream@^2.3.3, readable-stream@^2.3.5, readable-stream@^2.3.6, readable-stream@~2.3.6: + version "2.3.6" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.6.tgz#b11c27d88b8ff1fbe070643cf94b0c79ae1b0aaf" + integrity sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw== dependencies: core-util-is "~1.0.0" - inherits "~2.0.1" - isarray "0.0.1" - string_decoder "~0.10.x" + 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" -readable-stream@^2.0.0, readable-stream@^2.1.5, readable-stream@^2.2.2: +readable-stream@^2.1.5, readable-stream@^2.2.2: version "2.3.3" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.3.tgz#368f2512d79f9d46fdfc71349ae7878bbc1eb95c" integrity sha512-m+qzzcn7KUxEmd1gMbchF+Y2eIUbieUaxkWtptyHywrX0rE8QEYqPC07Vuy4Wm32/xE16NcdBctb8S0Xe/5IeQ== @@ -3139,13 +3965,14 @@ readable-stream@~1.1.9: isarray "0.0.1" string_decoder "~0.10.x" -readline2@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/readline2/-/readline2-0.1.1.tgz#99443ba6e83b830ef3051bfd7dc241a82728d568" - integrity sha1-mUQ7pug7gw7zBRv9fcJBqCco1Wg= +readdirp@^2.2.1: + version "2.2.1" + resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-2.2.1.tgz#0e87622a3325aa33e892285caf8b4e846529a525" + integrity sha512-1JU/8q+VgFZyxwrJ+SVIOsh+KywWGpds3NTqikiKpDMZWScmAYyKIgqkO+ARvNWJfXeXR1zxz7aHF4u4CyH6vQ== dependencies: - mute-stream "0.0.4" - strip-ansi "^2.0.1" + graceful-fs "^4.1.11" + micromatch "^3.1.10" + readable-stream "^2.0.2" rechoir@^0.6.2: version "0.6.2" @@ -3154,23 +3981,23 @@ rechoir@^0.6.2: dependencies: resolve "^1.1.6" -regenerate@^1.2.1: - version "1.3.3" - resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.3.3.tgz#0c336d3980553d755c39b586ae3b20aa49c82b7f" - integrity sha512-jVpo1GadrDAK59t/0jRx5VxYWQEDkkEKi6+HjE3joFVLfDOh9Xrdh0dF1eSq+BI/SwvTQ44gSscJ8N5zYL61sg== +regenerate-unicode-properties@^8.0.2: + version "8.1.0" + resolved "https://registry.yarnpkg.com/regenerate-unicode-properties/-/regenerate-unicode-properties-8.1.0.tgz#ef51e0f0ea4ad424b77bf7cb41f3e015c70a3f0e" + integrity sha512-LGZzkgtLY79GeXLm8Dp0BVLdQlWICzBnJz/ipWUgo59qBaZ+BHtq51P2q1uVZlppMuUAT37SDk39qUbjTWB7bA== + dependencies: + regenerate "^1.4.0" -regenerator-runtime@^0.11.0: - version "0.11.0" - resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.11.0.tgz#7e54fe5b5ccd5d6624ea6255c3473be090b802e1" - integrity sha512-/aA0kLeRb5N9K0d4fw7ooEbI+xDe+DKD499EQqygGqeS8N3xto15p09uY2xj7ixP81sNPXvRLnAQIqdVStgb1A== +regenerate@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.4.0.tgz#4a856ec4b56e4077c557589cae85e7a4c8869a11" + integrity sha512-1G6jJVDWrt0rK99kBjvEtziZNCICAuvIPkSiUFIQxVP06RCVpq3dmDo2oi6ABpYaDYaTRr67BEhL8r1wgEZZKg== -regenerator-transform@^0.10.0: - version "0.10.1" - resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.10.1.tgz#1e4996837231da8b7f3cf4114d71b5691a0680dd" - integrity sha512-PJepbvDbuK1xgIgnau7Y90cwaAmO/LCLMI2mPvaXq2heGMR3aWW5/BQvYrhJ8jgmQjXewXvBjzfqKcVOmhjZ6Q== +regenerator-transform@^0.14.0: + version "0.14.0" + resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.14.0.tgz#2ca9aaf7a2c239dd32e4761218425b8c7a86ecaf" + integrity sha512-rtOelq4Cawlbmq9xuMR5gdFmv7ku/sFoB7sRiywx7aq53bc52b4j6zvH7Te1Vt/X2YveDKnCGUbioieU7FEL3w== dependencies: - babel-runtime "^6.18.0" - babel-types "^6.19.0" private "^0.1.6" regex-not@^1.0.0, regex-not@^1.0.2: @@ -3181,27 +4008,62 @@ regex-not@^1.0.0, regex-not@^1.0.2: extend-shallow "^3.0.2" safe-regex "^1.1.0" -regexpu-core@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/regexpu-core/-/regexpu-core-2.0.0.tgz#49d038837b8dcf8bfa5b9a42139938e6ea2ae240" - integrity sha1-SdA4g3uNz4v6W5pCE5k45uoq4kA= - dependencies: - regenerate "^1.2.1" - regjsgen "^0.2.0" - regjsparser "^0.1.4" +regexp-tree@^0.1.6: + version "0.1.10" + resolved "https://registry.yarnpkg.com/regexp-tree/-/regexp-tree-0.1.10.tgz#d837816a039c7af8a8d64d7a7c3cf6a1d93450bc" + integrity sha512-K1qVSbcedffwuIslMwpe6vGlj+ZXRnGkvjAtFHfDZZZuEdA/h0dxljAPu9vhUo6Rrx2U2AwJ+nSQ6hK+lrP5MQ== -regjsgen@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/regjsgen/-/regjsgen-0.2.0.tgz#6c016adeac554f75823fe37ac05b92d5a4edb1f7" - integrity sha1-bAFq3qxVT3WCP+N6wFuS1aTtsfc= +regexpp@^1.0.1: + version "1.1.0" + resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-1.1.0.tgz#0e3516dd0b7904f413d2d4193dce4618c3a689ab" + integrity sha512-LOPw8FpgdQF9etWMaAfG/WRthIdXJGYp4mJ2Jgn/2lpkbod9jPn0t9UqN7AxBOKNfzRbYyVfgc7Vk4t/MpnXgw== + +regexpu-core@^4.5.4: + version "4.5.4" + resolved "https://registry.yarnpkg.com/regexpu-core/-/regexpu-core-4.5.4.tgz#080d9d02289aa87fe1667a4f5136bc98a6aebaae" + integrity sha512-BtizvGtFQKGPUcTy56o3nk1bGRp4SZOTYrDtGNlqCQufptV5IkkLN6Emw+yunAJjzf+C9FQFtvq7IoA3+oMYHQ== + dependencies: + regenerate "^1.4.0" + regenerate-unicode-properties "^8.0.2" + regjsgen "^0.5.0" + regjsparser "^0.6.0" + unicode-match-property-ecmascript "^1.0.4" + unicode-match-property-value-ecmascript "^1.1.0" + +regjsgen@^0.5.0: + version "0.5.0" + resolved "https://registry.yarnpkg.com/regjsgen/-/regjsgen-0.5.0.tgz#a7634dc08f89209c2049adda3525711fb97265dd" + integrity sha512-RnIrLhrXCX5ow/E5/Mh2O4e/oa1/jW0eaBKTSy3LaCj+M3Bqvm97GWDp2yUtzIs4LEn65zR2yiYGFqb2ApnzDA== -regjsparser@^0.1.4: - version "0.1.5" - resolved "https://registry.yarnpkg.com/regjsparser/-/regjsparser-0.1.5.tgz#7ee8f84dc6fa792d3fd0ae228d24bd949ead205c" - integrity sha1-fuj4Tcb6eS0/0K4ijSS9lJ6tIFw= +regjsparser@^0.6.0: + version "0.6.0" + resolved "https://registry.yarnpkg.com/regjsparser/-/regjsparser-0.6.0.tgz#f1e6ae8b7da2bae96c99399b868cd6c933a2ba9c" + integrity sha512-RQ7YyokLiQBomUJuUG8iGVvkgOLxwyZM8k6d3q5SAXpg4r5TZJZigKFvC6PpD+qQ98bCDC5YelPeA3EucDoNeQ== dependencies: jsesc "~0.5.0" +remove-bom-buffer@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/remove-bom-buffer/-/remove-bom-buffer-3.0.0.tgz#c2bf1e377520d324f623892e33c10cac2c252b53" + integrity sha512-8v2rWhaakv18qcvNeli2mZ/TMTL2nEyAKRvzo1WtnZBl15SHyEhrCu2/xKlJyUFKHiHgfXIyuY6g2dObJJycXQ== + dependencies: + is-buffer "^1.1.5" + is-utf8 "^0.2.1" + +remove-bom-stream@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/remove-bom-stream/-/remove-bom-stream-1.2.0.tgz#05f1a593f16e42e1fb90ebf59de8e569525f9523" + integrity sha1-BfGlk/FuQuH7kOv1nejlaVJflSM= + dependencies: + remove-bom-buffer "^3.0.0" + safe-buffer "^5.1.0" + through2 "^2.0.3" + +remove-trailing-separator@^1.0.1, remove-trailing-separator@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz#c24bce2a283adad5bc3f58e0d48249b92379d8ef" + integrity sha1-wkvOKig62tW8P1jg1IJJuSN52O8= + repeat-element@^1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/repeat-element/-/repeat-element-1.1.2.tgz#ef089a178d1483baae4d93eb98b4f9e4e11d990a" @@ -3212,18 +4074,25 @@ repeat-string@^1.6.1: resolved "https://registry.yarnpkg.com/repeat-string/-/repeat-string-1.6.1.tgz#8dcae470e1c88abc2d600fff4a776286da75e637" integrity sha1-jcrkcOHIirwtYA//Sndihtp15jc= -repeating@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/repeating/-/repeating-2.0.1.tgz#5214c53a926d3552707527fbab415dbc08d06dda" - integrity sha1-UhTFOpJtNVJwdSf7q0FdvAjQbdo= - dependencies: - is-finite "^1.0.0" - replace-ext@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/replace-ext/-/replace-ext-0.0.1.tgz#29bbd92078a739f0bcce2b4ee41e837953522924" integrity sha1-KbvZIHinOfC8zitO5B6DeVNSKSQ= +replace-ext@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/replace-ext/-/replace-ext-1.0.0.tgz#de63128373fcbf7c3ccfa4de5a480c45a67958eb" + integrity sha1-3mMSg3P8v3w8z6TeWkgMRaZ5WOs= + +replace-homedir@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/replace-homedir/-/replace-homedir-1.0.0.tgz#e87f6d513b928dde808260c12be7fec6ff6e798c" + integrity sha1-6H9tUTuSjd6AgmDBK+f+xv9ueYw= + dependencies: + homedir-polyfill "^1.0.1" + is-absolute "^1.0.0" + remove-trailing-separator "^1.1.0" + request@^2.83.0: version "2.83.0" resolved "https://registry.yarnpkg.com/request/-/request-2.83.0.tgz#ca0b65da02ed62935887808e6f510381034e3356" @@ -3252,6 +4121,24 @@ request@^2.83.0: tunnel-agent "^0.6.0" uuid "^3.1.0" +require-directory@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" + integrity sha1-jGStX9MNqxyXbiNE/+f3kqam30I= + +require-main-filename@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-1.0.1.tgz#97f717b69d48784f5f526a6c5aa8ffdda055a4d1" + integrity sha1-l/cXtp1IeE9fUmpsWqj/3aBVpNE= + +require-uncached@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/require-uncached/-/require-uncached-1.0.3.tgz#4e0d56d6c9662fd31e43011c4b95aa49955421d3" + integrity sha1-Tg1W1slmL9MeQwEcS5WqSZVUIdM= + dependencies: + caller-path "^0.1.0" + resolve-from "^1.0.0" + resolve-dir@^1.0.0, resolve-dir@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/resolve-dir/-/resolve-dir-1.0.1.tgz#79a40644c362be82f26effe739c9bb5382046f43" @@ -3265,6 +4152,13 @@ resolve-from@^1.0.0: resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-1.0.1.tgz#26cbfe935d1aeeeabb29bc3fe5aeb01e93d44226" integrity sha1-Jsv+k10a7uq7Kbw/5a6wHpPUQiY= +resolve-options@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/resolve-options/-/resolve-options-1.1.0.tgz#32bb9e39c06d67338dc9378c0d6d6074566ad131" + integrity sha1-MrueOcBtZzONyTeMDW1gdFZq0TE= + dependencies: + value-or-function "^3.0.0" + resolve-url@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" @@ -3282,26 +4176,67 @@ resolve@^1.1.6, resolve@^1.1.7: dependencies: path-parse "^1.0.5" +resolve@^1.10.0, resolve@^1.3.2, resolve@^1.4.0: + version "1.11.1" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.11.1.tgz#ea10d8110376982fef578df8fc30b9ac30a07a3e" + integrity sha512-vIpgF6wfuJOZI7KKKSP+HmiKggadPQAdsp5HiC1mvqnfp0gF1vdwgBWZIdrVft9pgqoMFQN+R7BSWZiBxx+BBw== + dependencies: + path-parse "^1.0.6" + +restore-cursor@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-2.0.0.tgz#9f7ee287f82fd326d4fd162923d62129eee0dfaf" + integrity sha1-n37ih/gv0ybU/RYpI9YhKe7g368= + dependencies: + onetime "^2.0.0" + signal-exit "^3.0.2" + ret@~0.1.10: version "0.1.15" resolved "https://registry.yarnpkg.com/ret/-/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc" integrity sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg== +rimraf@^2.6.1, rimraf@~2.6.2: + version "2.6.3" + resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.3.tgz#b2d104fe0d8fb27cf9e0a1cda8262dd3833c6cab" + integrity sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA== + dependencies: + glob "^7.1.3" + rimraf@~2.2.6: version "2.2.8" resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.2.8.tgz#e439be2aaee327321952730f99a8929e4fc50582" integrity sha1-5Dm+Kq7jJzIZUnMPmaiSnk/FBYI= -rx@^2.4.3: - version "2.5.3" - resolved "https://registry.yarnpkg.com/rx/-/rx-2.5.3.tgz#21adc7d80f02002af50dae97fd9dbf248755f566" - integrity sha1-Ia3H2A8CACr1Da6X/Z2/JIdV9WY= +run-async@^2.2.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.3.0.tgz#0371ab4ae0bdd720d4166d7dfda64ff7a445a6c0" + integrity sha1-A3GrSuC91yDUFm19/aZP96RFpsA= + dependencies: + is-promise "^2.1.0" + +rx-lite-aggregates@^4.0.8: + version "4.0.8" + resolved "https://registry.yarnpkg.com/rx-lite-aggregates/-/rx-lite-aggregates-4.0.8.tgz#753b87a89a11c95467c4ac1626c4efc4e05c67be" + integrity sha1-dTuHqJoRyVRnxKwWJsTvxOBcZ74= + dependencies: + rx-lite "*" + +rx-lite@*, rx-lite@^4.0.8: + version "4.0.8" + resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-4.0.8.tgz#0b1e11af8bc44836f04a6407e92da42467b79444" + integrity sha1-Cx4Rr4vESDbwSmQH6S2kJGe3lEQ= safe-buffer@^5.0.1, safe-buffer@^5.1.1, safe-buffer@~5.1.0, safe-buffer@~5.1.1: version "5.1.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.1.tgz#893312af69b2123def71f57889001671eeb2c853" integrity sha512-kKvNJn6Mm93gAczWVJg7wH+wGYWNrDHdWvpUmHyEsgCtIwwo3bqPtV4tR5tuPaUhTOo/kvhVwd8XwwOllGYkbg== +safe-buffer@^5.1.0, safe-buffer@^5.1.2: + version "5.1.2" + resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" + integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== + safe-regex@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/safe-regex/-/safe-regex-1.1.0.tgz#40a3669f3b077d1e943d44629e157dd48023bf2e" @@ -3309,20 +4244,37 @@ safe-regex@^1.1.0: dependencies: ret "~0.1.10" -safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: +"safer-buffer@>= 2.1.2 < 3", safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== -semver@^4.1.0: - version "4.3.6" - resolved "https://registry.yarnpkg.com/semver/-/semver-4.3.6.tgz#300bc6e0e86374f7ba61068b5b1ecd57fc6532da" - integrity sha1-MAvG4OhjdPe6YQaLWx7NV/xlMto= +sax@^1.2.4: + version "1.2.4" + resolved "https://registry.yarnpkg.com/sax/-/sax-1.2.4.tgz#2816234e2378bddc4e5354fab5caa895df7100d9" + integrity sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw== -sequencify@~0.0.7: - version "0.0.7" - resolved "https://registry.yarnpkg.com/sequencify/-/sequencify-0.0.7.tgz#90cff19d02e07027fd767f5ead3e7b95d1e7380c" - integrity sha1-kM/xnQLgcCf9dn9erT57ldHnOAw= +semver-greatest-satisfied-range@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/semver-greatest-satisfied-range/-/semver-greatest-satisfied-range-1.1.0.tgz#13e8c2658ab9691cb0cd71093240280d36f77a5b" + integrity sha1-E+jCZYq5aRywzXEJMkAoDTb3els= + dependencies: + sver-compat "^1.5.0" + +"semver@2 || 3 || 4 || 5", semver@^5.3.0, semver@^5.4.1, semver@^5.5.0: + version "5.7.0" + resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.0.tgz#790a7cf6fea5459bac96110b29b60412dc8ff96b" + integrity sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA== + +semver@^6.1.1: + version "6.2.0" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.2.0.tgz#4d813d9590aaf8a9192693d6c85b9344de5901db" + integrity sha512-jdFC1VdUGT/2Scgbimf7FSx9iJLXoqfglSF+gJeuNWVpiE37OIbc1jywR/GJyFdz3mnkz2/id0L0J/cr0izR5A== + +set-blocking@^2.0.0, set-blocking@~2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" + integrity sha1-BF+XgtARrppoA93TgrJDkrPYkPc= set-value@^0.4.3: version "0.4.3" @@ -3344,11 +4296,28 @@ set-value@^2.0.0: is-plain-object "^2.0.3" split-string "^3.0.1" +shebang-command@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea" + integrity sha1-RKrGW2lbAzmJaMOfNj/uXer98eo= + dependencies: + shebang-regex "^1.0.0" + +shebang-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3" + integrity sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM= + sigmund@~1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/sigmund/-/sigmund-1.0.1.tgz#3ff21f198cad2175f9f3b781853fd94d0d19b590" integrity sha1-P/IfGYytIXX587eBhT/ZTQ0ZtZA= +signal-exit@^3.0.0, signal-exit@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d" + integrity sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0= + sinon@^6.1.4: version "6.3.5" resolved "https://registry.yarnpkg.com/sinon/-/sinon-6.3.5.tgz#0f6d6a5b4ebaad1f6e8e019395542d1d02c144a0" @@ -3364,10 +4333,12 @@ sinon@^6.1.4: supports-color "^5.5.0" type-detect "^4.0.8" -slash@^1.0.0: +slice-ansi@1.0.0: version "1.0.0" - resolved "https://registry.yarnpkg.com/slash/-/slash-1.0.0.tgz#c41f2f6c39fc16d1cd17ad4b5d896114ae470d55" - integrity sha1-xB8vbDn8FtHNF61LXYlhFK5HDVU= + resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-1.0.0.tgz#044f1a49d8842ff307aad6b505ed178bd950134d" + integrity sha512-POqxBK6Lb3q6s047D/XsDVNPnF9Dl8JSaqe9h9lURl0OdNqy/ujDrOiIHtsqXMGbWWTIomRzAMaTyawAU//Reg== + dependencies: + is-fullwidth-code-point "^2.0.0" snapdragon-node@^2.0.1: version "2.1.1" @@ -3417,19 +4388,12 @@ source-map-resolve@^0.5.0: source-map-url "^0.4.0" urix "^0.1.0" -source-map-support@^0.4.15: - version "0.4.18" - resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.4.18.tgz#0286a6de8be42641338594e97ccea75f0a2c585f" - integrity sha512-try0/JqxPLF9nOjvSta7tVondkP5dwgyLDjVoyMDlmjugT2lRZ1OfsrYTkCd2hkDnJTKRbO/Rl3orm8vlsUzbA== - dependencies: - source-map "^0.5.6" - source-map-url@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.0.tgz#3e935d7ddd73631b97659956d55128e87b5084a3" integrity sha1-PpNdfd1zYxuXZZlW1VEo6HtQhKM= -source-map@^0.5.1, source-map@^0.5.6: +source-map@^0.5.0, source-map@^0.5.1, source-map@^0.5.6: version "0.5.7" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" integrity sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w= @@ -3451,6 +4415,32 @@ sparkles@^1.0.0: resolved "https://registry.yarnpkg.com/sparkles/-/sparkles-1.0.0.tgz#1acbbfb592436d10bbe8f785b7cc6f82815012c3" integrity sha1-Gsu/tZJDbRC76PeFt8xvgoFQEsM= +spdx-correct@^3.0.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.1.0.tgz#fb83e504445268f154b074e218c87c003cd31df4" + integrity sha512-lr2EZCctC2BNR7j7WzJ2FpDznxky1sjfxvvYEyzxNyb6lZXHODmEoJeFu4JupYlkfha1KZpJyoqiJ7pgA1qq8Q== + dependencies: + spdx-expression-parse "^3.0.0" + spdx-license-ids "^3.0.0" + +spdx-exceptions@^2.1.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz#2ea450aee74f2a89bfb94519c07fcd6f41322977" + integrity sha512-2XQACfElKi9SlVb1CYadKDXvoajPgBVPn/gOQLrTvHdElaVhr7ZEbqJaRnJLVNeaI4cMEAgVCeBMKF6MWRDCRA== + +spdx-expression-parse@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz#99e119b7a5da00e05491c9fa338b7904823b41d0" + integrity sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg== + dependencies: + spdx-exceptions "^2.1.0" + spdx-license-ids "^3.0.0" + +spdx-license-ids@^3.0.0: + version "3.0.4" + resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.4.tgz#75ecd1a88de8c184ef015eafb51b5b48bfd11bb1" + integrity sha512-7j8LYJLeY/Yb6ACbQ7F76qy5jHkp0U6jgBfJsk97bwWlVUnUWsAgpyaCvo17h0/RQGnQ036tVDomiwoI4pDkQA== + split-string@^3.0.1, split-string@^3.0.2: version "3.1.0" resolved "https://registry.yarnpkg.com/split-string/-/split-string-3.1.0.tgz#7cb09dda3a86585705c64b39a6466038682e8fe2" @@ -3478,6 +4468,11 @@ sshpk@^1.7.0: safer-buffer "^2.0.2" tweetnacl "~0.14.0" +stack-trace@0.0.10: + version "0.0.10" + resolved "https://registry.yarnpkg.com/stack-trace/-/stack-trace-0.0.10.tgz#547c70b347e8d32b4e108ea1a2a159e5fdde19c0" + integrity sha1-VHxws0fo0ytOEI6hoqFZ5f3eGcA= + static-extend@^0.1.1: version "0.1.2" resolved "https://registry.yarnpkg.com/static-extend/-/static-extend-0.1.2.tgz#60809c39cbff55337226fd5e0b520f341f1fb5c6" @@ -3486,10 +4481,32 @@ static-extend@^0.1.1: define-property "^0.2.5" object-copy "^0.1.0" -stream-consume@~0.1.0: - version "0.1.1" - resolved "https://registry.yarnpkg.com/stream-consume/-/stream-consume-0.1.1.tgz#d3bdb598c2bd0ae82b8cac7ac50b1107a7996c48" - integrity sha512-tNa3hzgkjEP7XbCkbRXe1jpg+ievoa0O4SCFlMOYEscGSS4JJsckGL8swUyAa/ApGU3Ae4t6Honor4HhL+tRyg== +stream-exhaust@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/stream-exhaust/-/stream-exhaust-1.0.2.tgz#acdac8da59ef2bc1e17a2c0ccf6c320d120e555d" + integrity sha512-b/qaq/GlBK5xaq1yrK9/zFcyRSTNxmcZwFLGSTG0mXgZl/4Z6GgiyYOXOvY7N3eEvFRAG1bkDRz5EPGSvPYQlw== + +stream-shift@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/stream-shift/-/stream-shift-1.0.0.tgz#d5c752825e5367e786f78e18e445ea223a155952" + integrity sha1-1cdSgl5TZ+eG944Y5EXqIjoVWVI= + +string-width@^1.0.1, string-width@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-1.0.2.tgz#118bdf5b8cdc51a2a7e70d211e07e2b0b9b107d3" + integrity sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M= + dependencies: + code-point-at "^1.0.0" + is-fullwidth-code-point "^1.0.0" + strip-ansi "^3.0.0" + +"string-width@^1.0.2 || 2", string-width@^2.1.0, string-width@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-2.1.1.tgz#ab93f27a8dc13d28cac815c462143a6d9012ae9e" + integrity sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw== + dependencies: + is-fullwidth-code-point "^2.0.0" + strip-ansi "^4.0.0" string_decoder@~0.10.x: version "0.10.31" @@ -3503,37 +4520,43 @@ string_decoder@~1.0.3: dependencies: safe-buffer "~5.1.0" +string_decoder@~1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.1.1.tgz#9cf1611ba62685d7030ae9e4ba34149c3af03fc8" + integrity sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg== + dependencies: + safe-buffer "~5.1.0" + stringstream@~0.0.5: version "0.0.6" resolved "https://registry.yarnpkg.com/stringstream/-/stringstream-0.0.6.tgz#7880225b0d4ad10e30927d167a1d6f2fd3b33a72" integrity sha512-87GEBAkegbBcweToUrdzf3eLhWNg06FJTebl4BVJz/JgWy8CvEr9dRtX5qWphiynMSQlxxi+QqN0z5T32SLlhA== -strip-ansi@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-2.0.1.tgz#df62c1aa94ed2f114e1d0f21fd1d50482b79a60e" - integrity sha1-32LBqpTtLxFOHQ8h/R1QSCt5pg4= - dependencies: - ansi-regex "^1.0.0" - -strip-ansi@^3.0.0: +strip-ansi@^3.0.0, strip-ansi@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf" integrity sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8= dependencies: ansi-regex "^2.0.0" -strip-bom@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-1.0.0.tgz#85b8862f3844b5a6d5ec8467a93598173a36f794" - integrity sha1-hbiGLzhEtabV7IRnqTWYFzo295Q= +strip-ansi@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-4.0.0.tgz#a8479022eb1ac368a871389b635262c505ee368f" + integrity sha1-qEeQIusaw2iocTibY1JixQXuNo8= + dependencies: + ansi-regex "^3.0.0" + +strip-bom@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-2.0.0.tgz#6219a85616520491f35788bdbf1447a99c7e6b0e" + integrity sha1-YhmoVhZSBJHzV4i9vxRHqZx+aw4= dependencies: - first-chunk-stream "^1.0.0" is-utf8 "^0.2.0" -strip-json-comments@~1.0.1: - version "1.0.4" - resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-1.0.4.tgz#1e15fbcac97d3ee99bf2d73b4c656b082bbafb91" - integrity sha1-HhX7ysl9Pumb8tc7TGVrCCu6+5E= +strip-json-comments@~2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" + integrity sha1-PFMZQukIwml8DsNEhYwobHygpgo= supports-color@1.2.0: version "1.2.0" @@ -3552,13 +4575,46 @@ supports-color@^3.1.0: dependencies: has-flag "^1.0.0" -supports-color@^5.5.0: +supports-color@^5.3.0, supports-color@^5.5.0: version "5.5.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== dependencies: has-flag "^3.0.0" +sver-compat@^1.5.0: + version "1.5.0" + resolved "https://registry.yarnpkg.com/sver-compat/-/sver-compat-1.5.0.tgz#3cf87dfeb4d07b4a3f14827bc186b3fd0c645cd8" + integrity sha1-PPh9/rTQe0o/FIJ7wYaz/QxkXNg= + dependencies: + es6-iterator "^2.0.1" + es6-symbol "^3.1.1" + +table@4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/table/-/table-4.0.2.tgz#a33447375391e766ad34d3486e6e2aedc84d2e36" + integrity sha512-UUkEAPdSGxtRpiV9ozJ5cMTtYiqz7Ni1OGqLXRCynrvzdtR1p+cfOWe2RJLwvUG8hNanaSRjecIqwOjqeatDsA== + dependencies: + ajv "^5.2.3" + ajv-keywords "^2.1.0" + chalk "^2.1.0" + lodash "^4.17.4" + slice-ansi "1.0.0" + string-width "^2.1.1" + +tar@^4: + version "4.4.10" + resolved "https://registry.yarnpkg.com/tar/-/tar-4.4.10.tgz#946b2810b9a5e0b26140cf78bea6b0b0d689eba1" + integrity sha512-g2SVs5QIxvo6OLp0GudTqEf05maawKUxXru104iaayWA09551tFCTI8f1Asb4lPfkBr91k07iL4c11XO3/b0tA== + dependencies: + chownr "^1.1.1" + fs-minipass "^1.2.5" + minipass "^2.3.5" + minizlib "^1.2.1" + mkdirp "^0.5.0" + safe-buffer "^5.1.2" + yallist "^3.0.3" + temp@^0.8.3: version "0.8.3" resolved "https://registry.yarnpkg.com/temp/-/temp-0.8.3.tgz#e0c6bc4d26b903124410e4fed81103014dfc1f59" @@ -3577,13 +4633,13 @@ text-table@~0.2.0: resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" integrity sha1-f17oI66AUgfACvLfSoTsP8+lcLQ= -through2@^0.6.1: - version "0.6.5" - resolved "https://registry.yarnpkg.com/through2/-/through2-0.6.5.tgz#41ab9c67b29d57209071410e1d7a7a968cd3ad48" - integrity sha1-QaucZ7KdVyCQcUEOHXp6lozTrUg= +through2-filter@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/through2-filter/-/through2-filter-3.0.0.tgz#700e786df2367c2c88cd8aa5be4cf9c1e7831254" + integrity sha512-jaRjI2WxN3W1V8/FMZ9HKIBXixtiqs3SQSX4/YGIiP3gL6djW48VoZq9tDqeCWs3MT8YY5wb/zli8VW8snY1CA== dependencies: - readable-stream ">=1.0.33-1 <1.1.0-0" - xtend ">=4.0.0 <4.1.0-0" + through2 "~2.0.0" + xtend "~4.0.0" through2@^2, through2@^2.0.0, through2@^2.0.1: version "2.0.3" @@ -3593,27 +4649,43 @@ through2@^2, through2@^2.0.0, through2@^2.0.1: readable-stream "^2.1.5" xtend "~4.0.1" +through2@^2.0.3, through2@~2.0.0: + version "2.0.5" + resolved "https://registry.yarnpkg.com/through2/-/through2-2.0.5.tgz#01c1e39eb31d07cb7d03a96a70823260b23132cd" + integrity sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ== + dependencies: + readable-stream "~2.3.6" + xtend "~4.0.1" + through@^2.3.4, through@^2.3.6: version "2.3.8" resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" integrity sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU= -tildify@^1.0.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/tildify/-/tildify-1.2.0.tgz#dcec03f55dca9b7aa3e5b04f21817eb56e63588a" - integrity sha1-3OwD9V3Km3qj5bBPIYF+tW5jWIo= - dependencies: - os-homedir "^1.0.0" - time-stamp@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/time-stamp/-/time-stamp-1.1.0.tgz#764a5a11af50561921b133f3b44e618687e0f5c3" integrity sha1-dkpaEa9QVhkhsTPztE5hhofg9cM= -to-fast-properties@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-1.0.3.tgz#b83571fa4d8c25b82e231b06e3a3055de4ca1a47" - integrity sha1-uDVx+k2MJbguIxsG46MFXeTKGkc= +tmp@^0.0.33: + version "0.0.33" + resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.0.33.tgz#6d34335889768d21b2bcda0aa277ced3b1bfadf9" + integrity sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw== + dependencies: + os-tmpdir "~1.0.2" + +to-absolute-glob@^2.0.0: + version "2.0.2" + resolved "https://registry.yarnpkg.com/to-absolute-glob/-/to-absolute-glob-2.0.2.tgz#1865f43d9e74b0822db9f145b78cff7d0f7c849b" + integrity sha1-GGX0PZ50sIItufFFt4z/fQ98hJs= + dependencies: + is-absolute "^1.0.0" + is-negated-glob "^1.0.0" + +to-fast-properties@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz#dc5e698cbd079265bc73e0377681a4e4e83f616e" + integrity sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4= to-iso-string@0.0.2: version "0.0.2" @@ -3645,6 +4717,13 @@ to-regex@^3.0.1, to-regex@^3.0.2: regex-not "^1.0.2" safe-regex "^1.1.0" +to-through@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/to-through/-/to-through-2.0.0.tgz#fc92adaba072647bc0b67d6b03664aa195093af6" + integrity sha1-/JKtq6ByZHvAtn1rA2ZKoZUJOvY= + dependencies: + through2 "^2.0.3" + tough-cookie@~2.3.3: version "2.3.3" resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.3.tgz#0b618a5565b6dea90bf3425d04d55edc475a7561" @@ -3691,6 +4770,11 @@ type-detect@^1.0.0: resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-1.0.0.tgz#762217cc06db258ec48908a1298e8b95121e8ea2" integrity sha1-diIXzAbbJY7EiQihKY6LlRIejqI= +type@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/type/-/type-1.0.1.tgz#084c9a17fcc9151a2cdb1459905c2e45e4bb7d61" + integrity sha512-MAM5dBMJCJNKs9E7JXo4CXRAansRfG0nlJxW7Wf6GZzSOvH31zClSaHdIMWLehe/EGMBkqeC55rrkaOr5Oo7Nw== + typedarray@^0.0.6: version "0.0.6" resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" @@ -3709,6 +4793,49 @@ unc-path-regex@^0.1.2: resolved "https://registry.yarnpkg.com/unc-path-regex/-/unc-path-regex-0.1.2.tgz#e73dd3d7b0d7c5ed86fbac6b0ae7d8c6a69d50fa" integrity sha1-5z3T17DXxe2G+6xrCufYxqadUPo= +undertaker-registry@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/undertaker-registry/-/undertaker-registry-1.0.1.tgz#5e4bda308e4a8a2ae584f9b9a4359a499825cc50" + integrity sha1-XkvaMI5KiirlhPm5pDWaSZglzFA= + +undertaker@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/undertaker/-/undertaker-1.2.1.tgz#701662ff8ce358715324dfd492a4f036055dfe4b" + integrity sha512-71WxIzDkgYk9ZS+spIB8iZXchFhAdEo2YU8xYqBYJ39DIUIqziK78ftm26eecoIY49X0J2MLhG4hr18Yp6/CMA== + dependencies: + arr-flatten "^1.0.1" + arr-map "^2.0.0" + bach "^1.0.0" + collection-map "^1.0.0" + es6-weak-map "^2.0.1" + last-run "^1.1.0" + object.defaults "^1.0.0" + object.reduce "^1.0.0" + undertaker-registry "^1.0.0" + +unicode-canonical-property-names-ecmascript@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-1.0.4.tgz#2619800c4c825800efdd8343af7dd9933cbe2818" + integrity sha512-jDrNnXWHd4oHiTZnx/ZG7gtUTVp+gCcTTKr8L0HjlwphROEW3+Him+IpvC+xcJEFegapiMZyZe02CyuOnRmbnQ== + +unicode-match-property-ecmascript@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/unicode-match-property-ecmascript/-/unicode-match-property-ecmascript-1.0.4.tgz#8ed2a32569961bce9227d09cd3ffbb8fed5f020c" + integrity sha512-L4Qoh15vTfntsn4P1zqnHulG0LdXgjSO035fEpdtp6YxXhMT51Q6vgM5lYdG/5X3MjS+k/Y9Xw4SFCY9IkR0rg== + dependencies: + unicode-canonical-property-names-ecmascript "^1.0.4" + unicode-property-aliases-ecmascript "^1.0.4" + +unicode-match-property-value-ecmascript@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-1.1.0.tgz#5b4b426e08d13a80365e0d657ac7a6c1ec46a277" + integrity sha512-hDTHvaBk3RmFzvSl0UVrUmC3PuW9wKVnpoUDYH0JDkSIovzw+J5viQmeYHxVSBptubnr7PbH2e0fnpDRQnQl5g== + +unicode-property-aliases-ecmascript@^1.0.4: + version "1.0.5" + resolved "https://registry.yarnpkg.com/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-1.0.5.tgz#a9cc6cc7ce63a0a3023fc99e341b94431d405a57" + integrity sha512-L5RAqCfXqAwR3RriF8pM0lU0w4Ryf/GgzONwi6KnL1taJQa7x1TCxdJnILX59WIGOwR57IVxn7Nej0fz1Ny6fw== + union-value@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/union-value/-/union-value-1.0.0.tgz#5c71c34cb5bad5dcebe3ea0cd08207ba5aa1aea4" @@ -3719,10 +4846,13 @@ union-value@^1.0.0: is-extendable "^0.1.1" set-value "^0.4.3" -unique-stream@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/unique-stream/-/unique-stream-1.0.0.tgz#d59a4a75427447d9aa6c91e70263f8d26a4b104b" - integrity sha1-1ZpKdUJ0R9mqbJHnAmP40mpLEEs= +unique-stream@^2.0.2: + version "2.3.1" + resolved "https://registry.yarnpkg.com/unique-stream/-/unique-stream-2.3.1.tgz#c65d110e9a4adf9a6c5948b28053d9a8d04cbeac" + integrity sha512-2nY4TnBE70yoxHkDli7DMazpWiP7xMdCYqU2nBRO0UB+ZpEkGsSija7MvmvnZFUeC+mrgiUfcHSr3LmRFIg4+A== + dependencies: + json-stable-stringify-without-jsonify "^1.0.1" + through2-filter "^3.0.0" unset-value@^1.0.0: version "1.0.0" @@ -3732,6 +4862,11 @@ unset-value@^1.0.0: has-value "^0.3.1" isobject "^3.0.0" +upath@^1.1.1: + version "1.1.2" + resolved "https://registry.yarnpkg.com/upath/-/upath-1.1.2.tgz#3db658600edaeeccbe6db5e684d67ee8c2acd068" + integrity sha512-kXpym8nmDmlCBr7nKdIx8P2jNBa+pBpIUFRnKJ4dr8htyYGJFokkr2ZvERRtUN+9SY+JqXouNgUPtv6JQva/2Q== + urix@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/urix/-/urix-0.1.0.tgz#da937f7a62e21fec1fd18d49b35c2935067a6c72" @@ -3744,11 +4879,6 @@ use@^3.1.0: dependencies: kind-of "^6.0.2" -user-home@^1.0.0, user-home@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/user-home/-/user-home-1.1.1.tgz#2b5be23a32b63a7c9deb8d0f28d485724a3df190" - integrity sha1-K1viOjK2Onyd640PKNSFcko98ZA= - util-deprecate@~1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" @@ -3759,12 +4889,25 @@ uuid@^3.1.0: resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.1.0.tgz#3dd3d3e790abc24d7b0d3a034ffababe28ebbc04" integrity sha512-DIWtzUkw04M4k3bf1IcpS2tngXEL26YUD2M0tMDUpnUrz2hgzUBlD55a4FjdLGPvfHxS6uluGWvaVEqgBcVa+g== -v8flags@^2.0.2: - version "2.1.1" - resolved "https://registry.yarnpkg.com/v8flags/-/v8flags-2.1.1.tgz#aab1a1fa30d45f88dd321148875ac02c0b55e5b4" - integrity sha1-qrGh+jDUX4jdMhFIh1rALAtV5bQ= +v8flags@^3.0.1: + version "3.1.3" + resolved "https://registry.yarnpkg.com/v8flags/-/v8flags-3.1.3.tgz#fc9dc23521ca20c5433f81cc4eb9b3033bb105d8" + integrity sha512-amh9CCg3ZxkzQ48Mhcb8iX7xpAfYJgePHxWMQCBWECpOSqJUXgY26ncA61UTV0BkPqfhcy6mzwCIoP4ygxpW8w== + dependencies: + homedir-polyfill "^1.0.1" + +validate-npm-package-license@^3.0.1: + version "3.0.4" + resolved "https://registry.yarnpkg.com/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz#fc91f6b9c7ba15c857f4cb2c5defeec39d4f410a" + integrity sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew== dependencies: - user-home "^1.1.1" + spdx-correct "^3.0.0" + spdx-expression-parse "^3.0.0" + +value-or-function@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/value-or-function/-/value-or-function-3.0.0.tgz#1c243a50b595c1be54a754bfece8563b9ff8d813" + integrity sha1-HCQ6ULWVwb5Up1S/7OhWO5/42BM= verror@1.10.0: version "1.10.0" @@ -3775,19 +4918,41 @@ verror@1.10.0: core-util-is "1.0.2" extsprintf "^1.2.0" -vinyl-fs@^0.3.0: - version "0.3.14" - resolved "https://registry.yarnpkg.com/vinyl-fs/-/vinyl-fs-0.3.14.tgz#9a6851ce1cac1c1cea5fe86c0931d620c2cfa9e6" - integrity sha1-mmhRzhysHBzqX+hsCTHWIMLPqeY= +vinyl-fs@^3.0.0: + version "3.0.3" + resolved "https://registry.yarnpkg.com/vinyl-fs/-/vinyl-fs-3.0.3.tgz#c85849405f67428feabbbd5c5dbdd64f47d31bc7" + integrity sha512-vIu34EkyNyJxmP0jscNzWBSygh7VWhqun6RmqVfXePrOwi9lhvRs//dOaGOTRUQr4tx7/zd26Tk5WeSVZitgng== + dependencies: + fs-mkdirp-stream "^1.0.0" + glob-stream "^6.1.0" + graceful-fs "^4.0.0" + is-valid-glob "^1.0.0" + lazystream "^1.0.0" + lead "^1.0.0" + object.assign "^4.0.4" + pumpify "^1.3.5" + readable-stream "^2.3.3" + remove-bom-buffer "^3.0.0" + remove-bom-stream "^1.2.0" + resolve-options "^1.1.0" + through2 "^2.0.0" + to-through "^2.0.0" + value-or-function "^3.0.0" + vinyl "^2.0.0" + vinyl-sourcemap "^1.1.0" + +vinyl-sourcemap@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/vinyl-sourcemap/-/vinyl-sourcemap-1.1.0.tgz#92a800593a38703a8cdb11d8b300ad4be63b3e16" + integrity sha1-kqgAWTo4cDqM2xHYswCtS+Y7PhY= dependencies: - defaults "^1.0.0" - glob-stream "^3.1.5" - glob-watcher "^0.0.6" - graceful-fs "^3.0.0" - mkdirp "^0.5.0" - strip-bom "^1.0.0" - through2 "^0.6.1" - vinyl "^0.4.0" + append-buffer "^1.0.2" + convert-source-map "^1.5.0" + graceful-fs "^4.1.6" + normalize-path "^2.1.1" + now-and-later "^2.0.0" + remove-bom-buffer "^3.0.0" + vinyl "^2.0.0" vinyl-sourcemaps-apply@^0.2.0: version "0.2.1" @@ -3796,14 +4961,6 @@ vinyl-sourcemaps-apply@^0.2.0: dependencies: source-map "^0.5.1" -vinyl@^0.4.0: - version "0.4.6" - resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-0.4.6.tgz#2f356c87a550a255461f36bbeb2a5ba8bf784847" - integrity sha1-LzVsh6VQolVGHza76ypbqL94SEc= - dependencies: - clone "^0.2.0" - clone-stats "^0.0.1" - vinyl@^0.5.0: version "0.5.3" resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-0.5.3.tgz#b0455b38fc5e0cf30d4325132e461970c2091cde" @@ -3813,6 +4970,23 @@ vinyl@^0.5.0: clone-stats "^0.0.1" replace-ext "0.0.1" +vinyl@^2.0.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-2.2.0.tgz#d85b07da96e458d25b2ffe19fece9f2caa13ed86" + integrity sha512-MBH+yP0kC/GQ5GwBqrTPTzEfiiLjta7hTtvQtbxBgTeSXsmKQRQecjibMbxIXzVT3Y9KJK+drOz1/k+vsu8Nkg== + dependencies: + clone "^2.1.1" + clone-buffer "^1.0.0" + clone-stats "^1.0.0" + cloneable-readable "^1.0.0" + remove-trailing-separator "^1.0.1" + replace-ext "^1.0.0" + +which-module@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/which-module/-/which-module-1.0.0.tgz#bba63ca861948994ff307736089e3b96026c2a4f" + integrity sha1-u6Y8qGGUiZT/MHc2CJ47lgJsKk8= + which@^1.1.1, which@^1.2.14: version "1.3.0" resolved "https://registry.yarnpkg.com/which/-/which-1.3.0.tgz#ff04bdfc010ee547d780bec38e1ac1c2777d253a" @@ -3820,6 +4994,20 @@ which@^1.1.1, which@^1.2.14: dependencies: isexe "^2.0.0" +which@^1.2.9: + version "1.3.1" + resolved "https://registry.yarnpkg.com/which/-/which-1.3.1.tgz#a45043d54f5805316da8d62f9f50918d3da70b0a" + integrity sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ== + dependencies: + isexe "^2.0.0" + +wide-align@^1.1.0: + version "1.1.3" + resolved "https://registry.yarnpkg.com/wide-align/-/wide-align-1.1.3.tgz#ae074e6bdc0c14a431e804e624549c633b000457" + integrity sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA== + dependencies: + string-width "^1.0.2 || 2" + wordwrap@^1.0.0, wordwrap@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" @@ -3830,17 +5018,68 @@ wordwrap@~0.0.2: resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.3.tgz#a3d5da6cd5c0bc0008d37234bbaf1bed63059107" integrity sha1-o9XabNXAvAAI03I0u68b7WMFkQc= +wrap-ansi@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-2.1.0.tgz#d8fc3d284dd05794fe84973caecdd1cf824fdd85" + integrity sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU= + dependencies: + string-width "^1.0.1" + strip-ansi "^3.0.1" + wrappy@1: version "1.0.2" resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= -xml-escape@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/xml-escape/-/xml-escape-1.0.0.tgz#00963d697b2adf0c185c4e04e73174ba9b288eb2" - integrity sha1-AJY9aXsq3wwYXE4E5zF0upsojrI= +write@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/write/-/write-0.2.1.tgz#5fc03828e264cea3fe91455476f7a3c566cb0757" + integrity sha1-X8A4KOJkzqP+kUVUdvejxWbLB1c= + dependencies: + mkdirp "^0.5.1" -"xtend@>=4.0.0 <4.1.0-0", xtend@^4.0.0, xtend@~4.0.1: +xtend@~4.0.0, xtend@~4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.1.tgz#a5c6d532be656e23db820efb943a1f04998d63af" integrity sha1-pcbVMr5lbiPbgg77lDofBJmNY68= + +y18n@^3.2.1: + version "3.2.1" + resolved "https://registry.yarnpkg.com/y18n/-/y18n-3.2.1.tgz#6d15fba884c08679c0d77e88e7759e811e07fa41" + integrity sha1-bRX7qITAhnnA136I53WegR4H+kE= + +yallist@^2.1.2: + version "2.1.2" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz#1c11f9218f076089a47dd512f93c6699a6a81d52" + integrity sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI= + +yallist@^3.0.0, yallist@^3.0.3: + version "3.0.3" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.0.3.tgz#b4b049e314be545e3ce802236d6cd22cd91c3de9" + integrity sha512-S+Zk8DEWE6oKpV+vI3qWkaK+jSbIK86pCwe2IF/xwIpQ8jEuxpw9NyaGjmp9+BoJv5FV2piqCDcoCtStppiq2A== + +yargs-parser@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-5.0.0.tgz#275ecf0d7ffe05c77e64e7c86e4cd94bf0e1228a" + integrity sha1-J17PDX/+Bcd+ZOfIbkzZS/DhIoo= + dependencies: + camelcase "^3.0.0" + +yargs@^7.1.0: + version "7.1.0" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-7.1.0.tgz#6ba318eb16961727f5d284f8ea003e8d6154d0c8" + integrity sha1-a6MY6xaWFyf10oT46gA+jWFU0Mg= + dependencies: + camelcase "^3.0.0" + cliui "^3.2.0" + decamelize "^1.1.1" + get-caller-file "^1.0.1" + os-locale "^1.4.0" + read-pkg-up "^1.0.1" + require-directory "^2.1.1" + require-main-filename "^1.0.1" + set-blocking "^2.0.0" + string-width "^1.0.2" + which-module "^1.0.0" + y18n "^3.2.1" + yargs-parser "^5.0.0" From 575b9f201a7e56093c0a3e712a2694e70e96cb7f Mon Sep 17 00:00:00 2001 From: Matt Donnelly Date: Wed, 3 Jul 2019 19:36:24 +0100 Subject: [PATCH 010/146] Fix babel-register and tests gulp task --- gulpfile.js | 15 +- package.json | 1 + yarn.lock | 837 +++++++-------------------------------------------- 3 files changed, 123 insertions(+), 730 deletions(-) diff --git a/gulpfile.js b/gulpfile.js index 5e58e58f..3e37b075 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -6,6 +6,8 @@ var istanbul = require('gulp-istanbul'); var plumber = require('gulp-plumber'); var babel = require('gulp-babel'); +require('@babel/register'); + gulp.task('static', function () { return gulp .src('**/*.js') @@ -25,18 +27,11 @@ gulp.task('pre-test', function () { gulp.task( 'test', - gulp.series('pre-test', function (done) { - var mochaErr; - gulp + gulp.series('pre-test', function () { + return gulp .src('test/**/*.js') .pipe(plumber()) - .pipe(mocha({ reporter: 'spec' })) - .on('error', function (err) { - mochaErr = err; - }) - .on('end', function () { - done(mochaErr); - }); + .pipe(mocha({ reporter: 'spec' })); }) ); diff --git a/package.json b/package.json index 10c2e863..d8ac3915 100644 --- a/package.json +++ b/package.json @@ -26,6 +26,7 @@ "devDependencies": { "@babel/core": "^7.4.5", "@babel/preset-env": "^7.4.5", + "@babel/register": "^7.4.4", "babel-eslint": "^10.0.2", "gulp": "^4.0.2", "gulp-babel": "^8.0.0", diff --git a/yarn.lock b/yarn.lock index b4564d73..28409aa8 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5,14 +5,12 @@ "@babel/code-frame@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0.tgz#06e2ab19bdb535385559aabb5ba59729482800f8" - integrity sha512-OfC2uemaknXr87bdLUkWog7nYuliM9Ij5HUcajsVcMCpQrcLmtxRbVFTIqmcSkSeYRBFBRxs2FiUqFJDLdiebA== dependencies: "@babel/highlight" "^7.0.0" "@babel/core@^7.4.5": version "7.4.5" resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.4.5.tgz#081f97e8ffca65a9b4b0fdc7e274e703f000c06a" - integrity sha512-OvjIh6aqXtlsA8ujtGKfC7LYWksYSX8yQcM8Ay3LuvVeQ63lcOKgoZWVqcpFwkd29aYU9rVx7jxhfhiEDV9MZA== dependencies: "@babel/code-frame" "^7.0.0" "@babel/generator" "^7.4.4" @@ -32,7 +30,6 @@ "@babel/generator@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.4.4.tgz#174a215eb843fc392c7edcaabeaa873de6e8f041" - integrity sha512-53UOLK6TVNqKxf7RUh8NE851EHRxOOeVXKbK2bivdb+iziMyk03Sr4eaE9OELCbyZAAafAKPDwF2TPUES5QbxQ== dependencies: "@babel/types" "^7.4.4" jsesc "^2.5.1" @@ -43,14 +40,12 @@ "@babel/helper-annotate-as-pure@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.0.0.tgz#323d39dd0b50e10c7c06ca7d7638e6864d8c5c32" - integrity sha512-3UYcJUj9kvSLbLbUIfQTqzcy5VX7GRZ/CCDrnOaZorFFM01aXp1+GJwuFGV4NDDoAS+mOUyHcO6UD/RfqOks3Q== dependencies: "@babel/types" "^7.0.0" "@babel/helper-builder-binary-assignment-operator-visitor@^7.1.0": version "7.1.0" resolved "https://registry.yarnpkg.com/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.1.0.tgz#6b69628dfe4087798e0c4ed98e3d4a6b2fbd2f5f" - integrity sha512-qNSR4jrmJ8M1VMM9tibvyRAHXQs2PmaksQF7c1CGJNipfe3D8p+wgNwgso/P2A2r2mdgBWAXljNWR0QRZAMW8w== dependencies: "@babel/helper-explode-assignable-expression" "^7.1.0" "@babel/types" "^7.0.0" @@ -58,7 +53,6 @@ "@babel/helper-call-delegate@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/helper-call-delegate/-/helper-call-delegate-7.4.4.tgz#87c1f8ca19ad552a736a7a27b1c1fcf8b1ff1f43" - integrity sha512-l79boDFJ8S1c5hvQvG+rc+wHw6IuH7YldmRKsYtpbawsxURu/paVy57FZMomGK22/JckepaikOkY0MoAmdyOlQ== dependencies: "@babel/helper-hoist-variables" "^7.4.4" "@babel/traverse" "^7.4.4" @@ -67,7 +61,6 @@ "@babel/helper-define-map@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/helper-define-map/-/helper-define-map-7.4.4.tgz#6969d1f570b46bdc900d1eba8e5d59c48ba2c12a" - integrity sha512-IX3Ln8gLhZpSuqHJSnTNBWGDE9kdkTEWl21A/K7PQ00tseBwbqCHTvNLHSBd9M0R5rER4h5Rsvj9vw0R5SieBg== dependencies: "@babel/helper-function-name" "^7.1.0" "@babel/types" "^7.4.4" @@ -76,7 +69,6 @@ "@babel/helper-explode-assignable-expression@^7.1.0": version "7.1.0" resolved "https://registry.yarnpkg.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.1.0.tgz#537fa13f6f1674df745b0c00ec8fe4e99681c8f6" - integrity sha512-NRQpfHrJ1msCHtKjbzs9YcMmJZOg6mQMmGRB+hbamEdG5PNpaSm95275VD92DvJKuyl0s2sFiDmMZ+EnnvufqA== dependencies: "@babel/traverse" "^7.1.0" "@babel/types" "^7.0.0" @@ -84,7 +76,6 @@ "@babel/helper-function-name@^7.1.0": version "7.1.0" resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.1.0.tgz#a0ceb01685f73355d4360c1247f582bfafc8ff53" - integrity sha512-A95XEoCpb3TO+KZzJ4S/5uW5fNe26DjBGqf1o9ucyLyCmi1dXq/B3c8iaWTfBk3VvetUxl16e8tIrd5teOCfGw== dependencies: "@babel/helper-get-function-arity" "^7.0.0" "@babel/template" "^7.1.0" @@ -93,35 +84,30 @@ "@babel/helper-get-function-arity@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0.tgz#83572d4320e2a4657263734113c42868b64e49c3" - integrity sha512-r2DbJeg4svYvt3HOS74U4eWKsUAMRH01Z1ds1zx8KNTPtpTL5JAsdFv8BNyOpVqdFhHkkRDIg5B4AsxmkjAlmQ== dependencies: "@babel/types" "^7.0.0" "@babel/helper-hoist-variables@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.4.4.tgz#0298b5f25c8c09c53102d52ac4a98f773eb2850a" - integrity sha512-VYk2/H/BnYbZDDg39hr3t2kKyifAm1W6zHRfhx8jGjIHpQEBv9dry7oQ2f3+J703TLu69nYdxsovl0XYfcnK4w== dependencies: "@babel/types" "^7.4.4" "@babel/helper-member-expression-to-functions@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.0.0.tgz#8cd14b0a0df7ff00f009e7d7a436945f47c7a16f" - integrity sha512-avo+lm/QmZlv27Zsi0xEor2fKcqWG56D5ae9dzklpIaY7cQMK5N8VSpaNVPPagiqmy7LrEjK1IWdGMOqPu5csg== dependencies: "@babel/types" "^7.0.0" "@babel/helper-module-imports@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.0.0.tgz#96081b7111e486da4d2cd971ad1a4fe216cc2e3d" - integrity sha512-aP/hlLq01DWNEiDg4Jn23i+CXxW/owM4WpDLFUbpjxe4NS3BhLVZQ5i7E0ZrxuQ/vwekIeciyamgB1UIYxxM6A== dependencies: "@babel/types" "^7.0.0" "@babel/helper-module-transforms@^7.1.0", "@babel/helper-module-transforms@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.4.4.tgz#96115ea42a2f139e619e98ed46df6019b94414b8" - integrity sha512-3Z1yp8TVQf+B4ynN7WoHPKS8EkdTbgAEy0nU0rs/1Kw4pDgmvYH3rz3aI11KgxKCba2cn7N+tqzV1mY2HMN96w== dependencies: "@babel/helper-module-imports" "^7.0.0" "@babel/helper-simple-access" "^7.1.0" @@ -133,26 +119,22 @@ "@babel/helper-optimise-call-expression@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.0.0.tgz#a2920c5702b073c15de51106200aa8cad20497d5" - integrity sha512-u8nd9NQePYNQV8iPWu/pLLYBqZBa4ZaY1YWRFMuxrid94wKI1QNt67NEZ7GAe5Kc/0LLScbim05xZFWkAdrj9g== dependencies: "@babel/types" "^7.0.0" "@babel/helper-plugin-utils@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.0.0.tgz#bbb3fbee98661c569034237cc03967ba99b4f250" - integrity sha512-CYAOUCARwExnEixLdB6sDm2dIJ/YgEAKDM1MOeMeZu9Ld/bDgVo8aiWrXwcY7OBh+1Ea2uUcVRcxKk0GJvW7QA== "@babel/helper-regex@^7.0.0", "@babel/helper-regex@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/helper-regex/-/helper-regex-7.4.4.tgz#a47e02bc91fb259d2e6727c2a30013e3ac13c4a2" - integrity sha512-Y5nuB/kESmR3tKjU8Nkn1wMGEx1tjJX076HBMeL3XLQCu6vA/YRzuTW0bbb+qRnXvQGn+d6Rx953yffl8vEy7Q== dependencies: lodash "^4.17.11" "@babel/helper-remap-async-to-generator@^7.1.0": version "7.1.0" resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.1.0.tgz#361d80821b6f38da75bd3f0785ece20a88c5fe7f" - integrity sha512-3fOK0L+Fdlg8S5al8u/hWE6vhufGSn0bN09xm2LXMy//REAF8kDCrYoOBKYmA8m5Nom+sV9LyLCwrFynA8/slg== dependencies: "@babel/helper-annotate-as-pure" "^7.0.0" "@babel/helper-wrap-function" "^7.1.0" @@ -163,7 +145,6 @@ "@babel/helper-replace-supers@^7.1.0", "@babel/helper-replace-supers@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.4.4.tgz#aee41783ebe4f2d3ab3ae775e1cc6f1a90cefa27" - integrity sha512-04xGEnd+s01nY1l15EuMS1rfKktNF+1CkKmHoErDppjAAZL+IUBZpzT748x262HF7fibaQPhbvWUl5HeSt1EXg== dependencies: "@babel/helper-member-expression-to-functions" "^7.0.0" "@babel/helper-optimise-call-expression" "^7.0.0" @@ -173,7 +154,6 @@ "@babel/helper-simple-access@^7.1.0": version "7.1.0" resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.1.0.tgz#65eeb954c8c245beaa4e859da6188f39d71e585c" - integrity sha512-Vk+78hNjRbsiu49zAPALxTb+JUQCz1aolpd8osOF16BGnLtseD21nbHgLPGUwrXEurZgiCOUmvs3ExTu4F5x6w== dependencies: "@babel/template" "^7.1.0" "@babel/types" "^7.0.0" @@ -181,14 +161,12 @@ "@babel/helper-split-export-declaration@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.4.4.tgz#ff94894a340be78f53f06af038b205c49d993677" - integrity sha512-Ro/XkzLf3JFITkW6b+hNxzZ1n5OQ80NvIUdmHspih1XAhtN3vPTuUFT4eQnela+2MaZ5ulH+iyP513KJrxbN7Q== dependencies: "@babel/types" "^7.4.4" "@babel/helper-wrap-function@^7.1.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/helper-wrap-function/-/helper-wrap-function-7.2.0.tgz#c4e0012445769e2815b55296ead43a958549f6fa" - integrity sha512-o9fP1BZLLSrYlxYEYyl2aS+Flun5gtjTIG8iln+XuEzQTs0PLagAGSXUcqruJwD5fM48jzIEggCKpIfWTcR7pQ== dependencies: "@babel/helper-function-name" "^7.1.0" "@babel/template" "^7.1.0" @@ -198,7 +176,6 @@ "@babel/helpers@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.4.4.tgz#868b0ef59c1dd4e78744562d5ce1b59c89f2f2a5" - integrity sha512-igczbR/0SeuPR8RFfC7tGrbdTbFL3QTvH6D+Z6zNxnTe//GyqmtHmDkzrqDmyZ3eSwPqB/LhyKoU5DXsp+Vp2A== dependencies: "@babel/template" "^7.4.4" "@babel/traverse" "^7.4.4" @@ -207,7 +184,6 @@ "@babel/highlight@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.0.0.tgz#f710c38c8d458e6dd9a201afb637fcb781ce99e4" - integrity sha512-UFMC4ZeFC48Tpvj7C8UgLvtkaUuovQX+5xNWrsIoMG8o2z+XFKjKaN9iVmS84dPwVN00W4wPmqvYoZF3EGAsfw== dependencies: chalk "^2.0.0" esutils "^2.0.2" @@ -216,12 +192,10 @@ "@babel/parser@^7.0.0", "@babel/parser@^7.4.4", "@babel/parser@^7.4.5": version "7.4.5" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.4.5.tgz#04af8d5d5a2b044a2a1bffacc1e5e6673544e872" - integrity sha512-9mUqkL1FF5T7f0WDFfAoDdiMVPWsdD1gZYzSnaXsxUCUqzuch/8of9G3VUSNiZmMBoRxT3neyVsqeiL/ZPcjew== "@babel/plugin-proposal-async-generator-functions@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.2.0.tgz#b289b306669dce4ad20b0252889a15768c9d417e" - integrity sha512-+Dfo/SCQqrwx48ptLVGLdE39YtWRuKc/Y9I5Fy0P1DDBB9lsAHpjcEJQt+4IifuSOSTLBKJObJqMvaO1pIE8LQ== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/helper-remap-async-to-generator" "^7.1.0" @@ -230,7 +204,6 @@ "@babel/plugin-proposal-json-strings@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.2.0.tgz#568ecc446c6148ae6b267f02551130891e29f317" - integrity sha512-MAFV1CA/YVmYwZG0fBQyXhmj0BHCB5egZHCKWIFVv/XCxAeVGIHfos3SwDck4LvCllENIAg7xMKOG5kH0dzyUg== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-syntax-json-strings" "^7.2.0" @@ -238,7 +211,6 @@ "@babel/plugin-proposal-object-rest-spread@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.4.4.tgz#1ef173fcf24b3e2df92a678f027673b55e7e3005" - integrity sha512-dMBG6cSPBbHeEBdFXeQ2QLc5gUpg4Vkaz8octD4aoW/ISO+jBOcsuxYL7bsb5WSu8RLP6boxrBIALEHgoHtO9g== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-syntax-object-rest-spread" "^7.2.0" @@ -246,7 +218,6 @@ "@babel/plugin-proposal-optional-catch-binding@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.2.0.tgz#135d81edb68a081e55e56ec48541ece8065c38f5" - integrity sha512-mgYj3jCcxug6KUcX4OBoOJz3CMrwRfQELPQ5560F70YQUBZB7uac9fqaWamKR1iWUzGiK2t0ygzjTScZnVz75g== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-syntax-optional-catch-binding" "^7.2.0" @@ -254,7 +225,6 @@ "@babel/plugin-proposal-unicode-property-regex@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.4.4.tgz#501ffd9826c0b91da22690720722ac7cb1ca9c78" - integrity sha512-j1NwnOqMG9mFUOH58JTFsA/+ZYzQLUZ/drqWUqxCYLGeu2JFZL8YrNC9hBxKmWtAuOCHPcRpgv7fhap09Fb4kA== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/helper-regex" "^7.4.4" @@ -263,42 +233,36 @@ "@babel/plugin-syntax-async-generators@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.2.0.tgz#69e1f0db34c6f5a0cf7e2b3323bf159a76c8cb7f" - integrity sha512-1ZrIRBv2t0GSlcwVoQ6VgSLpLgiN/FVQUzt9znxo7v2Ov4jJrs8RY8tv0wvDmFN3qIdMKWrmMMW6yZ0G19MfGg== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-syntax-json-strings@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.2.0.tgz#72bd13f6ffe1d25938129d2a186b11fd62951470" - integrity sha512-5UGYnMSLRE1dqqZwug+1LISpA403HzlSfsg6P9VXU6TBjcSHeNlw4DxDx7LgpF+iKZoOG/+uzqoRHTdcUpiZNg== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-syntax-object-rest-spread@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.2.0.tgz#3b7a3e733510c57e820b9142a6579ac8b0dfad2e" - integrity sha512-t0JKGgqk2We+9may3t0xDdmneaXmyxq0xieYcKHxIsrJO64n1OiMWNUtc5gQK1PA0NpdCRrtZp4z+IUaKugrSA== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-syntax-optional-catch-binding@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.2.0.tgz#a94013d6eda8908dfe6a477e7f9eda85656ecf5c" - integrity sha512-bDe4xKNhb0LI7IvZHiA13kff0KEfaGX/Hv4lMA9+7TEc63hMNvfKo6ZFpXhKuEp+II/q35Gc4NoMeDZyaUbj9w== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-arrow-functions@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.2.0.tgz#9aeafbe4d6ffc6563bf8f8372091628f00779550" - integrity sha512-ER77Cax1+8/8jCB9fo4Ud161OZzWN5qawi4GusDuRLcDbDG+bIGYY20zb2dfAFdTRGzrfq2xZPvF0R64EHnimg== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-async-to-generator@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.4.4.tgz#a3f1d01f2f21cadab20b33a82133116f14fb5894" - integrity sha512-YiqW2Li8TXmzgbXw+STsSqPBPFnGviiaSp6CYOq55X8GQ2SGVLrXB6pNid8HkqkZAzOH6knbai3snhP7v0fNwA== dependencies: "@babel/helper-module-imports" "^7.0.0" "@babel/helper-plugin-utils" "^7.0.0" @@ -307,14 +271,12 @@ "@babel/plugin-transform-block-scoped-functions@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.2.0.tgz#5d3cc11e8d5ddd752aa64c9148d0db6cb79fd190" - integrity sha512-ntQPR6q1/NKuphly49+QiQiTN0O63uOwjdD6dhIjSWBI5xlrbUFh720TIpzBhpnrLfv2tNH/BXvLIab1+BAI0w== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-block-scoping@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.4.4.tgz#c13279fabf6b916661531841a23c4b7dae29646d" - integrity sha512-jkTUyWZcTrwxu5DD4rWz6rDB5Cjdmgz6z7M7RLXOJyCUkFBawssDGcGh8M/0FTSB87avyJI1HsTwUXp9nKA1PA== dependencies: "@babel/helper-plugin-utils" "^7.0.0" lodash "^4.17.11" @@ -322,7 +284,6 @@ "@babel/plugin-transform-classes@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.4.4.tgz#0ce4094cdafd709721076d3b9c38ad31ca715eb6" - integrity sha512-/e44eFLImEGIpL9qPxSRat13I5QNRgBLu2hOQJCF7VLy/otSM/sypV1+XaIw5+502RX/+6YaSAPmldk+nhHDPw== dependencies: "@babel/helper-annotate-as-pure" "^7.0.0" "@babel/helper-define-map" "^7.4.4" @@ -336,21 +297,18 @@ "@babel/plugin-transform-computed-properties@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.2.0.tgz#83a7df6a658865b1c8f641d510c6f3af220216da" - integrity sha512-kP/drqTxY6Xt3NNpKiMomfgkNn4o7+vKxK2DDKcBG9sHj51vHqMBGy8wbDS/J4lMxnqs153/T3+DmCEAkC5cpA== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-destructuring@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.4.4.tgz#9d964717829cc9e4b601fc82a26a71a4d8faf20f" - integrity sha512-/aOx+nW0w8eHiEHm+BTERB2oJn5D127iye/SUQl7NjHy0lf+j7h4MKMMSOwdazGq9OxgiNADncE+SRJkCxjZpQ== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-dotall-regex@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.4.4.tgz#361a148bc951444312c69446d76ed1ea8e4450c3" - integrity sha512-P05YEhRc2h53lZDjRPk/OektxCVevFzZs2Gfjd545Wde3k+yFDbXORgl2e0xpbq8mLcKJ7Idss4fAg0zORN/zg== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/helper-regex" "^7.4.4" @@ -359,14 +317,12 @@ "@babel/plugin-transform-duplicate-keys@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.2.0.tgz#d952c4930f312a4dbfff18f0b2914e60c35530b3" - integrity sha512-q+yuxW4DsTjNceUiTzK0L+AfQ0zD9rWaTLiUqHA8p0gxx7lu1EylenfzjeIWNkPy6e/0VG/Wjw9uf9LueQwLOw== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-exponentiation-operator@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.2.0.tgz#a63868289e5b4007f7054d46491af51435766008" - integrity sha512-umh4hR6N7mu4Elq9GG8TOu9M0bakvlsREEC+ialrQN6ABS4oDQ69qJv1VtR3uxlKMCQMCvzk7vr17RHKcjx68A== dependencies: "@babel/helper-builder-binary-assignment-operator-visitor" "^7.1.0" "@babel/helper-plugin-utils" "^7.0.0" @@ -374,14 +330,12 @@ "@babel/plugin-transform-for-of@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.4.4.tgz#0267fc735e24c808ba173866c6c4d1440fc3c556" - integrity sha512-9T/5Dlr14Z9TIEXLXkt8T1DU7F24cbhwhMNUziN3hB1AXoZcdzPcTiKGRn/6iOymDqtTKWnr/BtRKN9JwbKtdQ== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-function-name@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.4.4.tgz#e1436116abb0610c2259094848754ac5230922ad" - integrity sha512-iU9pv7U+2jC9ANQkKeNF6DrPy4GBa4NWQtl6dHB4Pb3izX2JOEvDTFarlNsBj/63ZEzNNIAMs3Qw4fNCcSOXJA== dependencies: "@babel/helper-function-name" "^7.1.0" "@babel/helper-plugin-utils" "^7.0.0" @@ -389,21 +343,18 @@ "@babel/plugin-transform-literals@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-literals/-/plugin-transform-literals-7.2.0.tgz#690353e81f9267dad4fd8cfd77eafa86aba53ea1" - integrity sha512-2ThDhm4lI4oV7fVQ6pNNK+sx+c/GM5/SaML0w/r4ZB7sAneD/piDJtwdKlNckXeyGK7wlwg2E2w33C/Hh+VFCg== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-member-expression-literals@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.2.0.tgz#fa10aa5c58a2cb6afcf2c9ffa8cb4d8b3d489a2d" - integrity sha512-HiU3zKkSU6scTidmnFJ0bMX8hz5ixC93b4MHMiYebmk2lUVNGOboPsqQvx5LzooihijUoLR/v7Nc1rbBtnc7FA== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-modules-amd@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.2.0.tgz#82a9bce45b95441f617a24011dc89d12da7f4ee6" - integrity sha512-mK2A8ucqz1qhrdqjS9VMIDfIvvT2thrEsIQzbaTdc5QFzhDjQv2CkJJ5f6BXIkgbmaoax3zBr2RyvV/8zeoUZw== dependencies: "@babel/helper-module-transforms" "^7.1.0" "@babel/helper-plugin-utils" "^7.0.0" @@ -411,7 +362,6 @@ "@babel/plugin-transform-modules-commonjs@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.4.4.tgz#0bef4713d30f1d78c2e59b3d6db40e60192cac1e" - integrity sha512-4sfBOJt58sEo9a2BQXnZq+Q3ZTSAUXyK3E30o36BOGnJ+tvJ6YSxF0PG6kERvbeISgProodWuI9UVG3/FMY6iw== dependencies: "@babel/helper-module-transforms" "^7.4.4" "@babel/helper-plugin-utils" "^7.0.0" @@ -420,7 +370,6 @@ "@babel/plugin-transform-modules-systemjs@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.4.4.tgz#dc83c5665b07d6c2a7b224c00ac63659ea36a405" - integrity sha512-MSiModfILQc3/oqnG7NrP1jHaSPryO6tA2kOMmAQApz5dayPxWiHqmq4sWH2xF5LcQK56LlbKByCd8Aah/OIkQ== dependencies: "@babel/helper-hoist-variables" "^7.4.4" "@babel/helper-plugin-utils" "^7.0.0" @@ -428,7 +377,6 @@ "@babel/plugin-transform-modules-umd@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.2.0.tgz#7678ce75169f0877b8eb2235538c074268dd01ae" - integrity sha512-BV3bw6MyUH1iIsGhXlOK6sXhmSarZjtJ/vMiD9dNmpY8QXFFQTj+6v92pcfy1iqa8DeAfJFwoxcrS/TUZda6sw== dependencies: "@babel/helper-module-transforms" "^7.1.0" "@babel/helper-plugin-utils" "^7.0.0" @@ -436,21 +384,18 @@ "@babel/plugin-transform-named-capturing-groups-regex@^7.4.5": version "7.4.5" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.4.5.tgz#9d269fd28a370258199b4294736813a60bbdd106" - integrity sha512-z7+2IsWafTBbjNsOxU/Iv5CvTJlr5w4+HGu1HovKYTtgJ362f7kBcQglkfmlspKKZ3bgrbSGvLfNx++ZJgCWsg== dependencies: regexp-tree "^0.1.6" "@babel/plugin-transform-new-target@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.4.4.tgz#18d120438b0cc9ee95a47f2c72bc9768fbed60a5" - integrity sha512-r1z3T2DNGQwwe2vPGZMBNjioT2scgWzK9BCnDEh+46z8EEwXBq24uRzd65I7pjtugzPSj921aM15RpESgzsSuA== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-object-super@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.2.0.tgz#b35d4c10f56bab5d650047dad0f1d8e8814b6598" - integrity sha512-VMyhPYZISFZAqAPVkiYb7dUe2AsVi2/wCT5+wZdsNO31FojQJa9ns40hzZ6U9f50Jlq4w6qwzdBB2uwqZ00ebg== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/helper-replace-supers" "^7.1.0" @@ -458,7 +403,6 @@ "@babel/plugin-transform-parameters@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.4.4.tgz#7556cf03f318bd2719fe4c922d2d808be5571e16" - integrity sha512-oMh5DUO1V63nZcu/ZVLQFqiihBGo4OpxJxR1otF50GMeCLiRx5nUdtokd+u9SuVJrvvuIh9OosRFPP4pIPnwmw== dependencies: "@babel/helper-call-delegate" "^7.4.4" "@babel/helper-get-function-arity" "^7.0.0" @@ -467,42 +411,36 @@ "@babel/plugin-transform-property-literals@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.2.0.tgz#03e33f653f5b25c4eb572c98b9485055b389e905" - integrity sha512-9q7Dbk4RhgcLp8ebduOpCbtjh7C0itoLYHXd9ueASKAG/is5PQtMR5VJGka9NKqGhYEGn5ITahd4h9QeBMylWQ== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-regenerator@^7.4.5": version "7.4.5" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.4.5.tgz#629dc82512c55cee01341fb27bdfcb210354680f" - integrity sha512-gBKRh5qAaCWntnd09S8QC7r3auLCqq5DI6O0DlfoyDjslSBVqBibrMdsqO+Uhmx3+BlOmE/Kw1HFxmGbv0N9dA== dependencies: regenerator-transform "^0.14.0" "@babel/plugin-transform-reserved-words@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.2.0.tgz#4792af87c998a49367597d07fedf02636d2e1634" - integrity sha512-fz43fqW8E1tAB3DKF19/vxbpib1fuyCwSPE418ge5ZxILnBhWyhtPgz8eh1RCGGJlwvksHkyxMxh0eenFi+kFw== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-shorthand-properties@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.2.0.tgz#6333aee2f8d6ee7e28615457298934a3b46198f0" - integrity sha512-QP4eUM83ha9zmYtpbnyjTLAGKQritA5XW/iG9cjtuOI8s1RuL/3V6a3DeSHfKutJQ+ayUfeZJPcnCYEQzaPQqg== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-spread@^7.2.0": version "7.2.2" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-spread/-/plugin-transform-spread-7.2.2.tgz#3103a9abe22f742b6d406ecd3cd49b774919b406" - integrity sha512-KWfky/58vubwtS0hLqEnrWJjsMGaOeSBn90Ezn5Jeg9Z8KKHmELbP1yGylMlm5N6TPKeY9A2+UaSYLdxahg01w== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-sticky-regex@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.2.0.tgz#a1e454b5995560a9c1e0d537dfc15061fd2687e1" - integrity sha512-KKYCoGaRAf+ckH8gEL3JHUaFVyNHKe3ASNsZ+AlktgHevvxGigoIttrEJb8iKN03Q7Eazlv1s6cx2B2cQ3Jabw== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/helper-regex" "^7.0.0" @@ -510,7 +448,6 @@ "@babel/plugin-transform-template-literals@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.4.4.tgz#9d28fea7bbce637fb7612a0750989d8321d4bcb0" - integrity sha512-mQrEC4TWkhLN0z8ygIvEL9ZEToPhG5K7KDW3pzGqOfIGZ28Jb0POUkeWcoz8HnHvhFy6dwAT1j8OzqN8s804+g== dependencies: "@babel/helper-annotate-as-pure" "^7.0.0" "@babel/helper-plugin-utils" "^7.0.0" @@ -518,14 +455,12 @@ "@babel/plugin-transform-typeof-symbol@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.2.0.tgz#117d2bcec2fbf64b4b59d1f9819894682d29f2b2" - integrity sha512-2LNhETWYxiYysBtrBTqL8+La0jIoQQnIScUJc74OYvUGRmkskNY4EzLCnjHBzdmb38wqtTaixpo1NctEcvMDZw== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/plugin-transform-unicode-regex@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.4.4.tgz#ab4634bb4f14d36728bf5978322b35587787970f" - integrity sha512-il+/XdNw01i93+M9J9u4T7/e/Ue/vWfNZE4IRUQjplu2Mqb/AFTDimkw2tdEdSH50wuQXZAbXSql0UphQke+vA== dependencies: "@babel/helper-plugin-utils" "^7.0.0" "@babel/helper-regex" "^7.4.4" @@ -534,7 +469,6 @@ "@babel/preset-env@^7.4.5": version "7.4.5" resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.4.5.tgz#2fad7f62983d5af563b5f3139242755884998a58" - integrity sha512-f2yNVXM+FsR5V8UwcFeIHzHWgnhXg3NpRmy0ADvALpnhB0SLbCvrCRr4BLOUYbQNLS+Z0Yer46x9dJXpXewI7w== dependencies: "@babel/helper-module-imports" "^7.0.0" "@babel/helper-plugin-utils" "^7.0.0" @@ -585,10 +519,20 @@ js-levenshtein "^1.1.3" semver "^5.5.0" +"@babel/register@^7.4.4": + version "7.4.4" + resolved "https://registry.npmjs.org/@babel/register/-/register-7.4.4.tgz#370a68ba36f08f015a8b35d4864176c6b65d7a23" + dependencies: + core-js "^3.0.0" + find-cache-dir "^2.0.0" + lodash "^4.17.11" + mkdirp "^0.5.1" + pirates "^4.0.0" + source-map-support "^0.5.9" + "@babel/template@^7.1.0", "@babel/template@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.4.4.tgz#f4b88d1225689a08f5bc3a17483545be9e4ed237" - integrity sha512-CiGzLN9KgAvgZsnivND7rkA+AeJ9JB0ciPOD4U59GKbQP2iQl+olF1l76kJOupqidozfZ32ghwBEJDhnk9MEcw== dependencies: "@babel/code-frame" "^7.0.0" "@babel/parser" "^7.4.4" @@ -597,7 +541,6 @@ "@babel/traverse@^7.0.0", "@babel/traverse@^7.1.0", "@babel/traverse@^7.4.4", "@babel/traverse@^7.4.5": version "7.4.5" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.4.5.tgz#4e92d1728fd2f1897dafdd321efbff92156c3216" - integrity sha512-Vc+qjynwkjRmIFGxy0KYoPj4FdVDxLej89kMHFsWScq999uX+pwcX4v9mWRjW0KcAYTPAuVQl2LKP1wEVLsp+A== dependencies: "@babel/code-frame" "^7.0.0" "@babel/generator" "^7.4.4" @@ -612,7 +555,6 @@ "@babel/types@^7.0.0", "@babel/types@^7.2.0", "@babel/types@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.4.4.tgz#8db9e9a629bb7c29370009b4b779ed93fe57d5f0" - integrity sha512-dOllgYdnEFOebhkKCjzSVFqw/PmmB8pH6RGOWkY4GsboQNd47b1fBThBSwlHAq9alF9vc1M3+6oqR47R50L0tQ== dependencies: esutils "^2.0.2" lodash "^4.17.11" @@ -621,65 +563,54 @@ "@sinonjs/commons@^1.0.2": version "1.3.0" resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-1.3.0.tgz#50a2754016b6f30a994ceda6d9a0a8c36adda849" - integrity sha512-j4ZwhaHmwsCb4DlDOIWnI5YyKDNMoNThsmwEpfHx6a1EpsGZ9qYLxP++LMlmBRjtGptGHFsGItJ768snllFWpA== dependencies: type-detect "4.0.8" "@sinonjs/formatio@3.0.0", "@sinonjs/formatio@^3.0.0": version "3.0.0" resolved "https://registry.yarnpkg.com/@sinonjs/formatio/-/formatio-3.0.0.tgz#9d282d81030a03a03fa0c5ce31fd8786a4da311a" - integrity sha512-vdjoYLDptCgvtJs57ULshak3iJe4NW3sJ3g36xVDGff5AE8P30S6A093EIEPjdi2noGhfuNOEkbxt3J3awFW1w== dependencies: "@sinonjs/samsam" "2.1.0" "@sinonjs/samsam@2.1.0": version "2.1.0" resolved "https://registry.yarnpkg.com/@sinonjs/samsam/-/samsam-2.1.0.tgz#b8b8f5b819605bd63601a6ede459156880f38ea3" - integrity sha512-5x2kFgJYupaF1ns/RmharQ90lQkd2ELS8A9X0ymkAAdemYHGtI2KiUHG8nX2WU0T1qgnOU5YMqnBM2V7NUanNw== dependencies: array-from "^2.1.1" "@sinonjs/samsam@^2.1.2": version "2.1.2" resolved "https://registry.yarnpkg.com/@sinonjs/samsam/-/samsam-2.1.2.tgz#16947fce5f57258d01f1688fdc32723093c55d3f" - integrity sha512-ZwTHAlC9akprWDinwEPD4kOuwaYZlyMwVJIANsKNC3QVp0AHB04m7RnB4eqeWfgmxw8MGTzS9uMaw93Z3QcZbw== abbrev@1: version "1.1.1" resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8" - integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q== abbrev@1.0.x: version "1.0.9" resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.0.9.tgz#91b4792588a7738c25f35dd6f63752a2f8776135" - integrity sha1-kbR5JYinc4wl813W9jdSovh3YTU= acorn-jsx@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-3.0.1.tgz#afdf9488fb1ecefc8348f6fb22f464e32a58b36b" - integrity sha1-r9+UiPsezvyDSPb7IvRk4ypYs2s= dependencies: acorn "^3.0.4" acorn@^3.0.4: version "3.3.0" resolved "https://registry.yarnpkg.com/acorn/-/acorn-3.3.0.tgz#45e37fb39e8da3f25baee3ff5369e2bb5f22017a" - integrity sha1-ReN/s56No/JbruP/U2niu18iAXo= acorn@^5.5.0: version "5.7.3" resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.3.tgz#67aa231bf8812974b85235a96771eb6bd07ea279" - integrity sha512-T/zvzYRfbVojPWahDsE5evJdHb3oJoQfFbsrKM7w5Zcs++Tr257tia3BmMP8XYVjp1S9RZXQMh7gao96BlqZOw== ajv-keywords@^2.1.0: version "2.1.1" resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-2.1.1.tgz#617997fc5f60576894c435f940d819e135b80762" - integrity sha1-YXmX/F9gV2iUxDX5QNgZ4TW4B2I= ajv@^5.1.0: version "5.2.3" resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.2.3.tgz#c06f598778c44c6b161abafe3466b81ad1814ed2" - integrity sha1-wG9Zh3jETGsWGrr+NGa4GtGBTtI= dependencies: co "^4.6.0" fast-deep-equal "^1.0.0" @@ -689,7 +620,6 @@ ajv@^5.1.0: ajv@^5.2.3, ajv@^5.3.0: version "5.5.2" resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.2.tgz#73b5eeca3fab653e3d3f9422b341ad42205dc965" - integrity sha1-c7Xuyj+rZT49P5Qis0GtQiBdyWU= dependencies: co "^4.6.0" fast-deep-equal "^1.0.0" @@ -699,58 +629,48 @@ ajv@^5.2.3, ajv@^5.3.0: amdefine@>=0.0.4: version "1.0.1" resolved "https://registry.yarnpkg.com/amdefine/-/amdefine-1.0.1.tgz#4a5282ac164729e93619bcfd3ad151f817ce91f5" - integrity sha1-SlKCrBZHKek2Gbz9OtFR+BfOkfU= ansi-colors@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-1.1.0.tgz#6374b4dd5d4718ff3ce27a671a3b1cad077132a9" - integrity sha512-SFKX67auSNoVR38N3L+nvsPjOE0bybKTYbkf5tRvushrAPQ9V75huw0ZxBkKVeRU9kqH3d6HA4xTckbwZ4ixmA== dependencies: ansi-wrap "^0.1.0" ansi-escapes@^3.0.0: version "3.2.0" resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.2.0.tgz#8780b98ff9dbf5638152d1f1fe5c1d7b4442976b" - integrity sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ== ansi-gray@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/ansi-gray/-/ansi-gray-0.1.1.tgz#2962cf54ec9792c48510a3deb524436861ef7251" - integrity sha1-KWLPVOyXksSFEKPetSRDaGHvclE= dependencies: ansi-wrap "0.1.0" ansi-regex@^2.0.0: version "2.1.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" - integrity sha1-w7M6te42DYbg5ijwRorn7yfWVN8= ansi-regex@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.0.tgz#ed0317c322064f79466c02966bddb605ab37d998" - integrity sha1-7QMXwyIGT3lGbAKWa922Bas32Zg= ansi-styles@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" - integrity sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4= ansi-styles@^3.2.1: version "3.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" - integrity sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA== dependencies: color-convert "^1.9.0" ansi-wrap@0.1.0, ansi-wrap@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/ansi-wrap/-/ansi-wrap-0.1.0.tgz#a82250ddb0015e9a27ca82e82ea603bbfa45efaf" - integrity sha1-qCJQ3bABXponyoLoLqYDu/pF768= anymatch@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-2.0.0.tgz#bcb24b4f37934d9aa7ac17b4adaf89e7c76ef2eb" - integrity sha512-5teOsQWABXHHBFP9y3skS5P3d/WfWXpv3FUpy+LorMrNYaT9pI4oLMQX7jzQ2KklNpGpWHzdCXTDT2Y3XGlZBw== dependencies: micromatch "^3.1.4" normalize-path "^2.1.1" @@ -758,24 +678,20 @@ anymatch@^2.0.0: append-buffer@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/append-buffer/-/append-buffer-1.0.2.tgz#d8220cf466081525efea50614f3de6514dfa58f1" - integrity sha1-2CIM9GYIFSXv6lBhTz3mUU36WPE= dependencies: buffer-equal "^1.0.0" aproba@^1.0.3: version "1.2.0" resolved "https://registry.yarnpkg.com/aproba/-/aproba-1.2.0.tgz#6802e6264efd18c790a1b0d517f0f2627bf2c94a" - integrity sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw== archy@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/archy/-/archy-1.0.0.tgz#f9c8c13757cc1dd7bc379ac77b2c62a5c2868c40" - integrity sha1-+cjBN1fMHde8N5rHeyxipcKGjEA= are-we-there-yet@~1.1.2: version "1.1.5" resolved "https://registry.yarnpkg.com/are-we-there-yet/-/are-we-there-yet-1.1.5.tgz#4b35c2944f062a8bfcda66410760350fe9ddfc21" - integrity sha512-5hYdAkZlcG8tOLujVDTgCT+uPX0VnpAH28gWsLfzpXYm7wP6mp5Q/gYyR7YQ0cKVJcXJnl3j2kpBan13PtQf6w== dependencies: delegates "^1.0.0" readable-stream "^2.0.6" @@ -783,58 +699,48 @@ are-we-there-yet@~1.1.2: argparse@^1.0.7: version "1.0.10" resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.10.tgz#bcd6791ea5ae09725e17e5ad988134cd40b3d911" - integrity sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg== dependencies: sprintf-js "~1.0.2" arr-diff@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-4.0.0.tgz#d6461074febfec71e7e15235761a329a5dc7c520" - integrity sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA= arr-filter@^1.1.1: version "1.1.2" resolved "https://registry.yarnpkg.com/arr-filter/-/arr-filter-1.1.2.tgz#43fdddd091e8ef11aa4c45d9cdc18e2dff1711ee" - integrity sha1-Q/3d0JHo7xGqTEXZzcGOLf8XEe4= dependencies: make-iterator "^1.0.0" arr-flatten@^1.0.1, arr-flatten@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/arr-flatten/-/arr-flatten-1.1.0.tgz#36048bbff4e7b47e136644316c99669ea5ae91f1" - integrity sha512-L3hKV5R/p5o81R7O02IGnwpDmkp6E982XhtbuwSe3O4qOtMMMtodicASA1Cny2U+aCXcNpml+m4dPsvsJ3jatg== arr-map@^2.0.0, arr-map@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/arr-map/-/arr-map-2.0.2.tgz#3a77345ffc1cf35e2a91825601f9e58f2e24cac4" - integrity sha1-Onc0X/wc814qkYJWAfnljy4kysQ= dependencies: make-iterator "^1.0.0" arr-union@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/arr-union/-/arr-union-3.1.0.tgz#e39b09aea9def866a8f206e288af63919bae39c4" - integrity sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ= array-differ@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/array-differ/-/array-differ-1.0.0.tgz#eff52e3758249d33be402b8bb8e564bb2b5d4031" - integrity sha1-7/UuN1gknTO+QCuLuOVkuytdQDE= array-each@^1.0.0, array-each@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/array-each/-/array-each-1.0.1.tgz#a794af0c05ab1752846ee753a1f211a05ba0c44f" - integrity sha1-p5SvDAWrF1KEbudTofIRoFugxE8= array-from@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/array-from/-/array-from-2.1.1.tgz#cfe9d8c26628b9dc5aecc62a9f5d8f1f352c1195" - integrity sha1-z+nYwmYoudxa7MYqn12PHzUsEZU= array-initial@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/array-initial/-/array-initial-1.1.0.tgz#2fa74b26739371c3947bd7a7adc73be334b3d795" - integrity sha1-L6dLJnOTccOUe9enrcc74zSz15U= dependencies: array-slice "^1.0.0" is-number "^4.0.0" @@ -842,19 +748,16 @@ array-initial@^1.0.0: array-last@^1.1.1: version "1.3.0" resolved "https://registry.yarnpkg.com/array-last/-/array-last-1.3.0.tgz#7aa77073fec565ddab2493f5f88185f404a9d336" - integrity sha512-eOCut5rXlI6aCOS7Z7kCplKRKyiFQ6dHFBem4PwlwKeNFk2/XxTrhRh5T9PyaEWGy/NHTZWbY+nsZlNFJu9rYg== dependencies: is-number "^4.0.0" array-slice@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/array-slice/-/array-slice-1.1.0.tgz#e368ea15f89bc7069f7ffb89aec3a6c7d4ac22d4" - integrity sha512-B1qMD3RBP7O8o0H2KbrXDyB0IccejMF15+87Lvlor12ONPRHP6gTjXMNkt/d3ZuOGbAe66hFmaCfECI24Ufp6w== array-sort@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/array-sort/-/array-sort-1.0.0.tgz#e4c05356453f56f53512a7d1d6123f2c54c0a88a" - integrity sha512-ihLeJkonmdiAsD7vpgN3CRcx2J2S0TiYW+IS/5zHBI7mKUq3ySvBdzzBfD236ubDBQFiiyG3SWCPc+msQ9KoYg== dependencies: default-compare "^1.0.0" get-value "^2.0.6" @@ -863,39 +766,32 @@ array-sort@^1.0.0: array-uniq@^1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/array-uniq/-/array-uniq-1.0.3.tgz#af6ac877a25cc7f74e058894753858dfdb24fdb6" - integrity sha1-r2rId6Jcx/dOBYiUdThY39sk/bY= array-unique@^0.3.2: version "0.3.2" resolved "https://registry.yarnpkg.com/array-unique/-/array-unique-0.3.2.tgz#a894b75d4bc4f6cd679ef3244a9fd8f46ae2d428" - integrity sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg= asn1@~0.2.3: version "0.2.4" resolved "https://registry.yarnpkg.com/asn1/-/asn1-0.2.4.tgz#8d2475dfab553bb33e77b54e59e880bb8ce23136" - integrity sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg== dependencies: safer-buffer "~2.1.0" assert-plus@1.0.0, assert-plus@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-1.0.0.tgz#f12e0f3c5d77b0b1cdd9146942e4e96c1e4dd525" - integrity sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU= assertion-error@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/assertion-error/-/assertion-error-1.0.2.tgz#13ca515d86206da0bac66e834dd397d87581094c" - integrity sha1-E8pRXYYgbaC6xm6DTdOX2HWBCUw= assign-symbols@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/assign-symbols/-/assign-symbols-1.0.0.tgz#59667f41fadd4f20ccbc2bb96b8d4f7f78ec0367" - integrity sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c= async-done@^1.2.0, async-done@^1.2.2: version "1.3.2" resolved "https://registry.yarnpkg.com/async-done/-/async-done-1.3.2.tgz#5e15aa729962a4b07414f528a88cdf18e0b290a2" - integrity sha512-uYkTP8dw2og1tu1nmza1n1CMW0qb8gWWlwqMmLb7MhBVs4BXrFziT6HXUd+/RlRA/i4H9AkofYloUbs1fwMqlw== dependencies: end-of-stream "^1.1.0" once "^1.3.2" @@ -905,44 +801,36 @@ async-done@^1.2.0, async-done@^1.2.2: async-each@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/async-each/-/async-each-1.0.3.tgz#b727dbf87d7651602f06f4d4ac387f47d91b0cbf" - integrity sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ== async-settle@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/async-settle/-/async-settle-1.0.0.tgz#1d0a914bb02575bec8a8f3a74e5080f72b2c0c6b" - integrity sha1-HQqRS7Aldb7IqPOnTlCA9yssDGs= dependencies: async-done "^1.2.2" async@1.x: version "1.5.2" resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a" - integrity sha1-7GphrlZIDAw8skHJVhjiCJL5Zyo= asynckit@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" - integrity sha1-x57Zf380y48robyXkLzDZkdLS3k= atob@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/atob/-/atob-2.1.0.tgz#ab2b150e51d7b122b9efc8d7340c06b6c41076bc" - integrity sha512-SuiKH8vbsOyCALjA/+EINmt/Kdl+TQPrtFgW7XZZcwtryFu9e5kQoX3bjCW6mIvGH1fbeAZZuvwGR5IlBRznGw== aws-sign2@~0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz#b46e890934a9591f2d2f6f86d7e6a9f1b3fe76a8" - integrity sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg= aws4@^1.6.0: version "1.6.0" resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.6.0.tgz#83ef5ca860b2b32e4a0deedee8c771b9db57471e" - integrity sha1-g+9cqGCysy5KDe7e6MdxudtXRx4= babel-code-frame@^6.22.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.26.0.tgz#63fd43f7dc1e3bb7ce35947db8fe369a3f58c74b" - integrity sha1-Y/1D99weO7fONZR9uP42mj9Yx0s= dependencies: chalk "^1.1.3" esutils "^2.0.2" @@ -951,7 +839,6 @@ babel-code-frame@^6.22.0: babel-eslint@^10.0.2: version "10.0.2" resolved "https://registry.yarnpkg.com/babel-eslint/-/babel-eslint-10.0.2.tgz#182d5ac204579ff0881684b040560fdcc1558456" - integrity sha512-UdsurWPtgiPgpJ06ryUnuaSXC2s0WoSZnQmEpbAH65XZSdwowgN5MvyP7e88nW07FYXv72erVtpBkxyDVKhH1Q== dependencies: "@babel/code-frame" "^7.0.0" "@babel/parser" "^7.0.0" @@ -963,7 +850,6 @@ babel-eslint@^10.0.2: bach@^1.0.0: version "1.2.0" resolved "https://registry.yarnpkg.com/bach/-/bach-1.2.0.tgz#4b3ce96bf27134f79a1b414a51c14e34c3bd9880" - integrity sha1-Szzpa/JxNPeaG0FKUcFONMO9mIA= dependencies: arr-filter "^1.1.1" arr-flatten "^1.0.1" @@ -978,12 +864,10 @@ bach@^1.0.0: balanced-match@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767" - integrity sha1-ibTRmasr7kneFk6gK4nORi1xt2c= base@^0.11.1: version "0.11.2" resolved "https://registry.yarnpkg.com/base/-/base-0.11.2.tgz#7bde5ced145b6d551a90db87f83c558b4eb48a8f" - integrity sha512-5T6P4xPgpp0YDFvSWwEZ4NoE3aM4QBQXDzmVbraCkFj8zHM+mba8SyqB5DbZWyR7mYHo6Y7BdQo3MoA4m0TeQg== dependencies: cache-base "^1.0.1" class-utils "^0.3.5" @@ -996,43 +880,36 @@ base@^0.11.1: bcrypt-pbkdf@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz#a4301d389b6a43f9b67ff3ca11a3f6637e360e9e" - integrity sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4= dependencies: tweetnacl "^0.14.3" beeper@^1.0.0: version "1.1.1" resolved "https://registry.yarnpkg.com/beeper/-/beeper-1.1.1.tgz#e6d5ea8c5dad001304a70b22638447f69cb2f809" - integrity sha1-5tXqjF2tABMEpwsiY4RH9pyy+Ak= binary-extensions@^1.0.0: version "1.13.1" resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-1.13.1.tgz#598afe54755b2868a5330d2aff9d4ebb53209b65" - integrity sha512-Un7MIEDdUC5gNpcGDV97op1Ywk748MpHcFTHoYs6qnj1Z3j7I53VG3nwZhKzoBZmbdRNnb6WRdFlwl7tSDuZGw== bluebird@^3.3.4: version "3.5.1" resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.5.1.tgz#d9551f9de98f1fcda1e683d17ee91a0602ee2eb9" - integrity sha512-MKiLiV+I1AA596t9w1sQJ8jkiSr5+ZKi0WKrYGUn6d1Fx+Ij4tIj+m2WMQSGczs5jZVxV339chE8iwk6F64wjA== boom@4.x.x: version "4.3.1" resolved "https://registry.yarnpkg.com/boom/-/boom-4.3.1.tgz#4f8a3005cb4a7e3889f749030fd25b96e01d2e31" - integrity sha1-T4owBctKfjiJ90kDD9JbluAdLjE= dependencies: hoek "4.x.x" boom@5.x.x: version "5.2.0" resolved "https://registry.yarnpkg.com/boom/-/boom-5.2.0.tgz#5dd9da6ee3a5f302077436290cb717d3f4a54e02" - integrity sha512-Z5BTk6ZRe4tXXQlkqftmsAUANpXmuwlsF5Oov8ThoMbQRzdGTA1ngYRW160GexgOgjsFOKJz0LYhoNi+2AMBUw== dependencies: hoek "4.x.x" brace-expansion@^1.0.0, brace-expansion@^1.1.7: version "1.1.8" resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.8.tgz#c07b211c7c952ec1f8efd51a77ef0d1d3990a292" - integrity sha1-wHshHHyVLsH479Uad+8NHTmQopI= dependencies: balanced-match "^1.0.0" concat-map "0.0.1" @@ -1040,7 +917,6 @@ brace-expansion@^1.0.0, brace-expansion@^1.1.7: braces@^2.3.1, braces@^2.3.2: version "2.3.2" resolved "https://registry.yarnpkg.com/braces/-/braces-2.3.2.tgz#5979fd3f14cd531565e5fa2df1abfff1dfaee729" - integrity sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w== dependencies: arr-flatten "^1.1.0" array-unique "^0.3.2" @@ -1056,7 +932,6 @@ braces@^2.3.1, braces@^2.3.2: browserslist@^4.6.0, browserslist@^4.6.2: version "4.6.3" resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.6.3.tgz#0530cbc6ab0c1f3fc8c819c72377ba55cf647f05" - integrity sha512-CNBqTCq22RKM8wKJNowcqihHJ4SkI8CGeK7KOR9tPboXUuS5Zk5lQgzzTbs4oxD8x+6HUshZUa2OyNI9lR93bQ== dependencies: caniuse-lite "^1.0.30000975" electron-to-chromium "^1.3.164" @@ -1065,17 +940,14 @@ browserslist@^4.6.0, browserslist@^4.6.2: buffer-equal@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/buffer-equal/-/buffer-equal-1.0.0.tgz#59616b498304d556abd466966b22eeda3eca5fbe" - integrity sha1-WWFrSYME1Var1GaWayLu2j7KX74= buffer-from@^1.0.0: version "1.1.1" resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.1.tgz#32713bc028f75c02fdb710d7c7bcec1f2c6070ef" - integrity sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A== cache-base@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/cache-base/-/cache-base-1.0.1.tgz#0a7f46416831c8b662ee36fe4e7c59d76f666ab2" - integrity sha512-AKcdTnFSWATd5/GCPRxr2ChwIJ85CeyrEyjRHlKxQ56d4XJMGym0uAiKn0xbLOGOl3+yRpOTi484dVCEc5AUzQ== dependencies: collection-visit "^1.0.0" component-emitter "^1.2.1" @@ -1090,34 +962,28 @@ cache-base@^1.0.1: caller-path@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/caller-path/-/caller-path-0.1.0.tgz#94085ef63581ecd3daa92444a8fe94e82577751f" - integrity sha1-lAhe9jWB7NPaqSREqP6U6CV3dR8= dependencies: callsites "^0.2.0" callsites@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/callsites/-/callsites-0.2.0.tgz#afab96262910a7f33c19a5775825c69f34e350ca" - integrity sha1-r6uWJikQp/M8GaV3WCXGnzTjUMo= camelcase@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-3.0.0.tgz#32fc4b9fcdaf845fcdf7e73bb97cac2261f0ab0a" - integrity sha1-MvxLn82vhF/N9+c7uXysImHwqwo= caniuse-lite@^1.0.30000975: version "1.0.30000979" resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000979.tgz#92f16d00186a6cf20d6c5711bb6e042a3d667029" - integrity sha512-gcu45yfq3B7Y+WB05fOMfr0EiSlq+1u+m6rPHyJli/Wy3PVQNGaU7VA4bZE5qw+AU2UVOBR/N5g1bzADUqdvFw== caseless@~0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" - integrity sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw= "chai@>=1.9.2 <4.0.0": version "3.5.0" resolved "https://registry.yarnpkg.com/chai/-/chai-3.5.0.tgz#4d02637b067fe958bdbfdd3a40ec56fef7373247" - integrity sha1-TQJjewZ/6Vi9v906QOxW/vc3Mkc= dependencies: assertion-error "^1.0.1" deep-eql "^0.1.3" @@ -1126,7 +992,6 @@ caseless@~0.12.0: chalk@^1.0.0, chalk@^1.1.1, chalk@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/chalk/-/chalk-1.1.3.tgz#a8115c55e4a702fe4d150abd3872822a7e09fc98" - integrity sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg= dependencies: ansi-styles "^2.2.1" escape-string-regexp "^1.0.2" @@ -1137,7 +1002,6 @@ chalk@^1.0.0, chalk@^1.1.1, chalk@^1.1.3: chalk@^2.0.0, chalk@^2.1.0: version "2.4.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" - integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== dependencies: ansi-styles "^3.2.1" escape-string-regexp "^1.0.5" @@ -1146,12 +1010,10 @@ chalk@^2.0.0, chalk@^2.1.0: chardet@^0.4.0: version "0.4.2" resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.4.2.tgz#b5473b33dc97c424e5d98dc87d55d4d8a29c8bf2" - integrity sha1-tUc7M9yXxCTl2Y3IfVXU2KKci/I= chokidar@^2.0.0: version "2.1.6" resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-2.1.6.tgz#b6cad653a929e244ce8a834244164d241fa954c5" - integrity sha512-V2jUo67OKkc6ySiRpJrjlpJKl9kDuG+Xb8VgsGzb+aEouhgS1D0weyPU4lEzdAcsCAvrih2J2BqyXqHWvVLw5g== dependencies: anymatch "^2.0.0" async-each "^1.0.1" @@ -1170,17 +1032,14 @@ chokidar@^2.0.0: chownr@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/chownr/-/chownr-1.1.1.tgz#54726b8b8fff4df053c42187e801fb4412df1494" - integrity sha512-j38EvO5+LHX84jlo6h4UzmOwi0UgW61WRyPtJz4qaadK5eY3BTS5TY/S1Stc3Uk2lIM6TPevAlULiEJwie860g== circular-json@^0.3.1: version "0.3.3" resolved "https://registry.yarnpkg.com/circular-json/-/circular-json-0.3.3.tgz#815c99ea84f6809529d2f45791bdf82711352d66" - integrity sha512-UZK3NBx2Mca+b5LsG7bY183pHWt5Y1xts4P3Pz7ENTwGVnJOUWbRb3ocjvX7hx9tq/yTAdclXm9sZ38gNuem4A== class-utils@^0.3.5: version "0.3.6" resolved "https://registry.yarnpkg.com/class-utils/-/class-utils-0.3.6.tgz#f93369ae8b9a7ce02fd41faad0ca83033190c463" - integrity sha512-qOhPa/Fj7s6TY8H8esGu5QNpMMQxz79h+urzrNYN6mn+9BnxlDGf5QZ+XeCDsxSjPqsSR56XOZOJmpeurnLMeg== dependencies: arr-union "^3.1.0" define-property "^0.2.5" @@ -1190,19 +1049,16 @@ class-utils@^0.3.5: cli-cursor@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-2.1.0.tgz#b35dac376479facc3e94747d41d0d0f5238ffcb5" - integrity sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU= dependencies: restore-cursor "^2.0.0" cli-width@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-2.2.0.tgz#ff19ede8a9a5e579324147b0c11f0fbcbabed639" - integrity sha1-/xnt6Kml5XkyQUewwR8PvLq+1jk= cliui@^3.2.0: version "3.2.0" resolved "https://registry.yarnpkg.com/cliui/-/cliui-3.2.0.tgz#120601537a916d29940f934da3b48d585a39213d" - integrity sha1-EgYBU3qRbSmUD5NNo7SNWFo5IT0= dependencies: string-width "^1.0.1" strip-ansi "^3.0.1" @@ -1211,32 +1067,26 @@ cliui@^3.2.0: clone-buffer@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/clone-buffer/-/clone-buffer-1.0.0.tgz#e3e25b207ac4e701af721e2cb5a16792cac3dc58" - integrity sha1-4+JbIHrE5wGvch4staFnksrD3Fg= clone-stats@^0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/clone-stats/-/clone-stats-0.0.1.tgz#b88f94a82cf38b8791d58046ea4029ad88ca99d1" - integrity sha1-uI+UqCzzi4eR1YBG6kAprYjKmdE= clone-stats@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/clone-stats/-/clone-stats-1.0.0.tgz#b3782dff8bb5474e18b9b6bf0fdfe782f8777680" - integrity sha1-s3gt/4u1R04Yuba/D9/ngvh3doA= clone@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/clone/-/clone-1.0.2.tgz#260b7a99ebb1edfe247538175f783243cb19d149" - integrity sha1-Jgt6meux7f4kdTgXX3gyQ8sZ0Uk= clone@^2.1.1: version "2.1.2" resolved "https://registry.yarnpkg.com/clone/-/clone-2.1.2.tgz#1b7f4b9f591f1e8f83670401600345a02887435f" - integrity sha1-G39Ln1kfHo+DZwQBYANFoCiHQ18= cloneable-readable@^1.0.0: version "1.1.3" resolved "https://registry.yarnpkg.com/cloneable-readable/-/cloneable-readable-1.1.3.tgz#120a00cb053bfb63a222e709f9683ea2e11d8cec" - integrity sha512-2EF8zTQOxYq70Y4XKtorQupqF0m49MBz2/yf5Bj+MHjvpG3Hy7sImifnqD6UA+TKYxeSV+u6qqQPawN5UvnpKQ== dependencies: inherits "^2.0.1" process-nextick-args "^2.0.0" @@ -1245,17 +1095,14 @@ cloneable-readable@^1.0.0: co@^4.6.0: version "4.6.0" resolved "https://registry.yarnpkg.com/co/-/co-4.6.0.tgz#6ea6bdf3d853ae54ccb8e47bfa0bf3f9031fb184" - integrity sha1-bqa989hTrlTMuOR7+gvz+QMfsYQ= code-point-at@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77" - integrity sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c= collection-map@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/collection-map/-/collection-map-1.0.0.tgz#aea0f06f8d26c780c2b75494385544b2255af18c" - integrity sha1-rqDwb40mx4DCt1SUOFVEsiVa8Yw= dependencies: arr-map "^2.0.2" for-own "^1.0.0" @@ -1264,7 +1111,6 @@ collection-map@^1.0.0: collection-visit@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/collection-visit/-/collection-visit-1.0.0.tgz#4bc0373c164bc3291b4d368c829cf1a80a59dca0" - integrity sha1-S8A3PBZLwykbTTaMgpzxqApZ3KA= dependencies: map-visit "^1.0.0" object-visit "^1.0.0" @@ -1272,56 +1118,50 @@ collection-visit@^1.0.0: color-convert@^1.9.0: version "1.9.3" resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.3.tgz#bb71850690e1f136567de629d2d5471deda4c1e8" - integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== dependencies: color-name "1.1.3" color-name@1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" - integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= color-support@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/color-support/-/color-support-1.1.3.tgz#93834379a1cc9a0c61f82f52f0d04322251bd5a2" - integrity sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg== combined-stream@^1.0.5, combined-stream@~1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.5.tgz#938370a57b4a51dea2c77c15d5c5fdf895164009" - integrity sha1-k4NwpXtKUd6ix3wV1cX9+JUWQAk= dependencies: delayed-stream "~1.0.0" commander@0.6.1: version "0.6.1" - resolved "https://registry.yarnpkg.com/commander/-/commander-0.6.1.tgz#fa68a14f6a945d54dbbe50d8cdb3320e9e3b1a06" - integrity sha1-+mihT2qUXVTbvlDYzbMyDp47GgY= + resolved "https://registry.npmjs.org/commander/-/commander-0.6.1.tgz#fa68a14f6a945d54dbbe50d8cdb3320e9e3b1a06" commander@2.3.0: version "2.3.0" - resolved "https://registry.yarnpkg.com/commander/-/commander-2.3.0.tgz#fd430e889832ec353b9acd1de217c11cb3eef873" - integrity sha1-/UMOiJgy7DU7ms0d4hfBHLPu+HM= + resolved "https://registry.npmjs.org/commander/-/commander-2.3.0.tgz#fd430e889832ec353b9acd1de217c11cb3eef873" commander@~2.20.0: version "2.20.0" resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.0.tgz#d58bb2b5c1ee8f87b0d340027e9e94e222c5a422" - integrity sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ== + +commondir@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz#ddd800da0c66127393cca5950ea968a3aaf1253b" component-emitter@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.2.1.tgz#137918d6d78283f7df7a6b7c5a63e140e69425e6" - integrity sha1-E3kY1teCg/ffemt8WmPhQOaUJeY= concat-map@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" - integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= concat-stream@^1.6.0: version "1.6.2" resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34" - integrity sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw== dependencies: buffer-from "^1.0.0" inherits "^2.0.3" @@ -1331,29 +1171,24 @@ concat-stream@^1.6.0: console-control-strings@^1.0.0, console-control-strings@~1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/console-control-strings/-/console-control-strings-1.1.0.tgz#3d7cf4464db6446ea644bf4b39507f9851008e8e" - integrity sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4= convert-source-map@^1.1.0: version "1.6.0" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.6.0.tgz#51b537a8c43e0f04dec1993bffcdd504e758ac20" - integrity sha512-eFu7XigvxdZ1ETfbgPBohgyQ/Z++C0eEhTor0qRwBw9unw+L0/6V8wkSuGgzdThkiS5lSpdptOQPD8Ak40a+7A== dependencies: safe-buffer "~5.1.1" convert-source-map@^1.5.0: version "1.5.0" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.5.0.tgz#9acd70851c6d5dfdd93d9282e5edf94a03ff46b5" - integrity sha1-ms1whRxtXf3ZPZKC5e35SgP/RrU= copy-descriptor@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" - integrity sha1-Z29us8OZl8LuGsOpJP1hJHSPV40= copy-props@^2.0.1: version "2.0.4" resolved "https://registry.yarnpkg.com/copy-props/-/copy-props-2.0.4.tgz#93bb1cadfafd31da5bb8a9d4b41f471ec3a72dfe" - integrity sha512-7cjuUME+p+S3HZlbllgsn2CDwS+5eCCX16qBgNC4jgSTf49qR1VKy/Zhl400m0IQXl/bPGEVqncgUUMjrr4s8A== dependencies: each-props "^1.3.0" is-plain-object "^2.0.1" @@ -1361,7 +1196,6 @@ copy-props@^2.0.1: core-js-compat@^3.1.1: version "3.1.4" resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.1.4.tgz#e4d0c40fbd01e65b1d457980fe4112d4358a7408" - integrity sha512-Z5zbO9f1d0YrJdoaQhphVAnKPimX92D6z8lCGphH89MNRxlL1prI9ExJPqVwP0/kgkQCv8c4GJGT8X16yUncOg== dependencies: browserslist "^4.6.2" core-js-pure "3.1.4" @@ -1370,17 +1204,18 @@ core-js-compat@^3.1.1: core-js-pure@3.1.4: version "3.1.4" resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.1.4.tgz#5fa17dc77002a169a3566cc48dc774d2e13e3769" - integrity sha512-uJ4Z7iPNwiu1foygbcZYJsJs1jiXrTTCvxfLDXNhI/I+NHbSIEyr548y4fcsCEyWY0XgfAG/qqaunJ1SThHenA== + +core-js@^3.0.0: + version "3.1.4" + resolved "https://registry.npmjs.org/core-js/-/core-js-3.1.4.tgz#3a2837fc48e582e1ae25907afcd6cf03b0cc7a07" core-util-is@1.0.2, core-util-is@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" - integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac= cross-spawn@^5.1.0: version "5.1.0" resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-5.1.0.tgz#e8bd0efee58fcff6f8f94510a0a554bbfa235449" - integrity sha1-6L0O/uWPz/b4+UUQoKVUu/ojVEk= dependencies: lru-cache "^4.0.1" shebang-command "^1.2.0" @@ -1389,14 +1224,12 @@ cross-spawn@^5.1.0: cryptiles@3.x.x: version "3.1.2" resolved "https://registry.yarnpkg.com/cryptiles/-/cryptiles-3.1.2.tgz#a89fbb220f5ce25ec56e8c4aa8a4fd7b5b0d29fe" - integrity sha1-qJ+7Ig9c4l7FboxKqKT9e1sNKf4= dependencies: boom "5.x.x" d@1: version "1.0.1" resolved "https://registry.yarnpkg.com/d/-/d-1.0.1.tgz#8698095372d58dbee346ffd0c7093f99f8f9eb5a" - integrity sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA== dependencies: es5-ext "^0.10.50" type "^1.0.1" @@ -1404,112 +1237,94 @@ d@1: dashdash@^1.12.0: version "1.14.1" resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0" - integrity sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA= dependencies: assert-plus "^1.0.0" dateformat@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-2.2.0.tgz#4065e2013cf9fb916ddfd82efb506ad4c6769062" - integrity sha1-QGXiATz5+5Ft39gu+1Bq1MZ2kGI= debug@2.2.0: version "2.2.0" - resolved "https://registry.yarnpkg.com/debug/-/debug-2.2.0.tgz#f87057e995b1a1f6ae6a4960664137bc56f039da" - integrity sha1-+HBX6ZWxofauaklgZkE3vFbwOdo= + resolved "https://registry.npmjs.org/debug/-/debug-2.2.0.tgz#f87057e995b1a1f6ae6a4960664137bc56f039da" dependencies: ms "0.7.1" debug@^2.2.0, debug@^2.3.3: version "2.6.9" resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" - integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== dependencies: ms "2.0.0" debug@^3.1.0, debug@^3.2.6: version "3.2.6" resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.6.tgz#e83d17de16d8a7efb7717edbe5fb10135eee629b" - integrity sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ== dependencies: ms "^2.1.1" debug@^4.1.0: version "4.1.1" resolved "https://registry.yarnpkg.com/debug/-/debug-4.1.1.tgz#3b72260255109c6b589cee050f1d516139664791" - integrity sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw== dependencies: ms "^2.1.1" decamelize@^1.1.1: version "1.2.0" resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" - integrity sha1-9lNNFRSCabIDUue+4m9QH5oZEpA= decode-uri-component@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545" - integrity sha1-6zkTMzRYd1y4TNGh+uBiEGu4dUU= deep-eql@^0.1.3: version "0.1.3" resolved "https://registry.yarnpkg.com/deep-eql/-/deep-eql-0.1.3.tgz#ef558acab8de25206cd713906d74e56930eb69f2" - integrity sha1-71WKyrjeJSBs1xOQbXTlaTDrafI= dependencies: type-detect "0.1.1" deep-equal@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/deep-equal/-/deep-equal-1.0.1.tgz#f5d260292b660e084eff4cdbc9f08ad3247448b5" - integrity sha1-9dJgKStmDghO/0zbyfCK0yR0SLU= deep-extend@^0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/deep-extend/-/deep-extend-0.6.0.tgz#c4fa7c95404a17a9c3e8ca7e1537312b736330ac" - integrity sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA== deep-is@~0.1.2, deep-is@~0.1.3: version "0.1.3" resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34" - integrity sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ= default-compare@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/default-compare/-/default-compare-1.0.0.tgz#cb61131844ad84d84788fb68fd01681ca7781a2f" - integrity sha512-QWfXlM0EkAbqOCbD/6HjdwT19j7WCkMyiRhWilc4H9/5h/RzTF9gv5LYh1+CmDV5d1rki6KAWLtQale0xt20eQ== dependencies: kind-of "^5.0.2" default-resolution@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/default-resolution/-/default-resolution-2.0.0.tgz#bcb82baa72ad79b426a76732f1a81ad6df26d684" - integrity sha1-vLgrqnKtebQmp2cy8aga1t8m1oQ= define-properties@^1.1.2: version "1.1.3" resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.3.tgz#cf88da6cbee26fe6db7094f61d870cbd84cee9f1" - integrity sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ== dependencies: object-keys "^1.0.12" define-property@^0.2.5: version "0.2.5" resolved "https://registry.yarnpkg.com/define-property/-/define-property-0.2.5.tgz#c35b1ef918ec3c990f9a5bc57be04aacec5c8116" - integrity sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY= dependencies: is-descriptor "^0.1.0" define-property@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/define-property/-/define-property-1.0.0.tgz#769ebaaf3f4a63aad3af9e8d304c9bbe79bfb0e6" - integrity sha1-dp66rz9KY6rTr56NMEybvnm/sOY= dependencies: is-descriptor "^1.0.0" define-property@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/define-property/-/define-property-2.0.2.tgz#d459689e8d654ba77e02a817f8710d702cb16e9d" - integrity sha512-jwK2UV4cnPpbcG7+VRARKTZPUWowwXA8bzH5NP6ud0oeAxyYPuGZUAC7hMugpCdz4BeSZl2Dl9k66CHJ/46ZYQ== dependencies: is-descriptor "^1.0.2" isobject "^3.0.1" @@ -1517,51 +1332,42 @@ define-property@^2.0.2: delayed-stream@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" - integrity sha1-3zrhmayt+31ECqrgsp4icrJOxhk= delegates@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/delegates/-/delegates-1.0.0.tgz#84c6e159b81904fdca59a0ef44cd870d31250f9a" - integrity sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o= detect-file@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/detect-file/-/detect-file-1.0.0.tgz#f0d66d03672a825cb1b73bdb3fe62310c8e552b7" - integrity sha1-8NZtA2cqglyxtzvbP+YjEMjlUrc= detect-libc@^1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-1.0.3.tgz#fa137c4bd698edf55cd5cd02ac559f91a4c4ba9b" - integrity sha1-+hN8S9aY7fVc1c0CrFWfkaTEups= diff@1.4.0: version "1.4.0" - resolved "https://registry.yarnpkg.com/diff/-/diff-1.4.0.tgz#7f28d2eb9ee7b15a97efd89ce63dcfdaa3ccbabf" - integrity sha1-fyjS657nsVqX79ic5j3P2qPMur8= + resolved "https://registry.npmjs.org/diff/-/diff-1.4.0.tgz#7f28d2eb9ee7b15a97efd89ce63dcfdaa3ccbabf" diff@^3.5.0: version "3.5.0" resolved "https://registry.yarnpkg.com/diff/-/diff-3.5.0.tgz#800c0dd1e0a8bfbc95835c202ad220fe317e5a12" - integrity sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA== doctrine@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.1.0.tgz#5cd01fc101621b42c4cd7f5d1a66243716d3f39d" - integrity sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw== dependencies: esutils "^2.0.2" duplexer2@0.0.2: version "0.0.2" resolved "https://registry.yarnpkg.com/duplexer2/-/duplexer2-0.0.2.tgz#c614dcf67e2fb14995a91711e5a617e8a60a31db" - integrity sha1-xhTc9n4vsUmVqRcR5aYX6KYKMds= dependencies: readable-stream "~1.1.9" duplexify@^3.6.0: version "3.7.1" resolved "https://registry.yarnpkg.com/duplexify/-/duplexify-3.7.1.tgz#2a4df5317f6ccfd91f86d6fd25d8d8a103b88309" - integrity sha512-07z8uv2wMyS51kKhD1KsdXJg5WQ6t93RneqRxUHnskXVtlYYkLqM0gqStQZ3pj073g687jPCHrqNfCzawLYh5g== dependencies: end-of-stream "^1.0.0" inherits "^2.0.1" @@ -1571,7 +1377,6 @@ duplexify@^3.6.0: each-props@^1.3.0: version "1.3.2" resolved "https://registry.yarnpkg.com/each-props/-/each-props-1.3.2.tgz#ea45a414d16dd5cfa419b1a81720d5ca06892333" - integrity sha512-vV0Hem3zAGkJAyU7JSjixeU66rwdynTAa1vofCrSA5fEln+m67Az9CcnkVD776/fsN/UjIWmBDoNRS6t6G9RfA== dependencies: is-plain-object "^2.0.1" object.defaults "^1.1.0" @@ -1579,7 +1384,6 @@ each-props@^1.3.0: ecc-jsbn@~0.1.1: version "0.1.2" resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz#3a83a904e54353287874c564b7549386849a98c9" - integrity sha1-OoOpBOVDUyh4dMVkt1SThoSamMk= dependencies: jsbn "~0.1.0" safer-buffer "^2.1.0" @@ -1587,26 +1391,22 @@ ecc-jsbn@~0.1.1: electron-to-chromium@^1.3.164: version "1.3.185" resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.185.tgz#36368514eb719632a91435f3c9f57c98b47d81de" - integrity sha512-h2iW0AHIwix8ifNJg/RkXhQjUDqBME8TvX8qQQMvvF2Tb6F2KnO6febvI+JqI9CdZOWnl90CPxdBRWGDrdk9UA== end-of-stream@^1.0.0, end-of-stream@^1.1.0: version "1.4.1" resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.1.tgz#ed29634d19baba463b6ce6b80a37213eab71ec43" - integrity sha512-1MkrZNvWTKCaigbn+W15elq2BB/L22nqrSY5DKlo3X6+vclJm8Bb5djXJBmEX6fS3+zCh/F4VBK5Z2KxJt4s2Q== dependencies: once "^1.4.0" error-ex@^1.2.0: version "1.3.2" resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" - integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== dependencies: is-arrayish "^0.2.1" es5-ext@^0.10.35, es5-ext@^0.10.46, es5-ext@^0.10.50, es5-ext@~0.10.14: version "0.10.50" resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.50.tgz#6d0e23a0abdb27018e5ac4fd09b412bc5517a778" - integrity sha512-KMzZTPBkeQV/JcSQhI5/z6d9VWJ3EnQ194USTUwIYZ2ZbpN8+SGXQKt1h68EX44+qt+Fzr8DO17vnxrw7c3agw== dependencies: es6-iterator "~2.0.3" es6-symbol "~3.1.1" @@ -1615,7 +1415,6 @@ es5-ext@^0.10.35, es5-ext@^0.10.46, es5-ext@^0.10.50, es5-ext@~0.10.14: es6-iterator@^2.0.1, es6-iterator@^2.0.3, es6-iterator@~2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/es6-iterator/-/es6-iterator-2.0.3.tgz#a7de889141a05a94b0854403b2d0a0fbfa98f3b7" - integrity sha1-p96IkUGgWpSwhUQDstCg+/qY87c= dependencies: d "1" es5-ext "^0.10.35" @@ -1624,7 +1423,6 @@ es6-iterator@^2.0.1, es6-iterator@^2.0.3, es6-iterator@~2.0.3: es6-symbol@^3.1.1, es6-symbol@~3.1.1: version "3.1.1" resolved "https://registry.yarnpkg.com/es6-symbol/-/es6-symbol-3.1.1.tgz#bf00ef4fdab6ba1b46ecb7b629b4c7ed5715cc77" - integrity sha1-vwDvT9q2uhtG7Le2KbTH7VcVzHc= dependencies: d "1" es5-ext "~0.10.14" @@ -1632,7 +1430,6 @@ es6-symbol@^3.1.1, es6-symbol@~3.1.1: es6-weak-map@^2.0.1: version "2.0.3" resolved "https://registry.yarnpkg.com/es6-weak-map/-/es6-weak-map-2.0.3.tgz#b6da1f16cc2cc0d9be43e6bdbfc5e7dfcdf31d53" - integrity sha512-p5um32HOTO1kP+w7PRnB+5lQ43Z6muuMuIMffvDN8ZB4GcnjLBV6zGStpbASIMk4DCAvEaamhe2zhyCb/QXXsA== dependencies: d "1" es5-ext "^0.10.46" @@ -1641,18 +1438,15 @@ es6-weak-map@^2.0.1: escape-string-regexp@1.0.2: version "1.0.2" - resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.2.tgz#4dbc2fe674e71949caf3fb2695ce7f2dc1d9a8d1" - integrity sha1-Tbwv5nTnGUnK8/smlc5/LcHZqNE= + resolved "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.2.tgz#4dbc2fe674e71949caf3fb2695ce7f2dc1d9a8d1" escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" - integrity sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ= escodegen@1.7.x: version "1.7.1" resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.7.1.tgz#30ecfcf66ca98dc67cd2fd162abeb6eafa8ce6fc" - integrity sha1-MOz89mypjcZ80v0WKr626vqM5vw= dependencies: esprima "^1.2.2" estraverse "^1.9.1" @@ -1664,7 +1458,6 @@ escodegen@1.7.x: escodegen@1.8.x: version "1.8.1" resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.8.1.tgz#5a5b53af4693110bebb0867aa3430dd3b70a1018" - integrity sha1-WltTr0aTEQvrsIZ6o0MN07cKEBg= dependencies: esprima "^2.7.1" estraverse "^1.9.1" @@ -1676,7 +1469,6 @@ escodegen@1.8.x: eslint-scope@3.7.1: version "3.7.1" resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-3.7.1.tgz#3d63c3edfda02e06e01a452ad88caacc7cdcb6e8" - integrity sha1-PWPD7f2gLgbgGkUq2IyqzHzctug= dependencies: esrecurse "^4.1.0" estraverse "^4.1.1" @@ -1684,7 +1476,6 @@ eslint-scope@3.7.1: eslint-scope@^3.7.1: version "3.7.3" resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-3.7.3.tgz#bb507200d3d17f60247636160b4826284b108535" - integrity sha512-W+B0SvF4gamyCTmUc+uITPY0989iXVfKvhwtmJocTaYoc/3khEHmEmvfY/Gn9HA9VV75jrQECsHizkNw1b68FA== dependencies: esrecurse "^4.1.0" estraverse "^4.1.1" @@ -1692,12 +1483,10 @@ eslint-scope@^3.7.1: eslint-visitor-keys@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" - integrity sha512-qzm/XxIbxm/FHyH341ZrbnMUpe+5Bocte9xkmFMzPMjRaZMcXww+MpBptFvtU+79L362nqiLhekCxCxDPaUMBQ== eslint@^4.0.0: version "4.19.1" resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.19.1.tgz#32d1d653e1d90408854bfb296f076ec7e186a300" - integrity sha512-bT3/1x1EbZB7phzYu7vCr1v3ONuzDtX8WjuM9c0iYxe+cq+pwcKEoQjl7zd3RpC6YOLgnSy3cTN58M2jcoPDIQ== dependencies: ajv "^5.3.0" babel-code-frame "^6.22.0" @@ -1741,7 +1530,6 @@ eslint@^4.0.0: espree@^3.5.4: version "3.5.4" resolved "https://registry.yarnpkg.com/espree/-/espree-3.5.4.tgz#b0f447187c8a8bed944b815a660bddf5deb5d1a7" - integrity sha512-yAcIQxtmMiB/jL32dzEp2enBeidsB7xWPLNiw3IIkpVds1P+h7qF9YwJq1yUNzp2OKXgAprs4F61ih66UsoD1A== dependencies: acorn "^5.5.0" acorn-jsx "^3.0.0" @@ -1749,34 +1537,28 @@ espree@^3.5.4: esprima@2.5.x: version "2.5.0" resolved "https://registry.yarnpkg.com/esprima/-/esprima-2.5.0.tgz#f387a46fd344c1b1a39baf8c20bfb43b6d0058cc" - integrity sha1-84ekb9NEwbGjm6+MIL+0O20AWMw= esprima@2.7.x, esprima@^2.7.1: version "2.7.3" resolved "https://registry.yarnpkg.com/esprima/-/esprima-2.7.3.tgz#96e3b70d5779f6ad49cd032673d1c312767ba581" - integrity sha1-luO3DVd59q1JzQMmc9HDEnZ7pYE= esprima@^1.2.2: version "1.2.5" resolved "https://registry.yarnpkg.com/esprima/-/esprima-1.2.5.tgz#0993502feaf668138325756f30f9a51feeec11e9" - integrity sha1-CZNQL+r2aBODJXVvMPmlH+7sEek= esprima@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" - integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== esquery@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.1.tgz#406c51658b1f5991a5f9b62b1dc25b00e3e5c708" - integrity sha512-SmiyZ5zIWH9VM+SRUReLS5Q8a7GxtRdxEBVZpm98rJM7Sb+A9DVCndXfkeFUd3byderg+EbDkfnevfCwynWaNA== dependencies: estraverse "^4.0.0" esrecurse@^4.1.0: version "4.2.0" resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.2.0.tgz#fa9568d98d3823f9a41d91e902dcab9ea6e5b163" - integrity sha1-+pVo2Y04I/mkHZHpAtyrnqblsWM= dependencies: estraverse "^4.1.0" object-assign "^4.0.1" @@ -1784,22 +1566,18 @@ esrecurse@^4.1.0: estraverse@^1.9.1: version "1.9.3" resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-1.9.3.tgz#af67f2dc922582415950926091a4005d29c9bb44" - integrity sha1-r2fy3JIlgkFZUJJgkaQAXSnJu0Q= estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1: version "4.2.0" resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.2.0.tgz#0dee3fed31fcd469618ce7342099fc1afa0bdb13" - integrity sha1-De4/7TH81GlhjOc0IJn8GvoL2xM= esutils@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.2.tgz#0abf4f1caa5bcb1f7a9d8acc6dea4faaa04bac9b" - integrity sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs= expand-brackets@^2.1.4: version "2.1.4" resolved "https://registry.yarnpkg.com/expand-brackets/-/expand-brackets-2.1.4.tgz#b77735e315ce30f6b6eff0f83b04151a22449622" - integrity sha1-t3c14xXOMPa27/D4OwQVGiJEliI= dependencies: debug "^2.3.3" define-property "^0.2.5" @@ -1812,21 +1590,18 @@ expand-brackets@^2.1.4: expand-tilde@^2.0.0, expand-tilde@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/expand-tilde/-/expand-tilde-2.0.2.tgz#97e801aa052df02454de46b02bf621642cdc8502" - integrity sha1-l+gBqgUt8CRU3kawK/YhZCzchQI= dependencies: homedir-polyfill "^1.0.1" extend-shallow@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-2.0.1.tgz#51af7d614ad9a9f610ea1bafbb989d6b1c56890f" - integrity sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8= dependencies: is-extendable "^0.1.0" extend-shallow@^3.0.0, extend-shallow@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-3.0.2.tgz#26a71aaf073b39fb2127172746131c2704028db8" - integrity sha1-Jqcarwc7OfshJxcnRhMcJwQCjbg= dependencies: assign-symbols "^1.0.0" is-extendable "^1.0.1" @@ -1834,12 +1609,10 @@ extend-shallow@^3.0.0, extend-shallow@^3.0.2: extend@^3.0.0, extend@~3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444" - integrity sha1-p1Xqe8Gt/MWjHOfnYtuq3F5jZEQ= external-editor@^2.0.4: version "2.2.0" resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-2.2.0.tgz#045511cfd8d133f3846673d1047c154e214ad3d5" - integrity sha512-bSn6gvGxKt+b7+6TKEv1ZycHleA7aHhRHyAqJyp5pbUFuYYNIzpZnQDk7AsYckyWdEnTeAnay0aCy2aV6iTk9A== dependencies: chardet "^0.4.0" iconv-lite "^0.4.17" @@ -1848,7 +1621,6 @@ external-editor@^2.0.4: extglob@^2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/extglob/-/extglob-2.0.4.tgz#ad00fe4dc612a9232e8718711dc5cb5ab0285543" - integrity sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw== dependencies: array-unique "^0.3.2" define-property "^1.0.0" @@ -1862,12 +1634,10 @@ extglob@^2.0.4: extsprintf@1.3.0, extsprintf@^1.2.0: version "1.3.0" resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz#96918440e3041a7a414f8c52e3c574eb3c3e1e05" - integrity sha1-lpGEQOMEGnpBT4xS48V06zw+HgU= fancy-log@^1.1.0: version "1.3.0" resolved "https://registry.yarnpkg.com/fancy-log/-/fancy-log-1.3.0.tgz#45be17d02bb9917d60ccffd4995c999e6c8c9948" - integrity sha1-Rb4X0Cu5kX1gzP/UmVyZnmyMmUg= dependencies: chalk "^1.1.1" time-stamp "^1.0.0" @@ -1875,7 +1645,6 @@ fancy-log@^1.1.0: fancy-log@^1.3.2: version "1.3.3" resolved "https://registry.yarnpkg.com/fancy-log/-/fancy-log-1.3.3.tgz#dbc19154f558690150a23953a0adbd035be45fc7" - integrity sha512-k9oEhlyc0FrVh25qYuSELjr8oxsCoc4/LEZfg2iJJrfEk/tZL9bCoJE47gqAvI2m/AUjluCS4+3I0eTx8n3AEw== dependencies: ansi-gray "^0.1.1" color-support "^1.1.3" @@ -1885,34 +1654,28 @@ fancy-log@^1.3.2: fast-deep-equal@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-1.0.0.tgz#96256a3bc975595eb36d82e9929d060d893439ff" - integrity sha1-liVqO8l1WV6zbYLpkp0GDYk0Of8= fast-json-stable-stringify@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" - integrity sha1-1RQsDK7msRifh9OnYREGT4bIu/I= fast-levenshtein@~1.0.0: version "1.0.7" resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-1.0.7.tgz#0178dcdee023b92905193af0959e8a7639cfdcb9" - integrity sha1-AXjc3uAjuSkFGTrwlZ6KdjnP3Lk= fast-levenshtein@~2.0.4: version "2.0.6" resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" - integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc= figures@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/figures/-/figures-2.0.0.tgz#3ab1a2d2a62c8bfb431a0c94cb797a2fce27c962" - integrity sha1-OrGi0qYsi/tDGgyUy3l6L84nyWI= dependencies: escape-string-regexp "^1.0.5" file-entry-cache@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-2.0.0.tgz#c392990c3e684783d838b8c84a45d8a048458361" - integrity sha1-w5KZDD5oR4PYOLjISkXYoEhFg2E= dependencies: flat-cache "^1.2.1" object-assign "^4.0.1" @@ -1920,7 +1683,6 @@ file-entry-cache@^2.0.0: fileset@0.2.x: version "0.2.1" resolved "https://registry.yarnpkg.com/fileset/-/fileset-0.2.1.tgz#588ef8973c6623b2a76df465105696b96aac8067" - integrity sha1-WI74lzxmI7KnbfRlEFaWuWqsgGc= dependencies: glob "5.x" minimatch "2.x" @@ -1928,25 +1690,36 @@ fileset@0.2.x: fill-range@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-4.0.0.tgz#d544811d428f98eb06a63dc402d2403c328c38f7" - integrity sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc= dependencies: extend-shallow "^2.0.1" is-number "^3.0.0" repeat-string "^1.6.1" to-regex-range "^2.1.0" +find-cache-dir@^2.0.0: + version "2.1.0" + resolved "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-2.1.0.tgz#8d0f94cd13fe43c6c7c261a0d86115ca918c05f7" + dependencies: + commondir "^1.0.1" + make-dir "^2.0.0" + pkg-dir "^3.0.0" + find-up@^1.0.0: version "1.1.2" resolved "https://registry.yarnpkg.com/find-up/-/find-up-1.1.2.tgz#6b2e9822b1a2ce0a60ab64d610eccad53cb24d0f" - integrity sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8= dependencies: path-exists "^2.0.0" pinkie-promise "^2.0.0" +find-up@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz#49169f1d7993430646da61ecc5ae355c21c97b73" + dependencies: + locate-path "^3.0.0" + findup-sync@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/findup-sync/-/findup-sync-2.0.0.tgz#9326b1488c22d1a6088650a86901b2d9a90a2cbc" - integrity sha1-kyaxSIwi0aYIhlCoaQGy2akKLLw= dependencies: detect-file "^1.0.0" is-glob "^3.1.0" @@ -1956,7 +1729,6 @@ findup-sync@^2.0.0: findup-sync@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/findup-sync/-/findup-sync-3.0.0.tgz#17b108f9ee512dfb7a5c7f3c8b27ea9e1a9c08d1" - integrity sha512-YbffarhcicEhOrm4CtrwdKBdCuz576RLdhJDsIfvNtxUuhdRet1qZcsMjqbePtAseKdAnDyM/IyXbu7PRPRLYg== dependencies: detect-file "^1.0.0" is-glob "^4.0.0" @@ -1966,7 +1738,6 @@ findup-sync@^3.0.0: fined@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/fined/-/fined-1.1.0.tgz#b37dc844b76a2f5e7081e884f7c0ae344f153476" - integrity sha1-s33IRLdqL15wgeiE98CuNE8VNHY= dependencies: expand-tilde "^2.0.2" is-plain-object "^2.0.3" @@ -1977,12 +1748,10 @@ fined@^1.0.1: flagged-respawn@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/flagged-respawn/-/flagged-respawn-1.0.0.tgz#4e79ae9b2eb38bf86b3bb56bf3e0a56aa5fcabd7" - integrity sha1-Tnmumy6zi/hrO7Vr8+ClaqX8q9c= flat-cache@^1.2.1: version "1.3.4" resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-1.3.4.tgz#2c2ef77525cc2929007dfffa1dd314aa9c9dee6f" - integrity sha512-VwyB3Lkgacfik2vhqR4uv2rvebqmDvFu4jlN/C1RzWoJEo8I7z4Q404oiqYCkq41mni8EzQnm95emU9seckwtg== dependencies: circular-json "^0.3.1" graceful-fs "^4.1.2" @@ -1992,7 +1761,6 @@ flat-cache@^1.2.1: flush-write-stream@^1.0.2: version "1.1.1" resolved "https://registry.yarnpkg.com/flush-write-stream/-/flush-write-stream-1.1.1.tgz#8dd7d873a1babc207d94ead0c2e0e44276ebf2e8" - integrity sha512-3Z4XhFZ3992uIq0XOqb9AreonueSYphE6oYbpt5+3u06JWklbsPkNv3ZKkP9Bz/r+1MWCaMoSQ28P85+1Yc77w== dependencies: inherits "^2.0.3" readable-stream "^2.3.6" @@ -2000,24 +1768,20 @@ flush-write-stream@^1.0.2: for-in@^1.0.1, for-in@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80" - integrity sha1-gQaNKVqBQuwKxybG4iAMMPttXoA= for-own@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/for-own/-/for-own-1.0.0.tgz#c63332f415cedc4b04dbfe70cf836494c53cb44b" - integrity sha1-xjMy9BXO3EsE2/5wz4NklMU8tEs= dependencies: for-in "^1.0.1" forever-agent@~0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" - integrity sha1-+8cfDEGt6zf5bFd60e1C2P2sypE= form-data@~2.3.1: version "2.3.1" resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.1.tgz#6fb94fbd71885306d73d15cc497fe4cc4ecd44bf" - integrity sha1-b7lPvXGIUwbXPRXMSX/kzE7NRL8= dependencies: asynckit "^0.4.0" combined-stream "^1.0.5" @@ -2026,21 +1790,18 @@ form-data@~2.3.1: fragment-cache@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/fragment-cache/-/fragment-cache-0.2.1.tgz#4290fad27f13e89be7f33799c6bc5a0abfff0d19" - integrity sha1-QpD60n8T6Jvn8zeZxrxaCr//DRk= dependencies: map-cache "^0.2.2" fs-minipass@^1.2.5: version "1.2.6" resolved "https://registry.yarnpkg.com/fs-minipass/-/fs-minipass-1.2.6.tgz#2c5cc30ded81282bfe8a0d7c7c1853ddeb102c07" - integrity sha512-crhvyXcMejjv3Z5d2Fa9sf5xLYVCF5O1c71QxbVnbLsmYMBEvDAftewesN/HhY03YRoA7zOMxjNGrF5svGaaeQ== dependencies: minipass "^2.2.1" fs-mkdirp-stream@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fs-mkdirp-stream/-/fs-mkdirp-stream-1.0.0.tgz#0b7815fc3201c6a69e14db98ce098c16935259eb" - integrity sha1-C3gV/DIBxqaeFNuYzgmMFpNSWes= dependencies: graceful-fs "^4.1.11" through2 "^2.0.3" @@ -2048,12 +1809,10 @@ fs-mkdirp-stream@^1.0.0: fs.realpath@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" - integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= fsevents@^1.2.7: version "1.2.9" resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.2.9.tgz#3f5ed66583ccd6f400b5a00db6f7e861363e388f" - integrity sha512-oeyj2H3EjjonWcFjD5NvZNE9Rqe4UW+nQBU2HNeKw0koVLEFIhtyETyAakeAM3de7Z/SW5kcA+fZUait9EApnw== dependencies: nan "^2.12.1" node-pre-gyp "^0.12.0" @@ -2061,17 +1820,14 @@ fsevents@^1.2.7: function-bind@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" - integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== functional-red-black-tree@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" - integrity sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc= gauge@~2.7.3: version "2.7.4" resolved "https://registry.yarnpkg.com/gauge/-/gauge-2.7.4.tgz#2c03405c7538c39d7eb37b317022e325fb018bf7" - integrity sha1-LANAXHU4w51+s3sxcCLjJfsBi/c= dependencies: aproba "^1.0.3" console-control-strings "^1.0.0" @@ -2085,24 +1841,20 @@ gauge@~2.7.3: get-caller-file@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.3.tgz#f978fa4c90d1dfe7ff2d6beda2a515e713bdcf4a" - integrity sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w== get-value@^2.0.3, get-value@^2.0.6: version "2.0.6" resolved "https://registry.yarnpkg.com/get-value/-/get-value-2.0.6.tgz#dc15ca1c672387ca76bd37ac0a395ba2042a2c28" - integrity sha1-3BXKHGcjh8p2vTesCjlbogQqLCg= getpass@^0.1.1: version "0.1.7" resolved "https://registry.yarnpkg.com/getpass/-/getpass-0.1.7.tgz#5eff8e3e684d569ae4cb2b1282604e8ba62149fa" - integrity sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo= dependencies: assert-plus "^1.0.0" glob-parent@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-3.1.0.tgz#9e6af6299d8d3bd2bd40430832bd113df906c5ae" - integrity sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4= dependencies: is-glob "^3.1.0" path-dirname "^1.0.0" @@ -2110,7 +1862,6 @@ glob-parent@^3.1.0: glob-stream@^6.1.0: version "6.1.0" resolved "https://registry.yarnpkg.com/glob-stream/-/glob-stream-6.1.0.tgz#7045c99413b3eb94888d83ab46d0b404cc7bdde4" - integrity sha1-cEXJlBOz65SIjYOrRtC0BMx73eQ= dependencies: extend "^3.0.0" glob "^7.1.1" @@ -2126,7 +1877,6 @@ glob-stream@^6.1.0: glob-watcher@^5.0.3: version "5.0.3" resolved "https://registry.yarnpkg.com/glob-watcher/-/glob-watcher-5.0.3.tgz#88a8abf1c4d131eb93928994bc4a593c2e5dd626" - integrity sha512-8tWsULNEPHKQ2MR4zXuzSmqbdyV5PtwwCaWSGQ1WwHsJ07ilNeN1JB8ntxhckbnpSHaf9dXFUHzIWvm1I13dsg== dependencies: anymatch "^2.0.0" async-done "^1.2.0" @@ -2137,8 +1887,7 @@ glob-watcher@^5.0.3: glob@3.2.11: version "3.2.11" - resolved "https://registry.yarnpkg.com/glob/-/glob-3.2.11.tgz#4a973f635b9190f715d10987d5c00fd2815ebe3d" - integrity sha1-Spc/Y1uRkPcV0QmH1cAP0oFevj0= + resolved "https://registry.npmjs.org/glob/-/glob-3.2.11.tgz#4a973f635b9190f715d10987d5c00fd2815ebe3d" dependencies: inherits "2" minimatch "0.3" @@ -2146,7 +1895,6 @@ glob@3.2.11: glob@5.x, glob@^5.0.15: version "5.0.15" resolved "https://registry.yarnpkg.com/glob/-/glob-5.0.15.tgz#1bc936b9e02f4a603fcc222ecf7633d30b8b93b1" - integrity sha1-G8k2ueAvSmA/zCIuz3Yz0wuLk7E= dependencies: inflight "^1.0.4" inherits "2" @@ -2157,7 +1905,6 @@ glob@5.x, glob@^5.0.15: glob@^7.1.1, glob@^7.1.2, glob@^7.1.3: version "7.1.4" resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.4.tgz#aa608a2f6c577ad357e1ae5a5c26d9a8d1969255" - integrity sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A== dependencies: fs.realpath "^1.0.0" inflight "^1.0.4" @@ -2169,7 +1916,6 @@ glob@^7.1.1, glob@^7.1.2, glob@^7.1.3: global-modules@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/global-modules/-/global-modules-1.0.0.tgz#6d770f0eb523ac78164d72b5e71a8877265cc3ea" - integrity sha512-sKzpEkf11GpOFuw0Zzjzmt4B4UZwjOcG757PPvrfhxcLFbq0wpsgpOqxpxtxFiCG4DtG93M6XRVbF2oGdev7bg== dependencies: global-prefix "^1.0.1" is-windows "^1.0.1" @@ -2178,7 +1924,6 @@ global-modules@^1.0.0: global-prefix@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/global-prefix/-/global-prefix-1.0.2.tgz#dbf743c6c14992593c655568cb66ed32c0122ebe" - integrity sha1-2/dDxsFJklk8ZVVoy2btMsASLr4= dependencies: expand-tilde "^2.0.2" homedir-polyfill "^1.0.1" @@ -2189,29 +1934,24 @@ global-prefix@^1.0.1: globals@^11.0.1, globals@^11.1.0: version "11.12.0" resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" - integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== glogg@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/glogg/-/glogg-1.0.0.tgz#7fe0f199f57ac906cf512feead8f90ee4a284fc5" - integrity sha1-f+DxmfV6yQbPUS/urY+Q7kooT8U= dependencies: sparkles "^1.0.0" graceful-fs@^4.0.0, graceful-fs@^4.1.11, graceful-fs@^4.1.2, graceful-fs@^4.1.6: version "4.2.0" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.0.tgz#8d8fdc73977cb04104721cb53666c1ca64cd328b" - integrity sha512-jpSvDPV4Cq/bgtpndIWbI5hmYxhQGHPC4d4cqBPb4DLniCfhJokdXhwhaDuLBGLQdvvRum/UiX6ECVIPvDXqdg== growl@1.9.2: version "1.9.2" - resolved "https://registry.yarnpkg.com/growl/-/growl-1.9.2.tgz#0ea7743715db8d8de2c5ede1775e1b45ac85c02f" - integrity sha1-Dqd0NxXbjY3ixe3hd14bRayFwC8= + resolved "https://registry.npmjs.org/growl/-/growl-1.9.2.tgz#0ea7743715db8d8de2c5ede1775e1b45ac85c02f" gulp-babel@^8.0.0: version "8.0.0" resolved "https://registry.yarnpkg.com/gulp-babel/-/gulp-babel-8.0.0.tgz#e0da96f4f2ec4a88dd3a3030f476e38ab2126d87" - integrity sha512-oomaIqDXxFkg7lbpBou/gnUkX51/Y/M2ZfSjL2hdqXTAlSWZcgZtd2o0cOH0r/eE8LWD0+Q/PsLsr2DKOoqToQ== dependencies: plugin-error "^1.0.1" replace-ext "^1.0.0" @@ -2221,7 +1961,6 @@ gulp-babel@^8.0.0: gulp-cli@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/gulp-cli/-/gulp-cli-2.2.0.tgz#5533126eeb7fe415a7e3e84a297d334d5cf70ebc" - integrity sha512-rGs3bVYHdyJpLqR0TUBnlcZ1O5O++Zs4bA0ajm+zr3WFCfiSLjGwoCBqFs18wzN+ZxahT9DkOK5nDf26iDsWjA== dependencies: ansi-colors "^1.0.1" archy "^1.0.0" @@ -2245,7 +1984,6 @@ gulp-cli@^2.2.0: gulp-eslint@4.0.2: version "4.0.2" resolved "https://registry.yarnpkg.com/gulp-eslint/-/gulp-eslint-4.0.2.tgz#18a2a6768e4404cbf3e203239cb57474168fa606" - integrity sha512-fcFUQzFsN6dJ6KZlG+qPOEkqfcevRUXgztkYCvhNvJeSvOicC8ucutN4qR/ID8LmNZx9YPIkBzazTNnVvbh8wg== dependencies: eslint "^4.0.0" fancy-log "^1.3.2" @@ -2254,14 +1992,12 @@ gulp-eslint@4.0.2: gulp-exclude-gitignore@^1.0.0: version "1.2.0" resolved "https://registry.yarnpkg.com/gulp-exclude-gitignore/-/gulp-exclude-gitignore-1.2.0.tgz#341aeb62faab428af5550da9359ceff99388f1d0" - integrity sha512-J3LCmz9C1UU1pxf5Npx6SNc5o9YQptyc9IHaqLiBlihZmg44jaaTplWUZ0JPQkMdOTae0YgEDvT9TKlUWDSMUA== dependencies: gulp-ignore "^2.0.2" gulp-ignore@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/gulp-ignore/-/gulp-ignore-2.0.2.tgz#5c2ea2a0a4402e0ab4a2bcd12efd9295344d78f2" - integrity sha1-XC6ioKRALgq0orzRLv2SlTRNePI= dependencies: gulp-match "^1.0.3" through2 "^2.0.1" @@ -2269,7 +2005,6 @@ gulp-ignore@^2.0.2: gulp-istanbul@^0.10.3: version "0.10.4" resolved "https://registry.yarnpkg.com/gulp-istanbul/-/gulp-istanbul-0.10.4.tgz#2b2a1bcbeb96a62c78e69821d104d6fca32efb09" - integrity sha1-Kyoby+uWpix45pgh0QTW/KMu+wk= dependencies: gulp-util "^3.0.1" istanbul "^0.4.0" @@ -2280,14 +2015,12 @@ gulp-istanbul@^0.10.3: gulp-match@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/gulp-match/-/gulp-match-1.0.3.tgz#91c7c0d7f29becd6606d57d80a7f8776a87aba8e" - integrity sha1-kcfA1/Kb7NZgbVfYCn+Hdqh6uo4= dependencies: minimatch "^3.0.3" gulp-mocha@^2.0.0: version "2.2.0" - resolved "https://registry.yarnpkg.com/gulp-mocha/-/gulp-mocha-2.2.0.tgz#1ce5eba4b94b40c7436afec3c4982c8eea894192" - integrity sha1-HOXrpLlLQMdDav7DxJgsjuqJQZI= + resolved "https://registry.npmjs.org/gulp-mocha/-/gulp-mocha-2.2.0.tgz#1ce5eba4b94b40c7436afec3c4982c8eea894192" dependencies: gulp-util "^3.0.0" mocha "^2.0.1" @@ -2299,7 +2032,6 @@ gulp-mocha@^2.0.0: gulp-plumber@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/gulp-plumber/-/gulp-plumber-1.1.0.tgz#f12176c2d0422f60306c242fff6a01a394faba09" - integrity sha1-8SF2wtBCL2AwbCQv/2oBo5T6ugk= dependencies: gulp-util "^3" through2 "^2" @@ -2307,7 +2039,6 @@ gulp-plumber@^1.1.0: gulp-util@^3, gulp-util@^3.0.0, gulp-util@^3.0.1: version "3.0.8" resolved "https://registry.yarnpkg.com/gulp-util/-/gulp-util-3.0.8.tgz#0054e1e744502e27c04c187c3ecc505dd54bbb4f" - integrity sha1-AFTh50RQLifATBh8PsxQXdVLu08= dependencies: array-differ "^1.0.0" array-uniq "^1.0.2" @@ -2331,7 +2062,6 @@ gulp-util@^3, gulp-util@^3.0.0, gulp-util@^3.0.1: gulp@^4.0.2: version "4.0.2" resolved "https://registry.yarnpkg.com/gulp/-/gulp-4.0.2.tgz#543651070fd0f6ab0a0650c6a3e6ff5a7cb09caa" - integrity sha512-dvEs27SCZt2ibF29xYgmnwwCYZxdxhQ/+LFWlbAW8y7jt68L/65402Lz3+CKy0Ov4rOs+NERmDq7YlZaDqUIfA== dependencies: glob-watcher "^5.0.3" gulp-cli "^2.2.0" @@ -2341,14 +2071,12 @@ gulp@^4.0.2: gulplog@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/gulplog/-/gulplog-1.0.0.tgz#e28c4d45d05ecbbed818363ce8f9c5926229ffe5" - integrity sha1-4oxNRdBey77YGDY86PnFkmIp/+U= dependencies: glogg "^1.0.0" handlebars@^4.0.1: version "4.1.2" resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.1.2.tgz#b6b37c1ced0306b221e094fc7aca3ec23b131b67" - integrity sha512-nvfrjqvt9xQ8Z/w0ijewdD/vvWDTOweBUm96NTr66Wfvo1mJenBLwcYmPs3TIBP5ruzYGD7Hx/DaM9RmhroGPw== dependencies: neo-async "^2.6.0" optimist "^0.6.1" @@ -2359,12 +2087,10 @@ handlebars@^4.0.1: har-schema@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" - integrity sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI= har-validator@~5.0.3: version "5.0.3" resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.0.3.tgz#ba402c266194f15956ef15e0fcf242993f6a7dfd" - integrity sha1-ukAsJmGU8VlW7xXg/PJCmT9qff0= dependencies: ajv "^5.1.0" har-schema "^2.0.0" @@ -2372,41 +2098,34 @@ har-validator@~5.0.3: has-ansi@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/has-ansi/-/has-ansi-2.0.0.tgz#34f5049ce1ecdf2b0649af3ef24e45ed35416d91" - integrity sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE= dependencies: ansi-regex "^2.0.0" has-flag@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-1.0.0.tgz#9d9e793165ce017a00f00418c43f942a7b1d11fa" - integrity sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo= has-flag@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" - integrity sha1-tdRU3CGZriJWmfNGfloH87lVuv0= has-gulplog@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/has-gulplog/-/has-gulplog-0.1.0.tgz#6414c82913697da51590397dafb12f22967811ce" - integrity sha1-ZBTIKRNpfaUVkDl9r7EvIpZ4Ec4= dependencies: sparkles "^1.0.0" has-symbols@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.0.tgz#ba1a8f1af2a0fc39650f5c850367704122063b44" - integrity sha1-uhqPGvKg/DllD1yFA2dwQSIGO0Q= has-unicode@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/has-unicode/-/has-unicode-2.0.1.tgz#e0e6fe6a28cf51138855e086d1691e771de2a8b9" - integrity sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk= has-value@^0.3.1: version "0.3.1" resolved "https://registry.yarnpkg.com/has-value/-/has-value-0.3.1.tgz#7b1f58bada62ca827ec0a2078025654845995e1f" - integrity sha1-ex9YutpiyoJ+wKIHgCVlSEWZXh8= dependencies: get-value "^2.0.3" has-values "^0.1.4" @@ -2415,7 +2134,6 @@ has-value@^0.3.1: has-value@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/has-value/-/has-value-1.0.0.tgz#18b281da585b1c5c51def24c930ed29a0be6b177" - integrity sha1-GLKB2lhbHFxR3vJMkw7SmgvmsXc= dependencies: get-value "^2.0.6" has-values "^1.0.0" @@ -2424,12 +2142,10 @@ has-value@^1.0.0: has-values@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/has-values/-/has-values-0.1.4.tgz#6d61de95d91dfca9b9a02089ad384bff8f62b771" - integrity sha1-bWHeldkd/Km5oCCJrThL/49it3E= has-values@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/has-values/-/has-values-1.0.0.tgz#95b0b63fec2146619a6fe57fe75628d5a39efe4f" - integrity sha1-lbC2P+whRmGab+V/51Yo1aOe/k8= dependencies: is-number "^3.0.0" kind-of "^4.0.0" @@ -2437,7 +2153,6 @@ has-values@^1.0.0: hawk@~6.0.2: version "6.0.2" resolved "https://registry.yarnpkg.com/hawk/-/hawk-6.0.2.tgz#af4d914eb065f9b5ce4d9d11c1cb2126eecc3038" - integrity sha512-miowhl2+U7Qle4vdLqDdPt9m09K6yZhkLDTWGoUiUzrQCn+mHHSmfJgAyGaLRZbPmTqfFFjRV1QWCW0VWUJBbQ== dependencies: boom "4.x.x" cryptiles "3.x.x" @@ -2447,29 +2162,24 @@ hawk@~6.0.2: hoek@4.x.x: version "4.2.0" resolved "https://registry.yarnpkg.com/hoek/-/hoek-4.2.0.tgz#72d9d0754f7fe25ca2d01ad8f8f9a9449a89526d" - integrity sha512-v0XCLxICi9nPfYrS9RL8HbYnXi9obYAeLbSP00BmnZwCK9+Ih9WOjoZ8YoHCoav2csqn4FOz4Orldsy2dmDwmQ== homedir-polyfill@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/homedir-polyfill/-/homedir-polyfill-1.0.1.tgz#4c2bbc8a758998feebf5ed68580f76d46768b4bc" - integrity sha1-TCu8inWJmP7r9e1oWA921GdotLw= dependencies: parse-passwd "^1.0.0" hosted-git-info@^2.1.4: version "2.7.1" resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.7.1.tgz#97f236977bd6e125408930ff6de3eec6281ec047" - integrity sha512-7T/BxH19zbcCTa8XkMlbK5lTo1WtgkFi3GvdWEyNuc4Vex7/9Dqbnpsf4JMydcfj9HCg4zUWFTL3Za6lapg5/w== htmlencode@^0.0.4: version "0.0.4" resolved "https://registry.yarnpkg.com/htmlencode/-/htmlencode-0.0.4.tgz#f7e2d6afbe18a87a78e63ba3308e753766740e3f" - integrity sha1-9+LWr74YqHp45jujMI51N2Z0Dj8= http-signature@~1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/http-signature/-/http-signature-1.2.0.tgz#9aecd925114772f3d95b65a60abb8f7c18fbace1" - integrity sha1-muzZJRFHcvPZW2WmCruPfBj7rOE= dependencies: assert-plus "^1.0.0" jsprim "^1.2.2" @@ -2478,31 +2188,26 @@ http-signature@~1.2.0: iconv-lite@^0.4.17, iconv-lite@^0.4.4: version "0.4.24" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" - integrity sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA== dependencies: safer-buffer ">= 2.1.2 < 3" ignore-walk@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/ignore-walk/-/ignore-walk-3.0.1.tgz#a83e62e7d272ac0e3b551aaa82831a19b69f82f8" - integrity sha512-DTVlMx3IYPe0/JJcYP7Gxg7ttZZu3IInhuEhbchuqneY9wWe5Ojy2mXLBaQFUQmo0AW2r3qG7m1mg86js+gnlQ== dependencies: minimatch "^3.0.4" ignore@^3.3.3: version "3.3.10" resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.10.tgz#0a97fb876986e8081c631160f8f9f389157f0043" - integrity sha512-Pgs951kaMm5GXP7MOvxERINe3gsaVjUWFm+UZPSq9xYriQAksyhg0csnS0KXSNRD5NmNdapXEpjxG49+AKh/ug== imurmurhash@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" - integrity sha1-khi5srkoojixPcT7a21XbyMUU+o= inflight@^1.0.4: version "1.0.6" resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" - integrity sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk= dependencies: once "^1.3.0" wrappy "1" @@ -2510,22 +2215,18 @@ inflight@^1.0.4: inherits@2, inherits@^2.0.3, inherits@~2.0.1, inherits@~2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de" - integrity sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4= inherits@^2.0.1: version "2.0.4" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" - integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== ini@^1.3.4, ini@~1.3.0: version "1.3.5" resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.5.tgz#eee25f56db1c9ec6085e0c22778083f596abf927" - integrity sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw== inquirer@^3.0.6: version "3.3.0" resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-3.3.0.tgz#9dd2f2ad765dcab1ff0443b491442a20ba227dc9" - integrity sha512-h+xtnyk4EwKvFWHrUYsWErEVR+igKtLdchu+o0Z1RL7VU/jVMFbYir2bp6bAj8efFNxWqHX0dIss6fJQ+/+qeQ== dependencies: ansi-escapes "^3.0.0" chalk "^2.0.0" @@ -2545,29 +2246,24 @@ inquirer@^3.0.6: interpret@^1.1.0: version "1.2.0" resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.2.0.tgz#d5061a6224be58e8083985f5014d844359576296" - integrity sha512-mT34yGKMNceBQUoVn7iCDKDntA7SC6gycMAWzGx1z/CMCTV7b2AAtXlo3nRyHZ1FelRkQbQjprHSYGwzLtkVbw== invariant@^2.2.2: version "2.2.2" resolved "https://registry.yarnpkg.com/invariant/-/invariant-2.2.2.tgz#9e1f56ac0acdb6bf303306f338be3b204ae60360" - integrity sha1-nh9WrArNtr8wMwbzOL47IErmA2A= dependencies: loose-envify "^1.0.0" invert-kv@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-1.0.0.tgz#104a8e4aaca6d3d8cd157a8ef8bfab2d7a3ffdb6" - integrity sha1-EEqOSqym09jNFXqO+L+rLXo//bY= irregular-plurals@^1.0.0: version "1.4.0" - resolved "https://registry.yarnpkg.com/irregular-plurals/-/irregular-plurals-1.4.0.tgz#2ca9b033651111855412f16be5d77c62a458a766" - integrity sha1-LKmwM2UREYVUEvFr5dd8YqRYp2Y= + resolved "https://registry.npmjs.org/irregular-plurals/-/irregular-plurals-1.4.0.tgz#2ca9b033651111855412f16be5d77c62a458a766" is-absolute@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-absolute/-/is-absolute-1.0.0.tgz#395e1ae84b11f26ad1795e73c17378e48a301576" - integrity sha512-dOWoqflvcydARa360Gvv18DZ/gRuHKi2NU/wU5X1ZFzdYfH29nkiNZsF3mp4OJ3H4yo9Mx8A/uAGNzpzPN3yBA== dependencies: is-relative "^1.0.0" is-windows "^1.0.1" @@ -2575,52 +2271,44 @@ is-absolute@^1.0.0: is-accessor-descriptor@^0.1.6: version "0.1.6" resolved "https://registry.yarnpkg.com/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz#a9e12cb3ae8d876727eeef3843f8a0897b5c98d6" - integrity sha1-qeEss66Nh2cn7u84Q/igiXtcmNY= dependencies: kind-of "^3.0.2" is-accessor-descriptor@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz#169c2f6d3df1f992618072365c9b0ea1f6878656" - integrity sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ== dependencies: kind-of "^6.0.0" is-arrayish@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" - integrity sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0= is-binary-path@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/is-binary-path/-/is-binary-path-1.0.1.tgz#75f16642b480f187a711c814161fd3a4a7655898" - integrity sha1-dfFmQrSA8YenEcgUFh/TpKdlWJg= dependencies: binary-extensions "^1.0.0" is-buffer@^1.1.5: version "1.1.5" resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.5.tgz#1f3b26ef613b214b88cbca23cc6c01d87961eecc" - integrity sha1-Hzsm72E7IUuIy8ojzGwB2Hlh7sw= is-data-descriptor@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz#0b5ee648388e2c860282e793f1856fec3f301b56" - integrity sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y= dependencies: kind-of "^3.0.2" is-data-descriptor@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz#d84876321d0e7add03990406abbbbd36ba9268c7" - integrity sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ== dependencies: kind-of "^6.0.0" is-descriptor@^0.1.0: version "0.1.6" resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-0.1.6.tgz#366d8240dde487ca51823b1ab9f07a10a78251ca" - integrity sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg== dependencies: is-accessor-descriptor "^0.1.6" is-data-descriptor "^0.1.4" @@ -2629,7 +2317,6 @@ is-descriptor@^0.1.0: is-descriptor@^1.0.0, is-descriptor@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-1.0.2.tgz#3b159746a66604b04f8c81524ba365c5f14d86ec" - integrity sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg== dependencies: is-accessor-descriptor "^1.0.0" is-data-descriptor "^1.0.0" @@ -2638,157 +2325,130 @@ is-descriptor@^1.0.0, is-descriptor@^1.0.2: is-extendable@^0.1.0, is-extendable@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/is-extendable/-/is-extendable-0.1.1.tgz#62b110e289a471418e3ec36a617d472e301dfc89" - integrity sha1-YrEQ4omkcUGOPsNqYX1HLjAd/Ik= is-extendable@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/is-extendable/-/is-extendable-1.0.1.tgz#a7470f9e426733d81bd81e1155264e3a3507cab4" - integrity sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA== dependencies: is-plain-object "^2.0.4" is-extglob@^2.1.0, is-extglob@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" - integrity sha1-qIwCU1eR8C7TfHahueqXc8gz+MI= is-fullwidth-code-point@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz#ef9e31386f031a7f0d643af82fde50c457ef00cb" - integrity sha1-754xOG8DGn8NZDr4L95QxFfvAMs= dependencies: number-is-nan "^1.0.0" is-fullwidth-code-point@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" - integrity sha1-o7MKXE8ZkYMWeqq5O+764937ZU8= is-glob@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-3.1.0.tgz#7ba5ae24217804ac70707b96922567486cc3e84a" - integrity sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo= dependencies: is-extglob "^2.1.0" is-glob@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.1.tgz#7567dbe9f2f5e2467bc77ab83c4a29482407a5dc" - integrity sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg== dependencies: is-extglob "^2.1.1" is-negated-glob@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-negated-glob/-/is-negated-glob-1.0.0.tgz#6910bca5da8c95e784b5751b976cf5a10fee36d2" - integrity sha1-aRC8pdqMleeEtXUbl2z1oQ/uNtI= is-number@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/is-number/-/is-number-3.0.0.tgz#24fd6201a4782cf50561c810276afc7d12d71195" - integrity sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU= dependencies: kind-of "^3.0.2" is-number@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/is-number/-/is-number-4.0.0.tgz#0026e37f5454d73e356dfe6564699867c6a7f0ff" - integrity sha512-rSklcAIlf1OmFdyAqbnWTLVelsQ58uvZ66S/ZyawjWqIviTWCjg2PzVGw8WUA+nNuPTqb4wgA+NszrJ+08LlgQ== is-odd@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-odd/-/is-odd-2.0.0.tgz#7646624671fd7ea558ccd9a2795182f2958f1b24" - integrity sha512-OTiixgpZAT1M4NHgS5IguFp/Vz2VI3U7Goh4/HA1adtwyLtSBrxYlcSYkhpAE07s4fKEcjrFxyvtQBND4vFQyQ== dependencies: is-number "^4.0.0" is-plain-object@^2.0.1, is-plain-object@^2.0.3, is-plain-object@^2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/is-plain-object/-/is-plain-object-2.0.4.tgz#2c163b3fafb1b606d9d17928f05c2a1c38e07677" - integrity sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og== dependencies: isobject "^3.0.1" is-promise@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.1.0.tgz#79a2a9ece7f096e80f36d2b2f3bc16c1ff4bf3fa" - integrity sha1-eaKp7OfwlugPNtKy87wWwf9L8/o= is-relative@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-relative/-/is-relative-1.0.0.tgz#a1bb6935ce8c5dba1e8b9754b9b2dcc020e2260d" - integrity sha512-Kw/ReK0iqwKeu0MITLFuj0jbPAmEiOsIwyIXvvbfa6QfmN9pkD1M+8pdk7Rl/dTKbH34/XBFMbgD4iMJhLQbGA== dependencies: is-unc-path "^1.0.0" is-resolvable@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-resolvable/-/is-resolvable-1.1.0.tgz#fb18f87ce1feb925169c9a407c19318a3206ed88" - integrity sha512-qgDYXFSR5WvEfuS5dMj6oTMEbrrSaM0CrFk2Yiq/gXnBvD9pMa2jGXxyhGLfvhZpuMZe18CJpFxAt3CRs42NMg== is-typedarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" - integrity sha1-5HnICFjfDBsR3dppQPlgEfzaSpo= is-unc-path@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-unc-path/-/is-unc-path-1.0.0.tgz#d731e8898ed090a12c352ad2eaed5095ad322c9d" - integrity sha512-mrGpVd0fs7WWLfVsStvgF6iEJnbjDFZh9/emhRDcGWTduTfNHd9CHeUwH3gYIjdbwo4On6hunkztwOaAw0yllQ== dependencies: unc-path-regex "^0.1.2" is-utf8@^0.2.0, is-utf8@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/is-utf8/-/is-utf8-0.2.1.tgz#4b0da1442104d1b336340e80797e865cf39f7d72" - integrity sha1-Sw2hRCEE0bM2NA6AeX6GXPOffXI= is-valid-glob@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-valid-glob/-/is-valid-glob-1.0.0.tgz#29bf3eff701be2d4d315dbacc39bc39fe8f601aa" - integrity sha1-Kb8+/3Ab4tTTFdusw5vDn+j2Aao= is-windows@^1.0.1, is-windows@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/is-windows/-/is-windows-1.0.2.tgz#d1850eb9791ecd18e6182ce12a30f396634bb19d" - integrity sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA== isarray@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/isarray/-/isarray-0.0.1.tgz#8a18acfca9a8f4177e09abfc6038939b05d1eedf" - integrity sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8= isarray@1.0.0, isarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" - integrity sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE= isexe@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" - integrity sha1-6PvzdNxVb/iUehDcsFctYz8s+hA= isobject@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/isobject/-/isobject-2.1.0.tgz#f065561096a3f1da2ef46272f815c840d87e0c89" - integrity sha1-8GVWEJaj8dou9GJy+BXIQNh+DIk= dependencies: isarray "1.0.0" isobject@^3.0.0, isobject@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/isobject/-/isobject-3.0.1.tgz#4e431e92b11a9731636aa1f9c8d1ccbcfdab78df" - integrity sha1-TkMekrEalzFjaqH5yNHMvP2reN8= isstream@~0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" - integrity sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo= istanbul-threshold-checker@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/istanbul-threshold-checker/-/istanbul-threshold-checker-0.1.0.tgz#0e1442c017cb27a85f781734fefd2126405ca39c" - integrity sha1-DhRCwBfLJ6hfeBc0/v0hJkBco5w= dependencies: istanbul "0.3.*" lodash "3.6.*" @@ -2796,7 +2456,6 @@ istanbul-threshold-checker@^0.1.0: istanbul@0.3.*: version "0.3.22" resolved "https://registry.yarnpkg.com/istanbul/-/istanbul-0.3.22.tgz#3e164d85021fe19c985d1f0e7ef0c3e22d012eb6" - integrity sha1-PhZNhQIf4ZyYXR8OfvDD4i0BLrY= dependencies: abbrev "1.0.x" async "1.x" @@ -2816,7 +2475,6 @@ istanbul@0.3.*: istanbul@^0.4.0: version "0.4.5" resolved "https://registry.yarnpkg.com/istanbul/-/istanbul-0.4.5.tgz#65c7d73d4c4da84d4f3ac310b918fb0b8033733b" - integrity sha1-ZcfXPUxNqE1POsMQuRj7C4Azczs= dependencies: abbrev "1.0.x" async "1.x" @@ -2835,8 +2493,7 @@ istanbul@^0.4.0: jade@0.26.3: version "0.26.3" - resolved "https://registry.yarnpkg.com/jade/-/jade-0.26.3.tgz#8f10d7977d8d79f2f6ff862a81b0513ccb25686c" - integrity sha1-jxDXl32NefL2/4YqgbBRPMslaGw= + resolved "https://registry.npmjs.org/jade/-/jade-0.26.3.tgz#8f10d7977d8d79f2f6ff862a81b0513ccb25686c" dependencies: commander "0.6.1" mkdirp "0.3.0" @@ -2844,22 +2501,18 @@ jade@0.26.3: js-levenshtein@^1.1.3: version "1.1.6" resolved "https://registry.yarnpkg.com/js-levenshtein/-/js-levenshtein-1.1.6.tgz#c6cee58eb3550372df8deb85fad5ce66ce01d59d" - integrity sha512-X2BB11YZtrRqY4EnQcLX5Rh373zbK4alC1FW7D7MBhL2gtcC17cTnr6DmfHZeS0s2rTHjUTMMHfG7gO8SSdw+g== js-tokens@^3.0.0, js-tokens@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b" - integrity sha1-mGbfOVECEw449/mWvOtlRDIJwls= js-tokens@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" - integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== js-yaml@3.x, js-yaml@^3.9.1: version "3.13.1" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.13.1.tgz#aff151b30bfdfa8e49e05da22e7415e9dfa37847" - integrity sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw== dependencies: argparse "^1.0.7" esprima "^4.0.0" @@ -2867,61 +2520,50 @@ js-yaml@3.x, js-yaml@^3.9.1: jsbn@~0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513" - integrity sha1-peZUwuWi3rXyAdls77yoDA7y9RM= jsesc@^2.5.1: version "2.5.2" resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.2.tgz#80564d2e483dacf6e8ef209650a67df3f0c283a4" - integrity sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA== jsesc@~0.5.0: version "0.5.0" resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-0.5.0.tgz#e7dee66e35d6fc16f710fe91d5cf69f70f08911d" - integrity sha1-597mbjXW/Bb3EP6R1c9p9w8IkR0= json-schema-traverse@^0.3.0: version "0.3.1" resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz#349a6d44c53a51de89b40805c5d5e59b417d3340" - integrity sha1-NJptRMU6Ud6JtAgFxdXlm0F9M0A= json-schema@0.2.3: version "0.2.3" resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" - integrity sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM= json-stable-stringify-without-jsonify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" - integrity sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE= json-stable-stringify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz#9a759d39c5f2ff503fd5300646ed445f88c4f9af" - integrity sha1-mnWdOcXy/1A/1TAGRu1EX4jE+a8= dependencies: jsonify "~0.0.0" json-stringify-safe@^5.0.1, json-stringify-safe@~5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" - integrity sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus= json5@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/json5/-/json5-2.1.0.tgz#e7a0c62c48285c628d20a10b85c89bb807c32850" - integrity sha512-8Mh9h6xViijj36g7Dxi+Y4S6hNGV96vcJZr/SrlHh1LR/pEn/8j/+qIBbs44YKl69Lrfctp4QD+AdWLTMqEZAQ== dependencies: minimist "^1.2.0" jsonify@~0.0.0: version "0.0.0" resolved "https://registry.yarnpkg.com/jsonify/-/jsonify-0.0.0.tgz#2c74b6ee41d93ca51b7b5aaee8f503631d252a73" - integrity sha1-LHS27kHZPKUbe1qu6PUDYx0lKnM= jsprim@^1.2.2: version "1.4.1" resolved "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.1.tgz#313e66bc1e5cc06e438bc1b7499c2e5c56acb6a2" - integrity sha1-MT5mvB5cwG5Di8G3SZwuXFastqI= dependencies: assert-plus "1.0.0" extsprintf "1.3.0" @@ -2931,41 +2573,34 @@ jsprim@^1.2.2: just-debounce@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/just-debounce/-/just-debounce-1.0.0.tgz#87fccfaeffc0b68cd19d55f6722943f929ea35ea" - integrity sha1-h/zPrv/AtozRnVX2cilD+SnqNeo= just-extend@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/just-extend/-/just-extend-3.0.0.tgz#cee004031eaabf6406da03a7b84e4fe9d78ef288" - integrity sha512-Fu3T6pKBuxjWT/p4DkqGHFRsysc8OauWr4ZRTY9dIx07Y9O0RkoR5jcv28aeD1vuAwhm3nLkDurwLXoALp4DpQ== kind-of@^3.0.2, kind-of@^3.0.3, kind-of@^3.2.0: version "3.2.2" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-3.2.2.tgz#31ea21a734bab9bbb0f32466d893aea51e4a3c64" - integrity sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ= dependencies: is-buffer "^1.1.5" kind-of@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-4.0.0.tgz#20813df3d712928b207378691a45066fae72dd57" - integrity sha1-IIE989cSkosgc3hpGkUGb65y3Vc= dependencies: is-buffer "^1.1.5" kind-of@^5.0.0, kind-of@^5.0.2: version "5.1.0" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-5.1.0.tgz#729c91e2d857b7a419a1f9aa65685c4c33f5845d" - integrity sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw== kind-of@^6.0.0, kind-of@^6.0.2: version "6.0.2" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.2.tgz#01146b36a6218e64e58f3a8d66de5d7fc6f6d051" - integrity sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA== last-run@^1.1.0: version "1.1.1" resolved "https://registry.yarnpkg.com/last-run/-/last-run-1.1.1.tgz#45b96942c17b1c79c772198259ba943bebf8ca5b" - integrity sha1-RblpQsF7HHnHchmCWbqUO+v4yls= dependencies: default-resolution "^2.0.0" es6-weak-map "^2.0.1" @@ -2973,28 +2608,24 @@ last-run@^1.1.0: lazystream@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/lazystream/-/lazystream-1.0.0.tgz#f6995fe0f820392f61396be89462407bb77168e4" - integrity sha1-9plf4PggOS9hOWvolGJAe7dxaOQ= dependencies: readable-stream "^2.0.5" lcid@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/lcid/-/lcid-1.0.0.tgz#308accafa0bc483a3867b4b6f2b9506251d1b835" - integrity sha1-MIrMr6C8SDo4Z7S28rlQYlHRuDU= dependencies: invert-kv "^1.0.0" lead@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/lead/-/lead-1.0.0.tgz#6f14f99a37be3a9dd784f5495690e5903466ee42" - integrity sha1-bxT5mje+Op3XhPVJVpDlkDRm7kI= dependencies: flush-write-stream "^1.0.2" levn@^0.3.0, levn@~0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/levn/-/levn-0.3.0.tgz#3b09924edf9f083c0490fdd4c0bc4421e04764ee" - integrity sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4= dependencies: prelude-ls "~1.1.2" type-check "~0.3.2" @@ -3002,7 +2633,6 @@ levn@^0.3.0, levn@~0.3.0: levn@~0.2.5: version "0.2.5" resolved "https://registry.yarnpkg.com/levn/-/levn-0.2.5.tgz#ba8d339d0ca4a610e3a3f145b9caf48807155054" - integrity sha1-uo0znQykphDjo/FFucr0iAcVUFQ= dependencies: prelude-ls "~1.1.0" type-check "~0.3.1" @@ -3010,7 +2640,6 @@ levn@~0.2.5: liftoff@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/liftoff/-/liftoff-3.1.0.tgz#c9ba6081f908670607ee79062d700df062c52ed3" - integrity sha512-DlIPlJUkCV0Ips2zf2pJP0unEoT1kwYhiiPUGF3s/jtxTCjziNLoiVVh+jqWOWeFi6mmwQ5fNxvAUyPad4Dfog== dependencies: extend "^3.0.0" findup-sync "^3.0.0" @@ -3024,7 +2653,6 @@ liftoff@^3.1.0: load-json-file@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-1.1.0.tgz#956905708d58b4bab4c2261b04f59f31c99374c0" - integrity sha1-lWkFcI1YtLq0wiYbBPWfMcmTdMA= dependencies: graceful-fs "^4.1.2" parse-json "^2.2.0" @@ -3032,77 +2660,70 @@ load-json-file@^1.0.0: pinkie-promise "^2.0.0" strip-bom "^2.0.0" +locate-path@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz#dbec3b3ab759758071b58fe59fc41871af21400e" + dependencies: + p-locate "^3.0.0" + path-exists "^3.0.0" + lodash._basecopy@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/lodash._basecopy/-/lodash._basecopy-3.0.1.tgz#8da0e6a876cf344c0ad8a54882111dd3c5c7ca36" - integrity sha1-jaDmqHbPNEwK2KVIghEd08XHyjY= lodash._basetostring@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/lodash._basetostring/-/lodash._basetostring-3.0.1.tgz#d1861d877f824a52f669832dcaf3ee15566a07d5" - integrity sha1-0YYdh3+CSlL2aYMtyvPuFVZqB9U= lodash._basevalues@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/lodash._basevalues/-/lodash._basevalues-3.0.0.tgz#5b775762802bde3d3297503e26300820fdf661b7" - integrity sha1-W3dXYoAr3j0yl1A+JjAIIP32Ybc= lodash._getnative@^3.0.0: version "3.9.1" resolved "https://registry.yarnpkg.com/lodash._getnative/-/lodash._getnative-3.9.1.tgz#570bc7dede46d61cdcde687d65d3eecbaa3aaff5" - integrity sha1-VwvH3t5G1hzc3mh9ZdPuy6o6r/U= lodash._isiterateecall@^3.0.0: version "3.0.9" resolved "https://registry.yarnpkg.com/lodash._isiterateecall/-/lodash._isiterateecall-3.0.9.tgz#5203ad7ba425fae842460e696db9cf3e6aac057c" - integrity sha1-UgOte6Ql+uhCRg5pbbnPPmqsBXw= lodash._reescape@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/lodash._reescape/-/lodash._reescape-3.0.0.tgz#2b1d6f5dfe07c8a355753e5f27fac7f1cde1616a" - integrity sha1-Kx1vXf4HyKNVdT5fJ/rH8c3hYWo= lodash._reevaluate@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/lodash._reevaluate/-/lodash._reevaluate-3.0.0.tgz#58bc74c40664953ae0b124d806996daca431e2ed" - integrity sha1-WLx0xAZklTrgsSTYBpltrKQx4u0= lodash._reinterpolate@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/lodash._reinterpolate/-/lodash._reinterpolate-3.0.0.tgz#0ccf2d89166af03b3663c796538b75ac6e114d9d" - integrity sha1-DM8tiRZq8Ds2Y8eWU4t1rG4RTZ0= lodash._root@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/lodash._root/-/lodash._root-3.0.1.tgz#fba1c4524c19ee9a5f8136b4609f017cf4ded692" - integrity sha1-+6HEUkwZ7ppfgTa0YJ8BfPTe1pI= lodash.escape@^3.0.0: version "3.2.0" resolved "https://registry.yarnpkg.com/lodash.escape/-/lodash.escape-3.2.0.tgz#995ee0dc18c1b48cc92effae71a10aab5b487698" - integrity sha1-mV7g3BjBtIzJLv+ucaEKq1tIdpg= dependencies: lodash._root "^3.0.0" lodash.get@^4.4.2: version "4.4.2" resolved "https://registry.yarnpkg.com/lodash.get/-/lodash.get-4.4.2.tgz#2d177f652fa31e939b4438d5341499dfa3825e99" - integrity sha1-LRd/ZS+jHpObRDjVNBSZ36OCXpk= lodash.isarguments@^3.0.0: version "3.1.0" resolved "https://registry.yarnpkg.com/lodash.isarguments/-/lodash.isarguments-3.1.0.tgz#2f573d85c6a24289ff00663b491c1d338ff3458a" - integrity sha1-L1c9hcaiQon/AGY7SRwdM4/zRYo= lodash.isarray@^3.0.0: version "3.0.4" resolved "https://registry.yarnpkg.com/lodash.isarray/-/lodash.isarray-3.0.4.tgz#79e4eb88c36a8122af86f844aa9bcd851b5fbb55" - integrity sha1-eeTriMNqgSKvhvhEqpvNhRtfu1U= lodash.keys@^3.0.0: version "3.1.2" resolved "https://registry.yarnpkg.com/lodash.keys/-/lodash.keys-3.1.2.tgz#4dbc0472b156be50a0b286855d1bd0b0c656098a" - integrity sha1-TbwEcrFWvlCgsoaFXRvQsMZWCYo= dependencies: lodash._getnative "^3.0.0" lodash.isarguments "^3.0.0" @@ -3111,12 +2732,10 @@ lodash.keys@^3.0.0: lodash.restparam@^3.0.0: version "3.6.1" resolved "https://registry.yarnpkg.com/lodash.restparam/-/lodash.restparam-3.6.1.tgz#936a4e309ef330a7645ed4145986c85ae5b20805" - integrity sha1-k2pOMJ7zMKdkXtQUWYbIWuWyCAU= lodash.template@^3.0.0: version "3.6.2" resolved "https://registry.yarnpkg.com/lodash.template/-/lodash.template-3.6.2.tgz#f8cdecc6169a255be9098ae8b0c53d378931d14f" - integrity sha1-+M3sxhaaJVvpCYrosMU9N4kx0U8= dependencies: lodash._basecopy "^3.0.0" lodash._basetostring "^3.0.0" @@ -3131,7 +2750,6 @@ lodash.template@^3.0.0: lodash.templatesettings@^3.0.0: version "3.1.1" resolved "https://registry.yarnpkg.com/lodash.templatesettings/-/lodash.templatesettings-3.1.1.tgz#fb307844753b66b9f1afa54e262c745307dba8e5" - integrity sha1-+zB4RHU7Zrnxr6VOJix0UwfbqOU= dependencies: lodash._reinterpolate "^3.0.0" lodash.escape "^3.0.0" @@ -3139,76 +2757,70 @@ lodash.templatesettings@^3.0.0: lodash@3.6.*: version "3.6.0" resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.6.0.tgz#5266a8f49dd989be4f9f681b6f2a0c55285d0d9a" - integrity sha1-Umao9J3Zib5Pn2gbbyoMVShdDZo= lodash@^3.10.1: version "3.10.1" resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.10.1.tgz#5bf45e8e49ba4189e17d482789dfd15bd140b7b6" - integrity sha1-W/Rejkm6QYnhfUgnid/RW9FAt7Y= lodash@^4.0.0, lodash@^4.17.4: version "4.17.4" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.4.tgz#78203a4d1c328ae1d86dca6460e369b57f4055ae" - integrity sha1-eCA6TRwyiuHYbcpkYONptX9AVa4= lodash@^4.17.11, lodash@^4.3.0: version "4.17.11" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.11.tgz#b39ea6229ef607ecd89e2c8df12536891cac9b8d" - integrity sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg== lolex@^2.3.2: version "2.3.2" resolved "https://registry.yarnpkg.com/lolex/-/lolex-2.3.2.tgz#85f9450425103bf9e7a60668ea25dc43274ca807" - integrity sha512-A5pN2tkFj7H0dGIAM6MFvHKMJcPnjZsOMvR7ujCjfgW5TbV6H9vb1PgxLtHvjqNZTHsUolz+6/WEO0N1xNx2ng== lolex@^2.7.5: version "2.7.5" resolved "https://registry.yarnpkg.com/lolex/-/lolex-2.7.5.tgz#113001d56bfc7e02d56e36291cc5c413d1aa0733" - integrity sha512-l9x0+1offnKKIzYVjyXU2SiwhXDLekRzKyhnbyldPHvC7BvLPVpdNUNR2KeMAiCN2D/kLNttZgQD5WjSxuBx3Q== loose-envify@^1.0.0: version "1.3.1" resolved "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.3.1.tgz#d1a8ad33fa9ce0e713d65fdd0ac8b748d478c848" - integrity sha1-0aitM/qc4OcT1l/dCsi3SNR4yEg= dependencies: js-tokens "^3.0.0" lru-cache@2: version "2.7.3" - resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-2.7.3.tgz#6d4524e8b955f95d4f5b58851ce21dd72fb4e952" - integrity sha1-bUUk6LlV+V1PW1iFHOId1y+06VI= + resolved "https://registry.npmjs.org/lru-cache/-/lru-cache-2.7.3.tgz#6d4524e8b955f95d4f5b58851ce21dd72fb4e952" lru-cache@^4.0.1: version "4.1.5" resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.5.tgz#8bbe50ea85bed59bc9e33dcab8235ee9bcf443cd" - integrity sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g== dependencies: pseudomap "^1.0.2" yallist "^2.1.2" +make-dir@^2.0.0: + version "2.1.0" + resolved "https://registry.npmjs.org/make-dir/-/make-dir-2.1.0.tgz#5f0310e18b8be898cc07009295a30ae41e91e6f5" + dependencies: + pify "^4.0.1" + semver "^5.6.0" + make-iterator@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/make-iterator/-/make-iterator-1.0.1.tgz#29b33f312aa8f547c4a5e490f56afcec99133ad6" - integrity sha512-pxiuXh0iVEq7VM7KMIhs5gxsfxCux2URptUQaXo4iZZJxBAzTPOLE2BumO5dbfVYq/hBJFBR/a1mFDmOx5AGmw== dependencies: kind-of "^6.0.2" map-cache@^0.2.0, map-cache@^0.2.2: version "0.2.2" resolved "https://registry.yarnpkg.com/map-cache/-/map-cache-0.2.2.tgz#c32abd0bd6525d9b051645bb4f26ac5dc98a0dbf" - integrity sha1-wyq9C9ZSXZsFFkW7TyasXcmKDb8= map-visit@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/map-visit/-/map-visit-1.0.0.tgz#ecdca8f13144e660f1b5bd41f12f3479d98dfb8f" - integrity sha1-7Nyo8TFE5mDxtb1B8S80edmN+48= dependencies: object-visit "^1.0.0" matchdep@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/matchdep/-/matchdep-2.0.0.tgz#c6f34834a0d8dbc3b37c27ee8bbcb27c7775582e" - integrity sha1-xvNINKDY28OzfCfui7yyfHd1WC4= dependencies: findup-sync "^2.0.0" micromatch "^3.0.4" @@ -3218,7 +2830,6 @@ matchdep@^2.0.0: micromatch@^3.0.4, micromatch@^3.1.10, micromatch@^3.1.4: version "3.1.10" resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-3.1.10.tgz#70859bc95c9840952f359a068a3fc49f9ecfac23" - integrity sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg== dependencies: arr-diff "^4.0.0" array-unique "^0.3.2" @@ -3237,24 +2848,20 @@ micromatch@^3.0.4, micromatch@^3.1.10, micromatch@^3.1.4: mime-db@~1.30.0: version "1.30.0" resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.30.0.tgz#74c643da2dd9d6a45399963465b26d5ca7d71f01" - integrity sha1-dMZD2i3Z1qRTmZY0ZbJtXKfXHwE= mime-types@^2.1.12, mime-types@~2.1.17: version "2.1.17" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.17.tgz#09d7a393f03e995a79f8af857b70a9e0ab16557a" - integrity sha1-Cdejk/A+mVp5+K+Fe3Cp4KsWVXo= dependencies: mime-db "~1.30.0" mimic-fn@^1.0.0: version "1.2.0" resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" - integrity sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ== minimatch@0.3: version "0.3.0" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-0.3.0.tgz#275d8edaac4f1bb3326472089e7949c8394699dd" - integrity sha1-J12O2qxPG7MyZHIInnlJyDlGmd0= + resolved "https://registry.npmjs.org/minimatch/-/minimatch-0.3.0.tgz#275d8edaac4f1bb3326472089e7949c8394699dd" dependencies: lru-cache "2" sigmund "~1.0.0" @@ -3262,36 +2869,30 @@ minimatch@0.3: "minimatch@2 || 3", minimatch@^3.0.2, minimatch@^3.0.3, minimatch@^3.0.4: version "3.0.4" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" - integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== dependencies: brace-expansion "^1.1.7" minimatch@2.x: version "2.0.10" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-2.0.10.tgz#8d087c39c6b38c001b97fca7ce6d0e1e80afbac7" - integrity sha1-jQh8OcazjAAbl/ynzm0OHoCvusc= dependencies: brace-expansion "^1.0.0" minimist@0.0.8: version "0.0.8" resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d" - integrity sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0= minimist@^1.1.0, minimist@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284" - integrity sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ= minimist@~0.0.1: version "0.0.10" resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.10.tgz#de3f98543dbf96082be48ad1a0c7cda836301dcf" - integrity sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8= minipass@^2.2.1, minipass@^2.3.5: version "2.3.5" resolved "https://registry.yarnpkg.com/minipass/-/minipass-2.3.5.tgz#cacebe492022497f656b0f0f51e2682a9ed2d848" - integrity sha512-Gi1W4k059gyRbyVUZQ4mEqLm0YIUiGYfvxhF6SIlk3ui1WVxMTGfGdQ2SInh3PDrRTVvPKgULkpJtT4RH10+VA== dependencies: safe-buffer "^5.1.2" yallist "^3.0.0" @@ -3299,34 +2900,29 @@ minipass@^2.2.1, minipass@^2.3.5: minizlib@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/minizlib/-/minizlib-1.2.1.tgz#dd27ea6136243c7c880684e8672bb3a45fd9b614" - integrity sha512-7+4oTUOWKg7AuL3vloEWekXY2/D20cevzsrNT2kGWm+39J9hGTCBv8VI5Pm5lXZ/o3/mdR4f8rflAPhnQb8mPA== dependencies: minipass "^2.2.1" mixin-deep@^1.2.0: version "1.3.1" resolved "https://registry.yarnpkg.com/mixin-deep/-/mixin-deep-1.3.1.tgz#a49e7268dce1a0d9698e45326c5626df3543d0fe" - integrity sha512-8ZItLHeEgaqEvd5lYBXfm4EZSFCX29Jb9K+lAHhDKzReKBQKj3R+7NOF6tjqYi9t4oI8VUfaWITJQm86wnXGNQ== dependencies: for-in "^1.0.2" is-extendable "^1.0.1" mkdirp@0.3.0: version "0.3.0" - resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.3.0.tgz#1bbf5ab1ba827af23575143490426455f481fe1e" - integrity sha1-G79asbqCevI1dRQ0kEJkVfSB/h4= + resolved "https://registry.npmjs.org/mkdirp/-/mkdirp-0.3.0.tgz#1bbf5ab1ba827af23575143490426455f481fe1e" mkdirp@0.5.1, mkdirp@0.5.x, mkdirp@^0.5.0, mkdirp@^0.5.1: version "0.5.1" resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.1.tgz#30057438eac6cf7f8c4767f38648d6697d75c903" - integrity sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM= dependencies: minimist "0.0.8" mocha@^2.0.1: version "2.5.3" - resolved "https://registry.yarnpkg.com/mocha/-/mocha-2.5.3.tgz#161be5bdeb496771eb9b35745050b622b5aefc58" - integrity sha1-FhvlvetJZ3HrmzV0UFC2IrWu/Fg= + resolved "https://registry.npmjs.org/mocha/-/mocha-2.5.3.tgz#161be5bdeb496771eb9b35745050b622b5aefc58" dependencies: commander "2.3.0" debug "2.2.0" @@ -3341,45 +2937,37 @@ mocha@^2.0.1: ms@0.7.1: version "0.7.1" - resolved "https://registry.yarnpkg.com/ms/-/ms-0.7.1.tgz#9cd13c03adbff25b65effde7ce864ee952017098" - integrity sha1-nNE8A62/8ltl7/3nzoZO6VIBcJg= + resolved "https://registry.npmjs.org/ms/-/ms-0.7.1.tgz#9cd13c03adbff25b65effde7ce864ee952017098" ms@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" - integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g= ms@^2.1.1: version "2.1.2" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" - integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== multipipe@^0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/multipipe/-/multipipe-0.1.2.tgz#2a8f2ddf70eed564dff2d57f1e1a137d9f05078b" - integrity sha1-Ko8t33Du1WTf8tV/HhoTfZ8FB4s= dependencies: duplexer2 "0.0.2" mute-stdout@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/mute-stdout/-/mute-stdout-1.0.1.tgz#acb0300eb4de23a7ddeec014e3e96044b3472331" - integrity sha512-kDcwXR4PS7caBpuRYYBUz9iVixUk3anO3f5OYFiIPwK/20vCzKCHyKoulbiDY1S53zD2bxUpxN/IJ+TnXjfvxg== mute-stream@0.0.7: version "0.0.7" resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.7.tgz#3075ce93bc21b8fab43e1bc4da7e8115ed1e7bab" - integrity sha1-MHXOk7whuPq0PhvE2n6BFe0ee6s= nan@^2.12.1: version "2.14.0" resolved "https://registry.yarnpkg.com/nan/-/nan-2.14.0.tgz#7818f722027b2459a86f0295d434d1fc2336c52c" - integrity sha512-INOFj37C7k3AfaNTtX8RhsTw7qRy7eLET14cROi9+5HAVbbHuIWUHEauBv5qT4Av2tWasiTY1Jw6puUNqRJXQg== nanomatch@^1.2.9: version "1.2.9" resolved "https://registry.yarnpkg.com/nanomatch/-/nanomatch-1.2.9.tgz#879f7150cb2dab7a471259066c104eee6e0fa7c2" - integrity sha512-n8R9bS8yQ6eSXaV6jHUpKzD8gLsin02w1HSFiegwrs9E098Ylhw5jdyKPaYqvHknHaSCKTPp7C8dGCQ0q9koXA== dependencies: arr-diff "^4.0.0" array-unique "^0.3.2" @@ -3397,12 +2985,10 @@ nanomatch@^1.2.9: natural-compare@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" - integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= needle@^2.2.1: version "2.4.0" resolved "https://registry.yarnpkg.com/needle/-/needle-2.4.0.tgz#6833e74975c444642590e15a750288c5f939b57c" - integrity sha512-4Hnwzr3mi5L97hMYeNl8wRW/Onhy4nUKR/lVemJ8gJedxxUyBLm9kkrDColJvoSfwi0jCNhD+xCdOtiGDQiRZg== dependencies: debug "^3.2.6" iconv-lite "^0.4.4" @@ -3411,17 +2997,14 @@ needle@^2.2.1: neo-async@^2.6.0: version "2.6.1" resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.1.tgz#ac27ada66167fa8849a6addd837f6b189ad2081c" - integrity sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw== next-tick@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/next-tick/-/next-tick-1.0.0.tgz#ca86d1fe8828169b0120208e3dc8424b9db8342c" - integrity sha1-yobR/ogoFpsBICCOPchCS524NCw= nise@^1.4.5: version "1.4.6" resolved "https://registry.yarnpkg.com/nise/-/nise-1.4.6.tgz#76cc3915925056ae6c405dd8ad5d12bde570c19f" - integrity sha512-1GedetLKzmqmgwabuMSqPsT7oumdR77SBpDfNNJhADRIeA3LN/2RVqR4fFqwvzhAqcTef6PPCzQwITE/YQ8S8A== dependencies: "@sinonjs/formatio" "3.0.0" just-extend "^3.0.0" @@ -3432,7 +3015,6 @@ nise@^1.4.5: nock@7.5.0: version "7.5.0" resolved "https://registry.yarnpkg.com/nock/-/nock-7.5.0.tgz#e287dd3e5458cd305c3a859c7a80dfed369c0bbe" - integrity sha1-4ofdPlRYzTBcOoWceoDf7TacC74= dependencies: chai ">=1.9.2 <4.0.0" debug "^2.2.0" @@ -3443,10 +3025,13 @@ nock@7.5.0: propagate "0.3.x" qs "^6.0.2" +node-modules-regexp@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/node-modules-regexp/-/node-modules-regexp-1.0.0.tgz#8d9dbe28964a4ac5712e9131642107c71e90ec40" + node-pre-gyp@^0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.12.0.tgz#39ba4bb1439da030295f899e3b520b7785766149" - integrity sha512-4KghwV8vH5k+g2ylT+sLTjy5wmUOb9vPhnM8NHvRf9dHmnW/CndrFXy2aRPaPST6dugXSdHXfeaHQm77PIz/1A== dependencies: detect-libc "^1.0.2" mkdirp "^0.5.1" @@ -3462,21 +3047,18 @@ node-pre-gyp@^0.12.0: node-releases@^1.1.23: version "1.1.25" resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-1.1.25.tgz#0c2d7dbc7fed30fbe02a9ee3007b8c90bf0133d3" - integrity sha512-fI5BXuk83lKEoZDdH3gRhtsNgh05/wZacuXkgbiYkceE7+QIMXOg98n9ZV7mz27B+kFHnqHcUpscZZlGRSmTpQ== dependencies: semver "^5.3.0" nopt@3.x: version "3.0.6" resolved "https://registry.yarnpkg.com/nopt/-/nopt-3.0.6.tgz#c6465dbf08abcd4db359317f79ac68a646b28ff9" - integrity sha1-xkZdvwirzU2zWTF/eaxopkayj/k= dependencies: abbrev "1" nopt@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/nopt/-/nopt-4.0.1.tgz#d0d4685afd5415193c8c7505602d0d17cd64474d" - integrity sha1-0NRoWv1UFRk8jHUFYC0NF81kR00= dependencies: abbrev "1" osenv "^0.1.4" @@ -3484,7 +3066,6 @@ nopt@^4.0.1: normalize-package-data@^2.3.2: version "2.5.0" resolved "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-2.5.0.tgz#e66db1838b200c1dfc233225d12cb36520e234a8" - integrity sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA== dependencies: hosted-git-info "^2.1.4" resolve "^1.10.0" @@ -3494,31 +3075,26 @@ normalize-package-data@^2.3.2: normalize-path@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-2.1.1.tgz#1ab28b556e198363a8c1a6f7e6fa20137fe6aed9" - integrity sha1-GrKLVW4Zg2Oowab35vogE3/mrtk= dependencies: remove-trailing-separator "^1.0.1" normalize-path@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" - integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== now-and-later@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/now-and-later/-/now-and-later-2.0.1.tgz#8e579c8685764a7cc02cb680380e94f43ccb1f7c" - integrity sha512-KGvQ0cB70AQfg107Xvs/Fbu+dGmZoTRJp2TaPwcwQm3/7PteUyN2BCgk8KBMPGBUXZdVwyWS8fDCGFygBm19UQ== dependencies: once "^1.3.2" npm-bundled@^1.0.1: version "1.0.6" resolved "https://registry.yarnpkg.com/npm-bundled/-/npm-bundled-1.0.6.tgz#e7ba9aadcef962bb61248f91721cd932b3fe6bdd" - integrity sha512-8/JCaftHwbd//k6y2rEWp6k1wxVfpFzB6t1p825+cUb7Ym2XQfhwIC5KwhrvzZRJu+LtDE585zVaS32+CGtf0g== npm-packlist@^1.1.6: version "1.4.4" resolved "https://registry.yarnpkg.com/npm-packlist/-/npm-packlist-1.4.4.tgz#866224233850ac534b63d1a6e76050092b5d2f44" - integrity sha512-zTLo8UcVYtDU3gdeaFu2Xu0n0EvelfHDGuqtNIn5RO7yQj4H1TqNdBc/yZjxnWA0PVB8D3Woyp0i5B43JwQ6Vw== dependencies: ignore-walk "^3.0.1" npm-bundled "^1.0.1" @@ -3526,7 +3102,6 @@ npm-packlist@^1.1.6: npmlog@^4.0.2: version "4.1.2" resolved "https://registry.yarnpkg.com/npmlog/-/npmlog-4.1.2.tgz#08a7f2a8bf734604779a9efa4ad5cc717abb954b" - integrity sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg== dependencies: are-we-there-yet "~1.1.2" console-control-strings "~1.1.0" @@ -3536,27 +3111,22 @@ npmlog@^4.0.2: number-is-nan@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" - integrity sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0= oauth-sign@~0.8.2: version "0.8.2" resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.8.2.tgz#46a6ab7f0aead8deae9ec0565780b7d4efeb9d43" - integrity sha1-Rqarfwrq2N6unsBWV4C31O/rnUM= object-assign@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-3.0.0.tgz#9bedd5ca0897949bca47e7ff408062d549f587f2" - integrity sha1-m+3VygiXlJvKR+f/QIBi1Un1h/I= object-assign@^4.0.1, object-assign@^4.1.0: version "4.1.1" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" - integrity sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM= object-copy@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/object-copy/-/object-copy-0.1.0.tgz#7e7d858b781bd7c991a41ba975ed3812754e998c" - integrity sha1-fn2Fi3gb18mRpBupde04EnVOmYw= dependencies: copy-descriptor "^0.1.0" define-property "^0.2.5" @@ -3565,19 +3135,16 @@ object-copy@^0.1.0: object-keys@^1.0.11, object-keys@^1.0.12: version "1.1.1" resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.1.1.tgz#1c47f272df277f3b1daf061677d9c82e2322c60e" - integrity sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA== object-visit@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/object-visit/-/object-visit-1.0.1.tgz#f79c4493af0c5377b59fe39d395e41042dd045bb" - integrity sha1-95xEk68MU3e1n+OdOV5BBC3QRbs= dependencies: isobject "^3.0.0" object.assign@^4.0.4: version "4.1.0" resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.1.0.tgz#968bf1100d7956bb3ca086f006f846b3bc4008da" - integrity sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w== dependencies: define-properties "^1.1.2" function-bind "^1.1.1" @@ -3587,7 +3154,6 @@ object.assign@^4.0.4: object.defaults@^1.0.0, object.defaults@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/object.defaults/-/object.defaults-1.1.0.tgz#3a7f868334b407dea06da16d88d5cd29e435fecf" - integrity sha1-On+GgzS0B96gbaFtiNXNKeQ1/s8= dependencies: array-each "^1.0.1" array-slice "^1.0.0" @@ -3597,7 +3163,6 @@ object.defaults@^1.0.0, object.defaults@^1.1.0: object.map@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/object.map/-/object.map-1.0.1.tgz#cf83e59dc8fcc0ad5f4250e1f78b3b81bd801d37" - integrity sha1-z4Plncj8wK1fQlDh94s7gb2AHTc= dependencies: for-own "^1.0.0" make-iterator "^1.0.0" @@ -3605,14 +3170,12 @@ object.map@^1.0.0: object.pick@^1.2.0, object.pick@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/object.pick/-/object.pick-1.3.0.tgz#87a10ac4c1694bd2e1cbf53591a66141fb5dd747" - integrity sha1-h6EKxMFpS9Lhy/U1kaZhQftd10c= dependencies: isobject "^3.0.1" object.reduce@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/object.reduce/-/object.reduce-1.0.1.tgz#6fe348f2ac7fa0f95ca621226599096825bb03ad" - integrity sha1-b+NI8qx/oPlcpiEiZZkJaCW7A60= dependencies: for-own "^1.0.0" make-iterator "^1.0.0" @@ -3620,21 +3183,18 @@ object.reduce@^1.0.0: once@1.x, once@^1.3.0, once@^1.3.1, once@^1.3.2, once@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" - integrity sha1-WDsap3WWHUsROsF9nFC6753Xa9E= dependencies: wrappy "1" onetime@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/onetime/-/onetime-2.0.1.tgz#067428230fd67443b2794b22bba528b6867962d4" - integrity sha1-BnQoIw/WdEOyeUsiu6UotoZ5YtQ= dependencies: mimic-fn "^1.0.0" optimist@^0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/optimist/-/optimist-0.6.1.tgz#da3ea74686fa21a19a111c326e90eb15a0196686" - integrity sha1-2j6nRob6IaGaERwybpDrFaAZZoY= dependencies: minimist "~0.0.1" wordwrap "~0.0.2" @@ -3642,7 +3202,6 @@ optimist@^0.6.1: optionator@^0.5.0: version "0.5.0" resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.5.0.tgz#b75a8995a2d417df25b6e4e3862f50aa88651368" - integrity sha1-t1qJlaLUF98ltuTjhi9QqohlE2g= dependencies: deep-is "~0.1.2" fast-levenshtein "~1.0.0" @@ -3654,7 +3213,6 @@ optionator@^0.5.0: optionator@^0.8.1, optionator@^0.8.2: version "0.8.2" resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.2.tgz#364c5e409d3f4d6301d6c0b4c05bba50180aeb64" - integrity sha1-NkxeQJ0/TWMB1sC0wFu6UBgK62Q= dependencies: deep-is "~0.1.3" fast-levenshtein "~2.0.4" @@ -3666,39 +3224,49 @@ optionator@^0.8.1, optionator@^0.8.2: ordered-read-streams@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/ordered-read-streams/-/ordered-read-streams-1.0.1.tgz#77c0cb37c41525d64166d990ffad7ec6a0e1363e" - integrity sha1-d8DLN8QVJdZBZtmQ/61+xqDhNj4= dependencies: readable-stream "^2.0.1" os-homedir@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/os-homedir/-/os-homedir-1.0.2.tgz#ffbc4988336e0e833de0c168c7ef152121aa7fb3" - integrity sha1-/7xJiDNuDoM94MFox+8VISGqf7M= os-locale@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/os-locale/-/os-locale-1.4.0.tgz#20f9f17ae29ed345e8bde583b13d2009803c14d9" - integrity sha1-IPnxeuKe00XoveWDsT0gCYA8FNk= dependencies: lcid "^1.0.0" os-tmpdir@^1.0.0, os-tmpdir@~1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" - integrity sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ= osenv@^0.1.4: version "0.1.5" resolved "https://registry.yarnpkg.com/osenv/-/osenv-0.1.5.tgz#85cdfafaeb28e8677f416e287592b5f3f49ea410" - integrity sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g== dependencies: os-homedir "^1.0.0" os-tmpdir "^1.0.0" +p-limit@^2.0.0: + version "2.2.0" + resolved "https://registry.npmjs.org/p-limit/-/p-limit-2.2.0.tgz#417c9941e6027a9abcba5092dd2904e255b5fbc2" + dependencies: + p-try "^2.0.0" + +p-locate@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz#322d69a05c0264b25997d9f40cd8a891ab0064a4" + dependencies: + p-limit "^2.0.0" + +p-try@^2.0.0: + version "2.2.0" + resolved "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz#cb2868540e313d61de58fafbe35ce9004d5540e6" + parse-filepath@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/parse-filepath/-/parse-filepath-1.0.2.tgz#a632127f53aaf3d15876f5872f3ffac763d6c891" - integrity sha1-pjISf1Oq89FYdvWHLz/6x2PWyJE= dependencies: is-absolute "^1.0.0" map-cache "^0.2.0" @@ -3707,80 +3275,70 @@ parse-filepath@^1.0.1: parse-json@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-2.2.0.tgz#f480f40434ef80741f8469099f8dea18f55a4dc9" - integrity sha1-9ID0BDTvgHQfhGkJn43qGPVaTck= dependencies: error-ex "^1.2.0" parse-node-version@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/parse-node-version/-/parse-node-version-1.0.1.tgz#e2b5dbede00e7fa9bc363607f53327e8b073189b" - integrity sha512-3YHlOa/JgH6Mnpr05jP9eDG254US9ek25LyIxZlDItp2iJtwyaXQb57lBYLdT3MowkUFYEV2XXNAYIPlESvJlA== parse-passwd@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/parse-passwd/-/parse-passwd-1.0.0.tgz#6d5b934a456993b23d37f40a382d6f1666a8e5c6" - integrity sha1-bVuTSkVpk7I9N/QKOC1vFmao5cY= pascalcase@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/pascalcase/-/pascalcase-0.1.1.tgz#b363e55e8006ca6fe21784d2db22bd15d7917f14" - integrity sha1-s2PlXoAGym/iF4TS2yK9FdeRfxQ= path-dirname@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/path-dirname/-/path-dirname-1.0.2.tgz#cc33d24d525e099a5388c0336c6e32b9160609e0" - integrity sha1-zDPSTVJeCZpTiMAzbG4yuRYGCeA= path-exists@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-2.1.0.tgz#0feb6c64f0fc518d9a754dd5efb62c7022761f4b" - integrity sha1-D+tsZPD8UY2adU3V77YscCJ2H0s= dependencies: pinkie-promise "^2.0.0" +path-exists@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz#ce0ebeaa5f78cb18925ea7d810d7b59b010fd515" + path-is-absolute@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" - integrity sha1-F0uSaHNVNP+8es5r9TpanhtcX18= path-is-inside@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/path-is-inside/-/path-is-inside-1.0.2.tgz#365417dede44430d1c11af61027facf074bdfc53" - integrity sha1-NlQX3t5EQw0cEa9hAn+s8HS9/FM= path-parse@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.5.tgz#3c1adf871ea9cd6c9431b6ea2bd74a0ff055c4c1" - integrity sha1-PBrfhx6pzWyUMbbqK9dKD/BVxME= path-parse@^1.0.6: version "1.0.6" resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.6.tgz#d62dbb5679405d72c4737ec58600e9ddcf06d24c" - integrity sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw== path-root-regex@^0.1.0: version "0.1.2" resolved "https://registry.yarnpkg.com/path-root-regex/-/path-root-regex-0.1.2.tgz#bfccdc8df5b12dc52c8b43ec38d18d72c04ba96d" - integrity sha1-v8zcjfWxLcUsi0PsONGNcsBLqW0= path-root@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/path-root/-/path-root-0.1.1.tgz#9a4a6814cac1c0cd73360a95f32083c8ea4745b7" - integrity sha1-mkpoFMrBwM1zNgqV8yCDyOpHRbc= dependencies: path-root-regex "^0.1.0" path-to-regexp@^1.7.0: version "1.7.0" resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-1.7.0.tgz#59fde0f435badacba103a84e9d3bc64e96b9937d" - integrity sha1-Wf3g9DW62suhA6hOnTvGTpa5k30= dependencies: isarray "0.0.1" path-type@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/path-type/-/path-type-1.1.0.tgz#59c44f7ee491da704da415da5a4070ba4f8fe441" - integrity sha1-WcRPfuSR2nBNpBXaWkBwuk+P5EE= dependencies: graceful-fs "^4.1.2" pify "^2.0.0" @@ -3789,29 +3347,40 @@ path-type@^1.0.0: performance-now@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" - integrity sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns= pify@^2.0.0: version "2.3.0" resolved "https://registry.yarnpkg.com/pify/-/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c" - integrity sha1-7RQaasBDqEnqWISY59yosVMw6Qw= + +pify@^4.0.1: + version "4.0.1" + resolved "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz#4b2cd25c50d598735c50292224fd8c6df41e3231" pinkie-promise@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/pinkie-promise/-/pinkie-promise-2.0.1.tgz#2135d6dfa7a358c069ac9b178776288228450ffa" - integrity sha1-ITXW36ejWMBprJsXh3YogihFD/o= dependencies: pinkie "^2.0.0" pinkie@^2.0.0: version "2.0.4" resolved "https://registry.yarnpkg.com/pinkie/-/pinkie-2.0.4.tgz#72556b80cfa0d48a974e80e77248e80ed4f7f870" - integrity sha1-clVrgM+g1IqXToDnckjoDtT3+HA= + +pirates@^4.0.0: + version "4.0.1" + resolved "https://registry.npmjs.org/pirates/-/pirates-4.0.1.tgz#643a92caf894566f91b2b986d2c66950a8e2fb87" + dependencies: + node-modules-regexp "^1.0.0" + +pkg-dir@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/pkg-dir/-/pkg-dir-3.0.0.tgz#2749020f239ed990881b1f71210d51eb6523bea3" + dependencies: + find-up "^3.0.0" plugin-error@^1.0.0, plugin-error@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/plugin-error/-/plugin-error-1.0.1.tgz#77016bd8919d0ac377fdcdd0322328953ca5781c" - integrity sha512-L1zP0dk7vGweZME2i+EeakvUNqSrdiI3F91TwEoYiGrAfUXmVv6fJIq4g82PAXxNsWOp0J7ZqQy/3Szz0ajTxA== dependencies: ansi-colors "^1.0.1" arr-diff "^4.0.0" @@ -3820,65 +3389,53 @@ plugin-error@^1.0.0, plugin-error@^1.0.1: plur@^2.1.0: version "2.1.2" - resolved "https://registry.yarnpkg.com/plur/-/plur-2.1.2.tgz#7482452c1a0f508e3e344eaec312c91c29dc655a" - integrity sha1-dIJFLBoPUI4+NE6uwxLJHCncZVo= + resolved "https://registry.npmjs.org/plur/-/plur-2.1.2.tgz#7482452c1a0f508e3e344eaec312c91c29dc655a" dependencies: irregular-plurals "^1.0.0" pluralize@^7.0.0: version "7.0.0" resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-7.0.0.tgz#298b89df8b93b0221dbf421ad2b1b1ea23fc6777" - integrity sha512-ARhBOdzS3e41FbkW/XWrTEtukqqLoK5+Z/4UeDaLuSW+39JPeFgs4gCGqsrJHVZX0fUrx//4OF0K1CUGwlIFow== posix-character-classes@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/posix-character-classes/-/posix-character-classes-0.1.1.tgz#01eac0fe3b5af71a2a6c02feabb8c1fef7e00eab" - integrity sha1-AerA/jta9xoqbAL+q7jB/vfgDqs= prelude-ls@~1.1.0, prelude-ls@~1.1.1, prelude-ls@~1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54" - integrity sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ= pretty-hrtime@^1.0.0: version "1.0.3" resolved "https://registry.yarnpkg.com/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz#b7e3ea42435a4c9b2759d99e0f201eb195802ee1" - integrity sha1-t+PqQkNaTJsnWdmeDyAesZWALuE= private@^0.1.6: version "0.1.8" resolved "https://registry.yarnpkg.com/private/-/private-0.1.8.tgz#2381edb3689f7a53d653190060fcf822d2f368ff" - integrity sha512-VvivMrbvd2nKkiG38qjULzlc+4Vx4wm/whI9pQD35YrARNnhxeiRktSOhSukRLFNlzg6Br/cJPet5J/u19r/mg== process-nextick-args@^2.0.0, process-nextick-args@~2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2" - integrity sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag== process-nextick-args@~1.0.6: version "1.0.7" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-1.0.7.tgz#150e20b756590ad3f91093f25a4f2ad8bff30ba3" - integrity sha1-FQ4gt1ZZCtP5EJPyWk8q2L/zC6M= progress@^2.0.0: version "2.0.3" resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.3.tgz#7e8cf8d8f5b8f239c1bc68beb4eb78567d572ef8" - integrity sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA== propagate@0.3.x: version "0.3.1" resolved "https://registry.yarnpkg.com/propagate/-/propagate-0.3.1.tgz#e3a84404a7ece820dd6bbea9f6d924e3135ae09c" - integrity sha1-46hEBKfs6CDda76p9tkk4xNa4Jw= pseudomap@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3" - integrity sha1-8FKijacOYYkX7wqKw0wa5aaChrM= pump@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/pump/-/pump-2.0.1.tgz#12399add6e4cf7526d973cbc8b5ce2e2908b3909" - integrity sha512-ruPMNRkN3MHP1cWJc9OWr+T/xDP0jhXYCLfJcBuX54hhfIBnaQmAUMfDcG4DM5UMWByBbJY69QSphm3jtDKIkA== dependencies: end-of-stream "^1.1.0" once "^1.3.1" @@ -3886,7 +3443,6 @@ pump@^2.0.0: pumpify@^1.3.5: version "1.5.1" resolved "https://registry.yarnpkg.com/pumpify/-/pumpify-1.5.1.tgz#36513be246ab27570b1a374a5ce278bfd74370ce" - integrity sha512-oClZI37HvuUJJxSKKrC17bZ9Cu0ZYhEAGPsPUy9KlMUmv9dKX2o77RUmq7f3XjIxbwyGwYzbzQ1L2Ks8sIradQ== dependencies: duplexify "^3.6.0" inherits "^2.0.3" @@ -3895,17 +3451,14 @@ pumpify@^1.3.5: punycode@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" - integrity sha1-wNWmOycYgArY4esPpSachN1BhF4= qs@^6.0.2, qs@~6.5.1: version "6.5.1" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8" - integrity sha512-eRzhrN1WSINYCDCbrz796z37LOe3m5tmW7RQf6oBntukAG1nmovJvhnwHHRMAfeoItc1m2Hk02WER2aQ/iqs+A== rc@^1.2.7: version "1.2.8" resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.8.tgz#cd924bf5200a075b83c188cd6b9e211b7fc0d3ed" - integrity sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw== dependencies: deep-extend "^0.6.0" ini "~1.3.0" @@ -3915,7 +3468,6 @@ rc@^1.2.7: read-pkg-up@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-1.0.1.tgz#9d63c13276c065918d57f002a57f40a1b643fb02" - integrity sha1-nWPBMnbAZZGNV/ACpX9AobZD+wI= dependencies: find-up "^1.0.0" read-pkg "^1.0.0" @@ -3923,7 +3475,6 @@ read-pkg-up@^1.0.1: read-pkg@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-1.1.0.tgz#f5ffaa5ecd29cb31c0474bca7d756b6bb29e3f28" - integrity sha1-9f+qXs0pyzHAR0vKfXVra7KePyg= dependencies: load-json-file "^1.0.0" normalize-package-data "^2.3.2" @@ -3932,7 +3483,6 @@ read-pkg@^1.0.0: readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.5, readable-stream@^2.0.6, readable-stream@^2.3.3, readable-stream@^2.3.5, readable-stream@^2.3.6, readable-stream@~2.3.6: version "2.3.6" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.6.tgz#b11c27d88b8ff1fbe070643cf94b0c79ae1b0aaf" - integrity sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw== dependencies: core-util-is "~1.0.0" inherits "~2.0.3" @@ -3945,7 +3495,6 @@ readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable readable-stream@^2.1.5, readable-stream@^2.2.2: version "2.3.3" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.3.tgz#368f2512d79f9d46fdfc71349ae7878bbc1eb95c" - integrity sha512-m+qzzcn7KUxEmd1gMbchF+Y2eIUbieUaxkWtptyHywrX0rE8QEYqPC07Vuy4Wm32/xE16NcdBctb8S0Xe/5IeQ== dependencies: core-util-is "~1.0.0" inherits "~2.0.3" @@ -3958,7 +3507,6 @@ readable-stream@^2.1.5, readable-stream@^2.2.2: readable-stream@~1.1.9: version "1.1.14" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.1.14.tgz#7cf4c54ef648e3813084c636dd2079e166c081d9" - integrity sha1-fPTFTvZI44EwhMY23SB54WbAgdk= dependencies: core-util-is "~1.0.0" inherits "~2.0.1" @@ -3968,7 +3516,6 @@ readable-stream@~1.1.9: readdirp@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-2.2.1.tgz#0e87622a3325aa33e892285caf8b4e846529a525" - integrity sha512-1JU/8q+VgFZyxwrJ+SVIOsh+KywWGpds3NTqikiKpDMZWScmAYyKIgqkO+ARvNWJfXeXR1zxz7aHF4u4CyH6vQ== dependencies: graceful-fs "^4.1.11" micromatch "^3.1.10" @@ -3977,33 +3524,28 @@ readdirp@^2.2.1: rechoir@^0.6.2: version "0.6.2" resolved "https://registry.yarnpkg.com/rechoir/-/rechoir-0.6.2.tgz#85204b54dba82d5742e28c96756ef43af50e3384" - integrity sha1-hSBLVNuoLVdC4oyWdW70OvUOM4Q= dependencies: resolve "^1.1.6" regenerate-unicode-properties@^8.0.2: version "8.1.0" resolved "https://registry.yarnpkg.com/regenerate-unicode-properties/-/regenerate-unicode-properties-8.1.0.tgz#ef51e0f0ea4ad424b77bf7cb41f3e015c70a3f0e" - integrity sha512-LGZzkgtLY79GeXLm8Dp0BVLdQlWICzBnJz/ipWUgo59qBaZ+BHtq51P2q1uVZlppMuUAT37SDk39qUbjTWB7bA== dependencies: regenerate "^1.4.0" regenerate@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.4.0.tgz#4a856ec4b56e4077c557589cae85e7a4c8869a11" - integrity sha512-1G6jJVDWrt0rK99kBjvEtziZNCICAuvIPkSiUFIQxVP06RCVpq3dmDo2oi6ABpYaDYaTRr67BEhL8r1wgEZZKg== regenerator-transform@^0.14.0: version "0.14.0" resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.14.0.tgz#2ca9aaf7a2c239dd32e4761218425b8c7a86ecaf" - integrity sha512-rtOelq4Cawlbmq9xuMR5gdFmv7ku/sFoB7sRiywx7aq53bc52b4j6zvH7Te1Vt/X2YveDKnCGUbioieU7FEL3w== dependencies: private "^0.1.6" regex-not@^1.0.0, regex-not@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/regex-not/-/regex-not-1.0.2.tgz#1f4ece27e00b0b65e0247a6810e6a85d83a5752c" - integrity sha512-J6SDjUgDxQj5NusnOtdFxDwN/+HWykR8GELwctJ7mdqhcyy1xEc4SRFHUXvxTp661YaVKAjfRLZ9cCqS6tn32A== dependencies: extend-shallow "^3.0.2" safe-regex "^1.1.0" @@ -4011,17 +3553,14 @@ regex-not@^1.0.0, regex-not@^1.0.2: regexp-tree@^0.1.6: version "0.1.10" resolved "https://registry.yarnpkg.com/regexp-tree/-/regexp-tree-0.1.10.tgz#d837816a039c7af8a8d64d7a7c3cf6a1d93450bc" - integrity sha512-K1qVSbcedffwuIslMwpe6vGlj+ZXRnGkvjAtFHfDZZZuEdA/h0dxljAPu9vhUo6Rrx2U2AwJ+nSQ6hK+lrP5MQ== regexpp@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-1.1.0.tgz#0e3516dd0b7904f413d2d4193dce4618c3a689ab" - integrity sha512-LOPw8FpgdQF9etWMaAfG/WRthIdXJGYp4mJ2Jgn/2lpkbod9jPn0t9UqN7AxBOKNfzRbYyVfgc7Vk4t/MpnXgw== regexpu-core@^4.5.4: version "4.5.4" resolved "https://registry.yarnpkg.com/regexpu-core/-/regexpu-core-4.5.4.tgz#080d9d02289aa87fe1667a4f5136bc98a6aebaae" - integrity sha512-BtizvGtFQKGPUcTy56o3nk1bGRp4SZOTYrDtGNlqCQufptV5IkkLN6Emw+yunAJjzf+C9FQFtvq7IoA3+oMYHQ== dependencies: regenerate "^1.4.0" regenerate-unicode-properties "^8.0.2" @@ -4033,19 +3572,16 @@ regexpu-core@^4.5.4: regjsgen@^0.5.0: version "0.5.0" resolved "https://registry.yarnpkg.com/regjsgen/-/regjsgen-0.5.0.tgz#a7634dc08f89209c2049adda3525711fb97265dd" - integrity sha512-RnIrLhrXCX5ow/E5/Mh2O4e/oa1/jW0eaBKTSy3LaCj+M3Bqvm97GWDp2yUtzIs4LEn65zR2yiYGFqb2ApnzDA== regjsparser@^0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/regjsparser/-/regjsparser-0.6.0.tgz#f1e6ae8b7da2bae96c99399b868cd6c933a2ba9c" - integrity sha512-RQ7YyokLiQBomUJuUG8iGVvkgOLxwyZM8k6d3q5SAXpg4r5TZJZigKFvC6PpD+qQ98bCDC5YelPeA3EucDoNeQ== dependencies: jsesc "~0.5.0" remove-bom-buffer@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/remove-bom-buffer/-/remove-bom-buffer-3.0.0.tgz#c2bf1e377520d324f623892e33c10cac2c252b53" - integrity sha512-8v2rWhaakv18qcvNeli2mZ/TMTL2nEyAKRvzo1WtnZBl15SHyEhrCu2/xKlJyUFKHiHgfXIyuY6g2dObJJycXQ== dependencies: is-buffer "^1.1.5" is-utf8 "^0.2.1" @@ -4053,7 +3589,6 @@ remove-bom-buffer@^3.0.0: remove-bom-stream@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/remove-bom-stream/-/remove-bom-stream-1.2.0.tgz#05f1a593f16e42e1fb90ebf59de8e569525f9523" - integrity sha1-BfGlk/FuQuH7kOv1nejlaVJflSM= dependencies: remove-bom-buffer "^3.0.0" safe-buffer "^5.1.0" @@ -4062,32 +3597,26 @@ remove-bom-stream@^1.2.0: remove-trailing-separator@^1.0.1, remove-trailing-separator@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz#c24bce2a283adad5bc3f58e0d48249b92379d8ef" - integrity sha1-wkvOKig62tW8P1jg1IJJuSN52O8= repeat-element@^1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/repeat-element/-/repeat-element-1.1.2.tgz#ef089a178d1483baae4d93eb98b4f9e4e11d990a" - integrity sha1-7wiaF40Ug7quTZPrmLT55OEdmQo= repeat-string@^1.6.1: version "1.6.1" resolved "https://registry.yarnpkg.com/repeat-string/-/repeat-string-1.6.1.tgz#8dcae470e1c88abc2d600fff4a776286da75e637" - integrity sha1-jcrkcOHIirwtYA//Sndihtp15jc= replace-ext@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/replace-ext/-/replace-ext-0.0.1.tgz#29bbd92078a739f0bcce2b4ee41e837953522924" - integrity sha1-KbvZIHinOfC8zitO5B6DeVNSKSQ= replace-ext@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/replace-ext/-/replace-ext-1.0.0.tgz#de63128373fcbf7c3ccfa4de5a480c45a67958eb" - integrity sha1-3mMSg3P8v3w8z6TeWkgMRaZ5WOs= replace-homedir@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/replace-homedir/-/replace-homedir-1.0.0.tgz#e87f6d513b928dde808260c12be7fec6ff6e798c" - integrity sha1-6H9tUTuSjd6AgmDBK+f+xv9ueYw= dependencies: homedir-polyfill "^1.0.1" is-absolute "^1.0.0" @@ -4096,7 +3625,6 @@ replace-homedir@^1.0.0: request@^2.83.0: version "2.83.0" resolved "https://registry.yarnpkg.com/request/-/request-2.83.0.tgz#ca0b65da02ed62935887808e6f510381034e3356" - integrity sha512-lR3gD69osqm6EYLk9wB/G1W/laGWjzH90t1vEa2xuxHD5KUrSzp9pUSfTm+YC5Nxt2T8nMPEvKlhbQayU7bgFw== dependencies: aws-sign2 "~0.7.0" aws4 "^1.6.0" @@ -4124,17 +3652,14 @@ request@^2.83.0: require-directory@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" - integrity sha1-jGStX9MNqxyXbiNE/+f3kqam30I= require-main-filename@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-1.0.1.tgz#97f717b69d48784f5f526a6c5aa8ffdda055a4d1" - integrity sha1-l/cXtp1IeE9fUmpsWqj/3aBVpNE= require-uncached@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/require-uncached/-/require-uncached-1.0.3.tgz#4e0d56d6c9662fd31e43011c4b95aa49955421d3" - integrity sha1-Tg1W1slmL9MeQwEcS5WqSZVUIdM= dependencies: caller-path "^0.1.0" resolve-from "^1.0.0" @@ -4142,7 +3667,6 @@ require-uncached@^1.0.3: resolve-dir@^1.0.0, resolve-dir@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/resolve-dir/-/resolve-dir-1.0.1.tgz#79a40644c362be82f26effe739c9bb5382046f43" - integrity sha1-eaQGRMNivoLybv/nOcm7U4IEb0M= dependencies: expand-tilde "^2.0.0" global-modules "^1.0.0" @@ -4150,43 +3674,36 @@ resolve-dir@^1.0.0, resolve-dir@^1.0.1: resolve-from@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-1.0.1.tgz#26cbfe935d1aeeeabb29bc3fe5aeb01e93d44226" - integrity sha1-Jsv+k10a7uq7Kbw/5a6wHpPUQiY= resolve-options@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/resolve-options/-/resolve-options-1.1.0.tgz#32bb9e39c06d67338dc9378c0d6d6074566ad131" - integrity sha1-MrueOcBtZzONyTeMDW1gdFZq0TE= dependencies: value-or-function "^3.0.0" resolve-url@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" - integrity sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo= resolve@1.1.x: version "1.1.7" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.1.7.tgz#203114d82ad2c5ed9e8e0411b3932875e889e97b" - integrity sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs= resolve@^1.1.6, resolve@^1.1.7: version "1.7.1" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.7.1.tgz#aadd656374fd298aee895bc026b8297418677fd3" - integrity sha512-c7rwLofp8g1U+h1KNyHL/jicrKg1Ek4q+Lr33AL65uZTinUZHe30D5HlyN5V9NW0JX1D5dXQ4jqW5l7Sy/kGfw== dependencies: path-parse "^1.0.5" resolve@^1.10.0, resolve@^1.3.2, resolve@^1.4.0: version "1.11.1" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.11.1.tgz#ea10d8110376982fef578df8fc30b9ac30a07a3e" - integrity sha512-vIpgF6wfuJOZI7KKKSP+HmiKggadPQAdsp5HiC1mvqnfp0gF1vdwgBWZIdrVft9pgqoMFQN+R7BSWZiBxx+BBw== dependencies: path-parse "^1.0.6" restore-cursor@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-2.0.0.tgz#9f7ee287f82fd326d4fd162923d62129eee0dfaf" - integrity sha1-n37ih/gv0ybU/RYpI9YhKe7g368= dependencies: onetime "^2.0.0" signal-exit "^3.0.2" @@ -4194,92 +3711,76 @@ restore-cursor@^2.0.0: ret@~0.1.10: version "0.1.15" resolved "https://registry.yarnpkg.com/ret/-/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc" - integrity sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg== rimraf@^2.6.1, rimraf@~2.6.2: version "2.6.3" resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.3.tgz#b2d104fe0d8fb27cf9e0a1cda8262dd3833c6cab" - integrity sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA== dependencies: glob "^7.1.3" rimraf@~2.2.6: version "2.2.8" - resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.2.8.tgz#e439be2aaee327321952730f99a8929e4fc50582" - integrity sha1-5Dm+Kq7jJzIZUnMPmaiSnk/FBYI= + resolved "https://registry.npmjs.org/rimraf/-/rimraf-2.2.8.tgz#e439be2aaee327321952730f99a8929e4fc50582" run-async@^2.2.0: version "2.3.0" resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.3.0.tgz#0371ab4ae0bdd720d4166d7dfda64ff7a445a6c0" - integrity sha1-A3GrSuC91yDUFm19/aZP96RFpsA= dependencies: is-promise "^2.1.0" rx-lite-aggregates@^4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/rx-lite-aggregates/-/rx-lite-aggregates-4.0.8.tgz#753b87a89a11c95467c4ac1626c4efc4e05c67be" - integrity sha1-dTuHqJoRyVRnxKwWJsTvxOBcZ74= dependencies: rx-lite "*" rx-lite@*, rx-lite@^4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-4.0.8.tgz#0b1e11af8bc44836f04a6407e92da42467b79444" - integrity sha1-Cx4Rr4vESDbwSmQH6S2kJGe3lEQ= safe-buffer@^5.0.1, safe-buffer@^5.1.1, safe-buffer@~5.1.0, safe-buffer@~5.1.1: version "5.1.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.1.tgz#893312af69b2123def71f57889001671eeb2c853" - integrity sha512-kKvNJn6Mm93gAczWVJg7wH+wGYWNrDHdWvpUmHyEsgCtIwwo3bqPtV4tR5tuPaUhTOo/kvhVwd8XwwOllGYkbg== safe-buffer@^5.1.0, safe-buffer@^5.1.2: version "5.1.2" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" - integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== safe-regex@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/safe-regex/-/safe-regex-1.1.0.tgz#40a3669f3b077d1e943d44629e157dd48023bf2e" - integrity sha1-QKNmnzsHfR6UPURinhV91IAjvy4= dependencies: ret "~0.1.10" "safer-buffer@>= 2.1.2 < 3", safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" - integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== sax@^1.2.4: version "1.2.4" resolved "https://registry.yarnpkg.com/sax/-/sax-1.2.4.tgz#2816234e2378bddc4e5354fab5caa895df7100d9" - integrity sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw== semver-greatest-satisfied-range@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/semver-greatest-satisfied-range/-/semver-greatest-satisfied-range-1.1.0.tgz#13e8c2658ab9691cb0cd71093240280d36f77a5b" - integrity sha1-E+jCZYq5aRywzXEJMkAoDTb3els= dependencies: sver-compat "^1.5.0" -"semver@2 || 3 || 4 || 5", semver@^5.3.0, semver@^5.4.1, semver@^5.5.0: +"semver@2 || 3 || 4 || 5", semver@^5.3.0, semver@^5.4.1, semver@^5.5.0, semver@^5.6.0: version "5.7.0" resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.0.tgz#790a7cf6fea5459bac96110b29b60412dc8ff96b" - integrity sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA== semver@^6.1.1: version "6.2.0" resolved "https://registry.yarnpkg.com/semver/-/semver-6.2.0.tgz#4d813d9590aaf8a9192693d6c85b9344de5901db" - integrity sha512-jdFC1VdUGT/2Scgbimf7FSx9iJLXoqfglSF+gJeuNWVpiE37OIbc1jywR/GJyFdz3mnkz2/id0L0J/cr0izR5A== set-blocking@^2.0.0, set-blocking@~2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" - integrity sha1-BF+XgtARrppoA93TgrJDkrPYkPc= set-value@^0.4.3: version "0.4.3" resolved "https://registry.yarnpkg.com/set-value/-/set-value-0.4.3.tgz#7db08f9d3d22dc7f78e53af3c3bf4666ecdfccf1" - integrity sha1-fbCPnT0i3H945Trzw79GZuzfzPE= dependencies: extend-shallow "^2.0.1" is-extendable "^0.1.1" @@ -4289,7 +3790,6 @@ set-value@^0.4.3: set-value@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/set-value/-/set-value-2.0.0.tgz#71ae4a88f0feefbbf52d1ea604f3fb315ebb6274" - integrity sha512-hw0yxk9GT/Hr5yJEYnHNKYXkIA8mVJgd9ditYZCe16ZczcaELYYcfvaXesNACk2O8O0nTiPQcQhGUQj8JLzeeg== dependencies: extend-shallow "^2.0.1" is-extendable "^0.1.1" @@ -4299,29 +3799,24 @@ set-value@^2.0.0: shebang-command@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea" - integrity sha1-RKrGW2lbAzmJaMOfNj/uXer98eo= dependencies: shebang-regex "^1.0.0" shebang-regex@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3" - integrity sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM= sigmund@~1.0.0: version "1.0.1" - resolved "https://registry.yarnpkg.com/sigmund/-/sigmund-1.0.1.tgz#3ff21f198cad2175f9f3b781853fd94d0d19b590" - integrity sha1-P/IfGYytIXX587eBhT/ZTQ0ZtZA= + resolved "https://registry.npmjs.org/sigmund/-/sigmund-1.0.1.tgz#3ff21f198cad2175f9f3b781853fd94d0d19b590" signal-exit@^3.0.0, signal-exit@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d" - integrity sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0= sinon@^6.1.4: version "6.3.5" resolved "https://registry.yarnpkg.com/sinon/-/sinon-6.3.5.tgz#0f6d6a5b4ebaad1f6e8e019395542d1d02c144a0" - integrity sha512-xgoZ2gKjyVRcF08RrIQc+srnSyY1JDJtxu3Nsz07j1ffjgXoY6uPLf/qja6nDBZgzYYEovVkFryw2+KiZz11xQ== dependencies: "@sinonjs/commons" "^1.0.2" "@sinonjs/formatio" "^3.0.0" @@ -4336,14 +3831,12 @@ sinon@^6.1.4: slice-ansi@1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-1.0.0.tgz#044f1a49d8842ff307aad6b505ed178bd950134d" - integrity sha512-POqxBK6Lb3q6s047D/XsDVNPnF9Dl8JSaqe9h9lURl0OdNqy/ujDrOiIHtsqXMGbWWTIomRzAMaTyawAU//Reg== dependencies: is-fullwidth-code-point "^2.0.0" snapdragon-node@^2.0.1: version "2.1.1" resolved "https://registry.yarnpkg.com/snapdragon-node/-/snapdragon-node-2.1.1.tgz#6c175f86ff14bdb0724563e8f3c1b021a286853b" - integrity sha512-O27l4xaMYt/RSQ5TR3vpWCAB5Kb/czIcqUFOM/C4fYcLnbZUc1PkjTAMjof2pBWaSTwOUd6qUHcFGVGj7aIwnw== dependencies: define-property "^1.0.0" isobject "^3.0.0" @@ -4352,14 +3845,12 @@ snapdragon-node@^2.0.1: snapdragon-util@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/snapdragon-util/-/snapdragon-util-3.0.1.tgz#f956479486f2acd79700693f6f7b805e45ab56e2" - integrity sha512-mbKkMdQKsjX4BAL4bRYTj21edOf8cN7XHdYUJEe+Zn99hVEYcMvKPct1IqNe7+AZPirn8BCDOQBHQZknqmKlZQ== dependencies: kind-of "^3.2.0" snapdragon@^0.8.1: version "0.8.2" resolved "https://registry.yarnpkg.com/snapdragon/-/snapdragon-0.8.2.tgz#64922e7c565b0e14204ba1aa7d6964278d25182d" - integrity sha512-FtyOnWN/wCHTVXOMwvSv26d+ko5vWlIDD6zoUJ7LW8vh+ZBC8QdljveRP+crNrtBwioEUWy/4dMtbBjA4ioNlg== dependencies: base "^0.11.1" debug "^2.2.0" @@ -4373,14 +3864,12 @@ snapdragon@^0.8.1: sntp@2.x.x: version "2.0.2" resolved "https://registry.yarnpkg.com/sntp/-/sntp-2.0.2.tgz#5064110f0af85f7cfdb7d6b67a40028ce52b4b2b" - integrity sha1-UGQRDwr4X3z9t9a2ekACjOUrSys= dependencies: hoek "4.x.x" source-map-resolve@^0.5.0: version "0.5.1" resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.1.tgz#7ad0f593f2281598e854df80f19aae4b92d7a11a" - integrity sha512-0KW2wvzfxm8NCTb30z0LMNyPqWCdDGE2viwzUaucqJdkTRXtZiSY3I+2A6nVAjmdOy0I4gU8DwnVVGsk9jvP2A== dependencies: atob "^2.0.0" decode-uri-component "^0.2.0" @@ -4388,37 +3877,38 @@ source-map-resolve@^0.5.0: source-map-url "^0.4.0" urix "^0.1.0" +source-map-support@^0.5.9: + version "0.5.12" + resolved "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.12.tgz#b4f3b10d51857a5af0138d3ce8003b201613d599" + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + source-map-url@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.0.tgz#3e935d7ddd73631b97659956d55128e87b5084a3" - integrity sha1-PpNdfd1zYxuXZZlW1VEo6HtQhKM= source-map@^0.5.0, source-map@^0.5.1, source-map@^0.5.6: version "0.5.7" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" - integrity sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w= -source-map@^0.6.1, source-map@~0.6.1: +source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" - integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== source-map@~0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.2.0.tgz#dab73fbcfc2ba819b4de03bd6f6eaa48164b3f9d" - integrity sha1-2rc/vPwrqBm03gO9b26qSBZLP50= dependencies: amdefine ">=0.0.4" sparkles@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/sparkles/-/sparkles-1.0.0.tgz#1acbbfb592436d10bbe8f785b7cc6f82815012c3" - integrity sha1-Gsu/tZJDbRC76PeFt8xvgoFQEsM= spdx-correct@^3.0.0: version "3.1.0" resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.1.0.tgz#fb83e504445268f154b074e218c87c003cd31df4" - integrity sha512-lr2EZCctC2BNR7j7WzJ2FpDznxky1sjfxvvYEyzxNyb6lZXHODmEoJeFu4JupYlkfha1KZpJyoqiJ7pgA1qq8Q== dependencies: spdx-expression-parse "^3.0.0" spdx-license-ids "^3.0.0" @@ -4426,12 +3916,10 @@ spdx-correct@^3.0.0: spdx-exceptions@^2.1.0: version "2.2.0" resolved "https://registry.yarnpkg.com/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz#2ea450aee74f2a89bfb94519c07fcd6f41322977" - integrity sha512-2XQACfElKi9SlVb1CYadKDXvoajPgBVPn/gOQLrTvHdElaVhr7ZEbqJaRnJLVNeaI4cMEAgVCeBMKF6MWRDCRA== spdx-expression-parse@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz#99e119b7a5da00e05491c9fa338b7904823b41d0" - integrity sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg== dependencies: spdx-exceptions "^2.1.0" spdx-license-ids "^3.0.0" @@ -4439,24 +3927,20 @@ spdx-expression-parse@^3.0.0: spdx-license-ids@^3.0.0: version "3.0.4" resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.4.tgz#75ecd1a88de8c184ef015eafb51b5b48bfd11bb1" - integrity sha512-7j8LYJLeY/Yb6ACbQ7F76qy5jHkp0U6jgBfJsk97bwWlVUnUWsAgpyaCvo17h0/RQGnQ036tVDomiwoI4pDkQA== split-string@^3.0.1, split-string@^3.0.2: version "3.1.0" resolved "https://registry.yarnpkg.com/split-string/-/split-string-3.1.0.tgz#7cb09dda3a86585705c64b39a6466038682e8fe2" - integrity sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw== dependencies: extend-shallow "^3.0.0" sprintf-js@~1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" - integrity sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw= sshpk@^1.7.0: version "1.16.1" resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.16.1.tgz#fb661c0bef29b39db40769ee39fa70093d6f6877" - integrity sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg== dependencies: asn1 "~0.2.3" assert-plus "^1.0.0" @@ -4471,12 +3955,10 @@ sshpk@^1.7.0: stack-trace@0.0.10: version "0.0.10" resolved "https://registry.yarnpkg.com/stack-trace/-/stack-trace-0.0.10.tgz#547c70b347e8d32b4e108ea1a2a159e5fdde19c0" - integrity sha1-VHxws0fo0ytOEI6hoqFZ5f3eGcA= static-extend@^0.1.1: version "0.1.2" resolved "https://registry.yarnpkg.com/static-extend/-/static-extend-0.1.2.tgz#60809c39cbff55337226fd5e0b520f341f1fb5c6" - integrity sha1-YICcOcv/VTNyJv1eC1IPNB8ftcY= dependencies: define-property "^0.2.5" object-copy "^0.1.0" @@ -4484,17 +3966,14 @@ static-extend@^0.1.1: stream-exhaust@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/stream-exhaust/-/stream-exhaust-1.0.2.tgz#acdac8da59ef2bc1e17a2c0ccf6c320d120e555d" - integrity sha512-b/qaq/GlBK5xaq1yrK9/zFcyRSTNxmcZwFLGSTG0mXgZl/4Z6GgiyYOXOvY7N3eEvFRAG1bkDRz5EPGSvPYQlw== stream-shift@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/stream-shift/-/stream-shift-1.0.0.tgz#d5c752825e5367e786f78e18e445ea223a155952" - integrity sha1-1cdSgl5TZ+eG944Y5EXqIjoVWVI= string-width@^1.0.1, string-width@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/string-width/-/string-width-1.0.2.tgz#118bdf5b8cdc51a2a7e70d211e07e2b0b9b107d3" - integrity sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M= dependencies: code-point-at "^1.0.0" is-fullwidth-code-point "^1.0.0" @@ -4503,7 +3982,6 @@ string-width@^1.0.1, string-width@^1.0.2: "string-width@^1.0.2 || 2", string-width@^2.1.0, string-width@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/string-width/-/string-width-2.1.1.tgz#ab93f27a8dc13d28cac815c462143a6d9012ae9e" - integrity sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw== dependencies: is-fullwidth-code-point "^2.0.0" strip-ansi "^4.0.0" @@ -4511,81 +3989,68 @@ string-width@^1.0.1, string-width@^1.0.2: string_decoder@~0.10.x: version "0.10.31" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94" - integrity sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ= string_decoder@~1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.0.3.tgz#0fc67d7c141825de94282dd536bec6b9bce860ab" - integrity sha512-4AH6Z5fzNNBcH+6XDMfA/BTt87skxqJlO0lAh3Dker5zThcAxG6mKz+iGu308UKoPPQ8Dcqx/4JhujzltRa+hQ== dependencies: safe-buffer "~5.1.0" string_decoder@~1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.1.1.tgz#9cf1611ba62685d7030ae9e4ba34149c3af03fc8" - integrity sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg== dependencies: safe-buffer "~5.1.0" stringstream@~0.0.5: version "0.0.6" resolved "https://registry.yarnpkg.com/stringstream/-/stringstream-0.0.6.tgz#7880225b0d4ad10e30927d167a1d6f2fd3b33a72" - integrity sha512-87GEBAkegbBcweToUrdzf3eLhWNg06FJTebl4BVJz/JgWy8CvEr9dRtX5qWphiynMSQlxxi+QqN0z5T32SLlhA== strip-ansi@^3.0.0, strip-ansi@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf" - integrity sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8= dependencies: ansi-regex "^2.0.0" strip-ansi@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-4.0.0.tgz#a8479022eb1ac368a871389b635262c505ee368f" - integrity sha1-qEeQIusaw2iocTibY1JixQXuNo8= dependencies: ansi-regex "^3.0.0" strip-bom@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-2.0.0.tgz#6219a85616520491f35788bdbf1447a99c7e6b0e" - integrity sha1-YhmoVhZSBJHzV4i9vxRHqZx+aw4= dependencies: is-utf8 "^0.2.0" strip-json-comments@~2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" - integrity sha1-PFMZQukIwml8DsNEhYwobHygpgo= supports-color@1.2.0: version "1.2.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-1.2.0.tgz#ff1ed1e61169d06b3cf2d588e188b18d8847e17e" - integrity sha1-/x7R5hFp0Gs88tWI4YixjYhH4X4= + resolved "https://registry.npmjs.org/supports-color/-/supports-color-1.2.0.tgz#ff1ed1e61169d06b3cf2d588e188b18d8847e17e" supports-color@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7" - integrity sha1-U10EXOa2Nj+kARcIRimZXp3zJMc= supports-color@^3.1.0: version "3.2.3" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-3.2.3.tgz#65ac0504b3954171d8a64946b2ae3cbb8a5f54f6" - integrity sha1-ZawFBLOVQXHYpklGsq48u4pfVPY= dependencies: has-flag "^1.0.0" supports-color@^5.3.0, supports-color@^5.5.0: version "5.5.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" - integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== dependencies: has-flag "^3.0.0" sver-compat@^1.5.0: version "1.5.0" resolved "https://registry.yarnpkg.com/sver-compat/-/sver-compat-1.5.0.tgz#3cf87dfeb4d07b4a3f14827bc186b3fd0c645cd8" - integrity sha1-PPh9/rTQe0o/FIJ7wYaz/QxkXNg= dependencies: es6-iterator "^2.0.1" es6-symbol "^3.1.1" @@ -4593,7 +4058,6 @@ sver-compat@^1.5.0: table@4.0.2: version "4.0.2" resolved "https://registry.yarnpkg.com/table/-/table-4.0.2.tgz#a33447375391e766ad34d3486e6e2aedc84d2e36" - integrity sha512-UUkEAPdSGxtRpiV9ozJ5cMTtYiqz7Ni1OGqLXRCynrvzdtR1p+cfOWe2RJLwvUG8hNanaSRjecIqwOjqeatDsA== dependencies: ajv "^5.2.3" ajv-keywords "^2.1.0" @@ -4605,7 +4069,6 @@ table@4.0.2: tar@^4: version "4.4.10" resolved "https://registry.yarnpkg.com/tar/-/tar-4.4.10.tgz#946b2810b9a5e0b26140cf78bea6b0b0d689eba1" - integrity sha512-g2SVs5QIxvo6OLp0GudTqEf05maawKUxXru104iaayWA09551tFCTI8f1Asb4lPfkBr91k07iL4c11XO3/b0tA== dependencies: chownr "^1.1.1" fs-minipass "^1.2.5" @@ -4617,8 +4080,7 @@ tar@^4: temp@^0.8.3: version "0.8.3" - resolved "https://registry.yarnpkg.com/temp/-/temp-0.8.3.tgz#e0c6bc4d26b903124410e4fed81103014dfc1f59" - integrity sha1-4Ma8TSa5AxJEEOT+2BEDAU38H1k= + resolved "https://registry.npmjs.org/temp/-/temp-0.8.3.tgz#e0c6bc4d26b903124410e4fed81103014dfc1f59" dependencies: os-tmpdir "^1.0.0" rimraf "~2.2.6" @@ -4626,17 +4088,14 @@ temp@^0.8.3: text-encoding@^0.6.4: version "0.6.4" resolved "https://registry.yarnpkg.com/text-encoding/-/text-encoding-0.6.4.tgz#e399a982257a276dae428bb92845cb71bdc26d19" - integrity sha1-45mpgiV6J22uQou5KEXLcb3CbRk= text-table@~0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" - integrity sha1-f17oI66AUgfACvLfSoTsP8+lcLQ= through2-filter@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/through2-filter/-/through2-filter-3.0.0.tgz#700e786df2367c2c88cd8aa5be4cf9c1e7831254" - integrity sha512-jaRjI2WxN3W1V8/FMZ9HKIBXixtiqs3SQSX4/YGIiP3gL6djW48VoZq9tDqeCWs3MT8YY5wb/zli8VW8snY1CA== dependencies: through2 "~2.0.0" xtend "~4.0.0" @@ -4644,7 +4103,6 @@ through2-filter@^3.0.0: through2@^2, through2@^2.0.0, through2@^2.0.1: version "2.0.3" resolved "https://registry.yarnpkg.com/through2/-/through2-2.0.3.tgz#0004569b37c7c74ba39c43f3ced78d1ad94140be" - integrity sha1-AARWmzfHx0ujnEPzzteNGtlBQL4= dependencies: readable-stream "^2.1.5" xtend "~4.0.1" @@ -4652,7 +4110,6 @@ through2@^2, through2@^2.0.0, through2@^2.0.1: through2@^2.0.3, through2@~2.0.0: version "2.0.5" resolved "https://registry.yarnpkg.com/through2/-/through2-2.0.5.tgz#01c1e39eb31d07cb7d03a96a70823260b23132cd" - integrity sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ== dependencies: readable-stream "~2.3.6" xtend "~4.0.1" @@ -4660,24 +4117,20 @@ through2@^2.0.3, through2@~2.0.0: through@^2.3.4, through@^2.3.6: version "2.3.8" resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" - integrity sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU= time-stamp@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/time-stamp/-/time-stamp-1.1.0.tgz#764a5a11af50561921b133f3b44e618687e0f5c3" - integrity sha1-dkpaEa9QVhkhsTPztE5hhofg9cM= tmp@^0.0.33: version "0.0.33" resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.0.33.tgz#6d34335889768d21b2bcda0aa277ced3b1bfadf9" - integrity sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw== dependencies: os-tmpdir "~1.0.2" to-absolute-glob@^2.0.0: version "2.0.2" resolved "https://registry.yarnpkg.com/to-absolute-glob/-/to-absolute-glob-2.0.2.tgz#1865f43d9e74b0822db9f145b78cff7d0f7c849b" - integrity sha1-GGX0PZ50sIItufFFt4z/fQ98hJs= dependencies: is-absolute "^1.0.0" is-negated-glob "^1.0.0" @@ -4685,24 +4138,20 @@ to-absolute-glob@^2.0.0: to-fast-properties@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz#dc5e698cbd079265bc73e0377681a4e4e83f616e" - integrity sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4= to-iso-string@0.0.2: version "0.0.2" - resolved "https://registry.yarnpkg.com/to-iso-string/-/to-iso-string-0.0.2.tgz#4dc19e664dfccbe25bd8db508b00c6da158255d1" - integrity sha1-TcGeZk38y+Jb2NtQiwDG2hWCVdE= + resolved "https://registry.npmjs.org/to-iso-string/-/to-iso-string-0.0.2.tgz#4dc19e664dfccbe25bd8db508b00c6da158255d1" to-object-path@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/to-object-path/-/to-object-path-0.3.0.tgz#297588b7b0e7e0ac08e04e672f85c1f4999e17af" - integrity sha1-KXWIt7Dn4KwI4E5nL4XB9JmeF68= dependencies: kind-of "^3.0.2" to-regex-range@^2.1.0: version "2.1.1" resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-2.1.1.tgz#7c80c17b9dfebe599e27367e0d4dd5590141db38" - integrity sha1-fIDBe53+vlmeJzZ+DU3VWQFB2zg= dependencies: is-number "^3.0.0" repeat-string "^1.6.1" @@ -4710,7 +4159,6 @@ to-regex-range@^2.1.0: to-regex@^3.0.1, to-regex@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/to-regex/-/to-regex-3.0.2.tgz#13cfdd9b336552f30b51f33a8ae1b42a7a7599ce" - integrity sha512-FWtleNAtZ/Ki2qtqej2CXTOayOH9bHDQF+Q48VpWyDXjbYxA4Yz8iDB31zXOBUlOHHKidDbqGVrTUvQMPmBGBw== dependencies: define-property "^2.0.2" extend-shallow "^3.0.2" @@ -4720,70 +4168,58 @@ to-regex@^3.0.1, to-regex@^3.0.2: to-through@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/to-through/-/to-through-2.0.0.tgz#fc92adaba072647bc0b67d6b03664aa195093af6" - integrity sha1-/JKtq6ByZHvAtn1rA2ZKoZUJOvY= dependencies: through2 "^2.0.3" tough-cookie@~2.3.3: version "2.3.3" resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.3.tgz#0b618a5565b6dea90bf3425d04d55edc475a7561" - integrity sha1-C2GKVWW23qkL80JdBNVe3EdadWE= dependencies: punycode "^1.4.1" trim-right@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/trim-right/-/trim-right-1.0.1.tgz#cb2e1203067e0c8de1f614094b9fe45704ea6003" - integrity sha1-yy4SAwZ+DI3h9hQJS5/kVwTqYAM= tunnel-agent@^0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.6.0.tgz#27a5dea06b36b04a0a9966774b290868f0fc40fd" - integrity sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0= dependencies: safe-buffer "^5.0.1" tweetnacl@^0.14.3, tweetnacl@~0.14.0: version "0.14.5" resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64" - integrity sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q= type-check@~0.3.1, type-check@~0.3.2: version "0.3.2" resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.3.2.tgz#5884cab512cf1d355e3fb784f30804b2b520db72" - integrity sha1-WITKtRLPHTVeP7eE8wgEsrUg23I= dependencies: prelude-ls "~1.1.2" type-detect@0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-0.1.1.tgz#0ba5ec2a885640e470ea4e8505971900dac58822" - integrity sha1-C6XsKohWQORw6k6FBZcZANrFiCI= type-detect@4.0.8, type-detect@^4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c" - integrity sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g== type-detect@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-1.0.0.tgz#762217cc06db258ec48908a1298e8b95121e8ea2" - integrity sha1-diIXzAbbJY7EiQihKY6LlRIejqI= type@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/type/-/type-1.0.1.tgz#084c9a17fcc9151a2cdb1459905c2e45e4bb7d61" - integrity sha512-MAM5dBMJCJNKs9E7JXo4CXRAansRfG0nlJxW7Wf6GZzSOvH31zClSaHdIMWLehe/EGMBkqeC55rrkaOr5Oo7Nw== typedarray@^0.0.6: version "0.0.6" resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" - integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c= uglify-js@^3.1.4: version "3.6.0" resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.6.0.tgz#704681345c53a8b2079fb6cec294b05ead242ff5" - integrity sha512-W+jrUHJr3DXKhrsS7NUVxn3zqMOFn0hL/Ei6v0anCIMoKC93TjcflTagwIHLW7SfMFfiQuktQyFVCFHGUE0+yg== dependencies: commander "~2.20.0" source-map "~0.6.1" @@ -4791,17 +4227,14 @@ uglify-js@^3.1.4: unc-path-regex@^0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/unc-path-regex/-/unc-path-regex-0.1.2.tgz#e73dd3d7b0d7c5ed86fbac6b0ae7d8c6a69d50fa" - integrity sha1-5z3T17DXxe2G+6xrCufYxqadUPo= undertaker-registry@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/undertaker-registry/-/undertaker-registry-1.0.1.tgz#5e4bda308e4a8a2ae584f9b9a4359a499825cc50" - integrity sha1-XkvaMI5KiirlhPm5pDWaSZglzFA= undertaker@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/undertaker/-/undertaker-1.2.1.tgz#701662ff8ce358715324dfd492a4f036055dfe4b" - integrity sha512-71WxIzDkgYk9ZS+spIB8iZXchFhAdEo2YU8xYqBYJ39DIUIqziK78ftm26eecoIY49X0J2MLhG4hr18Yp6/CMA== dependencies: arr-flatten "^1.0.1" arr-map "^2.0.0" @@ -4816,12 +4249,10 @@ undertaker@^1.2.1: unicode-canonical-property-names-ecmascript@^1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-1.0.4.tgz#2619800c4c825800efdd8343af7dd9933cbe2818" - integrity sha512-jDrNnXWHd4oHiTZnx/ZG7gtUTVp+gCcTTKr8L0HjlwphROEW3+Him+IpvC+xcJEFegapiMZyZe02CyuOnRmbnQ== unicode-match-property-ecmascript@^1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/unicode-match-property-ecmascript/-/unicode-match-property-ecmascript-1.0.4.tgz#8ed2a32569961bce9227d09cd3ffbb8fed5f020c" - integrity sha512-L4Qoh15vTfntsn4P1zqnHulG0LdXgjSO035fEpdtp6YxXhMT51Q6vgM5lYdG/5X3MjS+k/Y9Xw4SFCY9IkR0rg== dependencies: unicode-canonical-property-names-ecmascript "^1.0.4" unicode-property-aliases-ecmascript "^1.0.4" @@ -4829,17 +4260,14 @@ unicode-match-property-ecmascript@^1.0.4: unicode-match-property-value-ecmascript@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-1.1.0.tgz#5b4b426e08d13a80365e0d657ac7a6c1ec46a277" - integrity sha512-hDTHvaBk3RmFzvSl0UVrUmC3PuW9wKVnpoUDYH0JDkSIovzw+J5viQmeYHxVSBptubnr7PbH2e0fnpDRQnQl5g== unicode-property-aliases-ecmascript@^1.0.4: version "1.0.5" resolved "https://registry.yarnpkg.com/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-1.0.5.tgz#a9cc6cc7ce63a0a3023fc99e341b94431d405a57" - integrity sha512-L5RAqCfXqAwR3RriF8pM0lU0w4Ryf/GgzONwi6KnL1taJQa7x1TCxdJnILX59WIGOwR57IVxn7Nej0fz1Ny6fw== union-value@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/union-value/-/union-value-1.0.0.tgz#5c71c34cb5bad5dcebe3ea0cd08207ba5aa1aea4" - integrity sha1-XHHDTLW61dzr4+oM0IIHulqhrqQ= dependencies: arr-union "^3.1.0" get-value "^2.0.6" @@ -4849,7 +4277,6 @@ union-value@^1.0.0: unique-stream@^2.0.2: version "2.3.1" resolved "https://registry.yarnpkg.com/unique-stream/-/unique-stream-2.3.1.tgz#c65d110e9a4adf9a6c5948b28053d9a8d04cbeac" - integrity sha512-2nY4TnBE70yoxHkDli7DMazpWiP7xMdCYqU2nBRO0UB+ZpEkGsSija7MvmvnZFUeC+mrgiUfcHSr3LmRFIg4+A== dependencies: json-stable-stringify-without-jsonify "^1.0.1" through2-filter "^3.0.0" @@ -4857,7 +4284,6 @@ unique-stream@^2.0.2: unset-value@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/unset-value/-/unset-value-1.0.0.tgz#8376873f7d2335179ffb1e6fc3a8ed0dfc8ab559" - integrity sha1-g3aHP30jNRef+x5vw6jtDfyKtVk= dependencies: has-value "^0.3.1" isobject "^3.0.0" @@ -4865,41 +4291,34 @@ unset-value@^1.0.0: upath@^1.1.1: version "1.1.2" resolved "https://registry.yarnpkg.com/upath/-/upath-1.1.2.tgz#3db658600edaeeccbe6db5e684d67ee8c2acd068" - integrity sha512-kXpym8nmDmlCBr7nKdIx8P2jNBa+pBpIUFRnKJ4dr8htyYGJFokkr2ZvERRtUN+9SY+JqXouNgUPtv6JQva/2Q== urix@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/urix/-/urix-0.1.0.tgz#da937f7a62e21fec1fd18d49b35c2935067a6c72" - integrity sha1-2pN/emLiH+wf0Y1Js1wpNQZ6bHI= use@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/use/-/use-3.1.0.tgz#14716bf03fdfefd03040aef58d8b4b85f3a7c544" - integrity sha512-6UJEQM/L+mzC3ZJNM56Q4DFGLX/evKGRg15UJHGB9X5j5Z3AFbgZvjUh2yq/UJUY4U5dh7Fal++XbNg1uzpRAw== dependencies: kind-of "^6.0.2" util-deprecate@~1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" - integrity sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8= uuid@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.1.0.tgz#3dd3d3e790abc24d7b0d3a034ffababe28ebbc04" - integrity sha512-DIWtzUkw04M4k3bf1IcpS2tngXEL26YUD2M0tMDUpnUrz2hgzUBlD55a4FjdLGPvfHxS6uluGWvaVEqgBcVa+g== v8flags@^3.0.1: version "3.1.3" resolved "https://registry.yarnpkg.com/v8flags/-/v8flags-3.1.3.tgz#fc9dc23521ca20c5433f81cc4eb9b3033bb105d8" - integrity sha512-amh9CCg3ZxkzQ48Mhcb8iX7xpAfYJgePHxWMQCBWECpOSqJUXgY26ncA61UTV0BkPqfhcy6mzwCIoP4ygxpW8w== dependencies: homedir-polyfill "^1.0.1" validate-npm-package-license@^3.0.1: version "3.0.4" resolved "https://registry.yarnpkg.com/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz#fc91f6b9c7ba15c857f4cb2c5defeec39d4f410a" - integrity sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew== dependencies: spdx-correct "^3.0.0" spdx-expression-parse "^3.0.0" @@ -4907,12 +4326,10 @@ validate-npm-package-license@^3.0.1: value-or-function@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/value-or-function/-/value-or-function-3.0.0.tgz#1c243a50b595c1be54a754bfece8563b9ff8d813" - integrity sha1-HCQ6ULWVwb5Up1S/7OhWO5/42BM= verror@1.10.0: version "1.10.0" resolved "https://registry.yarnpkg.com/verror/-/verror-1.10.0.tgz#3a105ca17053af55d6e270c1f8288682e18da400" - integrity sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA= dependencies: assert-plus "^1.0.0" core-util-is "1.0.2" @@ -4921,7 +4338,6 @@ verror@1.10.0: vinyl-fs@^3.0.0: version "3.0.3" resolved "https://registry.yarnpkg.com/vinyl-fs/-/vinyl-fs-3.0.3.tgz#c85849405f67428feabbbd5c5dbdd64f47d31bc7" - integrity sha512-vIu34EkyNyJxmP0jscNzWBSygh7VWhqun6RmqVfXePrOwi9lhvRs//dOaGOTRUQr4tx7/zd26Tk5WeSVZitgng== dependencies: fs-mkdirp-stream "^1.0.0" glob-stream "^6.1.0" @@ -4944,7 +4360,6 @@ vinyl-fs@^3.0.0: vinyl-sourcemap@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/vinyl-sourcemap/-/vinyl-sourcemap-1.1.0.tgz#92a800593a38703a8cdb11d8b300ad4be63b3e16" - integrity sha1-kqgAWTo4cDqM2xHYswCtS+Y7PhY= dependencies: append-buffer "^1.0.2" convert-source-map "^1.5.0" @@ -4957,14 +4372,12 @@ vinyl-sourcemap@^1.1.0: vinyl-sourcemaps-apply@^0.2.0: version "0.2.1" resolved "https://registry.yarnpkg.com/vinyl-sourcemaps-apply/-/vinyl-sourcemaps-apply-0.2.1.tgz#ab6549d61d172c2b1b87be5c508d239c8ef87705" - integrity sha1-q2VJ1h0XLCsbh75cUI0jnI74dwU= dependencies: source-map "^0.5.1" vinyl@^0.5.0: version "0.5.3" resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-0.5.3.tgz#b0455b38fc5e0cf30d4325132e461970c2091cde" - integrity sha1-sEVbOPxeDPMNQyUTLkYZcMIJHN4= dependencies: clone "^1.0.0" clone-stats "^0.0.1" @@ -4973,7 +4386,6 @@ vinyl@^0.5.0: vinyl@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-2.2.0.tgz#d85b07da96e458d25b2ffe19fece9f2caa13ed86" - integrity sha512-MBH+yP0kC/GQ5GwBqrTPTzEfiiLjta7hTtvQtbxBgTeSXsmKQRQecjibMbxIXzVT3Y9KJK+drOz1/k+vsu8Nkg== dependencies: clone "^2.1.1" clone-buffer "^1.0.0" @@ -4985,43 +4397,36 @@ vinyl@^2.0.0: which-module@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/which-module/-/which-module-1.0.0.tgz#bba63ca861948994ff307736089e3b96026c2a4f" - integrity sha1-u6Y8qGGUiZT/MHc2CJ47lgJsKk8= which@^1.1.1, which@^1.2.14: version "1.3.0" resolved "https://registry.yarnpkg.com/which/-/which-1.3.0.tgz#ff04bdfc010ee547d780bec38e1ac1c2777d253a" - integrity sha512-xcJpopdamTuY5duC/KnTTNBraPK54YwpenP4lzxU8H91GudWpFv38u0CKjclE1Wi2EH2EDz5LRcHcKbCIzqGyg== dependencies: isexe "^2.0.0" which@^1.2.9: version "1.3.1" resolved "https://registry.yarnpkg.com/which/-/which-1.3.1.tgz#a45043d54f5805316da8d62f9f50918d3da70b0a" - integrity sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ== dependencies: isexe "^2.0.0" wide-align@^1.1.0: version "1.1.3" resolved "https://registry.yarnpkg.com/wide-align/-/wide-align-1.1.3.tgz#ae074e6bdc0c14a431e804e624549c633b000457" - integrity sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA== dependencies: string-width "^1.0.2 || 2" wordwrap@^1.0.0, wordwrap@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" - integrity sha1-J1hIEIkUVqQXHI0CJkQa3pDLyus= wordwrap@~0.0.2: version "0.0.3" resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.3.tgz#a3d5da6cd5c0bc0008d37234bbaf1bed63059107" - integrity sha1-o9XabNXAvAAI03I0u68b7WMFkQc= wrap-ansi@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-2.1.0.tgz#d8fc3d284dd05794fe84973caecdd1cf824fdd85" - integrity sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU= dependencies: string-width "^1.0.1" strip-ansi "^3.0.1" @@ -5029,46 +4434,38 @@ wrap-ansi@^2.0.0: wrappy@1: version "1.0.2" resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" - integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= write@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/write/-/write-0.2.1.tgz#5fc03828e264cea3fe91455476f7a3c566cb0757" - integrity sha1-X8A4KOJkzqP+kUVUdvejxWbLB1c= dependencies: mkdirp "^0.5.1" xtend@~4.0.0, xtend@~4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.1.tgz#a5c6d532be656e23db820efb943a1f04998d63af" - integrity sha1-pcbVMr5lbiPbgg77lDofBJmNY68= y18n@^3.2.1: version "3.2.1" resolved "https://registry.yarnpkg.com/y18n/-/y18n-3.2.1.tgz#6d15fba884c08679c0d77e88e7759e811e07fa41" - integrity sha1-bRX7qITAhnnA136I53WegR4H+kE= yallist@^2.1.2: version "2.1.2" resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz#1c11f9218f076089a47dd512f93c6699a6a81d52" - integrity sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI= yallist@^3.0.0, yallist@^3.0.3: version "3.0.3" resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.0.3.tgz#b4b049e314be545e3ce802236d6cd22cd91c3de9" - integrity sha512-S+Zk8DEWE6oKpV+vI3qWkaK+jSbIK86pCwe2IF/xwIpQ8jEuxpw9NyaGjmp9+BoJv5FV2piqCDcoCtStppiq2A== yargs-parser@^5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-5.0.0.tgz#275ecf0d7ffe05c77e64e7c86e4cd94bf0e1228a" - integrity sha1-J17PDX/+Bcd+ZOfIbkzZS/DhIoo= dependencies: camelcase "^3.0.0" yargs@^7.1.0: version "7.1.0" resolved "https://registry.yarnpkg.com/yargs/-/yargs-7.1.0.tgz#6ba318eb16961727f5d284f8ea003e8d6154d0c8" - integrity sha1-a6MY6xaWFyf10oT46gA+jWFU0Mg= dependencies: camelcase "^3.0.0" cliui "^3.2.0" From 0b6da8284cbf99af1b54771e7623425c3e621988 Mon Sep 17 00:00:00 2001 From: Matt Donnelly Date: Wed, 3 Jul 2019 19:40:05 +0100 Subject: [PATCH 011/146] Bump gulp-mocha and add eslint peer dependecy --- gulpfile.js | 5 +- package.json | 3 +- yarn.lock | 496 ++++++++++++++++++++++++++++++++++++++------------- 3 files changed, 375 insertions(+), 129 deletions(-) diff --git a/gulpfile.js b/gulpfile.js index 3e37b075..e54b2c77 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -31,7 +31,10 @@ gulp.task( return gulp .src('test/**/*.js') .pipe(plumber()) - .pipe(mocha({ reporter: 'spec' })); + .pipe(mocha({ + compilers: 'js:@babel/register', + reporter: 'spec' + })); }) ); diff --git a/package.json b/package.json index d8ac3915..67aeb68e 100644 --- a/package.json +++ b/package.json @@ -28,12 +28,13 @@ "@babel/preset-env": "^7.4.5", "@babel/register": "^7.4.4", "babel-eslint": "^10.0.2", + "eslint": "^6.0.1", "gulp": "^4.0.2", "gulp-babel": "^8.0.0", "gulp-eslint": "4.0.2", "gulp-exclude-gitignore": "^1.0.0", "gulp-istanbul": "^0.10.3", - "gulp-mocha": "^2.0.0", + "gulp-mocha": "^6.0.0", "gulp-plumber": "^1.1.0", "nock": "7.5.0", "sinon": "^6.1.4" diff --git a/yarn.lock b/yarn.lock index 28409aa8..74e485fc 100644 --- a/yarn.lock +++ b/yarn.lock @@ -596,6 +596,10 @@ acorn-jsx@^3.0.0: dependencies: acorn "^3.0.4" +acorn-jsx@^5.0.0: + version "5.0.1" + resolved "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.0.1.tgz#32a064fd925429216a09b141102bfdd185fae40e" + acorn@^3.0.4: version "3.3.0" resolved "https://registry.yarnpkg.com/acorn/-/acorn-3.3.0.tgz#45e37fb39e8da3f25baee3ff5369e2bb5f22017a" @@ -604,6 +608,10 @@ acorn@^5.5.0: version "5.7.3" resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.3.tgz#67aa231bf8812974b85235a96771eb6bd07ea279" +acorn@^6.0.7: + version "6.1.1" + resolved "https://registry.npmjs.org/acorn/-/acorn-6.1.1.tgz#7d25ae05bb8ad1f9b699108e1094ecd7884adc1f" + ajv-keywords@^2.1.0: version "2.1.1" resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-2.1.1.tgz#617997fc5f60576894c435f940d819e135b80762" @@ -626,6 +634,15 @@ ajv@^5.2.3, ajv@^5.3.0: fast-json-stable-stringify "^2.0.0" json-schema-traverse "^0.3.0" +ajv@^6.10.0, ajv@^6.9.1: + version "6.10.0" + resolved "https://registry.npmjs.org/ajv/-/ajv-6.10.0.tgz#90d0d54439da587cd7e843bfb7045f50bd22bdf1" + dependencies: + fast-deep-equal "^2.0.1" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.4.1" + uri-js "^4.2.2" + amdefine@>=0.0.4: version "1.0.1" resolved "https://registry.yarnpkg.com/amdefine/-/amdefine-1.0.1.tgz#4a5282ac164729e93619bcfd3ad151f817ce91f5" @@ -636,7 +653,7 @@ ansi-colors@^1.0.1: dependencies: ansi-wrap "^0.1.0" -ansi-escapes@^3.0.0: +ansi-escapes@^3.0.0, ansi-escapes@^3.2.0: version "3.2.0" resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.2.0.tgz#8780b98ff9dbf5638152d1f1fe5c1d7b4442976b" @@ -654,11 +671,15 @@ ansi-regex@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.0.tgz#ed0317c322064f79466c02966bddb605ab37d998" +ansi-regex@^4.1.0: + version "4.1.0" + resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz#8b9f8f08cf1acb843756a839ca8c7e3168c51997" + ansi-styles@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" -ansi-styles@^3.2.1: +ansi-styles@^3.2.0, ansi-styles@^3.2.1: version "3.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" dependencies: @@ -789,6 +810,10 @@ assign-symbols@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/assign-symbols/-/assign-symbols-1.0.0.tgz#59667f41fadd4f20ccbc2bb96b8d4f7f78ec0367" +astral-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/astral-regex/-/astral-regex-1.0.0.tgz#6c8c3fb827dd43ee3918f27b82782ab7658a6fd9" + async-done@^1.2.0, async-done@^1.2.2: version "1.3.2" resolved "https://registry.yarnpkg.com/async-done/-/async-done-1.3.2.tgz#5e15aa729962a4b07414f528a88cdf18e0b290a2" @@ -929,6 +954,10 @@ braces@^2.3.1, braces@^2.3.2: split-string "^3.0.2" to-regex "^3.0.1" +browser-stdout@1.3.1: + version "1.3.1" + resolved "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz#baa559ee14ced73452229bad7326467c61fabd60" + browserslist@^4.6.0, browserslist@^4.6.2: version "4.6.3" resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.6.3.tgz#0530cbc6ab0c1f3fc8c819c72377ba55cf647f05" @@ -969,6 +998,10 @@ callsites@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/callsites/-/callsites-0.2.0.tgz#afab96262910a7f33c19a5775825c69f34e350ca" +callsites@^3.0.0: + version "3.1.0" + resolved "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" + camelcase@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-3.0.0.tgz#32fc4b9fcdaf845fcdf7e73bb97cac2261f0ab0a" @@ -999,7 +1032,7 @@ chalk@^1.0.0, chalk@^1.1.1, chalk@^1.1.3: strip-ansi "^3.0.0" supports-color "^2.0.0" -chalk@^2.0.0, chalk@^2.1.0: +chalk@^2.0.0, chalk@^2.1.0, chalk@^2.4.2: version "2.4.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" dependencies: @@ -1011,6 +1044,10 @@ chardet@^0.4.0: version "0.4.2" resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.4.2.tgz#b5473b33dc97c424e5d98dc87d55d4d8a29c8bf2" +chardet@^0.7.0: + version "0.7.0" + resolved "https://registry.npmjs.org/chardet/-/chardet-0.7.0.tgz#90094849f0937f2eedc2425d0d28a9e5f0cbad9e" + chokidar@^2.0.0: version "2.1.6" resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-2.1.6.tgz#b6cad653a929e244ce8a834244164d241fa954c5" @@ -1135,13 +1172,9 @@ combined-stream@^1.0.5, combined-stream@~1.0.5: dependencies: delayed-stream "~1.0.0" -commander@0.6.1: - version "0.6.1" - resolved "https://registry.npmjs.org/commander/-/commander-0.6.1.tgz#fa68a14f6a945d54dbbe50d8cdb3320e9e3b1a06" - -commander@2.3.0: - version "2.3.0" - resolved "https://registry.npmjs.org/commander/-/commander-2.3.0.tgz#fd430e889832ec353b9acd1de217c11cb3eef873" +commander@2.15.1: + version "2.15.1" + resolved "https://registry.npmjs.org/commander/-/commander-2.15.1.tgz#df46e867d0fc2aec66a34662b406a9ccafff5b0f" commander@~2.20.0: version "2.20.0" @@ -1221,6 +1254,16 @@ cross-spawn@^5.1.0: shebang-command "^1.2.0" which "^1.2.9" +cross-spawn@^6.0.0, cross-spawn@^6.0.5: + version "6.0.5" + resolved "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4" + dependencies: + nice-try "^1.0.4" + path-key "^2.0.1" + semver "^5.5.0" + shebang-command "^1.2.0" + which "^1.2.9" + cryptiles@3.x.x: version "3.1.2" resolved "https://registry.yarnpkg.com/cryptiles/-/cryptiles-3.1.2.tgz#a89fbb220f5ce25ec56e8c4aa8a4fd7b5b0d29fe" @@ -1234,6 +1277,10 @@ d@1: es5-ext "^0.10.50" type "^1.0.1" +dargs@^5.1.0: + version "5.1.0" + resolved "https://registry.npmjs.org/dargs/-/dargs-5.1.0.tgz#ec7ea50c78564cd36c9d5ec18f66329fade27829" + dashdash@^1.12.0: version "1.14.1" resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0" @@ -1244,11 +1291,11 @@ dateformat@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-2.2.0.tgz#4065e2013cf9fb916ddfd82efb506ad4c6769062" -debug@2.2.0: - version "2.2.0" - resolved "https://registry.npmjs.org/debug/-/debug-2.2.0.tgz#f87057e995b1a1f6ae6a4960664137bc56f039da" +debug@3.1.0: + version "3.1.0" + resolved "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" dependencies: - ms "0.7.1" + ms "2.0.0" debug@^2.2.0, debug@^2.3.3: version "2.6.9" @@ -1262,7 +1309,7 @@ debug@^3.1.0, debug@^3.2.6: dependencies: ms "^2.1.1" -debug@^4.1.0: +debug@^4.0.1, debug@^4.1.0: version "4.1.1" resolved "https://registry.yarnpkg.com/debug/-/debug-4.1.1.tgz#3b72260255109c6b589cee050f1d516139664791" dependencies: @@ -1345,11 +1392,7 @@ detect-libc@^1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-1.0.3.tgz#fa137c4bd698edf55cd5cd02ac559f91a4c4ba9b" -diff@1.4.0: - version "1.4.0" - resolved "https://registry.npmjs.org/diff/-/diff-1.4.0.tgz#7f28d2eb9ee7b15a97efd89ce63dcfdaa3ccbabf" - -diff@^3.5.0: +diff@3.5.0, diff@^3.5.0: version "3.5.0" resolved "https://registry.yarnpkg.com/diff/-/diff-3.5.0.tgz#800c0dd1e0a8bfbc95835c202ad220fe317e5a12" @@ -1359,6 +1402,12 @@ doctrine@^2.1.0: dependencies: esutils "^2.0.2" +doctrine@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz#addebead72a6574db783639dc87a121773973961" + dependencies: + esutils "^2.0.2" + duplexer2@0.0.2: version "0.0.2" resolved "https://registry.yarnpkg.com/duplexer2/-/duplexer2-0.0.2.tgz#c614dcf67e2fb14995a91711e5a617e8a60a31db" @@ -1392,6 +1441,10 @@ electron-to-chromium@^1.3.164: version "1.3.185" resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.185.tgz#36368514eb719632a91435f3c9f57c98b47d81de" +emoji-regex@^7.0.1: + version "7.0.3" + resolved "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz#933a04052860c85e83c122479c4748a8e4c72156" + end-of-stream@^1.0.0, end-of-stream@^1.1.0: version "1.4.1" resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.1.tgz#ed29634d19baba463b6ce6b80a37213eab71ec43" @@ -1436,11 +1489,7 @@ es6-weak-map@^2.0.1: es6-iterator "^2.0.3" es6-symbol "^3.1.1" -escape-string-regexp@1.0.2: - version "1.0.2" - resolved "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.2.tgz#4dbc2fe674e71949caf3fb2695ce7f2dc1d9a8d1" - -escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5: +escape-string-regexp@1.0.5, escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" @@ -1480,6 +1529,17 @@ eslint-scope@^3.7.1: esrecurse "^4.1.0" estraverse "^4.1.1" +eslint-scope@^4.0.3: + version "4.0.3" + resolved "https://registry.npmjs.org/eslint-scope/-/eslint-scope-4.0.3.tgz#ca03833310f6889a3264781aa82e63eb9cfe7848" + dependencies: + esrecurse "^4.1.0" + estraverse "^4.1.1" + +eslint-utils@^1.3.1: + version "1.3.1" + resolved "https://registry.npmjs.org/eslint-utils/-/eslint-utils-1.3.1.tgz#9a851ba89ee7c460346f97cf8939c7298827e512" + eslint-visitor-keys@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" @@ -1527,6 +1587,47 @@ eslint@^4.0.0: table "4.0.2" text-table "~0.2.0" +eslint@^6.0.1: + version "6.0.1" + resolved "https://registry.npmjs.org/eslint/-/eslint-6.0.1.tgz#4a32181d72cb999d6f54151df7d337131f81cda7" + dependencies: + "@babel/code-frame" "^7.0.0" + ajv "^6.10.0" + chalk "^2.1.0" + cross-spawn "^6.0.5" + debug "^4.0.1" + doctrine "^3.0.0" + eslint-scope "^4.0.3" + eslint-utils "^1.3.1" + eslint-visitor-keys "^1.0.0" + espree "^6.0.0" + esquery "^1.0.1" + esutils "^2.0.2" + file-entry-cache "^5.0.1" + functional-red-black-tree "^1.0.1" + glob-parent "^3.1.0" + globals "^11.7.0" + ignore "^4.0.6" + import-fresh "^3.0.0" + imurmurhash "^0.1.4" + inquirer "^6.2.2" + is-glob "^4.0.0" + js-yaml "^3.13.1" + json-stable-stringify-without-jsonify "^1.0.1" + levn "^0.3.0" + lodash "^4.17.11" + minimatch "^3.0.4" + mkdirp "^0.5.1" + natural-compare "^1.4.0" + optionator "^0.8.2" + progress "^2.0.0" + regexpp "^2.0.1" + semver "^5.5.1" + strip-ansi "^4.0.0" + strip-json-comments "^2.0.1" + table "^5.2.3" + text-table "^0.2.0" + espree@^3.5.4: version "3.5.4" resolved "https://registry.yarnpkg.com/espree/-/espree-3.5.4.tgz#b0f447187c8a8bed944b815a660bddf5deb5d1a7" @@ -1534,6 +1635,14 @@ espree@^3.5.4: acorn "^5.5.0" acorn-jsx "^3.0.0" +espree@^6.0.0: + version "6.0.0" + resolved "https://registry.npmjs.org/espree/-/espree-6.0.0.tgz#716fc1f5a245ef5b9a7fdb1d7b0d3f02322e75f6" + dependencies: + acorn "^6.0.7" + acorn-jsx "^5.0.0" + eslint-visitor-keys "^1.0.0" + esprima@2.5.x: version "2.5.0" resolved "https://registry.yarnpkg.com/esprima/-/esprima-2.5.0.tgz#f387a46fd344c1b1a39baf8c20bfb43b6d0058cc" @@ -1550,7 +1659,7 @@ esprima@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" -esquery@^1.0.0: +esquery@^1.0.0, esquery@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.1.tgz#406c51658b1f5991a5f9b62b1dc25b00e3e5c708" dependencies: @@ -1575,6 +1684,18 @@ esutils@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.2.tgz#0abf4f1caa5bcb1f7a9d8acc6dea4faaa04bac9b" +execa@^0.10.0: + version "0.10.0" + resolved "https://registry.npmjs.org/execa/-/execa-0.10.0.tgz#ff456a8f53f90f8eccc71a96d11bdfc7f082cb50" + dependencies: + cross-spawn "^6.0.0" + get-stream "^3.0.0" + is-stream "^1.1.0" + npm-run-path "^2.0.0" + p-finally "^1.0.0" + signal-exit "^3.0.0" + strip-eof "^1.0.0" + expand-brackets@^2.1.4: version "2.1.4" resolved "https://registry.yarnpkg.com/expand-brackets/-/expand-brackets-2.1.4.tgz#b77735e315ce30f6b6eff0f83b04151a22449622" @@ -1618,6 +1739,14 @@ external-editor@^2.0.4: iconv-lite "^0.4.17" tmp "^0.0.33" +external-editor@^3.0.3: + version "3.0.3" + resolved "https://registry.npmjs.org/external-editor/-/external-editor-3.0.3.tgz#5866db29a97826dbe4bf3afd24070ead9ea43a27" + dependencies: + chardet "^0.7.0" + iconv-lite "^0.4.24" + tmp "^0.0.33" + extglob@^2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/extglob/-/extglob-2.0.4.tgz#ad00fe4dc612a9232e8718711dc5cb5ab0285543" @@ -1655,6 +1784,10 @@ fast-deep-equal@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-1.0.0.tgz#96256a3bc975595eb36d82e9929d060d893439ff" +fast-deep-equal@^2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz#7b05218ddf9667bf7f370bf7fdb2cb15fdd0aa49" + fast-json-stable-stringify@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" @@ -1680,6 +1813,12 @@ file-entry-cache@^2.0.0: flat-cache "^1.2.1" object-assign "^4.0.1" +file-entry-cache@^5.0.1: + version "5.0.1" + resolved "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-5.0.1.tgz#ca0f6efa6dd3d561333fb14515065c2fafdf439c" + dependencies: + flat-cache "^2.0.1" + fileset@0.2.x: version "0.2.1" resolved "https://registry.yarnpkg.com/fileset/-/fileset-0.2.1.tgz#588ef8973c6623b2a76df465105696b96aac8067" @@ -1758,6 +1897,18 @@ flat-cache@^1.2.1: rimraf "~2.6.2" write "^0.2.1" +flat-cache@^2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/flat-cache/-/flat-cache-2.0.1.tgz#5d296d6f04bda44a4630a301413bdbc2ec085ec0" + dependencies: + flatted "^2.0.0" + rimraf "2.6.3" + write "1.0.3" + +flatted@^2.0.0: + version "2.0.1" + resolved "https://registry.npmjs.org/flatted/-/flatted-2.0.1.tgz#69e57caa8f0eacbc281d2e2cb458d46fdb449e08" + flush-write-stream@^1.0.2: version "1.1.1" resolved "https://registry.yarnpkg.com/flush-write-stream/-/flush-write-stream-1.1.1.tgz#8dd7d873a1babc207d94ead0c2e0e44276ebf2e8" @@ -1842,6 +1993,10 @@ get-caller-file@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.3.tgz#f978fa4c90d1dfe7ff2d6beda2a515e713bdcf4a" +get-stream@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/get-stream/-/get-stream-3.0.0.tgz#8e943d1358dc37555054ecbe2edb05aa174ede14" + get-value@^2.0.3, get-value@^2.0.6: version "2.0.6" resolved "https://registry.yarnpkg.com/get-value/-/get-value-2.0.6.tgz#dc15ca1c672387ca76bd37ac0a395ba2042a2c28" @@ -1885,13 +2040,6 @@ glob-watcher@^5.0.3: just-debounce "^1.0.0" object.defaults "^1.1.0" -glob@3.2.11: - version "3.2.11" - resolved "https://registry.npmjs.org/glob/-/glob-3.2.11.tgz#4a973f635b9190f715d10987d5c00fd2815ebe3d" - dependencies: - inherits "2" - minimatch "0.3" - glob@5.x, glob@^5.0.15: version "5.0.15" resolved "https://registry.yarnpkg.com/glob/-/glob-5.0.15.tgz#1bc936b9e02f4a603fcc222ecf7633d30b8b93b1" @@ -1902,6 +2050,17 @@ glob@5.x, glob@^5.0.15: once "^1.3.0" path-is-absolute "^1.0.0" +glob@7.1.2: + version "7.1.2" + resolved "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15" + dependencies: + fs.realpath "^1.0.0" + inflight "^1.0.4" + inherits "2" + minimatch "^3.0.4" + once "^1.3.0" + path-is-absolute "^1.0.0" + glob@^7.1.1, glob@^7.1.2, glob@^7.1.3: version "7.1.4" resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.4.tgz#aa608a2f6c577ad357e1ae5a5c26d9a8d1969255" @@ -1931,7 +2090,7 @@ global-prefix@^1.0.1: is-windows "^1.0.1" which "^1.2.14" -globals@^11.0.1, globals@^11.1.0: +globals@^11.0.1, globals@^11.1.0, globals@^11.7.0: version "11.12.0" resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" @@ -1945,9 +2104,9 @@ graceful-fs@^4.0.0, graceful-fs@^4.1.11, graceful-fs@^4.1.2, graceful-fs@^4.1.6: version "4.2.0" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.0.tgz#8d8fdc73977cb04104721cb53666c1ca64cd328b" -growl@1.9.2: - version "1.9.2" - resolved "https://registry.npmjs.org/growl/-/growl-1.9.2.tgz#0ea7743715db8d8de2c5ede1775e1b45ac85c02f" +growl@1.10.5: + version "1.10.5" + resolved "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz#f2735dc2283674fa67478b10181059355c369e5e" gulp-babel@^8.0.0: version "8.0.0" @@ -2018,16 +2177,17 @@ gulp-match@^1.0.3: dependencies: minimatch "^3.0.3" -gulp-mocha@^2.0.0: - version "2.2.0" - resolved "https://registry.npmjs.org/gulp-mocha/-/gulp-mocha-2.2.0.tgz#1ce5eba4b94b40c7436afec3c4982c8eea894192" +gulp-mocha@^6.0.0: + version "6.0.0" + resolved "https://registry.npmjs.org/gulp-mocha/-/gulp-mocha-6.0.0.tgz#80f32bc705ce30747f355ddb8ccd96a1c73bef13" dependencies: - gulp-util "^3.0.0" - mocha "^2.0.1" - plur "^2.1.0" - resolve-from "^1.0.0" - temp "^0.8.3" - through "^2.3.4" + dargs "^5.1.0" + execa "^0.10.0" + mocha "^5.2.0" + npm-run-path "^2.0.2" + plugin-error "^1.0.1" + supports-color "^5.4.0" + through2 "^2.0.3" gulp-plumber@^1.1.0: version "1.1.0" @@ -2036,7 +2196,7 @@ gulp-plumber@^1.1.0: gulp-util "^3" through2 "^2" -gulp-util@^3, gulp-util@^3.0.0, gulp-util@^3.0.1: +gulp-util@^3, gulp-util@^3.0.1: version "3.0.8" resolved "https://registry.yarnpkg.com/gulp-util/-/gulp-util-3.0.8.tgz#0054e1e744502e27c04c187c3ecc505dd54bbb4f" dependencies: @@ -2159,6 +2319,10 @@ hawk@~6.0.2: hoek "4.x.x" sntp "2.x.x" +he@1.1.1: + version "1.1.1" + resolved "https://registry.npmjs.org/he/-/he-1.1.1.tgz#93410fd21b009735151f8868c2f271f3427e23fd" + hoek@4.x.x: version "4.2.0" resolved "https://registry.yarnpkg.com/hoek/-/hoek-4.2.0.tgz#72d9d0754f7fe25ca2d01ad8f8f9a9449a89526d" @@ -2185,7 +2349,7 @@ http-signature@~1.2.0: jsprim "^1.2.2" sshpk "^1.7.0" -iconv-lite@^0.4.17, iconv-lite@^0.4.4: +iconv-lite@^0.4.17, iconv-lite@^0.4.24, iconv-lite@^0.4.4: version "0.4.24" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" dependencies: @@ -2201,6 +2365,17 @@ ignore@^3.3.3: version "3.3.10" resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.10.tgz#0a97fb876986e8081c631160f8f9f389157f0043" +ignore@^4.0.6: + version "4.0.6" + resolved "https://registry.npmjs.org/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc" + +import-fresh@^3.0.0: + version "3.1.0" + resolved "https://registry.npmjs.org/import-fresh/-/import-fresh-3.1.0.tgz#6d33fa1dcef6df930fae003446f33415af905118" + dependencies: + parent-module "^1.0.0" + resolve-from "^4.0.0" + imurmurhash@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" @@ -2243,6 +2418,24 @@ inquirer@^3.0.6: strip-ansi "^4.0.0" through "^2.3.6" +inquirer@^6.2.2: + version "6.4.1" + resolved "https://registry.npmjs.org/inquirer/-/inquirer-6.4.1.tgz#7bd9e5ab0567cd23b41b0180b68e0cfa82fc3c0b" + dependencies: + ansi-escapes "^3.2.0" + chalk "^2.4.2" + cli-cursor "^2.1.0" + cli-width "^2.0.0" + external-editor "^3.0.3" + figures "^2.0.0" + lodash "^4.17.11" + mute-stream "0.0.7" + run-async "^2.2.0" + rxjs "^6.4.0" + string-width "^2.1.0" + strip-ansi "^5.1.0" + through "^2.3.6" + interpret@^1.1.0: version "1.2.0" resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.2.0.tgz#d5061a6224be58e8083985f5014d844359576296" @@ -2257,10 +2450,6 @@ invert-kv@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-1.0.0.tgz#104a8e4aaca6d3d8cd157a8ef8bfab2d7a3ffdb6" -irregular-plurals@^1.0.0: - version "1.4.0" - resolved "https://registry.npmjs.org/irregular-plurals/-/irregular-plurals-1.4.0.tgz#2ca9b033651111855412f16be5d77c62a458a766" - is-absolute@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-absolute/-/is-absolute-1.0.0.tgz#395e1ae84b11f26ad1795e73c17378e48a301576" @@ -2398,6 +2587,10 @@ is-resolvable@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-resolvable/-/is-resolvable-1.1.0.tgz#fb18f87ce1feb925169c9a407c19318a3206ed88" +is-stream@^1.1.0: + version "1.1.0" + resolved "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44" + is-typedarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" @@ -2491,13 +2684,6 @@ istanbul@^0.4.0: which "^1.1.1" wordwrap "^1.0.0" -jade@0.26.3: - version "0.26.3" - resolved "https://registry.npmjs.org/jade/-/jade-0.26.3.tgz#8f10d7977d8d79f2f6ff862a81b0513ccb25686c" - dependencies: - commander "0.6.1" - mkdirp "0.3.0" - js-levenshtein@^1.1.3: version "1.1.6" resolved "https://registry.yarnpkg.com/js-levenshtein/-/js-levenshtein-1.1.6.tgz#c6cee58eb3550372df8deb85fad5ce66ce01d59d" @@ -2510,7 +2696,7 @@ js-tokens@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" -js-yaml@3.x, js-yaml@^3.9.1: +js-yaml@3.x, js-yaml@^3.13.1, js-yaml@^3.9.1: version "3.13.1" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.13.1.tgz#aff151b30bfdfa8e49e05da22e7415e9dfa37847" dependencies: @@ -2533,6 +2719,10 @@ json-schema-traverse@^0.3.0: version "0.3.1" resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz#349a6d44c53a51de89b40805c5d5e59b417d3340" +json-schema-traverse@^0.4.1: + version "0.4.1" + resolved "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" + json-schema@0.2.3: version "0.2.3" resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" @@ -2784,10 +2974,6 @@ loose-envify@^1.0.0: dependencies: js-tokens "^3.0.0" -lru-cache@2: - version "2.7.3" - resolved "https://registry.npmjs.org/lru-cache/-/lru-cache-2.7.3.tgz#6d4524e8b955f95d4f5b58851ce21dd72fb4e952" - lru-cache@^4.0.1: version "4.1.5" resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.5.tgz#8bbe50ea85bed59bc9e33dcab8235ee9bcf443cd" @@ -2859,14 +3045,7 @@ mimic-fn@^1.0.0: version "1.2.0" resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" -minimatch@0.3: - version "0.3.0" - resolved "https://registry.npmjs.org/minimatch/-/minimatch-0.3.0.tgz#275d8edaac4f1bb3326472089e7949c8394699dd" - dependencies: - lru-cache "2" - sigmund "~1.0.0" - -"minimatch@2 || 3", minimatch@^3.0.2, minimatch@^3.0.3, minimatch@^3.0.4: +"minimatch@2 || 3", minimatch@3.0.4, minimatch@^3.0.2, minimatch@^3.0.3, minimatch@^3.0.4: version "3.0.4" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" dependencies: @@ -2910,34 +3089,27 @@ mixin-deep@^1.2.0: for-in "^1.0.2" is-extendable "^1.0.1" -mkdirp@0.3.0: - version "0.3.0" - resolved "https://registry.npmjs.org/mkdirp/-/mkdirp-0.3.0.tgz#1bbf5ab1ba827af23575143490426455f481fe1e" - mkdirp@0.5.1, mkdirp@0.5.x, mkdirp@^0.5.0, mkdirp@^0.5.1: version "0.5.1" resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.1.tgz#30057438eac6cf7f8c4767f38648d6697d75c903" dependencies: minimist "0.0.8" -mocha@^2.0.1: - version "2.5.3" - resolved "https://registry.npmjs.org/mocha/-/mocha-2.5.3.tgz#161be5bdeb496771eb9b35745050b622b5aefc58" - dependencies: - commander "2.3.0" - debug "2.2.0" - diff "1.4.0" - escape-string-regexp "1.0.2" - glob "3.2.11" - growl "1.9.2" - jade "0.26.3" +mocha@^5.2.0: + version "5.2.0" + resolved "https://registry.npmjs.org/mocha/-/mocha-5.2.0.tgz#6d8ae508f59167f940f2b5b3c4a612ae50c90ae6" + dependencies: + browser-stdout "1.3.1" + commander "2.15.1" + debug "3.1.0" + diff "3.5.0" + escape-string-regexp "1.0.5" + glob "7.1.2" + growl "1.10.5" + he "1.1.1" + minimatch "3.0.4" mkdirp "0.5.1" - supports-color "1.2.0" - to-iso-string "0.0.2" - -ms@0.7.1: - version "0.7.1" - resolved "https://registry.npmjs.org/ms/-/ms-0.7.1.tgz#9cd13c03adbff25b65effde7ce864ee952017098" + supports-color "5.4.0" ms@2.0.0: version "2.0.0" @@ -3002,6 +3174,10 @@ next-tick@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/next-tick/-/next-tick-1.0.0.tgz#ca86d1fe8828169b0120208e3dc8424b9db8342c" +nice-try@^1.0.4: + version "1.0.5" + resolved "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz#a3378a7696ce7d223e88fc9b764bd7ef1089e366" + nise@^1.4.5: version "1.4.6" resolved "https://registry.yarnpkg.com/nise/-/nise-1.4.6.tgz#76cc3915925056ae6c405dd8ad5d12bde570c19f" @@ -3099,6 +3275,12 @@ npm-packlist@^1.1.6: ignore-walk "^3.0.1" npm-bundled "^1.0.1" +npm-run-path@^2.0.0, npm-run-path@^2.0.2: + version "2.0.2" + resolved "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz#35a9232dfa35d7067b4cb2ddf2357b1871536c5f" + dependencies: + path-key "^2.0.0" + npmlog@^4.0.2: version "4.1.2" resolved "https://registry.yarnpkg.com/npmlog/-/npmlog-4.1.2.tgz#08a7f2a8bf734604779a9efa4ad5cc717abb954b" @@ -3248,6 +3430,10 @@ osenv@^0.1.4: os-homedir "^1.0.0" os-tmpdir "^1.0.0" +p-finally@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae" + p-limit@^2.0.0: version "2.2.0" resolved "https://registry.npmjs.org/p-limit/-/p-limit-2.2.0.tgz#417c9941e6027a9abcba5092dd2904e255b5fbc2" @@ -3264,6 +3450,12 @@ p-try@^2.0.0: version "2.2.0" resolved "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz#cb2868540e313d61de58fafbe35ce9004d5540e6" +parent-module@^1.0.0: + version "1.0.1" + resolved "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz#691d2709e78c79fae3a156622452d00762caaaa2" + dependencies: + callsites "^3.0.0" + parse-filepath@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/parse-filepath/-/parse-filepath-1.0.2.tgz#a632127f53aaf3d15876f5872f3ffac763d6c891" @@ -3312,6 +3504,10 @@ path-is-inside@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/path-is-inside/-/path-is-inside-1.0.2.tgz#365417dede44430d1c11af61027facf074bdfc53" +path-key@^2.0.0, path-key@^2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40" + path-parse@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.5.tgz#3c1adf871ea9cd6c9431b6ea2bd74a0ff055c4c1" @@ -3387,12 +3583,6 @@ plugin-error@^1.0.0, plugin-error@^1.0.1: arr-union "^3.1.0" extend-shallow "^3.0.2" -plur@^2.1.0: - version "2.1.2" - resolved "https://registry.npmjs.org/plur/-/plur-2.1.2.tgz#7482452c1a0f508e3e344eaec312c91c29dc655a" - dependencies: - irregular-plurals "^1.0.0" - pluralize@^7.0.0: version "7.0.0" resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-7.0.0.tgz#298b89df8b93b0221dbf421ad2b1b1ea23fc6777" @@ -3452,6 +3642,10 @@ punycode@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" +punycode@^2.1.0: + version "2.1.1" + resolved "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" + qs@^6.0.2, qs@~6.5.1: version "6.5.1" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8" @@ -3558,6 +3752,10 @@ regexpp@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-1.1.0.tgz#0e3516dd0b7904f413d2d4193dce4618c3a689ab" +regexpp@^2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/regexpp/-/regexpp-2.0.1.tgz#8d19d31cf632482b589049f8281f93dbcba4d07f" + regexpu-core@^4.5.4: version "4.5.4" resolved "https://registry.yarnpkg.com/regexpu-core/-/regexpu-core-4.5.4.tgz#080d9d02289aa87fe1667a4f5136bc98a6aebaae" @@ -3675,6 +3873,10 @@ resolve-from@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-1.0.1.tgz#26cbfe935d1aeeeabb29bc3fe5aeb01e93d44226" +resolve-from@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" + resolve-options@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/resolve-options/-/resolve-options-1.1.0.tgz#32bb9e39c06d67338dc9378c0d6d6074566ad131" @@ -3712,16 +3914,12 @@ ret@~0.1.10: version "0.1.15" resolved "https://registry.yarnpkg.com/ret/-/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc" -rimraf@^2.6.1, rimraf@~2.6.2: +rimraf@2.6.3, rimraf@^2.6.1, rimraf@~2.6.2: version "2.6.3" resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.3.tgz#b2d104fe0d8fb27cf9e0a1cda8262dd3833c6cab" dependencies: glob "^7.1.3" -rimraf@~2.2.6: - version "2.2.8" - resolved "https://registry.npmjs.org/rimraf/-/rimraf-2.2.8.tgz#e439be2aaee327321952730f99a8929e4fc50582" - run-async@^2.2.0: version "2.3.0" resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.3.0.tgz#0371ab4ae0bdd720d4166d7dfda64ff7a445a6c0" @@ -3738,6 +3936,12 @@ rx-lite@*, rx-lite@^4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-4.0.8.tgz#0b1e11af8bc44836f04a6407e92da42467b79444" +rxjs@^6.4.0: + version "6.5.2" + resolved "https://registry.npmjs.org/rxjs/-/rxjs-6.5.2.tgz#2e35ce815cd46d84d02a209fb4e5921e051dbec7" + dependencies: + tslib "^1.9.0" + safe-buffer@^5.0.1, safe-buffer@^5.1.1, safe-buffer@~5.1.0, safe-buffer@~5.1.1: version "5.1.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.1.tgz#893312af69b2123def71f57889001671eeb2c853" @@ -3766,7 +3970,7 @@ semver-greatest-satisfied-range@^1.1.0: dependencies: sver-compat "^1.5.0" -"semver@2 || 3 || 4 || 5", semver@^5.3.0, semver@^5.4.1, semver@^5.5.0, semver@^5.6.0: +"semver@2 || 3 || 4 || 5", semver@^5.3.0, semver@^5.4.1, semver@^5.5.0, semver@^5.5.1, semver@^5.6.0: version "5.7.0" resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.0.tgz#790a7cf6fea5459bac96110b29b60412dc8ff96b" @@ -3806,10 +4010,6 @@ shebang-regex@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3" -sigmund@~1.0.0: - version "1.0.1" - resolved "https://registry.npmjs.org/sigmund/-/sigmund-1.0.1.tgz#3ff21f198cad2175f9f3b781853fd94d0d19b590" - signal-exit@^3.0.0, signal-exit@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d" @@ -3834,6 +4034,14 @@ slice-ansi@1.0.0: dependencies: is-fullwidth-code-point "^2.0.0" +slice-ansi@^2.1.0: + version "2.1.0" + resolved "https://registry.npmjs.org/slice-ansi/-/slice-ansi-2.1.0.tgz#cacd7693461a637a5788d92a7dd4fba068e81636" + dependencies: + ansi-styles "^3.2.0" + astral-regex "^1.0.0" + is-fullwidth-code-point "^2.0.0" + snapdragon-node@^2.0.1: version "2.1.1" resolved "https://registry.yarnpkg.com/snapdragon-node/-/snapdragon-node-2.1.1.tgz#6c175f86ff14bdb0724563e8f3c1b021a286853b" @@ -3986,6 +4194,14 @@ string-width@^1.0.1, string-width@^1.0.2: is-fullwidth-code-point "^2.0.0" strip-ansi "^4.0.0" +string-width@^3.0.0: + version "3.1.0" + resolved "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz#22767be21b62af1081574306f69ac51b62203961" + dependencies: + emoji-regex "^7.0.1" + is-fullwidth-code-point "^2.0.0" + strip-ansi "^5.1.0" + string_decoder@~0.10.x: version "0.10.31" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94" @@ -4018,19 +4234,31 @@ strip-ansi@^4.0.0: dependencies: ansi-regex "^3.0.0" +strip-ansi@^5.1.0: + version "5.2.0" + resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz#8c9a536feb6afc962bdfa5b104a5091c1ad9c0ae" + dependencies: + ansi-regex "^4.1.0" + strip-bom@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-2.0.0.tgz#6219a85616520491f35788bdbf1447a99c7e6b0e" dependencies: is-utf8 "^0.2.0" -strip-json-comments@~2.0.1: +strip-eof@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz#bb43ff5598a6eb05d89b59fcd129c983313606bf" + +strip-json-comments@^2.0.1, strip-json-comments@~2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" -supports-color@1.2.0: - version "1.2.0" - resolved "https://registry.npmjs.org/supports-color/-/supports-color-1.2.0.tgz#ff1ed1e61169d06b3cf2d588e188b18d8847e17e" +supports-color@5.4.0: + version "5.4.0" + resolved "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz#1c6b337402c2137605efe19f10fec390f6faab54" + dependencies: + has-flag "^3.0.0" supports-color@^2.0.0: version "2.0.0" @@ -4042,7 +4270,7 @@ supports-color@^3.1.0: dependencies: has-flag "^1.0.0" -supports-color@^5.3.0, supports-color@^5.5.0: +supports-color@^5.3.0, supports-color@^5.4.0, supports-color@^5.5.0: version "5.5.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" dependencies: @@ -4066,6 +4294,15 @@ table@4.0.2: slice-ansi "1.0.0" string-width "^2.1.1" +table@^5.2.3: + version "5.4.1" + resolved "https://registry.npmjs.org/table/-/table-5.4.1.tgz#0691ae2ebe8259858efb63e550b6d5f9300171e8" + dependencies: + ajv "^6.9.1" + lodash "^4.17.11" + slice-ansi "^2.1.0" + string-width "^3.0.0" + tar@^4: version "4.4.10" resolved "https://registry.yarnpkg.com/tar/-/tar-4.4.10.tgz#946b2810b9a5e0b26140cf78bea6b0b0d689eba1" @@ -4078,18 +4315,11 @@ tar@^4: safe-buffer "^5.1.2" yallist "^3.0.3" -temp@^0.8.3: - version "0.8.3" - resolved "https://registry.npmjs.org/temp/-/temp-0.8.3.tgz#e0c6bc4d26b903124410e4fed81103014dfc1f59" - dependencies: - os-tmpdir "^1.0.0" - rimraf "~2.2.6" - text-encoding@^0.6.4: version "0.6.4" resolved "https://registry.yarnpkg.com/text-encoding/-/text-encoding-0.6.4.tgz#e399a982257a276dae428bb92845cb71bdc26d19" -text-table@~0.2.0: +text-table@^0.2.0, text-table@~0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" @@ -4114,7 +4344,7 @@ through2@^2.0.3, through2@~2.0.0: readable-stream "~2.3.6" xtend "~4.0.1" -through@^2.3.4, through@^2.3.6: +through@^2.3.6: version "2.3.8" resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" @@ -4139,10 +4369,6 @@ to-fast-properties@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz#dc5e698cbd079265bc73e0377681a4e4e83f616e" -to-iso-string@0.0.2: - version "0.0.2" - resolved "https://registry.npmjs.org/to-iso-string/-/to-iso-string-0.0.2.tgz#4dc19e664dfccbe25bd8db508b00c6da158255d1" - to-object-path@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/to-object-path/-/to-object-path-0.3.0.tgz#297588b7b0e7e0ac08e04e672f85c1f4999e17af" @@ -4181,6 +4407,10 @@ trim-right@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/trim-right/-/trim-right-1.0.1.tgz#cb2e1203067e0c8de1f614094b9fe45704ea6003" +tslib@^1.9.0: + version "1.10.0" + resolved "https://registry.npmjs.org/tslib/-/tslib-1.10.0.tgz#c3c19f95973fb0a62973fb09d90d961ee43e5c8a" + tunnel-agent@^0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.6.0.tgz#27a5dea06b36b04a0a9966774b290868f0fc40fd" @@ -4292,6 +4522,12 @@ upath@^1.1.1: version "1.1.2" resolved "https://registry.yarnpkg.com/upath/-/upath-1.1.2.tgz#3db658600edaeeccbe6db5e684d67ee8c2acd068" +uri-js@^4.2.2: + version "4.2.2" + resolved "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz#94c540e1ff772956e2299507c010aea6c8838eb0" + dependencies: + punycode "^2.1.0" + urix@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/urix/-/urix-0.1.0.tgz#da937f7a62e21fec1fd18d49b35c2935067a6c72" @@ -4435,6 +4671,12 @@ wrappy@1: version "1.0.2" resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" +write@1.0.3: + version "1.0.3" + resolved "https://registry.npmjs.org/write/-/write-1.0.3.tgz#0800e14523b923a387e415123c865616aae0f5c3" + dependencies: + mkdirp "^0.5.1" + write@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/write/-/write-0.2.1.tgz#5fc03828e264cea3fe91455476f7a3c566cb0757" From 4e34f1e8f93ead7ef145667ed12a925fbcf5dce9 Mon Sep 17 00:00:00 2001 From: Matt Donnelly Date: Wed, 3 Jul 2019 19:41:15 +0100 Subject: [PATCH 012/146] Remove unneeded babel/register require --- gulpfile.js | 2 -- 1 file changed, 2 deletions(-) diff --git a/gulpfile.js b/gulpfile.js index e54b2c77..1fc6d4d0 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -6,8 +6,6 @@ var istanbul = require('gulp-istanbul'); var plumber = require('gulp-plumber'); var babel = require('gulp-babel'); -require('@babel/register'); - gulp.task('static', function () { return gulp .src('**/*.js') From 64a70a46875313211b2b087459548d3827b44827 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 4 Jul 2019 09:19:55 +0000 Subject: [PATCH 013/146] Bump hoek from 4.2.0 to 4.2.1 Bumps [hoek](https://github.com/hapijs/hoek) from 4.2.0 to 4.2.1. - [Release notes](https://github.com/hapijs/hoek/releases) - [Changelog](https://github.com/hapijs/hoek/blob/master/CHANGELOG.md) - [Commits](https://github.com/hapijs/hoek/compare/v4.2.0...v4.2.1) Signed-off-by: dependabot[bot] --- yarn.lock | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/yarn.lock b/yarn.lock index 74e485fc..3dedd9a0 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2324,8 +2324,8 @@ he@1.1.1: resolved "https://registry.npmjs.org/he/-/he-1.1.1.tgz#93410fd21b009735151f8868c2f271f3427e23fd" hoek@4.x.x: - version "4.2.0" - resolved "https://registry.yarnpkg.com/hoek/-/hoek-4.2.0.tgz#72d9d0754f7fe25ca2d01ad8f8f9a9449a89526d" + version "4.2.1" + resolved "https://registry.yarnpkg.com/hoek/-/hoek-4.2.1.tgz#9634502aa12c445dd5a7c5734b572bb8738aacbb" homedir-polyfill@^1.0.1: version "1.0.1" From 7f20c033723b37ef04a85b9bca148f422d00363f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 4 Jul 2019 09:24:35 +0000 Subject: [PATCH 014/146] Bump extend from 3.0.1 to 3.0.2 Bumps [extend](https://github.com/justmoon/node-extend) from 3.0.1 to 3.0.2. - [Release notes](https://github.com/justmoon/node-extend/releases) - [Changelog](https://github.com/justmoon/node-extend/blob/master/CHANGELOG.md) - [Commits](https://github.com/justmoon/node-extend/compare/v3.0.1...v3.0.2) Signed-off-by: dependabot[bot] --- yarn.lock | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/yarn.lock b/yarn.lock index 3dedd9a0..a4584601 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1728,8 +1728,8 @@ extend-shallow@^3.0.0, extend-shallow@^3.0.2: is-extendable "^1.0.1" extend@^3.0.0, extend@~3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444" + version "3.0.2" + resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa" external-editor@^2.0.4: version "2.2.0" From 1de4e588dc0fbed029045b7fd9ae2665d74b96a3 Mon Sep 17 00:00:00 2001 From: Colin Kennedy Date: Thu, 25 Jul 2019 17:37:40 +0100 Subject: [PATCH 015/146] Upgrading dependencies to remove vulnerabilities Upgrading `lodash` and `request` dependencies to point releases. Upgrading dev dependencies `gulp-instanbul` , `gulp-plumber` and `sinon` to point, or major releases. --- package.json | 10 +- yarn.lock | 674 ++++++++++++++++++--------------------------------- 2 files changed, 236 insertions(+), 448 deletions(-) diff --git a/package.json b/package.json index 67aeb68e..c4ba4ff6 100644 --- a/package.json +++ b/package.json @@ -20,8 +20,8 @@ "dependencies": { "bluebird": "^3.3.4", "htmlencode": "^0.0.4", - "lodash": "^4.17.11", - "request": "^2.83.0" + "lodash": "^4.17.15", + "request": "^2.88.0" }, "devDependencies": { "@babel/core": "^7.4.5", @@ -33,11 +33,11 @@ "gulp-babel": "^8.0.0", "gulp-eslint": "4.0.2", "gulp-exclude-gitignore": "^1.0.0", - "gulp-istanbul": "^0.10.3", + "gulp-istanbul": "^1.1.3", "gulp-mocha": "^6.0.0", - "gulp-plumber": "^1.1.0", + "gulp-plumber": "^1.2.1", "nock": "7.5.0", - "sinon": "^6.1.4" + "sinon": "^7.3.2" }, "scripts": { "prepublish": "gulp prepublish", diff --git a/yarn.lock b/yarn.lock index a4584601..9b5183aa 100644 --- a/yarn.lock +++ b/yarn.lock @@ -560,27 +560,40 @@ lodash "^4.17.11" to-fast-properties "^2.0.0" +"@sinonjs/commons@^1", "@sinonjs/commons@^1.4.0": + version "1.4.0" + resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-1.4.0.tgz#7b3ec2d96af481d7a0321252e7b1c94724ec5a78" + integrity sha512-9jHK3YF/8HtJ9wCAbG+j8cD0i0+ATS9A7gXFqS36TblLPNy6rEEc+SB0imo91eCboGaBYGV/MT1/br/J+EE7Tw== + dependencies: + type-detect "4.0.8" + "@sinonjs/commons@^1.0.2": version "1.3.0" resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-1.3.0.tgz#50a2754016b6f30a994ceda6d9a0a8c36adda849" dependencies: type-detect "4.0.8" -"@sinonjs/formatio@3.0.0", "@sinonjs/formatio@^3.0.0": - version "3.0.0" - resolved "https://registry.yarnpkg.com/@sinonjs/formatio/-/formatio-3.0.0.tgz#9d282d81030a03a03fa0c5ce31fd8786a4da311a" +"@sinonjs/formatio@^3.1.0", "@sinonjs/formatio@^3.2.1": + version "3.2.1" + resolved "https://registry.yarnpkg.com/@sinonjs/formatio/-/formatio-3.2.1.tgz#52310f2f9bcbc67bdac18c94ad4901b95fde267e" + integrity sha512-tsHvOB24rvyvV2+zKMmPkZ7dXX6LSLKZ7aOtXY6Edklp0uRcgGpOsQTTGTcWViFyx4uhWc6GV8QdnALbIbIdeQ== dependencies: - "@sinonjs/samsam" "2.1.0" + "@sinonjs/commons" "^1" + "@sinonjs/samsam" "^3.1.0" -"@sinonjs/samsam@2.1.0": - version "2.1.0" - resolved "https://registry.yarnpkg.com/@sinonjs/samsam/-/samsam-2.1.0.tgz#b8b8f5b819605bd63601a6ede459156880f38ea3" +"@sinonjs/samsam@^3.1.0", "@sinonjs/samsam@^3.3.1": + version "3.3.2" + resolved "https://registry.yarnpkg.com/@sinonjs/samsam/-/samsam-3.3.2.tgz#63942e3d5eb0b79f6de3bef9abfad15fb4b6401b" + integrity sha512-ILO/rR8LfAb60Y1Yfp9vxfYAASK43NFC2mLzpvLUbCQY/Qu8YwReboseu8aheCEkyElZF2L2T9mHcR2bgdvZyA== dependencies: + "@sinonjs/commons" "^1.0.2" array-from "^2.1.1" + lodash "^4.17.11" -"@sinonjs/samsam@^2.1.2": - version "2.1.2" - resolved "https://registry.yarnpkg.com/@sinonjs/samsam/-/samsam-2.1.2.tgz#16947fce5f57258d01f1688fdc32723093c55d3f" +"@sinonjs/text-encoding@^0.7.1": + version "0.7.1" + resolved "https://registry.yarnpkg.com/@sinonjs/text-encoding/-/text-encoding-0.7.1.tgz#8da5c6530915653f3a1f38fd5f101d8c3f8079c5" + integrity sha512-+iTbntw2IZPb/anVDbypzfQa+ay64MW0Zo8aJ8gZPWMMK6/OubMVb6lUPMagqjOPnmtauXnFCACVl3O7ogjeqQ== abbrev@1: version "1.1.1" @@ -616,15 +629,6 @@ ajv-keywords@^2.1.0: version "2.1.1" resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-2.1.1.tgz#617997fc5f60576894c435f940d819e135b80762" -ajv@^5.1.0: - version "5.2.3" - resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.2.3.tgz#c06f598778c44c6b161abafe3466b81ad1814ed2" - dependencies: - co "^4.6.0" - fast-deep-equal "^1.0.0" - json-schema-traverse "^0.3.0" - json-stable-stringify "^1.0.1" - ajv@^5.2.3, ajv@^5.3.0: version "5.5.2" resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.2.tgz#73b5eeca3fab653e3d3f9422b341ad42205dc965" @@ -643,6 +647,16 @@ ajv@^6.10.0, ajv@^6.9.1: json-schema-traverse "^0.4.1" uri-js "^4.2.2" +ajv@^6.5.5: + version "6.10.2" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.10.2.tgz#d3cea04d6b017b2894ad69040fec8b623eb4bd52" + integrity sha512-TXtUUEYHuaTEbLZWIKUr5pmBuhDLy+8KYtPYdcV8qC+pOZL+NKqYwvWSRrVXHn+ZmRRAu8vJTAznH7Oag6RVRw== + dependencies: + fast-deep-equal "^2.0.1" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.4.1" + uri-js "^4.2.2" + amdefine@>=0.0.4: version "1.0.1" resolved "https://registry.yarnpkg.com/amdefine/-/amdefine-1.0.1.tgz#4a5282ac164729e93619bcfd3ad151f817ce91f5" @@ -653,6 +667,13 @@ ansi-colors@^1.0.1: dependencies: ansi-wrap "^0.1.0" +ansi-cyan@^0.1.1: + version "0.1.1" + resolved "https://registry.yarnpkg.com/ansi-cyan/-/ansi-cyan-0.1.1.tgz#538ae528af8982f28ae30d86f2f17456d2609873" + integrity sha1-U4rlKK+JgvKK4w2G8vF0VtJgmHM= + dependencies: + ansi-wrap "0.1.0" + ansi-escapes@^3.0.0, ansi-escapes@^3.2.0: version "3.2.0" resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.2.0.tgz#8780b98ff9dbf5638152d1f1fe5c1d7b4442976b" @@ -663,6 +684,13 @@ ansi-gray@^0.1.1: dependencies: ansi-wrap "0.1.0" +ansi-red@^0.1.1: + version "0.1.1" + resolved "https://registry.yarnpkg.com/ansi-red/-/ansi-red-0.1.1.tgz#8c638f9d1080800a353c9c28c8a81ca4705d946c" + integrity sha1-jGOPnRCAgAo1PJwoyKgcpHBdlGw= + dependencies: + ansi-wrap "0.1.0" + ansi-regex@^2.0.0: version "2.1.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" @@ -723,6 +751,14 @@ argparse@^1.0.7: dependencies: sprintf-js "~1.0.2" +arr-diff@^1.0.1: + version "1.1.0" + resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-1.1.0.tgz#687c32758163588fef7de7b36fabe495eb1a399a" + integrity sha1-aHwydYFjWI/vfeezb6vklesaOZo= + dependencies: + arr-flatten "^1.0.1" + array-slice "^0.2.3" + arr-diff@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-4.0.0.tgz#d6461074febfec71e7e15235761a329a5dc7c520" @@ -743,14 +779,15 @@ arr-map@^2.0.0, arr-map@^2.0.2: dependencies: make-iterator "^1.0.0" +arr-union@^2.0.1: + version "2.1.0" + resolved "https://registry.yarnpkg.com/arr-union/-/arr-union-2.1.0.tgz#20f9eab5ec70f5c7d215b1077b1c39161d292c7d" + integrity sha1-IPnqtexw9cfSFbEHexw5Fh0pLH0= + arr-union@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/arr-union/-/arr-union-3.1.0.tgz#e39b09aea9def866a8f206e288af63919bae39c4" -array-differ@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/array-differ/-/array-differ-1.0.0.tgz#eff52e3758249d33be402b8bb8e564bb2b5d4031" - array-each@^1.0.0, array-each@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/array-each/-/array-each-1.0.1.tgz#a794af0c05ab1752846ee753a1f211a05ba0c44f" @@ -772,6 +809,11 @@ array-last@^1.1.1: dependencies: is-number "^4.0.0" +array-slice@^0.2.3: + version "0.2.3" + resolved "https://registry.yarnpkg.com/array-slice/-/array-slice-0.2.3.tgz#dd3cfb80ed7973a75117cdac69b0b99ec86186f5" + integrity sha1-3Tz7gO15c6dRF82sabC5nshhhvU= + array-slice@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/array-slice/-/array-slice-1.1.0.tgz#e368ea15f89bc7069f7ffb89aec3a6c7d4ac22d4" @@ -784,10 +826,6 @@ array-sort@^1.0.0: get-value "^2.0.6" kind-of "^5.0.2" -array-uniq@^1.0.2: - version "1.0.3" - resolved "https://registry.yarnpkg.com/array-uniq/-/array-uniq-1.0.3.tgz#af6ac877a25cc7f74e058894753858dfdb24fdb6" - array-unique@^0.3.2: version "0.3.2" resolved "https://registry.yarnpkg.com/array-unique/-/array-unique-0.3.2.tgz#a894b75d4bc4f6cd679ef3244a9fd8f46ae2d428" @@ -849,9 +887,10 @@ aws-sign2@~0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz#b46e890934a9591f2d2f6f86d7e6a9f1b3fe76a8" -aws4@^1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.6.0.tgz#83ef5ca860b2b32e4a0deedee8c771b9db57471e" +aws4@^1.8.0: + version "1.8.0" + resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.8.0.tgz#f0e003d9ca9e7f59c7a508945d7b2ef9a04a542f" + integrity sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ== babel-code-frame@^6.22.0: version "6.26.0" @@ -908,10 +947,6 @@ bcrypt-pbkdf@^1.0.0: dependencies: tweetnacl "^0.14.3" -beeper@^1.0.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/beeper/-/beeper-1.1.1.tgz#e6d5ea8c5dad001304a70b22638447f69cb2f809" - binary-extensions@^1.0.0: version "1.13.1" resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-1.13.1.tgz#598afe54755b2868a5330d2aff9d4ebb53209b65" @@ -920,19 +955,7 @@ bluebird@^3.3.4: version "3.5.1" resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.5.1.tgz#d9551f9de98f1fcda1e683d17ee91a0602ee2eb9" -boom@4.x.x: - version "4.3.1" - resolved "https://registry.yarnpkg.com/boom/-/boom-4.3.1.tgz#4f8a3005cb4a7e3889f749030fd25b96e01d2e31" - dependencies: - hoek "4.x.x" - -boom@5.x.x: - version "5.2.0" - resolved "https://registry.yarnpkg.com/boom/-/boom-5.2.0.tgz#5dd9da6ee3a5f302077436290cb717d3f4a54e02" - dependencies: - hoek "4.x.x" - -brace-expansion@^1.0.0, brace-expansion@^1.1.7: +brace-expansion@^1.1.7: version "1.1.8" resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.8.tgz#c07b211c7c952ec1f8efd51a77ef0d1d3990a292" dependencies: @@ -1022,7 +1045,7 @@ caseless@~0.12.0: deep-eql "^0.1.3" type-detect "^1.0.0" -chalk@^1.0.0, chalk@^1.1.1, chalk@^1.1.3: +chalk@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/chalk/-/chalk-1.1.3.tgz#a8115c55e4a702fe4d150abd3872822a7e09fc98" dependencies: @@ -1105,18 +1128,10 @@ clone-buffer@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/clone-buffer/-/clone-buffer-1.0.0.tgz#e3e25b207ac4e701af721e2cb5a16792cac3dc58" -clone-stats@^0.0.1: - version "0.0.1" - resolved "https://registry.yarnpkg.com/clone-stats/-/clone-stats-0.0.1.tgz#b88f94a82cf38b8791d58046ea4029ad88ca99d1" - clone-stats@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/clone-stats/-/clone-stats-1.0.0.tgz#b3782dff8bb5474e18b9b6bf0fdfe782f8777680" -clone@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/clone/-/clone-1.0.2.tgz#260b7a99ebb1edfe247538175f783243cb19d149" - clone@^2.1.1: version "2.1.2" resolved "https://registry.yarnpkg.com/clone/-/clone-2.1.2.tgz#1b7f4b9f591f1e8f83670401600345a02887435f" @@ -1166,9 +1181,10 @@ color-support@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/color-support/-/color-support-1.1.3.tgz#93834379a1cc9a0c61f82f52f0d04322251bd5a2" -combined-stream@^1.0.5, combined-stream@~1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.5.tgz#938370a57b4a51dea2c77c15d5c5fdf895164009" +combined-stream@^1.0.6, combined-stream@~1.0.6: + version "1.0.8" + resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.8.tgz#c3d45a8b34fd730631a110a8a2520682b31d5a7f" + integrity sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg== dependencies: delayed-stream "~1.0.0" @@ -1264,12 +1280,6 @@ cross-spawn@^6.0.0, cross-spawn@^6.0.5: shebang-command "^1.2.0" which "^1.2.9" -cryptiles@3.x.x: - version "3.1.2" - resolved "https://registry.yarnpkg.com/cryptiles/-/cryptiles-3.1.2.tgz#a89fbb220f5ce25ec56e8c4aa8a4fd7b5b0d29fe" - dependencies: - boom "5.x.x" - d@1: version "1.0.1" resolved "https://registry.yarnpkg.com/d/-/d-1.0.1.tgz#8698095372d58dbee346ffd0c7093f99f8f9eb5a" @@ -1287,10 +1297,6 @@ dashdash@^1.12.0: dependencies: assert-plus "^1.0.0" -dateformat@^2.0.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-2.2.0.tgz#4065e2013cf9fb916ddfd82efb506ad4c6769062" - debug@3.1.0: version "3.1.0" resolved "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" @@ -1337,7 +1343,7 @@ deep-extend@^0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/deep-extend/-/deep-extend-0.6.0.tgz#c4fa7c95404a17a9c3e8ca7e1537312b736330ac" -deep-is@~0.1.2, deep-is@~0.1.3: +deep-is@~0.1.3: version "0.1.3" resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34" @@ -1408,12 +1414,6 @@ doctrine@^3.0.0: dependencies: esutils "^2.0.2" -duplexer2@0.0.2: - version "0.0.2" - resolved "https://registry.yarnpkg.com/duplexer2/-/duplexer2-0.0.2.tgz#c614dcf67e2fb14995a91711e5a617e8a60a31db" - dependencies: - readable-stream "~1.1.9" - duplexify@^3.6.0: version "3.7.1" resolved "https://registry.yarnpkg.com/duplexify/-/duplexify-3.7.1.tgz#2a4df5317f6ccfd91f86d6fd25d8d8a103b88309" @@ -1493,17 +1493,6 @@ escape-string-regexp@1.0.5, escape-string-regexp@^1.0.2, escape-string-regexp@^1 version "1.0.5" resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" -escodegen@1.7.x: - version "1.7.1" - resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.7.1.tgz#30ecfcf66ca98dc67cd2fd162abeb6eafa8ce6fc" - dependencies: - esprima "^1.2.2" - estraverse "^1.9.1" - esutils "^2.0.2" - optionator "^0.5.0" - optionalDependencies: - source-map "~0.2.0" - escodegen@1.8.x: version "1.8.1" resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.8.1.tgz#5a5b53af4693110bebb0867aa3430dd3b70a1018" @@ -1643,18 +1632,10 @@ espree@^6.0.0: acorn-jsx "^5.0.0" eslint-visitor-keys "^1.0.0" -esprima@2.5.x: - version "2.5.0" - resolved "https://registry.yarnpkg.com/esprima/-/esprima-2.5.0.tgz#f387a46fd344c1b1a39baf8c20bfb43b6d0058cc" - esprima@2.7.x, esprima@^2.7.1: version "2.7.3" resolved "https://registry.yarnpkg.com/esprima/-/esprima-2.7.3.tgz#96e3b70d5779f6ad49cd032673d1c312767ba581" -esprima@^1.2.2: - version "1.2.5" - resolved "https://registry.yarnpkg.com/esprima/-/esprima-1.2.5.tgz#0993502feaf668138325756f30f9a51feeec11e9" - esprima@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" @@ -1714,6 +1695,13 @@ expand-tilde@^2.0.0, expand-tilde@^2.0.2: dependencies: homedir-polyfill "^1.0.1" +extend-shallow@^1.1.2: + version "1.1.4" + resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-1.1.4.tgz#19d6bf94dfc09d76ba711f39b872d21ff4dd9071" + integrity sha1-Gda/lN/AnXa6cR85uHLSH/TdkHE= + dependencies: + kind-of "^1.1.0" + extend-shallow@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-2.0.1.tgz#51af7d614ad9a9f610ea1bafbb989d6b1c56890f" @@ -1727,9 +1715,10 @@ extend-shallow@^3.0.0, extend-shallow@^3.0.2: assign-symbols "^1.0.0" is-extendable "^1.0.1" -extend@^3.0.0, extend@~3.0.1: +extend@^3.0.0, extend@~3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa" + integrity sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g== external-editor@^2.0.4: version "2.2.0" @@ -1764,13 +1753,6 @@ extsprintf@1.3.0, extsprintf@^1.2.0: version "1.3.0" resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz#96918440e3041a7a414f8c52e3c574eb3c3e1e05" -fancy-log@^1.1.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/fancy-log/-/fancy-log-1.3.0.tgz#45be17d02bb9917d60ccffd4995c999e6c8c9948" - dependencies: - chalk "^1.1.1" - time-stamp "^1.0.0" - fancy-log@^1.3.2: version "1.3.3" resolved "https://registry.yarnpkg.com/fancy-log/-/fancy-log-1.3.3.tgz#dbc19154f558690150a23953a0adbd035be45fc7" @@ -1792,10 +1774,6 @@ fast-json-stable-stringify@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" -fast-levenshtein@~1.0.0: - version "1.0.7" - resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-1.0.7.tgz#0178dcdee023b92905193af0959e8a7639cfdcb9" - fast-levenshtein@~2.0.4: version "2.0.6" resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" @@ -1819,13 +1797,6 @@ file-entry-cache@^5.0.1: dependencies: flat-cache "^2.0.1" -fileset@0.2.x: - version "0.2.1" - resolved "https://registry.yarnpkg.com/fileset/-/fileset-0.2.1.tgz#588ef8973c6623b2a76df465105696b96aac8067" - dependencies: - glob "5.x" - minimatch "2.x" - fill-range@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-4.0.0.tgz#d544811d428f98eb06a63dc402d2403c328c38f7" @@ -1930,12 +1901,13 @@ forever-agent@~0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" -form-data@~2.3.1: - version "2.3.1" - resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.1.tgz#6fb94fbd71885306d73d15cc497fe4cc4ecd44bf" +form-data@~2.3.2: + version "2.3.3" + resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.3.tgz#dcce52c05f644f298c6a7ab936bd724ceffbf3a6" + integrity sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ== dependencies: asynckit "^0.4.0" - combined-stream "^1.0.5" + combined-stream "^1.0.6" mime-types "^2.1.12" fragment-cache@^0.2.1: @@ -2040,24 +2012,24 @@ glob-watcher@^5.0.3: just-debounce "^1.0.0" object.defaults "^1.1.0" -glob@5.x, glob@^5.0.15: - version "5.0.15" - resolved "https://registry.yarnpkg.com/glob/-/glob-5.0.15.tgz#1bc936b9e02f4a603fcc222ecf7633d30b8b93b1" +glob@7.1.2: + version "7.1.2" + resolved "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15" dependencies: + fs.realpath "^1.0.0" inflight "^1.0.4" inherits "2" - minimatch "2 || 3" + minimatch "^3.0.4" once "^1.3.0" path-is-absolute "^1.0.0" -glob@7.1.2: - version "7.1.2" - resolved "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15" +glob@^5.0.15: + version "5.0.15" + resolved "https://registry.yarnpkg.com/glob/-/glob-5.0.15.tgz#1bc936b9e02f4a603fcc222ecf7633d30b8b93b1" dependencies: - fs.realpath "^1.0.0" inflight "^1.0.4" inherits "2" - minimatch "^3.0.4" + minimatch "2 || 3" once "^1.3.0" path-is-absolute "^1.0.0" @@ -2161,15 +2133,17 @@ gulp-ignore@^2.0.2: gulp-match "^1.0.3" through2 "^2.0.1" -gulp-istanbul@^0.10.3: - version "0.10.4" - resolved "https://registry.yarnpkg.com/gulp-istanbul/-/gulp-istanbul-0.10.4.tgz#2b2a1bcbeb96a62c78e69821d104d6fca32efb09" +gulp-istanbul@^1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/gulp-istanbul/-/gulp-istanbul-1.1.3.tgz#669a21516adb2540de798be26faee843ade8f20f" + integrity sha512-uMLSdqPDnBAV/B9rNyOgVMgrVC1tPbe+5GH6P13UOyxbRDT/w4sKYHWftPMA8j9om+NFvfeRlqpDXL2fixFWNA== dependencies: - gulp-util "^3.0.1" istanbul "^0.4.0" - istanbul-threshold-checker "^0.1.0" + istanbul-threshold-checker "^0.2.1" lodash "^4.0.0" + plugin-error "^0.1.2" through2 "^2.0.0" + vinyl-sourcemaps-apply "^0.2.1" gulp-match@^1.0.3: version "1.0.3" @@ -2189,35 +2163,15 @@ gulp-mocha@^6.0.0: supports-color "^5.4.0" through2 "^2.0.3" -gulp-plumber@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/gulp-plumber/-/gulp-plumber-1.1.0.tgz#f12176c2d0422f60306c242fff6a01a394faba09" - dependencies: - gulp-util "^3" - through2 "^2" - -gulp-util@^3, gulp-util@^3.0.1: - version "3.0.8" - resolved "https://registry.yarnpkg.com/gulp-util/-/gulp-util-3.0.8.tgz#0054e1e744502e27c04c187c3ecc505dd54bbb4f" +gulp-plumber@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/gulp-plumber/-/gulp-plumber-1.2.1.tgz#d38700755a300b9d372318e4ffb5ff7ced0b2c84" + integrity sha512-mctAi9msEAG7XzW5ytDVZ9PxWMzzi1pS2rBH7lA095DhMa6KEXjm+St0GOCc567pJKJ/oCvosVAZEpAey0q2eQ== dependencies: - array-differ "^1.0.0" - array-uniq "^1.0.2" - beeper "^1.0.0" - chalk "^1.0.0" - dateformat "^2.0.0" - fancy-log "^1.1.0" - gulplog "^1.0.0" - has-gulplog "^0.1.0" - lodash._reescape "^3.0.0" - lodash._reevaluate "^3.0.0" - lodash._reinterpolate "^3.0.0" - lodash.template "^3.0.0" - minimist "^1.1.0" - multipipe "^0.1.2" - object-assign "^3.0.0" - replace-ext "0.0.1" - through2 "^2.0.0" - vinyl "^0.5.0" + chalk "^1.1.3" + fancy-log "^1.3.2" + plugin-error "^0.1.2" + through2 "^2.0.3" gulp@^4.0.2: version "4.0.2" @@ -2248,11 +2202,12 @@ har-schema@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" -har-validator@~5.0.3: - version "5.0.3" - resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.0.3.tgz#ba402c266194f15956ef15e0fcf242993f6a7dfd" +har-validator@~5.1.0: + version "5.1.3" + resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.1.3.tgz#1ef89ebd3e4996557675eed9893110dc350fa080" + integrity sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g== dependencies: - ajv "^5.1.0" + ajv "^6.5.5" har-schema "^2.0.0" has-ansi@^2.0.0: @@ -2269,12 +2224,6 @@ has-flag@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" -has-gulplog@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/has-gulplog/-/has-gulplog-0.1.0.tgz#6414c82913697da51590397dafb12f22967811ce" - dependencies: - sparkles "^1.0.0" - has-symbols@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.0.tgz#ba1a8f1af2a0fc39650f5c850367704122063b44" @@ -2310,23 +2259,10 @@ has-values@^1.0.0: is-number "^3.0.0" kind-of "^4.0.0" -hawk@~6.0.2: - version "6.0.2" - resolved "https://registry.yarnpkg.com/hawk/-/hawk-6.0.2.tgz#af4d914eb065f9b5ce4d9d11c1cb2126eecc3038" - dependencies: - boom "4.x.x" - cryptiles "3.x.x" - hoek "4.x.x" - sntp "2.x.x" - he@1.1.1: version "1.1.1" resolved "https://registry.npmjs.org/he/-/he-1.1.1.tgz#93410fd21b009735151f8868c2f271f3427e23fd" -hoek@4.x.x: - version "4.2.1" - resolved "https://registry.yarnpkg.com/hoek/-/hoek-4.2.1.tgz#9634502aa12c445dd5a7c5734b572bb8738aacbb" - homedir-polyfill@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/homedir-polyfill/-/homedir-polyfill-1.0.1.tgz#4c2bbc8a758998feebf5ed68580f76d46768b4bc" @@ -2387,7 +2323,7 @@ inflight@^1.0.4: once "^1.3.0" wrappy "1" -inherits@2, inherits@^2.0.3, inherits@~2.0.1, inherits@~2.0.3: +inherits@2, inherits@^2.0.3, inherits@~2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de" @@ -2639,33 +2575,15 @@ isstream@~0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" -istanbul-threshold-checker@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/istanbul-threshold-checker/-/istanbul-threshold-checker-0.1.0.tgz#0e1442c017cb27a85f781734fefd2126405ca39c" +istanbul-threshold-checker@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/istanbul-threshold-checker/-/istanbul-threshold-checker-0.2.1.tgz#c5dc94e8f2cc5cd3ffd335452f84b553c4248331" + integrity sha1-xdyU6PLMXNP/0zVFL4S1U8QkgzE= dependencies: - istanbul "0.3.*" - lodash "3.6.*" + istanbul "~0.4.5" + lodash "~4.17.2" -istanbul@0.3.*: - version "0.3.22" - resolved "https://registry.yarnpkg.com/istanbul/-/istanbul-0.3.22.tgz#3e164d85021fe19c985d1f0e7ef0c3e22d012eb6" - dependencies: - abbrev "1.0.x" - async "1.x" - escodegen "1.7.x" - esprima "2.5.x" - fileset "0.2.x" - handlebars "^4.0.1" - js-yaml "3.x" - mkdirp "0.5.x" - nopt "3.x" - once "1.x" - resolve "1.1.x" - supports-color "^3.1.0" - which "^1.1.1" - wordwrap "^1.0.0" - -istanbul@^0.4.0: +istanbul@^0.4.0, istanbul@~0.4.5: version "0.4.5" resolved "https://registry.yarnpkg.com/istanbul/-/istanbul-0.4.5.tgz#65c7d73d4c4da84d4f3ac310b918fb0b8033733b" dependencies: @@ -2731,12 +2649,6 @@ json-stable-stringify-without-jsonify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" -json-stable-stringify@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz#9a759d39c5f2ff503fd5300646ed445f88c4f9af" - dependencies: - jsonify "~0.0.0" - json-stringify-safe@^5.0.1, json-stringify-safe@~5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" @@ -2747,10 +2659,6 @@ json5@^2.1.0: dependencies: minimist "^1.2.0" -jsonify@~0.0.0: - version "0.0.0" - resolved "https://registry.yarnpkg.com/jsonify/-/jsonify-0.0.0.tgz#2c74b6ee41d93ca51b7b5aaee8f503631d252a73" - jsprim@^1.2.2: version "1.4.1" resolved "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.1.tgz#313e66bc1e5cc06e438bc1b7499c2e5c56acb6a2" @@ -2764,9 +2672,15 @@ just-debounce@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/just-debounce/-/just-debounce-1.0.0.tgz#87fccfaeffc0b68cd19d55f6722943f929ea35ea" -just-extend@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/just-extend/-/just-extend-3.0.0.tgz#cee004031eaabf6406da03a7b84e4fe9d78ef288" +just-extend@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/just-extend/-/just-extend-4.0.2.tgz#f3f47f7dfca0f989c55410a7ebc8854b07108afc" + integrity sha512-FrLwOgm+iXrPV+5zDU6Jqu4gCRXbWEQg2O3SKONsWE4w7AXFRkryS53bpWdaL9cNol+AmR3AEYz6kn+o0fCPnw== + +kind-of@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-1.1.0.tgz#140a3d2d41a36d2efcfa9377b62c24f8495a5c44" + integrity sha1-FAo9LUGjbS78+pN3tiwk+ElaXEQ= kind-of@^3.0.2, kind-of@^3.0.3, kind-of@^3.2.0: version "3.2.2" @@ -2820,13 +2734,6 @@ levn@^0.3.0, levn@~0.3.0: prelude-ls "~1.1.2" type-check "~0.3.2" -levn@~0.2.5: - version "0.2.5" - resolved "https://registry.yarnpkg.com/levn/-/levn-0.2.5.tgz#ba8d339d0ca4a610e3a3f145b9caf48807155054" - dependencies: - prelude-ls "~1.1.0" - type-check "~0.3.1" - liftoff@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/liftoff/-/liftoff-3.1.0.tgz#c9ba6081f908670607ee79062d700df062c52ed3" @@ -2857,97 +2764,6 @@ locate-path@^3.0.0: p-locate "^3.0.0" path-exists "^3.0.0" -lodash._basecopy@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/lodash._basecopy/-/lodash._basecopy-3.0.1.tgz#8da0e6a876cf344c0ad8a54882111dd3c5c7ca36" - -lodash._basetostring@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/lodash._basetostring/-/lodash._basetostring-3.0.1.tgz#d1861d877f824a52f669832dcaf3ee15566a07d5" - -lodash._basevalues@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/lodash._basevalues/-/lodash._basevalues-3.0.0.tgz#5b775762802bde3d3297503e26300820fdf661b7" - -lodash._getnative@^3.0.0: - version "3.9.1" - resolved "https://registry.yarnpkg.com/lodash._getnative/-/lodash._getnative-3.9.1.tgz#570bc7dede46d61cdcde687d65d3eecbaa3aaff5" - -lodash._isiterateecall@^3.0.0: - version "3.0.9" - resolved "https://registry.yarnpkg.com/lodash._isiterateecall/-/lodash._isiterateecall-3.0.9.tgz#5203ad7ba425fae842460e696db9cf3e6aac057c" - -lodash._reescape@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/lodash._reescape/-/lodash._reescape-3.0.0.tgz#2b1d6f5dfe07c8a355753e5f27fac7f1cde1616a" - -lodash._reevaluate@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/lodash._reevaluate/-/lodash._reevaluate-3.0.0.tgz#58bc74c40664953ae0b124d806996daca431e2ed" - -lodash._reinterpolate@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/lodash._reinterpolate/-/lodash._reinterpolate-3.0.0.tgz#0ccf2d89166af03b3663c796538b75ac6e114d9d" - -lodash._root@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/lodash._root/-/lodash._root-3.0.1.tgz#fba1c4524c19ee9a5f8136b4609f017cf4ded692" - -lodash.escape@^3.0.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/lodash.escape/-/lodash.escape-3.2.0.tgz#995ee0dc18c1b48cc92effae71a10aab5b487698" - dependencies: - lodash._root "^3.0.0" - -lodash.get@^4.4.2: - version "4.4.2" - resolved "https://registry.yarnpkg.com/lodash.get/-/lodash.get-4.4.2.tgz#2d177f652fa31e939b4438d5341499dfa3825e99" - -lodash.isarguments@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/lodash.isarguments/-/lodash.isarguments-3.1.0.tgz#2f573d85c6a24289ff00663b491c1d338ff3458a" - -lodash.isarray@^3.0.0: - version "3.0.4" - resolved "https://registry.yarnpkg.com/lodash.isarray/-/lodash.isarray-3.0.4.tgz#79e4eb88c36a8122af86f844aa9bcd851b5fbb55" - -lodash.keys@^3.0.0: - version "3.1.2" - resolved "https://registry.yarnpkg.com/lodash.keys/-/lodash.keys-3.1.2.tgz#4dbc0472b156be50a0b286855d1bd0b0c656098a" - dependencies: - lodash._getnative "^3.0.0" - lodash.isarguments "^3.0.0" - lodash.isarray "^3.0.0" - -lodash.restparam@^3.0.0: - version "3.6.1" - resolved "https://registry.yarnpkg.com/lodash.restparam/-/lodash.restparam-3.6.1.tgz#936a4e309ef330a7645ed4145986c85ae5b20805" - -lodash.template@^3.0.0: - version "3.6.2" - resolved "https://registry.yarnpkg.com/lodash.template/-/lodash.template-3.6.2.tgz#f8cdecc6169a255be9098ae8b0c53d378931d14f" - dependencies: - lodash._basecopy "^3.0.0" - lodash._basetostring "^3.0.0" - lodash._basevalues "^3.0.0" - lodash._isiterateecall "^3.0.0" - lodash._reinterpolate "^3.0.0" - lodash.escape "^3.0.0" - lodash.keys "^3.0.0" - lodash.restparam "^3.0.0" - lodash.templatesettings "^3.0.0" - -lodash.templatesettings@^3.0.0: - version "3.1.1" - resolved "https://registry.yarnpkg.com/lodash.templatesettings/-/lodash.templatesettings-3.1.1.tgz#fb307844753b66b9f1afa54e262c745307dba8e5" - dependencies: - lodash._reinterpolate "^3.0.0" - lodash.escape "^3.0.0" - -lodash@3.6.*: - version "3.6.0" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.6.0.tgz#5266a8f49dd989be4f9f681b6f2a0c55285d0d9a" - lodash@^3.10.1: version "3.10.1" resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.10.1.tgz#5bf45e8e49ba4189e17d482789dfd15bd140b7b6" @@ -2960,13 +2776,15 @@ lodash@^4.17.11, lodash@^4.3.0: version "4.17.11" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.11.tgz#b39ea6229ef607ecd89e2c8df12536891cac9b8d" -lolex@^2.3.2: - version "2.3.2" - resolved "https://registry.yarnpkg.com/lolex/-/lolex-2.3.2.tgz#85f9450425103bf9e7a60668ea25dc43274ca807" +lodash@^4.17.15, lodash@~4.17.2: + version "4.17.15" + resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.15.tgz#b447f6670a0455bbfeedd11392eff330ea097548" + integrity sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A== -lolex@^2.7.5: - version "2.7.5" - resolved "https://registry.yarnpkg.com/lolex/-/lolex-2.7.5.tgz#113001d56bfc7e02d56e36291cc5c413d1aa0733" +lolex@^4.0.1, lolex@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/lolex/-/lolex-4.1.0.tgz#ecdd7b86539391d8237947a3419aa8ac975f0fe1" + integrity sha512-BYxIEXiVq5lGIXeVHnsFzqa1TxN5acnKnPCdlZSpzm8viNEOhiigupA4vTQ9HEFQ6nLTQ9wQOgBknJgzUYQ9Aw== loose-envify@^1.0.0: version "1.3.1" @@ -3031,16 +2849,28 @@ micromatch@^3.0.4, micromatch@^3.1.10, micromatch@^3.1.4: snapdragon "^0.8.1" to-regex "^3.0.2" +mime-db@1.40.0: + version "1.40.0" + resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.40.0.tgz#a65057e998db090f732a68f6c276d387d4126c32" + integrity sha512-jYdeOMPy9vnxEqFRRo6ZvTZ8d9oPb+k18PKoYNYUe2stVEBPPwsln/qWzdbmaIvnhZ9v2P+CuecK+fpUfsV2mA== + mime-db@~1.30.0: version "1.30.0" resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.30.0.tgz#74c643da2dd9d6a45399963465b26d5ca7d71f01" -mime-types@^2.1.12, mime-types@~2.1.17: +mime-types@^2.1.12: version "2.1.17" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.17.tgz#09d7a393f03e995a79f8af857b70a9e0ab16557a" dependencies: mime-db "~1.30.0" +mime-types@~2.1.19: + version "2.1.24" + resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.24.tgz#b6f8d0b3e951efb77dedeca194cff6d16f676f81" + integrity sha512-WaFHS3MCl5fapm3oLxU4eYDw77IQM2ACcxQ9RIxfaC3ooc6PFuBMGZZsYpvoXS5D5QTWPieo1jjLdAm3TBP3cQ== + dependencies: + mime-db "1.40.0" + mimic-fn@^1.0.0: version "1.2.0" resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" @@ -3051,17 +2881,11 @@ mimic-fn@^1.0.0: dependencies: brace-expansion "^1.1.7" -minimatch@2.x: - version "2.0.10" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-2.0.10.tgz#8d087c39c6b38c001b97fca7ce6d0e1e80afbac7" - dependencies: - brace-expansion "^1.0.0" - minimist@0.0.8: version "0.0.8" resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d" -minimist@^1.1.0, minimist@^1.2.0: +minimist@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284" @@ -3119,12 +2943,6 @@ ms@^2.1.1: version "2.1.2" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" -multipipe@^0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/multipipe/-/multipipe-0.1.2.tgz#2a8f2ddf70eed564dff2d57f1e1a137d9f05078b" - dependencies: - duplexer2 "0.0.2" - mute-stdout@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/mute-stdout/-/mute-stdout-1.0.1.tgz#acb0300eb4de23a7ddeec014e3e96044b3472331" @@ -3178,15 +2996,16 @@ nice-try@^1.0.4: version "1.0.5" resolved "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz#a3378a7696ce7d223e88fc9b764bd7ef1089e366" -nise@^1.4.5: - version "1.4.6" - resolved "https://registry.yarnpkg.com/nise/-/nise-1.4.6.tgz#76cc3915925056ae6c405dd8ad5d12bde570c19f" +nise@^1.4.10: + version "1.5.0" + resolved "https://registry.yarnpkg.com/nise/-/nise-1.5.0.tgz#d03ea0e6c1b75c638015aa3585eddc132949a50d" + integrity sha512-Z3sfYEkLFzFmL8KY6xnSJLRxwQwYBjOXi/24lb62ZnZiGA0JUzGGTI6TBIgfCSMIDl9Jlu8SRmHNACLTemDHww== dependencies: - "@sinonjs/formatio" "3.0.0" - just-extend "^3.0.0" - lolex "^2.3.2" + "@sinonjs/formatio" "^3.1.0" + "@sinonjs/text-encoding" "^0.7.1" + just-extend "^4.0.2" + lolex "^4.1.0" path-to-regexp "^1.7.0" - text-encoding "^0.6.4" nock@7.5.0: version "7.5.0" @@ -3294,13 +3113,10 @@ number-is-nan@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" -oauth-sign@~0.8.2: - version "0.8.2" - resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.8.2.tgz#46a6ab7f0aead8deae9ec0565780b7d4efeb9d43" - -object-assign@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-3.0.0.tgz#9bedd5ca0897949bca47e7ff408062d549f587f2" +oauth-sign@~0.9.0: + version "0.9.0" + resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.9.0.tgz#47a7b016baa68b5fa0ecf3dee08a85c679ac6455" + integrity sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ== object-assign@^4.0.1, object-assign@^4.1.0: version "4.1.1" @@ -3381,17 +3197,6 @@ optimist@^0.6.1: minimist "~0.0.1" wordwrap "~0.0.2" -optionator@^0.5.0: - version "0.5.0" - resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.5.0.tgz#b75a8995a2d417df25b6e4e3862f50aa88651368" - dependencies: - deep-is "~0.1.2" - fast-levenshtein "~1.0.0" - levn "~0.2.5" - prelude-ls "~1.1.1" - type-check "~0.3.1" - wordwrap "~0.0.2" - optionator@^0.8.1, optionator@^0.8.2: version "0.8.2" resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.2.tgz#364c5e409d3f4d6301d6c0b4c05bba50180aeb64" @@ -3574,6 +3379,17 @@ pkg-dir@^3.0.0: dependencies: find-up "^3.0.0" +plugin-error@^0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/plugin-error/-/plugin-error-0.1.2.tgz#3b9bb3335ccf00f425e07437e19276967da47ace" + integrity sha1-O5uzM1zPAPQl4HQ34ZJ2ln2kes4= + dependencies: + ansi-cyan "^0.1.1" + ansi-red "^0.1.1" + arr-diff "^1.0.1" + arr-union "^2.0.1" + extend-shallow "^1.1.2" + plugin-error@^1.0.0, plugin-error@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/plugin-error/-/plugin-error-1.0.1.tgz#77016bd8919d0ac377fdcdd0322328953ca5781c" @@ -3591,7 +3407,7 @@ posix-character-classes@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/posix-character-classes/-/posix-character-classes-0.1.1.tgz#01eac0fe3b5af71a2a6c02feabb8c1fef7e00eab" -prelude-ls@~1.1.0, prelude-ls@~1.1.1, prelude-ls@~1.1.2: +prelude-ls@~1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54" @@ -3623,6 +3439,11 @@ pseudomap@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3" +psl@^1.1.24: + version "1.2.0" + resolved "https://registry.yarnpkg.com/psl/-/psl-1.2.0.tgz#df12b5b1b3a30f51c329eacbdef98f3a6e136dc6" + integrity sha512-GEn74ZffufCmkDDLNcl3uuyF/aSD6exEyh1v/ZSdAomB82t6G9hzJVRx0jBmLDW+VfZqks3aScmMw9DszwUalA== + pump@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/pump/-/pump-2.0.1.tgz#12399add6e4cf7526d973cbc8b5ce2e2908b3909" @@ -3646,10 +3467,15 @@ punycode@^2.1.0: version "2.1.1" resolved "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" -qs@^6.0.2, qs@~6.5.1: +qs@^6.0.2: version "6.5.1" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8" +qs@~6.5.2: + version "6.5.2" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" + integrity sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA== + rc@^1.2.7: version "1.2.8" resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.8.tgz#cd924bf5200a075b83c188cd6b9e211b7fc0d3ed" @@ -3698,15 +3524,6 @@ readable-stream@^2.1.5, readable-stream@^2.2.2: string_decoder "~1.0.3" util-deprecate "~1.0.1" -readable-stream@~1.1.9: - version "1.1.14" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.1.14.tgz#7cf4c54ef648e3813084c636dd2079e166c081d9" - dependencies: - core-util-is "~1.0.0" - inherits "~2.0.1" - isarray "0.0.1" - string_decoder "~0.10.x" - readdirp@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-2.2.1.tgz#0e87622a3325aa33e892285caf8b4e846529a525" @@ -3804,10 +3621,6 @@ repeat-string@^1.6.1: version "1.6.1" resolved "https://registry.yarnpkg.com/repeat-string/-/repeat-string-1.6.1.tgz#8dcae470e1c88abc2d600fff4a776286da75e637" -replace-ext@0.0.1: - version "0.0.1" - resolved "https://registry.yarnpkg.com/replace-ext/-/replace-ext-0.0.1.tgz#29bbd92078a739f0bcce2b4ee41e837953522924" - replace-ext@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/replace-ext/-/replace-ext-1.0.0.tgz#de63128373fcbf7c3ccfa4de5a480c45a67958eb" @@ -3820,32 +3633,31 @@ replace-homedir@^1.0.0: is-absolute "^1.0.0" remove-trailing-separator "^1.1.0" -request@^2.83.0: - version "2.83.0" - resolved "https://registry.yarnpkg.com/request/-/request-2.83.0.tgz#ca0b65da02ed62935887808e6f510381034e3356" +request@^2.88.0: + version "2.88.0" + resolved "https://registry.yarnpkg.com/request/-/request-2.88.0.tgz#9c2fca4f7d35b592efe57c7f0a55e81052124fef" + integrity sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg== dependencies: aws-sign2 "~0.7.0" - aws4 "^1.6.0" + aws4 "^1.8.0" caseless "~0.12.0" - combined-stream "~1.0.5" - extend "~3.0.1" + combined-stream "~1.0.6" + extend "~3.0.2" forever-agent "~0.6.1" - form-data "~2.3.1" - har-validator "~5.0.3" - hawk "~6.0.2" + form-data "~2.3.2" + har-validator "~5.1.0" http-signature "~1.2.0" is-typedarray "~1.0.0" isstream "~0.1.2" json-stringify-safe "~5.0.1" - mime-types "~2.1.17" - oauth-sign "~0.8.2" + mime-types "~2.1.19" + oauth-sign "~0.9.0" performance-now "^2.1.0" - qs "~6.5.1" - safe-buffer "^5.1.1" - stringstream "~0.0.5" - tough-cookie "~2.3.3" + qs "~6.5.2" + safe-buffer "^5.1.2" + tough-cookie "~2.4.3" tunnel-agent "^0.6.0" - uuid "^3.1.0" + uuid "^3.3.2" require-directory@^2.1.1: version "2.1.1" @@ -3942,7 +3754,7 @@ rxjs@^6.4.0: dependencies: tslib "^1.9.0" -safe-buffer@^5.0.1, safe-buffer@^5.1.1, safe-buffer@~5.1.0, safe-buffer@~5.1.1: +safe-buffer@^5.0.1, safe-buffer@~5.1.0, safe-buffer@~5.1.1: version "5.1.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.1.tgz#893312af69b2123def71f57889001671eeb2c853" @@ -4014,19 +3826,18 @@ signal-exit@^3.0.0, signal-exit@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d" -sinon@^6.1.4: - version "6.3.5" - resolved "https://registry.yarnpkg.com/sinon/-/sinon-6.3.5.tgz#0f6d6a5b4ebaad1f6e8e019395542d1d02c144a0" +sinon@^7.3.2: + version "7.3.2" + resolved "https://registry.yarnpkg.com/sinon/-/sinon-7.3.2.tgz#82dba3a6d85f6d2181e1eca2c10d8657c2161f28" + integrity sha512-thErC1z64BeyGiPvF8aoSg0LEnptSaWE7YhdWWbWXgelOyThent7uKOnnEh9zBxDbKixtr5dEko+ws1sZMuFMA== dependencies: - "@sinonjs/commons" "^1.0.2" - "@sinonjs/formatio" "^3.0.0" - "@sinonjs/samsam" "^2.1.2" + "@sinonjs/commons" "^1.4.0" + "@sinonjs/formatio" "^3.2.1" + "@sinonjs/samsam" "^3.3.1" diff "^3.5.0" - lodash.get "^4.4.2" - lolex "^2.7.5" - nise "^1.4.5" + lolex "^4.0.1" + nise "^1.4.10" supports-color "^5.5.0" - type-detect "^4.0.8" slice-ansi@1.0.0: version "1.0.0" @@ -4069,12 +3880,6 @@ snapdragon@^0.8.1: source-map-resolve "^0.5.0" use "^3.1.0" -sntp@2.x.x: - version "2.0.2" - resolved "https://registry.yarnpkg.com/sntp/-/sntp-2.0.2.tgz#5064110f0af85f7cfdb7d6b67a40028ce52b4b2b" - dependencies: - hoek "4.x.x" - source-map-resolve@^0.5.0: version "0.5.1" resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.1.tgz#7ad0f593f2281598e854df80f19aae4b92d7a11a" @@ -4202,10 +4007,6 @@ string-width@^3.0.0: is-fullwidth-code-point "^2.0.0" strip-ansi "^5.1.0" -string_decoder@~0.10.x: - version "0.10.31" - resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94" - string_decoder@~1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.0.3.tgz#0fc67d7c141825de94282dd536bec6b9bce860ab" @@ -4218,10 +4019,6 @@ string_decoder@~1.1.1: dependencies: safe-buffer "~5.1.0" -stringstream@~0.0.5: - version "0.0.6" - resolved "https://registry.yarnpkg.com/stringstream/-/stringstream-0.0.6.tgz#7880225b0d4ad10e30927d167a1d6f2fd3b33a72" - strip-ansi@^3.0.0, strip-ansi@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf" @@ -4315,10 +4112,6 @@ tar@^4: safe-buffer "^5.1.2" yallist "^3.0.3" -text-encoding@^0.6.4: - version "0.6.4" - resolved "https://registry.yarnpkg.com/text-encoding/-/text-encoding-0.6.4.tgz#e399a982257a276dae428bb92845cb71bdc26d19" - text-table@^0.2.0, text-table@~0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" @@ -4330,7 +4123,7 @@ through2-filter@^3.0.0: through2 "~2.0.0" xtend "~4.0.0" -through2@^2, through2@^2.0.0, through2@^2.0.1: +through2@^2.0.0, through2@^2.0.1: version "2.0.3" resolved "https://registry.yarnpkg.com/through2/-/through2-2.0.3.tgz#0004569b37c7c74ba39c43f3ced78d1ad94140be" dependencies: @@ -4397,10 +4190,12 @@ to-through@^2.0.0: dependencies: through2 "^2.0.3" -tough-cookie@~2.3.3: - version "2.3.3" - resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.3.tgz#0b618a5565b6dea90bf3425d04d55edc475a7561" +tough-cookie@~2.4.3: + version "2.4.3" + resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.4.3.tgz#53f36da3f47783b0925afa06ff9f3b165280f781" + integrity sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ== dependencies: + psl "^1.1.24" punycode "^1.4.1" trim-right@^1.0.1: @@ -4421,7 +4216,7 @@ tweetnacl@^0.14.3, tweetnacl@~0.14.0: version "0.14.5" resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64" -type-check@~0.3.1, type-check@~0.3.2: +type-check@~0.3.2: version "0.3.2" resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.3.2.tgz#5884cab512cf1d355e3fb784f30804b2b520db72" dependencies: @@ -4431,7 +4226,7 @@ type-detect@0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-0.1.1.tgz#0ba5ec2a885640e470ea4e8505971900dac58822" -type-detect@4.0.8, type-detect@^4.0.8: +type-detect@4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c" @@ -4542,9 +4337,10 @@ util-deprecate@~1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" -uuid@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.1.0.tgz#3dd3d3e790abc24d7b0d3a034ffababe28ebbc04" +uuid@^3.3.2: + version "3.3.2" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.3.2.tgz#1b4af4955eb3077c501c23872fc6513811587131" + integrity sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA== v8flags@^3.0.1: version "3.1.3" @@ -4605,20 +4401,12 @@ vinyl-sourcemap@^1.1.0: remove-bom-buffer "^3.0.0" vinyl "^2.0.0" -vinyl-sourcemaps-apply@^0.2.0: +vinyl-sourcemaps-apply@^0.2.0, vinyl-sourcemaps-apply@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/vinyl-sourcemaps-apply/-/vinyl-sourcemaps-apply-0.2.1.tgz#ab6549d61d172c2b1b87be5c508d239c8ef87705" dependencies: source-map "^0.5.1" -vinyl@^0.5.0: - version "0.5.3" - resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-0.5.3.tgz#b0455b38fc5e0cf30d4325132e461970c2091cde" - dependencies: - clone "^1.0.0" - clone-stats "^0.0.1" - replace-ext "0.0.1" - vinyl@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-2.2.0.tgz#d85b07da96e458d25b2ffe19fece9f2caa13ed86" From 4e6cc606e841c95fcab99b763baa14c033b28827 Mon Sep 17 00:00:00 2001 From: Alexandre Passant Date: Wed, 31 Jul 2019 18:26:47 +0200 Subject: [PATCH 016/146] Add customer search (#252) --- README.md | 10 ++++++++++ lib/client.js | 2 ++ lib/customer.js | 8 ++++++++ test/customer.js | 14 ++++++++++++++ 4 files changed, 34 insertions(+) create mode 100644 lib/customer.js create mode 100644 test/customer.js diff --git a/README.md b/README.md index a2bcf9ec..fbdbebc7 100644 --- a/README.md +++ b/README.md @@ -244,6 +244,16 @@ var conversion = { client.leads.convert(conversion, callback); ``` +## Customers + +```node +// Search for customers +client.customers.search({ + query: { field: 'name', operator: '=', name: 'Alice'}, + sort: { field: 'name', order: 'ascending'}, + pagination: { per_page: 10 } +}, callback); + ## Visitors ```node diff --git a/lib/client.js b/lib/client.js index 157884c1..0a00040a 100644 --- a/lib/client.js +++ b/lib/client.js @@ -14,6 +14,7 @@ import Segment from './segment'; import Message from './message'; import Conversation from './conversation'; import Note from './note'; +import Customer from './customer'; export default class Client { constructor(...args) { @@ -45,6 +46,7 @@ export default class Client { this.messages = new Message(this); this.conversations = new Conversation(this); this.notes = new Note(this); + this.customers = new Customer(this); this.promises = false; this.requestOpts = { baseUrl: 'https://api.intercom.io' diff --git a/lib/customer.js b/lib/customer.js new file mode 100644 index 00000000..f2e8f15b --- /dev/null +++ b/lib/customer.js @@ -0,0 +1,8 @@ +export default class Customer { + constructor(client) { + this.client = client; + } + search(params, f) { + return this.client.post('/customers/search', params, f); + } +} diff --git a/test/customer.js b/test/customer.js new file mode 100644 index 00000000..5dd7a8e7 --- /dev/null +++ b/test/customer.js @@ -0,0 +1,14 @@ +import assert from 'assert'; +import {Client} from '../lib'; +import nock from 'nock'; + +describe('customers', () => { + it('should search', done => { + nock('https://api.intercom.io').post('/customers/search', { query: { field: 'name', operator: '=', name: 'Alice'}, sort: { field: 'name', order: 'ascending'}, pagination: { per_page: 10 }}).reply(200, {}); + const client = new Client('foo', 'bar').usePromises(); + client.customers.search({ query: { field: 'name', operator: '=', name: 'Alice'}, sort: { field: 'name', order: 'ascending'}, pagination: { per_page: 10 }}).then(r => { + assert.equal(200, r.statusCode); + done(); + }); + }); +}); From 2383d41580091fb3394af9e61aa4967092a18de2 Mon Sep 17 00:00:00 2001 From: Alexandre Passant Date: Thu, 1 Aug 2019 11:20:13 +0200 Subject: [PATCH 017/146] Ap/customer search (#253) * Typo --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index fbdbebc7..1326e755 100644 --- a/README.md +++ b/README.md @@ -253,6 +253,7 @@ client.customers.search({ sort: { field: 'name', order: 'ascending'}, pagination: { per_page: 10 } }, callback); +``` ## Visitors From 119b4ed86c5e222513e19353e0751ba6066e3953 Mon Sep 17 00:00:00 2001 From: Alexandre Passant Date: Fri, 2 Aug 2019 11:45:23 +0200 Subject: [PATCH 018/146] 2.11.0 (#254) * 2.11.0 * Remove package-lock --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index c4ba4ff6..6f501bd0 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "2.10.6", + "version": "2.11.0", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", From 25f02cdcb599195ad37ec1c7e4294f7f2e52b35e Mon Sep 17 00:00:00 2001 From: Jason Dugdale Date: Mon, 2 Sep 2019 03:12:34 -0700 Subject: [PATCH 019/146] Add example of how to specify API version to README (#232) * Add example of how to specify API version * Update README.md "Intercom versions their" > "We version our" Co-Authored-By: Alexandre Passant --- README.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/README.md b/README.md index 1326e755..81610bf6 100644 --- a/README.md +++ b/README.md @@ -95,6 +95,18 @@ client.useRequestOpts({ Note that certain request options (such as `json`, and certain `headers` names cannot be overriden). +#### Setting the API version + +We version our API (see the "Choose Version" section of the [API & Webhooks Reference](https://developers.intercom.com/intercom-api-reference/reference) for details). You can specify which version of the API to use when performing API requests using request options: + +```node +var client = new Intercom.Client({ token: 'my_token' }); +client.useRequestOpts({ + headers: { + 'Intercom-Version': 1.2 + } +}); +``` ## Users From 3b4c4f77498925281c5d7edbfa318ac7e80239c6 Mon Sep 17 00:00:00 2001 From: Jamie Quint Date: Thu, 19 Sep 2019 14:14:20 -0700 Subject: [PATCH 020/146] enable updating admin away mode and reassignment settings --- README.md | 5 +++++ lib/admin.js | 3 +++ test/admin.js | 8 ++++++++ 3 files changed, 16 insertions(+) diff --git a/README.md b/README.md index 81610bf6..f3cf4fc7 100644 --- a/README.md +++ b/README.md @@ -413,6 +413,11 @@ client.admins.me(callback); client.admins.find('123456789', callback); ``` +``` +// Update admin away mode and reassign settings +client.admins.away('123456789', {'away_mode_enabled': true, 'away_mode_reassign': false}, callback); +``` + ## Tags ```node diff --git a/lib/admin.js b/lib/admin.js index a0c631e5..78e19acb 100644 --- a/lib/admin.js +++ b/lib/admin.js @@ -11,4 +11,7 @@ export default class Admin { me(f) { return this.client.get('/me', {}, f); } + away(id, params, f) { + return this.client.put(`/admins/${id}/away`, params, f); + } } diff --git a/test/admin.js b/test/admin.js index 66508b64..3a5029cc 100644 --- a/test/admin.js +++ b/test/admin.js @@ -27,4 +27,12 @@ describe('admins', () => { done(); }); }); + it('should update admin away mode and reassign settings', done => { + nock('https://api.intercom.io').put('/admins/baz/away', { away_mode_enabled: true, away_mode_reassign: false }).reply(200, {}); + const client = new Client('foo', 'bar').usePromises(); + client.admins.away('baz', { away_mode_enabled: true, away_mode_reassign: false }).then(r => { + assert.equal(200, r.statusCode); + done(); + }); + }); }); From c9f67aacc0447be9d873e4854370f10ce3ad1e3c Mon Sep 17 00:00:00 2001 From: Jake Maldonado Date: Thu, 13 Aug 2020 10:24:41 -0400 Subject: [PATCH 021/146] add api 2.2 warning on readme --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 81610bf6..4ed20b6a 100644 --- a/README.md +++ b/README.md @@ -5,6 +5,8 @@ [![npm version](https://badge.fury.io/js/intercom-client.svg)](http://badge.fury.io/js/intercom-client) +### Does not currently support API V2.2 + ## Installation [![docker_image 1](https://cloud.githubusercontent.com/assets/15954251/17524401/5743439e-5e56-11e6-8567-d3d9da1727da.png)](https://hub.docker.com/r/intercom/sdk-images/)
From c75833f49d64c40b3f56f403db7b3d586f73c253 Mon Sep 17 00:00:00 2001 From: Jake Maldonado Date: Thu, 13 Aug 2020 13:59:46 -0400 Subject: [PATCH 022/146] update readme for correct api support info --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 4ed20b6a..c93ba7b6 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ [![npm version](https://badge.fury.io/js/intercom-client.svg)](http://badge.fury.io/js/intercom-client) -### Does not currently support API V2.2 +### Excluding Customer Search (2.0), only supports 1.X ## Installation From 74d4cb1fe76e2cb0e4c1cf87cb59bf6a8346028d Mon Sep 17 00:00:00 2001 From: Sean Healy Date: Tue, 27 Apr 2021 16:19:00 +0100 Subject: [PATCH 023/146] Update various npm packages --- package.json | 12 +- yarn.lock | 1787 +++++++++++++++++++++++++++++++++++--------------- 2 files changed, 1270 insertions(+), 529 deletions(-) diff --git a/package.json b/package.json index 6f501bd0..0a92b0a8 100644 --- a/package.json +++ b/package.json @@ -18,17 +18,17 @@ "api" ], "dependencies": { - "bluebird": "^3.3.4", + "bluebird": "^3.7.2", "htmlencode": "^0.0.4", - "lodash": "^4.17.15", + "lodash": "^4.17.19", "request": "^2.88.0" }, "devDependencies": { - "@babel/core": "^7.4.5", - "@babel/preset-env": "^7.4.5", - "@babel/register": "^7.4.4", + "@babel/core": "^7.13.16", + "@babel/preset-env": "^7.13.15", + "@babel/register": "^7.13.16", "babel-eslint": "^10.0.2", - "eslint": "^6.0.1", + "eslint": "^6.8.0", "gulp": "^4.0.2", "gulp-babel": "^8.0.0", "gulp-eslint": "4.0.2", diff --git a/yarn.lock b/yarn.lock index 9b5183aa..a388bd26 100644 --- a/yarn.lock +++ b/yarn.lock @@ -8,23 +8,46 @@ dependencies: "@babel/highlight" "^7.0.0" -"@babel/core@^7.4.5": - version "7.4.5" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.4.5.tgz#081f97e8ffca65a9b4b0fdc7e274e703f000c06a" - dependencies: - "@babel/code-frame" "^7.0.0" - "@babel/generator" "^7.4.4" - "@babel/helpers" "^7.4.4" - "@babel/parser" "^7.4.5" - "@babel/template" "^7.4.4" - "@babel/traverse" "^7.4.5" - "@babel/types" "^7.4.4" - convert-source-map "^1.1.0" +"@babel/code-frame@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.12.13.tgz#dcfc826beef65e75c50e21d3837d7d95798dd658" + integrity sha512-HV1Cm0Q3ZrpCR93tkWOYiuYIgLxZXZFVG2VgK+MBWjUqZTundupbfx2aXarXuw5Ko5aMcjtJgbSs4vUGBS5v6g== + dependencies: + "@babel/highlight" "^7.12.13" + +"@babel/compat-data@^7.13.11", "@babel/compat-data@^7.13.15", "@babel/compat-data@^7.13.8": + version "7.13.15" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.13.15.tgz#7e8eea42d0b64fda2b375b22d06c605222e848f4" + integrity sha512-ltnibHKR1VnrU4ymHyQ/CXtNXI6yZC0oJThyW78Hft8XndANwi+9H+UIklBDraIjFEJzw8wmcM427oDd9KS5wA== + +"@babel/core@^7.13.16": + version "7.13.16" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.13.16.tgz#7756ab24396cc9675f1c3fcd5b79fcce192ea96a" + integrity sha512-sXHpixBiWWFti0AV2Zq7avpTasr6sIAu7Y396c608541qAU2ui4a193m0KSQmfPSKFZLnQ3cvlKDOm3XkuXm3Q== + dependencies: + "@babel/code-frame" "^7.12.13" + "@babel/generator" "^7.13.16" + "@babel/helper-compilation-targets" "^7.13.16" + "@babel/helper-module-transforms" "^7.13.14" + "@babel/helpers" "^7.13.16" + "@babel/parser" "^7.13.16" + "@babel/template" "^7.12.13" + "@babel/traverse" "^7.13.15" + "@babel/types" "^7.13.16" + convert-source-map "^1.7.0" debug "^4.1.0" - json5 "^2.1.0" - lodash "^4.17.11" - resolve "^1.3.2" - semver "^5.4.1" + gensync "^1.0.0-beta.2" + json5 "^2.1.2" + semver "^6.3.0" + source-map "^0.5.0" + +"@babel/generator@^7.13.16": + version "7.13.16" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.13.16.tgz#0befc287031a201d84cdfc173b46b320ae472d14" + integrity sha512-grBBR75UnKOcUWMp8WoDxNsWCFl//XCK6HWTrBQKTr5SV9f5g0pNOjdyzi/DTBv12S9GnYPInIXQBTky7OXEMg== + dependencies: + "@babel/types" "^7.13.16" + jsesc "^2.5.1" source-map "^0.5.0" "@babel/generator@^7.4.4": @@ -37,41 +60,70 @@ source-map "^0.5.0" trim-right "^1.0.1" -"@babel/helper-annotate-as-pure@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.0.0.tgz#323d39dd0b50e10c7c06ca7d7638e6864d8c5c32" +"@babel/helper-annotate-as-pure@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.12.13.tgz#0f58e86dfc4bb3b1fcd7db806570e177d439b6ab" + integrity sha512-7YXfX5wQ5aYM/BOlbSccHDbuXXFPxeoUmfWtz8le2yTkTZc+BxsiEnENFoi2SlmA8ewDkG2LgIMIVzzn2h8kfw== dependencies: - "@babel/types" "^7.0.0" + "@babel/types" "^7.12.13" -"@babel/helper-builder-binary-assignment-operator-visitor@^7.1.0": - version "7.1.0" - resolved "https://registry.yarnpkg.com/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.1.0.tgz#6b69628dfe4087798e0c4ed98e3d4a6b2fbd2f5f" +"@babel/helper-builder-binary-assignment-operator-visitor@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.12.13.tgz#6bc20361c88b0a74d05137a65cac8d3cbf6f61fc" + integrity sha512-CZOv9tGphhDRlVjVkAgm8Nhklm9RzSmWpX2my+t7Ua/KT616pEzXsQCjinzvkRvHWJ9itO4f296efroX23XCMA== dependencies: - "@babel/helper-explode-assignable-expression" "^7.1.0" - "@babel/types" "^7.0.0" + "@babel/helper-explode-assignable-expression" "^7.12.13" + "@babel/types" "^7.12.13" -"@babel/helper-call-delegate@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/helper-call-delegate/-/helper-call-delegate-7.4.4.tgz#87c1f8ca19ad552a736a7a27b1c1fcf8b1ff1f43" +"@babel/helper-compilation-targets@^7.13.0", "@babel/helper-compilation-targets@^7.13.13", "@babel/helper-compilation-targets@^7.13.16", "@babel/helper-compilation-targets@^7.13.8": + version "7.13.16" + resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.13.16.tgz#6e91dccf15e3f43e5556dffe32d860109887563c" + integrity sha512-3gmkYIrpqsLlieFwjkGgLaSHmhnvlAYzZLlYVjlW+QwI+1zE17kGxuJGmIqDQdYp56XdmGeD+Bswx0UTyG18xA== dependencies: - "@babel/helper-hoist-variables" "^7.4.4" - "@babel/traverse" "^7.4.4" - "@babel/types" "^7.4.4" + "@babel/compat-data" "^7.13.15" + "@babel/helper-validator-option" "^7.12.17" + browserslist "^4.14.5" + semver "^6.3.0" -"@babel/helper-define-map@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/helper-define-map/-/helper-define-map-7.4.4.tgz#6969d1f570b46bdc900d1eba8e5d59c48ba2c12a" +"@babel/helper-create-class-features-plugin@^7.13.0": + version "7.13.11" + resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.13.11.tgz#30d30a005bca2c953f5653fc25091a492177f4f6" + integrity sha512-ays0I7XYq9xbjCSvT+EvysLgfc3tOkwCULHjrnscGT3A9qD4sk3wXnJ3of0MAWsWGjdinFvajHU2smYuqXKMrw== dependencies: - "@babel/helper-function-name" "^7.1.0" - "@babel/types" "^7.4.4" - lodash "^4.17.11" + "@babel/helper-function-name" "^7.12.13" + "@babel/helper-member-expression-to-functions" "^7.13.0" + "@babel/helper-optimise-call-expression" "^7.12.13" + "@babel/helper-replace-supers" "^7.13.0" + "@babel/helper-split-export-declaration" "^7.12.13" -"@babel/helper-explode-assignable-expression@^7.1.0": - version "7.1.0" - resolved "https://registry.yarnpkg.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.1.0.tgz#537fa13f6f1674df745b0c00ec8fe4e99681c8f6" +"@babel/helper-create-regexp-features-plugin@^7.12.13": + version "7.12.17" + resolved "https://registry.yarnpkg.com/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.12.17.tgz#a2ac87e9e319269ac655b8d4415e94d38d663cb7" + integrity sha512-p2VGmBu9oefLZ2nQpgnEnG0ZlRPvL8gAGvPUMQwUdaE8k49rOMuZpOwdQoy5qJf6K8jL3bcAMhVUlHAjIgJHUg== dependencies: - "@babel/traverse" "^7.1.0" - "@babel/types" "^7.0.0" + "@babel/helper-annotate-as-pure" "^7.12.13" + regexpu-core "^4.7.1" + +"@babel/helper-define-polyfill-provider@^0.2.0": + version "0.2.0" + resolved "https://registry.yarnpkg.com/@babel/helper-define-polyfill-provider/-/helper-define-polyfill-provider-0.2.0.tgz#a640051772045fedaaecc6f0c6c69f02bdd34bf1" + integrity sha512-JT8tHuFjKBo8NnaUbblz7mIu1nnvUDiHVjXXkulZULyidvo/7P6TY7+YqpV37IfF+KUFxmlK04elKtGKXaiVgw== + dependencies: + "@babel/helper-compilation-targets" "^7.13.0" + "@babel/helper-module-imports" "^7.12.13" + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/traverse" "^7.13.0" + debug "^4.1.1" + lodash.debounce "^4.0.8" + resolve "^1.14.2" + semver "^6.1.2" + +"@babel/helper-explode-assignable-expression@^7.12.13": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.13.0.tgz#17b5c59ff473d9f956f40ef570cf3a76ca12657f" + integrity sha512-qS0peLTDP8kOisG1blKbaoBg/o9OSa1qoumMjTK5pM+KDTtpxpsiubnCGP34vK8BXGcb2M9eigwgvoJryrzwWA== + dependencies: + "@babel/types" "^7.13.0" "@babel/helper-function-name@^7.1.0": version "7.1.0" @@ -81,82 +133,125 @@ "@babel/template" "^7.1.0" "@babel/types" "^7.0.0" +"@babel/helper-function-name@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.12.13.tgz#93ad656db3c3c2232559fd7b2c3dbdcbe0eb377a" + integrity sha512-TZvmPn0UOqmvi5G4vvw0qZTpVptGkB1GL61R6lKvrSdIxGm5Pky7Q3fpKiIkQCAtRCBUwB0PaThlx9vebCDSwA== + dependencies: + "@babel/helper-get-function-arity" "^7.12.13" + "@babel/template" "^7.12.13" + "@babel/types" "^7.12.13" + "@babel/helper-get-function-arity@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0.tgz#83572d4320e2a4657263734113c42868b64e49c3" dependencies: "@babel/types" "^7.0.0" -"@babel/helper-hoist-variables@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.4.4.tgz#0298b5f25c8c09c53102d52ac4a98f773eb2850a" +"@babel/helper-get-function-arity@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.12.13.tgz#bc63451d403a3b3082b97e1d8b3fe5bd4091e583" + integrity sha512-DjEVzQNz5LICkzN0REdpD5prGoidvbdYk1BVgRUOINaWJP2t6avB27X1guXK1kXNrX0WMfsrm1A/ZBthYuIMQg== dependencies: - "@babel/types" "^7.4.4" + "@babel/types" "^7.12.13" -"@babel/helper-member-expression-to-functions@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.0.0.tgz#8cd14b0a0df7ff00f009e7d7a436945f47c7a16f" +"@babel/helper-hoist-variables@^7.13.0": + version "7.13.16" + resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.13.16.tgz#1b1651249e94b51f8f0d33439843e33e39775b30" + integrity sha512-1eMtTrXtrwscjcAeO4BVK+vvkxaLJSPFz1w1KLawz6HLNi9bPFGBNwwDyVfiu1Tv/vRRFYfoGaKhmAQPGPn5Wg== dependencies: - "@babel/types" "^7.0.0" + "@babel/traverse" "^7.13.15" + "@babel/types" "^7.13.16" -"@babel/helper-module-imports@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.0.0.tgz#96081b7111e486da4d2cd971ad1a4fe216cc2e3d" +"@babel/helper-member-expression-to-functions@^7.13.0", "@babel/helper-member-expression-to-functions@^7.13.12": + version "7.13.12" + resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.13.12.tgz#dfe368f26d426a07299d8d6513821768216e6d72" + integrity sha512-48ql1CLL59aKbU94Y88Xgb2VFy7a95ykGRbJJaaVv+LX5U8wFpLfiGXJJGUozsmA1oEh/o5Bp60Voq7ACyA/Sw== dependencies: - "@babel/types" "^7.0.0" + "@babel/types" "^7.13.12" -"@babel/helper-module-transforms@^7.1.0", "@babel/helper-module-transforms@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.4.4.tgz#96115ea42a2f139e619e98ed46df6019b94414b8" +"@babel/helper-module-imports@^7.12.13", "@babel/helper-module-imports@^7.13.12": + version "7.13.12" + resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.13.12.tgz#c6a369a6f3621cb25da014078684da9196b61977" + integrity sha512-4cVvR2/1B693IuOvSI20xqqa/+bl7lqAMR59R4iu39R9aOX8/JoYY1sFaNvUMyMBGnHdwvJgUrzNLoUZxXypxA== dependencies: - "@babel/helper-module-imports" "^7.0.0" - "@babel/helper-simple-access" "^7.1.0" - "@babel/helper-split-export-declaration" "^7.4.4" - "@babel/template" "^7.4.4" - "@babel/types" "^7.4.4" - lodash "^4.17.11" + "@babel/types" "^7.13.12" -"@babel/helper-optimise-call-expression@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.0.0.tgz#a2920c5702b073c15de51106200aa8cad20497d5" +"@babel/helper-module-transforms@^7.13.0", "@babel/helper-module-transforms@^7.13.14": + version "7.13.14" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.13.14.tgz#e600652ba48ccb1641775413cb32cfa4e8b495ef" + integrity sha512-QuU/OJ0iAOSIatyVZmfqB0lbkVP0kDRiKj34xy+QNsnVZi/PA6BoSoreeqnxxa9EHFAIL0R9XOaAR/G9WlIy5g== dependencies: - "@babel/types" "^7.0.0" + "@babel/helper-module-imports" "^7.13.12" + "@babel/helper-replace-supers" "^7.13.12" + "@babel/helper-simple-access" "^7.13.12" + "@babel/helper-split-export-declaration" "^7.12.13" + "@babel/helper-validator-identifier" "^7.12.11" + "@babel/template" "^7.12.13" + "@babel/traverse" "^7.13.13" + "@babel/types" "^7.13.14" + +"@babel/helper-optimise-call-expression@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.12.13.tgz#5c02d171b4c8615b1e7163f888c1c81c30a2aaea" + integrity sha512-BdWQhoVJkp6nVjB7nkFWcn43dkprYauqtk++Py2eaf/GRDFm5BxRqEIZCiHlZUGAVmtwKcsVL1dC68WmzeFmiA== + dependencies: + "@babel/types" "^7.12.13" "@babel/helper-plugin-utils@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.0.0.tgz#bbb3fbee98661c569034237cc03967ba99b4f250" -"@babel/helper-regex@^7.0.0", "@babel/helper-regex@^7.4.4": +"@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.13.0", "@babel/helper-plugin-utils@^7.8.0", "@babel/helper-plugin-utils@^7.8.3": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.13.0.tgz#806526ce125aed03373bc416a828321e3a6a33af" + integrity sha512-ZPafIPSwzUlAoWT8DKs1W2VyF2gOWthGd5NGFMsBcMMol+ZhK+EQY/e6V96poa6PA/Bh+C9plWN0hXO1uB8AfQ== + +"@babel/helper-regex@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/helper-regex/-/helper-regex-7.4.4.tgz#a47e02bc91fb259d2e6727c2a30013e3ac13c4a2" dependencies: lodash "^4.17.11" -"@babel/helper-remap-async-to-generator@^7.1.0": - version "7.1.0" - resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.1.0.tgz#361d80821b6f38da75bd3f0785ece20a88c5fe7f" +"@babel/helper-remap-async-to-generator@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.13.0.tgz#376a760d9f7b4b2077a9dd05aa9c3927cadb2209" + integrity sha512-pUQpFBE9JvC9lrQbpX0TmeNIy5s7GnZjna2lhhcHC7DzgBs6fWn722Y5cfwgrtrqc7NAJwMvOa0mKhq6XaE4jg== dependencies: - "@babel/helper-annotate-as-pure" "^7.0.0" - "@babel/helper-wrap-function" "^7.1.0" - "@babel/template" "^7.1.0" - "@babel/traverse" "^7.1.0" - "@babel/types" "^7.0.0" + "@babel/helper-annotate-as-pure" "^7.12.13" + "@babel/helper-wrap-function" "^7.13.0" + "@babel/types" "^7.13.0" -"@babel/helper-replace-supers@^7.1.0", "@babel/helper-replace-supers@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.4.4.tgz#aee41783ebe4f2d3ab3ae775e1cc6f1a90cefa27" +"@babel/helper-replace-supers@^7.12.13", "@babel/helper-replace-supers@^7.13.0", "@babel/helper-replace-supers@^7.13.12": + version "7.13.12" + resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.13.12.tgz#6442f4c1ad912502481a564a7386de0c77ff3804" + integrity sha512-Gz1eiX+4yDO8mT+heB94aLVNCL+rbuT2xy4YfyNqu8F+OI6vMvJK891qGBTqL9Uc8wxEvRW92Id6G7sDen3fFw== dependencies: - "@babel/helper-member-expression-to-functions" "^7.0.0" - "@babel/helper-optimise-call-expression" "^7.0.0" - "@babel/traverse" "^7.4.4" - "@babel/types" "^7.4.4" + "@babel/helper-member-expression-to-functions" "^7.13.12" + "@babel/helper-optimise-call-expression" "^7.12.13" + "@babel/traverse" "^7.13.0" + "@babel/types" "^7.13.12" -"@babel/helper-simple-access@^7.1.0": - version "7.1.0" - resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.1.0.tgz#65eeb954c8c245beaa4e859da6188f39d71e585c" +"@babel/helper-simple-access@^7.12.13", "@babel/helper-simple-access@^7.13.12": + version "7.13.12" + resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.13.12.tgz#dd6c538afb61819d205a012c31792a39c7a5eaf6" + integrity sha512-7FEjbrx5SL9cWvXioDbnlYTppcZGuCY6ow3/D5vMggb2Ywgu4dMrpTJX0JdQAIcRRUElOIxF3yEooa9gUb9ZbA== dependencies: - "@babel/template" "^7.1.0" - "@babel/types" "^7.0.0" + "@babel/types" "^7.13.12" + +"@babel/helper-skip-transparent-expression-wrappers@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/helper-skip-transparent-expression-wrappers/-/helper-skip-transparent-expression-wrappers-7.12.1.tgz#462dc63a7e435ade8468385c63d2b84cce4b3cbf" + integrity sha512-Mf5AUuhG1/OCChOJ/HcADmvcHM42WJockombn8ATJG3OnyiSxBK/Mm5x78BQWvmtXZKHgbjdGL2kin/HOLlZGA== + dependencies: + "@babel/types" "^7.12.1" + +"@babel/helper-split-export-declaration@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.12.13.tgz#e9430be00baf3e88b0e13e6f9d4eaf2136372b05" + integrity sha512-tCJDltF83htUtXx5NLcaDqRmknv652ZWCHyoTETf1CXYJdPC7nohZohjUgieXhv0hTJdRf2FjDueFehdNucpzg== + dependencies: + "@babel/types" "^7.12.13" "@babel/helper-split-export-declaration@^7.4.4": version "7.4.4" @@ -164,22 +259,34 @@ dependencies: "@babel/types" "^7.4.4" -"@babel/helper-wrap-function@^7.1.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/helper-wrap-function/-/helper-wrap-function-7.2.0.tgz#c4e0012445769e2815b55296ead43a958549f6fa" +"@babel/helper-validator-identifier@^7.12.11": + version "7.12.11" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.12.11.tgz#c9a1f021917dcb5ccf0d4e453e399022981fc9ed" + integrity sha512-np/lG3uARFybkoHokJUmf1QfEvRVCPbmQeUQpKow5cQ3xWrV9i3rUHodKDJPQfTVX61qKi+UdYk8kik84n7XOw== + +"@babel/helper-validator-option@^7.12.17": + version "7.12.17" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.12.17.tgz#d1fbf012e1a79b7eebbfdc6d270baaf8d9eb9831" + integrity sha512-TopkMDmLzq8ngChwRlyjR6raKD6gMSae4JdYDB8bByKreQgG0RBTuKe9LRxW3wFtUnjxOPRKBDwEH6Mg5KeDfw== + +"@babel/helper-wrap-function@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/helper-wrap-function/-/helper-wrap-function-7.13.0.tgz#bdb5c66fda8526ec235ab894ad53a1235c79fcc4" + integrity sha512-1UX9F7K3BS42fI6qd2A4BjKzgGjToscyZTdp1DjknHLCIvpgne6918io+aL5LXFcER/8QWiwpoY902pVEqgTXA== dependencies: - "@babel/helper-function-name" "^7.1.0" - "@babel/template" "^7.1.0" - "@babel/traverse" "^7.1.0" - "@babel/types" "^7.2.0" + "@babel/helper-function-name" "^7.12.13" + "@babel/template" "^7.12.13" + "@babel/traverse" "^7.13.0" + "@babel/types" "^7.13.0" -"@babel/helpers@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.4.4.tgz#868b0ef59c1dd4e78744562d5ce1b59c89f2f2a5" +"@babel/helpers@^7.13.16": + version "7.13.17" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.13.17.tgz#b497c7a00e9719d5b613b8982bda6ed3ee94caf6" + integrity sha512-Eal4Gce4kGijo1/TGJdqp3WuhllaMLSrW6XcL0ulyUAQOuxHcCafZE8KHg9857gcTehsm/v7RcOx2+jp0Ryjsg== dependencies: - "@babel/template" "^7.4.4" - "@babel/traverse" "^7.4.4" - "@babel/types" "^7.4.4" + "@babel/template" "^7.12.13" + "@babel/traverse" "^7.13.17" + "@babel/types" "^7.13.17" "@babel/highlight@^7.0.0": version "7.0.0" @@ -189,38 +296,141 @@ esutils "^2.0.2" js-tokens "^4.0.0" +"@babel/highlight@^7.12.13": + version "7.13.10" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.13.10.tgz#a8b2a66148f5b27d666b15d81774347a731d52d1" + integrity sha512-5aPpe5XQPzflQrFwL1/QoeHkP2MsA4JCntcXHRhEsdsfPVkvPi2w7Qix4iV7t5S/oC9OodGrggd8aco1g3SZFg== + dependencies: + "@babel/helper-validator-identifier" "^7.12.11" + chalk "^2.0.0" + js-tokens "^4.0.0" + "@babel/parser@^7.0.0", "@babel/parser@^7.4.4", "@babel/parser@^7.4.5": version "7.4.5" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.4.5.tgz#04af8d5d5a2b044a2a1bffacc1e5e6673544e872" -"@babel/plugin-proposal-async-generator-functions@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.2.0.tgz#b289b306669dce4ad20b0252889a15768c9d417e" - dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-remap-async-to-generator" "^7.1.0" - "@babel/plugin-syntax-async-generators" "^7.2.0" - -"@babel/plugin-proposal-json-strings@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.2.0.tgz#568ecc446c6148ae6b267f02551130891e29f317" - dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-syntax-json-strings" "^7.2.0" - -"@babel/plugin-proposal-object-rest-spread@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.4.4.tgz#1ef173fcf24b3e2df92a678f027673b55e7e3005" - dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-syntax-object-rest-spread" "^7.2.0" - -"@babel/plugin-proposal-optional-catch-binding@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.2.0.tgz#135d81edb68a081e55e56ec48541ece8065c38f5" - dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-syntax-optional-catch-binding" "^7.2.0" +"@babel/parser@^7.12.13", "@babel/parser@^7.13.16": + version "7.13.16" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.13.16.tgz#0f18179b0448e6939b1f3f5c4c355a3a9bcdfd37" + integrity sha512-6bAg36mCwuqLO0hbR+z7PHuqWiCeP7Dzg73OpQwsAB1Eb8HnGEz5xYBzCfbu+YjoaJsJs+qheDxVAuqbt3ILEw== + +"@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@^7.13.12": + version "7.13.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/-/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.13.12.tgz#a3484d84d0b549f3fc916b99ee4783f26fabad2a" + integrity sha512-d0u3zWKcoZf379fOeJdr1a5WPDny4aOFZ6hlfKivgK0LY7ZxNfoaHL2fWwdGtHyVvra38FC+HVYkO+byfSA8AQ== + dependencies: + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/helper-skip-transparent-expression-wrappers" "^7.12.1" + "@babel/plugin-proposal-optional-chaining" "^7.13.12" + +"@babel/plugin-proposal-async-generator-functions@^7.13.15": + version "7.13.15" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.13.15.tgz#80e549df273a3b3050431b148c892491df1bcc5b" + integrity sha512-VapibkWzFeoa6ubXy/NgV5U2U4MVnUlvnx6wo1XhlsaTrLYWE0UFpDQsVrmn22q5CzeloqJ8gEMHSKxuee6ZdA== + dependencies: + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/helper-remap-async-to-generator" "^7.13.0" + "@babel/plugin-syntax-async-generators" "^7.8.4" + +"@babel/plugin-proposal-class-properties@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.13.0.tgz#146376000b94efd001e57a40a88a525afaab9f37" + integrity sha512-KnTDjFNC1g+45ka0myZNvSBFLhNCLN+GeGYLDEA8Oq7MZ6yMgfLoIRh86GRT0FjtJhZw8JyUskP9uvj5pHM9Zg== + dependencies: + "@babel/helper-create-class-features-plugin" "^7.13.0" + "@babel/helper-plugin-utils" "^7.13.0" + +"@babel/plugin-proposal-dynamic-import@^7.13.8": + version "7.13.8" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.13.8.tgz#876a1f6966e1dec332e8c9451afda3bebcdf2e1d" + integrity sha512-ONWKj0H6+wIRCkZi9zSbZtE/r73uOhMVHh256ys0UzfM7I3d4n+spZNWjOnJv2gzopumP2Wxi186vI8N0Y2JyQ== + dependencies: + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/plugin-syntax-dynamic-import" "^7.8.3" + +"@babel/plugin-proposal-export-namespace-from@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-export-namespace-from/-/plugin-proposal-export-namespace-from-7.12.13.tgz#393be47a4acd03fa2af6e3cde9b06e33de1b446d" + integrity sha512-INAgtFo4OnLN3Y/j0VwAgw3HDXcDtX+C/erMvWzuV9v71r7urb6iyMXu7eM9IgLr1ElLlOkaHjJ0SbCmdOQ3Iw== + dependencies: + "@babel/helper-plugin-utils" "^7.12.13" + "@babel/plugin-syntax-export-namespace-from" "^7.8.3" + +"@babel/plugin-proposal-json-strings@^7.13.8": + version "7.13.8" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.13.8.tgz#bf1fb362547075afda3634ed31571c5901afef7b" + integrity sha512-w4zOPKUFPX1mgvTmL/fcEqy34hrQ1CRcGxdphBc6snDnnqJ47EZDIyop6IwXzAC8G916hsIuXB2ZMBCExC5k7Q== + dependencies: + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/plugin-syntax-json-strings" "^7.8.3" + +"@babel/plugin-proposal-logical-assignment-operators@^7.13.8": + version "7.13.8" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-logical-assignment-operators/-/plugin-proposal-logical-assignment-operators-7.13.8.tgz#93fa78d63857c40ce3c8c3315220fd00bfbb4e1a" + integrity sha512-aul6znYB4N4HGweImqKn59Su9RS8lbUIqxtXTOcAGtNIDczoEFv+l1EhmX8rUBp3G1jMjKJm8m0jXVp63ZpS4A== + dependencies: + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" + +"@babel/plugin-proposal-nullish-coalescing-operator@^7.13.8": + version "7.13.8" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.13.8.tgz#3730a31dafd3c10d8ccd10648ed80a2ac5472ef3" + integrity sha512-iePlDPBn//UhxExyS9KyeYU7RM9WScAG+D3Hhno0PLJebAEpDZMocbDe64eqynhNAnwz/vZoL/q/QB2T1OH39A== + dependencies: + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" + +"@babel/plugin-proposal-numeric-separator@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-numeric-separator/-/plugin-proposal-numeric-separator-7.12.13.tgz#bd9da3188e787b5120b4f9d465a8261ce67ed1db" + integrity sha512-O1jFia9R8BUCl3ZGB7eitaAPu62TXJRHn7rh+ojNERCFyqRwJMTmhz+tJ+k0CwI6CLjX/ee4qW74FSqlq9I35w== + dependencies: + "@babel/helper-plugin-utils" "^7.12.13" + "@babel/plugin-syntax-numeric-separator" "^7.10.4" + +"@babel/plugin-proposal-object-rest-spread@^7.13.8": + version "7.13.8" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.13.8.tgz#5d210a4d727d6ce3b18f9de82cc99a3964eed60a" + integrity sha512-DhB2EuB1Ih7S3/IRX5AFVgZ16k3EzfRbq97CxAVI1KSYcW+lexV8VZb7G7L8zuPVSdQMRn0kiBpf/Yzu9ZKH0g== + dependencies: + "@babel/compat-data" "^7.13.8" + "@babel/helper-compilation-targets" "^7.13.8" + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/plugin-syntax-object-rest-spread" "^7.8.3" + "@babel/plugin-transform-parameters" "^7.13.0" + +"@babel/plugin-proposal-optional-catch-binding@^7.13.8": + version "7.13.8" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.13.8.tgz#3ad6bd5901506ea996fc31bdcf3ccfa2bed71107" + integrity sha512-0wS/4DUF1CuTmGo+NiaHfHcVSeSLj5S3e6RivPTg/2k3wOv3jO35tZ6/ZWsQhQMvdgI7CwphjQa/ccarLymHVA== + dependencies: + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" + +"@babel/plugin-proposal-optional-chaining@^7.13.12": + version "7.13.12" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.13.12.tgz#ba9feb601d422e0adea6760c2bd6bbb7bfec4866" + integrity sha512-fcEdKOkIB7Tf4IxrgEVeFC4zeJSTr78no9wTdBuZZbqF64kzllU0ybo2zrzm7gUQfxGhBgq4E39oRs8Zx/RMYQ== + dependencies: + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/helper-skip-transparent-expression-wrappers" "^7.12.1" + "@babel/plugin-syntax-optional-chaining" "^7.8.3" + +"@babel/plugin-proposal-private-methods@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-private-methods/-/plugin-proposal-private-methods-7.13.0.tgz#04bd4c6d40f6e6bbfa2f57e2d8094bad900ef787" + integrity sha512-MXyyKQd9inhx1kDYPkFRVOBXQ20ES8Pto3T7UZ92xj2mY0EVD8oAVzeyYuVfy/mxAdTSIayOvg+aVzcHV2bn6Q== + dependencies: + "@babel/helper-create-class-features-plugin" "^7.13.0" + "@babel/helper-plugin-utils" "^7.13.0" + +"@babel/plugin-proposal-unicode-property-regex@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.12.13.tgz#bebde51339be829c17aaaaced18641deb62b39ba" + integrity sha512-XyJmZidNfofEkqFV5VC/bLabGmO5QzenPO/YOfGuEbgU+2sSwMmio3YLb4WtBgcmmdwZHyVyv8on77IUjQ5Gvg== + dependencies: + "@babel/helper-create-regexp-features-plugin" "^7.12.13" + "@babel/helper-plugin-utils" "^7.12.13" "@babel/plugin-proposal-unicode-property-regex@^7.4.4": version "7.4.4" @@ -230,307 +440,451 @@ "@babel/helper-regex" "^7.4.4" regexpu-core "^4.5.4" -"@babel/plugin-syntax-async-generators@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.2.0.tgz#69e1f0db34c6f5a0cf7e2b3323bf159a76c8cb7f" +"@babel/plugin-syntax-async-generators@^7.8.4": + version "7.8.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz#a983fb1aeb2ec3f6ed042a210f640e90e786fe0d" + integrity sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-json-strings@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.2.0.tgz#72bd13f6ffe1d25938129d2a186b11fd62951470" +"@babel/plugin-syntax-class-properties@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz#b5c987274c4a3a82b89714796931a6b53544ae10" + integrity sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.12.13" -"@babel/plugin-syntax-object-rest-spread@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.2.0.tgz#3b7a3e733510c57e820b9142a6579ac8b0dfad2e" +"@babel/plugin-syntax-dynamic-import@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.8.3.tgz#62bf98b2da3cd21d626154fc96ee5b3cb68eacb3" + integrity sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-optional-catch-binding@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.2.0.tgz#a94013d6eda8908dfe6a477e7f9eda85656ecf5c" +"@babel/plugin-syntax-export-namespace-from@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-export-namespace-from/-/plugin-syntax-export-namespace-from-7.8.3.tgz#028964a9ba80dbc094c915c487ad7c4e7a66465a" + integrity sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-arrow-functions@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.2.0.tgz#9aeafbe4d6ffc6563bf8f8372091628f00779550" +"@babel/plugin-syntax-json-strings@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz#01ca21b668cd8218c9e640cb6dd88c5412b2c96a" + integrity sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-transform-async-to-generator@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.4.4.tgz#a3f1d01f2f21cadab20b33a82133116f14fb5894" +"@babel/plugin-syntax-logical-assignment-operators@^7.10.4": + version "7.10.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz#ca91ef46303530448b906652bac2e9fe9941f699" + integrity sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig== dependencies: - "@babel/helper-module-imports" "^7.0.0" - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-remap-async-to-generator" "^7.1.0" + "@babel/helper-plugin-utils" "^7.10.4" -"@babel/plugin-transform-block-scoped-functions@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.2.0.tgz#5d3cc11e8d5ddd752aa64c9148d0db6cb79fd190" +"@babel/plugin-syntax-nullish-coalescing-operator@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz#167ed70368886081f74b5c36c65a88c03b66d1a9" + integrity sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-transform-block-scoping@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.4.4.tgz#c13279fabf6b916661531841a23c4b7dae29646d" +"@babel/plugin-syntax-numeric-separator@^7.10.4": + version "7.10.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz#b9b070b3e33570cd9fd07ba7fa91c0dd37b9af97" + integrity sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - lodash "^4.17.11" + "@babel/helper-plugin-utils" "^7.10.4" -"@babel/plugin-transform-classes@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.4.4.tgz#0ce4094cdafd709721076d3b9c38ad31ca715eb6" +"@babel/plugin-syntax-object-rest-spread@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz#60e225edcbd98a640332a2e72dd3e66f1af55871" + integrity sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA== dependencies: - "@babel/helper-annotate-as-pure" "^7.0.0" - "@babel/helper-define-map" "^7.4.4" - "@babel/helper-function-name" "^7.1.0" - "@babel/helper-optimise-call-expression" "^7.0.0" - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-replace-supers" "^7.4.4" - "@babel/helper-split-export-declaration" "^7.4.4" - globals "^11.1.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-transform-computed-properties@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.2.0.tgz#83a7df6a658865b1c8f641d510c6f3af220216da" +"@babel/plugin-syntax-optional-catch-binding@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz#6111a265bcfb020eb9efd0fdfd7d26402b9ed6c1" + integrity sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-transform-destructuring@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.4.4.tgz#9d964717829cc9e4b601fc82a26a71a4d8faf20f" +"@babel/plugin-syntax-optional-chaining@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz#4f69c2ab95167e0180cd5336613f8c5788f7d48a" + integrity sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-transform-dotall-regex@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.4.4.tgz#361a148bc951444312c69446d76ed1ea8e4450c3" +"@babel/plugin-syntax-top-level-await@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.12.13.tgz#c5f0fa6e249f5b739727f923540cf7a806130178" + integrity sha512-A81F9pDwyS7yM//KwbCSDqy3Uj4NMIurtplxphWxoYtNPov7cJsDkAFNNyVlIZ3jwGycVsurZ+LtOA8gZ376iQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-regex" "^7.4.4" - regexpu-core "^4.5.4" + "@babel/helper-plugin-utils" "^7.12.13" -"@babel/plugin-transform-duplicate-keys@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.2.0.tgz#d952c4930f312a4dbfff18f0b2914e60c35530b3" +"@babel/plugin-transform-arrow-functions@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.13.0.tgz#10a59bebad52d637a027afa692e8d5ceff5e3dae" + integrity sha512-96lgJagobeVmazXFaDrbmCLQxBysKu7U6Do3mLsx27gf5Dk85ezysrs2BZUpXD703U/Su1xTBDxxar2oa4jAGg== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.13.0" -"@babel/plugin-transform-exponentiation-operator@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.2.0.tgz#a63868289e5b4007f7054d46491af51435766008" +"@babel/plugin-transform-async-to-generator@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.13.0.tgz#8e112bf6771b82bf1e974e5e26806c5c99aa516f" + integrity sha512-3j6E004Dx0K3eGmhxVJxwwI89CTJrce7lg3UrtFuDAVQ/2+SJ/h/aSFOeE6/n0WB1GsOffsJp6MnPQNQ8nmwhg== dependencies: - "@babel/helper-builder-binary-assignment-operator-visitor" "^7.1.0" - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-module-imports" "^7.12.13" + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/helper-remap-async-to-generator" "^7.13.0" -"@babel/plugin-transform-for-of@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.4.4.tgz#0267fc735e24c808ba173866c6c4d1440fc3c556" +"@babel/plugin-transform-block-scoped-functions@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.12.13.tgz#a9bf1836f2a39b4eb6cf09967739de29ea4bf4c4" + integrity sha512-zNyFqbc3kI/fVpqwfqkg6RvBgFpC4J18aKKMmv7KdQ/1GgREapSJAykLMVNwfRGO3BtHj3YQZl8kxCXPcVMVeg== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.12.13" -"@babel/plugin-transform-function-name@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.4.4.tgz#e1436116abb0610c2259094848754ac5230922ad" +"@babel/plugin-transform-block-scoping@^7.12.13": + version "7.13.16" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.13.16.tgz#a9c0f10794855c63b1d629914c7dcfeddd185892" + integrity sha512-ad3PHUxGnfWF4Efd3qFuznEtZKoBp0spS+DgqzVzRPV7urEBvPLue3y2j80w4Jf2YLzZHj8TOv/Lmvdmh3b2xg== dependencies: - "@babel/helper-function-name" "^7.1.0" - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.13.0" -"@babel/plugin-transform-literals@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-literals/-/plugin-transform-literals-7.2.0.tgz#690353e81f9267dad4fd8cfd77eafa86aba53ea1" +"@babel/plugin-transform-classes@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.13.0.tgz#0265155075c42918bf4d3a4053134176ad9b533b" + integrity sha512-9BtHCPUARyVH1oXGcSJD3YpsqRLROJx5ZNP6tN5vnk17N0SVf9WCtf8Nuh1CFmgByKKAIMstitKduoCmsaDK5g== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-annotate-as-pure" "^7.12.13" + "@babel/helper-function-name" "^7.12.13" + "@babel/helper-optimise-call-expression" "^7.12.13" + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/helper-replace-supers" "^7.13.0" + "@babel/helper-split-export-declaration" "^7.12.13" + globals "^11.1.0" -"@babel/plugin-transform-member-expression-literals@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.2.0.tgz#fa10aa5c58a2cb6afcf2c9ffa8cb4d8b3d489a2d" +"@babel/plugin-transform-computed-properties@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.13.0.tgz#845c6e8b9bb55376b1fa0b92ef0bdc8ea06644ed" + integrity sha512-RRqTYTeZkZAz8WbieLTvKUEUxZlUTdmL5KGMyZj7FnMfLNKV4+r5549aORG/mgojRmFlQMJDUupwAMiF2Q7OUg== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.13.0" -"@babel/plugin-transform-modules-amd@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.2.0.tgz#82a9bce45b95441f617a24011dc89d12da7f4ee6" +"@babel/plugin-transform-destructuring@^7.13.0": + version "7.13.17" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.13.17.tgz#678d96576638c19d5b36b332504d3fd6e06dea27" + integrity sha512-UAUqiLv+uRLO+xuBKKMEpC+t7YRNVRqBsWWq1yKXbBZBje/t3IXCiSinZhjn/DC3qzBfICeYd2EFGEbHsh5RLA== dependencies: - "@babel/helper-module-transforms" "^7.1.0" - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.13.0" -"@babel/plugin-transform-modules-commonjs@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.4.4.tgz#0bef4713d30f1d78c2e59b3d6db40e60192cac1e" +"@babel/plugin-transform-dotall-regex@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.12.13.tgz#3f1601cc29905bfcb67f53910f197aeafebb25ad" + integrity sha512-foDrozE65ZFdUC2OfgeOCrEPTxdB3yjqxpXh8CH+ipd9CHd4s/iq81kcUpyH8ACGNEPdFqbtzfgzbT/ZGlbDeQ== dependencies: - "@babel/helper-module-transforms" "^7.4.4" - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-simple-access" "^7.1.0" + "@babel/helper-create-regexp-features-plugin" "^7.12.13" + "@babel/helper-plugin-utils" "^7.12.13" -"@babel/plugin-transform-modules-systemjs@^7.4.4": +"@babel/plugin-transform-dotall-regex@^7.4.4": version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.4.4.tgz#dc83c5665b07d6c2a7b224c00ac63659ea36a405" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.4.4.tgz#361a148bc951444312c69446d76ed1ea8e4450c3" dependencies: - "@babel/helper-hoist-variables" "^7.4.4" "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-regex" "^7.4.4" + regexpu-core "^4.5.4" -"@babel/plugin-transform-modules-umd@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.2.0.tgz#7678ce75169f0877b8eb2235538c074268dd01ae" +"@babel/plugin-transform-duplicate-keys@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.12.13.tgz#6f06b87a8b803fd928e54b81c258f0a0033904de" + integrity sha512-NfADJiiHdhLBW3pulJlJI2NB0t4cci4WTZ8FtdIuNc2+8pslXdPtRRAEWqUY+m9kNOk2eRYbTAOipAxlrOcwwQ== dependencies: - "@babel/helper-module-transforms" "^7.1.0" - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.12.13" -"@babel/plugin-transform-named-capturing-groups-regex@^7.4.5": - version "7.4.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.4.5.tgz#9d269fd28a370258199b4294736813a60bbdd106" +"@babel/plugin-transform-exponentiation-operator@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.12.13.tgz#4d52390b9a273e651e4aba6aee49ef40e80cd0a1" + integrity sha512-fbUelkM1apvqez/yYx1/oICVnGo2KM5s63mhGylrmXUxK/IAXSIf87QIxVfZldWf4QsOafY6vV3bX8aMHSvNrA== dependencies: - regexp-tree "^0.1.6" + "@babel/helper-builder-binary-assignment-operator-visitor" "^7.12.13" + "@babel/helper-plugin-utils" "^7.12.13" -"@babel/plugin-transform-new-target@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.4.4.tgz#18d120438b0cc9ee95a47f2c72bc9768fbed60a5" +"@babel/plugin-transform-for-of@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.13.0.tgz#c799f881a8091ac26b54867a845c3e97d2696062" + integrity sha512-IHKT00mwUVYE0zzbkDgNRP6SRzvfGCYsOxIRz8KsiaaHCcT9BWIkO+H9QRJseHBLOGBZkHUdHiqj6r0POsdytg== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.13.0" -"@babel/plugin-transform-object-super@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.2.0.tgz#b35d4c10f56bab5d650047dad0f1d8e8814b6598" +"@babel/plugin-transform-function-name@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.12.13.tgz#bb024452f9aaed861d374c8e7a24252ce3a50051" + integrity sha512-6K7gZycG0cmIwwF7uMK/ZqeCikCGVBdyP2J5SKNCXO5EOHcqi+z7Jwf8AmyDNcBgxET8DrEtCt/mPKPyAzXyqQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-replace-supers" "^7.1.0" + "@babel/helper-function-name" "^7.12.13" + "@babel/helper-plugin-utils" "^7.12.13" -"@babel/plugin-transform-parameters@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.4.4.tgz#7556cf03f318bd2719fe4c922d2d808be5571e16" - dependencies: - "@babel/helper-call-delegate" "^7.4.4" - "@babel/helper-get-function-arity" "^7.0.0" - "@babel/helper-plugin-utils" "^7.0.0" - -"@babel/plugin-transform-property-literals@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.2.0.tgz#03e33f653f5b25c4eb572c98b9485055b389e905" +"@babel/plugin-transform-literals@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-literals/-/plugin-transform-literals-7.12.13.tgz#2ca45bafe4a820197cf315794a4d26560fe4bdb9" + integrity sha512-FW+WPjSR7hiUxMcKqyNjP05tQ2kmBCdpEpZHY1ARm96tGQCCBvXKnpjILtDplUnJ/eHZ0lALLM+d2lMFSpYJrQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.12.13" -"@babel/plugin-transform-regenerator@^7.4.5": - version "7.4.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.4.5.tgz#629dc82512c55cee01341fb27bdfcb210354680f" +"@babel/plugin-transform-member-expression-literals@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.12.13.tgz#5ffa66cd59b9e191314c9f1f803b938e8c081e40" + integrity sha512-kxLkOsg8yir4YeEPHLuO2tXP9R/gTjpuTOjshqSpELUN3ZAg2jfDnKUvzzJxObun38sw3wm4Uu69sX/zA7iRvg== dependencies: - regenerator-transform "^0.14.0" + "@babel/helper-plugin-utils" "^7.12.13" -"@babel/plugin-transform-reserved-words@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.2.0.tgz#4792af87c998a49367597d07fedf02636d2e1634" +"@babel/plugin-transform-modules-amd@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.13.0.tgz#19f511d60e3d8753cc5a6d4e775d3a5184866cc3" + integrity sha512-EKy/E2NHhY/6Vw5d1k3rgoobftcNUmp9fGjb9XZwQLtTctsRBOTRO7RHHxfIky1ogMN5BxN7p9uMA3SzPfotMQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-module-transforms" "^7.13.0" + "@babel/helper-plugin-utils" "^7.13.0" + babel-plugin-dynamic-import-node "^2.3.3" -"@babel/plugin-transform-shorthand-properties@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.2.0.tgz#6333aee2f8d6ee7e28615457298934a3b46198f0" +"@babel/plugin-transform-modules-commonjs@^7.13.8": + version "7.13.8" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.13.8.tgz#7b01ad7c2dcf2275b06fa1781e00d13d420b3e1b" + integrity sha512-9QiOx4MEGglfYZ4XOnU79OHr6vIWUakIj9b4mioN8eQIoEh+pf5p/zEB36JpDFWA12nNMiRf7bfoRvl9Rn79Bw== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-module-transforms" "^7.13.0" + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/helper-simple-access" "^7.12.13" + babel-plugin-dynamic-import-node "^2.3.3" -"@babel/plugin-transform-spread@^7.2.0": - version "7.2.2" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-spread/-/plugin-transform-spread-7.2.2.tgz#3103a9abe22f742b6d406ecd3cd49b774919b406" +"@babel/plugin-transform-modules-systemjs@^7.13.8": + version "7.13.8" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.13.8.tgz#6d066ee2bff3c7b3d60bf28dec169ad993831ae3" + integrity sha512-hwqctPYjhM6cWvVIlOIe27jCIBgHCsdH2xCJVAYQm7V5yTMoilbVMi9f6wKg0rpQAOn6ZG4AOyvCqFF/hUh6+A== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-hoist-variables" "^7.13.0" + "@babel/helper-module-transforms" "^7.13.0" + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/helper-validator-identifier" "^7.12.11" + babel-plugin-dynamic-import-node "^2.3.3" -"@babel/plugin-transform-sticky-regex@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.2.0.tgz#a1e454b5995560a9c1e0d537dfc15061fd2687e1" +"@babel/plugin-transform-modules-umd@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.13.0.tgz#8a3d96a97d199705b9fd021580082af81c06e70b" + integrity sha512-D/ILzAh6uyvkWjKKyFE/W0FzWwasv6vPTSqPcjxFqn6QpX3u8DjRVliq4F2BamO2Wee/om06Vyy+vPkNrd4wxw== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-regex" "^7.0.0" + "@babel/helper-module-transforms" "^7.13.0" + "@babel/helper-plugin-utils" "^7.13.0" -"@babel/plugin-transform-template-literals@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.4.4.tgz#9d28fea7bbce637fb7612a0750989d8321d4bcb0" +"@babel/plugin-transform-named-capturing-groups-regex@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.12.13.tgz#2213725a5f5bbbe364b50c3ba5998c9599c5c9d9" + integrity sha512-Xsm8P2hr5hAxyYblrfACXpQKdQbx4m2df9/ZZSQ8MAhsadw06+jW7s9zsSw6he+mJZXRlVMyEnVktJo4zjk1WA== dependencies: - "@babel/helper-annotate-as-pure" "^7.0.0" - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-create-regexp-features-plugin" "^7.12.13" -"@babel/plugin-transform-typeof-symbol@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.2.0.tgz#117d2bcec2fbf64b4b59d1f9819894682d29f2b2" +"@babel/plugin-transform-new-target@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.12.13.tgz#e22d8c3af24b150dd528cbd6e685e799bf1c351c" + integrity sha512-/KY2hbLxrG5GTQ9zzZSc3xWiOy379pIETEhbtzwZcw9rvuaVV4Fqy7BYGYOWZnaoXIQYbbJ0ziXLa/sKcGCYEQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.12.13" -"@babel/plugin-transform-unicode-regex@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.4.4.tgz#ab4634bb4f14d36728bf5978322b35587787970f" - dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-regex" "^7.4.4" - regexpu-core "^4.5.4" - -"@babel/preset-env@^7.4.5": - version "7.4.5" - resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.4.5.tgz#2fad7f62983d5af563b5f3139242755884998a58" +"@babel/plugin-transform-object-super@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.12.13.tgz#b4416a2d63b8f7be314f3d349bd55a9c1b5171f7" + integrity sha512-JzYIcj3XtYspZDV8j9ulnoMPZZnF/Cj0LUxPOjR89BdBVx+zYJI9MdMIlUZjbXDX+6YVeS6I3e8op+qQ3BYBoQ== + dependencies: + "@babel/helper-plugin-utils" "^7.12.13" + "@babel/helper-replace-supers" "^7.12.13" + +"@babel/plugin-transform-parameters@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.13.0.tgz#8fa7603e3097f9c0b7ca1a4821bc2fb52e9e5007" + integrity sha512-Jt8k/h/mIwE2JFEOb3lURoY5C85ETcYPnbuAJ96zRBzh1XHtQZfs62ChZ6EP22QlC8c7Xqr9q+e1SU5qttwwjw== + dependencies: + "@babel/helper-plugin-utils" "^7.13.0" + +"@babel/plugin-transform-property-literals@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.12.13.tgz#4e6a9e37864d8f1b3bc0e2dce7bf8857db8b1a81" + integrity sha512-nqVigwVan+lR+g8Fj8Exl0UQX2kymtjcWfMOYM1vTYEKujeyv2SkMgazf2qNcK7l4SDiKyTA/nHCPqL4e2zo1A== + dependencies: + "@babel/helper-plugin-utils" "^7.12.13" + +"@babel/plugin-transform-regenerator@^7.13.15": + version "7.13.15" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.13.15.tgz#e5eb28945bf8b6563e7f818945f966a8d2997f39" + integrity sha512-Bk9cOLSz8DiurcMETZ8E2YtIVJbFCPGW28DJWUakmyVWtQSm6Wsf0p4B4BfEr/eL2Nkhe/CICiUiMOCi1TPhuQ== + dependencies: + regenerator-transform "^0.14.2" + +"@babel/plugin-transform-reserved-words@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.12.13.tgz#7d9988d4f06e0fe697ea1d9803188aa18b472695" + integrity sha512-xhUPzDXxZN1QfiOy/I5tyye+TRz6lA7z6xaT4CLOjPRMVg1ldRf0LHw0TDBpYL4vG78556WuHdyO9oi5UmzZBg== + dependencies: + "@babel/helper-plugin-utils" "^7.12.13" + +"@babel/plugin-transform-shorthand-properties@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.12.13.tgz#db755732b70c539d504c6390d9ce90fe64aff7ad" + integrity sha512-xpL49pqPnLtf0tVluuqvzWIgLEhuPpZzvs2yabUHSKRNlN7ScYU7aMlmavOeyXJZKgZKQRBlh8rHbKiJDraTSw== + dependencies: + "@babel/helper-plugin-utils" "^7.12.13" + +"@babel/plugin-transform-spread@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-spread/-/plugin-transform-spread-7.13.0.tgz#84887710e273c1815ace7ae459f6f42a5d31d5fd" + integrity sha512-V6vkiXijjzYeFmQTr3dBxPtZYLPcUfY34DebOU27jIl2M/Y8Egm52Hw82CSjjPqd54GTlJs5x+CR7HeNr24ckg== + dependencies: + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/helper-skip-transparent-expression-wrappers" "^7.12.1" + +"@babel/plugin-transform-sticky-regex@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.12.13.tgz#760ffd936face73f860ae646fb86ee82f3d06d1f" + integrity sha512-Jc3JSaaWT8+fr7GRvQP02fKDsYk4K/lYwWq38r/UGfaxo89ajud321NH28KRQ7xy1Ybc0VUE5Pz8psjNNDUglg== + dependencies: + "@babel/helper-plugin-utils" "^7.12.13" + +"@babel/plugin-transform-template-literals@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.13.0.tgz#a36049127977ad94438dee7443598d1cefdf409d" + integrity sha512-d67umW6nlfmr1iehCcBv69eSUSySk1EsIS8aTDX4Xo9qajAh6mYtcl4kJrBkGXuxZPEgVr7RVfAvNW6YQkd4Mw== + dependencies: + "@babel/helper-plugin-utils" "^7.13.0" + +"@babel/plugin-transform-typeof-symbol@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.12.13.tgz#785dd67a1f2ea579d9c2be722de8c84cb85f5a7f" + integrity sha512-eKv/LmUJpMnu4npgfvs3LiHhJua5fo/CysENxa45YCQXZwKnGCQKAg87bvoqSW1fFT+HA32l03Qxsm8ouTY3ZQ== + dependencies: + "@babel/helper-plugin-utils" "^7.12.13" + +"@babel/plugin-transform-unicode-escapes@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.12.13.tgz#840ced3b816d3b5127dd1d12dcedc5dead1a5e74" + integrity sha512-0bHEkdwJ/sN/ikBHfSmOXPypN/beiGqjo+o4/5K+vxEFNPRPdImhviPakMKG4x96l85emoa0Z6cDflsdBusZbw== + dependencies: + "@babel/helper-plugin-utils" "^7.12.13" + +"@babel/plugin-transform-unicode-regex@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.12.13.tgz#b52521685804e155b1202e83fc188d34bb70f5ac" + integrity sha512-mDRzSNY7/zopwisPZ5kM9XKCfhchqIYwAKRERtEnhYscZB79VRekuRSoYbN0+KVe3y8+q1h6A4svXtP7N+UoCA== + dependencies: + "@babel/helper-create-regexp-features-plugin" "^7.12.13" + "@babel/helper-plugin-utils" "^7.12.13" + +"@babel/preset-env@^7.13.15": + version "7.13.15" + resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.13.15.tgz#c8a6eb584f96ecba183d3d414a83553a599f478f" + integrity sha512-D4JAPMXcxk69PKe81jRJ21/fP/uYdcTZ3hJDF5QX2HSI9bBxxYw/dumdR6dGumhjxlprHPE4XWoPaqzZUVy2MA== + dependencies: + "@babel/compat-data" "^7.13.15" + "@babel/helper-compilation-targets" "^7.13.13" + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/helper-validator-option" "^7.12.17" + "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining" "^7.13.12" + "@babel/plugin-proposal-async-generator-functions" "^7.13.15" + "@babel/plugin-proposal-class-properties" "^7.13.0" + "@babel/plugin-proposal-dynamic-import" "^7.13.8" + "@babel/plugin-proposal-export-namespace-from" "^7.12.13" + "@babel/plugin-proposal-json-strings" "^7.13.8" + "@babel/plugin-proposal-logical-assignment-operators" "^7.13.8" + "@babel/plugin-proposal-nullish-coalescing-operator" "^7.13.8" + "@babel/plugin-proposal-numeric-separator" "^7.12.13" + "@babel/plugin-proposal-object-rest-spread" "^7.13.8" + "@babel/plugin-proposal-optional-catch-binding" "^7.13.8" + "@babel/plugin-proposal-optional-chaining" "^7.13.12" + "@babel/plugin-proposal-private-methods" "^7.13.0" + "@babel/plugin-proposal-unicode-property-regex" "^7.12.13" + "@babel/plugin-syntax-async-generators" "^7.8.4" + "@babel/plugin-syntax-class-properties" "^7.12.13" + "@babel/plugin-syntax-dynamic-import" "^7.8.3" + "@babel/plugin-syntax-export-namespace-from" "^7.8.3" + "@babel/plugin-syntax-json-strings" "^7.8.3" + "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" + "@babel/plugin-syntax-numeric-separator" "^7.10.4" + "@babel/plugin-syntax-object-rest-spread" "^7.8.3" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" + "@babel/plugin-syntax-optional-chaining" "^7.8.3" + "@babel/plugin-syntax-top-level-await" "^7.12.13" + "@babel/plugin-transform-arrow-functions" "^7.13.0" + "@babel/plugin-transform-async-to-generator" "^7.13.0" + "@babel/plugin-transform-block-scoped-functions" "^7.12.13" + "@babel/plugin-transform-block-scoping" "^7.12.13" + "@babel/plugin-transform-classes" "^7.13.0" + "@babel/plugin-transform-computed-properties" "^7.13.0" + "@babel/plugin-transform-destructuring" "^7.13.0" + "@babel/plugin-transform-dotall-regex" "^7.12.13" + "@babel/plugin-transform-duplicate-keys" "^7.12.13" + "@babel/plugin-transform-exponentiation-operator" "^7.12.13" + "@babel/plugin-transform-for-of" "^7.13.0" + "@babel/plugin-transform-function-name" "^7.12.13" + "@babel/plugin-transform-literals" "^7.12.13" + "@babel/plugin-transform-member-expression-literals" "^7.12.13" + "@babel/plugin-transform-modules-amd" "^7.13.0" + "@babel/plugin-transform-modules-commonjs" "^7.13.8" + "@babel/plugin-transform-modules-systemjs" "^7.13.8" + "@babel/plugin-transform-modules-umd" "^7.13.0" + "@babel/plugin-transform-named-capturing-groups-regex" "^7.12.13" + "@babel/plugin-transform-new-target" "^7.12.13" + "@babel/plugin-transform-object-super" "^7.12.13" + "@babel/plugin-transform-parameters" "^7.13.0" + "@babel/plugin-transform-property-literals" "^7.12.13" + "@babel/plugin-transform-regenerator" "^7.13.15" + "@babel/plugin-transform-reserved-words" "^7.12.13" + "@babel/plugin-transform-shorthand-properties" "^7.12.13" + "@babel/plugin-transform-spread" "^7.13.0" + "@babel/plugin-transform-sticky-regex" "^7.12.13" + "@babel/plugin-transform-template-literals" "^7.13.0" + "@babel/plugin-transform-typeof-symbol" "^7.12.13" + "@babel/plugin-transform-unicode-escapes" "^7.12.13" + "@babel/plugin-transform-unicode-regex" "^7.12.13" + "@babel/preset-modules" "^0.1.4" + "@babel/types" "^7.13.14" + babel-plugin-polyfill-corejs2 "^0.2.0" + babel-plugin-polyfill-corejs3 "^0.2.0" + babel-plugin-polyfill-regenerator "^0.2.0" + core-js-compat "^3.9.0" + semver "^6.3.0" + +"@babel/preset-modules@^0.1.4": + version "0.1.4" + resolved "https://registry.yarnpkg.com/@babel/preset-modules/-/preset-modules-0.1.4.tgz#362f2b68c662842970fdb5e254ffc8fc1c2e415e" + integrity sha512-J36NhwnfdzpmH41M1DrnkkgAqhZaqr/NBdPfQ677mLzlaXo+oDiv1deyCDtgAhz8p328otdob0Du7+xgHGZbKg== dependencies: - "@babel/helper-module-imports" "^7.0.0" "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-proposal-async-generator-functions" "^7.2.0" - "@babel/plugin-proposal-json-strings" "^7.2.0" - "@babel/plugin-proposal-object-rest-spread" "^7.4.4" - "@babel/plugin-proposal-optional-catch-binding" "^7.2.0" "@babel/plugin-proposal-unicode-property-regex" "^7.4.4" - "@babel/plugin-syntax-async-generators" "^7.2.0" - "@babel/plugin-syntax-json-strings" "^7.2.0" - "@babel/plugin-syntax-object-rest-spread" "^7.2.0" - "@babel/plugin-syntax-optional-catch-binding" "^7.2.0" - "@babel/plugin-transform-arrow-functions" "^7.2.0" - "@babel/plugin-transform-async-to-generator" "^7.4.4" - "@babel/plugin-transform-block-scoped-functions" "^7.2.0" - "@babel/plugin-transform-block-scoping" "^7.4.4" - "@babel/plugin-transform-classes" "^7.4.4" - "@babel/plugin-transform-computed-properties" "^7.2.0" - "@babel/plugin-transform-destructuring" "^7.4.4" "@babel/plugin-transform-dotall-regex" "^7.4.4" - "@babel/plugin-transform-duplicate-keys" "^7.2.0" - "@babel/plugin-transform-exponentiation-operator" "^7.2.0" - "@babel/plugin-transform-for-of" "^7.4.4" - "@babel/plugin-transform-function-name" "^7.4.4" - "@babel/plugin-transform-literals" "^7.2.0" - "@babel/plugin-transform-member-expression-literals" "^7.2.0" - "@babel/plugin-transform-modules-amd" "^7.2.0" - "@babel/plugin-transform-modules-commonjs" "^7.4.4" - "@babel/plugin-transform-modules-systemjs" "^7.4.4" - "@babel/plugin-transform-modules-umd" "^7.2.0" - "@babel/plugin-transform-named-capturing-groups-regex" "^7.4.5" - "@babel/plugin-transform-new-target" "^7.4.4" - "@babel/plugin-transform-object-super" "^7.2.0" - "@babel/plugin-transform-parameters" "^7.4.4" - "@babel/plugin-transform-property-literals" "^7.2.0" - "@babel/plugin-transform-regenerator" "^7.4.5" - "@babel/plugin-transform-reserved-words" "^7.2.0" - "@babel/plugin-transform-shorthand-properties" "^7.2.0" - "@babel/plugin-transform-spread" "^7.2.0" - "@babel/plugin-transform-sticky-regex" "^7.2.0" - "@babel/plugin-transform-template-literals" "^7.4.4" - "@babel/plugin-transform-typeof-symbol" "^7.2.0" - "@babel/plugin-transform-unicode-regex" "^7.4.4" "@babel/types" "^7.4.4" - browserslist "^4.6.0" - core-js-compat "^3.1.1" - invariant "^2.2.2" - js-levenshtein "^1.1.3" - semver "^5.5.0" + esutils "^2.0.2" -"@babel/register@^7.4.4": - version "7.4.4" - resolved "https://registry.npmjs.org/@babel/register/-/register-7.4.4.tgz#370a68ba36f08f015a8b35d4864176c6b65d7a23" +"@babel/register@^7.13.16": + version "7.13.16" + resolved "https://registry.yarnpkg.com/@babel/register/-/register-7.13.16.tgz#ae3ab0b55c8ec28763877383c454f01521d9a53d" + integrity sha512-dh2t11ysujTwByQjXNgJ48QZ2zcXKQVdV8s0TbeMI0flmtGWCdTwK9tJiACHXPLmncm5+ktNn/diojA45JE4jg== dependencies: - core-js "^3.0.0" + clone-deep "^4.0.1" find-cache-dir "^2.0.0" - lodash "^4.17.11" - mkdirp "^0.5.1" + make-dir "^2.1.0" pirates "^4.0.0" - source-map-support "^0.5.9" + source-map-support "^0.5.16" + +"@babel/runtime@^7.8.4": + version "7.13.17" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.13.17.tgz#8966d1fc9593bf848602f0662d6b4d0069e3a7ec" + integrity sha512-NCdgJEelPTSh+FEFylhnP1ylq848l1z9t9N0j1Lfbcw0+KXGjsTvUmkxy+voLLXB5SOKMbLLx4jxYliGrYQseA== + dependencies: + regenerator-runtime "^0.13.4" -"@babel/template@^7.1.0", "@babel/template@^7.4.4": +"@babel/template@^7.1.0": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.4.4.tgz#f4b88d1225689a08f5bc3a17483545be9e4ed237" dependencies: @@ -538,7 +892,16 @@ "@babel/parser" "^7.4.4" "@babel/types" "^7.4.4" -"@babel/traverse@^7.0.0", "@babel/traverse@^7.1.0", "@babel/traverse@^7.4.4", "@babel/traverse@^7.4.5": +"@babel/template@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.12.13.tgz#530265be8a2589dbb37523844c5bcb55947fb327" + integrity sha512-/7xxiGA57xMo/P2GVvdEumr8ONhFOhfgq2ihK3h1e6THqzTAkHbkXgB0xI9yeTfIUoH3+oAeHhqm/I43OTbbjA== + dependencies: + "@babel/code-frame" "^7.12.13" + "@babel/parser" "^7.12.13" + "@babel/types" "^7.12.13" + +"@babel/traverse@^7.0.0": version "7.4.5" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.4.5.tgz#4e92d1728fd2f1897dafdd321efbff92156c3216" dependencies: @@ -552,7 +915,21 @@ globals "^11.1.0" lodash "^4.17.11" -"@babel/types@^7.0.0", "@babel/types@^7.2.0", "@babel/types@^7.4.4": +"@babel/traverse@^7.13.0", "@babel/traverse@^7.13.13", "@babel/traverse@^7.13.15", "@babel/traverse@^7.13.17": + version "7.13.17" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.13.17.tgz#c85415e0c7d50ac053d758baec98b28b2ecfeea3" + integrity sha512-BMnZn0R+X6ayqm3C3To7o1j7Q020gWdqdyP50KEoVqaCO2c/Im7sYZSmVgvefp8TTMQ+9CtwuBp0Z1CZ8V3Pvg== + dependencies: + "@babel/code-frame" "^7.12.13" + "@babel/generator" "^7.13.16" + "@babel/helper-function-name" "^7.12.13" + "@babel/helper-split-export-declaration" "^7.12.13" + "@babel/parser" "^7.13.16" + "@babel/types" "^7.13.17" + debug "^4.1.0" + globals "^11.1.0" + +"@babel/types@^7.0.0", "@babel/types@^7.4.4": version "7.4.4" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.4.4.tgz#8db9e9a629bb7c29370009b4b779ed93fe57d5f0" dependencies: @@ -560,6 +937,14 @@ lodash "^4.17.11" to-fast-properties "^2.0.0" +"@babel/types@^7.12.1", "@babel/types@^7.12.13", "@babel/types@^7.13.0", "@babel/types@^7.13.12", "@babel/types@^7.13.14", "@babel/types@^7.13.16", "@babel/types@^7.13.17": + version "7.13.17" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.13.17.tgz#48010a115c9fba7588b4437dd68c9469012b38b4" + integrity sha512-RawydLgxbOPDlTLJNtoIypwdmAy//uQIzlKt2+iBiJaRlVuI6QLUxVAyWGNfOzp8Yu4L4lLIacoCyTNtpb4wiA== + dependencies: + "@babel/helper-validator-identifier" "^7.12.11" + to-fast-properties "^2.0.0" + "@sinonjs/commons@^1", "@sinonjs/commons@^1.4.0": version "1.4.0" resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-1.4.0.tgz#7b3ec2d96af481d7a0321252e7b1c94724ec5a78" @@ -609,9 +994,10 @@ acorn-jsx@^3.0.0: dependencies: acorn "^3.0.4" -acorn-jsx@^5.0.0: - version "5.0.1" - resolved "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.0.1.tgz#32a064fd925429216a09b141102bfdd185fae40e" +acorn-jsx@^5.2.0: + version "5.3.1" + resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.3.1.tgz#fc8661e11b7ac1539c47dbfea2e72b3af34d267b" + integrity sha512-K0Ptm/47OKfQRpNQ2J/oIN/3QYiK6FwW+eJbILhsdxh2WTLdl+30o8aGdTbm5JbffpFFAg/g+zi1E+jvJha5ng== acorn@^3.0.4: version "3.3.0" @@ -621,9 +1007,10 @@ acorn@^5.5.0: version "5.7.3" resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.3.tgz#67aa231bf8812974b85235a96771eb6bd07ea279" -acorn@^6.0.7: - version "6.1.1" - resolved "https://registry.npmjs.org/acorn/-/acorn-6.1.1.tgz#7d25ae05bb8ad1f9b699108e1094ecd7884adc1f" +acorn@^7.1.1: + version "7.4.1" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.4.1.tgz#feaed255973d2e77555b83dbc08851a6c63520fa" + integrity sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A== ajv-keywords@^2.1.0: version "2.1.1" @@ -674,10 +1061,17 @@ ansi-cyan@^0.1.1: dependencies: ansi-wrap "0.1.0" -ansi-escapes@^3.0.0, ansi-escapes@^3.2.0: +ansi-escapes@^3.0.0: version "3.2.0" resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.2.0.tgz#8780b98ff9dbf5638152d1f1fe5c1d7b4442976b" +ansi-escapes@^4.2.1: + version "4.3.2" + resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-4.3.2.tgz#6b2291d1db7d98b6521d5f1efa42d0f3a9feb65e" + integrity sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ== + dependencies: + type-fest "^0.21.3" + ansi-gray@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/ansi-gray/-/ansi-gray-0.1.1.tgz#2962cf54ec9792c48510a3deb524436861ef7251" @@ -703,6 +1097,11 @@ ansi-regex@^4.1.0: version "4.1.0" resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz#8b9f8f08cf1acb843756a839ca8c7e3168c51997" +ansi-regex@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.0.tgz#388539f55179bf39339c81af30a654d69f87cb75" + integrity sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg== + ansi-styles@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" @@ -713,6 +1112,13 @@ ansi-styles@^3.2.0, ansi-styles@^3.2.1: dependencies: color-convert "^1.9.0" +ansi-styles@^4.1.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" + integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== + dependencies: + color-convert "^2.0.1" + ansi-wrap@0.1.0, ansi-wrap@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/ansi-wrap/-/ansi-wrap-0.1.0.tgz#a82250ddb0015e9a27ca82e82ea603bbfa45efaf" @@ -911,6 +1317,37 @@ babel-eslint@^10.0.2: eslint-scope "3.7.1" eslint-visitor-keys "^1.0.0" +babel-plugin-dynamic-import-node@^2.3.3: + version "2.3.3" + resolved "https://registry.yarnpkg.com/babel-plugin-dynamic-import-node/-/babel-plugin-dynamic-import-node-2.3.3.tgz#84fda19c976ec5c6defef57f9427b3def66e17a3" + integrity sha512-jZVI+s9Zg3IqA/kdi0i6UDCybUI3aSBLnglhYbSSjKlV7yF1F/5LWv8MakQmvYpnbJDS6fcBL2KzHSxNCMtWSQ== + dependencies: + object.assign "^4.1.0" + +babel-plugin-polyfill-corejs2@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-corejs2/-/babel-plugin-polyfill-corejs2-0.2.0.tgz#686775bf9a5aa757e10520903675e3889caeedc4" + integrity sha512-9bNwiR0dS881c5SHnzCmmGlMkJLl0OUZvxrxHo9w/iNoRuqaPjqlvBf4HrovXtQs/au5yKkpcdgfT1cC5PAZwg== + dependencies: + "@babel/compat-data" "^7.13.11" + "@babel/helper-define-polyfill-provider" "^0.2.0" + semver "^6.1.1" + +babel-plugin-polyfill-corejs3@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-corejs3/-/babel-plugin-polyfill-corejs3-0.2.0.tgz#f4b4bb7b19329827df36ff56f6e6d367026cb7a2" + integrity sha512-zZyi7p3BCUyzNxLx8KV61zTINkkV65zVkDAFNZmrTCRVhjo1jAS+YLvDJ9Jgd/w2tsAviCwFHReYfxO3Iql8Yg== + dependencies: + "@babel/helper-define-polyfill-provider" "^0.2.0" + core-js-compat "^3.9.1" + +babel-plugin-polyfill-regenerator@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-regenerator/-/babel-plugin-polyfill-regenerator-0.2.0.tgz#853f5f5716f4691d98c84f8069c7636ea8da7ab8" + integrity sha512-J7vKbCuD2Xi/eEHxquHN14bXAW9CXtecwuLrOIDJtcZzTaPzV1VdEfoUf9AzcRBMolKUQKM9/GVojeh0hFiqMg== + dependencies: + "@babel/helper-define-polyfill-provider" "^0.2.0" + bach@^1.0.0: version "1.2.0" resolved "https://registry.yarnpkg.com/bach/-/bach-1.2.0.tgz#4b3ce96bf27134f79a1b414a51c14e34c3bd9880" @@ -951,9 +1388,10 @@ binary-extensions@^1.0.0: version "1.13.1" resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-1.13.1.tgz#598afe54755b2868a5330d2aff9d4ebb53209b65" -bluebird@^3.3.4: - version "3.5.1" - resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.5.1.tgz#d9551f9de98f1fcda1e683d17ee91a0602ee2eb9" +bluebird@^3.7.2: + version "3.7.2" + resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.7.2.tgz#9f229c15be272454ffa973ace0dbee79a1b0c36f" + integrity sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg== brace-expansion@^1.1.7: version "1.1.8" @@ -981,13 +1419,16 @@ browser-stdout@1.3.1: version "1.3.1" resolved "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz#baa559ee14ced73452229bad7326467c61fabd60" -browserslist@^4.6.0, browserslist@^4.6.2: - version "4.6.3" - resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.6.3.tgz#0530cbc6ab0c1f3fc8c819c72377ba55cf647f05" +browserslist@^4.14.5, browserslist@^4.16.4: + version "4.16.5" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.16.5.tgz#952825440bca8913c62d0021334cbe928ef062ae" + integrity sha512-C2HAjrM1AI/djrpAUU/tr4pml1DqLIzJKSLDBXBrNErl9ZCCTXdhwxdJjYc16953+mBWf7Lw+uUJgpgb8cN71A== dependencies: - caniuse-lite "^1.0.30000975" - electron-to-chromium "^1.3.164" - node-releases "^1.1.23" + caniuse-lite "^1.0.30001214" + colorette "^1.2.2" + electron-to-chromium "^1.3.719" + escalade "^3.1.1" + node-releases "^1.1.71" buffer-equal@^1.0.0: version "1.0.0" @@ -1011,6 +1452,14 @@ cache-base@^1.0.1: union-value "^1.0.0" unset-value "^1.0.0" +call-bind@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/call-bind/-/call-bind-1.0.2.tgz#b1d4e89e688119c3c9a903ad30abb2f6a919be3c" + integrity sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA== + dependencies: + function-bind "^1.1.1" + get-intrinsic "^1.0.2" + caller-path@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/caller-path/-/caller-path-0.1.0.tgz#94085ef63581ecd3daa92444a8fe94e82577751f" @@ -1029,9 +1478,10 @@ camelcase@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-3.0.0.tgz#32fc4b9fcdaf845fcdf7e73bb97cac2261f0ab0a" -caniuse-lite@^1.0.30000975: - version "1.0.30000979" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000979.tgz#92f16d00186a6cf20d6c5711bb6e042a3d667029" +caniuse-lite@^1.0.30001214: + version "1.0.30001218" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001218.tgz#9b44f6ed16f875db6373e2debd4d14a07359002f" + integrity sha512-0ASydOWSy3bB88FbDpJSTt+PfDwnMqrym3yRZfqG8EXSQ06OZhF+q5wgYP/EN+jJMERItNcDQUqMyNjzZ+r5+Q== caseless@~0.12.0: version "0.12.0" @@ -1055,7 +1505,7 @@ chalk@^1.1.3: strip-ansi "^3.0.0" supports-color "^2.0.0" -chalk@^2.0.0, chalk@^2.1.0, chalk@^2.4.2: +chalk@^2.0.0, chalk@^2.1.0: version "2.4.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" dependencies: @@ -1063,6 +1513,14 @@ chalk@^2.0.0, chalk@^2.1.0, chalk@^2.4.2: escape-string-regexp "^1.0.5" supports-color "^5.3.0" +chalk@^4.1.0: + version "4.1.1" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.1.tgz#c80b3fab28bf6371e6863325eee67e618b77e6ad" + integrity sha512-diHzdDKxcU+bAsUboHLPEDQiw0qEe0qd7SYUn3HgcFlWgbDcfLGswOHYeGrHKzG9z6UYf01d9VFMfZxPM1xZSg== + dependencies: + ansi-styles "^4.1.0" + supports-color "^7.1.0" + chardet@^0.4.0: version "0.4.2" resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.4.2.tgz#b5473b33dc97c424e5d98dc87d55d4d8a29c8bf2" @@ -1112,10 +1570,22 @@ cli-cursor@^2.1.0: dependencies: restore-cursor "^2.0.0" +cli-cursor@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-3.1.0.tgz#264305a7ae490d1d03bf0c9ba7c925d1753af307" + integrity sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw== + dependencies: + restore-cursor "^3.1.0" + cli-width@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-2.2.0.tgz#ff19ede8a9a5e579324147b0c11f0fbcbabed639" +cli-width@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-3.0.0.tgz#a2f48437a2caa9a22436e794bf071ec9e61cedf6" + integrity sha512-FxqpkPPwu1HjuN93Omfm4h8uIanXofW0RxVEW3k5RKx+mJJYSthzNhp32Kzxxy3YAEZ/Dc/EWN1vZRY0+kOhbw== + cliui@^3.2.0: version "3.2.0" resolved "https://registry.yarnpkg.com/cliui/-/cliui-3.2.0.tgz#120601537a916d29940f934da3b48d585a39213d" @@ -1128,6 +1598,15 @@ clone-buffer@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/clone-buffer/-/clone-buffer-1.0.0.tgz#e3e25b207ac4e701af721e2cb5a16792cac3dc58" +clone-deep@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/clone-deep/-/clone-deep-4.0.1.tgz#c19fd9bdbbf85942b4fd979c84dcf7d5f07c2387" + integrity sha512-neHB9xuzh/wk0dIHweyAXv2aPGZIVk3pLMe+/RNzINf17fe0OG96QroktYAUm7SM1PBnzTabaLboqqxDyMU+SQ== + dependencies: + is-plain-object "^2.0.4" + kind-of "^6.0.2" + shallow-clone "^3.0.0" + clone-stats@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/clone-stats/-/clone-stats-1.0.0.tgz#b3782dff8bb5474e18b9b6bf0fdfe782f8777680" @@ -1173,14 +1652,31 @@ color-convert@^1.9.0: dependencies: color-name "1.1.3" +color-convert@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" + integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== + dependencies: + color-name "~1.1.4" + color-name@1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" +color-name@~1.1.4: + version "1.1.4" + resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" + integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== + color-support@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/color-support/-/color-support-1.1.3.tgz#93834379a1cc9a0c61f82f52f0d04322251bd5a2" +colorette@^1.2.2: + version "1.2.2" + resolved "https://registry.yarnpkg.com/colorette/-/colorette-1.2.2.tgz#cbcc79d5e99caea2dbf10eb3a26fd8b3e6acfa94" + integrity sha512-MKGMzyfeuutC/ZJ1cba9NqcNpfeqMUcYmyF1ZFY6/Cn7CNSAKx6a+s48sqLqyAiZuaP2TcqMhoo+dlwFnVxT9w== + combined-stream@^1.0.6, combined-stream@~1.0.6: version "1.0.8" resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.8.tgz#c3d45a8b34fd730631a110a8a2520682b31d5a7f" @@ -1193,8 +1689,9 @@ commander@2.15.1: resolved "https://registry.npmjs.org/commander/-/commander-2.15.1.tgz#df46e867d0fc2aec66a34662b406a9ccafff5b0f" commander@~2.20.0: - version "2.20.0" - resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.0.tgz#d58bb2b5c1ee8f87b0d340027e9e94e222c5a422" + version "2.20.3" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" + integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ== commondir@^1.0.1: version "1.0.1" @@ -1221,16 +1718,17 @@ console-control-strings@^1.0.0, console-control-strings@~1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/console-control-strings/-/console-control-strings-1.1.0.tgz#3d7cf4464db6446ea644bf4b39507f9851008e8e" -convert-source-map@^1.1.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.6.0.tgz#51b537a8c43e0f04dec1993bffcdd504e758ac20" - dependencies: - safe-buffer "~5.1.1" - convert-source-map@^1.5.0: version "1.5.0" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.5.0.tgz#9acd70851c6d5dfdd93d9282e5edf94a03ff46b5" +convert-source-map@^1.7.0: + version "1.7.0" + resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.7.0.tgz#17a2cb882d7f77d3490585e2ce6c524424a3a442" + integrity sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA== + dependencies: + safe-buffer "~5.1.1" + copy-descriptor@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" @@ -1242,21 +1740,13 @@ copy-props@^2.0.1: each-props "^1.3.0" is-plain-object "^2.0.1" -core-js-compat@^3.1.1: - version "3.1.4" - resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.1.4.tgz#e4d0c40fbd01e65b1d457980fe4112d4358a7408" +core-js-compat@^3.9.0, core-js-compat@^3.9.1: + version "3.11.0" + resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.11.0.tgz#635683f43480a0b41e3f6be3b1c648dadb8b4390" + integrity sha512-3wsN9YZJohOSDCjVB0GequOyHax8zFiogSX3XWLE28M1Ew7dTU57tgHjIylSBKSIouwmLBp3g61sKMz/q3xEGA== dependencies: - browserslist "^4.6.2" - core-js-pure "3.1.4" - semver "^6.1.1" - -core-js-pure@3.1.4: - version "3.1.4" - resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.1.4.tgz#5fa17dc77002a169a3566cc48dc774d2e13e3769" - -core-js@^3.0.0: - version "3.1.4" - resolved "https://registry.npmjs.org/core-js/-/core-js-3.1.4.tgz#3a2837fc48e582e1ae25907afcd6cf03b0cc7a07" + browserslist "^4.16.4" + semver "7.0.0" core-util-is@1.0.2, core-util-is@~1.0.0: version "1.0.2" @@ -1321,6 +1811,13 @@ debug@^4.0.1, debug@^4.1.0: dependencies: ms "^2.1.1" +debug@^4.1.1: + version "4.3.1" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.1.tgz#f0d229c505e0c6d8c49ac553d1b13dc183f6b2ee" + integrity sha512-doEwdvm4PCeK4K3RQN2ZC2BYUBaxwLARCqZmMjtF8a51J2Rb0xpVloFRnCODwqjpwnAoao4pelN8l3RJdv3gRQ== + dependencies: + ms "2.1.2" + decamelize@^1.1.1: version "1.2.0" resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" @@ -1357,9 +1854,10 @@ default-resolution@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/default-resolution/-/default-resolution-2.0.0.tgz#bcb82baa72ad79b426a76732f1a81ad6df26d684" -define-properties@^1.1.2: +define-properties@^1.1.2, define-properties@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.3.tgz#cf88da6cbee26fe6db7094f61d870cbd84cee9f1" + integrity sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ== dependencies: object-keys "^1.0.12" @@ -1437,14 +1935,20 @@ ecc-jsbn@~0.1.1: jsbn "~0.1.0" safer-buffer "^2.1.0" -electron-to-chromium@^1.3.164: - version "1.3.185" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.185.tgz#36368514eb719632a91435f3c9f57c98b47d81de" +electron-to-chromium@^1.3.719: + version "1.3.722" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.722.tgz#621657f79e7f65402e71aa3403bc941f3a4af0a0" + integrity sha512-aAsc906l0RBsVTsGTK+KirVfey9eNtxyejdkbNzkISGxb7AFna3Kf0qvsp8tMttzBt9Bz3HddtYQ+++/PZtRYA== emoji-regex@^7.0.1: version "7.0.3" resolved "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz#933a04052860c85e83c122479c4748a8e4c72156" +emoji-regex@^8.0.0: + version "8.0.0" + resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" + integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== + end-of-stream@^1.0.0, end-of-stream@^1.1.0: version "1.4.1" resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.1.tgz#ed29634d19baba463b6ce6b80a37213eab71ec43" @@ -1489,6 +1993,11 @@ es6-weak-map@^2.0.1: es6-iterator "^2.0.3" es6-symbol "^3.1.1" +escalade@^3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.1.1.tgz#d8cfdc7000965c5a0174b4a82eaa5c0552742e40" + integrity sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw== + escape-string-regexp@1.0.5, escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" @@ -1518,21 +2027,30 @@ eslint-scope@^3.7.1: esrecurse "^4.1.0" estraverse "^4.1.1" -eslint-scope@^4.0.3: - version "4.0.3" - resolved "https://registry.npmjs.org/eslint-scope/-/eslint-scope-4.0.3.tgz#ca03833310f6889a3264781aa82e63eb9cfe7848" +eslint-scope@^5.0.0: + version "5.1.1" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-5.1.1.tgz#e786e59a66cb92b3f6c1fb0d508aab174848f48c" + integrity sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw== dependencies: - esrecurse "^4.1.0" + esrecurse "^4.3.0" estraverse "^4.1.1" -eslint-utils@^1.3.1: - version "1.3.1" - resolved "https://registry.npmjs.org/eslint-utils/-/eslint-utils-1.3.1.tgz#9a851ba89ee7c460346f97cf8939c7298827e512" +eslint-utils@^1.4.3: + version "1.4.3" + resolved "https://registry.yarnpkg.com/eslint-utils/-/eslint-utils-1.4.3.tgz#74fec7c54d0776b6f67e0251040b5806564e981f" + integrity sha512-fbBN5W2xdY45KulGXmLHZ3c3FHfVYmKg0IrAKGOkT/464PQsx2UeIzfz1RmEci+KLm1bBaAzZAh8+/E+XAeZ8Q== + dependencies: + eslint-visitor-keys "^1.1.0" eslint-visitor-keys@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" +eslint-visitor-keys@^1.1.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz#30ebd1ef7c2fdff01c3a4f151044af25fab0523e" + integrity sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ== + eslint@^4.0.0: version "4.19.1" resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.19.1.tgz#32d1d653e1d90408854bfb296f076ec7e186a300" @@ -1576,9 +2094,10 @@ eslint@^4.0.0: table "4.0.2" text-table "~0.2.0" -eslint@^6.0.1: - version "6.0.1" - resolved "https://registry.npmjs.org/eslint/-/eslint-6.0.1.tgz#4a32181d72cb999d6f54151df7d337131f81cda7" +eslint@^6.8.0: + version "6.8.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-6.8.0.tgz#62262d6729739f9275723824302fb227c8c93ffb" + integrity sha512-K+Iayyo2LtyYhDSYwz5D5QdWw0hCacNzyq1Y821Xna2xSJj7cijoLLYmLxTQgcgZ9mC61nryMy9S7GRbYpI5Ig== dependencies: "@babel/code-frame" "^7.0.0" ajv "^6.10.0" @@ -1586,36 +2105,37 @@ eslint@^6.0.1: cross-spawn "^6.0.5" debug "^4.0.1" doctrine "^3.0.0" - eslint-scope "^4.0.3" - eslint-utils "^1.3.1" - eslint-visitor-keys "^1.0.0" - espree "^6.0.0" + eslint-scope "^5.0.0" + eslint-utils "^1.4.3" + eslint-visitor-keys "^1.1.0" + espree "^6.1.2" esquery "^1.0.1" esutils "^2.0.2" file-entry-cache "^5.0.1" functional-red-black-tree "^1.0.1" - glob-parent "^3.1.0" - globals "^11.7.0" + glob-parent "^5.0.0" + globals "^12.1.0" ignore "^4.0.6" import-fresh "^3.0.0" imurmurhash "^0.1.4" - inquirer "^6.2.2" + inquirer "^7.0.0" is-glob "^4.0.0" js-yaml "^3.13.1" json-stable-stringify-without-jsonify "^1.0.1" levn "^0.3.0" - lodash "^4.17.11" + lodash "^4.17.14" minimatch "^3.0.4" mkdirp "^0.5.1" natural-compare "^1.4.0" - optionator "^0.8.2" + optionator "^0.8.3" progress "^2.0.0" regexpp "^2.0.1" - semver "^5.5.1" - strip-ansi "^4.0.0" - strip-json-comments "^2.0.1" + semver "^6.1.2" + strip-ansi "^5.2.0" + strip-json-comments "^3.0.1" table "^5.2.3" text-table "^0.2.0" + v8-compile-cache "^2.0.3" espree@^3.5.4: version "3.5.4" @@ -1624,13 +2144,14 @@ espree@^3.5.4: acorn "^5.5.0" acorn-jsx "^3.0.0" -espree@^6.0.0: - version "6.0.0" - resolved "https://registry.npmjs.org/espree/-/espree-6.0.0.tgz#716fc1f5a245ef5b9a7fdb1d7b0d3f02322e75f6" +espree@^6.1.2: + version "6.2.1" + resolved "https://registry.yarnpkg.com/espree/-/espree-6.2.1.tgz#77fc72e1fd744a2052c20f38a5b575832e82734a" + integrity sha512-ysCxRQY3WaXJz9tdbWOwuWr5Y/XrPTGX9Kiz3yoUXwW0VZ4w30HTkQLaGx/+ttFjF8i+ACbArnB4ce68a9m5hw== dependencies: - acorn "^6.0.7" - acorn-jsx "^5.0.0" - eslint-visitor-keys "^1.0.0" + acorn "^7.1.1" + acorn-jsx "^5.2.0" + eslint-visitor-keys "^1.1.0" esprima@2.7.x, esprima@^2.7.1: version "2.7.3" @@ -1653,6 +2174,13 @@ esrecurse@^4.1.0: estraverse "^4.1.0" object-assign "^4.0.1" +esrecurse@^4.3.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.3.0.tgz#7ad7964d679abb28bee72cec63758b1c5d2c9921" + integrity sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag== + dependencies: + estraverse "^5.2.0" + estraverse@^1.9.1: version "1.9.3" resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-1.9.3.tgz#af67f2dc922582415950926091a4005d29c9bb44" @@ -1661,6 +2189,11 @@ estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1: version "4.2.0" resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.2.0.tgz#0dee3fed31fcd469618ce7342099fc1afa0bdb13" +estraverse@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-5.2.0.tgz#307df42547e6cc7324d3cf03c155d5cdb8c53880" + integrity sha512-BxbNGGNm0RyRYvUdHpIwv9IWzeM9XClbOxwoATuFdOE7ZE6wHL+HQ5T8hoPM+zHvmKzzsEqhgy0GrQ5X13afiQ== + esutils@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.2.tgz#0abf4f1caa5bcb1f7a9d8acc6dea4faaa04bac9b" @@ -1774,9 +2307,10 @@ fast-json-stable-stringify@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" -fast-levenshtein@~2.0.4: +fast-levenshtein@~2.0.4, fast-levenshtein@~2.0.6: version "2.0.6" resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" + integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc= figures@^2.0.0: version "2.0.0" @@ -1784,6 +2318,13 @@ figures@^2.0.0: dependencies: escape-string-regexp "^1.0.5" +figures@^3.0.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/figures/-/figures-3.2.0.tgz#625c18bd293c604dc4a8ddb2febf0c88341746af" + integrity sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg== + dependencies: + escape-string-regexp "^1.0.5" + file-entry-cache@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-2.0.0.tgz#c392990c3e684783d838b8c84a45d8a048458361" @@ -1961,10 +2502,24 @@ gauge@~2.7.3: strip-ansi "^3.0.1" wide-align "^1.1.0" +gensync@^1.0.0-beta.2: + version "1.0.0-beta.2" + resolved "https://registry.yarnpkg.com/gensync/-/gensync-1.0.0-beta.2.tgz#32a6ee76c3d7f52d46b2b1ae5d93fea8580a25e0" + integrity sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg== + get-caller-file@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.3.tgz#f978fa4c90d1dfe7ff2d6beda2a515e713bdcf4a" +get-intrinsic@^1.0.2: + version "1.1.1" + resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.1.1.tgz#15f59f376f855c446963948f0d24cd3637b4abc6" + integrity sha512-kWZrnVM42QCiEA2Ig1bG8zjoIMOgxWwYCEeNdwY6Tv/cOSeGpcoX4pXHfKUxNKVoArnrEr2e9srnAxxGIraS9Q== + dependencies: + function-bind "^1.1.1" + has "^1.0.3" + has-symbols "^1.0.1" + get-stream@^3.0.0: version "3.0.0" resolved "https://registry.npmjs.org/get-stream/-/get-stream-3.0.0.tgz#8e943d1358dc37555054ecbe2edb05aa174ede14" @@ -1986,6 +2541,13 @@ glob-parent@^3.1.0: is-glob "^3.1.0" path-dirname "^1.0.0" +glob-parent@^5.0.0: + version "5.1.2" + resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.2.tgz#869832c58034fe68a4093c17dc15e8340d8401c4" + integrity sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow== + dependencies: + is-glob "^4.0.1" + glob-stream@^6.1.0: version "6.1.0" resolved "https://registry.yarnpkg.com/glob-stream/-/glob-stream-6.1.0.tgz#7045c99413b3eb94888d83ab46d0b404cc7bdde4" @@ -2062,10 +2624,17 @@ global-prefix@^1.0.1: is-windows "^1.0.1" which "^1.2.14" -globals@^11.0.1, globals@^11.1.0, globals@^11.7.0: +globals@^11.0.1, globals@^11.1.0: version "11.12.0" resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" +globals@^12.1.0: + version "12.4.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-12.4.0.tgz#a18813576a41b00a24a97e7f815918c2e19925f8" + integrity sha512-BWICuzzDvDoH54NHKCseDanAhE3CeDorgDL5MT6LMXXj2WCnd9UC2szdk4AWLfjdgNBCXLUanXYcpBBKOSWGwg== + dependencies: + type-fest "^0.8.1" + glogg@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/glogg/-/glogg-1.0.0.tgz#7fe0f199f57ac906cf512feead8f90ee4a284fc5" @@ -2189,12 +2758,14 @@ gulplog@^1.0.0: glogg "^1.0.0" handlebars@^4.0.1: - version "4.1.2" - resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.1.2.tgz#b6b37c1ced0306b221e094fc7aca3ec23b131b67" + version "4.7.6" + resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.7.6.tgz#d4c05c1baf90e9945f77aa68a7a219aa4a7df74e" + integrity sha512-1f2BACcBfiwAfStCKZNrUCgqNZkGsAT7UM3kkYtXuLo0KnaVfjKOyf7PRzB6++aK9STyT1Pd2ZCPe3EGOXleXA== dependencies: + minimist "^1.2.5" neo-async "^2.6.0" - optimist "^0.6.1" source-map "^0.6.1" + wordwrap "^1.0.0" optionalDependencies: uglify-js "^3.1.4" @@ -2224,10 +2795,20 @@ has-flag@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" +has-flag@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" + integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== + has-symbols@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.0.tgz#ba1a8f1af2a0fc39650f5c850367704122063b44" +has-symbols@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.2.tgz#165d3070c00309752a1236a479331e3ac56f1423" + integrity sha512-chXa79rL/UC2KlX17jo3vRGz0azaWEx5tGqZg5pO3NUyEJVB17dMruQlzCCOfUvElghKcm5194+BCRvi2Rv/Gw== + has-unicode@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/has-unicode/-/has-unicode-2.0.1.tgz#e0e6fe6a28cf51138855e086d1691e771de2a8b9" @@ -2259,6 +2840,13 @@ has-values@^1.0.0: is-number "^3.0.0" kind-of "^4.0.0" +has@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" + integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== + dependencies: + function-bind "^1.1.1" + he@1.1.1: version "1.1.1" resolved "https://registry.npmjs.org/he/-/he-1.1.1.tgz#93410fd21b009735151f8868c2f271f3427e23fd" @@ -2354,34 +2942,29 @@ inquirer@^3.0.6: strip-ansi "^4.0.0" through "^2.3.6" -inquirer@^6.2.2: - version "6.4.1" - resolved "https://registry.npmjs.org/inquirer/-/inquirer-6.4.1.tgz#7bd9e5ab0567cd23b41b0180b68e0cfa82fc3c0b" +inquirer@^7.0.0: + version "7.3.3" + resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-7.3.3.tgz#04d176b2af04afc157a83fd7c100e98ee0aad003" + integrity sha512-JG3eIAj5V9CwcGvuOmoo6LB9kbAYT8HXffUl6memuszlwDC/qvFAJw49XJ5NROSFNPxp3iQg1GqkFhaY/CR0IA== dependencies: - ansi-escapes "^3.2.0" - chalk "^2.4.2" - cli-cursor "^2.1.0" - cli-width "^2.0.0" + ansi-escapes "^4.2.1" + chalk "^4.1.0" + cli-cursor "^3.1.0" + cli-width "^3.0.0" external-editor "^3.0.3" - figures "^2.0.0" - lodash "^4.17.11" - mute-stream "0.0.7" - run-async "^2.2.0" - rxjs "^6.4.0" - string-width "^2.1.0" - strip-ansi "^5.1.0" + figures "^3.0.0" + lodash "^4.17.19" + mute-stream "0.0.8" + run-async "^2.4.0" + rxjs "^6.6.0" + string-width "^4.1.0" + strip-ansi "^6.0.0" through "^2.3.6" interpret@^1.1.0: version "1.2.0" resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.2.0.tgz#d5061a6224be58e8083985f5014d844359576296" -invariant@^2.2.2: - version "2.2.2" - resolved "https://registry.yarnpkg.com/invariant/-/invariant-2.2.2.tgz#9e1f56ac0acdb6bf303306f338be3b204ae60360" - dependencies: - loose-envify "^1.0.0" - invert-kv@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-1.0.0.tgz#104a8e4aaca6d3d8cd157a8ef8bfab2d7a3ffdb6" @@ -2419,6 +3002,13 @@ is-buffer@^1.1.5: version "1.1.5" resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.5.tgz#1f3b26ef613b214b88cbca23cc6c01d87961eecc" +is-core-module@^2.2.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.3.0.tgz#d341652e3408bca69c4671b79a0954a3d349f887" + integrity sha512-xSphU2KG9867tsYdLD4RWQ1VqdFl4HTO9Thf3I/3dLEfr0dbPTWKsuCKrgqMljg4nPE+Gq0VCnzT3gr0CyBmsw== + dependencies: + has "^1.0.3" + is-data-descriptor@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz#0b5ee648388e2c860282e793f1856fec3f301b56" @@ -2471,13 +3061,18 @@ is-fullwidth-code-point@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" +is-fullwidth-code-point@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz#f116f8064fe90b3f7844a38997c0b75051269f1d" + integrity sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg== + is-glob@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-3.1.0.tgz#7ba5ae24217804ac70707b96922567486cc3e84a" dependencies: is-extglob "^2.1.0" -is-glob@^4.0.0: +is-glob@^4.0.0, is-glob@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.1.tgz#7567dbe9f2f5e2467bc77ab83c4a29482407a5dc" dependencies: @@ -2602,11 +3197,7 @@ istanbul@^0.4.0, istanbul@~0.4.5: which "^1.1.1" wordwrap "^1.0.0" -js-levenshtein@^1.1.3: - version "1.1.6" - resolved "https://registry.yarnpkg.com/js-levenshtein/-/js-levenshtein-1.1.6.tgz#c6cee58eb3550372df8deb85fad5ce66ce01d59d" - -js-tokens@^3.0.0, js-tokens@^3.0.2: +js-tokens@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b" @@ -2653,11 +3244,12 @@ json-stringify-safe@^5.0.1, json-stringify-safe@~5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" -json5@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/json5/-/json5-2.1.0.tgz#e7a0c62c48285c628d20a10b85c89bb807c32850" +json5@^2.1.2: + version "2.2.0" + resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.0.tgz#2dfefe720c6ba525d9ebd909950f0515316c89a3" + integrity sha512-f+8cldu7X/y7RAJurMEJmdoKXGB/X550w2Nr3tTbezL6RwEE/iMcm+tZnXeoZtKuOq6ft8+CqzEkrIgx1fPoQA== dependencies: - minimist "^1.2.0" + minimist "^1.2.5" jsprim@^1.2.2: version "1.4.1" @@ -2764,6 +3356,11 @@ locate-path@^3.0.0: p-locate "^3.0.0" path-exists "^3.0.0" +lodash.debounce@^4.0.8: + version "4.0.8" + resolved "https://registry.yarnpkg.com/lodash.debounce/-/lodash.debounce-4.0.8.tgz#82d79bff30a67c4005ffd5e2515300ad9ca4d7af" + integrity sha1-gteb/zCmfEAF/9XiUVMArZyk168= + lodash@^3.10.1: version "3.10.1" resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.10.1.tgz#5bf45e8e49ba4189e17d482789dfd15bd140b7b6" @@ -2776,7 +3373,12 @@ lodash@^4.17.11, lodash@^4.3.0: version "4.17.11" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.11.tgz#b39ea6229ef607ecd89e2c8df12536891cac9b8d" -lodash@^4.17.15, lodash@~4.17.2: +lodash@^4.17.14, lodash@^4.17.19: + version "4.17.21" + resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" + integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== + +lodash@~4.17.2: version "4.17.15" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.15.tgz#b447f6670a0455bbfeedd11392eff330ea097548" integrity sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A== @@ -2786,12 +3388,6 @@ lolex@^4.0.1, lolex@^4.1.0: resolved "https://registry.yarnpkg.com/lolex/-/lolex-4.1.0.tgz#ecdd7b86539391d8237947a3419aa8ac975f0fe1" integrity sha512-BYxIEXiVq5lGIXeVHnsFzqa1TxN5acnKnPCdlZSpzm8viNEOhiigupA4vTQ9HEFQ6nLTQ9wQOgBknJgzUYQ9Aw== -loose-envify@^1.0.0: - version "1.3.1" - resolved "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.3.1.tgz#d1a8ad33fa9ce0e713d65fdd0ac8b748d478c848" - dependencies: - js-tokens "^3.0.0" - lru-cache@^4.0.1: version "4.1.5" resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.5.tgz#8bbe50ea85bed59bc9e33dcab8235ee9bcf443cd" @@ -2799,7 +3395,7 @@ lru-cache@^4.0.1: pseudomap "^1.0.2" yallist "^2.1.2" -make-dir@^2.0.0: +make-dir@^2.0.0, make-dir@^2.1.0: version "2.1.0" resolved "https://registry.npmjs.org/make-dir/-/make-dir-2.1.0.tgz#5f0310e18b8be898cc07009295a30ae41e91e6f5" dependencies: @@ -2875,6 +3471,11 @@ mimic-fn@^1.0.0: version "1.2.0" resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" +mimic-fn@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-2.1.0.tgz#7ed2c2ccccaf84d3ffcb7a69b57711fc2083401b" + integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== + "minimatch@2 || 3", minimatch@3.0.4, minimatch@^3.0.2, minimatch@^3.0.3, minimatch@^3.0.4: version "3.0.4" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" @@ -2885,13 +3486,10 @@ minimist@0.0.8: version "0.0.8" resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d" -minimist@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284" - -minimist@~0.0.1: - version "0.0.10" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.10.tgz#de3f98543dbf96082be48ad1a0c7cda836301dcf" +minimist@^1.2.0, minimist@^1.2.5: + version "1.2.5" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602" + integrity sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw== minipass@^2.2.1, minipass@^2.3.5: version "2.3.5" @@ -2939,7 +3537,7 @@ ms@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" -ms@^2.1.1: +ms@2.1.2, ms@^2.1.1: version "2.1.2" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" @@ -2951,6 +3549,11 @@ mute-stream@0.0.7: version "0.0.7" resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.7.tgz#3075ce93bc21b8fab43e1bc4da7e8115ed1e7bab" +mute-stream@0.0.8: + version "0.0.8" + resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.8.tgz#1630c42b2251ff81e2a283de96a5497ea92e5e0d" + integrity sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA== + nan@^2.12.1: version "2.14.0" resolved "https://registry.yarnpkg.com/nan/-/nan-2.14.0.tgz#7818f722027b2459a86f0295d434d1fc2336c52c" @@ -2985,8 +3588,9 @@ needle@^2.2.1: sax "^1.2.4" neo-async@^2.6.0: - version "2.6.1" - resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.1.tgz#ac27ada66167fa8849a6addd837f6b189ad2081c" + version "2.6.2" + resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.2.tgz#b4aafb93e3aeb2d8174ca53cf163ab7d7308305f" + integrity sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw== next-tick@^1.0.0: version "1.0.0" @@ -3039,11 +3643,10 @@ node-pre-gyp@^0.12.0: semver "^5.3.0" tar "^4" -node-releases@^1.1.23: - version "1.1.25" - resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-1.1.25.tgz#0c2d7dbc7fed30fbe02a9ee3007b8c90bf0133d3" - dependencies: - semver "^5.3.0" +node-releases@^1.1.71: + version "1.1.71" + resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-1.1.71.tgz#cb1334b179896b1c89ecfdd4b725fb7bbdfc7dbb" + integrity sha512-zR6HoT6LrLCRBwukmrVbHv0EpEQjksO6GmFcZQQuCAy139BEsoVKPYnf3jongYW83fAa1torLGYwxxky/p28sg== nopt@3.x: version "3.0.6" @@ -3130,7 +3733,7 @@ object-copy@^0.1.0: define-property "^0.2.5" kind-of "^3.0.3" -object-keys@^1.0.11, object-keys@^1.0.12: +object-keys@^1.0.11, object-keys@^1.0.12, object-keys@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.1.1.tgz#1c47f272df277f3b1daf061677d9c82e2322c60e" @@ -3149,6 +3752,16 @@ object.assign@^4.0.4: has-symbols "^1.0.0" object-keys "^1.0.11" +object.assign@^4.1.0: + version "4.1.2" + resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.1.2.tgz#0ed54a342eceb37b38ff76eb831a0e788cb63940" + integrity sha512-ixT2L5THXsApyiUPYKmW+2EHpXXe5Ii3M+f4e+aJFAHao5amFRW6J0OO6c/LU8Be47utCx2GL89hxGB6XSmKuQ== + dependencies: + call-bind "^1.0.0" + define-properties "^1.1.3" + has-symbols "^1.0.1" + object-keys "^1.1.1" + object.defaults@^1.0.0, object.defaults@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/object.defaults/-/object.defaults-1.1.0.tgz#3a7f868334b407dea06da16d88d5cd29e435fecf" @@ -3190,12 +3803,12 @@ onetime@^2.0.0: dependencies: mimic-fn "^1.0.0" -optimist@^0.6.1: - version "0.6.1" - resolved "https://registry.yarnpkg.com/optimist/-/optimist-0.6.1.tgz#da3ea74686fa21a19a111c326e90eb15a0196686" +onetime@^5.1.0: + version "5.1.2" + resolved "https://registry.yarnpkg.com/onetime/-/onetime-5.1.2.tgz#d0e96ebb56b07476df1dd9c4806e5237985ca45e" + integrity sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg== dependencies: - minimist "~0.0.1" - wordwrap "~0.0.2" + mimic-fn "^2.1.0" optionator@^0.8.1, optionator@^0.8.2: version "0.8.2" @@ -3208,6 +3821,18 @@ optionator@^0.8.1, optionator@^0.8.2: type-check "~0.3.2" wordwrap "~1.0.0" +optionator@^0.8.3: + version "0.8.3" + resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.3.tgz#84fa1d036fe9d3c7e21d99884b601167ec8fb495" + integrity sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA== + dependencies: + deep-is "~0.1.3" + fast-levenshtein "~2.0.6" + levn "~0.3.0" + prelude-ls "~1.1.2" + type-check "~0.3.2" + word-wrap "~1.2.3" + ordered-read-streams@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/ordered-read-streams/-/ordered-read-streams-1.0.1.tgz#77c0cb37c41525d64166d990ffad7ec6a0e1363e" @@ -3415,10 +4040,6 @@ pretty-hrtime@^1.0.0: version "1.0.3" resolved "https://registry.yarnpkg.com/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz#b7e3ea42435a4c9b2759d99e0f201eb195802ee1" -private@^0.1.6: - version "0.1.8" - resolved "https://registry.yarnpkg.com/private/-/private-0.1.8.tgz#2381edb3689f7a53d653190060fcf822d2f368ff" - process-nextick-args@^2.0.0, process-nextick-args@~2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2" @@ -3544,15 +4165,28 @@ regenerate-unicode-properties@^8.0.2: dependencies: regenerate "^1.4.0" +regenerate-unicode-properties@^8.2.0: + version "8.2.0" + resolved "https://registry.yarnpkg.com/regenerate-unicode-properties/-/regenerate-unicode-properties-8.2.0.tgz#e5de7111d655e7ba60c057dbe9ff37c87e65cdec" + integrity sha512-F9DjY1vKLo/tPePDycuH3dn9H1OTPIkVD9Kz4LODu+F2C75mgjAJ7x/gwy6ZcSNRAAkhNlJSOHRe8k3p+K9WhA== + dependencies: + regenerate "^1.4.0" + regenerate@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.4.0.tgz#4a856ec4b56e4077c557589cae85e7a4c8869a11" -regenerator-transform@^0.14.0: - version "0.14.0" - resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.14.0.tgz#2ca9aaf7a2c239dd32e4761218425b8c7a86ecaf" +regenerator-runtime@^0.13.4: + version "0.13.7" + resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.7.tgz#cac2dacc8a1ea675feaabaeb8ae833898ae46f55" + integrity sha512-a54FxoJDIr27pgf7IgeQGxmqUNYrcV338lf/6gH456HZ/PhX+5BcwHXG9ajESmwe6WRO0tAzRUrRmNONWgkrew== + +regenerator-transform@^0.14.2: + version "0.14.5" + resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.14.5.tgz#c98da154683671c9c4dcb16ece736517e1b7feb4" + integrity sha512-eOf6vka5IO151Jfsw2NO9WpGX58W6wWmefK3I1zEGr0lOD0u8rwPaNqQL1aRxUaxLeKO3ArNh3VYg1KbaD+FFw== dependencies: - private "^0.1.6" + "@babel/runtime" "^7.8.4" regex-not@^1.0.0, regex-not@^1.0.2: version "1.0.2" @@ -3561,10 +4195,6 @@ regex-not@^1.0.0, regex-not@^1.0.2: extend-shallow "^3.0.2" safe-regex "^1.1.0" -regexp-tree@^0.1.6: - version "0.1.10" - resolved "https://registry.yarnpkg.com/regexp-tree/-/regexp-tree-0.1.10.tgz#d837816a039c7af8a8d64d7a7c3cf6a1d93450bc" - regexpp@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-1.1.0.tgz#0e3516dd0b7904f413d2d4193dce4618c3a689ab" @@ -3584,16 +4214,40 @@ regexpu-core@^4.5.4: unicode-match-property-ecmascript "^1.0.4" unicode-match-property-value-ecmascript "^1.1.0" +regexpu-core@^4.7.1: + version "4.7.1" + resolved "https://registry.yarnpkg.com/regexpu-core/-/regexpu-core-4.7.1.tgz#2dea5a9a07233298fbf0db91fa9abc4c6e0f8ad6" + integrity sha512-ywH2VUraA44DZQuRKzARmw6S66mr48pQVva4LBeRhcOltJ6hExvWly5ZjFLYo67xbIxb6W1q4bAGtgfEl20zfQ== + dependencies: + regenerate "^1.4.0" + regenerate-unicode-properties "^8.2.0" + regjsgen "^0.5.1" + regjsparser "^0.6.4" + unicode-match-property-ecmascript "^1.0.4" + unicode-match-property-value-ecmascript "^1.2.0" + regjsgen@^0.5.0: version "0.5.0" resolved "https://registry.yarnpkg.com/regjsgen/-/regjsgen-0.5.0.tgz#a7634dc08f89209c2049adda3525711fb97265dd" +regjsgen@^0.5.1: + version "0.5.2" + resolved "https://registry.yarnpkg.com/regjsgen/-/regjsgen-0.5.2.tgz#92ff295fb1deecbf6ecdab2543d207e91aa33733" + integrity sha512-OFFT3MfrH90xIW8OOSyUrk6QHD5E9JOTeGodiJeBS3J6IwlgzJMNE/1bZklWz5oTg+9dCMyEetclvCVXOPoN3A== + regjsparser@^0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/regjsparser/-/regjsparser-0.6.0.tgz#f1e6ae8b7da2bae96c99399b868cd6c933a2ba9c" dependencies: jsesc "~0.5.0" +regjsparser@^0.6.4: + version "0.6.9" + resolved "https://registry.yarnpkg.com/regjsparser/-/regjsparser-0.6.9.tgz#b489eef7c9a2ce43727627011429cf833a7183e6" + integrity sha512-ZqbNRz1SNjLAiYuwY0zoXW8Ne675IX5q+YHioAGbCw4X96Mjl2+dcX9B2ciaeyYjViDAfvIjFpQjJgLttTEERQ== + dependencies: + jsesc "~0.5.0" + remove-bom-buffer@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/remove-bom-buffer/-/remove-bom-buffer-3.0.0.tgz#c2bf1e377520d324f623892e33c10cac2c252b53" @@ -3709,12 +4363,20 @@ resolve@^1.1.6, resolve@^1.1.7: dependencies: path-parse "^1.0.5" -resolve@^1.10.0, resolve@^1.3.2, resolve@^1.4.0: +resolve@^1.10.0, resolve@^1.4.0: version "1.11.1" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.11.1.tgz#ea10d8110376982fef578df8fc30b9ac30a07a3e" dependencies: path-parse "^1.0.6" +resolve@^1.14.2: + version "1.20.0" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.20.0.tgz#629a013fb3f70755d6f0b7935cc1c2c5378b1975" + integrity sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A== + dependencies: + is-core-module "^2.2.0" + path-parse "^1.0.6" + restore-cursor@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-2.0.0.tgz#9f7ee287f82fd326d4fd162923d62129eee0dfaf" @@ -3722,6 +4384,14 @@ restore-cursor@^2.0.0: onetime "^2.0.0" signal-exit "^3.0.2" +restore-cursor@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-3.1.0.tgz#39f67c54b3a7a58cea5236d95cf0034239631f7e" + integrity sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA== + dependencies: + onetime "^5.1.0" + signal-exit "^3.0.2" + ret@~0.1.10: version "0.1.15" resolved "https://registry.yarnpkg.com/ret/-/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc" @@ -3738,6 +4408,11 @@ run-async@^2.2.0: dependencies: is-promise "^2.1.0" +run-async@^2.4.0: + version "2.4.1" + resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.4.1.tgz#8440eccf99ea3e70bd409d49aab88e10c189a455" + integrity sha512-tvVnVv01b8c1RrA6Ep7JkStj85Guv/YrMcwqYQnwjsAS2cTmmPGBBjAjpCW7RrSodNSoE2/qg9O4bceNvUuDgQ== + rx-lite-aggregates@^4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/rx-lite-aggregates/-/rx-lite-aggregates-4.0.8.tgz#753b87a89a11c95467c4ac1626c4efc4e05c67be" @@ -3748,9 +4423,10 @@ rx-lite@*, rx-lite@^4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-4.0.8.tgz#0b1e11af8bc44836f04a6407e92da42467b79444" -rxjs@^6.4.0: - version "6.5.2" - resolved "https://registry.npmjs.org/rxjs/-/rxjs-6.5.2.tgz#2e35ce815cd46d84d02a209fb4e5921e051dbec7" +rxjs@^6.6.0: + version "6.6.7" + resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.6.7.tgz#90ac018acabf491bf65044235d5863c4dab804c9" + integrity sha512-hTdwr+7yYNIT5n4AMYp85KA6yw2Va0FLa3Rguvbpa4W3I5xynaBZo41cM3XM+4Q6fRMj3sBYIR1VAmZMXYJvRQ== dependencies: tslib "^1.9.0" @@ -3782,14 +4458,24 @@ semver-greatest-satisfied-range@^1.1.0: dependencies: sver-compat "^1.5.0" -"semver@2 || 3 || 4 || 5", semver@^5.3.0, semver@^5.4.1, semver@^5.5.0, semver@^5.5.1, semver@^5.6.0: +"semver@2 || 3 || 4 || 5", semver@^5.3.0, semver@^5.5.0, semver@^5.6.0: version "5.7.0" resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.0.tgz#790a7cf6fea5459bac96110b29b60412dc8ff96b" +semver@7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.0.0.tgz#5f3ca35761e47e05b206c6daff2cf814f0316b8e" + integrity sha512-+GB6zVA9LWh6zovYQLALHwv5rb2PHGlJi3lfiqIHxR0uuwCgefcOJc59v9fv1w8GbStwxuuqqAjI9NMAOOgq1A== + semver@^6.1.1: version "6.2.0" resolved "https://registry.yarnpkg.com/semver/-/semver-6.2.0.tgz#4d813d9590aaf8a9192693d6c85b9344de5901db" +semver@^6.1.2, semver@^6.3.0: + version "6.3.0" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" + integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== + set-blocking@^2.0.0, set-blocking@~2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" @@ -3812,6 +4498,13 @@ set-value@^2.0.0: is-plain-object "^2.0.3" split-string "^3.0.1" +shallow-clone@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/shallow-clone/-/shallow-clone-3.0.1.tgz#8f2981ad92531f55035b01fb230769a40e02efa3" + integrity sha512-/6KqX+GVUdqPuPPd2LxDDxzX6CAbjJehAAOKlNpqqUpAqPM6HeL8f+o3a+JsyGjn2lv0WY8UsTgUJjU9Ok55NA== + dependencies: + kind-of "^6.0.2" + shebang-command@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea" @@ -3890,9 +4583,10 @@ source-map-resolve@^0.5.0: source-map-url "^0.4.0" urix "^0.1.0" -source-map-support@^0.5.9: - version "0.5.12" - resolved "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.12.tgz#b4f3b10d51857a5af0138d3ce8003b201613d599" +source-map-support@^0.5.16: + version "0.5.19" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.19.tgz#a98b62f86dcaf4f67399648c085291ab9e8fed61" + integrity sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw== dependencies: buffer-from "^1.0.0" source-map "^0.6.0" @@ -4007,6 +4701,15 @@ string-width@^3.0.0: is-fullwidth-code-point "^2.0.0" strip-ansi "^5.1.0" +string-width@^4.1.0: + version "4.2.2" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.2.tgz#dafd4f9559a7585cfba529c6a0a4f73488ebd4c5" + integrity sha512-XBJbT3N4JhVumXE0eoLU9DCjcaF92KLNqTmFCnG1pf8duUxFGwtP6AD6nkjw9a3IdiRtL3E2w3JDiE/xi3vOeA== + dependencies: + emoji-regex "^8.0.0" + is-fullwidth-code-point "^3.0.0" + strip-ansi "^6.0.0" + string_decoder@~1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.0.3.tgz#0fc67d7c141825de94282dd536bec6b9bce860ab" @@ -4031,12 +4734,19 @@ strip-ansi@^4.0.0: dependencies: ansi-regex "^3.0.0" -strip-ansi@^5.1.0: +strip-ansi@^5.1.0, strip-ansi@^5.2.0: version "5.2.0" resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz#8c9a536feb6afc962bdfa5b104a5091c1ad9c0ae" dependencies: ansi-regex "^4.1.0" +strip-ansi@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.0.tgz#0b1571dd7669ccd4f3e06e14ef1eed26225ae532" + integrity sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w== + dependencies: + ansi-regex "^5.0.0" + strip-bom@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-2.0.0.tgz#6219a85616520491f35788bdbf1447a99c7e6b0e" @@ -4047,7 +4757,12 @@ strip-eof@^1.0.0: version "1.0.0" resolved "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz#bb43ff5598a6eb05d89b59fcd129c983313606bf" -strip-json-comments@^2.0.1, strip-json-comments@~2.0.1: +strip-json-comments@^3.0.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" + integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== + +strip-json-comments@~2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" @@ -4073,6 +4788,13 @@ supports-color@^5.3.0, supports-color@^5.4.0, supports-color@^5.5.0: dependencies: has-flag "^3.0.0" +supports-color@^7.1.0: + version "7.2.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" + integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== + dependencies: + has-flag "^4.0.0" + sver-compat@^1.5.0: version "1.5.0" resolved "https://registry.yarnpkg.com/sver-compat/-/sver-compat-1.5.0.tgz#3cf87dfeb4d07b4a3f14827bc186b3fd0c645cd8" @@ -4234,6 +4956,16 @@ type-detect@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-1.0.0.tgz#762217cc06db258ec48908a1298e8b95121e8ea2" +type-fest@^0.21.3: + version "0.21.3" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.21.3.tgz#d260a24b0198436e133fa26a524a6d65fa3b2e37" + integrity sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w== + +type-fest@^0.8.1: + version "0.8.1" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.8.1.tgz#09e249ebde851d3b1e48d27c105444667f17b83d" + integrity sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA== + type@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/type/-/type-1.0.1.tgz#084c9a17fcc9151a2cdb1459905c2e45e4bb7d61" @@ -4243,11 +4975,9 @@ typedarray@^0.0.6: resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" uglify-js@^3.1.4: - version "3.6.0" - resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.6.0.tgz#704681345c53a8b2079fb6cec294b05ead242ff5" - dependencies: - commander "~2.20.0" - source-map "~0.6.1" + version "3.10.3" + resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.10.3.tgz#f0d2f99736c14de46d2d24649ba328be3e71c3bf" + integrity sha512-Lh00i69Uf6G74mvYpHCI9KVVXLcHW/xu79YTvH7Mkc9zyKUeSPz0owW0dguj0Scavns3ZOh3wY63J0Zb97Za2g== unc-path-regex@^0.1.2: version "0.1.2" @@ -4286,6 +5016,11 @@ unicode-match-property-value-ecmascript@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-1.1.0.tgz#5b4b426e08d13a80365e0d657ac7a6c1ec46a277" +unicode-match-property-value-ecmascript@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-1.2.0.tgz#0d91f600eeeb3096aa962b1d6fc88876e64ea531" + integrity sha512-wjuQHGQVofmSJv1uVISKLE5zO2rNGzM/KCYZch/QQvez7C1hUhBIuZ701fYXExuufJFMPhv2SyL8CyoIfMLbIQ== + unicode-property-aliases-ecmascript@^1.0.4: version "1.0.5" resolved "https://registry.yarnpkg.com/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-1.0.5.tgz#a9cc6cc7ce63a0a3023fc99e341b94431d405a57" @@ -4342,6 +5077,11 @@ uuid@^3.3.2: resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.3.2.tgz#1b4af4955eb3077c501c23872fc6513811587131" integrity sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA== +v8-compile-cache@^2.0.3: + version "2.3.0" + resolved "https://registry.yarnpkg.com/v8-compile-cache/-/v8-compile-cache-2.3.0.tgz#2de19618c66dc247dcfb6f99338035d8245a2cee" + integrity sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA== + v8flags@^3.0.1: version "3.1.3" resolved "https://registry.yarnpkg.com/v8flags/-/v8flags-3.1.3.tgz#fc9dc23521ca20c5433f81cc4eb9b3033bb105d8" @@ -4440,14 +5180,15 @@ wide-align@^1.1.0: dependencies: string-width "^1.0.2 || 2" +word-wrap@~1.2.3: + version "1.2.3" + resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c" + integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ== + wordwrap@^1.0.0, wordwrap@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" -wordwrap@~0.0.2: - version "0.0.3" - resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.3.tgz#a3d5da6cd5c0bc0008d37234bbaf1bed63059107" - wrap-ansi@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-2.1.0.tgz#d8fc3d284dd05794fe84973caecdd1cf824fdd85" From 457e73db21e6527bf19608c26b79e229a2a8c911 Mon Sep 17 00:00:00 2001 From: Johnny Nader Date: Thu, 29 Apr 2021 12:51:57 +0100 Subject: [PATCH 024/146] update lodash resolution and ci config --- .circleci/config.yml | 4 +- package.json | 2 +- yarn.lock | 1835 +++++++++++++++++++++--------------------- 3 files changed, 934 insertions(+), 907 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 2cb8a395..da34410c 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -2,12 +2,12 @@ version: 2 jobs: build: docker: - - image: circleci/node:8-browsers + - image: circleci/node:14-browsers working_directory: ~/intercom-node environment: - - YARN_VERSION: 1.7.0 + - YARN_VERSION: 1.22.10 steps: - checkout diff --git a/package.json b/package.json index 0a92b0a8..446a2732 100644 --- a/package.json +++ b/package.json @@ -36,7 +36,7 @@ "gulp-istanbul": "^1.1.3", "gulp-mocha": "^6.0.0", "gulp-plumber": "^1.2.1", - "nock": "7.5.0", + "nock": "^13.0.11", "sinon": "^7.3.2" }, "scripts": { diff --git a/yarn.lock b/yarn.lock index a388bd26..6c8395f2 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,13 +2,7 @@ # yarn lockfile v1 -"@babel/code-frame@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0.tgz#06e2ab19bdb535385559aabb5ba59729482800f8" - dependencies: - "@babel/highlight" "^7.0.0" - -"@babel/code-frame@^7.12.13": +"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.12.13": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.12.13.tgz#dcfc826beef65e75c50e21d3837d7d95798dd658" integrity sha512-HV1Cm0Q3ZrpCR93tkWOYiuYIgLxZXZFVG2VgK+MBWjUqZTundupbfx2aXarXuw5Ko5aMcjtJgbSs4vUGBS5v6g== @@ -50,16 +44,6 @@ jsesc "^2.5.1" source-map "^0.5.0" -"@babel/generator@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.4.4.tgz#174a215eb843fc392c7edcaabeaa873de6e8f041" - dependencies: - "@babel/types" "^7.4.4" - jsesc "^2.5.1" - lodash "^4.17.11" - source-map "^0.5.0" - trim-right "^1.0.1" - "@babel/helper-annotate-as-pure@^7.12.13": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.12.13.tgz#0f58e86dfc4bb3b1fcd7db806570e177d439b6ab" @@ -125,14 +109,6 @@ dependencies: "@babel/types" "^7.13.0" -"@babel/helper-function-name@^7.1.0": - version "7.1.0" - resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.1.0.tgz#a0ceb01685f73355d4360c1247f582bfafc8ff53" - dependencies: - "@babel/helper-get-function-arity" "^7.0.0" - "@babel/template" "^7.1.0" - "@babel/types" "^7.0.0" - "@babel/helper-function-name@^7.12.13": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.12.13.tgz#93ad656db3c3c2232559fd7b2c3dbdcbe0eb377a" @@ -142,12 +118,6 @@ "@babel/template" "^7.12.13" "@babel/types" "^7.12.13" -"@babel/helper-get-function-arity@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0.tgz#83572d4320e2a4657263734113c42868b64e49c3" - dependencies: - "@babel/types" "^7.0.0" - "@babel/helper-get-function-arity@^7.12.13": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.12.13.tgz#bc63451d403a3b3082b97e1d8b3fe5bd4091e583" @@ -198,21 +168,11 @@ dependencies: "@babel/types" "^7.12.13" -"@babel/helper-plugin-utils@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.0.0.tgz#bbb3fbee98661c569034237cc03967ba99b4f250" - -"@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.13.0", "@babel/helper-plugin-utils@^7.8.0", "@babel/helper-plugin-utils@^7.8.3": +"@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.13.0", "@babel/helper-plugin-utils@^7.8.0", "@babel/helper-plugin-utils@^7.8.3": version "7.13.0" resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.13.0.tgz#806526ce125aed03373bc416a828321e3a6a33af" integrity sha512-ZPafIPSwzUlAoWT8DKs1W2VyF2gOWthGd5NGFMsBcMMol+ZhK+EQY/e6V96poa6PA/Bh+C9plWN0hXO1uB8AfQ== -"@babel/helper-regex@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/helper-regex/-/helper-regex-7.4.4.tgz#a47e02bc91fb259d2e6727c2a30013e3ac13c4a2" - dependencies: - lodash "^4.17.11" - "@babel/helper-remap-async-to-generator@^7.13.0": version "7.13.0" resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.13.0.tgz#376a760d9f7b4b2077a9dd05aa9c3927cadb2209" @@ -253,12 +213,6 @@ dependencies: "@babel/types" "^7.12.13" -"@babel/helper-split-export-declaration@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.4.4.tgz#ff94894a340be78f53f06af038b205c49d993677" - dependencies: - "@babel/types" "^7.4.4" - "@babel/helper-validator-identifier@^7.12.11": version "7.12.11" resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.12.11.tgz#c9a1f021917dcb5ccf0d4e453e399022981fc9ed" @@ -288,14 +242,6 @@ "@babel/traverse" "^7.13.17" "@babel/types" "^7.13.17" -"@babel/highlight@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.0.0.tgz#f710c38c8d458e6dd9a201afb637fcb781ce99e4" - dependencies: - chalk "^2.0.0" - esutils "^2.0.2" - js-tokens "^4.0.0" - "@babel/highlight@^7.12.13": version "7.13.10" resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.13.10.tgz#a8b2a66148f5b27d666b15d81774347a731d52d1" @@ -305,11 +251,7 @@ chalk "^2.0.0" js-tokens "^4.0.0" -"@babel/parser@^7.0.0", "@babel/parser@^7.4.4", "@babel/parser@^7.4.5": - version "7.4.5" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.4.5.tgz#04af8d5d5a2b044a2a1bffacc1e5e6673544e872" - -"@babel/parser@^7.12.13", "@babel/parser@^7.13.16": +"@babel/parser@^7.12.13", "@babel/parser@^7.13.16", "@babel/parser@^7.7.0": version "7.13.16" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.13.16.tgz#0f18179b0448e6939b1f3f5c4c355a3a9bcdfd37" integrity sha512-6bAg36mCwuqLO0hbR+z7PHuqWiCeP7Dzg73OpQwsAB1Eb8HnGEz5xYBzCfbu+YjoaJsJs+qheDxVAuqbt3ILEw== @@ -424,7 +366,7 @@ "@babel/helper-create-class-features-plugin" "^7.13.0" "@babel/helper-plugin-utils" "^7.13.0" -"@babel/plugin-proposal-unicode-property-regex@^7.12.13": +"@babel/plugin-proposal-unicode-property-regex@^7.12.13", "@babel/plugin-proposal-unicode-property-regex@^7.4.4": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.12.13.tgz#bebde51339be829c17aaaaced18641deb62b39ba" integrity sha512-XyJmZidNfofEkqFV5VC/bLabGmO5QzenPO/YOfGuEbgU+2sSwMmio3YLb4WtBgcmmdwZHyVyv8on77IUjQ5Gvg== @@ -432,14 +374,6 @@ "@babel/helper-create-regexp-features-plugin" "^7.12.13" "@babel/helper-plugin-utils" "^7.12.13" -"@babel/plugin-proposal-unicode-property-regex@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.4.4.tgz#501ffd9826c0b91da22690720722ac7cb1ca9c78" - dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-regex" "^7.4.4" - regexpu-core "^4.5.4" - "@babel/plugin-syntax-async-generators@^7.8.4": version "7.8.4" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz#a983fb1aeb2ec3f6ed042a210f640e90e786fe0d" @@ -581,7 +515,7 @@ dependencies: "@babel/helper-plugin-utils" "^7.13.0" -"@babel/plugin-transform-dotall-regex@^7.12.13": +"@babel/plugin-transform-dotall-regex@^7.12.13", "@babel/plugin-transform-dotall-regex@^7.4.4": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.12.13.tgz#3f1601cc29905bfcb67f53910f197aeafebb25ad" integrity sha512-foDrozE65ZFdUC2OfgeOCrEPTxdB3yjqxpXh8CH+ipd9CHd4s/iq81kcUpyH8ACGNEPdFqbtzfgzbT/ZGlbDeQ== @@ -589,14 +523,6 @@ "@babel/helper-create-regexp-features-plugin" "^7.12.13" "@babel/helper-plugin-utils" "^7.12.13" -"@babel/plugin-transform-dotall-regex@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.4.4.tgz#361a148bc951444312c69446d76ed1ea8e4450c3" - dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-regex" "^7.4.4" - regexpu-core "^4.5.4" - "@babel/plugin-transform-duplicate-keys@^7.12.13": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.12.13.tgz#6f06b87a8b803fd928e54b81c258f0a0033904de" @@ -884,14 +810,6 @@ dependencies: regenerator-runtime "^0.13.4" -"@babel/template@^7.1.0": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.4.4.tgz#f4b88d1225689a08f5bc3a17483545be9e4ed237" - dependencies: - "@babel/code-frame" "^7.0.0" - "@babel/parser" "^7.4.4" - "@babel/types" "^7.4.4" - "@babel/template@^7.12.13": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.12.13.tgz#530265be8a2589dbb37523844c5bcb55947fb327" @@ -901,21 +819,7 @@ "@babel/parser" "^7.12.13" "@babel/types" "^7.12.13" -"@babel/traverse@^7.0.0": - version "7.4.5" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.4.5.tgz#4e92d1728fd2f1897dafdd321efbff92156c3216" - dependencies: - "@babel/code-frame" "^7.0.0" - "@babel/generator" "^7.4.4" - "@babel/helper-function-name" "^7.1.0" - "@babel/helper-split-export-declaration" "^7.4.4" - "@babel/parser" "^7.4.5" - "@babel/types" "^7.4.4" - debug "^4.1.0" - globals "^11.1.0" - lodash "^4.17.11" - -"@babel/traverse@^7.13.0", "@babel/traverse@^7.13.13", "@babel/traverse@^7.13.15", "@babel/traverse@^7.13.17": +"@babel/traverse@^7.13.0", "@babel/traverse@^7.13.13", "@babel/traverse@^7.13.15", "@babel/traverse@^7.13.17", "@babel/traverse@^7.7.0": version "7.13.17" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.13.17.tgz#c85415e0c7d50ac053d758baec98b28b2ecfeea3" integrity sha512-BMnZn0R+X6ayqm3C3To7o1j7Q020gWdqdyP50KEoVqaCO2c/Im7sYZSmVgvefp8TTMQ+9CtwuBp0Z1CZ8V3Pvg== @@ -929,15 +833,7 @@ debug "^4.1.0" globals "^11.1.0" -"@babel/types@^7.0.0", "@babel/types@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.4.4.tgz#8db9e9a629bb7c29370009b4b779ed93fe57d5f0" - dependencies: - esutils "^2.0.2" - lodash "^4.17.11" - to-fast-properties "^2.0.0" - -"@babel/types@^7.12.1", "@babel/types@^7.12.13", "@babel/types@^7.13.0", "@babel/types@^7.13.12", "@babel/types@^7.13.14", "@babel/types@^7.13.16", "@babel/types@^7.13.17": +"@babel/types@^7.12.1", "@babel/types@^7.12.13", "@babel/types@^7.13.0", "@babel/types@^7.13.12", "@babel/types@^7.13.14", "@babel/types@^7.13.16", "@babel/types@^7.13.17", "@babel/types@^7.4.4", "@babel/types@^7.7.0": version "7.13.17" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.13.17.tgz#48010a115c9fba7588b4437dd68c9469012b38b4" integrity sha512-RawydLgxbOPDlTLJNtoIypwdmAy//uQIzlKt2+iBiJaRlVuI6QLUxVAyWGNfOzp8Yu4L4lLIacoCyTNtpb4wiA== @@ -945,35 +841,29 @@ "@babel/helper-validator-identifier" "^7.12.11" to-fast-properties "^2.0.0" -"@sinonjs/commons@^1", "@sinonjs/commons@^1.4.0": - version "1.4.0" - resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-1.4.0.tgz#7b3ec2d96af481d7a0321252e7b1c94724ec5a78" - integrity sha512-9jHK3YF/8HtJ9wCAbG+j8cD0i0+ATS9A7gXFqS36TblLPNy6rEEc+SB0imo91eCboGaBYGV/MT1/br/J+EE7Tw== - dependencies: - type-detect "4.0.8" - -"@sinonjs/commons@^1.0.2": - version "1.3.0" - resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-1.3.0.tgz#50a2754016b6f30a994ceda6d9a0a8c36adda849" +"@sinonjs/commons@^1", "@sinonjs/commons@^1.3.0", "@sinonjs/commons@^1.4.0", "@sinonjs/commons@^1.7.0": + version "1.8.3" + resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-1.8.3.tgz#3802ddd21a50a949b6721ddd72da36e67e7f1b2d" + integrity sha512-xkNcLAn/wZaX14RPlwizcKicDk9G3F8m2nU3L7Ukm5zBgTwiT0wsoFAHx9Jq56fJA1z/7uKGtCRu16sOUCLIHQ== dependencies: type-detect "4.0.8" -"@sinonjs/formatio@^3.1.0", "@sinonjs/formatio@^3.2.1": - version "3.2.1" - resolved "https://registry.yarnpkg.com/@sinonjs/formatio/-/formatio-3.2.1.tgz#52310f2f9bcbc67bdac18c94ad4901b95fde267e" - integrity sha512-tsHvOB24rvyvV2+zKMmPkZ7dXX6LSLKZ7aOtXY6Edklp0uRcgGpOsQTTGTcWViFyx4uhWc6GV8QdnALbIbIdeQ== +"@sinonjs/formatio@^3.2.1": + version "3.2.2" + resolved "https://registry.yarnpkg.com/@sinonjs/formatio/-/formatio-3.2.2.tgz#771c60dfa75ea7f2d68e3b94c7e888a78781372c" + integrity sha512-B8SEsgd8gArBLMD6zpRw3juQ2FVSsmdd7qlevyDqzS9WTCtvF55/gAL+h6gue8ZvPYcdiPdvueM/qm//9XzyTQ== dependencies: "@sinonjs/commons" "^1" "@sinonjs/samsam" "^3.1.0" -"@sinonjs/samsam@^3.1.0", "@sinonjs/samsam@^3.3.1": - version "3.3.2" - resolved "https://registry.yarnpkg.com/@sinonjs/samsam/-/samsam-3.3.2.tgz#63942e3d5eb0b79f6de3bef9abfad15fb4b6401b" - integrity sha512-ILO/rR8LfAb60Y1Yfp9vxfYAASK43NFC2mLzpvLUbCQY/Qu8YwReboseu8aheCEkyElZF2L2T9mHcR2bgdvZyA== +"@sinonjs/samsam@^3.1.0", "@sinonjs/samsam@^3.3.3": + version "3.3.3" + resolved "https://registry.yarnpkg.com/@sinonjs/samsam/-/samsam-3.3.3.tgz#46682efd9967b259b81136b9f120fd54585feb4a" + integrity sha512-bKCMKZvWIjYD0BLGnNrxVuw4dkWCYsLqFOUWw8VgKF/+5Y+mE7LfHWPIYoDXowH+3a9LsWDMo0uAP8YDosPvHQ== dependencies: - "@sinonjs/commons" "^1.0.2" + "@sinonjs/commons" "^1.3.0" array-from "^2.1.1" - lodash "^4.17.11" + lodash "^4.17.15" "@sinonjs/text-encoding@^0.7.1": version "0.7.1" @@ -983,14 +873,17 @@ abbrev@1: version "1.1.1" resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8" + integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q== abbrev@1.0.x: version "1.0.9" resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.0.9.tgz#91b4792588a7738c25f35dd6f63752a2f8776135" + integrity sha1-kbR5JYinc4wl813W9jdSovh3YTU= acorn-jsx@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-3.0.1.tgz#afdf9488fb1ecefc8348f6fb22f464e32a58b36b" + integrity sha1-r9+UiPsezvyDSPb7IvRk4ypYs2s= dependencies: acorn "^3.0.4" @@ -1002,10 +895,12 @@ acorn-jsx@^5.2.0: acorn@^3.0.4: version "3.3.0" resolved "https://registry.yarnpkg.com/acorn/-/acorn-3.3.0.tgz#45e37fb39e8da3f25baee3ff5369e2bb5f22017a" + integrity sha1-ReN/s56No/JbruP/U2niu18iAXo= acorn@^5.5.0: - version "5.7.3" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.3.tgz#67aa231bf8812974b85235a96771eb6bd07ea279" + version "5.7.4" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.4.tgz#3e8d8a9947d0599a1796d10225d7432f4a4acf5e" + integrity sha512-1D++VG7BhrtvQpNbBzovKNc1FLGGEE/oGe7b9xJm/RFHMBeUaUGpluV9RLjZa47YFdPcDAenEYuq9pQPcMdLJg== acorn@^7.1.1: version "7.4.1" @@ -1015,31 +910,24 @@ acorn@^7.1.1: ajv-keywords@^2.1.0: version "2.1.1" resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-2.1.1.tgz#617997fc5f60576894c435f940d819e135b80762" + integrity sha1-YXmX/F9gV2iUxDX5QNgZ4TW4B2I= ajv@^5.2.3, ajv@^5.3.0: version "5.5.2" resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.2.tgz#73b5eeca3fab653e3d3f9422b341ad42205dc965" + integrity sha1-c7Xuyj+rZT49P5Qis0GtQiBdyWU= dependencies: co "^4.6.0" fast-deep-equal "^1.0.0" fast-json-stable-stringify "^2.0.0" json-schema-traverse "^0.3.0" -ajv@^6.10.0, ajv@^6.9.1: - version "6.10.0" - resolved "https://registry.npmjs.org/ajv/-/ajv-6.10.0.tgz#90d0d54439da587cd7e843bfb7045f50bd22bdf1" +ajv@^6.10.0, ajv@^6.10.2, ajv@^6.12.3: + version "6.12.6" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" + integrity sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g== dependencies: - fast-deep-equal "^2.0.1" - fast-json-stable-stringify "^2.0.0" - json-schema-traverse "^0.4.1" - uri-js "^4.2.2" - -ajv@^6.5.5: - version "6.10.2" - resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.10.2.tgz#d3cea04d6b017b2894ad69040fec8b623eb4bd52" - integrity sha512-TXtUUEYHuaTEbLZWIKUr5pmBuhDLy+8KYtPYdcV8qC+pOZL+NKqYwvWSRrVXHn+ZmRRAu8vJTAznH7Oag6RVRw== - dependencies: - fast-deep-equal "^2.0.1" + fast-deep-equal "^3.1.1" fast-json-stable-stringify "^2.0.0" json-schema-traverse "^0.4.1" uri-js "^4.2.2" @@ -1047,10 +935,12 @@ ajv@^6.5.5: amdefine@>=0.0.4: version "1.0.1" resolved "https://registry.yarnpkg.com/amdefine/-/amdefine-1.0.1.tgz#4a5282ac164729e93619bcfd3ad151f817ce91f5" + integrity sha1-SlKCrBZHKek2Gbz9OtFR+BfOkfU= ansi-colors@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-1.1.0.tgz#6374b4dd5d4718ff3ce27a671a3b1cad077132a9" + integrity sha512-SFKX67auSNoVR38N3L+nvsPjOE0bybKTYbkf5tRvushrAPQ9V75huw0ZxBkKVeRU9kqH3d6HA4xTckbwZ4ixmA== dependencies: ansi-wrap "^0.1.0" @@ -1064,6 +954,7 @@ ansi-cyan@^0.1.1: ansi-escapes@^3.0.0: version "3.2.0" resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.2.0.tgz#8780b98ff9dbf5638152d1f1fe5c1d7b4442976b" + integrity sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ== ansi-escapes@^4.2.1: version "4.3.2" @@ -1075,6 +966,7 @@ ansi-escapes@^4.2.1: ansi-gray@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/ansi-gray/-/ansi-gray-0.1.1.tgz#2962cf54ec9792c48510a3deb524436861ef7251" + integrity sha1-KWLPVOyXksSFEKPetSRDaGHvclE= dependencies: ansi-wrap "0.1.0" @@ -1088,14 +980,17 @@ ansi-red@^0.1.1: ansi-regex@^2.0.0: version "2.1.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" + integrity sha1-w7M6te42DYbg5ijwRorn7yfWVN8= ansi-regex@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.0.tgz#ed0317c322064f79466c02966bddb605ab37d998" + integrity sha1-7QMXwyIGT3lGbAKWa922Bas32Zg= ansi-regex@^4.1.0: version "4.1.0" - resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz#8b9f8f08cf1acb843756a839ca8c7e3168c51997" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.1.0.tgz#8b9f8f08cf1acb843756a839ca8c7e3168c51997" + integrity sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg== ansi-regex@^5.0.0: version "5.0.0" @@ -1105,10 +1000,12 @@ ansi-regex@^5.0.0: ansi-styles@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" + integrity sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4= ansi-styles@^3.2.0, ansi-styles@^3.2.1: version "3.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" + integrity sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA== dependencies: color-convert "^1.9.0" @@ -1122,10 +1019,12 @@ ansi-styles@^4.1.0: ansi-wrap@0.1.0, ansi-wrap@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/ansi-wrap/-/ansi-wrap-0.1.0.tgz#a82250ddb0015e9a27ca82e82ea603bbfa45efaf" + integrity sha1-qCJQ3bABXponyoLoLqYDu/pF768= anymatch@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-2.0.0.tgz#bcb24b4f37934d9aa7ac17b4adaf89e7c76ef2eb" + integrity sha512-5teOsQWABXHHBFP9y3skS5P3d/WfWXpv3FUpy+LorMrNYaT9pI4oLMQX7jzQ2KklNpGpWHzdCXTDT2Y3XGlZBw== dependencies: micromatch "^3.1.4" normalize-path "^2.1.1" @@ -1133,27 +1032,19 @@ anymatch@^2.0.0: append-buffer@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/append-buffer/-/append-buffer-1.0.2.tgz#d8220cf466081525efea50614f3de6514dfa58f1" + integrity sha1-2CIM9GYIFSXv6lBhTz3mUU36WPE= dependencies: buffer-equal "^1.0.0" -aproba@^1.0.3: - version "1.2.0" - resolved "https://registry.yarnpkg.com/aproba/-/aproba-1.2.0.tgz#6802e6264efd18c790a1b0d517f0f2627bf2c94a" - archy@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/archy/-/archy-1.0.0.tgz#f9c8c13757cc1dd7bc379ac77b2c62a5c2868c40" - -are-we-there-yet@~1.1.2: - version "1.1.5" - resolved "https://registry.yarnpkg.com/are-we-there-yet/-/are-we-there-yet-1.1.5.tgz#4b35c2944f062a8bfcda66410760350fe9ddfc21" - dependencies: - delegates "^1.0.0" - readable-stream "^2.0.6" + integrity sha1-+cjBN1fMHde8N5rHeyxipcKGjEA= argparse@^1.0.7: version "1.0.10" resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.10.tgz#bcd6791ea5ae09725e17e5ad988134cd40b3d911" + integrity sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg== dependencies: sprintf-js "~1.0.2" @@ -1168,20 +1059,24 @@ arr-diff@^1.0.1: arr-diff@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-4.0.0.tgz#d6461074febfec71e7e15235761a329a5dc7c520" + integrity sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA= arr-filter@^1.1.1: version "1.1.2" resolved "https://registry.yarnpkg.com/arr-filter/-/arr-filter-1.1.2.tgz#43fdddd091e8ef11aa4c45d9cdc18e2dff1711ee" + integrity sha1-Q/3d0JHo7xGqTEXZzcGOLf8XEe4= dependencies: make-iterator "^1.0.0" arr-flatten@^1.0.1, arr-flatten@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/arr-flatten/-/arr-flatten-1.1.0.tgz#36048bbff4e7b47e136644316c99669ea5ae91f1" + integrity sha512-L3hKV5R/p5o81R7O02IGnwpDmkp6E982XhtbuwSe3O4qOtMMMtodicASA1Cny2U+aCXcNpml+m4dPsvsJ3jatg== arr-map@^2.0.0, arr-map@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/arr-map/-/arr-map-2.0.2.tgz#3a77345ffc1cf35e2a91825601f9e58f2e24cac4" + integrity sha1-Onc0X/wc814qkYJWAfnljy4kysQ= dependencies: make-iterator "^1.0.0" @@ -1193,18 +1088,22 @@ arr-union@^2.0.1: arr-union@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/arr-union/-/arr-union-3.1.0.tgz#e39b09aea9def866a8f206e288af63919bae39c4" + integrity sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ= array-each@^1.0.0, array-each@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/array-each/-/array-each-1.0.1.tgz#a794af0c05ab1752846ee753a1f211a05ba0c44f" + integrity sha1-p5SvDAWrF1KEbudTofIRoFugxE8= array-from@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/array-from/-/array-from-2.1.1.tgz#cfe9d8c26628b9dc5aecc62a9f5d8f1f352c1195" + integrity sha1-z+nYwmYoudxa7MYqn12PHzUsEZU= array-initial@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/array-initial/-/array-initial-1.1.0.tgz#2fa74b26739371c3947bd7a7adc73be334b3d795" + integrity sha1-L6dLJnOTccOUe9enrcc74zSz15U= dependencies: array-slice "^1.0.0" is-number "^4.0.0" @@ -1212,6 +1111,7 @@ array-initial@^1.0.0: array-last@^1.1.1: version "1.3.0" resolved "https://registry.yarnpkg.com/array-last/-/array-last-1.3.0.tgz#7aa77073fec565ddab2493f5f88185f404a9d336" + integrity sha512-eOCut5rXlI6aCOS7Z7kCplKRKyiFQ6dHFBem4PwlwKeNFk2/XxTrhRh5T9PyaEWGy/NHTZWbY+nsZlNFJu9rYg== dependencies: is-number "^4.0.0" @@ -1223,10 +1123,12 @@ array-slice@^0.2.3: array-slice@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/array-slice/-/array-slice-1.1.0.tgz#e368ea15f89bc7069f7ffb89aec3a6c7d4ac22d4" + integrity sha512-B1qMD3RBP7O8o0H2KbrXDyB0IccejMF15+87Lvlor12ONPRHP6gTjXMNkt/d3ZuOGbAe66hFmaCfECI24Ufp6w== array-sort@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/array-sort/-/array-sort-1.0.0.tgz#e4c05356453f56f53512a7d1d6123f2c54c0a88a" + integrity sha512-ihLeJkonmdiAsD7vpgN3CRcx2J2S0TiYW+IS/5zHBI7mKUq3ySvBdzzBfD236ubDBQFiiyG3SWCPc+msQ9KoYg== dependencies: default-compare "^1.0.0" get-value "^2.0.6" @@ -1235,32 +1137,34 @@ array-sort@^1.0.0: array-unique@^0.3.2: version "0.3.2" resolved "https://registry.yarnpkg.com/array-unique/-/array-unique-0.3.2.tgz#a894b75d4bc4f6cd679ef3244a9fd8f46ae2d428" + integrity sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg= asn1@~0.2.3: version "0.2.4" resolved "https://registry.yarnpkg.com/asn1/-/asn1-0.2.4.tgz#8d2475dfab553bb33e77b54e59e880bb8ce23136" + integrity sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg== dependencies: safer-buffer "~2.1.0" assert-plus@1.0.0, assert-plus@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-1.0.0.tgz#f12e0f3c5d77b0b1cdd9146942e4e96c1e4dd525" - -assertion-error@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/assertion-error/-/assertion-error-1.0.2.tgz#13ca515d86206da0bac66e834dd397d87581094c" + integrity sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU= assign-symbols@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/assign-symbols/-/assign-symbols-1.0.0.tgz#59667f41fadd4f20ccbc2bb96b8d4f7f78ec0367" + integrity sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c= astral-regex@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/astral-regex/-/astral-regex-1.0.0.tgz#6c8c3fb827dd43ee3918f27b82782ab7658a6fd9" + resolved "https://registry.yarnpkg.com/astral-regex/-/astral-regex-1.0.0.tgz#6c8c3fb827dd43ee3918f27b82782ab7658a6fd9" + integrity sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg== async-done@^1.2.0, async-done@^1.2.2: version "1.3.2" resolved "https://registry.yarnpkg.com/async-done/-/async-done-1.3.2.tgz#5e15aa729962a4b07414f528a88cdf18e0b290a2" + integrity sha512-uYkTP8dw2og1tu1nmza1n1CMW0qb8gWWlwqMmLb7MhBVs4BXrFziT6HXUd+/RlRA/i4H9AkofYloUbs1fwMqlw== dependencies: end-of-stream "^1.1.0" once "^1.3.2" @@ -1270,52 +1174,60 @@ async-done@^1.2.0, async-done@^1.2.2: async-each@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/async-each/-/async-each-1.0.3.tgz#b727dbf87d7651602f06f4d4ac387f47d91b0cbf" + integrity sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ== async-settle@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/async-settle/-/async-settle-1.0.0.tgz#1d0a914bb02575bec8a8f3a74e5080f72b2c0c6b" + integrity sha1-HQqRS7Aldb7IqPOnTlCA9yssDGs= dependencies: async-done "^1.2.2" async@1.x: version "1.5.2" resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a" + integrity sha1-7GphrlZIDAw8skHJVhjiCJL5Zyo= asynckit@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" + integrity sha1-x57Zf380y48robyXkLzDZkdLS3k= -atob@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/atob/-/atob-2.1.0.tgz#ab2b150e51d7b122b9efc8d7340c06b6c41076bc" +atob@^2.1.2: + version "2.1.2" + resolved "https://registry.yarnpkg.com/atob/-/atob-2.1.2.tgz#6d9517eb9e030d2436666651e86bd9f6f13533c9" + integrity sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg== aws-sign2@~0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz#b46e890934a9591f2d2f6f86d7e6a9f1b3fe76a8" + integrity sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg= aws4@^1.8.0: - version "1.8.0" - resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.8.0.tgz#f0e003d9ca9e7f59c7a508945d7b2ef9a04a542f" - integrity sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ== + version "1.11.0" + resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.11.0.tgz#d61f46d83b2519250e2784daf5b09479a8b41c59" + integrity sha512-xh1Rl34h6Fi1DC2WWKfxUTVqRsNnr6LsKz2+hfwDxQJWmrx8+c7ylaqBMcHfl1U1r2dsifOvKX3LQuLNZ+XSvA== babel-code-frame@^6.22.0: version "6.26.0" resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.26.0.tgz#63fd43f7dc1e3bb7ce35947db8fe369a3f58c74b" + integrity sha1-Y/1D99weO7fONZR9uP42mj9Yx0s= dependencies: chalk "^1.1.3" esutils "^2.0.2" js-tokens "^3.0.2" babel-eslint@^10.0.2: - version "10.0.2" - resolved "https://registry.yarnpkg.com/babel-eslint/-/babel-eslint-10.0.2.tgz#182d5ac204579ff0881684b040560fdcc1558456" + version "10.1.0" + resolved "https://registry.yarnpkg.com/babel-eslint/-/babel-eslint-10.1.0.tgz#6968e568a910b78fb3779cdd8b6ac2f479943232" + integrity sha512-ifWaTHQ0ce+448CYop8AdrQiBsGrnC+bMgfyKFdi6EsPLTAWG+QfyDeM6OH+FmWnKvEq5NnBMLvlBUPKQZoDSg== dependencies: "@babel/code-frame" "^7.0.0" - "@babel/parser" "^7.0.0" - "@babel/traverse" "^7.0.0" - "@babel/types" "^7.0.0" - eslint-scope "3.7.1" + "@babel/parser" "^7.7.0" + "@babel/traverse" "^7.7.0" + "@babel/types" "^7.7.0" eslint-visitor-keys "^1.0.0" + resolve "^1.12.0" babel-plugin-dynamic-import-node@^2.3.3: version "2.3.3" @@ -1351,6 +1263,7 @@ babel-plugin-polyfill-regenerator@^0.2.0: bach@^1.0.0: version "1.2.0" resolved "https://registry.yarnpkg.com/bach/-/bach-1.2.0.tgz#4b3ce96bf27134f79a1b414a51c14e34c3bd9880" + integrity sha1-Szzpa/JxNPeaG0FKUcFONMO9mIA= dependencies: arr-filter "^1.1.1" arr-flatten "^1.0.1" @@ -1363,12 +1276,14 @@ bach@^1.0.0: now-and-later "^2.0.0" balanced-match@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767" + version "1.0.2" + resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" + integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== base@^0.11.1: version "0.11.2" resolved "https://registry.yarnpkg.com/base/-/base-0.11.2.tgz#7bde5ced145b6d551a90db87f83c558b4eb48a8f" + integrity sha512-5T6P4xPgpp0YDFvSWwEZ4NoE3aM4QBQXDzmVbraCkFj8zHM+mba8SyqB5DbZWyR7mYHo6Y7BdQo3MoA4m0TeQg== dependencies: cache-base "^1.0.1" class-utils "^0.3.5" @@ -1381,12 +1296,21 @@ base@^0.11.1: bcrypt-pbkdf@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz#a4301d389b6a43f9b67ff3ca11a3f6637e360e9e" + integrity sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4= dependencies: tweetnacl "^0.14.3" binary-extensions@^1.0.0: version "1.13.1" resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-1.13.1.tgz#598afe54755b2868a5330d2aff9d4ebb53209b65" + integrity sha512-Un7MIEDdUC5gNpcGDV97op1Ywk748MpHcFTHoYs6qnj1Z3j7I53VG3nwZhKzoBZmbdRNnb6WRdFlwl7tSDuZGw== + +bindings@^1.5.0: + version "1.5.0" + resolved "https://registry.yarnpkg.com/bindings/-/bindings-1.5.0.tgz#10353c9e945334bc0511a6d90b38fbc7c9c504df" + integrity sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ== + dependencies: + file-uri-to-path "1.0.0" bluebird@^3.7.2: version "3.7.2" @@ -1394,8 +1318,9 @@ bluebird@^3.7.2: integrity sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg== brace-expansion@^1.1.7: - version "1.1.8" - resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.8.tgz#c07b211c7c952ec1f8efd51a77ef0d1d3990a292" + version "1.1.11" + resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd" + integrity sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA== dependencies: balanced-match "^1.0.0" concat-map "0.0.1" @@ -1403,6 +1328,7 @@ brace-expansion@^1.1.7: braces@^2.3.1, braces@^2.3.2: version "2.3.2" resolved "https://registry.yarnpkg.com/braces/-/braces-2.3.2.tgz#5979fd3f14cd531565e5fa2df1abfff1dfaee729" + integrity sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w== dependencies: arr-flatten "^1.1.0" array-unique "^0.3.2" @@ -1417,9 +1343,10 @@ braces@^2.3.1, braces@^2.3.2: browser-stdout@1.3.1: version "1.3.1" - resolved "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz#baa559ee14ced73452229bad7326467c61fabd60" + resolved "https://registry.yarnpkg.com/browser-stdout/-/browser-stdout-1.3.1.tgz#baa559ee14ced73452229bad7326467c61fabd60" + integrity sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw== -browserslist@^4.14.5, browserslist@^4.16.4: +browserslist@^4.14.5, browserslist@^4.16.5: version "4.16.5" resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.16.5.tgz#952825440bca8913c62d0021334cbe928ef062ae" integrity sha512-C2HAjrM1AI/djrpAUU/tr4pml1DqLIzJKSLDBXBrNErl9ZCCTXdhwxdJjYc16953+mBWf7Lw+uUJgpgb8cN71A== @@ -1433,14 +1360,17 @@ browserslist@^4.14.5, browserslist@^4.16.4: buffer-equal@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/buffer-equal/-/buffer-equal-1.0.0.tgz#59616b498304d556abd466966b22eeda3eca5fbe" + integrity sha1-WWFrSYME1Var1GaWayLu2j7KX74= buffer-from@^1.0.0: version "1.1.1" resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.1.tgz#32713bc028f75c02fdb710d7c7bcec1f2c6070ef" + integrity sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A== cache-base@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/cache-base/-/cache-base-1.0.1.tgz#0a7f46416831c8b662ee36fe4e7c59d76f666ab2" + integrity sha512-AKcdTnFSWATd5/GCPRxr2ChwIJ85CeyrEyjRHlKxQ56d4XJMGym0uAiKn0xbLOGOl3+yRpOTi484dVCEc5AUzQ== dependencies: collection-visit "^1.0.0" component-emitter "^1.2.1" @@ -1463,41 +1393,39 @@ call-bind@^1.0.0: caller-path@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/caller-path/-/caller-path-0.1.0.tgz#94085ef63581ecd3daa92444a8fe94e82577751f" + integrity sha1-lAhe9jWB7NPaqSREqP6U6CV3dR8= dependencies: callsites "^0.2.0" callsites@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/callsites/-/callsites-0.2.0.tgz#afab96262910a7f33c19a5775825c69f34e350ca" + integrity sha1-r6uWJikQp/M8GaV3WCXGnzTjUMo= callsites@^3.0.0: version "3.1.0" - resolved "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" + resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" + integrity sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ== camelcase@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-3.0.0.tgz#32fc4b9fcdaf845fcdf7e73bb97cac2261f0ab0a" + integrity sha1-MvxLn82vhF/N9+c7uXysImHwqwo= caniuse-lite@^1.0.30001214: - version "1.0.30001218" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001218.tgz#9b44f6ed16f875db6373e2debd4d14a07359002f" - integrity sha512-0ASydOWSy3bB88FbDpJSTt+PfDwnMqrym3yRZfqG8EXSQ06OZhF+q5wgYP/EN+jJMERItNcDQUqMyNjzZ+r5+Q== + version "1.0.30001219" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001219.tgz#5bfa5d0519f41f993618bd318f606a4c4c16156b" + integrity sha512-c0yixVG4v9KBc/tQ2rlbB3A/bgBFRvl8h8M4IeUbqCca4gsiCfvtaheUssbnux/Mb66Vjz7x8yYjDgYcNQOhyQ== caseless@~0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" - -"chai@>=1.9.2 <4.0.0": - version "3.5.0" - resolved "https://registry.yarnpkg.com/chai/-/chai-3.5.0.tgz#4d02637b067fe958bdbfdd3a40ec56fef7373247" - dependencies: - assertion-error "^1.0.1" - deep-eql "^0.1.3" - type-detect "^1.0.0" + integrity sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw= chalk@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/chalk/-/chalk-1.1.3.tgz#a8115c55e4a702fe4d150abd3872822a7e09fc98" + integrity sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg= dependencies: ansi-styles "^2.2.1" escape-string-regexp "^1.0.2" @@ -1508,6 +1436,7 @@ chalk@^1.1.3: chalk@^2.0.0, chalk@^2.1.0: version "2.4.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" + integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== dependencies: ansi-styles "^3.2.1" escape-string-regexp "^1.0.5" @@ -1524,14 +1453,17 @@ chalk@^4.1.0: chardet@^0.4.0: version "0.4.2" resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.4.2.tgz#b5473b33dc97c424e5d98dc87d55d4d8a29c8bf2" + integrity sha1-tUc7M9yXxCTl2Y3IfVXU2KKci/I= chardet@^0.7.0: version "0.7.0" - resolved "https://registry.npmjs.org/chardet/-/chardet-0.7.0.tgz#90094849f0937f2eedc2425d0d28a9e5f0cbad9e" + resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.7.0.tgz#90094849f0937f2eedc2425d0d28a9e5f0cbad9e" + integrity sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA== chokidar@^2.0.0: - version "2.1.6" - resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-2.1.6.tgz#b6cad653a929e244ce8a834244164d241fa954c5" + version "2.1.8" + resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-2.1.8.tgz#804b3a7b6a99358c3c5c61e71d8728f041cff917" + integrity sha512-ZmZUazfOzf0Nve7duiCKD23PFSCs4JPoYyccjUFF3aQkQadqBhfzhjkwBH2mNOG9cTBwhamM37EIsIkZw3nRgg== dependencies: anymatch "^2.0.0" async-each "^1.0.1" @@ -1547,17 +1479,15 @@ chokidar@^2.0.0: optionalDependencies: fsevents "^1.2.7" -chownr@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/chownr/-/chownr-1.1.1.tgz#54726b8b8fff4df053c42187e801fb4412df1494" - circular-json@^0.3.1: version "0.3.3" resolved "https://registry.yarnpkg.com/circular-json/-/circular-json-0.3.3.tgz#815c99ea84f6809529d2f45791bdf82711352d66" + integrity sha512-UZK3NBx2Mca+b5LsG7bY183pHWt5Y1xts4P3Pz7ENTwGVnJOUWbRb3ocjvX7hx9tq/yTAdclXm9sZ38gNuem4A== class-utils@^0.3.5: version "0.3.6" resolved "https://registry.yarnpkg.com/class-utils/-/class-utils-0.3.6.tgz#f93369ae8b9a7ce02fd41faad0ca83033190c463" + integrity sha512-qOhPa/Fj7s6TY8H8esGu5QNpMMQxz79h+urzrNYN6mn+9BnxlDGf5QZ+XeCDsxSjPqsSR56XOZOJmpeurnLMeg== dependencies: arr-union "^3.1.0" define-property "^0.2.5" @@ -1567,6 +1497,7 @@ class-utils@^0.3.5: cli-cursor@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-2.1.0.tgz#b35dac376479facc3e94747d41d0d0f5238ffcb5" + integrity sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU= dependencies: restore-cursor "^2.0.0" @@ -1578,8 +1509,9 @@ cli-cursor@^3.1.0: restore-cursor "^3.1.0" cli-width@^2.0.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-2.2.0.tgz#ff19ede8a9a5e579324147b0c11f0fbcbabed639" + version "2.2.1" + resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-2.2.1.tgz#b0433d0b4e9c847ef18868a4ef16fd5fc8271c48" + integrity sha512-GRMWDxpOB6Dgk2E5Uo+3eEBvtOOlimMmpbFiKuLFnQzYDavtLFY3K5ona41jgN/WdRZtG7utuVSVTL4HbZHGkw== cli-width@^3.0.0: version "3.0.0" @@ -1589,6 +1521,7 @@ cli-width@^3.0.0: cliui@^3.2.0: version "3.2.0" resolved "https://registry.yarnpkg.com/cliui/-/cliui-3.2.0.tgz#120601537a916d29940f934da3b48d585a39213d" + integrity sha1-EgYBU3qRbSmUD5NNo7SNWFo5IT0= dependencies: string-width "^1.0.1" strip-ansi "^3.0.1" @@ -1597,6 +1530,7 @@ cliui@^3.2.0: clone-buffer@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/clone-buffer/-/clone-buffer-1.0.0.tgz#e3e25b207ac4e701af721e2cb5a16792cac3dc58" + integrity sha1-4+JbIHrE5wGvch4staFnksrD3Fg= clone-deep@^4.0.1: version "4.0.1" @@ -1610,14 +1544,17 @@ clone-deep@^4.0.1: clone-stats@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/clone-stats/-/clone-stats-1.0.0.tgz#b3782dff8bb5474e18b9b6bf0fdfe782f8777680" + integrity sha1-s3gt/4u1R04Yuba/D9/ngvh3doA= clone@^2.1.1: version "2.1.2" resolved "https://registry.yarnpkg.com/clone/-/clone-2.1.2.tgz#1b7f4b9f591f1e8f83670401600345a02887435f" + integrity sha1-G39Ln1kfHo+DZwQBYANFoCiHQ18= cloneable-readable@^1.0.0: version "1.1.3" resolved "https://registry.yarnpkg.com/cloneable-readable/-/cloneable-readable-1.1.3.tgz#120a00cb053bfb63a222e709f9683ea2e11d8cec" + integrity sha512-2EF8zTQOxYq70Y4XKtorQupqF0m49MBz2/yf5Bj+MHjvpG3Hy7sImifnqD6UA+TKYxeSV+u6qqQPawN5UvnpKQ== dependencies: inherits "^2.0.1" process-nextick-args "^2.0.0" @@ -1626,14 +1563,17 @@ cloneable-readable@^1.0.0: co@^4.6.0: version "4.6.0" resolved "https://registry.yarnpkg.com/co/-/co-4.6.0.tgz#6ea6bdf3d853ae54ccb8e47bfa0bf3f9031fb184" + integrity sha1-bqa989hTrlTMuOR7+gvz+QMfsYQ= code-point-at@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77" + integrity sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c= collection-map@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/collection-map/-/collection-map-1.0.0.tgz#aea0f06f8d26c780c2b75494385544b2255af18c" + integrity sha1-rqDwb40mx4DCt1SUOFVEsiVa8Yw= dependencies: arr-map "^2.0.2" for-own "^1.0.0" @@ -1642,6 +1582,7 @@ collection-map@^1.0.0: collection-visit@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/collection-visit/-/collection-visit-1.0.0.tgz#4bc0373c164bc3291b4d368c829cf1a80a59dca0" + integrity sha1-S8A3PBZLwykbTTaMgpzxqApZ3KA= dependencies: map-visit "^1.0.0" object-visit "^1.0.0" @@ -1649,6 +1590,7 @@ collection-visit@^1.0.0: color-convert@^1.9.0: version "1.9.3" resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.3.tgz#bb71850690e1f136567de629d2d5471deda4c1e8" + integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== dependencies: color-name "1.1.3" @@ -1662,6 +1604,7 @@ color-convert@^2.0.1: color-name@1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" + integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= color-name@~1.1.4: version "1.1.4" @@ -1671,6 +1614,7 @@ color-name@~1.1.4: color-support@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/color-support/-/color-support-1.1.3.tgz#93834379a1cc9a0c61f82f52f0d04322251bd5a2" + integrity sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg== colorette@^1.2.2: version "1.2.2" @@ -1686,43 +1630,35 @@ combined-stream@^1.0.6, combined-stream@~1.0.6: commander@2.15.1: version "2.15.1" - resolved "https://registry.npmjs.org/commander/-/commander-2.15.1.tgz#df46e867d0fc2aec66a34662b406a9ccafff5b0f" - -commander@~2.20.0: - version "2.20.3" - resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" - integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ== + resolved "https://registry.yarnpkg.com/commander/-/commander-2.15.1.tgz#df46e867d0fc2aec66a34662b406a9ccafff5b0f" + integrity sha512-VlfT9F3V0v+jr4yxPc5gg9s62/fIVWsd2Bk2iD435um1NlGMYdVCq+MjcXnhYq2icNOizHr1kK+5TI6H0Hy0ag== commondir@^1.0.1: version "1.0.1" - resolved "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz#ddd800da0c66127393cca5950ea968a3aaf1253b" + resolved "https://registry.yarnpkg.com/commondir/-/commondir-1.0.1.tgz#ddd800da0c66127393cca5950ea968a3aaf1253b" + integrity sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs= component-emitter@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.2.1.tgz#137918d6d78283f7df7a6b7c5a63e140e69425e6" + version "1.3.0" + resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.3.0.tgz#16e4070fba8ae29b679f2215853ee181ab2eabc0" + integrity sha512-Rd3se6QB+sO1TwqZjscQrurpEPIfO0/yYnSin6Q/rD3mOutHvUrCAhJub3r90uNb+SESBuE0QYoB90YdfatsRg== concat-map@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" + integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= concat-stream@^1.6.0: version "1.6.2" resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34" + integrity sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw== dependencies: buffer-from "^1.0.0" inherits "^2.0.3" readable-stream "^2.2.2" typedarray "^0.0.6" -console-control-strings@^1.0.0, console-control-strings@~1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/console-control-strings/-/console-control-strings-1.1.0.tgz#3d7cf4464db6446ea644bf4b39507f9851008e8e" - -convert-source-map@^1.5.0: - version "1.5.0" - resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.5.0.tgz#9acd70851c6d5dfdd93d9282e5edf94a03ff46b5" - -convert-source-map@^1.7.0: +convert-source-map@^1.5.0, convert-source-map@^1.7.0: version "1.7.0" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.7.0.tgz#17a2cb882d7f77d3490585e2ce6c524424a3a442" integrity sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA== @@ -1732,29 +1668,33 @@ convert-source-map@^1.7.0: copy-descriptor@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" + integrity sha1-Z29us8OZl8LuGsOpJP1hJHSPV40= copy-props@^2.0.1: - version "2.0.4" - resolved "https://registry.yarnpkg.com/copy-props/-/copy-props-2.0.4.tgz#93bb1cadfafd31da5bb8a9d4b41f471ec3a72dfe" + version "2.0.5" + resolved "https://registry.yarnpkg.com/copy-props/-/copy-props-2.0.5.tgz#03cf9ae328d4ebb36f8f1d804448a6af9ee3f2d2" + integrity sha512-XBlx8HSqrT0ObQwmSzM7WE5k8FxTV75h1DX1Z3n6NhQ/UYYAvInWYmG06vFt7hQZArE2fuO62aihiWIVQwh1sw== dependencies: - each-props "^1.3.0" - is-plain-object "^2.0.1" + each-props "^1.3.2" + is-plain-object "^5.0.0" core-js-compat@^3.9.0, core-js-compat@^3.9.1: - version "3.11.0" - resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.11.0.tgz#635683f43480a0b41e3f6be3b1c648dadb8b4390" - integrity sha512-3wsN9YZJohOSDCjVB0GequOyHax8zFiogSX3XWLE28M1Ew7dTU57tgHjIylSBKSIouwmLBp3g61sKMz/q3xEGA== + version "3.11.1" + resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.11.1.tgz#57a91e9b02d3bb8cf37f82eceaf44a3d646fa614" + integrity sha512-aZ0e4tmlG/aOBHj92/TuOuZwp6jFvn1WNabU5VOVixzhu5t5Ao+JZkQOPlgNXu6ynwLrwJxklT4Gw1G1VGEh+g== dependencies: - browserslist "^4.16.4" + browserslist "^4.16.5" semver "7.0.0" core-util-is@1.0.2, core-util-is@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" + integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac= cross-spawn@^5.1.0: version "5.1.0" resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-5.1.0.tgz#e8bd0efee58fcff6f8f94510a0a554bbfa235449" + integrity sha1-6L0O/uWPz/b4+UUQoKVUu/ojVEk= dependencies: lru-cache "^4.0.1" shebang-command "^1.2.0" @@ -1762,7 +1702,8 @@ cross-spawn@^5.1.0: cross-spawn@^6.0.0, cross-spawn@^6.0.5: version "6.0.5" - resolved "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4" + integrity sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ== dependencies: nice-try "^1.0.4" path-key "^2.0.1" @@ -1770,48 +1711,48 @@ cross-spawn@^6.0.0, cross-spawn@^6.0.5: shebang-command "^1.2.0" which "^1.2.9" -d@1: +d@1, d@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/d/-/d-1.0.1.tgz#8698095372d58dbee346ffd0c7093f99f8f9eb5a" + integrity sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA== dependencies: es5-ext "^0.10.50" type "^1.0.1" dargs@^5.1.0: version "5.1.0" - resolved "https://registry.npmjs.org/dargs/-/dargs-5.1.0.tgz#ec7ea50c78564cd36c9d5ec18f66329fade27829" + resolved "https://registry.yarnpkg.com/dargs/-/dargs-5.1.0.tgz#ec7ea50c78564cd36c9d5ec18f66329fade27829" + integrity sha1-7H6lDHhWTNNsnV7Bj2Yyn63ieCk= dashdash@^1.12.0: version "1.14.1" resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0" + integrity sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA= dependencies: assert-plus "^1.0.0" debug@3.1.0: version "3.1.0" - resolved "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" + resolved "https://registry.yarnpkg.com/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" + integrity sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g== dependencies: ms "2.0.0" debug@^2.2.0, debug@^2.3.3: version "2.6.9" resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" + integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== dependencies: ms "2.0.0" -debug@^3.1.0, debug@^3.2.6: - version "3.2.6" - resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.6.tgz#e83d17de16d8a7efb7717edbe5fb10135eee629b" - dependencies: - ms "^2.1.1" - -debug@^4.0.1, debug@^4.1.0: - version "4.1.1" - resolved "https://registry.yarnpkg.com/debug/-/debug-4.1.1.tgz#3b72260255109c6b589cee050f1d516139664791" +debug@^3.1.0: + version "3.2.7" + resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.7.tgz#72580b7e9145fb39b6676f9c5e5fb100b934179a" + integrity sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ== dependencies: ms "^2.1.1" -debug@^4.1.1: +debug@^4.0.1, debug@^4.1.0, debug@^4.1.1: version "4.3.1" resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.1.tgz#f0d229c505e0c6d8c49ac553d1b13dc183f6b2ee" integrity sha512-doEwdvm4PCeK4K3RQN2ZC2BYUBaxwLARCqZmMjtF8a51J2Rb0xpVloFRnCODwqjpwnAoao4pelN8l3RJdv3gRQ== @@ -1821,40 +1762,31 @@ debug@^4.1.1: decamelize@^1.1.1: version "1.2.0" resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" + integrity sha1-9lNNFRSCabIDUue+4m9QH5oZEpA= decode-uri-component@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545" - -deep-eql@^0.1.3: - version "0.1.3" - resolved "https://registry.yarnpkg.com/deep-eql/-/deep-eql-0.1.3.tgz#ef558acab8de25206cd713906d74e56930eb69f2" - dependencies: - type-detect "0.1.1" - -deep-equal@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/deep-equal/-/deep-equal-1.0.1.tgz#f5d260292b660e084eff4cdbc9f08ad3247448b5" - -deep-extend@^0.6.0: - version "0.6.0" - resolved "https://registry.yarnpkg.com/deep-extend/-/deep-extend-0.6.0.tgz#c4fa7c95404a17a9c3e8ca7e1537312b736330ac" + integrity sha1-6zkTMzRYd1y4TNGh+uBiEGu4dUU= deep-is@~0.1.3: version "0.1.3" resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34" + integrity sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ= default-compare@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/default-compare/-/default-compare-1.0.0.tgz#cb61131844ad84d84788fb68fd01681ca7781a2f" + integrity sha512-QWfXlM0EkAbqOCbD/6HjdwT19j7WCkMyiRhWilc4H9/5h/RzTF9gv5LYh1+CmDV5d1rki6KAWLtQale0xt20eQ== dependencies: kind-of "^5.0.2" default-resolution@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/default-resolution/-/default-resolution-2.0.0.tgz#bcb82baa72ad79b426a76732f1a81ad6df26d684" + integrity sha1-vLgrqnKtebQmp2cy8aga1t8m1oQ= -define-properties@^1.1.2, define-properties@^1.1.3: +define-properties@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.3.tgz#cf88da6cbee26fe6db7094f61d870cbd84cee9f1" integrity sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ== @@ -1864,18 +1796,21 @@ define-properties@^1.1.2, define-properties@^1.1.3: define-property@^0.2.5: version "0.2.5" resolved "https://registry.yarnpkg.com/define-property/-/define-property-0.2.5.tgz#c35b1ef918ec3c990f9a5bc57be04aacec5c8116" + integrity sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY= dependencies: is-descriptor "^0.1.0" define-property@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/define-property/-/define-property-1.0.0.tgz#769ebaaf3f4a63aad3af9e8d304c9bbe79bfb0e6" + integrity sha1-dp66rz9KY6rTr56NMEybvnm/sOY= dependencies: is-descriptor "^1.0.0" define-property@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/define-property/-/define-property-2.0.2.tgz#d459689e8d654ba77e02a817f8710d702cb16e9d" + integrity sha512-jwK2UV4cnPpbcG7+VRARKTZPUWowwXA8bzH5NP6ud0oeAxyYPuGZUAC7hMugpCdz4BeSZl2Dl9k66CHJ/46ZYQ== dependencies: is-descriptor "^1.0.2" isobject "^3.0.1" @@ -1883,47 +1818,46 @@ define-property@^2.0.2: delayed-stream@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" - -delegates@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/delegates/-/delegates-1.0.0.tgz#84c6e159b81904fdca59a0ef44cd870d31250f9a" + integrity sha1-3zrhmayt+31ECqrgsp4icrJOxhk= detect-file@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/detect-file/-/detect-file-1.0.0.tgz#f0d66d03672a825cb1b73bdb3fe62310c8e552b7" - -detect-libc@^1.0.2: - version "1.0.3" - resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-1.0.3.tgz#fa137c4bd698edf55cd5cd02ac559f91a4c4ba9b" + integrity sha1-8NZtA2cqglyxtzvbP+YjEMjlUrc= diff@3.5.0, diff@^3.5.0: version "3.5.0" resolved "https://registry.yarnpkg.com/diff/-/diff-3.5.0.tgz#800c0dd1e0a8bfbc95835c202ad220fe317e5a12" + integrity sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA== doctrine@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.1.0.tgz#5cd01fc101621b42c4cd7f5d1a66243716d3f39d" + integrity sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw== dependencies: esutils "^2.0.2" doctrine@^3.0.0: version "3.0.0" - resolved "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz#addebead72a6574db783639dc87a121773973961" + resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-3.0.0.tgz#addebead72a6574db783639dc87a121773973961" + integrity sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w== dependencies: esutils "^2.0.2" duplexify@^3.6.0: version "3.7.1" resolved "https://registry.yarnpkg.com/duplexify/-/duplexify-3.7.1.tgz#2a4df5317f6ccfd91f86d6fd25d8d8a103b88309" + integrity sha512-07z8uv2wMyS51kKhD1KsdXJg5WQ6t93RneqRxUHnskXVtlYYkLqM0gqStQZ3pj073g687jPCHrqNfCzawLYh5g== dependencies: end-of-stream "^1.0.0" inherits "^2.0.1" readable-stream "^2.0.0" stream-shift "^1.0.0" -each-props@^1.3.0: +each-props@^1.3.2: version "1.3.2" resolved "https://registry.yarnpkg.com/each-props/-/each-props-1.3.2.tgz#ea45a414d16dd5cfa419b1a81720d5ca06892333" + integrity sha512-vV0Hem3zAGkJAyU7JSjixeU66rwdynTAa1vofCrSA5fEln+m67Az9CcnkVD776/fsN/UjIWmBDoNRS6t6G9RfA== dependencies: is-plain-object "^2.0.1" object.defaults "^1.1.0" @@ -1931,18 +1865,20 @@ each-props@^1.3.0: ecc-jsbn@~0.1.1: version "0.1.2" resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz#3a83a904e54353287874c564b7549386849a98c9" + integrity sha1-OoOpBOVDUyh4dMVkt1SThoSamMk= dependencies: jsbn "~0.1.0" safer-buffer "^2.1.0" electron-to-chromium@^1.3.719: - version "1.3.722" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.722.tgz#621657f79e7f65402e71aa3403bc941f3a4af0a0" - integrity sha512-aAsc906l0RBsVTsGTK+KirVfey9eNtxyejdkbNzkISGxb7AFna3Kf0qvsp8tMttzBt9Bz3HddtYQ+++/PZtRYA== + version "1.3.723" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.723.tgz#52769a75635342a4db29af5f1e40bd3dad02c877" + integrity sha512-L+WXyXI7c7+G1V8ANzRsPI5giiimLAUDC6Zs1ojHHPhYXb3k/iTABFmWjivEtsWrRQymjnO66/rO2ZTABGdmWg== emoji-regex@^7.0.1: version "7.0.3" - resolved "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz#933a04052860c85e83c122479c4748a8e4c72156" + resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-7.0.3.tgz#933a04052860c85e83c122479c4748a8e4c72156" + integrity sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA== emoji-regex@^8.0.0: version "8.0.0" @@ -1950,43 +1886,49 @@ emoji-regex@^8.0.0: integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== end-of-stream@^1.0.0, end-of-stream@^1.1.0: - version "1.4.1" - resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.1.tgz#ed29634d19baba463b6ce6b80a37213eab71ec43" + version "1.4.4" + resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.4.tgz#5ae64a5f45057baf3626ec14da0ca5e4b2431eb0" + integrity sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q== dependencies: once "^1.4.0" error-ex@^1.2.0: version "1.3.2" resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" + integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== dependencies: is-arrayish "^0.2.1" -es5-ext@^0.10.35, es5-ext@^0.10.46, es5-ext@^0.10.50, es5-ext@~0.10.14: - version "0.10.50" - resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.50.tgz#6d0e23a0abdb27018e5ac4fd09b412bc5517a778" +es5-ext@^0.10.35, es5-ext@^0.10.46, es5-ext@^0.10.50: + version "0.10.53" + resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.53.tgz#93c5a3acfdbef275220ad72644ad02ee18368de1" + integrity sha512-Xs2Stw6NiNHWypzRTY1MtaG/uJlwCk8kH81920ma8mvN8Xq1gsfhZvpkImLQArw8AHnv8MT2I45J3c0R8slE+Q== dependencies: es6-iterator "~2.0.3" - es6-symbol "~3.1.1" - next-tick "^1.0.0" + es6-symbol "~3.1.3" + next-tick "~1.0.0" es6-iterator@^2.0.1, es6-iterator@^2.0.3, es6-iterator@~2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/es6-iterator/-/es6-iterator-2.0.3.tgz#a7de889141a05a94b0854403b2d0a0fbfa98f3b7" + integrity sha1-p96IkUGgWpSwhUQDstCg+/qY87c= dependencies: d "1" es5-ext "^0.10.35" es6-symbol "^3.1.1" -es6-symbol@^3.1.1, es6-symbol@~3.1.1: - version "3.1.1" - resolved "https://registry.yarnpkg.com/es6-symbol/-/es6-symbol-3.1.1.tgz#bf00ef4fdab6ba1b46ecb7b629b4c7ed5715cc77" +es6-symbol@^3.1.1, es6-symbol@~3.1.3: + version "3.1.3" + resolved "https://registry.yarnpkg.com/es6-symbol/-/es6-symbol-3.1.3.tgz#bad5d3c1bcdac28269f4cb331e431c78ac705d18" + integrity sha512-NJ6Yn3FuDinBaBRWl/q5X/s4koRHBrgKAu+yGI6JCBeiu3qrcbJhwT2GeR/EXVfylRk8dpQVJoLEFhK+Mu31NA== dependencies: - d "1" - es5-ext "~0.10.14" + d "^1.0.1" + ext "^1.1.2" es6-weak-map@^2.0.1: version "2.0.3" resolved "https://registry.yarnpkg.com/es6-weak-map/-/es6-weak-map-2.0.3.tgz#b6da1f16cc2cc0d9be43e6bdbfc5e7dfcdf31d53" + integrity sha512-p5um32HOTO1kP+w7PRnB+5lQ43Z6muuMuIMffvDN8ZB4GcnjLBV6zGStpbASIMk4DCAvEaamhe2zhyCb/QXXsA== dependencies: d "1" es5-ext "^0.10.46" @@ -2001,10 +1943,12 @@ escalade@^3.1.1: escape-string-regexp@1.0.5, escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" + integrity sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ= escodegen@1.8.x: version "1.8.1" resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.8.1.tgz#5a5b53af4693110bebb0867aa3430dd3b70a1018" + integrity sha1-WltTr0aTEQvrsIZ6o0MN07cKEBg= dependencies: esprima "^2.7.1" estraverse "^1.9.1" @@ -2013,16 +1957,10 @@ escodegen@1.8.x: optionalDependencies: source-map "~0.2.0" -eslint-scope@3.7.1: - version "3.7.1" - resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-3.7.1.tgz#3d63c3edfda02e06e01a452ad88caacc7cdcb6e8" - dependencies: - esrecurse "^4.1.0" - estraverse "^4.1.1" - eslint-scope@^3.7.1: version "3.7.3" resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-3.7.3.tgz#bb507200d3d17f60247636160b4826284b108535" + integrity sha512-W+B0SvF4gamyCTmUc+uITPY0989iXVfKvhwtmJocTaYoc/3khEHmEmvfY/Gn9HA9VV75jrQECsHizkNw1b68FA== dependencies: esrecurse "^4.1.0" estraverse "^4.1.1" @@ -2042,11 +1980,7 @@ eslint-utils@^1.4.3: dependencies: eslint-visitor-keys "^1.1.0" -eslint-visitor-keys@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" - -eslint-visitor-keys@^1.1.0: +eslint-visitor-keys@^1.0.0, eslint-visitor-keys@^1.1.0: version "1.3.0" resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz#30ebd1ef7c2fdff01c3a4f151044af25fab0523e" integrity sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ== @@ -2054,6 +1988,7 @@ eslint-visitor-keys@^1.1.0: eslint@^4.0.0: version "4.19.1" resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.19.1.tgz#32d1d653e1d90408854bfb296f076ec7e186a300" + integrity sha512-bT3/1x1EbZB7phzYu7vCr1v3ONuzDtX8WjuM9c0iYxe+cq+pwcKEoQjl7zd3RpC6YOLgnSy3cTN58M2jcoPDIQ== dependencies: ajv "^5.3.0" babel-code-frame "^6.22.0" @@ -2140,6 +2075,7 @@ eslint@^6.8.0: espree@^3.5.4: version "3.5.4" resolved "https://registry.yarnpkg.com/espree/-/espree-3.5.4.tgz#b0f447187c8a8bed944b815a660bddf5deb5d1a7" + integrity sha512-yAcIQxtmMiB/jL32dzEp2enBeidsB7xWPLNiw3IIkpVds1P+h7qF9YwJq1yUNzp2OKXgAprs4F61ih66UsoD1A== dependencies: acorn "^5.5.0" acorn-jsx "^3.0.0" @@ -2156,25 +2092,21 @@ espree@^6.1.2: esprima@2.7.x, esprima@^2.7.1: version "2.7.3" resolved "https://registry.yarnpkg.com/esprima/-/esprima-2.7.3.tgz#96e3b70d5779f6ad49cd032673d1c312767ba581" + integrity sha1-luO3DVd59q1JzQMmc9HDEnZ7pYE= esprima@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" + integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== esquery@^1.0.0, esquery@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.1.tgz#406c51658b1f5991a5f9b62b1dc25b00e3e5c708" - dependencies: - estraverse "^4.0.0" - -esrecurse@^4.1.0: - version "4.2.0" - resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.2.0.tgz#fa9568d98d3823f9a41d91e902dcab9ea6e5b163" + version "1.4.0" + resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.4.0.tgz#2148ffc38b82e8c7057dfed48425b3e61f0f24a5" + integrity sha512-cCDispWt5vHHtwMY2YrAQ4ibFkAL8RbH5YGBnZBc90MolvvfkkQcJro/aZiAQUlQ3qgrYS6D6v8Gc5G5CQsc9w== dependencies: - estraverse "^4.1.0" - object-assign "^4.0.1" + estraverse "^5.1.0" -esrecurse@^4.3.0: +esrecurse@^4.1.0, esrecurse@^4.3.0: version "4.3.0" resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.3.0.tgz#7ad7964d679abb28bee72cec63758b1c5d2c9921" integrity sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag== @@ -2184,23 +2116,27 @@ esrecurse@^4.3.0: estraverse@^1.9.1: version "1.9.3" resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-1.9.3.tgz#af67f2dc922582415950926091a4005d29c9bb44" + integrity sha1-r2fy3JIlgkFZUJJgkaQAXSnJu0Q= -estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1: - version "4.2.0" - resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.2.0.tgz#0dee3fed31fcd469618ce7342099fc1afa0bdb13" +estraverse@^4.1.1: + version "4.3.0" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.3.0.tgz#398ad3f3c5a24948be7725e83d11a7de28cdbd1d" + integrity sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw== -estraverse@^5.2.0: +estraverse@^5.1.0, estraverse@^5.2.0: version "5.2.0" resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-5.2.0.tgz#307df42547e6cc7324d3cf03c155d5cdb8c53880" integrity sha512-BxbNGGNm0RyRYvUdHpIwv9IWzeM9XClbOxwoATuFdOE7ZE6wHL+HQ5T8hoPM+zHvmKzzsEqhgy0GrQ5X13afiQ== esutils@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.2.tgz#0abf4f1caa5bcb1f7a9d8acc6dea4faaa04bac9b" + version "2.0.3" + resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.3.tgz#74d2eb4de0b8da1293711910d50775b9b710ef64" + integrity sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g== execa@^0.10.0: version "0.10.0" - resolved "https://registry.npmjs.org/execa/-/execa-0.10.0.tgz#ff456a8f53f90f8eccc71a96d11bdfc7f082cb50" + resolved "https://registry.yarnpkg.com/execa/-/execa-0.10.0.tgz#ff456a8f53f90f8eccc71a96d11bdfc7f082cb50" + integrity sha512-7XOMnz8Ynx1gGo/3hyV9loYNPWM94jG3+3T3Y8tsfSstFmETmENCMU/A/zj8Lyaj1lkgEepKepvd6240tBRvlw== dependencies: cross-spawn "^6.0.0" get-stream "^3.0.0" @@ -2213,6 +2149,7 @@ execa@^0.10.0: expand-brackets@^2.1.4: version "2.1.4" resolved "https://registry.yarnpkg.com/expand-brackets/-/expand-brackets-2.1.4.tgz#b77735e315ce30f6b6eff0f83b04151a22449622" + integrity sha1-t3c14xXOMPa27/D4OwQVGiJEliI= dependencies: debug "^2.3.3" define-property "^0.2.5" @@ -2225,9 +2162,17 @@ expand-brackets@^2.1.4: expand-tilde@^2.0.0, expand-tilde@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/expand-tilde/-/expand-tilde-2.0.2.tgz#97e801aa052df02454de46b02bf621642cdc8502" + integrity sha1-l+gBqgUt8CRU3kawK/YhZCzchQI= dependencies: homedir-polyfill "^1.0.1" +ext@^1.1.2: + version "1.4.0" + resolved "https://registry.yarnpkg.com/ext/-/ext-1.4.0.tgz#89ae7a07158f79d35517882904324077e4379244" + integrity sha512-Key5NIsUxdqKg3vIsdw9dSuXpPCQ297y6wBjL30edxwPgt2E44WcWBZey/ZvUc6sERLTxKdyCu4gZFmUbk1Q7A== + dependencies: + type "^2.0.0" + extend-shallow@^1.1.2: version "1.1.4" resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-1.1.4.tgz#19d6bf94dfc09d76ba711f39b872d21ff4dd9071" @@ -2238,12 +2183,14 @@ extend-shallow@^1.1.2: extend-shallow@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-2.0.1.tgz#51af7d614ad9a9f610ea1bafbb989d6b1c56890f" + integrity sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8= dependencies: is-extendable "^0.1.0" extend-shallow@^3.0.0, extend-shallow@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-3.0.2.tgz#26a71aaf073b39fb2127172746131c2704028db8" + integrity sha1-Jqcarwc7OfshJxcnRhMcJwQCjbg= dependencies: assign-symbols "^1.0.0" is-extendable "^1.0.1" @@ -2256,14 +2203,16 @@ extend@^3.0.0, extend@~3.0.2: external-editor@^2.0.4: version "2.2.0" resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-2.2.0.tgz#045511cfd8d133f3846673d1047c154e214ad3d5" + integrity sha512-bSn6gvGxKt+b7+6TKEv1ZycHleA7aHhRHyAqJyp5pbUFuYYNIzpZnQDk7AsYckyWdEnTeAnay0aCy2aV6iTk9A== dependencies: chardet "^0.4.0" iconv-lite "^0.4.17" tmp "^0.0.33" external-editor@^3.0.3: - version "3.0.3" - resolved "https://registry.npmjs.org/external-editor/-/external-editor-3.0.3.tgz#5866db29a97826dbe4bf3afd24070ead9ea43a27" + version "3.1.0" + resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-3.1.0.tgz#cb03f740befae03ea4d283caed2741a83f335495" + integrity sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew== dependencies: chardet "^0.7.0" iconv-lite "^0.4.24" @@ -2272,6 +2221,7 @@ external-editor@^3.0.3: extglob@^2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/extglob/-/extglob-2.0.4.tgz#ad00fe4dc612a9232e8718711dc5cb5ab0285543" + integrity sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw== dependencies: array-unique "^0.3.2" define-property "^1.0.0" @@ -2282,13 +2232,20 @@ extglob@^2.0.4: snapdragon "^0.8.1" to-regex "^3.0.1" -extsprintf@1.3.0, extsprintf@^1.2.0: +extsprintf@1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz#96918440e3041a7a414f8c52e3c574eb3c3e1e05" + integrity sha1-lpGEQOMEGnpBT4xS48V06zw+HgU= + +extsprintf@^1.2.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.4.0.tgz#e2689f8f356fad62cca65a3a91c5df5f9551692f" + integrity sha1-4mifjzVvrWLMplo6kcXfX5VRaS8= fancy-log@^1.3.2: version "1.3.3" resolved "https://registry.yarnpkg.com/fancy-log/-/fancy-log-1.3.3.tgz#dbc19154f558690150a23953a0adbd035be45fc7" + integrity sha512-k9oEhlyc0FrVh25qYuSELjr8oxsCoc4/LEZfg2iJJrfEk/tZL9bCoJE47gqAvI2m/AUjluCS4+3I0eTx8n3AEw== dependencies: ansi-gray "^0.1.1" color-support "^1.1.3" @@ -2296,18 +2253,26 @@ fancy-log@^1.3.2: time-stamp "^1.0.0" fast-deep-equal@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-1.0.0.tgz#96256a3bc975595eb36d82e9929d060d893439ff" + version "1.1.0" + resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-1.1.0.tgz#c053477817c86b51daa853c81e059b733d023614" + integrity sha1-wFNHeBfIa1HaqFPIHgWbcz0CNhQ= -fast-deep-equal@^2.0.1: - version "2.0.1" - resolved "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz#7b05218ddf9667bf7f370bf7fdb2cb15fdd0aa49" +fast-deep-equal@^3.1.1: + version "3.1.3" + resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" + integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== fast-json-stable-stringify@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" + version "2.1.0" + resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz#874bf69c6f404c2b5d99c481341399fd55892633" + integrity sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw== + +fast-levenshtein@^1.0.0: + version "1.1.4" + resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-1.1.4.tgz#e6a754cc8f15e58987aa9cbd27af66fd6f4e5af9" + integrity sha1-5qdUzI8V5YmHqpy9J69m/W9OWvk= -fast-levenshtein@~2.0.4, fast-levenshtein@~2.0.6: +fast-levenshtein@~2.0.6: version "2.0.6" resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc= @@ -2315,6 +2280,7 @@ fast-levenshtein@~2.0.4, fast-levenshtein@~2.0.6: figures@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/figures/-/figures-2.0.0.tgz#3ab1a2d2a62c8bfb431a0c94cb797a2fce27c962" + integrity sha1-OrGi0qYsi/tDGgyUy3l6L84nyWI= dependencies: escape-string-regexp "^1.0.5" @@ -2328,19 +2294,27 @@ figures@^3.0.0: file-entry-cache@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-2.0.0.tgz#c392990c3e684783d838b8c84a45d8a048458361" + integrity sha1-w5KZDD5oR4PYOLjISkXYoEhFg2E= dependencies: flat-cache "^1.2.1" object-assign "^4.0.1" file-entry-cache@^5.0.1: version "5.0.1" - resolved "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-5.0.1.tgz#ca0f6efa6dd3d561333fb14515065c2fafdf439c" + resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-5.0.1.tgz#ca0f6efa6dd3d561333fb14515065c2fafdf439c" + integrity sha512-bCg29ictuBaKUwwArK4ouCaqDgLZcysCFLmM/Yn/FDoqndh/9vNuQfXRDvTuXKLxfD/JtZQGKFT8MGcJBK644g== dependencies: flat-cache "^2.0.1" +file-uri-to-path@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz#553a7b8446ff6f684359c445f1e37a05dacc33dd" + integrity sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw== + fill-range@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-4.0.0.tgz#d544811d428f98eb06a63dc402d2403c328c38f7" + integrity sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc= dependencies: extend-shallow "^2.0.1" is-number "^3.0.0" @@ -2349,7 +2323,8 @@ fill-range@^4.0.0: find-cache-dir@^2.0.0: version "2.1.0" - resolved "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-2.1.0.tgz#8d0f94cd13fe43c6c7c261a0d86115ca918c05f7" + resolved "https://registry.yarnpkg.com/find-cache-dir/-/find-cache-dir-2.1.0.tgz#8d0f94cd13fe43c6c7c261a0d86115ca918c05f7" + integrity sha512-Tq6PixE0w/VMFfCgbONnkiQIVol/JJL7nRMi20fqzA4NRs9AfeqMGeRdPi3wIhYkxjeBaWh2rxwapn5Tu3IqOQ== dependencies: commondir "^1.0.1" make-dir "^2.0.0" @@ -2358,19 +2333,22 @@ find-cache-dir@^2.0.0: find-up@^1.0.0: version "1.1.2" resolved "https://registry.yarnpkg.com/find-up/-/find-up-1.1.2.tgz#6b2e9822b1a2ce0a60ab64d610eccad53cb24d0f" + integrity sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8= dependencies: path-exists "^2.0.0" pinkie-promise "^2.0.0" find-up@^3.0.0: version "3.0.0" - resolved "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz#49169f1d7993430646da61ecc5ae355c21c97b73" + resolved "https://registry.yarnpkg.com/find-up/-/find-up-3.0.0.tgz#49169f1d7993430646da61ecc5ae355c21c97b73" + integrity sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg== dependencies: locate-path "^3.0.0" findup-sync@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/findup-sync/-/findup-sync-2.0.0.tgz#9326b1488c22d1a6088650a86901b2d9a90a2cbc" + integrity sha1-kyaxSIwi0aYIhlCoaQGy2akKLLw= dependencies: detect-file "^1.0.0" is-glob "^3.1.0" @@ -2380,6 +2358,7 @@ findup-sync@^2.0.0: findup-sync@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/findup-sync/-/findup-sync-3.0.0.tgz#17b108f9ee512dfb7a5c7f3c8b27ea9e1a9c08d1" + integrity sha512-YbffarhcicEhOrm4CtrwdKBdCuz576RLdhJDsIfvNtxUuhdRet1qZcsMjqbePtAseKdAnDyM/IyXbu7PRPRLYg== dependencies: detect-file "^1.0.0" is-glob "^4.0.0" @@ -2387,8 +2366,9 @@ findup-sync@^3.0.0: resolve-dir "^1.0.1" fined@^1.0.1: - version "1.1.0" - resolved "https://registry.yarnpkg.com/fined/-/fined-1.1.0.tgz#b37dc844b76a2f5e7081e884f7c0ae344f153476" + version "1.2.0" + resolved "https://registry.yarnpkg.com/fined/-/fined-1.2.0.tgz#d00beccf1aa2b475d16d423b0238b713a2c4a37b" + integrity sha512-ZYDqPLGxDkDhDZBjZBb+oD1+j0rA4E0pXY50eplAAOPg2N/gUBSSk5IM1/QhPfyVo19lJ+CvXpqfvk+b2p/8Ng== dependencies: expand-tilde "^2.0.2" is-plain-object "^2.0.3" @@ -2397,12 +2377,14 @@ fined@^1.0.1: parse-filepath "^1.0.1" flagged-respawn@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/flagged-respawn/-/flagged-respawn-1.0.0.tgz#4e79ae9b2eb38bf86b3bb56bf3e0a56aa5fcabd7" + version "1.0.1" + resolved "https://registry.yarnpkg.com/flagged-respawn/-/flagged-respawn-1.0.1.tgz#e7de6f1279ddd9ca9aac8a5971d618606b3aab41" + integrity sha512-lNaHNVymajmk0OJMBn8fVUAU1BtDeKIqKoVhk4xAALB57aALg6b4W0MfJ/cUE0g9YBXy5XhSlPIpYIJ7HaY/3Q== flat-cache@^1.2.1: version "1.3.4" resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-1.3.4.tgz#2c2ef77525cc2929007dfffa1dd314aa9c9dee6f" + integrity sha512-VwyB3Lkgacfik2vhqR4uv2rvebqmDvFu4jlN/C1RzWoJEo8I7z4Q404oiqYCkq41mni8EzQnm95emU9seckwtg== dependencies: circular-json "^0.3.1" graceful-fs "^4.1.2" @@ -2411,19 +2393,22 @@ flat-cache@^1.2.1: flat-cache@^2.0.1: version "2.0.1" - resolved "https://registry.npmjs.org/flat-cache/-/flat-cache-2.0.1.tgz#5d296d6f04bda44a4630a301413bdbc2ec085ec0" + resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-2.0.1.tgz#5d296d6f04bda44a4630a301413bdbc2ec085ec0" + integrity sha512-LoQe6yDuUMDzQAEH8sgmh4Md6oZnc/7PjtwjNFSzveXqSHt6ka9fPBuso7IGf9Rz4uqnSnWiFH2B/zj24a5ReA== dependencies: flatted "^2.0.0" rimraf "2.6.3" write "1.0.3" flatted@^2.0.0: - version "2.0.1" - resolved "https://registry.npmjs.org/flatted/-/flatted-2.0.1.tgz#69e57caa8f0eacbc281d2e2cb458d46fdb449e08" + version "2.0.2" + resolved "https://registry.yarnpkg.com/flatted/-/flatted-2.0.2.tgz#4575b21e2bcee7434aa9be662f4b7b5f9c2b5138" + integrity sha512-r5wGx7YeOwNWNlCA0wQ86zKyDLMQr+/RB8xy74M4hTphfmjlijTSSXGuH8rnvKZnfT9i+75zmd8jcKdMR4O6jA== flush-write-stream@^1.0.2: version "1.1.1" resolved "https://registry.yarnpkg.com/flush-write-stream/-/flush-write-stream-1.1.1.tgz#8dd7d873a1babc207d94ead0c2e0e44276ebf2e8" + integrity sha512-3Z4XhFZ3992uIq0XOqb9AreonueSYphE6oYbpt5+3u06JWklbsPkNv3ZKkP9Bz/r+1MWCaMoSQ28P85+1Yc77w== dependencies: inherits "^2.0.3" readable-stream "^2.3.6" @@ -2431,16 +2416,19 @@ flush-write-stream@^1.0.2: for-in@^1.0.1, for-in@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80" + integrity sha1-gQaNKVqBQuwKxybG4iAMMPttXoA= for-own@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/for-own/-/for-own-1.0.0.tgz#c63332f415cedc4b04dbfe70cf836494c53cb44b" + integrity sha1-xjMy9BXO3EsE2/5wz4NklMU8tEs= dependencies: for-in "^1.0.1" forever-agent@~0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" + integrity sha1-+8cfDEGt6zf5bFd60e1C2P2sypE= form-data@~2.3.2: version "2.3.3" @@ -2454,18 +2442,14 @@ form-data@~2.3.2: fragment-cache@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/fragment-cache/-/fragment-cache-0.2.1.tgz#4290fad27f13e89be7f33799c6bc5a0abfff0d19" + integrity sha1-QpD60n8T6Jvn8zeZxrxaCr//DRk= dependencies: map-cache "^0.2.2" -fs-minipass@^1.2.5: - version "1.2.6" - resolved "https://registry.yarnpkg.com/fs-minipass/-/fs-minipass-1.2.6.tgz#2c5cc30ded81282bfe8a0d7c7c1853ddeb102c07" - dependencies: - minipass "^2.2.1" - fs-mkdirp-stream@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fs-mkdirp-stream/-/fs-mkdirp-stream-1.0.0.tgz#0b7815fc3201c6a69e14db98ce098c16935259eb" + integrity sha1-C3gV/DIBxqaeFNuYzgmMFpNSWes= dependencies: graceful-fs "^4.1.11" through2 "^2.0.3" @@ -2473,34 +2457,25 @@ fs-mkdirp-stream@^1.0.0: fs.realpath@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" + integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= fsevents@^1.2.7: - version "1.2.9" - resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.2.9.tgz#3f5ed66583ccd6f400b5a00db6f7e861363e388f" + version "1.2.13" + resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.2.13.tgz#f325cb0455592428bcf11b383370ef70e3bfcc38" + integrity sha512-oWb1Z6mkHIskLzEJ/XWX0srkpkTQ7vaopMQkyaEIoq0fmtFVxOthb8cCxeT+p3ynTdkk/RZwbgG4brR5BeWECw== dependencies: + bindings "^1.5.0" nan "^2.12.1" - node-pre-gyp "^0.12.0" function-bind@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" + integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== functional-red-black-tree@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" - -gauge@~2.7.3: - version "2.7.4" - resolved "https://registry.yarnpkg.com/gauge/-/gauge-2.7.4.tgz#2c03405c7538c39d7eb37b317022e325fb018bf7" - dependencies: - aproba "^1.0.3" - console-control-strings "^1.0.0" - has-unicode "^2.0.0" - object-assign "^4.1.0" - signal-exit "^3.0.0" - string-width "^1.0.1" - strip-ansi "^3.0.1" - wide-align "^1.1.0" + integrity sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc= gensync@^1.0.0-beta.2: version "1.0.0-beta.2" @@ -2510,6 +2485,7 @@ gensync@^1.0.0-beta.2: get-caller-file@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.3.tgz#f978fa4c90d1dfe7ff2d6beda2a515e713bdcf4a" + integrity sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w== get-intrinsic@^1.0.2: version "1.1.1" @@ -2522,21 +2498,25 @@ get-intrinsic@^1.0.2: get-stream@^3.0.0: version "3.0.0" - resolved "https://registry.npmjs.org/get-stream/-/get-stream-3.0.0.tgz#8e943d1358dc37555054ecbe2edb05aa174ede14" + resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-3.0.0.tgz#8e943d1358dc37555054ecbe2edb05aa174ede14" + integrity sha1-jpQ9E1jcN1VQVOy+LtsFqhdO3hQ= get-value@^2.0.3, get-value@^2.0.6: version "2.0.6" resolved "https://registry.yarnpkg.com/get-value/-/get-value-2.0.6.tgz#dc15ca1c672387ca76bd37ac0a395ba2042a2c28" + integrity sha1-3BXKHGcjh8p2vTesCjlbogQqLCg= getpass@^0.1.1: version "0.1.7" resolved "https://registry.yarnpkg.com/getpass/-/getpass-0.1.7.tgz#5eff8e3e684d569ae4cb2b1282604e8ba62149fa" + integrity sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo= dependencies: assert-plus "^1.0.0" glob-parent@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-3.1.0.tgz#9e6af6299d8d3bd2bd40430832bd113df906c5ae" + integrity sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4= dependencies: is-glob "^3.1.0" path-dirname "^1.0.0" @@ -2551,6 +2531,7 @@ glob-parent@^5.0.0: glob-stream@^6.1.0: version "6.1.0" resolved "https://registry.yarnpkg.com/glob-stream/-/glob-stream-6.1.0.tgz#7045c99413b3eb94888d83ab46d0b404cc7bdde4" + integrity sha1-cEXJlBOz65SIjYOrRtC0BMx73eQ= dependencies: extend "^3.0.0" glob "^7.1.1" @@ -2564,19 +2545,22 @@ glob-stream@^6.1.0: unique-stream "^2.0.2" glob-watcher@^5.0.3: - version "5.0.3" - resolved "https://registry.yarnpkg.com/glob-watcher/-/glob-watcher-5.0.3.tgz#88a8abf1c4d131eb93928994bc4a593c2e5dd626" + version "5.0.5" + resolved "https://registry.yarnpkg.com/glob-watcher/-/glob-watcher-5.0.5.tgz#aa6bce648332924d9a8489be41e3e5c52d4186dc" + integrity sha512-zOZgGGEHPklZNjZQaZ9f41i7F2YwE+tS5ZHrDhbBCk3stwahn5vQxnFmBJZHoYdusR6R1bLSXeGUy/BhctwKzw== dependencies: anymatch "^2.0.0" async-done "^1.2.0" chokidar "^2.0.0" is-negated-glob "^1.0.0" just-debounce "^1.0.0" + normalize-path "^3.0.0" object.defaults "^1.1.0" glob@7.1.2: version "7.1.2" - resolved "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15" + integrity sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ== dependencies: fs.realpath "^1.0.0" inflight "^1.0.4" @@ -2588,6 +2572,7 @@ glob@7.1.2: glob@^5.0.15: version "5.0.15" resolved "https://registry.yarnpkg.com/glob/-/glob-5.0.15.tgz#1bc936b9e02f4a603fcc222ecf7633d30b8b93b1" + integrity sha1-G8k2ueAvSmA/zCIuz3Yz0wuLk7E= dependencies: inflight "^1.0.4" inherits "2" @@ -2596,8 +2581,9 @@ glob@^5.0.15: path-is-absolute "^1.0.0" glob@^7.1.1, glob@^7.1.2, glob@^7.1.3: - version "7.1.4" - resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.4.tgz#aa608a2f6c577ad357e1ae5a5c26d9a8d1969255" + version "7.1.6" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.6.tgz#141f33b81a7c2492e125594307480c46679278a6" + integrity sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA== dependencies: fs.realpath "^1.0.0" inflight "^1.0.4" @@ -2609,6 +2595,7 @@ glob@^7.1.1, glob@^7.1.2, glob@^7.1.3: global-modules@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/global-modules/-/global-modules-1.0.0.tgz#6d770f0eb523ac78164d72b5e71a8877265cc3ea" + integrity sha512-sKzpEkf11GpOFuw0Zzjzmt4B4UZwjOcG757PPvrfhxcLFbq0wpsgpOqxpxtxFiCG4DtG93M6XRVbF2oGdev7bg== dependencies: global-prefix "^1.0.1" is-windows "^1.0.1" @@ -2617,6 +2604,7 @@ global-modules@^1.0.0: global-prefix@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/global-prefix/-/global-prefix-1.0.2.tgz#dbf743c6c14992593c655568cb66ed32c0122ebe" + integrity sha1-2/dDxsFJklk8ZVVoy2btMsASLr4= dependencies: expand-tilde "^2.0.2" homedir-polyfill "^1.0.1" @@ -2627,6 +2615,7 @@ global-prefix@^1.0.1: globals@^11.0.1, globals@^11.1.0: version "11.12.0" resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" + integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== globals@^12.1.0: version "12.4.0" @@ -2636,22 +2625,26 @@ globals@^12.1.0: type-fest "^0.8.1" glogg@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/glogg/-/glogg-1.0.0.tgz#7fe0f199f57ac906cf512feead8f90ee4a284fc5" + version "1.0.2" + resolved "https://registry.yarnpkg.com/glogg/-/glogg-1.0.2.tgz#2d7dd702beda22eb3bffadf880696da6d846313f" + integrity sha512-5mwUoSuBk44Y4EshyiqcH95ZntbDdTQqA3QYSrxmzj28Ai0vXBGMH1ApSANH14j2sIRtqCEyg6PfsuP7ElOEDA== dependencies: sparkles "^1.0.0" graceful-fs@^4.0.0, graceful-fs@^4.1.11, graceful-fs@^4.1.2, graceful-fs@^4.1.6: - version "4.2.0" - resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.0.tgz#8d8fdc73977cb04104721cb53666c1ca64cd328b" + version "4.2.6" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.6.tgz#ff040b2b0853b23c3d31027523706f1885d76bee" + integrity sha512-nTnJ528pbqxYanhpDYsi4Rd8MAeaBA67+RZ10CM1m3bTAVFEDcd5AuA4a6W5YkGZ1iNXHzZz8T6TBKLeBuNriQ== growl@1.10.5: version "1.10.5" - resolved "https://registry.npmjs.org/growl/-/growl-1.10.5.tgz#f2735dc2283674fa67478b10181059355c369e5e" + resolved "https://registry.yarnpkg.com/growl/-/growl-1.10.5.tgz#f2735dc2283674fa67478b10181059355c369e5e" + integrity sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA== gulp-babel@^8.0.0: version "8.0.0" resolved "https://registry.yarnpkg.com/gulp-babel/-/gulp-babel-8.0.0.tgz#e0da96f4f2ec4a88dd3a3030f476e38ab2126d87" + integrity sha512-oomaIqDXxFkg7lbpBou/gnUkX51/Y/M2ZfSjL2hdqXTAlSWZcgZtd2o0cOH0r/eE8LWD0+Q/PsLsr2DKOoqToQ== dependencies: plugin-error "^1.0.1" replace-ext "^1.0.0" @@ -2659,8 +2652,9 @@ gulp-babel@^8.0.0: vinyl-sourcemaps-apply "^0.2.0" gulp-cli@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/gulp-cli/-/gulp-cli-2.2.0.tgz#5533126eeb7fe415a7e3e84a297d334d5cf70ebc" + version "2.3.0" + resolved "https://registry.yarnpkg.com/gulp-cli/-/gulp-cli-2.3.0.tgz#ec0d380e29e52aa45e47977f0d32e18fd161122f" + integrity sha512-zzGBl5fHo0EKSXsHzjspp3y5CONegCm8ErO5Qh0UzFzk2y4tMvzLWhoDokADbarfZRL2pGpRp7yt6gfJX4ph7A== dependencies: ansi-colors "^1.0.1" archy "^1.0.0" @@ -2670,7 +2664,7 @@ gulp-cli@^2.2.0: copy-props "^2.0.1" fancy-log "^1.3.2" gulplog "^1.0.0" - interpret "^1.1.0" + interpret "^1.4.0" isobject "^3.0.1" liftoff "^3.1.0" matchdep "^2.0.0" @@ -2678,12 +2672,13 @@ gulp-cli@^2.2.0: pretty-hrtime "^1.0.0" replace-homedir "^1.0.0" semver-greatest-satisfied-range "^1.1.0" - v8flags "^3.0.1" + v8flags "^3.2.0" yargs "^7.1.0" gulp-eslint@4.0.2: version "4.0.2" resolved "https://registry.yarnpkg.com/gulp-eslint/-/gulp-eslint-4.0.2.tgz#18a2a6768e4404cbf3e203239cb57474168fa606" + integrity sha512-fcFUQzFsN6dJ6KZlG+qPOEkqfcevRUXgztkYCvhNvJeSvOicC8ucutN4qR/ID8LmNZx9YPIkBzazTNnVvbh8wg== dependencies: eslint "^4.0.0" fancy-log "^1.3.2" @@ -2692,12 +2687,14 @@ gulp-eslint@4.0.2: gulp-exclude-gitignore@^1.0.0: version "1.2.0" resolved "https://registry.yarnpkg.com/gulp-exclude-gitignore/-/gulp-exclude-gitignore-1.2.0.tgz#341aeb62faab428af5550da9359ceff99388f1d0" + integrity sha512-J3LCmz9C1UU1pxf5Npx6SNc5o9YQptyc9IHaqLiBlihZmg44jaaTplWUZ0JPQkMdOTae0YgEDvT9TKlUWDSMUA== dependencies: gulp-ignore "^2.0.2" gulp-ignore@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/gulp-ignore/-/gulp-ignore-2.0.2.tgz#5c2ea2a0a4402e0ab4a2bcd12efd9295344d78f2" + integrity sha1-XC6ioKRALgq0orzRLv2SlTRNePI= dependencies: gulp-match "^1.0.3" through2 "^2.0.1" @@ -2715,14 +2712,16 @@ gulp-istanbul@^1.1.3: vinyl-sourcemaps-apply "^0.2.1" gulp-match@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/gulp-match/-/gulp-match-1.0.3.tgz#91c7c0d7f29becd6606d57d80a7f8776a87aba8e" + version "1.1.0" + resolved "https://registry.yarnpkg.com/gulp-match/-/gulp-match-1.1.0.tgz#552b7080fc006ee752c90563f9fec9d61aafdf4f" + integrity sha512-DlyVxa1Gj24DitY2OjEsS+X6tDpretuxD6wTfhXE/Rw2hweqc1f6D/XtsJmoiCwLWfXgR87W9ozEityPCVzGtQ== dependencies: minimatch "^3.0.3" gulp-mocha@^6.0.0: version "6.0.0" - resolved "https://registry.npmjs.org/gulp-mocha/-/gulp-mocha-6.0.0.tgz#80f32bc705ce30747f355ddb8ccd96a1c73bef13" + resolved "https://registry.yarnpkg.com/gulp-mocha/-/gulp-mocha-6.0.0.tgz#80f32bc705ce30747f355ddb8ccd96a1c73bef13" + integrity sha512-FfBldW5ttnDpKf4Sg6/BLOOKCCbr5mbixDGK1t02/8oSrTCwNhgN/mdszG3cuQuYNzuouUdw4EH/mlYtgUscPg== dependencies: dargs "^5.1.0" execa "^0.10.0" @@ -2745,6 +2744,7 @@ gulp-plumber@^1.2.1: gulp@^4.0.2: version "4.0.2" resolved "https://registry.yarnpkg.com/gulp/-/gulp-4.0.2.tgz#543651070fd0f6ab0a0650c6a3e6ff5a7cb09caa" + integrity sha512-dvEs27SCZt2ibF29xYgmnwwCYZxdxhQ/+LFWlbAW8y7jt68L/65402Lz3+CKy0Ov4rOs+NERmDq7YlZaDqUIfA== dependencies: glob-watcher "^5.0.3" gulp-cli "^2.2.0" @@ -2754,13 +2754,14 @@ gulp@^4.0.2: gulplog@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/gulplog/-/gulplog-1.0.0.tgz#e28c4d45d05ecbbed818363ce8f9c5926229ffe5" + integrity sha1-4oxNRdBey77YGDY86PnFkmIp/+U= dependencies: glogg "^1.0.0" handlebars@^4.0.1: - version "4.7.6" - resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.7.6.tgz#d4c05c1baf90e9945f77aa68a7a219aa4a7df74e" - integrity sha512-1f2BACcBfiwAfStCKZNrUCgqNZkGsAT7UM3kkYtXuLo0KnaVfjKOyf7PRzB6++aK9STyT1Pd2ZCPe3EGOXleXA== + version "4.7.7" + resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.7.7.tgz#9ce33416aad02dbd6c8fafa8240d5d98004945a1" + integrity sha512-aAcXm5OAfE/8IXkcZvCepKU3VzW1/39Fb5ZuqMtgI/hT8X2YgoMvBY5dLhq/cpOvw7Lk1nK/UF71aLG/ZnVYRA== dependencies: minimist "^1.2.5" neo-async "^2.6.0" @@ -2772,50 +2773,47 @@ handlebars@^4.0.1: har-schema@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" + integrity sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI= -har-validator@~5.1.0: - version "5.1.3" - resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.1.3.tgz#1ef89ebd3e4996557675eed9893110dc350fa080" - integrity sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g== +har-validator@~5.1.3: + version "5.1.5" + resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.1.5.tgz#1f0803b9f8cb20c0fa13822df1ecddb36bde1efd" + integrity sha512-nmT2T0lljbxdQZfspsno9hgrG3Uir6Ks5afism62poxqBM6sDnMEuPmzTq8XN0OEwqKLLdh1jQI3qyE66Nzb3w== dependencies: - ajv "^6.5.5" + ajv "^6.12.3" har-schema "^2.0.0" has-ansi@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/has-ansi/-/has-ansi-2.0.0.tgz#34f5049ce1ecdf2b0649af3ef24e45ed35416d91" + integrity sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE= dependencies: ansi-regex "^2.0.0" has-flag@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-1.0.0.tgz#9d9e793165ce017a00f00418c43f942a7b1d11fa" + integrity sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo= has-flag@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" + integrity sha1-tdRU3CGZriJWmfNGfloH87lVuv0= has-flag@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== -has-symbols@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.0.tgz#ba1a8f1af2a0fc39650f5c850367704122063b44" - has-symbols@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.2.tgz#165d3070c00309752a1236a479331e3ac56f1423" integrity sha512-chXa79rL/UC2KlX17jo3vRGz0azaWEx5tGqZg5pO3NUyEJVB17dMruQlzCCOfUvElghKcm5194+BCRvi2Rv/Gw== -has-unicode@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/has-unicode/-/has-unicode-2.0.1.tgz#e0e6fe6a28cf51138855e086d1691e771de2a8b9" - has-value@^0.3.1: version "0.3.1" resolved "https://registry.yarnpkg.com/has-value/-/has-value-0.3.1.tgz#7b1f58bada62ca827ec0a2078025654845995e1f" + integrity sha1-ex9YutpiyoJ+wKIHgCVlSEWZXh8= dependencies: get-value "^2.0.3" has-values "^0.1.4" @@ -2824,6 +2822,7 @@ has-value@^0.3.1: has-value@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/has-value/-/has-value-1.0.0.tgz#18b281da585b1c5c51def24c930ed29a0be6b177" + integrity sha1-GLKB2lhbHFxR3vJMkw7SmgvmsXc= dependencies: get-value "^2.0.6" has-values "^1.0.0" @@ -2832,10 +2831,12 @@ has-value@^1.0.0: has-values@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/has-values/-/has-values-0.1.4.tgz#6d61de95d91dfca9b9a02089ad384bff8f62b771" + integrity sha1-bWHeldkd/Km5oCCJrThL/49it3E= has-values@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/has-values/-/has-values-1.0.0.tgz#95b0b63fec2146619a6fe57fe75628d5a39efe4f" + integrity sha1-lbC2P+whRmGab+V/51Yo1aOe/k8= dependencies: is-number "^3.0.0" kind-of "^4.0.0" @@ -2849,53 +2850,56 @@ has@^1.0.3: he@1.1.1: version "1.1.1" - resolved "https://registry.npmjs.org/he/-/he-1.1.1.tgz#93410fd21b009735151f8868c2f271f3427e23fd" + resolved "https://registry.yarnpkg.com/he/-/he-1.1.1.tgz#93410fd21b009735151f8868c2f271f3427e23fd" + integrity sha1-k0EP0hsAlzUVH4howvJx80J+I/0= homedir-polyfill@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/homedir-polyfill/-/homedir-polyfill-1.0.1.tgz#4c2bbc8a758998feebf5ed68580f76d46768b4bc" + version "1.0.3" + resolved "https://registry.yarnpkg.com/homedir-polyfill/-/homedir-polyfill-1.0.3.tgz#743298cef4e5af3e194161fbadcc2151d3a058e8" + integrity sha512-eSmmWE5bZTK2Nou4g0AI3zZ9rswp7GRKoKXS1BLUkvPviOqs4YTN1djQIqrXy9k5gEtdLPy86JjRwsNM9tnDcA== dependencies: parse-passwd "^1.0.0" hosted-git-info@^2.1.4: - version "2.7.1" - resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.7.1.tgz#97f236977bd6e125408930ff6de3eec6281ec047" + version "2.8.9" + resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.8.9.tgz#dffc0bf9a21c02209090f2aa69429e1414daf3f9" + integrity sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw== htmlencode@^0.0.4: version "0.0.4" resolved "https://registry.yarnpkg.com/htmlencode/-/htmlencode-0.0.4.tgz#f7e2d6afbe18a87a78e63ba3308e753766740e3f" + integrity sha1-9+LWr74YqHp45jujMI51N2Z0Dj8= http-signature@~1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/http-signature/-/http-signature-1.2.0.tgz#9aecd925114772f3d95b65a60abb8f7c18fbace1" + integrity sha1-muzZJRFHcvPZW2WmCruPfBj7rOE= dependencies: assert-plus "^1.0.0" jsprim "^1.2.2" sshpk "^1.7.0" -iconv-lite@^0.4.17, iconv-lite@^0.4.24, iconv-lite@^0.4.4: +iconv-lite@^0.4.17, iconv-lite@^0.4.24: version "0.4.24" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" + integrity sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA== dependencies: safer-buffer ">= 2.1.2 < 3" -ignore-walk@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/ignore-walk/-/ignore-walk-3.0.1.tgz#a83e62e7d272ac0e3b551aaa82831a19b69f82f8" - dependencies: - minimatch "^3.0.4" - ignore@^3.3.3: version "3.3.10" resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.10.tgz#0a97fb876986e8081c631160f8f9f389157f0043" + integrity sha512-Pgs951kaMm5GXP7MOvxERINe3gsaVjUWFm+UZPSq9xYriQAksyhg0csnS0KXSNRD5NmNdapXEpjxG49+AKh/ug== ignore@^4.0.6: version "4.0.6" - resolved "https://registry.npmjs.org/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc" + integrity sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg== import-fresh@^3.0.0: - version "3.1.0" - resolved "https://registry.npmjs.org/import-fresh/-/import-fresh-3.1.0.tgz#6d33fa1dcef6df930fae003446f33415af905118" + version "3.3.0" + resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.3.0.tgz#37162c25fcb9ebaa2e6e53d5b4d88ce17d9e0c2b" + integrity sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw== dependencies: parent-module "^1.0.0" resolve-from "^4.0.0" @@ -2903,29 +2907,30 @@ import-fresh@^3.0.0: imurmurhash@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" + integrity sha1-khi5srkoojixPcT7a21XbyMUU+o= inflight@^1.0.4: version "1.0.6" resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" + integrity sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk= dependencies: once "^1.3.0" wrappy "1" -inherits@2, inherits@^2.0.3, inherits@~2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de" - -inherits@^2.0.1: +inherits@2, inherits@^2.0.1, inherits@^2.0.3, inherits@~2.0.3: version "2.0.4" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" + integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== -ini@^1.3.4, ini@~1.3.0: - version "1.3.5" - resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.5.tgz#eee25f56db1c9ec6085e0c22778083f596abf927" +ini@^1.3.4: + version "1.3.8" + resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.8.tgz#a29da425b48806f34767a4efce397269af28432c" + integrity sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew== inquirer@^3.0.6: version "3.3.0" resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-3.3.0.tgz#9dd2f2ad765dcab1ff0443b491442a20ba227dc9" + integrity sha512-h+xtnyk4EwKvFWHrUYsWErEVR+igKtLdchu+o0Z1RL7VU/jVMFbYir2bp6bAj8efFNxWqHX0dIss6fJQ+/+qeQ== dependencies: ansi-escapes "^3.0.0" chalk "^2.0.0" @@ -2961,17 +2966,20 @@ inquirer@^7.0.0: strip-ansi "^6.0.0" through "^2.3.6" -interpret@^1.1.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.2.0.tgz#d5061a6224be58e8083985f5014d844359576296" +interpret@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.4.0.tgz#665ab8bc4da27a774a40584e812e3e0fa45b1a1e" + integrity sha512-agE4QfB2Lkp9uICn7BAqoscw4SZP9kTE2hxiFI3jBPmXJfdqiahTbUuKGsMoN2GtqL9AxhYioAcVvgsb1HvRbA== invert-kv@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-1.0.0.tgz#104a8e4aaca6d3d8cd157a8ef8bfab2d7a3ffdb6" + integrity sha1-EEqOSqym09jNFXqO+L+rLXo//bY= is-absolute@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-absolute/-/is-absolute-1.0.0.tgz#395e1ae84b11f26ad1795e73c17378e48a301576" + integrity sha512-dOWoqflvcydARa360Gvv18DZ/gRuHKi2NU/wU5X1ZFzdYfH29nkiNZsF3mp4OJ3H4yo9Mx8A/uAGNzpzPN3yBA== dependencies: is-relative "^1.0.0" is-windows "^1.0.1" @@ -2979,28 +2987,33 @@ is-absolute@^1.0.0: is-accessor-descriptor@^0.1.6: version "0.1.6" resolved "https://registry.yarnpkg.com/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz#a9e12cb3ae8d876727eeef3843f8a0897b5c98d6" + integrity sha1-qeEss66Nh2cn7u84Q/igiXtcmNY= dependencies: kind-of "^3.0.2" is-accessor-descriptor@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz#169c2f6d3df1f992618072365c9b0ea1f6878656" + integrity sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ== dependencies: kind-of "^6.0.0" is-arrayish@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" + integrity sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0= is-binary-path@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/is-binary-path/-/is-binary-path-1.0.1.tgz#75f16642b480f187a711c814161fd3a4a7655898" + integrity sha1-dfFmQrSA8YenEcgUFh/TpKdlWJg= dependencies: binary-extensions "^1.0.0" is-buffer@^1.1.5: - version "1.1.5" - resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.5.tgz#1f3b26ef613b214b88cbca23cc6c01d87961eecc" + version "1.1.6" + resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.6.tgz#efaa2ea9daa0d7ab2ea13a97b2b8ad51fefbe8be" + integrity sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w== is-core-module@^2.2.0: version "2.3.0" @@ -3012,18 +3025,21 @@ is-core-module@^2.2.0: is-data-descriptor@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz#0b5ee648388e2c860282e793f1856fec3f301b56" + integrity sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y= dependencies: kind-of "^3.0.2" is-data-descriptor@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz#d84876321d0e7add03990406abbbbd36ba9268c7" + integrity sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ== dependencies: kind-of "^6.0.0" is-descriptor@^0.1.0: version "0.1.6" resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-0.1.6.tgz#366d8240dde487ca51823b1ab9f07a10a78251ca" + integrity sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg== dependencies: is-accessor-descriptor "^0.1.6" is-data-descriptor "^0.1.4" @@ -3032,6 +3048,7 @@ is-descriptor@^0.1.0: is-descriptor@^1.0.0, is-descriptor@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-1.0.2.tgz#3b159746a66604b04f8c81524ba365c5f14d86ec" + integrity sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg== dependencies: is-accessor-descriptor "^1.0.0" is-data-descriptor "^1.0.0" @@ -3040,26 +3057,31 @@ is-descriptor@^1.0.0, is-descriptor@^1.0.2: is-extendable@^0.1.0, is-extendable@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/is-extendable/-/is-extendable-0.1.1.tgz#62b110e289a471418e3ec36a617d472e301dfc89" + integrity sha1-YrEQ4omkcUGOPsNqYX1HLjAd/Ik= is-extendable@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/is-extendable/-/is-extendable-1.0.1.tgz#a7470f9e426733d81bd81e1155264e3a3507cab4" + integrity sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA== dependencies: is-plain-object "^2.0.4" is-extglob@^2.1.0, is-extglob@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" + integrity sha1-qIwCU1eR8C7TfHahueqXc8gz+MI= is-fullwidth-code-point@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz#ef9e31386f031a7f0d643af82fde50c457ef00cb" + integrity sha1-754xOG8DGn8NZDr4L95QxFfvAMs= dependencies: number-is-nan "^1.0.0" is-fullwidth-code-point@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" + integrity sha1-o7MKXE8ZkYMWeqq5O+764937ZU8= is-fullwidth-code-point@^3.0.0: version "3.0.0" @@ -3069,106 +3091,121 @@ is-fullwidth-code-point@^3.0.0: is-glob@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-3.1.0.tgz#7ba5ae24217804ac70707b96922567486cc3e84a" + integrity sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo= dependencies: is-extglob "^2.1.0" is-glob@^4.0.0, is-glob@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.1.tgz#7567dbe9f2f5e2467bc77ab83c4a29482407a5dc" + integrity sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg== dependencies: is-extglob "^2.1.1" is-negated-glob@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-negated-glob/-/is-negated-glob-1.0.0.tgz#6910bca5da8c95e784b5751b976cf5a10fee36d2" + integrity sha1-aRC8pdqMleeEtXUbl2z1oQ/uNtI= is-number@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/is-number/-/is-number-3.0.0.tgz#24fd6201a4782cf50561c810276afc7d12d71195" + integrity sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU= dependencies: kind-of "^3.0.2" is-number@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/is-number/-/is-number-4.0.0.tgz#0026e37f5454d73e356dfe6564699867c6a7f0ff" - -is-odd@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/is-odd/-/is-odd-2.0.0.tgz#7646624671fd7ea558ccd9a2795182f2958f1b24" - dependencies: - is-number "^4.0.0" + integrity sha512-rSklcAIlf1OmFdyAqbnWTLVelsQ58uvZ66S/ZyawjWqIviTWCjg2PzVGw8WUA+nNuPTqb4wgA+NszrJ+08LlgQ== is-plain-object@^2.0.1, is-plain-object@^2.0.3, is-plain-object@^2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/is-plain-object/-/is-plain-object-2.0.4.tgz#2c163b3fafb1b606d9d17928f05c2a1c38e07677" + integrity sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og== dependencies: isobject "^3.0.1" -is-promise@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.1.0.tgz#79a2a9ece7f096e80f36d2b2f3bc16c1ff4bf3fa" +is-plain-object@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/is-plain-object/-/is-plain-object-5.0.0.tgz#4427f50ab3429e9025ea7d52e9043a9ef4159344" + integrity sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q== is-relative@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-relative/-/is-relative-1.0.0.tgz#a1bb6935ce8c5dba1e8b9754b9b2dcc020e2260d" + integrity sha512-Kw/ReK0iqwKeu0MITLFuj0jbPAmEiOsIwyIXvvbfa6QfmN9pkD1M+8pdk7Rl/dTKbH34/XBFMbgD4iMJhLQbGA== dependencies: is-unc-path "^1.0.0" is-resolvable@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-resolvable/-/is-resolvable-1.1.0.tgz#fb18f87ce1feb925169c9a407c19318a3206ed88" + integrity sha512-qgDYXFSR5WvEfuS5dMj6oTMEbrrSaM0CrFk2Yiq/gXnBvD9pMa2jGXxyhGLfvhZpuMZe18CJpFxAt3CRs42NMg== is-stream@^1.1.0: version "1.1.0" - resolved "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44" + resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44" + integrity sha1-EtSj3U5o4Lec6428hBc66A2RykQ= is-typedarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" + integrity sha1-5HnICFjfDBsR3dppQPlgEfzaSpo= is-unc-path@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-unc-path/-/is-unc-path-1.0.0.tgz#d731e8898ed090a12c352ad2eaed5095ad322c9d" + integrity sha512-mrGpVd0fs7WWLfVsStvgF6iEJnbjDFZh9/emhRDcGWTduTfNHd9CHeUwH3gYIjdbwo4On6hunkztwOaAw0yllQ== dependencies: unc-path-regex "^0.1.2" is-utf8@^0.2.0, is-utf8@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/is-utf8/-/is-utf8-0.2.1.tgz#4b0da1442104d1b336340e80797e865cf39f7d72" + integrity sha1-Sw2hRCEE0bM2NA6AeX6GXPOffXI= is-valid-glob@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-valid-glob/-/is-valid-glob-1.0.0.tgz#29bf3eff701be2d4d315dbacc39bc39fe8f601aa" + integrity sha1-Kb8+/3Ab4tTTFdusw5vDn+j2Aao= is-windows@^1.0.1, is-windows@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/is-windows/-/is-windows-1.0.2.tgz#d1850eb9791ecd18e6182ce12a30f396634bb19d" + integrity sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA== isarray@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/isarray/-/isarray-0.0.1.tgz#8a18acfca9a8f4177e09abfc6038939b05d1eedf" + integrity sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8= isarray@1.0.0, isarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" + integrity sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE= isexe@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" + integrity sha1-6PvzdNxVb/iUehDcsFctYz8s+hA= isobject@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/isobject/-/isobject-2.1.0.tgz#f065561096a3f1da2ef46272f815c840d87e0c89" + integrity sha1-8GVWEJaj8dou9GJy+BXIQNh+DIk= dependencies: isarray "1.0.0" isobject@^3.0.0, isobject@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/isobject/-/isobject-3.0.1.tgz#4e431e92b11a9731636aa1f9c8d1ccbcfdab78df" + integrity sha1-TkMekrEalzFjaqH5yNHMvP2reN8= isstream@~0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" + integrity sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo= istanbul-threshold-checker@^0.2.1: version "0.2.1" @@ -3181,6 +3218,7 @@ istanbul-threshold-checker@^0.2.1: istanbul@^0.4.0, istanbul@~0.4.5: version "0.4.5" resolved "https://registry.yarnpkg.com/istanbul/-/istanbul-0.4.5.tgz#65c7d73d4c4da84d4f3ac310b918fb0b8033733b" + integrity sha1-ZcfXPUxNqE1POsMQuRj7C4Azczs= dependencies: abbrev "1.0.x" async "1.x" @@ -3200,14 +3238,17 @@ istanbul@^0.4.0, istanbul@~0.4.5: js-tokens@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b" + integrity sha1-mGbfOVECEw449/mWvOtlRDIJwls= js-tokens@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" + integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== js-yaml@3.x, js-yaml@^3.13.1, js-yaml@^3.9.1: - version "3.13.1" - resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.13.1.tgz#aff151b30bfdfa8e49e05da22e7415e9dfa37847" + version "3.14.1" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.14.1.tgz#dae812fdb3825fa306609a8717383c50c36a0537" + integrity sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g== dependencies: argparse "^1.0.7" esprima "^4.0.0" @@ -3215,34 +3256,42 @@ js-yaml@3.x, js-yaml@^3.13.1, js-yaml@^3.9.1: jsbn@~0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513" + integrity sha1-peZUwuWi3rXyAdls77yoDA7y9RM= jsesc@^2.5.1: version "2.5.2" resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.2.tgz#80564d2e483dacf6e8ef209650a67df3f0c283a4" + integrity sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA== jsesc@~0.5.0: version "0.5.0" resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-0.5.0.tgz#e7dee66e35d6fc16f710fe91d5cf69f70f08911d" + integrity sha1-597mbjXW/Bb3EP6R1c9p9w8IkR0= json-schema-traverse@^0.3.0: version "0.3.1" resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz#349a6d44c53a51de89b40805c5d5e59b417d3340" + integrity sha1-NJptRMU6Ud6JtAgFxdXlm0F9M0A= json-schema-traverse@^0.4.1: version "0.4.1" - resolved "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" + resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" + integrity sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg== json-schema@0.2.3: version "0.2.3" resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" + integrity sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM= json-stable-stringify-without-jsonify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" + integrity sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE= json-stringify-safe@^5.0.1, json-stringify-safe@~5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" + integrity sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus= json5@^2.1.2: version "2.2.0" @@ -3254,6 +3303,7 @@ json5@^2.1.2: jsprim@^1.2.2: version "1.4.1" resolved "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.1.tgz#313e66bc1e5cc06e438bc1b7499c2e5c56acb6a2" + integrity sha1-MT5mvB5cwG5Di8G3SZwuXFastqI= dependencies: assert-plus "1.0.0" extsprintf "1.3.0" @@ -3261,13 +3311,14 @@ jsprim@^1.2.2: verror "1.10.0" just-debounce@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/just-debounce/-/just-debounce-1.0.0.tgz#87fccfaeffc0b68cd19d55f6722943f929ea35ea" + version "1.1.0" + resolved "https://registry.yarnpkg.com/just-debounce/-/just-debounce-1.1.0.tgz#2f81a3ad4121a76bc7cb45dbf704c0d76a8e5ddf" + integrity sha512-qpcRocdkUmf+UTNBYx5w6dexX5J31AKK1OmPwH630a83DdVVUIngk55RSAiIGpQyoH0dlr872VHfPjnQnK1qDQ== just-extend@^4.0.2: - version "4.0.2" - resolved "https://registry.yarnpkg.com/just-extend/-/just-extend-4.0.2.tgz#f3f47f7dfca0f989c55410a7ebc8854b07108afc" - integrity sha512-FrLwOgm+iXrPV+5zDU6Jqu4gCRXbWEQg2O3SKONsWE4w7AXFRkryS53bpWdaL9cNol+AmR3AEYz6kn+o0fCPnw== + version "4.2.1" + resolved "https://registry.yarnpkg.com/just-extend/-/just-extend-4.2.1.tgz#ef5e589afb61e5d66b24eca749409a8939a8c744" + integrity sha512-g3UB796vUFIY90VIv/WX3L2c8CS2MdWUww3CNrYmqza1Fg0DURc2K/O4YrnklBdQarSJ/y8JnJYDGc+1iumQjg== kind-of@^1.1.0: version "1.1.0" @@ -3277,26 +3328,31 @@ kind-of@^1.1.0: kind-of@^3.0.2, kind-of@^3.0.3, kind-of@^3.2.0: version "3.2.2" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-3.2.2.tgz#31ea21a734bab9bbb0f32466d893aea51e4a3c64" + integrity sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ= dependencies: is-buffer "^1.1.5" kind-of@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-4.0.0.tgz#20813df3d712928b207378691a45066fae72dd57" + integrity sha1-IIE989cSkosgc3hpGkUGb65y3Vc= dependencies: is-buffer "^1.1.5" kind-of@^5.0.0, kind-of@^5.0.2: version "5.1.0" resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-5.1.0.tgz#729c91e2d857b7a419a1f9aa65685c4c33f5845d" + integrity sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw== kind-of@^6.0.0, kind-of@^6.0.2: - version "6.0.2" - resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.2.tgz#01146b36a6218e64e58f3a8d66de5d7fc6f6d051" + version "6.0.3" + resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.3.tgz#07c05034a6c349fa06e24fa35aa76db4580ce4dd" + integrity sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw== last-run@^1.1.0: version "1.1.1" resolved "https://registry.yarnpkg.com/last-run/-/last-run-1.1.1.tgz#45b96942c17b1c79c772198259ba943bebf8ca5b" + integrity sha1-RblpQsF7HHnHchmCWbqUO+v4yls= dependencies: default-resolution "^2.0.0" es6-weak-map "^2.0.1" @@ -3304,24 +3360,28 @@ last-run@^1.1.0: lazystream@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/lazystream/-/lazystream-1.0.0.tgz#f6995fe0f820392f61396be89462407bb77168e4" + integrity sha1-9plf4PggOS9hOWvolGJAe7dxaOQ= dependencies: readable-stream "^2.0.5" lcid@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/lcid/-/lcid-1.0.0.tgz#308accafa0bc483a3867b4b6f2b9506251d1b835" + integrity sha1-MIrMr6C8SDo4Z7S28rlQYlHRuDU= dependencies: invert-kv "^1.0.0" lead@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/lead/-/lead-1.0.0.tgz#6f14f99a37be3a9dd784f5495690e5903466ee42" + integrity sha1-bxT5mje+Op3XhPVJVpDlkDRm7kI= dependencies: flush-write-stream "^1.0.2" levn@^0.3.0, levn@~0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/levn/-/levn-0.3.0.tgz#3b09924edf9f083c0490fdd4c0bc4421e04764ee" + integrity sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4= dependencies: prelude-ls "~1.1.2" type-check "~0.3.2" @@ -3329,6 +3389,7 @@ levn@^0.3.0, levn@~0.3.0: liftoff@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/liftoff/-/liftoff-3.1.0.tgz#c9ba6081f908670607ee79062d700df062c52ed3" + integrity sha512-DlIPlJUkCV0Ips2zf2pJP0unEoT1kwYhiiPUGF3s/jtxTCjziNLoiVVh+jqWOWeFi6mmwQ5fNxvAUyPad4Dfog== dependencies: extend "^3.0.0" findup-sync "^3.0.0" @@ -3342,6 +3403,7 @@ liftoff@^3.1.0: load-json-file@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-1.1.0.tgz#956905708d58b4bab4c2261b04f59f31c99374c0" + integrity sha1-lWkFcI1YtLq0wiYbBPWfMcmTdMA= dependencies: graceful-fs "^4.1.2" parse-json "^2.2.0" @@ -3351,7 +3413,8 @@ load-json-file@^1.0.0: locate-path@^3.0.0: version "3.0.0" - resolved "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz#dbec3b3ab759758071b58fe59fc41871af21400e" + resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-3.0.0.tgz#dbec3b3ab759758071b58fe59fc41871af21400e" + integrity sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A== dependencies: p-locate "^3.0.0" path-exists "^3.0.0" @@ -3361,43 +3424,40 @@ lodash.debounce@^4.0.8: resolved "https://registry.yarnpkg.com/lodash.debounce/-/lodash.debounce-4.0.8.tgz#82d79bff30a67c4005ffd5e2515300ad9ca4d7af" integrity sha1-gteb/zCmfEAF/9XiUVMArZyk168= -lodash@^3.10.1: - version "3.10.1" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.10.1.tgz#5bf45e8e49ba4189e17d482789dfd15bd140b7b6" - -lodash@^4.0.0, lodash@^4.17.4: - version "4.17.4" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.4.tgz#78203a4d1c328ae1d86dca6460e369b57f4055ae" - -lodash@^4.17.11, lodash@^4.3.0: - version "4.17.11" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.11.tgz#b39ea6229ef607ecd89e2c8df12536891cac9b8d" +lodash.set@^4.3.2: + version "4.3.2" + resolved "https://registry.yarnpkg.com/lodash.set/-/lodash.set-4.3.2.tgz#d8757b1da807dde24816b0d6a84bea1a76230b23" + integrity sha1-2HV7HagH3eJIFrDWqEvqGnYjCyM= -lodash@^4.17.14, lodash@^4.17.19: +lodash@^4.0.0, lodash@^4.17.14, lodash@^4.17.15, lodash@^4.17.19, lodash@^4.17.4, lodash@^4.3.0, lodash@~4.17.2: version "4.17.21" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== -lodash@~4.17.2: - version "4.17.15" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.15.tgz#b447f6670a0455bbfeedd11392eff330ea097548" - integrity sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A== +lolex@^4.2.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/lolex/-/lolex-4.2.0.tgz#ddbd7f6213ca1ea5826901ab1222b65d714b3cd7" + integrity sha512-gKO5uExCXvSm6zbF562EvM+rd1kQDnB9AZBbiQVzf1ZmdDpxUSvpnAaVOP83N/31mRK8Ml8/VE8DMvsAZQ+7wg== -lolex@^4.0.1, lolex@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/lolex/-/lolex-4.1.0.tgz#ecdd7b86539391d8237947a3419aa8ac975f0fe1" - integrity sha512-BYxIEXiVq5lGIXeVHnsFzqa1TxN5acnKnPCdlZSpzm8viNEOhiigupA4vTQ9HEFQ6nLTQ9wQOgBknJgzUYQ9Aw== +lolex@^5.0.1: + version "5.1.2" + resolved "https://registry.yarnpkg.com/lolex/-/lolex-5.1.2.tgz#953694d098ce7c07bc5ed6d0e42bc6c0c6d5a367" + integrity sha512-h4hmjAvHTmd+25JSwrtTIuwbKdwg5NzZVRMLn9saij4SZaepCrTCxPr35H/3bjwfMJtN+t3CX8672UIkglz28A== + dependencies: + "@sinonjs/commons" "^1.7.0" lru-cache@^4.0.1: version "4.1.5" resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.5.tgz#8bbe50ea85bed59bc9e33dcab8235ee9bcf443cd" + integrity sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g== dependencies: pseudomap "^1.0.2" yallist "^2.1.2" make-dir@^2.0.0, make-dir@^2.1.0: version "2.1.0" - resolved "https://registry.npmjs.org/make-dir/-/make-dir-2.1.0.tgz#5f0310e18b8be898cc07009295a30ae41e91e6f5" + resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-2.1.0.tgz#5f0310e18b8be898cc07009295a30ae41e91e6f5" + integrity sha512-LS9X+dc8KLxXCb8dni79fLIIUA5VyZoyjSMCwTluaXA0o27cCK0bhXkpgw+sTXVpPy/lSO57ilRixqk0vDmtRA== dependencies: pify "^4.0.1" semver "^5.6.0" @@ -3405,22 +3465,26 @@ make-dir@^2.0.0, make-dir@^2.1.0: make-iterator@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/make-iterator/-/make-iterator-1.0.1.tgz#29b33f312aa8f547c4a5e490f56afcec99133ad6" + integrity sha512-pxiuXh0iVEq7VM7KMIhs5gxsfxCux2URptUQaXo4iZZJxBAzTPOLE2BumO5dbfVYq/hBJFBR/a1mFDmOx5AGmw== dependencies: kind-of "^6.0.2" map-cache@^0.2.0, map-cache@^0.2.2: version "0.2.2" resolved "https://registry.yarnpkg.com/map-cache/-/map-cache-0.2.2.tgz#c32abd0bd6525d9b051645bb4f26ac5dc98a0dbf" + integrity sha1-wyq9C9ZSXZsFFkW7TyasXcmKDb8= map-visit@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/map-visit/-/map-visit-1.0.0.tgz#ecdca8f13144e660f1b5bd41f12f3479d98dfb8f" + integrity sha1-7Nyo8TFE5mDxtb1B8S80edmN+48= dependencies: object-visit "^1.0.0" matchdep@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/matchdep/-/matchdep-2.0.0.tgz#c6f34834a0d8dbc3b37c27ee8bbcb27c7775582e" + integrity sha1-xvNINKDY28OzfCfui7yyfHd1WC4= dependencies: findup-sync "^2.0.0" micromatch "^3.0.4" @@ -3430,6 +3494,7 @@ matchdep@^2.0.0: micromatch@^3.0.4, micromatch@^3.1.10, micromatch@^3.1.4: version "3.1.10" resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-3.1.10.tgz#70859bc95c9840952f359a068a3fc49f9ecfac23" + integrity sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg== dependencies: arr-diff "^4.0.0" array-unique "^0.3.2" @@ -3445,31 +3510,22 @@ micromatch@^3.0.4, micromatch@^3.1.10, micromatch@^3.1.4: snapdragon "^0.8.1" to-regex "^3.0.2" -mime-db@1.40.0: - version "1.40.0" - resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.40.0.tgz#a65057e998db090f732a68f6c276d387d4126c32" - integrity sha512-jYdeOMPy9vnxEqFRRo6ZvTZ8d9oPb+k18PKoYNYUe2stVEBPPwsln/qWzdbmaIvnhZ9v2P+CuecK+fpUfsV2mA== - -mime-db@~1.30.0: - version "1.30.0" - resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.30.0.tgz#74c643da2dd9d6a45399963465b26d5ca7d71f01" - -mime-types@^2.1.12: - version "2.1.17" - resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.17.tgz#09d7a393f03e995a79f8af857b70a9e0ab16557a" - dependencies: - mime-db "~1.30.0" +mime-db@1.47.0: + version "1.47.0" + resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.47.0.tgz#8cb313e59965d3c05cfbf898915a267af46a335c" + integrity sha512-QBmA/G2y+IfeS4oktet3qRZ+P5kPhCKRXxXnQEudYqUaEioAU1/Lq2us3D/t1Jfo4hE9REQPrbB7K5sOczJVIw== -mime-types@~2.1.19: - version "2.1.24" - resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.24.tgz#b6f8d0b3e951efb77dedeca194cff6d16f676f81" - integrity sha512-WaFHS3MCl5fapm3oLxU4eYDw77IQM2ACcxQ9RIxfaC3ooc6PFuBMGZZsYpvoXS5D5QTWPieo1jjLdAm3TBP3cQ== +mime-types@^2.1.12, mime-types@~2.1.19: + version "2.1.30" + resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.30.tgz#6e7be8b4c479825f85ed6326695db73f9305d62d" + integrity sha512-crmjA4bLtR8m9qLpHvgxSChT+XoSlZi8J4n/aIdn3z92e/U47Z0V/yl+Wh9W046GgFVAmoNR/fmdbZYcSSIUeg== dependencies: - mime-db "1.40.0" + mime-db "1.47.0" mimic-fn@^1.0.0: version "1.2.0" resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" + integrity sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ== mimic-fn@^2.1.0: version "2.1.0" @@ -3479,47 +3535,46 @@ mimic-fn@^2.1.0: "minimatch@2 || 3", minimatch@3.0.4, minimatch@^3.0.2, minimatch@^3.0.3, minimatch@^3.0.4: version "3.0.4" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" + integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== dependencies: brace-expansion "^1.1.7" minimist@0.0.8: version "0.0.8" resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d" + integrity sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0= -minimist@^1.2.0, minimist@^1.2.5: +minimist@^1.2.5: version "1.2.5" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602" integrity sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw== -minipass@^2.2.1, minipass@^2.3.5: - version "2.3.5" - resolved "https://registry.yarnpkg.com/minipass/-/minipass-2.3.5.tgz#cacebe492022497f656b0f0f51e2682a9ed2d848" - dependencies: - safe-buffer "^5.1.2" - yallist "^3.0.0" - -minizlib@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/minizlib/-/minizlib-1.2.1.tgz#dd27ea6136243c7c880684e8672bb3a45fd9b614" - dependencies: - minipass "^2.2.1" - mixin-deep@^1.2.0: - version "1.3.1" - resolved "https://registry.yarnpkg.com/mixin-deep/-/mixin-deep-1.3.1.tgz#a49e7268dce1a0d9698e45326c5626df3543d0fe" + version "1.3.2" + resolved "https://registry.yarnpkg.com/mixin-deep/-/mixin-deep-1.3.2.tgz#1120b43dc359a785dce65b55b82e257ccf479566" + integrity sha512-WRoDn//mXBiJ1H40rqa3vH0toePwSsGb45iInWlTySa+Uu4k3tYUSxa2v1KqAiLtvlrSzaExqS1gtk96A9zvEA== dependencies: for-in "^1.0.2" is-extendable "^1.0.1" -mkdirp@0.5.1, mkdirp@0.5.x, mkdirp@^0.5.0, mkdirp@^0.5.1: +mkdirp@0.5.1: version "0.5.1" resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.1.tgz#30057438eac6cf7f8c4767f38648d6697d75c903" + integrity sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM= dependencies: minimist "0.0.8" +mkdirp@0.5.x, mkdirp@^0.5.1: + version "0.5.5" + resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.5.tgz#d91cefd62d1436ca0f41620e251288d420099def" + integrity sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ== + dependencies: + minimist "^1.2.5" + mocha@^5.2.0: version "5.2.0" - resolved "https://registry.npmjs.org/mocha/-/mocha-5.2.0.tgz#6d8ae508f59167f940f2b5b3c4a612ae50c90ae6" + resolved "https://registry.yarnpkg.com/mocha/-/mocha-5.2.0.tgz#6d8ae508f59167f940f2b5b3c4a612ae50c90ae6" + integrity sha512-2IUgKDhc3J7Uug+FxMXuqIyYzH7gJjXECKe/w43IGgQHTSj3InJi+yAA7T24L9bQMRKiUEHxEX37G5JpVUGLcQ== dependencies: browser-stdout "1.3.1" commander "2.15.1" @@ -3536,18 +3591,27 @@ mocha@^5.2.0: ms@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" + integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g= -ms@2.1.2, ms@^2.1.1: +ms@2.1.2: version "2.1.2" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" + integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== + +ms@^2.1.1: + version "2.1.3" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" + integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== mute-stdout@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/mute-stdout/-/mute-stdout-1.0.1.tgz#acb0300eb4de23a7ddeec014e3e96044b3472331" + integrity sha512-kDcwXR4PS7caBpuRYYBUz9iVixUk3anO3f5OYFiIPwK/20vCzKCHyKoulbiDY1S53zD2bxUpxN/IJ+TnXjfvxg== mute-stream@0.0.7: version "0.0.7" resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.7.tgz#3075ce93bc21b8fab43e1bc4da7e8115ed1e7bab" + integrity sha1-MHXOk7whuPq0PhvE2n6BFe0ee6s= mute-stream@0.0.8: version "0.0.8" @@ -3555,19 +3619,20 @@ mute-stream@0.0.8: integrity sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA== nan@^2.12.1: - version "2.14.0" - resolved "https://registry.yarnpkg.com/nan/-/nan-2.14.0.tgz#7818f722027b2459a86f0295d434d1fc2336c52c" + version "2.14.2" + resolved "https://registry.yarnpkg.com/nan/-/nan-2.14.2.tgz#f5376400695168f4cc694ac9393d0c9585eeea19" + integrity sha512-M2ufzIiINKCuDfBSAUr1vWQ+vuVcA9kqx8JJUsbQi6yf1uGRyb7HfpdfUr5qLXf3B/t8dPvcjhKMmlfnP47EzQ== nanomatch@^1.2.9: - version "1.2.9" - resolved "https://registry.yarnpkg.com/nanomatch/-/nanomatch-1.2.9.tgz#879f7150cb2dab7a471259066c104eee6e0fa7c2" + version "1.2.13" + resolved "https://registry.yarnpkg.com/nanomatch/-/nanomatch-1.2.13.tgz#b87a8aa4fc0de8fe6be88895b38983ff265bd119" + integrity sha512-fpoe2T0RbHwBTBUOftAfBPaDEi06ufaUai0mE6Yn1kacc3SnTErfb/h+X94VXzI64rKFHYImXSvdwGGCmwOqCA== dependencies: arr-diff "^4.0.0" array-unique "^0.3.2" define-property "^2.0.2" extend-shallow "^3.0.2" fragment-cache "^0.2.1" - is-odd "^2.0.0" is-windows "^1.0.2" kind-of "^6.0.2" object.pick "^1.3.0" @@ -3578,70 +3643,48 @@ nanomatch@^1.2.9: natural-compare@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" - -needle@^2.2.1: - version "2.4.0" - resolved "https://registry.yarnpkg.com/needle/-/needle-2.4.0.tgz#6833e74975c444642590e15a750288c5f939b57c" - dependencies: - debug "^3.2.6" - iconv-lite "^0.4.4" - sax "^1.2.4" + integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= neo-async@^2.6.0: version "2.6.2" resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.2.tgz#b4aafb93e3aeb2d8174ca53cf163ab7d7308305f" integrity sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw== -next-tick@^1.0.0: +next-tick@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/next-tick/-/next-tick-1.0.0.tgz#ca86d1fe8828169b0120208e3dc8424b9db8342c" + integrity sha1-yobR/ogoFpsBICCOPchCS524NCw= nice-try@^1.0.4: version "1.0.5" - resolved "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz#a3378a7696ce7d223e88fc9b764bd7ef1089e366" + resolved "https://registry.yarnpkg.com/nice-try/-/nice-try-1.0.5.tgz#a3378a7696ce7d223e88fc9b764bd7ef1089e366" + integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== -nise@^1.4.10: - version "1.5.0" - resolved "https://registry.yarnpkg.com/nise/-/nise-1.5.0.tgz#d03ea0e6c1b75c638015aa3585eddc132949a50d" - integrity sha512-Z3sfYEkLFzFmL8KY6xnSJLRxwQwYBjOXi/24lb62ZnZiGA0JUzGGTI6TBIgfCSMIDl9Jlu8SRmHNACLTemDHww== +nise@^1.5.2: + version "1.5.3" + resolved "https://registry.yarnpkg.com/nise/-/nise-1.5.3.tgz#9d2cfe37d44f57317766c6e9408a359c5d3ac1f7" + integrity sha512-Ymbac/94xeIrMf59REBPOv0thr+CJVFMhrlAkW/gjCIE58BGQdCj0x7KRCb3yz+Ga2Rz3E9XXSvUyyxqqhjQAQ== dependencies: - "@sinonjs/formatio" "^3.1.0" + "@sinonjs/formatio" "^3.2.1" "@sinonjs/text-encoding" "^0.7.1" just-extend "^4.0.2" - lolex "^4.1.0" + lolex "^5.0.1" path-to-regexp "^1.7.0" -nock@7.5.0: - version "7.5.0" - resolved "https://registry.yarnpkg.com/nock/-/nock-7.5.0.tgz#e287dd3e5458cd305c3a859c7a80dfed369c0bbe" +nock@^13.0.11: + version "13.0.11" + resolved "https://registry.yarnpkg.com/nock/-/nock-13.0.11.tgz#ba733252e720897ca50033205c39db0c7470f331" + integrity sha512-sKZltNkkWblkqqPAsjYW0bm3s9DcHRPiMOyKO/PkfJ+ANHZ2+LA2PLe22r4lLrKgXaiSaDQwW3qGsJFtIpQIeQ== dependencies: - chai ">=1.9.2 <4.0.0" - debug "^2.2.0" - deep-equal "^1.0.0" + debug "^4.1.0" json-stringify-safe "^5.0.1" - lodash "^3.10.1" - mkdirp "^0.5.0" - propagate "0.3.x" - qs "^6.0.2" + lodash.set "^4.3.2" + propagate "^2.0.0" node-modules-regexp@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/node-modules-regexp/-/node-modules-regexp-1.0.0.tgz#8d9dbe28964a4ac5712e9131642107c71e90ec40" - -node-pre-gyp@^0.12.0: - version "0.12.0" - resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.12.0.tgz#39ba4bb1439da030295f899e3b520b7785766149" - dependencies: - detect-libc "^1.0.2" - mkdirp "^0.5.1" - needle "^2.2.1" - nopt "^4.0.1" - npm-packlist "^1.1.6" - npmlog "^4.0.2" - rc "^1.2.7" - rimraf "^2.6.1" - semver "^5.3.0" - tar "^4" + resolved "https://registry.yarnpkg.com/node-modules-regexp/-/node-modules-regexp-1.0.0.tgz#8d9dbe28964a4ac5712e9131642107c71e90ec40" + integrity sha1-jZ2+KJZKSsVxLpExZCEHxx6Q7EA= node-releases@^1.1.71: version "1.1.71" @@ -3651,19 +3694,14 @@ node-releases@^1.1.71: nopt@3.x: version "3.0.6" resolved "https://registry.yarnpkg.com/nopt/-/nopt-3.0.6.tgz#c6465dbf08abcd4db359317f79ac68a646b28ff9" + integrity sha1-xkZdvwirzU2zWTF/eaxopkayj/k= dependencies: abbrev "1" -nopt@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/nopt/-/nopt-4.0.1.tgz#d0d4685afd5415193c8c7505602d0d17cd64474d" - dependencies: - abbrev "1" - osenv "^0.1.4" - normalize-package-data@^2.3.2: version "2.5.0" resolved "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-2.5.0.tgz#e66db1838b200c1dfc233225d12cb36520e234a8" + integrity sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA== dependencies: hosted-git-info "^2.1.4" resolve "^1.10.0" @@ -3673,86 +3711,66 @@ normalize-package-data@^2.3.2: normalize-path@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-2.1.1.tgz#1ab28b556e198363a8c1a6f7e6fa20137fe6aed9" + integrity sha1-GrKLVW4Zg2Oowab35vogE3/mrtk= dependencies: remove-trailing-separator "^1.0.1" normalize-path@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" + integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== now-and-later@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/now-and-later/-/now-and-later-2.0.1.tgz#8e579c8685764a7cc02cb680380e94f43ccb1f7c" + integrity sha512-KGvQ0cB70AQfg107Xvs/Fbu+dGmZoTRJp2TaPwcwQm3/7PteUyN2BCgk8KBMPGBUXZdVwyWS8fDCGFygBm19UQ== dependencies: once "^1.3.2" -npm-bundled@^1.0.1: - version "1.0.6" - resolved "https://registry.yarnpkg.com/npm-bundled/-/npm-bundled-1.0.6.tgz#e7ba9aadcef962bb61248f91721cd932b3fe6bdd" - -npm-packlist@^1.1.6: - version "1.4.4" - resolved "https://registry.yarnpkg.com/npm-packlist/-/npm-packlist-1.4.4.tgz#866224233850ac534b63d1a6e76050092b5d2f44" - dependencies: - ignore-walk "^3.0.1" - npm-bundled "^1.0.1" - npm-run-path@^2.0.0, npm-run-path@^2.0.2: version "2.0.2" - resolved "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz#35a9232dfa35d7067b4cb2ddf2357b1871536c5f" + resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-2.0.2.tgz#35a9232dfa35d7067b4cb2ddf2357b1871536c5f" + integrity sha1-NakjLfo11wZ7TLLd8jV7GHFTbF8= dependencies: path-key "^2.0.0" -npmlog@^4.0.2: - version "4.1.2" - resolved "https://registry.yarnpkg.com/npmlog/-/npmlog-4.1.2.tgz#08a7f2a8bf734604779a9efa4ad5cc717abb954b" - dependencies: - are-we-there-yet "~1.1.2" - console-control-strings "~1.1.0" - gauge "~2.7.3" - set-blocking "~2.0.0" - number-is-nan@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" + integrity sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0= oauth-sign@~0.9.0: version "0.9.0" resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.9.0.tgz#47a7b016baa68b5fa0ecf3dee08a85c679ac6455" integrity sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ== -object-assign@^4.0.1, object-assign@^4.1.0: +object-assign@^4.0.1: version "4.1.1" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" + integrity sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM= object-copy@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/object-copy/-/object-copy-0.1.0.tgz#7e7d858b781bd7c991a41ba975ed3812754e998c" + integrity sha1-fn2Fi3gb18mRpBupde04EnVOmYw= dependencies: copy-descriptor "^0.1.0" define-property "^0.2.5" kind-of "^3.0.3" -object-keys@^1.0.11, object-keys@^1.0.12, object-keys@^1.1.1: +object-keys@^1.0.12, object-keys@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.1.1.tgz#1c47f272df277f3b1daf061677d9c82e2322c60e" + integrity sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA== object-visit@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/object-visit/-/object-visit-1.0.1.tgz#f79c4493af0c5377b59fe39d395e41042dd045bb" + integrity sha1-95xEk68MU3e1n+OdOV5BBC3QRbs= dependencies: isobject "^3.0.0" -object.assign@^4.0.4: - version "4.1.0" - resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.1.0.tgz#968bf1100d7956bb3ca086f006f846b3bc4008da" - dependencies: - define-properties "^1.1.2" - function-bind "^1.1.1" - has-symbols "^1.0.0" - object-keys "^1.0.11" - -object.assign@^4.1.0: +object.assign@^4.0.4, object.assign@^4.1.0: version "4.1.2" resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.1.2.tgz#0ed54a342eceb37b38ff76eb831a0e788cb63940" integrity sha512-ixT2L5THXsApyiUPYKmW+2EHpXXe5Ii3M+f4e+aJFAHao5amFRW6J0OO6c/LU8Be47utCx2GL89hxGB6XSmKuQ== @@ -3765,6 +3783,7 @@ object.assign@^4.1.0: object.defaults@^1.0.0, object.defaults@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/object.defaults/-/object.defaults-1.1.0.tgz#3a7f868334b407dea06da16d88d5cd29e435fecf" + integrity sha1-On+GgzS0B96gbaFtiNXNKeQ1/s8= dependencies: array-each "^1.0.1" array-slice "^1.0.0" @@ -3774,6 +3793,7 @@ object.defaults@^1.0.0, object.defaults@^1.1.0: object.map@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/object.map/-/object.map-1.0.1.tgz#cf83e59dc8fcc0ad5f4250e1f78b3b81bd801d37" + integrity sha1-z4Plncj8wK1fQlDh94s7gb2AHTc= dependencies: for-own "^1.0.0" make-iterator "^1.0.0" @@ -3781,12 +3801,14 @@ object.map@^1.0.0: object.pick@^1.2.0, object.pick@^1.3.0: version "1.3.0" resolved "https://registry.yarnpkg.com/object.pick/-/object.pick-1.3.0.tgz#87a10ac4c1694bd2e1cbf53591a66141fb5dd747" + integrity sha1-h6EKxMFpS9Lhy/U1kaZhQftd10c= dependencies: isobject "^3.0.1" object.reduce@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/object.reduce/-/object.reduce-1.0.1.tgz#6fe348f2ac7fa0f95ca621226599096825bb03ad" + integrity sha1-b+NI8qx/oPlcpiEiZZkJaCW7A60= dependencies: for-own "^1.0.0" make-iterator "^1.0.0" @@ -3794,12 +3816,14 @@ object.reduce@^1.0.0: once@1.x, once@^1.3.0, once@^1.3.1, once@^1.3.2, once@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" + integrity sha1-WDsap3WWHUsROsF9nFC6753Xa9E= dependencies: wrappy "1" onetime@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/onetime/-/onetime-2.0.1.tgz#067428230fd67443b2794b22bba528b6867962d4" + integrity sha1-BnQoIw/WdEOyeUsiu6UotoZ5YtQ= dependencies: mimic-fn "^1.0.0" @@ -3810,18 +3834,7 @@ onetime@^5.1.0: dependencies: mimic-fn "^2.1.0" -optionator@^0.8.1, optionator@^0.8.2: - version "0.8.2" - resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.2.tgz#364c5e409d3f4d6301d6c0b4c05bba50180aeb64" - dependencies: - deep-is "~0.1.3" - fast-levenshtein "~2.0.4" - levn "~0.3.0" - prelude-ls "~1.1.2" - type-check "~0.3.2" - wordwrap "~1.0.0" - -optionator@^0.8.3: +optionator@^0.8.1, optionator@^0.8.2, optionator@^0.8.3: version "0.8.3" resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.3.tgz#84fa1d036fe9d3c7e21d99884b601167ec8fb495" integrity sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA== @@ -3836,59 +3849,57 @@ optionator@^0.8.3: ordered-read-streams@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/ordered-read-streams/-/ordered-read-streams-1.0.1.tgz#77c0cb37c41525d64166d990ffad7ec6a0e1363e" + integrity sha1-d8DLN8QVJdZBZtmQ/61+xqDhNj4= dependencies: readable-stream "^2.0.1" -os-homedir@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/os-homedir/-/os-homedir-1.0.2.tgz#ffbc4988336e0e833de0c168c7ef152121aa7fb3" - os-locale@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/os-locale/-/os-locale-1.4.0.tgz#20f9f17ae29ed345e8bde583b13d2009803c14d9" + integrity sha1-IPnxeuKe00XoveWDsT0gCYA8FNk= dependencies: lcid "^1.0.0" -os-tmpdir@^1.0.0, os-tmpdir@~1.0.2: +os-tmpdir@~1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" - -osenv@^0.1.4: - version "0.1.5" - resolved "https://registry.yarnpkg.com/osenv/-/osenv-0.1.5.tgz#85cdfafaeb28e8677f416e287592b5f3f49ea410" - dependencies: - os-homedir "^1.0.0" - os-tmpdir "^1.0.0" + integrity sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ= p-finally@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae" + resolved "https://registry.yarnpkg.com/p-finally/-/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae" + integrity sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4= p-limit@^2.0.0: - version "2.2.0" - resolved "https://registry.npmjs.org/p-limit/-/p-limit-2.2.0.tgz#417c9941e6027a9abcba5092dd2904e255b5fbc2" + version "2.3.0" + resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-2.3.0.tgz#3dd33c647a214fdfffd835933eb086da0dc21db1" + integrity sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w== dependencies: p-try "^2.0.0" p-locate@^3.0.0: version "3.0.0" - resolved "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz#322d69a05c0264b25997d9f40cd8a891ab0064a4" + resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-3.0.0.tgz#322d69a05c0264b25997d9f40cd8a891ab0064a4" + integrity sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ== dependencies: p-limit "^2.0.0" p-try@^2.0.0: version "2.2.0" - resolved "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz#cb2868540e313d61de58fafbe35ce9004d5540e6" + resolved "https://registry.yarnpkg.com/p-try/-/p-try-2.2.0.tgz#cb2868540e313d61de58fafbe35ce9004d5540e6" + integrity sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ== parent-module@^1.0.0: version "1.0.1" - resolved "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz#691d2709e78c79fae3a156622452d00762caaaa2" + resolved "https://registry.yarnpkg.com/parent-module/-/parent-module-1.0.1.tgz#691d2709e78c79fae3a156622452d00762caaaa2" + integrity sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g== dependencies: callsites "^3.0.0" parse-filepath@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/parse-filepath/-/parse-filepath-1.0.2.tgz#a632127f53aaf3d15876f5872f3ffac763d6c891" + integrity sha1-pjISf1Oq89FYdvWHLz/6x2PWyJE= dependencies: is-absolute "^1.0.0" map-cache "^0.2.0" @@ -3897,74 +3908,85 @@ parse-filepath@^1.0.1: parse-json@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-2.2.0.tgz#f480f40434ef80741f8469099f8dea18f55a4dc9" + integrity sha1-9ID0BDTvgHQfhGkJn43qGPVaTck= dependencies: error-ex "^1.2.0" parse-node-version@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/parse-node-version/-/parse-node-version-1.0.1.tgz#e2b5dbede00e7fa9bc363607f53327e8b073189b" + integrity sha512-3YHlOa/JgH6Mnpr05jP9eDG254US9ek25LyIxZlDItp2iJtwyaXQb57lBYLdT3MowkUFYEV2XXNAYIPlESvJlA== parse-passwd@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/parse-passwd/-/parse-passwd-1.0.0.tgz#6d5b934a456993b23d37f40a382d6f1666a8e5c6" + integrity sha1-bVuTSkVpk7I9N/QKOC1vFmao5cY= pascalcase@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/pascalcase/-/pascalcase-0.1.1.tgz#b363e55e8006ca6fe21784d2db22bd15d7917f14" + integrity sha1-s2PlXoAGym/iF4TS2yK9FdeRfxQ= path-dirname@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/path-dirname/-/path-dirname-1.0.2.tgz#cc33d24d525e099a5388c0336c6e32b9160609e0" + integrity sha1-zDPSTVJeCZpTiMAzbG4yuRYGCeA= path-exists@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-2.1.0.tgz#0feb6c64f0fc518d9a754dd5efb62c7022761f4b" + integrity sha1-D+tsZPD8UY2adU3V77YscCJ2H0s= dependencies: pinkie-promise "^2.0.0" path-exists@^3.0.0: version "3.0.0" - resolved "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz#ce0ebeaa5f78cb18925ea7d810d7b59b010fd515" + resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-3.0.0.tgz#ce0ebeaa5f78cb18925ea7d810d7b59b010fd515" + integrity sha1-zg6+ql94yxiSXqfYENe1mwEP1RU= path-is-absolute@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" + integrity sha1-F0uSaHNVNP+8es5r9TpanhtcX18= path-is-inside@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/path-is-inside/-/path-is-inside-1.0.2.tgz#365417dede44430d1c11af61027facf074bdfc53" + integrity sha1-NlQX3t5EQw0cEa9hAn+s8HS9/FM= path-key@^2.0.0, path-key@^2.0.1: version "2.0.1" - resolved "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40" - -path-parse@^1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.5.tgz#3c1adf871ea9cd6c9431b6ea2bd74a0ff055c4c1" + resolved "https://registry.yarnpkg.com/path-key/-/path-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40" + integrity sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A= path-parse@^1.0.6: version "1.0.6" resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.6.tgz#d62dbb5679405d72c4737ec58600e9ddcf06d24c" + integrity sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw== path-root-regex@^0.1.0: version "0.1.2" resolved "https://registry.yarnpkg.com/path-root-regex/-/path-root-regex-0.1.2.tgz#bfccdc8df5b12dc52c8b43ec38d18d72c04ba96d" + integrity sha1-v8zcjfWxLcUsi0PsONGNcsBLqW0= path-root@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/path-root/-/path-root-0.1.1.tgz#9a4a6814cac1c0cd73360a95f32083c8ea4745b7" + integrity sha1-mkpoFMrBwM1zNgqV8yCDyOpHRbc= dependencies: path-root-regex "^0.1.0" path-to-regexp@^1.7.0: - version "1.7.0" - resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-1.7.0.tgz#59fde0f435badacba103a84e9d3bc64e96b9937d" + version "1.8.0" + resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-1.8.0.tgz#887b3ba9d84393e87a0a0b9f4cb756198b53548a" + integrity sha512-n43JRhlUKUAlibEJhPeir1ncUID16QnEjNpwzNdO3Lm4ywrBpBZ5oLD0I6br9evr1Y9JTqwRtAh7JLoOzAQdVA== dependencies: isarray "0.0.1" path-type@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/path-type/-/path-type-1.1.0.tgz#59c44f7ee491da704da415da5a4070ba4f8fe441" + integrity sha1-WcRPfuSR2nBNpBXaWkBwuk+P5EE= dependencies: graceful-fs "^4.1.2" pify "^2.0.0" @@ -3973,34 +3995,41 @@ path-type@^1.0.0: performance-now@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" + integrity sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns= pify@^2.0.0: version "2.3.0" resolved "https://registry.yarnpkg.com/pify/-/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c" + integrity sha1-7RQaasBDqEnqWISY59yosVMw6Qw= pify@^4.0.1: version "4.0.1" - resolved "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz#4b2cd25c50d598735c50292224fd8c6df41e3231" + resolved "https://registry.yarnpkg.com/pify/-/pify-4.0.1.tgz#4b2cd25c50d598735c50292224fd8c6df41e3231" + integrity sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g== pinkie-promise@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/pinkie-promise/-/pinkie-promise-2.0.1.tgz#2135d6dfa7a358c069ac9b178776288228450ffa" + integrity sha1-ITXW36ejWMBprJsXh3YogihFD/o= dependencies: pinkie "^2.0.0" pinkie@^2.0.0: version "2.0.4" resolved "https://registry.yarnpkg.com/pinkie/-/pinkie-2.0.4.tgz#72556b80cfa0d48a974e80e77248e80ed4f7f870" + integrity sha1-clVrgM+g1IqXToDnckjoDtT3+HA= pirates@^4.0.0: version "4.0.1" - resolved "https://registry.npmjs.org/pirates/-/pirates-4.0.1.tgz#643a92caf894566f91b2b986d2c66950a8e2fb87" + resolved "https://registry.yarnpkg.com/pirates/-/pirates-4.0.1.tgz#643a92caf894566f91b2b986d2c66950a8e2fb87" + integrity sha512-WuNqLTbMI3tmfef2TKxlQmAiLHKtFhlsCZnPIpuv2Ow0RDVO8lfy1Opf4NUzlMXLjPl+Men7AuVdX6TA+s+uGA== dependencies: node-modules-regexp "^1.0.0" pkg-dir@^3.0.0: version "3.0.0" - resolved "https://registry.npmjs.org/pkg-dir/-/pkg-dir-3.0.0.tgz#2749020f239ed990881b1f71210d51eb6523bea3" + resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-3.0.0.tgz#2749020f239ed990881b1f71210d51eb6523bea3" + integrity sha512-/E57AYkoeQ25qkxMj5PBOVgF8Kiu/h7cYS30Z5+R7WaiCCBfLq58ZI/dSeaEKb9WVJV5n/03QwrN3IeWIFllvw== dependencies: find-up "^3.0.0" @@ -4018,6 +4047,7 @@ plugin-error@^0.1.2: plugin-error@^1.0.0, plugin-error@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/plugin-error/-/plugin-error-1.0.1.tgz#77016bd8919d0ac377fdcdd0322328953ca5781c" + integrity sha512-L1zP0dk7vGweZME2i+EeakvUNqSrdiI3F91TwEoYiGrAfUXmVv6fJIq4g82PAXxNsWOp0J7ZqQy/3Szz0ajTxA== dependencies: ansi-colors "^1.0.1" arr-diff "^4.0.0" @@ -4027,47 +4057,52 @@ plugin-error@^1.0.0, plugin-error@^1.0.1: pluralize@^7.0.0: version "7.0.0" resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-7.0.0.tgz#298b89df8b93b0221dbf421ad2b1b1ea23fc6777" + integrity sha512-ARhBOdzS3e41FbkW/XWrTEtukqqLoK5+Z/4UeDaLuSW+39JPeFgs4gCGqsrJHVZX0fUrx//4OF0K1CUGwlIFow== posix-character-classes@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/posix-character-classes/-/posix-character-classes-0.1.1.tgz#01eac0fe3b5af71a2a6c02feabb8c1fef7e00eab" + integrity sha1-AerA/jta9xoqbAL+q7jB/vfgDqs= prelude-ls@~1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54" + integrity sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ= pretty-hrtime@^1.0.0: version "1.0.3" resolved "https://registry.yarnpkg.com/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz#b7e3ea42435a4c9b2759d99e0f201eb195802ee1" + integrity sha1-t+PqQkNaTJsnWdmeDyAesZWALuE= process-nextick-args@^2.0.0, process-nextick-args@~2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2" - -process-nextick-args@~1.0.6: - version "1.0.7" - resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-1.0.7.tgz#150e20b756590ad3f91093f25a4f2ad8bff30ba3" + integrity sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag== progress@^2.0.0: version "2.0.3" resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.3.tgz#7e8cf8d8f5b8f239c1bc68beb4eb78567d572ef8" + integrity sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA== -propagate@0.3.x: - version "0.3.1" - resolved "https://registry.yarnpkg.com/propagate/-/propagate-0.3.1.tgz#e3a84404a7ece820dd6bbea9f6d924e3135ae09c" +propagate@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/propagate/-/propagate-2.0.1.tgz#40cdedab18085c792334e64f0ac17256d38f9a45" + integrity sha512-vGrhOavPSTz4QVNuBNdcNXePNdNMaO1xj9yBeH1ScQPjk/rhg9sSlCXPhMkFuaNNW/syTvYqsnbIJxMBfRbbag== pseudomap@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3" + integrity sha1-8FKijacOYYkX7wqKw0wa5aaChrM= -psl@^1.1.24: - version "1.2.0" - resolved "https://registry.yarnpkg.com/psl/-/psl-1.2.0.tgz#df12b5b1b3a30f51c329eacbdef98f3a6e136dc6" - integrity sha512-GEn74ZffufCmkDDLNcl3uuyF/aSD6exEyh1v/ZSdAomB82t6G9hzJVRx0jBmLDW+VfZqks3aScmMw9DszwUalA== +psl@^1.1.28: + version "1.8.0" + resolved "https://registry.yarnpkg.com/psl/-/psl-1.8.0.tgz#9326f8bcfb013adcc005fdff056acce020e51c24" + integrity sha512-RIdOzyoavK+hA18OGGWDqUTsCLhtA7IcZ/6NCs4fFJaHBDab+pDDmDIByWFRQJq2Cd7r1OoQxBGKOaztq+hjIQ== pump@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/pump/-/pump-2.0.1.tgz#12399add6e4cf7526d973cbc8b5ce2e2908b3909" + integrity sha512-ruPMNRkN3MHP1cWJc9OWr+T/xDP0jhXYCLfJcBuX54hhfIBnaQmAUMfDcG4DM5UMWByBbJY69QSphm3jtDKIkA== dependencies: end-of-stream "^1.1.0" once "^1.3.1" @@ -4075,40 +4110,26 @@ pump@^2.0.0: pumpify@^1.3.5: version "1.5.1" resolved "https://registry.yarnpkg.com/pumpify/-/pumpify-1.5.1.tgz#36513be246ab27570b1a374a5ce278bfd74370ce" + integrity sha512-oClZI37HvuUJJxSKKrC17bZ9Cu0ZYhEAGPsPUy9KlMUmv9dKX2o77RUmq7f3XjIxbwyGwYzbzQ1L2Ks8sIradQ== dependencies: duplexify "^3.6.0" inherits "^2.0.3" pump "^2.0.0" -punycode@^1.4.1: - version "1.4.1" - resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" - -punycode@^2.1.0: +punycode@^2.1.0, punycode@^2.1.1: version "2.1.1" - resolved "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" - -qs@^6.0.2: - version "6.5.1" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" + integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== qs@~6.5.2: version "6.5.2" resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" integrity sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA== -rc@^1.2.7: - version "1.2.8" - resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.8.tgz#cd924bf5200a075b83c188cd6b9e211b7fc0d3ed" - dependencies: - deep-extend "^0.6.0" - ini "~1.3.0" - minimist "^1.2.0" - strip-json-comments "~2.0.1" - read-pkg-up@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-1.0.1.tgz#9d63c13276c065918d57f002a57f40a1b643fb02" + integrity sha1-nWPBMnbAZZGNV/ACpX9AobZD+wI= dependencies: find-up "^1.0.0" read-pkg "^1.0.0" @@ -4116,14 +4137,16 @@ read-pkg-up@^1.0.1: read-pkg@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-1.1.0.tgz#f5ffaa5ecd29cb31c0474bca7d756b6bb29e3f28" + integrity sha1-9f+qXs0pyzHAR0vKfXVra7KePyg= dependencies: load-json-file "^1.0.0" normalize-package-data "^2.3.2" path-type "^1.0.0" -readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.5, readable-stream@^2.0.6, readable-stream@^2.3.3, readable-stream@^2.3.5, readable-stream@^2.3.6, readable-stream@~2.3.6: - version "2.3.6" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.6.tgz#b11c27d88b8ff1fbe070643cf94b0c79ae1b0aaf" +readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.5, readable-stream@^2.1.5, readable-stream@^2.2.2, readable-stream@^2.3.3, readable-stream@^2.3.5, readable-stream@^2.3.6, readable-stream@~2.3.6: + version "2.3.7" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.7.tgz#1eca1cf711aef814c04f62252a36a62f6cb23b57" + integrity sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw== dependencies: core-util-is "~1.0.0" inherits "~2.0.3" @@ -4133,21 +4156,10 @@ readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable string_decoder "~1.1.1" util-deprecate "~1.0.1" -readable-stream@^2.1.5, readable-stream@^2.2.2: - version "2.3.3" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.3.tgz#368f2512d79f9d46fdfc71349ae7878bbc1eb95c" - dependencies: - core-util-is "~1.0.0" - inherits "~2.0.3" - isarray "~1.0.0" - process-nextick-args "~1.0.6" - safe-buffer "~5.1.1" - string_decoder "~1.0.3" - util-deprecate "~1.0.1" - readdirp@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-2.2.1.tgz#0e87622a3325aa33e892285caf8b4e846529a525" + integrity sha512-1JU/8q+VgFZyxwrJ+SVIOsh+KywWGpds3NTqikiKpDMZWScmAYyKIgqkO+ARvNWJfXeXR1zxz7aHF4u4CyH6vQ== dependencies: graceful-fs "^4.1.11" micromatch "^3.1.10" @@ -4156,15 +4168,10 @@ readdirp@^2.2.1: rechoir@^0.6.2: version "0.6.2" resolved "https://registry.yarnpkg.com/rechoir/-/rechoir-0.6.2.tgz#85204b54dba82d5742e28c96756ef43af50e3384" + integrity sha1-hSBLVNuoLVdC4oyWdW70OvUOM4Q= dependencies: resolve "^1.1.6" -regenerate-unicode-properties@^8.0.2: - version "8.1.0" - resolved "https://registry.yarnpkg.com/regenerate-unicode-properties/-/regenerate-unicode-properties-8.1.0.tgz#ef51e0f0ea4ad424b77bf7cb41f3e015c70a3f0e" - dependencies: - regenerate "^1.4.0" - regenerate-unicode-properties@^8.2.0: version "8.2.0" resolved "https://registry.yarnpkg.com/regenerate-unicode-properties/-/regenerate-unicode-properties-8.2.0.tgz#e5de7111d655e7ba60c057dbe9ff37c87e65cdec" @@ -4173,8 +4180,9 @@ regenerate-unicode-properties@^8.2.0: regenerate "^1.4.0" regenerate@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.4.0.tgz#4a856ec4b56e4077c557589cae85e7a4c8869a11" + version "1.4.2" + resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.4.2.tgz#b9346d8827e8f5a32f7ba29637d398b69014848a" + integrity sha512-zrceR/XhGYU/d/opr2EKO7aRHUeiBI8qjtfHqADTwZd6Szfy16la6kqD0MIUs5z5hx6AaKa+PixpPrR289+I0A== regenerator-runtime@^0.13.4: version "0.13.7" @@ -4191,6 +4199,7 @@ regenerator-transform@^0.14.2: regex-not@^1.0.0, regex-not@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/regex-not/-/regex-not-1.0.2.tgz#1f4ece27e00b0b65e0247a6810e6a85d83a5752c" + integrity sha512-J6SDjUgDxQj5NusnOtdFxDwN/+HWykR8GELwctJ7mdqhcyy1xEc4SRFHUXvxTp661YaVKAjfRLZ9cCqS6tn32A== dependencies: extend-shallow "^3.0.2" safe-regex "^1.1.0" @@ -4198,21 +4207,12 @@ regex-not@^1.0.0, regex-not@^1.0.2: regexpp@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-1.1.0.tgz#0e3516dd0b7904f413d2d4193dce4618c3a689ab" + integrity sha512-LOPw8FpgdQF9etWMaAfG/WRthIdXJGYp4mJ2Jgn/2lpkbod9jPn0t9UqN7AxBOKNfzRbYyVfgc7Vk4t/MpnXgw== regexpp@^2.0.1: version "2.0.1" - resolved "https://registry.npmjs.org/regexpp/-/regexpp-2.0.1.tgz#8d19d31cf632482b589049f8281f93dbcba4d07f" - -regexpu-core@^4.5.4: - version "4.5.4" - resolved "https://registry.yarnpkg.com/regexpu-core/-/regexpu-core-4.5.4.tgz#080d9d02289aa87fe1667a4f5136bc98a6aebaae" - dependencies: - regenerate "^1.4.0" - regenerate-unicode-properties "^8.0.2" - regjsgen "^0.5.0" - regjsparser "^0.6.0" - unicode-match-property-ecmascript "^1.0.4" - unicode-match-property-value-ecmascript "^1.1.0" + resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-2.0.1.tgz#8d19d31cf632482b589049f8281f93dbcba4d07f" + integrity sha512-lv0M6+TkDVniA3aD1Eg0DVpfU/booSu7Eev3TDO/mZKHBfVjgCGTV4t4buppESEYDtkArYFOxTJWv6S5C+iaNw== regexpu-core@^4.7.1: version "4.7.1" @@ -4226,21 +4226,11 @@ regexpu-core@^4.7.1: unicode-match-property-ecmascript "^1.0.4" unicode-match-property-value-ecmascript "^1.2.0" -regjsgen@^0.5.0: - version "0.5.0" - resolved "https://registry.yarnpkg.com/regjsgen/-/regjsgen-0.5.0.tgz#a7634dc08f89209c2049adda3525711fb97265dd" - regjsgen@^0.5.1: version "0.5.2" resolved "https://registry.yarnpkg.com/regjsgen/-/regjsgen-0.5.2.tgz#92ff295fb1deecbf6ecdab2543d207e91aa33733" integrity sha512-OFFT3MfrH90xIW8OOSyUrk6QHD5E9JOTeGodiJeBS3J6IwlgzJMNE/1bZklWz5oTg+9dCMyEetclvCVXOPoN3A== -regjsparser@^0.6.0: - version "0.6.0" - resolved "https://registry.yarnpkg.com/regjsparser/-/regjsparser-0.6.0.tgz#f1e6ae8b7da2bae96c99399b868cd6c933a2ba9c" - dependencies: - jsesc "~0.5.0" - regjsparser@^0.6.4: version "0.6.9" resolved "https://registry.yarnpkg.com/regjsparser/-/regjsparser-0.6.9.tgz#b489eef7c9a2ce43727627011429cf833a7183e6" @@ -4251,6 +4241,7 @@ regjsparser@^0.6.4: remove-bom-buffer@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/remove-bom-buffer/-/remove-bom-buffer-3.0.0.tgz#c2bf1e377520d324f623892e33c10cac2c252b53" + integrity sha512-8v2rWhaakv18qcvNeli2mZ/TMTL2nEyAKRvzo1WtnZBl15SHyEhrCu2/xKlJyUFKHiHgfXIyuY6g2dObJJycXQ== dependencies: is-buffer "^1.1.5" is-utf8 "^0.2.1" @@ -4258,6 +4249,7 @@ remove-bom-buffer@^3.0.0: remove-bom-stream@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/remove-bom-stream/-/remove-bom-stream-1.2.0.tgz#05f1a593f16e42e1fb90ebf59de8e569525f9523" + integrity sha1-BfGlk/FuQuH7kOv1nejlaVJflSM= dependencies: remove-bom-buffer "^3.0.0" safe-buffer "^5.1.0" @@ -4266,31 +4258,36 @@ remove-bom-stream@^1.2.0: remove-trailing-separator@^1.0.1, remove-trailing-separator@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz#c24bce2a283adad5bc3f58e0d48249b92379d8ef" + integrity sha1-wkvOKig62tW8P1jg1IJJuSN52O8= repeat-element@^1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/repeat-element/-/repeat-element-1.1.2.tgz#ef089a178d1483baae4d93eb98b4f9e4e11d990a" + version "1.1.4" + resolved "https://registry.yarnpkg.com/repeat-element/-/repeat-element-1.1.4.tgz#be681520847ab58c7568ac75fbfad28ed42d39e9" + integrity sha512-LFiNfRcSu7KK3evMyYOuCzv3L10TW7yC1G2/+StMjK8Y6Vqd2MG7r/Qjw4ghtuCOjFvlnms/iMmLqpvW/ES/WQ== repeat-string@^1.6.1: version "1.6.1" resolved "https://registry.yarnpkg.com/repeat-string/-/repeat-string-1.6.1.tgz#8dcae470e1c88abc2d600fff4a776286da75e637" + integrity sha1-jcrkcOHIirwtYA//Sndihtp15jc= replace-ext@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/replace-ext/-/replace-ext-1.0.0.tgz#de63128373fcbf7c3ccfa4de5a480c45a67958eb" + version "1.0.1" + resolved "https://registry.yarnpkg.com/replace-ext/-/replace-ext-1.0.1.tgz#2d6d996d04a15855d967443631dd5f77825b016a" + integrity sha512-yD5BHCe7quCgBph4rMQ+0KkIRKwWCrHDOX1p1Gp6HwjPM5kVoCdKGNhN7ydqqsX6lJEnQDKZ/tFMiEdQ1dvPEw== replace-homedir@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/replace-homedir/-/replace-homedir-1.0.0.tgz#e87f6d513b928dde808260c12be7fec6ff6e798c" + integrity sha1-6H9tUTuSjd6AgmDBK+f+xv9ueYw= dependencies: homedir-polyfill "^1.0.1" is-absolute "^1.0.0" remove-trailing-separator "^1.1.0" request@^2.88.0: - version "2.88.0" - resolved "https://registry.yarnpkg.com/request/-/request-2.88.0.tgz#9c2fca4f7d35b592efe57c7f0a55e81052124fef" - integrity sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg== + version "2.88.2" + resolved "https://registry.yarnpkg.com/request/-/request-2.88.2.tgz#d73c918731cb5a87da047e207234146f664d12b3" + integrity sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw== dependencies: aws-sign2 "~0.7.0" aws4 "^1.8.0" @@ -4299,7 +4296,7 @@ request@^2.88.0: extend "~3.0.2" forever-agent "~0.6.1" form-data "~2.3.2" - har-validator "~5.1.0" + har-validator "~5.1.3" http-signature "~1.2.0" is-typedarray "~1.0.0" isstream "~0.1.2" @@ -4309,21 +4306,24 @@ request@^2.88.0: performance-now "^2.1.0" qs "~6.5.2" safe-buffer "^5.1.2" - tough-cookie "~2.4.3" + tough-cookie "~2.5.0" tunnel-agent "^0.6.0" uuid "^3.3.2" require-directory@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" + integrity sha1-jGStX9MNqxyXbiNE/+f3kqam30I= require-main-filename@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-1.0.1.tgz#97f717b69d48784f5f526a6c5aa8ffdda055a4d1" + integrity sha1-l/cXtp1IeE9fUmpsWqj/3aBVpNE= require-uncached@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/require-uncached/-/require-uncached-1.0.3.tgz#4e0d56d6c9662fd31e43011c4b95aa49955421d3" + integrity sha1-Tg1W1slmL9MeQwEcS5WqSZVUIdM= dependencies: caller-path "^0.1.0" resolve-from "^1.0.0" @@ -4331,6 +4331,7 @@ require-uncached@^1.0.3: resolve-dir@^1.0.0, resolve-dir@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/resolve-dir/-/resolve-dir-1.0.1.tgz#79a40644c362be82f26effe739c9bb5382046f43" + integrity sha1-eaQGRMNivoLybv/nOcm7U4IEb0M= dependencies: expand-tilde "^2.0.0" global-modules "^1.0.0" @@ -4338,38 +4339,31 @@ resolve-dir@^1.0.0, resolve-dir@^1.0.1: resolve-from@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-1.0.1.tgz#26cbfe935d1aeeeabb29bc3fe5aeb01e93d44226" + integrity sha1-Jsv+k10a7uq7Kbw/5a6wHpPUQiY= resolve-from@^4.0.0: version "4.0.0" - resolved "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" + integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== resolve-options@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/resolve-options/-/resolve-options-1.1.0.tgz#32bb9e39c06d67338dc9378c0d6d6074566ad131" + integrity sha1-MrueOcBtZzONyTeMDW1gdFZq0TE= dependencies: value-or-function "^3.0.0" resolve-url@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" + integrity sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo= resolve@1.1.x: version "1.1.7" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.1.7.tgz#203114d82ad2c5ed9e8e0411b3932875e889e97b" + integrity sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs= -resolve@^1.1.6, resolve@^1.1.7: - version "1.7.1" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.7.1.tgz#aadd656374fd298aee895bc026b8297418677fd3" - dependencies: - path-parse "^1.0.5" - -resolve@^1.10.0, resolve@^1.4.0: - version "1.11.1" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.11.1.tgz#ea10d8110376982fef578df8fc30b9ac30a07a3e" - dependencies: - path-parse "^1.0.6" - -resolve@^1.14.2: +resolve@^1.1.6, resolve@^1.1.7, resolve@^1.10.0, resolve@^1.12.0, resolve@^1.14.2, resolve@^1.4.0: version "1.20.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.20.0.tgz#629a013fb3f70755d6f0b7935cc1c2c5378b1975" integrity sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A== @@ -4380,6 +4374,7 @@ resolve@^1.14.2: restore-cursor@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-2.0.0.tgz#9f7ee287f82fd326d4fd162923d62129eee0dfaf" + integrity sha1-n37ih/gv0ybU/RYpI9YhKe7g368= dependencies: onetime "^2.0.0" signal-exit "^3.0.2" @@ -4395,20 +4390,16 @@ restore-cursor@^3.1.0: ret@~0.1.10: version "0.1.15" resolved "https://registry.yarnpkg.com/ret/-/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc" + integrity sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg== -rimraf@2.6.3, rimraf@^2.6.1, rimraf@~2.6.2: +rimraf@2.6.3, rimraf@~2.6.2: version "2.6.3" resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.3.tgz#b2d104fe0d8fb27cf9e0a1cda8262dd3833c6cab" + integrity sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA== dependencies: glob "^7.1.3" -run-async@^2.2.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.3.0.tgz#0371ab4ae0bdd720d4166d7dfda64ff7a445a6c0" - dependencies: - is-promise "^2.1.0" - -run-async@^2.4.0: +run-async@^2.2.0, run-async@^2.4.0: version "2.4.1" resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.4.1.tgz#8440eccf99ea3e70bd409d49aab88e10c189a455" integrity sha512-tvVnVv01b8c1RrA6Ep7JkStj85Guv/YrMcwqYQnwjsAS2cTmmPGBBjAjpCW7RrSodNSoE2/qg9O4bceNvUuDgQ== @@ -4416,12 +4407,14 @@ run-async@^2.4.0: rx-lite-aggregates@^4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/rx-lite-aggregates/-/rx-lite-aggregates-4.0.8.tgz#753b87a89a11c95467c4ac1626c4efc4e05c67be" + integrity sha1-dTuHqJoRyVRnxKwWJsTvxOBcZ74= dependencies: rx-lite "*" rx-lite@*, rx-lite@^4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-4.0.8.tgz#0b1e11af8bc44836f04a6407e92da42467b79444" + integrity sha1-Cx4Rr4vESDbwSmQH6S2kJGe3lEQ= rxjs@^6.6.0: version "6.6.7" @@ -4430,68 +4423,59 @@ rxjs@^6.6.0: dependencies: tslib "^1.9.0" -safe-buffer@^5.0.1, safe-buffer@~5.1.0, safe-buffer@~5.1.1: - version "5.1.1" - resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.1.tgz#893312af69b2123def71f57889001671eeb2c853" +safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@^5.1.2: + version "5.2.1" + resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" + integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== -safe-buffer@^5.1.0, safe-buffer@^5.1.2: +safe-buffer@~5.1.0, safe-buffer@~5.1.1: version "5.1.2" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" + integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== safe-regex@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/safe-regex/-/safe-regex-1.1.0.tgz#40a3669f3b077d1e943d44629e157dd48023bf2e" + integrity sha1-QKNmnzsHfR6UPURinhV91IAjvy4= dependencies: ret "~0.1.10" "safer-buffer@>= 2.1.2 < 3", safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" - -sax@^1.2.4: - version "1.2.4" - resolved "https://registry.yarnpkg.com/sax/-/sax-1.2.4.tgz#2816234e2378bddc4e5354fab5caa895df7100d9" + integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== semver-greatest-satisfied-range@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/semver-greatest-satisfied-range/-/semver-greatest-satisfied-range-1.1.0.tgz#13e8c2658ab9691cb0cd71093240280d36f77a5b" + integrity sha1-E+jCZYq5aRywzXEJMkAoDTb3els= dependencies: sver-compat "^1.5.0" "semver@2 || 3 || 4 || 5", semver@^5.3.0, semver@^5.5.0, semver@^5.6.0: - version "5.7.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.0.tgz#790a7cf6fea5459bac96110b29b60412dc8ff96b" + version "5.7.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" + integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== semver@7.0.0: version "7.0.0" resolved "https://registry.yarnpkg.com/semver/-/semver-7.0.0.tgz#5f3ca35761e47e05b206c6daff2cf814f0316b8e" integrity sha512-+GB6zVA9LWh6zovYQLALHwv5rb2PHGlJi3lfiqIHxR0uuwCgefcOJc59v9fv1w8GbStwxuuqqAjI9NMAOOgq1A== -semver@^6.1.1: - version "6.2.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-6.2.0.tgz#4d813d9590aaf8a9192693d6c85b9344de5901db" - -semver@^6.1.2, semver@^6.3.0: +semver@^6.1.1, semver@^6.1.2, semver@^6.3.0: version "6.3.0" resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== -set-blocking@^2.0.0, set-blocking@~2.0.0: +set-blocking@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" + integrity sha1-BF+XgtARrppoA93TgrJDkrPYkPc= -set-value@^0.4.3: - version "0.4.3" - resolved "https://registry.yarnpkg.com/set-value/-/set-value-0.4.3.tgz#7db08f9d3d22dc7f78e53af3c3bf4666ecdfccf1" - dependencies: - extend-shallow "^2.0.1" - is-extendable "^0.1.1" - is-plain-object "^2.0.1" - to-object-path "^0.3.0" - -set-value@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/set-value/-/set-value-2.0.0.tgz#71ae4a88f0feefbbf52d1ea604f3fb315ebb6274" +set-value@^2.0.0, set-value@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/set-value/-/set-value-2.0.1.tgz#a18d40530e6f07de4228c7defe4227af8cad005b" + integrity sha512-JxHc1weCN68wRY0fhCoXpyK55m/XPHafOmK4UWD7m2CI14GMcFypt4w/0+NV5f/ZMby2F6S2wwA7fgynh9gWSw== dependencies: extend-shallow "^2.0.1" is-extendable "^0.1.1" @@ -4508,39 +4492,44 @@ shallow-clone@^3.0.0: shebang-command@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea" + integrity sha1-RKrGW2lbAzmJaMOfNj/uXer98eo= dependencies: shebang-regex "^1.0.0" shebang-regex@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3" + integrity sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM= signal-exit@^3.0.0, signal-exit@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d" + version "3.0.3" + resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.3.tgz#a1410c2edd8f077b08b4e253c8eacfcaf057461c" + integrity sha512-VUJ49FC8U1OxwZLxIbTTrDvLnf/6TDgxZcK8wxR8zs13xpx7xbG60ndBlhNrFi2EMuFRoeDoJO7wthSLq42EjA== sinon@^7.3.2: - version "7.3.2" - resolved "https://registry.yarnpkg.com/sinon/-/sinon-7.3.2.tgz#82dba3a6d85f6d2181e1eca2c10d8657c2161f28" - integrity sha512-thErC1z64BeyGiPvF8aoSg0LEnptSaWE7YhdWWbWXgelOyThent7uKOnnEh9zBxDbKixtr5dEko+ws1sZMuFMA== + version "7.5.0" + resolved "https://registry.yarnpkg.com/sinon/-/sinon-7.5.0.tgz#e9488ea466070ea908fd44a3d6478fd4923c67ec" + integrity sha512-AoD0oJWerp0/rY9czP/D6hDTTUYGpObhZjMpd7Cl/A6+j0xBE+ayL/ldfggkBXUs0IkvIiM1ljM8+WkOc5k78Q== dependencies: "@sinonjs/commons" "^1.4.0" "@sinonjs/formatio" "^3.2.1" - "@sinonjs/samsam" "^3.3.1" + "@sinonjs/samsam" "^3.3.3" diff "^3.5.0" - lolex "^4.0.1" - nise "^1.4.10" + lolex "^4.2.0" + nise "^1.5.2" supports-color "^5.5.0" slice-ansi@1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-1.0.0.tgz#044f1a49d8842ff307aad6b505ed178bd950134d" + integrity sha512-POqxBK6Lb3q6s047D/XsDVNPnF9Dl8JSaqe9h9lURl0OdNqy/ujDrOiIHtsqXMGbWWTIomRzAMaTyawAU//Reg== dependencies: is-fullwidth-code-point "^2.0.0" slice-ansi@^2.1.0: version "2.1.0" - resolved "https://registry.npmjs.org/slice-ansi/-/slice-ansi-2.1.0.tgz#cacd7693461a637a5788d92a7dd4fba068e81636" + resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-2.1.0.tgz#cacd7693461a637a5788d92a7dd4fba068e81636" + integrity sha512-Qu+VC3EwYLldKa1fCxuuvULvSJOKEgk9pi8dZeCVK7TqBfUNTH4sFkk4joj8afVSfAYgJoSOetjx9QWOJ5mYoQ== dependencies: ansi-styles "^3.2.0" astral-regex "^1.0.0" @@ -4549,6 +4538,7 @@ slice-ansi@^2.1.0: snapdragon-node@^2.0.1: version "2.1.1" resolved "https://registry.yarnpkg.com/snapdragon-node/-/snapdragon-node-2.1.1.tgz#6c175f86ff14bdb0724563e8f3c1b021a286853b" + integrity sha512-O27l4xaMYt/RSQ5TR3vpWCAB5Kb/czIcqUFOM/C4fYcLnbZUc1PkjTAMjof2pBWaSTwOUd6qUHcFGVGj7aIwnw== dependencies: define-property "^1.0.0" isobject "^3.0.0" @@ -4557,12 +4547,14 @@ snapdragon-node@^2.0.1: snapdragon-util@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/snapdragon-util/-/snapdragon-util-3.0.1.tgz#f956479486f2acd79700693f6f7b805e45ab56e2" + integrity sha512-mbKkMdQKsjX4BAL4bRYTj21edOf8cN7XHdYUJEe+Zn99hVEYcMvKPct1IqNe7+AZPirn8BCDOQBHQZknqmKlZQ== dependencies: kind-of "^3.2.0" snapdragon@^0.8.1: version "0.8.2" resolved "https://registry.yarnpkg.com/snapdragon/-/snapdragon-0.8.2.tgz#64922e7c565b0e14204ba1aa7d6964278d25182d" + integrity sha512-FtyOnWN/wCHTVXOMwvSv26d+ko5vWlIDD6zoUJ7LW8vh+ZBC8QdljveRP+crNrtBwioEUWy/4dMtbBjA4ioNlg== dependencies: base "^0.11.1" debug "^2.2.0" @@ -4574,10 +4566,11 @@ snapdragon@^0.8.1: use "^3.1.0" source-map-resolve@^0.5.0: - version "0.5.1" - resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.1.tgz#7ad0f593f2281598e854df80f19aae4b92d7a11a" + version "0.5.3" + resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.3.tgz#190866bece7553e1f8f267a2ee82c606b5509a1a" + integrity sha512-Htz+RnsXWk5+P2slx5Jh3Q66vhQj1Cllm0zvnaY98+NFx+Dv2CF/f5O/t8x+KaNdrdIAsruNzoh/KpialbqAnw== dependencies: - atob "^2.0.0" + atob "^2.1.2" decode-uri-component "^0.2.0" resolve-url "^0.2.1" source-map-url "^0.4.0" @@ -4592,62 +4585,74 @@ source-map-support@^0.5.16: source-map "^0.6.0" source-map-url@^0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.0.tgz#3e935d7ddd73631b97659956d55128e87b5084a3" + version "0.4.1" + resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.1.tgz#0af66605a745a5a2f91cf1bbf8a7afbc283dec56" + integrity sha512-cPiFOTLUKvJFIg4SKVScy4ilPPW6rFgMgfuZJPNoDuMs3nC1HbMUycBoJw77xFIp6z1UJQJOfx6C9GMH80DiTw== source-map@^0.5.0, source-map@^0.5.1, source-map@^0.5.6: version "0.5.7" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" + integrity sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w= -source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.1: +source-map@^0.6.0, source-map@^0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" + integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== source-map@~0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.2.0.tgz#dab73fbcfc2ba819b4de03bd6f6eaa48164b3f9d" + integrity sha1-2rc/vPwrqBm03gO9b26qSBZLP50= dependencies: amdefine ">=0.0.4" sparkles@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/sparkles/-/sparkles-1.0.0.tgz#1acbbfb592436d10bbe8f785b7cc6f82815012c3" + version "1.0.1" + resolved "https://registry.yarnpkg.com/sparkles/-/sparkles-1.0.1.tgz#008db65edce6c50eec0c5e228e1945061dd0437c" + integrity sha512-dSO0DDYUahUt/0/pD/Is3VIm5TGJjludZ0HVymmhYF6eNA53PVLhnUk0znSYbH8IYBuJdCE+1luR22jNLMaQdw== spdx-correct@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.1.0.tgz#fb83e504445268f154b074e218c87c003cd31df4" + version "3.1.1" + resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.1.1.tgz#dece81ac9c1e6713e5f7d1b6f17d468fa53d89a9" + integrity sha512-cOYcUWwhCuHCXi49RhFRCyJEK3iPj1Ziz9DpViV3tbZOwXD49QzIN3MpOLJNxh2qwq2lJJZaKMVw9qNi4jTC0w== dependencies: spdx-expression-parse "^3.0.0" spdx-license-ids "^3.0.0" spdx-exceptions@^2.1.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz#2ea450aee74f2a89bfb94519c07fcd6f41322977" + version "2.3.0" + resolved "https://registry.yarnpkg.com/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz#3f28ce1a77a00372683eade4a433183527a2163d" + integrity sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A== spdx-expression-parse@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz#99e119b7a5da00e05491c9fa338b7904823b41d0" + version "3.0.1" + resolved "https://registry.yarnpkg.com/spdx-expression-parse/-/spdx-expression-parse-3.0.1.tgz#cf70f50482eefdc98e3ce0a6833e4a53ceeba679" + integrity sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q== dependencies: spdx-exceptions "^2.1.0" spdx-license-ids "^3.0.0" spdx-license-ids@^3.0.0: - version "3.0.4" - resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.4.tgz#75ecd1a88de8c184ef015eafb51b5b48bfd11bb1" + version "3.0.7" + resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.7.tgz#e9c18a410e5ed7e12442a549fbd8afa767038d65" + integrity sha512-U+MTEOO0AiDzxwFvoa4JVnMV6mZlJKk2sBLt90s7G0Gd0Mlknc7kxEn3nuDPNZRta7O2uy8oLcZLVT+4sqNZHQ== split-string@^3.0.1, split-string@^3.0.2: version "3.1.0" resolved "https://registry.yarnpkg.com/split-string/-/split-string-3.1.0.tgz#7cb09dda3a86585705c64b39a6466038682e8fe2" + integrity sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw== dependencies: extend-shallow "^3.0.0" sprintf-js@~1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" + integrity sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw= sshpk@^1.7.0: version "1.16.1" resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.16.1.tgz#fb661c0bef29b39db40769ee39fa70093d6f6877" + integrity sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg== dependencies: asn1 "~0.2.3" assert-plus "^1.0.0" @@ -4662,10 +4667,12 @@ sshpk@^1.7.0: stack-trace@0.0.10: version "0.0.10" resolved "https://registry.yarnpkg.com/stack-trace/-/stack-trace-0.0.10.tgz#547c70b347e8d32b4e108ea1a2a159e5fdde19c0" + integrity sha1-VHxws0fo0ytOEI6hoqFZ5f3eGcA= static-extend@^0.1.1: version "0.1.2" resolved "https://registry.yarnpkg.com/static-extend/-/static-extend-0.1.2.tgz#60809c39cbff55337226fd5e0b520f341f1fb5c6" + integrity sha1-YICcOcv/VTNyJv1eC1IPNB8ftcY= dependencies: define-property "^0.2.5" object-copy "^0.1.0" @@ -4673,29 +4680,34 @@ static-extend@^0.1.1: stream-exhaust@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/stream-exhaust/-/stream-exhaust-1.0.2.tgz#acdac8da59ef2bc1e17a2c0ccf6c320d120e555d" + integrity sha512-b/qaq/GlBK5xaq1yrK9/zFcyRSTNxmcZwFLGSTG0mXgZl/4Z6GgiyYOXOvY7N3eEvFRAG1bkDRz5EPGSvPYQlw== stream-shift@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/stream-shift/-/stream-shift-1.0.0.tgz#d5c752825e5367e786f78e18e445ea223a155952" + version "1.0.1" + resolved "https://registry.yarnpkg.com/stream-shift/-/stream-shift-1.0.1.tgz#d7088281559ab2778424279b0877da3c392d5a3d" + integrity sha512-AiisoFqQ0vbGcZgQPY1cdP2I76glaVA/RauYR4G4thNFgkTqr90yXTo4LYX60Jl+sIlPNHHdGSwo01AvbKUSVQ== string-width@^1.0.1, string-width@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/string-width/-/string-width-1.0.2.tgz#118bdf5b8cdc51a2a7e70d211e07e2b0b9b107d3" + integrity sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M= dependencies: code-point-at "^1.0.0" is-fullwidth-code-point "^1.0.0" strip-ansi "^3.0.0" -"string-width@^1.0.2 || 2", string-width@^2.1.0, string-width@^2.1.1: +string-width@^2.1.0, string-width@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/string-width/-/string-width-2.1.1.tgz#ab93f27a8dc13d28cac815c462143a6d9012ae9e" + integrity sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw== dependencies: is-fullwidth-code-point "^2.0.0" strip-ansi "^4.0.0" string-width@^3.0.0: version "3.1.0" - resolved "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz#22767be21b62af1081574306f69ac51b62203961" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-3.1.0.tgz#22767be21b62af1081574306f69ac51b62203961" + integrity sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w== dependencies: emoji-regex "^7.0.1" is-fullwidth-code-point "^2.0.0" @@ -4710,33 +4722,31 @@ string-width@^4.1.0: is-fullwidth-code-point "^3.0.0" strip-ansi "^6.0.0" -string_decoder@~1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.0.3.tgz#0fc67d7c141825de94282dd536bec6b9bce860ab" - dependencies: - safe-buffer "~5.1.0" - string_decoder@~1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.1.1.tgz#9cf1611ba62685d7030ae9e4ba34149c3af03fc8" + integrity sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg== dependencies: safe-buffer "~5.1.0" strip-ansi@^3.0.0, strip-ansi@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf" + integrity sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8= dependencies: ansi-regex "^2.0.0" strip-ansi@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-4.0.0.tgz#a8479022eb1ac368a871389b635262c505ee368f" + integrity sha1-qEeQIusaw2iocTibY1JixQXuNo8= dependencies: ansi-regex "^3.0.0" strip-ansi@^5.1.0, strip-ansi@^5.2.0: version "5.2.0" - resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz#8c9a536feb6afc962bdfa5b104a5091c1ad9c0ae" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-5.2.0.tgz#8c9a536feb6afc962bdfa5b104a5091c1ad9c0ae" + integrity sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA== dependencies: ansi-regex "^4.1.0" @@ -4750,12 +4760,14 @@ strip-ansi@^6.0.0: strip-bom@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-2.0.0.tgz#6219a85616520491f35788bdbf1447a99c7e6b0e" + integrity sha1-YhmoVhZSBJHzV4i9vxRHqZx+aw4= dependencies: is-utf8 "^0.2.0" strip-eof@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz#bb43ff5598a6eb05d89b59fcd129c983313606bf" + resolved "https://registry.yarnpkg.com/strip-eof/-/strip-eof-1.0.0.tgz#bb43ff5598a6eb05d89b59fcd129c983313606bf" + integrity sha1-u0P/VZim6wXYm1n80SnJgzE2Br8= strip-json-comments@^3.0.1: version "3.1.1" @@ -4765,26 +4777,31 @@ strip-json-comments@^3.0.1: strip-json-comments@~2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" + integrity sha1-PFMZQukIwml8DsNEhYwobHygpgo= supports-color@5.4.0: version "5.4.0" - resolved "https://registry.npmjs.org/supports-color/-/supports-color-5.4.0.tgz#1c6b337402c2137605efe19f10fec390f6faab54" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.4.0.tgz#1c6b337402c2137605efe19f10fec390f6faab54" + integrity sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w== dependencies: has-flag "^3.0.0" supports-color@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7" + integrity sha1-U10EXOa2Nj+kARcIRimZXp3zJMc= supports-color@^3.1.0: version "3.2.3" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-3.2.3.tgz#65ac0504b3954171d8a64946b2ae3cbb8a5f54f6" + integrity sha1-ZawFBLOVQXHYpklGsq48u4pfVPY= dependencies: has-flag "^1.0.0" supports-color@^5.3.0, supports-color@^5.4.0, supports-color@^5.5.0: version "5.5.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" + integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== dependencies: has-flag "^3.0.0" @@ -4798,6 +4815,7 @@ supports-color@^7.1.0: sver-compat@^1.5.0: version "1.5.0" resolved "https://registry.yarnpkg.com/sver-compat/-/sver-compat-1.5.0.tgz#3cf87dfeb4d07b4a3f14827bc186b3fd0c645cd8" + integrity sha1-PPh9/rTQe0o/FIJ7wYaz/QxkXNg= dependencies: es6-iterator "^2.0.1" es6-symbol "^3.1.1" @@ -4805,6 +4823,7 @@ sver-compat@^1.5.0: table@4.0.2: version "4.0.2" resolved "https://registry.yarnpkg.com/table/-/table-4.0.2.tgz#a33447375391e766ad34d3486e6e2aedc84d2e36" + integrity sha512-UUkEAPdSGxtRpiV9ozJ5cMTtYiqz7Ni1OGqLXRCynrvzdtR1p+cfOWe2RJLwvUG8hNanaSRjecIqwOjqeatDsA== dependencies: ajv "^5.2.3" ajv-keywords "^2.1.0" @@ -4814,47 +4833,32 @@ table@4.0.2: string-width "^2.1.1" table@^5.2.3: - version "5.4.1" - resolved "https://registry.npmjs.org/table/-/table-5.4.1.tgz#0691ae2ebe8259858efb63e550b6d5f9300171e8" + version "5.4.6" + resolved "https://registry.yarnpkg.com/table/-/table-5.4.6.tgz#1292d19500ce3f86053b05f0e8e7e4a3bb21079e" + integrity sha512-wmEc8m4fjnob4gt5riFRtTu/6+4rSe12TpAELNSqHMfF3IqnA+CH37USM6/YR3qRZv7e56kAEAtd6nKZaxe0Ug== dependencies: - ajv "^6.9.1" - lodash "^4.17.11" + ajv "^6.10.2" + lodash "^4.17.14" slice-ansi "^2.1.0" string-width "^3.0.0" -tar@^4: - version "4.4.10" - resolved "https://registry.yarnpkg.com/tar/-/tar-4.4.10.tgz#946b2810b9a5e0b26140cf78bea6b0b0d689eba1" - dependencies: - chownr "^1.1.1" - fs-minipass "^1.2.5" - minipass "^2.3.5" - minizlib "^1.2.1" - mkdirp "^0.5.0" - safe-buffer "^5.1.2" - yallist "^3.0.3" - text-table@^0.2.0, text-table@~0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" + integrity sha1-f17oI66AUgfACvLfSoTsP8+lcLQ= through2-filter@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/through2-filter/-/through2-filter-3.0.0.tgz#700e786df2367c2c88cd8aa5be4cf9c1e7831254" + integrity sha512-jaRjI2WxN3W1V8/FMZ9HKIBXixtiqs3SQSX4/YGIiP3gL6djW48VoZq9tDqeCWs3MT8YY5wb/zli8VW8snY1CA== dependencies: through2 "~2.0.0" xtend "~4.0.0" -through2@^2.0.0, through2@^2.0.1: - version "2.0.3" - resolved "https://registry.yarnpkg.com/through2/-/through2-2.0.3.tgz#0004569b37c7c74ba39c43f3ced78d1ad94140be" - dependencies: - readable-stream "^2.1.5" - xtend "~4.0.1" - -through2@^2.0.3, through2@~2.0.0: +through2@^2.0.0, through2@^2.0.1, through2@^2.0.3, through2@~2.0.0: version "2.0.5" resolved "https://registry.yarnpkg.com/through2/-/through2-2.0.5.tgz#01c1e39eb31d07cb7d03a96a70823260b23132cd" + integrity sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ== dependencies: readable-stream "~2.3.6" xtend "~4.0.1" @@ -4862,20 +4866,24 @@ through2@^2.0.3, through2@~2.0.0: through@^2.3.6: version "2.3.8" resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" + integrity sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU= time-stamp@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/time-stamp/-/time-stamp-1.1.0.tgz#764a5a11af50561921b133f3b44e618687e0f5c3" + integrity sha1-dkpaEa9QVhkhsTPztE5hhofg9cM= tmp@^0.0.33: version "0.0.33" resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.0.33.tgz#6d34335889768d21b2bcda0aa277ced3b1bfadf9" + integrity sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw== dependencies: os-tmpdir "~1.0.2" to-absolute-glob@^2.0.0: version "2.0.2" resolved "https://registry.yarnpkg.com/to-absolute-glob/-/to-absolute-glob-2.0.2.tgz#1865f43d9e74b0822db9f145b78cff7d0f7c849b" + integrity sha1-GGX0PZ50sIItufFFt4z/fQ98hJs= dependencies: is-absolute "^1.0.0" is-negated-glob "^1.0.0" @@ -4883,16 +4891,19 @@ to-absolute-glob@^2.0.0: to-fast-properties@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz#dc5e698cbd079265bc73e0377681a4e4e83f616e" + integrity sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4= to-object-path@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/to-object-path/-/to-object-path-0.3.0.tgz#297588b7b0e7e0ac08e04e672f85c1f4999e17af" + integrity sha1-KXWIt7Dn4KwI4E5nL4XB9JmeF68= dependencies: kind-of "^3.0.2" to-regex-range@^2.1.0: version "2.1.1" resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-2.1.1.tgz#7c80c17b9dfebe599e27367e0d4dd5590141db38" + integrity sha1-fIDBe53+vlmeJzZ+DU3VWQFB2zg= dependencies: is-number "^3.0.0" repeat-string "^1.6.1" @@ -4900,6 +4911,7 @@ to-regex-range@^2.1.0: to-regex@^3.0.1, to-regex@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/to-regex/-/to-regex-3.0.2.tgz#13cfdd9b336552f30b51f33a8ae1b42a7a7599ce" + integrity sha512-FWtleNAtZ/Ki2qtqej2CXTOayOH9bHDQF+Q48VpWyDXjbYxA4Yz8iDB31zXOBUlOHHKidDbqGVrTUvQMPmBGBw== dependencies: define-property "^2.0.2" extend-shallow "^3.0.2" @@ -4909,52 +4921,46 @@ to-regex@^3.0.1, to-regex@^3.0.2: to-through@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/to-through/-/to-through-2.0.0.tgz#fc92adaba072647bc0b67d6b03664aa195093af6" + integrity sha1-/JKtq6ByZHvAtn1rA2ZKoZUJOvY= dependencies: through2 "^2.0.3" -tough-cookie@~2.4.3: - version "2.4.3" - resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.4.3.tgz#53f36da3f47783b0925afa06ff9f3b165280f781" - integrity sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ== +tough-cookie@~2.5.0: + version "2.5.0" + resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.5.0.tgz#cd9fb2a0aa1d5a12b473bd9fb96fa3dcff65ade2" + integrity sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g== dependencies: - psl "^1.1.24" - punycode "^1.4.1" - -trim-right@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/trim-right/-/trim-right-1.0.1.tgz#cb2e1203067e0c8de1f614094b9fe45704ea6003" + psl "^1.1.28" + punycode "^2.1.1" tslib@^1.9.0: - version "1.10.0" - resolved "https://registry.npmjs.org/tslib/-/tslib-1.10.0.tgz#c3c19f95973fb0a62973fb09d90d961ee43e5c8a" + version "1.14.1" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" + integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== tunnel-agent@^0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.6.0.tgz#27a5dea06b36b04a0a9966774b290868f0fc40fd" + integrity sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0= dependencies: safe-buffer "^5.0.1" tweetnacl@^0.14.3, tweetnacl@~0.14.0: version "0.14.5" resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64" + integrity sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q= type-check@~0.3.2: version "0.3.2" resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.3.2.tgz#5884cab512cf1d355e3fb784f30804b2b520db72" + integrity sha1-WITKtRLPHTVeP7eE8wgEsrUg23I= dependencies: prelude-ls "~1.1.2" -type-detect@0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-0.1.1.tgz#0ba5ec2a885640e470ea4e8505971900dac58822" - type-detect@4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c" - -type-detect@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-1.0.0.tgz#762217cc06db258ec48908a1298e8b95121e8ea2" + integrity sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g== type-fest@^0.21.3: version "0.21.3" @@ -4967,35 +4973,46 @@ type-fest@^0.8.1: integrity sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA== type@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/type/-/type-1.0.1.tgz#084c9a17fcc9151a2cdb1459905c2e45e4bb7d61" + version "1.2.0" + resolved "https://registry.yarnpkg.com/type/-/type-1.2.0.tgz#848dd7698dafa3e54a6c479e759c4bc3f18847a0" + integrity sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg== + +type@^2.0.0: + version "2.5.0" + resolved "https://registry.yarnpkg.com/type/-/type-2.5.0.tgz#0a2e78c2e77907b252abe5f298c1b01c63f0db3d" + integrity sha512-180WMDQaIMm3+7hGXWf12GtdniDEy7nYcyFMKJn/eZz/6tSLXrUN9V0wKSbMjej0I1WHWbpREDEKHtqPQa9NNw== typedarray@^0.0.6: version "0.0.6" resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" + integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c= uglify-js@^3.1.4: - version "3.10.3" - resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.10.3.tgz#f0d2f99736c14de46d2d24649ba328be3e71c3bf" - integrity sha512-Lh00i69Uf6G74mvYpHCI9KVVXLcHW/xu79YTvH7Mkc9zyKUeSPz0owW0dguj0Scavns3ZOh3wY63J0Zb97Za2g== + version "3.13.4" + resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.13.4.tgz#592588bb9f47ae03b24916e2471218d914955574" + integrity sha512-kv7fCkIXyQIilD5/yQy8O+uagsYIOt5cZvs890W40/e/rvjMSzJw81o9Bg0tkURxzZBROtDQhW2LFjOGoK3RZw== unc-path-regex@^0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/unc-path-regex/-/unc-path-regex-0.1.2.tgz#e73dd3d7b0d7c5ed86fbac6b0ae7d8c6a69d50fa" + integrity sha1-5z3T17DXxe2G+6xrCufYxqadUPo= undertaker-registry@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/undertaker-registry/-/undertaker-registry-1.0.1.tgz#5e4bda308e4a8a2ae584f9b9a4359a499825cc50" + integrity sha1-XkvaMI5KiirlhPm5pDWaSZglzFA= undertaker@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/undertaker/-/undertaker-1.2.1.tgz#701662ff8ce358715324dfd492a4f036055dfe4b" + version "1.3.0" + resolved "https://registry.yarnpkg.com/undertaker/-/undertaker-1.3.0.tgz#363a6e541f27954d5791d6fa3c1d321666f86d18" + integrity sha512-/RXwi5m/Mu3H6IHQGww3GNt1PNXlbeCuclF2QYR14L/2CHPz3DFZkvB5hZ0N/QUkiXWCACML2jXViIQEQc2MLg== dependencies: arr-flatten "^1.0.1" arr-map "^2.0.0" bach "^1.0.0" collection-map "^1.0.0" es6-weak-map "^2.0.1" + fast-levenshtein "^1.0.0" last-run "^1.1.0" object.defaults "^1.0.0" object.reduce "^1.0.0" @@ -5004,39 +5021,40 @@ undertaker@^1.2.1: unicode-canonical-property-names-ecmascript@^1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-1.0.4.tgz#2619800c4c825800efdd8343af7dd9933cbe2818" + integrity sha512-jDrNnXWHd4oHiTZnx/ZG7gtUTVp+gCcTTKr8L0HjlwphROEW3+Him+IpvC+xcJEFegapiMZyZe02CyuOnRmbnQ== unicode-match-property-ecmascript@^1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/unicode-match-property-ecmascript/-/unicode-match-property-ecmascript-1.0.4.tgz#8ed2a32569961bce9227d09cd3ffbb8fed5f020c" + integrity sha512-L4Qoh15vTfntsn4P1zqnHulG0LdXgjSO035fEpdtp6YxXhMT51Q6vgM5lYdG/5X3MjS+k/Y9Xw4SFCY9IkR0rg== dependencies: unicode-canonical-property-names-ecmascript "^1.0.4" unicode-property-aliases-ecmascript "^1.0.4" -unicode-match-property-value-ecmascript@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-1.1.0.tgz#5b4b426e08d13a80365e0d657ac7a6c1ec46a277" - unicode-match-property-value-ecmascript@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-1.2.0.tgz#0d91f600eeeb3096aa962b1d6fc88876e64ea531" integrity sha512-wjuQHGQVofmSJv1uVISKLE5zO2rNGzM/KCYZch/QQvez7C1hUhBIuZ701fYXExuufJFMPhv2SyL8CyoIfMLbIQ== unicode-property-aliases-ecmascript@^1.0.4: - version "1.0.5" - resolved "https://registry.yarnpkg.com/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-1.0.5.tgz#a9cc6cc7ce63a0a3023fc99e341b94431d405a57" + version "1.1.0" + resolved "https://registry.yarnpkg.com/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-1.1.0.tgz#dd57a99f6207bedff4628abefb94c50db941c8f4" + integrity sha512-PqSoPh/pWetQ2phoj5RLiaqIk4kCNwoV3CI+LfGmWLKI3rE3kl1h59XpX2BjgDrmbxD9ARtQobPGU1SguCYuQg== union-value@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/union-value/-/union-value-1.0.0.tgz#5c71c34cb5bad5dcebe3ea0cd08207ba5aa1aea4" + version "1.0.1" + resolved "https://registry.yarnpkg.com/union-value/-/union-value-1.0.1.tgz#0b6fe7b835aecda61c6ea4d4f02c14221e109847" + integrity sha512-tJfXmxMeWYnczCVs7XAEvIV7ieppALdyepWMkHkwciRpZraG/xwT+s2JN8+pr1+8jCRf80FFzvr+MpQeeoF4Xg== dependencies: arr-union "^3.1.0" get-value "^2.0.6" is-extendable "^0.1.1" - set-value "^0.4.3" + set-value "^2.0.1" unique-stream@^2.0.2: version "2.3.1" resolved "https://registry.yarnpkg.com/unique-stream/-/unique-stream-2.3.1.tgz#c65d110e9a4adf9a6c5948b28053d9a8d04cbeac" + integrity sha512-2nY4TnBE70yoxHkDli7DMazpWiP7xMdCYqU2nBRO0UB+ZpEkGsSija7MvmvnZFUeC+mrgiUfcHSr3LmRFIg4+A== dependencies: json-stable-stringify-without-jsonify "^1.0.1" through2-filter "^3.0.0" @@ -5044,53 +5062,59 @@ unique-stream@^2.0.2: unset-value@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/unset-value/-/unset-value-1.0.0.tgz#8376873f7d2335179ffb1e6fc3a8ed0dfc8ab559" + integrity sha1-g3aHP30jNRef+x5vw6jtDfyKtVk= dependencies: has-value "^0.3.1" isobject "^3.0.0" upath@^1.1.1: - version "1.1.2" - resolved "https://registry.yarnpkg.com/upath/-/upath-1.1.2.tgz#3db658600edaeeccbe6db5e684d67ee8c2acd068" + version "1.2.0" + resolved "https://registry.yarnpkg.com/upath/-/upath-1.2.0.tgz#8f66dbcd55a883acdae4408af8b035a5044c1894" + integrity sha512-aZwGpamFO61g3OlfT7OQCHqhGnW43ieH9WZeP7QxN/G/jS4jfqUkZxoryvJgVPEcrl5NL/ggHsSmLMHuH64Lhg== uri-js@^4.2.2: - version "4.2.2" - resolved "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz#94c540e1ff772956e2299507c010aea6c8838eb0" + version "4.4.1" + resolved "https://registry.yarnpkg.com/uri-js/-/uri-js-4.4.1.tgz#9b1a52595225859e55f669d928f88c6c57f2a77e" + integrity sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg== dependencies: punycode "^2.1.0" urix@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/urix/-/urix-0.1.0.tgz#da937f7a62e21fec1fd18d49b35c2935067a6c72" + integrity sha1-2pN/emLiH+wf0Y1Js1wpNQZ6bHI= use@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/use/-/use-3.1.0.tgz#14716bf03fdfefd03040aef58d8b4b85f3a7c544" - dependencies: - kind-of "^6.0.2" + version "3.1.1" + resolved "https://registry.yarnpkg.com/use/-/use-3.1.1.tgz#d50c8cac79a19fbc20f2911f56eb973f4e10070f" + integrity sha512-cwESVXlO3url9YWlFW/TA9cshCEhtu7IKJ/p5soJ/gGpj7vbvFrAY/eIioQ6Dw23KjZhYgiIo8HOs1nQ2vr/oQ== util-deprecate@~1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" + integrity sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8= uuid@^3.3.2: - version "3.3.2" - resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.3.2.tgz#1b4af4955eb3077c501c23872fc6513811587131" - integrity sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA== + version "3.4.0" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.4.0.tgz#b23e4358afa8a202fe7a100af1f5f883f02007ee" + integrity sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A== v8-compile-cache@^2.0.3: version "2.3.0" resolved "https://registry.yarnpkg.com/v8-compile-cache/-/v8-compile-cache-2.3.0.tgz#2de19618c66dc247dcfb6f99338035d8245a2cee" integrity sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA== -v8flags@^3.0.1: - version "3.1.3" - resolved "https://registry.yarnpkg.com/v8flags/-/v8flags-3.1.3.tgz#fc9dc23521ca20c5433f81cc4eb9b3033bb105d8" +v8flags@^3.2.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/v8flags/-/v8flags-3.2.0.tgz#b243e3b4dfd731fa774e7492128109a0fe66d656" + integrity sha512-mH8etigqMfiGWdeXpaaqGfs6BndypxusHHcv2qSHyZkGEznCd/qAXCWWRzeowtL54147cktFOC4P5y+kl8d8Jg== dependencies: homedir-polyfill "^1.0.1" validate-npm-package-license@^3.0.1: version "3.0.4" resolved "https://registry.yarnpkg.com/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz#fc91f6b9c7ba15c857f4cb2c5defeec39d4f410a" + integrity sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew== dependencies: spdx-correct "^3.0.0" spdx-expression-parse "^3.0.0" @@ -5098,10 +5122,12 @@ validate-npm-package-license@^3.0.1: value-or-function@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/value-or-function/-/value-or-function-3.0.0.tgz#1c243a50b595c1be54a754bfece8563b9ff8d813" + integrity sha1-HCQ6ULWVwb5Up1S/7OhWO5/42BM= verror@1.10.0: version "1.10.0" resolved "https://registry.yarnpkg.com/verror/-/verror-1.10.0.tgz#3a105ca17053af55d6e270c1f8288682e18da400" + integrity sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA= dependencies: assert-plus "^1.0.0" core-util-is "1.0.2" @@ -5110,6 +5136,7 @@ verror@1.10.0: vinyl-fs@^3.0.0: version "3.0.3" resolved "https://registry.yarnpkg.com/vinyl-fs/-/vinyl-fs-3.0.3.tgz#c85849405f67428feabbbd5c5dbdd64f47d31bc7" + integrity sha512-vIu34EkyNyJxmP0jscNzWBSygh7VWhqun6RmqVfXePrOwi9lhvRs//dOaGOTRUQr4tx7/zd26Tk5WeSVZitgng== dependencies: fs-mkdirp-stream "^1.0.0" glob-stream "^6.1.0" @@ -5132,6 +5159,7 @@ vinyl-fs@^3.0.0: vinyl-sourcemap@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/vinyl-sourcemap/-/vinyl-sourcemap-1.1.0.tgz#92a800593a38703a8cdb11d8b300ad4be63b3e16" + integrity sha1-kqgAWTo4cDqM2xHYswCtS+Y7PhY= dependencies: append-buffer "^1.0.2" convert-source-map "^1.5.0" @@ -5144,12 +5172,14 @@ vinyl-sourcemap@^1.1.0: vinyl-sourcemaps-apply@^0.2.0, vinyl-sourcemaps-apply@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/vinyl-sourcemaps-apply/-/vinyl-sourcemaps-apply-0.2.1.tgz#ab6549d61d172c2b1b87be5c508d239c8ef87705" + integrity sha1-q2VJ1h0XLCsbh75cUI0jnI74dwU= dependencies: source-map "^0.5.1" vinyl@^2.0.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-2.2.0.tgz#d85b07da96e458d25b2ffe19fece9f2caa13ed86" + version "2.2.1" + resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-2.2.1.tgz#23cfb8bbab5ece3803aa2c0a1eb28af7cbba1974" + integrity sha512-LII3bXRFBZLlezoG5FfZVcXflZgWP/4dCwKtxd5ky9+LOtM4CS3bIRQsmR1KMnMW07jpE8fqR2lcxPZ+8sJIcw== dependencies: clone "^2.1.1" clone-buffer "^1.0.0" @@ -5161,37 +5191,29 @@ vinyl@^2.0.0: which-module@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/which-module/-/which-module-1.0.0.tgz#bba63ca861948994ff307736089e3b96026c2a4f" + integrity sha1-u6Y8qGGUiZT/MHc2CJ47lgJsKk8= -which@^1.1.1, which@^1.2.14: - version "1.3.0" - resolved "https://registry.yarnpkg.com/which/-/which-1.3.0.tgz#ff04bdfc010ee547d780bec38e1ac1c2777d253a" - dependencies: - isexe "^2.0.0" - -which@^1.2.9: +which@^1.1.1, which@^1.2.14, which@^1.2.9: version "1.3.1" resolved "https://registry.yarnpkg.com/which/-/which-1.3.1.tgz#a45043d54f5805316da8d62f9f50918d3da70b0a" + integrity sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ== dependencies: isexe "^2.0.0" -wide-align@^1.1.0: - version "1.1.3" - resolved "https://registry.yarnpkg.com/wide-align/-/wide-align-1.1.3.tgz#ae074e6bdc0c14a431e804e624549c633b000457" - dependencies: - string-width "^1.0.2 || 2" - word-wrap@~1.2.3: version "1.2.3" resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c" integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ== -wordwrap@^1.0.0, wordwrap@~1.0.0: +wordwrap@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" + integrity sha1-J1hIEIkUVqQXHI0CJkQa3pDLyus= wrap-ansi@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-2.1.0.tgz#d8fc3d284dd05794fe84973caecdd1cf824fdd85" + integrity sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU= dependencies: string-width "^1.0.1" strip-ansi "^3.0.1" @@ -5199,44 +5221,49 @@ wrap-ansi@^2.0.0: wrappy@1: version "1.0.2" resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" + integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= write@1.0.3: version "1.0.3" - resolved "https://registry.npmjs.org/write/-/write-1.0.3.tgz#0800e14523b923a387e415123c865616aae0f5c3" + resolved "https://registry.yarnpkg.com/write/-/write-1.0.3.tgz#0800e14523b923a387e415123c865616aae0f5c3" + integrity sha512-/lg70HAjtkUgWPVZhZcm+T4hkL8Zbtp1nFNOn3lRrxnlv50SRBv7cR7RqR+GMsd3hUXy9hWBo4CHTbFTcOYwig== dependencies: mkdirp "^0.5.1" write@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/write/-/write-0.2.1.tgz#5fc03828e264cea3fe91455476f7a3c566cb0757" + integrity sha1-X8A4KOJkzqP+kUVUdvejxWbLB1c= dependencies: mkdirp "^0.5.1" xtend@~4.0.0, xtend@~4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.1.tgz#a5c6d532be656e23db820efb943a1f04998d63af" + version "4.0.2" + resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" + integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== y18n@^3.2.1: - version "3.2.1" - resolved "https://registry.yarnpkg.com/y18n/-/y18n-3.2.1.tgz#6d15fba884c08679c0d77e88e7759e811e07fa41" + version "3.2.2" + resolved "https://registry.yarnpkg.com/y18n/-/y18n-3.2.2.tgz#85c901bd6470ce71fc4bb723ad209b70f7f28696" + integrity sha512-uGZHXkHnhF0XeeAPgnKfPv1bgKAYyVvmNL1xlKsPYZPaIHxGti2hHqvOCQv71XMsLxu1QjergkqogUnms5D3YQ== yallist@^2.1.2: version "2.1.2" resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz#1c11f9218f076089a47dd512f93c6699a6a81d52" + integrity sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI= -yallist@^3.0.0, yallist@^3.0.3: - version "3.0.3" - resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.0.3.tgz#b4b049e314be545e3ce802236d6cd22cd91c3de9" - -yargs-parser@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-5.0.0.tgz#275ecf0d7ffe05c77e64e7c86e4cd94bf0e1228a" +yargs-parser@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-5.0.1.tgz#7ede329c1d8cdbbe209bd25cdb990e9b1ebbb394" + integrity sha512-wpav5XYiddjXxirPoCTUPbqM0PXvJ9hiBMvuJgInvo4/lAOTZzUprArw17q2O1P2+GHhbBr18/iQwjL5Z9BqfA== dependencies: camelcase "^3.0.0" + object.assign "^4.1.0" yargs@^7.1.0: - version "7.1.0" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-7.1.0.tgz#6ba318eb16961727f5d284f8ea003e8d6154d0c8" + version "7.1.2" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-7.1.2.tgz#63a0a5d42143879fdbb30370741374e0641d55db" + integrity sha512-ZEjj/dQYQy0Zx0lgLMLR8QuaqTihnxirir7EwUHp1Axq4e3+k8jXU5K0VLbNvedv1f4EWtBonDIZm0NUr+jCcA== dependencies: camelcase "^3.0.0" cliui "^3.2.0" @@ -5250,4 +5277,4 @@ yargs@^7.1.0: string-width "^1.0.2" which-module "^1.0.0" y18n "^3.2.1" - yargs-parser "^5.0.0" + yargs-parser "^5.0.1" From fab0e1e2b5ead89ad6960fb4cbe3924ba878d6ea Mon Sep 17 00:00:00 2001 From: Johnny Nader Date: Mon, 3 May 2021 18:24:56 +0100 Subject: [PATCH 025/146] bump version to 2.11.1 --- README.md | 47 +++++++++++++++++++++++------------------------ package.json | 3 ++- 2 files changed, 25 insertions(+), 25 deletions(-) diff --git a/README.md b/README.md index d6aa3c72..148e4c46 100644 --- a/README.md +++ b/README.md @@ -1,21 +1,25 @@ # intercom-node -> Official Node bindings to the Intercom API -[![Circle CI](https://circleci.com/gh/intercom/intercom-node.png?style=badge)](https://circleci.com/gh/intercom/intercom-node) +[![Circle CI](https://circleci.com/gh/intercom/intercom-node.png?style=shield)](https://circleci.com/gh/intercom/intercom-node) +[![npm](https://img.shields.io/npm/v/intercom-client)](https://www.npmjs.com/package/intercom-client) +![Intercom API Version](https://img.shields.io/badge/Intercom%20API%20Version-1.3-blue) -[![npm version](https://badge.fury.io/js/intercom-client.svg)](http://badge.fury.io/js/intercom-client) +> Official Node bindings to the [Intercom API](https://api.intercom.io/docs) -### Excluding Customer Search (2.0), only supports 1.X +## Project Updates -## Installation +### Maintenance + +We're currently building a new team to provide in-depth and dedicated SDK support. + +In the meantime, we'll be operating on limited capacity, meaning all pull requests will be evaluated on a best effort basis and will be limited to critical issues. -[![docker_image 1](https://cloud.githubusercontent.com/assets/15954251/17524401/5743439e-5e56-11e6-8567-d3d9da1727da.png)](https://hub.docker.com/r/intercom/sdk-images/)
-Try out our [Docker Image (Beta)](https://hub.docker.com/r/intercom/sdk-images/) to help you get started more quickly.
-It should make it easier to get setup with the SDK and start interacting with the API.
-(Note, this is in Beta and is for testing purposes only, it should not be used in production) +We'll communicate all relevant updates as we build this new team and support strategy in the coming months. + +## Installation ```bash -npm install intercom-client +yarn add intercom-client ``` **This client is intended for server side use only. Please use the [Intercom Javascript SDK](https://developers.intercom.com/v2.0/docs/intercom-javascript) for client-side operations.** @@ -23,7 +27,7 @@ npm install intercom-client ## Testing ```bash -npm test +yarn test ``` ## Running the code locally @@ -31,7 +35,7 @@ npm test Compile using babel: ```bash -gulp babel +yarn gulp babel ``` Require Intercom: @@ -48,8 +52,7 @@ Require Intercom: var Intercom = require('intercom-client'); ``` -Create a client: -#### Using Access Tokens +Create a client using access tokens: ```node var client = new Intercom.Client({ token: 'my_token' }); @@ -63,9 +66,11 @@ This client library supports two kinds of callbacks: client.users.list(function (d) { // d is the response from the server }); +``` -// Or +Or +```node client.users.list(function (err, d) { // err is an error response object, or null // d is a successful response object, or null @@ -97,7 +102,7 @@ client.useRequestOpts({ Note that certain request options (such as `json`, and certain `headers` names cannot be overriden). -#### Setting the API version +### Setting the API version We version our API (see the "Choose Version" section of the [API & Webhooks Reference](https://developers.intercom.com/intercom-api-reference/reference) for details). You can specify which version of the API to use when performing API requests using request options: @@ -238,7 +243,6 @@ client.leads.scroll.each({}, function(res) { client.leads.listBy({ email: 'wash@serenity.io' }, callback); ``` - ```node // Find contact by id client.leads.find({ id: '5342423' }, callback); @@ -306,7 +310,6 @@ var conversion = { client.visitors.convert(conversion, callback); ``` - ## Companies ```node @@ -341,7 +344,6 @@ client.companies.scroll.each({}, function(res) { }); ``` - ```node // Find company by id client.companies.find({ id: '1234' }, callback); @@ -353,7 +355,6 @@ client.companies.listUsers({ id: '1234' }, callback); client.companies.listUsers({ company_id: '1234' }, callback); ``` - ## Events Note: events will work when identified by 'email'. The `event_name` and `created_at` params are both required. Either `user_id` OR `email` is required. @@ -410,12 +411,12 @@ client.admins.list(callback); client.admins.me(callback); ``` -``` +```node // Find admin by ID client.admins.find('123456789', callback); ``` -``` +```node // Update admin away mode and reassign settings client.admins.away('123456789', {'away_mode_enabled': true, 'away_mode_reassign': false}, callback); ``` @@ -508,7 +509,6 @@ Listing conversations ([documentation](https://developers.intercom.com/intercom- client.conversations.list({ type: 'admin', admin_id: 21599 }, callback); ``` - ```node // Fetch a conversation client.conversations.find({ id: '1062682196' }, callback); @@ -625,7 +625,6 @@ IdentityVerification.userHash({secretKey: 's3cre7', identifier: 'jayne@serenity. Apache-2.0 - ## Pull Requests - **Add tests!** Your patch won't be accepted if it doesn't have tests. diff --git a/package.json b/package.json index 446a2732..4331c8b6 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "2.11.0", + "version": "2.11.1", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", @@ -31,6 +31,7 @@ "eslint": "^6.8.0", "gulp": "^4.0.2", "gulp-babel": "^8.0.0", + "gulp-cli": "^2.2.0", "gulp-eslint": "4.0.2", "gulp-exclude-gitignore": "^1.0.0", "gulp-istanbul": "^1.1.3", From 9a8fc6167d1fb82435d011039249494f8f6161a2 Mon Sep 17 00:00:00 2001 From: Johnny Nader Date: Tue, 4 May 2021 20:22:17 +0100 Subject: [PATCH 026/146] bump to released version 2.11.2 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 4331c8b6..31354e3b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "2.11.1", + "version": "2.11.2", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", From 050eed22d5ed2407cf679b7acdb8baec0d2bc200 Mon Sep 17 00:00:00 2001 From: Brian Fletcher Date: Mon, 18 Oct 2021 18:23:23 +0100 Subject: [PATCH 027/146] Document how to configure api.eu.intercom.io closes #285 --- README.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/README.md b/README.md index 148e4c46..acbb7ddf 100644 --- a/README.md +++ b/README.md @@ -58,6 +58,13 @@ Create a client using access tokens: var client = new Intercom.Client({ token: 'my_token' }); ``` +If you are using the EU service you can configure like the following: + +```node +var client = new Intercom.Client({token: 'my_token' }); +client.useRequestOpts({ baseUrl: 'https://api.eu.intercom.io' }) +``` + ## Callbacks This client library supports two kinds of callbacks: From 8beed561c0e65497d0032bfad6d6a18caf9eab1d Mon Sep 17 00:00:00 2001 From: Brian Fletcher Date: Wed, 12 Jan 2022 11:25:06 +0000 Subject: [PATCH 028/146] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index acbb7ddf..9f5c1c36 100644 --- a/README.md +++ b/README.md @@ -61,7 +61,7 @@ var client = new Intercom.Client({ token: 'my_token' }); If you are using the EU service you can configure like the following: ```node -var client = new Intercom.Client({token: 'my_token' }); +var client = new Intercom.Client({ token: 'my_token' }); client.useRequestOpts({ baseUrl: 'https://api.eu.intercom.io' }) ``` From 8e4f74acd6f8f9a9498edc0df861823f55c29b12 Mon Sep 17 00:00:00 2001 From: Volodymyr V <14982064+hypeofpipe@users.noreply.github.com> Date: Fri, 28 Jan 2022 16:41:31 +0100 Subject: [PATCH 029/146] Release v3.0.0 of the SDK --- .babelrc | 3 - .circleci/config.yml | 44 +- .editorconfig | 13 +- .eslintignore | 3 + .eslintrc | 213 +- .github/ISSUE_TEMPLATE.md | 13 +- .github/PULL_REQUEST_TEMPLATE.md | 6 + .gitignore | 30 +- .npmignore | 2 + .nycrc | 17 + .prettierignore | 3 + .prettierrc.json | 8 + .vscode/settings.json | 4 + .yarn/releases/yarn-3.1.1.cjs | 768 ++ .yarnrc.yml | 3 + README.md | 1267 +++- gulpfile.js | 47 - lib/admin.js | 17 - lib/admin.ts | 82 + lib/admin/admin.types.ts | 12 + lib/article.ts | 119 + lib/article/article.types.ts | 92 + lib/bulk.js | 26 - lib/client.js | 172 - lib/client.ts | 279 + lib/common/common.types.ts | 121 + lib/company.js | 38 - lib/company.ts | 198 + lib/company/company.types.ts | 39 + lib/contact.js | 40 - lib/contact.ts | 334 + lib/contact/contact.types.ts | 83 + lib/conversation.js | 17 - lib/conversation.ts | 549 ++ lib/conversation/conversation.types.ts | 163 + lib/counts.js | 29 - lib/customer.js | 8 - lib/dataAttribute.ts | 82 + lib/dataAttribute/dataAttribute.types.ts | 34 + lib/errors/badResponse.error.ts | 15 + lib/event.js | 16 - lib/event.ts | 87 + lib/event/event.types.ts | 29 + lib/helpCenter.ts | 171 + lib/helpCenter/helpCenter.types.ts | 37 + lib/index.js | 23 - lib/index.ts | 57 + lib/message.js | 8 - lib/message.ts | 57 + lib/message/message.types.ts | 18 + lib/note.js | 14 - lib/scroll.js | 49 - lib/scroll.ts | 67 + lib/segment.js | 11 - lib/segment.ts | 39 + lib/segment/segment.types.ts | 11 + lib/snippet.js | 79 - lib/subscription/subscription.types.ts | 20 + lib/tag.js | 26 - lib/tag.ts | 142 + lib/tag/tag.types.ts | 5 + lib/team.ts | 31 + lib/team/team.types.ts | 6 + lib/user-data.js | 62 - lib/user.js | 64 - lib/util/time.ts | 3 + lib/util/url.ts | 10 + lib/visitor.js | 21 - package.json | 106 +- test/admin.js | 38 - test/admin.ts | 64 + test/article.ts | 113 + test/bulk.js | 62 - test/client.js | 76 - test/client.ts | 69 + test/company.js | 78 - test/company.ts | 260 + test/contact.js | 87 - test/contact.ts | 361 + test/conversation.js | 38 - test/conversation.ts | 598 ++ test/counts.js | 70 - test/customer.js | 14 - test/dataAttribute.ts | 70 + test/errors.js | 252 - test/errors.ts | 109 + test/event.js | 26 - test/event.ts | 65 + test/helpCenter.ts | 181 + test/index.js | 26 - test/index.ts | 39 + test/message.js | 14 - test/message.ts | 42 + test/note.js | 30 - test/request-opts.js | 85 - test/request-opts.ts | 88 + test/scroll.js | 70 - test/segment.js | 22 - test/segment.ts | 43 + test/snippet.js | 108 - test/tag.js | 54 - test/tag.ts | 175 + test/team.ts | 33 + test/user-data.js | 166 - test/user.js | 180 - test/visitor.js | 63 - tsconfig.json | 30 + yarn.lock | 8868 +++++++++------------- 108 files changed, 10758 insertions(+), 8271 deletions(-) delete mode 100644 .babelrc create mode 100644 .eslintignore create mode 100644 .npmignore create mode 100644 .nycrc create mode 100644 .prettierignore create mode 100644 .prettierrc.json create mode 100644 .vscode/settings.json create mode 100755 .yarn/releases/yarn-3.1.1.cjs create mode 100644 .yarnrc.yml delete mode 100644 gulpfile.js delete mode 100644 lib/admin.js create mode 100644 lib/admin.ts create mode 100644 lib/admin/admin.types.ts create mode 100644 lib/article.ts create mode 100644 lib/article/article.types.ts delete mode 100644 lib/bulk.js delete mode 100644 lib/client.js create mode 100644 lib/client.ts create mode 100644 lib/common/common.types.ts delete mode 100644 lib/company.js create mode 100644 lib/company.ts create mode 100644 lib/company/company.types.ts delete mode 100644 lib/contact.js create mode 100644 lib/contact.ts create mode 100644 lib/contact/contact.types.ts delete mode 100644 lib/conversation.js create mode 100644 lib/conversation.ts create mode 100644 lib/conversation/conversation.types.ts delete mode 100644 lib/counts.js delete mode 100644 lib/customer.js create mode 100644 lib/dataAttribute.ts create mode 100644 lib/dataAttribute/dataAttribute.types.ts create mode 100644 lib/errors/badResponse.error.ts delete mode 100644 lib/event.js create mode 100644 lib/event.ts create mode 100644 lib/event/event.types.ts create mode 100644 lib/helpCenter.ts create mode 100644 lib/helpCenter/helpCenter.types.ts delete mode 100644 lib/index.js create mode 100644 lib/index.ts delete mode 100644 lib/message.js create mode 100644 lib/message.ts create mode 100644 lib/message/message.types.ts delete mode 100644 lib/note.js delete mode 100644 lib/scroll.js create mode 100644 lib/scroll.ts delete mode 100644 lib/segment.js create mode 100644 lib/segment.ts create mode 100644 lib/segment/segment.types.ts delete mode 100644 lib/snippet.js create mode 100644 lib/subscription/subscription.types.ts delete mode 100644 lib/tag.js create mode 100644 lib/tag.ts create mode 100644 lib/tag/tag.types.ts create mode 100644 lib/team.ts create mode 100644 lib/team/team.types.ts delete mode 100644 lib/user-data.js delete mode 100644 lib/user.js create mode 100644 lib/util/time.ts create mode 100644 lib/util/url.ts delete mode 100644 lib/visitor.js delete mode 100644 test/admin.js create mode 100644 test/admin.ts create mode 100644 test/article.ts delete mode 100644 test/bulk.js delete mode 100644 test/client.js create mode 100644 test/client.ts delete mode 100644 test/company.js create mode 100644 test/company.ts delete mode 100644 test/contact.js create mode 100644 test/contact.ts delete mode 100644 test/conversation.js create mode 100644 test/conversation.ts delete mode 100644 test/counts.js delete mode 100644 test/customer.js create mode 100644 test/dataAttribute.ts delete mode 100644 test/errors.js create mode 100644 test/errors.ts delete mode 100644 test/event.js create mode 100644 test/event.ts create mode 100644 test/helpCenter.ts delete mode 100644 test/index.js create mode 100644 test/index.ts delete mode 100644 test/message.js create mode 100644 test/message.ts delete mode 100644 test/note.js delete mode 100644 test/request-opts.js create mode 100644 test/request-opts.ts delete mode 100644 test/scroll.js delete mode 100644 test/segment.js create mode 100644 test/segment.ts delete mode 100644 test/snippet.js delete mode 100644 test/tag.js create mode 100644 test/tag.ts create mode 100644 test/team.ts delete mode 100644 test/user-data.js delete mode 100644 test/user.js delete mode 100644 test/visitor.js create mode 100644 tsconfig.json diff --git a/.babelrc b/.babelrc deleted file mode 100644 index 1320b9a3..00000000 --- a/.babelrc +++ /dev/null @@ -1,3 +0,0 @@ -{ - "presets": ["@babel/preset-env"] -} diff --git a/.circleci/config.yml b/.circleci/config.yml index da34410c..6a07a9f2 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1,29 +1,29 @@ version: 2 jobs: - build: - docker: - - image: circleci/node:14-browsers + build: + docker: + - image: circleci/node:14-browsers - working_directory: ~/intercom-node + working_directory: ~/intercom-node - environment: - - YARN_VERSION: 1.22.10 + environment: + - YARN_VERSION: 1.22.10 - steps: - - checkout - - run: export PATH="${PATH}:/home/circleci/.yarn/bin" - - run: - name: Install Yarn - command: | - if [[ ! -e ~/.yarn/bin/yarn || $(yarn --version) != "${YARN_VERSION}" ]]; then - echo "Download and install Yarn." - curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version $YARN_VERSION - else - echo "The correct version of Yarn is already installed." - fi - - run: yarn - - run: yarn test + steps: + - checkout + - run: export PATH="${PATH}:/home/circleci/.yarn/bin" + - run: + name: Install Yarn + command: | + if [[ ! -e ~/.yarn/bin/yarn || $(yarn --version) != "${YARN_VERSION}" ]]; then + echo "Download and install Yarn." + curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version $YARN_VERSION + else + echo "The correct version of Yarn is already installed." + fi + - run: yarn + - run: yarn test notify: - webhooks: - - url: https://muster.intercom.io/circle_webhooks + webhooks: + - url: https://muster.intercom.io/circle_webhooks diff --git a/.editorconfig b/.editorconfig index beffa308..ec7cea79 100644 --- a/.editorconfig +++ b/.editorconfig @@ -1,11 +1,16 @@ root = true [*] -indent_style = space -indent_size = 2 -charset = utf-8 -trim_trailing_whitespace = true +end_of_line = lf insert_final_newline = true +trim_trailing_whitespace = true +charset = utf-8 +indent_style = space +indent_size = 4 [*.md] trim_trailing_whitespace = false + +[*.{json,yml}] +indent_style = space +indent_size = 2 diff --git a/.eslintignore b/.eslintignore new file mode 100644 index 00000000..b354c747 --- /dev/null +++ b/.eslintignore @@ -0,0 +1,3 @@ +# Temporary workaround for Gulp's ESLint +dist/ +node_modules/ diff --git a/.eslintrc b/.eslintrc index ead4b94d..2c36b550 100644 --- a/.eslintrc +++ b/.eslintrc @@ -1,173 +1,44 @@ { - "parser": "babel-eslint", - "rules": { - "strict": [ - 2, - "global" - ], - "quotes": [ - 2, - "single" - ], - "indent": [ - 2, - 2 - ], - "one-var": [ - 2, - "never" - ], - "consistent-return": 0, - "no-use-before-define": [ - 2, - "nofunc" - ], - "space-before-function-paren": [ - 2, - { - "anonymous": "always", - "named": "never" - } - ], - "keyword-spacing": 2, - "array-bracket-spacing": [ - 2, - "never" - ], - "space-in-parens": [ - 2, - "never" - ], - "quote-props": [ - 2, - "as-needed" - ], - "no-multiple-empty-lines": [ - 2, - { - "max": 2 - } - ], - "brace-style": [ - 2, - "1tbs" - ], - "curly": [ - 2, - "all" - ], - "key-spacing": [ - 2, - { - "beforeColon": false, - "afterColon": true - } - ], - "space-infix-ops": 2, - "no-eval": 2, - "no-with": 2, - "eol-last": 2, - "comma-dangle": [ - 2, - "never" - ], - "no-cond-assign": 2, - "no-constant-condition": 2, - "no-control-regex": 2, - "no-debugger": 2, - "no-dupe-args": 2, - "no-dupe-keys": 2, - "no-duplicate-case": 2, - "no-empty-character-class": 2, - "no-empty": 2, - "no-ex-assign": 2, - "no-extra-boolean-cast": 2, - "no-extra-semi": 2, - "no-func-assign": 2, - "no-inner-declarations": [ - 2, - "functions" - ], - "no-invalid-regexp": 2, - "no-irregular-whitespace": 2, - "no-negated-in-lhs": 2, - "no-obj-calls": 2, - "no-regex-spaces": 2, - "no-sparse-arrays": 2, - "no-unreachable": 2, - "use-isnan": 2, - "valid-typeof": 2, - "dot-notation": [ - 2, - { - "allowKeywords": true - } - ], - "eqeqeq": 2, - "no-alert": 2, - "no-caller": 2, - "no-extend-native": 2, - "no-extra-bind": 2, - "no-fallthrough": 2, - "no-implied-eval": 2, - "no-iterator": 2, - "no-labels": 2, - "no-lone-blocks": 2, - "no-loop-func": 2, - "no-multi-spaces": 2, - "no-multi-str": 2, - "no-native-reassign": 2, - "no-new-func": 2, - "no-new-wrappers": 2, - "no-new": 2, - "no-octal-escape": 2, - "no-octal": 2, - "no-proto": 2, - "no-redeclare": 2, - "no-return-assign": 2, - "no-script-url": 2, - "no-sequences": 2, - "no-unused-expressions": 2, - "yoda": 2, - "no-delete-var": 2, - "no-label-var": 2, - "no-shadow-restricted-names": 2, - "no-shadow": 2, - "no-undef-init": 2, - "no-undef": 2, - "no-unused-vars": [ - 2, - { - "vars": "all", - "args": "after-used" - } - ], - "camelcase": 0, - "comma-spacing": 2, - "new-cap": 2, - "new-parens": 2, - "no-array-constructor": 2, - "no-mixed-spaces-and-tabs": [ - 2, - false - ], - "no-new-object": 2, - "no-spaced-func": 2, - "no-trailing-spaces": 2, - "no-underscore-dangle": 2, - "no-extra-parens": 2, - "semi-spacing": [ - 2, - { - "before": false, - "after": true - } - ], - "semi": 2 - }, - "env": { - "node": true, - "mocha": true, - "es6": true - } + "root": true, + "parser": "@typescript-eslint/parser", + "plugins": ["@typescript-eslint"], + "rules": { + "keyword-spacing": 2, + "array-bracket-spacing": [2, "never"], + "space-in-parens": [2, "never"], + "no-multiple-empty-lines": [ + 2, + { + "max": 2 + } + ], + "no-eval": 2, + "no-with": 2, + "no-debugger": 2, + "no-dupe-args": 2, + "no-dupe-keys": 2, + "no-duplicate-case": 2, + "no-empty-character-class": 2, + "no-empty": 2, + "no-ex-assign": 2, + "no-extra-boolean-cast": 2, + "no-extra-semi": 2, + "no-func-assign": 2, + "no-inner-declarations": [2, "functions"], + "no-invalid-regexp": 2, + "no-irregular-whitespace": 2, + "no-negated-in-lhs": 2, + "no-obj-calls": 2, + "no-regex-spaces": 2, + "no-sparse-arrays": 2, + "no-unreachable": 2, + "use-isnan": 2, + "valid-typeof": 2 + }, + "extends": [ + "eslint:recommended", + "plugin:@typescript-eslint/eslint-recommended", + "plugin:@typescript-eslint/recommended", + "prettier" + ] } diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md index 3df6e90b..bb13692e 100644 --- a/.github/ISSUE_TEMPLATE.md +++ b/.github/ISSUE_TEMPLATE.md @@ -2,18 +2,19 @@ Please use the following template to submit your issue. Following this template For feature requests please contact us at team@intercom.io - ## Version info - - intercom-node version: - - Node version: + +- intercom-node version: +- Node version: ## Expected behavior ## Actual behavior ## Steps to reproduce - 1. - 2. - 3. + +1. +2. +3. ## Logs diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index 7c94e728..8d3b2c35 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -1,5 +1,11 @@ #### Why? + Why are you making this change? #### How? + Technical details on your change + +#### QA + +Latest QA could be found on [branch `qa/should-never-be-merged-to-master`](https://github.com/intercom/intercom-node-v2/pull/10) diff --git a/.gitignore b/.gitignore index 25204297..243c86ed 100644 --- a/.gitignore +++ b/.gitignore @@ -9,18 +9,36 @@ pids *.pid *.seed -# Coverage directory used by tools like istanbul -coverage +# Coverage directory used by nyc +.nyc_output # node-waf configuration .lock-wscript -# Compiled binary addons (http://nodejs.org/api/addons.html) -build/Release - # Dependency directory # https://docs.npmjs.com/misc/faq#should-i-check-my-node-modules-folder-into-git node_modules -# Babel +# Compiled version dist + +# Yarn 3.x +.pnp.* +.yarn/* +!.yarn/patches +!.yarn/plugins +!.yarn/releases +!.yarn/sdks +!.yarn/versions + +# Typescript mappings for lib +lib/*.map +lib/**/*.map +# Typescript mappings for test +test/*.map +test/**/*.map +# Generated Javascript +lib/*.js +lib/**/*.js +test/*.js +test/**/*.js diff --git a/.npmignore b/.npmignore new file mode 100644 index 00000000..4b88ae94 --- /dev/null +++ b/.npmignore @@ -0,0 +1,2 @@ +# Should exist, because dist is in .gitignore +# More here: https://docs.npmjs.com/cli/v8/using-npm/developers#keeping-files-out-of-your-package diff --git a/.nycrc b/.nycrc new file mode 100644 index 00000000..1fab4bc8 --- /dev/null +++ b/.nycrc @@ -0,0 +1,17 @@ +{ + "extends": "@istanbuljs/nyc-config-typescript", + "include": [ + "lib/**/*.ts" + ], + "exclude": [ + "lib/**/*.types.ts" + ], + "require": [ + "ts-node/register" + ], + "sourceMap": true, + "instrument": true, + "cache": true, + "all": true, + "check-coverage": true +} diff --git a/.prettierignore b/.prettierignore new file mode 100644 index 00000000..ed1e58ee --- /dev/null +++ b/.prettierignore @@ -0,0 +1,3 @@ +# Ignore artifacts: +dist +node_modules diff --git a/.prettierrc.json b/.prettierrc.json new file mode 100644 index 00000000..b4ed29b5 --- /dev/null +++ b/.prettierrc.json @@ -0,0 +1,8 @@ +{ + "trailingComma": "es5", + "endOfLine": "lf", + "useTabs": false, + "tabWidth": 4, + "semi": true, + "singleQuote": true +} diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 00000000..324a9612 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,4 @@ +{ + "editor.defaultFormatter": "esbenp.prettier-vscode", + "editor.formatOnSave": true +} diff --git a/.yarn/releases/yarn-3.1.1.cjs b/.yarn/releases/yarn-3.1.1.cjs new file mode 100755 index 00000000..f5f2adca --- /dev/null +++ b/.yarn/releases/yarn-3.1.1.cjs @@ -0,0 +1,768 @@ +#!/usr/bin/env node +/* eslint-disable */ +//prettier-ignore +(()=>{var Mfe=Object.create,Vf=Object.defineProperty,Ofe=Object.defineProperties,Kfe=Object.getOwnPropertyDescriptor,Ufe=Object.getOwnPropertyDescriptors,Hfe=Object.getOwnPropertyNames,hE=Object.getOwnPropertySymbols,Gfe=Object.getPrototypeOf,eb=Object.prototype.hasOwnProperty,lO=Object.prototype.propertyIsEnumerable;var cO=(t,e,r)=>e in t?Vf(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,P=(t,e)=>{for(var r in e||(e={}))eb.call(e,r)&&cO(t,r,e[r]);if(hE)for(var r of hE(e))lO.call(e,r)&&cO(t,r,e[r]);return t},_=(t,e)=>Ofe(t,Ufe(e)),jfe=t=>Vf(t,"__esModule",{value:!0});var qr=(t,e)=>{var r={};for(var i in t)eb.call(t,i)&&e.indexOf(i)<0&&(r[i]=t[i]);if(t!=null&&hE)for(var i of hE(t))e.indexOf(i)<0&&lO.call(t,i)&&(r[i]=t[i]);return r},Yfe=(t,e)=>()=>(t&&(e=t(t=0)),e),E=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),it=(t,e)=>{for(var r in e)Vf(t,r,{get:e[r],enumerable:!0})},qfe=(t,e,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Hfe(e))!eb.call(t,i)&&i!=="default"&&Vf(t,i,{get:()=>e[i],enumerable:!(r=Kfe(e,i))||r.enumerable});return t},ie=t=>qfe(jfe(Vf(t!=null?Mfe(Gfe(t)):{},"default",t&&t.__esModule&&"default"in t?{get:()=>t.default,enumerable:!0}:{value:t,enumerable:!0})),t);var MO=E((i$e,FO)=>{FO.exports=NO;NO.sync=Ahe;var LO=require("fs");function lhe(t,e){var r=e.pathExt!==void 0?e.pathExt:process.env.PATHEXT;if(!r||(r=r.split(";"),r.indexOf("")!==-1))return!0;for(var i=0;i{OO.exports=KO;KO.sync=che;var UO=require("fs");function KO(t,e,r){UO.stat(t,function(i,n){r(i,i?!1:HO(n,e))})}function che(t,e){return HO(UO.statSync(t),e)}function HO(t,e){return t.isFile()&&uhe(t,e)}function uhe(t,e){var r=t.mode,i=t.uid,n=t.gid,s=e.uid!==void 0?e.uid:process.getuid&&process.getuid(),o=e.gid!==void 0?e.gid:process.getgid&&process.getgid(),a=parseInt("100",8),l=parseInt("010",8),c=parseInt("001",8),u=a|l,g=r&c||r&l&&n===o||r&a&&i===s||r&u&&s===0;return g}});var YO=E((o$e,jO)=>{var s$e=require("fs"),xE;process.platform==="win32"||global.TESTING_WINDOWS?xE=MO():xE=GO();jO.exports=db;db.sync=ghe;function db(t,e,r){if(typeof e=="function"&&(r=e,e={}),!r){if(typeof Promise!="function")throw new TypeError("callback not provided");return new Promise(function(i,n){db(t,e||{},function(s,o){s?n(s):i(o)})})}xE(t,e||{},function(i,n){i&&(i.code==="EACCES"||e&&e.ignoreErrors)&&(i=null,n=!1),r(i,n)})}function ghe(t,e){try{return xE.sync(t,e||{})}catch(r){if(e&&e.ignoreErrors||r.code==="EACCES")return!1;throw r}}});var XO=E((a$e,qO)=>{var eu=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys",JO=require("path"),fhe=eu?";":":",WO=YO(),zO=t=>Object.assign(new Error(`not found: ${t}`),{code:"ENOENT"}),VO=(t,e)=>{let r=e.colon||fhe,i=t.match(/\//)||eu&&t.match(/\\/)?[""]:[...eu?[process.cwd()]:[],...(e.path||process.env.PATH||"").split(r)],n=eu?e.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"",s=eu?n.split(r):[""];return eu&&t.indexOf(".")!==-1&&s[0]!==""&&s.unshift(""),{pathEnv:i,pathExt:s,pathExtExe:n}},_O=(t,e,r)=>{typeof e=="function"&&(r=e,e={}),e||(e={});let{pathEnv:i,pathExt:n,pathExtExe:s}=VO(t,e),o=[],a=c=>new Promise((u,g)=>{if(c===i.length)return e.all&&o.length?u(o):g(zO(t));let f=i[c],h=/^".*"$/.test(f)?f.slice(1,-1):f,p=JO.join(h,t),d=!h&&/^\.[\\\/]/.test(t)?t.slice(0,2)+p:p;u(l(d,c,0))}),l=(c,u,g)=>new Promise((f,h)=>{if(g===n.length)return f(a(u+1));let p=n[g];WO(c+p,{pathExt:s},(d,m)=>{if(!d&&m)if(e.all)o.push(c+p);else return f(c+p);return f(l(c,u,g+1))})});return r?a(0).then(c=>r(null,c),r):a(0)},hhe=(t,e)=>{e=e||{};let{pathEnv:r,pathExt:i,pathExtExe:n}=VO(t,e),s=[];for(let o=0;o{"use strict";var ZO=(t={})=>{let e=t.env||process.env;return(t.platform||process.platform)!=="win32"?"PATH":Object.keys(e).reverse().find(i=>i.toUpperCase()==="PATH")||"Path"};Cb.exports=ZO;Cb.exports.default=ZO});var iK=E((l$e,eK)=>{"use strict";var tK=require("path"),phe=XO(),dhe=$O();function rK(t,e){let r=t.options.env||process.env,i=process.cwd(),n=t.options.cwd!=null,s=n&&process.chdir!==void 0&&!process.chdir.disabled;if(s)try{process.chdir(t.options.cwd)}catch(a){}let o;try{o=phe.sync(t.command,{path:r[dhe({env:r})],pathExt:e?tK.delimiter:void 0})}catch(a){}finally{s&&process.chdir(i)}return o&&(o=tK.resolve(n?t.options.cwd:"",o)),o}function Che(t){return rK(t)||rK(t,!0)}eK.exports=Che});var nK=E((c$e,mb)=>{"use strict";var Eb=/([()\][%!^"`<>&|;, *?])/g;function mhe(t){return t=t.replace(Eb,"^$1"),t}function Ehe(t,e){return t=`${t}`,t=t.replace(/(\\*)"/g,'$1$1\\"'),t=t.replace(/(\\*)$/,"$1$1"),t=`"${t}"`,t=t.replace(Eb,"^$1"),e&&(t=t.replace(Eb,"^$1")),t}mb.exports.command=mhe;mb.exports.argument=Ehe});var oK=E((u$e,sK)=>{"use strict";sK.exports=/^#!(.*)/});var AK=E((g$e,aK)=>{"use strict";var Ihe=oK();aK.exports=(t="")=>{let e=t.match(Ihe);if(!e)return null;let[r,i]=e[0].replace(/#! ?/,"").split(" "),n=r.split("/").pop();return n==="env"?i:i?`${n} ${i}`:n}});var cK=E((f$e,lK)=>{"use strict";var Ib=require("fs"),yhe=AK();function whe(t){let e=150,r=Buffer.alloc(e),i;try{i=Ib.openSync(t,"r"),Ib.readSync(i,r,0,e,0),Ib.closeSync(i)}catch(n){}return yhe(r.toString())}lK.exports=whe});var hK=E((h$e,uK)=>{"use strict";var Bhe=require("path"),gK=iK(),fK=nK(),Qhe=cK(),bhe=process.platform==="win32",vhe=/\.(?:com|exe)$/i,She=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;function xhe(t){t.file=gK(t);let e=t.file&&Qhe(t.file);return e?(t.args.unshift(t.file),t.command=e,gK(t)):t.file}function khe(t){if(!bhe)return t;let e=xhe(t),r=!vhe.test(e);if(t.options.forceShell||r){let i=She.test(e);t.command=Bhe.normalize(t.command),t.command=fK.command(t.command),t.args=t.args.map(s=>fK.argument(s,i));let n=[t.command].concat(t.args).join(" ");t.args=["/d","/s","/c",`"${n}"`],t.command=process.env.comspec||"cmd.exe",t.options.windowsVerbatimArguments=!0}return t}function Phe(t,e,r){e&&!Array.isArray(e)&&(r=e,e=null),e=e?e.slice(0):[],r=Object.assign({},r);let i={command:t,args:e,options:r,file:void 0,original:{command:t,args:e}};return r.shell?i:khe(i)}uK.exports=Phe});var CK=E((p$e,pK)=>{"use strict";var yb=process.platform==="win32";function wb(t,e){return Object.assign(new Error(`${e} ${t.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${e} ${t.command}`,path:t.command,spawnargs:t.args})}function Dhe(t,e){if(!yb)return;let r=t.emit;t.emit=function(i,n){if(i==="exit"){let s=dK(n,e,"spawn");if(s)return r.call(t,"error",s)}return r.apply(t,arguments)}}function dK(t,e){return yb&&t===1&&!e.file?wb(e.original,"spawn"):null}function Rhe(t,e){return yb&&t===1&&!e.file?wb(e.original,"spawnSync"):null}pK.exports={hookChildProcess:Dhe,verifyENOENT:dK,verifyENOENTSync:Rhe,notFoundError:wb}});var bb=E((d$e,tu)=>{"use strict";var mK=require("child_process"),Bb=hK(),Qb=CK();function EK(t,e,r){let i=Bb(t,e,r),n=mK.spawn(i.command,i.args,i.options);return Qb.hookChildProcess(n,i),n}function Fhe(t,e,r){let i=Bb(t,e,r),n=mK.spawnSync(i.command,i.args,i.options);return n.error=n.error||Qb.verifyENOENTSync(n.status,i),n}tu.exports=EK;tu.exports.spawn=EK;tu.exports.sync=Fhe;tu.exports._parse=Bb;tu.exports._enoent=Qb});var yK=E((y$e,IK)=>{"use strict";IK.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}});var Nb=E((w$e,wK)=>{var gh=yK(),BK={};for(let t of Object.keys(gh))BK[gh[t]]=t;var Xe={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};wK.exports=Xe;for(let t of Object.keys(Xe)){if(!("channels"in Xe[t]))throw new Error("missing channels property: "+t);if(!("labels"in Xe[t]))throw new Error("missing channel labels property: "+t);if(Xe[t].labels.length!==Xe[t].channels)throw new Error("channel and label counts mismatch: "+t);let{channels:e,labels:r}=Xe[t];delete Xe[t].channels,delete Xe[t].labels,Object.defineProperty(Xe[t],"channels",{value:e}),Object.defineProperty(Xe[t],"labels",{value:r})}Xe.rgb.hsl=function(t){let e=t[0]/255,r=t[1]/255,i=t[2]/255,n=Math.min(e,r,i),s=Math.max(e,r,i),o=s-n,a,l;s===n?a=0:e===s?a=(r-i)/o:r===s?a=2+(i-e)/o:i===s&&(a=4+(e-r)/o),a=Math.min(a*60,360),a<0&&(a+=360);let c=(n+s)/2;return s===n?l=0:c<=.5?l=o/(s+n):l=o/(2-s-n),[a,l*100,c*100]};Xe.rgb.hsv=function(t){let e,r,i,n,s,o=t[0]/255,a=t[1]/255,l=t[2]/255,c=Math.max(o,a,l),u=c-Math.min(o,a,l),g=function(f){return(c-f)/6/u+1/2};return u===0?(n=0,s=0):(s=u/c,e=g(o),r=g(a),i=g(l),o===c?n=i-r:a===c?n=1/3+e-i:l===c&&(n=2/3+r-e),n<0?n+=1:n>1&&(n-=1)),[n*360,s*100,c*100]};Xe.rgb.hwb=function(t){let e=t[0],r=t[1],i=t[2],n=Xe.rgb.hsl(t)[0],s=1/255*Math.min(e,Math.min(r,i));return i=1-1/255*Math.max(e,Math.max(r,i)),[n,s*100,i*100]};Xe.rgb.cmyk=function(t){let e=t[0]/255,r=t[1]/255,i=t[2]/255,n=Math.min(1-e,1-r,1-i),s=(1-e-n)/(1-n)||0,o=(1-r-n)/(1-n)||0,a=(1-i-n)/(1-n)||0;return[s*100,o*100,a*100,n*100]};function The(t,e){return(t[0]-e[0])**2+(t[1]-e[1])**2+(t[2]-e[2])**2}Xe.rgb.keyword=function(t){let e=BK[t];if(e)return e;let r=Infinity,i;for(let n of Object.keys(gh)){let s=gh[n],o=The(t,s);o.04045?((e+.055)/1.055)**2.4:e/12.92,r=r>.04045?((r+.055)/1.055)**2.4:r/12.92,i=i>.04045?((i+.055)/1.055)**2.4:i/12.92;let n=e*.4124+r*.3576+i*.1805,s=e*.2126+r*.7152+i*.0722,o=e*.0193+r*.1192+i*.9505;return[n*100,s*100,o*100]};Xe.rgb.lab=function(t){let e=Xe.rgb.xyz(t),r=e[0],i=e[1],n=e[2];r/=95.047,i/=100,n/=108.883,r=r>.008856?r**(1/3):7.787*r+16/116,i=i>.008856?i**(1/3):7.787*i+16/116,n=n>.008856?n**(1/3):7.787*n+16/116;let s=116*i-16,o=500*(r-i),a=200*(i-n);return[s,o,a]};Xe.hsl.rgb=function(t){let e=t[0]/360,r=t[1]/100,i=t[2]/100,n,s,o;if(r===0)return o=i*255,[o,o,o];i<.5?n=i*(1+r):n=i+r-i*r;let a=2*i-n,l=[0,0,0];for(let c=0;c<3;c++)s=e+1/3*-(c-1),s<0&&s++,s>1&&s--,6*s<1?o=a+(n-a)*6*s:2*s<1?o=n:3*s<2?o=a+(n-a)*(2/3-s)*6:o=a,l[c]=o*255;return l};Xe.hsl.hsv=function(t){let e=t[0],r=t[1]/100,i=t[2]/100,n=r,s=Math.max(i,.01);i*=2,r*=i<=1?i:2-i,n*=s<=1?s:2-s;let o=(i+r)/2,a=i===0?2*n/(s+n):2*r/(i+r);return[e,a*100,o*100]};Xe.hsv.rgb=function(t){let e=t[0]/60,r=t[1]/100,i=t[2]/100,n=Math.floor(e)%6,s=e-Math.floor(e),o=255*i*(1-r),a=255*i*(1-r*s),l=255*i*(1-r*(1-s));switch(i*=255,n){case 0:return[i,l,o];case 1:return[a,i,o];case 2:return[o,i,l];case 3:return[o,a,i];case 4:return[l,o,i];case 5:return[i,o,a]}};Xe.hsv.hsl=function(t){let e=t[0],r=t[1]/100,i=t[2]/100,n=Math.max(i,.01),s,o;o=(2-r)*i;let a=(2-r)*n;return s=r*n,s/=a<=1?a:2-a,s=s||0,o/=2,[e,s*100,o*100]};Xe.hwb.rgb=function(t){let e=t[0]/360,r=t[1]/100,i=t[2]/100,n=r+i,s;n>1&&(r/=n,i/=n);let o=Math.floor(6*e),a=1-i;s=6*e-o,(o&1)!=0&&(s=1-s);let l=r+s*(a-r),c,u,g;switch(o){default:case 6:case 0:c=a,u=l,g=r;break;case 1:c=l,u=a,g=r;break;case 2:c=r,u=a,g=l;break;case 3:c=r,u=l,g=a;break;case 4:c=l,u=r,g=a;break;case 5:c=a,u=r,g=l;break}return[c*255,u*255,g*255]};Xe.cmyk.rgb=function(t){let e=t[0]/100,r=t[1]/100,i=t[2]/100,n=t[3]/100,s=1-Math.min(1,e*(1-n)+n),o=1-Math.min(1,r*(1-n)+n),a=1-Math.min(1,i*(1-n)+n);return[s*255,o*255,a*255]};Xe.xyz.rgb=function(t){let e=t[0]/100,r=t[1]/100,i=t[2]/100,n,s,o;return n=e*3.2406+r*-1.5372+i*-.4986,s=e*-.9689+r*1.8758+i*.0415,o=e*.0557+r*-.204+i*1.057,n=n>.0031308?1.055*n**(1/2.4)-.055:n*12.92,s=s>.0031308?1.055*s**(1/2.4)-.055:s*12.92,o=o>.0031308?1.055*o**(1/2.4)-.055:o*12.92,n=Math.min(Math.max(0,n),1),s=Math.min(Math.max(0,s),1),o=Math.min(Math.max(0,o),1),[n*255,s*255,o*255]};Xe.xyz.lab=function(t){let e=t[0],r=t[1],i=t[2];e/=95.047,r/=100,i/=108.883,e=e>.008856?e**(1/3):7.787*e+16/116,r=r>.008856?r**(1/3):7.787*r+16/116,i=i>.008856?i**(1/3):7.787*i+16/116;let n=116*r-16,s=500*(e-r),o=200*(r-i);return[n,s,o]};Xe.lab.xyz=function(t){let e=t[0],r=t[1],i=t[2],n,s,o;s=(e+16)/116,n=r/500+s,o=s-i/200;let a=s**3,l=n**3,c=o**3;return s=a>.008856?a:(s-16/116)/7.787,n=l>.008856?l:(n-16/116)/7.787,o=c>.008856?c:(o-16/116)/7.787,n*=95.047,s*=100,o*=108.883,[n,s,o]};Xe.lab.lch=function(t){let e=t[0],r=t[1],i=t[2],n;n=Math.atan2(i,r)*360/2/Math.PI,n<0&&(n+=360);let o=Math.sqrt(r*r+i*i);return[e,o,n]};Xe.lch.lab=function(t){let e=t[0],r=t[1],n=t[2]/360*2*Math.PI,s=r*Math.cos(n),o=r*Math.sin(n);return[e,s,o]};Xe.rgb.ansi16=function(t,e=null){let[r,i,n]=t,s=e===null?Xe.rgb.hsv(t)[2]:e;if(s=Math.round(s/50),s===0)return 30;let o=30+(Math.round(n/255)<<2|Math.round(i/255)<<1|Math.round(r/255));return s===2&&(o+=60),o};Xe.hsv.ansi16=function(t){return Xe.rgb.ansi16(Xe.hsv.rgb(t),t[2])};Xe.rgb.ansi256=function(t){let e=t[0],r=t[1],i=t[2];return e===r&&r===i?e<8?16:e>248?231:Math.round((e-8)/247*24)+232:16+36*Math.round(e/255*5)+6*Math.round(r/255*5)+Math.round(i/255*5)};Xe.ansi16.rgb=function(t){let e=t%10;if(e===0||e===7)return t>50&&(e+=3.5),e=e/10.5*255,[e,e,e];let r=(~~(t>50)+1)*.5,i=(e&1)*r*255,n=(e>>1&1)*r*255,s=(e>>2&1)*r*255;return[i,n,s]};Xe.ansi256.rgb=function(t){if(t>=232){let s=(t-232)*10+8;return[s,s,s]}t-=16;let e,r=Math.floor(t/36)/5*255,i=Math.floor((e=t%36)/6)/5*255,n=e%6/5*255;return[r,i,n]};Xe.rgb.hex=function(t){let r=(((Math.round(t[0])&255)<<16)+((Math.round(t[1])&255)<<8)+(Math.round(t[2])&255)).toString(16).toUpperCase();return"000000".substring(r.length)+r};Xe.hex.rgb=function(t){let e=t.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!e)return[0,0,0];let r=e[0];e[0].length===3&&(r=r.split("").map(a=>a+a).join(""));let i=parseInt(r,16),n=i>>16&255,s=i>>8&255,o=i&255;return[n,s,o]};Xe.rgb.hcg=function(t){let e=t[0]/255,r=t[1]/255,i=t[2]/255,n=Math.max(Math.max(e,r),i),s=Math.min(Math.min(e,r),i),o=n-s,a,l;return o<1?a=s/(1-o):a=0,o<=0?l=0:n===e?l=(r-i)/o%6:n===r?l=2+(i-e)/o:l=4+(e-r)/o,l/=6,l%=1,[l*360,o*100,a*100]};Xe.hsl.hcg=function(t){let e=t[1]/100,r=t[2]/100,i=r<.5?2*e*r:2*e*(1-r),n=0;return i<1&&(n=(r-.5*i)/(1-i)),[t[0],i*100,n*100]};Xe.hsv.hcg=function(t){let e=t[1]/100,r=t[2]/100,i=e*r,n=0;return i<1&&(n=(r-i)/(1-i)),[t[0],i*100,n*100]};Xe.hcg.rgb=function(t){let e=t[0]/360,r=t[1]/100,i=t[2]/100;if(r===0)return[i*255,i*255,i*255];let n=[0,0,0],s=e%1*6,o=s%1,a=1-o,l=0;switch(Math.floor(s)){case 0:n[0]=1,n[1]=o,n[2]=0;break;case 1:n[0]=a,n[1]=1,n[2]=0;break;case 2:n[0]=0,n[1]=1,n[2]=o;break;case 3:n[0]=0,n[1]=a,n[2]=1;break;case 4:n[0]=o,n[1]=0,n[2]=1;break;default:n[0]=1,n[1]=0,n[2]=a}return l=(1-r)*i,[(r*n[0]+l)*255,(r*n[1]+l)*255,(r*n[2]+l)*255]};Xe.hcg.hsv=function(t){let e=t[1]/100,r=t[2]/100,i=e+r*(1-e),n=0;return i>0&&(n=e/i),[t[0],n*100,i*100]};Xe.hcg.hsl=function(t){let e=t[1]/100,i=t[2]/100*(1-e)+.5*e,n=0;return i>0&&i<.5?n=e/(2*i):i>=.5&&i<1&&(n=e/(2*(1-i))),[t[0],n*100,i*100]};Xe.hcg.hwb=function(t){let e=t[1]/100,r=t[2]/100,i=e+r*(1-e);return[t[0],(i-e)*100,(1-i)*100]};Xe.hwb.hcg=function(t){let e=t[1]/100,r=t[2]/100,i=1-r,n=i-e,s=0;return n<1&&(s=(i-n)/(1-n)),[t[0],n*100,s*100]};Xe.apple.rgb=function(t){return[t[0]/65535*255,t[1]/65535*255,t[2]/65535*255]};Xe.rgb.apple=function(t){return[t[0]/255*65535,t[1]/255*65535,t[2]/255*65535]};Xe.gray.rgb=function(t){return[t[0]/100*255,t[0]/100*255,t[0]/100*255]};Xe.gray.hsl=function(t){return[0,0,t[0]]};Xe.gray.hsv=Xe.gray.hsl;Xe.gray.hwb=function(t){return[0,100,t[0]]};Xe.gray.cmyk=function(t){return[0,0,0,t[0]]};Xe.gray.lab=function(t){return[t[0],0,0]};Xe.gray.hex=function(t){let e=Math.round(t[0]/100*255)&255,i=((e<<16)+(e<<8)+e).toString(16).toUpperCase();return"000000".substring(i.length)+i};Xe.rgb.gray=function(t){return[(t[0]+t[1]+t[2])/3/255*100]}});var bK=E((B$e,QK)=>{var kE=Nb();function Mhe(){let t={},e=Object.keys(kE);for(let r=e.length,i=0;i{var Lb=Nb(),Hhe=bK(),ru={},Ghe=Object.keys(Lb);function jhe(t){let e=function(...r){let i=r[0];return i==null?i:(i.length>1&&(r=i),t(r))};return"conversion"in t&&(e.conversion=t.conversion),e}function Yhe(t){let e=function(...r){let i=r[0];if(i==null)return i;i.length>1&&(r=i);let n=t(r);if(typeof n=="object")for(let s=n.length,o=0;o{ru[t]={},Object.defineProperty(ru[t],"channels",{value:Lb[t].channels}),Object.defineProperty(ru[t],"labels",{value:Lb[t].labels});let e=Hhe(t);Object.keys(e).forEach(i=>{let n=e[i];ru[t][i]=Yhe(n),ru[t][i].raw=jhe(n)})});vK.exports=ru});var FK=E((b$e,xK)=>{"use strict";var kK=(t,e)=>(...r)=>`[${t(...r)+e}m`,PK=(t,e)=>(...r)=>{let i=t(...r);return`[${38+e};5;${i}m`},DK=(t,e)=>(...r)=>{let i=t(...r);return`[${38+e};2;${i[0]};${i[1]};${i[2]}m`},PE=t=>t,RK=(t,e,r)=>[t,e,r],iu=(t,e,r)=>{Object.defineProperty(t,e,{get:()=>{let i=r();return Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0}),i},enumerable:!0,configurable:!0})},Tb,nu=(t,e,r,i)=>{Tb===void 0&&(Tb=SK());let n=i?10:0,s={};for(let[o,a]of Object.entries(Tb)){let l=o==="ansi16"?"ansi":o;o===e?s[l]=t(r,n):typeof a=="object"&&(s[l]=t(a[e],n))}return s};function qhe(){let t=new Map,e={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};e.color.gray=e.color.blackBright,e.bgColor.bgGray=e.bgColor.bgBlackBright,e.color.grey=e.color.blackBright,e.bgColor.bgGrey=e.bgColor.bgBlackBright;for(let[r,i]of Object.entries(e)){for(let[n,s]of Object.entries(i))e[n]={open:`[${s[0]}m`,close:`[${s[1]}m`},i[n]=e[n],t.set(s[0],s[1]);Object.defineProperty(e,r,{value:i,enumerable:!1})}return Object.defineProperty(e,"codes",{value:t,enumerable:!1}),e.color.close="",e.bgColor.close="",iu(e.color,"ansi",()=>nu(kK,"ansi16",PE,!1)),iu(e.color,"ansi256",()=>nu(PK,"ansi256",PE,!1)),iu(e.color,"ansi16m",()=>nu(DK,"rgb",RK,!1)),iu(e.bgColor,"ansi",()=>nu(kK,"ansi16",PE,!0)),iu(e.bgColor,"ansi256",()=>nu(PK,"ansi256",PE,!0)),iu(e.bgColor,"ansi16m",()=>nu(DK,"rgb",RK,!0)),e}Object.defineProperty(xK,"exports",{enumerable:!0,get:qhe})});var LK=E((v$e,NK)=>{"use strict";NK.exports=(t,e=process.argv)=>{let r=t.startsWith("-")?"":t.length===1?"-":"--",i=e.indexOf(r+t),n=e.indexOf("--");return i!==-1&&(n===-1||i{"use strict";var Jhe=require("os"),MK=require("tty"),Wn=LK(),{env:Wr}=process,tA;Wn("no-color")||Wn("no-colors")||Wn("color=false")||Wn("color=never")?tA=0:(Wn("color")||Wn("colors")||Wn("color=true")||Wn("color=always"))&&(tA=1);"FORCE_COLOR"in Wr&&(Wr.FORCE_COLOR==="true"?tA=1:Wr.FORCE_COLOR==="false"?tA=0:tA=Wr.FORCE_COLOR.length===0?1:Math.min(parseInt(Wr.FORCE_COLOR,10),3));function Mb(t){return t===0?!1:{level:t,hasBasic:!0,has256:t>=2,has16m:t>=3}}function Ob(t,e){if(tA===0)return 0;if(Wn("color=16m")||Wn("color=full")||Wn("color=truecolor"))return 3;if(Wn("color=256"))return 2;if(t&&!e&&tA===void 0)return 0;let r=tA||0;if(Wr.TERM==="dumb")return r;if(process.platform==="win32"){let i=Jhe.release().split(".");return Number(i[0])>=10&&Number(i[2])>=10586?Number(i[2])>=14931?3:2:1}if("CI"in Wr)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI"].some(i=>i in Wr)||Wr.CI_NAME==="codeship"?1:r;if("TEAMCITY_VERSION"in Wr)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(Wr.TEAMCITY_VERSION)?1:0;if("GITHUB_ACTIONS"in Wr)return 1;if(Wr.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in Wr){let i=parseInt((Wr.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(Wr.TERM_PROGRAM){case"iTerm.app":return i>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(Wr.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(Wr.TERM)||"COLORTERM"in Wr?1:r}function Whe(t){let e=Ob(t,t&&t.isTTY);return Mb(e)}TK.exports={supportsColor:Whe,stdout:Mb(Ob(!0,MK.isatty(1))),stderr:Mb(Ob(!0,MK.isatty(2)))}});var UK=E((x$e,KK)=>{"use strict";var zhe=(t,e,r)=>{let i=t.indexOf(e);if(i===-1)return t;let n=e.length,s=0,o="";do o+=t.substr(s,i-s)+e+r,s=i+n,i=t.indexOf(e,s);while(i!==-1);return o+=t.substr(s),o},Vhe=(t,e,r,i)=>{let n=0,s="";do{let o=t[i-1]==="\r";s+=t.substr(n,(o?i-1:i)-n)+e+(o?`\r +`:` +`)+r,n=i+1,i=t.indexOf(` +`,n)}while(i!==-1);return s+=t.substr(n),s};KK.exports={stringReplaceAll:zhe,stringEncaseCRLFWithFirstIndex:Vhe}});var qK=E((k$e,HK)=>{"use strict";var _he=/(?:\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi,GK=/(?:^|\.)(\w+)(?:\(([^)]*)\))?/g,Xhe=/^(['"])((?:\\.|(?!\1)[^\\])*)\1$/,Zhe=/\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.)|([^\\])/gi,$he=new Map([["n",` +`],["r","\r"],["t"," "],["b","\b"],["f","\f"],["v","\v"],["0","\0"],["\\","\\"],["e",""],["a","\x07"]]);function jK(t){let e=t[0]==="u",r=t[1]==="{";return e&&!r&&t.length===5||t[0]==="x"&&t.length===3?String.fromCharCode(parseInt(t.slice(1),16)):e&&r?String.fromCodePoint(parseInt(t.slice(2,-1),16)):$he.get(t)||t}function epe(t,e){let r=[],i=e.trim().split(/\s*,\s*/g),n;for(let s of i){let o=Number(s);if(!Number.isNaN(o))r.push(o);else if(n=s.match(Xhe))r.push(n[2].replace(Zhe,(a,l,c)=>l?jK(l):c));else throw new Error(`Invalid Chalk template style argument: ${s} (in style '${t}')`)}return r}function tpe(t){GK.lastIndex=0;let e=[],r;for(;(r=GK.exec(t))!==null;){let i=r[1];if(r[2]){let n=epe(i,r[2]);e.push([i].concat(n))}else e.push([i])}return e}function YK(t,e){let r={};for(let n of e)for(let s of n.styles)r[s[0]]=n.inverse?null:s.slice(1);let i=t;for(let[n,s]of Object.entries(r))if(!!Array.isArray(s)){if(!(n in i))throw new Error(`Unknown Chalk style: ${n}`);i=s.length>0?i[n](...s):i[n]}return i}HK.exports=(t,e)=>{let r=[],i=[],n=[];if(e.replace(_he,(s,o,a,l,c,u)=>{if(o)n.push(jK(o));else if(l){let g=n.join("");n=[],i.push(r.length===0?g:YK(t,r)(g)),r.push({inverse:a,styles:tpe(l)})}else if(c){if(r.length===0)throw new Error("Found extraneous } in Chalk template literal");i.push(YK(t,r)(n.join(""))),n=[],r.pop()}else n.push(u)}),i.push(n.join("")),r.length>0){let s=`Chalk template literal is missing ${r.length} closing bracket${r.length===1?"":"s"} (\`}\`)`;throw new Error(s)}return i.join("")}});var jb=E((P$e,JK)=>{"use strict";var fh=FK(),{stdout:Kb,stderr:Ub}=OK(),{stringReplaceAll:rpe,stringEncaseCRLFWithFirstIndex:ipe}=UK(),WK=["ansi","ansi","ansi256","ansi16m"],su=Object.create(null),npe=(t,e={})=>{if(e.level>3||e.level<0)throw new Error("The `level` option should be an integer from 0 to 3");let r=Kb?Kb.level:0;t.level=e.level===void 0?r:e.level},zK=class{constructor(e){return VK(e)}},VK=t=>{let e={};return npe(e,t),e.template=(...r)=>spe(e.template,...r),Object.setPrototypeOf(e,DE.prototype),Object.setPrototypeOf(e.template,e),e.template.constructor=()=>{throw new Error("`chalk.constructor()` is deprecated. Use `new chalk.Instance()` instead.")},e.template.Instance=zK,e.template};function DE(t){return VK(t)}for(let[t,e]of Object.entries(fh))su[t]={get(){let r=RE(this,Hb(e.open,e.close,this._styler),this._isEmpty);return Object.defineProperty(this,t,{value:r}),r}};su.visible={get(){let t=RE(this,this._styler,!0);return Object.defineProperty(this,"visible",{value:t}),t}};var _K=["rgb","hex","keyword","hsl","hsv","hwb","ansi","ansi256"];for(let t of _K)su[t]={get(){let{level:e}=this;return function(...r){let i=Hb(fh.color[WK[e]][t](...r),fh.color.close,this._styler);return RE(this,i,this._isEmpty)}}};for(let t of _K){let e="bg"+t[0].toUpperCase()+t.slice(1);su[e]={get(){let{level:r}=this;return function(...i){let n=Hb(fh.bgColor[WK[r]][t](...i),fh.bgColor.close,this._styler);return RE(this,n,this._isEmpty)}}}}var ope=Object.defineProperties(()=>{},_(P({},su),{level:{enumerable:!0,get(){return this._generator.level},set(t){this._generator.level=t}}})),Hb=(t,e,r)=>{let i,n;return r===void 0?(i=t,n=e):(i=r.openAll+t,n=e+r.closeAll),{open:t,close:e,openAll:i,closeAll:n,parent:r}},RE=(t,e,r)=>{let i=(...n)=>ape(i,n.length===1?""+n[0]:n.join(" "));return i.__proto__=ope,i._generator=t,i._styler=e,i._isEmpty=r,i},ape=(t,e)=>{if(t.level<=0||!e)return t._isEmpty?"":e;let r=t._styler;if(r===void 0)return e;let{openAll:i,closeAll:n}=r;if(e.indexOf("")!==-1)for(;r!==void 0;)e=rpe(e,r.close,r.open),r=r.parent;let s=e.indexOf(` +`);return s!==-1&&(e=ipe(e,n,i,s)),i+e+n},Gb,spe=(t,...e)=>{let[r]=e;if(!Array.isArray(r))return e.join(" ");let i=e.slice(1),n=[r.raw[0]];for(let s=1;s{XK.exports=[{name:"AppVeyor",constant:"APPVEYOR",env:"APPVEYOR",pr:"APPVEYOR_PULL_REQUEST_NUMBER"},{name:"Azure Pipelines",constant:"AZURE_PIPELINES",env:"SYSTEM_TEAMFOUNDATIONCOLLECTIONURI",pr:"SYSTEM_PULLREQUEST_PULLREQUESTID"},{name:"Appcircle",constant:"APPCIRCLE",env:"AC_APPCIRCLE"},{name:"Bamboo",constant:"BAMBOO",env:"bamboo_planKey"},{name:"Bitbucket Pipelines",constant:"BITBUCKET",env:"BITBUCKET_COMMIT",pr:"BITBUCKET_PR_ID"},{name:"Bitrise",constant:"BITRISE",env:"BITRISE_IO",pr:"BITRISE_PULL_REQUEST"},{name:"Buddy",constant:"BUDDY",env:"BUDDY_WORKSPACE_ID",pr:"BUDDY_EXECUTION_PULL_REQUEST_ID"},{name:"Buildkite",constant:"BUILDKITE",env:"BUILDKITE",pr:{env:"BUILDKITE_PULL_REQUEST",ne:"false"}},{name:"CircleCI",constant:"CIRCLE",env:"CIRCLECI",pr:"CIRCLE_PULL_REQUEST"},{name:"Cirrus CI",constant:"CIRRUS",env:"CIRRUS_CI",pr:"CIRRUS_PR"},{name:"AWS CodeBuild",constant:"CODEBUILD",env:"CODEBUILD_BUILD_ARN"},{name:"Codefresh",constant:"CODEFRESH",env:"CF_BUILD_ID",pr:{any:["CF_PULL_REQUEST_NUMBER","CF_PULL_REQUEST_ID"]}},{name:"Codeship",constant:"CODESHIP",env:{CI_NAME:"codeship"}},{name:"Drone",constant:"DRONE",env:"DRONE",pr:{DRONE_BUILD_EVENT:"pull_request"}},{name:"dsari",constant:"DSARI",env:"DSARI"},{name:"GitHub Actions",constant:"GITHUB_ACTIONS",env:"GITHUB_ACTIONS",pr:{GITHUB_EVENT_NAME:"pull_request"}},{name:"GitLab CI",constant:"GITLAB",env:"GITLAB_CI",pr:"CI_MERGE_REQUEST_ID"},{name:"GoCD",constant:"GOCD",env:"GO_PIPELINE_LABEL"},{name:"LayerCI",constant:"LAYERCI",env:"LAYERCI",pr:"LAYERCI_PULL_REQUEST"},{name:"Hudson",constant:"HUDSON",env:"HUDSON_URL"},{name:"Jenkins",constant:"JENKINS",env:["JENKINS_URL","BUILD_ID"],pr:{any:["ghprbPullId","CHANGE_ID"]}},{name:"Magnum CI",constant:"MAGNUM",env:"MAGNUM"},{name:"Netlify CI",constant:"NETLIFY",env:"NETLIFY",pr:{env:"PULL_REQUEST",ne:"false"}},{name:"Nevercode",constant:"NEVERCODE",env:"NEVERCODE",pr:{env:"NEVERCODE_PULL_REQUEST",ne:"false"}},{name:"Render",constant:"RENDER",env:"RENDER",pr:{IS_PULL_REQUEST:"true"}},{name:"Sail CI",constant:"SAIL",env:"SAILCI",pr:"SAIL_PULL_REQUEST_NUMBER"},{name:"Semaphore",constant:"SEMAPHORE",env:"SEMAPHORE",pr:"PULL_REQUEST_NUMBER"},{name:"Screwdriver",constant:"SCREWDRIVER",env:"SCREWDRIVER",pr:{env:"SD_PULL_REQUEST",ne:"false"}},{name:"Shippable",constant:"SHIPPABLE",env:"SHIPPABLE",pr:{IS_PULL_REQUEST:"true"}},{name:"Solano CI",constant:"SOLANO",env:"TDDIUM",pr:"TDDIUM_PR_ID"},{name:"Strider CD",constant:"STRIDER",env:"STRIDER"},{name:"TaskCluster",constant:"TASKCLUSTER",env:["TASK_ID","RUN_ID"]},{name:"TeamCity",constant:"TEAMCITY",env:"TEAMCITY_VERSION"},{name:"Travis CI",constant:"TRAVIS",env:"TRAVIS",pr:{env:"TRAVIS_PULL_REQUEST",ne:"false"}},{name:"Vercel",constant:"VERCEL",env:"NOW_BUILDER"},{name:"Visual Studio App Center",constant:"APPCENTER",env:"APPCENTER_BUILD_ID"}]});var ml=E(Dn=>{"use strict";var $K=ZK(),ro=process.env;Object.defineProperty(Dn,"_vendors",{value:$K.map(function(t){return t.constant})});Dn.name=null;Dn.isPR=null;$K.forEach(function(t){let r=(Array.isArray(t.env)?t.env:[t.env]).every(function(i){return e1(i)});if(Dn[t.constant]=r,r)switch(Dn.name=t.name,typeof t.pr){case"string":Dn.isPR=!!ro[t.pr];break;case"object":"env"in t.pr?Dn.isPR=t.pr.env in ro&&ro[t.pr.env]!==t.pr.ne:"any"in t.pr?Dn.isPR=t.pr.any.some(function(i){return!!ro[i]}):Dn.isPR=e1(t.pr);break;default:Dn.isPR=null}});Dn.isCI=!!(ro.CI||ro.CONTINUOUS_INTEGRATION||ro.BUILD_NUMBER||ro.RUN_ID||Dn.name);function e1(t){return typeof t=="string"?!!ro[t]:Object.keys(t).every(function(e){return ro[e]===t[e]})}});var FE=E(zn=>{"use strict";zn.isInteger=t=>typeof t=="number"?Number.isInteger(t):typeof t=="string"&&t.trim()!==""?Number.isInteger(Number(t)):!1;zn.find=(t,e)=>t.nodes.find(r=>r.type===e);zn.exceedsLimit=(t,e,r=1,i)=>i===!1||!zn.isInteger(t)||!zn.isInteger(e)?!1:(Number(e)-Number(t))/Number(r)>=i;zn.escapeNode=(t,e=0,r)=>{let i=t.nodes[e];!i||(r&&i.type===r||i.type==="open"||i.type==="close")&&i.escaped!==!0&&(i.value="\\"+i.value,i.escaped=!0)};zn.encloseBrace=t=>t.type!=="brace"?!1:t.commas>>0+t.ranges>>0==0?(t.invalid=!0,!0):!1;zn.isInvalidBrace=t=>t.type!=="brace"?!1:t.invalid===!0||t.dollar?!0:t.commas>>0+t.ranges>>0==0||t.open!==!0||t.close!==!0?(t.invalid=!0,!0):!1;zn.isOpenOrClose=t=>t.type==="open"||t.type==="close"?!0:t.open===!0||t.close===!0;zn.reduce=t=>t.reduce((e,r)=>(r.type==="text"&&e.push(r.value),r.type==="range"&&(r.type="text"),e),[]);zn.flatten=(...t)=>{let e=[],r=i=>{for(let n=0;n{"use strict";var r1=FE();t1.exports=(t,e={})=>{let r=(i,n={})=>{let s=e.escapeInvalid&&r1.isInvalidBrace(n),o=i.invalid===!0&&e.escapeInvalid===!0,a="";if(i.value)return(s||o)&&r1.isOpenOrClose(i)?"\\"+i.value:i.value;if(i.value)return i.value;if(i.nodes)for(let l of i.nodes)a+=r(l);return a};return r(t)}});var n1=E((L$e,i1)=>{"use strict";i1.exports=function(t){return typeof t=="number"?t-t==0:typeof t=="string"&&t.trim()!==""?Number.isFinite?Number.isFinite(+t):isFinite(+t):!1}});var f1=E((T$e,s1)=>{"use strict";var o1=n1(),El=(t,e,r)=>{if(o1(t)===!1)throw new TypeError("toRegexRange: expected the first argument to be a number");if(e===void 0||t===e)return String(t);if(o1(e)===!1)throw new TypeError("toRegexRange: expected the second argument to be a number.");let i=P({relaxZeros:!0},r);typeof i.strictZeros=="boolean"&&(i.relaxZeros=i.strictZeros===!1);let n=String(i.relaxZeros),s=String(i.shorthand),o=String(i.capture),a=String(i.wrap),l=t+":"+e+"="+n+s+o+a;if(El.cache.hasOwnProperty(l))return El.cache[l].result;let c=Math.min(t,e),u=Math.max(t,e);if(Math.abs(c-u)===1){let d=t+"|"+e;return i.capture?`(${d})`:i.wrap===!1?d:`(?:${d})`}let g=A1(t)||A1(e),f={min:t,max:e,a:c,b:u},h=[],p=[];if(g&&(f.isPadded=g,f.maxLen=String(f.max).length),c<0){let d=u<0?Math.abs(u):1;p=a1(d,Math.abs(c),f,i),c=f.a=0}return u>=0&&(h=a1(c,u,f,i)),f.negatives=p,f.positives=h,f.result=Ape(p,h,i),i.capture===!0?f.result=`(${f.result})`:i.wrap!==!1&&h.length+p.length>1&&(f.result=`(?:${f.result})`),El.cache[l]=f,f.result};function Ape(t,e,r){let i=Yb(t,e,"-",!1,r)||[],n=Yb(e,t,"",!1,r)||[],s=Yb(t,e,"-?",!0,r)||[];return i.concat(s).concat(n).join("|")}function cpe(t,e){let r=1,i=1,n=l1(t,r),s=new Set([e]);for(;t<=n&&n<=e;)s.add(n),r+=1,n=l1(t,r);for(n=c1(e+1,i)-1;t1&&a.count.pop(),a.count.push(u.count[0]),a.string=a.pattern+u1(a.count),o=c+1;continue}r.isPadded&&(g=hpe(c,r,i)),u.string=g+u.pattern+u1(u.count),s.push(u),o=c+1,a=u}return s}function Yb(t,e,r,i,n){let s=[];for(let o of t){let{string:a}=o;!i&&!g1(e,"string",a)&&s.push(r+a),i&&g1(e,"string",a)&&s.push(r+a)}return s}function upe(t,e){let r=[];for(let i=0;ie?1:e>t?-1:0}function g1(t,e,r){return t.some(i=>i[e]===r)}function l1(t,e){return Number(String(t).slice(0,-e)+"9".repeat(e))}function c1(t,e){return t-t%Math.pow(10,e)}function u1(t){let[e=0,r=""]=t;return r||e>1?`{${e+(r?","+r:"")}}`:""}function gpe(t,e,r){return`[${t}${e-t==1?"":"-"}${e}]`}function A1(t){return/^-?(0+)\d/.test(t)}function hpe(t,e,r){if(!e.isPadded)return t;let i=Math.abs(e.maxLen-String(t).length),n=r.relaxZeros!==!1;switch(i){case 0:return"";case 1:return n?"0?":"0";case 2:return n?"0{0,2}":"00";default:return n?`0{0,${i}}`:`0{${i}}`}}El.cache={};El.clearCache=()=>El.cache={};s1.exports=El});var Wb=E((M$e,h1)=>{"use strict";var ppe=require("util"),p1=f1(),d1=t=>t!==null&&typeof t=="object"&&!Array.isArray(t),dpe=t=>e=>t===!0?Number(e):String(e),qb=t=>typeof t=="number"||typeof t=="string"&&t!=="",ph=t=>Number.isInteger(+t),Jb=t=>{let e=`${t}`,r=-1;if(e[0]==="-"&&(e=e.slice(1)),e==="0")return!1;for(;e[++r]==="0";);return r>0},Cpe=(t,e,r)=>typeof t=="string"||typeof e=="string"?!0:r.stringify===!0,mpe=(t,e,r)=>{if(e>0){let i=t[0]==="-"?"-":"";i&&(t=t.slice(1)),t=i+t.padStart(i?e-1:e,"0")}return r===!1?String(t):t},C1=(t,e)=>{let r=t[0]==="-"?"-":"";for(r&&(t=t.slice(1),e--);t.length{t.negatives.sort((o,a)=>oa?1:0),t.positives.sort((o,a)=>oa?1:0);let r=e.capture?"":"?:",i="",n="",s;return t.positives.length&&(i=t.positives.join("|")),t.negatives.length&&(n=`-(${r}${t.negatives.join("|")})`),i&&n?s=`${i}|${n}`:s=i||n,e.wrap?`(${r}${s})`:s},m1=(t,e,r,i)=>{if(r)return p1(t,e,P({wrap:!1},i));let n=String.fromCharCode(t);if(t===e)return n;let s=String.fromCharCode(e);return`[${n}-${s}]`},E1=(t,e,r)=>{if(Array.isArray(t)){let i=r.wrap===!0,n=r.capture?"":"?:";return i?`(${n}${t.join("|")})`:t.join("|")}return p1(t,e,r)},I1=(...t)=>new RangeError("Invalid range arguments: "+ppe.inspect(...t)),y1=(t,e,r)=>{if(r.strictRanges===!0)throw I1([t,e]);return[]},Ipe=(t,e)=>{if(e.strictRanges===!0)throw new TypeError(`Expected step "${t}" to be a number`);return[]},ype=(t,e,r=1,i={})=>{let n=Number(t),s=Number(e);if(!Number.isInteger(n)||!Number.isInteger(s)){if(i.strictRanges===!0)throw I1([t,e]);return[]}n===0&&(n=0),s===0&&(s=0);let o=n>s,a=String(t),l=String(e),c=String(r);r=Math.max(Math.abs(r),1);let u=Jb(a)||Jb(l)||Jb(c),g=u?Math.max(a.length,l.length,c.length):0,f=u===!1&&Cpe(t,e,i)===!1,h=i.transform||dpe(f);if(i.toRegex&&r===1)return m1(C1(t,g),C1(e,g),!0,i);let p={negatives:[],positives:[]},d=B=>p[B<0?"negatives":"positives"].push(Math.abs(B)),m=[],I=0;for(;o?n>=s:n<=s;)i.toRegex===!0&&r>1?d(n):m.push(mpe(h(n,I),g,f)),n=o?n-r:n+r,I++;return i.toRegex===!0?r>1?Epe(p,i):E1(m,null,P({wrap:!1},i)):m},wpe=(t,e,r=1,i={})=>{if(!ph(t)&&t.length>1||!ph(e)&&e.length>1)return y1(t,e,i);let n=i.transform||(f=>String.fromCharCode(f)),s=`${t}`.charCodeAt(0),o=`${e}`.charCodeAt(0),a=s>o,l=Math.min(s,o),c=Math.max(s,o);if(i.toRegex&&r===1)return m1(l,c,!1,i);let u=[],g=0;for(;a?s>=o:s<=o;)u.push(n(s,g)),s=a?s-r:s+r,g++;return i.toRegex===!0?E1(u,null,{wrap:!1,options:i}):u},LE=(t,e,r,i={})=>{if(e==null&&qb(t))return[t];if(!qb(t)||!qb(e))return y1(t,e,i);if(typeof r=="function")return LE(t,e,1,{transform:r});if(d1(r))return LE(t,e,0,r);let n=P({},i);return n.capture===!0&&(n.wrap=!0),r=r||n.step||1,ph(r)?ph(t)&&ph(e)?ype(t,e,r,n):wpe(t,e,Math.max(Math.abs(r),1),n):r!=null&&!d1(r)?Ipe(r,n):LE(t,e,1,r)};h1.exports=LE});var Q1=E((O$e,w1)=>{"use strict";var Bpe=Wb(),B1=FE(),Qpe=(t,e={})=>{let r=(i,n={})=>{let s=B1.isInvalidBrace(n),o=i.invalid===!0&&e.escapeInvalid===!0,a=s===!0||o===!0,l=e.escapeInvalid===!0?"\\":"",c="";if(i.isOpen===!0||i.isClose===!0)return l+i.value;if(i.type==="open")return a?l+i.value:"(";if(i.type==="close")return a?l+i.value:")";if(i.type==="comma")return i.prev.type==="comma"?"":a?i.value:"|";if(i.value)return i.value;if(i.nodes&&i.ranges>0){let u=B1.reduce(i.nodes),g=Bpe(...u,_(P({},e),{wrap:!1,toRegex:!0}));if(g.length!==0)return u.length>1&&g.length>1?`(${g})`:g}if(i.nodes)for(let u of i.nodes)c+=r(u,i);return c};return r(t)};w1.exports=Qpe});var S1=E((K$e,b1)=>{"use strict";var bpe=Wb(),v1=NE(),ou=FE(),Il=(t="",e="",r=!1)=>{let i=[];if(t=[].concat(t),e=[].concat(e),!e.length)return t;if(!t.length)return r?ou.flatten(e).map(n=>`{${n}}`):e;for(let n of t)if(Array.isArray(n))for(let s of n)i.push(Il(s,e,r));else for(let s of e)r===!0&&typeof s=="string"&&(s=`{${s}}`),i.push(Array.isArray(s)?Il(n,s,r):n+s);return ou.flatten(i)},vpe=(t,e={})=>{let r=e.rangeLimit===void 0?1e3:e.rangeLimit,i=(n,s={})=>{n.queue=[];let o=s,a=s.queue;for(;o.type!=="brace"&&o.type!=="root"&&o.parent;)o=o.parent,a=o.queue;if(n.invalid||n.dollar){a.push(Il(a.pop(),v1(n,e)));return}if(n.type==="brace"&&n.invalid!==!0&&n.nodes.length===2){a.push(Il(a.pop(),["{}"]));return}if(n.nodes&&n.ranges>0){let g=ou.reduce(n.nodes);if(ou.exceedsLimit(...g,e.step,r))throw new RangeError("expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.");let f=bpe(...g,e);f.length===0&&(f=v1(n,e)),a.push(Il(a.pop(),f)),n.nodes=[];return}let l=ou.encloseBrace(n),c=n.queue,u=n;for(;u.type!=="brace"&&u.type!=="root"&&u.parent;)u=u.parent,c=u.queue;for(let g=0;g{"use strict";x1.exports={MAX_LENGTH:1024*64,CHAR_0:"0",CHAR_9:"9",CHAR_UPPERCASE_A:"A",CHAR_LOWERCASE_A:"a",CHAR_UPPERCASE_Z:"Z",CHAR_LOWERCASE_Z:"z",CHAR_LEFT_PARENTHESES:"(",CHAR_RIGHT_PARENTHESES:")",CHAR_ASTERISK:"*",CHAR_AMPERSAND:"&",CHAR_AT:"@",CHAR_BACKSLASH:"\\",CHAR_BACKTICK:"`",CHAR_CARRIAGE_RETURN:"\r",CHAR_CIRCUMFLEX_ACCENT:"^",CHAR_COLON:":",CHAR_COMMA:",",CHAR_DOLLAR:"$",CHAR_DOT:".",CHAR_DOUBLE_QUOTE:'"',CHAR_EQUAL:"=",CHAR_EXCLAMATION_MARK:"!",CHAR_FORM_FEED:"\f",CHAR_FORWARD_SLASH:"/",CHAR_HASH:"#",CHAR_HYPHEN_MINUS:"-",CHAR_LEFT_ANGLE_BRACKET:"<",CHAR_LEFT_CURLY_BRACE:"{",CHAR_LEFT_SQUARE_BRACKET:"[",CHAR_LINE_FEED:` +`,CHAR_NO_BREAK_SPACE:"\xA0",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:" ",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\uFEFF"}});var N1=E((H$e,P1)=>{"use strict";var Spe=NE(),{MAX_LENGTH:D1,CHAR_BACKSLASH:zb,CHAR_BACKTICK:xpe,CHAR_COMMA:kpe,CHAR_DOT:Ppe,CHAR_LEFT_PARENTHESES:Dpe,CHAR_RIGHT_PARENTHESES:Rpe,CHAR_LEFT_CURLY_BRACE:Fpe,CHAR_RIGHT_CURLY_BRACE:Npe,CHAR_LEFT_SQUARE_BRACKET:R1,CHAR_RIGHT_SQUARE_BRACKET:F1,CHAR_DOUBLE_QUOTE:Lpe,CHAR_SINGLE_QUOTE:Tpe,CHAR_NO_BREAK_SPACE:Mpe,CHAR_ZERO_WIDTH_NOBREAK_SPACE:Ope}=k1(),Kpe=(t,e={})=>{if(typeof t!="string")throw new TypeError("Expected a string");let r=e||{},i=typeof r.maxLength=="number"?Math.min(D1,r.maxLength):D1;if(t.length>i)throw new SyntaxError(`Input length (${t.length}), exceeds max characters (${i})`);let n={type:"root",input:t,nodes:[]},s=[n],o=n,a=n,l=0,c=t.length,u=0,g=0,f,h={},p=()=>t[u++],d=m=>{if(m.type==="text"&&a.type==="dot"&&(a.type="text"),a&&a.type==="text"&&m.type==="text"){a.value+=m.value;return}return o.nodes.push(m),m.parent=o,m.prev=a,a=m,m};for(d({type:"bos"});u0){if(o.ranges>0){o.ranges=0;let m=o.nodes.shift();o.nodes=[m,{type:"text",value:Spe(o)}]}d({type:"comma",value:f}),o.commas++;continue}if(f===Ppe&&g>0&&o.commas===0){let m=o.nodes;if(g===0||m.length===0){d({type:"text",value:f});continue}if(a.type==="dot"){if(o.range=[],a.value+=f,a.type="range",o.nodes.length!==3&&o.nodes.length!==5){o.invalid=!0,o.ranges=0,a.type="text";continue}o.ranges++,o.args=[];continue}if(a.type==="range"){m.pop();let I=m[m.length-1];I.value+=a.value+f,a=I,o.ranges--;continue}d({type:"dot",value:f});continue}d({type:"text",value:f})}do if(o=s.pop(),o.type!=="root"){o.nodes.forEach(B=>{B.nodes||(B.type==="open"&&(B.isOpen=!0),B.type==="close"&&(B.isClose=!0),B.nodes||(B.type="text"),B.invalid=!0)});let m=s[s.length-1],I=m.nodes.indexOf(o);m.nodes.splice(I,1,...o.nodes)}while(s.length>0);return d({type:"eos"}),n};P1.exports=Kpe});var M1=E((G$e,L1)=>{"use strict";var T1=NE(),Upe=Q1(),Hpe=S1(),Gpe=N1(),Rn=(t,e={})=>{let r=[];if(Array.isArray(t))for(let i of t){let n=Rn.create(i,e);Array.isArray(n)?r.push(...n):r.push(n)}else r=[].concat(Rn.create(t,e));return e&&e.expand===!0&&e.nodupes===!0&&(r=[...new Set(r)]),r};Rn.parse=(t,e={})=>Gpe(t,e);Rn.stringify=(t,e={})=>typeof t=="string"?T1(Rn.parse(t,e),e):T1(t,e);Rn.compile=(t,e={})=>(typeof t=="string"&&(t=Rn.parse(t,e)),Upe(t,e));Rn.expand=(t,e={})=>{typeof t=="string"&&(t=Rn.parse(t,e));let r=Hpe(t,e);return e.noempty===!0&&(r=r.filter(Boolean)),e.nodupes===!0&&(r=[...new Set(r)]),r};Rn.create=(t,e={})=>t===""||t.length<3?[t]:e.expand!==!0?Rn.compile(t,e):Rn.expand(t,e);L1.exports=Rn});var dh=E((j$e,O1)=>{"use strict";var jpe=require("path"),io="\\\\/",K1=`[^${io}]`,ea="\\.",Ype="\\+",qpe="\\?",TE="\\/",Jpe="(?=.)",U1="[^/]",Vb=`(?:${TE}|$)`,H1=`(?:^|${TE})`,_b=`${ea}{1,2}${Vb}`,Wpe=`(?!${ea})`,zpe=`(?!${H1}${_b})`,Vpe=`(?!${ea}{0,1}${Vb})`,_pe=`(?!${_b})`,Xpe=`[^.${TE}]`,Zpe=`${U1}*?`,G1={DOT_LITERAL:ea,PLUS_LITERAL:Ype,QMARK_LITERAL:qpe,SLASH_LITERAL:TE,ONE_CHAR:Jpe,QMARK:U1,END_ANCHOR:Vb,DOTS_SLASH:_b,NO_DOT:Wpe,NO_DOTS:zpe,NO_DOT_SLASH:Vpe,NO_DOTS_SLASH:_pe,QMARK_NO_DOT:Xpe,STAR:Zpe,START_ANCHOR:H1},$pe=_(P({},G1),{SLASH_LITERAL:`[${io}]`,QMARK:K1,STAR:`${K1}*?`,DOTS_SLASH:`${ea}{1,2}(?:[${io}]|$)`,NO_DOT:`(?!${ea})`,NO_DOTS:`(?!(?:^|[${io}])${ea}{1,2}(?:[${io}]|$))`,NO_DOT_SLASH:`(?!${ea}{0,1}(?:[${io}]|$))`,NO_DOTS_SLASH:`(?!${ea}{1,2}(?:[${io}]|$))`,QMARK_NO_DOT:`[^.${io}]`,START_ANCHOR:`(?:^|[${io}])`,END_ANCHOR:`(?:[${io}]|$)`}),ede={alnum:"a-zA-Z0-9",alpha:"a-zA-Z",ascii:"\\x00-\\x7F",blank:" \\t",cntrl:"\\x00-\\x1F\\x7F",digit:"0-9",graph:"\\x21-\\x7E",lower:"a-z",print:"\\x20-\\x7E ",punct:"\\-!\"#$%&'()\\*+,./:;<=>?@[\\]^_`{|}~",space:" \\t\\r\\n\\v\\f",upper:"A-Z",word:"A-Za-z0-9_",xdigit:"A-Fa-f0-9"};O1.exports={MAX_LENGTH:1024*64,POSIX_REGEX_SOURCE:ede,REGEX_BACKSLASH:/\\(?![*+?^${}(|)[\]])/g,REGEX_NON_SPECIAL_CHARS:/^[^@![\].,$*+?^{}()|\\/]+/,REGEX_SPECIAL_CHARS:/[-*+?.^${}(|)[\]]/,REGEX_SPECIAL_CHARS_BACKREF:/(\\?)((\W)(\3*))/g,REGEX_SPECIAL_CHARS_GLOBAL:/([-*+?.^${}(|)[\]])/g,REGEX_REMOVE_BACKSLASH:/(?:\[.*?[^\\]\]|\\(?=.))/g,REPLACEMENTS:{"***":"*","**/**":"**","**/**/**":"**"},CHAR_0:48,CHAR_9:57,CHAR_UPPERCASE_A:65,CHAR_LOWERCASE_A:97,CHAR_UPPERCASE_Z:90,CHAR_LOWERCASE_Z:122,CHAR_LEFT_PARENTHESES:40,CHAR_RIGHT_PARENTHESES:41,CHAR_ASTERISK:42,CHAR_AMPERSAND:38,CHAR_AT:64,CHAR_BACKWARD_SLASH:92,CHAR_CARRIAGE_RETURN:13,CHAR_CIRCUMFLEX_ACCENT:94,CHAR_COLON:58,CHAR_COMMA:44,CHAR_DOT:46,CHAR_DOUBLE_QUOTE:34,CHAR_EQUAL:61,CHAR_EXCLAMATION_MARK:33,CHAR_FORM_FEED:12,CHAR_FORWARD_SLASH:47,CHAR_GRAVE_ACCENT:96,CHAR_HASH:35,CHAR_HYPHEN_MINUS:45,CHAR_LEFT_ANGLE_BRACKET:60,CHAR_LEFT_CURLY_BRACE:123,CHAR_LEFT_SQUARE_BRACKET:91,CHAR_LINE_FEED:10,CHAR_NO_BREAK_SPACE:160,CHAR_PERCENT:37,CHAR_PLUS:43,CHAR_QUESTION_MARK:63,CHAR_RIGHT_ANGLE_BRACKET:62,CHAR_RIGHT_CURLY_BRACE:125,CHAR_RIGHT_SQUARE_BRACKET:93,CHAR_SEMICOLON:59,CHAR_SINGLE_QUOTE:39,CHAR_SPACE:32,CHAR_TAB:9,CHAR_UNDERSCORE:95,CHAR_VERTICAL_LINE:124,CHAR_ZERO_WIDTH_NOBREAK_SPACE:65279,SEP:jpe.sep,extglobChars(t){return{"!":{type:"negate",open:"(?:(?!(?:",close:`))${t.STAR})`},"?":{type:"qmark",open:"(?:",close:")?"},"+":{type:"plus",open:"(?:",close:")+"},"*":{type:"star",open:"(?:",close:")*"},"@":{type:"at",open:"(?:",close:")"}}},globChars(t){return t===!0?$pe:G1}}});var Ch=E(cn=>{"use strict";var tde=require("path"),rde=process.platform==="win32",{REGEX_BACKSLASH:ide,REGEX_REMOVE_BACKSLASH:nde,REGEX_SPECIAL_CHARS:sde,REGEX_SPECIAL_CHARS_GLOBAL:ode}=dh();cn.isObject=t=>t!==null&&typeof t=="object"&&!Array.isArray(t);cn.hasRegexChars=t=>sde.test(t);cn.isRegexChar=t=>t.length===1&&cn.hasRegexChars(t);cn.escapeRegex=t=>t.replace(ode,"\\$1");cn.toPosixSlashes=t=>t.replace(ide,"/");cn.removeBackslashes=t=>t.replace(nde,e=>e==="\\"?"":e);cn.supportsLookbehinds=()=>{let t=process.version.slice(1).split(".").map(Number);return t.length===3&&t[0]>=9||t[0]===8&&t[1]>=10};cn.isWindows=t=>t&&typeof t.windows=="boolean"?t.windows:rde===!0||tde.sep==="\\";cn.escapeLast=(t,e,r)=>{let i=t.lastIndexOf(e,r);return i===-1?t:t[i-1]==="\\"?cn.escapeLast(t,e,i-1):`${t.slice(0,i)}\\${t.slice(i)}`};cn.removePrefix=(t,e={})=>{let r=t;return r.startsWith("./")&&(r=r.slice(2),e.prefix="./"),r};cn.wrapOutput=(t,e={},r={})=>{let i=r.contains?"":"^",n=r.contains?"":"$",s=`${i}(?:${t})${n}`;return e.negated===!0&&(s=`(?:^(?!${s}).*$)`),s}});var X1=E((q$e,j1)=>{"use strict";var Y1=Ch(),{CHAR_ASTERISK:Xb,CHAR_AT:ade,CHAR_BACKWARD_SLASH:mh,CHAR_COMMA:Ade,CHAR_DOT:Zb,CHAR_EXCLAMATION_MARK:q1,CHAR_FORWARD_SLASH:J1,CHAR_LEFT_CURLY_BRACE:$b,CHAR_LEFT_PARENTHESES:ev,CHAR_LEFT_SQUARE_BRACKET:lde,CHAR_PLUS:cde,CHAR_QUESTION_MARK:W1,CHAR_RIGHT_CURLY_BRACE:ude,CHAR_RIGHT_PARENTHESES:z1,CHAR_RIGHT_SQUARE_BRACKET:gde}=dh(),V1=t=>t===J1||t===mh,_1=t=>{t.isPrefix!==!0&&(t.depth=t.isGlobstar?Infinity:1)},fde=(t,e)=>{let r=e||{},i=t.length-1,n=r.parts===!0||r.scanToEnd===!0,s=[],o=[],a=[],l=t,c=-1,u=0,g=0,f=!1,h=!1,p=!1,d=!1,m=!1,I=!1,B=!1,b=!1,R=!1,H=0,L,K,J={value:"",depth:0,isGlob:!1},ne=()=>c>=i,q=()=>l.charCodeAt(c+1),A=()=>(L=K,l.charCodeAt(++c));for(;c0&&(W=l.slice(0,u),l=l.slice(u),g-=u),V&&p===!0&&g>0?(V=l.slice(0,g),X=l.slice(g)):p===!0?(V="",X=l):V=l,V&&V!==""&&V!=="/"&&V!==l&&V1(V.charCodeAt(V.length-1))&&(V=V.slice(0,-1)),r.unescape===!0&&(X&&(X=Y1.removeBackslashes(X)),V&&B===!0&&(V=Y1.removeBackslashes(V)));let F={prefix:W,input:t,start:u,base:V,glob:X,isBrace:f,isBracket:h,isGlob:p,isExtglob:d,isGlobstar:m,negated:b};if(r.tokens===!0&&(F.maxDepth=0,V1(K)||o.push(J),F.tokens=o),r.parts===!0||r.tokens===!0){let D;for(let he=0;he{"use strict";var ME=dh(),Fn=Ch(),{MAX_LENGTH:OE,POSIX_REGEX_SOURCE:hde,REGEX_NON_SPECIAL_CHARS:pde,REGEX_SPECIAL_CHARS_BACKREF:dde,REPLACEMENTS:$1}=ME,Cde=(t,e)=>{if(typeof e.expandRange=="function")return e.expandRange(...t,e);t.sort();let r=`[${t.join("-")}]`;try{new RegExp(r)}catch(i){return t.map(n=>Fn.escapeRegex(n)).join("..")}return r},au=(t,e)=>`Missing ${t}: "${e}" - use "\\\\${e}" to match literal characters`,eU=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");t=$1[t]||t;let r=P({},e),i=typeof r.maxLength=="number"?Math.min(OE,r.maxLength):OE,n=t.length;if(n>i)throw new SyntaxError(`Input length: ${n}, exceeds maximum allowed length: ${i}`);let s={type:"bos",value:"",output:r.prepend||""},o=[s],a=r.capture?"":"?:",l=Fn.isWindows(e),c=ME.globChars(l),u=ME.extglobChars(c),{DOT_LITERAL:g,PLUS_LITERAL:f,SLASH_LITERAL:h,ONE_CHAR:p,DOTS_SLASH:d,NO_DOT:m,NO_DOT_SLASH:I,NO_DOTS_SLASH:B,QMARK:b,QMARK_NO_DOT:R,STAR:H,START_ANCHOR:L}=c,K=G=>`(${a}(?:(?!${L}${G.dot?d:g}).)*?)`,J=r.dot?"":m,ne=r.dot?b:R,q=r.bash===!0?K(r):H;r.capture&&(q=`(${q})`),typeof r.noext=="boolean"&&(r.noextglob=r.noext);let A={input:t,index:-1,start:0,dot:r.dot===!0,consumed:"",output:"",prefix:"",backtrack:!1,negated:!1,brackets:0,braces:0,parens:0,quotes:0,globstar:!1,tokens:o};t=Fn.removePrefix(t,A),n=t.length;let V=[],W=[],X=[],F=s,D,he=()=>A.index===n-1,pe=A.peek=(G=1)=>t[A.index+G],Ne=A.advance=()=>t[++A.index],Pe=()=>t.slice(A.index+1),qe=(G="",Ce=0)=>{A.consumed+=G,A.index+=Ce},re=G=>{A.output+=G.output!=null?G.output:G.value,qe(G.value)},se=()=>{let G=1;for(;pe()==="!"&&(pe(2)!=="("||pe(3)==="?");)Ne(),A.start++,G++;return G%2==0?!1:(A.negated=!0,A.start++,!0)},be=G=>{A[G]++,X.push(G)},ae=G=>{A[G]--,X.pop()},Ae=G=>{if(F.type==="globstar"){let Ce=A.braces>0&&(G.type==="comma"||G.type==="brace"),ee=G.extglob===!0||V.length&&(G.type==="pipe"||G.type==="paren");G.type!=="slash"&&G.type!=="paren"&&!Ce&&!ee&&(A.output=A.output.slice(0,-F.output.length),F.type="star",F.value="*",F.output=q,A.output+=F.output)}if(V.length&&G.type!=="paren"&&!u[G.value]&&(V[V.length-1].inner+=G.value),(G.value||G.output)&&re(G),F&&F.type==="text"&&G.type==="text"){F.value+=G.value,F.output=(F.output||"")+G.value;return}G.prev=F,o.push(G),F=G},De=(G,Ce)=>{let ee=_(P({},u[Ce]),{conditions:1,inner:""});ee.prev=F,ee.parens=A.parens,ee.output=A.output;let Ue=(r.capture?"(":"")+ee.open;be("parens"),Ae({type:G,value:Ce,output:A.output?"":p}),Ae({type:"paren",extglob:!0,value:Ne(),output:Ue}),V.push(ee)},$=G=>{let Ce=G.close+(r.capture?")":"");if(G.type==="negate"){let ee=q;G.inner&&G.inner.length>1&&G.inner.includes("/")&&(ee=K(r)),(ee!==q||he()||/^\)+$/.test(Pe()))&&(Ce=G.close=`)$))${ee}`),G.prev.type==="bos"&&(A.negatedExtglob=!0)}Ae({type:"paren",extglob:!0,value:D,output:Ce}),ae("parens")};if(r.fastpaths!==!1&&!/(^[*!]|[/()[\]{}"])/.test(t)){let G=!1,Ce=t.replace(dde,(ee,Ue,Oe,vt,dt,ri)=>vt==="\\"?(G=!0,ee):vt==="?"?Ue?Ue+vt+(dt?b.repeat(dt.length):""):ri===0?ne+(dt?b.repeat(dt.length):""):b.repeat(Oe.length):vt==="."?g.repeat(Oe.length):vt==="*"?Ue?Ue+vt+(dt?q:""):q:Ue?ee:`\\${ee}`);return G===!0&&(r.unescape===!0?Ce=Ce.replace(/\\/g,""):Ce=Ce.replace(/\\+/g,ee=>ee.length%2==0?"\\\\":ee?"\\":"")),Ce===t&&r.contains===!0?(A.output=t,A):(A.output=Fn.wrapOutput(Ce,A,e),A)}for(;!he();){if(D=Ne(),D==="\0")continue;if(D==="\\"){let ee=pe();if(ee==="/"&&r.bash!==!0||ee==="."||ee===";")continue;if(!ee){D+="\\",Ae({type:"text",value:D});continue}let Ue=/^\\+/.exec(Pe()),Oe=0;if(Ue&&Ue[0].length>2&&(Oe=Ue[0].length,A.index+=Oe,Oe%2!=0&&(D+="\\")),r.unescape===!0?D=Ne()||"":D+=Ne()||"",A.brackets===0){Ae({type:"text",value:D});continue}}if(A.brackets>0&&(D!=="]"||F.value==="["||F.value==="[^")){if(r.posix!==!1&&D===":"){let ee=F.value.slice(1);if(ee.includes("[")&&(F.posix=!0,ee.includes(":"))){let Ue=F.value.lastIndexOf("["),Oe=F.value.slice(0,Ue),vt=F.value.slice(Ue+2),dt=hde[vt];if(dt){F.value=Oe+dt,A.backtrack=!0,Ne(),!s.output&&o.indexOf(F)===1&&(s.output=p);continue}}}(D==="["&&pe()!==":"||D==="-"&&pe()==="]")&&(D=`\\${D}`),D==="]"&&(F.value==="["||F.value==="[^")&&(D=`\\${D}`),r.posix===!0&&D==="!"&&F.value==="["&&(D="^"),F.value+=D,re({value:D});continue}if(A.quotes===1&&D!=='"'){D=Fn.escapeRegex(D),F.value+=D,re({value:D});continue}if(D==='"'){A.quotes=A.quotes===1?0:1,r.keepQuotes===!0&&Ae({type:"text",value:D});continue}if(D==="("){be("parens"),Ae({type:"paren",value:D});continue}if(D===")"){if(A.parens===0&&r.strictBrackets===!0)throw new SyntaxError(au("opening","("));let ee=V[V.length-1];if(ee&&A.parens===ee.parens+1){$(V.pop());continue}Ae({type:"paren",value:D,output:A.parens?")":"\\)"}),ae("parens");continue}if(D==="["){if(r.nobracket===!0||!Pe().includes("]")){if(r.nobracket!==!0&&r.strictBrackets===!0)throw new SyntaxError(au("closing","]"));D=`\\${D}`}else be("brackets");Ae({type:"bracket",value:D});continue}if(D==="]"){if(r.nobracket===!0||F&&F.type==="bracket"&&F.value.length===1){Ae({type:"text",value:D,output:`\\${D}`});continue}if(A.brackets===0){if(r.strictBrackets===!0)throw new SyntaxError(au("opening","["));Ae({type:"text",value:D,output:`\\${D}`});continue}ae("brackets");let ee=F.value.slice(1);if(F.posix!==!0&&ee[0]==="^"&&!ee.includes("/")&&(D=`/${D}`),F.value+=D,re({value:D}),r.literalBrackets===!1||Fn.hasRegexChars(ee))continue;let Ue=Fn.escapeRegex(F.value);if(A.output=A.output.slice(0,-F.value.length),r.literalBrackets===!0){A.output+=Ue,F.value=Ue;continue}F.value=`(${a}${Ue}|${F.value})`,A.output+=F.value;continue}if(D==="{"&&r.nobrace!==!0){be("braces");let ee={type:"brace",value:D,output:"(",outputIndex:A.output.length,tokensIndex:A.tokens.length};W.push(ee),Ae(ee);continue}if(D==="}"){let ee=W[W.length-1];if(r.nobrace===!0||!ee){Ae({type:"text",value:D,output:D});continue}let Ue=")";if(ee.dots===!0){let Oe=o.slice(),vt=[];for(let dt=Oe.length-1;dt>=0&&(o.pop(),Oe[dt].type!=="brace");dt--)Oe[dt].type!=="dots"&&vt.unshift(Oe[dt].value);Ue=Cde(vt,r),A.backtrack=!0}if(ee.comma!==!0&&ee.dots!==!0){let Oe=A.output.slice(0,ee.outputIndex),vt=A.tokens.slice(ee.tokensIndex);ee.value=ee.output="\\{",D=Ue="\\}",A.output=Oe;for(let dt of vt)A.output+=dt.output||dt.value}Ae({type:"brace",value:D,output:Ue}),ae("braces"),W.pop();continue}if(D==="|"){V.length>0&&V[V.length-1].conditions++,Ae({type:"text",value:D});continue}if(D===","){let ee=D,Ue=W[W.length-1];Ue&&X[X.length-1]==="braces"&&(Ue.comma=!0,ee="|"),Ae({type:"comma",value:D,output:ee});continue}if(D==="/"){if(F.type==="dot"&&A.index===A.start+1){A.start=A.index+1,A.consumed="",A.output="",o.pop(),F=s;continue}Ae({type:"slash",value:D,output:h});continue}if(D==="."){if(A.braces>0&&F.type==="dot"){F.value==="."&&(F.output=g);let ee=W[W.length-1];F.type="dots",F.output+=D,F.value+=D,ee.dots=!0;continue}if(A.braces+A.parens===0&&F.type!=="bos"&&F.type!=="slash"){Ae({type:"text",value:D,output:g});continue}Ae({type:"dot",value:D,output:g});continue}if(D==="?"){if(!(F&&F.value==="(")&&r.noextglob!==!0&&pe()==="("&&pe(2)!=="?"){De("qmark",D);continue}if(F&&F.type==="paren"){let Ue=pe(),Oe=D;if(Ue==="<"&&!Fn.supportsLookbehinds())throw new Error("Node.js v10 or higher is required for regex lookbehinds");(F.value==="("&&!/[!=<:]/.test(Ue)||Ue==="<"&&!/<([!=]|\w+>)/.test(Pe()))&&(Oe=`\\${D}`),Ae({type:"text",value:D,output:Oe});continue}if(r.dot!==!0&&(F.type==="slash"||F.type==="bos")){Ae({type:"qmark",value:D,output:R});continue}Ae({type:"qmark",value:D,output:b});continue}if(D==="!"){if(r.noextglob!==!0&&pe()==="("&&(pe(2)!=="?"||!/[!=<:]/.test(pe(3)))){De("negate",D);continue}if(r.nonegate!==!0&&A.index===0){se();continue}}if(D==="+"){if(r.noextglob!==!0&&pe()==="("&&pe(2)!=="?"){De("plus",D);continue}if(F&&F.value==="("||r.regex===!1){Ae({type:"plus",value:D,output:f});continue}if(F&&(F.type==="bracket"||F.type==="paren"||F.type==="brace")||A.parens>0){Ae({type:"plus",value:D});continue}Ae({type:"plus",value:f});continue}if(D==="@"){if(r.noextglob!==!0&&pe()==="("&&pe(2)!=="?"){Ae({type:"at",extglob:!0,value:D,output:""});continue}Ae({type:"text",value:D});continue}if(D!=="*"){(D==="$"||D==="^")&&(D=`\\${D}`);let ee=pde.exec(Pe());ee&&(D+=ee[0],A.index+=ee[0].length),Ae({type:"text",value:D});continue}if(F&&(F.type==="globstar"||F.star===!0)){F.type="star",F.star=!0,F.value+=D,F.output=q,A.backtrack=!0,A.globstar=!0,qe(D);continue}let G=Pe();if(r.noextglob!==!0&&/^\([^?]/.test(G)){De("star",D);continue}if(F.type==="star"){if(r.noglobstar===!0){qe(D);continue}let ee=F.prev,Ue=ee.prev,Oe=ee.type==="slash"||ee.type==="bos",vt=Ue&&(Ue.type==="star"||Ue.type==="globstar");if(r.bash===!0&&(!Oe||G[0]&&G[0]!=="/")){Ae({type:"star",value:D,output:""});continue}let dt=A.braces>0&&(ee.type==="comma"||ee.type==="brace"),ri=V.length&&(ee.type==="pipe"||ee.type==="paren");if(!Oe&&ee.type!=="paren"&&!dt&&!ri){Ae({type:"star",value:D,output:""});continue}for(;G.slice(0,3)==="/**";){let ii=t[A.index+4];if(ii&&ii!=="/")break;G=G.slice(3),qe("/**",3)}if(ee.type==="bos"&&he()){F.type="globstar",F.value+=D,F.output=K(r),A.output=F.output,A.globstar=!0,qe(D);continue}if(ee.type==="slash"&&ee.prev.type!=="bos"&&!vt&&he()){A.output=A.output.slice(0,-(ee.output+F.output).length),ee.output=`(?:${ee.output}`,F.type="globstar",F.output=K(r)+(r.strictSlashes?")":"|$)"),F.value+=D,A.globstar=!0,A.output+=ee.output+F.output,qe(D);continue}if(ee.type==="slash"&&ee.prev.type!=="bos"&&G[0]==="/"){let ii=G[1]!==void 0?"|$":"";A.output=A.output.slice(0,-(ee.output+F.output).length),ee.output=`(?:${ee.output}`,F.type="globstar",F.output=`${K(r)}${h}|${h}${ii})`,F.value+=D,A.output+=ee.output+F.output,A.globstar=!0,qe(D+Ne()),Ae({type:"slash",value:"/",output:""});continue}if(ee.type==="bos"&&G[0]==="/"){F.type="globstar",F.value+=D,F.output=`(?:^|${h}|${K(r)}${h})`,A.output=F.output,A.globstar=!0,qe(D+Ne()),Ae({type:"slash",value:"/",output:""});continue}A.output=A.output.slice(0,-F.output.length),F.type="globstar",F.output=K(r),F.value+=D,A.output+=F.output,A.globstar=!0,qe(D);continue}let Ce={type:"star",value:D,output:q};if(r.bash===!0){Ce.output=".*?",(F.type==="bos"||F.type==="slash")&&(Ce.output=J+Ce.output),Ae(Ce);continue}if(F&&(F.type==="bracket"||F.type==="paren")&&r.regex===!0){Ce.output=D,Ae(Ce);continue}(A.index===A.start||F.type==="slash"||F.type==="dot")&&(F.type==="dot"?(A.output+=I,F.output+=I):r.dot===!0?(A.output+=B,F.output+=B):(A.output+=J,F.output+=J),pe()!=="*"&&(A.output+=p,F.output+=p)),Ae(Ce)}for(;A.brackets>0;){if(r.strictBrackets===!0)throw new SyntaxError(au("closing","]"));A.output=Fn.escapeLast(A.output,"["),ae("brackets")}for(;A.parens>0;){if(r.strictBrackets===!0)throw new SyntaxError(au("closing",")"));A.output=Fn.escapeLast(A.output,"("),ae("parens")}for(;A.braces>0;){if(r.strictBrackets===!0)throw new SyntaxError(au("closing","}"));A.output=Fn.escapeLast(A.output,"{"),ae("braces")}if(r.strictSlashes!==!0&&(F.type==="star"||F.type==="bracket")&&Ae({type:"maybe_slash",value:"",output:`${h}?`}),A.backtrack===!0){A.output="";for(let G of A.tokens)A.output+=G.output!=null?G.output:G.value,G.suffix&&(A.output+=G.suffix)}return A};eU.fastpaths=(t,e)=>{let r=P({},e),i=typeof r.maxLength=="number"?Math.min(OE,r.maxLength):OE,n=t.length;if(n>i)throw new SyntaxError(`Input length: ${n}, exceeds maximum allowed length: ${i}`);t=$1[t]||t;let s=Fn.isWindows(e),{DOT_LITERAL:o,SLASH_LITERAL:a,ONE_CHAR:l,DOTS_SLASH:c,NO_DOT:u,NO_DOTS:g,NO_DOTS_SLASH:f,STAR:h,START_ANCHOR:p}=ME.globChars(s),d=r.dot?g:u,m=r.dot?f:u,I=r.capture?"":"?:",B={negated:!1,prefix:""},b=r.bash===!0?".*?":h;r.capture&&(b=`(${b})`);let R=J=>J.noglobstar===!0?b:`(${I}(?:(?!${p}${J.dot?c:o}).)*?)`,H=J=>{switch(J){case"*":return`${d}${l}${b}`;case".*":return`${o}${l}${b}`;case"*.*":return`${d}${b}${o}${l}${b}`;case"*/*":return`${d}${b}${a}${l}${m}${b}`;case"**":return d+R(r);case"**/*":return`(?:${d}${R(r)}${a})?${m}${l}${b}`;case"**/*.*":return`(?:${d}${R(r)}${a})?${m}${b}${o}${l}${b}`;case"**/.*":return`(?:${d}${R(r)}${a})?${o}${l}${b}`;default:{let ne=/^(.*?)\.(\w+)$/.exec(J);if(!ne)return;let q=H(ne[1]);return q?q+o+ne[2]:void 0}}},L=Fn.removePrefix(t,B),K=H(L);return K&&r.strictSlashes!==!0&&(K+=`${a}?`),K};Z1.exports=eU});var iU=E((W$e,rU)=>{"use strict";var mde=require("path"),Ede=X1(),tv=tU(),rv=Ch(),Ide=dh(),yde=t=>t&&typeof t=="object"&&!Array.isArray(t),Dr=(t,e,r=!1)=>{if(Array.isArray(t)){let u=t.map(f=>Dr(f,e,r));return f=>{for(let h of u){let p=h(f);if(p)return p}return!1}}let i=yde(t)&&t.tokens&&t.input;if(t===""||typeof t!="string"&&!i)throw new TypeError("Expected pattern to be a non-empty string");let n=e||{},s=rv.isWindows(e),o=i?Dr.compileRe(t,e):Dr.makeRe(t,e,!1,!0),a=o.state;delete o.state;let l=()=>!1;if(n.ignore){let u=_(P({},e),{ignore:null,onMatch:null,onResult:null});l=Dr(n.ignore,u,r)}let c=(u,g=!1)=>{let{isMatch:f,match:h,output:p}=Dr.test(u,o,e,{glob:t,posix:s}),d={glob:t,state:a,regex:o,posix:s,input:u,output:p,match:h,isMatch:f};return typeof n.onResult=="function"&&n.onResult(d),f===!1?(d.isMatch=!1,g?d:!1):l(u)?(typeof n.onIgnore=="function"&&n.onIgnore(d),d.isMatch=!1,g?d:!1):(typeof n.onMatch=="function"&&n.onMatch(d),g?d:!0)};return r&&(c.state=a),c};Dr.test=(t,e,r,{glob:i,posix:n}={})=>{if(typeof t!="string")throw new TypeError("Expected input to be a string");if(t==="")return{isMatch:!1,output:""};let s=r||{},o=s.format||(n?rv.toPosixSlashes:null),a=t===i,l=a&&o?o(t):t;return a===!1&&(l=o?o(t):t,a=l===i),(a===!1||s.capture===!0)&&(s.matchBase===!0||s.basename===!0?a=Dr.matchBase(t,e,r,n):a=e.exec(l)),{isMatch:Boolean(a),match:a,output:l}};Dr.matchBase=(t,e,r,i=rv.isWindows(r))=>(e instanceof RegExp?e:Dr.makeRe(e,r)).test(mde.basename(t));Dr.isMatch=(t,e,r)=>Dr(e,r)(t);Dr.parse=(t,e)=>Array.isArray(t)?t.map(r=>Dr.parse(r,e)):tv(t,_(P({},e),{fastpaths:!1}));Dr.scan=(t,e)=>Ede(t,e);Dr.compileRe=(t,e,r=!1,i=!1)=>{if(r===!0)return t.output;let n=e||{},s=n.contains?"":"^",o=n.contains?"":"$",a=`${s}(?:${t.output})${o}`;t&&t.negated===!0&&(a=`^(?!${a}).*$`);let l=Dr.toRegex(a,e);return i===!0&&(l.state=t),l};Dr.makeRe=(t,e,r=!1,i=!1)=>{if(!t||typeof t!="string")throw new TypeError("Expected a non-empty string");let n=e||{},s={negated:!1,fastpaths:!0},o="",a;return t.startsWith("./")&&(t=t.slice(2),o=s.prefix="./"),n.fastpaths!==!1&&(t[0]==="."||t[0]==="*")&&(a=tv.fastpaths(t,e)),a===void 0?(s=tv(t,e),s.prefix=o+(s.prefix||"")):s.output=a,Dr.compileRe(s,e,r,i)};Dr.toRegex=(t,e)=>{try{let r=e||{};return new RegExp(t,r.flags||(r.nocase?"i":""))}catch(r){if(e&&e.debug===!0)throw r;return/$^/}};Dr.constants=Ide;rU.exports=Dr});var iv=E((z$e,nU)=>{"use strict";nU.exports=iU()});var Nn=E((V$e,sU)=>{"use strict";var oU=require("util"),aU=M1(),no=iv(),nv=Ch(),AU=t=>typeof t=="string"&&(t===""||t==="./"),pr=(t,e,r)=>{e=[].concat(e),t=[].concat(t);let i=new Set,n=new Set,s=new Set,o=0,a=u=>{s.add(u.output),r&&r.onResult&&r.onResult(u)};for(let u=0;u!i.has(u));if(r&&c.length===0){if(r.failglob===!0)throw new Error(`No matches found for "${e.join(", ")}"`);if(r.nonull===!0||r.nullglob===!0)return r.unescape?e.map(u=>u.replace(/\\/g,"")):e}return c};pr.match=pr;pr.matcher=(t,e)=>no(t,e);pr.isMatch=(t,e,r)=>no(e,r)(t);pr.any=pr.isMatch;pr.not=(t,e,r={})=>{e=[].concat(e).map(String);let i=new Set,n=[],s=a=>{r.onResult&&r.onResult(a),n.push(a.output)},o=pr(t,e,_(P({},r),{onResult:s}));for(let a of n)o.includes(a)||i.add(a);return[...i]};pr.contains=(t,e,r)=>{if(typeof t!="string")throw new TypeError(`Expected a string: "${oU.inspect(t)}"`);if(Array.isArray(e))return e.some(i=>pr.contains(t,i,r));if(typeof e=="string"){if(AU(t)||AU(e))return!1;if(t.includes(e)||t.startsWith("./")&&t.slice(2).includes(e))return!0}return pr.isMatch(t,e,_(P({},r),{contains:!0}))};pr.matchKeys=(t,e,r)=>{if(!nv.isObject(t))throw new TypeError("Expected the first argument to be an object");let i=pr(Object.keys(t),e,r),n={};for(let s of i)n[s]=t[s];return n};pr.some=(t,e,r)=>{let i=[].concat(t);for(let n of[].concat(e)){let s=no(String(n),r);if(i.some(o=>s(o)))return!0}return!1};pr.every=(t,e,r)=>{let i=[].concat(t);for(let n of[].concat(e)){let s=no(String(n),r);if(!i.every(o=>s(o)))return!1}return!0};pr.all=(t,e,r)=>{if(typeof t!="string")throw new TypeError(`Expected a string: "${oU.inspect(t)}"`);return[].concat(e).every(i=>no(i,r)(t))};pr.capture=(t,e,r)=>{let i=nv.isWindows(r),s=no.makeRe(String(t),_(P({},r),{capture:!0})).exec(i?nv.toPosixSlashes(e):e);if(s)return s.slice(1).map(o=>o===void 0?"":o)};pr.makeRe=(...t)=>no.makeRe(...t);pr.scan=(...t)=>no.scan(...t);pr.parse=(t,e)=>{let r=[];for(let i of[].concat(t||[]))for(let n of aU(String(i),e))r.push(no.parse(n,e));return r};pr.braces=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");return e&&e.nobrace===!0||!/\{.*\}/.test(t)?[t]:aU(t,e)};pr.braceExpand=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");return pr.braces(t,_(P({},e),{expand:!0}))};sU.exports=pr});var cU=E((_$e,lU)=>{"use strict";lU.exports=({onlyFirst:t=!1}={})=>{let e=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:[a-zA-Z\\d]*(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(e,t?void 0:"g")}});var gU=E((X$e,uU)=>{"use strict";var wde=cU();uU.exports=t=>typeof t=="string"?t.replace(wde(),""):t});var lu={};it(lu,{KeyRelationship:()=>Bl,applyCascade:()=>fv,base64RegExp:()=>CU,colorStringAlphaRegExp:()=>dU,colorStringRegExp:()=>pU,computeKey:()=>rA,getPrintable:()=>Mr,hasExactLength:()=>wU,hasForbiddenKeys:()=>eCe,hasKeyRelationship:()=>pv,hasMaxLength:()=>Mde,hasMinLength:()=>Tde,hasMutuallyExclusiveKeys:()=>tCe,hasRequiredKeys:()=>$de,hasUniqueItems:()=>Ode,isArray:()=>xde,isAtLeast:()=>Hde,isAtMost:()=>Gde,isBase64:()=>Xde,isBoolean:()=>bde,isDate:()=>Sde,isDict:()=>Pde,isEnum:()=>Yi,isHexColor:()=>_de,isISO8601:()=>Vde,isInExclusiveRange:()=>Yde,isInInclusiveRange:()=>jde,isInstanceOf:()=>Rde,isInteger:()=>qde,isJSON:()=>Zde,isLiteral:()=>Bde,isLowerCase:()=>Jde,isNegative:()=>Kde,isNullable:()=>Lde,isNumber:()=>vde,isObject:()=>Dde,isOneOf:()=>Fde,isOptional:()=>Nde,isPositive:()=>Ude,isString:()=>gv,isTuple:()=>kde,isUUID4:()=>zde,isUnknown:()=>yU,isUpperCase:()=>Wde,iso8601RegExp:()=>uv,makeCoercionFn:()=>wl,makeSetter:()=>IU,makeTrait:()=>EU,makeValidator:()=>Ct,matchesRegExp:()=>hv,plural:()=>GE,pushError:()=>at,simpleKeyRegExp:()=>hU,uuid4RegExp:()=>mU});function Ct({test:t}){return EU(t)()}function Mr(t){return t===null?"null":t===void 0?"undefined":t===""?"an empty string":JSON.stringify(t)}function rA(t,e){var r,i,n;return typeof e=="number"?`${(r=t==null?void 0:t.p)!==null&&r!==void 0?r:"."}[${e}]`:hU.test(e)?`${(i=t==null?void 0:t.p)!==null&&i!==void 0?i:""}.${e}`:`${(n=t==null?void 0:t.p)!==null&&n!==void 0?n:"."}[${JSON.stringify(e)}]`}function wl(t,e){return r=>{let i=t[e];return t[e]=r,wl(t,e).bind(null,i)}}function IU(t,e){return r=>{t[e]=r}}function GE(t,e,r){return t===1?e:r}function at({errors:t,p:e}={},r){return t==null||t.push(`${e!=null?e:"."}: ${r}`),!1}function Bde(t){return Ct({test:(e,r)=>e!==t?at(r,`Expected a literal (got ${Mr(t)})`):!0})}function Yi(t){let e=Array.isArray(t)?t:Object.values(t),r=new Set(e);return Ct({test:(i,n)=>r.has(i)?!0:at(n,`Expected a valid enumeration value (got ${Mr(i)})`)})}var hU,pU,dU,CU,mU,uv,EU,yU,gv,Qde,bde,vde,Sde,xde,kde,Pde,Dde,Rde,Fde,fv,Nde,Lde,Tde,Mde,wU,Ode,Kde,Ude,Hde,Gde,jde,Yde,qde,hv,Jde,Wde,zde,Vde,_de,Xde,Zde,$de,eCe,tCe,Bl,rCe,pv,Ss=Yfe(()=>{hU=/^[a-zA-Z_][a-zA-Z0-9_]*$/,pU=/^#[0-9a-f]{6}$/i,dU=/^#[0-9a-f]{6}([0-9a-f]{2})?$/i,CU=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/,mU=/^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89aAbB][a-f0-9]{3}-[a-f0-9]{12}$/i,uv=/^(?:[1-9]\d{3}(-?)(?:(?:0[1-9]|1[0-2])\1(?:0[1-9]|1\d|2[0-8])|(?:0[13-9]|1[0-2])\1(?:29|30)|(?:0[13578]|1[02])(?:\1)31|00[1-9]|0[1-9]\d|[12]\d{2}|3(?:[0-5]\d|6[0-5]))|(?:[1-9]\d(?:0[48]|[2468][048]|[13579][26])|(?:[2468][048]|[13579][26])00)(?:(-?)02(?:\2)29|-?366))T(?:[01]\d|2[0-3])(:?)[0-5]\d(?:\3[0-5]\d)?(?:Z|[+-][01]\d(?:\3[0-5]\d)?)$/,EU=t=>()=>t;yU=()=>Ct({test:(t,e)=>!0});gv=()=>Ct({test:(t,e)=>typeof t!="string"?at(e,`Expected a string (got ${Mr(t)})`):!0});Qde=new Map([["true",!0],["True",!0],["1",!0],[1,!0],["false",!1],["False",!1],["0",!1],[0,!1]]),bde=()=>Ct({test:(t,e)=>{var r;if(typeof t!="boolean"){if(typeof(e==null?void 0:e.coercions)!="undefined"){if(typeof(e==null?void 0:e.coercion)=="undefined")return at(e,"Unbound coercion result");let i=Qde.get(t);if(typeof i!="undefined")return e.coercions.push([(r=e.p)!==null&&r!==void 0?r:".",e.coercion.bind(null,i)]),!0}return at(e,`Expected a boolean (got ${Mr(t)})`)}return!0}}),vde=()=>Ct({test:(t,e)=>{var r;if(typeof t!="number"){if(typeof(e==null?void 0:e.coercions)!="undefined"){if(typeof(e==null?void 0:e.coercion)=="undefined")return at(e,"Unbound coercion result");let i;if(typeof t=="string"){let n;try{n=JSON.parse(t)}catch(s){}if(typeof n=="number")if(JSON.stringify(n)===t)i=n;else return at(e,`Received a number that can't be safely represented by the runtime (${t})`)}if(typeof i!="undefined")return e.coercions.push([(r=e.p)!==null&&r!==void 0?r:".",e.coercion.bind(null,i)]),!0}return at(e,`Expected a number (got ${Mr(t)})`)}return!0}}),Sde=()=>Ct({test:(t,e)=>{var r;if(!(t instanceof Date)){if(typeof(e==null?void 0:e.coercions)!="undefined"){if(typeof(e==null?void 0:e.coercion)=="undefined")return at(e,"Unbound coercion result");let i;if(typeof t=="string"&&uv.test(t))i=new Date(t);else{let n;if(typeof t=="string"){let s;try{s=JSON.parse(t)}catch(o){}typeof s=="number"&&(n=s)}else typeof t=="number"&&(n=t);if(typeof n!="undefined")if(Number.isSafeInteger(n)||!Number.isSafeInteger(n*1e3))i=new Date(n*1e3);else return at(e,`Received a timestamp that can't be safely represented by the runtime (${t})`)}if(typeof i!="undefined")return e.coercions.push([(r=e.p)!==null&&r!==void 0?r:".",e.coercion.bind(null,i)]),!0}return at(e,`Expected a date (got ${Mr(t)})`)}return!0}}),xde=(t,{delimiter:e}={})=>Ct({test:(r,i)=>{var n;if(typeof r=="string"&&typeof e!="undefined"&&typeof(i==null?void 0:i.coercions)!="undefined"){if(typeof(i==null?void 0:i.coercion)=="undefined")return at(i,"Unbound coercion result");r=r.split(e),i.coercions.push([(n=i.p)!==null&&n!==void 0?n:".",i.coercion.bind(null,r)])}if(!Array.isArray(r))return at(i,`Expected an array (got ${Mr(r)})`);let s=!0;for(let o=0,a=r.length;o{let r=wU(t.length);return Ct({test:(i,n)=>{var s;if(typeof i=="string"&&typeof e!="undefined"&&typeof(n==null?void 0:n.coercions)!="undefined"){if(typeof(n==null?void 0:n.coercion)=="undefined")return at(n,"Unbound coercion result");i=i.split(e),n.coercions.push([(s=n.p)!==null&&s!==void 0?s:".",n.coercion.bind(null,i)])}if(!Array.isArray(i))return at(n,`Expected a tuple (got ${Mr(i)})`);let o=r(i,Object.assign({},n));for(let a=0,l=i.length;aCt({test:(r,i)=>{if(typeof r!="object"||r===null)return at(i,`Expected an object (got ${Mr(r)})`);let n=Object.keys(r),s=!0;for(let o=0,a=n.length;o{let r=Object.keys(t);return Ct({test:(i,n)=>{if(typeof i!="object"||i===null)return at(n,`Expected an object (got ${Mr(i)})`);let s=new Set([...r,...Object.keys(i)]),o={},a=!0;for(let l of s){if(l==="constructor"||l==="__proto__")a=at(Object.assign(Object.assign({},n),{p:rA(n,l)}),"Unsafe property name");else{let c=Object.prototype.hasOwnProperty.call(t,l)?t[l]:void 0,u=Object.prototype.hasOwnProperty.call(i,l)?i[l]:void 0;typeof c!="undefined"?a=c(u,Object.assign(Object.assign({},n),{p:rA(n,l),coercion:wl(i,l)}))&&a:e===null?a=at(Object.assign(Object.assign({},n),{p:rA(n,l)}),`Extraneous property (got ${Mr(u)})`):Object.defineProperty(o,l,{enumerable:!0,get:()=>u,set:IU(i,l)})}if(!a&&(n==null?void 0:n.errors)==null)break}return e!==null&&(a||(n==null?void 0:n.errors)!=null)&&(a=e(o,n)&&a),a}})},Rde=t=>Ct({test:(e,r)=>e instanceof t?!0:at(r,`Expected an instance of ${t.name} (got ${Mr(e)})`)}),Fde=(t,{exclusive:e=!1}={})=>Ct({test:(r,i)=>{var n,s,o;let a=[],l=typeof(i==null?void 0:i.errors)!="undefined"?[]:void 0;for(let c=0,u=t.length;c1?at(i,`Expected to match exactly a single predicate (matched ${a.join(", ")})`):(o=i==null?void 0:i.errors)===null||o===void 0||o.push(...l),!1}}),fv=(t,e)=>Ct({test:(r,i)=>{var n,s;let o={value:r},a=typeof(i==null?void 0:i.coercions)!="undefined"?wl(o,"value"):void 0,l=typeof(i==null?void 0:i.coercions)!="undefined"?[]:void 0;if(!t(r,Object.assign(Object.assign({},i),{coercion:a,coercions:l})))return!1;let c=[];if(typeof l!="undefined")for(let[,u]of l)c.push(u());try{if(typeof(i==null?void 0:i.coercions)!="undefined"){if(o.value!==r){if(typeof(i==null?void 0:i.coercion)=="undefined")return at(i,"Unbound coercion result");i.coercions.push([(n=i.p)!==null&&n!==void 0?n:".",i.coercion.bind(null,o.value)])}(s=i==null?void 0:i.coercions)===null||s===void 0||s.push(...l)}return e.every(u=>u(o.value,i))}finally{for(let u of c)u()}}}),Nde=t=>Ct({test:(e,r)=>typeof e=="undefined"?!0:t(e,r)}),Lde=t=>Ct({test:(e,r)=>e===null?!0:t(e,r)}),Tde=t=>Ct({test:(e,r)=>e.length>=t?!0:at(r,`Expected to have a length of at least ${t} elements (got ${e.length})`)}),Mde=t=>Ct({test:(e,r)=>e.length<=t?!0:at(r,`Expected to have a length of at most ${t} elements (got ${e.length})`)}),wU=t=>Ct({test:(e,r)=>e.length!==t?at(r,`Expected to have a length of exactly ${t} elements (got ${e.length})`):!0}),Ode=({map:t}={})=>Ct({test:(e,r)=>{let i=new Set,n=new Set;for(let s=0,o=e.length;sCt({test:(t,e)=>t<=0?!0:at(e,`Expected to be negative (got ${t})`)}),Ude=()=>Ct({test:(t,e)=>t>=0?!0:at(e,`Expected to be positive (got ${t})`)}),Hde=t=>Ct({test:(e,r)=>e>=t?!0:at(r,`Expected to be at least ${t} (got ${e})`)}),Gde=t=>Ct({test:(e,r)=>e<=t?!0:at(r,`Expected to be at most ${t} (got ${e})`)}),jde=(t,e)=>Ct({test:(r,i)=>r>=t&&r<=e?!0:at(i,`Expected to be in the [${t}; ${e}] range (got ${r})`)}),Yde=(t,e)=>Ct({test:(r,i)=>r>=t&&rCt({test:(e,r)=>e!==Math.round(e)?at(r,`Expected to be an integer (got ${e})`):Number.isSafeInteger(e)?!0:at(r,`Expected to be a safe integer (got ${e})`)}),hv=t=>Ct({test:(e,r)=>t.test(e)?!0:at(r,`Expected to match the pattern ${t.toString()} (got ${Mr(e)})`)}),Jde=()=>Ct({test:(t,e)=>t!==t.toLowerCase()?at(e,`Expected to be all-lowercase (got ${t})`):!0}),Wde=()=>Ct({test:(t,e)=>t!==t.toUpperCase()?at(e,`Expected to be all-uppercase (got ${t})`):!0}),zde=()=>Ct({test:(t,e)=>mU.test(t)?!0:at(e,`Expected to be a valid UUID v4 (got ${Mr(t)})`)}),Vde=()=>Ct({test:(t,e)=>uv.test(t)?!1:at(e,`Expected to be a valid ISO 8601 date string (got ${Mr(t)})`)}),_de=({alpha:t=!1})=>Ct({test:(e,r)=>(t?pU.test(e):dU.test(e))?!0:at(r,`Expected to be a valid hexadecimal color string (got ${Mr(e)})`)}),Xde=()=>Ct({test:(t,e)=>CU.test(t)?!0:at(e,`Expected to be a valid base 64 string (got ${Mr(t)})`)}),Zde=(t=yU())=>Ct({test:(e,r)=>{let i;try{i=JSON.parse(e)}catch(n){return at(r,`Expected to be a valid JSON string (got ${Mr(e)})`)}return t(i,r)}}),$de=t=>{let e=new Set(t);return Ct({test:(r,i)=>{let n=new Set(Object.keys(r)),s=[];for(let o of e)n.has(o)||s.push(o);return s.length>0?at(i,`Missing required ${GE(s.length,"property","properties")} ${s.map(o=>`"${o}"`).join(", ")}`):!0}})},eCe=t=>{let e=new Set(t);return Ct({test:(r,i)=>{let n=new Set(Object.keys(r)),s=[];for(let o of e)n.has(o)&&s.push(o);return s.length>0?at(i,`Forbidden ${GE(s.length,"property","properties")} ${s.map(o=>`"${o}"`).join(", ")}`):!0}})},tCe=t=>{let e=new Set(t);return Ct({test:(r,i)=>{let n=new Set(Object.keys(r)),s=[];for(let o of e)n.has(o)&&s.push(o);return s.length>1?at(i,`Mutually exclusive properties ${s.map(o=>`"${o}"`).join(", ")}`):!0}})};(function(t){t.Forbids="Forbids",t.Requires="Requires"})(Bl||(Bl={}));rCe={[Bl.Forbids]:{expect:!1,message:"forbids using"},[Bl.Requires]:{expect:!0,message:"requires using"}},pv=(t,e,r,{ignore:i=[]}={})=>{let n=new Set(i),s=new Set(r),o=rCe[e];return Ct({test:(a,l)=>{let c=new Set(Object.keys(a));if(!c.has(t)||n.has(a[t]))return!0;let u=[];for(let g of s)(c.has(g)&&!n.has(a[g]))!==o.expect&&u.push(g);return u.length>=1?at(l,`Property "${t}" ${o.message} ${GE(u.length,"property","properties")} ${u.map(g=>`"${g}"`).join(", ")}`):!0}})}});var Sh=E(($et,OU)=>{var mCe="2.0.0",ECe=256,ICe=Number.MAX_SAFE_INTEGER||9007199254740991,yCe=16;OU.exports={SEMVER_SPEC_VERSION:mCe,MAX_LENGTH:ECe,MAX_SAFE_INTEGER:ICe,MAX_SAFE_COMPONENT_LENGTH:yCe}});var xh=E((ett,KU)=>{var wCe=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...t)=>console.error("SEMVER",...t):()=>{};KU.exports=wCe});var Ql=E((iA,UU)=>{var{MAX_SAFE_COMPONENT_LENGTH:yv}=Sh(),BCe=xh();iA=UU.exports={};var QCe=iA.re=[],Je=iA.src=[],We=iA.t={},bCe=0,mt=(t,e,r)=>{let i=bCe++;BCe(i,e),We[t]=i,Je[i]=e,QCe[i]=new RegExp(e,r?"g":void 0)};mt("NUMERICIDENTIFIER","0|[1-9]\\d*");mt("NUMERICIDENTIFIERLOOSE","[0-9]+");mt("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*");mt("MAINVERSION",`(${Je[We.NUMERICIDENTIFIER]})\\.(${Je[We.NUMERICIDENTIFIER]})\\.(${Je[We.NUMERICIDENTIFIER]})`);mt("MAINVERSIONLOOSE",`(${Je[We.NUMERICIDENTIFIERLOOSE]})\\.(${Je[We.NUMERICIDENTIFIERLOOSE]})\\.(${Je[We.NUMERICIDENTIFIERLOOSE]})`);mt("PRERELEASEIDENTIFIER",`(?:${Je[We.NUMERICIDENTIFIER]}|${Je[We.NONNUMERICIDENTIFIER]})`);mt("PRERELEASEIDENTIFIERLOOSE",`(?:${Je[We.NUMERICIDENTIFIERLOOSE]}|${Je[We.NONNUMERICIDENTIFIER]})`);mt("PRERELEASE",`(?:-(${Je[We.PRERELEASEIDENTIFIER]}(?:\\.${Je[We.PRERELEASEIDENTIFIER]})*))`);mt("PRERELEASELOOSE",`(?:-?(${Je[We.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${Je[We.PRERELEASEIDENTIFIERLOOSE]})*))`);mt("BUILDIDENTIFIER","[0-9A-Za-z-]+");mt("BUILD",`(?:\\+(${Je[We.BUILDIDENTIFIER]}(?:\\.${Je[We.BUILDIDENTIFIER]})*))`);mt("FULLPLAIN",`v?${Je[We.MAINVERSION]}${Je[We.PRERELEASE]}?${Je[We.BUILD]}?`);mt("FULL",`^${Je[We.FULLPLAIN]}$`);mt("LOOSEPLAIN",`[v=\\s]*${Je[We.MAINVERSIONLOOSE]}${Je[We.PRERELEASELOOSE]}?${Je[We.BUILD]}?`);mt("LOOSE",`^${Je[We.LOOSEPLAIN]}$`);mt("GTLT","((?:<|>)?=?)");mt("XRANGEIDENTIFIERLOOSE",`${Je[We.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);mt("XRANGEIDENTIFIER",`${Je[We.NUMERICIDENTIFIER]}|x|X|\\*`);mt("XRANGEPLAIN",`[v=\\s]*(${Je[We.XRANGEIDENTIFIER]})(?:\\.(${Je[We.XRANGEIDENTIFIER]})(?:\\.(${Je[We.XRANGEIDENTIFIER]})(?:${Je[We.PRERELEASE]})?${Je[We.BUILD]}?)?)?`);mt("XRANGEPLAINLOOSE",`[v=\\s]*(${Je[We.XRANGEIDENTIFIERLOOSE]})(?:\\.(${Je[We.XRANGEIDENTIFIERLOOSE]})(?:\\.(${Je[We.XRANGEIDENTIFIERLOOSE]})(?:${Je[We.PRERELEASELOOSE]})?${Je[We.BUILD]}?)?)?`);mt("XRANGE",`^${Je[We.GTLT]}\\s*${Je[We.XRANGEPLAIN]}$`);mt("XRANGELOOSE",`^${Je[We.GTLT]}\\s*${Je[We.XRANGEPLAINLOOSE]}$`);mt("COERCE",`(^|[^\\d])(\\d{1,${yv}})(?:\\.(\\d{1,${yv}}))?(?:\\.(\\d{1,${yv}}))?(?:$|[^\\d])`);mt("COERCERTL",Je[We.COERCE],!0);mt("LONETILDE","(?:~>?)");mt("TILDETRIM",`(\\s*)${Je[We.LONETILDE]}\\s+`,!0);iA.tildeTrimReplace="$1~";mt("TILDE",`^${Je[We.LONETILDE]}${Je[We.XRANGEPLAIN]}$`);mt("TILDELOOSE",`^${Je[We.LONETILDE]}${Je[We.XRANGEPLAINLOOSE]}$`);mt("LONECARET","(?:\\^)");mt("CARETTRIM",`(\\s*)${Je[We.LONECARET]}\\s+`,!0);iA.caretTrimReplace="$1^";mt("CARET",`^${Je[We.LONECARET]}${Je[We.XRANGEPLAIN]}$`);mt("CARETLOOSE",`^${Je[We.LONECARET]}${Je[We.XRANGEPLAINLOOSE]}$`);mt("COMPARATORLOOSE",`^${Je[We.GTLT]}\\s*(${Je[We.LOOSEPLAIN]})$|^$`);mt("COMPARATOR",`^${Je[We.GTLT]}\\s*(${Je[We.FULLPLAIN]})$|^$`);mt("COMPARATORTRIM",`(\\s*)${Je[We.GTLT]}\\s*(${Je[We.LOOSEPLAIN]}|${Je[We.XRANGEPLAIN]})`,!0);iA.comparatorTrimReplace="$1$2$3";mt("HYPHENRANGE",`^\\s*(${Je[We.XRANGEPLAIN]})\\s+-\\s+(${Je[We.XRANGEPLAIN]})\\s*$`);mt("HYPHENRANGELOOSE",`^\\s*(${Je[We.XRANGEPLAINLOOSE]})\\s+-\\s+(${Je[We.XRANGEPLAINLOOSE]})\\s*$`);mt("STAR","(<|>)?=?\\s*\\*");mt("GTE0","^\\s*>=\\s*0.0.0\\s*$");mt("GTE0PRE","^\\s*>=\\s*0.0.0-0\\s*$")});var kh=E((ttt,HU)=>{var vCe=["includePrerelease","loose","rtl"],SCe=t=>t?typeof t!="object"?{loose:!0}:vCe.filter(e=>t[e]).reduce((e,r)=>(e[r]=!0,e),{}):{};HU.exports=SCe});var zE=E((rtt,GU)=>{var jU=/^[0-9]+$/,YU=(t,e)=>{let r=jU.test(t),i=jU.test(e);return r&&i&&(t=+t,e=+e),t===e?0:r&&!i?-1:i&&!r?1:tYU(e,t);GU.exports={compareIdentifiers:YU,rcompareIdentifiers:xCe}});var bi=E((itt,qU)=>{var VE=xh(),{MAX_LENGTH:JU,MAX_SAFE_INTEGER:_E}=Sh(),{re:WU,t:zU}=Ql(),kCe=kh(),{compareIdentifiers:Ph}=zE(),_n=class{constructor(e,r){if(r=kCe(r),e instanceof _n){if(e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease)return e;e=e.version}else if(typeof e!="string")throw new TypeError(`Invalid Version: ${e}`);if(e.length>JU)throw new TypeError(`version is longer than ${JU} characters`);VE("SemVer",e,r),this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease;let i=e.trim().match(r.loose?WU[zU.LOOSE]:WU[zU.FULL]);if(!i)throw new TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+i[1],this.minor=+i[2],this.patch=+i[3],this.major>_E||this.major<0)throw new TypeError("Invalid major version");if(this.minor>_E||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>_E||this.patch<0)throw new TypeError("Invalid patch version");i[4]?this.prerelease=i[4].split(".").map(n=>{if(/^[0-9]+$/.test(n)){let s=+n;if(s>=0&&s<_E)return s}return n}):this.prerelease=[],this.build=i[5]?i[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(e){if(VE("SemVer.compare",this.version,this.options,e),!(e instanceof _n)){if(typeof e=="string"&&e===this.version)return 0;e=new _n(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof _n||(e=new _n(e,this.options)),Ph(this.major,e.major)||Ph(this.minor,e.minor)||Ph(this.patch,e.patch)}comparePre(e){if(e instanceof _n||(e=new _n(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;let r=0;do{let i=this.prerelease[r],n=e.prerelease[r];if(VE("prerelease compare",r,i,n),i===void 0&&n===void 0)return 0;if(n===void 0)return 1;if(i===void 0)return-1;if(i===n)continue;return Ph(i,n)}while(++r)}compareBuild(e){e instanceof _n||(e=new _n(e,this.options));let r=0;do{let i=this.build[r],n=e.build[r];if(VE("prerelease compare",r,i,n),i===void 0&&n===void 0)return 0;if(n===void 0)return 1;if(i===void 0)return-1;if(i===n)continue;return Ph(i,n)}while(++r)}inc(e,r){switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",r);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",r);break;case"prepatch":this.prerelease.length=0,this.inc("patch",r),this.inc("pre",r);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",r),this.inc("pre",r);break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{let i=this.prerelease.length;for(;--i>=0;)typeof this.prerelease[i]=="number"&&(this.prerelease[i]++,i=-2);i===-1&&this.prerelease.push(0)}r&&(this.prerelease[0]===r?isNaN(this.prerelease[1])&&(this.prerelease=[r,0]):this.prerelease=[r,0]);break;default:throw new Error(`invalid increment argument: ${e}`)}return this.format(),this.raw=this.version,this}};qU.exports=_n});var bl=E((ntt,VU)=>{var{MAX_LENGTH:PCe}=Sh(),{re:_U,t:XU}=Ql(),ZU=bi(),DCe=kh(),RCe=(t,e)=>{if(e=DCe(e),t instanceof ZU)return t;if(typeof t!="string"||t.length>PCe||!(e.loose?_U[XU.LOOSE]:_U[XU.FULL]).test(t))return null;try{return new ZU(t,e)}catch(i){return null}};VU.exports=RCe});var e2=E((stt,$U)=>{var FCe=bl(),NCe=(t,e)=>{let r=FCe(t,e);return r?r.version:null};$U.exports=NCe});var r2=E((ott,t2)=>{var LCe=bl(),TCe=(t,e)=>{let r=LCe(t.trim().replace(/^[=v]+/,""),e);return r?r.version:null};t2.exports=TCe});var n2=E((att,i2)=>{var MCe=bi(),OCe=(t,e,r,i)=>{typeof r=="string"&&(i=r,r=void 0);try{return new MCe(t,r).inc(e,i).version}catch(n){return null}};i2.exports=OCe});var Xn=E((Att,s2)=>{var o2=bi(),KCe=(t,e,r)=>new o2(t,r).compare(new o2(e,r));s2.exports=KCe});var XE=E((ltt,a2)=>{var UCe=Xn(),HCe=(t,e,r)=>UCe(t,e,r)===0;a2.exports=HCe});var c2=E((ctt,A2)=>{var l2=bl(),GCe=XE(),jCe=(t,e)=>{if(GCe(t,e))return null;{let r=l2(t),i=l2(e),n=r.prerelease.length||i.prerelease.length,s=n?"pre":"",o=n?"prerelease":"";for(let a in r)if((a==="major"||a==="minor"||a==="patch")&&r[a]!==i[a])return s+a;return o}};A2.exports=jCe});var g2=E((utt,u2)=>{var YCe=bi(),qCe=(t,e)=>new YCe(t,e).major;u2.exports=qCe});var h2=E((gtt,f2)=>{var JCe=bi(),WCe=(t,e)=>new JCe(t,e).minor;f2.exports=WCe});var d2=E((ftt,p2)=>{var zCe=bi(),VCe=(t,e)=>new zCe(t,e).patch;p2.exports=VCe});var m2=E((htt,C2)=>{var _Ce=bl(),XCe=(t,e)=>{let r=_Ce(t,e);return r&&r.prerelease.length?r.prerelease:null};C2.exports=XCe});var I2=E((ptt,E2)=>{var ZCe=Xn(),$Ce=(t,e,r)=>ZCe(e,t,r);E2.exports=$Ce});var w2=E((dtt,y2)=>{var eme=Xn(),tme=(t,e)=>eme(t,e,!0);y2.exports=tme});var ZE=E((Ctt,B2)=>{var Q2=bi(),rme=(t,e,r)=>{let i=new Q2(t,r),n=new Q2(e,r);return i.compare(n)||i.compareBuild(n)};B2.exports=rme});var v2=E((mtt,b2)=>{var ime=ZE(),nme=(t,e)=>t.sort((r,i)=>ime(r,i,e));b2.exports=nme});var x2=E((Ett,S2)=>{var sme=ZE(),ome=(t,e)=>t.sort((r,i)=>sme(i,r,e));S2.exports=ome});var Dh=E((Itt,k2)=>{var ame=Xn(),Ame=(t,e,r)=>ame(t,e,r)>0;k2.exports=Ame});var $E=E((ytt,P2)=>{var lme=Xn(),cme=(t,e,r)=>lme(t,e,r)<0;P2.exports=cme});var wv=E((wtt,D2)=>{var ume=Xn(),gme=(t,e,r)=>ume(t,e,r)!==0;D2.exports=gme});var eI=E((Btt,R2)=>{var fme=Xn(),hme=(t,e,r)=>fme(t,e,r)>=0;R2.exports=hme});var tI=E((Qtt,F2)=>{var pme=Xn(),dme=(t,e,r)=>pme(t,e,r)<=0;F2.exports=dme});var Bv=E((btt,N2)=>{var Cme=XE(),mme=wv(),Eme=Dh(),Ime=eI(),yme=$E(),wme=tI(),Bme=(t,e,r,i)=>{switch(e){case"===":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t===r;case"!==":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t!==r;case"":case"=":case"==":return Cme(t,r,i);case"!=":return mme(t,r,i);case">":return Eme(t,r,i);case">=":return Ime(t,r,i);case"<":return yme(t,r,i);case"<=":return wme(t,r,i);default:throw new TypeError(`Invalid operator: ${e}`)}};N2.exports=Bme});var T2=E((vtt,L2)=>{var Qme=bi(),bme=bl(),{re:rI,t:iI}=Ql(),vme=(t,e)=>{if(t instanceof Qme)return t;if(typeof t=="number"&&(t=String(t)),typeof t!="string")return null;e=e||{};let r=null;if(!e.rtl)r=t.match(rI[iI.COERCE]);else{let i;for(;(i=rI[iI.COERCERTL].exec(t))&&(!r||r.index+r[0].length!==t.length);)(!r||i.index+i[0].length!==r.index+r[0].length)&&(r=i),rI[iI.COERCERTL].lastIndex=i.index+i[1].length+i[2].length;rI[iI.COERCERTL].lastIndex=-1}return r===null?null:bme(`${r[2]}.${r[3]||"0"}.${r[4]||"0"}`,e)};L2.exports=vme});var O2=E((Stt,M2)=>{"use strict";M2.exports=function(t){t.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}});var Rh=E((xtt,K2)=>{"use strict";K2.exports=Pt;Pt.Node=vl;Pt.create=Pt;function Pt(t){var e=this;if(e instanceof Pt||(e=new Pt),e.tail=null,e.head=null,e.length=0,t&&typeof t.forEach=="function")t.forEach(function(n){e.push(n)});else if(arguments.length>0)for(var r=0,i=arguments.length;r1)r=e;else if(this.head)i=this.head.next,r=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var n=0;i!==null;n++)r=t(r,i.value,n),i=i.next;return r};Pt.prototype.reduceReverse=function(t,e){var r,i=this.tail;if(arguments.length>1)r=e;else if(this.tail)i=this.tail.prev,r=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var n=this.length-1;i!==null;n--)r=t(r,i.value,n),i=i.prev;return r};Pt.prototype.toArray=function(){for(var t=new Array(this.length),e=0,r=this.head;r!==null;e++)t[e]=r.value,r=r.next;return t};Pt.prototype.toArrayReverse=function(){for(var t=new Array(this.length),e=0,r=this.tail;r!==null;e++)t[e]=r.value,r=r.prev;return t};Pt.prototype.slice=function(t,e){e=e||this.length,e<0&&(e+=this.length),t=t||0,t<0&&(t+=this.length);var r=new Pt;if(ethis.length&&(e=this.length);for(var i=0,n=this.head;n!==null&&ithis.length&&(e=this.length);for(var i=this.length,n=this.tail;n!==null&&i>e;i--)n=n.prev;for(;n!==null&&i>t;i--,n=n.prev)r.push(n.value);return r};Pt.prototype.splice=function(t,e,...r){t>this.length&&(t=this.length-1),t<0&&(t=this.length+t);for(var i=0,n=this.head;n!==null&&i{"use strict";var Pme=Rh(),Sl=Symbol("max"),ra=Symbol("length"),uu=Symbol("lengthCalculator"),Fh=Symbol("allowStale"),xl=Symbol("maxAge"),ia=Symbol("dispose"),H2=Symbol("noDisposeOnSet"),si=Symbol("lruList"),ks=Symbol("cache"),G2=Symbol("updateAgeOnGet"),Qv=()=>1,j2=class{constructor(e){if(typeof e=="number"&&(e={max:e}),e||(e={}),e.max&&(typeof e.max!="number"||e.max<0))throw new TypeError("max must be a non-negative number");let r=this[Sl]=e.max||Infinity,i=e.length||Qv;if(this[uu]=typeof i!="function"?Qv:i,this[Fh]=e.stale||!1,e.maxAge&&typeof e.maxAge!="number")throw new TypeError("maxAge must be a number");this[xl]=e.maxAge||0,this[ia]=e.dispose,this[H2]=e.noDisposeOnSet||!1,this[G2]=e.updateAgeOnGet||!1,this.reset()}set max(e){if(typeof e!="number"||e<0)throw new TypeError("max must be a non-negative number");this[Sl]=e||Infinity,Nh(this)}get max(){return this[Sl]}set allowStale(e){this[Fh]=!!e}get allowStale(){return this[Fh]}set maxAge(e){if(typeof e!="number")throw new TypeError("maxAge must be a non-negative number");this[xl]=e,Nh(this)}get maxAge(){return this[xl]}set lengthCalculator(e){typeof e!="function"&&(e=Qv),e!==this[uu]&&(this[uu]=e,this[ra]=0,this[si].forEach(r=>{r.length=this[uu](r.value,r.key),this[ra]+=r.length})),Nh(this)}get lengthCalculator(){return this[uu]}get length(){return this[ra]}get itemCount(){return this[si].length}rforEach(e,r){r=r||this;for(let i=this[si].tail;i!==null;){let n=i.prev;q2(this,e,i,r),i=n}}forEach(e,r){r=r||this;for(let i=this[si].head;i!==null;){let n=i.next;q2(this,e,i,r),i=n}}keys(){return this[si].toArray().map(e=>e.key)}values(){return this[si].toArray().map(e=>e.value)}reset(){this[ia]&&this[si]&&this[si].length&&this[si].forEach(e=>this[ia](e.key,e.value)),this[ks]=new Map,this[si]=new Pme,this[ra]=0}dump(){return this[si].map(e=>nI(this,e)?!1:{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter(e=>e)}dumpLru(){return this[si]}set(e,r,i){if(i=i||this[xl],i&&typeof i!="number")throw new TypeError("maxAge must be a number");let n=i?Date.now():0,s=this[uu](r,e);if(this[ks].has(e)){if(s>this[Sl])return gu(this,this[ks].get(e)),!1;let l=this[ks].get(e).value;return this[ia]&&(this[H2]||this[ia](e,l.value)),l.now=n,l.maxAge=i,l.value=r,this[ra]+=s-l.length,l.length=s,this.get(e),Nh(this),!0}let o=new Y2(e,r,s,n,i);return o.length>this[Sl]?(this[ia]&&this[ia](e,r),!1):(this[ra]+=o.length,this[si].unshift(o),this[ks].set(e,this[si].head),Nh(this),!0)}has(e){if(!this[ks].has(e))return!1;let r=this[ks].get(e).value;return!nI(this,r)}get(e){return bv(this,e,!0)}peek(e){return bv(this,e,!1)}pop(){let e=this[si].tail;return e?(gu(this,e),e.value):null}del(e){gu(this,this[ks].get(e))}load(e){this.reset();let r=Date.now();for(let i=e.length-1;i>=0;i--){let n=e[i],s=n.e||0;if(s===0)this.set(n.k,n.v);else{let o=s-r;o>0&&this.set(n.k,n.v,o)}}}prune(){this[ks].forEach((e,r)=>bv(this,r,!1))}},bv=(t,e,r)=>{let i=t[ks].get(e);if(i){let n=i.value;if(nI(t,n)){if(gu(t,i),!t[Fh])return}else r&&(t[G2]&&(i.value.now=Date.now()),t[si].unshiftNode(i));return n.value}},nI=(t,e)=>{if(!e||!e.maxAge&&!t[xl])return!1;let r=Date.now()-e.now;return e.maxAge?r>e.maxAge:t[xl]&&r>t[xl]},Nh=t=>{if(t[ra]>t[Sl])for(let e=t[si].tail;t[ra]>t[Sl]&&e!==null;){let r=e.prev;gu(t,e),e=r}},gu=(t,e)=>{if(e){let r=e.value;t[ia]&&t[ia](r.key,r.value),t[ra]-=r.length,t[ks].delete(r.key),t[si].removeNode(e)}},Y2=class{constructor(e,r,i,n,s){this.key=e,this.value=r,this.length=i,this.now=n,this.maxAge=s||0}},q2=(t,e,r,i)=>{let n=r.value;nI(t,n)&&(gu(t,r),t[Fh]||(n=void 0)),n&&e.call(i,n.value,n.key,t)};U2.exports=j2});var Zn=E((Ptt,W2)=>{var fu=class{constructor(e,r){if(r=Dme(r),e instanceof fu)return e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease?e:new fu(e.raw,r);if(e instanceof vv)return this.raw=e.value,this.set=[[e]],this.format(),this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=e,this.set=e.split(/\s*\|\|\s*/).map(i=>this.parseRange(i.trim())).filter(i=>i.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${e}`);if(this.set.length>1){let i=this.set[0];if(this.set=this.set.filter(n=>!V2(n[0])),this.set.length===0)this.set=[i];else if(this.set.length>1){for(let n of this.set)if(n.length===1&&Tme(n[0])){this.set=[n];break}}}this.format()}format(){return this.range=this.set.map(e=>e.join(" ").trim()).join("||").trim(),this.range}toString(){return this.range}parseRange(e){e=e.trim();let i=`parseRange:${Object.keys(this.options).join(",")}:${e}`,n=z2.get(i);if(n)return n;let s=this.options.loose,o=s?vi[di.HYPHENRANGELOOSE]:vi[di.HYPHENRANGE];e=e.replace(o,Kme(this.options.includePrerelease)),Rr("hyphen replace",e),e=e.replace(vi[di.COMPARATORTRIM],Fme),Rr("comparator trim",e,vi[di.COMPARATORTRIM]),e=e.replace(vi[di.TILDETRIM],Nme),e=e.replace(vi[di.CARETTRIM],Lme),e=e.split(/\s+/).join(" ");let a=s?vi[di.COMPARATORLOOSE]:vi[di.COMPARATOR],l=e.split(" ").map(f=>Mme(f,this.options)).join(" ").split(/\s+/).map(f=>Ome(f,this.options)).filter(this.options.loose?f=>!!f.match(a):()=>!0).map(f=>new vv(f,this.options)),c=l.length,u=new Map;for(let f of l){if(V2(f))return[f];u.set(f.value,f)}u.size>1&&u.has("")&&u.delete("");let g=[...u.values()];return z2.set(i,g),g}intersects(e,r){if(!(e instanceof fu))throw new TypeError("a Range is required");return this.set.some(i=>_2(i,r)&&e.set.some(n=>_2(n,r)&&i.every(s=>n.every(o=>s.intersects(o,r)))))}test(e){if(!e)return!1;if(typeof e=="string")try{e=new Rme(e,this.options)}catch(r){return!1}for(let r=0;rt.value==="<0.0.0-0",Tme=t=>t.value==="",_2=(t,e)=>{let r=!0,i=t.slice(),n=i.pop();for(;r&&i.length;)r=i.every(s=>n.intersects(s,e)),n=i.pop();return r},Mme=(t,e)=>(Rr("comp",t,e),t=jme(t,e),Rr("caret",t),t=Gme(t,e),Rr("tildes",t),t=Yme(t,e),Rr("xrange",t),t=qme(t,e),Rr("stars",t),t),Ji=t=>!t||t.toLowerCase()==="x"||t==="*",Gme=(t,e)=>t.trim().split(/\s+/).map(r=>Jme(r,e)).join(" "),Jme=(t,e)=>{let r=e.loose?vi[di.TILDELOOSE]:vi[di.TILDE];return t.replace(r,(i,n,s,o,a)=>{Rr("tilde",t,i,n,s,o,a);let l;return Ji(n)?l="":Ji(s)?l=`>=${n}.0.0 <${+n+1}.0.0-0`:Ji(o)?l=`>=${n}.${s}.0 <${n}.${+s+1}.0-0`:a?(Rr("replaceTilde pr",a),l=`>=${n}.${s}.${o}-${a} <${n}.${+s+1}.0-0`):l=`>=${n}.${s}.${o} <${n}.${+s+1}.0-0`,Rr("tilde return",l),l})},jme=(t,e)=>t.trim().split(/\s+/).map(r=>Wme(r,e)).join(" "),Wme=(t,e)=>{Rr("caret",t,e);let r=e.loose?vi[di.CARETLOOSE]:vi[di.CARET],i=e.includePrerelease?"-0":"";return t.replace(r,(n,s,o,a,l)=>{Rr("caret",t,n,s,o,a,l);let c;return Ji(s)?c="":Ji(o)?c=`>=${s}.0.0${i} <${+s+1}.0.0-0`:Ji(a)?s==="0"?c=`>=${s}.${o}.0${i} <${s}.${+o+1}.0-0`:c=`>=${s}.${o}.0${i} <${+s+1}.0.0-0`:l?(Rr("replaceCaret pr",l),s==="0"?o==="0"?c=`>=${s}.${o}.${a}-${l} <${s}.${o}.${+a+1}-0`:c=`>=${s}.${o}.${a}-${l} <${s}.${+o+1}.0-0`:c=`>=${s}.${o}.${a}-${l} <${+s+1}.0.0-0`):(Rr("no pr"),s==="0"?o==="0"?c=`>=${s}.${o}.${a}${i} <${s}.${o}.${+a+1}-0`:c=`>=${s}.${o}.${a}${i} <${s}.${+o+1}.0-0`:c=`>=${s}.${o}.${a} <${+s+1}.0.0-0`),Rr("caret return",c),c})},Yme=(t,e)=>(Rr("replaceXRanges",t,e),t.split(/\s+/).map(r=>zme(r,e)).join(" ")),zme=(t,e)=>{t=t.trim();let r=e.loose?vi[di.XRANGELOOSE]:vi[di.XRANGE];return t.replace(r,(i,n,s,o,a,l)=>{Rr("xRange",t,i,n,s,o,a,l);let c=Ji(s),u=c||Ji(o),g=u||Ji(a),f=g;return n==="="&&f&&(n=""),l=e.includePrerelease?"-0":"",c?n===">"||n==="<"?i="<0.0.0-0":i="*":n&&f?(u&&(o=0),a=0,n===">"?(n=">=",u?(s=+s+1,o=0,a=0):(o=+o+1,a=0)):n==="<="&&(n="<",u?s=+s+1:o=+o+1),n==="<"&&(l="-0"),i=`${n+s}.${o}.${a}${l}`):u?i=`>=${s}.0.0${l} <${+s+1}.0.0-0`:g&&(i=`>=${s}.${o}.0${l} <${s}.${+o+1}.0-0`),Rr("xRange return",i),i})},qme=(t,e)=>(Rr("replaceStars",t,e),t.trim().replace(vi[di.STAR],"")),Ome=(t,e)=>(Rr("replaceGTE0",t,e),t.trim().replace(vi[e.includePrerelease?di.GTE0PRE:di.GTE0],"")),Kme=t=>(e,r,i,n,s,o,a,l,c,u,g,f,h)=>(Ji(i)?r="":Ji(n)?r=`>=${i}.0.0${t?"-0":""}`:Ji(s)?r=`>=${i}.${n}.0${t?"-0":""}`:o?r=`>=${r}`:r=`>=${r}${t?"-0":""}`,Ji(c)?l="":Ji(u)?l=`<${+c+1}.0.0-0`:Ji(g)?l=`<${c}.${+u+1}.0-0`:f?l=`<=${c}.${u}.${g}-${f}`:t?l=`<${c}.${u}.${+g+1}-0`:l=`<=${l}`,`${r} ${l}`.trim()),Ume=(t,e,r)=>{for(let i=0;i0){let n=t[i].semver;if(n.major===e.major&&n.minor===e.minor&&n.patch===e.patch)return!0}return!1}return!0}});var Lh=E((Dtt,X2)=>{var Th=Symbol("SemVer ANY"),Mh=class{static get ANY(){return Th}constructor(e,r){if(r=Vme(r),e instanceof Mh){if(e.loose===!!r.loose)return e;e=e.value}xv("comparator",e,r),this.options=r,this.loose=!!r.loose,this.parse(e),this.semver===Th?this.value="":this.value=this.operator+this.semver.version,xv("comp",this)}parse(e){let r=this.options.loose?Z2[$2.COMPARATORLOOSE]:Z2[$2.COMPARATOR],i=e.match(r);if(!i)throw new TypeError(`Invalid comparator: ${e}`);this.operator=i[1]!==void 0?i[1]:"",this.operator==="="&&(this.operator=""),i[2]?this.semver=new eH(i[2],this.options.loose):this.semver=Th}toString(){return this.value}test(e){if(xv("Comparator.test",e,this.options.loose),this.semver===Th||e===Th)return!0;if(typeof e=="string")try{e=new eH(e,this.options)}catch(r){return!1}return Sv(e,this.operator,this.semver,this.options)}intersects(e,r){if(!(e instanceof Mh))throw new TypeError("a Comparator is required");if((!r||typeof r!="object")&&(r={loose:!!r,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new tH(e.value,r).test(this.value);if(e.operator==="")return e.value===""?!0:new tH(this.value,r).test(e.semver);let i=(this.operator===">="||this.operator===">")&&(e.operator===">="||e.operator===">"),n=(this.operator==="<="||this.operator==="<")&&(e.operator==="<="||e.operator==="<"),s=this.semver.version===e.semver.version,o=(this.operator===">="||this.operator==="<=")&&(e.operator===">="||e.operator==="<="),a=Sv(this.semver,"<",e.semver,r)&&(this.operator===">="||this.operator===">")&&(e.operator==="<="||e.operator==="<"),l=Sv(this.semver,">",e.semver,r)&&(this.operator==="<="||this.operator==="<")&&(e.operator===">="||e.operator===">");return i||n||s&&o||a||l}};X2.exports=Mh;var Vme=kh(),{re:Z2,t:$2}=Ql(),Sv=Bv(),xv=xh(),eH=bi(),tH=Zn()});var Oh=E((Rtt,rH)=>{var _me=Zn(),Xme=(t,e,r)=>{try{e=new _me(e,r)}catch(i){return!1}return e.test(t)};rH.exports=Xme});var nH=E((Ftt,iH)=>{var Zme=Zn(),$me=(t,e)=>new Zme(t,e).set.map(r=>r.map(i=>i.value).join(" ").trim().split(" "));iH.exports=$me});var oH=E((Ntt,sH)=>{var eEe=bi(),tEe=Zn(),rEe=(t,e,r)=>{let i=null,n=null,s=null;try{s=new tEe(e,r)}catch(o){return null}return t.forEach(o=>{s.test(o)&&(!i||n.compare(o)===-1)&&(i=o,n=new eEe(i,r))}),i};sH.exports=rEe});var AH=E((Ltt,aH)=>{var iEe=bi(),nEe=Zn(),sEe=(t,e,r)=>{let i=null,n=null,s=null;try{s=new nEe(e,r)}catch(o){return null}return t.forEach(o=>{s.test(o)&&(!i||n.compare(o)===1)&&(i=o,n=new iEe(i,r))}),i};aH.exports=sEe});var uH=E((Ttt,lH)=>{var kv=bi(),oEe=Zn(),cH=Dh(),aEe=(t,e)=>{t=new oEe(t,e);let r=new kv("0.0.0");if(t.test(r)||(r=new kv("0.0.0-0"),t.test(r)))return r;r=null;for(let i=0;i{let a=new kv(o.semver.version);switch(o.operator){case">":a.prerelease.length===0?a.patch++:a.prerelease.push(0),a.raw=a.format();case"":case">=":(!s||cH(a,s))&&(s=a);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${o.operator}`)}}),s&&(!r||cH(r,s))&&(r=s)}return r&&t.test(r)?r:null};lH.exports=aEe});var fH=E((Mtt,gH)=>{var AEe=Zn(),lEe=(t,e)=>{try{return new AEe(t,e).range||"*"}catch(r){return null}};gH.exports=lEe});var sI=E((Ott,hH)=>{var cEe=bi(),pH=Lh(),{ANY:uEe}=pH,gEe=Zn(),fEe=Oh(),dH=Dh(),CH=$E(),hEe=tI(),pEe=eI(),dEe=(t,e,r,i)=>{t=new cEe(t,i),e=new gEe(e,i);let n,s,o,a,l;switch(r){case">":n=dH,s=hEe,o=CH,a=">",l=">=";break;case"<":n=CH,s=pEe,o=dH,a="<",l="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(fEe(t,e,i))return!1;for(let c=0;c{h.semver===uEe&&(h=new pH(">=0.0.0")),g=g||h,f=f||h,n(h.semver,g.semver,i)?g=h:o(h.semver,f.semver,i)&&(f=h)}),g.operator===a||g.operator===l||(!f.operator||f.operator===a)&&s(t,f.semver))return!1;if(f.operator===l&&o(t,f.semver))return!1}return!0};hH.exports=dEe});var EH=E((Ktt,mH)=>{var CEe=sI(),mEe=(t,e,r)=>CEe(t,e,">",r);mH.exports=mEe});var yH=E((Utt,IH)=>{var EEe=sI(),IEe=(t,e,r)=>EEe(t,e,"<",r);IH.exports=IEe});var QH=E((Htt,wH)=>{var BH=Zn(),yEe=(t,e,r)=>(t=new BH(t,r),e=new BH(e,r),t.intersects(e));wH.exports=yEe});var vH=E((Gtt,bH)=>{var wEe=Oh(),BEe=Xn();bH.exports=(t,e,r)=>{let i=[],n=null,s=null,o=t.sort((u,g)=>BEe(u,g,r));for(let u of o)wEe(u,e,r)?(s=u,n||(n=u)):(s&&i.push([n,s]),s=null,n=null);n&&i.push([n,null]);let a=[];for(let[u,g]of i)u===g?a.push(u):!g&&u===o[0]?a.push("*"):g?u===o[0]?a.push(`<=${g}`):a.push(`${u} - ${g}`):a.push(`>=${u}`);let l=a.join(" || "),c=typeof e.raw=="string"?e.raw:String(e);return l.length{var xH=Zn(),oI=Lh(),{ANY:Pv}=oI,Kh=Oh(),Dv=Xn(),bEe=(t,e,r={})=>{if(t===e)return!0;t=new xH(t,r),e=new xH(e,r);let i=!1;e:for(let n of t.set){for(let s of e.set){let o=QEe(n,s,r);if(i=i||o!==null,o)continue e}if(i)return!1}return!0},QEe=(t,e,r)=>{if(t===e)return!0;if(t.length===1&&t[0].semver===Pv){if(e.length===1&&e[0].semver===Pv)return!0;r.includePrerelease?t=[new oI(">=0.0.0-0")]:t=[new oI(">=0.0.0")]}if(e.length===1&&e[0].semver===Pv){if(r.includePrerelease)return!0;e=[new oI(">=0.0.0")]}let i=new Set,n,s;for(let h of t)h.operator===">"||h.operator===">="?n=kH(n,h,r):h.operator==="<"||h.operator==="<="?s=PH(s,h,r):i.add(h.semver);if(i.size>1)return null;let o;if(n&&s){if(o=Dv(n.semver,s.semver,r),o>0)return null;if(o===0&&(n.operator!==">="||s.operator!=="<="))return null}for(let h of i){if(n&&!Kh(h,String(n),r)||s&&!Kh(h,String(s),r))return null;for(let p of e)if(!Kh(h,String(p),r))return!1;return!0}let a,l,c,u,g=s&&!r.includePrerelease&&s.semver.prerelease.length?s.semver:!1,f=n&&!r.includePrerelease&&n.semver.prerelease.length?n.semver:!1;g&&g.prerelease.length===1&&s.operator==="<"&&g.prerelease[0]===0&&(g=!1);for(let h of e){if(u=u||h.operator===">"||h.operator===">=",c=c||h.operator==="<"||h.operator==="<=",n){if(f&&h.semver.prerelease&&h.semver.prerelease.length&&h.semver.major===f.major&&h.semver.minor===f.minor&&h.semver.patch===f.patch&&(f=!1),h.operator===">"||h.operator===">="){if(a=kH(n,h,r),a===h&&a!==n)return!1}else if(n.operator===">="&&!Kh(n.semver,String(h),r))return!1}if(s){if(g&&h.semver.prerelease&&h.semver.prerelease.length&&h.semver.major===g.major&&h.semver.minor===g.minor&&h.semver.patch===g.patch&&(g=!1),h.operator==="<"||h.operator==="<="){if(l=PH(s,h,r),l===h&&l!==s)return!1}else if(s.operator==="<="&&!Kh(s.semver,String(h),r))return!1}if(!h.operator&&(s||n)&&o!==0)return!1}return!(n&&c&&!s&&o!==0||s&&u&&!n&&o!==0||f||g)},kH=(t,e,r)=>{if(!t)return e;let i=Dv(t.semver,e.semver,r);return i>0?t:i<0||e.operator===">"&&t.operator===">="?e:t},PH=(t,e,r)=>{if(!t)return e;let i=Dv(t.semver,e.semver,r);return i<0?t:i>0||e.operator==="<"&&t.operator==="<="?e:t};SH.exports=bEe});var Or=E((Ytt,RH)=>{var Rv=Ql();RH.exports={re:Rv.re,src:Rv.src,tokens:Rv.t,SEMVER_SPEC_VERSION:Sh().SEMVER_SPEC_VERSION,SemVer:bi(),compareIdentifiers:zE().compareIdentifiers,rcompareIdentifiers:zE().rcompareIdentifiers,parse:bl(),valid:e2(),clean:r2(),inc:n2(),diff:c2(),major:g2(),minor:h2(),patch:d2(),prerelease:m2(),compare:Xn(),rcompare:I2(),compareLoose:w2(),compareBuild:ZE(),sort:v2(),rsort:x2(),gt:Dh(),lt:$E(),eq:XE(),neq:wv(),gte:eI(),lte:tI(),cmp:Bv(),coerce:T2(),Comparator:Lh(),Range:Zn(),satisfies:Oh(),toComparators:nH(),maxSatisfying:oH(),minSatisfying:AH(),minVersion:uH(),validRange:fH(),outside:sI(),gtr:EH(),ltr:yH(),intersects:QH(),simplifyRange:vH(),subset:DH()}});var Uv=E(AI=>{"use strict";Object.defineProperty(AI,"__esModule",{value:!0});AI.VERSION=void 0;AI.VERSION="9.1.0"});var Dt=E((exports,module)=>{"use strict";var __spreadArray=exports&&exports.__spreadArray||function(t,e,r){if(r||arguments.length===2)for(var i=0,n=e.length,s;i{(function(t,e){typeof define=="function"&&define.amd?define([],e):typeof lI=="object"&&lI.exports?lI.exports=e():t.regexpToAst=e()})(typeof self!="undefined"?self:YH,function(){function t(){}t.prototype.saveState=function(){return{idx:this.idx,input:this.input,groupIdx:this.groupIdx}},t.prototype.restoreState=function(p){this.idx=p.idx,this.input=p.input,this.groupIdx=p.groupIdx},t.prototype.pattern=function(p){this.idx=0,this.input=p,this.groupIdx=0,this.consumeChar("/");var d=this.disjunction();this.consumeChar("/");for(var m={type:"Flags",loc:{begin:this.idx,end:p.length},global:!1,ignoreCase:!1,multiLine:!1,unicode:!1,sticky:!1};this.isRegExpFlag();)switch(this.popChar()){case"g":o(m,"global");break;case"i":o(m,"ignoreCase");break;case"m":o(m,"multiLine");break;case"u":o(m,"unicode");break;case"y":o(m,"sticky");break}if(this.idx!==this.input.length)throw Error("Redundant input: "+this.input.substring(this.idx));return{type:"Pattern",flags:m,value:d,loc:this.loc(0)}},t.prototype.disjunction=function(){var p=[],d=this.idx;for(p.push(this.alternative());this.peekChar()==="|";)this.consumeChar("|"),p.push(this.alternative());return{type:"Disjunction",value:p,loc:this.loc(d)}},t.prototype.alternative=function(){for(var p=[],d=this.idx;this.isTerm();)p.push(this.term());return{type:"Alternative",value:p,loc:this.loc(d)}},t.prototype.term=function(){return this.isAssertion()?this.assertion():this.atom()},t.prototype.assertion=function(){var p=this.idx;switch(this.popChar()){case"^":return{type:"StartAnchor",loc:this.loc(p)};case"$":return{type:"EndAnchor",loc:this.loc(p)};case"\\":switch(this.popChar()){case"b":return{type:"WordBoundary",loc:this.loc(p)};case"B":return{type:"NonWordBoundary",loc:this.loc(p)}}throw Error("Invalid Assertion Escape");case"(":this.consumeChar("?");var d;switch(this.popChar()){case"=":d="Lookahead";break;case"!":d="NegativeLookahead";break}a(d);var m=this.disjunction();return this.consumeChar(")"),{type:d,value:m,loc:this.loc(p)}}l()},t.prototype.quantifier=function(p){var d,m=this.idx;switch(this.popChar()){case"*":d={atLeast:0,atMost:Infinity};break;case"+":d={atLeast:1,atMost:Infinity};break;case"?":d={atLeast:0,atMost:1};break;case"{":var I=this.integerIncludingZero();switch(this.popChar()){case"}":d={atLeast:I,atMost:I};break;case",":var B;this.isDigit()?(B=this.integerIncludingZero(),d={atLeast:I,atMost:B}):d={atLeast:I,atMost:Infinity},this.consumeChar("}");break}if(p===!0&&d===void 0)return;a(d);break}if(!(p===!0&&d===void 0))return a(d),this.peekChar(0)==="?"?(this.consumeChar("?"),d.greedy=!1):d.greedy=!0,d.type="Quantifier",d.loc=this.loc(m),d},t.prototype.atom=function(){var p,d=this.idx;switch(this.peekChar()){case".":p=this.dotAll();break;case"\\":p=this.atomEscape();break;case"[":p=this.characterClass();break;case"(":p=this.group();break}return p===void 0&&this.isPatternCharacter()&&(p=this.patternCharacter()),a(p),p.loc=this.loc(d),this.isQuantifier()&&(p.quantifier=this.quantifier()),p},t.prototype.dotAll=function(){return this.consumeChar("."),{type:"Set",complement:!0,value:[n(` +`),n("\r"),n("\u2028"),n("\u2029")]}},t.prototype.atomEscape=function(){switch(this.consumeChar("\\"),this.peekChar()){case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":return this.decimalEscapeAtom();case"d":case"D":case"s":case"S":case"w":case"W":return this.characterClassEscape();case"f":case"n":case"r":case"t":case"v":return this.controlEscapeAtom();case"c":return this.controlLetterEscapeAtom();case"0":return this.nulCharacterAtom();case"x":return this.hexEscapeSequenceAtom();case"u":return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}},t.prototype.decimalEscapeAtom=function(){var p=this.positiveInteger();return{type:"GroupBackReference",value:p}},t.prototype.characterClassEscape=function(){var p,d=!1;switch(this.popChar()){case"d":p=u;break;case"D":p=u,d=!0;break;case"s":p=f;break;case"S":p=f,d=!0;break;case"w":p=g;break;case"W":p=g,d=!0;break}return a(p),{type:"Set",value:p,complement:d}},t.prototype.controlEscapeAtom=function(){var p;switch(this.popChar()){case"f":p=n("\f");break;case"n":p=n(` +`);break;case"r":p=n("\r");break;case"t":p=n(" ");break;case"v":p=n("\v");break}return a(p),{type:"Character",value:p}},t.prototype.controlLetterEscapeAtom=function(){this.consumeChar("c");var p=this.popChar();if(/[a-zA-Z]/.test(p)===!1)throw Error("Invalid ");var d=p.toUpperCase().charCodeAt(0)-64;return{type:"Character",value:d}},t.prototype.nulCharacterAtom=function(){return this.consumeChar("0"),{type:"Character",value:n("\0")}},t.prototype.hexEscapeSequenceAtom=function(){return this.consumeChar("x"),this.parseHexDigits(2)},t.prototype.regExpUnicodeEscapeSequenceAtom=function(){return this.consumeChar("u"),this.parseHexDigits(4)},t.prototype.identityEscapeAtom=function(){var p=this.popChar();return{type:"Character",value:n(p)}},t.prototype.classPatternCharacterAtom=function(){switch(this.peekChar()){case` +`:case"\r":case"\u2028":case"\u2029":case"\\":case"]":throw Error("TBD");default:var p=this.popChar();return{type:"Character",value:n(p)}}},t.prototype.characterClass=function(){var p=[],d=!1;for(this.consumeChar("["),this.peekChar(0)==="^"&&(this.consumeChar("^"),d=!0);this.isClassAtom();){var m=this.classAtom(),I=m.type==="Character";if(I&&this.isRangeDash()){this.consumeChar("-");var B=this.classAtom(),b=B.type==="Character";if(b){if(B.value=this.input.length)throw Error("Unexpected end of input");this.idx++},t.prototype.loc=function(p){return{begin:p,end:this.idx}};var e=/[0-9a-fA-F]/,r=/[0-9]/,i=/[1-9]/;function n(p){return p.charCodeAt(0)}function s(p,d){p.length!==void 0?p.forEach(function(m){d.push(m)}):d.push(p)}function o(p,d){if(p[d]===!0)throw"duplicate flag "+d;p[d]=!0}function a(p){if(p===void 0)throw Error("Internal Error - Should never get here!")}function l(){throw Error("Internal Error - Should never get here!")}var c,u=[];for(c=n("0");c<=n("9");c++)u.push(c);var g=[n("_")].concat(u);for(c=n("a");c<=n("z");c++)g.push(c);for(c=n("A");c<=n("Z");c++)g.push(c);var f=[n(" "),n("\f"),n(` +`),n("\r"),n(" "),n("\v"),n(" "),n("\xA0"),n("\u1680"),n("\u2000"),n("\u2001"),n("\u2002"),n("\u2003"),n("\u2004"),n("\u2005"),n("\u2006"),n("\u2007"),n("\u2008"),n("\u2009"),n("\u200A"),n("\u2028"),n("\u2029"),n("\u202F"),n("\u205F"),n("\u3000"),n("\uFEFF")];function h(){}return h.prototype.visitChildren=function(p){for(var d in p){var m=p[d];p.hasOwnProperty(d)&&(m.type!==void 0?this.visit(m):Array.isArray(m)&&m.forEach(function(I){this.visit(I)},this))}},h.prototype.visit=function(p){switch(p.type){case"Pattern":this.visitPattern(p);break;case"Flags":this.visitFlags(p);break;case"Disjunction":this.visitDisjunction(p);break;case"Alternative":this.visitAlternative(p);break;case"StartAnchor":this.visitStartAnchor(p);break;case"EndAnchor":this.visitEndAnchor(p);break;case"WordBoundary":this.visitWordBoundary(p);break;case"NonWordBoundary":this.visitNonWordBoundary(p);break;case"Lookahead":this.visitLookahead(p);break;case"NegativeLookahead":this.visitNegativeLookahead(p);break;case"Character":this.visitCharacter(p);break;case"Set":this.visitSet(p);break;case"Group":this.visitGroup(p);break;case"GroupBackReference":this.visitGroupBackReference(p);break;case"Quantifier":this.visitQuantifier(p);break}this.visitChildren(p)},h.prototype.visitPattern=function(p){},h.prototype.visitFlags=function(p){},h.prototype.visitDisjunction=function(p){},h.prototype.visitAlternative=function(p){},h.prototype.visitStartAnchor=function(p){},h.prototype.visitEndAnchor=function(p){},h.prototype.visitWordBoundary=function(p){},h.prototype.visitNonWordBoundary=function(p){},h.prototype.visitLookahead=function(p){},h.prototype.visitNegativeLookahead=function(p){},h.prototype.visitCharacter=function(p){},h.prototype.visitSet=function(p){},h.prototype.visitGroup=function(p){},h.prototype.visitGroupBackReference=function(p){},h.prototype.visitQuantifier=function(p){},{RegExpParser:t,BaseRegExpVisitor:h,VERSION:"0.5.0"}})});var gI=E(Eu=>{"use strict";Object.defineProperty(Eu,"__esModule",{value:!0});Eu.clearRegExpParserCache=Eu.getRegExpAst=void 0;var FEe=cI(),uI={},NEe=new FEe.RegExpParser;function LEe(t){var e=t.toString();if(uI.hasOwnProperty(e))return uI[e];var r=NEe.pattern(e);return uI[e]=r,r}Eu.getRegExpAst=LEe;function TEe(){uI={}}Eu.clearRegExpParserCache=TEe});var VH=E(fn=>{"use strict";var MEe=fn&&fn.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(fn,"__esModule",{value:!0});fn.canMatchCharCode=fn.firstCharOptimizedIndices=fn.getOptimizedStartCodesIndices=fn.failedOptimizationPrefixMsg=void 0;var qH=cI(),$n=Dt(),JH=gI(),sa=Hv(),WH="Complement Sets are not supported for first char optimization";fn.failedOptimizationPrefixMsg=`Unable to use "first char" lexer optimizations: +`;function OEe(t,e){e===void 0&&(e=!1);try{var r=(0,JH.getRegExpAst)(t),i=fI(r.value,{},r.flags.ignoreCase);return i}catch(s){if(s.message===WH)e&&(0,$n.PRINT_WARNING)(""+fn.failedOptimizationPrefixMsg+(" Unable to optimize: < "+t.toString()+` > +`)+` Complement Sets cannot be automatically optimized. + This will disable the lexer's first char optimizations. + See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#COMPLEMENT for details.`);else{var n="";e&&(n=` + This will disable the lexer's first char optimizations. + See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#REGEXP_PARSING for details.`),(0,$n.PRINT_ERROR)(fn.failedOptimizationPrefixMsg+` +`+(" Failed parsing: < "+t.toString()+` > +`)+(" Using the regexp-to-ast library version: "+qH.VERSION+` +`)+" Please open an issue at: https://github.com/bd82/regexp-to-ast/issues"+n)}}return[]}fn.getOptimizedStartCodesIndices=OEe;function fI(t,e,r){switch(t.type){case"Disjunction":for(var i=0;i=sa.minOptimizationVal)for(var f=u.from>=sa.minOptimizationVal?u.from:sa.minOptimizationVal,h=u.to,p=(0,sa.charCodeToOptimizedIndex)(f),d=(0,sa.charCodeToOptimizedIndex)(h),m=p;m<=d;m++)e[m]=m}}});break;case"Group":fI(o.value,e,r);break;default:throw Error("Non Exhaustive Match")}var a=o.quantifier!==void 0&&o.quantifier.atLeast===0;if(o.type==="Group"&&Gv(o)===!1||o.type!=="Group"&&a===!1)break}break;default:throw Error("non exhaustive match!")}return(0,$n.values)(e)}fn.firstCharOptimizedIndices=fI;function hI(t,e,r){var i=(0,sa.charCodeToOptimizedIndex)(t);e[i]=i,r===!0&&KEe(t,e)}function KEe(t,e){var r=String.fromCharCode(t),i=r.toUpperCase();if(i!==r){var n=(0,sa.charCodeToOptimizedIndex)(i.charCodeAt(0));e[n]=n}else{var s=r.toLowerCase();if(s!==r){var n=(0,sa.charCodeToOptimizedIndex)(s.charCodeAt(0));e[n]=n}}}function zH(t,e){return(0,$n.find)(t.value,function(r){if(typeof r=="number")return(0,$n.contains)(e,r);var i=r;return(0,$n.find)(e,function(n){return i.from<=n&&n<=i.to})!==void 0})}function Gv(t){return t.quantifier&&t.quantifier.atLeast===0?!0:t.value?(0,$n.isArray)(t.value)?(0,$n.every)(t.value,Gv):Gv(t.value):!1}var UEe=function(t){MEe(e,t);function e(r){var i=t.call(this)||this;return i.targetCharCodes=r,i.found=!1,i}return e.prototype.visitChildren=function(r){if(this.found!==!0){switch(r.type){case"Lookahead":this.visitLookahead(r);return;case"NegativeLookahead":this.visitNegativeLookahead(r);return}t.prototype.visitChildren.call(this,r)}},e.prototype.visitCharacter=function(r){(0,$n.contains)(this.targetCharCodes,r.value)&&(this.found=!0)},e.prototype.visitSet=function(r){r.complement?zH(r,this.targetCharCodes)===void 0&&(this.found=!0):zH(r,this.targetCharCodes)!==void 0&&(this.found=!0)},e}(qH.BaseRegExpVisitor);function HEe(t,e){if(e instanceof RegExp){var r=(0,JH.getRegExpAst)(e),i=new UEe(t);return i.visit(r),i.found}else return(0,$n.find)(e,function(n){return(0,$n.contains)(t,n.charCodeAt(0))})!==void 0}fn.canMatchCharCode=HEe});var Hv=E(je=>{"use strict";var _H=je&&je.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(je,"__esModule",{value:!0});je.charCodeToOptimizedIndex=je.minOptimizationVal=je.buildLineBreakIssueMessage=je.LineTerminatorOptimizedTester=je.isShortPattern=je.isCustomPattern=je.cloneEmptyGroups=je.performWarningRuntimeChecks=je.performRuntimeChecks=je.addStickyFlag=je.addStartOfInput=je.findUnreachablePatterns=je.findModesThatDoNotExist=je.findInvalidGroupType=je.findDuplicatePatterns=je.findUnsupportedFlags=je.findStartOfInputAnchor=je.findEmptyMatchRegExps=je.findEndOfInputAnchor=je.findInvalidPatterns=je.findMissingPatterns=je.validatePatterns=je.analyzeTokenTypes=je.enableSticky=je.disableSticky=je.SUPPORT_STICKY=je.MODES=je.DEFAULT_MODE=void 0;var XH=cI(),zt=Gh(),Ie=Dt(),Iu=VH(),ZH=gI(),ao="PATTERN";je.DEFAULT_MODE="defaultMode";je.MODES="modes";je.SUPPORT_STICKY=typeof new RegExp("(?:)").sticky=="boolean";function GEe(){je.SUPPORT_STICKY=!1}je.disableSticky=GEe;function jEe(){je.SUPPORT_STICKY=!0}je.enableSticky=jEe;function qEe(t,e){e=(0,Ie.defaults)(e,{useSticky:je.SUPPORT_STICKY,debug:!1,safeMode:!1,positionTracking:"full",lineTerminatorCharacters:["\r",` +`],tracer:function(B,b){return b()}});var r=e.tracer;r("initCharCodeToOptimizedIndexMap",function(){YEe()});var i;r("Reject Lexer.NA",function(){i=(0,Ie.reject)(t,function(B){return B[ao]===zt.Lexer.NA})});var n=!1,s;r("Transform Patterns",function(){n=!1,s=(0,Ie.map)(i,function(B){var b=B[ao];if((0,Ie.isRegExp)(b)){var R=b.source;return R.length===1&&R!=="^"&&R!=="$"&&R!=="."&&!b.ignoreCase?R:R.length===2&&R[0]==="\\"&&!(0,Ie.contains)(["d","D","s","S","t","r","n","t","0","c","b","B","f","v","w","W"],R[1])?R[1]:e.useSticky?Yv(b):jv(b)}else{if((0,Ie.isFunction)(b))return n=!0,{exec:b};if((0,Ie.has)(b,"exec"))return n=!0,b;if(typeof b=="string"){if(b.length===1)return b;var H=b.replace(/[\\^$.*+?()[\]{}|]/g,"\\$&"),L=new RegExp(H);return e.useSticky?Yv(L):jv(L)}else throw Error("non exhaustive match")}})});var o,a,l,c,u;r("misc mapping",function(){o=(0,Ie.map)(i,function(B){return B.tokenTypeIdx}),a=(0,Ie.map)(i,function(B){var b=B.GROUP;if(b!==zt.Lexer.SKIPPED){if((0,Ie.isString)(b))return b;if((0,Ie.isUndefined)(b))return!1;throw Error("non exhaustive match")}}),l=(0,Ie.map)(i,function(B){var b=B.LONGER_ALT;if(b){var R=(0,Ie.isArray)(b)?(0,Ie.map)(b,function(H){return(0,Ie.indexOf)(i,H)}):[(0,Ie.indexOf)(i,b)];return R}}),c=(0,Ie.map)(i,function(B){return B.PUSH_MODE}),u=(0,Ie.map)(i,function(B){return(0,Ie.has)(B,"POP_MODE")})});var g;r("Line Terminator Handling",function(){var B=tG(e.lineTerminatorCharacters);g=(0,Ie.map)(i,function(b){return!1}),e.positionTracking!=="onlyOffset"&&(g=(0,Ie.map)(i,function(b){if((0,Ie.has)(b,"LINE_BREAKS"))return b.LINE_BREAKS;if(eG(b,B)===!1)return(0,Iu.canMatchCharCode)(B,b.PATTERN)}))});var f,h,p,d;r("Misc Mapping #2",function(){f=(0,Ie.map)(i,qv),h=(0,Ie.map)(s,$H),p=(0,Ie.reduce)(i,function(B,b){var R=b.GROUP;return(0,Ie.isString)(R)&&R!==zt.Lexer.SKIPPED&&(B[R]=[]),B},{}),d=(0,Ie.map)(s,function(B,b){return{pattern:s[b],longerAlt:l[b],canLineTerminator:g[b],isCustom:f[b],short:h[b],group:a[b],push:c[b],pop:u[b],tokenTypeIdx:o[b],tokenType:i[b]}})});var m=!0,I=[];return e.safeMode||r("First Char Optimization",function(){I=(0,Ie.reduce)(i,function(B,b,R){if(typeof b.PATTERN=="string"){var H=b.PATTERN.charCodeAt(0),L=Wv(H);Jv(B,L,d[R])}else if((0,Ie.isArray)(b.START_CHARS_HINT)){var K;(0,Ie.forEach)(b.START_CHARS_HINT,function(ne){var q=typeof ne=="string"?ne.charCodeAt(0):ne,A=Wv(q);K!==A&&(K=A,Jv(B,A,d[R]))})}else if((0,Ie.isRegExp)(b.PATTERN))if(b.PATTERN.unicode)m=!1,e.ensureOptimizations&&(0,Ie.PRINT_ERROR)(""+Iu.failedOptimizationPrefixMsg+(" Unable to analyze < "+b.PATTERN.toString()+` > pattern. +`)+` The regexp unicode flag is not currently supported by the regexp-to-ast library. + This will disable the lexer's first char optimizations. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNICODE_OPTIMIZE`);else{var J=(0,Iu.getOptimizedStartCodesIndices)(b.PATTERN,e.ensureOptimizations);(0,Ie.isEmpty)(J)&&(m=!1),(0,Ie.forEach)(J,function(ne){Jv(B,ne,d[R])})}else e.ensureOptimizations&&(0,Ie.PRINT_ERROR)(""+Iu.failedOptimizationPrefixMsg+(" TokenType: <"+b.name+`> is using a custom token pattern without providing parameter. +`)+` This will disable the lexer's first char optimizations. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_OPTIMIZE`),m=!1;return B},[])}),r("ArrayPacking",function(){I=(0,Ie.packArray)(I)}),{emptyGroups:p,patternIdxToConfig:d,charCodeToPatternIdxToConfig:I,hasCustom:n,canBeOptimized:m}}je.analyzeTokenTypes=qEe;function WEe(t,e){var r=[],i=rG(t);r=r.concat(i.errors);var n=iG(i.valid),s=n.valid;return r=r.concat(n.errors),r=r.concat(JEe(s)),r=r.concat(nG(s)),r=r.concat(sG(s,e)),r=r.concat(oG(s)),r}je.validatePatterns=WEe;function JEe(t){var e=[],r=(0,Ie.filter)(t,function(i){return(0,Ie.isRegExp)(i[ao])});return e=e.concat(aG(r)),e=e.concat(lG(r)),e=e.concat(cG(r)),e=e.concat(uG(r)),e=e.concat(AG(r)),e}function rG(t){var e=(0,Ie.filter)(t,function(n){return!(0,Ie.has)(n,ao)}),r=(0,Ie.map)(e,function(n){return{message:"Token Type: ->"+n.name+"<- missing static 'PATTERN' property",type:zt.LexerDefinitionErrorType.MISSING_PATTERN,tokenTypes:[n]}}),i=(0,Ie.difference)(t,e);return{errors:r,valid:i}}je.findMissingPatterns=rG;function iG(t){var e=(0,Ie.filter)(t,function(n){var s=n[ao];return!(0,Ie.isRegExp)(s)&&!(0,Ie.isFunction)(s)&&!(0,Ie.has)(s,"exec")&&!(0,Ie.isString)(s)}),r=(0,Ie.map)(e,function(n){return{message:"Token Type: ->"+n.name+"<- static 'PATTERN' can only be a RegExp, a Function matching the {CustomPatternMatcherFunc} type or an Object matching the {ICustomPattern} interface.",type:zt.LexerDefinitionErrorType.INVALID_PATTERN,tokenTypes:[n]}}),i=(0,Ie.difference)(t,e);return{errors:r,valid:i}}je.findInvalidPatterns=iG;var zEe=/[^\\][\$]/;function aG(t){var e=function(n){_H(s,n);function s(){var o=n!==null&&n.apply(this,arguments)||this;return o.found=!1,o}return s.prototype.visitEndAnchor=function(o){this.found=!0},s}(XH.BaseRegExpVisitor),r=(0,Ie.filter)(t,function(n){var s=n[ao];try{var o=(0,ZH.getRegExpAst)(s),a=new e;return a.visit(o),a.found}catch(l){return zEe.test(s.source)}}),i=(0,Ie.map)(r,function(n){return{message:`Unexpected RegExp Anchor Error: + Token Type: ->`+n.name+`<- static 'PATTERN' cannot contain end of input anchor '$' + See chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:zt.LexerDefinitionErrorType.EOI_ANCHOR_FOUND,tokenTypes:[n]}});return i}je.findEndOfInputAnchor=aG;function AG(t){var e=(0,Ie.filter)(t,function(i){var n=i[ao];return n.test("")}),r=(0,Ie.map)(e,function(i){return{message:"Token Type: ->"+i.name+"<- static 'PATTERN' must not match an empty string",type:zt.LexerDefinitionErrorType.EMPTY_MATCH_PATTERN,tokenTypes:[i]}});return r}je.findEmptyMatchRegExps=AG;var VEe=/[^\\[][\^]|^\^/;function lG(t){var e=function(n){_H(s,n);function s(){var o=n!==null&&n.apply(this,arguments)||this;return o.found=!1,o}return s.prototype.visitStartAnchor=function(o){this.found=!0},s}(XH.BaseRegExpVisitor),r=(0,Ie.filter)(t,function(n){var s=n[ao];try{var o=(0,ZH.getRegExpAst)(s),a=new e;return a.visit(o),a.found}catch(l){return VEe.test(s.source)}}),i=(0,Ie.map)(r,function(n){return{message:`Unexpected RegExp Anchor Error: + Token Type: ->`+n.name+`<- static 'PATTERN' cannot contain start of input anchor '^' + See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:zt.LexerDefinitionErrorType.SOI_ANCHOR_FOUND,tokenTypes:[n]}});return i}je.findStartOfInputAnchor=lG;function cG(t){var e=(0,Ie.filter)(t,function(i){var n=i[ao];return n instanceof RegExp&&(n.multiline||n.global)}),r=(0,Ie.map)(e,function(i){return{message:"Token Type: ->"+i.name+"<- static 'PATTERN' may NOT contain global('g') or multiline('m')",type:zt.LexerDefinitionErrorType.UNSUPPORTED_FLAGS_FOUND,tokenTypes:[i]}});return r}je.findUnsupportedFlags=cG;function uG(t){var e=[],r=(0,Ie.map)(t,function(s){return(0,Ie.reduce)(t,function(o,a){return s.PATTERN.source===a.PATTERN.source&&!(0,Ie.contains)(e,a)&&a.PATTERN!==zt.Lexer.NA&&(e.push(a),o.push(a)),o},[])});r=(0,Ie.compact)(r);var i=(0,Ie.filter)(r,function(s){return s.length>1}),n=(0,Ie.map)(i,function(s){var o=(0,Ie.map)(s,function(l){return l.name}),a=(0,Ie.first)(s).PATTERN;return{message:"The same RegExp pattern ->"+a+"<-"+("has been used in all of the following Token Types: "+o.join(", ")+" <-"),type:zt.LexerDefinitionErrorType.DUPLICATE_PATTERNS_FOUND,tokenTypes:s}});return n}je.findDuplicatePatterns=uG;function nG(t){var e=(0,Ie.filter)(t,function(i){if(!(0,Ie.has)(i,"GROUP"))return!1;var n=i.GROUP;return n!==zt.Lexer.SKIPPED&&n!==zt.Lexer.NA&&!(0,Ie.isString)(n)}),r=(0,Ie.map)(e,function(i){return{message:"Token Type: ->"+i.name+"<- static 'GROUP' can only be Lexer.SKIPPED/Lexer.NA/A String",type:zt.LexerDefinitionErrorType.INVALID_GROUP_TYPE_FOUND,tokenTypes:[i]}});return r}je.findInvalidGroupType=nG;function sG(t,e){var r=(0,Ie.filter)(t,function(n){return n.PUSH_MODE!==void 0&&!(0,Ie.contains)(e,n.PUSH_MODE)}),i=(0,Ie.map)(r,function(n){var s="Token Type: ->"+n.name+"<- static 'PUSH_MODE' value cannot refer to a Lexer Mode ->"+n.PUSH_MODE+"<-which does not exist";return{message:s,type:zt.LexerDefinitionErrorType.PUSH_MODE_DOES_NOT_EXIST,tokenTypes:[n]}});return i}je.findModesThatDoNotExist=sG;function oG(t){var e=[],r=(0,Ie.reduce)(t,function(i,n,s){var o=n.PATTERN;return o===zt.Lexer.NA||((0,Ie.isString)(o)?i.push({str:o,idx:s,tokenType:n}):(0,Ie.isRegExp)(o)&&XEe(o)&&i.push({str:o.source,idx:s,tokenType:n})),i},[]);return(0,Ie.forEach)(t,function(i,n){(0,Ie.forEach)(r,function(s){var o=s.str,a=s.idx,l=s.tokenType;if(n"+i.name+"<-")+`in the lexer's definition. +See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNREACHABLE`;e.push({message:c,type:zt.LexerDefinitionErrorType.UNREACHABLE_PATTERN,tokenTypes:[i,l]})}})}),e}je.findUnreachablePatterns=oG;function _Ee(t,e){if((0,Ie.isRegExp)(e)){var r=e.exec(t);return r!==null&&r.index===0}else{if((0,Ie.isFunction)(e))return e(t,0,[],{});if((0,Ie.has)(e,"exec"))return e.exec(t,0,[],{});if(typeof e=="string")return e===t;throw Error("non exhaustive match")}}function XEe(t){var e=[".","\\","[","]","|","^","$","(",")","?","*","+","{"];return(0,Ie.find)(e,function(r){return t.source.indexOf(r)!==-1})===void 0}function jv(t){var e=t.ignoreCase?"i":"";return new RegExp("^(?:"+t.source+")",e)}je.addStartOfInput=jv;function Yv(t){var e=t.ignoreCase?"iy":"y";return new RegExp(""+t.source,e)}je.addStickyFlag=Yv;function ZEe(t,e,r){var i=[];return(0,Ie.has)(t,je.DEFAULT_MODE)||i.push({message:"A MultiMode Lexer cannot be initialized without a <"+je.DEFAULT_MODE+`> property in its definition +`,type:zt.LexerDefinitionErrorType.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE}),(0,Ie.has)(t,je.MODES)||i.push({message:"A MultiMode Lexer cannot be initialized without a <"+je.MODES+`> property in its definition +`,type:zt.LexerDefinitionErrorType.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY}),(0,Ie.has)(t,je.MODES)&&(0,Ie.has)(t,je.DEFAULT_MODE)&&!(0,Ie.has)(t.modes,t.defaultMode)&&i.push({message:"A MultiMode Lexer cannot be initialized with a "+je.DEFAULT_MODE+": <"+t.defaultMode+`>which does not exist +`,type:zt.LexerDefinitionErrorType.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST}),(0,Ie.has)(t,je.MODES)&&(0,Ie.forEach)(t.modes,function(n,s){(0,Ie.forEach)(n,function(o,a){(0,Ie.isUndefined)(o)&&i.push({message:"A Lexer cannot be initialized using an undefined Token Type. Mode:"+("<"+s+"> at index: <"+a+`> +`),type:zt.LexerDefinitionErrorType.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED})})}),i}je.performRuntimeChecks=ZEe;function $Ee(t,e,r){var i=[],n=!1,s=(0,Ie.compact)((0,Ie.flatten)((0,Ie.mapValues)(t.modes,function(l){return l}))),o=(0,Ie.reject)(s,function(l){return l[ao]===zt.Lexer.NA}),a=tG(r);return e&&(0,Ie.forEach)(o,function(l){var c=eG(l,a);if(c!==!1){var u=gG(l,c),g={message:u,type:c.issue,tokenType:l};i.push(g)}else(0,Ie.has)(l,"LINE_BREAKS")?l.LINE_BREAKS===!0&&(n=!0):(0,Iu.canMatchCharCode)(a,l.PATTERN)&&(n=!0)}),e&&!n&&i.push({message:`Warning: No LINE_BREAKS Found. + This Lexer has been defined to track line and column information, + But none of the Token Types can be identified as matching a line terminator. + See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#LINE_BREAKS + for details.`,type:zt.LexerDefinitionErrorType.NO_LINE_BREAKS_FLAGS}),i}je.performWarningRuntimeChecks=$Ee;function eIe(t){var e={},r=(0,Ie.keys)(t);return(0,Ie.forEach)(r,function(i){var n=t[i];if((0,Ie.isArray)(n))e[i]=[];else throw Error("non exhaustive match")}),e}je.cloneEmptyGroups=eIe;function qv(t){var e=t.PATTERN;if((0,Ie.isRegExp)(e))return!1;if((0,Ie.isFunction)(e))return!0;if((0,Ie.has)(e,"exec"))return!0;if((0,Ie.isString)(e))return!1;throw Error("non exhaustive match")}je.isCustomPattern=qv;function $H(t){return(0,Ie.isString)(t)&&t.length===1?t.charCodeAt(0):!1}je.isShortPattern=$H;je.LineTerminatorOptimizedTester={test:function(t){for(var e=t.length,r=this.lastIndex;r Token Type +`)+(" Root cause: "+e.errMsg+`. +`)+" For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#IDENTIFY_TERMINATOR";if(e.issue===zt.LexerDefinitionErrorType.CUSTOM_LINE_BREAK)return`Warning: A Custom Token Pattern should specify the option. +`+(" The problem is in the <"+t.name+`> Token Type +`)+" For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_LINE_BREAK";throw Error("non exhaustive match")}je.buildLineBreakIssueMessage=gG;function tG(t){var e=(0,Ie.map)(t,function(r){return(0,Ie.isString)(r)&&r.length>0?r.charCodeAt(0):r});return e}function Jv(t,e,r){t[e]===void 0?t[e]=[r]:t[e].push(r)}je.minOptimizationVal=256;var pI=[];function Wv(t){return t255?255+~~(t/255):t}}});var yu=E(Bt=>{"use strict";Object.defineProperty(Bt,"__esModule",{value:!0});Bt.isTokenType=Bt.hasExtendingTokensTypesMapProperty=Bt.hasExtendingTokensTypesProperty=Bt.hasCategoriesProperty=Bt.hasShortKeyProperty=Bt.singleAssignCategoriesToksMap=Bt.assignCategoriesMapProp=Bt.assignCategoriesTokensProp=Bt.assignTokenDefaultProps=Bt.expandCategories=Bt.augmentTokenTypes=Bt.tokenIdxToClass=Bt.tokenShortNameIdx=Bt.tokenStructuredMatcherNoCategories=Bt.tokenStructuredMatcher=void 0;var Kr=Dt();function tIe(t,e){var r=t.tokenTypeIdx;return r===e.tokenTypeIdx?!0:e.isParent===!0&&e.categoryMatchesMap[r]===!0}Bt.tokenStructuredMatcher=tIe;function rIe(t,e){return t.tokenTypeIdx===e.tokenTypeIdx}Bt.tokenStructuredMatcherNoCategories=rIe;Bt.tokenShortNameIdx=1;Bt.tokenIdxToClass={};function iIe(t){var e=fG(t);hG(e),dG(e),pG(e),(0,Kr.forEach)(e,function(r){r.isParent=r.categoryMatches.length>0})}Bt.augmentTokenTypes=iIe;function fG(t){for(var e=(0,Kr.cloneArr)(t),r=t,i=!0;i;){r=(0,Kr.compact)((0,Kr.flatten)((0,Kr.map)(r,function(s){return s.CATEGORIES})));var n=(0,Kr.difference)(r,e);e=e.concat(n),(0,Kr.isEmpty)(n)?i=!1:r=n}return e}Bt.expandCategories=fG;function hG(t){(0,Kr.forEach)(t,function(e){CG(e)||(Bt.tokenIdxToClass[Bt.tokenShortNameIdx]=e,e.tokenTypeIdx=Bt.tokenShortNameIdx++),zv(e)&&!(0,Kr.isArray)(e.CATEGORIES)&&(e.CATEGORIES=[e.CATEGORIES]),zv(e)||(e.CATEGORIES=[]),mG(e)||(e.categoryMatches=[]),EG(e)||(e.categoryMatchesMap={})})}Bt.assignTokenDefaultProps=hG;function pG(t){(0,Kr.forEach)(t,function(e){e.categoryMatches=[],(0,Kr.forEach)(e.categoryMatchesMap,function(r,i){e.categoryMatches.push(Bt.tokenIdxToClass[i].tokenTypeIdx)})})}Bt.assignCategoriesTokensProp=pG;function dG(t){(0,Kr.forEach)(t,function(e){Vv([],e)})}Bt.assignCategoriesMapProp=dG;function Vv(t,e){(0,Kr.forEach)(t,function(r){e.categoryMatchesMap[r.tokenTypeIdx]=!0}),(0,Kr.forEach)(e.CATEGORIES,function(r){var i=t.concat(e);(0,Kr.contains)(i,r)||Vv(i,r)})}Bt.singleAssignCategoriesToksMap=Vv;function CG(t){return(0,Kr.has)(t,"tokenTypeIdx")}Bt.hasShortKeyProperty=CG;function zv(t){return(0,Kr.has)(t,"CATEGORIES")}Bt.hasCategoriesProperty=zv;function mG(t){return(0,Kr.has)(t,"categoryMatches")}Bt.hasExtendingTokensTypesProperty=mG;function EG(t){return(0,Kr.has)(t,"categoryMatchesMap")}Bt.hasExtendingTokensTypesMapProperty=EG;function nIe(t){return(0,Kr.has)(t,"tokenTypeIdx")}Bt.isTokenType=nIe});var _v=E(dI=>{"use strict";Object.defineProperty(dI,"__esModule",{value:!0});dI.defaultLexerErrorProvider=void 0;dI.defaultLexerErrorProvider={buildUnableToPopLexerModeMessage:function(t){return"Unable to pop Lexer Mode after encountering Token ->"+t.image+"<- The Mode Stack is empty"},buildUnexpectedCharactersMessage:function(t,e,r,i,n){return"unexpected character: ->"+t.charAt(e)+"<- at offset: "+e+","+(" skipped "+r+" characters.")}}});var Gh=E(Rl=>{"use strict";Object.defineProperty(Rl,"__esModule",{value:!0});Rl.Lexer=Rl.LexerDefinitionErrorType=void 0;var Ps=Hv(),Vt=Dt(),sIe=yu(),oIe=_v(),aIe=gI(),AIe;(function(t){t[t.MISSING_PATTERN=0]="MISSING_PATTERN",t[t.INVALID_PATTERN=1]="INVALID_PATTERN",t[t.EOI_ANCHOR_FOUND=2]="EOI_ANCHOR_FOUND",t[t.UNSUPPORTED_FLAGS_FOUND=3]="UNSUPPORTED_FLAGS_FOUND",t[t.DUPLICATE_PATTERNS_FOUND=4]="DUPLICATE_PATTERNS_FOUND",t[t.INVALID_GROUP_TYPE_FOUND=5]="INVALID_GROUP_TYPE_FOUND",t[t.PUSH_MODE_DOES_NOT_EXIST=6]="PUSH_MODE_DOES_NOT_EXIST",t[t.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE=7]="MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE",t[t.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY=8]="MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY",t[t.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST=9]="MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST",t[t.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED=10]="LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED",t[t.SOI_ANCHOR_FOUND=11]="SOI_ANCHOR_FOUND",t[t.EMPTY_MATCH_PATTERN=12]="EMPTY_MATCH_PATTERN",t[t.NO_LINE_BREAKS_FLAGS=13]="NO_LINE_BREAKS_FLAGS",t[t.UNREACHABLE_PATTERN=14]="UNREACHABLE_PATTERN",t[t.IDENTIFY_TERMINATOR=15]="IDENTIFY_TERMINATOR",t[t.CUSTOM_LINE_BREAK=16]="CUSTOM_LINE_BREAK"})(AIe=Rl.LexerDefinitionErrorType||(Rl.LexerDefinitionErrorType={}));var jh={deferDefinitionErrorsHandling:!1,positionTracking:"full",lineTerminatorsPattern:/\n|\r\n?/g,lineTerminatorCharacters:[` +`,"\r"],ensureOptimizations:!1,safeMode:!1,errorMessageProvider:oIe.defaultLexerErrorProvider,traceInitPerf:!1,skipValidations:!1};Object.freeze(jh);var lIe=function(){function t(e,r){var i=this;if(r===void 0&&(r=jh),this.lexerDefinition=e,this.lexerDefinitionErrors=[],this.lexerDefinitionWarning=[],this.patternIdxToConfig={},this.charCodeToPatternIdxToConfig={},this.modes=[],this.emptyGroups={},this.config=void 0,this.trackStartLines=!0,this.trackEndLines=!0,this.hasCustom=!1,this.canModeBeOptimized={},typeof r=="boolean")throw Error(`The second argument to the Lexer constructor is now an ILexerConfig Object. +a boolean 2nd argument is no longer supported`);this.config=(0,Vt.merge)(jh,r);var n=this.config.traceInitPerf;n===!0?(this.traceInitMaxIdent=Infinity,this.traceInitPerf=!0):typeof n=="number"&&(this.traceInitMaxIdent=n,this.traceInitPerf=!0),this.traceInitIndent=-1,this.TRACE_INIT("Lexer Constructor",function(){var s,o=!0;i.TRACE_INIT("Lexer Config handling",function(){if(i.config.lineTerminatorsPattern===jh.lineTerminatorsPattern)i.config.lineTerminatorsPattern=Ps.LineTerminatorOptimizedTester;else if(i.config.lineTerminatorCharacters===jh.lineTerminatorCharacters)throw Error(`Error: Missing property on the Lexer config. + For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#MISSING_LINE_TERM_CHARS`);if(r.safeMode&&r.ensureOptimizations)throw Error('"safeMode" and "ensureOptimizations" flags are mutually exclusive.');i.trackStartLines=/full|onlyStart/i.test(i.config.positionTracking),i.trackEndLines=/full/i.test(i.config.positionTracking),(0,Vt.isArray)(e)?(s={modes:{}},s.modes[Ps.DEFAULT_MODE]=(0,Vt.cloneArr)(e),s[Ps.DEFAULT_MODE]=Ps.DEFAULT_MODE):(o=!1,s=(0,Vt.cloneObj)(e))}),i.config.skipValidations===!1&&(i.TRACE_INIT("performRuntimeChecks",function(){i.lexerDefinitionErrors=i.lexerDefinitionErrors.concat((0,Ps.performRuntimeChecks)(s,i.trackStartLines,i.config.lineTerminatorCharacters))}),i.TRACE_INIT("performWarningRuntimeChecks",function(){i.lexerDefinitionWarning=i.lexerDefinitionWarning.concat((0,Ps.performWarningRuntimeChecks)(s,i.trackStartLines,i.config.lineTerminatorCharacters))})),s.modes=s.modes?s.modes:{},(0,Vt.forEach)(s.modes,function(u,g){s.modes[g]=(0,Vt.reject)(u,function(f){return(0,Vt.isUndefined)(f)})});var a=(0,Vt.keys)(s.modes);if((0,Vt.forEach)(s.modes,function(u,g){i.TRACE_INIT("Mode: <"+g+"> processing",function(){if(i.modes.push(g),i.config.skipValidations===!1&&i.TRACE_INIT("validatePatterns",function(){i.lexerDefinitionErrors=i.lexerDefinitionErrors.concat((0,Ps.validatePatterns)(u,a))}),(0,Vt.isEmpty)(i.lexerDefinitionErrors)){(0,sIe.augmentTokenTypes)(u);var f;i.TRACE_INIT("analyzeTokenTypes",function(){f=(0,Ps.analyzeTokenTypes)(u,{lineTerminatorCharacters:i.config.lineTerminatorCharacters,positionTracking:r.positionTracking,ensureOptimizations:r.ensureOptimizations,safeMode:r.safeMode,tracer:i.TRACE_INIT.bind(i)})}),i.patternIdxToConfig[g]=f.patternIdxToConfig,i.charCodeToPatternIdxToConfig[g]=f.charCodeToPatternIdxToConfig,i.emptyGroups=(0,Vt.merge)(i.emptyGroups,f.emptyGroups),i.hasCustom=f.hasCustom||i.hasCustom,i.canModeBeOptimized[g]=f.canBeOptimized}})}),i.defaultMode=s.defaultMode,!(0,Vt.isEmpty)(i.lexerDefinitionErrors)&&!i.config.deferDefinitionErrorsHandling){var l=(0,Vt.map)(i.lexerDefinitionErrors,function(u){return u.message}),c=l.join(`----------------------- +`);throw new Error(`Errors detected in definition of Lexer: +`+c)}(0,Vt.forEach)(i.lexerDefinitionWarning,function(u){(0,Vt.PRINT_WARNING)(u.message)}),i.TRACE_INIT("Choosing sub-methods implementations",function(){if(Ps.SUPPORT_STICKY?(i.chopInput=Vt.IDENTITY,i.match=i.matchWithTest):(i.updateLastIndex=Vt.NOOP,i.match=i.matchWithExec),o&&(i.handleModes=Vt.NOOP),i.trackStartLines===!1&&(i.computeNewColumn=Vt.IDENTITY),i.trackEndLines===!1&&(i.updateTokenEndLineColumnLocation=Vt.NOOP),/full/i.test(i.config.positionTracking))i.createTokenInstance=i.createFullToken;else if(/onlyStart/i.test(i.config.positionTracking))i.createTokenInstance=i.createStartOnlyToken;else if(/onlyOffset/i.test(i.config.positionTracking))i.createTokenInstance=i.createOffsetOnlyToken;else throw Error('Invalid config option: "'+i.config.positionTracking+'"');i.hasCustom?(i.addToken=i.addTokenUsingPush,i.handlePayload=i.handlePayloadWithCustom):(i.addToken=i.addTokenUsingMemberAccess,i.handlePayload=i.handlePayloadNoCustom)}),i.TRACE_INIT("Failed Optimization Warnings",function(){var u=(0,Vt.reduce)(i.canModeBeOptimized,function(g,f,h){return f===!1&&g.push(h),g},[]);if(r.ensureOptimizations&&!(0,Vt.isEmpty)(u))throw Error("Lexer Modes: < "+u.join(", ")+` > cannot be optimized. + Disable the "ensureOptimizations" lexer config flag to silently ignore this and run the lexer in an un-optimized mode. + Or inspect the console log for details on how to resolve these issues.`)}),i.TRACE_INIT("clearRegExpParserCache",function(){(0,aIe.clearRegExpParserCache)()}),i.TRACE_INIT("toFastProperties",function(){(0,Vt.toFastProperties)(i)})})}return t.prototype.tokenize=function(e,r){if(r===void 0&&(r=this.defaultMode),!(0,Vt.isEmpty)(this.lexerDefinitionErrors)){var i=(0,Vt.map)(this.lexerDefinitionErrors,function(o){return o.message}),n=i.join(`----------------------- +`);throw new Error(`Unable to Tokenize because Errors detected in definition of Lexer: +`+n)}var s=this.tokenizeInternal(e,r);return s},t.prototype.tokenizeInternal=function(e,r){var i=this,n,s,o,a,l,c,u,g,f,h,p,d,m,I,B,b,R=e,H=R.length,L=0,K=0,J=this.hasCustom?0:Math.floor(e.length/10),ne=new Array(J),q=[],A=this.trackStartLines?1:void 0,V=this.trackStartLines?1:void 0,W=(0,Ps.cloneEmptyGroups)(this.emptyGroups),X=this.trackStartLines,F=this.config.lineTerminatorsPattern,D=0,he=[],pe=[],Ne=[],Pe=[];Object.freeze(Pe);var qe=void 0;function re(){return he}function se(wr){var Ui=(0,Ps.charCodeToOptimizedIndex)(wr),ws=pe[Ui];return ws===void 0?Pe:ws}var be=function(wr){if(Ne.length===1&&wr.tokenType.PUSH_MODE===void 0){var Ui=i.config.errorMessageProvider.buildUnableToPopLexerModeMessage(wr);q.push({offset:wr.startOffset,line:wr.startLine!==void 0?wr.startLine:void 0,column:wr.startColumn!==void 0?wr.startColumn:void 0,length:wr.image.length,message:Ui})}else{Ne.pop();var ws=(0,Vt.last)(Ne);he=i.patternIdxToConfig[ws],pe=i.charCodeToPatternIdxToConfig[ws],D=he.length;var Tf=i.canModeBeOptimized[ws]&&i.config.safeMode===!1;pe&&Tf?qe=se:qe=re}};function ae(wr){Ne.push(wr),pe=this.charCodeToPatternIdxToConfig[wr],he=this.patternIdxToConfig[wr],D=he.length,D=he.length;var Ui=this.canModeBeOptimized[wr]&&this.config.safeMode===!1;pe&&Ui?qe=se:qe=re}ae.call(this,r);for(var Ae;Lc.length){c=a,u=g,Ae=Oe;break}}}break}}if(c!==null){if(f=c.length,h=Ae.group,h!==void 0&&(p=Ae.tokenTypeIdx,d=this.createTokenInstance(c,L,p,Ae.tokenType,A,V,f),this.handlePayload(d,u),h===!1?K=this.addToken(ne,K,d):W[h].push(d)),e=this.chopInput(e,f),L=L+f,V=this.computeNewColumn(V,f),X===!0&&Ae.canLineTerminator===!0){var dt=0,ri=void 0,ii=void 0;F.lastIndex=0;do ri=F.test(c),ri===!0&&(ii=F.lastIndex-1,dt++);while(ri===!0);dt!==0&&(A=A+dt,V=f-ii,this.updateTokenEndLineColumnLocation(d,h,ii,dt,A,V,f))}this.handleModes(Ae,be,ae,d)}else{for(var an=L,yr=A,Ki=V,Qi=!1;!Qi&&L <"+e+">");var n=(0,Vt.timer)(r),s=n.time,o=n.value,a=s>10?console.warn:console.log;return this.traceInitIndent time: "+s+"ms"),this.traceInitIndent--,o}else return r()},t.SKIPPED="This marks a skipped Token pattern, this means each token identified by it willbe consumed and then thrown into oblivion, this can be used to for example to completely ignore whitespace.",t.NA=/NOT_APPLICABLE/,t}();Rl.Lexer=lIe});var nA=E(Ci=>{"use strict";Object.defineProperty(Ci,"__esModule",{value:!0});Ci.tokenMatcher=Ci.createTokenInstance=Ci.EOF=Ci.createToken=Ci.hasTokenLabel=Ci.tokenName=Ci.tokenLabel=void 0;var Ds=Dt(),cIe=Gh(),Xv=yu();function uIe(t){return IG(t)?t.LABEL:t.name}Ci.tokenLabel=uIe;function gIe(t){return t.name}Ci.tokenName=gIe;function IG(t){return(0,Ds.isString)(t.LABEL)&&t.LABEL!==""}Ci.hasTokenLabel=IG;var fIe="parent",yG="categories",wG="label",BG="group",QG="push_mode",bG="pop_mode",vG="longer_alt",SG="line_breaks",xG="start_chars_hint";function kG(t){return hIe(t)}Ci.createToken=kG;function hIe(t){var e=t.pattern,r={};if(r.name=t.name,(0,Ds.isUndefined)(e)||(r.PATTERN=e),(0,Ds.has)(t,fIe))throw`The parent property is no longer supported. +See: https://github.com/chevrotain/chevrotain/issues/564#issuecomment-349062346 for details.`;return(0,Ds.has)(t,yG)&&(r.CATEGORIES=t[yG]),(0,Xv.augmentTokenTypes)([r]),(0,Ds.has)(t,wG)&&(r.LABEL=t[wG]),(0,Ds.has)(t,BG)&&(r.GROUP=t[BG]),(0,Ds.has)(t,bG)&&(r.POP_MODE=t[bG]),(0,Ds.has)(t,QG)&&(r.PUSH_MODE=t[QG]),(0,Ds.has)(t,vG)&&(r.LONGER_ALT=t[vG]),(0,Ds.has)(t,SG)&&(r.LINE_BREAKS=t[SG]),(0,Ds.has)(t,xG)&&(r.START_CHARS_HINT=t[xG]),r}Ci.EOF=kG({name:"EOF",pattern:cIe.Lexer.NA});(0,Xv.augmentTokenTypes)([Ci.EOF]);function pIe(t,e,r,i,n,s,o,a){return{image:e,startOffset:r,endOffset:i,startLine:n,endLine:s,startColumn:o,endColumn:a,tokenTypeIdx:t.tokenTypeIdx,tokenType:t}}Ci.createTokenInstance=pIe;function dIe(t,e){return(0,Xv.tokenStructuredMatcher)(t,e)}Ci.tokenMatcher=dIe});var hn=E(Tt=>{"use strict";var oa=Tt&&Tt.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Tt,"__esModule",{value:!0});Tt.serializeProduction=Tt.serializeGrammar=Tt.Terminal=Tt.Alternation=Tt.RepetitionWithSeparator=Tt.Repetition=Tt.RepetitionMandatoryWithSeparator=Tt.RepetitionMandatory=Tt.Option=Tt.Alternative=Tt.Rule=Tt.NonTerminal=Tt.AbstractProduction=void 0;var $t=Dt(),CIe=nA(),Ao=function(){function t(e){this._definition=e}return Object.defineProperty(t.prototype,"definition",{get:function(){return this._definition},set:function(e){this._definition=e},enumerable:!1,configurable:!0}),t.prototype.accept=function(e){e.visit(this),(0,$t.forEach)(this.definition,function(r){r.accept(e)})},t}();Tt.AbstractProduction=Ao;var PG=function(t){oa(e,t);function e(r){var i=t.call(this,[])||this;return i.idx=1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return Object.defineProperty(e.prototype,"definition",{get:function(){return this.referencedRule!==void 0?this.referencedRule.definition:[]},set:function(r){},enumerable:!1,configurable:!0}),e.prototype.accept=function(r){r.visit(this)},e}(Ao);Tt.NonTerminal=PG;var DG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.orgText="",(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return e}(Ao);Tt.Rule=DG;var RG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.ignoreAmbiguities=!1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return e}(Ao);Tt.Alternative=RG;var FG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return e}(Ao);Tt.Option=FG;var NG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return e}(Ao);Tt.RepetitionMandatory=NG;var LG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return e}(Ao);Tt.RepetitionMandatoryWithSeparator=LG;var TG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return e}(Ao);Tt.Repetition=TG;var MG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return e}(Ao);Tt.RepetitionWithSeparator=MG;var OG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,i.ignoreAmbiguities=!1,i.hasPredicates=!1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return Object.defineProperty(e.prototype,"definition",{get:function(){return this._definition},set:function(r){this._definition=r},enumerable:!1,configurable:!0}),e}(Ao);Tt.Alternation=OG;var CI=function(){function t(e){this.idx=1,(0,$t.assign)(this,(0,$t.pick)(e,function(r){return r!==void 0}))}return t.prototype.accept=function(e){e.visit(this)},t}();Tt.Terminal=CI;function mIe(t){return(0,$t.map)(t,Yh)}Tt.serializeGrammar=mIe;function Yh(t){function e(s){return(0,$t.map)(s,Yh)}if(t instanceof PG){var r={type:"NonTerminal",name:t.nonTerminalName,idx:t.idx};return(0,$t.isString)(t.label)&&(r.label=t.label),r}else{if(t instanceof RG)return{type:"Alternative",definition:e(t.definition)};if(t instanceof FG)return{type:"Option",idx:t.idx,definition:e(t.definition)};if(t instanceof NG)return{type:"RepetitionMandatory",idx:t.idx,definition:e(t.definition)};if(t instanceof LG)return{type:"RepetitionMandatoryWithSeparator",idx:t.idx,separator:Yh(new CI({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof MG)return{type:"RepetitionWithSeparator",idx:t.idx,separator:Yh(new CI({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof TG)return{type:"Repetition",idx:t.idx,definition:e(t.definition)};if(t instanceof OG)return{type:"Alternation",idx:t.idx,definition:e(t.definition)};if(t instanceof CI){var i={type:"Terminal",name:t.terminalType.name,label:(0,CIe.tokenLabel)(t.terminalType),idx:t.idx};(0,$t.isString)(t.label)&&(i.terminalLabel=t.label);var n=t.terminalType.PATTERN;return t.terminalType.PATTERN&&(i.pattern=(0,$t.isRegExp)(n)?n.source:n),i}else{if(t instanceof DG)return{type:"Rule",name:t.name,orgText:t.orgText,definition:e(t.definition)};throw Error("non exhaustive match")}}}Tt.serializeProduction=Yh});var EI=E(mI=>{"use strict";Object.defineProperty(mI,"__esModule",{value:!0});mI.RestWalker=void 0;var Zv=Dt(),pn=hn(),EIe=function(){function t(){}return t.prototype.walk=function(e,r){var i=this;r===void 0&&(r=[]),(0,Zv.forEach)(e.definition,function(n,s){var o=(0,Zv.drop)(e.definition,s+1);if(n instanceof pn.NonTerminal)i.walkProdRef(n,o,r);else if(n instanceof pn.Terminal)i.walkTerminal(n,o,r);else if(n instanceof pn.Alternative)i.walkFlat(n,o,r);else if(n instanceof pn.Option)i.walkOption(n,o,r);else if(n instanceof pn.RepetitionMandatory)i.walkAtLeastOne(n,o,r);else if(n instanceof pn.RepetitionMandatoryWithSeparator)i.walkAtLeastOneSep(n,o,r);else if(n instanceof pn.RepetitionWithSeparator)i.walkManySep(n,o,r);else if(n instanceof pn.Repetition)i.walkMany(n,o,r);else if(n instanceof pn.Alternation)i.walkOr(n,o,r);else throw Error("non exhaustive match")})},t.prototype.walkTerminal=function(e,r,i){},t.prototype.walkProdRef=function(e,r,i){},t.prototype.walkFlat=function(e,r,i){var n=r.concat(i);this.walk(e,n)},t.prototype.walkOption=function(e,r,i){var n=r.concat(i);this.walk(e,n)},t.prototype.walkAtLeastOne=function(e,r,i){var n=[new pn.Option({definition:e.definition})].concat(r,i);this.walk(e,n)},t.prototype.walkAtLeastOneSep=function(e,r,i){var n=KG(e,r,i);this.walk(e,n)},t.prototype.walkMany=function(e,r,i){var n=[new pn.Option({definition:e.definition})].concat(r,i);this.walk(e,n)},t.prototype.walkManySep=function(e,r,i){var n=KG(e,r,i);this.walk(e,n)},t.prototype.walkOr=function(e,r,i){var n=this,s=r.concat(i);(0,Zv.forEach)(e.definition,function(o){var a=new pn.Alternative({definition:[o]});n.walk(a,s)})},t}();mI.RestWalker=EIe;function KG(t,e,r){var i=[new pn.Option({definition:[new pn.Terminal({terminalType:t.separator})].concat(t.definition)})],n=i.concat(e,r);return n}});var wu=E(II=>{"use strict";Object.defineProperty(II,"__esModule",{value:!0});II.GAstVisitor=void 0;var lo=hn(),IIe=function(){function t(){}return t.prototype.visit=function(e){var r=e;switch(r.constructor){case lo.NonTerminal:return this.visitNonTerminal(r);case lo.Alternative:return this.visitAlternative(r);case lo.Option:return this.visitOption(r);case lo.RepetitionMandatory:return this.visitRepetitionMandatory(r);case lo.RepetitionMandatoryWithSeparator:return this.visitRepetitionMandatoryWithSeparator(r);case lo.RepetitionWithSeparator:return this.visitRepetitionWithSeparator(r);case lo.Repetition:return this.visitRepetition(r);case lo.Alternation:return this.visitAlternation(r);case lo.Terminal:return this.visitTerminal(r);case lo.Rule:return this.visitRule(r);default:throw Error("non exhaustive match")}},t.prototype.visitNonTerminal=function(e){},t.prototype.visitAlternative=function(e){},t.prototype.visitOption=function(e){},t.prototype.visitRepetition=function(e){},t.prototype.visitRepetitionMandatory=function(e){},t.prototype.visitRepetitionMandatoryWithSeparator=function(e){},t.prototype.visitRepetitionWithSeparator=function(e){},t.prototype.visitAlternation=function(e){},t.prototype.visitTerminal=function(e){},t.prototype.visitRule=function(e){},t}();II.GAstVisitor=IIe});var Jh=E(Si=>{"use strict";var yIe=Si&&Si.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Si,"__esModule",{value:!0});Si.collectMethods=Si.DslMethodsCollectorVisitor=Si.getProductionDslName=Si.isBranchingProd=Si.isOptionalProd=Si.isSequenceProd=void 0;var qh=Dt(),dr=hn(),wIe=wu();function BIe(t){return t instanceof dr.Alternative||t instanceof dr.Option||t instanceof dr.Repetition||t instanceof dr.RepetitionMandatory||t instanceof dr.RepetitionMandatoryWithSeparator||t instanceof dr.RepetitionWithSeparator||t instanceof dr.Terminal||t instanceof dr.Rule}Si.isSequenceProd=BIe;function $v(t,e){e===void 0&&(e=[]);var r=t instanceof dr.Option||t instanceof dr.Repetition||t instanceof dr.RepetitionWithSeparator;return r?!0:t instanceof dr.Alternation?(0,qh.some)(t.definition,function(i){return $v(i,e)}):t instanceof dr.NonTerminal&&(0,qh.contains)(e,t)?!1:t instanceof dr.AbstractProduction?(t instanceof dr.NonTerminal&&e.push(t),(0,qh.every)(t.definition,function(i){return $v(i,e)})):!1}Si.isOptionalProd=$v;function QIe(t){return t instanceof dr.Alternation}Si.isBranchingProd=QIe;function bIe(t){if(t instanceof dr.NonTerminal)return"SUBRULE";if(t instanceof dr.Option)return"OPTION";if(t instanceof dr.Alternation)return"OR";if(t instanceof dr.RepetitionMandatory)return"AT_LEAST_ONE";if(t instanceof dr.RepetitionMandatoryWithSeparator)return"AT_LEAST_ONE_SEP";if(t instanceof dr.RepetitionWithSeparator)return"MANY_SEP";if(t instanceof dr.Repetition)return"MANY";if(t instanceof dr.Terminal)return"CONSUME";throw Error("non exhaustive match")}Si.getProductionDslName=bIe;var UG=function(t){yIe(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.separator="-",r.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]},r}return e.prototype.reset=function(){this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}},e.prototype.visitTerminal=function(r){var i=r.terminalType.name+this.separator+"Terminal";(0,qh.has)(this.dslMethods,i)||(this.dslMethods[i]=[]),this.dslMethods[i].push(r)},e.prototype.visitNonTerminal=function(r){var i=r.nonTerminalName+this.separator+"Terminal";(0,qh.has)(this.dslMethods,i)||(this.dslMethods[i]=[]),this.dslMethods[i].push(r)},e.prototype.visitOption=function(r){this.dslMethods.option.push(r)},e.prototype.visitRepetitionWithSeparator=function(r){this.dslMethods.repetitionWithSeparator.push(r)},e.prototype.visitRepetitionMandatory=function(r){this.dslMethods.repetitionMandatory.push(r)},e.prototype.visitRepetitionMandatoryWithSeparator=function(r){this.dslMethods.repetitionMandatoryWithSeparator.push(r)},e.prototype.visitRepetition=function(r){this.dslMethods.repetition.push(r)},e.prototype.visitAlternation=function(r){this.dslMethods.alternation.push(r)},e}(wIe.GAstVisitor);Si.DslMethodsCollectorVisitor=UG;var yI=new UG;function vIe(t){yI.reset(),t.accept(yI);var e=yI.dslMethods;return yI.reset(),e}Si.collectMethods=vIe});var tS=E(co=>{"use strict";Object.defineProperty(co,"__esModule",{value:!0});co.firstForTerminal=co.firstForBranching=co.firstForSequence=co.first=void 0;var wI=Dt(),HG=hn(),eS=Jh();function BI(t){if(t instanceof HG.NonTerminal)return BI(t.referencedRule);if(t instanceof HG.Terminal)return YG(t);if((0,eS.isSequenceProd)(t))return GG(t);if((0,eS.isBranchingProd)(t))return jG(t);throw Error("non exhaustive match")}co.first=BI;function GG(t){for(var e=[],r=t.definition,i=0,n=r.length>i,s,o=!0;n&&o;)s=r[i],o=(0,eS.isOptionalProd)(s),e=e.concat(BI(s)),i=i+1,n=r.length>i;return(0,wI.uniq)(e)}co.firstForSequence=GG;function jG(t){var e=(0,wI.map)(t.definition,function(r){return BI(r)});return(0,wI.uniq)((0,wI.flatten)(e))}co.firstForBranching=jG;function YG(t){return[t.terminalType]}co.firstForTerminal=YG});var rS=E(QI=>{"use strict";Object.defineProperty(QI,"__esModule",{value:!0});QI.IN=void 0;QI.IN="_~IN~_"});var VG=E(es=>{"use strict";var SIe=es&&es.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(es,"__esModule",{value:!0});es.buildInProdFollowPrefix=es.buildBetweenProdsFollowPrefix=es.computeAllProdsFollows=es.ResyncFollowsWalker=void 0;var xIe=EI(),kIe=tS(),qG=Dt(),JG=rS(),PIe=hn(),zG=function(t){SIe(e,t);function e(r){var i=t.call(this)||this;return i.topProd=r,i.follows={},i}return e.prototype.startWalking=function(){return this.walk(this.topProd),this.follows},e.prototype.walkTerminal=function(r,i,n){},e.prototype.walkProdRef=function(r,i,n){var s=WG(r.referencedRule,r.idx)+this.topProd.name,o=i.concat(n),a=new PIe.Alternative({definition:o}),l=(0,kIe.first)(a);this.follows[s]=l},e}(xIe.RestWalker);es.ResyncFollowsWalker=zG;function DIe(t){var e={};return(0,qG.forEach)(t,function(r){var i=new zG(r).startWalking();(0,qG.assign)(e,i)}),e}es.computeAllProdsFollows=DIe;function WG(t,e){return t.name+e+JG.IN}es.buildBetweenProdsFollowPrefix=WG;function RIe(t){var e=t.terminalType.name;return e+t.idx+JG.IN}es.buildInProdFollowPrefix=RIe});var Wh=E(aa=>{"use strict";Object.defineProperty(aa,"__esModule",{value:!0});aa.defaultGrammarValidatorErrorProvider=aa.defaultGrammarResolverErrorProvider=aa.defaultParserErrorProvider=void 0;var Bu=nA(),FIe=Dt(),Rs=Dt(),iS=hn(),_G=Jh();aa.defaultParserErrorProvider={buildMismatchTokenMessage:function(t){var e=t.expected,r=t.actual,i=t.previous,n=t.ruleName,s=(0,Bu.hasTokenLabel)(e),o=s?"--> "+(0,Bu.tokenLabel)(e)+" <--":"token of type --> "+e.name+" <--",a="Expecting "+o+" but found --> '"+r.image+"' <--";return a},buildNotAllInputParsedMessage:function(t){var e=t.firstRedundant,r=t.ruleName;return"Redundant input, expecting EOF but found: "+e.image},buildNoViableAltMessage:function(t){var e=t.expectedPathsPerAlt,r=t.actual,i=t.previous,n=t.customUserDescription,s=t.ruleName,o="Expecting: ",a=(0,Rs.first)(r).image,l=` +but found: '`+a+"'";if(n)return o+n+l;var c=(0,Rs.reduce)(e,function(h,p){return h.concat(p)},[]),u=(0,Rs.map)(c,function(h){return"["+(0,Rs.map)(h,function(p){return(0,Bu.tokenLabel)(p)}).join(", ")+"]"}),g=(0,Rs.map)(u,function(h,p){return" "+(p+1)+". "+h}),f=`one of these possible Token sequences: +`+g.join(` +`);return o+f+l},buildEarlyExitMessage:function(t){var e=t.expectedIterationPaths,r=t.actual,i=t.customUserDescription,n=t.ruleName,s="Expecting: ",o=(0,Rs.first)(r).image,a=` +but found: '`+o+"'";if(i)return s+i+a;var l=(0,Rs.map)(e,function(u){return"["+(0,Rs.map)(u,function(g){return(0,Bu.tokenLabel)(g)}).join(",")+"]"}),c=`expecting at least one iteration which starts with one of these possible Token sequences:: + `+("<"+l.join(" ,")+">");return s+c+a}};Object.freeze(aa.defaultParserErrorProvider);aa.defaultGrammarResolverErrorProvider={buildRuleNotFoundError:function(t,e){var r="Invalid grammar, reference to a rule which is not defined: ->"+e.nonTerminalName+`<- +inside top level rule: ->`+t.name+"<-";return r}};aa.defaultGrammarValidatorErrorProvider={buildDuplicateFoundError:function(t,e){function r(u){return u instanceof iS.Terminal?u.terminalType.name:u instanceof iS.NonTerminal?u.nonTerminalName:""}var i=t.name,n=(0,Rs.first)(e),s=n.idx,o=(0,_G.getProductionDslName)(n),a=r(n),l=s>0,c="->"+o+(l?s:"")+"<- "+(a?"with argument: ->"+a+"<-":"")+` + appears more than once (`+e.length+" times) in the top level rule: ->"+i+`<-. + For further details see: https://chevrotain.io/docs/FAQ.html#NUMERICAL_SUFFIXES + `;return c=c.replace(/[ \t]+/g," "),c=c.replace(/\s\s+/g,` +`),c},buildNamespaceConflictError:function(t){var e=`Namespace conflict found in grammar. +`+("The grammar has both a Terminal(Token) and a Non-Terminal(Rule) named: <"+t.name+`>. +`)+`To resolve this make sure each Terminal and Non-Terminal names are unique +This is easy to accomplish by using the convention that Terminal names start with an uppercase letter +and Non-Terminal names start with a lower case letter.`;return e},buildAlternationPrefixAmbiguityError:function(t){var e=(0,Rs.map)(t.prefixPath,function(n){return(0,Bu.tokenLabel)(n)}).join(", "),r=t.alternation.idx===0?"":t.alternation.idx,i="Ambiguous alternatives: <"+t.ambiguityIndices.join(" ,")+`> due to common lookahead prefix +`+("in inside <"+t.topLevelRule.name+`> Rule, +`)+("<"+e+`> may appears as a prefix path in all these alternatives. +`)+`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#COMMON_PREFIX +For Further details.`;return i},buildAlternationAmbiguityError:function(t){var e=(0,Rs.map)(t.prefixPath,function(n){return(0,Bu.tokenLabel)(n)}).join(", "),r=t.alternation.idx===0?"":t.alternation.idx,i="Ambiguous Alternatives Detected: <"+t.ambiguityIndices.join(" ,")+"> in "+(" inside <"+t.topLevelRule.name+`> Rule, +`)+("<"+e+`> may appears as a prefix path in all these alternatives. +`);return i=i+`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES +For Further details.`,i},buildEmptyRepetitionError:function(t){var e=(0,_G.getProductionDslName)(t.repetition);t.repetition.idx!==0&&(e+=t.repetition.idx);var r="The repetition <"+e+"> within Rule <"+t.topLevelRule.name+`> can never consume any tokens. +This could lead to an infinite loop.`;return r},buildTokenNameError:function(t){return"deprecated"},buildEmptyAlternationError:function(t){var e="Ambiguous empty alternative: <"+(t.emptyChoiceIdx+1)+">"+(" in inside <"+t.topLevelRule.name+`> Rule. +`)+"Only the last alternative may be an empty alternative.";return e},buildTooManyAlternativesError:function(t){var e=`An Alternation cannot have more than 256 alternatives: +`+(" inside <"+t.topLevelRule.name+`> Rule. + has `+(t.alternation.definition.length+1)+" alternatives.");return e},buildLeftRecursionError:function(t){var e=t.topLevelRule.name,r=FIe.map(t.leftRecursionPath,function(s){return s.name}),i=e+" --> "+r.concat([e]).join(" --> "),n=`Left Recursion found in grammar. +`+("rule: <"+e+`> can be invoked from itself (directly or indirectly) +`)+(`without consuming any Tokens. The grammar path that causes this is: + `+i+` +`)+` To fix this refactor your grammar to remove the left recursion. +see: https://en.wikipedia.org/wiki/LL_parser#Left_Factoring.`;return n},buildInvalidRuleNameError:function(t){return"deprecated"},buildDuplicateRuleNameError:function(t){var e;t.topLevelRule instanceof iS.Rule?e=t.topLevelRule.name:e=t.topLevelRule;var r="Duplicate definition, rule: ->"+e+"<- is already defined in the grammar: ->"+t.grammarName+"<-";return r}}});var $G=E(sA=>{"use strict";var NIe=sA&&sA.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(sA,"__esModule",{value:!0});sA.GastRefResolverVisitor=sA.resolveGrammar=void 0;var LIe=Tn(),XG=Dt(),TIe=wu();function MIe(t,e){var r=new ZG(t,e);return r.resolveRefs(),r.errors}sA.resolveGrammar=MIe;var ZG=function(t){NIe(e,t);function e(r,i){var n=t.call(this)||this;return n.nameToTopRule=r,n.errMsgProvider=i,n.errors=[],n}return e.prototype.resolveRefs=function(){var r=this;(0,XG.forEach)((0,XG.values)(this.nameToTopRule),function(i){r.currTopLevel=i,i.accept(r)})},e.prototype.visitNonTerminal=function(r){var i=this.nameToTopRule[r.nonTerminalName];if(i)r.referencedRule=i;else{var n=this.errMsgProvider.buildRuleNotFoundError(this.currTopLevel,r);this.errors.push({message:n,type:LIe.ParserDefinitionErrorType.UNRESOLVED_SUBRULE_REF,ruleName:this.currTopLevel.name,unresolvedRefName:r.nonTerminalName})}},e}(TIe.GAstVisitor);sA.GastRefResolverVisitor=ZG});var Vh=E(Br=>{"use strict";var Fl=Br&&Br.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Br,"__esModule",{value:!0});Br.nextPossibleTokensAfter=Br.possiblePathsFrom=Br.NextTerminalAfterAtLeastOneSepWalker=Br.NextTerminalAfterAtLeastOneWalker=Br.NextTerminalAfterManySepWalker=Br.NextTerminalAfterManyWalker=Br.AbstractNextTerminalAfterProductionWalker=Br.NextAfterTokenWalker=Br.AbstractNextPossibleTokensWalker=void 0;var ej=EI(),xt=Dt(),OIe=tS(),It=hn(),tj=function(t){Fl(e,t);function e(r,i){var n=t.call(this)||this;return n.topProd=r,n.path=i,n.possibleTokTypes=[],n.nextProductionName="",n.nextProductionOccurrence=0,n.found=!1,n.isAtEndOfPath=!1,n}return e.prototype.startWalking=function(){if(this.found=!1,this.path.ruleStack[0]!==this.topProd.name)throw Error("The path does not start with the walker's top Rule!");return this.ruleStack=(0,xt.cloneArr)(this.path.ruleStack).reverse(),this.occurrenceStack=(0,xt.cloneArr)(this.path.occurrenceStack).reverse(),this.ruleStack.pop(),this.occurrenceStack.pop(),this.updateExpectedNext(),this.walk(this.topProd),this.possibleTokTypes},e.prototype.walk=function(r,i){i===void 0&&(i=[]),this.found||t.prototype.walk.call(this,r,i)},e.prototype.walkProdRef=function(r,i,n){if(r.referencedRule.name===this.nextProductionName&&r.idx===this.nextProductionOccurrence){var s=i.concat(n);this.updateExpectedNext(),this.walk(r.referencedRule,s)}},e.prototype.updateExpectedNext=function(){(0,xt.isEmpty)(this.ruleStack)?(this.nextProductionName="",this.nextProductionOccurrence=0,this.isAtEndOfPath=!0):(this.nextProductionName=this.ruleStack.pop(),this.nextProductionOccurrence=this.occurrenceStack.pop())},e}(ej.RestWalker);Br.AbstractNextPossibleTokensWalker=tj;var KIe=function(t){Fl(e,t);function e(r,i){var n=t.call(this,r,i)||this;return n.path=i,n.nextTerminalName="",n.nextTerminalOccurrence=0,n.nextTerminalName=n.path.lastTok.name,n.nextTerminalOccurrence=n.path.lastTokOccurrence,n}return e.prototype.walkTerminal=function(r,i,n){if(this.isAtEndOfPath&&r.terminalType.name===this.nextTerminalName&&r.idx===this.nextTerminalOccurrence&&!this.found){var s=i.concat(n),o=new It.Alternative({definition:s});this.possibleTokTypes=(0,OIe.first)(o),this.found=!0}},e}(tj);Br.NextAfterTokenWalker=KIe;var zh=function(t){Fl(e,t);function e(r,i){var n=t.call(this)||this;return n.topRule=r,n.occurrence=i,n.result={token:void 0,occurrence:void 0,isEndOfRule:void 0},n}return e.prototype.startWalking=function(){return this.walk(this.topRule),this.result},e}(ej.RestWalker);Br.AbstractNextTerminalAfterProductionWalker=zh;var UIe=function(t){Fl(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.walkMany=function(r,i,n){if(r.idx===this.occurrence){var s=(0,xt.first)(i.concat(n));this.result.isEndOfRule=s===void 0,s instanceof It.Terminal&&(this.result.token=s.terminalType,this.result.occurrence=s.idx)}else t.prototype.walkMany.call(this,r,i,n)},e}(zh);Br.NextTerminalAfterManyWalker=UIe;var HIe=function(t){Fl(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.walkManySep=function(r,i,n){if(r.idx===this.occurrence){var s=(0,xt.first)(i.concat(n));this.result.isEndOfRule=s===void 0,s instanceof It.Terminal&&(this.result.token=s.terminalType,this.result.occurrence=s.idx)}else t.prototype.walkManySep.call(this,r,i,n)},e}(zh);Br.NextTerminalAfterManySepWalker=HIe;var GIe=function(t){Fl(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.walkAtLeastOne=function(r,i,n){if(r.idx===this.occurrence){var s=(0,xt.first)(i.concat(n));this.result.isEndOfRule=s===void 0,s instanceof It.Terminal&&(this.result.token=s.terminalType,this.result.occurrence=s.idx)}else t.prototype.walkAtLeastOne.call(this,r,i,n)},e}(zh);Br.NextTerminalAfterAtLeastOneWalker=GIe;var jIe=function(t){Fl(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.walkAtLeastOneSep=function(r,i,n){if(r.idx===this.occurrence){var s=(0,xt.first)(i.concat(n));this.result.isEndOfRule=s===void 0,s instanceof It.Terminal&&(this.result.token=s.terminalType,this.result.occurrence=s.idx)}else t.prototype.walkAtLeastOneSep.call(this,r,i,n)},e}(zh);Br.NextTerminalAfterAtLeastOneSepWalker=jIe;function rj(t,e,r){r===void 0&&(r=[]),r=(0,xt.cloneArr)(r);var i=[],n=0;function s(c){return c.concat((0,xt.drop)(t,n+1))}function o(c){var u=rj(s(c),e,r);return i.concat(u)}for(;r.length=0;W--){var X=I.definition[W],F={idx:p,def:X.definition.concat((0,xt.drop)(h)),ruleStack:d,occurrenceStack:m};g.push(F),g.push(o)}else if(I instanceof It.Alternative)g.push({idx:p,def:I.definition.concat((0,xt.drop)(h)),ruleStack:d,occurrenceStack:m});else if(I instanceof It.Rule)g.push(YIe(I,p,d,m));else throw Error("non exhaustive match")}}return u}Br.nextPossibleTokensAfter=qIe;function YIe(t,e,r,i){var n=(0,xt.cloneArr)(r);n.push(t.name);var s=(0,xt.cloneArr)(i);return s.push(1),{idx:e,def:t.definition,ruleStack:n,occurrenceStack:s}}});var _h=E(Gt=>{"use strict";var ij=Gt&&Gt.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Gt,"__esModule",{value:!0});Gt.areTokenCategoriesNotUsed=Gt.isStrictPrefixOfPath=Gt.containsPath=Gt.getLookaheadPathsForOptionalProd=Gt.getLookaheadPathsForOr=Gt.lookAheadSequenceFromAlternatives=Gt.buildSingleAlternativeLookaheadFunction=Gt.buildAlternativesLookAheadFunc=Gt.buildLookaheadFuncForOptionalProd=Gt.buildLookaheadFuncForOr=Gt.getProdType=Gt.PROD_TYPE=void 0;var _t=Dt(),nj=Vh(),JIe=EI(),bI=yu(),oA=hn(),WIe=wu(),zr;(function(t){t[t.OPTION=0]="OPTION",t[t.REPETITION=1]="REPETITION",t[t.REPETITION_MANDATORY=2]="REPETITION_MANDATORY",t[t.REPETITION_MANDATORY_WITH_SEPARATOR=3]="REPETITION_MANDATORY_WITH_SEPARATOR",t[t.REPETITION_WITH_SEPARATOR=4]="REPETITION_WITH_SEPARATOR",t[t.ALTERNATION=5]="ALTERNATION"})(zr=Gt.PROD_TYPE||(Gt.PROD_TYPE={}));function zIe(t){if(t instanceof oA.Option)return zr.OPTION;if(t instanceof oA.Repetition)return zr.REPETITION;if(t instanceof oA.RepetitionMandatory)return zr.REPETITION_MANDATORY;if(t instanceof oA.RepetitionMandatoryWithSeparator)return zr.REPETITION_MANDATORY_WITH_SEPARATOR;if(t instanceof oA.RepetitionWithSeparator)return zr.REPETITION_WITH_SEPARATOR;if(t instanceof oA.Alternation)return zr.ALTERNATION;throw Error("non exhaustive match")}Gt.getProdType=zIe;function VIe(t,e,r,i,n,s){var o=sj(t,e,r),a=nS(o)?bI.tokenStructuredMatcherNoCategories:bI.tokenStructuredMatcher;return s(o,i,a,n)}Gt.buildLookaheadFuncForOr=VIe;function _Ie(t,e,r,i,n,s){var o=oj(t,e,n,r),a=nS(o)?bI.tokenStructuredMatcherNoCategories:bI.tokenStructuredMatcher;return s(o[0],a,i)}Gt.buildLookaheadFuncForOptionalProd=_Ie;function XIe(t,e,r,i){var n=t.length,s=(0,_t.every)(t,function(l){return(0,_t.every)(l,function(c){return c.length===1})});if(e)return function(l){for(var c=(0,_t.map)(l,function(b){return b.GATE}),u=0;u{"use strict";var aS=Mt&&Mt.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Mt,"__esModule",{value:!0});Mt.checkPrefixAlternativesAmbiguities=Mt.validateSomeNonEmptyLookaheadPath=Mt.validateTooManyAlts=Mt.RepetionCollector=Mt.validateAmbiguousAlternationAlternatives=Mt.validateEmptyOrAlternative=Mt.getFirstNoneTerminal=Mt.validateNoLeftRecursion=Mt.validateRuleIsOverridden=Mt.validateRuleDoesNotAlreadyExist=Mt.OccurrenceValidationCollector=Mt.identifyProductionForDuplicates=Mt.validateGrammar=void 0;var jt=Dt(),Cr=Dt(),uo=Tn(),AS=Jh(),Qu=_h(),rye=Vh(),Fs=hn(),lS=wu();function sye(t,e,r,i,n){var s=jt.map(t,function(h){return iye(h,i)}),o=jt.map(t,function(h){return cS(h,h,i)}),a=[],l=[],c=[];(0,Cr.every)(o,Cr.isEmpty)&&(a=(0,Cr.map)(t,function(h){return uj(h,i)}),l=(0,Cr.map)(t,function(h){return gj(h,e,i)}),c=hj(t,e,i));var u=nye(t,r,i),g=(0,Cr.map)(t,function(h){return fj(h,i)}),f=(0,Cr.map)(t,function(h){return cj(h,t,n,i)});return jt.flatten(s.concat(c,o,a,l,u,g,f))}Mt.validateGrammar=sye;function iye(t,e){var r=new Cj;t.accept(r);var i=r.allProductions,n=jt.groupBy(i,pj),s=jt.pick(n,function(a){return a.length>1}),o=jt.map(jt.values(s),function(a){var l=jt.first(a),c=e.buildDuplicateFoundError(t,a),u=(0,AS.getProductionDslName)(l),g={message:c,type:uo.ParserDefinitionErrorType.DUPLICATE_PRODUCTIONS,ruleName:t.name,dslName:u,occurrence:l.idx},f=dj(l);return f&&(g.parameter=f),g});return o}function pj(t){return(0,AS.getProductionDslName)(t)+"_#_"+t.idx+"_#_"+dj(t)}Mt.identifyProductionForDuplicates=pj;function dj(t){return t instanceof Fs.Terminal?t.terminalType.name:t instanceof Fs.NonTerminal?t.nonTerminalName:""}var Cj=function(t){aS(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.allProductions=[],r}return e.prototype.visitNonTerminal=function(r){this.allProductions.push(r)},e.prototype.visitOption=function(r){this.allProductions.push(r)},e.prototype.visitRepetitionWithSeparator=function(r){this.allProductions.push(r)},e.prototype.visitRepetitionMandatory=function(r){this.allProductions.push(r)},e.prototype.visitRepetitionMandatoryWithSeparator=function(r){this.allProductions.push(r)},e.prototype.visitRepetition=function(r){this.allProductions.push(r)},e.prototype.visitAlternation=function(r){this.allProductions.push(r)},e.prototype.visitTerminal=function(r){this.allProductions.push(r)},e}(lS.GAstVisitor);Mt.OccurrenceValidationCollector=Cj;function cj(t,e,r,i){var n=[],s=(0,Cr.reduce)(e,function(a,l){return l.name===t.name?a+1:a},0);if(s>1){var o=i.buildDuplicateRuleNameError({topLevelRule:t,grammarName:r});n.push({message:o,type:uo.ParserDefinitionErrorType.DUPLICATE_RULE_NAME,ruleName:t.name})}return n}Mt.validateRuleDoesNotAlreadyExist=cj;function oye(t,e,r){var i=[],n;return jt.contains(e,t)||(n="Invalid rule override, rule: ->"+t+"<- cannot be overridden in the grammar: ->"+r+"<-as it is not defined in any of the super grammars ",i.push({message:n,type:uo.ParserDefinitionErrorType.INVALID_RULE_OVERRIDE,ruleName:t})),i}Mt.validateRuleIsOverridden=oye;function cS(t,e,r,i){i===void 0&&(i=[]);var n=[],s=Xh(e.definition);if(jt.isEmpty(s))return[];var o=t.name,a=jt.contains(s,t);a&&n.push({message:r.buildLeftRecursionError({topLevelRule:t,leftRecursionPath:i}),type:uo.ParserDefinitionErrorType.LEFT_RECURSION,ruleName:o});var l=jt.difference(s,i.concat([t])),c=jt.map(l,function(u){var g=jt.cloneArr(i);return g.push(u),cS(t,u,r,g)});return n.concat(jt.flatten(c))}Mt.validateNoLeftRecursion=cS;function Xh(t){var e=[];if(jt.isEmpty(t))return e;var r=jt.first(t);if(r instanceof Fs.NonTerminal)e.push(r.referencedRule);else if(r instanceof Fs.Alternative||r instanceof Fs.Option||r instanceof Fs.RepetitionMandatory||r instanceof Fs.RepetitionMandatoryWithSeparator||r instanceof Fs.RepetitionWithSeparator||r instanceof Fs.Repetition)e=e.concat(Xh(r.definition));else if(r instanceof Fs.Alternation)e=jt.flatten(jt.map(r.definition,function(o){return Xh(o.definition)}));else if(!(r instanceof Fs.Terminal))throw Error("non exhaustive match");var i=(0,AS.isOptionalProd)(r),n=t.length>1;if(i&&n){var s=jt.drop(t);return e.concat(Xh(s))}else return e}Mt.getFirstNoneTerminal=Xh;var uS=function(t){aS(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.alternations=[],r}return e.prototype.visitAlternation=function(r){this.alternations.push(r)},e}(lS.GAstVisitor);function uj(t,e){var r=new uS;t.accept(r);var i=r.alternations,n=jt.reduce(i,function(s,o){var a=jt.dropRight(o.definition),l=jt.map(a,function(c,u){var g=(0,rye.nextPossibleTokensAfter)([c],[],null,1);return jt.isEmpty(g)?{message:e.buildEmptyAlternationError({topLevelRule:t,alternation:o,emptyChoiceIdx:u}),type:uo.ParserDefinitionErrorType.NONE_LAST_EMPTY_ALT,ruleName:t.name,occurrence:o.idx,alternative:u+1}:null});return s.concat(jt.compact(l))},[]);return n}Mt.validateEmptyOrAlternative=uj;function gj(t,e,r){var i=new uS;t.accept(i);var n=i.alternations;n=(0,Cr.reject)(n,function(o){return o.ignoreAmbiguities===!0});var s=jt.reduce(n,function(o,a){var l=a.idx,c=a.maxLookahead||e,u=(0,Qu.getLookaheadPathsForOr)(l,t,c,a),g=aye(u,a,t,r),f=mj(u,a,t,r);return o.concat(g,f)},[]);return s}Mt.validateAmbiguousAlternationAlternatives=gj;var Ej=function(t){aS(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.allProductions=[],r}return e.prototype.visitRepetitionWithSeparator=function(r){this.allProductions.push(r)},e.prototype.visitRepetitionMandatory=function(r){this.allProductions.push(r)},e.prototype.visitRepetitionMandatoryWithSeparator=function(r){this.allProductions.push(r)},e.prototype.visitRepetition=function(r){this.allProductions.push(r)},e}(lS.GAstVisitor);Mt.RepetionCollector=Ej;function fj(t,e){var r=new uS;t.accept(r);var i=r.alternations,n=jt.reduce(i,function(s,o){return o.definition.length>255&&s.push({message:e.buildTooManyAlternativesError({topLevelRule:t,alternation:o}),type:uo.ParserDefinitionErrorType.TOO_MANY_ALTS,ruleName:t.name,occurrence:o.idx}),s},[]);return n}Mt.validateTooManyAlts=fj;function hj(t,e,r){var i=[];return(0,Cr.forEach)(t,function(n){var s=new Ej;n.accept(s);var o=s.allProductions;(0,Cr.forEach)(o,function(a){var l=(0,Qu.getProdType)(a),c=a.maxLookahead||e,u=a.idx,g=(0,Qu.getLookaheadPathsForOptionalProd)(u,n,l,c),f=g[0];if((0,Cr.isEmpty)((0,Cr.flatten)(f))){var h=r.buildEmptyRepetitionError({topLevelRule:n,repetition:a});i.push({message:h,type:uo.ParserDefinitionErrorType.NO_NON_EMPTY_LOOKAHEAD,ruleName:n.name})}})}),i}Mt.validateSomeNonEmptyLookaheadPath=hj;function aye(t,e,r,i){var n=[],s=(0,Cr.reduce)(t,function(a,l,c){return e.definition[c].ignoreAmbiguities===!0||(0,Cr.forEach)(l,function(u){var g=[c];(0,Cr.forEach)(t,function(f,h){c!==h&&(0,Qu.containsPath)(f,u)&&e.definition[h].ignoreAmbiguities!==!0&&g.push(h)}),g.length>1&&!(0,Qu.containsPath)(n,u)&&(n.push(u),a.push({alts:g,path:u}))}),a},[]),o=jt.map(s,function(a){var l=(0,Cr.map)(a.alts,function(u){return u+1}),c=i.buildAlternationAmbiguityError({topLevelRule:r,alternation:e,ambiguityIndices:l,prefixPath:a.path});return{message:c,type:uo.ParserDefinitionErrorType.AMBIGUOUS_ALTS,ruleName:r.name,occurrence:e.idx,alternatives:[a.alts]}});return o}function mj(t,e,r,i){var n=[],s=(0,Cr.reduce)(t,function(o,a,l){var c=(0,Cr.map)(a,function(u){return{idx:l,path:u}});return o.concat(c)},[]);return(0,Cr.forEach)(s,function(o){var a=e.definition[o.idx];if(a.ignoreAmbiguities!==!0){var l=o.idx,c=o.path,u=(0,Cr.findAll)(s,function(f){return e.definition[f.idx].ignoreAmbiguities!==!0&&f.idx{"use strict";Object.defineProperty(bu,"__esModule",{value:!0});bu.validateGrammar=bu.resolveGrammar=void 0;var fS=Dt(),Aye=$G(),lye=gS(),Ij=Wh();function cye(t){t=(0,fS.defaults)(t,{errMsgProvider:Ij.defaultGrammarResolverErrorProvider});var e={};return(0,fS.forEach)(t.rules,function(r){e[r.name]=r}),(0,Aye.resolveGrammar)(e,t.errMsgProvider)}bu.resolveGrammar=cye;function uye(t){return t=(0,fS.defaults)(t,{errMsgProvider:Ij.defaultGrammarValidatorErrorProvider}),(0,lye.validateGrammar)(t.rules,t.maxLookahead,t.tokenTypes,t.errMsgProvider,t.grammarName)}bu.validateGrammar=uye});var vu=E(dn=>{"use strict";var Zh=dn&&dn.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(dn,"__esModule",{value:!0});dn.EarlyExitException=dn.NotAllInputParsedException=dn.NoViableAltException=dn.MismatchedTokenException=dn.isRecognitionException=void 0;var gye=Dt(),wj="MismatchedTokenException",Bj="NoViableAltException",Qj="EarlyExitException",bj="NotAllInputParsedException",vj=[wj,Bj,Qj,bj];Object.freeze(vj);function fye(t){return(0,gye.contains)(vj,t.name)}dn.isRecognitionException=fye;var vI=function(t){Zh(e,t);function e(r,i){var n=this.constructor,s=t.call(this,r)||this;return s.token=i,s.resyncedTokens=[],Object.setPrototypeOf(s,n.prototype),Error.captureStackTrace&&Error.captureStackTrace(s,s.constructor),s}return e}(Error),hye=function(t){Zh(e,t);function e(r,i,n){var s=t.call(this,r,i)||this;return s.previousToken=n,s.name=wj,s}return e}(vI);dn.MismatchedTokenException=hye;var pye=function(t){Zh(e,t);function e(r,i,n){var s=t.call(this,r,i)||this;return s.previousToken=n,s.name=Bj,s}return e}(vI);dn.NoViableAltException=pye;var dye=function(t){Zh(e,t);function e(r,i){var n=t.call(this,r,i)||this;return n.name=bj,n}return e}(vI);dn.NotAllInputParsedException=dye;var Cye=function(t){Zh(e,t);function e(r,i,n){var s=t.call(this,r,i)||this;return s.previousToken=n,s.name=Qj,s}return e}(vI);dn.EarlyExitException=Cye});var pS=E(xi=>{"use strict";Object.defineProperty(xi,"__esModule",{value:!0});xi.attemptInRepetitionRecovery=xi.Recoverable=xi.InRuleRecoveryException=xi.IN_RULE_RECOVERY_EXCEPTION=xi.EOF_FOLLOW_KEY=void 0;var SI=nA(),ts=Dt(),mye=vu(),Eye=rS(),Iye=Tn();xi.EOF_FOLLOW_KEY={};xi.IN_RULE_RECOVERY_EXCEPTION="InRuleRecoveryException";function hS(t){this.name=xi.IN_RULE_RECOVERY_EXCEPTION,this.message=t}xi.InRuleRecoveryException=hS;hS.prototype=Error.prototype;var yye=function(){function t(){}return t.prototype.initRecoverable=function(e){this.firstAfterRepMap={},this.resyncFollows={},this.recoveryEnabled=(0,ts.has)(e,"recoveryEnabled")?e.recoveryEnabled:Iye.DEFAULT_PARSER_CONFIG.recoveryEnabled,this.recoveryEnabled&&(this.attemptInRepetitionRecovery=Sj)},t.prototype.getTokenToInsert=function(e){var r=(0,SI.createTokenInstance)(e,"",NaN,NaN,NaN,NaN,NaN,NaN);return r.isInsertedInRecovery=!0,r},t.prototype.canTokenTypeBeInsertedInRecovery=function(e){return!0},t.prototype.tryInRepetitionRecovery=function(e,r,i,n){for(var s=this,o=this.findReSyncTokenType(),a=this.exportLexerState(),l=[],c=!1,u=this.LA(1),g=this.LA(1),f=function(){var h=s.LA(0),p=s.errorMessageProvider.buildMismatchTokenMessage({expected:n,actual:u,previous:h,ruleName:s.getCurrRuleFullName()}),d=new mye.MismatchedTokenException(p,u,s.LA(0));d.resyncedTokens=(0,ts.dropRight)(l),s.SAVE_ERROR(d)};!c;)if(this.tokenMatcher(g,n)){f();return}else if(i.call(this)){f(),e.apply(this,r);return}else this.tokenMatcher(g,o)?c=!0:(g=this.SKIP_TOKEN(),this.addToResyncTokens(g,l));this.importLexerState(a)},t.prototype.shouldInRepetitionRecoveryBeTried=function(e,r,i){return!(i===!1||e===void 0||r===void 0||this.tokenMatcher(this.LA(1),e)||this.isBackTracking()||this.canPerformInRuleRecovery(e,this.getFollowsForInRuleRecovery(e,r)))},t.prototype.getFollowsForInRuleRecovery=function(e,r){var i=this.getCurrentGrammarPath(e,r),n=this.getNextPossibleTokenTypes(i);return n},t.prototype.tryInRuleRecovery=function(e,r){if(this.canRecoverWithSingleTokenInsertion(e,r)){var i=this.getTokenToInsert(e);return i}if(this.canRecoverWithSingleTokenDeletion(e)){var n=this.SKIP_TOKEN();return this.consumeToken(),n}throw new hS("sad sad panda")},t.prototype.canPerformInRuleRecovery=function(e,r){return this.canRecoverWithSingleTokenInsertion(e,r)||this.canRecoverWithSingleTokenDeletion(e)},t.prototype.canRecoverWithSingleTokenInsertion=function(e,r){var i=this;if(!this.canTokenTypeBeInsertedInRecovery(e)||(0,ts.isEmpty)(r))return!1;var n=this.LA(1),s=(0,ts.find)(r,function(o){return i.tokenMatcher(n,o)})!==void 0;return s},t.prototype.canRecoverWithSingleTokenDeletion=function(e){var r=this.tokenMatcher(this.LA(2),e);return r},t.prototype.isInCurrentRuleReSyncSet=function(e){var r=this.getCurrFollowKey(),i=this.getFollowSetFromFollowKey(r);return(0,ts.contains)(i,e)},t.prototype.findReSyncTokenType=function(){for(var e=this.flattenFollowSet(),r=this.LA(1),i=2;;){var n=r.tokenType;if((0,ts.contains)(e,n))return n;r=this.LA(i),i++}},t.prototype.getCurrFollowKey=function(){if(this.RULE_STACK.length===1)return xi.EOF_FOLLOW_KEY;var e=this.getLastExplicitRuleShortName(),r=this.getLastExplicitRuleOccurrenceIndex(),i=this.getPreviousExplicitRuleShortName();return{ruleName:this.shortRuleNameToFullName(e),idxInCallingRule:r,inRule:this.shortRuleNameToFullName(i)}},t.prototype.buildFullFollowKeyStack=function(){var e=this,r=this.RULE_STACK,i=this.RULE_OCCURRENCE_STACK;return(0,ts.map)(r,function(n,s){return s===0?xi.EOF_FOLLOW_KEY:{ruleName:e.shortRuleNameToFullName(n),idxInCallingRule:i[s],inRule:e.shortRuleNameToFullName(r[s-1])}})},t.prototype.flattenFollowSet=function(){var e=this,r=(0,ts.map)(this.buildFullFollowKeyStack(),function(i){return e.getFollowSetFromFollowKey(i)});return(0,ts.flatten)(r)},t.prototype.getFollowSetFromFollowKey=function(e){if(e===xi.EOF_FOLLOW_KEY)return[SI.EOF];var r=e.ruleName+e.idxInCallingRule+Eye.IN+e.inRule;return this.resyncFollows[r]},t.prototype.addToResyncTokens=function(e,r){return this.tokenMatcher(e,SI.EOF)||r.push(e),r},t.prototype.reSyncTo=function(e){for(var r=[],i=this.LA(1);this.tokenMatcher(i,e)===!1;)i=this.SKIP_TOKEN(),this.addToResyncTokens(i,r);return(0,ts.dropRight)(r)},t.prototype.attemptInRepetitionRecovery=function(e,r,i,n,s,o,a){},t.prototype.getCurrentGrammarPath=function(e,r){var i=this.getHumanReadableRuleStack(),n=(0,ts.cloneArr)(this.RULE_OCCURRENCE_STACK),s={ruleStack:i,occurrenceStack:n,lastTok:e,lastTokOccurrence:r};return s},t.prototype.getHumanReadableRuleStack=function(){var e=this;return(0,ts.map)(this.RULE_STACK,function(r){return e.shortRuleNameToFullName(r)})},t}();xi.Recoverable=yye;function Sj(t,e,r,i,n,s,o){var a=this.getKeyForAutomaticLookahead(i,n),l=this.firstAfterRepMap[a];if(l===void 0){var c=this.getCurrRuleFullName(),u=this.getGAstProductions()[c],g=new s(u,n);l=g.startWalking(),this.firstAfterRepMap[a]=l}var f=l.token,h=l.occurrence,p=l.isEndOfRule;this.RULE_STACK.length===1&&p&&f===void 0&&(f=SI.EOF,h=1),this.shouldInRepetitionRecoveryBeTried(f,h,o)&&this.tryInRepetitionRecovery(t,e,r,f)}xi.attemptInRepetitionRecovery=Sj});var xI=E(Nt=>{"use strict";Object.defineProperty(Nt,"__esModule",{value:!0});Nt.getKeyForAutomaticLookahead=Nt.AT_LEAST_ONE_SEP_IDX=Nt.MANY_SEP_IDX=Nt.AT_LEAST_ONE_IDX=Nt.MANY_IDX=Nt.OPTION_IDX=Nt.OR_IDX=Nt.BITS_FOR_ALT_IDX=Nt.BITS_FOR_RULE_IDX=Nt.BITS_FOR_OCCURRENCE_IDX=Nt.BITS_FOR_METHOD_TYPE=void 0;Nt.BITS_FOR_METHOD_TYPE=4;Nt.BITS_FOR_OCCURRENCE_IDX=8;Nt.BITS_FOR_RULE_IDX=12;Nt.BITS_FOR_ALT_IDX=8;Nt.OR_IDX=1<{"use strict";Object.defineProperty(kI,"__esModule",{value:!0});kI.LooksAhead=void 0;var Aa=_h(),Ns=Dt(),xj=Tn(),la=xI(),Nl=Jh(),Bye=function(){function t(){}return t.prototype.initLooksAhead=function(e){this.dynamicTokensEnabled=(0,Ns.has)(e,"dynamicTokensEnabled")?e.dynamicTokensEnabled:xj.DEFAULT_PARSER_CONFIG.dynamicTokensEnabled,this.maxLookahead=(0,Ns.has)(e,"maxLookahead")?e.maxLookahead:xj.DEFAULT_PARSER_CONFIG.maxLookahead,this.lookAheadFuncsCache=(0,Ns.isES2015MapSupported)()?new Map:[],(0,Ns.isES2015MapSupported)()?(this.getLaFuncFromCache=this.getLaFuncFromMap,this.setLaFuncCache=this.setLaFuncCacheUsingMap):(this.getLaFuncFromCache=this.getLaFuncFromObj,this.setLaFuncCache=this.setLaFuncUsingObj)},t.prototype.preComputeLookaheadFunctions=function(e){var r=this;(0,Ns.forEach)(e,function(i){r.TRACE_INIT(i.name+" Rule Lookahead",function(){var n=(0,Nl.collectMethods)(i),s=n.alternation,o=n.repetition,a=n.option,l=n.repetitionMandatory,c=n.repetitionMandatoryWithSeparator,u=n.repetitionWithSeparator;(0,Ns.forEach)(s,function(g){var f=g.idx===0?"":g.idx;r.TRACE_INIT(""+(0,Nl.getProductionDslName)(g)+f,function(){var h=(0,Aa.buildLookaheadFuncForOr)(g.idx,i,g.maxLookahead||r.maxLookahead,g.hasPredicates,r.dynamicTokensEnabled,r.lookAheadBuilderForAlternatives),p=(0,la.getKeyForAutomaticLookahead)(r.fullRuleNameToShort[i.name],la.OR_IDX,g.idx);r.setLaFuncCache(p,h)})}),(0,Ns.forEach)(o,function(g){r.computeLookaheadFunc(i,g.idx,la.MANY_IDX,Aa.PROD_TYPE.REPETITION,g.maxLookahead,(0,Nl.getProductionDslName)(g))}),(0,Ns.forEach)(a,function(g){r.computeLookaheadFunc(i,g.idx,la.OPTION_IDX,Aa.PROD_TYPE.OPTION,g.maxLookahead,(0,Nl.getProductionDslName)(g))}),(0,Ns.forEach)(l,function(g){r.computeLookaheadFunc(i,g.idx,la.AT_LEAST_ONE_IDX,Aa.PROD_TYPE.REPETITION_MANDATORY,g.maxLookahead,(0,Nl.getProductionDslName)(g))}),(0,Ns.forEach)(c,function(g){r.computeLookaheadFunc(i,g.idx,la.AT_LEAST_ONE_SEP_IDX,Aa.PROD_TYPE.REPETITION_MANDATORY_WITH_SEPARATOR,g.maxLookahead,(0,Nl.getProductionDslName)(g))}),(0,Ns.forEach)(u,function(g){r.computeLookaheadFunc(i,g.idx,la.MANY_SEP_IDX,Aa.PROD_TYPE.REPETITION_WITH_SEPARATOR,g.maxLookahead,(0,Nl.getProductionDslName)(g))})})})},t.prototype.computeLookaheadFunc=function(e,r,i,n,s,o){var a=this;this.TRACE_INIT(""+o+(r===0?"":r),function(){var l=(0,Aa.buildLookaheadFuncForOptionalProd)(r,e,s||a.maxLookahead,a.dynamicTokensEnabled,n,a.lookAheadBuilderForOptional),c=(0,la.getKeyForAutomaticLookahead)(a.fullRuleNameToShort[e.name],i,r);a.setLaFuncCache(c,l)})},t.prototype.lookAheadBuilderForOptional=function(e,r,i){return(0,Aa.buildSingleAlternativeLookaheadFunction)(e,r,i)},t.prototype.lookAheadBuilderForAlternatives=function(e,r,i,n){return(0,Aa.buildAlternativesLookAheadFunc)(e,r,i,n)},t.prototype.getKeyForAutomaticLookahead=function(e,r){var i=this.getLastExplicitRuleShortName();return(0,la.getKeyForAutomaticLookahead)(i,e,r)},t.prototype.getLaFuncFromCache=function(e){},t.prototype.getLaFuncFromMap=function(e){return this.lookAheadFuncsCache.get(e)},t.prototype.getLaFuncFromObj=function(e){return this.lookAheadFuncsCache[e]},t.prototype.setLaFuncCache=function(e,r){},t.prototype.setLaFuncCacheUsingMap=function(e,r){this.lookAheadFuncsCache.set(e,r)},t.prototype.setLaFuncUsingObj=function(e,r){this.lookAheadFuncsCache[e]=r},t}();kI.LooksAhead=Bye});var Pj=E(go=>{"use strict";Object.defineProperty(go,"__esModule",{value:!0});go.addNoneTerminalToCst=go.addTerminalToCst=go.setNodeLocationFull=go.setNodeLocationOnlyOffset=void 0;function Qye(t,e){isNaN(t.startOffset)===!0?(t.startOffset=e.startOffset,t.endOffset=e.endOffset):t.endOffset{"use strict";Object.defineProperty(aA,"__esModule",{value:!0});aA.defineNameProp=aA.functionName=aA.classNameFromInstance=void 0;var xye=Dt();function kye(t){return Dj(t.constructor)}aA.classNameFromInstance=kye;var Rj="name";function Dj(t){var e=t.name;return e||"anonymous"}aA.functionName=Dj;function Pye(t,e){var r=Object.getOwnPropertyDescriptor(t,Rj);return(0,xye.isUndefined)(r)||r.configurable?(Object.defineProperty(t,Rj,{enumerable:!1,configurable:!0,writable:!1,value:e}),!0):!1}aA.defineNameProp=Pye});var Mj=E(mi=>{"use strict";Object.defineProperty(mi,"__esModule",{value:!0});mi.validateRedundantMethods=mi.validateMissingCstMethods=mi.validateVisitor=mi.CstVisitorDefinitionError=mi.createBaseVisitorConstructorWithDefaults=mi.createBaseSemanticVisitorConstructor=mi.defaultVisit=void 0;var rs=Dt(),$h=dS();function Fj(t,e){for(var r=(0,rs.keys)(t),i=r.length,n=0;n: + `+(""+s.join(` + +`).replace(/\n/g,` + `)))}}};return r.prototype=i,r.prototype.constructor=r,r._RULE_NAMES=e,r}mi.createBaseSemanticVisitorConstructor=Dye;function Rye(t,e,r){var i=function(){};(0,$h.defineNameProp)(i,t+"BaseSemanticsWithDefaults");var n=Object.create(r.prototype);return(0,rs.forEach)(e,function(s){n[s]=Fj}),i.prototype=n,i.prototype.constructor=i,i}mi.createBaseVisitorConstructorWithDefaults=Rye;var CS;(function(t){t[t.REDUNDANT_METHOD=0]="REDUNDANT_METHOD",t[t.MISSING_METHOD=1]="MISSING_METHOD"})(CS=mi.CstVisitorDefinitionError||(mi.CstVisitorDefinitionError={}));function Nj(t,e){var r=Lj(t,e),i=Tj(t,e);return r.concat(i)}mi.validateVisitor=Nj;function Lj(t,e){var r=(0,rs.map)(e,function(i){if(!(0,rs.isFunction)(t[i]))return{msg:"Missing visitor method: <"+i+"> on "+(0,$h.functionName)(t.constructor)+" CST Visitor.",type:CS.MISSING_METHOD,methodName:i}});return(0,rs.compact)(r)}mi.validateMissingCstMethods=Lj;var Fye=["constructor","visit","validateVisitor"];function Tj(t,e){var r=[];for(var i in t)(0,rs.isFunction)(t[i])&&!(0,rs.contains)(Fye,i)&&!(0,rs.contains)(e,i)&&r.push({msg:"Redundant visitor method: <"+i+"> on "+(0,$h.functionName)(t.constructor)+` CST Visitor +There is no Grammar Rule corresponding to this method's name. +`,type:CS.REDUNDANT_METHOD,methodName:i});return r}mi.validateRedundantMethods=Tj});var Kj=E(PI=>{"use strict";Object.defineProperty(PI,"__esModule",{value:!0});PI.TreeBuilder=void 0;var Su=Pj(),Ur=Dt(),Oj=Mj(),Nye=Tn(),Lye=function(){function t(){}return t.prototype.initTreeBuilder=function(e){if(this.CST_STACK=[],this.outputCst=e.outputCst,this.nodeLocationTracking=(0,Ur.has)(e,"nodeLocationTracking")?e.nodeLocationTracking:Nye.DEFAULT_PARSER_CONFIG.nodeLocationTracking,!this.outputCst)this.cstInvocationStateUpdate=Ur.NOOP,this.cstFinallyStateUpdate=Ur.NOOP,this.cstPostTerminal=Ur.NOOP,this.cstPostNonTerminal=Ur.NOOP,this.cstPostRule=Ur.NOOP;else if(/full/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=Su.setNodeLocationFull,this.setNodeLocationFromNode=Su.setNodeLocationFull,this.cstPostRule=Ur.NOOP,this.setInitialNodeLocation=this.setInitialNodeLocationFullRecovery):(this.setNodeLocationFromToken=Ur.NOOP,this.setNodeLocationFromNode=Ur.NOOP,this.cstPostRule=this.cstPostRuleFull,this.setInitialNodeLocation=this.setInitialNodeLocationFullRegular);else if(/onlyOffset/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=Su.setNodeLocationOnlyOffset,this.setNodeLocationFromNode=Su.setNodeLocationOnlyOffset,this.cstPostRule=Ur.NOOP,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRecovery):(this.setNodeLocationFromToken=Ur.NOOP,this.setNodeLocationFromNode=Ur.NOOP,this.cstPostRule=this.cstPostRuleOnlyOffset,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRegular);else if(/none/i.test(this.nodeLocationTracking))this.setNodeLocationFromToken=Ur.NOOP,this.setNodeLocationFromNode=Ur.NOOP,this.cstPostRule=Ur.NOOP,this.setInitialNodeLocation=Ur.NOOP;else throw Error('Invalid config option: "'+e.nodeLocationTracking+'"')},t.prototype.setInitialNodeLocationOnlyOffsetRecovery=function(e){e.location={startOffset:NaN,endOffset:NaN}},t.prototype.setInitialNodeLocationOnlyOffsetRegular=function(e){e.location={startOffset:this.LA(1).startOffset,endOffset:NaN}},t.prototype.setInitialNodeLocationFullRecovery=function(e){e.location={startOffset:NaN,startLine:NaN,startColumn:NaN,endOffset:NaN,endLine:NaN,endColumn:NaN}},t.prototype.setInitialNodeLocationFullRegular=function(e){var r=this.LA(1);e.location={startOffset:r.startOffset,startLine:r.startLine,startColumn:r.startColumn,endOffset:NaN,endLine:NaN,endColumn:NaN}},t.prototype.cstInvocationStateUpdate=function(e,r){var i={name:e,children:{}};this.setInitialNodeLocation(i),this.CST_STACK.push(i)},t.prototype.cstFinallyStateUpdate=function(){this.CST_STACK.pop()},t.prototype.cstPostRuleFull=function(e){var r=this.LA(0),i=e.location;i.startOffset<=r.startOffset?(i.endOffset=r.endOffset,i.endLine=r.endLine,i.endColumn=r.endColumn):(i.startOffset=NaN,i.startLine=NaN,i.startColumn=NaN)},t.prototype.cstPostRuleOnlyOffset=function(e){var r=this.LA(0),i=e.location;i.startOffset<=r.startOffset?i.endOffset=r.endOffset:i.startOffset=NaN},t.prototype.cstPostTerminal=function(e,r){var i=this.CST_STACK[this.CST_STACK.length-1];(0,Su.addTerminalToCst)(i,r,e),this.setNodeLocationFromToken(i.location,r)},t.prototype.cstPostNonTerminal=function(e,r){var i=this.CST_STACK[this.CST_STACK.length-1];(0,Su.addNoneTerminalToCst)(i,r,e),this.setNodeLocationFromNode(i.location,e.location)},t.prototype.getBaseCstVisitorConstructor=function(){if((0,Ur.isUndefined)(this.baseCstVisitorConstructor)){var e=(0,Oj.createBaseSemanticVisitorConstructor)(this.className,(0,Ur.keys)(this.gastProductionsCache));return this.baseCstVisitorConstructor=e,e}return this.baseCstVisitorConstructor},t.prototype.getBaseCstVisitorConstructorWithDefaults=function(){if((0,Ur.isUndefined)(this.baseCstVisitorWithDefaultsConstructor)){var e=(0,Oj.createBaseVisitorConstructorWithDefaults)(this.className,(0,Ur.keys)(this.gastProductionsCache),this.getBaseCstVisitorConstructor());return this.baseCstVisitorWithDefaultsConstructor=e,e}return this.baseCstVisitorWithDefaultsConstructor},t.prototype.getLastExplicitRuleShortName=function(){var e=this.RULE_STACK;return e[e.length-1]},t.prototype.getPreviousExplicitRuleShortName=function(){var e=this.RULE_STACK;return e[e.length-2]},t.prototype.getLastExplicitRuleOccurrenceIndex=function(){var e=this.RULE_OCCURRENCE_STACK;return e[e.length-1]},t}();PI.TreeBuilder=Lye});var Hj=E(DI=>{"use strict";Object.defineProperty(DI,"__esModule",{value:!0});DI.LexerAdapter=void 0;var Uj=Tn(),Tye=function(){function t(){}return t.prototype.initLexerAdapter=function(){this.tokVector=[],this.tokVectorLength=0,this.currIdx=-1},Object.defineProperty(t.prototype,"input",{get:function(){return this.tokVector},set:function(e){if(this.selfAnalysisDone!==!0)throw Error("Missing invocation at the end of the Parser's constructor.");this.reset(),this.tokVector=e,this.tokVectorLength=e.length},enumerable:!1,configurable:!0}),t.prototype.SKIP_TOKEN=function(){return this.currIdx<=this.tokVector.length-2?(this.consumeToken(),this.LA(1)):Uj.END_OF_FILE},t.prototype.LA=function(e){var r=this.currIdx+e;return r<0||this.tokVectorLength<=r?Uj.END_OF_FILE:this.tokVector[r]},t.prototype.consumeToken=function(){this.currIdx++},t.prototype.exportLexerState=function(){return this.currIdx},t.prototype.importLexerState=function(e){this.currIdx=e},t.prototype.resetLexerState=function(){this.currIdx=-1},t.prototype.moveToTerminatedState=function(){this.currIdx=this.tokVector.length-1},t.prototype.getLexerPosition=function(){return this.exportLexerState()},t}();DI.LexerAdapter=Tye});var jj=E(RI=>{"use strict";Object.defineProperty(RI,"__esModule",{value:!0});RI.RecognizerApi=void 0;var Gj=Dt(),Mye=vu(),mS=Tn(),Oye=Wh(),Kye=gS(),Uye=hn(),Hye=function(){function t(){}return t.prototype.ACTION=function(e){return e.call(this)},t.prototype.consume=function(e,r,i){return this.consumeInternal(r,e,i)},t.prototype.subrule=function(e,r,i){return this.subruleInternal(r,e,i)},t.prototype.option=function(e,r){return this.optionInternal(r,e)},t.prototype.or=function(e,r){return this.orInternal(r,e)},t.prototype.many=function(e,r){return this.manyInternal(e,r)},t.prototype.atLeastOne=function(e,r){return this.atLeastOneInternal(e,r)},t.prototype.CONSUME=function(e,r){return this.consumeInternal(e,0,r)},t.prototype.CONSUME1=function(e,r){return this.consumeInternal(e,1,r)},t.prototype.CONSUME2=function(e,r){return this.consumeInternal(e,2,r)},t.prototype.CONSUME3=function(e,r){return this.consumeInternal(e,3,r)},t.prototype.CONSUME4=function(e,r){return this.consumeInternal(e,4,r)},t.prototype.CONSUME5=function(e,r){return this.consumeInternal(e,5,r)},t.prototype.CONSUME6=function(e,r){return this.consumeInternal(e,6,r)},t.prototype.CONSUME7=function(e,r){return this.consumeInternal(e,7,r)},t.prototype.CONSUME8=function(e,r){return this.consumeInternal(e,8,r)},t.prototype.CONSUME9=function(e,r){return this.consumeInternal(e,9,r)},t.prototype.SUBRULE=function(e,r){return this.subruleInternal(e,0,r)},t.prototype.SUBRULE1=function(e,r){return this.subruleInternal(e,1,r)},t.prototype.SUBRULE2=function(e,r){return this.subruleInternal(e,2,r)},t.prototype.SUBRULE3=function(e,r){return this.subruleInternal(e,3,r)},t.prototype.SUBRULE4=function(e,r){return this.subruleInternal(e,4,r)},t.prototype.SUBRULE5=function(e,r){return this.subruleInternal(e,5,r)},t.prototype.SUBRULE6=function(e,r){return this.subruleInternal(e,6,r)},t.prototype.SUBRULE7=function(e,r){return this.subruleInternal(e,7,r)},t.prototype.SUBRULE8=function(e,r){return this.subruleInternal(e,8,r)},t.prototype.SUBRULE9=function(e,r){return this.subruleInternal(e,9,r)},t.prototype.OPTION=function(e){return this.optionInternal(e,0)},t.prototype.OPTION1=function(e){return this.optionInternal(e,1)},t.prototype.OPTION2=function(e){return this.optionInternal(e,2)},t.prototype.OPTION3=function(e){return this.optionInternal(e,3)},t.prototype.OPTION4=function(e){return this.optionInternal(e,4)},t.prototype.OPTION5=function(e){return this.optionInternal(e,5)},t.prototype.OPTION6=function(e){return this.optionInternal(e,6)},t.prototype.OPTION7=function(e){return this.optionInternal(e,7)},t.prototype.OPTION8=function(e){return this.optionInternal(e,8)},t.prototype.OPTION9=function(e){return this.optionInternal(e,9)},t.prototype.OR=function(e){return this.orInternal(e,0)},t.prototype.OR1=function(e){return this.orInternal(e,1)},t.prototype.OR2=function(e){return this.orInternal(e,2)},t.prototype.OR3=function(e){return this.orInternal(e,3)},t.prototype.OR4=function(e){return this.orInternal(e,4)},t.prototype.OR5=function(e){return this.orInternal(e,5)},t.prototype.OR6=function(e){return this.orInternal(e,6)},t.prototype.OR7=function(e){return this.orInternal(e,7)},t.prototype.OR8=function(e){return this.orInternal(e,8)},t.prototype.OR9=function(e){return this.orInternal(e,9)},t.prototype.MANY=function(e){this.manyInternal(0,e)},t.prototype.MANY1=function(e){this.manyInternal(1,e)},t.prototype.MANY2=function(e){this.manyInternal(2,e)},t.prototype.MANY3=function(e){this.manyInternal(3,e)},t.prototype.MANY4=function(e){this.manyInternal(4,e)},t.prototype.MANY5=function(e){this.manyInternal(5,e)},t.prototype.MANY6=function(e){this.manyInternal(6,e)},t.prototype.MANY7=function(e){this.manyInternal(7,e)},t.prototype.MANY8=function(e){this.manyInternal(8,e)},t.prototype.MANY9=function(e){this.manyInternal(9,e)},t.prototype.MANY_SEP=function(e){this.manySepFirstInternal(0,e)},t.prototype.MANY_SEP1=function(e){this.manySepFirstInternal(1,e)},t.prototype.MANY_SEP2=function(e){this.manySepFirstInternal(2,e)},t.prototype.MANY_SEP3=function(e){this.manySepFirstInternal(3,e)},t.prototype.MANY_SEP4=function(e){this.manySepFirstInternal(4,e)},t.prototype.MANY_SEP5=function(e){this.manySepFirstInternal(5,e)},t.prototype.MANY_SEP6=function(e){this.manySepFirstInternal(6,e)},t.prototype.MANY_SEP7=function(e){this.manySepFirstInternal(7,e)},t.prototype.MANY_SEP8=function(e){this.manySepFirstInternal(8,e)},t.prototype.MANY_SEP9=function(e){this.manySepFirstInternal(9,e)},t.prototype.AT_LEAST_ONE=function(e){this.atLeastOneInternal(0,e)},t.prototype.AT_LEAST_ONE1=function(e){return this.atLeastOneInternal(1,e)},t.prototype.AT_LEAST_ONE2=function(e){this.atLeastOneInternal(2,e)},t.prototype.AT_LEAST_ONE3=function(e){this.atLeastOneInternal(3,e)},t.prototype.AT_LEAST_ONE4=function(e){this.atLeastOneInternal(4,e)},t.prototype.AT_LEAST_ONE5=function(e){this.atLeastOneInternal(5,e)},t.prototype.AT_LEAST_ONE6=function(e){this.atLeastOneInternal(6,e)},t.prototype.AT_LEAST_ONE7=function(e){this.atLeastOneInternal(7,e)},t.prototype.AT_LEAST_ONE8=function(e){this.atLeastOneInternal(8,e)},t.prototype.AT_LEAST_ONE9=function(e){this.atLeastOneInternal(9,e)},t.prototype.AT_LEAST_ONE_SEP=function(e){this.atLeastOneSepFirstInternal(0,e)},t.prototype.AT_LEAST_ONE_SEP1=function(e){this.atLeastOneSepFirstInternal(1,e)},t.prototype.AT_LEAST_ONE_SEP2=function(e){this.atLeastOneSepFirstInternal(2,e)},t.prototype.AT_LEAST_ONE_SEP3=function(e){this.atLeastOneSepFirstInternal(3,e)},t.prototype.AT_LEAST_ONE_SEP4=function(e){this.atLeastOneSepFirstInternal(4,e)},t.prototype.AT_LEAST_ONE_SEP5=function(e){this.atLeastOneSepFirstInternal(5,e)},t.prototype.AT_LEAST_ONE_SEP6=function(e){this.atLeastOneSepFirstInternal(6,e)},t.prototype.AT_LEAST_ONE_SEP7=function(e){this.atLeastOneSepFirstInternal(7,e)},t.prototype.AT_LEAST_ONE_SEP8=function(e){this.atLeastOneSepFirstInternal(8,e)},t.prototype.AT_LEAST_ONE_SEP9=function(e){this.atLeastOneSepFirstInternal(9,e)},t.prototype.RULE=function(e,r,i){if(i===void 0&&(i=mS.DEFAULT_RULE_CONFIG),(0,Gj.contains)(this.definedRulesNames,e)){var n=Oye.defaultGrammarValidatorErrorProvider.buildDuplicateRuleNameError({topLevelRule:e,grammarName:this.className}),s={message:n,type:mS.ParserDefinitionErrorType.DUPLICATE_RULE_NAME,ruleName:e};this.definitionErrors.push(s)}this.definedRulesNames.push(e);var o=this.defineRule(e,r,i);return this[e]=o,o},t.prototype.OVERRIDE_RULE=function(e,r,i){i===void 0&&(i=mS.DEFAULT_RULE_CONFIG);var n=[];n=n.concat((0,Kye.validateRuleIsOverridden)(e,this.definedRulesNames,this.className)),this.definitionErrors=this.definitionErrors.concat(n);var s=this.defineRule(e,r,i);return this[e]=s,s},t.prototype.BACKTRACK=function(e,r){return function(){this.isBackTrackingStack.push(1);var i=this.saveRecogState();try{return e.apply(this,r),!0}catch(n){if((0,Mye.isRecognitionException)(n))return!1;throw n}finally{this.reloadRecogState(i),this.isBackTrackingStack.pop()}}},t.prototype.getGAstProductions=function(){return this.gastProductionsCache},t.prototype.getSerializedGastProductions=function(){return(0,Uye.serializeGrammar)((0,Gj.values)(this.gastProductionsCache))},t}();RI.RecognizerApi=Hye});var Wj=E(FI=>{"use strict";Object.defineProperty(FI,"__esModule",{value:!0});FI.RecognizerEngine=void 0;var Er=Dt(),Mn=xI(),NI=vu(),Yj=_h(),xu=Vh(),qj=Tn(),Gye=pS(),Jj=nA(),ep=yu(),jye=dS(),Yye=function(){function t(){}return t.prototype.initRecognizerEngine=function(e,r){if(this.className=(0,jye.classNameFromInstance)(this),this.shortRuleNameToFull={},this.fullRuleNameToShort={},this.ruleShortNameIdx=256,this.tokenMatcher=ep.tokenStructuredMatcherNoCategories,this.definedRulesNames=[],this.tokensMap={},this.isBackTrackingStack=[],this.RULE_STACK=[],this.RULE_OCCURRENCE_STACK=[],this.gastProductionsCache={},(0,Er.has)(r,"serializedGrammar"))throw Error(`The Parser's configuration can no longer contain a property. + See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_6-0-0 + For Further details.`);if((0,Er.isArray)(e)){if((0,Er.isEmpty)(e))throw Error(`A Token Vocabulary cannot be empty. + Note that the first argument for the parser constructor + is no longer a Token vector (since v4.0).`);if(typeof e[0].startOffset=="number")throw Error(`The Parser constructor no longer accepts a token vector as the first argument. + See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_4-0-0 + For Further details.`)}if((0,Er.isArray)(e))this.tokensMap=(0,Er.reduce)(e,function(o,a){return o[a.name]=a,o},{});else if((0,Er.has)(e,"modes")&&(0,Er.every)((0,Er.flatten)((0,Er.values)(e.modes)),ep.isTokenType)){var i=(0,Er.flatten)((0,Er.values)(e.modes)),n=(0,Er.uniq)(i);this.tokensMap=(0,Er.reduce)(n,function(o,a){return o[a.name]=a,o},{})}else if((0,Er.isObject)(e))this.tokensMap=(0,Er.cloneObj)(e);else throw new Error(" argument must be An Array of Token constructors, A dictionary of Token constructors or an IMultiModeLexerDefinition");this.tokensMap.EOF=Jj.EOF;var s=(0,Er.every)((0,Er.values)(e),function(o){return(0,Er.isEmpty)(o.categoryMatches)});this.tokenMatcher=s?ep.tokenStructuredMatcherNoCategories:ep.tokenStructuredMatcher,(0,ep.augmentTokenTypes)((0,Er.values)(this.tokensMap))},t.prototype.defineRule=function(e,r,i){if(this.selfAnalysisDone)throw Error("Grammar rule <"+e+`> may not be defined after the 'performSelfAnalysis' method has been called' +Make sure that all grammar rule definitions are done before 'performSelfAnalysis' is called.`);var n=(0,Er.has)(i,"resyncEnabled")?i.resyncEnabled:qj.DEFAULT_RULE_CONFIG.resyncEnabled,s=(0,Er.has)(i,"recoveryValueFunc")?i.recoveryValueFunc:qj.DEFAULT_RULE_CONFIG.recoveryValueFunc,o=this.ruleShortNameIdx<r},t.prototype.orInternal=function(e,r){var i=this.getKeyForAutomaticLookahead(Mn.OR_IDX,r),n=(0,Er.isArray)(e)?e:e.DEF,s=this.getLaFuncFromCache(i),o=s.call(this,n);if(o!==void 0){var a=n[o];return a.ALT.call(this)}this.raiseNoAltException(r,e.ERR_MSG)},t.prototype.ruleFinallyStateUpdate=function(){if(this.RULE_STACK.pop(),this.RULE_OCCURRENCE_STACK.pop(),this.cstFinallyStateUpdate(),this.RULE_STACK.length===0&&this.isAtEndOfInput()===!1){var e=this.LA(1),r=this.errorMessageProvider.buildNotAllInputParsedMessage({firstRedundant:e,ruleName:this.getCurrRuleFullName()});this.SAVE_ERROR(new NI.NotAllInputParsedException(r,e))}},t.prototype.subruleInternal=function(e,r,i){var n;try{var s=i!==void 0?i.ARGS:void 0;return n=e.call(this,r,s),this.cstPostNonTerminal(n,i!==void 0&&i.LABEL!==void 0?i.LABEL:e.ruleName),n}catch(o){this.subruleInternalError(o,i,e.ruleName)}},t.prototype.subruleInternalError=function(e,r,i){throw(0,NI.isRecognitionException)(e)&&e.partialCstResult!==void 0&&(this.cstPostNonTerminal(e.partialCstResult,r!==void 0&&r.LABEL!==void 0?r.LABEL:i),delete e.partialCstResult),e},t.prototype.consumeInternal=function(e,r,i){var n;try{var s=this.LA(1);this.tokenMatcher(s,e)===!0?(this.consumeToken(),n=s):this.consumeInternalError(e,s,i)}catch(o){n=this.consumeInternalRecovery(e,r,o)}return this.cstPostTerminal(i!==void 0&&i.LABEL!==void 0?i.LABEL:e.name,n),n},t.prototype.consumeInternalError=function(e,r,i){var n,s=this.LA(0);throw i!==void 0&&i.ERR_MSG?n=i.ERR_MSG:n=this.errorMessageProvider.buildMismatchTokenMessage({expected:e,actual:r,previous:s,ruleName:this.getCurrRuleFullName()}),this.SAVE_ERROR(new NI.MismatchedTokenException(n,r,s))},t.prototype.consumeInternalRecovery=function(e,r,i){if(this.recoveryEnabled&&i.name==="MismatchedTokenException"&&!this.isBackTracking()){var n=this.getFollowsForInRuleRecovery(e,r);try{return this.tryInRuleRecovery(e,n)}catch(s){throw s.name===Gye.IN_RULE_RECOVERY_EXCEPTION?i:s}}else throw i},t.prototype.saveRecogState=function(){var e=this.errors,r=(0,Er.cloneArr)(this.RULE_STACK);return{errors:e,lexerState:this.exportLexerState(),RULE_STACK:r,CST_STACK:this.CST_STACK}},t.prototype.reloadRecogState=function(e){this.errors=e.errors,this.importLexerState(e.lexerState),this.RULE_STACK=e.RULE_STACK},t.prototype.ruleInvocationStateUpdate=function(e,r,i){this.RULE_OCCURRENCE_STACK.push(i),this.RULE_STACK.push(e),this.cstInvocationStateUpdate(r,e)},t.prototype.isBackTracking=function(){return this.isBackTrackingStack.length!==0},t.prototype.getCurrRuleFullName=function(){var e=this.getLastExplicitRuleShortName();return this.shortRuleNameToFull[e]},t.prototype.shortRuleNameToFullName=function(e){return this.shortRuleNameToFull[e]},t.prototype.isAtEndOfInput=function(){return this.tokenMatcher(this.LA(1),Jj.EOF)},t.prototype.reset=function(){this.resetLexerState(),this.isBackTrackingStack=[],this.errors=[],this.RULE_STACK=[],this.CST_STACK=[],this.RULE_OCCURRENCE_STACK=[]},t}();FI.RecognizerEngine=Yye});var Vj=E(LI=>{"use strict";Object.defineProperty(LI,"__esModule",{value:!0});LI.ErrorHandler=void 0;var ES=vu(),IS=Dt(),zj=_h(),qye=Tn(),Jye=function(){function t(){}return t.prototype.initErrorHandler=function(e){this._errors=[],this.errorMessageProvider=(0,IS.has)(e,"errorMessageProvider")?e.errorMessageProvider:qye.DEFAULT_PARSER_CONFIG.errorMessageProvider},t.prototype.SAVE_ERROR=function(e){if((0,ES.isRecognitionException)(e))return e.context={ruleStack:this.getHumanReadableRuleStack(),ruleOccurrenceStack:(0,IS.cloneArr)(this.RULE_OCCURRENCE_STACK)},this._errors.push(e),e;throw Error("Trying to save an Error which is not a RecognitionException")},Object.defineProperty(t.prototype,"errors",{get:function(){return(0,IS.cloneArr)(this._errors)},set:function(e){this._errors=e},enumerable:!1,configurable:!0}),t.prototype.raiseEarlyExitException=function(e,r,i){for(var n=this.getCurrRuleFullName(),s=this.getGAstProductions()[n],o=(0,zj.getLookaheadPathsForOptionalProd)(e,s,r,this.maxLookahead),a=o[0],l=[],c=1;c<=this.maxLookahead;c++)l.push(this.LA(c));var u=this.errorMessageProvider.buildEarlyExitMessage({expectedIterationPaths:a,actual:l,previous:this.LA(0),customUserDescription:i,ruleName:n});throw this.SAVE_ERROR(new ES.EarlyExitException(u,this.LA(1),this.LA(0)))},t.prototype.raiseNoAltException=function(e,r){for(var i=this.getCurrRuleFullName(),n=this.getGAstProductions()[i],s=(0,zj.getLookaheadPathsForOr)(e,n,this.maxLookahead),o=[],a=1;a<=this.maxLookahead;a++)o.push(this.LA(a));var l=this.LA(0),c=this.errorMessageProvider.buildNoViableAltMessage({expectedPathsPerAlt:s,actual:o,previous:l,customUserDescription:r,ruleName:this.getCurrRuleFullName()});throw this.SAVE_ERROR(new ES.NoViableAltException(c,this.LA(1),l))},t}();LI.ErrorHandler=Jye});var Zj=E(TI=>{"use strict";Object.defineProperty(TI,"__esModule",{value:!0});TI.ContentAssist=void 0;var _j=Vh(),Xj=Dt(),Wye=function(){function t(){}return t.prototype.initContentAssist=function(){},t.prototype.computeContentAssist=function(e,r){var i=this.gastProductionsCache[e];if((0,Xj.isUndefined)(i))throw Error("Rule ->"+e+"<- does not exist in this grammar.");return(0,_j.nextPossibleTokensAfter)([i],r,this.tokenMatcher,this.maxLookahead)},t.prototype.getNextPossibleTokenTypes=function(e){var r=(0,Xj.first)(e.ruleStack),i=this.getGAstProductions(),n=i[r],s=new _j.NextAfterTokenWalker(n,e).startWalking();return s},t}();TI.ContentAssist=Wye});var oY=E(MI=>{"use strict";Object.defineProperty(MI,"__esModule",{value:!0});MI.GastRecorder=void 0;var Cn=Dt(),fo=hn(),zye=Gh(),$j=yu(),eY=nA(),Vye=Tn(),_ye=xI(),OI={description:"This Object indicates the Parser is during Recording Phase"};Object.freeze(OI);var tY=!0,rY=Math.pow(2,_ye.BITS_FOR_OCCURRENCE_IDX)-1,iY=(0,eY.createToken)({name:"RECORDING_PHASE_TOKEN",pattern:zye.Lexer.NA});(0,$j.augmentTokenTypes)([iY]);var nY=(0,eY.createTokenInstance)(iY,`This IToken indicates the Parser is in Recording Phase + See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,-1,-1,-1,-1,-1,-1);Object.freeze(nY);var Xye={name:`This CSTNode indicates the Parser is in Recording Phase + See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,children:{}},$ye=function(){function t(){}return t.prototype.initGastRecorder=function(e){this.recordingProdStack=[],this.RECORDING_PHASE=!1},t.prototype.enableRecording=function(){var e=this;this.RECORDING_PHASE=!0,this.TRACE_INIT("Enable Recording",function(){for(var r=function(n){var s=n>0?n:"";e["CONSUME"+s]=function(o,a){return this.consumeInternalRecord(o,n,a)},e["SUBRULE"+s]=function(o,a){return this.subruleInternalRecord(o,n,a)},e["OPTION"+s]=function(o){return this.optionInternalRecord(o,n)},e["OR"+s]=function(o){return this.orInternalRecord(o,n)},e["MANY"+s]=function(o){this.manyInternalRecord(n,o)},e["MANY_SEP"+s]=function(o){this.manySepFirstInternalRecord(n,o)},e["AT_LEAST_ONE"+s]=function(o){this.atLeastOneInternalRecord(n,o)},e["AT_LEAST_ONE_SEP"+s]=function(o){this.atLeastOneSepFirstInternalRecord(n,o)}},i=0;i<10;i++)r(i);e.consume=function(n,s,o){return this.consumeInternalRecord(s,n,o)},e.subrule=function(n,s,o){return this.subruleInternalRecord(s,n,o)},e.option=function(n,s){return this.optionInternalRecord(s,n)},e.or=function(n,s){return this.orInternalRecord(s,n)},e.many=function(n,s){this.manyInternalRecord(n,s)},e.atLeastOne=function(n,s){this.atLeastOneInternalRecord(n,s)},e.ACTION=e.ACTION_RECORD,e.BACKTRACK=e.BACKTRACK_RECORD,e.LA=e.LA_RECORD})},t.prototype.disableRecording=function(){var e=this;this.RECORDING_PHASE=!1,this.TRACE_INIT("Deleting Recording methods",function(){for(var r=0;r<10;r++){var i=r>0?r:"";delete e["CONSUME"+i],delete e["SUBRULE"+i],delete e["OPTION"+i],delete e["OR"+i],delete e["MANY"+i],delete e["MANY_SEP"+i],delete e["AT_LEAST_ONE"+i],delete e["AT_LEAST_ONE_SEP"+i]}delete e.consume,delete e.subrule,delete e.option,delete e.or,delete e.many,delete e.atLeastOne,delete e.ACTION,delete e.BACKTRACK,delete e.LA})},t.prototype.ACTION_RECORD=function(e){},t.prototype.BACKTRACK_RECORD=function(e,r){return function(){return!0}},t.prototype.LA_RECORD=function(e){return Vye.END_OF_FILE},t.prototype.topLevelRuleRecord=function(e,r){try{var i=new fo.Rule({definition:[],name:e});return i.name=e,this.recordingProdStack.push(i),r.call(this),this.recordingProdStack.pop(),i}catch(n){if(n.KNOWN_RECORDER_ERROR!==!0)try{n.message=n.message+` + This error was thrown during the "grammar recording phase" For more info see: + https://chevrotain.io/docs/guide/internals.html#grammar-recording`}catch(s){throw n}throw n}},t.prototype.optionInternalRecord=function(e,r){return tp.call(this,fo.Option,e,r)},t.prototype.atLeastOneInternalRecord=function(e,r){tp.call(this,fo.RepetitionMandatory,r,e)},t.prototype.atLeastOneSepFirstInternalRecord=function(e,r){tp.call(this,fo.RepetitionMandatoryWithSeparator,r,e,tY)},t.prototype.manyInternalRecord=function(e,r){tp.call(this,fo.Repetition,r,e)},t.prototype.manySepFirstInternalRecord=function(e,r){tp.call(this,fo.RepetitionWithSeparator,r,e,tY)},t.prototype.orInternalRecord=function(e,r){return Zye.call(this,e,r)},t.prototype.subruleInternalRecord=function(e,r,i){if(KI(r),!e||(0,Cn.has)(e,"ruleName")===!1){var n=new Error(" argument is invalid"+(" expecting a Parser method reference but got: <"+JSON.stringify(e)+">")+(` + inside top level rule: <`+this.recordingProdStack[0].name+">"));throw n.KNOWN_RECORDER_ERROR=!0,n}var s=(0,Cn.peek)(this.recordingProdStack),o=e.ruleName,a=new fo.NonTerminal({idx:r,nonTerminalName:o,label:i==null?void 0:i.LABEL,referencedRule:void 0});return s.definition.push(a),this.outputCst?Xye:OI},t.prototype.consumeInternalRecord=function(e,r,i){if(KI(r),!(0,$j.hasShortKeyProperty)(e)){var n=new Error(" argument is invalid"+(" expecting a TokenType reference but got: <"+JSON.stringify(e)+">")+(` + inside top level rule: <`+this.recordingProdStack[0].name+">"));throw n.KNOWN_RECORDER_ERROR=!0,n}var s=(0,Cn.peek)(this.recordingProdStack),o=new fo.Terminal({idx:r,terminalType:e,label:i==null?void 0:i.LABEL});return s.definition.push(o),nY},t}();MI.GastRecorder=$ye;function tp(t,e,r,i){i===void 0&&(i=!1),KI(r);var n=(0,Cn.peek)(this.recordingProdStack),s=(0,Cn.isFunction)(e)?e:e.DEF,o=new t({definition:[],idx:r});return i&&(o.separator=e.SEP),(0,Cn.has)(e,"MAX_LOOKAHEAD")&&(o.maxLookahead=e.MAX_LOOKAHEAD),this.recordingProdStack.push(o),s.call(this),n.definition.push(o),this.recordingProdStack.pop(),OI}function Zye(t,e){var r=this;KI(e);var i=(0,Cn.peek)(this.recordingProdStack),n=(0,Cn.isArray)(t)===!1,s=n===!1?t:t.DEF,o=new fo.Alternation({definition:[],idx:e,ignoreAmbiguities:n&&t.IGNORE_AMBIGUITIES===!0});(0,Cn.has)(t,"MAX_LOOKAHEAD")&&(o.maxLookahead=t.MAX_LOOKAHEAD);var a=(0,Cn.some)(s,function(l){return(0,Cn.isFunction)(l.GATE)});return o.hasPredicates=a,i.definition.push(o),(0,Cn.forEach)(s,function(l){var c=new fo.Alternative({definition:[]});o.definition.push(c),(0,Cn.has)(l,"IGNORE_AMBIGUITIES")?c.ignoreAmbiguities=l.IGNORE_AMBIGUITIES:(0,Cn.has)(l,"GATE")&&(c.ignoreAmbiguities=!0),r.recordingProdStack.push(c),l.ALT.call(r),r.recordingProdStack.pop()}),OI}function sY(t){return t===0?"":""+t}function KI(t){if(t<0||t>rY){var e=new Error("Invalid DSL Method idx value: <"+t+`> + `+("Idx value must be a none negative value smaller than "+(rY+1)));throw e.KNOWN_RECORDER_ERROR=!0,e}}});var AY=E(UI=>{"use strict";Object.defineProperty(UI,"__esModule",{value:!0});UI.PerformanceTracer=void 0;var aY=Dt(),ewe=Tn(),twe=function(){function t(){}return t.prototype.initPerformanceTracer=function(e){if((0,aY.has)(e,"traceInitPerf")){var r=e.traceInitPerf,i=typeof r=="number";this.traceInitMaxIdent=i?r:Infinity,this.traceInitPerf=i?r>0:r}else this.traceInitMaxIdent=0,this.traceInitPerf=ewe.DEFAULT_PARSER_CONFIG.traceInitPerf;this.traceInitIndent=-1},t.prototype.TRACE_INIT=function(e,r){if(this.traceInitPerf===!0){this.traceInitIndent++;var i=new Array(this.traceInitIndent+1).join(" ");this.traceInitIndent <"+e+">");var n=(0,aY.timer)(r),s=n.time,o=n.value,a=s>10?console.warn:console.log;return this.traceInitIndent time: "+s+"ms"),this.traceInitIndent--,o}else return r()},t}();UI.PerformanceTracer=twe});var lY=E(HI=>{"use strict";Object.defineProperty(HI,"__esModule",{value:!0});HI.applyMixins=void 0;function rwe(t,e){e.forEach(function(r){var i=r.prototype;Object.getOwnPropertyNames(i).forEach(function(n){if(n!=="constructor"){var s=Object.getOwnPropertyDescriptor(i,n);s&&(s.get||s.set)?Object.defineProperty(t.prototype,n,s):t.prototype[n]=r.prototype[n]}})})}HI.applyMixins=rwe});var Tn=E(or=>{"use strict";var cY=or&&or.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(or,"__esModule",{value:!0});or.EmbeddedActionsParser=or.CstParser=or.Parser=or.EMPTY_ALT=or.ParserDefinitionErrorType=or.DEFAULT_RULE_CONFIG=or.DEFAULT_PARSER_CONFIG=or.END_OF_FILE=void 0;var Wi=Dt(),iwe=VG(),uY=nA(),gY=Wh(),fY=yj(),nwe=pS(),swe=kj(),owe=Kj(),awe=Hj(),Awe=jj(),lwe=Wj(),cwe=Vj(),uwe=Zj(),gwe=oY(),fwe=AY(),hwe=lY();or.END_OF_FILE=(0,uY.createTokenInstance)(uY.EOF,"",NaN,NaN,NaN,NaN,NaN,NaN);Object.freeze(or.END_OF_FILE);or.DEFAULT_PARSER_CONFIG=Object.freeze({recoveryEnabled:!1,maxLookahead:3,dynamicTokensEnabled:!1,outputCst:!0,errorMessageProvider:gY.defaultParserErrorProvider,nodeLocationTracking:"none",traceInitPerf:!1,skipValidations:!1});or.DEFAULT_RULE_CONFIG=Object.freeze({recoveryValueFunc:function(){},resyncEnabled:!0});var pwe;(function(t){t[t.INVALID_RULE_NAME=0]="INVALID_RULE_NAME",t[t.DUPLICATE_RULE_NAME=1]="DUPLICATE_RULE_NAME",t[t.INVALID_RULE_OVERRIDE=2]="INVALID_RULE_OVERRIDE",t[t.DUPLICATE_PRODUCTIONS=3]="DUPLICATE_PRODUCTIONS",t[t.UNRESOLVED_SUBRULE_REF=4]="UNRESOLVED_SUBRULE_REF",t[t.LEFT_RECURSION=5]="LEFT_RECURSION",t[t.NONE_LAST_EMPTY_ALT=6]="NONE_LAST_EMPTY_ALT",t[t.AMBIGUOUS_ALTS=7]="AMBIGUOUS_ALTS",t[t.CONFLICT_TOKENS_RULES_NAMESPACE=8]="CONFLICT_TOKENS_RULES_NAMESPACE",t[t.INVALID_TOKEN_NAME=9]="INVALID_TOKEN_NAME",t[t.NO_NON_EMPTY_LOOKAHEAD=10]="NO_NON_EMPTY_LOOKAHEAD",t[t.AMBIGUOUS_PREFIX_ALTS=11]="AMBIGUOUS_PREFIX_ALTS",t[t.TOO_MANY_ALTS=12]="TOO_MANY_ALTS"})(pwe=or.ParserDefinitionErrorType||(or.ParserDefinitionErrorType={}));function dwe(t){return t===void 0&&(t=void 0),function(){return t}}or.EMPTY_ALT=dwe;var GI=function(){function t(e,r){this.definitionErrors=[],this.selfAnalysisDone=!1;var i=this;if(i.initErrorHandler(r),i.initLexerAdapter(),i.initLooksAhead(r),i.initRecognizerEngine(e,r),i.initRecoverable(r),i.initTreeBuilder(r),i.initContentAssist(),i.initGastRecorder(r),i.initPerformanceTracer(r),(0,Wi.has)(r,"ignoredIssues"))throw new Error(`The IParserConfig property has been deprecated. + Please use the flag on the relevant DSL method instead. + See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#IGNORING_AMBIGUITIES + For further details.`);this.skipValidations=(0,Wi.has)(r,"skipValidations")?r.skipValidations:or.DEFAULT_PARSER_CONFIG.skipValidations}return t.performSelfAnalysis=function(e){throw Error("The **static** `performSelfAnalysis` method has been deprecated. \nUse the **instance** method with the same name instead.")},t.prototype.performSelfAnalysis=function(){var e=this;this.TRACE_INIT("performSelfAnalysis",function(){var r;e.selfAnalysisDone=!0;var i=e.className;e.TRACE_INIT("toFastProps",function(){(0,Wi.toFastProperties)(e)}),e.TRACE_INIT("Grammar Recording",function(){try{e.enableRecording(),(0,Wi.forEach)(e.definedRulesNames,function(s){var o=e[s],a=o.originalGrammarAction,l=void 0;e.TRACE_INIT(s+" Rule",function(){l=e.topLevelRuleRecord(s,a)}),e.gastProductionsCache[s]=l})}finally{e.disableRecording()}});var n=[];if(e.TRACE_INIT("Grammar Resolving",function(){n=(0,fY.resolveGrammar)({rules:(0,Wi.values)(e.gastProductionsCache)}),e.definitionErrors=e.definitionErrors.concat(n)}),e.TRACE_INIT("Grammar Validations",function(){if((0,Wi.isEmpty)(n)&&e.skipValidations===!1){var s=(0,fY.validateGrammar)({rules:(0,Wi.values)(e.gastProductionsCache),maxLookahead:e.maxLookahead,tokenTypes:(0,Wi.values)(e.tokensMap),errMsgProvider:gY.defaultGrammarValidatorErrorProvider,grammarName:i});e.definitionErrors=e.definitionErrors.concat(s)}}),(0,Wi.isEmpty)(e.definitionErrors)&&(e.recoveryEnabled&&e.TRACE_INIT("computeAllProdsFollows",function(){var s=(0,iwe.computeAllProdsFollows)((0,Wi.values)(e.gastProductionsCache));e.resyncFollows=s}),e.TRACE_INIT("ComputeLookaheadFunctions",function(){e.preComputeLookaheadFunctions((0,Wi.values)(e.gastProductionsCache))})),!t.DEFER_DEFINITION_ERRORS_HANDLING&&!(0,Wi.isEmpty)(e.definitionErrors))throw r=(0,Wi.map)(e.definitionErrors,function(s){return s.message}),new Error(`Parser Definition Errors detected: + `+r.join(` +------------------------------- +`))})},t.DEFER_DEFINITION_ERRORS_HANDLING=!1,t}();or.Parser=GI;(0,hwe.applyMixins)(GI,[nwe.Recoverable,swe.LooksAhead,owe.TreeBuilder,awe.LexerAdapter,lwe.RecognizerEngine,Awe.RecognizerApi,cwe.ErrorHandler,uwe.ContentAssist,gwe.GastRecorder,fwe.PerformanceTracer]);var Cwe=function(t){cY(e,t);function e(r,i){i===void 0&&(i=or.DEFAULT_PARSER_CONFIG);var n=this,s=(0,Wi.cloneObj)(i);return s.outputCst=!0,n=t.call(this,r,s)||this,n}return e}(GI);or.CstParser=Cwe;var mwe=function(t){cY(e,t);function e(r,i){i===void 0&&(i=or.DEFAULT_PARSER_CONFIG);var n=this,s=(0,Wi.cloneObj)(i);return s.outputCst=!1,n=t.call(this,r,s)||this,n}return e}(GI);or.EmbeddedActionsParser=mwe});var pY=E(jI=>{"use strict";Object.defineProperty(jI,"__esModule",{value:!0});jI.createSyntaxDiagramsCode=void 0;var hY=Uv();function Ewe(t,e){var r=e===void 0?{}:e,i=r.resourceBase,n=i===void 0?"https://unpkg.com/chevrotain@"+hY.VERSION+"/diagrams/":i,s=r.css,o=s===void 0?"https://unpkg.com/chevrotain@"+hY.VERSION+"/diagrams/diagrams.css":s,a=` + + + + + +`,l=` + +`,c=` + + + + +`,u=` +
+`,g=` + +`,f=` + +`;return a+l+c+u+g+f}jI.createSyntaxDiagramsCode=Ewe});var mY=E(He=>{"use strict";Object.defineProperty(He,"__esModule",{value:!0});He.Parser=He.createSyntaxDiagramsCode=He.clearCache=He.GAstVisitor=He.serializeProduction=He.serializeGrammar=He.Terminal=He.Rule=He.RepetitionWithSeparator=He.RepetitionMandatoryWithSeparator=He.RepetitionMandatory=He.Repetition=He.Option=He.NonTerminal=He.Alternative=He.Alternation=He.defaultLexerErrorProvider=He.NoViableAltException=He.NotAllInputParsedException=He.MismatchedTokenException=He.isRecognitionException=He.EarlyExitException=He.defaultParserErrorProvider=He.tokenName=He.tokenMatcher=He.tokenLabel=He.EOF=He.createTokenInstance=He.createToken=He.LexerDefinitionErrorType=He.Lexer=He.EMPTY_ALT=He.ParserDefinitionErrorType=He.EmbeddedActionsParser=He.CstParser=He.VERSION=void 0;var Iwe=Uv();Object.defineProperty(He,"VERSION",{enumerable:!0,get:function(){return Iwe.VERSION}});var YI=Tn();Object.defineProperty(He,"CstParser",{enumerable:!0,get:function(){return YI.CstParser}});Object.defineProperty(He,"EmbeddedActionsParser",{enumerable:!0,get:function(){return YI.EmbeddedActionsParser}});Object.defineProperty(He,"ParserDefinitionErrorType",{enumerable:!0,get:function(){return YI.ParserDefinitionErrorType}});Object.defineProperty(He,"EMPTY_ALT",{enumerable:!0,get:function(){return YI.EMPTY_ALT}});var dY=Gh();Object.defineProperty(He,"Lexer",{enumerable:!0,get:function(){return dY.Lexer}});Object.defineProperty(He,"LexerDefinitionErrorType",{enumerable:!0,get:function(){return dY.LexerDefinitionErrorType}});var ku=nA();Object.defineProperty(He,"createToken",{enumerable:!0,get:function(){return ku.createToken}});Object.defineProperty(He,"createTokenInstance",{enumerable:!0,get:function(){return ku.createTokenInstance}});Object.defineProperty(He,"EOF",{enumerable:!0,get:function(){return ku.EOF}});Object.defineProperty(He,"tokenLabel",{enumerable:!0,get:function(){return ku.tokenLabel}});Object.defineProperty(He,"tokenMatcher",{enumerable:!0,get:function(){return ku.tokenMatcher}});Object.defineProperty(He,"tokenName",{enumerable:!0,get:function(){return ku.tokenName}});var ywe=Wh();Object.defineProperty(He,"defaultParserErrorProvider",{enumerable:!0,get:function(){return ywe.defaultParserErrorProvider}});var rp=vu();Object.defineProperty(He,"EarlyExitException",{enumerable:!0,get:function(){return rp.EarlyExitException}});Object.defineProperty(He,"isRecognitionException",{enumerable:!0,get:function(){return rp.isRecognitionException}});Object.defineProperty(He,"MismatchedTokenException",{enumerable:!0,get:function(){return rp.MismatchedTokenException}});Object.defineProperty(He,"NotAllInputParsedException",{enumerable:!0,get:function(){return rp.NotAllInputParsedException}});Object.defineProperty(He,"NoViableAltException",{enumerable:!0,get:function(){return rp.NoViableAltException}});var wwe=_v();Object.defineProperty(He,"defaultLexerErrorProvider",{enumerable:!0,get:function(){return wwe.defaultLexerErrorProvider}});var ho=hn();Object.defineProperty(He,"Alternation",{enumerable:!0,get:function(){return ho.Alternation}});Object.defineProperty(He,"Alternative",{enumerable:!0,get:function(){return ho.Alternative}});Object.defineProperty(He,"NonTerminal",{enumerable:!0,get:function(){return ho.NonTerminal}});Object.defineProperty(He,"Option",{enumerable:!0,get:function(){return ho.Option}});Object.defineProperty(He,"Repetition",{enumerable:!0,get:function(){return ho.Repetition}});Object.defineProperty(He,"RepetitionMandatory",{enumerable:!0,get:function(){return ho.RepetitionMandatory}});Object.defineProperty(He,"RepetitionMandatoryWithSeparator",{enumerable:!0,get:function(){return ho.RepetitionMandatoryWithSeparator}});Object.defineProperty(He,"RepetitionWithSeparator",{enumerable:!0,get:function(){return ho.RepetitionWithSeparator}});Object.defineProperty(He,"Rule",{enumerable:!0,get:function(){return ho.Rule}});Object.defineProperty(He,"Terminal",{enumerable:!0,get:function(){return ho.Terminal}});var CY=hn();Object.defineProperty(He,"serializeGrammar",{enumerable:!0,get:function(){return CY.serializeGrammar}});Object.defineProperty(He,"serializeProduction",{enumerable:!0,get:function(){return CY.serializeProduction}});var Bwe=wu();Object.defineProperty(He,"GAstVisitor",{enumerable:!0,get:function(){return Bwe.GAstVisitor}});function Qwe(){console.warn(`The clearCache function was 'soft' removed from the Chevrotain API. + It performs no action other than printing this message. + Please avoid using it as it will be completely removed in the future`)}He.clearCache=Qwe;var bwe=pY();Object.defineProperty(He,"createSyntaxDiagramsCode",{enumerable:!0,get:function(){return bwe.createSyntaxDiagramsCode}});var vwe=function(){function t(){throw new Error(`The Parser class has been deprecated, use CstParser or EmbeddedActionsParser instead. +See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_7-0-0`)}return t}();He.Parser=vwe});var yY=E((Trt,EY)=>{var qI=mY(),ca=qI.createToken,IY=qI.tokenMatcher,yS=qI.Lexer,Swe=qI.EmbeddedActionsParser;EY.exports=t=>{let e=ca({name:"LogicalOperator",pattern:yS.NA}),r=ca({name:"Or",pattern:/\|/,categories:e}),i=ca({name:"Xor",pattern:/\^/,categories:e}),n=ca({name:"And",pattern:/&/,categories:e}),s=ca({name:"Not",pattern:/!/}),o=ca({name:"LParen",pattern:/\(/}),a=ca({name:"RParen",pattern:/\)/}),l=ca({name:"Query",pattern:t}),u=[ca({name:"WhiteSpace",pattern:/\s+/,group:yS.SKIPPED}),r,i,n,o,a,s,e,l],g=new yS(u);class f extends Swe{constructor(p){super(u);this.RULE("expression",()=>this.SUBRULE(this.logicalExpression)),this.RULE("logicalExpression",()=>{let m=this.SUBRULE(this.atomicExpression);return this.MANY(()=>{let I=m,B=this.CONSUME(e),b=this.SUBRULE2(this.atomicExpression);IY(B,r)?m=R=>I(R)||b(R):IY(B,i)?m=R=>!!(I(R)^b(R)):m=R=>I(R)&&b(R)}),m}),this.RULE("atomicExpression",()=>this.OR([{ALT:()=>this.SUBRULE(this.parenthesisExpression)},{ALT:()=>{let{image:d}=this.CONSUME(l);return m=>m(d)}},{ALT:()=>{this.CONSUME(s);let d=this.SUBRULE(this.atomicExpression);return m=>!d(m)}}])),this.RULE("parenthesisExpression",()=>{let d;return this.CONSUME(o),d=this.SUBRULE(this.expression),this.CONSUME(a),d}),this.performSelfAnalysis()}}return{TinylogicLexer:g,TinylogicParser:f}}});var wY=E(JI=>{var xwe=yY();JI.makeParser=(t=/[a-z]+/)=>{let{TinylogicLexer:e,TinylogicParser:r}=xwe(t),i=new r;return(n,s)=>{let o=e.tokenize(n);return i.input=o.tokens,i.expression()(s)}};JI.parse=JI.makeParser()});var QY=E((Ort,BY)=>{"use strict";BY.exports=(...t)=>[...new Set([].concat(...t))]});var wS=E((Krt,bY)=>{"use strict";var kwe=require("stream"),vY=kwe.PassThrough,Pwe=Array.prototype.slice;bY.exports=Dwe;function Dwe(){let t=[],e=!1,r=Pwe.call(arguments),i=r[r.length-1];i&&!Array.isArray(i)&&i.pipe==null?r.pop():i={};let n=i.end!==!1;i.objectMode==null&&(i.objectMode=!0),i.highWaterMark==null&&(i.highWaterMark=64*1024);let s=vY(i);function o(){for(let c=0,u=arguments.length;c0||(e=!1,a())}function f(h){function p(){h.removeListener("merge2UnpipeEnd",p),h.removeListener("end",p),g()}if(h._readableState.endEmitted)return g();h.on("merge2UnpipeEnd",p),h.on("end",p),h.pipe(s,{end:!1}),h.resume()}for(let h=0;h{"use strict";Object.defineProperty(WI,"__esModule",{value:!0});function Rwe(t){return t.reduce((e,r)=>[].concat(e,r),[])}WI.flatten=Rwe;function Fwe(t,e){let r=[[]],i=0;for(let n of t)e(n)?(i++,r[i]=[]):r[i].push(n);return r}WI.splitWhen=Fwe});var kY=E(BS=>{"use strict";Object.defineProperty(BS,"__esModule",{value:!0});function Nwe(t){return t.code==="ENOENT"}BS.isEnoentCodeError=Nwe});var DY=E(QS=>{"use strict";Object.defineProperty(QS,"__esModule",{value:!0});var PY=class{constructor(e,r){this.name=e,this.isBlockDevice=r.isBlockDevice.bind(r),this.isCharacterDevice=r.isCharacterDevice.bind(r),this.isDirectory=r.isDirectory.bind(r),this.isFIFO=r.isFIFO.bind(r),this.isFile=r.isFile.bind(r),this.isSocket=r.isSocket.bind(r),this.isSymbolicLink=r.isSymbolicLink.bind(r)}};function Lwe(t,e){return new PY(t,e)}QS.createDirentFromStats=Lwe});var RY=E(Pu=>{"use strict";Object.defineProperty(Pu,"__esModule",{value:!0});var Twe=require("path"),Mwe=2,Owe=/(\\?)([()*?[\]{|}]|^!|[!+@](?=\())/g;function Kwe(t){return t.replace(/\\/g,"/")}Pu.unixify=Kwe;function Uwe(t,e){return Twe.resolve(t,e)}Pu.makeAbsolute=Uwe;function Hwe(t){return t.replace(Owe,"\\$2")}Pu.escape=Hwe;function Gwe(t){if(t.charAt(0)==="."){let e=t.charAt(1);if(e==="/"||e==="\\")return t.slice(Mwe)}return t}Pu.removeLeadingDotSegment=Gwe});var NY=E((Yrt,FY)=>{FY.exports=function(e){if(typeof e!="string"||e==="")return!1;for(var r;r=/(\\).|([@?!+*]\(.*\))/g.exec(e);){if(r[2])return!0;e=e.slice(r.index+r[0].length)}return!1}});var TY=E((qrt,LY)=>{var jwe=NY(),Ywe={"{":"}","(":")","[":"]"},qwe=/\\(.)|(^!|\*|[\].+)]\?|\[[^\\\]]+\]|\{[^\\}]+\}|\(\?[:!=][^\\)]+\)|\([^|]+\|[^\\)]+\))/,Jwe=/\\(.)|(^!|[*?{}()[\]]|\(\?)/;LY.exports=function(e,r){if(typeof e!="string"||e==="")return!1;if(jwe(e))return!0;var i=qwe,n;for(r&&r.strict===!1&&(i=Jwe);n=i.exec(e);){if(n[2])return!0;var s=n.index+n[0].length,o=n[1],a=o?Ywe[o]:null;if(o&&a){var l=e.indexOf(a,s);l!==-1&&(s=l+1)}e=e.slice(s)}return!1}});var OY=E((Jrt,MY)=>{"use strict";var Wwe=TY(),zwe=require("path").posix.dirname,Vwe=require("os").platform()==="win32",bS="/",_we=/\\/g,Xwe=/[\{\[].*[\}\]]$/,Zwe=/(^|[^\\])([\{\[]|\([^\)]+$)/,$we=/\\([\!\*\?\|\[\]\(\)\{\}])/g;MY.exports=function(e,r){var i=Object.assign({flipBackslashes:!0},r);i.flipBackslashes&&Vwe&&e.indexOf(bS)<0&&(e=e.replace(_we,bS)),Xwe.test(e)&&(e+=bS),e+="a";do e=zwe(e);while(Wwe(e)||Zwe.test(e));return e.replace($we,"$1")}});var WY=E(Hr=>{"use strict";Object.defineProperty(Hr,"__esModule",{value:!0});var eBe=require("path"),tBe=OY(),KY=Nn(),rBe=iv(),UY="**",iBe="\\",nBe=/[*?]|^!/,sBe=/\[.*]/,oBe=/(?:^|[^!*+?@])\(.*\|.*\)/,aBe=/[!*+?@]\(.*\)/,ABe=/{.*(?:,|\.\.).*}/;function GY(t,e={}){return!HY(t,e)}Hr.isStaticPattern=GY;function HY(t,e={}){return!!(e.caseSensitiveMatch===!1||t.includes(iBe)||nBe.test(t)||sBe.test(t)||oBe.test(t)||e.extglob!==!1&&aBe.test(t)||e.braceExpansion!==!1&&ABe.test(t))}Hr.isDynamicPattern=HY;function lBe(t){return zI(t)?t.slice(1):t}Hr.convertToPositivePattern=lBe;function cBe(t){return"!"+t}Hr.convertToNegativePattern=cBe;function zI(t){return t.startsWith("!")&&t[1]!=="("}Hr.isNegativePattern=zI;function jY(t){return!zI(t)}Hr.isPositivePattern=jY;function uBe(t){return t.filter(zI)}Hr.getNegativePatterns=uBe;function gBe(t){return t.filter(jY)}Hr.getPositivePatterns=gBe;function fBe(t){return tBe(t,{flipBackslashes:!1})}Hr.getBaseDirectory=fBe;function hBe(t){return t.includes(UY)}Hr.hasGlobStar=hBe;function YY(t){return t.endsWith("/"+UY)}Hr.endsWithSlashGlobStar=YY;function pBe(t){let e=eBe.basename(t);return YY(t)||GY(e)}Hr.isAffectDepthOfReadingPattern=pBe;function dBe(t){return t.reduce((e,r)=>e.concat(qY(r)),[])}Hr.expandPatternsWithBraceExpansion=dBe;function qY(t){return KY.braces(t,{expand:!0,nodupes:!0})}Hr.expandBraceExpansion=qY;function CBe(t,e){let r=rBe.scan(t,Object.assign(Object.assign({},e),{parts:!0}));return r.parts.length===0?[t]:r.parts}Hr.getPatternParts=CBe;function JY(t,e){return KY.makeRe(t,e)}Hr.makeRe=JY;function mBe(t,e){return t.map(r=>JY(r,e))}Hr.convertPatternsToRe=mBe;function EBe(t,e){return e.some(r=>r.test(t))}Hr.matchAny=EBe});var VY=E(vS=>{"use strict";Object.defineProperty(vS,"__esModule",{value:!0});var IBe=wS();function yBe(t){let e=IBe(t);return t.forEach(r=>{r.once("error",i=>e.emit("error",i))}),e.once("close",()=>zY(t)),e.once("end",()=>zY(t)),e}vS.merge=yBe;function zY(t){t.forEach(e=>e.emit("close"))}});var _Y=E(VI=>{"use strict";Object.defineProperty(VI,"__esModule",{value:!0});function wBe(t){return typeof t=="string"}VI.isString=wBe;function BBe(t){return t===""}VI.isEmpty=BBe});var ga=E(ua=>{"use strict";Object.defineProperty(ua,"__esModule",{value:!0});var QBe=xY();ua.array=QBe;var bBe=kY();ua.errno=bBe;var vBe=DY();ua.fs=vBe;var SBe=RY();ua.path=SBe;var xBe=WY();ua.pattern=xBe;var kBe=VY();ua.stream=kBe;var PBe=_Y();ua.string=PBe});var tq=E(fa=>{"use strict";Object.defineProperty(fa,"__esModule",{value:!0});var Ll=ga();function DBe(t,e){let r=XY(t),i=ZY(t,e.ignore),n=r.filter(l=>Ll.pattern.isStaticPattern(l,e)),s=r.filter(l=>Ll.pattern.isDynamicPattern(l,e)),o=SS(n,i,!1),a=SS(s,i,!0);return o.concat(a)}fa.generate=DBe;function SS(t,e,r){let i=$Y(t);return"."in i?[xS(".",t,e,r)]:eq(i,e,r)}fa.convertPatternsToTasks=SS;function XY(t){return Ll.pattern.getPositivePatterns(t)}fa.getPositivePatterns=XY;function ZY(t,e){return Ll.pattern.getNegativePatterns(t).concat(e).map(Ll.pattern.convertToPositivePattern)}fa.getNegativePatternsAsPositive=ZY;function $Y(t){let e={};return t.reduce((r,i)=>{let n=Ll.pattern.getBaseDirectory(i);return n in r?r[n].push(i):r[n]=[i],r},e)}fa.groupPatternsByBaseDirectory=$Y;function eq(t,e,r){return Object.keys(t).map(i=>xS(i,t[i],e,r))}fa.convertPatternGroupsToTasks=eq;function xS(t,e,r,i){return{dynamic:i,positive:e,negative:r,base:t,patterns:[].concat(e,r.map(Ll.pattern.convertToNegativePattern))}}fa.convertPatternGroupToTask=xS});var iq=E(_I=>{"use strict";Object.defineProperty(_I,"__esModule",{value:!0});_I.read=void 0;function RBe(t,e,r){e.fs.lstat(t,(i,n)=>{if(i!==null){rq(r,i);return}if(!n.isSymbolicLink()||!e.followSymbolicLink){kS(r,n);return}e.fs.stat(t,(s,o)=>{if(s!==null){if(e.throwErrorOnBrokenSymbolicLink){rq(r,s);return}kS(r,n);return}e.markSymbolicLink&&(o.isSymbolicLink=()=>!0),kS(r,o)})})}_I.read=RBe;function rq(t,e){t(e)}function kS(t,e){t(null,e)}});var nq=E(XI=>{"use strict";Object.defineProperty(XI,"__esModule",{value:!0});XI.read=void 0;function FBe(t,e){let r=e.fs.lstatSync(t);if(!r.isSymbolicLink()||!e.followSymbolicLink)return r;try{let i=e.fs.statSync(t);return e.markSymbolicLink&&(i.isSymbolicLink=()=>!0),i}catch(i){if(!e.throwErrorOnBrokenSymbolicLink)return r;throw i}}XI.read=FBe});var sq=E(AA=>{"use strict";Object.defineProperty(AA,"__esModule",{value:!0});AA.createFileSystemAdapter=AA.FILE_SYSTEM_ADAPTER=void 0;var ZI=require("fs");AA.FILE_SYSTEM_ADAPTER={lstat:ZI.lstat,stat:ZI.stat,lstatSync:ZI.lstatSync,statSync:ZI.statSync};function NBe(t){return t===void 0?AA.FILE_SYSTEM_ADAPTER:Object.assign(Object.assign({},AA.FILE_SYSTEM_ADAPTER),t)}AA.createFileSystemAdapter=NBe});var aq=E(PS=>{"use strict";Object.defineProperty(PS,"__esModule",{value:!0});var LBe=sq(),oq=class{constructor(e={}){this._options=e,this.followSymbolicLink=this._getValue(this._options.followSymbolicLink,!0),this.fs=LBe.createFileSystemAdapter(this._options.fs),this.markSymbolicLink=this._getValue(this._options.markSymbolicLink,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!0)}_getValue(e,r){return e!=null?e:r}};PS.default=oq});var Tl=E(lA=>{"use strict";Object.defineProperty(lA,"__esModule",{value:!0});lA.statSync=lA.stat=lA.Settings=void 0;var Aq=iq(),TBe=nq(),DS=aq();lA.Settings=DS.default;function MBe(t,e,r){if(typeof e=="function"){Aq.read(t,RS(),e);return}Aq.read(t,RS(e),r)}lA.stat=MBe;function OBe(t,e){let r=RS(e);return TBe.read(t,r)}lA.statSync=OBe;function RS(t={}){return t instanceof DS.default?t:new DS.default(t)}});var cq=E((iit,lq)=>{lq.exports=KBe;function KBe(t,e){var r,i,n,s=!0;Array.isArray(t)?(r=[],i=t.length):(n=Object.keys(t),r={},i=n.length);function o(l){function c(){e&&e(l,r),e=null}s?process.nextTick(c):c()}function a(l,c,u){r[l]=u,(--i==0||c)&&o(c)}i?n?n.forEach(function(l){t[l](function(c,u){a(l,c,u)})}):t.forEach(function(l,c){l(function(u,g){a(c,u,g)})}):o(null),s=!1}});var FS=E($I=>{"use strict";Object.defineProperty($I,"__esModule",{value:!0});$I.IS_SUPPORT_READDIR_WITH_FILE_TYPES=void 0;var ey=process.versions.node.split(".");if(ey[0]===void 0||ey[1]===void 0)throw new Error(`Unexpected behavior. The 'process.versions.node' variable has invalid value: ${process.versions.node}`);var uq=Number.parseInt(ey[0],10),UBe=Number.parseInt(ey[1],10),gq=10,HBe=10,GBe=uq>gq,jBe=uq===gq&&UBe>=HBe;$I.IS_SUPPORT_READDIR_WITH_FILE_TYPES=GBe||jBe});var hq=E(ty=>{"use strict";Object.defineProperty(ty,"__esModule",{value:!0});ty.createDirentFromStats=void 0;var fq=class{constructor(e,r){this.name=e,this.isBlockDevice=r.isBlockDevice.bind(r),this.isCharacterDevice=r.isCharacterDevice.bind(r),this.isDirectory=r.isDirectory.bind(r),this.isFIFO=r.isFIFO.bind(r),this.isFile=r.isFile.bind(r),this.isSocket=r.isSocket.bind(r),this.isSymbolicLink=r.isSymbolicLink.bind(r)}};function YBe(t,e){return new fq(t,e)}ty.createDirentFromStats=YBe});var NS=E(ry=>{"use strict";Object.defineProperty(ry,"__esModule",{value:!0});ry.fs=void 0;var qBe=hq();ry.fs=qBe});var LS=E(iy=>{"use strict";Object.defineProperty(iy,"__esModule",{value:!0});iy.joinPathSegments=void 0;function JBe(t,e,r){return t.endsWith(r)?t+e:t+r+e}iy.joinPathSegments=JBe});var Iq=E(cA=>{"use strict";Object.defineProperty(cA,"__esModule",{value:!0});cA.readdir=cA.readdirWithFileTypes=cA.read=void 0;var WBe=Tl(),pq=cq(),zBe=FS(),dq=NS(),Cq=LS();function VBe(t,e,r){if(!e.stats&&zBe.IS_SUPPORT_READDIR_WITH_FILE_TYPES){mq(t,e,r);return}Eq(t,e,r)}cA.read=VBe;function mq(t,e,r){e.fs.readdir(t,{withFileTypes:!0},(i,n)=>{if(i!==null){ny(r,i);return}let s=n.map(a=>({dirent:a,name:a.name,path:Cq.joinPathSegments(t,a.name,e.pathSegmentSeparator)}));if(!e.followSymbolicLinks){TS(r,s);return}let o=s.map(a=>_Be(a,e));pq(o,(a,l)=>{if(a!==null){ny(r,a);return}TS(r,l)})})}cA.readdirWithFileTypes=mq;function _Be(t,e){return r=>{if(!t.dirent.isSymbolicLink()){r(null,t);return}e.fs.stat(t.path,(i,n)=>{if(i!==null){if(e.throwErrorOnBrokenSymbolicLink){r(i);return}r(null,t);return}t.dirent=dq.fs.createDirentFromStats(t.name,n),r(null,t)})}}function Eq(t,e,r){e.fs.readdir(t,(i,n)=>{if(i!==null){ny(r,i);return}let s=n.map(o=>{let a=Cq.joinPathSegments(t,o,e.pathSegmentSeparator);return l=>{WBe.stat(a,e.fsStatSettings,(c,u)=>{if(c!==null){l(c);return}let g={name:o,path:a,dirent:dq.fs.createDirentFromStats(o,u)};e.stats&&(g.stats=u),l(null,g)})}});pq(s,(o,a)=>{if(o!==null){ny(r,o);return}TS(r,a)})})}cA.readdir=Eq;function ny(t,e){t(e)}function TS(t,e){t(null,e)}});var bq=E(uA=>{"use strict";Object.defineProperty(uA,"__esModule",{value:!0});uA.readdir=uA.readdirWithFileTypes=uA.read=void 0;var XBe=Tl(),ZBe=FS(),yq=NS(),wq=LS();function $Be(t,e){return!e.stats&&ZBe.IS_SUPPORT_READDIR_WITH_FILE_TYPES?Bq(t,e):Qq(t,e)}uA.read=$Be;function Bq(t,e){return e.fs.readdirSync(t,{withFileTypes:!0}).map(i=>{let n={dirent:i,name:i.name,path:wq.joinPathSegments(t,i.name,e.pathSegmentSeparator)};if(n.dirent.isSymbolicLink()&&e.followSymbolicLinks)try{let s=e.fs.statSync(n.path);n.dirent=yq.fs.createDirentFromStats(n.name,s)}catch(s){if(e.throwErrorOnBrokenSymbolicLink)throw s}return n})}uA.readdirWithFileTypes=Bq;function Qq(t,e){return e.fs.readdirSync(t).map(i=>{let n=wq.joinPathSegments(t,i,e.pathSegmentSeparator),s=XBe.statSync(n,e.fsStatSettings),o={name:i,path:n,dirent:yq.fs.createDirentFromStats(i,s)};return e.stats&&(o.stats=s),o})}uA.readdir=Qq});var vq=E(gA=>{"use strict";Object.defineProperty(gA,"__esModule",{value:!0});gA.createFileSystemAdapter=gA.FILE_SYSTEM_ADAPTER=void 0;var Du=require("fs");gA.FILE_SYSTEM_ADAPTER={lstat:Du.lstat,stat:Du.stat,lstatSync:Du.lstatSync,statSync:Du.statSync,readdir:Du.readdir,readdirSync:Du.readdirSync};function e0e(t){return t===void 0?gA.FILE_SYSTEM_ADAPTER:Object.assign(Object.assign({},gA.FILE_SYSTEM_ADAPTER),t)}gA.createFileSystemAdapter=e0e});var xq=E(MS=>{"use strict";Object.defineProperty(MS,"__esModule",{value:!0});var t0e=require("path"),r0e=Tl(),i0e=vq(),Sq=class{constructor(e={}){this._options=e,this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,!1),this.fs=i0e.createFileSystemAdapter(this._options.fs),this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,t0e.sep),this.stats=this._getValue(this._options.stats,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!0),this.fsStatSettings=new r0e.Settings({followSymbolicLink:this.followSymbolicLinks,fs:this.fs,throwErrorOnBrokenSymbolicLink:this.throwErrorOnBrokenSymbolicLink})}_getValue(e,r){return e!=null?e:r}};MS.default=Sq});var sy=E(fA=>{"use strict";Object.defineProperty(fA,"__esModule",{value:!0});fA.Settings=fA.scandirSync=fA.scandir=void 0;var kq=Iq(),n0e=bq(),OS=xq();fA.Settings=OS.default;function s0e(t,e,r){if(typeof e=="function"){kq.read(t,KS(),e);return}kq.read(t,KS(e),r)}fA.scandir=s0e;function o0e(t,e){let r=KS(e);return n0e.read(t,r)}fA.scandirSync=o0e;function KS(t={}){return t instanceof OS.default?t:new OS.default(t)}});var Dq=E((fit,Pq)=>{"use strict";function a0e(t){var e=new t,r=e;function i(){var s=e;return s.next?e=s.next:(e=new t,r=e),s.next=null,s}function n(s){r.next=s,r=s}return{get:i,release:n}}Pq.exports=a0e});var Fq=E((hit,US)=>{"use strict";var A0e=Dq();function Rq(t,e,r){if(typeof t=="function"&&(r=e,e=t,t=null),r<1)throw new Error("fastqueue concurrency must be greater than 1");var i=A0e(l0e),n=null,s=null,o=0,a=null,l={push:d,drain:po,saturated:po,pause:u,paused:!1,concurrency:r,running:c,resume:h,idle:p,length:g,getQueue:f,unshift:m,empty:po,kill:B,killAndDrain:b,error:R};return l;function c(){return o}function u(){l.paused=!0}function g(){for(var H=n,L=0;H;)H=H.next,L++;return L}function f(){for(var H=n,L=[];H;)L.push(H.value),H=H.next;return L}function h(){if(!!l.paused){l.paused=!1;for(var H=0;H{"use strict";Object.defineProperty(Co,"__esModule",{value:!0});Co.joinPathSegments=Co.replacePathSegmentSeparator=Co.isAppliedFilter=Co.isFatalError=void 0;function u0e(t,e){return t.errorFilter===null?!0:!t.errorFilter(e)}Co.isFatalError=u0e;function g0e(t,e){return t===null||t(e)}Co.isAppliedFilter=g0e;function f0e(t,e){return t.split(/[/\\]/).join(e)}Co.replacePathSegmentSeparator=f0e;function h0e(t,e,r){return t===""?e:t.endsWith(r)?t+e:t+r+e}Co.joinPathSegments=h0e});var GS=E(HS=>{"use strict";Object.defineProperty(HS,"__esModule",{value:!0});var p0e=oy(),Nq=class{constructor(e,r){this._root=e,this._settings=r,this._root=p0e.replacePathSegmentSeparator(e,r.pathSegmentSeparator)}};HS.default=Nq});var YS=E(jS=>{"use strict";Object.defineProperty(jS,"__esModule",{value:!0});var d0e=require("events"),C0e=sy(),m0e=Fq(),ay=oy(),E0e=GS(),Lq=class extends E0e.default{constructor(e,r){super(e,r);this._settings=r,this._scandir=C0e.scandir,this._emitter=new d0e.EventEmitter,this._queue=m0e(this._worker.bind(this),this._settings.concurrency),this._isFatalError=!1,this._isDestroyed=!1,this._queue.drain=()=>{this._isFatalError||this._emitter.emit("end")}}read(){return this._isFatalError=!1,this._isDestroyed=!1,setImmediate(()=>{this._pushToQueue(this._root,this._settings.basePath)}),this._emitter}get isDestroyed(){return this._isDestroyed}destroy(){if(this._isDestroyed)throw new Error("The reader is already destroyed");this._isDestroyed=!0,this._queue.killAndDrain()}onEntry(e){this._emitter.on("entry",e)}onError(e){this._emitter.once("error",e)}onEnd(e){this._emitter.once("end",e)}_pushToQueue(e,r){let i={directory:e,base:r};this._queue.push(i,n=>{n!==null&&this._handleError(n)})}_worker(e,r){this._scandir(e.directory,this._settings.fsScandirSettings,(i,n)=>{if(i!==null){r(i,void 0);return}for(let s of n)this._handleEntry(s,e.base);r(null,void 0)})}_handleError(e){this._isDestroyed||!ay.isFatalError(this._settings,e)||(this._isFatalError=!0,this._isDestroyed=!0,this._emitter.emit("error",e))}_handleEntry(e,r){if(this._isDestroyed||this._isFatalError)return;let i=e.path;r!==void 0&&(e.path=ay.joinPathSegments(r,e.name,this._settings.pathSegmentSeparator)),ay.isAppliedFilter(this._settings.entryFilter,e)&&this._emitEntry(e),e.dirent.isDirectory()&&ay.isAppliedFilter(this._settings.deepFilter,e)&&this._pushToQueue(i,e.path)}_emitEntry(e){this._emitter.emit("entry",e)}};jS.default=Lq});var Mq=E(qS=>{"use strict";Object.defineProperty(qS,"__esModule",{value:!0});var I0e=YS(),Tq=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new I0e.default(this._root,this._settings),this._storage=new Set}read(e){this._reader.onError(r=>{y0e(e,r)}),this._reader.onEntry(r=>{this._storage.add(r)}),this._reader.onEnd(()=>{w0e(e,[...this._storage])}),this._reader.read()}};qS.default=Tq;function y0e(t,e){t(e)}function w0e(t,e){t(null,e)}});var Kq=E(JS=>{"use strict";Object.defineProperty(JS,"__esModule",{value:!0});var B0e=require("stream"),Q0e=YS(),Oq=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new Q0e.default(this._root,this._settings),this._stream=new B0e.Readable({objectMode:!0,read:()=>{},destroy:()=>{this._reader.isDestroyed||this._reader.destroy()}})}read(){return this._reader.onError(e=>{this._stream.emit("error",e)}),this._reader.onEntry(e=>{this._stream.push(e)}),this._reader.onEnd(()=>{this._stream.push(null)}),this._reader.read(),this._stream}};JS.default=Oq});var Hq=E(WS=>{"use strict";Object.defineProperty(WS,"__esModule",{value:!0});var b0e=sy(),Ay=oy(),v0e=GS(),Uq=class extends v0e.default{constructor(){super(...arguments);this._scandir=b0e.scandirSync,this._storage=new Set,this._queue=new Set}read(){return this._pushToQueue(this._root,this._settings.basePath),this._handleQueue(),[...this._storage]}_pushToQueue(e,r){this._queue.add({directory:e,base:r})}_handleQueue(){for(let e of this._queue.values())this._handleDirectory(e.directory,e.base)}_handleDirectory(e,r){try{let i=this._scandir(e,this._settings.fsScandirSettings);for(let n of i)this._handleEntry(n,r)}catch(i){this._handleError(i)}}_handleError(e){if(!!Ay.isFatalError(this._settings,e))throw e}_handleEntry(e,r){let i=e.path;r!==void 0&&(e.path=Ay.joinPathSegments(r,e.name,this._settings.pathSegmentSeparator)),Ay.isAppliedFilter(this._settings.entryFilter,e)&&this._pushToStorage(e),e.dirent.isDirectory()&&Ay.isAppliedFilter(this._settings.deepFilter,e)&&this._pushToQueue(i,e.path)}_pushToStorage(e){this._storage.add(e)}};WS.default=Uq});var jq=E(zS=>{"use strict";Object.defineProperty(zS,"__esModule",{value:!0});var S0e=Hq(),Gq=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new S0e.default(this._root,this._settings)}read(){return this._reader.read()}};zS.default=Gq});var qq=E(VS=>{"use strict";Object.defineProperty(VS,"__esModule",{value:!0});var x0e=require("path"),k0e=sy(),Yq=class{constructor(e={}){this._options=e,this.basePath=this._getValue(this._options.basePath,void 0),this.concurrency=this._getValue(this._options.concurrency,Number.POSITIVE_INFINITY),this.deepFilter=this._getValue(this._options.deepFilter,null),this.entryFilter=this._getValue(this._options.entryFilter,null),this.errorFilter=this._getValue(this._options.errorFilter,null),this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,x0e.sep),this.fsScandirSettings=new k0e.Settings({followSymbolicLinks:this._options.followSymbolicLinks,fs:this._options.fs,pathSegmentSeparator:this._options.pathSegmentSeparator,stats:this._options.stats,throwErrorOnBrokenSymbolicLink:this._options.throwErrorOnBrokenSymbolicLink})}_getValue(e,r){return e!=null?e:r}};VS.default=Yq});var XS=E(mo=>{"use strict";Object.defineProperty(mo,"__esModule",{value:!0});mo.Settings=mo.walkStream=mo.walkSync=mo.walk=void 0;var Jq=Mq(),P0e=Kq(),D0e=jq(),_S=qq();mo.Settings=_S.default;function R0e(t,e,r){if(typeof e=="function"){new Jq.default(t,ly()).read(e);return}new Jq.default(t,ly(e)).read(r)}mo.walk=R0e;function F0e(t,e){let r=ly(e);return new D0e.default(t,r).read()}mo.walkSync=F0e;function N0e(t,e){let r=ly(e);return new P0e.default(t,r).read()}mo.walkStream=N0e;function ly(t={}){return t instanceof _S.default?t:new _S.default(t)}});var $S=E(ZS=>{"use strict";Object.defineProperty(ZS,"__esModule",{value:!0});var L0e=require("path"),T0e=Tl(),Wq=ga(),zq=class{constructor(e){this._settings=e,this._fsStatSettings=new T0e.Settings({followSymbolicLink:this._settings.followSymbolicLinks,fs:this._settings.fs,throwErrorOnBrokenSymbolicLink:this._settings.followSymbolicLinks})}_getFullEntryPath(e){return L0e.resolve(this._settings.cwd,e)}_makeEntry(e,r){let i={name:r,path:r,dirent:Wq.fs.createDirentFromStats(r,e)};return this._settings.stats&&(i.stats=e),i}_isFatalError(e){return!Wq.errno.isEnoentCodeError(e)&&!this._settings.suppressErrors}};ZS.default=zq});var tx=E(ex=>{"use strict";Object.defineProperty(ex,"__esModule",{value:!0});var M0e=require("stream"),O0e=Tl(),K0e=XS(),U0e=$S(),Vq=class extends U0e.default{constructor(){super(...arguments);this._walkStream=K0e.walkStream,this._stat=O0e.stat}dynamic(e,r){return this._walkStream(e,r)}static(e,r){let i=e.map(this._getFullEntryPath,this),n=new M0e.PassThrough({objectMode:!0});n._write=(s,o,a)=>this._getEntry(i[s],e[s],r).then(l=>{l!==null&&r.entryFilter(l)&&n.push(l),s===i.length-1&&n.end(),a()}).catch(a);for(let s=0;sthis._makeEntry(n,r)).catch(n=>{if(i.errorFilter(n))return null;throw n})}_getStat(e){return new Promise((r,i)=>{this._stat(e,this._fsStatSettings,(n,s)=>n===null?r(s):i(n))})}};ex.default=Vq});var Xq=E(rx=>{"use strict";Object.defineProperty(rx,"__esModule",{value:!0});var Ru=ga(),_q=class{constructor(e,r,i){this._patterns=e,this._settings=r,this._micromatchOptions=i,this._storage=[],this._fillStorage()}_fillStorage(){let e=Ru.pattern.expandPatternsWithBraceExpansion(this._patterns);for(let r of e){let i=this._getPatternSegments(r),n=this._splitSegmentsIntoSections(i);this._storage.push({complete:n.length<=1,pattern:r,segments:i,sections:n})}}_getPatternSegments(e){return Ru.pattern.getPatternParts(e,this._micromatchOptions).map(i=>Ru.pattern.isDynamicPattern(i,this._settings)?{dynamic:!0,pattern:i,patternRe:Ru.pattern.makeRe(i,this._micromatchOptions)}:{dynamic:!1,pattern:i})}_splitSegmentsIntoSections(e){return Ru.array.splitWhen(e,r=>r.dynamic&&Ru.pattern.hasGlobStar(r.pattern))}};rx.default=_q});var $q=E(ix=>{"use strict";Object.defineProperty(ix,"__esModule",{value:!0});var H0e=Xq(),Zq=class extends H0e.default{match(e){let r=e.split("/"),i=r.length,n=this._storage.filter(s=>!s.complete||s.segments.length>i);for(let s of n){let o=s.sections[0];if(!s.complete&&i>o.length||r.every((l,c)=>{let u=s.segments[c];return!!(u.dynamic&&u.patternRe.test(l)||!u.dynamic&&u.pattern===l)}))return!0}return!1}};ix.default=Zq});var tJ=E(nx=>{"use strict";Object.defineProperty(nx,"__esModule",{value:!0});var cy=ga(),G0e=$q(),eJ=class{constructor(e,r){this._settings=e,this._micromatchOptions=r}getFilter(e,r,i){let n=this._getMatcher(r),s=this._getNegativePatternsRe(i);return o=>this._filter(e,o,n,s)}_getMatcher(e){return new G0e.default(e,this._settings,this._micromatchOptions)}_getNegativePatternsRe(e){let r=e.filter(cy.pattern.isAffectDepthOfReadingPattern);return cy.pattern.convertPatternsToRe(r,this._micromatchOptions)}_filter(e,r,i,n){let s=this._getEntryLevel(e,r.path);if(this._isSkippedByDeep(s)||this._isSkippedSymbolicLink(r))return!1;let o=cy.path.removeLeadingDotSegment(r.path);return this._isSkippedByPositivePatterns(o,i)?!1:this._isSkippedByNegativePatterns(o,n)}_isSkippedByDeep(e){return e>=this._settings.deep}_isSkippedSymbolicLink(e){return!this._settings.followSymbolicLinks&&e.dirent.isSymbolicLink()}_getEntryLevel(e,r){let i=e.split("/").length;return r.split("/").length-(e===""?0:i)}_isSkippedByPositivePatterns(e,r){return!this._settings.baseNameMatch&&!r.match(e)}_isSkippedByNegativePatterns(e,r){return!cy.pattern.matchAny(e,r)}};nx.default=eJ});var iJ=E(sx=>{"use strict";Object.defineProperty(sx,"__esModule",{value:!0});var ip=ga(),rJ=class{constructor(e,r){this._settings=e,this._micromatchOptions=r,this.index=new Map}getFilter(e,r){let i=ip.pattern.convertPatternsToRe(e,this._micromatchOptions),n=ip.pattern.convertPatternsToRe(r,this._micromatchOptions);return s=>this._filter(s,i,n)}_filter(e,r,i){if(this._settings.unique){if(this._isDuplicateEntry(e))return!1;this._createIndexRecord(e)}if(this._onlyFileFilter(e)||this._onlyDirectoryFilter(e)||this._isSkippedByAbsoluteNegativePatterns(e,i))return!1;let n=this._settings.baseNameMatch?e.name:e.path;return this._isMatchToPatterns(n,r)&&!this._isMatchToPatterns(e.path,i)}_isDuplicateEntry(e){return this.index.has(e.path)}_createIndexRecord(e){this.index.set(e.path,void 0)}_onlyFileFilter(e){return this._settings.onlyFiles&&!e.dirent.isFile()}_onlyDirectoryFilter(e){return this._settings.onlyDirectories&&!e.dirent.isDirectory()}_isSkippedByAbsoluteNegativePatterns(e,r){if(!this._settings.absolute)return!1;let i=ip.path.makeAbsolute(this._settings.cwd,e.path);return this._isMatchToPatterns(i,r)}_isMatchToPatterns(e,r){let i=ip.path.removeLeadingDotSegment(e);return ip.pattern.matchAny(i,r)}};sx.default=rJ});var sJ=E(ox=>{"use strict";Object.defineProperty(ox,"__esModule",{value:!0});var j0e=ga(),nJ=class{constructor(e){this._settings=e}getFilter(){return e=>this._isNonFatalError(e)}_isNonFatalError(e){return j0e.errno.isEnoentCodeError(e)||this._settings.suppressErrors}};ox.default=nJ});var AJ=E(ax=>{"use strict";Object.defineProperty(ax,"__esModule",{value:!0});var oJ=ga(),aJ=class{constructor(e){this._settings=e}getTransformer(){return e=>this._transform(e)}_transform(e){let r=e.path;return this._settings.absolute&&(r=oJ.path.makeAbsolute(this._settings.cwd,r),r=oJ.path.unixify(r)),this._settings.markDirectories&&e.dirent.isDirectory()&&(r+="/"),this._settings.objectMode?Object.assign(Object.assign({},e),{path:r}):r}};ax.default=aJ});var uy=E(Ax=>{"use strict";Object.defineProperty(Ax,"__esModule",{value:!0});var Y0e=require("path"),q0e=tJ(),J0e=iJ(),W0e=sJ(),z0e=AJ(),lJ=class{constructor(e){this._settings=e,this.errorFilter=new W0e.default(this._settings),this.entryFilter=new J0e.default(this._settings,this._getMicromatchOptions()),this.deepFilter=new q0e.default(this._settings,this._getMicromatchOptions()),this.entryTransformer=new z0e.default(this._settings)}_getRootDirectory(e){return Y0e.resolve(this._settings.cwd,e.base)}_getReaderOptions(e){let r=e.base==="."?"":e.base;return{basePath:r,pathSegmentSeparator:"/",concurrency:this._settings.concurrency,deepFilter:this.deepFilter.getFilter(r,e.positive,e.negative),entryFilter:this.entryFilter.getFilter(e.positive,e.negative),errorFilter:this.errorFilter.getFilter(),followSymbolicLinks:this._settings.followSymbolicLinks,fs:this._settings.fs,stats:this._settings.stats,throwErrorOnBrokenSymbolicLink:this._settings.throwErrorOnBrokenSymbolicLink,transform:this.entryTransformer.getTransformer()}}_getMicromatchOptions(){return{dot:this._settings.dot,matchBase:this._settings.baseNameMatch,nobrace:!this._settings.braceExpansion,nocase:!this._settings.caseSensitiveMatch,noext:!this._settings.extglob,noglobstar:!this._settings.globstar,posix:!0,strictSlashes:!1}}};Ax.default=lJ});var uJ=E(lx=>{"use strict";Object.defineProperty(lx,"__esModule",{value:!0});var V0e=tx(),_0e=uy(),cJ=class extends _0e.default{constructor(){super(...arguments);this._reader=new V0e.default(this._settings)}read(e){let r=this._getRootDirectory(e),i=this._getReaderOptions(e),n=[];return new Promise((s,o)=>{let a=this.api(r,e,i);a.once("error",o),a.on("data",l=>n.push(i.transform(l))),a.once("end",()=>s(n))})}api(e,r,i){return r.dynamic?this._reader.dynamic(e,i):this._reader.static(r.patterns,i)}};lx.default=cJ});var fJ=E(cx=>{"use strict";Object.defineProperty(cx,"__esModule",{value:!0});var X0e=require("stream"),Z0e=tx(),$0e=uy(),gJ=class extends $0e.default{constructor(){super(...arguments);this._reader=new Z0e.default(this._settings)}read(e){let r=this._getRootDirectory(e),i=this._getReaderOptions(e),n=this.api(r,e,i),s=new X0e.Readable({objectMode:!0,read:()=>{}});return n.once("error",o=>s.emit("error",o)).on("data",o=>s.emit("data",i.transform(o))).once("end",()=>s.emit("end")),s.once("close",()=>n.destroy()),s}api(e,r,i){return r.dynamic?this._reader.dynamic(e,i):this._reader.static(r.patterns,i)}};cx.default=gJ});var pJ=E(ux=>{"use strict";Object.defineProperty(ux,"__esModule",{value:!0});var eQe=Tl(),tQe=XS(),rQe=$S(),hJ=class extends rQe.default{constructor(){super(...arguments);this._walkSync=tQe.walkSync,this._statSync=eQe.statSync}dynamic(e,r){return this._walkSync(e,r)}static(e,r){let i=[];for(let n of e){let s=this._getFullEntryPath(n),o=this._getEntry(s,n,r);o===null||!r.entryFilter(o)||i.push(o)}return i}_getEntry(e,r,i){try{let n=this._getStat(e);return this._makeEntry(n,r)}catch(n){if(i.errorFilter(n))return null;throw n}}_getStat(e){return this._statSync(e,this._fsStatSettings)}};ux.default=hJ});var CJ=E(gx=>{"use strict";Object.defineProperty(gx,"__esModule",{value:!0});var iQe=pJ(),nQe=uy(),dJ=class extends nQe.default{constructor(){super(...arguments);this._reader=new iQe.default(this._settings)}read(e){let r=this._getRootDirectory(e),i=this._getReaderOptions(e);return this.api(r,e,i).map(i.transform)}api(e,r,i){return r.dynamic?this._reader.dynamic(e,i):this._reader.static(r.patterns,i)}};gx.default=dJ});var EJ=E(np=>{"use strict";Object.defineProperty(np,"__esModule",{value:!0});var Fu=require("fs"),sQe=require("os"),oQe=sQe.cpus().length;np.DEFAULT_FILE_SYSTEM_ADAPTER={lstat:Fu.lstat,lstatSync:Fu.lstatSync,stat:Fu.stat,statSync:Fu.statSync,readdir:Fu.readdir,readdirSync:Fu.readdirSync};var mJ=class{constructor(e={}){this._options=e,this.absolute=this._getValue(this._options.absolute,!1),this.baseNameMatch=this._getValue(this._options.baseNameMatch,!1),this.braceExpansion=this._getValue(this._options.braceExpansion,!0),this.caseSensitiveMatch=this._getValue(this._options.caseSensitiveMatch,!0),this.concurrency=this._getValue(this._options.concurrency,oQe),this.cwd=this._getValue(this._options.cwd,process.cwd()),this.deep=this._getValue(this._options.deep,Infinity),this.dot=this._getValue(this._options.dot,!1),this.extglob=this._getValue(this._options.extglob,!0),this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,!0),this.fs=this._getFileSystemMethods(this._options.fs),this.globstar=this._getValue(this._options.globstar,!0),this.ignore=this._getValue(this._options.ignore,[]),this.markDirectories=this._getValue(this._options.markDirectories,!1),this.objectMode=this._getValue(this._options.objectMode,!1),this.onlyDirectories=this._getValue(this._options.onlyDirectories,!1),this.onlyFiles=this._getValue(this._options.onlyFiles,!0),this.stats=this._getValue(this._options.stats,!1),this.suppressErrors=this._getValue(this._options.suppressErrors,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!1),this.unique=this._getValue(this._options.unique,!0),this.onlyDirectories&&(this.onlyFiles=!1),this.stats&&(this.objectMode=!0)}_getValue(e,r){return e===void 0?r:e}_getFileSystemMethods(e={}){return Object.assign(Object.assign({},np.DEFAULT_FILE_SYSTEM_ADAPTER),e)}};np.default=mJ});var gy=E((Oit,IJ)=>{"use strict";var yJ=tq(),aQe=uJ(),AQe=fJ(),lQe=CJ(),fx=EJ(),Ml=ga();async function px(t,e){Nu(t);let r=hx(t,aQe.default,e),i=await Promise.all(r);return Ml.array.flatten(i)}(function(t){function e(o,a){Nu(o);let l=hx(o,lQe.default,a);return Ml.array.flatten(l)}t.sync=e;function r(o,a){Nu(o);let l=hx(o,AQe.default,a);return Ml.stream.merge(l)}t.stream=r;function i(o,a){Nu(o);let l=[].concat(o),c=new fx.default(a);return yJ.generate(l,c)}t.generateTasks=i;function n(o,a){Nu(o);let l=new fx.default(a);return Ml.pattern.isDynamicPattern(o,l)}t.isDynamicPattern=n;function s(o){return Nu(o),Ml.path.escape(o)}t.escapePath=s})(px||(px={}));function hx(t,e,r){let i=[].concat(t),n=new fx.default(r),s=yJ.generate(i,n),o=new e(n);return s.map(o.read,o)}function Nu(t){if(![].concat(t).every(i=>Ml.string.isString(i)&&!Ml.string.isEmpty(i)))throw new TypeError("Patterns must be a string (non empty) or an array of strings")}IJ.exports=px});var BJ=E(Ol=>{"use strict";var{promisify:cQe}=require("util"),wJ=require("fs");async function dx(t,e,r){if(typeof r!="string")throw new TypeError(`Expected a string, got ${typeof r}`);try{return(await cQe(wJ[t])(r))[e]()}catch(i){if(i.code==="ENOENT")return!1;throw i}}function Cx(t,e,r){if(typeof r!="string")throw new TypeError(`Expected a string, got ${typeof r}`);try{return wJ[t](r)[e]()}catch(i){if(i.code==="ENOENT")return!1;throw i}}Ol.isFile=dx.bind(null,"stat","isFile");Ol.isDirectory=dx.bind(null,"stat","isDirectory");Ol.isSymlink=dx.bind(null,"lstat","isSymbolicLink");Ol.isFileSync=Cx.bind(null,"statSync","isFile");Ol.isDirectorySync=Cx.bind(null,"statSync","isDirectory");Ol.isSymlinkSync=Cx.bind(null,"lstatSync","isSymbolicLink")});var xJ=E((Uit,mx)=>{"use strict";var Kl=require("path"),QJ=BJ(),bJ=t=>t.length>1?`{${t.join(",")}}`:t[0],vJ=(t,e)=>{let r=t[0]==="!"?t.slice(1):t;return Kl.isAbsolute(r)?r:Kl.join(e,r)},uQe=(t,e)=>Kl.extname(t)?`**/${t}`:`**/${t}.${bJ(e)}`,SJ=(t,e)=>{if(e.files&&!Array.isArray(e.files))throw new TypeError(`Expected \`files\` to be of type \`Array\` but received type \`${typeof e.files}\``);if(e.extensions&&!Array.isArray(e.extensions))throw new TypeError(`Expected \`extensions\` to be of type \`Array\` but received type \`${typeof e.extensions}\``);return e.files&&e.extensions?e.files.map(r=>Kl.posix.join(t,uQe(r,e.extensions))):e.files?e.files.map(r=>Kl.posix.join(t,`**/${r}`)):e.extensions?[Kl.posix.join(t,`**/*.${bJ(e.extensions)}`)]:[Kl.posix.join(t,"**")]};mx.exports=async(t,e)=>{if(e=P({cwd:process.cwd()},e),typeof e.cwd!="string")throw new TypeError(`Expected \`cwd\` to be of type \`string\` but received type \`${typeof e.cwd}\``);let r=await Promise.all([].concat(t).map(async i=>await QJ.isDirectory(vJ(i,e.cwd))?SJ(i,e):i));return[].concat.apply([],r)};mx.exports.sync=(t,e)=>{if(e=P({cwd:process.cwd()},e),typeof e.cwd!="string")throw new TypeError(`Expected \`cwd\` to be of type \`string\` but received type \`${typeof e.cwd}\``);let r=[].concat(t).map(i=>QJ.isDirectorySync(vJ(i,e.cwd))?SJ(i,e):i);return[].concat.apply([],r)}});var TJ=E((Hit,kJ)=>{function PJ(t){return Array.isArray(t)?t:[t]}var gQe=/^\s+$/,fQe=/^\\!/,hQe=/^\\#/,pQe=/\r?\n/g,dQe=/^\.*\/|^\.+$/,Ex="/",DJ=typeof Symbol!="undefined"?Symbol.for("node-ignore"):"node-ignore",CQe=(t,e,r)=>Object.defineProperty(t,e,{value:r}),mQe=/([0-z])-([0-z])/g,EQe=t=>t.replace(mQe,(e,r,i)=>r.charCodeAt(0)<=i.charCodeAt(0)?e:""),IQe=[[/\\?\s+$/,t=>t.indexOf("\\")===0?" ":""],[/\\\s/g,()=>" "],[/[\\^$.|*+(){]/g,t=>`\\${t}`],[/\[([^\]/]*)($|\])/g,(t,e,r)=>r==="]"?`[${EQe(e)}]`:`\\${t}`],[/(?!\\)\?/g,()=>"[^/]"],[/^\//,()=>"^"],[/\//g,()=>"\\/"],[/^\^*\\\*\\\*\\\//,()=>"^(?:.*\\/)?"],[/(?:[^*])$/,t=>/\/$/.test(t)?`${t}$`:`${t}(?=$|\\/$)`],[/^(?=[^^])/,function(){return/\/(?!$)/.test(this)?"^":"(?:^|\\/)"}],[/\\\/\\\*\\\*(?=\\\/|$)/g,(t,e,r)=>e+6`${e}[^\\/]*`],[/(\^|\\\/)?\\\*$/,(t,e)=>`${e?`${e}[^/]+`:"[^/]*"}(?=$|\\/$)`],[/\\\\\\/g,()=>"\\"]],RJ=Object.create(null),yQe=(t,e,r)=>{let i=RJ[t];if(i)return i;let n=IQe.reduce((s,o)=>s.replace(o[0],o[1].bind(t)),t);return RJ[t]=r?new RegExp(n,"i"):new RegExp(n)},Ix=t=>typeof t=="string",wQe=t=>t&&Ix(t)&&!gQe.test(t)&&t.indexOf("#")!==0,BQe=t=>t.split(pQe),FJ=class{constructor(e,r,i,n){this.origin=e,this.pattern=r,this.negative=i,this.regex=n}},QQe=(t,e)=>{let r=t,i=!1;t.indexOf("!")===0&&(i=!0,t=t.substr(1)),t=t.replace(fQe,"!").replace(hQe,"#");let n=yQe(t,i,e);return new FJ(r,t,i,n)},bQe=(t,e)=>{throw new e(t)},ha=(t,e,r)=>Ix(t)?t?ha.isNotRelative(t)?r(`path should be a \`path.relative()\`d string, but got "${e}"`,RangeError):!0:r("path must not be empty",TypeError):r(`path must be a string, but got \`${e}\``,TypeError),NJ=t=>dQe.test(t);ha.isNotRelative=NJ;ha.convert=t=>t;var LJ=class{constructor({ignorecase:e=!0}={}){this._rules=[],this._ignorecase=e,CQe(this,DJ,!0),this._initCache()}_initCache(){this._ignoreCache=Object.create(null),this._testCache=Object.create(null)}_addPattern(e){if(e&&e[DJ]){this._rules=this._rules.concat(e._rules),this._added=!0;return}if(wQe(e)){let r=QQe(e,this._ignorecase);this._added=!0,this._rules.push(r)}}add(e){return this._added=!1,PJ(Ix(e)?BQe(e):e).forEach(this._addPattern,this),this._added&&this._initCache(),this}addPattern(e){return this.add(e)}_testOne(e,r){let i=!1,n=!1;return this._rules.forEach(s=>{let{negative:o}=s;if(n===o&&i!==n||o&&!i&&!n&&!r)return;s.regex.test(e)&&(i=!o,n=o)}),{ignored:i,unignored:n}}_test(e,r,i,n){let s=e&&ha.convert(e);return ha(s,e,bQe),this._t(s,r,i,n)}_t(e,r,i,n){if(e in r)return r[e];if(n||(n=e.split(Ex)),n.pop(),!n.length)return r[e]=this._testOne(e,i);let s=this._t(n.join(Ex)+Ex,r,i,n);return r[e]=s.ignored?s:this._testOne(e,i)}ignores(e){return this._test(e,this._ignoreCache,!1).ignored}createFilter(){return e=>!this.ignores(e)}filter(e){return PJ(e).filter(this.createFilter())}test(e){return this._test(e,this._testCache,!0)}},fy=t=>new LJ(t),vQe=()=>!1,SQe=t=>ha(t&&ha.convert(t),t,vQe);fy.isPathValid=SQe;fy.default=fy;kJ.exports=fy;if(typeof process!="undefined"&&(process.env&&process.env.IGNORE_TEST_WIN32||process.platform==="win32")){let t=r=>/^\\\\\?\\/.test(r)||/["<>|\u0000-\u001F]+/u.test(r)?r:r.replace(/\\/g,"/");ha.convert=t;let e=/^[a-z]:\//i;ha.isNotRelative=r=>e.test(r)||NJ(r)}});var OJ=E((Git,MJ)=>{"use strict";MJ.exports=t=>{let e=/^\\\\\?\\/.test(t),r=/[^\u0000-\u0080]+/.test(t);return e||r?t:t.replace(/\\/g,"/")}});var qJ=E((jit,yx)=>{"use strict";var{promisify:xQe}=require("util"),KJ=require("fs"),pa=require("path"),UJ=gy(),kQe=TJ(),sp=OJ(),HJ=["**/node_modules/**","**/flow-typed/**","**/coverage/**","**/.git"],PQe=xQe(KJ.readFile),DQe=t=>e=>e.startsWith("!")?"!"+pa.posix.join(t,e.slice(1)):pa.posix.join(t,e),RQe=(t,e)=>{let r=sp(pa.relative(e.cwd,pa.dirname(e.fileName)));return t.split(/\r?\n/).filter(Boolean).filter(i=>!i.startsWith("#")).map(DQe(r))},GJ=t=>{let e=kQe();for(let r of t)e.add(RQe(r.content,{cwd:r.cwd,fileName:r.filePath}));return e},FQe=(t,e)=>{if(t=sp(t),pa.isAbsolute(e)){if(sp(e).startsWith(t))return e;throw new Error(`Path ${e} is not in cwd ${t}`)}return pa.join(t,e)},jJ=(t,e)=>r=>t.ignores(sp(pa.relative(e,FQe(e,r.path||r)))),NQe=async(t,e)=>{let r=pa.join(e,t),i=await PQe(r,"utf8");return{cwd:e,filePath:r,content:i}},LQe=(t,e)=>{let r=pa.join(e,t),i=KJ.readFileSync(r,"utf8");return{cwd:e,filePath:r,content:i}},YJ=({ignore:t=[],cwd:e=sp(process.cwd())}={})=>({ignore:t,cwd:e});yx.exports=async t=>{t=YJ(t);let e=await UJ("**/.gitignore",{ignore:HJ.concat(t.ignore),cwd:t.cwd}),r=await Promise.all(e.map(n=>NQe(n,t.cwd))),i=GJ(r);return jJ(i,t.cwd)};yx.exports.sync=t=>{t=YJ(t);let r=UJ.sync("**/.gitignore",{ignore:HJ.concat(t.ignore),cwd:t.cwd}).map(n=>LQe(n,t.cwd)),i=GJ(r);return jJ(i,t.cwd)}});var VJ=E((Yit,JJ)=>{"use strict";var{Transform:TQe}=require("stream"),wx=class extends TQe{constructor(){super({objectMode:!0})}},WJ=class extends wx{constructor(e){super();this._filter=e}_transform(e,r,i){this._filter(e)&&this.push(e),i()}},zJ=class extends wx{constructor(){super();this._pushed=new Set}_transform(e,r,i){this._pushed.has(e)||(this.push(e),this._pushed.add(e)),i()}};JJ.exports={FilterStream:WJ,UniqueStream:zJ}});var vx=E((qit,Ul)=>{"use strict";var _J=require("fs"),hy=QY(),MQe=wS(),py=gy(),dy=xJ(),Bx=qJ(),{FilterStream:OQe,UniqueStream:KQe}=VJ(),XJ=()=>!1,ZJ=t=>t[0]==="!",UQe=t=>{if(!t.every(e=>typeof e=="string"))throw new TypeError("Patterns must be a string or an array of strings")},HQe=(t={})=>{if(!t.cwd)return;let e;try{e=_J.statSync(t.cwd)}catch{return}if(!e.isDirectory())throw new Error("The `cwd` option must be a path to a directory")},GQe=t=>t.stats instanceof _J.Stats?t.path:t,Cy=(t,e)=>{t=hy([].concat(t)),UQe(t),HQe(e);let r=[];e=P({ignore:[],expandDirectories:!0},e);for(let[i,n]of t.entries()){if(ZJ(n))continue;let s=t.slice(i).filter(a=>ZJ(a)).map(a=>a.slice(1)),o=_(P({},e),{ignore:e.ignore.concat(s)});r.push({pattern:n,options:o})}return r},jQe=(t,e)=>{let r={};return t.options.cwd&&(r.cwd=t.options.cwd),Array.isArray(t.options.expandDirectories)?r=_(P({},r),{files:t.options.expandDirectories}):typeof t.options.expandDirectories=="object"&&(r=P(P({},r),t.options.expandDirectories)),e(t.pattern,r)},Qx=(t,e)=>t.options.expandDirectories?jQe(t,e):[t.pattern],$J=t=>t&&t.gitignore?Bx.sync({cwd:t.cwd,ignore:t.ignore}):XJ,bx=t=>e=>{let{options:r}=t;return r.ignore&&Array.isArray(r.ignore)&&r.expandDirectories&&(r.ignore=dy.sync(r.ignore)),{pattern:e,options:r}};Ul.exports=async(t,e)=>{let r=Cy(t,e),i=async()=>e&&e.gitignore?Bx({cwd:e.cwd,ignore:e.ignore}):XJ,n=async()=>{let l=await Promise.all(r.map(async c=>{let u=await Qx(c,dy);return Promise.all(u.map(bx(c)))}));return hy(...l)},[s,o]=await Promise.all([i(),n()]),a=await Promise.all(o.map(l=>py(l.pattern,l.options)));return hy(...a).filter(l=>!s(GQe(l)))};Ul.exports.sync=(t,e)=>{let r=Cy(t,e),i=[];for(let o of r){let a=Qx(o,dy.sync).map(bx(o));i.push(...a)}let n=$J(e),s=[];for(let o of i)s=hy(s,py.sync(o.pattern,o.options));return s.filter(o=>!n(o))};Ul.exports.stream=(t,e)=>{let r=Cy(t,e),i=[];for(let a of r){let l=Qx(a,dy.sync).map(bx(a));i.push(...l)}let n=$J(e),s=new OQe(a=>!n(a)),o=new KQe;return MQe(i.map(a=>py.stream(a.pattern,a.options))).pipe(s).pipe(o)};Ul.exports.generateGlobTasks=Cy;Ul.exports.hasMagic=(t,e)=>[].concat(t).some(r=>py.isDynamicPattern(r,e));Ul.exports.gitignore=Bx});var Ca=E((da,Dy)=>{"use strict";Object.defineProperty(da,"__esModule",{value:!0});var A3=["Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Uint16Array","Int32Array","Uint32Array","Float32Array","Float64Array","BigInt64Array","BigUint64Array"];function ibe(t){return A3.includes(t)}var nbe=["Function","Generator","AsyncGenerator","GeneratorFunction","AsyncGeneratorFunction","AsyncFunction","Observable","Array","Buffer","Object","RegExp","Date","Error","Map","Set","WeakMap","WeakSet","ArrayBuffer","SharedArrayBuffer","DataView","Promise","URL","FormData","URLSearchParams","HTMLElement",...A3];function sbe(t){return nbe.includes(t)}var obe=["null","undefined","string","number","bigint","boolean","symbol"];function abe(t){return obe.includes(t)}function Hu(t){return e=>typeof e===t}var{toString:l3}=Object.prototype,mp=t=>{let e=l3.call(t).slice(8,-1);if(/HTML\w+Element/.test(e)&&j.domElement(t))return"HTMLElement";if(sbe(e))return e},er=t=>e=>mp(e)===t;function j(t){if(t===null)return"null";switch(typeof t){case"undefined":return"undefined";case"string":return"string";case"number":return"number";case"boolean":return"boolean";case"function":return"Function";case"bigint":return"bigint";case"symbol":return"symbol";default:}if(j.observable(t))return"Observable";if(j.array(t))return"Array";if(j.buffer(t))return"Buffer";let e=mp(t);if(e)return e;if(t instanceof String||t instanceof Boolean||t instanceof Number)throw new TypeError("Please don't use object wrappers for primitive types");return"Object"}j.undefined=Hu("undefined");j.string=Hu("string");var Abe=Hu("number");j.number=t=>Abe(t)&&!j.nan(t);j.bigint=Hu("bigint");j.function_=Hu("function");j.null_=t=>t===null;j.class_=t=>j.function_(t)&&t.toString().startsWith("class ");j.boolean=t=>t===!0||t===!1;j.symbol=Hu("symbol");j.numericString=t=>j.string(t)&&!j.emptyStringOrWhitespace(t)&&!Number.isNaN(Number(t));j.array=(t,e)=>Array.isArray(t)?j.function_(e)?t.every(e):!0:!1;j.buffer=t=>{var e,r,i,n;return(n=(i=(r=(e=t)===null||e===void 0?void 0:e.constructor)===null||r===void 0?void 0:r.isBuffer)===null||i===void 0?void 0:i.call(r,t))!==null&&n!==void 0?n:!1};j.nullOrUndefined=t=>j.null_(t)||j.undefined(t);j.object=t=>!j.null_(t)&&(typeof t=="object"||j.function_(t));j.iterable=t=>{var e;return j.function_((e=t)===null||e===void 0?void 0:e[Symbol.iterator])};j.asyncIterable=t=>{var e;return j.function_((e=t)===null||e===void 0?void 0:e[Symbol.asyncIterator])};j.generator=t=>j.iterable(t)&&j.function_(t.next)&&j.function_(t.throw);j.asyncGenerator=t=>j.asyncIterable(t)&&j.function_(t.next)&&j.function_(t.throw);j.nativePromise=t=>er("Promise")(t);var lbe=t=>{var e,r;return j.function_((e=t)===null||e===void 0?void 0:e.then)&&j.function_((r=t)===null||r===void 0?void 0:r.catch)};j.promise=t=>j.nativePromise(t)||lbe(t);j.generatorFunction=er("GeneratorFunction");j.asyncGeneratorFunction=t=>mp(t)==="AsyncGeneratorFunction";j.asyncFunction=t=>mp(t)==="AsyncFunction";j.boundFunction=t=>j.function_(t)&&!t.hasOwnProperty("prototype");j.regExp=er("RegExp");j.date=er("Date");j.error=er("Error");j.map=t=>er("Map")(t);j.set=t=>er("Set")(t);j.weakMap=t=>er("WeakMap")(t);j.weakSet=t=>er("WeakSet")(t);j.int8Array=er("Int8Array");j.uint8Array=er("Uint8Array");j.uint8ClampedArray=er("Uint8ClampedArray");j.int16Array=er("Int16Array");j.uint16Array=er("Uint16Array");j.int32Array=er("Int32Array");j.uint32Array=er("Uint32Array");j.float32Array=er("Float32Array");j.float64Array=er("Float64Array");j.bigInt64Array=er("BigInt64Array");j.bigUint64Array=er("BigUint64Array");j.arrayBuffer=er("ArrayBuffer");j.sharedArrayBuffer=er("SharedArrayBuffer");j.dataView=er("DataView");j.directInstanceOf=(t,e)=>Object.getPrototypeOf(t)===e.prototype;j.urlInstance=t=>er("URL")(t);j.urlString=t=>{if(!j.string(t))return!1;try{return new URL(t),!0}catch(e){return!1}};j.truthy=t=>Boolean(t);j.falsy=t=>!t;j.nan=t=>Number.isNaN(t);j.primitive=t=>j.null_(t)||abe(typeof t);j.integer=t=>Number.isInteger(t);j.safeInteger=t=>Number.isSafeInteger(t);j.plainObject=t=>{if(l3.call(t)!=="[object Object]")return!1;let e=Object.getPrototypeOf(t);return e===null||e===Object.getPrototypeOf({})};j.typedArray=t=>ibe(mp(t));var cbe=t=>j.safeInteger(t)&&t>=0;j.arrayLike=t=>!j.nullOrUndefined(t)&&!j.function_(t)&&cbe(t.length);j.inRange=(t,e)=>{if(j.number(e))return t>=Math.min(0,e)&&t<=Math.max(e,0);if(j.array(e)&&e.length===2)return t>=Math.min(...e)&&t<=Math.max(...e);throw new TypeError(`Invalid range: ${JSON.stringify(e)}`)};var ube=1,gbe=["innerHTML","ownerDocument","style","attributes","nodeValue"];j.domElement=t=>j.object(t)&&t.nodeType===ube&&j.string(t.nodeName)&&!j.plainObject(t)&&gbe.every(e=>e in t);j.observable=t=>{var e,r,i,n;return t?t===((r=(e=t)[Symbol.observable])===null||r===void 0?void 0:r.call(e))||t===((n=(i=t)["@@observable"])===null||n===void 0?void 0:n.call(i)):!1};j.nodeStream=t=>j.object(t)&&j.function_(t.pipe)&&!j.observable(t);j.infinite=t=>t===Infinity||t===-Infinity;var c3=t=>e=>j.integer(e)&&Math.abs(e%2)===t;j.evenInteger=c3(0);j.oddInteger=c3(1);j.emptyArray=t=>j.array(t)&&t.length===0;j.nonEmptyArray=t=>j.array(t)&&t.length>0;j.emptyString=t=>j.string(t)&&t.length===0;j.nonEmptyString=t=>j.string(t)&&t.length>0;var fbe=t=>j.string(t)&&!/\S/.test(t);j.emptyStringOrWhitespace=t=>j.emptyString(t)||fbe(t);j.emptyObject=t=>j.object(t)&&!j.map(t)&&!j.set(t)&&Object.keys(t).length===0;j.nonEmptyObject=t=>j.object(t)&&!j.map(t)&&!j.set(t)&&Object.keys(t).length>0;j.emptySet=t=>j.set(t)&&t.size===0;j.nonEmptySet=t=>j.set(t)&&t.size>0;j.emptyMap=t=>j.map(t)&&t.size===0;j.nonEmptyMap=t=>j.map(t)&&t.size>0;j.propertyKey=t=>j.any([j.string,j.number,j.symbol],t);j.formData=t=>er("FormData")(t);j.urlSearchParams=t=>er("URLSearchParams")(t);var u3=(t,e,r)=>{if(!j.function_(e))throw new TypeError(`Invalid predicate: ${JSON.stringify(e)}`);if(r.length===0)throw new TypeError("Invalid number of values");return t.call(r,e)};j.any=(t,...e)=>(j.array(t)?t:[t]).some(i=>u3(Array.prototype.some,i,e));j.all=(t,...e)=>u3(Array.prototype.every,t,e);var Te=(t,e,r,i={})=>{if(!t){let{multipleValues:n}=i,s=n?`received values of types ${[...new Set(r.map(o=>`\`${j(o)}\``))].join(", ")}`:`received value of type \`${j(r)}\``;throw new TypeError(`Expected value which is \`${e}\`, ${s}.`)}};da.assert={undefined:t=>Te(j.undefined(t),"undefined",t),string:t=>Te(j.string(t),"string",t),number:t=>Te(j.number(t),"number",t),bigint:t=>Te(j.bigint(t),"bigint",t),function_:t=>Te(j.function_(t),"Function",t),null_:t=>Te(j.null_(t),"null",t),class_:t=>Te(j.class_(t),"Class",t),boolean:t=>Te(j.boolean(t),"boolean",t),symbol:t=>Te(j.symbol(t),"symbol",t),numericString:t=>Te(j.numericString(t),"string with a number",t),array:(t,e)=>{Te(j.array(t),"Array",t),e&&t.forEach(e)},buffer:t=>Te(j.buffer(t),"Buffer",t),nullOrUndefined:t=>Te(j.nullOrUndefined(t),"null or undefined",t),object:t=>Te(j.object(t),"Object",t),iterable:t=>Te(j.iterable(t),"Iterable",t),asyncIterable:t=>Te(j.asyncIterable(t),"AsyncIterable",t),generator:t=>Te(j.generator(t),"Generator",t),asyncGenerator:t=>Te(j.asyncGenerator(t),"AsyncGenerator",t),nativePromise:t=>Te(j.nativePromise(t),"native Promise",t),promise:t=>Te(j.promise(t),"Promise",t),generatorFunction:t=>Te(j.generatorFunction(t),"GeneratorFunction",t),asyncGeneratorFunction:t=>Te(j.asyncGeneratorFunction(t),"AsyncGeneratorFunction",t),asyncFunction:t=>Te(j.asyncFunction(t),"AsyncFunction",t),boundFunction:t=>Te(j.boundFunction(t),"Function",t),regExp:t=>Te(j.regExp(t),"RegExp",t),date:t=>Te(j.date(t),"Date",t),error:t=>Te(j.error(t),"Error",t),map:t=>Te(j.map(t),"Map",t),set:t=>Te(j.set(t),"Set",t),weakMap:t=>Te(j.weakMap(t),"WeakMap",t),weakSet:t=>Te(j.weakSet(t),"WeakSet",t),int8Array:t=>Te(j.int8Array(t),"Int8Array",t),uint8Array:t=>Te(j.uint8Array(t),"Uint8Array",t),uint8ClampedArray:t=>Te(j.uint8ClampedArray(t),"Uint8ClampedArray",t),int16Array:t=>Te(j.int16Array(t),"Int16Array",t),uint16Array:t=>Te(j.uint16Array(t),"Uint16Array",t),int32Array:t=>Te(j.int32Array(t),"Int32Array",t),uint32Array:t=>Te(j.uint32Array(t),"Uint32Array",t),float32Array:t=>Te(j.float32Array(t),"Float32Array",t),float64Array:t=>Te(j.float64Array(t),"Float64Array",t),bigInt64Array:t=>Te(j.bigInt64Array(t),"BigInt64Array",t),bigUint64Array:t=>Te(j.bigUint64Array(t),"BigUint64Array",t),arrayBuffer:t=>Te(j.arrayBuffer(t),"ArrayBuffer",t),sharedArrayBuffer:t=>Te(j.sharedArrayBuffer(t),"SharedArrayBuffer",t),dataView:t=>Te(j.dataView(t),"DataView",t),urlInstance:t=>Te(j.urlInstance(t),"URL",t),urlString:t=>Te(j.urlString(t),"string with a URL",t),truthy:t=>Te(j.truthy(t),"truthy",t),falsy:t=>Te(j.falsy(t),"falsy",t),nan:t=>Te(j.nan(t),"NaN",t),primitive:t=>Te(j.primitive(t),"primitive",t),integer:t=>Te(j.integer(t),"integer",t),safeInteger:t=>Te(j.safeInteger(t),"integer",t),plainObject:t=>Te(j.plainObject(t),"plain object",t),typedArray:t=>Te(j.typedArray(t),"TypedArray",t),arrayLike:t=>Te(j.arrayLike(t),"array-like",t),domElement:t=>Te(j.domElement(t),"HTMLElement",t),observable:t=>Te(j.observable(t),"Observable",t),nodeStream:t=>Te(j.nodeStream(t),"Node.js Stream",t),infinite:t=>Te(j.infinite(t),"infinite number",t),emptyArray:t=>Te(j.emptyArray(t),"empty array",t),nonEmptyArray:t=>Te(j.nonEmptyArray(t),"non-empty array",t),emptyString:t=>Te(j.emptyString(t),"empty string",t),nonEmptyString:t=>Te(j.nonEmptyString(t),"non-empty string",t),emptyStringOrWhitespace:t=>Te(j.emptyStringOrWhitespace(t),"empty string or whitespace",t),emptyObject:t=>Te(j.emptyObject(t),"empty object",t),nonEmptyObject:t=>Te(j.nonEmptyObject(t),"non-empty object",t),emptySet:t=>Te(j.emptySet(t),"empty set",t),nonEmptySet:t=>Te(j.nonEmptySet(t),"non-empty set",t),emptyMap:t=>Te(j.emptyMap(t),"empty map",t),nonEmptyMap:t=>Te(j.nonEmptyMap(t),"non-empty map",t),propertyKey:t=>Te(j.propertyKey(t),"PropertyKey",t),formData:t=>Te(j.formData(t),"FormData",t),urlSearchParams:t=>Te(j.urlSearchParams(t),"URLSearchParams",t),evenInteger:t=>Te(j.evenInteger(t),"even integer",t),oddInteger:t=>Te(j.oddInteger(t),"odd integer",t),directInstanceOf:(t,e)=>Te(j.directInstanceOf(t,e),"T",t),inRange:(t,e)=>Te(j.inRange(t,e),"in range",t),any:(t,...e)=>Te(j.any(t,...e),"predicate returns truthy for any value",e,{multipleValues:!0}),all:(t,...e)=>Te(j.all(t,...e),"predicate returns truthy for all values",e,{multipleValues:!0})};Object.defineProperties(j,{class:{value:j.class_},function:{value:j.function_},null:{value:j.null_}});Object.defineProperties(da.assert,{class:{value:da.assert.class_},function:{value:da.assert.function_},null:{value:da.assert.null_}});da.default=j;Dy.exports=j;Dy.exports.default=j;Dy.exports.assert=da.assert});var g3=E((gnt,Ux)=>{"use strict";var Hx=class extends Error{constructor(e){super(e||"Promise was canceled");this.name="CancelError"}get isCanceled(){return!0}},Ep=class{static fn(e){return(...r)=>new Ep((i,n,s)=>{r.push(s),e(...r).then(i,n)})}constructor(e){this._cancelHandlers=[],this._isPending=!0,this._isCanceled=!1,this._rejectOnCancel=!0,this._promise=new Promise((r,i)=>{this._reject=i;let n=a=>{this._isPending=!1,r(a)},s=a=>{this._isPending=!1,i(a)},o=a=>{if(!this._isPending)throw new Error("The `onCancel` handler was attached after the promise settled.");this._cancelHandlers.push(a)};return Object.defineProperties(o,{shouldReject:{get:()=>this._rejectOnCancel,set:a=>{this._rejectOnCancel=a}}}),e(n,s,o)})}then(e,r){return this._promise.then(e,r)}catch(e){return this._promise.catch(e)}finally(e){return this._promise.finally(e)}cancel(e){if(!(!this._isPending||this._isCanceled)){if(this._cancelHandlers.length>0)try{for(let r of this._cancelHandlers)r()}catch(r){this._reject(r)}this._isCanceled=!0,this._rejectOnCancel&&this._reject(new Hx(e))}}get isCanceled(){return this._isCanceled}};Object.setPrototypeOf(Ep.prototype,Promise.prototype);Ux.exports=Ep;Ux.exports.CancelError=Hx});var f3=E((Gx,jx)=>{"use strict";Object.defineProperty(Gx,"__esModule",{value:!0});var hbe=require("tls"),Yx=(t,e)=>{let r;typeof e=="function"?r={connect:e}:r=e;let i=typeof r.connect=="function",n=typeof r.secureConnect=="function",s=typeof r.close=="function",o=()=>{i&&r.connect(),t instanceof hbe.TLSSocket&&n&&(t.authorized?r.secureConnect():t.authorizationError||t.once("secureConnect",r.secureConnect)),s&&t.once("close",r.close)};t.writable&&!t.connecting?o():t.connecting?t.once("connect",o):t.destroyed&&s&&r.close(t._hadError)};Gx.default=Yx;jx.exports=Yx;jx.exports.default=Yx});var h3=E((qx,Jx)=>{"use strict";Object.defineProperty(qx,"__esModule",{value:!0});var pbe=f3(),dbe=Number(process.versions.node.split(".")[0]),Wx=t=>{let e={start:Date.now(),socket:void 0,lookup:void 0,connect:void 0,secureConnect:void 0,upload:void 0,response:void 0,end:void 0,error:void 0,abort:void 0,phases:{wait:void 0,dns:void 0,tcp:void 0,tls:void 0,request:void 0,firstByte:void 0,download:void 0,total:void 0}};t.timings=e;let r=o=>{let a=o.emit.bind(o);o.emit=(l,...c)=>(l==="error"&&(e.error=Date.now(),e.phases.total=e.error-e.start,o.emit=a),a(l,...c))};r(t),t.prependOnceListener("abort",()=>{e.abort=Date.now(),(!e.response||dbe>=13)&&(e.phases.total=Date.now()-e.start)});let i=o=>{e.socket=Date.now(),e.phases.wait=e.socket-e.start;let a=()=>{e.lookup=Date.now(),e.phases.dns=e.lookup-e.socket};o.prependOnceListener("lookup",a),pbe.default(o,{connect:()=>{e.connect=Date.now(),e.lookup===void 0&&(o.removeListener("lookup",a),e.lookup=e.connect,e.phases.dns=e.lookup-e.socket),e.phases.tcp=e.connect-e.lookup},secureConnect:()=>{e.secureConnect=Date.now(),e.phases.tls=e.secureConnect-e.connect}})};t.socket?i(t.socket):t.prependOnceListener("socket",i);let n=()=>{var o;e.upload=Date.now(),e.phases.request=e.upload-(o=e.secureConnect,o!=null?o:e.connect)};return(()=>typeof t.writableFinished=="boolean"?t.writableFinished:t.finished&&t.outputSize===0&&(!t.socket||t.socket.writableLength===0))()?n():t.prependOnceListener("finish",n),t.prependOnceListener("response",o=>{e.response=Date.now(),e.phases.firstByte=e.response-e.upload,o.timings=e,r(o),o.prependOnceListener("end",()=>{e.end=Date.now(),e.phases.download=e.end-e.response,e.phases.total=e.end-e.start})}),e};qx.default=Wx;Jx.exports=Wx;Jx.exports.default=Wx});var y3=E((fnt,zx)=>{"use strict";var{V4MAPPED:Cbe,ADDRCONFIG:mbe,ALL:p3,promises:{Resolver:d3},lookup:Ebe}=require("dns"),{promisify:Vx}=require("util"),Ibe=require("os"),Gu=Symbol("cacheableLookupCreateConnection"),_x=Symbol("cacheableLookupInstance"),C3=Symbol("expires"),ybe=typeof p3=="number",m3=t=>{if(!(t&&typeof t.createConnection=="function"))throw new Error("Expected an Agent instance as the first argument")},wbe=t=>{for(let e of t)e.family!==6&&(e.address=`::ffff:${e.address}`,e.family=6)},E3=()=>{let t=!1,e=!1;for(let r of Object.values(Ibe.networkInterfaces()))for(let i of r)if(!i.internal&&(i.family==="IPv6"?e=!0:t=!0,t&&e))return{has4:t,has6:e};return{has4:t,has6:e}},Bbe=t=>Symbol.iterator in t,I3={ttl:!0},Qbe={all:!0},Xx=class{constructor({cache:e=new Map,maxTtl:r=Infinity,fallbackDuration:i=3600,errorTtl:n=.15,resolver:s=new d3,lookup:o=Ebe}={}){if(this.maxTtl=r,this.errorTtl=n,this._cache=e,this._resolver=s,this._dnsLookup=Vx(o),this._resolver instanceof d3?(this._resolve4=this._resolver.resolve4.bind(this._resolver),this._resolve6=this._resolver.resolve6.bind(this._resolver)):(this._resolve4=Vx(this._resolver.resolve4.bind(this._resolver)),this._resolve6=Vx(this._resolver.resolve6.bind(this._resolver))),this._iface=E3(),this._pending={},this._nextRemovalTime=!1,this._hostnamesToFallback=new Set,i<1)this._fallback=!1;else{this._fallback=!0;let a=setInterval(()=>{this._hostnamesToFallback.clear()},i*1e3);a.unref&&a.unref()}this.lookup=this.lookup.bind(this),this.lookupAsync=this.lookupAsync.bind(this)}set servers(e){this.clear(),this._resolver.setServers(e)}get servers(){return this._resolver.getServers()}lookup(e,r,i){if(typeof r=="function"?(i=r,r={}):typeof r=="number"&&(r={family:r}),!i)throw new Error("Callback must be a function.");this.lookupAsync(e,r).then(n=>{r.all?i(null,n):i(null,n.address,n.family,n.expires,n.ttl)},i)}async lookupAsync(e,r={}){typeof r=="number"&&(r={family:r});let i=await this.query(e);if(r.family===6){let n=i.filter(s=>s.family===6);r.hints&Cbe&&(ybe&&r.hints&p3||n.length===0)?wbe(i):i=n}else r.family===4&&(i=i.filter(n=>n.family===4));if(r.hints&mbe){let{_iface:n}=this;i=i.filter(s=>s.family===6?n.has6:n.has4)}if(i.length===0){let n=new Error(`cacheableLookup ENOTFOUND ${e}`);throw n.code="ENOTFOUND",n.hostname=e,n}return r.all?i:i[0]}async query(e){let r=await this._cache.get(e);if(!r){let i=this._pending[e];if(i)r=await i;else{let n=this.queryAndCache(e);this._pending[e]=n,r=await n}}return r=r.map(i=>P({},i)),r}async _resolve(e){let r=async c=>{try{return await c}catch(u){if(u.code==="ENODATA"||u.code==="ENOTFOUND")return[];throw u}},[i,n]=await Promise.all([this._resolve4(e,I3),this._resolve6(e,I3)].map(c=>r(c))),s=0,o=0,a=0,l=Date.now();for(let c of i)c.family=4,c.expires=l+c.ttl*1e3,s=Math.max(s,c.ttl);for(let c of n)c.family=6,c.expires=l+c.ttl*1e3,o=Math.max(o,c.ttl);return i.length>0?n.length>0?a=Math.min(s,o):a=s:a=o,{entries:[...i,...n],cacheTtl:a}}async _lookup(e){try{return{entries:await this._dnsLookup(e,{all:!0}),cacheTtl:0}}catch(r){return{entries:[],cacheTtl:0}}}async _set(e,r,i){if(this.maxTtl>0&&i>0){i=Math.min(i,this.maxTtl)*1e3,r[C3]=Date.now()+i;try{await this._cache.set(e,r,i)}catch(n){this.lookupAsync=async()=>{let s=new Error("Cache Error. Please recreate the CacheableLookup instance.");throw s.cause=n,s}}Bbe(this._cache)&&this._tick(i)}}async queryAndCache(e){if(this._hostnamesToFallback.has(e))return this._dnsLookup(e,Qbe);try{let r=await this._resolve(e);r.entries.length===0&&this._fallback&&(r=await this._lookup(e),r.entries.length!==0&&this._hostnamesToFallback.add(e));let i=r.entries.length===0?this.errorTtl:r.cacheTtl;return await this._set(e,r.entries,i),delete this._pending[e],r.entries}catch(r){throw delete this._pending[e],r}}_tick(e){let r=this._nextRemovalTime;(!r||e{this._nextRemovalTime=!1;let i=Infinity,n=Date.now();for(let[s,o]of this._cache){let a=o[C3];n>=a?this._cache.delete(s):a("lookup"in r||(r.lookup=this.lookup),e[Gu](r,i))}uninstall(e){if(m3(e),e[Gu]){if(e[_x]!==this)throw new Error("The agent is not owned by this CacheableLookup instance");e.createConnection=e[Gu],delete e[Gu],delete e[_x]}}updateInterfaceInfo(){let{_iface:e}=this;this._iface=E3(),(e.has4&&!this._iface.has4||e.has6&&!this._iface.has6)&&this._cache.clear()}clear(e){if(e){this._cache.delete(e);return}this._cache.clear()}};zx.exports=Xx;zx.exports.default=Xx});var Q3=E((hnt,Zx)=>{"use strict";var bbe=typeof URL=="undefined"?require("url").URL:URL,vbe="text/plain",Sbe="us-ascii",w3=(t,e)=>e.some(r=>r instanceof RegExp?r.test(t):r===t),xbe=(t,{stripHash:e})=>{let r=t.match(/^data:([^,]*?),([^#]*?)(?:#(.*))?$/);if(!r)throw new Error(`Invalid URL: ${t}`);let i=r[1].split(";"),n=r[2],s=e?"":r[3],o=!1;i[i.length-1]==="base64"&&(i.pop(),o=!0);let a=(i.shift()||"").toLowerCase(),c=[...i.map(u=>{let[g,f=""]=u.split("=").map(h=>h.trim());return g==="charset"&&(f=f.toLowerCase(),f===Sbe)?"":`${g}${f?`=${f}`:""}`}).filter(Boolean)];return o&&c.push("base64"),(c.length!==0||a&&a!==vbe)&&c.unshift(a),`data:${c.join(";")},${o?n.trim():n}${s?`#${s}`:""}`},B3=(t,e)=>{if(e=P({defaultProtocol:"http:",normalizeProtocol:!0,forceHttp:!1,forceHttps:!1,stripAuthentication:!0,stripHash:!1,stripWWW:!0,removeQueryParameters:[/^utm_\w+/i],removeTrailingSlash:!0,removeDirectoryIndex:!1,sortQueryParameters:!0},e),Reflect.has(e,"normalizeHttps"))throw new Error("options.normalizeHttps is renamed to options.forceHttp");if(Reflect.has(e,"normalizeHttp"))throw new Error("options.normalizeHttp is renamed to options.forceHttps");if(Reflect.has(e,"stripFragment"))throw new Error("options.stripFragment is renamed to options.stripHash");if(t=t.trim(),/^data:/i.test(t))return xbe(t,e);let r=t.startsWith("//");!r&&/^\.*\//.test(t)||(t=t.replace(/^(?!(?:\w+:)?\/\/)|^\/\//,e.defaultProtocol));let n=new bbe(t);if(e.forceHttp&&e.forceHttps)throw new Error("The `forceHttp` and `forceHttps` options cannot be used together");if(e.forceHttp&&n.protocol==="https:"&&(n.protocol="http:"),e.forceHttps&&n.protocol==="http:"&&(n.protocol="https:"),e.stripAuthentication&&(n.username="",n.password=""),e.stripHash&&(n.hash=""),n.pathname&&(n.pathname=n.pathname.replace(/((?!:).|^)\/{2,}/g,(s,o)=>/^(?!\/)/g.test(o)?`${o}/`:"/")),n.pathname&&(n.pathname=decodeURI(n.pathname)),e.removeDirectoryIndex===!0&&(e.removeDirectoryIndex=[/^index\.[a-z]+$/]),Array.isArray(e.removeDirectoryIndex)&&e.removeDirectoryIndex.length>0){let s=n.pathname.split("/"),o=s[s.length-1];w3(o,e.removeDirectoryIndex)&&(s=s.slice(0,s.length-1),n.pathname=s.slice(1).join("/")+"/")}if(n.hostname&&(n.hostname=n.hostname.replace(/\.$/,""),e.stripWWW&&/^www\.([a-z\-\d]{2,63})\.([a-z.]{2,5})$/.test(n.hostname)&&(n.hostname=n.hostname.replace(/^www\./,""))),Array.isArray(e.removeQueryParameters))for(let s of[...n.searchParams.keys()])w3(s,e.removeQueryParameters)&&n.searchParams.delete(s);return e.sortQueryParameters&&n.searchParams.sort(),e.removeTrailingSlash&&(n.pathname=n.pathname.replace(/\/$/,"")),t=n.toString(),(e.removeTrailingSlash||n.pathname==="/")&&n.hash===""&&(t=t.replace(/\/$/,"")),r&&!e.normalizeProtocol&&(t=t.replace(/^http:\/\//,"//")),e.stripProtocol&&(t=t.replace(/^(?:https?:)?\/\//,"")),t};Zx.exports=B3;Zx.exports.default=B3});var S3=E((pnt,b3)=>{b3.exports=v3;function v3(t,e){if(t&&e)return v3(t)(e);if(typeof t!="function")throw new TypeError("need wrapper function");return Object.keys(t).forEach(function(i){r[i]=t[i]}),r;function r(){for(var i=new Array(arguments.length),n=0;n{var x3=S3();$x.exports=x3(Ry);$x.exports.strict=x3(k3);Ry.proto=Ry(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return Ry(this)},configurable:!0}),Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return k3(this)},configurable:!0})});function Ry(t){var e=function(){return e.called?e.value:(e.called=!0,e.value=t.apply(this,arguments))};return e.called=!1,e}function k3(t){var e=function(){if(e.called)throw new Error(e.onceError);return e.called=!0,e.value=t.apply(this,arguments)},r=t.name||"Function wrapped with `once`";return e.onceError=r+" shouldn't be called more than once",e.called=!1,e}});var tk=E((Cnt,P3)=>{var kbe=ek(),Pbe=function(){},Dbe=function(t){return t.setHeader&&typeof t.abort=="function"},Rbe=function(t){return t.stdio&&Array.isArray(t.stdio)&&t.stdio.length===3},D3=function(t,e,r){if(typeof e=="function")return D3(t,null,e);e||(e={}),r=kbe(r||Pbe);var i=t._writableState,n=t._readableState,s=e.readable||e.readable!==!1&&t.readable,o=e.writable||e.writable!==!1&&t.writable,a=function(){t.writable||l()},l=function(){o=!1,s||r.call(t)},c=function(){s=!1,o||r.call(t)},u=function(p){r.call(t,p?new Error("exited with error code: "+p):null)},g=function(p){r.call(t,p)},f=function(){if(s&&!(n&&n.ended))return r.call(t,new Error("premature close"));if(o&&!(i&&i.ended))return r.call(t,new Error("premature close"))},h=function(){t.req.on("finish",l)};return Dbe(t)?(t.on("complete",l),t.on("abort",f),t.req?h():t.on("request",h)):o&&!i&&(t.on("end",a),t.on("close",a)),Rbe(t)&&t.on("exit",u),t.on("end",c),t.on("finish",l),e.error!==!1&&t.on("error",g),t.on("close",f),function(){t.removeListener("complete",l),t.removeListener("abort",f),t.removeListener("request",h),t.req&&t.req.removeListener("finish",l),t.removeListener("end",a),t.removeListener("close",a),t.removeListener("finish",l),t.removeListener("exit",u),t.removeListener("end",c),t.removeListener("error",g),t.removeListener("close",f)}};P3.exports=D3});var N3=E((mnt,R3)=>{var Fbe=ek(),Nbe=tk(),rk=require("fs"),Ip=function(){},Lbe=/^v?\.0/.test(process.version),Fy=function(t){return typeof t=="function"},Tbe=function(t){return!Lbe||!rk?!1:(t instanceof(rk.ReadStream||Ip)||t instanceof(rk.WriteStream||Ip))&&Fy(t.close)},Mbe=function(t){return t.setHeader&&Fy(t.abort)},Obe=function(t,e,r,i){i=Fbe(i);var n=!1;t.on("close",function(){n=!0}),Nbe(t,{readable:e,writable:r},function(o){if(o)return i(o);n=!0,i()});var s=!1;return function(o){if(!n&&!s){if(s=!0,Tbe(t))return t.close(Ip);if(Mbe(t))return t.abort();if(Fy(t.destroy))return t.destroy();i(o||new Error("stream was destroyed"))}}},F3=function(t){t()},Kbe=function(t,e){return t.pipe(e)},Ube=function(){var t=Array.prototype.slice.call(arguments),e=Fy(t[t.length-1]||Ip)&&t.pop()||Ip;if(Array.isArray(t[0])&&(t=t[0]),t.length<2)throw new Error("pump requires two streams per minimum");var r,i=t.map(function(n,s){var o=s0;return Obe(n,o,a,function(l){r||(r=l),l&&i.forEach(F3),!o&&(i.forEach(F3),e(r))})});return t.reduce(Kbe)};R3.exports=Ube});var T3=E((Ent,L3)=>{"use strict";var{PassThrough:Hbe}=require("stream");L3.exports=t=>{t=P({},t);let{array:e}=t,{encoding:r}=t,i=r==="buffer",n=!1;e?n=!(r||i):r=r||"utf8",i&&(r=null);let s=new Hbe({objectMode:n});r&&s.setEncoding(r);let o=0,a=[];return s.on("data",l=>{a.push(l),n?o=a.length:o+=l.length}),s.getBufferedValue=()=>e?a:i?Buffer.concat(a,o):a.join(""),s.getBufferedLength=()=>o,s}});var M3=E((Int,ju)=>{"use strict";var Gbe=N3(),jbe=T3(),ik=class extends Error{constructor(){super("maxBuffer exceeded");this.name="MaxBufferError"}};async function Ny(t,e){if(!t)return Promise.reject(new Error("Expected a stream"));e=P({maxBuffer:Infinity},e);let{maxBuffer:r}=e,i;return await new Promise((n,s)=>{let o=a=>{a&&(a.bufferedData=i.getBufferedValue()),s(a)};i=Gbe(t,jbe(e),a=>{if(a){o(a);return}n()}),i.on("data",()=>{i.getBufferedLength()>r&&o(new ik)})}),i.getBufferedValue()}ju.exports=Ny;ju.exports.default=Ny;ju.exports.buffer=(t,e)=>Ny(t,_(P({},e),{encoding:"buffer"}));ju.exports.array=(t,e)=>Ny(t,_(P({},e),{array:!0}));ju.exports.MaxBufferError=ik});var K3=E((wnt,O3)=>{"use strict";var Ybe=[200,203,204,206,300,301,404,405,410,414,501],qbe=[200,203,204,300,301,302,303,307,308,404,405,410,414,501],Jbe={date:!0,connection:!0,"keep-alive":!0,"proxy-authenticate":!0,"proxy-authorization":!0,te:!0,trailer:!0,"transfer-encoding":!0,upgrade:!0},Wbe={"content-length":!0,"content-encoding":!0,"transfer-encoding":!0,"content-range":!0};function nk(t){let e={};if(!t)return e;let r=t.trim().split(/\s*,\s*/);for(let i of r){let[n,s]=i.split(/\s*=\s*/,2);e[n]=s===void 0?!0:s.replace(/^"|"$/g,"")}return e}function zbe(t){let e=[];for(let r in t){let i=t[r];e.push(i===!0?r:r+"="+i)}if(!!e.length)return e.join(", ")}O3.exports=class{constructor(e,r,{shared:i,cacheHeuristic:n,immutableMinTimeToLive:s,ignoreCargoCult:o,trustServerDate:a,_fromObject:l}={}){if(l){this._fromObject(l);return}if(!r||!r.headers)throw Error("Response headers missing");this._assertRequestHasHeaders(e),this._responseTime=this.now(),this._isShared=i!==!1,this._trustServerDate=a!==void 0?a:!0,this._cacheHeuristic=n!==void 0?n:.1,this._immutableMinTtl=s!==void 0?s:24*3600*1e3,this._status="status"in r?r.status:200,this._resHeaders=r.headers,this._rescc=nk(r.headers["cache-control"]),this._method="method"in e?e.method:"GET",this._url=e.url,this._host=e.headers.host,this._noAuthorization=!e.headers.authorization,this._reqHeaders=r.headers.vary?e.headers:null,this._reqcc=nk(e.headers["cache-control"]),o&&"pre-check"in this._rescc&&"post-check"in this._rescc&&(delete this._rescc["pre-check"],delete this._rescc["post-check"],delete this._rescc["no-cache"],delete this._rescc["no-store"],delete this._rescc["must-revalidate"],this._resHeaders=Object.assign({},this._resHeaders,{"cache-control":zbe(this._rescc)}),delete this._resHeaders.expires,delete this._resHeaders.pragma),!r.headers["cache-control"]&&/no-cache/.test(r.headers.pragma)&&(this._rescc["no-cache"]=!0)}now(){return Date.now()}storable(){return!!(!this._reqcc["no-store"]&&(this._method==="GET"||this._method==="HEAD"||this._method==="POST"&&this._hasExplicitExpiration())&&qbe.indexOf(this._status)!==-1&&!this._rescc["no-store"]&&(!this._isShared||!this._rescc.private)&&(!this._isShared||this._noAuthorization||this._allowsStoringAuthenticated())&&(this._resHeaders.expires||this._rescc.public||this._rescc["max-age"]||this._rescc["s-maxage"]||Ybe.indexOf(this._status)!==-1))}_hasExplicitExpiration(){return this._isShared&&this._rescc["s-maxage"]||this._rescc["max-age"]||this._resHeaders.expires}_assertRequestHasHeaders(e){if(!e||!e.headers)throw Error("Request headers missing")}satisfiesWithoutRevalidation(e){this._assertRequestHasHeaders(e);let r=nk(e.headers["cache-control"]);return r["no-cache"]||/no-cache/.test(e.headers.pragma)||r["max-age"]&&this.age()>r["max-age"]||r["min-fresh"]&&this.timeToLive()<1e3*r["min-fresh"]||this.stale()&&!(r["max-stale"]&&!this._rescc["must-revalidate"]&&(r["max-stale"]===!0||r["max-stale"]>this.age()-this.maxAge()))?!1:this._requestMatches(e,!1)}_requestMatches(e,r){return(!this._url||this._url===e.url)&&this._host===e.headers.host&&(!e.method||this._method===e.method||r&&e.method==="HEAD")&&this._varyMatches(e)}_allowsStoringAuthenticated(){return this._rescc["must-revalidate"]||this._rescc.public||this._rescc["s-maxage"]}_varyMatches(e){if(!this._resHeaders.vary)return!0;if(this._resHeaders.vary==="*")return!1;let r=this._resHeaders.vary.trim().toLowerCase().split(/\s*,\s*/);for(let i of r)if(e.headers[i]!==this._reqHeaders[i])return!1;return!0}_copyWithoutHopByHopHeaders(e){let r={};for(let i in e)Jbe[i]||(r[i]=e[i]);if(e.connection){let i=e.connection.trim().split(/\s*,\s*/);for(let n of i)delete r[n]}if(r.warning){let i=r.warning.split(/,/).filter(n=>!/^\s*1[0-9][0-9]/.test(n));i.length?r.warning=i.join(",").trim():delete r.warning}return r}responseHeaders(){let e=this._copyWithoutHopByHopHeaders(this._resHeaders),r=this.age();return r>3600*24&&!this._hasExplicitExpiration()&&this.maxAge()>3600*24&&(e.warning=(e.warning?`${e.warning}, `:"")+'113 - "rfc7234 5.5.4"'),e.age=`${Math.round(r)}`,e.date=new Date(this.now()).toUTCString(),e}date(){return this._trustServerDate?this._serverDate():this._responseTime}_serverDate(){let e=Date.parse(this._resHeaders.date);if(isFinite(e)){let r=8*3600*1e3;if(Math.abs(this._responseTime-e)e&&(e=i)}let r=(this.now()-this._responseTime)/1e3;return e+r}_ageValue(){let e=parseInt(this._resHeaders.age);return isFinite(e)?e:0}maxAge(){if(!this.storable()||this._rescc["no-cache"]||this._isShared&&this._resHeaders["set-cookie"]&&!this._rescc.public&&!this._rescc.immutable||this._resHeaders.vary==="*")return 0;if(this._isShared){if(this._rescc["proxy-revalidate"])return 0;if(this._rescc["s-maxage"])return parseInt(this._rescc["s-maxage"],10)}if(this._rescc["max-age"])return parseInt(this._rescc["max-age"],10);let e=this._rescc.immutable?this._immutableMinTtl:0,r=this._serverDate();if(this._resHeaders.expires){let i=Date.parse(this._resHeaders.expires);return Number.isNaN(i)||ii)return Math.max(e,(r-i)/1e3*this._cacheHeuristic)}return e}timeToLive(){return Math.max(0,this.maxAge()-this.age())*1e3}stale(){return this.maxAge()<=this.age()}static fromObject(e){return new this(void 0,void 0,{_fromObject:e})}_fromObject(e){if(this._responseTime)throw Error("Reinitialized");if(!e||e.v!==1)throw Error("Invalid serialization");this._responseTime=e.t,this._isShared=e.sh,this._cacheHeuristic=e.ch,this._immutableMinTtl=e.imm!==void 0?e.imm:24*3600*1e3,this._status=e.st,this._resHeaders=e.resh,this._rescc=e.rescc,this._method=e.m,this._url=e.u,this._host=e.h,this._noAuthorization=e.a,this._reqHeaders=e.reqh,this._reqcc=e.reqcc}toObject(){return{v:1,t:this._responseTime,sh:this._isShared,ch:this._cacheHeuristic,imm:this._immutableMinTtl,st:this._status,resh:this._resHeaders,rescc:this._rescc,m:this._method,u:this._url,h:this._host,a:this._noAuthorization,reqh:this._reqHeaders,reqcc:this._reqcc}}revalidationHeaders(e){this._assertRequestHasHeaders(e);let r=this._copyWithoutHopByHopHeaders(e.headers);if(delete r["if-range"],!this._requestMatches(e,!0)||!this.storable())return delete r["if-none-match"],delete r["if-modified-since"],r;if(this._resHeaders.etag&&(r["if-none-match"]=r["if-none-match"]?`${r["if-none-match"]}, ${this._resHeaders.etag}`:this._resHeaders.etag),r["accept-ranges"]||r["if-match"]||r["if-unmodified-since"]||this._method&&this._method!="GET"){if(delete r["if-modified-since"],r["if-none-match"]){let n=r["if-none-match"].split(/,/).filter(s=>!/^\s*W\//.test(s));n.length?r["if-none-match"]=n.join(",").trim():delete r["if-none-match"]}}else this._resHeaders["last-modified"]&&!r["if-modified-since"]&&(r["if-modified-since"]=this._resHeaders["last-modified"]);return r}revalidatedPolicy(e,r){if(this._assertRequestHasHeaders(e),!r||!r.headers)throw Error("Response headers missing");let i=!1;if(r.status!==void 0&&r.status!=304?i=!1:r.headers.etag&&!/^\s*W\//.test(r.headers.etag)?i=this._resHeaders.etag&&this._resHeaders.etag.replace(/^\s*W\//,"")===r.headers.etag:this._resHeaders.etag&&r.headers.etag?i=this._resHeaders.etag.replace(/^\s*W\//,"")===r.headers.etag.replace(/^\s*W\//,""):this._resHeaders["last-modified"]?i=this._resHeaders["last-modified"]===r.headers["last-modified"]:!this._resHeaders.etag&&!this._resHeaders["last-modified"]&&!r.headers.etag&&!r.headers["last-modified"]&&(i=!0),!i)return{policy:new this.constructor(e,r),modified:r.status!=304,matches:!1};let n={};for(let o in this._resHeaders)n[o]=o in r.headers&&!Wbe[o]?r.headers[o]:this._resHeaders[o];let s=Object.assign({},r,{status:this._status,method:this._method,headers:n});return{policy:new this.constructor(e,s,{shared:this._isShared,cacheHeuristic:this._cacheHeuristic,immutableMinTimeToLive:this._immutableMinTtl,trustServerDate:this._trustServerDate}),modified:!1,matches:!0}}}});var Ly=E((Bnt,U3)=>{"use strict";U3.exports=t=>{let e={};for(let[r,i]of Object.entries(t))e[r.toLowerCase()]=i;return e}});var j3=E((Qnt,H3)=>{"use strict";var Vbe=require("stream").Readable,_be=Ly(),G3=class extends Vbe{constructor(e,r,i,n){if(typeof e!="number")throw new TypeError("Argument `statusCode` should be a number");if(typeof r!="object")throw new TypeError("Argument `headers` should be an object");if(!(i instanceof Buffer))throw new TypeError("Argument `body` should be a buffer");if(typeof n!="string")throw new TypeError("Argument `url` should be a string");super();this.statusCode=e,this.headers=_be(r),this.body=i,this.url=n}_read(){this.push(this.body),this.push(null)}};H3.exports=G3});var q3=E((bnt,Y3)=>{"use strict";var Xbe=["destroy","setTimeout","socket","headers","trailers","rawHeaders","statusCode","httpVersion","httpVersionMinor","httpVersionMajor","rawTrailers","statusMessage"];Y3.exports=(t,e)=>{let r=new Set(Object.keys(t).concat(Xbe));for(let i of r)i in e||(e[i]=typeof t[i]=="function"?t[i].bind(t):t[i])}});var W3=E((vnt,J3)=>{"use strict";var Zbe=require("stream").PassThrough,$be=q3(),eve=t=>{if(!(t&&t.pipe))throw new TypeError("Parameter `response` must be a response stream.");let e=new Zbe;return $be(t,e),t.pipe(e)};J3.exports=eve});var z3=E(sk=>{sk.stringify=function t(e){if(typeof e=="undefined")return e;if(e&&Buffer.isBuffer(e))return JSON.stringify(":base64:"+e.toString("base64"));if(e&&e.toJSON&&(e=e.toJSON()),e&&typeof e=="object"){var r="",i=Array.isArray(e);r=i?"[":"{";var n=!0;for(var s in e){var o=typeof e[s]=="function"||!i&&typeof e[s]=="undefined";Object.hasOwnProperty.call(e,s)&&!o&&(n||(r+=","),n=!1,i?e[s]==null?r+="null":r+=t(e[s]):e[s]!==void 0&&(r+=t(s)+":"+t(e[s])))}return r+=i?"]":"}",r}else return typeof e=="string"?JSON.stringify(/^:/.test(e)?":"+e:e):typeof e=="undefined"?"null":JSON.stringify(e)};sk.parse=function(t){return JSON.parse(t,function(e,r){return typeof r=="string"?/^:base64:/.test(r)?Buffer.from(r.substring(8),"base64"):/^:/.test(r)?r.substring(1):r:r})}});var Z3=E((xnt,V3)=>{"use strict";var tve=require("events"),_3=z3(),rve=t=>{let e={redis:"@keyv/redis",mongodb:"@keyv/mongo",mongo:"@keyv/mongo",sqlite:"@keyv/sqlite",postgresql:"@keyv/postgres",postgres:"@keyv/postgres",mysql:"@keyv/mysql"};if(t.adapter||t.uri){let r=t.adapter||/^[^:]*/.exec(t.uri)[0];return new(require(e[r]))(t)}return new Map},X3=class extends tve{constructor(e,r){super();if(this.opts=Object.assign({namespace:"keyv",serialize:_3.stringify,deserialize:_3.parse},typeof e=="string"?{uri:e}:e,r),!this.opts.store){let i=Object.assign({},this.opts);this.opts.store=rve(i)}typeof this.opts.store.on=="function"&&this.opts.store.on("error",i=>this.emit("error",i)),this.opts.store.namespace=this.opts.namespace}_getKeyPrefix(e){return`${this.opts.namespace}:${e}`}get(e,r){e=this._getKeyPrefix(e);let{store:i}=this.opts;return Promise.resolve().then(()=>i.get(e)).then(n=>typeof n=="string"?this.opts.deserialize(n):n).then(n=>{if(n!==void 0){if(typeof n.expires=="number"&&Date.now()>n.expires){this.delete(e);return}return r&&r.raw?n:n.value}})}set(e,r,i){e=this._getKeyPrefix(e),typeof i=="undefined"&&(i=this.opts.ttl),i===0&&(i=void 0);let{store:n}=this.opts;return Promise.resolve().then(()=>{let s=typeof i=="number"?Date.now()+i:null;return r={value:r,expires:s},this.opts.serialize(r)}).then(s=>n.set(e,s,i)).then(()=>!0)}delete(e){e=this._getKeyPrefix(e);let{store:r}=this.opts;return Promise.resolve().then(()=>r.delete(e))}clear(){let{store:e}=this.opts;return Promise.resolve().then(()=>e.clear())}};V3.exports=X3});var tW=E((knt,$3)=>{"use strict";var ive=require("events"),Ty=require("url"),nve=Q3(),sve=M3(),ok=K3(),eW=j3(),ove=Ly(),ave=W3(),Ave=Z3(),yo=class{constructor(e,r){if(typeof e!="function")throw new TypeError("Parameter `request` must be a function");return this.cache=new Ave({uri:typeof r=="string"&&r,store:typeof r!="string"&&r,namespace:"cacheable-request"}),this.createCacheableRequest(e)}createCacheableRequest(e){return(r,i)=>{let n;if(typeof r=="string")n=ak(Ty.parse(r)),r={};else if(r instanceof Ty.URL)n=ak(Ty.parse(r.toString())),r={};else{let[g,...f]=(r.path||"").split("?"),h=f.length>0?`?${f.join("?")}`:"";n=ak(_(P({},r),{pathname:g,search:h}))}r=P(P({headers:{},method:"GET",cache:!0,strictTtl:!1,automaticFailover:!1},r),lve(n)),r.headers=ove(r.headers);let s=new ive,o=nve(Ty.format(n),{stripWWW:!1,removeTrailingSlash:!1,stripAuthentication:!1}),a=`${r.method}:${o}`,l=!1,c=!1,u=g=>{c=!0;let f=!1,h,p=new Promise(m=>{h=()=>{f||(f=!0,m())}}),d=m=>{if(l&&!g.forceRefresh){m.status=m.statusCode;let B=ok.fromObject(l.cachePolicy).revalidatedPolicy(g,m);if(!B.modified){let b=B.policy.responseHeaders();m=new eW(l.statusCode,b,l.body,l.url),m.cachePolicy=B.policy,m.fromCache=!0}}m.fromCache||(m.cachePolicy=new ok(g,m,g),m.fromCache=!1);let I;g.cache&&m.cachePolicy.storable()?(I=ave(m),(async()=>{try{let B=sve.buffer(m);if(await Promise.race([p,new Promise(L=>m.once("end",L))]),f)return;let b=await B,R={cachePolicy:m.cachePolicy.toObject(),url:m.url,statusCode:m.fromCache?l.statusCode:m.statusCode,body:b},H=g.strictTtl?m.cachePolicy.timeToLive():void 0;g.maxTtl&&(H=H?Math.min(H,g.maxTtl):g.maxTtl),await this.cache.set(a,R,H)}catch(B){s.emit("error",new yo.CacheError(B))}})()):g.cache&&l&&(async()=>{try{await this.cache.delete(a)}catch(B){s.emit("error",new yo.CacheError(B))}})(),s.emit("response",I||m),typeof i=="function"&&i(I||m)};try{let m=e(g,d);m.once("error",h),m.once("abort",h),s.emit("request",m)}catch(m){s.emit("error",new yo.RequestError(m))}};return(async()=>{let g=async h=>{await Promise.resolve();let p=h.cache?await this.cache.get(a):void 0;if(typeof p=="undefined")return u(h);let d=ok.fromObject(p.cachePolicy);if(d.satisfiesWithoutRevalidation(h)&&!h.forceRefresh){let m=d.responseHeaders(),I=new eW(p.statusCode,m,p.body,p.url);I.cachePolicy=d,I.fromCache=!0,s.emit("response",I),typeof i=="function"&&i(I)}else l=p,h.headers=d.revalidationHeaders(h),u(h)},f=h=>s.emit("error",new yo.CacheError(h));this.cache.once("error",f),s.on("response",()=>this.cache.removeListener("error",f));try{await g(r)}catch(h){r.automaticFailover&&!c&&u(r),s.emit("error",new yo.CacheError(h))}})(),s}}};function lve(t){let e=P({},t);return e.path=`${t.pathname||"/"}${t.search||""}`,delete e.pathname,delete e.search,e}function ak(t){return{protocol:t.protocol,auth:t.auth,hostname:t.hostname||t.host||"localhost",port:t.port,pathname:t.pathname,search:t.search}}yo.RequestError=class extends Error{constructor(t){super(t.message);this.name="RequestError",Object.assign(this,t)}};yo.CacheError=class extends Error{constructor(t){super(t.message);this.name="CacheError",Object.assign(this,t)}};$3.exports=yo});var iW=E((Pnt,rW)=>{"use strict";var cve=["aborted","complete","headers","httpVersion","httpVersionMinor","httpVersionMajor","method","rawHeaders","rawTrailers","setTimeout","socket","statusCode","statusMessage","trailers","url"];rW.exports=(t,e)=>{if(e._readableState.autoDestroy)throw new Error("The second stream must have the `autoDestroy` option set to `false`");let r=new Set(Object.keys(t).concat(cve)),i={};for(let n of r)n in e||(i[n]={get(){let s=t[n];return typeof s=="function"?s.bind(t):s},set(s){t[n]=s},enumerable:!0,configurable:!1});return Object.defineProperties(e,i),t.once("aborted",()=>{e.destroy(),e.emit("aborted")}),t.once("close",()=>{t.complete&&e.readable?e.once("end",()=>{e.emit("close")}):e.emit("close")}),e}});var sW=E((Dnt,nW)=>{"use strict";var{Transform:uve,PassThrough:gve}=require("stream"),Ak=require("zlib"),fve=iW();nW.exports=t=>{let e=(t.headers["content-encoding"]||"").toLowerCase();if(!["gzip","deflate","br"].includes(e))return t;let r=e==="br";if(r&&typeof Ak.createBrotliDecompress!="function")return t.destroy(new Error("Brotli is not supported on Node.js < 12")),t;let i=!0,n=new uve({transform(a,l,c){i=!1,c(null,a)},flush(a){a()}}),s=new gve({autoDestroy:!1,destroy(a,l){t.destroy(),l(a)}}),o=r?Ak.createBrotliDecompress():Ak.createUnzip();return o.once("error",a=>{if(i&&!t.readable){s.end();return}s.destroy(a)}),fve(t,s),t.pipe(n).pipe(o).pipe(s),s}});var lk=E((Rnt,oW)=>{"use strict";var aW=class{constructor(e={}){if(!(e.maxSize&&e.maxSize>0))throw new TypeError("`maxSize` must be a number greater than 0");this.maxSize=e.maxSize,this.onEviction=e.onEviction,this.cache=new Map,this.oldCache=new Map,this._size=0}_set(e,r){if(this.cache.set(e,r),this._size++,this._size>=this.maxSize){if(this._size=0,typeof this.onEviction=="function")for(let[i,n]of this.oldCache.entries())this.onEviction(i,n);this.oldCache=this.cache,this.cache=new Map}}get(e){if(this.cache.has(e))return this.cache.get(e);if(this.oldCache.has(e)){let r=this.oldCache.get(e);return this.oldCache.delete(e),this._set(e,r),r}}set(e,r){return this.cache.has(e)?this.cache.set(e,r):this._set(e,r),this}has(e){return this.cache.has(e)||this.oldCache.has(e)}peek(e){if(this.cache.has(e))return this.cache.get(e);if(this.oldCache.has(e))return this.oldCache.get(e)}delete(e){let r=this.cache.delete(e);return r&&this._size--,this.oldCache.delete(e)||r}clear(){this.cache.clear(),this.oldCache.clear(),this._size=0}*keys(){for(let[e]of this)yield e}*values(){for(let[,e]of this)yield e}*[Symbol.iterator](){for(let e of this.cache)yield e;for(let e of this.oldCache){let[r]=e;this.cache.has(r)||(yield e)}}get size(){let e=0;for(let r of this.oldCache.keys())this.cache.has(r)||e++;return Math.min(this._size+e,this.maxSize)}};oW.exports=aW});var uk=E((Fnt,AW)=>{"use strict";var hve=require("events"),pve=require("tls"),dve=require("http2"),Cve=lk(),_i=Symbol("currentStreamsCount"),lW=Symbol("request"),ns=Symbol("cachedOriginSet"),Yu=Symbol("gracefullyClosing"),mve=["maxDeflateDynamicTableSize","maxSessionMemory","maxHeaderListPairs","maxOutstandingPings","maxReservedRemoteStreams","maxSendHeaderBlockLength","paddingStrategy","localAddress","path","rejectUnauthorized","minDHSize","ca","cert","clientCertEngine","ciphers","key","pfx","servername","minVersion","maxVersion","secureProtocol","crl","honorCipherOrder","ecdhCurve","dhparam","secureOptions","sessionIdContext"],Eve=(t,e,r)=>{let i=0,n=t.length;for(;i>>1;r(t[s],e)?i=s+1:n=s}return i},Ive=(t,e)=>t.remoteSettings.maxConcurrentStreams>e.remoteSettings.maxConcurrentStreams,ck=(t,e)=>{for(let r of t)r[ns].lengthe[ns].includes(i))&&r[_i]+e[_i]<=e.remoteSettings.maxConcurrentStreams&&cW(r)},yve=(t,e)=>{for(let r of t)e[ns].lengthr[ns].includes(i))&&e[_i]+r[_i]<=r.remoteSettings.maxConcurrentStreams&&cW(e)},uW=({agent:t,isFree:e})=>{let r={};for(let i in t.sessions){let s=t.sessions[i].filter(o=>{let a=o[ma.kCurrentStreamsCount]{t[Yu]=!0,t[_i]===0&&t.close()},ma=class extends hve{constructor({timeout:e=6e4,maxSessions:r=Infinity,maxFreeSessions:i=10,maxCachedTlsSessions:n=100}={}){super();this.sessions={},this.queue={},this.timeout=e,this.maxSessions=r,this.maxFreeSessions=i,this._freeSessionsCount=0,this._sessionsCount=0,this.settings={enablePush:!1},this.tlsSessionCache=new Cve({maxSize:n})}static normalizeOrigin(e,r){return typeof e=="string"&&(e=new URL(e)),r&&e.hostname!==r&&(e.hostname=r),e.origin}normalizeOptions(e){let r="";if(e)for(let i of mve)e[i]&&(r+=`:${e[i]}`);return r}_tryToCreateNewSession(e,r){if(!(e in this.queue)||!(r in this.queue[e]))return;let i=this.queue[e][r];this._sessionsCount{Array.isArray(i)?(i=[...i],n()):i=[{resolve:n,reject:s}];let o=this.normalizeOptions(r),a=ma.normalizeOrigin(e,r&&r.servername);if(a===void 0){for(let{reject:u}of i)u(new TypeError("The `origin` argument needs to be a string or an URL object"));return}if(o in this.sessions){let u=this.sessions[o],g=-1,f=-1,h;for(let p of u){let d=p.remoteSettings.maxConcurrentStreams;if(d=d||p[Yu]||p.destroyed)continue;h||(g=d),m>f&&(h=p,f=m)}}if(h){if(i.length!==1){for(let{reject:p}of i){let d=new Error(`Expected the length of listeners to be 1, got ${i.length}. +Please report this to https://github.com/szmarczak/http2-wrapper/`);p(d)}return}i[0].resolve(h);return}}if(o in this.queue){if(a in this.queue[o]){this.queue[o][a].listeners.push(...i),this._tryToCreateNewSession(o,a);return}}else this.queue[o]={};let l=()=>{o in this.queue&&this.queue[o][a]===c&&(delete this.queue[o][a],Object.keys(this.queue[o]).length===0&&delete this.queue[o])},c=()=>{let u=`${a}:${o}`,g=!1;try{let f=dve.connect(e,P({createConnection:this.createConnection,settings:this.settings,session:this.tlsSessionCache.get(u)},r));f[_i]=0,f[Yu]=!1;let h=()=>f[_i]{this.tlsSessionCache.set(u,m)}),f.once("error",m=>{for(let{reject:I}of i)I(m);this.tlsSessionCache.delete(u)}),f.setTimeout(this.timeout,()=>{f.destroy()}),f.once("close",()=>{if(g){p&&this._freeSessionsCount--,this._sessionsCount--;let m=this.sessions[o];m.splice(m.indexOf(f),1),m.length===0&&delete this.sessions[o]}else{let m=new Error("Session closed without receiving a SETTINGS frame");m.code="HTTP2WRAPPER_NOSETTINGS";for(let{reject:I}of i)I(m);l()}this._tryToCreateNewSession(o,a)});let d=()=>{if(!(!(o in this.queue)||!h())){for(let m of f[ns])if(m in this.queue[o]){let{listeners:I}=this.queue[o][m];for(;I.length!==0&&h();)I.shift().resolve(f);let B=this.queue[o];if(B[m].listeners.length===0&&(delete B[m],Object.keys(B).length===0)){delete this.queue[o];break}if(!h())break}}};f.on("origin",()=>{f[ns]=f.originSet,!!h()&&(d(),ck(this.sessions[o],f))}),f.once("remoteSettings",()=>{if(f.ref(),f.unref(),this._sessionsCount++,c.destroyed){let m=new Error("Agent has been destroyed");for(let I of i)I.reject(m);f.destroy();return}f[ns]=f.originSet;{let m=this.sessions;if(o in m){let I=m[o];I.splice(Eve(I,f,Ive),0,f)}else m[o]=[f]}this._freeSessionsCount+=1,g=!0,this.emit("session",f),d(),l(),f[_i]===0&&this._freeSessionsCount>this.maxFreeSessions&&f.close(),i.length!==0&&(this.getSession(a,r,i),i.length=0),f.on("remoteSettings",()=>{d(),ck(this.sessions[o],f)})}),f[lW]=f.request,f.request=(m,I)=>{if(f[Yu])throw new Error("The session is gracefully closing. No new streams are allowed.");let B=f[lW](m,I);return f.ref(),++f[_i],f[_i]===f.remoteSettings.maxConcurrentStreams&&this._freeSessionsCount--,B.once("close",()=>{if(p=h(),--f[_i],!f.destroyed&&!f.closed&&(yve(this.sessions[o],f),h()&&!f.closed)){p||(this._freeSessionsCount++,p=!0);let b=f[_i]===0;b&&f.unref(),b&&(this._freeSessionsCount>this.maxFreeSessions||f[Yu])?f.close():(ck(this.sessions[o],f),d())}}),B}}catch(f){for(let h of i)h.reject(f);l()}};c.listeners=i,c.completed=!1,c.destroyed=!1,this.queue[o][a]=c,this._tryToCreateNewSession(o,a)})}request(e,r,i,n){return new Promise((s,o)=>{this.getSession(e,r,[{reject:o,resolve:a=>{try{s(a.request(i,n))}catch(l){o(l)}}}])})}createConnection(e,r){return ma.connect(e,r)}static connect(e,r){r.ALPNProtocols=["h2"];let i=e.port||443,n=e.hostname||e.host;return typeof r.servername=="undefined"&&(r.servername=n),pve.connect(i,n,r)}closeFreeSessions(){for(let e of Object.values(this.sessions))for(let r of e)r[_i]===0&&r.close()}destroy(e){for(let r of Object.values(this.sessions))for(let i of r)i.destroy(e);for(let r of Object.values(this.queue))for(let i of Object.values(r))i.destroyed=!0;this.queue={}}get freeSessions(){return uW({agent:this,isFree:!0})}get busySessions(){return uW({agent:this,isFree:!1})}};ma.kCurrentStreamsCount=_i;ma.kGracefullyClosing=Yu;AW.exports={Agent:ma,globalAgent:new ma}});var gk=E((Nnt,gW)=>{"use strict";var{Readable:wve}=require("stream"),fW=class extends wve{constructor(e,r){super({highWaterMark:r,autoDestroy:!1});this.statusCode=null,this.statusMessage="",this.httpVersion="2.0",this.httpVersionMajor=2,this.httpVersionMinor=0,this.headers={},this.trailers={},this.req=null,this.aborted=!1,this.complete=!1,this.upgrade=null,this.rawHeaders=[],this.rawTrailers=[],this.socket=e,this.connection=e,this._dumped=!1}_destroy(e){this.req._request.destroy(e)}setTimeout(e,r){return this.req.setTimeout(e,r),this}_dump(){this._dumped||(this._dumped=!0,this.removeAllListeners("data"),this.resume())}_read(){this.req&&this.req._request.resume()}};gW.exports=fW});var fk=E((Lnt,hW)=>{"use strict";hW.exports=t=>{let e={protocol:t.protocol,hostname:typeof t.hostname=="string"&&t.hostname.startsWith("[")?t.hostname.slice(1,-1):t.hostname,host:t.host,hash:t.hash,search:t.search,pathname:t.pathname,href:t.href,path:`${t.pathname||""}${t.search||""}`};return typeof t.port=="string"&&t.port.length!==0&&(e.port=Number(t.port)),(t.username||t.password)&&(e.auth=`${t.username||""}:${t.password||""}`),e}});var dW=E((Tnt,pW)=>{"use strict";pW.exports=(t,e,r)=>{for(let i of r)t.on(i,(...n)=>e.emit(i,...n))}});var mW=E((Mnt,CW)=>{"use strict";CW.exports=t=>{switch(t){case":method":case":scheme":case":authority":case":path":return!0;default:return!1}}});var IW=E((Knt,EW)=>{"use strict";var qu=(t,e,r)=>{EW.exports[e]=class extends t{constructor(...n){super(typeof r=="string"?r:r(n));this.name=`${super.name} [${e}]`,this.code=e}}};qu(TypeError,"ERR_INVALID_ARG_TYPE",t=>{let e=t[0].includes(".")?"property":"argument",r=t[1],i=Array.isArray(r);return i&&(r=`${r.slice(0,-1).join(", ")} or ${r.slice(-1)}`),`The "${t[0]}" ${e} must be ${i?"one of":"of"} type ${r}. Received ${typeof t[2]}`});qu(TypeError,"ERR_INVALID_PROTOCOL",t=>`Protocol "${t[0]}" not supported. Expected "${t[1]}"`);qu(Error,"ERR_HTTP_HEADERS_SENT",t=>`Cannot ${t[0]} headers after they are sent to the client`);qu(TypeError,"ERR_INVALID_HTTP_TOKEN",t=>`${t[0]} must be a valid HTTP token [${t[1]}]`);qu(TypeError,"ERR_HTTP_INVALID_HEADER_VALUE",t=>`Invalid value "${t[0]} for header "${t[1]}"`);qu(TypeError,"ERR_INVALID_CHAR",t=>`Invalid character in ${t[0]} [${t[1]}]`)});var Ck=E((Unt,yW)=>{"use strict";var Bve=require("http2"),{Writable:Qve}=require("stream"),{Agent:wW,globalAgent:bve}=uk(),vve=gk(),Sve=fk(),xve=dW(),kve=mW(),{ERR_INVALID_ARG_TYPE:hk,ERR_INVALID_PROTOCOL:Pve,ERR_HTTP_HEADERS_SENT:BW,ERR_INVALID_HTTP_TOKEN:Dve,ERR_HTTP_INVALID_HEADER_VALUE:Rve,ERR_INVALID_CHAR:Fve}=IW(),{HTTP2_HEADER_STATUS:QW,HTTP2_HEADER_METHOD:bW,HTTP2_HEADER_PATH:vW,HTTP2_METHOD_CONNECT:Nve}=Bve.constants,Pi=Symbol("headers"),pk=Symbol("origin"),dk=Symbol("session"),SW=Symbol("options"),My=Symbol("flushedHeaders"),yp=Symbol("jobs"),Lve=/^[\^`\-\w!#$%&*+.|~]+$/,Tve=/[^\t\u0020-\u007E\u0080-\u00FF]/,xW=class extends Qve{constructor(e,r,i){super({autoDestroy:!1});let n=typeof e=="string"||e instanceof URL;if(n&&(e=Sve(e instanceof URL?e:new URL(e))),typeof r=="function"||r===void 0?(i=r,r=n?e:P({},e)):r=P(P({},e),r),r.h2session)this[dk]=r.h2session;else if(r.agent===!1)this.agent=new wW({maxFreeSessions:0});else if(typeof r.agent=="undefined"||r.agent===null)typeof r.createConnection=="function"?(this.agent=new wW({maxFreeSessions:0}),this.agent.createConnection=r.createConnection):this.agent=bve;else if(typeof r.agent.request=="function")this.agent=r.agent;else throw new hk("options.agent",["Agent-like Object","undefined","false"],r.agent);if(r.protocol&&r.protocol!=="https:")throw new Pve(r.protocol,"https:");let s=r.port||r.defaultPort||this.agent&&this.agent.defaultPort||443,o=r.hostname||r.host||"localhost";delete r.hostname,delete r.host,delete r.port;let{timeout:a}=r;if(r.timeout=void 0,this[Pi]=Object.create(null),this[yp]=[],this.socket=null,this.connection=null,this.method=r.method||"GET",this.path=r.path,this.res=null,this.aborted=!1,this.reusedSocket=!1,r.headers)for(let[l,c]of Object.entries(r.headers))this.setHeader(l,c);r.auth&&!("authorization"in this[Pi])&&(this[Pi].authorization="Basic "+Buffer.from(r.auth).toString("base64")),r.session=r.tlsSession,r.path=r.socketPath,this[SW]=r,s===443?(this[pk]=`https://${o}`,":authority"in this[Pi]||(this[Pi][":authority"]=o)):(this[pk]=`https://${o}:${s}`,":authority"in this[Pi]||(this[Pi][":authority"]=`${o}:${s}`)),a&&this.setTimeout(a),i&&this.once("response",i),this[My]=!1}get method(){return this[Pi][bW]}set method(e){e&&(this[Pi][bW]=e.toUpperCase())}get path(){return this[Pi][vW]}set path(e){e&&(this[Pi][vW]=e)}get _mustNotHaveABody(){return this.method==="GET"||this.method==="HEAD"||this.method==="DELETE"}_write(e,r,i){if(this._mustNotHaveABody){i(new Error("The GET, HEAD and DELETE methods must NOT have a body"));return}this.flushHeaders();let n=()=>this._request.write(e,r,i);this._request?n():this[yp].push(n)}_final(e){if(this.destroyed)return;this.flushHeaders();let r=()=>{if(this._mustNotHaveABody){e();return}this._request.end(e)};this._request?r():this[yp].push(r)}abort(){this.res&&this.res.complete||(this.aborted||process.nextTick(()=>this.emit("abort")),this.aborted=!0,this.destroy())}_destroy(e,r){this.res&&this.res._dump(),this._request&&this._request.destroy(),r(e)}async flushHeaders(){if(this[My]||this.destroyed)return;this[My]=!0;let e=this.method===Nve,r=i=>{if(this._request=i,this.destroyed){i.destroy();return}e||xve(i,this,["timeout","continue","close","error"]);let n=o=>(...a)=>{!this.writable&&!this.destroyed?o(...a):this.once("finish",()=>{o(...a)})};i.once("response",n((o,a,l)=>{let c=new vve(this.socket,i.readableHighWaterMark);this.res=c,c.req=this,c.statusCode=o[QW],c.headers=o,c.rawHeaders=l,c.once("end",()=>{this.aborted?(c.aborted=!0,c.emit("aborted")):(c.complete=!0,c.socket=null,c.connection=null)}),e?(c.upgrade=!0,this.emit("connect",c,i,Buffer.alloc(0))?this.emit("close"):i.destroy()):(i.on("data",u=>{!c._dumped&&!c.push(u)&&i.pause()}),i.once("end",()=>{c.push(null)}),this.emit("response",c)||c._dump())})),i.once("headers",n(o=>this.emit("information",{statusCode:o[QW]}))),i.once("trailers",n((o,a,l)=>{let{res:c}=this;c.trailers=o,c.rawTrailers=l}));let{socket:s}=i.session;this.socket=s,this.connection=s;for(let o of this[yp])o();this.emit("socket",this.socket)};if(this[dk])try{r(this[dk].request(this[Pi]))}catch(i){this.emit("error",i)}else{this.reusedSocket=!0;try{r(await this.agent.request(this[pk],this[SW],this[Pi]))}catch(i){this.emit("error",i)}}}getHeader(e){if(typeof e!="string")throw new hk("name","string",e);return this[Pi][e.toLowerCase()]}get headersSent(){return this[My]}removeHeader(e){if(typeof e!="string")throw new hk("name","string",e);if(this.headersSent)throw new BW("remove");delete this[Pi][e.toLowerCase()]}setHeader(e,r){if(this.headersSent)throw new BW("set");if(typeof e!="string"||!Lve.test(e)&&!kve(e))throw new Dve("Header name",e);if(typeof r=="undefined")throw new Rve(r,e);if(Tve.test(r))throw new Fve("header content",e);this[Pi][e.toLowerCase()]=r}setNoDelay(){}setSocketKeepAlive(){}setTimeout(e,r){let i=()=>this._request.setTimeout(e,r);return this._request?i():this[yp].push(i),this}get maxHeadersCount(){if(!this.destroyed&&this._request)return this._request.session.localSettings.maxHeaderListSize}set maxHeadersCount(e){}};yW.exports=xW});var PW=E((Hnt,kW)=>{"use strict";var Mve=require("tls");kW.exports=(t={})=>new Promise((e,r)=>{let i=Mve.connect(t,()=>{t.resolveSocket?(i.off("error",r),e({alpnProtocol:i.alpnProtocol,socket:i})):(i.destroy(),e({alpnProtocol:i.alpnProtocol}))});i.on("error",r)})});var RW=E((Gnt,DW)=>{"use strict";var Ove=require("net");DW.exports=t=>{let e=t.host,r=t.headers&&t.headers.host;return r&&(r.startsWith("[")?r.indexOf("]")===-1?e=r:e=r.slice(1,-1):e=r.split(":",1)[0]),Ove.isIP(e)?"":e}});var LW=E((jnt,mk)=>{"use strict";var FW=require("http"),Ek=require("https"),Kve=PW(),Uve=lk(),Hve=Ck(),Gve=RW(),jve=fk(),Oy=new Uve({maxSize:100}),wp=new Map,NW=(t,e,r)=>{e._httpMessage={shouldKeepAlive:!0};let i=()=>{t.emit("free",e,r)};e.on("free",i);let n=()=>{t.removeSocket(e,r)};e.on("close",n);let s=()=>{t.removeSocket(e,r),e.off("close",n),e.off("free",i),e.off("agentRemove",s)};e.on("agentRemove",s),t.emit("free",e,r)},Yve=async t=>{let e=`${t.host}:${t.port}:${t.ALPNProtocols.sort()}`;if(!Oy.has(e)){if(wp.has(e))return(await wp.get(e)).alpnProtocol;let{path:r,agent:i}=t;t.path=t.socketPath;let n=Kve(t);wp.set(e,n);try{let{socket:s,alpnProtocol:o}=await n;if(Oy.set(e,o),t.path=r,o==="h2")s.destroy();else{let{globalAgent:a}=Ek,l=Ek.Agent.prototype.createConnection;i?i.createConnection===l?NW(i,s,t):s.destroy():a.createConnection===l?NW(a,s,t):s.destroy()}return wp.delete(e),o}catch(s){throw wp.delete(e),s}}return Oy.get(e)};mk.exports=async(t,e,r)=>{if((typeof t=="string"||t instanceof URL)&&(t=jve(new URL(t))),typeof e=="function"&&(r=e,e=void 0),e=_(P(P({ALPNProtocols:["h2","http/1.1"]},t),e),{resolveSocket:!0}),!Array.isArray(e.ALPNProtocols)||e.ALPNProtocols.length===0)throw new Error("The `ALPNProtocols` option must be an Array with at least one entry");e.protocol=e.protocol||"https:";let i=e.protocol==="https:";e.host=e.hostname||e.host||"localhost",e.session=e.tlsSession,e.servername=e.servername||Gve(e),e.port=e.port||(i?443:80),e._defaultAgent=i?Ek.globalAgent:FW.globalAgent;let n=e.agent;if(n){if(n.addRequest)throw new Error("The `options.agent` object can contain only `http`, `https` or `http2` properties");e.agent=n[i?"https":"http"]}return i&&await Yve(e)==="h2"?(n&&(e.agent=n.http2),new Hve(e,r)):FW.request(e,r)};mk.exports.protocolCache=Oy});var MW=E((Ynt,TW)=>{"use strict";var qve=require("http2"),Jve=uk(),Ik=Ck(),Wve=gk(),zve=LW(),Vve=(t,e,r)=>new Ik(t,e,r),_ve=(t,e,r)=>{let i=new Ik(t,e,r);return i.end(),i};TW.exports=_(P(_(P({},qve),{ClientRequest:Ik,IncomingMessage:Wve}),Jve),{request:Vve,get:_ve,auto:zve})});var wk=E(yk=>{"use strict";Object.defineProperty(yk,"__esModule",{value:!0});var OW=Ca();yk.default=t=>OW.default.nodeStream(t)&&OW.default.function_(t.getBoundary)});var GW=E(Bk=>{"use strict";Object.defineProperty(Bk,"__esModule",{value:!0});var KW=require("fs"),UW=require("util"),HW=Ca(),Xve=wk(),Zve=UW.promisify(KW.stat);Bk.default=async(t,e)=>{if(e&&"content-length"in e)return Number(e["content-length"]);if(!t)return 0;if(HW.default.string(t))return Buffer.byteLength(t);if(HW.default.buffer(t))return t.length;if(Xve.default(t))return UW.promisify(t.getLength.bind(t))();if(t instanceof KW.ReadStream){let{size:r}=await Zve(t.path);return r===0?void 0:r}}});var bk=E(Qk=>{"use strict";Object.defineProperty(Qk,"__esModule",{value:!0});function $ve(t,e,r){let i={};for(let n of r)i[n]=(...s)=>{e.emit(n,...s)},t.on(n,i[n]);return()=>{for(let n of r)t.off(n,i[n])}}Qk.default=$ve});var jW=E(vk=>{"use strict";Object.defineProperty(vk,"__esModule",{value:!0});vk.default=()=>{let t=[];return{once(e,r,i){e.once(r,i),t.push({origin:e,event:r,fn:i})},unhandleAll(){for(let e of t){let{origin:r,event:i,fn:n}=e;r.removeListener(i,n)}t.length=0}}}});var qW=E(Bp=>{"use strict";Object.defineProperty(Bp,"__esModule",{value:!0});Bp.TimeoutError=void 0;var eSe=require("net"),tSe=jW(),YW=Symbol("reentry"),rSe=()=>{},Sk=class extends Error{constructor(e,r){super(`Timeout awaiting '${r}' for ${e}ms`);this.event=r,this.name="TimeoutError",this.code="ETIMEDOUT"}};Bp.TimeoutError=Sk;Bp.default=(t,e,r)=>{if(YW in t)return rSe;t[YW]=!0;let i=[],{once:n,unhandleAll:s}=tSe.default(),o=(g,f,h)=>{var p;let d=setTimeout(f,g,g,h);(p=d.unref)===null||p===void 0||p.call(d);let m=()=>{clearTimeout(d)};return i.push(m),m},{host:a,hostname:l}=r,c=(g,f)=>{t.destroy(new Sk(g,f))},u=()=>{for(let g of i)g();s()};if(t.once("error",g=>{if(u(),t.listenerCount("error")===0)throw g}),t.once("close",u),n(t,"response",g=>{n(g,"end",u)}),typeof e.request!="undefined"&&o(e.request,c,"request"),typeof e.socket!="undefined"){let g=()=>{c(e.socket,"socket")};t.setTimeout(e.socket,g),i.push(()=>{t.removeListener("timeout",g)})}return n(t,"socket",g=>{var f;let{socketPath:h}=t;if(g.connecting){let p=Boolean(h!=null?h:eSe.isIP((f=l!=null?l:a)!==null&&f!==void 0?f:"")!==0);if(typeof e.lookup!="undefined"&&!p&&typeof g.address().address=="undefined"){let d=o(e.lookup,c,"lookup");n(g,"lookup",d)}if(typeof e.connect!="undefined"){let d=()=>o(e.connect,c,"connect");p?n(g,"connect",d()):n(g,"lookup",m=>{m===null&&n(g,"connect",d())})}typeof e.secureConnect!="undefined"&&r.protocol==="https:"&&n(g,"connect",()=>{let d=o(e.secureConnect,c,"secureConnect");n(g,"secureConnect",d)})}if(typeof e.send!="undefined"){let p=()=>o(e.send,c,"send");g.connecting?n(g,"connect",()=>{n(t,"upload-complete",p())}):n(t,"upload-complete",p())}}),typeof e.response!="undefined"&&n(t,"upload-complete",()=>{let g=o(e.response,c,"response");n(t,"response",g)}),u}});var WW=E(xk=>{"use strict";Object.defineProperty(xk,"__esModule",{value:!0});var JW=Ca();xk.default=t=>{t=t;let e={protocol:t.protocol,hostname:JW.default.string(t.hostname)&&t.hostname.startsWith("[")?t.hostname.slice(1,-1):t.hostname,host:t.host,hash:t.hash,search:t.search,pathname:t.pathname,href:t.href,path:`${t.pathname||""}${t.search||""}`};return JW.default.string(t.port)&&t.port.length>0&&(e.port=Number(t.port)),(t.username||t.password)&&(e.auth=`${t.username||""}:${t.password||""}`),e}});var zW=E(kk=>{"use strict";Object.defineProperty(kk,"__esModule",{value:!0});var iSe=require("url"),nSe=["protocol","host","hostname","port","pathname","search"];kk.default=(t,e)=>{var r,i;if(e.path){if(e.pathname)throw new TypeError("Parameters `path` and `pathname` are mutually exclusive.");if(e.search)throw new TypeError("Parameters `path` and `search` are mutually exclusive.");if(e.searchParams)throw new TypeError("Parameters `path` and `searchParams` are mutually exclusive.")}if(e.search&&e.searchParams)throw new TypeError("Parameters `search` and `searchParams` are mutually exclusive.");if(!t){if(!e.protocol)throw new TypeError("No URL protocol specified");t=`${e.protocol}//${(i=(r=e.hostname)!==null&&r!==void 0?r:e.host)!==null&&i!==void 0?i:""}`}let n=new iSe.URL(t);if(e.path){let s=e.path.indexOf("?");s===-1?e.pathname=e.path:(e.pathname=e.path.slice(0,s),e.search=e.path.slice(s+1)),delete e.path}for(let s of nSe)e[s]&&(n[s]=e[s].toString());return n}});var _W=E(Pk=>{"use strict";Object.defineProperty(Pk,"__esModule",{value:!0});var VW=class{constructor(){this.weakMap=new WeakMap,this.map=new Map}set(e,r){typeof e=="object"?this.weakMap.set(e,r):this.map.set(e,r)}get(e){return typeof e=="object"?this.weakMap.get(e):this.map.get(e)}has(e){return typeof e=="object"?this.weakMap.has(e):this.map.has(e)}};Pk.default=VW});var Rk=E(Dk=>{"use strict";Object.defineProperty(Dk,"__esModule",{value:!0});var sSe=async t=>{let e=[],r=0;for await(let i of t)e.push(i),r+=Buffer.byteLength(i);return Buffer.isBuffer(e[0])?Buffer.concat(e,r):Buffer.from(e.join(""))};Dk.default=sSe});var ZW=E(ql=>{"use strict";Object.defineProperty(ql,"__esModule",{value:!0});ql.dnsLookupIpVersionToFamily=ql.isDnsLookupIpVersion=void 0;var XW={auto:0,ipv4:4,ipv6:6};ql.isDnsLookupIpVersion=t=>t in XW;ql.dnsLookupIpVersionToFamily=t=>{if(ql.isDnsLookupIpVersion(t))return XW[t];throw new Error("Invalid DNS lookup IP version")}});var Fk=E(Ky=>{"use strict";Object.defineProperty(Ky,"__esModule",{value:!0});Ky.isResponseOk=void 0;Ky.isResponseOk=t=>{let{statusCode:e}=t,r=t.request.options.followRedirect?299:399;return e>=200&&e<=r||e===304}});var e8=E(Nk=>{"use strict";Object.defineProperty(Nk,"__esModule",{value:!0});var $W=new Set;Nk.default=t=>{$W.has(t)||($W.add(t),process.emitWarning(`Got: ${t}`,{type:"DeprecationWarning"}))}});var t8=E(Lk=>{"use strict";Object.defineProperty(Lk,"__esModule",{value:!0});var ar=Ca(),oSe=(t,e)=>{if(ar.default.null_(t.encoding))throw new TypeError("To get a Buffer, set `options.responseType` to `buffer` instead");ar.assert.any([ar.default.string,ar.default.undefined],t.encoding),ar.assert.any([ar.default.boolean,ar.default.undefined],t.resolveBodyOnly),ar.assert.any([ar.default.boolean,ar.default.undefined],t.methodRewriting),ar.assert.any([ar.default.boolean,ar.default.undefined],t.isStream),ar.assert.any([ar.default.string,ar.default.undefined],t.responseType),t.responseType===void 0&&(t.responseType="text");let{retry:r}=t;if(e?t.retry=P({},e.retry):t.retry={calculateDelay:i=>i.computedValue,limit:0,methods:[],statusCodes:[],errorCodes:[],maxRetryAfter:void 0},ar.default.object(r)?(t.retry=P(P({},t.retry),r),t.retry.methods=[...new Set(t.retry.methods.map(i=>i.toUpperCase()))],t.retry.statusCodes=[...new Set(t.retry.statusCodes)],t.retry.errorCodes=[...new Set(t.retry.errorCodes)]):ar.default.number(r)&&(t.retry.limit=r),ar.default.undefined(t.retry.maxRetryAfter)&&(t.retry.maxRetryAfter=Math.min(...[t.timeout.request,t.timeout.connect].filter(ar.default.number))),ar.default.object(t.pagination)){e&&(t.pagination=P(P({},e.pagination),t.pagination));let{pagination:i}=t;if(!ar.default.function_(i.transform))throw new Error("`options.pagination.transform` must be implemented");if(!ar.default.function_(i.shouldContinue))throw new Error("`options.pagination.shouldContinue` must be implemented");if(!ar.default.function_(i.filter))throw new TypeError("`options.pagination.filter` must be implemented");if(!ar.default.function_(i.paginate))throw new Error("`options.pagination.paginate` must be implemented")}return t.responseType==="json"&&t.headers.accept===void 0&&(t.headers.accept="application/json"),t};Lk.default=oSe});var r8=E(Qp=>{"use strict";Object.defineProperty(Qp,"__esModule",{value:!0});Qp.retryAfterStatusCodes=void 0;Qp.retryAfterStatusCodes=new Set([413,429,503]);var aSe=({attemptCount:t,retryOptions:e,error:r,retryAfter:i})=>{if(t>e.limit)return 0;let n=e.methods.includes(r.options.method),s=e.errorCodes.includes(r.code),o=r.response&&e.statusCodes.includes(r.response.statusCode);if(!n||!s&&!o)return 0;if(r.response){if(i)return e.maxRetryAfter===void 0||i>e.maxRetryAfter?0:i;if(r.response.statusCode===413)return 0}let a=Math.random()*100;return 2**(t-1)*1e3+a};Qp.default=aSe});var vp=E(Rt=>{"use strict";Object.defineProperty(Rt,"__esModule",{value:!0});Rt.UnsupportedProtocolError=Rt.ReadError=Rt.TimeoutError=Rt.UploadError=Rt.CacheError=Rt.HTTPError=Rt.MaxRedirectsError=Rt.RequestError=Rt.setNonEnumerableProperties=Rt.knownHookEvents=Rt.withoutBody=Rt.kIsNormalizedAlready=void 0;var i8=require("util"),n8=require("stream"),ASe=require("fs"),dA=require("url"),s8=require("http"),Tk=require("http"),lSe=require("https"),cSe=h3(),uSe=y3(),o8=tW(),gSe=sW(),fSe=MW(),hSe=Ly(),ce=Ca(),pSe=GW(),a8=wk(),dSe=bk(),A8=qW(),CSe=WW(),l8=zW(),mSe=_W(),ESe=Rk(),c8=ZW(),ISe=Fk(),CA=e8(),ySe=t8(),wSe=r8(),Mk,Ei=Symbol("request"),Uy=Symbol("response"),Ju=Symbol("responseSize"),Wu=Symbol("downloadedSize"),zu=Symbol("bodySize"),Vu=Symbol("uploadedSize"),Hy=Symbol("serverResponsesPiped"),u8=Symbol("unproxyEvents"),g8=Symbol("isFromCache"),Ok=Symbol("cancelTimeouts"),f8=Symbol("startedReading"),_u=Symbol("stopReading"),Gy=Symbol("triggerRead"),mA=Symbol("body"),bp=Symbol("jobs"),h8=Symbol("originalResponse"),p8=Symbol("retryTimeout");Rt.kIsNormalizedAlready=Symbol("isNormalizedAlready");var BSe=ce.default.string(process.versions.brotli);Rt.withoutBody=new Set(["GET","HEAD"]);Rt.knownHookEvents=["init","beforeRequest","beforeRedirect","beforeError","beforeRetry","afterResponse"];function QSe(t){for(let e in t){let r=t[e];if(!ce.default.string(r)&&!ce.default.number(r)&&!ce.default.boolean(r)&&!ce.default.null_(r)&&!ce.default.undefined(r))throw new TypeError(`The \`searchParams\` value '${String(r)}' must be a string, number, boolean or null`)}}function bSe(t){return ce.default.object(t)&&!("statusCode"in t)}var Kk=new mSe.default,vSe=async t=>new Promise((e,r)=>{let i=n=>{r(n)};t.pending||e(),t.once("error",i),t.once("ready",()=>{t.off("error",i),e()})}),SSe=new Set([300,301,302,303,304,307,308]),xSe=["context","body","json","form"];Rt.setNonEnumerableProperties=(t,e)=>{let r={};for(let i of t)if(!!i)for(let n of xSe)n in i&&(r[n]={writable:!0,configurable:!0,enumerable:!1,value:i[n]});Object.defineProperties(e,r)};var _r=class extends Error{constructor(e,r,i){var n;super(e);if(Error.captureStackTrace(this,this.constructor),this.name="RequestError",this.code=r.code,i instanceof Uk?(Object.defineProperty(this,"request",{enumerable:!1,value:i}),Object.defineProperty(this,"response",{enumerable:!1,value:i[Uy]}),Object.defineProperty(this,"options",{enumerable:!1,value:i.options})):Object.defineProperty(this,"options",{enumerable:!1,value:i}),this.timings=(n=this.request)===null||n===void 0?void 0:n.timings,ce.default.string(r.stack)&&ce.default.string(this.stack)){let s=this.stack.indexOf(this.message)+this.message.length,o=this.stack.slice(s).split(` +`).reverse(),a=r.stack.slice(r.stack.indexOf(r.message)+r.message.length).split(` +`).reverse();for(;a.length!==0&&a[0]===o[0];)o.shift();this.stack=`${this.stack.slice(0,s)}${o.reverse().join(` +`)}${a.reverse().join(` +`)}`}}};Rt.RequestError=_r;var Hk=class extends _r{constructor(e){super(`Redirected ${e.options.maxRedirects} times. Aborting.`,{},e);this.name="MaxRedirectsError"}};Rt.MaxRedirectsError=Hk;var Gk=class extends _r{constructor(e){super(`Response code ${e.statusCode} (${e.statusMessage})`,{},e.request);this.name="HTTPError"}};Rt.HTTPError=Gk;var jk=class extends _r{constructor(e,r){super(e.message,e,r);this.name="CacheError"}};Rt.CacheError=jk;var Yk=class extends _r{constructor(e,r){super(e.message,e,r);this.name="UploadError"}};Rt.UploadError=Yk;var qk=class extends _r{constructor(e,r,i){super(e.message,e,i);this.name="TimeoutError",this.event=e.event,this.timings=r}};Rt.TimeoutError=qk;var jy=class extends _r{constructor(e,r){super(e.message,e,r);this.name="ReadError"}};Rt.ReadError=jy;var Jk=class extends _r{constructor(e){super(`Unsupported protocol "${e.url.protocol}"`,{},e);this.name="UnsupportedProtocolError"}};Rt.UnsupportedProtocolError=Jk;var kSe=["socket","connect","continue","information","upgrade","timeout"],Uk=class extends n8.Duplex{constructor(e,r={},i){super({autoDestroy:!1,highWaterMark:0});this[Wu]=0,this[Vu]=0,this.requestInitialized=!1,this[Hy]=new Set,this.redirects=[],this[_u]=!1,this[Gy]=!1,this[bp]=[],this.retryCount=0,this._progressCallbacks=[];let n=()=>this._unlockWrite(),s=()=>this._lockWrite();this.on("pipe",c=>{c.prependListener("data",n),c.on("data",s),c.prependListener("end",n),c.on("end",s)}),this.on("unpipe",c=>{c.off("data",n),c.off("data",s),c.off("end",n),c.off("end",s)}),this.on("pipe",c=>{c instanceof Tk.IncomingMessage&&(this.options.headers=P(P({},c.headers),this.options.headers))});let{json:o,body:a,form:l}=r;if((o||a||l)&&this._lockWrite(),Rt.kIsNormalizedAlready in r)this.options=r;else try{this.options=this.constructor.normalizeArguments(e,r,i)}catch(c){ce.default.nodeStream(r.body)&&r.body.destroy(),this.destroy(c);return}(async()=>{var c;try{this.options.body instanceof ASe.ReadStream&&await vSe(this.options.body);let{url:u}=this.options;if(!u)throw new TypeError("Missing `url` property");if(this.requestUrl=u.toString(),decodeURI(this.requestUrl),await this._finalizeBody(),await this._makeRequest(),this.destroyed){(c=this[Ei])===null||c===void 0||c.destroy();return}for(let g of this[bp])g();this[bp].length=0,this.requestInitialized=!0}catch(u){if(u instanceof _r){this._beforeError(u);return}this.destroyed||this.destroy(u)}})()}static normalizeArguments(e,r,i){var n,s,o,a,l;let c=r;if(ce.default.object(e)&&!ce.default.urlInstance(e))r=P(P(P({},i),e),r);else{if(e&&r&&r.url!==void 0)throw new TypeError("The `url` option is mutually exclusive with the `input` argument");r=P(P({},i),r),e!==void 0&&(r.url=e),ce.default.urlInstance(r.url)&&(r.url=new dA.URL(r.url.toString()))}if(r.cache===!1&&(r.cache=void 0),r.dnsCache===!1&&(r.dnsCache=void 0),ce.assert.any([ce.default.string,ce.default.undefined],r.method),ce.assert.any([ce.default.object,ce.default.undefined],r.headers),ce.assert.any([ce.default.string,ce.default.urlInstance,ce.default.undefined],r.prefixUrl),ce.assert.any([ce.default.object,ce.default.undefined],r.cookieJar),ce.assert.any([ce.default.object,ce.default.string,ce.default.undefined],r.searchParams),ce.assert.any([ce.default.object,ce.default.string,ce.default.undefined],r.cache),ce.assert.any([ce.default.object,ce.default.number,ce.default.undefined],r.timeout),ce.assert.any([ce.default.object,ce.default.undefined],r.context),ce.assert.any([ce.default.object,ce.default.undefined],r.hooks),ce.assert.any([ce.default.boolean,ce.default.undefined],r.decompress),ce.assert.any([ce.default.boolean,ce.default.undefined],r.ignoreInvalidCookies),ce.assert.any([ce.default.boolean,ce.default.undefined],r.followRedirect),ce.assert.any([ce.default.number,ce.default.undefined],r.maxRedirects),ce.assert.any([ce.default.boolean,ce.default.undefined],r.throwHttpErrors),ce.assert.any([ce.default.boolean,ce.default.undefined],r.http2),ce.assert.any([ce.default.boolean,ce.default.undefined],r.allowGetBody),ce.assert.any([ce.default.string,ce.default.undefined],r.localAddress),ce.assert.any([c8.isDnsLookupIpVersion,ce.default.undefined],r.dnsLookupIpVersion),ce.assert.any([ce.default.object,ce.default.undefined],r.https),ce.assert.any([ce.default.boolean,ce.default.undefined],r.rejectUnauthorized),r.https&&(ce.assert.any([ce.default.boolean,ce.default.undefined],r.https.rejectUnauthorized),ce.assert.any([ce.default.function_,ce.default.undefined],r.https.checkServerIdentity),ce.assert.any([ce.default.string,ce.default.object,ce.default.array,ce.default.undefined],r.https.certificateAuthority),ce.assert.any([ce.default.string,ce.default.object,ce.default.array,ce.default.undefined],r.https.key),ce.assert.any([ce.default.string,ce.default.object,ce.default.array,ce.default.undefined],r.https.certificate),ce.assert.any([ce.default.string,ce.default.undefined],r.https.passphrase),ce.assert.any([ce.default.string,ce.default.buffer,ce.default.array,ce.default.undefined],r.https.pfx)),ce.assert.any([ce.default.object,ce.default.undefined],r.cacheOptions),ce.default.string(r.method)?r.method=r.method.toUpperCase():r.method="GET",r.headers===(i==null?void 0:i.headers)?r.headers=P({},r.headers):r.headers=hSe(P(P({},i==null?void 0:i.headers),r.headers)),"slashes"in r)throw new TypeError("The legacy `url.Url` has been deprecated. Use `URL` instead.");if("auth"in r)throw new TypeError("Parameter `auth` is deprecated. Use `username` / `password` instead.");if("searchParams"in r&&r.searchParams&&r.searchParams!==(i==null?void 0:i.searchParams)){let h;if(ce.default.string(r.searchParams)||r.searchParams instanceof dA.URLSearchParams)h=new dA.URLSearchParams(r.searchParams);else{QSe(r.searchParams),h=new dA.URLSearchParams;for(let p in r.searchParams){let d=r.searchParams[p];d===null?h.append(p,""):d!==void 0&&h.append(p,d)}}(n=i==null?void 0:i.searchParams)===null||n===void 0||n.forEach((p,d)=>{h.has(d)||h.append(d,p)}),r.searchParams=h}if(r.username=(s=r.username)!==null&&s!==void 0?s:"",r.password=(o=r.password)!==null&&o!==void 0?o:"",ce.default.undefined(r.prefixUrl)?r.prefixUrl=(a=i==null?void 0:i.prefixUrl)!==null&&a!==void 0?a:"":(r.prefixUrl=r.prefixUrl.toString(),r.prefixUrl!==""&&!r.prefixUrl.endsWith("/")&&(r.prefixUrl+="/")),ce.default.string(r.url)){if(r.url.startsWith("/"))throw new Error("`input` must not start with a slash when using `prefixUrl`");r.url=l8.default(r.prefixUrl+r.url,r)}else(ce.default.undefined(r.url)&&r.prefixUrl!==""||r.protocol)&&(r.url=l8.default(r.prefixUrl,r));if(r.url){"port"in r&&delete r.port;let{prefixUrl:h}=r;Object.defineProperty(r,"prefixUrl",{set:d=>{let m=r.url;if(!m.href.startsWith(d))throw new Error(`Cannot change \`prefixUrl\` from ${h} to ${d}: ${m.href}`);r.url=new dA.URL(d+m.href.slice(h.length)),h=d},get:()=>h});let{protocol:p}=r.url;if(p==="unix:"&&(p="http:",r.url=new dA.URL(`http://unix${r.url.pathname}${r.url.search}`)),r.searchParams&&(r.url.search=r.searchParams.toString()),p!=="http:"&&p!=="https:")throw new Jk(r);r.username===""?r.username=r.url.username:r.url.username=r.username,r.password===""?r.password=r.url.password:r.url.password=r.password}let{cookieJar:u}=r;if(u){let{setCookie:h,getCookieString:p}=u;ce.assert.function_(h),ce.assert.function_(p),h.length===4&&p.length===0&&(h=i8.promisify(h.bind(r.cookieJar)),p=i8.promisify(p.bind(r.cookieJar)),r.cookieJar={setCookie:h,getCookieString:p})}let{cache:g}=r;if(g&&(Kk.has(g)||Kk.set(g,new o8((h,p)=>{let d=h[Ei](h,p);return ce.default.promise(d)&&(d.once=(m,I)=>{if(m==="error")d.catch(I);else if(m==="abort")(async()=>{try{(await d).once("abort",I)}catch(B){}})();else throw new Error(`Unknown HTTP2 promise event: ${m}`);return d}),d},g))),r.cacheOptions=P({},r.cacheOptions),r.dnsCache===!0)Mk||(Mk=new uSe.default),r.dnsCache=Mk;else if(!ce.default.undefined(r.dnsCache)&&!r.dnsCache.lookup)throw new TypeError(`Parameter \`dnsCache\` must be a CacheableLookup instance or a boolean, got ${ce.default(r.dnsCache)}`);ce.default.number(r.timeout)?r.timeout={request:r.timeout}:i&&r.timeout!==i.timeout?r.timeout=P(P({},i.timeout),r.timeout):r.timeout=P({},r.timeout),r.context||(r.context={});let f=r.hooks===(i==null?void 0:i.hooks);r.hooks=P({},r.hooks);for(let h of Rt.knownHookEvents)if(h in r.hooks)if(ce.default.array(r.hooks[h]))r.hooks[h]=[...r.hooks[h]];else throw new TypeError(`Parameter \`${h}\` must be an Array, got ${ce.default(r.hooks[h])}`);else r.hooks[h]=[];if(i&&!f)for(let h of Rt.knownHookEvents)i.hooks[h].length>0&&(r.hooks[h]=[...i.hooks[h],...r.hooks[h]]);if("family"in r&&CA.default('"options.family" was never documented, please use "options.dnsLookupIpVersion"'),(i==null?void 0:i.https)&&(r.https=P(P({},i.https),r.https)),"rejectUnauthorized"in r&&CA.default('"options.rejectUnauthorized" is now deprecated, please use "options.https.rejectUnauthorized"'),"checkServerIdentity"in r&&CA.default('"options.checkServerIdentity" was never documented, please use "options.https.checkServerIdentity"'),"ca"in r&&CA.default('"options.ca" was never documented, please use "options.https.certificateAuthority"'),"key"in r&&CA.default('"options.key" was never documented, please use "options.https.key"'),"cert"in r&&CA.default('"options.cert" was never documented, please use "options.https.certificate"'),"passphrase"in r&&CA.default('"options.passphrase" was never documented, please use "options.https.passphrase"'),"pfx"in r&&CA.default('"options.pfx" was never documented, please use "options.https.pfx"'),"followRedirects"in r)throw new TypeError("The `followRedirects` option does not exist. Use `followRedirect` instead.");if(r.agent){for(let h in r.agent)if(h!=="http"&&h!=="https"&&h!=="http2")throw new TypeError(`Expected the \`options.agent\` properties to be \`http\`, \`https\` or \`http2\`, got \`${h}\``)}return r.maxRedirects=(l=r.maxRedirects)!==null&&l!==void 0?l:0,Rt.setNonEnumerableProperties([i,c],r),ySe.default(r,i)}_lockWrite(){let e=()=>{throw new TypeError("The payload has been already provided")};this.write=e,this.end=e}_unlockWrite(){this.write=super.write,this.end=super.end}async _finalizeBody(){let{options:e}=this,{headers:r}=e,i=!ce.default.undefined(e.form),n=!ce.default.undefined(e.json),s=!ce.default.undefined(e.body),o=i||n||s,a=Rt.withoutBody.has(e.method)&&!(e.method==="GET"&&e.allowGetBody);if(this._cannotHaveBody=a,o){if(a)throw new TypeError(`The \`${e.method}\` method cannot be used with a body`);if([s,i,n].filter(l=>l).length>1)throw new TypeError("The `body`, `json` and `form` options are mutually exclusive");if(s&&!(e.body instanceof n8.Readable)&&!ce.default.string(e.body)&&!ce.default.buffer(e.body)&&!a8.default(e.body))throw new TypeError("The `body` option must be a stream.Readable, string or Buffer");if(i&&!ce.default.object(e.form))throw new TypeError("The `form` option must be an Object");{let l=!ce.default.string(r["content-type"]);s?(a8.default(e.body)&&l&&(r["content-type"]=`multipart/form-data; boundary=${e.body.getBoundary()}`),this[mA]=e.body):i?(l&&(r["content-type"]="application/x-www-form-urlencoded"),this[mA]=new dA.URLSearchParams(e.form).toString()):(l&&(r["content-type"]="application/json"),this[mA]=e.stringifyJson(e.json));let c=await pSe.default(this[mA],e.headers);ce.default.undefined(r["content-length"])&&ce.default.undefined(r["transfer-encoding"])&&!a&&!ce.default.undefined(c)&&(r["content-length"]=String(c))}}else a?this._lockWrite():this._unlockWrite();this[zu]=Number(r["content-length"])||void 0}async _onResponseBase(e){let{options:r}=this,{url:i}=r;this[h8]=e,r.decompress&&(e=gSe(e));let n=e.statusCode,s=e;s.statusMessage=s.statusMessage?s.statusMessage:s8.STATUS_CODES[n],s.url=r.url.toString(),s.requestUrl=this.requestUrl,s.redirectUrls=this.redirects,s.request=this,s.isFromCache=e.fromCache||!1,s.ip=this.ip,s.retryCount=this.retryCount,this[g8]=s.isFromCache,this[Ju]=Number(e.headers["content-length"])||void 0,this[Uy]=e,e.once("end",()=>{this[Ju]=this[Wu],this.emit("downloadProgress",this.downloadProgress)}),e.once("error",a=>{e.destroy(),this._beforeError(new jy(a,this))}),e.once("aborted",()=>{this._beforeError(new jy({name:"Error",message:"The server aborted pending request",code:"ECONNRESET"},this))}),this.emit("downloadProgress",this.downloadProgress);let o=e.headers["set-cookie"];if(ce.default.object(r.cookieJar)&&o){let a=o.map(async l=>r.cookieJar.setCookie(l,i.toString()));r.ignoreInvalidCookies&&(a=a.map(async l=>l.catch(()=>{})));try{await Promise.all(a)}catch(l){this._beforeError(l);return}}if(r.followRedirect&&e.headers.location&&SSe.has(n)){if(e.resume(),this[Ei]&&(this[Ok](),delete this[Ei],this[u8]()),(n===303&&r.method!=="GET"&&r.method!=="HEAD"||!r.methodRewriting)&&(r.method="GET","body"in r&&delete r.body,"json"in r&&delete r.json,"form"in r&&delete r.form,this[mA]=void 0,delete r.headers["content-length"]),this.redirects.length>=r.maxRedirects){this._beforeError(new Hk(this));return}try{let l=Buffer.from(e.headers.location,"binary").toString(),c=new dA.URL(l,i),u=c.toString();decodeURI(u),c.hostname!==i.hostname||c.port!==i.port?("host"in r.headers&&delete r.headers.host,"cookie"in r.headers&&delete r.headers.cookie,"authorization"in r.headers&&delete r.headers.authorization,(r.username||r.password)&&(r.username="",r.password="")):(c.username=r.username,c.password=r.password),this.redirects.push(u),r.url=c;for(let g of r.hooks.beforeRedirect)await g(r,s);this.emit("redirect",s,r),await this._makeRequest()}catch(l){this._beforeError(l);return}return}if(r.isStream&&r.throwHttpErrors&&!ISe.isResponseOk(s)){this._beforeError(new Gk(s));return}e.on("readable",()=>{this[Gy]&&this._read()}),this.on("resume",()=>{e.resume()}),this.on("pause",()=>{e.pause()}),e.once("end",()=>{this.push(null)}),this.emit("response",e);for(let a of this[Hy])if(!a.headersSent){for(let l in e.headers){let c=r.decompress?l!=="content-encoding":!0,u=e.headers[l];c&&a.setHeader(l,u)}a.statusCode=n}}async _onResponse(e){try{await this._onResponseBase(e)}catch(r){this._beforeError(r)}}_onRequest(e){let{options:r}=this,{timeout:i,url:n}=r;cSe.default(e),this[Ok]=A8.default(e,i,n);let s=r.cache?"cacheableResponse":"response";e.once(s,l=>{this._onResponse(l)}),e.once("error",l=>{var c;e.destroy(),(c=e.res)===null||c===void 0||c.removeAllListeners("end"),l=l instanceof A8.TimeoutError?new qk(l,this.timings,this):new _r(l.message,l,this),this._beforeError(l)}),this[u8]=dSe.default(e,this,kSe),this[Ei]=e,this.emit("uploadProgress",this.uploadProgress);let o=this[mA],a=this.redirects.length===0?this:e;ce.default.nodeStream(o)?(o.pipe(a),o.once("error",l=>{this._beforeError(new Yk(l,this))})):(this._unlockWrite(),ce.default.undefined(o)?(this._cannotHaveBody||this._noPipe)&&(a.end(),this._lockWrite()):(this._writeRequest(o,void 0,()=>{}),a.end(),this._lockWrite())),this.emit("request",e)}async _createCacheableRequest(e,r){return new Promise((i,n)=>{Object.assign(r,CSe.default(e)),delete r.url;let s,o=Kk.get(r.cache)(r,async a=>{a._readableState.autoDestroy=!1,s&&(await s).emit("cacheableResponse",a),i(a)});r.url=e,o.once("error",n),o.once("request",async a=>{s=a,i(s)})})}async _makeRequest(){var e,r,i,n,s;let{options:o}=this,{headers:a}=o;for(let I in a)if(ce.default.undefined(a[I]))delete a[I];else if(ce.default.null_(a[I]))throw new TypeError(`Use \`undefined\` instead of \`null\` to delete the \`${I}\` header`);if(o.decompress&&ce.default.undefined(a["accept-encoding"])&&(a["accept-encoding"]=BSe?"gzip, deflate, br":"gzip, deflate"),o.cookieJar){let I=await o.cookieJar.getCookieString(o.url.toString());ce.default.nonEmptyString(I)&&(o.headers.cookie=I)}for(let I of o.hooks.beforeRequest){let B=await I(o);if(!ce.default.undefined(B)){o.request=()=>B;break}}o.body&&this[mA]!==o.body&&(this[mA]=o.body);let{agent:l,request:c,timeout:u,url:g}=o;if(o.dnsCache&&!("lookup"in o)&&(o.lookup=o.dnsCache.lookup),g.hostname==="unix"){let I=/(?.+?):(?.+)/.exec(`${g.pathname}${g.search}`);if(I==null?void 0:I.groups){let{socketPath:B,path:b}=I.groups;Object.assign(o,{socketPath:B,path:b,host:""})}}let f=g.protocol==="https:",h;o.http2?h=fSe.auto:h=f?lSe.request:s8.request;let p=(e=o.request)!==null&&e!==void 0?e:h,d=o.cache?this._createCacheableRequest:p;l&&!o.http2&&(o.agent=l[f?"https":"http"]),o[Ei]=p,delete o.request,delete o.timeout;let m=o;if(m.shared=(r=o.cacheOptions)===null||r===void 0?void 0:r.shared,m.cacheHeuristic=(i=o.cacheOptions)===null||i===void 0?void 0:i.cacheHeuristic,m.immutableMinTimeToLive=(n=o.cacheOptions)===null||n===void 0?void 0:n.immutableMinTimeToLive,m.ignoreCargoCult=(s=o.cacheOptions)===null||s===void 0?void 0:s.ignoreCargoCult,o.dnsLookupIpVersion!==void 0)try{m.family=c8.dnsLookupIpVersionToFamily(o.dnsLookupIpVersion)}catch(I){throw new Error("Invalid `dnsLookupIpVersion` option value")}o.https&&("rejectUnauthorized"in o.https&&(m.rejectUnauthorized=o.https.rejectUnauthorized),o.https.checkServerIdentity&&(m.checkServerIdentity=o.https.checkServerIdentity),o.https.certificateAuthority&&(m.ca=o.https.certificateAuthority),o.https.certificate&&(m.cert=o.https.certificate),o.https.key&&(m.key=o.https.key),o.https.passphrase&&(m.passphrase=o.https.passphrase),o.https.pfx&&(m.pfx=o.https.pfx));try{let I=await d(g,m);ce.default.undefined(I)&&(I=h(g,m)),o.request=c,o.timeout=u,o.agent=l,o.https&&("rejectUnauthorized"in o.https&&delete m.rejectUnauthorized,o.https.checkServerIdentity&&delete m.checkServerIdentity,o.https.certificateAuthority&&delete m.ca,o.https.certificate&&delete m.cert,o.https.key&&delete m.key,o.https.passphrase&&delete m.passphrase,o.https.pfx&&delete m.pfx),bSe(I)?this._onRequest(I):this.writable?(this.once("finish",()=>{this._onResponse(I)}),this._unlockWrite(),this.end(),this._lockWrite()):this._onResponse(I)}catch(I){throw I instanceof o8.CacheError?new jk(I,this):new _r(I.message,I,this)}}async _error(e){try{for(let r of this.options.hooks.beforeError)e=await r(e)}catch(r){e=new _r(r.message,r,this)}this.destroy(e)}_beforeError(e){if(this[_u])return;let{options:r}=this,i=this.retryCount+1;this[_u]=!0,e instanceof _r||(e=new _r(e.message,e,this));let n=e,{response:s}=n;(async()=>{if(s&&!s.body){s.setEncoding(this._readableState.encoding);try{s.rawBody=await ESe.default(s),s.body=s.rawBody.toString()}catch(o){}}if(this.listenerCount("retry")!==0){let o;try{let a;s&&"retry-after"in s.headers&&(a=Number(s.headers["retry-after"]),Number.isNaN(a)?(a=Date.parse(s.headers["retry-after"])-Date.now(),a<=0&&(a=1)):a*=1e3),o=await r.retry.calculateDelay({attemptCount:i,retryOptions:r.retry,error:n,retryAfter:a,computedValue:wSe.default({attemptCount:i,retryOptions:r.retry,error:n,retryAfter:a,computedValue:0})})}catch(a){this._error(new _r(a.message,a,this));return}if(o){let a=async()=>{try{for(let l of this.options.hooks.beforeRetry)await l(this.options,n,i)}catch(l){this._error(new _r(l.message,e,this));return}this.destroyed||(this.destroy(),this.emit("retry",i,e))};this[p8]=setTimeout(a,o);return}}this._error(n)})()}_read(){this[Gy]=!0;let e=this[Uy];if(e&&!this[_u]){e.readableLength&&(this[Gy]=!1);let r;for(;(r=e.read())!==null;){this[Wu]+=r.length,this[f8]=!0;let i=this.downloadProgress;i.percent<1&&this.emit("downloadProgress",i),this.push(r)}}}_write(e,r,i){let n=()=>{this._writeRequest(e,r,i)};this.requestInitialized?n():this[bp].push(n)}_writeRequest(e,r,i){this[Ei].destroyed||(this._progressCallbacks.push(()=>{this[Vu]+=Buffer.byteLength(e,r);let n=this.uploadProgress;n.percent<1&&this.emit("uploadProgress",n)}),this[Ei].write(e,r,n=>{!n&&this._progressCallbacks.length>0&&this._progressCallbacks.shift()(),i(n)}))}_final(e){let r=()=>{for(;this._progressCallbacks.length!==0;)this._progressCallbacks.shift()();if(!(Ei in this)){e();return}if(this[Ei].destroyed){e();return}this[Ei].end(i=>{i||(this[zu]=this[Vu],this.emit("uploadProgress",this.uploadProgress),this[Ei].emit("upload-complete")),e(i)})};this.requestInitialized?r():this[bp].push(r)}_destroy(e,r){var i;this[_u]=!0,clearTimeout(this[p8]),Ei in this&&(this[Ok](),((i=this[Uy])===null||i===void 0?void 0:i.complete)||this[Ei].destroy()),e!==null&&!ce.default.undefined(e)&&!(e instanceof _r)&&(e=new _r(e.message,e,this)),r(e)}get _isAboutToError(){return this[_u]}get ip(){var e;return(e=this.socket)===null||e===void 0?void 0:e.remoteAddress}get aborted(){var e,r,i;return((r=(e=this[Ei])===null||e===void 0?void 0:e.destroyed)!==null&&r!==void 0?r:this.destroyed)&&!((i=this[h8])===null||i===void 0?void 0:i.complete)}get socket(){var e,r;return(r=(e=this[Ei])===null||e===void 0?void 0:e.socket)!==null&&r!==void 0?r:void 0}get downloadProgress(){let e;return this[Ju]?e=this[Wu]/this[Ju]:this[Ju]===this[Wu]?e=1:e=0,{percent:e,transferred:this[Wu],total:this[Ju]}}get uploadProgress(){let e;return this[zu]?e=this[Vu]/this[zu]:this[zu]===this[Vu]?e=1:e=0,{percent:e,transferred:this[Vu],total:this[zu]}}get timings(){var e;return(e=this[Ei])===null||e===void 0?void 0:e.timings}get isFromCache(){return this[g8]}pipe(e,r){if(this[f8])throw new Error("Failed to pipe. The response has been emitted already.");return e instanceof Tk.ServerResponse&&this[Hy].add(e),super.pipe(e,r)}unpipe(e){return e instanceof Tk.ServerResponse&&this[Hy].delete(e),super.unpipe(e),this}};Rt.default=Uk});var Sp=E(Ms=>{"use strict";var PSe=Ms&&Ms.__createBinding||(Object.create?function(t,e,r,i){i===void 0&&(i=r),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,i){i===void 0&&(i=r),t[i]=e[r]}),DSe=Ms&&Ms.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&PSe(e,t,r)};Object.defineProperty(Ms,"__esModule",{value:!0});Ms.CancelError=Ms.ParseError=void 0;var d8=vp(),C8=class extends d8.RequestError{constructor(e,r){let{options:i}=r.request;super(`${e.message} in "${i.url.toString()}"`,e,r.request);this.name="ParseError"}};Ms.ParseError=C8;var m8=class extends d8.RequestError{constructor(e){super("Promise was canceled",{},e);this.name="CancelError"}get isCanceled(){return!0}};Ms.CancelError=m8;DSe(vp(),Ms)});var I8=E(Wk=>{"use strict";Object.defineProperty(Wk,"__esModule",{value:!0});var E8=Sp(),RSe=(t,e,r,i)=>{let{rawBody:n}=t;try{if(e==="text")return n.toString(i);if(e==="json")return n.length===0?"":r(n.toString());if(e==="buffer")return n;throw new E8.ParseError({message:`Unknown body type '${e}'`,name:"Error"},t)}catch(s){throw new E8.ParseError(s,t)}};Wk.default=RSe});var zk=E(EA=>{"use strict";var FSe=EA&&EA.__createBinding||(Object.create?function(t,e,r,i){i===void 0&&(i=r),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,i){i===void 0&&(i=r),t[i]=e[r]}),NSe=EA&&EA.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&FSe(e,t,r)};Object.defineProperty(EA,"__esModule",{value:!0});var LSe=require("events"),TSe=Ca(),MSe=g3(),Yy=Sp(),y8=I8(),w8=vp(),OSe=bk(),KSe=Rk(),B8=Fk(),USe=["request","response","redirect","uploadProgress","downloadProgress"];function Q8(t){let e,r,i=new LSe.EventEmitter,n=new MSe((o,a,l)=>{let c=u=>{let g=new w8.default(void 0,t);g.retryCount=u,g._noPipe=!0,l(()=>g.destroy()),l.shouldReject=!1,l(()=>a(new Yy.CancelError(g))),e=g,g.once("response",async p=>{var d;if(p.retryCount=u,p.request.aborted)return;let m;try{m=await KSe.default(g),p.rawBody=m}catch(R){return}if(g._isAboutToError)return;let I=((d=p.headers["content-encoding"])!==null&&d!==void 0?d:"").toLowerCase(),B=["gzip","deflate","br"].includes(I),{options:b}=g;if(B&&!b.decompress)p.body=m;else try{p.body=y8.default(p,b.responseType,b.parseJson,b.encoding)}catch(R){if(p.body=m.toString(),B8.isResponseOk(p)){g._beforeError(R);return}}try{for(let[R,H]of b.hooks.afterResponse.entries())p=await H(p,async L=>{let K=w8.default.normalizeArguments(void 0,_(P({},L),{retry:{calculateDelay:()=>0},throwHttpErrors:!1,resolveBodyOnly:!1}),b);K.hooks.afterResponse=K.hooks.afterResponse.slice(0,R);for(let ne of K.hooks.beforeRetry)await ne(K);let J=Q8(K);return l(()=>{J.catch(()=>{}),J.cancel()}),J})}catch(R){g._beforeError(new Yy.RequestError(R.message,R,g));return}if(!B8.isResponseOk(p)){g._beforeError(new Yy.HTTPError(p));return}r=p,o(g.options.resolveBodyOnly?p.body:p)});let f=p=>{if(n.isCanceled)return;let{options:d}=g;if(p instanceof Yy.HTTPError&&!d.throwHttpErrors){let{response:m}=p;o(g.options.resolveBodyOnly?m.body:m);return}a(p)};g.once("error",f);let h=g.options.body;g.once("retry",(p,d)=>{var m,I;if(h===((m=d.request)===null||m===void 0?void 0:m.options.body)&&TSe.default.nodeStream((I=d.request)===null||I===void 0?void 0:I.options.body)){f(d);return}c(p)}),OSe.default(g,i,USe)};c(0)});n.on=(o,a)=>(i.on(o,a),n);let s=o=>{let a=(async()=>{await n;let{options:l}=r.request;return y8.default(r,o,l.parseJson,l.encoding)})();return Object.defineProperties(a,Object.getOwnPropertyDescriptors(n)),a};return n.json=()=>{let{headers:o}=e.options;return!e.writableFinished&&o.accept===void 0&&(o.accept="application/json"),s("json")},n.buffer=()=>s("buffer"),n.text=()=>s("text"),n}EA.default=Q8;NSe(Sp(),EA)});var b8=E(Vk=>{"use strict";Object.defineProperty(Vk,"__esModule",{value:!0});var HSe=Sp();function GSe(t,...e){let r=(async()=>{if(t instanceof HSe.RequestError)try{for(let n of e)if(n)for(let s of n)t=await s(t)}catch(n){t=n}throw t})(),i=()=>r;return r.json=i,r.text=i,r.buffer=i,r.on=i,r}Vk.default=GSe});var x8=E(_k=>{"use strict";Object.defineProperty(_k,"__esModule",{value:!0});var v8=Ca();function S8(t){for(let e of Object.values(t))(v8.default.plainObject(e)||v8.default.array(e))&&S8(e);return Object.freeze(t)}_k.default=S8});var P8=E(k8=>{"use strict";Object.defineProperty(k8,"__esModule",{value:!0})});var Xk=E(ss=>{"use strict";var jSe=ss&&ss.__createBinding||(Object.create?function(t,e,r,i){i===void 0&&(i=r),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,i){i===void 0&&(i=r),t[i]=e[r]}),YSe=ss&&ss.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&jSe(e,t,r)};Object.defineProperty(ss,"__esModule",{value:!0});ss.defaultHandler=void 0;var D8=Ca(),os=zk(),qSe=b8(),qy=vp(),JSe=x8(),WSe={RequestError:os.RequestError,CacheError:os.CacheError,ReadError:os.ReadError,HTTPError:os.HTTPError,MaxRedirectsError:os.MaxRedirectsError,TimeoutError:os.TimeoutError,ParseError:os.ParseError,CancelError:os.CancelError,UnsupportedProtocolError:os.UnsupportedProtocolError,UploadError:os.UploadError},zSe=async t=>new Promise(e=>{setTimeout(e,t)}),{normalizeArguments:Jy}=qy.default,R8=(...t)=>{let e;for(let r of t)e=Jy(void 0,r,e);return e},VSe=t=>t.isStream?new qy.default(void 0,t):os.default(t),_Se=t=>"defaults"in t&&"options"in t.defaults,XSe=["get","post","put","patch","head","delete"];ss.defaultHandler=(t,e)=>e(t);var F8=(t,e)=>{if(t)for(let r of t)r(e)},N8=t=>{t._rawHandlers=t.handlers,t.handlers=t.handlers.map(i=>(n,s)=>{let o,a=i(n,l=>(o=s(l),o));if(a!==o&&!n.isStream&&o){let l=a,{then:c,catch:u,finally:g}=l;Object.setPrototypeOf(l,Object.getPrototypeOf(o)),Object.defineProperties(l,Object.getOwnPropertyDescriptors(o)),l.then=c,l.catch=u,l.finally=g}return a});let e=(i,n={},s)=>{var o,a;let l=0,c=u=>t.handlers[l++](u,l===t.handlers.length?VSe:c);if(D8.default.plainObject(i)){let u=P(P({},i),n);qy.setNonEnumerableProperties([i,n],u),n=u,i=void 0}try{let u;try{F8(t.options.hooks.init,n),F8((o=n.hooks)===null||o===void 0?void 0:o.init,n)}catch(f){u=f}let g=Jy(i,n,s!=null?s:t.options);if(g[qy.kIsNormalizedAlready]=!0,u)throw new os.RequestError(u.message,u,g);return c(g)}catch(u){if(n.isStream)throw u;return qSe.default(u,t.options.hooks.beforeError,(a=n.hooks)===null||a===void 0?void 0:a.beforeError)}};e.extend=(...i)=>{let n=[t.options],s=[...t._rawHandlers],o;for(let a of i)_Se(a)?(n.push(a.defaults.options),s.push(...a.defaults._rawHandlers),o=a.defaults.mutableDefaults):(n.push(a),"handlers"in a&&s.push(...a.handlers),o=a.mutableDefaults);return s=s.filter(a=>a!==ss.defaultHandler),s.length===0&&s.push(ss.defaultHandler),N8({options:R8(...n),handlers:s,mutableDefaults:Boolean(o)})};let r=async function*(i,n){let s=Jy(i,n,t.options);s.resolveBodyOnly=!1;let o=s.pagination;if(!D8.default.object(o))throw new TypeError("`options.pagination` must be implemented");let a=[],{countLimit:l}=o,c=0;for(;c{let s=[];for await(let o of r(i,n))s.push(o);return s},e.paginate.each=r,e.stream=(i,n)=>e(i,_(P({},n),{isStream:!0}));for(let i of XSe)e[i]=(n,s)=>e(n,_(P({},s),{method:i})),e.stream[i]=(n,s)=>e(n,_(P({},s),{method:i,isStream:!0}));return Object.assign(e,WSe),Object.defineProperty(e,"defaults",{value:t.mutableDefaults?t:JSe.default(t),writable:t.mutableDefaults,configurable:t.mutableDefaults,enumerable:!0}),e.mergeOptions=R8,e};ss.default=N8;YSe(P8(),ss)});var zy=E((Ea,Wy)=>{"use strict";var ZSe=Ea&&Ea.__createBinding||(Object.create?function(t,e,r,i){i===void 0&&(i=r),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,i){i===void 0&&(i=r),t[i]=e[r]}),L8=Ea&&Ea.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&ZSe(e,t,r)};Object.defineProperty(Ea,"__esModule",{value:!0});var $Se=require("url"),T8=Xk(),exe={options:{method:"GET",retry:{limit:2,methods:["GET","PUT","HEAD","DELETE","OPTIONS","TRACE"],statusCodes:[408,413,429,500,502,503,504,521,522,524],errorCodes:["ETIMEDOUT","ECONNRESET","EADDRINUSE","ECONNREFUSED","EPIPE","ENOTFOUND","ENETUNREACH","EAI_AGAIN"],maxRetryAfter:void 0,calculateDelay:({computedValue:t})=>t},timeout:{},headers:{"user-agent":"got (https://github.com/sindresorhus/got)"},hooks:{init:[],beforeRequest:[],beforeRedirect:[],beforeRetry:[],beforeError:[],afterResponse:[]},cache:void 0,dnsCache:void 0,decompress:!0,throwHttpErrors:!0,followRedirect:!0,isStream:!1,responseType:"text",resolveBodyOnly:!1,maxRedirects:10,prefixUrl:"",methodRewriting:!0,ignoreInvalidCookies:!1,context:{},http2:!1,allowGetBody:!1,https:void 0,pagination:{transform:t=>t.request.options.responseType==="json"?t.body:JSON.parse(t.body),paginate:t=>{if(!Reflect.has(t.headers,"link"))return!1;let e=t.headers.link.split(","),r;for(let i of e){let n=i.split(";");if(n[1].includes("next")){r=n[0].trimStart().trim(),r=r.slice(1,-1);break}}return r?{url:new $Se.URL(r)}:!1},filter:()=>!0,shouldContinue:()=>!0,countLimit:Infinity,backoff:0,requestLimit:1e4,stackAllItems:!0},parseJson:t=>JSON.parse(t),stringifyJson:t=>JSON.stringify(t),cacheOptions:{}},handlers:[T8.defaultHandler],mutableDefaults:!1},Zk=T8.default(exe);Ea.default=Zk;Wy.exports=Zk;Wy.exports.default=Zk;Wy.exports.__esModule=!0;L8(Xk(),Ea);L8(zk(),Ea)});var U8=E(Xu=>{"use strict";var fst=require("net"),txe=require("tls"),$k=require("http"),M8=require("https"),rxe=require("events"),hst=require("assert"),ixe=require("util");Xu.httpOverHttp=nxe;Xu.httpsOverHttp=sxe;Xu.httpOverHttps=oxe;Xu.httpsOverHttps=axe;function nxe(t){var e=new Ia(t);return e.request=$k.request,e}function sxe(t){var e=new Ia(t);return e.request=$k.request,e.createSocket=O8,e.defaultPort=443,e}function oxe(t){var e=new Ia(t);return e.request=M8.request,e}function axe(t){var e=new Ia(t);return e.request=M8.request,e.createSocket=O8,e.defaultPort=443,e}function Ia(t){var e=this;e.options=t||{},e.proxyOptions=e.options.proxy||{},e.maxSockets=e.options.maxSockets||$k.Agent.defaultMaxSockets,e.requests=[],e.sockets=[],e.on("free",function(i,n,s,o){for(var a=K8(n,s,o),l=0,c=e.requests.length;l=this.maxSockets){s.requests.push(o);return}s.createSocket(o,function(a){a.on("free",l),a.on("close",c),a.on("agentRemove",c),e.onSocket(a);function l(){s.emit("free",a,o)}function c(u){s.removeSocket(a),a.removeListener("free",l),a.removeListener("close",c),a.removeListener("agentRemove",c)}})};Ia.prototype.createSocket=function(e,r){var i=this,n={};i.sockets.push(n);var s=eP({},i.proxyOptions,{method:"CONNECT",path:e.host+":"+e.port,agent:!1,headers:{host:e.host+":"+e.port}});e.localAddress&&(s.localAddress=e.localAddress),s.proxyAuth&&(s.headers=s.headers||{},s.headers["Proxy-Authorization"]="Basic "+new Buffer(s.proxyAuth).toString("base64")),IA("making CONNECT request");var o=i.request(s);o.useChunkedEncodingByDefault=!1,o.once("response",a),o.once("upgrade",l),o.once("connect",c),o.once("error",u),o.end();function a(g){g.upgrade=!0}function l(g,f,h){process.nextTick(function(){c(g,f,h)})}function c(g,f,h){if(o.removeAllListeners(),f.removeAllListeners(),g.statusCode!==200){IA("tunneling socket could not be established, statusCode=%d",g.statusCode),f.destroy();var p=new Error("tunneling socket could not be established, statusCode="+g.statusCode);p.code="ECONNRESET",e.request.emit("error",p),i.removeSocket(n);return}if(h.length>0){IA("got illegal response body from proxy"),f.destroy();var p=new Error("got illegal response body from proxy");p.code="ECONNRESET",e.request.emit("error",p),i.removeSocket(n);return}return IA("tunneling connection has established"),i.sockets[i.sockets.indexOf(n)]=f,r(f)}function u(g){o.removeAllListeners(),IA(`tunneling socket could not be established, cause=%s +`,g.message,g.stack);var f=new Error("tunneling socket could not be established, cause="+g.message);f.code="ECONNRESET",e.request.emit("error",f),i.removeSocket(n)}};Ia.prototype.removeSocket=function(e){var r=this.sockets.indexOf(e);if(r!==-1){this.sockets.splice(r,1);var i=this.requests.shift();i&&this.createSocket(i,function(n){i.request.onSocket(n)})}};function O8(t,e){var r=this;Ia.prototype.createSocket.call(r,t,function(i){var n=t.request.getHeader("host"),s=eP({},r.options,{socket:i,servername:n?n.replace(/:.*$/,""):t.host}),o=txe.connect(0,s);r.sockets[r.sockets.indexOf(i)]=o,e(o)})}function K8(t,e,r){return typeof t=="string"?{host:t,port:e,localAddress:r}:t}function eP(t){for(var e=1,r=arguments.length;e{H8.exports=U8()});var b4=E((xot,sP)=>{var e4=Object.assign({},require("fs")),oe=typeof oe!="undefined"?oe:{},kp={},wA;for(wA in oe)oe.hasOwnProperty(wA)&&(kp[wA]=oe[wA]);var oP=[],t4="./this.program",r4=function(t,e){throw e},i4=!1,Wl=!0,Pp="";function dxe(t){return oe.locateFile?oe.locateFile(t,Pp):Pp+t}var Xy,aP,Zy,AP;Wl&&(i4?Pp=require("path").dirname(Pp)+"/":Pp=__dirname+"/",Xy=function(e,r){var i=s4(e);return i?r?i:i.toString():(Zy||(Zy=e4),AP||(AP=require("path")),e=AP.normalize(e),Zy.readFileSync(e,r?null:"utf8"))},aP=function(e){var r=Xy(e,!0);return r.buffer||(r=new Uint8Array(r)),n4(r.buffer),r},process.argv.length>1&&(t4=process.argv[1].replace(/\\/g,"/")),oP=process.argv.slice(2),typeof sP!="undefined"&&(sP.exports=oe),r4=function(t){process.exit(t)},oe.inspect=function(){return"[Emscripten Module object]"});var $y=oe.print||console.log.bind(console),Di=oe.printErr||console.warn.bind(console);for(wA in kp)kp.hasOwnProperty(wA)&&(oe[wA]=kp[wA]);kp=null;oe.arguments&&(oP=oe.arguments);oe.thisProgram&&(t4=oe.thisProgram);oe.quit&&(r4=oe.quit);var Cxe=16;function mxe(t,e){return e||(e=Cxe),Math.ceil(t/e)*e}var Exe=0,Ixe=function(t){Exe=t},lP;oe.wasmBinary&&(lP=oe.wasmBinary);var Pst=oe.noExitRuntime||!0;typeof WebAssembly!="object"&&Gr("no native wasm support detected");function yxe(t,e,r){switch(e=e||"i8",e.charAt(e.length-1)==="*"&&(e="i32"),e){case"i1":return Zi[t>>0];case"i8":return Zi[t>>0];case"i16":return cP[t>>1];case"i32":return _e[t>>2];case"i64":return _e[t>>2];case"float":return o4[t>>2];case"double":return a4[t>>3];default:Gr("invalid type for getValue: "+e)}return null}var ew,A4=!1,wxe;function n4(t,e){t||Gr("Assertion failed: "+e)}function l4(t){var e=oe["_"+t];return n4(e,"Cannot call unknown function "+t+", make sure it is exported"),e}function vxe(t,e,r,i,n){var s={string:function(h){var p=0;if(h!=null&&h!==0){var d=(h.length<<2)+1;p=g4(d),u4(h,p,d)}return p},array:function(h){var p=g4(h.length);return Bxe(h,p),p}};function o(h){return e==="string"?c4(h):e==="boolean"?Boolean(h):h}var a=l4(t),l=[],c=0;if(i)for(var u=0;u=i);)++n;if(n-e>16&&t.subarray&&f4)return f4.decode(t.subarray(e,n));for(var s="";e>10,56320|c&1023)}}return s}function c4(t,e){return t?Zu($u,t,e):""}function tw(t,e,r,i){if(!(i>0))return 0;for(var n=r,s=r+i-1,o=0;o=55296&&a<=57343){var l=t.charCodeAt(++o);a=65536+((a&1023)<<10)|l&1023}if(a<=127){if(r>=s)break;e[r++]=a}else if(a<=2047){if(r+1>=s)break;e[r++]=192|a>>6,e[r++]=128|a&63}else if(a<=65535){if(r+2>=s)break;e[r++]=224|a>>12,e[r++]=128|a>>6&63,e[r++]=128|a&63}else{if(r+3>=s)break;e[r++]=240|a>>18,e[r++]=128|a>>12&63,e[r++]=128|a>>6&63,e[r++]=128|a&63}}return e[r]=0,r-n}function u4(t,e,r){return tw(t,$u,e,r)}function rw(t){for(var e=0,r=0;r=55296&&i<=57343&&(i=65536+((i&1023)<<10)|t.charCodeAt(++r)&1023),i<=127?++e:i<=2047?e+=2:i<=65535?e+=3:e+=4}return e}function uP(t){var e=rw(t)+1,r=h4(e);return r&&tw(t,Zi,r,e),r}function Bxe(t,e){Zi.set(t,e)}function xxe(t,e){return t%e>0&&(t+=e-t%e),t}var gP,Zi,$u,cP,kxe,_e,Pxe,o4,a4;function p4(t){gP=t,oe.HEAP8=Zi=new Int8Array(t),oe.HEAP16=cP=new Int16Array(t),oe.HEAP32=_e=new Int32Array(t),oe.HEAPU8=$u=new Uint8Array(t),oe.HEAPU16=kxe=new Uint16Array(t),oe.HEAPU32=Pxe=new Uint32Array(t),oe.HEAPF32=o4=new Float32Array(t),oe.HEAPF64=a4=new Float64Array(t)}var Dst=oe.INITIAL_MEMORY||16777216,fP,d4=[],C4=[],m4=[],Dxe=!1;function Fxe(){if(oe.preRun)for(typeof oe.preRun=="function"&&(oe.preRun=[oe.preRun]);oe.preRun.length;)Rxe(oe.preRun.shift());hP(d4)}function Nxe(){Dxe=!0,!oe.noFSInit&&!y.init.initialized&&y.init(),BA.init(),hP(C4)}function Txe(){if(oe.postRun)for(typeof oe.postRun=="function"&&(oe.postRun=[oe.postRun]);oe.postRun.length;)Lxe(oe.postRun.shift());hP(m4)}function Rxe(t){d4.unshift(t)}function Mxe(t){C4.unshift(t)}function Lxe(t){m4.unshift(t)}var zl=0,pP=null,Dp=null;function Oxe(t){return t}function E4(t){zl++,oe.monitorRunDependencies&&oe.monitorRunDependencies(zl)}function dP(t){if(zl--,oe.monitorRunDependencies&&oe.monitorRunDependencies(zl),zl==0&&(pP!==null&&(clearInterval(pP),pP=null),Dp)){var e=Dp;Dp=null,e()}}oe.preloadedImages={};oe.preloadedAudios={};function Gr(t){oe.onAbort&&oe.onAbort(t),t+="",Di(t),A4=!0,wxe=1,t="abort("+t+"). Build with -s ASSERTIONS=1 for more info.";var e=new WebAssembly.RuntimeError(t);throw e}var I4="data:application/octet-stream;base64,";function y4(t){return t.startsWith(I4)}var Rp="data:application/octet-stream;base64,AGFzbQEAAAABlAInYAF/AX9gA39/fwF/YAF/AGACf38Bf2ACf38AYAV/f39/fwF/YAR/f39/AX9gA39/fwBgBH9+f38Bf2AAAX9gBX9/f35/AX5gA39+fwF/YAF/AX5gAn9+AX9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EgACgCECABKAK8LWo2ArwtCyAAIAAoAixBAWo2AiwMAQsLIAAoAjwgACgCPEGUAWogACgCOEEBaxC4ASAAKAI8IAAoAjxBiBNqIAAoAjRBAWsQuAEgAEFAayQAIAQoAiwgBCgCLEGUAWogBCgCLEGIE2oQugELCyAEKAIsEL0BIAQoAiAEQCAEKAIsELwBCyAEQTBqJAAL1AEBAX8jAEEgayICJAAgAiAANgIYIAIgATcDECACIAIoAhhFOgAPAkAgAigCGEUEQCACIAIpAxCnEBgiADYCGCAARQRAIAJBADYCHAwCCwsgAkEYEBgiADYCCCAARQRAIAItAA9BAXEEQCACKAIYEBULIAJBADYCHAwBCyACKAIIQQE6AAAgAigCCCACKAIYNgIEIAIoAgggAikDEDcDCCACKAIIQgA3AxAgAigCCCACLQAPQQFxOgABIAIgAigCCDYCHAsgAigCHCEAIAJBIGokACAAC3gBAX8jAEEQayIBJAAgASAANgIIIAEgASgCCEIEEB42AgQCQCABKAIERQRAIAFBADYCDAwBCyABIAEoAgQtAAAgASgCBC0AASABKAIELQACIAEoAgQtAANBCHRqQQh0akEIdGo2AgwLIAEoAgwhACABQRBqJAAgAAt/AQN/IAAhAQJAIABBA3EEQANAIAEtAABFDQIgAUEBaiIBQQNxDQALCwNAIAEiAkEEaiEBIAIoAgAiA0F/cyADQYGChAhrcUGAgYKEeHFFDQALIANB/wFxRQRAIAIgAGsPCwNAIAItAAEhAyACQQFqIgEhAiADDQALCyABIABrC2EBAX8jAEEQayICIAA2AgggAiABNwMAAkAgAikDACACKAIIKQMIVgRAIAIoAghBADoAACACQX82AgwMAQsgAigCCEEBOgAAIAIoAgggAikDADcDECACQQA2AgwLIAIoAgwL7wEBAX8jAEEgayICJAAgAiAANgIYIAIgATcDECACIAIoAhhCCBAeNgIMAkAgAigCDEUEQCACQX82AhwMAQsgAigCDCACKQMQQv8BgzwAACACKAIMIAIpAxBCCIhC/wGDPAABIAIoAgwgAikDEEIQiEL/AYM8AAIgAigCDCACKQMQQhiIQv8BgzwAAyACKAIMIAIpAxBCIIhC/wGDPAAEIAIoAgwgAikDEEIoiEL/AYM8AAUgAigCDCACKQMQQjCIQv8BgzwABiACKAIMIAIpAxBCOIhC/wGDPAAHIAJBADYCHAsgAigCHBogAkEgaiQAC4cDAQF/IwBBMGsiAyQAIAMgADYCJCADIAE2AiAgAyACNwMYAkAgAygCJC0AKEEBcQRAIANCfzcDKAwBCwJAAkAgAygCJCgCIEUNACADKQMYQv///////////wBWDQAgAykDGFANASADKAIgDQELIAMoAiRBDGpBEkEAEBQgA0J/NwMoDAELIAMoAiQtADVBAXEEQCADQn83AygMAQsCfyMAQRBrIgAgAygCJDYCDCAAKAIMLQA0QQFxCwRAIANCADcDKAwBCyADKQMYUARAIANCADcDKAwBCyADQgA3AxADQCADKQMQIAMpAxhUBEAgAyADKAIkIAMoAiAgAykDEKdqIAMpAxggAykDEH1BARAhIgI3AwggAkIAUwRAIAMoAiRBAToANSADKQMQUARAIANCfzcDKAwECyADIAMpAxA3AygMAwsgAykDCFAEQCADKAIkQQE6ADQFIAMgAykDCCADKQMQfDcDEAwCCwsLIAMgAykDEDcDKAsgAykDKCECIANBMGokACACCzYBAX8jAEEQayIBIAA2AgwCfiABKAIMLQAAQQFxBEAgASgCDCkDCCABKAIMKQMQfQwBC0IACwuyAQIBfwF+IwBBEGsiASQAIAEgADYCBCABIAEoAgRCCBAeNgIAAkAgASgCAEUEQCABQgA3AwgMAQsgASABKAIALQAArSABKAIALQAHrUI4hiABKAIALQAGrUIwhnwgASgCAC0ABa1CKIZ8IAEoAgAtAAStQiCGfCABKAIALQADrUIYhnwgASgCAC0AAq1CEIZ8IAEoAgAtAAGtQgiGfHw3AwgLIAEpAwghAiABQRBqJAAgAgumAQEBfyMAQRBrIgEkACABIAA2AggCQCABKAIIKAIgRQRAIAEoAghBDGpBEkEAEBQgAUF/NgIMDAELIAEoAggiACAAKAIgQQFrNgIgIAEoAggoAiBFBEAgASgCCEEAQgBBAhAhGiABKAIIKAIABEAgASgCCCg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QFGBEAgACkDCEL///////////8AWA0BCyAAKAIUQQxqQRJBABAUIABCfzcDGAwBCyAAIAAoAhQgACgCECAAKQMIQQsQITcDGAsgACkDGCECIABBIGokACADIAI3AwACQCACQgBTBEAgAygCGEEIaiADKAIYKAIAEBcgA0F/NgIcDAELIAMpAwAgAykDCFIEQCADKAIYQQhqQQZBGxAUIANBfzYCHAwBCyADQQA2AhwLIAMoAhwhACADQSBqJAAgAAtrAQF/IwBBIGsiAiAANgIcIAJCASACKAIcrYY3AxAgAkEMaiABNgIAA0AgAiACKAIMIgBBBGo2AgwgAiAAKAIANgIIIAIoAghBAEhFBEAgAiACKQMQQgEgAigCCK2GhDcDEAwBCwsgAikDEAsvAQF/IwBBEGsiASQAIAEgADYCDCABKAIMKAIIEBUgASgCDEEANgIIIAFBEGokAAvNAQEBfyMAQRBrIgIkACACIAA2AgggAiABNgIEAkAgAigCCC0AKEEBcQRAIAJBfzYCDAwBCyACKAIERQRAIAIoAghBDGpBEkEAEBQgAkF/NgIMDAELIAIoAgQQOyACKAIIKAIABEAgAigCCCgCACACKAIEEDhBAEgEQCACKAIIQQxqIAIoAggoAgAQFyACQX82AgwMAgsLIAIoAgggAigCBEI4QQMQIUIAUwRAIAJBfzYCDAwBCyACQQA2AgwLIAIoAgwhACACQRBqJAAgAAsxAQF/IwBBEGsiASQAIAEgADYCDCABKAIMBEAgASgCDBBdIAEoAgwQFQsgAUEQaiQAC98EAQF/IwBBIGsiAiAANgIYIAIgATYCFAJAIAIoAhhFBEAgAkEBNgIcDAELIAIgAigCGCgCADYCDAJAIAIoAhgoAggEQCACIAIoAhgoAgg2AhAMAQsgAkEBNgIQIAJBADYCCANAAkAgAigCCCACKAIYLwEETw0AAkAgAigCDCACKAIIai0AAEEfSwRAIAIoAgwgAigCCGotAABBgAFJDQELIAIoAgwgAigCCGotAABBDUYNACACKAIMIAIoAghqLQAAQQpGDQAgAigCDCACKAIIai0AAEEJRgRADAELIAJBAzYCEAJAIAIoAgwgAigCCGot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kAgAygCpAEpAyBC/////w9UBEAgAygCTCADKAKkASkDIKcQIAwBCyADKAJMQX8QIAsCQCADKAKkASkDKEL/////D1QEQCADKAJMIAMoAqQBKQMopxAgDAELIAMoAkxBfxAgCwsgAygCTCADKAKkASgCMBBTQf//A3EQHyADIAMoAqQBKAI0IAMoAqABEIYBQf//A3EgAygCkAFBgAYQhgFB//8DcWo2AogBIAMoAkwgAygCiAFB//8DcRAfIAMoAqABQYACcUUEQCADKAJMIAMoAqQBKAI4EFNB//8DcRAfIAMoAkwgAygCpAEoAjxB//8DcRAfIAMoAkwgAygCpAEvAUAQHyADKAJMIAMoAqQBKAJEECACQCADKAKkASkDSEL/////D1QEQCADKAJMIAMoAqQBKQNIpxAgDAELIAMoAkxBfxAgCwsCfyMAQRBrIgAgAygCTDYCDCAAKAIMLQAAQQFxRQsEQCADKAKoAUEIakEUQQAQFCADKAJMEBYgAygCkAEQIyADQX82AqwBDAELIAMoAqgBIANB0ABqAn4jAEEQayIAIAMoAkw2AgwCfiAAKAIMLQAAQQFxBEAgACgCDCkDEAwBC0IACwsQNUEASARAIAMoAkwQFiADKAKQARAjIANBfzYCrAEMAQsgAygCTBAWIAMoAqQBKAIwBEAgAygCqAEgAygCpAEoAjAQigFBAEgEQCADKAKQARAjIANBfzYCrAEMAgsLIAMoApABBEAgAygCqAEgAygCkAFBgAYQhQFBAEgEQCADKAKQARAjIANBfzYCrAEMAgsLIAMoApABECMgAygCpAEoAjQEQCADKAKoASADKAKkASgCNCADKAKgARCFAUEASARAIANBfzYCrAEMAgsLIAMoAqABQYACcUUEQCADKAKkASgCOARAIAMoAqgBIAMoAqQBKAI4EIoBQQBIBEAgA0F/NgKsAQwDCwsLIAMgAy0AhwFBAXE2AqwBCyADKAKsASEAIANBsAFqJAAgAAvgAgEBfyMAQSBrIgQkACAEIAA7ARogBCABOwEYIAQgAjYCFCAEIAM2AhAgBEEQEBgiADYCDAJAIABFBEAgBEEANgIcDAELIAQoAgxBADYCACAEKAIMIAQ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iABKAIMQQA2AiQLIAFBEGokAAumAQEBfyMAQRBrIgIkACACIAA2AgggAiABNgIEAkAgAigCCC0AKEEBcQRAIAJBfzYCDAwBCyACKAIIKAIABEAgAigCCCgCACACKAIEEGhBAEgEQCACKAIIQQxqIAIoAggoAgAQFyACQX82AgwMAgsLIAIoAgggAkEEakIEQRMQIUIAUwRAIAJBfzYCDAwBCyACQQA2AgwLIAIoAgwhACACQRBqJAAgAAuNCAIBfwF+IwBBkAFrIgMkACADIAA2AoQBIAMgATYCgAEgAyACNgJ8IAMQTwJAIAMoAoABKQMIQgBSBEAgAyADKAKAASgCACgCACkDSDcDYCADIAMoAoABKAIAKAIAKQNINwNoDAELIANCADcDYCADQgA3A2gLIANCADcDcAJAA0AgAykDcCADKAKAASkDCFQEQCADKAKAASgCACADKQNwp0EEdGooAgApA0ggAykDaFQEQCADIAMoAoABKAIAIAMpA3CnQQR0aigCACkDSDcDaAsgAykDaCADKAKAASkDIFYEQCADKAJ8QRNBABAUIANCfzcDiAEMAwsgAyADKAKAASgCACADKQNwp0EEdGooAgApA0ggAygCgAEoAgAgAykDcKdBBHRqKAIAKQMgfCADKAKAASgCACADKQNwp0EEdGooAgAoAjAQU0H//wNxrXxCHnw3A1ggAykDWCADKQNgVgRAIAMgAykDWDcDYAsgAykDYCADKAKAASkDIFYEQCADKAJ8QRNBABAUIANCfzcDiAEMAwsgAygChAEoAgAgAygCgAEoAgAgAykDcKdBBHRqKAIAKQNIQQAQJ0EASARAIAMoAnwgAygChAEoAgAQFyADQn83A4gBDAMLIAMgAygChAEoAgBBAEEBIAMoAnwQxgFCf1EEQCADEF0gA0J/NwOIAQwDCwJ/IAMoAoABKAIAIAMpA3CnQQR0aigCACEBIwBBEGsiACQAIAAgATYCCCAAIAM2AgQCQAJAAkAgACgCCC8BCiAAKAIELwEKSA0AIAAoAggoAhAgACgCBCgCEEcNACAAKAIIKAIUIAAoAgQoAhRHDQAgACgCCCgCMCAAKAIEKAIwEIsBDQELIABBfzYCD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DAwBCyABQQA2AgwLIAEoAgwL0gQBAX8jAEEgayIDIAA2AhwgAyABNgIYIAMgAjYCFCADIAMoAhxB3BZqIAMoAhRBAnRqKAIANgIQIAMgAygCFEEBdDYCDANAAkAgAygCDCADKAIcKALQKEoNAAJAIAMoAgwgAygCHCgC0ChODQAgAygCGCADKAIcIAMoAgxBAnRqQeAWaigCAEECdGovAQAgAygCGCADKAIcQdwWaiADKAIMQQJ0aigCAEECdGovAQBOBEAgAygCGCADKAIcIAMoAgxBAnRqQeAWaigCAEECdGovAQAgAygCGCADKAIcQdwWaiADKAIMQQJ0aigCAEECdGovAQBHDQEgAygCHCADKAIMQQJ0akHgFmooAgAgAygCHEHYKGpqLQAAIAMoAhxB3BZqIAMoAgxBAnRqKAIAIAMoAhxB2Chqai0AAEoNAQsgAyADKAIMQQFqNgIMCyADKAIYIAMoAhBBAnRqLwEAIAMoAhggAygCHEHcFmogAygCDEECdGooAgBBAnRqLwEASA0AAkAgAygCGCADKAIQQQJ0ai8BACADKAIYIAMoAhxB3BZqIAMoAgxBAnRqKAIAQQJ0ai8BAEcNACADKAIQIAMoAhxB2Chqai0AACADKAIcQdwWaiADKAIMQQJ0aigCACADKAIcQdgoamotAABKDQAMAQsgAygCHEHcFmogAygCFEECdGogAygCHEHcFmogAygCDEECdGooAgA2AgAgAyADKAIMNgIUIAMgAygCDEEBdDYCDAwBCwsgAygCHEHcFmogAygCFEECdGogAygCEDYCAAvXEwEDfyMAQTBrIgIkACACIAA2AiwgAiABNgIoIAIgAigCKCgCADYCJCACIAIoAigoAggoAgA2AiAgAiACKAIoKAIIKAIMNgIcIAJBfzYCECACKAIsQQA2AtAoIAIoAixBvQQ2AtQoIAJBADYCGANAIAIoAhggAigCHEgEQAJAIAIoAiQgAigCGEECdGovAQAEQCACIAIoAhgiATYCECACKAIsQdwWaiEDIAIoAiwiBCgC0ChBAWohACAEIAA2AtAoIABBAnQgA2ogATYCACACKAIYIAIoAixB2ChqakEAOgAADAELIAIoAiQgAigCGEECdGpBADsBAgsgAiACKAIYQQFqNgIYDAELCwNAIAIoAiwoAtAoQQJIBEACQCACKAIQQQJIBEAgAiACKAIQQQFqIgA2AhAMAQtBACEACyACKAIsQdwWaiEDIAIoAiwiBCgC0ChBAWohASAEIAE2AtAoIAFBAnQgA2ogADYCACACIAA2AgwgAigCJCACKAIMQQJ0akEBOwEAIAIoAgwgAigCLEHYKGpqQQA6AAAgAigCLCIAIAAoAqgtQQFrNgKoLSACKAIgBEAgAigCLCIAIAAoAqwtIAIoAiAgAigCDEECdGovAQJrNgKsLQsMAQsLIAIoAiggAigCEDYCBCACIAIoAiwoAtAoQQJtNgIYA0AgAigCGEEBTgRAIAIoAiwgAigCJCACKAIYEHogAiACKAIYQQFrNgIYDAELCyACIAIoAhw2AgwDQCACIAIoAiwoAuAWNgIYIAIoAixB3BZqIQEgAigCLCIDKALQKCEAIAMgAEEBazYC0CggAigCLCAAQQJ0IAFqKAIANgLgFiACKAIsIAIoAiRBARB6IAIgAigCLCgC4BY2AhQgAigCGCEBIAIoAixB3BZqIQMgAigCLCIEKALUKEEBayEAIAQgADYC1CggAEECdCADaiABNgIAIAIoAhQhASACKAIsQdwWaiEDIAIoAiwiBCgC1ChBAWshACAEIAA2AtQoIABBAnQgA2ogATYCACACKAIkIAIoAgxBAnRqIAIoAiQgAigCGEECdGovAQAgAigCJCACKAIUQQJ0ai8BAGo7AQAgAigCDCACKAIsQdgoamoCfyACKAIYIAIoAixB2Chqai0AACACKAIUIAIoAixB2Chqai0AAE4EQCACKAIYIAIoAixB2Chqai0AAAwBCyACKAIUIAIoAixB2Chqai0AAAtBAWo6AAAgAigCJCACKAIUQQJ0aiACKAIMIgA7AQIgAigCJCACKAIYQQJ0aiAAOwECIAIgAigCDCIAQQFqNgIMIAIoAiwgADYC4BYgAigCLCACKAIkQQEQeiACKAIsKALQKEECTg0ACyACKAIsKALgFiEBIAIoAixB3BZqIQMgAigCLCIEKALUKEEBayEAIAQgADYC1CggAEECdCADaiABNg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gayICJAAgAiAANwMQIAIgATYCDCACQTAQGCIBNgIIAkAgAUUEQCACKAIMQQ5BABAUIAJBADYCHAwBCyACKAIIQQA2AgAgAigCCEIANwMQIAIoAghCADcDCCACKAIIQgA3AyAgAigCCEIANwMYIAIoAghBADYCKCACKAIIQQA6ACwgAigCCCACKQMQIAIoAgwQgwFBAXFFBEAgAigCCBAkIAJBADYCHAwBCyACIAIoAgg2AhwLIAIoAhwhASACQSBqJAAgAQvWAgEBfyMAQSBrIgMkACADIAA2AhggAyABNgIUIAMgAjYCECADIANBDGpCBBApNgIIAkAgAygCCEUEQCADQX82AhwMAQsDQCADKAIUBEAgAygCFCgCBCADKAIQcUGABnEEQCADKAIIQgAQLBogAygCCCADKAIULwEIEB8gAygCCCADKAIULwEKEB8CfyMAQRBrIgAgAygCCDYCDCAAKAIMLQAAQQFxRQsEQCADKAIYQQhqQRRBABAUIAMoAggQFiADQX82AhwMBAsgAygCGCADQQxqQgQQNUEASARAIAMoAggQFiADQX82AhwMBAsgAygCFC8BCgRAIAMoAhggAygCFCgCDCADKAIULwEKrRA1QQBIBEAgAygCCBAWIANBfzYCHAwFCwsLIAMgAygCFCgCADYCFAwBCwsgAygCCBAWIANBADYCHAsgAygCHCEAIANBIGokACAAC2gBAX8jAEEQayICIAA2AgwgAiABNgIIIAJBADsBBgNAIAIoAgwEQCACKAIMKAIEIAIoAghxQYAGcQRAIAIgAigCDC8BCiACLwEGQQRqajsBBgsgAiACKAIMKAIANgIMDAELCyACLwEGC/ABAQF/IwBBEGsiASQAIAEgADYCDCABIAEoAgw2AgggAUEANgIEA0AgASgCDARAAkACQCABKAIMLwEIQfXGAUYNACABKAIMLwEIQfXgAUYNACABKAIMLwEIQYGyAkYNACABKAIMLwEIQQFHDQELIAEgASgCDCgCADYCACABKAIIIAEoAgxGBEAgASABKAIANgIICyABKAIMQQA2AgAgASgCDBAjIAEoAgQEQCABKAIEIAEoAgA2AgALIAEgASgCADYCDAwCCyABIAEoAgw2AgQgASABKA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MAQsCQCABKAKUAUEEcUUNACABKQOAASABKQMwfCABKQOYASABKQM4fFENACABKAKQAUEVQQAQFCABQQA2AqwBDAELIAEpAyggASkDMEIugFYEQCABKAKQAUEVQQAQFCABQQA2AqwBDAELIAEgASkDKCABKAKQARCEASIFNgKMASAFRQRAIAFBADYCrAEMAQsgASgCjAFBAToALCABKAKMASABKQMwNwMYIAEoAowBIAEpA4ABNwMgIAEgASgCjAE2AqwBCyABKAKsASEFIAFBsAFqJAAgACAFNgJQDAELIAAoAmQgACkDMBAsGiAAKAJkIQUgACkDWCEJIAAoAmgoAhQhBiAAKAJUIQcjAEHQAGsiASQAIAEgBTYCSCABIAk3A0AgASAGNgI8IAEgBzYCOAJAIAEoAkgQL0IWVARAIAEoAjhBFUEAEBQgAUEANgJMDAELIwBBEGsiBSABKAJINgIMIAECfiAFKAIMLQAAQQFxBEAgBSgCDCkDEAwBC0IACzcDCCABKAJIQgQQHhogASgCSBAqBEAgASgCOEEBQQAQFCABQQA2AkwMAQsgASABKAJIEB1B//8Dca03AyggASABKAJIEB1B//8Dca03AyAgASkDICABKQMoUgRAIAEoAjhBE0EAEBQgAUEANgJMDAELIAEgASgCSBAqrTcDGCABIAEoAkgQKq03AxAgASkDECABKQMQIAEpAxh8VgRAIAEoAjhBBEEWEBQgAUEANgJMDAELIAEpAxAgASkDGHwgASkDQCABKQMIfFYEQCABKAI4QRVBABAUIAFBADYCTAwBCwJAIAEoAjxBBHFFDQAgASkDECABKQMYfCABKQNAIAEpAwh8UQ0AIAEoAjhBFUEAEBQgAUEANgJMDAELIAEgASkDICABKAI4EIQBIgU2AjQgBUUEQCABQQA2AkwMAQsgASgCNEEAOgAsIAEoAjQgASkDGDcDGCABKAI0IAEpAxA3AyAgASABKAI0NgJMCyABKAJMIQUgAUHQAGokACAAIAU2AlALIAAoAlBFBEAgAEEANgJsDAELIAAoAmQgACkDMEIUfBAsGiAAIAAoAmQQHTsBTiAAKAJQKQMgIAAoAlApAxh8IAApA1ggACkDM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AIoAiwiAEEBajYCLCAALQABIQEgAiACKAIoIgBBAWo2AihBACAALQABIAFHDQAaIAIgAigCLCIAQQFqNgIsIAAtAAEhASACIAIoAigiAEEBajYCKEEAIAAtAAEgAUcNABogAiACKAIsIgBBAWo2AiwgAC0AASEBIAIgAigCKCIAQQFqNgIoQQAgAC0AASABRw0AGiACIAIoAiwiAEEBajYCLCAALQABIQEgAiACKAIoIgBBAWo2AihBACAALQABIAFHDQAaIAIgAigCLCIAQQFqNgIsIAAtAAEhASACIAIoAigiAEEBajYCKEEAIAAtAAEgAUcNABogAiACKAIsIgBBAWo2AiwgAC0AASEBIAIgAigCKCIAQQFqNgIoQQAgAC0AASABRw0AGiACKAIsIAIoAgxJC0EBcQ0ACyACQYICIAIoAgwgAigCLGtrNgIkIAIgAigCDEGCAms2AiwgAigCJCACKAIgSgRAIAIoAjggAigCNDYCcCACIAIoAiQ2AiAgAigCJCACKAIcTg0CIAIgAigCLCACKAIgQQFrai0AADoACyACIAIoAiwgAigCIGotAAA6AAoLCyACIAIoAhQgAigCNCACKAIQcUEBdGovAQAiATYCNEEAIQAgASACKAIYSwR/IAIgAigCMEEBayIANgIwIABBAEcFQQALQQFxDQELCwJAIAIoAiAgAigCOCgCdE0EQCACIAIoAiA2AjwMAQsgAiACKAI4KAJ0NgI8CyACKAI8C5IQAQF/IwBBMGsiAiQAIAIgADYCKCACIAE2AiQgAgJ/IAIoAigoAiwgAigCKCgCDEEFa0kEQCACKAIoKAIsDAELIAIoAigoAgxBBWsLNgIgIAJBADYCECACIAIoAigoAgAoAgQ2AgwDQAJAIAJB//8DNgIcIAIgAigCKCgCvC1BKmpBA3U2AhQgAigCKCgCACgCECACKAIUSQ0AIAIgAigCKCgCACgCECACKAIUazYCFCACIAIoAigoAmwgAigCKCgCXGs2AhggAigCHCACKAIYIAIoAigoAgAoAgRqSwRAIAIgAigCGCACKAIoKAIAKAIEajYCHAsgAigCHCACKAIUSwRAIAIgAigCFDYCHAsCQCACKAIcIAIoAiBPDQACQCACKAIcRQRAIAIoAiRBBEcNAQsgAigCJEUNACACKAIcIAIoAhggAigCKCgCACgCBGpGDQELDAELQQAhACACIAIoAiRBBEYEfyACKAIcIAIoAhggAigCKCgCACgCBGpGBUEAC0EBcTYCECACKAIoQQBBACACKAIQEFwgAigCKCgCCCACKAIoKAIUQQRraiACKAIcOgAAIAIoAigoAgggAigCKCgCFEEDa2ogAigCHEEIdjoAACACKAIoKAIIIAIoAigoAhRBAmtqIAIoAhxBf3M6AAAgAigCKCgCCCACKAIoKAIUQQFraiACKAIcQX9zQQh2OgAAIAIoAigoAgAQHCACKAIYBEAgAigCGCACKAIcSwRAIAIgAigCHDYCGAsgAigCKCgCACgCDCACKAIoKAI4IAIoAigoAlxqIAIoAhgQGRogAigCKCgCACIAIAIoAhggACgCDGo2AgwgAigCKCgCACIAIAAoAhAgAigCGGs2AhAgAigCKCgCACIAIAIoAhggACgCFGo2AhQgAigCKCIAIAIoAhggACgCXGo2AlwgAiACKAIcIAIoAhhrNgIcCyACKAIcBEAgAigCKCgCACACKAIoKAIAKAIMIAIoAhwQeBogAigCKCgCACIAIAIoAhwgACgCDGo2AgwgAigCKCgCACIAIAAoAhAgAigCHGs2AhAgAigCKCgCACIAIAIoAhwgACgCFGo2AhQLIAIoAhBFDQELCyACIAIoAgwgAigCKCgCACgCBGs2AgwgAigCDARAAkAgAigCDCACKAIoKAIsTwRAIAIoAihBAjYCsC0gAigCKCgCOCACKAIoKAIAKAIAIAIoAigoAixrIAIoAigoAiwQGRogAigCKCACKAIoKAIsNgJsDAELIAIoAgwgAigCKCgCPCACKAIoKAJsa08EQCACKAIoIgAgACgCbCACKAIoKAIsazYCbCACKAIoKAI4IAIoAigoAjggAigCKCgCLGogAigCKCgCbBAZGiACKAIoKAKwLUECSQRAIAIoAigiACAAKAKwLUEBajYCsC0LCyACKAIoKAI4IAIoAigoAmxqIAIoAigoAgAoAgAgAigCDGsgAigCDBAZGiACKAIoIgAgAigCDCAAKAJsajYCbAsg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ANgIcIABFBEAgAUG4EygCADYCrAEMAQsgASgCHCEAAn8gASgCpAEEQCABKAKkAQwBC0H6EgshA0HfEkH6EiABKAKkARshAiABIAEoAqABNgIIIAEgAjYCBCABIAM2AgAgAEG+CiABEHAgASgCqAEgASgCHDYCCCABIAEoAhw2AqwBCyABKAKsASEAIAFBsAFqJAAgAAszAQF/IAAoAhQiAyABIAIgACgCECADayIBIAEgAksbIgEQGRogACAAKAIUIAFqNgIUIAILjwUCBn4BfyABIAEoAgBBD2pBcHEiAUEQajYCACAAAnwgASkDACEDIAEpAwghBiMAQSBrIggkAAJAIAZC////////////AIMiBEKAgICAgIDAgDx9IARCgICAgICAwP/DAH1UBEAgBkIEhiADQjyIhCEEIANC//////////8PgyIDQoGAgICAgICACFoEQCAEQoGAgICAgICAwAB8IQIMAgsgBEKAgICAgICAgEB9IQIgA0KAgICAgICAgAiFQgBSDQEgAiAEQgGDfCECDAELIANQIARCgICAgICAwP//AFQgBEKAgICAgIDA//8AURtFBEAgBkIEhiADQjyIhEL/////////A4NCgICAgICAgPz/AIQhAgwBC0KAgICAgICA+P8AIQIgBEL///////+//8MAVg0AQgAhAiAEQjCIpyIAQZH3AEkNACADIQIgBkL///////8/g0KAgICAgIDAAIQiBSEHAkAgAEGB9wBrIgFBwABxBEAgAiABQUBqrYYhB0IAIQIMAQsgAUUNACAHIAGtIgSGIAJBwAAgAWutiIQhByACIASGIQILIAggAjcDECAIIAc3AxgCQEGB+AAgAGsiAEHAAHEEQCAFIABBQGqtiCEDQgAhBQwBCyAARQ0AIAVBwAAgAGuthiADIACtIgKIhCEDIAUgAoghBQsgCCADNwMAIAggBTcDCCAIKQMIQgSGIAgpAwAiA0I8iIQhAiAIKQMQIAgpAxiEQgBSrSADQv//////////D4OEIgNCgYCAgICAgIAIWgRAIAJCAXwhAgwBCyADQoCAgICAgICACIVCAFINACACQgGDIAJ8IQILIAhBIGokACACIAZCgICAgICAgICAf4OEvws5AwALrRcDEn8CfgF8IwBBsARrIgkk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gCfyABKAIYKAJcQQBOBEAgASgCGCgCOCABKAIYKAJcagwBC0EACyABKAIYKAJsIAEoAhgoAlxrQQAQKCABKAIYIAEoAhgoAmw2AlwgASgCGCgCABAcIAEoAhgoAgAoAhBFBEAgAUEANgIcDAILCyABQQE2AhwLIAEoAhwhAiABQSBqJAAgAgwBCwJ/IAAoAiwoAogBQQNGBEAgACgCLCECIAAoAjQhAyMAQTBrIgEkACABIAI2AiggASADNgIkAkADQAJAIAEoAigoAnRBggJNBEAgASgCKBBbAkAgASgCKCgCdEGCAksNACABKAIkDQAgAUEANgIsDAQLIAEoAigoAnRFDQELIAEoAihBADYCYAJAIAEoAigoAnRBA0kNACABKAIoKAJsRQ0AIAEgASgCKCgCOCABKAIoKAJsakEBazYCGCABIAEoAhgtAAA2AhwgASgCHCECIAEgASgCGCIDQQFqNgIYAkAgAy0AASACRw0AIAEoAhwhAiABIAEoAhgiA0EBajYCGCADLQABIAJHDQAgASgCHCECIAEgASgCGCIDQQFqNgIYIAMtAAEgAkcNACABIAEoAigoAjggASgCKCgCbGpBggJqNgIUA0AgASgCHCECIAEgASgCGCIDQQFqNgIYAn9BACADLQABIAJHDQAaIAEoAhwhAiABIAEoAhgiA0EBajYCGEEAIAMtAAEgAkcNABogASgCHCECIAEgASgCGCIDQQFqNgIYQQAgAy0AASACRw0AGiABKAIcIQIgASABKAIYIgNBAWo2AhhBACADLQABIAJHDQAaIAEoAhwhAiABIAEoAhgiA0EBajYCGEEAIAMtAAEgAkcNABogASgCHCECIAEgASgCGCIDQQFqNgIYQQAgAy0AASACRw0AGiABKAIcIQIgASABKAIYIgNBAWo2AhhBACADLQABIAJHDQAaIAEoAhwhAiABIAEoAhgiA0EBajYCGEEAIAMtAAEgAkcNABogASgCGCABKAIUSQtBAXENAAsgASgCKEGCAiABKAIUIAEoAhhrazYCYCABKAIoKAJgIAEoAigoAnRLBEAgASgCKCABKAIoKAJ0NgJgCwsLAkAgASgCKCgCYEEDTwRAIAEgASgCKCgCYEEDazoAEyABQQE7ARAgASgCKCICKAKkLSACKAKgLUEBdGogAS8BEDsBACABLQATIQMgASgCKCICKAKYLSEEIAIgAigCoC0iAkEBajYCoC0gAiAEaiADOgAAIAEgAS8BEEEBazsBECABKAIoIAEtABNB0N0Aai0AAEECdGpBmAlqIgIgAi8BAEEBajsBACABKAIoQYgTagJ/IAEvARBBgAJJBEAgAS8BEC0A0FkMAQsgAS8BEEEHdkGAAmotANBZC0ECdGoiAiACLwEAQQFqOwEAIAEgASgCKCgCoC0gASgCKCgCnC1BAWtGNgIgIAEoAigiAiACKAJ0IAEoAigoAmBrNgJ0IAEoAigiAiABKAIoKAJgIAIoAmxqNgJsIAEoAihBADYCYAwBCyABIAEoAigiAigCOCACKAJsai0AADoADyABKAIoIgIoAqQtIAIoAqAtQQF0akEAOwEAIAEtAA8hAyABKAIoIgIoApgtIQQgAiACKAKgLSICQQFqNgKgLSACIARqIAM6AAAgASgCKCABLQAPQQJ0aiICIAIvAZQBQQFqOwGUASABIAEoAigoAqAtIAEoAigoApwtQQFrRjYCICABKAIoIgIgAigCdEEBazYCdCABKAIoIgIgAigCbEEBajYCbAsgASgCIARAIAEoAigCfyABKAIoKAJcQQBOBEAgASgCKCgCOCABKAIoKAJcagwBC0EACyABKAIoKAJsIAEoAigoAlxrQQAQKCABKAIoIAEoAigoAmw2AlwgASgCKCgCABAcIAEoAigoAgAoAhBFBEAgAUEANgIsDAQLCwwBCwsgASgCKEEANgK0LSABKAIkQQRGBEAgASgCKAJ/IAEoAigoAlxBAE4EQCABKAIoKAI4IAEoAigoAlxqDAELQQALIAEoAigoAmwgASgCKCgCXGtBARAoIAEoAiggASgCKCgCbDYCXCABKAIoKAIAEBwgASgCKCgCACgCEEUEQCABQQI2AiwMAgsgAUEDNgIsDAELIAEoAigoAqAtBEAgASgCKAJ/IAEoAigoAlxBAE4EQCABKAIoKAI4IAEoAigoAlxqDAELQQALIAEoAigoAmwgASgCKCgCXGtBABAoIAEoAiggASgCKCgCbDYCXC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CyABKAIMQRBxBEAgASABLwESNgIIIAEgASgCDEEPcTYCDCABKAIMBEAgASgCKCABKAIMSQRAIAEgASgCUCICQQFqNgJQIAEgASgCLCACLQAAIAEoAih0ajYCLCABIAEoAihBCGo2AigLIAEgASgCCCABKAIsQQEgASgCDHRBAWtxajYCCCABIAEoAiwgASgCDHY2AiwgASABKAIoIAEoAgxrNgIoCyABKAIoQQ9JBEAgASABKAJQIgJBAWo2AlAgASABKAIsIAItAAAgASgCKHRqNgIsIAEgASgCKEEIajYCKCABIAEoAlAiAkEBajYCUCABIAEoAiwgAi0AACABKAIodGo2AiwgASABKAIoQQhqNgIoCyABIAEoAiAgASgCLCABKAIYcUECdGooAQA2ARACQANAIAEgAS0AETYCDCABIAEoAiwgASgCDHY2AiwgASABKAIoIAEoAgxrNgIoIAEgAS0AEDYCDCABKAIMQRBxBEAgASABLwESNgIEIAEgASgCDEEPcTYCDCABKAIoIAEoAgxJBEAgASABKAJQIgJBAWo2AlAgASABKAIsIAItAAAgASgCKHRqNgIsIAEgASgCKEEIajYCKCABKAIoIAEoAgxJBEAgASABKAJQIgJBAWo2AlAgASABKAIsIAItAAAgASgCKHRqNgIsIAEgASgCKEEIajYCKAsLIAEgASgCBCABKAIsQQEgASgCDHRBAWtxajYCBCABIAEoAiwgASgCDHY2AiwgASABKAIoIAEoAgxrNgIoIAEgASgCSCABKAJEazYCDAJAIAEoAgQgASgCDEsEQCABIAEoAgQgASgCDGs2AgwgASgCDCABKAI4SwRAIAEoAlQoAsQ3BEAgASgCXEHdDDYCGCABKAJUQdH+ADYCBAwKCwsgASABKAIwNgIAAkAgASgCNEUEQCABIAEoAgAgASgCPCABKAIMa2o2AgAgASgCDCABKAIISQRAIAEgASgCCCABKAIMazYCCANAIAEgASgCACICQQFqNgIAIAItAAAhAiABIAEoAkgiA0EBajYCSCADIAI6AAAgASABKAIMQQFrIgI2AgwgAg0ACyABIAEoAkggASgCBGs2AgALDAELAkAgASgCNCABKAIMSQRAIAEgASgCACABKAI8IAEoAjRqIAEoAgxrajYCACABIAEoAgwgASgCNGs2AgwgASgCDCABKAIISQRAIAEgASgCCCABKAIMazYCCANAIAEgASgCACICQQFqNgIAIAItAAAhAiABIAEoAkgiA0EBajYCSCADIAI6AAAgASABKAIMQQFrIgI2AgwgAg0ACyABIAEoAjA2AgAgASgCNCABKAIISQRAIAEgASgCNDYCDCABIAEoAgggASgCDGs2AggDQCABIAEoAgAiAkEBajYCACACLQAAIQIgASABKAJIIgNBAWo2AkggAyACOgAAIAEgASgCDEEBayICNgIMIAINAAsgASABKAJIIAEoAgRrNgIACwsMAQsgASABKAIAIAEoAjQgASgCDGtqNgIAIAEoAgwgASgCCEkEQCABIAEoAgggASgCDGs2AggDQCABIAEoAgAiAkEBajYCACACLQAAIQIgASABKAJIIgNBAWo2AkggAyACOgAAIAEgASgCDEEBayICNgIMIAINAAsgASABKAJIIAEoAgRrNgIACwsLA0AgASgCCEECSwRAIAEgASgCACICQQFqNgIAIAItAAAhAiABIAEoAkgiA0EBajYCSCADIAI6AAAgASABKAIAIgJBAWo2AgAgAi0AACECIAEgASgCSCIDQQFqNgJIIAMgAjoAACABIAEoAgAiAkEBajYCACACLQAAIQIgASABKAJIIgNBAWo2AkggAyACOgAAIAEgASgCCEEDazYCCAwBCwsMAQsgASABKAJIIAEoAgRrNgIAA0AgASABKAIAIgJBAWo2AgAgAi0AACECIAEgASgCSCIDQQFqNgJIIAMgAjoAACABIAEoAgAiAkEBajYCACACLQAAIQIgASABKAJIIgNBAWo2AkggAyACOgAAIAEgASgCACICQQFqNgIAIAItAAAhAiABIAEoAkgiA0EBajYCSCADIAI6AAAgASABKAIIQQNrNgIIIAEoAghBAksNAAsLIAEoAggEQCABIAEoAgAiAkEBajYCACACLQAAIQIgASABKAJIIgNBAWo2AkggAyACOgAAIAEoAghBAUsEQCABIAEoAgAiAkEBajYCACACLQAAIQIgASABKAJIIgNBAWo2AkggAyACOgAACwsMAgsgASgCDEHAAHFFBEAgASABKAIgIAEvAR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kAAAAgAIAAAgEABAkAAAAgAAIBAgEAEAkAQYDwAAulAgMABAAFAAYABwAIAAkACgALAA0ADwARABMAFwAbAB8AIwArADMAOwBDAFMAYwBzAIMAowDDAOMAAgEAAAAAAAAQABAAEAAQABAAEAAQABAAEQARABEAEQASABIAEgASABMAEwATABMAFAAUABQAFAAVABUAFQAVABAATQDKAAAAAQACAAMABAAFAAcACQANABEAGQAhADEAQQBhAIEAwQABAYEBAQIBAwEEAQYBCAEMARABGAEgATABQAFgAAAAABAAEAAQABAAEQARABIAEgATABMAFAAUABUAFQAWABYAFwAXABgAGAAZABkAGgAaABsAGwAcABwAHQAdAEAAQAAQABEAEgAAAAgABwAJAAYACgAFAAsABAAMAAMADQACAA4AAQAPAEGw8gALwRFgBwAAAAhQAAAIEAAUCHMAEgcfAAAIcAAACDAAAAnAABAHCgAACGAAAAggAAAJoAAACAAAAAiAAAAIQAAACeAAEAcGAAAIWAAACBgAAAmQABMHOwAACHgAAAg4AAAJ0AARBxEAAAhoAAAIKAAACbAAAAgIAAAIiAAACEgAAAnwABAHBAAACFQAAAgUABUI4wATBysAAAh0AAAINAAACcgAEQcNAAAIZAAACCQAAAmoAAAIBAAACIQAAAhEAAAJ6AAQBwgAAAhcAAAIHAAACZgAFAdTAAAIfAAACDwAAAnYABIHFwAACGwAAAgsAAAJuAAACAwAAAiMAAAITAAACfgAEAcDAAAIUgAACBIAFQijABMHIwAACHIAAAgyAAAJxAARBwsAAAhiAAAIIgAACaQAAAgCAAAIggAACEIAAAnkABAHBwAACFoAAAgaAAAJlAAUB0MAAAh6AAAIOgAACdQAEgcTAAAIagAACCoAAAm0AAAICgAACIoAAAhKAAAJ9AAQBwUAAAhWAAAIFgBACAAAEwczAAAIdgAACDYAAAnMABEHDwAACGYAAAgmAAAJrAAACAYAAAiGAAAIRgAACewAEAcJAAAIXgAACB4AAAmcABQHYwAACH4AAAg+AAAJ3AASBxsAAAhuAAAILgAACbwAAAgOAAAIjgAACE4AAAn8AGAHAAAAC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SImrp1YDbP+3zYg/1He0K6WjcPG65Kj8QYP92W/hinovLXSWBx8NCV4Ddixw90ClLKdvV0GoqnTfoFhkA0rHxDxTrq9fGAQVseNtKIarDKS/Q/DpUIE5VxZSN/////////////////////8=";y4(Rp)||(Rp=dxe(Rp));function Kxe(t){try{if(t==Rp&&lP)return new Uint8Array(lP);var e=s4(t);if(e)return e;if(aP)return aP(t);throw"sync fetching of the wasm failed: you can preload it to Module['wasmBinary'] manually, or emcc.py will do that for you when generating HTML (but not JS)"}catch(r){Gr(r)}}function Uxe(t,e){var r,i,n;try{n=Kxe(t),i=new WebAssembly.Module(n),r=new WebAssembly.Instance(i,e)}catch(o){var s=o.toString();throw Di("failed to compile wasm module: "+s),(s.includes("imported Memory")||s.includes("memory import"))&&Di("Memory size incompatibility issues may be due to changing INITIAL_MEMORY at runtime to something too large. Use ALLOW_MEMORY_GROWTH to allow any size memory (and also make sure not to set INITIAL_MEMORY at runtime to something smaller than it was at compile time)."),o}return[r,i]}function Gxe(){var t={a:Hxe};function e(n,s){var o=n.exports;oe.asm=o,ew=oe.asm.u,p4(ew.buffer),fP=oe.asm.za,Mxe(oe.asm.v),dP("wasm-instantiate")}if(E4("wasm-instantiate"),oe.instantiateWasm)try{var r=oe.instantiateWasm(t,e);return r}catch(n){return Di("Module.instantiateWasm callback failed with error: "+n),!1}var i=Uxe(Rp,t);return e(i[0]),oe.asm}var ai,ya;function hP(t){for(;t.length>0;){var e=t.shift();if(typeof e=="function"){e(oe);continue}var r=e.func;typeof r=="number"?e.arg===void 0?fP.get(r)():fP.get(r)(e.arg):r(e.arg===void 0?null:e.arg)}}function iw(t,e){var r=new Date(_e[t>>2]*1e3);_e[e>>2]=r.getUTCSeconds(),_e[e+4>>2]=r.getUTCMinutes(),_e[e+8>>2]=r.getUTCHours(),_e[e+12>>2]=r.getUTCDate(),_e[e+16>>2]=r.getUTCMonth(),_e[e+20>>2]=r.getUTCFullYear()-1900,_e[e+24>>2]=r.getUTCDay(),_e[e+36>>2]=0,_e[e+32>>2]=0;var i=Date.UTC(r.getUTCFullYear(),0,1,0,0,0,0),n=(r.getTime()-i)/(1e3*60*60*24)|0;return _e[e+28>>2]=n,iw.GMTString||(iw.GMTString=uP("GMT")),_e[e+40>>2]=iw.GMTString,e}function jxe(t,e){return iw(t,e)}var yt={splitPath:function(t){var e=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/;return e.exec(t).slice(1)},normalizeArray:function(t,e){for(var r=0,i=t.length-1;i>=0;i--){var n=t[i];n==="."?t.splice(i,1):n===".."?(t.splice(i,1),r++):r&&(t.splice(i,1),r--)}if(e)for(;r;r--)t.unshift("..");return t},normalize:function(t){var e=t.charAt(0)==="/",r=t.substr(-1)==="/";return t=yt.normalizeArray(t.split("/").filter(function(i){return!!i}),!e).join("/"),!t&&!e&&(t="."),t&&r&&(t+="/"),(e?"/":"")+t},dirname:function(t){var e=yt.splitPath(t),r=e[0],i=e[1];return!r&&!i?".":(i&&(i=i.substr(0,i.length-1)),r+i)},basename:function(t){if(t==="/")return"/";t=yt.normalize(t),t=t.replace(/\/$/,"");var e=t.lastIndexOf("/");return e===-1?t:t.substr(e+1)},extname:function(t){return yt.splitPath(t)[3]},join:function(){var t=Array.prototype.slice.call(arguments,0);return yt.normalize(t.join("/"))},join2:function(t,e){return yt.normalize(t+"/"+e)}};function Yxe(){if(typeof crypto=="object"&&typeof crypto.getRandomValues=="function"){var t=new Uint8Array(1);return function(){return crypto.getRandomValues(t),t[0]}}else if(Wl)try{var e=require("crypto");return function(){return e.randomBytes(1)[0]}}catch(r){}return function(){Gr("randomDevice")}}var wa={resolve:function(){for(var t="",e=!1,r=arguments.length-1;r>=-1&&!e;r--){var i=r>=0?arguments[r]:y.cwd();if(typeof i!="string")throw new TypeError("Arguments to path.resolve must be strings");if(!i)return"";t=i+"/"+t,e=i.charAt(0)==="/"}return t=yt.normalizeArray(t.split("/").filter(function(n){return!!n}),!e).join("/"),(e?"/":"")+t||"."},relative:function(t,e){t=wa.resolve(t).substr(1),e=wa.resolve(e).substr(1);function r(c){for(var u=0;u=0&&c[g]==="";g--);return u>g?[]:c.slice(u,g-u+1)}for(var i=r(t.split("/")),n=r(e.split("/")),s=Math.min(i.length,n.length),o=s,a=0;a0?e=i.slice(0,n).toString("utf-8"):e=null}else typeof window!="undefined"&&typeof window.prompt=="function"?(e=window.prompt("Input: "),e!==null&&(e+=` +`)):typeof readline=="function"&&(e=readline(),e!==null&&(e+=` +`));if(!e)return null;t.input=CP(e,!0)}return t.input.shift()},put_char:function(t,e){e===null||e===10?($y(Zu(t.output,0)),t.output=[]):e!=0&&t.output.push(e)},flush:function(t){t.output&&t.output.length>0&&($y(Zu(t.output,0)),t.output=[])}},default_tty1_ops:{put_char:function(t,e){e===null||e===10?(Di(Zu(t.output,0)),t.output=[]):e!=0&&t.output.push(e)},flush:function(t){t.output&&t.output.length>0&&(Di(Zu(t.output,0)),t.output=[])}}};function mP(t){for(var e=mxe(t,65536),r=h4(e);t=e)){var i=1024*1024;e=Math.max(e,r*(r>>0),r!=0&&(e=Math.max(e,256));var n=t.contents;t.contents=new Uint8Array(e),t.usedBytes>0&&t.contents.set(n.subarray(0,t.usedBytes),0)}},resizeFileStorage:function(t,e){if(t.usedBytes!=e)if(e==0)t.contents=null,t.usedBytes=0;else{var r=t.contents;t.contents=new Uint8Array(e),r&&t.contents.set(r.subarray(0,Math.min(e,t.usedBytes))),t.usedBytes=e}},node_ops:{getattr:function(t){var e={};return e.dev=y.isChrdev(t.mode)?t.id:1,e.ino=t.id,e.mode=t.mode,e.nlink=1,e.uid=0,e.gid=0,e.rdev=t.rdev,y.isDir(t.mode)?e.size=4096:y.isFile(t.mode)?e.size=t.usedBytes:y.isLink(t.mode)?e.size=t.link.length:e.size=0,e.atime=new Date(t.timestamp),e.mtime=new Date(t.timestamp),e.ctime=new Date(t.timestamp),e.blksize=4096,e.blocks=Math.ceil(e.size/e.blksize),e},setattr:function(t,e){e.mode!==void 0&&(t.mode=e.mode),e.timestamp!==void 0&&(t.timestamp=e.timestamp),e.size!==void 0&&pt.resizeFileStorage(t,e.size)},lookup:function(t,e){throw y.genericErrors[44]},mknod:function(t,e,r,i){return pt.createNode(t,e,r,i)},rename:function(t,e,r){if(y.isDir(t.mode)){var i;try{i=y.lookupNode(e,r)}catch(s){}if(i)for(var n in i.contents)throw new y.ErrnoError(55)}delete t.parent.contents[t.name],t.parent.timestamp=Date.now(),t.name=r,e.contents[r]=t,e.timestamp=t.parent.timestamp,t.parent=e},unlink:function(t,e){delete t.contents[e],t.timestamp=Date.now()},rmdir:function(t,e){var r=y.lookupNode(t,e);for(var i in r.contents)throw new y.ErrnoError(55);delete t.contents[e],t.timestamp=Date.now()},readdir:function(t){var e=[".",".."];for(var r in t.contents)!t.contents.hasOwnProperty(r)||e.push(r);return e},symlink:function(t,e,r){var i=pt.createNode(t,e,511|40960,0);return i.link=r,i},readlink:function(t){if(!y.isLink(t.mode))throw new y.ErrnoError(28);return t.link}},stream_ops:{read:function(t,e,r,i,n){var s=t.node.contents;if(n>=t.node.usedBytes)return 0;var o=Math.min(t.node.usedBytes-n,i);if(o>8&&s.subarray)e.set(s.subarray(n,n+o),r);else for(var a=0;a0||i+r>2)}catch(r){throw r.code?new y.ErrnoError(tt.convertNodeCode(r)):r}return e.mode},realPath:function(t){for(var e=[];t.parent!==t;)e.push(t.name),t=t.parent;return e.push(t.mount.opts.root),e.reverse(),yt.join.apply(null,e)},flagsForNode:function(t){t&=~2097152,t&=~2048,t&=~32768,t&=~524288;var e=0;for(var r in tt.flagsForNodeMap)t&r&&(e|=tt.flagsForNodeMap[r],t^=r);if(t)throw new y.ErrnoError(28);return e},node_ops:{getattr:function(t){var e=tt.realPath(t),r;try{r=ft.lstatSync(e)}catch(i){throw i.code?new y.ErrnoError(tt.convertNodeCode(i)):i}return tt.isWindows&&!r.blksize&&(r.blksize=4096),tt.isWindows&&!r.blocks&&(r.blocks=(r.size+r.blksize-1)/r.blksize|0),{dev:r.dev,ino:r.ino,mode:r.mode,nlink:r.nlink,uid:r.uid,gid:r.gid,rdev:r.rdev,size:r.size,atime:r.atime,mtime:r.mtime,ctime:r.ctime,blksize:r.blksize,blocks:r.blocks}},setattr:function(t,e){var r=tt.realPath(t);try{if(e.mode!==void 0&&(ft.chmodSync(r,e.mode),t.mode=e.mode),e.timestamp!==void 0){var i=new Date(e.timestamp);ft.utimesSync(r,i,i)}e.size!==void 0&&ft.truncateSync(r,e.size)}catch(n){throw n.code?new y.ErrnoError(tt.convertNodeCode(n)):n}},lookup:function(t,e){var r=yt.join2(tt.realPath(t),e),i=tt.getMode(r);return tt.createNode(t,e,i)},mknod:function(t,e,r,i){var n=tt.createNode(t,e,r,i),s=tt.realPath(n);try{y.isDir(n.mode)?ft.mkdirSync(s,n.mode):ft.writeFileSync(s,"",{mode:n.mode})}catch(o){throw o.code?new y.ErrnoError(tt.convertNodeCode(o)):o}return n},rename:function(t,e,r){var i=tt.realPath(t),n=yt.join2(tt.realPath(e),r);try{ft.renameSync(i,n)}catch(s){throw s.code?new y.ErrnoError(tt.convertNodeCode(s)):s}t.name=r},unlink:function(t,e){var r=yt.join2(tt.realPath(t),e);try{ft.unlinkSync(r)}catch(i){throw i.code?new y.ErrnoError(tt.convertNodeCode(i)):i}},rmdir:function(t,e){var r=yt.join2(tt.realPath(t),e);try{ft.rmdirSync(r)}catch(i){throw i.code?new y.ErrnoError(tt.convertNodeCode(i)):i}},readdir:function(t){var e=tt.realPath(t);try{return ft.readdirSync(e)}catch(r){throw r.code?new y.ErrnoError(tt.convertNodeCode(r)):r}},symlink:function(t,e,r){var i=yt.join2(tt.realPath(t),e);try{ft.symlinkSync(r,i)}catch(n){throw n.code?new y.ErrnoError(tt.convertNodeCode(n)):n}},readlink:function(t){var e=tt.realPath(t);try{return e=ft.readlinkSync(e),e=EP.relative(EP.resolve(t.mount.opts.root),e),e}catch(r){throw r.code?new y.ErrnoError(tt.convertNodeCode(r)):r}}},stream_ops:{open:function(t){var e=tt.realPath(t.node);try{y.isFile(t.node.mode)&&(t.nfd=ft.openSync(e,tt.flagsForNode(t.flags)))}catch(r){throw r.code?new y.ErrnoError(tt.convertNodeCode(r)):r}},close:function(t){try{y.isFile(t.node.mode)&&t.nfd&&ft.closeSync(t.nfd)}catch(e){throw e.code?new y.ErrnoError(tt.convertNodeCode(e)):e}},read:function(t,e,r,i,n){if(i===0)return 0;try{return ft.readSync(t.nfd,tt.bufferFrom(e.buffer),r,i,n)}catch(s){throw new y.ErrnoError(tt.convertNodeCode(s))}},write:function(t,e,r,i,n){try{return ft.writeSync(t.nfd,tt.bufferFrom(e.buffer),r,i,n)}catch(s){throw new y.ErrnoError(tt.convertNodeCode(s))}},llseek:function(t,e,r){var i=e;if(r===1)i+=t.position;else if(r===2&&y.isFile(t.node.mode))try{var n=ft.fstatSync(t.nfd);i+=n.size}catch(s){throw new y.ErrnoError(tt.convertNodeCode(s))}if(i<0)throw new y.ErrnoError(28);return i},mmap:function(t,e,r,i,n,s){if(e!==0)throw new y.ErrnoError(28);if(!y.isFile(t.node.mode))throw new y.ErrnoError(43);var o=mP(r);return tt.stream_ops.read(t,Zi,o,r,i),{ptr:o,allocated:!0}},msync:function(t,e,r,i,n){if(!y.isFile(t.node.mode))throw new y.ErrnoError(43);if(n&2)return 0;var s=tt.stream_ops.write(t,e,0,i,r,!1);return 0}}},w4={lookupPath:function(t){return{path:t,node:{mode:tt.getMode(t)}}},createStandardStreams:function(){y.streams[0]={fd:0,nfd:0,position:0,path:"",flags:0,tty:!0,seekable:!1};for(var t=1;t<3;t++)y.streams[t]={fd:t,nfd:t,position:0,path:"",flags:577,tty:!0,seekable:!1}},cwd:function(){return process.cwd()},chdir:function(){process.chdir.apply(void 0,arguments)},mknod:function(t,e){y.isDir(t)?ft.mkdirSync(t,e):ft.writeFileSync(t,"",{mode:e})},mkdir:function(){ft.mkdirSync.apply(void 0,arguments)},symlink:function(){ft.symlinkSync.apply(void 0,arguments)},rename:function(){ft.renameSync.apply(void 0,arguments)},rmdir:function(){ft.rmdirSync.apply(void 0,arguments)},readdir:function(){ft.readdirSync.apply(void 0,arguments)},unlink:function(){ft.unlinkSync.apply(void 0,arguments)},readlink:function(){return ft.readlinkSync.apply(void 0,arguments)},stat:function(){return ft.statSync.apply(void 0,arguments)},lstat:function(){return ft.lstatSync.apply(void 0,arguments)},chmod:function(){ft.chmodSync.apply(void 0,arguments)},fchmod:function(){ft.fchmodSync.apply(void 0,arguments)},chown:function(){ft.chownSync.apply(void 0,arguments)},fchown:function(){ft.fchownSync.apply(void 0,arguments)},truncate:function(){ft.truncateSync.apply(void 0,arguments)},ftruncate:function(t,e){if(e<0)throw new y.ErrnoError(28);ft.ftruncateSync.apply(void 0,arguments)},utime:function(){ft.utimesSync.apply(void 0,arguments)},open:function(t,e,r,i){typeof e=="string"&&(e=Vl.modeStringToFlags(e));var n=ft.openSync(t,tt.flagsForNode(e),r),s=i!=null?i:y.nextfd(n),o={fd:s,nfd:n,position:0,path:t,flags:e,seekable:!0};return y.streams[s]=o,o},close:function(t){t.stream_ops||ft.closeSync(t.nfd),y.closeStream(t.fd)},llseek:function(t,e,r){if(t.stream_ops)return Vl.llseek(t,e,r);var i=e;if(r===1)i+=t.position;else if(r===2)i+=ft.fstatSync(t.nfd).size;else if(r!==0)throw new y.ErrnoError(eg.EINVAL);if(i<0)throw new y.ErrnoError(eg.EINVAL);return t.position=i,i},read:function(t,e,r,i,n){if(t.stream_ops)return Vl.read(t,e,r,i,n);var s=typeof n!="undefined";!s&&t.seekable&&(n=t.position);var o=ft.readSync(t.nfd,tt.bufferFrom(e.buffer),r,i,n);return s||(t.position+=o),o},write:function(t,e,r,i,n){if(t.stream_ops)return Vl.write(t,e,r,i,n);t.flags&+"1024"&&y.llseek(t,0,+"2");var s=typeof n!="undefined";!s&&t.seekable&&(n=t.position);var o=ft.writeSync(t.nfd,tt.bufferFrom(e.buffer),r,i,n);return s||(t.position+=o),o},allocate:function(){throw new y.ErrnoError(eg.EOPNOTSUPP)},mmap:function(t,e,r,i,n,s){if(t.stream_ops)return Vl.mmap(t,e,r,i,n,s);if(e!==0)throw new y.ErrnoError(28);var o=mP(r);return y.read(t,Zi,o,r,i),{ptr:o,allocated:!0}},msync:function(t,e,r,i,n){return t.stream_ops?Vl.msync(t,e,r,i,n):(n&2||y.write(t,e,0,i,r),0)},munmap:function(){return 0},ioctl:function(){throw new y.ErrnoError(eg.ENOTTY)}},y={root:null,mounts:[],devices:{},streams:[],nextInode:1,nameTable:null,currentPath:"/",initialized:!1,ignorePermissions:!0,trackingDelegate:{},tracking:{openFlags:{READ:1,WRITE:2}},ErrnoError:null,genericErrors:{},filesystems:null,syncFSRequests:0,lookupPath:function(t,e){if(t=wa.resolve(y.cwd(),t),e=e||{},!t)return{path:"",node:null};var r={follow_mount:!0,recurse_count:0};for(var i in r)e[i]===void 0&&(e[i]=r[i]);if(e.recurse_count>8)throw new y.ErrnoError(32);for(var n=yt.normalizeArray(t.split("/").filter(function(f){return!!f}),!1),s=y.root,o="/",a=0;a40)throw new y.ErrnoError(32)}}return{path:o,node:s}},getPath:function(t){for(var e;;){if(y.isRoot(t)){var r=t.mount.mountpoint;return e?r[r.length-1]!=="/"?r+"/"+e:r+e:r}e=e?t.name+"/"+e:t.name,t=t.parent}},hashName:function(t,e){for(var r=0,i=0;i>>0)%y.nameTable.length},hashAddNode:function(t){var e=y.hashName(t.parent.id,t.name);t.name_next=y.nameTable[e],y.nameTable[e]=t},hashRemoveNode:function(t){var e=y.hashName(t.parent.id,t.name);if(y.nameTable[e]===t)y.nameTable[e]=t.name_next;else for(var r=y.nameTable[e];r;){if(r.name_next===t){r.name_next=t.name_next;break}r=r.name_next}},lookupNode:function(t,e){var r=y.mayLookup(t);if(r)throw new y.ErrnoError(r,t);for(var i=y.hashName(t.id,e),n=y.nameTable[i];n;n=n.name_next){var s=n.name;if(n.parent.id===t.id&&s===e)return n}return y.lookup(t,e)},createNode:function(t,e,r,i){var n=new y.FSNode(t,e,r,i);return y.hashAddNode(n),n},destroyNode:function(t){y.hashRemoveNode(t)},isRoot:function(t){return t===t.parent},isMountpoint:function(t){return!!t.mounted},isFile:function(t){return(t&61440)==32768},isDir:function(t){return(t&61440)==16384},isLink:function(t){return(t&61440)==40960},isChrdev:function(t){return(t&61440)==8192},isBlkdev:function(t){return(t&61440)==24576},isFIFO:function(t){return(t&61440)==4096},isSocket:function(t){return(t&49152)==49152},flagModes:{r:0,"r+":2,w:577,"w+":578,a:1089,"a+":1090},modeStringToFlags:function(t){var e=y.flagModes[t];if(typeof e=="undefined")throw new Error("Unknown file open mode: "+t);return e},flagsToPermissionString:function(t){var e=["r","w","rw"][t&3];return t&512&&(e+="w"),e},nodePermissions:function(t,e){return y.ignorePermissions?0:e.includes("r")&&!(t.mode&292)||e.includes("w")&&!(t.mode&146)||e.includes("x")&&!(t.mode&73)?2:0},mayLookup:function(t){var e=y.nodePermissions(t,"x");return e||(t.node_ops.lookup?0:2)},mayCreate:function(t,e){try{var r=y.lookupNode(t,e);return 20}catch(i){}return y.nodePermissions(t,"wx")},mayDelete:function(t,e,r){var i;try{i=y.lookupNode(t,e)}catch(s){return s.errno}var n=y.nodePermissions(t,"wx");if(n)return n;if(r){if(!y.isDir(i.mode))return 54;if(y.isRoot(i)||y.getPath(i)===y.cwd())return 10}else if(y.isDir(i.mode))return 31;return 0},mayOpen:function(t,e){return t?y.isLink(t.mode)?32:y.isDir(t.mode)&&(y.flagsToPermissionString(e)!=="r"||e&512)?31:y.nodePermissions(t,y.flagsToPermissionString(e)):44},MAX_OPEN_FDS:4096,nextfd:function(t,e){t=t||0,e=e||y.MAX_OPEN_FDS;for(var r=t;r<=e;r++)if(!y.streams[r])return r;throw new y.ErrnoError(33)},getStream:function(t){return y.streams[t]},createStream:function(t,e,r){y.FSStream||(y.FSStream=function(){},y.FSStream.prototype={object:{get:function(){return this.node},set:function(o){this.node=o}},isRead:{get:function(){return(this.flags&2097155)!=1}},isWrite:{get:function(){return(this.flags&2097155)!=0}},isAppend:{get:function(){return this.flags&1024}}});var i=new y.FSStream;for(var n in t)i[n]=t[n];t=i;var s=y.nextfd(e,r);return t.fd=s,y.streams[s]=t,t},closeStream:function(t){y.streams[t]=null},chrdev_stream_ops:{open:function(t){var e=y.getDevice(t.node.rdev);t.stream_ops=e.stream_ops,t.stream_ops.open&&t.stream_ops.open(t)},llseek:function(){throw new y.ErrnoError(70)}},major:function(t){return t>>8},minor:function(t){return t&255},makedev:function(t,e){return t<<8|e},registerDevice:function(t,e){y.devices[t]={stream_ops:e}},getDevice:function(t){return y.devices[t]},getMounts:function(t){for(var e=[],r=[t];r.length;){var i=r.pop();e.push(i),r.push.apply(r,i.mounts)}return e},syncfs:function(t,e){typeof t=="function"&&(e=t,t=!1),y.syncFSRequests++,y.syncFSRequests>1&&Di("warning: "+y.syncFSRequests+" FS.syncfs operations in flight at once, probably just doing extra work");var r=y.getMounts(y.root.mount),i=0;function n(o){return y.syncFSRequests--,e(o)}function s(o){if(o)return s.errored?void 0:(s.errored=!0,n(o));++i>=r.length&&n(null)}r.forEach(function(o){if(!o.type.syncfs)return s(null);o.type.syncfs(o,t,s)})},mount:function(t,e,r){var i=r==="/",n=!r,s;if(i&&y.root)throw new y.ErrnoError(10);if(!i&&!n){var o=y.lookupPath(r,{follow_mount:!1});if(r=o.path,s=o.node,y.isMountpoint(s))throw new y.ErrnoError(10);if(!y.isDir(s.mode))throw new y.ErrnoError(54)}var a={type:t,opts:e,mountpoint:r,mounts:[]},l=t.mount(a);return l.mount=a,a.root=l,i?y.root=l:s&&(s.mounted=a,s.mount&&s.mount.mounts.push(a)),l},unmount:function(t){var e=y.lookupPath(t,{follow_mount:!1});if(!y.isMountpoint(e.node))throw new y.ErrnoError(28);var r=e.node,i=r.mounted,n=y.getMounts(i);Object.keys(y.nameTable).forEach(function(o){for(var a=y.nameTable[o];a;){var l=a.name_next;n.includes(a.mount)&&y.destroyNode(a),a=l}}),r.mounted=null;var s=r.mount.mounts.indexOf(i);r.mount.mounts.splice(s,1)},lookup:function(t,e){return t.node_ops.lookup(t,e)},mknod:function(t,e,r){var i=y.lookupPath(t,{parent:!0}),n=i.node,s=yt.basename(t);if(!s||s==="."||s==="..")throw new y.ErrnoError(28);var o=y.mayCreate(n,s);if(o)throw new y.ErrnoError(o);if(!n.node_ops.mknod)throw new y.ErrnoError(63);return n.node_ops.mknod(n,s,e,r)},create:function(t,e){return e=e!==void 0?e:438,e&=4095,e|=32768,y.mknod(t,e,0)},mkdir:function(t,e){return e=e!==void 0?e:511,e&=511|512,e|=16384,y.mknod(t,e,0)},mkdirTree:function(t,e){for(var r=t.split("/"),i="",n=0;nthis.length-1||f<0)){var h=f%this.chunkSize,p=f/this.chunkSize|0;return this.getter(p)[h]}},s.prototype.setDataGetter=function(f){this.getter=f},s.prototype.cacheLength=function(){var f=new XMLHttpRequest;if(f.open("HEAD",r,!1),f.send(null),!(f.status>=200&&f.status<300||f.status===304))throw new Error("Couldn't load "+r+". Status: "+f.status);var h=Number(f.getResponseHeader("Content-length")),p,d=(p=f.getResponseHeader("Accept-Ranges"))&&p==="bytes",m=(p=f.getResponseHeader("Content-Encoding"))&&p==="gzip",I=1024*1024;d||(I=h);var B=function(R,H){if(R>H)throw new Error("invalid range ("+R+", "+H+") or no bytes requested!");if(H>h-1)throw new Error("only "+h+" bytes available! programmer error!");var L=new XMLHttpRequest;if(L.open("GET",r,!1),h!==I&&L.setRequestHeader("Range","bytes="+R+"-"+H),typeof Uint8Array!="undefined"&&(L.responseType="arraybuffer"),L.overrideMimeType&&L.overrideMimeType("text/plain; charset=x-user-defined"),L.send(null),!(L.status>=200&&L.status<300||L.status===304))throw new Error("Couldn't load "+r+". Status: "+L.status);return L.response!==void 0?new Uint8Array(L.response||[]):CP(L.responseText||"",!0)},b=this;b.setDataGetter(function(R){var H=R*I,L=(R+1)*I-1;if(L=Math.min(L,h-1),typeof b.chunks[R]=="undefined"&&(b.chunks[R]=B(H,L)),typeof b.chunks[R]=="undefined")throw new Error("doXHR failed!");return b.chunks[R]}),(m||!h)&&(I=h=1,h=this.getter(0).length,I=h,$y("LazyFiles on gzip forces download of the whole file when length is accessed")),this._length=h,this._chunkSize=I,this.lengthKnown=!0},typeof XMLHttpRequest!="undefined"){if(!i4)throw"Cannot do synchronous binary XHRs outside webworkers in modern browsers. Use --embed-file or --preload-file in emcc";var o=new s;Object.defineProperties(o,{length:{get:function(){return this.lengthKnown||this.cacheLength(),this._length}},chunkSize:{get:function(){return this.lengthKnown||this.cacheLength(),this._chunkSize}}});var a={isDevice:!1,contents:o}}else var a={isDevice:!1,url:r};var l=y.createFile(t,e,a,i,n);a.contents?l.contents=a.contents:a.url&&(l.contents=null,l.url=a.url),Object.defineProperties(l,{usedBytes:{get:function(){return this.contents.length}}});var c={},u=Object.keys(l.stream_ops);return u.forEach(function(g){var f=l.stream_ops[g];c[g]=function(){return y.forceLoadFile(l),f.apply(null,arguments)}}),c.read=function(f,h,p,d,m){y.forceLoadFile(l);var I=f.node.contents;if(m>=I.length)return 0;var B=Math.min(I.length-m,d);if(I.slice)for(var b=0;b>2]=i.dev,_e[r+4>>2]=0,_e[r+8>>2]=i.ino,_e[r+12>>2]=i.mode,_e[r+16>>2]=i.nlink,_e[r+20>>2]=i.uid,_e[r+24>>2]=i.gid,_e[r+28>>2]=i.rdev,_e[r+32>>2]=0,ya=[i.size>>>0,(ai=i.size,+Math.abs(ai)>=1?ai>0?(Math.min(+Math.floor(ai/4294967296),4294967295)|0)>>>0:~~+Math.ceil((ai-+(~~ai>>>0))/4294967296)>>>0:0)],_e[r+40>>2]=ya[0],_e[r+44>>2]=ya[1],_e[r+48>>2]=4096,_e[r+52>>2]=i.blocks,_e[r+56>>2]=i.atime.getTime()/1e3|0,_e[r+60>>2]=0,_e[r+64>>2]=i.mtime.getTime()/1e3|0,_e[r+68>>2]=0,_e[r+72>>2]=i.ctime.getTime()/1e3|0,_e[r+76>>2]=0,ya=[i.ino>>>0,(ai=i.ino,+Math.abs(ai)>=1?ai>0?(Math.min(+Math.floor(ai/4294967296),4294967295)|0)>>>0:~~+Math.ceil((ai-+(~~ai>>>0))/4294967296)>>>0:0)],_e[r+80>>2]=ya[0],_e[r+84>>2]=ya[1],0},doMsync:function(t,e,r,i,n){var s=$u.slice(t,t+r);y.msync(e,s,n,r,i)},doMkdir:function(t,e){return t=yt.normalize(t),t[t.length-1]==="/"&&(t=t.substr(0,t.length-1)),y.mkdir(t,e,0),0},doMknod:function(t,e,r){switch(e&61440){case 32768:case 8192:case 24576:case 4096:case 49152:break;default:return-28}return y.mknod(t,e,r),0},doReadlink:function(t,e,r){if(r<=0)return-28;var i=y.readlink(t),n=Math.min(r,rw(i)),s=Zi[e+n];return u4(i,e,r+1),Zi[e+n]=s,n},doAccess:function(t,e){if(e&~7)return-28;var r,i=y.lookupPath(t,{follow:!0});if(r=i.node,!r)return-44;var n="";return e&4&&(n+="r"),e&2&&(n+="w"),e&1&&(n+="x"),n&&y.nodePermissions(r,n)?-2:0},doDup:function(t,e,r){var i=y.getStream(r);return i&&y.close(i),y.open(t,e,0,r,r).fd},doReadv:function(t,e,r,i){for(var n=0,s=0;s>2],a=_e[e+(s*8+4)>>2],l=y.read(t,Zi,o,a,i);if(l<0)return-1;if(n+=l,l>2],a=_e[e+(s*8+4)>>2],l=y.write(t,Zi,o,a,i);if(l<0)return-1;n+=l}return n},varargs:void 0,get:function(){Ot.varargs+=4;var t=_e[Ot.varargs-4>>2];return t},getStr:function(t){var e=c4(t);return e},getStreamFromFD:function(t){var e=y.getStream(t);if(!e)throw new y.ErrnoError(8);return e},get64:function(t,e){return t}};function qxe(t,e){try{return t=Ot.getStr(t),y.chmod(t,e),0}catch(r){return(typeof y=="undefined"||!(r instanceof y.ErrnoError))&&Gr(r),-r.errno}}function Wxe(t){return _e[Jxe()>>2]=t,t}function zxe(t,e,r){Ot.varargs=r;try{var i=Ot.getStreamFromFD(t);switch(e){case 0:{var n=Ot.get();if(n<0)return-28;var s;return s=y.open(i.path,i.flags,0,n),s.fd}case 1:case 2:return 0;case 3:return i.flags;case 4:{var n=Ot.get();return i.flags|=n,0}case 12:{var n=Ot.get(),o=0;return cP[n+o>>1]=2,0}case 13:case 14:return 0;case 16:case 8:return-28;case 9:return Wxe(28),-1;default:return-28}}catch(a){return(typeof y=="undefined"||!(a instanceof y.ErrnoError))&&Gr(a),-a.errno}}function Vxe(t,e){try{var r=Ot.getStreamFromFD(t);return Ot.doStat(y.stat,r.path,e)}catch(i){return(typeof y=="undefined"||!(i instanceof y.ErrnoError))&&Gr(i),-i.errno}}function _xe(t,e,r){Ot.varargs=r;try{var i=Ot.getStreamFromFD(t);switch(e){case 21509:case 21505:return i.tty?0:-59;case 21510:case 21511:case 21512:case 21506:case 21507:case 21508:return i.tty?0:-59;case 21519:{if(!i.tty)return-59;var n=Ot.get();return _e[n>>2]=0,0}case 21520:return i.tty?-28:-59;case 21531:{var n=Ot.get();return y.ioctl(i,e,n)}case 21523:return i.tty?0:-59;case 21524:return i.tty?0:-59;default:Gr("bad ioctl syscall "+e)}}catch(s){return(typeof y=="undefined"||!(s instanceof y.ErrnoError))&&Gr(s),-s.errno}}function Xxe(t,e,r){Ot.varargs=r;try{var i=Ot.getStr(t),n=r?Ot.get():0,s=y.open(i,e,n);return s.fd}catch(o){return(typeof y=="undefined"||!(o instanceof y.ErrnoError))&&Gr(o),-o.errno}}function Zxe(t,e){try{return t=Ot.getStr(t),e=Ot.getStr(e),y.rename(t,e),0}catch(r){return(typeof y=="undefined"||!(r instanceof y.ErrnoError))&&Gr(r),-r.errno}}function $xe(t){try{return t=Ot.getStr(t),y.rmdir(t),0}catch(e){return(typeof y=="undefined"||!(e instanceof y.ErrnoError))&&Gr(e),-e.errno}}function eke(t,e){try{return t=Ot.getStr(t),Ot.doStat(y.stat,t,e)}catch(r){return(typeof y=="undefined"||!(r instanceof y.ErrnoError))&&Gr(r),-r.errno}}function tke(t){try{return t=Ot.getStr(t),y.unlink(t),0}catch(e){return(typeof y=="undefined"||!(e instanceof y.ErrnoError))&&Gr(e),-e.errno}}function rke(t,e,r){$u.copyWithin(t,e,e+r)}function ike(t){try{return ew.grow(t-gP.byteLength+65535>>>16),p4(ew.buffer),1}catch(e){}}function nke(t){var e=$u.length;t=t>>>0;var r=2147483648;if(t>r)return!1;for(var i=1;i<=4;i*=2){var n=e*(1+.2/i);n=Math.min(n,t+100663296);var s=Math.min(r,xxe(Math.max(t,n),65536)),o=ike(s);if(o)return!0}return!1}function ske(t){try{var e=Ot.getStreamFromFD(t);return y.close(e),0}catch(r){return(typeof y=="undefined"||!(r instanceof y.ErrnoError))&&Gr(r),r.errno}}function oke(t,e){try{var r=Ot.getStreamFromFD(t),i=r.tty?2:y.isDir(r.mode)?3:y.isLink(r.mode)?7:4;return Zi[e>>0]=i,0}catch(n){return(typeof y=="undefined"||!(n instanceof y.ErrnoError))&&Gr(n),n.errno}}function ake(t,e,r,i){try{var n=Ot.getStreamFromFD(t),s=Ot.doReadv(n,e,r);return _e[i>>2]=s,0}catch(o){return(typeof y=="undefined"||!(o instanceof y.ErrnoError))&&Gr(o),o.errno}}function Ake(t,e,r,i,n){try{var s=Ot.getStreamFromFD(t),o=4294967296,a=r*o+(e>>>0),l=9007199254740992;return a<=-l||a>=l?-61:(y.llseek(s,a,i),ya=[s.position>>>0,(ai=s.position,+Math.abs(ai)>=1?ai>0?(Math.min(+Math.floor(ai/4294967296),4294967295)|0)>>>0:~~+Math.ceil((ai-+(~~ai>>>0))/4294967296)>>>0:0)],_e[n>>2]=ya[0],_e[n+4>>2]=ya[1],s.getdents&&a===0&&i===0&&(s.getdents=null),0)}catch(c){return(typeof y=="undefined"||!(c instanceof y.ErrnoError))&&Gr(c),c.errno}}function lke(t,e,r,i){try{var n=Ot.getStreamFromFD(t),s=Ot.doWritev(n,e,r);return _e[i>>2]=s,0}catch(o){return(typeof y=="undefined"||!(o instanceof y.ErrnoError))&&Gr(o),o.errno}}function cke(t){Ixe(t)}function uke(t){var e=Date.now()/1e3|0;return t&&(_e[t>>2]=e),e}function IP(){if(IP.called)return;IP.called=!0;var t=new Date().getFullYear(),e=new Date(t,0,1),r=new Date(t,6,1),i=e.getTimezoneOffset(),n=r.getTimezoneOffset(),s=Math.max(i,n);_e[fke()>>2]=s*60,_e[gke()>>2]=Number(i!=n);function o(g){var f=g.toTimeString().match(/\(([A-Za-z ]+)\)$/);return f?f[1]:"GMT"}var a=o(e),l=o(r),c=uP(a),u=uP(l);n>2]=c,_e[nw()+4>>2]=u):(_e[nw()>>2]=u,_e[nw()+4>>2]=c)}function hke(t){IP();var e=Date.UTC(_e[t+20>>2]+1900,_e[t+16>>2],_e[t+12>>2],_e[t+8>>2],_e[t+4>>2],_e[t>>2],0),r=new Date(e);_e[t+24>>2]=r.getUTCDay();var i=Date.UTC(r.getUTCFullYear(),0,1,0,0,0,0),n=(r.getTime()-i)/(1e3*60*60*24)|0;return _e[t+28>>2]=n,r.getTime()/1e3|0}var B4=function(t,e,r,i){t||(t=this),this.parent=t,this.mount=t.mount,this.mounted=null,this.id=y.nextInode++,this.name=e,this.mode=r,this.node_ops={},this.stream_ops={},this.rdev=i},sw=292|73,ow=146;Object.defineProperties(B4.prototype,{read:{get:function(){return(this.mode&sw)===sw},set:function(t){t?this.mode|=sw:this.mode&=~sw}},write:{get:function(){return(this.mode&ow)===ow},set:function(t){t?this.mode|=ow:this.mode&=~ow}},isFolder:{get:function(){return y.isDir(this.mode)}},isDevice:{get:function(){return y.isChrdev(this.mode)}}});y.FSNode=B4;y.staticInit();Wl&&(ft=e4,EP=require("path"),tt.staticInit());var ft,EP;if(Wl){Q4=function(t){return function(){try{return t.apply(this,arguments)}catch(e){throw e.code?new y.ErrnoError(eg[e.code]):e}}},Vl=Object.assign({},y);for(yP in w4)y[yP]=Q4(w4[yP])}else throw new Error("NODERAWFS is currently only supported on Node.js environment.");var Q4,Vl,yP;function CP(t,e,r){var i=r>0?r:rw(t)+1,n=new Array(i),s=tw(t,n,0,n.length);return e&&(n.length=s),n}var pke=typeof atob=="function"?atob:function(t){var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",r="",i,n,s,o,a,l,c,u=0;t=t.replace(/[^A-Za-z0-9\+\/\=]/g,"");do o=e.indexOf(t.charAt(u++)),a=e.indexOf(t.charAt(u++)),l=e.indexOf(t.charAt(u++)),c=e.indexOf(t.charAt(u++)),i=o<<2|a>>4,n=(a&15)<<4|l>>2,s=(l&3)<<6|c,r=r+String.fromCharCode(i),l!==64&&(r=r+String.fromCharCode(n)),c!==64&&(r=r+String.fromCharCode(s));while(u0||(Fxe(),zl>0))return;function e(){aw||(aw=!0,oe.calledRun=!0,!A4&&(Nxe(),oe.onRuntimeInitialized&&oe.onRuntimeInitialized(),Txe()))}oe.setStatus?(oe.setStatus("Running..."),setTimeout(function(){setTimeout(function(){oe.setStatus("")},1),e()},1)):e()}oe.run=wP;if(oe.preInit)for(typeof oe.preInit=="function"&&(oe.preInit=[oe.preInit]);oe.preInit.length>0;)oe.preInit.pop()();wP()});var x4=E((Dot,S4)=>{"use strict";function Cke(t,e){function r(){this.constructor=t}r.prototype=e.prototype,t.prototype=new r}function _l(t,e,r,i){this.message=t,this.expected=e,this.found=r,this.location=i,this.name="SyntaxError",typeof Error.captureStackTrace=="function"&&Error.captureStackTrace(this,_l)}Cke(_l,Error);_l.buildMessage=function(t,e){var r={literal:function(c){return'"'+n(c.text)+'"'},class:function(c){var u="",g;for(g=0;g0){for(g=1,f=1;g>",ee=At(">>",!1),Ue=">&",Oe=At(">&",!1),vt=">",dt=At(">",!1),ri="<<<",ii=At("<<<",!1),an="<&",yr=At("<&",!1),Ki="<",Qi=At("<",!1),Go=function(C){return{type:"argument",segments:[].concat(...C)}},wr=function(C){return C},Ui="'",ws=At("'",!1),Tf=function(C){return[{type:"text",text:C}]},Mf='"',Rm=At('"',!1),Fm=function(C){return C},Nm=function(C){return{type:"arithmetic",arithmetic:C,quoted:!0}},DQ=function(C){return{type:"shell",shell:C,quoted:!0}},RQ=function(C){return _(P({type:"variable"},C),{quoted:!0})},Of=function(C){return{type:"text",text:C}},FQ=function(C){return{type:"arithmetic",arithmetic:C,quoted:!1}},NQ=function(C){return{type:"shell",shell:C,quoted:!1}},Lm=function(C){return _(P({type:"variable"},C),{quoted:!1})},LQ=function(C){return{type:"glob",pattern:C}},Va="\\",jo=At("\\",!1),Tm=/^[\\']/,Mm=Qs(["\\","'"],!1,!1),te=function(C){return C},Om=/^[^']/,Km=Qs(["'"],!0,!1),il=function(C){return C.join("")},Um=/^[\\$"]/,Hm=Qs(["\\","$",'"'],!1,!1),Kf=/^[^$"]/,Gm=Qs(["$",'"'],!0,!1),jm="\\0",TQ=At("\\0",!1),MQ=function(){return"\0"},Ym="\\a",qm=At("\\a",!1),Jm=function(){return"a"},Wm="\\b",zm=At("\\b",!1),Vm=function(){return"\b"},Uf="\\e",OQ=At("\\e",!1),KQ=function(){return""},_m="\\f",UQ=At("\\f",!1),HQ=function(){return"\f"},O="\\n",ht=At("\\n",!1),Vc=function(){return` +`},xn="\\r",Hf=At("\\r",!1),Ye=function(){return"\r"},nl="\\t",Xm=At("\\t",!1),MM=function(){return" "},GQ="\\v",OM=At("\\v",!1),fr=function(){return"\v"},Bs="\\x",jQ=At("\\x",!1),Zm=function(C){return String.fromCharCode(parseInt(C,16))},Yo="\\u",$m=At("\\u",!1),_a="\\U",et=At("\\U",!1),YQ=function(C){return String.fromCodePoint(parseInt(C,16))},eE=/^[0-9a-fA-f]/,tE=Qs([["0","9"],["a","f"],["A","f"]],!1,!1),Xa=Cfe(),sl="-",ol=At("-",!1),al="+",qo=At("+",!1),Al=".",qQ=At(".",!1),rE=function(C,Q,k){return{type:"number",value:(C==="-"?-1:1)*parseFloat(Q.join("")+"."+k.join(""))}},iE=function(C,Q){return{type:"number",value:(C==="-"?-1:1)*parseInt(Q.join(""))}},JQ=function(C){return P({type:"variable"},C)},ll=function(C){return{type:"variable",name:C}},WQ=function(C){return C},nE="*",Gf=At("*",!1),_c="/",jf=At("/",!1),sE=function(C,Q,k){return{type:Q==="*"?"multiplication":"division",right:k}},cl=function(C,Q){return Q.reduce((k,N)=>P({left:k},N),C)},oE=function(C,Q,k){return{type:Q==="+"?"addition":"subtraction",right:k}},Yf="$((",Xc=At("$((",!1),xr="))",KM=At("))",!1),Jo=function(C){return C},Zs="$(",aE=At("$(",!1),Zc=function(C){return C},x="${",U=At("${",!1),le=":-",xe=At(":-",!1),Qe=function(C,Q){return{name:C,defaultValue:Q}},Ge=":-}",ct=At(":-}",!1),sr=function(C){return{name:C,defaultValue:[]}},Wo=function(C){return{name:C}},Afe="$",lfe=At("$",!1),cfe=function(C){return e.isGlobPattern(C)},ufe=function(C){return C},UM=/^[a-zA-Z0-9_]/,HM=Qs([["a","z"],["A","Z"],["0","9"],"_"],!1,!1),GM=function(){return dfe()},jM=/^[$@*?#a-zA-Z0-9_\-]/,YM=Qs(["$","@","*","?","#",["a","z"],["A","Z"],["0","9"],"_","-"],!1,!1),gfe=/^[(){}<>$|&; \t"']/,ffe=Qs(["(",")","{","}","<",">","$","|","&",";"," "," ",'"',"'"],!1,!1),hfe=/^[<>&; \t"']/,pfe=Qs(["<",">","&",";"," "," ",'"',"'"],!1,!1),qM=/^[ \t]/,JM=Qs([" "," "],!1,!1),w=0,Re=0,AE=[{line:1,column:1}],$s=0,zQ=[],we=0,lE;if("startRule"in e){if(!(e.startRule in i))throw new Error(`Can't start parsing from rule "`+e.startRule+'".');n=i[e.startRule]}function dfe(){return t.substring(Re,w)}function P_e(){return qf(Re,w)}function D_e(C,Q){throw Q=Q!==void 0?Q:qf(Re,w),zM([Efe(C)],t.substring(Re,w),Q)}function R_e(C,Q){throw Q=Q!==void 0?Q:qf(Re,w),Ife(C,Q)}function At(C,Q){return{type:"literal",text:C,ignoreCase:Q}}function Qs(C,Q,k){return{type:"class",parts:C,inverted:Q,ignoreCase:k}}function Cfe(){return{type:"any"}}function mfe(){return{type:"end"}}function Efe(C){return{type:"other",description:C}}function WM(C){var Q=AE[C],k;if(Q)return Q;for(k=C-1;!AE[k];)k--;for(Q=AE[k],Q={line:Q.line,column:Q.column};k$s&&($s=w,zQ=[]),zQ.push(C))}function Ife(C,Q){return new _l(C,null,null,Q)}function zM(C,Q,k){return new _l(_l.buildMessage(C,Q),C,Q,k)}function VM(){var C,Q;return C=w,Q=Jf(),Q===r&&(Q=null),Q!==r&&(Re=C,Q=s(Q)),C=Q,C}function Jf(){var C,Q,k,N,Z;if(C=w,Q=VQ(),Q!==r){for(k=[],N=ke();N!==r;)k.push(N),N=ke();k!==r?(N=_M(),N!==r?(Z=yfe(),Z===r&&(Z=null),Z!==r?(Re=C,Q=o(Q,N,Z),C=Q):(w=C,C=r)):(w=C,C=r)):(w=C,C=r)}else w=C,C=r;if(C===r)if(C=w,Q=VQ(),Q!==r){for(k=[],N=ke();N!==r;)k.push(N),N=ke();k!==r?(N=_M(),N===r&&(N=null),N!==r?(Re=C,Q=a(Q,N),C=Q):(w=C,C=r)):(w=C,C=r)}else w=C,C=r;return C}function yfe(){var C,Q,k,N,Z;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r)if(k=Jf(),k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();N!==r?(Re=C,Q=l(k),C=Q):(w=C,C=r)}else w=C,C=r;else w=C,C=r;return C}function _M(){var C;return t.charCodeAt(w)===59?(C=c,w++):(C=r,we===0&&ve(u)),C===r&&(t.charCodeAt(w)===38?(C=g,w++):(C=r,we===0&&ve(f))),C}function VQ(){var C,Q,k;return C=w,Q=XM(),Q!==r?(k=wfe(),k===r&&(k=null),k!==r?(Re=C,Q=h(Q,k),C=Q):(w=C,C=r)):(w=C,C=r),C}function wfe(){var C,Q,k,N,Z,Ee,ot;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r)if(k=Bfe(),k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();if(N!==r)if(Z=VQ(),Z!==r){for(Ee=[],ot=ke();ot!==r;)Ee.push(ot),ot=ke();Ee!==r?(Re=C,Q=p(k,Z),C=Q):(w=C,C=r)}else w=C,C=r;else w=C,C=r}else w=C,C=r;else w=C,C=r;return C}function Bfe(){var C;return t.substr(w,2)===d?(C=d,w+=2):(C=r,we===0&&ve(m)),C===r&&(t.substr(w,2)===I?(C=I,w+=2):(C=r,we===0&&ve(B))),C}function XM(){var C,Q,k;return C=w,Q=vfe(),Q!==r?(k=Qfe(),k===r&&(k=null),k!==r?(Re=C,Q=b(Q,k),C=Q):(w=C,C=r)):(w=C,C=r),C}function Qfe(){var C,Q,k,N,Z,Ee,ot;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r)if(k=bfe(),k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();if(N!==r)if(Z=XM(),Z!==r){for(Ee=[],ot=ke();ot!==r;)Ee.push(ot),ot=ke();Ee!==r?(Re=C,Q=R(k,Z),C=Q):(w=C,C=r)}else w=C,C=r;else w=C,C=r}else w=C,C=r;else w=C,C=r;return C}function bfe(){var C;return t.substr(w,2)===H?(C=H,w+=2):(C=r,we===0&&ve(L)),C===r&&(t.charCodeAt(w)===124?(C=K,w++):(C=r,we===0&&ve(J))),C}function cE(){var C,Q,k,N,Z,Ee;if(C=w,Q=oO(),Q!==r)if(t.charCodeAt(w)===61?(k=ne,w++):(k=r,we===0&&ve(q)),k!==r)if(N=$M(),N!==r){for(Z=[],Ee=ke();Ee!==r;)Z.push(Ee),Ee=ke();Z!==r?(Re=C,Q=A(Q,N),C=Q):(w=C,C=r)}else w=C,C=r;else w=C,C=r;else w=C,C=r;if(C===r)if(C=w,Q=oO(),Q!==r)if(t.charCodeAt(w)===61?(k=ne,w++):(k=r,we===0&&ve(q)),k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();N!==r?(Re=C,Q=V(Q),C=Q):(w=C,C=r)}else w=C,C=r;else w=C,C=r;return C}function vfe(){var C,Q,k,N,Z,Ee,ot,ut,Tr,ni,Yn;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r)if(t.charCodeAt(w)===40?(k=W,w++):(k=r,we===0&&ve(X)),k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();if(N!==r)if(Z=Jf(),Z!==r){for(Ee=[],ot=ke();ot!==r;)Ee.push(ot),ot=ke();if(Ee!==r)if(t.charCodeAt(w)===41?(ot=F,w++):(ot=r,we===0&&ve(D)),ot!==r){for(ut=[],Tr=ke();Tr!==r;)ut.push(Tr),Tr=ke();if(ut!==r){for(Tr=[],ni=Wf();ni!==r;)Tr.push(ni),ni=Wf();if(Tr!==r){for(ni=[],Yn=ke();Yn!==r;)ni.push(Yn),Yn=ke();ni!==r?(Re=C,Q=he(Z,Tr),C=Q):(w=C,C=r)}else w=C,C=r}else w=C,C=r}else w=C,C=r;else w=C,C=r}else w=C,C=r;else w=C,C=r}else w=C,C=r;else w=C,C=r;if(C===r){for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r)if(t.charCodeAt(w)===123?(k=pe,w++):(k=r,we===0&&ve(Ne)),k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();if(N!==r)if(Z=Jf(),Z!==r){for(Ee=[],ot=ke();ot!==r;)Ee.push(ot),ot=ke();if(Ee!==r)if(t.charCodeAt(w)===125?(ot=Pe,w++):(ot=r,we===0&&ve(qe)),ot!==r){for(ut=[],Tr=ke();Tr!==r;)ut.push(Tr),Tr=ke();if(ut!==r){for(Tr=[],ni=Wf();ni!==r;)Tr.push(ni),ni=Wf();if(Tr!==r){for(ni=[],Yn=ke();Yn!==r;)ni.push(Yn),Yn=ke();ni!==r?(Re=C,Q=re(Z,Tr),C=Q):(w=C,C=r)}else w=C,C=r}else w=C,C=r}else w=C,C=r;else w=C,C=r}else w=C,C=r;else w=C,C=r}else w=C,C=r;else w=C,C=r;if(C===r){for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r){for(k=[],N=cE();N!==r;)k.push(N),N=cE();if(k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();if(N!==r){if(Z=[],Ee=ZM(),Ee!==r)for(;Ee!==r;)Z.push(Ee),Ee=ZM();else Z=r;if(Z!==r){for(Ee=[],ot=ke();ot!==r;)Ee.push(ot),ot=ke();Ee!==r?(Re=C,Q=se(k,Z),C=Q):(w=C,C=r)}else w=C,C=r}else w=C,C=r}else w=C,C=r}else w=C,C=r;if(C===r){for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r){if(k=[],N=cE(),N!==r)for(;N!==r;)k.push(N),N=cE();else k=r;if(k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();N!==r?(Re=C,Q=be(k),C=Q):(w=C,C=r)}else w=C,C=r}else w=C,C=r}}}return C}function Sfe(){var C,Q,k,N,Z;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r){if(k=[],N=uE(),N!==r)for(;N!==r;)k.push(N),N=uE();else k=r;if(k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();N!==r?(Re=C,Q=ae(k),C=Q):(w=C,C=r)}else w=C,C=r}else w=C,C=r;return C}function ZM(){var C,Q,k;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r?(k=Wf(),k!==r?(Re=C,Q=Ae(k),C=Q):(w=C,C=r)):(w=C,C=r),C===r){for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();Q!==r?(k=uE(),k!==r?(Re=C,Q=Ae(k),C=Q):(w=C,C=r)):(w=C,C=r)}return C}function Wf(){var C,Q,k,N,Z;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();return Q!==r?(De.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve($)),k===r&&(k=null),k!==r?(N=xfe(),N!==r?(Z=uE(),Z!==r?(Re=C,Q=G(k,N,Z),C=Q):(w=C,C=r)):(w=C,C=r)):(w=C,C=r)):(w=C,C=r),C}function xfe(){var C;return t.substr(w,2)===Ce?(C=Ce,w+=2):(C=r,we===0&&ve(ee)),C===r&&(t.substr(w,2)===Ue?(C=Ue,w+=2):(C=r,we===0&&ve(Oe)),C===r&&(t.charCodeAt(w)===62?(C=vt,w++):(C=r,we===0&&ve(dt)),C===r&&(t.substr(w,3)===ri?(C=ri,w+=3):(C=r,we===0&&ve(ii)),C===r&&(t.substr(w,2)===an?(C=an,w+=2):(C=r,we===0&&ve(yr)),C===r&&(t.charCodeAt(w)===60?(C=Ki,w++):(C=r,we===0&&ve(Qi))))))),C}function uE(){var C,Q,k;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();return Q!==r?(k=$M(),k!==r?(Re=C,Q=Ae(k),C=Q):(w=C,C=r)):(w=C,C=r),C}function $M(){var C,Q,k;if(C=w,Q=[],k=eO(),k!==r)for(;k!==r;)Q.push(k),k=eO();else Q=r;return Q!==r&&(Re=C,Q=Go(Q)),C=Q,C}function eO(){var C,Q;return C=w,Q=kfe(),Q!==r&&(Re=C,Q=wr(Q)),C=Q,C===r&&(C=w,Q=Pfe(),Q!==r&&(Re=C,Q=wr(Q)),C=Q,C===r&&(C=w,Q=Dfe(),Q!==r&&(Re=C,Q=wr(Q)),C=Q)),C}function kfe(){var C,Q,k,N;return C=w,t.charCodeAt(w)===39?(Q=Ui,w++):(Q=r,we===0&&ve(ws)),Q!==r?(k=Rfe(),k!==r?(t.charCodeAt(w)===39?(N=Ui,w++):(N=r,we===0&&ve(ws)),N!==r?(Re=C,Q=Tf(k),C=Q):(w=C,C=r)):(w=C,C=r)):(w=C,C=r),C}function Pfe(){var C,Q,k,N;if(C=w,t.charCodeAt(w)===34?(Q=Mf,w++):(Q=r,we===0&&ve(Rm)),Q!==r){for(k=[],N=tO();N!==r;)k.push(N),N=tO();k!==r?(t.charCodeAt(w)===34?(N=Mf,w++):(N=r,we===0&&ve(Rm)),N!==r?(Re=C,Q=Fm(k),C=Q):(w=C,C=r)):(w=C,C=r)}else w=C,C=r;return C}function Dfe(){var C,Q,k;if(C=w,Q=[],k=rO(),k!==r)for(;k!==r;)Q.push(k),k=rO();else Q=r;return Q!==r&&(Re=C,Q=Fm(Q)),C=Q,C}function tO(){var C,Q;return C=w,Q=nO(),Q!==r&&(Re=C,Q=Nm(Q)),C=Q,C===r&&(C=w,Q=sO(),Q!==r&&(Re=C,Q=DQ(Q)),C=Q,C===r&&(C=w,Q=ZQ(),Q!==r&&(Re=C,Q=RQ(Q)),C=Q,C===r&&(C=w,Q=Ffe(),Q!==r&&(Re=C,Q=Of(Q)),C=Q))),C}function rO(){var C,Q;return C=w,Q=nO(),Q!==r&&(Re=C,Q=FQ(Q)),C=Q,C===r&&(C=w,Q=sO(),Q!==r&&(Re=C,Q=NQ(Q)),C=Q,C===r&&(C=w,Q=ZQ(),Q!==r&&(Re=C,Q=Lm(Q)),C=Q,C===r&&(C=w,Q=Lfe(),Q!==r&&(Re=C,Q=LQ(Q)),C=Q,C===r&&(C=w,Q=Nfe(),Q!==r&&(Re=C,Q=Of(Q)),C=Q)))),C}function Rfe(){var C,Q,k,N,Z;for(C=w,Q=[],k=gE(),k===r&&(k=fE(),k===r&&(k=w,t.charCodeAt(w)===92?(N=Va,w++):(N=r,we===0&&ve(jo)),N!==r?(Tm.test(t.charAt(w))?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Mm)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r),k===r&&(Om.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(Km)))));k!==r;)Q.push(k),k=gE(),k===r&&(k=fE(),k===r&&(k=w,t.charCodeAt(w)===92?(N=Va,w++):(N=r,we===0&&ve(jo)),N!==r?(Tm.test(t.charAt(w))?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Mm)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r),k===r&&(Om.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(Km)))));return Q!==r&&(Re=C,Q=il(Q)),C=Q,C}function Ffe(){var C,Q,k,N,Z;if(C=w,Q=[],k=gE(),k===r&&(k=fE(),k===r&&(k=w,t.charCodeAt(w)===92?(N=Va,w++):(N=r,we===0&&ve(jo)),N!==r?(Um.test(t.charAt(w))?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Hm)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r),k===r&&(Kf.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(Gm))))),k!==r)for(;k!==r;)Q.push(k),k=gE(),k===r&&(k=fE(),k===r&&(k=w,t.charCodeAt(w)===92?(N=Va,w++):(N=r,we===0&&ve(jo)),N!==r?(Um.test(t.charAt(w))?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Hm)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r),k===r&&(Kf.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(Gm)))));else Q=r;return Q!==r&&(Re=C,Q=il(Q)),C=Q,C}function gE(){var C,Q;return C=w,t.substr(w,2)===jm?(Q=jm,w+=2):(Q=r,we===0&&ve(TQ)),Q!==r&&(Re=C,Q=MQ()),C=Q,C===r&&(C=w,t.substr(w,2)===Ym?(Q=Ym,w+=2):(Q=r,we===0&&ve(qm)),Q!==r&&(Re=C,Q=Jm()),C=Q,C===r&&(C=w,t.substr(w,2)===Wm?(Q=Wm,w+=2):(Q=r,we===0&&ve(zm)),Q!==r&&(Re=C,Q=Vm()),C=Q,C===r&&(C=w,t.substr(w,2)===Uf?(Q=Uf,w+=2):(Q=r,we===0&&ve(OQ)),Q!==r&&(Re=C,Q=KQ()),C=Q,C===r&&(C=w,t.substr(w,2)===_m?(Q=_m,w+=2):(Q=r,we===0&&ve(UQ)),Q!==r&&(Re=C,Q=HQ()),C=Q,C===r&&(C=w,t.substr(w,2)===O?(Q=O,w+=2):(Q=r,we===0&&ve(ht)),Q!==r&&(Re=C,Q=Vc()),C=Q,C===r&&(C=w,t.substr(w,2)===xn?(Q=xn,w+=2):(Q=r,we===0&&ve(Hf)),Q!==r&&(Re=C,Q=Ye()),C=Q,C===r&&(C=w,t.substr(w,2)===nl?(Q=nl,w+=2):(Q=r,we===0&&ve(Xm)),Q!==r&&(Re=C,Q=MM()),C=Q,C===r&&(C=w,t.substr(w,2)===GQ?(Q=GQ,w+=2):(Q=r,we===0&&ve(OM)),Q!==r&&(Re=C,Q=fr()),C=Q)))))))),C}function fE(){var C,Q,k,N,Z,Ee,ot,ut,Tr,ni,Yn,$Q;return C=w,t.substr(w,2)===Bs?(Q=Bs,w+=2):(Q=r,we===0&&ve(jQ)),Q!==r?(k=w,N=w,Z=An(),Z!==r?(Ee=An(),Ee!==r?(Z=[Z,Ee],N=Z):(w=N,N=r)):(w=N,N=r),N!==r?k=t.substring(k,w):k=N,k!==r?(Re=C,Q=Zm(k),C=Q):(w=C,C=r)):(w=C,C=r),C===r&&(C=w,t.substr(w,2)===Yo?(Q=Yo,w+=2):(Q=r,we===0&&ve($m)),Q!==r?(k=w,N=w,Z=An(),Z!==r?(Ee=An(),Ee!==r?(ot=An(),ot!==r?(ut=An(),ut!==r?(Z=[Z,Ee,ot,ut],N=Z):(w=N,N=r)):(w=N,N=r)):(w=N,N=r)):(w=N,N=r),N!==r?k=t.substring(k,w):k=N,k!==r?(Re=C,Q=Zm(k),C=Q):(w=C,C=r)):(w=C,C=r),C===r&&(C=w,t.substr(w,2)===_a?(Q=_a,w+=2):(Q=r,we===0&&ve(et)),Q!==r?(k=w,N=w,Z=An(),Z!==r?(Ee=An(),Ee!==r?(ot=An(),ot!==r?(ut=An(),ut!==r?(Tr=An(),Tr!==r?(ni=An(),ni!==r?(Yn=An(),Yn!==r?($Q=An(),$Q!==r?(Z=[Z,Ee,ot,ut,Tr,ni,Yn,$Q],N=Z):(w=N,N=r)):(w=N,N=r)):(w=N,N=r)):(w=N,N=r)):(w=N,N=r)):(w=N,N=r)):(w=N,N=r)):(w=N,N=r),N!==r?k=t.substring(k,w):k=N,k!==r?(Re=C,Q=YQ(k),C=Q):(w=C,C=r)):(w=C,C=r))),C}function An(){var C;return eE.test(t.charAt(w))?(C=t.charAt(w),w++):(C=r,we===0&&ve(tE)),C}function Nfe(){var C,Q,k,N,Z;if(C=w,Q=[],k=w,t.charCodeAt(w)===92?(N=Va,w++):(N=r,we===0&&ve(jo)),N!==r?(t.length>w?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Xa)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r),k===r&&(k=w,N=w,we++,Z=aO(),we--,Z===r?N=void 0:(w=N,N=r),N!==r?(t.length>w?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Xa)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r)),k!==r)for(;k!==r;)Q.push(k),k=w,t.charCodeAt(w)===92?(N=Va,w++):(N=r,we===0&&ve(jo)),N!==r?(t.length>w?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Xa)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r),k===r&&(k=w,N=w,we++,Z=aO(),we--,Z===r?N=void 0:(w=N,N=r),N!==r?(t.length>w?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Xa)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r));else Q=r;return Q!==r&&(Re=C,Q=il(Q)),C=Q,C}function _Q(){var C,Q,k,N,Z,Ee;if(C=w,t.charCodeAt(w)===45?(Q=sl,w++):(Q=r,we===0&&ve(ol)),Q===r&&(t.charCodeAt(w)===43?(Q=al,w++):(Q=r,we===0&&ve(qo))),Q===r&&(Q=null),Q!==r){if(k=[],De.test(t.charAt(w))?(N=t.charAt(w),w++):(N=r,we===0&&ve($)),N!==r)for(;N!==r;)k.push(N),De.test(t.charAt(w))?(N=t.charAt(w),w++):(N=r,we===0&&ve($));else k=r;if(k!==r)if(t.charCodeAt(w)===46?(N=Al,w++):(N=r,we===0&&ve(qQ)),N!==r){if(Z=[],De.test(t.charAt(w))?(Ee=t.charAt(w),w++):(Ee=r,we===0&&ve($)),Ee!==r)for(;Ee!==r;)Z.push(Ee),De.test(t.charAt(w))?(Ee=t.charAt(w),w++):(Ee=r,we===0&&ve($));else Z=r;Z!==r?(Re=C,Q=rE(Q,k,Z),C=Q):(w=C,C=r)}else w=C,C=r;else w=C,C=r}else w=C,C=r;if(C===r){if(C=w,t.charCodeAt(w)===45?(Q=sl,w++):(Q=r,we===0&&ve(ol)),Q===r&&(t.charCodeAt(w)===43?(Q=al,w++):(Q=r,we===0&&ve(qo))),Q===r&&(Q=null),Q!==r){if(k=[],De.test(t.charAt(w))?(N=t.charAt(w),w++):(N=r,we===0&&ve($)),N!==r)for(;N!==r;)k.push(N),De.test(t.charAt(w))?(N=t.charAt(w),w++):(N=r,we===0&&ve($));else k=r;k!==r?(Re=C,Q=iE(Q,k),C=Q):(w=C,C=r)}else w=C,C=r;if(C===r&&(C=w,Q=ZQ(),Q!==r&&(Re=C,Q=JQ(Q)),C=Q,C===r&&(C=w,Q=zf(),Q!==r&&(Re=C,Q=ll(Q)),C=Q,C===r)))if(C=w,t.charCodeAt(w)===40?(Q=W,w++):(Q=r,we===0&&ve(X)),Q!==r){for(k=[],N=ke();N!==r;)k.push(N),N=ke();if(k!==r)if(N=iO(),N!==r){for(Z=[],Ee=ke();Ee!==r;)Z.push(Ee),Ee=ke();Z!==r?(t.charCodeAt(w)===41?(Ee=F,w++):(Ee=r,we===0&&ve(D)),Ee!==r?(Re=C,Q=WQ(N),C=Q):(w=C,C=r)):(w=C,C=r)}else w=C,C=r;else w=C,C=r}else w=C,C=r}return C}function XQ(){var C,Q,k,N,Z,Ee,ot,ut;if(C=w,Q=_Q(),Q!==r){for(k=[],N=w,Z=[],Ee=ke();Ee!==r;)Z.push(Ee),Ee=ke();if(Z!==r)if(t.charCodeAt(w)===42?(Ee=nE,w++):(Ee=r,we===0&&ve(Gf)),Ee===r&&(t.charCodeAt(w)===47?(Ee=_c,w++):(Ee=r,we===0&&ve(jf))),Ee!==r){for(ot=[],ut=ke();ut!==r;)ot.push(ut),ut=ke();ot!==r?(ut=_Q(),ut!==r?(Re=N,Z=sE(Q,Ee,ut),N=Z):(w=N,N=r)):(w=N,N=r)}else w=N,N=r;else w=N,N=r;for(;N!==r;){for(k.push(N),N=w,Z=[],Ee=ke();Ee!==r;)Z.push(Ee),Ee=ke();if(Z!==r)if(t.charCodeAt(w)===42?(Ee=nE,w++):(Ee=r,we===0&&ve(Gf)),Ee===r&&(t.charCodeAt(w)===47?(Ee=_c,w++):(Ee=r,we===0&&ve(jf))),Ee!==r){for(ot=[],ut=ke();ut!==r;)ot.push(ut),ut=ke();ot!==r?(ut=_Q(),ut!==r?(Re=N,Z=sE(Q,Ee,ut),N=Z):(w=N,N=r)):(w=N,N=r)}else w=N,N=r;else w=N,N=r}k!==r?(Re=C,Q=cl(Q,k),C=Q):(w=C,C=r)}else w=C,C=r;return C}function iO(){var C,Q,k,N,Z,Ee,ot,ut;if(C=w,Q=XQ(),Q!==r){for(k=[],N=w,Z=[],Ee=ke();Ee!==r;)Z.push(Ee),Ee=ke();if(Z!==r)if(t.charCodeAt(w)===43?(Ee=al,w++):(Ee=r,we===0&&ve(qo)),Ee===r&&(t.charCodeAt(w)===45?(Ee=sl,w++):(Ee=r,we===0&&ve(ol))),Ee!==r){for(ot=[],ut=ke();ut!==r;)ot.push(ut),ut=ke();ot!==r?(ut=XQ(),ut!==r?(Re=N,Z=oE(Q,Ee,ut),N=Z):(w=N,N=r)):(w=N,N=r)}else w=N,N=r;else w=N,N=r;for(;N!==r;){for(k.push(N),N=w,Z=[],Ee=ke();Ee!==r;)Z.push(Ee),Ee=ke();if(Z!==r)if(t.charCodeAt(w)===43?(Ee=al,w++):(Ee=r,we===0&&ve(qo)),Ee===r&&(t.charCodeAt(w)===45?(Ee=sl,w++):(Ee=r,we===0&&ve(ol))),Ee!==r){for(ot=[],ut=ke();ut!==r;)ot.push(ut),ut=ke();ot!==r?(ut=XQ(),ut!==r?(Re=N,Z=oE(Q,Ee,ut),N=Z):(w=N,N=r)):(w=N,N=r)}else w=N,N=r;else w=N,N=r}k!==r?(Re=C,Q=cl(Q,k),C=Q):(w=C,C=r)}else w=C,C=r;return C}function nO(){var C,Q,k,N,Z,Ee;if(C=w,t.substr(w,3)===Yf?(Q=Yf,w+=3):(Q=r,we===0&&ve(Xc)),Q!==r){for(k=[],N=ke();N!==r;)k.push(N),N=ke();if(k!==r)if(N=iO(),N!==r){for(Z=[],Ee=ke();Ee!==r;)Z.push(Ee),Ee=ke();Z!==r?(t.substr(w,2)===xr?(Ee=xr,w+=2):(Ee=r,we===0&&ve(KM)),Ee!==r?(Re=C,Q=Jo(N),C=Q):(w=C,C=r)):(w=C,C=r)}else w=C,C=r;else w=C,C=r}else w=C,C=r;return C}function sO(){var C,Q,k,N;return C=w,t.substr(w,2)===Zs?(Q=Zs,w+=2):(Q=r,we===0&&ve(aE)),Q!==r?(k=Jf(),k!==r?(t.charCodeAt(w)===41?(N=F,w++):(N=r,we===0&&ve(D)),N!==r?(Re=C,Q=Zc(k),C=Q):(w=C,C=r)):(w=C,C=r)):(w=C,C=r),C}function ZQ(){var C,Q,k,N,Z,Ee;return C=w,t.substr(w,2)===x?(Q=x,w+=2):(Q=r,we===0&&ve(U)),Q!==r?(k=zf(),k!==r?(t.substr(w,2)===le?(N=le,w+=2):(N=r,we===0&&ve(xe)),N!==r?(Z=Sfe(),Z!==r?(t.charCodeAt(w)===125?(Ee=Pe,w++):(Ee=r,we===0&&ve(qe)),Ee!==r?(Re=C,Q=Qe(k,Z),C=Q):(w=C,C=r)):(w=C,C=r)):(w=C,C=r)):(w=C,C=r)):(w=C,C=r),C===r&&(C=w,t.substr(w,2)===x?(Q=x,w+=2):(Q=r,we===0&&ve(U)),Q!==r?(k=zf(),k!==r?(t.substr(w,3)===Ge?(N=Ge,w+=3):(N=r,we===0&&ve(ct)),N!==r?(Re=C,Q=sr(k),C=Q):(w=C,C=r)):(w=C,C=r)):(w=C,C=r),C===r&&(C=w,t.substr(w,2)===x?(Q=x,w+=2):(Q=r,we===0&&ve(U)),Q!==r?(k=zf(),k!==r?(t.charCodeAt(w)===125?(N=Pe,w++):(N=r,we===0&&ve(qe)),N!==r?(Re=C,Q=Wo(k),C=Q):(w=C,C=r)):(w=C,C=r)):(w=C,C=r),C===r&&(C=w,t.charCodeAt(w)===36?(Q=Afe,w++):(Q=r,we===0&&ve(lfe)),Q!==r?(k=zf(),k!==r?(Re=C,Q=Wo(k),C=Q):(w=C,C=r)):(w=C,C=r)))),C}function Lfe(){var C,Q,k;return C=w,Q=Tfe(),Q!==r?(Re=w,k=cfe(Q),k?k=void 0:k=r,k!==r?(Re=C,Q=ufe(Q),C=Q):(w=C,C=r)):(w=C,C=r),C}function Tfe(){var C,Q,k,N,Z;if(C=w,Q=[],k=w,N=w,we++,Z=AO(),we--,Z===r?N=void 0:(w=N,N=r),N!==r?(t.length>w?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Xa)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r),k!==r)for(;k!==r;)Q.push(k),k=w,N=w,we++,Z=AO(),we--,Z===r?N=void 0:(w=N,N=r),N!==r?(t.length>w?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Xa)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r);else Q=r;return Q!==r&&(Re=C,Q=il(Q)),C=Q,C}function oO(){var C,Q,k;if(C=w,Q=[],UM.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(HM)),k!==r)for(;k!==r;)Q.push(k),UM.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(HM));else Q=r;return Q!==r&&(Re=C,Q=GM()),C=Q,C}function zf(){var C,Q,k;if(C=w,Q=[],jM.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(YM)),k!==r)for(;k!==r;)Q.push(k),jM.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(YM));else Q=r;return Q!==r&&(Re=C,Q=GM()),C=Q,C}function aO(){var C;return gfe.test(t.charAt(w))?(C=t.charAt(w),w++):(C=r,we===0&&ve(ffe)),C}function AO(){var C;return hfe.test(t.charAt(w))?(C=t.charAt(w),w++):(C=r,we===0&&ve(pfe)),C}function ke(){var C,Q;if(C=[],qM.test(t.charAt(w))?(Q=t.charAt(w),w++):(Q=r,we===0&&ve(JM)),Q!==r)for(;Q!==r;)C.push(Q),qM.test(t.charAt(w))?(Q=t.charAt(w),w++):(Q=r,we===0&&ve(JM));else C=r;return C}if(lE=n(),lE!==r&&w===t.length)return lE;throw lE!==r&&w{"use strict";function Eke(t,e){function r(){this.constructor=t}r.prototype=e.prototype,t.prototype=new r}function Xl(t,e,r,i){this.message=t,this.expected=e,this.found=r,this.location=i,this.name="SyntaxError",typeof Error.captureStackTrace=="function"&&Error.captureStackTrace(this,Xl)}Eke(Xl,Error);Xl.buildMessage=function(t,e){var r={literal:function(c){return'"'+n(c.text)+'"'},class:function(c){var u="",g;for(g=0;g0){for(g=1,f=1;gH&&(H=B,L=[]),L.push($))}function qe($,G){return new Xl($,null,null,G)}function re($,G,Ce){return new Xl(Xl.buildMessage($,G),$,G,Ce)}function se(){var $,G,Ce,ee;return $=B,G=be(),G!==r?(t.charCodeAt(B)===47?(Ce=s,B++):(Ce=r,K===0&&Pe(o)),Ce!==r?(ee=be(),ee!==r?(b=$,G=a(G,ee),$=G):(B=$,$=r)):(B=$,$=r)):(B=$,$=r),$===r&&($=B,G=be(),G!==r&&(b=$,G=l(G)),$=G),$}function be(){var $,G,Ce,ee;return $=B,G=ae(),G!==r?(t.charCodeAt(B)===64?(Ce=c,B++):(Ce=r,K===0&&Pe(u)),Ce!==r?(ee=De(),ee!==r?(b=$,G=g(G,ee),$=G):(B=$,$=r)):(B=$,$=r)):(B=$,$=r),$===r&&($=B,G=ae(),G!==r&&(b=$,G=f(G)),$=G),$}function ae(){var $,G,Ce,ee,Ue;return $=B,t.charCodeAt(B)===64?(G=c,B++):(G=r,K===0&&Pe(u)),G!==r?(Ce=Ae(),Ce!==r?(t.charCodeAt(B)===47?(ee=s,B++):(ee=r,K===0&&Pe(o)),ee!==r?(Ue=Ae(),Ue!==r?(b=$,G=h(),$=G):(B=$,$=r)):(B=$,$=r)):(B=$,$=r)):(B=$,$=r),$===r&&($=B,G=Ae(),G!==r&&(b=$,G=h()),$=G),$}function Ae(){var $,G,Ce;if($=B,G=[],p.test(t.charAt(B))?(Ce=t.charAt(B),B++):(Ce=r,K===0&&Pe(d)),Ce!==r)for(;Ce!==r;)G.push(Ce),p.test(t.charAt(B))?(Ce=t.charAt(B),B++):(Ce=r,K===0&&Pe(d));else G=r;return G!==r&&(b=$,G=h()),$=G,$}function De(){var $,G,Ce;if($=B,G=[],m.test(t.charAt(B))?(Ce=t.charAt(B),B++):(Ce=r,K===0&&Pe(I)),Ce!==r)for(;Ce!==r;)G.push(Ce),m.test(t.charAt(B))?(Ce=t.charAt(B),B++):(Ce=r,K===0&&Pe(I));else G=r;return G!==r&&(b=$,G=h()),$=G,$}if(J=n(),J!==r&&B===t.length)return J;throw J!==r&&B{"use strict";function F4(t){return typeof t=="undefined"||t===null}function yke(t){return typeof t=="object"&&t!==null}function wke(t){return Array.isArray(t)?t:F4(t)?[]:[t]}function Bke(t,e){var r,i,n,s;if(e)for(s=Object.keys(e),r=0,i=s.length;r{"use strict";function Lp(t,e){Error.call(this),this.name="YAMLException",this.reason=t,this.mark=e,this.message=(this.reason||"(unknown reason)")+(this.mark?" "+this.mark.toString():""),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}Lp.prototype=Object.create(Error.prototype);Lp.prototype.constructor=Lp;Lp.prototype.toString=function(e){var r=this.name+": ";return r+=this.reason||"(unknown reason)",!e&&this.mark&&(r+=" "+this.mark.toString()),r};N4.exports=Lp});var M4=E((Vot,L4)=>{"use strict";var T4=$l();function kP(t,e,r,i,n){this.name=t,this.buffer=e,this.position=r,this.line=i,this.column=n}kP.prototype.getSnippet=function(e,r){var i,n,s,o,a;if(!this.buffer)return null;for(e=e||4,r=r||75,i="",n=this.position;n>0&&`\0\r +\x85\u2028\u2029`.indexOf(this.buffer.charAt(n-1))===-1;)if(n-=1,this.position-n>r/2-1){i=" ... ",n+=5;break}for(s="",o=this.position;or/2-1){s=" ... ",o-=5;break}return a=this.buffer.slice(n,o),T4.repeat(" ",e)+i+a+s+` +`+T4.repeat(" ",e+this.position-n+i.length)+"^"};kP.prototype.toString=function(e){var r,i="";return this.name&&(i+='in "'+this.name+'" '),i+="at line "+(this.line+1)+", column "+(this.column+1),e||(r=this.getSnippet(),r&&(i+=`: +`+r)),i};L4.exports=kP});var Xr=E((_ot,O4)=>{"use strict";var K4=ng(),vke=["kind","resolve","construct","instanceOf","predicate","represent","defaultStyle","styleAliases"],Ske=["scalar","sequence","mapping"];function xke(t){var e={};return t!==null&&Object.keys(t).forEach(function(r){t[r].forEach(function(i){e[String(i)]=r})}),e}function kke(t,e){if(e=e||{},Object.keys(e).forEach(function(r){if(vke.indexOf(r)===-1)throw new K4('Unknown option "'+r+'" is met in definition of "'+t+'" YAML type.')}),this.tag=t,this.kind=e.kind||null,this.resolve=e.resolve||function(){return!0},this.construct=e.construct||function(r){return r},this.instanceOf=e.instanceOf||null,this.predicate=e.predicate||null,this.represent=e.represent||null,this.defaultStyle=e.defaultStyle||null,this.styleAliases=xke(e.styleAliases||null),Ske.indexOf(this.kind)===-1)throw new K4('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}O4.exports=kke});var ec=E((Xot,U4)=>{"use strict";var H4=$l(),hw=ng(),Pke=Xr();function PP(t,e,r){var i=[];return t.include.forEach(function(n){r=PP(n,e,r)}),t[e].forEach(function(n){r.forEach(function(s,o){s.tag===n.tag&&s.kind===n.kind&&i.push(o)}),r.push(n)}),r.filter(function(n,s){return i.indexOf(s)===-1})}function Dke(){var t={scalar:{},sequence:{},mapping:{},fallback:{}},e,r;function i(n){t[n.kind][n.tag]=t.fallback[n.tag]=n}for(e=0,r=arguments.length;e{"use strict";var Rke=Xr();G4.exports=new Rke("tag:yaml.org,2002:str",{kind:"scalar",construct:function(t){return t!==null?t:""}})});var q4=E(($ot,Y4)=>{"use strict";var Fke=Xr();Y4.exports=new Fke("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(t){return t!==null?t:[]}})});var W4=E((eat,J4)=>{"use strict";var Nke=Xr();J4.exports=new Nke("tag:yaml.org,2002:map",{kind:"mapping",construct:function(t){return t!==null?t:{}}})});var pw=E((tat,z4)=>{"use strict";var Lke=ec();z4.exports=new Lke({explicit:[j4(),q4(),W4()]})});var _4=E((rat,V4)=>{"use strict";var Tke=Xr();function Mke(t){if(t===null)return!0;var e=t.length;return e===1&&t==="~"||e===4&&(t==="null"||t==="Null"||t==="NULL")}function Oke(){return null}function Kke(t){return t===null}V4.exports=new Tke("tag:yaml.org,2002:null",{kind:"scalar",resolve:Mke,construct:Oke,predicate:Kke,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"}},defaultStyle:"lowercase"})});var Z4=E((iat,X4)=>{"use strict";var Uke=Xr();function Hke(t){if(t===null)return!1;var e=t.length;return e===4&&(t==="true"||t==="True"||t==="TRUE")||e===5&&(t==="false"||t==="False"||t==="FALSE")}function Gke(t){return t==="true"||t==="True"||t==="TRUE"}function jke(t){return Object.prototype.toString.call(t)==="[object Boolean]"}X4.exports=new Uke("tag:yaml.org,2002:bool",{kind:"scalar",resolve:Hke,construct:Gke,predicate:jke,represent:{lowercase:function(t){return t?"true":"false"},uppercase:function(t){return t?"TRUE":"FALSE"},camelcase:function(t){return t?"True":"False"}},defaultStyle:"lowercase"})});var ez=E((nat,$4)=>{"use strict";var Yke=$l(),qke=Xr();function Jke(t){return 48<=t&&t<=57||65<=t&&t<=70||97<=t&&t<=102}function Wke(t){return 48<=t&&t<=55}function zke(t){return 48<=t&&t<=57}function Vke(t){if(t===null)return!1;var e=t.length,r=0,i=!1,n;if(!e)return!1;if(n=t[r],(n==="-"||n==="+")&&(n=t[++r]),n==="0"){if(r+1===e)return!0;if(n=t[++r],n==="b"){for(r++;r=0?"0b"+t.toString(2):"-0b"+t.toString(2).slice(1)},octal:function(t){return t>=0?"0"+t.toString(8):"-0"+t.toString(8).slice(1)},decimal:function(t){return t.toString(10)},hexadecimal:function(t){return t>=0?"0x"+t.toString(16).toUpperCase():"-0x"+t.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}})});var iz=E((sat,tz)=>{"use strict";var rz=$l(),Zke=Xr(),$ke=new RegExp("^(?:[-+]?(?:0|[1-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\\.[0-9_]*|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function ePe(t){return!(t===null||!$ke.test(t)||t[t.length-1]==="_")}function tPe(t){var e,r,i,n;return e=t.replace(/_/g,"").toLowerCase(),r=e[0]==="-"?-1:1,n=[],"+-".indexOf(e[0])>=0&&(e=e.slice(1)),e===".inf"?r===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:e===".nan"?NaN:e.indexOf(":")>=0?(e.split(":").forEach(function(s){n.unshift(parseFloat(s,10))}),e=0,i=1,n.forEach(function(s){e+=s*i,i*=60}),r*e):r*parseFloat(e,10)}var rPe=/^[-+]?[0-9]+e/;function iPe(t,e){var r;if(isNaN(t))switch(e){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===t)switch(e){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===t)switch(e){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(rz.isNegativeZero(t))return"-0.0";return r=t.toString(10),rPe.test(r)?r.replace("e",".e"):r}function nPe(t){return Object.prototype.toString.call(t)==="[object Number]"&&(t%1!=0||rz.isNegativeZero(t))}tz.exports=new Zke("tag:yaml.org,2002:float",{kind:"scalar",resolve:ePe,construct:tPe,predicate:nPe,represent:iPe,defaultStyle:"lowercase"})});var DP=E((oat,nz)=>{"use strict";var sPe=ec();nz.exports=new sPe({include:[pw()],implicit:[_4(),Z4(),ez(),iz()]})});var RP=E((aat,sz)=>{"use strict";var oPe=ec();sz.exports=new oPe({include:[DP()]})});var lz=E((Aat,oz)=>{"use strict";var aPe=Xr(),az=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),Az=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function APe(t){return t===null?!1:az.exec(t)!==null||Az.exec(t)!==null}function lPe(t){var e,r,i,n,s,o,a,l=0,c=null,u,g,f;if(e=az.exec(t),e===null&&(e=Az.exec(t)),e===null)throw new Error("Date resolve error");if(r=+e[1],i=+e[2]-1,n=+e[3],!e[4])return new Date(Date.UTC(r,i,n));if(s=+e[4],o=+e[5],a=+e[6],e[7]){for(l=e[7].slice(0,3);l.length<3;)l+="0";l=+l}return e[9]&&(u=+e[10],g=+(e[11]||0),c=(u*60+g)*6e4,e[9]==="-"&&(c=-c)),f=new Date(Date.UTC(r,i,n,s,o,a,l)),c&&f.setTime(f.getTime()-c),f}function cPe(t){return t.toISOString()}oz.exports=new aPe("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:APe,construct:lPe,instanceOf:Date,represent:cPe})});var uz=E((lat,cz)=>{"use strict";var uPe=Xr();function gPe(t){return t==="<<"||t===null}cz.exports=new uPe("tag:yaml.org,2002:merge",{kind:"scalar",resolve:gPe})});var hz=E((cat,gz)=>{"use strict";var tc;try{fz=require,tc=fz("buffer").Buffer}catch(t){}var fz,fPe=Xr(),FP=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/= +\r`;function hPe(t){if(t===null)return!1;var e,r,i=0,n=t.length,s=FP;for(r=0;r64)){if(e<0)return!1;i+=6}return i%8==0}function pPe(t){var e,r,i=t.replace(/[\r\n=]/g,""),n=i.length,s=FP,o=0,a=[];for(e=0;e>16&255),a.push(o>>8&255),a.push(o&255)),o=o<<6|s.indexOf(i.charAt(e));return r=n%4*6,r===0?(a.push(o>>16&255),a.push(o>>8&255),a.push(o&255)):r===18?(a.push(o>>10&255),a.push(o>>2&255)):r===12&&a.push(o>>4&255),tc?tc.from?tc.from(a):new tc(a):a}function dPe(t){var e="",r=0,i,n,s=t.length,o=FP;for(i=0;i>18&63],e+=o[r>>12&63],e+=o[r>>6&63],e+=o[r&63]),r=(r<<8)+t[i];return n=s%3,n===0?(e+=o[r>>18&63],e+=o[r>>12&63],e+=o[r>>6&63],e+=o[r&63]):n===2?(e+=o[r>>10&63],e+=o[r>>4&63],e+=o[r<<2&63],e+=o[64]):n===1&&(e+=o[r>>2&63],e+=o[r<<4&63],e+=o[64],e+=o[64]),e}function CPe(t){return tc&&tc.isBuffer(t)}gz.exports=new fPe("tag:yaml.org,2002:binary",{kind:"scalar",resolve:hPe,construct:pPe,predicate:CPe,represent:dPe})});var dz=E((uat,pz)=>{"use strict";var mPe=Xr(),EPe=Object.prototype.hasOwnProperty,IPe=Object.prototype.toString;function yPe(t){if(t===null)return!0;var e=[],r,i,n,s,o,a=t;for(r=0,i=a.length;r{"use strict";var BPe=Xr(),QPe=Object.prototype.toString;function bPe(t){if(t===null)return!0;var e,r,i,n,s,o=t;for(s=new Array(o.length),e=0,r=o.length;e{"use strict";var SPe=Xr(),xPe=Object.prototype.hasOwnProperty;function kPe(t){if(t===null)return!0;var e,r=t;for(e in r)if(xPe.call(r,e)&&r[e]!==null)return!1;return!0}function PPe(t){return t!==null?t:{}}Ez.exports=new SPe("tag:yaml.org,2002:set",{kind:"mapping",resolve:kPe,construct:PPe})});var og=E((hat,yz)=>{"use strict";var DPe=ec();yz.exports=new DPe({include:[RP()],implicit:[lz(),uz()],explicit:[hz(),dz(),mz(),Iz()]})});var Bz=E((pat,wz)=>{"use strict";var RPe=Xr();function FPe(){return!0}function NPe(){}function LPe(){return""}function TPe(t){return typeof t=="undefined"}wz.exports=new RPe("tag:yaml.org,2002:js/undefined",{kind:"scalar",resolve:FPe,construct:NPe,predicate:TPe,represent:LPe})});var bz=E((dat,Qz)=>{"use strict";var MPe=Xr();function OPe(t){if(t===null||t.length===0)return!1;var e=t,r=/\/([gim]*)$/.exec(t),i="";return!(e[0]==="/"&&(r&&(i=r[1]),i.length>3||e[e.length-i.length-1]!=="/"))}function KPe(t){var e=t,r=/\/([gim]*)$/.exec(t),i="";return e[0]==="/"&&(r&&(i=r[1]),e=e.slice(1,e.length-i.length-1)),new RegExp(e,i)}function UPe(t){var e="/"+t.source+"/";return t.global&&(e+="g"),t.multiline&&(e+="m"),t.ignoreCase&&(e+="i"),e}function HPe(t){return Object.prototype.toString.call(t)==="[object RegExp]"}Qz.exports=new MPe("tag:yaml.org,2002:js/regexp",{kind:"scalar",resolve:OPe,construct:KPe,predicate:HPe,represent:UPe})});var xz=E((Cat,vz)=>{"use strict";var dw;try{Sz=require,dw=Sz("esprima")}catch(t){typeof window!="undefined"&&(dw=window.esprima)}var Sz,GPe=Xr();function jPe(t){if(t===null)return!1;try{var e="("+t+")",r=dw.parse(e,{range:!0});return!(r.type!=="Program"||r.body.length!==1||r.body[0].type!=="ExpressionStatement"||r.body[0].expression.type!=="ArrowFunctionExpression"&&r.body[0].expression.type!=="FunctionExpression")}catch(i){return!1}}function YPe(t){var e="("+t+")",r=dw.parse(e,{range:!0}),i=[],n;if(r.type!=="Program"||r.body.length!==1||r.body[0].type!=="ExpressionStatement"||r.body[0].expression.type!=="ArrowFunctionExpression"&&r.body[0].expression.type!=="FunctionExpression")throw new Error("Failed to resolve function");return r.body[0].expression.params.forEach(function(s){i.push(s.name)}),n=r.body[0].expression.body.range,r.body[0].expression.body.type==="BlockStatement"?new Function(i,e.slice(n[0]+1,n[1]-1)):new Function(i,"return "+e.slice(n[0],n[1]))}function qPe(t){return t.toString()}function JPe(t){return Object.prototype.toString.call(t)==="[object Function]"}vz.exports=new GPe("tag:yaml.org,2002:js/function",{kind:"scalar",resolve:jPe,construct:YPe,predicate:JPe,represent:qPe})});var Tp=E((mat,kz)=>{"use strict";var Pz=ec();kz.exports=Pz.DEFAULT=new Pz({include:[og()],explicit:[Bz(),bz(),xz()]})});var Vz=E((Eat,Mp)=>{"use strict";var Ba=$l(),Dz=ng(),WPe=M4(),Rz=og(),zPe=Tp(),QA=Object.prototype.hasOwnProperty,Cw=1,Fz=2,Nz=3,mw=4,NP=1,VPe=2,Lz=3,_Pe=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,XPe=/[\x85\u2028\u2029]/,ZPe=/[,\[\]\{\}]/,Tz=/^(?:!|!!|![a-z\-]+!)$/i,Mz=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function Oz(t){return Object.prototype.toString.call(t)}function wo(t){return t===10||t===13}function rc(t){return t===9||t===32}function yn(t){return t===9||t===32||t===10||t===13}function ag(t){return t===44||t===91||t===93||t===123||t===125}function $Pe(t){var e;return 48<=t&&t<=57?t-48:(e=t|32,97<=e&&e<=102?e-97+10:-1)}function eDe(t){return t===120?2:t===117?4:t===85?8:0}function tDe(t){return 48<=t&&t<=57?t-48:-1}function Kz(t){return t===48?"\0":t===97?"\x07":t===98?"\b":t===116||t===9?" ":t===110?` +`:t===118?"\v":t===102?"\f":t===114?"\r":t===101?"":t===32?" ":t===34?'"':t===47?"/":t===92?"\\":t===78?"\x85":t===95?"\xA0":t===76?"\u2028":t===80?"\u2029":""}function rDe(t){return t<=65535?String.fromCharCode(t):String.fromCharCode((t-65536>>10)+55296,(t-65536&1023)+56320)}var Uz=new Array(256),Hz=new Array(256);for(var Ag=0;Ag<256;Ag++)Uz[Ag]=Kz(Ag)?1:0,Hz[Ag]=Kz(Ag);function iDe(t,e){this.input=t,this.filename=e.filename||null,this.schema=e.schema||zPe,this.onWarning=e.onWarning||null,this.legacy=e.legacy||!1,this.json=e.json||!1,this.listener=e.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=t.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.documents=[]}function Gz(t,e){return new Dz(e,new WPe(t.filename,t.input,t.position,t.line,t.position-t.lineStart))}function st(t,e){throw Gz(t,e)}function Ew(t,e){t.onWarning&&t.onWarning.call(null,Gz(t,e))}var jz={YAML:function(e,r,i){var n,s,o;e.version!==null&&st(e,"duplication of %YAML directive"),i.length!==1&&st(e,"YAML directive accepts exactly one argument"),n=/^([0-9]+)\.([0-9]+)$/.exec(i[0]),n===null&&st(e,"ill-formed argument of the YAML directive"),s=parseInt(n[1],10),o=parseInt(n[2],10),s!==1&&st(e,"unacceptable YAML version of the document"),e.version=i[0],e.checkLineBreaks=o<2,o!==1&&o!==2&&Ew(e,"unsupported YAML version of the document")},TAG:function(e,r,i){var n,s;i.length!==2&&st(e,"TAG directive accepts exactly two arguments"),n=i[0],s=i[1],Tz.test(n)||st(e,"ill-formed tag handle (first argument) of the TAG directive"),QA.call(e.tagMap,n)&&st(e,'there is a previously declared suffix for "'+n+'" tag handle'),Mz.test(s)||st(e,"ill-formed tag prefix (second argument) of the TAG directive"),e.tagMap[n]=s}};function bA(t,e,r,i){var n,s,o,a;if(e1&&(t.result+=Ba.repeat(` +`,e-1))}function nDe(t,e,r){var i,n,s,o,a,l,c,u,g=t.kind,f=t.result,h;if(h=t.input.charCodeAt(t.position),yn(h)||ag(h)||h===35||h===38||h===42||h===33||h===124||h===62||h===39||h===34||h===37||h===64||h===96||(h===63||h===45)&&(n=t.input.charCodeAt(t.position+1),yn(n)||r&&ag(n)))return!1;for(t.kind="scalar",t.result="",s=o=t.position,a=!1;h!==0;){if(h===58){if(n=t.input.charCodeAt(t.position+1),yn(n)||r&&ag(n))break}else if(h===35){if(i=t.input.charCodeAt(t.position-1),yn(i))break}else{if(t.position===t.lineStart&&Iw(t)||r&&ag(h))break;if(wo(h))if(l=t.line,c=t.lineStart,u=t.lineIndent,jr(t,!1,-1),t.lineIndent>=e){a=!0,h=t.input.charCodeAt(t.position);continue}else{t.position=o,t.line=l,t.lineStart=c,t.lineIndent=u;break}}a&&(bA(t,s,o,!1),TP(t,t.line-l),s=o=t.position,a=!1),rc(h)||(o=t.position+1),h=t.input.charCodeAt(++t.position)}return bA(t,s,o,!1),t.result?!0:(t.kind=g,t.result=f,!1)}function sDe(t,e){var r,i,n;if(r=t.input.charCodeAt(t.position),r!==39)return!1;for(t.kind="scalar",t.result="",t.position++,i=n=t.position;(r=t.input.charCodeAt(t.position))!==0;)if(r===39)if(bA(t,i,t.position,!0),r=t.input.charCodeAt(++t.position),r===39)i=t.position,t.position++,n=t.position;else return!0;else wo(r)?(bA(t,i,n,!0),TP(t,jr(t,!1,e)),i=n=t.position):t.position===t.lineStart&&Iw(t)?st(t,"unexpected end of the document within a single quoted scalar"):(t.position++,n=t.position);st(t,"unexpected end of the stream within a single quoted scalar")}function oDe(t,e){var r,i,n,s,o,a;if(a=t.input.charCodeAt(t.position),a!==34)return!1;for(t.kind="scalar",t.result="",t.position++,r=i=t.position;(a=t.input.charCodeAt(t.position))!==0;){if(a===34)return bA(t,r,t.position,!0),t.position++,!0;if(a===92){if(bA(t,r,t.position,!0),a=t.input.charCodeAt(++t.position),wo(a))jr(t,!1,e);else if(a<256&&Uz[a])t.result+=Hz[a],t.position++;else if((o=eDe(a))>0){for(n=o,s=0;n>0;n--)a=t.input.charCodeAt(++t.position),(o=$Pe(a))>=0?s=(s<<4)+o:st(t,"expected hexadecimal character");t.result+=rDe(s),t.position++}else st(t,"unknown escape sequence");r=i=t.position}else wo(a)?(bA(t,r,i,!0),TP(t,jr(t,!1,e)),r=i=t.position):t.position===t.lineStart&&Iw(t)?st(t,"unexpected end of the document within a double quoted scalar"):(t.position++,i=t.position)}st(t,"unexpected end of the stream within a double quoted scalar")}function aDe(t,e){var r=!0,i,n=t.tag,s,o=t.anchor,a,l,c,u,g,f={},h,p,d,m;if(m=t.input.charCodeAt(t.position),m===91)l=93,g=!1,s=[];else if(m===123)l=125,g=!0,s={};else return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=s),m=t.input.charCodeAt(++t.position);m!==0;){if(jr(t,!0,e),m=t.input.charCodeAt(t.position),m===l)return t.position++,t.tag=n,t.anchor=o,t.kind=g?"mapping":"sequence",t.result=s,!0;r||st(t,"missed comma between flow collection entries"),p=h=d=null,c=u=!1,m===63&&(a=t.input.charCodeAt(t.position+1),yn(a)&&(c=u=!0,t.position++,jr(t,!0,e))),i=t.line,cg(t,e,Cw,!1,!0),p=t.tag,h=t.result,jr(t,!0,e),m=t.input.charCodeAt(t.position),(u||t.line===i)&&m===58&&(c=!0,m=t.input.charCodeAt(++t.position),jr(t,!0,e),cg(t,e,Cw,!1,!0),d=t.result),g?lg(t,s,f,p,h,d):c?s.push(lg(t,null,f,p,h,d)):s.push(h),jr(t,!0,e),m=t.input.charCodeAt(t.position),m===44?(r=!0,m=t.input.charCodeAt(++t.position)):r=!1}st(t,"unexpected end of the stream within a flow collection")}function ADe(t,e){var r,i,n=NP,s=!1,o=!1,a=e,l=0,c=!1,u,g;if(g=t.input.charCodeAt(t.position),g===124)i=!1;else if(g===62)i=!0;else return!1;for(t.kind="scalar",t.result="";g!==0;)if(g=t.input.charCodeAt(++t.position),g===43||g===45)NP===n?n=g===43?Lz:VPe:st(t,"repeat of a chomping mode identifier");else if((u=tDe(g))>=0)u===0?st(t,"bad explicit indentation width of a block scalar; it cannot be less than one"):o?st(t,"repeat of an indentation width identifier"):(a=e+u-1,o=!0);else break;if(rc(g)){do g=t.input.charCodeAt(++t.position);while(rc(g));if(g===35)do g=t.input.charCodeAt(++t.position);while(!wo(g)&&g!==0)}for(;g!==0;){for(LP(t),t.lineIndent=0,g=t.input.charCodeAt(t.position);(!o||t.lineIndenta&&(a=t.lineIndent),wo(g)){l++;continue}if(t.lineIndente)&&l!==0)st(t,"bad indentation of a sequence entry");else if(t.lineIndente)&&(cg(t,e,mw,!0,n)&&(p?f=t.result:h=t.result),p||(lg(t,c,u,g,f,h,s,o),g=f=h=null),jr(t,!0,-1),m=t.input.charCodeAt(t.position)),t.lineIndent>e&&m!==0)st(t,"bad indentation of a mapping entry");else if(t.lineIndente?l=1:t.lineIndent===e?l=0:t.lineIndente?l=1:t.lineIndent===e?l=0:t.lineIndent tag; it should be "scalar", not "'+t.kind+'"'),g=0,f=t.implicitTypes.length;g tag; it should be "'+h.kind+'", not "'+t.kind+'"'),h.resolve(t.result)?(t.result=h.construct(t.result),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):st(t,"cannot resolve a node with !<"+t.tag+"> explicit tag")):st(t,"unknown tag !<"+t.tag+">");return t.listener!==null&&t.listener("close",t),t.tag!==null||t.anchor!==null||u}function fDe(t){var e=t.position,r,i,n,s=!1,o;for(t.version=null,t.checkLineBreaks=t.legacy,t.tagMap={},t.anchorMap={};(o=t.input.charCodeAt(t.position))!==0&&(jr(t,!0,-1),o=t.input.charCodeAt(t.position),!(t.lineIndent>0||o!==37));){for(s=!0,o=t.input.charCodeAt(++t.position),r=t.position;o!==0&&!yn(o);)o=t.input.charCodeAt(++t.position);for(i=t.input.slice(r,t.position),n=[],i.length<1&&st(t,"directive name must not be less than one character in length");o!==0;){for(;rc(o);)o=t.input.charCodeAt(++t.position);if(o===35){do o=t.input.charCodeAt(++t.position);while(o!==0&&!wo(o));break}if(wo(o))break;for(r=t.position;o!==0&&!yn(o);)o=t.input.charCodeAt(++t.position);n.push(t.input.slice(r,t.position))}o!==0&&LP(t),QA.call(jz,i)?jz[i](t,i,n):Ew(t,'unknown document directive "'+i+'"')}if(jr(t,!0,-1),t.lineIndent===0&&t.input.charCodeAt(t.position)===45&&t.input.charCodeAt(t.position+1)===45&&t.input.charCodeAt(t.position+2)===45?(t.position+=3,jr(t,!0,-1)):s&&st(t,"directives end mark is expected"),cg(t,t.lineIndent-1,mw,!1,!0),jr(t,!0,-1),t.checkLineBreaks&&XPe.test(t.input.slice(e,t.position))&&Ew(t,"non-ASCII line breaks are interpreted as content"),t.documents.push(t.result),t.position===t.lineStart&&Iw(t)){t.input.charCodeAt(t.position)===46&&(t.position+=3,jr(t,!0,-1));return}if(t.position{"use strict";var Op=$l(),Kp=ng(),dDe=Tp(),CDe=og(),_z=Object.prototype.toString,Xz=Object.prototype.hasOwnProperty,mDe=9,Up=10,EDe=13,IDe=32,yDe=33,wDe=34,Zz=35,BDe=37,QDe=38,bDe=39,vDe=42,$z=44,SDe=45,e5=58,xDe=61,kDe=62,PDe=63,DDe=64,t5=91,r5=93,RDe=96,i5=123,FDe=124,n5=125,Ri={};Ri[0]="\\0";Ri[7]="\\a";Ri[8]="\\b";Ri[9]="\\t";Ri[10]="\\n";Ri[11]="\\v";Ri[12]="\\f";Ri[13]="\\r";Ri[27]="\\e";Ri[34]='\\"';Ri[92]="\\\\";Ri[133]="\\N";Ri[160]="\\_";Ri[8232]="\\L";Ri[8233]="\\P";var NDe=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"];function LDe(t,e){var r,i,n,s,o,a,l;if(e===null)return{};for(r={},i=Object.keys(e),n=0,s=i.length;n0?t.charCodeAt(s-1):null,f=f&&a5(o,a)}else{for(s=0;si&&t[g+1]!==" ",g=s);else if(!ug(o))return yw;a=s>0?t.charCodeAt(s-1):null,f=f&&a5(o,a)}c=c||u&&s-g-1>i&&t[g+1]!==" "}return!l&&!c?f&&!n(t)?l5:c5:r>9&&A5(t)?yw:c?g5:u5}function jDe(t,e,r,i){t.dump=function(){if(e.length===0)return"''";if(!t.noCompatMode&&NDe.indexOf(e)!==-1)return"'"+e+"'";var n=t.indent*Math.max(1,r),s=t.lineWidth===-1?-1:Math.max(Math.min(t.lineWidth,40),t.lineWidth-n),o=i||t.flowLevel>-1&&r>=t.flowLevel;function a(l){return MDe(t,l)}switch(UDe(e,o,t.indent,s,a)){case l5:return e;case c5:return"'"+e.replace(/'/g,"''")+"'";case u5:return"|"+f5(e,t.indent)+h5(o5(e,n));case g5:return">"+f5(e,t.indent)+h5(o5(HDe(e,s),n));case yw:return'"'+GDe(e,s)+'"';default:throw new Kp("impossible error: invalid scalar style")}}()}function f5(t,e){var r=A5(t)?String(e):"",i=t[t.length-1]===` +`,n=i&&(t[t.length-2]===` +`||t===` +`),s=n?"+":i?"":"-";return r+s+` +`}function h5(t){return t[t.length-1]===` +`?t.slice(0,-1):t}function HDe(t,e){for(var r=/(\n+)([^\n]*)/g,i=function(){var c=t.indexOf(` +`);return c=c!==-1?c:t.length,r.lastIndex=c,p5(t.slice(0,c),e)}(),n=t[0]===` +`||t[0]===" ",s,o;o=r.exec(t);){var a=o[1],l=o[2];s=l[0]===" ",i+=a+(!n&&!s&&l!==""?` +`:"")+p5(l,e),n=s}return i}function p5(t,e){if(t===""||t[0]===" ")return t;for(var r=/ [^ ]/g,i,n=0,s,o=0,a=0,l="";i=r.exec(t);)a=i.index,a-n>e&&(s=o>n?o:a,l+=` +`+t.slice(n,s),n=s+1),o=a;return l+=` +`,t.length-n>e&&o>n?l+=t.slice(n,o)+` +`+t.slice(o+1):l+=t.slice(n),l.slice(1)}function GDe(t){for(var e="",r,i,n,s=0;s=55296&&r<=56319&&(i=t.charCodeAt(s+1),i>=56320&&i<=57343)){e+=s5((r-55296)*1024+i-56320+65536),s++;continue}n=Ri[r],e+=!n&&ug(r)?t[s]:n||s5(r)}return e}function YDe(t,e,r){var i="",n=t.tag,s,o;for(s=0,o=r.length;s1024&&(u+="? "),u+=t.dump+(t.condenseFlow?'"':"")+":"+(t.condenseFlow?"":" "),!!ic(t,e,c,!1,!1)&&(u+=t.dump,i+=u));t.tag=n,t.dump="{"+i+"}"}function WDe(t,e,r,i){var n="",s=t.tag,o=Object.keys(r),a,l,c,u,g,f;if(t.sortKeys===!0)o.sort();else if(typeof t.sortKeys=="function")o.sort(t.sortKeys);else if(t.sortKeys)throw new Kp("sortKeys must be a boolean or a function");for(a=0,l=o.length;a1024,g&&(t.dump&&Up===t.dump.charCodeAt(0)?f+="?":f+="? "),f+=t.dump,g&&(f+=OP(t,e)),!!ic(t,e+1,u,!0,g)&&(t.dump&&Up===t.dump.charCodeAt(0)?f+=":":f+=": ",f+=t.dump,n+=f));t.tag=s,t.dump=n||"{}"}function d5(t,e,r){var i,n,s,o,a,l;for(n=r?t.explicitTypes:t.implicitTypes,s=0,o=n.length;s tag resolver accepts not "'+l+'" style');t.dump=i}return!0}return!1}function ic(t,e,r,i,n,s){t.tag=null,t.dump=r,d5(t,r,!1)||d5(t,r,!0);var o=_z.call(t.dump);i&&(i=t.flowLevel<0||t.flowLevel>e);var a=o==="[object Object]"||o==="[object Array]",l,c;if(a&&(l=t.duplicates.indexOf(r),c=l!==-1),(t.tag!==null&&t.tag!=="?"||c||t.indent!==2&&e>0)&&(n=!1),c&&t.usedDuplicates[l])t.dump="*ref_"+l;else{if(a&&c&&!t.usedDuplicates[l]&&(t.usedDuplicates[l]=!0),o==="[object Object]")i&&Object.keys(t.dump).length!==0?(WDe(t,e,t.dump,n),c&&(t.dump="&ref_"+l+t.dump)):(JDe(t,e,t.dump),c&&(t.dump="&ref_"+l+" "+t.dump));else if(o==="[object Array]"){var u=t.noArrayIndent&&e>0?e-1:e;i&&t.dump.length!==0?(qDe(t,u,t.dump,n),c&&(t.dump="&ref_"+l+t.dump)):(YDe(t,u,t.dump),c&&(t.dump="&ref_"+l+" "+t.dump))}else if(o==="[object String]")t.tag!=="?"&&jDe(t,t.dump,e,s);else{if(t.skipInvalid)return!1;throw new Kp("unacceptable kind of an object to dump "+o)}t.tag!==null&&t.tag!=="?"&&(t.dump="!<"+t.tag+"> "+t.dump)}return!0}function zDe(t,e){var r=[],i=[],n,s;for(UP(t,r,i),n=0,s=i.length;n{"use strict";var ww=Vz(),E5=m5();function Bw(t){return function(){throw new Error("Function "+t+" is deprecated and cannot be used.")}}Qr.exports.Type=Xr();Qr.exports.Schema=ec();Qr.exports.FAILSAFE_SCHEMA=pw();Qr.exports.JSON_SCHEMA=DP();Qr.exports.CORE_SCHEMA=RP();Qr.exports.DEFAULT_SAFE_SCHEMA=og();Qr.exports.DEFAULT_FULL_SCHEMA=Tp();Qr.exports.load=ww.load;Qr.exports.loadAll=ww.loadAll;Qr.exports.safeLoad=ww.safeLoad;Qr.exports.safeLoadAll=ww.safeLoadAll;Qr.exports.dump=E5.dump;Qr.exports.safeDump=E5.safeDump;Qr.exports.YAMLException=ng();Qr.exports.MINIMAL_SCHEMA=pw();Qr.exports.SAFE_SCHEMA=og();Qr.exports.DEFAULT_SCHEMA=Tp();Qr.exports.scan=Bw("scan");Qr.exports.parse=Bw("parse");Qr.exports.compose=Bw("compose");Qr.exports.addConstructor=Bw("addConstructor")});var w5=E((wat,y5)=>{"use strict";var _De=I5();y5.exports=_De});var Q5=E((Bat,B5)=>{"use strict";function XDe(t,e){function r(){this.constructor=t}r.prototype=e.prototype,t.prototype=new r}function nc(t,e,r,i){this.message=t,this.expected=e,this.found=r,this.location=i,this.name="SyntaxError",typeof Error.captureStackTrace=="function"&&Error.captureStackTrace(this,nc)}XDe(nc,Error);nc.buildMessage=function(t,e){var r={literal:function(c){return'"'+n(c.text)+'"'},class:function(c){var u="",g;for(g=0;g0){for(g=1,f=1;g({[xe]:le})))},H=function(x){return x},L=function(x){return x},K=Yo("correct indentation"),J=" ",ne=fr(" ",!1),q=function(x){return x.length===Zc*aE},A=function(x){return x.length===(Zc+1)*aE},V=function(){return Zc++,!0},W=function(){return Zc--,!0},X=function(){return Xm()},F=Yo("pseudostring"),D=/^[^\r\n\t ?:,\][{}#&*!|>'"%@`\-]/,he=Bs(["\r",` +`," "," ","?",":",",","]","[","{","}","#","&","*","!","|",">","'",'"',"%","@","`","-"],!0,!1),pe=/^[^\r\n\t ,\][{}:#"']/,Ne=Bs(["\r",` +`," "," ",",","]","[","{","}",":","#",'"',"'"],!0,!1),Pe=function(){return Xm().replace(/^ *| *$/g,"")},qe="--",re=fr("--",!1),se=/^[a-zA-Z\/0-9]/,be=Bs([["a","z"],["A","Z"],"/",["0","9"]],!1,!1),ae=/^[^\r\n\t :,]/,Ae=Bs(["\r",` +`," "," ",":",","],!0,!1),De="null",$=fr("null",!1),G=function(){return null},Ce="true",ee=fr("true",!1),Ue=function(){return!0},Oe="false",vt=fr("false",!1),dt=function(){return!1},ri=Yo("string"),ii='"',an=fr('"',!1),yr=function(){return""},Ki=function(x){return x},Qi=function(x){return x.join("")},Go=/^[^"\\\0-\x1F\x7F]/,wr=Bs(['"',"\\",["\0",""],"\x7F"],!0,!1),Ui='\\"',ws=fr('\\"',!1),Tf=function(){return'"'},Mf="\\\\",Rm=fr("\\\\",!1),Fm=function(){return"\\"},Nm="\\/",DQ=fr("\\/",!1),RQ=function(){return"/"},Of="\\b",FQ=fr("\\b",!1),NQ=function(){return"\b"},Lm="\\f",LQ=fr("\\f",!1),Va=function(){return"\f"},jo="\\n",Tm=fr("\\n",!1),Mm=function(){return` +`},te="\\r",Om=fr("\\r",!1),Km=function(){return"\r"},il="\\t",Um=fr("\\t",!1),Hm=function(){return" "},Kf="\\u",Gm=fr("\\u",!1),jm=function(x,U,le,xe){return String.fromCharCode(parseInt(`0x${x}${U}${le}${xe}`))},TQ=/^[0-9a-fA-F]/,MQ=Bs([["0","9"],["a","f"],["A","F"]],!1,!1),Ym=Yo("blank space"),qm=/^[ \t]/,Jm=Bs([" "," "],!1,!1),Wm=Yo("white space"),zm=/^[ \t\n\r]/,Vm=Bs([" "," ",` +`,"\r"],!1,!1),Uf=`\r +`,OQ=fr(`\r +`,!1),KQ=` +`,_m=fr(` +`,!1),UQ="\r",HQ=fr("\r",!1),O=0,ht=0,Vc=[{line:1,column:1}],xn=0,Hf=[],Ye=0,nl;if("startRule"in e){if(!(e.startRule in i))throw new Error(`Can't start parsing from rule "`+e.startRule+'".');n=i[e.startRule]}function Xm(){return t.substring(ht,O)}function MM(){return _a(ht,O)}function GQ(x,U){throw U=U!==void 0?U:_a(ht,O),eE([Yo(x)],t.substring(ht,O),U)}function OM(x,U){throw U=U!==void 0?U:_a(ht,O),YQ(x,U)}function fr(x,U){return{type:"literal",text:x,ignoreCase:U}}function Bs(x,U,le){return{type:"class",parts:x,inverted:U,ignoreCase:le}}function jQ(){return{type:"any"}}function Zm(){return{type:"end"}}function Yo(x){return{type:"other",description:x}}function $m(x){var U=Vc[x],le;if(U)return U;for(le=x-1;!Vc[le];)le--;for(U=Vc[le],U={line:U.line,column:U.column};lexn&&(xn=O,Hf=[]),Hf.push(x))}function YQ(x,U){return new nc(x,null,null,U)}function eE(x,U,le){return new nc(nc.buildMessage(x,U),x,U,le)}function tE(){var x;return x=ol(),x}function Xa(){var x,U,le;for(x=O,U=[],le=sl();le!==r;)U.push(le),le=sl();return U!==r&&(ht=x,U=s(U)),x=U,x}function sl(){var x,U,le,xe,Qe;return x=O,U=Al(),U!==r?(t.charCodeAt(O)===45?(le=o,O++):(le=r,Ye===0&&et(a)),le!==r?(xe=xr(),xe!==r?(Qe=qo(),Qe!==r?(ht=x,U=l(Qe),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r),x}function ol(){var x,U,le;for(x=O,U=[],le=al();le!==r;)U.push(le),le=al();return U!==r&&(ht=x,U=c(U)),x=U,x}function al(){var x,U,le,xe,Qe,Ge,ct,sr,Wo;if(x=O,U=xr(),U===r&&(U=null),U!==r){if(le=O,t.charCodeAt(O)===35?(xe=u,O++):(xe=r,Ye===0&&et(g)),xe!==r){if(Qe=[],Ge=O,ct=O,Ye++,sr=Zs(),Ye--,sr===r?ct=void 0:(O=ct,ct=r),ct!==r?(t.length>O?(sr=t.charAt(O),O++):(sr=r,Ye===0&&et(f)),sr!==r?(ct=[ct,sr],Ge=ct):(O=Ge,Ge=r)):(O=Ge,Ge=r),Ge!==r)for(;Ge!==r;)Qe.push(Ge),Ge=O,ct=O,Ye++,sr=Zs(),Ye--,sr===r?ct=void 0:(O=ct,ct=r),ct!==r?(t.length>O?(sr=t.charAt(O),O++):(sr=r,Ye===0&&et(f)),sr!==r?(ct=[ct,sr],Ge=ct):(O=Ge,Ge=r)):(O=Ge,Ge=r);else Qe=r;Qe!==r?(xe=[xe,Qe],le=xe):(O=le,le=r)}else O=le,le=r;if(le===r&&(le=null),le!==r){if(xe=[],Qe=Jo(),Qe!==r)for(;Qe!==r;)xe.push(Qe),Qe=Jo();else xe=r;xe!==r?(ht=x,U=h(),x=U):(O=x,x=r)}else O=x,x=r}else O=x,x=r;if(x===r&&(x=O,U=Al(),U!==r?(le=JQ(),le!==r?(xe=xr(),xe===r&&(xe=null),xe!==r?(t.charCodeAt(O)===58?(Qe=p,O++):(Qe=r,Ye===0&&et(d)),Qe!==r?(Ge=xr(),Ge===r&&(Ge=null),Ge!==r?(ct=qo(),ct!==r?(ht=x,U=m(le,ct),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r),x===r&&(x=O,U=Al(),U!==r?(le=ll(),le!==r?(xe=xr(),xe===r&&(xe=null),xe!==r?(t.charCodeAt(O)===58?(Qe=p,O++):(Qe=r,Ye===0&&et(d)),Qe!==r?(Ge=xr(),Ge===r&&(Ge=null),Ge!==r?(ct=qo(),ct!==r?(ht=x,U=m(le,ct),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r),x===r))){if(x=O,U=Al(),U!==r)if(le=ll(),le!==r)if(xe=xr(),xe!==r)if(Qe=nE(),Qe!==r){if(Ge=[],ct=Jo(),ct!==r)for(;ct!==r;)Ge.push(ct),ct=Jo();else Ge=r;Ge!==r?(ht=x,U=m(le,Qe),x=U):(O=x,x=r)}else O=x,x=r;else O=x,x=r;else O=x,x=r;else O=x,x=r;if(x===r)if(x=O,U=Al(),U!==r)if(le=ll(),le!==r){if(xe=[],Qe=O,Ge=xr(),Ge===r&&(Ge=null),Ge!==r?(t.charCodeAt(O)===44?(ct=I,O++):(ct=r,Ye===0&&et(B)),ct!==r?(sr=xr(),sr===r&&(sr=null),sr!==r?(Wo=ll(),Wo!==r?(ht=Qe,Ge=b(le,Wo),Qe=Ge):(O=Qe,Qe=r)):(O=Qe,Qe=r)):(O=Qe,Qe=r)):(O=Qe,Qe=r),Qe!==r)for(;Qe!==r;)xe.push(Qe),Qe=O,Ge=xr(),Ge===r&&(Ge=null),Ge!==r?(t.charCodeAt(O)===44?(ct=I,O++):(ct=r,Ye===0&&et(B)),ct!==r?(sr=xr(),sr===r&&(sr=null),sr!==r?(Wo=ll(),Wo!==r?(ht=Qe,Ge=b(le,Wo),Qe=Ge):(O=Qe,Qe=r)):(O=Qe,Qe=r)):(O=Qe,Qe=r)):(O=Qe,Qe=r);else xe=r;xe!==r?(Qe=xr(),Qe===r&&(Qe=null),Qe!==r?(t.charCodeAt(O)===58?(Ge=p,O++):(Ge=r,Ye===0&&et(d)),Ge!==r?(ct=xr(),ct===r&&(ct=null),ct!==r?(sr=qo(),sr!==r?(ht=x,U=R(le,xe,sr),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)}else O=x,x=r;else O=x,x=r}return x}function qo(){var x,U,le,xe,Qe,Ge,ct;if(x=O,U=O,Ye++,le=O,xe=Zs(),xe!==r?(Qe=qQ(),Qe!==r?(t.charCodeAt(O)===45?(Ge=o,O++):(Ge=r,Ye===0&&et(a)),Ge!==r?(ct=xr(),ct!==r?(xe=[xe,Qe,Ge,ct],le=xe):(O=le,le=r)):(O=le,le=r)):(O=le,le=r)):(O=le,le=r),Ye--,le!==r?(O=U,U=void 0):U=r,U!==r?(le=Jo(),le!==r?(xe=rE(),xe!==r?(Qe=Xa(),Qe!==r?(Ge=iE(),Ge!==r?(ht=x,U=H(Qe),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r),x===r&&(x=O,U=Zs(),U!==r?(le=rE(),le!==r?(xe=ol(),xe!==r?(Qe=iE(),Qe!==r?(ht=x,U=H(xe),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r),x===r))if(x=O,U=WQ(),U!==r){if(le=[],xe=Jo(),xe!==r)for(;xe!==r;)le.push(xe),xe=Jo();else le=r;le!==r?(ht=x,U=L(U),x=U):(O=x,x=r)}else O=x,x=r;return x}function Al(){var x,U,le;for(Ye++,x=O,U=[],t.charCodeAt(O)===32?(le=J,O++):(le=r,Ye===0&&et(ne));le!==r;)U.push(le),t.charCodeAt(O)===32?(le=J,O++):(le=r,Ye===0&&et(ne));return U!==r?(ht=O,le=q(U),le?le=void 0:le=r,le!==r?(U=[U,le],x=U):(O=x,x=r)):(O=x,x=r),Ye--,x===r&&(U=r,Ye===0&&et(K)),x}function qQ(){var x,U,le;for(x=O,U=[],t.charCodeAt(O)===32?(le=J,O++):(le=r,Ye===0&&et(ne));le!==r;)U.push(le),t.charCodeAt(O)===32?(le=J,O++):(le=r,Ye===0&&et(ne));return U!==r?(ht=O,le=A(U),le?le=void 0:le=r,le!==r?(U=[U,le],x=U):(O=x,x=r)):(O=x,x=r),x}function rE(){var x;return ht=O,x=V(),x?x=void 0:x=r,x}function iE(){var x;return ht=O,x=W(),x?x=void 0:x=r,x}function JQ(){var x;return x=cl(),x===r&&(x=Gf()),x}function ll(){var x,U,le;if(x=cl(),x===r){if(x=O,U=[],le=_c(),le!==r)for(;le!==r;)U.push(le),le=_c();else U=r;U!==r&&(ht=x,U=X()),x=U}return x}function WQ(){var x;return x=jf(),x===r&&(x=sE(),x===r&&(x=cl(),x===r&&(x=Gf()))),x}function nE(){var x;return x=jf(),x===r&&(x=cl(),x===r&&(x=_c())),x}function Gf(){var x,U,le,xe,Qe,Ge;if(Ye++,x=O,D.test(t.charAt(O))?(U=t.charAt(O),O++):(U=r,Ye===0&&et(he)),U!==r){for(le=[],xe=O,Qe=xr(),Qe===r&&(Qe=null),Qe!==r?(pe.test(t.charAt(O))?(Ge=t.charAt(O),O++):(Ge=r,Ye===0&&et(Ne)),Ge!==r?(Qe=[Qe,Ge],xe=Qe):(O=xe,xe=r)):(O=xe,xe=r);xe!==r;)le.push(xe),xe=O,Qe=xr(),Qe===r&&(Qe=null),Qe!==r?(pe.test(t.charAt(O))?(Ge=t.charAt(O),O++):(Ge=r,Ye===0&&et(Ne)),Ge!==r?(Qe=[Qe,Ge],xe=Qe):(O=xe,xe=r)):(O=xe,xe=r);le!==r?(ht=x,U=Pe(),x=U):(O=x,x=r)}else O=x,x=r;return Ye--,x===r&&(U=r,Ye===0&&et(F)),x}function _c(){var x,U,le,xe,Qe;if(x=O,t.substr(O,2)===qe?(U=qe,O+=2):(U=r,Ye===0&&et(re)),U===r&&(U=null),U!==r)if(se.test(t.charAt(O))?(le=t.charAt(O),O++):(le=r,Ye===0&&et(be)),le!==r){for(xe=[],ae.test(t.charAt(O))?(Qe=t.charAt(O),O++):(Qe=r,Ye===0&&et(Ae));Qe!==r;)xe.push(Qe),ae.test(t.charAt(O))?(Qe=t.charAt(O),O++):(Qe=r,Ye===0&&et(Ae));xe!==r?(ht=x,U=Pe(),x=U):(O=x,x=r)}else O=x,x=r;else O=x,x=r;return x}function jf(){var x,U;return x=O,t.substr(O,4)===De?(U=De,O+=4):(U=r,Ye===0&&et($)),U!==r&&(ht=x,U=G()),x=U,x}function sE(){var x,U;return x=O,t.substr(O,4)===Ce?(U=Ce,O+=4):(U=r,Ye===0&&et(ee)),U!==r&&(ht=x,U=Ue()),x=U,x===r&&(x=O,t.substr(O,5)===Oe?(U=Oe,O+=5):(U=r,Ye===0&&et(vt)),U!==r&&(ht=x,U=dt()),x=U),x}function cl(){var x,U,le,xe;return Ye++,x=O,t.charCodeAt(O)===34?(U=ii,O++):(U=r,Ye===0&&et(an)),U!==r?(t.charCodeAt(O)===34?(le=ii,O++):(le=r,Ye===0&&et(an)),le!==r?(ht=x,U=yr(),x=U):(O=x,x=r)):(O=x,x=r),x===r&&(x=O,t.charCodeAt(O)===34?(U=ii,O++):(U=r,Ye===0&&et(an)),U!==r?(le=oE(),le!==r?(t.charCodeAt(O)===34?(xe=ii,O++):(xe=r,Ye===0&&et(an)),xe!==r?(ht=x,U=Ki(le),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)),Ye--,x===r&&(U=r,Ye===0&&et(ri)),x}function oE(){var x,U,le;if(x=O,U=[],le=Yf(),le!==r)for(;le!==r;)U.push(le),le=Yf();else U=r;return U!==r&&(ht=x,U=Qi(U)),x=U,x}function Yf(){var x,U,le,xe,Qe,Ge;return Go.test(t.charAt(O))?(x=t.charAt(O),O++):(x=r,Ye===0&&et(wr)),x===r&&(x=O,t.substr(O,2)===Ui?(U=Ui,O+=2):(U=r,Ye===0&&et(ws)),U!==r&&(ht=x,U=Tf()),x=U,x===r&&(x=O,t.substr(O,2)===Mf?(U=Mf,O+=2):(U=r,Ye===0&&et(Rm)),U!==r&&(ht=x,U=Fm()),x=U,x===r&&(x=O,t.substr(O,2)===Nm?(U=Nm,O+=2):(U=r,Ye===0&&et(DQ)),U!==r&&(ht=x,U=RQ()),x=U,x===r&&(x=O,t.substr(O,2)===Of?(U=Of,O+=2):(U=r,Ye===0&&et(FQ)),U!==r&&(ht=x,U=NQ()),x=U,x===r&&(x=O,t.substr(O,2)===Lm?(U=Lm,O+=2):(U=r,Ye===0&&et(LQ)),U!==r&&(ht=x,U=Va()),x=U,x===r&&(x=O,t.substr(O,2)===jo?(U=jo,O+=2):(U=r,Ye===0&&et(Tm)),U!==r&&(ht=x,U=Mm()),x=U,x===r&&(x=O,t.substr(O,2)===te?(U=te,O+=2):(U=r,Ye===0&&et(Om)),U!==r&&(ht=x,U=Km()),x=U,x===r&&(x=O,t.substr(O,2)===il?(U=il,O+=2):(U=r,Ye===0&&et(Um)),U!==r&&(ht=x,U=Hm()),x=U,x===r&&(x=O,t.substr(O,2)===Kf?(U=Kf,O+=2):(U=r,Ye===0&&et(Gm)),U!==r?(le=Xc(),le!==r?(xe=Xc(),xe!==r?(Qe=Xc(),Qe!==r?(Ge=Xc(),Ge!==r?(ht=x,U=jm(le,xe,Qe,Ge),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)))))))))),x}function Xc(){var x;return TQ.test(t.charAt(O))?(x=t.charAt(O),O++):(x=r,Ye===0&&et(MQ)),x}function xr(){var x,U;if(Ye++,x=[],qm.test(t.charAt(O))?(U=t.charAt(O),O++):(U=r,Ye===0&&et(Jm)),U!==r)for(;U!==r;)x.push(U),qm.test(t.charAt(O))?(U=t.charAt(O),O++):(U=r,Ye===0&&et(Jm));else x=r;return Ye--,x===r&&(U=r,Ye===0&&et(Ym)),x}function KM(){var x,U;if(Ye++,x=[],zm.test(t.charAt(O))?(U=t.charAt(O),O++):(U=r,Ye===0&&et(Vm)),U!==r)for(;U!==r;)x.push(U),zm.test(t.charAt(O))?(U=t.charAt(O),O++):(U=r,Ye===0&&et(Vm));else x=r;return Ye--,x===r&&(U=r,Ye===0&&et(Wm)),x}function Jo(){var x,U,le,xe,Qe,Ge;if(x=O,U=Zs(),U!==r){for(le=[],xe=O,Qe=xr(),Qe===r&&(Qe=null),Qe!==r?(Ge=Zs(),Ge!==r?(Qe=[Qe,Ge],xe=Qe):(O=xe,xe=r)):(O=xe,xe=r);xe!==r;)le.push(xe),xe=O,Qe=xr(),Qe===r&&(Qe=null),Qe!==r?(Ge=Zs(),Ge!==r?(Qe=[Qe,Ge],xe=Qe):(O=xe,xe=r)):(O=xe,xe=r);le!==r?(U=[U,le],x=U):(O=x,x=r)}else O=x,x=r;return x}function Zs(){var x;return t.substr(O,2)===Uf?(x=Uf,O+=2):(x=r,Ye===0&&et(OQ)),x===r&&(t.charCodeAt(O)===10?(x=KQ,O++):(x=r,Ye===0&&et(_m)),x===r&&(t.charCodeAt(O)===13?(x=UQ,O++):(x=r,Ye===0&&et(HQ)))),x}let aE=2,Zc=0;if(nl=n(),nl!==r&&O===t.length)return nl;throw nl!==r&&O{var fRe=typeof global=="object"&&global&&global.Object===Object&&global;V5.exports=fRe});var Ks=E((Zat,_5)=>{var hRe=WP(),pRe=typeof self=="object"&&self&&self.Object===Object&&self,dRe=hRe||pRe||Function("return this")();_5.exports=dRe});var ac=E(($at,X5)=>{var CRe=Ks(),mRe=CRe.Symbol;X5.exports=mRe});var $5=E((eAt,Z5)=>{function ERe(t,e){for(var r=-1,i=t==null?0:t.length,n=Array(i);++r{var IRe=Array.isArray;e6.exports=IRe});var n6=E((rAt,t6)=>{var r6=ac(),i6=Object.prototype,yRe=i6.hasOwnProperty,wRe=i6.toString,Jp=r6?r6.toStringTag:void 0;function BRe(t){var e=yRe.call(t,Jp),r=t[Jp];try{t[Jp]=void 0;var i=!0}catch(s){}var n=wRe.call(t);return i&&(e?t[Jp]=r:delete t[Jp]),n}t6.exports=BRe});var o6=E((iAt,s6)=>{var QRe=Object.prototype,bRe=QRe.toString;function vRe(t){return bRe.call(t)}s6.exports=vRe});var Ac=E((nAt,a6)=>{var A6=ac(),SRe=n6(),xRe=o6(),kRe="[object Null]",PRe="[object Undefined]",l6=A6?A6.toStringTag:void 0;function DRe(t){return t==null?t===void 0?PRe:kRe:l6&&l6 in Object(t)?SRe(t):xRe(t)}a6.exports=DRe});var Qo=E((sAt,c6)=>{function RRe(t){return t!=null&&typeof t=="object"}c6.exports=RRe});var Nw=E((oAt,u6)=>{var FRe=Ac(),NRe=Qo(),LRe="[object Symbol]";function TRe(t){return typeof t=="symbol"||NRe(t)&&FRe(t)==LRe}u6.exports=TRe});var C6=E((aAt,g6)=>{var f6=ac(),MRe=$5(),ORe=As(),KRe=Nw(),URe=1/0,h6=f6?f6.prototype:void 0,p6=h6?h6.toString:void 0;function d6(t){if(typeof t=="string")return t;if(ORe(t))return MRe(t,d6)+"";if(KRe(t))return p6?p6.call(t):"";var e=t+"";return e=="0"&&1/t==-URe?"-0":e}g6.exports=d6});var gg=E((AAt,m6)=>{var HRe=C6();function GRe(t){return t==null?"":HRe(t)}m6.exports=GRe});var zP=E((lAt,E6)=>{function jRe(t,e,r){var i=-1,n=t.length;e<0&&(e=-e>n?0:n+e),r=r>n?n:r,r<0&&(r+=n),n=e>r?0:r-e>>>0,e>>>=0;for(var s=Array(n);++i{var YRe=zP();function qRe(t,e,r){var i=t.length;return r=r===void 0?i:r,!e&&r>=i?t:YRe(t,e,r)}I6.exports=qRe});var VP=E((uAt,w6)=>{var JRe="\\ud800-\\udfff",WRe="\\u0300-\\u036f",zRe="\\ufe20-\\ufe2f",VRe="\\u20d0-\\u20ff",_Re=WRe+zRe+VRe,XRe="\\ufe0e\\ufe0f",ZRe="\\u200d",$Re=RegExp("["+ZRe+JRe+_Re+XRe+"]");function eFe(t){return $Re.test(t)}w6.exports=eFe});var Q6=E((gAt,B6)=>{function tFe(t){return t.split("")}B6.exports=tFe});var R6=E((fAt,b6)=>{var v6="\\ud800-\\udfff",rFe="\\u0300-\\u036f",iFe="\\ufe20-\\ufe2f",nFe="\\u20d0-\\u20ff",sFe=rFe+iFe+nFe,oFe="\\ufe0e\\ufe0f",aFe="["+v6+"]",_P="["+sFe+"]",XP="\\ud83c[\\udffb-\\udfff]",AFe="(?:"+_P+"|"+XP+")",S6="[^"+v6+"]",x6="(?:\\ud83c[\\udde6-\\uddff]){2}",k6="[\\ud800-\\udbff][\\udc00-\\udfff]",lFe="\\u200d",P6=AFe+"?",D6="["+oFe+"]?",cFe="(?:"+lFe+"(?:"+[S6,x6,k6].join("|")+")"+D6+P6+")*",uFe=D6+P6+cFe,gFe="(?:"+[S6+_P+"?",_P,x6,k6,aFe].join("|")+")",fFe=RegExp(XP+"(?="+XP+")|"+gFe+uFe,"g");function hFe(t){return t.match(fFe)||[]}b6.exports=hFe});var N6=E((hAt,F6)=>{var pFe=Q6(),dFe=VP(),CFe=R6();function mFe(t){return dFe(t)?CFe(t):pFe(t)}F6.exports=mFe});var T6=E((pAt,L6)=>{var EFe=y6(),IFe=VP(),yFe=N6(),wFe=gg();function BFe(t){return function(e){e=wFe(e);var r=IFe(e)?yFe(e):void 0,i=r?r[0]:e.charAt(0),n=r?EFe(r,1).join(""):e.slice(1);return i[t]()+n}}L6.exports=BFe});var O6=E((dAt,M6)=>{var QFe=T6(),bFe=QFe("toUpperCase");M6.exports=bFe});var ZP=E((CAt,K6)=>{var vFe=gg(),SFe=O6();function xFe(t){return SFe(vFe(t).toLowerCase())}K6.exports=xFe});var H6=E((mAt,U6)=>{"use strict";U6.exports=(t,...e)=>new Promise(r=>{r(t(...e))})});var Wp=E((EAt,$P)=>{"use strict";var kFe=H6(),G6=t=>{if(t<1)throw new TypeError("Expected `concurrency` to be a number from 1 and up");let e=[],r=0,i=()=>{r--,e.length>0&&e.shift()()},n=(a,l,...c)=>{r++;let u=kFe(a,...c);l(u),u.then(i,i)},s=(a,l,...c)=>{rnew Promise(c=>s(a,c,...l));return Object.defineProperties(o,{activeCount:{get:()=>r},pendingCount:{get:()=>e.length}}),o};$P.exports=G6;$P.exports.default=G6});var X6=E((FAt,Mw)=>{function PFe(){var t=0,e=1,r=2,i=3,n=4,s=5,o=6,a=7,l=8,c=9,u=10,g=11,f=12,h=13,p=14,d=15,m=16,I=17,B=0,b=1,R=2,H=3,L=4;function K(A,V){return 55296<=A.charCodeAt(V)&&A.charCodeAt(V)<=56319&&56320<=A.charCodeAt(V+1)&&A.charCodeAt(V+1)<=57343}function J(A,V){V===void 0&&(V=0);var W=A.charCodeAt(V);if(55296<=W&&W<=56319&&V=1){var X=A.charCodeAt(V-1),F=W;return 55296<=X&&X<=56319?(X-55296)*1024+(F-56320)+65536:F}return W}function ne(A,V,W){var X=[A].concat(V).concat([W]),F=X[X.length-2],D=W,he=X.lastIndexOf(p);if(he>1&&X.slice(1,he).every(function(Pe){return Pe==i})&&[i,h,I].indexOf(A)==-1)return R;var pe=X.lastIndexOf(n);if(pe>0&&X.slice(1,pe).every(function(Pe){return Pe==n})&&[f,n].indexOf(F)==-1)return X.filter(function(Pe){return Pe==n}).length%2==1?H:L;if(F==t&&D==e)return B;if(F==r||F==t||F==e)return D==p&&V.every(function(Pe){return Pe==i})?R:b;if(D==r||D==t||D==e)return b;if(F==o&&(D==o||D==a||D==c||D==u))return B;if((F==c||F==a)&&(D==a||D==l))return B;if((F==u||F==l)&&D==l)return B;if(D==i||D==d)return B;if(D==s)return B;if(F==f)return B;var Ne=X.indexOf(i)!=-1?X.lastIndexOf(i)-1:X.length-2;return[h,I].indexOf(X[Ne])!=-1&&X.slice(Ne+1,-1).every(function(Pe){return Pe==i})&&D==p||F==d&&[m,I].indexOf(D)!=-1?B:V.indexOf(n)!=-1?R:F==n&&D==n?B:b}this.nextBreak=function(A,V){if(V===void 0&&(V=0),V<0)return 0;if(V>=A.length-1)return A.length;for(var W=q(J(A,V)),X=[],F=V+1;F{var DFe=X6(),RFe=/^(.*?)(\x1b\[[^m]+m|\x1b\]8;;.*?(\x1b\\|\u0007))/,FFe=new DFe;Z6.exports=(t,e=0,r=t.length)=>{if(e<0||r<0)throw new RangeError("Negative indices aren't supported by this implementation");let i=r-e,n="",s=0,o=0;for(;t.length>0;){let a=t.match(RFe)||[t,t,void 0],l=FFe.splitGraphemes(a[1]),c=Math.min(e-s,l.length);l=l.slice(c);let u=Math.min(i-o,l.length);n+=l.slice(0,u).join(""),s+=c,o+=u,typeof a[2]!="undefined"&&(n+=a[2]),t=t.slice(a[0].length)}return n}});var fg=E((alt,f9)=>{"use strict";var h9=new Map([["C","cwd"],["f","file"],["z","gzip"],["P","preservePaths"],["U","unlink"],["strip-components","strip"],["stripComponents","strip"],["keep-newer","newer"],["keepNewer","newer"],["keep-newer-files","newer"],["keepNewerFiles","newer"],["k","keep"],["keep-existing","keep"],["keepExisting","keep"],["m","noMtime"],["no-mtime","noMtime"],["p","preserveOwner"],["L","follow"],["h","follow"]]),olt=f9.exports=t=>t?Object.keys(t).map(e=>[h9.has(e)?h9.get(e):e,t[e]]).reduce((e,r)=>(e[r[0]]=r[1],e),Object.create(null)):{}});var hg=E((Alt,p9)=>{"use strict";var JFe=require("events"),d9=require("stream"),_p=Rh(),C9=require("string_decoder").StringDecoder,va=Symbol("EOF"),Xp=Symbol("maybeEmitEnd"),xA=Symbol("emittedEnd"),Gw=Symbol("emittingEnd"),jw=Symbol("closed"),m9=Symbol("read"),iD=Symbol("flush"),E9=Symbol("flushChunk"),Bn=Symbol("encoding"),Sa=Symbol("decoder"),Yw=Symbol("flowing"),Zp=Symbol("paused"),$p=Symbol("resume"),rn=Symbol("bufferLength"),I9=Symbol("bufferPush"),nD=Symbol("bufferShift"),Ni=Symbol("objectMode"),Li=Symbol("destroyed"),y9=global._MP_NO_ITERATOR_SYMBOLS_!=="1",WFe=y9&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),zFe=y9&&Symbol.iterator||Symbol("iterator not implemented"),w9=t=>t==="end"||t==="finish"||t==="prefinish",VFe=t=>t instanceof ArrayBuffer||typeof t=="object"&&t.constructor&&t.constructor.name==="ArrayBuffer"&&t.byteLength>=0,_Fe=t=>!Buffer.isBuffer(t)&&ArrayBuffer.isView(t);p9.exports=class B9 extends d9{constructor(e){super();this[Yw]=!1,this[Zp]=!1,this.pipes=new _p,this.buffer=new _p,this[Ni]=e&&e.objectMode||!1,this[Ni]?this[Bn]=null:this[Bn]=e&&e.encoding||null,this[Bn]==="buffer"&&(this[Bn]=null),this[Sa]=this[Bn]?new C9(this[Bn]):null,this[va]=!1,this[xA]=!1,this[Gw]=!1,this[jw]=!1,this.writable=!0,this.readable=!0,this[rn]=0,this[Li]=!1}get bufferLength(){return this[rn]}get encoding(){return this[Bn]}set encoding(e){if(this[Ni])throw new Error("cannot set encoding in objectMode");if(this[Bn]&&e!==this[Bn]&&(this[Sa]&&this[Sa].lastNeed||this[rn]))throw new Error("cannot change encoding");this[Bn]!==e&&(this[Sa]=e?new C9(e):null,this.buffer.length&&(this.buffer=this.buffer.map(r=>this[Sa].write(r)))),this[Bn]=e}setEncoding(e){this.encoding=e}get objectMode(){return this[Ni]}set objectMode(e){this[Ni]=this[Ni]||!!e}write(e,r,i){if(this[va])throw new Error("write after end");return this[Li]?(this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0):(typeof r=="function"&&(i=r,r="utf8"),r||(r="utf8"),!this[Ni]&&!Buffer.isBuffer(e)&&(_Fe(e)?e=Buffer.from(e.buffer,e.byteOffset,e.byteLength):VFe(e)?e=Buffer.from(e):typeof e!="string"&&(this.objectMode=!0)),!this.objectMode&&!e.length?(this[rn]!==0&&this.emit("readable"),i&&i(),this.flowing):(typeof e=="string"&&!this[Ni]&&!(r===this[Bn]&&!this[Sa].lastNeed)&&(e=Buffer.from(e,r)),Buffer.isBuffer(e)&&this[Bn]&&(e=this[Sa].write(e)),this.flowing?(this[rn]!==0&&this[iD](!0),this.emit("data",e)):this[I9](e),this[rn]!==0&&this.emit("readable"),i&&i(),this.flowing))}read(e){if(this[Li])return null;try{return this[rn]===0||e===0||e>this[rn]?null:(this[Ni]&&(e=null),this.buffer.length>1&&!this[Ni]&&(this.encoding?this.buffer=new _p([Array.from(this.buffer).join("")]):this.buffer=new _p([Buffer.concat(Array.from(this.buffer),this[rn])])),this[m9](e||null,this.buffer.head.value))}finally{this[Xp]()}}[m9](e,r){return e===r.length||e===null?this[nD]():(this.buffer.head.value=r.slice(e),r=r.slice(0,e),this[rn]-=e),this.emit("data",r),!this.buffer.length&&!this[va]&&this.emit("drain"),r}end(e,r,i){return typeof e=="function"&&(i=e,e=null),typeof r=="function"&&(i=r,r="utf8"),e&&this.write(e,r),i&&this.once("end",i),this[va]=!0,this.writable=!1,(this.flowing||!this[Zp])&&this[Xp](),this}[$p](){this[Li]||(this[Zp]=!1,this[Yw]=!0,this.emit("resume"),this.buffer.length?this[iD]():this[va]?this[Xp]():this.emit("drain"))}resume(){return this[$p]()}pause(){this[Yw]=!1,this[Zp]=!0}get destroyed(){return this[Li]}get flowing(){return this[Yw]}get paused(){return this[Zp]}[I9](e){return this[Ni]?this[rn]+=1:this[rn]+=e.length,this.buffer.push(e)}[nD](){return this.buffer.length&&(this[Ni]?this[rn]-=1:this[rn]-=this.buffer.head.value.length),this.buffer.shift()}[iD](e){do;while(this[E9](this[nD]()));!e&&!this.buffer.length&&!this[va]&&this.emit("drain")}[E9](e){return e?(this.emit("data",e),this.flowing):!1}pipe(e,r){if(this[Li])return;let i=this[xA];r=r||{},e===process.stdout||e===process.stderr?r.end=!1:r.end=r.end!==!1;let n={dest:e,opts:r,ondrain:s=>this[$p]()};return this.pipes.push(n),e.on("drain",n.ondrain),this[$p](),i&&n.opts.end&&n.dest.end(),e}addListener(e,r){return this.on(e,r)}on(e,r){try{return super.on(e,r)}finally{e==="data"&&!this.pipes.length&&!this.flowing?this[$p]():w9(e)&&this[xA]&&(super.emit(e),this.removeAllListeners(e))}}get emittedEnd(){return this[xA]}[Xp](){!this[Gw]&&!this[xA]&&!this[Li]&&this.buffer.length===0&&this[va]&&(this[Gw]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[jw]&&this.emit("close"),this[Gw]=!1)}emit(e,r){if(e!=="error"&&e!=="close"&&e!==Li&&this[Li])return;if(e==="data"){if(!r)return;this.pipes.length&&this.pipes.forEach(n=>n.dest.write(r)===!1&&this.pause())}else if(e==="end"){if(this[xA]===!0)return;this[xA]=!0,this.readable=!1,this[Sa]&&(r=this[Sa].end(),r&&(this.pipes.forEach(n=>n.dest.write(r)),super.emit("data",r))),this.pipes.forEach(n=>{n.dest.removeListener("drain",n.ondrain),n.opts.end&&n.dest.end()})}else if(e==="close"&&(this[jw]=!0,!this[xA]&&!this[Li]))return;let i=new Array(arguments.length);if(i[0]=e,i[1]=r,arguments.length>2)for(let n=2;n{e.push(i),this[Ni]||(e.dataLength+=i.length)}),r.then(()=>e)}concat(){return this[Ni]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(e=>this[Ni]?Promise.reject(new Error("cannot concat in objectMode")):this[Bn]?e.join(""):Buffer.concat(e,e.dataLength))}promise(){return new Promise((e,r)=>{this.on(Li,()=>r(new Error("stream destroyed"))),this.on("end",()=>e()),this.on("error",i=>r(i))})}[WFe](){return{next:()=>{let r=this.read();if(r!==null)return Promise.resolve({done:!1,value:r});if(this[va])return Promise.resolve({done:!0});let i=null,n=null,s=c=>{this.removeListener("data",o),this.removeListener("end",a),n(c)},o=c=>{this.removeListener("error",s),this.removeListener("end",a),this.pause(),i({value:c,done:!!this[va]})},a=()=>{this.removeListener("error",s),this.removeListener("data",o),i({done:!0})},l=()=>s(new Error("stream destroyed"));return new Promise((c,u)=>{n=u,i=c,this.once(Li,l),this.once("error",s),this.once("end",a),this.once("data",o)})}}}[zFe](){return{next:()=>{let r=this.read();return{value:r,done:r===null}}}}destroy(e){return this[Li]?(e?this.emit("error",e):this.emit(Li),this):(this[Li]=!0,this.buffer=new _p,this[rn]=0,typeof this.close=="function"&&!this[jw]&&this.close(),e?this.emit("error",e):this.emit(Li),this)}static isStream(e){return!!e&&(e instanceof B9||e instanceof d9||e instanceof JFe&&(typeof e.pipe=="function"||typeof e.write=="function"&&typeof e.end=="function"))}}});var b9=E((llt,Q9)=>{var XFe=require("zlib").constants||{ZLIB_VERNUM:4736};Q9.exports=Object.freeze(Object.assign(Object.create(null),{Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_VERSION_ERROR:-6,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,DEFLATE:1,INFLATE:2,GZIP:3,GUNZIP:4,DEFLATERAW:5,INFLATERAW:6,UNZIP:7,BROTLI_DECODE:8,BROTLI_ENCODE:9,Z_MIN_WINDOWBITS:8,Z_MAX_WINDOWBITS:15,Z_DEFAULT_WINDOWBITS:15,Z_MIN_CHUNK:64,Z_MAX_CHUNK:Infinity,Z_DEFAULT_CHUNK:16384,Z_MIN_MEMLEVEL:1,Z_MAX_MEMLEVEL:9,Z_DEFAULT_MEMLEVEL:8,Z_MIN_LEVEL:-1,Z_MAX_LEVEL:9,Z_DEFAULT_LEVEL:-1,BROTLI_OPERATION_PROCESS:0,BROTLI_OPERATION_FLUSH:1,BROTLI_OPERATION_FINISH:2,BROTLI_OPERATION_EMIT_METADATA:3,BROTLI_MODE_GENERIC:0,BROTLI_MODE_TEXT:1,BROTLI_MODE_FONT:2,BROTLI_DEFAULT_MODE:0,BROTLI_MIN_QUALITY:0,BROTLI_MAX_QUALITY:11,BROTLI_DEFAULT_QUALITY:11,BROTLI_MIN_WINDOW_BITS:10,BROTLI_MAX_WINDOW_BITS:24,BROTLI_LARGE_MAX_WINDOW_BITS:30,BROTLI_DEFAULT_WINDOW:22,BROTLI_MIN_INPUT_BLOCK_BITS:16,BROTLI_MAX_INPUT_BLOCK_BITS:24,BROTLI_PARAM_MODE:0,BROTLI_PARAM_QUALITY:1,BROTLI_PARAM_LGWIN:2,BROTLI_PARAM_LGBLOCK:3,BROTLI_PARAM_DISABLE_LITERAL_CONTEXT_MODELING:4,BROTLI_PARAM_SIZE_HINT:5,BROTLI_PARAM_LARGE_WINDOW:6,BROTLI_PARAM_NPOSTFIX:7,BROTLI_PARAM_NDIRECT:8,BROTLI_DECODER_RESULT_ERROR:0,BROTLI_DECODER_RESULT_SUCCESS:1,BROTLI_DECODER_RESULT_NEEDS_MORE_INPUT:2,BROTLI_DECODER_RESULT_NEEDS_MORE_OUTPUT:3,BROTLI_DECODER_PARAM_DISABLE_RING_BUFFER_REALLOCATION:0,BROTLI_DECODER_PARAM_LARGE_WINDOW:1,BROTLI_DECODER_NO_ERROR:0,BROTLI_DECODER_SUCCESS:1,BROTLI_DECODER_NEEDS_MORE_INPUT:2,BROTLI_DECODER_NEEDS_MORE_OUTPUT:3,BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_NIBBLE:-1,BROTLI_DECODER_ERROR_FORMAT_RESERVED:-2,BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_META_NIBBLE:-3,BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_ALPHABET:-4,BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_SAME:-5,BROTLI_DECODER_ERROR_FORMAT_CL_SPACE:-6,BROTLI_DECODER_ERROR_FORMAT_HUFFMAN_SPACE:-7,BROTLI_DECODER_ERROR_FORMAT_CONTEXT_MAP_REPEAT:-8,BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_1:-9,BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_2:-10,BROTLI_DECODER_ERROR_FORMAT_TRANSFORM:-11,BROTLI_DECODER_ERROR_FORMAT_DICTIONARY:-12,BROTLI_DECODER_ERROR_FORMAT_WINDOW_BITS:-13,BROTLI_DECODER_ERROR_FORMAT_PADDING_1:-14,BROTLI_DECODER_ERROR_FORMAT_PADDING_2:-15,BROTLI_DECODER_ERROR_FORMAT_DISTANCE:-16,BROTLI_DECODER_ERROR_DICTIONARY_NOT_SET:-19,BROTLI_DECODER_ERROR_INVALID_ARGUMENTS:-20,BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MODES:-21,BROTLI_DECODER_ERROR_ALLOC_TREE_GROUPS:-22,BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MAP:-25,BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_1:-26,BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_2:-27,BROTLI_DECODER_ERROR_ALLOC_BLOCK_TYPE_TREES:-30,BROTLI_DECODER_ERROR_UNREACHABLE:-31},XFe))});var fD=E(Un=>{"use strict";var sD=require("assert"),kA=require("buffer").Buffer,v9=require("zlib"),uc=Un.constants=b9(),ZFe=hg(),S9=kA.concat,gc=Symbol("_superWrite"),ed=class extends Error{constructor(e){super("zlib: "+e.message);this.code=e.code,this.errno=e.errno,this.code||(this.code="ZLIB_ERROR"),this.message="zlib: "+e.message,Error.captureStackTrace(this,this.constructor)}get name(){return"ZlibError"}},$Fe=Symbol("opts"),td=Symbol("flushFlag"),x9=Symbol("finishFlushFlag"),oD=Symbol("fullFlushFlag"),tr=Symbol("handle"),qw=Symbol("onError"),pg=Symbol("sawError"),aD=Symbol("level"),AD=Symbol("strategy"),lD=Symbol("ended"),clt=Symbol("_defaultFullFlush"),cD=class extends ZFe{constructor(e,r){if(!e||typeof e!="object")throw new TypeError("invalid options for ZlibBase constructor");super(e);this[pg]=!1,this[lD]=!1,this[$Fe]=e,this[td]=e.flush,this[x9]=e.finishFlush;try{this[tr]=new v9[r](e)}catch(i){throw new ed(i)}this[qw]=i=>{this[pg]||(this[pg]=!0,this.close(),this.emit("error",i))},this[tr].on("error",i=>this[qw](new ed(i))),this.once("end",()=>this.close)}close(){this[tr]&&(this[tr].close(),this[tr]=null,this.emit("close"))}reset(){if(!this[pg])return sD(this[tr],"zlib binding closed"),this[tr].reset()}flush(e){this.ended||(typeof e!="number"&&(e=this[oD]),this.write(Object.assign(kA.alloc(0),{[td]:e})))}end(e,r,i){return e&&this.write(e,r),this.flush(this[x9]),this[lD]=!0,super.end(null,null,i)}get ended(){return this[lD]}write(e,r,i){if(typeof r=="function"&&(i=r,r="utf8"),typeof e=="string"&&(e=kA.from(e,r)),this[pg])return;sD(this[tr],"zlib binding closed");let n=this[tr]._handle,s=n.close;n.close=()=>{};let o=this[tr].close;this[tr].close=()=>{},kA.concat=c=>c;let a;try{let c=typeof e[td]=="number"?e[td]:this[td];a=this[tr]._processChunk(e,c),kA.concat=S9}catch(c){kA.concat=S9,this[qw](new ed(c))}finally{this[tr]&&(this[tr]._handle=n,n.close=s,this[tr].close=o,this[tr].removeAllListeners("error"))}this[tr]&&this[tr].on("error",c=>this[qw](new ed(c)));let l;if(a)if(Array.isArray(a)&&a.length>0){l=this[gc](kA.from(a[0]));for(let c=1;c{this.flush(n),s()};try{this[tr].params(e,r)}finally{this[tr].flush=i}this[tr]&&(this[aD]=e,this[AD]=r)}}}},k9=class extends PA{constructor(e){super(e,"Deflate")}},P9=class extends PA{constructor(e){super(e,"Inflate")}},uD=Symbol("_portable"),D9=class extends PA{constructor(e){super(e,"Gzip");this[uD]=e&&!!e.portable}[gc](e){return this[uD]?(this[uD]=!1,e[9]=255,super[gc](e)):super[gc](e)}},R9=class extends PA{constructor(e){super(e,"Gunzip")}},F9=class extends PA{constructor(e){super(e,"DeflateRaw")}},N9=class extends PA{constructor(e){super(e,"InflateRaw")}},L9=class extends PA{constructor(e){super(e,"Unzip")}},gD=class extends cD{constructor(e,r){e=e||{},e.flush=e.flush||uc.BROTLI_OPERATION_PROCESS,e.finishFlush=e.finishFlush||uc.BROTLI_OPERATION_FINISH,super(e,r),this[oD]=uc.BROTLI_OPERATION_FLUSH}},T9=class extends gD{constructor(e){super(e,"BrotliCompress")}},M9=class extends gD{constructor(e){super(e,"BrotliDecompress")}};Un.Deflate=k9;Un.Inflate=P9;Un.Gzip=D9;Un.Gunzip=R9;Un.DeflateRaw=F9;Un.InflateRaw=N9;Un.Unzip=L9;typeof v9.BrotliCompress=="function"?(Un.BrotliCompress=T9,Un.BrotliDecompress=M9):Un.BrotliCompress=Un.BrotliDecompress=class{constructor(){throw new Error("Brotli is not supported in this version of Node.js")}}});var rd=E(Jw=>{"use strict";Jw.name=new Map([["0","File"],["","OldFile"],["1","Link"],["2","SymbolicLink"],["3","CharacterDevice"],["4","BlockDevice"],["5","Directory"],["6","FIFO"],["7","ContiguousFile"],["g","GlobalExtendedHeader"],["x","ExtendedHeader"],["A","SolarisACL"],["D","GNUDumpDir"],["I","Inode"],["K","NextFileHasLongLinkpath"],["L","NextFileHasLongPath"],["M","ContinuationFile"],["N","OldGnuLongPath"],["S","SparseFile"],["V","TapeVolumeHeader"],["X","OldExtendedHeader"]]);Jw.code=new Map(Array.from(Jw.name).map(t=>[t[1],t[0]]))});var id=E((plt,O9)=>{"use strict";var flt=rd(),eNe=hg(),hD=Symbol("slurp");O9.exports=class extends eNe{constructor(e,r,i){super();switch(this.pause(),this.extended=r,this.globalExtended=i,this.header=e,this.startBlockSize=512*Math.ceil(e.size/512),this.blockRemain=this.startBlockSize,this.remain=e.size,this.type=e.type,this.meta=!1,this.ignore=!1,this.type){case"File":case"OldFile":case"Link":case"SymbolicLink":case"CharacterDevice":case"BlockDevice":case"Directory":case"FIFO":case"ContiguousFile":case"GNUDumpDir":break;case"NextFileHasLongLinkpath":case"NextFileHasLongPath":case"OldGnuLongPath":case"GlobalExtendedHeader":case"ExtendedHeader":case"OldExtendedHeader":this.meta=!0;break;default:this.ignore=!0}this.path=e.path,this.mode=e.mode,this.mode&&(this.mode=this.mode&4095),this.uid=e.uid,this.gid=e.gid,this.uname=e.uname,this.gname=e.gname,this.size=e.size,this.mtime=e.mtime,this.atime=e.atime,this.ctime=e.ctime,this.linkpath=e.linkpath,this.uname=e.uname,this.gname=e.gname,r&&this[hD](r),i&&this[hD](i,!0)}write(e){let r=e.length;if(r>this.blockRemain)throw new Error("writing more to entry than is appropriate");let i=this.remain,n=this.blockRemain;return this.remain=Math.max(0,i-r),this.blockRemain=Math.max(0,n-r),this.ignore?!0:i>=r?super.write(e):super.write(e.slice(0,i))}[hD](e,r){for(let i in e)e[i]!==null&&e[i]!==void 0&&!(r&&i==="path")&&(this[i]=e[i])}}});var H9=E(pD=>{"use strict";var dlt=pD.encode=(t,e)=>{if(Number.isSafeInteger(t))t<0?rNe(t,e):tNe(t,e);else throw Error("cannot encode number outside of javascript safe integer range");return e},tNe=(t,e)=>{e[0]=128;for(var r=e.length;r>1;r--)e[r-1]=t&255,t=Math.floor(t/256)},rNe=(t,e)=>{e[0]=255;var r=!1;t=t*-1;for(var i=e.length;i>1;i--){var n=t&255;t=Math.floor(t/256),r?e[i-1]=K9(n):n===0?e[i-1]=0:(r=!0,e[i-1]=U9(n))}},Clt=pD.parse=t=>{var e=t[t.length-1],r=t[0],i;if(r===128)i=nNe(t.slice(1,t.length));else if(r===255)i=iNe(t);else throw Error("invalid base256 encoding");if(!Number.isSafeInteger(i))throw Error("parsed number outside of javascript safe integer range");return i},iNe=t=>{for(var e=t.length,r=0,i=!1,n=e-1;n>-1;n--){var s=t[n],o;i?o=K9(s):s===0?o=s:(i=!0,o=U9(s)),o!==0&&(r-=o*Math.pow(256,e-n-1))}return r},nNe=t=>{for(var e=t.length,r=0,i=e-1;i>-1;i--){var n=t[i];n!==0&&(r+=n*Math.pow(256,e-i-1))}return r},K9=t=>(255^t)&255,U9=t=>(255^t)+1&255});var Cg=E((Elt,G9)=>{"use strict";var dD=rd(),dg=require("path").posix,j9=H9(),CD=Symbol("slurp"),Hn=Symbol("type"),Y9=class{constructor(e,r,i,n){this.cksumValid=!1,this.needPax=!1,this.nullBlock=!1,this.block=null,this.path=null,this.mode=null,this.uid=null,this.gid=null,this.size=null,this.mtime=null,this.cksum=null,this[Hn]="0",this.linkpath=null,this.uname=null,this.gname=null,this.devmaj=0,this.devmin=0,this.atime=null,this.ctime=null,Buffer.isBuffer(e)?this.decode(e,r||0,i,n):e&&this.set(e)}decode(e,r,i,n){if(r||(r=0),!e||!(e.length>=r+512))throw new Error("need 512 bytes for header");if(this.path=fc(e,r,100),this.mode=DA(e,r+100,8),this.uid=DA(e,r+108,8),this.gid=DA(e,r+116,8),this.size=DA(e,r+124,12),this.mtime=mD(e,r+136,12),this.cksum=DA(e,r+148,12),this[CD](i),this[CD](n,!0),this[Hn]=fc(e,r+156,1),this[Hn]===""&&(this[Hn]="0"),this[Hn]==="0"&&this.path.substr(-1)==="/"&&(this[Hn]="5"),this[Hn]==="5"&&(this.size=0),this.linkpath=fc(e,r+157,100),e.slice(r+257,r+265).toString()==="ustar\x0000")if(this.uname=fc(e,r+265,32),this.gname=fc(e,r+297,32),this.devmaj=DA(e,r+329,8),this.devmin=DA(e,r+337,8),e[r+475]!==0){let o=fc(e,r+345,155);this.path=o+"/"+this.path}else{let o=fc(e,r+345,130);o&&(this.path=o+"/"+this.path),this.atime=mD(e,r+476,12),this.ctime=mD(e,r+488,12)}let s=8*32;for(let o=r;o=r+512))throw new Error("need 512 bytes for header");let i=this.ctime||this.atime?130:155,n=sNe(this.path||"",i),s=n[0],o=n[1];this.needPax=n[2],this.needPax=hc(e,r,100,s)||this.needPax,this.needPax=RA(e,r+100,8,this.mode)||this.needPax,this.needPax=RA(e,r+108,8,this.uid)||this.needPax,this.needPax=RA(e,r+116,8,this.gid)||this.needPax,this.needPax=RA(e,r+124,12,this.size)||this.needPax,this.needPax=ED(e,r+136,12,this.mtime)||this.needPax,e[r+156]=this[Hn].charCodeAt(0),this.needPax=hc(e,r+157,100,this.linkpath)||this.needPax,e.write("ustar\x0000",r+257,8),this.needPax=hc(e,r+265,32,this.uname)||this.needPax,this.needPax=hc(e,r+297,32,this.gname)||this.needPax,this.needPax=RA(e,r+329,8,this.devmaj)||this.needPax,this.needPax=RA(e,r+337,8,this.devmin)||this.needPax,this.needPax=hc(e,r+345,i,o)||this.needPax,e[r+475]!==0?this.needPax=hc(e,r+345,155,o)||this.needPax:(this.needPax=hc(e,r+345,130,o)||this.needPax,this.needPax=ED(e,r+476,12,this.atime)||this.needPax,this.needPax=ED(e,r+488,12,this.ctime)||this.needPax);let a=8*32;for(let l=r;l{let r=100,i=t,n="",s,o=dg.parse(t).root||".";if(Buffer.byteLength(i)r&&Buffer.byteLength(n)<=e?s=[i.substr(0,r-1),n,!0]:(i=dg.join(dg.basename(n),i),n=dg.dirname(n));while(n!==o&&!s);s||(s=[t.substr(0,r-1),"",!0])}return s},fc=(t,e,r)=>t.slice(e,e+r).toString("utf8").replace(/\0.*/,""),mD=(t,e,r)=>oNe(DA(t,e,r)),oNe=t=>t===null?null:new Date(t*1e3),DA=(t,e,r)=>t[e]&128?j9.parse(t.slice(e,e+r)):aNe(t,e,r),ANe=t=>isNaN(t)?null:t,aNe=(t,e,r)=>ANe(parseInt(t.slice(e,e+r).toString("utf8").replace(/\0.*$/,"").trim(),8)),lNe={12:8589934591,8:2097151},RA=(t,e,r,i)=>i===null?!1:i>lNe[r]||i<0?(j9.encode(i,t.slice(e,e+r)),!0):(cNe(t,e,r,i),!1),cNe=(t,e,r,i)=>t.write(uNe(i,r),e,r,"ascii"),uNe=(t,e)=>gNe(Math.floor(t).toString(8),e),gNe=(t,e)=>(t.length===e-1?t:new Array(e-t.length-1).join("0")+t+" ")+"\0",ED=(t,e,r,i)=>i===null?!1:RA(t,e,r,i.getTime()/1e3),fNe=new Array(156).join("\0"),hc=(t,e,r,i)=>i===null?!1:(t.write(i+fNe,e,r,"utf8"),i.length!==Buffer.byteLength(i)||i.length>r);G9.exports=Y9});var zw=E((Ilt,q9)=>{"use strict";var hNe=Cg(),pNe=require("path"),Ww=class{constructor(e,r){this.atime=e.atime||null,this.charset=e.charset||null,this.comment=e.comment||null,this.ctime=e.ctime||null,this.gid=e.gid||null,this.gname=e.gname||null,this.linkpath=e.linkpath||null,this.mtime=e.mtime||null,this.path=e.path||null,this.size=e.size||null,this.uid=e.uid||null,this.uname=e.uname||null,this.dev=e.dev||null,this.ino=e.ino||null,this.nlink=e.nlink||null,this.global=r||!1}encode(){let e=this.encodeBody();if(e==="")return null;let r=Buffer.byteLength(e),i=512*Math.ceil(1+r/512),n=Buffer.allocUnsafe(i);for(let s=0;s<512;s++)n[s]=0;new hNe({path:("PaxHeader/"+pNe.basename(this.path)).slice(0,99),mode:this.mode||420,uid:this.uid||null,gid:this.gid||null,size:r,mtime:this.mtime||null,type:this.global?"GlobalExtendedHeader":"ExtendedHeader",linkpath:"",uname:this.uname||"",gname:this.gname||"",devmaj:0,devmin:0,atime:this.atime||null,ctime:this.ctime||null}).encode(n),n.write(e,512,r,"utf8");for(let s=r+512;s=Math.pow(10,s)&&(s+=1),s+n+i}};Ww.parse=(t,e,r)=>new Ww(dNe(CNe(t),e),r);var dNe=(t,e)=>e?Object.keys(t).reduce((r,i)=>(r[i]=t[i],r),e):t,CNe=t=>t.replace(/\n$/,"").split(` +`).reduce(mNe,Object.create(null)),mNe=(t,e)=>{let r=parseInt(e,10);if(r!==Buffer.byteLength(e)+1)return t;e=e.substr((r+" ").length);let i=e.split("="),n=i.shift().replace(/^SCHILY\.(dev|ino|nlink)/,"$1");if(!n)return t;let s=i.join("=");return t[n]=/^([A-Z]+\.)?([mac]|birth|creation)time$/.test(n)?new Date(s*1e3):/^[0-9]+$/.test(s)?+s:s,t};q9.exports=Ww});var Vw=E((ylt,J9)=>{"use strict";J9.exports=t=>class extends t{warn(e,r,i={}){this.file&&(i.file=this.file),this.cwd&&(i.cwd=this.cwd),i.code=r instanceof Error&&r.code||e,i.tarCode=e,!this.strict&&i.recoverable!==!1?(r instanceof Error&&(i=Object.assign(r,i),r=r.message),this.emit("warn",i.tarCode,r,i)):r instanceof Error?this.emit("error",Object.assign(r,i)):this.emit("error",Object.assign(new Error(`${e}: ${r}`),i))}}});var yD=E((wlt,W9)=>{"use strict";var _w=["|","<",">","?",":"],ID=_w.map(t=>String.fromCharCode(61440+t.charCodeAt(0))),ENe=new Map(_w.map((t,e)=>[t,ID[e]])),INe=new Map(ID.map((t,e)=>[t,_w[e]]));W9.exports={encode:t=>_w.reduce((e,r)=>e.split(r).join(ENe.get(r)),t),decode:t=>ID.reduce((e,r)=>e.split(r).join(INe.get(r)),t)}});var V9=E((Blt,z9)=>{"use strict";z9.exports=(t,e,r)=>(t&=4095,r&&(t=(t|384)&~18),e&&(t&256&&(t|=64),t&32&&(t|=8),t&4&&(t|=1)),t)});var xD=E((xlt,_9)=>{"use strict";var X9=hg(),Z9=zw(),$9=Cg(),Qlt=id(),bo=require("fs"),mg=require("path"),blt=rd(),yNe=16*1024*1024,eV=Symbol("process"),tV=Symbol("file"),rV=Symbol("directory"),wD=Symbol("symlink"),iV=Symbol("hardlink"),nd=Symbol("header"),Xw=Symbol("read"),BD=Symbol("lstat"),Zw=Symbol("onlstat"),QD=Symbol("onread"),bD=Symbol("onreadlink"),vD=Symbol("openfile"),SD=Symbol("onopenfile"),pc=Symbol("close"),$w=Symbol("mode"),nV=Vw(),wNe=yD(),sV=V9(),eB=nV(class extends X9{constructor(e,r){if(r=r||{},super(r),typeof e!="string")throw new TypeError("path is required");this.path=e,this.portable=!!r.portable,this.myuid=process.getuid&&process.getuid(),this.myuser=process.env.USER||"",this.maxReadSize=r.maxReadSize||yNe,this.linkCache=r.linkCache||new Map,this.statCache=r.statCache||new Map,this.preservePaths=!!r.preservePaths,this.cwd=r.cwd||process.cwd(),this.strict=!!r.strict,this.noPax=!!r.noPax,this.noMtime=!!r.noMtime,this.mtime=r.mtime||null,typeof r.onwarn=="function"&&this.on("warn",r.onwarn);let i=!1;if(!this.preservePaths&&mg.win32.isAbsolute(e)){let n=mg.win32.parse(e);this.path=e.substr(n.root.length),i=n.root}this.win32=!!r.win32||process.platform==="win32",this.win32&&(this.path=wNe.decode(this.path.replace(/\\/g,"/")),e=e.replace(/\\/g,"/")),this.absolute=r.absolute||mg.resolve(this.cwd,e),this.path===""&&(this.path="./"),i&&this.warn("TAR_ENTRY_INFO",`stripping ${i} from absolute path`,{entry:this,path:i+this.path}),this.statCache.has(this.absolute)?this[Zw](this.statCache.get(this.absolute)):this[BD]()}[BD](){bo.lstat(this.absolute,(e,r)=>{if(e)return this.emit("error",e);this[Zw](r)})}[Zw](e){this.statCache.set(this.absolute,e),this.stat=e,e.isFile()||(e.size=0),this.type=BNe(e),this.emit("stat",e),this[eV]()}[eV](){switch(this.type){case"File":return this[tV]();case"Directory":return this[rV]();case"SymbolicLink":return this[wD]();default:return this.end()}}[$w](e){return sV(e,this.type==="Directory",this.portable)}[nd](){this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.header=new $9({path:this.path,linkpath:this.linkpath,mode:this[$w](this.stat.mode),uid:this.portable?null:this.stat.uid,gid:this.portable?null:this.stat.gid,size:this.stat.size,mtime:this.noMtime?null:this.mtime||this.stat.mtime,type:this.type,uname:this.portable?null:this.stat.uid===this.myuid?this.myuser:"",atime:this.portable?null:this.stat.atime,ctime:this.portable?null:this.stat.ctime}),this.header.encode()&&!this.noPax&&this.write(new Z9({atime:this.portable?null:this.header.atime,ctime:this.portable?null:this.header.ctime,gid:this.portable?null:this.header.gid,mtime:this.noMtime?null:this.mtime||this.header.mtime,path:this.path,linkpath:this.linkpath,size:this.header.size,uid:this.portable?null:this.header.uid,uname:this.portable?null:this.header.uname,dev:this.portable?null:this.stat.dev,ino:this.portable?null:this.stat.ino,nlink:this.portable?null:this.stat.nlink}).encode()),this.write(this.header.block)}[rV](){this.path.substr(-1)!=="/"&&(this.path+="/"),this.stat.size=0,this[nd](),this.end()}[wD](){bo.readlink(this.absolute,(e,r)=>{if(e)return this.emit("error",e);this[bD](r)})}[bD](e){this.linkpath=e.replace(/\\/g,"/"),this[nd](),this.end()}[iV](e){this.type="Link",this.linkpath=mg.relative(this.cwd,e).replace(/\\/g,"/"),this.stat.size=0,this[nd](),this.end()}[tV](){if(this.stat.nlink>1){let e=this.stat.dev+":"+this.stat.ino;if(this.linkCache.has(e)){let r=this.linkCache.get(e);if(r.indexOf(this.cwd)===0)return this[iV](r)}this.linkCache.set(e,this.absolute)}if(this[nd](),this.stat.size===0)return this.end();this[vD]()}[vD](){bo.open(this.absolute,"r",(e,r)=>{if(e)return this.emit("error",e);this[SD](r)})}[SD](e){let r=512*Math.ceil(this.stat.size/512),i=Math.min(r,this.maxReadSize),n=Buffer.allocUnsafe(i);this[Xw](e,n,0,n.length,0,this.stat.size,r)}[Xw](e,r,i,n,s,o,a){bo.read(e,r,i,n,s,(l,c)=>{if(l)return this[pc](e,()=>this.emit("error",l));this[QD](e,r,i,n,s,o,a,c)})}[pc](e,r){bo.close(e,r)}[QD](e,r,i,n,s,o,a,l){if(l<=0&&o>0){let u=new Error("encountered unexpected EOF");return u.path=this.absolute,u.syscall="read",u.code="EOF",this[pc](e,()=>this.emit("error",u))}if(l>o){let u=new Error("did not encounter expected EOF");return u.path=this.absolute,u.syscall="read",u.code="EOF",this[pc](e,()=>this.emit("error",u))}if(l===o)for(let u=l;uu?this.emit("error",u):this.end());i>=n&&(r=Buffer.allocUnsafe(n),i=0),n=r.length-i,this[Xw](e,r,i,n,s,o,a)}}),oV=class extends eB{constructor(e,r){super(e,r)}[BD](){this[Zw](bo.lstatSync(this.absolute))}[wD](){this[bD](bo.readlinkSync(this.absolute))}[vD](){this[SD](bo.openSync(this.absolute,"r"))}[Xw](e,r,i,n,s,o,a){let l=!0;try{let c=bo.readSync(e,r,i,n,s);this[QD](e,r,i,n,s,o,a,c),l=!1}finally{if(l)try{this[pc](e,()=>{})}catch(c){}}}[pc](e,r){bo.closeSync(e),r()}},QNe=nV(class extends X9{constructor(e,r){r=r||{},super(r),this.preservePaths=!!r.preservePaths,this.portable=!!r.portable,this.strict=!!r.strict,this.noPax=!!r.noPax,this.noMtime=!!r.noMtime,this.readEntry=e,this.type=e.type,this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.path=e.path,this.mode=this[$w](e.mode),this.uid=this.portable?null:e.uid,this.gid=this.portable?null:e.gid,this.uname=this.portable?null:e.uname,this.gname=this.portable?null:e.gname,this.size=e.size,this.mtime=this.noMtime?null:r.mtime||e.mtime,this.atime=this.portable?null:e.atime,this.ctime=this.portable?null:e.ctime,this.linkpath=e.linkpath,typeof r.onwarn=="function"&&this.on("warn",r.onwarn);let i=!1;if(mg.isAbsolute(this.path)&&!this.preservePaths){let n=mg.parse(this.path);i=n.root,this.path=this.path.substr(n.root.length)}this.remain=e.size,this.blockRemain=e.startBlockSize,this.header=new $9({path:this.path,linkpath:this.linkpath,mode:this.mode,uid:this.portable?null:this.uid,gid:this.portable?null:this.gid,size:this.size,mtime:this.noMtime?null:this.mtime,type:this.type,uname:this.portable?null:this.uname,atime:this.portable?null:this.atime,ctime:this.portable?null:this.ctime}),i&&this.warn("TAR_ENTRY_INFO",`stripping ${i} from absolute path`,{entry:this,path:i+this.path}),this.header.encode()&&!this.noPax&&super.write(new Z9({atime:this.portable?null:this.atime,ctime:this.portable?null:this.ctime,gid:this.portable?null:this.gid,mtime:this.noMtime?null:this.mtime,path:this.path,linkpath:this.linkpath,size:this.size,uid:this.portable?null:this.uid,uname:this.portable?null:this.uname,dev:this.portable?null:this.readEntry.dev,ino:this.portable?null:this.readEntry.ino,nlink:this.portable?null:this.readEntry.nlink}).encode()),super.write(this.header.block),e.pipe(this)}[$w](e){return sV(e,this.type==="Directory",this.portable)}write(e){let r=e.length;if(r>this.blockRemain)throw new Error("writing more to entry than is appropriate");return this.blockRemain-=r,super.write(e)}end(){return this.blockRemain&&this.write(Buffer.alloc(this.blockRemain)),super.end()}});eB.Sync=oV;eB.Tar=QNe;var BNe=t=>t.isFile()?"File":t.isDirectory()?"Directory":t.isSymbolicLink()?"SymbolicLink":"Unsupported";_9.exports=eB});var AB=E((Plt,aV)=>{"use strict";var kD=class{constructor(e,r){this.path=e||"./",this.absolute=r,this.entry=null,this.stat=null,this.readdir=null,this.pending=!1,this.ignore=!1,this.piped=!1}},bNe=hg(),vNe=fD(),SNe=id(),PD=xD(),xNe=PD.Sync,kNe=PD.Tar,PNe=Rh(),AV=Buffer.alloc(1024),tB=Symbol("onStat"),rB=Symbol("ended"),vo=Symbol("queue"),Eg=Symbol("current"),dc=Symbol("process"),iB=Symbol("processing"),lV=Symbol("processJob"),So=Symbol("jobs"),DD=Symbol("jobDone"),nB=Symbol("addFSEntry"),cV=Symbol("addTarEntry"),RD=Symbol("stat"),FD=Symbol("readdir"),sB=Symbol("onreaddir"),oB=Symbol("pipe"),uV=Symbol("entry"),ND=Symbol("entryOpt"),LD=Symbol("writeEntryClass"),gV=Symbol("write"),TD=Symbol("ondrain"),aB=require("fs"),fV=require("path"),DNe=Vw(),MD=DNe(class extends bNe{constructor(e){super(e);e=e||Object.create(null),this.opt=e,this.file=e.file||"",this.cwd=e.cwd||process.cwd(),this.maxReadSize=e.maxReadSize,this.preservePaths=!!e.preservePaths,this.strict=!!e.strict,this.noPax=!!e.noPax,this.prefix=(e.prefix||"").replace(/(\\|\/)+$/,""),this.linkCache=e.linkCache||new Map,this.statCache=e.statCache||new Map,this.readdirCache=e.readdirCache||new Map,this[LD]=PD,typeof e.onwarn=="function"&&this.on("warn",e.onwarn),this.portable=!!e.portable,this.zip=null,e.gzip?(typeof e.gzip!="object"&&(e.gzip={}),this.portable&&(e.gzip.portable=!0),this.zip=new vNe.Gzip(e.gzip),this.zip.on("data",r=>super.write(r)),this.zip.on("end",r=>super.end()),this.zip.on("drain",r=>this[TD]()),this.on("resume",r=>this.zip.resume())):this.on("drain",this[TD]),this.noDirRecurse=!!e.noDirRecurse,this.follow=!!e.follow,this.noMtime=!!e.noMtime,this.mtime=e.mtime||null,this.filter=typeof e.filter=="function"?e.filter:r=>!0,this[vo]=new PNe,this[So]=0,this.jobs=+e.jobs||4,this[iB]=!1,this[rB]=!1}[gV](e){return super.write(e)}add(e){return this.write(e),this}end(e){return e&&this.write(e),this[rB]=!0,this[dc](),this}write(e){if(this[rB])throw new Error("write after end");return e instanceof SNe?this[cV](e):this[nB](e),this.flowing}[cV](e){let r=fV.resolve(this.cwd,e.path);if(this.prefix&&(e.path=this.prefix+"/"+e.path.replace(/^\.(\/+|$)/,"")),!this.filter(e.path,e))e.resume();else{let i=new kD(e.path,r,!1);i.entry=new kNe(e,this[ND](i)),i.entry.on("end",n=>this[DD](i)),this[So]+=1,this[vo].push(i)}this[dc]()}[nB](e){let r=fV.resolve(this.cwd,e);this.prefix&&(e=this.prefix+"/"+e.replace(/^\.(\/+|$)/,"")),this[vo].push(new kD(e,r)),this[dc]()}[RD](e){e.pending=!0,this[So]+=1;let r=this.follow?"stat":"lstat";aB[r](e.absolute,(i,n)=>{e.pending=!1,this[So]-=1,i?this.emit("error",i):this[tB](e,n)})}[tB](e,r){this.statCache.set(e.absolute,r),e.stat=r,this.filter(e.path,r)||(e.ignore=!0),this[dc]()}[FD](e){e.pending=!0,this[So]+=1,aB.readdir(e.absolute,(r,i)=>{if(e.pending=!1,this[So]-=1,r)return this.emit("error",r);this[sB](e,i)})}[sB](e,r){this.readdirCache.set(e.absolute,r),e.readdir=r,this[dc]()}[dc](){if(!this[iB]){this[iB]=!0;for(let e=this[vo].head;e!==null&&this[So]this.warn(r,i,n),noPax:this.noPax,cwd:this.cwd,absolute:e.absolute,preservePaths:this.preservePaths,maxReadSize:this.maxReadSize,strict:this.strict,portable:this.portable,linkCache:this.linkCache,statCache:this.statCache,noMtime:this.noMtime,mtime:this.mtime}}[uV](e){this[So]+=1;try{return new this[LD](e.path,this[ND](e)).on("end",()=>this[DD](e)).on("error",r=>this.emit("error",r))}catch(r){this.emit("error",r)}}[TD](){this[Eg]&&this[Eg].entry&&this[Eg].entry.resume()}[oB](e){e.piped=!0,e.readdir&&e.readdir.forEach(n=>{let s=this.prefix?e.path.slice(this.prefix.length+1)||"./":e.path,o=s==="./"?"":s.replace(/\/*$/,"/");this[nB](o+n)});let r=e.entry,i=this.zip;i?r.on("data",n=>{i.write(n)||r.pause()}):r.on("data",n=>{super.write(n)||r.pause()})}pause(){return this.zip&&this.zip.pause(),super.pause()}}),hV=class extends MD{constructor(e){super(e);this[LD]=xNe}pause(){}resume(){}[RD](e){let r=this.follow?"statSync":"lstatSync";this[tB](e,aB[r](e.absolute))}[FD](e,r){this[sB](e,aB.readdirSync(e.absolute))}[oB](e){let r=e.entry,i=this.zip;e.readdir&&e.readdir.forEach(n=>{let s=this.prefix?e.path.slice(this.prefix.length+1)||"./":e.path,o=s==="./"?"":s.replace(/\/*$/,"/");this[nB](o+n)}),i?r.on("data",n=>{i.write(n)}):r.on("data",n=>{super[gV](n)})}};MD.Sync=hV;aV.exports=MD});var bg=E(sd=>{"use strict";var RNe=hg(),FNe=require("events").EventEmitter,ls=require("fs"),lB=process.binding("fs"),Dlt=lB.writeBuffers,NNe=lB.FSReqWrap||lB.FSReqCallback,Ig=Symbol("_autoClose"),xo=Symbol("_close"),od=Symbol("_ended"),Jt=Symbol("_fd"),pV=Symbol("_finished"),Cc=Symbol("_flags"),OD=Symbol("_flush"),KD=Symbol("_handleChunk"),UD=Symbol("_makeBuf"),HD=Symbol("_mode"),cB=Symbol("_needDrain"),yg=Symbol("_onerror"),wg=Symbol("_onopen"),GD=Symbol("_onread"),mc=Symbol("_onwrite"),FA=Symbol("_open"),NA=Symbol("_path"),Ec=Symbol("_pos"),ko=Symbol("_queue"),Bg=Symbol("_read"),dV=Symbol("_readSize"),LA=Symbol("_reading"),uB=Symbol("_remain"),CV=Symbol("_size"),gB=Symbol("_write"),Qg=Symbol("_writing"),fB=Symbol("_defaultFlag"),jD=class extends RNe{constructor(e,r){if(r=r||{},super(r),this.writable=!1,typeof e!="string")throw new TypeError("path must be a string");this[Jt]=typeof r.fd=="number"?r.fd:null,this[NA]=e,this[dV]=r.readSize||16*1024*1024,this[LA]=!1,this[CV]=typeof r.size=="number"?r.size:Infinity,this[uB]=this[CV],this[Ig]=typeof r.autoClose=="boolean"?r.autoClose:!0,typeof this[Jt]=="number"?this[Bg]():this[FA]()}get fd(){return this[Jt]}get path(){return this[NA]}write(){throw new TypeError("this is a readable stream")}end(){throw new TypeError("this is a readable stream")}[FA](){ls.open(this[NA],"r",(e,r)=>this[wg](e,r))}[wg](e,r){e?this[yg](e):(this[Jt]=r,this.emit("open",r),this[Bg]())}[UD](){return Buffer.allocUnsafe(Math.min(this[dV],this[uB]))}[Bg](){if(!this[LA]){this[LA]=!0;let e=this[UD]();if(e.length===0)return process.nextTick(()=>this[GD](null,0,e));ls.read(this[Jt],e,0,e.length,null,(r,i,n)=>this[GD](r,i,n))}}[GD](e,r,i){this[LA]=!1,e?this[yg](e):this[KD](r,i)&&this[Bg]()}[xo](){this[Ig]&&typeof this[Jt]=="number"&&(ls.close(this[Jt],e=>this.emit("close")),this[Jt]=null)}[yg](e){this[LA]=!0,this[xo](),this.emit("error",e)}[KD](e,r){let i=!1;return this[uB]-=e,e>0&&(i=super.write(ethis[wg](e,r))}[wg](e,r){this[fB]&&this[Cc]==="r+"&&e&&e.code==="ENOENT"?(this[Cc]="w",this[FA]()):e?this[yg](e):(this[Jt]=r,this.emit("open",r),this[OD]())}end(e,r){e&&this.write(e,r),this[od]=!0,!this[Qg]&&!this[ko].length&&typeof this[Jt]=="number"&&this[mc](null,0)}write(e,r){return typeof e=="string"&&(e=new Buffer(e,r)),this[od]?(this.emit("error",new Error("write() after end()")),!1):this[Jt]===null||this[Qg]||this[ko].length?(this[ko].push(e),this[cB]=!0,!1):(this[Qg]=!0,this[gB](e),!0)}[gB](e){ls.write(this[Jt],e,0,e.length,this[Ec],(r,i)=>this[mc](r,i))}[mc](e,r){e?this[yg](e):(this[Ec]!==null&&(this[Ec]+=r),this[ko].length?this[OD]():(this[Qg]=!1,this[od]&&!this[pV]?(this[pV]=!0,this[xo](),this.emit("finish")):this[cB]&&(this[cB]=!1,this.emit("drain"))))}[OD](){if(this[ko].length===0)this[od]&&this[mc](null,0);else if(this[ko].length===1)this[gB](this[ko].pop());else{let e=this[ko];this[ko]=[],LNe(this[Jt],e,this[Ec],(r,i)=>this[mc](r,i))}}[xo](){this[Ig]&&typeof this[Jt]=="number"&&(ls.close(this[Jt],e=>this.emit("close")),this[Jt]=null)}},EV=class extends YD{[FA](){let e;try{e=ls.openSync(this[NA],this[Cc],this[HD])}catch(r){if(this[fB]&&this[Cc]==="r+"&&r&&r.code==="ENOENT")return this[Cc]="w",this[FA]();throw r}this[wg](null,e)}[xo](){if(this[Ig]&&typeof this[Jt]=="number"){try{ls.closeSync(this[Jt])}catch(e){}this[Jt]=null,this.emit("close")}}[gB](e){try{this[mc](null,ls.writeSync(this[Jt],e,0,e.length,this[Ec]))}catch(r){this[mc](r,0)}}},LNe=(t,e,r,i)=>{let n=(o,a)=>i(o,a,e),s=new NNe;s.oncomplete=n,lB.writeBuffers(t,e,r,s)};sd.ReadStream=jD;sd.ReadStreamSync=mV;sd.WriteStream=YD;sd.WriteStreamSync=EV});var ld=E((Llt,IV)=>{"use strict";var TNe=Vw(),Flt=require("path"),MNe=Cg(),ONe=require("events"),KNe=Rh(),UNe=1024*1024,HNe=id(),yV=zw(),GNe=fD(),qD=Buffer.from([31,139]),cs=Symbol("state"),Ic=Symbol("writeEntry"),xa=Symbol("readEntry"),JD=Symbol("nextEntry"),wV=Symbol("processEntry"),us=Symbol("extendedHeader"),ad=Symbol("globalExtendedHeader"),TA=Symbol("meta"),BV=Symbol("emitMeta"),Ar=Symbol("buffer"),ka=Symbol("queue"),yc=Symbol("ended"),QV=Symbol("emittedEnd"),wc=Symbol("emit"),Qn=Symbol("unzip"),hB=Symbol("consumeChunk"),pB=Symbol("consumeChunkSub"),WD=Symbol("consumeBody"),bV=Symbol("consumeMeta"),vV=Symbol("consumeHeader"),dB=Symbol("consuming"),zD=Symbol("bufferConcat"),VD=Symbol("maybeEnd"),Ad=Symbol("writing"),MA=Symbol("aborted"),CB=Symbol("onDone"),Bc=Symbol("sawValidEntry"),mB=Symbol("sawNullBlock"),EB=Symbol("sawEOF"),jNe=t=>!0;IV.exports=TNe(class extends ONe{constructor(e){e=e||{},super(e),this.file=e.file||"",this[Bc]=null,this.on(CB,r=>{(this[cs]==="begin"||this[Bc]===!1)&&this.warn("TAR_BAD_ARCHIVE","Unrecognized archive format")}),e.ondone?this.on(CB,e.ondone):this.on(CB,r=>{this.emit("prefinish"),this.emit("finish"),this.emit("end"),this.emit("close")}),this.strict=!!e.strict,this.maxMetaEntrySize=e.maxMetaEntrySize||UNe,this.filter=typeof e.filter=="function"?e.filter:jNe,this.writable=!0,this.readable=!1,this[ka]=new KNe,this[Ar]=null,this[xa]=null,this[Ic]=null,this[cs]="begin",this[TA]="",this[us]=null,this[ad]=null,this[yc]=!1,this[Qn]=null,this[MA]=!1,this[mB]=!1,this[EB]=!1,typeof e.onwarn=="function"&&this.on("warn",e.onwarn),typeof e.onentry=="function"&&this.on("entry",e.onentry)}[vV](e,r){this[Bc]===null&&(this[Bc]=!1);let i;try{i=new MNe(e,r,this[us],this[ad])}catch(n){return this.warn("TAR_ENTRY_INVALID",n)}if(i.nullBlock)this[mB]?(this[EB]=!0,this[cs]==="begin"&&(this[cs]="header"),this[wc]("eof")):(this[mB]=!0,this[wc]("nullBlock"));else if(this[mB]=!1,!i.cksumValid)this.warn("TAR_ENTRY_INVALID","checksum failure",{header:i});else if(!i.path)this.warn("TAR_ENTRY_INVALID","path is required",{header:i});else{let n=i.type;if(/^(Symbolic)?Link$/.test(n)&&!i.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath required",{header:i});else if(!/^(Symbolic)?Link$/.test(n)&&i.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath forbidden",{header:i});else{let s=this[Ic]=new HNe(i,this[us],this[ad]);if(!this[Bc])if(s.remain){let o=()=>{s.invalid||(this[Bc]=!0)};s.on("end",o)}else this[Bc]=!0;s.meta?s.size>this.maxMetaEntrySize?(s.ignore=!0,this[wc]("ignoredEntry",s),this[cs]="ignore",s.resume()):s.size>0&&(this[TA]="",s.on("data",o=>this[TA]+=o),this[cs]="meta"):(this[us]=null,s.ignore=s.ignore||!this.filter(s.path,s),s.ignore?(this[wc]("ignoredEntry",s),this[cs]=s.remain?"ignore":"header",s.resume()):(s.remain?this[cs]="body":(this[cs]="header",s.end()),this[xa]?this[ka].push(s):(this[ka].push(s),this[JD]())))}}}[wV](e){let r=!0;return e?Array.isArray(e)?this.emit.apply(this,e):(this[xa]=e,this.emit("entry",e),e.emittedEnd||(e.on("end",i=>this[JD]()),r=!1)):(this[xa]=null,r=!1),r}[JD](){do;while(this[wV](this[ka].shift()));if(!this[ka].length){let e=this[xa];!e||e.flowing||e.size===e.remain?this[Ad]||this.emit("drain"):e.once("drain",i=>this.emit("drain"))}}[WD](e,r){let i=this[Ic],n=i.blockRemain,s=n>=e.length&&r===0?e:e.slice(r,r+n);return i.write(s),i.blockRemain||(this[cs]="header",this[Ic]=null,i.end()),s.length}[bV](e,r){let i=this[Ic],n=this[WD](e,r);return this[Ic]||this[BV](i),n}[wc](e,r,i){!this[ka].length&&!this[xa]?this.emit(e,r,i):this[ka].push([e,r,i])}[BV](e){switch(this[wc]("meta",this[TA]),e.type){case"ExtendedHeader":case"OldExtendedHeader":this[us]=yV.parse(this[TA],this[us],!1);break;case"GlobalExtendedHeader":this[ad]=yV.parse(this[TA],this[ad],!0);break;case"NextFileHasLongPath":case"OldGnuLongPath":this[us]=this[us]||Object.create(null),this[us].path=this[TA].replace(/\0.*/,"");break;case"NextFileHasLongLinkpath":this[us]=this[us]||Object.create(null),this[us].linkpath=this[TA].replace(/\0.*/,"");break;default:throw new Error("unknown meta: "+e.type)}}abort(e){this[MA]=!0,this.emit("abort",e),this.warn("TAR_ABORT",e,{recoverable:!1})}write(e){if(this[MA])return;if(this[Qn]===null&&e){if(this[Ar]&&(e=Buffer.concat([this[Ar],e]),this[Ar]=null),e.lengththis[hB](s)),this[Qn].on("error",s=>this.abort(s)),this[Qn].on("end",s=>{this[yc]=!0,this[hB]()}),this[Ad]=!0;let n=this[Qn][i?"end":"write"](e);return this[Ad]=!1,n}}this[Ad]=!0,this[Qn]?this[Qn].write(e):this[hB](e),this[Ad]=!1;let r=this[ka].length?!1:this[xa]?this[xa].flowing:!0;return!r&&!this[ka].length&&this[xa].once("drain",i=>this.emit("drain")),r}[zD](e){e&&!this[MA]&&(this[Ar]=this[Ar]?Buffer.concat([this[Ar],e]):e)}[VD](){if(this[yc]&&!this[QV]&&!this[MA]&&!this[dB]){this[QV]=!0;let e=this[Ic];if(e&&e.blockRemain){let r=this[Ar]?this[Ar].length:0;this.warn("TAR_BAD_ARCHIVE",`Truncated input (needed ${e.blockRemain} more bytes, only ${r} available)`,{entry:e}),this[Ar]&&e.write(this[Ar]),e.end()}this[wc](CB)}}[hB](e){if(this[dB])this[zD](e);else if(!e&&!this[Ar])this[VD]();else{if(this[dB]=!0,this[Ar]){this[zD](e);let r=this[Ar];this[Ar]=null,this[pB](r)}else this[pB](e);for(;this[Ar]&&this[Ar].length>=512&&!this[MA]&&!this[EB];){let r=this[Ar];this[Ar]=null,this[pB](r)}this[dB]=!1}(!this[Ar]||this[yc])&&this[VD]()}[pB](e){let r=0,i=e.length;for(;r+512<=i&&!this[MA]&&!this[EB];)switch(this[cs]){case"begin":case"header":this[vV](e,r),r+=512;break;case"ignore":case"body":r+=this[WD](e,r);break;case"meta":r+=this[bV](e,r);break;default:throw new Error("invalid state: "+this[cs])}r{"use strict";var YNe=fg(),xV=ld(),vg=require("fs"),qNe=bg(),kV=require("path"),Tlt=SV.exports=(t,e,r)=>{typeof t=="function"?(r=t,e=null,t={}):Array.isArray(t)&&(e=t,t={}),typeof e=="function"&&(r=e,e=null),e?e=Array.from(e):e=[];let i=YNe(t);if(i.sync&&typeof r=="function")throw new TypeError("callback not supported for sync tar functions");if(!i.file&&typeof r=="function")throw new TypeError("callback only supported with file option");return e.length&&WNe(i,e),i.noResume||JNe(i),i.file&&i.sync?zNe(i):i.file?VNe(i,r):PV(i)},JNe=t=>{let e=t.onentry;t.onentry=e?r=>{e(r),r.resume()}:r=>r.resume()},WNe=(t,e)=>{let r=new Map(e.map(s=>[s.replace(/\/+$/,""),!0])),i=t.filter,n=(s,o)=>{let a=o||kV.parse(s).root||".",l=s===a?!1:r.has(s)?r.get(s):n(kV.dirname(s),a);return r.set(s,l),l};t.filter=i?(s,o)=>i(s,o)&&n(s.replace(/\/+$/,"")):s=>n(s.replace(/\/+$/,""))},zNe=t=>{let e=PV(t),r=t.file,i=!0,n;try{let s=vg.statSync(r),o=t.maxReadSize||16*1024*1024;if(s.size{let r=new xV(t),i=t.maxReadSize||16*1024*1024,n=t.file,s=new Promise((o,a)=>{r.on("error",a),r.on("end",o),vg.stat(n,(l,c)=>{if(l)a(l);else{let u=new qNe.ReadStream(n,{readSize:i,size:c.size});u.on("error",a),u.pipe(r)}})});return e?s.then(e,e):s},PV=t=>new xV(t)});var TV=E((Ult,DV)=>{"use strict";var _Ne=fg(),yB=AB(),Olt=require("fs"),RV=bg(),FV=IB(),NV=require("path"),Klt=DV.exports=(t,e,r)=>{if(typeof e=="function"&&(r=e),Array.isArray(t)&&(e=t,t={}),!e||!Array.isArray(e)||!e.length)throw new TypeError("no files or directories specified");e=Array.from(e);let i=_Ne(t);if(i.sync&&typeof r=="function")throw new TypeError("callback not supported for sync tar functions");if(!i.file&&typeof r=="function")throw new TypeError("callback only supported with file option");return i.file&&i.sync?XNe(i,e):i.file?ZNe(i,e,r):i.sync?$Ne(i,e):eLe(i,e)},XNe=(t,e)=>{let r=new yB.Sync(t),i=new RV.WriteStreamSync(t.file,{mode:t.mode||438});r.pipe(i),LV(r,e)},ZNe=(t,e,r)=>{let i=new yB(t),n=new RV.WriteStream(t.file,{mode:t.mode||438});i.pipe(n);let s=new Promise((o,a)=>{n.on("error",a),n.on("close",o),i.on("error",a)});return _D(i,e),r?s.then(r,r):s},LV=(t,e)=>{e.forEach(r=>{r.charAt(0)==="@"?FV({file:NV.resolve(t.cwd,r.substr(1)),sync:!0,noResume:!0,onentry:i=>t.add(i)}):t.add(r)}),t.end()},_D=(t,e)=>{for(;e.length;){let r=e.shift();if(r.charAt(0)==="@")return FV({file:NV.resolve(t.cwd,r.substr(1)),noResume:!0,onentry:i=>t.add(i)}).then(i=>_D(t,e));t.add(r)}t.end()},$Ne=(t,e)=>{let r=new yB.Sync(t);return LV(r,e),r},eLe=(t,e)=>{let r=new yB(t);return _D(r,e),r}});var XD=E((jlt,MV)=>{"use strict";var tLe=fg(),OV=AB(),Hlt=ld(),gs=require("fs"),KV=bg(),UV=IB(),HV=require("path"),GV=Cg(),Glt=MV.exports=(t,e,r)=>{let i=tLe(t);if(!i.file)throw new TypeError("file is required");if(i.gzip)throw new TypeError("cannot append to compressed archives");if(!e||!Array.isArray(e)||!e.length)throw new TypeError("no files or directories specified");return e=Array.from(e),i.sync?rLe(i,e):iLe(i,e,r)},rLe=(t,e)=>{let r=new OV.Sync(t),i=!0,n,s;try{try{n=gs.openSync(t.file,"r+")}catch(l){if(l.code==="ENOENT")n=gs.openSync(t.file,"w+");else throw l}let o=gs.fstatSync(n),a=Buffer.alloc(512);e:for(s=0;so.size)break;s+=c,t.mtimeCache&&t.mtimeCache.set(l.path,l.mtime)}i=!1,nLe(t,r,s,n,e)}finally{if(i)try{gs.closeSync(n)}catch(o){}}},nLe=(t,e,r,i,n)=>{let s=new KV.WriteStreamSync(t.file,{fd:i,start:r});e.pipe(s),sLe(e,n)},iLe=(t,e,r)=>{e=Array.from(e);let i=new OV(t),n=(o,a,l)=>{let c=(p,d)=>{p?gs.close(o,m=>l(p)):l(null,d)},u=0;if(a===0)return c(null,0);let g=0,f=Buffer.alloc(512),h=(p,d)=>{if(p)return c(p);if(g+=d,g<512&&d)return gs.read(o,f,g,f.length-g,u+g,h);if(u===0&&f[0]===31&&f[1]===139)return c(new Error("cannot append to compressed archives"));if(g<512)return c(null,u);let m=new GV(f);if(!m.cksumValid)return c(null,u);let I=512*Math.ceil(m.size/512);if(u+I+512>a||(u+=I+512,u>=a))return c(null,u);t.mtimeCache&&t.mtimeCache.set(m.path,m.mtime),g=0,gs.read(o,f,0,512,u,h)};gs.read(o,f,0,512,u,h)},s=new Promise((o,a)=>{i.on("error",a);let l="r+",c=(u,g)=>{if(u&&u.code==="ENOENT"&&l==="r+")return l="w+",gs.open(t.file,l,c);if(u)return a(u);gs.fstat(g,(f,h)=>{if(f)return a(f);n(g,h.size,(p,d)=>{if(p)return a(p);let m=new KV.WriteStream(t.file,{fd:g,start:d});i.pipe(m),m.on("error",a),m.on("close",o),jV(i,e)})})};gs.open(t.file,l,c)});return r?s.then(r,r):s},sLe=(t,e)=>{e.forEach(r=>{r.charAt(0)==="@"?UV({file:HV.resolve(t.cwd,r.substr(1)),sync:!0,noResume:!0,onentry:i=>t.add(i)}):t.add(r)}),t.end()},jV=(t,e)=>{for(;e.length;){let r=e.shift();if(r.charAt(0)==="@")return UV({file:HV.resolve(t.cwd,r.substr(1)),noResume:!0,onentry:i=>t.add(i)}).then(i=>jV(t,e));t.add(r)}t.end()}});var qV=E((qlt,YV)=>{"use strict";var oLe=fg(),aLe=XD(),Ylt=YV.exports=(t,e,r)=>{let i=oLe(t);if(!i.file)throw new TypeError("file is required");if(i.gzip)throw new TypeError("cannot append to compressed archives");if(!e||!Array.isArray(e)||!e.length)throw new TypeError("no files or directories specified");return e=Array.from(e),ALe(i),aLe(i,e,r)},ALe=t=>{let e=t.filter;t.mtimeCache||(t.mtimeCache=new Map),t.filter=e?(r,i)=>e(r,i)&&!(t.mtimeCache.get(r)>i.mtime):(r,i)=>!(t.mtimeCache.get(r)>i.mtime)}});var zV=E((Jlt,JV)=>{var{promisify:WV}=require("util"),OA=require("fs"),lLe=t=>{if(!t)t={mode:511,fs:OA};else if(typeof t=="object")t=P({mode:511,fs:OA},t);else if(typeof t=="number")t={mode:t,fs:OA};else if(typeof t=="string")t={mode:parseInt(t,8),fs:OA};else throw new TypeError("invalid options argument");return t.mkdir=t.mkdir||t.fs.mkdir||OA.mkdir,t.mkdirAsync=WV(t.mkdir),t.stat=t.stat||t.fs.stat||OA.stat,t.statAsync=WV(t.stat),t.statSync=t.statSync||t.fs.statSync||OA.statSync,t.mkdirSync=t.mkdirSync||t.fs.mkdirSync||OA.mkdirSync,t};JV.exports=lLe});var _V=E((Wlt,VV)=>{var cLe=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform,{resolve:uLe,parse:gLe}=require("path"),fLe=t=>{if(/\0/.test(t))throw Object.assign(new TypeError("path must be a string without null bytes"),{path:t,code:"ERR_INVALID_ARG_VALUE"});if(t=uLe(t),cLe==="win32"){let e=/[*|"<>?:]/,{root:r}=gLe(t);if(e.test(t.substr(r.length)))throw Object.assign(new Error("Illegal characters in path."),{path:t,code:"EINVAL"})}return t};VV.exports=fLe});var t7=E((zlt,XV)=>{var{dirname:ZV}=require("path"),$V=(t,e,r=void 0)=>r===e?Promise.resolve():t.statAsync(e).then(i=>i.isDirectory()?r:void 0,i=>i.code==="ENOENT"?$V(t,ZV(e),e):void 0),e7=(t,e,r=void 0)=>{if(r!==e)try{return t.statSync(e).isDirectory()?r:void 0}catch(i){return i.code==="ENOENT"?e7(t,ZV(e),e):void 0}};XV.exports={findMade:$V,findMadeSync:e7}});var eR=E((Vlt,r7)=>{var{dirname:i7}=require("path"),ZD=(t,e,r)=>{e.recursive=!1;let i=i7(t);return i===t?e.mkdirAsync(t,e).catch(n=>{if(n.code!=="EISDIR")throw n}):e.mkdirAsync(t,e).then(()=>r||t,n=>{if(n.code==="ENOENT")return ZD(i,e).then(s=>ZD(t,e,s));if(n.code!=="EEXIST"&&n.code!=="EROFS")throw n;return e.statAsync(t).then(s=>{if(s.isDirectory())return r;throw n},()=>{throw n})})},$D=(t,e,r)=>{let i=i7(t);if(e.recursive=!1,i===t)try{return e.mkdirSync(t,e)}catch(n){if(n.code!=="EISDIR")throw n;return}try{return e.mkdirSync(t,e),r||t}catch(n){if(n.code==="ENOENT")return $D(t,e,$D(i,e,r));if(n.code!=="EEXIST"&&n.code!=="EROFS")throw n;try{if(!e.statSync(t).isDirectory())throw n}catch(s){throw n}}};r7.exports={mkdirpManual:ZD,mkdirpManualSync:$D}});var o7=E((_lt,n7)=>{var{dirname:s7}=require("path"),{findMade:hLe,findMadeSync:pLe}=t7(),{mkdirpManual:dLe,mkdirpManualSync:CLe}=eR(),mLe=(t,e)=>(e.recursive=!0,s7(t)===t?e.mkdirAsync(t,e):hLe(e,t).then(i=>e.mkdirAsync(t,e).then(()=>i).catch(n=>{if(n.code==="ENOENT")return dLe(t,e);throw n}))),ELe=(t,e)=>{if(e.recursive=!0,s7(t)===t)return e.mkdirSync(t,e);let i=pLe(e,t);try{return e.mkdirSync(t,e),i}catch(n){if(n.code==="ENOENT")return CLe(t,e);throw n}};n7.exports={mkdirpNative:mLe,mkdirpNativeSync:ELe}});var c7=E((Xlt,a7)=>{var A7=require("fs"),ILe=process.env.__TESTING_MKDIRP_NODE_VERSION__||process.version,tR=ILe.replace(/^v/,"").split("."),l7=+tR[0]>10||+tR[0]==10&&+tR[1]>=12,yLe=l7?t=>t.mkdir===A7.mkdir:()=>!1,wLe=l7?t=>t.mkdirSync===A7.mkdirSync:()=>!1;a7.exports={useNative:yLe,useNativeSync:wLe}});var d7=E((Zlt,u7)=>{var Sg=zV(),xg=_V(),{mkdirpNative:g7,mkdirpNativeSync:f7}=o7(),{mkdirpManual:h7,mkdirpManualSync:p7}=eR(),{useNative:BLe,useNativeSync:QLe}=c7(),kg=(t,e)=>(t=xg(t),e=Sg(e),BLe(e)?g7(t,e):h7(t,e)),bLe=(t,e)=>(t=xg(t),e=Sg(e),QLe(e)?f7(t,e):p7(t,e));kg.sync=bLe;kg.native=(t,e)=>g7(xg(t),Sg(e));kg.manual=(t,e)=>h7(xg(t),Sg(e));kg.nativeSync=(t,e)=>f7(xg(t),Sg(e));kg.manualSync=(t,e)=>p7(xg(t),Sg(e));u7.exports=kg});var B7=E(($lt,C7)=>{"use strict";var fs=require("fs"),Qc=require("path"),vLe=fs.lchown?"lchown":"chown",SLe=fs.lchownSync?"lchownSync":"chownSync",m7=fs.lchown&&!process.version.match(/v1[1-9]+\./)&&!process.version.match(/v10\.[6-9]/),E7=(t,e,r)=>{try{return fs[SLe](t,e,r)}catch(i){if(i.code!=="ENOENT")throw i}},xLe=(t,e,r)=>{try{return fs.chownSync(t,e,r)}catch(i){if(i.code!=="ENOENT")throw i}},kLe=m7?(t,e,r,i)=>n=>{!n||n.code!=="EISDIR"?i(n):fs.chown(t,e,r,i)}:(t,e,r,i)=>i,rR=m7?(t,e,r)=>{try{return E7(t,e,r)}catch(i){if(i.code!=="EISDIR")throw i;xLe(t,e,r)}}:(t,e,r)=>E7(t,e,r),PLe=process.version,I7=(t,e,r)=>fs.readdir(t,e,r),DLe=(t,e)=>fs.readdirSync(t,e);/^v4\./.test(PLe)&&(I7=(t,e,r)=>fs.readdir(t,r));var wB=(t,e,r,i)=>{fs[vLe](t,e,r,kLe(t,e,r,n=>{i(n&&n.code!=="ENOENT"?n:null)}))},y7=(t,e,r,i,n)=>{if(typeof e=="string")return fs.lstat(Qc.resolve(t,e),(s,o)=>{if(s)return n(s.code!=="ENOENT"?s:null);o.name=e,y7(t,o,r,i,n)});if(e.isDirectory())iR(Qc.resolve(t,e.name),r,i,s=>{if(s)return n(s);let o=Qc.resolve(t,e.name);wB(o,r,i,n)});else{let s=Qc.resolve(t,e.name);wB(s,r,i,n)}},iR=(t,e,r,i)=>{I7(t,{withFileTypes:!0},(n,s)=>{if(n){if(n.code==="ENOENT")return i();if(n.code!=="ENOTDIR"&&n.code!=="ENOTSUP")return i(n)}if(n||!s.length)return wB(t,e,r,i);let o=s.length,a=null,l=c=>{if(!a){if(c)return i(a=c);if(--o==0)return wB(t,e,r,i)}};s.forEach(c=>y7(t,c,e,r,l))})},RLe=(t,e,r,i)=>{if(typeof e=="string")try{let n=fs.lstatSync(Qc.resolve(t,e));n.name=e,e=n}catch(n){if(n.code==="ENOENT")return;throw n}e.isDirectory()&&w7(Qc.resolve(t,e.name),r,i),rR(Qc.resolve(t,e.name),r,i)},w7=(t,e,r)=>{let i;try{i=DLe(t,{withFileTypes:!0})}catch(n){if(n.code==="ENOENT")return;if(n.code==="ENOTDIR"||n.code==="ENOTSUP")return rR(t,e,r);throw n}return i&&i.length&&i.forEach(n=>RLe(t,n,e,r)),rR(t,e,r)};C7.exports=iR;iR.sync=w7});var S7=E((rct,nR)=>{"use strict";var Q7=d7(),hs=require("fs"),BB=require("path"),b7=B7(),sR=class extends Error{constructor(e,r){super("Cannot extract through symbolic link");this.path=r,this.symlink=e}get name(){return"SylinkError"}},cd=class extends Error{constructor(e,r){super(r+": Cannot cd into '"+e+"'");this.path=e,this.code=r}get name(){return"CwdError"}},ect=nR.exports=(t,e,r)=>{let i=e.umask,n=e.mode|448,s=(n&i)!=0,o=e.uid,a=e.gid,l=typeof o=="number"&&typeof a=="number"&&(o!==e.processUid||a!==e.processGid),c=e.preserve,u=e.unlink,g=e.cache,f=e.cwd,h=(m,I)=>{m?r(m):(g.set(t,!0),I&&l?b7(I,o,a,B=>h(B)):s?hs.chmod(t,n,r):r())};if(g&&g.get(t)===!0)return h();if(t===f)return hs.stat(t,(m,I)=>{(m||!I.isDirectory())&&(m=new cd(t,m&&m.code||"ENOTDIR")),h(m)});if(c)return Q7(t,{mode:n}).then(m=>h(null,m),h);let d=BB.relative(f,t).split(/\/|\\/);QB(f,d,n,g,u,f,null,h)},QB=(t,e,r,i,n,s,o,a)=>{if(!e.length)return a(null,o);let l=e.shift(),c=t+"/"+l;if(i.get(c))return QB(c,e,r,i,n,s,o,a);hs.mkdir(c,r,v7(c,e,r,i,n,s,o,a))},v7=(t,e,r,i,n,s,o,a)=>l=>{if(l){if(l.path&&BB.dirname(l.path)===s&&(l.code==="ENOTDIR"||l.code==="ENOENT"))return a(new cd(s,l.code));hs.lstat(t,(c,u)=>{if(c)a(c);else if(u.isDirectory())QB(t,e,r,i,n,s,o,a);else if(n)hs.unlink(t,g=>{if(g)return a(g);hs.mkdir(t,r,v7(t,e,r,i,n,s,o,a))});else{if(u.isSymbolicLink())return a(new sR(t,t+"/"+e.join("/")));a(l)}})}else o=o||t,QB(t,e,r,i,n,s,o,a)},tct=nR.exports.sync=(t,e)=>{let r=e.umask,i=e.mode|448,n=(i&r)!=0,s=e.uid,o=e.gid,a=typeof s=="number"&&typeof o=="number"&&(s!==e.processUid||o!==e.processGid),l=e.preserve,c=e.unlink,u=e.cache,g=e.cwd,f=m=>{u.set(t,!0),m&&a&&b7.sync(m,s,o),n&&hs.chmodSync(t,i)};if(u&&u.get(t)===!0)return f();if(t===g){let m=!1,I="ENOTDIR";try{m=hs.statSync(t).isDirectory()}catch(B){I=B.code}finally{if(!m)throw new cd(t,I)}f();return}if(l)return f(Q7.sync(t,i));let p=BB.relative(g,t).split(/\/|\\/),d=null;for(let m=p.shift(),I=g;m&&(I+="/"+m);m=p.shift())if(!u.get(I))try{hs.mkdirSync(I,i),d=d||I,u.set(I,!0)}catch(B){if(B.path&&BB.dirname(B.path)===g&&(B.code==="ENOTDIR"||B.code==="ENOENT"))return new cd(g,B.code);let b=hs.lstatSync(I);if(b.isDirectory()){u.set(I,!0);continue}else if(c){hs.unlinkSync(I),hs.mkdirSync(I,i),d=d||I,u.set(I,!0);continue}else if(b.isSymbolicLink())return new sR(I,I+"/"+p.join("/"))}return f(d)}});var P7=E((ict,x7)=>{var k7=require("assert");x7.exports=()=>{let t=new Map,e=new Map,{join:r}=require("path"),i=u=>r(u).split(/[\\\/]/).slice(0,-1).reduce((g,f)=>g.length?g.concat(r(g[g.length-1],f)):[f],[]),n=new Set,s=u=>{let g=e.get(u);if(!g)throw new Error("function does not have any path reservations");return{paths:g.paths.map(f=>t.get(f)),dirs:[...g.dirs].map(f=>t.get(f))}},o=u=>{let{paths:g,dirs:f}=s(u);return g.every(h=>h[0]===u)&&f.every(h=>h[0]instanceof Set&&h[0].has(u))},a=u=>n.has(u)||!o(u)?!1:(n.add(u),u(()=>l(u)),!0),l=u=>{if(!n.has(u))return!1;let{paths:g,dirs:f}=e.get(u),h=new Set;return g.forEach(p=>{let d=t.get(p);k7.equal(d[0],u),d.length===1?t.delete(p):(d.shift(),typeof d[0]=="function"?h.add(d[0]):d[0].forEach(m=>h.add(m)))}),f.forEach(p=>{let d=t.get(p);k7(d[0]instanceof Set),d[0].size===1&&d.length===1?t.delete(p):d[0].size===1?(d.shift(),h.add(d[0])):d[0].delete(u)}),n.delete(u),h.forEach(p=>a(p)),!0};return{check:o,reserve:(u,g)=>{let f=new Set(u.map(h=>i(h)).reduce((h,p)=>h.concat(p)));return e.set(g,{dirs:f,paths:u}),u.forEach(h=>{let p=t.get(h);p?p.push(g):t.set(h,[g])}),f.forEach(h=>{let p=t.get(h);p?p[p.length-1]instanceof Set?p[p.length-1].add(g):p.push(new Set([g])):t.set(h,[new Set([g])])}),a(g)}}}});var F7=E((nct,D7)=>{var FLe=process.env.__FAKE_PLATFORM__||process.platform,NLe=FLe==="win32",LLe=global.__FAKE_TESTING_FS__||require("fs"),{O_CREAT:TLe,O_TRUNC:MLe,O_WRONLY:OLe,UV_FS_O_FILEMAP:R7=0}=LLe.constants,KLe=NLe&&!!R7,ULe=512*1024,HLe=R7|MLe|TLe|OLe;D7.exports=KLe?t=>t"w"});var hR=E((Act,N7)=>{"use strict";var GLe=require("assert"),sct=require("events").EventEmitter,jLe=ld(),Ut=require("fs"),YLe=bg(),Pa=require("path"),oR=S7(),oct=oR.sync,L7=yD(),qLe=P7(),T7=Symbol("onEntry"),aR=Symbol("checkFs"),M7=Symbol("checkFs2"),AR=Symbol("isReusable"),Da=Symbol("makeFs"),lR=Symbol("file"),cR=Symbol("directory"),bB=Symbol("link"),O7=Symbol("symlink"),K7=Symbol("hardlink"),U7=Symbol("unsupported"),act=Symbol("unknown"),H7=Symbol("checkPath"),Pg=Symbol("mkdir"),nn=Symbol("onError"),vB=Symbol("pending"),G7=Symbol("pend"),Dg=Symbol("unpend"),uR=Symbol("ended"),gR=Symbol("maybeClose"),fR=Symbol("skip"),ud=Symbol("doChown"),gd=Symbol("uid"),fd=Symbol("gid"),j7=require("crypto"),Y7=F7(),SB=()=>{throw new Error("sync function called cb somehow?!?")},JLe=(t,e)=>{if(process.platform!=="win32")return Ut.unlink(t,e);let r=t+".DELETE."+j7.randomBytes(16).toString("hex");Ut.rename(t,r,i=>{if(i)return e(i);Ut.unlink(r,e)})},WLe=t=>{if(process.platform!=="win32")return Ut.unlinkSync(t);let e=t+".DELETE."+j7.randomBytes(16).toString("hex");Ut.renameSync(t,e),Ut.unlinkSync(e)},q7=(t,e,r)=>t===t>>>0?t:e===e>>>0?e:r,xB=class extends jLe{constructor(e){if(e||(e={}),e.ondone=r=>{this[uR]=!0,this[gR]()},super(e),this.reservations=qLe(),this.transform=typeof e.transform=="function"?e.transform:null,this.writable=!0,this.readable=!1,this[vB]=0,this[uR]=!1,this.dirCache=e.dirCache||new Map,typeof e.uid=="number"||typeof e.gid=="number"){if(typeof e.uid!="number"||typeof e.gid!="number")throw new TypeError("cannot set owner without number uid and gid");if(e.preserveOwner)throw new TypeError("cannot preserve owner in archive and also set owner explicitly");this.uid=e.uid,this.gid=e.gid,this.setOwner=!0}else this.uid=null,this.gid=null,this.setOwner=!1;e.preserveOwner===void 0&&typeof e.uid!="number"?this.preserveOwner=process.getuid&&process.getuid()===0:this.preserveOwner=!!e.preserveOwner,this.processUid=(this.preserveOwner||this.setOwner)&&process.getuid?process.getuid():null,this.processGid=(this.preserveOwner||this.setOwner)&&process.getgid?process.getgid():null,this.forceChown=e.forceChown===!0,this.win32=!!e.win32||process.platform==="win32",this.newer=!!e.newer,this.keep=!!e.keep,this.noMtime=!!e.noMtime,this.preservePaths=!!e.preservePaths,this.unlink=!!e.unlink,this.cwd=Pa.resolve(e.cwd||process.cwd()),this.strip=+e.strip||0,this.processUmask=process.umask(),this.umask=typeof e.umask=="number"?e.umask:this.processUmask,this.dmode=e.dmode||511&~this.umask,this.fmode=e.fmode||438&~this.umask,this.on("entry",r=>this[T7](r))}warn(e,r,i={}){return(e==="TAR_BAD_ARCHIVE"||e==="TAR_ABORT")&&(i.recoverable=!1),super.warn(e,r,i)}[gR](){this[uR]&&this[vB]===0&&(this.emit("prefinish"),this.emit("finish"),this.emit("end"),this.emit("close"))}[H7](e){if(this.strip){let r=e.path.split(/\/|\\/);if(r.length=this.strip&&(e.linkpath=i.slice(this.strip).join("/"))}}if(!this.preservePaths){let r=e.path;if(r.match(/(^|\/|\\)\.\.(\\|\/|$)/))return this.warn("TAR_ENTRY_ERROR","path contains '..'",{entry:e,path:r}),!1;if(Pa.win32.isAbsolute(r)){let i=Pa.win32.parse(r);e.path=r.substr(i.root.length);let n=i.root;this.warn("TAR_ENTRY_INFO",`stripping ${n} from absolute path`,{entry:e,path:r})}}if(this.win32){let r=Pa.win32.parse(e.path);e.path=r.root===""?L7.encode(e.path):r.root+L7.encode(e.path.substr(r.root.length))}return Pa.isAbsolute(e.path)?e.absolute=e.path:e.absolute=Pa.resolve(this.cwd,e.path),!0}[T7](e){if(!this[H7](e))return e.resume();switch(GLe.equal(typeof e.absolute,"string"),e.type){case"Directory":case"GNUDumpDir":e.mode&&(e.mode=e.mode|448);case"File":case"OldFile":case"ContiguousFile":case"Link":case"SymbolicLink":return this[aR](e);case"CharacterDevice":case"BlockDevice":case"FIFO":return this[U7](e)}}[nn](e,r){e.name==="CwdError"?this.emit("error",e):(this.warn("TAR_ENTRY_ERROR",e,{entry:r}),this[Dg](),r.resume())}[Pg](e,r,i){oR(e,{uid:this.uid,gid:this.gid,processUid:this.processUid,processGid:this.processGid,umask:this.processUmask,preserve:this.preservePaths,unlink:this.unlink,cache:this.dirCache,cwd:this.cwd,mode:r},i)}[ud](e){return this.forceChown||this.preserveOwner&&(typeof e.uid=="number"&&e.uid!==this.processUid||typeof e.gid=="number"&&e.gid!==this.processGid)||typeof this.uid=="number"&&this.uid!==this.processUid||typeof this.gid=="number"&&this.gid!==this.processGid}[gd](e){return q7(this.uid,e.uid,this.processUid)}[fd](e){return q7(this.gid,e.gid,this.processGid)}[lR](e,r){let i=e.mode&4095||this.fmode,n=new YLe.WriteStream(e.absolute,{flags:Y7(e.size),mode:i,autoClose:!1});n.on("error",l=>this[nn](l,e));let s=1,o=l=>{if(l)return this[nn](l,e);--s==0&&Ut.close(n.fd,c=>{r(),c?this[nn](c,e):this[Dg]()})};n.on("finish",l=>{let c=e.absolute,u=n.fd;if(e.mtime&&!this.noMtime){s++;let g=e.atime||new Date,f=e.mtime;Ut.futimes(u,g,f,h=>h?Ut.utimes(c,g,f,p=>o(p&&h)):o())}if(this[ud](e)){s++;let g=this[gd](e),f=this[fd](e);Ut.fchown(u,g,f,h=>h?Ut.chown(c,g,f,p=>o(p&&h)):o())}o()});let a=this.transform&&this.transform(e)||e;a!==e&&(a.on("error",l=>this[nn](l,e)),e.pipe(a)),a.pipe(n)}[cR](e,r){let i=e.mode&4095||this.dmode;this[Pg](e.absolute,i,n=>{if(n)return r(),this[nn](n,e);let s=1,o=a=>{--s==0&&(r(),this[Dg](),e.resume())};e.mtime&&!this.noMtime&&(s++,Ut.utimes(e.absolute,e.atime||new Date,e.mtime,o)),this[ud](e)&&(s++,Ut.chown(e.absolute,this[gd](e),this[fd](e),o)),o()})}[U7](e){e.unsupported=!0,this.warn("TAR_ENTRY_UNSUPPORTED",`unsupported entry type: ${e.type}`,{entry:e}),e.resume()}[O7](e,r){this[bB](e,e.linkpath,"symlink",r)}[K7](e,r){this[bB](e,Pa.resolve(this.cwd,e.linkpath),"link",r)}[G7](){this[vB]++}[Dg](){this[vB]--,this[gR]()}[fR](e){this[Dg](),e.resume()}[AR](e,r){return e.type==="File"&&!this.unlink&&r.isFile()&&r.nlink<=1&&process.platform!=="win32"}[aR](e){this[G7]();let r=[e.path];e.linkpath&&r.push(e.linkpath),this.reservations.reserve(r,i=>this[M7](e,i))}[M7](e,r){this[Pg](Pa.dirname(e.absolute),this.dmode,i=>{if(i)return r(),this[nn](i,e);Ut.lstat(e.absolute,(n,s)=>{s&&(this.keep||this.newer&&s.mtime>e.mtime)?(this[fR](e),r()):n||this[AR](e,s)?this[Da](null,e,r):s.isDirectory()?e.type==="Directory"?!e.mode||(s.mode&4095)===e.mode?this[Da](null,e,r):Ut.chmod(e.absolute,e.mode,o=>this[Da](o,e,r)):Ut.rmdir(e.absolute,o=>this[Da](o,e,r)):JLe(e.absolute,o=>this[Da](o,e,r))})})}[Da](e,r,i){if(e)return this[nn](e,r);switch(r.type){case"File":case"OldFile":case"ContiguousFile":return this[lR](r,i);case"Link":return this[K7](r,i);case"SymbolicLink":return this[O7](r,i);case"Directory":case"GNUDumpDir":return this[cR](r,i)}}[bB](e,r,i,n){Ut[i](r,e.absolute,s=>{if(s)return this[nn](s,e);n(),this[Dg](),e.resume()})}},J7=class extends xB{constructor(e){super(e)}[aR](e){let r=this[Pg](Pa.dirname(e.absolute),this.dmode,SB);if(r)return this[nn](r,e);try{let i=Ut.lstatSync(e.absolute);if(this.keep||this.newer&&i.mtime>e.mtime)return this[fR](e);if(this[AR](e,i))return this[Da](null,e,SB);try{return i.isDirectory()?e.type==="Directory"?e.mode&&(i.mode&4095)!==e.mode&&Ut.chmodSync(e.absolute,e.mode):Ut.rmdirSync(e.absolute):WLe(e.absolute),this[Da](null,e,SB)}catch(n){return this[nn](n,e)}}catch(i){return this[Da](null,e,SB)}}[lR](e,r){let i=e.mode&4095||this.fmode,n=l=>{let c;try{Ut.closeSync(o)}catch(u){c=u}(l||c)&&this[nn](l||c,e)},s,o;try{o=Ut.openSync(e.absolute,Y7(e.size),i)}catch(l){return n(l)}let a=this.transform&&this.transform(e)||e;a!==e&&(a.on("error",l=>this[nn](l,e)),e.pipe(a)),a.on("data",l=>{try{Ut.writeSync(o,l,0,l.length)}catch(c){n(c)}}),a.on("end",l=>{let c=null;if(e.mtime&&!this.noMtime){let u=e.atime||new Date,g=e.mtime;try{Ut.futimesSync(o,u,g)}catch(f){try{Ut.utimesSync(e.absolute,u,g)}catch(h){c=f}}}if(this[ud](e)){let u=this[gd](e),g=this[fd](e);try{Ut.fchownSync(o,u,g)}catch(f){try{Ut.chownSync(e.absolute,u,g)}catch(h){c=c||f}}}n(c)})}[cR](e,r){let i=e.mode&4095||this.dmode,n=this[Pg](e.absolute,i);if(n)return this[nn](n,e);if(e.mtime&&!this.noMtime)try{Ut.utimesSync(e.absolute,e.atime||new Date,e.mtime)}catch(s){}if(this[ud](e))try{Ut.chownSync(e.absolute,this[gd](e),this[fd](e))}catch(s){}e.resume()}[Pg](e,r){try{return oR.sync(e,{uid:this.uid,gid:this.gid,processUid:this.processUid,processGid:this.processGid,umask:this.processUmask,preserve:this.preservePaths,unlink:this.unlink,cache:this.dirCache,cwd:this.cwd,mode:r})}catch(i){return i}}[bB](e,r,i,n){try{Ut[i+"Sync"](r,e.absolute),e.resume()}catch(s){return this[nn](s,e)}}};xB.Sync=J7;N7.exports=xB});var X7=E((cct,W7)=>{"use strict";var zLe=fg(),kB=hR(),z7=require("fs"),V7=bg(),_7=require("path"),lct=W7.exports=(t,e,r)=>{typeof t=="function"?(r=t,e=null,t={}):Array.isArray(t)&&(e=t,t={}),typeof e=="function"&&(r=e,e=null),e?e=Array.from(e):e=[];let i=zLe(t);if(i.sync&&typeof r=="function")throw new TypeError("callback not supported for sync tar functions");if(!i.file&&typeof r=="function")throw new TypeError("callback only supported with file option");return e.length&&VLe(i,e),i.file&&i.sync?_Le(i):i.file?XLe(i,r):i.sync?ZLe(i):$Le(i)},VLe=(t,e)=>{let r=new Map(e.map(s=>[s.replace(/\/+$/,""),!0])),i=t.filter,n=(s,o)=>{let a=o||_7.parse(s).root||".",l=s===a?!1:r.has(s)?r.get(s):n(_7.dirname(s),a);return r.set(s,l),l};t.filter=i?(s,o)=>i(s,o)&&n(s.replace(/\/+$/,"")):s=>n(s.replace(/\/+$/,""))},_Le=t=>{let e=new kB.Sync(t),r=t.file,i=!0,n,s=z7.statSync(r),o=t.maxReadSize||16*1024*1024;new V7.ReadStreamSync(r,{readSize:o,size:s.size}).pipe(e)},XLe=(t,e)=>{let r=new kB(t),i=t.maxReadSize||16*1024*1024,n=t.file,s=new Promise((o,a)=>{r.on("error",a),r.on("close",o),z7.stat(n,(l,c)=>{if(l)a(l);else{let u=new V7.ReadStream(n,{readSize:i,size:c.size});u.on("error",a),u.pipe(r)}})});return e?s.then(e,e):s},ZLe=t=>new kB.Sync(t),$Le=t=>new kB(t)});var Z7=E($r=>{"use strict";$r.c=$r.create=TV();$r.r=$r.replace=XD();$r.t=$r.list=IB();$r.u=$r.update=qV();$r.x=$r.extract=X7();$r.Pack=AB();$r.Unpack=hR();$r.Parse=ld();$r.ReadEntry=id();$r.WriteEntry=xD();$r.Header=Cg();$r.Pax=zw();$r.types=rd()});var e_=E((gct,pR)=>{"use strict";var eTe=Object.prototype.hasOwnProperty,sn="~";function hd(){}Object.create&&(hd.prototype=Object.create(null),new hd().__proto__||(sn=!1));function tTe(t,e,r){this.fn=t,this.context=e,this.once=r||!1}function $7(t,e,r,i,n){if(typeof r!="function")throw new TypeError("The listener must be a function");var s=new tTe(r,i||t,n),o=sn?sn+e:e;return t._events[o]?t._events[o].fn?t._events[o]=[t._events[o],s]:t._events[o].push(s):(t._events[o]=s,t._eventsCount++),t}function PB(t,e){--t._eventsCount==0?t._events=new hd:delete t._events[e]}function Ti(){this._events=new hd,this._eventsCount=0}Ti.prototype.eventNames=function(){var e=[],r,i;if(this._eventsCount===0)return e;for(i in r=this._events)eTe.call(r,i)&&e.push(sn?i.slice(1):i);return Object.getOwnPropertySymbols?e.concat(Object.getOwnPropertySymbols(r)):e};Ti.prototype.listeners=function(e){var r=sn?sn+e:e,i=this._events[r];if(!i)return[];if(i.fn)return[i.fn];for(var n=0,s=i.length,o=new Array(s);n{"use strict";t_.exports=(t,e)=>(e=e||(()=>{}),t.then(r=>new Promise(i=>{i(e())}).then(()=>r),r=>new Promise(i=>{i(e())}).then(()=>{throw r})))});var n_=E((hct,DB)=>{"use strict";var rTe=r_(),dR=class extends Error{constructor(e){super(e);this.name="TimeoutError"}},i_=(t,e,r)=>new Promise((i,n)=>{if(typeof e!="number"||e<0)throw new TypeError("Expected `milliseconds` to be a positive number");if(e===Infinity){i(t);return}let s=setTimeout(()=>{if(typeof r=="function"){try{i(r())}catch(l){n(l)}return}let o=typeof r=="string"?r:`Promise timed out after ${e} milliseconds`,a=r instanceof Error?r:new dR(o);typeof t.cancel=="function"&&t.cancel(),n(a)},e);rTe(t.then(i,n),()=>{clearTimeout(s)})});DB.exports=i_;DB.exports.default=i_;DB.exports.TimeoutError=dR});var s_=E(CR=>{"use strict";Object.defineProperty(CR,"__esModule",{value:!0});function iTe(t,e,r){let i=0,n=t.length;for(;n>0;){let s=n/2|0,o=i+s;r(t[o],e)<=0?(i=++o,n-=s+1):n=s}return i}CR.default=iTe});var a_=E(mR=>{"use strict";Object.defineProperty(mR,"__esModule",{value:!0});var nTe=s_(),o_=class{constructor(){this._queue=[]}enqueue(e,r){r=Object.assign({priority:0},r);let i={priority:r.priority,run:e};if(this.size&&this._queue[this.size-1].priority>=r.priority){this._queue.push(i);return}let n=nTe.default(this._queue,i,(s,o)=>o.priority-s.priority);this._queue.splice(n,0,i)}dequeue(){let e=this._queue.shift();return e==null?void 0:e.run}filter(e){return this._queue.filter(r=>r.priority===e.priority).map(r=>r.run)}get size(){return this._queue.length}};mR.default=o_});var c_=E(ER=>{"use strict";Object.defineProperty(ER,"__esModule",{value:!0});var sTe=e_(),A_=n_(),oTe=a_(),RB=()=>{},aTe=new A_.TimeoutError,l_=class extends sTe{constructor(e){var r,i,n,s;super();if(this._intervalCount=0,this._intervalEnd=0,this._pendingCount=0,this._resolveEmpty=RB,this._resolveIdle=RB,e=Object.assign({carryoverConcurrencyCount:!1,intervalCap:Infinity,interval:0,concurrency:Infinity,autoStart:!0,queueClass:oTe.default},e),!(typeof e.intervalCap=="number"&&e.intervalCap>=1))throw new TypeError(`Expected \`intervalCap\` to be a number from 1 and up, got \`${(i=(r=e.intervalCap)===null||r===void 0?void 0:r.toString())!==null&&i!==void 0?i:""}\` (${typeof e.intervalCap})`);if(e.interval===void 0||!(Number.isFinite(e.interval)&&e.interval>=0))throw new TypeError(`Expected \`interval\` to be a finite number >= 0, got \`${(s=(n=e.interval)===null||n===void 0?void 0:n.toString())!==null&&s!==void 0?s:""}\` (${typeof e.interval})`);this._carryoverConcurrencyCount=e.carryoverConcurrencyCount,this._isIntervalIgnored=e.intervalCap===Infinity||e.interval===0,this._intervalCap=e.intervalCap,this._interval=e.interval,this._queue=new e.queueClass,this._queueClass=e.queueClass,this.concurrency=e.concurrency,this._timeout=e.timeout,this._throwOnTimeout=e.throwOnTimeout===!0,this._isPaused=e.autoStart===!1}get _doesIntervalAllowAnother(){return this._isIntervalIgnored||this._intervalCount{this._onResumeInterval()},r)),!0}return!1}_tryToStartAnother(){if(this._queue.size===0)return this._intervalId&&clearInterval(this._intervalId),this._intervalId=void 0,this._resolvePromises(),!1;if(!this._isPaused){let e=!this._isIntervalPaused();if(this._doesIntervalAllowAnother&&this._doesConcurrentAllowAnother){let r=this._queue.dequeue();return r?(this.emit("active"),r(),e&&this._initializeIntervalIfNeeded(),!0):!1}}return!1}_initializeIntervalIfNeeded(){this._isIntervalIgnored||this._intervalId!==void 0||(this._intervalId=setInterval(()=>{this._onInterval()},this._interval),this._intervalEnd=Date.now()+this._interval)}_onInterval(){this._intervalCount===0&&this._pendingCount===0&&this._intervalId&&(clearInterval(this._intervalId),this._intervalId=void 0),this._intervalCount=this._carryoverConcurrencyCount?this._pendingCount:0,this._processQueue()}_processQueue(){for(;this._tryToStartAnother(););}get concurrency(){return this._concurrency}set concurrency(e){if(!(typeof e=="number"&&e>=1))throw new TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${e}\` (${typeof e})`);this._concurrency=e,this._processQueue()}async add(e,r={}){return new Promise((i,n)=>{let s=async()=>{this._pendingCount++,this._intervalCount++;try{let o=this._timeout===void 0&&r.timeout===void 0?e():A_.default(Promise.resolve(e()),r.timeout===void 0?this._timeout:r.timeout,()=>{(r.throwOnTimeout===void 0?this._throwOnTimeout:r.throwOnTimeout)&&n(aTe)});i(await o)}catch(o){n(o)}this._next()};this._queue.enqueue(s,r),this._tryToStartAnother(),this.emit("add")})}async addAll(e,r){return Promise.all(e.map(async i=>this.add(i,r)))}start(){return this._isPaused?(this._isPaused=!1,this._processQueue(),this):this}pause(){this._isPaused=!0}clear(){this._queue=new this._queueClass}async onEmpty(){if(this._queue.size!==0)return new Promise(e=>{let r=this._resolveEmpty;this._resolveEmpty=()=>{r(),e()}})}async onIdle(){if(!(this._pendingCount===0&&this._queue.size===0))return new Promise(e=>{let r=this._resolveIdle;this._resolveIdle=()=>{r(),e()}})}get size(){return this._queue.size}sizeBy(e){return this._queue.filter(e).length}get pending(){return this._pendingCount}get isPaused(){return this._isPaused}get timeout(){return this._timeout}set timeout(e){this._timeout=e}};ER.default=l_});var p_=E((Ect,h_)=>{var yR;h_.exports.getContent=()=>(typeof yR=="undefined"&&(yR=require("zlib").brotliDecompressSync(Buffer.from("W4IvekBxw2bzwtWbVf5fyX2AzAPMISJEY/fbMcKtepRTQlBXjG63eijJbQN4ALzvTBt+EVRVTTsqQ1wCS1oAYPuvqgWZIinRemQXGoWk4C5BOebq1CAsym3ILBoVZ6LpLswKQ4VNE6OQ3IoPxtM31ikJr/0aapiJOVzKMZJvVs7xyhEPb7LomEWn5rAew20WdiSC78J8645T+pzTZd2xBeNUftH3D/KCqIvf9WM4TH9KLFd/FFfbC9KDCMMr8adqt8u9KMdA74EW1Fz9lq72Fjds/1MKj113I0V5rYqPiha9B2QgN/UDYBFRw5RY5xhbddceetpc4haPeL+qeP+HTa1/Pq/ByyJE0UgpHdi9UprGorlUjHtupQT+VS2rl031EBiQOP5mroPRuipsZVWUW16j8M/7N+4KHWj7S2plWoCBPv+/38++//x8bZ2sRVXnUHS884T7MhrTmVHjqPfJZSGBA9aVWAxVdDc9Xf/vTf3++/NlPBnDmKNYctqelsOFLOtk2d/mNhagxTxLQhWSlVZ2r6Xa/z4vkq5xSelcxWaxOaNFx4IjJdnZ+Erp8j+b5umKtUkoCoPelwSsxzIp9VzqNhmsiVywXNlJmPWlWr9O1wIvqPm8JC82ja2IDr1iR/Fe8z/fZv0/P1+3V3CNoJcd5i006W2GbMubVIrYElLcSMfKvdfYoV4apEfBp/E11b/nciLpskmBtKqU1gftJEwEDG/ZtYz+9//7pf3nx7wFo/SUT5iokUamoOLyl2UKjd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Tyh5F4Iy7Hn2n6CDfbg19UDne3DdytglcmFKS/vKOpWLMYfqbKyMRfszSBnCgIpJoRqtAngSE1jV3MTCsAcz3hQs3cozb+YPpcST0sgh7zj8O+SxT7j9/oI4ezNJWw3eEn2GALDw3DyCsy3lS3Jzy8lkLvqYsxEn2niP0z9HK+bsvETqtmlzBYjvst/ayEPzFMCY6Cbd8jzMKAZafHiI6sh8tbBQcpz83TvHzx2rHU5ICEAcBDXctnJHArUy/oZ9+eLW5jPtVMuKB33QQ=","base64")).toString()),yR)});var y_=E((wR,I_)=>{(function(t,e){typeof wR=="object"?I_.exports=e():typeof define=="function"&&define.amd?define(e):t.treeify=e()})(wR,function(){function t(n,s){var o=s?"\u2514":"\u251C";return n?o+="\u2500 ":o+="\u2500\u2500\u2510",o}function e(n,s){var o=[];for(var a in n)!n.hasOwnProperty(a)||s&&typeof n[a]=="function"||o.push(a);return o}function r(n,s,o,a,l,c,u){var g="",f=0,h,p,d=a.slice(0);if(d.push([s,o])&&a.length>0&&(a.forEach(function(I,B){B>0&&(g+=(I[1]?" ":"\u2502")+" "),!p&&I[0]===s&&(p=!0)}),g+=t(n,o)+n,l&&(typeof s!="object"||s instanceof Date)&&(g+=": "+s),p&&(g+=" (circular ref.)"),u(g)),!p&&typeof s=="object"){var m=e(s,c);m.forEach(function(I){h=++f===m.length,r(I,s[I],h,d,l,c,u)})}}var i={};return i.asLines=function(n,s,o,a){var l=typeof o!="function"?o:!1;r(".",n,!1,[],s,l,a||o)},i.asTree=function(n,s,o){var a="";return r(".",n,!1,[],s,o,function(l){a+=l+` +`}),a},i})});var x_=E((Uct,bR)=>{"use strict";var pTe=t=>{let e=!1,r=!1,i=!1;for(let n=0;n{if(!(typeof t=="string"||Array.isArray(t)))throw new TypeError("Expected the input to be `string | string[]`");e=Object.assign({pascalCase:!1},e);let r=n=>e.pascalCase?n.charAt(0).toUpperCase()+n.slice(1):n;return Array.isArray(t)?t=t.map(n=>n.trim()).filter(n=>n.length).join("-"):t=t.trim(),t.length===0?"":t.length===1?e.pascalCase?t.toUpperCase():t.toLowerCase():(t!==t.toLowerCase()&&(t=pTe(t)),t=t.replace(/^[_.\- ]+/,"").toLowerCase().replace(/[_.\- ]+(\w|$)/g,(n,s)=>s.toUpperCase()).replace(/\d+(\w|$)/g,n=>n.toUpperCase()),r(t))};bR.exports=S_;bR.exports.default=S_});var Na=E(TR=>{"use strict";Object.defineProperty(TR,"__esModule",{value:!0});TR.default=L_;function L_(){}L_.prototype={diff:function(e,r){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=i.callback;typeof i=="function"&&(n=i,i={}),this.options=i;var s=this;function o(d){return n?(setTimeout(function(){n(void 0,d)},0),!0):d}e=this.castInput(e),r=this.castInput(r),e=this.removeEmpty(this.tokenize(e)),r=this.removeEmpty(this.tokenize(r));var a=r.length,l=e.length,c=1,u=a+l,g=[{newPos:-1,components:[]}],f=this.extractCommon(g[0],r,e,0);if(g[0].newPos+1>=a&&f+1>=l)return o([{value:this.join(r),count:r.length}]);function h(){for(var d=-1*c;d<=c;d+=2){var m=void 0,I=g[d-1],B=g[d+1],b=(B?B.newPos:0)-d;I&&(g[d-1]=void 0);var R=I&&I.newPos+1=a&&b+1>=l)return o(yTe(s,m.components,r,e,s.useLongestToken));g[d]=m}c++}if(n)(function d(){setTimeout(function(){if(c>u)return n();h()||d()},0)})();else for(;c<=u;){var p=h();if(p)return p}},pushComponent:function(e,r,i){var n=e[e.length-1];n&&n.added===r&&n.removed===i?e[e.length-1]={count:n.count+1,added:r,removed:i}:e.push({count:1,added:r,removed:i})},extractCommon:function(e,r,i,n){for(var s=r.length,o=i.length,a=e.newPos,l=a-n,c=0;a+1h.length?d:h}),c.value=t.join(u)}else c.value=t.join(r.slice(a,a+c.count));a+=c.count,c.added||(l+=c.count)}}var f=e[o-1];return o>1&&typeof f.value=="string"&&(f.added||f.removed)&&t.equals("",f.value)&&(e[o-2].value+=f.value,e.pop()),e}function wTe(t){return{newPos:t.newPos,components:t.components.slice(0)}}});var M_=E(Cd=>{"use strict";Object.defineProperty(Cd,"__esModule",{value:!0});Cd.diffChars=BTe;Cd.characterDiff=void 0;var bTe=QTe(Na());function QTe(t){return t&&t.__esModule?t:{default:t}}var T_=new bTe.default;Cd.characterDiff=T_;function BTe(t,e,r){return T_.diff(t,e,r)}});var OR=E(MR=>{"use strict";Object.defineProperty(MR,"__esModule",{value:!0});MR.generateOptions=vTe;function vTe(t,e){if(typeof t=="function")e.callback=t;else if(t)for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r]);return e}});var U_=E(Ng=>{"use strict";Object.defineProperty(Ng,"__esModule",{value:!0});Ng.diffWords=STe;Ng.diffWordsWithSpace=xTe;Ng.wordDiff=void 0;var PTe=kTe(Na()),DTe=OR();function kTe(t){return t&&t.__esModule?t:{default:t}}var O_=/^[A-Za-z\xC0-\u02C6\u02C8-\u02D7\u02DE-\u02FF\u1E00-\u1EFF]+$/,K_=/\S/,md=new PTe.default;Ng.wordDiff=md;md.equals=function(t,e){return this.options.ignoreCase&&(t=t.toLowerCase(),e=e.toLowerCase()),t===e||this.options.ignoreWhitespace&&!K_.test(t)&&!K_.test(e)};md.tokenize=function(t){for(var e=t.split(/(\s+|[()[\]{}'"]|\b)/),r=0;r{"use strict";Object.defineProperty(Lg,"__esModule",{value:!0});Lg.diffLines=RTe;Lg.diffTrimmedLines=FTe;Lg.lineDiff=void 0;var LTe=NTe(Na()),TTe=OR();function NTe(t){return t&&t.__esModule?t:{default:t}}var OB=new LTe.default;Lg.lineDiff=OB;OB.tokenize=function(t){var e=[],r=t.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(var i=0;i{"use strict";Object.defineProperty(Ed,"__esModule",{value:!0});Ed.diffSentences=MTe;Ed.sentenceDiff=void 0;var KTe=OTe(Na());function OTe(t){return t&&t.__esModule?t:{default:t}}var KR=new KTe.default;Ed.sentenceDiff=KR;KR.tokenize=function(t){return t.split(/(\S.+?[.!?])(?=\s+|$)/)};function MTe(t,e,r){return KR.diff(t,e,r)}});var G_=E(Id=>{"use strict";Object.defineProperty(Id,"__esModule",{value:!0});Id.diffCss=UTe;Id.cssDiff=void 0;var GTe=HTe(Na());function HTe(t){return t&&t.__esModule?t:{default:t}}var UR=new GTe.default;Id.cssDiff=UR;UR.tokenize=function(t){return t.split(/([{}:;,]|\s+)/)};function UTe(t,e,r){return UR.diff(t,e,r)}});var Y_=E(Tg=>{"use strict";Object.defineProperty(Tg,"__esModule",{value:!0});Tg.diffJson=jTe;Tg.canonicalize=UB;Tg.jsonDiff=void 0;var j_=YTe(Na()),qTe=KB();function YTe(t){return t&&t.__esModule?t:{default:t}}function HB(t){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?HB=function(r){return typeof r}:HB=function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r},HB(t)}var JTe=Object.prototype.toString,bc=new j_.default;Tg.jsonDiff=bc;bc.useLongestToken=!0;bc.tokenize=qTe.lineDiff.tokenize;bc.castInput=function(t){var e=this.options,r=e.undefinedReplacement,i=e.stringifyReplacer,n=i===void 0?function(s,o){return typeof o=="undefined"?r:o}:i;return typeof t=="string"?t:JSON.stringify(UB(t,null,null,n),n," ")};bc.equals=function(t,e){return j_.default.prototype.equals.call(bc,t.replace(/,([\r\n])/g,"$1"),e.replace(/,([\r\n])/g,"$1"))};function jTe(t,e,r){return bc.diff(t,e,r)}function UB(t,e,r,i,n){e=e||[],r=r||[],i&&(t=i(n,t));var s;for(s=0;s{"use strict";Object.defineProperty(yd,"__esModule",{value:!0});yd.diffArrays=WTe;yd.arrayDiff=void 0;var VTe=zTe(Na());function zTe(t){return t&&t.__esModule?t:{default:t}}var wd=new VTe.default;yd.arrayDiff=wd;wd.tokenize=function(t){return t.slice()};wd.join=wd.removeEmpty=function(t){return t};function WTe(t,e,r){return wd.diff(t,e,r)}});var GB=E(HR=>{"use strict";Object.defineProperty(HR,"__esModule",{value:!0});HR.parsePatch=_Te;function _Te(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=t.split(/\r\n|[\n\v\f\r\x85]/),i=t.match(/\r\n|[\n\v\f\r\x85]/g)||[],n=[],s=0;function o(){var c={};for(n.push(c);s{"use strict";Object.defineProperty(GR,"__esModule",{value:!0});GR.default=XTe;function XTe(t,e,r){var i=!0,n=!1,s=!1,o=1;return function a(){if(i&&!s){if(n?o++:i=!1,t+o<=r)return o;s=!0}if(!n)return s||(i=!0),e<=t-o?-o++:(n=!0,a())}}});var V_=E(jB=>{"use strict";Object.defineProperty(jB,"__esModule",{value:!0});jB.applyPatch=W_;jB.applyPatches=ZTe;var z_=GB(),eMe=$Te(J_());function $Te(t){return t&&t.__esModule?t:{default:t}}function W_(t,e){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(typeof e=="string"&&(e=(0,z_.parsePatch)(e)),Array.isArray(e)){if(e.length>1)throw new Error("applyPatch only works with a single input.");e=e[0]}var i=t.split(/\r\n|[\n\v\f\r\x85]/),n=t.match(/\r\n|[\n\v\f\r\x85]/g)||[],s=e.hunks,o=r.compareLine||function(F,D,he,pe){return D===pe},a=0,l=r.fuzzFactor||0,c=0,u=0,g,f;function h(F,D){for(var he=0;he0?pe[0]:" ",Pe=pe.length>0?pe.substr(1):pe;if(Ne===" "||Ne==="-"){if(!o(D+1,i[D],Ne,Pe)&&(a++,a>l))return!1;D++}}return!0}for(var p=0;p0?ne[0]:" ",A=ne.length>0?ne.substr(1):ne,V=L.linedelimiters[J];if(q===" ")K++;else if(q==="-")i.splice(K,1),n.splice(K,1);else if(q==="+")i.splice(K,0,A),n.splice(K,0,V),K++;else if(q==="\\"){var W=L.lines[J-1]?L.lines[J-1][0]:null;W==="+"?g=!0:W==="-"&&(f=!0)}}}if(g)for(;!i[i.length-1];)i.pop(),n.pop();else f&&(i.push(""),n.push(` +`));for(var X=0;X{"use strict";Object.defineProperty(Bd,"__esModule",{value:!0});Bd.structuredPatch=__;Bd.createTwoFilesPatch=X_;Bd.createPatch=tMe;var rMe=KB();function jR(t){return sMe(t)||nMe(t)||iMe()}function iMe(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function nMe(t){if(Symbol.iterator in Object(t)||Object.prototype.toString.call(t)==="[object Arguments]")return Array.from(t)}function sMe(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e0?l(L.lines.slice(-o.context)):[],u-=f.length,g-=f.length)}(H=f).push.apply(H,jR(R.map(function(X){return(b.added?"+":"-")+X}))),b.added?p+=R.length:h+=R.length}else{if(u)if(R.length<=o.context*2&&B=a.length-2&&R.length<=o.context){var A=/\n$/.test(r),V=/\n$/.test(i),W=R.length==0&&f.length>q.oldLines;!A&&W&&f.splice(q.oldLines,0,"\\ No newline at end of file"),(!A&&!W||!V)&&f.push("\\ No newline at end of file")}c.push(q),u=0,g=0,f=[]}h+=R.length,p+=R.length}},m=0;m{"use strict";Object.defineProperty(YB,"__esModule",{value:!0});YB.arrayEqual=oMe;YB.arrayStartsWith=Z_;function oMe(t,e){return t.length!==e.length?!1:Z_(t,e)}function Z_(t,e){if(e.length>t.length)return!1;for(var r=0;r{"use strict";Object.defineProperty(qB,"__esModule",{value:!0});qB.calcLineCount=eX;qB.merge=aMe;var AMe=YR(),lMe=GB(),qR=$_();function Mg(t){return gMe(t)||uMe(t)||cMe()}function cMe(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function uMe(t){if(Symbol.iterator in Object(t)||Object.prototype.toString.call(t)==="[object Arguments]")return Array.from(t)}function gMe(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e{"use strict";Object.defineProperty(zR,"__esModule",{value:!0});zR.convertChangesToDMP=dMe;function dMe(t){for(var e=[],r,i,n=0;n{"use strict";Object.defineProperty(VR,"__esModule",{value:!0});VR.convertChangesToXML=CMe;function CMe(t){for(var e=[],r=0;r"):i.removed&&e.push(""),e.push(mMe(i.value)),i.added?e.push(""):i.removed&&e.push("")}return e.join("")}function mMe(t){var e=t;return e=e.replace(/&/g,"&"),e=e.replace(//g,">"),e=e.replace(/"/g,"""),e}});var CX=E(br=>{"use strict";Object.defineProperty(br,"__esModule",{value:!0});Object.defineProperty(br,"Diff",{enumerable:!0,get:function(){return EMe.default}});Object.defineProperty(br,"diffChars",{enumerable:!0,get:function(){return IMe.diffChars}});Object.defineProperty(br,"diffWords",{enumerable:!0,get:function(){return fX.diffWords}});Object.defineProperty(br,"diffWordsWithSpace",{enumerable:!0,get:function(){return fX.diffWordsWithSpace}});Object.defineProperty(br,"diffLines",{enumerable:!0,get:function(){return hX.diffLines}});Object.defineProperty(br,"diffTrimmedLines",{enumerable:!0,get:function(){return hX.diffTrimmedLines}});Object.defineProperty(br,"diffSentences",{enumerable:!0,get:function(){return yMe.diffSentences}});Object.defineProperty(br,"diffCss",{enumerable:!0,get:function(){return wMe.diffCss}});Object.defineProperty(br,"diffJson",{enumerable:!0,get:function(){return pX.diffJson}});Object.defineProperty(br,"canonicalize",{enumerable:!0,get:function(){return pX.canonicalize}});Object.defineProperty(br,"diffArrays",{enumerable:!0,get:function(){return BMe.diffArrays}});Object.defineProperty(br,"applyPatch",{enumerable:!0,get:function(){return dX.applyPatch}});Object.defineProperty(br,"applyPatches",{enumerable:!0,get:function(){return dX.applyPatches}});Object.defineProperty(br,"parsePatch",{enumerable:!0,get:function(){return QMe.parsePatch}});Object.defineProperty(br,"merge",{enumerable:!0,get:function(){return bMe.merge}});Object.defineProperty(br,"structuredPatch",{enumerable:!0,get:function(){return _R.structuredPatch}});Object.defineProperty(br,"createTwoFilesPatch",{enumerable:!0,get:function(){return _R.createTwoFilesPatch}});Object.defineProperty(br,"createPatch",{enumerable:!0,get:function(){return _R.createPatch}});Object.defineProperty(br,"convertChangesToDMP",{enumerable:!0,get:function(){return vMe.convertChangesToDMP}});Object.defineProperty(br,"convertChangesToXML",{enumerable:!0,get:function(){return SMe.convertChangesToXML}});var EMe=xMe(Na()),IMe=M_(),fX=U_(),hX=KB(),yMe=H_(),wMe=G_(),pX=Y_(),BMe=q_(),dX=V_(),QMe=GB(),bMe=cX(),_R=YR(),vMe=uX(),SMe=gX();function xMe(t){return t&&t.__esModule?t:{default:t}}});var WB=E((agt,mX)=>{var kMe=As(),PMe=Nw(),DMe=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,RMe=/^\w*$/;function FMe(t,e){if(kMe(t))return!1;var r=typeof t;return r=="number"||r=="symbol"||r=="boolean"||t==null||PMe(t)?!0:RMe.test(t)||!DMe.test(t)||e!=null&&t in Object(e)}mX.exports=FMe});var Gs=E((Agt,EX)=>{function NMe(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}EX.exports=NMe});var zB=E((lgt,IX)=>{var LMe=Ac(),TMe=Gs(),MMe="[object AsyncFunction]",OMe="[object Function]",KMe="[object GeneratorFunction]",UMe="[object Proxy]";function HMe(t){if(!TMe(t))return!1;var e=LMe(t);return e==OMe||e==KMe||e==MMe||e==UMe}IX.exports=HMe});var wX=E((cgt,yX)=>{var GMe=Ks(),jMe=GMe["__core-js_shared__"];yX.exports=jMe});var bX=E((ugt,BX)=>{var XR=wX(),QX=function(){var t=/[^.]+$/.exec(XR&&XR.keys&&XR.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function YMe(t){return!!QX&&QX in t}BX.exports=YMe});var ZR=E((ggt,vX)=>{var qMe=Function.prototype,JMe=qMe.toString;function WMe(t){if(t!=null){try{return JMe.call(t)}catch(e){}try{return t+""}catch(e){}}return""}vX.exports=WMe});var xX=E((fgt,SX)=>{var zMe=zB(),VMe=bX(),_Me=Gs(),XMe=ZR(),ZMe=/[\\^$.*+?()[\]{}|]/g,$Me=/^\[object .+?Constructor\]$/,eOe=Function.prototype,tOe=Object.prototype,rOe=eOe.toString,iOe=tOe.hasOwnProperty,nOe=RegExp("^"+rOe.call(iOe).replace(ZMe,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function sOe(t){if(!_Me(t)||VMe(t))return!1;var e=zMe(t)?nOe:$Me;return e.test(XMe(t))}SX.exports=sOe});var PX=E((hgt,kX)=>{function oOe(t,e){return t==null?void 0:t[e]}kX.exports=oOe});var UA=E((pgt,DX)=>{var aOe=xX(),AOe=PX();function lOe(t,e){var r=AOe(t,e);return aOe(r)?r:void 0}DX.exports=lOe});var Qd=E((dgt,RX)=>{var cOe=UA(),uOe=cOe(Object,"create");RX.exports=uOe});var LX=E((Cgt,FX)=>{var NX=Qd();function gOe(){this.__data__=NX?NX(null):{},this.size=0}FX.exports=gOe});var MX=E((mgt,TX)=>{function fOe(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}TX.exports=fOe});var KX=E((Egt,OX)=>{var hOe=Qd(),pOe="__lodash_hash_undefined__",dOe=Object.prototype,COe=dOe.hasOwnProperty;function mOe(t){var e=this.__data__;if(hOe){var r=e[t];return r===pOe?void 0:r}return COe.call(e,t)?e[t]:void 0}OX.exports=mOe});var HX=E((Igt,UX)=>{var EOe=Qd(),IOe=Object.prototype,yOe=IOe.hasOwnProperty;function wOe(t){var e=this.__data__;return EOe?e[t]!==void 0:yOe.call(e,t)}UX.exports=wOe});var jX=E((ygt,GX)=>{var BOe=Qd(),QOe="__lodash_hash_undefined__";function bOe(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=BOe&&e===void 0?QOe:e,this}GX.exports=bOe});var qX=E((wgt,YX)=>{var vOe=LX(),SOe=MX(),xOe=KX(),kOe=HX(),POe=jX();function Og(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e{function DOe(){this.__data__=[],this.size=0}JX.exports=DOe});var Kg=E((Qgt,zX)=>{function ROe(t,e){return t===e||t!==t&&e!==e}zX.exports=ROe});var bd=E((bgt,VX)=>{var FOe=Kg();function NOe(t,e){for(var r=t.length;r--;)if(FOe(t[r][0],e))return r;return-1}VX.exports=NOe});var XX=E((vgt,_X)=>{var LOe=bd(),TOe=Array.prototype,MOe=TOe.splice;function OOe(t){var e=this.__data__,r=LOe(e,t);if(r<0)return!1;var i=e.length-1;return r==i?e.pop():MOe.call(e,r,1),--this.size,!0}_X.exports=OOe});var $X=E((Sgt,ZX)=>{var KOe=bd();function UOe(t){var e=this.__data__,r=KOe(e,t);return r<0?void 0:e[r][1]}ZX.exports=UOe});var tZ=E((xgt,eZ)=>{var HOe=bd();function GOe(t){return HOe(this.__data__,t)>-1}eZ.exports=GOe});var iZ=E((kgt,rZ)=>{var jOe=bd();function YOe(t,e){var r=this.__data__,i=jOe(r,t);return i<0?(++this.size,r.push([t,e])):r[i][1]=e,this}rZ.exports=YOe});var vd=E((Pgt,nZ)=>{var qOe=WX(),JOe=XX(),WOe=$X(),zOe=tZ(),VOe=iZ();function Ug(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e{var _Oe=UA(),XOe=Ks(),ZOe=_Oe(XOe,"Map");sZ.exports=ZOe});var AZ=E((Rgt,oZ)=>{var aZ=qX(),$Oe=vd(),eKe=VB();function tKe(){this.size=0,this.__data__={hash:new aZ,map:new(eKe||$Oe),string:new aZ}}oZ.exports=tKe});var cZ=E((Fgt,lZ)=>{function rKe(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}lZ.exports=rKe});var Sd=E((Ngt,uZ)=>{var iKe=cZ();function nKe(t,e){var r=t.__data__;return iKe(e)?r[typeof e=="string"?"string":"hash"]:r.map}uZ.exports=nKe});var fZ=E((Lgt,gZ)=>{var sKe=Sd();function oKe(t){var e=sKe(this,t).delete(t);return this.size-=e?1:0,e}gZ.exports=oKe});var pZ=E((Tgt,hZ)=>{var aKe=Sd();function AKe(t){return aKe(this,t).get(t)}hZ.exports=AKe});var CZ=E((Mgt,dZ)=>{var lKe=Sd();function cKe(t){return lKe(this,t).has(t)}dZ.exports=cKe});var EZ=E((Ogt,mZ)=>{var uKe=Sd();function gKe(t,e){var r=uKe(this,t),i=r.size;return r.set(t,e),this.size+=r.size==i?0:1,this}mZ.exports=gKe});var _B=E((Kgt,IZ)=>{var fKe=AZ(),hKe=fZ(),pKe=pZ(),dKe=CZ(),CKe=EZ();function Hg(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e{var wZ=_B(),mKe="Expected a function";function $R(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(mKe);var r=function(){var i=arguments,n=e?e.apply(this,i):i[0],s=r.cache;if(s.has(n))return s.get(n);var o=t.apply(this,i);return r.cache=s.set(n,o)||s,o};return r.cache=new($R.Cache||wZ),r}$R.Cache=wZ;yZ.exports=$R});var bZ=E((Hgt,QZ)=>{var EKe=BZ(),IKe=500;function yKe(t){var e=EKe(t,function(i){return r.size===IKe&&r.clear(),i}),r=e.cache;return e}QZ.exports=yKe});var SZ=E((Ggt,vZ)=>{var wKe=bZ(),BKe=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,QKe=/\\(\\)?/g,bKe=wKe(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(BKe,function(r,i,n,s){e.push(n?s.replace(QKe,"$1"):i||r)}),e});vZ.exports=bKe});var Gg=E((jgt,xZ)=>{var vKe=As(),SKe=WB(),xKe=SZ(),kKe=gg();function PKe(t,e){return vKe(t)?t:SKe(t,e)?[t]:xKe(kKe(t))}xZ.exports=PKe});var Sc=E((Ygt,kZ)=>{var DKe=Nw(),RKe=1/0;function FKe(t){if(typeof t=="string"||DKe(t))return t;var e=t+"";return e=="0"&&1/t==-RKe?"-0":e}kZ.exports=FKe});var xd=E((qgt,PZ)=>{var NKe=Gg(),LKe=Sc();function TKe(t,e){e=NKe(e,t);for(var r=0,i=e.length;t!=null&&r{var MKe=UA(),OKe=function(){try{var t=MKe(Object,"defineProperty");return t({},"",{}),t}catch(e){}}();DZ.exports=OKe});var jg=E((Wgt,RZ)=>{var FZ=eF();function KKe(t,e,r){e=="__proto__"&&FZ?FZ(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}RZ.exports=KKe});var XB=E((zgt,NZ)=>{var UKe=jg(),HKe=Kg(),GKe=Object.prototype,jKe=GKe.hasOwnProperty;function YKe(t,e,r){var i=t[e];(!(jKe.call(t,e)&&HKe(i,r))||r===void 0&&!(e in t))&&UKe(t,e,r)}NZ.exports=YKe});var kd=E((Vgt,LZ)=>{var qKe=9007199254740991,JKe=/^(?:0|[1-9]\d*)$/;function WKe(t,e){var r=typeof t;return e=e==null?qKe:e,!!e&&(r=="number"||r!="symbol"&&JKe.test(t))&&t>-1&&t%1==0&&t{var zKe=XB(),VKe=Gg(),_Ke=kd(),MZ=Gs(),XKe=Sc();function ZKe(t,e,r,i){if(!MZ(t))return t;e=VKe(e,t);for(var n=-1,s=e.length,o=s-1,a=t;a!=null&&++n{var $Ke=xd(),e1e=tF(),t1e=Gg();function r1e(t,e,r){for(var i=-1,n=e.length,s={};++i{function i1e(t,e){return t!=null&&e in Object(t)}UZ.exports=i1e});var jZ=E(($gt,GZ)=>{var n1e=Ac(),s1e=Qo(),o1e="[object Arguments]";function a1e(t){return s1e(t)&&n1e(t)==o1e}GZ.exports=a1e});var Pd=E((eft,YZ)=>{var qZ=jZ(),A1e=Qo(),JZ=Object.prototype,l1e=JZ.hasOwnProperty,c1e=JZ.propertyIsEnumerable,u1e=qZ(function(){return arguments}())?qZ:function(t){return A1e(t)&&l1e.call(t,"callee")&&!c1e.call(t,"callee")};YZ.exports=u1e});var ZB=E((tft,WZ)=>{var g1e=9007199254740991;function f1e(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=g1e}WZ.exports=f1e});var rF=E((rft,zZ)=>{var h1e=Gg(),p1e=Pd(),d1e=As(),C1e=kd(),m1e=ZB(),E1e=Sc();function I1e(t,e,r){e=h1e(e,t);for(var i=-1,n=e.length,s=!1;++i{var y1e=HZ(),w1e=rF();function B1e(t,e){return t!=null&&w1e(t,e,y1e)}VZ.exports=B1e});var XZ=E((nft,_Z)=>{var Q1e=KZ(),b1e=iF();function v1e(t,e){return Q1e(t,e,function(r,i){return b1e(t,i)})}_Z.exports=v1e});var $B=E((sft,ZZ)=>{function S1e(t,e){for(var r=-1,i=e.length,n=t.length;++r{var e$=ac(),x1e=Pd(),k1e=As(),t$=e$?e$.isConcatSpreadable:void 0;function P1e(t){return k1e(t)||x1e(t)||!!(t$&&t&&t[t$])}$Z.exports=P1e});var s$=E((aft,i$)=>{var D1e=$B(),R1e=r$();function n$(t,e,r,i,n){var s=-1,o=t.length;for(r||(r=R1e),n||(n=[]);++s0&&r(a)?e>1?n$(a,e-1,r,i,n):D1e(n,a):i||(n[n.length]=a)}return n}i$.exports=n$});var a$=E((Aft,o$)=>{var F1e=s$();function N1e(t){var e=t==null?0:t.length;return e?F1e(t,1):[]}o$.exports=N1e});var l$=E((lft,A$)=>{function L1e(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}A$.exports=L1e});var nF=E((cft,c$)=>{var T1e=l$(),u$=Math.max;function M1e(t,e,r){return e=u$(e===void 0?t.length-1:e,0),function(){for(var i=arguments,n=-1,s=u$(i.length-e,0),o=Array(s);++n{function O1e(t){return function(){return t}}g$.exports=O1e});var e0=E((gft,h$)=>{function K1e(t){return t}h$.exports=K1e});var C$=E((fft,p$)=>{var U1e=f$(),d$=eF(),H1e=e0(),G1e=d$?function(t,e){return d$(t,"toString",{configurable:!0,enumerable:!1,value:U1e(e),writable:!0})}:H1e;p$.exports=G1e});var E$=E((hft,m$)=>{var j1e=800,Y1e=16,q1e=Date.now;function J1e(t){var e=0,r=0;return function(){var i=q1e(),n=Y1e-(i-r);if(r=i,n>0){if(++e>=j1e)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}m$.exports=J1e});var sF=E((pft,I$)=>{var W1e=C$(),z1e=E$(),V1e=z1e(W1e);I$.exports=V1e});var w$=E((dft,y$)=>{var _1e=a$(),X1e=nF(),Z1e=sF();function $1e(t){return Z1e(X1e(t,void 0,_1e),t+"")}y$.exports=$1e});var Q$=E((Cft,B$)=>{var eUe=XZ(),tUe=w$(),rUe=tUe(function(t,e){return t==null?{}:eUe(t,e)});B$.exports=rUe});var M$=E((lpt,N$)=>{"use strict";var pF;try{pF=Map}catch(t){}var dF;try{dF=Set}catch(t){}function L$(t,e,r){if(!t||typeof t!="object"||typeof t=="function")return t;if(t.nodeType&&"cloneNode"in t)return t.cloneNode(!0);if(t instanceof Date)return new Date(t.getTime());if(t instanceof RegExp)return new RegExp(t);if(Array.isArray(t))return t.map(T$);if(pF&&t instanceof pF)return new Map(Array.from(t.entries()));if(dF&&t instanceof dF)return new Set(Array.from(t.values()));if(t instanceof Object){e.push(t);var i=Object.create(t);r.push(i);for(var n in t){var s=e.findIndex(function(o){return o===t[n]});i[n]=s>-1?r[s]:L$(t[n],e,r)}return i}return t}function T$(t){return L$(t,[],[])}N$.exports=T$});var Nd=E(CF=>{"use strict";Object.defineProperty(CF,"__esModule",{value:!0});CF.default=uUe;var gUe=Object.prototype.toString,fUe=Error.prototype.toString,hUe=RegExp.prototype.toString,pUe=typeof Symbol!="undefined"?Symbol.prototype.toString:()=>"",dUe=/^Symbol\((.*)\)(.*)$/;function CUe(t){return t!=+t?"NaN":t===0&&1/t<0?"-0":""+t}function O$(t,e=!1){if(t==null||t===!0||t===!1)return""+t;let r=typeof t;if(r==="number")return CUe(t);if(r==="string")return e?`"${t}"`:t;if(r==="function")return"[Function "+(t.name||"anonymous")+"]";if(r==="symbol")return pUe.call(t).replace(dUe,"Symbol($1)");let i=gUe.call(t).slice(8,-1);return i==="Date"?isNaN(t.getTime())?""+t:t.toISOString(t):i==="Error"||t instanceof Error?"["+fUe.call(t)+"]":i==="RegExp"?hUe.call(t):null}function uUe(t,e){let r=O$(t,e);return r!==null?r:JSON.stringify(t,function(i,n){let s=O$(this[i],e);return s!==null?s:n},2)}});var La=E(ci=>{"use strict";Object.defineProperty(ci,"__esModule",{value:!0});ci.default=ci.array=ci.object=ci.boolean=ci.date=ci.number=ci.string=ci.mixed=void 0;var K$=mUe(Nd());function mUe(t){return t&&t.__esModule?t:{default:t}}var U$={default:"${path} is invalid",required:"${path} is a required field",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:t,type:e,value:r,originalValue:i})=>{let n=i!=null&&i!==r,s=`${t} must be a \`${e}\` type, but the final value was: \`${(0,K$.default)(r,!0)}\``+(n?` (cast from the value \`${(0,K$.default)(i,!0)}\`).`:".");return r===null&&(s+='\n If "null" is intended as an empty value be sure to mark the schema as `.nullable()`'),s},defined:"${path} must be defined"};ci.mixed=U$;var H$={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"};ci.string=H$;var G$={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"};ci.number=G$;var j$={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"};ci.date=j$;var Y$={isValue:"${path} field must be ${value}"};ci.boolean=Y$;var q$={noUnknown:"${path} field has unspecified keys: ${unknown}"};ci.object=q$;var J$={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must be have ${length} items"};ci.array=J$;var EUe=Object.assign(Object.create(null),{mixed:U$,string:H$,number:G$,date:j$,object:q$,array:J$,boolean:Y$});ci.default=EUe});var z$=E((gpt,W$)=>{var IUe=Object.prototype,yUe=IUe.hasOwnProperty;function wUe(t,e){return t!=null&&yUe.call(t,e)}W$.exports=wUe});var Ld=E((fpt,V$)=>{var BUe=z$(),QUe=rF();function bUe(t,e){return t!=null&&QUe(t,e,BUe)}V$.exports=bUe});var qg=E(n0=>{"use strict";Object.defineProperty(n0,"__esModule",{value:!0});n0.default=void 0;var vUe=t=>t&&t.__isYupSchema__;n0.default=vUe});var Z$=E(s0=>{"use strict";Object.defineProperty(s0,"__esModule",{value:!0});s0.default=void 0;var SUe=_$(Ld()),xUe=_$(qg());function _$(t){return t&&t.__esModule?t:{default:t}}var X$=class{constructor(e,r){if(this.refs=e,this.refs=e,typeof r=="function"){this.fn=r;return}if(!(0,SUe.default)(r,"is"))throw new TypeError("`is:` is required for `when()` conditions");if(!r.then&&!r.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:i,then:n,otherwise:s}=r,o=typeof i=="function"?i:(...a)=>a.every(l=>l===i);this.fn=function(...a){let l=a.pop(),c=a.pop(),u=o(...a)?n:s;if(!!u)return typeof u=="function"?u(c):c.concat(u.resolve(l))}}resolve(e,r){let i=this.refs.map(s=>s.getValue(r==null?void 0:r.value,r==null?void 0:r.parent,r==null?void 0:r.context)),n=this.fn.apply(e,i.concat(e,r));if(n===void 0||n===e)return e;if(!(0,xUe.default)(n))throw new TypeError("conditions must return a schema object");return n.resolve(r)}},kUe=X$;s0.default=kUe});var EF=E(mF=>{"use strict";Object.defineProperty(mF,"__esModule",{value:!0});mF.default=PUe;function PUe(t){return t==null?[]:[].concat(t)}});var xc=E(o0=>{"use strict";Object.defineProperty(o0,"__esModule",{value:!0});o0.default=void 0;var DUe=$$(Nd()),RUe=$$(EF());function $$(t){return t&&t.__esModule?t:{default:t}}function IF(){return IF=Object.assign||function(t){for(var e=1;e(0,DUe.default)(r[s])):typeof e=="function"?e(r):e}static isError(e){return e&&e.name==="ValidationError"}constructor(e,r,i,n){super();this.name="ValidationError",this.value=r,this.path=i,this.type=n,this.errors=[],this.inner=[],(0,RUe.default)(e).forEach(s=>{Td.isError(s)?(this.errors.push(...s.errors),this.inner=this.inner.concat(s.inner.length?s.inner:s)):this.errors.push(s)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0],Error.captureStackTrace&&Error.captureStackTrace(this,Td)}};o0.default=Td});var a0=E(yF=>{"use strict";Object.defineProperty(yF,"__esModule",{value:!0});yF.default=NUe;var wF=LUe(xc());function LUe(t){return t&&t.__esModule?t:{default:t}}var TUe=t=>{let e=!1;return(...r)=>{e||(e=!0,t(...r))}};function NUe(t,e){let{endEarly:r,tests:i,args:n,value:s,errors:o,sort:a,path:l}=t,c=TUe(e),u=i.length,g=[];if(o=o||[],!u)return o.length?c(new wF.default(o,s,l)):c(null,s);for(let f=0;f{function MUe(t){return function(e,r,i){for(var n=-1,s=Object(e),o=i(e),a=o.length;a--;){var l=o[t?a:++n];if(r(s[l],l,s)===!1)break}return e}}eee.exports=MUe});var BF=E((Ipt,ree)=>{var OUe=tee(),KUe=OUe();ree.exports=KUe});var nee=E((ypt,iee)=>{function UUe(t,e){for(var r=-1,i=Array(t);++r{function HUe(){return!1}see.exports=HUe});var Od=E((Md,Jg)=>{var GUe=Ks(),jUe=oee(),aee=typeof Md=="object"&&Md&&!Md.nodeType&&Md,Aee=aee&&typeof Jg=="object"&&Jg&&!Jg.nodeType&&Jg,YUe=Aee&&Aee.exports===aee,lee=YUe?GUe.Buffer:void 0,qUe=lee?lee.isBuffer:void 0,JUe=qUe||jUe;Jg.exports=JUe});var uee=E((Bpt,cee)=>{var WUe=Ac(),zUe=ZB(),VUe=Qo(),_Ue="[object Arguments]",XUe="[object Array]",ZUe="[object Boolean]",$Ue="[object Date]",e2e="[object Error]",t2e="[object Function]",r2e="[object Map]",i2e="[object Number]",n2e="[object Object]",s2e="[object RegExp]",o2e="[object Set]",a2e="[object String]",A2e="[object WeakMap]",l2e="[object ArrayBuffer]",c2e="[object DataView]",u2e="[object Float32Array]",g2e="[object Float64Array]",f2e="[object Int8Array]",h2e="[object Int16Array]",p2e="[object Int32Array]",d2e="[object Uint8Array]",C2e="[object Uint8ClampedArray]",m2e="[object Uint16Array]",E2e="[object Uint32Array]",lr={};lr[u2e]=lr[g2e]=lr[f2e]=lr[h2e]=lr[p2e]=lr[d2e]=lr[C2e]=lr[m2e]=lr[E2e]=!0;lr[_Ue]=lr[XUe]=lr[l2e]=lr[ZUe]=lr[c2e]=lr[$Ue]=lr[e2e]=lr[t2e]=lr[r2e]=lr[i2e]=lr[n2e]=lr[s2e]=lr[o2e]=lr[a2e]=lr[A2e]=!1;function I2e(t){return VUe(t)&&zUe(t.length)&&!!lr[WUe(t)]}cee.exports=I2e});var A0=E((Qpt,gee)=>{function y2e(t){return function(e){return t(e)}}gee.exports=y2e});var l0=E((Kd,Wg)=>{var w2e=WP(),fee=typeof Kd=="object"&&Kd&&!Kd.nodeType&&Kd,Ud=fee&&typeof Wg=="object"&&Wg&&!Wg.nodeType&&Wg,B2e=Ud&&Ud.exports===fee,QF=B2e&&w2e.process,Q2e=function(){try{var t=Ud&&Ud.require&&Ud.require("util").types;return t||QF&&QF.binding&&QF.binding("util")}catch(e){}}();Wg.exports=Q2e});var c0=E((bpt,hee)=>{var b2e=uee(),v2e=A0(),pee=l0(),dee=pee&&pee.isTypedArray,S2e=dee?v2e(dee):b2e;hee.exports=S2e});var bF=E((vpt,Cee)=>{var x2e=nee(),k2e=Pd(),P2e=As(),D2e=Od(),R2e=kd(),F2e=c0(),N2e=Object.prototype,L2e=N2e.hasOwnProperty;function T2e(t,e){var r=P2e(t),i=!r&&k2e(t),n=!r&&!i&&D2e(t),s=!r&&!i&&!n&&F2e(t),o=r||i||n||s,a=o?x2e(t.length,String):[],l=a.length;for(var c in t)(e||L2e.call(t,c))&&!(o&&(c=="length"||n&&(c=="offset"||c=="parent")||s&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||R2e(c,l)))&&a.push(c);return a}Cee.exports=T2e});var u0=E((Spt,mee)=>{var M2e=Object.prototype;function O2e(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||M2e;return t===r}mee.exports=O2e});var vF=E((xpt,Eee)=>{function K2e(t,e){return function(r){return t(e(r))}}Eee.exports=K2e});var yee=E((kpt,Iee)=>{var U2e=vF(),H2e=U2e(Object.keys,Object);Iee.exports=H2e});var Bee=E((Ppt,wee)=>{var G2e=u0(),j2e=yee(),Y2e=Object.prototype,q2e=Y2e.hasOwnProperty;function J2e(t){if(!G2e(t))return j2e(t);var e=[];for(var r in Object(t))q2e.call(t,r)&&r!="constructor"&&e.push(r);return e}wee.exports=J2e});var Hd=E((Dpt,Qee)=>{var W2e=zB(),z2e=ZB();function V2e(t){return t!=null&&z2e(t.length)&&!W2e(t)}Qee.exports=V2e});var zg=E((Rpt,bee)=>{var _2e=bF(),X2e=Bee(),Z2e=Hd();function $2e(t){return Z2e(t)?_2e(t):X2e(t)}bee.exports=$2e});var SF=E((Fpt,vee)=>{var eHe=BF(),tHe=zg();function rHe(t,e){return t&&eHe(t,e,tHe)}vee.exports=rHe});var xee=E((Npt,See)=>{var iHe=vd();function nHe(){this.__data__=new iHe,this.size=0}See.exports=nHe});var Pee=E((Lpt,kee)=>{function sHe(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}kee.exports=sHe});var Ree=E((Tpt,Dee)=>{function oHe(t){return this.__data__.get(t)}Dee.exports=oHe});var Nee=E((Mpt,Fee)=>{function aHe(t){return this.__data__.has(t)}Fee.exports=aHe});var Tee=E((Opt,Lee)=>{var AHe=vd(),lHe=VB(),cHe=_B(),uHe=200;function gHe(t,e){var r=this.__data__;if(r instanceof AHe){var i=r.__data__;if(!lHe||i.length{var fHe=vd(),hHe=xee(),pHe=Pee(),dHe=Ree(),CHe=Nee(),mHe=Tee();function Vg(t){var e=this.__data__=new fHe(t);this.size=e.size}Vg.prototype.clear=hHe;Vg.prototype.delete=pHe;Vg.prototype.get=dHe;Vg.prototype.has=CHe;Vg.prototype.set=mHe;Mee.exports=Vg});var Kee=E((Upt,Oee)=>{var EHe="__lodash_hash_undefined__";function IHe(t){return this.__data__.set(t,EHe),this}Oee.exports=IHe});var Hee=E((Hpt,Uee)=>{function yHe(t){return this.__data__.has(t)}Uee.exports=yHe});var jee=E((Gpt,Gee)=>{var wHe=_B(),BHe=Kee(),QHe=Hee();function g0(t){var e=-1,r=t==null?0:t.length;for(this.__data__=new wHe;++e{function bHe(t,e){for(var r=-1,i=t==null?0:t.length;++r{function vHe(t,e){return t.has(e)}Jee.exports=vHe});var xF=E((qpt,zee)=>{var SHe=jee(),xHe=qee(),kHe=Wee(),PHe=1,DHe=2;function RHe(t,e,r,i,n,s){var o=r&PHe,a=t.length,l=e.length;if(a!=l&&!(o&&l>a))return!1;var c=s.get(t),u=s.get(e);if(c&&u)return c==e&&u==t;var g=-1,f=!0,h=r&DHe?new SHe:void 0;for(s.set(t,e),s.set(e,t);++g{var FHe=Ks(),NHe=FHe.Uint8Array;Vee.exports=NHe});var Xee=E((Wpt,_ee)=>{function LHe(t){var e=-1,r=Array(t.size);return t.forEach(function(i,n){r[++e]=[n,i]}),r}_ee.exports=LHe});var $ee=E((zpt,Zee)=>{function THe(t){var e=-1,r=Array(t.size);return t.forEach(function(i){r[++e]=i}),r}Zee.exports=THe});var nte=E((Vpt,ete)=>{var tte=ac(),rte=kF(),MHe=Kg(),OHe=xF(),KHe=Xee(),UHe=$ee(),HHe=1,GHe=2,jHe="[object Boolean]",YHe="[object Date]",qHe="[object Error]",JHe="[object Map]",WHe="[object Number]",zHe="[object RegExp]",VHe="[object Set]",_He="[object String]",XHe="[object Symbol]",ZHe="[object ArrayBuffer]",$He="[object DataView]",ite=tte?tte.prototype:void 0,PF=ite?ite.valueOf:void 0;function eGe(t,e,r,i,n,s,o){switch(r){case $He:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case ZHe:return!(t.byteLength!=e.byteLength||!s(new rte(t),new rte(e)));case jHe:case YHe:case WHe:return MHe(+t,+e);case qHe:return t.name==e.name&&t.message==e.message;case zHe:case _He:return t==e+"";case JHe:var a=KHe;case VHe:var l=i&HHe;if(a||(a=UHe),t.size!=e.size&&!l)return!1;var c=o.get(t);if(c)return c==e;i|=GHe,o.set(t,e);var u=OHe(a(t),a(e),i,n,s,o);return o.delete(t),u;case XHe:if(PF)return PF.call(t)==PF.call(e)}return!1}ete.exports=eGe});var DF=E((_pt,ste)=>{var tGe=$B(),rGe=As();function iGe(t,e,r){var i=e(t);return rGe(t)?i:tGe(i,r(t))}ste.exports=iGe});var ate=E((Xpt,ote)=>{function nGe(t,e){for(var r=-1,i=t==null?0:t.length,n=0,s=[];++r{function sGe(){return[]}Ate.exports=sGe});var f0=E(($pt,lte)=>{var oGe=ate(),aGe=RF(),AGe=Object.prototype,lGe=AGe.propertyIsEnumerable,cte=Object.getOwnPropertySymbols,cGe=cte?function(t){return t==null?[]:(t=Object(t),oGe(cte(t),function(e){return lGe.call(t,e)}))}:aGe;lte.exports=cGe});var FF=E((edt,ute)=>{var uGe=DF(),gGe=f0(),fGe=zg();function hGe(t){return uGe(t,fGe,gGe)}ute.exports=hGe});var hte=E((tdt,gte)=>{var fte=FF(),pGe=1,dGe=Object.prototype,CGe=dGe.hasOwnProperty;function mGe(t,e,r,i,n,s){var o=r&pGe,a=fte(t),l=a.length,c=fte(e),u=c.length;if(l!=u&&!o)return!1;for(var g=l;g--;){var f=a[g];if(!(o?f in e:CGe.call(e,f)))return!1}var h=s.get(t),p=s.get(e);if(h&&p)return h==e&&p==t;var d=!0;s.set(t,e),s.set(e,t);for(var m=o;++g{var EGe=UA(),IGe=Ks(),yGe=EGe(IGe,"DataView");pte.exports=yGe});var mte=E((idt,Cte)=>{var wGe=UA(),BGe=Ks(),QGe=wGe(BGe,"Promise");Cte.exports=QGe});var Ite=E((ndt,Ete)=>{var bGe=UA(),vGe=Ks(),SGe=bGe(vGe,"Set");Ete.exports=SGe});var wte=E((sdt,yte)=>{var xGe=UA(),kGe=Ks(),PGe=xGe(kGe,"WeakMap");yte.exports=PGe});var jd=E((odt,Bte)=>{var NF=dte(),LF=VB(),TF=mte(),MF=Ite(),OF=wte(),Qte=Ac(),_g=ZR(),bte="[object Map]",DGe="[object Object]",vte="[object Promise]",Ste="[object Set]",xte="[object WeakMap]",kte="[object DataView]",RGe=_g(NF),FGe=_g(LF),NGe=_g(TF),LGe=_g(MF),TGe=_g(OF),kc=Qte;(NF&&kc(new NF(new ArrayBuffer(1)))!=kte||LF&&kc(new LF)!=bte||TF&&kc(TF.resolve())!=vte||MF&&kc(new MF)!=Ste||OF&&kc(new OF)!=xte)&&(kc=function(t){var e=Qte(t),r=e==DGe?t.constructor:void 0,i=r?_g(r):"";if(i)switch(i){case RGe:return kte;case FGe:return bte;case NGe:return vte;case LGe:return Ste;case TGe:return xte}return e});Bte.exports=kc});var Mte=E((adt,Pte)=>{var KF=Gd(),MGe=xF(),OGe=nte(),KGe=hte(),Dte=jd(),Rte=As(),Fte=Od(),UGe=c0(),HGe=1,Nte="[object Arguments]",Lte="[object Array]",h0="[object Object]",GGe=Object.prototype,Tte=GGe.hasOwnProperty;function jGe(t,e,r,i,n,s){var o=Rte(t),a=Rte(e),l=o?Lte:Dte(t),c=a?Lte:Dte(e);l=l==Nte?h0:l,c=c==Nte?h0:c;var u=l==h0,g=c==h0,f=l==c;if(f&&Fte(t)){if(!Fte(e))return!1;o=!0,u=!1}if(f&&!u)return s||(s=new KF),o||UGe(t)?MGe(t,e,r,i,n,s):OGe(t,e,l,r,i,n,s);if(!(r&HGe)){var h=u&&Tte.call(t,"__wrapped__"),p=g&&Tte.call(e,"__wrapped__");if(h||p){var d=h?t.value():t,m=p?e.value():e;return s||(s=new KF),n(d,m,r,i,s)}}return f?(s||(s=new KF),KGe(t,e,r,i,n,s)):!1}Pte.exports=jGe});var UF=E((Adt,Ote)=>{var YGe=Mte(),Kte=Qo();function Ute(t,e,r,i,n){return t===e?!0:t==null||e==null||!Kte(t)&&!Kte(e)?t!==t&&e!==e:YGe(t,e,r,i,Ute,n)}Ote.exports=Ute});var Gte=E((ldt,Hte)=>{var qGe=Gd(),JGe=UF(),WGe=1,zGe=2;function VGe(t,e,r,i){var n=r.length,s=n,o=!i;if(t==null)return!s;for(t=Object(t);n--;){var a=r[n];if(o&&a[2]?a[1]!==t[a[0]]:!(a[0]in t))return!1}for(;++n{var _Ge=Gs();function XGe(t){return t===t&&!_Ge(t)}jte.exports=XGe});var qte=E((udt,Yte)=>{var ZGe=HF(),$Ge=zg();function eje(t){for(var e=$Ge(t),r=e.length;r--;){var i=e[r],n=t[i];e[r]=[i,n,ZGe(n)]}return e}Yte.exports=eje});var GF=E((gdt,Jte)=>{function tje(t,e){return function(r){return r==null?!1:r[t]===e&&(e!==void 0||t in Object(r))}}Jte.exports=tje});var zte=E((fdt,Wte)=>{var rje=Gte(),ije=qte(),nje=GF();function sje(t){var e=ije(t);return e.length==1&&e[0][2]?nje(e[0][0],e[0][1]):function(r){return r===t||rje(r,t,e)}}Wte.exports=sje});var p0=E((hdt,Vte)=>{var oje=xd();function aje(t,e,r){var i=t==null?void 0:oje(t,e);return i===void 0?r:i}Vte.exports=aje});var Xte=E((pdt,_te)=>{var Aje=UF(),lje=p0(),cje=iF(),uje=WB(),gje=HF(),fje=GF(),hje=Sc(),pje=1,dje=2;function Cje(t,e){return uje(t)&&gje(e)?fje(hje(t),e):function(r){var i=lje(r,t);return i===void 0&&i===e?cje(r,t):Aje(e,i,pje|dje)}}_te.exports=Cje});var $te=E((ddt,Zte)=>{function mje(t){return function(e){return e==null?void 0:e[t]}}Zte.exports=mje});var tre=E((Cdt,ere)=>{var Eje=xd();function Ije(t){return function(e){return Eje(e,t)}}ere.exports=Ije});var ire=E((mdt,rre)=>{var yje=$te(),wje=tre(),Bje=WB(),Qje=Sc();function bje(t){return Bje(t)?yje(Qje(t)):wje(t)}rre.exports=bje});var jF=E((Edt,nre)=>{var vje=zte(),Sje=Xte(),xje=e0(),kje=As(),Pje=ire();function Dje(t){return typeof t=="function"?t:t==null?xje:typeof t=="object"?kje(t)?Sje(t[0],t[1]):vje(t):Pje(t)}nre.exports=Dje});var YF=E((Idt,sre)=>{var Rje=jg(),Fje=SF(),Nje=jF();function Lje(t,e){var r={};return e=Nje(e,3),Fje(t,function(i,n,s){Rje(r,n,e(i,n,s))}),r}sre.exports=Lje});var Yd=E((ydt,ore)=>{"use strict";function Pc(t){this._maxSize=t,this.clear()}Pc.prototype.clear=function(){this._size=0,this._values=Object.create(null)};Pc.prototype.get=function(t){return this._values[t]};Pc.prototype.set=function(t,e){return this._size>=this._maxSize&&this.clear(),t in this._values||this._size++,this._values[t]=e};var Tje=/[^.^\]^[]+|(?=\[\]|\.\.)/g,are=/^\d+$/,Mje=/^\d/,Oje=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,Kje=/^\s*(['"]?)(.*?)(\1)\s*$/,qF=512,Are=new Pc(qF),lre=new Pc(qF),cre=new Pc(qF);ore.exports={Cache:Pc,split:WF,normalizePath:JF,setter:function(t){var e=JF(t);return lre.get(t)||lre.set(t,function(i,n){for(var s=0,o=e.length,a=i;s{"use strict";Object.defineProperty(qd,"__esModule",{value:!0});qd.create=Yje;qd.default=void 0;var qje=Yd(),d0={context:"$",value:"."};function Yje(t,e){return new C0(t,e)}var C0=class{constructor(e,r={}){if(typeof e!="string")throw new TypeError("ref must be a string, got: "+e);if(this.key=e.trim(),e==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===d0.context,this.isValue=this.key[0]===d0.value,this.isSibling=!this.isContext&&!this.isValue;let i=this.isContext?d0.context:this.isValue?d0.value:"";this.path=this.key.slice(i.length),this.getter=this.path&&(0,qje.getter)(this.path,!0),this.map=r.map}getValue(e,r,i){let n=this.isContext?i:this.isValue?e:r;return this.getter&&(n=this.getter(n||{})),this.map&&(n=this.map(n)),n}cast(e,r){return this.getValue(e,r==null?void 0:r.parent,r==null?void 0:r.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(e){return e&&e.__isYupRef}};qd.default=C0;C0.prototype.__isYupRef=!0});var ure=E(VF=>{"use strict";Object.defineProperty(VF,"__esModule",{value:!0});VF.default=Jje;var Wje=_F(YF()),m0=_F(xc()),zje=_F(Dc());function _F(t){return t&&t.__esModule?t:{default:t}}function E0(){return E0=Object.assign||function(t){for(var e=1;e=0)&&(r[n]=t[n]);return r}function Jje(t){function e(r,i){let{value:n,path:s="",label:o,options:a,originalValue:l,sync:c}=r,u=Vje(r,["value","path","label","options","originalValue","sync"]),{name:g,test:f,params:h,message:p}=t,{parent:d,context:m}=a;function I(L){return zje.default.isRef(L)?L.getValue(n,d,m):L}function B(L={}){let K=(0,Wje.default)(E0({value:n,originalValue:l,label:o,path:L.path||s},h,L.params),I),J=new m0.default(m0.default.formatError(L.message||p,K),n,K.path,L.type||g);return J.params=K,J}let b=E0({path:s,parent:d,type:g,createError:B,resolve:I,options:a,originalValue:l},u);if(!c){try{Promise.resolve(f.call(b,n,b)).then(L=>{m0.default.isError(L)?i(L):L?i(null,L):i(B())})}catch(L){i(L)}return}let R;try{var H;if(R=f.call(b,n,b),typeof((H=R)==null?void 0:H.then)=="function")throw new Error(`Validation test of type: "${b.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`)}catch(L){i(L);return}m0.default.isError(R)?i(R):R?i(null,R):i(B())}return e.OPTIONS=t,e}});var XF=E(Jd=>{"use strict";Object.defineProperty(Jd,"__esModule",{value:!0});Jd.getIn=gre;Jd.default=void 0;var _je=Yd(),Xje=t=>t.substr(0,t.length-1).substr(1);function gre(t,e,r,i=r){let n,s,o;return e?((0,_je.forEach)(e,(a,l,c)=>{let u=l?Xje(a):a;if(t=t.resolve({context:i,parent:n,value:r}),t.innerType){let g=c?parseInt(u,10):0;if(r&&g>=r.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${a}, in the path: ${e}. because there is no value at that index. `);n=r,r=r&&r[g],t=t.innerType}if(!c){if(!t.fields||!t.fields[u])throw new Error(`The schema does not contain the path: ${e}. (failed at: ${o} which is a type: "${t._type}")`);n=r,r=r&&r[u],t=t.fields[u]}s=u,o=l?"["+a+"]":"."+a}),{schema:t,parent:n,parentPath:s}):{parent:n,parentPath:e,schema:t}}var Zje=(t,e,r,i)=>gre(t,e,r,i).schema,$je=Zje;Jd.default=$je});var hre=E(I0=>{"use strict";Object.defineProperty(I0,"__esModule",{value:!0});I0.default=void 0;var fre=eYe(Dc());function eYe(t){return t&&t.__esModule?t:{default:t}}var y0=class{constructor(){this.list=new Set,this.refs=new Map}get size(){return this.list.size+this.refs.size}describe(){let e=[];for(let r of this.list)e.push(r);for(let[,r]of this.refs)e.push(r.describe());return e}toArray(){return Array.from(this.list).concat(Array.from(this.refs.values()))}add(e){fre.default.isRef(e)?this.refs.set(e.key,e):this.list.add(e)}delete(e){fre.default.isRef(e)?this.refs.delete(e.key):this.list.delete(e)}has(e,r){if(this.list.has(e))return!0;let i,n=this.refs.values();for(;i=n.next(),!i.done;)if(r(i.value)===e)return!0;return!1}clone(){let e=new y0;return e.list=new Set(this.list),e.refs=new Map(this.refs),e}merge(e,r){let i=this.clone();return e.list.forEach(n=>i.add(n)),e.refs.forEach(n=>i.add(n)),r.list.forEach(n=>i.delete(n)),r.refs.forEach(n=>i.delete(n)),i}};I0.default=y0});var Ma=E(w0=>{"use strict";Object.defineProperty(w0,"__esModule",{value:!0});w0.default=void 0;var pre=Ta(M$()),Xg=La(),tYe=Ta(Z$()),dre=Ta(a0()),B0=Ta(ure()),Cre=Ta(Nd()),rYe=Ta(Dc()),iYe=XF(),nYe=Ta(EF()),mre=Ta(xc()),Ere=Ta(hre());function Ta(t){return t&&t.__esModule?t:{default:t}}function ds(){return ds=Object.assign||function(t){for(var e=1;e{this.typeError(Xg.mixed.notType)}),this.type=(e==null?void 0:e.type)||"mixed",this.spec=ds({strip:!1,strict:!1,abortEarly:!0,recursive:!0,nullable:!1,presence:"optional"},e==null?void 0:e.spec)}get _type(){return this.type}_typeCheck(e){return!0}clone(e){if(this._mutate)return e&&Object.assign(this.spec,e),this;let r=Object.create(Object.getPrototypeOf(this));return r.type=this.type,r._typeError=this._typeError,r._whitelistError=this._whitelistError,r._blacklistError=this._blacklistError,r._whitelist=this._whitelist.clone(),r._blacklist=this._blacklist.clone(),r.exclusiveTests=ds({},this.exclusiveTests),r.deps=[...this.deps],r.conditions=[...this.conditions],r.tests=[...this.tests],r.transforms=[...this.transforms],r.spec=(0,pre.default)(ds({},this.spec,e)),r}label(e){var r=this.clone();return r.spec.label=e,r}meta(...e){if(e.length===0)return this.spec.meta;let r=this.clone();return r.spec.meta=Object.assign(r.spec.meta||{},e[0]),r}withMutation(e){let r=this._mutate;this._mutate=!0;let i=e(this);return this._mutate=r,i}concat(e){if(!e||e===this)return this;if(e.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${e.type}`);let r=this,i=e.clone(),n=ds({},r.spec,i.spec);return i.spec=n,i._typeError||(i._typeError=r._typeError),i._whitelistError||(i._whitelistError=r._whitelistError),i._blacklistError||(i._blacklistError=r._blacklistError),i._whitelist=r._whitelist.merge(e._whitelist,e._blacklist),i._blacklist=r._blacklist.merge(e._blacklist,e._whitelist),i.tests=r.tests,i.exclusiveTests=r.exclusiveTests,i.withMutation(s=>{e.tests.forEach(o=>{s.test(o.OPTIONS)})}),i}isType(e){return this.spec.nullable&&e===null?!0:this._typeCheck(e)}resolve(e){let r=this;if(r.conditions.length){let i=r.conditions;r=r.clone(),r.conditions=[],r=i.reduce((n,s)=>s.resolve(n,e),r),r=r.resolve(e)}return r}cast(e,r={}){let i=this.resolve(ds({value:e},r)),n=i._cast(e,r);if(e!==void 0&&r.assert!==!1&&i.isType(n)!==!0){let s=(0,Cre.default)(e),o=(0,Cre.default)(n);throw new TypeError(`The value of ${r.path||"field"} could not be cast to a value that satisfies the schema type: "${i._type}". + +attempted value: ${s} +`+(o!==s?`result of cast: ${o}`:""))}return n}_cast(e,r){let i=e===void 0?e:this.transforms.reduce((n,s)=>s.call(this,n,e,this),e);return i===void 0&&(i=this.getDefault()),i}_validate(e,r={},i){let{sync:n,path:s,from:o=[],originalValue:a=e,strict:l=this.spec.strict,abortEarly:c=this.spec.abortEarly}=r,u=e;l||(u=this._cast(u,ds({assert:!1},r)));let g={value:u,path:s,options:r,originalValue:a,schema:this,label:this.spec.label,sync:n,from:o},f=[];this._typeError&&f.push(this._typeError),this._whitelistError&&f.push(this._whitelistError),this._blacklistError&&f.push(this._blacklistError),(0,dre.default)({args:g,value:u,path:s,sync:n,tests:f,endEarly:c},h=>{if(h)return void i(h,u);(0,dre.default)({tests:this.tests,args:g,path:s,sync:n,value:u,endEarly:c},i)})}validate(e,r,i){let n=this.resolve(ds({},r,{value:e}));return typeof i=="function"?n._validate(e,r,i):new Promise((s,o)=>n._validate(e,r,(a,l)=>{a?o(a):s(l)}))}validateSync(e,r){let i=this.resolve(ds({},r,{value:e})),n;return i._validate(e,ds({},r,{sync:!0}),(s,o)=>{if(s)throw s;n=o}),n}isValid(e,r){return this.validate(e,r).then(()=>!0,i=>{if(mre.default.isError(i))return!1;throw i})}isValidSync(e,r){try{return this.validateSync(e,r),!0}catch(i){if(mre.default.isError(i))return!1;throw i}}_getDefault(){let e=this.spec.default;return e==null?e:typeof e=="function"?e.call(this):(0,pre.default)(e)}getDefault(e){return this.resolve(e||{})._getDefault()}default(e){return arguments.length===0?this._getDefault():this.clone({default:e})}strict(e=!0){var r=this.clone();return r.spec.strict=e,r}_isPresent(e){return e!=null}defined(e=Xg.mixed.defined){return this.test({message:e,name:"defined",exclusive:!0,test(r){return r!==void 0}})}required(e=Xg.mixed.required){return this.clone({presence:"required"}).withMutation(r=>r.test({message:e,name:"required",exclusive:!0,test(i){return this.schema._isPresent(i)}}))}notRequired(){var e=this.clone({presence:"optional"});return e.tests=e.tests.filter(r=>r.OPTIONS.name!=="required"),e}nullable(e=!0){var r=this.clone({nullable:e!==!1});return r}transform(e){var r=this.clone();return r.transforms.push(e),r}test(...e){let r;if(e.length===1?typeof e[0]=="function"?r={test:e[0]}:r=e[0]:e.length===2?r={name:e[0],test:e[1]}:r={name:e[0],message:e[1],test:e[2]},r.message===void 0&&(r.message=Xg.mixed.default),typeof r.test!="function")throw new TypeError("`test` is a required parameters");let i=this.clone(),n=(0,B0.default)(r),s=r.exclusive||r.name&&i.exclusiveTests[r.name]===!0;if(r.exclusive&&!r.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return r.name&&(i.exclusiveTests[r.name]=!!r.exclusive),i.tests=i.tests.filter(o=>!(o.OPTIONS.name===r.name&&(s||o.OPTIONS.test===n.OPTIONS.test))),i.tests.push(n),i}when(e,r){!Array.isArray(e)&&typeof e!="string"&&(r=e,e=".");let i=this.clone(),n=(0,nYe.default)(e).map(s=>new rYe.default(s));return n.forEach(s=>{s.isSibling&&i.deps.push(s.key)}),i.conditions.push(new tYe.default(n,r)),i}typeError(e){var r=this.clone();return r._typeError=(0,B0.default)({message:e,name:"typeError",test(i){return i!==void 0&&!this.schema.isType(i)?this.createError({params:{type:this.schema._type}}):!0}}),r}oneOf(e,r=Xg.mixed.oneOf){var i=this.clone();return e.forEach(n=>{i._whitelist.add(n),i._blacklist.delete(n)}),i._whitelistError=(0,B0.default)({message:r,name:"oneOf",test(n){if(n===void 0)return!0;let s=this.schema._whitelist;return s.has(n,this.resolve)?!0:this.createError({params:{values:s.toArray().join(", ")}})}}),i}notOneOf(e,r=Xg.mixed.notOneOf){var i=this.clone();return e.forEach(n=>{i._blacklist.add(n),i._whitelist.delete(n)}),i._blacklistError=(0,B0.default)({message:r,name:"notOneOf",test(n){let s=this.schema._blacklist;return s.has(n,this.resolve)?this.createError({params:{values:s.toArray().join(", ")}}):!0}}),i}strip(e=!0){let r=this.clone();return r.spec.strip=e,r}describe(){let e=this.clone(),{label:r,meta:i}=e.spec;return{meta:i,label:r,type:e.type,oneOf:e._whitelist.describe(),notOneOf:e._blacklist.describe(),tests:e.tests.map(s=>({name:s.OPTIONS.name,params:s.OPTIONS.params})).filter((s,o,a)=>a.findIndex(l=>l.name===s.name)===o)}}};w0.default=Do;Do.prototype.__isYupSchema__=!0;for(let t of["validate","validateSync"])Do.prototype[`${t}At`]=function(e,r,i={}){let{parent:n,parentPath:s,schema:o}=(0,iYe.getIn)(this,e,r,i.context);return o[t](n&&n[s],ds({},i,{parent:n,path:e}))};for(let t of["equals","is"])Do.prototype[t]=Do.prototype.oneOf;for(let t of["not","nope"])Do.prototype[t]=Do.prototype.notOneOf;Do.prototype.optional=Do.prototype.notRequired});var yre=E(Wd=>{"use strict";Object.defineProperty(Wd,"__esModule",{value:!0});Wd.create=Ire;Wd.default=void 0;var oYe=sYe(Ma());function sYe(t){return t&&t.__esModule?t:{default:t}}var ZF=oYe.default,aYe=ZF;Wd.default=aYe;function Ire(){return new ZF}Ire.prototype=ZF.prototype});var Zg=E(Q0=>{"use strict";Object.defineProperty(Q0,"__esModule",{value:!0});Q0.default=void 0;var AYe=t=>t==null;Q0.default=AYe});var vre=E(zd=>{"use strict";Object.defineProperty(zd,"__esModule",{value:!0});zd.create=wre;zd.default=void 0;var lYe=Bre(Ma()),Qre=La(),bre=Bre(Zg());function Bre(t){return t&&t.__esModule?t:{default:t}}function wre(){return new b0}var b0=class extends lYe.default{constructor(){super({type:"boolean"});this.withMutation(()=>{this.transform(function(e){if(!this.isType(e)){if(/^(true|1)$/i.test(String(e)))return!0;if(/^(false|0)$/i.test(String(e)))return!1}return e})})}_typeCheck(e){return e instanceof Boolean&&(e=e.valueOf()),typeof e=="boolean"}isTrue(e=Qre.boolean.isValue){return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"true"},test(r){return(0,bre.default)(r)||r===!0}})}isFalse(e=Qre.boolean.isValue){return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"false"},test(r){return(0,bre.default)(r)||r===!1}})}};zd.default=b0;wre.prototype=b0.prototype});var kre=E(Vd=>{"use strict";Object.defineProperty(Vd,"__esModule",{value:!0});Vd.create=Sre;Vd.default=void 0;var Ro=La(),Oa=xre(Zg()),cYe=xre(Ma());function xre(t){return t&&t.__esModule?t:{default:t}}var uYe=/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))$/i,gYe=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,fYe=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,hYe=t=>(0,Oa.default)(t)||t===t.trim(),pYe={}.toString();function Sre(){return new v0}var v0=class extends cYe.default{constructor(){super({type:"string"});this.withMutation(()=>{this.transform(function(e){if(this.isType(e)||Array.isArray(e))return e;let r=e!=null&&e.toString?e.toString():e;return r===pYe?e:r})})}_typeCheck(e){return e instanceof String&&(e=e.valueOf()),typeof e=="string"}_isPresent(e){return super._isPresent(e)&&!!e.length}length(e,r=Ro.string.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:e},test(i){return(0,Oa.default)(i)||i.length===this.resolve(e)}})}min(e,r=Ro.string.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:e},test(i){return(0,Oa.default)(i)||i.length>=this.resolve(e)}})}max(e,r=Ro.string.max){return this.test({name:"max",exclusive:!0,message:r,params:{max:e},test(i){return(0,Oa.default)(i)||i.length<=this.resolve(e)}})}matches(e,r){let i=!1,n,s;return r&&(typeof r=="object"?{excludeEmptyString:i=!1,message:n,name:s}=r:n=r),this.test({name:s||"matches",message:n||Ro.string.matches,params:{regex:e},test:o=>(0,Oa.default)(o)||o===""&&i||o.search(e)!==-1})}email(e=Ro.string.email){return this.matches(uYe,{name:"email",message:e,excludeEmptyString:!0})}url(e=Ro.string.url){return this.matches(gYe,{name:"url",message:e,excludeEmptyString:!0})}uuid(e=Ro.string.uuid){return this.matches(fYe,{name:"uuid",message:e,excludeEmptyString:!1})}ensure(){return this.default("").transform(e=>e===null?"":e)}trim(e=Ro.string.trim){return this.transform(r=>r!=null?r.trim():r).test({message:e,name:"trim",test:hYe})}lowercase(e=Ro.string.lowercase){return this.transform(r=>(0,Oa.default)(r)?r:r.toLowerCase()).test({message:e,name:"string_case",exclusive:!0,test:r=>(0,Oa.default)(r)||r===r.toLowerCase()})}uppercase(e=Ro.string.uppercase){return this.transform(r=>(0,Oa.default)(r)?r:r.toUpperCase()).test({message:e,name:"string_case",exclusive:!0,test:r=>(0,Oa.default)(r)||r===r.toUpperCase()})}};Vd.default=v0;Sre.prototype=v0.prototype});var Rre=E(_d=>{"use strict";Object.defineProperty(_d,"__esModule",{value:!0});_d.create=Pre;_d.default=void 0;var Rc=La(),Fc=Dre(Zg()),dYe=Dre(Ma());function Dre(t){return t&&t.__esModule?t:{default:t}}var CYe=t=>t!=+t;function Pre(){return new S0}var S0=class extends dYe.default{constructor(){super({type:"number"});this.withMutation(()=>{this.transform(function(e){let r=e;if(typeof r=="string"){if(r=r.replace(/\s/g,""),r==="")return NaN;r=+r}return this.isType(r)?r:parseFloat(r)})})}_typeCheck(e){return e instanceof Number&&(e=e.valueOf()),typeof e=="number"&&!CYe(e)}min(e,r=Rc.number.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:e},test(i){return(0,Fc.default)(i)||i>=this.resolve(e)}})}max(e,r=Rc.number.max){return this.test({message:r,name:"max",exclusive:!0,params:{max:e},test(i){return(0,Fc.default)(i)||i<=this.resolve(e)}})}lessThan(e,r=Rc.number.lessThan){return this.test({message:r,name:"max",exclusive:!0,params:{less:e},test(i){return(0,Fc.default)(i)||ithis.resolve(e)}})}positive(e=Rc.number.positive){return this.moreThan(0,e)}negative(e=Rc.number.negative){return this.lessThan(0,e)}integer(e=Rc.number.integer){return this.test({name:"integer",message:e,test:r=>(0,Fc.default)(r)||Number.isInteger(r)})}truncate(){return this.transform(e=>(0,Fc.default)(e)?e:e|0)}round(e){var r,i=["ceil","floor","round","trunc"];if(e=((r=e)==null?void 0:r.toLowerCase())||"round",e==="trunc")return this.truncate();if(i.indexOf(e.toLowerCase())===-1)throw new TypeError("Only valid options for round() are: "+i.join(", "));return this.transform(n=>(0,Fc.default)(n)?n:Math[e](n))}};_d.default=S0;Pre.prototype=S0.prototype});var Fre=E($F=>{"use strict";Object.defineProperty($F,"__esModule",{value:!0});$F.default=mYe;var EYe=/^(\d{4}|[+\-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,\.](\d{1,}))?)?(?:(Z)|([+\-])(\d{2})(?::?(\d{2}))?)?)?$/;function mYe(t){var e=[1,4,5,6,7,10,11],r=0,i,n;if(n=EYe.exec(t)){for(var s=0,o;o=e[s];++s)n[o]=+n[o]||0;n[2]=(+n[2]||1)-1,n[3]=+n[3]||1,n[7]=n[7]?String(n[7]).substr(0,3):0,(n[8]===void 0||n[8]==="")&&(n[9]===void 0||n[9]==="")?i=+new Date(n[1],n[2],n[3],n[4],n[5],n[6],n[7]):(n[8]!=="Z"&&n[9]!==void 0&&(r=n[10]*60+n[11],n[9]==="+"&&(r=0-r)),i=Date.UTC(n[1],n[2],n[3],n[4],n[5]+r,n[6],n[7]))}else i=Date.parse?Date.parse(t):NaN;return i}});var Tre=E(Xd=>{"use strict";Object.defineProperty(Xd,"__esModule",{value:!0});Xd.create=eN;Xd.default=void 0;var IYe=x0(Fre()),Nre=La(),Lre=x0(Zg()),yYe=x0(Dc()),wYe=x0(Ma());function x0(t){return t&&t.__esModule?t:{default:t}}var tN=new Date(""),BYe=t=>Object.prototype.toString.call(t)==="[object Date]";function eN(){return new Zd}var Zd=class extends wYe.default{constructor(){super({type:"date"});this.withMutation(()=>{this.transform(function(e){return this.isType(e)?e:(e=(0,IYe.default)(e),isNaN(e)?tN:new Date(e))})})}_typeCheck(e){return BYe(e)&&!isNaN(e.getTime())}prepareParam(e,r){let i;if(yYe.default.isRef(e))i=e;else{let n=this.cast(e);if(!this._typeCheck(n))throw new TypeError(`\`${r}\` must be a Date or a value that can be \`cast()\` to a Date`);i=n}return i}min(e,r=Nre.date.min){let i=this.prepareParam(e,"min");return this.test({message:r,name:"min",exclusive:!0,params:{min:e},test(n){return(0,Lre.default)(n)||n>=this.resolve(i)}})}max(e,r=Nre.date.max){var i=this.prepareParam(e,"max");return this.test({message:r,name:"max",exclusive:!0,params:{max:e},test(n){return(0,Lre.default)(n)||n<=this.resolve(i)}})}};Xd.default=Zd;Zd.INVALID_DATE=tN;eN.prototype=Zd.prototype;eN.INVALID_DATE=tN});var Ore=E((Ndt,Mre)=>{function QYe(t,e,r,i){var n=-1,s=t==null?0:t.length;for(i&&s&&(r=t[++n]);++n{function bYe(t){return function(e){return t==null?void 0:t[e]}}Kre.exports=bYe});var Gre=E((Tdt,Hre)=>{var vYe=Ure(),SYe={\u00C0:"A",\u00C1:"A",\u00C2:"A",\u00C3:"A",\u00C4:"A",\u00C5:"A",\u00E0:"a",\u00E1:"a",\u00E2:"a",\u00E3:"a",\u00E4:"a",\u00E5:"a",\u00C7:"C",\u00E7:"c",\u00D0:"D",\u00F0:"d",\u00C8:"E",\u00C9:"E",\u00CA:"E",\u00CB:"E",\u00E8:"e",\u00E9:"e",\u00EA:"e",\u00EB:"e",\u00CC:"I",\u00CD:"I",\u00CE:"I",\u00CF:"I",\u00EC:"i",\u00ED:"i",\u00EE:"i",\u00EF:"i",\u00D1:"N",\u00F1:"n",\u00D2:"O",\u00D3:"O",\u00D4:"O",\u00D5:"O",\u00D6:"O",\u00D8:"O",\u00F2:"o",\u00F3:"o",\u00F4:"o",\u00F5:"o",\u00F6:"o",\u00F8:"o",\u00D9:"U",\u00DA:"U",\u00DB:"U",\u00DC:"U",\u00F9:"u",\u00FA:"u",\u00FB:"u",\u00FC:"u",\u00DD:"Y",\u00FD:"y",\u00FF:"y",\u00C6:"Ae",\u00E6:"ae",\u00DE:"Th",\u00FE:"th",\u00DF:"ss",\u0100:"A",\u0102:"A",\u0104:"A",\u0101:"a",\u0103:"a",\u0105:"a",\u0106:"C",\u0108:"C",\u010A:"C",\u010C:"C",\u0107:"c",\u0109:"c",\u010B:"c",\u010D:"c",\u010E:"D",\u0110:"D",\u010F:"d",\u0111:"d",\u0112:"E",\u0114:"E",\u0116:"E",\u0118:"E",\u011A:"E",\u0113:"e",\u0115:"e",\u0117:"e",\u0119:"e",\u011B:"e",\u011C:"G",\u011E:"G",\u0120:"G",\u0122:"G",\u011D:"g",\u011F:"g",\u0121:"g",\u0123:"g",\u0124:"H",\u0126:"H",\u0125:"h",\u0127:"h",\u0128:"I",\u012A:"I",\u012C:"I",\u012E:"I",\u0130:"I",\u0129:"i",\u012B:"i",\u012D:"i",\u012F:"i",\u0131:"i",\u0134:"J",\u0135:"j",\u0136:"K",\u0137:"k",\u0138:"k",\u0139:"L",\u013B:"L",\u013D:"L",\u013F:"L",\u0141:"L",\u013A:"l",\u013C:"l",\u013E:"l",\u0140:"l",\u0142:"l",\u0143:"N",\u0145:"N",\u0147:"N",\u014A:"N",\u0144:"n",\u0146:"n",\u0148:"n",\u014B:"n",\u014C:"O",\u014E:"O",\u0150:"O",\u014D:"o",\u014F:"o",\u0151:"o",\u0154:"R",\u0156:"R",\u0158:"R",\u0155:"r",\u0157:"r",\u0159:"r",\u015A:"S",\u015C:"S",\u015E:"S",\u0160:"S",\u015B:"s",\u015D:"s",\u015F:"s",\u0161:"s",\u0162:"T",\u0164:"T",\u0166:"T",\u0163:"t",\u0165:"t",\u0167:"t",\u0168:"U",\u016A:"U",\u016C:"U",\u016E:"U",\u0170:"U",\u0172:"U",\u0169:"u",\u016B:"u",\u016D:"u",\u016F:"u",\u0171:"u",\u0173:"u",\u0174:"W",\u0175:"w",\u0176:"Y",\u0177:"y",\u0178:"Y",\u0179:"Z",\u017B:"Z",\u017D:"Z",\u017A:"z",\u017C:"z",\u017E:"z",\u0132:"IJ",\u0133:"ij",\u0152:"Oe",\u0153:"oe",\u0149:"'n",\u017F:"s"},xYe=vYe(SYe);Hre.exports=xYe});var Yre=E((Mdt,jre)=>{var kYe=Gre(),PYe=gg(),DYe=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,RYe="\\u0300-\\u036f",FYe="\\ufe20-\\ufe2f",NYe="\\u20d0-\\u20ff",LYe=RYe+FYe+NYe,TYe="["+LYe+"]",MYe=RegExp(TYe,"g");function OYe(t){return t=PYe(t),t&&t.replace(DYe,kYe).replace(MYe,"")}jre.exports=OYe});var Jre=E((Odt,qre)=>{var KYe=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function UYe(t){return t.match(KYe)||[]}qre.exports=UYe});var zre=E((Kdt,Wre)=>{var HYe=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function GYe(t){return HYe.test(t)}Wre.exports=GYe});var fie=E((Udt,Vre)=>{var _re="\\ud800-\\udfff",jYe="\\u0300-\\u036f",YYe="\\ufe20-\\ufe2f",qYe="\\u20d0-\\u20ff",JYe=jYe+YYe+qYe,Xre="\\u2700-\\u27bf",Zre="a-z\\xdf-\\xf6\\xf8-\\xff",WYe="\\xac\\xb1\\xd7\\xf7",zYe="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",VYe="\\u2000-\\u206f",_Ye=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",$re="A-Z\\xc0-\\xd6\\xd8-\\xde",XYe="\\ufe0e\\ufe0f",eie=WYe+zYe+VYe+_Ye,tie="['\u2019]",rie="["+eie+"]",ZYe="["+JYe+"]",iie="\\d+",$Ye="["+Xre+"]",nie="["+Zre+"]",sie="[^"+_re+eie+iie+Xre+Zre+$re+"]",eqe="\\ud83c[\\udffb-\\udfff]",tqe="(?:"+ZYe+"|"+eqe+")",rqe="[^"+_re+"]",oie="(?:\\ud83c[\\udde6-\\uddff]){2}",aie="[\\ud800-\\udbff][\\udc00-\\udfff]",$g="["+$re+"]",iqe="\\u200d",Aie="(?:"+nie+"|"+sie+")",nqe="(?:"+$g+"|"+sie+")",lie="(?:"+tie+"(?:d|ll|m|re|s|t|ve))?",cie="(?:"+tie+"(?:D|LL|M|RE|S|T|VE))?",uie=tqe+"?",gie="["+XYe+"]?",sqe="(?:"+iqe+"(?:"+[rqe,oie,aie].join("|")+")"+gie+uie+")*",oqe="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",aqe="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Aqe=gie+uie+sqe,lqe="(?:"+[$Ye,oie,aie].join("|")+")"+Aqe,cqe=RegExp([$g+"?"+nie+"+"+lie+"(?="+[rie,$g,"$"].join("|")+")",nqe+"+"+cie+"(?="+[rie,$g+Aie,"$"].join("|")+")",$g+"?"+Aie+"+"+lie,$g+"+"+cie,aqe,oqe,iie,lqe].join("|"),"g");function uqe(t){return t.match(cqe)||[]}Vre.exports=uqe});var pie=E((Hdt,hie)=>{var gqe=Jre(),fqe=zre(),hqe=gg(),pqe=fie();function dqe(t,e,r){return t=hqe(t),e=r?void 0:e,e===void 0?fqe(t)?pqe(t):gqe(t):t.match(e)||[]}hie.exports=dqe});var rN=E((Gdt,die)=>{var Cqe=Ore(),mqe=Yre(),Eqe=pie(),Iqe="['\u2019]",yqe=RegExp(Iqe,"g");function wqe(t){return function(e){return Cqe(Eqe(mqe(e).replace(yqe,"")),t,"")}}die.exports=wqe});var mie=E((jdt,Cie)=>{var Bqe=rN(),Qqe=Bqe(function(t,e,r){return t+(r?"_":"")+e.toLowerCase()});Cie.exports=Qqe});var Iie=E((Ydt,Eie)=>{var bqe=ZP(),vqe=rN(),Sqe=vqe(function(t,e,r){return e=e.toLowerCase(),t+(r?bqe(e):e)});Eie.exports=Sqe});var wie=E((qdt,yie)=>{var xqe=jg(),kqe=SF(),Pqe=jF();function Dqe(t,e){var r={};return e=Pqe(e,3),kqe(t,function(i,n,s){xqe(r,e(i,n,s),i)}),r}yie.exports=Dqe});var Qie=E((Jdt,iN)=>{iN.exports=function(t){return Bie(Rqe(t),t)};iN.exports.array=Bie;function Bie(t,e){var r=t.length,i=new Array(r),n={},s=r,o=Fqe(e),a=Nqe(t);for(e.forEach(function(c){if(!a.has(c[0])||!a.has(c[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});s--;)n[s]||l(t[s],s,new Set);return i;function l(c,u,g){if(g.has(c)){var f;try{f=", node was:"+JSON.stringify(c)}catch(d){f=""}throw new Error("Cyclic dependency"+f)}if(!a.has(c))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(c));if(!n[u]){n[u]=!0;var h=o.get(c)||new Set;if(h=Array.from(h),u=h.length){g.add(c);do{var p=h[--u];l(p,a.get(p),g)}while(u);g.delete(c)}i[--r]=c}}}function Rqe(t){for(var e=new Set,r=0,i=t.length;r{"use strict";Object.defineProperty(nN,"__esModule",{value:!0});nN.default=Lqe;var Tqe=k0(Ld()),Mqe=k0(Qie()),Oqe=Yd(),Kqe=k0(Dc()),Uqe=k0(qg());function k0(t){return t&&t.__esModule?t:{default:t}}function Lqe(t,e=[]){let r=[],i=[];function n(s,o){var a=(0,Oqe.split)(s)[0];~i.indexOf(a)||i.push(a),~e.indexOf(`${o}-${a}`)||r.push([o,a])}for(let s in t)if((0,Tqe.default)(t,s)){let o=t[s];~i.indexOf(s)||i.push(s),Kqe.default.isRef(o)&&o.isSibling?n(o.path,s):(0,Uqe.default)(o)&&"deps"in o&&o.deps.forEach(a=>n(a,s))}return Mqe.default.array(i,r).reverse()}});var Sie=E(sN=>{"use strict";Object.defineProperty(sN,"__esModule",{value:!0});sN.default=Hqe;function vie(t,e){let r=Infinity;return t.some((i,n)=>{var s;if(((s=e.path)==null?void 0:s.indexOf(i))!==-1)return r=n,!0}),r}function Hqe(t){return(e,r)=>vie(t,e)-vie(t,r)}});var Nie=E($d=>{"use strict";Object.defineProperty($d,"__esModule",{value:!0});$d.create=xie;$d.default=void 0;var kie=Fo(Ld()),Pie=Fo(mie()),Gqe=Fo(Iie()),jqe=Fo(wie()),Yqe=Fo(YF()),qqe=Yd(),Die=La(),Jqe=Fo(bie()),Rie=Fo(Sie()),Wqe=Fo(a0()),zqe=Fo(xc()),oN=Fo(Ma());function Fo(t){return t&&t.__esModule?t:{default:t}}function ef(){return ef=Object.assign||function(t){for(var e=1;eObject.prototype.toString.call(t)==="[object Object]";function Vqe(t,e){let r=Object.keys(t.fields);return Object.keys(e).filter(i=>r.indexOf(i)===-1)}var _qe=(0,Rie.default)([]),P0=class extends oN.default{constructor(e){super({type:"object"});this.fields=Object.create(null),this._sortErrors=_qe,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{this.transform(function(i){if(typeof i=="string")try{i=JSON.parse(i)}catch(n){i=null}return this.isType(i)?i:null}),e&&this.shape(e)})}_typeCheck(e){return Fie(e)||typeof e=="function"}_cast(e,r={}){var i;let n=super._cast(e,r);if(n===void 0)return this.getDefault();if(!this._typeCheck(n))return n;let s=this.fields,o=(i=r.stripUnknown)!=null?i:this.spec.noUnknown,a=this._nodes.concat(Object.keys(n).filter(g=>this._nodes.indexOf(g)===-1)),l={},c=ef({},r,{parent:l,__validating:r.__validating||!1}),u=!1;for(let g of a){let f=s[g],h=(0,kie.default)(n,g);if(f){let p,d=n[g];c.path=(r.path?`${r.path}.`:"")+g,f=f.resolve({value:d,context:r.context,parent:l});let m="spec"in f?f.spec:void 0,I=m==null?void 0:m.strict;if(m==null?void 0:m.strip){u=u||g in n;continue}p=!r.__validating||!I?f.cast(n[g],c):n[g],p!==void 0&&(l[g]=p)}else h&&!o&&(l[g]=n[g]);l[g]!==n[g]&&(u=!0)}return u?l:n}_validate(e,r={},i){let n=[],{sync:s,from:o=[],originalValue:a=e,abortEarly:l=this.spec.abortEarly,recursive:c=this.spec.recursive}=r;o=[{schema:this,value:a},...o],r.__validating=!0,r.originalValue=a,r.from=o,super._validate(e,r,(u,g)=>{if(u){if(!zqe.default.isError(u)||l)return void i(u,g);n.push(u)}if(!c||!Fie(g)){i(n[0]||null,g);return}a=a||g;let f=this._nodes.map(h=>(p,d)=>{let m=h.indexOf(".")===-1?(r.path?`${r.path}.`:"")+h:`${r.path||""}["${h}"]`,I=this.fields[h];if(I&&"validate"in I){I.validate(g[h],ef({},r,{path:m,from:o,strict:!0,parent:g,originalValue:a[h]}),d);return}d(null)});(0,Wqe.default)({sync:s,tests:f,value:g,errors:n,endEarly:l,sort:this._sortErrors,path:r.path},i)})}clone(e){let r=super.clone(e);return r.fields=ef({},this.fields),r._nodes=this._nodes,r._excludedEdges=this._excludedEdges,r._sortErrors=this._sortErrors,r}concat(e){let r=super.concat(e),i=r.fields;for(let[n,s]of Object.entries(this.fields)){let o=i[n];o===void 0?i[n]=s:o instanceof oN.default&&s instanceof oN.default&&(i[n]=s.concat(o))}return r.withMutation(()=>r.shape(i))}getDefaultFromShape(){let e={};return this._nodes.forEach(r=>{let i=this.fields[r];e[r]="default"in i?i.getDefault():void 0}),e}_getDefault(){if("default"in this.spec)return super._getDefault();if(!!this._nodes.length)return this.getDefaultFromShape()}shape(e,r=[]){let i=this.clone(),n=Object.assign(i.fields,e);if(i.fields=n,i._sortErrors=(0,Rie.default)(Object.keys(n)),r.length){Array.isArray(r[0])||(r=[r]);let s=r.map(([o,a])=>`${o}-${a}`);i._excludedEdges=i._excludedEdges.concat(s)}return i._nodes=(0,Jqe.default)(n,i._excludedEdges),i}pick(e){let r={};for(let i of e)this.fields[i]&&(r[i]=this.fields[i]);return this.clone().withMutation(i=>(i.fields={},i.shape(r)))}omit(e){let r=this.clone(),i=r.fields;r.fields={};for(let n of e)delete i[n];return r.withMutation(()=>r.shape(i))}from(e,r,i){let n=(0,qqe.getter)(e,!0);return this.transform(s=>{if(s==null)return s;let o=s;return(0,kie.default)(s,e)&&(o=ef({},s),i||delete o[e],o[r]=n(s)),o})}noUnknown(e=!0,r=Die.object.noUnknown){typeof e=="string"&&(r=e,e=!0);let i=this.test({name:"noUnknown",exclusive:!0,message:r,test(n){if(n==null)return!0;let s=Vqe(this.schema,n);return!e||s.length===0||this.createError({params:{unknown:s.join(", ")}})}});return i.spec.noUnknown=e,i}unknown(e=!0,r=Die.object.noUnknown){return this.noUnknown(!e,r)}transformKeys(e){return this.transform(r=>r&&(0,jqe.default)(r,(i,n)=>e(n)))}camelCase(){return this.transformKeys(Gqe.default)}snakeCase(){return this.transformKeys(Pie.default)}constantCase(){return this.transformKeys(e=>(0,Pie.default)(e).toUpperCase())}describe(){let e=super.describe();return e.fields=(0,Yqe.default)(this.fields,r=>r.describe()),e}};$d.default=P0;function xie(t){return new P0(t)}xie.prototype=P0.prototype});var Tie=E(eC=>{"use strict";Object.defineProperty(eC,"__esModule",{value:!0});eC.create=Lie;eC.default=void 0;var aN=tf(Zg()),Xqe=tf(qg()),Zqe=tf(Nd()),AN=La(),$qe=tf(a0()),eJe=tf(xc()),tJe=tf(Ma());function tf(t){return t&&t.__esModule?t:{default:t}}function D0(){return D0=Object.assign||function(t){for(var e=1;e{this.transform(function(r){if(typeof r=="string")try{r=JSON.parse(r)}catch(i){r=null}return this.isType(r)?r:null})})}_typeCheck(e){return Array.isArray(e)}get _subType(){return this.innerType}_cast(e,r){let i=super._cast(e,r);if(!this._typeCheck(i)||!this.innerType)return i;let n=!1,s=i.map((o,a)=>{let l=this.innerType.cast(o,D0({},r,{path:`${r.path||""}[${a}]`}));return l!==o&&(n=!0),l});return n?s:i}_validate(e,r={},i){var n,s;let o=[],a=r.sync,l=r.path,c=this.innerType,u=(n=r.abortEarly)!=null?n:this.spec.abortEarly,g=(s=r.recursive)!=null?s:this.spec.recursive,f=r.originalValue!=null?r.originalValue:e;super._validate(e,r,(h,p)=>{if(h){if(!eJe.default.isError(h)||u)return void i(h,p);o.push(h)}if(!g||!c||!this._typeCheck(p)){i(o[0]||null,p);return}f=f||p;let d=new Array(p.length);for(let m=0;mc.validate(I,b,H)}(0,$qe.default)({sync:a,path:l,value:p,errors:o,endEarly:u,tests:d},i)})}clone(e){let r=super.clone(e);return r.innerType=this.innerType,r}concat(e){let r=super.concat(e);return r.innerType=this.innerType,e.innerType&&(r.innerType=r.innerType?r.innerType.concat(e.innerType):e.innerType),r}of(e){let r=this.clone();if(!(0,Xqe.default)(e))throw new TypeError("`array.of()` sub-schema must be a valid yup schema not: "+(0,Zqe.default)(e));return r.innerType=e,r}length(e,r=AN.array.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:e},test(i){return(0,aN.default)(i)||i.length===this.resolve(e)}})}min(e,r){return r=r||AN.array.min,this.test({message:r,name:"min",exclusive:!0,params:{min:e},test(i){return(0,aN.default)(i)||i.length>=this.resolve(e)}})}max(e,r){return r=r||AN.array.max,this.test({message:r,name:"max",exclusive:!0,params:{max:e},test(i){return(0,aN.default)(i)||i.length<=this.resolve(e)}})}ensure(){return this.default(()=>[]).transform((e,r)=>this._typeCheck(e)?e:r==null?[]:[].concat(r))}compact(e){let r=e?(i,n,s)=>!e(i,n,s):i=>!!i;return this.transform(i=>i!=null?i.filter(r):i)}describe(){let e=super.describe();return this.innerType&&(e.innerType=this.innerType.describe()),e}nullable(e=!0){return super.nullable(e)}defined(){return super.defined()}required(e){return super.required(e)}};eC.default=R0;Lie.prototype=R0.prototype});var Mie=E(tC=>{"use strict";Object.defineProperty(tC,"__esModule",{value:!0});tC.create=rJe;tC.default=void 0;var nJe=iJe(qg());function iJe(t){return t&&t.__esModule?t:{default:t}}function rJe(t){return new lN(t)}var lN=class{constructor(e){this.type="lazy",this.__isYupSchema__=!0,this._resolve=(r,i={})=>{let n=this.builder(r,i);if(!(0,nJe.default)(n))throw new TypeError("lazy() functions must return a valid schema");return n.resolve(i)},this.builder=e}resolve(e){return this._resolve(e.value,e)}cast(e,r){return this._resolve(e,r).cast(e,r)}validate(e,r,i){return this._resolve(e,r).validate(e,r,i)}validateSync(e,r){return this._resolve(e,r).validateSync(e,r)}validateAt(e,r,i){return this._resolve(r,i).validateAt(e,r,i)}validateSyncAt(e,r,i){return this._resolve(r,i).validateSyncAt(e,r,i)}describe(){return null}isValid(e,r){return this._resolve(e,r).isValid(e,r)}isValidSync(e,r){return this._resolve(e,r).isValidSync(e,r)}},sJe=lN;tC.default=sJe});var Oie=E(cN=>{"use strict";Object.defineProperty(cN,"__esModule",{value:!0});cN.default=oJe;var AJe=aJe(La());function aJe(t){return t&&t.__esModule?t:{default:t}}function oJe(t){Object.keys(t).forEach(e=>{Object.keys(t[e]).forEach(r=>{AJe.default[e][r]=t[e][r]})})}});var gN=E(cr=>{"use strict";Object.defineProperty(cr,"__esModule",{value:!0});cr.addMethod=lJe;Object.defineProperty(cr,"MixedSchema",{enumerable:!0,get:function(){return Kie.default}});Object.defineProperty(cr,"mixed",{enumerable:!0,get:function(){return Kie.create}});Object.defineProperty(cr,"BooleanSchema",{enumerable:!0,get:function(){return uN.default}});Object.defineProperty(cr,"bool",{enumerable:!0,get:function(){return uN.create}});Object.defineProperty(cr,"boolean",{enumerable:!0,get:function(){return uN.create}});Object.defineProperty(cr,"StringSchema",{enumerable:!0,get:function(){return Uie.default}});Object.defineProperty(cr,"string",{enumerable:!0,get:function(){return Uie.create}});Object.defineProperty(cr,"NumberSchema",{enumerable:!0,get:function(){return Hie.default}});Object.defineProperty(cr,"number",{enumerable:!0,get:function(){return Hie.create}});Object.defineProperty(cr,"DateSchema",{enumerable:!0,get:function(){return Gie.default}});Object.defineProperty(cr,"date",{enumerable:!0,get:function(){return Gie.create}});Object.defineProperty(cr,"ObjectSchema",{enumerable:!0,get:function(){return jie.default}});Object.defineProperty(cr,"object",{enumerable:!0,get:function(){return jie.create}});Object.defineProperty(cr,"ArraySchema",{enumerable:!0,get:function(){return Yie.default}});Object.defineProperty(cr,"array",{enumerable:!0,get:function(){return Yie.create}});Object.defineProperty(cr,"ref",{enumerable:!0,get:function(){return cJe.create}});Object.defineProperty(cr,"lazy",{enumerable:!0,get:function(){return uJe.create}});Object.defineProperty(cr,"ValidationError",{enumerable:!0,get:function(){return gJe.default}});Object.defineProperty(cr,"reach",{enumerable:!0,get:function(){return fJe.default}});Object.defineProperty(cr,"isSchema",{enumerable:!0,get:function(){return qie.default}});Object.defineProperty(cr,"setLocale",{enumerable:!0,get:function(){return hJe.default}});Object.defineProperty(cr,"BaseSchema",{enumerable:!0,get:function(){return pJe.default}});var Kie=Nc(yre()),uN=Nc(vre()),Uie=Nc(kre()),Hie=Nc(Rre()),Gie=Nc(Tre()),jie=Nc(Nie()),Yie=Nc(Tie()),cJe=Dc(),uJe=Mie(),gJe=rC(xc()),fJe=rC(XF()),qie=rC(qg()),hJe=rC(Oie()),pJe=rC(Ma());function rC(t){return t&&t.__esModule?t:{default:t}}function Jie(){if(typeof WeakMap!="function")return null;var t=new WeakMap;return Jie=function(){return t},t}function Nc(t){if(t&&t.__esModule)return t;if(t===null||typeof t!="object"&&typeof t!="function")return{default:t};var e=Jie();if(e&&e.has(t))return e.get(t);var r={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n)){var s=i?Object.getOwnPropertyDescriptor(t,n):null;s&&(s.get||s.set)?Object.defineProperty(r,n,s):r[n]=t[n]}return r.default=t,e&&e.set(t,r),r}function lJe(t,e,r){if(!t||!(0,qie.default)(t.prototype))throw new TypeError("You must provide a yup schema constructor function");if(typeof e!="string")throw new TypeError("A Method name must be provided");if(typeof r!="function")throw new TypeError("Method function must be provided");t.prototype[e]=r}});var Xie=E((gCt,nC)=>{"use strict";var mJe=process.env.TERM_PROGRAM==="Hyper",EJe=process.platform==="win32",zie=process.platform==="linux",fN={ballotDisabled:"\u2612",ballotOff:"\u2610",ballotOn:"\u2611",bullet:"\u2022",bulletWhite:"\u25E6",fullBlock:"\u2588",heart:"\u2764",identicalTo:"\u2261",line:"\u2500",mark:"\u203B",middot:"\xB7",minus:"\uFF0D",multiplication:"\xD7",obelus:"\xF7",pencilDownRight:"\u270E",pencilRight:"\u270F",pencilUpRight:"\u2710",percent:"%",pilcrow2:"\u2761",pilcrow:"\xB6",plusMinus:"\xB1",section:"\xA7",starsOff:"\u2606",starsOn:"\u2605",upDownArrow:"\u2195"},Vie=Object.assign({},fN,{check:"\u221A",cross:"\xD7",ellipsisLarge:"...",ellipsis:"...",info:"i",question:"?",questionSmall:"?",pointer:">",pointerSmall:"\xBB",radioOff:"( )",radioOn:"(*)",warning:"\u203C"}),_ie=Object.assign({},fN,{ballotCross:"\u2718",check:"\u2714",cross:"\u2716",ellipsisLarge:"\u22EF",ellipsis:"\u2026",info:"\u2139",question:"?",questionFull:"\uFF1F",questionSmall:"\uFE56",pointer:zie?"\u25B8":"\u276F",pointerSmall:zie?"\u2023":"\u203A",radioOff:"\u25EF",radioOn:"\u25C9",warning:"\u26A0"});nC.exports=EJe&&!mJe?Vie:_ie;Reflect.defineProperty(nC.exports,"common",{enumerable:!1,value:fN});Reflect.defineProperty(nC.exports,"windows",{enumerable:!1,value:Vie});Reflect.defineProperty(nC.exports,"other",{enumerable:!1,value:_ie})});var js=E((fCt,hN)=>{"use strict";var IJe=t=>t!==null&&typeof t=="object"&&!Array.isArray(t),yJe=/[\u001b\u009b][[\]#;?()]*(?:(?:(?:[^\W_]*;?[^\W_]*)\u0007)|(?:(?:[0-9]{1,4}(;[0-9]{0,4})*)?[~0-9=<>cf-nqrtyA-PRZ]))/g,Zie=()=>{let t={enabled:!0,visible:!0,styles:{},keys:{}};"FORCE_COLOR"in process.env&&(t.enabled=process.env.FORCE_COLOR!=="0");let e=s=>{let o=s.open=`[${s.codes[0]}m`,a=s.close=`[${s.codes[1]}m`,l=s.regex=new RegExp(`\\u001b\\[${s.codes[1]}m`,"g");return s.wrap=(c,u)=>{c.includes(a)&&(c=c.replace(l,a+o));let g=o+c+a;return u?g.replace(/\r*\n/g,`${a}$&${o}`):g},s},r=(s,o,a)=>typeof s=="function"?s(o):s.wrap(o,a),i=(s,o)=>{if(s===""||s==null)return"";if(t.enabled===!1)return s;if(t.visible===!1)return"";let a=""+s,l=a.includes(` +`),c=o.length;for(c>0&&o.includes("unstyle")&&(o=[...new Set(["unstyle",...o])].reverse());c-- >0;)a=r(t.styles[o[c]],a,l);return a},n=(s,o,a)=>{t.styles[s]=e({name:s,codes:o}),(t.keys[a]||(t.keys[a]=[])).push(s),Reflect.defineProperty(t,s,{configurable:!0,enumerable:!0,set(c){t.alias(s,c)},get(){let c=u=>i(u,c.stack);return Reflect.setPrototypeOf(c,t),c.stack=this.stack?this.stack.concat(s):[s],c}})};return n("reset",[0,0],"modifier"),n("bold",[1,22],"modifier"),n("dim",[2,22],"modifier"),n("italic",[3,23],"modifier"),n("underline",[4,24],"modifier"),n("inverse",[7,27],"modifier"),n("hidden",[8,28],"modifier"),n("strikethrough",[9,29],"modifier"),n("black",[30,39],"color"),n("red",[31,39],"color"),n("green",[32,39],"color"),n("yellow",[33,39],"color"),n("blue",[34,39],"color"),n("magenta",[35,39],"color"),n("cyan",[36,39],"color"),n("white",[37,39],"color"),n("gray",[90,39],"color"),n("grey",[90,39],"color"),n("bgBlack",[40,49],"bg"),n("bgRed",[41,49],"bg"),n("bgGreen",[42,49],"bg"),n("bgYellow",[43,49],"bg"),n("bgBlue",[44,49],"bg"),n("bgMagenta",[45,49],"bg"),n("bgCyan",[46,49],"bg"),n("bgWhite",[47,49],"bg"),n("blackBright",[90,39],"bright"),n("redBright",[91,39],"bright"),n("greenBright",[92,39],"bright"),n("yellowBright",[93,39],"bright"),n("blueBright",[94,39],"bright"),n("magentaBright",[95,39],"bright"),n("cyanBright",[96,39],"bright"),n("whiteBright",[97,39],"bright"),n("bgBlackBright",[100,49],"bgBright"),n("bgRedBright",[101,49],"bgBright"),n("bgGreenBright",[102,49],"bgBright"),n("bgYellowBright",[103,49],"bgBright"),n("bgBlueBright",[104,49],"bgBright"),n("bgMagentaBright",[105,49],"bgBright"),n("bgCyanBright",[106,49],"bgBright"),n("bgWhiteBright",[107,49],"bgBright"),t.ansiRegex=yJe,t.hasColor=t.hasAnsi=s=>(t.ansiRegex.lastIndex=0,typeof s=="string"&&s!==""&&t.ansiRegex.test(s)),t.alias=(s,o)=>{let a=typeof o=="string"?t[o]:o;if(typeof a!="function")throw new TypeError("Expected alias to be the name of an existing color (string) or a function");a.stack||(Reflect.defineProperty(a,"name",{value:s}),t.styles[s]=a,a.stack=[s]),Reflect.defineProperty(t,s,{configurable:!0,enumerable:!0,set(l){t.alias(s,l)},get(){let l=c=>i(c,l.stack);return Reflect.setPrototypeOf(l,t),l.stack=this.stack?this.stack.concat(a.stack):a.stack,l}})},t.theme=s=>{if(!IJe(s))throw new TypeError("Expected theme to be an object");for(let o of Object.keys(s))t.alias(o,s[o]);return t},t.alias("unstyle",s=>typeof s=="string"&&s!==""?(t.ansiRegex.lastIndex=0,s.replace(t.ansiRegex,"")):""),t.alias("noop",s=>s),t.none=t.clear=t.noop,t.stripColor=t.unstyle,t.symbols=Xie(),t.define=n,t};hN.exports=Zie();hN.exports.create=Zie});var Mi=E(bt=>{"use strict";var wJe=Object.prototype.toString,Cs=js(),$ie=!1,pN=[],ene={yellow:"blue",cyan:"red",green:"magenta",black:"white",blue:"yellow",red:"cyan",magenta:"green",white:"black"};bt.longest=(t,e)=>t.reduce((r,i)=>Math.max(r,e?i[e].length:i.length),0);bt.hasColor=t=>!!t&&Cs.hasColor(t);var N0=bt.isObject=t=>t!==null&&typeof t=="object"&&!Array.isArray(t);bt.nativeType=t=>wJe.call(t).slice(8,-1).toLowerCase().replace(/\s/g,"");bt.isAsyncFn=t=>bt.nativeType(t)==="asyncfunction";bt.isPrimitive=t=>t!=null&&typeof t!="object"&&typeof t!="function";bt.resolve=(t,e,...r)=>typeof e=="function"?e.call(t,...r):e;bt.scrollDown=(t=[])=>[...t.slice(1),t[0]];bt.scrollUp=(t=[])=>[t.pop(),...t];bt.reorder=(t=[])=>{let e=t.slice();return e.sort((r,i)=>r.index>i.index?1:r.index{let i=t.length,n=r===i?0:r<0?i-1:r,s=t[e];t[e]=t[n],t[n]=s};bt.width=(t,e=80)=>{let r=t&&t.columns?t.columns:e;return t&&typeof t.getWindowSize=="function"&&(r=t.getWindowSize()[0]),process.platform==="win32"?r-1:r};bt.height=(t,e=20)=>{let r=t&&t.rows?t.rows:e;return t&&typeof t.getWindowSize=="function"&&(r=t.getWindowSize()[1]),r};bt.wordWrap=(t,e={})=>{if(!t)return t;typeof e=="number"&&(e={width:e});let{indent:r="",newline:i=` +`+r,width:n=80}=e;n-=((i+r).match(/[^\S\n]/g)||[]).length;let o=`.{1,${n}}([\\s\\u200B]+|$)|[^\\s\\u200B]+?([\\s\\u200B]+|$)`,a=t.trim(),l=new RegExp(o,"g"),c=a.match(l)||[];return c=c.map(u=>u.replace(/\n$/,"")),e.padEnd&&(c=c.map(u=>u.padEnd(n," "))),e.padStart&&(c=c.map(u=>u.padStart(n," "))),r+c.join(i)};bt.unmute=t=>{let e=t.stack.find(i=>Cs.keys.color.includes(i));return e?Cs[e]:t.stack.find(i=>i.slice(2)==="bg")?Cs[e.slice(2)]:i=>i};bt.pascal=t=>t?t[0].toUpperCase()+t.slice(1):"";bt.inverse=t=>{if(!t||!t.stack)return t;let e=t.stack.find(i=>Cs.keys.color.includes(i));if(e){let i=Cs["bg"+bt.pascal(e)];return i?i.black:t}let r=t.stack.find(i=>i.slice(0,2)==="bg");return r?Cs[r.slice(2).toLowerCase()]||t:Cs.none};bt.complement=t=>{if(!t||!t.stack)return t;let e=t.stack.find(i=>Cs.keys.color.includes(i)),r=t.stack.find(i=>i.slice(0,2)==="bg");if(e&&!r)return Cs[ene[e]||e];if(r){let i=r.slice(2).toLowerCase(),n=ene[i];return n&&Cs["bg"+bt.pascal(n)]||t}return Cs.none};bt.meridiem=t=>{let e=t.getHours(),r=t.getMinutes(),i=e>=12?"pm":"am";e=e%12;let n=e===0?12:e,s=r<10?"0"+r:r;return n+":"+s+" "+i};bt.set=(t={},e="",r)=>e.split(".").reduce((i,n,s,o)=>{let a=o.length-1>s?i[n]||{}:r;return!bt.isObject(a)&&s{let i=t[e]==null?e.split(".").reduce((n,s)=>n&&n[s],t):t[e];return i==null?r:i};bt.mixin=(t,e)=>{if(!N0(t))return e;if(!N0(e))return t;for(let r of Object.keys(e)){let i=Object.getOwnPropertyDescriptor(e,r);if(i.hasOwnProperty("value"))if(t.hasOwnProperty(r)&&N0(i.value)){let n=Object.getOwnPropertyDescriptor(t,r);N0(n.value)?t[r]=bt.merge({},t[r],e[r]):Reflect.defineProperty(t,r,i)}else Reflect.defineProperty(t,r,i);else Reflect.defineProperty(t,r,i)}return t};bt.merge=(...t)=>{let e={};for(let r of t)bt.mixin(e,r);return e};bt.mixinEmitter=(t,e)=>{let r=e.constructor.prototype;for(let i of Object.keys(r)){let n=r[i];typeof n=="function"?bt.define(t,i,n.bind(e)):bt.define(t,i,n)}};bt.onExit=t=>{let e=(r,i)=>{$ie||($ie=!0,pN.forEach(n=>n()),r===!0&&process.exit(128+i))};pN.length===0&&(process.once("SIGTERM",e.bind(null,!0,15)),process.once("SIGINT",e.bind(null,!0,2)),process.once("exit",e)),pN.push(t)};bt.define=(t,e,r)=>{Reflect.defineProperty(t,e,{value:r})};bt.defineExport=(t,e,r)=>{let i;Reflect.defineProperty(t,e,{enumerable:!0,configurable:!0,set(n){i=n},get(){return i?i():r()}})}});var tne=E(nf=>{"use strict";nf.ctrl={a:"first",b:"backward",c:"cancel",d:"deleteForward",e:"last",f:"forward",g:"reset",i:"tab",k:"cutForward",l:"reset",n:"newItem",m:"cancel",j:"submit",p:"search",r:"remove",s:"save",u:"undo",w:"cutLeft",x:"toggleCursor",v:"paste"};nf.shift={up:"shiftUp",down:"shiftDown",left:"shiftLeft",right:"shiftRight",tab:"prev"};nf.fn={up:"pageUp",down:"pageDown",left:"pageLeft",right:"pageRight",delete:"deleteForward"};nf.option={b:"backward",f:"forward",d:"cutRight",left:"cutLeft",up:"altUp",down:"altDown"};nf.keys={pageup:"pageUp",pagedown:"pageDown",home:"home",end:"end",cancel:"cancel",delete:"deleteForward",backspace:"delete",down:"down",enter:"submit",escape:"cancel",left:"left",space:"space",number:"number",return:"submit",right:"right",tab:"next",up:"up"}});var nne=E((dCt,rne)=>{"use strict";var ine=require("readline"),BJe=tne(),QJe=/^(?:\x1b)([a-zA-Z0-9])$/,bJe=/^(?:\x1b+)(O|N|\[|\[\[)(?:(\d+)(?:;(\d+))?([~^$])|(?:1;)?(\d+)?([a-zA-Z]))/,vJe={OP:"f1",OQ:"f2",OR:"f3",OS:"f4","[11~":"f1","[12~":"f2","[13~":"f3","[14~":"f4","[[A":"f1","[[B":"f2","[[C":"f3","[[D":"f4","[[E":"f5","[15~":"f5","[17~":"f6","[18~":"f7","[19~":"f8","[20~":"f9","[21~":"f10","[23~":"f11","[24~":"f12","[A":"up","[B":"down","[C":"right","[D":"left","[E":"clear","[F":"end","[H":"home",OA:"up",OB:"down",OC:"right",OD:"left",OE:"clear",OF:"end",OH:"home","[1~":"home","[2~":"insert","[3~":"delete","[4~":"end","[5~":"pageup","[6~":"pagedown","[[5~":"pageup","[[6~":"pagedown","[7~":"home","[8~":"end","[a":"up","[b":"down","[c":"right","[d":"left","[e":"clear","[2$":"insert","[3$":"delete","[5$":"pageup","[6$":"pagedown","[7$":"home","[8$":"end",Oa:"up",Ob:"down",Oc:"right",Od:"left",Oe:"clear","[2^":"insert","[3^":"delete","[5^":"pageup","[6^":"pagedown","[7^":"home","[8^":"end","[Z":"tab"};function SJe(t){return["[a","[b","[c","[d","[e","[2$","[3$","[5$","[6$","[7$","[8$","[Z"].includes(t)}function xJe(t){return["Oa","Ob","Oc","Od","Oe","[2^","[3^","[5^","[6^","[7^","[8^"].includes(t)}var L0=(t="",e={})=>{let r,i=P({name:e.name,ctrl:!1,meta:!1,shift:!1,option:!1,sequence:t,raw:t},e);if(Buffer.isBuffer(t)?t[0]>127&&t[1]===void 0?(t[0]-=128,t=""+String(t)):t=String(t):t!==void 0&&typeof t!="string"?t=String(t):t||(t=i.sequence||""),i.sequence=i.sequence||t||i.name,t==="\r")i.raw=void 0,i.name="return";else if(t===` +`)i.name="enter";else if(t===" ")i.name="tab";else if(t==="\b"||t==="\x7F"||t==="\x7F"||t==="\b")i.name="backspace",i.meta=t.charAt(0)==="";else if(t===""||t==="")i.name="escape",i.meta=t.length===2;else if(t===" "||t===" ")i.name="space",i.meta=t.length===2;else if(t<="")i.name=String.fromCharCode(t.charCodeAt(0)+"a".charCodeAt(0)-1),i.ctrl=!0;else if(t.length===1&&t>="0"&&t<="9")i.name="number";else if(t.length===1&&t>="a"&&t<="z")i.name=t;else if(t.length===1&&t>="A"&&t<="Z")i.name=t.toLowerCase(),i.shift=!0;else if(r=QJe.exec(t))i.meta=!0,i.shift=/^[A-Z]$/.test(r[1]);else if(r=bJe.exec(t)){let n=[...t];n[0]===""&&n[1]===""&&(i.option=!0);let s=[r[1],r[2],r[4],r[6]].filter(Boolean).join(""),o=(r[3]||r[5]||1)-1;i.ctrl=!!(o&4),i.meta=!!(o&10),i.shift=!!(o&1),i.code=s,i.name=vJe[s],i.shift=SJe(s)||i.shift,i.ctrl=xJe(s)||i.ctrl}return i};L0.listen=(t={},e)=>{let{stdin:r}=t;if(!r||r!==process.stdin&&!r.isTTY)throw new Error("Invalid stream passed");let i=ine.createInterface({terminal:!0,input:r});ine.emitKeypressEvents(r,i);let n=(a,l)=>e(a,L0(a,l),i),s=r.isRaw;return r.isTTY&&r.setRawMode(!0),r.on("keypress",n),i.resume(),()=>{r.isTTY&&r.setRawMode(s),r.removeListener("keypress",n),i.pause(),i.close()}};L0.action=(t,e,r)=>{let i=P(P({},BJe),r);return e.ctrl?(e.action=i.ctrl[e.name],e):e.option&&i.option?(e.action=i.option[e.name],e):e.shift?(e.action=i.shift[e.name],e):(e.action=i.keys[e.name],e)};rne.exports=L0});var one=E((CCt,sne)=>{"use strict";sne.exports=t=>{t.timers=t.timers||{};let e=t.options.timers;if(!!e)for(let r of Object.keys(e)){let i=e[r];typeof i=="number"&&(i={interval:i}),kJe(t,r,i)}};function kJe(t,e,r={}){let i=t.timers[e]={name:e,start:Date.now(),ms:0,tick:0},n=r.interval||120;i.frames=r.frames||[],i.loading=!0;let s=setInterval(()=>{i.ms=Date.now()-i.start,i.tick++,t.render()},n);return i.stop=()=>{i.loading=!1,clearInterval(s)},Reflect.defineProperty(i,"interval",{value:s}),t.once("close",()=>i.stop()),i.stop}});var lne=E((mCt,ane)=>{"use strict";var{define:PJe,width:DJe}=Mi(),Ane=class{constructor(e){let r=e.options;PJe(this,"_prompt",e),this.type=e.type,this.name=e.name,this.message="",this.header="",this.footer="",this.error="",this.hint="",this.input="",this.cursor=0,this.index=0,this.lines=0,this.tick=0,this.prompt="",this.buffer="",this.width=DJe(r.stdout||process.stdout),Object.assign(this,r),this.name=this.name||this.message,this.message=this.message||this.name,this.symbols=e.symbols,this.styles=e.styles,this.required=new Set,this.cancelled=!1,this.submitted=!1}clone(){let e=P({},this);return e.status=this.status,e.buffer=Buffer.from(e.buffer),delete e.clone,e}set color(e){this._color=e}get color(){let e=this.prompt.styles;if(this.cancelled)return e.cancelled;if(this.submitted)return e.submitted;let r=this._color||e[this.status];return typeof r=="function"?r:e.pending}set loading(e){this._loading=e}get loading(){return typeof this._loading=="boolean"?this._loading:this.loadingChoices?"choices":!1}get status(){return this.cancelled?"cancelled":this.submitted?"submitted":"pending"}};ane.exports=Ane});var une=E((ECt,cne)=>{"use strict";var dN=Mi(),yi=js(),CN={default:yi.noop,noop:yi.noop,set inverse(t){this._inverse=t},get inverse(){return this._inverse||dN.inverse(this.primary)},set complement(t){this._complement=t},get complement(){return this._complement||dN.complement(this.primary)},primary:yi.cyan,success:yi.green,danger:yi.magenta,strong:yi.bold,warning:yi.yellow,muted:yi.dim,disabled:yi.gray,dark:yi.dim.gray,underline:yi.underline,set info(t){this._info=t},get info(){return this._info||this.primary},set em(t){this._em=t},get em(){return this._em||this.primary.underline},set heading(t){this._heading=t},get heading(){return this._heading||this.muted.underline},set pending(t){this._pending=t},get pending(){return this._pending||this.primary},set submitted(t){this._submitted=t},get submitted(){return this._submitted||this.success},set cancelled(t){this._cancelled=t},get cancelled(){return this._cancelled||this.danger},set typing(t){this._typing=t},get typing(){return this._typing||this.dim},set placeholder(t){this._placeholder=t},get placeholder(){return this._placeholder||this.primary.dim},set highlight(t){this._highlight=t},get highlight(){return this._highlight||this.inverse}};CN.merge=(t={})=>{t.styles&&typeof t.styles.enabled=="boolean"&&(yi.enabled=t.styles.enabled),t.styles&&typeof t.styles.visible=="boolean"&&(yi.visible=t.styles.visible);let e=dN.merge({},CN,t.styles);delete e.merge;for(let r of Object.keys(yi))e.hasOwnProperty(r)||Reflect.defineProperty(e,r,{get:()=>yi[r]});for(let r of Object.keys(yi.styles))e.hasOwnProperty(r)||Reflect.defineProperty(e,r,{get:()=>yi[r]});return e};cne.exports=CN});var fne=E((ICt,gne)=>{"use strict";var mN=process.platform==="win32",Ka=js(),RJe=Mi(),EN=_(P({},Ka.symbols),{upDownDoubleArrow:"\u21D5",upDownDoubleArrow2:"\u2B0D",upDownArrow:"\u2195",asterisk:"*",asterism:"\u2042",bulletWhite:"\u25E6",electricArrow:"\u2301",ellipsisLarge:"\u22EF",ellipsisSmall:"\u2026",fullBlock:"\u2588",identicalTo:"\u2261",indicator:Ka.symbols.check,leftAngle:"\u2039",mark:"\u203B",minus:"\u2212",multiplication:"\xD7",obelus:"\xF7",percent:"%",pilcrow:"\xB6",pilcrow2:"\u2761",pencilUpRight:"\u2710",pencilDownRight:"\u270E",pencilRight:"\u270F",plus:"+",plusMinus:"\xB1",pointRight:"\u261E",rightAngle:"\u203A",section:"\xA7",hexagon:{off:"\u2B21",on:"\u2B22",disabled:"\u2B22"},ballot:{on:"\u2611",off:"\u2610",disabled:"\u2612"},stars:{on:"\u2605",off:"\u2606",disabled:"\u2606"},folder:{on:"\u25BC",off:"\u25B6",disabled:"\u25B6"},prefix:{pending:Ka.symbols.question,submitted:Ka.symbols.check,cancelled:Ka.symbols.cross},separator:{pending:Ka.symbols.pointerSmall,submitted:Ka.symbols.middot,cancelled:Ka.symbols.middot},radio:{off:mN?"( )":"\u25EF",on:mN?"(*)":"\u25C9",disabled:mN?"(|)":"\u24BE"},numbers:["\u24EA","\u2460","\u2461","\u2462","\u2463","\u2464","\u2465","\u2466","\u2467","\u2468","\u2469","\u246A","\u246B","\u246C","\u246D","\u246E","\u246F","\u2470","\u2471","\u2472","\u2473","\u3251","\u3252","\u3253","\u3254","\u3255","\u3256","\u3257","\u3258","\u3259","\u325A","\u325B","\u325C","\u325D","\u325E","\u325F","\u32B1","\u32B2","\u32B3","\u32B4","\u32B5","\u32B6","\u32B7","\u32B8","\u32B9","\u32BA","\u32BB","\u32BC","\u32BD","\u32BE","\u32BF"]});EN.merge=t=>{let e=RJe.merge({},Ka.symbols,EN,t.symbols);return delete e.merge,e};gne.exports=EN});var pne=E((yCt,hne)=>{"use strict";var FJe=une(),NJe=fne(),LJe=Mi();hne.exports=t=>{t.options=LJe.merge({},t.options.theme,t.options),t.symbols=NJe.merge(t.options),t.styles=FJe.merge(t.options)}});var Ine=E((dne,Cne)=>{"use strict";var mne=process.env.TERM_PROGRAM==="Apple_Terminal",TJe=js(),IN=Mi(),Ys=Cne.exports=dne,Ir="[",Ene="\x07",yN=!1,HA=Ys.code={bell:Ene,beep:Ene,beginning:`${Ir}G`,down:`${Ir}J`,esc:Ir,getPosition:`${Ir}6n`,hide:`${Ir}?25l`,line:`${Ir}2K`,lineEnd:`${Ir}K`,lineStart:`${Ir}1K`,restorePosition:Ir+(mne?"8":"u"),savePosition:Ir+(mne?"7":"s"),screen:`${Ir}2J`,show:`${Ir}?25h`,up:`${Ir}1J`},Lc=Ys.cursor={get hidden(){return yN},hide(){return yN=!0,HA.hide},show(){return yN=!1,HA.show},forward:(t=1)=>`${Ir}${t}C`,backward:(t=1)=>`${Ir}${t}D`,nextLine:(t=1)=>`${Ir}E`.repeat(t),prevLine:(t=1)=>`${Ir}F`.repeat(t),up:(t=1)=>t?`${Ir}${t}A`:"",down:(t=1)=>t?`${Ir}${t}B`:"",right:(t=1)=>t?`${Ir}${t}C`:"",left:(t=1)=>t?`${Ir}${t}D`:"",to(t,e){return e?`${Ir}${e+1};${t+1}H`:`${Ir}${t+1}G`},move(t=0,e=0){let r="";return r+=t<0?Lc.left(-t):t>0?Lc.right(t):"",r+=e<0?Lc.up(-e):e>0?Lc.down(e):"",r},restore(t={}){let{after:e,cursor:r,initial:i,input:n,prompt:s,size:o,value:a}=t;if(i=IN.isPrimitive(i)?String(i):"",n=IN.isPrimitive(n)?String(n):"",a=IN.isPrimitive(a)?String(a):"",o){let l=Ys.cursor.up(o)+Ys.cursor.to(s.length),c=n.length-r;return c>0&&(l+=Ys.cursor.left(c)),l}if(a||e){let l=!n&&!!i?-i.length:-n.length+r;return e&&(l-=e.length),n===""&&i&&!s.includes(i)&&(l+=i.length),Ys.cursor.move(l)}}},wN=Ys.erase={screen:HA.screen,up:HA.up,down:HA.down,line:HA.line,lineEnd:HA.lineEnd,lineStart:HA.lineStart,lines(t){let e="";for(let r=0;r{if(!e)return wN.line+Lc.to(0);let r=s=>[...TJe.unstyle(s)].length,i=t.split(/\r?\n/),n=0;for(let s of i)n+=1+Math.floor(Math.max(r(s)-1,0)/e);return(wN.line+Lc.prevLine()).repeat(n-1)+wN.line+Lc.to(0)}});var sf=E((wCt,yne)=>{"use strict";var MJe=require("events"),wne=js(),BN=nne(),OJe=one(),KJe=lne(),UJe=pne(),bn=Mi(),Tc=Ine(),T0=class extends MJe{constructor(e={}){super();this.name=e.name,this.type=e.type,this.options=e,UJe(this),OJe(this),this.state=new KJe(this),this.initial=[e.initial,e.default].find(r=>r!=null),this.stdout=e.stdout||process.stdout,this.stdin=e.stdin||process.stdin,this.scale=e.scale||1,this.term=this.options.term||process.env.TERM_PROGRAM,this.margin=GJe(this.options.margin),this.setMaxListeners(0),HJe(this)}async keypress(e,r={}){this.keypressed=!0;let i=BN.action(e,BN(e,r),this.options.actions);this.state.keypress=i,this.emit("keypress",e,i),this.emit("state",this.state.clone());let n=this.options[i.action]||this[i.action]||this.dispatch;if(typeof n=="function")return await n.call(this,e,i);this.alert()}alert(){delete this.state.alert,this.options.show===!1?this.emit("alert"):this.stdout.write(Tc.code.beep)}cursorHide(){this.stdout.write(Tc.cursor.hide()),bn.onExit(()=>this.cursorShow())}cursorShow(){this.stdout.write(Tc.cursor.show())}write(e){!e||(this.stdout&&this.state.show!==!1&&this.stdout.write(e),this.state.buffer+=e)}clear(e=0){let r=this.state.buffer;this.state.buffer="",!(!r&&!e||this.options.show===!1)&&this.stdout.write(Tc.cursor.down(e)+Tc.clear(r,this.width))}restore(){if(this.state.closed||this.options.show===!1)return;let{prompt:e,after:r,rest:i}=this.sections(),{cursor:n,initial:s="",input:o="",value:a=""}=this,l=this.state.size=i.length,c={after:r,cursor:n,initial:s,input:o,prompt:e,size:l,value:a},u=Tc.cursor.restore(c);u&&this.stdout.write(u)}sections(){let{buffer:e,input:r,prompt:i}=this.state;i=wne.unstyle(i);let n=wne.unstyle(e),s=n.indexOf(i),o=n.slice(0,s),l=n.slice(s).split(` +`),c=l[0],u=l[l.length-1],f=(i+(r?" "+r:"")).length,h=fe.call(this,this.value),this.result=()=>i.call(this,this.value),typeof r.initial=="function"&&(this.initial=await r.initial.call(this,this)),typeof r.onRun=="function"&&await r.onRun.call(this,this),typeof r.onSubmit=="function"){let n=r.onSubmit.bind(this),s=this.submit.bind(this);delete this.options.onSubmit,this.submit=async()=>(await n(this.name,this.value,this),s())}await this.start(),await this.render()}render(){throw new Error("expected prompt to have a custom render method")}run(){return new Promise(async(e,r)=>{if(this.once("submit",e),this.once("cancel",r),await this.skip())return this.render=()=>{},this.submit();await this.initialize(),this.emit("run")})}async element(e,r,i){let{options:n,state:s,symbols:o,timers:a}=this,l=a&&a[e];s.timer=l;let c=n[e]||s[e]||o[e],u=r&&r[e]!=null?r[e]:await c;if(u==="")return u;let g=await this.resolve(u,s,r,i);return!g&&r&&r[e]?this.resolve(c,s,r,i):g}async prefix(){let e=await this.element("prefix")||this.symbols,r=this.timers&&this.timers.prefix,i=this.state;return i.timer=r,bn.isObject(e)&&(e=e[i.status]||e.pending),bn.hasColor(e)?e:(this.styles[i.status]||this.styles.pending)(e)}async message(){let e=await this.element("message");return bn.hasColor(e)?e:this.styles.strong(e)}async separator(){let e=await this.element("separator")||this.symbols,r=this.timers&&this.timers.separator,i=this.state;i.timer=r;let n=e[i.status]||e.pending||i.separator,s=await this.resolve(n,i);return bn.isObject(s)&&(s=s[i.status]||s.pending),bn.hasColor(s)?s:this.styles.muted(s)}async pointer(e,r){let i=await this.element("pointer",e,r);if(typeof i=="string"&&bn.hasColor(i))return i;if(i){let n=this.styles,s=this.index===r,o=s?n.primary:c=>c,a=await this.resolve(i[s?"on":"off"]||i,this.state),l=bn.hasColor(a)?a:o(a);return s?l:" ".repeat(a.length)}}async indicator(e,r){let i=await this.element("indicator",e,r);if(typeof i=="string"&&bn.hasColor(i))return i;if(i){let n=this.styles,s=e.enabled===!0,o=s?n.success:n.dark,a=i[s?"on":"off"]||i;return bn.hasColor(a)?a:o(a)}return""}body(){return null}footer(){if(this.state.status==="pending")return this.element("footer")}header(){if(this.state.status==="pending")return this.element("header")}async hint(){if(this.state.status==="pending"&&!this.isValue(this.state.input)){let e=await this.element("hint");return bn.hasColor(e)?e:this.styles.muted(e)}}error(e){return this.state.submitted?"":e||this.state.error}format(e){return e}result(e){return e}validate(e){return this.options.required===!0?this.isValue(e):!0}isValue(e){return e!=null&&e!==""}resolve(e,...r){return bn.resolve(this,e,...r)}get base(){return T0.prototype}get style(){return this.styles[this.state.status]}get height(){return this.options.rows||bn.height(this.stdout,25)}get width(){return this.options.columns||bn.width(this.stdout,80)}get size(){return{width:this.width,height:this.height}}set cursor(e){this.state.cursor=e}get cursor(){return this.state.cursor}set input(e){this.state.input=e}get input(){return this.state.input}set value(e){this.state.value=e}get value(){let{input:e,value:r}=this.state,i=[r,e].find(this.isValue.bind(this));return this.isValue(i)?i:this.initial}static get prompt(){return e=>new this(e).run()}};function HJe(t){let e=n=>t[n]===void 0||typeof t[n]=="function",r=["actions","choices","initial","margin","roles","styles","symbols","theme","timers","value"],i=["body","footer","error","header","hint","indicator","message","prefix","separator","skip"];for(let n of Object.keys(t.options)){if(r.includes(n)||/^on[A-Z]/.test(n))continue;let s=t.options[n];typeof s=="function"&&e(n)?i.includes(n)||(t[n]=s.bind(t)):typeof t[n]!="function"&&(t[n]=s)}}function GJe(t){typeof t=="number"&&(t=[t,t,t,t]);let e=[].concat(t||[]),r=n=>n%2==0?` +`:" ",i=[];for(let n=0;n<4;n++){let s=r(n);e[n]?i.push(s.repeat(e[n])):i.push("")}return i}yne.exports=T0});var bne=E((BCt,Bne)=>{"use strict";var jJe=Mi(),Qne={default(t,e){return e},checkbox(t,e){throw new Error("checkbox role is not implemented yet")},editable(t,e){throw new Error("editable role is not implemented yet")},expandable(t,e){throw new Error("expandable role is not implemented yet")},heading(t,e){return e.disabled="",e.indicator=[e.indicator," "].find(r=>r!=null),e.message=e.message||"",e},input(t,e){throw new Error("input role is not implemented yet")},option(t,e){return Qne.default(t,e)},radio(t,e){throw new Error("radio role is not implemented yet")},separator(t,e){return e.disabled="",e.indicator=[e.indicator," "].find(r=>r!=null),e.message=e.message||t.symbols.line.repeat(5),e},spacer(t,e){return e}};Bne.exports=(t,e={})=>{let r=jJe.merge({},Qne,e.roles);return r[t]||r.default}});var sC=E((QCt,vne)=>{"use strict";var YJe=js(),qJe=sf(),JJe=bne(),M0=Mi(),{reorder:QN,scrollUp:WJe,scrollDown:zJe,isObject:Sne,swap:VJe}=M0,xne=class extends qJe{constructor(e){super(e);this.cursorHide(),this.maxSelected=e.maxSelected||Infinity,this.multiple=e.multiple||!1,this.initial=e.initial||0,this.delay=e.delay||0,this.longest=0,this.num=""}async initialize(){typeof this.options.initial=="function"&&(this.initial=await this.options.initial.call(this)),await this.reset(!0),await super.initialize()}async reset(){let{choices:e,initial:r,autofocus:i,suggest:n}=this.options;if(this.state._choices=[],this.state.choices=[],this.choices=await Promise.all(await this.toChoices(e)),this.choices.forEach(s=>s.enabled=!1),typeof n!="function"&&this.selectable.length===0)throw new Error("At least one choice must be selectable");Sne(r)&&(r=Object.keys(r)),Array.isArray(r)?(i!=null&&(this.index=this.findIndex(i)),r.forEach(s=>this.enable(this.find(s))),await this.render()):(i!=null&&(r=i),typeof r=="string"&&(r=this.findIndex(r)),typeof r=="number"&&r>-1&&(this.index=Math.max(0,Math.min(r,this.choices.length)),this.enable(this.find(this.index)))),this.isDisabled(this.focused)&&await this.down()}async toChoices(e,r){this.state.loadingChoices=!0;let i=[],n=0,s=async(o,a)=>{typeof o=="function"&&(o=await o.call(this)),o instanceof Promise&&(o=await o);for(let l=0;l(this.state.loadingChoices=!1,o))}async toChoice(e,r,i){if(typeof e=="function"&&(e=await e.call(this,this)),e instanceof Promise&&(e=await e),typeof e=="string"&&(e={name:e}),e.normalized)return e;e.normalized=!0;let n=e.value;if(e=JJe(e.role,this.options)(this,e),typeof e.disabled=="string"&&!e.hint&&(e.hint=e.disabled,e.disabled=!0),e.disabled===!0&&e.hint==null&&(e.hint="(disabled)"),e.index!=null)return e;e.name=e.name||e.key||e.title||e.value||e.message,e.message=e.message||e.name||"",e.value=[e.value,e.name].find(this.isValue.bind(this)),e.input="",e.index=r,e.cursor=0,M0.define(e,"parent",i),e.level=i?i.level+1:1,e.indent==null&&(e.indent=i?i.indent+" ":e.indent||""),e.path=i?i.path+"."+e.name:e.name,e.enabled=!!(this.multiple&&!this.isDisabled(e)&&(e.enabled||this.isSelected(e))),this.isDisabled(e)||(this.longest=Math.max(this.longest,YJe.unstyle(e.message).length));let o=P({},e);return e.reset=(a=o.input,l=o.value)=>{for(let c of Object.keys(o))e[c]=o[c];e.input=a,e.value=l},n==null&&typeof e.initial=="function"&&(e.input=await e.initial.call(this,this.state,e,r)),e}async onChoice(e,r){this.emit("choice",e,r,this),typeof e.onChoice=="function"&&await e.onChoice.call(this,this.state,e,r)}async addChoice(e,r,i){let n=await this.toChoice(e,r,i);return this.choices.push(n),this.index=this.choices.length-1,this.limit=this.choices.length,n}async newItem(e,r,i){let n=P({name:"New choice name?",editable:!0,newChoice:!0},e),s=await this.addChoice(n,r,i);return s.updateChoice=()=>{delete s.newChoice,s.name=s.message=s.input,s.input="",s.cursor=0},this.render()}indent(e){return e.indent==null?e.level>1?" ".repeat(e.level-1):"":e.indent}dispatch(e,r){if(this.multiple&&this[r.name])return this[r.name]();this.alert()}focus(e,r){return typeof r!="boolean"&&(r=e.enabled),r&&!e.enabled&&this.selected.length>=this.maxSelected?this.alert():(this.index=e.index,e.enabled=r&&!this.isDisabled(e),e)}space(){return this.multiple?(this.toggle(this.focused),this.render()):this.alert()}a(){if(this.maxSelectedr.enabled);return this.choices.forEach(r=>r.enabled=!e),this.render()}i(){return this.choices.length-this.selected.length>this.maxSelected?this.alert():(this.choices.forEach(e=>e.enabled=!e.enabled),this.render())}g(e=this.focused){return this.choices.some(r=>!!r.parent)?(this.toggle(e.parent&&!e.choices?e.parent:e),this.render()):this.a()}toggle(e,r){if(!e.enabled&&this.selected.length>=this.maxSelected)return this.alert();typeof r!="boolean"&&(r=!e.enabled),e.enabled=r,e.choices&&e.choices.forEach(n=>this.toggle(n,r));let i=e.parent;for(;i;){let n=i.choices.filter(s=>this.isDisabled(s));i.enabled=n.every(s=>s.enabled===!0),i=i.parent}return kne(this,this.choices),this.emit("toggle",e,this),e}enable(e){return this.selected.length>=this.maxSelected?this.alert():(e.enabled=!this.isDisabled(e),e.choices&&e.choices.forEach(this.enable.bind(this)),e)}disable(e){return e.enabled=!1,e.choices&&e.choices.forEach(this.disable.bind(this)),e}number(e){this.num+=e;let r=i=>{let n=Number(i);if(n>this.choices.length-1)return this.alert();let s=this.focused,o=this.choices.find(a=>n===a.index);if(!o.enabled&&this.selected.length>=this.maxSelected)return this.alert();if(this.visible.indexOf(o)===-1){let a=QN(this.choices),l=a.indexOf(o);if(s.index>l){let c=a.slice(l,l+this.limit),u=a.filter(g=>!c.includes(g));this.choices=c.concat(u)}else{let c=l-this.limit+1;this.choices=a.slice(c).concat(a.slice(0,c))}}return this.index=this.choices.indexOf(o),this.toggle(this.focused),this.render()};return clearTimeout(this.numberTimeout),new Promise(i=>{let n=this.choices.length,s=this.num,o=(a=!1,l)=>{clearTimeout(this.numberTimeout),a&&(l=r(s)),this.num="",i(l)};if(s==="0"||s.length===1&&Number(s+"0")>n)return o(!0);if(Number(s)>n)return o(!1,this.alert());this.numberTimeout=setTimeout(()=>o(!0),this.delay)})}home(){return this.choices=QN(this.choices),this.index=0,this.render()}end(){let e=this.choices.length-this.limit,r=QN(this.choices);return this.choices=r.slice(e).concat(r.slice(0,e)),this.index=this.limit-1,this.render()}first(){return this.index=0,this.render()}last(){return this.index=this.visible.length-1,this.render()}prev(){return this.visible.length<=1?this.alert():this.up()}next(){return this.visible.length<=1?this.alert():this.down()}right(){return this.cursor>=this.input.length?this.alert():(this.cursor++,this.render())}left(){return this.cursor<=0?this.alert():(this.cursor--,this.render())}up(){let e=this.choices.length,r=this.visible.length,i=this.index;return this.options.scroll===!1&&i===0?this.alert():e>r&&i===0?this.scrollUp():(this.index=(i-1%e+e)%e,this.isDisabled()?this.up():this.render())}down(){let e=this.choices.length,r=this.visible.length,i=this.index;return this.options.scroll===!1&&i===r-1?this.alert():e>r&&i===r-1?this.scrollDown():(this.index=(i+1)%e,this.isDisabled()?this.down():this.render())}scrollUp(e=0){return this.choices=WJe(this.choices),this.index=e,this.isDisabled()?this.up():this.render()}scrollDown(e=this.visible.length-1){return this.choices=zJe(this.choices),this.index=e,this.isDisabled()?this.down():this.render()}async shiftUp(){if(this.options.sort===!0){this.sorting=!0,this.swap(this.index-1),await this.up(),this.sorting=!1;return}return this.scrollUp(this.index)}async shiftDown(){if(this.options.sort===!0){this.sorting=!0,this.swap(this.index+1),await this.down(),this.sorting=!1;return}return this.scrollDown(this.index)}pageUp(){return this.visible.length<=1?this.alert():(this.limit=Math.max(this.limit-1,0),this.index=Math.min(this.limit-1,this.index),this._limit=this.limit,this.isDisabled()?this.up():this.render())}pageDown(){return this.visible.length>=this.choices.length?this.alert():(this.index=Math.max(0,this.index),this.limit=Math.min(this.limit+1,this.choices.length),this._limit=this.limit,this.isDisabled()?this.down():this.render())}swap(e){VJe(this.choices,this.index,e)}isDisabled(e=this.focused){return e&&["disabled","collapsed","hidden","completing","readonly"].some(i=>e[i]===!0)?!0:e&&e.role==="heading"}isEnabled(e=this.focused){if(Array.isArray(e))return e.every(r=>this.isEnabled(r));if(e.choices){let r=e.choices.filter(i=>!this.isDisabled(i));return e.enabled&&r.every(i=>this.isEnabled(i))}return e.enabled&&!this.isDisabled(e)}isChoice(e,r){return e.name===r||e.index===Number(r)}isSelected(e){return Array.isArray(this.initial)?this.initial.some(r=>this.isChoice(e,r)):this.isChoice(e,this.initial)}map(e=[],r="value"){return[].concat(e||[]).reduce((i,n)=>(i[n]=this.find(n,r),i),{})}filter(e,r){let i=(a,l)=>[a.name,l].includes(e),n=typeof e=="function"?e:i,o=(this.options.multiple?this.state._choices:this.choices).filter(n);return r?o.map(a=>a[r]):o}find(e,r){if(Sne(e))return r?e[r]:e;let i=(o,a)=>[o.name,a].includes(e),n=typeof e=="function"?e:i,s=this.choices.find(n);if(s)return r?s[r]:s}findIndex(e){return this.choices.indexOf(this.find(e))}async submit(){let e=this.focused;if(!e)return this.alert();if(e.newChoice)return e.input?(e.updateChoice(),this.render()):this.alert();if(this.choices.some(o=>o.newChoice))return this.alert();let{reorder:r,sort:i}=this.options,n=this.multiple===!0,s=this.selected;return s===void 0?this.alert():(Array.isArray(s)&&r!==!1&&i!==!0&&(s=M0.reorder(s)),this.value=n?s.map(o=>o.name):s.name,super.submit())}set choices(e=[]){this.state._choices=this.state._choices||[],this.state.choices=e;for(let r of e)this.state._choices.some(i=>i.name===r.name)||this.state._choices.push(r);if(!this._initial&&this.options.initial){this._initial=!0;let r=this.initial;if(typeof r=="string"||typeof r=="number"){let i=this.find(r);i&&(this.initial=i.index,this.focus(i,!0))}}}get choices(){return kne(this,this.state.choices||[])}set visible(e){this.state.visible=e}get visible(){return(this.state.visible||this.choices).slice(0,this.limit)}set limit(e){this.state.limit=e}get limit(){let{state:e,options:r,choices:i}=this,n=e.limit||this._limit||r.limit||i.length;return Math.min(n,this.height)}set value(e){super.value=e}get value(){return typeof super.value!="string"&&super.value===this.initial?this.input:super.value}set index(e){this.state.index=e}get index(){return Math.max(0,this.state?this.state.index:0)}get enabled(){return this.filter(this.isEnabled.bind(this))}get focused(){let e=this.choices[this.index];return e&&this.state.submitted&&this.multiple!==!0&&(e.enabled=!0),e}get selectable(){return this.choices.filter(e=>!this.isDisabled(e))}get selected(){return this.multiple?this.enabled:this.focused}};function kne(t,e){if(e instanceof Promise)return e;if(typeof e=="function"){if(M0.isAsyncFn(e))return e;e=e.call(t,t)}for(let r of e){if(Array.isArray(r.choices)){let i=r.choices.filter(n=>!t.isDisabled(n));r.enabled=i.every(n=>n.enabled===!0)}t.isDisabled(r)===!0&&delete r.enabled}return e}vne.exports=xne});var GA=E((bCt,Pne)=>{"use strict";var _Je=sC(),bN=Mi(),Dne=class extends _Je{constructor(e){super(e);this.emptyError=this.options.emptyError||"No items were selected"}async dispatch(e,r){if(this.multiple)return this[r.name]?await this[r.name](e,r):await super.dispatch(e,r);this.alert()}separator(){if(this.options.separator)return super.separator();let e=this.styles.muted(this.symbols.ellipsis);return this.state.submitted?super.separator():e}pointer(e,r){return!this.multiple||this.options.pointer?super.pointer(e,r):""}indicator(e,r){return this.multiple?super.indicator(e,r):""}choiceMessage(e,r){let i=this.resolve(e.message,this.state,e,r);return e.role==="heading"&&!bN.hasColor(i)&&(i=this.styles.strong(i)),this.resolve(i,this.state,e,r)}choiceSeparator(){return":"}async renderChoice(e,r){await this.onChoice(e,r);let i=this.index===r,n=await this.pointer(e,r),s=await this.indicator(e,r)+(e.pad||""),o=await this.resolve(e.hint,this.state,e,r);o&&!bN.hasColor(o)&&(o=this.styles.muted(o));let a=this.indent(e),l=await this.choiceMessage(e,r),c=()=>[this.margin[3],a+n+s,l,this.margin[1],o].filter(Boolean).join(" ");return e.role==="heading"?c():e.disabled?(bN.hasColor(l)||(l=this.styles.disabled(l)),c()):(i&&(l=this.styles.em(l)),c())}async renderChoices(){if(this.state.loading==="choices")return this.styles.warning("Loading choices");if(this.state.submitted)return"";let e=this.visible.map(async(s,o)=>await this.renderChoice(s,o)),r=await Promise.all(e);r.length||r.push(this.styles.danger("No matching choices"));let i=this.margin[0]+r.join(` +`),n;return this.options.choicesHeader&&(n=await this.resolve(this.options.choicesHeader,this.state)),[n,i].filter(Boolean).join(` +`)}format(){return!this.state.submitted||this.state.cancelled?"":Array.isArray(this.selected)?this.selected.map(e=>this.styles.primary(e.name)).join(", "):this.styles.primary(this.selected.name)}async render(){let{submitted:e,size:r}=this.state,i="",n=await this.header(),s=await this.prefix(),o=await this.separator(),a=await this.message();this.options.promptLine!==!1&&(i=[s,a,o,""].join(" "),this.state.prompt=i);let l=await this.format(),c=await this.error()||await this.hint(),u=await this.renderChoices(),g=await this.footer();l&&(i+=l),c&&!i.includes(c)&&(i+=" "+c),e&&!l&&!u.trim()&&this.multiple&&this.emptyError!=null&&(i+=this.styles.danger(this.emptyError)),this.clear(r),this.write([n,i,u,g].filter(Boolean).join(` +`)),this.write(this.margin[2]),this.restore()}};Pne.exports=Dne});var Nne=E((vCt,Rne)=>{"use strict";var XJe=GA(),ZJe=(t,e)=>{let r=t.toLowerCase();return i=>{let s=i.toLowerCase().indexOf(r),o=e(i.slice(s,s+r.length));return s>=0?i.slice(0,s)+o+i.slice(s+r.length):i}},Fne=class extends XJe{constructor(e){super(e);this.cursorShow()}moveCursor(e){this.state.cursor+=e}dispatch(e){return this.append(e)}space(e){return this.options.multiple?super.space(e):this.append(e)}append(e){let{cursor:r,input:i}=this.state;return this.input=i.slice(0,r)+e+i.slice(r),this.moveCursor(1),this.complete()}delete(){let{cursor:e,input:r}=this.state;return r?(this.input=r.slice(0,e-1)+r.slice(e),this.moveCursor(-1),this.complete()):this.alert()}deleteForward(){let{cursor:e,input:r}=this.state;return r[e]===void 0?this.alert():(this.input=`${r}`.slice(0,e)+`${r}`.slice(e+1),this.complete())}number(e){return this.append(e)}async complete(){this.completing=!0,this.choices=await this.suggest(this.input,this.state._choices),this.state.limit=void 0,this.index=Math.min(Math.max(this.visible.length-1,0),this.index),await this.render(),this.completing=!1}suggest(e=this.input,r=this.state._choices){if(typeof this.options.suggest=="function")return this.options.suggest.call(this,e,r);let i=e.toLowerCase();return r.filter(n=>n.message.toLowerCase().includes(i))}pointer(){return""}format(){if(!this.focused)return this.input;if(this.options.multiple&&this.state.submitted)return this.selected.map(e=>this.styles.primary(e.message)).join(", ");if(this.state.submitted){let e=this.value=this.input=this.focused.value;return this.styles.primary(e)}return this.input}async render(){if(this.state.status!=="pending")return super.render();let e=this.options.highlight?this.options.highlight.bind(this):this.styles.placeholder,r=ZJe(this.input,e),i=this.choices;this.choices=i.map(n=>_(P({},n),{message:r(n.message)})),await super.render(),this.choices=i}submit(){return this.options.multiple&&(this.value=this.selected.map(e=>e.name)),super.submit()}};Rne.exports=Fne});var SN=E((SCt,Lne)=>{"use strict";var vN=Mi();Lne.exports=(t,e={})=>{t.cursorHide();let{input:r="",initial:i="",pos:n,showCursor:s=!0,color:o}=e,a=o||t.styles.placeholder,l=vN.inverse(t.styles.primary),c=d=>l(t.styles.black(d)),u=r,g=" ",f=c(g);if(t.blink&&t.blink.off===!0&&(c=d=>d,f=""),s&&n===0&&i===""&&r==="")return c(g);if(s&&n===0&&(r===i||r===""))return c(i[0])+a(i.slice(1));i=vN.isPrimitive(i)?`${i}`:"",r=vN.isPrimitive(r)?`${r}`:"";let h=i&&i.startsWith(r)&&i!==r,p=h?c(i[r.length]):f;if(n!==r.length&&s===!0&&(u=r.slice(0,n)+c(r[n])+r.slice(n+1),p=""),s===!1&&(p=""),h){let d=t.styles.unstyle(u+p);return u+p+a(i.slice(d.length))}return u+p}});var O0=E((xCt,Tne)=>{"use strict";var $Je=js(),e3e=GA(),t3e=SN(),Mne=class extends e3e{constructor(e){super(_(P({},e),{multiple:!0}));this.type="form",this.initial=this.options.initial,this.align=[this.options.align,"right"].find(r=>r!=null),this.emptyError="",this.values={}}async reset(e){return await super.reset(),e===!0&&(this._index=this.index),this.index=this._index,this.values={},this.choices.forEach(r=>r.reset&&r.reset()),this.render()}dispatch(e){return!!e&&this.append(e)}append(e){let r=this.focused;if(!r)return this.alert();let{cursor:i,input:n}=r;return r.value=r.input=n.slice(0,i)+e+n.slice(i),r.cursor++,this.render()}delete(){let e=this.focused;if(!e||e.cursor<=0)return this.alert();let{cursor:r,input:i}=e;return e.value=e.input=i.slice(0,r-1)+i.slice(r),e.cursor--,this.render()}deleteForward(){let e=this.focused;if(!e)return this.alert();let{cursor:r,input:i}=e;if(i[r]===void 0)return this.alert();let n=`${i}`.slice(0,r)+`${i}`.slice(r+1);return e.value=e.input=n,this.render()}right(){let e=this.focused;return e?e.cursor>=e.input.length?this.alert():(e.cursor++,this.render()):this.alert()}left(){let e=this.focused;return e?e.cursor<=0?this.alert():(e.cursor--,this.render()):this.alert()}space(e,r){return this.dispatch(e,r)}number(e,r){return this.dispatch(e,r)}next(){let e=this.focused;if(!e)return this.alert();let{initial:r,input:i}=e;return r&&r.startsWith(i)&&i!==r?(e.value=e.input=r,e.cursor=e.value.length,this.render()):super.next()}prev(){let e=this.focused;return e?e.cursor===0?super.prev():(e.value=e.input="",e.cursor=0,this.render()):this.alert()}separator(){return""}format(e){return this.state.submitted?"":super.format(e)}pointer(){return""}indicator(e){return e.input?"\u29BF":"\u2299"}async choiceSeparator(e,r){let i=await this.resolve(e.separator,this.state,e,r)||":";return i?" "+this.styles.disabled(i):""}async renderChoice(e,r){await this.onChoice(e,r);let{state:i,styles:n}=this,{cursor:s,initial:o="",name:a,hint:l,input:c=""}=e,{muted:u,submitted:g,primary:f,danger:h}=n,p=l,d=this.index===r,m=e.validate||(()=>!0),I=await this.choiceSeparator(e,r),B=e.message;this.align==="right"&&(B=B.padStart(this.longest+1," ")),this.align==="left"&&(B=B.padEnd(this.longest+1," "));let b=this.values[a]=c||o,R=c?"success":"dark";await m.call(e,b,this.state)!==!0&&(R="danger");let L=n[R](await this.indicator(e,r))+(e.pad||""),K=this.indent(e),J=()=>[K,L,B+I,c,p].filter(Boolean).join(" ");if(i.submitted)return B=$Je.unstyle(B),c=g(c),p="",J();if(e.format)c=await e.format.call(this,c,e,r);else{let ne=this.styles.muted;c=t3e(this,{input:c,initial:o,pos:s,showCursor:d,color:ne})}return this.isValue(c)||(c=this.styles.muted(this.symbols.ellipsis)),e.result&&(this.values[a]=await e.result.call(this,b,e,r)),d&&(B=f(B)),e.error?c+=(c?" ":"")+h(e.error.trim()):e.hint&&(c+=(c?" ":"")+u(e.hint.trim())),J()}async submit(){return this.value=this.values,super.base.submit.call(this)}};Tne.exports=Mne});var xN=E((kCt,One)=>{"use strict";var r3e=O0(),i3e=()=>{throw new Error("expected prompt to have a custom authenticate method")},Kne=(t=i3e)=>{class e extends r3e{constructor(i){super(i)}async submit(){this.value=await t.call(this,this.values,this.state),super.base.submit.call(this)}static create(i){return Kne(i)}}return e};One.exports=Kne()});var Gne=E((PCt,Une)=>{"use strict";var n3e=xN();function s3e(t,e){return t.username===this.options.username&&t.password===this.options.password}var Hne=(t=s3e)=>{let e=[{name:"username",message:"username"},{name:"password",message:"password",format(i){return this.options.showPassword?i:(this.state.submitted?this.styles.primary:this.styles.muted)(this.symbols.asterisk.repeat(i.length))}}];class r extends n3e.create(t){constructor(n){super(_(P({},n),{choices:e}))}static create(n){return Hne(n)}}return r};Une.exports=Hne()});var K0=E((DCt,jne)=>{"use strict";var o3e=sf(),{isPrimitive:a3e,hasColor:A3e}=Mi(),Yne=class extends o3e{constructor(e){super(e);this.cursorHide()}async initialize(){let e=await this.resolve(this.initial,this.state);this.input=await this.cast(e),await super.initialize()}dispatch(e){return this.isValue(e)?(this.input=e,this.submit()):this.alert()}format(e){let{styles:r,state:i}=this;return i.submitted?r.success(e):r.primary(e)}cast(e){return this.isTrue(e)}isTrue(e){return/^[ty1]/i.test(e)}isFalse(e){return/^[fn0]/i.test(e)}isValue(e){return a3e(e)&&(this.isTrue(e)||this.isFalse(e))}async hint(){if(this.state.status==="pending"){let e=await this.element("hint");return A3e(e)?e:this.styles.muted(e)}}async render(){let{input:e,size:r}=this.state,i=await this.prefix(),n=await this.separator(),s=await this.message(),o=this.styles.muted(this.default),a=[i,s,o,n].filter(Boolean).join(" ");this.state.prompt=a;let l=await this.header(),c=this.value=this.cast(e),u=await this.format(c),g=await this.error()||await this.hint(),f=await this.footer();g&&!a.includes(g)&&(u+=" "+g),a+=" "+u,this.clear(r),this.write([l,a,f].filter(Boolean).join(` +`)),this.restore()}set value(e){super.value=e}get value(){return this.cast(super.value)}};jne.exports=Yne});var Wne=E((RCt,qne)=>{"use strict";var l3e=K0(),Jne=class extends l3e{constructor(e){super(e);this.default=this.options.default||(this.initial?"(Y/n)":"(y/N)")}};qne.exports=Jne});var _ne=E((FCt,zne)=>{"use strict";var c3e=GA(),u3e=O0(),of=u3e.prototype,Vne=class extends c3e{constructor(e){super(_(P({},e),{multiple:!0}));this.align=[this.options.align,"left"].find(r=>r!=null),this.emptyError="",this.values={}}dispatch(e,r){let i=this.focused,n=i.parent||{};return!i.editable&&!n.editable&&(e==="a"||e==="i")?super[e]():of.dispatch.call(this,e,r)}append(e,r){return of.append.call(this,e,r)}delete(e,r){return of.delete.call(this,e,r)}space(e){return this.focused.editable?this.append(e):super.space()}number(e){return this.focused.editable?this.append(e):super.number(e)}next(){return this.focused.editable?of.next.call(this):super.next()}prev(){return this.focused.editable?of.prev.call(this):super.prev()}async indicator(e,r){let i=e.indicator||"",n=e.editable?i:super.indicator(e,r);return await this.resolve(n,this.state,e,r)||""}indent(e){return e.role==="heading"?"":e.editable?" ":" "}async renderChoice(e,r){return e.indent="",e.editable?of.renderChoice.call(this,e,r):super.renderChoice(e,r)}error(){return""}footer(){return this.state.error}async validate(){let e=!0;for(let r of this.choices){if(typeof r.validate!="function"||r.role==="heading")continue;let i=r.parent?this.value[r.parent.name]:this.value;if(r.editable?i=r.value===r.name?r.initial||"":r.value:this.isDisabled(r)||(i=r.enabled===!0),e=await r.validate(i,this.state),e!==!0)break}return e!==!0&&(this.state.error=typeof e=="string"?e:"Invalid Input"),e}submit(){if(this.focused.newChoice===!0)return super.submit();if(this.choices.some(e=>e.newChoice))return this.alert();this.value={};for(let e of this.choices){let r=e.parent?this.value[e.parent.name]:this.value;if(e.role==="heading"){this.value[e.name]={};continue}e.editable?r[e.name]=e.value===e.name?e.initial||"":e.value:this.isDisabled(e)||(r[e.name]=e.enabled===!0)}return this.base.submit.call(this)}};zne.exports=Vne});var Mc=E((NCt,Xne)=>{"use strict";var g3e=sf(),f3e=SN(),{isPrimitive:h3e}=Mi(),Zne=class extends g3e{constructor(e){super(e);this.initial=h3e(this.initial)?String(this.initial):"",this.initial&&this.cursorHide(),this.state.prevCursor=0,this.state.clipboard=[]}async keypress(e,r={}){let i=this.state.prevKeypress;return this.state.prevKeypress=r,this.options.multiline===!0&&r.name==="return"&&(!i||i.name!=="return")?this.append(` +`,r):super.keypress(e,r)}moveCursor(e){this.cursor+=e}reset(){return this.input=this.value="",this.cursor=0,this.render()}dispatch(e,r){if(!e||r.ctrl||r.code)return this.alert();this.append(e)}append(e){let{cursor:r,input:i}=this.state;this.input=`${i}`.slice(0,r)+e+`${i}`.slice(r),this.moveCursor(String(e).length),this.render()}insert(e){this.append(e)}delete(){let{cursor:e,input:r}=this.state;if(e<=0)return this.alert();this.input=`${r}`.slice(0,e-1)+`${r}`.slice(e),this.moveCursor(-1),this.render()}deleteForward(){let{cursor:e,input:r}=this.state;if(r[e]===void 0)return this.alert();this.input=`${r}`.slice(0,e)+`${r}`.slice(e+1),this.render()}cutForward(){let e=this.cursor;if(this.input.length<=e)return this.alert();this.state.clipboard.push(this.input.slice(e)),this.input=this.input.slice(0,e),this.render()}cutLeft(){let e=this.cursor;if(e===0)return this.alert();let r=this.input.slice(0,e),i=this.input.slice(e),n=r.split(" ");this.state.clipboard.push(n.pop()),this.input=n.join(" "),this.cursor=this.input.length,this.input+=i,this.render()}paste(){if(!this.state.clipboard.length)return this.alert();this.insert(this.state.clipboard.pop()),this.render()}toggleCursor(){this.state.prevCursor?(this.cursor=this.state.prevCursor,this.state.prevCursor=0):(this.state.prevCursor=this.cursor,this.cursor=0),this.render()}first(){this.cursor=0,this.render()}last(){this.cursor=this.input.length-1,this.render()}next(){let e=this.initial!=null?String(this.initial):"";if(!e||!e.startsWith(this.input))return this.alert();this.input=this.initial,this.cursor=this.initial.length,this.render()}prev(){if(!this.input)return this.alert();this.reset()}backward(){return this.left()}forward(){return this.right()}right(){return this.cursor>=this.input.length?this.alert():(this.moveCursor(1),this.render())}left(){return this.cursor<=0?this.alert():(this.moveCursor(-1),this.render())}isValue(e){return!!e}async format(e=this.value){let r=await this.resolve(this.initial,this.state);return this.state.submitted?this.styles.submitted(e||r):f3e(this,{input:e,initial:r,pos:this.cursor})}async render(){let e=this.state.size,r=await this.prefix(),i=await this.separator(),n=await this.message(),s=[r,n,i].filter(Boolean).join(" ");this.state.prompt=s;let o=await this.header(),a=await this.format(),l=await this.error()||await this.hint(),c=await this.footer();l&&!a.includes(l)&&(a+=" "+l),s+=" "+a,this.clear(e),this.write([o,s,c].filter(Boolean).join(` +`)),this.restore()}};Xne.exports=Zne});var ese=E((LCt,$ne)=>{"use strict";var p3e=t=>t.filter((e,r)=>t.lastIndexOf(e)===r),U0=t=>p3e(t).filter(Boolean);$ne.exports=(t,e={},r="")=>{let{past:i=[],present:n=""}=e,s,o;switch(t){case"prev":case"undo":return s=i.slice(0,i.length-1),o=i[i.length-1]||"",{past:U0([r,...s]),present:o};case"next":case"redo":return s=i.slice(1),o=i[0]||"",{past:U0([...s,r]),present:o};case"save":return{past:U0([...i,r]),present:""};case"remove":return o=U0(i.filter(a=>a!==r)),n="",o.length&&(n=o.pop()),{past:o,present:n};default:throw new Error(`Invalid action: "${t}"`)}}});var kN=E((TCt,tse)=>{"use strict";var d3e=Mc(),rse=ese(),ise=class extends d3e{constructor(e){super(e);let r=this.options.history;if(r&&r.store){let i=r.values||this.initial;this.autosave=!!r.autosave,this.store=r.store,this.data=this.store.get("values")||{past:[],present:i},this.initial=this.data.present||this.data.past[this.data.past.length-1]}}completion(e){return this.store?(this.data=rse(e,this.data,this.input),this.data.present?(this.input=this.data.present,this.cursor=this.input.length,this.render()):this.alert()):this.alert()}altUp(){return this.completion("prev")}altDown(){return this.completion("next")}prev(){return this.save(),super.prev()}save(){!this.store||(this.data=rse("save",this.data,this.input),this.store.set("values",this.data))}submit(){return this.store&&this.autosave===!0&&this.save(),super.submit()}};tse.exports=ise});var ose=E((MCt,nse)=>{"use strict";var C3e=Mc(),sse=class extends C3e{format(){return""}};nse.exports=sse});var lse=E((OCt,ase)=>{"use strict";var m3e=Mc(),Ase=class extends m3e{constructor(e={}){super(e);this.sep=this.options.separator||/, */,this.initial=e.initial||""}split(e=this.value){return e?String(e).split(this.sep):[]}format(){let e=this.state.submitted?this.styles.primary:r=>r;return this.list.map(e).join(", ")}async submit(e){let r=this.state.error||await this.validate(this.list,this.state);return r!==!0?(this.state.error=r,super.submit()):(this.value=this.list,super.submit())}get list(){return this.split()}};ase.exports=Ase});var gse=E((KCt,cse)=>{"use strict";var E3e=GA(),use=class extends E3e{constructor(e){super(_(P({},e),{multiple:!0}))}};cse.exports=use});var PN=E((UCt,fse)=>{"use strict";var I3e=Mc(),hse=class extends I3e{constructor(e={}){super(P({style:"number"},e));this.min=this.isValue(e.min)?this.toNumber(e.min):-Infinity,this.max=this.isValue(e.max)?this.toNumber(e.max):Infinity,this.delay=e.delay!=null?e.delay:1e3,this.float=e.float!==!1,this.round=e.round===!0||e.float===!1,this.major=e.major||10,this.minor=e.minor||1,this.initial=e.initial!=null?e.initial:"",this.input=String(this.initial),this.cursor=this.input.length,this.cursorShow()}append(e){return!/[-+.]/.test(e)||e==="."&&this.input.includes(".")?this.alert("invalid number"):super.append(e)}number(e){return super.append(e)}next(){return this.input&&this.input!==this.initial?this.alert():this.isValue(this.initial)?(this.input=this.initial,this.cursor=String(this.initial).length,this.render()):this.alert()}up(e){let r=e||this.minor,i=this.toNumber(this.input);return i>this.max+r?this.alert():(this.input=`${i+r}`,this.render())}down(e){let r=e||this.minor,i=this.toNumber(this.input);return ithis.isValue(r));return this.value=this.toNumber(e||0),super.submit()}};fse.exports=hse});var dse=E((HCt,pse)=>{pse.exports=PN()});var Ese=E((GCt,Cse)=>{"use strict";var y3e=Mc(),mse=class extends y3e{constructor(e){super(e);this.cursorShow()}format(e=this.input){return this.keypressed?(this.state.submitted?this.styles.primary:this.styles.muted)(this.symbols.asterisk.repeat(e.length)):""}};Cse.exports=mse});var Bse=E((jCt,Ise)=>{"use strict";var w3e=js(),B3e=sC(),yse=Mi(),wse=class extends B3e{constructor(e={}){super(e);this.widths=[].concat(e.messageWidth||50),this.align=[].concat(e.align||"left"),this.linebreak=e.linebreak||!1,this.edgeLength=e.edgeLength||3,this.newline=e.newline||` + `;let r=e.startNumber||1;typeof this.scale=="number"&&(this.scaleKey=!1,this.scale=Array(this.scale).fill(0).map((i,n)=>({name:n+r})))}async reset(){return this.tableized=!1,await super.reset(),this.render()}tableize(){if(this.tableized===!0)return;this.tableized=!0;let e=0;for(let r of this.choices){e=Math.max(e,r.message.length),r.scaleIndex=r.initial||2,r.scale=[];for(let i=0;i=this.scale.length-1?this.alert():(e.scaleIndex++,this.render())}left(){let e=this.focused;return e.scaleIndex<=0?this.alert():(e.scaleIndex--,this.render())}indent(){return""}format(){return this.state.submitted?this.choices.map(r=>this.styles.info(r.index)).join(", "):""}pointer(){return""}renderScaleKey(){if(this.scaleKey===!1||this.state.submitted)return"";let e=this.scale.map(i=>` ${i.name} - ${i.message}`);return["",...e].map(i=>this.styles.muted(i)).join(` +`)}renderScaleHeading(e){let r=this.scale.map(l=>l.name);typeof this.options.renderScaleHeading=="function"&&(r=this.options.renderScaleHeading.call(this,e));let i=this.scaleLength-r.join("").length,n=Math.round(i/(r.length-1)),o=r.map(l=>this.styles.strong(l)).join(" ".repeat(n)),a=" ".repeat(this.widths[0]);return this.margin[3]+a+this.margin[1]+o}scaleIndicator(e,r,i){if(typeof this.options.scaleIndicator=="function")return this.options.scaleIndicator.call(this,e,r,i);let n=e.scaleIndex===r.index;return r.disabled?this.styles.hint(this.symbols.radio.disabled):n?this.styles.success(this.symbols.radio.on):this.symbols.radio.off}renderScale(e,r){let i=e.scale.map(s=>this.scaleIndicator(e,s,r)),n=this.term==="Hyper"?"":" ";return i.join(n+this.symbols.line.repeat(this.edgeLength))}async renderChoice(e,r){await this.onChoice(e,r);let i=this.index===r,n=await this.pointer(e,r),s=await e.hint;s&&!yse.hasColor(s)&&(s=this.styles.muted(s));let o=p=>this.margin[3]+p.replace(/\s+$/,"").padEnd(this.widths[0]," "),a=this.newline,l=this.indent(e),c=await this.resolve(e.message,this.state,e,r),u=await this.renderScale(e,r),g=this.margin[1]+this.margin[3];this.scaleLength=w3e.unstyle(u).length,this.widths[0]=Math.min(this.widths[0],this.width-this.scaleLength-g.length);let h=yse.wordWrap(c,{width:this.widths[0],newline:a}).split(` +`).map(p=>o(p)+this.margin[1]);return i&&(u=this.styles.info(u),h=h.map(p=>this.styles.info(p))),h[0]+=u,this.linebreak&&h.push(""),[l+n,h.join(` +`)].filter(Boolean)}async renderChoices(){if(this.state.submitted)return"";this.tableize();let e=this.visible.map(async(n,s)=>await this.renderChoice(n,s)),r=await Promise.all(e),i=await this.renderScaleHeading();return this.margin[0]+[i,...r.map(n=>n.join(" "))].join(` +`)}async render(){let{submitted:e,size:r}=this.state,i=await this.prefix(),n=await this.separator(),s=await this.message(),o="";this.options.promptLine!==!1&&(o=[i,s,n,""].join(" "),this.state.prompt=o);let a=await this.header(),l=await this.format(),c=await this.renderScaleKey(),u=await this.error()||await this.hint(),g=await this.renderChoices(),f=await this.footer(),h=this.emptyError;l&&(o+=l),u&&!o.includes(u)&&(o+=" "+u),e&&!l&&!g.trim()&&this.multiple&&h!=null&&(o+=this.styles.danger(h)),this.clear(r),this.write([a,o,c,g,f].filter(Boolean).join(` +`)),this.state.submitted||this.write(this.margin[2]),this.restore()}submit(){this.value={};for(let e of this.choices)this.value[e.name]=e.scaleIndex;return this.base.submit.call(this)}};Ise.exports=wse});var Sse=E((YCt,Qse)=>{"use strict";var bse=js(),Q3e=(t="")=>typeof t=="string"?t.replace(/^['"]|['"]$/g,""):"",vse=class{constructor(e){this.name=e.key,this.field=e.field||{},this.value=Q3e(e.initial||this.field.initial||""),this.message=e.message||this.name,this.cursor=0,this.input="",this.lines=[]}},b3e=async(t={},e={},r=i=>i)=>{let i=new Set,n=t.fields||[],s=t.template,o=[],a=[],l=[],c=1;typeof s=="function"&&(s=await s());let u=-1,g=()=>s[++u],f=()=>s[u+1],h=p=>{p.line=c,o.push(p)};for(h({type:"bos",value:""});uR.name===I.key);I.field=n.find(R=>R.name===I.key),b||(b=new vse(I),a.push(b)),b.lines.push(I.line-1);continue}let d=o[o.length-1];d.type==="text"&&d.line===c?d.value+=p:h({type:"text",value:p})}return h({type:"eos",value:""}),{input:s,tabstops:o,unique:i,keys:l,items:a}};Qse.exports=async t=>{let e=t.options,r=new Set(e.required===!0?[]:e.required||[]),i=P(P({},e.values),e.initial),{tabstops:n,items:s,keys:o}=await b3e(e,i),a=DN("result",t,e),l=DN("format",t,e),c=DN("validate",t,e,!0),u=t.isValue.bind(t);return async(g={},f=!1)=>{let h=0;g.required=r,g.items=s,g.keys=o,g.output="";let p=async(B,b,R,H)=>{let L=await c(B,b,R,H);return L===!1?"Invalid field "+R.name:L};for(let B of n){let b=B.value,R=B.key;if(B.type!=="template"){b&&(g.output+=b);continue}if(B.type==="template"){let H=s.find(q=>q.name===R);e.required===!0&&g.required.add(H.name);let L=[H.input,g.values[H.value],H.value,b].find(u),J=(H.field||{}).message||B.inner;if(f){let q=await p(g.values[R],g,H,h);if(q&&typeof q=="string"||q===!1){g.invalid.set(R,q);continue}g.invalid.delete(R);let A=await a(g.values[R],g,H,h);g.output+=bse.unstyle(A);continue}H.placeholder=!1;let ne=b;b=await l(b,g,H,h),L!==b?(g.values[R]=L,b=t.styles.typing(L),g.missing.delete(J)):(g.values[R]=void 0,L=`<${J}>`,b=t.styles.primary(L),H.placeholder=!0,g.required.has(R)&&g.missing.add(J)),g.missing.has(J)&&g.validating&&(b=t.styles.warning(L)),g.invalid.has(R)&&g.validating&&(b=t.styles.danger(L)),h===g.index&&(ne!==b?b=t.styles.underline(b):b=t.styles.heading(bse.unstyle(b))),h++}b&&(g.output+=b)}let d=g.output.split(` +`).map(B=>" "+B),m=s.length,I=0;for(let B of s)g.invalid.has(B.name)&&B.lines.forEach(b=>{d[b][0]===" "&&(d[b]=g.styles.danger(g.symbols.bullet)+d[b].slice(1))}),t.isValue(g.values[B.name])&&I++;return g.completed=(I/m*100).toFixed(0),g.output=d.join(` +`),g.output}};function DN(t,e,r,i){return(n,s,o,a)=>typeof o.field[t]=="function"?o.field[t].call(e,n,s,o,a):[i,n].find(l=>e.isValue(l))}});var Pse=E((qCt,xse)=>{"use strict";var v3e=js(),S3e=Sse(),x3e=sf(),kse=class extends x3e{constructor(e){super(e);this.cursorHide(),this.reset(!0)}async initialize(){this.interpolate=await S3e(this),await super.initialize()}async reset(e){this.state.keys=[],this.state.invalid=new Map,this.state.missing=new Set,this.state.completed=0,this.state.values={},e!==!0&&(await this.initialize(),await this.render())}moveCursor(e){let r=this.getItem();this.cursor+=e,r.cursor+=e}dispatch(e,r){if(!r.code&&!r.ctrl&&e!=null&&this.getItem()){this.append(e,r);return}this.alert()}append(e,r){let i=this.getItem(),n=i.input.slice(0,this.cursor),s=i.input.slice(this.cursor);this.input=i.input=`${n}${e}${s}`,this.moveCursor(1),this.render()}delete(){let e=this.getItem();if(this.cursor<=0||!e.input)return this.alert();let r=e.input.slice(this.cursor),i=e.input.slice(0,this.cursor-1);this.input=e.input=`${i}${r}`,this.moveCursor(-1),this.render()}increment(e){return e>=this.state.keys.length-1?0:e+1}decrement(e){return e<=0?this.state.keys.length-1:e-1}first(){this.state.index=0,this.render()}last(){this.state.index=this.state.keys.length-1,this.render()}right(){if(this.cursor>=this.input.length)return this.alert();this.moveCursor(1),this.render()}left(){if(this.cursor<=0)return this.alert();this.moveCursor(-1),this.render()}prev(){this.state.index=this.decrement(this.state.index),this.getItem(),this.render()}next(){this.state.index=this.increment(this.state.index),this.getItem(),this.render()}up(){this.prev()}down(){this.next()}format(e){let r=this.state.completed<100?this.styles.warning:this.styles.success;return this.state.submitted===!0&&this.state.completed!==100&&(r=this.styles.danger),r(`${this.state.completed}% completed`)}async render(){let{index:e,keys:r=[],submitted:i,size:n}=this.state,s=[this.options.newline,` +`].find(B=>B!=null),o=await this.prefix(),a=await this.separator(),l=await this.message(),c=[o,l,a].filter(Boolean).join(" ");this.state.prompt=c;let u=await this.header(),g=await this.error()||"",f=await this.hint()||"",h=i?"":await this.interpolate(this.state),p=this.state.key=r[e]||"",d=await this.format(p),m=await this.footer();d&&(c+=" "+d),f&&!d&&this.state.completed===0&&(c+=" "+f),this.clear(n);let I=[u,c,h,m,g.trim()];this.write(I.filter(Boolean).join(s)),this.restore()}getItem(e){let{items:r,keys:i,index:n}=this.state,s=r.find(o=>o.name===i[n]);return s&&s.input!=null&&(this.input=s.input,this.cursor=s.cursor),s}async submit(){typeof this.interpolate!="function"&&await this.initialize(),await this.interpolate(this.state,!0);let{invalid:e,missing:r,output:i,values:n}=this.state;if(e.size){let a="";for(let[l,c]of e)a+=`Invalid ${l}: ${c} +`;return this.state.error=a,super.submit()}if(r.size)return this.state.error="Required: "+[...r.keys()].join(", "),super.submit();let o=v3e.unstyle(i).split(` +`).map(a=>a.slice(1)).join(` +`);return this.value={values:n,result:o},super.submit()}};xse.exports=kse});var Fse=E((JCt,Dse)=>{"use strict";var k3e="(Use + to sort)",P3e=GA(),Rse=class extends P3e{constructor(e){super(_(P({},e),{reorder:!1,sort:!0,multiple:!0}));this.state.hint=[this.options.hint,k3e].find(this.isValue.bind(this))}indicator(){return""}async renderChoice(e,r){let i=await super.renderChoice(e,r),n=this.symbols.identicalTo+" ",s=this.index===r&&this.sorting?this.styles.muted(n):" ";return this.options.drag===!1&&(s=""),this.options.numbered===!0?s+`${r+1} - `+i:s+i}get selected(){return this.choices}submit(){return this.value=this.choices.map(e=>e.value),super.submit()}};Dse.exports=Rse});var Tse=E((WCt,Nse)=>{"use strict";var D3e=sC(),Lse=class extends D3e{constructor(e={}){super(e);if(this.emptyError=e.emptyError||"No items were selected",this.term=process.env.TERM_PROGRAM,!this.options.header){let r=["","4 - Strongly Agree","3 - Agree","2 - Neutral","1 - Disagree","0 - Strongly Disagree",""];r=r.map(i=>this.styles.muted(i)),this.state.header=r.join(` + `)}}async toChoices(...e){if(this.createdScales)return!1;this.createdScales=!0;let r=await super.toChoices(...e);for(let i of r)i.scale=R3e(5,this.options),i.scaleIdx=2;return r}dispatch(){this.alert()}space(){let e=this.focused,r=e.scale[e.scaleIdx],i=r.selected;return e.scale.forEach(n=>n.selected=!1),r.selected=!i,this.render()}indicator(){return""}pointer(){return""}separator(){return this.styles.muted(this.symbols.ellipsis)}right(){let e=this.focused;return e.scaleIdx>=e.scale.length-1?this.alert():(e.scaleIdx++,this.render())}left(){let e=this.focused;return e.scaleIdx<=0?this.alert():(e.scaleIdx--,this.render())}indent(){return" "}async renderChoice(e,r){await this.onChoice(e,r);let i=this.index===r,n=this.term==="Hyper",s=n?9:8,o=n?"":" ",a=this.symbols.line.repeat(s),l=" ".repeat(s+(n?0:1)),c=b=>(b?this.styles.success("\u25C9"):"\u25EF")+o,u=r+1+".",g=i?this.styles.heading:this.styles.noop,f=await this.resolve(e.message,this.state,e,r),h=this.indent(e),p=h+e.scale.map((b,R)=>c(R===e.scaleIdx)).join(a),d=b=>b===e.scaleIdx?g(b):b,m=h+e.scale.map((b,R)=>d(R)).join(l),I=()=>[u,f].filter(Boolean).join(" "),B=()=>[I(),p,m," "].filter(Boolean).join(` +`);return i&&(p=this.styles.cyan(p),m=this.styles.cyan(m)),B()}async renderChoices(){if(this.state.submitted)return"";let e=this.visible.map(async(i,n)=>await this.renderChoice(i,n)),r=await Promise.all(e);return r.length||r.push(this.styles.danger("No matching choices")),r.join(` +`)}format(){return this.state.submitted?this.choices.map(r=>this.styles.info(r.scaleIdx)).join(", "):""}async render(){let{submitted:e,size:r}=this.state,i=await this.prefix(),n=await this.separator(),s=await this.message(),o=[i,s,n].filter(Boolean).join(" ");this.state.prompt=o;let a=await this.header(),l=await this.format(),c=await this.error()||await this.hint(),u=await this.renderChoices(),g=await this.footer();(l||!c)&&(o+=" "+l),c&&!o.includes(c)&&(o+=" "+c),e&&!l&&!u&&this.multiple&&this.type!=="form"&&(o+=this.styles.danger(this.emptyError)),this.clear(r),this.write([o,a,u,g].filter(Boolean).join(` +`)),this.restore()}submit(){this.value={};for(let e of this.choices)this.value[e.name]=e.scaleIdx;return this.base.submit.call(this)}};function R3e(t,e={}){if(Array.isArray(e.scale))return e.scale.map(i=>P({},i));let r=[];for(let i=1;i{Mse.exports=kN()});var Hse=E((VCt,Kse)=>{"use strict";var F3e=K0(),Use=class extends F3e{async initialize(){await super.initialize(),this.value=this.initial=!!this.options.initial,this.disabled=this.options.disabled||"no",this.enabled=this.options.enabled||"yes",await this.render()}reset(){this.value=this.initial,this.render()}delete(){this.alert()}toggle(){this.value=!this.value,this.render()}enable(){if(this.value===!0)return this.alert();this.value=!0,this.render()}disable(){if(this.value===!1)return this.alert();this.value=!1,this.render()}up(){this.toggle()}down(){this.toggle()}right(){this.toggle()}left(){this.toggle()}next(){this.toggle()}prev(){this.toggle()}dispatch(e="",r){switch(e.toLowerCase()){case" ":return this.toggle();case"1":case"y":case"t":return this.enable();case"0":case"n":case"f":return this.disable();default:return this.alert()}}format(){let e=i=>this.styles.primary.underline(i);return[this.value?this.disabled:e(this.disabled),this.value?e(this.enabled):this.enabled].join(this.styles.muted(" / "))}async render(){let{size:e}=this.state,r=await this.header(),i=await this.prefix(),n=await this.separator(),s=await this.message(),o=await this.format(),a=await this.error()||await this.hint(),l=await this.footer(),c=[i,s,n,o].join(" ");this.state.prompt=c,a&&!c.includes(a)&&(c+=" "+a),this.clear(e),this.write([r,c,l].filter(Boolean).join(` +`)),this.write(this.margin[2]),this.restore()}};Kse.exports=Use});var Yse=E((_Ct,Gse)=>{"use strict";var N3e=GA(),jse=class extends N3e{constructor(e){super(e);if(typeof this.options.correctChoice!="number"||this.options.correctChoice<0)throw new Error("Please specify the index of the correct answer from the list of choices")}async toChoices(e,r){let i=await super.toChoices(e,r);if(i.length<2)throw new Error("Please give at least two choices to the user");if(this.options.correctChoice>i.length)throw new Error("Please specify the index of the correct answer from the list of choices");return i}check(e){return e.index===this.options.correctChoice}async result(e){return{selectedAnswer:e,correctAnswer:this.options.choices[this.options.correctChoice].value,correct:await this.check(this.state)}}};Gse.exports=jse});var Jse=E(RN=>{"use strict";var qse=Mi(),ti=(t,e)=>{qse.defineExport(RN,t,e),qse.defineExport(RN,t.toLowerCase(),e)};ti("AutoComplete",()=>Nne());ti("BasicAuth",()=>Gne());ti("Confirm",()=>Wne());ti("Editable",()=>_ne());ti("Form",()=>O0());ti("Input",()=>kN());ti("Invisible",()=>ose());ti("List",()=>lse());ti("MultiSelect",()=>gse());ti("Numeral",()=>dse());ti("Password",()=>Ese());ti("Scale",()=>Bse());ti("Select",()=>GA());ti("Snippet",()=>Pse());ti("Sort",()=>Fse());ti("Survey",()=>Tse());ti("Text",()=>Ose());ti("Toggle",()=>Hse());ti("Quiz",()=>Yse())});var zse=E((ZCt,Wse)=>{Wse.exports={ArrayPrompt:sC(),AuthPrompt:xN(),BooleanPrompt:K0(),NumberPrompt:PN(),StringPrompt:Mc()}});var aC=E(($Ct,Vse)=>{"use strict";var _se=require("assert"),FN=require("events"),jA=Mi(),No=class extends FN{constructor(e,r){super();this.options=jA.merge({},e),this.answers=P({},r)}register(e,r){if(jA.isObject(e)){for(let n of Object.keys(e))this.register(n,e[n]);return this}_se.equal(typeof r,"function","expected a function");let i=e.toLowerCase();return r.prototype instanceof this.Prompt?this.prompts[i]=r:this.prompts[i]=r(this.Prompt,this),this}async prompt(e=[]){for(let r of[].concat(e))try{typeof r=="function"&&(r=await r.call(this)),await this.ask(jA.merge({},this.options,r))}catch(i){return Promise.reject(i)}return this.answers}async ask(e){typeof e=="function"&&(e=await e.call(this));let r=jA.merge({},this.options,e),{type:i,name:n}=e,{set:s,get:o}=jA;if(typeof i=="function"&&(i=await i.call(this,e,this.answers)),!i)return this.answers[n];_se(this.prompts[i],`Prompt "${i}" is not registered`);let a=new this.prompts[i](r),l=o(this.answers,n);a.state.answers=this.answers,a.enquirer=this,n&&a.on("submit",u=>{this.emit("answer",n,u,a),s(this.answers,n,u)});let c=a.emit.bind(a);return a.emit=(...u)=>(this.emit.call(this,...u),c(...u)),this.emit("prompt",a,this),r.autofill&&l!=null?(a.value=a.input=l,r.autofill==="show"&&await a.submit()):l=a.value=await a.run(),l}use(e){return e.call(this,this),this}set Prompt(e){this._Prompt=e}get Prompt(){return this._Prompt||this.constructor.Prompt}get prompts(){return this.constructor.prompts}static set Prompt(e){this._Prompt=e}static get Prompt(){return this._Prompt||sf()}static get prompts(){return Jse()}static get types(){return zse()}static get prompt(){let e=(r,...i)=>{let n=new this(...i),s=n.emit.bind(n);return n.emit=(...o)=>(e.emit(...o),s(...o)),n.prompt(r)};return jA.mixinEmitter(e,new FN),e}};jA.mixinEmitter(No,new FN);var NN=No.prompts;for(let t of Object.keys(NN)){let e=t.toLowerCase(),r=i=>new NN[t](i).run();No.prompt[e]=r,No[e]=r,No[t]||Reflect.defineProperty(No,t,{get:()=>NN[t]})}var oC=t=>{jA.defineExport(No,t,()=>No.types[t])};oC("ArrayPrompt");oC("AuthPrompt");oC("BooleanPrompt");oC("NumberPrompt");oC("StringPrompt");Vse.exports=No});var loe=E((Gmt,Aoe)=>{function K3e(t,e){for(var r=-1,i=t==null?0:t.length;++r{var U3e=XB(),H3e=jg();function G3e(t,e,r,i){var n=!r;r||(r={});for(var s=-1,o=e.length;++s{var j3e=Af(),Y3e=zg();function q3e(t,e){return t&&j3e(e,Y3e(e),t)}uoe.exports=q3e});var hoe=E((qmt,foe)=>{function J3e(t){var e=[];if(t!=null)for(var r in Object(t))e.push(r);return e}foe.exports=J3e});var doe=E((Jmt,poe)=>{var W3e=Gs(),z3e=u0(),V3e=hoe(),_3e=Object.prototype,X3e=_3e.hasOwnProperty;function Z3e(t){if(!W3e(t))return V3e(t);var e=z3e(t),r=[];for(var i in t)i=="constructor"&&(e||!X3e.call(t,i))||r.push(i);return r}poe.exports=Z3e});var lf=E((Wmt,Coe)=>{var $3e=bF(),eWe=doe(),tWe=Hd();function rWe(t){return tWe(t)?$3e(t,!0):eWe(t)}Coe.exports=rWe});var Eoe=E((zmt,moe)=>{var iWe=Af(),nWe=lf();function sWe(t,e){return t&&iWe(e,nWe(e),t)}moe.exports=sWe});var UN=E((hC,cf)=>{var oWe=Ks(),Ioe=typeof hC=="object"&&hC&&!hC.nodeType&&hC,yoe=Ioe&&typeof cf=="object"&&cf&&!cf.nodeType&&cf,aWe=yoe&&yoe.exports===Ioe,woe=aWe?oWe.Buffer:void 0,Boe=woe?woe.allocUnsafe:void 0;function AWe(t,e){if(e)return t.slice();var r=t.length,i=Boe?Boe(r):new t.constructor(r);return t.copy(i),i}cf.exports=AWe});var HN=E((Vmt,Qoe)=>{function lWe(t,e){var r=-1,i=t.length;for(e||(e=Array(i));++r{var cWe=Af(),uWe=f0();function gWe(t,e){return cWe(t,uWe(t),e)}boe.exports=gWe});var H0=E((Xmt,Soe)=>{var fWe=vF(),hWe=fWe(Object.getPrototypeOf,Object);Soe.exports=hWe});var GN=E((Zmt,xoe)=>{var pWe=$B(),dWe=H0(),CWe=f0(),mWe=RF(),EWe=Object.getOwnPropertySymbols,IWe=EWe?function(t){for(var e=[];t;)pWe(e,CWe(t)),t=dWe(t);return e}:mWe;xoe.exports=IWe});var Poe=E(($mt,koe)=>{var yWe=Af(),wWe=GN();function BWe(t,e){return yWe(t,wWe(t),e)}koe.exports=BWe});var Roe=E((eEt,Doe)=>{var QWe=DF(),bWe=GN(),vWe=lf();function SWe(t){return QWe(t,vWe,bWe)}Doe.exports=SWe});var Noe=E((tEt,Foe)=>{var xWe=Object.prototype,kWe=xWe.hasOwnProperty;function PWe(t){var e=t.length,r=new t.constructor(e);return e&&typeof t[0]=="string"&&kWe.call(t,"index")&&(r.index=t.index,r.input=t.input),r}Foe.exports=PWe});var G0=E((rEt,Loe)=>{var Toe=kF();function DWe(t){var e=new t.constructor(t.byteLength);return new Toe(e).set(new Toe(t)),e}Loe.exports=DWe});var Ooe=E((iEt,Moe)=>{var RWe=G0();function FWe(t,e){var r=e?RWe(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}Moe.exports=FWe});var Uoe=E((nEt,Koe)=>{var NWe=/\w*$/;function LWe(t){var e=new t.constructor(t.source,NWe.exec(t));return e.lastIndex=t.lastIndex,e}Koe.exports=LWe});var qoe=E((sEt,Hoe)=>{var Goe=ac(),joe=Goe?Goe.prototype:void 0,Yoe=joe?joe.valueOf:void 0;function TWe(t){return Yoe?Object(Yoe.call(t)):{}}Hoe.exports=TWe});var jN=E((oEt,Joe)=>{var MWe=G0();function OWe(t,e){var r=e?MWe(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}Joe.exports=OWe});var zoe=E((aEt,Woe)=>{var KWe=G0(),UWe=Ooe(),HWe=Uoe(),GWe=qoe(),jWe=jN(),YWe="[object Boolean]",qWe="[object Date]",JWe="[object Map]",WWe="[object Number]",zWe="[object RegExp]",VWe="[object Set]",_We="[object String]",XWe="[object Symbol]",ZWe="[object ArrayBuffer]",$We="[object DataView]",e8e="[object Float32Array]",t8e="[object Float64Array]",r8e="[object Int8Array]",i8e="[object Int16Array]",n8e="[object Int32Array]",s8e="[object Uint8Array]",o8e="[object Uint8ClampedArray]",a8e="[object Uint16Array]",A8e="[object Uint32Array]";function l8e(t,e,r){var i=t.constructor;switch(e){case ZWe:return KWe(t);case YWe:case qWe:return new i(+t);case $We:return UWe(t,r);case e8e:case t8e:case r8e:case i8e:case n8e:case s8e:case o8e:case a8e:case A8e:return jWe(t,r);case JWe:return new i;case WWe:case _We:return new i(t);case zWe:return HWe(t);case VWe:return new i;case XWe:return GWe(t)}}Woe.exports=l8e});var Xoe=E((AEt,Voe)=>{var c8e=Gs(),_oe=Object.create,u8e=function(){function t(){}return function(e){if(!c8e(e))return{};if(_oe)return _oe(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}}();Voe.exports=u8e});var YN=E((lEt,Zoe)=>{var g8e=Xoe(),f8e=H0(),h8e=u0();function p8e(t){return typeof t.constructor=="function"&&!h8e(t)?g8e(f8e(t)):{}}Zoe.exports=p8e});var eae=E((cEt,$oe)=>{var d8e=jd(),C8e=Qo(),m8e="[object Map]";function E8e(t){return C8e(t)&&d8e(t)==m8e}$oe.exports=E8e});var nae=E((uEt,tae)=>{var I8e=eae(),y8e=A0(),rae=l0(),iae=rae&&rae.isMap,w8e=iae?y8e(iae):I8e;tae.exports=w8e});var oae=E((gEt,sae)=>{var B8e=jd(),Q8e=Qo(),b8e="[object Set]";function v8e(t){return Q8e(t)&&B8e(t)==b8e}sae.exports=v8e});var cae=E((fEt,aae)=>{var S8e=oae(),x8e=A0(),Aae=l0(),lae=Aae&&Aae.isSet,k8e=lae?x8e(lae):S8e;aae.exports=k8e});var pae=E((hEt,uae)=>{var P8e=Gd(),D8e=loe(),R8e=XB(),F8e=goe(),N8e=Eoe(),L8e=UN(),T8e=HN(),M8e=voe(),O8e=Poe(),K8e=FF(),U8e=Roe(),H8e=jd(),G8e=Noe(),j8e=zoe(),Y8e=YN(),q8e=As(),J8e=Od(),W8e=nae(),z8e=Gs(),V8e=cae(),_8e=zg(),X8e=lf(),Z8e=1,$8e=2,e4e=4,gae="[object Arguments]",t4e="[object Array]",r4e="[object Boolean]",i4e="[object Date]",n4e="[object Error]",fae="[object Function]",s4e="[object GeneratorFunction]",o4e="[object Map]",a4e="[object Number]",hae="[object Object]",A4e="[object RegExp]",l4e="[object Set]",c4e="[object String]",u4e="[object Symbol]",g4e="[object WeakMap]",f4e="[object ArrayBuffer]",h4e="[object DataView]",p4e="[object Float32Array]",d4e="[object Float64Array]",C4e="[object Int8Array]",m4e="[object Int16Array]",E4e="[object Int32Array]",I4e="[object Uint8Array]",y4e="[object Uint8ClampedArray]",w4e="[object Uint16Array]",B4e="[object Uint32Array]",rr={};rr[gae]=rr[t4e]=rr[f4e]=rr[h4e]=rr[r4e]=rr[i4e]=rr[p4e]=rr[d4e]=rr[C4e]=rr[m4e]=rr[E4e]=rr[o4e]=rr[a4e]=rr[hae]=rr[A4e]=rr[l4e]=rr[c4e]=rr[u4e]=rr[I4e]=rr[y4e]=rr[w4e]=rr[B4e]=!0;rr[n4e]=rr[fae]=rr[g4e]=!1;function j0(t,e,r,i,n,s){var o,a=e&Z8e,l=e&$8e,c=e&e4e;if(r&&(o=n?r(t,i,n,s):r(t)),o!==void 0)return o;if(!z8e(t))return t;var u=q8e(t);if(u){if(o=G8e(t),!a)return T8e(t,o)}else{var g=H8e(t),f=g==fae||g==s4e;if(J8e(t))return L8e(t,a);if(g==hae||g==gae||f&&!n){if(o=l||f?{}:Y8e(t),!a)return l?O8e(t,N8e(o,t)):M8e(t,F8e(o,t))}else{if(!rr[g])return n?t:{};o=j8e(t,g,a)}}s||(s=new P8e);var h=s.get(t);if(h)return h;s.set(t,o),V8e(t)?t.forEach(function(m){o.add(j0(m,e,r,m,t,s))}):W8e(t)&&t.forEach(function(m,I){o.set(I,j0(m,e,r,I,t,s))});var p=c?l?U8e:K8e:l?X8e:_8e,d=u?void 0:p(t);return D8e(d||t,function(m,I){d&&(I=m,m=t[I]),R8e(o,I,j0(m,e,r,I,t,s))}),o}uae.exports=j0});var qN=E((pEt,dae)=>{var Q4e=pae(),b4e=1,v4e=4;function S4e(t){return Q4e(t,b4e|v4e)}dae.exports=S4e});var mae=E((dEt,Cae)=>{var x4e=tF();function k4e(t,e,r){return t==null?t:x4e(t,e,r)}Cae.exports=k4e});var Qae=E((wEt,Bae)=>{function P4e(t){var e=t==null?0:t.length;return e?t[e-1]:void 0}Bae.exports=P4e});var vae=E((BEt,bae)=>{var D4e=xd(),R4e=zP();function F4e(t,e){return e.length<2?t:D4e(t,R4e(e,0,-1))}bae.exports=F4e});var xae=E((QEt,Sae)=>{var N4e=Gg(),L4e=Qae(),T4e=vae(),M4e=Sc();function O4e(t,e){return e=N4e(e,t),t=T4e(t,e),t==null||delete t[M4e(L4e(e))]}Sae.exports=O4e});var Pae=E((bEt,kae)=>{var K4e=xae();function U4e(t,e){return t==null?!0:K4e(t,e)}kae.exports=U4e});var Kae=E((tIt,Oae)=>{Oae.exports={name:"@yarnpkg/cli",version:"3.1.1",license:"BSD-2-Clause",main:"./sources/index.ts",dependencies:{"@yarnpkg/core":"workspace:^","@yarnpkg/fslib":"workspace:^","@yarnpkg/libzip":"workspace:^","@yarnpkg/parsers":"workspace:^","@yarnpkg/plugin-compat":"workspace:^","@yarnpkg/plugin-dlx":"workspace:^","@yarnpkg/plugin-essentials":"workspace:^","@yarnpkg/plugin-file":"workspace:^","@yarnpkg/plugin-git":"workspace:^","@yarnpkg/plugin-github":"workspace:^","@yarnpkg/plugin-http":"workspace:^","@yarnpkg/plugin-init":"workspace:^","@yarnpkg/plugin-link":"workspace:^","@yarnpkg/plugin-nm":"workspace:^","@yarnpkg/plugin-npm":"workspace:^","@yarnpkg/plugin-npm-cli":"workspace:^","@yarnpkg/plugin-pack":"workspace:^","@yarnpkg/plugin-patch":"workspace:^","@yarnpkg/plugin-pnp":"workspace:^","@yarnpkg/plugin-pnpm":"workspace:^","@yarnpkg/shell":"workspace:^",chalk:"^3.0.0","ci-info":"^3.2.0",clipanion:"^3.0.1",semver:"^7.1.2",tslib:"^1.13.0",typanion:"^3.3.0",yup:"^0.32.9"},devDependencies:{"@types/semver":"^7.1.0","@types/yup":"^0","@yarnpkg/builder":"workspace:^","@yarnpkg/monorepo":"workspace:^","@yarnpkg/pnpify":"workspace:^",micromatch:"^4.0.2",typescript:"^4.5.2"},peerDependencies:{"@yarnpkg/core":"workspace:^"},scripts:{postpack:"rm -rf lib",prepack:'run build:compile "$(pwd)"',"build:cli+hook":"run build:pnp:hook && builder build bundle","build:cli":"builder build bundle","run:cli":"builder run","update-local":"run build:cli --no-git-hash && rsync -a --delete bundles/ bin/"},publishConfig:{main:"./lib/index.js",types:"./lib/index.d.ts",bin:null},files:["/lib/**/*","!/lib/pluginConfiguration.*","!/lib/cli.*"],"@yarnpkg/builder":{bundles:{standard:["@yarnpkg/plugin-essentials","@yarnpkg/plugin-compat","@yarnpkg/plugin-dlx","@yarnpkg/plugin-file","@yarnpkg/plugin-git","@yarnpkg/plugin-github","@yarnpkg/plugin-http","@yarnpkg/plugin-init","@yarnpkg/plugin-link","@yarnpkg/plugin-nm","@yarnpkg/plugin-npm","@yarnpkg/plugin-npm-cli","@yarnpkg/plugin-pack","@yarnpkg/plugin-patch","@yarnpkg/plugin-pnp","@yarnpkg/plugin-pnpm"]}},repository:{type:"git",url:"ssh://git@github.com/yarnpkg/berry.git",directory:"packages/yarnpkg-cli"},engines:{node:">=12 <14 || 14.2 - 14.9 || >14.10.0"}}});var iL=E((SBt,QAe)=>{"use strict";QAe.exports=function(e,r){r===!0&&(r=0);var i=e.indexOf("://"),n=e.substring(0,i).split("+").filter(Boolean);return typeof r=="number"?n[r]:n}});var nL=E((xBt,bAe)=>{"use strict";var sze=iL();function vAe(t){if(Array.isArray(t))return t.indexOf("ssh")!==-1||t.indexOf("rsync")!==-1;if(typeof t!="string")return!1;var e=sze(t);return t=t.substring(t.indexOf("://")+3),vAe(e)?!0:t.indexOf("@"){"use strict";var oze=iL(),aze=nL(),Aze=require("querystring");function lze(t){t=(t||"").trim();var e={protocols:oze(t),protocol:null,port:null,resource:"",user:"",pathname:"",hash:"",search:"",href:t,query:Object.create(null)},r=t.indexOf("://"),i=-1,n=null,s=null;t.startsWith(".")&&(t.startsWith("./")&&(t=t.substring(2)),e.pathname=t,e.protocol="file");var o=t.charAt(1);return e.protocol||(e.protocol=e.protocols[0],e.protocol||(aze(t)?e.protocol="ssh":((o==="/"||o==="~")&&(t=t.substring(2)),e.protocol="file"))),r!==-1&&(t=t.substring(r+3)),s=t.split("/"),e.protocol!=="file"?e.resource=s.shift():e.resource="",n=e.resource.split("@"),n.length===2&&(e.user=n[0],e.resource=n[1]),n=e.resource.split(":"),n.length===2&&(e.resource=n[0],n[1]?(e.port=Number(n[1]),isNaN(e.port)&&(e.port=null,s.unshift(n[1]))):e.port=null),s=s.filter(Boolean),e.protocol==="file"?e.pathname=e.href:e.pathname=e.pathname||(e.protocol!=="file"||e.href[0]==="/"?"/":"")+s.join("/"),n=e.pathname.split("#"),n.length===2&&(e.pathname=n[0],e.hash=n[1]),n=e.pathname.split("?"),n.length===2&&(e.pathname=n[0],e.search=n[1]),e.query=Aze.parse(e.search),e.href=e.href.replace(/\/$/,""),e.pathname=e.pathname.replace(/\/$/,""),e}SAe.exports=lze});var DAe=E((PBt,kAe)=>{"use strict";var cze=typeof URL=="undefined"?require("url").URL:URL,PAe=(t,e)=>e.some(r=>r instanceof RegExp?r.test(t):r===t);kAe.exports=(t,e)=>{e=Object.assign({defaultProtocol:"http:",normalizeProtocol:!0,forceHttp:!1,forceHttps:!1,stripHash:!0,stripWWW:!0,removeQueryParameters:[/^utm_\w+/i],removeTrailingSlash:!0,removeDirectoryIndex:!1,sortQueryParameters:!0},e),Reflect.has(e,"normalizeHttps")&&(e.forceHttp=e.normalizeHttps),Reflect.has(e,"normalizeHttp")&&(e.forceHttps=e.normalizeHttp),Reflect.has(e,"stripFragment")&&(e.stripHash=e.stripFragment),t=t.trim();let r=t.startsWith("//");!r&&/^\.*\//.test(t)||(t=t.replace(/^(?!(?:\w+:)?\/\/)|^\/\//,e.defaultProtocol));let n=new cze(t);if(e.forceHttp&&e.forceHttps)throw new Error("The `forceHttp` and `forceHttps` options cannot be used together");if(e.forceHttp&&n.protocol==="https:"&&(n.protocol="http:"),e.forceHttps&&n.protocol==="http:"&&(n.protocol="https:"),e.stripHash&&(n.hash=""),n.pathname&&(n.pathname=n.pathname.replace(/((?![https?:]).)\/{2,}/g,(s,o)=>/^(?!\/)/g.test(o)?`${o}/`:"/")),n.pathname&&(n.pathname=decodeURI(n.pathname)),e.removeDirectoryIndex===!0&&(e.removeDirectoryIndex=[/^index\.[a-z]+$/]),Array.isArray(e.removeDirectoryIndex)&&e.removeDirectoryIndex.length>0){let s=n.pathname.split("/"),o=s[s.length-1];PAe(o,e.removeDirectoryIndex)&&(s=s.slice(0,s.length-1),n.pathname=s.slice(1).join("/")+"/")}if(n.hostname&&(n.hostname=n.hostname.replace(/\.$/,""),e.stripWWW&&/^www\.([a-z\-\d]{2,63})\.([a-z\.]{2,5})$/.test(n.hostname)&&(n.hostname=n.hostname.replace(/^www\./,""))),Array.isArray(e.removeQueryParameters))for(let s of[...n.searchParams.keys()])PAe(s,e.removeQueryParameters)&&n.searchParams.delete(s);return e.sortQueryParameters&&n.searchParams.sort(),t=n.toString(),(e.removeTrailingSlash||n.pathname==="/")&&(t=t.replace(/\/$/,"")),r&&!e.normalizeProtocol&&(t=t.replace(/^http:\/\//,"//")),t}});var FAe=E((DBt,RAe)=>{"use strict";var uze=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},gze=xAe(),fze=DAe();function hze(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(typeof t!="string"||!t.trim())throw new Error("Invalid url.");e&&((typeof e=="undefined"?"undefined":uze(e))!=="object"&&(e={stripFragment:!1}),t=fze(t,e));var r=gze(t);return r}RAe.exports=hze});var TAe=E((RBt,NAe)=>{"use strict";var pze=FAe(),LAe=nL();function dze(t){var e=pze(t);e.token="";var r=e.user.split(":");return r.length===2&&(r[1]==="x-oauth-basic"?e.token=r[0]:r[0]==="x-token-auth"&&(e.token=r[1])),LAe(e.protocols)||LAe(t)?e.protocol="ssh":e.protocols.length?e.protocol=e.protocols[0]:e.protocol="file",e.href=e.href.replace(/\/$/,""),e}NAe.exports=dze});var OAe=E((FBt,MAe)=>{"use strict";var Cze=TAe();function sL(t){if(typeof t!="string")throw new Error("The url must be a string.");var e=Cze(t),r=e.resource.split("."),i=null;switch(e.toString=function(l){return sL.stringify(this,l)},e.source=r.length>2?r.slice(1-r.length).join("."):e.source=e.resource,e.git_suffix=/\.git$/.test(e.pathname),e.name=decodeURIComponent(e.pathname.replace(/^\//,"").replace(/\.git$/,"")),e.owner=decodeURIComponent(e.user),e.source){case"git.cloudforge.com":e.owner=e.user,e.organization=r[0],e.source="cloudforge.com";break;case"visualstudio.com":if(e.resource==="vs-ssh.visualstudio.com"){i=e.name.split("/"),i.length===4&&(e.organization=i[1],e.owner=i[2],e.name=i[3],e.full_name=i[2]+"/"+i[3]);break}else{i=e.name.split("/"),i.length===2?(e.owner=i[1],e.name=i[1],e.full_name="_git/"+e.name):i.length===3?(e.name=i[2],i[0]==="DefaultCollection"?(e.owner=i[2],e.organization=i[0],e.full_name=e.organization+"/_git/"+e.name):(e.owner=i[0],e.full_name=e.owner+"/_git/"+e.name)):i.length===4&&(e.organization=i[0],e.owner=i[1],e.name=i[3],e.full_name=e.organization+"/"+e.owner+"/_git/"+e.name);break}case"dev.azure.com":case"azure.com":if(e.resource==="ssh.dev.azure.com"){i=e.name.split("/"),i.length===4&&(e.organization=i[1],e.owner=i[2],e.name=i[3]);break}else{i=e.name.split("/"),i.length===5?(e.organization=i[0],e.owner=i[1],e.name=i[4],e.full_name="_git/"+e.name):i.length===3?(e.name=i[2],i[0]==="DefaultCollection"?(e.owner=i[2],e.organization=i[0],e.full_name=e.organization+"/_git/"+e.name):(e.owner=i[0],e.full_name=e.owner+"/_git/"+e.name)):i.length===4&&(e.organization=i[0],e.owner=i[1],e.name=i[3],e.full_name=e.organization+"/"+e.owner+"/_git/"+e.name);break}default:i=e.name.split("/");var n=i.length-1;if(i.length>=2){var s=i.indexOf("blob",2),o=i.indexOf("tree",2),a=i.indexOf("commit",2);n=s>0?s-1:o>0?o-1:a>0?a-1:n,e.owner=i.slice(0,n).join("/"),e.name=i[n],a&&(e.commit=i[n+2])}e.ref="",e.filepathtype="",e.filepath="",i.length>n+2&&["blob","tree"].indexOf(i[n+1])>=0&&(e.filepathtype=i[n+1],e.ref=i[n+2],i.length>n+3&&(e.filepath=i.slice(n+3).join("/"))),e.organization=e.owner;break}return e.full_name||(e.full_name=e.owner,e.name&&(e.full_name&&(e.full_name+="/"),e.full_name+=e.name)),e}sL.stringify=function(t,e){e=e||(t.protocols&&t.protocols.length?t.protocols.join("+"):t.protocol);var r=t.port?":"+t.port:"",i=t.user||"git",n=t.git_suffix?".git":"";switch(e){case"ssh":return r?"ssh://"+i+"@"+t.resource+r+"/"+t.full_name+n:i+"@"+t.resource+":"+t.full_name+n;case"git+ssh":case"ssh+git":case"ftp":case"ftps":return e+"://"+i+"@"+t.resource+r+"/"+t.full_name+n;case"http":case"https":var s=t.token?mze(t):t.user&&(t.protocols.includes("http")||t.protocols.includes("https"))?t.user+"@":"";return e+"://"+s+t.resource+r+"/"+t.full_name+n;default:return t.href}};function mze(t){switch(t.source){case"bitbucket.org":return"x-token-auth:"+t.token+"@";default:return t.token+"@"}}MAe.exports=sL});var NL=E((Obt,ole)=>{var Mze=jg(),Oze=Kg();function Kze(t,e,r){(r!==void 0&&!Oze(t[e],r)||r===void 0&&!(e in t))&&Mze(t,e,r)}ole.exports=Kze});var Ale=E((Kbt,ale)=>{var Uze=Hd(),Hze=Qo();function Gze(t){return Hze(t)&&Uze(t)}ale.exports=Gze});var ule=E((Ubt,lle)=>{var jze=Ac(),Yze=H0(),qze=Qo(),Jze="[object Object]",Wze=Function.prototype,zze=Object.prototype,cle=Wze.toString,Vze=zze.hasOwnProperty,_ze=cle.call(Object);function Xze(t){if(!qze(t)||jze(t)!=Jze)return!1;var e=Yze(t);if(e===null)return!0;var r=Vze.call(e,"constructor")&&e.constructor;return typeof r=="function"&&r instanceof r&&cle.call(r)==_ze}lle.exports=Xze});var LL=E((Hbt,gle)=>{function Zze(t,e){if(!(e==="constructor"&&typeof t[e]=="function")&&e!="__proto__")return t[e]}gle.exports=Zze});var hle=E((Gbt,fle)=>{var $ze=Af(),e5e=lf();function t5e(t){return $ze(t,e5e(t))}fle.exports=t5e});var Ile=E((jbt,ple)=>{var dle=NL(),r5e=UN(),i5e=jN(),n5e=HN(),s5e=YN(),Cle=Pd(),mle=As(),o5e=Ale(),a5e=Od(),A5e=zB(),l5e=Gs(),c5e=ule(),u5e=c0(),Ele=LL(),g5e=hle();function f5e(t,e,r,i,n,s,o){var a=Ele(t,r),l=Ele(e,r),c=o.get(l);if(c){dle(t,r,c);return}var u=s?s(a,l,r+"",t,e,o):void 0,g=u===void 0;if(g){var f=mle(l),h=!f&&a5e(l),p=!f&&!h&&u5e(l);u=l,f||h||p?mle(a)?u=a:o5e(a)?u=n5e(a):h?(g=!1,u=r5e(l,!0)):p?(g=!1,u=i5e(l,!0)):u=[]:c5e(l)||Cle(l)?(u=a,Cle(a)?u=g5e(a):(!l5e(a)||A5e(a))&&(u=s5e(l))):g=!1}g&&(o.set(l,u),n(u,l,i,s,o),o.delete(l)),dle(t,r,u)}ple.exports=f5e});var Ble=E((Ybt,yle)=>{var h5e=Gd(),p5e=NL(),d5e=BF(),C5e=Ile(),m5e=Gs(),E5e=lf(),I5e=LL();function wle(t,e,r,i,n){t!==e&&d5e(e,function(s,o){if(n||(n=new h5e),m5e(s))C5e(t,e,o,r,wle,i,n);else{var a=i?i(I5e(t,o),s,o+"",t,e,n):void 0;a===void 0&&(a=s),p5e(t,o,a)}},E5e)}yle.exports=wle});var ble=E((qbt,Qle)=>{var y5e=e0(),w5e=nF(),B5e=sF();function Q5e(t,e){return B5e(w5e(t,e,y5e),t+"")}Qle.exports=Q5e});var Sle=E((Jbt,vle)=>{var b5e=Kg(),v5e=Hd(),S5e=kd(),x5e=Gs();function k5e(t,e,r){if(!x5e(r))return!1;var i=typeof e;return(i=="number"?v5e(r)&&S5e(e,r.length):i=="string"&&e in r)?b5e(r[e],t):!1}vle.exports=k5e});var kle=E((Wbt,xle)=>{var P5e=ble(),D5e=Sle();function R5e(t){return P5e(function(e,r){var i=-1,n=r.length,s=n>1?r[n-1]:void 0,o=n>2?r[2]:void 0;for(s=t.length>3&&typeof s=="function"?(n--,s):void 0,o&&D5e(r[0],r[1],o)&&(s=n<3?void 0:s,n=1),e=Object(e);++i{var F5e=Ble(),N5e=kle(),L5e=N5e(function(t,e,r){F5e(t,e,r)});Ple.exports=L5e});var Wle=E(($vt,Jle)=>{var VL;Jle.exports=()=>(typeof VL=="undefined"&&(VL=require("zlib").brotliDecompressSync(Buffer.from("WxSteIBtDGp/1Rsko1+37VeQEmWILAWus2NIX9GQfXTamdxQ3DAVQZm/czI4dZrL7m2taiqoqpqbVIbMBngCLTBU/Z3f9icopIlQyRwSW0LmAd1xJBp0KShTakLvhLqFls9ECISbkeazt+a3Oz6WDcIQ0rgyHJrpCa+V4cmVQ2z4oM2JfN4j+7vMT96CNwkkkPaSsvdW3AmkfVxAApnLX5aOBjpOc3P7TNjG17v+MIABlUDmOqzCLLLbv11H5fHeze26jjOpgJE6N40WFR11m5pRVZE27TUgwrj1KxBDRB2mWGZPkat662N5RXbtr37ttfl5OkO+WOsjtp6CdnBKLX6mPgUXYbPeQnK4HXKv21cNTTU/x/thkJk1y4lIlXAEX2X5tnKBomsuEuC/3L/Kl6Djv67fzqYtzB3ZIfxZGZV/UVGEKpxXKOofHL63VOt0JTRRECeeZkOI2lsusUvit9l8Rgd4KcD+a6reezk9CohA64NZQ9UjO9Y2FA2HXpJXJtl7X5d93/58LZOCHFNmJNnm9NZxSuNKhWvm4hEGZ/UClh42aRS/vqnf77VZ9fwoZhBOL0qrl7KcXvJXWUBfGKx7D/27W4BcZUhgbakekjx1KunF96Ywq5naq6kYVY9yxv8gYRE0HApxX06hcmX/37dZ/fPzdeNZ0JvIcpZt7N4IhO7USQgH06uLsRXrARoM8rFEqlwzDGw3R0OYgB9g61P17dVUZ+d7BqHZ2XiEQ0iV9aEAEnTOqy3r+Z06w0o844wwrVRWlBK7/K4eKTEzN01fqlXV3/T3KXQIkM0YgRbQpkbwRIn3x4ODflri+GZ3k2zbbTslJW4Ei6ggvik8fNbr+uV2Zt5/eXStdt9OHJATA2YHDkgmZbOYj94QwWzZlqlngRfnXpKUIu5H2RZ/PPwFXGaGOb6qrl6yUmkixBsgNDEqIowBIcRS7fnIFdr9O+DSFmK5YFO/LgkI8dYp8oVL+VEyrT8edve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SO1Xkk08HfxaQb9B69clyEorTUG1uyyVBfsRqmltf4CCwx/TYvXe/zB3P9aIr6dyzXufkNPl4Uc/XdUDjrCywVM9Nn0Zn9VNZu+89x71cA+cgC1yXlCZremcn+D9wJZz+4v3j3/9KEqul87dklTfICvP4J/tkKSYAkp6S2/qidd8o1EXNSraYXIZ+UN9HAMg9ezqYizSLSrkVKC4HZ+JfExqOVGA7xLxxd97aN4YoNmCpcmk2o3CPoNTbJl6HSQHJaIVhyMGBVSGTANcrmCfvo754uZcA+lavfki67M584Fn1L5bcwncusGNdCe2OqVzreua1K0pRsJ3z8W5aOrhR7Ra+7qEXhdAw=","base64")).toString()),VL)});var $le=E(XL=>{function pf(t,e){if(typeof t=="string")return t;if(t){let r,i;if(Array.isArray(t)){for(r=0;r0)return(f=pf(n[g],u))?f.replace("*",c.substring(g.length-1)):Gc(i,c,1)}return Gc(i,c)}}function l6e(t,e={}){let r=0,i,n=e.browser,s=e.fields||["module","main"];for(n&&!s.includes("browser")&&s.unshift("browser");r{var eT;nce.exports=()=>(typeof eT=="undefined"&&(eT=require("zlib").brotliDecompressSync(Buffer.from("GzAfABynw5pcuBFmTv/70/1/f76uO9EY2rrhxLEWYC/7pSrhkeCCoArnFYpOj/QE6fHx/9uvLDqs7BiRsBXp++jMh+HuCQG8qpo/jQFCBS4aVBSu82uBpBshV9hdhtNJ5SY01hAgQGf92Yk6uIWH23NmLWpvI/fq4YaC6ep7dbhgBKxrceRcU3/MeT3keq5fx3N9Ilx5x6/unaWRPwdp0d46sZJnmNonGRAEgSIv8bIRDT92SKHtAQS1+L9lk0IfNBmC0P+Bzz15CLp7KzBkg7MGTxSRr0KLpulDDZQHK6cvj0DXQcCXhNZS6vUSVWoDpZrGhKjl/9sMLDCwpasO4JXS8geYKH2eJ98pCISCGGIZ4f0EaPFVw6g1hHTtBMdGyaSAuIZznuByTQOKR+LTBZo9rNzUzxL41JB6UziDRdbK0SYtv251lGn4hAgwg66Aaqv6ZEIZ0Glk1ao5S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GHHyoyq8v7VrX0YQqg8iaeZl8sGD2r0TEr+1Wj4x0bmZ6WUHSr2bx3/PGu5d/zsmmxKglKna2lnstwta3+nqyEhQZBe4QKV+1KkZp5HS1l75WuhJZuvd9bmt6KHrwf2f7kE8iR8s+oImRLwXVi6Fum4EeYQb9lUh8LyKgqe9A/FpksPVbqXYPY7G3ansEqdF3IClEzzIKkmQubjcGQlnUTOq9KF1u98uogWAaJ3eBDErzN3rzz0Y5UGZggNlcV6uBKsdqrl1VeAq04LUyMnCENsPVETgA=","base64")).toString()),eT)});var gce=E((aT,AT)=>{(function(t){aT&&typeof aT=="object"&&typeof AT!="undefined"?AT.exports=t():typeof define=="function"&&define.amd?define([],t):typeof window!="undefined"?window.isWindows=t():typeof global!="undefined"?global.isWindows=t():typeof self!="undefined"?self.isWindows=t():this.isWindows=t()})(function(){"use strict";return function(){return process&&(process.platform==="win32"||/^(msys|cygwin)$/.test(process.env.OSTYPE))}})});var dce=E((Dxt,fce)=>{"use strict";lT.ifExists=E6e;var mf=require("util"),Es=require("path"),hce=gce(),I6e=/^#!\s*(?:\/usr\/bin\/env)?\s*([^ \t]+)(.*)$/,y6e={createPwshFile:!0,createCmdFile:hce(),fs:require("fs")},w6e=new Map([[".js","node"],[".cjs","node"],[".mjs","node"],[".cmd","cmd"],[".bat","cmd"],[".ps1","pwsh"],[".sh","sh"]]);function pce(t){let e=P(P({},y6e),t),r=e.fs;return e.fs_={chmod:r.chmod?mf.promisify(r.chmod):async()=>{},mkdir:mf.promisify(r.mkdir),readFile:mf.promisify(r.readFile),stat:mf.promisify(r.stat),unlink:mf.promisify(r.unlink),writeFile:mf.promisify(r.writeFile)},e}async function lT(t,e,r){let i=pce(r);await i.fs_.stat(t),await B6e(t,e,i)}function E6e(t,e,r){return lT(t,e,r).catch(()=>{})}function Q6e(t,e){return e.fs_.unlink(t).catch(()=>{})}async function B6e(t,e,r){let i=await S6e(t,r);return await b6e(e,r),v6e(t,e,i,r)}function b6e(t,e){return e.fs_.mkdir(Es.dirname(t),{recursive:!0})}function v6e(t,e,r,i){let n=pce(i),s=[{generator:P6e,extension:""}];return n.createCmdFile&&s.push({generator:k6e,extension:".cmd"}),n.createPwshFile&&s.push({generator:D6e,extension:".ps1"}),Promise.all(s.map(o=>x6e(t,e+o.extension,r,o.generator,n)))}function R6e(t,e){return Q6e(t,e)}function N6e(t,e){return F6e(t,e)}async function S6e(t,e){let n=(await e.fs_.readFile(t,"utf8")).trim().split(/\r*\n/)[0].match(I6e);if(!n){let s=Es.extname(t).toLowerCase();return{program:w6e.get(s)||null,additionalArgs:""}}return{program:n[1],additionalArgs:n[2]}}async function x6e(t,e,r,i,n){let s=n.preserveSymlinks?"--preserve-symlinks":"",o=[r.additionalArgs,s].filter(a=>a).join(" ");return n=Object.assign({},n,{prog:r.program,args:o}),await R6e(e,n),await n.fs_.writeFile(e,i(t,e,n),"utf8"),N6e(e,n)}function k6e(t,e,r){let n=Es.relative(Es.dirname(e),t).split("/").join("\\"),s=Es.isAbsolute(n)?`"${n}"`:`"%~dp0\\${n}"`,o,a=r.prog,l=r.args||"",c=cT(r.nodePath).win32;a?(o=`"%~dp0\\${a}.exe"`,n=s):(a=s,l="",n="");let u=r.progArgs?`${r.progArgs.join(" ")} `:"",g=c?`@SET NODE_PATH=${c}\r +`:"";return o?g+=`@IF EXIST ${o} (\r + ${o} ${l} ${n} ${u}%*\r +) ELSE (\r + @SETLOCAL\r + @SET PATHEXT=%PATHEXT:;.JS;=;%\r + ${a} ${l} ${n} ${u}%*\r +)\r +`:g+=`@${a} ${l} ${n} ${u}%*\r +`,g}function P6e(t,e,r){let i=Es.relative(Es.dirname(e),t),n=r.prog&&r.prog.split("\\").join("/"),s;i=i.split("\\").join("/");let o=Es.isAbsolute(i)?`"${i}"`:`"$basedir/${i}"`,a=r.args||"",l=cT(r.nodePath).posix;n?(s=`"$basedir/${r.prog}"`,i=o):(n=o,a="",i="");let c=r.progArgs?`${r.progArgs.join(" ")} `:"",u=`#!/bin/sh +basedir=$(dirname "$(echo "$0" | sed -e 's,\\\\,/,g')") + +case \`uname\` in + *CYGWIN*) basedir=\`cygpath -w "$basedir"\`;; +esac + +`,g=r.nodePath?`export NODE_PATH="${l}" +`:"";return s?u+=`${g}if [ -x ${s} ]; then + exec ${s} ${a} ${i} ${c}"$@" +else + exec ${n} ${a} ${i} ${c}"$@" +fi +`:u+=`${g}${n} ${a} ${i} ${c}"$@" +exit $? +`,u}function D6e(t,e,r){let i=Es.relative(Es.dirname(e),t),n=r.prog&&r.prog.split("\\").join("/"),s=n&&`"${n}$exe"`,o;i=i.split("\\").join("/");let a=Es.isAbsolute(i)?`"${i}"`:`"$basedir/${i}"`,l=r.args||"",c=cT(r.nodePath),u=c.win32,g=c.posix;s?(o=`"$basedir/${r.prog}$exe"`,i=a):(s=a,l="",i="");let f=r.progArgs?`${r.progArgs.join(" ")} `:"",h=`#!/usr/bin/env pwsh +$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent + +$exe="" +${r.nodePath?`$env_node_path=$env:NODE_PATH +$env:NODE_PATH="${u}" +`:""}if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) { + # Fix case when both the Windows and Linux builds of Node + # are installed in the same directory + $exe=".exe" +}`;return r.nodePath&&(h+=` else { + $env:NODE_PATH="${g}" +}`),o?h+=` +$ret=0 +if (Test-Path ${o}) { + # Support pipeline input + if ($MyInvocation.ExpectingInput) { + $input | & ${o} ${l} ${i} ${f}$args + } else { + & ${o} ${l} ${i} ${f}$args + } + $ret=$LASTEXITCODE +} else { + # Support pipeline input + if ($MyInvocation.ExpectingInput) { + $input | & ${s} ${l} ${i} ${f}$args + } else { + & ${s} ${l} ${i} ${f}$args + } + $ret=$LASTEXITCODE +} +${r.nodePath?`$env:NODE_PATH=$env_node_path +`:""}exit $ret +`:h+=` +# Support pipeline input +if ($MyInvocation.ExpectingInput) { + $input | & ${s} ${l} ${i} ${f}$args +} else { + & ${s} ${l} ${i} ${f}$args +} +${r.nodePath?`$env:NODE_PATH=$env_node_path +`:""}exit $LASTEXITCODE +`,h}function F6e(t,e){return e.fs_.chmod(t,493)}function cT(t){if(!t)return{win32:"",posix:""};let e=typeof t=="string"?t.split(Es.delimiter):Array.from(t),r={};for(let i=0;i`/mnt/${a.toLowerCase()}`):e[i];r.win32=r.win32?`${r.win32};${n}`:n,r.posix=r.posix?`${r.posix}:${s}`:s,r[i]={win32:n,posix:s}}return r}fce.exports=lT});var PT=E((fPt,Nce)=>{Nce.exports=require("stream")});var Oce=E((hPt,Lce)=>{"use strict";function Tce(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),r.push.apply(r,i)}return r}function e9e(t){for(var e=1;e0?this.tail.next=i:this.head=i,this.tail=i,++this.length}},{key:"unshift",value:function(r){var i={data:r,next:this.head};this.length===0&&(this.tail=i),this.head=i,++this.length}},{key:"shift",value:function(){if(this.length!==0){var r=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,r}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(r){if(this.length===0)return"";for(var i=this.head,n=""+i.data;i=i.next;)n+=r+i.data;return n}},{key:"concat",value:function(r){if(this.length===0)return iQ.alloc(0);for(var i=iQ.allocUnsafe(r>>>0),n=this.head,s=0;n;)o9e(n.data,i,s),s+=n.data.length,n=n.next;return i}},{key:"consume",value:function(r,i){var n;return ro.length?o.length:r;if(a===o.length?s+=o:s+=o.slice(0,r),r-=a,r===0){a===o.length?(++n,i.next?this.head=i.next:this.head=this.tail=null):(this.head=i,i.data=o.slice(a));break}++n}return this.length-=n,s}},{key:"_getBuffer",value:function(r){var i=iQ.allocUnsafe(r),n=this.head,s=1;for(n.data.copy(i),r-=n.data.length;n=n.next;){var o=n.data,a=r>o.length?o.length:r;if(o.copy(i,i.length-r,0,a),r-=a,r===0){a===o.length?(++s,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=o.slice(a));break}++s}return this.length-=s,i}},{key:s9e,value:function(r,i){return DT(this,e9e({},i,{depth:0,customInspect:!1}))}}]),t}()});var FT=E((pPt,Kce)=>{"use strict";function a9e(t,e){var r=this,i=this._readableState&&this._readableState.destroyed,n=this._writableState&&this._writableState.destroyed;return i||n?(e?e(t):t&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(RT,this,t)):process.nextTick(RT,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(s){!e&&s?r._writableState?r._writableState.errorEmitted?process.nextTick(nQ,r):(r._writableState.errorEmitted=!0,process.nextTick(Uce,r,s)):process.nextTick(Uce,r,s):e?(process.nextTick(nQ,r),e(s)):process.nextTick(nQ,r)}),this)}function Uce(t,e){RT(t,e),nQ(t)}function nQ(t){t._writableState&&!t._writableState.emitClose||t._readableState&&!t._readableState.emitClose||t.emit("close")}function A9e(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function RT(t,e){t.emit("error",e)}function l9e(t,e){var r=t._readableState,i=t._writableState;r&&r.autoDestroy||i&&i.autoDestroy?t.destroy(e):t.emit("error",e)}Kce.exports={destroy:a9e,undestroy:A9e,errorOrDestroy:l9e}});var VA=E((dPt,Hce)=>{"use strict";var Gce={};function Is(t,e,r){r||(r=Error);function i(s,o,a){return typeof e=="string"?e:e(s,o,a)}class n extends r{constructor(o,a,l){super(i(o,a,l))}}n.prototype.name=r.name,n.prototype.code=t,Gce[t]=n}function jce(t,e){if(Array.isArray(t)){let r=t.length;return t=t.map(i=>String(i)),r>2?`one of ${e} ${t.slice(0,r-1).join(", ")}, or `+t[r-1]:r===2?`one of ${e} ${t[0]} or ${t[1]}`:`of ${e} ${t[0]}`}else return`of ${e} ${String(t)}`}function c9e(t,e,r){return t.substr(!r||r<0?0:+r,e.length)===e}function u9e(t,e,r){return(r===void 0||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}function g9e(t,e,r){return typeof r!="number"&&(r=0),r+e.length>t.length?!1:t.indexOf(e,r)!==-1}Is("ERR_INVALID_OPT_VALUE",function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'},TypeError);Is("ERR_INVALID_ARG_TYPE",function(t,e,r){let i;typeof e=="string"&&c9e(e,"not ")?(i="must not be",e=e.replace(/^not /,"")):i="must be";let n;if(u9e(t," argument"))n=`The ${t} ${i} ${jce(e,"type")}`;else{let s=g9e(t,".")?"property":"argument";n=`The "${t}" ${s} ${i} ${jce(e,"type")}`}return n+=`. Received type ${typeof r}`,n},TypeError);Is("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");Is("ERR_METHOD_NOT_IMPLEMENTED",function(t){return"The "+t+" method is not implemented"});Is("ERR_STREAM_PREMATURE_CLOSE","Premature close");Is("ERR_STREAM_DESTROYED",function(t){return"Cannot call "+t+" after a stream was destroyed"});Is("ERR_MULTIPLE_CALLBACK","Callback called multiple times");Is("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");Is("ERR_STREAM_WRITE_AFTER_END","write after end");Is("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);Is("ERR_UNKNOWN_ENCODING",function(t){return"Unknown encoding: "+t},TypeError);Is("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");Hce.exports.codes=Gce});var NT=E((CPt,Yce)=>{"use strict";var f9e=VA().codes.ERR_INVALID_OPT_VALUE;function h9e(t,e,r){return t.highWaterMark!=null?t.highWaterMark:e?t[r]:null}function p9e(t,e,r,i){var n=h9e(e,i,r);if(n!=null){if(!(isFinite(n)&&Math.floor(n)===n)||n<0){var s=i?r:"highWaterMark";throw new f9e(s,n)}return Math.floor(n)}return t.objectMode?16:16*1024}Yce.exports={getHighWaterMark:p9e}});var qce=E((mPt,LT)=>{typeof Object.create=="function"?LT.exports=function(e,r){r&&(e.super_=r,e.prototype=Object.create(r.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:LT.exports=function(e,r){if(r){e.super_=r;var i=function(){};i.prototype=r.prototype,e.prototype=new i,e.prototype.constructor=e}}});var _A=E((EPt,TT)=>{try{if(MT=require("util"),typeof MT.inherits!="function")throw"";TT.exports=MT.inherits}catch(t){TT.exports=qce()}var MT});var Wce=E((IPt,Jce)=>{Jce.exports=require("util").deprecate});var UT=E((yPt,zce)=>{"use strict";zce.exports=Sr;function Vce(t){var e=this;this.next=null,this.entry=null,this.finish=function(){d9e(e,t)}}var If;Sr.WritableState=em;var C9e={deprecate:Wce()},_ce=PT(),sQ=require("buffer").Buffer,m9e=global.Uint8Array||function(){};function E9e(t){return sQ.from(t)}function I9e(t){return sQ.isBuffer(t)||t instanceof m9e}var OT=FT(),y9e=NT(),w9e=y9e.getHighWaterMark,XA=VA().codes,B9e=XA.ERR_INVALID_ARG_TYPE,Q9e=XA.ERR_METHOD_NOT_IMPLEMENTED,b9e=XA.ERR_MULTIPLE_CALLBACK,v9e=XA.ERR_STREAM_CANNOT_PIPE,S9e=XA.ERR_STREAM_DESTROYED,x9e=XA.ERR_STREAM_NULL_VALUES,k9e=XA.ERR_STREAM_WRITE_AFTER_END,P9e=XA.ERR_UNKNOWN_ENCODING,yf=OT.errorOrDestroy;_A()(Sr,_ce);function D9e(){}function em(t,e,r){If=If||Yc(),t=t||{},typeof r!="boolean"&&(r=e instanceof If),this.objectMode=!!t.objectMode,r&&(this.objectMode=this.objectMode||!!t.writableObjectMode),this.highWaterMark=w9e(this,t,"writableHighWaterMark",r),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var i=t.decodeStrings===!1;this.decodeStrings=!i,this.defaultEncoding=t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(n){R9e(e,n)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=t.emitClose!==!1,this.autoDestroy=!!t.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new Vce(this)}em.prototype.getBuffer=function(){for(var e=this.bufferedRequest,r=[];e;)r.push(e),e=e.next;return r};(function(){try{Object.defineProperty(em.prototype,"buffer",{get:C9e.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(t){}})();var oQ;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(oQ=Function.prototype[Symbol.hasInstance],Object.defineProperty(Sr,Symbol.hasInstance,{value:function(e){return oQ.call(this,e)?!0:this!==Sr?!1:e&&e._writableState instanceof em}})):oQ=function(e){return e instanceof this};function Sr(t){If=If||Yc();var e=this instanceof If;if(!e&&!oQ.call(Sr,this))return new Sr(t);this._writableState=new em(t,this,e),this.writable=!0,t&&(typeof t.write=="function"&&(this._write=t.write),typeof t.writev=="function"&&(this._writev=t.writev),typeof t.destroy=="function"&&(this._destroy=t.destroy),typeof t.final=="function"&&(this._final=t.final)),_ce.call(this)}Sr.prototype.pipe=function(){yf(this,new v9e)};function F9e(t,e){var r=new k9e;yf(t,r),process.nextTick(e,r)}function N9e(t,e,r,i){var n;return r===null?n=new x9e:typeof r!="string"&&!e.objectMode&&(n=new B9e("chunk",["string","Buffer"],r)),n?(yf(t,n),process.nextTick(i,n),!1):!0}Sr.prototype.write=function(t,e,r){var i=this._writableState,n=!1,s=!i.objectMode&&I9e(t);return s&&!sQ.isBuffer(t)&&(t=E9e(t)),typeof e=="function"&&(r=e,e=null),s?e="buffer":e||(e=i.defaultEncoding),typeof r!="function"&&(r=D9e),i.ending?F9e(this,r):(s||N9e(this,i,t,r))&&(i.pendingcb++,n=L9e(this,i,s,t,e,r)),n};Sr.prototype.cork=function(){this._writableState.corked++};Sr.prototype.uncork=function(){var t=this._writableState;t.corked&&(t.corked--,!t.writing&&!t.corked&&!t.bufferProcessing&&t.bufferedRequest&&Xce(this,t))};Sr.prototype.setDefaultEncoding=function(e){if(typeof e=="string"&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new P9e(e);return this._writableState.defaultEncoding=e,this};Object.defineProperty(Sr.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function T9e(t,e,r){return!t.objectMode&&t.decodeStrings!==!1&&typeof e=="string"&&(e=sQ.from(e,r)),e}Object.defineProperty(Sr.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function L9e(t,e,r,i,n,s){if(!r){var o=T9e(e,i,n);i!==o&&(r=!0,n="buffer",i=o)}var a=e.objectMode?1:i.length;e.length+=a;var l=e.length{"use strict";var j9e=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};eue.exports=Mo;var tue=HT(),GT=UT();_A()(Mo,tue);for(jT=j9e(GT.prototype),aQ=0;aQ{var lQ=require("buffer"),qa=lQ.Buffer;function iue(t,e){for(var r in t)e[r]=t[r]}qa.from&&qa.alloc&&qa.allocUnsafe&&qa.allocUnsafeSlow?rue.exports=lQ:(iue(lQ,YT),YT.Buffer=wf);function wf(t,e,r){return qa(t,e,r)}iue(qa,wf);wf.from=function(t,e,r){if(typeof t=="number")throw new TypeError("Argument must not be a number");return qa(t,e,r)};wf.alloc=function(t,e,r){if(typeof t!="number")throw new TypeError("Argument must be a number");var i=qa(t);return e!==void 0?typeof r=="string"?i.fill(e,r):i.fill(e):i.fill(0),i};wf.allocUnsafe=function(t){if(typeof t!="number")throw new TypeError("Argument must be a number");return qa(t)};wf.allocUnsafeSlow=function(t){if(typeof t!="number")throw new TypeError("Argument must be a number");return lQ.SlowBuffer(t)}});var WT=E(sue=>{"use strict";var qT=nue().Buffer,oue=qT.isEncoding||function(t){switch(t=""+t,t&&t.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function J9e(t){if(!t)return"utf8";for(var e;;)switch(t){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return t;default:if(e)return;t=(""+t).toLowerCase(),e=!0}}function W9e(t){var e=J9e(t);if(typeof e!="string"&&(qT.isEncoding===oue||!oue(t)))throw new Error("Unknown encoding: "+t);return e||t}sue.StringDecoder=rm;function rm(t){this.encoding=W9e(t);var e;switch(this.encoding){case"utf16le":this.text=V9e,this.end=_9e,e=4;break;case"utf8":this.fillLast=z9e,e=4;break;case"base64":this.text=X9e,this.end=Z9e,e=3;break;default:this.write=$9e,this.end=eVe;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=qT.allocUnsafe(e)}rm.prototype.write=function(t){if(t.length===0)return"";var e,r;if(this.lastNeed){if(e=this.fillLast(t),e===void 0)return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r>5==6?2:t>>4==14?3:t>>3==30?4:t>>6==2?-1:-2}function iVe(t,e,r){var i=e.length-1;if(i=0?(n>0&&(t.lastNeed=n-1),n):--i=0?(n>0&&(t.lastNeed=n-2),n):--i=0?(n>0&&(n===2?n=0:t.lastNeed=n-3),n):0))}function nVe(t,e,r){if((e[0]&192)!=128)return t.lastNeed=0,"\uFFFD";if(t.lastNeed>1&&e.length>1){if((e[1]&192)!=128)return t.lastNeed=1,"\uFFFD";if(t.lastNeed>2&&e.length>2&&(e[2]&192)!=128)return t.lastNeed=2,"\uFFFD"}}function z9e(t){var e=this.lastTotal-this.lastNeed,r=nVe(this,t,e);if(r!==void 0)return r;if(this.lastNeed<=t.length)return t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,e,0,t.length),this.lastNeed-=t.length}function rVe(t,e){var r=iVe(this,t,e);if(!this.lastNeed)return t.toString("utf8",e);this.lastTotal=r;var i=t.length-(r-this.lastNeed);return t.copy(this.lastChar,0,i),t.toString("utf8",e,i)}function tVe(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+"\uFFFD":e}function V9e(t,e){if((t.length-e)%2==0){var r=t.toString("utf16le",e);if(r){var i=r.charCodeAt(r.length-1);if(i>=55296&&i<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=t[t.length-1],t.toString("utf16le",e,t.length-1)}function _9e(t){var e=t&&t.length?this.write(t):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return e+this.lastChar.toString("utf16le",0,r)}return e}function X9e(t,e){var r=(t.length-e)%3;return r===0?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,r===1?this.lastChar[0]=t[t.length-1]:(this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1]),t.toString("base64",e,t.length-r))}function Z9e(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function $9e(t){return t.toString(this.encoding)}function eVe(t){return t&&t.length?this.write(t):""}});var cQ=E((QPt,aue)=>{"use strict";var Aue=VA().codes.ERR_STREAM_PREMATURE_CLOSE;function sVe(t){var e=!1;return function(){if(!e){e=!0;for(var r=arguments.length,i=new Array(r),n=0;n{"use strict";var uQ;function ZA(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var AVe=cQ(),$A=Symbol("lastResolve"),qc=Symbol("lastReject"),im=Symbol("error"),gQ=Symbol("ended"),Jc=Symbol("lastPromise"),zT=Symbol("handlePromise"),Wc=Symbol("stream");function el(t,e){return{value:t,done:e}}function lVe(t){var e=t[$A];if(e!==null){var r=t[Wc].read();r!==null&&(t[Jc]=null,t[$A]=null,t[qc]=null,e(el(r,!1)))}}function cVe(t){process.nextTick(lVe,t)}function uVe(t,e){return function(r,i){t.then(function(){if(e[gQ]){r(el(void 0,!0));return}e[zT](r,i)},i)}}var gVe=Object.getPrototypeOf(function(){}),fVe=Object.setPrototypeOf((uQ={get stream(){return this[Wc]},next:function(){var e=this,r=this[im];if(r!==null)return Promise.reject(r);if(this[gQ])return Promise.resolve(el(void 0,!0));if(this[Wc].destroyed)return new Promise(function(o,a){process.nextTick(function(){e[im]?a(e[im]):o(el(void 0,!0))})});var i=this[Jc],n;if(i)n=new Promise(uVe(i,this));else{var s=this[Wc].read();if(s!==null)return Promise.resolve(el(s,!1));n=new Promise(this[zT])}return this[Jc]=n,n}},ZA(uQ,Symbol.asyncIterator,function(){return this}),ZA(uQ,"return",function(){var e=this;return new Promise(function(r,i){e[Wc].destroy(null,function(n){if(n){i(n);return}r(el(void 0,!0))})})}),uQ),gVe),hVe=function(e){var r,i=Object.create(fVe,(r={},ZA(r,Wc,{value:e,writable:!0}),ZA(r,$A,{value:null,writable:!0}),ZA(r,qc,{value:null,writable:!0}),ZA(r,im,{value:null,writable:!0}),ZA(r,gQ,{value:e._readableState.endEmitted,writable:!0}),ZA(r,zT,{value:function(s,o){var a=i[Wc].read();a?(i[Jc]=null,i[$A]=null,i[qc]=null,s(el(a,!1))):(i[$A]=s,i[qc]=o)},writable:!0}),r));return i[Jc]=null,AVe(e,function(n){if(n&&n.code!=="ERR_STREAM_PREMATURE_CLOSE"){var s=i[qc];s!==null&&(i[Jc]=null,i[$A]=null,i[qc]=null,s(n)),i[im]=n;return}var o=i[$A];o!==null&&(i[Jc]=null,i[$A]=null,i[qc]=null,o(el(void 0,!0))),i[gQ]=!0}),e.on("readable",cVe.bind(null,i)),i};cue.exports=hVe});var pue=E((vPt,gue)=>{"use strict";function fue(t,e,r,i,n,s,o){try{var a=t[s](o),l=a.value}catch(c){r(c);return}a.done?e(l):Promise.resolve(l).then(i,n)}function pVe(t){return function(){var e=this,r=arguments;return new Promise(function(i,n){var s=t.apply(e,r);function o(l){fue(s,i,n,o,a,"next",l)}function a(l){fue(s,i,n,o,a,"throw",l)}o(void 0)})}}function hue(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),r.push.apply(r,i)}return r}function CVe(t){for(var e=1;e{"use strict";due.exports=kt;var Bf;kt.ReadableState=Cue;var SPt=require("events").EventEmitter,mue=function(e,r){return e.listeners(r).length},nm=PT(),fQ=require("buffer").Buffer,IVe=global.Uint8Array||function(){};function yVe(t){return fQ.from(t)}function wVe(t){return fQ.isBuffer(t)||t instanceof IVe}var VT=require("util"),Et;VT&&VT.debuglog?Et=VT.debuglog("stream"):Et=function(){};var BVe=Oce(),_T=FT(),QVe=NT(),bVe=QVe.getHighWaterMark,hQ=VA().codes,vVe=hQ.ERR_INVALID_ARG_TYPE,SVe=hQ.ERR_STREAM_PUSH_AFTER_EOF,xVe=hQ.ERR_METHOD_NOT_IMPLEMENTED,kVe=hQ.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,Qf,XT,ZT;_A()(kt,nm);var sm=_T.errorOrDestroy,$T=["error","close","destroy","pause","resume"];function PVe(t,e,r){if(typeof t.prependListener=="function")return t.prependListener(e,r);!t._events||!t._events[e]?t.on(e,r):Array.isArray(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]}function Cue(t,e,r){Bf=Bf||Yc(),t=t||{},typeof r!="boolean"&&(r=e instanceof Bf),this.objectMode=!!t.objectMode,r&&(this.objectMode=this.objectMode||!!t.readableObjectMode),this.highWaterMark=bVe(this,t,"readableHighWaterMark",r),this.buffer=new BVe,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=t.emitClose!==!1,this.autoDestroy=!!t.autoDestroy,this.destroyed=!1,this.defaultEncoding=t.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,t.encoding&&(Qf||(Qf=WT().StringDecoder),this.decoder=new Qf(t.encoding),this.encoding=t.encoding)}function kt(t){if(Bf=Bf||Yc(),!(this instanceof kt))return new kt(t);var e=this instanceof Bf;this._readableState=new Cue(t,this,e),this.readable=!0,t&&(typeof t.read=="function"&&(this._read=t.read),typeof t.destroy=="function"&&(this._destroy=t.destroy)),nm.call(this)}Object.defineProperty(kt.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(e){!this._readableState||(this._readableState.destroyed=e)}});kt.prototype.destroy=_T.destroy;kt.prototype._undestroy=_T.undestroy;kt.prototype._destroy=function(t,e){e(t)};kt.prototype.push=function(t,e){var r=this._readableState,i;return r.objectMode?i=!0:typeof t=="string"&&(e=e||r.defaultEncoding,e!==r.encoding&&(t=fQ.from(t,e),e=""),i=!0),Eue(this,t,e,!1,i)};kt.prototype.unshift=function(t){return Eue(this,t,null,!0,!1)};function Eue(t,e,r,i,n){Et("readableAddChunk",e);var s=t._readableState;if(e===null)s.reading=!1,RVe(t,s);else{var o;if(n||(o=DVe(s,e)),o)sm(t,o);else if(s.objectMode||e&&e.length>0)if(typeof e!="string"&&!s.objectMode&&Object.getPrototypeOf(e)!==fQ.prototype&&(e=yVe(e)),i)s.endEmitted?sm(t,new kVe):eM(t,s,e,!0);else if(s.ended)sm(t,new SVe);else{if(s.destroyed)return!1;s.reading=!1,s.decoder&&!r?(e=s.decoder.write(e),s.objectMode||e.length!==0?eM(t,s,e,!1):tM(t,s)):eM(t,s,e,!1)}else i||(s.reading=!1,tM(t,s))}return!s.ended&&(s.length=Iue?t=Iue:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}function yue(t,e){return t<=0||e.length===0&&e.ended?0:e.objectMode?1:t!==t?e.flowing&&e.length?e.buffer.head.data.length:e.length:(t>e.highWaterMark&&(e.highWaterMark=FVe(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}kt.prototype.read=function(t){Et("read",t),t=parseInt(t,10);var e=this._readableState,r=t;if(t!==0&&(e.emittedReadable=!1),t===0&&e.needReadable&&((e.highWaterMark!==0?e.length>=e.highWaterMark:e.length>0)||e.ended))return Et("read: emitReadable",e.length,e.ended),e.length===0&&e.ended?rM(this):pQ(this),null;if(t=yue(t,e),t===0&&e.ended)return e.length===0&&rM(this),null;var i=e.needReadable;Et("need readable",i),(e.length===0||e.length-t0?n=wue(t,e):n=null,n===null?(e.needReadable=e.length<=e.highWaterMark,t=0):(e.length-=t,e.awaitDrain=0),e.length===0&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&rM(this)),n!==null&&this.emit("data",n),n};function RVe(t,e){if(Et("onEofChunk"),!e.ended){if(e.decoder){var r=e.decoder.end();r&&r.length&&(e.buffer.push(r),e.length+=e.objectMode?1:r.length)}e.ended=!0,e.sync?pQ(t):(e.needReadable=!1,e.emittedReadable||(e.emittedReadable=!0,Bue(t)))}}function pQ(t){var e=t._readableState;Et("emitReadable",e.needReadable,e.emittedReadable),e.needReadable=!1,e.emittedReadable||(Et("emitReadable",e.flowing),e.emittedReadable=!0,process.nextTick(Bue,t))}function Bue(t){var e=t._readableState;Et("emitReadable_",e.destroyed,e.length,e.ended),!e.destroyed&&(e.length||e.ended)&&(t.emit("readable"),e.emittedReadable=!1),e.needReadable=!e.flowing&&!e.ended&&e.length<=e.highWaterMark,iM(t)}function tM(t,e){e.readingMore||(e.readingMore=!0,process.nextTick(NVe,t,e))}function NVe(t,e){for(;!e.reading&&!e.ended&&(e.length1&&Que(i.pipes,t)!==-1)&&!c&&(Et("false write response, pause",i.awaitDrain),i.awaitDrain++),r.pause())}function f(m){Et("onerror",m),d(),t.removeListener("error",f),mue(t,"error")===0&&sm(t,m)}PVe(t,"error",f);function h(){t.removeListener("finish",p),d()}t.once("close",h);function p(){Et("onfinish"),t.removeListener("close",h),d()}t.once("finish",p);function d(){Et("unpipe"),r.unpipe(t)}return t.emit("pipe",r),i.flowing||(Et("pipe resume"),r.resume()),t};function LVe(t){return function(){var r=t._readableState;Et("pipeOnDrain",r.awaitDrain),r.awaitDrain&&r.awaitDrain--,r.awaitDrain===0&&mue(t,"data")&&(r.flowing=!0,iM(t))}}kt.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(e.pipesCount===0)return this;if(e.pipesCount===1)return t&&t!==e.pipes?this:(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r),this);if(!t){var i=e.pipes,n=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var s=0;s0,i.flowing!==!1&&this.resume()):t==="readable"&&!i.endEmitted&&!i.readableListening&&(i.readableListening=i.needReadable=!0,i.flowing=!1,i.emittedReadable=!1,Et("on readable",i.length,i.reading),i.length?pQ(this):i.reading||process.nextTick(TVe,this)),r};kt.prototype.addListener=kt.prototype.on;kt.prototype.removeListener=function(t,e){var r=nm.prototype.removeListener.call(this,t,e);return t==="readable"&&process.nextTick(bue,this),r};kt.prototype.removeAllListeners=function(t){var e=nm.prototype.removeAllListeners.apply(this,arguments);return(t==="readable"||t===void 0)&&process.nextTick(bue,this),e};function bue(t){var e=t._readableState;e.readableListening=t.listenerCount("readable")>0,e.resumeScheduled&&!e.paused?e.flowing=!0:t.listenerCount("data")>0&&t.resume()}function TVe(t){Et("readable nexttick read 0"),t.read(0)}kt.prototype.resume=function(){var t=this._readableState;return t.flowing||(Et("resume"),t.flowing=!t.readableListening,MVe(this,t)),t.paused=!1,this};function MVe(t,e){e.resumeScheduled||(e.resumeScheduled=!0,process.nextTick(OVe,t,e))}function OVe(t,e){Et("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),iM(t),e.flowing&&!e.reading&&t.read(0)}kt.prototype.pause=function(){return Et("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(Et("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function iM(t){var e=t._readableState;for(Et("flow",e.flowing);e.flowing&&t.read()!==null;);}kt.prototype.wrap=function(t){var e=this,r=this._readableState,i=!1;t.on("end",function(){if(Et("wrapped end"),r.decoder&&!r.ended){var o=r.decoder.end();o&&o.length&&e.push(o)}e.push(null)}),t.on("data",function(o){if(Et("wrapped data"),r.decoder&&(o=r.decoder.write(o)),!(r.objectMode&&o==null)&&!(!r.objectMode&&(!o||!o.length))){var a=e.push(o);a||(i=!0,t.pause())}});for(var n in t)this[n]===void 0&&typeof t[n]=="function"&&(this[n]=function(a){return function(){return t[a].apply(t,arguments)}}(n));for(var s=0;s<$T.length;s++)t.on($T[s],this.emit.bind(this,$T[s]));return this._read=function(o){Et("wrapped _read",o),i&&(i=!1,t.resume())},this};typeof Symbol=="function"&&(kt.prototype[Symbol.asyncIterator]=function(){return XT===void 0&&(XT=uue()),XT(this)});Object.defineProperty(kt.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}});Object.defineProperty(kt.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}});Object.defineProperty(kt.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(e){this._readableState&&(this._readableState.flowing=e)}});kt._fromList=wue;Object.defineProperty(kt.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function wue(t,e){if(e.length===0)return null;var r;return e.objectMode?r=e.buffer.shift():!t||t>=e.length?(e.decoder?r=e.buffer.join(""):e.buffer.length===1?r=e.buffer.first():r=e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r}function rM(t){var e=t._readableState;Et("endReadable",e.endEmitted),e.endEmitted||(e.ended=!0,process.nextTick(KVe,e,t))}function KVe(t,e){if(Et("endReadableNT",t.endEmitted,t.length),!t.endEmitted&&t.length===0&&(t.endEmitted=!0,e.readable=!1,e.emit("end"),t.autoDestroy)){var r=e._writableState;(!r||r.autoDestroy&&r.finished)&&e.destroy()}}typeof Symbol=="function"&&(kt.from=function(t,e){return ZT===void 0&&(ZT=pue()),ZT(kt,t,e)});function Que(t,e){for(var r=0,i=t.length;r{"use strict";vue.exports=Ja;var dQ=VA().codes,UVe=dQ.ERR_METHOD_NOT_IMPLEMENTED,HVe=dQ.ERR_MULTIPLE_CALLBACK,GVe=dQ.ERR_TRANSFORM_ALREADY_TRANSFORMING,jVe=dQ.ERR_TRANSFORM_WITH_LENGTH_0,CQ=Yc();_A()(Ja,CQ);function YVe(t,e){var r=this._transformState;r.transforming=!1;var i=r.writecb;if(i===null)return this.emit("error",new HVe);r.writechunk=null,r.writecb=null,e!=null&&this.push(e),i(t);var n=this._readableState;n.reading=!1,(n.needReadable||n.length{"use strict";xue.exports=om;var kue=nM();_A()(om,kue);function om(t){if(!(this instanceof om))return new om(t);kue.call(this,t)}om.prototype._transform=function(t,e,r){r(null,t)}});var Lue=E((DPt,Due)=>{"use strict";var sM;function JVe(t){var e=!1;return function(){e||(e=!0,t.apply(void 0,arguments))}}var Rue=VA().codes,WVe=Rue.ERR_MISSING_ARGS,zVe=Rue.ERR_STREAM_DESTROYED;function Fue(t){if(t)throw t}function VVe(t){return t.setHeader&&typeof t.abort=="function"}function _Ve(t,e,r,i){i=JVe(i);var n=!1;t.on("close",function(){n=!0}),sM===void 0&&(sM=cQ()),sM(t,{readable:e,writable:r},function(o){if(o)return i(o);n=!0,i()});var s=!1;return function(o){if(!n&&!s){if(s=!0,VVe(t))return t.abort();if(typeof t.destroy=="function")return t.destroy();i(o||new zVe("pipe"))}}}function Nue(t){t()}function XVe(t,e){return t.pipe(e)}function ZVe(t){return!t.length||typeof t[t.length-1]!="function"?Fue:t.pop()}function $Ve(){for(var t=arguments.length,e=new Array(t),r=0;r0;return _Ve(o,l,c,function(u){n||(n=u),u&&s.forEach(Nue),!l&&(s.forEach(Nue),i(n))})});return e.reduce(XVe)}Due.exports=$Ve});var bf=E((ys,am)=>{var Am=require("stream");process.env.READABLE_STREAM==="disable"&&Am?(am.exports=Am.Readable,Object.assign(am.exports,Am),am.exports.Stream=Am):(ys=am.exports=HT(),ys.Stream=Am||ys,ys.Readable=ys,ys.Writable=UT(),ys.Duplex=Yc(),ys.Transform=nM(),ys.PassThrough=Pue(),ys.finished=cQ(),ys.pipeline=Lue())});var Oue=E((RPt,Tue)=>{"use strict";var{Buffer:_s}=require("buffer"),Mue=Symbol.for("BufferList");function nr(t){if(!(this instanceof nr))return new nr(t);nr._init.call(this,t)}nr._init=function(e){Object.defineProperty(this,Mue,{value:!0}),this._bufs=[],this.length=0,e&&this.append(e)};nr.prototype._new=function(e){return new nr(e)};nr.prototype._offset=function(e){if(e===0)return[0,0];let r=0;for(let i=0;ithis.length||e<0)return;let r=this._offset(e);return this._bufs[r[0]][r[1]]};nr.prototype.slice=function(e,r){return typeof e=="number"&&e<0&&(e+=this.length),typeof r=="number"&&r<0&&(r+=this.length),this.copy(null,0,e,r)};nr.prototype.copy=function(e,r,i,n){if((typeof i!="number"||i<0)&&(i=0),(typeof n!="number"||n>this.length)&&(n=this.length),i>=this.length||n<=0)return e||_s.alloc(0);let s=!!e,o=this._offset(i),a=n-i,l=a,c=s&&r||0,u=o[1];if(i===0&&n===this.length){if(!s)return this._bufs.length===1?this._bufs[0]:_s.concat(this._bufs,this.length);for(let g=0;gf)this._bufs[g].copy(e,c,u),c+=f;else{this._bufs[g].copy(e,c,u,u+l),c+=f;break}l-=f,u&&(u=0)}return e.length>c?e.slice(0,c):e};nr.prototype.shallowSlice=function(e,r){if(e=e||0,r=typeof r!="number"?this.length:r,e<0&&(e+=this.length),r<0&&(r+=this.length),e===r)return this._new();let i=this._offset(e),n=this._offset(r),s=this._bufs.slice(i[0],n[0]+1);return n[1]===0?s.pop():s[s.length-1]=s[s.length-1].slice(0,n[1]),i[1]!==0&&(s[0]=s[0].slice(i[1])),this._new(s)};nr.prototype.toString=function(e,r,i){return this.slice(r,i).toString(e)};nr.prototype.consume=function(e){if(e=Math.trunc(e),Number.isNaN(e)||e<=0)return this;for(;this._bufs.length;)if(e>=this._bufs[0].length)e-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift();else{this._bufs[0]=this._bufs[0].slice(e),this.length-=e;break}return this};nr.prototype.duplicate=function(){let e=this._new();for(let r=0;rthis.length?this.length:e;let i=this._offset(e),n=i[0],s=i[1];for(;n=t.length){let l=o.indexOf(t,s);if(l!==-1)return this._reverseOffset([n,l]);s=o.length-t.length+1}else{let l=this._reverseOffset([n,s]);if(this._match(l,t))return l;s++}s=0}return-1};nr.prototype._match=function(t,e){if(this.length-t{"use strict";var oM=bf().Duplex,e7e=_A(),lm=Oue();function Oi(t){if(!(this instanceof Oi))return new Oi(t);if(typeof t=="function"){this._callback=t;let e=function(i){this._callback&&(this._callback(i),this._callback=null)}.bind(this);this.on("pipe",function(i){i.on("error",e)}),this.on("unpipe",function(i){i.removeListener("error",e)}),t=null}lm._init.call(this,t),oM.call(this)}e7e(Oi,oM);Object.assign(Oi.prototype,lm.prototype);Oi.prototype._new=function(e){return new Oi(e)};Oi.prototype._write=function(e,r,i){this._appendBuffer(e),typeof i=="function"&&i()};Oi.prototype._read=function(e){if(!this.length)return this.push(null);e=Math.min(e,this.length),this.push(this.slice(0,e)),this.consume(e)};Oi.prototype.end=function(e){oM.prototype.end.call(this,e),this._callback&&(this._callback(null,this.slice()),this._callback=null)};Oi.prototype._destroy=function(e,r){this._bufs.length=0,this.length=0,r(e)};Oi.prototype._isBufferList=function(e){return e instanceof Oi||e instanceof lm||Oi.isBufferList(e)};Oi.isBufferList=lm.isBufferList;mQ.exports=Oi;mQ.exports.BufferListStream=Oi;mQ.exports.BufferList=lm});var lM=E(vf=>{var t7e=Buffer.alloc,r7e="0000000000000000000",i7e="7777777777777777777",Uue="0".charCodeAt(0),Hue=Buffer.from("ustar\0","binary"),n7e=Buffer.from("00","binary"),s7e=Buffer.from("ustar ","binary"),o7e=Buffer.from(" \0","binary"),a7e=parseInt("7777",8),cm=257,aM=263,A7e=function(t,e,r){return typeof t!="number"?r:(t=~~t,t>=e?e:t>=0||(t+=e,t>=0)?t:0)},l7e=function(t){switch(t){case 0:return"file";case 1:return"link";case 2:return"symlink";case 3:return"character-device";case 4:return"block-device";case 5:return"directory";case 6:return"fifo";case 7:return"contiguous-file";case 72:return"pax-header";case 55:return"pax-global-header";case 27:return"gnu-long-link-path";case 28:case 30:return"gnu-long-path"}return null},c7e=function(t){switch(t){case"file":return 0;case"link":return 1;case"symlink":return 2;case"character-device":return 3;case"block-device":return 4;case"directory":return 5;case"fifo":return 6;case"contiguous-file":return 7;case"pax-header":return 72}return 0},Gue=function(t,e,r,i){for(;re?i7e.slice(0,e)+" ":r7e.slice(0,e-t.length)+t+" "};function u7e(t){var e;if(t[0]===128)e=!0;else if(t[0]===255)e=!1;else return null;for(var r=[],i=t.length-1;i>0;i--){var n=t[i];e?r.push(n):r.push(255-n)}var s=0,o=r.length;for(i=0;i=Math.pow(10,r)&&r++,e+r+t};vf.decodeLongPath=function(t,e){return Sf(t,0,t.length,e)};vf.encodePax=function(t){var e="";t.name&&(e+=AM(" path="+t.name+` +`)),t.linkname&&(e+=AM(" linkpath="+t.linkname+` +`));var r=t.pax;if(r)for(var i in r)e+=AM(" "+i+"="+r[i]+` +`);return Buffer.from(e)};vf.decodePax=function(t){for(var e={};t.length;){for(var r=0;r100;){var n=r.indexOf("/");if(n===-1)return null;i+=i?"/"+r.slice(0,n):r.slice(0,n),r=r.slice(n+1)}return Buffer.byteLength(r)>100||Buffer.byteLength(i)>155||t.linkname&&Buffer.byteLength(t.linkname)>100?null:(e.write(r),e.write(tl(t.mode&a7e,6),100),e.write(tl(t.uid,6),108),e.write(tl(t.gid,6),116),e.write(tl(t.size,11),124),e.write(tl(t.mtime.getTime()/1e3|0,11),136),e[156]=Uue+c7e(t.type),t.linkname&&e.write(t.linkname,157),Hue.copy(e,cm),n7e.copy(e,aM),t.uname&&e.write(t.uname,265),t.gname&&e.write(t.gname,297),e.write(tl(t.devmajor||0,6),329),e.write(tl(t.devminor||0,6),337),i&&e.write(i,345),e.write(tl(jue(e),6),148),e)};vf.decode=function(t,e,r){var i=t[156]===0?0:t[156]-Uue,n=Sf(t,0,100,e),s=rl(t,100,8),o=rl(t,108,8),a=rl(t,116,8),l=rl(t,124,12),c=rl(t,136,12),u=l7e(i),g=t[157]===0?null:Sf(t,157,100,e),f=Sf(t,265,32),h=Sf(t,297,32),p=rl(t,329,8),d=rl(t,337,8),m=jue(t);if(m===8*32)return null;if(m!==rl(t,148,8))throw new Error("Invalid tar header. Maybe the tar is corrupted or it needs to be gunzipped?");if(Hue.compare(t,cm,cm+6)===0)t[345]&&(n=Sf(t,345,155,e)+"/"+n);else if(!(s7e.compare(t,cm,cm+6)===0&&o7e.compare(t,aM,aM+2)===0)){if(!r)throw new Error("Invalid tar header: unknown format.")}return i===0&&n&&n[n.length-1]==="/"&&(i=5),{name:n,mode:s,uid:o,gid:a,size:l,mtime:new Date(1e3*c),type:u,linkname:g,uname:f,gname:h,devmajor:p,devminor:d}}});var _ue=E((LPt,Yue)=>{var que=require("util"),g7e=Kue(),um=lM(),Jue=bf().Writable,Wue=bf().PassThrough,zue=function(){},Vue=function(t){return t&=511,t&&512-t},f7e=function(t,e){var r=new EQ(t,e);return r.end(),r},h7e=function(t,e){return e.path&&(t.name=e.path),e.linkpath&&(t.linkname=e.linkpath),e.size&&(t.size=parseInt(e.size,10)),t.pax=e,t},EQ=function(t,e){this._parent=t,this.offset=e,Wue.call(this,{autoDestroy:!1})};que.inherits(EQ,Wue);EQ.prototype.destroy=function(t){this._parent.destroy(t)};var Wa=function(t){if(!(this instanceof Wa))return new Wa(t);Jue.call(this,t),t=t||{},this._offset=0,this._buffer=g7e(),this._missing=0,this._partial=!1,this._onparse=zue,this._header=null,this._stream=null,this._overflow=null,this._cb=null,this._locked=!1,this._destroyed=!1,this._pax=null,this._paxGlobal=null,this._gnuLongPath=null,this._gnuLongLinkPath=null;var e=this,r=e._buffer,i=function(){e._continue()},n=function(f){if(e._locked=!1,f)return e.destroy(f);e._stream||i()},s=function(){e._stream=null;var f=Vue(e._header.size);f?e._parse(f,o):e._parse(512,g),e._locked||i()},o=function(){e._buffer.consume(Vue(e._header.size)),e._parse(512,g),i()},a=function(){var f=e._header.size;e._paxGlobal=um.decodePax(r.slice(0,f)),r.consume(f),s()},l=function(){var f=e._header.size;e._pax=um.decodePax(r.slice(0,f)),e._paxGlobal&&(e._pax=Object.assign({},e._paxGlobal,e._pax)),r.consume(f),s()},c=function(){var f=e._header.size;this._gnuLongPath=um.decodeLongPath(r.slice(0,f),t.filenameEncoding),r.consume(f),s()},u=function(){var f=e._header.size;this._gnuLongLinkPath=um.decodeLongPath(r.slice(0,f),t.filenameEncoding),r.consume(f),s()},g=function(){var f=e._offset,h;try{h=e._header=um.decode(r.slice(0,512),t.filenameEncoding,t.allowUnknownFormat)}catch(p){e.emit("error",p)}if(r.consume(512),!h){e._parse(512,g),i();return}if(h.type==="gnu-long-path"){e._parse(h.size,c),i();return}if(h.type==="gnu-long-link-path"){e._parse(h.size,u),i();return}if(h.type==="pax-global-header"){e._parse(h.size,a),i();return}if(h.type==="pax-header"){e._parse(h.size,l),i();return}if(e._gnuLongPath&&(h.name=e._gnuLongPath,e._gnuLongPath=null),e._gnuLongLinkPath&&(h.linkname=e._gnuLongLinkPath,e._gnuLongLinkPath=null),e._pax&&(e._header=h=h7e(h,e._pax),e._pax=null),e._locked=!0,!h.size||h.type==="directory"){e._parse(512,g),e.emit("entry",h,f7e(e,f),n);return}e._stream=new EQ(e,f),e.emit("entry",h,e._stream,n),e._parse(h.size,s),i()};this._onheader=g,this._parse(512,g)};que.inherits(Wa,Jue);Wa.prototype.destroy=function(t){this._destroyed||(this._destroyed=!0,t&&this.emit("error",t),this.emit("close"),this._stream&&this._stream.emit("close"))};Wa.prototype._parse=function(t,e){this._destroyed||(this._offset+=t,this._missing=t,e===this._onheader&&(this._partial=!1),this._onparse=e)};Wa.prototype._continue=function(){if(!this._destroyed){var t=this._cb;this._cb=zue,this._overflow?this._write(this._overflow,void 0,t):t()}};Wa.prototype._write=function(t,e,r){if(!this._destroyed){var i=this._stream,n=this._buffer,s=this._missing;if(t.length&&(this._partial=!0),t.lengths&&(o=t.slice(s),t=t.slice(0,s)),i?i.end(t):n.append(t),this._overflow=o,this._onparse()}};Wa.prototype._final=function(t){if(this._partial)return this.destroy(new Error("Unexpected end of data"));t()};Yue.exports=Wa});var Zue=E((TPt,Xue)=>{Xue.exports=require("fs").constants||require("constants")});var ige=E((MPt,$ue)=>{var xf=Zue(),ege=tk(),IQ=_A(),p7e=Buffer.alloc,tge=bf().Readable,kf=bf().Writable,d7e=require("string_decoder").StringDecoder,yQ=lM(),C7e=parseInt("755",8),m7e=parseInt("644",8),rge=p7e(1024),cM=function(){},uM=function(t,e){e&=511,e&&t.push(rge.slice(0,512-e))};function E7e(t){switch(t&xf.S_IFMT){case xf.S_IFBLK:return"block-device";case xf.S_IFCHR:return"character-device";case xf.S_IFDIR:return"directory";case xf.S_IFIFO:return"fifo";case xf.S_IFLNK:return"symlink"}return"file"}var wQ=function(t){kf.call(this),this.written=0,this._to=t,this._destroyed=!1};IQ(wQ,kf);wQ.prototype._write=function(t,e,r){if(this.written+=t.length,this._to.push(t))return r();this._to._drain=r};wQ.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var BQ=function(){kf.call(this),this.linkname="",this._decoder=new d7e("utf-8"),this._destroyed=!1};IQ(BQ,kf);BQ.prototype._write=function(t,e,r){this.linkname+=this._decoder.write(t),r()};BQ.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var gm=function(){kf.call(this),this._destroyed=!1};IQ(gm,kf);gm.prototype._write=function(t,e,r){r(new Error("No body allowed for this entry"))};gm.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var Oo=function(t){if(!(this instanceof Oo))return new Oo(t);tge.call(this,t),this._drain=cM,this._finalized=!1,this._finalizing=!1,this._destroyed=!1,this._stream=null};IQ(Oo,tge);Oo.prototype.entry=function(t,e,r){if(this._stream)throw new Error("already piping an entry");if(!(this._finalized||this._destroyed)){typeof e=="function"&&(r=e,e=null),r||(r=cM);var i=this;if((!t.size||t.type==="symlink")&&(t.size=0),t.type||(t.type=E7e(t.mode)),t.mode||(t.mode=t.type==="directory"?C7e:m7e),t.uid||(t.uid=0),t.gid||(t.gid=0),t.mtime||(t.mtime=new Date),typeof e=="string"&&(e=Buffer.from(e)),Buffer.isBuffer(e)){t.size=e.length,this._encode(t);var n=this.push(e);return uM(i,t.size),n?process.nextTick(r):this._drain=r,new gm}if(t.type==="symlink"&&!t.linkname){var s=new BQ;return ege(s,function(a){if(a)return i.destroy(),r(a);t.linkname=s.linkname,i._encode(t),r()}),s}if(this._encode(t),t.type!=="file"&&t.type!=="contiguous-file")return process.nextTick(r),new gm;var o=new wQ(this);return this._stream=o,ege(o,function(a){if(i._stream=null,a)return i.destroy(),r(a);if(o.written!==t.size)return i.destroy(),r(new Error("size mismatch"));uM(i,t.size),i._finalizing&&i.finalize(),r()}),o}};Oo.prototype.finalize=function(){if(this._stream){this._finalizing=!0;return}this._finalized||(this._finalized=!0,this.push(rge),this.push(null))};Oo.prototype.destroy=function(t){this._destroyed||(this._destroyed=!0,t&&this.emit("error",t),this.emit("close"),this._stream&&this._stream.destroy&&this._stream.destroy())};Oo.prototype._encode=function(t){if(!t.pax){var e=yQ.encode(t);if(e){this.push(e);return}}this._encodePax(t)};Oo.prototype._encodePax=function(t){var e=yQ.encodePax({name:t.name,linkname:t.linkname,pax:t.pax}),r={name:"PaxHeader",mode:t.mode,uid:t.uid,gid:t.gid,size:e.length,mtime:t.mtime,type:"pax-header",linkname:t.linkname&&"PaxHeader",uname:t.uname,gname:t.gname,devmajor:t.devmajor,devminor:t.devminor};this.push(yQ.encode(r)),this.push(e),uM(this,e.length),r.size=t.size,r.type=t.type,this.push(yQ.encode(r))};Oo.prototype._read=function(t){var e=this._drain;this._drain=cM,e()};$ue.exports=Oo});var nge=E(gM=>{gM.extract=_ue();gM.pack=ige()});var Cge=E((oDt,fge)=>{"use strict";var Pf=class{constructor(e,r,i){this.__specs=e||{},Object.keys(this.__specs).forEach(n=>{if(typeof this.__specs[n]=="string"){let s=this.__specs[n],o=this.__specs[s];if(o){let a=o.aliases||[];a.push(n,s),o.aliases=[...new Set(a)],this.__specs[n]=o}else throw new Error(`Alias refers to invalid key: ${s} -> ${n}`)}}),this.__opts=r||{},this.__providers=pge(i.filter(n=>n!=null&&typeof n=="object")),this.__isFiggyPudding=!0}get(e){return mM(this,e,!0)}get[Symbol.toStringTag](){return"FiggyPudding"}forEach(e,r=this){for(let[i,n]of this.entries())e.call(r,n,i,this)}toJSON(){let e={};return this.forEach((r,i)=>{e[i]=r}),e}*entries(e){for(let i of Object.keys(this.__specs))yield[i,this.get(i)];let r=e||this.__opts.other;if(r){let i=new Set;for(let n of this.__providers){let s=n.entries?n.entries(r):R7e(n);for(let[o,a]of s)r(o)&&!i.has(o)&&(i.add(o),yield[o,a])}}}*[Symbol.iterator](){for(let[e,r]of this.entries())yield[e,r]}*keys(){for(let[e]of this.entries())yield e}*values(){for(let[,e]of this.entries())yield e}concat(...e){return new Proxy(new Pf(this.__specs,this.__opts,pge(this.__providers).concat(e)),hge)}};try{let t=require("util");Pf.prototype[t.inspect.custom]=function(e,r){return this[Symbol.toStringTag]+" "+t.inspect(this.toJSON(),r)}}catch(t){}function F7e(t){throw Object.assign(new Error(`invalid config key requested: ${t}`),{code:"EBADKEY"})}function mM(t,e,r){let i=t.__specs[e];if(r&&!i&&(!t.__opts.other||!t.__opts.other(e)))F7e(e);else{i||(i={});let n;for(let s of t.__providers){if(n=dge(e,s),n===void 0&&i.aliases&&i.aliases.length){for(let o of i.aliases)if(o!==e&&(n=dge(o,s),n!==void 0))break}if(n!==void 0)break}return n===void 0&&i.default!==void 0?typeof i.default=="function"?i.default(t):i.default:n}}function dge(t,e){let r;return e.__isFiggyPudding?r=mM(e,t,!1):typeof e.get=="function"?r=e.get(t):r=e[t],r}var hge={has(t,e){return e in t.__specs&&mM(t,e,!1)!==void 0},ownKeys(t){return Object.keys(t.__specs)},get(t,e){return typeof e=="symbol"||e.slice(0,2)==="__"||e in Pf.prototype?t[e]:t.get(e)},set(t,e,r){if(typeof e=="symbol"||e.slice(0,2)==="__")return t[e]=r,!0;throw new Error("figgyPudding options cannot be modified. Use .concat() instead.")},deleteProperty(){throw new Error("figgyPudding options cannot be deleted. Use .concat() and shadow them instead.")}};fge.exports=N7e;function N7e(t,e){function r(...i){return new Proxy(new Pf(t,e,i),hge)}return r}function pge(t){let e=[];return t.forEach(r=>e.unshift(r)),e}function R7e(t){return Object.keys(t).map(e=>[e,t[e]])}});var Ige=E((aDt,Ko)=>{"use strict";var hm=require("crypto"),L7e=Cge(),T7e=require("stream").Transform,mge=["sha256","sha384","sha512"],M7e=/^[a-z0-9+/]+(?:=?=?)$/i,O7e=/^([^-]+)-([^?]+)([?\S*]*)$/,K7e=/^([^-]+)-([A-Za-z0-9+/=]{44,88})(\?[\x21-\x7E]*)*$/,U7e=/^[\x21-\x7E]+$/,on=L7e({algorithms:{default:["sha512"]},error:{default:!1},integrity:{},options:{default:[]},pickAlgorithm:{default:()=>H7e},Promise:{default:()=>Promise},sep:{default:" "},single:{default:!1},size:{},strict:{default:!1}}),zc=class{get isHash(){return!0}constructor(e,r){r=on(r);let i=!!r.strict;this.source=e.trim();let n=this.source.match(i?K7e:O7e);if(!n||i&&!mge.some(o=>o===n[1]))return;this.algorithm=n[1],this.digest=n[2];let s=n[3];this.options=s?s.slice(1).split("?"):[]}hexDigest(){return this.digest&&Buffer.from(this.digest,"base64").toString("hex")}toJSON(){return this.toString()}toString(e){if(e=on(e),e.strict&&!(mge.some(i=>i===this.algorithm)&&this.digest.match(M7e)&&(this.options||[]).every(i=>i.match(U7e))))return"";let r=this.options&&this.options.length?`?${this.options.join("?")}`:"";return`${this.algorithm}-${this.digest}${r}`}},Df=class{get isIntegrity(){return!0}toJSON(){return this.toString()}toString(e){e=on(e);let r=e.sep||" ";return e.strict&&(r=r.replace(/\S+/g," ")),Object.keys(this).map(i=>this[i].map(n=>zc.prototype.toString.call(n,e)).filter(n=>n.length).join(r)).filter(i=>i.length).join(r)}concat(e,r){r=on(r);let i=typeof e=="string"?e:pm(e,r);return Uo(`${this.toString(r)} ${i}`,r)}hexDigest(){return Uo(this,{single:!0}).hexDigest()}match(e,r){r=on(r);let i=Uo(e,r),n=i.pickAlgorithm(r);return this[n]&&i[n]&&this[n].find(s=>i[n].find(o=>s.digest===o.digest))||!1}pickAlgorithm(e){e=on(e);let r=e.pickAlgorithm,i=Object.keys(this);if(!i.length)throw new Error(`No algorithms available for ${JSON.stringify(this.toString())}`);return i.reduce((n,s)=>r(n,s)||n)}};Ko.exports.parse=Uo;function Uo(t,e){if(e=on(e),typeof t=="string")return EM(t,e);if(t.algorithm&&t.digest){let r=new Df;return r[t.algorithm]=[t],EM(pm(r,e),e)}else return EM(pm(t,e),e)}function EM(t,e){return e.single?new zc(t,e):t.trim().split(/\s+/).reduce((r,i)=>{let n=new zc(i,e);if(n.algorithm&&n.digest){let s=n.algorithm;r[s]||(r[s]=[]),r[s].push(n)}return r},new Df)}Ko.exports.stringify=pm;function pm(t,e){return e=on(e),t.algorithm&&t.digest?zc.prototype.toString.call(t,e):typeof t=="string"?pm(Uo(t,e),e):Df.prototype.toString.call(t,e)}Ko.exports.fromHex=G7e;function G7e(t,e,r){r=on(r);let i=r.options&&r.options.length?`?${r.options.join("?")}`:"";return Uo(`${e}-${Buffer.from(t,"hex").toString("base64")}${i}`,r)}Ko.exports.fromData=j7e;function j7e(t,e){e=on(e);let r=e.algorithms,i=e.options&&e.options.length?`?${e.options.join("?")}`:"";return r.reduce((n,s)=>{let o=hm.createHash(s).update(t).digest("base64"),a=new zc(`${s}-${o}${i}`,e);if(a.algorithm&&a.digest){let l=a.algorithm;n[l]||(n[l]=[]),n[l].push(a)}return n},new Df)}Ko.exports.fromStream=Y7e;function Y7e(t,e){e=on(e);let r=e.Promise||Promise,i=IM(e);return new r((n,s)=>{t.pipe(i),t.on("error",s),i.on("error",s);let o;i.on("integrity",a=>{o=a}),i.on("end",()=>n(o)),i.on("data",()=>{})})}Ko.exports.checkData=q7e;function q7e(t,e,r){if(r=on(r),e=Uo(e,r),!Object.keys(e).length){if(r.error)throw Object.assign(new Error("No valid integrity hashes to check against"),{code:"EINTEGRITY"});return!1}let i=e.pickAlgorithm(r),n=hm.createHash(i).update(t).digest("base64"),s=Uo({algorithm:i,digest:n}),o=s.match(e,r);if(o||!r.error)return o;if(typeof r.size=="number"&&t.length!==r.size){let a=new Error(`data size mismatch when checking ${e}. + Wanted: ${r.size} + Found: ${t.length}`);throw a.code="EBADSIZE",a.found=t.length,a.expected=r.size,a.sri=e,a}else{let a=new Error(`Integrity checksum failed when using ${i}: Wanted ${e}, but got ${s}. (${t.length} bytes)`);throw a.code="EINTEGRITY",a.found=s,a.expected=e,a.algorithm=i,a.sri=e,a}}Ko.exports.checkStream=J7e;function J7e(t,e,r){r=on(r);let i=r.Promise||Promise,n=IM(r.concat({integrity:e}));return new i((s,o)=>{t.pipe(n),t.on("error",o),n.on("error",o);let a;n.on("verified",l=>{a=l}),n.on("end",()=>s(a)),n.on("data",()=>{})})}Ko.exports.integrityStream=IM;function IM(t){t=on(t);let e=t.integrity&&Uo(t.integrity,t),r=e&&Object.keys(e).length,i=r&&e.pickAlgorithm(t),n=r&&e[i],s=Array.from(new Set(t.algorithms.concat(i?[i]:[]))),o=s.map(hm.createHash),a=0,l=new T7e({transform(c,u,g){a+=c.length,o.forEach(f=>f.update(c,u)),g(null,c,u)}}).on("end",()=>{let c=t.options&&t.options.length?`?${t.options.join("?")}`:"",u=Uo(o.map((f,h)=>`${s[h]}-${f.digest("base64")}${c}`).join(" "),t),g=r&&u.match(e,t);if(typeof t.size=="number"&&a!==t.size){let f=new Error(`stream size mismatch when checking ${e}. + Wanted: ${t.size} + Found: ${a}`);f.code="EBADSIZE",f.found=a,f.expected=t.size,f.sri=e,l.emit("error",f)}else if(t.integrity&&!g){let f=new Error(`${e} integrity checksum failed when using ${i}: wanted ${n} but got ${u}. (${a} bytes)`);f.code="EINTEGRITY",f.found=u,f.expected=n,f.algorithm=i,f.sri=e,l.emit("error",f)}else l.emit("size",a),l.emit("integrity",u),g&&l.emit("verified",g)});return l}Ko.exports.create=W7e;function W7e(t){t=on(t);let e=t.algorithms,r=t.options.length?`?${t.options.join("?")}`:"",i=e.map(hm.createHash);return{update:function(n,s){return i.forEach(o=>o.update(n,s)),this},digest:function(n){return e.reduce((o,a)=>{let l=i.shift().digest("base64"),c=new zc(`${a}-${l}${r}`,t);if(c.algorithm&&c.digest){let u=c.algorithm;o[u]||(o[u]=[]),o[u].push(c)}return o},new Df)}}}var z7e=new Set(hm.getHashes()),Ege=["md5","whirlpool","sha1","sha224","sha256","sha384","sha512","sha3","sha3-256","sha3-384","sha3-512","sha3_256","sha3_384","sha3_512"].filter(t=>z7e.has(t));function H7e(t,e){return Ege.indexOf(t.toLowerCase())>=Ege.indexOf(e.toLowerCase())?t:e}});var Fd={};it(Fd,{BuildType:()=>Gn,Cache:()=>Qt,Configuration:()=>fe,DEFAULT_LOCK_FILENAME:()=>DR,DEFAULT_RC_FILENAME:()=>PR,FormatType:()=>ps,InstallMode:()=>li,LightReport:()=>Fa,LinkType:()=>gt,Manifest:()=>Ze,MessageName:()=>z,PackageExtensionStatus:()=>ki,PackageExtensionType:()=>oi,Project:()=>Ke,ProjectLookup:()=>KA,Report:()=>Xi,ReportError:()=>nt,SettingsType:()=>ge,StreamReport:()=>Fe,TAG_REGEXP:()=>Rg,TelemetryManager:()=>Rd,ThrowReport:()=>ei,VirtualFetcher:()=>dd,Workspace:()=>Dd,WorkspaceResolver:()=>Yr,YarnVersion:()=>Zr,execUtils:()=>hr,folderUtils:()=>Pb,formatUtils:()=>ue,hashUtils:()=>mn,httpUtils:()=>Zt,miscUtils:()=>de,scriptUtils:()=>Kt,semverUtils:()=>qt,structUtils:()=>S,tgzUtils:()=>Ai,treeUtils:()=>Hs});var hr={};it(hr,{EndStrategy:()=>Pn,execvp:()=>Nhe,pipevp:()=>to});var ch={};it(ch,{AliasFS:()=>Xo,CwdFS:()=>Ft,DEFAULT_COMPRESSION_LEVEL:()=>pl,FakeFS:()=>eA,Filename:()=>wt,JailFS:()=>Zo,LazyFS:()=>oh,LinkStrategy:()=>eh,NoFS:()=>bE,NodeFS:()=>Wt,PortablePath:()=>Se,PosixFS:()=>ah,ProxiedFS:()=>fi,VirtualFS:()=>Pr,ZipFS:()=>Jr,ZipOpenFS:()=>Jn,constants:()=>mr,extendFs:()=>SE,normalizeLineEndings:()=>ul,npath:()=>M,opendir:()=>wE,patchFs:()=>pb,ppath:()=>v,statUtils:()=>rb,toFilename:()=>kr,xfs:()=>T});var mr={};it(mr,{SAFE_TIME:()=>tb,S_IFDIR:()=>zo,S_IFLNK:()=>_o,S_IFMT:()=>kn,S_IFREG:()=>Vo});var kn=61440,zo=16384,Vo=32768,_o=40960,tb=456789e3;var rb={};it(rb,{BigIntStatsEntry:()=>Xf,DEFAULT_MODE:()=>_f,DirEntry:()=>uO,StatEntry:()=>Za,areStatsEqual:()=>nb,clearStats:()=>pE,convertToBigIntStats:()=>dE,makeDefaultStats:()=>Zf,makeEmptyStats:()=>Jfe});var ib=ie(require("util"));var _f=Vo|420,uO=class{constructor(){this.name="";this.mode=0}isBlockDevice(){return!1}isCharacterDevice(){return!1}isDirectory(){return(this.mode&kn)===zo}isFIFO(){return!1}isFile(){return(this.mode&kn)===Vo}isSocket(){return!1}isSymbolicLink(){return(this.mode&kn)===_o}},Za=class{constructor(){this.uid=0;this.gid=0;this.size=0;this.blksize=0;this.atimeMs=0;this.mtimeMs=0;this.ctimeMs=0;this.birthtimeMs=0;this.atime=new Date(0);this.mtime=new Date(0);this.ctime=new Date(0);this.birthtime=new Date(0);this.dev=0;this.ino=0;this.mode=_f;this.nlink=1;this.rdev=0;this.blocks=1}isBlockDevice(){return!1}isCharacterDevice(){return!1}isDirectory(){return(this.mode&kn)===zo}isFIFO(){return!1}isFile(){return(this.mode&kn)===Vo}isSocket(){return!1}isSymbolicLink(){return(this.mode&kn)===_o}},Xf=class{constructor(){this.uid=BigInt(0);this.gid=BigInt(0);this.size=BigInt(0);this.blksize=BigInt(0);this.atimeMs=BigInt(0);this.mtimeMs=BigInt(0);this.ctimeMs=BigInt(0);this.birthtimeMs=BigInt(0);this.atimeNs=BigInt(0);this.mtimeNs=BigInt(0);this.ctimeNs=BigInt(0);this.birthtimeNs=BigInt(0);this.atime=new Date(0);this.mtime=new Date(0);this.ctime=new Date(0);this.birthtime=new Date(0);this.dev=BigInt(0);this.ino=BigInt(0);this.mode=BigInt(_f);this.nlink=BigInt(1);this.rdev=BigInt(0);this.blocks=BigInt(1)}isBlockDevice(){return!1}isCharacterDevice(){return!1}isDirectory(){return(this.mode&BigInt(kn))===BigInt(zo)}isFIFO(){return!1}isFile(){return(this.mode&BigInt(kn))===BigInt(Vo)}isSocket(){return!1}isSymbolicLink(){return(this.mode&BigInt(kn))===BigInt(_o)}};function Zf(){return new Za}function Jfe(){return pE(Zf())}function pE(t){for(let e in t)if(Object.prototype.hasOwnProperty.call(t,e)){let r=t[e];typeof r=="number"?t[e]=0:typeof r=="bigint"?t[e]=BigInt(0):ib.types.isDate(r)&&(t[e]=new Date(0))}return t}function dE(t){let e=new Xf;for(let r in t)if(Object.prototype.hasOwnProperty.call(t,r)){let i=t[r];typeof i=="number"?e[r]=BigInt(i):ib.types.isDate(i)&&(e[r]=new Date(i))}return e.atimeNs=e.atimeMs*BigInt(1e6),e.mtimeNs=e.mtimeMs*BigInt(1e6),e.ctimeNs=e.ctimeMs*BigInt(1e6),e.birthtimeNs=e.birthtimeMs*BigInt(1e6),e}function nb(t,e){if(t.atimeMs!==e.atimeMs||t.birthtimeMs!==e.birthtimeMs||t.blksize!==e.blksize||t.blocks!==e.blocks||t.ctimeMs!==e.ctimeMs||t.dev!==e.dev||t.gid!==e.gid||t.ino!==e.ino||t.isBlockDevice()!==e.isBlockDevice()||t.isCharacterDevice()!==e.isCharacterDevice()||t.isDirectory()!==e.isDirectory()||t.isFIFO()!==e.isFIFO()||t.isFile()!==e.isFile()||t.isSocket()!==e.isSocket()||t.isSymbolicLink()!==e.isSymbolicLink()||t.mode!==e.mode||t.mtimeMs!==e.mtimeMs||t.nlink!==e.nlink||t.rdev!==e.rdev||t.size!==e.size||t.uid!==e.uid)return!1;let r=t,i=e;return!(r.atimeNs!==i.atimeNs||r.mtimeNs!==i.mtimeNs||r.ctimeNs!==i.ctimeNs||r.birthtimeNs!==i.birthtimeNs)}var mE=ie(require("fs"));var $f=ie(require("path")),gO;(function(i){i[i.File=0]="File",i[i.Portable=1]="Portable",i[i.Native=2]="Native"})(gO||(gO={}));var Se={root:"/",dot:"."},wt={nodeModules:"node_modules",manifest:"package.json",lockfile:"yarn.lock",virtual:"__virtual__",pnpJs:".pnp.js",pnpCjs:".pnp.cjs",rc:".yarnrc.yml"},M=Object.create($f.default),v=Object.create($f.default.posix);M.cwd=()=>process.cwd();v.cwd=()=>sb(process.cwd());v.resolve=(...t)=>t.length>0&&v.isAbsolute(t[0])?$f.default.posix.resolve(...t):$f.default.posix.resolve(v.cwd(),...t);var fO=function(t,e,r){return e=t.normalize(e),r=t.normalize(r),e===r?".":(e.endsWith(t.sep)||(e=e+t.sep),r.startsWith(e)?r.slice(e.length):null)};M.fromPortablePath=hO;M.toPortablePath=sb;M.contains=(t,e)=>fO(M,t,e);v.contains=(t,e)=>fO(v,t,e);var Wfe=/^([a-zA-Z]:.*)$/,zfe=/^\\\\(\.\\)?(.*)$/,Vfe=/^\/([a-zA-Z]:.*)$/,_fe=/^\/unc\/(\.dot\/)?(.*)$/;function hO(t){if(process.platform!=="win32")return t;let e,r;if(e=t.match(Vfe))t=e[1];else if(r=t.match(_fe))t=`\\\\${r[1]?".\\":""}${r[2]}`;else return t;return t.replace(/\//g,"\\")}function sb(t){if(process.platform!=="win32")return t;let e,r;return(e=t.match(Wfe))?t=`/${e[1]}`:(r=t.match(zfe))&&(t=`/unc/${r[1]?".dot/":""}${r[2]}`),t.replace(/\\/g,"/")}function CE(t,e){return t===M?hO(e):sb(e)}function kr(t){if(M.parse(t).dir!==""||v.parse(t).dir!=="")throw new Error(`Invalid filename: "${t}"`);return t}var EE=new Date(tb*1e3),eh;(function(r){r.Allow="allow",r.ReadOnly="readOnly"})(eh||(eh={}));async function pO(t,e,r,i,n){let s=t.pathUtils.normalize(e),o=r.pathUtils.normalize(i),a=[],l=[],c=n.stableTime?{mtime:EE,atime:EE}:await r.lstatPromise(o);await t.mkdirpPromise(t.pathUtils.dirname(e),{utimes:[c.atime,c.mtime]});let u=typeof t.lutimesPromise=="function"?t.lutimesPromise.bind(t):t.utimesPromise.bind(t);await ob(a,l,u,t,s,r,o,n);for(let g of a)await g();await Promise.all(l.map(g=>g()))}async function ob(t,e,r,i,n,s,o,a){var f,h;let l=await Xfe(i,n),c=await s.lstatPromise(o),u=a.stableTime?{mtime:EE,atime:EE}:c,g;switch(!0){case c.isDirectory():g=await Zfe(t,e,r,i,n,l,s,o,c,a);break;case c.isFile():g=await $fe(t,e,r,i,n,l,s,o,c,a);break;case c.isSymbolicLink():g=await ehe(t,e,r,i,n,l,s,o,c,a);break;default:throw new Error(`Unsupported file type (${c.mode})`)}return(g||((f=l==null?void 0:l.mtime)==null?void 0:f.getTime())!==u.mtime.getTime()||((h=l==null?void 0:l.atime)==null?void 0:h.getTime())!==u.atime.getTime())&&(e.push(()=>r(n,u.atime,u.mtime)),g=!0),(l===null||(l.mode&511)!=(c.mode&511))&&(e.push(()=>i.chmodPromise(n,c.mode&511)),g=!0),g}async function Xfe(t,e){try{return await t.lstatPromise(e)}catch(r){return null}}async function Zfe(t,e,r,i,n,s,o,a,l,c){if(s!==null&&!s.isDirectory())if(c.overwrite)t.push(async()=>i.removePromise(n)),s=null;else return!1;let u=!1;s===null&&(t.push(async()=>{try{await i.mkdirPromise(n,{mode:l.mode})}catch(f){if(f.code!=="EEXIST")throw f}}),u=!0);let g=await o.readdirPromise(a);if(c.stableSort)for(let f of g.sort())await ob(t,e,r,i,i.pathUtils.join(n,f),o,o.pathUtils.join(a,f),c)&&(u=!0);else(await Promise.all(g.map(async h=>{await ob(t,e,r,i,i.pathUtils.join(n,h),o,o.pathUtils.join(a,h),c)}))).some(h=>h)&&(u=!0);return u}var ab=new WeakMap;function Ab(t,e,r,i,n){return async()=>{await t.linkPromise(r,e),n===eh.ReadOnly&&(i.mode&=~146,await t.chmodPromise(e,i.mode))}}function the(t,e,r,i,n){let s=ab.get(t);return typeof s=="undefined"?async()=>{try{await t.copyFilePromise(r,e,mE.default.constants.COPYFILE_FICLONE_FORCE),ab.set(t,!0)}catch(o){if(o.code==="ENOSYS"||o.code==="ENOTSUP")ab.set(t,!1),await Ab(t,e,r,i,n)();else throw o}}:s?async()=>t.copyFilePromise(r,e,mE.default.constants.COPYFILE_FICLONE_FORCE):Ab(t,e,r,i,n)}async function $fe(t,e,r,i,n,s,o,a,l,c){var f;if(s!==null)if(c.overwrite)t.push(async()=>i.removePromise(n)),s=null;else return!1;let u=(f=c.linkStrategy)!=null?f:null,g=i===o?u!==null?the(i,n,a,l,u):async()=>i.copyFilePromise(a,n,mE.default.constants.COPYFILE_FICLONE):u!==null?Ab(i,n,a,l,u):async()=>i.writeFilePromise(n,await o.readFilePromise(a));return t.push(async()=>g()),!0}async function ehe(t,e,r,i,n,s,o,a,l,c){if(s!==null)if(c.overwrite)t.push(async()=>i.removePromise(n)),s=null;else return!1;return t.push(async()=>{await i.symlinkPromise(CE(i.pathUtils,await o.readlinkPromise(a)),n)}),!0}function qn(t,e){return Object.assign(new Error(`${t}: ${e}`),{code:t})}function IE(t){return qn("EBUSY",t)}function th(t,e){return qn("ENOSYS",`${t}, ${e}`)}function $a(t){return qn("EINVAL",`invalid argument, ${t}`)}function Hi(t){return qn("EBADF",`bad file descriptor, ${t}`)}function bs(t){return qn("ENOENT",`no such file or directory, ${t}`)}function eo(t){return qn("ENOTDIR",`not a directory, ${t}`)}function rh(t){return qn("EISDIR",`illegal operation on a directory, ${t}`)}function yE(t){return qn("EEXIST",`file already exists, ${t}`)}function ln(t){return qn("EROFS",`read-only filesystem, ${t}`)}function dO(t){return qn("ENOTEMPTY",`directory not empty, ${t}`)}function CO(t){return qn("EOPNOTSUPP",`operation not supported, ${t}`)}function mO(){return qn("ERR_DIR_CLOSED","Directory handle was closed")}var lb=class extends Error{constructor(e,r){super(e);this.name="Libzip Error",this.code=r}};var EO=class{constructor(e,r,i={}){this.path=e;this.nextDirent=r;this.opts=i;this.closed=!1}throwIfClosed(){if(this.closed)throw mO()}async*[Symbol.asyncIterator](){try{let e;for(;(e=await this.read())!==null;)yield e}finally{await this.close()}}read(e){let r=this.readSync();return typeof e!="undefined"?e(null,r):Promise.resolve(r)}readSync(){return this.throwIfClosed(),this.nextDirent()}close(e){return this.closeSync(),typeof e!="undefined"?e(null):Promise.resolve()}closeSync(){var e,r;this.throwIfClosed(),(r=(e=this.opts).onClose)==null||r.call(e),this.closed=!0}};function wE(t,e,r,i){let n=()=>{let s=r.shift();return typeof s=="undefined"?null:Object.assign(t.statSync(t.pathUtils.join(e,s)),{name:s})};return new EO(e,n,i)}var IO=ie(require("os"));var eA=class{constructor(e){this.pathUtils=e}async*genTraversePromise(e,{stableSort:r=!1}={}){let i=[e];for(;i.length>0;){let n=i.shift();if((await this.lstatPromise(n)).isDirectory()){let o=await this.readdirPromise(n);if(r)for(let a of o.sort())i.push(this.pathUtils.join(n,a));else throw new Error("Not supported")}else yield n}}async removePromise(e,{recursive:r=!0,maxRetries:i=5}={}){let n;try{n=await this.lstatPromise(e)}catch(s){if(s.code==="ENOENT")return;throw s}if(n.isDirectory()){if(r){let o=await this.readdirPromise(e);await Promise.all(o.map(a=>this.removePromise(this.pathUtils.resolve(e,a))))}let s=0;do try{await this.rmdirPromise(e);break}catch(o){if(o.code==="EBUSY"||o.code==="ENOTEMPTY"){if(i===0)break;await new Promise(a=>setTimeout(a,s*100));continue}else throw o}while(s++{let l;try{[l]=await this.readJsonPromise(i)}catch(c){return Date.now()-s<500}try{return process.kill(l,0),!0}catch(c){return!1}};for(;o===null;)try{o=await this.openPromise(i,"wx")}catch(l){if(l.code==="EEXIST"){if(!await a())try{await this.unlinkPromise(i);continue}catch(c){}if(Date.now()-s<60*1e3)await new Promise(c=>setTimeout(c,n));else throw new Error(`Couldn't acquire a lock in a reasonable time (via ${i})`)}else throw l}await this.writePromise(o,JSON.stringify([process.pid]));try{return await r()}finally{try{await this.closePromise(o),await this.unlinkPromise(i)}catch(l){}}}async readJsonPromise(e){let r=await this.readFilePromise(e,"utf8");try{return JSON.parse(r)}catch(i){throw i.message+=` (in ${e})`,i}}readJsonSync(e){let r=this.readFileSync(e,"utf8");try{return JSON.parse(r)}catch(i){throw i.message+=` (in ${e})`,i}}async writeJsonPromise(e,r){return await this.writeFilePromise(e,`${JSON.stringify(r,null,2)} +`)}writeJsonSync(e,r){return this.writeFileSync(e,`${JSON.stringify(r,null,2)} +`)}async preserveTimePromise(e,r){let i=await this.lstatPromise(e),n=await r();typeof n!="undefined"&&(e=n),this.lutimesPromise?await this.lutimesPromise(e,i.atime,i.mtime):i.isSymbolicLink()||await this.utimesPromise(e,i.atime,i.mtime)}async preserveTimeSync(e,r){let i=this.lstatSync(e),n=r();typeof n!="undefined"&&(e=n),this.lutimesSync?this.lutimesSync(e,i.atime,i.mtime):i.isSymbolicLink()||this.utimesSync(e,i.atime,i.mtime)}},gl=class extends eA{constructor(){super(v)}};function rhe(t){let e=t.match(/\r?\n/g);if(e===null)return IO.EOL;let r=e.filter(n=>n===`\r +`).length,i=e.length-r;return r>i?`\r +`:` +`}function ul(t,e){return e.replace(/\r?\n/g,rhe(t))}var $c=ie(require("fs")),cb=ie(require("stream")),QO=ie(require("util")),ub=ie(require("zlib"));var yO=ie(require("fs"));var Wt=class extends gl{constructor(e=yO.default){super();this.realFs=e,typeof this.realFs.lutimes!="undefined"&&(this.lutimesPromise=this.lutimesPromiseImpl,this.lutimesSync=this.lutimesSyncImpl)}getExtractHint(){return!1}getRealPath(){return Se.root}resolve(e){return v.resolve(e)}async openPromise(e,r,i){return await new Promise((n,s)=>{this.realFs.open(M.fromPortablePath(e),r,i,this.makeCallback(n,s))})}openSync(e,r,i){return this.realFs.openSync(M.fromPortablePath(e),r,i)}async opendirPromise(e,r){return await new Promise((i,n)=>{typeof r!="undefined"?this.realFs.opendir(M.fromPortablePath(e),r,this.makeCallback(i,n)):this.realFs.opendir(M.fromPortablePath(e),this.makeCallback(i,n))}).then(i=>Object.defineProperty(i,"path",{value:e,configurable:!0,writable:!0}))}opendirSync(e,r){let i=typeof r!="undefined"?this.realFs.opendirSync(M.fromPortablePath(e),r):this.realFs.opendirSync(M.fromPortablePath(e));return Object.defineProperty(i,"path",{value:e,configurable:!0,writable:!0})}async readPromise(e,r,i=0,n=0,s=-1){return await new Promise((o,a)=>{this.realFs.read(e,r,i,n,s,(l,c)=>{l?a(l):o(c)})})}readSync(e,r,i,n,s){return this.realFs.readSync(e,r,i,n,s)}async writePromise(e,r,i,n,s){return await new Promise((o,a)=>typeof r=="string"?this.realFs.write(e,r,i,this.makeCallback(o,a)):this.realFs.write(e,r,i,n,s,this.makeCallback(o,a)))}writeSync(e,r,i,n,s){return typeof r=="string"?this.realFs.writeSync(e,r,i):this.realFs.writeSync(e,r,i,n,s)}async closePromise(e){await new Promise((r,i)=>{this.realFs.close(e,this.makeCallback(r,i))})}closeSync(e){this.realFs.closeSync(e)}createReadStream(e,r){let i=e!==null?M.fromPortablePath(e):e;return this.realFs.createReadStream(i,r)}createWriteStream(e,r){let i=e!==null?M.fromPortablePath(e):e;return this.realFs.createWriteStream(i,r)}async realpathPromise(e){return await new Promise((r,i)=>{this.realFs.realpath(M.fromPortablePath(e),{},this.makeCallback(r,i))}).then(r=>M.toPortablePath(r))}realpathSync(e){return M.toPortablePath(this.realFs.realpathSync(M.fromPortablePath(e),{}))}async existsPromise(e){return await new Promise(r=>{this.realFs.exists(M.fromPortablePath(e),r)})}accessSync(e,r){return this.realFs.accessSync(M.fromPortablePath(e),r)}async accessPromise(e,r){return await new Promise((i,n)=>{this.realFs.access(M.fromPortablePath(e),r,this.makeCallback(i,n))})}existsSync(e){return this.realFs.existsSync(M.fromPortablePath(e))}async statPromise(e,r){return await new Promise((i,n)=>{r?this.realFs.stat(M.fromPortablePath(e),r,this.makeCallback(i,n)):this.realFs.stat(M.fromPortablePath(e),this.makeCallback(i,n))})}statSync(e,r){return r?this.realFs.statSync(M.fromPortablePath(e),r):this.realFs.statSync(M.fromPortablePath(e))}async fstatPromise(e,r){return await new Promise((i,n)=>{r?this.realFs.fstat(e,r,this.makeCallback(i,n)):this.realFs.fstat(e,this.makeCallback(i,n))})}fstatSync(e,r){return r?this.realFs.fstatSync(e,r):this.realFs.fstatSync(e)}async lstatPromise(e,r){return await new Promise((i,n)=>{r?this.realFs.lstat(M.fromPortablePath(e),r,this.makeCallback(i,n)):this.realFs.lstat(M.fromPortablePath(e),this.makeCallback(i,n))})}lstatSync(e,r){return r?this.realFs.lstatSync(M.fromPortablePath(e),r):this.realFs.lstatSync(M.fromPortablePath(e))}async chmodPromise(e,r){return await new Promise((i,n)=>{this.realFs.chmod(M.fromPortablePath(e),r,this.makeCallback(i,n))})}chmodSync(e,r){return this.realFs.chmodSync(M.fromPortablePath(e),r)}async chownPromise(e,r,i){return await new Promise((n,s)=>{this.realFs.chown(M.fromPortablePath(e),r,i,this.makeCallback(n,s))})}chownSync(e,r,i){return this.realFs.chownSync(M.fromPortablePath(e),r,i)}async renamePromise(e,r){return await new Promise((i,n)=>{this.realFs.rename(M.fromPortablePath(e),M.fromPortablePath(r),this.makeCallback(i,n))})}renameSync(e,r){return this.realFs.renameSync(M.fromPortablePath(e),M.fromPortablePath(r))}async copyFilePromise(e,r,i=0){return await new Promise((n,s)=>{this.realFs.copyFile(M.fromPortablePath(e),M.fromPortablePath(r),i,this.makeCallback(n,s))})}copyFileSync(e,r,i=0){return this.realFs.copyFileSync(M.fromPortablePath(e),M.fromPortablePath(r),i)}async appendFilePromise(e,r,i){return await new Promise((n,s)=>{let o=typeof e=="string"?M.fromPortablePath(e):e;i?this.realFs.appendFile(o,r,i,this.makeCallback(n,s)):this.realFs.appendFile(o,r,this.makeCallback(n,s))})}appendFileSync(e,r,i){let n=typeof e=="string"?M.fromPortablePath(e):e;i?this.realFs.appendFileSync(n,r,i):this.realFs.appendFileSync(n,r)}async writeFilePromise(e,r,i){return await new Promise((n,s)=>{let o=typeof e=="string"?M.fromPortablePath(e):e;i?this.realFs.writeFile(o,r,i,this.makeCallback(n,s)):this.realFs.writeFile(o,r,this.makeCallback(n,s))})}writeFileSync(e,r,i){let n=typeof e=="string"?M.fromPortablePath(e):e;i?this.realFs.writeFileSync(n,r,i):this.realFs.writeFileSync(n,r)}async unlinkPromise(e){return await new Promise((r,i)=>{this.realFs.unlink(M.fromPortablePath(e),this.makeCallback(r,i))})}unlinkSync(e){return this.realFs.unlinkSync(M.fromPortablePath(e))}async utimesPromise(e,r,i){return await new Promise((n,s)=>{this.realFs.utimes(M.fromPortablePath(e),r,i,this.makeCallback(n,s))})}utimesSync(e,r,i){this.realFs.utimesSync(M.fromPortablePath(e),r,i)}async lutimesPromiseImpl(e,r,i){let n=this.realFs.lutimes;if(typeof n=="undefined")throw th("unavailable Node binding",`lutimes '${e}'`);return await new Promise((s,o)=>{n.call(this.realFs,M.fromPortablePath(e),r,i,this.makeCallback(s,o))})}lutimesSyncImpl(e,r,i){let n=this.realFs.lutimesSync;if(typeof n=="undefined")throw th("unavailable Node binding",`lutimes '${e}'`);n.call(this.realFs,M.fromPortablePath(e),r,i)}async mkdirPromise(e,r){return await new Promise((i,n)=>{this.realFs.mkdir(M.fromPortablePath(e),r,this.makeCallback(i,n))})}mkdirSync(e,r){return this.realFs.mkdirSync(M.fromPortablePath(e),r)}async rmdirPromise(e,r){return await new Promise((i,n)=>{r?this.realFs.rmdir(M.fromPortablePath(e),r,this.makeCallback(i,n)):this.realFs.rmdir(M.fromPortablePath(e),this.makeCallback(i,n))})}rmdirSync(e,r){return this.realFs.rmdirSync(M.fromPortablePath(e),r)}async linkPromise(e,r){return await new Promise((i,n)=>{this.realFs.link(M.fromPortablePath(e),M.fromPortablePath(r),this.makeCallback(i,n))})}linkSync(e,r){return this.realFs.linkSync(M.fromPortablePath(e),M.fromPortablePath(r))}async symlinkPromise(e,r,i){return await new Promise((n,s)=>{this.realFs.symlink(M.fromPortablePath(e.replace(/\/+$/,"")),M.fromPortablePath(r),i,this.makeCallback(n,s))})}symlinkSync(e,r,i){return this.realFs.symlinkSync(M.fromPortablePath(e.replace(/\/+$/,"")),M.fromPortablePath(r),i)}async readFilePromise(e,r){return await new Promise((i,n)=>{let s=typeof e=="string"?M.fromPortablePath(e):e;this.realFs.readFile(s,r,this.makeCallback(i,n))})}readFileSync(e,r){let i=typeof e=="string"?M.fromPortablePath(e):e;return this.realFs.readFileSync(i,r)}async readdirPromise(e,r){return await new Promise((i,n)=>{(r==null?void 0:r.withFileTypes)?this.realFs.readdir(M.fromPortablePath(e),{withFileTypes:!0},this.makeCallback(i,n)):this.realFs.readdir(M.fromPortablePath(e),this.makeCallback(s=>i(s),n))})}readdirSync(e,r){return(r==null?void 0:r.withFileTypes)?this.realFs.readdirSync(M.fromPortablePath(e),{withFileTypes:!0}):this.realFs.readdirSync(M.fromPortablePath(e))}async readlinkPromise(e){return await new Promise((r,i)=>{this.realFs.readlink(M.fromPortablePath(e),this.makeCallback(r,i))}).then(r=>M.toPortablePath(r))}readlinkSync(e){return M.toPortablePath(this.realFs.readlinkSync(M.fromPortablePath(e)))}async truncatePromise(e,r){return await new Promise((i,n)=>{this.realFs.truncate(M.fromPortablePath(e),r,this.makeCallback(i,n))})}truncateSync(e,r){return this.realFs.truncateSync(M.fromPortablePath(e),r)}watch(e,r,i){return this.realFs.watch(M.fromPortablePath(e),r,i)}watchFile(e,r,i){return this.realFs.watchFile(M.fromPortablePath(e),r,i)}unwatchFile(e,r){return this.realFs.unwatchFile(M.fromPortablePath(e),r)}makeCallback(e,r){return(i,n)=>{i?r(i):e(n)}}};var wO=ie(require("events"));var fl;(function(r){r.Change="change",r.Stop="stop"})(fl||(fl={}));var hl;(function(i){i.Ready="ready",i.Running="running",i.Stopped="stopped"})(hl||(hl={}));function BO(t,e){if(t!==e)throw new Error(`Invalid StatWatcher status: expected '${e}', got '${t}'`)}var ih=class extends wO.EventEmitter{constructor(e,r,{bigint:i=!1}={}){super();this.status=hl.Ready;this.changeListeners=new Map;this.startTimeout=null;this.fakeFs=e,this.path=r,this.bigint=i,this.lastStats=this.stat()}static create(e,r,i){let n=new ih(e,r,i);return n.start(),n}start(){BO(this.status,hl.Ready),this.status=hl.Running,this.startTimeout=setTimeout(()=>{this.startTimeout=null,this.fakeFs.existsSync(this.path)||this.emit(fl.Change,this.lastStats,this.lastStats)},3)}stop(){BO(this.status,hl.Running),this.status=hl.Stopped,this.startTimeout!==null&&(clearTimeout(this.startTimeout),this.startTimeout=null),this.emit(fl.Stop)}stat(){try{return this.fakeFs.statSync(this.path,{bigint:this.bigint})}catch(e){let r=this.bigint?new Xf:new Za;return pE(r)}}makeInterval(e){let r=setInterval(()=>{let i=this.stat(),n=this.lastStats;nb(i,n)||(this.lastStats=i,this.emit(fl.Change,i,n))},e.interval);return e.persistent?r:r.unref()}registerChangeListener(e,r){this.addListener(fl.Change,e),this.changeListeners.set(e,this.makeInterval(r))}unregisterChangeListener(e){this.removeListener(fl.Change,e);let r=this.changeListeners.get(e);typeof r!="undefined"&&clearInterval(r),this.changeListeners.delete(e)}unregisterAllChangeListeners(){for(let e of this.changeListeners.keys())this.unregisterChangeListener(e)}hasChangeListeners(){return this.changeListeners.size>0}ref(){for(let e of this.changeListeners.values())e.ref();return this}unref(){for(let e of this.changeListeners.values())e.unref();return this}};var BE=new WeakMap;function QE(t,e,r,i){let n,s,o,a;switch(typeof r){case"function":n=!1,s=!0,o=5007,a=r;break;default:({bigint:n=!1,persistent:s=!0,interval:o=5007}=r),a=i;break}let l=BE.get(t);typeof l=="undefined"&&BE.set(t,l=new Map);let c=l.get(e);return typeof c=="undefined"&&(c=ih.create(t,e,{bigint:n}),l.set(e,c)),c.registerChangeListener(a,{persistent:s,interval:o}),c}function nh(t,e,r){let i=BE.get(t);if(typeof i=="undefined")return;let n=i.get(e);typeof n!="undefined"&&(typeof r=="undefined"?n.unregisterAllChangeListeners():n.unregisterChangeListener(r),n.hasChangeListeners()||(n.stop(),i.delete(e)))}function sh(t){let e=BE.get(t);if(typeof e!="undefined")for(let r of e.keys())nh(t,r)}var pl="mixed";function ihe(t){if(typeof t=="string"&&String(+t)===t)return+t;if(Number.isFinite(t))return t<0?Date.now()/1e3:t;if((0,QO.isDate)(t))return t.getTime()/1e3;throw new Error("Invalid time")}function bO(){return Buffer.from([80,75,5,6,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0])}var Jr=class extends gl{constructor(e,r){super();this.lzSource=null;this.listings=new Map;this.entries=new Map;this.fileSources=new Map;this.fds=new Map;this.nextFd=0;this.ready=!1;this.readOnly=!1;this.libzip=r.libzip;let i=r;if(this.level=typeof i.level!="undefined"?i.level:pl,e!=null||(e=bO()),typeof e=="string"){let{baseFs:o=new Wt}=i;this.baseFs=o,this.path=e}else this.path=null,this.baseFs=null;if(r.stats)this.stats=r.stats;else if(typeof e=="string")try{this.stats=this.baseFs.statSync(e)}catch(o){if(o.code==="ENOENT"&&i.create)this.stats=Zf();else throw o}else this.stats=Zf();let n=this.libzip.malloc(4);try{let o=0;if(typeof e=="string"&&i.create&&(o|=this.libzip.ZIP_CREATE|this.libzip.ZIP_TRUNCATE),r.readOnly&&(o|=this.libzip.ZIP_RDONLY,this.readOnly=!0),typeof e=="string")this.zip=this.libzip.open(M.fromPortablePath(e),o,n);else{let a=this.allocateUnattachedSource(e);try{this.zip=this.libzip.openFromSource(a,o,n),this.lzSource=a}catch(l){throw this.libzip.source.free(a),l}}if(this.zip===0){let a=this.libzip.struct.errorS();throw this.libzip.error.initWithCode(a,this.libzip.getValue(n,"i32")),this.makeLibzipError(a)}}finally{this.libzip.free(n)}this.listings.set(Se.root,new Set);let s=this.libzip.getNumEntries(this.zip,0);for(let o=0;oe)throw new Error("Overread");let n=this.libzip.HEAPU8.subarray(r,r+e);return Buffer.from(n)}finally{this.libzip.free(r)}}finally{this.libzip.source.close(this.lzSource),this.libzip.source.free(this.lzSource),this.ready=!1}}prepareClose(){if(!this.ready)throw IE("archive closed, close");sh(this)}saveAndClose(){if(!this.path||!this.baseFs)throw new Error("ZipFS cannot be saved and must be discarded when loaded from a buffer");if(this.prepareClose(),this.readOnly){this.discardAndClose();return}let e=this.baseFs.existsSync(this.path)||this.stats.mode===_f?void 0:this.stats.mode;if(this.entries.size===0)this.discardAndClose(),this.baseFs.writeFileSync(this.path,bO(),{mode:e});else{if(this.libzip.close(this.zip)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));typeof e!="undefined"&&this.baseFs.chmodSync(this.path,e)}this.ready=!1}discardAndClose(){this.prepareClose(),this.libzip.discard(this.zip),this.ready=!1}resolve(e){return v.resolve(Se.root,e)}async openPromise(e,r,i){return this.openSync(e,r,i)}openSync(e,r,i){let n=this.nextFd++;return this.fds.set(n,{cursor:0,p:e}),n}hasOpenFileHandles(){return!!this.fds.size}async opendirPromise(e,r){return this.opendirSync(e,r)}opendirSync(e,r={}){let i=this.resolveFilename(`opendir '${e}'`,e);if(!this.entries.has(i)&&!this.listings.has(i))throw bs(`opendir '${e}'`);let n=this.listings.get(i);if(!n)throw eo(`opendir '${e}'`);let s=[...n],o=this.openSync(i,"r");return wE(this,i,s,{onClose:()=>{this.closeSync(o)}})}async readPromise(e,r,i,n,s){return this.readSync(e,r,i,n,s)}readSync(e,r,i=0,n=r.byteLength,s=-1){let o=this.fds.get(e);if(typeof o=="undefined")throw Hi("read");let a;s===-1||s===null?a=o.cursor:a=s;let l=this.readFileSync(o.p);l.copy(r,i,a,a+n);let c=Math.max(0,Math.min(l.length-a,n));return(s===-1||s===null)&&(o.cursor+=c),c}async writePromise(e,r,i,n,s){return typeof r=="string"?this.writeSync(e,r,s):this.writeSync(e,r,i,n,s)}writeSync(e,r,i,n,s){throw typeof this.fds.get(e)=="undefined"?Hi("read"):new Error("Unimplemented")}async closePromise(e){return this.closeSync(e)}closeSync(e){if(typeof this.fds.get(e)=="undefined")throw Hi("read");this.fds.delete(e)}createReadStream(e,{encoding:r}={}){if(e===null)throw new Error("Unimplemented");let i=this.openSync(e,"r"),n=Object.assign(new cb.PassThrough({emitClose:!0,autoDestroy:!0,destroy:(o,a)=>{clearImmediate(s),this.closeSync(i),a(o)}}),{close(){n.destroy()},bytesRead:0,path:e}),s=setImmediate(async()=>{try{let o=await this.readFilePromise(e,r);n.bytesRead=o.length,n.end(o)}catch(o){n.destroy(o)}});return n}createWriteStream(e,{encoding:r}={}){if(this.readOnly)throw ln(`open '${e}'`);if(e===null)throw new Error("Unimplemented");let i=[],n=this.openSync(e,"w"),s=Object.assign(new cb.PassThrough({autoDestroy:!0,emitClose:!0,destroy:(o,a)=>{try{o?a(o):(this.writeFileSync(e,Buffer.concat(i),r),a(null))}catch(l){a(l)}finally{this.closeSync(n)}}}),{bytesWritten:0,path:e,close(){s.destroy()}});return s.on("data",o=>{let a=Buffer.from(o);s.bytesWritten+=a.length,i.push(a)}),s}async realpathPromise(e){return this.realpathSync(e)}realpathSync(e){let r=this.resolveFilename(`lstat '${e}'`,e);if(!this.entries.has(r)&&!this.listings.has(r))throw bs(`lstat '${e}'`);return r}async existsPromise(e){return this.existsSync(e)}existsSync(e){if(!this.ready)throw IE(`archive closed, existsSync '${e}'`);if(this.symlinkCount===0){let i=v.resolve(Se.root,e);return this.entries.has(i)||this.listings.has(i)}let r;try{r=this.resolveFilename(`stat '${e}'`,e)}catch(i){return!1}return this.entries.has(r)||this.listings.has(r)}async accessPromise(e,r){return this.accessSync(e,r)}accessSync(e,r=$c.constants.F_OK){let i=this.resolveFilename(`access '${e}'`,e);if(!this.entries.has(i)&&!this.listings.has(i))throw bs(`access '${e}'`);if(this.readOnly&&r&$c.constants.W_OK)throw ln(`access '${e}'`)}async statPromise(e,r){return this.statSync(e,r)}statSync(e,r){let i=this.resolveFilename(`stat '${e}'`,e);if(!this.entries.has(i)&&!this.listings.has(i))throw bs(`stat '${e}'`);if(e[e.length-1]==="/"&&!this.listings.has(i))throw eo(`stat '${e}'`);return this.statImpl(`stat '${e}'`,i,r)}async fstatPromise(e,r){return this.fstatSync(e,r)}fstatSync(e,r){let i=this.fds.get(e);if(typeof i=="undefined")throw Hi("fstatSync");let{p:n}=i,s=this.resolveFilename(`stat '${n}'`,n);if(!this.entries.has(s)&&!this.listings.has(s))throw bs(`stat '${n}'`);if(n[n.length-1]==="/"&&!this.listings.has(s))throw eo(`stat '${n}'`);return this.statImpl(`fstat '${n}'`,s,r)}async lstatPromise(e,r){return this.lstatSync(e,r)}lstatSync(e,r){let i=this.resolveFilename(`lstat '${e}'`,e,!1);if(!this.entries.has(i)&&!this.listings.has(i))throw bs(`lstat '${e}'`);if(e[e.length-1]==="/"&&!this.listings.has(i))throw eo(`lstat '${e}'`);return this.statImpl(`lstat '${e}'`,i,r)}statImpl(e,r,i={}){let n=this.entries.get(r);if(typeof n!="undefined"){let s=this.libzip.struct.statS();if(this.libzip.statIndex(this.zip,n,0,0,s)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));let a=this.stats.uid,l=this.stats.gid,c=this.libzip.struct.statSize(s)>>>0,u=512,g=Math.ceil(c/u),f=(this.libzip.struct.statMtime(s)>>>0)*1e3,h=f,p=f,d=f,m=new Date(h),I=new Date(p),B=new Date(d),b=new Date(f),R=this.listings.has(r)?zo:this.isSymbolicLink(n)?_o:Vo,H=R===zo?493:420,L=R|this.getUnixMode(n,H)&511,K=this.libzip.struct.statCrc(s),J=Object.assign(new Za,{uid:a,gid:l,size:c,blksize:u,blocks:g,atime:m,birthtime:I,ctime:B,mtime:b,atimeMs:h,birthtimeMs:p,ctimeMs:d,mtimeMs:f,mode:L,crc:K});return i.bigint===!0?dE(J):J}if(this.listings.has(r)){let s=this.stats.uid,o=this.stats.gid,a=0,l=512,c=0,u=this.stats.mtimeMs,g=this.stats.mtimeMs,f=this.stats.mtimeMs,h=this.stats.mtimeMs,p=new Date(u),d=new Date(g),m=new Date(f),I=new Date(h),B=zo|493,b=0,R=Object.assign(new Za,{uid:s,gid:o,size:a,blksize:l,blocks:c,atime:p,birthtime:d,ctime:m,mtime:I,atimeMs:u,birthtimeMs:g,ctimeMs:f,mtimeMs:h,mode:B,crc:b});return i.bigint===!0?dE(R):R}throw new Error("Unreachable")}getUnixMode(e,r){if(this.libzip.file.getExternalAttributes(this.zip,e,0,0,this.libzip.uint08S,this.libzip.uint32S)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));return this.libzip.getValue(this.libzip.uint08S,"i8")>>>0!==this.libzip.ZIP_OPSYS_UNIX?r:this.libzip.getValue(this.libzip.uint32S,"i32")>>>16}registerListing(e){let r=this.listings.get(e);if(r)return r;let i=this.registerListing(v.dirname(e));return r=new Set,i.add(v.basename(e)),this.listings.set(e,r),r}registerEntry(e,r){this.registerListing(v.dirname(e)).add(v.basename(e)),this.entries.set(e,r)}unregisterListing(e){this.listings.delete(e);let r=this.listings.get(v.dirname(e));r==null||r.delete(v.basename(e))}unregisterEntry(e){this.unregisterListing(e);let r=this.entries.get(e);this.entries.delete(e),typeof r!="undefined"&&(this.fileSources.delete(r),this.isSymbolicLink(r)&&this.symlinkCount--)}deleteEntry(e,r){if(this.unregisterEntry(e),this.libzip.delete(this.zip,r)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip))}resolveFilename(e,r,i=!0){if(!this.ready)throw IE(`archive closed, ${e}`);let n=v.resolve(Se.root,r);if(n==="/")return Se.root;let s=this.entries.get(n);if(i&&s!==void 0)if(this.symlinkCount!==0&&this.isSymbolicLink(s)){let o=this.getFileSource(s).toString();return this.resolveFilename(e,v.resolve(v.dirname(n),o),!0)}else return n;for(;;){let o=this.resolveFilename(e,v.dirname(n),!0),a=this.listings.has(o),l=this.entries.has(o);if(!a&&!l)throw bs(e);if(!a)throw eo(e);if(n=v.resolve(o,v.basename(n)),!i||this.symlinkCount===0)break;let c=this.libzip.name.locate(this.zip,n.slice(1));if(c===-1)break;if(this.isSymbolicLink(c)){let u=this.getFileSource(c).toString();n=v.resolve(v.dirname(n),u)}else break}return n}allocateBuffer(e){Buffer.isBuffer(e)||(e=Buffer.from(e));let r=this.libzip.malloc(e.byteLength);if(!r)throw new Error("Couldn't allocate enough memory");return new Uint8Array(this.libzip.HEAPU8.buffer,r,e.byteLength).set(e),{buffer:r,byteLength:e.byteLength}}allocateUnattachedSource(e){let r=this.libzip.struct.errorS(),{buffer:i,byteLength:n}=this.allocateBuffer(e),s=this.libzip.source.fromUnattachedBuffer(i,n,0,!0,r);if(s===0)throw this.libzip.free(r),this.makeLibzipError(r);return s}allocateSource(e){let{buffer:r,byteLength:i}=this.allocateBuffer(e),n=this.libzip.source.fromBuffer(this.zip,r,i,0,!0);if(n===0)throw this.libzip.free(r),this.makeLibzipError(this.libzip.getError(this.zip));return n}setFileSource(e,r){let i=Buffer.isBuffer(r)?r:Buffer.from(r),n=v.relative(Se.root,e),s=this.allocateSource(r);try{let o=this.libzip.file.add(this.zip,n,s,this.libzip.ZIP_FL_OVERWRITE);if(o===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));if(this.level!=="mixed"){let a;if(this.level===0?a=this.libzip.ZIP_CM_STORE:a=this.libzip.ZIP_CM_DEFLATE,this.libzip.file.setCompression(this.zip,o,0,a,this.level)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip))}return this.fileSources.set(o,i),o}catch(o){throw this.libzip.source.free(s),o}}isSymbolicLink(e){if(this.symlinkCount===0)return!1;if(this.libzip.file.getExternalAttributes(this.zip,e,0,0,this.libzip.uint08S,this.libzip.uint32S)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));return this.libzip.getValue(this.libzip.uint08S,"i8")>>>0!==this.libzip.ZIP_OPSYS_UNIX?!1:(this.libzip.getValue(this.libzip.uint32S,"i32")>>>16&kn)===_o}getFileSource(e,r={asyncDecompress:!1}){let i=this.fileSources.get(e);if(typeof i!="undefined")return i;let n=this.libzip.struct.statS();if(this.libzip.statIndex(this.zip,e,0,0,n)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));let o=this.libzip.struct.statCompSize(n),a=this.libzip.struct.statCompMethod(n),l=this.libzip.malloc(o);try{let c=this.libzip.fopenIndex(this.zip,e,0,this.libzip.ZIP_FL_COMPRESSED);if(c===0)throw this.makeLibzipError(this.libzip.getError(this.zip));try{let u=this.libzip.fread(c,l,o,0);if(u===-1)throw this.makeLibzipError(this.libzip.file.getError(c));if(uo)throw new Error("Overread");let g=this.libzip.HEAPU8.subarray(l,l+o),f=Buffer.from(g);if(a===0)return this.fileSources.set(e,f),f;if(r.asyncDecompress)return new Promise((h,p)=>{ub.default.inflateRaw(f,(d,m)=>{d?p(d):(this.fileSources.set(e,m),h(m))})});{let h=ub.default.inflateRawSync(f);return this.fileSources.set(e,h),h}}finally{this.libzip.fclose(c)}}finally{this.libzip.free(l)}}async chmodPromise(e,r){return this.chmodSync(e,r)}chmodSync(e,r){if(this.readOnly)throw ln(`chmod '${e}'`);r&=493;let i=this.resolveFilename(`chmod '${e}'`,e,!1),n=this.entries.get(i);if(typeof n=="undefined")throw new Error(`Assertion failed: The entry should have been registered (${i})`);let o=this.getUnixMode(n,Vo|0)&~511|r;if(this.libzip.file.setExternalAttributes(this.zip,n,0,0,this.libzip.ZIP_OPSYS_UNIX,o<<16)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip))}async chownPromise(e,r,i){return this.chownSync(e,r,i)}chownSync(e,r,i){throw new Error("Unimplemented")}async renamePromise(e,r){return this.renameSync(e,r)}renameSync(e,r){throw new Error("Unimplemented")}async copyFilePromise(e,r,i){let{indexSource:n,indexDest:s,resolvedDestP:o}=this.prepareCopyFile(e,r,i),a=await this.getFileSource(n,{asyncDecompress:!0}),l=this.setFileSource(o,a);l!==s&&this.registerEntry(o,l)}copyFileSync(e,r,i=0){let{indexSource:n,indexDest:s,resolvedDestP:o}=this.prepareCopyFile(e,r,i),a=this.getFileSource(n),l=this.setFileSource(o,a);l!==s&&this.registerEntry(o,l)}prepareCopyFile(e,r,i=0){if(this.readOnly)throw ln(`copyfile '${e} -> '${r}'`);if((i&$c.constants.COPYFILE_FICLONE_FORCE)!=0)throw th("unsupported clone operation",`copyfile '${e}' -> ${r}'`);let n=this.resolveFilename(`copyfile '${e} -> ${r}'`,e),s=this.entries.get(n);if(typeof s=="undefined")throw $a(`copyfile '${e}' -> '${r}'`);let o=this.resolveFilename(`copyfile '${e}' -> ${r}'`,r),a=this.entries.get(o);if((i&($c.constants.COPYFILE_EXCL|$c.constants.COPYFILE_FICLONE_FORCE))!=0&&typeof a!="undefined")throw yE(`copyfile '${e}' -> '${r}'`);return{indexSource:s,resolvedDestP:o,indexDest:a}}async appendFilePromise(e,r,i){if(this.readOnly)throw ln(`open '${e}'`);return typeof i=="undefined"?i={flag:"a"}:typeof i=="string"?i={flag:"a",encoding:i}:typeof i.flag=="undefined"&&(i=P({flag:"a"},i)),this.writeFilePromise(e,r,i)}appendFileSync(e,r,i={}){if(this.readOnly)throw ln(`open '${e}'`);return typeof i=="undefined"?i={flag:"a"}:typeof i=="string"?i={flag:"a",encoding:i}:typeof i.flag=="undefined"&&(i=P({flag:"a"},i)),this.writeFileSync(e,r,i)}fdToPath(e,r){var n;let i=(n=this.fds.get(e))==null?void 0:n.p;if(typeof i=="undefined")throw Hi(r);return i}async writeFilePromise(e,r,i){let{encoding:n,mode:s,index:o,resolvedP:a}=this.prepareWriteFile(e,i);o!==void 0&&typeof i=="object"&&i.flag&&i.flag.includes("a")&&(r=Buffer.concat([await this.getFileSource(o,{asyncDecompress:!0}),Buffer.from(r)])),n!==null&&(r=r.toString(n));let l=this.setFileSource(a,r);l!==o&&this.registerEntry(a,l),s!==null&&await this.chmodPromise(a,s)}writeFileSync(e,r,i){let{encoding:n,mode:s,index:o,resolvedP:a}=this.prepareWriteFile(e,i);o!==void 0&&typeof i=="object"&&i.flag&&i.flag.includes("a")&&(r=Buffer.concat([this.getFileSource(o),Buffer.from(r)])),n!==null&&(r=r.toString(n));let l=this.setFileSource(a,r);l!==o&&this.registerEntry(a,l),s!==null&&this.chmodSync(a,s)}prepareWriteFile(e,r){if(typeof e=="number"&&(e=this.fdToPath(e,"read")),this.readOnly)throw ln(`open '${e}'`);let i=this.resolveFilename(`open '${e}'`,e);if(this.listings.has(i))throw rh(`open '${e}'`);let n=null,s=null;typeof r=="string"?n=r:typeof r=="object"&&({encoding:n=null,mode:s=null}=r);let o=this.entries.get(i);return{encoding:n,mode:s,resolvedP:i,index:o}}async unlinkPromise(e){return this.unlinkSync(e)}unlinkSync(e){if(this.readOnly)throw ln(`unlink '${e}'`);let r=this.resolveFilename(`unlink '${e}'`,e);if(this.listings.has(r))throw rh(`unlink '${e}'`);let i=this.entries.get(r);if(typeof i=="undefined")throw $a(`unlink '${e}'`);this.deleteEntry(r,i)}async utimesPromise(e,r,i){return this.utimesSync(e,r,i)}utimesSync(e,r,i){if(this.readOnly)throw ln(`utimes '${e}'`);let n=this.resolveFilename(`utimes '${e}'`,e);this.utimesImpl(n,i)}async lutimesPromise(e,r,i){return this.lutimesSync(e,r,i)}lutimesSync(e,r,i){if(this.readOnly)throw ln(`lutimes '${e}'`);let n=this.resolveFilename(`utimes '${e}'`,e,!1);this.utimesImpl(n,i)}utimesImpl(e,r){this.listings.has(e)&&(this.entries.has(e)||this.hydrateDirectory(e));let i=this.entries.get(e);if(i===void 0)throw new Error("Unreachable");if(this.libzip.file.setMtime(this.zip,i,0,ihe(r),0)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip))}async mkdirPromise(e,r){return this.mkdirSync(e,r)}mkdirSync(e,{mode:r=493,recursive:i=!1}={}){if(i){this.mkdirpSync(e,{chmod:r});return}if(this.readOnly)throw ln(`mkdir '${e}'`);let n=this.resolveFilename(`mkdir '${e}'`,e);if(this.entries.has(n)||this.listings.has(n))throw yE(`mkdir '${e}'`);this.hydrateDirectory(n),this.chmodSync(n,r)}async rmdirPromise(e,r){return this.rmdirSync(e,r)}rmdirSync(e,{recursive:r=!1}={}){if(this.readOnly)throw ln(`rmdir '${e}'`);if(r){this.removeSync(e);return}let i=this.resolveFilename(`rmdir '${e}'`,e),n=this.listings.get(i);if(!n)throw eo(`rmdir '${e}'`);if(n.size>0)throw dO(`rmdir '${e}'`);let s=this.entries.get(i);if(typeof s=="undefined")throw $a(`rmdir '${e}'`);this.deleteEntry(e,s)}hydrateDirectory(e){let r=this.libzip.dir.add(this.zip,v.relative(Se.root,e));if(r===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));return this.registerListing(e),this.registerEntry(e,r),r}async linkPromise(e,r){return this.linkSync(e,r)}linkSync(e,r){throw CO(`link '${e}' -> '${r}'`)}async symlinkPromise(e,r){return this.symlinkSync(e,r)}symlinkSync(e,r){if(this.readOnly)throw ln(`symlink '${e}' -> '${r}'`);let i=this.resolveFilename(`symlink '${e}' -> '${r}'`,r);if(this.listings.has(i))throw rh(`symlink '${e}' -> '${r}'`);if(this.entries.has(i))throw yE(`symlink '${e}' -> '${r}'`);let n=this.setFileSource(i,e);if(this.registerEntry(i,n),this.libzip.file.setExternalAttributes(this.zip,n,0,0,this.libzip.ZIP_OPSYS_UNIX,(_o|511)<<16)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));this.symlinkCount+=1}async readFilePromise(e,r){typeof r=="object"&&(r=r?r.encoding:void 0);let i=await this.readFileBuffer(e,{asyncDecompress:!0});return r?i.toString(r):i}readFileSync(e,r){typeof r=="object"&&(r=r?r.encoding:void 0);let i=this.readFileBuffer(e);return r?i.toString(r):i}readFileBuffer(e,r={asyncDecompress:!1}){typeof e=="number"&&(e=this.fdToPath(e,"read"));let i=this.resolveFilename(`open '${e}'`,e);if(!this.entries.has(i)&&!this.listings.has(i))throw bs(`open '${e}'`);if(e[e.length-1]==="/"&&!this.listings.has(i))throw eo(`open '${e}'`);if(this.listings.has(i))throw rh("read");let n=this.entries.get(i);if(n===void 0)throw new Error("Unreachable");return this.getFileSource(n,r)}async readdirPromise(e,r){return this.readdirSync(e,r)}readdirSync(e,r){let i=this.resolveFilename(`scandir '${e}'`,e);if(!this.entries.has(i)&&!this.listings.has(i))throw bs(`scandir '${e}'`);let n=this.listings.get(i);if(!n)throw eo(`scandir '${e}'`);let s=[...n];return(r==null?void 0:r.withFileTypes)?s.map(o=>Object.assign(this.statImpl("lstat",v.join(e,o)),{name:o})):s}async readlinkPromise(e){let r=this.prepareReadlink(e);return(await this.getFileSource(r,{asyncDecompress:!0})).toString()}readlinkSync(e){let r=this.prepareReadlink(e);return this.getFileSource(r).toString()}prepareReadlink(e){let r=this.resolveFilename(`readlink '${e}'`,e,!1);if(!this.entries.has(r)&&!this.listings.has(r))throw bs(`readlink '${e}'`);if(e[e.length-1]==="/"&&!this.listings.has(r))throw eo(`open '${e}'`);if(this.listings.has(r))throw $a(`readlink '${e}'`);let i=this.entries.get(r);if(i===void 0)throw new Error("Unreachable");if(!this.isSymbolicLink(i))throw $a(`readlink '${e}'`);return i}async truncatePromise(e,r=0){let i=this.resolveFilename(`open '${e}'`,e),n=this.entries.get(i);if(typeof n=="undefined")throw $a(`open '${e}'`);let s=await this.getFileSource(n,{asyncDecompress:!0}),o=Buffer.alloc(r,0);return s.copy(o),await this.writeFilePromise(e,o)}truncateSync(e,r=0){let i=this.resolveFilename(`open '${e}'`,e),n=this.entries.get(i);if(typeof n=="undefined")throw $a(`open '${e}'`);let s=this.getFileSource(n),o=Buffer.alloc(r,0);return s.copy(o),this.writeFileSync(e,o)}watch(e,r,i){let n;switch(typeof r){case"function":case"string":case"undefined":n=!0;break;default:({persistent:n=!0}=r);break}if(!n)return{on:()=>{},close:()=>{}};let s=setInterval(()=>{},24*60*60*1e3);return{on:()=>{},close:()=>{clearInterval(s)}}}watchFile(e,r,i){let n=v.resolve(Se.root,e);return QE(this,n,r,i)}unwatchFile(e,r){let i=v.resolve(Se.root,e);return nh(this,i,r)}};var fi=class extends eA{getExtractHint(e){return this.baseFs.getExtractHint(e)}resolve(e){return this.mapFromBase(this.baseFs.resolve(this.mapToBase(e)))}getRealPath(){return this.mapFromBase(this.baseFs.getRealPath())}async openPromise(e,r,i){return this.baseFs.openPromise(this.mapToBase(e),r,i)}openSync(e,r,i){return this.baseFs.openSync(this.mapToBase(e),r,i)}async opendirPromise(e,r){return Object.assign(await this.baseFs.opendirPromise(this.mapToBase(e),r),{path:e})}opendirSync(e,r){return Object.assign(this.baseFs.opendirSync(this.mapToBase(e),r),{path:e})}async readPromise(e,r,i,n,s){return await this.baseFs.readPromise(e,r,i,n,s)}readSync(e,r,i,n,s){return this.baseFs.readSync(e,r,i,n,s)}async writePromise(e,r,i,n,s){return typeof r=="string"?await this.baseFs.writePromise(e,r,i):await this.baseFs.writePromise(e,r,i,n,s)}writeSync(e,r,i,n,s){return typeof r=="string"?this.baseFs.writeSync(e,r,i):this.baseFs.writeSync(e,r,i,n,s)}async closePromise(e){return this.baseFs.closePromise(e)}closeSync(e){this.baseFs.closeSync(e)}createReadStream(e,r){return this.baseFs.createReadStream(e!==null?this.mapToBase(e):e,r)}createWriteStream(e,r){return this.baseFs.createWriteStream(e!==null?this.mapToBase(e):e,r)}async realpathPromise(e){return this.mapFromBase(await this.baseFs.realpathPromise(this.mapToBase(e)))}realpathSync(e){return this.mapFromBase(this.baseFs.realpathSync(this.mapToBase(e)))}async existsPromise(e){return this.baseFs.existsPromise(this.mapToBase(e))}existsSync(e){return this.baseFs.existsSync(this.mapToBase(e))}accessSync(e,r){return this.baseFs.accessSync(this.mapToBase(e),r)}async accessPromise(e,r){return this.baseFs.accessPromise(this.mapToBase(e),r)}async statPromise(e,r){return this.baseFs.statPromise(this.mapToBase(e),r)}statSync(e,r){return this.baseFs.statSync(this.mapToBase(e),r)}async fstatPromise(e,r){return this.baseFs.fstatPromise(e,r)}fstatSync(e,r){return this.baseFs.fstatSync(e,r)}async lstatPromise(e,r){return this.baseFs.lstatPromise(this.mapToBase(e),r)}lstatSync(e,r){return this.baseFs.lstatSync(this.mapToBase(e),r)}async chmodPromise(e,r){return this.baseFs.chmodPromise(this.mapToBase(e),r)}chmodSync(e,r){return this.baseFs.chmodSync(this.mapToBase(e),r)}async chownPromise(e,r,i){return this.baseFs.chownPromise(this.mapToBase(e),r,i)}chownSync(e,r,i){return this.baseFs.chownSync(this.mapToBase(e),r,i)}async renamePromise(e,r){return this.baseFs.renamePromise(this.mapToBase(e),this.mapToBase(r))}renameSync(e,r){return this.baseFs.renameSync(this.mapToBase(e),this.mapToBase(r))}async copyFilePromise(e,r,i=0){return this.baseFs.copyFilePromise(this.mapToBase(e),this.mapToBase(r),i)}copyFileSync(e,r,i=0){return this.baseFs.copyFileSync(this.mapToBase(e),this.mapToBase(r),i)}async appendFilePromise(e,r,i){return this.baseFs.appendFilePromise(this.fsMapToBase(e),r,i)}appendFileSync(e,r,i){return this.baseFs.appendFileSync(this.fsMapToBase(e),r,i)}async writeFilePromise(e,r,i){return this.baseFs.writeFilePromise(this.fsMapToBase(e),r,i)}writeFileSync(e,r,i){return this.baseFs.writeFileSync(this.fsMapToBase(e),r,i)}async unlinkPromise(e){return this.baseFs.unlinkPromise(this.mapToBase(e))}unlinkSync(e){return this.baseFs.unlinkSync(this.mapToBase(e))}async utimesPromise(e,r,i){return this.baseFs.utimesPromise(this.mapToBase(e),r,i)}utimesSync(e,r,i){return this.baseFs.utimesSync(this.mapToBase(e),r,i)}async mkdirPromise(e,r){return this.baseFs.mkdirPromise(this.mapToBase(e),r)}mkdirSync(e,r){return this.baseFs.mkdirSync(this.mapToBase(e),r)}async rmdirPromise(e,r){return this.baseFs.rmdirPromise(this.mapToBase(e),r)}rmdirSync(e,r){return this.baseFs.rmdirSync(this.mapToBase(e),r)}async linkPromise(e,r){return this.baseFs.linkPromise(this.mapToBase(e),this.mapToBase(r))}linkSync(e,r){return this.baseFs.linkSync(this.mapToBase(e),this.mapToBase(r))}async symlinkPromise(e,r,i){let n=this.mapToBase(r);if(this.pathUtils.isAbsolute(e))return this.baseFs.symlinkPromise(this.mapToBase(e),n,i);let s=this.mapToBase(this.pathUtils.join(this.pathUtils.dirname(r),e)),o=this.baseFs.pathUtils.relative(this.baseFs.pathUtils.dirname(n),s);return this.baseFs.symlinkPromise(o,n,i)}symlinkSync(e,r,i){let n=this.mapToBase(r);if(this.pathUtils.isAbsolute(e))return this.baseFs.symlinkSync(this.mapToBase(e),n,i);let s=this.mapToBase(this.pathUtils.join(this.pathUtils.dirname(r),e)),o=this.baseFs.pathUtils.relative(this.baseFs.pathUtils.dirname(n),s);return this.baseFs.symlinkSync(o,n,i)}async readFilePromise(e,r){return r==="utf8"?this.baseFs.readFilePromise(this.fsMapToBase(e),r):this.baseFs.readFilePromise(this.fsMapToBase(e),r)}readFileSync(e,r){return r==="utf8"?this.baseFs.readFileSync(this.fsMapToBase(e),r):this.baseFs.readFileSync(this.fsMapToBase(e),r)}async readdirPromise(e,r){return this.baseFs.readdirPromise(this.mapToBase(e),r)}readdirSync(e,r){return this.baseFs.readdirSync(this.mapToBase(e),r)}async readlinkPromise(e){return this.mapFromBase(await this.baseFs.readlinkPromise(this.mapToBase(e)))}readlinkSync(e){return this.mapFromBase(this.baseFs.readlinkSync(this.mapToBase(e)))}async truncatePromise(e,r){return this.baseFs.truncatePromise(this.mapToBase(e),r)}truncateSync(e,r){return this.baseFs.truncateSync(this.mapToBase(e),r)}watch(e,r,i){return this.baseFs.watch(this.mapToBase(e),r,i)}watchFile(e,r,i){return this.baseFs.watchFile(this.mapToBase(e),r,i)}unwatchFile(e,r){return this.baseFs.unwatchFile(this.mapToBase(e),r)}fsMapToBase(e){return typeof e=="number"?e:this.mapToBase(e)}};var Xo=class extends fi{constructor(e,{baseFs:r,pathUtils:i}){super(i);this.target=e,this.baseFs=r}getRealPath(){return this.target}getBaseFs(){return this.baseFs}mapFromBase(e){return e}mapToBase(e){return e}};var Ft=class extends fi{constructor(e,{baseFs:r=new Wt}={}){super(v);this.target=this.pathUtils.normalize(e),this.baseFs=r}getRealPath(){return this.pathUtils.resolve(this.baseFs.getRealPath(),this.target)}resolve(e){return this.pathUtils.isAbsolute(e)?v.normalize(e):this.baseFs.resolve(v.join(this.target,e))}mapFromBase(e){return e}mapToBase(e){return this.pathUtils.isAbsolute(e)?e:this.pathUtils.join(this.target,e)}};var vO=Se.root,Zo=class extends fi{constructor(e,{baseFs:r=new Wt}={}){super(v);this.target=this.pathUtils.resolve(Se.root,e),this.baseFs=r}getRealPath(){return this.pathUtils.resolve(this.baseFs.getRealPath(),this.pathUtils.relative(Se.root,this.target))}getTarget(){return this.target}getBaseFs(){return this.baseFs}mapToBase(e){let r=this.pathUtils.normalize(e);if(this.pathUtils.isAbsolute(e))return this.pathUtils.resolve(this.target,this.pathUtils.relative(vO,e));if(r.match(/^\.\.\/?/))throw new Error(`Resolving this path (${e}) would escape the jail`);return this.pathUtils.resolve(this.target,e)}mapFromBase(e){return this.pathUtils.resolve(vO,this.pathUtils.relative(this.target,e))}};var oh=class extends fi{constructor(e,r){super(r);this.instance=null;this.factory=e}get baseFs(){return this.instance||(this.instance=this.factory()),this.instance}set baseFs(e){this.instance=e}mapFromBase(e){return e}mapToBase(e){return e}};var ze=()=>Object.assign(new Error("ENOSYS: unsupported filesystem access"),{code:"ENOSYS"}),gb=class extends eA{constructor(){super(v)}getExtractHint(){throw ze()}getRealPath(){throw ze()}resolve(){throw ze()}async openPromise(){throw ze()}openSync(){throw ze()}async opendirPromise(){throw ze()}opendirSync(){throw ze()}async readPromise(){throw ze()}readSync(){throw ze()}async writePromise(){throw ze()}writeSync(){throw ze()}async closePromise(){throw ze()}closeSync(){throw ze()}createWriteStream(){throw ze()}createReadStream(){throw ze()}async realpathPromise(){throw ze()}realpathSync(){throw ze()}async readdirPromise(){throw ze()}readdirSync(){throw ze()}async existsPromise(e){throw ze()}existsSync(e){throw ze()}async accessPromise(){throw ze()}accessSync(){throw ze()}async statPromise(){throw ze()}statSync(){throw ze()}async fstatPromise(e){throw ze()}fstatSync(e){throw ze()}async lstatPromise(e){throw ze()}lstatSync(e){throw ze()}async chmodPromise(){throw ze()}chmodSync(){throw ze()}async chownPromise(){throw ze()}chownSync(){throw ze()}async mkdirPromise(){throw ze()}mkdirSync(){throw ze()}async rmdirPromise(){throw ze()}rmdirSync(){throw ze()}async linkPromise(){throw ze()}linkSync(){throw ze()}async symlinkPromise(){throw ze()}symlinkSync(){throw ze()}async renamePromise(){throw ze()}renameSync(){throw ze()}async copyFilePromise(){throw ze()}copyFileSync(){throw ze()}async appendFilePromise(){throw ze()}appendFileSync(){throw ze()}async writeFilePromise(){throw ze()}writeFileSync(){throw ze()}async unlinkPromise(){throw ze()}unlinkSync(){throw ze()}async utimesPromise(){throw ze()}utimesSync(){throw ze()}async readFilePromise(){throw ze()}readFileSync(){throw ze()}async readlinkPromise(){throw ze()}readlinkSync(){throw ze()}async truncatePromise(){throw ze()}truncateSync(){throw ze()}watch(){throw ze()}watchFile(){throw ze()}unwatchFile(){throw ze()}},bE=gb;bE.instance=new gb;var ah=class extends fi{constructor(e){super(M);this.baseFs=e}mapFromBase(e){return M.fromPortablePath(e)}mapToBase(e){return M.toPortablePath(e)}};var nhe=/^[0-9]+$/,fb=/^(\/(?:[^/]+\/)*?(?:\$\$virtual|__virtual__))((?:\/((?:[^/]+-)?[a-f0-9]+)(?:\/([^/]+))?)?((?:\/.*)?))$/,she=/^([^/]+-)?[a-f0-9]+$/,Pr=class extends fi{static makeVirtualPath(e,r,i){if(v.basename(e)!=="__virtual__")throw new Error('Assertion failed: Virtual folders must be named "__virtual__"');if(!v.basename(r).match(she))throw new Error("Assertion failed: Virtual components must be ended by an hexadecimal hash");let s=v.relative(v.dirname(e),i).split("/"),o=0;for(;o{let r=t.indexOf(e);if(r<=0)return null;let i=r;for(;r>=0&&(i=r+e.length,t[i]!==v.sep);){if(t[r-1]===v.sep)return null;r=t.indexOf(e,i)}return t.length>i&&t[i]!==v.sep?null:t.slice(0,i)},Jn=class extends gl{constructor({libzip:e,baseFs:r=new Wt,filter:i=null,maxOpenFiles:n=Infinity,readOnlyArchives:s=!1,useCache:o=!0,maxAge:a=5e3,fileExtensions:l=null}){super();this.fdMap=new Map;this.nextFd=3;this.isZip=new Set;this.notZip=new Set;this.realPaths=new Map;this.limitOpenFilesTimeout=null;this.libzipFactory=typeof e!="function"?()=>e:e,this.baseFs=r,this.zipInstances=o?new Map:null,this.filter=i,this.maxOpenFiles=n,this.readOnlyArchives=s,this.maxAge=a,this.fileExtensions=l}static async openPromise(e,r){let i=new Jn(r);try{return await e(i)}finally{i.saveAndClose()}}get libzip(){return typeof this.libzipInstance=="undefined"&&(this.libzipInstance=this.libzipFactory()),this.libzipInstance}getExtractHint(e){return this.baseFs.getExtractHint(e)}getRealPath(){return this.baseFs.getRealPath()}saveAndClose(){if(sh(this),this.zipInstances)for(let[e,{zipFs:r}]of this.zipInstances.entries())r.saveAndClose(),this.zipInstances.delete(e)}discardAndClose(){if(sh(this),this.zipInstances)for(let[e,{zipFs:r}]of this.zipInstances.entries())r.discardAndClose(),this.zipInstances.delete(e)}resolve(e){return this.baseFs.resolve(e)}remapFd(e,r){let i=this.nextFd++|$o;return this.fdMap.set(i,[e,r]),i}async openPromise(e,r,i){return await this.makeCallPromise(e,async()=>await this.baseFs.openPromise(e,r,i),async(n,{subPath:s})=>this.remapFd(n,await n.openPromise(s,r,i)))}openSync(e,r,i){return this.makeCallSync(e,()=>this.baseFs.openSync(e,r,i),(n,{subPath:s})=>this.remapFd(n,n.openSync(s,r,i)))}async opendirPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.opendirPromise(e,r),async(i,{subPath:n})=>await i.opendirPromise(n,r),{requireSubpath:!1})}opendirSync(e,r){return this.makeCallSync(e,()=>this.baseFs.opendirSync(e,r),(i,{subPath:n})=>i.opendirSync(n,r),{requireSubpath:!1})}async readPromise(e,r,i,n,s){if((e&$o)==0)return await this.baseFs.readPromise(e,r,i,n,s);let o=this.fdMap.get(e);if(typeof o=="undefined")throw Hi("read");let[a,l]=o;return await a.readPromise(l,r,i,n,s)}readSync(e,r,i,n,s){if((e&$o)==0)return this.baseFs.readSync(e,r,i,n,s);let o=this.fdMap.get(e);if(typeof o=="undefined")throw Hi("readSync");let[a,l]=o;return a.readSync(l,r,i,n,s)}async writePromise(e,r,i,n,s){if((e&$o)==0)return typeof r=="string"?await this.baseFs.writePromise(e,r,i):await this.baseFs.writePromise(e,r,i,n,s);let o=this.fdMap.get(e);if(typeof o=="undefined")throw Hi("write");let[a,l]=o;return typeof r=="string"?await a.writePromise(l,r,i):await a.writePromise(l,r,i,n,s)}writeSync(e,r,i,n,s){if((e&$o)==0)return typeof r=="string"?this.baseFs.writeSync(e,r,i):this.baseFs.writeSync(e,r,i,n,s);let o=this.fdMap.get(e);if(typeof o=="undefined")throw Hi("writeSync");let[a,l]=o;return typeof r=="string"?a.writeSync(l,r,i):a.writeSync(l,r,i,n,s)}async closePromise(e){if((e&$o)==0)return await this.baseFs.closePromise(e);let r=this.fdMap.get(e);if(typeof r=="undefined")throw Hi("close");this.fdMap.delete(e);let[i,n]=r;return await i.closePromise(n)}closeSync(e){if((e&$o)==0)return this.baseFs.closeSync(e);let r=this.fdMap.get(e);if(typeof r=="undefined")throw Hi("closeSync");this.fdMap.delete(e);let[i,n]=r;return i.closeSync(n)}createReadStream(e,r){return e===null?this.baseFs.createReadStream(e,r):this.makeCallSync(e,()=>this.baseFs.createReadStream(e,r),(i,{subPath:n})=>i.createReadStream(n,r))}createWriteStream(e,r){return e===null?this.baseFs.createWriteStream(e,r):this.makeCallSync(e,()=>this.baseFs.createWriteStream(e,r),(i,{subPath:n})=>i.createWriteStream(n,r))}async realpathPromise(e){return await this.makeCallPromise(e,async()=>await this.baseFs.realpathPromise(e),async(r,{archivePath:i,subPath:n})=>{let s=this.realPaths.get(i);return typeof s=="undefined"&&(s=await this.baseFs.realpathPromise(i),this.realPaths.set(i,s)),this.pathUtils.join(s,this.pathUtils.relative(Se.root,await r.realpathPromise(n)))})}realpathSync(e){return this.makeCallSync(e,()=>this.baseFs.realpathSync(e),(r,{archivePath:i,subPath:n})=>{let s=this.realPaths.get(i);return typeof s=="undefined"&&(s=this.baseFs.realpathSync(i),this.realPaths.set(i,s)),this.pathUtils.join(s,this.pathUtils.relative(Se.root,r.realpathSync(n)))})}async existsPromise(e){return await this.makeCallPromise(e,async()=>await this.baseFs.existsPromise(e),async(r,{subPath:i})=>await r.existsPromise(i))}existsSync(e){return this.makeCallSync(e,()=>this.baseFs.existsSync(e),(r,{subPath:i})=>r.existsSync(i))}async accessPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.accessPromise(e,r),async(i,{subPath:n})=>await i.accessPromise(n,r))}accessSync(e,r){return this.makeCallSync(e,()=>this.baseFs.accessSync(e,r),(i,{subPath:n})=>i.accessSync(n,r))}async statPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.statPromise(e,r),async(i,{subPath:n})=>await i.statPromise(n,r))}statSync(e,r){return this.makeCallSync(e,()=>this.baseFs.statSync(e,r),(i,{subPath:n})=>i.statSync(n,r))}async fstatPromise(e,r){if((e&$o)==0)return this.baseFs.fstatPromise(e,r);let i=this.fdMap.get(e);if(typeof i=="undefined")throw Hi("fstat");let[n,s]=i;return n.fstatPromise(s,r)}fstatSync(e,r){if((e&$o)==0)return this.baseFs.fstatSync(e,r);let i=this.fdMap.get(e);if(typeof i=="undefined")throw Hi("fstatSync");let[n,s]=i;return n.fstatSync(s,r)}async lstatPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.lstatPromise(e,r),async(i,{subPath:n})=>await i.lstatPromise(n,r))}lstatSync(e,r){return this.makeCallSync(e,()=>this.baseFs.lstatSync(e,r),(i,{subPath:n})=>i.lstatSync(n,r))}async chmodPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.chmodPromise(e,r),async(i,{subPath:n})=>await i.chmodPromise(n,r))}chmodSync(e,r){return this.makeCallSync(e,()=>this.baseFs.chmodSync(e,r),(i,{subPath:n})=>i.chmodSync(n,r))}async chownPromise(e,r,i){return await this.makeCallPromise(e,async()=>await this.baseFs.chownPromise(e,r,i),async(n,{subPath:s})=>await n.chownPromise(s,r,i))}chownSync(e,r,i){return this.makeCallSync(e,()=>this.baseFs.chownSync(e,r,i),(n,{subPath:s})=>n.chownSync(s,r,i))}async renamePromise(e,r){return await this.makeCallPromise(e,async()=>await this.makeCallPromise(r,async()=>await this.baseFs.renamePromise(e,r),async()=>{throw Object.assign(new Error("EEXDEV: cross-device link not permitted"),{code:"EEXDEV"})}),async(i,{subPath:n})=>await this.makeCallPromise(r,async()=>{throw Object.assign(new Error("EEXDEV: cross-device link not permitted"),{code:"EEXDEV"})},async(s,{subPath:o})=>{if(i!==s)throw Object.assign(new Error("EEXDEV: cross-device link not permitted"),{code:"EEXDEV"});return await i.renamePromise(n,o)}))}renameSync(e,r){return this.makeCallSync(e,()=>this.makeCallSync(r,()=>this.baseFs.renameSync(e,r),()=>{throw Object.assign(new Error("EEXDEV: cross-device link not permitted"),{code:"EEXDEV"})}),(i,{subPath:n})=>this.makeCallSync(r,()=>{throw Object.assign(new Error("EEXDEV: cross-device link not permitted"),{code:"EEXDEV"})},(s,{subPath:o})=>{if(i!==s)throw Object.assign(new Error("EEXDEV: cross-device link not permitted"),{code:"EEXDEV"});return i.renameSync(n,o)}))}async copyFilePromise(e,r,i=0){let n=async(s,o,a,l)=>{if((i&Ah.constants.COPYFILE_FICLONE_FORCE)!=0)throw Object.assign(new Error(`EXDEV: cross-device clone not permitted, copyfile '${o}' -> ${l}'`),{code:"EXDEV"});if(i&Ah.constants.COPYFILE_EXCL&&await this.existsPromise(o))throw Object.assign(new Error(`EEXIST: file already exists, copyfile '${o}' -> '${l}'`),{code:"EEXIST"});let c;try{c=await s.readFilePromise(o)}catch(u){throw Object.assign(new Error(`EINVAL: invalid argument, copyfile '${o}' -> '${l}'`),{code:"EINVAL"})}await a.writeFilePromise(l,c)};return await this.makeCallPromise(e,async()=>await this.makeCallPromise(r,async()=>await this.baseFs.copyFilePromise(e,r,i),async(s,{subPath:o})=>await n(this.baseFs,e,s,o)),async(s,{subPath:o})=>await this.makeCallPromise(r,async()=>await n(s,o,this.baseFs,r),async(a,{subPath:l})=>s!==a?await n(s,o,a,l):await s.copyFilePromise(o,l,i)))}copyFileSync(e,r,i=0){let n=(s,o,a,l)=>{if((i&Ah.constants.COPYFILE_FICLONE_FORCE)!=0)throw Object.assign(new Error(`EXDEV: cross-device clone not permitted, copyfile '${o}' -> ${l}'`),{code:"EXDEV"});if(i&Ah.constants.COPYFILE_EXCL&&this.existsSync(o))throw Object.assign(new Error(`EEXIST: file already exists, copyfile '${o}' -> '${l}'`),{code:"EEXIST"});let c;try{c=s.readFileSync(o)}catch(u){throw Object.assign(new Error(`EINVAL: invalid argument, copyfile '${o}' -> '${l}'`),{code:"EINVAL"})}a.writeFileSync(l,c)};return this.makeCallSync(e,()=>this.makeCallSync(r,()=>this.baseFs.copyFileSync(e,r,i),(s,{subPath:o})=>n(this.baseFs,e,s,o)),(s,{subPath:o})=>this.makeCallSync(r,()=>n(s,o,this.baseFs,r),(a,{subPath:l})=>s!==a?n(s,o,a,l):s.copyFileSync(o,l,i)))}async appendFilePromise(e,r,i){return await this.makeCallPromise(e,async()=>await this.baseFs.appendFilePromise(e,r,i),async(n,{subPath:s})=>await n.appendFilePromise(s,r,i))}appendFileSync(e,r,i){return this.makeCallSync(e,()=>this.baseFs.appendFileSync(e,r,i),(n,{subPath:s})=>n.appendFileSync(s,r,i))}async writeFilePromise(e,r,i){return await this.makeCallPromise(e,async()=>await this.baseFs.writeFilePromise(e,r,i),async(n,{subPath:s})=>await n.writeFilePromise(s,r,i))}writeFileSync(e,r,i){return this.makeCallSync(e,()=>this.baseFs.writeFileSync(e,r,i),(n,{subPath:s})=>n.writeFileSync(s,r,i))}async unlinkPromise(e){return await this.makeCallPromise(e,async()=>await this.baseFs.unlinkPromise(e),async(r,{subPath:i})=>await r.unlinkPromise(i))}unlinkSync(e){return this.makeCallSync(e,()=>this.baseFs.unlinkSync(e),(r,{subPath:i})=>r.unlinkSync(i))}async utimesPromise(e,r,i){return await this.makeCallPromise(e,async()=>await this.baseFs.utimesPromise(e,r,i),async(n,{subPath:s})=>await n.utimesPromise(s,r,i))}utimesSync(e,r,i){return this.makeCallSync(e,()=>this.baseFs.utimesSync(e,r,i),(n,{subPath:s})=>n.utimesSync(s,r,i))}async mkdirPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.mkdirPromise(e,r),async(i,{subPath:n})=>await i.mkdirPromise(n,r))}mkdirSync(e,r){return this.makeCallSync(e,()=>this.baseFs.mkdirSync(e,r),(i,{subPath:n})=>i.mkdirSync(n,r))}async rmdirPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.rmdirPromise(e,r),async(i,{subPath:n})=>await i.rmdirPromise(n,r))}rmdirSync(e,r){return this.makeCallSync(e,()=>this.baseFs.rmdirSync(e,r),(i,{subPath:n})=>i.rmdirSync(n,r))}async linkPromise(e,r){return await this.makeCallPromise(r,async()=>await this.baseFs.linkPromise(e,r),async(i,{subPath:n})=>await i.linkPromise(e,n))}linkSync(e,r){return this.makeCallSync(r,()=>this.baseFs.linkSync(e,r),(i,{subPath:n})=>i.linkSync(e,n))}async symlinkPromise(e,r,i){return await this.makeCallPromise(r,async()=>await this.baseFs.symlinkPromise(e,r,i),async(n,{subPath:s})=>await n.symlinkPromise(e,s))}symlinkSync(e,r,i){return this.makeCallSync(r,()=>this.baseFs.symlinkSync(e,r,i),(n,{subPath:s})=>n.symlinkSync(e,s))}async readFilePromise(e,r){return this.makeCallPromise(e,async()=>{switch(r){case"utf8":return await this.baseFs.readFilePromise(e,r);default:return await this.baseFs.readFilePromise(e,r)}},async(i,{subPath:n})=>await i.readFilePromise(n,r))}readFileSync(e,r){return this.makeCallSync(e,()=>{switch(r){case"utf8":return this.baseFs.readFileSync(e,r);default:return this.baseFs.readFileSync(e,r)}},(i,{subPath:n})=>i.readFileSync(n,r))}async readdirPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.readdirPromise(e,r),async(i,{subPath:n})=>await i.readdirPromise(n,r),{requireSubpath:!1})}readdirSync(e,r){return this.makeCallSync(e,()=>this.baseFs.readdirSync(e,r),(i,{subPath:n})=>i.readdirSync(n,r),{requireSubpath:!1})}async readlinkPromise(e){return await this.makeCallPromise(e,async()=>await this.baseFs.readlinkPromise(e),async(r,{subPath:i})=>await r.readlinkPromise(i))}readlinkSync(e){return this.makeCallSync(e,()=>this.baseFs.readlinkSync(e),(r,{subPath:i})=>r.readlinkSync(i))}async truncatePromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.truncatePromise(e,r),async(i,{subPath:n})=>await i.truncatePromise(n,r))}truncateSync(e,r){return this.makeCallSync(e,()=>this.baseFs.truncateSync(e,r),(i,{subPath:n})=>i.truncateSync(n,r))}watch(e,r,i){return this.makeCallSync(e,()=>this.baseFs.watch(e,r,i),(n,{subPath:s})=>n.watch(s,r,i))}watchFile(e,r,i){return this.makeCallSync(e,()=>this.baseFs.watchFile(e,r,i),()=>QE(this,e,r,i))}unwatchFile(e,r){return this.makeCallSync(e,()=>this.baseFs.unwatchFile(e,r),()=>nh(this,e,r))}async makeCallPromise(e,r,i,{requireSubpath:n=!0}={}){if(typeof e!="string")return await r();let s=this.resolve(e),o=this.findZip(s);return o?n&&o.subPath==="/"?await r():await this.getZipPromise(o.archivePath,async a=>await i(a,o)):await r()}makeCallSync(e,r,i,{requireSubpath:n=!0}={}){if(typeof e!="string")return r();let s=this.resolve(e),o=this.findZip(s);return!o||n&&o.subPath==="/"?r():this.getZipSync(o.archivePath,a=>i(a,o))}findZip(e){if(this.filter&&!this.filter.test(e))return null;let r="";for(;;){let i=e.substr(r.length),n;if(!this.fileExtensions)n=SO(i,".zip");else for(let s of this.fileExtensions)if(n=SO(i,s),n)break;if(!n)return null;if(r=this.pathUtils.join(r,n),this.isZip.has(r)===!1){if(this.notZip.has(r))continue;try{if(!this.baseFs.lstatSync(r).isFile()){this.notZip.add(r);continue}}catch{return null}this.isZip.add(r)}return{archivePath:r,subPath:this.pathUtils.join(Se.root,e.substr(r.length))}}}limitOpenFiles(e){if(this.zipInstances===null)return;let r=Date.now(),i=r+this.maxAge,n=e===null?0:this.zipInstances.size-e;for(let[s,{zipFs:o,expiresAt:a,refCount:l}]of this.zipInstances.entries())if(!(l!==0||o.hasOpenFileHandles())){if(r>=a){o.saveAndClose(),this.zipInstances.delete(s),n-=1;continue}else if(e===null||n<=0){i=a;break}o.saveAndClose(),this.zipInstances.delete(s),n-=1}this.limitOpenFilesTimeout===null&&(e===null&&this.zipInstances.size>0||e!==null)&&(this.limitOpenFilesTimeout=setTimeout(()=>{this.limitOpenFilesTimeout=null,this.limitOpenFiles(null)},i-r).unref())}async getZipPromise(e,r){let i=async()=>({baseFs:this.baseFs,libzip:this.libzip,readOnly:this.readOnlyArchives,stats:await this.baseFs.statPromise(e)});if(this.zipInstances){let n=this.zipInstances.get(e);if(!n){let s=await i();n=this.zipInstances.get(e),n||(n={zipFs:new Jr(e,s),expiresAt:0,refCount:0})}this.zipInstances.delete(e),this.limitOpenFiles(this.maxOpenFiles-1),this.zipInstances.set(e,n),n.expiresAt=Date.now()+this.maxAge,n.refCount+=1;try{return await r(n.zipFs)}finally{n.refCount-=1}}else{let n=new Jr(e,await i());try{return await r(n)}finally{n.saveAndClose()}}}getZipSync(e,r){let i=()=>({baseFs:this.baseFs,libzip:this.libzip,readOnly:this.readOnlyArchives,stats:this.baseFs.statSync(e)});if(this.zipInstances){let n=this.zipInstances.get(e);return n||(n={zipFs:new Jr(e,i()),expiresAt:0,refCount:0}),this.zipInstances.delete(e),this.limitOpenFiles(this.maxOpenFiles-1),this.zipInstances.set(e,n),n.expiresAt=Date.now()+this.maxAge,r(n.zipFs)}else{let n=new Jr(e,i());try{return r(n)}finally{n.saveAndClose()}}}};var lh=ie(require("util"));var vE=ie(require("url"));var hb=class extends fi{constructor(e){super(M);this.baseFs=e}mapFromBase(e){return e}mapToBase(e){return e instanceof vE.URL?(0,vE.fileURLToPath)(e):e}};var ohe=new Set(["accessSync","appendFileSync","createReadStream","createWriteStream","chmodSync","chownSync","closeSync","copyFileSync","linkSync","lstatSync","fstatSync","lutimesSync","mkdirSync","openSync","opendirSync","readSync","readlinkSync","readFileSync","readdirSync","readlinkSync","realpathSync","renameSync","rmdirSync","statSync","symlinkSync","truncateSync","unlinkSync","unwatchFile","utimesSync","watch","watchFile","writeFileSync","writeSync"]),xO=new Set(["accessPromise","appendFilePromise","chmodPromise","chownPromise","closePromise","copyFilePromise","linkPromise","fstatPromise","lstatPromise","lutimesPromise","mkdirPromise","openPromise","opendirPromise","readdirPromise","realpathPromise","readFilePromise","readdirPromise","readlinkPromise","renamePromise","rmdirPromise","statPromise","symlinkPromise","truncatePromise","unlinkPromise","utimesPromise","writeFilePromise","writeSync"]),ahe=new Set(["appendFilePromise","chmodPromise","chownPromise","closePromise","readPromise","readFilePromise","statPromise","truncatePromise","utimesPromise","writePromise","writeFilePromise"]);function pb(t,e){e=new hb(e);let r=(i,n,s)=>{let o=i[n];i[n]=s,typeof(o==null?void 0:o[lh.promisify.custom])!="undefined"&&(s[lh.promisify.custom]=o[lh.promisify.custom])};{r(t,"exists",(i,...n)=>{let o=typeof n[n.length-1]=="function"?n.pop():()=>{};process.nextTick(()=>{e.existsPromise(i).then(a=>{o(a)},()=>{o(!1)})})}),r(t,"read",(i,n,...s)=>{let a=typeof s[s.length-1]=="function"?s.pop():()=>{};process.nextTick(()=>{e.readPromise(i,n,...s).then(l=>{a(null,l,n)},l=>{a(l,0,n)})})});for(let i of xO){let n=i.replace(/Promise$/,"");if(typeof t[n]=="undefined")continue;let s=e[i];if(typeof s=="undefined")continue;r(t,n,(...a)=>{let c=typeof a[a.length-1]=="function"?a.pop():()=>{};process.nextTick(()=>{s.apply(e,a).then(u=>{c(null,u)},u=>{c(u)})})})}t.realpath.native=t.realpath}{r(t,"existsSync",i=>{try{return e.existsSync(i)}catch(n){return!1}});for(let i of ohe){let n=i;if(typeof t[n]=="undefined")continue;let s=e[i];typeof s!="undefined"&&r(t,n,s.bind(e))}t.realpathSync.native=t.realpathSync}{let i=process.emitWarning;process.emitWarning=()=>{};let n;try{n=t.promises}finally{process.emitWarning=i}if(typeof n!="undefined"){for(let o of xO){let a=o.replace(/Promise$/,"");if(typeof n[a]=="undefined")continue;let l=e[o];typeof l!="undefined"&&o!=="open"&&r(n,a,l.bind(e))}class s{constructor(a){this.fd=a}}for(let o of ahe){let a=o.replace(/Promise$/,""),l=e[o];typeof l!="undefined"&&r(s.prototype,a,function(...c){return l.call(e,this.fd,...c)})}r(n,"open",async(...o)=>{let a=await e.openPromise(...o);return new s(a)})}}t.read[lh.promisify.custom]=async(i,n,...s)=>({bytesRead:await e.readPromise(i,n,...s),buffer:n})}function SE(t,e){let r=Object.create(t);return pb(r,e),r}var kO=ie(require("os"));function PO(t){let e=M.toPortablePath(kO.default.tmpdir()),r=Math.ceil(Math.random()*4294967296).toString(16).padStart(8,"0");return v.join(e,`${t}${r}`)}var vs=new Set,DO=!1;function RO(){DO||(DO=!0,process.once("exit",()=>{T.rmtempSync()}))}var T=Object.assign(new Wt,{detachTemp(t){vs.delete(t)},mktempSync(t){for(RO();;){let e=PO("xfs-");try{this.mkdirSync(e)}catch(i){if(i.code==="EEXIST")continue;throw i}let r=this.realpathSync(e);if(vs.add(r),typeof t!="undefined")try{return t(r)}finally{if(vs.has(r)){vs.delete(r);try{this.removeSync(r)}catch{}}}else return r}},async mktempPromise(t){for(RO();;){let e=PO("xfs-");try{await this.mkdirPromise(e)}catch(i){if(i.code==="EEXIST")continue;throw i}let r=await this.realpathPromise(e);if(vs.add(r),typeof t!="undefined")try{return await t(r)}finally{if(vs.has(r)){vs.delete(r);try{await this.removePromise(r)}catch{}}}else return r}},async rmtempPromise(){await Promise.all(Array.from(vs.values()).map(async t=>{try{await T.removePromise(t,{maxRetries:0}),vs.delete(t)}catch{}}))},rmtempSync(){for(let t of vs)try{T.removeSync(t),vs.delete(t)}catch{}}});var vb=ie(bb()),Pn;(function(i){i[i.Never=0]="Never",i[i.ErrorCode=1]="ErrorCode",i[i.Always=2]="Always"})(Pn||(Pn={}));function dl(t){return t!==null&&typeof t.fd=="number"}var Cl=new Set;function Sb(){}function xb(){for(let t of Cl)t.kill()}async function to(t,e,{cwd:r,env:i=process.env,strict:n=!1,stdin:s=null,stdout:o,stderr:a,end:l=2}){let c=["pipe","pipe","pipe"];s===null?c[0]="ignore":dl(s)&&(c[0]=s),dl(o)&&(c[1]=o),dl(a)&&(c[2]=a);let u=(0,vb.default)(t,e,{cwd:M.fromPortablePath(r),env:_(P({},i),{PWD:M.fromPortablePath(r)}),stdio:c});Cl.add(u),Cl.size===1&&(process.on("SIGINT",Sb),process.on("SIGTERM",xb)),!dl(s)&&s!==null&&s.pipe(u.stdin),dl(o)||u.stdout.pipe(o,{end:!1}),dl(a)||u.stderr.pipe(a,{end:!1});let g=()=>{for(let f of new Set([o,a]))dl(f)||f.end()};return new Promise((f,h)=>{u.on("error",p=>{Cl.delete(u),Cl.size===0&&(process.off("SIGINT",Sb),process.off("SIGTERM",xb)),(l===2||l===1)&&g(),h(p)}),u.on("close",(p,d)=>{Cl.delete(u),Cl.size===0&&(process.off("SIGINT",Sb),process.off("SIGTERM",xb)),(l===2||l===1&&p>0)&&g(),p===0||!n?f({code:kb(p,d)}):h(p!==null?new Error(`Child "${t}" exited with exit code ${p}`):new Error(`Child "${t}" exited with signal ${d}`))})})}async function Nhe(t,e,{cwd:r,env:i=process.env,encoding:n="utf8",strict:s=!1}){let o=["ignore","pipe","pipe"],a=[],l=[],c=M.fromPortablePath(r);typeof i.PWD!="undefined"&&(i=_(P({},i),{PWD:c}));let u=(0,vb.default)(t,e,{cwd:c,env:i,stdio:o});return u.stdout.on("data",g=>{a.push(g)}),u.stderr.on("data",g=>{l.push(g)}),await new Promise((g,f)=>{u.on("error",()=>{f()}),u.on("close",(h,p)=>{let d=n==="buffer"?Buffer.concat(a):Buffer.concat(a).toString(n),m=n==="buffer"?Buffer.concat(l):Buffer.concat(l).toString(n);h===0||!s?g({code:kb(h,p),stdout:d,stderr:m}):f(Object.assign(new Error(`Child "${t}" exited with exit code ${h} + +${m}`),{code:kb(h,p),stdout:d,stderr:m}))})})}var Lhe=new Map([["SIGINT",2],["SIGQUIT",3],["SIGKILL",9],["SIGTERM",15]]);function kb(t,e){let r=Lhe.get(e);return typeof r!="undefined"?128+r:t!=null?t:1}var Pb={};it(Pb,{getDefaultGlobalFolder:()=>Rb,getHomeFolder:()=>uh,isFolderInside:()=>Fb});var Db=ie(require("os"));function Rb(){if(process.platform==="win32"){let t=M.toPortablePath(process.env.LOCALAPPDATA||M.join((0,Db.homedir)(),"AppData","Local"));return v.resolve(t,"Yarn/Berry")}if(process.env.XDG_DATA_HOME){let t=M.toPortablePath(process.env.XDG_DATA_HOME);return v.resolve(t,"yarn/berry")}return v.resolve(uh(),".yarn/berry")}function uh(){return M.toPortablePath((0,Db.homedir)()||"/usr/local/share")}function Fb(t,e){let r=v.relative(e,t);return r&&!r.startsWith("..")&&!v.isAbsolute(r)}var ue={};it(ue,{LogLevel:()=>Ts,Style:()=>Gl,Type:()=>Le,addLogFilterSupport:()=>Cp,applyColor:()=>On,applyHyperlink:()=>Ku,applyStyle:()=>Py,json:()=>Uu,mark:()=>xx,pretty:()=>Ve,prettyField:()=>Yl,prettyList:()=>Kx,supportsColor:()=>xy,supportsHyperlinks:()=>Mx,tuple:()=>jl});var pp=ie(jb()),dp=ie(ml()),o3=ie(Nn()),a3=ie(gU());var z;(function(te){te[te.UNNAMED=0]="UNNAMED",te[te.EXCEPTION=1]="EXCEPTION",te[te.MISSING_PEER_DEPENDENCY=2]="MISSING_PEER_DEPENDENCY",te[te.CYCLIC_DEPENDENCIES=3]="CYCLIC_DEPENDENCIES",te[te.DISABLED_BUILD_SCRIPTS=4]="DISABLED_BUILD_SCRIPTS",te[te.BUILD_DISABLED=5]="BUILD_DISABLED",te[te.SOFT_LINK_BUILD=6]="SOFT_LINK_BUILD",te[te.MUST_BUILD=7]="MUST_BUILD",te[te.MUST_REBUILD=8]="MUST_REBUILD",te[te.BUILD_FAILED=9]="BUILD_FAILED",te[te.RESOLVER_NOT_FOUND=10]="RESOLVER_NOT_FOUND",te[te.FETCHER_NOT_FOUND=11]="FETCHER_NOT_FOUND",te[te.LINKER_NOT_FOUND=12]="LINKER_NOT_FOUND",te[te.FETCH_NOT_CACHED=13]="FETCH_NOT_CACHED",te[te.YARN_IMPORT_FAILED=14]="YARN_IMPORT_FAILED",te[te.REMOTE_INVALID=15]="REMOTE_INVALID",te[te.REMOTE_NOT_FOUND=16]="REMOTE_NOT_FOUND",te[te.RESOLUTION_PACK=17]="RESOLUTION_PACK",te[te.CACHE_CHECKSUM_MISMATCH=18]="CACHE_CHECKSUM_MISMATCH",te[te.UNUSED_CACHE_ENTRY=19]="UNUSED_CACHE_ENTRY",te[te.MISSING_LOCKFILE_ENTRY=20]="MISSING_LOCKFILE_ENTRY",te[te.WORKSPACE_NOT_FOUND=21]="WORKSPACE_NOT_FOUND",te[te.TOO_MANY_MATCHING_WORKSPACES=22]="TOO_MANY_MATCHING_WORKSPACES",te[te.CONSTRAINTS_MISSING_DEPENDENCY=23]="CONSTRAINTS_MISSING_DEPENDENCY",te[te.CONSTRAINTS_INCOMPATIBLE_DEPENDENCY=24]="CONSTRAINTS_INCOMPATIBLE_DEPENDENCY",te[te.CONSTRAINTS_EXTRANEOUS_DEPENDENCY=25]="CONSTRAINTS_EXTRANEOUS_DEPENDENCY",te[te.CONSTRAINTS_INVALID_DEPENDENCY=26]="CONSTRAINTS_INVALID_DEPENDENCY",te[te.CANT_SUGGEST_RESOLUTIONS=27]="CANT_SUGGEST_RESOLUTIONS",te[te.FROZEN_LOCKFILE_EXCEPTION=28]="FROZEN_LOCKFILE_EXCEPTION",te[te.CROSS_DRIVE_VIRTUAL_LOCAL=29]="CROSS_DRIVE_VIRTUAL_LOCAL",te[te.FETCH_FAILED=30]="FETCH_FAILED",te[te.DANGEROUS_NODE_MODULES=31]="DANGEROUS_NODE_MODULES",te[te.NODE_GYP_INJECTED=32]="NODE_GYP_INJECTED",te[te.AUTHENTICATION_NOT_FOUND=33]="AUTHENTICATION_NOT_FOUND",te[te.INVALID_CONFIGURATION_KEY=34]="INVALID_CONFIGURATION_KEY",te[te.NETWORK_ERROR=35]="NETWORK_ERROR",te[te.LIFECYCLE_SCRIPT=36]="LIFECYCLE_SCRIPT",te[te.CONSTRAINTS_MISSING_FIELD=37]="CONSTRAINTS_MISSING_FIELD",te[te.CONSTRAINTS_INCOMPATIBLE_FIELD=38]="CONSTRAINTS_INCOMPATIBLE_FIELD",te[te.CONSTRAINTS_EXTRANEOUS_FIELD=39]="CONSTRAINTS_EXTRANEOUS_FIELD",te[te.CONSTRAINTS_INVALID_FIELD=40]="CONSTRAINTS_INVALID_FIELD",te[te.AUTHENTICATION_INVALID=41]="AUTHENTICATION_INVALID",te[te.PROLOG_UNKNOWN_ERROR=42]="PROLOG_UNKNOWN_ERROR",te[te.PROLOG_SYNTAX_ERROR=43]="PROLOG_SYNTAX_ERROR",te[te.PROLOG_EXISTENCE_ERROR=44]="PROLOG_EXISTENCE_ERROR",te[te.STACK_OVERFLOW_RESOLUTION=45]="STACK_OVERFLOW_RESOLUTION",te[te.AUTOMERGE_FAILED_TO_PARSE=46]="AUTOMERGE_FAILED_TO_PARSE",te[te.AUTOMERGE_IMMUTABLE=47]="AUTOMERGE_IMMUTABLE",te[te.AUTOMERGE_SUCCESS=48]="AUTOMERGE_SUCCESS",te[te.AUTOMERGE_REQUIRED=49]="AUTOMERGE_REQUIRED",te[te.DEPRECATED_CLI_SETTINGS=50]="DEPRECATED_CLI_SETTINGS",te[te.PLUGIN_NAME_NOT_FOUND=51]="PLUGIN_NAME_NOT_FOUND",te[te.INVALID_PLUGIN_REFERENCE=52]="INVALID_PLUGIN_REFERENCE",te[te.CONSTRAINTS_AMBIGUITY=53]="CONSTRAINTS_AMBIGUITY",te[te.CACHE_OUTSIDE_PROJECT=54]="CACHE_OUTSIDE_PROJECT",te[te.IMMUTABLE_INSTALL=55]="IMMUTABLE_INSTALL",te[te.IMMUTABLE_CACHE=56]="IMMUTABLE_CACHE",te[te.INVALID_MANIFEST=57]="INVALID_MANIFEST",te[te.PACKAGE_PREPARATION_FAILED=58]="PACKAGE_PREPARATION_FAILED",te[te.INVALID_RANGE_PEER_DEPENDENCY=59]="INVALID_RANGE_PEER_DEPENDENCY",te[te.INCOMPATIBLE_PEER_DEPENDENCY=60]="INCOMPATIBLE_PEER_DEPENDENCY",te[te.DEPRECATED_PACKAGE=61]="DEPRECATED_PACKAGE",te[te.INCOMPATIBLE_OS=62]="INCOMPATIBLE_OS",te[te.INCOMPATIBLE_CPU=63]="INCOMPATIBLE_CPU",te[te.FROZEN_ARTIFACT_EXCEPTION=64]="FROZEN_ARTIFACT_EXCEPTION",te[te.TELEMETRY_NOTICE=65]="TELEMETRY_NOTICE",te[te.PATCH_HUNK_FAILED=66]="PATCH_HUNK_FAILED",te[te.INVALID_CONFIGURATION_VALUE=67]="INVALID_CONFIGURATION_VALUE",te[te.UNUSED_PACKAGE_EXTENSION=68]="UNUSED_PACKAGE_EXTENSION",te[te.REDUNDANT_PACKAGE_EXTENSION=69]="REDUNDANT_PACKAGE_EXTENSION",te[te.AUTO_NM_SUCCESS=70]="AUTO_NM_SUCCESS",te[te.NM_CANT_INSTALL_EXTERNAL_SOFT_LINK=71]="NM_CANT_INSTALL_EXTERNAL_SOFT_LINK",te[te.NM_PRESERVE_SYMLINKS_REQUIRED=72]="NM_PRESERVE_SYMLINKS_REQUIRED",te[te.UPDATE_LOCKFILE_ONLY_SKIP_LINK=73]="UPDATE_LOCKFILE_ONLY_SKIP_LINK",te[te.NM_HARDLINKS_MODE_DOWNGRADED=74]="NM_HARDLINKS_MODE_DOWNGRADED",te[te.PROLOG_INSTANTIATION_ERROR=75]="PROLOG_INSTANTIATION_ERROR",te[te.INCOMPATIBLE_ARCHITECTURE=76]="INCOMPATIBLE_ARCHITECTURE",te[te.GHOST_ARCHITECTURE=77]="GHOST_ARCHITECTURE"})(z||(z={}));function KE(t){return`YN${t.toString(10).padStart(4,"0")}`}var de={};it(de,{BufferStream:()=>OH,CachingStrategy:()=>Dl,DefaultStream:()=>KH,assertNever:()=>Lv,bufferStream:()=>Cu,buildIgnorePattern:()=>DEe,convertMapsToIndexableObjects:()=>aI,dynamicRequire:()=>mu,escapeRegExp:()=>SEe,getArrayWithDefault:()=>hu,getFactoryWithDefault:()=>na,getMapWithDefault:()=>pu,getSetWithDefault:()=>Pl,isIndexableObject:()=>Tv,isPathLike:()=>REe,isTaggedYarnVersion:()=>vEe,mapAndFilter:()=>kl,mapAndFind:()=>MH,overrideType:()=>Nv,parseBoolean:()=>Hh,parseOptionalBoolean:()=>jH,prettifyAsyncErrors:()=>du,prettifySyncErrors:()=>Mv,releaseAfterUseAsync:()=>kEe,replaceEnvVariables:()=>Ov,sortMap:()=>gn,tryParseOptionalBoolean:()=>Kv,validateEnum:()=>xEe});var vh={};it(vh,{Builtins:()=>Iv,Cli:()=>oo,Command:()=>ye,Option:()=>Y,UsageError:()=>me});var yl=0,Eh=1,Gi=2,sv="",hi="\0",Au=-1,ov=/^(-h|--help)(?:=([0-9]+))?$/,UE=/^(--[a-z]+(?:-[a-z]+)*|-[a-zA-Z]+)$/,fU=/^-[a-zA-Z]{2,}$/,av=/^([^=]+)=([\s\S]*)$/,Av=process.env.DEBUG_CLI==="1";var me=class extends Error{constructor(e){super(e);this.clipanion={type:"usage"},this.name="UsageError"}},Ih=class extends Error{constructor(e,r){super();if(this.input=e,this.candidates=r,this.clipanion={type:"none"},this.name="UnknownSyntaxError",this.candidates.length===0)this.message="Command not found, but we're not sure what's the alternative.";else if(this.candidates.every(i=>i.reason!==null&&i.reason===r[0].reason)){let[{reason:i}]=this.candidates;this.message=`${i} + +${this.candidates.map(({usage:n})=>`$ ${n}`).join(` +`)}`}else if(this.candidates.length===1){let[{usage:i}]=this.candidates;this.message=`Command not found; did you mean: + +$ ${i} +${lv(e)}`}else this.message=`Command not found; did you mean one of: + +${this.candidates.map(({usage:i},n)=>`${`${n}.`.padStart(4)} ${i}`).join(` +`)} + +${lv(e)}`}},cv=class extends Error{constructor(e,r){super();this.input=e,this.usages=r,this.clipanion={type:"none"},this.name="AmbiguousSyntaxError",this.message=`Cannot find which to pick amongst the following alternatives: + +${this.usages.map((i,n)=>`${`${n}.`.padStart(4)} ${i}`).join(` +`)} + +${lv(e)}`}},lv=t=>`While running ${t.filter(e=>e!==hi).map(e=>{let r=JSON.stringify(e);return e.match(/\s/)||e.length===0||r!==`"${e}"`?r:e}).join(" ")}`;var yh=Symbol("clipanion/isOption");function ji(t){return _(P({},t),{[yh]:!0})}function so(t,e){return typeof t=="undefined"?[t,e]:typeof t=="object"&&t!==null&&!Array.isArray(t)?[void 0,t]:[t,e]}function HE(t,e=!1){let r=t.replace(/^\.: /,"");return e&&(r=r[0].toLowerCase()+r.slice(1)),r}function wh(t,e){return e.length===1?new me(`${t}: ${HE(e[0],!0)}`):new me(`${t}: +${e.map(r=>` +- ${HE(r)}`).join("")}`)}function Bh(t,e,r){if(typeof r=="undefined")return e;let i=[],n=[],s=a=>{let l=e;return e=a,s.bind(null,l)};if(!r(e,{errors:i,coercions:n,coercion:s}))throw wh(`Invalid value for ${t}`,i);for(let[,a]of n)a();return e}var ye=class{constructor(){this.help=!1}static Usage(e){return e}async catch(e){throw e}async validateAndExecute(){let r=this.constructor.schema;if(typeof r!="undefined"){let{isDict:n,isUnknown:s,applyCascade:o}=await Promise.resolve().then(()=>(Ss(),lu)),a=o(n(s()),r),l=[],c=[];if(!a(this,{errors:l,coercions:c}))throw wh("Invalid option schema",l);for(let[,g]of c)g()}let i=await this.execute();return typeof i!="undefined"?i:0}};ye.isOption=yh;ye.Default=[];function un(t){Av&&console.log(t)}var BU={candidateUsage:null,requiredOptions:[],errorMessage:null,ignoreOptions:!1,path:[],positionals:[],options:[],remainder:null,selectedIndex:Au};function QU(){return{nodes:[qi(),qi(),qi()]}}function nCe(t){let e=QU(),r=[],i=e.nodes.length;for(let n of t){r.push(i);for(let s=0;s{if(e.has(i))return;e.add(i);let n=t.nodes[i];for(let o of Object.values(n.statics))for(let{to:a}of o)r(a);for(let[,{to:o}]of n.dynamics)r(o);for(let{to:o}of n.shortcuts)r(o);let s=new Set(n.shortcuts.map(({to:o})=>o));for(;n.shortcuts.length>0;){let{to:o}=n.shortcuts.shift(),a=t.nodes[o];for(let[l,c]of Object.entries(a.statics)){let u=Object.prototype.hasOwnProperty.call(n.statics,l)?n.statics[l]:n.statics[l]=[];for(let g of c)u.some(({to:f})=>g.to===f)||u.push(g)}for(let[l,c]of a.dynamics)n.dynamics.some(([u,{to:g}])=>l===u&&c.to===g)||n.dynamics.push([l,c]);for(let l of a.shortcuts)s.has(l.to)||(n.shortcuts.push(l),s.add(l.to))}};r(yl)}function oCe(t,{prefix:e=""}={}){if(Av){un(`${e}Nodes are:`);for(let r=0;rl!==Gi).map(({state:l})=>({usage:l.candidateUsage,reason:null})));if(a.every(({node:l})=>l===Gi))throw new Ih(e,a.map(({state:l})=>({usage:l.candidateUsage,reason:l.errorMessage})));i=aCe(a)}if(i.length>0){un(" Results:");for(let s of i)un(` - ${s.node} -> ${JSON.stringify(s.state)}`)}else un(" No results");return i}function ACe(t,e){if(e.selectedIndex!==null)return!0;if(Object.prototype.hasOwnProperty.call(t.statics,hi)){for(let{to:r}of t.statics[hi])if(r===Eh)return!0}return!1}function cCe(t,e,r){let i=r&&e.length>0?[""]:[],n=vU(t,e,r),s=[],o=new Set,a=(l,c,u=!0)=>{let g=[c];for(;g.length>0;){let h=g;g=[];for(let p of h){let d=t.nodes[p],m=Object.keys(d.statics);for(let I of Object.keys(d.statics)){let B=m[0];for(let{to:b,reducer:R}of d.statics[B])R==="pushPath"&&(u||l.push(B),g.push(b))}}u=!1}let f=JSON.stringify(l);o.has(f)||(s.push(l),o.add(f))};for(let{node:l,state:c}of n){if(c.remainder!==null){a([c.remainder],l);continue}let u=t.nodes[l],g=ACe(u,c);for(let[f,h]of Object.entries(u.statics))(g&&f!==hi||!f.startsWith("-")&&h.some(({reducer:p})=>p==="pushPath"))&&a([...i,f],l);if(!!g)for(let[f,{to:h}]of u.dynamics){if(h===Gi)continue;let p=lCe(f,c);if(p!==null)for(let d of p)a([...i,d],l)}}return[...s].sort()}function gCe(t,e){let r=vU(t,[...e,hi]);return uCe(e,r.map(({state:i})=>i))}function aCe(t){let e=0;for(let{state:r}of t)r.path.length>e&&(e=r.path.length);return t.filter(({state:r})=>r.path.length===e)}function uCe(t,e){let r=e.filter(g=>g.selectedIndex!==null);if(r.length===0)throw new Error;let i=r.filter(g=>g.requiredOptions.every(f=>f.some(h=>g.options.find(p=>p.name===h))));if(i.length===0)throw new Ih(t,r.map(g=>({usage:g.candidateUsage,reason:null})));let n=0;for(let g of i)g.path.length>n&&(n=g.path.length);let s=i.filter(g=>g.path.length===n),o=g=>g.positionals.filter(({extra:f})=>!f).length+g.options.length,a=s.map(g=>({state:g,positionalCount:o(g)})),l=0;for(let{positionalCount:g}of a)g>l&&(l=g);let c=a.filter(({positionalCount:g})=>g===l).map(({state:g})=>g),u=fCe(c);if(u.length>1)throw new cv(t,u.map(g=>g.candidateUsage));return u[0]}function fCe(t){let e=[],r=[];for(let i of t)i.selectedIndex===Au?r.push(i):e.push(i);return r.length>0&&e.push(_(P({},BU),{path:SU(...r.map(i=>i.path)),options:r.reduce((i,n)=>i.concat(n.options),[])})),e}function SU(t,e,...r){return e===void 0?Array.from(t):SU(t.filter((i,n)=>i===e[n]),...r)}function qi(){return{dynamics:[],shortcuts:[],statics:{}}}function bU(t){return t===Eh||t===Gi}function Cv(t,e=0){return{to:bU(t.to)?t.to:t.to>2?t.to+e-2:t.to+e,reducer:t.reducer}}function iCe(t,e=0){let r=qi();for(let[i,n]of t.dynamics)r.dynamics.push([i,Cv(n,e)]);for(let i of t.shortcuts)r.shortcuts.push(Cv(i,e));for(let[i,n]of Object.entries(t.statics))r.statics[i]=n.map(s=>Cv(s,e));return r}function pi(t,e,r,i,n){t.nodes[e].dynamics.push([r,{to:i,reducer:n}])}function cu(t,e,r,i){t.nodes[e].shortcuts.push({to:r,reducer:i})}function ta(t,e,r,i,n){(Object.prototype.hasOwnProperty.call(t.nodes[e].statics,r)?t.nodes[e].statics[r]:t.nodes[e].statics[r]=[]).push({to:i,reducer:n})}function jE(t,e,r,i){if(Array.isArray(e)){let[n,...s]=e;return t[n](r,i,...s)}else return t[e](r,i)}function lCe(t,e){let r=Array.isArray(t)?YE[t[0]]:YE[t];if(typeof r.suggest=="undefined")return null;let i=Array.isArray(t)?t.slice(1):[];return r.suggest(e,...i)}var YE={always:()=>!0,isOptionLike:(t,e)=>!t.ignoreOptions&&e!=="-"&&e.startsWith("-"),isNotOptionLike:(t,e)=>t.ignoreOptions||e==="-"||!e.startsWith("-"),isOption:(t,e,r,i)=>!t.ignoreOptions&&e===r,isBatchOption:(t,e,r)=>!t.ignoreOptions&&fU.test(e)&&[...e.slice(1)].every(i=>r.includes(`-${i}`)),isBoundOption:(t,e,r,i)=>{let n=e.match(av);return!t.ignoreOptions&&!!n&&UE.test(n[1])&&r.includes(n[1])&&i.filter(s=>s.names.includes(n[1])).every(s=>s.allowBinding)},isNegatedOption:(t,e,r)=>!t.ignoreOptions&&e===`--no-${r.slice(2)}`,isHelp:(t,e)=>!t.ignoreOptions&&ov.test(e),isUnsupportedOption:(t,e,r)=>!t.ignoreOptions&&e.startsWith("-")&&UE.test(e)&&!r.includes(e),isInvalidOption:(t,e)=>!t.ignoreOptions&&e.startsWith("-")&&!UE.test(e)};YE.isOption.suggest=(t,e,r=!0)=>r?null:[e];var dv={setCandidateState:(t,e,r)=>P(P({},t),r),setSelectedIndex:(t,e,r)=>_(P({},t),{selectedIndex:r}),pushBatch:(t,e)=>_(P({},t),{options:t.options.concat([...e.slice(1)].map(r=>({name:`-${r}`,value:!0})))}),pushBound:(t,e)=>{let[,r,i]=e.match(av);return _(P({},t),{options:t.options.concat({name:r,value:i})})},pushPath:(t,e)=>_(P({},t),{path:t.path.concat(e)}),pushPositional:(t,e)=>_(P({},t),{positionals:t.positionals.concat({value:e,extra:!1})}),pushExtra:(t,e)=>_(P({},t),{positionals:t.positionals.concat({value:e,extra:!0})}),pushExtraNoLimits:(t,e)=>_(P({},t),{positionals:t.positionals.concat({value:e,extra:Ln})}),pushTrue:(t,e,r=e)=>_(P({},t),{options:t.options.concat({name:e,value:!0})}),pushFalse:(t,e,r=e)=>_(P({},t),{options:t.options.concat({name:r,value:!1})}),pushUndefined:(t,e)=>_(P({},t),{options:t.options.concat({name:e,value:void 0})}),pushStringValue:(t,e)=>{var r;let i=_(P({},t),{options:[...t.options]}),n=t.options[t.options.length-1];return n.value=((r=n.value)!==null&&r!==void 0?r:[]).concat([e]),i},setStringValue:(t,e)=>{let r=_(P({},t),{options:[...t.options]}),i=t.options[t.options.length-1];return i.value=e,r},inhibateOptions:t=>_(P({},t),{ignoreOptions:!0}),useHelp:(t,e,r)=>{let[,,i]=e.match(ov);return typeof i!="undefined"?_(P({},t),{options:[{name:"-c",value:String(r)},{name:"-i",value:i}]}):_(P({},t),{options:[{name:"-c",value:String(r)}]})},setError:(t,e,r)=>e===hi?_(P({},t),{errorMessage:`${r}.`}):_(P({},t),{errorMessage:`${r} ("${e}").`}),setOptionArityError:(t,e)=>{let r=t.options[t.options.length-1];return _(P({},t),{errorMessage:`Not enough arguments to option ${r.name}.`})}},Ln=Symbol(),xU=class{constructor(e,r){this.allOptionNames=[],this.arity={leading:[],trailing:[],extra:[],proxy:!1},this.options=[],this.paths=[],this.cliIndex=e,this.cliOpts=r}addPath(e){this.paths.push(e)}setArity({leading:e=this.arity.leading,trailing:r=this.arity.trailing,extra:i=this.arity.extra,proxy:n=this.arity.proxy}){Object.assign(this.arity,{leading:e,trailing:r,extra:i,proxy:n})}addPositional({name:e="arg",required:r=!0}={}){if(!r&&this.arity.extra===Ln)throw new Error("Optional parameters cannot be declared when using .rest() or .proxy()");if(!r&&this.arity.trailing.length>0)throw new Error("Optional parameters cannot be declared after the required trailing positional arguments");!r&&this.arity.extra!==Ln?this.arity.extra.push(e):this.arity.extra!==Ln&&this.arity.extra.length===0?this.arity.leading.push(e):this.arity.trailing.push(e)}addRest({name:e="arg",required:r=0}={}){if(this.arity.extra===Ln)throw new Error("Infinite lists cannot be declared multiple times in the same command");if(this.arity.trailing.length>0)throw new Error("Infinite lists cannot be declared after the required trailing positional arguments");for(let i=0;i1)throw new Error("The arity cannot be higher than 1 when the option only supports the --arg=value syntax");if(!Number.isInteger(i))throw new Error(`The arity must be an integer, got ${i}`);if(i<0)throw new Error(`The arity must be positive, got ${i}`);this.allOptionNames.push(...e),this.options.push({names:e,description:r,arity:i,hidden:n,required:s,allowBinding:o})}setContext(e){this.context=e}usage({detailed:e=!0,inlineOptions:r=!0}={}){let i=[this.cliOpts.binaryName],n=[];if(this.paths.length>0&&i.push(...this.paths[0]),e){for(let{names:o,arity:a,hidden:l,description:c,required:u}of this.options){if(l)continue;let g=[];for(let h=0;h`:`[${f}]`)}i.push(...this.arity.leading.map(o=>`<${o}>`)),this.arity.extra===Ln?i.push("..."):i.push(...this.arity.extra.map(o=>`[${o}]`)),i.push(...this.arity.trailing.map(o=>`<${o}>`))}return{usage:i.join(" "),options:n}}compile(){if(typeof this.context=="undefined")throw new Error("Assertion failed: No context attached");let e=QU(),r=yl,i=this.usage().usage,n=this.options.filter(a=>a.required).map(a=>a.names);r=xs(e,qi()),ta(e,yl,sv,r,["setCandidateState",{candidateUsage:i,requiredOptions:n}]);let s=this.arity.proxy?"always":"isNotOptionLike",o=this.paths.length>0?this.paths:[[]];for(let a of o){let l=r;if(a.length>0){let f=xs(e,qi());cu(e,l,f),this.registerOptions(e,f),l=f}for(let f=0;f0||!this.arity.proxy){let f=xs(e,qi());pi(e,l,"isHelp",f,["useHelp",this.cliIndex]),ta(e,f,hi,Eh,["setSelectedIndex",Au]),this.registerOptions(e,l)}this.arity.leading.length>0&&ta(e,l,hi,Gi,["setError","Not enough positional arguments"]);let c=l;for(let f=0;f0||f+1!==this.arity.leading.length)&&ta(e,h,hi,Gi,["setError","Not enough positional arguments"]),pi(e,c,"isNotOptionLike",h,"pushPositional"),c=h}let u=c;if(this.arity.extra===Ln||this.arity.extra.length>0){let f=xs(e,qi());if(cu(e,c,f),this.arity.extra===Ln){let h=xs(e,qi());this.arity.proxy||this.registerOptions(e,h),pi(e,c,s,h,"pushExtraNoLimits"),pi(e,h,s,h,"pushExtraNoLimits"),cu(e,h,f)}else for(let h=0;h0&&ta(e,u,hi,Gi,["setError","Not enough positional arguments"]);let g=u;for(let f=0;fo.length>s.length?o:s,"");if(i.arity===0)for(let s of i.names)pi(e,r,["isOption",s,i.hidden||s!==n],r,"pushTrue"),s.startsWith("--")&&!s.startsWith("--no-")&&pi(e,r,["isNegatedOption",s],r,["pushFalse",s]);else{let s=xs(e,qi());for(let o of i.names)pi(e,r,["isOption",o,i.hidden||o!==n],s,"pushUndefined");for(let o=0;o=0&&egCe(i,n),suggest:(n,s)=>cCe(i,n,s)}}};var kU=80,mv=Array(kU).fill("\u2501");for(let t=0;t<=24;++t)mv[mv.length-t]=`[38;5;${232+t}m\u2501`;var Ev={header:t=>`\u2501\u2501\u2501 ${t}${t.length`${t}`,error:t=>`${t}`,code:t=>`${t}`},PU={header:t=>t,bold:t=>t,error:t=>t,code:t=>t};function hCe(t){let e=t.split(` +`),r=e.filter(n=>n.match(/\S/)),i=r.length>0?r.reduce((n,s)=>Math.min(n,s.length-s.trimStart().length),Number.MAX_VALUE):0;return e.map(n=>n.slice(i).trimRight()).join(` +`)}function Vn(t,{format:e,paragraphs:r}){return t=t.replace(/\r\n?/g,` +`),t=hCe(t),t=t.replace(/^\n+|\n+$/g,""),t=t.replace(/^(\s*)-([^\n]*?)\n+/gm,`$1-$2 + +`),t=t.replace(/\n(\n)?\n*/g,"$1"),r&&(t=t.split(/\n/).map(i=>{let n=i.match(/^\s*[*-][\t ]+(.*)/);if(!n)return i.match(/(.{1,80})(?: |$)/g).join(` +`);let s=i.length-i.trimStart().length;return n[1].match(new RegExp(`(.{1,${78-s}})(?: |$)`,"g")).map((o,a)=>" ".repeat(s)+(a===0?"- ":" ")+o).join(` +`)}).join(` + +`)),t=t.replace(/(`+)((?:.|[\n])*?)\1/g,(i,n,s)=>e.code(n+s+n)),t=t.replace(/(\*\*)((?:.|[\n])*?)\1/g,(i,n,s)=>e.bold(n+s+n)),t?`${t} +`:""}var bh=class extends ye{constructor(e){super();this.contexts=e,this.commands=[]}static from(e,r){let i=new bh(r);i.path=e.path;for(let n of e.options)switch(n.name){case"-c":i.commands.push(Number(n.value));break;case"-i":i.index=Number(n.value);break}return i}async execute(){let e=this.commands;if(typeof this.index!="undefined"&&this.index>=0&&this.index1){this.context.stdout.write(`Multiple commands match your selection: +`),this.context.stdout.write(` +`);let r=0;for(let i of this.commands)this.context.stdout.write(this.cli.usage(this.contexts[i].commandClass,{prefix:`${r++}. `.padStart(5)}));this.context.stdout.write(` +`),this.context.stdout.write(`Run again with -h= to see the longer details of any of those commands. +`)}}};var DU=Symbol("clipanion/errorCommand");function pCe(){return process.env.FORCE_COLOR==="0"?!1:!!(process.env.FORCE_COLOR==="1"||typeof process.stdout!="undefined"&&process.stdout.isTTY)}var oo=class{constructor({binaryLabel:e,binaryName:r="...",binaryVersion:i,enableColors:n=pCe()}={}){this.registrations=new Map,this.builder=new Qh({binaryName:r}),this.binaryLabel=e,this.binaryName=r,this.binaryVersion=i,this.enableColors=n}static from(e,r={}){let i=new oo(r);for(let n of e)i.register(n);return i}register(e){var r;let i=new Map,n=new e;for(let l in n){let c=n[l];typeof c=="object"&&c!==null&&c[ye.isOption]&&i.set(l,c)}let s=this.builder.command(),o=s.cliIndex,a=(r=e.paths)!==null&&r!==void 0?r:n.paths;if(typeof a!="undefined")for(let l of a)s.addPath(l);this.registrations.set(e,{specs:i,builder:s,index:o});for(let[l,{definition:c}]of i.entries())c(s,l);s.setContext({commandClass:e})}process(e){let{contexts:r,process:i}=this.builder.compile(),n=i(e);switch(n.selectedIndex){case Au:return bh.from(n,r);default:{let{commandClass:s}=r[n.selectedIndex],o=this.registrations.get(s);if(typeof o=="undefined")throw new Error("Assertion failed: Expected the command class to have been registered.");let a=new s;a.path=n.path;try{for(let[l,{transformer:c}]of o.specs.entries())a[l]=c(o.builder,l,n);return a}catch(l){throw l[DU]=a,l}}break}}async run(e,r){let i;if(!Array.isArray(e))i=e;else try{i=this.process(e)}catch(s){return r.stdout.write(this.error(s)),1}if(i.help)return r.stdout.write(this.usage(i,{detailed:!0})),0;i.context=r,i.cli={binaryLabel:this.binaryLabel,binaryName:this.binaryName,binaryVersion:this.binaryVersion,enableColors:this.enableColors,definitions:()=>this.definitions(),error:(s,o)=>this.error(s,o),process:s=>this.process(s),run:(s,o)=>this.run(s,P(P({},r),o)),usage:(s,o)=>this.usage(s,o)};let n;try{n=await i.validateAndExecute().catch(s=>i.catch(s).then(()=>0))}catch(s){return r.stdout.write(this.error(s,{command:i})),1}return n}async runExit(e,r){process.exitCode=await this.run(e,r)}suggest(e,r){let{suggest:i}=this.builder.compile();return i(e,r)}definitions({colored:e=!1}={}){let r=[];for(let[i,{index:n}]of this.registrations){if(typeof i.usage=="undefined")continue;let{usage:s}=this.getUsageByIndex(n,{detailed:!1}),{usage:o,options:a}=this.getUsageByIndex(n,{detailed:!0,inlineOptions:!1}),l=typeof i.usage.category!="undefined"?Vn(i.usage.category,{format:this.format(e),paragraphs:!1}):void 0,c=typeof i.usage.description!="undefined"?Vn(i.usage.description,{format:this.format(e),paragraphs:!1}):void 0,u=typeof i.usage.details!="undefined"?Vn(i.usage.details,{format:this.format(e),paragraphs:!0}):void 0,g=typeof i.usage.examples!="undefined"?i.usage.examples.map(([f,h])=>[Vn(f,{format:this.format(e),paragraphs:!1}),h.replace(/\$0/g,this.binaryName)]):void 0;r.push({path:s,usage:o,category:l,description:c,details:u,examples:g,options:a})}return r}usage(e=null,{colored:r,detailed:i=!1,prefix:n="$ "}={}){var s;if(e===null){for(let l of this.registrations.keys()){let c=l.paths,u=typeof l.usage!="undefined";if(!c||c.length===0||c.length===1&&c[0].length===0||((s=c==null?void 0:c.some(h=>h.length===0))!==null&&s!==void 0?s:!1))if(e){e=null;break}else e=l;else if(u){e=null;continue}}e&&(i=!0)}let o=e!==null&&e instanceof ye?e.constructor:e,a="";if(o)if(i){let{description:l="",details:c="",examples:u=[]}=o.usage||{};l!==""&&(a+=Vn(l,{format:this.format(r),paragraphs:!1}).replace(/^./,h=>h.toUpperCase()),a+=` +`),(c!==""||u.length>0)&&(a+=`${this.format(r).header("Usage")} +`,a+=` +`);let{usage:g,options:f}=this.getUsageByRegistration(o,{inlineOptions:!1});if(a+=`${this.format(r).bold(n)}${g} +`,f.length>0){a+=` +`,a+=`${Ev.header("Options")} +`;let h=f.reduce((p,d)=>Math.max(p,d.definition.length),0);a+=` +`;for(let{definition:p,description:d}of f)a+=` ${this.format(r).bold(p.padEnd(h))} ${Vn(d,{format:this.format(r),paragraphs:!1})}`}if(c!==""&&(a+=` +`,a+=`${this.format(r).header("Details")} +`,a+=` +`,a+=Vn(c,{format:this.format(r),paragraphs:!0})),u.length>0){a+=` +`,a+=`${this.format(r).header("Examples")} +`;for(let[h,p]of u)a+=` +`,a+=Vn(h,{format:this.format(r),paragraphs:!1}),a+=`${p.replace(/^/m,` ${this.format(r).bold(n)}`).replace(/\$0/g,this.binaryName)} +`}}else{let{usage:l}=this.getUsageByRegistration(o);a+=`${this.format(r).bold(n)}${l} +`}else{let l=new Map;for(let[f,{index:h}]of this.registrations.entries()){if(typeof f.usage=="undefined")continue;let p=typeof f.usage.category!="undefined"?Vn(f.usage.category,{format:this.format(r),paragraphs:!1}):null,d=l.get(p);typeof d=="undefined"&&l.set(p,d=[]);let{usage:m}=this.getUsageByIndex(h);d.push({commandClass:f,usage:m})}let c=Array.from(l.keys()).sort((f,h)=>f===null?-1:h===null?1:f.localeCompare(h,"en",{usage:"sort",caseFirst:"upper"})),u=typeof this.binaryLabel!="undefined",g=typeof this.binaryVersion!="undefined";u||g?(u&&g?a+=`${this.format(r).header(`${this.binaryLabel} - ${this.binaryVersion}`)} + +`:u?a+=`${this.format(r).header(`${this.binaryLabel}`)} +`:a+=`${this.format(r).header(`${this.binaryVersion}`)} +`,a+=` ${this.format(r).bold(n)}${this.binaryName} +`):a+=`${this.format(r).bold(n)}${this.binaryName} +`;for(let f of c){let h=l.get(f).slice().sort((d,m)=>d.usage.localeCompare(m.usage,"en",{usage:"sort",caseFirst:"upper"})),p=f!==null?f.trim():"General commands";a+=` +`,a+=`${this.format(r).header(`${p}`)} +`;for(let{commandClass:d,usage:m}of h){let I=d.usage.description||"undocumented";a+=` +`,a+=` ${this.format(r).bold(m)} +`,a+=` ${Vn(I,{format:this.format(r),paragraphs:!1})}`}}a+=` +`,a+=Vn("You can also print more details about any of these commands by calling them with the `-h,--help` flag right after the command name.",{format:this.format(r),paragraphs:!0})}return a}error(e,r){var i,{colored:n,command:s=(i=e[DU])!==null&&i!==void 0?i:null}=r===void 0?{}:r;e instanceof Error||(e=new Error(`Execution failed with a non-error rejection (rejected value: ${JSON.stringify(e)})`));let o="",a=e.name.replace(/([a-z])([A-Z])/g,"$1 $2");a==="Error"&&(a="Internal Error"),o+=`${this.format(n).error(a)}: ${e.message} +`;let l=e.clipanion;return typeof l!="undefined"?l.type==="usage"&&(o+=` +`,o+=this.usage(s)):e.stack&&(o+=`${e.stack.replace(/^.*\n/,"")} +`),o}getUsageByRegistration(e,r){let i=this.registrations.get(e);if(typeof i=="undefined")throw new Error("Assertion failed: Unregistered command");return this.getUsageByIndex(i.index,r)}getUsageByIndex(e,r){return this.builder.getBuilderByIndex(e).usage(r)}format(e=this.enableColors){return e?Ev:PU}};oo.defaultContext={stdin:process.stdin,stdout:process.stdout,stderr:process.stderr};var Iv={};it(Iv,{DefinitionsCommand:()=>qE,HelpCommand:()=>JE,VersionCommand:()=>WE});var qE=class extends ye{async execute(){this.context.stdout.write(`${JSON.stringify(this.cli.definitions(),null,2)} +`)}};qE.paths=[["--clipanion=definitions"]];var JE=class extends ye{async execute(){this.context.stdout.write(this.cli.usage())}};JE.paths=[["-h"],["--help"]];var WE=class extends ye{async execute(){var e;this.context.stdout.write(`${(e=this.cli.binaryVersion)!==null&&e!==void 0?e:""} +`)}};WE.paths=[["-v"],["--version"]];var Y={};it(Y,{Array:()=>RU,Boolean:()=>FU,Counter:()=>NU,Proxy:()=>LU,Rest:()=>TU,String:()=>MU,applyValidator:()=>Bh,cleanValidationError:()=>HE,formatError:()=>wh,isOptionSymbol:()=>yh,makeCommandOption:()=>ji,rerouteArguments:()=>so});function RU(t,e,r){let[i,n]=so(e,r!=null?r:{}),{arity:s=1}=n,o=t.split(","),a=new Set(o);return ji({definition(l){l.addOption({names:o,arity:s,hidden:n==null?void 0:n.hidden,description:n==null?void 0:n.description,required:n.required})},transformer(l,c,u){let g=typeof i!="undefined"?[...i]:void 0;for(let{name:f,value:h}of u.options)!a.has(f)||(g=g!=null?g:[],g.push(h));return g}})}function FU(t,e,r){let[i,n]=so(e,r!=null?r:{}),s=t.split(","),o=new Set(s);return ji({definition(a){a.addOption({names:s,allowBinding:!1,arity:0,hidden:n.hidden,description:n.description,required:n.required})},transformer(a,l,c){let u=i;for(let{name:g,value:f}of c.options)!o.has(g)||(u=f);return u}})}function NU(t,e,r){let[i,n]=so(e,r!=null?r:{}),s=t.split(","),o=new Set(s);return ji({definition(a){a.addOption({names:s,allowBinding:!1,arity:0,hidden:n.hidden,description:n.description,required:n.required})},transformer(a,l,c){let u=i;for(let{name:g,value:f}of c.options)!o.has(g)||(u!=null||(u=0),f?u+=1:u=0);return u}})}function LU(t={}){return ji({definition(e,r){var i;e.addProxy({name:(i=t.name)!==null&&i!==void 0?i:r,required:t.required})},transformer(e,r,i){return i.positionals.map(({value:n})=>n)}})}function TU(t={}){return ji({definition(e,r){var i;e.addRest({name:(i=t.name)!==null&&i!==void 0?i:r,required:t.required})},transformer(e,r,i){let n=o=>{let a=i.positionals[o];return a.extra===Ln||a.extra===!1&&oo)}})}function dCe(t,e,r){let[i,n]=so(e,r!=null?r:{}),{arity:s=1}=n,o=t.split(","),a=new Set(o);return ji({definition(l){l.addOption({names:o,arity:n.tolerateBoolean?0:s,hidden:n.hidden,description:n.description,required:n.required})},transformer(l,c,u){let g,f=i;for(let{name:h,value:p}of u.options)!a.has(h)||(g=h,f=p);return typeof f=="string"?Bh(g!=null?g:c,f,n.validator):f}})}function CCe(t={}){let{required:e=!0}=t;return ji({definition(r,i){var n;r.addPositional({name:(n=t.name)!==null&&n!==void 0?n:i,required:t.required})},transformer(r,i,n){var s;for(let o=0;oJSON.stringify(i)).join(", ")})`);return e}function kl(t,e){let r=[];for(let i of t){let n=e(i);n!==LH&&r.push(n)}return r}var LH=Symbol();kl.skip=LH;function MH(t,e){for(let r of t){let i=e(r);if(i!==TH)return i}}var TH=Symbol();MH.skip=TH;function Tv(t){return typeof t=="object"&&t!==null}function aI(t){if(t instanceof Map&&(t=Object.fromEntries(t)),Tv(t))for(let e of Object.keys(t)){let r=t[e];Tv(r)&&(t[e]=aI(r))}return t}function na(t,e,r){let i=t.get(e);return typeof i=="undefined"&&t.set(e,i=r()),i}function hu(t,e){let r=t.get(e);return typeof r=="undefined"&&t.set(e,r=[]),r}function Pl(t,e){let r=t.get(e);return typeof r=="undefined"&&t.set(e,r=new Set),r}function pu(t,e){let r=t.get(e);return typeof r=="undefined"&&t.set(e,r=new Map),r}async function kEe(t,e){if(e==null)return await t();try{return await t()}finally{await e()}}async function du(t,e){try{return await t()}catch(r){throw r.message=e(r.message),r}}function Mv(t,e){try{return t()}catch(r){throw r.message=e(r.message),r}}async function Cu(t){return await new Promise((e,r)=>{let i=[];t.on("error",n=>{r(n)}),t.on("data",n=>{i.push(n)}),t.on("end",()=>{e(Buffer.concat(i))})})}var OH=class extends Fv.Transform{constructor(){super(...arguments);this.chunks=[]}_transform(e,r,i){if(r!=="buffer"||!Buffer.isBuffer(e))throw new Error("Assertion failed: BufferStream only accept buffers");this.chunks.push(e),i(null,null)}_flush(e){e(null,Buffer.concat(this.chunks))}},KH=class extends Fv.Transform{constructor(e=Buffer.alloc(0)){super();this.active=!0;this.ifEmpty=e}_transform(e,r,i){if(r!=="buffer"||!Buffer.isBuffer(e))throw new Error("Assertion failed: DefaultStream only accept buffers");this.active=!1,i(null,e)}_flush(e){this.active&&this.ifEmpty.length>0?e(null,this.ifEmpty):e(null)}},Uh=eval("require");function UH(t){return Uh(M.fromPortablePath(t))}function HH(path){let physicalPath=M.fromPortablePath(path),currentCacheEntry=Uh.cache[physicalPath];delete Uh.cache[physicalPath];let result;try{result=UH(physicalPath);let freshCacheEntry=Uh.cache[physicalPath],dynamicModule=eval("module"),freshCacheIndex=dynamicModule.children.indexOf(freshCacheEntry);freshCacheIndex!==-1&&dynamicModule.children.splice(freshCacheIndex,1)}finally{Uh.cache[physicalPath]=currentCacheEntry}return result}var GH=new Map;function PEe(t){let e=GH.get(t),r=T.statSync(t);if((e==null?void 0:e.mtime)===r.mtimeMs)return e.instance;let i=HH(t);return GH.set(t,{mtime:r.mtimeMs,instance:i}),i}var Dl;(function(i){i[i.NoCache=0]="NoCache",i[i.FsTime=1]="FsTime",i[i.Node=2]="Node"})(Dl||(Dl={}));function mu(t,{cachingStrategy:e=2}={}){switch(e){case 0:return HH(t);case 1:return PEe(t);case 2:return UH(t);default:throw new Error("Unsupported caching strategy")}}function gn(t,e){let r=Array.from(t);Array.isArray(e)||(e=[e]);let i=[];for(let s of e)i.push(r.map(o=>s(o)));let n=r.map((s,o)=>o);return n.sort((s,o)=>{for(let a of i){let l=a[s]a[o]?1:0;if(l!==0)return l}return 0}),n.map(s=>r[s])}function DEe(t){return t.length===0?null:t.map(e=>`(${FH.default.makeRe(e,{windows:!1,dot:!0}).source})`).join("|")}function Ov(t,{env:e}){let r=/\${(?[\d\w_]+)(?:)?(?:-(?[^}]*))?}/g;return t.replace(r,(...i)=>{let{variableName:n,colon:s,fallback:o}=i[i.length-1],a=Object.prototype.hasOwnProperty.call(e,n),l=e[n];if(l||a&&!s)return l;if(o!=null)return o;throw new me(`Environment variable not found (${n})`)})}function Hh(t){switch(t){case"true":case"1":case 1:case!0:return!0;case"false":case"0":case 0:case!1:return!1;default:throw new Error(`Couldn't parse "${t}" as a boolean`)}}function jH(t){return typeof t=="undefined"?t:Hh(t)}function Kv(t){try{return jH(t)}catch{return null}}function REe(t){return!!(M.isAbsolute(t)||t.match(/^(\.{1,2}|~)\//))}var S={};it(S,{areDescriptorsEqual:()=>i3,areIdentsEqual:()=>cp,areLocatorsEqual:()=>up,areVirtualPackagesEquivalent:()=>XQe,bindDescriptor:()=>VQe,bindLocator:()=>_Qe,convertDescriptorToLocator:()=>By,convertLocatorToDescriptor:()=>WQe,convertPackageToLocator:()=>zQe,convertToIdent:()=>JQe,convertToManifestRange:()=>ebe,copyPackage:()=>ap,devirtualizeDescriptor:()=>Ap,devirtualizeLocator:()=>lp,getIdentVendorPath:()=>Lx,isPackageCompatible:()=>Sy,isVirtualDescriptor:()=>hA,isVirtualLocator:()=>Io,makeDescriptor:()=>Yt,makeIdent:()=>Eo,makeLocator:()=>Vi,makeRange:()=>by,parseDescriptor:()=>pA,parseFileStyleRange:()=>ZQe,parseIdent:()=>En,parseLocator:()=>Hl,parseRange:()=>Tu,prettyDependent:()=>Nx,prettyDescriptor:()=>Xt,prettyIdent:()=>Vr,prettyLocator:()=>lt,prettyLocatorNoColors:()=>Rx,prettyRange:()=>yy,prettyReference:()=>fp,prettyResolution:()=>Fx,prettyWorkspace:()=>hp,renamePackage:()=>op,slugifyIdent:()=>Dx,slugifyLocator:()=>Mu,sortDescriptors:()=>Ou,stringifyDescriptor:()=>In,stringifyIdent:()=>St,stringifyLocator:()=>is,tryParseDescriptor:()=>gp,tryParseIdent:()=>n3,tryParseLocator:()=>Qy,virtualizeDescriptor:()=>kx,virtualizePackage:()=>Px});var Lu=ie(require("querystring")),e3=ie(Or()),t3=ie(wY());var mn={};it(mn,{checksumFile:()=>Ey,checksumPattern:()=>Iy,makeHash:()=>zi});var my=ie(require("crypto")),Sx=ie(vx());function zi(...t){let e=(0,my.createHash)("sha512"),r="";for(let i of t)typeof i=="string"?r+=i:i&&(r&&(e.update(r),r=""),e.update(i));return r&&e.update(r),e.digest("hex")}async function Ey(t,{baseFs:e,algorithm:r}={baseFs:T,algorithm:"sha512"}){let i=await e.openPromise(t,"r");try{let n=65536,s=Buffer.allocUnsafeSlow(n),o=(0,my.createHash)(r),a=0;for(;(a=await e.readPromise(i,s,0,n))!==0;)o.update(a===n?s:s.slice(0,a));return o.digest("hex")}finally{await e.closePromise(i)}}async function Iy(t,{cwd:e}){let i=(await(0,Sx.default)(t,{cwd:M.fromPortablePath(e),expandDirectories:!1,onlyDirectories:!0,unique:!0})).map(a=>`${a}/**/*`),n=await(0,Sx.default)([t,...i],{cwd:M.fromPortablePath(e),expandDirectories:!1,onlyFiles:!1,unique:!0});n.sort();let s=await Promise.all(n.map(async a=>{let l=[Buffer.from(a)],c=M.toPortablePath(a),u=await T.lstatPromise(c);return u.isSymbolicLink()?l.push(Buffer.from(await T.readlinkPromise(c))):u.isFile()&&l.push(await T.readFilePromise(c)),l.join("\0")})),o=(0,my.createHash)("sha512");for(let a of s)o.update(a);return o.digest("hex")}var wy="virtual:",YQe=5,r3=/(os|cpu)=([a-z0-9_-]+)/,qQe=(0,t3.makeParser)(r3);function Eo(t,e){if(t==null?void 0:t.startsWith("@"))throw new Error("Invalid scope: don't prefix it with '@'");return{identHash:zi(t,e),scope:t,name:e}}function Yt(t,e){return{identHash:t.identHash,scope:t.scope,name:t.name,descriptorHash:zi(t.identHash,e),range:e}}function Vi(t,e){return{identHash:t.identHash,scope:t.scope,name:t.name,locatorHash:zi(t.identHash,e),reference:e}}function JQe(t){return{identHash:t.identHash,scope:t.scope,name:t.name}}function By(t){return{identHash:t.identHash,scope:t.scope,name:t.name,locatorHash:t.descriptorHash,reference:t.range}}function WQe(t){return{identHash:t.identHash,scope:t.scope,name:t.name,descriptorHash:t.locatorHash,range:t.reference}}function zQe(t){return{identHash:t.identHash,scope:t.scope,name:t.name,locatorHash:t.locatorHash,reference:t.reference}}function op(t,e){return{identHash:e.identHash,scope:e.scope,name:e.name,locatorHash:e.locatorHash,reference:e.reference,version:t.version,languageName:t.languageName,linkType:t.linkType,conditions:t.conditions,dependencies:new Map(t.dependencies),peerDependencies:new Map(t.peerDependencies),dependenciesMeta:new Map(t.dependenciesMeta),peerDependenciesMeta:new Map(t.peerDependenciesMeta),bin:new Map(t.bin)}}function ap(t){return op(t,t)}function kx(t,e){if(e.includes("#"))throw new Error("Invalid entropy");return Yt(t,`virtual:${e}#${t.range}`)}function Px(t,e){if(e.includes("#"))throw new Error("Invalid entropy");return op(t,Vi(t,`virtual:${e}#${t.reference}`))}function hA(t){return t.range.startsWith(wy)}function Io(t){return t.reference.startsWith(wy)}function Ap(t){if(!hA(t))throw new Error("Not a virtual descriptor");return Yt(t,t.range.replace(/^[^#]*#/,""))}function lp(t){if(!Io(t))throw new Error("Not a virtual descriptor");return Vi(t,t.reference.replace(/^[^#]*#/,""))}function VQe(t,e){return t.range.includes("::")?t:Yt(t,`${t.range}::${Lu.default.stringify(e)}`)}function _Qe(t,e){return t.reference.includes("::")?t:Vi(t,`${t.reference}::${Lu.default.stringify(e)}`)}function cp(t,e){return t.identHash===e.identHash}function i3(t,e){return t.descriptorHash===e.descriptorHash}function up(t,e){return t.locatorHash===e.locatorHash}function XQe(t,e){if(!Io(t))throw new Error("Invalid package type");if(!Io(e))throw new Error("Invalid package type");if(!cp(t,e)||t.dependencies.size!==e.dependencies.size)return!1;for(let r of t.dependencies.values()){let i=e.dependencies.get(r.identHash);if(!i||!i3(r,i))return!1}return!0}function En(t){let e=n3(t);if(!e)throw new Error(`Invalid ident (${t})`);return e}function n3(t){let e=t.match(/^(?:@([^/]+?)\/)?([^/]+)$/);if(!e)return null;let[,r,i]=e,n=typeof r!="undefined"?r:null;return Eo(n,i)}function pA(t,e=!1){let r=gp(t,e);if(!r)throw new Error(`Invalid descriptor (${t})`);return r}function gp(t,e=!1){let r=e?t.match(/^(?:@([^/]+?)\/)?([^/]+?)(?:@(.+))$/):t.match(/^(?:@([^/]+?)\/)?([^/]+?)(?:@(.+))?$/);if(!r)return null;let[,i,n,s]=r;if(s==="unknown")throw new Error(`Invalid range (${t})`);let o=typeof i!="undefined"?i:null,a=typeof s!="undefined"?s:"unknown";return Yt(Eo(o,n),a)}function Hl(t,e=!1){let r=Qy(t,e);if(!r)throw new Error(`Invalid locator (${t})`);return r}function Qy(t,e=!1){let r=e?t.match(/^(?:@([^/]+?)\/)?([^/]+?)(?:@(.+))$/):t.match(/^(?:@([^/]+?)\/)?([^/]+?)(?:@(.+))?$/);if(!r)return null;let[,i,n,s]=r;if(s==="unknown")throw new Error(`Invalid reference (${t})`);let o=typeof i!="undefined"?i:null,a=typeof s!="undefined"?s:"unknown";return Vi(Eo(o,n),a)}function Tu(t,e){let r=t.match(/^([^#:]*:)?((?:(?!::)[^#])*)(?:#((?:(?!::).)*))?(?:::(.*))?$/);if(r===null)throw new Error(`Invalid range (${t})`);let i=typeof r[1]!="undefined"?r[1]:null;if(typeof(e==null?void 0:e.requireProtocol)=="string"&&i!==e.requireProtocol)throw new Error(`Invalid protocol (${i})`);if((e==null?void 0:e.requireProtocol)&&i===null)throw new Error(`Missing protocol (${i})`);let n=typeof r[3]!="undefined"?decodeURIComponent(r[2]):null;if((e==null?void 0:e.requireSource)&&n===null)throw new Error(`Missing source (${t})`);let s=typeof r[3]!="undefined"?decodeURIComponent(r[3]):decodeURIComponent(r[2]),o=(e==null?void 0:e.parseSelector)?Lu.default.parse(s):s,a=typeof r[4]!="undefined"?Lu.default.parse(r[4]):null;return{protocol:i,source:n,selector:o,params:a}}function ZQe(t,{protocol:e}){let{selector:r,params:i}=Tu(t,{requireProtocol:e,requireBindings:!0});if(typeof i.locator!="string")throw new Error(`Assertion failed: Invalid bindings for ${t}`);return{parentLocator:Hl(i.locator,!0),path:r}}function s3(t){return t=t.replace(/%/g,"%25"),t=t.replace(/:/g,"%3A"),t=t.replace(/#/g,"%23"),t}function $Qe(t){return t===null?!1:Object.entries(t).length>0}function by({protocol:t,source:e,selector:r,params:i}){let n="";return t!==null&&(n+=`${t}`),e!==null&&(n+=`${s3(e)}#`),n+=s3(r),$Qe(i)&&(n+=`::${Lu.default.stringify(i)}`),n}function ebe(t){let{params:e,protocol:r,source:i,selector:n}=Tu(t);for(let s in e)s.startsWith("__")&&delete e[s];return by({protocol:r,source:i,params:e,selector:n})}function St(t){return t.scope?`@${t.scope}/${t.name}`:`${t.name}`}function In(t){return t.scope?`@${t.scope}/${t.name}@${t.range}`:`${t.name}@${t.range}`}function is(t){return t.scope?`@${t.scope}/${t.name}@${t.reference}`:`${t.name}@${t.reference}`}function Dx(t){return t.scope!==null?`@${t.scope}-${t.name}`:t.name}function Mu(t){let{protocol:e,selector:r}=Tu(t.reference),i=e!==null?e.replace(/:$/,""):"exotic",n=e3.default.valid(r),s=n!==null?`${i}-${n}`:`${i}`,o=10,a=t.scope?`${Dx(t)}-${s}-${t.locatorHash.slice(0,o)}`:`${Dx(t)}-${s}-${t.locatorHash.slice(0,o)}`;return kr(a)}function Vr(t,e){return e.scope?`${Ve(t,`@${e.scope}/`,Le.SCOPE)}${Ve(t,e.name,Le.NAME)}`:`${Ve(t,e.name,Le.NAME)}`}function vy(t){if(t.startsWith(wy)){let e=vy(t.substr(t.indexOf("#")+1)),r=t.substr(wy.length,YQe);return`${e} [${r}]`}else return t.replace(/\?.*/,"?[...]")}function yy(t,e){return`${Ve(t,vy(e),Le.RANGE)}`}function Xt(t,e){return`${Vr(t,e)}${Ve(t,"@",Le.RANGE)}${yy(t,e.range)}`}function fp(t,e){return`${Ve(t,vy(e),Le.REFERENCE)}`}function lt(t,e){return`${Vr(t,e)}${Ve(t,"@",Le.REFERENCE)}${fp(t,e.reference)}`}function Rx(t){return`${St(t)}@${vy(t.reference)}`}function Ou(t){return gn(t,[e=>St(e),e=>e.range])}function hp(t,e){return Vr(t,e.locator)}function Fx(t,e,r){let i=hA(e)?Ap(e):e;return r===null?`${Xt(t,i)} \u2192 ${xx(t).Cross}`:i.identHash===r.identHash?`${Xt(t,i)} \u2192 ${fp(t,r.reference)}`:`${Xt(t,i)} \u2192 ${lt(t,r)}`}function Nx(t,e,r){return r===null?`${lt(t,e)}`:`${lt(t,e)} (via ${yy(t,r.range)})`}function Lx(t){return`node_modules/${St(t)}`}function Sy(t,e){return t.conditions?qQe(t.conditions,r=>{let[,i,n]=r.match(r3),s=e[i];return s?s.includes(n):!0}):!0}var gt;(function(r){r.HARD="HARD",r.SOFT="SOFT"})(gt||(gt={}));var oi;(function(i){i.Dependency="Dependency",i.PeerDependency="PeerDependency",i.PeerDependencyMeta="PeerDependencyMeta"})(oi||(oi={}));var ki;(function(i){i.Inactive="inactive",i.Redundant="redundant",i.Active="active"})(ki||(ki={}));var Le={NO_HINT:"NO_HINT",NULL:"NULL",SCOPE:"SCOPE",NAME:"NAME",RANGE:"RANGE",REFERENCE:"REFERENCE",NUMBER:"NUMBER",PATH:"PATH",URL:"URL",ADDED:"ADDED",REMOVED:"REMOVED",CODE:"CODE",DURATION:"DURATION",SIZE:"SIZE",IDENT:"IDENT",DESCRIPTOR:"DESCRIPTOR",LOCATOR:"LOCATOR",RESOLUTION:"RESOLUTION",DEPENDENT:"DEPENDENT",PACKAGE_EXTENSION:"PACKAGE_EXTENSION",SETTING:"SETTING"},Gl;(function(e){e[e.BOLD=2]="BOLD"})(Gl||(Gl={}));var Tx=dp.default.GITHUB_ACTIONS?{level:2}:pp.default.supportsColor?{level:pp.default.supportsColor.level}:{level:0},xy=Tx.level!==0,Mx=xy&&!dp.default.GITHUB_ACTIONS&&!dp.default.CIRCLE&&!dp.default.GITLAB,Ox=new pp.default.Instance(Tx),tbe=new Map([[Le.NO_HINT,null],[Le.NULL,["#a853b5",129]],[Le.SCOPE,["#d75f00",166]],[Le.NAME,["#d7875f",173]],[Le.RANGE,["#00afaf",37]],[Le.REFERENCE,["#87afff",111]],[Le.NUMBER,["#ffd700",220]],[Le.PATH,["#d75fd7",170]],[Le.URL,["#d75fd7",170]],[Le.ADDED,["#5faf00",70]],[Le.REMOVED,["#d70000",160]],[Le.CODE,["#87afff",111]],[Le.SIZE,["#ffd700",220]]]),Ls=t=>t,ky={[Le.NUMBER]:Ls({pretty:(t,e)=>`${e}`,json:t=>t}),[Le.IDENT]:Ls({pretty:(t,e)=>Vr(t,e),json:t=>St(t)}),[Le.LOCATOR]:Ls({pretty:(t,e)=>lt(t,e),json:t=>is(t)}),[Le.DESCRIPTOR]:Ls({pretty:(t,e)=>Xt(t,e),json:t=>In(t)}),[Le.RESOLUTION]:Ls({pretty:(t,{descriptor:e,locator:r})=>Fx(t,e,r),json:({descriptor:t,locator:e})=>({descriptor:In(t),locator:e!==null?is(e):null})}),[Le.DEPENDENT]:Ls({pretty:(t,{locator:e,descriptor:r})=>Nx(t,e,r),json:({locator:t,descriptor:e})=>({locator:is(t),descriptor:In(e)})}),[Le.PACKAGE_EXTENSION]:Ls({pretty:(t,e)=>{switch(e.type){case oi.Dependency:return`${Vr(t,e.parentDescriptor)} \u27A4 ${On(t,"dependencies",Le.CODE)} \u27A4 ${Vr(t,e.descriptor)}`;case oi.PeerDependency:return`${Vr(t,e.parentDescriptor)} \u27A4 ${On(t,"peerDependencies",Le.CODE)} \u27A4 ${Vr(t,e.descriptor)}`;case oi.PeerDependencyMeta:return`${Vr(t,e.parentDescriptor)} \u27A4 ${On(t,"peerDependenciesMeta",Le.CODE)} \u27A4 ${Vr(t,En(e.selector))} \u27A4 ${On(t,e.key,Le.CODE)}`;default:throw new Error(`Assertion failed: Unsupported package extension type: ${e.type}`)}},json:t=>{switch(t.type){case oi.Dependency:return`${St(t.parentDescriptor)} > ${St(t.descriptor)}`;case oi.PeerDependency:return`${St(t.parentDescriptor)} >> ${St(t.descriptor)}`;case oi.PeerDependencyMeta:return`${St(t.parentDescriptor)} >> ${t.selector} / ${t.key}`;default:throw new Error(`Assertion failed: Unsupported package extension type: ${t.type}`)}}}),[Le.SETTING]:Ls({pretty:(t,e)=>(t.get(e),Ku(t,On(t,e,Le.CODE),`https://yarnpkg.com/configuration/yarnrc#${e}`)),json:t=>t}),[Le.DURATION]:Ls({pretty:(t,e)=>{if(e>1e3*60){let r=Math.floor(e/1e3/60),i=Math.ceil((e-r*60*1e3)/1e3);return i===0?`${r}m`:`${r}m ${i}s`}else{let r=Math.floor(e/1e3),i=e-r*1e3;return i===0?`${r}s`:`${r}s ${i}ms`}},json:t=>t}),[Le.SIZE]:Ls({pretty:(t,e)=>{let r=["KB","MB","GB","TB"],i=r.length;for(;i>1&&e<1024**i;)i-=1;let n=1024**i,s=Math.floor(e*100/n)/100;return On(t,`${s} ${r[i-1]}`,Le.NUMBER)},json:t=>t}),[Le.PATH]:Ls({pretty:(t,e)=>On(t,M.fromPortablePath(e),Le.PATH),json:t=>M.fromPortablePath(t)})};function jl(t,e){return[e,t]}function Py(t,e,r){return t.get("enableColors")&&r&2&&(e=pp.default.bold(e)),e}function On(t,e,r){if(!t.get("enableColors"))return e;let i=tbe.get(r);if(i===null)return e;let n=typeof i=="undefined"?r:Tx.level>=3?i[0]:i[1],s=typeof n=="number"?Ox.ansi256(n):n.startsWith("#")?Ox.hex(n):Ox[n];if(typeof s!="function")throw new Error(`Invalid format type ${n}`);return s(e)}var rbe=!!process.env.KONSOLE_VERSION;function Ku(t,e,r){return t.get("enableHyperlinks")?rbe?`]8;;${r}\\${e}]8;;\\`:`]8;;${r}\x07${e}]8;;\x07`:e}function Ve(t,e,r){if(e===null)return On(t,"null",Le.NULL);if(Object.prototype.hasOwnProperty.call(ky,r))return ky[r].pretty(t,e);if(typeof e!="string")throw new Error(`Assertion failed: Expected the value to be a string, got ${typeof e}`);return On(t,e,r)}function Kx(t,e,r,{separator:i=", "}={}){return[...e].map(n=>Ve(t,n,r)).join(i)}function Uu(t,e){if(t===null)return null;if(Object.prototype.hasOwnProperty.call(ky,e))return Nv(e),ky[e].json(t);if(typeof t!="string")throw new Error(`Assertion failed: Expected the value to be a string, got ${typeof t}`);return t}function xx(t){return{Check:On(t,"\u2713","green"),Cross:On(t,"\u2718","red"),Question:On(t,"?","cyan")}}function Yl(t,{label:e,value:[r,i]}){return`${Ve(t,e,Le.CODE)}: ${Ve(t,r,i)}`}var Ts;(function(n){n.Error="error",n.Warning="warning",n.Info="info",n.Discard="discard"})(Ts||(Ts={}));function Cp(t,{configuration:e}){let r=e.get("logFilters"),i=new Map,n=new Map,s=[];for(let g of r){let f=g.get("level");if(typeof f=="undefined")continue;let h=g.get("code");typeof h!="undefined"&&i.set(h,f);let p=g.get("text");typeof p!="undefined"&&n.set(p,f);let d=g.get("pattern");typeof d!="undefined"&&s.push([o3.default.matcher(d,{contains:!0}),f])}s.reverse();let o=(g,f,h)=>{if(g===null||g===z.UNNAMED)return h;let p=n.size>0||s.length>0?(0,a3.default)(f):f;if(n.size>0){let d=n.get(p);if(typeof d!="undefined")return d!=null?d:h}if(s.length>0){for(let[d,m]of s)if(d(p))return m!=null?m:h}if(i.size>0){let d=i.get(KE(g));if(typeof d!="undefined")return d!=null?d:h}return h},a=t.reportInfo,l=t.reportWarning,c=t.reportError,u=function(g,f,h,p){switch(o(f,h,p)){case Ts.Info:a.call(g,f,h);break;case Ts.Warning:l.call(g,f!=null?f:z.UNNAMED,h);break;case Ts.Error:c.call(g,f!=null?f:z.UNNAMED,h);break}};t.reportInfo=function(...g){return u(this,...g,Ts.Info)},t.reportWarning=function(...g){return u(this,...g,Ts.Warning)},t.reportError=function(...g){return u(this,...g,Ts.Error)}}var Zt={};it(Zt,{Method:()=>Jl,RequestError:()=>z8.RequestError,del:()=>pxe,get:()=>fxe,getNetworkSettings:()=>Z8,post:()=>iP,put:()=>hxe,request:()=>xp});var q8=ie(zy()),J8=ie(require("https")),W8=ie(require("http")),tP=ie(Nn()),rP=ie(G8()),Vy=ie(require("url"));var j8=ie(require("stream")),Y8=ie(require("string_decoder"));var nt=class extends Error{constructor(e,r,i){super(r);this.reportExtra=i;this.reportCode=e}};function Axe(t){return typeof t.reportCode!="undefined"}var Xi=class{constructor(){this.reportedInfos=new Set;this.reportedWarnings=new Set;this.reportedErrors=new Set}static progressViaCounter(e){let r=0,i,n=new Promise(l=>{i=l}),s=l=>{let c=i;n=new Promise(u=>{i=u}),r=l,c()},o=(l=0)=>{s(r+1)},a=async function*(){for(;r{let o=i.write(s),a;do if(a=o.indexOf(` +`),a!==-1){let l=n+o.substr(0,a);o=o.substr(a+1),n="",e!==null?this.reportInfo(null,`${e} ${l}`):this.reportInfo(null,l)}while(a!==-1);n+=o}),r.on("end",()=>{let s=i.end();s!==""&&(e!==null?this.reportInfo(null,`${e} ${s}`):this.reportInfo(null,s))}),r}};var z8=ie(zy()),V8=new Map,_8=new Map,lxe=new W8.Agent({keepAlive:!0}),cxe=new J8.Agent({keepAlive:!0});function X8(t){let e=new Vy.URL(t),r={host:e.hostname,headers:{}};return e.port&&(r.port=Number(e.port)),{proxy:r}}async function uxe(t){return na(_8,t,()=>T.readFilePromise(t).then(e=>(_8.set(t,e),e)))}function gxe({statusCode:t,statusMessage:e},r){let i=Ve(r,t,Le.NUMBER),n=`https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/${t}`;return Ku(r,`${i}${e?` (${e})`:""}`,n)}async function _y(t,{configuration:e,customErrorMessage:r}){var i,n;try{return await t}catch(s){if(s.name!=="HTTPError")throw s;let o=(n=r==null?void 0:r(s))!=null?n:(i=s.response.body)==null?void 0:i.error;o==null&&(s.message.startsWith("Response code")?o="The remote server failed to provide the requested resource":o=s.message),s instanceof q8.TimeoutError&&s.event==="socket"&&(o+=`(can be increased via ${Ve(e,"httpTimeout",Le.SETTING)})`);let a=new nt(z.NETWORK_ERROR,o,l=>{s.response&&l.reportError(z.NETWORK_ERROR,` ${Yl(e,{label:"Response Code",value:jl(Le.NO_HINT,gxe(s.response,e))})}`),s.request&&(l.reportError(z.NETWORK_ERROR,` ${Yl(e,{label:"Request Method",value:jl(Le.NO_HINT,s.request.options.method)})}`),l.reportError(z.NETWORK_ERROR,` ${Yl(e,{label:"Request URL",value:jl(Le.URL,s.request.requestUrl)})}`)),s.request.redirects.length>0&&l.reportError(z.NETWORK_ERROR,` ${Yl(e,{label:"Request Redirects",value:jl(Le.NO_HINT,Kx(e,s.request.redirects,Le.URL))})}`),s.request.retryCount===s.request.options.retry.limit&&l.reportError(z.NETWORK_ERROR,` ${Yl(e,{label:"Request Retry Count",value:jl(Le.NO_HINT,`${Ve(e,s.request.retryCount,Le.NUMBER)} (can be increased via ${Ve(e,"httpRetry",Le.SETTING)})`)})}`)});throw a.originalError=s,a}}function Z8(t,e){let r=[...e.configuration.get("networkSettings")].sort(([o],[a])=>a.length-o.length),i={enableNetwork:void 0,caFilePath:void 0,httpProxy:void 0,httpsProxy:void 0},n=Object.keys(i),s=typeof t=="string"?new Vy.URL(t):t;for(let[o,a]of r)if(tP.default.isMatch(s.hostname,o))for(let l of n){let c=a.get(l);c!==null&&typeof i[l]=="undefined"&&(i[l]=c)}for(let o of n)typeof i[o]=="undefined"&&(i[o]=e.configuration.get(o));return i}var Jl;(function(n){n.GET="GET",n.PUT="PUT",n.POST="POST",n.DELETE="DELETE"})(Jl||(Jl={}));async function xp(t,e,{configuration:r,headers:i,jsonRequest:n,jsonResponse:s,method:o=Jl.GET}){let a=typeof t=="string"?new Vy.URL(t):t,l=Z8(a,{configuration:r});if(l.enableNetwork===!1)throw new Error(`Request to '${a.href}' has been blocked because of your configuration settings`);if(a.protocol==="http:"&&!tP.default.isMatch(a.hostname,r.get("unsafeHttpWhitelist")))throw new Error(`Unsafe http requests must be explicitly whitelisted in your configuration (${a.hostname})`);let u={agent:{http:l.httpProxy?rP.default.httpOverHttp(X8(l.httpProxy)):lxe,https:l.httpsProxy?rP.default.httpsOverHttp(X8(l.httpsProxy)):cxe},headers:i,method:o};u.responseType=s?"json":"buffer",e!==null&&(Buffer.isBuffer(e)||!n&&typeof e=="string"?u.body=e:u.json=e);let g=r.get("httpTimeout"),f=r.get("httpRetry"),h=r.get("enableStrictSsl"),p=l.caFilePath,{default:d}=await Promise.resolve().then(()=>ie(zy())),m=p?await uxe(p):void 0,I=d.extend(P({timeout:{socket:g},retry:f,https:{rejectUnauthorized:h,certificateAuthority:m}},u));return r.getLimit("networkConcurrency")(()=>I(a))}async function fxe(t,n){var s=n,{configuration:e,jsonResponse:r}=s,i=qr(s,["configuration","jsonResponse"]);let o=na(V8,t,()=>_y(xp(t,null,P({configuration:e},i)),{configuration:e}).then(a=>(V8.set(t,a.body),a.body)));return Buffer.isBuffer(o)===!1&&(o=await o),r?JSON.parse(o.toString()):o}async function hxe(t,e,n){var s=n,{customErrorMessage:r}=s,i=qr(s,["customErrorMessage"]);return(await _y(xp(t,e,_(P({},i),{method:Jl.PUT})),i)).body}async function iP(t,e,n){var s=n,{customErrorMessage:r}=s,i=qr(s,["customErrorMessage"]);return(await _y(xp(t,e,_(P({},i),{method:Jl.POST})),i)).body}async function pxe(t,i){var n=i,{customErrorMessage:e}=n,r=qr(n,["customErrorMessage"]);return(await _y(xp(t,null,_(P({},r),{method:Jl.DELETE})),r)).body}var Kt={};it(Kt,{PackageManager:()=>tn,detectPackageManager:()=>a9,executePackageAccessibleBinary:()=>g9,executePackageScript:()=>Uw,executePackageShellcode:()=>rD,executeWorkspaceAccessibleBinary:()=>qFe,executeWorkspaceLifecycleScript:()=>u9,executeWorkspaceScript:()=>c9,getPackageAccessibleBinaries:()=>Hw,getWorkspaceAccessibleBinaries:()=>l9,hasPackageScript:()=>GFe,hasWorkspaceScript:()=>tD,makeScriptEnv:()=>Vp,maybeExecuteWorkspaceLifecycleScript:()=>YFe,prepareExternalProject:()=>HFe});var Fp={};it(Fp,{getLibzipPromise:()=>$i,getLibzipSync:()=>v4});var yA=["number","number"],nP;(function(D){D[D.ZIP_ER_OK=0]="ZIP_ER_OK",D[D.ZIP_ER_MULTIDISK=1]="ZIP_ER_MULTIDISK",D[D.ZIP_ER_RENAME=2]="ZIP_ER_RENAME",D[D.ZIP_ER_CLOSE=3]="ZIP_ER_CLOSE",D[D.ZIP_ER_SEEK=4]="ZIP_ER_SEEK",D[D.ZIP_ER_READ=5]="ZIP_ER_READ",D[D.ZIP_ER_WRITE=6]="ZIP_ER_WRITE",D[D.ZIP_ER_CRC=7]="ZIP_ER_CRC",D[D.ZIP_ER_ZIPCLOSED=8]="ZIP_ER_ZIPCLOSED",D[D.ZIP_ER_NOENT=9]="ZIP_ER_NOENT",D[D.ZIP_ER_EXISTS=10]="ZIP_ER_EXISTS",D[D.ZIP_ER_OPEN=11]="ZIP_ER_OPEN",D[D.ZIP_ER_TMPOPEN=12]="ZIP_ER_TMPOPEN",D[D.ZIP_ER_ZLIB=13]="ZIP_ER_ZLIB",D[D.ZIP_ER_MEMORY=14]="ZIP_ER_MEMORY",D[D.ZIP_ER_CHANGED=15]="ZIP_ER_CHANGED",D[D.ZIP_ER_COMPNOTSUPP=16]="ZIP_ER_COMPNOTSUPP",D[D.ZIP_ER_EOF=17]="ZIP_ER_EOF",D[D.ZIP_ER_INVAL=18]="ZIP_ER_INVAL",D[D.ZIP_ER_NOZIP=19]="ZIP_ER_NOZIP",D[D.ZIP_ER_INTERNAL=20]="ZIP_ER_INTERNAL",D[D.ZIP_ER_INCONS=21]="ZIP_ER_INCONS",D[D.ZIP_ER_REMOVE=22]="ZIP_ER_REMOVE",D[D.ZIP_ER_DELETED=23]="ZIP_ER_DELETED",D[D.ZIP_ER_ENCRNOTSUPP=24]="ZIP_ER_ENCRNOTSUPP",D[D.ZIP_ER_RDONLY=25]="ZIP_ER_RDONLY",D[D.ZIP_ER_NOPASSWD=26]="ZIP_ER_NOPASSWD",D[D.ZIP_ER_WRONGPASSWD=27]="ZIP_ER_WRONGPASSWD",D[D.ZIP_ER_OPNOTSUPP=28]="ZIP_ER_OPNOTSUPP",D[D.ZIP_ER_INUSE=29]="ZIP_ER_INUSE",D[D.ZIP_ER_TELL=30]="ZIP_ER_TELL",D[D.ZIP_ER_COMPRESSED_DATA=31]="ZIP_ER_COMPRESSED_DATA"})(nP||(nP={}));var $8=t=>({get HEAP8(){return t.HEAP8},get HEAPU8(){return t.HEAPU8},errors:nP,SEEK_SET:0,SEEK_CUR:1,SEEK_END:2,ZIP_CHECKCONS:4,ZIP_CREATE:1,ZIP_EXCL:2,ZIP_TRUNCATE:8,ZIP_RDONLY:16,ZIP_FL_OVERWRITE:8192,ZIP_FL_COMPRESSED:4,ZIP_OPSYS_DOS:0,ZIP_OPSYS_AMIGA:1,ZIP_OPSYS_OPENVMS:2,ZIP_OPSYS_UNIX:3,ZIP_OPSYS_VM_CMS:4,ZIP_OPSYS_ATARI_ST:5,ZIP_OPSYS_OS_2:6,ZIP_OPSYS_MACINTOSH:7,ZIP_OPSYS_Z_SYSTEM:8,ZIP_OPSYS_CPM:9,ZIP_OPSYS_WINDOWS_NTFS:10,ZIP_OPSYS_MVS:11,ZIP_OPSYS_VSE:12,ZIP_OPSYS_ACORN_RISC:13,ZIP_OPSYS_VFAT:14,ZIP_OPSYS_ALTERNATE_MVS:15,ZIP_OPSYS_BEOS:16,ZIP_OPSYS_TANDEM:17,ZIP_OPSYS_OS_400:18,ZIP_OPSYS_OS_X:19,ZIP_CM_DEFAULT:-1,ZIP_CM_STORE:0,ZIP_CM_DEFLATE:8,uint08S:t._malloc(1),uint16S:t._malloc(2),uint32S:t._malloc(4),uint64S:t._malloc(8),malloc:t._malloc,free:t._free,getValue:t.getValue,open:t.cwrap("zip_open","number",["string","number","number"]),openFromSource:t.cwrap("zip_open_from_source","number",["number","number","number"]),close:t.cwrap("zip_close","number",["number"]),discard:t.cwrap("zip_discard",null,["number"]),getError:t.cwrap("zip_get_error","number",["number"]),getName:t.cwrap("zip_get_name","string",["number","number","number"]),getNumEntries:t.cwrap("zip_get_num_entries","number",["number","number"]),delete:t.cwrap("zip_delete","number",["number","number"]),stat:t.cwrap("zip_stat","number",["number","string","number","number"]),statIndex:t.cwrap("zip_stat_index","number",["number",...yA,"number","number"]),fopen:t.cwrap("zip_fopen","number",["number","string","number"]),fopenIndex:t.cwrap("zip_fopen_index","number",["number",...yA,"number"]),fread:t.cwrap("zip_fread","number",["number","number","number","number"]),fclose:t.cwrap("zip_fclose","number",["number"]),dir:{add:t.cwrap("zip_dir_add","number",["number","string"])},file:{add:t.cwrap("zip_file_add","number",["number","string","number","number"]),getError:t.cwrap("zip_file_get_error","number",["number"]),getExternalAttributes:t.cwrap("zip_file_get_external_attributes","number",["number",...yA,"number","number","number"]),setExternalAttributes:t.cwrap("zip_file_set_external_attributes","number",["number",...yA,"number","number","number"]),setMtime:t.cwrap("zip_file_set_mtime","number",["number",...yA,"number","number"]),setCompression:t.cwrap("zip_set_file_compression","number",["number",...yA,"number","number"])},ext:{countSymlinks:t.cwrap("zip_ext_count_symlinks","number",["number"])},error:{initWithCode:t.cwrap("zip_error_init_with_code",null,["number","number"]),strerror:t.cwrap("zip_error_strerror","string",["number"])},name:{locate:t.cwrap("zip_name_locate","number",["number","string","number"])},source:{fromUnattachedBuffer:t.cwrap("zip_source_buffer_create","number",["number","number","number","number"]),fromBuffer:t.cwrap("zip_source_buffer","number",["number","number",...yA,"number"]),free:t.cwrap("zip_source_free",null,["number"]),keep:t.cwrap("zip_source_keep",null,["number"]),open:t.cwrap("zip_source_open","number",["number"]),close:t.cwrap("zip_source_close","number",["number"]),seek:t.cwrap("zip_source_seek","number",["number",...yA,"number"]),tell:t.cwrap("zip_source_tell","number",["number"]),read:t.cwrap("zip_source_read","number",["number","number","number"]),error:t.cwrap("zip_source_error","number",["number"]),setMtime:t.cwrap("zip_source_set_mtime","number",["number","number"])},struct:{stat:t.cwrap("zipstruct_stat","number",[]),statS:t.cwrap("zipstruct_statS","number",[]),statName:t.cwrap("zipstruct_stat_name","string",["number"]),statIndex:t.cwrap("zipstruct_stat_index","number",["number"]),statSize:t.cwrap("zipstruct_stat_size","number",["number"]),statCompSize:t.cwrap("zipstruct_stat_comp_size","number",["number"]),statCompMethod:t.cwrap("zipstruct_stat_comp_method","number",["number"]),statMtime:t.cwrap("zipstruct_stat_mtime","number",["number"]),statCrc:t.cwrap("zipstruct_stat_crc","number",["number"]),error:t.cwrap("zipstruct_error","number",[]),errorS:t.cwrap("zipstruct_errorS","number",[]),errorCodeZip:t.cwrap("zipstruct_error_code_zip","number",["number"])}});var BP=null;function v4(){return BP===null&&(BP=$8(b4())),BP}async function $i(){return v4()}var jp={};it(jp,{ShellError:()=>as,execute:()=>Fw,globUtils:()=>bw});var Hp={};it(Hp,{parseResolution:()=>gw,parseShell:()=>Aw,parseSyml:()=>Ii,stringifyArgument:()=>SP,stringifyArgumentSegment:()=>xP,stringifyArithmeticExpression:()=>uw,stringifyCommand:()=>vP,stringifyCommandChain:()=>rg,stringifyCommandChainThen:()=>bP,stringifyCommandLine:()=>lw,stringifyCommandLineThen:()=>QP,stringifyEnvSegment:()=>cw,stringifyRedirectArgument:()=>Np,stringifyResolution:()=>fw,stringifyShell:()=>tg,stringifyShellLine:()=>tg,stringifySyml:()=>Qa,stringifyValueArgument:()=>ig});var k4=ie(x4());function Aw(t,e={isGlobPattern:()=>!1}){try{return(0,k4.parse)(t,e)}catch(r){throw r.location&&(r.message=r.message.replace(/(\.)?$/,` (line ${r.location.start.line}, column ${r.location.start.column})$1`)),r}}function tg(t,{endSemicolon:e=!1}={}){return t.map(({command:r,type:i},n)=>`${lw(r)}${i===";"?n!==t.length-1||e?";":"":" &"}`).join(" ")}function lw(t){return`${rg(t.chain)}${t.then?` ${QP(t.then)}`:""}`}function QP(t){return`${t.type} ${lw(t.line)}`}function rg(t){return`${vP(t)}${t.then?` ${bP(t.then)}`:""}`}function bP(t){return`${t.type} ${rg(t.chain)}`}function vP(t){switch(t.type){case"command":return`${t.envs.length>0?`${t.envs.map(e=>cw(e)).join(" ")} `:""}${t.args.map(e=>SP(e)).join(" ")}`;case"subshell":return`(${tg(t.subshell)})${t.args.length>0?` ${t.args.map(e=>Np(e)).join(" ")}`:""}`;case"group":return`{ ${tg(t.group,{endSemicolon:!0})} }${t.args.length>0?` ${t.args.map(e=>Np(e)).join(" ")}`:""}`;case"envs":return t.envs.map(e=>cw(e)).join(" ");default:throw new Error(`Unsupported command type: "${t.type}"`)}}function cw(t){return`${t.name}=${t.args[0]?ig(t.args[0]):""}`}function SP(t){switch(t.type){case"redirection":return Np(t);case"argument":return ig(t);default:throw new Error(`Unsupported argument type: "${t.type}"`)}}function Np(t){return`${t.subtype} ${t.args.map(e=>ig(e)).join(" ")}`}function ig(t){return t.segments.map(e=>xP(e)).join("")}function xP(t){let e=(i,n)=>n?`"${i}"`:i,r=i=>i===""?'""':i.match(/[(){}<>$|&; \t"']/)?`$'${i.replace(/\\/g,"\\\\").replace(/'/g,"\\'").replace(/\f/g,"\\f").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\t/g,"\\t").replace(/\v/g,"\\v").replace(/\0/g,"\\0")}'`:i;switch(t.type){case"text":return r(t.text);case"glob":return t.pattern;case"shell":return e(`\${${tg(t.shell)}}`,t.quoted);case"variable":return e(typeof t.defaultValue=="undefined"?`\${${t.name}}`:t.defaultValue.length===0?`\${${t.name}:-}`:`\${${t.name}:-${t.defaultValue.map(i=>ig(i)).join(" ")}}`,t.quoted);case"arithmetic":return`$(( ${uw(t.arithmetic)} ))`;default:throw new Error(`Unsupported argument segment type: "${t.type}"`)}}function uw(t){let e=n=>{switch(n){case"addition":return"+";case"subtraction":return"-";case"multiplication":return"*";case"division":return"/";default:throw new Error(`Can't extract operator from arithmetic expression of type "${n}"`)}},r=(n,s)=>s?`( ${n} )`:n,i=n=>r(uw(n),!["number","variable"].includes(n.type));switch(t.type){case"number":return String(t.value);case"variable":return t.name;default:return`${i(t.left)} ${e(t.type)} ${i(t.right)}`}}var R4=ie(D4());function gw(t){let e=t.match(/^\*{1,2}\/(.*)/);if(e)throw new Error(`The override for '${t}' includes a glob pattern. Glob patterns have been removed since their behaviours don't match what you'd expect. Set the override to '${e[1]}' instead.`);try{return(0,R4.parse)(t)}catch(r){throw r.location&&(r.message=r.message.replace(/(\.)?$/,` (line ${r.location.start.line}, column ${r.location.start.column})$1`)),r}}function fw(t){let e="";return t.from&&(e+=t.from.fullName,t.from.description&&(e+=`@${t.from.description}`),e+="/"),e+=t.descriptor.fullName,t.descriptor.description&&(e+=`@${t.descriptor.description}`),e}var Qw=ie(w5()),b5=ie(Q5()),$De=/^(?![-?:,\][{}#&*!|>'"%@` \t\r\n]).([ \t]*(?![,\][{}:# \t\r\n]).)*$/,v5=["__metadata","version","resolution","dependencies","peerDependencies","dependenciesMeta","peerDependenciesMeta","binaries"],HP=class{constructor(e){this.data=e}};function S5(t){return t.match($De)?t:JSON.stringify(t)}function x5(t){return typeof t=="undefined"?!0:typeof t=="object"&&t!==null?Object.keys(t).every(e=>x5(t[e])):!1}function GP(t,e,r){if(t===null)return`null +`;if(typeof t=="number"||typeof t=="boolean")return`${t.toString()} +`;if(typeof t=="string")return`${S5(t)} +`;if(Array.isArray(t)){if(t.length===0)return`[] +`;let i=" ".repeat(e);return` +${t.map(s=>`${i}- ${GP(s,e+1,!1)}`).join("")}`}if(typeof t=="object"&&t){let i,n;t instanceof HP?(i=t.data,n=!1):(i=t,n=!0);let s=" ".repeat(e),o=Object.keys(i);n&&o.sort((l,c)=>{let u=v5.indexOf(l),g=v5.indexOf(c);return u===-1&&g===-1?lc?1:0:u!==-1&&g===-1?-1:u===-1&&g!==-1?1:u-g});let a=o.filter(l=>!x5(i[l])).map((l,c)=>{let u=i[l],g=S5(l),f=GP(u,e+1,!0),h=c>0||r?s:"";return f.startsWith(` +`)?`${h}${g}:${f}`:`${h}${g}: ${f}`}).join(e===0?` +`:"")||` +`;return r?` +${a}`:`${a}`}throw new Error(`Unsupported value type (${t})`)}function Qa(t){try{let e=GP(t,0,!1);return e!==` +`?e:""}catch(e){throw e.location&&(e.message=e.message.replace(/(\.)?$/,` (line ${e.location.start.line}, column ${e.location.start.column})$1`)),e}}Qa.PreserveOrdering=HP;function eRe(t){return t.endsWith(` +`)||(t+=` +`),(0,b5.parse)(t)}var tRe=/^(#.*(\r?\n))*?#\s+yarn\s+lockfile\s+v1\r?\n/i;function rRe(t){if(tRe.test(t))return eRe(t);let e=(0,Qw.safeLoad)(t,{schema:Qw.FAILSAFE_SCHEMA,json:!0});if(e==null)return{};if(typeof e!="object")throw new Error(`Expected an indexed object, got a ${typeof e} instead. Does your file follow Yaml's rules?`);if(Array.isArray(e))throw new Error("Expected an indexed object, got an array instead. Does your file follow Yaml's rules?");return e}function Ii(t){return rRe(t)}var U5=ie(jb()),H5=ie(require("os")),Kn=ie(require("stream")),G5=ie(require("util"));var as=class extends Error{constructor(e){super(e);this.name="ShellError"}};var bw={};it(bw,{fastGlobOptions:()=>D5,isBraceExpansion:()=>R5,isGlobPattern:()=>iRe,match:()=>nRe,micromatchOptions:()=>Sw});var k5=ie(gy()),P5=ie(require("fs")),vw=ie(Nn()),Sw={strictBrackets:!0},D5={onlyDirectories:!1,onlyFiles:!1};function iRe(t){if(!vw.default.scan(t,Sw).isGlob)return!1;try{vw.default.parse(t,Sw)}catch{return!1}return!0}function nRe(t,{cwd:e,baseFs:r}){return(0,k5.default)(t,_(P({},D5),{cwd:M.fromPortablePath(e),fs:SE(P5.default,new ah(r))}))}function R5(t){return vw.default.scan(t,Sw).isBrace}var F5=ie(bb()),Bo=ie(require("stream")),N5=ie(require("string_decoder")),wn;(function(i){i[i.STDIN=0]="STDIN",i[i.STDOUT=1]="STDOUT",i[i.STDERR=2]="STDERR"})(wn||(wn={}));var sc=new Set;function jP(){}function YP(){for(let t of sc)t.kill()}function L5(t,e,r,i){return n=>{let s=n[0]instanceof Bo.Transform?"pipe":n[0],o=n[1]instanceof Bo.Transform?"pipe":n[1],a=n[2]instanceof Bo.Transform?"pipe":n[2],l=(0,F5.default)(t,e,_(P({},i),{stdio:[s,o,a]}));return sc.add(l),sc.size===1&&(process.on("SIGINT",jP),process.on("SIGTERM",YP)),n[0]instanceof Bo.Transform&&n[0].pipe(l.stdin),n[1]instanceof Bo.Transform&&l.stdout.pipe(n[1],{end:!1}),n[2]instanceof Bo.Transform&&l.stderr.pipe(n[2],{end:!1}),{stdin:l.stdin,promise:new Promise(c=>{l.on("error",u=>{switch(sc.delete(l),sc.size===0&&(process.off("SIGINT",jP),process.off("SIGTERM",YP)),u.code){case"ENOENT":n[2].write(`command not found: ${t} +`),c(127);break;case"EACCES":n[2].write(`permission denied: ${t} +`),c(128);break;default:n[2].write(`uncaught error: ${u.message} +`),c(1);break}}),l.on("exit",u=>{sc.delete(l),sc.size===0&&(process.off("SIGINT",jP),process.off("SIGTERM",YP)),c(u!==null?u:129)})})}}}function T5(t){return e=>{let r=e[0]==="pipe"?new Bo.PassThrough:e[0];return{stdin:r,promise:Promise.resolve().then(()=>t({stdin:r,stdout:e[1],stderr:e[2]}))}}}var Os=class{constructor(e){this.stream=e}close(){}get(){return this.stream}},M5=class{constructor(){this.stream=null}close(){if(this.stream===null)throw new Error("Assertion failed: No stream attached");this.stream.end()}attach(e){this.stream=e}get(){if(this.stream===null)throw new Error("Assertion failed: No stream attached");return this.stream}},Gp=class{constructor(e,r){this.stdin=null;this.stdout=null;this.stderr=null;this.pipe=null;this.ancestor=e,this.implementation=r}static start(e,{stdin:r,stdout:i,stderr:n}){let s=new Gp(null,e);return s.stdin=r,s.stdout=i,s.stderr=n,s}pipeTo(e,r=1){let i=new Gp(this,e),n=new M5;return i.pipe=n,i.stdout=this.stdout,i.stderr=this.stderr,(r&1)==1?this.stdout=n:this.ancestor!==null&&(this.stderr=this.ancestor.stdout),(r&2)==2?this.stderr=n:this.ancestor!==null&&(this.stderr=this.ancestor.stderr),i}async exec(){let e=["ignore","ignore","ignore"];if(this.pipe)e[0]="pipe";else{if(this.stdin===null)throw new Error("Assertion failed: No input stream registered");e[0]=this.stdin.get()}let r;if(this.stdout===null)throw new Error("Assertion failed: No output stream registered");r=this.stdout,e[1]=r.get();let i;if(this.stderr===null)throw new Error("Assertion failed: No error stream registered");i=this.stderr,e[2]=i.get();let n=this.implementation(e);return this.pipe&&this.pipe.attach(n.stdin),await n.promise.then(s=>(r.close(),i.close(),s))}async run(){let e=[];for(let i=this;i;i=i.ancestor)e.push(i.exec());return(await Promise.all(e))[0]}};function xw(t,e){return Gp.start(t,e)}function O5(t,e=null){let r=new Bo.PassThrough,i=new N5.StringDecoder,n="";return r.on("data",s=>{let o=i.write(s),a;do if(a=o.indexOf(` +`),a!==-1){let l=n+o.substr(0,a);o=o.substr(a+1),n="",t(e!==null?`${e} ${l}`:l)}while(a!==-1);n+=o}),r.on("end",()=>{let s=i.end();s!==""&&t(e!==null?`${e} ${s}`:s)}),r}function K5(t,{prefix:e}){return{stdout:O5(r=>t.stdout.write(`${r} +`),t.stdout.isTTY?e:null),stderr:O5(r=>t.stderr.write(`${r} +`),t.stderr.isTTY?e:null)}}var sRe=(0,G5.promisify)(setTimeout);var Fi;(function(r){r[r.Readable=1]="Readable",r[r.Writable=2]="Writable"})(Fi||(Fi={}));function j5(t,e,r){let i=new Kn.PassThrough({autoDestroy:!0});switch(t){case wn.STDIN:(e&1)==1&&r.stdin.pipe(i,{end:!1}),(e&2)==2&&r.stdin instanceof Kn.Writable&&i.pipe(r.stdin,{end:!1});break;case wn.STDOUT:(e&1)==1&&r.stdout.pipe(i,{end:!1}),(e&2)==2&&i.pipe(r.stdout,{end:!1});break;case wn.STDERR:(e&1)==1&&r.stderr.pipe(i,{end:!1}),(e&2)==2&&i.pipe(r.stderr,{end:!1});break;default:throw new as(`Bad file descriptor: "${t}"`)}return i}function kw(t,e={}){let r=P(P({},t),e);return r.environment=P(P({},t.environment),e.environment),r.variables=P(P({},t.variables),e.variables),r}var oRe=new Map([["cd",async([t=(0,H5.homedir)(),...e],r,i)=>{let n=v.resolve(i.cwd,M.toPortablePath(t));if(!(await r.baseFs.statPromise(n).catch(o=>{throw o.code==="ENOENT"?new as(`cd: no such file or directory: ${t}`):o})).isDirectory())throw new as(`cd: not a directory: ${t}`);return i.cwd=n,0}],["pwd",async(t,e,r)=>(r.stdout.write(`${M.fromPortablePath(r.cwd)} +`),0)],[":",async(t,e,r)=>0],["true",async(t,e,r)=>0],["false",async(t,e,r)=>1],["exit",async([t,...e],r,i)=>i.exitCode=parseInt(t!=null?t:i.variables["?"],10)],["echo",async(t,e,r)=>(r.stdout.write(`${t.join(" ")} +`),0)],["sleep",async([t],e,r)=>{if(typeof t=="undefined")throw new as("sleep: missing operand");let i=Number(t);if(Number.isNaN(i))throw new as(`sleep: invalid time interval '${t}'`);return await sRe(1e3*i,0)}],["__ysh_run_procedure",async(t,e,r)=>{let i=r.procedures[t[0]];return await xw(i,{stdin:new Os(r.stdin),stdout:new Os(r.stdout),stderr:new Os(r.stderr)}).run()}],["__ysh_set_redirects",async(t,e,r)=>{let i=r.stdin,n=r.stdout,s=r.stderr,o=[],a=[],l=[],c=0;for(;t[c]!=="--";){let g=t[c++],{type:f,fd:h}=JSON.parse(g),p=B=>{switch(h){case null:case 0:o.push(B);break;default:throw new Error(`Unsupported file descriptor: "${h}"`)}},d=B=>{switch(h){case null:case 1:a.push(B);break;case 2:l.push(B);break;default:throw new Error(`Unsupported file descriptor: "${h}"`)}},m=Number(t[c++]),I=c+m;for(let B=c;Be.baseFs.createReadStream(v.resolve(r.cwd,M.toPortablePath(t[B]))));break;case"<<<":p(()=>{let b=new Kn.PassThrough;return process.nextTick(()=>{b.write(`${t[B]} +`),b.end()}),b});break;case"<&":p(()=>j5(Number(t[B]),1,r));break;case">":case">>":{let b=v.resolve(r.cwd,M.toPortablePath(t[B]));d(b==="/dev/null"?new Kn.Writable({autoDestroy:!0,emitClose:!0,write(R,H,L){setImmediate(L)}}):e.baseFs.createWriteStream(b,f===">>"?{flags:"a"}:void 0))}break;case">&":d(j5(Number(t[B]),2,r));break;default:throw new Error(`Assertion failed: Unsupported redirection type: "${f}"`)}}if(o.length>0){let g=new Kn.PassThrough;i=g;let f=h=>{if(h===o.length)g.end();else{let p=o[h]();p.pipe(g,{end:!1}),p.on("end",()=>{f(h+1)})}};f(0)}if(a.length>0){let g=new Kn.PassThrough;n=g;for(let f of a)g.pipe(f)}if(l.length>0){let g=new Kn.PassThrough;s=g;for(let f of l)g.pipe(f)}let u=await xw(Yp(t.slice(c+1),e,r),{stdin:new Os(i),stdout:new Os(n),stderr:new Os(s)}).run();return await Promise.all(a.map(g=>new Promise((f,h)=>{g.on("error",p=>{h(p)}),g.on("close",()=>{f()}),g.end()}))),await Promise.all(l.map(g=>new Promise((f,h)=>{g.on("error",p=>{h(p)}),g.on("close",()=>{f()}),g.end()}))),u}]]);async function aRe(t,e,r){let i=[],n=new Kn.PassThrough;return n.on("data",s=>i.push(s)),await Pw(t,e,kw(r,{stdout:n})),Buffer.concat(i).toString().replace(/[\r\n]+$/,"")}async function Y5(t,e,r){let i=t.map(async s=>{let o=await oc(s.args,e,r);return{name:s.name,value:o.join(" ")}});return(await Promise.all(i)).reduce((s,o)=>(s[o.name]=o.value,s),{})}function Dw(t){return t.match(/[^ \r\n\t]+/g)||[]}async function q5(t,e,r,i,n=i){switch(t.name){case"$":i(String(process.pid));break;case"#":i(String(e.args.length));break;case"@":if(t.quoted)for(let s of e.args)n(s);else for(let s of e.args){let o=Dw(s);for(let a=0;a=0&&st+e,subtraction:(t,e)=>t-e,multiplication:(t,e)=>t*e,division:(t,e)=>Math.trunc(t/e)};async function qp(t,e,r){if(t.type==="number"){if(Number.isInteger(t.value))return t.value;throw new Error(`Invalid number: "${t.value}", only integers are allowed`)}else if(t.type==="variable"){let i=[];await q5(_(P({},t),{quoted:!0}),e,r,s=>i.push(s));let n=Number(i.join(" "));return Number.isNaN(n)?qp({type:"variable",name:i.join(" ")},e,r):qp({type:"number",value:n},e,r)}else return ARe[t.type](await qp(t.left,e,r),await qp(t.right,e,r))}async function oc(t,e,r){let i=new Map,n=[],s=[],o=u=>{s.push(u)},a=()=>{s.length>0&&n.push(s.join("")),s=[]},l=u=>{o(u),a()},c=(u,g,f)=>{let h=JSON.stringify({type:u,fd:g}),p=i.get(h);typeof p=="undefined"&&i.set(h,p=[]),p.push(f)};for(let u of t){let g=!1;switch(u.type){case"redirection":{let f=await oc(u.args,e,r);for(let h of f)c(u.subtype,u.fd,h)}break;case"argument":for(let f of u.segments)switch(f.type){case"text":o(f.text);break;case"glob":o(f.pattern),g=!0;break;case"shell":{let h=await aRe(f.shell,e,r);if(f.quoted)o(h);else{let p=Dw(h);for(let d=0;d0){let u=[];for(let[g,f]of i.entries())u.splice(u.length,0,g,String(f.length),...f);n.splice(0,0,"__ysh_set_redirects",...u,"--")}return n}function Yp(t,e,r){e.builtins.has(t[0])||(t=["command",...t]);let i=M.fromPortablePath(r.cwd),n=r.environment;typeof n.PWD!="undefined"&&(n=_(P({},n),{PWD:i}));let[s,...o]=t;if(s==="command")return L5(o[0],o.slice(1),e,{cwd:i,env:n});let a=e.builtins.get(s);if(typeof a=="undefined")throw new Error(`Assertion failed: A builtin should exist for "${s}"`);return T5(async({stdin:l,stdout:c,stderr:u})=>{let{stdin:g,stdout:f,stderr:h}=r;r.stdin=l,r.stdout=c,r.stderr=u;try{return await a(o,e,r)}finally{r.stdin=g,r.stdout=f,r.stderr=h}})}function lRe(t,e,r){return i=>{let n=new Kn.PassThrough,s=Pw(t,e,kw(r,{stdin:n}));return{stdin:n,promise:s}}}function cRe(t,e,r){return i=>{let n=new Kn.PassThrough,s=Pw(t,e,r);return{stdin:n,promise:s}}}function J5(t,e,r,i){if(e.length===0)return t;{let n;do n=String(Math.random());while(Object.prototype.hasOwnProperty.call(i.procedures,n));return i.procedures=P({},i.procedures),i.procedures[n]=t,Yp([...e,"__ysh_run_procedure",n],r,i)}}async function W5(t,e,r){let i=t,n=null,s=null;for(;i;){let o=i.then?P({},r):r,a;switch(i.type){case"command":{let l=await oc(i.args,e,r),c=await Y5(i.envs,e,r);a=i.envs.length?Yp(l,e,kw(o,{environment:c})):Yp(l,e,o)}break;case"subshell":{let l=await oc(i.args,e,r),c=lRe(i.subshell,e,o);a=J5(c,l,e,o)}break;case"group":{let l=await oc(i.args,e,r),c=cRe(i.group,e,o);a=J5(c,l,e,o)}break;case"envs":{let l=await Y5(i.envs,e,r);o.environment=P(P({},o.environment),l),a=Yp(["true"],e,o)}break}if(typeof a=="undefined")throw new Error("Assertion failed: An action should have been generated");if(n===null)s=xw(a,{stdin:new Os(o.stdin),stdout:new Os(o.stdout),stderr:new Os(o.stderr)});else{if(s===null)throw new Error("Assertion failed: The execution pipeline should have been setup");switch(n){case"|":s=s.pipeTo(a,wn.STDOUT);break;case"|&":s=s.pipeTo(a,wn.STDOUT|wn.STDERR);break}}i.then?(n=i.then.type,i=i.then.chain):i=null}if(s===null)throw new Error("Assertion failed: The execution pipeline should have been setup");return await s.run()}async function uRe(t,e,r,{background:i=!1}={}){function n(s){let o=["#2E86AB","#A23B72","#F18F01","#C73E1D","#CCE2A3"],a=o[s%o.length];return U5.default.hex(a)}if(i){let s=r.nextBackgroundJobIndex++,o=n(s),a=`[${s}]`,l=o(a),{stdout:c,stderr:u}=K5(r,{prefix:l});return r.backgroundJobs.push(W5(t,e,kw(r,{stdout:c,stderr:u})).catch(g=>u.write(`${g.message} +`)).finally(()=>{r.stdout.isTTY&&r.stdout.write(`Job ${l}, '${o(rg(t))}' has ended +`)})),0}return await W5(t,e,r)}async function gRe(t,e,r,{background:i=!1}={}){let n,s=a=>{n=a,r.variables["?"]=String(a)},o=async a=>{try{return await uRe(a.chain,e,r,{background:i&&typeof a.then=="undefined"})}catch(l){if(!(l instanceof as))throw l;return r.stderr.write(`${l.message} +`),1}};for(s(await o(t));t.then;){if(r.exitCode!==null)return r.exitCode;switch(t.then.type){case"&&":n===0&&s(await o(t.then.line));break;case"||":n!==0&&s(await o(t.then.line));break;default:throw new Error(`Assertion failed: Unsupported command type: "${t.then.type}"`)}t=t.then.line}return n}async function Pw(t,e,r){let i=r.backgroundJobs;r.backgroundJobs=[];let n=0;for(let{command:s,type:o}of t){if(n=await gRe(s,e,r,{background:o==="&"}),r.exitCode!==null)return r.exitCode;r.variables["?"]=String(n)}return await Promise.all(r.backgroundJobs),r.backgroundJobs=i,n}function z5(t){switch(t.type){case"variable":return t.name==="@"||t.name==="#"||t.name==="*"||Number.isFinite(parseInt(t.name,10))||"defaultValue"in t&&!!t.defaultValue&&t.defaultValue.some(e=>Rw(e));case"arithmetic":return qP(t.arithmetic);case"shell":return JP(t.shell);default:return!1}}function Rw(t){switch(t.type){case"redirection":return t.args.some(e=>Rw(e));case"argument":return t.segments.some(e=>z5(e));default:throw new Error(`Assertion failed: Unsupported argument type: "${t.type}"`)}}function qP(t){switch(t.type){case"variable":return z5(t);case"number":return!1;default:return qP(t.left)||qP(t.right)}}function JP(t){return t.some(({command:e})=>{for(;e;){let r=e.chain;for(;r;){let i;switch(r.type){case"subshell":i=JP(r.subshell);break;case"command":i=r.envs.some(n=>n.args.some(s=>Rw(s)))||r.args.some(n=>Rw(n));break}if(i)return!0;if(!r.then)break;r=r.then.chain}if(!e.then)break;e=e.then.line}return!1})}async function Fw(t,e=[],{baseFs:r=new Wt,builtins:i={},cwd:n=M.toPortablePath(process.cwd()),env:s=process.env,stdin:o=process.stdin,stdout:a=process.stdout,stderr:l=process.stderr,variables:c={},glob:u=bw}={}){let g={};for(let[p,d]of Object.entries(s))typeof d!="undefined"&&(g[p]=d);let f=new Map(oRe);for(let[p,d]of Object.entries(i))f.set(p,d);o===null&&(o=new Kn.PassThrough,o.end());let h=Aw(t,u);if(!JP(h)&&h.length>0&&e.length>0){let{command:p}=h[h.length-1];for(;p.then;)p=p.then.line;let d=p.chain;for(;d.then;)d=d.then.chain;d.type==="command"&&(d.args=d.args.concat(e.map(m=>({type:"argument",segments:[{type:"text",text:m}]}))))}return await Pw(h,{args:e,baseFs:r,builtins:f,initialStdin:o,initialStdout:a,initialStderr:l,glob:u},{cwd:n,environment:g,exitCode:null,procedures:{},stdin:o,stdout:a,stderr:l,variables:Object.assign({},c,{["?"]:0}),nextBackgroundJobIndex:1,backgroundJobs:[]})}var s9=ie(ZP()),o9=ie(Wp()),cc=ie(require("stream"));var J6=ie(Or());var zp=class{supportsDescriptor(e,r){return!!(e.range.startsWith(zp.protocol)||r.project.tryWorkspaceByDescriptor(e)!==null)}supportsLocator(e,r){return!!e.reference.startsWith(zp.protocol)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){return[i.project.getWorkspaceByDescriptor(e).anchoredLocator]}async getSatisfying(e,r,i){return null}async resolve(e,r){let i=r.project.getWorkspaceByCwd(e.reference.slice(zp.protocol.length));return _(P({},e),{version:i.manifest.version||"0.0.0",languageName:"unknown",linkType:gt.SOFT,conditions:null,dependencies:new Map([...i.manifest.dependencies,...i.manifest.devDependencies]),peerDependencies:new Map([...i.manifest.peerDependencies]),dependenciesMeta:i.manifest.dependenciesMeta,peerDependenciesMeta:i.manifest.peerDependenciesMeta,bin:i.manifest.bin})}},Yr=zp;Yr.protocol="workspace:";var qt={};it(qt,{SemVer:()=>j6.SemVer,satisfiesWithPrereleases:()=>lc,validRange:()=>Us});var Lw=ie(Or()),j6=ie(Or()),Y6=new Map;function lc(t,e,r=!1){if(!t)return!1;let i=`${e}${r}`,n=Y6.get(i);if(typeof n=="undefined")try{n=new Lw.default.Range(e,{includePrerelease:!0,loose:r})}catch{return!1}finally{Y6.set(i,n||null)}else if(n===null)return!1;let s;try{s=new Lw.default.SemVer(t,n)}catch(o){return!1}return n.test(s)?!0:(s.prerelease&&(s.prerelease=[]),n.set.some(o=>{for(let a of o)a.semver.prerelease&&(a.semver.prerelease=[]);return o.every(a=>a.test(s))}))}var q6=new Map;function Us(t){if(t.indexOf(":")!==-1)return null;let e=q6.get(t);if(typeof e!="undefined")return e;try{e=new Lw.default.Range(t)}catch{e=null}return q6.set(t,e),e}var vA=class{constructor(){this.indent=" ";this.name=null;this.version=null;this.os=null;this.cpu=null;this.type=null;this.packageManager=null;this.private=!1;this.license=null;this.main=null;this.module=null;this.browser=null;this.languageName=null;this.bin=new Map;this.scripts=new Map;this.dependencies=new Map;this.devDependencies=new Map;this.peerDependencies=new Map;this.workspaceDefinitions=[];this.dependenciesMeta=new Map;this.peerDependenciesMeta=new Map;this.resolutions=[];this.files=null;this.publishConfig=null;this.installConfig=null;this.preferUnplugged=null;this.raw={};this.errors=[]}static async tryFind(e,{baseFs:r=new Wt}={}){let i=v.join(e,"package.json");return await r.existsPromise(i)?await vA.fromFile(i,{baseFs:r}):null}static async find(e,{baseFs:r}={}){let i=await vA.tryFind(e,{baseFs:r});if(i===null)throw new Error("Manifest not found");return i}static async fromFile(e,{baseFs:r=new Wt}={}){let i=new vA;return await i.loadFile(e,{baseFs:r}),i}static fromText(e){let r=new vA;return r.loadFromText(e),r}static isManifestFieldCompatible(e,r){if(e===null)return!0;let i=!0,n=!1;for(let s of e)if(s[0]==="!"){if(n=!0,r===s.slice(1))return!1}else if(i=!1,s===r)return!0;return n&&i}loadFromText(e){let r;try{r=JSON.parse(z6(e)||"{}")}catch(i){throw i.message+=` (when parsing ${e})`,i}this.load(r),this.indent=W6(e)}async loadFile(e,{baseFs:r=new Wt}){let i=await r.readFilePromise(e,"utf8"),n;try{n=JSON.parse(z6(i)||"{}")}catch(s){throw s.message+=` (when parsing ${e})`,s}this.load(n),this.indent=W6(i)}load(e,{yamlCompatibilityMode:r=!1}={}){if(typeof e!="object"||e===null)throw new Error(`Utterly invalid manifest data (${e})`);this.raw=e;let i=[];if(this.name=null,typeof e.name=="string")try{this.name=En(e.name)}catch(s){i.push(new Error("Parsing failed for the 'name' field"))}if(typeof e.version=="string"?this.version=e.version:this.version=null,Array.isArray(e.os)){let s=[];this.os=s;for(let o of e.os)typeof o!="string"?i.push(new Error("Parsing failed for the 'os' field")):s.push(o)}else this.os=null;if(Array.isArray(e.cpu)){let s=[];this.cpu=s;for(let o of e.cpu)typeof o!="string"?i.push(new Error("Parsing failed for the 'cpu' field")):s.push(o)}else this.cpu=null;if(typeof e.type=="string"?this.type=e.type:this.type=null,typeof e.packageManager=="string"?this.packageManager=e.packageManager:this.packageManager=null,typeof e.private=="boolean"?this.private=e.private:this.private=!1,typeof e.license=="string"?this.license=e.license:this.license=null,typeof e.languageName=="string"?this.languageName=e.languageName:this.languageName=null,typeof e.main=="string"?this.main=en(e.main):this.main=null,typeof e.module=="string"?this.module=en(e.module):this.module=null,e.browser!=null)if(typeof e.browser=="string")this.browser=en(e.browser);else{this.browser=new Map;for(let[s,o]of Object.entries(e.browser))this.browser.set(en(s),typeof o=="string"?en(o):o)}else this.browser=null;if(this.bin=new Map,typeof e.bin=="string")this.name!==null?this.bin.set(this.name.name,en(e.bin)):i.push(new Error("String bin field, but no attached package name"));else if(typeof e.bin=="object"&&e.bin!==null)for(let[s,o]of Object.entries(e.bin)){if(typeof o!="string"){i.push(new Error(`Invalid bin definition for '${s}'`));continue}this.bin.set(s,en(o))}if(this.scripts=new Map,typeof e.scripts=="object"&&e.scripts!==null)for(let[s,o]of Object.entries(e.scripts)){if(typeof o!="string"){i.push(new Error(`Invalid script definition for '${s}'`));continue}this.scripts.set(s,o)}if(this.dependencies=new Map,typeof e.dependencies=="object"&&e.dependencies!==null)for(let[s,o]of Object.entries(e.dependencies)){if(typeof o!="string"){i.push(new Error(`Invalid dependency range for '${s}'`));continue}let a;try{a=En(s)}catch(c){i.push(new Error(`Parsing failed for the dependency name '${s}'`));continue}let l=Yt(a,o);this.dependencies.set(l.identHash,l)}if(this.devDependencies=new Map,typeof e.devDependencies=="object"&&e.devDependencies!==null)for(let[s,o]of Object.entries(e.devDependencies)){if(typeof o!="string"){i.push(new Error(`Invalid dependency range for '${s}'`));continue}let a;try{a=En(s)}catch(c){i.push(new Error(`Parsing failed for the dependency name '${s}'`));continue}let l=Yt(a,o);this.devDependencies.set(l.identHash,l)}if(this.peerDependencies=new Map,typeof e.peerDependencies=="object"&&e.peerDependencies!==null)for(let[s,o]of Object.entries(e.peerDependencies)){let a;try{a=En(s)}catch(c){i.push(new Error(`Parsing failed for the dependency name '${s}'`));continue}(typeof o!="string"||!o.startsWith(Yr.protocol)&&!Us(o))&&(i.push(new Error(`Invalid dependency range for '${s}'`)),o="*");let l=Yt(a,o);this.peerDependencies.set(l.identHash,l)}typeof e.workspaces=="object"&&e.workspaces.nohoist&&i.push(new Error("'nohoist' is deprecated, please use 'installConfig.hoistingLimits' instead"));let n=Array.isArray(e.workspaces)?e.workspaces:typeof e.workspaces=="object"&&e.workspaces!==null&&Array.isArray(e.workspaces.packages)?e.workspaces.packages:[];this.workspaceDefinitions=[];for(let s of n){if(typeof s!="string"){i.push(new Error(`Invalid workspace definition for '${s}'`));continue}this.workspaceDefinitions.push({pattern:s})}if(this.dependenciesMeta=new Map,typeof e.dependenciesMeta=="object"&&e.dependenciesMeta!==null)for(let[s,o]of Object.entries(e.dependenciesMeta)){if(typeof o!="object"||o===null){i.push(new Error(`Invalid meta field for '${s}`));continue}let a=pA(s),l=this.ensureDependencyMeta(a),c=Tw(o.built,{yamlCompatibilityMode:r});if(c===null){i.push(new Error(`Invalid built meta field for '${s}'`));continue}let u=Tw(o.optional,{yamlCompatibilityMode:r});if(u===null){i.push(new Error(`Invalid optional meta field for '${s}'`));continue}let g=Tw(o.unplugged,{yamlCompatibilityMode:r});if(g===null){i.push(new Error(`Invalid unplugged meta field for '${s}'`));continue}Object.assign(l,{built:c,optional:u,unplugged:g})}if(this.peerDependenciesMeta=new Map,typeof e.peerDependenciesMeta=="object"&&e.peerDependenciesMeta!==null)for(let[s,o]of Object.entries(e.peerDependenciesMeta)){if(typeof o!="object"||o===null){i.push(new Error(`Invalid meta field for '${s}'`));continue}let a=pA(s),l=this.ensurePeerDependencyMeta(a),c=Tw(o.optional,{yamlCompatibilityMode:r});if(c===null){i.push(new Error(`Invalid optional meta field for '${s}'`));continue}Object.assign(l,{optional:c})}if(this.resolutions=[],typeof e.resolutions=="object"&&e.resolutions!==null)for(let[s,o]of Object.entries(e.resolutions)){if(typeof o!="string"){i.push(new Error(`Invalid resolution entry for '${s}'`));continue}try{this.resolutions.push({pattern:gw(s),reference:o})}catch(a){i.push(a);continue}}if(Array.isArray(e.files)){this.files=new Set;for(let s of e.files){if(typeof s!="string"){i.push(new Error(`Invalid files entry for '${s}'`));continue}this.files.add(s)}}else this.files=null;if(typeof e.publishConfig=="object"&&e.publishConfig!==null){if(this.publishConfig={},typeof e.publishConfig.access=="string"&&(this.publishConfig.access=e.publishConfig.access),typeof e.publishConfig.main=="string"&&(this.publishConfig.main=en(e.publishConfig.main)),typeof e.publishConfig.module=="string"&&(this.publishConfig.module=en(e.publishConfig.module)),e.publishConfig.browser!=null)if(typeof e.publishConfig.browser=="string")this.publishConfig.browser=en(e.publishConfig.browser);else{this.publishConfig.browser=new Map;for(let[s,o]of Object.entries(e.publishConfig.browser))this.publishConfig.browser.set(en(s),typeof o=="string"?en(o):o)}if(typeof e.publishConfig.registry=="string"&&(this.publishConfig.registry=e.publishConfig.registry),typeof e.publishConfig.bin=="string")this.name!==null?this.publishConfig.bin=new Map([[this.name.name,en(e.publishConfig.bin)]]):i.push(new Error("String bin field, but no attached package name"));else if(typeof e.publishConfig.bin=="object"&&e.publishConfig.bin!==null){this.publishConfig.bin=new Map;for(let[s,o]of Object.entries(e.publishConfig.bin)){if(typeof o!="string"){i.push(new Error(`Invalid bin definition for '${s}'`));continue}this.publishConfig.bin.set(s,en(o))}}if(Array.isArray(e.publishConfig.executableFiles)){this.publishConfig.executableFiles=new Set;for(let s of e.publishConfig.executableFiles){if(typeof s!="string"){i.push(new Error("Invalid executable file definition"));continue}this.publishConfig.executableFiles.add(en(s))}}}else this.publishConfig=null;if(typeof e.installConfig=="object"&&e.installConfig!==null){this.installConfig={};for(let s of Object.keys(e.installConfig))s==="hoistingLimits"?typeof e.installConfig.hoistingLimits=="string"?this.installConfig.hoistingLimits=e.installConfig.hoistingLimits:i.push(new Error("Invalid hoisting limits definition")):s=="selfReferences"?typeof e.installConfig.selfReferences=="boolean"?this.installConfig.selfReferences=e.installConfig.selfReferences:i.push(new Error("Invalid selfReferences definition, must be a boolean value")):i.push(new Error(`Unrecognized installConfig key: ${s}`))}else this.installConfig=null;if(typeof e.optionalDependencies=="object"&&e.optionalDependencies!==null)for(let[s,o]of Object.entries(e.optionalDependencies)){if(typeof o!="string"){i.push(new Error(`Invalid dependency range for '${s}'`));continue}let a;try{a=En(s)}catch(g){i.push(new Error(`Parsing failed for the dependency name '${s}'`));continue}let l=Yt(a,o);this.dependencies.set(l.identHash,l);let c=Yt(a,"unknown"),u=this.ensureDependencyMeta(c);Object.assign(u,{optional:!0})}typeof e.preferUnplugged=="boolean"?this.preferUnplugged=e.preferUnplugged:this.preferUnplugged=null,this.errors=i}getForScope(e){switch(e){case"dependencies":return this.dependencies;case"devDependencies":return this.devDependencies;case"peerDependencies":return this.peerDependencies;default:throw new Error(`Unsupported value ("${e}")`)}}hasConsumerDependency(e){return!!(this.dependencies.has(e.identHash)||this.peerDependencies.has(e.identHash))}hasHardDependency(e){return!!(this.dependencies.has(e.identHash)||this.devDependencies.has(e.identHash))}hasSoftDependency(e){return!!this.peerDependencies.has(e.identHash)}hasDependency(e){return!!(this.hasHardDependency(e)||this.hasSoftDependency(e))}getConditions(){let e=[];return this.os&&this.os.length>0&&e.push(V6("os",this.os)),this.cpu&&this.cpu.length>0&&e.push(V6("cpu",this.cpu)),e.length>0?e.join(" & "):null}isCompatibleWithOS(e){return vA.isManifestFieldCompatible(this.os,e)}isCompatibleWithCPU(e){return vA.isManifestFieldCompatible(this.cpu,e)}ensureDependencyMeta(e){if(e.range!=="unknown"&&!J6.default.valid(e.range))throw new Error(`Invalid meta field range for '${In(e)}'`);let r=St(e),i=e.range!=="unknown"?e.range:null,n=this.dependenciesMeta.get(r);n||this.dependenciesMeta.set(r,n=new Map);let s=n.get(i);return s||n.set(i,s={}),s}ensurePeerDependencyMeta(e){if(e.range!=="unknown")throw new Error(`Invalid meta field range for '${In(e)}'`);let r=St(e),i=this.peerDependenciesMeta.get(r);return i||this.peerDependenciesMeta.set(r,i={}),i}setRawField(e,r,{after:i=[]}={}){let n=new Set(i.filter(s=>Object.prototype.hasOwnProperty.call(this.raw,s)));if(n.size===0||Object.prototype.hasOwnProperty.call(this.raw,e))this.raw[e]=r;else{let s=this.raw,o=this.raw={},a=!1;for(let l of Object.keys(s))o[l]=s[l],a||(n.delete(l),n.size===0&&(o[e]=r,a=!0))}}exportTo(e,{compatibilityMode:r=!0}={}){var s;if(Object.assign(e,this.raw),this.name!==null?e.name=St(this.name):delete e.name,this.version!==null?e.version=this.version:delete e.version,this.os!==null?e.os=this.os:delete e.os,this.cpu!==null?e.cpu=this.cpu:delete e.cpu,this.type!==null?e.type=this.type:delete e.type,this.packageManager!==null?e.packageManager=this.packageManager:delete e.packageManager,this.private?e.private=!0:delete e.private,this.license!==null?e.license=this.license:delete e.license,this.languageName!==null?e.languageName=this.languageName:delete e.languageName,this.main!==null?e.main=this.main:delete e.main,this.module!==null?e.module=this.module:delete e.module,this.browser!==null){let o=this.browser;typeof o=="string"?e.browser=o:o instanceof Map&&(e.browser=Object.assign({},...Array.from(o.keys()).sort().map(a=>({[a]:o.get(a)}))))}else delete e.browser;this.bin.size===1&&this.name!==null&&this.bin.has(this.name.name)?e.bin=this.bin.get(this.name.name):this.bin.size>0?e.bin=Object.assign({},...Array.from(this.bin.keys()).sort().map(o=>({[o]:this.bin.get(o)}))):delete e.bin,this.workspaceDefinitions.length>0?this.raw.workspaces&&!Array.isArray(this.raw.workspaces)?e.workspaces=_(P({},this.raw.workspaces),{packages:this.workspaceDefinitions.map(({pattern:o})=>o)}):e.workspaces=this.workspaceDefinitions.map(({pattern:o})=>o):this.raw.workspaces&&!Array.isArray(this.raw.workspaces)&&Object.keys(this.raw.workspaces).length>0?e.workspaces=this.raw.workspaces:delete e.workspaces;let i=[],n=[];for(let o of this.dependencies.values()){let a=this.dependenciesMeta.get(St(o)),l=!1;if(r&&a){let c=a.get(null);c&&c.optional&&(l=!0)}l?n.push(o):i.push(o)}i.length>0?e.dependencies=Object.assign({},...Ou(i).map(o=>({[St(o)]:o.range}))):delete e.dependencies,n.length>0?e.optionalDependencies=Object.assign({},...Ou(n).map(o=>({[St(o)]:o.range}))):delete e.optionalDependencies,this.devDependencies.size>0?e.devDependencies=Object.assign({},...Ou(this.devDependencies.values()).map(o=>({[St(o)]:o.range}))):delete e.devDependencies,this.peerDependencies.size>0?e.peerDependencies=Object.assign({},...Ou(this.peerDependencies.values()).map(o=>({[St(o)]:o.range}))):delete e.peerDependencies,e.dependenciesMeta={};for(let[o,a]of gn(this.dependenciesMeta.entries(),([l,c])=>l))for(let[l,c]of gn(a.entries(),([u,g])=>u!==null?`0${u}`:"1")){let u=l!==null?In(Yt(En(o),l)):o,g=P({},c);r&&l===null&&delete g.optional,Object.keys(g).length!==0&&(e.dependenciesMeta[u]=g)}if(Object.keys(e.dependenciesMeta).length===0&&delete e.dependenciesMeta,this.peerDependenciesMeta.size>0?e.peerDependenciesMeta=Object.assign({},...gn(this.peerDependenciesMeta.entries(),([o,a])=>o).map(([o,a])=>({[o]:a}))):delete e.peerDependenciesMeta,this.resolutions.length>0?e.resolutions=Object.assign({},...this.resolutions.map(({pattern:o,reference:a})=>({[fw(o)]:a}))):delete e.resolutions,this.files!==null?e.files=Array.from(this.files):delete e.files,this.preferUnplugged!==null?e.preferUnplugged=this.preferUnplugged:delete e.preferUnplugged,this.scripts!==null&&this.scripts.size>0){(s=e.scripts)!=null||(e.scripts={});for(let o of Object.keys(e.scripts))this.scripts.has(o)||delete e.scripts[o];for(let[o,a]of this.scripts.entries())e.scripts[o]=a}else delete e.scripts;return e}},Ze=vA;Ze.fileName="package.json",Ze.allDependencies=["dependencies","devDependencies","peerDependencies"],Ze.hardDependencies=["dependencies","devDependencies"];function W6(t){let e=t.match(/^[ \t]+/m);return e?e[0]:" "}function z6(t){return t.charCodeAt(0)===65279?t.slice(1):t}function en(t){return t.replace(/\\/g,"/")}function Tw(t,{yamlCompatibilityMode:e}){return e?Kv(t):typeof t=="undefined"||typeof t=="boolean"?t:null}function _6(t,e){let r=e.search(/[^!]/);if(r===-1)return"invalid";let i=r%2==0?"":"!",n=e.slice(r);return`${i}${t}=${n}`}function V6(t,e){return e.length===1?_6(t,e[0]):`(${e.map(r=>_6(t,r)).join(" | ")})`}var e9=ie($6()),Ow=ie(ml());var t9=["\u280B","\u2819","\u2839","\u2838","\u283C","\u2834","\u2826","\u2827","\u2807","\u280F"],r9=80,NFe=new Set([z.FETCH_NOT_CACHED,z.UNUSED_CACHE_ENTRY]),LFe=5,SA=Ow.default.GITHUB_ACTIONS?{start:t=>`::group::${t} +`,end:t=>`::endgroup:: +`}:Ow.default.TRAVIS?{start:t=>`travis_fold:start:${t} +`,end:t=>`travis_fold:end:${t} +`}:Ow.default.GITLAB?{start:t=>`section_start:${Math.floor(Date.now()/1e3)}:${t.toLowerCase().replace(/\W+/g,"_")}[collapsed=true]\r${t} +`,end:t=>`section_end:${Math.floor(Date.now()/1e3)}:${t.toLowerCase().replace(/\W+/g,"_")}\r`}:null,i9=new Date,TFe=["iTerm.app","Apple_Terminal"].includes(process.env.TERM_PROGRAM)||!!process.env.WT_SESSION,MFe=t=>t,Kw=MFe({patrick:{date:[17,3],chars:["\u{1F340}","\u{1F331}"],size:40},simba:{date:[19,7],chars:["\u{1F981}","\u{1F334}"],size:40},jack:{date:[31,10],chars:["\u{1F383}","\u{1F987}"],size:40},hogsfather:{date:[31,12],chars:["\u{1F389}","\u{1F384}"],size:40},default:{chars:["=","-"],size:80}}),OFe=TFe&&Object.keys(Kw).find(t=>{let e=Kw[t];return!(e.date&&(e.date[0]!==i9.getDate()||e.date[1]!==i9.getMonth()+1))})||"default";function n9(t,{configuration:e,json:r}){if(!e.get("enableMessageNames"))return"";let n=KE(t===null?0:t);return!r&&t===null?Ve(e,n,"grey"):n}function eD(t,{configuration:e,json:r}){let i=n9(t,{configuration:e,json:r});if(!i||t===null||t===z.UNNAMED)return i;let n=z[t],s=`https://yarnpkg.com/advanced/error-codes#${i}---${n}`.toLowerCase();return Ku(e,i,s)}var Fe=class extends Xi{constructor({configuration:e,stdout:r,json:i=!1,includeFooter:n=!0,includeLogs:s=!i,includeInfos:o=s,includeWarnings:a=s,forgettableBufferSize:l=LFe,forgettableNames:c=new Set}){super();this.uncommitted=new Set;this.cacheHitCount=0;this.cacheMissCount=0;this.lastCacheMiss=null;this.warningCount=0;this.errorCount=0;this.startTime=Date.now();this.indent=0;this.progress=new Map;this.progressTime=0;this.progressFrame=0;this.progressTimeout=null;this.forgettableLines=[];Cp(this,{configuration:e}),this.configuration=e,this.forgettableBufferSize=l,this.forgettableNames=new Set([...c,...NFe]),this.includeFooter=n,this.includeInfos=o,this.includeWarnings=a,this.json=i,this.stdout=r;let u=this.configuration.get("progressBarStyle")||OFe;if(!Object.prototype.hasOwnProperty.call(Kw,u))throw new Error("Assertion failed: Invalid progress bar style");this.progressStyle=Kw[u];let g="\u27A4 YN0000: \u250C ".length,f=Math.max(0,Math.min(process.stdout.columns-g,80));this.progressMaxScaledSize=Math.floor(this.progressStyle.size*f/80)}static async start(e,r){let i=new this(e),n=process.emitWarning;process.emitWarning=(s,o)=>{if(typeof s!="string"){let l=s;s=l.message,o=o!=null?o:l.name}let a=typeof o!="undefined"?`${o}: ${s}`:s;i.reportWarning(z.UNNAMED,a)};try{await r(i)}catch(s){i.reportExceptionOnce(s)}finally{await i.finalize(),process.emitWarning=n}return i}hasErrors(){return this.errorCount>0}exitCode(){return this.hasErrors()?1:0}reportCacheHit(e){this.cacheHitCount+=1}reportCacheMiss(e,r){this.lastCacheMiss=e,this.cacheMissCount+=1,typeof r!="undefined"&&!this.configuration.get("preferAggregateCacheInfo")&&this.reportInfo(z.FETCH_NOT_CACHED,r)}startTimerSync(e,r,i){let n=typeof r=="function"?{}:r,s=typeof r=="function"?r:i,o={committed:!1,action:()=>{this.reportInfo(null,`\u250C ${e}`),this.indent+=1,SA!==null&&!this.json&&this.includeInfos&&this.stdout.write(SA.start(e))}};n.skipIfEmpty?this.uncommitted.add(o):(o.action(),o.committed=!0);let a=Date.now();try{return s()}catch(l){throw this.reportExceptionOnce(l),l}finally{let l=Date.now();this.uncommitted.delete(o),o.committed&&(this.indent-=1,SA!==null&&!this.json&&this.includeInfos&&this.stdout.write(SA.end(e)),this.configuration.get("enableTimers")&&l-a>200?this.reportInfo(null,`\u2514 Completed in ${Ve(this.configuration,l-a,Le.DURATION)}`):this.reportInfo(null,"\u2514 Completed"))}}async startTimerPromise(e,r,i){let n=typeof r=="function"?{}:r,s=typeof r=="function"?r:i,o={committed:!1,action:()=>{this.reportInfo(null,`\u250C ${e}`),this.indent+=1,SA!==null&&!this.json&&this.includeInfos&&this.stdout.write(SA.start(e))}};n.skipIfEmpty?this.uncommitted.add(o):(o.action(),o.committed=!0);let a=Date.now();try{return await s()}catch(l){throw this.reportExceptionOnce(l),l}finally{let l=Date.now();this.uncommitted.delete(o),o.committed&&(this.indent-=1,SA!==null&&!this.json&&this.includeInfos&&this.stdout.write(SA.end(e)),this.configuration.get("enableTimers")&&l-a>200?this.reportInfo(null,`\u2514 Completed in ${Ve(this.configuration,l-a,Le.DURATION)}`):this.reportInfo(null,"\u2514 Completed"))}}async startCacheReport(e){let r=this.configuration.get("preferAggregateCacheInfo")?{cacheHitCount:this.cacheHitCount,cacheMissCount:this.cacheMissCount}:null;try{return await e()}catch(i){throw this.reportExceptionOnce(i),i}finally{r!==null&&this.reportCacheChanges(r)}}reportSeparator(){this.indent===0?this.writeLineWithForgettableReset(""):this.reportInfo(null,"")}reportInfo(e,r){if(!this.includeInfos)return;this.commit();let i=this.formatNameWithHyperlink(e),n=i?`${i}: `:"",s=`${Ve(this.configuration,"\u27A4","blueBright")} ${n}${this.formatIndent()}${r}`;if(this.json)this.reportJson({type:"info",name:e,displayName:this.formatName(e),indent:this.formatIndent(),data:r});else if(this.forgettableNames.has(e))if(this.forgettableLines.push(s),this.forgettableLines.length>this.forgettableBufferSize){for(;this.forgettableLines.length>this.forgettableBufferSize;)this.forgettableLines.shift();this.writeLines(this.forgettableLines,{truncate:!0})}else this.writeLine(s,{truncate:!0});else this.writeLineWithForgettableReset(s)}reportWarning(e,r){if(this.warningCount+=1,!this.includeWarnings)return;this.commit();let i=this.formatNameWithHyperlink(e),n=i?`${i}: `:"";this.json?this.reportJson({type:"warning",name:e,displayName:this.formatName(e),indent:this.formatIndent(),data:r}):this.writeLineWithForgettableReset(`${Ve(this.configuration,"\u27A4","yellowBright")} ${n}${this.formatIndent()}${r}`)}reportError(e,r){this.errorCount+=1,this.commit();let i=this.formatNameWithHyperlink(e),n=i?`${i}: `:"";this.json?this.reportJson({type:"error",name:e,displayName:this.formatName(e),indent:this.formatIndent(),data:r}):this.writeLineWithForgettableReset(`${Ve(this.configuration,"\u27A4","redBright")} ${n}${this.formatIndent()}${r}`,{truncate:!1})}reportProgress(e){let r=!1,i=Promise.resolve().then(async()=>{let s={progress:0,title:void 0};this.progress.set(e,{definition:s,lastScaledSize:-1}),this.refreshProgress(-1);for await(let{progress:o,title:a}of e)r||s.progress===o&&s.title===a||(s.progress=o,s.title=a,this.refreshProgress());n()}),n=()=>{r||(r=!0,this.progress.delete(e),this.refreshProgress(1))};return _(P({},i),{stop:n})}reportJson(e){this.json&&this.writeLineWithForgettableReset(`${JSON.stringify(e)}`)}async finalize(){if(!this.includeFooter)return;let e="";this.errorCount>0?e="Failed with errors":this.warningCount>0?e="Done with warnings":e="Done";let r=Ve(this.configuration,Date.now()-this.startTime,Le.DURATION),i=this.configuration.get("enableTimers")?`${e} in ${r}`:e;this.errorCount>0?this.reportError(z.UNNAMED,i):this.warningCount>0?this.reportWarning(z.UNNAMED,i):this.reportInfo(z.UNNAMED,i)}writeLine(e,{truncate:r}={}){this.clearProgress({clear:!0}),this.stdout.write(`${this.truncate(e,{truncate:r})} +`),this.writeProgress()}writeLineWithForgettableReset(e,{truncate:r}={}){this.forgettableLines=[],this.writeLine(e,{truncate:r})}writeLines(e,{truncate:r}={}){this.clearProgress({delta:e.length});for(let i of e)this.stdout.write(`${this.truncate(i,{truncate:r})} +`);this.writeProgress()}reportCacheChanges({cacheHitCount:e,cacheMissCount:r}){let i=this.cacheHitCount-e,n=this.cacheMissCount-r;if(i===0&&n===0)return;let s="";this.cacheHitCount>1?s+=`${this.cacheHitCount} packages were already cached`:this.cacheHitCount===1?s+=" - one package was already cached":s+="No packages were cached",this.cacheHitCount>0?this.cacheMissCount>1?s+=`, ${this.cacheMissCount} had to be fetched`:this.cacheMissCount===1&&(s+=`, one had to be fetched (${lt(this.configuration,this.lastCacheMiss)})`):this.cacheMissCount>1?s+=` - ${this.cacheMissCount} packages had to be fetched`:this.cacheMissCount===1&&(s+=` - one package had to be fetched (${lt(this.configuration,this.lastCacheMiss)})`),this.reportInfo(z.FETCH_NOT_CACHED,s)}commit(){let e=this.uncommitted;this.uncommitted=new Set;for(let r of e)r.committed=!0,r.action()}clearProgress({delta:e=0,clear:r=!1}){!this.configuration.get("enableProgressBars")||this.json||this.progress.size+e>0&&(this.stdout.write(`[${this.progress.size+e}A`),(e>0||r)&&this.stdout.write(""))}writeProgress(){if(!this.configuration.get("enableProgressBars")||this.json||(this.progressTimeout!==null&&clearTimeout(this.progressTimeout),this.progressTimeout=null,this.progress.size===0))return;let e=Date.now();e-this.progressTime>r9&&(this.progressFrame=(this.progressFrame+1)%t9.length,this.progressTime=e);let r=t9[this.progressFrame];for(let i of this.progress.values()){let n=this.progressStyle.chars[0].repeat(i.lastScaledSize),s=this.progressStyle.chars[1].repeat(this.progressMaxScaledSize-i.lastScaledSize),o=this.formatName(null),a=o?`${o}: `:"";this.stdout.write(`${Ve(this.configuration,"\u27A4","blueBright")} ${a}${r} ${n}${s} +`)}this.progressTimeout=setTimeout(()=>{this.refreshProgress()},r9)}refreshProgress(e=0){let r=!1;if(this.progress.size===0)r=!0;else for(let i of this.progress.values()){let n=Math.trunc(this.progressMaxScaledSize*i.definition.progress),s=i.lastScaledSize;if(i.lastScaledSize=n,n!==s){r=!0;break}}r&&(this.clearProgress({delta:e}),this.writeProgress())}truncate(e,{truncate:r}={}){return this.configuration.get("enableProgressBars")||(r=!1),typeof r=="undefined"&&(r=this.configuration.get("preferTruncatedLines")),r&&(e=(0,e9.default)(e,0,process.stdout.columns-1)),e}formatName(e){return n9(e,{configuration:this.configuration,json:this.json})}formatNameWithHyperlink(e){return eD(e,{configuration:this.configuration,json:this.json})}formatIndent(){return"\u2502 ".repeat(this.indent)}};var Zr="3.1.1";var tn;(function(n){n.Yarn1="Yarn Classic",n.Yarn2="Yarn",n.Npm="npm",n.Pnpm="pnpm"})(tn||(tn={}));async function ba(t,e,r,i=[]){if(process.platform==="win32"){let n=`@goto #_undefined_# 2>NUL || @title %COMSPEC% & @setlocal & @"${r}" ${i.map(s=>`"${s.replace('"','""')}"`).join(" ")} %*`;await T.writeFilePromise(v.format({dir:t,name:e,ext:".cmd"}),n)}await T.writeFilePromise(v.join(t,e),`#!/bin/sh +exec "${r}" ${i.map(n=>`'${n.replace(/'/g,`'"'"'`)}'`).join(" ")} "$@" +`,{mode:493})}async function a9(t){let e=await Ze.tryFind(t);if(e==null?void 0:e.packageManager){let i=Qy(e.packageManager);if(i==null?void 0:i.name){let n=`found ${JSON.stringify({packageManager:e.packageManager})} in manifest`,[s]=i.reference.split(".");switch(i.name){case"yarn":return{packageManager:Number(s)===1?tn.Yarn1:tn.Yarn2,reason:n};case"npm":return{packageManager:tn.Npm,reason:n};case"pnpm":return{packageManager:tn.Pnpm,reason:n}}}}let r;try{r=await T.readFilePromise(v.join(t,wt.lockfile),"utf8")}catch{}return r!==void 0?r.match(/^__metadata:$/m)?{packageManager:tn.Yarn2,reason:'"__metadata" key found in yarn.lock'}:{packageManager:tn.Yarn1,reason:'"__metadata" key not found in yarn.lock, must be a Yarn classic lockfile'}:T.existsSync(v.join(t,"package-lock.json"))?{packageManager:tn.Npm,reason:`found npm's "package-lock.json" lockfile`}:T.existsSync(v.join(t,"pnpm-lock.yaml"))?{packageManager:tn.Pnpm,reason:`found pnpm's "pnpm-lock.yaml" lockfile`}:null}async function Vp({project:t,locator:e,binFolder:r,lifecycleScript:i}){var l,c;let n={};for(let[u,g]of Object.entries(process.env))typeof g!="undefined"&&(n[u.toLowerCase()!=="path"?u:"PATH"]=g);let s=M.fromPortablePath(r);n.BERRY_BIN_FOLDER=M.fromPortablePath(s);let o=process.env.COREPACK_ROOT?M.join(process.env.COREPACK_ROOT,"dist/yarn.js"):process.argv[1];if(await Promise.all([ba(r,"node",process.execPath),...Zr!==null?[ba(r,"run",process.execPath,[o,"run"]),ba(r,"yarn",process.execPath,[o]),ba(r,"yarnpkg",process.execPath,[o]),ba(r,"node-gyp",process.execPath,[o,"run","--top-level","node-gyp"])]:[]]),t&&(n.INIT_CWD=M.fromPortablePath(t.configuration.startingCwd),n.PROJECT_CWD=M.fromPortablePath(t.cwd)),n.PATH=n.PATH?`${s}${M.delimiter}${n.PATH}`:`${s}`,n.npm_execpath=`${s}${M.sep}yarn`,n.npm_node_execpath=`${s}${M.sep}node`,e){if(!t)throw new Error("Assertion failed: Missing project");let u=t.tryWorkspaceByLocator(e),g=u?(l=u.manifest.version)!=null?l:"":(c=t.storedPackages.get(e.locatorHash).version)!=null?c:"";n.npm_package_name=St(e),n.npm_package_version=g}let a=Zr!==null?`yarn/${Zr}`:`yarn/${mu("@yarnpkg/core").version}-core`;return n.npm_config_user_agent=`${a} npm/? node/${process.versions.node} ${process.platform} ${process.arch}`,i&&(n.npm_lifecycle_event=i),t&&await t.configuration.triggerHook(u=>u.setupScriptEnvironment,t,n,async(u,g,f)=>await ba(r,kr(u),g,f)),n}var KFe=2,UFe=(0,o9.default)(KFe);async function HFe(t,e,{configuration:r,report:i,workspace:n=null,locator:s=null}){await UFe(async()=>{await T.mktempPromise(async o=>{let a=v.join(o,"pack.log"),l=null,{stdout:c,stderr:u}=r.getSubprocessStreams(a,{prefix:M.fromPortablePath(t),report:i}),g=s&&Io(s)?lp(s):s,f=g?is(g):"an external project";c.write(`Packing ${f} from sources +`);let h=await a9(t),p;h!==null?(c.write(`Using ${h.packageManager} for bootstrap. Reason: ${h.reason} + +`),p=h.packageManager):(c.write(`No package manager configuration detected; defaulting to Yarn + +`),p=tn.Yarn2),await T.mktempPromise(async d=>{let m=await Vp({binFolder:d}),B=new Map([[tn.Yarn1,async()=>{let R=n!==null?["workspace",n]:[],H=await to("yarn",["set","version","classic","--only-if-needed"],{cwd:t,env:m,stdin:l,stdout:c,stderr:u,end:Pn.ErrorCode});if(H.code!==0)return H.code;await T.appendFilePromise(v.join(t,".npmignore"),`/.yarn +`),c.write(` +`);let L=await to("yarn",["install"],{cwd:t,env:m,stdin:l,stdout:c,stderr:u,end:Pn.ErrorCode});if(L.code!==0)return L.code;c.write(` +`);let K=await to("yarn",[...R,"pack","--filename",M.fromPortablePath(e)],{cwd:t,env:m,stdin:l,stdout:c,stderr:u});return K.code!==0?K.code:0}],[tn.Yarn2,async()=>{let R=n!==null?["workspace",n]:[];m.YARN_ENABLE_INLINE_BUILDS="1";let H=v.join(t,wt.lockfile);await T.existsPromise(H)||await T.writeFilePromise(H,"");let L=await to("yarn",[...R,"pack","--install-if-needed","--filename",M.fromPortablePath(e)],{cwd:t,env:m,stdin:l,stdout:c,stderr:u});return L.code!==0?L.code:0}],[tn.Npm,async()=>{if(n!==null){let A=new cc.PassThrough,V=Cu(A);A.pipe(c,{end:!1});let W=await to("npm",["--version"],{cwd:t,env:m,stdin:l,stdout:A,stderr:u,end:Pn.Never});if(A.end(),W.code!==0)return c.end(),u.end(),W.code;let X=(await V).toString().trim();if(!lc(X,">=7.x")){let F=Eo(null,"npm"),D=Yt(F,X),he=Yt(F,">=7.x");throw new Error(`Workspaces aren't supported by ${Xt(r,D)}; please upgrade to ${Xt(r,he)} (npm has been detected as the primary package manager for ${Ve(r,t,Le.PATH)})`)}}let R=n!==null?["--workspace",n]:[];delete m.npm_config_user_agent;let H=await to("npm",["install"],{cwd:t,env:m,stdin:l,stdout:c,stderr:u,end:Pn.ErrorCode});if(H.code!==0)return H.code;let L=new cc.PassThrough,K=Cu(L);L.pipe(c);let J=await to("npm",["pack","--silent",...R],{cwd:t,env:m,stdin:l,stdout:L,stderr:u});if(J.code!==0)return J.code;let ne=(await K).toString().trim().replace(/^.*\n/s,""),q=v.resolve(t,M.toPortablePath(ne));return await T.renamePromise(q,e),0}]]).get(p);if(typeof B=="undefined")throw new Error("Assertion failed: Unsupported workflow");let b=await B();if(!(b===0||typeof b=="undefined"))throw T.detachTemp(o),new nt(z.PACKAGE_PREPARATION_FAILED,`Packing the package failed (exit code ${b}, logs can be found here: ${Ve(r,a,Le.PATH)})`)})})})}async function GFe(t,e,{project:r}){let i=r.tryWorkspaceByLocator(t);if(i!==null)return tD(i,e);let n=r.storedPackages.get(t.locatorHash);if(!n)throw new Error(`Package for ${lt(r.configuration,t)} not found in the project`);return await Jn.openPromise(async s=>{let o=r.configuration,a=r.configuration.getLinkers(),l={project:r,report:new Fe({stdout:new cc.PassThrough,configuration:o})},c=a.find(h=>h.supportsPackage(n,l));if(!c)throw new Error(`The package ${lt(r.configuration,n)} isn't supported by any of the available linkers`);let u=await c.findPackageLocation(n,l),g=new Ft(u,{baseFs:s});return(await Ze.find(Se.dot,{baseFs:g})).scripts.has(e)},{libzip:await $i()})}async function Uw(t,e,r,{cwd:i,project:n,stdin:s,stdout:o,stderr:a}){return await T.mktempPromise(async l=>{let{manifest:c,env:u,cwd:g}=await A9(t,{project:n,binFolder:l,cwd:i,lifecycleScript:e}),f=c.scripts.get(e);if(typeof f=="undefined")return 1;let h=async()=>await Fw(f,r,{cwd:g,env:u,stdin:s,stdout:o,stderr:a});return await(await n.configuration.reduceHook(d=>d.wrapScriptExecution,h,n,t,e,{script:f,args:r,cwd:g,env:u,stdin:s,stdout:o,stderr:a}))()})}async function rD(t,e,r,{cwd:i,project:n,stdin:s,stdout:o,stderr:a}){return await T.mktempPromise(async l=>{let{env:c,cwd:u}=await A9(t,{project:n,binFolder:l,cwd:i});return await Fw(e,r,{cwd:u,env:c,stdin:s,stdout:o,stderr:a})})}async function jFe(t,{binFolder:e,cwd:r,lifecycleScript:i}){let n=await Vp({project:t.project,locator:t.anchoredLocator,binFolder:e,lifecycleScript:i});return await Promise.all(Array.from(await l9(t),([s,[,o]])=>ba(e,kr(s),process.execPath,[o]))),typeof r=="undefined"&&(r=v.dirname(await T.realpathPromise(v.join(t.cwd,"package.json")))),{manifest:t.manifest,binFolder:e,env:n,cwd:r}}async function A9(t,{project:e,binFolder:r,cwd:i,lifecycleScript:n}){let s=e.tryWorkspaceByLocator(t);if(s!==null)return jFe(s,{binFolder:r,cwd:i,lifecycleScript:n});let o=e.storedPackages.get(t.locatorHash);if(!o)throw new Error(`Package for ${lt(e.configuration,t)} not found in the project`);return await Jn.openPromise(async a=>{let l=e.configuration,c=e.configuration.getLinkers(),u={project:e,report:new Fe({stdout:new cc.PassThrough,configuration:l})},g=c.find(m=>m.supportsPackage(o,u));if(!g)throw new Error(`The package ${lt(e.configuration,o)} isn't supported by any of the available linkers`);let f=await Vp({project:e,locator:t,binFolder:r,lifecycleScript:n});await Promise.all(Array.from(await Hw(t,{project:e}),([m,[,I]])=>ba(r,kr(m),process.execPath,[I])));let h=await g.findPackageLocation(o,u),p=new Ft(h,{baseFs:a}),d=await Ze.find(Se.dot,{baseFs:p});return typeof i=="undefined"&&(i=h),{manifest:d,binFolder:r,env:f,cwd:i}},{libzip:await $i()})}async function c9(t,e,r,{cwd:i,stdin:n,stdout:s,stderr:o}){return await Uw(t.anchoredLocator,e,r,{cwd:i,project:t.project,stdin:n,stdout:s,stderr:o})}function tD(t,e){return t.manifest.scripts.has(e)}async function u9(t,e,{cwd:r,report:i}){let{configuration:n}=t.project,s=null;await T.mktempPromise(async o=>{let a=v.join(o,`${e}.log`),l=`# This file contains the result of Yarn calling the "${e}" lifecycle script inside a workspace ("${M.fromPortablePath(t.cwd)}") +`,{stdout:c,stderr:u}=n.getSubprocessStreams(a,{report:i,prefix:lt(n,t.anchoredLocator),header:l});i.reportInfo(z.LIFECYCLE_SCRIPT,`Calling the "${e}" lifecycle script`);let g=await c9(t,e,[],{cwd:r,stdin:s,stdout:c,stderr:u});if(c.end(),u.end(),g!==0)throw T.detachTemp(o),new nt(z.LIFECYCLE_SCRIPT,`${(0,s9.default)(e)} script failed (exit code ${Ve(n,g,Le.NUMBER)}, logs can be found here: ${Ve(n,a,Le.PATH)}); run ${Ve(n,`yarn ${e}`,Le.CODE)} to investigate`)})}async function YFe(t,e,r){tD(t,e)&&await u9(t,e,r)}async function Hw(t,{project:e}){let r=e.configuration,i=new Map,n=e.storedPackages.get(t.locatorHash);if(!n)throw new Error(`Package for ${lt(r,t)} not found in the project`);let s=new cc.Writable,o=r.getLinkers(),a={project:e,report:new Fe({configuration:r,stdout:s})},l=new Set([t.locatorHash]);for(let u of n.dependencies.values()){let g=e.storedResolutions.get(u.descriptorHash);if(!g)throw new Error(`Assertion failed: The resolution (${Xt(r,u)}) should have been registered`);l.add(g)}let c=await Promise.all(Array.from(l,async u=>{let g=e.storedPackages.get(u);if(!g)throw new Error(`Assertion failed: The package (${u}) should have been registered`);if(g.bin.size===0)return kl.skip;let f=o.find(p=>p.supportsPackage(g,a));if(!f)return kl.skip;let h=null;try{h=await f.findPackageLocation(g,a)}catch(p){if(p.code==="LOCATOR_NOT_INSTALLED")return kl.skip;throw p}return{dependency:g,packageLocation:h}}));for(let u of c){if(u===kl.skip)continue;let{dependency:g,packageLocation:f}=u;for(let[h,p]of g.bin)i.set(h,[g,M.fromPortablePath(v.resolve(f,p))])}return i}async function l9(t){return await Hw(t.anchoredLocator,{project:t.project})}async function g9(t,e,r,{cwd:i,project:n,stdin:s,stdout:o,stderr:a,nodeArgs:l=[],packageAccessibleBinaries:c}){c!=null||(c=await Hw(t,{project:n}));let u=c.get(e);if(!u)throw new Error(`Binary not found (${e}) for ${lt(n.configuration,t)}`);return await T.mktempPromise(async g=>{let[,f]=u,h=await Vp({project:n,locator:t,binFolder:g});await Promise.all(Array.from(c,([d,[,m]])=>ba(h.BERRY_BIN_FOLDER,kr(d),process.execPath,[m])));let p;try{p=await to(process.execPath,[...l,f,...r],{cwd:i,env:h,stdin:s,stdout:o,stderr:a})}finally{await T.removePromise(h.BERRY_BIN_FOLDER)}return p.code})}async function qFe(t,e,r,{cwd:i,stdin:n,stdout:s,stderr:o,packageAccessibleBinaries:a}){return await g9(t.anchoredLocator,e,r,{project:t.project,cwd:i,stdin:n,stdout:s,stderr:o,packageAccessibleBinaries:a})}var Ai={};it(Ai,{convertToZip:()=>lTe,extractArchiveTo:()=>uTe,makeArchiveFromDirectory:()=>ATe});var d_=ie(require("stream")),C_=ie(Z7());var u_=ie(require("os")),g_=ie(c_()),f_=ie(require("worker_threads")),IR=class{constructor(e){this.source=e;this.pool=[];this.queue=new g_.default({concurrency:Math.max(1,(0,u_.cpus)().length)});let r=setTimeout(()=>{if(!(this.queue.size!==0||this.queue.pending!==0)){for(let i of this.pool)i.terminate();this.pool=[]}},1e3).unref();this.queue.on("idle",()=>{r.refresh()})}run(e){return this.queue.add(()=>{var i;let r=(i=this.pool.pop())!=null?i:new f_.Worker(this.source,{eval:!0,execArgv:[...process.execArgv,"--unhandled-rejections=strict"]});return r.ref(),new Promise((n,s)=>{let o=a=>{a!==0&&s(new Error(`Worker exited with code ${a}`))};r.once("message",a=>{this.pool.push(r),r.unref(),r.off("error",s),r.off("exit",o),n(a)}),r.once("error",s),r.once("exit",o),r.postMessage(e)})})}};var m_=ie(p_());async function ATe(t,{baseFs:e=new Wt,prefixPath:r=Se.root,compressionLevel:i,inMemory:n=!1}={}){let s=await $i(),o;if(n)o=new Jr(null,{libzip:s,level:i});else{let l=await T.mktempPromise(),c=v.join(l,"archive.zip");o=new Jr(c,{create:!0,libzip:s,level:i})}let a=v.resolve(Se.root,r);return await o.copyPromise(a,t,{baseFs:e,stableTime:!0,stableSort:!0}),o}var E_;async function lTe(t,e){let r=await T.mktempPromise(),i=v.join(r,"archive.zip");return E_||(E_=new IR((0,m_.getContent)())),await E_.run({tmpFile:i,tgz:t,opts:e}),new Jr(i,{libzip:await $i(),level:e.compressionLevel})}async function*cTe(t){let e=new C_.default.Parse,r=new d_.PassThrough({objectMode:!0,autoDestroy:!0,emitClose:!0});e.on("entry",i=>{r.write(i)}),e.on("error",i=>{r.destroy(i)}),e.on("close",()=>{r.destroyed||r.end()}),e.end(t);for await(let i of r){let n=i;yield n,n.resume()}}async function uTe(t,e,{stripComponents:r=0,prefixPath:i=Se.dot}={}){var s,o;function n(a){if(a.path[0]==="/")return!0;let l=a.path.split(/\//g);return!!(l.some(c=>c==="..")||l.length<=r)}for await(let a of cTe(t)){if(n(a))continue;let l=v.normalize(M.toPortablePath(a.path)).replace(/\/$/,"").split(/\//g);if(l.length<=r)continue;let c=l.slice(r).join("/"),u=v.join(i,c),g=420;switch((a.type==="Directory"||(((s=a.mode)!=null?s:0)&73)!=0)&&(g|=73),a.type){case"Directory":e.mkdirpSync(v.dirname(u),{chmod:493,utimes:[mr.SAFE_TIME,mr.SAFE_TIME]}),e.mkdirSync(u,{mode:g}),e.utimesSync(u,mr.SAFE_TIME,mr.SAFE_TIME);break;case"OldFile":case"File":e.mkdirpSync(v.dirname(u),{chmod:493,utimes:[mr.SAFE_TIME,mr.SAFE_TIME]}),e.writeFileSync(u,await Cu(a),{mode:g}),e.utimesSync(u,mr.SAFE_TIME,mr.SAFE_TIME);break;case"SymbolicLink":e.mkdirpSync(v.dirname(u),{chmod:493,utimes:[mr.SAFE_TIME,mr.SAFE_TIME]}),e.symlinkSync(a.linkpath,u),(o=e.lutimesSync)==null||o.call(e,u,mr.SAFE_TIME,mr.SAFE_TIME);break}}return e}var Hs={};it(Hs,{emitList:()=>gTe,emitTree:()=>b_,treeNodeToJson:()=>Q_,treeNodeToTreeify:()=>B_});var w_=ie(y_());function B_(t,{configuration:e}){let r={},i=(n,s)=>{let o=Array.isArray(n)?n.entries():Object.entries(n);for(let[a,{label:l,value:c,children:u}]of o){let g=[];typeof l!="undefined"&&g.push(Py(e,l,Gl.BOLD)),typeof c!="undefined"&&g.push(Ve(e,c[0],c[1])),g.length===0&&g.push(Py(e,`${a}`,Gl.BOLD));let f=g.join(": "),h=s[f]={};typeof u!="undefined"&&i(u,h)}};if(typeof t.children=="undefined")throw new Error("The root node must only contain children");return i(t.children,r),r}function Q_(t){let e=r=>{var s;if(typeof r.children=="undefined"){if(typeof r.value=="undefined")throw new Error("Assertion failed: Expected a value to be set if the children are missing");return Uu(r.value[0],r.value[1])}let i=Array.isArray(r.children)?r.children.entries():Object.entries((s=r.children)!=null?s:{}),n=Array.isArray(r.children)?[]:{};for(let[o,a]of i)n[o]=e(a);return typeof r.value=="undefined"?n:{value:Uu(r.value[0],r.value[1]),children:n}};return e(t)}function gTe(t,{configuration:e,stdout:r,json:i}){let n=t.map(s=>({value:s}));b_({children:n},{configuration:e,stdout:r,json:i})}function b_(t,{configuration:e,stdout:r,json:i,separators:n=0}){var o;if(i){let a=Array.isArray(t.children)?t.children.values():Object.values((o=t.children)!=null?o:{});for(let l of a)r.write(`${JSON.stringify(Q_(l))} +`);return}let s=(0,w_.asTree)(B_(t,{configuration:e}),!1,!1);if(n>=1&&(s=s.replace(/^([├└]─)/gm,`\u2502 +$1`).replace(/^│\n/,"")),n>=2)for(let a=0;a<2;++a)s=s.replace(/^([│ ].{2}[├│ ].{2}[^\n]+\n)(([│ ]).{2}[├└].{2}[^\n]*\n[│ ].{2}[│ ].{2}[├└]─)/gm,`$1$3 \u2502 +$2`).replace(/^│\n/,"");if(n>=3)throw new Error("Only the first two levels are accepted by treeUtils.emitTree");r.write(s)}var v_=ie(require("crypto")),BR=ie(require("fs"));var fTe=8,Qt=class{constructor(e,{configuration:r,immutable:i=r.get("enableImmutableCache"),check:n=!1}){this.markedFiles=new Set;this.mutexes=new Map;this.cacheId=`-${(0,v_.randomBytes)(8).toString("hex")}.tmp`;this.configuration=r,this.cwd=e,this.immutable=i,this.check=n;let s=r.get("cacheKeyOverride");if(s!==null)this.cacheKey=`${s}`;else{let o=r.get("compressionLevel"),a=o!==pl?`c${o}`:"";this.cacheKey=[fTe,a].join("")}}static async find(e,{immutable:r,check:i}={}){let n=new Qt(e.get("cacheFolder"),{configuration:e,immutable:r,check:i});return await n.setup(),n}get mirrorCwd(){if(!this.configuration.get("enableMirror"))return null;let e=`${this.configuration.get("globalFolder")}/cache`;return e!==this.cwd?e:null}getVersionFilename(e){return`${Mu(e)}-${this.cacheKey}.zip`}getChecksumFilename(e,r){let n=hTe(r).slice(0,10);return`${Mu(e)}-${n}.zip`}getLocatorPath(e,r,i={}){var s;return this.mirrorCwd===null||((s=i.unstablePackages)==null?void 0:s.has(e.locatorHash))?v.resolve(this.cwd,this.getVersionFilename(e)):r===null||QR(r)!==this.cacheKey?null:v.resolve(this.cwd,this.getChecksumFilename(e,r))}getLocatorMirrorPath(e){let r=this.mirrorCwd;return r!==null?v.resolve(r,this.getVersionFilename(e)):null}async setup(){if(!this.configuration.get("enableGlobalCache"))if(this.immutable){if(!await T.existsPromise(this.cwd))throw new nt(z.IMMUTABLE_CACHE,"Cache path does not exist.")}else{await T.mkdirPromise(this.cwd,{recursive:!0});let e=v.resolve(this.cwd,".gitignore");await T.changeFilePromise(e,`/.gitignore +*.flock +*.tmp +`)}(this.mirrorCwd||!this.immutable)&&await T.mkdirPromise(this.mirrorCwd||this.cwd,{recursive:!0})}async fetchPackageFromCache(e,r,a){var l=a,{onHit:i,onMiss:n,loader:s}=l,o=qr(l,["onHit","onMiss","loader"]);var A;let c=this.getLocatorMirrorPath(e),u=new Wt,g=()=>{let V=new Jr(null,{libzip:H}),W=v.join(Se.root,Lx(e));return V.mkdirSync(W,{recursive:!0}),V.writeJsonSync(v.join(W,wt.manifest),{name:St(e),mocked:!0}),V},f=async(V,W=null)=>{let X=!o.skipIntegrityCheck||!r?`${this.cacheKey}/${await Ey(V)}`:r;if(W!==null){let F=!o.skipIntegrityCheck||!r?`${this.cacheKey}/${await Ey(W)}`:r;if(X!==F)throw new nt(z.CACHE_CHECKSUM_MISMATCH,"The remote archive doesn't match the local checksum - has the local cache been corrupted?")}if(r!==null&&X!==r){let F;switch(this.check?F="throw":QR(r)!==QR(X)?F="update":F=this.configuration.get("checksumBehavior"),F){case"ignore":return r;case"update":return X;default:case"throw":throw new nt(z.CACHE_CHECKSUM_MISMATCH,"The remote archive doesn't match the expected checksum")}}return X},h=async V=>{if(!s)throw new Error(`Cache check required but no loader configured for ${lt(this.configuration,e)}`);let W=await s(),X=W.getRealPath();return W.saveAndClose(),await T.chmodPromise(X,420),await f(V,X)},p=async()=>{if(c===null||!await T.existsPromise(c)){let V=await s(),W=V.getRealPath();return V.saveAndClose(),{source:"loader",path:W}}return{source:"mirror",path:c}},d=async()=>{if(!s)throw new Error(`Cache entry required but missing for ${lt(this.configuration,e)}`);if(this.immutable)throw new nt(z.IMMUTABLE_CACHE,`Cache entry required but missing for ${lt(this.configuration,e)}`);let{path:V,source:W}=await p(),X=await f(V),F=this.getLocatorPath(e,X,o);if(!F)throw new Error("Assertion failed: Expected the cache path to be available");let D=[];W!=="mirror"&&c!==null&&D.push(async()=>{let pe=`${c}${this.cacheId}`;await T.copyFilePromise(V,pe,BR.default.constants.COPYFILE_FICLONE),await T.chmodPromise(pe,420),await T.renamePromise(pe,c)}),(!o.mirrorWriteOnly||c===null)&&D.push(async()=>{let pe=`${F}${this.cacheId}`;await T.copyFilePromise(V,pe,BR.default.constants.COPYFILE_FICLONE),await T.chmodPromise(pe,420),await T.renamePromise(pe,F)});let he=o.mirrorWriteOnly&&c!=null?c:F;return await Promise.all(D.map(pe=>pe())),[!1,he,X]},m=async()=>{let W=(async()=>{var Ne;let X=this.getLocatorPath(e,r,o),F=X!==null?await u.existsPromise(X):!1,D=!!((Ne=o.mockedPackages)==null?void 0:Ne.has(e.locatorHash))&&(!this.check||!F),he=D||F,pe=he?i:n;if(pe&&pe(),he){let Pe=null,qe=X;return D||(Pe=this.check?await h(qe):await f(qe)),[D,qe,Pe]}else return d()})();this.mutexes.set(e.locatorHash,W);try{return await W}finally{this.mutexes.delete(e.locatorHash)}};for(let V;V=this.mutexes.get(e.locatorHash);)await V;let[I,B,b]=await m();this.markedFiles.add(B);let R,H=await $i(),L=I?()=>g():()=>new Jr(B,{baseFs:u,libzip:H,readOnly:!0}),K=new oh(()=>Mv(()=>R=L(),V=>`Failed to open the cache entry for ${lt(this.configuration,e)}: ${V}`),v),J=new Xo(B,{baseFs:K,pathUtils:v}),ne=()=>{R==null||R.discardAndClose()},q=((A=o.unstablePackages)==null?void 0:A.has(e.locatorHash))?null:b;return[J,ne,q]}};function QR(t){let e=t.indexOf("/");return e!==-1?t.slice(0,e):null}function hTe(t){let e=t.indexOf("/");return e!==-1?t.slice(e+1):t}var F_=ie(x_()),NB=ie(ml());var N_=ie(Wp()),kR=ie(require("stream"));var k_={hooks:{reduceDependency:(t,e,r,i,{resolver:n,resolveOptions:s})=>{for(let{pattern:o,reference:a}of e.topLevelWorkspace.manifest.resolutions){if(o.from&&o.from.fullName!==St(r)||o.from&&o.from.description&&o.from.description!==r.reference||o.descriptor.fullName!==St(t)||o.descriptor.description&&o.descriptor.description!==t.range)continue;return n.bindDescriptor(Yt(t,a),e.topLevelWorkspace.anchoredLocator,s)}return t},validateProject:async(t,e)=>{for(let r of t.workspaces){let i=hp(t.configuration,r);await t.configuration.triggerHook(n=>n.validateWorkspace,r,{reportWarning:(n,s)=>e.reportWarning(n,`${i}: ${s}`),reportError:(n,s)=>e.reportError(n,`${i}: ${s}`)})}},validateWorkspace:async(t,e)=>{let{manifest:r}=t;r.resolutions.length&&t.cwd!==t.project.cwd&&r.errors.push(new Error("Resolutions field will be ignored"));for(let i of r.errors)e.reportWarning(z.INVALID_MANIFEST,i.message)}}};var vR=class{constructor(e){this.fetchers=e}supports(e,r){return!!this.tryFetcher(e,r)}getLocalPath(e,r){return this.getFetcher(e,r).getLocalPath(e,r)}async fetch(e,r){return await this.getFetcher(e,r).fetch(e,r)}tryFetcher(e,r){let i=this.fetchers.find(n=>n.supports(e,r));return i||null}getFetcher(e,r){let i=this.fetchers.find(n=>n.supports(e,r));if(!i)throw new nt(z.FETCHER_NOT_FOUND,`${lt(r.project.configuration,e)} isn't supported by any available fetcher`);return i}};var pd=class{constructor(e){this.resolvers=e.filter(r=>r)}supportsDescriptor(e,r){return!!this.tryResolverByDescriptor(e,r)}supportsLocator(e,r){return!!this.tryResolverByLocator(e,r)}shouldPersistResolution(e,r){return this.getResolverByLocator(e,r).shouldPersistResolution(e,r)}bindDescriptor(e,r,i){return this.getResolverByDescriptor(e,i).bindDescriptor(e,r,i)}getResolutionDependencies(e,r){return this.getResolverByDescriptor(e,r).getResolutionDependencies(e,r)}async getCandidates(e,r,i){return await this.getResolverByDescriptor(e,i).getCandidates(e,r,i)}async getSatisfying(e,r,i){return this.getResolverByDescriptor(e,i).getSatisfying(e,r,i)}async resolve(e,r){return await this.getResolverByLocator(e,r).resolve(e,r)}tryResolverByDescriptor(e,r){let i=this.resolvers.find(n=>n.supportsDescriptor(e,r));return i||null}getResolverByDescriptor(e,r){let i=this.resolvers.find(n=>n.supportsDescriptor(e,r));if(!i)throw new Error(`${Xt(r.project.configuration,e)} isn't supported by any available resolver`);return i}tryResolverByLocator(e,r){let i=this.resolvers.find(n=>n.supportsLocator(e,r));return i||null}getResolverByLocator(e,r){let i=this.resolvers.find(n=>n.supportsLocator(e,r));if(!i)throw new Error(`${lt(r.project.configuration,e)} isn't supported by any available resolver`);return i}};var P_=ie(Or());var Rg=/^(?!v)[a-z0-9._-]+$/i,SR=class{supportsDescriptor(e,r){return!!(Us(e.range)||Rg.test(e.range))}supportsLocator(e,r){return!!(P_.default.valid(e.reference)||Rg.test(e.reference))}shouldPersistResolution(e,r){return r.resolver.shouldPersistResolution(this.forwardLocator(e,r),r)}bindDescriptor(e,r,i){return i.resolver.bindDescriptor(this.forwardDescriptor(e,i),r,i)}getResolutionDependencies(e,r){return r.resolver.getResolutionDependencies(this.forwardDescriptor(e,r),r)}async getCandidates(e,r,i){return await i.resolver.getCandidates(this.forwardDescriptor(e,i),r,i)}async getSatisfying(e,r,i){return await i.resolver.getSatisfying(this.forwardDescriptor(e,i),r,i)}async resolve(e,r){let i=await r.resolver.resolve(this.forwardLocator(e,r),r);return op(i,e)}forwardDescriptor(e,r){return Yt(e,`${r.project.configuration.get("defaultProtocol")}${e.range}`)}forwardLocator(e,r){return Vi(e,`${r.project.configuration.get("defaultProtocol")}${e.reference}`)}};var dd=class{supports(e){return!!e.reference.startsWith("virtual:")}getLocalPath(e,r){let i=e.reference.indexOf("#");if(i===-1)throw new Error("Invalid virtual package reference");let n=e.reference.slice(i+1),s=Vi(e,n);return r.fetcher.getLocalPath(s,r)}async fetch(e,r){let i=e.reference.indexOf("#");if(i===-1)throw new Error("Invalid virtual package reference");let n=e.reference.slice(i+1),s=Vi(e,n),o=await r.fetcher.fetch(s,r);return await this.ensureVirtualLink(e,o,r)}getLocatorFilename(e){return Mu(e)}async ensureVirtualLink(e,r,i){let n=r.packageFs.getRealPath(),s=i.project.configuration.get("virtualFolder"),o=this.getLocatorFilename(e),a=Pr.makeVirtualPath(s,o,n),l=new Xo(a,{baseFs:r.packageFs,pathUtils:v});return _(P({},r),{packageFs:l})}};var Fg=class{static isVirtualDescriptor(e){return!!e.range.startsWith(Fg.protocol)}static isVirtualLocator(e){return!!e.reference.startsWith(Fg.protocol)}supportsDescriptor(e,r){return Fg.isVirtualDescriptor(e)}supportsLocator(e,r){return Fg.isVirtualLocator(e)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){throw new Error('Assertion failed: calling "bindDescriptor" on a virtual descriptor is unsupported')}getResolutionDependencies(e,r){throw new Error('Assertion failed: calling "getResolutionDependencies" on a virtual descriptor is unsupported')}async getCandidates(e,r,i){throw new Error('Assertion failed: calling "getCandidates" on a virtual descriptor is unsupported')}async getSatisfying(e,r,i){throw new Error('Assertion failed: calling "getSatisfying" on a virtual descriptor is unsupported')}async resolve(e,r){throw new Error('Assertion failed: calling "resolve" on a virtual locator is unsupported')}},FB=Fg;FB.protocol="virtual:";var xR=class{supports(e){return!!e.reference.startsWith(Yr.protocol)}getLocalPath(e,r){return this.getWorkspace(e,r).cwd}async fetch(e,r){let i=this.getWorkspace(e,r).cwd;return{packageFs:new Ft(i),prefixPath:Se.dot,localPath:i}}getWorkspace(e,r){return r.project.getWorkspaceByCwd(e.reference.slice(Yr.protocol.length))}};var D_=ie(require("module"));function R_(){return new Set(D_.default.builtinModules||Object.keys(process.binding("natives")))}var dTe=new Set(["binFolder","version","flags","profile","gpg","ignoreNode","wrapOutput","home","confDir"]),LB="yarn_",PR=".yarnrc.yml",DR="yarn.lock",CTe="********",ge;(function(u){u.ANY="ANY",u.BOOLEAN="BOOLEAN",u.ABSOLUTE_PATH="ABSOLUTE_PATH",u.LOCATOR="LOCATOR",u.LOCATOR_LOOSE="LOCATOR_LOOSE",u.NUMBER="NUMBER",u.STRING="STRING",u.SECRET="SECRET",u.SHAPE="SHAPE",u.MAP="MAP"})(ge||(ge={}));var ps=Le,RR={lastUpdateCheck:{description:"Last timestamp we checked whether new Yarn versions were available",type:ge.STRING,default:null},yarnPath:{description:"Path to the local executable that must be used over the global one",type:ge.ABSOLUTE_PATH,default:null},ignorePath:{description:"If true, the local executable will be ignored when using the global one",type:ge.BOOLEAN,default:!1},ignoreCwd:{description:"If true, the `--cwd` flag will be ignored",type:ge.BOOLEAN,default:!1},cacheKeyOverride:{description:"A global cache key override; used only for test purposes",type:ge.STRING,default:null},globalFolder:{description:"Folder where are stored the system-wide settings",type:ge.ABSOLUTE_PATH,default:Rb()},cacheFolder:{description:"Folder where the cache files must be written",type:ge.ABSOLUTE_PATH,default:"./.yarn/cache"},compressionLevel:{description:"Zip files compression level, from 0 to 9 or mixed (a variant of 9, which stores some files uncompressed, when compression doesn't yield good results)",type:ge.NUMBER,values:["mixed",0,1,2,3,4,5,6,7,8,9],default:pl},virtualFolder:{description:"Folder where the virtual packages (cf doc) will be mapped on the disk (must be named __virtual__)",type:ge.ABSOLUTE_PATH,default:"./.yarn/__virtual__"},lockfileFilename:{description:"Name of the files where the Yarn dependency tree entries must be stored",type:ge.STRING,default:DR},installStatePath:{description:"Path of the file where the install state will be persisted",type:ge.ABSOLUTE_PATH,default:"./.yarn/install-state.gz"},immutablePatterns:{description:"Array of glob patterns; files matching them won't be allowed to change during immutable installs",type:ge.STRING,default:[],isArray:!0},rcFilename:{description:"Name of the files where the configuration can be found",type:ge.STRING,default:TB()},enableGlobalCache:{description:"If true, the system-wide cache folder will be used regardless of `cache-folder`",type:ge.BOOLEAN,default:!1},enableColors:{description:"If true, the CLI is allowed to use colors in its output",type:ge.BOOLEAN,default:xy,defaultText:""},enableHyperlinks:{description:"If true, the CLI is allowed to use hyperlinks in its output",type:ge.BOOLEAN,default:Mx,defaultText:""},enableInlineBuilds:{description:"If true, the CLI will print the build output on the command line",type:ge.BOOLEAN,default:NB.isCI,defaultText:""},enableMessageNames:{description:"If true, the CLI will prefix most messages with codes suitable for search engines",type:ge.BOOLEAN,default:!0},enableProgressBars:{description:"If true, the CLI is allowed to show a progress bar for long-running events",type:ge.BOOLEAN,default:!NB.isCI&&process.stdout.isTTY&&process.stdout.columns>22,defaultText:""},enableTimers:{description:"If true, the CLI is allowed to print the time spent executing commands",type:ge.BOOLEAN,default:!0},preferAggregateCacheInfo:{description:"If true, the CLI will only print a one-line report of any cache changes",type:ge.BOOLEAN,default:NB.isCI},preferInteractive:{description:"If true, the CLI will automatically use the interactive mode when called from a TTY",type:ge.BOOLEAN,default:!1},preferTruncatedLines:{description:"If true, the CLI will truncate lines that would go beyond the size of the terminal",type:ge.BOOLEAN,default:!1},progressBarStyle:{description:"Which style of progress bar should be used (only when progress bars are enabled)",type:ge.STRING,default:void 0,defaultText:""},defaultLanguageName:{description:"Default language mode that should be used when a package doesn't offer any insight",type:ge.STRING,default:"node"},defaultProtocol:{description:"Default resolution protocol used when resolving pure semver and tag ranges",type:ge.STRING,default:"npm:"},enableTransparentWorkspaces:{description:"If false, Yarn won't automatically resolve workspace dependencies unless they use the `workspace:` protocol",type:ge.BOOLEAN,default:!0},supportedArchitectures:{description:"Architectures that Yarn will fetch and inject into the resolver",type:ge.SHAPE,properties:{os:{description:"Array of supported process.platform strings, or null to target them all",type:ge.STRING,isArray:!0,isNullable:!0,default:["current"]},cpu:{description:"Array of supported process.arch strings, or null to target them all",type:ge.STRING,isArray:!0,isNullable:!0,default:["current"]}}},enableMirror:{description:"If true, the downloaded packages will be retrieved and stored in both the local and global folders",type:ge.BOOLEAN,default:!0},enableNetwork:{description:"If false, the package manager will refuse to use the network if required to",type:ge.BOOLEAN,default:!0},httpProxy:{description:"URL of the http proxy that must be used for outgoing http requests",type:ge.STRING,default:null},httpsProxy:{description:"URL of the http proxy that must be used for outgoing https requests",type:ge.STRING,default:null},unsafeHttpWhitelist:{description:"List of the hostnames for which http queries are allowed (glob patterns are supported)",type:ge.STRING,default:[],isArray:!0},httpTimeout:{description:"Timeout of each http request in milliseconds",type:ge.NUMBER,default:6e4},httpRetry:{description:"Retry times on http failure",type:ge.NUMBER,default:3},networkConcurrency:{description:"Maximal number of concurrent requests",type:ge.NUMBER,default:50},networkSettings:{description:"Network settings per hostname (glob patterns are supported)",type:ge.MAP,valueDefinition:{description:"",type:ge.SHAPE,properties:{caFilePath:{description:"Path to file containing one or multiple Certificate Authority signing certificates",type:ge.ABSOLUTE_PATH,default:null},enableNetwork:{description:"If false, the package manager will refuse to use the network if required to",type:ge.BOOLEAN,default:null},httpProxy:{description:"URL of the http proxy that must be used for outgoing http requests",type:ge.STRING,default:null},httpsProxy:{description:"URL of the http proxy that must be used for outgoing https requests",type:ge.STRING,default:null}}}},caFilePath:{description:"A path to a file containing one or multiple Certificate Authority signing certificates",type:ge.ABSOLUTE_PATH,default:null},enableStrictSsl:{description:"If false, SSL certificate errors will be ignored",type:ge.BOOLEAN,default:!0},logFilters:{description:"Overrides for log levels",type:ge.SHAPE,isArray:!0,concatenateValues:!0,properties:{code:{description:"Code of the messages covered by this override",type:ge.STRING,default:void 0},text:{description:"Code of the texts covered by this override",type:ge.STRING,default:void 0},pattern:{description:"Code of the patterns covered by this override",type:ge.STRING,default:void 0},level:{description:"Log level override, set to null to remove override",type:ge.STRING,values:Object.values(Ts),isNullable:!0,default:void 0}}},enableTelemetry:{description:"If true, telemetry will be periodically sent, following the rules in https://yarnpkg.com/advanced/telemetry",type:ge.BOOLEAN,default:!0},telemetryInterval:{description:"Minimal amount of time between two telemetry uploads, in days",type:ge.NUMBER,default:7},telemetryUserId:{description:"If you desire to tell us which project you are, you can set this field. Completely optional and opt-in.",type:ge.STRING,default:null},enableScripts:{description:"If true, packages are allowed to have install scripts by default",type:ge.BOOLEAN,default:!0},enableStrictSettings:{description:"If true, unknown settings will cause Yarn to abort",type:ge.BOOLEAN,default:!0},enableImmutableCache:{description:"If true, the cache is reputed immutable and actions that would modify it will throw",type:ge.BOOLEAN,default:!1},checksumBehavior:{description:"Enumeration defining what to do when a checksum doesn't match expectations",type:ge.STRING,default:"throw"},packageExtensions:{description:"Map of package corrections to apply on the dependency tree",type:ge.MAP,valueDefinition:{description:"The extension that will be applied to any package whose version matches the specified range",type:ge.SHAPE,properties:{dependencies:{description:"The set of dependencies that must be made available to the current package in order for it to work properly",type:ge.MAP,valueDefinition:{description:"A range",type:ge.STRING}},peerDependencies:{description:"Inherited dependencies - the consumer of the package will be tasked to provide them",type:ge.MAP,valueDefinition:{description:"A semver range",type:ge.STRING}},peerDependenciesMeta:{description:"Extra information related to the dependencies listed in the peerDependencies field",type:ge.MAP,valueDefinition:{description:"The peerDependency meta",type:ge.SHAPE,properties:{optional:{description:"If true, the selected peer dependency will be marked as optional by the package manager and the consumer omitting it won't be reported as an error",type:ge.BOOLEAN,default:!1}}}}}}}};function NR(t,e,r,i,n){if(i.isArray||i.type===ge.ANY&&Array.isArray(r))return Array.isArray(r)?r.map((s,o)=>FR(t,`${e}[${o}]`,s,i,n)):String(r).split(/,/).map(s=>FR(t,e,s,i,n));if(Array.isArray(r))throw new Error(`Non-array configuration settings "${e}" cannot be an array`);return FR(t,e,r,i,n)}function FR(t,e,r,i,n){var a;switch(i.type){case ge.ANY:return r;case ge.SHAPE:return mTe(t,e,r,i,n);case ge.MAP:return ETe(t,e,r,i,n)}if(r===null&&!i.isNullable&&i.default!==null)throw new Error(`Non-nullable configuration settings "${e}" cannot be set to null`);if((a=i.values)==null?void 0:a.includes(r))return r;let o=(()=>{if(i.type===ge.BOOLEAN&&typeof r!="string")return Hh(r);if(typeof r!="string")throw new Error(`Expected value (${r}) to be a string`);let l=Ov(r,{env:process.env});switch(i.type){case ge.ABSOLUTE_PATH:return v.resolve(n,M.toPortablePath(l));case ge.LOCATOR_LOOSE:return Hl(l,!1);case ge.NUMBER:return parseInt(l);case ge.LOCATOR:return Hl(l);case ge.BOOLEAN:return Hh(l);default:return l}})();if(i.values&&!i.values.includes(o))throw new Error(`Invalid value, expected one of ${i.values.join(", ")}`);return o}function mTe(t,e,r,i,n){if(typeof r!="object"||Array.isArray(r))throw new me(`Object configuration settings "${e}" must be an object`);let s=LR(t,i,{ignoreArrays:!0});if(r===null)return s;for(let[o,a]of Object.entries(r)){let l=`${e}.${o}`;if(!i.properties[o])throw new me(`Unrecognized configuration settings found: ${e}.${o} - run "yarn config -v" to see the list of settings supported in Yarn`);s.set(o,NR(t,l,a,i.properties[o],n))}return s}function ETe(t,e,r,i,n){let s=new Map;if(typeof r!="object"||Array.isArray(r))throw new me(`Map configuration settings "${e}" must be an object`);if(r===null)return s;for(let[o,a]of Object.entries(r)){let l=i.normalizeKeys?i.normalizeKeys(o):o,c=`${e}['${l}']`,u=i.valueDefinition;s.set(l,NR(t,c,a,u,n))}return s}function LR(t,e,{ignoreArrays:r=!1}={}){switch(e.type){case ge.SHAPE:{if(e.isArray&&!r)return[];let i=new Map;for(let[n,s]of Object.entries(e.properties))i.set(n,LR(t,s));return i}break;case ge.MAP:return e.isArray&&!r?[]:new Map;case ge.ABSOLUTE_PATH:return e.default===null?null:t.projectCwd===null?v.isAbsolute(e.default)?v.normalize(e.default):e.isNullable?null:void 0:Array.isArray(e.default)?e.default.map(i=>v.resolve(t.projectCwd,i)):v.resolve(t.projectCwd,e.default);default:return e.default}}function MB(t,e,r){if(e.type===ge.SECRET&&typeof t=="string"&&r.hideSecrets)return CTe;if(e.type===ge.ABSOLUTE_PATH&&typeof t=="string"&&r.getNativePaths)return M.fromPortablePath(t);if(e.isArray&&Array.isArray(t)){let i=[];for(let n of t)i.push(MB(n,e,r));return i}if(e.type===ge.MAP&&t instanceof Map){let i=new Map;for(let[n,s]of t.entries())i.set(n,MB(s,e.valueDefinition,r));return i}if(e.type===ge.SHAPE&&t instanceof Map){let i=new Map;for(let[n,s]of t.entries()){let o=e.properties[n];i.set(n,MB(s,o,r))}return i}return t}function ITe(){let t={};for(let[e,r]of Object.entries(process.env))e=e.toLowerCase(),!!e.startsWith(LB)&&(e=(0,F_.default)(e.slice(LB.length)),t[e]=r);return t}function TB(){let t=`${LB}rc_filename`;for(let[e,r]of Object.entries(process.env))if(e.toLowerCase()===t&&typeof r=="string")return r;return PR}var KA;(function(i){i[i.LOCKFILE=0]="LOCKFILE",i[i.MANIFEST=1]="MANIFEST",i[i.NONE=2]="NONE"})(KA||(KA={}));var Ra=class{constructor(e){this.projectCwd=null;this.plugins=new Map;this.settings=new Map;this.values=new Map;this.sources=new Map;this.invalid=new Map;this.packageExtensions=new Map;this.limits=new Map;this.startingCwd=e}static create(e,r,i){let n=new Ra(e);typeof r!="undefined"&&!(r instanceof Map)&&(n.projectCwd=r),n.importSettings(RR);let s=typeof i!="undefined"?i:r instanceof Map?r:new Map;for(let[o,a]of s)n.activatePlugin(o,a);return n}static async find(e,r,{lookup:i=0,strict:n=!0,usePath:s=!1,useRc:o=!0}={}){let a=ITe();delete a.rcFilename;let l=await Ra.findRcFiles(e),c=await Ra.findHomeRcFile();if(c){let I=l.find(B=>B.path===c.path);I?I.strict=!1:l.push(_(P({},c),{strict:!1}))}let u=({ignoreCwd:I,yarnPath:B,ignorePath:b,lockfileFilename:R})=>({ignoreCwd:I,yarnPath:B,ignorePath:b,lockfileFilename:R}),g=L=>{var K=L,{ignoreCwd:I,yarnPath:B,ignorePath:b,lockfileFilename:R}=K,H=qr(K,["ignoreCwd","yarnPath","ignorePath","lockfileFilename"]);return H},f=new Ra(e);f.importSettings(u(RR)),f.useWithSource("",u(a),e,{strict:!1});for(let{path:I,cwd:B,data:b}of l)f.useWithSource(I,u(b),B,{strict:!1});if(s){let I=f.get("yarnPath"),B=f.get("ignorePath");if(I!==null&&!B)return f}let h=f.get("lockfileFilename"),p;switch(i){case 0:p=await Ra.findProjectCwd(e,h);break;case 1:p=await Ra.findProjectCwd(e,null);break;case 2:T.existsSync(v.join(e,"package.json"))?p=v.resolve(e):p=null;break}f.startingCwd=e,f.projectCwd=p,f.importSettings(g(RR));let d=new Map([["@@core",k_]]),m=I=>"default"in I?I.default:I;if(r!==null){for(let R of r.plugins.keys())d.set(R,m(r.modules.get(R)));let I=new Map;for(let R of R_())I.set(R,()=>mu(R));for(let[R,H]of r.modules)I.set(R,()=>H);let B=new Set,b=async(R,H)=>{let{factory:L,name:K}=mu(R);if(B.has(K))return;let J=new Map(I),ne=A=>{if(J.has(A))return J.get(A)();throw new me(`This plugin cannot access the package referenced via ${A} which is neither a builtin, nor an exposed entry`)},q=await du(async()=>m(await L(ne)),A=>`${A} (when initializing ${K}, defined in ${H})`);I.set(K,()=>q),B.add(K),d.set(K,q)};if(a.plugins)for(let R of a.plugins.split(";")){let H=v.resolve(e,M.toPortablePath(R));await b(H,"")}for(let{path:R,cwd:H,data:L}of l)if(!!o&&!!Array.isArray(L.plugins))for(let K of L.plugins){let J=typeof K!="string"?K.path:K,ne=v.resolve(H,M.toPortablePath(J));await b(ne,R)}}for(let[I,B]of d)f.activatePlugin(I,B);f.useWithSource("",g(a),e,{strict:n});for(let{path:I,cwd:B,data:b,strict:R}of l)f.useWithSource(I,g(b),B,{strict:R!=null?R:n});return f.get("enableGlobalCache")&&(f.values.set("cacheFolder",`${f.get("globalFolder")}/cache`),f.sources.set("cacheFolder","")),await f.refreshPackageExtensions(),f}static async findRcFiles(e){let r=TB(),i=[],n=e,s=null;for(;n!==s;){s=n;let o=v.join(s,r);if(T.existsSync(o)){let a=await T.readFilePromise(o,"utf8"),l;try{l=Ii(a)}catch(c){let u="";throw a.match(/^\s+(?!-)[^:]+\s+\S+/m)&&(u=" (in particular, make sure you list the colons after each key name)"),new me(`Parse error when loading ${o}; please check it's proper Yaml${u}`)}i.push({path:o,cwd:s,data:l})}n=v.dirname(s)}return i}static async findHomeRcFile(){let e=TB(),r=uh(),i=v.join(r,e);if(T.existsSync(i)){let n=await T.readFilePromise(i,"utf8"),s=Ii(n);return{path:i,cwd:r,data:s}}return null}static async findProjectCwd(e,r){let i=null,n=e,s=null;for(;n!==s;){if(s=n,T.existsSync(v.join(s,"package.json"))&&(i=s),r!==null){if(T.existsSync(v.join(s,r))){i=s;break}}else if(i!==null)break;n=v.dirname(s)}return i}static async updateConfiguration(e,r){let i=TB(),n=v.join(e,i),s=T.existsSync(n)?Ii(await T.readFilePromise(n,"utf8")):{},o=!1,a;if(typeof r=="function"){try{a=r(s)}catch{a=r({})}if(a===s)return}else{a=s;for(let l of Object.keys(r)){let c=s[l],u=r[l],g;if(typeof u=="function")try{g=u(c)}catch{g=u(void 0)}else g=u;c!==g&&(a[l]=g,o=!0)}if(!o)return}await T.changeFilePromise(n,Qa(a),{automaticNewlines:!0})}static async updateHomeConfiguration(e){let r=uh();return await Ra.updateConfiguration(r,e)}activatePlugin(e,r){this.plugins.set(e,r),typeof r.configuration!="undefined"&&this.importSettings(r.configuration)}importSettings(e){for(let[r,i]of Object.entries(e))if(i!=null){if(this.settings.has(r))throw new Error(`Cannot redefine settings "${r}"`);this.settings.set(r,i),this.values.set(r,LR(this,i))}}useWithSource(e,r,i,n){try{this.use(e,r,i,n)}catch(s){throw s.message+=` (in ${Ve(this,e,Le.PATH)})`,s}}use(e,r,i,{strict:n=!0,overwrite:s=!1}={}){n=n&&this.get("enableStrictSettings");for(let o of["enableStrictSettings",...Object.keys(r)]){if(typeof r[o]=="undefined"||o==="plugins"||e===""&&dTe.has(o))continue;if(o==="rcFilename")throw new me(`The rcFilename settings can only be set via ${`${LB}RC_FILENAME`.toUpperCase()}, not via a rc file`);let l=this.settings.get(o);if(!l){if(n)throw new me(`Unrecognized or legacy configuration settings found: ${o} - run "yarn config -v" to see the list of settings supported in Yarn`);this.invalid.set(o,e);continue}if(this.sources.has(o)&&!(s||l.type===ge.MAP||l.isArray&&l.concatenateValues))continue;let c;try{c=NR(this,o,r[o],l,i)}catch(u){throw u.message+=` in ${Ve(this,e,Le.PATH)}`,u}if(o==="enableStrictSettings"&&e!==""){n=c;continue}if(l.type===ge.MAP){let u=this.values.get(o);this.values.set(o,new Map(s?[...u,...c]:[...c,...u])),this.sources.set(o,`${this.sources.get(o)}, ${e}`)}else if(l.isArray&&l.concatenateValues){let u=this.values.get(o);this.values.set(o,s?[...u,...c]:[...c,...u]),this.sources.set(o,`${this.sources.get(o)}, ${e}`)}else this.values.set(o,c),this.sources.set(o,e)}}get(e){if(!this.values.has(e))throw new Error(`Invalid configuration key "${e}"`);return this.values.get(e)}getSpecial(e,{hideSecrets:r=!1,getNativePaths:i=!1}){let n=this.get(e),s=this.settings.get(e);if(typeof s=="undefined")throw new me(`Couldn't find a configuration settings named "${e}"`);return MB(n,s,{hideSecrets:r,getNativePaths:i})}getSubprocessStreams(e,{header:r,prefix:i,report:n}){let s,o,a=T.createWriteStream(e);if(this.get("enableInlineBuilds")){let l=n.createStreamReporter(`${i} ${Ve(this,"STDOUT","green")}`),c=n.createStreamReporter(`${i} ${Ve(this,"STDERR","red")}`);s=new kR.PassThrough,s.pipe(l),s.pipe(a),o=new kR.PassThrough,o.pipe(c),o.pipe(a)}else s=a,o=a,typeof r!="undefined"&&s.write(`${r} +`);return{stdout:s,stderr:o}}makeResolver(){let e=[];for(let r of this.plugins.values())for(let i of r.resolvers||[])e.push(new i);return new pd([new FB,new Yr,new SR,...e])}makeFetcher(){let e=[];for(let r of this.plugins.values())for(let i of r.fetchers||[])e.push(new i);return new vR([new dd,new xR,...e])}getLinkers(){let e=[];for(let r of this.plugins.values())for(let i of r.linkers||[])e.push(new i);return e}getSupportedArchitectures(){let e=this.get("supportedArchitectures"),r=e.get("os");r!==null&&(r=r.map(n=>n==="current"?process.platform:n));let i=e.get("cpu");return i!==null&&(i=i.map(n=>n==="current"?process.arch:n)),{os:r,cpu:i}}async refreshPackageExtensions(){this.packageExtensions=new Map;let e=this.packageExtensions,r=(i,n,{userProvided:s=!1}={})=>{if(!Us(i.range))throw new Error("Only semver ranges are allowed as keys for the packageExtensions setting");let o=new Ze;o.load(n,{yamlCompatibilityMode:!0});let a=hu(e,i.identHash),l=[];a.push([i.range,l]);let c={status:ki.Inactive,userProvided:s,parentDescriptor:i};for(let u of o.dependencies.values())l.push(_(P({},c),{type:oi.Dependency,descriptor:u}));for(let u of o.peerDependencies.values())l.push(_(P({},c),{type:oi.PeerDependency,descriptor:u}));for(let[u,g]of o.peerDependenciesMeta)for(let[f,h]of Object.entries(g))l.push(_(P({},c),{type:oi.PeerDependencyMeta,selector:u,key:f,value:h}))};await this.triggerHook(i=>i.registerPackageExtensions,this,r);for(let[i,n]of this.get("packageExtensions"))r(pA(i,!0),aI(n),{userProvided:!0})}normalizePackage(e){let r=ap(e);if(this.packageExtensions==null)throw new Error("refreshPackageExtensions has to be called before normalizing packages");let i=this.packageExtensions.get(e.identHash);if(typeof i!="undefined"){let s=e.version;if(s!==null){for(let[o,a]of i)if(!!lc(s,o))for(let l of a)switch(l.status===ki.Inactive&&(l.status=ki.Redundant),l.type){case oi.Dependency:typeof r.dependencies.get(l.descriptor.identHash)=="undefined"&&(l.status=ki.Active,r.dependencies.set(l.descriptor.identHash,l.descriptor));break;case oi.PeerDependency:typeof r.peerDependencies.get(l.descriptor.identHash)=="undefined"&&(l.status=ki.Active,r.peerDependencies.set(l.descriptor.identHash,l.descriptor));break;case oi.PeerDependencyMeta:{let c=r.peerDependenciesMeta.get(l.selector);(typeof c=="undefined"||!Object.prototype.hasOwnProperty.call(c,l.key)||c[l.key]!==l.value)&&(l.status=ki.Active,na(r.peerDependenciesMeta,l.selector,()=>({}))[l.key]=l.value)}break;default:Lv(l);break}}}let n=s=>s.scope?`${s.scope}__${s.name}`:`${s.name}`;for(let s of r.peerDependenciesMeta.keys()){let o=En(s);r.peerDependencies.has(o.identHash)||r.peerDependencies.set(o.identHash,Yt(o,"*"))}for(let s of r.peerDependencies.values()){if(s.scope==="types")continue;let o=n(s),a=Eo("types",o),l=St(a);r.peerDependencies.has(a.identHash)||r.peerDependenciesMeta.has(l)||(r.peerDependencies.set(a.identHash,Yt(a,"*")),r.peerDependenciesMeta.set(l,{optional:!0}))}return r.dependencies=new Map(gn(r.dependencies,([,s])=>In(s))),r.peerDependencies=new Map(gn(r.peerDependencies,([,s])=>In(s))),r}getLimit(e){return na(this.limits,e,()=>(0,N_.default)(this.get(e)))}async triggerHook(e,...r){for(let i of this.plugins.values()){let n=i.hooks;if(!n)continue;let s=e(n);!s||await s(...r)}}async triggerMultipleHooks(e,r){for(let i of r)await this.triggerHook(e,...i)}async reduceHook(e,r,...i){let n=r;for(let s of this.plugins.values()){let o=s.hooks;if(!o)continue;let a=e(o);!a||(n=await a(n,...i))}return n}async firstHook(e,...r){for(let i of this.plugins.values()){let n=i.hooks;if(!n)continue;let s=e(n);if(!s)continue;let o=await s(...r);if(typeof o!="undefined")return o}return null}},fe=Ra;fe.telemetry=null;var Gn;(function(r){r[r.SCRIPT=0]="SCRIPT",r[r.SHELLCODE=1]="SHELLCODE"})(Gn||(Gn={}));var Fa=class extends Xi{constructor({configuration:e,stdout:r,suggestInstall:i=!0}){super();this.errorCount=0;Cp(this,{configuration:e}),this.configuration=e,this.stdout=r,this.suggestInstall=i}static async start(e,r){let i=new this(e);try{await r(i)}catch(n){i.reportExceptionOnce(n)}finally{await i.finalize()}return i}hasErrors(){return this.errorCount>0}exitCode(){return this.hasErrors()?1:0}reportCacheHit(e){}reportCacheMiss(e){}startTimerSync(e,r,i){return(typeof r=="function"?r:i)()}async startTimerPromise(e,r,i){return await(typeof r=="function"?r:i)()}async startCacheReport(e){return await e()}reportSeparator(){}reportInfo(e,r){}reportWarning(e,r){}reportError(e,r){this.errorCount+=1,this.stdout.write(`${Ve(this.configuration,"\u27A4","redBright")} ${this.formatNameWithHyperlink(e)}: ${r} +`)}reportProgress(e){let r=Promise.resolve().then(async()=>{for await(let{}of e);}),i=()=>{};return _(P({},r),{stop:i})}reportJson(e){}async finalize(){this.errorCount>0&&(this.stdout.write(` +`),this.stdout.write(`${Ve(this.configuration,"\u27A4","redBright")} Errors happened when preparing the environment required to run this command. +`),this.suggestInstall&&this.stdout.write(`${Ve(this.configuration,"\u27A4","redBright")} This might be caused by packages being missing from the lockfile, in which case running "yarn install" might help. +`))}formatNameWithHyperlink(e){return eD(e,{configuration:this.configuration,json:!1})}};var t0=ie(require("crypto")),v$=ie(CX()),r0=ie(Q$()),S$=ie(Wp()),x$=ie(Or()),lF=ie(require("util")),cF=ie(require("v8")),uF=ie(require("zlib"));var iUe=[[/^(git(?:\+(?:https|ssh))?:\/\/.*(?:\.git)?)#(.*)$/,(t,e,r,i)=>`${r}#commit=${i}`],[/^https:\/\/((?:[^/]+?)@)?codeload\.github\.com\/([^/]+\/[^/]+)\/tar\.gz\/([0-9a-f]+)$/,(t,e,r="",i,n)=>`https://${r}github.com/${i}.git#commit=${n}`],[/^https:\/\/((?:[^/]+?)@)?github\.com\/([^/]+\/[^/]+?)(?:\.git)?#([0-9a-f]+)$/,(t,e,r="",i,n)=>`https://${r}github.com/${i}.git#commit=${n}`],[/^https?:\/\/[^/]+\/(?:[^/]+\/)*(?:@.+(?:\/|(?:%2f)))?([^/]+)\/(?:-|download)\/\1-[^/]+\.tgz(?:#|$)/,t=>`npm:${t}`],[/^https:\/\/npm\.pkg\.github\.com\/download\/(?:@[^/]+)\/(?:[^/]+)\/(?:[^/]+)\/(?:[0-9a-f]+)(?:#|$)/,t=>`npm:${t}`],[/^https:\/\/npm\.fontawesome\.com\/(?:@[^/]+)\/([^/]+)\/-\/([^/]+)\/\1-\2.tgz(?:#|$)/,t=>`npm:${t}`],[/^https?:\/\/(?:[^\\.]+)\.jfrog\.io\/.*\/(@[^/]+)\/([^/]+)\/-\/\1\/\2-(?:[.\d\w-]+)\.tgz(?:#|$)/,(t,e)=>by({protocol:"npm:",source:null,selector:t,params:{__archiveUrl:e}})],[/^[^/]+\.tgz#[0-9a-f]+$/,t=>`npm:${t}`]],oF=class{constructor(){this.resolutions=null}async setup(e,{report:r}){let i=v.join(e.cwd,e.configuration.get("lockfileFilename"));if(!T.existsSync(i))return;let n=await T.readFilePromise(i,"utf8"),s=Ii(n);if(Object.prototype.hasOwnProperty.call(s,"__metadata"))return;let o=this.resolutions=new Map;for(let a of Object.keys(s)){let l=gp(a);if(!l){r.reportWarning(z.YARN_IMPORT_FAILED,`Failed to parse the string "${a}" into a proper descriptor`);continue}Us(l.range)&&(l=Yt(l,`npm:${l.range}`));let{version:c,resolved:u}=s[a];if(!u)continue;let g;for(let[h,p]of iUe){let d=u.match(h);if(d){g=p(c,...d);break}}if(!g){r.reportWarning(z.YARN_IMPORT_FAILED,`${Xt(e.configuration,l)}: Only some patterns can be imported from legacy lockfiles (not "${u}")`);continue}let f=l;try{let h=Tu(l.range),p=gp(h.selector,!0);p&&(f=p)}catch{}o.set(l.descriptorHash,Vi(f,g))}}supportsDescriptor(e,r){return this.resolutions?this.resolutions.has(e.descriptorHash):!1}supportsLocator(e,r){return!1}shouldPersistResolution(e,r){throw new Error("Assertion failed: This resolver doesn't support resolving locators to packages")}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){if(!this.resolutions)throw new Error("Assertion failed: The resolution store should have been setup");let n=this.resolutions.get(e.descriptorHash);if(!n)throw new Error("Assertion failed: The resolution should have been registered");return[n]}async getSatisfying(e,r,i){return null}async resolve(e,r){throw new Error("Assertion failed: This resolver doesn't support resolving locators to packages")}};var aF=class{constructor(e){this.resolver=e}supportsDescriptor(e,r){return!!(r.project.storedResolutions.get(e.descriptorHash)||r.project.originalPackages.has(By(e).locatorHash))}supportsLocator(e,r){return!!(r.project.originalPackages.has(e.locatorHash)&&!r.project.lockfileNeedsRefresh)}shouldPersistResolution(e,r){throw new Error("The shouldPersistResolution method shouldn't be called on the lockfile resolver, which would always answer yes")}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return this.resolver.getResolutionDependencies(e,r)}async getCandidates(e,r,i){let n=i.project.originalPackages.get(By(e).locatorHash);if(n)return[n];let s=i.project.storedResolutions.get(e.descriptorHash);if(!s)throw new Error("Expected the resolution to have been successful - resolution not found");if(n=i.project.originalPackages.get(s),!n)throw new Error("Expected the resolution to have been successful - package not found");return[n]}async getSatisfying(e,r,i){return null}async resolve(e,r){let i=r.project.originalPackages.get(e.locatorHash);if(!i)throw new Error("The lockfile resolver isn't meant to resolve packages - they should already have been stored into a cache");return i}};var AF=class{constructor(e){this.resolver=e}supportsDescriptor(e,r){return this.resolver.supportsDescriptor(e,r)}supportsLocator(e,r){return this.resolver.supportsLocator(e,r)}shouldPersistResolution(e,r){return this.resolver.shouldPersistResolution(e,r)}bindDescriptor(e,r,i){return this.resolver.bindDescriptor(e,r,i)}getResolutionDependencies(e,r){return this.resolver.getResolutionDependencies(e,r)}async getCandidates(e,r,i){throw new nt(z.MISSING_LOCKFILE_ENTRY,`This package doesn't seem to be present in your lockfile; run "yarn install" to update the lockfile`)}async getSatisfying(e,r,i){throw new nt(z.MISSING_LOCKFILE_ENTRY,`This package doesn't seem to be present in your lockfile; run "yarn install" to update the lockfile`)}async resolve(e,r){throw new nt(z.MISSING_LOCKFILE_ENTRY,`This package doesn't seem to be present in your lockfile; run "yarn install" to update the lockfile`)}};var ei=class extends Xi{reportCacheHit(e){}reportCacheMiss(e){}startTimerSync(e,r,i){return(typeof r=="function"?r:i)()}async startTimerPromise(e,r,i){return await(typeof r=="function"?r:i)()}async startCacheReport(e){return await e()}reportSeparator(){}reportInfo(e,r){}reportWarning(e,r){}reportError(e,r){}reportProgress(e){let r=Promise.resolve().then(async()=>{for await(let{}of e);}),i=()=>{};return _(P({},r),{stop:i})}reportJson(e){}async finalize(){}};var b$=ie(vx());var Dd=class{constructor(e,{project:r}){this.workspacesCwds=new Set;this.dependencies=new Map;this.project=r,this.cwd=e}async setup(){this.manifest=T.existsSync(v.join(this.cwd,Ze.fileName))?await Ze.find(this.cwd):new Ze,this.relativeCwd=v.relative(this.project.cwd,this.cwd)||Se.dot;let e=this.manifest.name?this.manifest.name:Eo(null,`${this.computeCandidateName()}-${zi(this.relativeCwd).substr(0,6)}`),r=this.manifest.version?this.manifest.version:"0.0.0";this.locator=Vi(e,r),this.anchoredDescriptor=Yt(this.locator,`${Yr.protocol}${this.relativeCwd}`),this.anchoredLocator=Vi(this.locator,`${Yr.protocol}${this.relativeCwd}`);let i=this.manifest.workspaceDefinitions.map(({pattern:s})=>s),n=await(0,b$.default)(i,{cwd:M.fromPortablePath(this.cwd),expandDirectories:!1,onlyDirectories:!0,onlyFiles:!1,ignore:["**/node_modules","**/.git","**/.yarn"]});n.sort();for(let s of n){let o=v.resolve(this.cwd,M.toPortablePath(s));T.existsSync(v.join(o,"package.json"))&&this.workspacesCwds.add(o)}}accepts(e){var o;let r=e.indexOf(":"),i=r!==-1?e.slice(0,r+1):null,n=r!==-1?e.slice(r+1):e;if(i===Yr.protocol&&v.normalize(n)===this.relativeCwd||i===Yr.protocol&&(n==="*"||n==="^"||n==="~"))return!0;let s=Us(n);return s?i===Yr.protocol?s.test((o=this.manifest.version)!=null?o:"0.0.0"):this.project.configuration.get("enableTransparentWorkspaces")&&this.manifest.version!==null?s.test(this.manifest.version):!1:!1}computeCandidateName(){return this.cwd===this.project.cwd?"root-workspace":`${v.basename(this.cwd)}`||"unnamed-workspace"}getRecursiveWorkspaceDependencies({dependencies:e=Ze.hardDependencies}={}){let r=new Set,i=n=>{for(let s of e)for(let o of n.manifest[s].values()){let a=this.project.tryWorkspaceByDescriptor(o);a===null||r.has(a)||(r.add(a),i(a))}};return i(this),r}getRecursiveWorkspaceDependents({dependencies:e=Ze.hardDependencies}={}){let r=new Set,i=n=>{for(let s of this.project.workspaces)e.some(a=>[...s.manifest[a].values()].some(l=>{let c=this.project.tryWorkspaceByDescriptor(l);return c!==null&&up(c.anchoredLocator,n.anchoredLocator)}))&&!r.has(s)&&(r.add(s),i(s))};return i(this),r}getRecursiveWorkspaceChildren(){let e=[];for(let r of this.workspacesCwds){let i=this.project.workspacesByCwd.get(r);i&&e.push(i,...i.getRecursiveWorkspaceChildren())}return e}async persistManifest(){let e={};this.manifest.exportTo(e);let r=v.join(this.cwd,Ze.fileName),i=`${JSON.stringify(e,null,this.manifest.indent)} +`;await T.changeFilePromise(r,i,{automaticNewlines:!0}),this.manifest.raw=e}};var k$=5,nUe=1,sUe=/ *, */g,P$=/\/$/,oUe=32,aUe=(0,lF.promisify)(uF.default.gzip),AUe=(0,lF.promisify)(uF.default.gunzip),li;(function(r){r.UpdateLockfile="update-lockfile",r.SkipBuild="skip-build"})(li||(li={}));var gF={restoreInstallersCustomData:["installersCustomData"],restoreResolutions:["accessibleLocators","conditionalLocators","disabledLocators","optionalBuilds","storedDescriptors","storedResolutions","storedPackages","lockFileChecksum"],restoreBuildState:["storedBuildState"]},D$=t=>zi(`${nUe}`,t),Ke=class{constructor(e,{configuration:r}){this.resolutionAliases=new Map;this.workspaces=[];this.workspacesByCwd=new Map;this.workspacesByIdent=new Map;this.storedResolutions=new Map;this.storedDescriptors=new Map;this.storedPackages=new Map;this.storedChecksums=new Map;this.storedBuildState=new Map;this.accessibleLocators=new Set;this.conditionalLocators=new Set;this.disabledLocators=new Set;this.originalPackages=new Map;this.optionalBuilds=new Set;this.lockfileNeedsRefresh=!1;this.peerRequirements=new Map;this.installersCustomData=new Map;this.lockFileChecksum=null;this.installStateChecksum=null;this.configuration=r,this.cwd=e}static async find(e,r){var c,u,g;if(!e.projectCwd)throw new me(`No project found in ${r}`);let i=e.projectCwd,n=r,s=null;for(;s!==e.projectCwd;){if(s=n,T.existsSync(v.join(s,wt.manifest))){i=s;break}n=v.dirname(s)}let o=new Ke(e.projectCwd,{configuration:e});(c=fe.telemetry)==null||c.reportProject(o.cwd),await o.setupResolutions(),await o.setupWorkspaces(),(u=fe.telemetry)==null||u.reportWorkspaceCount(o.workspaces.length),(g=fe.telemetry)==null||g.reportDependencyCount(o.workspaces.reduce((f,h)=>f+h.manifest.dependencies.size+h.manifest.devDependencies.size,0));let a=o.tryWorkspaceByCwd(i);if(a)return{project:o,workspace:a,locator:a.anchoredLocator};let l=await o.findLocatorForLocation(`${i}/`,{strict:!0});if(l)return{project:o,locator:l,workspace:null};throw new me(`The nearest package directory (${Ve(e,i,Le.PATH)}) doesn't seem to be part of the project declared in ${Ve(e,o.cwd,Le.PATH)}. + +- If the project directory is right, it might be that you forgot to list ${Ve(e,v.relative(o.cwd,i),Le.PATH)} as a workspace. +- If it isn't, it's likely because you have a yarn.lock or package.json file there, confusing the project root detection.`)}async setupResolutions(){var i;this.storedResolutions=new Map,this.storedDescriptors=new Map,this.storedPackages=new Map,this.lockFileChecksum=null;let e=v.join(this.cwd,this.configuration.get("lockfileFilename")),r=this.configuration.get("defaultLanguageName");if(T.existsSync(e)){let n=await T.readFilePromise(e,"utf8");this.lockFileChecksum=D$(n);let s=Ii(n);if(s.__metadata){let o=s.__metadata.version,a=s.__metadata.cacheKey;this.lockfileNeedsRefresh=o0;){let r=e;e=[];for(let i of r){if(this.workspacesByCwd.has(i))continue;let n=await this.addWorkspace(i),s=this.storedPackages.get(n.anchoredLocator.locatorHash);s&&(n.dependencies=s.dependencies);for(let o of n.workspacesCwds)e.push(o)}}}async addWorkspace(e){let r=new Dd(e,{project:this});await r.setup();let i=this.workspacesByIdent.get(r.locator.identHash);if(typeof i!="undefined")throw new Error(`Duplicate workspace name ${Vr(this.configuration,r.locator)}: ${M.fromPortablePath(e)} conflicts with ${M.fromPortablePath(i.cwd)}`);return this.workspaces.push(r),this.workspacesByCwd.set(e,r),this.workspacesByIdent.set(r.locator.identHash,r),r}get topLevelWorkspace(){return this.getWorkspaceByCwd(this.cwd)}tryWorkspaceByCwd(e){v.isAbsolute(e)||(e=v.resolve(this.cwd,e)),e=v.normalize(e).replace(/\/+$/,"");let r=this.workspacesByCwd.get(e);return r||null}getWorkspaceByCwd(e){let r=this.tryWorkspaceByCwd(e);if(!r)throw new Error(`Workspace not found (${e})`);return r}tryWorkspaceByFilePath(e){let r=null;for(let i of this.workspaces)v.relative(i.cwd,e).startsWith("../")||r&&r.cwd.length>=i.cwd.length||(r=i);return r||null}getWorkspaceByFilePath(e){let r=this.tryWorkspaceByFilePath(e);if(!r)throw new Error(`Workspace not found (${e})`);return r}tryWorkspaceByIdent(e){let r=this.workspacesByIdent.get(e.identHash);return typeof r=="undefined"?null:r}getWorkspaceByIdent(e){let r=this.tryWorkspaceByIdent(e);if(!r)throw new Error(`Workspace not found (${Vr(this.configuration,e)})`);return r}tryWorkspaceByDescriptor(e){let r=this.tryWorkspaceByIdent(e);return r===null||(hA(e)&&(e=Ap(e)),!r.accepts(e.range))?null:r}getWorkspaceByDescriptor(e){let r=this.tryWorkspaceByDescriptor(e);if(r===null)throw new Error(`Workspace not found (${Xt(this.configuration,e)})`);return r}tryWorkspaceByLocator(e){let r=this.tryWorkspaceByIdent(e);return r===null||(Io(e)&&(e=lp(e)),r.locator.locatorHash!==e.locatorHash&&r.anchoredLocator.locatorHash!==e.locatorHash)?null:r}getWorkspaceByLocator(e){let r=this.tryWorkspaceByLocator(e);if(!r)throw new Error(`Workspace not found (${lt(this.configuration,e)})`);return r}refreshWorkspaceDependencies(){for(let e of this.workspaces){let r=this.storedPackages.get(e.anchoredLocator.locatorHash);if(!r)throw new Error(`Assertion failed: Expected workspace ${hp(this.configuration,e)} (${Ve(this.configuration,v.join(e.cwd,wt.manifest),Le.PATH)}) to have been resolved. Run "yarn install" to update the lockfile`);e.dependencies=new Map(r.dependencies)}}forgetResolution(e){let r=n=>{this.storedResolutions.delete(n),this.storedDescriptors.delete(n)},i=n=>{this.originalPackages.delete(n),this.storedPackages.delete(n),this.accessibleLocators.delete(n)};if("descriptorHash"in e){let n=this.storedResolutions.get(e.descriptorHash);r(e.descriptorHash);let s=new Set(this.storedResolutions.values());typeof n!="undefined"&&!s.has(n)&&i(n)}if("locatorHash"in e){i(e.locatorHash);for(let[n,s]of this.storedResolutions)s===e.locatorHash&&r(n)}}forgetTransientResolutions(){let e=this.configuration.makeResolver();for(let r of this.originalPackages.values()){let i;try{i=e.shouldPersistResolution(r,{project:this,resolver:e})}catch{i=!1}i||this.forgetResolution(r)}}forgetVirtualResolutions(){for(let e of this.storedPackages.values())for(let[r,i]of e.dependencies)hA(i)&&e.dependencies.set(r,Ap(i))}getDependencyMeta(e,r){let i={},s=this.topLevelWorkspace.manifest.dependenciesMeta.get(St(e));if(!s)return i;let o=s.get(null);if(o&&Object.assign(i,o),r===null||!x$.default.valid(r))return i;for(let[a,l]of s)a!==null&&a===r&&Object.assign(i,l);return i}async findLocatorForLocation(e,{strict:r=!1}={}){let i=new ei,n=this.configuration.getLinkers(),s={project:this,report:i};for(let o of n){let a=await o.findPackageLocator(e,s);if(a){if(r&&(await o.findPackageLocation(a,s)).replace(P$,"")!==e.replace(P$,""))continue;return a}}return null}async resolveEverything(e){if(!this.workspacesByCwd||!this.workspacesByIdent)throw new Error("Workspaces must have been setup before calling this function");this.forgetVirtualResolutions(),e.lockfileOnly||this.forgetTransientResolutions();let r=e.resolver||this.configuration.makeResolver(),i=new oF;await i.setup(this,{report:e.report});let n=e.lockfileOnly?[new AF(r)]:[i,r],s=new pd([new aF(r),...n]),o=this.configuration.makeFetcher(),a=e.lockfileOnly?{project:this,report:e.report,resolver:s}:{project:this,report:e.report,resolver:s,fetchOptions:{project:this,cache:e.cache,checksums:this.storedChecksums,report:e.report,fetcher:o,cacheOptions:{mirrorWriteOnly:!0}}},l=new Map,c=new Map,u=new Map,g=new Map,f=new Map,h=new Map,p=this.topLevelWorkspace.anchoredLocator,d=new Set,m=[],I=async W=>{let X=await du(async()=>await s.resolve(W,a),D=>`${lt(this.configuration,W)}: ${D}`);if(!up(W,X))throw new Error(`Assertion failed: The locator cannot be changed by the resolver (went from ${lt(this.configuration,W)} to ${lt(this.configuration,X)})`);g.set(X.locatorHash,X);let F=this.configuration.normalizePackage(X);for(let[D,he]of F.dependencies){let pe=await this.configuration.reduceHook(Pe=>Pe.reduceDependency,he,this,F,he,{resolver:s,resolveOptions:a});if(!cp(he,pe))throw new Error("Assertion failed: The descriptor ident cannot be changed through aliases");let Ne=s.bindDescriptor(pe,W,a);F.dependencies.set(D,Ne)}return m.push(Promise.all([...F.dependencies.values()].map(D=>H(D)))),c.set(F.locatorHash,F),F},B=async W=>{let X=f.get(W.locatorHash);if(typeof X!="undefined")return X;let F=Promise.resolve().then(()=>I(W));return f.set(W.locatorHash,F),F},b=async(W,X)=>{let F=await H(X);return l.set(W.descriptorHash,W),u.set(W.descriptorHash,F.locatorHash),F},R=async W=>{let X=this.resolutionAliases.get(W.descriptorHash);if(typeof X!="undefined")return b(W,this.storedDescriptors.get(X));let F=s.getResolutionDependencies(W,a),D=new Map(await Promise.all(F.map(async Ne=>{let Pe=s.bindDescriptor(Ne,p,a),qe=await H(Pe);return d.add(qe.locatorHash),[Ne.descriptorHash,qe]}))),pe=(await du(async()=>await s.getCandidates(W,D,a),Ne=>`${Xt(this.configuration,W)}: ${Ne}`))[0];if(typeof pe=="undefined")throw new Error(`${Xt(this.configuration,W)}: No candidates found`);return l.set(W.descriptorHash,W),u.set(W.descriptorHash,pe.locatorHash),B(pe)},H=W=>{let X=h.get(W.descriptorHash);if(typeof X!="undefined")return X;l.set(W.descriptorHash,W);let F=Promise.resolve().then(()=>R(W));return h.set(W.descriptorHash,F),F};for(let W of this.workspaces){let X=W.anchoredDescriptor;m.push(H(X))}for(;m.length>0;){let W=[...m];m.length=0,await Promise.all(W)}let L=new Set(this.resolutionAliases.values()),K=new Set(c.keys()),J=new Set,ne=new Map;lUe({project:this,report:e.report,accessibleLocators:J,volatileDescriptors:L,optionalBuilds:K,peerRequirements:ne,allDescriptors:l,allResolutions:u,allPackages:c});for(let W of d)K.delete(W);for(let W of L)l.delete(W),u.delete(W);let q=this.configuration.getSupportedArchitectures(),A=new Set,V=new Set;for(let W of c.values())W.conditions!=null&&(!K.has(W.locatorHash)||(Sy(W,q)||(Sy(W,{os:[process.platform],cpu:[process.arch]})&&e.report.reportWarningOnce(z.GHOST_ARCHITECTURE,`${lt(this.configuration,W)}: Your current architecture (${process.platform}-${process.arch}) is supported by this package, but is missing from the ${Ve(this.configuration,"supportedArchitectures",ps.SETTING)} setting`),V.add(W.locatorHash)),A.add(W.locatorHash)));this.storedResolutions=u,this.storedDescriptors=l,this.storedPackages=c,this.accessibleLocators=J,this.conditionalLocators=A,this.disabledLocators=V,this.originalPackages=g,this.optionalBuilds=K,this.peerRequirements=ne,this.refreshWorkspaceDependencies()}async fetchEverything({cache:e,report:r,fetcher:i,mode:n}){let s={mockedPackages:this.disabledLocators,unstablePackages:this.conditionalLocators},o=i||this.configuration.makeFetcher(),a={checksums:this.storedChecksums,project:this,cache:e,fetcher:o,report:r,cacheOptions:s},l=Array.from(new Set(gn(this.storedResolutions.values(),[f=>{let h=this.storedPackages.get(f);if(!h)throw new Error("Assertion failed: The locator should have been registered");return is(h)}])));n===li.UpdateLockfile&&(l=l.filter(f=>!this.storedChecksums.has(f)));let c=!1,u=Xi.progressViaCounter(l.length);r.reportProgress(u);let g=(0,S$.default)(oUe);if(await r.startCacheReport(async()=>{await Promise.all(l.map(f=>g(async()=>{let h=this.storedPackages.get(f);if(!h)throw new Error("Assertion failed: The locator should have been registered");if(Io(h))return;let p;try{p=await o.fetch(h,a)}catch(d){d.message=`${lt(this.configuration,h)}: ${d.message}`,r.reportExceptionOnce(d),c=d;return}p.checksum!=null?this.storedChecksums.set(h.locatorHash,p.checksum):this.storedChecksums.delete(h.locatorHash),p.releaseFs&&p.releaseFs()}).finally(()=>{u.tick()})))}),c)throw c}async linkEverything({cache:e,report:r,fetcher:i,mode:n}){var A,V,W;let s={mockedPackages:this.disabledLocators,unstablePackages:this.conditionalLocators,skipIntegrityCheck:!0},o=i||this.configuration.makeFetcher(),a={checksums:this.storedChecksums,project:this,cache:e,fetcher:o,report:r,skipIntegrityCheck:!0,cacheOptions:s},l=this.configuration.getLinkers(),c={project:this,report:r},u=new Map(l.map(X=>{let F=X.makeInstaller(c),D=F.getCustomDataKey(),he=this.installersCustomData.get(D);return typeof he!="undefined"&&F.attachCustomData(he),[X,F]})),g=new Map,f=new Map,h=new Map,p=new Map(await Promise.all([...this.accessibleLocators].map(async X=>{let F=this.storedPackages.get(X);if(!F)throw new Error("Assertion failed: The locator should have been registered");return[X,await o.fetch(F,a)]}))),d=[];for(let X of this.accessibleLocators){let F=this.storedPackages.get(X);if(typeof F=="undefined")throw new Error("Assertion failed: The locator should have been registered");let D=p.get(F.locatorHash);if(typeof D=="undefined")throw new Error("Assertion failed: The fetch result should have been registered");let he=[],pe=Pe=>{he.push(Pe)},Ne=this.tryWorkspaceByLocator(F);if(Ne!==null){let Pe=[],{scripts:qe}=Ne.manifest;for(let se of["preinstall","install","postinstall"])qe.has(se)&&Pe.push([Gn.SCRIPT,se]);try{for(let[se,be]of u)if(se.supportsPackage(F,c)&&(await be.installPackage(F,D,{holdFetchResult:pe})).buildDirective!==null)throw new Error("Assertion failed: Linkers can't return build directives for workspaces; this responsibility befalls to the Yarn core")}finally{he.length===0?(A=D.releaseFs)==null||A.call(D):d.push(Promise.all(he).catch(()=>{}).then(()=>{var se;(se=D.releaseFs)==null||se.call(D)}))}let re=v.join(D.packageFs.getRealPath(),D.prefixPath);f.set(F.locatorHash,re),!Io(F)&&Pe.length>0&&h.set(F.locatorHash,{directives:Pe,buildLocations:[re]})}else{let Pe=l.find(se=>se.supportsPackage(F,c));if(!Pe)throw new nt(z.LINKER_NOT_FOUND,`${lt(this.configuration,F)} isn't supported by any available linker`);let qe=u.get(Pe);if(!qe)throw new Error("Assertion failed: The installer should have been registered");let re;try{re=await qe.installPackage(F,D,{holdFetchResult:pe})}finally{he.length===0?(V=D.releaseFs)==null||V.call(D):d.push(Promise.all(he).then(()=>{}).then(()=>{var se;(se=D.releaseFs)==null||se.call(D)}))}g.set(F.locatorHash,Pe),f.set(F.locatorHash,re.packageLocation),re.buildDirective&&re.buildDirective.length>0&&re.packageLocation&&h.set(F.locatorHash,{directives:re.buildDirective,buildLocations:[re.packageLocation]})}}let m=new Map;for(let X of this.accessibleLocators){let F=this.storedPackages.get(X);if(!F)throw new Error("Assertion failed: The locator should have been registered");let D=this.tryWorkspaceByLocator(F)!==null,he=async(pe,Ne)=>{let Pe=f.get(F.locatorHash);if(typeof Pe=="undefined")throw new Error(`Assertion failed: The package (${lt(this.configuration,F)}) should have been registered`);let qe=[];for(let re of F.dependencies.values()){let se=this.storedResolutions.get(re.descriptorHash);if(typeof se=="undefined")throw new Error(`Assertion failed: The resolution (${Xt(this.configuration,re)}, from ${lt(this.configuration,F)})should have been registered`);let be=this.storedPackages.get(se);if(typeof be=="undefined")throw new Error(`Assertion failed: The package (${se}, resolved from ${Xt(this.configuration,re)}) should have been registered`);let ae=this.tryWorkspaceByLocator(be)===null?g.get(se):null;if(typeof ae=="undefined")throw new Error(`Assertion failed: The package (${se}, resolved from ${Xt(this.configuration,re)}) should have been registered`);ae===pe||ae===null?f.get(be.locatorHash)!==null&&qe.push([re,be]):!D&&Pe!==null&&hu(m,se).push(Pe)}Pe!==null&&await Ne.attachInternalDependencies(F,qe)};if(D)for(let[pe,Ne]of u)pe.supportsPackage(F,c)&&await he(pe,Ne);else{let pe=g.get(F.locatorHash);if(!pe)throw new Error("Assertion failed: The linker should have been found");let Ne=u.get(pe);if(!Ne)throw new Error("Assertion failed: The installer should have been registered");await he(pe,Ne)}}for(let[X,F]of m){let D=this.storedPackages.get(X);if(!D)throw new Error("Assertion failed: The package should have been registered");let he=g.get(D.locatorHash);if(!he)throw new Error("Assertion failed: The linker should have been found");let pe=u.get(he);if(!pe)throw new Error("Assertion failed: The installer should have been registered");await pe.attachExternalDependents(D,F)}let I=new Map;for(let X of u.values()){let F=await X.finalizeInstall();for(let D of(W=F==null?void 0:F.records)!=null?W:[])h.set(D.locatorHash,{directives:D.buildDirective,buildLocations:D.buildLocations});typeof(F==null?void 0:F.customData)!="undefined"&&I.set(X.getCustomDataKey(),F.customData)}if(this.installersCustomData=I,await Promise.all(d),n===li.SkipBuild)return;let B=new Set(this.storedPackages.keys()),b=new Set(h.keys());for(let X of b)B.delete(X);let R=(0,t0.createHash)("sha512");R.update(process.versions.node),await this.configuration.triggerHook(X=>X.globalHashGeneration,this,X=>{R.update("\0"),R.update(X)});let H=R.digest("hex"),L=new Map,K=X=>{let F=L.get(X.locatorHash);if(typeof F!="undefined")return F;let D=this.storedPackages.get(X.locatorHash);if(typeof D=="undefined")throw new Error("Assertion failed: The package should have been registered");let he=(0,t0.createHash)("sha512");he.update(X.locatorHash),L.set(X.locatorHash,"");for(let pe of D.dependencies.values()){let Ne=this.storedResolutions.get(pe.descriptorHash);if(typeof Ne=="undefined")throw new Error(`Assertion failed: The resolution (${Xt(this.configuration,pe)}) should have been registered`);let Pe=this.storedPackages.get(Ne);if(typeof Pe=="undefined")throw new Error("Assertion failed: The package should have been registered");he.update(K(Pe))}return F=he.digest("hex"),L.set(X.locatorHash,F),F},J=(X,F)=>{let D=(0,t0.createHash)("sha512");D.update(H),D.update(K(X));for(let he of F)D.update(he);return D.digest("hex")},ne=new Map,q=!1;for(;b.size>0;){let X=b.size,F=[];for(let D of b){let he=this.storedPackages.get(D);if(!he)throw new Error("Assertion failed: The package should have been registered");let pe=!0;for(let qe of he.dependencies.values()){let re=this.storedResolutions.get(qe.descriptorHash);if(!re)throw new Error(`Assertion failed: The resolution (${Xt(this.configuration,qe)}) should have been registered`);if(b.has(re)){pe=!1;break}}if(!pe)continue;b.delete(D);let Ne=h.get(he.locatorHash);if(!Ne)throw new Error("Assertion failed: The build directive should have been registered");let Pe=J(he,Ne.buildLocations);if(this.storedBuildState.get(he.locatorHash)===Pe){ne.set(he.locatorHash,Pe);continue}q||(await this.persistInstallStateFile(),q=!0),this.storedBuildState.has(he.locatorHash)?r.reportInfo(z.MUST_REBUILD,`${lt(this.configuration,he)} must be rebuilt because its dependency tree changed`):r.reportInfo(z.MUST_BUILD,`${lt(this.configuration,he)} must be built because it never has been before or the last one failed`);for(let qe of Ne.buildLocations){if(!v.isAbsolute(qe))throw new Error(`Assertion failed: Expected the build location to be absolute (not ${qe})`);F.push((async()=>{for(let[re,se]of Ne.directives){let be=`# This file contains the result of Yarn building a package (${is(he)}) +`;switch(re){case Gn.SCRIPT:be+=`# Script name: ${se} +`;break;case Gn.SHELLCODE:be+=`# Script code: ${se} +`;break}let ae=null;if(!await T.mktempPromise(async De=>{let $=v.join(De,"build.log"),{stdout:G,stderr:Ce}=this.configuration.getSubprocessStreams($,{header:be,prefix:lt(this.configuration,he),report:r}),ee;try{switch(re){case Gn.SCRIPT:ee=await Uw(he,se,[],{cwd:qe,project:this,stdin:ae,stdout:G,stderr:Ce});break;case Gn.SHELLCODE:ee=await rD(he,se,[],{cwd:qe,project:this,stdin:ae,stdout:G,stderr:Ce});break}}catch(Oe){Ce.write(Oe.stack),ee=1}if(G.end(),Ce.end(),ee===0)return ne.set(he.locatorHash,Pe),!0;T.detachTemp(De);let Ue=`${lt(this.configuration,he)} couldn't be built successfully (exit code ${Ve(this.configuration,ee,Le.NUMBER)}, logs can be found here: ${Ve(this.configuration,$,Le.PATH)})`;return this.optionalBuilds.has(he.locatorHash)?(r.reportInfo(z.BUILD_FAILED,Ue),ne.set(he.locatorHash,Pe),!0):(r.reportError(z.BUILD_FAILED,Ue),!1)}))return}})())}}if(await Promise.all(F),X===b.size){let D=Array.from(b).map(he=>{let pe=this.storedPackages.get(he);if(!pe)throw new Error("Assertion failed: The package should have been registered");return lt(this.configuration,pe)}).join(", ");r.reportError(z.CYCLIC_DEPENDENCIES,`Some packages have circular dependencies that make their build order unsatisfiable - as a result they won't be built (affected packages are: ${D})`);break}}this.storedBuildState=ne}async install(e){var a,l;let r=this.configuration.get("nodeLinker");(a=fe.telemetry)==null||a.reportInstall(r),await e.report.startTimerPromise("Project validation",{skipIfEmpty:!0},async()=>{await this.configuration.triggerHook(c=>c.validateProject,this,{reportWarning:e.report.reportWarning.bind(e.report),reportError:e.report.reportError.bind(e.report)})});for(let c of this.configuration.packageExtensions.values())for(let[,u]of c)for(let g of u)g.status=ki.Inactive;let i=v.join(this.cwd,this.configuration.get("lockfileFilename")),n=null;if(e.immutable)try{n=await T.readFilePromise(i,"utf8")}catch(c){throw c.code==="ENOENT"?new nt(z.FROZEN_LOCKFILE_EXCEPTION,"The lockfile would have been created by this install, which is explicitly forbidden."):c}await e.report.startTimerPromise("Resolution step",async()=>{await this.resolveEverything(e)}),await e.report.startTimerPromise("Post-resolution validation",{skipIfEmpty:!0},async()=>{for(let[,c]of this.configuration.packageExtensions)for(let[,u]of c)for(let g of u)if(g.userProvided){let f=Ve(this.configuration,g,Le.PACKAGE_EXTENSION);switch(g.status){case ki.Inactive:e.report.reportWarning(z.UNUSED_PACKAGE_EXTENSION,`${f}: No matching package in the dependency tree; you may not need this rule anymore.`);break;case ki.Redundant:e.report.reportWarning(z.REDUNDANT_PACKAGE_EXTENSION,`${f}: This rule seems redundant when applied on the original package; the extension may have been applied upstream.`);break}}if(n!==null){let c=ul(n,this.generateLockfile());if(c!==n){let u=(0,v$.structuredPatch)(i,i,n,c);e.report.reportSeparator();for(let g of u.hunks){e.report.reportInfo(null,`@@ -${g.oldStart},${g.oldLines} +${g.newStart},${g.newLines} @@`);for(let f of g.lines)f.startsWith("+")?e.report.reportError(z.FROZEN_LOCKFILE_EXCEPTION,Ve(this.configuration,f,Le.ADDED)):f.startsWith("-")?e.report.reportError(z.FROZEN_LOCKFILE_EXCEPTION,Ve(this.configuration,f,Le.REMOVED)):e.report.reportInfo(null,Ve(this.configuration,f,"grey"))}throw e.report.reportSeparator(),new nt(z.FROZEN_LOCKFILE_EXCEPTION,"The lockfile would have been modified by this install, which is explicitly forbidden.")}}});for(let c of this.configuration.packageExtensions.values())for(let[,u]of c)for(let g of u)g.userProvided&&g.status===ki.Active&&((l=fe.telemetry)==null||l.reportPackageExtension(Uu(g,Le.PACKAGE_EXTENSION)));await e.report.startTimerPromise("Fetch step",async()=>{await this.fetchEverything(e),(typeof e.persistProject=="undefined"||e.persistProject)&&e.mode!==li.UpdateLockfile&&await this.cacheCleanup(e)});let s=e.immutable?[...new Set(this.configuration.get("immutablePatterns"))].sort():[],o=await Promise.all(s.map(async c=>Iy(c,{cwd:this.cwd})));(typeof e.persistProject=="undefined"||e.persistProject)&&await this.persist(),await e.report.startTimerPromise("Link step",async()=>{if(e.mode===li.UpdateLockfile){e.report.reportWarning(z.UPDATE_LOCKFILE_ONLY_SKIP_LINK,`Skipped due to ${Ve(this.configuration,"mode=update-lockfile",Le.CODE)}`);return}await this.linkEverything(e);let c=await Promise.all(s.map(async u=>Iy(u,{cwd:this.cwd})));for(let u=0;uc.afterAllInstalled,this,e)}generateLockfile(){let e=new Map;for(let[n,s]of this.storedResolutions.entries()){let o=e.get(s);o||e.set(s,o=new Set),o.add(n)}let r={};r.__metadata={version:k$,cacheKey:void 0};for(let[n,s]of e.entries()){let o=this.originalPackages.get(n);if(!o)continue;let a=[];for(let f of s){let h=this.storedDescriptors.get(f);if(!h)throw new Error("Assertion failed: The descriptor should have been registered");a.push(h)}let l=a.map(f=>In(f)).sort().join(", "),c=new Ze;c.version=o.linkType===gt.HARD?o.version:"0.0.0-use.local",c.languageName=o.languageName,c.dependencies=new Map(o.dependencies),c.peerDependencies=new Map(o.peerDependencies),c.dependenciesMeta=new Map(o.dependenciesMeta),c.peerDependenciesMeta=new Map(o.peerDependenciesMeta),c.bin=new Map(o.bin);let u,g=this.storedChecksums.get(o.locatorHash);if(typeof g!="undefined"){let f=g.indexOf("/");if(f===-1)throw new Error("Assertion failed: Expected the checksum to reference its cache key");let h=g.slice(0,f),p=g.slice(f+1);typeof r.__metadata.cacheKey=="undefined"&&(r.__metadata.cacheKey=h),h===r.__metadata.cacheKey?u=p:u=g}r[l]=_(P({},c.exportTo({},{compatibilityMode:!1})),{linkType:o.linkType.toLowerCase(),resolution:is(o),checksum:u,conditions:o.conditions||void 0})}return`${[`# This file is generated by running "yarn install" inside your project. +`,`# Manual changes might be lost - proceed with caution! +`].join("")} +`+Qa(r)}async persistLockfile(){let e=v.join(this.cwd,this.configuration.get("lockfileFilename")),r="";try{r=await T.readFilePromise(e,"utf8")}catch(s){}let i=this.generateLockfile(),n=ul(r,i);n!==r&&(await T.writeFilePromise(e,n),this.lockFileChecksum=D$(n),this.lockfileNeedsRefresh=!1)}async persistInstallStateFile(){let e=[];for(let o of Object.values(gF))e.push(...o);let r=(0,r0.default)(this,e),i=cF.default.serialize(r),n=zi(i);if(this.installStateChecksum===n)return;let s=this.configuration.get("installStatePath");await T.mkdirPromise(v.dirname(s),{recursive:!0}),await T.writeFilePromise(s,await aUe(i)),this.installStateChecksum=n}async restoreInstallState({restoreInstallersCustomData:e=!0,restoreResolutions:r=!0,restoreBuildState:i=!0}={}){let n=this.configuration.get("installStatePath");if(!T.existsSync(n)){r&&await this.applyLightResolution();return}let s=await AUe(await T.readFilePromise(n));this.installStateChecksum=zi(s);let o=cF.default.deserialize(s);e&&typeof o.installersCustomData!="undefined"&&(this.installersCustomData=o.installersCustomData),i&&Object.assign(this,(0,r0.default)(o,gF.restoreBuildState)),r&&(o.lockFileChecksum===this.lockFileChecksum?(Object.assign(this,(0,r0.default)(o,gF.restoreResolutions)),this.refreshWorkspaceDependencies()):await this.applyLightResolution())}async applyLightResolution(){await this.resolveEverything({lockfileOnly:!0,report:new ei}),await this.persistInstallStateFile()}async persist(){await this.persistLockfile();for(let e of this.workspacesByCwd.values())await e.persistManifest()}async cacheCleanup({cache:e,report:r}){let i=new Set([".gitignore"]);if(!Fb(e.cwd,this.cwd)||!await T.existsPromise(e.cwd))return;let n=this.configuration.get("preferAggregateCacheInfo"),s=0,o=null;for(let a of await T.readdirPromise(e.cwd)){if(i.has(a))continue;let l=v.resolve(e.cwd,a);e.markedFiles.has(l)||(o=a,e.immutable?r.reportError(z.IMMUTABLE_CACHE,`${Ve(this.configuration,v.basename(l),"magenta")} appears to be unused and would be marked for deletion, but the cache is immutable`):(n?s+=1:r.reportInfo(z.UNUSED_CACHE_ENTRY,`${Ve(this.configuration,v.basename(l),"magenta")} appears to be unused - removing`),await T.removePromise(l)))}n&&s!==0&&r.reportInfo(z.UNUSED_CACHE_ENTRY,s>1?`${s} packages appeared to be unused and were removed`:`${o} appeared to be unused and was removed`),e.markedFiles.clear()}};function lUe({project:t,allDescriptors:e,allResolutions:r,allPackages:i,accessibleLocators:n=new Set,optionalBuilds:s=new Set,volatileDescriptors:o=new Set,peerRequirements:a=new Map,report:l,tolerateMissingPackages:c=!1}){var ne;let u=new Map,g=[],f=new Map,h=new Map,p=new Map,d=new Map,m=new Map,I=new Map(t.workspaces.map(q=>{let A=q.anchoredLocator.locatorHash,V=i.get(A);if(typeof V=="undefined"){if(c)return[A,null];throw new Error("Assertion failed: The workspace should have an associated package")}return[A,ap(V)]})),B=()=>{let q=T.mktempSync(),A=v.join(q,"stacktrace.log"),V=String(g.length+1).length,W=g.map((X,F)=>`${`${F+1}.`.padStart(V," ")} ${is(X)} +`).join("");throw T.writeFileSync(A,W),T.detachTemp(q),new nt(z.STACK_OVERFLOW_RESOLUTION,`Encountered a stack overflow when resolving peer dependencies; cf ${M.fromPortablePath(A)}`)},b=q=>{let A=r.get(q.descriptorHash);if(typeof A=="undefined")throw new Error("Assertion failed: The resolution should have been registered");let V=i.get(A);if(!V)throw new Error("Assertion failed: The package could not be found");return V},R=(q,A,V,{top:W,optional:X})=>{g.length>1e3&&B(),g.push(A);let F=H(q,A,V,{top:W,optional:X});return g.pop(),F},H=(q,A,V,{top:W,optional:X})=>{if(n.has(A.locatorHash))return;n.add(A.locatorHash),X||s.delete(A.locatorHash);let F=i.get(A.locatorHash);if(!F){if(c)return;throw new Error(`Assertion failed: The package (${lt(t.configuration,A)}) should have been registered`)}let D=[],he=[],pe=[],Ne=[],Pe=[];for(let re of Array.from(F.dependencies.values())){if(F.peerDependencies.has(re.identHash)&&F.locatorHash!==W)continue;if(hA(re))throw new Error("Assertion failed: Virtual packages shouldn't be encountered when virtualizing a branch");o.delete(re.descriptorHash);let se=X;if(!se){let ee=F.dependenciesMeta.get(St(re));if(typeof ee!="undefined"){let Ue=ee.get(null);typeof Ue!="undefined"&&Ue.optional&&(se=!0)}}let be=r.get(re.descriptorHash);if(!be){if(c)continue;throw new Error(`Assertion failed: The resolution (${Xt(t.configuration,re)}) should have been registered`)}let ae=I.get(be)||i.get(be);if(!ae)throw new Error(`Assertion failed: The package (${be}, resolved from ${Xt(t.configuration,re)}) should have been registered`);if(ae.peerDependencies.size===0){R(re,ae,new Map,{top:W,optional:se});continue}let Ae=u.get(ae.locatorHash);typeof Ae=="number"&&Ae>=2&&B();let De,$,G=new Set,Ce;he.push(()=>{De=kx(re,A.locatorHash),$=Px(ae,A.locatorHash),F.dependencies.delete(re.identHash),F.dependencies.set(De.identHash,De),r.set(De.descriptorHash,$.locatorHash),e.set(De.descriptorHash,De),i.set($.locatorHash,$),D.push([ae,De,$])}),pe.push(()=>{var ee;Ce=new Map;for(let Ue of $.peerDependencies.values()){let Oe=F.dependencies.get(Ue.identHash);if(!Oe&&cp(A,Ue)&&(Oe=q),(!Oe||Oe.range==="missing:")&&$.dependencies.has(Ue.identHash)){$.peerDependencies.delete(Ue.identHash);continue}Oe||(Oe=Yt(Ue,"missing:")),$.dependencies.set(Oe.identHash,Oe),hA(Oe)&&Pl(p,Oe.descriptorHash).add($.locatorHash),f.set(Oe.identHash,Oe),Oe.range==="missing:"&&G.add(Oe.identHash),Ce.set(Ue.identHash,(ee=V.get(Ue.identHash))!=null?ee:$.locatorHash)}$.dependencies=new Map(gn($.dependencies,([Ue,Oe])=>St(Oe)))}),Ne.push(()=>{if(!i.has($.locatorHash))return;let ee=u.get(ae.locatorHash),Ue=typeof ee!="undefined"?ee+1:1;u.set(ae.locatorHash,Ue),R(De,$,Ce,{top:W,optional:se}),u.set(ae.locatorHash,Ue-1)}),Pe.push(()=>{let ee=F.dependencies.get(re.identHash);if(typeof ee=="undefined")throw new Error("Assertion failed: Expected the peer dependency to have been turned into a dependency");let Ue=r.get(ee.descriptorHash);if(typeof Ue=="undefined")throw new Error("Assertion failed: Expected the descriptor to be registered");if(Pl(m,Ue).add(A.locatorHash),!!i.has($.locatorHash)){for(let Oe of $.peerDependencies.values()){let vt=Ce.get(Oe.identHash);if(typeof vt=="undefined")throw new Error("Assertion failed: Expected the peer dependency ident to be registered");hu(pu(d,vt),St(Oe)).push($.locatorHash)}for(let Oe of G)$.dependencies.delete(Oe)}})}for(let re of[...he,...pe])re();let qe;do{qe=!0;for(let[re,se,be]of D){if(!i.has(be.locatorHash))continue;let ae=pu(h,re.locatorHash),Ae=zi(...[...be.dependencies.values()].map(Ce=>{let ee=Ce.range!=="missing:"?r.get(Ce.descriptorHash):"missing:";if(typeof ee=="undefined")throw new Error(`Assertion failed: Expected the resolution for ${Xt(t.configuration,Ce)} to have been registered`);return ee===W?`${ee} (top)`:ee}),se.identHash),De=ae.get(Ae);if(typeof De=="undefined"){ae.set(Ae,se);continue}if(De===se)continue;qe=!1,i.delete(be.locatorHash),e.delete(se.descriptorHash),r.delete(se.descriptorHash),n.delete(be.locatorHash);let $=p.get(se.descriptorHash)||[],G=[F.locatorHash,...$];p.delete(se.descriptorHash);for(let Ce of G){let ee=i.get(Ce);typeof ee!="undefined"&&ee.dependencies.set(se.identHash,De)}}}while(!qe);for(let re of[...Ne,...Pe])re()};for(let q of t.workspaces){let A=q.anchoredLocator;o.delete(q.anchoredDescriptor.descriptorHash),R(q.anchoredDescriptor,A,new Map,{top:A.locatorHash,optional:!1})}var L;(function(V){V[V.NotProvided=0]="NotProvided",V[V.NotCompatible=1]="NotCompatible"})(L||(L={}));let K=[];for(let[q,A]of m){let V=i.get(q);if(typeof V=="undefined")throw new Error("Assertion failed: Expected the root to be registered");let W=d.get(q);if(typeof W!="undefined")for(let X of A){let F=i.get(X);if(typeof F!="undefined")for(let[D,he]of W){let pe=En(D);if(F.peerDependencies.has(pe.identHash))continue;let Ne=`p${zi(X,D,q).slice(0,5)}`;a.set(Ne,{subject:X,requested:pe,rootRequester:q,allRequesters:he});let Pe=V.dependencies.get(pe.identHash);if(typeof Pe!="undefined"){let qe=b(Pe),re=(ne=qe.version)!=null?ne:"0.0.0",se=new Set;for(let ae of he){let Ae=i.get(ae);if(typeof Ae=="undefined")throw new Error("Assertion failed: Expected the link to be registered");let De=Ae.peerDependencies.get(pe.identHash);if(typeof De=="undefined")throw new Error("Assertion failed: Expected the ident to be registered");se.add(De.range)}[...se].every(ae=>{if(ae.startsWith(Yr.protocol)){if(!t.tryWorkspaceByLocator(qe))return!1;ae=ae.slice(Yr.protocol.length),(ae==="^"||ae==="~")&&(ae="*")}return lc(re,ae)})||K.push({type:1,subject:F,requested:pe,requester:V,version:re,hash:Ne,requirementCount:he.length})}else{let qe=V.peerDependenciesMeta.get(D);(qe==null?void 0:qe.optional)||K.push({type:0,subject:F,requested:pe,requester:V,hash:Ne})}}}}let J=[q=>Rx(q.subject),q=>St(q.requested),q=>`${q.type}`];for(let q of gn(K,J))switch(q.type){case 0:l==null||l.reportWarning(z.MISSING_PEER_DEPENDENCY,`${lt(t.configuration,q.subject)} doesn't provide ${Vr(t.configuration,q.requested)} (${Ve(t.configuration,q.hash,Le.CODE)}), requested by ${Vr(t.configuration,q.requester)}`);break;case 1:{let A=q.requirementCount>1?"and some of its descendants request":"requests";l==null||l.reportWarning(z.INCOMPATIBLE_PEER_DEPENDENCY,`${lt(t.configuration,q.subject)} provides ${Vr(t.configuration,q.requested)} (${Ve(t.configuration,q.hash,Le.CODE)}) with version ${fp(t.configuration,q.version)}, which doesn't satisfy what ${Vr(t.configuration,q.requester)} ${A}`)}break}K.length>0&&(l==null||l.reportWarning(z.UNNAMED,`Some peer dependencies are incorrectly met; run ${Ve(t.configuration,"yarn explain peer-requirements ",Le.CODE)} for details, where ${Ve(t.configuration,"",Le.CODE)} is the six-letter p-prefixed code`))}var Po;(function(l){l.VERSION="version",l.COMMAND_NAME="commandName",l.PLUGIN_NAME="pluginName",l.INSTALL_COUNT="installCount",l.PROJECT_COUNT="projectCount",l.WORKSPACE_COUNT="workspaceCount",l.DEPENDENCY_COUNT="dependencyCount",l.EXTENSION="packageExtension"})(Po||(Po={}));var Rd=class{constructor(e,r){this.values=new Map;this.hits=new Map;this.enumerators=new Map;this.configuration=e;let i=this.getRegistryPath();this.isNew=!T.existsSync(i),this.sendReport(r),this.startBuffer()}reportVersion(e){this.reportValue(Po.VERSION,e.replace(/-git\..*/,"-git"))}reportCommandName(e){this.reportValue(Po.COMMAND_NAME,e||"")}reportPluginName(e){this.reportValue(Po.PLUGIN_NAME,e)}reportProject(e){this.reportEnumerator(Po.PROJECT_COUNT,e)}reportInstall(e){this.reportHit(Po.INSTALL_COUNT,e)}reportPackageExtension(e){this.reportValue(Po.EXTENSION,e)}reportWorkspaceCount(e){this.reportValue(Po.WORKSPACE_COUNT,String(e))}reportDependencyCount(e){this.reportValue(Po.DEPENDENCY_COUNT,String(e))}reportValue(e,r){Pl(this.values,e).add(r)}reportEnumerator(e,r){Pl(this.enumerators,e).add(zi(r))}reportHit(e,r="*"){let i=pu(this.hits,e),n=na(i,r,()=>0);i.set(r,n+1)}getRegistryPath(){let e=this.configuration.get("globalFolder");return v.join(e,"telemetry.json")}sendReport(e){var u,g,f;let r=this.getRegistryPath(),i;try{i=T.readJsonSync(r)}catch{i={}}let n=Date.now(),s=this.configuration.get("telemetryInterval")*24*60*60*1e3,a=((u=i.lastUpdate)!=null?u:n+s+Math.floor(s*Math.random()))+s;if(a>n&&i.lastUpdate!=null)return;try{T.mkdirSync(v.dirname(r),{recursive:!0}),T.writeJsonSync(r,{lastUpdate:n})}catch{return}if(a>n||!i.blocks)return;let l=`https://browser-http-intake.logs.datadoghq.eu/v1/input/${e}?ddsource=yarn`,c=h=>iP(l,h,{configuration:this.configuration}).catch(()=>{});for(let[h,p]of Object.entries((g=i.blocks)!=null?g:{})){if(Object.keys(p).length===0)continue;let d=p;d.userId=h,d.reportType="primary";for(let B of Object.keys((f=d.enumerators)!=null?f:{}))d.enumerators[B]=d.enumerators[B].length;c(d);let m=new Map,I=20;for(let[B,b]of Object.entries(d.values))b.length>0&&m.set(B,b.slice(0,I));for(;m.size>0;){let B={};B.userId=h,B.reportType="secondary",B.metrics={};for(let[b,R]of m)B.metrics[b]=R.shift(),R.length===0&&m.delete(b);c(B)}}}applyChanges(){var o,a,l,c,u,g,f,h,p;let e=this.getRegistryPath(),r;try{r=T.readJsonSync(e)}catch{r={}}let i=(o=this.configuration.get("telemetryUserId"))!=null?o:"*",n=r.blocks=(a=r.blocks)!=null?a:{},s=n[i]=(l=n[i])!=null?l:{};for(let d of this.hits.keys()){let m=s.hits=(c=s.hits)!=null?c:{},I=m[d]=(u=m[d])!=null?u:{};for(let[B,b]of this.hits.get(d))I[B]=((g=I[B])!=null?g:0)+b}for(let d of["values","enumerators"])for(let m of this[d].keys()){let I=s[d]=(f=s[d])!=null?f:{};I[m]=[...new Set([...(h=I[m])!=null?h:[],...(p=this[d].get(m))!=null?p:[]])]}T.mkdirSync(v.dirname(e),{recursive:!0}),T.writeJsonSync(e,r)}startBuffer(){process.on("exit",()=>{try{this.applyChanges()}catch{}})}};var fF=ie(require("child_process")),R$=ie(ml());var hF=ie(require("fs"));var Yg=new Map([["constraints",[["constraints","query"],["constraints","source"],["constraints"]]],["exec",[]],["interactive-tools",[["search"],["upgrade-interactive"]]],["stage",[["stage"]]],["typescript",[]],["version",[["version","apply"],["version","check"],["version"]]],["workspace-tools",[["workspaces","focus"],["workspaces","foreach"]]]]);function cUe(t){let e=M.fromPortablePath(t);process.on("SIGINT",()=>{}),e?(0,fF.execFileSync)(process.execPath,[e,...process.argv.slice(2)],{stdio:"inherit",env:_(P({},process.env),{YARN_IGNORE_PATH:"1",YARN_IGNORE_CWD:"1"})}):(0,fF.execFileSync)(e,process.argv.slice(2),{stdio:"inherit",env:_(P({},process.env),{YARN_IGNORE_PATH:"1",YARN_IGNORE_CWD:"1"})})}async function i0({binaryVersion:t,pluginConfiguration:e}){async function r(){let n=new oo({binaryLabel:"Yarn Package Manager",binaryName:"yarn",binaryVersion:t});try{await i(n)}catch(s){process.stdout.write(n.error(s)),process.exitCode=1}}async function i(n){var p,d,m,I,B;let s=process.versions.node,o=">=12 <14 || 14.2 - 14.9 || >14.10.0";if(process.env.YARN_IGNORE_NODE!=="1"&&!qt.satisfiesWithPrereleases(s,o))throw new me(`This tool requires a Node version compatible with ${o} (got ${s}). Upgrade Node, or set \`YARN_IGNORE_NODE=1\` in your environment.`);let a=await fe.find(M.toPortablePath(process.cwd()),e,{usePath:!0,strict:!1}),l=a.get("yarnPath"),c=a.get("ignorePath"),u=a.get("ignoreCwd"),g=M.toPortablePath(M.resolve(process.argv[1])),f=b=>T.readFilePromise(b).catch(()=>Buffer.of());if(!c&&!u&&await(async()=>l===g||Buffer.compare(...await Promise.all([f(l),f(g)]))===0)()){process.env.YARN_IGNORE_PATH="1",process.env.YARN_IGNORE_CWD="1",await i(n);return}else if(l!==null&&!c)if(!T.existsSync(l))process.stdout.write(n.error(new Error(`The "yarn-path" option has been set (in ${a.sources.get("yarnPath")}), but the specified location doesn't exist (${l}).`))),process.exitCode=1;else try{cUe(l)}catch(b){process.exitCode=b.code||1}else{c&&delete process.env.YARN_IGNORE_PATH,a.get("enableTelemetry")&&!R$.isCI&&process.stdout.isTTY&&(fe.telemetry=new Rd(a,"puba9cdc10ec5790a2cf4969dd413a47270")),(p=fe.telemetry)==null||p.reportVersion(t);for(let[L,K]of a.plugins.entries()){Yg.has((m=(d=L.match(/^@yarnpkg\/plugin-(.*)$/))==null?void 0:d[1])!=null?m:"")&&((I=fe.telemetry)==null||I.reportPluginName(L));for(let J of K.commands||[])n.register(J)}let R=n.process(process.argv.slice(2));R.help||(B=fe.telemetry)==null||B.reportCommandName(R.path.join(" "));let H=R.cwd;if(typeof H!="undefined"&&!u){let L=(0,hF.realpathSync)(process.cwd()),K=(0,hF.realpathSync)(H);if(L!==K){process.chdir(H),await r();return}}await n.runExit(R,{cwd:M.toPortablePath(process.cwd()),plugins:e,quiet:!1,stdin:process.stdin,stdout:process.stdout,stderr:process.stderr})}}return r().catch(n=>{process.stdout.write(n.stack||n.message),process.exitCode=1}).finally(()=>T.rmtempPromise())}function F$(t){t.Command.Path=(...e)=>r=>{r.paths=r.paths||[],r.paths.push(e)};for(let e of["Array","Boolean","String","Proxy","Rest","Counter"])t.Command[e]=(...r)=>(i,n)=>{let s=t.Option[e](...r);Object.defineProperty(i,`__${n}`,{configurable:!1,enumerable:!0,get(){return s},set(o){this[n]=o}})};return t}var iC={};it(iC,{BaseCommand:()=>Be,WorkspaceRequiredError:()=>rt,getDynamicLibs:()=>Wie,getPluginConfiguration:()=>F0,main:()=>i0,openWorkspace:()=>rf,pluginCommands:()=>Yg});var Be=class extends ye{constructor(){super(...arguments);this.cwd=Y.String("--cwd",{hidden:!0})}};var rt=class extends me{constructor(e,r){let i=v.relative(e,r),n=v.join(e,Ze.fileName);super(`This command can only be run from within a workspace of your project (${i} isn't a workspace of ${n}).`)}};var dJe=ie(Or());Ss();var CJe=ie(gN()),Wie=()=>new Map([["@yarnpkg/cli",iC],["@yarnpkg/core",Fd],["@yarnpkg/fslib",ch],["@yarnpkg/libzip",Fp],["@yarnpkg/parsers",Hp],["@yarnpkg/shell",jp],["clipanion",vh],["semver",dJe],["typanion",lu],["yup",CJe]]);async function rf(t,e){let{project:r,workspace:i}=await Ke.find(t,e);if(!i)throw new rt(r.cwd,e);return i}var x_e=ie(Or());Ss();var k_e=ie(gN());var hL={};it(hL,{dedupeUtils:()=>zN,default:()=>Qze,suggestUtils:()=>LN});var WAe=ie(ml());var roe=ie(aC());Ss();var LN={};it(LN,{Modifier:()=>Lo,Strategy:()=>Fr,Target:()=>vr,WorkspaceModifier:()=>af,applyModifier:()=>Zse,extractDescriptorFromPath:()=>ON,extractRangeModifier:()=>Xse,fetchDescriptorFrom:()=>MN,findProjectDescriptors:()=>toe,getModifier:()=>AC,getSuggestedDescriptors:()=>lC,makeWorkspaceDescriptor:()=>eoe,toWorkspaceModifier:()=>$se});var TN=ie(Or()),L3e="workspace:",vr;(function(i){i.REGULAR="dependencies",i.DEVELOPMENT="devDependencies",i.PEER="peerDependencies"})(vr||(vr={}));var Lo;(function(i){i.CARET="^",i.TILDE="~",i.EXACT=""})(Lo||(Lo={}));var af;(function(i){i.CARET="^",i.TILDE="~",i.EXACT="*"})(af||(af={}));var Fr;(function(s){s.KEEP="keep",s.REUSE="reuse",s.PROJECT="project",s.LATEST="latest",s.CACHE="cache"})(Fr||(Fr={}));function AC(t,e){return t.exact?Lo.EXACT:t.caret?Lo.CARET:t.tilde?Lo.TILDE:e.configuration.get("defaultSemverRangePrefix")}var T3e=/^([\^~]?)[0-9]+(?:\.[0-9]+){0,2}(?:-\S+)?$/;function Xse(t,{project:e}){let r=t.match(T3e);return r?r[1]:e.configuration.get("defaultSemverRangePrefix")}function Zse(t,e){let{protocol:r,source:i,params:n,selector:s}=S.parseRange(t.range);return TN.default.valid(s)&&(s=`${e}${t.range}`),S.makeDescriptor(t,S.makeRange({protocol:r,source:i,params:n,selector:s}))}function $se(t){switch(t){case Lo.CARET:return af.CARET;case Lo.TILDE:return af.TILDE;case Lo.EXACT:return af.EXACT;default:throw new Error(`Assertion failed: Unknown modifier: "${t}"`)}}function eoe(t,e){return S.makeDescriptor(t.anchoredDescriptor,`${L3e}${$se(e)}`)}async function toe(t,{project:e,target:r}){let i=new Map,n=s=>{let o=i.get(s.descriptorHash);return o||i.set(s.descriptorHash,o={descriptor:s,locators:[]}),o};for(let s of e.workspaces)if(r===vr.PEER){let o=s.manifest.peerDependencies.get(t.identHash);o!==void 0&&n(o).locators.push(s.locator)}else{let o=s.manifest.dependencies.get(t.identHash),a=s.manifest.devDependencies.get(t.identHash);r===vr.DEVELOPMENT?a!==void 0?n(a).locators.push(s.locator):o!==void 0&&n(o).locators.push(s.locator):o!==void 0?n(o).locators.push(s.locator):a!==void 0&&n(a).locators.push(s.locator)}return i}async function ON(t,{cwd:e,workspace:r}){return await M3e(async i=>{v.isAbsolute(t)||(t=v.relative(r.cwd,v.resolve(e,t)),t.match(/^\.{0,2}\//)||(t=`./${t}`));let{project:n}=r,s=await MN(S.makeIdent(null,"archive"),t,{project:r.project,cache:i,workspace:r});if(!s)throw new Error("Assertion failed: The descriptor should have been found");let o=new ei,a=n.configuration.makeResolver(),l=n.configuration.makeFetcher(),c={checksums:n.storedChecksums,project:n,cache:i,fetcher:l,report:o,resolver:a},u=a.bindDescriptor(s,r.anchoredLocator,c),g=S.convertDescriptorToLocator(u),f=await l.fetch(g,c),h=await Ze.find(f.prefixPath,{baseFs:f.packageFs});if(!h.name)throw new Error("Target path doesn't have a name");return S.makeDescriptor(h.name,t)})}async function lC(t,{project:e,workspace:r,cache:i,target:n,modifier:s,strategies:o,maxResults:a=Infinity}){if(!(a>=0))throw new Error(`Invalid maxResults (${a})`);if(t.range!=="unknown")return{suggestions:[{descriptor:t,name:`Use ${S.prettyDescriptor(e.configuration,t)}`,reason:"(unambiguous explicit request)"}],rejections:[]};let l=typeof r!="undefined"&&r!==null&&r.manifest[n].get(t.identHash)||null,c=[],u=[],g=async f=>{try{await f()}catch(h){u.push(h)}};for(let f of o){if(c.length>=a)break;switch(f){case Fr.KEEP:await g(async()=>{l&&c.push({descriptor:l,name:`Keep ${S.prettyDescriptor(e.configuration,l)}`,reason:"(no changes)"})});break;case Fr.REUSE:await g(async()=>{for(let{descriptor:h,locators:p}of(await toe(t,{project:e,target:n})).values()){if(p.length===1&&p[0].locatorHash===r.anchoredLocator.locatorHash&&o.includes(Fr.KEEP))continue;let d=`(originally used by ${S.prettyLocator(e.configuration,p[0])}`;d+=p.length>1?` and ${p.length-1} other${p.length>2?"s":""})`:")",c.push({descriptor:h,name:`Reuse ${S.prettyDescriptor(e.configuration,h)}`,reason:d})}});break;case Fr.CACHE:await g(async()=>{for(let h of e.storedDescriptors.values())h.identHash===t.identHash&&c.push({descriptor:h,name:`Reuse ${S.prettyDescriptor(e.configuration,h)}`,reason:"(already used somewhere in the lockfile)"})});break;case Fr.PROJECT:await g(async()=>{if(r.manifest.name!==null&&t.identHash===r.manifest.name.identHash)return;let h=e.tryWorkspaceByIdent(t);if(h===null)return;let p=eoe(h,s);c.push({descriptor:p,name:`Attach ${S.prettyDescriptor(e.configuration,p)}`,reason:`(local workspace at ${ue.pretty(e.configuration,h.relativeCwd,ue.Type.PATH)})`})});break;case Fr.LATEST:await g(async()=>{if(t.range!=="unknown")c.push({descriptor:t,name:`Use ${S.prettyRange(e.configuration,t.range)}`,reason:"(explicit range requested)"});else if(n===vr.PEER)c.push({descriptor:S.makeDescriptor(t,"*"),name:"Use *",reason:"(catch-all peer dependency pattern)"});else if(!e.configuration.get("enableNetwork"))c.push({descriptor:null,name:"Resolve from latest",reason:ue.pretty(e.configuration,"(unavailable because enableNetwork is toggled off)","grey")});else{let h=await MN(t,"latest",{project:e,cache:i,workspace:r,preserveModifier:!1});h&&(h=Zse(h,s),c.push({descriptor:h,name:`Use ${S.prettyDescriptor(e.configuration,h)}`,reason:"(resolved from latest)"}))}});break}}return{suggestions:c.slice(0,a),rejections:u.slice(0,a)}}async function MN(t,e,{project:r,cache:i,workspace:n,preserveModifier:s=!0}){let o=S.makeDescriptor(t,e),a=new ei,l=r.configuration.makeFetcher(),c=r.configuration.makeResolver(),u={project:r,fetcher:l,cache:i,checksums:r.storedChecksums,report:a,cacheOptions:{skipIntegrityCheck:!0},skipIntegrityCheck:!0},g=_(P({},u),{resolver:c,fetchOptions:u}),f=c.bindDescriptor(o,n.anchoredLocator,g),h=await c.getCandidates(f,new Map,g);if(h.length===0)return null;let p=h[0],{protocol:d,source:m,params:I,selector:B}=S.parseRange(S.convertToManifestRange(p.reference));if(d===r.configuration.get("defaultProtocol")&&(d=null),TN.default.valid(B)&&s!==!1){let b=typeof s=="string"?s:o.range;B=Xse(b,{project:r})+B}return S.makeDescriptor(p,S.makeRange({protocol:d,source:m,params:I,selector:B}))}async function M3e(t){return await T.mktempPromise(async e=>{let r=fe.create(e);return r.useWithSource(e,{enableMirror:!1,compressionLevel:0},e,{overwrite:!0}),await t(new Qt(e,{configuration:r,check:!1,immutable:!1}))})}var cC=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.exact=Y.Boolean("-E,--exact",!1,{description:"Don't use any semver modifier on the resolved range"});this.tilde=Y.Boolean("-T,--tilde",!1,{description:"Use the `~` semver modifier on the resolved range"});this.caret=Y.Boolean("-C,--caret",!1,{description:"Use the `^` semver modifier on the resolved range"});this.dev=Y.Boolean("-D,--dev",!1,{description:"Add a package as a dev dependency"});this.peer=Y.Boolean("-P,--peer",!1,{description:"Add a package as a peer dependency"});this.optional=Y.Boolean("-O,--optional",!1,{description:"Add / upgrade a package to an optional regular / peer dependency"});this.preferDev=Y.Boolean("--prefer-dev",!1,{description:"Add / upgrade a package to a dev dependency"});this.interactive=Y.Boolean("-i,--interactive",{description:"Reuse the specified package from other workspaces in the project"});this.cached=Y.Boolean("--cached",!1,{description:"Reuse the highest version already used somewhere within the project"});this.mode=Y.String("--mode",{description:"Change what artifacts installs generate",validator:Yi(li)});this.silent=Y.Boolean("--silent",{hidden:!0});this.packages=Y.Rest()}async execute(){var d;let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState({restoreResolutions:!1});let s=(d=this.interactive)!=null?d:e.get("preferInteractive"),o=AC(this,r),a=[...s?[Fr.REUSE]:[],Fr.PROJECT,...this.cached?[Fr.CACHE]:[],Fr.LATEST],l=s?Infinity:1,c=await Promise.all(this.packages.map(async m=>{let I=m.match(/^\.{0,2}\//)?await ON(m,{cwd:this.context.cwd,workspace:i}):S.parseDescriptor(m),B=O3e(i,I,{dev:this.dev,peer:this.peer,preferDev:this.preferDev,optional:this.optional}),b=await lC(I,{project:r,workspace:i,cache:n,target:B,modifier:o,strategies:a,maxResults:l});return[I,b,B]})),u=await Fa.start({configuration:e,stdout:this.context.stdout,suggestInstall:!1},async m=>{for(let[I,{suggestions:B,rejections:b}]of c)if(B.filter(H=>H.descriptor!==null).length===0){let[H]=b;if(typeof H=="undefined")throw new Error("Assertion failed: Expected an error to have been set");r.configuration.get("enableNetwork")?m.reportError(z.CANT_SUGGEST_RESOLUTIONS,`${S.prettyDescriptor(e,I)} can't be resolved to a satisfying range`):m.reportError(z.CANT_SUGGEST_RESOLUTIONS,`${S.prettyDescriptor(e,I)} can't be resolved to a satisfying range (note: network resolution has been disabled)`),m.reportSeparator(),m.reportExceptionOnce(H)}});if(u.hasErrors())return u.exitCode();let g=!1,f=[],h=[];for(let[,{suggestions:m},I]of c){let B,b=m.filter(K=>K.descriptor!==null),R=b[0].descriptor,H=b.every(K=>S.areDescriptorsEqual(K.descriptor,R));b.length===1||H?B=R:(g=!0,{answer:B}=await(0,roe.prompt)({type:"select",name:"answer",message:"Which range do you want to use?",choices:m.map(({descriptor:K,name:J,reason:ne})=>K?{name:J,hint:ne,descriptor:K}:{name:J,hint:ne,disabled:!0}),onCancel:()=>process.exit(130),result(K){return this.find(K,"descriptor")},stdin:this.context.stdin,stdout:this.context.stdout}));let L=i.manifest[I].get(B.identHash);(typeof L=="undefined"||L.descriptorHash!==B.descriptorHash)&&(i.manifest[I].set(B.identHash,B),this.optional&&(I==="dependencies"?i.manifest.ensureDependencyMeta(_(P({},B),{range:"unknown"})).optional=!0:I==="peerDependencies"&&(i.manifest.ensurePeerDependencyMeta(_(P({},B),{range:"unknown"})).optional=!0)),typeof L=="undefined"?f.push([i,I,B,a]):h.push([i,I,L,B]))}return await e.triggerMultipleHooks(m=>m.afterWorkspaceDependencyAddition,f),await e.triggerMultipleHooks(m=>m.afterWorkspaceDependencyReplacement,h),g&&this.context.stdout.write(` +`),(await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout,includeLogs:!this.context.quiet},async m=>{await r.install({cache:n,report:m,mode:this.mode})})).exitCode()}};cC.paths=[["add"]],cC.usage=ye.Usage({description:"add dependencies to the project",details:"\n This command adds a package to the package.json for the nearest workspace.\n\n - If it didn't exist before, the package will by default be added to the regular `dependencies` field, but this behavior can be overriden thanks to the `-D,--dev` flag (which will cause the dependency to be added to the `devDependencies` field instead) and the `-P,--peer` flag (which will do the same but for `peerDependencies`).\n\n - If the package was already listed in your dependencies, it will by default be upgraded whether it's part of your `dependencies` or `devDependencies` (it won't ever update `peerDependencies`, though).\n\n - If set, the `--prefer-dev` flag will operate as a more flexible `-D,--dev` in that it will add the package to your `devDependencies` if it isn't already listed in either `dependencies` or `devDependencies`, but it will also happily upgrade your `dependencies` if that's what you already use (whereas `-D,--dev` would throw an exception).\n\n - If set, the `-O,--optional` flag will add the package to the `optionalDependencies` field and, in combination with the `-P,--peer` flag, it will add the package as an optional peer dependency. If the package was already listed in your `dependencies`, it will be upgraded to `optionalDependencies`. If the package was already listed in your `peerDependencies`, in combination with the `-P,--peer` flag, it will be upgraded to an optional peer dependency: `\"peerDependenciesMeta\": { \"\": { \"optional\": true } }`\n\n - If the added package doesn't specify a range at all its `latest` tag will be resolved and the returned version will be used to generate a new semver range (using the `^` modifier by default unless otherwise configured via the `defaultSemverRangePrefix` configuration, or the `~` modifier if `-T,--tilde` is specified, or no modifier at all if `-E,--exact` is specified). Two exceptions to this rule: the first one is that if the package is a workspace then its local version will be used, and the second one is that if you use `-P,--peer` the default range will be `*` and won't be resolved at all.\n\n - If the added package specifies a range (such as `^1.0.0`, `latest`, or `rc`), Yarn will add this range as-is in the resulting package.json entry (in particular, tags such as `rc` will be encoded as-is rather than being converted into a semver range).\n\n If the `--cached` option is used, Yarn will preferably reuse the highest version already used somewhere within the project, even if through a transitive dependency.\n\n If the `-i,--interactive` option is used (or if the `preferInteractive` settings is toggled on) the command will first try to check whether other workspaces in the project use the specified package and, if so, will offer to reuse them.\n\n If the `--mode=` option is set, Yarn will change which artifacts are generated. The modes currently supported are:\n\n - `skip-build` will not run the build scripts at all. Note that this is different from setting `enableScripts` to false because the later will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run.\n\n - `update-lockfile` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost.\n\n For a compilation of all the supported protocols, please consult the dedicated page from our website: https://yarnpkg.com/features/protocols.\n ",examples:[["Add a regular package to the current workspace","$0 add lodash"],["Add a specific version for a package to the current workspace","$0 add lodash@1.2.3"],["Add a package from a GitHub repository (the master branch) to the current workspace using a URL","$0 add lodash@https://github.com/lodash/lodash"],["Add a package from a GitHub repository (the master branch) to the current workspace using the GitHub protocol","$0 add lodash@github:lodash/lodash"],["Add a package from a GitHub repository (the master branch) to the current workspace using the GitHub protocol (shorthand)","$0 add lodash@lodash/lodash"],["Add a package from a specific branch of a GitHub repository to the current workspace using the GitHub protocol (shorthand)","$0 add lodash-es@lodash/lodash#es"]]});var ioe=cC;function O3e(t,e,{dev:r,peer:i,preferDev:n,optional:s}){let o=t.manifest[vr.REGULAR].has(e.identHash),a=t.manifest[vr.DEVELOPMENT].has(e.identHash),l=t.manifest[vr.PEER].has(e.identHash);if((r||i)&&o)throw new me(`Package "${S.prettyIdent(t.project.configuration,e)}" is already listed as a regular dependency - remove the -D,-P flags or remove it from your dependencies first`);if(!r&&!i&&l)throw new me(`Package "${S.prettyIdent(t.project.configuration,e)}" is already listed as a peer dependency - use either of -D or -P, or remove it from your peer dependencies first`);if(s&&a)throw new me(`Package "${S.prettyIdent(t.project.configuration,e)}" is already listed as a dev dependency - remove the -O flag or remove it from your dev dependencies first`);if(s&&!i&&l)throw new me(`Package "${S.prettyIdent(t.project.configuration,e)}" is already listed as a peer dependency - remove the -O flag or add the -P flag or remove it from your peer dependencies first`);if((r||n)&&s)throw new me(`Package "${S.prettyIdent(t.project.configuration,e)}" cannot simultaneously be a dev dependency and an optional dependency`);return i?vr.PEER:r||n?vr.DEVELOPMENT:o?vr.REGULAR:a?vr.DEVELOPMENT:vr.REGULAR}var uC=class extends Be{constructor(){super(...arguments);this.verbose=Y.Boolean("-v,--verbose",!1,{description:"Print both the binary name and the locator of the package that provides the binary"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.name=Y.String({required:!1})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,locator:i}=await Ke.find(e,this.context.cwd);if(await r.restoreInstallState(),this.name){let o=(await Kt.getPackageAccessibleBinaries(i,{project:r})).get(this.name);if(!o)throw new me(`Couldn't find a binary named "${this.name}" for package "${S.prettyLocator(e,i)}"`);let[,a]=o;return this.context.stdout.write(`${a} +`),0}return(await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout},async s=>{let o=await Kt.getPackageAccessibleBinaries(i,{project:r}),l=Array.from(o.keys()).reduce((c,u)=>Math.max(c,u.length),0);for(let[c,[u,g]]of o)s.reportJson({name:c,source:S.stringifyIdent(u),path:g});if(this.verbose)for(let[c,[u]]of o)s.reportInfo(null,`${c.padEnd(l," ")} ${S.prettyLocator(e,u)}`);else for(let c of o.keys())s.reportInfo(null,c)})).exitCode()}};uC.paths=[["bin"]],uC.usage=ye.Usage({description:"get the path to a binary script",details:` + When used without arguments, this command will print the list of all the binaries available in the current workspace. Adding the \`-v,--verbose\` flag will cause the output to contain both the binary name and the locator of the package that provides the binary. + + When an argument is specified, this command will just print the path to the binary on the standard output and exit. Note that the reported path may be stored within a zip archive. + `,examples:[["List all the available binaries","$0 bin"],["Print the path to a specific binary","$0 bin eslint"]]});var noe=uC;var gC=class extends Be{constructor(){super(...arguments);this.mirror=Y.Boolean("--mirror",!1,{description:"Remove the global cache files instead of the local cache files"});this.all=Y.Boolean("--all",!1,{description:"Remove both the global cache files and the local cache files of the current project"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=await Qt.find(e);return(await Fe.start({configuration:e,stdout:this.context.stdout},async()=>{let n=(this.all||this.mirror)&&r.mirrorCwd!==null,s=!this.mirror;n&&(await T.removePromise(r.mirrorCwd),await e.triggerHook(o=>o.cleanGlobalArtifacts,e)),s&&await T.removePromise(r.cwd)})).exitCode()}};gC.paths=[["cache","clean"],["cache","clear"]],gC.usage=ye.Usage({description:"remove the shared cache files",details:` + This command will remove all the files from the cache. + `,examples:[["Remove all the local archives","$0 cache clean"],["Remove all the archives stored in the ~/.yarn directory","$0 cache clean --mirror"]]});var soe=gC;var ooe=ie(p0()),KN=ie(require("util")),fC=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.unsafe=Y.Boolean("--no-redacted",!1,{description:"Don't redact secrets (such as tokens) from the output"});this.name=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=this.name.replace(/[.[].*$/,""),i=this.name.replace(/^[^.[]*/,"");if(typeof e.settings.get(r)=="undefined")throw new me(`Couldn't find a configuration settings named "${r}"`);let s=e.getSpecial(r,{hideSecrets:!this.unsafe,getNativePaths:!0}),o=de.convertMapsToIndexableObjects(s),a=i?(0,ooe.default)(o,i):o,l=await Fe.start({configuration:e,includeFooter:!1,json:this.json,stdout:this.context.stdout},async c=>{c.reportJson(a)});if(!this.json){if(typeof a=="string")return this.context.stdout.write(`${a} +`),l.exitCode();KN.inspect.styles.name="cyan",this.context.stdout.write(`${(0,KN.inspect)(a,{depth:Infinity,colors:e.get("enableColors"),compact:!1})} +`)}return l.exitCode()}};fC.paths=[["config","get"]],fC.usage=ye.Usage({description:"read a configuration settings",details:` + This command will print a configuration setting. + + Secrets (such as tokens) will be redacted from the output by default. If this behavior isn't desired, set the \`--no-redacted\` to get the untransformed value. + `,examples:[["Print a simple configuration setting","yarn config get yarnPath"],["Print a complex configuration setting","yarn config get packageExtensions"],["Print a nested field from the configuration",`yarn config get 'npmScopes["my-company"].npmRegistryServer'`],["Print a token from the configuration","yarn config get npmAuthToken --no-redacted"],["Print a configuration setting as JSON","yarn config get packageExtensions --json"]]});var aoe=fC;var Eae=ie(qN()),Iae=ie(p0()),yae=ie(mae()),JN=ie(require("util")),pC=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Set complex configuration settings to JSON values"});this.home=Y.Boolean("-H,--home",!1,{description:"Update the home configuration instead of the project configuration"});this.name=Y.String();this.value=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=()=>{if(!e.projectCwd)throw new me("This command must be run from within a project folder");return e.projectCwd},i=this.name.replace(/[.[].*$/,""),n=this.name.replace(/^[^.[]*\.?/,"");if(typeof e.settings.get(i)=="undefined")throw new me(`Couldn't find a configuration settings named "${i}"`);if(i==="enableStrictSettings")throw new me("This setting only affects the file it's in, and thus cannot be set from the CLI");let o=this.json?JSON.parse(this.value):this.value;await(this.home?h=>fe.updateHomeConfiguration(h):h=>fe.updateConfiguration(r(),h))(h=>{if(n){let p=(0,Eae.default)(h);return(0,yae.default)(p,this.name,o),p}else return _(P({},h),{[i]:o})});let c=(await fe.find(this.context.cwd,this.context.plugins)).getSpecial(i,{hideSecrets:!0,getNativePaths:!0}),u=de.convertMapsToIndexableObjects(c),g=n?(0,Iae.default)(u,n):u;return(await Fe.start({configuration:e,includeFooter:!1,stdout:this.context.stdout},async h=>{JN.inspect.styles.name="cyan",h.reportInfo(z.UNNAMED,`Successfully set ${this.name} to ${(0,JN.inspect)(g,{depth:Infinity,colors:e.get("enableColors"),compact:!1})}`)})).exitCode()}};pC.paths=[["config","set"]],pC.usage=ye.Usage({description:"change a configuration settings",details:` + This command will set a configuration setting. + + When used without the \`--json\` flag, it can only set a simple configuration setting (a string, a number, or a boolean). + + When used with the \`--json\` flag, it can set both simple and complex configuration settings, including Arrays and Objects. + `,examples:[["Set a simple configuration setting (a string, a number, or a boolean)","yarn config set initScope myScope"],["Set a simple configuration setting (a string, a number, or a boolean) using the `--json` flag",'yarn config set initScope --json \\"myScope\\"'],["Set a complex configuration setting (an Array) using the `--json` flag",`yarn config set unsafeHttpWhitelist --json '["*.example.com", "example.com"]'`],["Set a complex configuration setting (an Object) using the `--json` flag",`yarn config set packageExtensions --json '{ "@babel/parser@*": { "dependencies": { "@babel/types": "*" } } }'`],["Set a nested configuration setting",'yarn config set npmScopes.company.npmRegistryServer "https://npm.example.com"'],["Set a nested configuration setting using indexed access for non-simple keys",`yarn config set 'npmRegistries["//npm.example.com"].npmAuthToken' "ffffffff-ffff-ffff-ffff-ffffffffffff"`]]});var wae=pC;var Dae=ie(qN()),Rae=ie(Ld()),Fae=ie(Pae()),dC=class extends Be{constructor(){super(...arguments);this.home=Y.Boolean("-H,--home",!1,{description:"Update the home configuration instead of the project configuration"});this.name=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=()=>{if(!e.projectCwd)throw new me("This command must be run from within a project folder");return e.projectCwd},i=this.name.replace(/[.[].*$/,""),n=this.name.replace(/^[^.[]*\.?/,"");if(typeof e.settings.get(i)=="undefined")throw new me(`Couldn't find a configuration settings named "${i}"`);let o=this.home?l=>fe.updateHomeConfiguration(l):l=>fe.updateConfiguration(r(),l);return(await Fe.start({configuration:e,includeFooter:!1,stdout:this.context.stdout},async l=>{let c=!1;await o(u=>{if(!(0,Rae.default)(u,this.name))return l.reportWarning(z.UNNAMED,`Configuration doesn't contain setting ${this.name}; there is nothing to unset`),c=!0,u;let g=n?(0,Dae.default)(u):P({},u);return(0,Fae.default)(g,this.name),g}),c||l.reportInfo(z.UNNAMED,`Successfully unset ${this.name}`)})).exitCode()}};dC.paths=[["config","unset"]],dC.usage=ye.Usage({description:"unset a configuration setting",details:` + This command will unset a configuration setting. + `,examples:[["Unset a simple configuration setting","yarn config unset initScope"],["Unset a complex configuration setting","yarn config unset packageExtensions"],["Unset a nested configuration setting","yarn config unset npmScopes.company.npmRegistryServer"]]});var Nae=dC;var WN=ie(require("util")),CC=class extends Be{constructor(){super(...arguments);this.verbose=Y.Boolean("-v,--verbose",!1,{description:"Print the setting description on top of the regular key/value information"});this.why=Y.Boolean("--why",!1,{description:"Print the reason why a setting is set a particular way"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins,{strict:!1});return(await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout},async i=>{if(e.invalid.size>0&&!this.json){for(let[n,s]of e.invalid)i.reportError(z.INVALID_CONFIGURATION_KEY,`Invalid configuration key "${n}" in ${s}`);i.reportSeparator()}if(this.json){let n=de.sortMap(e.settings.keys(),s=>s);for(let s of n){let o=e.settings.get(s),a=e.getSpecial(s,{hideSecrets:!0,getNativePaths:!0}),l=e.sources.get(s);this.verbose?i.reportJson({key:s,effective:a,source:l}):i.reportJson(P({key:s,effective:a,source:l},o))}}else{let n=de.sortMap(e.settings.keys(),a=>a),s=n.reduce((a,l)=>Math.max(a,l.length),0),o={breakLength:Infinity,colors:e.get("enableColors"),maxArrayLength:2};if(this.why||this.verbose){let a=n.map(c=>{let u=e.settings.get(c);if(!u)throw new Error(`Assertion failed: This settings ("${c}") should have been registered`);let g=this.why?e.sources.get(c)||"":u.description;return[c,g]}),l=a.reduce((c,[,u])=>Math.max(c,u.length),0);for(let[c,u]of a)i.reportInfo(null,`${c.padEnd(s," ")} ${u.padEnd(l," ")} ${(0,WN.inspect)(e.getSpecial(c,{hideSecrets:!0,getNativePaths:!0}),o)}`)}else for(let a of n)i.reportInfo(null,`${a.padEnd(s," ")} ${(0,WN.inspect)(e.getSpecial(a,{hideSecrets:!0,getNativePaths:!0}),o)}`)}})).exitCode()}};CC.paths=[["config"]],CC.usage=ye.Usage({description:"display the current configuration",details:` + This command prints the current active configuration settings. + `,examples:[["Print the active configuration settings","$0 config"]]});var Lae=CC;Ss();var zN={};it(zN,{Strategy:()=>Oc,acceptedStrategies:()=>H4e,dedupe:()=>VN});var Tae=ie(Nn()),Oc;(function(e){e.HIGHEST="highest"})(Oc||(Oc={}));var H4e=new Set(Object.values(Oc)),G4e={highest:async(t,e,{resolver:r,fetcher:i,resolveOptions:n,fetchOptions:s})=>{let o=new Map;for(let[a,l]of t.storedResolutions){let c=t.storedDescriptors.get(a);if(typeof c=="undefined")throw new Error(`Assertion failed: The descriptor (${a}) should have been registered`);de.getSetWithDefault(o,c.identHash).add(l)}return Array.from(t.storedDescriptors.values(),async a=>{if(e.length&&!Tae.default.isMatch(S.stringifyIdent(a),e))return null;let l=t.storedResolutions.get(a.descriptorHash);if(typeof l=="undefined")throw new Error(`Assertion failed: The resolution (${a.descriptorHash}) should have been registered`);let c=t.originalPackages.get(l);if(typeof c=="undefined"||!r.shouldPersistResolution(c,n))return null;let u=o.get(a.identHash);if(typeof u=="undefined")throw new Error(`Assertion failed: The resolutions (${a.identHash}) should have been registered`);if(u.size===1)return null;let g=[...u].map(m=>{let I=t.originalPackages.get(m);if(typeof I=="undefined")throw new Error(`Assertion failed: The package (${m}) should have been registered`);return I.reference}),f=await r.getSatisfying(a,g,n),h=f==null?void 0:f[0];if(typeof h=="undefined")return null;let p=h.locatorHash,d=t.originalPackages.get(p);if(typeof d=="undefined")throw new Error(`Assertion failed: The package (${p}) should have been registered`);return p===l?null:{descriptor:a,currentPackage:c,updatedPackage:d}})}};async function VN(t,{strategy:e,patterns:r,cache:i,report:n}){let{configuration:s}=t,o=new ei,a=s.makeResolver(),l=s.makeFetcher(),c={cache:i,checksums:t.storedChecksums,fetcher:l,project:t,report:o,skipIntegrityCheck:!0,cacheOptions:{skipIntegrityCheck:!0}},u={project:t,resolver:a,report:o,fetchOptions:c};return await n.startTimerPromise("Deduplication step",async()=>{let f=await G4e[e](t,r,{resolver:a,resolveOptions:u,fetcher:l,fetchOptions:c}),h=Xi.progressViaCounter(f.length);n.reportProgress(h);let p=0;await Promise.all(f.map(I=>I.then(B=>{if(B===null)return;p++;let{descriptor:b,currentPackage:R,updatedPackage:H}=B;n.reportInfo(z.UNNAMED,`${S.prettyDescriptor(s,b)} can be deduped from ${S.prettyLocator(s,R)} to ${S.prettyLocator(s,H)}`),n.reportJson({descriptor:S.stringifyDescriptor(b),currentResolution:S.stringifyLocator(R),updatedResolution:S.stringifyLocator(H)}),t.storedResolutions.set(b.descriptorHash,H.locatorHash)}).finally(()=>h.tick())));let d;switch(p){case 0:d="No packages";break;case 1:d="One package";break;default:d=`${p} packages`}let m=ue.pretty(s,e,ue.Type.CODE);return n.reportInfo(z.UNNAMED,`${d} can be deduped using the ${m} strategy`),p})}var mC=class extends Be{constructor(){super(...arguments);this.strategy=Y.String("-s,--strategy",Oc.HIGHEST,{description:"The strategy to use when deduping dependencies",validator:Yi(Oc)});this.check=Y.Boolean("-c,--check",!1,{description:"Exit with exit code 1 when duplicates are found, without persisting the dependency tree"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.mode=Y.String("--mode",{description:"Change what artifacts installs generate",validator:Yi(li)});this.patterns=Y.Rest()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r}=await Ke.find(e,this.context.cwd),i=await Qt.find(e);await r.restoreInstallState({restoreResolutions:!1});let n=0,s=await Fe.start({configuration:e,includeFooter:!1,stdout:this.context.stdout,json:this.json},async o=>{n=await VN(r,{strategy:this.strategy,patterns:this.patterns,cache:i,report:o})});return s.hasErrors()?s.exitCode():this.check?n?1:0:(await Fe.start({configuration:e,stdout:this.context.stdout,json:this.json},async a=>{await r.install({cache:i,report:a,mode:this.mode})})).exitCode()}};mC.paths=[["dedupe"]],mC.usage=ye.Usage({description:"deduplicate dependencies with overlapping ranges",details:"\n Duplicates are defined as descriptors with overlapping ranges being resolved and locked to different locators. They are a natural consequence of Yarn's deterministic installs, but they can sometimes pile up and unnecessarily increase the size of your project.\n\n This command dedupes dependencies in the current project using different strategies (only one is implemented at the moment):\n\n - `highest`: Reuses (where possible) the locators with the highest versions. This means that dependencies can only be upgraded, never downgraded. It's also guaranteed that it never takes more than a single pass to dedupe the entire dependency tree.\n\n **Note:** Even though it never produces a wrong dependency tree, this command should be used with caution, as it modifies the dependency tree, which can sometimes cause problems when packages don't strictly follow semver recommendations. Because of this, it is recommended to also review the changes manually.\n\n If set, the `-c,--check` flag will only report the found duplicates, without persisting the modified dependency tree. If changes are found, the command will exit with a non-zero exit code, making it suitable for CI purposes.\n\n If the `--mode=` option is set, Yarn will change which artifacts are generated. The modes currently supported are:\n\n - `skip-build` will not run the build scripts at all. Note that this is different from setting `enableScripts` to false because the later will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run.\n\n - `update-lockfile` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost.\n\n This command accepts glob patterns as arguments (if valid Idents and supported by [micromatch](https://github.com/micromatch/micromatch)). Make sure to escape the patterns, to prevent your own shell from trying to expand them.\n\n ### In-depth explanation:\n\n Yarn doesn't deduplicate dependencies by default, otherwise installs wouldn't be deterministic and the lockfile would be useless. What it actually does is that it tries to not duplicate dependencies in the first place.\n\n **Example:** If `foo@^2.3.4` (a dependency of a dependency) has already been resolved to `foo@2.3.4`, running `yarn add foo@*`will cause Yarn to reuse `foo@2.3.4`, even if the latest `foo` is actually `foo@2.10.14`, thus preventing unnecessary duplication.\n\n Duplication happens when Yarn can't unlock dependencies that have already been locked inside the lockfile.\n\n **Example:** If `foo@^2.3.4` (a dependency of a dependency) has already been resolved to `foo@2.3.4`, running `yarn add foo@2.10.14` will cause Yarn to install `foo@2.10.14` because the existing resolution doesn't satisfy the range `2.10.14`. This behavior can lead to (sometimes) unwanted duplication, since now the lockfile contains 2 separate resolutions for the 2 `foo` descriptors, even though they have overlapping ranges, which means that the lockfile can be simplified so that both descriptors resolve to `foo@2.10.14`.\n ",examples:[["Dedupe all packages","$0 dedupe"],["Dedupe all packages using a specific strategy","$0 dedupe --strategy highest"],["Dedupe a specific package","$0 dedupe lodash"],["Dedupe all packages with the `@babel/*` scope","$0 dedupe '@babel/*'"],["Check for duplicates (can be used as a CI step)","$0 dedupe --check"]]});var Mae=mC;var Y0=class extends Be{async execute(){let{plugins:e}=await fe.find(this.context.cwd,this.context.plugins),r=[];for(let o of e){let{commands:a}=o[1];if(a){let c=oo.from(a).definitions();r.push([o[0],c])}}let i=this.cli.definitions(),n=(o,a)=>o.split(" ").slice(1).join()===a.split(" ").slice(1).join(),s=Kae()["@yarnpkg/builder"].bundles.standard;for(let o of r){let a=o[1];for(let l of a)i.find(c=>n(c.path,l.path)).plugin={name:o[0],isDefault:s.includes(o[0])}}this.context.stdout.write(`${JSON.stringify(i,null,2)} +`)}};Y0.paths=[["--clipanion=definitions"]];var Uae=Y0;var q0=class extends Be{async execute(){this.context.stdout.write(this.cli.usage(null))}};q0.paths=[["help"],["--help"],["-h"]];var Hae=q0;var _N=class extends Be{constructor(){super(...arguments);this.leadingArgument=Y.String();this.args=Y.Proxy()}async execute(){if(this.leadingArgument.match(/[\\/]/)&&!S.tryParseIdent(this.leadingArgument)){let e=v.resolve(this.context.cwd,M.toPortablePath(this.leadingArgument));return await this.cli.run(this.args,{cwd:e})}else return await this.cli.run(["run",this.leadingArgument,...this.args])}},Gae=_N;var J0=class extends Be{async execute(){this.context.stdout.write(`${Zr||""} +`)}};J0.paths=[["-v"],["--version"]];var jae=J0;var EC=class extends Be{constructor(){super(...arguments);this.commandName=Y.String();this.args=Y.Proxy()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,locator:i}=await Ke.find(e,this.context.cwd);return await r.restoreInstallState(),await Kt.executePackageShellcode(i,this.commandName,this.args,{cwd:this.context.cwd,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr,project:r})}};EC.paths=[["exec"]],EC.usage=ye.Usage({description:"execute a shell script",details:` + This command simply executes a shell script within the context of the root directory of the active workspace using the portable shell. + + It also makes sure to call it in a way that's compatible with the current project (for example, on PnP projects the environment will be setup in such a way that PnP will be correctly injected into the environment). + `,examples:[["Execute a single shell command","$0 exec echo Hello World"],["Execute a shell script",'$0 exec "tsc & babel src --out-dir lib"']]});var Yae=EC;Ss();var IC=class extends Be{constructor(){super(...arguments);this.hash=Y.String({required:!1,validator:fv(gv(),[hv(/^p[0-9a-f]{5}$/)])})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r}=await Ke.find(e,this.context.cwd);return await r.restoreInstallState({restoreResolutions:!1}),await r.applyLightResolution(),typeof this.hash!="undefined"?await j4e(this.hash,r,{stdout:this.context.stdout}):(await Fe.start({configuration:e,stdout:this.context.stdout,includeFooter:!1},async n=>{var o;let s=[([,a])=>S.stringifyLocator(r.storedPackages.get(a.subject)),([,a])=>S.stringifyIdent(a.requested)];for(let[a,l]of de.sortMap(r.peerRequirements,s)){let c=r.storedPackages.get(l.subject);if(typeof c=="undefined")throw new Error("Assertion failed: Expected the subject package to have been registered");let u=r.storedPackages.get(l.rootRequester);if(typeof u=="undefined")throw new Error("Assertion failed: Expected the root package to have been registered");let g=(o=c.dependencies.get(l.requested.identHash))!=null?o:null,f=ue.pretty(e,a,ue.Type.CODE),h=S.prettyLocator(e,c),p=S.prettyIdent(e,l.requested),d=S.prettyIdent(e,u),m=l.allRequesters.length-1,I=`descendant${m===1?"":"s"}`,B=m>0?` and ${m} ${I}`:"",b=g!==null?"provides":"doesn't provide";n.reportInfo(null,`${f} \u2192 ${h} ${b} ${p} to ${d}${B}`)}})).exitCode()}};IC.paths=[["explain","peer-requirements"]],IC.usage=ye.Usage({description:"explain a set of peer requirements",details:` + A set of peer requirements represents all peer requirements that a dependent must satisfy when providing a given peer request to a requester and its descendants. + + When the hash argument is specified, this command prints a detailed explanation of all requirements of the set corresponding to the hash and whether they're satisfied or not. + + When used without arguments, this command lists all sets of peer requirements and the corresponding hash that can be used to get detailed information about a given set. + + **Note:** A hash is a six-letter p-prefixed code that can be obtained from peer dependency warnings or from the list of all peer requirements (\`yarn explain peer-requirements\`). + `,examples:[["Explain the corresponding set of peer requirements for a hash","$0 explain peer-requirements p1a4ed"],["List all sets of peer requirements","$0 explain peer-requirements"]]});var qae=IC;async function j4e(t,e,r){let{configuration:i}=e,n=e.peerRequirements.get(t);if(typeof n=="undefined")throw new Error(`No peerDependency requirements found for hash: "${t}"`);return(await Fe.start({configuration:i,stdout:r.stdout,includeFooter:!1},async o=>{var I,B;let a=e.storedPackages.get(n.subject);if(typeof a=="undefined")throw new Error("Assertion failed: Expected the subject package to have been registered");let l=e.storedPackages.get(n.rootRequester);if(typeof l=="undefined")throw new Error("Assertion failed: Expected the root package to have been registered");let c=(I=a.dependencies.get(n.requested.identHash))!=null?I:null,u=c!==null?e.storedResolutions.get(c.descriptorHash):null;if(typeof u=="undefined")throw new Error("Assertion failed: Expected the resolution to have been registered");let g=u!==null?e.storedPackages.get(u):null;if(typeof g=="undefined")throw new Error("Assertion failed: Expected the provided package to have been registered");let f=[...n.allRequesters.values()].map(b=>{let R=e.storedPackages.get(b);if(typeof R=="undefined")throw new Error("Assertion failed: Expected the package to be registered");let H=S.devirtualizeLocator(R),L=e.storedPackages.get(H.locatorHash);if(typeof L=="undefined")throw new Error("Assertion failed: Expected the package to be registered");let K=L.peerDependencies.get(n.requested.identHash);if(typeof K=="undefined")throw new Error("Assertion failed: Expected the peer dependency to be registered");return{pkg:R,peerDependency:K}});if(g!==null){let b=f.every(({peerDependency:R})=>qt.satisfiesWithPrereleases(g.version,R.range));o.reportInfo(z.UNNAMED,`${S.prettyLocator(i,a)} provides ${S.prettyLocator(i,g)} with version ${S.prettyReference(i,(B=g.version)!=null?B:"")}, which ${b?"satisfies":"doesn't satisfy"} the following requirements:`)}else o.reportInfo(z.UNNAMED,`${S.prettyLocator(i,a)} doesn't provide ${S.prettyIdent(i,n.requested)}, breaking the following requirements:`);o.reportSeparator();let h=ue.mark(i),p=[];for(let{pkg:b,peerDependency:R}of de.sortMap(f,H=>S.stringifyLocator(H.pkg))){let L=(g!==null?qt.satisfiesWithPrereleases(g.version,R.range):!1)?h.Check:h.Cross;p.push({stringifiedLocator:S.stringifyLocator(b),prettyLocator:S.prettyLocator(i,b),prettyRange:S.prettyRange(i,R.range),mark:L})}let d=Math.max(...p.map(({stringifiedLocator:b})=>b.length)),m=Math.max(...p.map(({prettyRange:b})=>b.length));for(let{stringifiedLocator:b,prettyLocator:R,prettyRange:H,mark:L}of de.sortMap(p,({stringifiedLocator:K})=>K))o.reportInfo(null,`${R.padEnd(d+(R.length-b.length)," ")} \u2192 ${H.padEnd(m," ")} ${L}`);p.length>1&&(o.reportSeparator(),o.reportInfo(z.UNNAMED,`Note: these requirements start with ${S.prettyLocator(e.configuration,l)}`))})).exitCode()}var Jae=ie(Nn()),yC=class extends Be{constructor(){super(...arguments);this.all=Y.Boolean("-A,--all",!1,{description:"Print versions of a package from the whole project"});this.recursive=Y.Boolean("-R,--recursive",!1,{description:"Print information for all packages, including transitive dependencies"});this.extra=Y.Array("-X,--extra",[],{description:"An array of requests of extra data provided by plugins"});this.cache=Y.Boolean("--cache",!1,{description:"Print information about the cache entry of a package (path, size, checksum)"});this.dependents=Y.Boolean("--dependents",!1,{description:"Print all dependents for each matching package"});this.manifest=Y.Boolean("--manifest",!1,{description:"Print data obtained by looking at the package archive (license, homepage, ...)"});this.nameOnly=Y.Boolean("--name-only",!1,{description:"Only print the name for the matching packages"});this.virtuals=Y.Boolean("--virtuals",!1,{description:"Print each instance of the virtual packages"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.patterns=Y.Rest()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i&&!this.all)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState();let s=new Set(this.extra);this.cache&&s.add("cache"),this.dependents&&s.add("dependents"),this.manifest&&s.add("manifest");let o=(b,{recursive:R})=>{let H=b.anchoredLocator.locatorHash,L=new Map,K=[H];for(;K.length>0;){let J=K.shift();if(L.has(J))continue;let ne=r.storedPackages.get(J);if(typeof ne=="undefined")throw new Error("Assertion failed: Expected the package to be registered");if(L.set(J,ne),S.isVirtualLocator(ne)&&K.push(S.devirtualizeLocator(ne).locatorHash),!(!R&&J!==H))for(let q of ne.dependencies.values()){let A=r.storedResolutions.get(q.descriptorHash);if(typeof A=="undefined")throw new Error("Assertion failed: Expected the resolution to be registered");K.push(A)}}return L.values()},a=({recursive:b})=>{let R=new Map;for(let H of r.workspaces)for(let L of o(H,{recursive:b}))R.set(L.locatorHash,L);return R.values()},l=({all:b,recursive:R})=>b&&R?r.storedPackages.values():b?a({recursive:R}):o(i,{recursive:R}),c=({all:b,recursive:R})=>{let H=l({all:b,recursive:R}),L=this.patterns.map(ne=>{let q=S.parseLocator(ne),A=Jae.default.makeRe(S.stringifyIdent(q)),V=S.isVirtualLocator(q),W=V?S.devirtualizeLocator(q):q;return X=>{let F=S.stringifyIdent(X);if(!A.test(F))return!1;if(q.reference==="unknown")return!0;let D=S.isVirtualLocator(X),he=D?S.devirtualizeLocator(X):X;return!(V&&D&&q.reference!==X.reference||W.reference!==he.reference)}}),K=de.sortMap([...H],ne=>S.stringifyLocator(ne));return{selection:K.filter(ne=>L.length===0||L.some(q=>q(ne))),sortedLookup:K}},{selection:u,sortedLookup:g}=c({all:this.all,recursive:this.recursive});if(u.length===0)throw new me("No package matched your request");let f=new Map;if(this.dependents)for(let b of g)for(let R of b.dependencies.values()){let H=r.storedResolutions.get(R.descriptorHash);if(typeof H=="undefined")throw new Error("Assertion failed: Expected the resolution to be registered");de.getArrayWithDefault(f,H).push(b)}let h=new Map;for(let b of g){if(!S.isVirtualLocator(b))continue;let R=S.devirtualizeLocator(b);de.getArrayWithDefault(h,R.locatorHash).push(b)}let p={},d={children:p},m=e.makeFetcher(),I={project:r,fetcher:m,cache:n,checksums:r.storedChecksums,report:new ei,cacheOptions:{skipIntegrityCheck:!0},skipIntegrityCheck:!0},B=[async(b,R,H)=>{var J,ne;if(!R.has("manifest"))return;let L=await m.fetch(b,I),K;try{K=await Ze.find(L.prefixPath,{baseFs:L.packageFs})}finally{(J=L.releaseFs)==null||J.call(L)}H("Manifest",{License:ue.tuple(ue.Type.NO_HINT,K.license),Homepage:ue.tuple(ue.Type.URL,(ne=K.raw.homepage)!=null?ne:null)})},async(b,R,H)=>{var A;if(!R.has("cache"))return;let L={mockedPackages:r.disabledLocators,unstablePackages:r.conditionalLocators},K=(A=r.storedChecksums.get(b.locatorHash))!=null?A:null,J=n.getLocatorPath(b,K,L),ne;if(J!==null)try{ne=T.statSync(J)}catch{}let q=typeof ne!="undefined"?[ne.size,ue.Type.SIZE]:void 0;H("Cache",{Checksum:ue.tuple(ue.Type.NO_HINT,K),Path:ue.tuple(ue.Type.PATH,J),Size:q})}];for(let b of u){let R=S.isVirtualLocator(b);if(!this.virtuals&&R)continue;let H={},L={value:[b,ue.Type.LOCATOR],children:H};if(p[S.stringifyLocator(b)]=L,this.nameOnly){delete L.children;continue}let K=h.get(b.locatorHash);typeof K!="undefined"&&(H.Instances={label:"Instances",value:ue.tuple(ue.Type.NUMBER,K.length)}),H.Version={label:"Version",value:ue.tuple(ue.Type.NO_HINT,b.version)};let J=(q,A)=>{let V={};if(H[q]=V,Array.isArray(A))V.children=A.map(W=>({value:W}));else{let W={};V.children=W;for(let[X,F]of Object.entries(A))typeof F!="undefined"&&(W[X]={label:X,value:F})}};if(!R){for(let q of B)await q(b,s,J);await e.triggerHook(q=>q.fetchPackageInfo,b,s,J)}b.bin.size>0&&!R&&J("Exported Binaries",[...b.bin.keys()].map(q=>ue.tuple(ue.Type.PATH,q)));let ne=f.get(b.locatorHash);typeof ne!="undefined"&&ne.length>0&&J("Dependents",ne.map(q=>ue.tuple(ue.Type.LOCATOR,q))),b.dependencies.size>0&&!R&&J("Dependencies",[...b.dependencies.values()].map(q=>{var W;let A=r.storedResolutions.get(q.descriptorHash),V=typeof A!="undefined"&&(W=r.storedPackages.get(A))!=null?W:null;return ue.tuple(ue.Type.RESOLUTION,{descriptor:q,locator:V})})),b.peerDependencies.size>0&&R&&J("Peer dependencies",[...b.peerDependencies.values()].map(q=>{var X,F;let A=b.dependencies.get(q.identHash),V=typeof A!="undefined"&&(X=r.storedResolutions.get(A.descriptorHash))!=null?X:null,W=V!==null&&(F=r.storedPackages.get(V))!=null?F:null;return ue.tuple(ue.Type.RESOLUTION,{descriptor:q,locator:W})}))}Hs.emitTree(d,{configuration:e,json:this.json,stdout:this.context.stdout,separators:this.nameOnly?0:2})}};yC.paths=[["info"]],yC.usage=ye.Usage({description:"see information related to packages",details:"\n This command prints various information related to the specified packages, accepting glob patterns.\n\n By default, if the locator reference is missing, Yarn will default to print the information about all the matching direct dependencies of the package for the active workspace. To instead print all versions of the package that are direct dependencies of any of your workspaces, use the `-A,--all` flag. Adding the `-R,--recursive` flag will also report transitive dependencies.\n\n Some fields will be hidden by default in order to keep the output readable, but can be selectively displayed by using additional options (`--dependents`, `--manifest`, `--virtuals`, ...) described in the option descriptions.\n\n Note that this command will only print the information directly related to the selected packages - if you wish to know why the package is there in the first place, use `yarn why` which will do just that (it also provides a `-R,--recursive` flag that may be of some help).\n ",examples:[["Show information about Lodash","$0 info lodash"]]});var Wae=yC;var W0=ie(ml());Ss();var wC=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.immutable=Y.Boolean("--immutable",{description:"Abort with an error exit code if the lockfile was to be modified"});this.immutableCache=Y.Boolean("--immutable-cache",{description:"Abort with an error exit code if the cache folder was to be modified"});this.checkCache=Y.Boolean("--check-cache",!1,{description:"Always refetch the packages and ensure that their checksums are consistent"});this.inlineBuilds=Y.Boolean("--inline-builds",{description:"Verbosely print the output of the build steps of dependencies"});this.mode=Y.String("--mode",{description:"Change what artifacts installs generate",validator:Yi(li)});this.cacheFolder=Y.String("--cache-folder",{hidden:!0});this.frozenLockfile=Y.Boolean("--frozen-lockfile",{hidden:!0});this.ignoreEngines=Y.Boolean("--ignore-engines",{hidden:!0});this.nonInteractive=Y.Boolean("--non-interactive",{hidden:!0});this.preferOffline=Y.Boolean("--prefer-offline",{hidden:!0});this.production=Y.Boolean("--production",{hidden:!0});this.registry=Y.String("--registry",{hidden:!0});this.silent=Y.Boolean("--silent",{hidden:!0});this.networkTimeout=Y.String("--network-timeout",{hidden:!0})}async execute(){var c;let e=await fe.find(this.context.cwd,this.context.plugins);typeof this.inlineBuilds!="undefined"&&e.useWithSource("",{enableInlineBuilds:this.inlineBuilds},e.startingCwd,{overwrite:!0});let r=!!process.env.FUNCTION_TARGET||!!process.env.GOOGLE_RUNTIME,i=async(u,{error:g})=>{let f=await Fe.start({configuration:e,stdout:this.context.stdout,includeFooter:!1},async h=>{g?h.reportError(z.DEPRECATED_CLI_SETTINGS,u):h.reportWarning(z.DEPRECATED_CLI_SETTINGS,u)});return f.hasErrors()?f.exitCode():null};if(typeof this.ignoreEngines!="undefined"){let u=await i("The --ignore-engines option is deprecated; engine checking isn't a core feature anymore",{error:!W0.default.VERCEL});if(u!==null)return u}if(typeof this.registry!="undefined"){let u=await i("The --registry option is deprecated; prefer setting npmRegistryServer in your .yarnrc.yml file",{error:!1});if(u!==null)return u}if(typeof this.preferOffline!="undefined"){let u=await i("The --prefer-offline flag is deprecated; use the --cached flag with 'yarn add' instead",{error:!W0.default.VERCEL});if(u!==null)return u}if(typeof this.production!="undefined"){let u=await i("The --production option is deprecated on 'install'; use 'yarn workspaces focus' instead",{error:!0});if(u!==null)return u}if(typeof this.nonInteractive!="undefined"){let u=await i("The --non-interactive option is deprecated",{error:!r});if(u!==null)return u}if(typeof this.frozenLockfile!="undefined"&&(await i("The --frozen-lockfile option is deprecated; use --immutable and/or --immutable-cache instead",{error:!1}),this.immutable=this.frozenLockfile),typeof this.cacheFolder!="undefined"){let u=await i("The cache-folder option has been deprecated; use rc settings instead",{error:!W0.default.NETLIFY});if(u!==null)return u}let n=(c=this.immutable)!=null?c:e.get("enableImmutableInstalls");if(e.projectCwd!==null){let u=await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout,includeFooter:!1},async g=>{await Y4e(e,n)&&(g.reportInfo(z.AUTOMERGE_SUCCESS,"Automatically fixed merge conflicts \u{1F44D}"),g.reportSeparator())});if(u.hasErrors())return u.exitCode()}if(e.projectCwd!==null&&typeof e.sources.get("nodeLinker")=="undefined"){let u=e.projectCwd,g;try{g=await T.readFilePromise(v.join(u,wt.lockfile),"utf8")}catch{}if(g==null?void 0:g.includes("yarn lockfile v1")){let f=await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout,includeFooter:!1},async h=>{h.reportInfo(z.AUTO_NM_SUCCESS,"Migrating from Yarn 1; automatically enabling the compatibility node-modules linker \u{1F44D}"),h.reportSeparator(),e.use("",{nodeLinker:"node-modules"},u,{overwrite:!0}),await fe.updateConfiguration(u,{nodeLinker:"node-modules"})});if(f.hasErrors())return f.exitCode()}}if(e.projectCwd!==null){let u=await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout,includeFooter:!1},async g=>{var f;((f=fe.telemetry)==null?void 0:f.isNew)&&(g.reportInfo(z.TELEMETRY_NOTICE,"Yarn will periodically gather anonymous telemetry: https://yarnpkg.com/advanced/telemetry"),g.reportInfo(z.TELEMETRY_NOTICE,`Run ${ue.pretty(e,"yarn config set --home enableTelemetry 0",ue.Type.CODE)} to disable`),g.reportSeparator())});if(u.hasErrors())return u.exitCode()}let{project:s,workspace:o}=await Ke.find(e,this.context.cwd),a=await Qt.find(e,{immutable:this.immutableCache,check:this.checkCache});if(!o)throw new rt(s.cwd,this.context.cwd);return await s.restoreInstallState({restoreResolutions:!1}),(await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout,includeLogs:!0},async u=>{await s.install({cache:a,report:u,immutable:n,mode:this.mode})})).exitCode()}};wC.paths=[["install"],ye.Default],wC.usage=ye.Usage({description:"install the project dependencies",details:` + This command sets up your project if needed. The installation is split into four different steps that each have their own characteristics: + + - **Resolution:** First the package manager will resolve your dependencies. The exact way a dependency version is privileged over another isn't standardized outside of the regular semver guarantees. If a package doesn't resolve to what you would expect, check that all dependencies are correctly declared (also check our website for more information: ). + + - **Fetch:** Then we download all the dependencies if needed, and make sure that they're all stored within our cache (check the value of \`cacheFolder\` in \`yarn config\` to see where the cache files are stored). + + - **Link:** Then we send the dependency tree information to internal plugins tasked with writing them on the disk in some form (for example by generating the .pnp.cjs file you might know). + + - **Build:** Once the dependency tree has been written on the disk, the package manager will now be free to run the build scripts for all packages that might need it, in a topological order compatible with the way they depend on one another. See https://yarnpkg.com/advanced/lifecycle-scripts for detail. + + Note that running this command is not part of the recommended workflow. Yarn supports zero-installs, which means that as long as you store your cache and your .pnp.cjs file inside your repository, everything will work without requiring any install right after cloning your repository or switching branches. + + If the \`--immutable\` option is set (defaults to true on CI), Yarn will abort with an error exit code if the lockfile was to be modified (other paths can be added using the \`immutablePatterns\` configuration setting). For backward compatibility we offer an alias under the name of \`--frozen-lockfile\`, but it will be removed in a later release. + + If the \`--immutable-cache\` option is set, Yarn will abort with an error exit code if the cache folder was to be modified (either because files would be added, or because they'd be removed). + + If the \`--check-cache\` option is set, Yarn will always refetch the packages and will ensure that their checksum matches what's 1/ described in the lockfile 2/ inside the existing cache files (if present). This is recommended as part of your CI workflow if you're both following the Zero-Installs model and accepting PRs from third-parties, as they'd otherwise have the ability to alter the checked-in packages before submitting them. + + If the \`--inline-builds\` option is set, Yarn will verbosely print the output of the build steps of your dependencies (instead of writing them into individual files). This is likely useful mostly for debug purposes only when using Docker-like environments. + + If the \`--mode=\` option is set, Yarn will change which artifacts are generated. The modes currently supported are: + + - \`skip-build\` will not run the build scripts at all. Note that this is different from setting \`enableScripts\` to false because the later will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run. + + - \`update-lockfile\` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost. + `,examples:[["Install the project","$0 install"],["Validate a project when using Zero-Installs","$0 install --immutable --immutable-cache"],["Validate a project when using Zero-Installs (slightly safer if you accept external PRs)","$0 install --immutable --immutable-cache --check-cache"]]});var zae=wC,q4e="|||||||",J4e=">>>>>>>",W4e="=======",Vae="<<<<<<<";async function Y4e(t,e){if(!t.projectCwd)return!1;let r=v.join(t.projectCwd,t.get("lockfileFilename"));if(!await T.existsPromise(r))return!1;let i=await T.readFilePromise(r,"utf8");if(!i.includes(Vae))return!1;if(e)throw new nt(z.AUTOMERGE_IMMUTABLE,"Cannot autofix a lockfile when running an immutable install");let[n,s]=z4e(i),o,a;try{o=Ii(n),a=Ii(s)}catch(c){throw new nt(z.AUTOMERGE_FAILED_TO_PARSE,"The individual variants of the lockfile failed to parse")}let l=P(P({},o),a);for(let[c,u]of Object.entries(l))typeof u=="string"&&delete l[c];return await T.changeFilePromise(r,Qa(l),{automaticNewlines:!0}),!0}function z4e(t){let e=[[],[]],r=t.split(/\r?\n/g),i=!1;for(;r.length>0;){let n=r.shift();if(typeof n=="undefined")throw new Error("Assertion failed: Some lines should remain");if(n.startsWith(Vae)){for(;r.length>0;){let s=r.shift();if(typeof s=="undefined")throw new Error("Assertion failed: Some lines should remain");if(s===W4e){i=!1;break}else if(i||s.startsWith(q4e)){i=!0;continue}else e[0].push(s)}for(;r.length>0;){let s=r.shift();if(typeof s=="undefined")throw new Error("Assertion failed: Some lines should remain");if(s.startsWith(J4e))break;e[1].push(s)}}else e[0].push(n),e[1].push(n)}return[e[0].join(` +`),e[1].join(` +`)]}var BC=class extends Be{constructor(){super(...arguments);this.all=Y.Boolean("-A,--all",!1,{description:"Link all workspaces belonging to the target project to the current one"});this.private=Y.Boolean("-p,--private",!1,{description:"Also link private workspaces belonging to the target project to the current one"});this.relative=Y.Boolean("-r,--relative",!1,{description:"Link workspaces using relative paths instead of absolute paths"});this.destination=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState({restoreResolutions:!1});let s=v.resolve(this.context.cwd,M.toPortablePath(this.destination)),o=await fe.find(s,this.context.plugins,{useRc:!1,strict:!1}),{project:a,workspace:l}=await Ke.find(o,s);if(r.cwd===a.cwd)throw new me("Invalid destination; Can't link the project to itself");if(!l)throw new rt(a.cwd,s);let c=r.topLevelWorkspace,u=[];if(this.all){for(let f of a.workspaces)f.manifest.name&&(!f.manifest.private||this.private)&&u.push(f);if(u.length===0)throw new me("No workspace found to be linked in the target project")}else{if(!l.manifest.name)throw new me("The target workspace doesn't have a name and thus cannot be linked");if(l.manifest.private&&!this.private)throw new me("The target workspace is marked private - use the --private flag to link it anyway");u.push(l)}for(let f of u){let h=S.stringifyIdent(f.locator),p=this.relative?v.relative(r.cwd,f.cwd):f.cwd;c.manifest.resolutions.push({pattern:{descriptor:{fullName:h}},reference:`portal:${p}`})}return(await Fe.start({configuration:e,stdout:this.context.stdout},async f=>{await r.install({cache:n,report:f})})).exitCode()}};BC.paths=[["link"]],BC.usage=ye.Usage({description:"connect the local project to another one",details:"\n This command will set a new `resolutions` field in the project-level manifest and point it to the workspace at the specified location (even if part of another project).\n ",examples:[["Register a remote workspace for use in the current project","$0 link ~/ts-loader"],["Register all workspaces from a remote project for use in the current project","$0 link ~/jest --all"]]});var _ae=BC;var QC=class extends Be{constructor(){super(...arguments);this.args=Y.Proxy()}async execute(){return this.cli.run(["exec","node",...this.args])}};QC.paths=[["node"]],QC.usage=ye.Usage({description:"run node with the hook already setup",details:` + This command simply runs Node. It also makes sure to call it in a way that's compatible with the current project (for example, on PnP projects the environment will be setup in such a way that PnP will be correctly injected into the environment). + + The Node process will use the exact same version of Node as the one used to run Yarn itself, which might be a good way to ensure that your commands always use a consistent Node version. + `,examples:[["Run a Node script","$0 node ./my-script.js"]]});var Xae=QC;var lAe=ie(require("os"));var rAe=ie(require("os"));var V4e="https://raw.githubusercontent.com/yarnpkg/berry/master/plugins.yml";async function Kc(t){let e=await Zt.get(V4e,{configuration:t});return Ii(e.toString())}var bC=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins);return(await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout},async i=>{let n=await Kc(e);for(let s of Object.entries(n)){let[l,o]=s,a=o,{experimental:c}=a,u=qr(a,["experimental"]);let g=l;c&&(g+=" [experimental]"),i.reportJson(P({name:l,experimental:c},u)),i.reportInfo(null,g)}})).exitCode()}};bC.paths=[["plugin","list"]],bC.usage=ye.Usage({category:"Plugin-related commands",description:"list the available official plugins",details:"\n This command prints the plugins available directly from the Yarn repository. Only those plugins can be referenced by name in `yarn plugin import`.\n ",examples:[["List the official plugins","$0 plugin list"]]});var Zae=bC;var $ae=ie(Or()),vC=class extends Be{constructor(){super(...arguments);this.onlyIfNeeded=Y.Boolean("--only-if-needed",!1,{description:"Only lock the Yarn version if it isn't already locked"});this.version=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins);if(e.get("yarnPath")&&this.onlyIfNeeded)return 0;let r=()=>{if(typeof Zr=="undefined")throw new me("The --install flag can only be used without explicit version specifier from the Yarn CLI");return`file://${process.argv[1]}`},i;if(this.version==="self")i=r();else if(this.version==="latest"||this.version==="berry"||this.version==="stable")i=`https://repo.yarnpkg.com/${await eAe(e,"stable")}/packages/yarnpkg-cli/bin/yarn.js`;else if(this.version==="canary")i=`https://repo.yarnpkg.com/${await eAe(e,"canary")}/packages/yarnpkg-cli/bin/yarn.js`;else if(this.version==="classic")i="https://nightly.yarnpkg.com/latest.js";else if(this.version.match(/^\.{0,2}[\\/]/)||M.isAbsolute(this.version))i=`file://${M.resolve(this.version)}`;else if(qt.satisfiesWithPrereleases(this.version,">=2.0.0"))i=`https://repo.yarnpkg.com/${this.version}/packages/yarnpkg-cli/bin/yarn.js`;else if(qt.satisfiesWithPrereleases(this.version,"^0.x || ^1.x"))i=`https://github.com/yarnpkg/yarn/releases/download/v${this.version}/yarn-${this.version}.js`;else if(qt.validRange(this.version))i=`https://repo.yarnpkg.com/${await _4e(e,this.version)}/packages/yarnpkg-cli/bin/yarn.js`;else throw new me(`Invalid version descriptor "${this.version}"`);return(await Fe.start({configuration:e,stdout:this.context.stdout,includeLogs:!this.context.quiet},async s=>{let o="file://",a;i.startsWith(o)?(s.reportInfo(z.UNNAMED,`Downloading ${ue.pretty(e,i,ps.URL)}`),a=await T.readFilePromise(M.toPortablePath(i.slice(o.length)))):(s.reportInfo(z.UNNAMED,`Retrieving ${ue.pretty(e,i,ps.PATH)}`),a=await Zt.get(i,{configuration:e})),await XN(e,null,a,{report:s})})).exitCode()}};vC.paths=[["set","version"]],vC.usage=ye.Usage({description:"lock the Yarn version used by the project",details:"\n This command will download a specific release of Yarn directly from the Yarn GitHub repository, will store it inside your project, and will change the `yarnPath` settings from your project `.yarnrc.yml` file to point to the new file.\n\n A very good use case for this command is to enforce the version of Yarn used by the any single member of your team inside a same project - by doing this you ensure that you have control on Yarn upgrades and downgrades (including on your deployment servers), and get rid of most of the headaches related to someone using a slightly different version and getting a different behavior than you.\n\n The version specifier can be:\n\n - a tag:\n - `latest` / `berry` / `stable` -> the most recent stable berry (`>=2.0.0`) release\n - `canary` -> the most recent canary (release candidate) berry (`>=2.0.0`) release\n - `classic` -> the most recent classic (`^0.x || ^1.x`) release\n\n - a semver range (e.g. `2.x`) -> the most recent version satisfying the range (limited to berry releases)\n\n - a semver version (e.g. `2.4.1`, `1.22.1`)\n\n - a local file referenced through either a relative or absolute path\n\n - `self` -> the version used to invoke the command\n ",examples:[["Download the latest release from the Yarn repository","$0 set version latest"],["Download the latest canary release from the Yarn repository","$0 set version canary"],["Download the latest classic release from the Yarn repository","$0 set version classic"],["Download the most recent Yarn 3 build","$0 set version 3.x"],["Download a specific Yarn 2 build","$0 set version 2.0.0-rc.30"],["Switch back to a specific Yarn 1 release","$0 set version 1.22.1"],["Use a release from the local filesystem","$0 set version ./yarn.cjs"],["Download the version used to invoke the command","$0 set version self"]]});var tAe=vC;async function _4e(t,e){let i=(await Zt.get("https://repo.yarnpkg.com/tags",{configuration:t,jsonResponse:!0})).tags.filter(n=>qt.satisfiesWithPrereleases(n,e));if(i.length===0)throw new me(`No matching release found for range ${ue.pretty(t,e,ue.Type.RANGE)}.`);return i[0]}async function eAe(t,e){let r=await Zt.get("https://repo.yarnpkg.com/tags",{configuration:t,jsonResponse:!0});if(!r.latest[e])throw new me(`Tag ${ue.pretty(t,e,ue.Type.RANGE)} not found`);return r.latest[e]}async function XN(t,e,r,{report:i}){var g;e===null&&await T.mktempPromise(async f=>{let h=v.join(f,"yarn.cjs");await T.writeFilePromise(h,r);let{stdout:p}=await hr.execvp(process.execPath,[M.fromPortablePath(h),"--version"],{cwd:f,env:_(P({},process.env),{YARN_IGNORE_PATH:"1"})});if(e=p.trim(),!$ae.default.valid(e))throw new Error(`Invalid semver version. ${ue.pretty(t,"yarn --version",ue.Type.CODE)} returned: +${e}`)});let n=(g=t.projectCwd)!=null?g:t.startingCwd,s=v.resolve(n,".yarn/releases"),o=v.resolve(s,`yarn-${e}.cjs`),a=v.relative(t.startingCwd,o),l=v.relative(n,o),c=t.get("yarnPath"),u=c===null||c.startsWith(`${s}/`);if(i.reportInfo(z.UNNAMED,`Saving the new release in ${ue.pretty(t,a,"magenta")}`),await T.removePromise(v.dirname(o)),await T.mkdirPromise(v.dirname(o),{recursive:!0}),await T.writeFilePromise(o,r,{mode:493}),u){await fe.updateConfiguration(n,{yarnPath:l});let f=await Ze.tryFind(n)||new Ze;e&&de.isTaggedYarnVersion(e)&&(f.packageManager=`yarn@${e}`);let h={};f.exportTo(h);let p=v.join(n,Ze.fileName),d=`${JSON.stringify(h,null,f.indent)} +`;await T.changeFilePromise(p,d,{automaticNewlines:!0})}}var X4e=/^[0-9]+$/;function iAe(t){return X4e.test(t)?`pull/${t}/head`:t}var Z4e=({repository:t,branch:e},r)=>[["git","init",M.fromPortablePath(r)],["git","remote","add","origin",t],["git","fetch","origin",iAe(e)],["git","reset","--hard","FETCH_HEAD"]],$4e=({branch:t})=>[["git","fetch","origin",iAe(t),"--force"],["git","reset","--hard","FETCH_HEAD"],["git","clean","-dfx"]],eze=({plugins:t,noMinify:e},r)=>[["yarn","build:cli",...new Array().concat(...t.map(i=>["--plugin",v.resolve(r,i)])),...e?["--no-minify"]:[],"|"]],SC=class extends Be{constructor(){super(...arguments);this.installPath=Y.String("--path",{description:"The path where the repository should be cloned to"});this.repository=Y.String("--repository","https://github.com/yarnpkg/berry.git",{description:"The repository that should be cloned"});this.branch=Y.String("--branch","master",{description:"The branch of the repository that should be cloned"});this.plugins=Y.Array("--plugin",[],{description:"An array of additional plugins that should be included in the bundle"});this.noMinify=Y.Boolean("--no-minify",!1,{description:"Build a bundle for development (debugging) - non-minified and non-mangled"});this.force=Y.Boolean("-f,--force",!1,{description:"Always clone the repository instead of trying to fetch the latest commits"});this.skipPlugins=Y.Boolean("--skip-plugins",!1,{description:"Skip updating the contrib plugins"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r}=await Ke.find(e,this.context.cwd),i=typeof this.installPath!="undefined"?v.resolve(this.context.cwd,M.toPortablePath(this.installPath)):v.resolve(M.toPortablePath((0,rAe.tmpdir)()),"yarnpkg-sources",mn.makeHash(this.repository).slice(0,6));return(await Fe.start({configuration:e,stdout:this.context.stdout},async s=>{await $N(this,{configuration:e,report:s,target:i}),s.reportSeparator(),s.reportInfo(z.UNNAMED,"Building a fresh bundle"),s.reportSeparator(),await xC(eze(this,i),{configuration:e,context:this.context,target:i}),s.reportSeparator();let o=v.resolve(i,"packages/yarnpkg-cli/bundles/yarn.js"),a=await T.readFilePromise(o);await XN(e,"sources",a,{report:s}),this.skipPlugins||await tze(this,{project:r,report:s,target:i})})).exitCode()}};SC.paths=[["set","version","from","sources"]],SC.usage=ye.Usage({description:"build Yarn from master",details:` + This command will clone the Yarn repository into a temporary folder, then build it. The resulting bundle will then be copied into the local project. + + By default, it also updates all contrib plugins to the same commit the bundle is built from. This behavior can be disabled by using the \`--skip-plugins\` flag. + `,examples:[["Build Yarn from master","$0 set version from sources"]]});var nAe=SC;async function xC(t,{configuration:e,context:r,target:i}){for(let[n,...s]of t){let o=s[s.length-1]==="|";if(o&&s.pop(),o)await hr.pipevp(n,s,{cwd:i,stdin:r.stdin,stdout:r.stdout,stderr:r.stderr,strict:!0});else{r.stdout.write(`${ue.pretty(e,` $ ${[n,...s].join(" ")}`,"grey")} +`);try{await hr.execvp(n,s,{cwd:i,strict:!0})}catch(a){throw r.stdout.write(a.stdout||a.stack),a}}}}async function $N(t,{configuration:e,report:r,target:i}){let n=!1;if(!t.force&&T.existsSync(v.join(i,".git"))){r.reportInfo(z.UNNAMED,"Fetching the latest commits"),r.reportSeparator();try{await xC($4e(t),{configuration:e,context:t.context,target:i}),n=!0}catch(s){r.reportSeparator(),r.reportWarning(z.UNNAMED,"Repository update failed; we'll try to regenerate it")}}n||(r.reportInfo(z.UNNAMED,"Cloning the remote repository"),r.reportSeparator(),await T.removePromise(i),await T.mkdirPromise(i,{recursive:!0}),await xC(Z4e(t,i),{configuration:e,context:t.context,target:i}))}async function tze(t,{project:e,report:r,target:i}){let n=await Kc(e.configuration),s=new Set(Object.keys(n));for(let o of e.configuration.plugins.keys())!s.has(o)||await ZN(o,t,{project:e,report:r,target:i})}var sAe=ie(Or()),oAe=ie(require("url")),aAe=ie(require("vm"));var kC=class extends Be{constructor(){super(...arguments);this.name=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins);return(await Fe.start({configuration:e,stdout:this.context.stdout},async i=>{let{project:n}=await Ke.find(e,this.context.cwd),s,o;if(this.name.match(/^\.{0,2}[\\/]/)||M.isAbsolute(this.name)){let a=v.resolve(this.context.cwd,M.toPortablePath(this.name));i.reportInfo(z.UNNAMED,`Reading ${ue.pretty(e,a,ue.Type.PATH)}`),s=v.relative(n.cwd,a),o=await T.readFilePromise(a)}else{let a;if(this.name.match(/^https?:/)){try{new oAe.URL(this.name)}catch{throw new nt(z.INVALID_PLUGIN_REFERENCE,`Plugin specifier "${this.name}" is neither a plugin name nor a valid url`)}s=this.name,a=this.name}else{let l=S.parseLocator(this.name.replace(/^((@yarnpkg\/)?plugin-)?/,"@yarnpkg/plugin-"));if(l.reference!=="unknown"&&!sAe.default.valid(l.reference))throw new nt(z.UNNAMED,"Official plugins only accept strict version references. Use an explicit URL if you wish to download them from another location.");let c=S.stringifyIdent(l),u=await Kc(e);if(!Object.prototype.hasOwnProperty.call(u,c))throw new nt(z.PLUGIN_NAME_NOT_FOUND,`Couldn't find a plugin named "${c}" on the remote registry. Note that only the plugins referenced on our website (https://github.com/yarnpkg/berry/blob/master/plugins.yml) can be referenced by their name; any other plugin will have to be referenced through its public url (for example https://github.com/yarnpkg/berry/raw/master/packages/plugin-typescript/bin/%40yarnpkg/plugin-typescript.js).`);s=c,a=u[c].url,l.reference!=="unknown"?a=a.replace(/\/master\//,`/${c}/${l.reference}/`):Zr!==null&&(a=a.replace(/\/master\//,`/@yarnpkg/cli/${Zr}/`))}i.reportInfo(z.UNNAMED,`Downloading ${ue.pretty(e,a,"green")}`),o=await Zt.get(a,{configuration:e})}await eL(s,o,{project:n,report:i})})).exitCode()}};kC.paths=[["plugin","import"]],kC.usage=ye.Usage({category:"Plugin-related commands",description:"download a plugin",details:` + This command downloads the specified plugin from its remote location and updates the configuration to reference it in further CLI invocations. + + Three types of plugin references are accepted: + + - If the plugin is stored within the Yarn repository, it can be referenced by name. + - Third-party plugins can be referenced directly through their public urls. + - Local plugins can be referenced by their path on the disk. + + Plugins cannot be downloaded from the npm registry, and aren't allowed to have dependencies (they need to be bundled into a single file, possibly thanks to the \`@yarnpkg/builder\` package). + `,examples:[['Download and activate the "@yarnpkg/plugin-exec" plugin',"$0 plugin import @yarnpkg/plugin-exec"],['Download and activate the "@yarnpkg/plugin-exec" plugin (shorthand)',"$0 plugin import exec"],["Download and activate a community plugin","$0 plugin import https://example.org/path/to/plugin.js"],["Activate a local plugin","$0 plugin import ./path/to/plugin.js"]]});var AAe=kC;async function eL(t,e,{project:r,report:i}){let{configuration:n}=r,s={},o={exports:s};(0,aAe.runInNewContext)(e.toString(),{module:o,exports:s});let a=o.exports.name,l=`.yarn/plugins/${a}.cjs`,c=v.resolve(r.cwd,l);i.reportInfo(z.UNNAMED,`Saving the new plugin in ${ue.pretty(n,l,"magenta")}`),await T.mkdirPromise(v.dirname(c),{recursive:!0}),await T.writeFilePromise(c,e);let u={path:l,spec:t};await fe.updateConfiguration(r.cwd,g=>{let f=[],h=!1;for(let p of g.plugins||[]){let d=typeof p!="string"?p.path:p,m=v.resolve(r.cwd,M.toPortablePath(d)),{name:I}=de.dynamicRequire(m);I!==a?f.push(p):(f.push(u),h=!0)}return h||f.push(u),_(P({},g),{plugins:f})})}var rze=({pluginName:t,noMinify:e},r)=>[["yarn",`build:${t}`,...e?["--no-minify"]:[],"|"]],PC=class extends Be{constructor(){super(...arguments);this.installPath=Y.String("--path",{description:"The path where the repository should be cloned to"});this.repository=Y.String("--repository","https://github.com/yarnpkg/berry.git",{description:"The repository that should be cloned"});this.branch=Y.String("--branch","master",{description:"The branch of the repository that should be cloned"});this.noMinify=Y.Boolean("--no-minify",!1,{description:"Build a plugin for development (debugging) - non-minified and non-mangled"});this.force=Y.Boolean("-f,--force",!1,{description:"Always clone the repository instead of trying to fetch the latest commits"});this.name=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=typeof this.installPath!="undefined"?v.resolve(this.context.cwd,M.toPortablePath(this.installPath)):v.resolve(M.toPortablePath((0,lAe.tmpdir)()),"yarnpkg-sources",mn.makeHash(this.repository).slice(0,6));return(await Fe.start({configuration:e,stdout:this.context.stdout},async n=>{let{project:s}=await Ke.find(e,this.context.cwd),o=S.parseIdent(this.name.replace(/^((@yarnpkg\/)?plugin-)?/,"@yarnpkg/plugin-")),a=S.stringifyIdent(o),l=await Kc(e);if(!Object.prototype.hasOwnProperty.call(l,a))throw new nt(z.PLUGIN_NAME_NOT_FOUND,`Couldn't find a plugin named "${a}" on the remote registry. Note that only the plugins referenced on our website (https://github.com/yarnpkg/berry/blob/master/plugins.yml) can be built and imported from sources.`);let c=a;await $N(this,{configuration:e,report:n,target:r}),await ZN(c,this,{project:s,report:n,target:r})})).exitCode()}};PC.paths=[["plugin","import","from","sources"]],PC.usage=ye.Usage({category:"Plugin-related commands",description:"build a plugin from sources",details:` + This command clones the Yarn repository into a temporary folder, builds the specified contrib plugin and updates the configuration to reference it in further CLI invocations. + + The plugins can be referenced by their short name if sourced from the official Yarn repository. + `,examples:[['Build and activate the "@yarnpkg/plugin-exec" plugin',"$0 plugin import from sources @yarnpkg/plugin-exec"],['Build and activate the "@yarnpkg/plugin-exec" plugin (shorthand)',"$0 plugin import from sources exec"]]});var cAe=PC;async function ZN(t,{context:e,noMinify:r},{project:i,report:n,target:s}){let o=t.replace(/@yarnpkg\//,""),{configuration:a}=i;n.reportSeparator(),n.reportInfo(z.UNNAMED,`Building a fresh ${o}`),n.reportSeparator(),await xC(rze({pluginName:o,noMinify:r},s),{configuration:a,context:e,target:s}),n.reportSeparator();let l=v.resolve(s,`packages/${o}/bundles/${t}.js`),c=await T.readFilePromise(l);await eL(t,c,{project:i,report:n})}var DC=class extends Be{constructor(){super(...arguments);this.name=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r}=await Ke.find(e,this.context.cwd);return(await Fe.start({configuration:e,stdout:this.context.stdout},async n=>{let s=this.name,o=S.parseIdent(s);if(!e.plugins.has(s))throw new me(`${S.prettyIdent(e,o)} isn't referenced by the current configuration`);let a=`.yarn/plugins/${s}.cjs`,l=v.resolve(r.cwd,a);T.existsSync(l)&&(n.reportInfo(z.UNNAMED,`Removing ${ue.pretty(e,a,ue.Type.PATH)}...`),await T.removePromise(l)),n.reportInfo(z.UNNAMED,"Updating the configuration..."),await fe.updateConfiguration(r.cwd,c=>{if(!Array.isArray(c.plugins))return c;let u=c.plugins.filter(g=>g.path!==a);return c.plugins.length===u.length?c:_(P({},c),{plugins:u})})})).exitCode()}};DC.paths=[["plugin","remove"]],DC.usage=ye.Usage({category:"Plugin-related commands",description:"remove a plugin",details:` + This command deletes the specified plugin from the .yarn/plugins folder and removes it from the configuration. + + **Note:** The plugins have to be referenced by their name property, which can be obtained using the \`yarn plugin runtime\` command. Shorthands are not allowed. + `,examples:[["Remove a plugin imported from the Yarn repository","$0 plugin remove @yarnpkg/plugin-typescript"],["Remove a plugin imported from a local file","$0 plugin remove my-local-plugin"]]});var uAe=DC;var RC=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins);return(await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout},async i=>{for(let n of e.plugins.keys()){let s=this.context.plugins.plugins.has(n),o=n;s&&(o+=" [builtin]"),i.reportJson({name:n,builtin:s}),i.reportInfo(null,`${o}`)}})).exitCode()}};RC.paths=[["plugin","runtime"]],RC.usage=ye.Usage({category:"Plugin-related commands",description:"list the active plugins",details:` + This command prints the currently active plugins. Will be displayed both builtin plugins and external plugins. + `,examples:[["List the currently active plugins","$0 plugin runtime"]]});var gAe=RC;var FC=class extends Be{constructor(){super(...arguments);this.idents=Y.Rest()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);let s=new Set;for(let a of this.idents)s.add(S.parseIdent(a).identHash);if(await r.restoreInstallState({restoreResolutions:!1}),await r.resolveEverything({cache:n,report:new ei}),s.size>0)for(let a of r.storedPackages.values())s.has(a.identHash)&&r.storedBuildState.delete(a.locatorHash);else r.storedBuildState.clear();return(await Fe.start({configuration:e,stdout:this.context.stdout,includeLogs:!this.context.quiet},async a=>{await r.install({cache:n,report:a})})).exitCode()}};FC.paths=[["rebuild"]],FC.usage=ye.Usage({description:"rebuild the project's native packages",details:` + This command will automatically cause Yarn to forget about previous compilations of the given packages and to run them again. + + Note that while Yarn forgets the compilation, the previous artifacts aren't erased from the filesystem and may affect the next builds (in good or bad). To avoid this, you may remove the .yarn/unplugged folder, or any other relevant location where packages might have been stored (Yarn may offer a way to do that automatically in the future). + + By default all packages will be rebuilt, but you can filter the list by specifying the names of the packages you want to clear from memory. + `,examples:[["Rebuild all packages","$0 rebuild"],["Rebuild fsevents only","$0 rebuild fsevents"]]});var fAe=FC;var tL=ie(Nn());Ss();var NC=class extends Be{constructor(){super(...arguments);this.all=Y.Boolean("-A,--all",!1,{description:"Apply the operation to all workspaces from the current project"});this.mode=Y.String("--mode",{description:"Change what artifacts installs generate",validator:Yi(li)});this.patterns=Y.Rest()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState({restoreResolutions:!1});let s=this.all?r.workspaces:[i],o=[vr.REGULAR,vr.DEVELOPMENT,vr.PEER],a=[],l=!1,c=[];for(let h of this.patterns){let p=!1,d=S.parseIdent(h);for(let m of s){let I=[...m.manifest.peerDependenciesMeta.keys()];for(let B of(0,tL.default)(I,h))m.manifest.peerDependenciesMeta.delete(B),l=!0,p=!0;for(let B of o){let b=m.manifest.getForScope(B),R=[...b.values()].map(H=>S.stringifyIdent(H));for(let H of(0,tL.default)(R,S.stringifyIdent(d))){let{identHash:L}=S.parseIdent(H),K=b.get(L);if(typeof K=="undefined")throw new Error("Assertion failed: Expected the descriptor to be registered");m.manifest[B].delete(L),c.push([m,B,K]),l=!0,p=!0}}}p||a.push(h)}let u=a.length>1?"Patterns":"Pattern",g=a.length>1?"don't":"doesn't",f=this.all?"any":"this";if(a.length>0)throw new me(`${u} ${ue.prettyList(e,a,ps.CODE)} ${g} match any packages referenced by ${f} workspace`);return l?(await e.triggerMultipleHooks(p=>p.afterWorkspaceDependencyRemoval,c),(await Fe.start({configuration:e,stdout:this.context.stdout},async p=>{await r.install({cache:n,report:p,mode:this.mode})})).exitCode()):0}};NC.paths=[["remove"]],NC.usage=ye.Usage({description:"remove dependencies from the project",details:` + This command will remove the packages matching the specified patterns from the current workspace. + + If the \`--mode=\` option is set, Yarn will change which artifacts are generated. The modes currently supported are: + + - \`skip-build\` will not run the build scripts at all. Note that this is different from setting \`enableScripts\` to false because the later will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run. + + - \`update-lockfile\` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost. + + This command accepts glob patterns as arguments (if valid Idents and supported by [micromatch](https://github.com/micromatch/micromatch)). Make sure to escape the patterns, to prevent your own shell from trying to expand them. + `,examples:[["Remove a dependency from the current project","$0 remove lodash"],["Remove a dependency from all workspaces at once","$0 remove lodash --all"],["Remove all dependencies starting with `eslint-`","$0 remove 'eslint-*'"],["Remove all dependencies with the `@babel` scope","$0 remove '@babel/*'"],["Remove all dependencies matching `react-dom` or `react-helmet`","$0 remove 'react-{dom,helmet}'"]]});var hAe=NC;var pAe=ie(require("util")),z0=class extends Be{async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);return(await Fe.start({configuration:e,stdout:this.context.stdout},async s=>{let o=i.manifest.scripts,a=de.sortMap(o.keys(),u=>u),l={breakLength:Infinity,colors:e.get("enableColors"),maxArrayLength:2},c=a.reduce((u,g)=>Math.max(u,g.length),0);for(let[u,g]of o.entries())s.reportInfo(null,`${u.padEnd(c," ")} ${(0,pAe.inspect)(g,l)}`)})).exitCode()}};z0.paths=[["run"]];var dAe=z0;var LC=class extends Be{constructor(){super(...arguments);this.inspect=Y.String("--inspect",!1,{tolerateBoolean:!0,description:"Forwarded to the underlying Node process when executing a binary"});this.inspectBrk=Y.String("--inspect-brk",!1,{tolerateBoolean:!0,description:"Forwarded to the underlying Node process when executing a binary"});this.topLevel=Y.Boolean("-T,--top-level",!1,{description:"Check the root workspace for scripts and/or binaries instead of the current one"});this.binariesOnly=Y.Boolean("-B,--binaries-only",!1,{description:"Ignore any user defined scripts and only check for binaries"});this.silent=Y.Boolean("--silent",{hidden:!0});this.scriptName=Y.String();this.args=Y.Proxy()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i,locator:n}=await Ke.find(e,this.context.cwd);await r.restoreInstallState();let s=this.topLevel?r.topLevelWorkspace.anchoredLocator:n;if(!this.binariesOnly&&await Kt.hasPackageScript(s,this.scriptName,{project:r}))return await Kt.executePackageScript(s,this.scriptName,this.args,{project:r,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr});let o=await Kt.getPackageAccessibleBinaries(s,{project:r});if(o.get(this.scriptName)){let l=[];return this.inspect&&(typeof this.inspect=="string"?l.push(`--inspect=${this.inspect}`):l.push("--inspect")),this.inspectBrk&&(typeof this.inspectBrk=="string"?l.push(`--inspect-brk=${this.inspectBrk}`):l.push("--inspect-brk")),await Kt.executePackageAccessibleBinary(s,this.scriptName,this.args,{cwd:this.context.cwd,project:r,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr,nodeArgs:l,packageAccessibleBinaries:o})}if(!this.topLevel&&!this.binariesOnly&&i&&this.scriptName.includes(":")){let c=(await Promise.all(r.workspaces.map(async u=>u.manifest.scripts.has(this.scriptName)?u:null))).filter(u=>u!==null);if(c.length===1)return await Kt.executeWorkspaceScript(c[0],this.scriptName,this.args,{stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr})}if(this.topLevel)throw this.scriptName==="node-gyp"?new me(`Couldn't find a script name "${this.scriptName}" in the top-level (used by ${S.prettyLocator(e,n)}). This typically happens because some package depends on "node-gyp" to build itself, but didn't list it in their dependencies. To fix that, please run "yarn add node-gyp" into your top-level workspace. You also can open an issue on the repository of the specified package to suggest them to use an optional peer dependency.`):new me(`Couldn't find a script name "${this.scriptName}" in the top-level (used by ${S.prettyLocator(e,n)}).`);{if(this.scriptName==="global")throw new me("The 'yarn global' commands have been removed in 2.x - consider using 'yarn dlx' or a third-party plugin instead");let l=[this.scriptName].concat(this.args);for(let[c,u]of Yg)for(let g of u)if(l.length>=g.length&&JSON.stringify(l.slice(0,g.length))===JSON.stringify(g))throw new me(`Couldn't find a script named "${this.scriptName}", but a matching command can be found in the ${c} plugin. You can install it with "yarn plugin import ${c}".`);throw new me(`Couldn't find a script named "${this.scriptName}".`)}}};LC.paths=[["run"]],LC.usage=ye.Usage({description:"run a script defined in the package.json",details:` + This command will run a tool. The exact tool that will be executed will depend on the current state of your workspace: + + - If the \`scripts\` field from your local package.json contains a matching script name, its definition will get executed. + + - Otherwise, if one of the local workspace's dependencies exposes a binary with a matching name, this binary will get executed. + + - Otherwise, if the specified name contains a colon character and if one of the workspaces in the project contains exactly one script with a matching name, then this script will get executed. + + Whatever happens, the cwd of the spawned process will be the workspace that declares the script (which makes it possible to call commands cross-workspaces using the third syntax). + `,examples:[["Run the tests from the local workspace","$0 run test"],['Same thing, but without the "run" keyword',"$0 test"],["Inspect Webpack while running","$0 run --inspect-brk webpack"]]});var CAe=LC;var TC=class extends Be{constructor(){super(...arguments);this.save=Y.Boolean("-s,--save",!1,{description:"Persist the resolution inside the top-level manifest"});this.descriptor=Y.String();this.resolution=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(await r.restoreInstallState({restoreResolutions:!1}),!i)throw new rt(r.cwd,this.context.cwd);let s=S.parseDescriptor(this.descriptor,!0),o=S.makeDescriptor(s,this.resolution);return r.storedDescriptors.set(s.descriptorHash,s),r.storedDescriptors.set(o.descriptorHash,o),r.resolutionAliases.set(s.descriptorHash,o.descriptorHash),(await Fe.start({configuration:e,stdout:this.context.stdout},async l=>{await r.install({cache:n,report:l})})).exitCode()}};TC.paths=[["set","resolution"]],TC.usage=ye.Usage({description:"enforce a package resolution",details:'\n This command updates the resolution table so that `descriptor` is resolved by `resolution`.\n\n Note that by default this command only affect the current resolution table - meaning that this "manual override" will disappear if you remove the lockfile, or if the package disappear from the table. If you wish to make the enforced resolution persist whatever happens, add the `-s,--save` flag which will also edit the `resolutions` field from your top-level manifest.\n\n Note that no attempt is made at validating that `resolution` is a valid resolution entry for `descriptor`.\n ',examples:[["Force all instances of lodash@npm:^1.2.3 to resolve to 1.5.0","$0 set resolution lodash@npm:^1.2.3 1.5.0"]]});var mAe=TC;var EAe=ie(Nn()),MC=class extends Be{constructor(){super(...arguments);this.all=Y.Boolean("-A,--all",!1,{description:"Unlink all workspaces belonging to the target project from the current one"});this.leadingArguments=Y.Rest()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);let s=r.topLevelWorkspace,o=new Set;if(this.leadingArguments.length===0&&this.all)for(let{pattern:l,reference:c}of s.manifest.resolutions)c.startsWith("portal:")&&o.add(l.descriptor.fullName);if(this.leadingArguments.length>0)for(let l of this.leadingArguments){let c=v.resolve(this.context.cwd,M.toPortablePath(l));if(de.isPathLike(l)){let u=await fe.find(c,this.context.plugins,{useRc:!1,strict:!1}),{project:g,workspace:f}=await Ke.find(u,c);if(!f)throw new rt(g.cwd,c);if(this.all){for(let h of g.workspaces)h.manifest.name&&o.add(S.stringifyIdent(h.locator));if(o.size===0)throw new me("No workspace found to be unlinked in the target project")}else{if(!f.manifest.name)throw new me("The target workspace doesn't have a name and thus cannot be unlinked");o.add(S.stringifyIdent(f.locator))}}else{let u=[...s.manifest.resolutions.map(({pattern:g})=>g.descriptor.fullName)];for(let g of(0,EAe.default)(u,l))o.add(g)}}return s.manifest.resolutions=s.manifest.resolutions.filter(({pattern:l})=>!o.has(l.descriptor.fullName)),(await Fe.start({configuration:e,stdout:this.context.stdout},async l=>{await r.install({cache:n,report:l})})).exitCode()}};MC.paths=[["unlink"]],MC.usage=ye.Usage({description:"disconnect the local project from another one",details:` + This command will remove any resolutions in the project-level manifest that would have been added via a yarn link with similar arguments. + `,examples:[["Unregister a remote workspace in the current project","$0 unlink ~/ts-loader"],["Unregister all workspaces from a remote project in the current project","$0 unlink ~/jest --all"],["Unregister all previously linked workspaces","$0 unlink --all"],["Unregister all workspaces matching a glob","$0 unlink '@babel/*' 'pkg-{a,b}'"]]});var IAe=MC;var yAe=ie(aC()),rL=ie(Nn());Ss();var uf=class extends Be{constructor(){super(...arguments);this.interactive=Y.Boolean("-i,--interactive",{description:"Offer various choices, depending on the detected upgrade paths"});this.exact=Y.Boolean("-E,--exact",!1,{description:"Don't use any semver modifier on the resolved range"});this.tilde=Y.Boolean("-T,--tilde",!1,{description:"Use the `~` semver modifier on the resolved range"});this.caret=Y.Boolean("-C,--caret",!1,{description:"Use the `^` semver modifier on the resolved range"});this.recursive=Y.Boolean("-R,--recursive",!1,{description:"Resolve again ALL resolutions for those packages"});this.mode=Y.String("--mode",{description:"Change what artifacts installs generate",validator:Yi(li)});this.patterns=Y.Rest()}async execute(){return this.recursive?await this.executeUpRecursive():await this.executeUpClassic()}async executeUpRecursive(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState({restoreResolutions:!1});let s=[...r.storedDescriptors.values()],o=s.map(u=>S.stringifyIdent(u)),a=new Set;for(let u of this.patterns){if(S.parseDescriptor(u).range!=="unknown")throw new me("Ranges aren't allowed when using --recursive");for(let g of(0,rL.default)(o,u)){let f=S.parseIdent(g);a.add(f.identHash)}}let l=s.filter(u=>a.has(u.identHash));for(let u of l)r.storedDescriptors.delete(u.descriptorHash),r.storedResolutions.delete(u.descriptorHash);return(await Fe.start({configuration:e,stdout:this.context.stdout},async u=>{await r.install({cache:n,report:u})})).exitCode()}async executeUpClassic(){var d;let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState({restoreResolutions:!1});let s=(d=this.interactive)!=null?d:e.get("preferInteractive"),o=AC(this,r),a=s?[Fr.KEEP,Fr.REUSE,Fr.PROJECT,Fr.LATEST]:[Fr.PROJECT,Fr.LATEST],l=[],c=[];for(let m of this.patterns){let I=!1,B=S.parseDescriptor(m);for(let b of r.workspaces)for(let R of[vr.REGULAR,vr.DEVELOPMENT]){let L=[...b.manifest.getForScope(R).values()].map(K=>S.stringifyIdent(K));for(let K of(0,rL.default)(L,S.stringifyIdent(B))){let J=S.parseIdent(K),ne=b.manifest[R].get(J.identHash);if(typeof ne=="undefined")throw new Error("Assertion failed: Expected the descriptor to be registered");let q=S.makeDescriptor(J,B.range);l.push(Promise.resolve().then(async()=>[b,R,ne,await lC(q,{project:r,workspace:b,cache:n,target:R,modifier:o,strategies:a})])),I=!0}}I||c.push(m)}if(c.length>1)throw new me(`Patterns ${ue.prettyList(e,c,ps.CODE)} don't match any packages referenced by any workspace`);if(c.length>0)throw new me(`Pattern ${ue.prettyList(e,c,ps.CODE)} doesn't match any packages referenced by any workspace`);let u=await Promise.all(l),g=await Fa.start({configuration:e,stdout:this.context.stdout,suggestInstall:!1},async m=>{for(let[,,I,{suggestions:B,rejections:b}]of u){let R=B.filter(H=>H.descriptor!==null);if(R.length===0){let[H]=b;if(typeof H=="undefined")throw new Error("Assertion failed: Expected an error to have been set");let L=this.cli.error(H);r.configuration.get("enableNetwork")?m.reportError(z.CANT_SUGGEST_RESOLUTIONS,`${S.prettyDescriptor(e,I)} can't be resolved to a satisfying range + +${L}`):m.reportError(z.CANT_SUGGEST_RESOLUTIONS,`${S.prettyDescriptor(e,I)} can't be resolved to a satisfying range (note: network resolution has been disabled) + +${L}`)}else R.length>1&&!s&&m.reportError(z.CANT_SUGGEST_RESOLUTIONS,`${S.prettyDescriptor(e,I)} has multiple possible upgrade strategies; use -i to disambiguate manually`)}});if(g.hasErrors())return g.exitCode();let f=!1,h=[];for(let[m,I,,{suggestions:B}]of u){let b,R=B.filter(J=>J.descriptor!==null),H=R[0].descriptor,L=R.every(J=>S.areDescriptorsEqual(J.descriptor,H));R.length===1||L?b=H:(f=!0,{answer:b}=await(0,yAe.prompt)({type:"select",name:"answer",message:`Which range to you want to use in ${S.prettyWorkspace(e,m)} \u276F ${I}?`,choices:B.map(({descriptor:J,name:ne,reason:q})=>J?{name:ne,hint:q,descriptor:J}:{name:ne,hint:q,disabled:!0}),onCancel:()=>process.exit(130),result(J){return this.find(J,"descriptor")},stdin:this.context.stdin,stdout:this.context.stdout}));let K=m.manifest[I].get(b.identHash);if(typeof K=="undefined")throw new Error("Assertion failed: This descriptor should have a matching entry");if(K.descriptorHash!==b.descriptorHash)m.manifest[I].set(b.identHash,b),h.push([m,I,K,b]);else{let J=e.makeResolver(),ne={project:r,resolver:J},q=J.bindDescriptor(K,m.anchoredLocator,ne);r.forgetResolution(q)}}return await e.triggerMultipleHooks(m=>m.afterWorkspaceDependencyReplacement,h),f&&this.context.stdout.write(` +`),(await Fe.start({configuration:e,stdout:this.context.stdout},async m=>{await r.install({cache:n,report:m,mode:this.mode})})).exitCode()}};uf.paths=[["up"]],uf.usage=ye.Usage({description:"upgrade dependencies across the project",details:"\n This command upgrades the packages matching the list of specified patterns to their latest available version across the whole project (regardless of whether they're part of `dependencies` or `devDependencies` - `peerDependencies` won't be affected). This is a project-wide command: all workspaces will be upgraded in the process.\n\n If `-R,--recursive` is set the command will change behavior and no other switch will be allowed. When operating under this mode `yarn up` will force all ranges matching the selected packages to be resolved again (often to the highest available versions) before being stored in the lockfile. It however won't touch your manifests anymore, so depending on your needs you might want to run both `yarn up` and `yarn up -R` to cover all bases.\n\n If `-i,--interactive` is set (or if the `preferInteractive` settings is toggled on) the command will offer various choices, depending on the detected upgrade paths. Some upgrades require this flag in order to resolve ambiguities.\n\n The, `-C,--caret`, `-E,--exact` and `-T,--tilde` options have the same meaning as in the `add` command (they change the modifier used when the range is missing or a tag, and are ignored when the range is explicitly set).\n\n If the `--mode=` option is set, Yarn will change which artifacts are generated. The modes currently supported are:\n\n - `skip-build` will not run the build scripts at all. Note that this is different from setting `enableScripts` to false because the later will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run.\n\n - `update-lockfile` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost.\n\n Generally you can see `yarn up` as a counterpart to what was `yarn upgrade --latest` in Yarn 1 (ie it ignores the ranges previously listed in your manifests), but unlike `yarn upgrade` which only upgraded dependencies in the current workspace, `yarn up` will upgrade all workspaces at the same time.\n\n This command accepts glob patterns as arguments (if valid Descriptors and supported by [micromatch](https://github.com/micromatch/micromatch)). Make sure to escape the patterns, to prevent your own shell from trying to expand them.\n\n **Note:** The ranges have to be static, only the package scopes and names can contain glob patterns.\n ",examples:[["Upgrade all instances of lodash to the latest release","$0 up lodash"],["Upgrade all instances of lodash to the latest release, but ask confirmation for each","$0 up lodash -i"],["Upgrade all instances of lodash to 1.2.3","$0 up lodash@1.2.3"],["Upgrade all instances of packages with the `@babel` scope to the latest release","$0 up '@babel/*'"],["Upgrade all instances of packages containing the word `jest` to the latest release","$0 up '*jest*'"],["Upgrade all instances of packages with the `@babel` scope to 7.0.0","$0 up '@babel/*@7.0.0'"]]}),uf.schema=[pv("recursive",Bl.Forbids,["interactive","exact","tilde","caret"],{ignore:[void 0,!1]})];var wAe=uf;var OC=class extends Be{constructor(){super(...arguments);this.recursive=Y.Boolean("-R,--recursive",!1,{description:"List, for each workspace, what are all the paths that lead to the dependency"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.peers=Y.Boolean("--peers",!1,{description:"Also print the peer dependencies that match the specified name"});this.package=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState();let n=S.parseIdent(this.package).identHash,s=this.recursive?nze(r,n,{configuration:e,peers:this.peers}):ize(r,n,{configuration:e,peers:this.peers});Hs.emitTree(s,{configuration:e,stdout:this.context.stdout,json:this.json,separators:1})}};OC.paths=[["why"]],OC.usage=ye.Usage({description:"display the reason why a package is needed",details:` + This command prints the exact reasons why a package appears in the dependency tree. + + If \`-R,--recursive\` is set, the listing will go in depth and will list, for each workspaces, what are all the paths that lead to the dependency. Note that the display is somewhat optimized in that it will not print the package listing twice for a single package, so if you see a leaf named "Foo" when looking for "Bar", it means that "Foo" already got printed higher in the tree. + `,examples:[["Explain why lodash is used in your project","$0 why lodash"]]});var BAe=OC;function ize(t,e,{configuration:r,peers:i}){let n=de.sortMap(t.storedPackages.values(),a=>S.stringifyLocator(a)),s={},o={children:s};for(let a of n){let l={},c=null;for(let u of a.dependencies.values()){if(!i&&a.peerDependencies.has(u.identHash))continue;let g=t.storedResolutions.get(u.descriptorHash);if(!g)throw new Error("Assertion failed: The resolution should have been registered");let f=t.storedPackages.get(g);if(!f)throw new Error("Assertion failed: The package should have been registered");if(f.identHash!==e)continue;if(c===null){let p=S.stringifyLocator(a);s[p]={value:[a,ue.Type.LOCATOR],children:l}}let h=S.stringifyLocator(f);l[h]={value:[{descriptor:u,locator:f},ue.Type.DEPENDENT]}}}return o}function nze(t,e,{configuration:r,peers:i}){let n=de.sortMap(t.workspaces,f=>S.stringifyLocator(f.anchoredLocator)),s=new Set,o=new Set,a=f=>{if(s.has(f.locatorHash))return o.has(f.locatorHash);if(s.add(f.locatorHash),f.identHash===e)return o.add(f.locatorHash),!0;let h=!1;f.identHash===e&&(h=!0);for(let p of f.dependencies.values()){if(!i&&f.peerDependencies.has(p.identHash))continue;let d=t.storedResolutions.get(p.descriptorHash);if(!d)throw new Error("Assertion failed: The resolution should have been registered");let m=t.storedPackages.get(d);if(!m)throw new Error("Assertion failed: The package should have been registered");a(m)&&(h=!0)}return h&&o.add(f.locatorHash),h};for(let f of n){let h=t.storedPackages.get(f.anchoredLocator.locatorHash);if(!h)throw new Error("Assertion failed: The package should have been registered");a(h)}let l=new Set,c={},u={children:c},g=(f,h,p)=>{if(!o.has(f.locatorHash))return;let d=p!==null?ue.tuple(ue.Type.DEPENDENT,{locator:f,descriptor:p}):ue.tuple(ue.Type.LOCATOR,f),m={},I={value:d,children:m},B=S.stringifyLocator(f);if(h[B]=I,!l.has(f.locatorHash)&&(l.add(f.locatorHash),!(p!==null&&t.tryWorkspaceByLocator(f))))for(let b of f.dependencies.values()){if(!i&&f.peerDependencies.has(b.identHash))continue;let R=t.storedResolutions.get(b.descriptorHash);if(!R)throw new Error("Assertion failed: The resolution should have been registered");let H=t.storedPackages.get(R);if(!H)throw new Error("Assertion failed: The package should have been registered");g(H,m,b)}};for(let f of n){let h=t.storedPackages.get(f.anchoredLocator.locatorHash);if(!h)throw new Error("Assertion failed: The package should have been registered");g(h,c,null)}return u}var fL={};it(fL,{default:()=>wze,gitUtils:()=>Uc});var Uc={};it(Uc,{TreeishProtocols:()=>vn,clone:()=>cL,fetchBase:()=>jAe,fetchChangedFiles:()=>YAe,fetchChangedWorkspaces:()=>Ize,fetchRoot:()=>GAe,isGitUrl:()=>ff,lsRemote:()=>HAe,normalizeLocator:()=>AL,normalizeRepoUrl:()=>KC,resolveUrl:()=>lL,splitRepoUrl:()=>UC});var oL=ie(OAe()),gf=ie(require("querystring")),aL=ie(Or()),KAe=ie(require("url"));function UAe(){return _(P({},process.env),{GIT_SSH_COMMAND:"ssh -o BatchMode=yes"})}var Eze=[/^ssh:/,/^git(?:\+[^:]+)?:/,/^(?:git\+)?https?:[^#]+\/[^#]+(?:\.git)(?:#.*)?$/,/^git@[^#]+\/[^#]+\.git(?:#.*)?$/,/^(?:github:|https:\/\/github\.com\/)?(?!\.{1,2}\/)([a-zA-Z._0-9-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z._0-9-]+?)(?:\.git)?(?:#.*)?$/,/^https:\/\/github\.com\/(?!\.{1,2}\/)([a-zA-Z0-9._-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z0-9._-]+?)\/tarball\/(.+)?$/],vn;(function(n){n.Commit="commit",n.Head="head",n.Tag="tag",n.Semver="semver"})(vn||(vn={}));function ff(t){return t?Eze.some(e=>!!t.match(e)):!1}function UC(t){t=KC(t);let e=t.indexOf("#");if(e===-1)return{repo:t,treeish:{protocol:vn.Head,request:"HEAD"},extra:{}};let r=t.slice(0,e),i=t.slice(e+1);if(i.match(/^[a-z]+=/)){let n=gf.default.parse(i);for(let[l,c]of Object.entries(n))if(typeof c!="string")throw new Error(`Assertion failed: The ${l} parameter must be a literal string`);let s=Object.values(vn).find(l=>Object.prototype.hasOwnProperty.call(n,l)),o,a;typeof s!="undefined"?(o=s,a=n[s]):(o=vn.Head,a="HEAD");for(let l of Object.values(vn))delete n[l];return{repo:r,treeish:{protocol:o,request:a},extra:n}}else{let n=i.indexOf(":"),s,o;return n===-1?(s=null,o=i):(s=i.slice(0,n),o=i.slice(n+1)),{repo:r,treeish:{protocol:s,request:o},extra:{}}}}function KC(t,{git:e=!1}={}){var r;if(t=t.replace(/^git\+https:/,"https:"),t=t.replace(/^(?:github:|https:\/\/github\.com\/)?(?!\.{1,2}\/)([a-zA-Z0-9._-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z0-9._-]+?)(?:\.git)?(#.*)?$/,"https://github.com/$1/$2.git$3"),t=t.replace(/^https:\/\/github\.com\/(?!\.{1,2}\/)([a-zA-Z0-9._-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z0-9._-]+?)\/tarball\/(.+)?$/,"https://github.com/$1/$2.git#$3"),e){t=t.replace(/^git\+([^:]+):/,"$1:");let i;try{i=KAe.default.parse(t)}catch{i=null}i&&i.protocol==="ssh:"&&((r=i.path)==null?void 0:r.startsWith("/:"))&&(t=t.replace(/^ssh:\/\//,""))}return t}function AL(t){return S.makeLocator(t,KC(t.reference))}async function HAe(t,e){let r=KC(t,{git:!0});if(!Zt.getNetworkSettings(`https://${(0,oL.default)(r).resource}`,{configuration:e}).enableNetwork)throw new Error(`Request to '${r}' has been blocked because of your configuration settings`);let n;try{n=await hr.execvp("git",["ls-remote",r],{cwd:e.startingCwd,env:UAe(),strict:!0})}catch(l){throw l.message=`Listing the refs for ${t} failed`,l}let s=new Map,o=/^([a-f0-9]{40})\t([^\n]+)/gm,a;for(;(a=o.exec(n.stdout))!==null;)s.set(a[2],a[1]);return s}async function lL(t,e){let{repo:r,treeish:{protocol:i,request:n},extra:s}=UC(t),o=await HAe(r,e),a=(c,u)=>{switch(c){case vn.Commit:{if(!u.match(/^[a-f0-9]{40}$/))throw new Error("Invalid commit hash");return gf.default.stringify(_(P({},s),{commit:u}))}case vn.Head:{let g=o.get(u==="HEAD"?u:`refs/heads/${u}`);if(typeof g=="undefined")throw new Error(`Unknown head ("${u}")`);return gf.default.stringify(_(P({},s),{commit:g}))}case vn.Tag:{let g=o.get(`refs/tags/${u}`);if(typeof g=="undefined")throw new Error(`Unknown tag ("${u}")`);return gf.default.stringify(_(P({},s),{commit:g}))}case vn.Semver:{let g=qt.validRange(u);if(!g)throw new Error(`Invalid range ("${u}")`);let f=new Map([...o.entries()].filter(([p])=>p.startsWith("refs/tags/")).map(([p,d])=>[aL.default.parse(p.slice(10)),d]).filter(p=>p[0]!==null)),h=aL.default.maxSatisfying([...f.keys()],g);if(h===null)throw new Error(`No matching range ("${u}")`);return gf.default.stringify(_(P({},s),{commit:f.get(h)}))}case null:{let g;if((g=l(vn.Commit,u))!==null||(g=l(vn.Tag,u))!==null||(g=l(vn.Head,u))!==null)return g;throw u.match(/^[a-f0-9]+$/)?new Error(`Couldn't resolve "${u}" as either a commit, a tag, or a head - if a commit, use the 40-characters commit hash`):new Error(`Couldn't resolve "${u}" as either a commit, a tag, or a head`)}default:throw new Error(`Invalid Git resolution protocol ("${c}")`)}},l=(c,u)=>{try{return a(c,u)}catch(g){return null}};return`${r}#${a(i,n)}`}async function cL(t,e){return await e.getLimit("cloneConcurrency")(async()=>{let{repo:r,treeish:{protocol:i,request:n}}=UC(t);if(i!=="commit")throw new Error("Invalid treeish protocol when cloning");let s=KC(r,{git:!0});if(Zt.getNetworkSettings(`https://${(0,oL.default)(s).resource}`,{configuration:e}).enableNetwork===!1)throw new Error(`Request to '${s}' has been blocked because of your configuration settings`);let o=await T.mktempPromise(),a={cwd:o,env:UAe(),strict:!0};try{await hr.execvp("git",["clone","-c core.autocrlf=false",s,M.fromPortablePath(o)],a),await hr.execvp("git",["checkout",`${n}`],a)}catch(l){throw l.message=`Repository clone failed: ${l.message}`,l}return o})}async function GAe(t){let e=null,r,i=t;do r=i,await T.existsPromise(v.join(r,".git"))&&(e=r),i=v.dirname(r);while(e===null&&i!==r);return e}async function jAe(t,{baseRefs:e}){if(e.length===0)throw new me("Can't run this command with zero base refs specified.");let r=[];for(let a of e){let{code:l}=await hr.execvp("git",["merge-base",a,"HEAD"],{cwd:t});l===0&&r.push(a)}if(r.length===0)throw new me(`No ancestor could be found between any of HEAD and ${e.join(", ")}`);let{stdout:i}=await hr.execvp("git",["merge-base","HEAD",...r],{cwd:t,strict:!0}),n=i.trim(),{stdout:s}=await hr.execvp("git",["show","--quiet","--pretty=format:%s",n],{cwd:t,strict:!0}),o=s.trim();return{hash:n,title:o}}async function YAe(t,{base:e,project:r}){let i=de.buildIgnorePattern(r.configuration.get("changesetIgnorePatterns")),{stdout:n}=await hr.execvp("git",["diff","--name-only",`${e}`],{cwd:t,strict:!0}),s=n.split(/\r\n|\r|\n/).filter(c=>c.length>0).map(c=>v.resolve(t,M.toPortablePath(c))),{stdout:o}=await hr.execvp("git",["ls-files","--others","--exclude-standard"],{cwd:t,strict:!0}),a=o.split(/\r\n|\r|\n/).filter(c=>c.length>0).map(c=>v.resolve(t,M.toPortablePath(c))),l=[...new Set([...s,...a].sort())];return i?l.filter(c=>!v.relative(r.cwd,c).match(i)):l}async function Ize({ref:t,project:e}){if(e.configuration.projectCwd===null)throw new me("This command can only be run from within a Yarn project");let r=[v.resolve(e.cwd,e.configuration.get("cacheFolder")),v.resolve(e.cwd,e.configuration.get("installStatePath")),v.resolve(e.cwd,e.configuration.get("lockfileFilename")),v.resolve(e.cwd,e.configuration.get("virtualFolder"))];await e.configuration.triggerHook(o=>o.populateYarnPaths,e,o=>{o!=null&&r.push(o)});let i=await GAe(e.configuration.projectCwd);if(i==null)throw new me("This command can only be run on Git repositories");let n=await jAe(i,{baseRefs:typeof t=="string"?[t]:e.configuration.get("changesetBaseRefs")}),s=await YAe(i,{base:n.hash,project:e});return new Set(de.mapAndFilter(s,o=>{let a=e.tryWorkspaceByFilePath(o);return a===null?de.mapAndFilter.skip:r.some(l=>o.startsWith(l))?de.mapAndFilter.skip:a}))}var uL=class{supports(e,r){return ff(e.reference)}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,n=AL(e),s=new Map(r.checksums);s.set(n.locatorHash,i);let o=_(P({},r),{checksums:s}),a=await this.downloadHosted(n,o);if(a!==null)return a;let[l,c,u]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the remote repository`),loader:()=>this.cloneFromRemote(n,o),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:l,releaseFs:c,prefixPath:S.getIdentVendorPath(e),checksum:u}}async downloadHosted(e,r){return r.project.configuration.reduceHook(i=>i.fetchHostedRepository,null,e,r)}async cloneFromRemote(e,r){let i=await cL(e.reference,r.project.configuration),n=UC(e.reference),s=v.join(i,"package.tgz");await Kt.prepareExternalProject(i,s,{configuration:r.project.configuration,report:r.report,workspace:n.extra.workspace,locator:e});let o=await T.readFilePromise(s);return await de.releaseAfterUseAsync(async()=>await Ai.convertToZip(o,{compressionLevel:r.project.configuration.get("compressionLevel"),prefixPath:S.getIdentVendorPath(e),stripComponents:1}))}};var gL=class{supportsDescriptor(e,r){return ff(e.range)}supportsLocator(e,r){return ff(e.reference)}shouldPersistResolution(e,r){return!0}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){let n=await lL(e.range,i.project.configuration);return[S.makeLocator(e,n)]}async getSatisfying(e,r,i){return null}async resolve(e,r){if(!r.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let i=await r.fetchOptions.fetcher.fetch(e,r.fetchOptions),n=await de.releaseAfterUseAsync(async()=>await Ze.find(i.prefixPath,{baseFs:i.packageFs}),i.releaseFs);return _(P({},e),{version:n.version||"0.0.0",languageName:n.languageName||r.project.configuration.get("defaultLanguageName"),linkType:gt.HARD,conditions:n.getConditions(),dependencies:n.dependencies,peerDependencies:n.peerDependencies,dependenciesMeta:n.dependenciesMeta,peerDependenciesMeta:n.peerDependenciesMeta,bin:n.bin})}};var yze={configuration:{changesetBaseRefs:{description:"The base git refs that the current HEAD is compared against when detecting changes. Supports git branches, tags, and commits.",type:ge.STRING,isArray:!0,isNullable:!1,default:["master","origin/master","upstream/master","main","origin/main","upstream/main"]},changesetIgnorePatterns:{description:"Array of glob patterns; files matching them will be ignored when fetching the changed files",type:ge.STRING,default:[],isArray:!0},cloneConcurrency:{description:"Maximal number of concurrent clones",type:ge.NUMBER,default:2}},fetchers:[uL],resolvers:[gL]};var wze=yze;var HC=class extends Be{constructor(){super(...arguments);this.since=Y.String("--since",{description:"Only include workspaces that have been changed since the specified ref.",tolerateBoolean:!0});this.recursive=Y.Boolean("-R,--recursive",!1,{description:"Find packages via dependencies/devDependencies instead of using the workspaces field"});this.verbose=Y.Boolean("-v,--verbose",!1,{description:"Also return the cross-dependencies between workspaces"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r}=await Ke.find(e,this.context.cwd);return(await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout},async n=>{let s=this.since?await Uc.fetchChangedWorkspaces({ref:this.since,project:r}):r.workspaces,o=new Set(s);if(this.recursive)for(let a of[...s].map(l=>l.getRecursiveWorkspaceDependents()))for(let l of a)o.add(l);for(let a of o){let{manifest:l}=a,c;if(this.verbose){let u=new Set,g=new Set;for(let f of Ze.hardDependencies)for(let[h,p]of l.getForScope(f)){let d=r.tryWorkspaceByDescriptor(p);d===null?r.workspacesByIdent.has(h)&&g.add(p):u.add(d)}c={workspaceDependencies:Array.from(u).map(f=>f.relativeCwd),mismatchedWorkspaceDependencies:Array.from(g).map(f=>S.stringifyDescriptor(f))}}n.reportInfo(null,`${a.relativeCwd}`),n.reportJson(P({location:a.relativeCwd,name:l.name?S.stringifyIdent(l.name):null},c))}})).exitCode()}};HC.paths=[["workspaces","list"]],HC.usage=ye.Usage({category:"Workspace-related commands",description:"list all available workspaces",details:"\n This command will print the list of all workspaces in the project.\n\n - If `--since` is set, Yarn will only list workspaces that have been modified since the specified ref. By default Yarn will use the refs specified by the `changesetBaseRefs` configuration option.\n\n - If `-R,--recursive` is set, Yarn will find workspaces to run the command on by recursively evaluating `dependencies` and `devDependencies` fields, instead of looking at the `workspaces` fields.\n\n - If both the `-v,--verbose` and `--json` options are set, Yarn will also return the cross-dependencies between each workspaces (useful when you wish to automatically generate Buck / Bazel rules).\n "});var qAe=HC;var GC=class extends Be{constructor(){super(...arguments);this.workspaceName=Y.String();this.commandName=Y.String();this.args=Y.Proxy()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);let n=r.workspaces,s=new Map(n.map(a=>{let l=S.convertToIdent(a.locator);return[S.stringifyIdent(l),a]})),o=s.get(this.workspaceName);if(o===void 0){let a=Array.from(s.keys()).sort();throw new me(`Workspace '${this.workspaceName}' not found. Did you mean any of the following: + - ${a.join(` + - `)}?`)}return this.cli.run([this.commandName,...this.args],{cwd:o.cwd})}};GC.paths=[["workspace"]],GC.usage=ye.Usage({category:"Workspace-related commands",description:"run a command within the specified workspace",details:` + This command will run a given sub-command on a single workspace. + `,examples:[["Add a package to a single workspace","yarn workspace components add -D react"],["Run build script on a single workspace","yarn workspace components run build"]]});var JAe=GC;var Bze={configuration:{enableImmutableInstalls:{description:"If true (the default on CI), prevents the install command from modifying the lockfile",type:ge.BOOLEAN,default:WAe.isCI},defaultSemverRangePrefix:{description:"The default save prefix: '^', '~' or ''",type:ge.STRING,values:["^","~",""],default:Lo.CARET}},commands:[soe,aoe,wae,Nae,mAe,nAe,tAe,qAe,Uae,Hae,Gae,jae,ioe,noe,Lae,Mae,Yae,qae,Wae,zae,_ae,IAe,Xae,cAe,AAe,uAe,Zae,gAe,fAe,hAe,dAe,CAe,wAe,BAe,JAe]},Qze=Bze;var mL={};it(mL,{default:()=>vze});var Me={optional:!0},zAe=[["@tailwindcss/aspect-ratio@<0.2.1",{peerDependencies:{tailwindcss:"^2.0.2"}}],["@tailwindcss/line-clamp@<0.2.1",{peerDependencies:{tailwindcss:"^2.0.2"}}],["@fullhuman/postcss-purgecss@3.1.3 || 3.1.3-alpha.0",{peerDependencies:{postcss:"^8.0.0"}}],["@samverschueren/stream-to-observable@<0.3.1",{peerDependenciesMeta:{rxjs:Me,zenObservable:Me}}],["any-observable@<0.5.1",{peerDependenciesMeta:{rxjs:Me,zenObservable:Me}}],["@pm2/agent@<1.0.4",{dependencies:{debug:"*"}}],["debug@<4.2.0",{peerDependenciesMeta:{["supports-color"]:Me}}],["got@<11",{dependencies:{["@types/responselike"]:"^1.0.0",["@types/keyv"]:"^3.1.1"}}],["cacheable-lookup@<4.1.2",{dependencies:{["@types/keyv"]:"^3.1.1"}}],["http-link-dataloader@*",{peerDependencies:{graphql:"^0.13.1 || ^14.0.0"}}],["typescript-language-server@*",{dependencies:{["vscode-jsonrpc"]:"^5.0.1",["vscode-languageserver-protocol"]:"^3.15.0"}}],["postcss-syntax@*",{peerDependenciesMeta:{["postcss-html"]:Me,["postcss-jsx"]:Me,["postcss-less"]:Me,["postcss-markdown"]:Me,["postcss-scss"]:Me}}],["jss-plugin-rule-value-function@<=10.1.1",{dependencies:{["tiny-warning"]:"^1.0.2"}}],["ink-select-input@<4.1.0",{peerDependencies:{react:"^16.8.2"}}],["license-webpack-plugin@<2.3.18",{peerDependenciesMeta:{webpack:Me}}],["snowpack@>=3.3.0",{dependencies:{["node-gyp"]:"^7.1.0"}}],["promise-inflight@*",{peerDependenciesMeta:{bluebird:Me}}],["reactcss@*",{peerDependencies:{react:"*"}}],["react-color@<=2.19.0",{peerDependencies:{react:"*"}}],["gatsby-plugin-i18n@*",{dependencies:{ramda:"^0.24.1"}}],["useragent@^2.0.0",{dependencies:{request:"^2.88.0",yamlparser:"0.0.x",semver:"5.5.x"}}],["@apollographql/apollo-tools@*",{peerDependencies:{graphql:"^14.2.1 || ^15.0.0"}}],["material-table@^2.0.0",{dependencies:{"@babel/runtime":"^7.11.2"}}],["@babel/parser@*",{dependencies:{"@babel/types":"^7.8.3"}}],["fork-ts-checker-webpack-plugin@<=6.3.4",{peerDependencies:{eslint:">= 6",typescript:">= 2.7",webpack:">= 4","vue-template-compiler":"*"},peerDependenciesMeta:{eslint:Me,"vue-template-compiler":Me}}],["rc-animate@<=3.1.1",{peerDependencies:{react:">=16.9.0","react-dom":">=16.9.0"}}],["react-bootstrap-table2-paginator@*",{dependencies:{classnames:"^2.2.6"}}],["react-draggable@<=4.4.3",{peerDependencies:{react:">= 16.3.0","react-dom":">= 16.3.0"}}],["apollo-upload-client@<14",{peerDependencies:{graphql:"14 - 15"}}],["react-instantsearch-core@<=6.7.0",{peerDependencies:{algoliasearch:">= 3.1 < 5"}}],["react-instantsearch-dom@<=6.7.0",{dependencies:{"react-fast-compare":"^3.0.0"}}],["ws@<7.2.1",{peerDependencies:{bufferutil:"^4.0.1","utf-8-validate":"^5.0.2"},peerDependenciesMeta:{bufferutil:Me,"utf-8-validate":Me}}],["react-portal@*",{peerDependencies:{"react-dom":"^15.0.0-0 || ^16.0.0-0 || ^17.0.0-0"}}],["react-scripts@<=4.0.1",{peerDependencies:{react:"*"}}],["testcafe@<=1.10.1",{dependencies:{"@babel/plugin-transform-for-of":"^7.12.1","@babel/runtime":"^7.12.5"}}],["testcafe-legacy-api@<=4.2.0",{dependencies:{"testcafe-hammerhead":"^17.0.1","read-file-relative":"^1.2.0"}}],["@google-cloud/firestore@<=4.9.3",{dependencies:{protobufjs:"^6.8.6"}}],["gatsby-source-apiserver@*",{dependencies:{["babel-polyfill"]:"^6.26.0"}}],["@webpack-cli/package-utils@<=1.0.1-alpha.4",{dependencies:{["cross-spawn"]:"^7.0.3"}}],["gatsby-remark-prismjs@<3.3.28",{dependencies:{lodash:"^4"}}],["gatsby-plugin-favicon@*",{peerDependencies:{webpack:"*"}}],["gatsby-plugin-sharp@*",{dependencies:{debug:"^4.3.1"}}],["gatsby-react-router-scroll@*",{dependencies:{["prop-types"]:"^15.7.2"}}],["@rebass/forms@*",{dependencies:{["@styled-system/should-forward-prop"]:"^5.0.0"},peerDependencies:{react:"^16.8.6"}}],["rebass@*",{peerDependencies:{react:"^16.8.6"}}],["@ant-design/react-slick@<=0.28.3",{peerDependencies:{react:">=16.0.0"}}],["mqtt@<4.2.7",{dependencies:{duplexify:"^4.1.1"}}],["vue-cli-plugin-vuetify@<=2.0.3",{dependencies:{semver:"^6.3.0"},peerDependenciesMeta:{"sass-loader":Me,"vuetify-loader":Me}}],["vue-cli-plugin-vuetify@<=2.0.4",{dependencies:{"null-loader":"^3.0.0"}}],["@vuetify/cli-plugin-utils@<=0.0.4",{dependencies:{semver:"^6.3.0"},peerDependenciesMeta:{"sass-loader":Me}}],["@vue/cli-plugin-typescript@<=5.0.0-alpha.0",{dependencies:{"babel-loader":"^8.1.0"}}],["@vue/cli-plugin-typescript@<=5.0.0-beta.0",{dependencies:{"@babel/core":"^7.12.16"},peerDependencies:{"vue-template-compiler":"^2.0.0"},peerDependenciesMeta:{"vue-template-compiler":Me}}],["cordova-ios@<=6.3.0",{dependencies:{underscore:"^1.9.2"}}],["cordova-lib@<=10.0.1",{dependencies:{underscore:"^1.9.2"}}],["git-node-fs@*",{peerDependencies:{"js-git":"^0.7.8"},peerDependenciesMeta:{"js-git":Me}}],["consolidate@*",{peerDependencies:{velocityjs:"^2.0.1",tinyliquid:"^0.2.34","liquid-node":"^3.0.1",jade:"^1.11.0","then-jade":"*",dust:"^0.3.0","dustjs-helpers":"^1.7.4","dustjs-linkedin":"^2.7.5",swig:"^1.4.2","swig-templates":"^2.0.3","razor-tmpl":"^1.3.1",atpl:">=0.7.6",liquor:"^0.0.5",twig:"^1.15.2",ejs:"^3.1.5",eco:"^1.1.0-rc-3",jazz:"^0.0.18",jqtpl:"~1.1.0",hamljs:"^0.6.2",hamlet:"^0.3.3",whiskers:"^0.4.0","haml-coffee":"^1.14.1","hogan.js":"^3.0.2",templayed:">=0.2.3",handlebars:"^4.7.6",underscore:"^1.11.0",lodash:"^4.17.20",pug:"^3.0.0","then-pug":"*",qejs:"^3.0.5",walrus:"^0.10.1",mustache:"^4.0.1",just:"^0.1.8",ect:"^0.5.9",mote:"^0.2.0",toffee:"^0.3.6",dot:"^1.1.3","bracket-template":"^1.1.5",ractive:"^1.3.12",nunjucks:"^3.2.2",htmling:"^0.0.8","babel-core":"^6.26.3",plates:"~0.4.11","react-dom":"^16.13.1",react:"^16.13.1","arc-templates":"^0.5.3",vash:"^0.13.0",slm:"^2.0.0",marko:"^3.14.4",teacup:"^2.0.0","coffee-script":"^1.12.7",squirrelly:"^5.1.0",twing:"^5.0.2"},peerDependenciesMeta:{velocityjs:Me,tinyliquid:Me,"liquid-node":Me,jade:Me,"then-jade":Me,dust:Me,"dustjs-helpers":Me,"dustjs-linkedin":Me,swig:Me,"swig-templates":Me,"razor-tmpl":Me,atpl:Me,liquor:Me,twig:Me,ejs:Me,eco:Me,jazz:Me,jqtpl:Me,hamljs:Me,hamlet:Me,whiskers:Me,"haml-coffee":Me,"hogan.js":Me,templayed:Me,handlebars:Me,underscore:Me,lodash:Me,pug:Me,"then-pug":Me,qejs:Me,walrus:Me,mustache:Me,just:Me,ect:Me,mote:Me,toffee:Me,dot:Me,"bracket-template":Me,ractive:Me,nunjucks:Me,htmling:Me,"babel-core":Me,plates:Me,"react-dom":Me,react:Me,"arc-templates":Me,vash:Me,slm:Me,marko:Me,teacup:Me,"coffee-script":Me,squirrelly:Me,twing:Me}}],["vue-loader@<=16.3.1",{peerDependencies:{"@vue/compiler-sfc":"^3.0.8",webpack:"^4.1.0 || ^5.0.0-0"}}],["scss-parser@*",{dependencies:{lodash:"^4.17.21"}}],["query-ast@*",{dependencies:{lodash:"^4.17.21"}}],["redux-thunk@<=2.3.0",{peerDependencies:{redux:"^4.0.0"}}],["skypack@<=0.3.2",{dependencies:{tar:"^6.1.0"}}],["@npmcli/metavuln-calculator@*",{dependencies:{"json-parse-even-better-errors":"^2.3.1"}}],["bin-links@*",{dependencies:{"mkdirp-infer-owner":"^1.0.2"}}],["rollup-plugin-polyfill-node@*",{peerDependencies:{rollup:"^1.20.0 || ^2.0.0"}}],["snowpack@*",{dependencies:{"magic-string":"^0.25.7"}}],["elm-webpack-loader@*",{dependencies:{temp:"^0.9.4"}}],["winston-transport@<=4.4.0",{dependencies:{logform:"^2.2.0"}}],["jest-vue-preprocessor@*",{dependencies:{"@babel/core":"7.8.7","@babel/template":"7.8.6"},peerDependencies:{pug:"^2.0.4"},peerDependenciesMeta:{pug:Me}}],["redux-persist@*",{peerDependencies:{react:">=16"},peerDependenciesMeta:{react:Me}}],["sodium@>=3",{dependencies:{"node-gyp":"^3.8.0"}}],["babel-plugin-graphql-tag@<=3.1.0",{peerDependencies:{graphql:"^14.0.0 || ^15.0.0"}}],["@playwright/test@<=1.14.1",{dependencies:{"jest-matcher-utils":"^26.4.2"}}],...["babel-plugin-remove-graphql-queries@<3.14.0-next.1","babel-preset-gatsby-package@<1.14.0-next.1","create-gatsby@<1.14.0-next.1","gatsby-admin@<0.24.0-next.1","gatsby-cli@<3.14.0-next.1","gatsby-core-utils@<2.14.0-next.1","gatsby-design-tokens@<3.14.0-next.1","gatsby-legacy-polyfills@<1.14.0-next.1","gatsby-plugin-benchmark-reporting@<1.14.0-next.1","gatsby-plugin-graphql-config@<0.23.0-next.1","gatsby-plugin-image@<1.14.0-next.1","gatsby-plugin-mdx@<2.14.0-next.1","gatsby-plugin-netlify-cms@<5.14.0-next.1","gatsby-plugin-no-sourcemaps@<3.14.0-next.1","gatsby-plugin-page-creator@<3.14.0-next.1","gatsby-plugin-preact@<5.14.0-next.1","gatsby-plugin-preload-fonts@<2.14.0-next.1","gatsby-plugin-schema-snapshot@<2.14.0-next.1","gatsby-plugin-styletron@<6.14.0-next.1","gatsby-plugin-subfont@<3.14.0-next.1","gatsby-plugin-utils@<1.14.0-next.1","gatsby-recipes@<0.25.0-next.1","gatsby-source-shopify@<5.6.0-next.1","gatsby-source-wikipedia@<3.14.0-next.1","gatsby-transformer-screenshot@<3.14.0-next.1","gatsby-worker@<0.5.0-next.1"].map(t=>[t,{dependencies:{"@babel/runtime":"^7.14.8"}}]),["gatsby-core-utils@<2.14.0-next.1",{dependencies:{got:"8.3.2"}}],["gatsby-plugin-gatsby-cloud@<=3.1.0-next.0",{dependencies:{"gatsby-core-utils":"^2.13.0-next.0"}}],["gatsby-plugin-gatsby-cloud@<=3.2.0-next.1",{peerDependencies:{webpack:"*"}}],["babel-plugin-remove-graphql-queries@<=3.14.0-next.1",{dependencies:{"gatsby-core-utils":"^2.8.0-next.1"}}],["gatsby-plugin-netlify@3.13.0-next.1",{dependencies:{"gatsby-core-utils":"^2.13.0-next.0"}}],["clipanion-v3-codemod@<=0.2.0",{peerDependencies:{jscodeshift:"^0.11.0"}}],["react-live@*",{peerDependencies:{"react-dom":"*",react:"*"}}],["webpack@<4.44.1",{peerDependenciesMeta:{"webpack-cli":Me,"webpack-command":Me}}],["webpack@<5.0.0-beta.23",{peerDependenciesMeta:{"webpack-cli":Me}}],["webpack-dev-server@<3.10.2",{peerDependenciesMeta:{"webpack-cli":Me}}]];var pL;function VAe(){return typeof pL=="undefined"&&(pL=require("zlib").brotliDecompressSync(Buffer.from("G7weAByFTVk3Vs7UfHhq4yykgEM7pbW7TI43SG2S5tvGrwHBAzdz+s/npQ6tgEvobvxisrPIadkXeUAJotBn5bDZ5kAhcRqsIHe3F75Walet5hNalwgFDtxb0BiDUjiUQkjG0yW2hto9HPgiCkm316d6bC0kST72YN7D7rfkhCE9x4J0XwB0yavalxpUu2t9xszHrmtwalOxT7VslsxWcB1qpqZwERUra4psWhTV8BgwWeizurec82Caf1ABL11YMfbf8FJ9JBceZOkgmvrQPbC9DUldX/yMbmX06UQluCEjSwUoyO+EZPIjofr+/oAZUck2enraRD+oWLlnlYnj8xB+gwSo9lmmks4fXv574qSqcWA6z21uYkzMu3EWj+K23RxeQlLqiE35/rC8GcS4CGkKHKKq+zAIQwD9iRDNfiAqueLLpicFFrNsAI4zeTD/eO9MHcnRa5m8UT+M2+V+AkFST4BlKneiAQRSdST8KEAIyFlULt6wa9EBd0Ds28VmpaxquJdVt+nwdEs5xUskI13OVtFyY0UrQIRAlCuvvWivvlSKQfTO+2Q8OyUR1W5RvetaPz4jD27hdtwHFFA1Ptx6Ee/t2cY2rg2G46M1pNDRf2pWhvpy8pqMnuI3++4OF3+7OFIWXGjh+o7Nr2jNvbiYcQdQS1h903/jVFgOpA0yJ78z+x759bFA0rq+6aY5qPB4FzS3oYoLupDUhD9nDz6F6H7hpnlMf18KNKDu4IKjTWwrAnY6MFQw1W6ymOALHlFyCZmQhldg1MQHaMVVQTVgDC60TfaBqG++Y8PEoFhN/PBTZT175KNP/BlHDYGOOBmnBdzqJKplZ/ljiVG0ZBzfqeBRrrUkn6rA54462SgiliKoYVnbeptMdXNfAuaupIEi0bApF10TlgHfmEJAPUVidRVFyDupSem5po5vErPqWKhKbUIp0LozpYsIKK57dM/HKr+nguF+7924IIWMICkQ8JUigs9D+W+c4LnNoRtPPKNRUiCYmP+Jfo2lfKCKw8qpraEeWU3uiNRO6zcyKQoXPR5htmzzLznke7b4YbXW3I1lIRzmgG02Udb58U+7TpwyN7XymCgH+wuPDthZVQvRZuEP+SnLtMicz9m5zASWOBiAcLmkuFlTKuHspSIhCBD0yUPKcxu81A+4YD78rA2vtwsUEday9WNyrShyrl60rWmA+SmbYZkQOwFJWArxRYYc5jGhA5ikxYw1rx3ei4NmeX/lKiwpZ9Ln1tV2Ae7sArvxuVLbJjqJRjW1vFXAyHpvLG+8MJ6T2Ubx5M2KDa2SN6vuIGxJ9WQM9Mk3Q7aCNiZONXllhqq24DmoLbQfW2rYWsOgHWjtOmIQMyMKdiHZDjoyIq5+U700nZ6odJAoYXPQBvFNiQ78d5jaXliBqLTJEqUCwi+LiH2mx92EmNKDsJL74Z613+3lf20pxkV1+erOrjj8pW00vsPaahKUM+05ssd5uwM7K482KWEf3TCwlg/o3e5ngto7qSMz7YteIgCsF1UOcsLk7F7MxWbvrPMY473ew0G+noVL8EPbkmEMftMSeL6HFub/zy+2JQ==","base64")).toString()),pL}var dL;function _Ae(){return typeof dL=="undefined"&&(dL=require("zlib").brotliDecompressSync(Buffer.from("G8MSIIzURnVBnObTcvb3XE6v2S9Qgc2K801Oa5otNKEtK8BINZNcaQHy+9/vf/WXBimwutXC33P2DPc64pps5rz7NGGWaOKNSPL4Y2KRE8twut2lFOIN+OXPtRmPMRhMTILib2bEQx43az2I5d3YS8Roa5UZpF/ujHb3Djd3GDvYUfvFYSUQ39vb2cmifp/rgB4J/65J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BDzA+YvFdjZzVIEDcKGpS6PbUJehFRjEne8D0lVU1XuRtlgszq6pTNlQ/3MzNOEgCWPyTct22V2mEi2krizn5VDo9B19/X2DB3hCGRMM7ONbtnAcIx/OWB1u5uPbW1gsH8irXxT/IzG0PoXWYjhbMsH3KTuoOl5o17PulcgvsfTSnKFM354GWI8luqZnrswWjiXy3G+Vbyo1KMopFmmvBwNELgaS8z8dNZchx/Cl/xjddxhMcyqtzFyONb2Zdu90NkI8pAeufe7YlXrp53v8Dj/l8vWeVspRKBGXScBBPI/HinSTGmLDOGGOCIyH0JFdOZx0gWsacNlQLJMIrBhqRxXxHF/5pseWwejlAAvZ3klZSDSYY8mkToaWejXhgNomeGtx1DTLEUFMRkgF5yFB22WYdJnaWN14r1YJj81hGi45+jrADS5nYRhCiSlCJJ1nL8pYX+HDSMhdTEWyRcgHVp/IsUIZYMfT+YYncUQPgcxNGCHfZ88vDdrcUuaGIl6zhAsiaq7R5dfqrqXH/JcBhfjT8D0azayIyEz75Nxp6YkcyDxlJq3EXnJUpqDohJJOysL1t1uNiHESlvsxPb5cpbW0+ICZqJmUZus1BMW0F5IVBODLIo2zHHjA0=","base64")).toString()),dL}var CL;function XAe(){return typeof CL=="undefined"&&(CL=require("zlib").brotliDecompressSync(Buffer.from("m3wJE1GkN6sQTGg/U6NIb0aTKMP9bivYNuU6vRmRrSm//3UCehrg5OrrHCrSWkCREhF890RJt8fjR4A2EeX46L4IrTIWP/affkbbukX9rgdYBpRx68FI2tVZV558HxxDbdbwcwWkxS9fTf/18/XcF+clrnTSdsJrlW6VKgApOBTI2YUuI09ioW31NNUEPOEYwiH60pTg2ci7Zluqr7fVRbadjqmOuYgcHJcM4LBSeue6QXpmFJpjz6uvUY+qiVCSyyWXY8pujLb8Gjf4fk5Utq7UVA2mJ3RlmbiNgx50eZC/iKz6+5zWK7EBdVOHtfr7yYnjEryCuaayo/JNKQnrzulnbmJV2VwuioDYlbOf/59vWqYk1hgD7K7EWdmIR0GEwwFlnM2U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O5ymjeXSlYeDQGL9NDKWG1V63HEy/jX4N0r7vriLL1Tj8/fjS3CUz/B27evM2HDtE4Awr/jMw7SQjRx0MSn72NNqs5K2k5iGjwAIeWHyrLhHdf03vRsqqXJr6r+8bGzdavV7dea+t6ryEMvQ1hX0GDXbjABANwNLyr3sae/dBIVPIn5xylkitd0NnWDTBn1gukmMrWsI00jMGaUNuSodS3VDvhaJdorwyo9nprszsV0NVO2BwDY82B94hwYnfHDC+Cs1lQKcEcSG++qCHzA0Cj1APioFITFWPXB1ikCcahdV+/yegPurSDclV44lrxGRVZpyJhj8XgiNLP5IQCwSi9a677N6CqsuNsDcNZUuRo9N654bzgP1affA0vpuDsB3eqZMMAtMzs2MNuAyAF4VCGWhKA3tA0MhF0vJW8mvKbC+srpH18yLDeAJ1I0G5VKZVcf7Gz2rzfWe6dosIDE/ZixuQHsXTfaArKyivxJPGLewHOMMM/6KusfXzoqSlXV+6Ww2/akKnmhCkfsQpkJAFBmt/Iemp2/EqnYGRUQYpPFZwlbqxrUsX1KEoaN5NoyK1Us144d5wr0JplvvgO4qrSbOxeQMoAAwM0WzR/cQAO5uYKcFXG/tR4JoD2lFKvLXK5gqvEaQMWVvwI=","base64")).toString()),CL}var ZAe=new Map([[S.makeIdent(null,"fsevents").identHash,VAe],[S.makeIdent(null,"resolve").identHash,_Ae],[S.makeIdent(null,"typescript").identHash,XAe]]),bze={hooks:{registerPackageExtensions:async(t,e)=>{for(let[r,i]of zAe)e(S.parseDescriptor(r,!0),i)},getBuiltinPatch:async(t,e)=>{var s;let r="compat/";if(!e.startsWith(r))return;let i=S.parseIdent(e.slice(r.length)),n=(s=ZAe.get(i.identHash))==null?void 0:s();return typeof n!="undefined"?n:null},reduceDependency:async(t,e,r,i)=>typeof ZAe.get(t.identHash)=="undefined"?t:S.makeDescriptor(t,S.makeRange({protocol:"patch:",source:S.stringifyDescriptor(t),selector:`~builtin`,params:null}))}},vze=bze;var EL={};it(EL,{default:()=>xze});var V0=class extends Be{constructor(){super(...arguments);this.pkg=Y.String("-p,--package",{description:"The package to run the provided command from"});this.quiet=Y.Boolean("-q,--quiet",!1,{description:"Only report critical errors instead of printing the full install logs"});this.command=Y.String();this.args=Y.Proxy()}async execute(){let e=[];this.pkg&&e.push("--package",this.pkg),this.quiet&&e.push("--quiet");let r=S.parseIdent(this.command),i=S.makeIdent(r.scope,`create-${r.name}`);return this.cli.run(["dlx",...e,S.stringifyIdent(i),...this.args])}};V0.paths=[["create"]];var $Ae=V0;var jC=class extends Be{constructor(){super(...arguments);this.packages=Y.Array("-p,--package",{description:"The package(s) to install before running the command"});this.quiet=Y.Boolean("-q,--quiet",!1,{description:"Only report critical errors instead of printing the full install logs"});this.command=Y.String();this.args=Y.Proxy()}async execute(){return fe.telemetry=null,await T.mktempPromise(async e=>{var p;let r=v.join(e,`dlx-${process.pid}`);await T.mkdirPromise(r),await T.writeFilePromise(v.join(r,"package.json"),`{} +`),await T.writeFilePromise(v.join(r,"yarn.lock"),"");let i=v.join(r,".yarnrc.yml"),n=await fe.findProjectCwd(this.context.cwd,wt.lockfile),s=!(await fe.find(this.context.cwd,null,{strict:!1})).get("enableGlobalCache"),o=n!==null?v.join(n,".yarnrc.yml"):null;o!==null&&T.existsSync(o)?(await T.copyFilePromise(o,i),await fe.updateConfiguration(r,d=>{let m=_(P({},d),{enableGlobalCache:s,enableTelemetry:!1});return Array.isArray(d.plugins)&&(m.plugins=d.plugins.map(I=>{let B=typeof I=="string"?I:I.path,b=M.isAbsolute(B)?B:M.resolve(M.fromPortablePath(n),B);return typeof I=="string"?b:{path:b,spec:I.spec}})),m})):await T.writeFilePromise(i,`enableGlobalCache: ${s} +enableTelemetry: false +`);let a=(p=this.packages)!=null?p:[this.command],l=S.parseDescriptor(this.command).name,c=await this.cli.run(["add","--",...a],{cwd:r,quiet:this.quiet});if(c!==0)return c;this.quiet||this.context.stdout.write(` +`);let u=await fe.find(r,this.context.plugins),{project:g,workspace:f}=await Ke.find(u,r);if(f===null)throw new rt(g.cwd,r);await g.restoreInstallState();let h=await Kt.getWorkspaceAccessibleBinaries(f);return h.has(l)===!1&&h.size===1&&typeof this.packages=="undefined"&&(l=Array.from(h)[0][0]),await Kt.executeWorkspaceAccessibleBinary(f,l,this.args,{packageAccessibleBinaries:h,cwd:this.context.cwd,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr})})}};jC.paths=[["dlx"]],jC.usage=ye.Usage({description:"run a package in a temporary environment",details:"\n This command will install a package within a temporary environment, and run its binary script if it contains any. The binary will run within the current cwd.\n\n By default Yarn will download the package named `command`, but this can be changed through the use of the `-p,--package` flag which will instruct Yarn to still run the same command but from a different package.\n\n Using `yarn dlx` as a replacement of `yarn add` isn't recommended, as it makes your project non-deterministic (Yarn doesn't keep track of the packages installed through `dlx` - neither their name, nor their version).\n ",examples:[["Use create-react-app to create a new React app","yarn dlx create-react-app ./my-app"],["Install multiple packages for a single command",`yarn dlx -p typescript -p ts-node ts-node --transpile-only -e "console.log('hello!')"`]]});var ele=jC;var Sze={commands:[$Ae,ele]},xze=Sze;var xL={};it(xL,{default:()=>Dze,fileUtils:()=>IL});var hf=/^(?:[a-zA-Z]:[\\/]|\.{0,2}\/)/,YC=/^[^?]*\.(?:tar\.gz|tgz)(?:::.*)?$/,Nr="file:";var IL={};it(IL,{makeArchiveFromLocator:()=>_0,makeBufferFromLocator:()=>BL,makeLocator:()=>wL,makeSpec:()=>tle,parseSpec:()=>yL});function yL(t){let{params:e,selector:r}=S.parseRange(t),i=M.toPortablePath(r);return{parentLocator:e&&typeof e.locator=="string"?S.parseLocator(e.locator):null,path:i}}function tle({parentLocator:t,path:e,folderHash:r,protocol:i}){let n=t!==null?{locator:S.stringifyLocator(t)}:{},s=typeof r!="undefined"?{hash:r}:{};return S.makeRange({protocol:i,source:e,selector:e,params:P(P({},s),n)})}function wL(t,{parentLocator:e,path:r,folderHash:i,protocol:n}){return S.makeLocator(t,tle({parentLocator:e,path:r,folderHash:i,protocol:n}))}async function _0(t,{protocol:e,fetchOptions:r,inMemory:i=!1}){let{parentLocator:n,path:s}=S.parseFileStyleRange(t.reference,{protocol:e}),o=v.isAbsolute(s)?{packageFs:new Ft(Se.root),prefixPath:Se.dot,localPath:Se.root}:await r.fetcher.fetch(n,r),a=o.localPath?{packageFs:new Ft(Se.root),prefixPath:v.relative(Se.root,o.localPath)}:o;o!==a&&o.releaseFs&&o.releaseFs();let l=a.packageFs,c=v.join(a.prefixPath,s);return await de.releaseAfterUseAsync(async()=>await Ai.makeArchiveFromDirectory(c,{baseFs:l,prefixPath:S.getIdentVendorPath(t),compressionLevel:r.project.configuration.get("compressionLevel"),inMemory:i}),a.releaseFs)}async function BL(t,{protocol:e,fetchOptions:r}){return(await _0(t,{protocol:e,fetchOptions:r,inMemory:!0})).getBufferAndClose()}var QL=class{supports(e,r){return!!e.reference.startsWith(Nr)}getLocalPath(e,r){let{parentLocator:i,path:n}=S.parseFileStyleRange(e.reference,{protocol:Nr});if(v.isAbsolute(n))return n;let s=r.fetcher.getLocalPath(i,r);return s===null?null:v.resolve(s,n)}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the disk`),loader:()=>this.fetchFromDisk(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:S.getIdentVendorPath(e),localPath:this.getLocalPath(e,r),checksum:o}}async fetchFromDisk(e,r){return _0(e,{protocol:Nr,fetchOptions:r})}};var kze=2,bL=class{supportsDescriptor(e,r){return e.range.match(hf)?!0:!!e.range.startsWith(Nr)}supportsLocator(e,r){return!!e.reference.startsWith(Nr)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){return hf.test(e.range)&&(e=S.makeDescriptor(e,`${Nr}${e.range}`)),S.bindDescriptor(e,{locator:S.stringifyLocator(r)})}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){if(!i.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let{path:n,parentLocator:s}=yL(e.range);if(s===null)throw new Error("Assertion failed: The descriptor should have been bound");let o=await BL(S.makeLocator(e,S.makeRange({protocol:Nr,source:n,selector:n,params:{locator:S.stringifyLocator(s)}})),{protocol:Nr,fetchOptions:i.fetchOptions}),a=mn.makeHash(`${kze}`,o).slice(0,6);return[wL(e,{parentLocator:s,path:n,folderHash:a,protocol:Nr})]}async getSatisfying(e,r,i){return null}async resolve(e,r){if(!r.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let i=await r.fetchOptions.fetcher.fetch(e,r.fetchOptions),n=await de.releaseAfterUseAsync(async()=>await Ze.find(i.prefixPath,{baseFs:i.packageFs}),i.releaseFs);return _(P({},e),{version:n.version||"0.0.0",languageName:n.languageName||r.project.configuration.get("defaultLanguageName"),linkType:gt.HARD,conditions:n.getConditions(),dependencies:n.dependencies,peerDependencies:n.peerDependencies,dependenciesMeta:n.dependenciesMeta,peerDependenciesMeta:n.peerDependenciesMeta,bin:n.bin})}};var vL=class{supports(e,r){return YC.test(e.reference)?!!e.reference.startsWith(Nr):!1}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the disk`),loader:()=>this.fetchFromDisk(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:S.getIdentVendorPath(e),checksum:o}}async fetchFromDisk(e,r){let{parentLocator:i,path:n}=S.parseFileStyleRange(e.reference,{protocol:Nr}),s=v.isAbsolute(n)?{packageFs:new Ft(Se.root),prefixPath:Se.dot,localPath:Se.root}:await r.fetcher.fetch(i,r),o=s.localPath?{packageFs:new Ft(Se.root),prefixPath:v.relative(Se.root,s.localPath)}:s;s!==o&&s.releaseFs&&s.releaseFs();let a=o.packageFs,l=v.join(o.prefixPath,n),c=await a.readFilePromise(l);return await de.releaseAfterUseAsync(async()=>await Ai.convertToZip(c,{compressionLevel:r.project.configuration.get("compressionLevel"),prefixPath:S.getIdentVendorPath(e),stripComponents:1}),o.releaseFs)}};var SL=class{supportsDescriptor(e,r){return YC.test(e.range)?!!(e.range.startsWith(Nr)||hf.test(e.range)):!1}supportsLocator(e,r){return YC.test(e.reference)?!!e.reference.startsWith(Nr):!1}shouldPersistResolution(e,r){return!0}bindDescriptor(e,r,i){return hf.test(e.range)&&(e=S.makeDescriptor(e,`${Nr}${e.range}`)),S.bindDescriptor(e,{locator:S.stringifyLocator(r)})}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){let n=e.range;return n.startsWith(Nr)&&(n=n.slice(Nr.length)),[S.makeLocator(e,`${Nr}${M.toPortablePath(n)}`)]}async getSatisfying(e,r,i){return null}async resolve(e,r){if(!r.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let i=await r.fetchOptions.fetcher.fetch(e,r.fetchOptions),n=await de.releaseAfterUseAsync(async()=>await Ze.find(i.prefixPath,{baseFs:i.packageFs}),i.releaseFs);return _(P({},e),{version:n.version||"0.0.0",languageName:n.languageName||r.project.configuration.get("defaultLanguageName"),linkType:gt.HARD,conditions:n.getConditions(),dependencies:n.dependencies,peerDependencies:n.peerDependencies,dependenciesMeta:n.dependenciesMeta,peerDependenciesMeta:n.peerDependenciesMeta,bin:n.bin})}};var Pze={fetchers:[vL,QL],resolvers:[SL,bL]},Dze=Pze;var PL={};it(PL,{default:()=>Nze});var rle=ie(require("querystring")),ile=[/^https?:\/\/(?:([^/]+?)@)?github.com\/([^/#]+)\/([^/#]+)\/tarball\/([^/#]+)(?:#(.*))?$/,/^https?:\/\/(?:([^/]+?)@)?github.com\/([^/#]+)\/([^/#]+?)(?:\.git)?(?:#(.*))?$/];function nle(t){return t?ile.some(e=>!!t.match(e)):!1}function sle(t){let e;for(let a of ile)if(e=t.match(a),e)break;if(!e)throw new Error(Rze(t));let[,r,i,n,s="master"]=e,{commit:o}=rle.default.parse(s);return s=o||s.replace(/[^:]*:/,""),{auth:r,username:i,reponame:n,treeish:s}}function Rze(t){return`Input cannot be parsed as a valid GitHub URL ('${t}').`}var kL=class{supports(e,r){return!!nle(e.reference)}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from GitHub`),loader:()=>this.fetchFromNetwork(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:S.getIdentVendorPath(e),checksum:o}}async fetchFromNetwork(e,r){let i=await Zt.get(this.getLocatorUrl(e,r),{configuration:r.project.configuration});return await T.mktempPromise(async n=>{let s=new Ft(n);await Ai.extractArchiveTo(i,s,{stripComponents:1});let o=Uc.splitRepoUrl(e.reference),a=v.join(n,"package.tgz");await Kt.prepareExternalProject(n,a,{configuration:r.project.configuration,report:r.report,workspace:o.extra.workspace,locator:e});let l=await T.readFilePromise(a);return await Ai.convertToZip(l,{compressionLevel:r.project.configuration.get("compressionLevel"),prefixPath:S.getIdentVendorPath(e),stripComponents:1})})}getLocatorUrl(e,r){let{auth:i,username:n,reponame:s,treeish:o}=sle(e.reference);return`https://${i?`${i}@`:""}github.com/${n}/${s}/archive/${o}.tar.gz`}};var Fze={hooks:{async fetchHostedRepository(t,e,r){if(t!==null)return t;let i=new kL;if(!i.supports(e,r))return null;try{return await i.fetch(e,r)}catch(n){return null}}}},Nze=Fze;var FL={};it(FL,{default:()=>Tze});var qC=/^[^?]*\.(?:tar\.gz|tgz)(?:\?.*)?$/,JC=/^https?:/;var DL=class{supports(e,r){return qC.test(e.reference)?!!JC.test(e.reference):!1}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the remote server`),loader:()=>this.fetchFromNetwork(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:S.getIdentVendorPath(e),checksum:o}}async fetchFromNetwork(e,r){let i=await Zt.get(e.reference,{configuration:r.project.configuration});return await Ai.convertToZip(i,{compressionLevel:r.project.configuration.get("compressionLevel"),prefixPath:S.getIdentVendorPath(e),stripComponents:1})}};var RL=class{supportsDescriptor(e,r){return qC.test(e.range)?!!JC.test(e.range):!1}supportsLocator(e,r){return qC.test(e.reference)?!!JC.test(e.reference):!1}shouldPersistResolution(e,r){return!0}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){return[S.convertDescriptorToLocator(e)]}async getSatisfying(e,r,i){return null}async resolve(e,r){if(!r.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let i=await r.fetchOptions.fetcher.fetch(e,r.fetchOptions),n=await de.releaseAfterUseAsync(async()=>await Ze.find(i.prefixPath,{baseFs:i.packageFs}),i.releaseFs);return _(P({},e),{version:n.version||"0.0.0",languageName:n.languageName||r.project.configuration.get("defaultLanguageName"),linkType:gt.HARD,conditions:n.getConditions(),dependencies:n.dependencies,peerDependencies:n.peerDependencies,dependenciesMeta:n.dependenciesMeta,peerDependenciesMeta:n.peerDependenciesMeta,bin:n.bin})}};var Lze={fetchers:[DL],resolvers:[RL]},Tze=Lze;var ML={};it(ML,{default:()=>M5e});var Rle=ie(Dle()),TL=ie(require("util")),WC=class extends Be{constructor(){super(...arguments);this.private=Y.Boolean("-p,--private",!1,{description:"Initialize a private package"});this.workspace=Y.Boolean("-w,--workspace",!1,{description:"Initialize a workspace root with a `packages/` directory"});this.install=Y.String("-i,--install",!1,{tolerateBoolean:!0,description:"Initialize a package with a specific bundle that will be locked in the project"});this.usev2=Y.Boolean("-2",!1,{hidden:!0});this.yes=Y.Boolean("-y,--yes",{hidden:!0});this.assumeFreshProject=Y.Boolean("--assume-fresh-project",!1,{hidden:!0})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=typeof this.install=="string"?this.install:this.usev2||this.install===!0?"latest":null;return r!==null?await this.executeProxy(e,r):await this.executeRegular(e)}async executeProxy(e,r){if(e.projectCwd!==null&&e.projectCwd!==this.context.cwd)throw new me("Cannot use the --install flag from within a project subdirectory");T.existsSync(this.context.cwd)||await T.mkdirPromise(this.context.cwd,{recursive:!0});let i=v.join(this.context.cwd,e.get("lockfileFilename"));T.existsSync(i)||await T.writeFilePromise(i,"");let n=await this.cli.run(["set","version",r],{quiet:!0});if(n!==0)return n;let s=[];return this.private&&s.push("-p"),this.workspace&&s.push("-w"),this.yes&&s.push("-y"),await T.mktempPromise(async o=>{let{code:a}=await hr.pipevp("yarn",["init",...s],{cwd:this.context.cwd,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr,env:await Kt.makeScriptEnv({binFolder:o})});return a})}async executeRegular(e){var l;let r=null;try{r=(await Ke.find(e,this.context.cwd)).project}catch{r=null}T.existsSync(this.context.cwd)||await T.mkdirPromise(this.context.cwd,{recursive:!0});let i=await Ze.tryFind(this.context.cwd)||new Ze,n=Object.fromEntries(e.get("initFields").entries());i.load(n),i.name=(l=i.name)!=null?l:S.makeIdent(e.get("initScope"),v.basename(this.context.cwd)),i.packageManager=Zr&&de.isTaggedYarnVersion(Zr)?`yarn@${Zr}`:null,typeof i.raw.private=="undefined"&&(this.private||this.workspace&&i.workspaceDefinitions.length===0)&&(i.private=!0),this.workspace&&i.workspaceDefinitions.length===0&&(await T.mkdirPromise(v.join(this.context.cwd,"packages"),{recursive:!0}),i.workspaceDefinitions=[{pattern:"packages/*"}]);let s={};i.exportTo(s),TL.inspect.styles.name="cyan",this.context.stdout.write(`${(0,TL.inspect)(s,{depth:Infinity,colors:!0,compact:!1})} +`);let o=v.join(this.context.cwd,Ze.fileName);await T.changeFilePromise(o,`${JSON.stringify(s,null,2)} +`,{automaticNewlines:!0});let a=v.join(this.context.cwd,"README.md");if(T.existsSync(a)||await T.writeFilePromise(a,`# ${S.stringifyIdent(i.name)} +`),!r||r.cwd===this.context.cwd){let c=v.join(this.context.cwd,wt.lockfile);T.existsSync(c)||await T.writeFilePromise(c,"");let g=["/.yarn/*","!/.yarn/patches","!/.yarn/plugins","!/.yarn/releases","!/.yarn/sdks","","# Swap the comments on the following lines if you don't wish to use zero-installs","# Documentation here: https://yarnpkg.com/features/zero-installs","!/.yarn/cache","#/.pnp.*"].map(m=>`${m} +`).join(""),f=v.join(this.context.cwd,".gitignore");T.existsSync(f)||await T.writeFilePromise(f,g);let h={["*"]:{endOfLine:"lf",insertFinalNewline:!0},["*.{js,json,yml}"]:{charset:"utf-8",indentStyle:"space",indentSize:2}};(0,Rle.default)(h,e.get("initEditorConfig"));let p=`root = true +`;for(let[m,I]of Object.entries(h)){p+=` +[${m}] +`;for(let[B,b]of Object.entries(I))p+=`${B.replace(/[A-Z]/g,H=>`_${H.toLowerCase()}`)} = ${b} +`}let d=v.join(this.context.cwd,".editorconfig");T.existsSync(d)||await T.writeFilePromise(d,p),T.existsSync(v.join(this.context.cwd,".git"))||await hr.execvp("git",["init"],{cwd:this.context.cwd})}}};WC.paths=[["init"]],WC.usage=ye.Usage({description:"create a new package",details:"\n This command will setup a new package in your local directory.\n\n If the `-p,--private` or `-w,--workspace` options are set, the package will be private by default.\n\n If the `-w,--workspace` option is set, the package will be configured to accept a set of workspaces in the `packages/` directory.\n\n If the `-i,--install` option is given a value, Yarn will first download it using `yarn set version` and only then forward the init call to the newly downloaded bundle. Without arguments, the downloaded bundle will be `latest`.\n\n The initial settings of the manifest can be changed by using the `initScope` and `initFields` configuration values. Additionally, Yarn will generate an EditorConfig file whose rules can be altered via `initEditorConfig`, and will initialize a Git repository in the current directory.\n ",examples:[["Create a new package in the local directory","yarn init"],["Create a new private package in the local directory","yarn init -p"],["Create a new package and store the Yarn release inside","yarn init -i=latest"],["Create a new private package and defines it as a workspace root","yarn init -w"]]});var Fle=WC;var T5e={configuration:{initScope:{description:"Scope used when creating packages via the init command",type:ge.STRING,default:null},initFields:{description:"Additional fields to set when creating packages via the init command",type:ge.MAP,valueDefinition:{description:"",type:ge.ANY}},initEditorConfig:{description:"Extra rules to define in the generator editorconfig",type:ge.MAP,valueDefinition:{description:"",type:ge.ANY}}},commands:[Fle]},M5e=T5e;var GL={};it(GL,{default:()=>K5e});var Ua="portal:",Ha="link:";var OL=class{supports(e,r){return!!e.reference.startsWith(Ua)}getLocalPath(e,r){let{parentLocator:i,path:n}=S.parseFileStyleRange(e.reference,{protocol:Ua});if(v.isAbsolute(n))return n;let s=r.fetcher.getLocalPath(i,r);return s===null?null:v.resolve(s,n)}async fetch(e,r){var c;let{parentLocator:i,path:n}=S.parseFileStyleRange(e.reference,{protocol:Ua}),s=v.isAbsolute(n)?{packageFs:new Ft(Se.root),prefixPath:Se.dot,localPath:Se.root}:await r.fetcher.fetch(i,r),o=s.localPath?{packageFs:new Ft(Se.root),prefixPath:v.relative(Se.root,s.localPath),localPath:Se.root}:s;s!==o&&s.releaseFs&&s.releaseFs();let a=o.packageFs,l=v.resolve((c=o.localPath)!=null?c:o.packageFs.getRealPath(),o.prefixPath,n);return s.localPath?{packageFs:new Ft(l,{baseFs:a}),releaseFs:o.releaseFs,prefixPath:Se.dot,localPath:l}:{packageFs:new Zo(l,{baseFs:a}),releaseFs:o.releaseFs,prefixPath:Se.dot}}};var KL=class{supportsDescriptor(e,r){return!!e.range.startsWith(Ua)}supportsLocator(e,r){return!!e.reference.startsWith(Ua)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){return S.bindDescriptor(e,{locator:S.stringifyLocator(r)})}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){let n=e.range.slice(Ua.length);return[S.makeLocator(e,`${Ua}${M.toPortablePath(n)}`)]}async getSatisfying(e,r,i){return null}async resolve(e,r){if(!r.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let i=await r.fetchOptions.fetcher.fetch(e,r.fetchOptions),n=await de.releaseAfterUseAsync(async()=>await Ze.find(i.prefixPath,{baseFs:i.packageFs}),i.releaseFs);return _(P({},e),{version:n.version||"0.0.0",languageName:n.languageName||r.project.configuration.get("defaultLanguageName"),linkType:gt.SOFT,conditions:n.getConditions(),dependencies:new Map([...n.dependencies]),peerDependencies:n.peerDependencies,dependenciesMeta:n.dependenciesMeta,peerDependenciesMeta:n.peerDependenciesMeta,bin:n.bin})}};var UL=class{supports(e,r){return!!e.reference.startsWith(Ha)}getLocalPath(e,r){let{parentLocator:i,path:n}=S.parseFileStyleRange(e.reference,{protocol:Ha});if(v.isAbsolute(n))return n;let s=r.fetcher.getLocalPath(i,r);return s===null?null:v.resolve(s,n)}async fetch(e,r){var c;let{parentLocator:i,path:n}=S.parseFileStyleRange(e.reference,{protocol:Ha}),s=v.isAbsolute(n)?{packageFs:new Ft(Se.root),prefixPath:Se.dot,localPath:Se.root}:await r.fetcher.fetch(i,r),o=s.localPath?{packageFs:new Ft(Se.root),prefixPath:v.relative(Se.root,s.localPath),localPath:Se.root}:s;s!==o&&s.releaseFs&&s.releaseFs();let a=o.packageFs,l=v.resolve((c=o.localPath)!=null?c:o.packageFs.getRealPath(),o.prefixPath,n);return s.localPath?{packageFs:new Ft(l,{baseFs:a}),releaseFs:o.releaseFs,prefixPath:Se.dot,discardFromLookup:!0,localPath:l}:{packageFs:new Zo(l,{baseFs:a}),releaseFs:o.releaseFs,prefixPath:Se.dot,discardFromLookup:!0}}};var HL=class{supportsDescriptor(e,r){return!!e.range.startsWith(Ha)}supportsLocator(e,r){return!!e.reference.startsWith(Ha)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){return S.bindDescriptor(e,{locator:S.stringifyLocator(r)})}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){let n=e.range.slice(Ha.length);return[S.makeLocator(e,`${Ha}${M.toPortablePath(n)}`)]}async getSatisfying(e,r,i){return null}async resolve(e,r){return _(P({},e),{version:"0.0.0",languageName:r.project.configuration.get("defaultLanguageName"),linkType:gt.SOFT,conditions:null,dependencies:new Map,peerDependencies:new Map,dependenciesMeta:new Map,peerDependenciesMeta:new Map,bin:new Map})}};var O5e={fetchers:[UL,OL],resolvers:[HL,KL]},K5e=O5e;var mT={};it(mT,{default:()=>Y6e});var Ga;(function(i){i[i.YES=0]="YES",i[i.NO=1]="NO",i[i.DEPENDS=2]="DEPENDS"})(Ga||(Ga={}));var jL=(t,e)=>`${t}@${e}`,Nle=(t,e)=>{let r=e.indexOf("#"),i=r>=0?e.substring(r+1):e;return jL(t,i)},qs;(function(s){s[s.NONE=-1]="NONE",s[s.PERF=0]="PERF",s[s.CHECK=1]="CHECK",s[s.REASONS=2]="REASONS",s[s.INTENSIVE_CHECK=9]="INTENSIVE_CHECK"})(qs||(qs={}));var Tle=(t,e={})=>{let r=e.debugLevel||Number(process.env.NM_DEBUG_LEVEL||-1),i=e.check||r>=9,n=e.hoistingLimits||new Map,s={check:i,debugLevel:r,hoistingLimits:n,fastLookupPossible:!0},o;s.debugLevel>=0&&(o=Date.now());let a=U5e(t,s),l=!1,c=0;do l=YL(a,[a],new Set([a.locator]),new Map,s).anotherRoundNeeded,s.fastLookupPossible=!1,c++;while(l);if(s.debugLevel>=0&&console.log(`hoist time: ${Date.now()-o}ms, rounds: ${c}`),s.debugLevel>=1){let u=zC(a);if(YL(a,[a],new Set([a.locator]),new Map,s).isGraphChanged)throw new Error(`The hoisting result is not terminal, prev tree: +${u}, next tree: +${zC(a)}`);let f=Lle(a);if(f)throw new Error(`${f}, after hoisting finished: +${zC(a)}`)}return s.debugLevel>=2&&console.log(zC(a)),H5e(a)},G5e=t=>{let e=t[t.length-1],r=new Map,i=new Set,n=s=>{if(!i.has(s)){i.add(s);for(let o of s.hoistedDependencies.values())r.set(o.name,o);for(let o of s.dependencies.values())s.peerNames.has(o.name)||n(o)}};return n(e),r},j5e=t=>{let e=t[t.length-1],r=new Map,i=new Set,n=new Set,s=(o,a)=>{if(i.has(o))return;i.add(o);for(let c of o.hoistedDependencies.values())if(!a.has(c.name)){let u;for(let g of t)u=g.dependencies.get(c.name),u&&r.set(u.name,u)}let l=new Set;for(let c of o.dependencies.values())l.add(c.name);for(let c of o.dependencies.values())o.peerNames.has(c.name)||s(c,l)};return s(e,n),r},Mle=(t,e)=>{if(e.decoupled)return e;let{name:r,references:i,ident:n,locator:s,dependencies:o,originalDependencies:a,hoistedDependencies:l,peerNames:c,reasons:u,isHoistBorder:g,hoistPriority:f,isWorkspace:h,hoistedFrom:p,hoistedTo:d}=e,m={name:r,references:new Set(i),ident:n,locator:s,dependencies:new Map(o),originalDependencies:new Map(a),hoistedDependencies:new Map(l),peerNames:new Set(c),reasons:new Map(u),decoupled:!0,isHoistBorder:g,hoistPriority:f,isWorkspace:h,hoistedFrom:new Map(p),hoistedTo:new Map(d)},I=m.dependencies.get(r);return I&&I.ident==m.ident&&m.dependencies.set(r,m),t.dependencies.set(m.name,m),m},Y5e=(t,e)=>{let r=new Map([[t.name,[t.ident]]]);for(let n of t.dependencies.values())t.peerNames.has(n.name)||r.set(n.name,[n.ident]);let i=Array.from(e.keys());i.sort((n,s)=>{let o=e.get(n),a=e.get(s);return a.hoistPriority!==o.hoistPriority?a.hoistPriority-o.hoistPriority:a.peerDependents.size!==o.peerDependents.size?a.peerDependents.size-o.peerDependents.size:a.dependents.size-o.dependents.size});for(let n of i){let s=n.substring(0,n.indexOf("@",1)),o=n.substring(s.length+1);if(!t.peerNames.has(s)){let a=r.get(s);a||(a=[],r.set(s,a)),a.indexOf(o)<0&&a.push(o)}}return r},qL=t=>{let e=new Set,r=(i,n=new Set)=>{if(!n.has(i)){n.add(i);for(let s of i.peerNames)if(!t.peerNames.has(s)){let o=t.dependencies.get(s);o&&!e.has(o)&&r(o,n)}e.add(i)}};for(let i of t.dependencies.values())t.peerNames.has(i.name)||r(i);return e},YL=(t,e,r,i,n,s=new Set)=>{let o=e[e.length-1];if(s.has(o))return{anotherRoundNeeded:!1,isGraphChanged:!1};s.add(o);let a=J5e(o),l=Y5e(o,a),c=t==o?new Map:n.fastLookupPossible?G5e(e):j5e(e),u,g=!1,f=!1,h=new Map(Array.from(l.entries()).map(([d,m])=>[d,m[0]])),p=new Map;do{let d=q5e(t,e,r,c,h,l,i,p,n);d.isGraphChanged&&(f=!0),d.anotherRoundNeeded&&(g=!0),u=!1;for(let[m,I]of l)I.length>1&&!o.dependencies.has(m)&&(h.delete(m),I.shift(),h.set(m,I[0]),u=!0)}while(u);for(let d of o.dependencies.values())if(!o.peerNames.has(d.name)&&!r.has(d.locator)){r.add(d.locator);let m=YL(t,[...e,d],r,p,n);m.isGraphChanged&&(f=!0),m.anotherRoundNeeded&&(g=!0),r.delete(d.locator)}return{anotherRoundNeeded:g,isGraphChanged:f}},W5e=(t,e,r,i,n,s,o,a,{outputReason:l,fastLookupPossible:c})=>{let u,g=null,f=new Set;l&&(u=`${Array.from(e).map(m=>wi(m)).join("\u2192")}`);let h=r[r.length-1],d=!(i.ident===h.ident);if(l&&!d&&(g="- self-reference"),d&&(d=!i.isWorkspace,l&&!d&&(g="- workspace")),d&&(d=!h.isWorkspace||h.hoistedFrom.has(i.name)||e.size===1,l&&!d&&(g=h.reasons.get(i.name))),d&&(d=!t.peerNames.has(i.name),l&&!d&&(g=`- cannot shadow peer: ${wi(t.originalDependencies.get(i.name).locator)} at ${u}`)),d){let m=!1,I=n.get(i.name);if(m=!I||I.ident===i.ident,l&&!m&&(g=`- filled by: ${wi(I.locator)} at ${u}`),m)for(let B=r.length-1;B>=1;B--){let R=r[B].dependencies.get(i.name);if(R&&R.ident!==i.ident){m=!1;let H=a.get(h);H||(H=new Set,a.set(h,H)),H.add(i.name),l&&(g=`- filled by ${wi(R.locator)} at ${r.slice(0,B).map(L=>wi(L.locator)).join("\u2192")}`);break}}d=m}if(d&&(d=s.get(i.name)===i.ident,l&&!d&&(g=`- filled by: ${wi(o.get(i.name)[0])} at ${u}`)),d){let m=!0,I=new Set(i.peerNames);for(let B=r.length-1;B>=1;B--){let b=r[B];for(let R of I){if(b.peerNames.has(R)&&b.originalDependencies.has(R))continue;let H=b.dependencies.get(R);H&&t.dependencies.get(R)!==H&&(B===r.length-1?f.add(H):(f=null,m=!1,l&&(g=`- peer dependency ${wi(H.locator)} from parent ${wi(b.locator)} was not hoisted to ${u}`))),I.delete(R)}if(!m)break}d=m}if(d&&!c)for(let m of i.hoistedDependencies.values()){let I=n.get(m.name);if(!I||m.ident!==I.ident){d=!1,l&&(g=`- previously hoisted dependency mismatch, needed: ${wi(m.locator)}, available: ${wi(I==null?void 0:I.locator)}`);break}}return f!==null&&f.size>0?{isHoistable:2,dependsOn:f,reason:g}:{isHoistable:d?0:1,reason:g}},q5e=(t,e,r,i,n,s,o,a,l)=>{let c=e[e.length-1],u=new Set,g=!1,f=!1,h=(m,I,B,b)=>{if(u.has(B))return;let R=[...I,B.locator],H=new Map,L=new Map;for(let q of qL(B)){let A=W5e(c,r,[c,...m,B],q,i,n,s,a,{outputReason:l.debugLevel>=2,fastLookupPossible:l.fastLookupPossible});if(L.set(q,A),A.isHoistable===2)for(let V of A.dependsOn){let W=H.get(V.name)||new Set;W.add(q.name),H.set(V.name,W)}}let K=new Set,J=(q,A,V)=>{if(!K.has(q)){K.add(q),L.set(q,{isHoistable:1,reason:V});for(let W of H.get(q.name)||[])J(B.dependencies.get(W),A,l.debugLevel>=2?`- peer dependency ${wi(q.locator)} from parent ${wi(B.locator)} was not hoisted`:"")}};for(let[q,A]of L)A.isHoistable===1&&J(q,A,A.reason);for(let q of L.keys())if(!K.has(q)){f=!0;let A=o.get(B);A&&A.has(q.name)&&(g=!0),B.dependencies.delete(q.name),B.hoistedDependencies.set(q.name,q),B.reasons.delete(q.name);let V=c.dependencies.get(q.name);if(l.debugLevel>=2){let W=Array.from(I).concat([B.locator]).map(F=>wi(F)).join("\u2192"),X=c.hoistedFrom.get(q.name);X||(X=[],c.hoistedFrom.set(q.name,X)),X.push(W),B.hoistedTo.set(q.name,Array.from(e).map(F=>wi(F.locator)).join("\u2192"))}if(!V)c.ident!==q.ident&&(c.dependencies.set(q.name,q),b.add(q));else for(let W of q.references)V.references.add(W)}if(l.check){let q=Lle(t);if(q)throw new Error(`${q}, after hoisting dependencies of ${[c,...m,B].map(A=>wi(A.locator)).join("\u2192")}: +${zC(t)}`)}let ne=qL(B);for(let q of ne)if(K.has(q)){let A=L.get(q);if((n.get(q.name)===q.ident||!B.reasons.has(q.name))&&A.isHoistable!==0&&B.reasons.set(q.name,A.reason),!q.isHoistBorder&&R.indexOf(q.locator)<0){u.add(B);let W=Mle(B,q);h([...m,B],[...I,B.locator],W,d),u.delete(B)}}},p,d=new Set(qL(c));do{p=d,d=new Set;for(let m of p){if(m.locator===c.locator||m.isHoistBorder)continue;let I=Mle(c,m);h([],Array.from(r),I,d)}}while(d.size>0);return{anotherRoundNeeded:g,isGraphChanged:f}},Lle=t=>{let e=[],r=new Set,i=new Set,n=(s,o,a)=>{if(r.has(s)||(r.add(s),i.has(s)))return;let l=new Map(o);for(let c of s.dependencies.values())s.peerNames.has(c.name)||l.set(c.name,c);for(let c of s.originalDependencies.values()){let u=l.get(c.name),g=()=>`${Array.from(i).concat([s]).map(f=>wi(f.locator)).join("\u2192")}`;if(s.peerNames.has(c.name)){let f=o.get(c.name);(f!==u||!f||f.ident!==c.ident)&&e.push(`${g()} - broken peer promise: expected ${c.ident} but found ${f&&f.ident}`)}else{let f=a.hoistedFrom.get(s.name),h=s.hoistedTo.get(c.name),p=`${f?` hoisted from ${f.join(", ")}`:""}`,d=`${h?` hoisted to ${h}`:""}`,m=`${g()}${p}`;u?u.ident!==c.ident&&e.push(`${m} - broken require promise for ${c.name}${d}: expected ${c.ident}, but found: ${u.ident}`):e.push(`${m} - broken require promise: no required dependency ${c.name}${d} found`)}}i.add(s);for(let c of s.dependencies.values())s.peerNames.has(c.name)||n(c,l,s);i.delete(s)};return n(t,t.dependencies,t),e.join(` +`)},U5e=(t,e)=>{let{identName:r,name:i,reference:n,peerNames:s}=t,o={name:i,references:new Set([n]),locator:jL(r,n),ident:Nle(r,n),dependencies:new Map,originalDependencies:new Map,hoistedDependencies:new Map,peerNames:new Set(s),reasons:new Map,decoupled:!0,isHoistBorder:!0,hoistPriority:0,isWorkspace:!0,hoistedFrom:new Map,hoistedTo:new Map},a=new Map([[t,o]]),l=(c,u)=>{let g=a.get(c),f=!!g;if(!g){let{name:h,identName:p,reference:d,peerNames:m,hoistPriority:I,isWorkspace:B}=c,b=e.hoistingLimits.get(u.locator);g={name:h,references:new Set([d]),locator:jL(p,d),ident:Nle(p,d),dependencies:new Map,originalDependencies:new Map,hoistedDependencies:new Map,peerNames:new Set(m),reasons:new Map,decoupled:!0,isHoistBorder:b?b.has(h):!1,hoistPriority:I||0,isWorkspace:B||!1,hoistedFrom:new Map,hoistedTo:new Map},a.set(c,g)}if(u.dependencies.set(c.name,g),u.originalDependencies.set(c.name,g),f){let h=new Set,p=d=>{if(!h.has(d)){h.add(d),d.decoupled=!1;for(let m of d.dependencies.values())d.peerNames.has(m.name)||p(m)}};p(g)}else for(let h of c.dependencies)l(h,g)};for(let c of t.dependencies)l(c,o);return o},JL=t=>t.substring(0,t.indexOf("@",1)),H5e=t=>{let e={name:t.name,identName:JL(t.locator),references:new Set(t.references),dependencies:new Set},r=new Set([t]),i=(n,s,o)=>{let a=r.has(n),l;if(s===n)l=o;else{let{name:c,references:u,locator:g}=n;l={name:c,identName:JL(g),references:u,dependencies:new Set}}if(o.dependencies.add(l),!a){r.add(n);for(let c of n.dependencies.values())n.peerNames.has(c.name)||i(c,n,l);r.delete(n)}};for(let n of t.dependencies.values())i(n,t,e);return e},J5e=t=>{let e=new Map,r=new Set([t]),i=o=>`${o.name}@${o.ident}`,n=o=>{let a=i(o),l=e.get(a);return l||(l={dependents:new Set,peerDependents:new Set,hoistPriority:0},e.set(a,l)),l},s=(o,a)=>{let l=!!r.has(a);if(n(a).dependents.add(o.ident),!l){r.add(a);for(let u of a.dependencies.values()){let g=n(u);g.hoistPriority=Math.max(g.hoistPriority,u.hoistPriority),a.peerNames.has(u.name)?g.peerDependents.add(a.ident):s(a,u)}}};for(let o of t.dependencies.values())t.peerNames.has(o.name)||s(t,o);return e},wi=t=>{if(!t)return"none";let e=t.indexOf("@",1),r=t.substring(0,e);r.endsWith("$wsroot$")&&(r=`wh:${r.replace("$wsroot$","")}`);let i=t.substring(e+1);if(i==="workspace:.")return".";if(i){let n=(i.indexOf("#")>0?i.split("#")[1]:i).replace("npm:","");return i.startsWith("virtual")&&(r=`v:${r}`),n.startsWith("workspace")&&(r=`w:${r}`,n=""),`${r}${n?`@${n}`:""}`}else return`${r}`},Ole=5e4,zC=t=>{let e=0,r=(n,s,o="")=>{if(e>Ole||s.has(n))return"";e++;let a=Array.from(n.dependencies.values()).sort((c,u)=>c.name.localeCompare(u.name)),l="";s.add(n);for(let c=0;c":"")+(f!==u.name?`a:${u.name}:`:"")+wi(u.locator)+(g?` ${g}`:"")+(u!==n&&h.length>0?`, hoisted from: ${h.join(", ")}`:"")} +`,l+=r(u,s,`${o}${cOle?` +Tree is too large, part of the tree has been dunped +`:"")};var Js;(function(r){r.HARD="HARD",r.SOFT="SOFT"})(Js||(Js={}));var Sn;(function(i){i.WORKSPACES="workspaces",i.DEPENDENCIES="dependencies",i.NONE="none"})(Sn||(Sn={}));var Kle="node_modules",Hc="$wsroot$";var VC=(t,e)=>{let{packageTree:r,hoistingLimits:i,errors:n,preserveSymlinksRequired:s}=z5e(t,e),o=null;if(n.length===0){let a=Tle(r,{hoistingLimits:i});o=V5e(t,a,e)}return{tree:o,errors:n,preserveSymlinksRequired:s}},ms=t=>`${t.name}@${t.reference}`,WL=t=>{let e=new Map;for(let[r,i]of t.entries())if(!i.dirList){let n=e.get(i.locator);n||(n={target:i.target,linkType:i.linkType,locations:[],aliases:i.aliases},e.set(i.locator,n)),n.locations.push(r)}for(let r of e.values())r.locations=r.locations.sort((i,n)=>{let s=i.split(v.delimiter).length,o=n.split(v.delimiter).length;return s!==o?o-s:n.localeCompare(i)});return e},Ule=(t,e)=>{let r=S.isVirtualLocator(t)?S.devirtualizeLocator(t):t,i=S.isVirtualLocator(e)?S.devirtualizeLocator(e):e;return S.areLocatorsEqual(r,i)},zL=(t,e,r,i)=>{if(t.linkType!==Js.SOFT)return!1;let n=M.toPortablePath(r.resolveVirtual&&e.reference&&e.reference.startsWith("virtual:")?r.resolveVirtual(t.packageLocation):t.packageLocation);return v.contains(i,n)===null},_5e=t=>{let e=t.getPackageInformation(t.topLevel);if(e===null)throw new Error("Assertion failed: Expected the top-level package to have been registered");if(t.findPackageLocator(e.packageLocation)===null)throw new Error("Assertion failed: Expected the top-level package to have a physical locator");let i=M.toPortablePath(e.packageLocation.slice(0,-1)),n=new Map,s={children:new Map},o=t.getDependencyTreeRoots(),a=new Map,l=new Set,c=(f,h)=>{let p=ms(f);if(l.has(p))return;l.add(p);let d=t.getPackageInformation(f);if(d){let m=h?ms(h):"";if(ms(f)!==m&&d.linkType===Js.SOFT&&!zL(d,f,t,i)){let I=Hle(d,f,t);(!a.get(I)||f.reference.startsWith("workspace:"))&&a.set(I,f)}for(let[I,B]of d.packageDependencies)B!==null&&(d.packagePeers.has(I)||c(t.getLocator(I,B),f))}};for(let f of o)c(f,null);let u=i.split(v.sep);for(let f of a.values()){let h=t.getPackageInformation(f),d=M.toPortablePath(h.packageLocation.slice(0,-1)).split(v.sep).slice(u.length),m=s;for(let I of d){let B=m.children.get(I);B||(B={children:new Map},m.children.set(I,B)),m=B}m.workspaceLocator=f}let g=(f,h)=>{if(f.workspaceLocator){let p=ms(h),d=n.get(p);d||(d=new Set,n.set(p,d)),d.add(f.workspaceLocator)}for(let p of f.children.values())g(p,f.workspaceLocator||h)};for(let f of s.children.values())g(f,s.workspaceLocator);return n},z5e=(t,e)=>{let r=[],i=!1,n=new Map,s=_5e(t),o=t.getPackageInformation(t.topLevel);if(o===null)throw new Error("Assertion failed: Expected the top-level package to have been registered");let a=t.findPackageLocator(o.packageLocation);if(a===null)throw new Error("Assertion failed: Expected the top-level package to have a physical locator");let l=M.toPortablePath(o.packageLocation.slice(0,-1)),c={name:a.name,identName:a.name,reference:a.reference,peerNames:o.packagePeers,dependencies:new Set,isWorkspace:!0},u=new Map,g=(h,p)=>`${ms(p)}:${h}`,f=(h,p,d,m,I,B,b,R)=>{var X,F;let H=g(h,d),L=u.get(H),K=!!L;!K&&d.name===a.name&&d.reference===a.reference&&(L=c,u.set(H,c));let J=zL(p,d,t,l);if(!L){let D=p.linkType===Js.SOFT&&d.name.endsWith(Hc);L={name:h,identName:d.name,reference:d.reference,dependencies:new Set,peerNames:D?new Set:p.packagePeers,isWorkspace:D},u.set(H,L)}let ne;if(J?ne=2:I.linkType===Js.SOFT?ne=1:ne=0,L.hoistPriority=Math.max(L.hoistPriority||0,ne),R&&!J){let D=ms({name:m.identName,reference:m.reference}),he=n.get(D)||new Set;n.set(D,he),he.add(L.name)}let q=new Map(p.packageDependencies);if(e.project){let D=e.project.workspacesByCwd.get(M.toPortablePath(p.packageLocation.slice(0,-1)));if(D){let he=new Set([...Array.from(D.manifest.peerDependencies.values(),pe=>S.stringifyIdent(pe)),...Array.from(D.manifest.peerDependenciesMeta.keys())]);for(let pe of he)q.has(pe)||(q.set(pe,B.get(pe)||null),L.peerNames.add(pe))}}let A=ms({name:d.name.replace(Hc,""),reference:d.reference}),V=s.get(A);if(V)for(let D of V)q.set(`${D.name}${Hc}`,D.reference);(p!==I||p.linkType!==Js.SOFT||!e.selfReferencesByCwd||e.selfReferencesByCwd.get(b))&&m.dependencies.add(L);let W=d!==a&&p.linkType===Js.SOFT&&!d.name.endsWith(Hc)&&!J;if(!K&&!W){let D=new Map;for(let[he,pe]of q)if(pe!==null){let Ne=t.getLocator(he,pe),Pe=t.getLocator(he.replace(Hc,""),pe),qe=t.getPackageInformation(Pe);if(qe===null)throw new Error("Assertion failed: Expected the package to have been registered");let re=zL(qe,Ne,t,l);if(e.validateExternalSoftLinks&&e.project&&re){qe.packageDependencies.size>0&&(i=!0);for(let[De,$]of qe.packageDependencies)if($!==null){let G=S.parseLocator(Array.isArray($)?`${$[0]}@${$[1]}`:`${De}@${$}`);if(ms(G)!==ms(Ne)){let Ce=q.get(De);if(Ce){let ee=S.parseLocator(Array.isArray(Ce)?`${Ce[0]}@${Ce[1]}`:`${De}@${Ce}`);Ule(ee,G)||r.push({messageName:z.NM_CANT_INSTALL_EXTERNAL_SOFT_LINK,text:`Cannot link ${S.prettyIdent(e.project.configuration,S.parseIdent(Ne.name))} into ${S.prettyLocator(e.project.configuration,S.parseLocator(`${d.name}@${d.reference}`))} dependency ${S.prettyLocator(e.project.configuration,G)} conflicts with parent dependency ${S.prettyLocator(e.project.configuration,ee)}`})}else{let ee=D.get(De);if(ee){let Ue=ee.target,Oe=S.parseLocator(Array.isArray(Ue)?`${Ue[0]}@${Ue[1]}`:`${De}@${Ue}`);Ule(Oe,G)||r.push({messageName:z.NM_CANT_INSTALL_EXTERNAL_SOFT_LINK,text:`Cannot link ${S.prettyIdent(e.project.configuration,S.parseIdent(Ne.name))} into ${S.prettyLocator(e.project.configuration,S.parseLocator(`${d.name}@${d.reference}`))} dependency ${S.prettyLocator(e.project.configuration,G)} conflicts with dependency ${S.prettyLocator(e.project.configuration,Oe)} from sibling portal ${S.prettyIdent(e.project.configuration,S.parseIdent(ee.portal.name))}`})}else D.set(De,{target:G.reference,portal:Ne})}}}}let se=(X=e.hoistingLimitsByCwd)==null?void 0:X.get(b),be=re?b:v.relative(l,M.toPortablePath(qe.packageLocation))||Se.dot,ae=(F=e.hoistingLimitsByCwd)==null?void 0:F.get(be),Ae=se===Sn.DEPENDENCIES||ae===Sn.DEPENDENCIES||ae===Sn.WORKSPACES;f(ms(Ne)===ms(d)?h:he,qe,Ne,L,p,q,be,Ae)}}};return f(a.name,o,a,c,o,o.packageDependencies,Se.dot,!1),{packageTree:c,hoistingLimits:n,errors:r,preserveSymlinksRequired:i}};function Hle(t,e,r){let i=r.resolveVirtual&&e.reference&&e.reference.startsWith("virtual:")?r.resolveVirtual(t.packageLocation):t.packageLocation;return M.toPortablePath(i||t.packageLocation)}function X5e(t,e,r){let i=e.getLocator(t.name.replace(Hc,""),t.reference),n=e.getPackageInformation(i);if(n===null)throw new Error("Assertion failed: Expected the package to be registered");let s,o;return r.pnpifyFs?(o=M.toPortablePath(n.packageLocation),s=Js.SOFT):(o=Hle(n,t,e),s=n.linkType),{linkType:s,target:o}}var V5e=(t,e,r)=>{let i=new Map,n=(u,g,f)=>{let{linkType:h,target:p}=X5e(u,t,r);return{locator:ms(u),nodePath:g,target:p,linkType:h,aliases:f}},s=u=>{let[g,f]=u.split("/");return f?{scope:kr(g),name:kr(f)}:{scope:null,name:kr(g)}},o=new Set,a=(u,g,f)=>{if(!o.has(u)){o.add(u);for(let h of u.dependencies){if(h===u)continue;let p=Array.from(h.references).sort(),d={name:h.identName,reference:p[0]},{name:m,scope:I}=s(h.name),B=I?[I,m]:[m],b=v.join(g,Kle),R=v.join(b,...B),H=`${f}/${d.name}`,L=n(d,f,p.slice(1)),K=!1;if(L.linkType===Js.SOFT&&r.project){let J=r.project.workspacesByCwd.get(L.target.slice(0,-1));K=!!(J&&!J.manifest.name)}if(!h.name.endsWith(Hc)&&!K){let J=i.get(R);if(J){if(J.dirList)throw new Error(`Assertion failed: ${R} cannot merge dir node with leaf node`);{let V=S.parseLocator(J.locator),W=S.parseLocator(L.locator);if(J.linkType!==L.linkType)throw new Error(`Assertion failed: ${R} cannot merge nodes with different link types ${J.nodePath}/${S.stringifyLocator(V)} and ${f}/${S.stringifyLocator(W)}`);if(V.identHash!==W.identHash)throw new Error(`Assertion failed: ${R} cannot merge nodes with different idents ${J.nodePath}/${S.stringifyLocator(V)} and ${f}/s${S.stringifyLocator(W)}`);L.aliases=[...L.aliases,...J.aliases,S.parseLocator(J.locator).reference]}}i.set(R,L);let ne=R.split("/"),q=ne.indexOf(Kle),A=ne.length-1;for(;q>=0&&A>q;){let V=M.toPortablePath(ne.slice(0,A).join(v.sep)),W=kr(ne[A]),X=i.get(V);if(!X)i.set(V,{dirList:new Set([W])});else if(X.dirList){if(X.dirList.has(W))break;X.dirList.add(W)}A--}}a(h,L.linkType===Js.SOFT?L.target:R,H)}}},l=n({name:e.name,reference:Array.from(e.references)[0]},"",[]),c=l.target;return i.set(c,l),a(e,c,""),i};var oT={};it(oT,{PnpInstaller:()=>Cf,PnpLinker:()=>jc,default:()=>m6e,getPnpPath:()=>qA,jsInstallUtils:()=>Ws,pnpUtils:()=>nT,quotePathIfNeeded:()=>uce});var lce=ie(Or()),cce=ie(require("url"));var Gle;(function(r){r.HARD="HARD",r.SOFT="SOFT"})(Gle||(Gle={}));var Ht;(function(f){f.DEFAULT="DEFAULT",f.TOP_LEVEL="TOP_LEVEL",f.FALLBACK_EXCLUSION_LIST="FALLBACK_EXCLUSION_LIST",f.FALLBACK_EXCLUSION_ENTRIES="FALLBACK_EXCLUSION_ENTRIES",f.FALLBACK_EXCLUSION_DATA="FALLBACK_EXCLUSION_DATA",f.PACKAGE_REGISTRY_DATA="PACKAGE_REGISTRY_DATA",f.PACKAGE_REGISTRY_ENTRIES="PACKAGE_REGISTRY_ENTRIES",f.PACKAGE_STORE_DATA="PACKAGE_STORE_DATA",f.PACKAGE_STORE_ENTRIES="PACKAGE_STORE_ENTRIES",f.PACKAGE_INFORMATION_DATA="PACKAGE_INFORMATION_DATA",f.PACKAGE_DEPENDENCIES="PACKAGE_DEPENDENCIES",f.PACKAGE_DEPENDENCY="PACKAGE_DEPENDENCY"})(Ht||(Ht={}));var jle={[Ht.DEFAULT]:{collapsed:!1,next:{["*"]:Ht.DEFAULT}},[Ht.TOP_LEVEL]:{collapsed:!1,next:{fallbackExclusionList:Ht.FALLBACK_EXCLUSION_LIST,packageRegistryData:Ht.PACKAGE_REGISTRY_DATA,["*"]:Ht.DEFAULT}},[Ht.FALLBACK_EXCLUSION_LIST]:{collapsed:!1,next:{["*"]:Ht.FALLBACK_EXCLUSION_ENTRIES}},[Ht.FALLBACK_EXCLUSION_ENTRIES]:{collapsed:!0,next:{["*"]:Ht.FALLBACK_EXCLUSION_DATA}},[Ht.FALLBACK_EXCLUSION_DATA]:{collapsed:!0,next:{["*"]:Ht.DEFAULT}},[Ht.PACKAGE_REGISTRY_DATA]:{collapsed:!1,next:{["*"]:Ht.PACKAGE_REGISTRY_ENTRIES}},[Ht.PACKAGE_REGISTRY_ENTRIES]:{collapsed:!0,next:{["*"]:Ht.PACKAGE_STORE_DATA}},[Ht.PACKAGE_STORE_DATA]:{collapsed:!1,next:{["*"]:Ht.PACKAGE_STORE_ENTRIES}},[Ht.PACKAGE_STORE_ENTRIES]:{collapsed:!0,next:{["*"]:Ht.PACKAGE_INFORMATION_DATA}},[Ht.PACKAGE_INFORMATION_DATA]:{collapsed:!1,next:{packageDependencies:Ht.PACKAGE_DEPENDENCIES,["*"]:Ht.DEFAULT}},[Ht.PACKAGE_DEPENDENCIES]:{collapsed:!1,next:{["*"]:Ht.PACKAGE_DEPENDENCY}},[Ht.PACKAGE_DEPENDENCY]:{collapsed:!0,next:{["*"]:Ht.DEFAULT}}};function Z5e(t,e,r){let i="";i+="[";for(let n=0,s=t.length;ns(o)));let n=r.map((s,o)=>o);return n.sort((s,o)=>{for(let a of i){let l=a[s]a[o]?1:0;if(l!==0)return l}return 0}),n.map(s=>r[s])}function r6e(t){let e=new Map,r=_C(t.fallbackExclusionList||[],[({name:i,reference:n})=>i,({name:i,reference:n})=>n]);for(let{name:i,reference:n}of r){let s=e.get(i);typeof s=="undefined"&&e.set(i,s=new Set),s.add(n)}return Array.from(e).map(([i,n])=>[i,Array.from(n)])}function i6e(t){return _C(t.fallbackPool||[],([e])=>e)}function n6e(t){let e=[];for(let[r,i]of _C(t.packageRegistry,([n])=>n===null?"0":`1${n}`)){let n=[];e.push([r,n]);for(let[s,{packageLocation:o,packageDependencies:a,packagePeers:l,linkType:c,discardFromLookup:u}]of _C(i,([g])=>g===null?"0":`1${g}`)){let g=[];r!==null&&s!==null&&!a.has(r)&&g.push([r,s]);for(let[p,d]of _C(a.entries(),([m])=>m))g.push([p,d]);let f=l&&l.size>0?Array.from(l):void 0,h=u||void 0;n.push([s,{packageLocation:o,packageDependencies:g,packagePeers:f,linkType:c,discardFromLookup:h}])}}return e}function XC(t){return{__info:["This file is automatically generated. Do not touch it, or risk","your modifications being lost. We also recommend you not to read","it either without using the @yarnpkg/pnp package, as the data layout","is entirely unspecified and WILL change from a version to another."],dependencyTreeRoots:t.dependencyTreeRoots,enableTopLevelFallback:t.enableTopLevelFallback||!1,ignorePatternData:t.ignorePattern||null,fallbackExclusionList:r6e(t),fallbackPool:i6e(t),packageRegistryData:n6e(t)}}var zle=ie(Wle());function Vle(t,e){return[t?`${t} +`:"",`/* eslint-disable */ + +`,`try { +`,` Object.freeze({}).detectStrictMode = true; +`,`} catch (error) { +`," throw new Error(`The whole PnP file got strict-mode-ified, which is known to break (Emscripten libraries aren't strict mode). This usually happens when the file goes through Babel.`);\n",`} +`,` +`,`var __non_webpack_module__ = module; +`,` +`,`function $$SETUP_STATE(hydrateRuntimeState, basePath) { +`,e.replace(/^/gm," "),`} +`,` +`,(0,zle.default)()].join("")}function s6e(t){return JSON.stringify(t,null,2)}function o6e(t){return[`return hydrateRuntimeState(${qle(t)}, {basePath: basePath || __dirname}); +`].join("")}function a6e(t){return[`var path = require('path'); +`,`var dataLocation = path.resolve(__dirname, ${JSON.stringify(t)}); +`,`return hydrateRuntimeState(require(dataLocation), {basePath: basePath || path.dirname(dataLocation)}); +`].join("")}function _le(t){let e=XC(t),r=o6e(e);return Vle(t.shebang,r)}function Xle(t){let e=XC(t),r=a6e(t.dataLocation),i=Vle(t.shebang,r);return{dataFile:s6e(e),loaderFile:i}}var tce=ie(require("fs")),u6e=ie(require("path")),rce=ie(require("util"));function _L(t,{basePath:e}){let r=M.toPortablePath(e),i=v.resolve(r),n=t.ignorePatternData!==null?new RegExp(t.ignorePatternData):null,s=new Map,o=new Map(t.packageRegistryData.map(([g,f])=>[g,new Map(f.map(([h,p])=>{var b;if(g===null!=(h===null))throw new Error("Assertion failed: The name and reference should be null, or neither should");let d=(b=p.discardFromLookup)!=null?b:!1,m={name:g,reference:h},I=s.get(p.packageLocation);I?(I.discardFromLookup=I.discardFromLookup&&d,d||(I.locator=m)):s.set(p.packageLocation,{locator:m,discardFromLookup:d});let B=null;return[h,{packageDependencies:new Map(p.packageDependencies),packagePeers:new Set(p.packagePeers),linkType:p.linkType,discardFromLookup:d,get packageLocation(){return B||(B=v.join(i,p.packageLocation))}}]}))])),a=new Map(t.fallbackExclusionList.map(([g,f])=>[g,new Set(f)])),l=new Map(t.fallbackPool),c=t.dependencyTreeRoots,u=t.enableTopLevelFallback;return{basePath:r,dependencyTreeRoots:c,enableTopLevelFallback:u,fallbackExclusionList:a,fallbackPool:l,ignorePattern:n,packageLocatorsByLocations:s,packageRegistry:o}}var df=ie(require("module")),ece=ie($le()),ZL=ie(require("util"));var ur;(function(l){l.API_ERROR="API_ERROR",l.BUILTIN_NODE_RESOLUTION_FAILED="BUILTIN_NODE_RESOLUTION_FAILED",l.MISSING_DEPENDENCY="MISSING_DEPENDENCY",l.MISSING_PEER_DEPENDENCY="MISSING_PEER_DEPENDENCY",l.QUALIFIED_PATH_RESOLUTION_FAILED="QUALIFIED_PATH_RESOLUTION_FAILED",l.INTERNAL="INTERNAL",l.UNDECLARED_DEPENDENCY="UNDECLARED_DEPENDENCY",l.UNSUPPORTED="UNSUPPORTED"})(ur||(ur={}));var c6e=new Set([ur.BUILTIN_NODE_RESOLUTION_FAILED,ur.MISSING_DEPENDENCY,ur.MISSING_PEER_DEPENDENCY,ur.QUALIFIED_PATH_RESOLUTION_FAILED,ur.UNDECLARED_DEPENDENCY]);function ui(t,e,r={}){let i=c6e.has(t)?"MODULE_NOT_FOUND":t,n={configurable:!0,writable:!0,enumerable:!1};return Object.defineProperties(new Error(e),{code:_(P({},n),{value:i}),pnpCode:_(P({},n),{value:t}),data:_(P({},n),{value:r})})}function YA(t){return M.normalize(M.fromPortablePath(t))}function $L(t,e){let r=Number(process.env.PNP_ALWAYS_WARN_ON_FALLBACK)>0,i=Number(process.env.PNP_DEBUG_LEVEL),n=new Set(df.Module.builtinModules||Object.keys(process.binding("natives"))),s=re=>n.has(re)||re.startsWith("node:"),o=/^(?![a-zA-Z]:[\\/]|\\\\|\.{0,2}(?:\/|$))((?:node:)?(?:@[^/]+\/)?[^/]+)\/*(.*|)$/,a=/^(\/|\.{1,2}(\/|$))/,l=/\/$/,c=/^\.{0,2}\//,u={name:null,reference:null},g=[],f=new Set;if(t.enableTopLevelFallback===!0&&g.push(u),e.compatibilityMode!==!1)for(let re of["react-scripts","gatsby"]){let se=t.packageRegistry.get(re);if(se)for(let be of se.keys()){if(be===null)throw new Error("Assertion failed: This reference shouldn't be null");g.push({name:re,reference:be})}}let{ignorePattern:h,packageRegistry:p,packageLocatorsByLocations:d}=t;function m(re,se){return{fn:re,args:se,error:null,result:null}}function I(re){var De,$,G,Ce,ee,Ue;let se=(G=($=(De=process.stderr)==null?void 0:De.hasColors)==null?void 0:$.call(De))!=null?G:process.stdout.isTTY,be=(Oe,vt)=>`[${Oe}m${vt}`,ae=re.error;console.error(ae?be("31;1",`\u2716 ${(Ce=re.error)==null?void 0:Ce.message.replace(/\n.*/s,"")}`):be("33;1","\u203C Resolution")),re.args.length>0&&console.error();for(let Oe of re.args)console.error(` ${be("37;1","In \u2190")} ${(0,ZL.inspect)(Oe,{colors:se,compact:!0})}`);re.result&&(console.error(),console.error(` ${be("37;1","Out \u2192")} ${(0,ZL.inspect)(re.result,{colors:se,compact:!0})}`));let Ae=(Ue=(ee=new Error().stack.match(/(?<=^ +)at.*/gm))==null?void 0:ee.slice(2))!=null?Ue:[];if(Ae.length>0){console.error();for(let Oe of Ae)console.error(` ${be("38;5;244",Oe)}`)}console.error()}function B(re,se){if(e.allowDebug===!1)return se;if(Number.isFinite(i)){if(i>=2)return(...be)=>{let ae=m(re,be);try{return ae.result=se(...be)}catch(Ae){throw ae.error=Ae}finally{I(ae)}};if(i>=1)return(...be)=>{try{return se(...be)}catch(ae){let Ae=m(re,be);throw Ae.error=ae,I(Ae),ae}}}return se}function b(re){let se=W(re);if(!se)throw ui(ur.INTERNAL,"Couldn't find a matching entry in the dependency tree for the specified parent (this is probably an internal error)");return se}function R(re){if(re.name===null)return!0;for(let se of t.dependencyTreeRoots)if(se.name===re.name&&se.reference===re.reference)return!0;return!1}let H=new Set(["default","node","require"]);function L(re,se=H){let be=D(v.join(re,"internal.js"),{resolveIgnored:!0,includeDiscardFromLookup:!0});if(be===null)throw ui(ur.INTERNAL,`The locator that owns the "${re}" path can't be found inside the dependency tree (this is probably an internal error)`);let{packageLocation:ae}=b(be),Ae=v.join(ae,wt.manifest);if(!e.fakeFs.existsSync(Ae))return null;let De=JSON.parse(e.fakeFs.readFileSync(Ae,"utf8")),$=v.contains(ae,re);if($===null)throw ui(ur.INTERNAL,"unqualifiedPath doesn't contain the packageLocation (this is probably an internal error)");c.test($)||($=`./${$}`);let G=(0,ece.resolve)(De,v.normalize($),{conditions:se,unsafe:!0});return typeof G=="string"?v.join(ae,G):null}function K(re,se,{extensions:be}){let ae;try{se.push(re),ae=e.fakeFs.statSync(re)}catch(Ae){}if(ae&&!ae.isDirectory())return e.fakeFs.realpathSync(re);if(ae&&ae.isDirectory()){let Ae;try{Ae=JSON.parse(e.fakeFs.readFileSync(v.join(re,wt.manifest),"utf8"))}catch($){}let De;if(Ae&&Ae.main&&(De=v.resolve(re,Ae.main)),De&&De!==re){let $=K(De,se,{extensions:be});if($!==null)return $}}for(let Ae=0,De=be.length;Ae{let G=JSON.stringify($.name);if(ae.has(G))return;ae.add(G);let Ce=X($);for(let ee of Ce)if(b(ee).packagePeers.has(re))Ae(ee);else{let Oe=be.get(ee.name);typeof Oe=="undefined"&&be.set(ee.name,Oe=new Set),Oe.add(ee.reference)}};Ae(se);let De=[];for(let $ of[...be.keys()].sort())for(let G of[...be.get($)].sort())De.push({name:$,reference:G});return De}function D(re,{resolveIgnored:se=!1,includeDiscardFromLookup:be=!1}={}){if(q(re)&&!se)return null;let ae=v.relative(t.basePath,re);ae.match(a)||(ae=`./${ae}`),ae.endsWith("/")||(ae=`${ae}/`);do{let Ae=d.get(ae);if(typeof Ae=="undefined"||Ae.discardFromLookup&&!be){ae=ae.substring(0,ae.lastIndexOf("/",ae.length-2)+1);continue}return Ae.locator}while(ae!=="");return null}function he(re,se,{considerBuiltins:be=!0}={}){if(re==="pnpapi")return M.toPortablePath(e.pnpapiResolution);if(be&&s(re))return null;let ae=YA(re),Ae=se&&YA(se);if(se&&q(se)&&(!v.isAbsolute(re)||D(re)===null)){let G=ne(re,se);if(G===!1)throw ui(ur.BUILTIN_NODE_RESOLUTION_FAILED,`The builtin node resolution algorithm was unable to resolve the requested module (it didn't go through the pnp resolver because the issuer was explicitely ignored by the regexp) + +Require request: "${ae}" +Required by: ${Ae} +`,{request:ae,issuer:Ae});return M.toPortablePath(G)}let De,$=re.match(o);if($){if(!se)throw ui(ur.API_ERROR,"The resolveToUnqualified function must be called with a valid issuer when the path isn't a builtin nor absolute",{request:ae,issuer:Ae});let[,G,Ce]=$,ee=D(se);if(!ee){let yr=ne(re,se);if(yr===!1)throw ui(ur.BUILTIN_NODE_RESOLUTION_FAILED,`The builtin node resolution algorithm was unable to resolve the requested module (it didn't go through the pnp resolver because the issuer doesn't seem to be part of the Yarn-managed dependency tree). + +Require path: "${ae}" +Required by: ${Ae} +`,{request:ae,issuer:Ae});return M.toPortablePath(yr)}let Oe=b(ee).packageDependencies.get(G),vt=null;if(Oe==null&&ee.name!==null){let yr=t.fallbackExclusionList.get(ee.name);if(!yr||!yr.has(ee.reference)){for(let Qi=0,Go=g.length;QiR(Ki))?dt=ui(ur.MISSING_PEER_DEPENDENCY,`${ee.name} tried to access ${G} (a peer dependency) but it isn't provided by your application; this makes the require call ambiguous and unsound. + +Required package: ${G}${G!==ae?` (via "${ae}")`:""} +Required by: ${ee.name}@${ee.reference} (via ${Ae}) +${yr.map(Ki=>`Ancestor breaking the chain: ${Ki.name}@${Ki.reference} +`).join("")} +`,{request:ae,issuer:Ae,issuerLocator:Object.assign({},ee),dependencyName:G,brokenAncestors:yr}):dt=ui(ur.MISSING_PEER_DEPENDENCY,`${ee.name} tried to access ${G} (a peer dependency) but it isn't provided by its ancestors; this makes the require call ambiguous and unsound. + +Required package: ${G}${G!==ae?` (via "${ae}")`:""} +Required by: ${ee.name}@${ee.reference} (via ${Ae}) + +${yr.map(Ki=>`Ancestor breaking the chain: ${Ki.name}@${Ki.reference} +`).join("")} +`,{request:ae,issuer:Ae,issuerLocator:Object.assign({},ee),dependencyName:G,brokenAncestors:yr})}else Oe===void 0&&(!be&&s(re)?R(ee)?dt=ui(ur.UNDECLARED_DEPENDENCY,`Your application tried to access ${G}. While this module is usually interpreted as a Node builtin, your resolver is running inside a non-Node resolution context where such builtins are ignored. Since ${G} isn't otherwise declared in your dependencies, this makes the require call ambiguous and unsound. + +Required package: ${G}${G!==ae?` (via "${ae}")`:""} +Required by: ${Ae} +`,{request:ae,issuer:Ae,dependencyName:G}):dt=ui(ur.UNDECLARED_DEPENDENCY,`${ee.name} tried to access ${G}. While this module is usually interpreted as a Node builtin, your resolver is running inside a non-Node resolution context where such builtins are ignored. Since ${G} isn't otherwise declared in ${ee.name}'s dependencies, this makes the require call ambiguous and unsound. + +Required package: ${G}${G!==ae?` (via "${ae}")`:""} +Required by: ${Ae} +`,{request:ae,issuer:Ae,issuerLocator:Object.assign({},ee),dependencyName:G}):R(ee)?dt=ui(ur.UNDECLARED_DEPENDENCY,`Your application tried to access ${G}, but it isn't declared in your dependencies; this makes the require call ambiguous and unsound. + +Required package: ${G}${G!==ae?` (via "${ae}")`:""} +Required by: ${Ae} +`,{request:ae,issuer:Ae,dependencyName:G}):dt=ui(ur.UNDECLARED_DEPENDENCY,`${ee.name} tried to access ${G}, but it isn't declared in its dependencies; this makes the require call ambiguous and unsound. + +Required package: ${G}${G!==ae?` (via "${ae}")`:""} +Required by: ${ee.name}@${ee.reference} (via ${Ae}) +`,{request:ae,issuer:Ae,issuerLocator:Object.assign({},ee),dependencyName:G}));if(Oe==null){if(vt===null||dt===null)throw dt||new Error("Assertion failed: Expected an error to have been set");Oe=vt;let yr=dt.message.replace(/\n.*/g,"");dt.message=yr,!f.has(yr)&&i!==0&&(f.add(yr),process.emitWarning(dt))}let ri=Array.isArray(Oe)?{name:Oe[0],reference:Oe[1]}:{name:G,reference:Oe},ii=b(ri);if(!ii.packageLocation)throw ui(ur.MISSING_DEPENDENCY,`A dependency seems valid but didn't get installed for some reason. This might be caused by a partial install, such as dev vs prod. + +Required package: ${ri.name}@${ri.reference}${ri.name!==ae?` (via "${ae}")`:""} +Required by: ${ee.name}@${ee.reference} (via ${Ae}) +`,{request:ae,issuer:Ae,dependencyLocator:Object.assign({},ri)});let an=ii.packageLocation;Ce?De=v.join(an,Ce):De=an}else if(v.isAbsolute(re))De=v.normalize(re);else{if(!se)throw ui(ur.API_ERROR,"The resolveToUnqualified function must be called with a valid issuer when the path isn't a builtin nor absolute",{request:ae,issuer:Ae});let G=v.resolve(se);se.match(l)?De=v.normalize(v.join(G,re)):De=v.normalize(v.join(v.dirname(G),re))}return v.normalize(De)}function pe(re,se,be=H){if(a.test(re))return se;let ae=L(se,be);return ae?v.normalize(ae):se}function Ne(re,{extensions:se=Object.keys(df.Module._extensions)}={}){let be=[],ae=K(re,be,{extensions:se});if(ae)return v.normalize(ae);{let Ae=YA(re),De=D(re);if(De){let{packageLocation:$}=b(De);if(!e.fakeFs.existsSync($)){let G=$.includes("/unplugged/")?"Required unplugged package missing from disk. This may happen when switching branches without running installs (unplugged packages must be fully materialized on disk to work).":"Required package missing from disk. If you keep your packages inside your repository then restarting the Node process may be enough. Otherwise, try to run an install first.";throw ui(ur.QUALIFIED_PATH_RESOLUTION_FAILED,`${G} + +Missing package: ${De.name}@${De.reference} +Expected package location: ${YA($)} +`,{unqualifiedPath:Ae})}}throw ui(ur.QUALIFIED_PATH_RESOLUTION_FAILED,`Qualified path resolution failed - none of those files can be found on the disk. + +Source path: ${Ae} +${be.map($=>`Not found: ${YA($)} +`).join("")}`,{unqualifiedPath:Ae})}}function Pe(re,se,{considerBuiltins:be,extensions:ae,conditions:Ae}={}){let De=he(re,se,{considerBuiltins:be});if(re==="pnpapi")return De;if(De===null)return null;let $=()=>se!==null?q(se):!1,G=(!be||!s(re))&&!$()?pe(re,De,Ae):De;try{return Ne(G,{extensions:ae})}catch(Ce){throw Ce.pnpCode==="QUALIFIED_PATH_RESOLUTION_FAILED"&&Object.assign(Ce.data,{request:YA(re),issuer:se&&YA(se)}),Ce}}function qe(re){let se=v.normalize(re),be=Pr.resolveVirtual(se);return be!==se?be:null}return{VERSIONS:A,topLevel:V,getLocator:(re,se)=>Array.isArray(se)?{name:se[0],reference:se[1]}:{name:re,reference:se},getDependencyTreeRoots:()=>[...t.dependencyTreeRoots],getAllLocators(){let re=[];for(let[se,be]of p)for(let ae of be.keys())se!==null&&ae!==null&&re.push({name:se,reference:ae});return re},getPackageInformation:re=>{let se=W(re);if(se===null)return null;let be=M.fromPortablePath(se.packageLocation);return _(P({},se),{packageLocation:be})},findPackageLocator:re=>D(M.toPortablePath(re)),resolveToUnqualified:B("resolveToUnqualified",(re,se,be)=>{let ae=se!==null?M.toPortablePath(se):null,Ae=he(M.toPortablePath(re),ae,be);return Ae===null?null:M.fromPortablePath(Ae)}),resolveUnqualified:B("resolveUnqualified",(re,se)=>M.fromPortablePath(Ne(M.toPortablePath(re),se))),resolveRequest:B("resolveRequest",(re,se,be)=>{let ae=se!==null?M.toPortablePath(se):null,Ae=Pe(M.toPortablePath(re),ae,be);return Ae===null?null:M.fromPortablePath(Ae)}),resolveVirtual:B("resolveVirtual",re=>{let se=qe(M.toPortablePath(re));return se!==null?M.fromPortablePath(se):null})}}var ISt=(0,rce.promisify)(tce.readFile);var ice=(t,e,r)=>{let i=XC(t),n=_L(i,{basePath:e}),s=M.join(e,wt.pnpCjs);return $L(n,{fakeFs:r,pnpapiResolution:s})};var tT=ie(sce());var Ws={};it(Ws,{checkAndReportManifestCompatibility:()=>oce,extractBuildScripts:()=>Z0,getExtractHint:()=>rT,hasBindingGyp:()=>iT});function oce(t,e,{configuration:r,report:i}){return S.isPackageCompatible(t,{os:[process.platform],cpu:[process.arch]})?!0:(i==null||i.reportWarningOnce(z.INCOMPATIBLE_ARCHITECTURE,`${S.prettyLocator(r,t)} The ${process.platform}-${process.arch} architecture is incompatible with this module, ${e} skipped.`),!1)}function Z0(t,e,r,{configuration:i,report:n}){let s=[];for(let a of["preinstall","install","postinstall"])e.manifest.scripts.has(a)&&s.push([Gn.SCRIPT,a]);return!e.manifest.scripts.has("install")&&e.misc.hasBindingGyp&&s.push([Gn.SHELLCODE,"node-gyp rebuild"]),s.length===0?[]:t.linkType!==gt.HARD?(n==null||n.reportWarningOnce(z.SOFT_LINK_BUILD,`${S.prettyLocator(i,t)} lists build scripts, but is referenced through a soft link. Soft links don't support build scripts, so they'll be ignored.`),[]):r&&r.built===!1?(n==null||n.reportInfoOnce(z.BUILD_DISABLED,`${S.prettyLocator(i,t)} lists build scripts, but its build has been explicitly disabled through configuration.`),[]):!i.get("enableScripts")&&!r.built?(n==null||n.reportWarningOnce(z.DISABLED_BUILD_SCRIPTS,`${S.prettyLocator(i,t)} lists build scripts, but all build scripts have been disabled.`),[]):oce(t,"build",{configuration:i,report:n})?s:[]}var g6e=new Set([".exe",".h",".hh",".hpp",".c",".cc",".cpp",".java",".jar",".node"]);function rT(t){return t.packageFs.getExtractHint({relevantExtensions:g6e})}function iT(t){let e=v.join(t.prefixPath,"binding.gyp");return t.packageFs.existsSync(e)}var nT={};it(nT,{getUnpluggedPath:()=>ZC});function ZC(t,{configuration:e}){return v.resolve(e.get("pnpUnpluggedFolder"),S.slugifyLocator(t))}var f6e=new Set([S.makeIdent(null,"nan").identHash,S.makeIdent(null,"node-gyp").identHash,S.makeIdent(null,"node-pre-gyp").identHash,S.makeIdent(null,"node-addon-api").identHash,S.makeIdent(null,"fsevents").identHash]),jc=class{constructor(){this.mode="strict";this.pnpCache=new Map}supportsPackage(e,r){return!(r.project.configuration.get("nodeLinker")!=="pnp"||r.project.configuration.get("pnpMode")!==this.mode)}async findPackageLocation(e,r){let i=qA(r.project).cjs;if(!T.existsSync(i))throw new me(`The project in ${ue.pretty(r.project.configuration,`${r.project.cwd}/package.json`,ue.Type.PATH)} doesn't seem to have been installed - running an install there might help`);let n=de.getFactoryWithDefault(this.pnpCache,i,()=>de.dynamicRequire(i,{cachingStrategy:de.CachingStrategy.FsTime})),s={name:S.stringifyIdent(e),reference:e.reference},o=n.getPackageInformation(s);if(!o)throw new me(`Couldn't find ${S.prettyLocator(r.project.configuration,e)} in the currently installed PnP map - running an install might help`);return M.toPortablePath(o.packageLocation)}async findPackageLocator(e,r){let i=qA(r.project).cjs;if(!T.existsSync(i))return null;let s=de.getFactoryWithDefault(this.pnpCache,i,()=>de.dynamicRequire(i,{cachingStrategy:de.CachingStrategy.FsTime})).findPackageLocator(M.fromPortablePath(e));return s?S.makeLocator(S.parseIdent(s.name),s.reference):null}makeInstaller(e){return new Cf(e)}},Cf=class{constructor(e){this.opts=e;this.mode="strict";this.packageRegistry=new Map;this.virtualTemplates=new Map;this.isESMLoaderRequired=!1;this.customData={store:new Map};this.unpluggedPaths=new Set;this.opts=e}getCustomDataKey(){return JSON.stringify({name:"PnpInstaller",version:2})}attachCustomData(e){this.customData=e}async installPackage(e,r){let i=S.stringifyIdent(e),n=e.reference,s=!!this.opts.project.tryWorkspaceByLocator(e),o=S.isVirtualLocator(e),a=e.peerDependencies.size>0&&!o,l=!a&&!s,c=!a&&e.linkType!==gt.SOFT,u,g;if(l||c){let B=o?S.devirtualizeLocator(e):e;u=this.customData.store.get(B.locatorHash),typeof u=="undefined"&&(u=await h6e(r),e.linkType===gt.HARD&&this.customData.store.set(B.locatorHash,u)),u.manifest.type==="module"&&(this.isESMLoaderRequired=!0),g=this.opts.project.getDependencyMeta(B,e.version)}let f=l?Z0(e,u,g,{configuration:this.opts.project.configuration,report:this.opts.report}):[],h=c?await this.unplugPackageIfNeeded(e,u,r,g):r.packageFs;if(v.isAbsolute(r.prefixPath))throw new Error(`Assertion failed: Expected the prefix path (${r.prefixPath}) to be relative to the parent`);let p=v.resolve(h.getRealPath(),r.prefixPath),d=sT(this.opts.project.cwd,p),m=new Map,I=new Set;if(o){for(let B of e.peerDependencies.values())m.set(S.stringifyIdent(B),null),I.add(S.stringifyIdent(B));if(!s){let B=S.devirtualizeLocator(e);this.virtualTemplates.set(B.locatorHash,{location:sT(this.opts.project.cwd,Pr.resolveVirtual(p)),locator:B})}}return de.getMapWithDefault(this.packageRegistry,i).set(n,{packageLocation:d,packageDependencies:m,packagePeers:I,linkType:e.linkType,discardFromLookup:r.discardFromLookup||!1}),{packageLocation:p,buildDirective:f.length>0?f:null}}async attachInternalDependencies(e,r){let i=this.getPackageInformation(e);for(let[n,s]of r){let o=S.areIdentsEqual(n,s)?s.reference:[S.stringifyIdent(s),s.reference];i.packageDependencies.set(S.stringifyIdent(n),o)}}async attachExternalDependents(e,r){for(let i of r)this.getDiskInformation(i).packageDependencies.set(S.stringifyIdent(e),e.reference)}async finalizeInstall(){if(this.opts.project.configuration.get("pnpMode")!==this.mode)return;let e=qA(this.opts.project);if(T.existsSync(e.cjsLegacy)&&(this.opts.report.reportWarning(z.UNNAMED,`Removing the old ${ue.pretty(this.opts.project.configuration,wt.pnpJs,ue.Type.PATH)} file. You might need to manually update existing references to reference the new ${ue.pretty(this.opts.project.configuration,wt.pnpCjs,ue.Type.PATH)} file. If you use Editor SDKs, you'll have to rerun ${ue.pretty(this.opts.project.configuration,"yarn sdks",ue.Type.CODE)}.`),await T.removePromise(e.cjsLegacy)),this.isEsmEnabled()||await T.removePromise(e.esmLoader),this.opts.project.configuration.get("nodeLinker")!=="pnp"){await T.removePromise(e.cjs),await T.removePromise(this.opts.project.configuration.get("pnpDataPath")),await T.removePromise(e.esmLoader);return}for(let{locator:u,location:g}of this.virtualTemplates.values())de.getMapWithDefault(this.packageRegistry,S.stringifyIdent(u)).set(u.reference,{packageLocation:g,packageDependencies:new Map,packagePeers:new Set,linkType:gt.SOFT,discardFromLookup:!1});this.packageRegistry.set(null,new Map([[null,this.getPackageInformation(this.opts.project.topLevelWorkspace.anchoredLocator)]]));let r=this.opts.project.configuration.get("pnpFallbackMode"),i=this.opts.project.workspaces.map(({anchoredLocator:u})=>({name:S.stringifyIdent(u),reference:u.reference})),n=r!=="none",s=[],o=new Map,a=de.buildIgnorePattern([".yarn/sdks/**",...this.opts.project.configuration.get("pnpIgnorePatterns")]),l=this.packageRegistry,c=this.opts.project.configuration.get("pnpShebang");if(r==="dependencies-only")for(let u of this.opts.project.storedPackages.values())this.opts.project.tryWorkspaceByLocator(u)&&s.push({name:S.stringifyIdent(u),reference:u.reference});return await this.finalizeInstallWithPnp({dependencyTreeRoots:i,enableTopLevelFallback:n,fallbackExclusionList:s,fallbackPool:o,ignorePattern:a,packageRegistry:l,shebang:c}),{customData:this.customData}}async transformPnpSettings(e){}isEsmEnabled(){if(this.opts.project.configuration.sources.has("pnpEnableEsmLoader"))return this.opts.project.configuration.get("pnpEnableEsmLoader");if(this.isESMLoaderRequired)return!0;for(let e of this.opts.project.workspaces)if(e.manifest.type==="module")return!0;return!1}async finalizeInstallWithPnp(e){let r=qA(this.opts.project),i=this.opts.project.configuration.get("pnpDataPath"),n=await this.locateNodeModules(e.ignorePattern);if(n.length>0){this.opts.report.reportWarning(z.DANGEROUS_NODE_MODULES,"One or more node_modules have been detected and will be removed. This operation may take some time.");for(let o of n)await T.removePromise(o)}if(await this.transformPnpSettings(e),this.opts.project.configuration.get("pnpEnableInlining")){let o=_le(e);await T.changeFilePromise(r.cjs,o,{automaticNewlines:!0,mode:493}),await T.removePromise(i)}else{let o=v.relative(v.dirname(r.cjs),i),{dataFile:a,loaderFile:l}=Xle(_(P({},e),{dataLocation:o}));await T.changeFilePromise(r.cjs,l,{automaticNewlines:!0,mode:493}),await T.changeFilePromise(i,a,{automaticNewlines:!0,mode:420})}this.isEsmEnabled()&&(this.opts.report.reportWarning(z.UNNAMED,"ESM support for PnP uses the experimental loader API and is therefore experimental"),await T.changeFilePromise(r.esmLoader,(0,tT.default)(),{automaticNewlines:!0,mode:420}));let s=this.opts.project.configuration.get("pnpUnpluggedFolder");if(this.unpluggedPaths.size===0)await T.removePromise(s);else for(let o of await T.readdirPromise(s)){let a=v.resolve(s,o);this.unpluggedPaths.has(a)||await T.removePromise(a)}}async locateNodeModules(e){let r=[],i=e?new RegExp(e):null;for(let n of this.opts.project.workspaces){let s=v.join(n.cwd,"node_modules");if(i&&i.test(v.relative(this.opts.project.cwd,n.cwd))||!T.existsSync(s))continue;let o=await T.readdirPromise(s,{withFileTypes:!0}),a=o.filter(l=>!l.isDirectory()||l.name===".bin"||!l.name.startsWith("."));if(a.length===o.length)r.push(s);else for(let l of a)r.push(v.join(s,l.name))}return r}async unplugPackageIfNeeded(e,r,i,n){return this.shouldBeUnplugged(e,r,n)?this.unplugPackage(e,i):i.packageFs}shouldBeUnplugged(e,r,i){return typeof i.unplugged!="undefined"?i.unplugged:f6e.has(e.identHash)||e.conditions!=null?!0:r.manifest.preferUnplugged!==null?r.manifest.preferUnplugged:!!(Z0(e,r,i,{configuration:this.opts.project.configuration}).length>0||r.misc.extractHint)}async unplugPackage(e,r){let i=ZC(e,{configuration:this.opts.project.configuration});if(this.opts.project.disabledLocators.has(e.locatorHash))return new Xo(i,{baseFs:r.packageFs,pathUtils:v});this.unpluggedPaths.add(i);let n=v.join(i,r.prefixPath,".ready");return await T.existsPromise(n)?new Ft(i):(this.opts.project.storedBuildState.delete(e.locatorHash),await T.mkdirPromise(i,{recursive:!0}),await T.copyPromise(i,Se.dot,{baseFs:r.packageFs,overwrite:!1}),await T.writeFilePromise(n,""),new Ft(i))}getPackageInformation(e){let r=S.stringifyIdent(e),i=e.reference,n=this.packageRegistry.get(r);if(!n)throw new Error(`Assertion failed: The package information store should have been available (for ${S.prettyIdent(this.opts.project.configuration,e)})`);let s=n.get(i);if(!s)throw new Error(`Assertion failed: The package information should have been available (for ${S.prettyLocator(this.opts.project.configuration,e)})`);return s}getDiskInformation(e){let r=de.getMapWithDefault(this.packageRegistry,"@@disk"),i=sT(this.opts.project.cwd,e);return de.getFactoryWithDefault(r,i,()=>({packageLocation:i,packageDependencies:new Map,packagePeers:new Set,linkType:gt.SOFT,discardFromLookup:!1}))}};function sT(t,e){let r=v.relative(t,e);return r.match(/^\.{0,2}\//)||(r=`./${r}`),r.replace(/\/?$/,"/")}async function h6e(t){var i;let e=(i=await Ze.tryFind(t.prefixPath,{baseFs:t.packageFs}))!=null?i:new Ze,r=new Set(["preinstall","install","postinstall"]);for(let n of e.scripts.keys())r.has(n)||e.scripts.delete(n);return{manifest:{scripts:e.scripts,preferUnplugged:e.preferUnplugged,type:e.type},misc:{extractHint:rT(t),hasBindingGyp:iT(t)}}}var ace=ie(Nn());var $C=class extends Be{constructor(){super(...arguments);this.all=Y.Boolean("-A,--all",!1,{description:"Unplug direct dependencies from the entire project"});this.recursive=Y.Boolean("-R,--recursive",!1,{description:"Unplug both direct and transitive dependencies"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.patterns=Y.Rest()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);if(e.get("nodeLinker")!=="pnp")throw new me("This command can only be used if the `nodeLinker` option is set to `pnp`");await r.restoreInstallState();let s=new Set(this.patterns),o=this.patterns.map(f=>{let h=S.parseDescriptor(f),p=h.range!=="unknown"?h:S.makeDescriptor(h,"*");if(!qt.validRange(p.range))throw new me(`The range of the descriptor patterns must be a valid semver range (${S.prettyDescriptor(e,p)})`);return d=>{let m=S.stringifyIdent(d);return!ace.default.isMatch(m,S.stringifyIdent(p))||d.version&&!qt.satisfiesWithPrereleases(d.version,p.range)?!1:(s.delete(f),!0)}}),a=()=>{let f=[];for(let h of r.storedPackages.values())!r.tryWorkspaceByLocator(h)&&!S.isVirtualLocator(h)&&o.some(p=>p(h))&&f.push(h);return f},l=f=>{let h=new Set,p=[],d=(m,I)=>{if(!h.has(m.locatorHash)&&(h.add(m.locatorHash),!r.tryWorkspaceByLocator(m)&&o.some(B=>B(m))&&p.push(m),!(I>0&&!this.recursive)))for(let B of m.dependencies.values()){let b=r.storedResolutions.get(B.descriptorHash);if(!b)throw new Error("Assertion failed: The resolution should have been registered");let R=r.storedPackages.get(b);if(!R)throw new Error("Assertion failed: The package should have been registered");d(R,I+1)}};for(let m of f){let I=r.storedPackages.get(m.anchoredLocator.locatorHash);if(!I)throw new Error("Assertion failed: The package should have been registered");d(I,0)}return p},c,u;if(this.all&&this.recursive?(c=a(),u="the project"):this.all?(c=l(r.workspaces),u="any workspace"):(c=l([i]),u="this workspace"),s.size>1)throw new me(`Patterns ${ue.prettyList(e,s,ue.Type.CODE)} don't match any packages referenced by ${u}`);if(s.size>0)throw new me(`Pattern ${ue.prettyList(e,s,ue.Type.CODE)} doesn't match any packages referenced by ${u}`);return c=de.sortMap(c,f=>S.stringifyLocator(f)),(await Fe.start({configuration:e,stdout:this.context.stdout,json:this.json},async f=>{var h;for(let p of c){let d=(h=p.version)!=null?h:"unknown",m=r.topLevelWorkspace.manifest.ensureDependencyMeta(S.makeDescriptor(p,d));m.unplugged=!0,f.reportInfo(z.UNNAMED,`Will unpack ${S.prettyLocator(e,p)} to ${ue.pretty(e,ZC(p,{configuration:e}),ue.Type.PATH)}`),f.reportJson({locator:S.stringifyLocator(p),version:d})}await r.topLevelWorkspace.persistManifest(),f.reportSeparator(),await r.install({cache:n,report:f})})).exitCode()}};$C.paths=[["unplug"]],$C.usage=ye.Usage({description:"force the unpacking of a list of packages",details:"\n This command will add the selectors matching the specified patterns to the list of packages that must be unplugged when installed.\n\n A package being unplugged means that instead of being referenced directly through its archive, it will be unpacked at install time in the directory configured via `pnpUnpluggedFolder`. Note that unpacking packages this way is generally not recommended because it'll make it harder to store your packages within the repository. However, it's a good approach to quickly and safely debug some packages, and can even sometimes be required depending on the context (for example when the package contains shellscripts).\n\n Running the command will set a persistent flag inside your top-level `package.json`, in the `dependenciesMeta` field. As such, to undo its effects, you'll need to revert the changes made to the manifest and run `yarn install` to apply the modification.\n\n By default, only direct dependencies from the current workspace are affected. If `-A,--all` is set, direct dependencies from the entire project are affected. Using the `-R,--recursive` flag will affect transitive dependencies as well as direct ones.\n\n This command accepts glob patterns inside the scope and name components (not the range). Make sure to escape the patterns to prevent your own shell from trying to expand them.\n ",examples:[["Unplug the lodash dependency from the active workspace","yarn unplug lodash"],["Unplug all instances of lodash referenced by any workspace","yarn unplug lodash -A"],["Unplug all instances of lodash referenced by the active workspace and its dependencies","yarn unplug lodash -R"],["Unplug all instances of lodash, anywhere","yarn unplug lodash -AR"],["Unplug one specific version of lodash","yarn unplug lodash@1.2.3"],["Unplug all packages with the `@babel` scope","yarn unplug '@babel/*'"],["Unplug all packages (only for testing, not recommended)","yarn unplug -R '*'"]]});var Ace=$C;var qA=t=>({cjs:v.join(t.cwd,wt.pnpCjs),cjsLegacy:v.join(t.cwd,wt.pnpJs),esmLoader:v.join(t.cwd,".pnp.loader.mjs")}),uce=t=>/\s/.test(t)?JSON.stringify(t):t;async function p6e(t,e,r){let i=qA(t),n=`--require ${uce(M.fromPortablePath(i.cjs))}`;if(T.existsSync(i.esmLoader)&&(n=`${n} --experimental-loader ${(0,cce.pathToFileURL)(M.fromPortablePath(i.esmLoader)).href}`),i.cjs.includes(" ")&&lce.default.lt(process.versions.node,"12.0.0"))throw new Error(`Expected the build location to not include spaces when using Node < 12.0.0 (${process.versions.node})`);if(T.existsSync(i.cjs)){let s=e.NODE_OPTIONS||"",o=/\s*--require\s+\S*\.pnp\.c?js\s*/g,a=/\s*--experimental-loader\s+\S*\.pnp\.loader\.mjs\s*/;s=s.replace(o," ").replace(a," ").trim(),s=s?`${n} ${s}`:n,e.NODE_OPTIONS=s}}async function d6e(t,e){let r=qA(t);e(r.cjs),e(r.esmLoader),e(t.configuration.get("pnpDataPath")),e(t.configuration.get("pnpUnpluggedFolder"))}var C6e={hooks:{populateYarnPaths:d6e,setupScriptEnvironment:p6e},configuration:{nodeLinker:{description:'The linker used for installing Node packages, one of: "pnp", "node-modules"',type:ge.STRING,default:"pnp"},pnpMode:{description:"If 'strict', generates standard PnP maps. If 'loose', merges them with the n_m resolution.",type:ge.STRING,default:"strict"},pnpShebang:{description:"String to prepend to the generated PnP script",type:ge.STRING,default:"#!/usr/bin/env node"},pnpIgnorePatterns:{description:"Array of glob patterns; files matching them will use the classic resolution",type:ge.STRING,default:[],isArray:!0},pnpEnableEsmLoader:{description:"If true, Yarn will generate an ESM loader (`.pnp.loader.mjs`). If this is not explicitly set Yarn tries to automatically detect whether ESM support is required.",type:ge.BOOLEAN,default:!1},pnpEnableInlining:{description:"If true, the PnP data will be inlined along with the generated loader",type:ge.BOOLEAN,default:!0},pnpFallbackMode:{description:"If true, the generated PnP loader will follow the top-level fallback rule",type:ge.STRING,default:"dependencies-only"},pnpUnpluggedFolder:{description:"Folder where the unplugged packages must be stored",type:ge.ABSOLUTE_PATH,default:"./.yarn/unplugged"},pnpDataPath:{description:"Path of the file where the PnP data (used by the loader) must be written",type:ge.ABSOLUTE_PATH,default:"./.pnp.data.json"}},linkers:[jc],commands:[Ace]},m6e=C6e;var Cce=ie(dce());var uT=ie(require("crypto")),mce=ie(require("fs")),Ece=1,gi="node_modules",gT=".bin",Ice=".yarn-state.yml",Bi;(function(i){i.CLASSIC="classic",i.HARDLINKS_LOCAL="hardlinks-local",i.HARDLINKS_GLOBAL="hardlinks-global"})(Bi||(Bi={}));var fT=class{constructor(){this.installStateCache=new Map}supportsPackage(e,r){return r.project.configuration.get("nodeLinker")==="node-modules"}async findPackageLocation(e,r){let i=r.project.tryWorkspaceByLocator(e);if(i)return i.cwd;let n=await de.getFactoryWithDefault(this.installStateCache,r.project.cwd,async()=>await hT(r.project,{unrollAliases:!0}));if(n===null)throw new me("Couldn't find the node_modules state file - running an install might help (findPackageLocation)");let s=n.locatorMap.get(S.stringifyLocator(e));if(!s){let a=new me(`Couldn't find ${S.prettyLocator(r.project.configuration,e)} in the currently installed node_modules map - running an install might help`);throw a.code="LOCATOR_NOT_INSTALLED",a}let o=r.project.configuration.startingCwd;return s.locations.find(a=>v.contains(o,a))||s.locations[0]}async findPackageLocator(e,r){let i=await de.getFactoryWithDefault(this.installStateCache,r.project.cwd,async()=>await hT(r.project,{unrollAliases:!0}));if(i===null)return null;let{locationRoot:n,segments:s}=$0(v.resolve(e),{skipPrefix:r.project.cwd}),o=i.locationTree.get(n);if(!o)return null;let a=o.locator;for(let l of s){if(o=o.children.get(l),!o)break;a=o.locator||a}return S.parseLocator(a)}makeInstaller(e){return new yce(e)}},yce=class{constructor(e){this.opts=e;this.localStore=new Map;this.realLocatorChecksums=new Map;this.customData={store:new Map}}getCustomDataKey(){return JSON.stringify({name:"NodeModulesInstaller",version:1})}attachCustomData(e){this.customData=e}async installPackage(e,r){var u;let i=v.resolve(r.packageFs.getRealPath(),r.prefixPath),n=this.customData.store.get(e.locatorHash);if(typeof n=="undefined"&&(n=await L6e(e,r),e.linkType===gt.HARD&&this.customData.store.set(e.locatorHash,n)),!Ws.checkAndReportManifestCompatibility(e,"link",{configuration:this.opts.project.configuration,report:this.opts.report}))return{packageLocation:null,buildDirective:null};let s=new Map,o=new Set;s.has(S.stringifyIdent(e))||s.set(S.stringifyIdent(e),e.reference);let a=e;if(S.isVirtualLocator(e)){a=S.devirtualizeLocator(e);for(let g of e.peerDependencies.values())s.set(S.stringifyIdent(g),null),o.add(S.stringifyIdent(g))}let l={packageLocation:`${M.fromPortablePath(i)}/`,packageDependencies:s,packagePeers:o,linkType:e.linkType,discardFromLookup:(u=r.discardFromLookup)!=null?u:!1};this.localStore.set(e.locatorHash,{pkg:e,customPackageData:n,dependencyMeta:this.opts.project.getDependencyMeta(e,e.version),pnpNode:l});let c=r.checksum?r.checksum.substring(r.checksum.indexOf("/")+1):null;return this.realLocatorChecksums.set(a.locatorHash,c),{packageLocation:i,buildDirective:null}}async attachInternalDependencies(e,r){let i=this.localStore.get(e.locatorHash);if(typeof i=="undefined")throw new Error("Assertion failed: Expected information object to have been registered");for(let[n,s]of r){let o=S.areIdentsEqual(n,s)?s.reference:[S.stringifyIdent(s),s.reference];i.pnpNode.packageDependencies.set(S.stringifyIdent(n),o)}}async attachExternalDependents(e,r){throw new Error("External dependencies haven't been implemented for the node-modules linker")}async finalizeInstall(){if(this.opts.project.configuration.get("nodeLinker")!=="node-modules")return;let e=new Pr({baseFs:new Jn({libzip:await $i(),maxOpenFiles:80,readOnlyArchives:!0})}),r=await hT(this.opts.project),i=this.opts.project.configuration.get("nmMode");(r===null||i!==r.nmMode)&&(this.opts.project.storedBuildState.clear(),r={locatorMap:new Map,binSymlinks:new Map,locationTree:new Map,nmMode:i});let n=new Map(this.opts.project.workspaces.map(f=>{var p,d;let h=this.opts.project.configuration.get("nmHoistingLimits");try{h=de.validateEnum(Sn,(d=(p=f.manifest.installConfig)==null?void 0:p.hoistingLimits)!=null?d:h)}catch(m){let I=S.prettyWorkspace(this.opts.project.configuration,f);this.opts.report.reportWarning(z.INVALID_MANIFEST,`${I}: Invalid 'installConfig.hoistingLimits' value. Expected one of ${Object.values(Sn).join(", ")}, using default: "${h}"`)}return[f.relativeCwd,h]})),s=new Map(this.opts.project.workspaces.map(f=>{var p,d;let h=this.opts.project.configuration.get("nmSelfReferences");return h=(d=(p=f.manifest.installConfig)==null?void 0:p.selfReferences)!=null?d:h,[f.relativeCwd,h]})),o={VERSIONS:{std:1},topLevel:{name:null,reference:null},getLocator:(f,h)=>Array.isArray(h)?{name:h[0],reference:h[1]}:{name:f,reference:h},getDependencyTreeRoots:()=>this.opts.project.workspaces.map(f=>{let h=f.anchoredLocator;return{name:S.stringifyIdent(f.locator),reference:h.reference}}),getPackageInformation:f=>{let h=f.reference===null?this.opts.project.topLevelWorkspace.anchoredLocator:S.makeLocator(S.parseIdent(f.name),f.reference),p=this.localStore.get(h.locatorHash);if(typeof p=="undefined")throw new Error("Assertion failed: Expected the package reference to have been registered");return p.pnpNode},findPackageLocator:f=>{let h=this.opts.project.tryWorkspaceByCwd(M.toPortablePath(f));if(h!==null){let p=h.anchoredLocator;return{name:S.stringifyIdent(p),reference:p.reference}}throw new Error("Assertion failed: Unimplemented")},resolveToUnqualified:()=>{throw new Error("Assertion failed: Unimplemented")},resolveUnqualified:()=>{throw new Error("Assertion failed: Unimplemented")},resolveRequest:()=>{throw new Error("Assertion failed: Unimplemented")},resolveVirtual:f=>M.fromPortablePath(Pr.resolveVirtual(M.toPortablePath(f)))},{tree:a,errors:l,preserveSymlinksRequired:c}=VC(o,{pnpifyFs:!1,validateExternalSoftLinks:!0,hoistingLimitsByCwd:n,project:this.opts.project,selfReferencesByCwd:s});if(!a){for(let{messageName:f,text:h}of l)this.opts.report.reportError(f,h);return}let u=WL(a);await T6e(r,u,{baseFs:e,project:this.opts.project,report:this.opts.report,realLocatorChecksums:this.realLocatorChecksums,loadManifest:async f=>{let h=S.parseLocator(f),p=this.localStore.get(h.locatorHash);if(typeof p=="undefined")throw new Error("Assertion failed: Expected the slot to exist");return p.customPackageData.manifest}});let g=[];for(let[f,h]of u.entries()){if(wce(f))continue;let p=S.parseLocator(f),d=this.localStore.get(p.locatorHash);if(typeof d=="undefined")throw new Error("Assertion failed: Expected the slot to exist");if(this.opts.project.tryWorkspaceByLocator(d.pkg))continue;let m=Ws.extractBuildScripts(d.pkg,d.customPackageData,d.dependencyMeta,{configuration:this.opts.project.configuration,report:this.opts.report});m.length!==0&&g.push({buildLocations:h.locations,locatorHash:p.locatorHash,buildDirective:m})}return c&&this.opts.report.reportWarning(z.NM_PRESERVE_SYMLINKS_REQUIRED,`The application uses portals and that's why ${ue.pretty(this.opts.project.configuration,"--preserve-symlinks",ue.Type.CODE)} Node option is required for launching it`),{customData:this.customData,records:g}}};async function L6e(t,e){var n;let r=(n=await Ze.tryFind(e.prefixPath,{baseFs:e.packageFs}))!=null?n:new Ze,i=new Set(["preinstall","install","postinstall"]);for(let s of r.scripts.keys())i.has(s)||r.scripts.delete(s);return{manifest:{bin:r.bin,scripts:r.scripts},misc:{extractHint:Ws.getExtractHint(e),hasBindingGyp:Ws.hasBindingGyp(e)}}}async function M6e(t,e,r,i){let n="";n+=`# Warning: This file is automatically generated. Removing it is fine, but will +`,n+=`# cause your node_modules installation to become invalidated. +`,n+=` +`,n+=`__metadata: +`,n+=` version: ${Ece} +`,n+=` nmMode: ${i.value} +`;let s=Array.from(e.keys()).sort(),o=S.stringifyLocator(t.topLevelWorkspace.anchoredLocator);for(let c of s){let u=e.get(c);n+=` +`,n+=`${JSON.stringify(c)}: +`,n+=` locations: +`;for(let g of u.locations){let f=v.contains(t.cwd,g);if(f===null)throw new Error(`Assertion failed: Expected the path to be within the project (${g})`);n+=` - ${JSON.stringify(f)} +`}if(u.aliases.length>0){n+=` aliases: +`;for(let g of u.aliases)n+=` - ${JSON.stringify(g)} +`}if(c===o&&r.size>0){n+=` bin: +`;for(let[g,f]of r){let h=v.contains(t.cwd,g);if(h===null)throw new Error(`Assertion failed: Expected the path to be within the project (${g})`);n+=` ${JSON.stringify(h)}: +`;for(let[p,d]of f){let m=v.relative(v.join(g,gi),d);n+=` ${JSON.stringify(p)}: ${JSON.stringify(m)} +`}}}}let a=t.cwd,l=v.join(a,gi,Ice);await T.changeFilePromise(l,n,{automaticNewlines:!0})}async function hT(t,{unrollAliases:e=!1}={}){let r=t.cwd,i=v.join(r,gi,Ice);if(!T.existsSync(i))return null;let n=Ii(await T.readFilePromise(i,"utf8"));if(n.__metadata.version>Ece)return null;let s=n.__metadata.nmMode||Bi.CLASSIC,o=new Map,a=new Map;delete n.__metadata;for(let[l,c]of Object.entries(n)){let u=c.locations.map(f=>v.join(r,f)),g=c.bin;if(g)for(let[f,h]of Object.entries(g)){let p=v.join(r,M.toPortablePath(f)),d=de.getMapWithDefault(a,p);for(let[m,I]of Object.entries(h))d.set(kr(m),M.toPortablePath([p,gi,I].join(v.delimiter)))}if(o.set(l,{target:Se.dot,linkType:gt.HARD,locations:u,aliases:c.aliases||[]}),e&&c.aliases)for(let f of c.aliases){let{scope:h,name:p}=S.parseLocator(l),d=S.makeLocator(S.makeIdent(h,p),f),m=S.stringifyLocator(d);o.set(m,{target:Se.dot,linkType:gt.HARD,locations:u,aliases:[]})}}return{locatorMap:o,binSymlinks:a,locationTree:Bce(o,{skipPrefix:t.cwd}),nmMode:s}}var Ef=async(t,e)=>{if(t.split(v.sep).indexOf(gi)<0)throw new Error(`Assertion failed: trying to remove dir that doesn't contain node_modules: ${t}`);try{if(!e.innerLoop&&(await T.lstatPromise(t)).isSymbolicLink()){await T.unlinkPromise(t);return}let r=await T.readdirPromise(t,{withFileTypes:!0});for(let i of r){let n=v.join(t,kr(i.name));i.isDirectory()?(i.name!==gi||e&&e.innerLoop)&&await Ef(n,{innerLoop:!0,contentsOnly:!1}):await T.unlinkPromise(n)}e.contentsOnly||await T.rmdirPromise(t)}catch(r){if(r.code!=="ENOENT"&&r.code!=="ENOTEMPTY")throw r}},Qce=4,$0=(t,{skipPrefix:e})=>{let r=v.contains(e,t);if(r===null)throw new Error(`Assertion failed: Writing attempt prevented to ${t} which is outside project root: ${e}`);let i=r.split(v.sep).filter(l=>l!==""),n=i.indexOf(gi),s=i.slice(0,n).join(v.sep),o=v.join(e,s),a=i.slice(n);return{locationRoot:o,segments:a}},Bce=(t,{skipPrefix:e})=>{let r=new Map;if(t===null)return r;let i=()=>({children:new Map,linkType:gt.HARD});for(let[n,s]of t.entries()){if(s.linkType===gt.SOFT&&v.contains(e,s.target)!==null){let a=de.getFactoryWithDefault(r,s.target,i);a.locator=n,a.linkType=s.linkType}for(let o of s.locations){let{locationRoot:a,segments:l}=$0(o,{skipPrefix:e}),c=de.getFactoryWithDefault(r,a,i);for(let u=0;u{let r;try{process.platform==="win32"&&(r=await T.lstatPromise(t))}catch(i){}process.platform=="win32"&&(!r||r.isDirectory())?await T.symlinkPromise(t,e,"junction"):await T.symlinkPromise(v.relative(v.dirname(e),t),e)};async function bce(t,e,r){let i=v.join(t,kr(`${uT.default.randomBytes(16).toString("hex")}.tmp`));try{await T.writeFilePromise(i,r);try{await T.linkPromise(i,e)}catch(n){}}finally{await T.unlinkPromise(i)}}async function O6e({srcPath:t,dstPath:e,srcMode:r,globalHardlinksStore:i,baseFs:n,nmMode:s,digest:o}){if(s.value===Bi.HARDLINKS_GLOBAL&&i&&o){let l=v.join(i,o.substring(0,2),`${o.substring(2)}.dat`),c;try{if(await mn.checksumFile(l,{baseFs:T,algorithm:"sha1"})!==o){let g=v.join(i,kr(`${uT.default.randomBytes(16).toString("hex")}.tmp`));await T.renamePromise(l,g);let f=await n.readFilePromise(t);await T.writeFilePromise(g,f);try{await T.linkPromise(g,l),await T.unlinkPromise(g)}catch(h){}}await T.linkPromise(l,e),c=!0}catch(u){c=!1}if(!c){let u=await n.readFilePromise(t);await bce(i,l,u);try{await T.linkPromise(l,e)}catch(g){g&&g.code&&g.code=="EXDEV"&&(s.value=Bi.HARDLINKS_LOCAL,await n.copyFilePromise(t,e))}}}else await n.copyFilePromise(t,e);let a=r&511;a!==420&&await T.chmodPromise(e,a)}var JA;(function(i){i.FILE="file",i.DIRECTORY="directory",i.SYMLINK="symlink"})(JA||(JA={}));var K6e=async(t,e,{baseFs:r,globalHardlinksStore:i,nmMode:n,packageChecksum:s})=>{await T.mkdirPromise(t,{recursive:!0});let o=async(l=Se.dot)=>{let c=v.join(e,l),u=await r.readdirPromise(c,{withFileTypes:!0}),g=new Map;for(let f of u){let h=v.join(l,f.name),p,d=v.join(c,f.name);if(f.isFile()){if(p={kind:JA.FILE,mode:(await r.lstatPromise(d)).mode},n.value===Bi.HARDLINKS_GLOBAL){let m=await mn.checksumFile(d,{baseFs:r,algorithm:"sha1"});p.digest=m}}else if(f.isDirectory())p={kind:JA.DIRECTORY};else if(f.isSymbolicLink())p={kind:JA.SYMLINK,symlinkTo:await r.readlinkPromise(d)};else throw new Error(`Unsupported file type (file: ${d}, mode: 0o${await r.statSync(d).mode.toString(8).padStart(6,"0")})`);if(g.set(h,p),f.isDirectory()&&h!==gi){let m=await o(h);for(let[I,B]of m)g.set(I,B)}}return g},a;if(n.value===Bi.HARDLINKS_GLOBAL&&i&&s){let l=v.join(i,s.substring(0,2),`${s.substring(2)}.json`);try{a=new Map(Object.entries(JSON.parse(await T.readFilePromise(l,"utf8"))))}catch(c){a=await o(),await bce(i,l,Buffer.from(JSON.stringify(Object.fromEntries(a))))}}else a=await o();for(let[l,c]of a){let u=v.join(e,l),g=v.join(t,l);c.kind===JA.DIRECTORY?await T.mkdirPromise(g,{recursive:!0}):c.kind===JA.FILE?await O6e({srcPath:u,dstPath:g,srcMode:c.mode,digest:c.digest,nmMode:n,baseFs:r,globalHardlinksStore:i}):c.kind===JA.SYMLINK&&await pT(v.resolve(v.dirname(g),c.symlinkTo),g)}};function U6e(t,e){let r=new Map([...t]),i=new Map([...e]);for(let[n,s]of t){let o=v.join(n,gi);if(!T.existsSync(o)){s.children.delete(gi);for(let a of i.keys())v.contains(o,a)!==null&&i.delete(a)}}return{locationTree:r,binSymlinks:i}}function wce(t){let e=S.parseDescriptor(t);return S.isVirtualDescriptor(e)&&(e=S.devirtualizeDescriptor(e)),e.range.startsWith("link:")}async function H6e(t,e,r,{loadManifest:i}){let n=new Map;for(let[a,{locations:l}]of t){let c=wce(a)?null:await i(a,l[0]),u=new Map;if(c)for(let[g,f]of c.bin){let h=v.join(l[0],f);f!==""&&T.existsSync(h)&&u.set(g,f)}n.set(a,u)}let s=new Map,o=(a,l,c)=>{let u=new Map,g=v.contains(r,a);if(c.locator&&g!==null){let f=n.get(c.locator);for(let[h,p]of f){let d=v.join(a,M.toPortablePath(p));u.set(kr(h),d)}for(let[h,p]of c.children){let d=v.join(a,h),m=o(d,d,p);m.size>0&&s.set(a,new Map([...s.get(a)||new Map,...m]))}}else for(let[f,h]of c.children){let p=o(v.join(a,f),l,h);for(let[d,m]of p)u.set(d,m)}return u};for(let[a,l]of e){let c=o(a,a,l);c.size>0&&s.set(a,new Map([...s.get(a)||new Map,...c]))}return s}var vce=(t,e)=>{if(!t||!e)return t===e;let r=S.parseLocator(t);S.isVirtualLocator(r)&&(r=S.devirtualizeLocator(r));let i=S.parseLocator(e);return S.isVirtualLocator(i)&&(i=S.devirtualizeLocator(i)),S.areLocatorsEqual(r,i)};function dT(t){return v.join(t.get("globalFolder"),"store")}async function T6e(t,e,{baseFs:r,project:i,report:n,loadManifest:s,realLocatorChecksums:o}){let a=v.join(i.cwd,gi),{locationTree:l,binSymlinks:c}=U6e(t.locationTree,t.binSymlinks),u=Bce(e,{skipPrefix:i.cwd}),g=[],f=async({srcDir:L,dstDir:K,linkType:J,globalHardlinksStore:ne,nmMode:q,packageChecksum:A})=>{let V=(async()=>{try{J===gt.SOFT?(await T.mkdirPromise(v.dirname(K),{recursive:!0}),await pT(v.resolve(L),K)):await K6e(K,L,{baseFs:r,globalHardlinksStore:ne,nmMode:q,packageChecksum:A})}catch(W){throw W.message=`While persisting ${L} -> ${K} ${W.message}`,W}finally{B.tick()}})().then(()=>g.splice(g.indexOf(V),1));g.push(V),g.length>Qce&&await Promise.race(g)},h=async(L,K,J)=>{let ne=(async()=>{let q=async(A,V,W)=>{try{W.innerLoop||await T.mkdirPromise(V,{recursive:!0});let X=await T.readdirPromise(A,{withFileTypes:!0});for(let F of X){if(!W.innerLoop&&F.name===gT)continue;let D=v.join(A,F.name),he=v.join(V,F.name);F.isDirectory()?(F.name!==gi||W&&W.innerLoop)&&(await T.mkdirPromise(he,{recursive:!0}),await q(D,he,_(P({},W),{innerLoop:!0}))):H.value===Bi.HARDLINKS_LOCAL||H.value===Bi.HARDLINKS_GLOBAL?await T.linkPromise(D,he):await T.copyFilePromise(D,he,mce.default.constants.COPYFILE_FICLONE)}}catch(X){throw W.innerLoop||(X.message=`While cloning ${A} -> ${V} ${X.message}`),X}finally{W.innerLoop||B.tick()}};await q(L,K,J)})().then(()=>g.splice(g.indexOf(ne),1));g.push(ne),g.length>Qce&&await Promise.race(g)},p=async(L,K,J)=>{if(!J)K.children.has(gi)&&await Ef(v.join(L,gi),{contentsOnly:!1}),await Ef(L,{contentsOnly:L===a});else for(let[ne,q]of K.children){let A=J.children.get(ne);await p(v.join(L,ne),q,A)}};for(let[L,K]of l){let J=u.get(L);for(let[ne,q]of K.children){if(ne===".")continue;let A=J&&J.children.get(ne);await p(v.join(L,ne),q,A)}}let d=async(L,K,J)=>{if(!J)K.children.has(gi)&&await Ef(v.join(L,gi),{contentsOnly:!0}),await Ef(L,{contentsOnly:K.linkType===gt.HARD});else{vce(K.locator,J.locator)||await Ef(L,{contentsOnly:K.linkType===gt.HARD});for(let[ne,q]of K.children){let A=J.children.get(ne);await d(v.join(L,ne),q,A)}}};for(let[L,K]of u){let J=l.get(L);for(let[ne,q]of K.children){if(ne===".")continue;let A=J&&J.children.get(ne);await d(v.join(L,ne),q,A)}}let m=new Map,I=[];for(let[L,{locations:K}]of t.locatorMap.entries())for(let J of K){let{locationRoot:ne,segments:q}=$0(J,{skipPrefix:i.cwd}),A=u.get(ne),V=ne;if(A){for(let W of q)if(V=v.join(V,W),A=A.children.get(W),!A)break;if(A){let W=vce(A.locator,L),X=e.get(A.locator),F=X.target,D=V,he=X.linkType;if(W)m.has(F)||m.set(F,D);else if(F!==D){let pe=S.parseLocator(A.locator);S.isVirtualLocator(pe)&&(pe=S.devirtualizeLocator(pe)),I.push({srcDir:F,dstDir:D,linkType:he,realLocatorHash:pe.locatorHash})}}}}for(let[L,{locations:K}]of e.entries())for(let J of K){let{locationRoot:ne,segments:q}=$0(J,{skipPrefix:i.cwd}),A=l.get(ne),V=u.get(ne),W=ne,X=e.get(L),F=S.parseLocator(L);S.isVirtualLocator(F)&&(F=S.devirtualizeLocator(F));let D=F.locatorHash,he=X.target,pe=J;if(he===pe)continue;let Ne=X.linkType;for(let Pe of q)V=V.children.get(Pe);if(!A)I.push({srcDir:he,dstDir:pe,linkType:Ne,realLocatorHash:D});else for(let Pe of q)if(W=v.join(W,Pe),A=A.children.get(Pe),!A){I.push({srcDir:he,dstDir:pe,linkType:Ne,realLocatorHash:D});break}}let B=Xi.progressViaCounter(I.length),b=n.reportProgress(B),R=i.configuration.get("nmMode"),H={value:R};try{let L=H.value===Bi.HARDLINKS_GLOBAL?`${dT(i.configuration)}/v1`:null;if(L&&!await T.existsPromise(L)){await T.mkdirpPromise(L);for(let J=0;J<256;J++)await T.mkdirPromise(v.join(L,J.toString(16).padStart(2,"0")))}for(let J of I)(J.linkType===gt.SOFT||!m.has(J.srcDir))&&(m.set(J.srcDir,J.dstDir),await f(_(P({},J),{globalHardlinksStore:L,nmMode:H,packageChecksum:o.get(J.realLocatorHash)||null})));await Promise.all(g),g.length=0;for(let J of I){let ne=m.get(J.srcDir);J.linkType!==gt.SOFT&&J.dstDir!==ne&&await h(ne,J.dstDir,{nmMode:H})}await Promise.all(g),await T.mkdirPromise(a,{recursive:!0});let K=await H6e(e,u,i.cwd,{loadManifest:s});await G6e(c,K,i.cwd),await M6e(i,e,K,H),R==Bi.HARDLINKS_GLOBAL&&H.value==Bi.HARDLINKS_LOCAL&&n.reportWarningOnce(z.NM_HARDLINKS_MODE_DOWNGRADED,"'nmMode' has been downgraded to 'hardlinks-local' due to global cache and install folder being on different devices")}finally{b.stop()}}async function G6e(t,e,r){for(let i of t.keys()){if(v.contains(r,i)===null)throw new Error(`Assertion failed. Excepted bin symlink location to be inside project dir, instead it was at ${i}`);if(!e.has(i)){let n=v.join(i,gi,gT);await T.removePromise(n)}}for(let[i,n]of e){if(v.contains(r,i)===null)throw new Error(`Assertion failed. Excepted bin symlink location to be inside project dir, instead it was at ${i}`);let s=v.join(i,gi,gT),o=t.get(i)||new Map;await T.mkdirPromise(s,{recursive:!0});for(let a of o.keys())n.has(a)||(await T.removePromise(v.join(s,a)),process.platform==="win32"&&await T.removePromise(v.join(s,kr(`${a}.cmd`))));for(let[a,l]of n){let c=o.get(a),u=v.join(s,a);c!==l&&(process.platform==="win32"?await(0,Cce.default)(M.fromPortablePath(l),M.fromPortablePath(u),{createPwshFile:!1}):(await T.removePromise(u),await pT(l,u),v.contains(r,await T.realpathPromise(l))!==null&&await T.chmodPromise(l,493)))}}}var CT=class extends jc{constructor(){super(...arguments);this.mode="loose"}makeInstaller(e){return new Sce(e)}},Sce=class extends Cf{constructor(){super(...arguments);this.mode="loose"}async transformPnpSettings(e){let r=new Pr({baseFs:new Jn({libzip:await $i(),maxOpenFiles:80,readOnlyArchives:!0})}),i=ice(e,this.opts.project.cwd,r),{tree:n,errors:s}=VC(i,{pnpifyFs:!1,project:this.opts.project});if(!n){for(let{messageName:u,text:g}of s)this.opts.report.reportError(u,g);return}let o=new Map;e.fallbackPool=o;let a=(u,g)=>{let f=S.parseLocator(g.locator),h=S.stringifyIdent(f);h===u?o.set(u,f.reference):o.set(u,[h,f.reference])},l=v.join(this.opts.project.cwd,wt.nodeModules),c=n.get(l);if(typeof c!="undefined"){if("target"in c)throw new Error("Assertion failed: Expected the root junction point to be a directory");for(let u of c.dirList){let g=v.join(l,u),f=n.get(g);if(typeof f=="undefined")throw new Error("Assertion failed: Expected the child to have been registered");if("target"in f)a(u,f);else for(let h of f.dirList){let p=v.join(g,h),d=n.get(p);if(typeof d=="undefined")throw new Error("Assertion failed: Expected the subchild to have been registered");if("target"in d)a(`${u}/${h}`,d);else throw new Error("Assertion failed: Expected the leaf junction to be a package")}}}}};var j6e={hooks:{cleanGlobalArtifacts:async t=>{let e=dT(t);await T.removePromise(e)}},configuration:{nmHoistingLimits:{description:"Prevent packages to be hoisted past specific levels",type:ge.STRING,values:[Sn.WORKSPACES,Sn.DEPENDENCIES,Sn.NONE],default:Sn.NONE},nmMode:{description:'If set to "hardlinks-local" Yarn will utilize hardlinks to reduce disk space consumption inside "node_modules" directories. With "hardlinks-global" Yarn will use global content addressable storage to reduce "node_modules" size across all the projects using this option.',type:ge.STRING,values:[Bi.CLASSIC,Bi.HARDLINKS_LOCAL,Bi.HARDLINKS_GLOBAL],default:Bi.CLASSIC},nmSelfReferences:{description:"If set to 'false' the workspace will not be allowed to require itself and corresponding self-referencing symlink will not be created",type:ge.BOOLEAN,default:!0}},linkers:[fT,CT]},Y6e=j6e;var yM={};it(yM,{default:()=>Z7e,npmConfigUtils:()=>gr,npmHttpUtils:()=>Lt,npmPublishUtils:()=>Rf});var Rce=ie(Or());var ir="npm:";var Lt={};it(Lt,{AuthType:()=>jn,customPackageError:()=>W6e,del:()=>_6e,get:()=>zs,getIdentUrl:()=>zA,handleInvalidAuthenticationError:()=>WA,post:()=>z6e,put:()=>V6e});var Pce=ie(aC()),Dce=ie(require("url"));var gr={};it(gr,{RegistryType:()=>ja,getAuditRegistry:()=>q6e,getAuthConfiguration:()=>IT,getDefaultRegistry:()=>eQ,getPublishRegistry:()=>xce,getRegistryConfiguration:()=>kce,getScopeConfiguration:()=>ET,getScopeRegistry:()=>Ya,normalizeRegistry:()=>To});var ja;(function(i){i.AUDIT_REGISTRY="npmAuditRegistry",i.FETCH_REGISTRY="npmRegistryServer",i.PUBLISH_REGISTRY="npmPublishRegistry"})(ja||(ja={}));function To(t){return t.replace(/\/$/,"")}function q6e(t,{configuration:e}){let r=e.get(ja.AUDIT_REGISTRY);return r!==null?To(r):xce(t,{configuration:e})}function xce(t,{configuration:e}){var r;return((r=t.publishConfig)==null?void 0:r.registry)?To(t.publishConfig.registry):t.name?Ya(t.name.scope,{configuration:e,type:ja.PUBLISH_REGISTRY}):eQ({configuration:e,type:ja.PUBLISH_REGISTRY})}function Ya(t,{configuration:e,type:r=ja.FETCH_REGISTRY}){let i=ET(t,{configuration:e});if(i===null)return eQ({configuration:e,type:r});let n=i.get(r);return n===null?eQ({configuration:e,type:r}):To(n)}function eQ({configuration:t,type:e=ja.FETCH_REGISTRY}){let r=t.get(e);return To(r!==null?r:t.get(ja.FETCH_REGISTRY))}function kce(t,{configuration:e}){let r=e.get("npmRegistries"),i=To(t),n=r.get(i);if(typeof n!="undefined")return n;let s=r.get(i.replace(/^[a-z]+:/,""));return typeof s!="undefined"?s:null}function ET(t,{configuration:e}){if(t===null)return null;let i=e.get("npmScopes").get(t);return i||null}function IT(t,{configuration:e,ident:r}){let i=r&&ET(r.scope,{configuration:e});return(i==null?void 0:i.get("npmAuthIdent"))||(i==null?void 0:i.get("npmAuthToken"))?i:kce(t,{configuration:e})||e}var jn;(function(n){n[n.NO_AUTH=0]="NO_AUTH",n[n.BEST_EFFORT=1]="BEST_EFFORT",n[n.CONFIGURATION=2]="CONFIGURATION",n[n.ALWAYS_AUTH=3]="ALWAYS_AUTH"})(jn||(jn={}));async function WA(t,{attemptedAs:e,registry:r,headers:i,configuration:n}){var s,o;if(((s=t.originalError)==null?void 0:s.name)==="HTTPError"&&((o=t.originalError)==null?void 0:o.response.statusCode)===401)throw new nt(z.AUTHENTICATION_INVALID,`Invalid authentication (${typeof e!="string"?`as ${await J6e(r,i,{configuration:n})}`:`attempted as ${e}`})`)}function W6e(t){var e;return((e=t.response)==null?void 0:e.statusCode)===404?"Package not found":null}function zA(t){return t.scope?`/@${t.scope}%2f${t.name}`:`/${t.name}`}async function zs(t,a){var l=a,{configuration:e,headers:r,ident:i,authType:n,registry:s}=l,o=qr(l,["configuration","headers","ident","authType","registry"]);if(i&&typeof s=="undefined"&&(s=Ya(i.scope,{configuration:e})),i&&i.scope&&typeof n=="undefined"&&(n=1),typeof s!="string")throw new Error("Assertion failed: The registry should be a string");let c=await tQ(s,{authType:n,configuration:e,ident:i});c&&(r=_(P({},r),{authorization:c}));try{return await Zt.get(t.charAt(0)==="/"?`${s}${t}`:t,P({configuration:e,headers:r},o))}catch(u){throw await WA(u,{registry:s,configuration:e,headers:r}),u}}async function z6e(t,e,c){var u=c,{attemptedAs:r,configuration:i,headers:n,ident:s,authType:o=3,registry:a}=u,l=qr(u,["attemptedAs","configuration","headers","ident","authType","registry"]);if(s&&typeof a=="undefined"&&(a=Ya(s.scope,{configuration:i})),typeof a!="string")throw new Error("Assertion failed: The registry should be a string");let g=await tQ(a,{authType:o,configuration:i,ident:s});g&&(n=_(P({},n),{authorization:g}));try{return await Zt.post(a+t,e,P({configuration:i,headers:n},l))}catch(f){if(!wT(f))throw await WA(f,{attemptedAs:r,registry:a,configuration:i,headers:n}),f;let h=await yT(),p=P(P({},n),BT(h));try{return await Zt.post(`${a}${t}`,e,P({configuration:i,headers:p},l))}catch(d){throw await WA(d,{attemptedAs:r,registry:a,configuration:i,headers:n}),d}}}async function V6e(t,e,c){var u=c,{attemptedAs:r,configuration:i,headers:n,ident:s,authType:o=3,registry:a}=u,l=qr(u,["attemptedAs","configuration","headers","ident","authType","registry"]);if(s&&typeof a=="undefined"&&(a=Ya(s.scope,{configuration:i})),typeof a!="string")throw new Error("Assertion failed: The registry should be a string");let g=await tQ(a,{authType:o,configuration:i,ident:s});g&&(n=_(P({},n),{authorization:g}));try{return await Zt.put(a+t,e,P({configuration:i,headers:n},l))}catch(f){if(!wT(f))throw await WA(f,{attemptedAs:r,registry:a,configuration:i,headers:n}),f;let h=await yT(),p=P(P({},n),BT(h));try{return await Zt.put(`${a}${t}`,e,P({configuration:i,headers:p},l))}catch(d){throw await WA(d,{attemptedAs:r,registry:a,configuration:i,headers:n}),d}}}async function _6e(t,l){var c=l,{attemptedAs:e,configuration:r,headers:i,ident:n,authType:s=3,registry:o}=c,a=qr(c,["attemptedAs","configuration","headers","ident","authType","registry"]);if(n&&typeof o=="undefined"&&(o=Ya(n.scope,{configuration:r})),typeof o!="string")throw new Error("Assertion failed: The registry should be a string");let u=await tQ(o,{authType:s,configuration:r,ident:n});u&&(i=_(P({},i),{authorization:u}));try{return await Zt.del(o+t,P({configuration:r,headers:i},a))}catch(g){if(!wT(g))throw await WA(g,{attemptedAs:e,registry:o,configuration:r,headers:i}),g;let f=await yT(),h=P(P({},i),BT(f));try{return await Zt.del(`${o}${t}`,P({configuration:r,headers:h},a))}catch(p){throw await WA(p,{attemptedAs:e,registry:o,configuration:r,headers:i}),p}}}async function tQ(t,{authType:e=2,configuration:r,ident:i}){let n=IT(t,{configuration:r,ident:i}),s=X6e(n,e);if(!s)return null;let o=await r.reduceHook(a=>a.getNpmAuthenticationHeader,void 0,t,{configuration:r,ident:i});if(o)return o;if(n.get("npmAuthToken"))return`Bearer ${n.get("npmAuthToken")}`;if(n.get("npmAuthIdent")){let a=n.get("npmAuthIdent");return a.includes(":")?`Basic ${Buffer.from(a).toString("base64")}`:`Basic ${a}`}if(s&&e!==1)throw new nt(z.AUTHENTICATION_NOT_FOUND,"No authentication configured for request");return null}function X6e(t,e){switch(e){case 2:return t.get("npmAlwaysAuth");case 1:case 3:return!0;case 0:return!1;default:throw new Error("Unreachable")}}async function J6e(t,e,{configuration:r}){var i;if(typeof e=="undefined"||typeof e.authorization=="undefined")return"an anonymous user";try{return(i=(await Zt.get(new Dce.URL(`${t}/-/whoami`).href,{configuration:r,headers:e,jsonResponse:!0})).username)!=null?i:"an unknown user"}catch{return"an unknown user"}}async function yT(){if(process.env.TEST_ENV)return process.env.TEST_NPM_2FA_TOKEN||"";let{otp:t}=await(0,Pce.prompt)({type:"password",name:"otp",message:"One-time password:",required:!0,onCancel:()=>process.exit(130)});return t}function wT(t){var e,r;if(((e=t.originalError)==null?void 0:e.name)!=="HTTPError")return!1;try{return((r=t.originalError)==null?void 0:r.response.headers["www-authenticate"].split(/,\s*/).map(n=>n.toLowerCase())).includes("otp")}catch(i){return!1}}function BT(t){return{["npm-otp"]:t}}var QT=class{supports(e,r){if(!e.reference.startsWith(ir))return!1;let{selector:i,params:n}=S.parseRange(e.reference);return!(!Rce.default.valid(i)||n===null||typeof n.__archiveUrl!="string")}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the remote server`),loader:()=>this.fetchFromNetwork(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:S.getIdentVendorPath(e),checksum:o}}async fetchFromNetwork(e,r){let{params:i}=S.parseRange(e.reference);if(i===null||typeof i.__archiveUrl!="string")throw new Error("Assertion failed: The archiveUrl querystring parameter should have been available");let n=await zs(i.__archiveUrl,{configuration:r.project.configuration,ident:e});return await Ai.convertToZip(n,{compressionLevel:r.project.configuration.get("compressionLevel"),prefixPath:S.getIdentVendorPath(e),stripComponents:1})}};var bT=class{supportsDescriptor(e,r){return!(!e.range.startsWith(ir)||!S.tryParseDescriptor(e.range.slice(ir.length),!0))}supportsLocator(e,r){return!1}shouldPersistResolution(e,r){throw new Error("Unreachable")}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){let i=S.parseDescriptor(e.range.slice(ir.length),!0);return r.resolver.getResolutionDependencies(i,r)}async getCandidates(e,r,i){let n=S.parseDescriptor(e.range.slice(ir.length),!0);return await i.resolver.getCandidates(n,r,i)}async getSatisfying(e,r,i){let n=S.parseDescriptor(e.range.slice(ir.length),!0);return i.resolver.getSatisfying(n,r,i)}resolve(e,r){throw new Error("Unreachable")}};var vT=ie(Or()),Fce=ie(require("url"));var Vs=class{supports(e,r){if(!e.reference.startsWith(ir))return!1;let i=new Fce.URL(e.reference);return!(!vT.default.valid(i.pathname)||i.searchParams.has("__archiveUrl"))}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the remote registry`),loader:()=>this.fetchFromNetwork(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:S.getIdentVendorPath(e),checksum:o}}async fetchFromNetwork(e,r){let i;try{i=await zs(Vs.getLocatorUrl(e),{configuration:r.project.configuration,ident:e})}catch(n){i=await zs(Vs.getLocatorUrl(e).replace(/%2f/g,"/"),{configuration:r.project.configuration,ident:e})}return await Ai.convertToZip(i,{compressionLevel:r.project.configuration.get("compressionLevel"),prefixPath:S.getIdentVendorPath(e),stripComponents:1})}static isConventionalTarballUrl(e,r,{configuration:i}){let n=Ya(e.scope,{configuration:i}),s=Vs.getLocatorUrl(e);return r=r.replace(/^https?:(\/\/(?:[^/]+\.)?npmjs.org(?:$|\/))/,"https:$1"),n=n.replace(/^https:\/\/registry\.npmjs\.org($|\/)/,"https://registry.yarnpkg.com$1"),r=r.replace(/^https:\/\/registry\.npmjs\.org($|\/)/,"https://registry.yarnpkg.com$1"),r===n+s||r===n+s.replace(/%2f/g,"/")}static getLocatorUrl(e){let r=vT.default.clean(e.reference.slice(ir.length));if(r===null)throw new nt(z.RESOLVER_NOT_FOUND,"The npm semver resolver got selected, but the version isn't semver");return`${zA(e)}/-/${e.name}-${r}.tgz`}};var ST=ie(Or());var rQ=S.makeIdent(null,"node-gyp"),Z6e=/\b(node-gyp|prebuild-install)\b/,xT=class{supportsDescriptor(e,r){return e.range.startsWith(ir)?!!qt.validRange(e.range.slice(ir.length)):!1}supportsLocator(e,r){if(!e.reference.startsWith(ir))return!1;let{selector:i}=S.parseRange(e.reference);return!!ST.default.valid(i)}shouldPersistResolution(e,r){return!0}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){let n=qt.validRange(e.range.slice(ir.length));if(n===null)throw new Error(`Expected a valid range, got ${e.range.slice(ir.length)}`);let s=await zs(zA(e),{configuration:i.project.configuration,ident:e,jsonResponse:!0}),o=de.mapAndFilter(Object.keys(s.versions),c=>{try{let u=new qt.SemVer(c);if(n.test(u))return u}catch{}return de.mapAndFilter.skip}),a=o.filter(c=>!s.versions[c.raw].deprecated),l=a.length>0?a:o;return l.sort((c,u)=>-c.compare(u)),l.map(c=>{let u=S.makeLocator(e,`${ir}${c.raw}`),g=s.versions[c.raw].dist.tarball;return Vs.isConventionalTarballUrl(u,g,{configuration:i.project.configuration})?u:S.bindLocator(u,{__archiveUrl:g})})}async getSatisfying(e,r,i){let n=qt.validRange(e.range.slice(ir.length));if(n===null)throw new Error(`Expected a valid range, got ${e.range.slice(ir.length)}`);return de.mapAndFilter(r,s=>{try{let{selector:o}=S.parseRange(s,{requireProtocol:ir}),a=new qt.SemVer(o);if(n.test(a))return{reference:s,version:a}}catch{}return de.mapAndFilter.skip}).sort((s,o)=>-s.version.compare(o.version)).map(({reference:s})=>S.makeLocator(e,s))}async resolve(e,r){let{selector:i}=S.parseRange(e.reference),n=ST.default.clean(i);if(n===null)throw new nt(z.RESOLVER_NOT_FOUND,"The npm semver resolver got selected, but the version isn't semver");let s=await zs(zA(e),{configuration:r.project.configuration,ident:e,jsonResponse:!0});if(!Object.prototype.hasOwnProperty.call(s,"versions"))throw new nt(z.REMOTE_INVALID,'Registry returned invalid data for - missing "versions" field');if(!Object.prototype.hasOwnProperty.call(s.versions,n))throw new nt(z.REMOTE_NOT_FOUND,`Registry failed to return reference "${n}"`);let o=new Ze;if(o.load(s.versions[n]),!o.dependencies.has(rQ.identHash)&&!o.peerDependencies.has(rQ.identHash)){for(let a of o.scripts.values())if(a.match(Z6e)){o.dependencies.set(rQ.identHash,S.makeDescriptor(rQ,"latest")),r.report.reportWarningOnce(z.NODE_GYP_INJECTED,`${S.prettyLocator(r.project.configuration,e)}: Implicit dependencies on node-gyp are discouraged`);break}}return typeof o.raw.deprecated=="string"&&r.report.reportWarningOnce(z.DEPRECATED_PACKAGE,`${S.prettyLocator(r.project.configuration,e)} is deprecated: ${o.raw.deprecated}`),_(P({},e),{version:n,languageName:"node",linkType:gt.HARD,conditions:o.getConditions(),dependencies:o.dependencies,peerDependencies:o.peerDependencies,dependenciesMeta:o.dependenciesMeta,peerDependenciesMeta:o.peerDependenciesMeta,bin:o.bin})}};var kT=class{supportsDescriptor(e,r){return!(!e.range.startsWith(ir)||!Rg.test(e.range.slice(ir.length)))}supportsLocator(e,r){return!1}shouldPersistResolution(e,r){throw new Error("Unreachable")}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){let n=e.range.slice(ir.length),s=await zs(zA(e),{configuration:i.project.configuration,ident:e,jsonResponse:!0});if(!Object.prototype.hasOwnProperty.call(s,"dist-tags"))throw new nt(z.REMOTE_INVALID,'Registry returned invalid data - missing "dist-tags" field');let o=s["dist-tags"];if(!Object.prototype.hasOwnProperty.call(o,n))throw new nt(z.REMOTE_NOT_FOUND,`Registry failed to return tag "${n}"`);let a=o[n],l=S.makeLocator(e,`${ir}${a}`),c=s.versions[a].dist.tarball;return Vs.isConventionalTarballUrl(l,c,{configuration:i.project.configuration})?[l]:[S.bindLocator(l,{__archiveUrl:c})]}async getSatisfying(e,r,i){return null}async resolve(e,r){throw new Error("Unreachable")}};var Rf={};it(Rf,{getGitHead:()=>_7e,makePublishBody:()=>V7e});var CM={};it(CM,{default:()=>D7e,packUtils:()=>za});var za={};it(za,{genPackList:()=>QQ,genPackStream:()=>dM,genPackageManifest:()=>age,hasPackScripts:()=>hM,prepareForPack:()=>pM});var fM=ie(Nn()),sge=ie(nge()),oge=ie(require("zlib")),I7e=["/package.json","/readme","/readme.*","/license","/license.*","/licence","/licence.*","/changelog","/changelog.*"],y7e=["/package.tgz",".github",".git",".hg","node_modules",".npmignore",".gitignore",".#*",".DS_Store"];async function hM(t){return!!(Kt.hasWorkspaceScript(t,"prepack")||Kt.hasWorkspaceScript(t,"postpack"))}async function pM(t,{report:e},r){await Kt.maybeExecuteWorkspaceLifecycleScript(t,"prepack",{report:e});try{let i=v.join(t.cwd,Ze.fileName);await T.existsPromise(i)&&await t.manifest.loadFile(i,{baseFs:T}),await r()}finally{await Kt.maybeExecuteWorkspaceLifecycleScript(t,"postpack",{report:e})}}async function dM(t,e){var s,o;typeof e=="undefined"&&(e=await QQ(t));let r=new Set;for(let a of(o=(s=t.manifest.publishConfig)==null?void 0:s.executableFiles)!=null?o:new Set)r.add(v.normalize(a));for(let a of t.manifest.bin.values())r.add(v.normalize(a));let i=sge.default.pack();process.nextTick(async()=>{for(let a of e){let l=v.normalize(a),c=v.resolve(t.cwd,l),u=v.join("package",l),g=await T.lstatPromise(c),f={name:u,mtime:new Date(mr.SAFE_TIME*1e3)},h=r.has(l)?493:420,p,d,m=new Promise((B,b)=>{p=B,d=b}),I=B=>{B?d(B):p()};if(g.isFile()){let B;l==="package.json"?B=Buffer.from(JSON.stringify(await age(t),null,2)):B=await T.readFilePromise(c),i.entry(_(P({},f),{mode:h,type:"file"}),B,I)}else g.isSymbolicLink()?i.entry(_(P({},f),{mode:h,type:"symlink",linkname:await T.readlinkPromise(c)}),I):I(new Error(`Unsupported file type ${g.mode} for ${M.fromPortablePath(l)}`));await m}i.finalize()});let n=(0,oge.createGzip)();return i.pipe(n),n}async function age(t){let e=JSON.parse(JSON.stringify(t.manifest.raw));return await t.project.configuration.triggerHook(r=>r.beforeWorkspacePacking,t,e),e}async function QQ(t){var g,f,h,p,d,m,I,B;let e=t.project,r=e.configuration,i={accept:[],reject:[]};for(let b of y7e)i.reject.push(b);for(let b of I7e)i.accept.push(b);i.reject.push(r.get("rcFilename"));let n=b=>{if(b===null||!b.startsWith(`${t.cwd}/`))return;let R=v.relative(t.cwd,b),H=v.resolve(Se.root,R);i.reject.push(H)};n(v.resolve(e.cwd,r.get("lockfileFilename"))),n(r.get("cacheFolder")),n(r.get("globalFolder")),n(r.get("installStatePath")),n(r.get("virtualFolder")),n(r.get("yarnPath")),await r.triggerHook(b=>b.populateYarnPaths,e,b=>{n(b)});for(let b of e.workspaces){let R=v.relative(t.cwd,b.cwd);R!==""&&!R.match(/^(\.\.)?\//)&&i.reject.push(`/${R}`)}let s={accept:[],reject:[]},o=(f=(g=t.manifest.publishConfig)==null?void 0:g.main)!=null?f:t.manifest.main,a=(p=(h=t.manifest.publishConfig)==null?void 0:h.module)!=null?p:t.manifest.module,l=(m=(d=t.manifest.publishConfig)==null?void 0:d.browser)!=null?m:t.manifest.browser,c=(B=(I=t.manifest.publishConfig)==null?void 0:I.bin)!=null?B:t.manifest.bin;o!=null&&s.accept.push(v.resolve(Se.root,o)),a!=null&&s.accept.push(v.resolve(Se.root,a)),typeof l=="string"&&s.accept.push(v.resolve(Se.root,l));for(let b of c.values())s.accept.push(v.resolve(Se.root,b));if(l instanceof Map)for(let[b,R]of l.entries())s.accept.push(v.resolve(Se.root,b)),typeof R=="string"&&s.accept.push(v.resolve(Se.root,R));let u=t.manifest.files!==null;if(u){s.reject.push("/*");for(let b of t.manifest.files)Age(s.accept,b,{cwd:Se.root})}return await w7e(t.cwd,{hasExplicitFileList:u,globalList:i,ignoreList:s})}async function w7e(t,{hasExplicitFileList:e,globalList:r,ignoreList:i}){let n=[],s=new Zo(t),o=[[Se.root,[i]]];for(;o.length>0;){let[a,l]=o.pop(),c=await s.lstatPromise(a);if(!cge(a,{globalList:r,ignoreLists:c.isDirectory()?null:l}))if(c.isDirectory()){let u=await s.readdirPromise(a),g=!1,f=!1;if(!e||a!==Se.root)for(let d of u)g=g||d===".gitignore",f=f||d===".npmignore";let h=f?await lge(s,a,".npmignore"):g?await lge(s,a,".gitignore"):null,p=h!==null?[h].concat(l):l;cge(a,{globalList:r,ignoreLists:l})&&(p=[...l,{accept:[],reject:["**/*"]}]);for(let d of u)o.push([v.resolve(a,d),p])}else(c.isFile()||c.isSymbolicLink())&&n.push(v.relative(Se.root,a))}return n.sort()}async function lge(t,e,r){let i={accept:[],reject:[]},n=await t.readFilePromise(v.join(e,r),"utf8");for(let s of n.split(/\n/g))Age(i.reject,s,{cwd:e});return i}function B7e(t,{cwd:e}){let r=t[0]==="!";return r&&(t=t.slice(1)),t.match(/\.{0,1}\//)&&(t=v.resolve(e,t)),r&&(t=`!${t}`),t}function Age(t,e,{cwd:r}){let i=e.trim();i===""||i[0]==="#"||t.push(B7e(i,{cwd:r}))}function cge(t,{globalList:e,ignoreLists:r}){if(bQ(t,e.accept))return!1;if(bQ(t,e.reject))return!0;if(r!==null)for(let i of r){if(bQ(t,i.accept))return!1;if(bQ(t,i.reject))return!0}return!1}function bQ(t,e){let r=e,i=[];for(let n=0;n{await pM(i,{report:l},async()=>{l.reportJson({base:M.fromPortablePath(i.cwd)});let c=await QQ(i);for(let u of c)l.reportInfo(null,M.fromPortablePath(u)),l.reportJson({location:M.fromPortablePath(u)});if(!this.dryRun){let u=await dM(i,c),g=T.createWriteStream(s);u.pipe(g),await new Promise(f=>{g.on("finish",f)})}}),this.dryRun||(l.reportInfo(z.UNNAMED,`Package archive generated in ${ue.pretty(e,s,ue.Type.PATH)}`),l.reportJson({output:M.fromPortablePath(s)}))})).exitCode()}};fm.paths=[["pack"]],fm.usage=ye.Usage({description:"generate a tarball from the active workspace",details:"\n This command will turn the active workspace into a compressed archive suitable for publishing. The archive will by default be stored at the root of the workspace (`package.tgz`).\n\n If the `-o,---out` is set the archive will be created at the specified path. The `%s` and `%v` variables can be used within the path and will be respectively replaced by the package name and version.\n ",examples:[["Create an archive from the active workspace","yarn pack"],["List the files that would be made part of the workspace's archive","yarn pack --dry-run"],["Name and output the archive in a dedicated folder","yarn pack --out /artifacts/%s-%v.tgz"]]});var gge=fm;function Q7e(t,{workspace:e}){let r=t.replace("%s",b7e(e)).replace("%v",v7e(e));return M.toPortablePath(r)}function b7e(t){return t.manifest.name!==null?S.slugifyIdent(t.manifest.name):"package"}function v7e(t){return t.manifest.version!==null?t.manifest.version:"unknown"}var S7e=["dependencies","devDependencies","peerDependencies"],x7e="workspace:",k7e=(t,e)=>{var i,n;e.publishConfig&&(e.publishConfig.main&&(e.main=e.publishConfig.main),e.publishConfig.browser&&(e.browser=e.publishConfig.browser),e.publishConfig.module&&(e.module=e.publishConfig.module),e.publishConfig.browser&&(e.browser=e.publishConfig.browser),e.publishConfig.exports&&(e.exports=e.publishConfig.exports),e.publishConfig.bin&&(e.bin=e.publishConfig.bin));let r=t.project;for(let s of S7e)for(let o of t.manifest.getForScope(s).values()){let a=r.tryWorkspaceByDescriptor(o),l=S.parseRange(o.range);if(l.protocol===x7e)if(a===null){if(r.tryWorkspaceByIdent(o)===null)throw new nt(z.WORKSPACE_NOT_FOUND,`${S.prettyDescriptor(r.configuration,o)}: No local workspace found for this range`)}else{let c;S.areDescriptorsEqual(o,a.anchoredDescriptor)||l.selector==="*"?c=(i=a.manifest.version)!=null?i:"0.0.0":l.selector==="~"||l.selector==="^"?c=`${l.selector}${(n=a.manifest.version)!=null?n:"0.0.0"}`:c=l.selector,e[s][S.stringifyIdent(o)]=c}}},P7e={hooks:{beforeWorkspacePacking:k7e},commands:[gge]},D7e=P7e;var yge=ie(require("crypto")),wge=ie(Ige()),Bge=ie(require("url"));async function V7e(t,e,{access:r,tag:i,registry:n,gitHead:s}){let o=t.project.configuration,a=t.manifest.name,l=t.manifest.version,c=S.stringifyIdent(a),u=(0,yge.createHash)("sha1").update(e).digest("hex"),g=wge.default.fromData(e).toString();typeof r=="undefined"&&(t.manifest.publishConfig&&typeof t.manifest.publishConfig.access=="string"?r=t.manifest.publishConfig.access:o.get("npmPublishAccess")!==null?r=o.get("npmPublishAccess"):a.scope?r="restricted":r="public");let f=await za.genPackageManifest(t),h=`${c}-${l}.tgz`,p=new Bge.URL(`${To(n)}/${c}/-/${h}`);return{_id:c,_attachments:{[h]:{content_type:"application/octet-stream",data:e.toString("base64"),length:e.length}},name:c,access:r,["dist-tags"]:{[i]:l},versions:{[l]:_(P({},f),{_id:`${c}@${l}`,name:c,version:l,gitHead:s,dist:{shasum:u,integrity:g,tarball:p.toString()}})}}}async function _7e(t){try{let{stdout:e}=await hr.execvp("git",["rev-parse","--revs-only","HEAD"],{cwd:t});return e.trim()===""?void 0:e.trim()}catch{return}}var wM={npmAlwaysAuth:{description:"URL of the selected npm registry (note: npm enterprise isn't supported)",type:ge.BOOLEAN,default:!1},npmAuthIdent:{description:"Authentication identity for the npm registry (_auth in npm and yarn v1)",type:ge.SECRET,default:null},npmAuthToken:{description:"Authentication token for the npm registry (_authToken in npm and yarn v1)",type:ge.SECRET,default:null}},Qge={npmAuditRegistry:{description:"Registry to query for audit reports",type:ge.STRING,default:null},npmPublishRegistry:{description:"Registry to push packages to",type:ge.STRING,default:null},npmRegistryServer:{description:"URL of the selected npm registry (note: npm enterprise isn't supported)",type:ge.STRING,default:"https://registry.yarnpkg.com"}},X7e={configuration:_(P(P({},wM),Qge),{npmScopes:{description:"Settings per package scope",type:ge.MAP,valueDefinition:{description:"",type:ge.SHAPE,properties:P(P({},wM),Qge)}},npmRegistries:{description:"Settings per registry",type:ge.MAP,normalizeKeys:To,valueDefinition:{description:"",type:ge.SHAPE,properties:P({},wM)}}}),fetchers:[QT,Vs],resolvers:[bT,xT,kT]},Z7e=X7e;var vM={};it(vM,{default:()=>a_e});Ss();var Ho;(function(i){i.All="all",i.Production="production",i.Development="development"})(Ho||(Ho={}));var Xs;(function(s){s.Info="info",s.Low="low",s.Moderate="moderate",s.High="high",s.Critical="critical"})(Xs||(Xs={}));var vQ=[Xs.Info,Xs.Low,Xs.Moderate,Xs.High,Xs.Critical];function bge(t,e){let r=[],i=new Set,n=o=>{i.has(o)||(i.add(o),r.push(o))};for(let o of e)n(o);let s=new Set;for(;r.length>0;){let o=r.shift(),a=t.storedResolutions.get(o);if(typeof a=="undefined")throw new Error("Assertion failed: Expected the resolution to have been registered");let l=t.storedPackages.get(a);if(!!l){s.add(o);for(let c of l.dependencies.values())n(c.descriptorHash)}}return s}function $7e(t,e){return new Set([...t].filter(r=>!e.has(r)))}function e_e(t,e,{all:r}){let i=r?t.workspaces:[e],n=i.map(f=>f.manifest),s=new Set(n.map(f=>[...f.dependencies].map(([h,p])=>h)).flat()),o=new Set(n.map(f=>[...f.devDependencies].map(([h,p])=>h)).flat()),a=i.map(f=>[...f.dependencies.values()]).flat(),l=a.filter(f=>s.has(f.identHash)).map(f=>f.descriptorHash),c=a.filter(f=>o.has(f.identHash)).map(f=>f.descriptorHash),u=bge(t,l),g=bge(t,c);return $7e(g,u)}function vge(t){let e={};for(let r of t)e[S.stringifyIdent(r)]=S.parseRange(r.range).selector;return e}function Sge(t){if(typeof t=="undefined")return new Set;let e=vQ.indexOf(t),r=vQ.slice(e);return new Set(r)}function t_e(t,e){let r=Sge(e),i={};for(let n of r)i[n]=t[n];return i}function xge(t,e){var i;let r=t_e(t,e);for(let n of Object.keys(r))if((i=r[n])!=null?i:0>0)return!0;return!1}function kge(t,e){var s;let r={},i={children:r},n=Object.values(t.advisories);if(e!=null){let o=Sge(e);n=n.filter(a=>o.has(a.severity))}for(let o of de.sortMap(n,a=>a.module_name))r[o.module_name]={label:o.module_name,value:ue.tuple(ue.Type.RANGE,o.findings.map(a=>a.version).join(", ")),children:{Issue:{label:"Issue",value:ue.tuple(ue.Type.NO_HINT,o.title)},URL:{label:"URL",value:ue.tuple(ue.Type.URL,o.url)},Severity:{label:"Severity",value:ue.tuple(ue.Type.NO_HINT,o.severity)},["Vulnerable Versions"]:{label:"Vulnerable Versions",value:ue.tuple(ue.Type.RANGE,o.vulnerable_versions)},["Patched Versions"]:{label:"Patched Versions",value:ue.tuple(ue.Type.RANGE,o.patched_versions)},Via:{label:"Via",value:ue.tuple(ue.Type.NO_HINT,Array.from(new Set(o.findings.map(a=>a.paths).flat().map(a=>a.split(">")[0]))).join(", "))},Recommendation:{label:"Recommendation",value:ue.tuple(ue.Type.NO_HINT,(s=o.recommendation)==null?void 0:s.replace(/\n/g," "))}}};return i}function Pge(t,e,{all:r,environment:i}){let n=r?t.workspaces:[e],s=[Ho.All,Ho.Production].includes(i),o=[];if(s)for(let c of n)for(let u of c.manifest.dependencies.values())o.push(u);let a=[Ho.All,Ho.Development].includes(i),l=[];if(a)for(let c of n)for(let u of c.manifest.devDependencies.values())l.push(u);return vge([...o,...l].filter(c=>S.parseRange(c.range).protocol===null))}function Dge(t,e,{all:r}){var s;let i=e_e(t,e,{all:r}),n={};for(let o of t.storedPackages.values())n[S.stringifyIdent(o)]={version:(s=o.version)!=null?s:"0.0.0",integrity:o.identHash,requires:vge(o.dependencies.values()),dev:i.has(S.convertLocatorToDescriptor(o).descriptorHash)};return n}var dm=class extends Be{constructor(){super(...arguments);this.all=Y.Boolean("-A,--all",!1,{description:"Audit dependencies from all workspaces"});this.recursive=Y.Boolean("-R,--recursive",!1,{description:"Audit transitive dependencies as well"});this.environment=Y.String("--environment",Ho.All,{description:"Which environments to cover",validator:Yi(Ho)});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.severity=Y.String("--severity",Xs.Info,{description:"Minimal severity requested for packages to be displayed",validator:Yi(Xs)})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState();let n=Pge(r,i,{all:this.all,environment:this.environment}),s=Dge(r,i,{all:this.all});if(!this.recursive)for(let f of Object.keys(s))Object.prototype.hasOwnProperty.call(n,f)?s[f].requires={}:delete s[f];let o={requires:n,dependencies:s},a=gr.getAuditRegistry(i.manifest,{configuration:e}),l,c=await Fa.start({configuration:e,stdout:this.context.stdout},async()=>{l=await Lt.post("/-/npm/v1/security/audits/quick",o,{authType:Lt.AuthType.BEST_EFFORT,configuration:e,jsonResponse:!0,registry:a})});if(c.hasErrors())return c.exitCode();let u=xge(l.metadata.vulnerabilities,this.severity);return!this.json&&u?(Hs.emitTree(kge(l,this.severity),{configuration:e,json:this.json,stdout:this.context.stdout,separators:2}),1):(await Fe.start({configuration:e,includeFooter:!1,json:this.json,stdout:this.context.stdout},async f=>{f.reportJson(l),u||f.reportInfo(z.EXCEPTION,"No audit suggestions")})).exitCode()}};dm.paths=[["npm","audit"]],dm.usage=ye.Usage({description:"perform a vulnerability audit against the installed packages",details:` + This command checks for known security reports on the packages you use. The reports are by default extracted from the npm registry, and may or may not be relevant to your actual program (not all vulnerabilities affect all code paths). + + For consistency with our other commands the default is to only check the direct dependencies for the active workspace. To extend this search to all workspaces, use \`-A,--all\`. To extend this search to both direct and transitive dependencies, use \`-R,--recursive\`. + + Applying the \`--severity\` flag will limit the audit table to vulnerabilities of the corresponding severity and above. Valid values are ${vQ.map(e=>`\`${e}\``).join(", ")}. + + If the \`--json\` flag is set, Yarn will print the output exactly as received from the registry. Regardless of this flag, the process will exit with a non-zero exit code if a report is found for the selected packages. + + To understand the dependency tree requiring vulnerable packages, check the raw report with the \`--json\` flag or use \`yarn why \` to get more information as to who depends on them. + `,examples:[["Checks for known security issues with the installed packages. The output is a list of known issues.","yarn npm audit"],["Audit dependencies in all workspaces","yarn npm audit --all"],["Limit auditing to `dependencies` (excludes `devDependencies`)","yarn npm audit --environment production"],["Show audit report as valid JSON","yarn npm audit --json"],["Audit all direct and transitive dependencies","yarn npm audit --recursive"],["Output moderate (or more severe) vulnerabilities","yarn npm audit --severity moderate"]]});var Rge=dm;var BM=ie(Or()),QM=ie(require("util")),Cm=class extends Be{constructor(){super(...arguments);this.fields=Y.String("-f,--fields",{description:"A comma-separated list of manifest fields that should be displayed"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.packages=Y.Rest()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r}=await Ke.find(e,this.context.cwd),i=typeof this.fields!="undefined"?new Set(["name",...this.fields.split(/\s*,\s*/)]):null,n=[],s=!1,o=await Fe.start({configuration:e,includeFooter:!1,json:this.json,stdout:this.context.stdout},async a=>{for(let l of this.packages){let c;if(l==="."){let b=r.topLevelWorkspace;if(!b.manifest.name)throw new me(`Missing 'name' field in ${M.fromPortablePath(v.join(b.cwd,wt.manifest))}`);c=S.makeDescriptor(b.manifest.name,"unknown")}else c=S.parseDescriptor(l);let u=Lt.getIdentUrl(c),g=bM(await Lt.get(u,{configuration:e,ident:c,jsonResponse:!0,customErrorMessage:Lt.customPackageError})),f=Object.keys(g.versions).sort(BM.default.compareLoose),p=g["dist-tags"].latest||f[f.length-1],d=qt.validRange(c.range);if(d){let b=BM.default.maxSatisfying(f,d);b!==null?p=b:(a.reportWarning(z.UNNAMED,`Unmet range ${S.prettyRange(e,c.range)}; falling back to the latest version`),s=!0)}else c.range!=="unknown"&&(a.reportWarning(z.UNNAMED,`Invalid range ${S.prettyRange(e,c.range)}; falling back to the latest version`),s=!0);let m=g.versions[p],I=_(P(P({},g),m),{version:p,versions:f}),B;if(i!==null){B={};for(let b of i){let R=I[b];if(typeof R!="undefined")B[b]=R;else{a.reportWarning(z.EXCEPTION,`The '${b}' field doesn't exist inside ${S.prettyIdent(e,c)}'s informations`),s=!0;continue}}}else this.json||(delete I.dist,delete I.readme,delete I.users),B=I;a.reportJson(B),this.json||n.push(B)}});QM.inspect.styles.name="cyan";for(let a of n)(a!==n[0]||s)&&this.context.stdout.write(` +`),this.context.stdout.write(`${(0,QM.inspect)(a,{depth:Infinity,colors:!0,compact:!1})} +`);return o.exitCode()}};Cm.paths=[["npm","info"]],Cm.usage=ye.Usage({category:"Npm-related commands",description:"show information about a package",details:"\n This command will fetch information about a package from the npm registry, and prints it in a tree format.\n\n The package does not have to be installed locally, but needs to have been published (in particular, local changes will be ignored even for workspaces).\n\n Append `@` to the package argument to provide information specific to the latest version that satisfies the range. If the range is invalid or if there is no version satisfying the range, the command will print a warning and fall back to the latest version.\n\n If the `-f,--fields` option is set, it's a comma-separated list of fields which will be used to only display part of the package informations.\n\n By default, this command won't return the `dist`, `readme`, and `users` fields, since they are often very long. To explicitly request those fields, explicitly list them with the `--fields` flag or request the output in JSON mode.\n ",examples:[["Show all available information about react (except the `dist`, `readme`, and `users` fields)","yarn npm info react"],["Show all available information about react as valid JSON (including the `dist`, `readme`, and `users` fields)","yarn npm info react --json"],["Show all available information about react 16.12.0","yarn npm info react@16.12.0"],["Show the description of react","yarn npm info react --fields description"],["Show all available versions of react","yarn npm info react --fields versions"],["Show the readme of react","yarn npm info react --fields readme"],["Show a few fields of react","yarn npm info react --fields homepage,repository"]]});var Fge=Cm;function bM(t){if(Array.isArray(t)){let e=[];for(let r of t)r=bM(r),r&&e.push(r);return e}else if(typeof t=="object"&&t!==null){let e={};for(let r of Object.keys(t)){if(r.startsWith("_"))continue;let i=bM(t[r]);i&&(e[r]=i)}return e}else return t||null}var Nge=ie(aC()),mm=class extends Be{constructor(){super(...arguments);this.scope=Y.String("-s,--scope",{description:"Login to the registry configured for a given scope"});this.publish=Y.Boolean("--publish",!1,{description:"Login to the publish registry"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=await SQ({configuration:e,cwd:this.context.cwd,publish:this.publish,scope:this.scope});return(await Fe.start({configuration:e,stdout:this.context.stdout},async n=>{let s=await i_e({registry:r,report:n,stdin:this.context.stdin,stdout:this.context.stdout}),o=`/-/user/org.couchdb.user:${encodeURIComponent(s.name)}`,a=await Lt.put(o,s,{attemptedAs:s.name,configuration:e,registry:r,jsonResponse:!0,authType:Lt.AuthType.NO_AUTH});return await r_e(r,a.token,{configuration:e,scope:this.scope}),n.reportInfo(z.UNNAMED,"Successfully logged in")})).exitCode()}};mm.paths=[["npm","login"]],mm.usage=ye.Usage({category:"Npm-related commands",description:"store new login info to access the npm registry",details:"\n This command will ask you for your username, password, and 2FA One-Time-Password (when it applies). It will then modify your local configuration (in your home folder, never in the project itself) to reference the new tokens thus generated.\n\n Adding the `-s,--scope` flag will cause the authentication to be done against whatever registry is configured for the associated scope (see also `npmScopes`).\n\n Adding the `--publish` flag will cause the authentication to be done against the registry used when publishing the package (see also `publishConfig.registry` and `npmPublishRegistry`).\n ",examples:[["Login to the default registry","yarn npm login"],["Login to the registry linked to the @my-scope registry","yarn npm login --scope my-scope"],["Login to the publish registry for the current package","yarn npm login --publish"]]});var Lge=mm;async function SQ({scope:t,publish:e,configuration:r,cwd:i}){return t&&e?gr.getScopeRegistry(t,{configuration:r,type:gr.RegistryType.PUBLISH_REGISTRY}):t?gr.getScopeRegistry(t,{configuration:r}):e?gr.getPublishRegistry((await rf(r,i)).manifest,{configuration:r}):gr.getDefaultRegistry({configuration:r})}async function r_e(t,e,{configuration:r,scope:i}){let n=o=>a=>{let l=de.isIndexableObject(a)?a:{},c=l[o],u=de.isIndexableObject(c)?c:{};return _(P({},l),{[o]:_(P({},u),{npmAuthToken:e})})},s=i?{npmScopes:n(i)}:{npmRegistries:n(t)};return await fe.updateHomeConfiguration(s)}async function i_e({registry:t,report:e,stdin:r,stdout:i}){if(process.env.TEST_ENV)return{name:process.env.TEST_NPM_USER||"",password:process.env.TEST_NPM_PASSWORD||""};e.reportInfo(z.UNNAMED,`Logging in to ${t}`);let n=!1;t.match(/^https:\/\/npm\.pkg\.github\.com(\/|$)/)&&(e.reportInfo(z.UNNAMED,"You seem to be using the GitHub Package Registry. Tokens must be generated with the 'repo', 'write:packages', and 'read:packages' permissions."),n=!0),e.reportSeparator();let{username:s,password:o}=await(0,Nge.prompt)([{type:"input",name:"username",message:"Username:",required:!0,onCancel:()=>process.exit(130),stdin:r,stdout:i},{type:"password",name:"password",message:n?"Token:":"Password:",required:!0,onCancel:()=>process.exit(130),stdin:r,stdout:i}]);return e.reportSeparator(),{name:s,password:o}}var Ff=new Set(["npmAuthIdent","npmAuthToken"]),Em=class extends Be{constructor(){super(...arguments);this.scope=Y.String("-s,--scope",{description:"Logout of the registry configured for a given scope"});this.publish=Y.Boolean("--publish",!1,{description:"Logout of the publish registry"});this.all=Y.Boolean("-A,--all",!1,{description:"Logout of all registries"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=async()=>{var l;let n=await SQ({configuration:e,cwd:this.context.cwd,publish:this.publish,scope:this.scope}),s=await fe.find(this.context.cwd,this.context.plugins),o=S.makeIdent((l=this.scope)!=null?l:null,"pkg");return!gr.getAuthConfiguration(n,{configuration:s,ident:o}).get("npmAuthToken")};return(await Fe.start({configuration:e,stdout:this.context.stdout},async n=>{if(this.all&&(await n_e(),n.reportInfo(z.UNNAMED,"Successfully logged out from everything")),this.scope){await Tge("npmScopes",this.scope),await r()?n.reportInfo(z.UNNAMED,`Successfully logged out from ${this.scope}`):n.reportWarning(z.UNNAMED,"Scope authentication settings removed, but some other ones settings still apply to it");return}let s=await SQ({configuration:e,cwd:this.context.cwd,publish:this.publish});await Tge("npmRegistries",s),await r()?n.reportInfo(z.UNNAMED,`Successfully logged out from ${s}`):n.reportWarning(z.UNNAMED,"Registry authentication settings removed, but some other ones settings still apply to it")})).exitCode()}};Em.paths=[["npm","logout"]],Em.usage=ye.Usage({category:"Npm-related commands",description:"logout of the npm registry",details:"\n This command will log you out by modifying your local configuration (in your home folder, never in the project itself) to delete all credentials linked to a registry.\n\n Adding the `-s,--scope` flag will cause the deletion to be done against whatever registry is configured for the associated scope (see also `npmScopes`).\n\n Adding the `--publish` flag will cause the deletion to be done against the registry used when publishing the package (see also `publishConfig.registry` and `npmPublishRegistry`).\n\n Adding the `-A,--all` flag will cause the deletion to be done against all registries and scopes.\n ",examples:[["Logout of the default registry","yarn npm logout"],["Logout of the @my-scope scope","yarn npm logout --scope my-scope"],["Logout of the publish registry for the current package","yarn npm logout --publish"],["Logout of all registries","yarn npm logout --all"]]});var Mge=Em;function s_e(t,e){let r=t[e];if(!de.isIndexableObject(r))return!1;let i=new Set(Object.keys(r));if([...Ff].every(s=>!i.has(s)))return!1;for(let s of Ff)i.delete(s);if(i.size===0)return t[e]=void 0,!0;let n=P({},r);for(let s of Ff)delete n[s];return t[e]=n,!0}async function n_e(){let t=e=>{let r=!1,i=de.isIndexableObject(e)?P({},e):{};i.npmAuthToken&&(delete i.npmAuthToken,r=!0);for(let n of Object.keys(i))s_e(i,n)&&(r=!0);if(Object.keys(i).length!==0)return r?i:e};return await fe.updateHomeConfiguration({npmRegistries:t,npmScopes:t})}async function Tge(t,e){return await fe.updateHomeConfiguration({[t]:r=>{let i=de.isIndexableObject(r)?r:{};if(!Object.prototype.hasOwnProperty.call(i,e))return r;let n=i[e],s=de.isIndexableObject(n)?n:{},o=new Set(Object.keys(s));if([...Ff].every(l=>!o.has(l)))return r;for(let l of Ff)o.delete(l);if(o.size===0)return Object.keys(i).length===1?void 0:_(P({},i),{[e]:void 0});let a={};for(let l of Ff)a[l]=void 0;return _(P({},i),{[e]:P(P({},s),a)})}})}var Im=class extends Be{constructor(){super(...arguments);this.access=Y.String("--access",{description:"The access for the published package (public or restricted)"});this.tag=Y.String("--tag","latest",{description:"The tag on the registry that the package should be attached to"});this.tolerateRepublish=Y.Boolean("--tolerate-republish",!1,{description:"Warn and exit when republishing an already existing version of a package"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);if(i.manifest.private)throw new me("Private workspaces cannot be published");if(i.manifest.name===null||i.manifest.version===null)throw new me("Workspaces must have valid names and versions to be published on an external registry");await r.restoreInstallState();let n=i.manifest.name,s=i.manifest.version,o=gr.getPublishRegistry(i.manifest,{configuration:e});return(await Fe.start({configuration:e,stdout:this.context.stdout},async l=>{var c,u;if(this.tolerateRepublish)try{let g=await Lt.get(Lt.getIdentUrl(n),{configuration:e,registry:o,ident:n,jsonResponse:!0});if(!Object.prototype.hasOwnProperty.call(g,"versions"))throw new nt(z.REMOTE_INVALID,'Registry returned invalid data for - missing "versions" field');if(Object.prototype.hasOwnProperty.call(g.versions,s)){l.reportWarning(z.UNNAMED,`Registry already knows about version ${s}; skipping.`);return}}catch(g){if(((u=(c=g.originalError)==null?void 0:c.response)==null?void 0:u.statusCode)!==404)throw g}await Kt.maybeExecuteWorkspaceLifecycleScript(i,"prepublish",{report:l}),await za.prepareForPack(i,{report:l},async()=>{let g=await za.genPackList(i);for(let m of g)l.reportInfo(null,m);let f=await za.genPackStream(i,g),h=await de.bufferStream(f),p=await Rf.getGitHead(i.cwd),d=await Rf.makePublishBody(i,h,{access:this.access,tag:this.tag,registry:o,gitHead:p});await Lt.put(Lt.getIdentUrl(n),d,{configuration:e,registry:o,ident:n,jsonResponse:!0})}),l.reportInfo(z.UNNAMED,"Package archive published")})).exitCode()}};Im.paths=[["npm","publish"]],Im.usage=ye.Usage({category:"Npm-related commands",description:"publish the active workspace to the npm registry",details:'\n This command will pack the active workspace into a fresh archive and upload it to the npm registry.\n\n The package will by default be attached to the `latest` tag on the registry, but this behavior can be overriden by using the `--tag` option.\n\n Note that for legacy reasons scoped packages are by default published with an access set to `restricted` (aka "private packages"). This requires you to register for a paid npm plan. In case you simply wish to publish a public scoped package to the registry (for free), just add the `--access public` flag. This behavior can be enabled by default through the `npmPublishAccess` settings.\n ',examples:[["Publish the active workspace","yarn npm publish"]]});var Oge=Im;var Uge=ie(Or());var ym=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.package=Y.String({required:!1})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n;if(typeof this.package!="undefined")n=S.parseIdent(this.package);else{if(!i)throw new rt(r.cwd,this.context.cwd);if(!i.manifest.name)throw new me(`Missing 'name' field in ${M.fromPortablePath(v.join(i.cwd,wt.manifest))}`);n=i.manifest.name}let s=await wm(n,e),a={children:de.sortMap(Object.entries(s),([l])=>l).map(([l,c])=>({value:ue.tuple(ue.Type.RESOLUTION,{descriptor:S.makeDescriptor(n,l),locator:S.makeLocator(n,c)})}))};return Hs.emitTree(a,{configuration:e,json:this.json,stdout:this.context.stdout})}};ym.paths=[["npm","tag","list"]],ym.usage=ye.Usage({category:"Npm-related commands",description:"list all dist-tags of a package",details:` + This command will list all tags of a package from the npm registry. + + If the package is not specified, Yarn will default to the current workspace. + `,examples:[["List all tags of package `my-pkg`","yarn npm tag list my-pkg"]]});var Kge=ym;async function wm(t,e){let r=`/-/package${Lt.getIdentUrl(t)}/dist-tags`;return Lt.get(r,{configuration:e,ident:t,jsonResponse:!0,customErrorMessage:Lt.customPackageError})}var Bm=class extends Be{constructor(){super(...arguments);this.package=Y.String();this.tag=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);let n=S.parseDescriptor(this.package,!0),s=n.range;if(!Uge.default.valid(s))throw new me(`The range ${ue.pretty(e,n.range,ue.Type.RANGE)} must be a valid semver version`);let o=gr.getPublishRegistry(i.manifest,{configuration:e}),a=ue.pretty(e,n,ue.Type.IDENT),l=ue.pretty(e,s,ue.Type.RANGE),c=ue.pretty(e,this.tag,ue.Type.CODE);return(await Fe.start({configuration:e,stdout:this.context.stdout},async g=>{let f=await wm(n,e);Object.prototype.hasOwnProperty.call(f,this.tag)&&f[this.tag]===s&&g.reportWarning(z.UNNAMED,`Tag ${c} is already set to version ${l}`);let h=`/-/package${Lt.getIdentUrl(n)}/dist-tags/${encodeURIComponent(this.tag)}`;await Lt.put(h,s,{configuration:e,registry:o,ident:n,jsonRequest:!0,jsonResponse:!0}),g.reportInfo(z.UNNAMED,`Tag ${c} added to version ${l} of package ${a}`)})).exitCode()}};Bm.paths=[["npm","tag","add"]],Bm.usage=ye.Usage({category:"Npm-related commands",description:"add a tag for a specific version of a package",details:` + This command will add a tag to the npm registry for a specific version of a package. If the tag already exists, it will be overwritten. + `,examples:[["Add a `beta` tag for version `2.3.4-beta.4` of package `my-pkg`","yarn npm tag add my-pkg@2.3.4-beta.4 beta"]]});var Hge=Bm;var Qm=class extends Be{constructor(){super(...arguments);this.package=Y.String();this.tag=Y.String()}async execute(){if(this.tag==="latest")throw new me("The 'latest' tag cannot be removed.");let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);let n=S.parseIdent(this.package),s=gr.getPublishRegistry(i.manifest,{configuration:e}),o=ue.pretty(e,this.tag,ue.Type.CODE),a=ue.pretty(e,n,ue.Type.IDENT),l=await wm(n,e);if(!Object.prototype.hasOwnProperty.call(l,this.tag))throw new me(`${o} is not a tag of package ${a}`);return(await Fe.start({configuration:e,stdout:this.context.stdout},async u=>{let g=`/-/package${Lt.getIdentUrl(n)}/dist-tags/${encodeURIComponent(this.tag)}`;await Lt.del(g,{configuration:e,registry:s,ident:n,jsonResponse:!0}),u.reportInfo(z.UNNAMED,`Tag ${o} removed from package ${a}`)})).exitCode()}};Qm.paths=[["npm","tag","remove"]],Qm.usage=ye.Usage({category:"Npm-related commands",description:"remove a tag from a package",details:` + This command will remove a tag from a package from the npm registry. + `,examples:[["Remove the `beta` tag from package `my-pkg`","yarn npm tag remove my-pkg beta"]]});var Gge=Qm;var bm=class extends Be{constructor(){super(...arguments);this.scope=Y.String("-s,--scope",{description:"Print username for the registry configured for a given scope"});this.publish=Y.Boolean("--publish",!1,{description:"Print username for the publish registry"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r;return this.scope&&this.publish?r=gr.getScopeRegistry(this.scope,{configuration:e,type:gr.RegistryType.PUBLISH_REGISTRY}):this.scope?r=gr.getScopeRegistry(this.scope,{configuration:e}):this.publish?r=gr.getPublishRegistry((await rf(e,this.context.cwd)).manifest,{configuration:e}):r=gr.getDefaultRegistry({configuration:e}),(await Fe.start({configuration:e,stdout:this.context.stdout},async n=>{var o,a;let s;try{s=await Lt.get("/-/whoami",{configuration:e,registry:r,authType:Lt.AuthType.ALWAYS_AUTH,jsonResponse:!0,ident:this.scope?S.makeIdent(this.scope,""):void 0})}catch(l){if(((o=l.response)==null?void 0:o.statusCode)===401||((a=l.response)==null?void 0:a.statusCode)===403){n.reportError(z.AUTHENTICATION_INVALID,"Authentication failed - your credentials may have expired");return}else throw l}n.reportInfo(z.UNNAMED,s.username)})).exitCode()}};bm.paths=[["npm","whoami"]],bm.usage=ye.Usage({category:"Npm-related commands",description:"display the name of the authenticated user",details:"\n Print the username associated with the current authentication settings to the standard output.\n\n When using `-s,--scope`, the username printed will be the one that matches the authentication settings of the registry associated with the given scope (those settings can be overriden using the `npmRegistries` map, and the registry associated with the scope is configured via the `npmScopes` map).\n\n When using `--publish`, the registry we'll select will by default be the one used when publishing packages (`publishConfig.registry` or `npmPublishRegistry` if available, otherwise we'll fallback to the regular `npmRegistryServer`).\n ",examples:[["Print username for the default registry","yarn npm whoami"],["Print username for the registry on a given scope","yarn npm whoami --scope company"]]});var jge=bm;var o_e={configuration:{npmPublishAccess:{description:"Default access of the published packages",type:ge.STRING,default:null}},commands:[Rge,Fge,Lge,Mge,Oge,Hge,Kge,Gge,jge]},a_e=o_e;var NM={};it(NM,{default:()=>B_e,patchUtils:()=>SM});var SM={};it(SM,{applyPatchFile:()=>PQ,diffFolders:()=>DM,extractPackageToDisk:()=>PM,extractPatchFlags:()=>Xge,isParentRequired:()=>kM,loadPatchFiles:()=>km,makeDescriptor:()=>I_e,makeLocator:()=>xM,parseDescriptor:()=>Sm,parseLocator:()=>xm,parsePatchFile:()=>kQ});var vm=class extends Error{constructor(e,r){super(`Cannot apply hunk #${e+1}`);this.hunk=r}};var A_e=/^@@ -(\d+)(,(\d+))? \+(\d+)(,(\d+))? @@.*/;function Nf(t){return v.relative(Se.root,v.resolve(Se.root,M.toPortablePath(t)))}function l_e(t){let e=t.trim().match(A_e);if(!e)throw new Error(`Bad header line: '${t}'`);return{original:{start:Math.max(Number(e[1]),1),length:Number(e[3]||1)},patched:{start:Math.max(Number(e[4]),1),length:Number(e[6]||1)}}}var c_e=420,u_e=493,Lr;(function(i){i.Context="context",i.Insertion="insertion",i.Deletion="deletion"})(Lr||(Lr={}));var Yge=()=>({semverExclusivity:null,diffLineFromPath:null,diffLineToPath:null,oldMode:null,newMode:null,deletedFileMode:null,newFileMode:null,renameFrom:null,renameTo:null,beforeHash:null,afterHash:null,fromPath:null,toPath:null,hunks:null}),g_e=t=>({header:l_e(t),parts:[]}),f_e={["@"]:"header",["-"]:Lr.Deletion,["+"]:Lr.Insertion,[" "]:Lr.Context,["\\"]:"pragma",undefined:Lr.Context};function p_e(t){let e=[],r=Yge(),i="parsing header",n=null,s=null;function o(){n&&(s&&(n.parts.push(s),s=null),r.hunks.push(n),n=null)}function a(){o(),e.push(r),r=Yge()}for(let l=0;l0?"patch":"mode change",B=null;switch(I){case"rename":{if(!u||!g)throw new Error("Bad parser state: rename from & to not given");e.push({type:"rename",semverExclusivity:i,fromPath:Nf(u),toPath:Nf(g)}),B=g}break;case"file deletion":{let b=n||p;if(!b)throw new Error("Bad parse state: no path given for file deletion");e.push({type:"file deletion",semverExclusivity:i,hunk:m&&m[0]||null,path:Nf(b),mode:xQ(l),hash:f})}break;case"file creation":{let b=s||d;if(!b)throw new Error("Bad parse state: no path given for file creation");e.push({type:"file creation",semverExclusivity:i,hunk:m&&m[0]||null,path:Nf(b),mode:xQ(c),hash:h})}break;case"patch":case"mode change":B=d||s;break;default:de.assertNever(I);break}B&&o&&a&&o!==a&&e.push({type:"mode change",semverExclusivity:i,path:Nf(B),oldMode:xQ(o),newMode:xQ(a)}),B&&m&&m.length&&e.push({type:"patch",semverExclusivity:i,path:Nf(B),hunks:m,beforeHash:f,afterHash:h})}if(e.length===0)throw new Error("Unable to parse patch file: No changes found. Make sure the patch is a valid UTF8 encoded string");return e}function xQ(t){let e=parseInt(t,8)&511;if(e!==c_e&&e!==u_e)throw new Error(`Unexpected file mode string: ${t}`);return e}function kQ(t){let e=t.split(/\n/g);return e[e.length-1]===""&&e.pop(),d_e(p_e(e))}function h_e(t){let e=0,r=0;for(let{type:i,lines:n}of t.parts)switch(i){case Lr.Context:r+=n.length,e+=n.length;break;case Lr.Deletion:e+=n.length;break;case Lr.Insertion:r+=n.length;break;default:de.assertNever(i);break}if(e!==t.header.original.length||r!==t.header.patched.length){let i=n=>n<0?n:`+${n}`;throw new Error(`hunk header integrity check failed (expected @@ ${i(t.header.original.length)} ${i(t.header.patched.length)} @@, got @@ ${i(e)} ${i(r)} @@)`)}}async function Lf(t,e,r){let i=await t.lstatPromise(e),n=await r();if(typeof n!="undefined"&&(e=n),t.lutimesPromise)await t.lutimesPromise(e,i.atime,i.mtime);else if(!i.isSymbolicLink())await t.utimesPromise(e,i.atime,i.mtime);else throw new Error("Cannot preserve the time values of a symlink")}async function PQ(t,{baseFs:e=new Wt,dryRun:r=!1,version:i=null}={}){for(let n of t)if(!(n.semverExclusivity!==null&&i!==null&&!qt.satisfiesWithPrereleases(i,n.semverExclusivity)))switch(n.type){case"file deletion":if(r){if(!e.existsSync(n.path))throw new Error(`Trying to delete a file that doesn't exist: ${n.path}`)}else await Lf(e,v.dirname(n.path),async()=>{await e.unlinkPromise(n.path)});break;case"rename":if(r){if(!e.existsSync(n.fromPath))throw new Error(`Trying to move a file that doesn't exist: ${n.fromPath}`)}else await Lf(e,v.dirname(n.fromPath),async()=>{await Lf(e,v.dirname(n.toPath),async()=>{await Lf(e,n.fromPath,async()=>(await e.movePromise(n.fromPath,n.toPath),n.toPath))})});break;case"file creation":if(r){if(e.existsSync(n.path))throw new Error(`Trying to create a file that already exists: ${n.path}`)}else{let s=n.hunk?n.hunk.parts[0].lines.join(` +`)+(n.hunk.parts[0].noNewlineAtEndOfFile?"":` +`):"";await e.mkdirpPromise(v.dirname(n.path),{chmod:493,utimes:[mr.SAFE_TIME,mr.SAFE_TIME]}),await e.writeFilePromise(n.path,s,{mode:n.mode}),await e.utimesPromise(n.path,mr.SAFE_TIME,mr.SAFE_TIME)}break;case"patch":await Lf(e,n.path,async()=>{await C_e(n,{baseFs:e,dryRun:r})});break;case"mode change":{let o=(await e.statPromise(n.path)).mode;if(qge(n.newMode)!==qge(o))continue;await Lf(e,n.path,async()=>{await e.chmodPromise(n.path,n.newMode)})}break;default:de.assertNever(n);break}}function qge(t){return(t&64)>0}function Jge(t){return t.replace(/\s+$/,"")}function m_e(t,e){return Jge(t)===Jge(e)}async function C_e({hunks:t,path:e},{baseFs:r,dryRun:i=!1}){let n=await r.statSync(e).mode,o=(await r.readFileSync(e,"utf8")).split(/\n/),a=[],l=0,c=0;for(let g of t){let f=Math.max(c,g.header.patched.start+l),h=Math.max(0,f-c),p=Math.max(0,o.length-f-g.header.original.length),d=Math.max(h,p),m=0,I=0,B=null;for(;m<=d;){if(m<=h&&(I=f-m,B=Wge(g,o,I),B!==null)){m=-m;break}if(m<=p&&(I=f+m,B=Wge(g,o,I),B!==null))break;m+=1}if(B===null)throw new vm(t.indexOf(g),g);a.push(B),l+=m,c=I+g.header.original.length}if(i)return;let u=0;for(let g of a)for(let f of g)switch(f.type){case"splice":{let h=f.index+u;o.splice(h,f.numToDelete,...f.linesToInsert),u+=f.linesToInsert.length-f.numToDelete}break;case"pop":o.pop();break;case"push":o.push(f.line);break;default:de.assertNever(f);break}await r.writeFilePromise(e,o.join(` +`),{mode:n})}function Wge(t,e,r){let i=[];for(let n of t.parts)switch(n.type){case Lr.Context:case Lr.Deletion:{for(let s of n.lines){let o=e[r];if(o==null||!m_e(o,s))return null;r+=1}n.type===Lr.Deletion&&(i.push({type:"splice",index:r-n.lines.length,numToDelete:n.lines.length,linesToInsert:[]}),n.noNewlineAtEndOfFile&&i.push({type:"push",line:""}))}break;case Lr.Insertion:i.push({type:"splice",index:r,numToDelete:0,linesToInsert:n.lines}),n.noNewlineAtEndOfFile&&i.push({type:"pop"});break;default:de.assertNever(n.type);break}return i}var E_e=/^builtin<([^>]+)>$/;function zge(t,e){let{source:r,selector:i,params:n}=S.parseRange(t);if(r===null)throw new Error("Patch locators must explicitly define their source");let s=i?i.split(/&/).map(c=>M.toPortablePath(c)):[],o=n&&typeof n.locator=="string"?S.parseLocator(n.locator):null,a=n&&typeof n.version=="string"?n.version:null,l=e(r);return{parentLocator:o,sourceItem:l,patchPaths:s,sourceVersion:a}}function Sm(t){let i=zge(t.range,S.parseDescriptor),{sourceItem:e}=i,r=qr(i,["sourceItem"]);return _(P({},r),{sourceDescriptor:e})}function xm(t){let i=zge(t.reference,S.parseLocator),{sourceItem:e}=i,r=qr(i,["sourceItem"]);return _(P({},r),{sourceLocator:e})}function Vge({parentLocator:t,sourceItem:e,patchPaths:r,sourceVersion:i,patchHash:n},s){let o=t!==null?{locator:S.stringifyLocator(t)}:{},a=typeof i!="undefined"?{version:i}:{},l=typeof n!="undefined"?{hash:n}:{};return S.makeRange({protocol:"patch:",source:s(e),selector:r.join("&"),params:P(P(P({},a),l),o)})}function I_e(t,{parentLocator:e,sourceDescriptor:r,patchPaths:i}){return S.makeLocator(t,Vge({parentLocator:e,sourceItem:r,patchPaths:i},S.stringifyDescriptor))}function xM(t,{parentLocator:e,sourcePackage:r,patchPaths:i,patchHash:n}){return S.makeLocator(t,Vge({parentLocator:e,sourceItem:r,sourceVersion:r.version,patchPaths:i,patchHash:n},S.stringifyLocator))}function _ge({onAbsolute:t,onRelative:e,onBuiltin:r},i){i.startsWith("~")&&(i=i.slice(1));let s=i.match(E_e);return s!==null?r(s[1]):v.isAbsolute(i)?t(i):e(i)}function Xge(t){let e=t.startsWith("~");return e&&(t=t.slice(1)),{optional:e}}function kM(t){return _ge({onAbsolute:()=>!1,onRelative:()=>!0,onBuiltin:()=>!1},t)}async function km(t,e,r){let i=t!==null?await r.fetcher.fetch(t,r):null,n=i&&i.localPath?{packageFs:new Ft(Se.root),prefixPath:v.relative(Se.root,i.localPath)}:i;i&&i!==n&&i.releaseFs&&i.releaseFs();let s=await de.releaseAfterUseAsync(async()=>await Promise.all(e.map(async o=>{let a=Xge(o),l=await _ge({onAbsolute:async()=>await T.readFilePromise(o,"utf8"),onRelative:async()=>{if(n===null)throw new Error("Assertion failed: The parent locator should have been fetched");return await n.packageFs.readFilePromise(v.join(n.prefixPath,o),"utf8")},onBuiltin:async c=>await r.project.configuration.firstHook(u=>u.getBuiltinPatch,r.project,c)},o);return _(P({},a),{source:l})})));for(let o of s)typeof o.source=="string"&&(o.source=o.source.replace(/\r\n?/g,` +`));return s}async function PM(t,{cache:e,project:r}){let i=r.storedPackages.get(t.locatorHash);if(typeof i=="undefined")throw new Error("Assertion failed: Expected the package to be registered");let n=r.storedChecksums,s=new ei,o=r.configuration.makeFetcher(),a=await o.fetch(t,{cache:e,project:r,fetcher:o,checksums:n,report:s}),l=await T.mktempPromise(),c=v.join(l,"source"),u=v.join(l,"user"),g=v.join(l,".yarn-patch.json");return await Promise.all([T.copyPromise(c,a.prefixPath,{baseFs:a.packageFs}),T.copyPromise(u,a.prefixPath,{baseFs:a.packageFs}),T.writeJsonPromise(g,{locator:S.stringifyLocator(t),version:i.version})]),T.detachTemp(l),u}async function DM(t,e){let r=M.fromPortablePath(t).replace(/\\/g,"/"),i=M.fromPortablePath(e).replace(/\\/g,"/"),{stdout:n,stderr:s}=await hr.execvp("git",["-c","core.safecrlf=false","diff","--src-prefix=a/","--dst-prefix=b/","--ignore-cr-at-eol","--full-index","--no-index","--text",r,i],{cwd:M.toPortablePath(process.cwd()),env:_(P({},process.env),{GIT_CONFIG_NOSYSTEM:"1",HOME:"",XDG_CONFIG_HOME:"",USERPROFILE:""})});if(s.length>0)throw new Error(`Unable to diff directories. Make sure you have a recent version of 'git' available in PATH. +The following error was reported by 'git': +${s}`);let o=r.startsWith("/")?a=>a.slice(1):a=>a;return n.replace(new RegExp(`(a|b)(${de.escapeRegExp(`/${o(r)}/`)})`,"g"),"$1/").replace(new RegExp(`(a|b)${de.escapeRegExp(`/${o(i)}/`)}`,"g"),"$1/").replace(new RegExp(de.escapeRegExp(`${r}/`),"g"),"").replace(new RegExp(de.escapeRegExp(`${i}/`),"g"),"")}function Zge(t,{configuration:e,report:r}){for(let i of t.parts)for(let n of i.lines)switch(i.type){case Lr.Context:r.reportInfo(null,` ${ue.pretty(e,n,"grey")}`);break;case Lr.Deletion:r.reportError(z.FROZEN_LOCKFILE_EXCEPTION,`- ${ue.pretty(e,n,ue.Type.REMOVED)}`);break;case Lr.Insertion:r.reportError(z.FROZEN_LOCKFILE_EXCEPTION,`+ ${ue.pretty(e,n,ue.Type.ADDED)}`);break;default:de.assertNever(i.type)}}var RM=class{supports(e,r){return!!e.reference.startsWith("patch:")}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the disk`),loader:()=>this.patchPackage(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:S.getIdentVendorPath(e),localPath:this.getLocalPath(e,r),checksum:o}}async patchPackage(e,r){let{parentLocator:i,sourceLocator:n,sourceVersion:s,patchPaths:o}=xm(e),a=await km(i,o,r),l=await T.mktempPromise(),c=v.join(l,"current.zip"),u=await r.fetcher.fetch(n,r),g=S.getIdentVendorPath(e),f=await $i(),h=new Jr(c,{libzip:f,create:!0,level:r.project.configuration.get("compressionLevel")});await de.releaseAfterUseAsync(async()=>{await h.copyPromise(g,u.prefixPath,{baseFs:u.packageFs,stableSort:!0})},u.releaseFs),h.saveAndClose();for(let{source:p,optional:d}of a){if(p===null)continue;let m=new Jr(c,{libzip:f,level:r.project.configuration.get("compressionLevel")}),I=new Ft(v.resolve(Se.root,g),{baseFs:m});try{await PQ(kQ(p),{baseFs:I,version:s})}catch(B){if(!(B instanceof vm))throw B;let b=r.project.configuration.get("enableInlineHunks"),R=!b&&!d?" (set enableInlineHunks for details)":"",H=`${S.prettyLocator(r.project.configuration,e)}: ${B.message}${R}`,L=K=>{!b||Zge(B.hunk,{configuration:r.project.configuration,report:K})};if(m.discardAndClose(),d){r.report.reportWarningOnce(z.PATCH_HUNK_FAILED,H,{reportExtra:L});continue}else throw new nt(z.PATCH_HUNK_FAILED,H,L)}m.saveAndClose()}return new Jr(c,{libzip:f,level:r.project.configuration.get("compressionLevel")})}};var y_e=3,FM=class{supportsDescriptor(e,r){return!!e.range.startsWith("patch:")}supportsLocator(e,r){return!!e.reference.startsWith("patch:")}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){let{patchPaths:n}=Sm(e);return n.every(s=>!kM(s))?e:S.bindDescriptor(e,{locator:S.stringifyLocator(r)})}getResolutionDependencies(e,r){let{sourceDescriptor:i}=Sm(e);return[i]}async getCandidates(e,r,i){if(!i.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let{parentLocator:n,sourceDescriptor:s,patchPaths:o}=Sm(e),a=await km(n,o,i.fetchOptions),l=r.get(s.descriptorHash);if(typeof l=="undefined")throw new Error("Assertion failed: The dependency should have been resolved");let c=mn.makeHash(`${y_e}`,...a.map(u=>JSON.stringify(u))).slice(0,6);return[xM(e,{parentLocator:n,sourcePackage:l,patchPaths:o,patchHash:c})]}async getSatisfying(e,r,i){return null}async resolve(e,r){let{sourceLocator:i}=xm(e),n=await r.resolver.resolve(i,r);return P(P({},n),e)}};var Pm=class extends Be{constructor(){super(...arguments);this.save=Y.Boolean("-s,--save",!1,{description:"Add the patch to your resolution entries"});this.patchFolder=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState();let n=v.resolve(this.context.cwd,M.toPortablePath(this.patchFolder)),s=v.join(n,"../source"),o=v.join(n,"../.yarn-patch.json");if(!T.existsSync(s))throw new me("The argument folder didn't get created by 'yarn patch'");let a=await DM(s,n),l=await T.readJsonPromise(o),c=S.parseLocator(l.locator,!0);if(!r.storedPackages.has(c.locatorHash))throw new me("No package found in the project for the given locator");if(!this.save){this.context.stdout.write(a);return}let u=e.get("patchFolder"),g=v.join(u,S.slugifyLocator(c));await T.mkdirPromise(u,{recursive:!0}),await T.writeFilePromise(g,a);let f=v.relative(r.cwd,g);r.topLevelWorkspace.manifest.resolutions.push({pattern:{descriptor:{fullName:S.stringifyIdent(c),description:l.version}},reference:`patch:${S.stringifyLocator(c)}#${f}`}),await r.persist()}};Pm.paths=[["patch-commit"]],Pm.usage=ye.Usage({description:"generate a patch out of a directory",details:"\n This will print a patchfile on stdout based on the diff between the folder passed in and the original version of the package. Such file is suitable for consumption with the `patch:` protocol.\n\n Only folders generated by `yarn patch` are accepted as valid input for `yarn patch-commit`.\n "});var $ge=Pm;var Dm=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.package=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState();let s=S.parseLocator(this.package);if(s.reference==="unknown"){let o=de.mapAndFilter([...r.storedPackages.values()],a=>a.identHash!==s.identHash?de.mapAndFilter.skip:S.isVirtualLocator(a)?de.mapAndFilter.skip:a);if(o.length===0)throw new me("No package found in the project for the given locator");if(o.length>1)throw new me(`Multiple candidate packages found; explicitly choose one of them (use \`yarn why \` to get more information as to who depends on them): +${o.map(a=>` +- ${S.prettyLocator(e,a)}`).join("")}`);s=o[0]}if(!r.storedPackages.has(s.locatorHash))throw new me("No package found in the project for the given locator");await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout},async o=>{let a=await PM(s,{cache:n,project:r});o.reportJson({locator:S.stringifyLocator(s),path:M.fromPortablePath(a)}),o.reportInfo(z.UNNAMED,`Package ${S.prettyLocator(e,s)} got extracted with success!`),o.reportInfo(z.UNNAMED,`You can now edit the following folder: ${ue.pretty(e,M.fromPortablePath(a),"magenta")}`),o.reportInfo(z.UNNAMED,`Once you are done run ${ue.pretty(e,`yarn patch-commit ${process.platform==="win32"?'"':""}${M.fromPortablePath(a)}${process.platform==="win32"?'"':""}`,"cyan")} and Yarn will store a patchfile based on your changes.`)})}};Dm.paths=[["patch"]],Dm.usage=ye.Usage({description:"prepare a package for patching",details:'\n This command will cause a package to be extracted in a temporary directory (under a folder named "patch-workdir"). This folder will be editable at will; running `yarn patch` inside it will then cause Yarn to generate a patchfile and register it into your top-level manifest (cf the `patch:` protocol).\n '});var efe=Dm;var w_e={configuration:{enableInlineHunks:{description:"If true, the installs will print unmatched patch hunks",type:ge.BOOLEAN,default:!1},patchFolder:{description:"Folder where the patch files must be written",type:ge.ABSOLUTE_PATH,default:"./.yarn/patches"}},commands:[$ge,efe],fetchers:[RM],resolvers:[FM]},B_e=w_e;var TM={};it(TM,{default:()=>S_e});var tfe=ie(Wp()),LM=class{supportsPackage(e,r){return r.project.configuration.get("nodeLinker")==="pnpm"}async findPackageLocation(e,r){return nfe(e,{project:r.project})}async findPackageLocator(e,r){let i=ife(),n=r.project.installersCustomData.get(i);if(!n)throw new me(`The project in ${ue.pretty(r.project.configuration,`${r.project.cwd}/package.json`,ue.Type.PATH)} doesn't seem to have been installed - running an install there might help`);let s=e.match(/(^.*\/node_modules\/(@[^/]*\/)?[^/]+)(\/.*$)/);if(s){let l=n.locatorByPath.get(s[1]);if(l)return l}let o=e,a=e;do{a=o,o=v.dirname(a);let l=n.locatorByPath.get(a);if(l)return l}while(o!==a);return null}makeInstaller(e){return new rfe(e)}},rfe=class{constructor(e){this.opts=e;this.asyncActions=new afe;this.packageLocations=new Map;this.customData={locatorByPath:new Map}}getCustomDataKey(){return ife()}attachCustomData(e){this.customData=e}async installPackage(e,r,i){switch(e.linkType){case gt.SOFT:return this.installPackageSoft(e,r,i);case gt.HARD:return this.installPackageHard(e,r,i)}throw new Error("Assertion failed: Unsupported package link type")}async installPackageSoft(e,r,i){let n=v.resolve(r.packageFs.getRealPath(),r.prefixPath);return this.packageLocations.set(e.locatorHash,n),{packageLocation:n,buildDirective:null}}async installPackageHard(e,r,i){var u;let n=nfe(e,{project:this.opts.project});this.customData.locatorByPath.set(n,S.stringifyLocator(e)),this.packageLocations.set(e.locatorHash,n),i.holdFetchResult(this.asyncActions.set(e.locatorHash,async()=>{await T.mkdirPromise(n,{recursive:!0}),await T.copyPromise(n,r.prefixPath,{baseFs:r.packageFs,overwrite:!1})}));let o=S.isVirtualLocator(e)?S.devirtualizeLocator(e):e,a={manifest:(u=await Ze.tryFind(r.prefixPath,{baseFs:r.packageFs}))!=null?u:new Ze,misc:{hasBindingGyp:Ws.hasBindingGyp(r)}},l=this.opts.project.getDependencyMeta(o,e.version),c=Ws.extractBuildScripts(e,a,l,{configuration:this.opts.project.configuration,report:this.opts.report});return{packageLocation:n,buildDirective:c}}async attachInternalDependencies(e,r){this.opts.project.configuration.get("nodeLinker")==="pnpm"&&(!ofe(e,{project:this.opts.project})||this.asyncActions.reduce(e.locatorHash,async i=>{await i;let n=this.packageLocations.get(e.locatorHash);if(typeof n=="undefined")throw new Error(`Assertion failed: Expected the package to have been registered (${S.stringifyLocator(e)})`);let s=v.join(n,wt.nodeModules);r.length>0&&await T.mkdirpPromise(s);let o=await Q_e(s),a=[];for(let[l,c]of r){let u=c;ofe(c,{project:this.opts.project})||(this.opts.report.reportWarning(z.UNNAMED,"The pnpm linker doesn't support providing different versions to workspaces' peer dependencies"),u=S.devirtualizeLocator(c));let g=this.packageLocations.get(u.locatorHash);if(typeof g=="undefined")throw new Error(`Assertion failed: Expected the package to have been registered (${S.stringifyLocator(c)})`);let f=S.stringifyIdent(l),h=v.join(s,f),p=v.relative(v.dirname(h),g),d=o.get(f);o.delete(f),a.push(Promise.resolve().then(async()=>{if(d){if(d.isSymbolicLink()&&await T.readlinkPromise(h)===p)return;await T.removePromise(h)}await T.mkdirpPromise(v.dirname(h)),process.platform=="win32"?await T.symlinkPromise(g,h,"junction"):await T.symlinkPromise(p,h)}))}for(let l of o.keys())a.push(T.removePromise(v.join(s,l)));await Promise.all(a)}))}async attachExternalDependents(e,r){throw new Error("External dependencies haven't been implemented for the pnpm linker")}async finalizeInstall(){let e=sfe(this.opts.project),r=new Set;for(let s of this.packageLocations.values())r.add(v.basename(s));let i;try{i=await T.readdirPromise(e)}catch{i=[]}let n=[];for(let s of i)r.has(s)||n.push(T.removePromise(v.join(e,s)));await Promise.all(n),await this.asyncActions.wait()}};function ife(){return JSON.stringify({name:"PnpmInstaller",version:1})}function sfe(t){return v.join(t.cwd,wt.nodeModules,".store")}function nfe(t,{project:e}){let r=S.slugifyLocator(t);return v.join(sfe(e),r)}function ofe(t,{project:e}){return!S.isVirtualLocator(t)||!e.tryWorkspaceByLocator(t)}async function Q_e(t){let e=new Map,r=[];try{r=await T.readdirPromise(t,{withFileTypes:!0})}catch(i){if(i.code!=="ENOENT")throw i}try{for(let i of r)if(!i.name.startsWith("."))if(i.name.startsWith("@"))for(let n of await T.readdirPromise(v.join(t,i.name),{withFileTypes:!0}))e.set(`${i.name}/${n.name}`,n);else e.set(i.name,i)}catch(i){if(i.code!=="ENOENT")throw i}return e}function b_e(){let t,e;return{promise:new Promise((i,n)=>{t=i,e=n}),resolve:t,reject:e}}var afe=class{constructor(){this.deferred=new Map;this.promises=new Map;this.limit=(0,tfe.default)(10)}set(e,r){let i=this.deferred.get(e);typeof i=="undefined"&&this.deferred.set(e,i=b_e());let n=this.limit(()=>r());return this.promises.set(e,n),n.then(()=>{this.promises.get(e)===n&&i.resolve()},s=>{this.promises.get(e)===n&&i.reject(s)}),i.promise}reduce(e,r){var n;let i=(n=this.promises.get(e))!=null?n:Promise.resolve();this.set(e,()=>r(i))}async wait(){await Promise.all(this.promises.values())}};var v_e={linkers:[LM]},S_e=v_e;var F0=()=>({modules:new Map([["@yarnpkg/cli",iC],["@yarnpkg/core",Fd],["@yarnpkg/fslib",ch],["@yarnpkg/libzip",Fp],["@yarnpkg/parsers",Hp],["@yarnpkg/shell",jp],["clipanion",F$(vh)],["semver",x_e],["typanion",lu],["yup",k_e],["@yarnpkg/plugin-essentials",hL],["@yarnpkg/plugin-compat",mL],["@yarnpkg/plugin-dlx",EL],["@yarnpkg/plugin-file",xL],["@yarnpkg/plugin-git",fL],["@yarnpkg/plugin-github",PL],["@yarnpkg/plugin-http",FL],["@yarnpkg/plugin-init",ML],["@yarnpkg/plugin-link",GL],["@yarnpkg/plugin-nm",mT],["@yarnpkg/plugin-npm",yM],["@yarnpkg/plugin-npm-cli",vM],["@yarnpkg/plugin-pack",CM],["@yarnpkg/plugin-patch",NM],["@yarnpkg/plugin-pnp",oT],["@yarnpkg/plugin-pnpm",TM]]),plugins:new Set(["@yarnpkg/plugin-essentials","@yarnpkg/plugin-compat","@yarnpkg/plugin-dlx","@yarnpkg/plugin-file","@yarnpkg/plugin-git","@yarnpkg/plugin-github","@yarnpkg/plugin-http","@yarnpkg/plugin-init","@yarnpkg/plugin-link","@yarnpkg/plugin-nm","@yarnpkg/plugin-npm","@yarnpkg/plugin-npm-cli","@yarnpkg/plugin-pack","@yarnpkg/plugin-patch","@yarnpkg/plugin-pnp","@yarnpkg/plugin-pnpm"])});i0({binaryVersion:Zr||"",pluginConfiguration:F0()});})(); +/*! + * buildToken + * Builds OAuth token prefix (helper function) + * + * @name buildToken + * @function + * @param {GitUrl} obj The parsed Git url object. + * @return {String} token prefix + */ +/*! + * fill-range + * + * Copyright (c) 2014-present, Jon Schlinkert. + * Licensed under the MIT License. + */ +/*! + * is-extglob + * + * Copyright (c) 2014-2016, Jon Schlinkert. + * Licensed under the MIT License. + */ +/*! + * is-glob + * + * Copyright (c) 2014-2017, Jon Schlinkert. + * Released under the MIT License. + */ +/*! + * is-number + * + * Copyright (c) 2014-present, Jon Schlinkert. + * Released under the MIT License. + */ +/*! + * is-windows + * + * Copyright © 2015-2018, Jon Schlinkert. + * Released under the MIT License. + */ +/*! + * to-regex-range + * + * Copyright (c) 2015-present, Jon Schlinkert. + * Released under the MIT License. + */ diff --git a/.yarnrc.yml b/.yarnrc.yml new file mode 100644 index 00000000..3b477710 --- /dev/null +++ b/.yarnrc.yml @@ -0,0 +1,3 @@ +nodeLinker: node-modules + +yarnPath: .yarn/releases/yarn-3.1.1.cjs diff --git a/README.md b/README.md index 148e4c46..dd6f86ac 100644 --- a/README.md +++ b/README.md @@ -2,19 +2,16 @@ [![Circle CI](https://circleci.com/gh/intercom/intercom-node.png?style=shield)](https://circleci.com/gh/intercom/intercom-node) [![npm](https://img.shields.io/npm/v/intercom-client)](https://www.npmjs.com/package/intercom-client) -![Intercom API Version](https://img.shields.io/badge/Intercom%20API%20Version-1.3-blue) +![Intercom API Version](https://img.shields.io/badge/Intercom%20API%20Version-2.4-blue) +![Typescript Supported](https://img.shields.io/badge/Typescript-Supported-lightgrey) > Official Node bindings to the [Intercom API](https://api.intercom.io/docs) ## Project Updates -### Maintenance +## Breaking changes -We're currently building a new team to provide in-depth and dedicated SDK support. - -In the meantime, we'll be operating on limited capacity, meaning all pull requests will be evaluated on a best effort basis and will be limited to critical issues. - -We'll communicate all relevant updates as we build this new team and support strategy in the coming months. +The Node SDK has been updated to support latest API version (2.4). The update also contains requested features, such like Typescript support. You can find more information on how-to migrate and what has changed in the [migration guide](https://github.com/intercom/intercom-node/wiki/Migration-guide). ## Installation @@ -22,7 +19,7 @@ We'll communicate all relevant updates as we build this new team and support str yarn add intercom-client ``` -**This client is intended for server side use only. Please use the [Intercom Javascript SDK](https://developers.intercom.com/v2.0/docs/intercom-javascript) for client-side operations.** +**This client is intended for server side use only. Please use the [Intercom Javascript SDK](https://developers.intercom.com/v2.4/docs/intercom-javascript) for client-side operations.** ## Testing @@ -35,590 +32,1052 @@ yarn test Compile using babel: ```bash -yarn gulp babel +yarn prepublish ``` -Require Intercom: +## Usage -```node -var Intercom = require('./dist/index'); +Import Intercom: + +```typescript +import { Client } from './dist/index'; ``` -## Usage +Create a client using access tokens: + +```typescript +const client = new Client({ tokenAuth: { token: 'my_token' } }); +``` + +## Request Options -Require Intercom: +This client library also supports passing in [`request` options](https://github.com/axios/axios#request-config): -```node -var Intercom = require('intercom-client'); +```typescript +const client = new Client({ tokenAuth: { token: 'my_token' } }); +client.useRequestOpts({ + baseURL: 'http://local.test-server.com', +}); ``` -Create a client using access tokens: +Note that certain request options (such as `json`, and certain `headers` names cannot be overriden). -```node -var client = new Intercom.Client({ token: 'my_token' }); +### Setting the API version + +We version our API (see the "Choose Version" section of the [API & Webhooks Reference](https://developers.intercom.com/intercom-api-reference/reference) for details). You can specify which version of the API to use when performing API requests using request options: + +```typescript +const client = new Client({ tokenAuth: { token: 'my_token' } }); +client.useRequestOpts({ + headers: { + 'Intercom-Version': 2.4, + }, +}); ``` -## Callbacks +## Examples -This client library supports two kinds of callbacks: +### Admins -```node -client.users.list(function (d) { - // d is the response from the server +#### [Retrieve admin](https://developers.intercom.com/intercom-api-reference/reference/view-an-admin) + +```typescript +const admin = await client.admins.find({ id: '123' }); +``` + +#### [Set Admin away](https://developers.intercom.com/intercom-api-reference/reference/set-admin-away-mode) + +```typescript +await client.admins.away({ + adminId: '123', + enableAwayMode: true, + enableReassignMode: false, }); ``` -Or +#### [List all activity logs](https://developers.intercom.com/intercom-api-reference/reference/view-admin-activity-logs) -```node -client.users.list(function (err, d) { - // err is an error response object, or null - // d is a successful response object, or null +```typescript +await client.admins.listAllActivityLogs({ + before: new Date('Fri, 17 Dec 2021 18:02:18 GMT');, + after: new Date('Fri, 17 Dec 2021 18:02:18 GMT');, }); ``` -## Promises +#### [List all admins](https://developers.intercom.com/intercom-api-reference/reference/list-admins) + +```typescript +const admins = await client.admins.list(); +``` -This client library also supports using Promises instead of callbacks: +### Articles -```node -client.users.create({ email: 'foo@bar.com' }).then(function (r) { - // ... +#### [Create an article](https://developers.intercom.com/intercom-api-reference/reference/create-an-article) + +```typescript +const article = await client.articles.create({ + title: 'Thanks for everything', + description: 'English description', + body: '

This is the body in html

', + authorId: 1, + state: 'published', + parentId: 1, + parentType: 'collection', + translatedContent: { + fr: { + title: 'Allez les verts', + description: 'French description', + body: '

French body in html

', + author_id: 1, + state: 'published', + }, + }, }); ``` -## Request Options +#### [Retrieve an article](https://developers.intercom.com/intercom-api-reference/reference/retrieve-an-article) + +```typescript +const response = await client.articles.find({ id: '123' }); +``` + +#### [Update an article](https://developers.intercom.com/intercom-api-reference/reference/update-an-article) + +```typescript +const article = await client.articles.update({ + id: '123', + title: 'Thanks for everything', + description: 'English description', + body: '

This is the body in html

', + authorId: 1, + state: 'published', + parentId: 1, + parentType: 'collection', + translatedContent: { + fr: { + title: 'Allez les verts', + description: 'French description', + body: '

French body in html

', + author_id: 1, + state: 'published', + }, + }, +}); +``` -This client library also supports passing in [`request` options](https://github.com/request/request#requestoptions-callback): +#### [Delete an article](https://developers.intercom.com/intercom-api-reference/reference/delete-an-article) -```node -var client = new Intercom.Client({ token: 'my_token' }); -client.useRequestOpts({ - baseUrl: 'http://local.test-server.com', - // Uses the forever-agent / http(s).Agent({keepAlive:true}) - forever: true +```typescript +await client.articles.delete({ id: '123' }); +``` + +#### [List all articles](https://developers.intercom.com/intercom-api-reference/reference/list-all-articles) + +```typescript +const response = await client.articles.list({ + page: 3, + perPage: 12, }); ``` -Note that certain request options (such as `json`, and certain `headers` names cannot be overriden). +### Companies -### Setting the API version +#### [Create a company](https://developers.intercom.com/intercom-api-reference/reference/create-or-update-company) -We version our API (see the "Choose Version" section of the [API & Webhooks Reference](https://developers.intercom.com/intercom-api-reference/reference) for details). You can specify which version of the API to use when performing API requests using request options: +```typescript +const company = await client.companies.create({ + createdAt: dateToUnixTimestamp(new Date()), + companyId: '46029', + name: 'BestCompanyInc.', + monthlySpend: 9001, + plan: '1. Get pizzaid', + size: 62049, + website: 'http://the-best.one', + industry: 'The Best One', + customAttributes: {}, +}); +``` -```node -var client = new Intercom.Client({ token: 'my_token' }); -client.useRequestOpts({ - headers: { - 'Intercom-Version': 1.2 - } +#### [Update a company](https://developers.intercom.com/intercom-api-reference/reference/update-a-company) + +```typescript +const company = await client.companies.create({ + createdAt: dateToUnixTimestamp(new Date()), + companyId: '46029', + name: 'BestCompanyInc.', + monthlySpend: 9001, + plan: '1. Get pizzaid', + size: 62049, + website: 'http://the-best.one', + industry: 'The Best One', + customAttributes: {}, }); ``` -## Users +#### [Retrieve a company](https://developers.intercom.com/intercom-api-reference/reference/view-a-company) -```node -// Create a user -client.users.create({ - email: 'jayne@serenity.io', - custom_attributes: { - foo: 'bar' - } -}, callback); - -// Update a user -client.users.update({ - email: 'jayne@serenity.io', - custom_attributes: { - foo: 'bar' - } -}, callback); +##### By id + +```typescript +const company = await client.companies.find({ + companyId: 123, +}); ``` -```node -// Create/update a user with custom attributes -client.users.create({ email: 'jayne@serenity.io', custom_attributes: { invited_friend: true } }, callback); +##### By name + +```typescript +const company = await client.companies.find({ + name: 'bruh moment inc.', +}); ``` -```node -// List users -client.users.list(callback); +#### [Delete a company](https://developers.intercom.com/intercom-api-reference/reference/delete-a-company) + +```typescript +const company = await client.companies.delete({ + id: 62049, +}); ``` -```node -// List users by tag or segment -client.users.listBy({ tag_id: 'haven' }, callback); +#### [List all companies](https://developers.intercom.com/intercom-api-reference/reference/list-companies) + +##### With pagination + +```typescript +const companies = await client.companies.list({ + page: 1, + perPage: 35, + order: Order.DESC, +}); ``` -```node -// Scroll through users list -client.users.scroll.each({}, function(res) { - // if you return a promise from your callback, the client will only scroll - // after this promise has resolved - new Bluebird((resolve) => { - setTimeout(() => { - console.log(res.body.users.length); - // Your custom logic - resolve(); - }, 500) - }) +##### With TagId and SegmentId + +```typescript +const companies = await client.companies.list({ + tagId: '1234', + segmentId: '4567', }); +``` + +#### [Scroll over companies](https://developers.intercom.com/intercom-api-reference/reference/iterating-over-all-companies) + +##### Using infinite scroll +```typescript +const companies = await client.companies.scroll.each({}); ``` -```node -// Find user by id -client.users.find({ id: '55b9eaf' }, callback); +##### Using manual scroll + +```typescript +const companies = await client.companies.scroll.next({ + scrollParam: '123_soleil', +}); +``` -// Find user by user_id -client.users.find({ user_id: 'foobar' }, callback); +#### [Attach a contact](https://developers.intercom.com/intercom-api-reference/reference/attach-contact-to-company) -// Find user by email -client.users.find({ email: 'jayne@serenity.io' }, callback); +```typescript +const response = await client.companies.attachContact({ + contactId: '123', + companyId: '234', +}); ``` -```node -// Archive user by id (https://developers.intercom.com/intercom-api-reference/reference#archive-a-user) -client.users.archive({ id: '1234' }, callback); +#### [Detach a contact](https://developers.intercom.com/intercom-api-reference/reference/detach-contact-from-company) + +```typescript +const response = await client.companies.detachContact({ + contactId: '123', + companyId: '234', +}); ``` -```node -// Permanently delete a user by id (https://developers.intercom.com/intercom-api-reference/reference#delete-users) -const intercomUserId = '123' -client.users.requestPermanentDeletion(intercomUserId, callback); +#### [List attached contacts](https://developers.intercom.com/intercom-api-reference/reference/list-company-contacts) + +```typescript +const response = await client.companies.listAttachedContacts({ + companyId: '123', + page: 1, + perPage: 15, +}); ``` -```node -// Permanently delete a user by id in params -client.users.requestPermanentDeletionByParams({ id: '55b9eaf' }, callback); +#### [List attached segments](https://developers.intercom.com/intercom-api-reference/reference/list-attached-segments-1) -// Permanently delete a user by user_id -client.users.requestPermanentDeletionByParams({ user_id: 'foobar' }, callback); +```typescript +const response = await client.companies.listAttachedSegments({ + companyId: '123', +}); +``` + +### Contacts + +#### [Create Contact](https://developers.intercom.com/intercom-api-reference/reference/create-contact) -// Permanently delete a user by email -client.users.requestPermanentDeletionByParams({ email: 'jayne@serenity.io' }, callback); +##### With User Role + +```typescript +const user = await client.contacts.createUser({ + externalId: '536e564f316c83104c000020', + phone: '+48370044567', + name: 'Niko Bellic', + avatar: 'https://nico-from-gta-iv.com/lets_go_bowling.jpg', + signedUpAt: 1638203719, + lastSeenAt: 1638203720, + ownerId: '536e564f316c83104c000021', + isUnsubscribedFromEmails: true, +}); ``` -## Leads +##### With Lead Role -```node -// Create a contact -client.leads.create(function (r) { - console.log(r); +```typescript +const lead = await client.contacts.createLead({ + phone: '+48370044567', + name: 'Roman Bellic', + avatar: 'https://nico-from-gta-iv.com/lets_go_bowling_yey.jpg', + signedUpAt: 1638203719, + lastSeenAt: 1638203720, + ownerId: '536e564f316c83104c000021', + isUnsubscribedFromEmails: true, }); +``` -// Create a contact with attributes -client.leads.create({ email: 'jayne@serenity.io' }, function (r) { - console.log(r); +#### [Retrieve a Contact](https://developers.intercom.com/intercom-api-reference/reference/get-contact) + +```typescript +const response = await client.contacts.find({ id: '123' }); +``` + +#### [Update a Contact](https://developers.intercom.com/intercom-api-reference/reference/update-contact) + +```typescript +const response = await client.contacts.update({ + id: '123', + role: Role.USER, + name: 'Roman The Bowling Fan', + customAttributes: { + callBrother: "Hey Niko, it's me – Roman. Let's go bowling!", + }, }); ``` -```node -// Update a contact by id -client.leads.update({ id: '5435345', email: 'wash@serenity.io' }, callback); +#### [Delete a Contact](https://developers.intercom.com/intercom-api-reference/reference/delete-contact) + +```typescript +const response = await client.contacts.delete({ id: '123' }); ``` -```node -// List contacts -client.leads.list(callback); +#### [Archive a Contact](https://developers.intercom.com/intercom-api-reference/reference/archive-a-contact) + +```typescript +const response = await client.contacts.archive({ id: '123' }); ``` -```node -// Scroll through contacts list -client.leads.scroll.each({}, function(res) { - // if you return a promise from your callback, the client will only scroll - // after this promise has resolved - new Bluebird((resolve) => { - setTimeout(() => { - console.log(res.body.contacts.length); - // Your custom logic - resolve(); - }, 500) - }) +#### [Unarchive a Contact](https://developers.intercom.com/intercom-api-reference/reference/unarchive-a-contact) + +```typescript +const response = await client.contacts.unarchive({ id: '123' }); +``` + +#### [Merge two Contacts](https://developers.intercom.com/intercom-api-reference/reference/merge-contact) + +```typescript +const response = await client.contacts.mergeLeadInUser({ + leadId: '123', + userId: '234', }); ``` -```node -// List contacts by email -client.leads.listBy({ email: 'wash@serenity.io' }, callback); +#### [Search for contacts](https://developers.intercom.com/intercom-api-reference/reference/search-for-contacts) + +```typescript +const response = await client.contacts.search({ + data: { + query: { + operator: Operators.AND, + value: [ + { + operator: Operators.AND, + value: [ + { + field: 'updated_at', + operator: Operators.GREATER_THAN, + value: 1560436650, + }, + { + field: 'conversation_rating.rating', + operator: Operators.EQUALS, + value: 1, + }, + ], + }, + { + operator: Operators.OR, + value: [ + { + field: 'updated_at', + operator: Operators.GREATER_THAN, + value: 1560436650, + }, + { + field: 'conversation_rating.rating', + operator: Operators.EQUALS, + value: 2, + }, + ], + }, + ], + }, + pagination: { + per_page: 5, + starting_after: + 'WzE2MzU4NjA2NDgwMDAsIjYxODJiNjJlNDM4YjdhM2EwMWE4YWYxNSIsMl0=', + }, + sort: { field: 'name', order: SearchContactOrderBy.ASC }, + }, +}); ``` -```node -// Find contact by id -client.leads.find({ id: '5342423' }, callback); +#### [List all Contacts](https://developers.intercom.com/intercom-api-reference/reference/list-contacts) + +##### With cursor + +```typescript +const response = await client.contacts.list({ + perPage: 5, + startingAfter: + 'WzE2MzU3NzU4NjkwMDAsIjYxODJiNjJhMDMwZTk4OTBkZWU4NGM5YiIsMl0=', +}); ``` -```node -// Delete contact by id -client.leads.delete({ id: '5342423' }, callback); +##### Without a cursor + +```typescript +const response = await client.contacts.list(); ``` -```node -// Convert Leads into Users -var conversion = { - contact: { user_id: '1234-5678-9876' }, - user: { email: 'mal@serenity.io' } -}; -client.leads.convert(conversion, callback); +#### [List attached companies](https://developers.intercom.com/intercom-api-reference/reference/list-companies-of-contact) + +```typescript +const response = await client.contacts.listAttachedCompanies({ + id: '123', + perPage: 5, + page: 1, +}); ``` -## Customers +#### [List attached tags](https://developers.intercom.com/intercom-api-reference/reference/list-tags-of-contact) -```node -// Search for customers -client.customers.search({ - query: { field: 'name', operator: '=', name: 'Alice'}, - sort: { field: 'name', order: 'ascending'}, - pagination: { per_page: 10 } -}, callback); +```typescript +const response = await client.contacts.listAttachedTags({ id: '123' }); ``` -## Visitors +#### [List attached segments](https://developers.intercom.com/intercom-api-reference/reference/list-attached-segments) -```node -// Update a visitor by id -client.visitors.update({ id: '5435345', email: 'wash@serenity.io' }, callback); +```typescript +const response = await client.contacts.listAttachedSegments({ id: '123' }); ``` -```node -// Find visitor by id or user_id -client.visitors.find({ id: '5342423' }, callback); -client.visitors.find({ user_id: '5b868511-ca3b-4eac-8d26-cfd82a83ac76' }, callback); +#### [List attached email subscriptions](https://developers.intercom.com/intercom-api-reference/reference/list-attached-email-subscriptions) + +```typescript +const response = await client.contacts.listAttachedEmailSubscriptions({ + id: '123', +}); ``` -```node -// Delete visitor by id -client.visitors.delete({ id: '5342423' }, callback); +### Conversations + +#### [Create a conversation](https://developers.intercom.com/intercom-api-reference/reference/create-a-conversation) + +```typescript +const response = await client.conversations.create({ + userId: '123', + body: 'Hello darkness my old friend', +}); ``` -```node -// Convert visitors into Users -var conversion = { - visitor: { user_id: '1234-5678-9876' }, - user: { email: 'mal@serenity.io' }, - type: "user" -}; -client.visitors.convert(conversion, callback); +#### [Retrieve a conversation](https://developers.intercom.com/intercom-api-reference/reference/retrieve-a-conversation) + +##### Formatted text + +```typescript +const response = await client.conversations.find({ + id: '123', +}); ``` -```node -// Convert visitors into Lead -var conversion = { - visitor: { user_id: '1234-5678-9876' }, - type: "lead" -}; -client.visitors.convert(conversion, callback); +##### As plain text + +```typescript +const response = await client.conversations.find({ + id: '123', + inPlainText: true, +}); ``` -## Companies +#### [Update a conversation](https://developers.intercom.com/intercom-api-reference/reference/update-a-conversation) -```node -// Create/update a company -client.companies.create({ company_id: '1234', name: 'serenity' }, function (r) { - console.log(r); +```typescript +const response = await client.conversations.update({ + id, + markRead: true, + customAttributes: { + anything: 'you want', + }, }); ``` -```node -// List companies -client.companies.list(callback); +#### [Reply to a conversation](https://developers.intercom.com/intercom-api-reference/reference/reply-to-a-conversation) + +##### By id + +###### As user + +```typescript +const response = await client.conversations.replyByIdAsUser({ + id: '098', + body: 'blablbalba', + intercomUserId: '123', + attachmentUrls: '345', +}); ``` -```node -// List companies by tag or segment -client.companies.listBy({ tag_id: 'haven' }, callback); +###### As admin + +```typescript +const response = await client.conversations.replyByIdAsAdmin({ + id: '098', + adminId: '458', + messageType: ReplyToConversationMessageType.NOTE, + body: 'Bee C', + attachmentUrls: ['https://site.org/bebra.jpg'], +}); ``` -```node -// Scroll through companies list -client.companies.scroll.each({}, function(res) { - // if you return a promise from your callback, the client will only scroll - // after this promise has resolved - new Bluebird((resolve) => { - setTimeout(() => { - console.log(res.body.companies.length); - // Your custom logic - resolve(); - }, 500) - }) +##### By last conversation + +###### As user + +```typescript +const response = await client.conversations.replyByLastAsUser({ + body: 'blablbalba', + intercomUserId: '123', + attachmentUrls: '345', }); ``` -```node -// Find company by id -client.companies.find({ id: '1234' }, callback); +###### As admin + +```typescript +const response = await client.conversations.replyByLastAsAdmin({ + adminId: '458', + messageType: ReplyToConversationMessageType.NOTE, + body: 'Bee C', + attachmentUrls: ['https://site.org/bebra.jpg'], +}); ``` -```node -// List company users by id or company_id -client.companies.listUsers({ id: '1234' }, callback); -client.companies.listUsers({ company_id: '1234' }, callback); +#### [Assign a conversation](https://developers.intercom.com/intercom-api-reference/reference/assign-a-conversation) + +##### As team without assignment rules + +```typescript +const response = await client.conversations.assign({ + id: '123', + type: AssignToConversationUserType.TEAM, + adminId: '456', + assigneeId: '789', + body: 'blablbalba', +}); ``` -## Events +##### As team with assignment rules -Note: events will work when identified by 'email'. The `event_name` and `created_at` params are both required. Either `user_id` OR `email` is required. +```typescript +const response = await client.conversations.assign({ + id: '123', + withRunningAssignmentRules: true, +}); +``` -```node -// Create a event -client.events.create({ - event_name: 'Foo', - created_at: 1439826340, - user_id: 'bar', - metadata: { type: 'baz' } -}, function (d) { - console.log(d); +#### [Snooze a conversation](https://developers.intercom.com/intercom-api-reference/reference/snooze-a-conversation) + +```typescript +const response = await client.conversations.snooze({ + id: '123', + adminId: '234', + snoozedUntil: '1501512795', }); ``` -```node -// List events by user -client.events.listBy({ - type: 'user', - user_id: 'bar' -}, callback); +#### [Close a conversation](https://developers.intercom.com/intercom-api-reference/reference/close-a-conversation) + +```typescript +const response = await client.conversations.close({ + id: '123', + adminId: '456', + body: "That's it...", +}); ``` -## Counts +#### [Open a conversation](https://developers.intercom.com/intercom-api-reference/reference/open-a-conversation) -```node -client.counts.appCounts(callback); +```typescript +const response = await client.conversations.open({ + id: '123', + adminId: '234', +}); +``` -client.counts.conversationCounts(callback); +#### [Attach a contact to group conversation](https://developers.intercom.com/intercom-api-reference/reference/adding-to-group-conversations-as-admin) -client.counts.conversationAdminCounts(callback); +##### As admin, using intercomUserid -client.counts.userTagCounts(callback); +```typescript +const response = await client.conversations.attachContactAsAdmin({ + id: '123', + adminId: '234', + customer: { + intercomUserId: '456', + }, +}); +``` -client.counts.userSegmentCounts(callback); +##### As contact, using intercomUserid -client.counts.companyTagCounts(callback); +```typescript +const response = await client.conversations.attachContactAsAdmin({ + id: '123', + userId: '234', + customer: { + intercomUserId: '456', + }, +}); +``` -client.counts.companySegmentCounts(callback); +#### [Delete a contact from group conversation as admin](https://developers.intercom.com/intercom-api-reference/reference/deleting-from-group-conversations) + +```typescript +const response = await client.conversations.detachContactAsAdmin({ + conversationId: '123', + contactId: '456', + adminId: '789', +}); +``` -client.counts.companyUserCounts(callback); +#### [Search for conversations](https://developers.intercom.com/intercom-api-reference/reference/search-for-conversations) + +```typescript +const response = await client.conversations.search({ + data: { + query: { + operator: Operators.AND, + value: [ + { + operator: Operators.AND, + value: [ + { + field: 'updated_at', + operator: Operators.GREATER_THAN, + value: 1560436650, + }, + { + field: 'conversation_rating.rating', + operator: Operators.EQUALS, + value: 1, + }, + ], + }, + { + operator: Operators.OR, + value: [ + { + field: 'updated_at', + operator: Operators.GREATER_THAN, + value: 1560436650, + }, + { + field: 'conversation_rating.rating', + operator: Operators.EQUALS, + value: 2, + }, + ], + }, + ], + }, + pagination: { + per_page: 5, + starting_after: + 'WzE2MzU4NjA2NDgwMDAsIjYxODJiNjJlNDM4YjdhM2EwMWE4YWYxNSIsMl0=', + }, + sort: { + field: 'name', + order: SearchConversationOrderBy.DESC, + }, + }, +}); ``` -## Admins +#### [List all conversations](https://developers.intercom.com/intercom-api-reference/reference/list-conversations) -```node -// List admins -client.admins.list(callback); +```typescript +const response = await client.conversations.list({ + query: { + order: Order.DESC, + sort: SortBy.UpdatedAt, + page: 1, + perPage: 10, + }, +}); ``` -```node -// Find current admin (only works with OAuth tokens) -client.admins.me(callback); +#### [Redact a conversation](https://developers.intercom.com/intercom-api-reference/reference/redact-a-conversation-part) + +```typescript +const response = await client.conversations.redactConversationPart({ + type: RedactConversationPartType.CONVERSATION_PART, + conversationId: '123', + conversationPartId: '456', +}); ``` -```node -// Find admin by ID -client.admins.find('123456789', callback); +### Data Attributes + +#### [Create Data Attribute](https://developers.intercom.com/intercom-api-reference/reference/create-data-attributes) + +```typescript +const response = await client.dataAttributes.create({ + name: 'list_cda', + model: ModelType.CONTACT, + dataType: DataType.STRING, + description: 'You are either alive or dead', + options: [{ value: 'alive' }, { value: 'dead' }], +}); ``` -```node -// Update admin away mode and reassign settings -client.admins.away('123456789', {'away_mode_enabled': true, 'away_mode_reassign': false}, callback); +#### [Update Data Attribute](https://developers.intercom.com/intercom-api-reference/reference/update-data-attributes) + +```typescript +const response = await client.dataAttributes.update({ + id: '123', + description: 'You are either alive or dead', + options: [{ value: 'alive' }, { value: 'dead' }], + archived: true, +}); ``` -## Tags +#### [List all Data Attributes](https://developers.intercom.com/intercom-api-reference/reference/list-data-attributes) -```node -// Create a tag -client.tags.create({ name: 'haven' }, callback); +```typescript +const response = await client.dataAttributes.list({ + model: ModelType.CONTACT, + includeArchived: true, +}); ``` -```node -// Tag a user by id -client.tags.tag({ name: 'haven', users: [{ id: '54645654' }] }, callback); +### Events + +#### [Submit a data event](https://developers.intercom.com/intercom-api-reference/reference/list-data-attributes) + +```typescript +const response = await client.events.create({ + eventName: 'placed-order', + createdAt: 1389913941, + userId: 'f4ca124298', + metadata: { + order_date: 1392036272, + stripe_invoice: 'inv_3434343434', + order_number: { + value: '3434-3434', + url: 'https://example.org/orders/3434-3434', + }, + price: { + currency: 'usd', + amount: 2999, + }, + }, +}); ``` -```node -// Tag a company by id -client.tags.tag({ name: 'haven', companies: [{ id: '54645654' }] }, callback); +#### [List all data events](https://developers.intercom.com/intercom-api-reference/reference/list-user-events) + +```typescript +const response = await client.events.listBy({ + userId: '1234', + perPage: 2, + summary: true, + email: 'i_love_memes@gmail.com', +}); ``` -```node -// Untag a user by id -client.tags.untag({ name: 'haven', users: [{ id: '5345342' }] }, callback); +### Help Center - Collections + +#### [Create a collection](https://developers.intercom.com/intercom-api-reference/reference/create-a-collection) + +```typescript +const collection = await client.helpCenter.collections.create({ + name: 'Thanks for everything', + description: 'English description', + translatedContent: { + fr: { + name: 'Allez les verts', + description: 'French description', + }, + }, +}); ``` -```node -// List tags -client.tags.list(callback); +#### [Retrieve a collection](https://developers.intercom.com/intercom-api-reference/reference/retrieve-a-collection) + +```typescript +const response = await client.helpCenter.collections.find({ id: '123' }); ``` -```node -// Delete a tag by id -client.tags.delete({ id: '130963' }, callback); +#### [Update a collection](https://developers.intercom.com/intercom-api-reference/reference/update-a-collection) + +```typescript +const article = await client.helpCenter.collections.update({ + id: '123', + name: 'Thanks for everything', + description: 'English description', + translated_content: { + fr: { + name: 'Allez les verts', + description: 'French description', + }, + }, +}); ``` -## Segments +#### [Delete a collection](https://developers.intercom.com/intercom-api-reference/reference/delete-a-collection) -```node -// List segments -client.segments.list(callback); +```typescript +await client.helpCenter.collections.delete({ + id: '123', +}); ``` -```node -// Find segment by id -client.segments.find({ id: '55719a4a' }, callback); +#### [List all collections](https://developers.intercom.com/intercom-api-reference/reference/list-all-collections) + +```typescript +const response = client.helpCenter.collections.list({ + page: 3, + perPage: 12, +}); ``` -## Messages +## Help Center - Sections -```node -// Admin initiated messages: -// Sending an email to a User -var message = { - message_type: "email", - subject: "Hey", - body: "Ponies, cute small horses or something more sinister?", - template: "plain", - from: { - type: "admin", - id: "21599" - }, - to: { - type: "user", - id: "55c1ce1def857c31f80001af" - } -} - -client.messages.create(message, callback); +#### [Create a section](https://developers.intercom.com/intercom-api-reference/reference/create-a-section) + +```typescript +const collection = await client.helpCenter.sections.create({ + name: 'Thanks for everything', + parent_id: '1234', + translatedContent: { + fr: { + name: 'Allez les verts', + description: 'French description', + }, + }, +}); ``` -```node -// Creating a user-initiated message: -var message = { - from: { - type: "user", - id: "55c1ce1def857c31f80001af" - }, - body: "Howdy" -} +#### [Retrieve a section](https://developers.intercom.com/intercom-api-reference/reference/retrieve-a-section) -client.messages.create(message, callback); +```typescript +const response = await client.helpCenter.sections.find({ id: '123' }); ``` -## Conversations +#### [Update a section](https://developers.intercom.com/intercom-api-reference/reference/update-a-section) -Listing conversations ([documentation](https://developers.intercom.com/intercom-api-reference/reference#list-conversations)): +```typescript +const article = await client.helpCenter.sections.update({ + id: '123', + name: 'Thanks for everything', + parent_id: '456', + translated_content: { + fr: { + name: 'Allez les verts', + description: 'French description', + }, + }, +}); +``` -```node -client.conversations.list({ type: 'admin', admin_id: 21599 }, callback); +#### [Delete a section](https://developers.intercom.com/intercom-api-reference/reference/delete-a-section) + +```typescript +await client.helpCenter.sections.delete({ + id: '123', +}); ``` -```node -// Fetch a conversation -client.conversations.find({ id: '1062682196' }, callback); +#### [List all sections](https://developers.intercom.com/intercom-api-reference/reference/list-all-sections) + +```typescript +const response = client.helpCenter.sections.list({ + page: 3, + perPage: 12, +}); ``` -```node -// Reply to a conversation -var reply = { - id: '1039067180', - intercom_user_id: '55b26822ce97179e52001334', - body: 'Some reply :)', - type: 'user', - message_type: 'comment' -}; - -client.conversations.reply(reply, callback); - -// Reply to a conversation with attachments -var reply = { - id: '1039067180', - intercom_user_id: '55b26822ce97179e52001334', - body: 'Some reply :)', - type: 'user', - message_type: 'comment', - attachment_urls: ['http://www.example.com/myattachment.jpg'] -}; - -client.conversations.reply(reply, callback); +### Messages + +#### [Create a message](https://developers.intercom.com/intercom-api-reference/reference/admin-initiated-conversation) + +```typescript +const response = await client.messages.create({ + messageType: 'email', + subject: 'This is our demand now', + body: 'Destroy ponies', + template: 'plain', + from: { + type: 'admin', + id: '394051', + }, + to: { + type: 'user', + id: '536e564f316c83104c000020', + }, +}); ``` -```node -// Assign a conversation to an admin -var assignment = { - id: '13879167940', - type: 'admin', - admin_id: '1309092', - assignee_id: '1723471', - message_type: 'assignment' -}; +### Segments + +#### [Retrieve a segment](https://developers.intercom.com/intercom-api-reference/reference/view-a-segment) -client.conversations.reply(assignment, callback); +```typescript +const response = await client.segments.find({ + id: '123', + includeCount: true, +}); +``` -// Assign a conversation to unassigned -var assignment = { - id: '13879167940', - type: 'admin', - admin_id: '1309092', - assignee_id: '0', - message_type: 'assignment' -} +#### [List all segments](https://developers.intercom.com/intercom-api-reference/reference/list-segments) -client.conversations.reply(assignment, callback); +```typescript +const response = await client.segments.list({ + includeCount: true, +}); ``` -```node -// Mark a conversation as read -client.conversations.markAsRead({ id: '1039067180' }, callback); +### Tags + +#### [Create or update a tag](https://developers.intercom.com/intercom-api-reference/reference/create-and-update-tags) + +##### Create + +```typescript +const response = await client.tags.create({ name: 'haven' }); ``` -## Notes +##### Update -```node -// Create a note -var note = { - admin_id: 21599, - body: 'Hello notes!', - user: { - id: '55b26822ce97179e52001334' - } -}; +```typescript +const response = await client.tags.update({ id: '123', name: 'haven' }); +``` + +#### [Delete a tag](https://developers.intercom.com/intercom-api-reference/reference/delete-a-tag) -client.notes.create(note, callback); +```typescript +const response = await client.tags.delete({ id: 'baz' }); ``` -```node -// List notes by user -client.notes.list({ email: 'bob@intercom.io' }, callback); +#### [Attach a contact](https://developers.intercom.com/intercom-api-reference/reference/tag-contact) + +```typescript +const response = await client.tags.tagContact({ + contactId: '123', + tagId: '234', +}); ``` -```node -//Fetch a note -client.notes.find({ id: '3342887' }, callback); +#### [Attach a conversation](https://developers.intercom.com/intercom-api-reference/reference/attach-a-tag-to-a-conversation) + +```typescript +const response = await client.tags.tagConversation({ + conversationId: '123', + tagId: '456', + adminId: '789', +}); ``` -## Pagination +#### [Tag companies](https://developers.intercom.com/intercom-api-reference/reference/tag-companies) -When listing, the Intercom API may return a pagination object: +```typescript +const response = await client.tags.tagCompanies({ + tagName: 'gutenTag', + companiesIds: ['123', '234', '456'], +}); +``` -```json -{ - "pages": { - "next": "..." - } -} +#### [Untag companies](https://developers.intercom.com/intercom-api-reference/reference/untag-companies) + +```typescript +const response = await client.tags.tagCompanies({ + tagName: 'gutenTag', + companiesIds: ['123', '234', '456'], +}); ``` -You can grab the next page of results using the client: +#### [Untag conversation](https://developers.intercom.com/intercom-api-reference/reference/detach-a-tag-from-a-conversation) -```node -client.nextPage(response.pages, callback); +```typescript +const response = await client.tags.untagConversation({ + conversationId: '123', + tagId: '345', + adminId: '678', +}); ``` -## Identity verification +#### [Untag contact](https://developers.intercom.com/intercom-api-reference/reference/untag-contact) + +```typescript +const response = await client.tags.untagContact({ + contactId: '123', + tagId: '345', +}); +``` + +#### [List all tags](https://developers.intercom.com/intercom-api-reference/reference/list-tags-for-an-app) + +```typescript +const response = await client.tags.list(); +``` + +### Teams + +#### [Retrieve a team](https://developers.intercom.com/intercom-api-reference/reference/view-a-team) + +```typescript +const response = await client.teams.find({ + id: '123', +}); +``` + +#### [List all teams](https://developers.intercom.com/intercom-api-reference/reference/list-teams) + +```typescript +const response = await client.teams.list(); +``` + +### Identity verification `intercom-node` provides a helper for using [identity verification](https://docs.intercom.com/configure-intercom-for-your-product-or-site/staying-secure/enable-identity-verification-on-your-web-product): -``` node +```node import { IdentityVerification } from 'intercom-client'; -IdentityVerification.userHash({secretKey: 's3cre7', identifier: 'jayne@serenity.io'}); +IdentityVerification.userHash({ + secretKey: 's3cre7', + identifier: 'jayne@serenity.io', +}); ``` ## License @@ -627,16 +1086,16 @@ Apache-2.0 ## Pull Requests -- **Add tests!** Your patch won't be accepted if it doesn't have tests. +- **Add tests!** Your patch won't be accepted if it doesn't have tests. -- **Document any change in behaviour**. Make sure the README and any other - relevant documentation are kept up-to-date. +- **Document any change in behaviour**. Make sure the README and any other + relevant documentation are kept up-to-date. -- **Create topic branches**. Don't ask us to pull from your master branch. +- **Create topic branches**. Don't ask us to pull from your master branch. -- **One pull request per feature**. If you want to do more than one thing, send - multiple pull requests. +- **One pull request per feature**. If you want to do more than one thing, send + multiple pull requests. -- **Send coherent history**. Make sure each individual commit in your pull - request is meaningful. If you had to make multiple intermediate commits while - developing, please squash them before sending them to us. +- **Send coherent history**. Make sure each individual commit in your pull + request is meaningful. If you had to make multiple intermediate commits while + developing, please squash them before sending them to us. diff --git a/gulpfile.js b/gulpfile.js deleted file mode 100644 index 1fc6d4d0..00000000 --- a/gulpfile.js +++ /dev/null @@ -1,47 +0,0 @@ -var gulp = require('gulp'); -var eslint = require('gulp-eslint'); -var excludeGitignore = require('gulp-exclude-gitignore'); -var mocha = require('gulp-mocha'); -var istanbul = require('gulp-istanbul'); -var plumber = require('gulp-plumber'); -var babel = require('gulp-babel'); - -gulp.task('static', function () { - return gulp - .src('**/*.js') - .pipe(excludeGitignore()) - .pipe(eslint()) - .pipe(eslint.format()) - .pipe(eslint.failAfterError()); -}); - -gulp.task('pre-test', function () { - return gulp - .src('lib/**/*.js') - .pipe(babel()) - .pipe(istanbul({ includeUntested: true })) - .pipe(istanbul.hookRequire()); -}); - -gulp.task( - 'test', - gulp.series('pre-test', function () { - return gulp - .src('test/**/*.js') - .pipe(plumber()) - .pipe(mocha({ - compilers: 'js:@babel/register', - reporter: 'spec' - })); - }) -); - -gulp.task('babel', function () { - return gulp - .src('lib/**/*.js') - .pipe(babel()) - .pipe(gulp.dest('dist')); -}); - -gulp.task('prepublish', gulp.series('babel')); -gulp.task('default', gulp.series('static', 'test')); diff --git a/lib/admin.js b/lib/admin.js deleted file mode 100644 index 78e19acb..00000000 --- a/lib/admin.js +++ /dev/null @@ -1,17 +0,0 @@ -export default class Admin { - constructor(client) { - this.client = client; - } - list(f) { - return this.client.get('/admins', {}, f); - } - find(id, f) { - return this.client.get(`/admins/${id}`, {}, f); - } - me(f) { - return this.client.get('/me', {}, f); - } - away(id, params, f) { - return this.client.put(`/admins/${id}/away`, params, f); - } -} diff --git a/lib/admin.ts b/lib/admin.ts new file mode 100644 index 00000000..bf5c7b09 --- /dev/null +++ b/lib/admin.ts @@ -0,0 +1,82 @@ +import { Client } from '.'; +import { AdminObject } from './admin/admin.types'; +import { dateToUnixTimestamp } from './util/time'; + +export default class Admin { + public readonly baseUrl = 'admins'; + + constructor(private readonly client: Client) { + this.client = client; + } + + find({ id }: AdminGetByIdData) { + return this.client.get({ url: `/${this.baseUrl}/${id}` }); + } + away({ adminId, enableAwayMode, enableReassignMode }: SetAdminAwayData) { + const data = { + away_mode_enabled: enableAwayMode, + away_mode_reassign: enableReassignMode, + }; + + return this.client.put({ + url: `/${this.baseUrl}/${adminId}/away`, + data, + }); + } + listAllActivityLogs({ before, after }: ListAllActivityLogsData) { + const params = { + created_at_after: dateToUnixTimestamp(after), + created_at_before: before ? dateToUnixTimestamp(before) : undefined, + }; + + return this.client.get({ + url: `/${this.baseUrl}/activity_logs`, + params, + }); + } + list() { + return this.client.get({ url: `/${this.baseUrl}` }); + } +} + +interface AdminGetByIdData { + id: string; +} + +interface SetAdminAwayData { + adminId: string; + enableAwayMode: boolean; + enableReassignMode: boolean; +} + +interface ListAllActivityLogsData { + after: Date; + before?: Date; +} + +interface ListAllActivityLogsResponse { + type: 'activity_log.list'; + activityLogs: Array; + pages?: Pages; +} + +interface ActivityObject { + id: string; + activity_type: string; + activity_description: string; + metadata: Record; + performed_by: AdminObject; +} + +interface Pages { + type: 'pages'; + next: unknown | null; + page: number; + per_page: number; + total_pages: number; +} + +interface ListAllResponse { + type: 'admin.list'; + admins: AdminObject[]; +} diff --git a/lib/admin/admin.types.ts b/lib/admin/admin.types.ts new file mode 100644 index 00000000..b319cfdf --- /dev/null +++ b/lib/admin/admin.types.ts @@ -0,0 +1,12 @@ +export interface AdminObject { + type: 'admin'; + id: string; + name: string; + email: string; + job_title: string; + away_mode_enabled: boolean; + away_mode_reassign: boolean; + has_inbox_seat: boolean; + team_ids: Array; + avatar: string; +} diff --git a/lib/article.ts b/lib/article.ts new file mode 100644 index 00000000..cefa6a1f --- /dev/null +++ b/lib/article.ts @@ -0,0 +1,119 @@ +import { Client } from '.'; +import { + ArticleObject, + TranslatedContentObject, +} from './article/article.types'; +import { GenericDeletedResponse, Paginated } from './common/common.types'; + +export default class Article { + public readonly baseUrl = 'articles'; + + constructor(private readonly client: Client) { + this.client = client; + } + + create({ + title, + description, + body, + authorId, + state, + parentId, + parentType, + translatedContent, + }: CreateArticleData) { + const data = { + title, + description, + body, + author_id: authorId, + state, + parent_id: parentId, + parent_type: parentType, + translated_content: translatedContent, + }; + + return this.client.post({ + url: `/${this.baseUrl}`, + data, + }); + } + find({ id }: ArticleFindByIdData) { + return this.client.get({ + url: `/${this.baseUrl}/${id}`, + }); + } + update({ + id, + title, + description, + body, + authorId, + state, + parentId, + parentType, + translatedContent, + }: UpdateArticleData) { + const data = { + title, + description, + body, + author_id: authorId, + state, + parent_id: parentId, + parent_type: parentType, + translated_content: translatedContent, + }; + + return this.client.put({ + url: `/${this.baseUrl}/${id}`, + data, + }); + } + delete({ id }: ArticleDeleteByIdData) { + return this.client.delete({ + url: `/${this.baseUrl}/${id}`, + }); + } + list({ page, perPage: per_page }: ArticleListData) { + const params = { + page, + per_page, + }; + + return this.client.get({ + url: `/${this.baseUrl}`, + params, + }); + } +} + +interface CreateArticleData { + title: string; + authorId: number; + description?: string; + body?: string; + state?: string; + parentId?: number; + parentType?: string; + translatedContent?: Omit; +} + +interface OperationById { + id: string; +} + +type ArticleFindByIdData = OperationById; + +type UpdateArticleData = Partial & OperationById; + +type ArticleDeleteByIdData = OperationById; + +type ArticleDeleteByIdResponse = GenericDeletedResponse<'article'>; + +type ArticleListData = { + page?: number; + perPage?: number; +}; + +type ArticleListResponse = Paginated; diff --git a/lib/article/article.types.ts b/lib/article/article.types.ts new file mode 100644 index 00000000..76d86410 --- /dev/null +++ b/lib/article/article.types.ts @@ -0,0 +1,92 @@ +import { Timestamp } from '../common/common.types'; + +export type ArticleObject = { + type: 'article'; + id: string; + workspace_id: string; + title: string; + description: string; + body: string; + author_id: string; + state: string; + created_at: Timestamp; + updated_at: Timestamp; + url: string; + parent_id: string; + parent_type: string; + default_locale: string; + translated_content: TranslatedContentObject; + statistics: StatisticsObject; +}; + +export enum Locales { + ARABIC = 'ar', + BULGARIAN = 'bg', + BOSNIAN = 'bs', + CATALAN = 'ca', + CZECH = 'cs', + DANISH = 'da', + GERMAN = 'de', + DE_FORM = 'de-form', + GREEK = 'el', + ENGLISH = 'en', + SPANISH = 'es', + ESTONIAN = 'et', + FINNISH = 'fi', + FRENCH = 'fr', + HEBREW = 'he', + CROATIAN = 'hr', + HUNGARIAN = 'hu', + INDONESIAN = 'id', + ITALIAN = 'it', + JAPANESE = 'ja', + KOREAN = 'ko', + LITHUANIAN = 'lt', + LATVIAN = 'lv', + MONGOLIAN = 'mn', + NORWEGIAN = 'nb', + DUTCH = 'nl', + POLISH = 'pl', + PORTUGUESE_BRAZIL = 'pt-BR', + PORTUGUESE = 'pt', + ROMANIAN = 'ro', + RUSSIAN = 'ru', + SLOVENIAN = 'sl', + SERBIAN = 'sr', + SWEDISH = 'sv', + TURKISH = 'tr', + VIETNAMESE = 'vi', + CHINESE_S = 'zh-CN', + CHINESE_T = 'zh-TW', +} + +export interface ContentObject { + type?: 'article_content'; + title: string; + description: string; + body: string; + author?: string; + author_id?: number; + state: string; + created_at?: Timestamp; + updated_at?: Timestamp; + url?: string; +} + +export type ArticleLocalesMapping = { + [key in Locales]: ContentObject; +}; + +export type TranslatedContentObject = { + type: 'article_translated_content'; +} & Partial; + +export type StatisticsObject = { + type: 'article_statistics'; + views: number; + conversations: number; + reactions: number; + happy_reaction_percentage: number; + neutral_reaction_percentage: number; + sad_reaction_percentage: number; +}; diff --git a/lib/bulk.js b/lib/bulk.js deleted file mode 100644 index d3f39734..00000000 --- a/lib/bulk.js +++ /dev/null @@ -1,26 +0,0 @@ -export default class Bulk { - constructor(client, dataType) { - this.client = client; - this.dataType = dataType; - } - bulk(bulkOperations, f) { - const dataType = this.dataType; - const bulkParams = { items: [] }; - const url = `/bulk/${dataType}s`; - bulkOperations.forEach(function (params) { - for (let k in params) { - const data = params[k]; - const method = k === 'create' ? 'post' : k; - if (method !== 'post' && method !== 'delete') { - throw new Error(`Unknown bulk type: ${method}`); - } - bulkParams.items.push({ - method: method, - data_type: dataType, - data: data - }); - } - }); - return this.client.post(url, bulkParams, f); - } -} diff --git a/lib/client.js b/lib/client.js deleted file mode 100644 index 0a00040a..00000000 --- a/lib/client.js +++ /dev/null @@ -1,172 +0,0 @@ -import { deprecate } from 'util'; -import request from 'request'; -import Bluebird from 'bluebird'; -import merge from 'lodash/merge'; -import User from './user'; -import Event from './event'; -import Company from './company'; -import Contact from './contact'; -import Visitor from './visitor'; -import Counts from './counts'; -import Admin from './admin'; -import Tag from './tag'; -import Segment from './segment'; -import Message from './message'; -import Conversation from './conversation'; -import Note from './note'; -import Customer from './customer'; - -export default class Client { - constructor(...args) { - if (args.length === 2) { - this.usernamePart = args[0]; - this.passwordPart = args[1]; - } else if (args.length === 1) { - if (args[0].token) { - this.usernamePart = args[0].token; - this.passwordPart = ''; - } else { - this.usernamePart = args[0].appId; - this.passwordPart = args[0].appApiKey; - } - } - if (!this.usernamePart || this.passwordPart === undefined) { - throw new Error('Could not construct a client with those parameters'); - } - this.users = new User(this); - this.events = new Event(this); - this.companies = new Company(this); - this.contacts = new Contact(this); - this.leads = new Contact(this); - this.visitors = new Visitor(this); - this.counts = new Counts(this); - this.admins = new Admin(this); - this.tags = new Tag(this); - this.segments = new Segment(this); - this.messages = new Message(this); - this.conversations = new Conversation(this); - this.notes = new Note(this); - this.customers = new Customer(this); - this.promises = false; - this.requestOpts = { - baseUrl: 'https://api.intercom.io' - }; - - this.useBaseUrl = deprecate(baseUrl => this.useRequestOpts({ baseUrl }), 'intercom-client - client.useBaseUrl(url): Use client.useRequestOpts({ baseUrl: url }) instead'); - } - usePromises() { - this.promises = true; - return this; - } - useRequestOpts(opts) { - this.requestOpts = Object.assign(this.requestOpts, opts); - return this; - } - promiseProxy(f, args) { - if (this.promises || !f) { - const callbackHandler = this.callback; - return new Bluebird((resolve, reject) => { - const resolver = (err, data) => { - if (err) { - reject(err); - } else { - resolve(data); - } - }; - this.request(args, (err, r) => { - callbackHandler(resolver, err, r); - }); - }); - } else { - this.request(args, (err, r) => this.callback(f, err, r)); - } - } - ping(f) { - this.request({ - uri: '/admins' - }, (_, response) => f(response.statusCode)); - } - put(endpoint, data, f) { - return this.promiseProxy(f, - { - method: 'put', - uri: endpoint, - body: data - } - ); - } - post(endpoint, data, f) { - return this.promiseProxy(f, - { - method: 'post', - uri: endpoint, - body: data - } - ); - } - get(endpoint, data, f) { - return this.promiseProxy(f, - { - method: 'get', - uri: endpoint, - qs: data - } - ); - } - nextPage(paginationObject, f) { - return this.promiseProxy(f, - { - method: 'get', - uri: paginationObject.next, - baseUrl: null - } - ); - } - delete(endpoint, data, f) { - return this.promiseProxy(f, - { - method: 'delete', - uri: endpoint, - qs: data - } - ); - } - request(args, callback) { - const defaultArgs = { - json: true, - headers: { - Accept: 'application/json', - 'User-Agent': 'intercom-node-client/2.0.0' - } - }; - // Don't just use Object.assign(requestArgs, args) here because we need to handle special cases like .headers - // Per request args should take prededence over the default, and both of these over the user specified args via .useRequestOpts - const requestArgs = merge({}, this.requestOpts, defaultArgs, args); - return request(requestArgs, callback).auth(this.usernamePart, this.passwordPart); - } - callback(f, err, res) { - if (!f) { - return; - } - if (f.length >= 2) { - if (res && res.body && res.body.type === 'error.list') { - let message = null; - if (Array.isArray(res.body.errors) && res.body.errors[0] && 'message' in res.body.errors[0]) { - // Try to use the first errors message - message = res.body.errors[0].message; - } - err = new Error(message || 'Response error'); - err.statusCode = res.statusCode; - err.body = res.body; - err.headers = res.headers; - } - if (err) { - f(err, null); - } else { - f(null, res); - } - } else { - f(res || null); - } - } -} diff --git a/lib/client.ts b/lib/client.ts new file mode 100644 index 00000000..f0b093c3 --- /dev/null +++ b/lib/client.ts @@ -0,0 +1,279 @@ +import { deprecate } from 'util'; +import axios, { Axios, AxiosDefaults, AxiosResponse } from 'axios'; +import { merge, omit } from 'lodash'; + +import Article from './article'; +import Admin from './admin'; +import Company from './company'; +import Conversation from './conversation'; +import Contact from './contact'; +import DataAttribute from './dataAttribute'; +import Event from './event'; +import HelpCenter from './helpCenter'; +import Segment from './segment'; +import Message from './message'; +import Team from './team'; +import Tag from './tag'; + +import * as packageJson from '../package.json'; + +import { BadResponseError } from './errors/badResponse.error'; + +interface RequestOptions { + url: string; + // eslint-disable-next-line @typescript-eslint/no-explicit-any + data?: any; + // eslint-disable-next-line @typescript-eslint/no-explicit-any + params?: any; +} + +type Constructor = { + usernameAuth?: UsernameAuth; + tokenAuth?: TokenAuth; + apiKeyAuth?: ApiKeyAuth; +}; + +type UsernameAuth = { + username: string; + password: string; +}; + +type TokenAuth = { + token: string; +}; + +type ApiKeyAuth = { + appId: string; + appApiKey: string; +}; + +export default class Client { + articles: Article; + admins: Admin; + axiosInstance: Axios; + companies: Company; + contacts: Contact; + conversations: Conversation; + dataAttributes: DataAttribute; + events: Event; + helpCenter: HelpCenter; + messages: Message; + segments: Segment; + passwordPart?: string; + propertiesToOmitInRequestOpts: string[]; + requestOpts: Partial; + tags: Tag; + teams: Team; + usebaseURL: (baseURL: string) => this; + usernamePart?: string; + + constructor(args: Constructor) { + const [usernamePart, passwordPart] = Client.getAuthDetails(args); + + this.usernamePart = usernamePart; + this.passwordPart = passwordPart; + + if (!this.usernamePart || this.passwordPart === undefined) { + throw new Error( + 'Could not construct a client with those parameters' + ); + } + + this.admins = new Admin(this); + this.articles = new Article(this); + this.companies = new Company(this); + this.contacts = new Contact(this); + this.conversations = new Conversation(this); + this.dataAttributes = new DataAttribute(this); + this.events = new Event(this); + this.helpCenter = new HelpCenter(this); + this.messages = new Message(this); + this.segments = new Segment(this); + this.tags = new Tag(this); + this.teams = new Team(this); + this.requestOpts = { + baseURL: 'https://api.intercom.io', + }; + this.propertiesToOmitInRequestOpts = ['headers.common.Accept']; + + this.usebaseURL = deprecate( + (baseURL) => this.useRequestOpts({ baseURL }), + 'intercom-client - client.usebaseURL(url): Use client.useRequestOpts({ baseURL: url }) instead' + ); + + this.axiosInstance = this.initiateAxiosInstance(); + } + initiateAxiosInstance(): Axios { + const defaultHeaders = { + 'User-Agent': `intercom-node-client/${packageJson.version}`, + Accept: 'application/json', + }; + + const axiosInstance = axios.create({ + auth: { + username: this.usernamePart as string, + password: this.passwordPart as string, + }, + baseURL: this.requestOpts.baseURL, + }); + + axiosInstance.defaults.headers.common = merge( + axiosInstance.defaults.headers.common, + defaultHeaders + ); + + return axiosInstance; + } + + useRequestOpts(opts: Partial) { + const filteredOpts = this.filterUnwantedProperties(opts); + + this.requestOpts = merge(this.requestOpts, filteredOpts); + this.updateAxiosInstanceDefaults(); + + return this; + } + + updateAxiosInstanceDefaults(): void { + this.axiosInstance.defaults = merge( + this.axiosInstance.defaults, + this.requestOpts + ); + } + + filterUnwantedProperties( + opts: Partial + ): Partial { + return omit(opts, this.propertiesToOmitInRequestOpts); + } + + async ping(): Promise { + try { + const response = await this.axiosInstance.get('/admins'); + + return response.data; + } catch (err) { + const error = err.response + ? this.checkOnErrorInResponse(err.response) + : err; + + throw error; + } + } + + async put({ url, data }: RequestOptions): Promise { + try { + const response = await this.axiosInstance.put(url, data); + + return response.data; + } catch (err) { + const error = err.response + ? this.checkOnErrorInResponse(err.response) + : err; + + throw error; + } + } + + async post({ url, data }: RequestOptions): Promise { + try { + const response = await this.axiosInstance.post(url, data); + + return response.data; + } catch (err) { + const error = err.response + ? this.checkOnErrorInResponse(err.response) + : err; + + throw error; + } + } + + async get({ url, data, params }: RequestOptions): Promise { + try { + const response = await this.axiosInstance.get(url, { + params, + data, + }); + + return response.data; + } catch (err) { + const error = err.response + ? this.checkOnErrorInResponse(err.response) + : err; + + throw error; + } + } + + async nextPage(paginationObject: { next: string }): Promise { + try { + const response = await this.axiosInstance.get( + paginationObject.next, + { baseURL: undefined } + ); + + return response.data; + } catch (err) { + const error = err.response + ? this.checkOnErrorInResponse(err.response) + : err; + + throw error; + } + } + + async delete({ url, data, params }: RequestOptions): Promise { + try { + const response = await this.axiosInstance.delete(url, { + data, + params, + }); + + return response.data; + } catch (err) { + const error = err.response + ? this.checkOnErrorInResponse(err.response) + : err; + + throw error; + } + } + + private checkOnErrorInResponse({ + data, + headers, + status, + }: AxiosResponse): Error | undefined { + if (data.type !== 'error.list') { + return undefined; + } + + const message = + Array.isArray(data.errors) && data.errors[0].message + ? data.errors[0].message + : null; + return new BadResponseError( + message || 'Response error', + data, + headers, + status + ); + } + + private static getAuthDetails( + args: Constructor + ): [username: string | undefined, password: string | undefined] { + if (args.apiKeyAuth) { + return [args.apiKeyAuth.appId, args.apiKeyAuth.appApiKey]; + } + if (args.tokenAuth) { + return [args.tokenAuth.token, '']; + } + if (args.usernameAuth) { + return [args.usernameAuth.username, args.usernameAuth.password]; + } + + return [undefined, undefined]; + } +} diff --git a/lib/common/common.types.ts b/lib/common/common.types.ts new file mode 100644 index 00000000..caa76ce7 --- /dev/null +++ b/lib/common/common.types.ts @@ -0,0 +1,121 @@ +export type StringifiedTimestamp = string; +export type Timestamp = number; +export type Seconds = number; +export type JavascriptObject = Record; + +export enum Role { + USER = 'user', + LEAD = 'lead', +} + +export type Paginated = { + type: string; + data: T[]; + pages: { + type: 'pages'; + next?: { + page: number; + starting_after?: string; + }; + page: number; + per_page: number; + total_pages: number; + }; + total_count: number; +}; + +type Join = K extends string | number + ? P extends string | number + ? `${K}${'' extends P ? '' : '.'}${P}` + : never + : never; + +type Prev = [ + never, + 0, + 1, + 2, + 3, + 4, + 5, + 6, + 7, + 8, + 9, + 10, + 11, + 12, + 13, + 14, + 15, + 16, + 17, + 18, + 19, + 20, + ...0[] +]; + +// D is depth, we don't want to go past 3 nested objects +export type Paths = [D] extends [never] + ? never + : T extends object + ? { + [K in keyof T]-?: K extends string | number + ? `${K}` | Join> + : never; + }[keyof T] + : ''; + +// D is depth, we don't want to go past 3 nested objects +export type Leaves = [D] extends [never] + ? never + : T extends object + ? { [K in keyof T]-?: Join> }[keyof T] + : ''; + +export enum Operators { + AND = 'AND', + OR = 'OR', + EQUALS = '=', + NOT_EQUALS = '!=', + IN = 'IN', + NIN = 'NIN', + GREATER_THAN = '>', + LESS_THAN = '<', + CONTAINS = '~', + NOT_CONTAINS = '!~', + STARTS_WITH = '^', + ENDS_WITH = '$', +} + +interface FlatQuery { + field: Leaves; + operator: Operators; + value: string | number | null; +} + +interface NestedQueries { + operator: Operators; + value: Array | NestedQueries> | string | number | null; +} + +export interface GenericSearchFilters { + query: FlatQuery | NestedQueries; +} + +export enum Order { + DESC = 'desc', + ASC = 'asc', +} + +export interface PaginationParams { + page?: number; + perPage?: number; +} + +export interface GenericDeletedResponse { + id: string; + object: ObjectType; + deleted: boolean; +} diff --git a/lib/company.js b/lib/company.js deleted file mode 100644 index 4c9fcba2..00000000 --- a/lib/company.js +++ /dev/null @@ -1,38 +0,0 @@ -import Scroll from './scroll'; - -export default class Company { - constructor(client) { - this.client = client; - this.scroll = new Scroll(this.client, 'companie'); - } - create(data, f) { - return this.client.post('/companies', data, f); - } - update(data, f) { - return this.create(data, f); - } - list(f) { - return this.client.get('/companies', {}, f); - } - listBy(params, f) { - return this.client.get('/companies', params, f); - } - find(params, f) { - if (params.id) { - return this.client.get(`/companies/${params.id}`, {}, f); - } else if (params.company_id) { - return this.client.get('/companies', { company_id: params.company_id }, f); - } else if (params.name) { - return this.client.get('/companies', { name: params.name }, f); - } - } - listUsers(params, f) { - if (params.id) { - return this.client.get(`/companies/${params.id}/users`, {}, f); - } else if (params.company_id) { - return this.client.get('/companies', { company_id: params.company_id, type: 'user' }, f); - } else if (params.name) { - return this.client.get('/companies', { name: params.name, type: 'user' }, f); - } - } -} diff --git a/lib/company.ts b/lib/company.ts new file mode 100644 index 00000000..c4f4f346 --- /dev/null +++ b/lib/company.ts @@ -0,0 +1,198 @@ +import { Client } from '.'; +import { + PaginationParams, + JavascriptObject, + Order, + Paginated, + Timestamp, + GenericDeletedResponse, +} from './common/common.types'; +import { CompanyObject, ListCompaniesResponse } from './company/company.types'; +import { ContactObject } from './contact/contact.types'; +import Scroll from './scroll'; +import { SegmentObject } from './segment/segment.types'; +import { encodeParamsForURL } from './util/url'; + +export default class Company { + public readonly baseUrl = 'companies'; + public readonly scroll: Scroll; + + constructor(private readonly client: Client) { + this.client = client; + this.scroll = new Scroll(this.client, this.baseUrl); + } + create({ + createdAt, + companyId, + name, + monthlySpend, + plan, + size, + website, + industry, + customAttributes, + }: CreateCompanyData) { + const data = { + remote_created_at: createdAt, + company_id: companyId, + name, + monthly_spend: monthlySpend, + plan, + size, + website, + industry, + custom_attributes: customAttributes, + }; + + return this.client.post({ + url: `/${this.baseUrl}`, + data, + }); + } + update({ + createdAt, + companyId, + name, + monthlySpend, + plan, + size, + website, + industry, + customAttributes, + }: UpdateCompanyData) { + const data = { + remote_created_at: createdAt, + name, + monthly_spend: monthlySpend, + plan, + size, + website, + industry, + custom_attributes: customAttributes, + }; + + return this.client.put({ + url: `/${this.baseUrl}/${companyId}`, + data, + }); + } + find({ companyId, name }: FindCompanyData) { + const query = { + company_id: companyId, + name, + }; + + return this.client.get({ + url: `/${this.baseUrl}`, + params: encodeParamsForURL( + query as Record> + ), + }); + } + delete({ id }: DeleteCompanyData) { + return this.client.delete({ + url: `/${this.baseUrl}/${id}`, + }); + } + list({ + page, + perPage: per_page, + order, + tagId: tag_id, + segmentId: segment_id, + }: ListCompaniesData) { + const params = { + page, + per_page, + order, + tag_id, + segment_id, + }; + + return this.client.get({ + url: `/${this.baseUrl}`, + params, + }); + } + attachContact({ contactId, companyId }: AttachContactData) { + const data = { + id: companyId, + }; + + return this.client.post({ + url: `/${this.client.contacts.baseUrl}/${contactId}/${this.baseUrl}`, + data, + }); + } + detachContact({ contactId, companyId }: DetachContactData) { + return this.client.delete({ + url: `/${this.client.contacts.baseUrl}/${contactId}/${this.baseUrl}/${companyId}`, + }); + } + listAttachedContacts({ + companyId, + page, + perPage, + }: ListAttachedContactsData) { + const params = { page, perPage }; + + return this.client.get>({ + url: `/${this.baseUrl}/${companyId}/${this.client.contacts.baseUrl}`, + params, + }); + } + listAttachedSegments({ companyId }: ListAttachedSegmentsData) { + return this.client.get({ + url: `/${this.baseUrl}/${companyId}/${this.client.segments.baseUrl}`, + }); + } +} + +interface CreateCompanyData { + createdAt: Timestamp; + companyId: string; + name: string; + monthlySpend: number; + plan: string; + size: number; + website: string; + industry: string; + customAttributes: JavascriptObject; +} +// +type UpdateCompanyData = CreateCompanyData; +// +interface FindCompanyData { + companyId?: string; + name?: string; +} +// +interface DeleteCompanyData { + id: string; +} +type DeleteCompanyResponse = GenericDeletedResponse<'company'>; +// +interface ListCompaniesData extends PaginationParams { + order?: Order; + tagId?: string; + segmentId?: string; +} +// +interface AttachContactData { + contactId: string; + companyId: string; +} +// +type DetachContactData = AttachContactData; +// +interface ListAttachedContactsData extends PaginationParams { + companyId: string; +} +// +interface ListAttachedSegmentsData { + companyId: string; +} +interface ListAttachedSegmentsResponse { + type: 'list'; + data: SegmentObject[]; +} diff --git a/lib/company/company.types.ts b/lib/company/company.types.ts new file mode 100644 index 00000000..f5f22b99 --- /dev/null +++ b/lib/company/company.types.ts @@ -0,0 +1,39 @@ +import { JavascriptObject, Paginated, Timestamp } from '../common/common.types'; +import { SegmentObject } from '../segment/segment.types'; +import { TagObject } from '../tag/tag.types'; + +export interface CompanyObject { + type: 'company'; + company_id: string; + id: string; + app_id: string; + name: string; + remote_created_at: Timestamp; + created_at: Timestamp; + updated_at: Timestamp; + last_request_at: Timestamp; + monthly_spend: number; + session_count: number; + user_count: number; + size: number; + website: string; + industry: string; + tags: { + type: 'tag.list'; + tags: TagObject; + }; + segments: { + type: 'segment.list'; + segments: SegmentObject; + }; + plan: PlanObject; + custom_attributes: JavascriptObject; +} + +export interface PlanObject { + type: 'plan'; + id: string; + name: string; +} + +export type ListCompaniesResponse = Paginated; diff --git a/lib/contact.js b/lib/contact.js deleted file mode 100644 index 7d257f50..00000000 --- a/lib/contact.js +++ /dev/null @@ -1,40 +0,0 @@ -import Scroll from './scroll'; - -export default class Contact { - constructor(client) { - this.client = client; - this.scroll = new Scroll(this.client, 'contact'); - } - create() { - const parameters_or_function = arguments[0]; - let params = {}; - let callback = parameters_or_function; - if (typeof parameters_or_function !== 'function') { - params = parameters_or_function; - callback = arguments[1]; - } - return this.client.post('/contacts', params, callback); - } - update(params, f) { - return this.client.post('/contacts', params, f); - } - list(f) { - return this.client.get('/contacts', {}, f); - } - listBy(params, f) { - return this.client.get('/contacts', params, f); - } - find(params, f) { - if (params.id) { - return this.client.get(`/contacts/${params.id}`, {}, f); - } else if (params.user_id) { - return this.client.get('/contacts', { user_id: params.user_id }, f); - } - } - delete(params, f) { - return this.client.delete(`/contacts/${params.id}`, {}, f); - } - convert(params, f) { - return this.client.post('/contacts/convert', params, f); - } -} diff --git a/lib/contact.ts b/lib/contact.ts new file mode 100644 index 00000000..5abf8a82 --- /dev/null +++ b/lib/contact.ts @@ -0,0 +1,334 @@ +import { Client } from '.'; +import { ContactObject } from './contact/contact.types'; +import { + GenericDeletedResponse, + GenericSearchFilters, + Leaves, + Paginated, + Role, +} from './common/common.types'; +import { ListCompaniesResponse } from './company/company.types'; +import { SegmentObject } from './segment/segment.types'; +import { TagObject } from './tag/tag.types'; +import { SubscriptionObject } from './subscription/subscription.types'; + +export default class Contact { + public readonly baseUrl = 'contacts'; + + constructor(private readonly client: Client) { + this.client = client; + } + createUser({ + externalId, + phone, + name, + avatar, + signedUpAt, + lastSeenAt, + ownerId, + isUnsubscribedFromEmails, + customAttributes, + }: CreateUserData) { + const requestData: CreateContactRequest = { + role: Role.USER, + external_id: externalId, + phone, + name, + avatar, + signed_up_at: signedUpAt, + last_seen_at: lastSeenAt, + owner_id: ownerId, + unsubscribed_from_emails: isUnsubscribedFromEmails, + custom_attributes: customAttributes, + }; + + return this.client.post({ + url: `/${this.baseUrl}`, + data: requestData, + }); + } + createLead(data?: CreateLeadData) { + const requestData: CreateContactRequest = { + role: Role.LEAD, + phone: data?.phone, + name: data?.name, + avatar: data?.avatar, + signed_up_at: data?.signedUpAt, + last_seen_at: data?.lastSeenAt, + owner_id: data?.ownerId, + unsubscribed_from_emails: data?.isUnsubscribedFromMails, + custom_attributes: data?.customAttributes, + }; + return this.client.post({ + url: `/${this.baseUrl}`, + data: requestData, + }); + } + find({ id }: RetrieveContactData) { + return this.client.get({ + url: `/${this.baseUrl}/${id}`, + }); + } + update({ + id, + role, + externalId, + phone, + name, + avatar, + signedUpAt, + lastSeenAt, + ownerId, + isUnsubscribedFromMails, + customAttributes, + }: UpdateContactData) { + const data: UpdateContactRequest = { + role, + external_id: externalId, + phone, + name, + avatar, + signed_up_at: signedUpAt, + last_seen_at: lastSeenAt, + owner_id: ownerId, + unsubscribed_from_emails: isUnsubscribedFromMails, + custom_attributes: customAttributes, + }; + + return this.client.put({ + url: `/${this.baseUrl}/${id}`, + data, + }); + } + mergeLeadInUser({ leadId, userId }: MergeLeadInUserContactData) { + const data: MergeLeadInUserContactRequest = { + from: leadId, + into: userId, + }; + + return this.client.post({ + url: `/${this.baseUrl}/merge`, + data, + }); + } + search({ data }: SearchContactRequest) { + return this.client.post({ + url: `/${this.baseUrl}/search`, + data, + }); + } + list({ perPage, startingAfter }: ListAllContactsData) { + const params: ListAllContactsRequest = { + per_page: perPage, + starting_after: startingAfter, + }; + return this.client.get({ + url: `/${this.baseUrl}`, + params, + }); + } + delete({ id }: DeleteContactData) { + return this.client.delete({ + url: `/${this.baseUrl}/${id}`, + }); + } + archive({ id }: ArchiveContactData) { + return this.client.post({ + url: `/${this.baseUrl}/${id}/archive`, + }); + } + unarchive({ id }: UnarchiveContactData) { + return this.client.post({ + url: `/${this.baseUrl}/${id}/unarchive`, + }); + } + listAttachedCompanies({ id, perPage, page }: ListAttachedCompaniesData) { + const params = { + per_page: perPage, + page, + }; + return this.client.get({ + url: `/${this.baseUrl}/${id}/companies`, + params, + }); + } + listAttachedTags({ id }: RetrieveContactData) { + return this.client.get({ + url: `/${this.baseUrl}/${id}/tags`, + }); + } + listAttachedSegments({ id }: RetrieveContactData) { + return this.client.get({ + url: `/${this.baseUrl}/${id}/segments`, + }); + } + listAttachedEmailSubscriptions({ id }: RetrieveContactData) { + return this.client.get({ + url: `/${this.baseUrl}/${id}/subscriptions`, + }); + } +} + +type CreateContactRequest = Pick & + Partial< + Pick< + ContactObject, + | 'external_id' + | 'email' + | 'phone' + | 'name' + | 'avatar' + | 'signed_up_at' + | 'last_seen_at' + | 'owner_id' + | 'unsubscribed_from_emails' + | 'custom_attributes' + > + >; + +interface CreateUserData { + externalId?: CreateContactRequest['external_id']; + phone?: CreateContactRequest['phone']; + name?: CreateContactRequest['name']; + avatar?: CreateContactRequest['avatar']; + signedUpAt?: CreateContactRequest['signed_up_at']; + lastSeenAt?: CreateContactRequest['last_seen_at']; + ownerId?: CreateContactRequest['owner_id']; + isUnsubscribedFromEmails?: CreateContactRequest['unsubscribed_from_emails']; + customAttributes?: CreateContactRequest['custom_attributes']; +} + +interface CreateLeadData { + phone?: CreateContactRequest['phone']; + name?: CreateContactRequest['name']; + avatar?: CreateContactRequest['avatar']; + signedUpAt?: CreateContactRequest['signed_up_at']; + lastSeenAt?: CreateContactRequest['last_seen_at']; + ownerId?: CreateContactRequest['owner_id']; + isUnsubscribedFromMails?: CreateContactRequest['unsubscribed_from_emails']; + customAttributes?: CreateContactRequest['custom_attributes']; +} +// +interface RetrieveContactData { + id: string; +} +// +type UpdateContactRequest = Partial< + Pick< + ContactObject, + | 'role' + | 'external_id' + | 'email' + | 'phone' + | 'name' + | 'avatar' + | 'signed_up_at' + | 'last_seen_at' + | 'owner_id' + | 'unsubscribed_from_emails' + | 'custom_attributes' + > +>; + +type UpdateContactData = { + id: string; + role?: UpdateContactRequest['role']; + externalId?: UpdateContactRequest['external_id']; + phone?: UpdateContactRequest['phone']; + name?: UpdateContactRequest['name']; + avatar?: UpdateContactRequest['avatar']; + signedUpAt?: UpdateContactRequest['signed_up_at']; + lastSeenAt?: UpdateContactRequest['last_seen_at']; + ownerId?: UpdateContactRequest['owner_id']; + isUnsubscribedFromMails?: UpdateContactRequest['unsubscribed_from_emails']; + customAttributes?: UpdateContactRequest['custom_attributes']; +}; +// +interface DeleteContactData { + id: string; +} + +type DeleteContactResponse = GenericDeletedResponse<'contact'>; +// +interface ArchiveContactData { + id: string; +} + +interface ArchiveContactResponse { + id: string; + object: ContactObject; + archived: boolean; +} +// +type UnarchiveContactData = ArchiveContactData; + +type UnarchiveContactResponse = ArchiveContactResponse; +// +interface MergeLeadInUserContactRequest { + from: string; + into: string; +} + +interface MergeLeadInUserContactData { + leadId: string; + userId: string; +} +// +export enum SearchContactOrderBy { + ASC = 'ascending', + DESC = 'descending', +} +interface SearchContactPagination { + pagination: { + per_page: number; + starting_after?: string; + }; +} + +interface SearchContactOrder { + sort: { + field: Leaves; + order: SearchContactOrderBy; + }; +} + +interface SearchContactRequest { + data: GenericSearchFilters & + Partial & + Partial; +} + +type SearchContactResponse = Paginated; +// +interface ListAllContactsRequest { + per_page?: number; + starting_after?: string; +} + +interface ListAllContactsData { + perPage?: number; + startingAfter?: string; +} + +type ListContactsResponse = Paginated; +// +type ListAttachedTagsResponse = { + type: string; + tags: Array; +}; +// +type ListAttachedSegmentsResponse = { + type: string; + data: Array; +}; +// +type ListAttachedEmailSubscriptionsResponse = { + type: string; + data: Array; +}; +// +type ListAttachedCompaniesData = { + id: string; + perPage?: number; + page?: number; +}; diff --git a/lib/contact/contact.types.ts b/lib/contact/contact.types.ts new file mode 100644 index 00000000..3df2d720 --- /dev/null +++ b/lib/contact/contact.types.ts @@ -0,0 +1,83 @@ +import { JavascriptObject, Role, Timestamp } from '../common/common.types'; + +export interface ContactObject { + type: 'contact'; + id: string; + workspace_id: string; + external_id: string; + role: Role; + email: string; + phone: string; + name: string; + avatar: string; + owner_id: number; + social_profiles: Array; + has_hard_bounced: boolean; + marked_email_as_spam: boolean; + unsubscribed_from_emails: boolean; + created_at: Timestamp; + updated_at: Timestamp; + signed_up_at: Timestamp; + last_seen_at: Timestamp; + last_replied_at: Timestamp; + last_contacted_at: Timestamp; + last_email_opened_at: Timestamp; + last_email_clicked_at: Timestamp; + language_override: string; + browser: string; + browser_version: string; + browser_language: string; + os: string; + location: LocationObject; + android_app_name: string | null; + android_app_version: string | null; + android_device: string | null; + android_os_version: string | null; + android_sdk_version: string | null; + android_last_seen_at: Timestamp | null; + ios_app_name: string | null; + ios_app_version: string | null; + ios_device: string | null; + ios_os_version: string | null; + ios_sdk_version: string | null; + ios_last_seen_at: Timestamp | null; + custom_attributes: JavascriptObject; + tags: AddressableList; + notes: AddressableList; + companies: AddressableList; + referrer: string; + utm_campaign: string | null; + utm_content: string | null; + utm_medium: string | null; + utm_source: string | null; + utm_term: string | null; +} + +interface LocationObject { + type: 'location'; + country: string; + region: string; + city: string; + country_code: string; + continent_code: string; +} + +interface SocialProfileObject { + type: 'social_profile'; + name: string; + url: string; +} + +interface AddressableList { + type: 'list'; + data: Array; + url: string; + total_count: number; + has_more: boolean; +} + +interface AddressableObject { + type: 'company' | 'note' | 'tag'; + id: string; + url: string; +} diff --git a/lib/conversation.js b/lib/conversation.js deleted file mode 100644 index d68fba52..00000000 --- a/lib/conversation.js +++ /dev/null @@ -1,17 +0,0 @@ -export default class Conversation { - constructor(client) { - this.client = client; - } - list(data, f) { - return this.client.get('/conversations', data, f); - } - find(params, f) { - return this.client.get(`/conversations/${params.id}`, params, f); - } - reply(params, f) { - return this.client.post(`/conversations/${params.id}/reply`, params, f); - } - markAsRead(params, f) { - return this.client.put(`/conversations/${params.id}`, { read: true }, f); - } -} diff --git a/lib/conversation.ts b/lib/conversation.ts new file mode 100644 index 00000000..223ec29b --- /dev/null +++ b/lib/conversation.ts @@ -0,0 +1,549 @@ +import Client from './client'; +import { + Paginated, + StringifiedTimestamp, + GenericSearchFilters, + Leaves, + Order, +} from './common/common.types'; +import { + ContactType, + ConversationObject, + ConversationObjectWithoutParts, +} from './conversation/conversation.types'; +import { MessageObject } from './message/message.types'; + +export default class Conversation { + public readonly baseUrl = 'conversations'; + + constructor(private readonly client: Client) { + this.client = client; + } + create({ userId, body }: CreateConversationData) { + const requestData: CreateConversationRequest = { + from: { + id: userId, + type: 'user', + }, + body, + }; + return this.client.post({ + url: `/${this.baseUrl}`, + data: requestData, + }); + } + find({ id, inPlainText }: RetrieveConversationData) { + const params = inPlainText + ? { + display_as: 'plaintext', + } + : undefined; + + return this.client.get({ + url: `/${this.baseUrl}/${id}`, + params, + }); + } + update({ id, markRead, customAttributes }: UpdateConversationData) { + const data: UpdateConversationRequest = { + read: markRead, + custom_attributes: customAttributes, + }; + + return this.client.put({ + url: `/${this.baseUrl}/${id}`, + data, + }); + } + replyByIdAsUser({ + id, + body, + intercomUserId, + userId, + email, + attachmentUrls, + }: ReplyByIdAsUserData) { + const data: ReplyToConversationAsUser = { + message_type: ReplyToConversationMessageType.COMMENT, + type: ReplyToConversationUserType.USER, + body, + intercom_user_id: intercomUserId, + user_id: userId, + email: email, + attachment_urls: attachmentUrls, + }; + return this.client.post({ + url: `/${this.baseUrl}/${id}/reply`, + data, + }); + } + replyByIdAsAdmin({ + id, + adminId, + messageType, + body, + attachmentUrls, + }: ReplyByIdAsAdminData) { + const data: ReplyToConversationAsAdmin = { + admin_id: adminId, + message_type: messageType, + type: ReplyToConversationUserType.ADMIN, + body, + attachment_urls: attachmentUrls, + }; + return this.client.post({ + url: `/${this.baseUrl}/${id}/reply`, + data, + }); + } + replyByLastAsUser({ + body, + intercomUserId, + userId, + email, + attachmentUrls, + }: ReplyByLastAsUserData) { + const data: ReplyToConversationAsUser = { + message_type: ReplyToConversationMessageType.COMMENT, + type: ReplyToConversationUserType.USER, + body, + intercom_user_id: intercomUserId, + user_id: userId, + email: email, + attachment_urls: attachmentUrls, + }; + return this.client.post({ + url: `/${this.baseUrl}/last/reply`, + data, + }); + } + replyByLastAsAdmin({ + adminId, + messageType, + body, + attachmentUrls, + }: ReplyByLastAsAdminData) { + const data: ReplyToConversationAsAdmin = { + admin_id: adminId, + message_type: messageType, + type: ReplyToConversationUserType.ADMIN, + body, + attachment_urls: attachmentUrls, + }; + return this.client.post({ + url: `/${this.baseUrl}/last/reply`, + data, + }); + } + assign({ + id, + type, + adminId, + assigneeId, + body, + withRunningAssignmentRules = false, + }: AssignConversationData) { + const url = `/${this.baseUrl}/${id}${ + withRunningAssignmentRules ? '/run_assignment_rules' : '' + }/parts`; + const data: AssignConversationRequest | undefined = + withRunningAssignmentRules + ? undefined + : { + message_type: AssignToConversationMessageType.ASSIGNMENT, + type, + admin_id: adminId, + assignee_id: assigneeId, + body, + }; + + return this.client.post({ url, data }); + } + snooze({ id, adminId, snoozedUntil }: SnoozeConversationData) { + const data: SnoozeConversationRequest = { + message_type: SnoozeConversationMessageType.SNOOZED, + admin_id: adminId, + snoozed_until: snoozedUntil, + }; + + return this.client.post({ + url: `/${this.baseUrl}/${id}/reply`, + data, + }); + } + close({ id, adminId, body }: CloseConversationData) { + const data: CloseConversationRequest = { + message_type: CloseConversationMessageType.CLOSED, + type: CloseConversationType.ADMIN, + admin_id: adminId, + body, + }; + + return this.client.post({ + url: `/${this.baseUrl}/${id}/parts`, + data, + }); + } + open({ id, adminId }: OpenConversationData) { + const data: OpenConversationRequest = { + message_type: OpenConversationMessageType.OPEN, + admin_id: adminId, + }; + + return this.client.post({ + url: `/${this.baseUrl}/${id}/parts`, + data, + }); + } + attachContactAsAdmin({ + id, + adminId, + customer, + }: AttachContactToConversationAsAdminData) { + const data: AttachContactToConversationAdminRequest = { + admin_id: adminId, + customer: { + intercom_user_id: customer.intercomUserId, + user_id: customer.userId, + email: customer.email, + }, + }; + + return this.client.post({ + url: `/${this.baseUrl}/${id}/customers`, + data, + }); + } + attachContactAsContact({ + id, + userId, + intercomUserId, + email, + customer, + }: AttachContactToConversationAsContactData) { + const data: AttachContactToConversationContactRequest = { + intercom_user_id: intercomUserId, + user_id: userId, + email, + customer: { + intercom_user_id: customer.intercomUserId, + user_id: customer.userId, + email: customer.email, + }, + }; + + return this.client.post({ + url: `/${this.baseUrl}/${id}/customers`, + data, + }); + } + detachContactAsAdmin({ + conversationId, + contactId, + adminId, + }: DetachContactFromConversationData) { + const data: DetachContactFromConversationRequest = { + admin_id: adminId, + }; + + return this.client.delete({ + url: `/${this.baseUrl}/${conversationId}/customers/${contactId}`, + data, + }); + } + search({ data }: SearchConversationRequest) { + return this.client.post({ + url: `/${this.baseUrl}/search`, + data, + }); + } + list({ + query: { order, sort, page, perPage: per_page }, + }: ListConversationData) { + const params = { order, sort, page, per_page }; + + return this.client.get({ + url: `/${this.baseUrl}`, + params, + }); + } + redactConversationPart({ + conversationId, + conversationPartId, + sourceId, + type, + }: RedactConversationPartData) { + const data: RedactConversationPartRequest = { + conversation_id: conversationId, + conversation_part_id: conversationPartId, + source_id: sourceId, + type, + }; + + return this.client.post({ + url: `/${this.baseUrl}/redact`, + data, + }); + } +} + +interface CreateConversationRequest { + from: { + type: 'user' | string; + id: string; + }; + body: string; +} + +interface CreateConversationData { + userId: string; + body: string; +} +// +interface RetrieveConversationData { + id: string; + inPlainText?: boolean; +} +// +interface UpdateConversationRequest { + custom_attributes?: object; + read?: boolean; +} +interface UpdateConversationData { + id: string; + markRead?: boolean; + customAttributes?: object; +} +// +export enum ReplyToConversationMessageType { + COMMENT = 'comment', + NOTE = 'note', +} +export enum ReplyToConversationUserType { + ADMIN = 'admin', + USER = 'user', +} + +interface ReplyToConversationAsUser { + message_type: ReplyToConversationMessageType; + type: ReplyToConversationUserType; + body: string; + // refactor to CustomerObject + intercom_user_id?: string; + user_id?: string; + email?: string; + attachment_urls?: Array; +} + +interface ReplyToConversationAsAdmin { + admin_id: string; + message_type: ReplyToConversationMessageType; + type: ReplyToConversationUserType; + body: string; + attachment_urls?: Array; +} + +interface ReplyByIdAsUserData { + id: string; + body: string; + intercomUserId?: string; + userId?: string; + email?: string; + attachmentUrls?: Array; +} + +interface ReplyByIdAsAdminData { + id: string; + adminId: string; + messageType: ReplyToConversationMessageType; + body: string; + attachmentUrls?: Array; +} + +type ReplyByLastAsUserData = Omit; + +type ReplyByLastAsAdminData = Omit; +// +export enum AssignToConversationMessageType { + ASSIGNMENT = 'assignment', +} +export enum AssignToConversationUserType { + ADMIN = 'admin', + TEAM = 'team', +} + +interface AssignConversationRequest { + message_type: AssignToConversationMessageType; + type?: AssignToConversationUserType; + admin_id?: string; + assignee_id?: string | 0; + body?: string; +} + +interface AssignConversationData { + id: string; + type?: AssignToConversationUserType; + adminId?: string; + assigneeId?: string | 0; + body?: string; + withRunningAssignmentRules?: boolean; +} +// +export enum SnoozeConversationMessageType { + SNOOZED = 'snoozed', +} + +interface SnoozeConversationRequest { + message_type: SnoozeConversationMessageType; + admin_id: string; + snoozed_until: StringifiedTimestamp; +} + +interface SnoozeConversationData { + id: string; + adminId: string; + snoozedUntil: StringifiedTimestamp; +} +// +export enum CloseConversationMessageType { + CLOSED = 'closed', +} +export enum CloseConversationType { + ADMIN = 'admin', +} + +interface CloseConversationRequest { + message_type: CloseConversationMessageType; + type: CloseConversationType; + admin_id: string; + body?: string; +} + +interface CloseConversationData { + id: string; + adminId: string; + body?: string; +} +// +export enum OpenConversationMessageType { + OPEN = 'open', +} + +interface OpenConversationRequest { + message_type: OpenConversationMessageType; + admin_id: string; +} + +interface OpenConversationData { + id: string; + adminId: string; +} +// +interface CustomerObject { + intercom_user_id?: string; + user_id?: string; + email?: string; +} + +interface NormalizedCustomerObject { + intercomUserId?: string; + userId?: string; + email?: string; +} + +interface AttachContactToConversationAdminRequest { + admin_id: string; + customer: CustomerObject; +} + +interface AttachContactToConversationContactRequest extends CustomerObject { + customer: CustomerObject; +} + +interface AttachContactToConversationAsAdminData { + id: string; + adminId: string; + customer: NormalizedCustomerObject; +} + +interface AttachContactToConversationAsContactData + extends NormalizedCustomerObject { + id: string; + customer: NormalizedCustomerObject; +} + +interface AttachContactToConversationResponse { + customers: Array<{ id: string; type: ContactType }>; +} +// +interface DetachContactFromConversationRequest { + admin_id: string; +} + +interface DetachContactFromConversationData { + conversationId: string; + contactId: string; + adminId: string; +} +// +export enum SearchConversationOrderBy { + ASC = 'ascending', + DESC = 'descending', +} +interface SearchConversationPagination { + pagination: { + per_page: number; + starting_after?: string; + }; +} + +interface SearchConversationOrder { + sort: { + field: Leaves; + order: SearchConversationOrderBy; + }; +} + +interface SearchConversationRequest { + data: GenericSearchFilters & + Partial & + Partial; +} + +type SearchConversationResponse = Paginated; +// +export enum SortBy { + CreatedAt = 'created_at', + UpdatedAt = 'updated_at', + WaitingSince = 'waiting_since', +} + +interface ListConversationData { + query: { + order: Order; + sort: SortBy; + page?: number; + perPage?: number; + }; +} + +type ListConversationResponse = Paginated; +// +export enum RedactConversationPartType { + CONVERSATION_PART = 'conversation_part', + SOURCE = 'source', +} + +interface RedactConversationPartRequest { + type: RedactConversationPartType; + conversation_id: string; + conversation_part_id?: string; + source_id?: string; +} + +interface RedactConversationPartData { + type: RedactConversationPartType; + conversationId: string; + conversationPartId?: string; + sourceId?: string; +} diff --git a/lib/conversation/conversation.types.ts b/lib/conversation/conversation.types.ts new file mode 100644 index 00000000..f1c370a9 --- /dev/null +++ b/lib/conversation/conversation.types.ts @@ -0,0 +1,163 @@ +import { AdminObject } from '../admin/admin.types'; +import { JavascriptObject, Seconds, Timestamp } from '../common/common.types'; + +export interface ConversationObject { + type: 'conversation'; + id: string; + created_at: Timestamp; + updated_at: Timestamp; + source: SourceObject; + contacts: Array; + teammates: Array; + title: string; + admin_assignee_id: number; + team_assignee_id: number; + custom_attributes: JavascriptObject; + topics: JavascriptObject; + open: boolean; + state: ConversationState; + read: boolean; + waiting_since: Timestamp; + snoozed_until: Timestamp; + tags: JavascriptObject[]; + first_contact_reply: FirstContactReplyObject; + priority: ConversationPriority; + sla_applied: SLAObject; + conversation_rating: ConversationRatingObject; + statistics: StatisticsObject; + conversation_parts: ConversationPartObject; +} + +export type ConversationObjectWithoutParts = Exclude< + ConversationObject, + 'conversation_parts' +>; + +interface SourceObject { + type: ConversationSourceType; + id: string; + delivered_as: string; + subject?: string; + body: string; + author: Author; + attachments: JavascriptObject[]; + url: string; + redacted: boolean; +} + +interface ContactObject { + type: ContactType; + id: string; +} + +interface TeammateObject { + type: 'admin'; + id: string; +} + +interface FirstContactReplyObject { + type: ConversationSourceType; + url: string; + created_at: Timestamp; +} + +interface ConversationRatingObject { + rating: FromOneToFiveRating; + remark?: string; + created_at: Timestamp; + contact: ContactObject; + teammate: TeammateObject; +} + +interface SLAObject { + sla_name: string; + sla_status: SLAStatus; +} + +interface StatisticsObject { + time_to_assignment: Seconds; + time_to_admin_reply: Seconds; + time_to_first_close: Seconds; + time_to_last_close: Seconds; + median_time_to_reply: Seconds; + first_contact_reply_at: Seconds; + first_assignment_at: Seconds; + first_admin_reply_at: Seconds; + first_close_at: Seconds; + last_assignment_at: Seconds; + last_assignment_admin_reply_at: Seconds; + last_contact_reply_at: Seconds; + last_admin_reply_at: Seconds; + last_close_at: Seconds; + last_closed_by: AdminObject; + count_reopens: number; + count_assignments: number; + count_conversations_parts: number; +} + +interface ConversationPartObject { + type: 'conversation_part.list'; + conversation_parts: { + id: string; + part_type: string; + body: string; + created_at: Timestamp; + updated_at: Timestamp; + notified_at: Timestamp; + assigned_to: string | null; + author: Author; + attachments: JavascriptObject[]; + redacted: boolean; + }[]; +} + +enum ConversationState { + OPEN = 'open', + CLOSED = 'closed', + SNOOZED = 'snoozed', +} + +enum ConversationPriority { + PRIORITY = 'priority', + NOT_PRIORITY = 'not_priority', +} + +enum ConversationSourceType { + CONVERASTION = 'conversation', + PUSH = 'push', + FACEBOOK = 'facebook', + TWITTER = 'twitter', + EMAIL = 'email', +} + +export enum ContactType { + USER = 'user', + LEAD = 'lead', +} + +enum FromOneToFiveRating { + ONE = 1, + TWO = 2, + THREE = 3, + FOUR = 4, + FIVE = 5, +} + +enum SLAStatus { + HIT = 'hit', + MISSED = 'missed', + CANCELLED = 'cancelled', + ACTIVE = 'active', +} + +interface Author { + id: string; + type: AuthorType; +} + +enum AuthorType { + USER = 'user', + ADMIN = 'admin', + BOT = 'bot', + TEAM = 'team', +} diff --git a/lib/counts.js b/lib/counts.js deleted file mode 100644 index 5883642e..00000000 --- a/lib/counts.js +++ /dev/null @@ -1,29 +0,0 @@ -export default class Counts { - constructor(client) { - this.client = client; - } - appCounts(f) { - return this.client.get('/counts', {}, f); - } - conversationCounts(f) { - return this.client.get('/counts', { type: 'conversation' }, f); - } - conversationAdminCounts(f) { - return this.client.get('/counts', { type: 'conversation', count: 'admin' }, f); - } - userTagCounts(f) { - return this.client.get('/counts', { type: 'user', count: 'tag' }, f); - } - userSegmentCounts(f) { - return this.client.get('/counts', { type: 'user', count: 'segment' }, f); - } - companyTagCounts(f) { - return this.client.get('/counts', { type: 'company', count: 'tag' }, f); - } - companySegmentCounts(f) { - return this.client.get('/counts', { type: 'company', count: 'segment' }, f); - } - companyUserCounts(f) { - return this.client.get('/counts', { type: 'company', count: 'user' }, f); - } -} diff --git a/lib/customer.js b/lib/customer.js deleted file mode 100644 index f2e8f15b..00000000 --- a/lib/customer.js +++ /dev/null @@ -1,8 +0,0 @@ -export default class Customer { - constructor(client) { - this.client = client; - } - search(params, f) { - return this.client.post('/customers/search', params, f); - } -} diff --git a/lib/dataAttribute.ts b/lib/dataAttribute.ts new file mode 100644 index 00000000..46952d05 --- /dev/null +++ b/lib/dataAttribute.ts @@ -0,0 +1,82 @@ +import { Client } from '.'; +import { + DataAttributeObject, + ModelType, +} from './dataAttribute/dataAttribute.types'; + +export default class DataAttribute { + public readonly baseUrl = 'data_attributes'; + + constructor(private readonly client: Client) { + this.client = client; + } + + create({ + name, + model, + dataType: data_type, + description, + options, + }: CreateDataAttributeData) { + const data = { + name, + model, + data_type, + description, + options, + }; + + return this.client.post({ + url: `/${this.baseUrl}`, + data, + }); + } + update({ archived, description, id, options }: UpdateDataAttributeData) { + const data = { + archived, + description, + options, + }; + + return this.client.put({ + url: `/${this.baseUrl}/${id}`, + data, + }); + } + list({ model, includeArchived: include_archived }: ListDataAttributeData) { + const queryParams = { + model, + include_archived, + }; + + return this.client.get({ + url: `/${this.baseUrl}`, + params: queryParams, + }); + } +} + +interface CreateDataAttributeData { + name: DataAttributeObject['name']; + model: DataAttributeObject['model']; + dataType: DataAttributeObject['data_type']; + description?: DataAttributeObject['description']; + options?: DataAttributeObject['options']; +} + +interface UpdateDataAttributeData { + id: string; + archived?: DataAttributeObject['archived']; + description?: DataAttributeObject['description']; + options?: DataAttributeObject['options']; +} + +interface ListDataAttributeData { + model?: ModelType; + includeArchived?: boolean; +} + +interface ListAllResponse { + type: 'list'; + data: DataAttributeObject[]; +} diff --git a/lib/dataAttribute/dataAttribute.types.ts b/lib/dataAttribute/dataAttribute.types.ts new file mode 100644 index 00000000..4256dd0e --- /dev/null +++ b/lib/dataAttribute/dataAttribute.types.ts @@ -0,0 +1,34 @@ +import { Timestamp } from '../common/common.types'; + +export interface DataAttributeObject { + id: string; + name: string; + full_name: string; + label: string; + description: string; + data_type: DataType; + api_writable: boolean; + ui_writable: boolean; + custom: boolean; + archived: boolean; + model: ModelType; + options: Record<'value', string>[]; + type?: 'data_attribute'; + created_at?: Timestamp; + updated_at?: Timestamp; + admin_id?: string; +} + +export enum ModelType { + CONTACT = 'contact', + COMPANY = 'company', + CONVERSATION = 'conversation', +} + +export enum DataType { + STRING = 'string', + INTEGER = 'integer', + FLOAT = 'float', + BOOLEAN = 'boolean', + DATE = 'date', +} diff --git a/lib/errors/badResponse.error.ts b/lib/errors/badResponse.error.ts new file mode 100644 index 00000000..4688c26c --- /dev/null +++ b/lib/errors/badResponse.error.ts @@ -0,0 +1,15 @@ +import { AxiosResponse } from 'axios'; + +export class BadResponseError extends Error { + constructor( + readonly message: string, + readonly body: AxiosResponse['data'], + readonly headers: AxiosResponse['headers'], + readonly statusCode: AxiosResponse['status'] + ) { + super(message); + this.body = body; + this.headers = headers; + this.statusCode = statusCode; + } +} diff --git a/lib/event.js b/lib/event.js deleted file mode 100644 index cce36bad..00000000 --- a/lib/event.js +++ /dev/null @@ -1,16 +0,0 @@ -import Bulk from './bulk'; - -export default class Event { - constructor(client) { - this.client = client; - } - create(data, f) { - return this.client.post('/events', data, f); - } - listBy(params, f) { - return this.client.get('/events', params, f); - } - bulk(params, f) { - return new Bulk(this.client, 'event').bulk(params, f); - } -} diff --git a/lib/event.ts b/lib/event.ts new file mode 100644 index 00000000..55aac37b --- /dev/null +++ b/lib/event.ts @@ -0,0 +1,87 @@ +import { Client } from '.'; +import { EventObject, SummaryEventObject } from './event/event.types'; + +export default class Event { + public readonly baseUrl = 'events'; + + constructor(private readonly client: Client) { + this.client = client; + } + create({ + eventName: event_name, + createdAt: created_at, + userId: user_id, + id, + email, + metadata, + }: CreateEventData) { + const data: EventObject = { + event_name, + created_at, + user_id, + id, + email, + metadata, + }; + + return this.client.post({ url: `/${this.baseUrl}`, data }); + } + listBy({ + userId: user_id, + email, + intercomUserId: intercom_user_id, + perPage: per_page, + summary, + }: ListParams) { + const params = { + type: 'user', + user_id, + email, + intercom_user_id, + per_page, + summary, + }; + + return summary + ? this.client.get({ + url: `/${this.baseUrl}`, + params, + }) + : this.client.get({ + url: `/${this.baseUrl}`, + params, + }); + } +} + +interface CreateEventData { + eventName: EventObject['event_name']; + createdAt: EventObject['created_at']; + userId?: EventObject['user_id']; + id?: EventObject['id']; + email?: EventObject['email']; + metadata?: EventObject['metadata']; +} +// +interface ListParams { + userId?: EventObject['user_id']; + email?: EventObject['email']; + intercomUserId?: string; + perPage?: number; + summary?: boolean; +} +interface ListParamsResponse { + type: 'event.list'; + events: EventObject[]; + pages: { + next?: string; + since?: string; + }; +} +interface ListParamsWithSummaryResponse { + type: 'event.summary'; + email: string; + intercom_user_id: string; + user_id: string; + events: SummaryEventObject[]; +} diff --git a/lib/event/event.types.ts b/lib/event/event.types.ts new file mode 100644 index 00000000..f10b2e0b --- /dev/null +++ b/lib/event/event.types.ts @@ -0,0 +1,29 @@ +import { Timestamp } from '../common/common.types'; + +export interface SummaryEventObject { + name: string; + first: Date | string; + last: Date | string; + count: number; + description: string | null; +} + +export interface EventObject { + event_name: string; + created_at: Timestamp; + user_id?: string; + id?: string; + email?: string; + metadata?: Metadata; +} + +export interface Metadata { + [x: string]: string | number | RichLink | MonetaryAmount; +} + +type RichLink = { + url: string; + value: string; +}; + +type MonetaryAmount = { amount: number; currency: string }; diff --git a/lib/helpCenter.ts b/lib/helpCenter.ts new file mode 100644 index 00000000..de59e22c --- /dev/null +++ b/lib/helpCenter.ts @@ -0,0 +1,171 @@ +import { Client } from '.'; +import { GenericDeletedResponse, Paginated } from './common/common.types'; +import { + CollectionObject, + GroupTranslatedContentObject, + SectionObject, +} from './helpCenter/helpCenter.types'; + +export default class HelpCenter { + public readonly collections: Collection; + public readonly sections: Section; + + constructor(client: Client) { + this.collections = new Collection(client); + this.sections = new Section(client); + } +} + +class Collection { + public readonly baseUrl = 'help_center/collections'; + + constructor(private readonly client: Client) { + this.client = client; + } + + create({ name, description, translatedContent }: CreateCollectionData) { + const data = { + name, + description, + translated_content: translatedContent, + }; + + return this.client.post({ + url: `/${this.baseUrl}`, + data, + }); + } + find({ id }: CollectionFindByIdData) { + return this.client.get({ + url: `/${this.baseUrl}/${id}`, + }); + } + update({ id, name, description, translatedContent }: UpdateCollectionData) { + const data = { + name, + description, + translated_content: translatedContent, + }; + + return this.client.put({ + url: `/${this.baseUrl}/${id}`, + data, + }); + } + delete({ id }: CollectionDeleteByIdData) { + return this.client.delete({ + url: `/${this.baseUrl}/${id}`, + }); + } + list({ page, perPage: per_page }: CollectionListData) { + const params = { + page, + per_page, + }; + + return this.client.get({ + url: `/${this.baseUrl}`, + params, + }); + } +} + +interface CreateCollectionData { + name: string; + description?: string; + translatedContent?: Omit; +} + +type CollectionFindByIdData = OperationById; + +type UpdateCollectionData = Partial & OperationById; + +type CollectionDeleteByIdData = OperationById; + +type CollectionDeleteByIdResponse = GenericDeletedResponse<'collection'>; + +type CollectionListData = { + page?: number; + perPage?: number; +}; + +type CollectionListResponse = Paginated; + +class Section { + public readonly baseUrl = 'help_center/sections'; + + constructor(private readonly client: Client) { + this.client = client; + } + + create({ name, parentId, translatedContent }: CreateSectionData) { + const data = { + name, + parent_id: parentId, + translated_content: translatedContent, + }; + + return this.client.post({ + url: `/${this.baseUrl}`, + data, + }); + } + find({ id }: SectionFindByIdData) { + return this.client.get({ + url: `/${this.baseUrl}/${id}`, + }); + } + update({ id, name, parentId, translatedContent }: UpdateSectionData) { + const data = { + name, + parent_id: parentId, + translated_content: translatedContent, + }; + + return this.client.put({ + url: `/${this.baseUrl}/${id}`, + data, + }); + } + delete({ id }: SectionDeleteByIdData) { + return this.client.delete({ + url: `/${this.baseUrl}/${id}`, + }); + } + list({ page, perPage: per_page }: SectionListData) { + const params = { + page, + per_page, + }; + + return this.client.get({ + url: `/${this.baseUrl}`, + params, + }); + } +} + +interface CreateSectionData { + name: string; + parentId: string; + translatedContent?: Omit; +} + +type SectionFindByIdData = OperationById; + +type UpdateSectionData = Partial & OperationById; + +type SectionDeleteByIdData = OperationById; + +type SectionDeleteByIdResponse = GenericDeletedResponse<'section'>; + +type SectionListData = { + page?: number; + perPage?: number; +}; + +type SectionListResponse = Paginated; + +interface OperationById { + id: string; +} diff --git a/lib/helpCenter/helpCenter.types.ts b/lib/helpCenter/helpCenter.types.ts new file mode 100644 index 00000000..737ca930 --- /dev/null +++ b/lib/helpCenter/helpCenter.types.ts @@ -0,0 +1,37 @@ +import { ArticleObject, Locales } from '../index'; + +export type CollectionObject = { + type: 'collection'; + name: string; + icon: string; + order: number; +} & Pick< + ArticleObject, + | 'id' + | 'workspace_id' + | 'description' + | 'created_at' + | 'updated_at' + | 'url' + | 'default_locale' + | 'translated_content' +>; + +export type SectionObject = { + type: 'section'; + parent_id: number; +} & Omit; + +export type GroupTranslatedContentObject = { + type: 'group_translated_content'; +} & Partial; + +export type HelpCenterLocalesMapping = { + [key in Locales]: GroupContentObject; +}; + +export type GroupContentObject = { + name: string; + description: string; + type?: 'group_content'; +}; diff --git a/lib/index.js b/lib/index.js deleted file mode 100644 index 25873704..00000000 --- a/lib/index.js +++ /dev/null @@ -1,23 +0,0 @@ -export { default as Client } from './client'; -export { default as User } from './user'; -export { default as Snippet } from './snippet'; -export { default as UserData } from './user-data'; - -import crypto from 'crypto'; - -export class IdentityVerification { - static userHash(params) { - let secretKey = params.secretKey; - let identifier = params.identifier; - if (!secretKey) { - throw new Error('secretKey must be provided'); - } - if (!identifier) { - throw new Error('identifier must be provided'); - } - return crypto - .createHmac('sha256', secretKey) - .update(identifier) - .digest('hex'); - } -} diff --git a/lib/index.ts b/lib/index.ts new file mode 100644 index 00000000..40c8d1be --- /dev/null +++ b/lib/index.ts @@ -0,0 +1,57 @@ +import crypto from 'crypto'; + +export class IdentityVerification { + static userHash({ + secretKey, + identifier, + }: { + secretKey?: string; + identifier?: string; + }) { + if (!secretKey) { + throw new Error('secretKey must be provided'); + } + if (!identifier) { + throw new Error('identifier must be provided'); + } + return crypto + .createHmac('sha256', secretKey) + .update(identifier) + .digest('hex'); + } +} + +export { default as Client } from './client'; + +// Export model types +export * from './admin/admin.types'; +export * from './article/article.types'; +export * from './common/common.types'; +export * from './company/company.types'; +export * from './contact/contact.types'; +export * from './conversation/conversation.types'; +export * from './dataAttribute/dataAttribute.types'; +export * from './event/event.types'; +export * from './helpCenter/helpCenter.types'; +export * from './message/message.types'; +export * from './segment/segment.types'; +export * from './subscription/subscription.types'; +export * from './tag/tag.types'; +export * from './team/team.types'; + +// Export enums needed for requests +export { SearchContactOrderBy } from './contact'; +export { + ReplyToConversationMessageType, + ReplyToConversationUserType, + AssignToConversationMessageType, + AssignToConversationUserType, + SnoozeConversationMessageType, + CloseConversationMessageType, + CloseConversationType, + OpenConversationMessageType, + SearchConversationOrderBy, + SortBy, + RedactConversationPartType, +} from './conversation'; +export { RecepientType } from './message'; diff --git a/lib/message.js b/lib/message.js deleted file mode 100644 index a0662a0e..00000000 --- a/lib/message.js +++ /dev/null @@ -1,8 +0,0 @@ -export default class Message { - constructor(client) { - this.client = client; - } - create(data, f) { - return this.client.post('/messages', data, f); - } -} diff --git a/lib/message.ts b/lib/message.ts new file mode 100644 index 00000000..550e43b7 --- /dev/null +++ b/lib/message.ts @@ -0,0 +1,57 @@ +import { Client } from '.'; +import { MessageObject, MessageType } from './message/message.types'; + +export default class Message { + private messagesBaseUrl = 'messages'; + + constructor(private readonly client: Client) { + this.client = client; + } + + create({ + messageType: message_type, + subject, + body, + template, + from, + to, + }: CreateMessageBody) { + const data: CreateMessageRequest = { + message_type, + subject, + body, + template, + from, + to, + }; + + return this.client.post({ + url: `/${this.messagesBaseUrl}`, + data, + }); + } +} + +interface CreateMessageRequest { + message_type: MessageType; + body: string; + from: Recepient; + to: Recepient; + subject?: string; + template?: string; +} + +interface CreateMessageBody extends Omit { + messageType: MessageType; +} + +type Recepient = { + id: string; + type: RecepientType; +}; + +export enum RecepientType { + ADMIN = 'admin', + USER = 'user', + LEAD = 'lead', +} diff --git a/lib/message/message.types.ts b/lib/message/message.types.ts new file mode 100644 index 00000000..fe84adb0 --- /dev/null +++ b/lib/message/message.types.ts @@ -0,0 +1,18 @@ +import { Timestamp } from '../common/common.types'; + +export interface MessageObject { + type: string; + id: string; + created_at: Timestamp; + subject?: string; + body: string; + message_type: MessageType; + conversation_id?: string; +} + +export enum MessageType { + EMAIL = 'email', + INAPP = 'inapp', + FACEBOOK = 'facebook', + TWITTER = 'twitter', +} diff --git a/lib/note.js b/lib/note.js deleted file mode 100644 index 99ab1b10..00000000 --- a/lib/note.js +++ /dev/null @@ -1,14 +0,0 @@ -export default class Note { - constructor(client) { - this.client = client; - } - create(params, f) { - return this.client.post('/notes', params, f); - } - list(params, f) { - return this.client.get('/notes', params, f); - } - find(params, f) { - return this.client.get(`/notes/${params.id}`, {}, f); - } -} diff --git a/lib/scroll.js b/lib/scroll.js deleted file mode 100644 index 75c3e06b..00000000 --- a/lib/scroll.js +++ /dev/null @@ -1,49 +0,0 @@ -import Bluebird from 'bluebird'; - -export default class Scroll { - constructor(client, dataType) { - this.client = client; - this.dataType = dataType; - } - each(params, f) { - var self = this; - this.scroll_param = undefined; - - return new Bluebird(function (resolve, reject) { - self.eachInternal(params, f, { resolve, reject }); - }); - } - eachInternal(params, f, promise) { - var self = this; - this.client.get(this.scrollUrl(), params) - .then(function (response) { - var result = f(response); - if (response.body[`${self.dataType}s`].length > 0) { - self.scroll_param = response.body.scroll_param; - if (result && 'then' in result && typeof result.then === 'function') { - result.then(function () { - self.eachInternal(params, f, promise); - }, function (error) { - promise.reject(error); - }); - } else { - self.eachInternal(params, f, promise); - } - - } else { - promise.resolve(); - } - }) - .catch(function (error) { - promise.reject(error); - }); - } - scrollUrl() { - const dataType = this.dataType; - if (typeof this.scroll_param !== 'undefined') { - return `/${dataType}s/scroll?scroll_param=${this.scroll_param}`; - } else { - return `/${dataType}s/scroll`; - } - } -} diff --git a/lib/scroll.ts b/lib/scroll.ts new file mode 100644 index 00000000..0657f0c4 --- /dev/null +++ b/lib/scroll.ts @@ -0,0 +1,67 @@ +import { Client } from '.'; + +export default class Scroll { + constructor( + private readonly client: Client, + private readonly scrollUrlDataType: string, + private scrollParam?: string + ) { + this.client = client; + this.scrollParam = scrollParam; + } + + async each(params: EachData): Promise { + this.scrollParam = params.scrollParam ?? undefined; + + return this.eachInternal(); + } + + async eachInternal(storedData: EntityType[] = []): Promise { + const response = await this.client.get>({ + url: this.scrollUrl(), + }); + const dataFromResponse = response.data; + const combinedData = [...dataFromResponse, ...storedData]; + + if (dataFromResponse.length > 0) { + this.scrollParam = response.scroll_param; + return this.eachInternal(combinedData); + } + + return combinedData; + } + + async next({ + scrollParam, + }: NextData): Promise> { + this.scrollParam = scrollParam; + + const response = await this.client.get>({ + url: this.scrollUrl(), + }); + + return response; + } + + scrollUrl() { + const baseScrollUrl = `/${this.scrollUrlDataType}/scroll`; + + return this.scrollParam && this.scrollParam.length > 0 + ? `${baseScrollUrl}?scroll_param=${this.scrollParam}` + : baseScrollUrl; + } +} + +interface ScrollableResponse { + type: 'list'; + data: EntityType[]; + pages: number | null; + total_count: number | null; + scroll_param?: string; +} + +interface EachData { + scrollParam?: string; +} + +type NextData = EachData; diff --git a/lib/segment.js b/lib/segment.js deleted file mode 100644 index 51a09276..00000000 --- a/lib/segment.js +++ /dev/null @@ -1,11 +0,0 @@ -export default class Segment { - constructor(client) { - this.client = client; - } - list(f) { - return this.client.get('/segments', {}, f); - } - find(params, f) { - return this.client.get(`/segments/${params.id}`, {}, f); - } -} diff --git a/lib/segment.ts b/lib/segment.ts new file mode 100644 index 00000000..c0a1f775 --- /dev/null +++ b/lib/segment.ts @@ -0,0 +1,39 @@ +import { Client } from '.'; +import { SegmentObject } from './segment/segment.types'; + +export default class Segment { + public readonly baseUrl = 'segments'; + + constructor(private readonly client: Client) { + this.client = client; + } + list({ includeCount: include_count }: ListData) { + const params = { include_count }; + + return this.client.get({ + url: `/${this.baseUrl}`, + params, + }); + } + find({ id, includeCount: include_count }: FindSegmentData) { + const params = { include_count }; + + return this.client.get({ + url: `/${this.baseUrl}/${id}`, + params, + }); + } +} + +interface ListData { + includeCount?: boolean; +} +interface ListResponse { + type: 'segment.list'; + segments: SegmentObject[]; +} +// +interface FindSegmentData { + id: string; + includeCount?: boolean; +} diff --git a/lib/segment/segment.types.ts b/lib/segment/segment.types.ts new file mode 100644 index 00000000..7e5bca61 --- /dev/null +++ b/lib/segment/segment.types.ts @@ -0,0 +1,11 @@ +import { Role, Timestamp } from '../common/common.types'; + +export type SegmentObject = { + type: 'segment'; + id: string; + name: string; + created_at: Timestamp; + updated_at: Timestamp; + person_type: Role; + count?: number; +}; diff --git a/lib/snippet.js b/lib/snippet.js deleted file mode 100644 index b9461cae..00000000 --- a/lib/snippet.js +++ /dev/null @@ -1,79 +0,0 @@ -import { IdentityVerification } from './index'; -import htmlencode from 'htmlencode'; - -export default class Snippet { - constructor(settings) { - this.loggedOut = !settings.user_id && !settings.email; - - if (!settings.app_id) { - throw new Error('You must provide an app_id in your Intercom settings'); - } - if (!this.loggedOut && !settings.verificationSecret) { - throw new Error('You must provide your verification secret in your Intercom settings'); - } - - this.settings = settings; - } - create() { - const verificationSecret = this.getVerificationSecret(); - const identifier = this.getIdentifier(); - this.setUserHash(verificationSecret, identifier); - return this.generateSnippetHTML(); - } - getVerificationSecret() { - const { verificationSecret } = this.settings; - delete this.settings.verificationSecret; - return verificationSecret; - } - getIdentifier() { - if (this.settings.user_id) { - return this.settings.user_id.toString(); - } else { - return this.settings.email; - } - } - setUserHash(verificationSecret, identifier) { - if (this.loggedOut) { - return; - } - - const userHash = IdentityVerification.userHash({ - secretKey: verificationSecret, - identifier - }); - this.settings.user_hash = userHash; - } - generateSnippetHTML() { - return ` - - - `; - } - settingsToString(settings) { - const intercomSettings = []; - Object.keys(settings).map(key => { - if (typeof settings[key] === 'object' && settings[key] !== null) { - intercomSettings.push(`${key}: { ${this.settingsToString(settings[key])} }`); - } else { - const escapedKey = this.escapeString(key); - const value = this.escapeString(settings[key]); - if (typeof settings[key] === 'string') { - intercomSettings.push(`${escapedKey}: "${value}"`); - } else { - intercomSettings.push(`${escapedKey}: ${value}`); - } - } - }); - return intercomSettings.join(', '); - } - escapeString(string) { - if (typeof string === 'string') { - string = htmlencode.htmlEncode(string).replace(/\"/gi, '\\"'); - } - return string; - } -} diff --git a/lib/subscription/subscription.types.ts b/lib/subscription/subscription.types.ts new file mode 100644 index 00000000..f39f687b --- /dev/null +++ b/lib/subscription/subscription.types.ts @@ -0,0 +1,20 @@ +export type SubscriptionObject = { + type: 'subscription'; + id: string; + state: SubscriptionState; + default_translation: TranslationObject; + translations: TranslationObject[]; + consent_type: 'opt_out'; +}; + +export enum SubscriptionState { + ARCHIVED = 'archived', + DRAFT = 'draft', + LIVE = 'live', +} + +export type TranslationObject = { + name: string; + description: string; + locale: string; +}; diff --git a/lib/tag.js b/lib/tag.js deleted file mode 100644 index 640ef8b8..00000000 --- a/lib/tag.js +++ /dev/null @@ -1,26 +0,0 @@ -export default class Tag { - constructor(client) { - this.client = client; - } - create(data, f) { - return this.client.post('/tags', data, f); - } - tag(data, f) { - return this.client.post('/tags', data, f); - } - untag(data, f) { - (data.users || []).forEach(user => { - user.untag = true; - }); - (data.companies || []).forEach(company => { - company.untag = true; - }); - return this.client.post('/tags', data, f); - } - delete(params, f) { - return this.client.delete(`/tags/${params.id}`, {}, f); - } - list(f) { - return this.client.get('/tags', {}, f); - } -} diff --git a/lib/tag.ts b/lib/tag.ts new file mode 100644 index 00000000..a72cc598 --- /dev/null +++ b/lib/tag.ts @@ -0,0 +1,142 @@ +import { Client } from '.'; +import { TagObject } from './tag/tag.types'; + +export default class Tag { + private tagsBaseUrl = 'tags'; + + constructor(private readonly client: Client) { + this.client = client; + } + + create(data: CreateTagData) { + return this.client.post({ + url: `/${this.tagsBaseUrl}`, + data, + }); + } + update(data: UpdateTagData) { + return this.client.post({ + url: `/${this.tagsBaseUrl}`, + data, + }); + } + delete({ id }: DeleteTagData) { + return this.client.delete({ + url: `/${this.tagsBaseUrl}/${id}`, + }); + } + tagContact({ contactId, tagId }: TagContactData) { + const data = { + id: tagId, + }; + return this.client.post({ + url: `/${this.client.contacts.baseUrl}/${contactId}/${this.tagsBaseUrl}`, + data, + }); + } + tagConversation({ + conversationId, + tagId, + adminId: admin_id, + }: TagConversationData) { + const data = { + id: tagId, + admin_id, + }; + + return this.client.post({ + url: `/${this.client.conversations.baseUrl}/${conversationId}/${this.tagsBaseUrl}`, + data, + }); + } + tagCompanies({ tagName: name, companiesIds }: TagCompaniesData) { + const data = { + name, + companies: companiesIds.map((id) => ({ id })), + }; + + return this.client.post({ + url: `/${this.tagsBaseUrl}`, + data, + }); + } + untagContact({ contactId, tagId }: UntagContactData) { + return this.client.delete({ + url: `/${this.client.contacts.baseUrl}/${contactId}/${this.tagsBaseUrl}/${tagId}`, + }); + } + untagConversation({ + conversationId, + tagId, + adminId: admin_id, + }: UntagConversationData) { + const data = { + id: tagId, + admin_id, + }; + + return this.client.delete({ + url: `/${this.client.conversations.baseUrl}/${conversationId}/${this.tagsBaseUrl}/${tagId}`, + data, + }); + } + untagCompanies({ tagName: name, companiesIds }: UntagCompaniesData) { + const data = { + name, + companies: companiesIds.map((id) => ({ id, untag: true })), + }; + + return this.client.post({ + url: `/${this.tagsBaseUrl}`, + data, + }); + } + list() { + return this.client.get({ + url: `/${this.tagsBaseUrl}`, + }); + } +} + +interface CreateTagData { + name: string; +} +// +interface UpdateTagData extends CreateTagData { + id: string; +} +// +interface DeleteTagData { + id: string; +} +// +interface TagContactData { + contactId: string; + tagId: string; +} +// +interface TagConversationData { + conversationId: string; + tagId: string; + adminId: string; +} +// +interface TagCompaniesData { + tagName: string; + companiesIds: string[]; +} +// +type UntagContactData = TagContactData; +// +interface UntagConversationData { + tagId: string; + conversationId: string; + adminId: string; +} +// +type UntagCompaniesData = TagCompaniesData; +// +interface ListAllTagsResponse { + type: 'list'; + data: Array; +} diff --git a/lib/tag/tag.types.ts b/lib/tag/tag.types.ts new file mode 100644 index 00000000..b55c8923 --- /dev/null +++ b/lib/tag/tag.types.ts @@ -0,0 +1,5 @@ +export interface TagObject { + id: string; + name: string; + type: 'tag'; +} diff --git a/lib/team.ts b/lib/team.ts new file mode 100644 index 00000000..5170acda --- /dev/null +++ b/lib/team.ts @@ -0,0 +1,31 @@ +import { Client } from '.'; +import { TeamObject } from './team/team.types'; + +export default class Team { + private readonly baseUrl = 'teams'; + + constructor(private readonly client: Client) { + this.client = client; + } + + find({ id }: FindTeamData) { + return this.client.get({ + url: `/${this.baseUrl}/${id}`, + }); + } + + list() { + return this.client.get({ + url: `/${this.baseUrl}`, + }); + } +} + +interface FindTeamData { + id: string; +} + +interface ListTeamsResponse { + type: 'team.list'; + teams: TeamObject[]; +} diff --git a/lib/team/team.types.ts b/lib/team/team.types.ts new file mode 100644 index 00000000..6ff6b700 --- /dev/null +++ b/lib/team/team.types.ts @@ -0,0 +1,6 @@ +export interface TeamObject { + type: 'team'; + id: string; + name: string; + admin_ids: string[]; +} diff --git a/lib/user-data.js b/lib/user-data.js deleted file mode 100644 index 5bd50433..00000000 --- a/lib/user-data.js +++ /dev/null @@ -1,62 +0,0 @@ -import { IdentityVerification } from './index'; -import htmlencode from 'htmlencode'; - -export default class UserData { - constructor(settings) { - this.loggedOut = !settings.user_id && !settings.email; - - if (!settings.app_id) { - throw new Error('You must provide an app_id in your Intercom settings'); - } - if (!this.loggedOut && !settings.verificationSecret) { - throw new Error('You must provide your verification secret in your Intercom settings'); - } - - this.settings = settings; - } - json() { - this.setUserHash(); - return this.escapedSettings(this.settings); - } - getVerificationSecret() { - const { verificationSecret } = this.settings; - delete this.settings.verificationSecret; - return verificationSecret; - } - setUserHash() { - if (this.loggedOut || this.settings.user_hash !== undefined) { - return; - } - - const { verificationSecret } = this.settings; - delete this.settings.verificationSecret; - const identifier = this.settings.user_id ? this.settings.user_id.toString() : this.settings.email; - - - const userHash = IdentityVerification.userHash({ - secretKey: verificationSecret, - identifier - }); - - this.settings.user_hash = userHash; - } - escapedSettings(settings) { - const intercomSettings = {}; - Object.keys(settings).map(key => { - if (typeof settings[key] === 'object' && settings[key] !== null) { - intercomSettings[key] = this.escapedSettings(settings[key]); - } else { - const escapedKey = this.escapeString(key); - const value = this.escapeString(settings[key]); - intercomSettings[escapedKey] = value; - } - }); - return intercomSettings; - } - escapeString(string) { - if (typeof string === 'string') { - string = htmlencode.htmlEncode(string).replace(/\"/gi, '\\"'); - } - return string; - } -} diff --git a/lib/user.js b/lib/user.js deleted file mode 100644 index 0cf0c233..00000000 --- a/lib/user.js +++ /dev/null @@ -1,64 +0,0 @@ -import Bulk from './bulk'; -import Scroll from './scroll'; -import { deprecate } from 'util'; - -export default class User { - constructor(client) { - this.client = client; - this.scroll = new Scroll(this.client, 'user'); - - // Keep this API around but mark it deprecated - this.delete = deprecate(this.archive.bind(this), 'intercom-client - user.delete: Use user.archive instead'); - } - create(data, f) { - return this.client.post('/users', data, f); - } - update(data, f) { - return this.create(data, f); - } - list(f) { - return this.client.get('/users', {}, f); - } - listBy(params, f) { - return this.client.get('/users', params, f); - } - find(params, f) { - if (params.id) { - return this.client.get(`/users/${params.id}`, {}, f); - } else if (params.user_id) { - return this.client.get('/users', { user_id: params.user_id }, f); - } else if (params.email) { - return this.client.get('/users', { email: params.email }, f); - } - } - archive(params, f) { - if (params.id) { - return this.client.delete(`/users/${params.id}`, {}, f); - } else if (params.user_id) { - return this.client.delete('/users', { user_id: params.user_id }, f); - } else if (params.email) { - return this.client.delete('/users', { email: params.email }, f); - } - } - bulk(params, f) { - return new Bulk(this.client, 'user').bulk(params, f); - } - requestPermanentDeletion(intercom_user_id, f) { - return this.client.post('/user_delete_requests', { intercom_user_id }, f); - } - requestPermanentDeletionByParams(params, f) { - if (params.id) { - return this.requestPermanentDeletion(params.id, f); - } - - return this.find(params) - .then((res) => this.requestPermanentDeletion(res.body.id, f)) - .catch((err) => { - if (f) { - return f(err); - } - - throw err; - }); - } -} diff --git a/lib/util/time.ts b/lib/util/time.ts new file mode 100644 index 00000000..5c93eb13 --- /dev/null +++ b/lib/util/time.ts @@ -0,0 +1,3 @@ +import { Timestamp } from "../common/common.types"; + +export const dateToUnixTimestamp = (date: Date): Timestamp => Math.floor(date.getTime() / 1000); diff --git a/lib/util/url.ts b/lib/util/url.ts new file mode 100644 index 00000000..b5b049e1 --- /dev/null +++ b/lib/util/url.ts @@ -0,0 +1,10 @@ +import { URLSearchParams } from 'url'; +import { omitBy, isEmpty } from 'lodash'; + +export const encodeParamsForURL = ( + params: Record> +): URLSearchParams => new URLSearchParams(purifyFromEmptiness(params)); + +const purifyFromEmptiness = ( + object: Record> +): Record> => omitBy(object, isEmpty); diff --git a/lib/visitor.js b/lib/visitor.js deleted file mode 100644 index 9ab6e538..00000000 --- a/lib/visitor.js +++ /dev/null @@ -1,21 +0,0 @@ -export default class Visitor { - constructor(client) { - this.client = client; - } - update(params, f) { - return this.client.post('/visitors', params, f); - } - find(params, f) { - if (params.id) { - return this.client.get(`/visitors/${params.id}`, {}, f); - } else if (params.user_id) { - return this.client.get('/visitors', { user_id: params.user_id }, f); - } - } - delete(params, f) { - return this.client.delete(`/visitors/${params.id}`, {}, f); - } - convert(params, f) { - return this.client.post('/visitors/convert', params, f); - } -} diff --git a/package.json b/package.json index 31354e3b..3e3ca7aa 100644 --- a/package.json +++ b/package.json @@ -1,51 +1,59 @@ { - "name": "intercom-client", - "version": "2.11.2", - "description": "Official Node bindings to the Intercom API", - "homepage": "https://github.com/intercom/intercom-node", - "bugs:": "https://github.com/intercom/intercom-node/issues", - "repository": "intercom/intercom-node", - "author": { - "name": "Bob Long", - "email": "bob@intercom.io" - }, - "files": [ - "dist" - ], - "main": "dist/index.js", - "keywords": [ - "intercom", - "api" - ], - "dependencies": { - "bluebird": "^3.7.2", - "htmlencode": "^0.0.4", - "lodash": "^4.17.19", - "request": "^2.88.0" - }, - "devDependencies": { - "@babel/core": "^7.13.16", - "@babel/preset-env": "^7.13.15", - "@babel/register": "^7.13.16", - "babel-eslint": "^10.0.2", - "eslint": "^6.8.0", - "gulp": "^4.0.2", - "gulp-babel": "^8.0.0", - "gulp-cli": "^2.2.0", - "gulp-eslint": "4.0.2", - "gulp-exclude-gitignore": "^1.0.0", - "gulp-istanbul": "^1.1.3", - "gulp-mocha": "^6.0.0", - "gulp-plumber": "^1.2.1", - "nock": "^13.0.11", - "sinon": "^7.3.2" - }, - "scripts": { - "prepublish": "gulp prepublish", - "test": "gulp" - }, - "engines": { - "node": ">= v0.10.0" - }, - "license": "Apache-2.0" + "name": "intercom-client", + "version": "3.0.0", + "description": "Official Node bindings to the Intercom API", + "homepage": "https://github.com/intercom/intercom-node", + "bugs:": "https://github.com/intercom/intercom-node/issues", + "repository": "intercom/intercom-node", + "author": { + "name": "Bob Long", + "email": "bob@intercom.io" + }, + "files": [ + "dist" + ], + "main": "dist/index.js", + "keywords": [ + "intercom", + "api" + ], + "dependencies": { + "axios": "^0.24.0", + "htmlencode": "^0.0.4", + "lodash": "^4.17.21" + }, + "devDependencies": { + "@istanbuljs/nyc-config-typescript": "^1.0.2", + "@types/lodash": "^4.14.176", + "@types/mocha": "^9.1.0", + "@types/node": "^16.11.6", + "@types/sinon": "^10.0.6", + "@typescript-eslint/eslint-plugin": "^5.7.0", + "@typescript-eslint/parser": "^5.7.0", + "eslint": "^8.2.0", + "eslint-config-prettier": "^8.3.0", + "merge2": "^1.4.1", + "mocha": "^9.2.0", + "nock": "^13.0.11", + "nyc": "^15.1.0", + "prettier": "^2.5.1", + "sinon": "^7.3.2", + "ts-node": "^10.4.0", + "tslib": "^2.3.1", + "typescript": "^4.5.3" + }, + "scripts": { + "clean": "rm -r dist", + "static": "eslint .", + "compile_ts": "tsc", + "move_compiled_to_dist": "mv dist/lib/* dist && rmdir dist/lib", + "prepublish": "yarn clean && yarn static && yarn compile_ts && yarn move_compiled_to_dist", + "test": "mocha -r ts-node/register test/*.ts", + "coverage": "nyc yarn test" + }, + "engines": { + "node": ">= v8.0.0" + }, + "license": "Apache-2.0", + "packageManager": "yarn@3.1.1" } diff --git a/test/admin.js b/test/admin.js deleted file mode 100644 index 3a5029cc..00000000 --- a/test/admin.js +++ /dev/null @@ -1,38 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('admins', () => { - it('should be listed', done => { - nock('https://api.intercom.io').get('/admins').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.admins.list().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should find current admin', done => { - nock('https://api.intercom.io').get('/me').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.admins.me().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should find admins by id', done => { - nock('https://api.intercom.io').get('/admins/baz').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.admins.find('baz').then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should update admin away mode and reassign settings', done => { - nock('https://api.intercom.io').put('/admins/baz/away', { away_mode_enabled: true, away_mode_reassign: false }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.admins.away('baz', { away_mode_enabled: true, away_mode_reassign: false }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); -}); diff --git a/test/admin.ts b/test/admin.ts new file mode 100644 index 00000000..90246842 --- /dev/null +++ b/test/admin.ts @@ -0,0 +1,64 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; + +describe('admins', () => { + it('should find admins by id', async () => { + nock('https://api.intercom.io').get('/admins/baz').reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.admins.find({ id: 'baz' }); + + assert.deepStrictEqual({}, response); + }); + it('should set an admin away', async () => { + const id = 'baz'; + const requestData = { + away_mode_enabled: true, + away_mode_reassign: false, + }; + + nock('https://api.intercom.io') + .put(`/admins/${id}/away`, requestData) + .reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.admins.away({ + adminId: id, + enableAwayMode: true, + enableReassignMode: false, + }); + + assert.deepStrictEqual({}, response); + }); + it('should list all activites logs', async () => { + const date = new Date('Fri, 17 Dec 2021 18:02:18 GMT'); + const dateInUnix = '1639764138'; + + nock('https://api.intercom.io') + .get( + `/admins/activity_logs?created_at_after=${dateInUnix}&created_at_before=${dateInUnix}` + ) + .reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.admins.listAllActivityLogs({ + before: date, + after: date, + }); + + assert.deepStrictEqual({}, response); + }); + it('should list all', async () => { + nock('https://api.intercom.io').get('/admins').reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.admins.list(); + + assert.deepStrictEqual({}, response); + }); +}); diff --git a/test/article.ts b/test/article.ts new file mode 100644 index 00000000..b52028a0 --- /dev/null +++ b/test/article.ts @@ -0,0 +1,113 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; + +describe('articles', () => { + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + it('creates article', async () => { + const requestData = { + title: 'Thanks for everything', + description: 'English description', + body: '

This is the body in html

', + author_id: 1, + state: 'published', + parent_id: 1, + parent_type: 'collection', + translated_content: { + fr: { + title: 'Allez les verts', + description: 'French description', + body: '

French body in html

', + author_id: 1, + state: 'published', + }, + }, + }; + nock('https://api.intercom.io').post('/articles').reply(200, {}); + const response = await client.articles.create({ + title: requestData.title, + description: requestData.description, + body: requestData.body, + authorId: requestData.author_id, + state: requestData.state, + parentId: requestData.parent_id, + parentType: requestData.parent_type, + translatedContent: requestData.translated_content, + }); + + assert.deepStrictEqual({}, response); + }); + it('retrieves an article', async () => { + const id = 'baz'; + + nock('https://api.intercom.io').get(`/articles/${id}`).reply(200, {}); + + const response = await client.articles.find({ id }); + + assert.deepStrictEqual({}, response); + }); + it('updates an article', async () => { + const id = 'baz'; + const requestData = { + title: 'Thanks for everything', + description: 'English description', + body: '

This is the body in html

', + author_id: 1, + state: 'published', + parent_id: 1, + parent_type: 'collection', + translated_content: { + fr: { + title: 'Allez les verts', + description: 'French description', + body: '

French body in html

', + author_id: 1, + state: 'published', + }, + }, + }; + nock('https://api.intercom.io').put(`/articles/${id}`).reply(200, {}); + const response = await client.articles.update({ + id, + title: requestData.title, + description: requestData.description, + body: requestData.body, + authorId: requestData.author_id, + state: requestData.state, + parentId: requestData.parent_id, + parentType: requestData.parent_type, + translatedContent: requestData.translated_content, + }); + + assert.deepStrictEqual({}, response); + }); + it('deletes an article', async () => { + const id = 'baz'; + nock('https://api.intercom.io') + .delete(`/articles/${id}`) + .reply(200, {}); + + const response = await client.articles.delete({ + id, + }); + + assert.deepStrictEqual({}, response); + }); + it('lists all', async () => { + const requestQuery = { page: 3, per_page: 12 }; + + nock('https://api.intercom.io') + .get('/articles') + .query(requestQuery) + .reply(200, {}); + + const response = await client.articles.list({ + page: requestQuery.page, + perPage: requestQuery.per_page, + }); + + assert.deepStrictEqual({}, response); + }); +}); diff --git a/test/bulk.js b/test/bulk.js deleted file mode 100644 index e92b596c..00000000 --- a/test/bulk.js +++ /dev/null @@ -1,62 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('bulk', () => { - it('should send bulk users', done => { - nock('https://api.intercom.io').post('/bulk/users', { - items: [ - { - method: 'post', - data_type: 'user', - data: { - email: 'wash@serenity.io' - } - }, - { - method: 'post', - data_type: 'user', - data: { - email: 'mal@serenity.io' - } - } - ] - }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.users.bulk([ - { create: { email: 'wash@serenity.io' }}, - { create: { email: 'mal@serenity.io'}} - ]).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should send bulk events', done => { - nock('https://api.intercom.io').post('/bulk/events', { - items: [ - { - method: 'post', - data_type: 'event', - data: { - foo: 'bar' - } - }, - { - method: 'post', - data_type: 'event', - data: { - bar: 'baz' - } - } - ] - }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.events.bulk([ - { create: { foo: 'bar' }}, - { create: { bar: 'baz'}} - ]).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); -}); diff --git a/test/client.js b/test/client.js deleted file mode 100644 index 180b1f87..00000000 --- a/test/client.js +++ /dev/null @@ -1,76 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('clients', () => { - it('should resolve promises', done => { - nock('https://api.intercom.io').get('/users').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - assert.equal(true, client.promises); - client.users.list().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should use promises when callbacks are absent', done => { - nock('https://api.intercom.io').get('/users').reply(200, {}); - const client = new Client('foo', 'bar'); - client.users.list().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should reject promises', done => { - nock('https://api.intercom.io').get('/users').reply(200, {type: 'error.list'}); - const client = new Client('foo', 'bar').usePromises(); - assert.equal(true, client.promises); - client.users.list().catch(err => { - assert.deepStrictEqual({ type: 'error.list' }, err.body); - done(); - }); - }); - it('should reject promises with error objects', done => { - nock('https://api.intercom.io').get('/users').reply(200, {type: 'error.list'}); - const client = new Client('foo', 'bar').usePromises(); - client.users.list().catch(err => { - assert.equal(true, err instanceof Error); - done(); - }); - }); - it('should callback with errors', done => { - const callback = function (err, d) { - assert.equal('error.list', err.body.type); - assert.equal(null, d); - done(); - }; - const client = new Client('foo', 'bar'); - client.callback(callback, { body: { type: 'error.list' }}); - }); - it('should not crash if the callback is missing', () => { - const client = new Client('foo', 'bar'); - assert.doesNotThrow(() => { - client.callback(); - }); - }); - it('should construct with two fields', () => { - const client = new Client('foo', 'bar'); - assert.equal('foo', client.usernamePart); - assert.equal('bar', client.passwordPart); - }); - it('should construct with an object', () => { - const client = new Client({ appId: 'foo', appApiKey: 'bar' }); - assert.equal('foo', client.usernamePart); - assert.equal('bar', client.passwordPart); - }); - it('should construct with an object containing an OAuth token', () => { - const client = new Client({ token: 'foo' }); - assert.equal('foo', client.usernamePart); - assert.equal('', client.passwordPart); - }); - it('should throw if no credentials found', () => { - assert.throws(() => { - const client = new Client('baz'); - console.log(client.usernamePart); - }, /Could not construct a client with those parameters/); - }); -}); diff --git a/test/client.ts b/test/client.ts new file mode 100644 index 00000000..79f5bc94 --- /dev/null +++ b/test/client.ts @@ -0,0 +1,69 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; + +describe('clients', () => { + it('should resolve promises', async () => { + nock('https://api.intercom.io').get('/admins').reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.admins.list(); + + assert.deepStrictEqual({}, response); + }); + it('should reject promises', async () => { + nock('https://api.intercom.io') + .get('/admins') + .reply(200, { type: 'error.list' }); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + try { + await client.admins.list(); + } catch (err) { + assert.deepStrictEqual({ type: 'error.list' }, err.body); + } + }); + it('should reject promises with error objects', async () => { + nock('https://api.intercom.io') + .get('/admins') + .reply(200, { type: 'error.list' }); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + try { + await client.admins.list(); + } catch (err) { + assert.equal(true, err instanceof Error); + } + }); + it('should construct with two fields', () => { + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + assert.equal('foo', client.usernamePart); + assert.equal('bar', client.passwordPart); + }); + it('should construct with an object', () => { + const client = new Client({ + apiKeyAuth: { appId: 'foo', appApiKey: 'bar' }, + }); + assert.equal('foo', client.usernamePart); + assert.equal('bar', client.passwordPart); + }); + it('should construct with an object containing an OAuth token', () => { + const client = new Client({ tokenAuth: { token: 'foo' } }); + assert.equal('foo', client.usernamePart); + assert.equal('', client.passwordPart); + }); + it('should throw if no credentials found', () => { + assert.throws(() => { + const client = new Client({}); + console.log(client.usernamePart); + }, /Could not construct a client with those parameters/); + }); +}); diff --git a/test/company.js b/test/company.js deleted file mode 100644 index 32a601c4..00000000 --- a/test/company.js +++ /dev/null @@ -1,78 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('companies', () => { - it('should be created', done => { - nock('https://api.intercom.io').post('/companies', { name: 'baz' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.companies.create({ name: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should list', done => { - nock('https://api.intercom.io').get('/companies').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.companies.list().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should list by params', done => { - nock('https://api.intercom.io').get('/companies').query({ tag_id: '1234' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.companies.listBy({ tag_id: '1234' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should find companies by id', done => { - nock('https://api.intercom.io').get('/companies/baz').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.companies.find({ id: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should find companies by company_id', done => { - nock('https://api.intercom.io').get('/companies').query({ company_id: 'baz' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.companies.find({ company_id: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should find companies by name', done => { - nock('https://api.intercom.io').get('/companies').query({ name: 'baz' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.companies.find({ name: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should list company users by id', done => { - nock('https://api.intercom.io').get('/companies/baz/users').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.companies.listUsers({ id: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should list company users by company_id', done => { - nock('https://api.intercom.io').get('/companies').query({ company_id: 'baz', type: 'user' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.companies.listUsers({ company_id: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should list company users by company name', done => { - nock('https://api.intercom.io').get('/companies').query({ name: 'baz', type: 'user' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.companies.listUsers({ name: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); -}); diff --git a/test/company.ts b/test/company.ts new file mode 100644 index 00000000..8725f965 --- /dev/null +++ b/test/company.ts @@ -0,0 +1,260 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; +import { dateToUnixTimestamp } from '../lib/util/time'; +import { Order } from '../lib/common/common.types'; + +const dummyCompany = { + type: 'company', + company_id: 'dummy-company', + id: '59yo', + app_id: 'einszweidrei', + name: 'Bitconeeeeeeect', + created_at: 1509716268, + updated_at: 1509977818, + last_request_at: 1506274700, + monthly_spend: 0, + session_count: 0, + user_count: 1, + tags: { + type: 'tag.list', + tags: [], + }, + segments: { + type: 'segment.list', + segments: [], + }, + plan: {}, + custom_attributes: {}, +}; +describe('companies', () => { + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + it('should be created', async () => { + const requestBody = { + remote_created_at: dateToUnixTimestamp(new Date()), + company_id: '46029', + name: 'BestCompanyInc.', + monthly_spend: 9001, + plan: '1. Get pizzaid', + size: 62049, + website: 'http://the-best.one', + industry: 'The Best One', + custom_attributes: {}, + }; + + nock('https://api.intercom.io') + .post('/companies', requestBody) + .reply(200, {}); + + const response = await client.companies.create({ + createdAt: requestBody.remote_created_at, + companyId: requestBody.company_id, + name: requestBody.name, + monthlySpend: requestBody.monthly_spend, + plan: requestBody.plan, + size: requestBody.size, + website: requestBody.website, + industry: requestBody.industry, + customAttributes: requestBody.custom_attributes, + }); + + assert.deepStrictEqual({}, response); + }); + it('should be updated', async () => { + const company_id = '46029'; + const requestBody = { + remote_created_at: dateToUnixTimestamp(new Date()), + name: 'BestCompanyInc.', + monthly_spend: 9001, + plan: '1. Get pizzaid', + size: 62049, + website: 'http://the-best.one', + industry: 'The Best One', + custom_attributes: {}, + }; + + nock('https://api.intercom.io') + .put(`/companies/${company_id}`, requestBody) + .reply(200, {}); + + const response = await client.companies.update({ + createdAt: requestBody.remote_created_at, + companyId: company_id, + name: requestBody.name, + monthlySpend: requestBody.monthly_spend, + plan: requestBody.plan, + size: requestBody.size, + website: requestBody.website, + industry: requestBody.industry, + customAttributes: requestBody.custom_attributes, + }); + + assert.deepStrictEqual({}, response); + }); + it('should find companies by company_id', async () => { + const queryData = { + company_id: 'baz', + }; + nock('https://api.intercom.io') + .get('/companies') + .query(queryData) + .reply(200, {}); + const response = await client.companies.find({ + companyId: queryData.company_id, + }); + + assert.deepStrictEqual({}, response); + }); + it('should find companies by name', async () => { + const queryData = { + name: 'bruh moment inc.', + }; + nock('https://api.intercom.io') + .get('/companies') + .query(queryData) + .reply(200, {}); + const response = await client.companies.find({ name: queryData.name }); + + assert.deepStrictEqual({}, response); + }); + it('should delete company by id', async () => { + const id = 'baz'; + + nock('https://api.intercom.io') + .delete(`/companies/${id}`) + .reply(200, {}); + + const response = await client.companies.delete({ + id, + }); + + assert.deepStrictEqual({}, response); + }); + it('should list with pagination', async () => { + nock('https://api.intercom.io') + .get('/companies') + .query({ page: 1, per_page: 35, order: Order.DESC }) + .reply(200, {}); + const response = await client.companies.list({ + page: 1, + perPage: 35, + order: Order.DESC, + }); + + assert.deepStrictEqual({}, response); + }); + it('should list by params', async () => { + nock('https://api.intercom.io') + .get('/companies') + .query({ tag_id: '1234', segment_id: '4567' }) + .reply(200, {}); + const response = await client.companies.list({ + tagId: '1234', + segmentId: '4567', + }); + + assert.deepStrictEqual({}, response); + }); + it('should get all infinite companies with scroll', async () => { + nock('https://api.intercom.io') + .get('/companies/scroll') + .reply(200, { + type: 'list', + scroll_param: '123_soleil', + data: [dummyCompany], + }); + + nock('https://api.intercom.io') + .get('/companies/scroll?scroll_param=123_soleil') + .reply(200, { + type: 'list', + scroll_param: '123_soleil_345', + data: [], + }); + + const response = await client.companies.scroll.each({}); + + assert.equal(1, response.length); + assert.deepStrictEqual(dummyCompany, response[0]); + }); + it('should get companies with manual scroll', async () => { + nock('https://api.intercom.io') + .get('/companies/scroll?scroll_param=123_soleil') + .reply(200, { + type: 'list', + scroll_param: '123_soleil_345', + data: [dummyCompany], + }); + + const response = await client.companies.scroll.next({ + scrollParam: '123_soleil', + }); + + assert.deepStrictEqual(dummyCompany, response.data[0]); + assert.deepStrictEqual('123_soleil_345', response.scroll_param); + }); + it('should attach contact to company', async () => { + const contactId = '123'; + const companyId = '234'; + + nock('https://api.intercom.io') + .post(`/contacts/${contactId}/companies`, { id: companyId }) + .reply(200, {}); + + const response = await client.companies.attachContact({ + contactId, + companyId, + }); + + assert.deepStrictEqual({}, response); + }); + it('should detach contact from company', async () => { + const contactId = '123'; + const companyId = '234'; + + nock('https://api.intercom.io') + .delete(`/contacts/${contactId}/companies/${companyId}`) + .reply(200, {}); + + const response = await client.companies.detachContact({ + contactId, + companyId, + }); + + assert.deepStrictEqual({}, response); + }); + it('should list all attached contacts to company', async () => { + const companyId = '234'; + const page = 1; + const perPage = 15; + + nock('https://api.intercom.io') + .get(`/companies/${companyId}/contacts`) + .query({ page, perPage }) + .reply(200, {}); + + const response = await client.companies.listAttachedContacts({ + companyId, + page, + perPage, + }); + + assert.deepStrictEqual({}, response); + }); + it('should list all attached segments to company', async () => { + const companyId = '234'; + + nock('https://api.intercom.io') + .get(`/companies/${companyId}/segments`) + .reply(200, {}); + + const response = await client.companies.listAttachedSegments({ + companyId, + }); + + assert.deepStrictEqual({}, response); + }); +}); diff --git a/test/contact.js b/test/contact.js deleted file mode 100644 index 5ccc72b2..00000000 --- a/test/contact.js +++ /dev/null @@ -1,87 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('contacts', () => { - it('keep the Contacts alias', () => { - nock('https://api.intercom.io').post('/contacts').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - assert.deepEqual(client.leads, client.contacts); - }); - it('should be created', done => { - nock('https://api.intercom.io').post('/contacts').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.leads.create().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should be created with parameters', done => { - nock('https://api.intercom.io').post('/contacts', { foo: 'bar' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.leads.create({ foo: 'bar' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should be updated', done => { - nock('https://api.intercom.io').post('/contacts', { id: 'baz', email: 'foo@intercom.io' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.leads.update({ id: 'baz', email: 'foo@intercom.io' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should list', done => { - nock('https://api.intercom.io').get('/contacts').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.leads.list().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should list by params', done => { - nock('https://api.intercom.io').get('/contacts').query({ email: 'jayne@serenity.io' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.leads.listBy({ email: 'jayne@serenity.io' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should find by id', done => { - nock('https://api.intercom.io').get('/contacts/baz').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.leads.find({ id: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should find by user_id', done => { - nock('https://api.intercom.io').get('/contacts?user_id=baz').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.leads.find({ user_id: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('delete by id', done => { - nock('https://api.intercom.io').delete('/contacts/baz').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.leads.delete({ id: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should convert', done => { - const conversionObject = { - contact: { user_id: 'baz' }, - user: { email: 'bang' } - }; - nock('https://api.intercom.io').post('/contacts/convert', conversionObject).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.leads.convert(conversionObject).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); -}); diff --git a/test/contact.ts b/test/contact.ts new file mode 100644 index 00000000..d23e0ecc --- /dev/null +++ b/test/contact.ts @@ -0,0 +1,361 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; +import { Operators, Role } from '../lib/common/common.types'; +import { SearchContactOrderBy } from '../lib/contact'; + +describe('contacts', () => { + it('should create a contact with user role', async () => { + const id = '536e564f316c83104c000020'; + + const contact = { + role: 'user', + external_id: id, + phone: '+48370044567', + name: 'Niko Bellic', + avatar: 'https://nico-from-gta-iv.com/lets_go_bowling.jpg', + signed_up_at: 1638203719, + last_seen_at: 1638203719, + owner_id: 1, + unsubscribed_from_emails: true, + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post('/contacts', contact) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.createUser({ + externalId: contact.external_id, + phone: contact.phone, + name: contact.name, + avatar: contact.avatar, + signedUpAt: contact.signed_up_at, + lastSeenAt: contact.last_seen_at, + ownerId: contact.owner_id, + isUnsubscribedFromEmails: contact.unsubscribed_from_emails, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should create a contact with lead role', async () => { + const contact = { + role: 'lead', + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post('/contacts', contact) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.createLead(); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should retrieve a contact by id', async () => { + const id = '536e564f316c83104c000020'; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .get(`/contacts/${id}`) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.find({ id }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should update a contact', async () => { + const id = '536e564f316c83104c000020'; + + const requestBody = { + role: Role.USER, + name: 'Roman The Bowling Fan', + custom_attributes: { + callBrother: "Hey Niko, it's me – Roman. Let's go bowling!", + }, + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .put(`/contacts/${id}`, requestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.update({ + id, + role: requestBody.role, + name: requestBody.name, + customAttributes: requestBody.custom_attributes, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should delete a contact by id', async () => { + const id = '536e564f316c83104c000020'; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .delete(`/contacts/${id}`) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.delete({ id }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should archive a contact by id', async () => { + const id = '536e564f316c83104c000020'; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/contacts/${id}/archive`) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.archive({ id }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should unarchive a contact by id', async () => { + const id = '536e564f316c83104c000020'; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/contacts/${id}/unarchive`) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.unarchive({ id }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should merge two contacts', async () => { + const leadId = '536e564f316c83104c000020'; + const userId = '536e564f316c83104c000021'; + + const requestBody = { + from: leadId, + into: userId, + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/contacts/merge`, requestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.mergeLeadInUser({ + leadId, + userId, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should search for contacts using filters, sorts ascending by name, paginates 5 pages per page on page 2', async () => { + const requestBody = { + query: { + operator: Operators.AND, + value: [ + { + operator: Operators.AND, + value: [ + { + field: 'updated_at', + operator: Operators.GREATER_THAN, + value: 1560436650, + }, + { + field: 'conversation_rating.rating', + operator: Operators.EQUALS, + value: 1, + }, + ], + }, + { + operator: Operators.OR, + value: [ + { + field: 'updated_at', + operator: Operators.GREATER_THAN, + value: 1560436650, + }, + { + field: 'conversation_rating.rating', + operator: Operators.EQUALS, + value: 2, + }, + ], + }, + ], + }, + pagination: { + per_page: 5, + starting_after: + 'WzE2MzU4NjA2NDgwMDAsIjYxODJiNjJlNDM4YjdhM2EwMWE4YWYxNSIsMl0=', + }, + sort: { + field: 'name', + order: 'ascending', + }, + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/contacts/search`, requestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.search({ + data: { + query: requestBody.query, + pagination: requestBody.pagination, + sort: { field: 'name', order: SearchContactOrderBy.ASC }, + }, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should list all contacts, with per page = 5 and cursor set to next page', async () => { + nock('https://api.intercom.io') + .get( + '/contacts?per_page=5&starting_after=WzE2MzU3NzU4NjkwMDAsIjYxODJiNjJhMDMwZTk4OTBkZWU4NGM5YiIsMl0=' + ) + .reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.contacts.list({ + perPage: 5, + startingAfter: + 'WzE2MzU3NzU4NjkwMDAsIjYxODJiNjJhMDMwZTk4OTBkZWU4NGM5YiIsMl0=', + }); + + assert.deepStrictEqual({}, response); + }); + + it('should list attached companies of contact by id', async () => { + const id = '536e564f316c83104c000020'; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .get(`/contacts/${id}/companies?per_page=5&page=1`) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.listAttachedCompanies({ + id, + perPage: 5, + page: 1, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should list attached tags of contact by id', async () => { + const id = '536e564f316c83104c000020'; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .get(`/contacts/${id}/tags`) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.listAttachedTags({ id }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should list attached segments of contact by id', async () => { + const id = '536e564f316c83104c000020'; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .get(`/contacts/${id}/segments`) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.listAttachedSegments({ id }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should list attached email subscriptions of contact by id', async () => { + const id = '536e564f316c83104c000020'; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .get(`/contacts/${id}/subscriptions`) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.listAttachedEmailSubscriptions({ + id, + }); + + assert.deepStrictEqual(expectedReply, response); + }); +}); diff --git a/test/conversation.js b/test/conversation.js deleted file mode 100644 index b4d05f31..00000000 --- a/test/conversation.js +++ /dev/null @@ -1,38 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('conversations', () => { - it('should be listed', done => { - nock('https://api.intercom.io').get('/conversations').query({ foo: 'bar' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.conversations.list({ foo: 'bar' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should find', done => { - nock('https://api.intercom.io').get('/conversations/bar').query({ id: 'bar' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.conversations.find({ id: 'bar' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should reply', done => { - nock('https://api.intercom.io').post('/conversations/bar/reply', { id: 'bar', baz: 'bang' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.conversations.reply({ id: 'bar', baz: 'bang' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should mark as read', done => { - nock('https://api.intercom.io').put('/conversations/bar', { read: true }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.conversations.markAsRead({ id: 'bar' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); -}); diff --git a/test/conversation.ts b/test/conversation.ts new file mode 100644 index 00000000..90fe3a9b --- /dev/null +++ b/test/conversation.ts @@ -0,0 +1,598 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; +import { + AssignToConversationMessageType, + AssignToConversationUserType, + CloseConversationMessageType, + CloseConversationType, + OpenConversationMessageType, + RedactConversationPartType, + ReplyToConversationMessageType, + ReplyToConversationUserType, + SearchConversationOrderBy, + SnoozeConversationMessageType, + SortBy, +} from '../lib/conversation'; +import { Operators, Order } from '../lib/common/common.types'; + +describe('conversations', () => { + it('should create a conversation', async () => { + const id = '536e564f316c83104c000020'; + + const message = { + from: { + type: 'user', + id, + }, + body: 'Hello darkness my old friend', + }; + + const expectedReply = { + type: 'user_message', + id: '2001', + created_at: 1401917202, + body: 'Hello darkness my old friend', + message_type: 'inapp', + conversation_id: '36000324324', + }; + + nock('https://api.intercom.io') + .post('/conversations', message) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.create({ + userId: id, + body: message.body, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should retrieve a conversation as is', async () => { + const id = '536e564f316c83104c000020'; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .get(`/conversations/${id}`) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.find({ id }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should retrieve a conversation as plain text', async () => { + const id = '536e564f316c83104c000020'; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .get(`/conversations/${id}`) + .query({ display_as: 'plaintext' }) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.find({ + id, + inPlainText: true, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should update a conversation', async () => { + const id = '536e564f316c83104c000020'; + + const requestBody = { + read: false, + custom_attributes: { + yey: 'in the bay', + }, + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .put(`/conversations/${id}`, requestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.update({ + id, + markRead: requestBody.read, + customAttributes: requestBody.custom_attributes, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should reply as user to a conversation by id', async () => { + const id = '536e564f316c83104c000020'; + + const userRequestBody = { + message_type: ReplyToConversationMessageType.COMMENT, + type: ReplyToConversationUserType.USER, + body: 'blablbalba', + intercom_user_id: id, + attachment_urls: ['https://definitely-sfw-site.org/bebra.jpg'], + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/conversations/${id}/reply`, userRequestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.replyByIdAsUser({ + id, + body: userRequestBody.body, + intercomUserId: userRequestBody.intercom_user_id, + attachmentUrls: userRequestBody.attachment_urls, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should reply as admin to a conversation by id', async () => { + const id = '536e564f316c83104c000020'; + + const adminRequestBody = { + admin_id: '536e564f316c83104c000020', + message_type: ReplyToConversationMessageType.NOTE, + type: ReplyToConversationUserType.ADMIN, + body: 'blablbalba', + attachment_urls: ['https://definitely-sfw-site.org/bebra.jpg'], + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/conversations/${id}/reply`, adminRequestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.replyByIdAsAdmin({ + id, + adminId: adminRequestBody.admin_id, + messageType: adminRequestBody.message_type, + body: adminRequestBody.body, + attachmentUrls: adminRequestBody.attachment_urls, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should reply as user to last conversation', async () => { + const id = '536e564f316c83104c000020'; + + const userRequestBody = { + message_type: ReplyToConversationMessageType.COMMENT, + type: ReplyToConversationUserType.USER, + body: 'blablbalba', + intercom_user_id: id, + attachment_urls: ['https://definitely-sfw-site.org/bebra.jpg'], + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/conversations/last/reply`, userRequestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.replyByLastAsUser({ + body: userRequestBody.body, + intercomUserId: userRequestBody.intercom_user_id, + attachmentUrls: userRequestBody.attachment_urls, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should reply as admin to last conversation', async () => { + const adminId = '536e564f316c83104c000021'; + + const adminRequestBody = { + admin_id: adminId, + message_type: ReplyToConversationMessageType.NOTE, + type: ReplyToConversationUserType.ADMIN, + body: 'blablbalba', + attachment_urls: ['https://definitely-sfw-site.org/bebra.jpg'], + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/conversations/last/reply`, adminRequestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.replyByLastAsAdmin({ + adminId, + messageType: adminRequestBody.message_type, + body: adminRequestBody.body, + attachmentUrls: adminRequestBody.attachment_urls, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should assign a conversation as team without assignment_rules', async () => { + const id = '536e564f316c83104c000020'; + + const userRequestBody = { + message_type: AssignToConversationMessageType.ASSIGNMENT, + type: AssignToConversationUserType.TEAM, + assignee_id: id, + admin_id: id, + body: 'blablbalba', + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/conversations/${id}/parts`, userRequestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.assign({ + id, + type: userRequestBody.type, + adminId: userRequestBody.admin_id, + assigneeId: userRequestBody.assignee_id, + body: userRequestBody.body, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should assign a conversation as team with assignment_rules', async () => { + const id = '536e564f316c83104c000020'; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/conversations/${id}/run_assignment_rules/parts`) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.assign({ + id, + withRunningAssignmentRules: true, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should snooze a conversation', async () => { + const id = '536e564f316c83104c000020'; + + const adminRequestBody = { + message_type: SnoozeConversationMessageType.SNOOZED, + admin_id: id, + snoozed_until: '1501512795', + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/conversations/${id}/reply`, adminRequestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.snooze({ + id, + adminId: adminRequestBody.admin_id, + snoozedUntil: adminRequestBody.snoozed_until, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should close a conversation', async () => { + const id = '536e564f316c83104c000020'; + + const adminRequestBody = { + message_type: CloseConversationMessageType.CLOSED, + type: CloseConversationType.ADMIN, + admin_id: id, + body: 'Closed conversation because of X.', + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/conversations/${id}/parts`, adminRequestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.close({ + id, + adminId: adminRequestBody.admin_id, + body: adminRequestBody.body, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should open a conversation', async () => { + const id = '536e564f316c83104c000020'; + + const adminRequestBody = { + message_type: OpenConversationMessageType.OPEN, + admin_id: id, + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/conversations/${id}/parts`, adminRequestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.open({ + id, + adminId: adminRequestBody.admin_id, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should attach a contact to the conversation as admin', async () => { + const id = '536e564f316c83104c000020'; + + const adminRequestBody = { + admin_id: id, + customer: { + intercom_user_id: id, + }, + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/conversations/${id}/customers`, adminRequestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.attachContactAsAdmin({ + id, + adminId: adminRequestBody.admin_id, + customer: { + intercomUserId: adminRequestBody.customer.intercom_user_id, + }, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should attach a contact to the conversation as contact', async () => { + const id = '536e564f316c83104c000020'; + + const contactRequestBody = { + user_id: id, + customer: { + intercom_user_id: id, + }, + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/conversations/${id}/customers`, contactRequestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.attachContactAsContact({ + id, + userId: contactRequestBody.user_id, + customer: { + intercomUserId: contactRequestBody.customer.intercom_user_id, + }, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should detach a contact from the conversation as admin', async () => { + const id = '536e564f316c83104c000020'; + const contactId = '536e564f316c83104c000021'; + const conversationId = '536e564f316c83104c000022'; + + const adminRequestBody = { + admin_id: id, + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .delete( + `/conversations/${conversationId}/customers/${contactId}`, + adminRequestBody + ) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.detachContactAsAdmin({ + conversationId, + contactId, + adminId: adminRequestBody.admin_id, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should search for conversations using filters', async () => { + const requestBody = { + query: { + operator: Operators.AND, + value: [ + { + operator: Operators.AND, + value: [ + { + field: 'updated_at', + operator: Operators.GREATER_THAN, + value: 1560436650, + }, + { + field: 'conversation_rating.rating', + operator: Operators.EQUALS, + value: 1, + }, + ], + }, + { + operator: Operators.OR, + value: [ + { + field: 'updated_at', + operator: Operators.GREATER_THAN, + value: 1560436650, + }, + { + field: 'conversation_rating.rating', + operator: Operators.EQUALS, + value: 2, + }, + ], + }, + ], + }, + pagination: { + per_page: 5, + starting_after: + 'WzE2MzU4NjA2NDgwMDAsIjYxODJiNjJlNDM4YjdhM2EwMWE4YWYxNSIsMl0=', + }, + sort: { + field: 'name', + order: SearchConversationOrderBy.DESC, + }, + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post(`/conversations/search`, requestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.search({ + data: { + query: requestBody.query, + pagination: requestBody.pagination, + // eslint-disable-next-line @typescript-eslint/no-explicit-any + sort: requestBody.sort as any, + }, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should list all conversations', async () => { + const expectedReply = {}; + + nock('https://api.intercom.io') + .get(`/conversations?order=desc&sort=updated_at&page=1&per_page=10`) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.list({ + query: { + order: Order.DESC, + sort: SortBy.UpdatedAt, + page: 1, + perPage: 10, + }, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should redact a conversation part', async () => { + const conversation_id = '536e564f316c83104c000020'; + const conversation_part_id = '536e564f316c83104c000021'; + + const requestBody = { + type: RedactConversationPartType.CONVERSATION_PART, + conversation_id, + conversation_part_id, + }; + const expectedReply = {}; + + nock('https://api.intercom.io') + .post('/conversations/redact', requestBody) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.redactConversationPart({ + type: requestBody.type, + conversationId: requestBody.conversation_id, + conversationPartId: requestBody.conversation_part_id, + }); + + assert.deepStrictEqual(expectedReply, response); + }); +}); diff --git a/test/counts.js b/test/counts.js deleted file mode 100644 index f4d72199..00000000 --- a/test/counts.js +++ /dev/null @@ -1,70 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('counts', () => { - it('app counts', done => { - nock('https://api.intercom.io').get('/counts').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.counts.appCounts().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('conversation app counts', done => { - nock('https://api.intercom.io').get('/counts').query({ type: 'conversation' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.counts.conversationCounts().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('conversation admin counts', done => { - nock('https://api.intercom.io').get('/counts').query({ type: 'conversation', count: 'admin' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.counts.conversationAdminCounts().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('user tag counts', done => { - nock('https://api.intercom.io').get('/counts').query({ type: 'user', count: 'tag' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.counts.userTagCounts().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('user segment counts', done => { - nock('https://api.intercom.io').get('/counts').query({ type: 'user', count: 'segment' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.counts.userSegmentCounts().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('company tag counts', done => { - nock('https://api.intercom.io').get('/counts').query({ type: 'company', count: 'tag' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.counts.companyTagCounts().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('company segment counts', done => { - nock('https://api.intercom.io').get('/counts').query({ type: 'company', count: 'segment' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.counts.companySegmentCounts().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('company user counts', done => { - nock('https://api.intercom.io').get('/counts').query({ type: 'company', count: 'user' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.counts.companyUserCounts().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); -}); diff --git a/test/customer.js b/test/customer.js deleted file mode 100644 index 5dd7a8e7..00000000 --- a/test/customer.js +++ /dev/null @@ -1,14 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('customers', () => { - it('should search', done => { - nock('https://api.intercom.io').post('/customers/search', { query: { field: 'name', operator: '=', name: 'Alice'}, sort: { field: 'name', order: 'ascending'}, pagination: { per_page: 10 }}).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.customers.search({ query: { field: 'name', operator: '=', name: 'Alice'}, sort: { field: 'name', order: 'ascending'}, pagination: { per_page: 10 }}).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); -}); diff --git a/test/dataAttribute.ts b/test/dataAttribute.ts new file mode 100644 index 00000000..9c4c01cf --- /dev/null +++ b/test/dataAttribute.ts @@ -0,0 +1,70 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import { DataType, ModelType } from '../lib/dataAttribute/dataAttribute.types'; +import nock from 'nock'; + +describe('data attributes', () => { + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + it('should create', async () => { + const requestBody = { + name: 'list_cda', + model: ModelType.CONTACT, + data_type: DataType.STRING, + description: 'You are either alive or dead', + options: [{ value: 'alive' }, { value: 'dead' }], + }; + + nock('https://api.intercom.io') + .post('/data_attributes', requestBody) + .reply(200, {}); + const response = await client.dataAttributes.create({ + name: requestBody.name, + model: ModelType.CONTACT, + dataType: DataType.STRING, + description: requestBody.description, + options: requestBody.options, + }); + + assert.deepStrictEqual({}, response); + }); + it('should update', async () => { + const id = '123'; + const requestBody = { + description: 'You are either alive or dead', + options: [{ value: 'alive' }, { value: 'dead' }], + archived: true, + }; + + nock('https://api.intercom.io') + .put(`/data_attributes/${id}`) + .reply(200, {}); + const response = await client.dataAttributes.update({ + id, + description: requestBody.description, + options: requestBody.options, + archived: requestBody.archived, + }); + + assert.deepStrictEqual({}, response); + }); + it('should list all', async () => { + const queryParams = { + model: ModelType.CONTACT, + include_archived: true, + }; + + nock('https://api.intercom.io') + .get('/data_attributes') + .query(queryParams) + .reply(200, {}); + const response = await client.dataAttributes.list({ + model: queryParams.model, + includeArchived: queryParams.include_archived, + }); + + assert.deepStrictEqual({}, response); + }); +}); diff --git a/test/errors.js b/test/errors.js deleted file mode 100644 index 2493b3d7..00000000 --- a/test/errors.js +++ /dev/null @@ -1,252 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('errors', () => { - describe('with promises', () => { - it('should fail with ESOCKETTIMEDOUT error', () => { - - const socketErr = new Error('Socket timeout'); - socketErr.code = 'ESOCKETTIMEDOUT'; - - nock('https://api.intercom.io').replyContentLength().get('/admins').replyWithError(socketErr); - const client = new Client('foo', 'bar').usePromises(); - return client.admins.list().then(r => { - assert.strictEqual(r, null, 'Valid response'); - }).catch(err => { - assert.deepStrictEqual(err, socketErr); - }); - }); - it('should fail with unauthorized (401) error', () => { - nock('https://api.intercom.io').replyContentLength().get('/admins').reply(401, - { - type: 'error.list', - request_id: 'b2i3ri5909msvfqskol0', - errors: [ - { - code: 'token_unauthorized', - message: 'Not authorized to access resource' - } - ] - }, - { - 'X-Intercom-Version': '3736ab533ad11d88d93cdef3fcef9a98a5724229', - 'X-RateLimit-Limit': '83', - 'X-RateLimit-Remaining': '27', - 'X-RateLimit-Reset': '1522850540', - 'X-Request-Id': 'b2i3ri5909msvfqskol0', - 'X-Runtime': '0.037708' - } - ); - const client = new Client('foo', 'bar').usePromises(); - return client.admins.list().then(r => { - assert.strictEqual(r, null, 'Valid response'); - }).catch(err => { - assert.strictEqual(err.statusCode, 401); - assert.strictEqual(err.body.request_id, 'b2i3ri5909msvfqskol0'); - assert.deepStrictEqual(err.body.errors, [{ code: 'token_unauthorized', message: 'Not authorized to access resource' }]); - assert.deepStrictEqual(err.message, 'Not authorized to access resource'); - assert.strictEqual(err.headers['x-request-id'], 'b2i3ri5909msvfqskol0'); - }); - }); - it('should fail with too many requests (429) error', () => { - nock('https://api.intercom.io').replyContentLength().get('/me').reply(429, - { - type: 'error.list', - request_id: 'b2i3mhcboc6pcbe33q80', - errors: [ - { - code: 'rate_limit_exceeded', - message: 'Exceeded rate limit of 83 in 10_seconds' - } - ] - }, - { - 'X-Intercom-Version': '3736ab533ad11d88d93cdef3fcef9a98a5724229', - 'X-RateLimit-Limit': '83', - 'X-RateLimit-Remaining': '0', - 'X-RateLimit-Reset': '1522849880', - 'X-Request-Id': 'b2i3mhcboc6pcbe33q80', - 'X-Runtime': '0.037708' - } - ); - const client = new Client('foo', 'bar').usePromises(); - return client.admins.me().then(r => { - assert.strictEqual(r, null, 'Valid response'); - }).catch(err => { - assert.strictEqual(err.statusCode, 429); - assert.strictEqual(err.body.request_id, 'b2i3mhcboc6pcbe33q80'); - assert.deepStrictEqual(err.body.errors, [{ code: 'rate_limit_exceeded', message: 'Exceeded rate limit of 83 in 10_seconds' }]); - assert.deepStrictEqual(err.message, 'Exceeded rate limit of 83 in 10_seconds'); - assert.strictEqual(err.headers['x-request-id'], 'b2i3mhcboc6pcbe33q80'); - assert.strictEqual(err.headers['x-ratelimit-reset'], '1522849880'); - }); - }); - }); - - describe('with callback', () => { - describe('with 1 arg', () => { - it('should fail with ESOCKETTIMEDOUT error', done => { - - const socketErr = new Error('Socket timeout'); - socketErr.code = 'ESOCKETTIMEDOUT'; - - nock('https://api.intercom.io').replyContentLength().get('/admins').replyWithError(socketErr); - const client = new Client('foo', 'bar'); - client.admins.list(r => { - assert.strictEqual(r, null, 'Valid response'); - - done(); - }); - }); - it('should fail with unauthorized (401) error', done => { - nock('https://api.intercom.io').replyContentLength().get('/admins').reply(401, - { - type: 'error.list', - request_id: 'b2i3ri5909msvfqskol0', - errors: [ - { - code: 'token_unauthorized', - message: 'Not authorized to access resource' - } - ] - }, - { - 'X-Intercom-Version': '3736ab533ad11d88d93cdef3fcef9a98a5724229', - 'X-RateLimit-Limit': '83', - 'X-RateLimit-Remaining': '27', - 'X-RateLimit-Reset': '1522850540', - 'X-Request-Id': 'b2i3ri5909msvfqskol0', - 'X-Runtime': '0.037708' - } - ); - const client = new Client('foo', 'bar'); - client.admins.list(r => { - assert.strictEqual(r.statusCode, 401); - assert.strictEqual(r.body.type, 'error.list'); - assert.strictEqual(r.body.request_id, 'b2i3ri5909msvfqskol0'); - assert.ok(Array.isArray(r.body.errors)); - - done(); - }); - }); - it('should fail with too many requests (429) error', done => { - nock('https://api.intercom.io').replyContentLength().get('/me').reply(429, - { - type: 'error.list', - request_id: 'b2i3mhcboc6pcbe33q80', - errors: [ - { - code: 'rate_limit_exceeded', - message: 'Exceeded rate limit of 83 in 10_seconds' - } - ] - }, - { - 'X-Intercom-Version': '3736ab533ad11d88d93cdef3fcef9a98a5724229', - 'X-RateLimit-Limit': '83', - 'X-RateLimit-Remaining': '0', - 'X-RateLimit-Reset': '1522849880', - 'X-Request-Id': 'b2i3mhcboc6pcbe33q80', - 'X-Runtime': '0.037708' - } - ); - const client = new Client('foo', 'bar'); - client.admins.me(r => { - assert.strictEqual(r.statusCode, 429); - assert.strictEqual(r.body.type, 'error.list'); - assert.strictEqual(r.body.request_id, 'b2i3mhcboc6pcbe33q80'); - assert.ok(Array.isArray(r.body.errors)); - - done(); - }); - }); - }); - describe('with 2 args', () => { - it('should fail with ESOCKETTIMEDOUT error', done => { - - const socketErr = new Error('Socket timeout'); - socketErr.code = 'ESOCKETTIMEDOUT'; - - nock('https://api.intercom.io').replyContentLength().get('/admins').replyWithError(socketErr); - const client = new Client('foo', 'bar'); - client.admins.list((err, r) => { - assert.strictEqual(r, null, 'Valid response'); - - assert.deepStrictEqual(err, socketErr); - - done(); - }); - }); - it('should fail with unauthorized (401) error', done => { - nock('https://api.intercom.io').replyContentLength().get('/admins').reply(401, - { - type: 'error.list', - request_id: 'b2i3ri5909msvfqskol0', - errors: [ - { - code: 'token_unauthorized', - message: 'Not authorized to access resource' - } - ] - }, - { - 'X-Intercom-Version': '3736ab533ad11d88d93cdef3fcef9a98a5724229', - 'X-RateLimit-Limit': '83', - 'X-RateLimit-Remaining': '27', - 'X-RateLimit-Reset': '1522850540', - 'X-Request-Id': 'b2i3ri5909msvfqskol0', - 'X-Runtime': '0.037708' - } - ); - const client = new Client('foo', 'bar'); - client.admins.list((err, r) => { - assert.strictEqual(r, null, 'Valid response'); - - assert.strictEqual(err.statusCode, 401); - assert.strictEqual(err.body.request_id, 'b2i3ri5909msvfqskol0'); - assert.deepStrictEqual(err.body.errors, [{ code: 'token_unauthorized', message: 'Not authorized to access resource' }]); - assert.deepStrictEqual(err.message, 'Not authorized to access resource'); - assert.strictEqual(err.headers['x-request-id'], 'b2i3ri5909msvfqskol0'); - - done(); - }); - }); - it('should fail with too many requests (429) error', done => { - nock('https://api.intercom.io').replyContentLength().get('/me').reply(429, - { - type: 'error.list', - request_id: 'b2i3mhcboc6pcbe33q80', - errors: [ - { - code: 'rate_limit_exceeded', - message: 'Exceeded rate limit of 83 in 10_seconds' - } - ] - }, - { - 'X-Intercom-Version': '3736ab533ad11d88d93cdef3fcef9a98a5724229', - 'X-RateLimit-Limit': '83', - 'X-RateLimit-Remaining': '0', - 'X-RateLimit-Reset': '1522849880', - 'X-Request-Id': 'b2i3mhcboc6pcbe33q80', - 'X-Runtime': '0.037708' - } - ); - const client = new Client('foo', 'bar'); - client.admins.me((err, r) => { - assert.strictEqual(r, null, 'Valid response'); - - assert.strictEqual(err.statusCode, 429); - assert.strictEqual(err.body.request_id, 'b2i3mhcboc6pcbe33q80'); - assert.deepStrictEqual(err.body.errors, [{ code: 'rate_limit_exceeded', message: 'Exceeded rate limit of 83 in 10_seconds' }]); - assert.deepStrictEqual(err.message, 'Exceeded rate limit of 83 in 10_seconds'); - assert.strictEqual(err.headers['x-request-id'], 'b2i3mhcboc6pcbe33q80'); - assert.strictEqual(err.headers['x-ratelimit-reset'], '1522849880'); - - done(); - }); - }); - }); - }); -}); diff --git a/test/errors.ts b/test/errors.ts new file mode 100644 index 00000000..1efc0337 --- /dev/null +++ b/test/errors.ts @@ -0,0 +1,109 @@ +import assert from 'assert'; +import nock from 'nock'; +import { Client } from '../lib'; + +describe('errors', () => { + it('should fail with unauthorized (401) error', async () => { + nock('https://api.intercom.io') + .replyContentLength() + .get('/admins') + .reply( + 401, + { + type: 'error.list', + request_id: 'b2i3ri5909msvfqskol0', + errors: [ + { + code: 'token_unauthorized', + message: 'Not authorized to access resource', + }, + ], + }, + { + 'X-Intercom-Version': + '3736ab533ad11d88d93cdef3fcef9a98a5724229', + 'X-RateLimit-Limit': '83', + 'X-RateLimit-Remaining': '27', + 'X-RateLimit-Reset': '1522850540', + 'X-Request-Id': 'b2i3ri5909msvfqskol0', + 'X-Runtime': '0.037708', + } + ); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + try { + const response = await client.admins.list(); + assert.strictEqual(response, null, 'Valid response'); + } catch (err) { + assert.strictEqual(err.statusCode, 401); + assert.strictEqual(err.body.request_id, 'b2i3ri5909msvfqskol0'); + assert.deepStrictEqual(err.body.errors, [ + { + code: 'token_unauthorized', + message: 'Not authorized to access resource', + }, + ]); + assert.deepStrictEqual( + err.message, + 'Not authorized to access resource' + ); + assert.strictEqual( + err.headers['x-request-id'], + 'b2i3ri5909msvfqskol0' + ); + } + }); + it('should fail with too many requests (429) error', async () => { + nock('https://api.intercom.io') + .replyContentLength() + .get('/admins') + .reply( + 429, + { + type: 'error.list', + request_id: 'b2i3mhcboc6pcbe33q80', + errors: [ + { + code: 'rate_limit_exceeded', + message: 'Exceeded rate limit of 83 in 10_seconds', + }, + ], + }, + { + 'X-Intercom-Version': + '3736ab533ad11d88d93cdef3fcef9a98a5724229', + 'X-RateLimit-Limit': '83', + 'X-RateLimit-Remaining': '0', + 'X-RateLimit-Reset': '1522849880', + 'X-Request-Id': 'b2i3mhcboc6pcbe33q80', + 'X-Runtime': '0.037708', + } + ); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + try { + const response = await client.admins.list(); + assert.strictEqual(response, null, 'Valid response'); + } catch (err) { + assert.strictEqual(err.statusCode, 429); + assert.strictEqual(err.body.request_id, 'b2i3mhcboc6pcbe33q80'); + assert.deepStrictEqual(err.body.errors, [ + { + code: 'rate_limit_exceeded', + message: 'Exceeded rate limit of 83 in 10_seconds', + }, + ]); + assert.deepStrictEqual( + err.message, + 'Exceeded rate limit of 83 in 10_seconds' + ); + assert.strictEqual( + err.headers['x-request-id'], + 'b2i3mhcboc6pcbe33q80' + ); + assert.strictEqual(err.headers['x-ratelimit-reset'], '1522849880'); + } + }); +}); diff --git a/test/event.js b/test/event.js deleted file mode 100644 index ec691561..00000000 --- a/test/event.js +++ /dev/null @@ -1,26 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('events', () => { - it('should be created', done => { - nock('https://api.intercom.io').post('/events', { event_name: 'Foo', created_at: 1234, user_id: 'bar' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.events.create({ - event_name: 'Foo', - created_at: 1234, - user_id: 'bar' - }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should list by params', done => { - nock('https://api.intercom.io').get('/events').query({ type: 'user', user_id: '1234' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.events.listBy({ type: 'user', user_id: '1234' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); -}); diff --git a/test/event.ts b/test/event.ts new file mode 100644 index 00000000..187d9a39 --- /dev/null +++ b/test/event.ts @@ -0,0 +1,65 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; + +describe('events', () => { + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + it('should be submitted (created)', async () => { + const requestBody = { + event_name: 'placed-order', + created_at: 1389913941, + user_id: 'f4ca124298', + metadata: { + order_date: 1392036272, + stripe_invoice: 'inv_3434343434', + order_number: { + value: '3434-3434', + url: 'https://example.org/orders/3434-3434', + }, + price: { + currency: 'usd', + amount: 2999, + }, + }, + }; + + nock('https://api.intercom.io') + .post('/events', requestBody) + .reply(200, {}); + + const response = await client.events.create({ + eventName: requestBody.event_name, + createdAt: requestBody.created_at, + userId: requestBody.user_id, + metadata: requestBody.metadata, + }); + + assert.deepStrictEqual({}, response); + }); + it('should list by params', async () => { + const requestParams = { + type: 'user', + user_id: '1234', + per_page: 2, + summary: true, + email: 'i_love_memes@gmail.com', + }; + + nock('https://api.intercom.io') + .get('/events') + .query(requestParams) + .reply(200, {}); + + const response = await client.events.listBy({ + userId: requestParams.user_id, + perPage: requestParams.per_page, + summary: requestParams.summary, + email: requestParams.email, + }); + + assert.deepStrictEqual({}, response); + }); +}); diff --git a/test/helpCenter.ts b/test/helpCenter.ts new file mode 100644 index 00000000..8978bff2 --- /dev/null +++ b/test/helpCenter.ts @@ -0,0 +1,181 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; + +describe('help center', () => { + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + describe('collections', () => { + it('creates a collection', async () => { + const requestData = { + name: 'Thanks for everything', + description: 'English description', + translated_content: { + fr: { + name: 'Allez les verts', + description: 'French description', + }, + }, + }; + nock('https://api.intercom.io') + .post('/help_center/collections') + .reply(200, {}); + const response = await client.helpCenter.collections.create({ + name: requestData.name, + description: requestData.description, + translatedContent: requestData.translated_content, + }); + + assert.deepStrictEqual({}, response); + }); + it('retrieves a collection', async () => { + const id = 'baz'; + + nock('https://api.intercom.io') + .get(`/help_center/collections/${id}`) + .reply(200, {}); + + const response = await client.helpCenter.collections.find({ id }); + + assert.deepStrictEqual({}, response); + }); + it('updates a collection', async () => { + const id = 'baz'; + const requestData = { + name: 'Thanks for everything', + description: 'English description', + translated_content: { + fr: { + name: 'Allez les verts', + description: 'French description', + }, + }, + }; + nock('https://api.intercom.io') + .put(`/help_center/collections/${id}`) + .reply(200, {}); + const response = await client.helpCenter.collections.update({ + id, + name: requestData.name, + description: requestData.description, + translatedContent: requestData.translated_content, + }); + + assert.deepStrictEqual({}, response); + }); + it('deletes a collection', async () => { + const id = 'baz'; + nock('https://api.intercom.io') + .delete(`/help_center/collections/${id}`) + .reply(200, {}); + + const response = await client.helpCenter.collections.delete({ + id, + }); + + assert.deepStrictEqual({}, response); + }); + it('lists all', async () => { + const requestQuery = { page: 3, per_page: 12 }; + + nock('https://api.intercom.io') + .get('/help_center/collections') + .query(requestQuery) + .reply(200, {}); + + const response = await client.helpCenter.collections.list({ + page: requestQuery.page, + perPage: requestQuery.per_page, + }); + + assert.deepStrictEqual({}, response); + }); + }); + describe('sections', () => { + it('creates a section', async () => { + const requestData = { + name: 'Thanks for everything', + parent_id: '123', + translated_content: { + fr: { + name: 'Allez les verts', + description: 'French description', + }, + }, + }; + nock('https://api.intercom.io') + .post('/help_center/sections') + .reply(200, {}); + const response = await client.helpCenter.sections.create({ + name: requestData.name, + parentId: requestData.parent_id, + translatedContent: requestData.translated_content, + }); + + assert.deepStrictEqual({}, response); + }); + it('retrieves a section', async () => { + const id = 'baz'; + + nock('https://api.intercom.io') + .get(`/help_center/sections/${id}`) + .reply(200, {}); + + const response = await client.helpCenter.sections.find({ id }); + + assert.deepStrictEqual({}, response); + }); + it('updates a section', async () => { + const id = 'baz'; + const requestData = { + name: 'Thanks for everything', + parent_id: '123', + translated_content: { + fr: { + name: 'Allez les verts', + description: 'French description', + }, + }, + }; + nock('https://api.intercom.io') + .put(`/help_center/sections/${id}`) + .reply(200, {}); + const response = await client.helpCenter.sections.update({ + id, + name: requestData.name, + parentId: requestData.parent_id, + translatedContent: requestData.translated_content, + }); + + assert.deepStrictEqual({}, response); + }); + it('deletes a section', async () => { + const id = 'baz'; + nock('https://api.intercom.io') + .delete(`/help_center/sections/${id}`) + .reply(200, {}); + + const response = await client.helpCenter.sections.delete({ + id, + }); + + assert.deepStrictEqual({}, response); + }); + it('lists all', async () => { + const requestQuery = { page: 3, per_page: 12 }; + + nock('https://api.intercom.io') + .get('/help_center/sections') + .query(requestQuery) + .reply(200, {}); + + const response = await client.helpCenter.sections.list({ + page: requestQuery.page, + perPage: requestQuery.per_page, + }); + + assert.deepStrictEqual({}, response); + }); + }); +}); diff --git a/test/index.js b/test/index.js deleted file mode 100644 index 2c7ccd3e..00000000 --- a/test/index.js +++ /dev/null @@ -1,26 +0,0 @@ -import assert from 'assert'; -import {Client, IdentityVerification} from '../lib'; -import nock from 'nock'; - -describe('clients', () => { - it('ping', done => { - nock('https://api.intercom.io').get('/admins').reply(200, {}); - const client = new Client('foo', 'bar'); - client.ping(r => { - assert.equal(200, r); - done(); - }); - }); - it('paginate', done => { - nock('https://api.intercom.io').get('/foo/bar/baz').query({ blue: 'red' }).reply(200, { foo: 'bar' }); - const client = new Client('foo', 'bar').usePromises(); - const paginationObject = { next: 'https://api.intercom.io/foo/bar/baz?blue=red' }; - client.nextPage(paginationObject).then(r => { - assert.deepEqual({foo: 'bar'}, r.body); - done(); - }); - }); - it('should compute user hashes', () => { - assert.equal('c8acc43edc084edb8207a50320ba4ec5d113686cf8050274a305480c98512e45', IdentityVerification.userHash({secretKey: 'bar', identifier: 'baz'})); - }); -}); diff --git a/test/index.ts b/test/index.ts new file mode 100644 index 00000000..cd324c05 --- /dev/null +++ b/test/index.ts @@ -0,0 +1,39 @@ +import assert from 'assert'; +import { Client, IdentityVerification } from '../lib'; +import nock from 'nock'; + +describe('clients', () => { + it('ping', async () => { + nock('https://api.intercom.io').get('/admins').reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.ping(); + + assert.deepStrictEqual({}, response); + }); + it('paginate', async () => { + nock('https://api.intercom.io') + .get('/foo/bar/baz') + .query({ blue: 'red' }) + .reply(200, { foo: 'bar' }); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const paginationObject = { + next: 'https://api.intercom.io/foo/bar/baz?blue=red', + }; + const response = await client.nextPage(paginationObject); + + assert.deepStrictEqual({ foo: 'bar' }, response); + }); + it('should compute user hashes', () => { + assert.equal( + 'c8acc43edc084edb8207a50320ba4ec5d113686cf8050274a305480c98512e45', + IdentityVerification.userHash({ + secretKey: 'bar', + identifier: 'baz', + }) + ); + }); +}); diff --git a/test/message.js b/test/message.js deleted file mode 100644 index 41c4125f..00000000 --- a/test/message.js +++ /dev/null @@ -1,14 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('messages', () => { - it('should be created', done => { - nock('https://api.intercom.io').post('/messages', { message_type: 'foo' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.messages.create({ message_type: 'foo' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); -}); diff --git a/test/message.ts b/test/message.ts new file mode 100644 index 00000000..7306eb1d --- /dev/null +++ b/test/message.ts @@ -0,0 +1,42 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; +import { MessageType } from '../lib/message/message.types'; +import { RecepientType } from '../lib/message'; + +describe('messages', () => { + it('should be created', async () => { + const requestBody = { + message_type: MessageType.EMAIL, + subject: 'This is our demand now', + body: 'Destroy ponies', + template: 'plain', + from: { + type: RecepientType.ADMIN, + id: '394051', + }, + to: { + type: RecepientType.USER, + id: '536e564f316c83104c000020', + }, + }; + + nock('https://api.intercom.io') + .post('/messages', requestBody) + .reply(200, {}); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.messages.create({ + messageType: requestBody.message_type, + subject: requestBody.subject, + body: requestBody.body, + template: requestBody.template, + from: requestBody.from, + to: requestBody.to, + }); + + assert.deepStrictEqual({}, response); + }); +}); diff --git a/test/note.js b/test/note.js deleted file mode 100644 index 3a2b2ba5..00000000 --- a/test/note.js +++ /dev/null @@ -1,30 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('notes', () => { - it('should be created', done => { - nock('https://api.intercom.io').post('/notes', { foo: 'bar' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.notes.create({ foo: 'bar' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should list', done => { - nock('https://api.intercom.io').get('/notes').query({ foo: 'bar' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.notes.list({ foo: 'bar' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should find notes by id', done => { - nock('https://api.intercom.io').get('/notes/bar').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.notes.find({ id: 'bar' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); -}); diff --git a/test/request-opts.js b/test/request-opts.js deleted file mode 100644 index d619d24f..00000000 --- a/test/request-opts.js +++ /dev/null @@ -1,85 +0,0 @@ -import assert from 'assert'; -import { Client } from '../lib'; -import nock from 'nock'; -import sinon from 'sinon'; - -describe('request-opts', function () { - it('should be able to change request options', function () { - const jsonReviver = sinon.stub().returnsArg(1); - - nock('https://api.intercom.io').get('/admins/baz').reply(200, {}); - const client = new Client('foo', 'bar') - .usePromises() - .useRequestOpts({ - jsonReviver - }); - - return client.admins.find('baz').then(r => { - assert.equal(200, r.statusCode); - sinon.assert.called(jsonReviver); - }); - }); - it('should be able to change request baseUrl option', function () { - nock('http://local.test-server.com').get('/admins/baz').reply(200, {}); - const client = new Client('foo', 'bar') - .usePromises() - .useRequestOpts({ - baseUrl: 'http://local.test-server.com' - }); - - return client.admins.find('baz').then(r => { - assert.equal(200, r.statusCode); - }); - }); - it('should be able to change request options merging in headers', function () { - const jsonReviver = sinon.stub().returnsArg(1); - const customHeaderCheck = sinon.stub().returns(true); - const userAgentHeaderCheck = sinon.stub().returns(true); - const acceptHeaderCheck = sinon.stub().returns(true); - - nock('https://api.intercom.io', { - reqheaders: { - 'x-intercom-header': customHeaderCheck, - 'User-Agent': userAgentHeaderCheck, - Accept: acceptHeaderCheck - } - }).get('/admins/baz').reply(200, {}); - const client = new Client('foo', 'bar') - .usePromises() - .useRequestOpts({ - jsonReviver, - headers: { - Accept: 'text/plain', - 'x-intercom-header': 'bar' - } - }); - - return client.admins.find('baz').then(r => { - assert.equal(200, r.statusCode); - sinon.assert.called(jsonReviver); - // Should always have a user-agent - sinon.assert.calledOnce(userAgentHeaderCheck); - sinon.assert.calledWithMatch(userAgentHeaderCheck, sinon.match.string); - // Shouldn't allow accept header to be overriden - sinon.assert.calledOnce(acceptHeaderCheck); - sinon.assert.calledWithExactly(acceptHeaderCheck, 'application/json'); - // Should include custom header - sinon.assert.calledOnce(customHeaderCheck); - sinon.assert.calledWithExactly(customHeaderCheck, 'bar'); - }); - }); -}); - -describe('base-url', function () { - it('should be able to change base url (using old .useBaseUrl method)', done => { - nock('http://local.test-server.com').get('/admins').reply(200, {}); - const client = new Client('foo', 'bar') - .usePromises() - .useBaseUrl('http://local.test-server.com'); - - client.admins.list().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); -}); diff --git a/test/request-opts.ts b/test/request-opts.ts new file mode 100644 index 00000000..7d88ef1e --- /dev/null +++ b/test/request-opts.ts @@ -0,0 +1,88 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; +import sinon from 'sinon'; +import { HeadersDefaults } from 'axios'; + +describe('request-opts', function () { + it('should be able to change request options', async () => { + nock('https://api.intercom.io').get('/admins/baz').reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }).useRequestOpts({ + proxy: false, + }); + + const response = await client.admins.find({ id: 'baz' }); + + assert.deepStrictEqual({}, response); + assert.deepStrictEqual(client.requestOpts, { + baseURL: 'https://api.intercom.io', + proxy: false, + }); + }); + it('should be able to change request baseURL option', async () => { + nock('http://local.test-server.com').get('/admins/baz').reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }).useRequestOpts({ + baseURL: 'http://local.test-server.com', + }); + + const response = await client.admins.find({ id: 'baz' }); + + assert.deepStrictEqual({}, response); + }); + it('should be able to change request options merging in headers', async () => { + const customHeaderCheck = sinon.stub().returns(true); + const userAgentHeaderCheck = sinon.stub().returns(true); + const acceptHeaderCheck = sinon.stub().returns(true); + + nock('https://api.intercom.io', { + reqheaders: { + 'x-intercom-header': customHeaderCheck, + 'User-Agent': userAgentHeaderCheck, + Accept: acceptHeaderCheck, + }, + }) + .get('/admins/baz') + .reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }).useRequestOpts({ + headers: { + common: { + Accept: 'text/plain', + 'x-intercom-header': 'bar', + }, + } as unknown as HeadersDefaults, + }); + + const response = await client.admins.find({ id: 'baz' }); + + assert.deepStrictEqual({}, response); + // Should always have a user-agent + sinon.assert.calledOnce(userAgentHeaderCheck); + sinon.assert.calledWithMatch(userAgentHeaderCheck, sinon.match.string); + // Shouldn't allow accept header to be overriden + sinon.assert.calledOnce(acceptHeaderCheck); + sinon.assert.calledWithExactly(acceptHeaderCheck, 'application/json'); + // Should include custom header + sinon.assert.calledOnce(customHeaderCheck); + sinon.assert.calledWithExactly(customHeaderCheck, 'bar'); + }); +}); + +describe('base-url', function () { + it('should be able to change base url (using old .usebaseURL method)', async () => { + nock('http://local.test-server.com').get('/admins').reply(200, {}); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }).usebaseURL('http://local.test-server.com'); + + const response = await client.admins.list(); + + assert.deepStrictEqual({}, response); + }); +}); diff --git a/test/scroll.js b/test/scroll.js deleted file mode 100644 index df85705c..00000000 --- a/test/scroll.js +++ /dev/null @@ -1,70 +0,0 @@ -import Bluebird from 'bluebird'; -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('scroll', () => { - before(function () { - nock('https://api.intercom.io').get('/users/scroll').times(3).reply(200, { - type: 'user.list', - scroll_param: '123_soleil', - users: [ - { - type: 'user', - id: 'abc123', - name: 'dummy user' - } - ] - }); - - nock('https://api.intercom.io').get('/users/scroll?scroll_param=123_soleil').times(3).reply(200, { - type: 'user.list', - scroll_param: '123_soleil', - users: [] - }); - }); - - it('should get users with scroll', done => { - const client = new Client('foo', 'bar'); - - client.users.scroll.each({}, function (res) { - assert.equal(200, res.statusCode); - if (res.body.users.length === 0) { - done(); - } - }); - }); - - it('should return a promise that resolves at the end of the scroll', done => { - const client = new Client('foo', 'bar'); - let nbCalls = 0; - - const promise = client.users.scroll.each({}, function () { - nbCalls++; - }); - - promise.then(() => { - assert.equal(2, nbCalls); - - done(); - }); - }); - - it('should wait for promises returned by the callback before scrolling', done => { - const client = new Client('foo', 'bar'); - let nbCalls = 0; - - client.users.scroll.each({}, function (res) { - nbCalls++; - - return res.body.users.length === 0 ? - done() : - new Bluebird((resolve) => { - setTimeout(() => { - assert.equal(1, nbCalls, 'hasn\'t re-scrolled before resolve'); - resolve(); - }, 500); - }); - }); - }); -}); diff --git a/test/segment.js b/test/segment.js deleted file mode 100644 index 1a32351b..00000000 --- a/test/segment.js +++ /dev/null @@ -1,22 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('segments', () => { - it('should be listed', done => { - nock('https://api.intercom.io').get('/segments').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.segments.list().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('find by id', done => { - nock('https://api.intercom.io').get('/segments/baz').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.segments.find({ id: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); -}); diff --git a/test/segment.ts b/test/segment.ts new file mode 100644 index 00000000..718df81a --- /dev/null +++ b/test/segment.ts @@ -0,0 +1,43 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; + +describe('segments', () => { + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + it('should be listed', async () => { + const queryParams = { + include_count: true, + }; + + nock('https://api.intercom.io') + .get('/segments') + .query(queryParams) + .reply(200, {}); + const response = await client.segments.list({ + includeCount: queryParams.include_count, + }); + + assert.deepStrictEqual({}, response); + }); + it('find by id', async () => { + const id = 'baz'; + const queryParams = { + include_count: true, + }; + + nock('https://api.intercom.io') + .get(`/segments/${id}`) + .query(queryParams) + .reply(200, {}); + + const response = await client.segments.find({ + id, + includeCount: queryParams.include_count, + }); + + assert.deepStrictEqual({}, response); + }); +}); diff --git a/test/snippet.js b/test/snippet.js deleted file mode 100644 index e4f02119..00000000 --- a/test/snippet.js +++ /dev/null @@ -1,108 +0,0 @@ -import Snippet from '../lib/snippet'; -import assert from 'assert'; - -describe('snippet', () => { - it('should be able to grab the verification secret', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - user_id: 1 - }; - const snippet = new Snippet(settings); - assert.equal(snippet.getVerificationSecret(), 'abc123'); - }); - - it('should grab the user_id as the identifier', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - user_id: 1, - email: 'peter@intercom.io' - }; - const snippet = new Snippet(settings); - assert.equal(snippet.getIdentifier(), 1); - }); - - it('should grab the email as the identifier if no user_id', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - email: 'peter@intercom.io' - }; - const snippet = new Snippet(settings); - assert.equal(snippet.getIdentifier(), 'peter@intercom.io'); - }); - - it('should throw an error if there\'s no verification secret', () => { - const settings = { - app_id: 'xyz789', - user_id: 1 - }; - assert.throws(() => new Snippet(settings), Error); - }); - - it('should error if there\'s no app_id', () => { - const settings = { - verificationSecret: 'abc123', - user_id: 1 - }; - assert.throws(() => new Snippet(settings), Error); - }); - - it('should return the logged out snippet if no identifier', () => { - const settings = { - app_id: 'xyz789' - }; - const snippet = new Snippet(settings); - assert.equal(snippet.settingsToString(settings), 'app_id: "xyz789"'); - }); - - it('should escape bad stuff', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - email: 'peter@"intercom.io' - }; - const snippet = new Snippet(settings); - assert.equal(snippet.settingsToString(settings), 'verificationSecret: "abc123", app_id: "xyz789", email: "peter@\\"<script>alert(1)</script>intercom.io"'); - }); - - it('should not include the verification secret in the snippet html', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - user_id: 1, - email: 'peter@intercom.io', - name: 'Peter McKenna', - company: { - id: 123, - name: 'Intercom' - } - }; - const snippet = new Snippet(settings); - assert.equal(snippet.create().indexOf(settings.verificationSecret), -1); - }); - - it('should return the snippet html', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - user_id: 1, - email: 'peter@intercom.io', - name: 'Peter McKenna', - company: { - id: 123, - name: 'Intercom' - } - }; - const snippet = new Snippet(settings); - assert.equal(snippet.create(), ` - - - `); - }); -}); diff --git a/test/tag.js b/test/tag.js deleted file mode 100644 index c9cda558..00000000 --- a/test/tag.js +++ /dev/null @@ -1,54 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('tags', () => { - it('should be created/updated', done => { - nock('https://api.intercom.io').post('/tags').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.tags.create({ name: 'haven' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should tag users and companies', done => { - nock('https://api.intercom.io').post('/tags', { name: 'haven', users: [{ id: '5534534' }] }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.tags.tag({ name: 'haven', users: [{ id: '5534534' }] }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should untag users', done => { - nock('https://api.intercom.io').post('/tags', { name: 'haven', users: [{ id: '5534534', untag: true }] }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.tags.untag({ name: 'haven', users: [{ id: '5534534' }] }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should untag companies', done => { - nock('https://api.intercom.io').post('/tags', { name: 'haven', companies: [{ id: '5534534', untag: true }] }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.tags.untag({ name: 'haven', companies: [{ id: '5534534' }] }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should delete tags', done => { - nock('https://api.intercom.io').delete('/tags/baz').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.tags.delete({ id: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should list', done => { - nock('https://api.intercom.io').get('/tags').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.tags.list().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); -}); diff --git a/test/tag.ts b/test/tag.ts new file mode 100644 index 00000000..8fa5d39a --- /dev/null +++ b/test/tag.ts @@ -0,0 +1,175 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; + +describe('tags', () => { + it('should be created', async () => { + const requestBody = { + name: 'haven', + }; + + nock('https://api.intercom.io') + .post('/tags', requestBody) + .reply(200, {}); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.tags.create({ name: 'haven' }); + + assert.deepStrictEqual({}, response); + }); + it('should be updated', async () => { + const requestBody = { + id: '123', + name: 'haven', + }; + + nock('https://api.intercom.io') + .post('/tags', requestBody) + .reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.tags.update({ id: '123', name: 'haven' }); + + assert.deepStrictEqual({}, response); + }); + it('should delete tags', async () => { + nock('https://api.intercom.io').delete('/tags/baz').reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.tags.delete({ id: 'baz' }); + + assert.deepStrictEqual({}, response); + }); + it('should tag contacts', async () => { + const contactId = 'contactid123'; + const requestBody = { + id: 'tagid123', + }; + + nock('https://api.intercom.io') + .post(`/contacts/${contactId}/tags`, requestBody) + .reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.tags.tagContact({ + contactId, + tagId: requestBody.id, + }); + + assert.deepStrictEqual({}, response); + }); + it('should tag conversations', async () => { + const conversationId = 'contactid123'; + const requestBody = { + id: 'tagid123', + admin_id: 'adminid123', + }; + + nock('https://api.intercom.io') + .post(`/conversations/${conversationId}/tags`, requestBody) + .reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.tags.tagConversation({ + conversationId, + tagId: requestBody.id, + adminId: requestBody.admin_id, + }); + + assert.deepStrictEqual({}, response); + }); + it('should tag companies', async () => { + const requestBody = { + name: 'tagname_69', + companies: [{ id: '123' }, { id: '234' }, { id: '456' }], + }; + + nock('https://api.intercom.io') + .post(`/tags`, requestBody) + .reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.tags.tagCompanies({ + tagName: requestBody.name, + companiesIds: ['123', '234', '456'], + }); + + assert.deepStrictEqual({}, response); + }); + it('should untag contacts', async () => { + const { contactId, tagId } = { + contactId: 'contactId123', + tagId: 'tagId123', + }; + + nock('https://api.intercom.io') + .delete(`/contacts/${contactId}/tags/${tagId}`) + .reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.tags.untagContact({ contactId, tagId }); + + assert.deepStrictEqual({}, response); + }); + it('should untag conversations', async () => { + const conversationId = 'contactid123'; + const requestBody = { + id: 'tagid123', + admin_id: 'adminid123', + }; + + nock('https://api.intercom.io') + .delete(`/conversations/${conversationId}/tags/${requestBody.id}`) + .reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.tags.untagConversation({ + conversationId, + tagId: requestBody.id, + adminId: requestBody.admin_id, + }); + + assert.deepStrictEqual({}, response); + }); + it('should untag companies', async () => { + const requestBody = { + name: 'tagname_69', + companies: [ + { id: '123', untag: true }, + { id: '234', untag: true }, + { id: '456', untag: true }, + ], + }; + + nock('https://api.intercom.io') + .post(`/tags`, requestBody) + .reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.tags.untagCompanies({ + tagName: requestBody.name, + companiesIds: ['123', '234', '456'], + }); + + assert.deepStrictEqual({}, response); + }); + it('should list', async () => { + nock('https://api.intercom.io').get('/tags').reply(200, {}); + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + const response = await client.tags.list(); + + assert.deepStrictEqual({}, response); + }); +}); diff --git a/test/team.ts b/test/team.ts new file mode 100644 index 00000000..123ce6fd --- /dev/null +++ b/test/team.ts @@ -0,0 +1,33 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; + +describe('teams', () => { + let client: Client; + + before(() => { + client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + }); + + it('should be retrieved by id', async () => { + const teamId = '123'; + + nock('https://api.intercom.io').get(`/teams/${teamId}`).reply(200, {}); + + const response = await client.teams.find({ + id: teamId, + }); + + assert.deepStrictEqual({}, response); + }); + + it('should list all teams', async () => { + nock('https://api.intercom.io').get('/teams').reply(200, {}); + + const response = await client.teams.list(); + + assert.deepStrictEqual({}, response); + }); +}); diff --git a/test/user-data.js b/test/user-data.js deleted file mode 100644 index d887f795..00000000 --- a/test/user-data.js +++ /dev/null @@ -1,166 +0,0 @@ -import UserData from '../lib/user-data'; -import { IdentityVerification } from '../lib/index'; -import assert from 'assert'; -import sinon from 'sinon'; - -describe('userData', () => { - it('should be able to grab the verification secret', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - user_id: 1 - }; - const userData = new UserData(settings); - assert.equal(userData.getVerificationSecret(), 'abc123'); - }); - - it('should grab the user_id as the identifier', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - user_id: 1, - email: 'jess@intercom.io' - }; - const userData = new UserData(settings); - const userHash = sinon.spy(IdentityVerification, 'userHash'); - userData.json(); - userHash.restore(); - sinon.assert.calledWith(userHash, { - secretKey: 'abc123', - identifier: '1' - }); - }); - - it('should grab the email as the identifier if no user_id', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - email: 'jess@intercom.io' - }; - const userData = new UserData(settings); - const userHash = sinon.spy(IdentityVerification, 'userHash'); - userData.json(); - userHash.restore(); - sinon.assert.calledWith(userHash, { - secretKey: 'abc123', - identifier: 'jess@intercom.io' - }); - }); - - it('should throw an error if there\'s no verification secret', () => { - const settings = { - app_id: 'xyz789', - user_id: 1 - }; - assert.throws(() => new UserData(settings), Error); - }); - - it('should error if there\'s no app_id', () => { - const settings = { - verificationSecret: 'abc123', - user_id: 1 - }; - assert.throws(() => new UserData(settings), Error); - }); - - it('should return the logged out userData if no identifier', () => { - const settings = { - app_id: 'xyz789' - }; - const userData = new UserData(settings); - assert.equal(JSON.stringify(userData.json()), JSON.stringify({ app_id: 'xyz789'})); - }); - - it('should escape bad stuff in values', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - email: 'jess@"intercom.io' - }; - const userData = new UserData(settings); - assert.equal(userData.json().email, 'jess@\\"<script>alert(1)</script>intercom.io'); - }); - - it('should escape bad stuff in object keys', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - user_id: '1' - }; - settings[''] = 'jess@"intercom.io'; - const userData = new UserData(settings); - const result = userData.json(); - assert.equal(result['<script>doSomethingEvil();</script>'], 'jess@\\\"<script>alert(1)</script>intercom.io'); - }); - - it('should escape bad stuff in next object keys and values', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - user_id: '1' - }; - settings.maliciousSettings = { - '': 'jess@"intercom.io' - }; - const userData = new UserData(settings); - const result = userData.json(); - assert.equal(result.maliciousSettings['<script>doSomethingEvil();</script>'], 'jess@\\"<script>alert(1)</script>intercom.io'); - }); - - it('should not include the verification secret in the userData', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - user_id: 1, - email: 'jess@intercom.io', - name: 'Jess OB', - company: { - id: 123, - name: 'Intercom' - } - }; - const userData = new UserData(settings); - const result = userData.json(); - assert.equal(Object.keys(result).indexOf(settings.verificationSecret), -1); - }); - - it('should skip setUserHash if user_hash is already defined', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - user_id: 1 - }; - const userData = new UserData(settings); - const userHash = sinon.spy(IdentityVerification, 'userHash'); - userData.json(); - userData.json(); - userHash.restore(); - sinon.assert.calledOnce(userHash); - }); - - it('should return the userData', () => { - const settings = { - verificationSecret: 'abc123', - app_id: 'xyz789', - user_id: 1, - email: 'jess@intercom.io', - name: 'Jess OB', - company: { - id: 123, - name: 'Intercom' - } - }; - const userData = new UserData(settings); - assert.equal(JSON.stringify(userData.json()), JSON.stringify({ - app_id: 'xyz789', - user_id: 1, - email: 'jess@intercom.io', - name: 'Jess OB', - company: { - id: 123, - name: 'Intercom' - }, - user_hash: 'f02877f24c9dd37542268a28627ebaf2e07d0d114d9482abcdc20f60874b40b3' - })); - }); -}); diff --git a/test/user.js b/test/user.js deleted file mode 100644 index 71172c97..00000000 --- a/test/user.js +++ /dev/null @@ -1,180 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('users', () => { - it('should be created', done => { - nock('https://api.intercom.io').post('/users', { email: 'foo@bar.com' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.users.create({ email: 'foo@bar.com' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should be updated', done => { - nock('https://api.intercom.io').post('/users', { email: 'foo@bar.com' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.users.update({ email: 'foo@bar.com' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should list', done => { - nock('https://api.intercom.io').get('/users').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.users.list().then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should list by params', done => { - nock('https://api.intercom.io').get('/users').query({ tag_id: '1234' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.users.listBy({ tag_id: '1234' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should find users by id', done => { - nock('https://api.intercom.io').get('/users/baz').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.users.find({ id: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should find users by user_id', done => { - nock('https://api.intercom.io').get('/users').query({ user_id: 'foo' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.users.find({ user_id: 'foo' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should find users by email', done => { - nock('https://api.intercom.io').get('/users').query({ email: 'foo' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.users.find({ email: 'foo' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should archive users by id', done => { - nock('https://api.intercom.io').delete('/users/baz').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.users.archive({ id: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should archive users by user_id', done => { - nock('https://api.intercom.io').delete('/users').query({ user_id: 'foo' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.users.archive({ user_id: 'foo' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should archive users by email', done => { - nock('https://api.intercom.io').delete('/users').query({ email: 'foo' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.users.archive({ email: 'foo' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should archive (using old delete function) users by id', done => { - nock('https://api.intercom.io').delete('/users/baz').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.users.delete({ id: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should archive (using old delete function) users by user_id', done => { - nock('https://api.intercom.io').delete('/users').query({ user_id: 'foo' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.users.delete({ user_id: 'foo' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should archive (using old delete function) users by email', done => { - nock('https://api.intercom.io').delete('/users').query({ email: 'foo' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.users.delete({ email: 'foo' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should permanently delete users by intercom user ID', done => { - nock('https://api.intercom.io').post('/user_delete_requests', { intercom_user_id: 'foo' }).reply(200, { id: 10 }); - const client = new Client('foo', 'bar').usePromises(); - client.users.requestPermanentDeletion('foo').then(r => { - assert.equal(200, r.statusCode); - assert.deepStrictEqual({ id: 10 }, r.body); - done(); - }); - }); - it('should permanently delete users by Intercom user ID in params', (done) => { - nock('https://api.intercom.io') - .post('/user_delete_requests', { intercom_user_id: 'foo' }) - .reply(200, { id: 10 }); - const client = new Client('foo', 'bar').usePromises(); - client.users.requestPermanentDeletionByParams({id: 'foo'}).then((r) => { - assert.equal(200, r.statusCode); - assert.deepStrictEqual({ id: 10 }, r.body); - done(); - }); - }); - it('should permanently delete users by user_id', (done) => { - nock('https://api.intercom.io') - .get('/users') - .query({ user_id: 'foo' }) - .reply(200, { id: 10 }) - .post('/user_delete_requests', { intercom_user_id: 10 }) - .reply(200, { id: 10 }); - const client = new Client('foo', 'bar').usePromises(); - client.users.requestPermanentDeletionByParams({user_id: 'foo'}).then((r) => { - assert.equal(200, r.statusCode); - assert.deepStrictEqual({ id: 10 }, r.body); - done(); - }); - }); - it('should permanently delete users by email', (done) => { - nock('https://api.intercom.io') - .get('/users') - .query({ email: 'foo' }) - .reply(200, { id: 10 }) - .post('/user_delete_requests', { intercom_user_id: 10 }) - .reply(200, { id: 10 }); - const client = new Client('foo', 'bar').usePromises(); - client.users.requestPermanentDeletionByParams({email: 'foo'}).then((r) => { - assert.equal(200, r.statusCode); - assert.deepStrictEqual({ id: 10 }, r.body); - done(); - }); - }); - it('should callback with errors if calls fail', (done) => { - nock('https://api.intercom.io') - .get('/users') - .query({ email: 'foo' }) - .reply(200, {type: 'error.list'}); - const client = new Client('foo', 'bar'); - client.users.requestPermanentDeletionByParams({email: 'foo'}, (err) => { - assert.equal(true, err instanceof Error); - done(); - }); - }); - it('should reject promises if calls fail', (done) => { - nock('https://api.intercom.io') - .get('/users') - .query({ email: 'foo' }) - .reply(200, {type: 'error.list'}); - const client = new Client('foo', 'bar').usePromises(); - client.users.requestPermanentDeletionByParams({email: 'foo'}).catch(err => { - assert.equal(true, err instanceof Error); - done(); - }); - }); -}); diff --git a/test/visitor.js b/test/visitor.js deleted file mode 100644 index ba9c9e01..00000000 --- a/test/visitor.js +++ /dev/null @@ -1,63 +0,0 @@ -import assert from 'assert'; -import {Client} from '../lib'; -import nock from 'nock'; - -describe('visitors', () => { - it('should be updated', done => { - nock('https://api.intercom.io').post('/visitors', { id: 'baz', email: 'foo@intercom.io' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.visitors.update({ id: 'baz', email: 'foo@intercom.io' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should find by user_id', done => { - nock('https://api.intercom.io').get('/visitors').query({ user_id: '1234-5678-9876' }).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.visitors.find({ user_id: '1234-5678-9876' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should find by id', done => { - nock('https://api.intercom.io').get('/visitors/baz').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.visitors.find({ id: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('delete by id', done => { - nock('https://api.intercom.io').delete('/visitors/baz').reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.visitors.delete({ id: 'baz' }).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should convert to user', done => { - const conversionObject = { - visitor: { user_id: 'baz' }, - user: { email: 'bang' }, - type: 'user' - }; - nock('https://api.intercom.io').post('/visitors/convert', conversionObject).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.visitors.convert(conversionObject).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); - it('should convert to lead', done => { - const conversionObject = { - visitor: { user_id: 'baz' }, - type: 'lead' - }; - nock('https://api.intercom.io').post('/visitors/convert', conversionObject).reply(200, {}); - const client = new Client('foo', 'bar').usePromises(); - client.visitors.convert(conversionObject).then(r => { - assert.equal(200, r.statusCode); - done(); - }); - }); -}); diff --git a/tsconfig.json b/tsconfig.json new file mode 100644 index 00000000..94d0069f --- /dev/null +++ b/tsconfig.json @@ -0,0 +1,30 @@ +{ + "compilerOptions": { + "lib": ["es5", "es6"], + "outDir": "./dist", + "allowSyntheticDefaultImports": true, + "esModuleInterop": true, + "target": "es5", + "module": "commonjs", + "moduleResolution": "node", + "importHelpers": true, + "emitDecoratorMetadata": true, + "experimentalDecorators": true, + "sourceMap": true, + "noImplicitAny": true, + "noFallthroughCasesInSwitch": true, + "noImplicitReturns": true, + "stripInternal": true, + "pretty": true, + "strictNullChecks": true, + "noUnusedLocals": true, + "downlevelIteration": true, + "rootDir": ".", + // Ensure that .d.ts files are created by tsc, but not .js files + "declaration": true, + "declarationMap": true, + "resolveJsonModule": true + }, + "include": ["lib/**/*"], + "exclude": ["node_modules"] +} diff --git a/yarn.lock b/yarn.lock index 6c8395f2..9ff9500a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1,5280 +1,3588 @@ -# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. -# yarn lockfile v1 - - -"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.12.13.tgz#dcfc826beef65e75c50e21d3837d7d95798dd658" - integrity sha512-HV1Cm0Q3ZrpCR93tkWOYiuYIgLxZXZFVG2VgK+MBWjUqZTundupbfx2aXarXuw5Ko5aMcjtJgbSs4vUGBS5v6g== - dependencies: - "@babel/highlight" "^7.12.13" - -"@babel/compat-data@^7.13.11", "@babel/compat-data@^7.13.15", "@babel/compat-data@^7.13.8": - version "7.13.15" - resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.13.15.tgz#7e8eea42d0b64fda2b375b22d06c605222e848f4" - integrity sha512-ltnibHKR1VnrU4ymHyQ/CXtNXI6yZC0oJThyW78Hft8XndANwi+9H+UIklBDraIjFEJzw8wmcM427oDd9KS5wA== - -"@babel/core@^7.13.16": - version "7.13.16" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.13.16.tgz#7756ab24396cc9675f1c3fcd5b79fcce192ea96a" - integrity sha512-sXHpixBiWWFti0AV2Zq7avpTasr6sIAu7Y396c608541qAU2ui4a193m0KSQmfPSKFZLnQ3cvlKDOm3XkuXm3Q== - dependencies: - "@babel/code-frame" "^7.12.13" - "@babel/generator" "^7.13.16" - "@babel/helper-compilation-targets" "^7.13.16" - "@babel/helper-module-transforms" "^7.13.14" - "@babel/helpers" "^7.13.16" - "@babel/parser" "^7.13.16" - "@babel/template" "^7.12.13" - "@babel/traverse" "^7.13.15" - "@babel/types" "^7.13.16" - convert-source-map "^1.7.0" - debug "^4.1.0" - gensync "^1.0.0-beta.2" - json5 "^2.1.2" - semver "^6.3.0" - source-map "^0.5.0" - -"@babel/generator@^7.13.16": - version "7.13.16" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.13.16.tgz#0befc287031a201d84cdfc173b46b320ae472d14" - integrity sha512-grBBR75UnKOcUWMp8WoDxNsWCFl//XCK6HWTrBQKTr5SV9f5g0pNOjdyzi/DTBv12S9GnYPInIXQBTky7OXEMg== - dependencies: - "@babel/types" "^7.13.16" - jsesc "^2.5.1" - source-map "^0.5.0" - -"@babel/helper-annotate-as-pure@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.12.13.tgz#0f58e86dfc4bb3b1fcd7db806570e177d439b6ab" - integrity sha512-7YXfX5wQ5aYM/BOlbSccHDbuXXFPxeoUmfWtz8le2yTkTZc+BxsiEnENFoi2SlmA8ewDkG2LgIMIVzzn2h8kfw== - dependencies: - "@babel/types" "^7.12.13" - -"@babel/helper-builder-binary-assignment-operator-visitor@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.12.13.tgz#6bc20361c88b0a74d05137a65cac8d3cbf6f61fc" - integrity sha512-CZOv9tGphhDRlVjVkAgm8Nhklm9RzSmWpX2my+t7Ua/KT616pEzXsQCjinzvkRvHWJ9itO4f296efroX23XCMA== - dependencies: - "@babel/helper-explode-assignable-expression" "^7.12.13" - "@babel/types" "^7.12.13" - -"@babel/helper-compilation-targets@^7.13.0", "@babel/helper-compilation-targets@^7.13.13", "@babel/helper-compilation-targets@^7.13.16", "@babel/helper-compilation-targets@^7.13.8": - version "7.13.16" - resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.13.16.tgz#6e91dccf15e3f43e5556dffe32d860109887563c" - integrity sha512-3gmkYIrpqsLlieFwjkGgLaSHmhnvlAYzZLlYVjlW+QwI+1zE17kGxuJGmIqDQdYp56XdmGeD+Bswx0UTyG18xA== - dependencies: - "@babel/compat-data" "^7.13.15" - "@babel/helper-validator-option" "^7.12.17" - browserslist "^4.14.5" - semver "^6.3.0" - -"@babel/helper-create-class-features-plugin@^7.13.0": - version "7.13.11" - resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.13.11.tgz#30d30a005bca2c953f5653fc25091a492177f4f6" - integrity sha512-ays0I7XYq9xbjCSvT+EvysLgfc3tOkwCULHjrnscGT3A9qD4sk3wXnJ3of0MAWsWGjdinFvajHU2smYuqXKMrw== - dependencies: - "@babel/helper-function-name" "^7.12.13" - "@babel/helper-member-expression-to-functions" "^7.13.0" - "@babel/helper-optimise-call-expression" "^7.12.13" - "@babel/helper-replace-supers" "^7.13.0" - "@babel/helper-split-export-declaration" "^7.12.13" - -"@babel/helper-create-regexp-features-plugin@^7.12.13": - version "7.12.17" - resolved "https://registry.yarnpkg.com/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.12.17.tgz#a2ac87e9e319269ac655b8d4415e94d38d663cb7" - integrity sha512-p2VGmBu9oefLZ2nQpgnEnG0ZlRPvL8gAGvPUMQwUdaE8k49rOMuZpOwdQoy5qJf6K8jL3bcAMhVUlHAjIgJHUg== - dependencies: - "@babel/helper-annotate-as-pure" "^7.12.13" - regexpu-core "^4.7.1" - -"@babel/helper-define-polyfill-provider@^0.2.0": - version "0.2.0" - resolved "https://registry.yarnpkg.com/@babel/helper-define-polyfill-provider/-/helper-define-polyfill-provider-0.2.0.tgz#a640051772045fedaaecc6f0c6c69f02bdd34bf1" - integrity sha512-JT8tHuFjKBo8NnaUbblz7mIu1nnvUDiHVjXXkulZULyidvo/7P6TY7+YqpV37IfF+KUFxmlK04elKtGKXaiVgw== - dependencies: - "@babel/helper-compilation-targets" "^7.13.0" - "@babel/helper-module-imports" "^7.12.13" - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/traverse" "^7.13.0" - debug "^4.1.1" - lodash.debounce "^4.0.8" - resolve "^1.14.2" - semver "^6.1.2" - -"@babel/helper-explode-assignable-expression@^7.12.13": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.13.0.tgz#17b5c59ff473d9f956f40ef570cf3a76ca12657f" - integrity sha512-qS0peLTDP8kOisG1blKbaoBg/o9OSa1qoumMjTK5pM+KDTtpxpsiubnCGP34vK8BXGcb2M9eigwgvoJryrzwWA== - dependencies: - "@babel/types" "^7.13.0" - -"@babel/helper-function-name@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.12.13.tgz#93ad656db3c3c2232559fd7b2c3dbdcbe0eb377a" - integrity sha512-TZvmPn0UOqmvi5G4vvw0qZTpVptGkB1GL61R6lKvrSdIxGm5Pky7Q3fpKiIkQCAtRCBUwB0PaThlx9vebCDSwA== - dependencies: - "@babel/helper-get-function-arity" "^7.12.13" - "@babel/template" "^7.12.13" - "@babel/types" "^7.12.13" - -"@babel/helper-get-function-arity@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.12.13.tgz#bc63451d403a3b3082b97e1d8b3fe5bd4091e583" - integrity sha512-DjEVzQNz5LICkzN0REdpD5prGoidvbdYk1BVgRUOINaWJP2t6avB27X1guXK1kXNrX0WMfsrm1A/ZBthYuIMQg== - dependencies: - "@babel/types" "^7.12.13" - -"@babel/helper-hoist-variables@^7.13.0": - version "7.13.16" - resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.13.16.tgz#1b1651249e94b51f8f0d33439843e33e39775b30" - integrity sha512-1eMtTrXtrwscjcAeO4BVK+vvkxaLJSPFz1w1KLawz6HLNi9bPFGBNwwDyVfiu1Tv/vRRFYfoGaKhmAQPGPn5Wg== - dependencies: - "@babel/traverse" "^7.13.15" - "@babel/types" "^7.13.16" - -"@babel/helper-member-expression-to-functions@^7.13.0", "@babel/helper-member-expression-to-functions@^7.13.12": - version "7.13.12" - resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.13.12.tgz#dfe368f26d426a07299d8d6513821768216e6d72" - integrity sha512-48ql1CLL59aKbU94Y88Xgb2VFy7a95ykGRbJJaaVv+LX5U8wFpLfiGXJJGUozsmA1oEh/o5Bp60Voq7ACyA/Sw== - dependencies: - "@babel/types" "^7.13.12" - -"@babel/helper-module-imports@^7.12.13", "@babel/helper-module-imports@^7.13.12": - version "7.13.12" - resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.13.12.tgz#c6a369a6f3621cb25da014078684da9196b61977" - integrity sha512-4cVvR2/1B693IuOvSI20xqqa/+bl7lqAMR59R4iu39R9aOX8/JoYY1sFaNvUMyMBGnHdwvJgUrzNLoUZxXypxA== - dependencies: - "@babel/types" "^7.13.12" - -"@babel/helper-module-transforms@^7.13.0", "@babel/helper-module-transforms@^7.13.14": - version "7.13.14" - resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.13.14.tgz#e600652ba48ccb1641775413cb32cfa4e8b495ef" - integrity sha512-QuU/OJ0iAOSIatyVZmfqB0lbkVP0kDRiKj34xy+QNsnVZi/PA6BoSoreeqnxxa9EHFAIL0R9XOaAR/G9WlIy5g== - dependencies: - "@babel/helper-module-imports" "^7.13.12" - "@babel/helper-replace-supers" "^7.13.12" - "@babel/helper-simple-access" "^7.13.12" - "@babel/helper-split-export-declaration" "^7.12.13" - "@babel/helper-validator-identifier" "^7.12.11" - "@babel/template" "^7.12.13" - "@babel/traverse" "^7.13.13" - "@babel/types" "^7.13.14" - -"@babel/helper-optimise-call-expression@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.12.13.tgz#5c02d171b4c8615b1e7163f888c1c81c30a2aaea" - integrity sha512-BdWQhoVJkp6nVjB7nkFWcn43dkprYauqtk++Py2eaf/GRDFm5BxRqEIZCiHlZUGAVmtwKcsVL1dC68WmzeFmiA== - dependencies: - "@babel/types" "^7.12.13" - -"@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.13.0", "@babel/helper-plugin-utils@^7.8.0", "@babel/helper-plugin-utils@^7.8.3": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.13.0.tgz#806526ce125aed03373bc416a828321e3a6a33af" - integrity sha512-ZPafIPSwzUlAoWT8DKs1W2VyF2gOWthGd5NGFMsBcMMol+ZhK+EQY/e6V96poa6PA/Bh+C9plWN0hXO1uB8AfQ== - -"@babel/helper-remap-async-to-generator@^7.13.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.13.0.tgz#376a760d9f7b4b2077a9dd05aa9c3927cadb2209" - integrity sha512-pUQpFBE9JvC9lrQbpX0TmeNIy5s7GnZjna2lhhcHC7DzgBs6fWn722Y5cfwgrtrqc7NAJwMvOa0mKhq6XaE4jg== - dependencies: - "@babel/helper-annotate-as-pure" "^7.12.13" - "@babel/helper-wrap-function" "^7.13.0" - "@babel/types" "^7.13.0" - -"@babel/helper-replace-supers@^7.12.13", "@babel/helper-replace-supers@^7.13.0", "@babel/helper-replace-supers@^7.13.12": - version "7.13.12" - resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.13.12.tgz#6442f4c1ad912502481a564a7386de0c77ff3804" - integrity sha512-Gz1eiX+4yDO8mT+heB94aLVNCL+rbuT2xy4YfyNqu8F+OI6vMvJK891qGBTqL9Uc8wxEvRW92Id6G7sDen3fFw== - dependencies: - "@babel/helper-member-expression-to-functions" "^7.13.12" - "@babel/helper-optimise-call-expression" "^7.12.13" - "@babel/traverse" "^7.13.0" - "@babel/types" "^7.13.12" - -"@babel/helper-simple-access@^7.12.13", "@babel/helper-simple-access@^7.13.12": - version "7.13.12" - resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.13.12.tgz#dd6c538afb61819d205a012c31792a39c7a5eaf6" - integrity sha512-7FEjbrx5SL9cWvXioDbnlYTppcZGuCY6ow3/D5vMggb2Ywgu4dMrpTJX0JdQAIcRRUElOIxF3yEooa9gUb9ZbA== - dependencies: - "@babel/types" "^7.13.12" - -"@babel/helper-skip-transparent-expression-wrappers@^7.12.1": - version "7.12.1" - resolved "https://registry.yarnpkg.com/@babel/helper-skip-transparent-expression-wrappers/-/helper-skip-transparent-expression-wrappers-7.12.1.tgz#462dc63a7e435ade8468385c63d2b84cce4b3cbf" - integrity sha512-Mf5AUuhG1/OCChOJ/HcADmvcHM42WJockombn8ATJG3OnyiSxBK/Mm5x78BQWvmtXZKHgbjdGL2kin/HOLlZGA== - dependencies: - "@babel/types" "^7.12.1" - -"@babel/helper-split-export-declaration@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.12.13.tgz#e9430be00baf3e88b0e13e6f9d4eaf2136372b05" - integrity sha512-tCJDltF83htUtXx5NLcaDqRmknv652ZWCHyoTETf1CXYJdPC7nohZohjUgieXhv0hTJdRf2FjDueFehdNucpzg== - dependencies: - "@babel/types" "^7.12.13" - -"@babel/helper-validator-identifier@^7.12.11": - version "7.12.11" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.12.11.tgz#c9a1f021917dcb5ccf0d4e453e399022981fc9ed" - integrity sha512-np/lG3uARFybkoHokJUmf1QfEvRVCPbmQeUQpKow5cQ3xWrV9i3rUHodKDJPQfTVX61qKi+UdYk8kik84n7XOw== - -"@babel/helper-validator-option@^7.12.17": - version "7.12.17" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.12.17.tgz#d1fbf012e1a79b7eebbfdc6d270baaf8d9eb9831" - integrity sha512-TopkMDmLzq8ngChwRlyjR6raKD6gMSae4JdYDB8bByKreQgG0RBTuKe9LRxW3wFtUnjxOPRKBDwEH6Mg5KeDfw== - -"@babel/helper-wrap-function@^7.13.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/helper-wrap-function/-/helper-wrap-function-7.13.0.tgz#bdb5c66fda8526ec235ab894ad53a1235c79fcc4" - integrity sha512-1UX9F7K3BS42fI6qd2A4BjKzgGjToscyZTdp1DjknHLCIvpgne6918io+aL5LXFcER/8QWiwpoY902pVEqgTXA== - dependencies: - "@babel/helper-function-name" "^7.12.13" - "@babel/template" "^7.12.13" - "@babel/traverse" "^7.13.0" - "@babel/types" "^7.13.0" - -"@babel/helpers@^7.13.16": - version "7.13.17" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.13.17.tgz#b497c7a00e9719d5b613b8982bda6ed3ee94caf6" - integrity sha512-Eal4Gce4kGijo1/TGJdqp3WuhllaMLSrW6XcL0ulyUAQOuxHcCafZE8KHg9857gcTehsm/v7RcOx2+jp0Ryjsg== - dependencies: - "@babel/template" "^7.12.13" - "@babel/traverse" "^7.13.17" - "@babel/types" "^7.13.17" - -"@babel/highlight@^7.12.13": - version "7.13.10" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.13.10.tgz#a8b2a66148f5b27d666b15d81774347a731d52d1" - integrity sha512-5aPpe5XQPzflQrFwL1/QoeHkP2MsA4JCntcXHRhEsdsfPVkvPi2w7Qix4iV7t5S/oC9OodGrggd8aco1g3SZFg== - dependencies: - "@babel/helper-validator-identifier" "^7.12.11" - chalk "^2.0.0" - js-tokens "^4.0.0" - -"@babel/parser@^7.12.13", "@babel/parser@^7.13.16", "@babel/parser@^7.7.0": - version "7.13.16" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.13.16.tgz#0f18179b0448e6939b1f3f5c4c355a3a9bcdfd37" - integrity sha512-6bAg36mCwuqLO0hbR+z7PHuqWiCeP7Dzg73OpQwsAB1Eb8HnGEz5xYBzCfbu+YjoaJsJs+qheDxVAuqbt3ILEw== - -"@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@^7.13.12": - version "7.13.12" - resolved "https://registry.yarnpkg.com/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/-/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.13.12.tgz#a3484d84d0b549f3fc916b99ee4783f26fabad2a" - integrity sha512-d0u3zWKcoZf379fOeJdr1a5WPDny4aOFZ6hlfKivgK0LY7ZxNfoaHL2fWwdGtHyVvra38FC+HVYkO+byfSA8AQ== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/helper-skip-transparent-expression-wrappers" "^7.12.1" - "@babel/plugin-proposal-optional-chaining" "^7.13.12" - -"@babel/plugin-proposal-async-generator-functions@^7.13.15": - version "7.13.15" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.13.15.tgz#80e549df273a3b3050431b148c892491df1bcc5b" - integrity sha512-VapibkWzFeoa6ubXy/NgV5U2U4MVnUlvnx6wo1XhlsaTrLYWE0UFpDQsVrmn22q5CzeloqJ8gEMHSKxuee6ZdA== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/helper-remap-async-to-generator" "^7.13.0" - "@babel/plugin-syntax-async-generators" "^7.8.4" - -"@babel/plugin-proposal-class-properties@^7.13.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.13.0.tgz#146376000b94efd001e57a40a88a525afaab9f37" - integrity sha512-KnTDjFNC1g+45ka0myZNvSBFLhNCLN+GeGYLDEA8Oq7MZ6yMgfLoIRh86GRT0FjtJhZw8JyUskP9uvj5pHM9Zg== - dependencies: - "@babel/helper-create-class-features-plugin" "^7.13.0" - "@babel/helper-plugin-utils" "^7.13.0" - -"@babel/plugin-proposal-dynamic-import@^7.13.8": - version "7.13.8" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.13.8.tgz#876a1f6966e1dec332e8c9451afda3bebcdf2e1d" - integrity sha512-ONWKj0H6+wIRCkZi9zSbZtE/r73uOhMVHh256ys0UzfM7I3d4n+spZNWjOnJv2gzopumP2Wxi186vI8N0Y2JyQ== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/plugin-syntax-dynamic-import" "^7.8.3" - -"@babel/plugin-proposal-export-namespace-from@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-export-namespace-from/-/plugin-proposal-export-namespace-from-7.12.13.tgz#393be47a4acd03fa2af6e3cde9b06e33de1b446d" - integrity sha512-INAgtFo4OnLN3Y/j0VwAgw3HDXcDtX+C/erMvWzuV9v71r7urb6iyMXu7eM9IgLr1ElLlOkaHjJ0SbCmdOQ3Iw== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - "@babel/plugin-syntax-export-namespace-from" "^7.8.3" - -"@babel/plugin-proposal-json-strings@^7.13.8": - version "7.13.8" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.13.8.tgz#bf1fb362547075afda3634ed31571c5901afef7b" - integrity sha512-w4zOPKUFPX1mgvTmL/fcEqy34hrQ1CRcGxdphBc6snDnnqJ47EZDIyop6IwXzAC8G916hsIuXB2ZMBCExC5k7Q== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/plugin-syntax-json-strings" "^7.8.3" - -"@babel/plugin-proposal-logical-assignment-operators@^7.13.8": - version "7.13.8" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-logical-assignment-operators/-/plugin-proposal-logical-assignment-operators-7.13.8.tgz#93fa78d63857c40ce3c8c3315220fd00bfbb4e1a" - integrity sha512-aul6znYB4N4HGweImqKn59Su9RS8lbUIqxtXTOcAGtNIDczoEFv+l1EhmX8rUBp3G1jMjKJm8m0jXVp63ZpS4A== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" - -"@babel/plugin-proposal-nullish-coalescing-operator@^7.13.8": - version "7.13.8" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.13.8.tgz#3730a31dafd3c10d8ccd10648ed80a2ac5472ef3" - integrity sha512-iePlDPBn//UhxExyS9KyeYU7RM9WScAG+D3Hhno0PLJebAEpDZMocbDe64eqynhNAnwz/vZoL/q/QB2T1OH39A== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" - -"@babel/plugin-proposal-numeric-separator@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-numeric-separator/-/plugin-proposal-numeric-separator-7.12.13.tgz#bd9da3188e787b5120b4f9d465a8261ce67ed1db" - integrity sha512-O1jFia9R8BUCl3ZGB7eitaAPu62TXJRHn7rh+ojNERCFyqRwJMTmhz+tJ+k0CwI6CLjX/ee4qW74FSqlq9I35w== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - "@babel/plugin-syntax-numeric-separator" "^7.10.4" - -"@babel/plugin-proposal-object-rest-spread@^7.13.8": - version "7.13.8" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.13.8.tgz#5d210a4d727d6ce3b18f9de82cc99a3964eed60a" - integrity sha512-DhB2EuB1Ih7S3/IRX5AFVgZ16k3EzfRbq97CxAVI1KSYcW+lexV8VZb7G7L8zuPVSdQMRn0kiBpf/Yzu9ZKH0g== - dependencies: - "@babel/compat-data" "^7.13.8" - "@babel/helper-compilation-targets" "^7.13.8" - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/plugin-syntax-object-rest-spread" "^7.8.3" - "@babel/plugin-transform-parameters" "^7.13.0" - -"@babel/plugin-proposal-optional-catch-binding@^7.13.8": - version "7.13.8" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.13.8.tgz#3ad6bd5901506ea996fc31bdcf3ccfa2bed71107" - integrity sha512-0wS/4DUF1CuTmGo+NiaHfHcVSeSLj5S3e6RivPTg/2k3wOv3jO35tZ6/ZWsQhQMvdgI7CwphjQa/ccarLymHVA== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" - -"@babel/plugin-proposal-optional-chaining@^7.13.12": - version "7.13.12" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.13.12.tgz#ba9feb601d422e0adea6760c2bd6bbb7bfec4866" - integrity sha512-fcEdKOkIB7Tf4IxrgEVeFC4zeJSTr78no9wTdBuZZbqF64kzllU0ybo2zrzm7gUQfxGhBgq4E39oRs8Zx/RMYQ== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/helper-skip-transparent-expression-wrappers" "^7.12.1" - "@babel/plugin-syntax-optional-chaining" "^7.8.3" - -"@babel/plugin-proposal-private-methods@^7.13.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-private-methods/-/plugin-proposal-private-methods-7.13.0.tgz#04bd4c6d40f6e6bbfa2f57e2d8094bad900ef787" - integrity sha512-MXyyKQd9inhx1kDYPkFRVOBXQ20ES8Pto3T7UZ92xj2mY0EVD8oAVzeyYuVfy/mxAdTSIayOvg+aVzcHV2bn6Q== - dependencies: - "@babel/helper-create-class-features-plugin" "^7.13.0" - "@babel/helper-plugin-utils" "^7.13.0" - -"@babel/plugin-proposal-unicode-property-regex@^7.12.13", "@babel/plugin-proposal-unicode-property-regex@^7.4.4": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.12.13.tgz#bebde51339be829c17aaaaced18641deb62b39ba" - integrity sha512-XyJmZidNfofEkqFV5VC/bLabGmO5QzenPO/YOfGuEbgU+2sSwMmio3YLb4WtBgcmmdwZHyVyv8on77IUjQ5Gvg== - dependencies: - "@babel/helper-create-regexp-features-plugin" "^7.12.13" - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-syntax-async-generators@^7.8.4": - version "7.8.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz#a983fb1aeb2ec3f6ed042a210f640e90e786fe0d" - integrity sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-class-properties@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz#b5c987274c4a3a82b89714796931a6b53544ae10" - integrity sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-syntax-dynamic-import@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.8.3.tgz#62bf98b2da3cd21d626154fc96ee5b3cb68eacb3" - integrity sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-export-namespace-from@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-export-namespace-from/-/plugin-syntax-export-namespace-from-7.8.3.tgz#028964a9ba80dbc094c915c487ad7c4e7a66465a" - integrity sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q== - dependencies: - "@babel/helper-plugin-utils" "^7.8.3" - -"@babel/plugin-syntax-json-strings@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz#01ca21b668cd8218c9e640cb6dd88c5412b2c96a" - integrity sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-logical-assignment-operators@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz#ca91ef46303530448b906652bac2e9fe9941f699" - integrity sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig== - dependencies: - "@babel/helper-plugin-utils" "^7.10.4" - -"@babel/plugin-syntax-nullish-coalescing-operator@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz#167ed70368886081f74b5c36c65a88c03b66d1a9" - integrity sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-numeric-separator@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz#b9b070b3e33570cd9fd07ba7fa91c0dd37b9af97" - integrity sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug== - dependencies: - "@babel/helper-plugin-utils" "^7.10.4" - -"@babel/plugin-syntax-object-rest-spread@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz#60e225edcbd98a640332a2e72dd3e66f1af55871" - integrity sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-optional-catch-binding@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz#6111a265bcfb020eb9efd0fdfd7d26402b9ed6c1" - integrity sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-optional-chaining@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz#4f69c2ab95167e0180cd5336613f8c5788f7d48a" - integrity sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-top-level-await@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.12.13.tgz#c5f0fa6e249f5b739727f923540cf7a806130178" - integrity sha512-A81F9pDwyS7yM//KwbCSDqy3Uj4NMIurtplxphWxoYtNPov7cJsDkAFNNyVlIZ3jwGycVsurZ+LtOA8gZ376iQ== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-arrow-functions@^7.13.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.13.0.tgz#10a59bebad52d637a027afa692e8d5ceff5e3dae" - integrity sha512-96lgJagobeVmazXFaDrbmCLQxBysKu7U6Do3mLsx27gf5Dk85ezysrs2BZUpXD703U/Su1xTBDxxar2oa4jAGg== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - -"@babel/plugin-transform-async-to-generator@^7.13.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.13.0.tgz#8e112bf6771b82bf1e974e5e26806c5c99aa516f" - integrity sha512-3j6E004Dx0K3eGmhxVJxwwI89CTJrce7lg3UrtFuDAVQ/2+SJ/h/aSFOeE6/n0WB1GsOffsJp6MnPQNQ8nmwhg== - dependencies: - "@babel/helper-module-imports" "^7.12.13" - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/helper-remap-async-to-generator" "^7.13.0" - -"@babel/plugin-transform-block-scoped-functions@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.12.13.tgz#a9bf1836f2a39b4eb6cf09967739de29ea4bf4c4" - integrity sha512-zNyFqbc3kI/fVpqwfqkg6RvBgFpC4J18aKKMmv7KdQ/1GgREapSJAykLMVNwfRGO3BtHj3YQZl8kxCXPcVMVeg== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-block-scoping@^7.12.13": - version "7.13.16" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.13.16.tgz#a9c0f10794855c63b1d629914c7dcfeddd185892" - integrity sha512-ad3PHUxGnfWF4Efd3qFuznEtZKoBp0spS+DgqzVzRPV7urEBvPLue3y2j80w4Jf2YLzZHj8TOv/Lmvdmh3b2xg== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - -"@babel/plugin-transform-classes@^7.13.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.13.0.tgz#0265155075c42918bf4d3a4053134176ad9b533b" - integrity sha512-9BtHCPUARyVH1oXGcSJD3YpsqRLROJx5ZNP6tN5vnk17N0SVf9WCtf8Nuh1CFmgByKKAIMstitKduoCmsaDK5g== - dependencies: - "@babel/helper-annotate-as-pure" "^7.12.13" - "@babel/helper-function-name" "^7.12.13" - "@babel/helper-optimise-call-expression" "^7.12.13" - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/helper-replace-supers" "^7.13.0" - "@babel/helper-split-export-declaration" "^7.12.13" - globals "^11.1.0" - -"@babel/plugin-transform-computed-properties@^7.13.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.13.0.tgz#845c6e8b9bb55376b1fa0b92ef0bdc8ea06644ed" - integrity sha512-RRqTYTeZkZAz8WbieLTvKUEUxZlUTdmL5KGMyZj7FnMfLNKV4+r5549aORG/mgojRmFlQMJDUupwAMiF2Q7OUg== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - -"@babel/plugin-transform-destructuring@^7.13.0": - version "7.13.17" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.13.17.tgz#678d96576638c19d5b36b332504d3fd6e06dea27" - integrity sha512-UAUqiLv+uRLO+xuBKKMEpC+t7YRNVRqBsWWq1yKXbBZBje/t3IXCiSinZhjn/DC3qzBfICeYd2EFGEbHsh5RLA== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - -"@babel/plugin-transform-dotall-regex@^7.12.13", "@babel/plugin-transform-dotall-regex@^7.4.4": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.12.13.tgz#3f1601cc29905bfcb67f53910f197aeafebb25ad" - integrity sha512-foDrozE65ZFdUC2OfgeOCrEPTxdB3yjqxpXh8CH+ipd9CHd4s/iq81kcUpyH8ACGNEPdFqbtzfgzbT/ZGlbDeQ== - dependencies: - "@babel/helper-create-regexp-features-plugin" "^7.12.13" - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-duplicate-keys@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.12.13.tgz#6f06b87a8b803fd928e54b81c258f0a0033904de" - integrity sha512-NfADJiiHdhLBW3pulJlJI2NB0t4cci4WTZ8FtdIuNc2+8pslXdPtRRAEWqUY+m9kNOk2eRYbTAOipAxlrOcwwQ== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-exponentiation-operator@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.12.13.tgz#4d52390b9a273e651e4aba6aee49ef40e80cd0a1" - integrity sha512-fbUelkM1apvqez/yYx1/oICVnGo2KM5s63mhGylrmXUxK/IAXSIf87QIxVfZldWf4QsOafY6vV3bX8aMHSvNrA== - dependencies: - "@babel/helper-builder-binary-assignment-operator-visitor" "^7.12.13" - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-for-of@^7.13.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.13.0.tgz#c799f881a8091ac26b54867a845c3e97d2696062" - integrity sha512-IHKT00mwUVYE0zzbkDgNRP6SRzvfGCYsOxIRz8KsiaaHCcT9BWIkO+H9QRJseHBLOGBZkHUdHiqj6r0POsdytg== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - -"@babel/plugin-transform-function-name@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.12.13.tgz#bb024452f9aaed861d374c8e7a24252ce3a50051" - integrity sha512-6K7gZycG0cmIwwF7uMK/ZqeCikCGVBdyP2J5SKNCXO5EOHcqi+z7Jwf8AmyDNcBgxET8DrEtCt/mPKPyAzXyqQ== - dependencies: - "@babel/helper-function-name" "^7.12.13" - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-literals@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-literals/-/plugin-transform-literals-7.12.13.tgz#2ca45bafe4a820197cf315794a4d26560fe4bdb9" - integrity sha512-FW+WPjSR7hiUxMcKqyNjP05tQ2kmBCdpEpZHY1ARm96tGQCCBvXKnpjILtDplUnJ/eHZ0lALLM+d2lMFSpYJrQ== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-member-expression-literals@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.12.13.tgz#5ffa66cd59b9e191314c9f1f803b938e8c081e40" - integrity sha512-kxLkOsg8yir4YeEPHLuO2tXP9R/gTjpuTOjshqSpELUN3ZAg2jfDnKUvzzJxObun38sw3wm4Uu69sX/zA7iRvg== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-modules-amd@^7.13.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.13.0.tgz#19f511d60e3d8753cc5a6d4e775d3a5184866cc3" - integrity sha512-EKy/E2NHhY/6Vw5d1k3rgoobftcNUmp9fGjb9XZwQLtTctsRBOTRO7RHHxfIky1ogMN5BxN7p9uMA3SzPfotMQ== - dependencies: - "@babel/helper-module-transforms" "^7.13.0" - "@babel/helper-plugin-utils" "^7.13.0" - babel-plugin-dynamic-import-node "^2.3.3" - -"@babel/plugin-transform-modules-commonjs@^7.13.8": - version "7.13.8" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.13.8.tgz#7b01ad7c2dcf2275b06fa1781e00d13d420b3e1b" - integrity sha512-9QiOx4MEGglfYZ4XOnU79OHr6vIWUakIj9b4mioN8eQIoEh+pf5p/zEB36JpDFWA12nNMiRf7bfoRvl9Rn79Bw== - dependencies: - "@babel/helper-module-transforms" "^7.13.0" - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/helper-simple-access" "^7.12.13" - babel-plugin-dynamic-import-node "^2.3.3" - -"@babel/plugin-transform-modules-systemjs@^7.13.8": - version "7.13.8" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.13.8.tgz#6d066ee2bff3c7b3d60bf28dec169ad993831ae3" - integrity sha512-hwqctPYjhM6cWvVIlOIe27jCIBgHCsdH2xCJVAYQm7V5yTMoilbVMi9f6wKg0rpQAOn6ZG4AOyvCqFF/hUh6+A== - dependencies: - "@babel/helper-hoist-variables" "^7.13.0" - "@babel/helper-module-transforms" "^7.13.0" - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/helper-validator-identifier" "^7.12.11" - babel-plugin-dynamic-import-node "^2.3.3" - -"@babel/plugin-transform-modules-umd@^7.13.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.13.0.tgz#8a3d96a97d199705b9fd021580082af81c06e70b" - integrity sha512-D/ILzAh6uyvkWjKKyFE/W0FzWwasv6vPTSqPcjxFqn6QpX3u8DjRVliq4F2BamO2Wee/om06Vyy+vPkNrd4wxw== - dependencies: - "@babel/helper-module-transforms" "^7.13.0" - "@babel/helper-plugin-utils" "^7.13.0" - -"@babel/plugin-transform-named-capturing-groups-regex@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.12.13.tgz#2213725a5f5bbbe364b50c3ba5998c9599c5c9d9" - integrity sha512-Xsm8P2hr5hAxyYblrfACXpQKdQbx4m2df9/ZZSQ8MAhsadw06+jW7s9zsSw6he+mJZXRlVMyEnVktJo4zjk1WA== - dependencies: - "@babel/helper-create-regexp-features-plugin" "^7.12.13" - -"@babel/plugin-transform-new-target@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.12.13.tgz#e22d8c3af24b150dd528cbd6e685e799bf1c351c" - integrity sha512-/KY2hbLxrG5GTQ9zzZSc3xWiOy379pIETEhbtzwZcw9rvuaVV4Fqy7BYGYOWZnaoXIQYbbJ0ziXLa/sKcGCYEQ== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-object-super@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.12.13.tgz#b4416a2d63b8f7be314f3d349bd55a9c1b5171f7" - integrity sha512-JzYIcj3XtYspZDV8j9ulnoMPZZnF/Cj0LUxPOjR89BdBVx+zYJI9MdMIlUZjbXDX+6YVeS6I3e8op+qQ3BYBoQ== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - "@babel/helper-replace-supers" "^7.12.13" - -"@babel/plugin-transform-parameters@^7.13.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.13.0.tgz#8fa7603e3097f9c0b7ca1a4821bc2fb52e9e5007" - integrity sha512-Jt8k/h/mIwE2JFEOb3lURoY5C85ETcYPnbuAJ96zRBzh1XHtQZfs62ChZ6EP22QlC8c7Xqr9q+e1SU5qttwwjw== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - -"@babel/plugin-transform-property-literals@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.12.13.tgz#4e6a9e37864d8f1b3bc0e2dce7bf8857db8b1a81" - integrity sha512-nqVigwVan+lR+g8Fj8Exl0UQX2kymtjcWfMOYM1vTYEKujeyv2SkMgazf2qNcK7l4SDiKyTA/nHCPqL4e2zo1A== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-regenerator@^7.13.15": - version "7.13.15" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.13.15.tgz#e5eb28945bf8b6563e7f818945f966a8d2997f39" - integrity sha512-Bk9cOLSz8DiurcMETZ8E2YtIVJbFCPGW28DJWUakmyVWtQSm6Wsf0p4B4BfEr/eL2Nkhe/CICiUiMOCi1TPhuQ== - dependencies: - regenerator-transform "^0.14.2" - -"@babel/plugin-transform-reserved-words@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.12.13.tgz#7d9988d4f06e0fe697ea1d9803188aa18b472695" - integrity sha512-xhUPzDXxZN1QfiOy/I5tyye+TRz6lA7z6xaT4CLOjPRMVg1ldRf0LHw0TDBpYL4vG78556WuHdyO9oi5UmzZBg== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-shorthand-properties@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.12.13.tgz#db755732b70c539d504c6390d9ce90fe64aff7ad" - integrity sha512-xpL49pqPnLtf0tVluuqvzWIgLEhuPpZzvs2yabUHSKRNlN7ScYU7aMlmavOeyXJZKgZKQRBlh8rHbKiJDraTSw== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-spread@^7.13.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-spread/-/plugin-transform-spread-7.13.0.tgz#84887710e273c1815ace7ae459f6f42a5d31d5fd" - integrity sha512-V6vkiXijjzYeFmQTr3dBxPtZYLPcUfY34DebOU27jIl2M/Y8Egm52Hw82CSjjPqd54GTlJs5x+CR7HeNr24ckg== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/helper-skip-transparent-expression-wrappers" "^7.12.1" - -"@babel/plugin-transform-sticky-regex@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.12.13.tgz#760ffd936face73f860ae646fb86ee82f3d06d1f" - integrity sha512-Jc3JSaaWT8+fr7GRvQP02fKDsYk4K/lYwWq38r/UGfaxo89ajud321NH28KRQ7xy1Ybc0VUE5Pz8psjNNDUglg== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-template-literals@^7.13.0": - version "7.13.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.13.0.tgz#a36049127977ad94438dee7443598d1cefdf409d" - integrity sha512-d67umW6nlfmr1iehCcBv69eSUSySk1EsIS8aTDX4Xo9qajAh6mYtcl4kJrBkGXuxZPEgVr7RVfAvNW6YQkd4Mw== - dependencies: - "@babel/helper-plugin-utils" "^7.13.0" - -"@babel/plugin-transform-typeof-symbol@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.12.13.tgz#785dd67a1f2ea579d9c2be722de8c84cb85f5a7f" - integrity sha512-eKv/LmUJpMnu4npgfvs3LiHhJua5fo/CysENxa45YCQXZwKnGCQKAg87bvoqSW1fFT+HA32l03Qxsm8ouTY3ZQ== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-unicode-escapes@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.12.13.tgz#840ced3b816d3b5127dd1d12dcedc5dead1a5e74" - integrity sha512-0bHEkdwJ/sN/ikBHfSmOXPypN/beiGqjo+o4/5K+vxEFNPRPdImhviPakMKG4x96l85emoa0Z6cDflsdBusZbw== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-transform-unicode-regex@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.12.13.tgz#b52521685804e155b1202e83fc188d34bb70f5ac" - integrity sha512-mDRzSNY7/zopwisPZ5kM9XKCfhchqIYwAKRERtEnhYscZB79VRekuRSoYbN0+KVe3y8+q1h6A4svXtP7N+UoCA== - dependencies: - "@babel/helper-create-regexp-features-plugin" "^7.12.13" - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/preset-env@^7.13.15": - version "7.13.15" - resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.13.15.tgz#c8a6eb584f96ecba183d3d414a83553a599f478f" - integrity sha512-D4JAPMXcxk69PKe81jRJ21/fP/uYdcTZ3hJDF5QX2HSI9bBxxYw/dumdR6dGumhjxlprHPE4XWoPaqzZUVy2MA== - dependencies: - "@babel/compat-data" "^7.13.15" - "@babel/helper-compilation-targets" "^7.13.13" - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/helper-validator-option" "^7.12.17" - "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining" "^7.13.12" - "@babel/plugin-proposal-async-generator-functions" "^7.13.15" - "@babel/plugin-proposal-class-properties" "^7.13.0" - "@babel/plugin-proposal-dynamic-import" "^7.13.8" - "@babel/plugin-proposal-export-namespace-from" "^7.12.13" - "@babel/plugin-proposal-json-strings" "^7.13.8" - "@babel/plugin-proposal-logical-assignment-operators" "^7.13.8" - "@babel/plugin-proposal-nullish-coalescing-operator" "^7.13.8" - "@babel/plugin-proposal-numeric-separator" "^7.12.13" - "@babel/plugin-proposal-object-rest-spread" "^7.13.8" - "@babel/plugin-proposal-optional-catch-binding" "^7.13.8" - "@babel/plugin-proposal-optional-chaining" "^7.13.12" - "@babel/plugin-proposal-private-methods" "^7.13.0" - "@babel/plugin-proposal-unicode-property-regex" "^7.12.13" - "@babel/plugin-syntax-async-generators" "^7.8.4" - "@babel/plugin-syntax-class-properties" "^7.12.13" - "@babel/plugin-syntax-dynamic-import" "^7.8.3" - "@babel/plugin-syntax-export-namespace-from" "^7.8.3" - "@babel/plugin-syntax-json-strings" "^7.8.3" - "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" - "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" - "@babel/plugin-syntax-numeric-separator" "^7.10.4" - "@babel/plugin-syntax-object-rest-spread" "^7.8.3" - "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" - "@babel/plugin-syntax-optional-chaining" "^7.8.3" - "@babel/plugin-syntax-top-level-await" "^7.12.13" - "@babel/plugin-transform-arrow-functions" "^7.13.0" - "@babel/plugin-transform-async-to-generator" "^7.13.0" - "@babel/plugin-transform-block-scoped-functions" "^7.12.13" - "@babel/plugin-transform-block-scoping" "^7.12.13" - "@babel/plugin-transform-classes" "^7.13.0" - "@babel/plugin-transform-computed-properties" "^7.13.0" - "@babel/plugin-transform-destructuring" "^7.13.0" - "@babel/plugin-transform-dotall-regex" "^7.12.13" - "@babel/plugin-transform-duplicate-keys" "^7.12.13" - "@babel/plugin-transform-exponentiation-operator" "^7.12.13" - "@babel/plugin-transform-for-of" "^7.13.0" - "@babel/plugin-transform-function-name" "^7.12.13" - "@babel/plugin-transform-literals" "^7.12.13" - "@babel/plugin-transform-member-expression-literals" "^7.12.13" - "@babel/plugin-transform-modules-amd" "^7.13.0" - "@babel/plugin-transform-modules-commonjs" "^7.13.8" - "@babel/plugin-transform-modules-systemjs" "^7.13.8" - "@babel/plugin-transform-modules-umd" "^7.13.0" - "@babel/plugin-transform-named-capturing-groups-regex" "^7.12.13" - "@babel/plugin-transform-new-target" "^7.12.13" - "@babel/plugin-transform-object-super" "^7.12.13" - "@babel/plugin-transform-parameters" "^7.13.0" - "@babel/plugin-transform-property-literals" "^7.12.13" - "@babel/plugin-transform-regenerator" "^7.13.15" - "@babel/plugin-transform-reserved-words" "^7.12.13" - "@babel/plugin-transform-shorthand-properties" "^7.12.13" - "@babel/plugin-transform-spread" "^7.13.0" - "@babel/plugin-transform-sticky-regex" "^7.12.13" - "@babel/plugin-transform-template-literals" "^7.13.0" - "@babel/plugin-transform-typeof-symbol" "^7.12.13" - "@babel/plugin-transform-unicode-escapes" "^7.12.13" - "@babel/plugin-transform-unicode-regex" "^7.12.13" - "@babel/preset-modules" "^0.1.4" - "@babel/types" "^7.13.14" - babel-plugin-polyfill-corejs2 "^0.2.0" - babel-plugin-polyfill-corejs3 "^0.2.0" - babel-plugin-polyfill-regenerator "^0.2.0" - core-js-compat "^3.9.0" - semver "^6.3.0" - -"@babel/preset-modules@^0.1.4": - version "0.1.4" - resolved "https://registry.yarnpkg.com/@babel/preset-modules/-/preset-modules-0.1.4.tgz#362f2b68c662842970fdb5e254ffc8fc1c2e415e" - integrity sha512-J36NhwnfdzpmH41M1DrnkkgAqhZaqr/NBdPfQ677mLzlaXo+oDiv1deyCDtgAhz8p328otdob0Du7+xgHGZbKg== - dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-proposal-unicode-property-regex" "^7.4.4" - "@babel/plugin-transform-dotall-regex" "^7.4.4" - "@babel/types" "^7.4.4" - esutils "^2.0.2" - -"@babel/register@^7.13.16": - version "7.13.16" - resolved "https://registry.yarnpkg.com/@babel/register/-/register-7.13.16.tgz#ae3ab0b55c8ec28763877383c454f01521d9a53d" - integrity sha512-dh2t11ysujTwByQjXNgJ48QZ2zcXKQVdV8s0TbeMI0flmtGWCdTwK9tJiACHXPLmncm5+ktNn/diojA45JE4jg== - dependencies: - clone-deep "^4.0.1" - find-cache-dir "^2.0.0" - make-dir "^2.1.0" - pirates "^4.0.0" - source-map-support "^0.5.16" - -"@babel/runtime@^7.8.4": - version "7.13.17" - resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.13.17.tgz#8966d1fc9593bf848602f0662d6b4d0069e3a7ec" - integrity sha512-NCdgJEelPTSh+FEFylhnP1ylq848l1z9t9N0j1Lfbcw0+KXGjsTvUmkxy+voLLXB5SOKMbLLx4jxYliGrYQseA== - dependencies: - regenerator-runtime "^0.13.4" - -"@babel/template@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.12.13.tgz#530265be8a2589dbb37523844c5bcb55947fb327" - integrity sha512-/7xxiGA57xMo/P2GVvdEumr8ONhFOhfgq2ihK3h1e6THqzTAkHbkXgB0xI9yeTfIUoH3+oAeHhqm/I43OTbbjA== - dependencies: - "@babel/code-frame" "^7.12.13" - "@babel/parser" "^7.12.13" - "@babel/types" "^7.12.13" - -"@babel/traverse@^7.13.0", "@babel/traverse@^7.13.13", "@babel/traverse@^7.13.15", "@babel/traverse@^7.13.17", "@babel/traverse@^7.7.0": - version "7.13.17" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.13.17.tgz#c85415e0c7d50ac053d758baec98b28b2ecfeea3" - integrity sha512-BMnZn0R+X6ayqm3C3To7o1j7Q020gWdqdyP50KEoVqaCO2c/Im7sYZSmVgvefp8TTMQ+9CtwuBp0Z1CZ8V3Pvg== - dependencies: - "@babel/code-frame" "^7.12.13" - "@babel/generator" "^7.13.16" - "@babel/helper-function-name" "^7.12.13" - "@babel/helper-split-export-declaration" "^7.12.13" - "@babel/parser" "^7.13.16" - "@babel/types" "^7.13.17" - debug "^4.1.0" - globals "^11.1.0" - -"@babel/types@^7.12.1", "@babel/types@^7.12.13", "@babel/types@^7.13.0", "@babel/types@^7.13.12", "@babel/types@^7.13.14", "@babel/types@^7.13.16", "@babel/types@^7.13.17", "@babel/types@^7.4.4", "@babel/types@^7.7.0": - version "7.13.17" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.13.17.tgz#48010a115c9fba7588b4437dd68c9469012b38b4" - integrity sha512-RawydLgxbOPDlTLJNtoIypwdmAy//uQIzlKt2+iBiJaRlVuI6QLUxVAyWGNfOzp8Yu4L4lLIacoCyTNtpb4wiA== - dependencies: - "@babel/helper-validator-identifier" "^7.12.11" - to-fast-properties "^2.0.0" - -"@sinonjs/commons@^1", "@sinonjs/commons@^1.3.0", "@sinonjs/commons@^1.4.0", "@sinonjs/commons@^1.7.0": - version "1.8.3" - resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-1.8.3.tgz#3802ddd21a50a949b6721ddd72da36e67e7f1b2d" - integrity sha512-xkNcLAn/wZaX14RPlwizcKicDk9G3F8m2nU3L7Ukm5zBgTwiT0wsoFAHx9Jq56fJA1z/7uKGtCRu16sOUCLIHQ== - dependencies: - type-detect "4.0.8" - -"@sinonjs/formatio@^3.2.1": - version "3.2.2" - resolved "https://registry.yarnpkg.com/@sinonjs/formatio/-/formatio-3.2.2.tgz#771c60dfa75ea7f2d68e3b94c7e888a78781372c" - integrity sha512-B8SEsgd8gArBLMD6zpRw3juQ2FVSsmdd7qlevyDqzS9WTCtvF55/gAL+h6gue8ZvPYcdiPdvueM/qm//9XzyTQ== - dependencies: - "@sinonjs/commons" "^1" - "@sinonjs/samsam" "^3.1.0" - -"@sinonjs/samsam@^3.1.0", "@sinonjs/samsam@^3.3.3": - version "3.3.3" - resolved "https://registry.yarnpkg.com/@sinonjs/samsam/-/samsam-3.3.3.tgz#46682efd9967b259b81136b9f120fd54585feb4a" - integrity sha512-bKCMKZvWIjYD0BLGnNrxVuw4dkWCYsLqFOUWw8VgKF/+5Y+mE7LfHWPIYoDXowH+3a9LsWDMo0uAP8YDosPvHQ== - dependencies: - "@sinonjs/commons" "^1.3.0" - array-from "^2.1.1" - lodash "^4.17.15" - -"@sinonjs/text-encoding@^0.7.1": - version "0.7.1" - resolved "https://registry.yarnpkg.com/@sinonjs/text-encoding/-/text-encoding-0.7.1.tgz#8da5c6530915653f3a1f38fd5f101d8c3f8079c5" - integrity sha512-+iTbntw2IZPb/anVDbypzfQa+ay64MW0Zo8aJ8gZPWMMK6/OubMVb6lUPMagqjOPnmtauXnFCACVl3O7ogjeqQ== - -abbrev@1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8" - integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q== - -abbrev@1.0.x: - version "1.0.9" - resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.0.9.tgz#91b4792588a7738c25f35dd6f63752a2f8776135" - integrity sha1-kbR5JYinc4wl813W9jdSovh3YTU= - -acorn-jsx@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-3.0.1.tgz#afdf9488fb1ecefc8348f6fb22f464e32a58b36b" - integrity sha1-r9+UiPsezvyDSPb7IvRk4ypYs2s= - dependencies: - acorn "^3.0.4" - -acorn-jsx@^5.2.0: - version "5.3.1" - resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.3.1.tgz#fc8661e11b7ac1539c47dbfea2e72b3af34d267b" - integrity sha512-K0Ptm/47OKfQRpNQ2J/oIN/3QYiK6FwW+eJbILhsdxh2WTLdl+30o8aGdTbm5JbffpFFAg/g+zi1E+jvJha5ng== - -acorn@^3.0.4: - version "3.3.0" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-3.3.0.tgz#45e37fb39e8da3f25baee3ff5369e2bb5f22017a" - integrity sha1-ReN/s56No/JbruP/U2niu18iAXo= - -acorn@^5.5.0: - version "5.7.4" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.4.tgz#3e8d8a9947d0599a1796d10225d7432f4a4acf5e" - integrity sha512-1D++VG7BhrtvQpNbBzovKNc1FLGGEE/oGe7b9xJm/RFHMBeUaUGpluV9RLjZa47YFdPcDAenEYuq9pQPcMdLJg== - -acorn@^7.1.1: - version "7.4.1" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.4.1.tgz#feaed255973d2e77555b83dbc08851a6c63520fa" - integrity sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A== - -ajv-keywords@^2.1.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-2.1.1.tgz#617997fc5f60576894c435f940d819e135b80762" - integrity sha1-YXmX/F9gV2iUxDX5QNgZ4TW4B2I= - -ajv@^5.2.3, ajv@^5.3.0: - version "5.5.2" - resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.2.tgz#73b5eeca3fab653e3d3f9422b341ad42205dc965" - integrity sha1-c7Xuyj+rZT49P5Qis0GtQiBdyWU= - dependencies: - co "^4.6.0" - fast-deep-equal "^1.0.0" - fast-json-stable-stringify "^2.0.0" - json-schema-traverse "^0.3.0" - -ajv@^6.10.0, ajv@^6.10.2, ajv@^6.12.3: - version "6.12.6" - resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" - integrity sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g== - dependencies: - fast-deep-equal "^3.1.1" - fast-json-stable-stringify "^2.0.0" - json-schema-traverse "^0.4.1" - uri-js "^4.2.2" - -amdefine@>=0.0.4: - version "1.0.1" - resolved "https://registry.yarnpkg.com/amdefine/-/amdefine-1.0.1.tgz#4a5282ac164729e93619bcfd3ad151f817ce91f5" - integrity sha1-SlKCrBZHKek2Gbz9OtFR+BfOkfU= - -ansi-colors@^1.0.1: - version "1.1.0" - resolved "https://registry.yarnpkg.com/ansi-colors/-/ansi-colors-1.1.0.tgz#6374b4dd5d4718ff3ce27a671a3b1cad077132a9" - integrity sha512-SFKX67auSNoVR38N3L+nvsPjOE0bybKTYbkf5tRvushrAPQ9V75huw0ZxBkKVeRU9kqH3d6HA4xTckbwZ4ixmA== - dependencies: - ansi-wrap "^0.1.0" - -ansi-cyan@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/ansi-cyan/-/ansi-cyan-0.1.1.tgz#538ae528af8982f28ae30d86f2f17456d2609873" - integrity sha1-U4rlKK+JgvKK4w2G8vF0VtJgmHM= - dependencies: - ansi-wrap "0.1.0" - -ansi-escapes@^3.0.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.2.0.tgz#8780b98ff9dbf5638152d1f1fe5c1d7b4442976b" - integrity sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ== - -ansi-escapes@^4.2.1: - version "4.3.2" - resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-4.3.2.tgz#6b2291d1db7d98b6521d5f1efa42d0f3a9feb65e" - integrity sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ== - dependencies: - type-fest "^0.21.3" - -ansi-gray@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/ansi-gray/-/ansi-gray-0.1.1.tgz#2962cf54ec9792c48510a3deb524436861ef7251" - integrity sha1-KWLPVOyXksSFEKPetSRDaGHvclE= - dependencies: - ansi-wrap "0.1.0" - -ansi-red@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/ansi-red/-/ansi-red-0.1.1.tgz#8c638f9d1080800a353c9c28c8a81ca4705d946c" - integrity sha1-jGOPnRCAgAo1PJwoyKgcpHBdlGw= - dependencies: - ansi-wrap "0.1.0" - -ansi-regex@^2.0.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" - integrity sha1-w7M6te42DYbg5ijwRorn7yfWVN8= - -ansi-regex@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.0.tgz#ed0317c322064f79466c02966bddb605ab37d998" - integrity sha1-7QMXwyIGT3lGbAKWa922Bas32Zg= - -ansi-regex@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.1.0.tgz#8b9f8f08cf1acb843756a839ca8c7e3168c51997" - integrity sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg== - -ansi-regex@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.0.tgz#388539f55179bf39339c81af30a654d69f87cb75" - integrity sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg== - -ansi-styles@^2.2.1: - version "2.2.1" - resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" - integrity sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4= - -ansi-styles@^3.2.0, ansi-styles@^3.2.1: - version "3.2.1" - resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" - integrity sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA== - dependencies: - color-convert "^1.9.0" - -ansi-styles@^4.1.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" - integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== - dependencies: - color-convert "^2.0.1" - -ansi-wrap@0.1.0, ansi-wrap@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/ansi-wrap/-/ansi-wrap-0.1.0.tgz#a82250ddb0015e9a27ca82e82ea603bbfa45efaf" - integrity sha1-qCJQ3bABXponyoLoLqYDu/pF768= - -anymatch@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-2.0.0.tgz#bcb24b4f37934d9aa7ac17b4adaf89e7c76ef2eb" - integrity sha512-5teOsQWABXHHBFP9y3skS5P3d/WfWXpv3FUpy+LorMrNYaT9pI4oLMQX7jzQ2KklNpGpWHzdCXTDT2Y3XGlZBw== - dependencies: - micromatch "^3.1.4" - normalize-path "^2.1.1" - -append-buffer@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/append-buffer/-/append-buffer-1.0.2.tgz#d8220cf466081525efea50614f3de6514dfa58f1" - integrity sha1-2CIM9GYIFSXv6lBhTz3mUU36WPE= - dependencies: - buffer-equal "^1.0.0" - -archy@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/archy/-/archy-1.0.0.tgz#f9c8c13757cc1dd7bc379ac77b2c62a5c2868c40" - integrity sha1-+cjBN1fMHde8N5rHeyxipcKGjEA= - -argparse@^1.0.7: - version "1.0.10" - resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.10.tgz#bcd6791ea5ae09725e17e5ad988134cd40b3d911" - integrity sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg== - dependencies: - sprintf-js "~1.0.2" - -arr-diff@^1.0.1: - version "1.1.0" - resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-1.1.0.tgz#687c32758163588fef7de7b36fabe495eb1a399a" - integrity sha1-aHwydYFjWI/vfeezb6vklesaOZo= - dependencies: - arr-flatten "^1.0.1" - array-slice "^0.2.3" - -arr-diff@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-4.0.0.tgz#d6461074febfec71e7e15235761a329a5dc7c520" - integrity sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA= - -arr-filter@^1.1.1: - version "1.1.2" - resolved "https://registry.yarnpkg.com/arr-filter/-/arr-filter-1.1.2.tgz#43fdddd091e8ef11aa4c45d9cdc18e2dff1711ee" - integrity sha1-Q/3d0JHo7xGqTEXZzcGOLf8XEe4= - dependencies: - make-iterator "^1.0.0" - -arr-flatten@^1.0.1, arr-flatten@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/arr-flatten/-/arr-flatten-1.1.0.tgz#36048bbff4e7b47e136644316c99669ea5ae91f1" - integrity sha512-L3hKV5R/p5o81R7O02IGnwpDmkp6E982XhtbuwSe3O4qOtMMMtodicASA1Cny2U+aCXcNpml+m4dPsvsJ3jatg== - -arr-map@^2.0.0, arr-map@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/arr-map/-/arr-map-2.0.2.tgz#3a77345ffc1cf35e2a91825601f9e58f2e24cac4" - integrity sha1-Onc0X/wc814qkYJWAfnljy4kysQ= - dependencies: - make-iterator "^1.0.0" - -arr-union@^2.0.1: - version "2.1.0" - resolved "https://registry.yarnpkg.com/arr-union/-/arr-union-2.1.0.tgz#20f9eab5ec70f5c7d215b1077b1c39161d292c7d" - integrity sha1-IPnqtexw9cfSFbEHexw5Fh0pLH0= - -arr-union@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/arr-union/-/arr-union-3.1.0.tgz#e39b09aea9def866a8f206e288af63919bae39c4" - integrity sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ= - -array-each@^1.0.0, array-each@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/array-each/-/array-each-1.0.1.tgz#a794af0c05ab1752846ee753a1f211a05ba0c44f" - integrity sha1-p5SvDAWrF1KEbudTofIRoFugxE8= - -array-from@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/array-from/-/array-from-2.1.1.tgz#cfe9d8c26628b9dc5aecc62a9f5d8f1f352c1195" - integrity sha1-z+nYwmYoudxa7MYqn12PHzUsEZU= - -array-initial@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/array-initial/-/array-initial-1.1.0.tgz#2fa74b26739371c3947bd7a7adc73be334b3d795" - integrity sha1-L6dLJnOTccOUe9enrcc74zSz15U= - dependencies: - array-slice "^1.0.0" - is-number "^4.0.0" - -array-last@^1.1.1: - version "1.3.0" - resolved "https://registry.yarnpkg.com/array-last/-/array-last-1.3.0.tgz#7aa77073fec565ddab2493f5f88185f404a9d336" - integrity sha512-eOCut5rXlI6aCOS7Z7kCplKRKyiFQ6dHFBem4PwlwKeNFk2/XxTrhRh5T9PyaEWGy/NHTZWbY+nsZlNFJu9rYg== - dependencies: - is-number "^4.0.0" - -array-slice@^0.2.3: - version "0.2.3" - resolved "https://registry.yarnpkg.com/array-slice/-/array-slice-0.2.3.tgz#dd3cfb80ed7973a75117cdac69b0b99ec86186f5" - integrity sha1-3Tz7gO15c6dRF82sabC5nshhhvU= - -array-slice@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/array-slice/-/array-slice-1.1.0.tgz#e368ea15f89bc7069f7ffb89aec3a6c7d4ac22d4" - integrity sha512-B1qMD3RBP7O8o0H2KbrXDyB0IccejMF15+87Lvlor12ONPRHP6gTjXMNkt/d3ZuOGbAe66hFmaCfECI24Ufp6w== - -array-sort@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/array-sort/-/array-sort-1.0.0.tgz#e4c05356453f56f53512a7d1d6123f2c54c0a88a" - integrity sha512-ihLeJkonmdiAsD7vpgN3CRcx2J2S0TiYW+IS/5zHBI7mKUq3ySvBdzzBfD236ubDBQFiiyG3SWCPc+msQ9KoYg== - dependencies: - default-compare "^1.0.0" - get-value "^2.0.6" - kind-of "^5.0.2" - -array-unique@^0.3.2: - version "0.3.2" - resolved "https://registry.yarnpkg.com/array-unique/-/array-unique-0.3.2.tgz#a894b75d4bc4f6cd679ef3244a9fd8f46ae2d428" - integrity sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg= - -asn1@~0.2.3: - version "0.2.4" - resolved "https://registry.yarnpkg.com/asn1/-/asn1-0.2.4.tgz#8d2475dfab553bb33e77b54e59e880bb8ce23136" - integrity sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg== - dependencies: - safer-buffer "~2.1.0" - -assert-plus@1.0.0, assert-plus@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-1.0.0.tgz#f12e0f3c5d77b0b1cdd9146942e4e96c1e4dd525" - integrity sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU= - -assign-symbols@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/assign-symbols/-/assign-symbols-1.0.0.tgz#59667f41fadd4f20ccbc2bb96b8d4f7f78ec0367" - integrity sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c= - -astral-regex@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/astral-regex/-/astral-regex-1.0.0.tgz#6c8c3fb827dd43ee3918f27b82782ab7658a6fd9" - integrity sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg== - -async-done@^1.2.0, async-done@^1.2.2: - version "1.3.2" - resolved "https://registry.yarnpkg.com/async-done/-/async-done-1.3.2.tgz#5e15aa729962a4b07414f528a88cdf18e0b290a2" - integrity sha512-uYkTP8dw2og1tu1nmza1n1CMW0qb8gWWlwqMmLb7MhBVs4BXrFziT6HXUd+/RlRA/i4H9AkofYloUbs1fwMqlw== - dependencies: - end-of-stream "^1.1.0" - once "^1.3.2" - process-nextick-args "^2.0.0" - stream-exhaust "^1.0.1" - -async-each@^1.0.1: - version "1.0.3" - resolved "https://registry.yarnpkg.com/async-each/-/async-each-1.0.3.tgz#b727dbf87d7651602f06f4d4ac387f47d91b0cbf" - integrity sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ== - -async-settle@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/async-settle/-/async-settle-1.0.0.tgz#1d0a914bb02575bec8a8f3a74e5080f72b2c0c6b" - integrity sha1-HQqRS7Aldb7IqPOnTlCA9yssDGs= - dependencies: - async-done "^1.2.2" - -async@1.x: - version "1.5.2" - resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a" - integrity sha1-7GphrlZIDAw8skHJVhjiCJL5Zyo= - -asynckit@^0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" - integrity sha1-x57Zf380y48robyXkLzDZkdLS3k= - -atob@^2.1.2: - version "2.1.2" - resolved "https://registry.yarnpkg.com/atob/-/atob-2.1.2.tgz#6d9517eb9e030d2436666651e86bd9f6f13533c9" - integrity sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg== - -aws-sign2@~0.7.0: - version "0.7.0" - resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz#b46e890934a9591f2d2f6f86d7e6a9f1b3fe76a8" - integrity sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg= - -aws4@^1.8.0: - version "1.11.0" - resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.11.0.tgz#d61f46d83b2519250e2784daf5b09479a8b41c59" - integrity sha512-xh1Rl34h6Fi1DC2WWKfxUTVqRsNnr6LsKz2+hfwDxQJWmrx8+c7ylaqBMcHfl1U1r2dsifOvKX3LQuLNZ+XSvA== - -babel-code-frame@^6.22.0: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.26.0.tgz#63fd43f7dc1e3bb7ce35947db8fe369a3f58c74b" - integrity sha1-Y/1D99weO7fONZR9uP42mj9Yx0s= - dependencies: - chalk "^1.1.3" - esutils "^2.0.2" - js-tokens "^3.0.2" - -babel-eslint@^10.0.2: - version "10.1.0" - resolved "https://registry.yarnpkg.com/babel-eslint/-/babel-eslint-10.1.0.tgz#6968e568a910b78fb3779cdd8b6ac2f479943232" - integrity sha512-ifWaTHQ0ce+448CYop8AdrQiBsGrnC+bMgfyKFdi6EsPLTAWG+QfyDeM6OH+FmWnKvEq5NnBMLvlBUPKQZoDSg== - dependencies: - "@babel/code-frame" "^7.0.0" - "@babel/parser" "^7.7.0" - "@babel/traverse" "^7.7.0" - "@babel/types" "^7.7.0" - eslint-visitor-keys "^1.0.0" - resolve "^1.12.0" - -babel-plugin-dynamic-import-node@^2.3.3: - version "2.3.3" - resolved "https://registry.yarnpkg.com/babel-plugin-dynamic-import-node/-/babel-plugin-dynamic-import-node-2.3.3.tgz#84fda19c976ec5c6defef57f9427b3def66e17a3" - integrity sha512-jZVI+s9Zg3IqA/kdi0i6UDCybUI3aSBLnglhYbSSjKlV7yF1F/5LWv8MakQmvYpnbJDS6fcBL2KzHSxNCMtWSQ== - dependencies: - object.assign "^4.1.0" - -babel-plugin-polyfill-corejs2@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-corejs2/-/babel-plugin-polyfill-corejs2-0.2.0.tgz#686775bf9a5aa757e10520903675e3889caeedc4" - integrity sha512-9bNwiR0dS881c5SHnzCmmGlMkJLl0OUZvxrxHo9w/iNoRuqaPjqlvBf4HrovXtQs/au5yKkpcdgfT1cC5PAZwg== - dependencies: - "@babel/compat-data" "^7.13.11" - "@babel/helper-define-polyfill-provider" "^0.2.0" - semver "^6.1.1" - -babel-plugin-polyfill-corejs3@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-corejs3/-/babel-plugin-polyfill-corejs3-0.2.0.tgz#f4b4bb7b19329827df36ff56f6e6d367026cb7a2" - integrity sha512-zZyi7p3BCUyzNxLx8KV61zTINkkV65zVkDAFNZmrTCRVhjo1jAS+YLvDJ9Jgd/w2tsAviCwFHReYfxO3Iql8Yg== - dependencies: - "@babel/helper-define-polyfill-provider" "^0.2.0" - core-js-compat "^3.9.1" - -babel-plugin-polyfill-regenerator@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-regenerator/-/babel-plugin-polyfill-regenerator-0.2.0.tgz#853f5f5716f4691d98c84f8069c7636ea8da7ab8" - integrity sha512-J7vKbCuD2Xi/eEHxquHN14bXAW9CXtecwuLrOIDJtcZzTaPzV1VdEfoUf9AzcRBMolKUQKM9/GVojeh0hFiqMg== - dependencies: - "@babel/helper-define-polyfill-provider" "^0.2.0" - -bach@^1.0.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/bach/-/bach-1.2.0.tgz#4b3ce96bf27134f79a1b414a51c14e34c3bd9880" - integrity sha1-Szzpa/JxNPeaG0FKUcFONMO9mIA= - dependencies: - arr-filter "^1.1.1" - arr-flatten "^1.0.1" - arr-map "^2.0.0" - array-each "^1.0.0" - array-initial "^1.0.0" - array-last "^1.1.1" - async-done "^1.2.2" - async-settle "^1.0.0" - now-and-later "^2.0.0" - -balanced-match@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" - integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== - -base@^0.11.1: - version "0.11.2" - resolved "https://registry.yarnpkg.com/base/-/base-0.11.2.tgz#7bde5ced145b6d551a90db87f83c558b4eb48a8f" - integrity sha512-5T6P4xPgpp0YDFvSWwEZ4NoE3aM4QBQXDzmVbraCkFj8zHM+mba8SyqB5DbZWyR7mYHo6Y7BdQo3MoA4m0TeQg== - dependencies: - cache-base "^1.0.1" - class-utils "^0.3.5" - component-emitter "^1.2.1" - define-property "^1.0.0" - isobject "^3.0.1" - mixin-deep "^1.2.0" - pascalcase "^0.1.1" - -bcrypt-pbkdf@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz#a4301d389b6a43f9b67ff3ca11a3f6637e360e9e" - integrity sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4= - dependencies: - tweetnacl "^0.14.3" - -binary-extensions@^1.0.0: - version "1.13.1" - resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-1.13.1.tgz#598afe54755b2868a5330d2aff9d4ebb53209b65" - integrity sha512-Un7MIEDdUC5gNpcGDV97op1Ywk748MpHcFTHoYs6qnj1Z3j7I53VG3nwZhKzoBZmbdRNnb6WRdFlwl7tSDuZGw== - -bindings@^1.5.0: - version "1.5.0" - resolved "https://registry.yarnpkg.com/bindings/-/bindings-1.5.0.tgz#10353c9e945334bc0511a6d90b38fbc7c9c504df" - integrity sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ== - dependencies: - file-uri-to-path "1.0.0" - -bluebird@^3.7.2: - version "3.7.2" - resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.7.2.tgz#9f229c15be272454ffa973ace0dbee79a1b0c36f" - integrity sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg== - -brace-expansion@^1.1.7: - version "1.1.11" - resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd" - integrity sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA== - dependencies: - balanced-match "^1.0.0" - concat-map "0.0.1" - -braces@^2.3.1, braces@^2.3.2: - version "2.3.2" - resolved "https://registry.yarnpkg.com/braces/-/braces-2.3.2.tgz#5979fd3f14cd531565e5fa2df1abfff1dfaee729" - integrity sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w== - dependencies: - arr-flatten "^1.1.0" - array-unique "^0.3.2" - extend-shallow "^2.0.1" - fill-range "^4.0.0" - isobject "^3.0.1" - repeat-element "^1.1.2" - snapdragon "^0.8.1" - snapdragon-node "^2.0.1" - split-string "^3.0.2" - to-regex "^3.0.1" - -browser-stdout@1.3.1: - version "1.3.1" - resolved "https://registry.yarnpkg.com/browser-stdout/-/browser-stdout-1.3.1.tgz#baa559ee14ced73452229bad7326467c61fabd60" - integrity sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw== - -browserslist@^4.14.5, browserslist@^4.16.5: - version "4.16.5" - resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.16.5.tgz#952825440bca8913c62d0021334cbe928ef062ae" - integrity sha512-C2HAjrM1AI/djrpAUU/tr4pml1DqLIzJKSLDBXBrNErl9ZCCTXdhwxdJjYc16953+mBWf7Lw+uUJgpgb8cN71A== - dependencies: - caniuse-lite "^1.0.30001214" - colorette "^1.2.2" - electron-to-chromium "^1.3.719" - escalade "^3.1.1" - node-releases "^1.1.71" - -buffer-equal@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/buffer-equal/-/buffer-equal-1.0.0.tgz#59616b498304d556abd466966b22eeda3eca5fbe" - integrity sha1-WWFrSYME1Var1GaWayLu2j7KX74= - -buffer-from@^1.0.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.1.tgz#32713bc028f75c02fdb710d7c7bcec1f2c6070ef" - integrity sha512-MQcXEUbCKtEo7bhqEs6560Hyd4XaovZlO/k9V3hjVUF/zwW7KBVdSK4gIt/bzwS9MbR5qob+F5jusZsb0YQK2A== - -cache-base@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/cache-base/-/cache-base-1.0.1.tgz#0a7f46416831c8b662ee36fe4e7c59d76f666ab2" - integrity sha512-AKcdTnFSWATd5/GCPRxr2ChwIJ85CeyrEyjRHlKxQ56d4XJMGym0uAiKn0xbLOGOl3+yRpOTi484dVCEc5AUzQ== - dependencies: - collection-visit "^1.0.0" - component-emitter "^1.2.1" - get-value "^2.0.6" - has-value "^1.0.0" - isobject "^3.0.1" - set-value "^2.0.0" - to-object-path "^0.3.0" - union-value "^1.0.0" - unset-value "^1.0.0" - -call-bind@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/call-bind/-/call-bind-1.0.2.tgz#b1d4e89e688119c3c9a903ad30abb2f6a919be3c" - integrity sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA== - dependencies: - function-bind "^1.1.1" - get-intrinsic "^1.0.2" - -caller-path@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/caller-path/-/caller-path-0.1.0.tgz#94085ef63581ecd3daa92444a8fe94e82577751f" - integrity sha1-lAhe9jWB7NPaqSREqP6U6CV3dR8= - dependencies: - callsites "^0.2.0" - -callsites@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/callsites/-/callsites-0.2.0.tgz#afab96262910a7f33c19a5775825c69f34e350ca" - integrity sha1-r6uWJikQp/M8GaV3WCXGnzTjUMo= - -callsites@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" - integrity sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ== - -camelcase@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-3.0.0.tgz#32fc4b9fcdaf845fcdf7e73bb97cac2261f0ab0a" - integrity sha1-MvxLn82vhF/N9+c7uXysImHwqwo= - -caniuse-lite@^1.0.30001214: - version "1.0.30001219" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001219.tgz#5bfa5d0519f41f993618bd318f606a4c4c16156b" - integrity sha512-c0yixVG4v9KBc/tQ2rlbB3A/bgBFRvl8h8M4IeUbqCca4gsiCfvtaheUssbnux/Mb66Vjz7x8yYjDgYcNQOhyQ== - -caseless@~0.12.0: - version "0.12.0" - resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" - integrity sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw= - -chalk@^1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-1.1.3.tgz#a8115c55e4a702fe4d150abd3872822a7e09fc98" - integrity sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg= - dependencies: - ansi-styles "^2.2.1" - escape-string-regexp "^1.0.2" - has-ansi "^2.0.0" - strip-ansi "^3.0.0" - supports-color "^2.0.0" - -chalk@^2.0.0, chalk@^2.1.0: - version "2.4.2" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" - integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== - dependencies: - ansi-styles "^3.2.1" - escape-string-regexp "^1.0.5" - supports-color "^5.3.0" - -chalk@^4.1.0: - version "4.1.1" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.1.tgz#c80b3fab28bf6371e6863325eee67e618b77e6ad" - integrity sha512-diHzdDKxcU+bAsUboHLPEDQiw0qEe0qd7SYUn3HgcFlWgbDcfLGswOHYeGrHKzG9z6UYf01d9VFMfZxPM1xZSg== - dependencies: - ansi-styles "^4.1.0" - supports-color "^7.1.0" - -chardet@^0.4.0: - version "0.4.2" - resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.4.2.tgz#b5473b33dc97c424e5d98dc87d55d4d8a29c8bf2" - integrity sha1-tUc7M9yXxCTl2Y3IfVXU2KKci/I= - -chardet@^0.7.0: - version "0.7.0" - resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.7.0.tgz#90094849f0937f2eedc2425d0d28a9e5f0cbad9e" - integrity sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA== - -chokidar@^2.0.0: - version "2.1.8" - resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-2.1.8.tgz#804b3a7b6a99358c3c5c61e71d8728f041cff917" - integrity sha512-ZmZUazfOzf0Nve7duiCKD23PFSCs4JPoYyccjUFF3aQkQadqBhfzhjkwBH2mNOG9cTBwhamM37EIsIkZw3nRgg== - dependencies: - anymatch "^2.0.0" - async-each "^1.0.1" - braces "^2.3.2" - glob-parent "^3.1.0" - inherits "^2.0.3" - is-binary-path "^1.0.0" - is-glob "^4.0.0" - normalize-path "^3.0.0" - path-is-absolute "^1.0.0" - readdirp "^2.2.1" - upath "^1.1.1" - optionalDependencies: - fsevents "^1.2.7" - -circular-json@^0.3.1: - version "0.3.3" - resolved "https://registry.yarnpkg.com/circular-json/-/circular-json-0.3.3.tgz#815c99ea84f6809529d2f45791bdf82711352d66" - integrity sha512-UZK3NBx2Mca+b5LsG7bY183pHWt5Y1xts4P3Pz7ENTwGVnJOUWbRb3ocjvX7hx9tq/yTAdclXm9sZ38gNuem4A== - -class-utils@^0.3.5: - version "0.3.6" - resolved "https://registry.yarnpkg.com/class-utils/-/class-utils-0.3.6.tgz#f93369ae8b9a7ce02fd41faad0ca83033190c463" - integrity sha512-qOhPa/Fj7s6TY8H8esGu5QNpMMQxz79h+urzrNYN6mn+9BnxlDGf5QZ+XeCDsxSjPqsSR56XOZOJmpeurnLMeg== - dependencies: - arr-union "^3.1.0" - define-property "^0.2.5" - isobject "^3.0.0" - static-extend "^0.1.1" - -cli-cursor@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-2.1.0.tgz#b35dac376479facc3e94747d41d0d0f5238ffcb5" - integrity sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU= - dependencies: - restore-cursor "^2.0.0" - -cli-cursor@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-3.1.0.tgz#264305a7ae490d1d03bf0c9ba7c925d1753af307" - integrity sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw== - dependencies: - restore-cursor "^3.1.0" - -cli-width@^2.0.0: - version "2.2.1" - resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-2.2.1.tgz#b0433d0b4e9c847ef18868a4ef16fd5fc8271c48" - integrity sha512-GRMWDxpOB6Dgk2E5Uo+3eEBvtOOlimMmpbFiKuLFnQzYDavtLFY3K5ona41jgN/WdRZtG7utuVSVTL4HbZHGkw== - -cli-width@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-3.0.0.tgz#a2f48437a2caa9a22436e794bf071ec9e61cedf6" - integrity sha512-FxqpkPPwu1HjuN93Omfm4h8uIanXofW0RxVEW3k5RKx+mJJYSthzNhp32Kzxxy3YAEZ/Dc/EWN1vZRY0+kOhbw== - -cliui@^3.2.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/cliui/-/cliui-3.2.0.tgz#120601537a916d29940f934da3b48d585a39213d" - integrity sha1-EgYBU3qRbSmUD5NNo7SNWFo5IT0= - dependencies: - string-width "^1.0.1" - strip-ansi "^3.0.1" - wrap-ansi "^2.0.0" - -clone-buffer@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/clone-buffer/-/clone-buffer-1.0.0.tgz#e3e25b207ac4e701af721e2cb5a16792cac3dc58" - integrity sha1-4+JbIHrE5wGvch4staFnksrD3Fg= - -clone-deep@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/clone-deep/-/clone-deep-4.0.1.tgz#c19fd9bdbbf85942b4fd979c84dcf7d5f07c2387" - integrity sha512-neHB9xuzh/wk0dIHweyAXv2aPGZIVk3pLMe+/RNzINf17fe0OG96QroktYAUm7SM1PBnzTabaLboqqxDyMU+SQ== - dependencies: - is-plain-object "^2.0.4" - kind-of "^6.0.2" - shallow-clone "^3.0.0" - -clone-stats@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/clone-stats/-/clone-stats-1.0.0.tgz#b3782dff8bb5474e18b9b6bf0fdfe782f8777680" - integrity sha1-s3gt/4u1R04Yuba/D9/ngvh3doA= - -clone@^2.1.1: - version "2.1.2" - resolved "https://registry.yarnpkg.com/clone/-/clone-2.1.2.tgz#1b7f4b9f591f1e8f83670401600345a02887435f" - integrity sha1-G39Ln1kfHo+DZwQBYANFoCiHQ18= - -cloneable-readable@^1.0.0: - version "1.1.3" - resolved "https://registry.yarnpkg.com/cloneable-readable/-/cloneable-readable-1.1.3.tgz#120a00cb053bfb63a222e709f9683ea2e11d8cec" - integrity sha512-2EF8zTQOxYq70Y4XKtorQupqF0m49MBz2/yf5Bj+MHjvpG3Hy7sImifnqD6UA+TKYxeSV+u6qqQPawN5UvnpKQ== - dependencies: - inherits "^2.0.1" - process-nextick-args "^2.0.0" - readable-stream "^2.3.5" - -co@^4.6.0: - version "4.6.0" - resolved "https://registry.yarnpkg.com/co/-/co-4.6.0.tgz#6ea6bdf3d853ae54ccb8e47bfa0bf3f9031fb184" - integrity sha1-bqa989hTrlTMuOR7+gvz+QMfsYQ= - -code-point-at@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77" - integrity sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c= - -collection-map@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/collection-map/-/collection-map-1.0.0.tgz#aea0f06f8d26c780c2b75494385544b2255af18c" - integrity sha1-rqDwb40mx4DCt1SUOFVEsiVa8Yw= - dependencies: - arr-map "^2.0.2" - for-own "^1.0.0" - make-iterator "^1.0.0" - -collection-visit@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/collection-visit/-/collection-visit-1.0.0.tgz#4bc0373c164bc3291b4d368c829cf1a80a59dca0" - integrity sha1-S8A3PBZLwykbTTaMgpzxqApZ3KA= - dependencies: - map-visit "^1.0.0" - object-visit "^1.0.0" - -color-convert@^1.9.0: - version "1.9.3" - resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.3.tgz#bb71850690e1f136567de629d2d5471deda4c1e8" - integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== - dependencies: - color-name "1.1.3" - -color-convert@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" - integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== - dependencies: - color-name "~1.1.4" - -color-name@1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" - integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= - -color-name@~1.1.4: - version "1.1.4" - resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" - integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== - -color-support@^1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/color-support/-/color-support-1.1.3.tgz#93834379a1cc9a0c61f82f52f0d04322251bd5a2" - integrity sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg== - -colorette@^1.2.2: - version "1.2.2" - resolved "https://registry.yarnpkg.com/colorette/-/colorette-1.2.2.tgz#cbcc79d5e99caea2dbf10eb3a26fd8b3e6acfa94" - integrity sha512-MKGMzyfeuutC/ZJ1cba9NqcNpfeqMUcYmyF1ZFY6/Cn7CNSAKx6a+s48sqLqyAiZuaP2TcqMhoo+dlwFnVxT9w== - -combined-stream@^1.0.6, combined-stream@~1.0.6: - version "1.0.8" - resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.8.tgz#c3d45a8b34fd730631a110a8a2520682b31d5a7f" - integrity sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg== - dependencies: - delayed-stream "~1.0.0" - -commander@2.15.1: - version "2.15.1" - resolved "https://registry.yarnpkg.com/commander/-/commander-2.15.1.tgz#df46e867d0fc2aec66a34662b406a9ccafff5b0f" - integrity sha512-VlfT9F3V0v+jr4yxPc5gg9s62/fIVWsd2Bk2iD435um1NlGMYdVCq+MjcXnhYq2icNOizHr1kK+5TI6H0Hy0ag== - -commondir@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/commondir/-/commondir-1.0.1.tgz#ddd800da0c66127393cca5950ea968a3aaf1253b" - integrity sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs= - -component-emitter@^1.2.1: - version "1.3.0" - resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.3.0.tgz#16e4070fba8ae29b679f2215853ee181ab2eabc0" - integrity sha512-Rd3se6QB+sO1TwqZjscQrurpEPIfO0/yYnSin6Q/rD3mOutHvUrCAhJub3r90uNb+SESBuE0QYoB90YdfatsRg== - -concat-map@0.0.1: - version "0.0.1" - resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" - integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= - -concat-stream@^1.6.0: - version "1.6.2" - resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34" - integrity sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw== - dependencies: - buffer-from "^1.0.0" - inherits "^2.0.3" - readable-stream "^2.2.2" - typedarray "^0.0.6" - -convert-source-map@^1.5.0, convert-source-map@^1.7.0: - version "1.7.0" - resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.7.0.tgz#17a2cb882d7f77d3490585e2ce6c524424a3a442" - integrity sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA== - dependencies: - safe-buffer "~5.1.1" - -copy-descriptor@^0.1.0: - version "0.1.1" - resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" - integrity sha1-Z29us8OZl8LuGsOpJP1hJHSPV40= - -copy-props@^2.0.1: - version "2.0.5" - resolved "https://registry.yarnpkg.com/copy-props/-/copy-props-2.0.5.tgz#03cf9ae328d4ebb36f8f1d804448a6af9ee3f2d2" - integrity sha512-XBlx8HSqrT0ObQwmSzM7WE5k8FxTV75h1DX1Z3n6NhQ/UYYAvInWYmG06vFt7hQZArE2fuO62aihiWIVQwh1sw== - dependencies: - each-props "^1.3.2" - is-plain-object "^5.0.0" - -core-js-compat@^3.9.0, core-js-compat@^3.9.1: - version "3.11.1" - resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.11.1.tgz#57a91e9b02d3bb8cf37f82eceaf44a3d646fa614" - integrity sha512-aZ0e4tmlG/aOBHj92/TuOuZwp6jFvn1WNabU5VOVixzhu5t5Ao+JZkQOPlgNXu6ynwLrwJxklT4Gw1G1VGEh+g== - dependencies: - browserslist "^4.16.5" - semver "7.0.0" - -core-util-is@1.0.2, core-util-is@~1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" - integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac= - -cross-spawn@^5.1.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-5.1.0.tgz#e8bd0efee58fcff6f8f94510a0a554bbfa235449" - integrity sha1-6L0O/uWPz/b4+UUQoKVUu/ojVEk= - dependencies: - lru-cache "^4.0.1" - shebang-command "^1.2.0" - which "^1.2.9" - -cross-spawn@^6.0.0, cross-spawn@^6.0.5: - version "6.0.5" - resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4" - integrity sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ== - dependencies: - nice-try "^1.0.4" - path-key "^2.0.1" - semver "^5.5.0" - shebang-command "^1.2.0" - which "^1.2.9" - -d@1, d@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/d/-/d-1.0.1.tgz#8698095372d58dbee346ffd0c7093f99f8f9eb5a" - integrity sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA== - dependencies: - es5-ext "^0.10.50" - type "^1.0.1" - -dargs@^5.1.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/dargs/-/dargs-5.1.0.tgz#ec7ea50c78564cd36c9d5ec18f66329fade27829" - integrity sha1-7H6lDHhWTNNsnV7Bj2Yyn63ieCk= - -dashdash@^1.12.0: - version "1.14.1" - resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0" - integrity sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA= - dependencies: - assert-plus "^1.0.0" - -debug@3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" - integrity sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g== - dependencies: - ms "2.0.0" - -debug@^2.2.0, debug@^2.3.3: - version "2.6.9" - resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" - integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== - dependencies: - ms "2.0.0" - -debug@^3.1.0: - version "3.2.7" - resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.7.tgz#72580b7e9145fb39b6676f9c5e5fb100b934179a" - integrity sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ== - dependencies: - ms "^2.1.1" - -debug@^4.0.1, debug@^4.1.0, debug@^4.1.1: - version "4.3.1" - resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.1.tgz#f0d229c505e0c6d8c49ac553d1b13dc183f6b2ee" - integrity sha512-doEwdvm4PCeK4K3RQN2ZC2BYUBaxwLARCqZmMjtF8a51J2Rb0xpVloFRnCODwqjpwnAoao4pelN8l3RJdv3gRQ== - dependencies: - ms "2.1.2" - -decamelize@^1.1.1: - version "1.2.0" - resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" - integrity sha1-9lNNFRSCabIDUue+4m9QH5oZEpA= - -decode-uri-component@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545" - integrity sha1-6zkTMzRYd1y4TNGh+uBiEGu4dUU= - -deep-is@~0.1.3: - version "0.1.3" - resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34" - integrity sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ= - -default-compare@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/default-compare/-/default-compare-1.0.0.tgz#cb61131844ad84d84788fb68fd01681ca7781a2f" - integrity sha512-QWfXlM0EkAbqOCbD/6HjdwT19j7WCkMyiRhWilc4H9/5h/RzTF9gv5LYh1+CmDV5d1rki6KAWLtQale0xt20eQ== - dependencies: - kind-of "^5.0.2" - -default-resolution@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/default-resolution/-/default-resolution-2.0.0.tgz#bcb82baa72ad79b426a76732f1a81ad6df26d684" - integrity sha1-vLgrqnKtebQmp2cy8aga1t8m1oQ= - -define-properties@^1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.3.tgz#cf88da6cbee26fe6db7094f61d870cbd84cee9f1" - integrity sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ== - dependencies: - object-keys "^1.0.12" - -define-property@^0.2.5: - version "0.2.5" - resolved "https://registry.yarnpkg.com/define-property/-/define-property-0.2.5.tgz#c35b1ef918ec3c990f9a5bc57be04aacec5c8116" - integrity sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY= - dependencies: - is-descriptor "^0.1.0" - -define-property@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/define-property/-/define-property-1.0.0.tgz#769ebaaf3f4a63aad3af9e8d304c9bbe79bfb0e6" - integrity sha1-dp66rz9KY6rTr56NMEybvnm/sOY= - dependencies: - is-descriptor "^1.0.0" - -define-property@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/define-property/-/define-property-2.0.2.tgz#d459689e8d654ba77e02a817f8710d702cb16e9d" - integrity sha512-jwK2UV4cnPpbcG7+VRARKTZPUWowwXA8bzH5NP6ud0oeAxyYPuGZUAC7hMugpCdz4BeSZl2Dl9k66CHJ/46ZYQ== - dependencies: - is-descriptor "^1.0.2" - isobject "^3.0.1" - -delayed-stream@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" - integrity sha1-3zrhmayt+31ECqrgsp4icrJOxhk= - -detect-file@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/detect-file/-/detect-file-1.0.0.tgz#f0d66d03672a825cb1b73bdb3fe62310c8e552b7" - integrity sha1-8NZtA2cqglyxtzvbP+YjEMjlUrc= - -diff@3.5.0, diff@^3.5.0: - version "3.5.0" - resolved "https://registry.yarnpkg.com/diff/-/diff-3.5.0.tgz#800c0dd1e0a8bfbc95835c202ad220fe317e5a12" - integrity sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA== - -doctrine@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.1.0.tgz#5cd01fc101621b42c4cd7f5d1a66243716d3f39d" - integrity sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw== - dependencies: - esutils "^2.0.2" - -doctrine@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-3.0.0.tgz#addebead72a6574db783639dc87a121773973961" - integrity sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w== - dependencies: - esutils "^2.0.2" - -duplexify@^3.6.0: - version "3.7.1" - resolved "https://registry.yarnpkg.com/duplexify/-/duplexify-3.7.1.tgz#2a4df5317f6ccfd91f86d6fd25d8d8a103b88309" - integrity sha512-07z8uv2wMyS51kKhD1KsdXJg5WQ6t93RneqRxUHnskXVtlYYkLqM0gqStQZ3pj073g687jPCHrqNfCzawLYh5g== - dependencies: - end-of-stream "^1.0.0" - inherits "^2.0.1" - readable-stream "^2.0.0" - stream-shift "^1.0.0" - -each-props@^1.3.2: - version "1.3.2" - resolved "https://registry.yarnpkg.com/each-props/-/each-props-1.3.2.tgz#ea45a414d16dd5cfa419b1a81720d5ca06892333" - integrity sha512-vV0Hem3zAGkJAyU7JSjixeU66rwdynTAa1vofCrSA5fEln+m67Az9CcnkVD776/fsN/UjIWmBDoNRS6t6G9RfA== - dependencies: - is-plain-object "^2.0.1" - object.defaults "^1.1.0" - -ecc-jsbn@~0.1.1: - version "0.1.2" - resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz#3a83a904e54353287874c564b7549386849a98c9" - integrity sha1-OoOpBOVDUyh4dMVkt1SThoSamMk= - dependencies: - jsbn "~0.1.0" - safer-buffer "^2.1.0" - -electron-to-chromium@^1.3.719: - version "1.3.723" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.723.tgz#52769a75635342a4db29af5f1e40bd3dad02c877" - integrity sha512-L+WXyXI7c7+G1V8ANzRsPI5giiimLAUDC6Zs1ojHHPhYXb3k/iTABFmWjivEtsWrRQymjnO66/rO2ZTABGdmWg== - -emoji-regex@^7.0.1: - version "7.0.3" - resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-7.0.3.tgz#933a04052860c85e83c122479c4748a8e4c72156" - integrity sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA== - -emoji-regex@^8.0.0: - version "8.0.0" - resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" - integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== - -end-of-stream@^1.0.0, end-of-stream@^1.1.0: - version "1.4.4" - resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.4.tgz#5ae64a5f45057baf3626ec14da0ca5e4b2431eb0" - integrity sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q== - dependencies: - once "^1.4.0" - -error-ex@^1.2.0: - version "1.3.2" - resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" - integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== - dependencies: - is-arrayish "^0.2.1" - -es5-ext@^0.10.35, es5-ext@^0.10.46, es5-ext@^0.10.50: - version "0.10.53" - resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.53.tgz#93c5a3acfdbef275220ad72644ad02ee18368de1" - integrity sha512-Xs2Stw6NiNHWypzRTY1MtaG/uJlwCk8kH81920ma8mvN8Xq1gsfhZvpkImLQArw8AHnv8MT2I45J3c0R8slE+Q== - dependencies: - es6-iterator "~2.0.3" - es6-symbol "~3.1.3" - next-tick "~1.0.0" - -es6-iterator@^2.0.1, es6-iterator@^2.0.3, es6-iterator@~2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/es6-iterator/-/es6-iterator-2.0.3.tgz#a7de889141a05a94b0854403b2d0a0fbfa98f3b7" - integrity sha1-p96IkUGgWpSwhUQDstCg+/qY87c= - dependencies: - d "1" - es5-ext "^0.10.35" - es6-symbol "^3.1.1" - -es6-symbol@^3.1.1, es6-symbol@~3.1.3: - version "3.1.3" - resolved "https://registry.yarnpkg.com/es6-symbol/-/es6-symbol-3.1.3.tgz#bad5d3c1bcdac28269f4cb331e431c78ac705d18" - integrity sha512-NJ6Yn3FuDinBaBRWl/q5X/s4koRHBrgKAu+yGI6JCBeiu3qrcbJhwT2GeR/EXVfylRk8dpQVJoLEFhK+Mu31NA== - dependencies: - d "^1.0.1" - ext "^1.1.2" - -es6-weak-map@^2.0.1: - version "2.0.3" - resolved "https://registry.yarnpkg.com/es6-weak-map/-/es6-weak-map-2.0.3.tgz#b6da1f16cc2cc0d9be43e6bdbfc5e7dfcdf31d53" - integrity sha512-p5um32HOTO1kP+w7PRnB+5lQ43Z6muuMuIMffvDN8ZB4GcnjLBV6zGStpbASIMk4DCAvEaamhe2zhyCb/QXXsA== - dependencies: - d "1" - es5-ext "^0.10.46" - es6-iterator "^2.0.3" - es6-symbol "^3.1.1" - -escalade@^3.1.1: - version "3.1.1" - resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.1.1.tgz#d8cfdc7000965c5a0174b4a82eaa5c0552742e40" - integrity sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw== - -escape-string-regexp@1.0.5, escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" - integrity sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ= - -escodegen@1.8.x: - version "1.8.1" - resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.8.1.tgz#5a5b53af4693110bebb0867aa3430dd3b70a1018" - integrity sha1-WltTr0aTEQvrsIZ6o0MN07cKEBg= - dependencies: - esprima "^2.7.1" - estraverse "^1.9.1" - esutils "^2.0.2" - optionator "^0.8.1" - optionalDependencies: - source-map "~0.2.0" - -eslint-scope@^3.7.1: - version "3.7.3" - resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-3.7.3.tgz#bb507200d3d17f60247636160b4826284b108535" - integrity sha512-W+B0SvF4gamyCTmUc+uITPY0989iXVfKvhwtmJocTaYoc/3khEHmEmvfY/Gn9HA9VV75jrQECsHizkNw1b68FA== - dependencies: - esrecurse "^4.1.0" - estraverse "^4.1.1" - -eslint-scope@^5.0.0: - version "5.1.1" - resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-5.1.1.tgz#e786e59a66cb92b3f6c1fb0d508aab174848f48c" - integrity sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw== - dependencies: - esrecurse "^4.3.0" - estraverse "^4.1.1" - -eslint-utils@^1.4.3: - version "1.4.3" - resolved "https://registry.yarnpkg.com/eslint-utils/-/eslint-utils-1.4.3.tgz#74fec7c54d0776b6f67e0251040b5806564e981f" - integrity sha512-fbBN5W2xdY45KulGXmLHZ3c3FHfVYmKg0IrAKGOkT/464PQsx2UeIzfz1RmEci+KLm1bBaAzZAh8+/E+XAeZ8Q== - dependencies: - eslint-visitor-keys "^1.1.0" - -eslint-visitor-keys@^1.0.0, eslint-visitor-keys@^1.1.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz#30ebd1ef7c2fdff01c3a4f151044af25fab0523e" - integrity sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ== - -eslint@^4.0.0: - version "4.19.1" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.19.1.tgz#32d1d653e1d90408854bfb296f076ec7e186a300" - integrity sha512-bT3/1x1EbZB7phzYu7vCr1v3ONuzDtX8WjuM9c0iYxe+cq+pwcKEoQjl7zd3RpC6YOLgnSy3cTN58M2jcoPDIQ== - dependencies: - ajv "^5.3.0" - babel-code-frame "^6.22.0" - chalk "^2.1.0" - concat-stream "^1.6.0" - cross-spawn "^5.1.0" - debug "^3.1.0" - doctrine "^2.1.0" - eslint-scope "^3.7.1" - eslint-visitor-keys "^1.0.0" - espree "^3.5.4" - esquery "^1.0.0" - esutils "^2.0.2" - file-entry-cache "^2.0.0" - functional-red-black-tree "^1.0.1" - glob "^7.1.2" - globals "^11.0.1" - ignore "^3.3.3" - imurmurhash "^0.1.4" - inquirer "^3.0.6" - is-resolvable "^1.0.0" - js-yaml "^3.9.1" - json-stable-stringify-without-jsonify "^1.0.1" - levn "^0.3.0" - lodash "^4.17.4" - minimatch "^3.0.2" - mkdirp "^0.5.1" - natural-compare "^1.4.0" - optionator "^0.8.2" - path-is-inside "^1.0.2" - pluralize "^7.0.0" - progress "^2.0.0" - regexpp "^1.0.1" - require-uncached "^1.0.3" - semver "^5.3.0" - strip-ansi "^4.0.0" - strip-json-comments "~2.0.1" - table "4.0.2" - text-table "~0.2.0" - -eslint@^6.8.0: - version "6.8.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-6.8.0.tgz#62262d6729739f9275723824302fb227c8c93ffb" - integrity sha512-K+Iayyo2LtyYhDSYwz5D5QdWw0hCacNzyq1Y821Xna2xSJj7cijoLLYmLxTQgcgZ9mC61nryMy9S7GRbYpI5Ig== - dependencies: - "@babel/code-frame" "^7.0.0" - ajv "^6.10.0" - chalk "^2.1.0" - cross-spawn "^6.0.5" - debug "^4.0.1" - doctrine "^3.0.0" - eslint-scope "^5.0.0" - eslint-utils "^1.4.3" - eslint-visitor-keys "^1.1.0" - espree "^6.1.2" - esquery "^1.0.1" - esutils "^2.0.2" - file-entry-cache "^5.0.1" - functional-red-black-tree "^1.0.1" - glob-parent "^5.0.0" - globals "^12.1.0" - ignore "^4.0.6" - import-fresh "^3.0.0" - imurmurhash "^0.1.4" - inquirer "^7.0.0" - is-glob "^4.0.0" - js-yaml "^3.13.1" - json-stable-stringify-without-jsonify "^1.0.1" - levn "^0.3.0" - lodash "^4.17.14" - minimatch "^3.0.4" - mkdirp "^0.5.1" - natural-compare "^1.4.0" - optionator "^0.8.3" - progress "^2.0.0" - regexpp "^2.0.1" - semver "^6.1.2" - strip-ansi "^5.2.0" - strip-json-comments "^3.0.1" - table "^5.2.3" - text-table "^0.2.0" - v8-compile-cache "^2.0.3" - -espree@^3.5.4: - version "3.5.4" - resolved "https://registry.yarnpkg.com/espree/-/espree-3.5.4.tgz#b0f447187c8a8bed944b815a660bddf5deb5d1a7" - integrity sha512-yAcIQxtmMiB/jL32dzEp2enBeidsB7xWPLNiw3IIkpVds1P+h7qF9YwJq1yUNzp2OKXgAprs4F61ih66UsoD1A== - dependencies: - acorn "^5.5.0" - acorn-jsx "^3.0.0" - -espree@^6.1.2: - version "6.2.1" - resolved "https://registry.yarnpkg.com/espree/-/espree-6.2.1.tgz#77fc72e1fd744a2052c20f38a5b575832e82734a" - integrity sha512-ysCxRQY3WaXJz9tdbWOwuWr5Y/XrPTGX9Kiz3yoUXwW0VZ4w30HTkQLaGx/+ttFjF8i+ACbArnB4ce68a9m5hw== - dependencies: - acorn "^7.1.1" - acorn-jsx "^5.2.0" - eslint-visitor-keys "^1.1.0" - -esprima@2.7.x, esprima@^2.7.1: - version "2.7.3" - resolved "https://registry.yarnpkg.com/esprima/-/esprima-2.7.3.tgz#96e3b70d5779f6ad49cd032673d1c312767ba581" - integrity sha1-luO3DVd59q1JzQMmc9HDEnZ7pYE= - -esprima@^4.0.0: - version "4.0.1" - resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" - integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== - -esquery@^1.0.0, esquery@^1.0.1: - version "1.4.0" - resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.4.0.tgz#2148ffc38b82e8c7057dfed48425b3e61f0f24a5" - integrity sha512-cCDispWt5vHHtwMY2YrAQ4ibFkAL8RbH5YGBnZBc90MolvvfkkQcJro/aZiAQUlQ3qgrYS6D6v8Gc5G5CQsc9w== - dependencies: - estraverse "^5.1.0" - -esrecurse@^4.1.0, esrecurse@^4.3.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.3.0.tgz#7ad7964d679abb28bee72cec63758b1c5d2c9921" - integrity sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag== - dependencies: - estraverse "^5.2.0" - -estraverse@^1.9.1: - version "1.9.3" - resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-1.9.3.tgz#af67f2dc922582415950926091a4005d29c9bb44" - integrity sha1-r2fy3JIlgkFZUJJgkaQAXSnJu0Q= - -estraverse@^4.1.1: - version "4.3.0" - resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.3.0.tgz#398ad3f3c5a24948be7725e83d11a7de28cdbd1d" - integrity sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw== - -estraverse@^5.1.0, estraverse@^5.2.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-5.2.0.tgz#307df42547e6cc7324d3cf03c155d5cdb8c53880" - integrity sha512-BxbNGGNm0RyRYvUdHpIwv9IWzeM9XClbOxwoATuFdOE7ZE6wHL+HQ5T8hoPM+zHvmKzzsEqhgy0GrQ5X13afiQ== - -esutils@^2.0.2: - version "2.0.3" - resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.3.tgz#74d2eb4de0b8da1293711910d50775b9b710ef64" - integrity sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g== - -execa@^0.10.0: - version "0.10.0" - resolved "https://registry.yarnpkg.com/execa/-/execa-0.10.0.tgz#ff456a8f53f90f8eccc71a96d11bdfc7f082cb50" - integrity sha512-7XOMnz8Ynx1gGo/3hyV9loYNPWM94jG3+3T3Y8tsfSstFmETmENCMU/A/zj8Lyaj1lkgEepKepvd6240tBRvlw== - dependencies: - cross-spawn "^6.0.0" - get-stream "^3.0.0" - is-stream "^1.1.0" - npm-run-path "^2.0.0" - p-finally "^1.0.0" - signal-exit "^3.0.0" - strip-eof "^1.0.0" - -expand-brackets@^2.1.4: - version "2.1.4" - resolved "https://registry.yarnpkg.com/expand-brackets/-/expand-brackets-2.1.4.tgz#b77735e315ce30f6b6eff0f83b04151a22449622" - integrity sha1-t3c14xXOMPa27/D4OwQVGiJEliI= - dependencies: - debug "^2.3.3" - define-property "^0.2.5" - extend-shallow "^2.0.1" - posix-character-classes "^0.1.0" - regex-not "^1.0.0" - snapdragon "^0.8.1" - to-regex "^3.0.1" - -expand-tilde@^2.0.0, expand-tilde@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/expand-tilde/-/expand-tilde-2.0.2.tgz#97e801aa052df02454de46b02bf621642cdc8502" - integrity sha1-l+gBqgUt8CRU3kawK/YhZCzchQI= - dependencies: - homedir-polyfill "^1.0.1" - -ext@^1.1.2: - version "1.4.0" - resolved "https://registry.yarnpkg.com/ext/-/ext-1.4.0.tgz#89ae7a07158f79d35517882904324077e4379244" - integrity sha512-Key5NIsUxdqKg3vIsdw9dSuXpPCQ297y6wBjL30edxwPgt2E44WcWBZey/ZvUc6sERLTxKdyCu4gZFmUbk1Q7A== - dependencies: - type "^2.0.0" - -extend-shallow@^1.1.2: - version "1.1.4" - resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-1.1.4.tgz#19d6bf94dfc09d76ba711f39b872d21ff4dd9071" - integrity sha1-Gda/lN/AnXa6cR85uHLSH/TdkHE= - dependencies: - kind-of "^1.1.0" - -extend-shallow@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-2.0.1.tgz#51af7d614ad9a9f610ea1bafbb989d6b1c56890f" - integrity sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8= - dependencies: - is-extendable "^0.1.0" - -extend-shallow@^3.0.0, extend-shallow@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-3.0.2.tgz#26a71aaf073b39fb2127172746131c2704028db8" - integrity sha1-Jqcarwc7OfshJxcnRhMcJwQCjbg= - dependencies: - assign-symbols "^1.0.0" - is-extendable "^1.0.1" - -extend@^3.0.0, extend@~3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa" - integrity sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g== - -external-editor@^2.0.4: - version "2.2.0" - resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-2.2.0.tgz#045511cfd8d133f3846673d1047c154e214ad3d5" - integrity sha512-bSn6gvGxKt+b7+6TKEv1ZycHleA7aHhRHyAqJyp5pbUFuYYNIzpZnQDk7AsYckyWdEnTeAnay0aCy2aV6iTk9A== - dependencies: - chardet "^0.4.0" - iconv-lite "^0.4.17" - tmp "^0.0.33" - -external-editor@^3.0.3: - version "3.1.0" - resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-3.1.0.tgz#cb03f740befae03ea4d283caed2741a83f335495" - integrity sha512-hMQ4CX1p1izmuLYyZqLMO/qGNw10wSv9QDCPfzXfyFrOaCSSoRfqE1Kf1s5an66J5JZC62NewG+mK49jOCtQew== - dependencies: - chardet "^0.7.0" - iconv-lite "^0.4.24" - tmp "^0.0.33" - -extglob@^2.0.4: - version "2.0.4" - resolved "https://registry.yarnpkg.com/extglob/-/extglob-2.0.4.tgz#ad00fe4dc612a9232e8718711dc5cb5ab0285543" - integrity sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw== - dependencies: - array-unique "^0.3.2" - define-property "^1.0.0" - expand-brackets "^2.1.4" - extend-shallow "^2.0.1" - fragment-cache "^0.2.1" - regex-not "^1.0.0" - snapdragon "^0.8.1" - to-regex "^3.0.1" - -extsprintf@1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz#96918440e3041a7a414f8c52e3c574eb3c3e1e05" - integrity sha1-lpGEQOMEGnpBT4xS48V06zw+HgU= - -extsprintf@^1.2.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.4.0.tgz#e2689f8f356fad62cca65a3a91c5df5f9551692f" - integrity sha1-4mifjzVvrWLMplo6kcXfX5VRaS8= - -fancy-log@^1.3.2: - version "1.3.3" - resolved "https://registry.yarnpkg.com/fancy-log/-/fancy-log-1.3.3.tgz#dbc19154f558690150a23953a0adbd035be45fc7" - integrity sha512-k9oEhlyc0FrVh25qYuSELjr8oxsCoc4/LEZfg2iJJrfEk/tZL9bCoJE47gqAvI2m/AUjluCS4+3I0eTx8n3AEw== - dependencies: - ansi-gray "^0.1.1" - color-support "^1.1.3" - parse-node-version "^1.0.0" - time-stamp "^1.0.0" - -fast-deep-equal@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-1.1.0.tgz#c053477817c86b51daa853c81e059b733d023614" - integrity sha1-wFNHeBfIa1HaqFPIHgWbcz0CNhQ= - -fast-deep-equal@^3.1.1: - version "3.1.3" - resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" - integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== - -fast-json-stable-stringify@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz#874bf69c6f404c2b5d99c481341399fd55892633" - integrity sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw== - -fast-levenshtein@^1.0.0: - version "1.1.4" - resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-1.1.4.tgz#e6a754cc8f15e58987aa9cbd27af66fd6f4e5af9" - integrity sha1-5qdUzI8V5YmHqpy9J69m/W9OWvk= - -fast-levenshtein@~2.0.6: - version "2.0.6" - resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" - integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc= - -figures@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/figures/-/figures-2.0.0.tgz#3ab1a2d2a62c8bfb431a0c94cb797a2fce27c962" - integrity sha1-OrGi0qYsi/tDGgyUy3l6L84nyWI= - dependencies: - escape-string-regexp "^1.0.5" - -figures@^3.0.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/figures/-/figures-3.2.0.tgz#625c18bd293c604dc4a8ddb2febf0c88341746af" - integrity sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg== - dependencies: - escape-string-regexp "^1.0.5" - -file-entry-cache@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-2.0.0.tgz#c392990c3e684783d838b8c84a45d8a048458361" - integrity sha1-w5KZDD5oR4PYOLjISkXYoEhFg2E= - dependencies: - flat-cache "^1.2.1" - object-assign "^4.0.1" - -file-entry-cache@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-5.0.1.tgz#ca0f6efa6dd3d561333fb14515065c2fafdf439c" - integrity sha512-bCg29ictuBaKUwwArK4ouCaqDgLZcysCFLmM/Yn/FDoqndh/9vNuQfXRDvTuXKLxfD/JtZQGKFT8MGcJBK644g== - dependencies: - flat-cache "^2.0.1" - -file-uri-to-path@1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz#553a7b8446ff6f684359c445f1e37a05dacc33dd" - integrity sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw== - -fill-range@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-4.0.0.tgz#d544811d428f98eb06a63dc402d2403c328c38f7" - integrity sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc= - dependencies: - extend-shallow "^2.0.1" - is-number "^3.0.0" - repeat-string "^1.6.1" - to-regex-range "^2.1.0" - -find-cache-dir@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/find-cache-dir/-/find-cache-dir-2.1.0.tgz#8d0f94cd13fe43c6c7c261a0d86115ca918c05f7" - integrity sha512-Tq6PixE0w/VMFfCgbONnkiQIVol/JJL7nRMi20fqzA4NRs9AfeqMGeRdPi3wIhYkxjeBaWh2rxwapn5Tu3IqOQ== - dependencies: - commondir "^1.0.1" - make-dir "^2.0.0" - pkg-dir "^3.0.0" - -find-up@^1.0.0: - version "1.1.2" - resolved "https://registry.yarnpkg.com/find-up/-/find-up-1.1.2.tgz#6b2e9822b1a2ce0a60ab64d610eccad53cb24d0f" - integrity sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8= - dependencies: - path-exists "^2.0.0" - pinkie-promise "^2.0.0" - -find-up@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/find-up/-/find-up-3.0.0.tgz#49169f1d7993430646da61ecc5ae355c21c97b73" - integrity sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg== - dependencies: - locate-path "^3.0.0" - -findup-sync@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/findup-sync/-/findup-sync-2.0.0.tgz#9326b1488c22d1a6088650a86901b2d9a90a2cbc" - integrity sha1-kyaxSIwi0aYIhlCoaQGy2akKLLw= - dependencies: - detect-file "^1.0.0" - is-glob "^3.1.0" - micromatch "^3.0.4" - resolve-dir "^1.0.1" - -findup-sync@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/findup-sync/-/findup-sync-3.0.0.tgz#17b108f9ee512dfb7a5c7f3c8b27ea9e1a9c08d1" - integrity sha512-YbffarhcicEhOrm4CtrwdKBdCuz576RLdhJDsIfvNtxUuhdRet1qZcsMjqbePtAseKdAnDyM/IyXbu7PRPRLYg== - dependencies: - detect-file "^1.0.0" - is-glob "^4.0.0" - micromatch "^3.0.4" - resolve-dir "^1.0.1" - -fined@^1.0.1: - version "1.2.0" - resolved "https://registry.yarnpkg.com/fined/-/fined-1.2.0.tgz#d00beccf1aa2b475d16d423b0238b713a2c4a37b" - integrity sha512-ZYDqPLGxDkDhDZBjZBb+oD1+j0rA4E0pXY50eplAAOPg2N/gUBSSk5IM1/QhPfyVo19lJ+CvXpqfvk+b2p/8Ng== - dependencies: - expand-tilde "^2.0.2" - is-plain-object "^2.0.3" - object.defaults "^1.1.0" - object.pick "^1.2.0" - parse-filepath "^1.0.1" - -flagged-respawn@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/flagged-respawn/-/flagged-respawn-1.0.1.tgz#e7de6f1279ddd9ca9aac8a5971d618606b3aab41" - integrity sha512-lNaHNVymajmk0OJMBn8fVUAU1BtDeKIqKoVhk4xAALB57aALg6b4W0MfJ/cUE0g9YBXy5XhSlPIpYIJ7HaY/3Q== - -flat-cache@^1.2.1: - version "1.3.4" - resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-1.3.4.tgz#2c2ef77525cc2929007dfffa1dd314aa9c9dee6f" - integrity sha512-VwyB3Lkgacfik2vhqR4uv2rvebqmDvFu4jlN/C1RzWoJEo8I7z4Q404oiqYCkq41mni8EzQnm95emU9seckwtg== - dependencies: - circular-json "^0.3.1" - graceful-fs "^4.1.2" - rimraf "~2.6.2" - write "^0.2.1" - -flat-cache@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-2.0.1.tgz#5d296d6f04bda44a4630a301413bdbc2ec085ec0" - integrity sha512-LoQe6yDuUMDzQAEH8sgmh4Md6oZnc/7PjtwjNFSzveXqSHt6ka9fPBuso7IGf9Rz4uqnSnWiFH2B/zj24a5ReA== - dependencies: - flatted "^2.0.0" - rimraf "2.6.3" - write "1.0.3" - -flatted@^2.0.0: - version "2.0.2" - resolved "https://registry.yarnpkg.com/flatted/-/flatted-2.0.2.tgz#4575b21e2bcee7434aa9be662f4b7b5f9c2b5138" - integrity sha512-r5wGx7YeOwNWNlCA0wQ86zKyDLMQr+/RB8xy74M4hTphfmjlijTSSXGuH8rnvKZnfT9i+75zmd8jcKdMR4O6jA== - -flush-write-stream@^1.0.2: - version "1.1.1" - resolved "https://registry.yarnpkg.com/flush-write-stream/-/flush-write-stream-1.1.1.tgz#8dd7d873a1babc207d94ead0c2e0e44276ebf2e8" - integrity sha512-3Z4XhFZ3992uIq0XOqb9AreonueSYphE6oYbpt5+3u06JWklbsPkNv3ZKkP9Bz/r+1MWCaMoSQ28P85+1Yc77w== - dependencies: - inherits "^2.0.3" - readable-stream "^2.3.6" - -for-in@^1.0.1, for-in@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80" - integrity sha1-gQaNKVqBQuwKxybG4iAMMPttXoA= - -for-own@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/for-own/-/for-own-1.0.0.tgz#c63332f415cedc4b04dbfe70cf836494c53cb44b" - integrity sha1-xjMy9BXO3EsE2/5wz4NklMU8tEs= - dependencies: - for-in "^1.0.1" - -forever-agent@~0.6.1: - version "0.6.1" - resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" - integrity sha1-+8cfDEGt6zf5bFd60e1C2P2sypE= - -form-data@~2.3.2: - version "2.3.3" - resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.3.tgz#dcce52c05f644f298c6a7ab936bd724ceffbf3a6" - integrity sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ== - dependencies: - asynckit "^0.4.0" - combined-stream "^1.0.6" - mime-types "^2.1.12" - -fragment-cache@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/fragment-cache/-/fragment-cache-0.2.1.tgz#4290fad27f13e89be7f33799c6bc5a0abfff0d19" - integrity sha1-QpD60n8T6Jvn8zeZxrxaCr//DRk= - dependencies: - map-cache "^0.2.2" - -fs-mkdirp-stream@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/fs-mkdirp-stream/-/fs-mkdirp-stream-1.0.0.tgz#0b7815fc3201c6a69e14db98ce098c16935259eb" - integrity sha1-C3gV/DIBxqaeFNuYzgmMFpNSWes= - dependencies: - graceful-fs "^4.1.11" - through2 "^2.0.3" - -fs.realpath@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" - integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= - -fsevents@^1.2.7: - version "1.2.13" - resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.2.13.tgz#f325cb0455592428bcf11b383370ef70e3bfcc38" - integrity sha512-oWb1Z6mkHIskLzEJ/XWX0srkpkTQ7vaopMQkyaEIoq0fmtFVxOthb8cCxeT+p3ynTdkk/RZwbgG4brR5BeWECw== - dependencies: - bindings "^1.5.0" - nan "^2.12.1" - -function-bind@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" - integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== - -functional-red-black-tree@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" - integrity sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc= - -gensync@^1.0.0-beta.2: - version "1.0.0-beta.2" - resolved "https://registry.yarnpkg.com/gensync/-/gensync-1.0.0-beta.2.tgz#32a6ee76c3d7f52d46b2b1ae5d93fea8580a25e0" - integrity sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg== - -get-caller-file@^1.0.1: - version "1.0.3" - resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.3.tgz#f978fa4c90d1dfe7ff2d6beda2a515e713bdcf4a" - integrity sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w== - -get-intrinsic@^1.0.2: - version "1.1.1" - resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.1.1.tgz#15f59f376f855c446963948f0d24cd3637b4abc6" - integrity sha512-kWZrnVM42QCiEA2Ig1bG8zjoIMOgxWwYCEeNdwY6Tv/cOSeGpcoX4pXHfKUxNKVoArnrEr2e9srnAxxGIraS9Q== - dependencies: - function-bind "^1.1.1" - has "^1.0.3" - has-symbols "^1.0.1" - -get-stream@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-3.0.0.tgz#8e943d1358dc37555054ecbe2edb05aa174ede14" - integrity sha1-jpQ9E1jcN1VQVOy+LtsFqhdO3hQ= - -get-value@^2.0.3, get-value@^2.0.6: - version "2.0.6" - resolved "https://registry.yarnpkg.com/get-value/-/get-value-2.0.6.tgz#dc15ca1c672387ca76bd37ac0a395ba2042a2c28" - integrity sha1-3BXKHGcjh8p2vTesCjlbogQqLCg= - -getpass@^0.1.1: - version "0.1.7" - resolved "https://registry.yarnpkg.com/getpass/-/getpass-0.1.7.tgz#5eff8e3e684d569ae4cb2b1282604e8ba62149fa" - integrity sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo= - dependencies: - assert-plus "^1.0.0" - -glob-parent@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-3.1.0.tgz#9e6af6299d8d3bd2bd40430832bd113df906c5ae" - integrity sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4= - dependencies: - is-glob "^3.1.0" - path-dirname "^1.0.0" - -glob-parent@^5.0.0: - version "5.1.2" - resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.2.tgz#869832c58034fe68a4093c17dc15e8340d8401c4" - integrity sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow== - dependencies: - is-glob "^4.0.1" - -glob-stream@^6.1.0: - version "6.1.0" - resolved "https://registry.yarnpkg.com/glob-stream/-/glob-stream-6.1.0.tgz#7045c99413b3eb94888d83ab46d0b404cc7bdde4" - integrity sha1-cEXJlBOz65SIjYOrRtC0BMx73eQ= - dependencies: - extend "^3.0.0" - glob "^7.1.1" - glob-parent "^3.1.0" - is-negated-glob "^1.0.0" - ordered-read-streams "^1.0.0" - pumpify "^1.3.5" - readable-stream "^2.1.5" - remove-trailing-separator "^1.0.1" - to-absolute-glob "^2.0.0" - unique-stream "^2.0.2" - -glob-watcher@^5.0.3: - version "5.0.5" - resolved "https://registry.yarnpkg.com/glob-watcher/-/glob-watcher-5.0.5.tgz#aa6bce648332924d9a8489be41e3e5c52d4186dc" - integrity sha512-zOZgGGEHPklZNjZQaZ9f41i7F2YwE+tS5ZHrDhbBCk3stwahn5vQxnFmBJZHoYdusR6R1bLSXeGUy/BhctwKzw== - dependencies: - anymatch "^2.0.0" - async-done "^1.2.0" - chokidar "^2.0.0" - is-negated-glob "^1.0.0" - just-debounce "^1.0.0" - normalize-path "^3.0.0" - object.defaults "^1.1.0" - -glob@7.1.2: - version "7.1.2" - resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15" - integrity sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ== - dependencies: - fs.realpath "^1.0.0" - inflight "^1.0.4" - inherits "2" - minimatch "^3.0.4" - once "^1.3.0" - path-is-absolute "^1.0.0" - -glob@^5.0.15: - version "5.0.15" - resolved "https://registry.yarnpkg.com/glob/-/glob-5.0.15.tgz#1bc936b9e02f4a603fcc222ecf7633d30b8b93b1" - integrity sha1-G8k2ueAvSmA/zCIuz3Yz0wuLk7E= - dependencies: - inflight "^1.0.4" - inherits "2" - minimatch "2 || 3" - once "^1.3.0" - path-is-absolute "^1.0.0" - -glob@^7.1.1, glob@^7.1.2, glob@^7.1.3: - version "7.1.6" - resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.6.tgz#141f33b81a7c2492e125594307480c46679278a6" - integrity sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA== - dependencies: - fs.realpath "^1.0.0" - inflight "^1.0.4" - inherits "2" - minimatch "^3.0.4" - once "^1.3.0" - path-is-absolute "^1.0.0" - -global-modules@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/global-modules/-/global-modules-1.0.0.tgz#6d770f0eb523ac78164d72b5e71a8877265cc3ea" - integrity sha512-sKzpEkf11GpOFuw0Zzjzmt4B4UZwjOcG757PPvrfhxcLFbq0wpsgpOqxpxtxFiCG4DtG93M6XRVbF2oGdev7bg== - dependencies: - global-prefix "^1.0.1" - is-windows "^1.0.1" - resolve-dir "^1.0.0" - -global-prefix@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/global-prefix/-/global-prefix-1.0.2.tgz#dbf743c6c14992593c655568cb66ed32c0122ebe" - integrity sha1-2/dDxsFJklk8ZVVoy2btMsASLr4= - dependencies: - expand-tilde "^2.0.2" - homedir-polyfill "^1.0.1" - ini "^1.3.4" - is-windows "^1.0.1" - which "^1.2.14" - -globals@^11.0.1, globals@^11.1.0: - version "11.12.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" - integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== - -globals@^12.1.0: - version "12.4.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-12.4.0.tgz#a18813576a41b00a24a97e7f815918c2e19925f8" - integrity sha512-BWICuzzDvDoH54NHKCseDanAhE3CeDorgDL5MT6LMXXj2WCnd9UC2szdk4AWLfjdgNBCXLUanXYcpBBKOSWGwg== - dependencies: - type-fest "^0.8.1" - -glogg@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/glogg/-/glogg-1.0.2.tgz#2d7dd702beda22eb3bffadf880696da6d846313f" - integrity sha512-5mwUoSuBk44Y4EshyiqcH95ZntbDdTQqA3QYSrxmzj28Ai0vXBGMH1ApSANH14j2sIRtqCEyg6PfsuP7ElOEDA== - dependencies: - sparkles "^1.0.0" - -graceful-fs@^4.0.0, graceful-fs@^4.1.11, graceful-fs@^4.1.2, graceful-fs@^4.1.6: - version "4.2.6" - resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.6.tgz#ff040b2b0853b23c3d31027523706f1885d76bee" - integrity sha512-nTnJ528pbqxYanhpDYsi4Rd8MAeaBA67+RZ10CM1m3bTAVFEDcd5AuA4a6W5YkGZ1iNXHzZz8T6TBKLeBuNriQ== - -growl@1.10.5: - version "1.10.5" - resolved "https://registry.yarnpkg.com/growl/-/growl-1.10.5.tgz#f2735dc2283674fa67478b10181059355c369e5e" - integrity sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA== - -gulp-babel@^8.0.0: - version "8.0.0" - resolved "https://registry.yarnpkg.com/gulp-babel/-/gulp-babel-8.0.0.tgz#e0da96f4f2ec4a88dd3a3030f476e38ab2126d87" - integrity sha512-oomaIqDXxFkg7lbpBou/gnUkX51/Y/M2ZfSjL2hdqXTAlSWZcgZtd2o0cOH0r/eE8LWD0+Q/PsLsr2DKOoqToQ== - dependencies: - plugin-error "^1.0.1" - replace-ext "^1.0.0" - through2 "^2.0.0" - vinyl-sourcemaps-apply "^0.2.0" - -gulp-cli@^2.2.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/gulp-cli/-/gulp-cli-2.3.0.tgz#ec0d380e29e52aa45e47977f0d32e18fd161122f" - integrity sha512-zzGBl5fHo0EKSXsHzjspp3y5CONegCm8ErO5Qh0UzFzk2y4tMvzLWhoDokADbarfZRL2pGpRp7yt6gfJX4ph7A== - dependencies: - ansi-colors "^1.0.1" - archy "^1.0.0" - array-sort "^1.0.0" - color-support "^1.1.3" - concat-stream "^1.6.0" - copy-props "^2.0.1" - fancy-log "^1.3.2" - gulplog "^1.0.0" - interpret "^1.4.0" - isobject "^3.0.1" - liftoff "^3.1.0" - matchdep "^2.0.0" - mute-stdout "^1.0.0" - pretty-hrtime "^1.0.0" - replace-homedir "^1.0.0" - semver-greatest-satisfied-range "^1.1.0" - v8flags "^3.2.0" - yargs "^7.1.0" - -gulp-eslint@4.0.2: - version "4.0.2" - resolved "https://registry.yarnpkg.com/gulp-eslint/-/gulp-eslint-4.0.2.tgz#18a2a6768e4404cbf3e203239cb57474168fa606" - integrity sha512-fcFUQzFsN6dJ6KZlG+qPOEkqfcevRUXgztkYCvhNvJeSvOicC8ucutN4qR/ID8LmNZx9YPIkBzazTNnVvbh8wg== - dependencies: - eslint "^4.0.0" - fancy-log "^1.3.2" - plugin-error "^1.0.0" - -gulp-exclude-gitignore@^1.0.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/gulp-exclude-gitignore/-/gulp-exclude-gitignore-1.2.0.tgz#341aeb62faab428af5550da9359ceff99388f1d0" - integrity sha512-J3LCmz9C1UU1pxf5Npx6SNc5o9YQptyc9IHaqLiBlihZmg44jaaTplWUZ0JPQkMdOTae0YgEDvT9TKlUWDSMUA== - dependencies: - gulp-ignore "^2.0.2" - -gulp-ignore@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/gulp-ignore/-/gulp-ignore-2.0.2.tgz#5c2ea2a0a4402e0ab4a2bcd12efd9295344d78f2" - integrity sha1-XC6ioKRALgq0orzRLv2SlTRNePI= - dependencies: - gulp-match "^1.0.3" - through2 "^2.0.1" - -gulp-istanbul@^1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/gulp-istanbul/-/gulp-istanbul-1.1.3.tgz#669a21516adb2540de798be26faee843ade8f20f" - integrity sha512-uMLSdqPDnBAV/B9rNyOgVMgrVC1tPbe+5GH6P13UOyxbRDT/w4sKYHWftPMA8j9om+NFvfeRlqpDXL2fixFWNA== - dependencies: - istanbul "^0.4.0" - istanbul-threshold-checker "^0.2.1" - lodash "^4.0.0" - plugin-error "^0.1.2" - through2 "^2.0.0" - vinyl-sourcemaps-apply "^0.2.1" - -gulp-match@^1.0.3: - version "1.1.0" - resolved "https://registry.yarnpkg.com/gulp-match/-/gulp-match-1.1.0.tgz#552b7080fc006ee752c90563f9fec9d61aafdf4f" - integrity sha512-DlyVxa1Gj24DitY2OjEsS+X6tDpretuxD6wTfhXE/Rw2hweqc1f6D/XtsJmoiCwLWfXgR87W9ozEityPCVzGtQ== - dependencies: - minimatch "^3.0.3" - -gulp-mocha@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/gulp-mocha/-/gulp-mocha-6.0.0.tgz#80f32bc705ce30747f355ddb8ccd96a1c73bef13" - integrity sha512-FfBldW5ttnDpKf4Sg6/BLOOKCCbr5mbixDGK1t02/8oSrTCwNhgN/mdszG3cuQuYNzuouUdw4EH/mlYtgUscPg== - dependencies: - dargs "^5.1.0" - execa "^0.10.0" - mocha "^5.2.0" - npm-run-path "^2.0.2" - plugin-error "^1.0.1" - supports-color "^5.4.0" - through2 "^2.0.3" - -gulp-plumber@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/gulp-plumber/-/gulp-plumber-1.2.1.tgz#d38700755a300b9d372318e4ffb5ff7ced0b2c84" - integrity sha512-mctAi9msEAG7XzW5ytDVZ9PxWMzzi1pS2rBH7lA095DhMa6KEXjm+St0GOCc567pJKJ/oCvosVAZEpAey0q2eQ== - dependencies: - chalk "^1.1.3" - fancy-log "^1.3.2" - plugin-error "^0.1.2" - through2 "^2.0.3" - -gulp@^4.0.2: - version "4.0.2" - resolved "https://registry.yarnpkg.com/gulp/-/gulp-4.0.2.tgz#543651070fd0f6ab0a0650c6a3e6ff5a7cb09caa" - integrity sha512-dvEs27SCZt2ibF29xYgmnwwCYZxdxhQ/+LFWlbAW8y7jt68L/65402Lz3+CKy0Ov4rOs+NERmDq7YlZaDqUIfA== - dependencies: - glob-watcher "^5.0.3" - gulp-cli "^2.2.0" - undertaker "^1.2.1" - vinyl-fs "^3.0.0" - -gulplog@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/gulplog/-/gulplog-1.0.0.tgz#e28c4d45d05ecbbed818363ce8f9c5926229ffe5" - integrity sha1-4oxNRdBey77YGDY86PnFkmIp/+U= - dependencies: - glogg "^1.0.0" - -handlebars@^4.0.1: - version "4.7.7" - resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.7.7.tgz#9ce33416aad02dbd6c8fafa8240d5d98004945a1" - integrity sha512-aAcXm5OAfE/8IXkcZvCepKU3VzW1/39Fb5ZuqMtgI/hT8X2YgoMvBY5dLhq/cpOvw7Lk1nK/UF71aLG/ZnVYRA== - dependencies: - minimist "^1.2.5" - neo-async "^2.6.0" - source-map "^0.6.1" - wordwrap "^1.0.0" - optionalDependencies: - uglify-js "^3.1.4" - -har-schema@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" - integrity sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI= - -har-validator@~5.1.3: - version "5.1.5" - resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.1.5.tgz#1f0803b9f8cb20c0fa13822df1ecddb36bde1efd" - integrity sha512-nmT2T0lljbxdQZfspsno9hgrG3Uir6Ks5afism62poxqBM6sDnMEuPmzTq8XN0OEwqKLLdh1jQI3qyE66Nzb3w== - dependencies: - ajv "^6.12.3" - har-schema "^2.0.0" - -has-ansi@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/has-ansi/-/has-ansi-2.0.0.tgz#34f5049ce1ecdf2b0649af3ef24e45ed35416d91" - integrity sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE= - dependencies: - ansi-regex "^2.0.0" - -has-flag@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-1.0.0.tgz#9d9e793165ce017a00f00418c43f942a7b1d11fa" - integrity sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo= - -has-flag@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" - integrity sha1-tdRU3CGZriJWmfNGfloH87lVuv0= - -has-flag@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" - integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== - -has-symbols@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.2.tgz#165d3070c00309752a1236a479331e3ac56f1423" - integrity sha512-chXa79rL/UC2KlX17jo3vRGz0azaWEx5tGqZg5pO3NUyEJVB17dMruQlzCCOfUvElghKcm5194+BCRvi2Rv/Gw== - -has-value@^0.3.1: - version "0.3.1" - resolved "https://registry.yarnpkg.com/has-value/-/has-value-0.3.1.tgz#7b1f58bada62ca827ec0a2078025654845995e1f" - integrity sha1-ex9YutpiyoJ+wKIHgCVlSEWZXh8= - dependencies: - get-value "^2.0.3" - has-values "^0.1.4" - isobject "^2.0.0" - -has-value@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/has-value/-/has-value-1.0.0.tgz#18b281da585b1c5c51def24c930ed29a0be6b177" - integrity sha1-GLKB2lhbHFxR3vJMkw7SmgvmsXc= - dependencies: - get-value "^2.0.6" - has-values "^1.0.0" - isobject "^3.0.0" - -has-values@^0.1.4: - version "0.1.4" - resolved "https://registry.yarnpkg.com/has-values/-/has-values-0.1.4.tgz#6d61de95d91dfca9b9a02089ad384bff8f62b771" - integrity sha1-bWHeldkd/Km5oCCJrThL/49it3E= - -has-values@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/has-values/-/has-values-1.0.0.tgz#95b0b63fec2146619a6fe57fe75628d5a39efe4f" - integrity sha1-lbC2P+whRmGab+V/51Yo1aOe/k8= - dependencies: - is-number "^3.0.0" - kind-of "^4.0.0" - -has@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" - integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== - dependencies: - function-bind "^1.1.1" - -he@1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/he/-/he-1.1.1.tgz#93410fd21b009735151f8868c2f271f3427e23fd" - integrity sha1-k0EP0hsAlzUVH4howvJx80J+I/0= - -homedir-polyfill@^1.0.1: - version "1.0.3" - resolved "https://registry.yarnpkg.com/homedir-polyfill/-/homedir-polyfill-1.0.3.tgz#743298cef4e5af3e194161fbadcc2151d3a058e8" - integrity sha512-eSmmWE5bZTK2Nou4g0AI3zZ9rswp7GRKoKXS1BLUkvPviOqs4YTN1djQIqrXy9k5gEtdLPy86JjRwsNM9tnDcA== - dependencies: - parse-passwd "^1.0.0" - -hosted-git-info@^2.1.4: - version "2.8.9" - resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.8.9.tgz#dffc0bf9a21c02209090f2aa69429e1414daf3f9" - integrity sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw== - -htmlencode@^0.0.4: - version "0.0.4" - resolved "https://registry.yarnpkg.com/htmlencode/-/htmlencode-0.0.4.tgz#f7e2d6afbe18a87a78e63ba3308e753766740e3f" - integrity sha1-9+LWr74YqHp45jujMI51N2Z0Dj8= - -http-signature@~1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/http-signature/-/http-signature-1.2.0.tgz#9aecd925114772f3d95b65a60abb8f7c18fbace1" - integrity sha1-muzZJRFHcvPZW2WmCruPfBj7rOE= - dependencies: - assert-plus "^1.0.0" - jsprim "^1.2.2" - sshpk "^1.7.0" - -iconv-lite@^0.4.17, iconv-lite@^0.4.24: - version "0.4.24" - resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" - integrity sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA== - dependencies: - safer-buffer ">= 2.1.2 < 3" - -ignore@^3.3.3: - version "3.3.10" - resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.10.tgz#0a97fb876986e8081c631160f8f9f389157f0043" - integrity sha512-Pgs951kaMm5GXP7MOvxERINe3gsaVjUWFm+UZPSq9xYriQAksyhg0csnS0KXSNRD5NmNdapXEpjxG49+AKh/ug== - -ignore@^4.0.6: - version "4.0.6" - resolved "https://registry.yarnpkg.com/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc" - integrity sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg== - -import-fresh@^3.0.0: - version "3.3.0" - resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.3.0.tgz#37162c25fcb9ebaa2e6e53d5b4d88ce17d9e0c2b" - integrity sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw== - dependencies: - parent-module "^1.0.0" - resolve-from "^4.0.0" - -imurmurhash@^0.1.4: - version "0.1.4" - resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" - integrity sha1-khi5srkoojixPcT7a21XbyMUU+o= - -inflight@^1.0.4: - version "1.0.6" - resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" - integrity sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk= - dependencies: - once "^1.3.0" - wrappy "1" - -inherits@2, inherits@^2.0.1, inherits@^2.0.3, inherits@~2.0.3: - version "2.0.4" - resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" - integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== - -ini@^1.3.4: - version "1.3.8" - resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.8.tgz#a29da425b48806f34767a4efce397269af28432c" - integrity sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew== - -inquirer@^3.0.6: - version "3.3.0" - resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-3.3.0.tgz#9dd2f2ad765dcab1ff0443b491442a20ba227dc9" - integrity sha512-h+xtnyk4EwKvFWHrUYsWErEVR+igKtLdchu+o0Z1RL7VU/jVMFbYir2bp6bAj8efFNxWqHX0dIss6fJQ+/+qeQ== - dependencies: - ansi-escapes "^3.0.0" - chalk "^2.0.0" - cli-cursor "^2.1.0" - cli-width "^2.0.0" - external-editor "^2.0.4" - figures "^2.0.0" - lodash "^4.3.0" - mute-stream "0.0.7" - run-async "^2.2.0" - rx-lite "^4.0.8" - rx-lite-aggregates "^4.0.8" - string-width "^2.1.0" - strip-ansi "^4.0.0" - through "^2.3.6" - -inquirer@^7.0.0: - version "7.3.3" - resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-7.3.3.tgz#04d176b2af04afc157a83fd7c100e98ee0aad003" - integrity sha512-JG3eIAj5V9CwcGvuOmoo6LB9kbAYT8HXffUl6memuszlwDC/qvFAJw49XJ5NROSFNPxp3iQg1GqkFhaY/CR0IA== - dependencies: - ansi-escapes "^4.2.1" - chalk "^4.1.0" - cli-cursor "^3.1.0" - cli-width "^3.0.0" - external-editor "^3.0.3" - figures "^3.0.0" - lodash "^4.17.19" - mute-stream "0.0.8" - run-async "^2.4.0" - rxjs "^6.6.0" - string-width "^4.1.0" - strip-ansi "^6.0.0" - through "^2.3.6" - -interpret@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.4.0.tgz#665ab8bc4da27a774a40584e812e3e0fa45b1a1e" - integrity sha512-agE4QfB2Lkp9uICn7BAqoscw4SZP9kTE2hxiFI3jBPmXJfdqiahTbUuKGsMoN2GtqL9AxhYioAcVvgsb1HvRbA== - -invert-kv@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-1.0.0.tgz#104a8e4aaca6d3d8cd157a8ef8bfab2d7a3ffdb6" - integrity sha1-EEqOSqym09jNFXqO+L+rLXo//bY= - -is-absolute@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-absolute/-/is-absolute-1.0.0.tgz#395e1ae84b11f26ad1795e73c17378e48a301576" - integrity sha512-dOWoqflvcydARa360Gvv18DZ/gRuHKi2NU/wU5X1ZFzdYfH29nkiNZsF3mp4OJ3H4yo9Mx8A/uAGNzpzPN3yBA== - dependencies: - is-relative "^1.0.0" - is-windows "^1.0.1" - -is-accessor-descriptor@^0.1.6: - version "0.1.6" - resolved "https://registry.yarnpkg.com/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz#a9e12cb3ae8d876727eeef3843f8a0897b5c98d6" - integrity sha1-qeEss66Nh2cn7u84Q/igiXtcmNY= - dependencies: - kind-of "^3.0.2" - -is-accessor-descriptor@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz#169c2f6d3df1f992618072365c9b0ea1f6878656" - integrity sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ== - dependencies: - kind-of "^6.0.0" - -is-arrayish@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" - integrity sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0= - -is-binary-path@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/is-binary-path/-/is-binary-path-1.0.1.tgz#75f16642b480f187a711c814161fd3a4a7655898" - integrity sha1-dfFmQrSA8YenEcgUFh/TpKdlWJg= - dependencies: - binary-extensions "^1.0.0" - -is-buffer@^1.1.5: - version "1.1.6" - resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.6.tgz#efaa2ea9daa0d7ab2ea13a97b2b8ad51fefbe8be" - integrity sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w== - -is-core-module@^2.2.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.3.0.tgz#d341652e3408bca69c4671b79a0954a3d349f887" - integrity sha512-xSphU2KG9867tsYdLD4RWQ1VqdFl4HTO9Thf3I/3dLEfr0dbPTWKsuCKrgqMljg4nPE+Gq0VCnzT3gr0CyBmsw== - dependencies: - has "^1.0.3" - -is-data-descriptor@^0.1.4: - version "0.1.4" - resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz#0b5ee648388e2c860282e793f1856fec3f301b56" - integrity sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y= - dependencies: - kind-of "^3.0.2" - -is-data-descriptor@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz#d84876321d0e7add03990406abbbbd36ba9268c7" - integrity sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ== - dependencies: - kind-of "^6.0.0" - -is-descriptor@^0.1.0: - version "0.1.6" - resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-0.1.6.tgz#366d8240dde487ca51823b1ab9f07a10a78251ca" - integrity sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg== - dependencies: - is-accessor-descriptor "^0.1.6" - is-data-descriptor "^0.1.4" - kind-of "^5.0.0" - -is-descriptor@^1.0.0, is-descriptor@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-1.0.2.tgz#3b159746a66604b04f8c81524ba365c5f14d86ec" - integrity sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg== - dependencies: - is-accessor-descriptor "^1.0.0" - is-data-descriptor "^1.0.0" - kind-of "^6.0.2" - -is-extendable@^0.1.0, is-extendable@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/is-extendable/-/is-extendable-0.1.1.tgz#62b110e289a471418e3ec36a617d472e301dfc89" - integrity sha1-YrEQ4omkcUGOPsNqYX1HLjAd/Ik= - -is-extendable@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/is-extendable/-/is-extendable-1.0.1.tgz#a7470f9e426733d81bd81e1155264e3a3507cab4" - integrity sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA== - dependencies: - is-plain-object "^2.0.4" - -is-extglob@^2.1.0, is-extglob@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" - integrity sha1-qIwCU1eR8C7TfHahueqXc8gz+MI= - -is-fullwidth-code-point@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz#ef9e31386f031a7f0d643af82fde50c457ef00cb" - integrity sha1-754xOG8DGn8NZDr4L95QxFfvAMs= - dependencies: - number-is-nan "^1.0.0" - -is-fullwidth-code-point@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" - integrity sha1-o7MKXE8ZkYMWeqq5O+764937ZU8= - -is-fullwidth-code-point@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz#f116f8064fe90b3f7844a38997c0b75051269f1d" - integrity sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg== - -is-glob@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-3.1.0.tgz#7ba5ae24217804ac70707b96922567486cc3e84a" - integrity sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo= - dependencies: - is-extglob "^2.1.0" - -is-glob@^4.0.0, is-glob@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.1.tgz#7567dbe9f2f5e2467bc77ab83c4a29482407a5dc" - integrity sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg== - dependencies: - is-extglob "^2.1.1" - -is-negated-glob@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-negated-glob/-/is-negated-glob-1.0.0.tgz#6910bca5da8c95e784b5751b976cf5a10fee36d2" - integrity sha1-aRC8pdqMleeEtXUbl2z1oQ/uNtI= - -is-number@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/is-number/-/is-number-3.0.0.tgz#24fd6201a4782cf50561c810276afc7d12d71195" - integrity sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU= - dependencies: - kind-of "^3.0.2" - -is-number@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/is-number/-/is-number-4.0.0.tgz#0026e37f5454d73e356dfe6564699867c6a7f0ff" - integrity sha512-rSklcAIlf1OmFdyAqbnWTLVelsQ58uvZ66S/ZyawjWqIviTWCjg2PzVGw8WUA+nNuPTqb4wgA+NszrJ+08LlgQ== - -is-plain-object@^2.0.1, is-plain-object@^2.0.3, is-plain-object@^2.0.4: - version "2.0.4" - resolved "https://registry.yarnpkg.com/is-plain-object/-/is-plain-object-2.0.4.tgz#2c163b3fafb1b606d9d17928f05c2a1c38e07677" - integrity sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og== - dependencies: - isobject "^3.0.1" - -is-plain-object@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/is-plain-object/-/is-plain-object-5.0.0.tgz#4427f50ab3429e9025ea7d52e9043a9ef4159344" - integrity sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q== - -is-relative@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-relative/-/is-relative-1.0.0.tgz#a1bb6935ce8c5dba1e8b9754b9b2dcc020e2260d" - integrity sha512-Kw/ReK0iqwKeu0MITLFuj0jbPAmEiOsIwyIXvvbfa6QfmN9pkD1M+8pdk7Rl/dTKbH34/XBFMbgD4iMJhLQbGA== - dependencies: - is-unc-path "^1.0.0" - -is-resolvable@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/is-resolvable/-/is-resolvable-1.1.0.tgz#fb18f87ce1feb925169c9a407c19318a3206ed88" - integrity sha512-qgDYXFSR5WvEfuS5dMj6oTMEbrrSaM0CrFk2Yiq/gXnBvD9pMa2jGXxyhGLfvhZpuMZe18CJpFxAt3CRs42NMg== - -is-stream@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44" - integrity sha1-EtSj3U5o4Lec6428hBc66A2RykQ= - -is-typedarray@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" - integrity sha1-5HnICFjfDBsR3dppQPlgEfzaSpo= - -is-unc-path@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-unc-path/-/is-unc-path-1.0.0.tgz#d731e8898ed090a12c352ad2eaed5095ad322c9d" - integrity sha512-mrGpVd0fs7WWLfVsStvgF6iEJnbjDFZh9/emhRDcGWTduTfNHd9CHeUwH3gYIjdbwo4On6hunkztwOaAw0yllQ== - dependencies: - unc-path-regex "^0.1.2" - -is-utf8@^0.2.0, is-utf8@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/is-utf8/-/is-utf8-0.2.1.tgz#4b0da1442104d1b336340e80797e865cf39f7d72" - integrity sha1-Sw2hRCEE0bM2NA6AeX6GXPOffXI= - -is-valid-glob@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-valid-glob/-/is-valid-glob-1.0.0.tgz#29bf3eff701be2d4d315dbacc39bc39fe8f601aa" - integrity sha1-Kb8+/3Ab4tTTFdusw5vDn+j2Aao= - -is-windows@^1.0.1, is-windows@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-windows/-/is-windows-1.0.2.tgz#d1850eb9791ecd18e6182ce12a30f396634bb19d" - integrity sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA== - -isarray@0.0.1: - version "0.0.1" - resolved "https://registry.yarnpkg.com/isarray/-/isarray-0.0.1.tgz#8a18acfca9a8f4177e09abfc6038939b05d1eedf" - integrity sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8= - -isarray@1.0.0, isarray@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" - integrity sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE= - -isexe@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" - integrity sha1-6PvzdNxVb/iUehDcsFctYz8s+hA= - -isobject@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/isobject/-/isobject-2.1.0.tgz#f065561096a3f1da2ef46272f815c840d87e0c89" - integrity sha1-8GVWEJaj8dou9GJy+BXIQNh+DIk= - dependencies: - isarray "1.0.0" - -isobject@^3.0.0, isobject@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/isobject/-/isobject-3.0.1.tgz#4e431e92b11a9731636aa1f9c8d1ccbcfdab78df" - integrity sha1-TkMekrEalzFjaqH5yNHMvP2reN8= - -isstream@~0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" - integrity sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo= - -istanbul-threshold-checker@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/istanbul-threshold-checker/-/istanbul-threshold-checker-0.2.1.tgz#c5dc94e8f2cc5cd3ffd335452f84b553c4248331" - integrity sha1-xdyU6PLMXNP/0zVFL4S1U8QkgzE= - dependencies: - istanbul "~0.4.5" - lodash "~4.17.2" - -istanbul@^0.4.0, istanbul@~0.4.5: - version "0.4.5" - resolved "https://registry.yarnpkg.com/istanbul/-/istanbul-0.4.5.tgz#65c7d73d4c4da84d4f3ac310b918fb0b8033733b" - integrity sha1-ZcfXPUxNqE1POsMQuRj7C4Azczs= - dependencies: - abbrev "1.0.x" - async "1.x" - escodegen "1.8.x" - esprima "2.7.x" - glob "^5.0.15" - handlebars "^4.0.1" - js-yaml "3.x" - mkdirp "0.5.x" - nopt "3.x" - once "1.x" - resolve "1.1.x" - supports-color "^3.1.0" - which "^1.1.1" - wordwrap "^1.0.0" - -js-tokens@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b" - integrity sha1-mGbfOVECEw449/mWvOtlRDIJwls= - -js-tokens@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" - integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== - -js-yaml@3.x, js-yaml@^3.13.1, js-yaml@^3.9.1: - version "3.14.1" - resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.14.1.tgz#dae812fdb3825fa306609a8717383c50c36a0537" - integrity sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g== - dependencies: - argparse "^1.0.7" - esprima "^4.0.0" - -jsbn@~0.1.0: - version "0.1.1" - resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513" - integrity sha1-peZUwuWi3rXyAdls77yoDA7y9RM= - -jsesc@^2.5.1: - version "2.5.2" - resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.2.tgz#80564d2e483dacf6e8ef209650a67df3f0c283a4" - integrity sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA== - -jsesc@~0.5.0: - version "0.5.0" - resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-0.5.0.tgz#e7dee66e35d6fc16f710fe91d5cf69f70f08911d" - integrity sha1-597mbjXW/Bb3EP6R1c9p9w8IkR0= - -json-schema-traverse@^0.3.0: - version "0.3.1" - resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz#349a6d44c53a51de89b40805c5d5e59b417d3340" - integrity sha1-NJptRMU6Ud6JtAgFxdXlm0F9M0A= - -json-schema-traverse@^0.4.1: - version "0.4.1" - resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" - integrity sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg== - -json-schema@0.2.3: - version "0.2.3" - resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" - integrity sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM= - -json-stable-stringify-without-jsonify@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" - integrity sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE= - -json-stringify-safe@^5.0.1, json-stringify-safe@~5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" - integrity sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus= - -json5@^2.1.2: - version "2.2.0" - resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.0.tgz#2dfefe720c6ba525d9ebd909950f0515316c89a3" - integrity sha512-f+8cldu7X/y7RAJurMEJmdoKXGB/X550w2Nr3tTbezL6RwEE/iMcm+tZnXeoZtKuOq6ft8+CqzEkrIgx1fPoQA== - dependencies: - minimist "^1.2.5" - -jsprim@^1.2.2: - version "1.4.1" - resolved "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.1.tgz#313e66bc1e5cc06e438bc1b7499c2e5c56acb6a2" - integrity sha1-MT5mvB5cwG5Di8G3SZwuXFastqI= - dependencies: - assert-plus "1.0.0" - extsprintf "1.3.0" - json-schema "0.2.3" - verror "1.10.0" - -just-debounce@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/just-debounce/-/just-debounce-1.1.0.tgz#2f81a3ad4121a76bc7cb45dbf704c0d76a8e5ddf" - integrity sha512-qpcRocdkUmf+UTNBYx5w6dexX5J31AKK1OmPwH630a83DdVVUIngk55RSAiIGpQyoH0dlr872VHfPjnQnK1qDQ== - -just-extend@^4.0.2: - version "4.2.1" - resolved "https://registry.yarnpkg.com/just-extend/-/just-extend-4.2.1.tgz#ef5e589afb61e5d66b24eca749409a8939a8c744" - integrity sha512-g3UB796vUFIY90VIv/WX3L2c8CS2MdWUww3CNrYmqza1Fg0DURc2K/O4YrnklBdQarSJ/y8JnJYDGc+1iumQjg== - -kind-of@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-1.1.0.tgz#140a3d2d41a36d2efcfa9377b62c24f8495a5c44" - integrity sha1-FAo9LUGjbS78+pN3tiwk+ElaXEQ= - -kind-of@^3.0.2, kind-of@^3.0.3, kind-of@^3.2.0: - version "3.2.2" - resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-3.2.2.tgz#31ea21a734bab9bbb0f32466d893aea51e4a3c64" - integrity sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ= - dependencies: - is-buffer "^1.1.5" - -kind-of@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-4.0.0.tgz#20813df3d712928b207378691a45066fae72dd57" - integrity sha1-IIE989cSkosgc3hpGkUGb65y3Vc= - dependencies: - is-buffer "^1.1.5" - -kind-of@^5.0.0, kind-of@^5.0.2: - version "5.1.0" - resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-5.1.0.tgz#729c91e2d857b7a419a1f9aa65685c4c33f5845d" - integrity sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw== - -kind-of@^6.0.0, kind-of@^6.0.2: - version "6.0.3" - resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.3.tgz#07c05034a6c349fa06e24fa35aa76db4580ce4dd" - integrity sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw== - -last-run@^1.1.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/last-run/-/last-run-1.1.1.tgz#45b96942c17b1c79c772198259ba943bebf8ca5b" - integrity sha1-RblpQsF7HHnHchmCWbqUO+v4yls= - dependencies: - default-resolution "^2.0.0" - es6-weak-map "^2.0.1" - -lazystream@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/lazystream/-/lazystream-1.0.0.tgz#f6995fe0f820392f61396be89462407bb77168e4" - integrity sha1-9plf4PggOS9hOWvolGJAe7dxaOQ= - dependencies: - readable-stream "^2.0.5" - -lcid@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/lcid/-/lcid-1.0.0.tgz#308accafa0bc483a3867b4b6f2b9506251d1b835" - integrity sha1-MIrMr6C8SDo4Z7S28rlQYlHRuDU= - dependencies: - invert-kv "^1.0.0" - -lead@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/lead/-/lead-1.0.0.tgz#6f14f99a37be3a9dd784f5495690e5903466ee42" - integrity sha1-bxT5mje+Op3XhPVJVpDlkDRm7kI= - dependencies: - flush-write-stream "^1.0.2" - -levn@^0.3.0, levn@~0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/levn/-/levn-0.3.0.tgz#3b09924edf9f083c0490fdd4c0bc4421e04764ee" - integrity sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4= - dependencies: - prelude-ls "~1.1.2" - type-check "~0.3.2" - -liftoff@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/liftoff/-/liftoff-3.1.0.tgz#c9ba6081f908670607ee79062d700df062c52ed3" - integrity sha512-DlIPlJUkCV0Ips2zf2pJP0unEoT1kwYhiiPUGF3s/jtxTCjziNLoiVVh+jqWOWeFi6mmwQ5fNxvAUyPad4Dfog== - dependencies: - extend "^3.0.0" - findup-sync "^3.0.0" - fined "^1.0.1" - flagged-respawn "^1.0.0" - is-plain-object "^2.0.4" - object.map "^1.0.0" - rechoir "^0.6.2" - resolve "^1.1.7" - -load-json-file@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-1.1.0.tgz#956905708d58b4bab4c2261b04f59f31c99374c0" - integrity sha1-lWkFcI1YtLq0wiYbBPWfMcmTdMA= - dependencies: - graceful-fs "^4.1.2" - parse-json "^2.2.0" - pify "^2.0.0" - pinkie-promise "^2.0.0" - strip-bom "^2.0.0" - -locate-path@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-3.0.0.tgz#dbec3b3ab759758071b58fe59fc41871af21400e" - integrity sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A== - dependencies: - p-locate "^3.0.0" - path-exists "^3.0.0" - -lodash.debounce@^4.0.8: - version "4.0.8" - resolved "https://registry.yarnpkg.com/lodash.debounce/-/lodash.debounce-4.0.8.tgz#82d79bff30a67c4005ffd5e2515300ad9ca4d7af" - integrity sha1-gteb/zCmfEAF/9XiUVMArZyk168= - -lodash.set@^4.3.2: - version "4.3.2" - resolved "https://registry.yarnpkg.com/lodash.set/-/lodash.set-4.3.2.tgz#d8757b1da807dde24816b0d6a84bea1a76230b23" - integrity sha1-2HV7HagH3eJIFrDWqEvqGnYjCyM= - -lodash@^4.0.0, lodash@^4.17.14, lodash@^4.17.15, lodash@^4.17.19, lodash@^4.17.4, lodash@^4.3.0, lodash@~4.17.2: - version "4.17.21" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" - integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== - -lolex@^4.2.0: - version "4.2.0" - resolved "https://registry.yarnpkg.com/lolex/-/lolex-4.2.0.tgz#ddbd7f6213ca1ea5826901ab1222b65d714b3cd7" - integrity sha512-gKO5uExCXvSm6zbF562EvM+rd1kQDnB9AZBbiQVzf1ZmdDpxUSvpnAaVOP83N/31mRK8Ml8/VE8DMvsAZQ+7wg== - -lolex@^5.0.1: - version "5.1.2" - resolved "https://registry.yarnpkg.com/lolex/-/lolex-5.1.2.tgz#953694d098ce7c07bc5ed6d0e42bc6c0c6d5a367" - integrity sha512-h4hmjAvHTmd+25JSwrtTIuwbKdwg5NzZVRMLn9saij4SZaepCrTCxPr35H/3bjwfMJtN+t3CX8672UIkglz28A== - dependencies: - "@sinonjs/commons" "^1.7.0" - -lru-cache@^4.0.1: - version "4.1.5" - resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.5.tgz#8bbe50ea85bed59bc9e33dcab8235ee9bcf443cd" - integrity sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g== - dependencies: - pseudomap "^1.0.2" - yallist "^2.1.2" - -make-dir@^2.0.0, make-dir@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-2.1.0.tgz#5f0310e18b8be898cc07009295a30ae41e91e6f5" - integrity sha512-LS9X+dc8KLxXCb8dni79fLIIUA5VyZoyjSMCwTluaXA0o27cCK0bhXkpgw+sTXVpPy/lSO57ilRixqk0vDmtRA== - dependencies: - pify "^4.0.1" - semver "^5.6.0" - -make-iterator@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/make-iterator/-/make-iterator-1.0.1.tgz#29b33f312aa8f547c4a5e490f56afcec99133ad6" - integrity sha512-pxiuXh0iVEq7VM7KMIhs5gxsfxCux2URptUQaXo4iZZJxBAzTPOLE2BumO5dbfVYq/hBJFBR/a1mFDmOx5AGmw== - dependencies: - kind-of "^6.0.2" - -map-cache@^0.2.0, map-cache@^0.2.2: - version "0.2.2" - resolved "https://registry.yarnpkg.com/map-cache/-/map-cache-0.2.2.tgz#c32abd0bd6525d9b051645bb4f26ac5dc98a0dbf" - integrity sha1-wyq9C9ZSXZsFFkW7TyasXcmKDb8= - -map-visit@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/map-visit/-/map-visit-1.0.0.tgz#ecdca8f13144e660f1b5bd41f12f3479d98dfb8f" - integrity sha1-7Nyo8TFE5mDxtb1B8S80edmN+48= - dependencies: - object-visit "^1.0.0" - -matchdep@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/matchdep/-/matchdep-2.0.0.tgz#c6f34834a0d8dbc3b37c27ee8bbcb27c7775582e" - integrity sha1-xvNINKDY28OzfCfui7yyfHd1WC4= - dependencies: - findup-sync "^2.0.0" - micromatch "^3.0.4" - resolve "^1.4.0" - stack-trace "0.0.10" - -micromatch@^3.0.4, micromatch@^3.1.10, micromatch@^3.1.4: - version "3.1.10" - resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-3.1.10.tgz#70859bc95c9840952f359a068a3fc49f9ecfac23" - integrity sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg== - dependencies: - arr-diff "^4.0.0" - array-unique "^0.3.2" - braces "^2.3.1" - define-property "^2.0.2" - extend-shallow "^3.0.2" - extglob "^2.0.4" - fragment-cache "^0.2.1" - kind-of "^6.0.2" - nanomatch "^1.2.9" - object.pick "^1.3.0" - regex-not "^1.0.0" - snapdragon "^0.8.1" - to-regex "^3.0.2" - -mime-db@1.47.0: - version "1.47.0" - resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.47.0.tgz#8cb313e59965d3c05cfbf898915a267af46a335c" - integrity sha512-QBmA/G2y+IfeS4oktet3qRZ+P5kPhCKRXxXnQEudYqUaEioAU1/Lq2us3D/t1Jfo4hE9REQPrbB7K5sOczJVIw== - -mime-types@^2.1.12, mime-types@~2.1.19: - version "2.1.30" - resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.30.tgz#6e7be8b4c479825f85ed6326695db73f9305d62d" - integrity sha512-crmjA4bLtR8m9qLpHvgxSChT+XoSlZi8J4n/aIdn3z92e/U47Z0V/yl+Wh9W046GgFVAmoNR/fmdbZYcSSIUeg== - dependencies: - mime-db "1.47.0" - -mimic-fn@^1.0.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" - integrity sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ== - -mimic-fn@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-2.1.0.tgz#7ed2c2ccccaf84d3ffcb7a69b57711fc2083401b" - integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== - -"minimatch@2 || 3", minimatch@3.0.4, minimatch@^3.0.2, minimatch@^3.0.3, minimatch@^3.0.4: - version "3.0.4" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" - integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== - dependencies: - brace-expansion "^1.1.7" - -minimist@0.0.8: - version "0.0.8" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d" - integrity sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0= - -minimist@^1.2.5: - version "1.2.5" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602" - integrity sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw== - -mixin-deep@^1.2.0: - version "1.3.2" - resolved "https://registry.yarnpkg.com/mixin-deep/-/mixin-deep-1.3.2.tgz#1120b43dc359a785dce65b55b82e257ccf479566" - integrity sha512-WRoDn//mXBiJ1H40rqa3vH0toePwSsGb45iInWlTySa+Uu4k3tYUSxa2v1KqAiLtvlrSzaExqS1gtk96A9zvEA== - dependencies: - for-in "^1.0.2" - is-extendable "^1.0.1" - -mkdirp@0.5.1: - version "0.5.1" - resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.1.tgz#30057438eac6cf7f8c4767f38648d6697d75c903" - integrity sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM= - dependencies: - minimist "0.0.8" - -mkdirp@0.5.x, mkdirp@^0.5.1: - version "0.5.5" - resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.5.tgz#d91cefd62d1436ca0f41620e251288d420099def" - integrity sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ== - dependencies: - minimist "^1.2.5" - -mocha@^5.2.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/mocha/-/mocha-5.2.0.tgz#6d8ae508f59167f940f2b5b3c4a612ae50c90ae6" - integrity sha512-2IUgKDhc3J7Uug+FxMXuqIyYzH7gJjXECKe/w43IGgQHTSj3InJi+yAA7T24L9bQMRKiUEHxEX37G5JpVUGLcQ== - dependencies: - browser-stdout "1.3.1" - commander "2.15.1" - debug "3.1.0" - diff "3.5.0" - escape-string-regexp "1.0.5" - glob "7.1.2" - growl "1.10.5" - he "1.1.1" - minimatch "3.0.4" - mkdirp "0.5.1" - supports-color "5.4.0" - -ms@2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" - integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g= - -ms@2.1.2: - version "2.1.2" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" - integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== - -ms@^2.1.1: - version "2.1.3" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" - integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== - -mute-stdout@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/mute-stdout/-/mute-stdout-1.0.1.tgz#acb0300eb4de23a7ddeec014e3e96044b3472331" - integrity sha512-kDcwXR4PS7caBpuRYYBUz9iVixUk3anO3f5OYFiIPwK/20vCzKCHyKoulbiDY1S53zD2bxUpxN/IJ+TnXjfvxg== - -mute-stream@0.0.7: - version "0.0.7" - resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.7.tgz#3075ce93bc21b8fab43e1bc4da7e8115ed1e7bab" - integrity sha1-MHXOk7whuPq0PhvE2n6BFe0ee6s= - -mute-stream@0.0.8: - version "0.0.8" - resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.8.tgz#1630c42b2251ff81e2a283de96a5497ea92e5e0d" - integrity sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA== - -nan@^2.12.1: - version "2.14.2" - resolved "https://registry.yarnpkg.com/nan/-/nan-2.14.2.tgz#f5376400695168f4cc694ac9393d0c9585eeea19" - integrity sha512-M2ufzIiINKCuDfBSAUr1vWQ+vuVcA9kqx8JJUsbQi6yf1uGRyb7HfpdfUr5qLXf3B/t8dPvcjhKMmlfnP47EzQ== - -nanomatch@^1.2.9: - version "1.2.13" - resolved "https://registry.yarnpkg.com/nanomatch/-/nanomatch-1.2.13.tgz#b87a8aa4fc0de8fe6be88895b38983ff265bd119" - integrity sha512-fpoe2T0RbHwBTBUOftAfBPaDEi06ufaUai0mE6Yn1kacc3SnTErfb/h+X94VXzI64rKFHYImXSvdwGGCmwOqCA== - dependencies: - arr-diff "^4.0.0" - array-unique "^0.3.2" - define-property "^2.0.2" - extend-shallow "^3.0.2" - fragment-cache "^0.2.1" - is-windows "^1.0.2" - kind-of "^6.0.2" - object.pick "^1.3.0" - regex-not "^1.0.0" - snapdragon "^0.8.1" - to-regex "^3.0.1" - -natural-compare@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" - integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= - -neo-async@^2.6.0: - version "2.6.2" - resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.2.tgz#b4aafb93e3aeb2d8174ca53cf163ab7d7308305f" - integrity sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw== - -next-tick@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/next-tick/-/next-tick-1.0.0.tgz#ca86d1fe8828169b0120208e3dc8424b9db8342c" - integrity sha1-yobR/ogoFpsBICCOPchCS524NCw= - -nice-try@^1.0.4: - version "1.0.5" - resolved "https://registry.yarnpkg.com/nice-try/-/nice-try-1.0.5.tgz#a3378a7696ce7d223e88fc9b764bd7ef1089e366" - integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== - -nise@^1.5.2: - version "1.5.3" - resolved "https://registry.yarnpkg.com/nise/-/nise-1.5.3.tgz#9d2cfe37d44f57317766c6e9408a359c5d3ac1f7" - integrity sha512-Ymbac/94xeIrMf59REBPOv0thr+CJVFMhrlAkW/gjCIE58BGQdCj0x7KRCb3yz+Ga2Rz3E9XXSvUyyxqqhjQAQ== - dependencies: - "@sinonjs/formatio" "^3.2.1" - "@sinonjs/text-encoding" "^0.7.1" - just-extend "^4.0.2" - lolex "^5.0.1" - path-to-regexp "^1.7.0" - -nock@^13.0.11: - version "13.0.11" - resolved "https://registry.yarnpkg.com/nock/-/nock-13.0.11.tgz#ba733252e720897ca50033205c39db0c7470f331" - integrity sha512-sKZltNkkWblkqqPAsjYW0bm3s9DcHRPiMOyKO/PkfJ+ANHZ2+LA2PLe22r4lLrKgXaiSaDQwW3qGsJFtIpQIeQ== - dependencies: - debug "^4.1.0" - json-stringify-safe "^5.0.1" - lodash.set "^4.3.2" - propagate "^2.0.0" - -node-modules-regexp@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/node-modules-regexp/-/node-modules-regexp-1.0.0.tgz#8d9dbe28964a4ac5712e9131642107c71e90ec40" - integrity sha1-jZ2+KJZKSsVxLpExZCEHxx6Q7EA= - -node-releases@^1.1.71: - version "1.1.71" - resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-1.1.71.tgz#cb1334b179896b1c89ecfdd4b725fb7bbdfc7dbb" - integrity sha512-zR6HoT6LrLCRBwukmrVbHv0EpEQjksO6GmFcZQQuCAy139BEsoVKPYnf3jongYW83fAa1torLGYwxxky/p28sg== - -nopt@3.x: - version "3.0.6" - resolved "https://registry.yarnpkg.com/nopt/-/nopt-3.0.6.tgz#c6465dbf08abcd4db359317f79ac68a646b28ff9" - integrity sha1-xkZdvwirzU2zWTF/eaxopkayj/k= - dependencies: - abbrev "1" - -normalize-package-data@^2.3.2: - version "2.5.0" - resolved "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-2.5.0.tgz#e66db1838b200c1dfc233225d12cb36520e234a8" - integrity sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA== - dependencies: - hosted-git-info "^2.1.4" - resolve "^1.10.0" - semver "2 || 3 || 4 || 5" - validate-npm-package-license "^3.0.1" - -normalize-path@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-2.1.1.tgz#1ab28b556e198363a8c1a6f7e6fa20137fe6aed9" - integrity sha1-GrKLVW4Zg2Oowab35vogE3/mrtk= - dependencies: - remove-trailing-separator "^1.0.1" - -normalize-path@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" - integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== - -now-and-later@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/now-and-later/-/now-and-later-2.0.1.tgz#8e579c8685764a7cc02cb680380e94f43ccb1f7c" - integrity sha512-KGvQ0cB70AQfg107Xvs/Fbu+dGmZoTRJp2TaPwcwQm3/7PteUyN2BCgk8KBMPGBUXZdVwyWS8fDCGFygBm19UQ== - dependencies: - once "^1.3.2" - -npm-run-path@^2.0.0, npm-run-path@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-2.0.2.tgz#35a9232dfa35d7067b4cb2ddf2357b1871536c5f" - integrity sha1-NakjLfo11wZ7TLLd8jV7GHFTbF8= - dependencies: - path-key "^2.0.0" - -number-is-nan@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" - integrity sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0= - -oauth-sign@~0.9.0: - version "0.9.0" - resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.9.0.tgz#47a7b016baa68b5fa0ecf3dee08a85c679ac6455" - integrity sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ== - -object-assign@^4.0.1: - version "4.1.1" - resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" - integrity sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM= - -object-copy@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/object-copy/-/object-copy-0.1.0.tgz#7e7d858b781bd7c991a41ba975ed3812754e998c" - integrity sha1-fn2Fi3gb18mRpBupde04EnVOmYw= - dependencies: - copy-descriptor "^0.1.0" - define-property "^0.2.5" - kind-of "^3.0.3" - -object-keys@^1.0.12, object-keys@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.1.1.tgz#1c47f272df277f3b1daf061677d9c82e2322c60e" - integrity sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA== - -object-visit@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/object-visit/-/object-visit-1.0.1.tgz#f79c4493af0c5377b59fe39d395e41042dd045bb" - integrity sha1-95xEk68MU3e1n+OdOV5BBC3QRbs= - dependencies: - isobject "^3.0.0" - -object.assign@^4.0.4, object.assign@^4.1.0: - version "4.1.2" - resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.1.2.tgz#0ed54a342eceb37b38ff76eb831a0e788cb63940" - integrity sha512-ixT2L5THXsApyiUPYKmW+2EHpXXe5Ii3M+f4e+aJFAHao5amFRW6J0OO6c/LU8Be47utCx2GL89hxGB6XSmKuQ== - dependencies: - call-bind "^1.0.0" - define-properties "^1.1.3" - has-symbols "^1.0.1" - object-keys "^1.1.1" - -object.defaults@^1.0.0, object.defaults@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/object.defaults/-/object.defaults-1.1.0.tgz#3a7f868334b407dea06da16d88d5cd29e435fecf" - integrity sha1-On+GgzS0B96gbaFtiNXNKeQ1/s8= - dependencies: - array-each "^1.0.1" - array-slice "^1.0.0" - for-own "^1.0.0" - isobject "^3.0.0" - -object.map@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/object.map/-/object.map-1.0.1.tgz#cf83e59dc8fcc0ad5f4250e1f78b3b81bd801d37" - integrity sha1-z4Plncj8wK1fQlDh94s7gb2AHTc= - dependencies: - for-own "^1.0.0" - make-iterator "^1.0.0" - -object.pick@^1.2.0, object.pick@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/object.pick/-/object.pick-1.3.0.tgz#87a10ac4c1694bd2e1cbf53591a66141fb5dd747" - integrity sha1-h6EKxMFpS9Lhy/U1kaZhQftd10c= - dependencies: - isobject "^3.0.1" - -object.reduce@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/object.reduce/-/object.reduce-1.0.1.tgz#6fe348f2ac7fa0f95ca621226599096825bb03ad" - integrity sha1-b+NI8qx/oPlcpiEiZZkJaCW7A60= - dependencies: - for-own "^1.0.0" - make-iterator "^1.0.0" - -once@1.x, once@^1.3.0, once@^1.3.1, once@^1.3.2, once@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" - integrity sha1-WDsap3WWHUsROsF9nFC6753Xa9E= - dependencies: - wrappy "1" - -onetime@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/onetime/-/onetime-2.0.1.tgz#067428230fd67443b2794b22bba528b6867962d4" - integrity sha1-BnQoIw/WdEOyeUsiu6UotoZ5YtQ= - dependencies: - mimic-fn "^1.0.0" - -onetime@^5.1.0: - version "5.1.2" - resolved "https://registry.yarnpkg.com/onetime/-/onetime-5.1.2.tgz#d0e96ebb56b07476df1dd9c4806e5237985ca45e" - integrity sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg== - dependencies: - mimic-fn "^2.1.0" - -optionator@^0.8.1, optionator@^0.8.2, optionator@^0.8.3: - version "0.8.3" - resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.3.tgz#84fa1d036fe9d3c7e21d99884b601167ec8fb495" - integrity sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA== - dependencies: - deep-is "~0.1.3" - fast-levenshtein "~2.0.6" - levn "~0.3.0" - prelude-ls "~1.1.2" - type-check "~0.3.2" - word-wrap "~1.2.3" - -ordered-read-streams@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/ordered-read-streams/-/ordered-read-streams-1.0.1.tgz#77c0cb37c41525d64166d990ffad7ec6a0e1363e" - integrity sha1-d8DLN8QVJdZBZtmQ/61+xqDhNj4= - dependencies: - readable-stream "^2.0.1" - -os-locale@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/os-locale/-/os-locale-1.4.0.tgz#20f9f17ae29ed345e8bde583b13d2009803c14d9" - integrity sha1-IPnxeuKe00XoveWDsT0gCYA8FNk= - dependencies: - lcid "^1.0.0" - -os-tmpdir@~1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" - integrity sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ= - -p-finally@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/p-finally/-/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae" - integrity sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4= - -p-limit@^2.0.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-2.3.0.tgz#3dd33c647a214fdfffd835933eb086da0dc21db1" - integrity sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w== - dependencies: - p-try "^2.0.0" - -p-locate@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-3.0.0.tgz#322d69a05c0264b25997d9f40cd8a891ab0064a4" - integrity sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ== - dependencies: - p-limit "^2.0.0" - -p-try@^2.0.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/p-try/-/p-try-2.2.0.tgz#cb2868540e313d61de58fafbe35ce9004d5540e6" - integrity sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ== - -parent-module@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/parent-module/-/parent-module-1.0.1.tgz#691d2709e78c79fae3a156622452d00762caaaa2" - integrity sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g== - dependencies: - callsites "^3.0.0" - -parse-filepath@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/parse-filepath/-/parse-filepath-1.0.2.tgz#a632127f53aaf3d15876f5872f3ffac763d6c891" - integrity sha1-pjISf1Oq89FYdvWHLz/6x2PWyJE= - dependencies: - is-absolute "^1.0.0" - map-cache "^0.2.0" - path-root "^0.1.1" - -parse-json@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-2.2.0.tgz#f480f40434ef80741f8469099f8dea18f55a4dc9" - integrity sha1-9ID0BDTvgHQfhGkJn43qGPVaTck= - dependencies: - error-ex "^1.2.0" - -parse-node-version@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/parse-node-version/-/parse-node-version-1.0.1.tgz#e2b5dbede00e7fa9bc363607f53327e8b073189b" - integrity sha512-3YHlOa/JgH6Mnpr05jP9eDG254US9ek25LyIxZlDItp2iJtwyaXQb57lBYLdT3MowkUFYEV2XXNAYIPlESvJlA== - -parse-passwd@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/parse-passwd/-/parse-passwd-1.0.0.tgz#6d5b934a456993b23d37f40a382d6f1666a8e5c6" - integrity sha1-bVuTSkVpk7I9N/QKOC1vFmao5cY= - -pascalcase@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/pascalcase/-/pascalcase-0.1.1.tgz#b363e55e8006ca6fe21784d2db22bd15d7917f14" - integrity sha1-s2PlXoAGym/iF4TS2yK9FdeRfxQ= - -path-dirname@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/path-dirname/-/path-dirname-1.0.2.tgz#cc33d24d525e099a5388c0336c6e32b9160609e0" - integrity sha1-zDPSTVJeCZpTiMAzbG4yuRYGCeA= - -path-exists@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-2.1.0.tgz#0feb6c64f0fc518d9a754dd5efb62c7022761f4b" - integrity sha1-D+tsZPD8UY2adU3V77YscCJ2H0s= - dependencies: - pinkie-promise "^2.0.0" - -path-exists@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-3.0.0.tgz#ce0ebeaa5f78cb18925ea7d810d7b59b010fd515" - integrity sha1-zg6+ql94yxiSXqfYENe1mwEP1RU= - -path-is-absolute@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" - integrity sha1-F0uSaHNVNP+8es5r9TpanhtcX18= - -path-is-inside@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/path-is-inside/-/path-is-inside-1.0.2.tgz#365417dede44430d1c11af61027facf074bdfc53" - integrity sha1-NlQX3t5EQw0cEa9hAn+s8HS9/FM= - -path-key@^2.0.0, path-key@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/path-key/-/path-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40" - integrity sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A= - -path-parse@^1.0.6: - version "1.0.6" - resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.6.tgz#d62dbb5679405d72c4737ec58600e9ddcf06d24c" - integrity sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw== - -path-root-regex@^0.1.0: - version "0.1.2" - resolved "https://registry.yarnpkg.com/path-root-regex/-/path-root-regex-0.1.2.tgz#bfccdc8df5b12dc52c8b43ec38d18d72c04ba96d" - integrity sha1-v8zcjfWxLcUsi0PsONGNcsBLqW0= - -path-root@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/path-root/-/path-root-0.1.1.tgz#9a4a6814cac1c0cd73360a95f32083c8ea4745b7" - integrity sha1-mkpoFMrBwM1zNgqV8yCDyOpHRbc= - dependencies: - path-root-regex "^0.1.0" - -path-to-regexp@^1.7.0: - version "1.8.0" - resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-1.8.0.tgz#887b3ba9d84393e87a0a0b9f4cb756198b53548a" - integrity sha512-n43JRhlUKUAlibEJhPeir1ncUID16QnEjNpwzNdO3Lm4ywrBpBZ5oLD0I6br9evr1Y9JTqwRtAh7JLoOzAQdVA== - dependencies: - isarray "0.0.1" - -path-type@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/path-type/-/path-type-1.1.0.tgz#59c44f7ee491da704da415da5a4070ba4f8fe441" - integrity sha1-WcRPfuSR2nBNpBXaWkBwuk+P5EE= - dependencies: - graceful-fs "^4.1.2" - pify "^2.0.0" - pinkie-promise "^2.0.0" - -performance-now@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" - integrity sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns= - -pify@^2.0.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/pify/-/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c" - integrity sha1-7RQaasBDqEnqWISY59yosVMw6Qw= - -pify@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/pify/-/pify-4.0.1.tgz#4b2cd25c50d598735c50292224fd8c6df41e3231" - integrity sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g== - -pinkie-promise@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/pinkie-promise/-/pinkie-promise-2.0.1.tgz#2135d6dfa7a358c069ac9b178776288228450ffa" - integrity sha1-ITXW36ejWMBprJsXh3YogihFD/o= - dependencies: - pinkie "^2.0.0" - -pinkie@^2.0.0: - version "2.0.4" - resolved "https://registry.yarnpkg.com/pinkie/-/pinkie-2.0.4.tgz#72556b80cfa0d48a974e80e77248e80ed4f7f870" - integrity sha1-clVrgM+g1IqXToDnckjoDtT3+HA= - -pirates@^4.0.0: - version "4.0.1" - resolved "https://registry.yarnpkg.com/pirates/-/pirates-4.0.1.tgz#643a92caf894566f91b2b986d2c66950a8e2fb87" - integrity sha512-WuNqLTbMI3tmfef2TKxlQmAiLHKtFhlsCZnPIpuv2Ow0RDVO8lfy1Opf4NUzlMXLjPl+Men7AuVdX6TA+s+uGA== - dependencies: - node-modules-regexp "^1.0.0" - -pkg-dir@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-3.0.0.tgz#2749020f239ed990881b1f71210d51eb6523bea3" - integrity sha512-/E57AYkoeQ25qkxMj5PBOVgF8Kiu/h7cYS30Z5+R7WaiCCBfLq58ZI/dSeaEKb9WVJV5n/03QwrN3IeWIFllvw== - dependencies: - find-up "^3.0.0" - -plugin-error@^0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/plugin-error/-/plugin-error-0.1.2.tgz#3b9bb3335ccf00f425e07437e19276967da47ace" - integrity sha1-O5uzM1zPAPQl4HQ34ZJ2ln2kes4= - dependencies: - ansi-cyan "^0.1.1" - ansi-red "^0.1.1" - arr-diff "^1.0.1" - arr-union "^2.0.1" - extend-shallow "^1.1.2" - -plugin-error@^1.0.0, plugin-error@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/plugin-error/-/plugin-error-1.0.1.tgz#77016bd8919d0ac377fdcdd0322328953ca5781c" - integrity sha512-L1zP0dk7vGweZME2i+EeakvUNqSrdiI3F91TwEoYiGrAfUXmVv6fJIq4g82PAXxNsWOp0J7ZqQy/3Szz0ajTxA== - dependencies: - ansi-colors "^1.0.1" - arr-diff "^4.0.0" - arr-union "^3.1.0" - extend-shallow "^3.0.2" - -pluralize@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-7.0.0.tgz#298b89df8b93b0221dbf421ad2b1b1ea23fc6777" - integrity sha512-ARhBOdzS3e41FbkW/XWrTEtukqqLoK5+Z/4UeDaLuSW+39JPeFgs4gCGqsrJHVZX0fUrx//4OF0K1CUGwlIFow== - -posix-character-classes@^0.1.0: - version "0.1.1" - resolved "https://registry.yarnpkg.com/posix-character-classes/-/posix-character-classes-0.1.1.tgz#01eac0fe3b5af71a2a6c02feabb8c1fef7e00eab" - integrity sha1-AerA/jta9xoqbAL+q7jB/vfgDqs= - -prelude-ls@~1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54" - integrity sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ= - -pretty-hrtime@^1.0.0: - version "1.0.3" - resolved "https://registry.yarnpkg.com/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz#b7e3ea42435a4c9b2759d99e0f201eb195802ee1" - integrity sha1-t+PqQkNaTJsnWdmeDyAesZWALuE= - -process-nextick-args@^2.0.0, process-nextick-args@~2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2" - integrity sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag== - -progress@^2.0.0: - version "2.0.3" - resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.3.tgz#7e8cf8d8f5b8f239c1bc68beb4eb78567d572ef8" - integrity sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA== - -propagate@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/propagate/-/propagate-2.0.1.tgz#40cdedab18085c792334e64f0ac17256d38f9a45" - integrity sha512-vGrhOavPSTz4QVNuBNdcNXePNdNMaO1xj9yBeH1ScQPjk/rhg9sSlCXPhMkFuaNNW/syTvYqsnbIJxMBfRbbag== - -pseudomap@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3" - integrity sha1-8FKijacOYYkX7wqKw0wa5aaChrM= - -psl@^1.1.28: - version "1.8.0" - resolved "https://registry.yarnpkg.com/psl/-/psl-1.8.0.tgz#9326f8bcfb013adcc005fdff056acce020e51c24" - integrity sha512-RIdOzyoavK+hA18OGGWDqUTsCLhtA7IcZ/6NCs4fFJaHBDab+pDDmDIByWFRQJq2Cd7r1OoQxBGKOaztq+hjIQ== - -pump@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/pump/-/pump-2.0.1.tgz#12399add6e4cf7526d973cbc8b5ce2e2908b3909" - integrity sha512-ruPMNRkN3MHP1cWJc9OWr+T/xDP0jhXYCLfJcBuX54hhfIBnaQmAUMfDcG4DM5UMWByBbJY69QSphm3jtDKIkA== - dependencies: - end-of-stream "^1.1.0" - once "^1.3.1" - -pumpify@^1.3.5: - version "1.5.1" - resolved "https://registry.yarnpkg.com/pumpify/-/pumpify-1.5.1.tgz#36513be246ab27570b1a374a5ce278bfd74370ce" - integrity sha512-oClZI37HvuUJJxSKKrC17bZ9Cu0ZYhEAGPsPUy9KlMUmv9dKX2o77RUmq7f3XjIxbwyGwYzbzQ1L2Ks8sIradQ== - dependencies: - duplexify "^3.6.0" - inherits "^2.0.3" - pump "^2.0.0" - -punycode@^2.1.0, punycode@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" - integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== - -qs@~6.5.2: - version "6.5.2" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" - integrity sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA== - -read-pkg-up@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-1.0.1.tgz#9d63c13276c065918d57f002a57f40a1b643fb02" - integrity sha1-nWPBMnbAZZGNV/ACpX9AobZD+wI= - dependencies: - find-up "^1.0.0" - read-pkg "^1.0.0" - -read-pkg@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-1.1.0.tgz#f5ffaa5ecd29cb31c0474bca7d756b6bb29e3f28" - integrity sha1-9f+qXs0pyzHAR0vKfXVra7KePyg= - dependencies: - load-json-file "^1.0.0" - normalize-package-data "^2.3.2" - path-type "^1.0.0" - -readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.5, readable-stream@^2.1.5, readable-stream@^2.2.2, readable-stream@^2.3.3, readable-stream@^2.3.5, readable-stream@^2.3.6, readable-stream@~2.3.6: - version "2.3.7" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.7.tgz#1eca1cf711aef814c04f62252a36a62f6cb23b57" - integrity sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw== - dependencies: - 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" - -readdirp@^2.2.1: - version "2.2.1" - resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-2.2.1.tgz#0e87622a3325aa33e892285caf8b4e846529a525" - integrity sha512-1JU/8q+VgFZyxwrJ+SVIOsh+KywWGpds3NTqikiKpDMZWScmAYyKIgqkO+ARvNWJfXeXR1zxz7aHF4u4CyH6vQ== - dependencies: - graceful-fs "^4.1.11" - micromatch "^3.1.10" - readable-stream "^2.0.2" - -rechoir@^0.6.2: - version "0.6.2" - resolved "https://registry.yarnpkg.com/rechoir/-/rechoir-0.6.2.tgz#85204b54dba82d5742e28c96756ef43af50e3384" - integrity sha1-hSBLVNuoLVdC4oyWdW70OvUOM4Q= - dependencies: - resolve "^1.1.6" - -regenerate-unicode-properties@^8.2.0: - version "8.2.0" - resolved "https://registry.yarnpkg.com/regenerate-unicode-properties/-/regenerate-unicode-properties-8.2.0.tgz#e5de7111d655e7ba60c057dbe9ff37c87e65cdec" - integrity sha512-F9DjY1vKLo/tPePDycuH3dn9H1OTPIkVD9Kz4LODu+F2C75mgjAJ7x/gwy6ZcSNRAAkhNlJSOHRe8k3p+K9WhA== - dependencies: - regenerate "^1.4.0" - -regenerate@^1.4.0: - version "1.4.2" - resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.4.2.tgz#b9346d8827e8f5a32f7ba29637d398b69014848a" - integrity sha512-zrceR/XhGYU/d/opr2EKO7aRHUeiBI8qjtfHqADTwZd6Szfy16la6kqD0MIUs5z5hx6AaKa+PixpPrR289+I0A== - -regenerator-runtime@^0.13.4: - version "0.13.7" - resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.7.tgz#cac2dacc8a1ea675feaabaeb8ae833898ae46f55" - integrity sha512-a54FxoJDIr27pgf7IgeQGxmqUNYrcV338lf/6gH456HZ/PhX+5BcwHXG9ajESmwe6WRO0tAzRUrRmNONWgkrew== - -regenerator-transform@^0.14.2: - version "0.14.5" - resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.14.5.tgz#c98da154683671c9c4dcb16ece736517e1b7feb4" - integrity sha512-eOf6vka5IO151Jfsw2NO9WpGX58W6wWmefK3I1zEGr0lOD0u8rwPaNqQL1aRxUaxLeKO3ArNh3VYg1KbaD+FFw== - dependencies: - "@babel/runtime" "^7.8.4" - -regex-not@^1.0.0, regex-not@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/regex-not/-/regex-not-1.0.2.tgz#1f4ece27e00b0b65e0247a6810e6a85d83a5752c" - integrity sha512-J6SDjUgDxQj5NusnOtdFxDwN/+HWykR8GELwctJ7mdqhcyy1xEc4SRFHUXvxTp661YaVKAjfRLZ9cCqS6tn32A== - dependencies: - extend-shallow "^3.0.2" - safe-regex "^1.1.0" - -regexpp@^1.0.1: - version "1.1.0" - resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-1.1.0.tgz#0e3516dd0b7904f413d2d4193dce4618c3a689ab" - integrity sha512-LOPw8FpgdQF9etWMaAfG/WRthIdXJGYp4mJ2Jgn/2lpkbod9jPn0t9UqN7AxBOKNfzRbYyVfgc7Vk4t/MpnXgw== - -regexpp@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-2.0.1.tgz#8d19d31cf632482b589049f8281f93dbcba4d07f" - integrity sha512-lv0M6+TkDVniA3aD1Eg0DVpfU/booSu7Eev3TDO/mZKHBfVjgCGTV4t4buppESEYDtkArYFOxTJWv6S5C+iaNw== - -regexpu-core@^4.7.1: - version "4.7.1" - resolved "https://registry.yarnpkg.com/regexpu-core/-/regexpu-core-4.7.1.tgz#2dea5a9a07233298fbf0db91fa9abc4c6e0f8ad6" - integrity sha512-ywH2VUraA44DZQuRKzARmw6S66mr48pQVva4LBeRhcOltJ6hExvWly5ZjFLYo67xbIxb6W1q4bAGtgfEl20zfQ== - dependencies: - regenerate "^1.4.0" - regenerate-unicode-properties "^8.2.0" - regjsgen "^0.5.1" - regjsparser "^0.6.4" - unicode-match-property-ecmascript "^1.0.4" - unicode-match-property-value-ecmascript "^1.2.0" - -regjsgen@^0.5.1: - version "0.5.2" - resolved "https://registry.yarnpkg.com/regjsgen/-/regjsgen-0.5.2.tgz#92ff295fb1deecbf6ecdab2543d207e91aa33733" - integrity sha512-OFFT3MfrH90xIW8OOSyUrk6QHD5E9JOTeGodiJeBS3J6IwlgzJMNE/1bZklWz5oTg+9dCMyEetclvCVXOPoN3A== - -regjsparser@^0.6.4: - version "0.6.9" - resolved "https://registry.yarnpkg.com/regjsparser/-/regjsparser-0.6.9.tgz#b489eef7c9a2ce43727627011429cf833a7183e6" - integrity sha512-ZqbNRz1SNjLAiYuwY0zoXW8Ne675IX5q+YHioAGbCw4X96Mjl2+dcX9B2ciaeyYjViDAfvIjFpQjJgLttTEERQ== - dependencies: - jsesc "~0.5.0" - -remove-bom-buffer@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/remove-bom-buffer/-/remove-bom-buffer-3.0.0.tgz#c2bf1e377520d324f623892e33c10cac2c252b53" - integrity sha512-8v2rWhaakv18qcvNeli2mZ/TMTL2nEyAKRvzo1WtnZBl15SHyEhrCu2/xKlJyUFKHiHgfXIyuY6g2dObJJycXQ== - dependencies: - is-buffer "^1.1.5" - is-utf8 "^0.2.1" - -remove-bom-stream@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/remove-bom-stream/-/remove-bom-stream-1.2.0.tgz#05f1a593f16e42e1fb90ebf59de8e569525f9523" - integrity sha1-BfGlk/FuQuH7kOv1nejlaVJflSM= - dependencies: - remove-bom-buffer "^3.0.0" - safe-buffer "^5.1.0" - through2 "^2.0.3" - -remove-trailing-separator@^1.0.1, remove-trailing-separator@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz#c24bce2a283adad5bc3f58e0d48249b92379d8ef" - integrity sha1-wkvOKig62tW8P1jg1IJJuSN52O8= - -repeat-element@^1.1.2: - version "1.1.4" - resolved "https://registry.yarnpkg.com/repeat-element/-/repeat-element-1.1.4.tgz#be681520847ab58c7568ac75fbfad28ed42d39e9" - integrity sha512-LFiNfRcSu7KK3evMyYOuCzv3L10TW7yC1G2/+StMjK8Y6Vqd2MG7r/Qjw4ghtuCOjFvlnms/iMmLqpvW/ES/WQ== - -repeat-string@^1.6.1: - version "1.6.1" - resolved "https://registry.yarnpkg.com/repeat-string/-/repeat-string-1.6.1.tgz#8dcae470e1c88abc2d600fff4a776286da75e637" - integrity sha1-jcrkcOHIirwtYA//Sndihtp15jc= - -replace-ext@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/replace-ext/-/replace-ext-1.0.1.tgz#2d6d996d04a15855d967443631dd5f77825b016a" - integrity sha512-yD5BHCe7quCgBph4rMQ+0KkIRKwWCrHDOX1p1Gp6HwjPM5kVoCdKGNhN7ydqqsX6lJEnQDKZ/tFMiEdQ1dvPEw== - -replace-homedir@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/replace-homedir/-/replace-homedir-1.0.0.tgz#e87f6d513b928dde808260c12be7fec6ff6e798c" - integrity sha1-6H9tUTuSjd6AgmDBK+f+xv9ueYw= - dependencies: - homedir-polyfill "^1.0.1" - is-absolute "^1.0.0" - remove-trailing-separator "^1.1.0" - -request@^2.88.0: - version "2.88.2" - resolved "https://registry.yarnpkg.com/request/-/request-2.88.2.tgz#d73c918731cb5a87da047e207234146f664d12b3" - integrity sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw== - dependencies: - aws-sign2 "~0.7.0" - aws4 "^1.8.0" - caseless "~0.12.0" - combined-stream "~1.0.6" - extend "~3.0.2" - forever-agent "~0.6.1" - form-data "~2.3.2" - har-validator "~5.1.3" - http-signature "~1.2.0" - is-typedarray "~1.0.0" - isstream "~0.1.2" - json-stringify-safe "~5.0.1" - mime-types "~2.1.19" - oauth-sign "~0.9.0" - performance-now "^2.1.0" - qs "~6.5.2" - safe-buffer "^5.1.2" - tough-cookie "~2.5.0" - tunnel-agent "^0.6.0" - uuid "^3.3.2" - -require-directory@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" - integrity sha1-jGStX9MNqxyXbiNE/+f3kqam30I= - -require-main-filename@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-1.0.1.tgz#97f717b69d48784f5f526a6c5aa8ffdda055a4d1" - integrity sha1-l/cXtp1IeE9fUmpsWqj/3aBVpNE= - -require-uncached@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/require-uncached/-/require-uncached-1.0.3.tgz#4e0d56d6c9662fd31e43011c4b95aa49955421d3" - integrity sha1-Tg1W1slmL9MeQwEcS5WqSZVUIdM= - dependencies: - caller-path "^0.1.0" - resolve-from "^1.0.0" - -resolve-dir@^1.0.0, resolve-dir@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/resolve-dir/-/resolve-dir-1.0.1.tgz#79a40644c362be82f26effe739c9bb5382046f43" - integrity sha1-eaQGRMNivoLybv/nOcm7U4IEb0M= - dependencies: - expand-tilde "^2.0.0" - global-modules "^1.0.0" - -resolve-from@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-1.0.1.tgz#26cbfe935d1aeeeabb29bc3fe5aeb01e93d44226" - integrity sha1-Jsv+k10a7uq7Kbw/5a6wHpPUQiY= - -resolve-from@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" - integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== - -resolve-options@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/resolve-options/-/resolve-options-1.1.0.tgz#32bb9e39c06d67338dc9378c0d6d6074566ad131" - integrity sha1-MrueOcBtZzONyTeMDW1gdFZq0TE= - dependencies: - value-or-function "^3.0.0" - -resolve-url@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" - integrity sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo= - -resolve@1.1.x: - version "1.1.7" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.1.7.tgz#203114d82ad2c5ed9e8e0411b3932875e889e97b" - integrity sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs= - -resolve@^1.1.6, resolve@^1.1.7, resolve@^1.10.0, resolve@^1.12.0, resolve@^1.14.2, resolve@^1.4.0: - version "1.20.0" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.20.0.tgz#629a013fb3f70755d6f0b7935cc1c2c5378b1975" - integrity sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A== - dependencies: - is-core-module "^2.2.0" - path-parse "^1.0.6" - -restore-cursor@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-2.0.0.tgz#9f7ee287f82fd326d4fd162923d62129eee0dfaf" - integrity sha1-n37ih/gv0ybU/RYpI9YhKe7g368= - dependencies: - onetime "^2.0.0" - signal-exit "^3.0.2" - -restore-cursor@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-3.1.0.tgz#39f67c54b3a7a58cea5236d95cf0034239631f7e" - integrity sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA== - dependencies: - onetime "^5.1.0" - signal-exit "^3.0.2" - -ret@~0.1.10: - version "0.1.15" - resolved "https://registry.yarnpkg.com/ret/-/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc" - integrity sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg== - -rimraf@2.6.3, rimraf@~2.6.2: - version "2.6.3" - resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.3.tgz#b2d104fe0d8fb27cf9e0a1cda8262dd3833c6cab" - integrity sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA== - dependencies: - glob "^7.1.3" - -run-async@^2.2.0, run-async@^2.4.0: - version "2.4.1" - resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.4.1.tgz#8440eccf99ea3e70bd409d49aab88e10c189a455" - integrity sha512-tvVnVv01b8c1RrA6Ep7JkStj85Guv/YrMcwqYQnwjsAS2cTmmPGBBjAjpCW7RrSodNSoE2/qg9O4bceNvUuDgQ== - -rx-lite-aggregates@^4.0.8: - version "4.0.8" - resolved "https://registry.yarnpkg.com/rx-lite-aggregates/-/rx-lite-aggregates-4.0.8.tgz#753b87a89a11c95467c4ac1626c4efc4e05c67be" - integrity sha1-dTuHqJoRyVRnxKwWJsTvxOBcZ74= - dependencies: - rx-lite "*" - -rx-lite@*, rx-lite@^4.0.8: - version "4.0.8" - resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-4.0.8.tgz#0b1e11af8bc44836f04a6407e92da42467b79444" - integrity sha1-Cx4Rr4vESDbwSmQH6S2kJGe3lEQ= - -rxjs@^6.6.0: - version "6.6.7" - resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.6.7.tgz#90ac018acabf491bf65044235d5863c4dab804c9" - integrity sha512-hTdwr+7yYNIT5n4AMYp85KA6yw2Va0FLa3Rguvbpa4W3I5xynaBZo41cM3XM+4Q6fRMj3sBYIR1VAmZMXYJvRQ== - dependencies: - tslib "^1.9.0" - -safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@^5.1.2: - version "5.2.1" - resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" - integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== - -safe-buffer@~5.1.0, safe-buffer@~5.1.1: - version "5.1.2" - resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" - integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== - -safe-regex@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/safe-regex/-/safe-regex-1.1.0.tgz#40a3669f3b077d1e943d44629e157dd48023bf2e" - integrity sha1-QKNmnzsHfR6UPURinhV91IAjvy4= - dependencies: - ret "~0.1.10" - -"safer-buffer@>= 2.1.2 < 3", safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: - version "2.1.2" - resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" - integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== - -semver-greatest-satisfied-range@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/semver-greatest-satisfied-range/-/semver-greatest-satisfied-range-1.1.0.tgz#13e8c2658ab9691cb0cd71093240280d36f77a5b" - integrity sha1-E+jCZYq5aRywzXEJMkAoDTb3els= - dependencies: - sver-compat "^1.5.0" - -"semver@2 || 3 || 4 || 5", semver@^5.3.0, semver@^5.5.0, semver@^5.6.0: - version "5.7.1" - resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" - integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== - -semver@7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.0.0.tgz#5f3ca35761e47e05b206c6daff2cf814f0316b8e" - integrity sha512-+GB6zVA9LWh6zovYQLALHwv5rb2PHGlJi3lfiqIHxR0uuwCgefcOJc59v9fv1w8GbStwxuuqqAjI9NMAOOgq1A== - -semver@^6.1.1, semver@^6.1.2, semver@^6.3.0: - version "6.3.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" - integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== - -set-blocking@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" - integrity sha1-BF+XgtARrppoA93TgrJDkrPYkPc= - -set-value@^2.0.0, set-value@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/set-value/-/set-value-2.0.1.tgz#a18d40530e6f07de4228c7defe4227af8cad005b" - integrity sha512-JxHc1weCN68wRY0fhCoXpyK55m/XPHafOmK4UWD7m2CI14GMcFypt4w/0+NV5f/ZMby2F6S2wwA7fgynh9gWSw== - dependencies: - extend-shallow "^2.0.1" - is-extendable "^0.1.1" - is-plain-object "^2.0.3" - split-string "^3.0.1" - -shallow-clone@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/shallow-clone/-/shallow-clone-3.0.1.tgz#8f2981ad92531f55035b01fb230769a40e02efa3" - integrity sha512-/6KqX+GVUdqPuPPd2LxDDxzX6CAbjJehAAOKlNpqqUpAqPM6HeL8f+o3a+JsyGjn2lv0WY8UsTgUJjU9Ok55NA== - dependencies: - kind-of "^6.0.2" - -shebang-command@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea" - integrity sha1-RKrGW2lbAzmJaMOfNj/uXer98eo= - dependencies: - shebang-regex "^1.0.0" - -shebang-regex@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3" - integrity sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM= - -signal-exit@^3.0.0, signal-exit@^3.0.2: - version "3.0.3" - resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.3.tgz#a1410c2edd8f077b08b4e253c8eacfcaf057461c" - integrity sha512-VUJ49FC8U1OxwZLxIbTTrDvLnf/6TDgxZcK8wxR8zs13xpx7xbG60ndBlhNrFi2EMuFRoeDoJO7wthSLq42EjA== - -sinon@^7.3.2: - version "7.5.0" - resolved "https://registry.yarnpkg.com/sinon/-/sinon-7.5.0.tgz#e9488ea466070ea908fd44a3d6478fd4923c67ec" - integrity sha512-AoD0oJWerp0/rY9czP/D6hDTTUYGpObhZjMpd7Cl/A6+j0xBE+ayL/ldfggkBXUs0IkvIiM1ljM8+WkOc5k78Q== - dependencies: - "@sinonjs/commons" "^1.4.0" - "@sinonjs/formatio" "^3.2.1" - "@sinonjs/samsam" "^3.3.3" - diff "^3.5.0" - lolex "^4.2.0" - nise "^1.5.2" - supports-color "^5.5.0" - -slice-ansi@1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-1.0.0.tgz#044f1a49d8842ff307aad6b505ed178bd950134d" - integrity sha512-POqxBK6Lb3q6s047D/XsDVNPnF9Dl8JSaqe9h9lURl0OdNqy/ujDrOiIHtsqXMGbWWTIomRzAMaTyawAU//Reg== - dependencies: - is-fullwidth-code-point "^2.0.0" - -slice-ansi@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-2.1.0.tgz#cacd7693461a637a5788d92a7dd4fba068e81636" - integrity sha512-Qu+VC3EwYLldKa1fCxuuvULvSJOKEgk9pi8dZeCVK7TqBfUNTH4sFkk4joj8afVSfAYgJoSOetjx9QWOJ5mYoQ== - dependencies: - ansi-styles "^3.2.0" - astral-regex "^1.0.0" - is-fullwidth-code-point "^2.0.0" - -snapdragon-node@^2.0.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/snapdragon-node/-/snapdragon-node-2.1.1.tgz#6c175f86ff14bdb0724563e8f3c1b021a286853b" - integrity sha512-O27l4xaMYt/RSQ5TR3vpWCAB5Kb/czIcqUFOM/C4fYcLnbZUc1PkjTAMjof2pBWaSTwOUd6qUHcFGVGj7aIwnw== - dependencies: - define-property "^1.0.0" - isobject "^3.0.0" - snapdragon-util "^3.0.1" - -snapdragon-util@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/snapdragon-util/-/snapdragon-util-3.0.1.tgz#f956479486f2acd79700693f6f7b805e45ab56e2" - integrity sha512-mbKkMdQKsjX4BAL4bRYTj21edOf8cN7XHdYUJEe+Zn99hVEYcMvKPct1IqNe7+AZPirn8BCDOQBHQZknqmKlZQ== - dependencies: - kind-of "^3.2.0" - -snapdragon@^0.8.1: - version "0.8.2" - resolved "https://registry.yarnpkg.com/snapdragon/-/snapdragon-0.8.2.tgz#64922e7c565b0e14204ba1aa7d6964278d25182d" - integrity sha512-FtyOnWN/wCHTVXOMwvSv26d+ko5vWlIDD6zoUJ7LW8vh+ZBC8QdljveRP+crNrtBwioEUWy/4dMtbBjA4ioNlg== - dependencies: - base "^0.11.1" - debug "^2.2.0" - define-property "^0.2.5" - extend-shallow "^2.0.1" - map-cache "^0.2.2" - source-map "^0.5.6" - source-map-resolve "^0.5.0" - use "^3.1.0" - -source-map-resolve@^0.5.0: - version "0.5.3" - resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.3.tgz#190866bece7553e1f8f267a2ee82c606b5509a1a" - integrity sha512-Htz+RnsXWk5+P2slx5Jh3Q66vhQj1Cllm0zvnaY98+NFx+Dv2CF/f5O/t8x+KaNdrdIAsruNzoh/KpialbqAnw== - dependencies: - atob "^2.1.2" - decode-uri-component "^0.2.0" - resolve-url "^0.2.1" - source-map-url "^0.4.0" - urix "^0.1.0" - -source-map-support@^0.5.16: - version "0.5.19" - resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.19.tgz#a98b62f86dcaf4f67399648c085291ab9e8fed61" - integrity sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw== - dependencies: - buffer-from "^1.0.0" - source-map "^0.6.0" - -source-map-url@^0.4.0: - version "0.4.1" - resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.1.tgz#0af66605a745a5a2f91cf1bbf8a7afbc283dec56" - integrity sha512-cPiFOTLUKvJFIg4SKVScy4ilPPW6rFgMgfuZJPNoDuMs3nC1HbMUycBoJw77xFIp6z1UJQJOfx6C9GMH80DiTw== - -source-map@^0.5.0, source-map@^0.5.1, source-map@^0.5.6: - version "0.5.7" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" - integrity sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w= - -source-map@^0.6.0, source-map@^0.6.1: - version "0.6.1" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" - integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== - -source-map@~0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.2.0.tgz#dab73fbcfc2ba819b4de03bd6f6eaa48164b3f9d" - integrity sha1-2rc/vPwrqBm03gO9b26qSBZLP50= - dependencies: - amdefine ">=0.0.4" - -sparkles@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/sparkles/-/sparkles-1.0.1.tgz#008db65edce6c50eec0c5e228e1945061dd0437c" - integrity sha512-dSO0DDYUahUt/0/pD/Is3VIm5TGJjludZ0HVymmhYF6eNA53PVLhnUk0znSYbH8IYBuJdCE+1luR22jNLMaQdw== - -spdx-correct@^3.0.0: - version "3.1.1" - resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.1.1.tgz#dece81ac9c1e6713e5f7d1b6f17d468fa53d89a9" - integrity sha512-cOYcUWwhCuHCXi49RhFRCyJEK3iPj1Ziz9DpViV3tbZOwXD49QzIN3MpOLJNxh2qwq2lJJZaKMVw9qNi4jTC0w== - dependencies: - spdx-expression-parse "^3.0.0" - spdx-license-ids "^3.0.0" - -spdx-exceptions@^2.1.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz#3f28ce1a77a00372683eade4a433183527a2163d" - integrity sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A== - -spdx-expression-parse@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/spdx-expression-parse/-/spdx-expression-parse-3.0.1.tgz#cf70f50482eefdc98e3ce0a6833e4a53ceeba679" - integrity sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q== - dependencies: - spdx-exceptions "^2.1.0" - spdx-license-ids "^3.0.0" - -spdx-license-ids@^3.0.0: - version "3.0.7" - resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.7.tgz#e9c18a410e5ed7e12442a549fbd8afa767038d65" - integrity sha512-U+MTEOO0AiDzxwFvoa4JVnMV6mZlJKk2sBLt90s7G0Gd0Mlknc7kxEn3nuDPNZRta7O2uy8oLcZLVT+4sqNZHQ== - -split-string@^3.0.1, split-string@^3.0.2: - version "3.1.0" - resolved "https://registry.yarnpkg.com/split-string/-/split-string-3.1.0.tgz#7cb09dda3a86585705c64b39a6466038682e8fe2" - integrity sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw== - dependencies: - extend-shallow "^3.0.0" - -sprintf-js@~1.0.2: - version "1.0.3" - resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" - integrity sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw= - -sshpk@^1.7.0: - version "1.16.1" - resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.16.1.tgz#fb661c0bef29b39db40769ee39fa70093d6f6877" - integrity sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg== - dependencies: - asn1 "~0.2.3" - assert-plus "^1.0.0" - bcrypt-pbkdf "^1.0.0" - dashdash "^1.12.0" - ecc-jsbn "~0.1.1" - getpass "^0.1.1" - jsbn "~0.1.0" - safer-buffer "^2.0.2" - tweetnacl "~0.14.0" - -stack-trace@0.0.10: - version "0.0.10" - resolved "https://registry.yarnpkg.com/stack-trace/-/stack-trace-0.0.10.tgz#547c70b347e8d32b4e108ea1a2a159e5fdde19c0" - integrity sha1-VHxws0fo0ytOEI6hoqFZ5f3eGcA= - -static-extend@^0.1.1: - version "0.1.2" - resolved "https://registry.yarnpkg.com/static-extend/-/static-extend-0.1.2.tgz#60809c39cbff55337226fd5e0b520f341f1fb5c6" - integrity sha1-YICcOcv/VTNyJv1eC1IPNB8ftcY= - dependencies: - define-property "^0.2.5" - object-copy "^0.1.0" - -stream-exhaust@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/stream-exhaust/-/stream-exhaust-1.0.2.tgz#acdac8da59ef2bc1e17a2c0ccf6c320d120e555d" - integrity sha512-b/qaq/GlBK5xaq1yrK9/zFcyRSTNxmcZwFLGSTG0mXgZl/4Z6GgiyYOXOvY7N3eEvFRAG1bkDRz5EPGSvPYQlw== - -stream-shift@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/stream-shift/-/stream-shift-1.0.1.tgz#d7088281559ab2778424279b0877da3c392d5a3d" - integrity sha512-AiisoFqQ0vbGcZgQPY1cdP2I76glaVA/RauYR4G4thNFgkTqr90yXTo4LYX60Jl+sIlPNHHdGSwo01AvbKUSVQ== - -string-width@^1.0.1, string-width@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/string-width/-/string-width-1.0.2.tgz#118bdf5b8cdc51a2a7e70d211e07e2b0b9b107d3" - integrity sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M= - dependencies: - code-point-at "^1.0.0" - is-fullwidth-code-point "^1.0.0" - strip-ansi "^3.0.0" - -string-width@^2.1.0, string-width@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/string-width/-/string-width-2.1.1.tgz#ab93f27a8dc13d28cac815c462143a6d9012ae9e" - integrity sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw== - dependencies: - is-fullwidth-code-point "^2.0.0" - strip-ansi "^4.0.0" - -string-width@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/string-width/-/string-width-3.1.0.tgz#22767be21b62af1081574306f69ac51b62203961" - integrity sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w== - dependencies: - emoji-regex "^7.0.1" - is-fullwidth-code-point "^2.0.0" - strip-ansi "^5.1.0" - -string-width@^4.1.0: - version "4.2.2" - resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.2.tgz#dafd4f9559a7585cfba529c6a0a4f73488ebd4c5" - integrity sha512-XBJbT3N4JhVumXE0eoLU9DCjcaF92KLNqTmFCnG1pf8duUxFGwtP6AD6nkjw9a3IdiRtL3E2w3JDiE/xi3vOeA== - dependencies: - emoji-regex "^8.0.0" - is-fullwidth-code-point "^3.0.0" - strip-ansi "^6.0.0" - -string_decoder@~1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.1.1.tgz#9cf1611ba62685d7030ae9e4ba34149c3af03fc8" - integrity sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg== - dependencies: - safe-buffer "~5.1.0" - -strip-ansi@^3.0.0, strip-ansi@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf" - integrity sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8= - dependencies: - ansi-regex "^2.0.0" - -strip-ansi@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-4.0.0.tgz#a8479022eb1ac368a871389b635262c505ee368f" - integrity sha1-qEeQIusaw2iocTibY1JixQXuNo8= - dependencies: - ansi-regex "^3.0.0" - -strip-ansi@^5.1.0, strip-ansi@^5.2.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-5.2.0.tgz#8c9a536feb6afc962bdfa5b104a5091c1ad9c0ae" - integrity sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA== - dependencies: - ansi-regex "^4.1.0" - -strip-ansi@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.0.tgz#0b1571dd7669ccd4f3e06e14ef1eed26225ae532" - integrity sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w== - dependencies: - ansi-regex "^5.0.0" - -strip-bom@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-2.0.0.tgz#6219a85616520491f35788bdbf1447a99c7e6b0e" - integrity sha1-YhmoVhZSBJHzV4i9vxRHqZx+aw4= - dependencies: - is-utf8 "^0.2.0" - -strip-eof@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/strip-eof/-/strip-eof-1.0.0.tgz#bb43ff5598a6eb05d89b59fcd129c983313606bf" - integrity sha1-u0P/VZim6wXYm1n80SnJgzE2Br8= - -strip-json-comments@^3.0.1: - version "3.1.1" - resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" - integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== - -strip-json-comments@~2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" - integrity sha1-PFMZQukIwml8DsNEhYwobHygpgo= - -supports-color@5.4.0: - version "5.4.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.4.0.tgz#1c6b337402c2137605efe19f10fec390f6faab54" - integrity sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w== - dependencies: - has-flag "^3.0.0" - -supports-color@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7" - integrity sha1-U10EXOa2Nj+kARcIRimZXp3zJMc= - -supports-color@^3.1.0: - version "3.2.3" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-3.2.3.tgz#65ac0504b3954171d8a64946b2ae3cbb8a5f54f6" - integrity sha1-ZawFBLOVQXHYpklGsq48u4pfVPY= - dependencies: - has-flag "^1.0.0" - -supports-color@^5.3.0, supports-color@^5.4.0, supports-color@^5.5.0: - version "5.5.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" - integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== - dependencies: - has-flag "^3.0.0" - -supports-color@^7.1.0: - version "7.2.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" - integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== - dependencies: - has-flag "^4.0.0" - -sver-compat@^1.5.0: - version "1.5.0" - resolved "https://registry.yarnpkg.com/sver-compat/-/sver-compat-1.5.0.tgz#3cf87dfeb4d07b4a3f14827bc186b3fd0c645cd8" - integrity sha1-PPh9/rTQe0o/FIJ7wYaz/QxkXNg= - dependencies: - es6-iterator "^2.0.1" - es6-symbol "^3.1.1" - -table@4.0.2: - version "4.0.2" - resolved "https://registry.yarnpkg.com/table/-/table-4.0.2.tgz#a33447375391e766ad34d3486e6e2aedc84d2e36" - integrity sha512-UUkEAPdSGxtRpiV9ozJ5cMTtYiqz7Ni1OGqLXRCynrvzdtR1p+cfOWe2RJLwvUG8hNanaSRjecIqwOjqeatDsA== - dependencies: - ajv "^5.2.3" - ajv-keywords "^2.1.0" - chalk "^2.1.0" - lodash "^4.17.4" - slice-ansi "1.0.0" - string-width "^2.1.1" - -table@^5.2.3: - version "5.4.6" - resolved "https://registry.yarnpkg.com/table/-/table-5.4.6.tgz#1292d19500ce3f86053b05f0e8e7e4a3bb21079e" - integrity sha512-wmEc8m4fjnob4gt5riFRtTu/6+4rSe12TpAELNSqHMfF3IqnA+CH37USM6/YR3qRZv7e56kAEAtd6nKZaxe0Ug== - dependencies: - ajv "^6.10.2" - lodash "^4.17.14" - slice-ansi "^2.1.0" - string-width "^3.0.0" - -text-table@^0.2.0, text-table@~0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" - integrity sha1-f17oI66AUgfACvLfSoTsP8+lcLQ= - -through2-filter@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/through2-filter/-/through2-filter-3.0.0.tgz#700e786df2367c2c88cd8aa5be4cf9c1e7831254" - integrity sha512-jaRjI2WxN3W1V8/FMZ9HKIBXixtiqs3SQSX4/YGIiP3gL6djW48VoZq9tDqeCWs3MT8YY5wb/zli8VW8snY1CA== - dependencies: - through2 "~2.0.0" - xtend "~4.0.0" - -through2@^2.0.0, through2@^2.0.1, through2@^2.0.3, through2@~2.0.0: - version "2.0.5" - resolved "https://registry.yarnpkg.com/through2/-/through2-2.0.5.tgz#01c1e39eb31d07cb7d03a96a70823260b23132cd" - integrity sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ== - dependencies: - readable-stream "~2.3.6" - xtend "~4.0.1" - -through@^2.3.6: - version "2.3.8" - resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" - integrity sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU= - -time-stamp@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/time-stamp/-/time-stamp-1.1.0.tgz#764a5a11af50561921b133f3b44e618687e0f5c3" - integrity sha1-dkpaEa9QVhkhsTPztE5hhofg9cM= - -tmp@^0.0.33: - version "0.0.33" - resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.0.33.tgz#6d34335889768d21b2bcda0aa277ced3b1bfadf9" - integrity sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw== - dependencies: - os-tmpdir "~1.0.2" - -to-absolute-glob@^2.0.0: - version "2.0.2" - resolved "https://registry.yarnpkg.com/to-absolute-glob/-/to-absolute-glob-2.0.2.tgz#1865f43d9e74b0822db9f145b78cff7d0f7c849b" - integrity sha1-GGX0PZ50sIItufFFt4z/fQ98hJs= - dependencies: - is-absolute "^1.0.0" - is-negated-glob "^1.0.0" - -to-fast-properties@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz#dc5e698cbd079265bc73e0377681a4e4e83f616e" - integrity sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4= - -to-object-path@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/to-object-path/-/to-object-path-0.3.0.tgz#297588b7b0e7e0ac08e04e672f85c1f4999e17af" - integrity sha1-KXWIt7Dn4KwI4E5nL4XB9JmeF68= - dependencies: - kind-of "^3.0.2" - -to-regex-range@^2.1.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-2.1.1.tgz#7c80c17b9dfebe599e27367e0d4dd5590141db38" - integrity sha1-fIDBe53+vlmeJzZ+DU3VWQFB2zg= - dependencies: - is-number "^3.0.0" - repeat-string "^1.6.1" - -to-regex@^3.0.1, to-regex@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/to-regex/-/to-regex-3.0.2.tgz#13cfdd9b336552f30b51f33a8ae1b42a7a7599ce" - integrity sha512-FWtleNAtZ/Ki2qtqej2CXTOayOH9bHDQF+Q48VpWyDXjbYxA4Yz8iDB31zXOBUlOHHKidDbqGVrTUvQMPmBGBw== - dependencies: - define-property "^2.0.2" - extend-shallow "^3.0.2" - regex-not "^1.0.2" - safe-regex "^1.1.0" - -to-through@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/to-through/-/to-through-2.0.0.tgz#fc92adaba072647bc0b67d6b03664aa195093af6" - integrity sha1-/JKtq6ByZHvAtn1rA2ZKoZUJOvY= - dependencies: - through2 "^2.0.3" - -tough-cookie@~2.5.0: - version "2.5.0" - resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.5.0.tgz#cd9fb2a0aa1d5a12b473bd9fb96fa3dcff65ade2" - integrity sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g== - dependencies: - psl "^1.1.28" - punycode "^2.1.1" - -tslib@^1.9.0: - version "1.14.1" - resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" - integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== - -tunnel-agent@^0.6.0: - version "0.6.0" - resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.6.0.tgz#27a5dea06b36b04a0a9966774b290868f0fc40fd" - integrity sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0= - dependencies: - safe-buffer "^5.0.1" - -tweetnacl@^0.14.3, tweetnacl@~0.14.0: - version "0.14.5" - resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64" - integrity sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q= - -type-check@~0.3.2: - version "0.3.2" - resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.3.2.tgz#5884cab512cf1d355e3fb784f30804b2b520db72" - integrity sha1-WITKtRLPHTVeP7eE8wgEsrUg23I= - dependencies: - prelude-ls "~1.1.2" - -type-detect@4.0.8: - version "4.0.8" - resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c" - integrity sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g== - -type-fest@^0.21.3: - version "0.21.3" - resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.21.3.tgz#d260a24b0198436e133fa26a524a6d65fa3b2e37" - integrity sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w== - -type-fest@^0.8.1: - version "0.8.1" - resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.8.1.tgz#09e249ebde851d3b1e48d27c105444667f17b83d" - integrity sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA== - -type@^1.0.1: - version "1.2.0" - resolved "https://registry.yarnpkg.com/type/-/type-1.2.0.tgz#848dd7698dafa3e54a6c479e759c4bc3f18847a0" - integrity sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg== - -type@^2.0.0: - version "2.5.0" - resolved "https://registry.yarnpkg.com/type/-/type-2.5.0.tgz#0a2e78c2e77907b252abe5f298c1b01c63f0db3d" - integrity sha512-180WMDQaIMm3+7hGXWf12GtdniDEy7nYcyFMKJn/eZz/6tSLXrUN9V0wKSbMjej0I1WHWbpREDEKHtqPQa9NNw== - -typedarray@^0.0.6: - version "0.0.6" - resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" - integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c= - -uglify-js@^3.1.4: - version "3.13.4" - resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.13.4.tgz#592588bb9f47ae03b24916e2471218d914955574" - integrity sha512-kv7fCkIXyQIilD5/yQy8O+uagsYIOt5cZvs890W40/e/rvjMSzJw81o9Bg0tkURxzZBROtDQhW2LFjOGoK3RZw== - -unc-path-regex@^0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/unc-path-regex/-/unc-path-regex-0.1.2.tgz#e73dd3d7b0d7c5ed86fbac6b0ae7d8c6a69d50fa" - integrity sha1-5z3T17DXxe2G+6xrCufYxqadUPo= - -undertaker-registry@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/undertaker-registry/-/undertaker-registry-1.0.1.tgz#5e4bda308e4a8a2ae584f9b9a4359a499825cc50" - integrity sha1-XkvaMI5KiirlhPm5pDWaSZglzFA= - -undertaker@^1.2.1: - version "1.3.0" - resolved "https://registry.yarnpkg.com/undertaker/-/undertaker-1.3.0.tgz#363a6e541f27954d5791d6fa3c1d321666f86d18" - integrity sha512-/RXwi5m/Mu3H6IHQGww3GNt1PNXlbeCuclF2QYR14L/2CHPz3DFZkvB5hZ0N/QUkiXWCACML2jXViIQEQc2MLg== - dependencies: - arr-flatten "^1.0.1" - arr-map "^2.0.0" - bach "^1.0.0" - collection-map "^1.0.0" - es6-weak-map "^2.0.1" - fast-levenshtein "^1.0.0" - last-run "^1.1.0" - object.defaults "^1.0.0" - object.reduce "^1.0.0" - undertaker-registry "^1.0.0" - -unicode-canonical-property-names-ecmascript@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-1.0.4.tgz#2619800c4c825800efdd8343af7dd9933cbe2818" - integrity sha512-jDrNnXWHd4oHiTZnx/ZG7gtUTVp+gCcTTKr8L0HjlwphROEW3+Him+IpvC+xcJEFegapiMZyZe02CyuOnRmbnQ== - -unicode-match-property-ecmascript@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/unicode-match-property-ecmascript/-/unicode-match-property-ecmascript-1.0.4.tgz#8ed2a32569961bce9227d09cd3ffbb8fed5f020c" - integrity sha512-L4Qoh15vTfntsn4P1zqnHulG0LdXgjSO035fEpdtp6YxXhMT51Q6vgM5lYdG/5X3MjS+k/Y9Xw4SFCY9IkR0rg== - dependencies: - unicode-canonical-property-names-ecmascript "^1.0.4" - unicode-property-aliases-ecmascript "^1.0.4" - -unicode-match-property-value-ecmascript@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-1.2.0.tgz#0d91f600eeeb3096aa962b1d6fc88876e64ea531" - integrity sha512-wjuQHGQVofmSJv1uVISKLE5zO2rNGzM/KCYZch/QQvez7C1hUhBIuZ701fYXExuufJFMPhv2SyL8CyoIfMLbIQ== - -unicode-property-aliases-ecmascript@^1.0.4: - version "1.1.0" - resolved "https://registry.yarnpkg.com/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-1.1.0.tgz#dd57a99f6207bedff4628abefb94c50db941c8f4" - integrity sha512-PqSoPh/pWetQ2phoj5RLiaqIk4kCNwoV3CI+LfGmWLKI3rE3kl1h59XpX2BjgDrmbxD9ARtQobPGU1SguCYuQg== - -union-value@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/union-value/-/union-value-1.0.1.tgz#0b6fe7b835aecda61c6ea4d4f02c14221e109847" - integrity sha512-tJfXmxMeWYnczCVs7XAEvIV7ieppALdyepWMkHkwciRpZraG/xwT+s2JN8+pr1+8jCRf80FFzvr+MpQeeoF4Xg== - dependencies: - arr-union "^3.1.0" - get-value "^2.0.6" - is-extendable "^0.1.1" - set-value "^2.0.1" - -unique-stream@^2.0.2: - version "2.3.1" - resolved "https://registry.yarnpkg.com/unique-stream/-/unique-stream-2.3.1.tgz#c65d110e9a4adf9a6c5948b28053d9a8d04cbeac" - integrity sha512-2nY4TnBE70yoxHkDli7DMazpWiP7xMdCYqU2nBRO0UB+ZpEkGsSija7MvmvnZFUeC+mrgiUfcHSr3LmRFIg4+A== - dependencies: - json-stable-stringify-without-jsonify "^1.0.1" - through2-filter "^3.0.0" - -unset-value@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/unset-value/-/unset-value-1.0.0.tgz#8376873f7d2335179ffb1e6fc3a8ed0dfc8ab559" - integrity sha1-g3aHP30jNRef+x5vw6jtDfyKtVk= - dependencies: - has-value "^0.3.1" - isobject "^3.0.0" - -upath@^1.1.1: - version "1.2.0" - resolved "https://registry.yarnpkg.com/upath/-/upath-1.2.0.tgz#8f66dbcd55a883acdae4408af8b035a5044c1894" - integrity sha512-aZwGpamFO61g3OlfT7OQCHqhGnW43ieH9WZeP7QxN/G/jS4jfqUkZxoryvJgVPEcrl5NL/ggHsSmLMHuH64Lhg== - -uri-js@^4.2.2: - version "4.4.1" - resolved "https://registry.yarnpkg.com/uri-js/-/uri-js-4.4.1.tgz#9b1a52595225859e55f669d928f88c6c57f2a77e" - integrity sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg== - dependencies: - punycode "^2.1.0" - -urix@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/urix/-/urix-0.1.0.tgz#da937f7a62e21fec1fd18d49b35c2935067a6c72" - integrity sha1-2pN/emLiH+wf0Y1Js1wpNQZ6bHI= - -use@^3.1.0: - version "3.1.1" - resolved "https://registry.yarnpkg.com/use/-/use-3.1.1.tgz#d50c8cac79a19fbc20f2911f56eb973f4e10070f" - integrity sha512-cwESVXlO3url9YWlFW/TA9cshCEhtu7IKJ/p5soJ/gGpj7vbvFrAY/eIioQ6Dw23KjZhYgiIo8HOs1nQ2vr/oQ== - -util-deprecate@~1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" - integrity sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8= - -uuid@^3.3.2: - version "3.4.0" - resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.4.0.tgz#b23e4358afa8a202fe7a100af1f5f883f02007ee" - integrity sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A== - -v8-compile-cache@^2.0.3: - version "2.3.0" - resolved "https://registry.yarnpkg.com/v8-compile-cache/-/v8-compile-cache-2.3.0.tgz#2de19618c66dc247dcfb6f99338035d8245a2cee" - integrity sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA== - -v8flags@^3.2.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/v8flags/-/v8flags-3.2.0.tgz#b243e3b4dfd731fa774e7492128109a0fe66d656" - integrity sha512-mH8etigqMfiGWdeXpaaqGfs6BndypxusHHcv2qSHyZkGEznCd/qAXCWWRzeowtL54147cktFOC4P5y+kl8d8Jg== - dependencies: - homedir-polyfill "^1.0.1" - -validate-npm-package-license@^3.0.1: - version "3.0.4" - resolved "https://registry.yarnpkg.com/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz#fc91f6b9c7ba15c857f4cb2c5defeec39d4f410a" - integrity sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew== - dependencies: - spdx-correct "^3.0.0" - spdx-expression-parse "^3.0.0" - -value-or-function@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/value-or-function/-/value-or-function-3.0.0.tgz#1c243a50b595c1be54a754bfece8563b9ff8d813" - integrity sha1-HCQ6ULWVwb5Up1S/7OhWO5/42BM= - -verror@1.10.0: - version "1.10.0" - resolved "https://registry.yarnpkg.com/verror/-/verror-1.10.0.tgz#3a105ca17053af55d6e270c1f8288682e18da400" - integrity sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA= - dependencies: - assert-plus "^1.0.0" - core-util-is "1.0.2" - extsprintf "^1.2.0" - -vinyl-fs@^3.0.0: - version "3.0.3" - resolved "https://registry.yarnpkg.com/vinyl-fs/-/vinyl-fs-3.0.3.tgz#c85849405f67428feabbbd5c5dbdd64f47d31bc7" - integrity sha512-vIu34EkyNyJxmP0jscNzWBSygh7VWhqun6RmqVfXePrOwi9lhvRs//dOaGOTRUQr4tx7/zd26Tk5WeSVZitgng== - dependencies: - fs-mkdirp-stream "^1.0.0" - glob-stream "^6.1.0" - graceful-fs "^4.0.0" - is-valid-glob "^1.0.0" - lazystream "^1.0.0" - lead "^1.0.0" - object.assign "^4.0.4" - pumpify "^1.3.5" - readable-stream "^2.3.3" - remove-bom-buffer "^3.0.0" - remove-bom-stream "^1.2.0" - resolve-options "^1.1.0" - through2 "^2.0.0" - to-through "^2.0.0" - value-or-function "^3.0.0" - vinyl "^2.0.0" - vinyl-sourcemap "^1.1.0" - -vinyl-sourcemap@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/vinyl-sourcemap/-/vinyl-sourcemap-1.1.0.tgz#92a800593a38703a8cdb11d8b300ad4be63b3e16" - integrity sha1-kqgAWTo4cDqM2xHYswCtS+Y7PhY= - dependencies: - append-buffer "^1.0.2" - convert-source-map "^1.5.0" - graceful-fs "^4.1.6" - normalize-path "^2.1.1" - now-and-later "^2.0.0" - remove-bom-buffer "^3.0.0" - vinyl "^2.0.0" - -vinyl-sourcemaps-apply@^0.2.0, vinyl-sourcemaps-apply@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/vinyl-sourcemaps-apply/-/vinyl-sourcemaps-apply-0.2.1.tgz#ab6549d61d172c2b1b87be5c508d239c8ef87705" - integrity sha1-q2VJ1h0XLCsbh75cUI0jnI74dwU= - dependencies: - source-map "^0.5.1" - -vinyl@^2.0.0: - version "2.2.1" - resolved "https://registry.yarnpkg.com/vinyl/-/vinyl-2.2.1.tgz#23cfb8bbab5ece3803aa2c0a1eb28af7cbba1974" - integrity sha512-LII3bXRFBZLlezoG5FfZVcXflZgWP/4dCwKtxd5ky9+LOtM4CS3bIRQsmR1KMnMW07jpE8fqR2lcxPZ+8sJIcw== - dependencies: - clone "^2.1.1" - clone-buffer "^1.0.0" - clone-stats "^1.0.0" - cloneable-readable "^1.0.0" - remove-trailing-separator "^1.0.1" - replace-ext "^1.0.0" - -which-module@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/which-module/-/which-module-1.0.0.tgz#bba63ca861948994ff307736089e3b96026c2a4f" - integrity sha1-u6Y8qGGUiZT/MHc2CJ47lgJsKk8= - -which@^1.1.1, which@^1.2.14, which@^1.2.9: - version "1.3.1" - resolved "https://registry.yarnpkg.com/which/-/which-1.3.1.tgz#a45043d54f5805316da8d62f9f50918d3da70b0a" - integrity sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ== - dependencies: - isexe "^2.0.0" - -word-wrap@~1.2.3: - version "1.2.3" - resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c" - integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ== - -wordwrap@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" - integrity sha1-J1hIEIkUVqQXHI0CJkQa3pDLyus= - -wrap-ansi@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-2.1.0.tgz#d8fc3d284dd05794fe84973caecdd1cf824fdd85" - integrity sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU= - dependencies: - string-width "^1.0.1" - strip-ansi "^3.0.1" - -wrappy@1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" - integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= - -write@1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/write/-/write-1.0.3.tgz#0800e14523b923a387e415123c865616aae0f5c3" - integrity sha512-/lg70HAjtkUgWPVZhZcm+T4hkL8Zbtp1nFNOn3lRrxnlv50SRBv7cR7RqR+GMsd3hUXy9hWBo4CHTbFTcOYwig== - dependencies: - mkdirp "^0.5.1" - -write@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/write/-/write-0.2.1.tgz#5fc03828e264cea3fe91455476f7a3c566cb0757" - integrity sha1-X8A4KOJkzqP+kUVUdvejxWbLB1c= - dependencies: - mkdirp "^0.5.1" - -xtend@~4.0.0, xtend@~4.0.1: - version "4.0.2" - resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" - integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== - -y18n@^3.2.1: - version "3.2.2" - resolved "https://registry.yarnpkg.com/y18n/-/y18n-3.2.2.tgz#85c901bd6470ce71fc4bb723ad209b70f7f28696" - integrity sha512-uGZHXkHnhF0XeeAPgnKfPv1bgKAYyVvmNL1xlKsPYZPaIHxGti2hHqvOCQv71XMsLxu1QjergkqogUnms5D3YQ== - -yallist@^2.1.2: - version "2.1.2" - resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz#1c11f9218f076089a47dd512f93c6699a6a81d52" - integrity sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI= - -yargs-parser@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-5.0.1.tgz#7ede329c1d8cdbbe209bd25cdb990e9b1ebbb394" - integrity sha512-wpav5XYiddjXxirPoCTUPbqM0PXvJ9hiBMvuJgInvo4/lAOTZzUprArw17q2O1P2+GHhbBr18/iQwjL5Z9BqfA== - dependencies: - camelcase "^3.0.0" - object.assign "^4.1.0" - -yargs@^7.1.0: - version "7.1.2" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-7.1.2.tgz#63a0a5d42143879fdbb30370741374e0641d55db" - integrity sha512-ZEjj/dQYQy0Zx0lgLMLR8QuaqTihnxirir7EwUHp1Axq4e3+k8jXU5K0VLbNvedv1f4EWtBonDIZm0NUr+jCcA== - dependencies: - camelcase "^3.0.0" - cliui "^3.2.0" - decamelize "^1.1.1" - get-caller-file "^1.0.1" - os-locale "^1.4.0" - read-pkg-up "^1.0.1" - require-directory "^2.1.1" - require-main-filename "^1.0.1" - set-blocking "^2.0.0" - string-width "^1.0.2" - which-module "^1.0.0" - y18n "^3.2.1" - yargs-parser "^5.0.1" +# This file is generated by running "yarn install" inside your project. +# Manual changes might be lost - proceed with caution! + +__metadata: + version: 5 + cacheKey: 8 + +"@babel/code-frame@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/code-frame@npm:7.16.7" + dependencies: + "@babel/highlight": ^7.16.7 + checksum: db2f7faa31bc2c9cf63197b481b30ea57147a5fc1a6fab60e5d6c02cdfbf6de8e17b5121f99917b3dabb5eeb572da078312e70697415940383efc140d4e0808b + languageName: node + linkType: hard + +"@babel/compat-data@npm:^7.16.4": + version: 7.16.8 + resolution: "@babel/compat-data@npm:7.16.8" + checksum: 10da2dac5ea9589c251412b00920889910e476c1ab24cd7095577635bc3a27c785151c89db4e26285fd39f509510ec29ab9d7e721f4fc16e4aec221cacde784b + languageName: node + linkType: hard + +"@babel/core@npm:^7.7.5": + version: 7.16.12 + resolution: "@babel/core@npm:7.16.12" + dependencies: + "@babel/code-frame": ^7.16.7 + "@babel/generator": ^7.16.8 + "@babel/helper-compilation-targets": ^7.16.7 + "@babel/helper-module-transforms": ^7.16.7 + "@babel/helpers": ^7.16.7 + "@babel/parser": ^7.16.12 + "@babel/template": ^7.16.7 + "@babel/traverse": ^7.16.10 + "@babel/types": ^7.16.8 + convert-source-map: ^1.7.0 + debug: ^4.1.0 + gensync: ^1.0.0-beta.2 + json5: ^2.1.2 + semver: ^6.3.0 + source-map: ^0.5.0 + checksum: 29b56f3cb7c329fc038a2efaccf64ac3025835676b3d90f57f2265b6acd477a970114d09021b38d019ac8f20b2bb1596a9e79ce1f820d6b8cf0e4a802891817c + languageName: node + linkType: hard + +"@babel/generator@npm:^7.16.8": + version: 7.16.8 + resolution: "@babel/generator@npm:7.16.8" + dependencies: + "@babel/types": ^7.16.8 + jsesc: ^2.5.1 + source-map: ^0.5.0 + checksum: 83af38b34735605c9d5f774c87a46c2cffaf666b28e9eeba883b2d7076412257e5c2264c26d9740ce44da6955fdaf857659391db02c012714a2a6dc19e403105 + languageName: node + linkType: hard + +"@babel/helper-compilation-targets@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-compilation-targets@npm:7.16.7" + dependencies: + "@babel/compat-data": ^7.16.4 + "@babel/helper-validator-option": ^7.16.7 + browserslist: ^4.17.5 + semver: ^6.3.0 + peerDependencies: + "@babel/core": ^7.0.0 + checksum: 7238aaee78c011a42fb5ca92e5eff098752f7b314c2111d7bb9cdd58792fcab1b9c819b59f6a0851dc210dc09dc06b30d130a23982753e70eb3111bc65204842 + languageName: node + linkType: hard + +"@babel/helper-environment-visitor@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-environment-visitor@npm:7.16.7" + dependencies: + "@babel/types": ^7.16.7 + checksum: c03a10105d9ebd1fe632a77356b2e6e2f3c44edba9a93b0dc3591b6a66bd7a2e323dd9502f9ce96fc6401234abff1907aa877b6674f7826b61c953f7c8204bbe + languageName: node + linkType: hard + +"@babel/helper-function-name@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-function-name@npm:7.16.7" + dependencies: + "@babel/helper-get-function-arity": ^7.16.7 + "@babel/template": ^7.16.7 + "@babel/types": ^7.16.7 + checksum: fc77cbe7b10cfa2a262d7a37dca575c037f20419dfe0c5d9317f589599ca24beb5f5c1057748011159149eaec47fe32338c6c6412376fcded68200df470161e1 + languageName: node + linkType: hard + +"@babel/helper-get-function-arity@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-get-function-arity@npm:7.16.7" + dependencies: + "@babel/types": ^7.16.7 + checksum: 25d969fb207ff2ad5f57a90d118f6c42d56a0171022e200aaa919ba7dc95ae7f92ec71cdea6c63ef3629a0dc962ab4c78e09ca2b437185ab44539193f796e0c3 + languageName: node + linkType: hard + +"@babel/helper-hoist-variables@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-hoist-variables@npm:7.16.7" + dependencies: + "@babel/types": ^7.16.7 + checksum: 6ae1641f4a751cd9045346e3f61c3d9ec1312fd779ab6d6fecfe2a96e59a481ad5d7e40d2a840894c13b3fd6114345b157f9e3062fc5f1580f284636e722de60 + languageName: node + linkType: hard + +"@babel/helper-module-imports@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-module-imports@npm:7.16.7" + dependencies: + "@babel/types": ^7.16.7 + checksum: ddd2c4a600a2e9a4fee192ab92bf35a627c5461dbab4af31b903d9ba4d6b6e59e0ff3499fde4e2e9a0eebe24906f00b636f8b4d9bd72ff24d50e6618215c3212 + languageName: node + linkType: hard + +"@babel/helper-module-transforms@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-module-transforms@npm:7.16.7" + dependencies: + "@babel/helper-environment-visitor": ^7.16.7 + "@babel/helper-module-imports": ^7.16.7 + "@babel/helper-simple-access": ^7.16.7 + "@babel/helper-split-export-declaration": ^7.16.7 + "@babel/helper-validator-identifier": ^7.16.7 + "@babel/template": ^7.16.7 + "@babel/traverse": ^7.16.7 + "@babel/types": ^7.16.7 + checksum: 6e930ce776c979f299cdbeaf80187f4ab086d75287b96ecc1c6896d392fcb561065f0d6219fc06fa79b4ceb4bbdc1a9847da8099aba9b077d0a9e583500fb673 + languageName: node + linkType: hard + +"@babel/helper-simple-access@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-simple-access@npm:7.16.7" + dependencies: + "@babel/types": ^7.16.7 + checksum: 8d22c46c5ec2ead0686c4d5a3d1d12b5190c59be676bfe0d9d89df62b437b51d1a3df2ccfb8a77dded2e585176ebf12986accb6d45a18cff229eef3b10344f4b + languageName: node + linkType: hard + +"@babel/helper-split-export-declaration@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-split-export-declaration@npm:7.16.7" + dependencies: + "@babel/types": ^7.16.7 + checksum: e10aaf135465c55114627951b79115f24bc7af72ecbb58d541d66daf1edaee5dde7cae3ec8c3639afaf74526c03ae3ce723444e3b5b3dc77140c456cd84bcaa1 + languageName: node + linkType: hard + +"@babel/helper-validator-identifier@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-validator-identifier@npm:7.16.7" + checksum: dbb3db9d184343152520a209b5684f5e0ed416109cde82b428ca9c759c29b10c7450657785a8b5c5256aa74acc6da491c1f0cf6b784939f7931ef82982051b69 + languageName: node + linkType: hard + +"@babel/helper-validator-option@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-validator-option@npm:7.16.7" + checksum: c5ccc451911883cc9f12125d47be69434f28094475c1b9d2ada7c3452e6ac98a1ee8ddd364ca9e3f9855fcdee96cdeafa32543ebd9d17fee7a1062c202e80570 + languageName: node + linkType: hard + +"@babel/helpers@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helpers@npm:7.16.7" + dependencies: + "@babel/template": ^7.16.7 + "@babel/traverse": ^7.16.7 + "@babel/types": ^7.16.7 + checksum: 75504c76b66a29b91f954fcc0867dfe275a4cfba5b44df6d64405df74ea72f967fccfa63d62c31c423c5502d113290000c581e0e4858a214f0303d7ecf55c29f + languageName: node + linkType: hard + +"@babel/highlight@npm:^7.16.7": + version: 7.16.10 + resolution: "@babel/highlight@npm:7.16.10" + dependencies: + "@babel/helper-validator-identifier": ^7.16.7 + chalk: ^2.0.0 + js-tokens: ^4.0.0 + checksum: 1f1bdd752a90844f4efc22166a46303fb651ba0fd75a06daba3ebae2575ab3edc1da9827c279872a3aaf305f50a18473c5fa1966752726a2b253065fd4c0745e + languageName: node + linkType: hard + +"@babel/parser@npm:^7.16.10, @babel/parser@npm:^7.16.12, @babel/parser@npm:^7.16.7": + version: 7.16.12 + resolution: "@babel/parser@npm:7.16.12" + bin: + parser: ./bin/babel-parser.js + checksum: af287f0f3dfa564958a7dddfeb62e08c0de9ce9bd8447fcde0997da26ec477bf19f37161b9d970e2c7e0d1f77e441258907d3347beddd0d42cae85ed46947703 + languageName: node + linkType: hard + +"@babel/template@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/template@npm:7.16.7" + dependencies: + "@babel/code-frame": ^7.16.7 + "@babel/parser": ^7.16.7 + "@babel/types": ^7.16.7 + checksum: 10cd112e89276e00f8b11b55a51c8b2f1262c318283a980f4d6cdb0286dc05734b9aaeeb9f3ad3311900b09bc913e02343fcaa9d4a4f413964aaab04eb84ac4a + languageName: node + linkType: hard + +"@babel/traverse@npm:^7.16.10, @babel/traverse@npm:^7.16.7": + version: 7.16.10 + resolution: "@babel/traverse@npm:7.16.10" + dependencies: + "@babel/code-frame": ^7.16.7 + "@babel/generator": ^7.16.8 + "@babel/helper-environment-visitor": ^7.16.7 + "@babel/helper-function-name": ^7.16.7 + "@babel/helper-hoist-variables": ^7.16.7 + "@babel/helper-split-export-declaration": ^7.16.7 + "@babel/parser": ^7.16.10 + "@babel/types": ^7.16.8 + debug: ^4.1.0 + globals: ^11.1.0 + checksum: 58f52314f8a02157cd3004712e703e6b22dff57cee4bc1ab1954c511c6f885fd7763ea68d2d5f006891bc7b77b1f2e9c8c7cb0354f580c8343d5559ed971d087 + languageName: node + linkType: hard + +"@babel/types@npm:^7.16.7, @babel/types@npm:^7.16.8, @babel/types@npm:^7.8.3": + version: 7.16.8 + resolution: "@babel/types@npm:7.16.8" + dependencies: + "@babel/helper-validator-identifier": ^7.16.7 + to-fast-properties: ^2.0.0 + checksum: 4f6a187b2924df70e21d6e6c0822f91b1b936fe060bc92bb477b93bd8a712c88fe41a73f85c0ec53b033353374fe33e773b04ffc340ad36afd8f647dd05c4ee1 + languageName: node + linkType: hard + +"@cspotcode/source-map-consumer@npm:0.8.0": + version: 0.8.0 + resolution: "@cspotcode/source-map-consumer@npm:0.8.0" + checksum: c0c16ca3d2f58898f1bd74c4f41a189dbcc202e642e60e489cbcc2e52419c4e89bdead02c886a12fb13ea37798ede9e562b2321df997ebc210ae9bd881561b4e + languageName: node + linkType: hard + +"@cspotcode/source-map-support@npm:0.7.0": + version: 0.7.0 + resolution: "@cspotcode/source-map-support@npm:0.7.0" + dependencies: + "@cspotcode/source-map-consumer": 0.8.0 + checksum: 9faddda7757cd778b5fd6812137b2cc265810043680d6399acc20441668fafcdc874053be9dccd0d9110087287bfad27eb3bf342f72bceca9aa9059f5d0c4be8 + languageName: node + linkType: hard + +"@eslint/eslintrc@npm:^1.0.5": + version: 1.0.5 + resolution: "@eslint/eslintrc@npm:1.0.5" + dependencies: + ajv: ^6.12.4 + debug: ^4.3.2 + espree: ^9.2.0 + globals: ^13.9.0 + ignore: ^4.0.6 + import-fresh: ^3.2.1 + js-yaml: ^4.1.0 + minimatch: ^3.0.4 + strip-json-comments: ^3.1.1 + checksum: b35b50d7b65bd8acd92a05b6fb15ac62c0cefa40dfef0324ca5bf8632bf3679bab6e173c53b3ad1e1d837701cecdbd9c144b35f46588cdf4e046a9caa272488d + languageName: node + linkType: hard + +"@gar/promisify@npm:^1.0.1": + version: 1.1.2 + resolution: "@gar/promisify@npm:1.1.2" + checksum: d05081e0887a49c178b75ee3067bd6ee086f73c154d121b854fb2e044e8a89cb1cbb6de3a0dd93a519b80f0531fda68b099dd7256205f7fbb3490324342f2217 + languageName: node + linkType: hard + +"@humanwhocodes/config-array@npm:^0.9.2": + version: 0.9.2 + resolution: "@humanwhocodes/config-array@npm:0.9.2" + dependencies: + "@humanwhocodes/object-schema": ^1.2.1 + debug: ^4.1.1 + minimatch: ^3.0.4 + checksum: 28a9e2974c50a86765cb6cc96e03d29187ea33fdaba62c4f35db89002e3cfbd340e64c9f6cf869e33e2e5cdcc06e78763458f4178d38a6f30aea1308787ca706 + languageName: node + linkType: hard + +"@humanwhocodes/object-schema@npm:^1.2.1": + version: 1.2.1 + resolution: "@humanwhocodes/object-schema@npm:1.2.1" + checksum: a824a1ec31591231e4bad5787641f59e9633827d0a2eaae131a288d33c9ef0290bd16fda8da6f7c0fcb014147865d12118df10db57f27f41e20da92369fcb3f1 + languageName: node + linkType: hard + +"@istanbuljs/load-nyc-config@npm:^1.0.0": + version: 1.1.0 + resolution: "@istanbuljs/load-nyc-config@npm:1.1.0" + dependencies: + camelcase: ^5.3.1 + find-up: ^4.1.0 + get-package-type: ^0.1.0 + js-yaml: ^3.13.1 + resolve-from: ^5.0.0 + checksum: d578da5e2e804d5c93228450a1380e1a3c691de4953acc162f387b717258512a3e07b83510a936d9fab03eac90817473917e24f5d16297af3867f59328d58568 + languageName: node + linkType: hard + +"@istanbuljs/nyc-config-typescript@npm:^1.0.2": + version: 1.0.2 + resolution: "@istanbuljs/nyc-config-typescript@npm:1.0.2" + dependencies: + "@istanbuljs/schema": ^0.1.2 + peerDependencies: + nyc: ">=15" + checksum: df6f9c9b17df8f1d8813f768c11ca31ec125d60bcd82d8273a467022e414d2d686ee80abb7b0f0e3c512b7ed686771fadb7fb5be8881619b9f6cb1f31b86e9f3 + languageName: node + linkType: hard + +"@istanbuljs/schema@npm:^0.1.2": + version: 0.1.3 + resolution: "@istanbuljs/schema@npm:0.1.3" + checksum: 5282759d961d61350f33d9118d16bcaed914ebf8061a52f4fa474b2cb08720c9c81d165e13b82f2e5a8a212cc5af482f0c6fc1ac27b9e067e5394c9a6ed186c9 + languageName: node + linkType: hard + +"@nodelib/fs.scandir@npm:2.1.5": + version: 2.1.5 + resolution: "@nodelib/fs.scandir@npm:2.1.5" + dependencies: + "@nodelib/fs.stat": 2.0.5 + run-parallel: ^1.1.9 + checksum: a970d595bd23c66c880e0ef1817791432dbb7acbb8d44b7e7d0e7a22f4521260d4a83f7f9fd61d44fda4610105577f8f58a60718105fb38352baed612fd79e59 + languageName: node + linkType: hard + +"@nodelib/fs.stat@npm:2.0.5, @nodelib/fs.stat@npm:^2.0.2": + version: 2.0.5 + resolution: "@nodelib/fs.stat@npm:2.0.5" + checksum: 012480b5ca9d97bff9261571dbbec7bbc6033f69cc92908bc1ecfad0792361a5a1994bc48674b9ef76419d056a03efadfce5a6cf6dbc0a36559571a7a483f6f0 + languageName: node + linkType: hard + +"@nodelib/fs.walk@npm:^1.2.3": + version: 1.2.8 + resolution: "@nodelib/fs.walk@npm:1.2.8" + dependencies: + "@nodelib/fs.scandir": 2.1.5 + fastq: ^1.6.0 + checksum: 190c643f156d8f8f277bf2a6078af1ffde1fd43f498f187c2db24d35b4b4b5785c02c7dc52e356497b9a1b65b13edc996de08de0b961c32844364da02986dc53 + languageName: node + linkType: hard + +"@npmcli/fs@npm:^1.0.0": + version: 1.1.0 + resolution: "@npmcli/fs@npm:1.1.0" + dependencies: + "@gar/promisify": ^1.0.1 + semver: ^7.3.5 + checksum: e435b883b4f8da8c95a820f458cabb7d86582406eed5ad79fc689000d3e2df17e1f475c4903627272c001357cabc70d8b4c62520cbdae8cfab1dfdd51949f408 + languageName: node + linkType: hard + +"@npmcli/move-file@npm:^1.0.1": + version: 1.1.2 + resolution: "@npmcli/move-file@npm:1.1.2" + dependencies: + mkdirp: ^1.0.4 + rimraf: ^3.0.2 + checksum: c96381d4a37448ea280951e46233f7e541058cf57a57d4094dd4bdcaae43fa5872b5f2eb6bfb004591a68e29c5877abe3cdc210cb3588cbf20ab2877f31a7de7 + languageName: node + linkType: hard + +"@sinonjs/commons@npm:^1, @sinonjs/commons@npm:^1.3.0, @sinonjs/commons@npm:^1.4.0, @sinonjs/commons@npm:^1.7.0": + version: 1.8.3 + resolution: "@sinonjs/commons@npm:1.8.3" + dependencies: + type-detect: 4.0.8 + checksum: 6159726db5ce6bf9f2297f8427f7ca5b3dff45b31e5cee23496f1fa6ef0bb4eab878b23fb2c5e6446381f6a66aba4968ef2fc255c1180d753d4b8c271636a2e5 + languageName: node + linkType: hard + +"@sinonjs/fake-timers@npm:^7.1.0": + version: 7.1.2 + resolution: "@sinonjs/fake-timers@npm:7.1.2" + dependencies: + "@sinonjs/commons": ^1.7.0 + checksum: c84773d7973edad5511a31d2cc75023447b5cf714a84de9bb50eda45dda88a0d3bd2c30bf6e6e936da50a048d5352e2151c694e13e59b97d187ba1f329e9a00c + languageName: node + linkType: hard + +"@sinonjs/formatio@npm:^3.2.1": + version: 3.2.2 + resolution: "@sinonjs/formatio@npm:3.2.2" + dependencies: + "@sinonjs/commons": ^1 + "@sinonjs/samsam": ^3.1.0 + checksum: ddc30698df9b0aa59204da93ca94fd04bc5672ac03c798c0a487c35d514d7d8e0ce0e4c72386fc80e29f59cb1cc54eeea3b7f804281b3c4e3dd2394de56c6e4a + languageName: node + linkType: hard + +"@sinonjs/samsam@npm:^3.1.0, @sinonjs/samsam@npm:^3.3.3": + version: 3.3.3 + resolution: "@sinonjs/samsam@npm:3.3.3" + dependencies: + "@sinonjs/commons": ^1.3.0 + array-from: ^2.1.1 + lodash: ^4.17.15 + checksum: 340f2f62dec3fa1e5e9300a75996bd12ab9d2da4f6b453fa5d1ee101cc5e58eb218af2e2584b496d41ba31c3c0854d47a691fd9a0d8b9092f3cb6a5c7a080856 + languageName: node + linkType: hard + +"@sinonjs/text-encoding@npm:^0.7.1": + version: 0.7.1 + resolution: "@sinonjs/text-encoding@npm:0.7.1" + checksum: 130de0bb568c5f8a611ec21d1a4e3f80ab0c5ec333010f49cfc1adc5cba6d8808699c8a587a46b0f0b016a1f4c1389bc96141e773e8460fcbb441875b2e91ba7 + languageName: node + linkType: hard + +"@tootallnate/once@npm:1": + version: 1.1.2 + resolution: "@tootallnate/once@npm:1.1.2" + checksum: e1fb1bbbc12089a0cb9433dc290f97bddd062deadb6178ce9bcb93bb7c1aecde5e60184bc7065aec42fe1663622a213493c48bbd4972d931aae48315f18e1be9 + languageName: node + linkType: hard + +"@tsconfig/node10@npm:^1.0.7": + version: 1.0.8 + resolution: "@tsconfig/node10@npm:1.0.8" + checksum: b8d5fffbc6b17ef64ef74f7fdbccee02a809a063ade785c3648dae59406bc207f70ea2c4296f92749b33019fa36a5ae716e42e49cc7f1bbf0fd147be0d6b970a + languageName: node + linkType: hard + +"@tsconfig/node12@npm:^1.0.7": + version: 1.0.9 + resolution: "@tsconfig/node12@npm:1.0.9" + checksum: a01b2400ab3582b86b589c6d31dcd0c0656f333adecde85d6d7d4086adb059808b82692380bb169546d189bf771ae21d02544a75b57bd6da4a5dd95f8567bec9 + languageName: node + linkType: hard + +"@tsconfig/node14@npm:^1.0.0": + version: 1.0.1 + resolution: "@tsconfig/node14@npm:1.0.1" + checksum: 976345e896c0f059867f94f8d0f6ddb8b1844fb62bf36b727de8a9a68f024857e5db97ed51d3325e23e0616a5e48c034ff51a8d595b3fe7e955f3587540489be + languageName: node + linkType: hard + +"@tsconfig/node16@npm:^1.0.2": + version: 1.0.2 + resolution: "@tsconfig/node16@npm:1.0.2" + checksum: ca94d3639714672bbfd55f03521d3f56bb6a25479bd425da81faf21f13e1e9d15f40f97377dedbbf477a5841c5b0c8f4cd1b391f33553d750b9202c54c2c07aa + languageName: node + linkType: hard + +"@types/json-schema@npm:^7.0.9": + version: 7.0.9 + resolution: "@types/json-schema@npm:7.0.9" + checksum: 259d0e25f11a21ba5c708f7ea47196bd396e379fddb79c76f9f4f62c945879dc21657904914313ec2754e443c5018ea8372362f323f30e0792897fdb2098a705 + languageName: node + linkType: hard + +"@types/lodash@npm:^4.14.176": + version: 4.14.178 + resolution: "@types/lodash@npm:4.14.178" + checksum: a69a04a60bfc5257c3130a554b4efa0c383f0141b7b3db8ab7cf07ad2a46ea085fce66d0242da41da7e5647b133d5dfb2c15add9cbed8d7fef955e4a1e5b3128 + languageName: node + linkType: hard + +"@types/mocha@npm:^9.1.0": + version: 9.1.0 + resolution: "@types/mocha@npm:9.1.0" + checksum: 21e1000dafcfe387c6812be41c44a47b48c27a74d5a70c3d5ef1bb5c88eadadfc74dba06e93f160e7248c8a57b3977b590f82504c801c9927816ecd4668023c0 + languageName: node + linkType: hard + +"@types/node@npm:^16.11.6": + version: 16.11.21 + resolution: "@types/node@npm:16.11.21" + checksum: 75b679dc6375cf09bc14a2d1b344be6f3fd8ea50f212b0d60970dc9e175cef45e44c284c716eb9e766ffa52d0c83b689adb3d1911b6dd8649c560b8f77442a22 + languageName: node + linkType: hard + +"@types/sinon@npm:^10.0.6": + version: 10.0.8 + resolution: "@types/sinon@npm:10.0.8" + dependencies: + "@sinonjs/fake-timers": ^7.1.0 + checksum: 76a00bc4e80a90c15b0691387703a85274d80e96a133281e993214488a47020ca0d0957a924f87468b4b6ade3465edd39ac2a451daea7d0f6f07ac352bc29309 + languageName: node + linkType: hard + +"@typescript-eslint/eslint-plugin@npm:^5.7.0": + version: 5.10.0 + resolution: "@typescript-eslint/eslint-plugin@npm:5.10.0" + dependencies: + "@typescript-eslint/scope-manager": 5.10.0 + "@typescript-eslint/type-utils": 5.10.0 + "@typescript-eslint/utils": 5.10.0 + debug: ^4.3.2 + functional-red-black-tree: ^1.0.1 + ignore: ^5.1.8 + regexpp: ^3.2.0 + semver: ^7.3.5 + tsutils: ^3.21.0 + peerDependencies: + "@typescript-eslint/parser": ^5.0.0 + eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + peerDependenciesMeta: + typescript: + optional: true + checksum: 675b79c519e5287a184720317d309c55e308c19eb52f1f062e3851168a9b6e4768363bd31bdcbf897c080f1c21cb39736cd522408620818dd9ce483d1573bf89 + languageName: node + linkType: hard + +"@typescript-eslint/parser@npm:^5.7.0": + version: 5.10.0 + resolution: "@typescript-eslint/parser@npm:5.10.0" + dependencies: + "@typescript-eslint/scope-manager": 5.10.0 + "@typescript-eslint/types": 5.10.0 + "@typescript-eslint/typescript-estree": 5.10.0 + debug: ^4.3.2 + peerDependencies: + eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + peerDependenciesMeta: + typescript: + optional: true + checksum: 127aaa807659bbd4b2b274263d1ef821b8d0746f0a18ae55466718d070ba43c94e5575849954271f0d6582d2114c96a0ff6645189015a6522c4d8682d4d20a1b + languageName: node + linkType: hard + +"@typescript-eslint/scope-manager@npm:5.10.0": + version: 5.10.0 + resolution: "@typescript-eslint/scope-manager@npm:5.10.0" + dependencies: + "@typescript-eslint/types": 5.10.0 + "@typescript-eslint/visitor-keys": 5.10.0 + checksum: 934cbb4a03d383537fda05b926eeba0597d63ef1c65328d55abe20a060b6559ba2017825e167dc2093a23d675c37aaa2056dec1747b17f0fbca419fba68f8d0f + languageName: node + linkType: hard + +"@typescript-eslint/type-utils@npm:5.10.0": + version: 5.10.0 + resolution: "@typescript-eslint/type-utils@npm:5.10.0" + dependencies: + "@typescript-eslint/utils": 5.10.0 + debug: ^4.3.2 + tsutils: ^3.21.0 + peerDependencies: + eslint: "*" + peerDependenciesMeta: + typescript: + optional: true + checksum: aa6bf7fcac7aa956ccf938b8d93d1ecd8956ea1f5690046967fe69f0bd2592cd8e29a992f5a252990b8e13c1e09c3f9efb6375d0551f4b4c08c69cd662be2e73 + languageName: node + linkType: hard + +"@typescript-eslint/types@npm:5.10.0": + version: 5.10.0 + resolution: "@typescript-eslint/types@npm:5.10.0" + checksum: 269988cbb1772616ade3af5f70a3c4d7871c90fa04fbc4ed8b1148ec0a6853f2d51609fe51aa797486bfe9b704a4c4a3410e6225470db18850d3469a7db5a63b + languageName: node + linkType: hard + +"@typescript-eslint/typescript-estree@npm:5.10.0": + version: 5.10.0 + resolution: "@typescript-eslint/typescript-estree@npm:5.10.0" + dependencies: + "@typescript-eslint/types": 5.10.0 + "@typescript-eslint/visitor-keys": 5.10.0 + debug: ^4.3.2 + globby: ^11.0.4 + is-glob: ^4.0.3 + semver: ^7.3.5 + tsutils: ^3.21.0 + peerDependenciesMeta: + typescript: + optional: true + checksum: 1097fd5a96857a285020a2c5ee7abb7e5984771ac44b61b5d500724dc3ff88030e4e5340fcd872779b1307fbb224240d6543babb901559675efcab20a2dc70dc + languageName: node + linkType: hard + +"@typescript-eslint/utils@npm:5.10.0": + version: 5.10.0 + resolution: "@typescript-eslint/utils@npm:5.10.0" + dependencies: + "@types/json-schema": ^7.0.9 + "@typescript-eslint/scope-manager": 5.10.0 + "@typescript-eslint/types": 5.10.0 + "@typescript-eslint/typescript-estree": 5.10.0 + eslint-scope: ^5.1.1 + eslint-utils: ^3.0.0 + peerDependencies: + eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + checksum: 9c53b0e47b922210c5dc0c7ac045206062ad4f21f9bf03ef091894d3fcfe9fde7e72c70a97b5073a54a42b7628943dd8dcef00bd3285ebd63039909888dea84a + languageName: node + linkType: hard + +"@typescript-eslint/visitor-keys@npm:5.10.0": + version: 5.10.0 + resolution: "@typescript-eslint/visitor-keys@npm:5.10.0" + dependencies: + "@typescript-eslint/types": 5.10.0 + eslint-visitor-keys: ^3.0.0 + checksum: 9b99c6be709c59be6a1705f0244aad732a5e523af8b8eb87e5dd6a3d27a027329bf2617aa6f15a36f79bce4215ac09277e144737a0d8d674e93b073b36fd963e + languageName: node + linkType: hard + +"@ungap/promise-all-settled@npm:1.1.2": + version: 1.1.2 + resolution: "@ungap/promise-all-settled@npm:1.1.2" + checksum: 08d37fdfa23a6fe8139f1305313562ebad973f3fac01bcce2773b2bda5bcb0146dfdcf3cb6a722cf0a5f2ca0bc56a827eac8f1e7b3beddc548f654addf1fc34c + languageName: node + linkType: hard + +"abbrev@npm:1": + version: 1.1.1 + resolution: "abbrev@npm:1.1.1" + checksum: a4a97ec07d7ea112c517036882b2ac22f3109b7b19077dc656316d07d308438aac28e4d9746dc4d84bf6b1e75b4a7b0a5f3cb30592419f128ca9a8cee3bcfa17 + languageName: node + linkType: hard + +"acorn-jsx@npm:^5.3.1": + version: 5.3.2 + resolution: "acorn-jsx@npm:5.3.2" + peerDependencies: + acorn: ^6.0.0 || ^7.0.0 || ^8.0.0 + checksum: c3d3b2a89c9a056b205b69530a37b972b404ee46ec8e5b341666f9513d3163e2a4f214a71f4dfc7370f5a9c07472d2fd1c11c91c3f03d093e37637d95da98950 + languageName: node + linkType: hard + +"acorn-walk@npm:^8.1.1": + version: 8.2.0 + resolution: "acorn-walk@npm:8.2.0" + checksum: 1715e76c01dd7b2d4ca472f9c58968516a4899378a63ad5b6c2d668bba8da21a71976c14ec5f5b75f887b6317c4ae0b897ab141c831d741dc76024d8745f1ad1 + languageName: node + linkType: hard + +"acorn@npm:^8.4.1, acorn@npm:^8.7.0": + version: 8.7.0 + resolution: "acorn@npm:8.7.0" + bin: + acorn: bin/acorn + checksum: e0f79409d68923fbf1aa6d4166f3eedc47955320d25c89a20cc822e6ba7c48c5963d5bc657bc242d68f7a4ac9faf96eef033e8f73656da6c640d4219935fdfd0 + languageName: node + linkType: hard + +"agent-base@npm:6, agent-base@npm:^6.0.2": + version: 6.0.2 + resolution: "agent-base@npm:6.0.2" + dependencies: + debug: 4 + checksum: f52b6872cc96fd5f622071b71ef200e01c7c4c454ee68bc9accca90c98cfb39f2810e3e9aa330435835eedc8c23f4f8a15267f67c6e245d2b33757575bdac49d + languageName: node + linkType: hard + +"agentkeepalive@npm:^4.1.3": + version: 4.2.0 + resolution: "agentkeepalive@npm:4.2.0" + dependencies: + debug: ^4.1.0 + depd: ^1.1.2 + humanize-ms: ^1.2.1 + checksum: 89806f83ceebbcaabf6bd581a8dce4870910fd2a11f66df8f505b4cd4ce4ca5ab9e6eec8d11ce8531a6b60f6748b75b0775e0e2fa33871503ef00d535418a19a + languageName: node + linkType: hard + +"aggregate-error@npm:^3.0.0": + version: 3.1.0 + resolution: "aggregate-error@npm:3.1.0" + dependencies: + clean-stack: ^2.0.0 + indent-string: ^4.0.0 + checksum: 1101a33f21baa27a2fa8e04b698271e64616b886795fd43c31068c07533c7b3facfcaf4e9e0cab3624bd88f729a592f1c901a1a229c9e490eafce411a8644b79 + languageName: node + linkType: hard + +"ajv@npm:^6.10.0, ajv@npm:^6.12.4": + version: 6.12.6 + resolution: "ajv@npm:6.12.6" + dependencies: + fast-deep-equal: ^3.1.1 + fast-json-stable-stringify: ^2.0.0 + json-schema-traverse: ^0.4.1 + uri-js: ^4.2.2 + checksum: 874972efe5c4202ab0a68379481fbd3d1b5d0a7bd6d3cc21d40d3536ebff3352a2a1fabb632d4fd2cc7fe4cbdcd5ed6782084c9bbf7f32a1536d18f9da5007d4 + languageName: node + linkType: hard + +"ansi-colors@npm:4.1.1": + version: 4.1.1 + resolution: "ansi-colors@npm:4.1.1" + checksum: 138d04a51076cb085da0a7e2d000c5c0bb09f6e772ed5c65c53cb118d37f6c5f1637506d7155fb5f330f0abcf6f12fa2e489ac3f8cdab9da393bf1bb4f9a32b0 + languageName: node + linkType: hard + +"ansi-regex@npm:^5.0.1": + version: 5.0.1 + resolution: "ansi-regex@npm:5.0.1" + checksum: 2aa4bb54caf2d622f1afdad09441695af2a83aa3fe8b8afa581d205e57ed4261c183c4d3877cee25794443fde5876417d859c108078ab788d6af7e4fe52eb66b + languageName: node + linkType: hard + +"ansi-styles@npm:^3.2.1": + version: 3.2.1 + resolution: "ansi-styles@npm:3.2.1" + dependencies: + color-convert: ^1.9.0 + checksum: d85ade01c10e5dd77b6c89f34ed7531da5830d2cb5882c645f330079975b716438cd7ebb81d0d6e6b4f9c577f19ae41ab55f07f19786b02f9dfd9e0377395665 + languageName: node + linkType: hard + +"ansi-styles@npm:^4.0.0, ansi-styles@npm:^4.1.0": + version: 4.3.0 + resolution: "ansi-styles@npm:4.3.0" + dependencies: + color-convert: ^2.0.1 + checksum: 513b44c3b2105dd14cc42a19271e80f386466c4be574bccf60b627432f9198571ebf4ab1e4c3ba17347658f4ee1711c163d574248c0c1cdc2d5917a0ad582ec4 + languageName: node + linkType: hard + +"anymatch@npm:~3.1.2": + version: 3.1.2 + resolution: "anymatch@npm:3.1.2" + dependencies: + normalize-path: ^3.0.0 + picomatch: ^2.0.4 + checksum: 985163db2292fac9e5a1e072bf99f1b5baccf196e4de25a0b0b81865ebddeb3b3eb4480734ef0a2ac8c002845396b91aa89121f5b84f93981a4658164a9ec6e9 + languageName: node + linkType: hard + +"append-transform@npm:^2.0.0": + version: 2.0.0 + resolution: "append-transform@npm:2.0.0" + dependencies: + default-require-extensions: ^3.0.0 + checksum: f26f393bf7a428fd1bb18f2758a819830a582243310c5170edb3f98fdc5a535333d02b952f7c2d9b14522bd8ead5b132a0b15000eca18fa9f49172963ebbc231 + languageName: node + linkType: hard + +"aproba@npm:^1.0.3 || ^2.0.0": + version: 2.0.0 + resolution: "aproba@npm:2.0.0" + checksum: 5615cadcfb45289eea63f8afd064ab656006361020e1735112e346593856f87435e02d8dcc7ff0d11928bc7d425f27bc7c2a84f6c0b35ab0ff659c814c138a24 + languageName: node + linkType: hard + +"archy@npm:^1.0.0": + version: 1.0.0 + resolution: "archy@npm:1.0.0" + checksum: 504ae7af655130bab9f471343cfdb054feaec7d8e300e13348bc9fe9e660f83d422e473069584f73233c701ae37d1c8452ff2522f2a20c38849e0f406f1732ac + languageName: node + linkType: hard + +"are-we-there-yet@npm:^2.0.0": + version: 2.0.0 + resolution: "are-we-there-yet@npm:2.0.0" + dependencies: + delegates: ^1.0.0 + readable-stream: ^3.6.0 + checksum: 6c80b4fd04ecee6ba6e737e0b72a4b41bdc64b7d279edfc998678567ff583c8df27e27523bc789f2c99be603ffa9eaa612803da1d886962d2086e7ff6fa90c7c + languageName: node + linkType: hard + +"arg@npm:^4.1.0": + version: 4.1.3 + resolution: "arg@npm:4.1.3" + checksum: 544af8dd3f60546d3e4aff084d451b96961d2267d668670199692f8d054f0415d86fc5497d0e641e91546f0aa920e7c29e5250e99fc89f5552a34b5d93b77f43 + languageName: node + linkType: hard + +"argparse@npm:^1.0.7": + version: 1.0.10 + resolution: "argparse@npm:1.0.10" + dependencies: + sprintf-js: ~1.0.2 + checksum: 7ca6e45583a28de7258e39e13d81e925cfa25d7d4aacbf806a382d3c02fcb13403a07fb8aeef949f10a7cfe4a62da0e2e807b348a5980554cc28ee573ef95945 + languageName: node + linkType: hard + +"argparse@npm:^2.0.1": + version: 2.0.1 + resolution: "argparse@npm:2.0.1" + checksum: 83644b56493e89a254bae05702abf3a1101b4fa4d0ca31df1c9985275a5a5bd47b3c27b7fa0b71098d41114d8ca000e6ed90cad764b306f8a503665e4d517ced + languageName: node + linkType: hard + +"array-from@npm:^2.1.1": + version: 2.1.1 + resolution: "array-from@npm:2.1.1" + checksum: 4cd5fa27aa6133b99a57c2881d2a8a66ec59b8e17a0c900f7e8ac9a0a2fae450ed682b67435467bfa71ac9328d025a760c5c46a95586a352180c5a79fc13015d + languageName: node + linkType: hard + +"array-union@npm:^2.1.0": + version: 2.1.0 + resolution: "array-union@npm:2.1.0" + checksum: 5bee12395cba82da674931df6d0fea23c4aa4660cb3b338ced9f828782a65caa232573e6bf3968f23e0c5eb301764a382cef2f128b170a9dc59de0e36c39f98d + languageName: node + linkType: hard + +"axios@npm:^0.24.0": + version: 0.24.0 + resolution: "axios@npm:0.24.0" + dependencies: + follow-redirects: ^1.14.4 + checksum: 468cf496c08a6aadfb7e699bebdac02851e3043d4e7d282350804ea8900e30d368daa6e3cd4ab83b8ddb5a3b1e17a5a21ada13fc9cebd27b74828f47a4236316 + languageName: node + linkType: hard + +"balanced-match@npm:^1.0.0": + version: 1.0.2 + resolution: "balanced-match@npm:1.0.2" + checksum: 9706c088a283058a8a99e0bf91b0a2f75497f185980d9ffa8b304de1d9e58ebda7c72c07ebf01dadedaac5b2907b2c6f566f660d62bd336c3468e960403b9d65 + languageName: node + linkType: hard + +"binary-extensions@npm:^2.0.0": + version: 2.2.0 + resolution: "binary-extensions@npm:2.2.0" + checksum: ccd267956c58d2315f5d3ea6757cf09863c5fc703e50fbeb13a7dc849b812ef76e3cf9ca8f35a0c48498776a7478d7b4a0418e1e2b8cb9cb9731f2922aaad7f8 + languageName: node + linkType: hard + +"brace-expansion@npm:^1.1.7": + version: 1.1.11 + resolution: "brace-expansion@npm:1.1.11" + dependencies: + balanced-match: ^1.0.0 + concat-map: 0.0.1 + checksum: faf34a7bb0c3fcf4b59c7808bc5d2a96a40988addf2e7e09dfbb67a2251800e0d14cd2bfc1aa79174f2f5095c54ff27f46fb1289fe2d77dac755b5eb3434cc07 + languageName: node + linkType: hard + +"braces@npm:^3.0.1, braces@npm:~3.0.2": + version: 3.0.2 + resolution: "braces@npm:3.0.2" + dependencies: + fill-range: ^7.0.1 + checksum: e2a8e769a863f3d4ee887b5fe21f63193a891c68b612ddb4b68d82d1b5f3ff9073af066c343e9867a393fe4c2555dcb33e89b937195feb9c1613d259edfcd459 + languageName: node + linkType: hard + +"browser-stdout@npm:1.3.1": + version: 1.3.1 + resolution: "browser-stdout@npm:1.3.1" + checksum: b717b19b25952dd6af483e368f9bcd6b14b87740c3d226c2977a65e84666ffd67000bddea7d911f111a9b6ddc822b234de42d52ab6507bce4119a4cc003ef7b3 + languageName: node + linkType: hard + +"browserslist@npm:^4.17.5": + version: 4.19.1 + resolution: "browserslist@npm:4.19.1" + dependencies: + caniuse-lite: ^1.0.30001286 + electron-to-chromium: ^1.4.17 + escalade: ^3.1.1 + node-releases: ^2.0.1 + picocolors: ^1.0.0 + bin: + browserslist: cli.js + checksum: c0777fd483691638fd6801e16c9d809e1d65f6d2b06db2e806654be51045cbab1452a89841a2c5caea2cbe19d621b4f1d391cffbb24512aa33280039ab345875 + languageName: node + linkType: hard + +"cacache@npm:^15.2.0": + version: 15.3.0 + resolution: "cacache@npm:15.3.0" + dependencies: + "@npmcli/fs": ^1.0.0 + "@npmcli/move-file": ^1.0.1 + chownr: ^2.0.0 + fs-minipass: ^2.0.0 + glob: ^7.1.4 + infer-owner: ^1.0.4 + lru-cache: ^6.0.0 + minipass: ^3.1.1 + minipass-collect: ^1.0.2 + minipass-flush: ^1.0.5 + minipass-pipeline: ^1.2.2 + mkdirp: ^1.0.3 + p-map: ^4.0.0 + promise-inflight: ^1.0.1 + rimraf: ^3.0.2 + ssri: ^8.0.1 + tar: ^6.0.2 + unique-filename: ^1.1.1 + checksum: a07327c27a4152c04eb0a831c63c00390d90f94d51bb80624a66f4e14a6b6360bbf02a84421267bd4d00ca73ac9773287d8d7169e8d2eafe378d2ce140579db8 + languageName: node + linkType: hard + +"caching-transform@npm:^4.0.0": + version: 4.0.0 + resolution: "caching-transform@npm:4.0.0" + dependencies: + hasha: ^5.0.0 + make-dir: ^3.0.0 + package-hash: ^4.0.0 + write-file-atomic: ^3.0.0 + checksum: c4db6939533b677866808de67c32f0aaf8bf4fd3e3b8dc957e5d630c007c06b7f11512d44c38a38287fb068e931067e8da9019c34d787259a44121c9a6b87a1f + languageName: node + linkType: hard + +"callsites@npm:^3.0.0": + version: 3.1.0 + resolution: "callsites@npm:3.1.0" + checksum: 072d17b6abb459c2ba96598918b55868af677154bec7e73d222ef95a8fdb9bbf7dae96a8421085cdad8cd190d86653b5b6dc55a4484f2e5b2e27d5e0c3fc15b3 + languageName: node + linkType: hard + +"camelcase@npm:^5.0.0, camelcase@npm:^5.3.1": + version: 5.3.1 + resolution: "camelcase@npm:5.3.1" + checksum: e6effce26b9404e3c0f301498184f243811c30dfe6d0b9051863bd8e4034d09c8c2923794f280d6827e5aa055f6c434115ff97864a16a963366fb35fd673024b + languageName: node + linkType: hard + +"camelcase@npm:^6.0.0": + version: 6.3.0 + resolution: "camelcase@npm:6.3.0" + checksum: 8c96818a9076434998511251dcb2761a94817ea17dbdc37f47ac080bd088fc62c7369429a19e2178b993497132c8cbcf5cc1f44ba963e76782ba469c0474938d + languageName: node + linkType: hard + +"caniuse-lite@npm:^1.0.30001286": + version: 1.0.30001301 + resolution: "caniuse-lite@npm:1.0.30001301" + checksum: 0e359f2c682bed35521902ce7fc91136c485de4c1e1e33272d6fbb7cdf77178df7649960a9b69ce9da12022aadd7a0037b3c9b3594c41146d58216654dc9a236 + languageName: node + linkType: hard + +"chalk@npm:^2.0.0": + version: 2.4.2 + resolution: "chalk@npm:2.4.2" + dependencies: + ansi-styles: ^3.2.1 + escape-string-regexp: ^1.0.5 + supports-color: ^5.3.0 + checksum: ec3661d38fe77f681200f878edbd9448821924e0f93a9cefc0e26a33b145f1027a2084bf19967160d11e1f03bfe4eaffcabf5493b89098b2782c3fe0b03d80c2 + languageName: node + linkType: hard + +"chalk@npm:^4.0.0, chalk@npm:^4.1.0": + version: 4.1.2 + resolution: "chalk@npm:4.1.2" + dependencies: + ansi-styles: ^4.1.0 + supports-color: ^7.1.0 + checksum: fe75c9d5c76a7a98d45495b91b2172fa3b7a09e0cc9370e5c8feb1c567b85c4288e2b3fded7cfdd7359ac28d6b3844feb8b82b8686842e93d23c827c417e83fc + languageName: node + linkType: hard + +"chokidar@npm:3.5.3": + version: 3.5.3 + resolution: "chokidar@npm:3.5.3" + dependencies: + anymatch: ~3.1.2 + braces: ~3.0.2 + fsevents: ~2.3.2 + glob-parent: ~5.1.2 + is-binary-path: ~2.1.0 + is-glob: ~4.0.1 + normalize-path: ~3.0.0 + readdirp: ~3.6.0 + dependenciesMeta: + fsevents: + optional: true + checksum: b49fcde40176ba007ff361b198a2d35df60d9bb2a5aab228279eb810feae9294a6b4649ab15981304447afe1e6ffbf4788ad5db77235dc770ab777c6e771980c + languageName: node + linkType: hard + +"chownr@npm:^2.0.0": + version: 2.0.0 + resolution: "chownr@npm:2.0.0" + checksum: c57cf9dd0791e2f18a5ee9c1a299ae6e801ff58fee96dc8bfd0dcb4738a6ce58dd252a3605b1c93c6418fe4f9d5093b28ffbf4d66648cb2a9c67eaef9679be2f + languageName: node + linkType: hard + +"clean-stack@npm:^2.0.0": + version: 2.2.0 + resolution: "clean-stack@npm:2.2.0" + checksum: 2ac8cd2b2f5ec986a3c743935ec85b07bc174d5421a5efc8017e1f146a1cf5f781ae962618f416352103b32c9cd7e203276e8c28241bbe946160cab16149fb68 + languageName: node + linkType: hard + +"cliui@npm:^6.0.0": + version: 6.0.0 + resolution: "cliui@npm:6.0.0" + dependencies: + string-width: ^4.2.0 + strip-ansi: ^6.0.0 + wrap-ansi: ^6.2.0 + checksum: 4fcfd26d292c9f00238117f39fc797608292ae36bac2168cfee4c85923817d0607fe21b3329a8621e01aedf512c99b7eaa60e363a671ffd378df6649fb48ae42 + languageName: node + linkType: hard + +"cliui@npm:^7.0.2": + version: 7.0.4 + resolution: "cliui@npm:7.0.4" + dependencies: + string-width: ^4.2.0 + strip-ansi: ^6.0.0 + wrap-ansi: ^7.0.0 + checksum: ce2e8f578a4813806788ac399b9e866297740eecd4ad1823c27fd344d78b22c5f8597d548adbcc46f0573e43e21e751f39446c5a5e804a12aace402b7a315d7f + languageName: node + linkType: hard + +"color-convert@npm:^1.9.0": + version: 1.9.3 + resolution: "color-convert@npm:1.9.3" + dependencies: + color-name: 1.1.3 + checksum: fd7a64a17cde98fb923b1dd05c5f2e6f7aefda1b60d67e8d449f9328b4e53b228a428fd38bfeaeb2db2ff6b6503a776a996150b80cdf224062af08a5c8a3a203 + languageName: node + linkType: hard + +"color-convert@npm:^2.0.1": + version: 2.0.1 + resolution: "color-convert@npm:2.0.1" + dependencies: + color-name: ~1.1.4 + checksum: 79e6bdb9fd479a205c71d89574fccfb22bd9053bd98c6c4d870d65c132e5e904e6034978e55b43d69fcaa7433af2016ee203ce76eeba9cfa554b373e7f7db336 + languageName: node + linkType: hard + +"color-name@npm:1.1.3": + version: 1.1.3 + resolution: "color-name@npm:1.1.3" + checksum: 09c5d3e33d2105850153b14466501f2bfb30324a2f76568a408763a3b7433b0e50e5b4ab1947868e65cb101bb7cb75029553f2c333b6d4b8138a73fcc133d69d + languageName: node + linkType: hard + +"color-name@npm:~1.1.4": + version: 1.1.4 + resolution: "color-name@npm:1.1.4" + checksum: b0445859521eb4021cd0fb0cc1a75cecf67fceecae89b63f62b201cca8d345baf8b952c966862a9d9a2632987d4f6581f0ec8d957dfacece86f0a7919316f610 + languageName: node + linkType: hard + +"color-support@npm:^1.1.2": + version: 1.1.3 + resolution: "color-support@npm:1.1.3" + bin: + color-support: bin.js + checksum: 9b7356817670b9a13a26ca5af1c21615463b500783b739b7634a0c2047c16cef4b2865d7576875c31c3cddf9dd621fa19285e628f20198b233a5cfdda6d0793b + languageName: node + linkType: hard + +"commondir@npm:^1.0.1": + version: 1.0.1 + resolution: "commondir@npm:1.0.1" + checksum: 59715f2fc456a73f68826285718503340b9f0dd89bfffc42749906c5cf3d4277ef11ef1cca0350d0e79204f00f1f6d83851ececc9095dc88512a697ac0b9bdcb + languageName: node + linkType: hard + +"concat-map@npm:0.0.1": + version: 0.0.1 + resolution: "concat-map@npm:0.0.1" + checksum: 902a9f5d8967a3e2faf138d5cb784b9979bad2e6db5357c5b21c568df4ebe62bcb15108af1b2253744844eb964fc023fbd9afbbbb6ddd0bcc204c6fb5b7bf3af + languageName: node + linkType: hard + +"console-control-strings@npm:^1.0.0, console-control-strings@npm:^1.1.0": + version: 1.1.0 + resolution: "console-control-strings@npm:1.1.0" + checksum: 8755d76787f94e6cf79ce4666f0c5519906d7f5b02d4b884cf41e11dcd759ed69c57da0670afd9236d229a46e0f9cf519db0cd829c6dca820bb5a5c3def584ed + languageName: node + linkType: hard + +"convert-source-map@npm:^1.7.0": + version: 1.8.0 + resolution: "convert-source-map@npm:1.8.0" + dependencies: + safe-buffer: ~5.1.1 + checksum: 985d974a2d33e1a2543ada51c93e1ba2f73eaed608dc39f229afc78f71dcc4c8b7d7c684aa647e3c6a3a204027444d69e53e169ce94e8d1fa8d7dee80c9c8fed + languageName: node + linkType: hard + +"create-require@npm:^1.1.0": + version: 1.1.1 + resolution: "create-require@npm:1.1.1" + checksum: a9a1503d4390d8b59ad86f4607de7870b39cad43d929813599a23714831e81c520bddf61bcdd1f8e30f05fd3a2b71ae8538e946eb2786dc65c2bbc520f692eff + languageName: node + linkType: hard + +"cross-spawn@npm:^7.0.0, cross-spawn@npm:^7.0.2": + version: 7.0.3 + resolution: "cross-spawn@npm:7.0.3" + dependencies: + path-key: ^3.1.0 + shebang-command: ^2.0.0 + which: ^2.0.1 + checksum: 671cc7c7288c3a8406f3c69a3ae2fc85555c04169e9d611def9a675635472614f1c0ed0ef80955d5b6d4e724f6ced67f0ad1bb006c2ea643488fcfef994d7f52 + languageName: node + linkType: hard + +"debug@npm:4, debug@npm:4.3.3, debug@npm:^4.1.0, debug@npm:^4.1.1, debug@npm:^4.3.1, debug@npm:^4.3.2": + version: 4.3.3 + resolution: "debug@npm:4.3.3" + dependencies: + ms: 2.1.2 + peerDependenciesMeta: + supports-color: + optional: true + checksum: 14472d56fe4a94dbcfaa6dbed2dd3849f1d72ba78104a1a328047bb564643ca49df0224c3a17fa63533fd11dd3d4c8636cd861191232a2c6735af00cc2d4de16 + languageName: node + linkType: hard + +"decamelize@npm:^1.2.0": + version: 1.2.0 + resolution: "decamelize@npm:1.2.0" + checksum: ad8c51a7e7e0720c70ec2eeb1163b66da03e7616d7b98c9ef43cce2416395e84c1e9548dd94f5f6ffecfee9f8b94251fc57121a8b021f2ff2469b2bae247b8aa + languageName: node + linkType: hard + +"decamelize@npm:^4.0.0": + version: 4.0.0 + resolution: "decamelize@npm:4.0.0" + checksum: b7d09b82652c39eead4d6678bb578e3bebd848add894b76d0f6b395bc45b2d692fb88d977e7cfb93c4ed6c119b05a1347cef261174916c2e75c0a8ca57da1809 + languageName: node + linkType: hard + +"deep-is@npm:^0.1.3": + version: 0.1.4 + resolution: "deep-is@npm:0.1.4" + checksum: edb65dd0d7d1b9c40b2f50219aef30e116cedd6fc79290e740972c132c09106d2e80aa0bc8826673dd5a00222d4179c84b36a790eef63a4c4bca75a37ef90804 + languageName: node + linkType: hard + +"default-require-extensions@npm:^3.0.0": + version: 3.0.0 + resolution: "default-require-extensions@npm:3.0.0" + dependencies: + strip-bom: ^4.0.0 + checksum: 0b5bdb6786ebb0ff6ef55386f37c8d221963fbbd3009588fe71032c85ca16da05eff2ad01bfe9bfc8bac5ce95a18f66b38c50d454482e3e9d2de1142424a3e7c + languageName: node + linkType: hard + +"delegates@npm:^1.0.0": + version: 1.0.0 + resolution: "delegates@npm:1.0.0" + checksum: a51744d9b53c164ba9c0492471a1a2ffa0b6727451bdc89e31627fdf4adda9d51277cfcbfb20f0a6f08ccb3c436f341df3e92631a3440226d93a8971724771fd + languageName: node + linkType: hard + +"depd@npm:^1.1.2": + version: 1.1.2 + resolution: "depd@npm:1.1.2" + checksum: 6b406620d269619852885ce15965272b829df6f409724415e0002c8632ab6a8c0a08ec1f0bd2add05dc7bd7507606f7e2cc034fa24224ab829580040b835ecd9 + languageName: node + linkType: hard + +"diff@npm:5.0.0": + version: 5.0.0 + resolution: "diff@npm:5.0.0" + checksum: f19fe29284b633afdb2725c2a8bb7d25761ea54d321d8e67987ac851c5294be4afeab532bd84531e02583a3fe7f4014aa314a3eda84f5590e7a9e6b371ef3b46 + languageName: node + linkType: hard + +"diff@npm:^3.5.0": + version: 3.5.0 + resolution: "diff@npm:3.5.0" + checksum: 00842950a6551e26ce495bdbce11047e31667deea546527902661f25cc2e73358967ebc78cf86b1a9736ec3e14286433225f9970678155753a6291c3bca5227b + languageName: node + linkType: hard + +"diff@npm:^4.0.1": + version: 4.0.2 + resolution: "diff@npm:4.0.2" + checksum: f2c09b0ce4e6b301c221addd83bf3f454c0bc00caa3dd837cf6c127d6edf7223aa2bbe3b688feea110b7f262adbfc845b757c44c8a9f8c0c5b15d8fa9ce9d20d + languageName: node + linkType: hard + +"dir-glob@npm:^3.0.1": + version: 3.0.1 + resolution: "dir-glob@npm:3.0.1" + dependencies: + path-type: ^4.0.0 + checksum: fa05e18324510d7283f55862f3161c6759a3f2f8dbce491a2fc14c8324c498286c54282c1f0e933cb930da8419b30679389499b919122952a4f8592362ef4615 + languageName: node + linkType: hard + +"doctrine@npm:^3.0.0": + version: 3.0.0 + resolution: "doctrine@npm:3.0.0" + dependencies: + esutils: ^2.0.2 + checksum: fd7673ca77fe26cd5cba38d816bc72d641f500f1f9b25b83e8ce28827fe2da7ad583a8da26ab6af85f834138cf8dae9f69b0cd6ab925f52ddab1754db44d99ce + languageName: node + linkType: hard + +"electron-to-chromium@npm:^1.4.17": + version: 1.4.51 + resolution: "electron-to-chromium@npm:1.4.51" + checksum: dad1fd5faad1eed0206951429290ff0343eebfcabc201600dc0aeda7a2de07e0db697728fcd0b9e14f9c5f8cd5ec4841acda3179c5b2f8cdea09a5e81c634313 + languageName: node + linkType: hard + +"emoji-regex@npm:^8.0.0": + version: 8.0.0 + resolution: "emoji-regex@npm:8.0.0" + checksum: d4c5c39d5a9868b5fa152f00cada8a936868fd3367f33f71be515ecee4c803132d11b31a6222b2571b1e5f7e13890156a94880345594d0ce7e3c9895f560f192 + languageName: node + linkType: hard + +"encoding@npm:^0.1.12": + version: 0.1.13 + resolution: "encoding@npm:0.1.13" + dependencies: + iconv-lite: ^0.6.2 + checksum: bb98632f8ffa823996e508ce6a58ffcf5856330fde839ae42c9e1f436cc3b5cc651d4aeae72222916545428e54fd0f6aa8862fd8d25bdbcc4589f1e3f3715e7f + languageName: node + linkType: hard + +"env-paths@npm:^2.2.0": + version: 2.2.1 + resolution: "env-paths@npm:2.2.1" + checksum: 65b5df55a8bab92229ab2b40dad3b387fad24613263d103a97f91c9fe43ceb21965cd3392b1ccb5d77088021e525c4e0481adb309625d0cb94ade1d1fb8dc17e + languageName: node + linkType: hard + +"err-code@npm:^2.0.2": + version: 2.0.3 + resolution: "err-code@npm:2.0.3" + checksum: 8b7b1be20d2de12d2255c0bc2ca638b7af5171142693299416e6a9339bd7d88fc8d7707d913d78e0993176005405a236b066b45666b27b797252c771156ace54 + languageName: node + linkType: hard + +"es6-error@npm:^4.0.1": + version: 4.1.1 + resolution: "es6-error@npm:4.1.1" + checksum: ae41332a51ec1323da6bbc5d75b7803ccdeddfae17c41b6166ebbafc8e8beb7a7b80b884b7fab1cc80df485860ac3c59d78605e860bb4f8cd816b3d6ade0d010 + languageName: node + linkType: hard + +"escalade@npm:^3.1.1": + version: 3.1.1 + resolution: "escalade@npm:3.1.1" + checksum: a3e2a99f07acb74b3ad4989c48ca0c3140f69f923e56d0cba0526240ee470b91010f9d39001f2a4a313841d237ede70a729e92125191ba5d21e74b106800b133 + languageName: node + linkType: hard + +"escape-string-regexp@npm:4.0.0, escape-string-regexp@npm:^4.0.0": + version: 4.0.0 + resolution: "escape-string-regexp@npm:4.0.0" + checksum: 98b48897d93060f2322108bf29db0feba7dd774be96cd069458d1453347b25ce8682ecc39859d4bca2203cc0ab19c237bcc71755eff49a0f8d90beadeeba5cc5 + languageName: node + linkType: hard + +"escape-string-regexp@npm:^1.0.5": + version: 1.0.5 + resolution: "escape-string-regexp@npm:1.0.5" + checksum: 6092fda75c63b110c706b6a9bfde8a612ad595b628f0bd2147eea1d3406723020810e591effc7db1da91d80a71a737a313567c5abb3813e8d9c71f4aa595b410 + languageName: node + linkType: hard + +"eslint-config-prettier@npm:^8.3.0": + version: 8.3.0 + resolution: "eslint-config-prettier@npm:8.3.0" + peerDependencies: + eslint: ">=7.0.0" + bin: + eslint-config-prettier: bin/cli.js + checksum: df4cea3032671995bb5ab07e016169072f7fa59f44a53251664d9ca60951b66cdc872683b5c6a3729c91497c11490ca44a79654b395dd6756beb0c3903a37196 + languageName: node + linkType: hard + +"eslint-scope@npm:^5.1.1": + version: 5.1.1 + resolution: "eslint-scope@npm:5.1.1" + dependencies: + esrecurse: ^4.3.0 + estraverse: ^4.1.1 + checksum: 47e4b6a3f0cc29c7feedee6c67b225a2da7e155802c6ea13bbef4ac6b9e10c66cd2dcb987867ef176292bf4e64eccc680a49e35e9e9c669f4a02bac17e86abdb + languageName: node + linkType: hard + +"eslint-scope@npm:^7.1.0": + version: 7.1.0 + resolution: "eslint-scope@npm:7.1.0" + dependencies: + esrecurse: ^4.3.0 + estraverse: ^5.2.0 + checksum: 2070470a0725438ed47075b2574a4c03cf59aa32648da8cff9e3548c84f6b0079cfdb9ee1dd7ab0bfe97011f64b2af5bfd4b69cf14a1292130dec661eec7914a + languageName: node + linkType: hard + +"eslint-utils@npm:^3.0.0": + version: 3.0.0 + resolution: "eslint-utils@npm:3.0.0" + dependencies: + eslint-visitor-keys: ^2.0.0 + peerDependencies: + eslint: ">=5" + checksum: 0668fe02f5adab2e5a367eee5089f4c39033af20499df88fe4e6aba2015c20720404d8c3d6349b6f716b08fdf91b9da4e5d5481f265049278099c4c836ccb619 + languageName: node + linkType: hard + +"eslint-visitor-keys@npm:^2.0.0": + version: 2.1.0 + resolution: "eslint-visitor-keys@npm:2.1.0" + checksum: e3081d7dd2611a35f0388bbdc2f5da60b3a3c5b8b6e928daffff7391146b434d691577aa95064c8b7faad0b8a680266bcda0a42439c18c717b80e6718d7e267d + languageName: node + linkType: hard + +"eslint-visitor-keys@npm:^3.0.0, eslint-visitor-keys@npm:^3.1.0, eslint-visitor-keys@npm:^3.2.0": + version: 3.2.0 + resolution: "eslint-visitor-keys@npm:3.2.0" + checksum: fdadbb26f9e6417d3db7ad4f00bb0d573b6031c32fa72e8cdae32d038223faaeddff2ee443c90cb489bf774e75bff765c00912b8f9106d65e4f202ccd78c1b18 + languageName: node + linkType: hard + +"eslint@npm:^8.2.0": + version: 8.7.0 + resolution: "eslint@npm:8.7.0" + dependencies: + "@eslint/eslintrc": ^1.0.5 + "@humanwhocodes/config-array": ^0.9.2 + ajv: ^6.10.0 + chalk: ^4.0.0 + cross-spawn: ^7.0.2 + debug: ^4.3.2 + doctrine: ^3.0.0 + escape-string-regexp: ^4.0.0 + eslint-scope: ^7.1.0 + eslint-utils: ^3.0.0 + eslint-visitor-keys: ^3.2.0 + espree: ^9.3.0 + esquery: ^1.4.0 + esutils: ^2.0.2 + fast-deep-equal: ^3.1.3 + file-entry-cache: ^6.0.1 + functional-red-black-tree: ^1.0.1 + glob-parent: ^6.0.1 + globals: ^13.6.0 + ignore: ^5.2.0 + import-fresh: ^3.0.0 + imurmurhash: ^0.1.4 + is-glob: ^4.0.0 + js-yaml: ^4.1.0 + json-stable-stringify-without-jsonify: ^1.0.1 + levn: ^0.4.1 + lodash.merge: ^4.6.2 + minimatch: ^3.0.4 + natural-compare: ^1.4.0 + optionator: ^0.9.1 + regexpp: ^3.2.0 + strip-ansi: ^6.0.1 + strip-json-comments: ^3.1.0 + text-table: ^0.2.0 + v8-compile-cache: ^2.0.3 + bin: + eslint: bin/eslint.js + checksum: 1c80375a48b0fe3ccae3c6354323e4f0e92e970f23abc5b9705b90b7aef514b69ebd0a63e74962d30789986c91fa41c0e25cd2f98f19e9e2a2d36aafdfc9ccc9 + languageName: node + linkType: hard + +"espree@npm:^9.2.0, espree@npm:^9.3.0": + version: 9.3.0 + resolution: "espree@npm:9.3.0" + dependencies: + acorn: ^8.7.0 + acorn-jsx: ^5.3.1 + eslint-visitor-keys: ^3.1.0 + checksum: c0f1885c4eab652f9be08eb9228cea0df046b559b29d4aed8d6590ea9bd60177d4cb245d204a6f737a79a096861bb4ab8e480aeb8c1dbafef5beec1157353ce4 + languageName: node + linkType: hard + +"esprima@npm:^4.0.0": + version: 4.0.1 + resolution: "esprima@npm:4.0.1" + bin: + esparse: ./bin/esparse.js + esvalidate: ./bin/esvalidate.js + checksum: b45bc805a613dbea2835278c306b91aff6173c8d034223fa81498c77dcbce3b2931bf6006db816f62eacd9fd4ea975dfd85a5b7f3c6402cfd050d4ca3c13a628 + languageName: node + linkType: hard + +"esquery@npm:^1.4.0": + version: 1.4.0 + resolution: "esquery@npm:1.4.0" + dependencies: + estraverse: ^5.1.0 + checksum: a0807e17abd7fbe5fbd4fab673038d6d8a50675cdae6b04fbaa520c34581be0c5fa24582990e8acd8854f671dd291c78bb2efb9e0ed5b62f33bac4f9cf820210 + languageName: node + linkType: hard + +"esrecurse@npm:^4.3.0": + version: 4.3.0 + resolution: "esrecurse@npm:4.3.0" + dependencies: + estraverse: ^5.2.0 + checksum: ebc17b1a33c51cef46fdc28b958994b1dc43cd2e86237515cbc3b4e5d2be6a811b2315d0a1a4d9d340b6d2308b15322f5c8291059521cc5f4802f65e7ec32837 + languageName: node + linkType: hard + +"estraverse@npm:^4.1.1": + version: 4.3.0 + resolution: "estraverse@npm:4.3.0" + checksum: a6299491f9940bb246124a8d44b7b7a413a8336f5436f9837aaa9330209bd9ee8af7e91a654a3545aee9c54b3308e78ee360cef1d777d37cfef77d2fa33b5827 + languageName: node + linkType: hard + +"estraverse@npm:^5.1.0, estraverse@npm:^5.2.0": + version: 5.3.0 + resolution: "estraverse@npm:5.3.0" + checksum: 072780882dc8416ad144f8fe199628d2b3e7bbc9989d9ed43795d2c90309a2047e6bc5979d7e2322a341163d22cfad9e21f4110597fe487519697389497e4e2b + languageName: node + linkType: hard + +"esutils@npm:^2.0.2": + version: 2.0.3 + resolution: "esutils@npm:2.0.3" + checksum: 22b5b08f74737379a840b8ed2036a5fb35826c709ab000683b092d9054e5c2a82c27818f12604bfc2a9a76b90b6834ef081edbc1c7ae30d1627012e067c6ec87 + languageName: node + linkType: hard + +"fast-deep-equal@npm:^3.1.1, fast-deep-equal@npm:^3.1.3": + version: 3.1.3 + resolution: "fast-deep-equal@npm:3.1.3" + checksum: e21a9d8d84f53493b6aa15efc9cfd53dd5b714a1f23f67fb5dc8f574af80df889b3bce25dc081887c6d25457cce704e636395333abad896ccdec03abaf1f3f9d + languageName: node + linkType: hard + +"fast-glob@npm:^3.2.9": + version: 3.2.11 + resolution: "fast-glob@npm:3.2.11" + dependencies: + "@nodelib/fs.stat": ^2.0.2 + "@nodelib/fs.walk": ^1.2.3 + glob-parent: ^5.1.2 + merge2: ^1.3.0 + micromatch: ^4.0.4 + checksum: f473105324a7780a20c06de842e15ddbb41d3cb7e71d1e4fe6e8373204f22245d54f5ab9e2061e6a1c613047345954d29b022e0e76f5c28b1df9858179a0e6d7 + languageName: node + linkType: hard + +"fast-json-stable-stringify@npm:^2.0.0": + version: 2.1.0 + resolution: "fast-json-stable-stringify@npm:2.1.0" + checksum: b191531e36c607977e5b1c47811158733c34ccb3bfde92c44798929e9b4154884378536d26ad90dfecd32e1ffc09c545d23535ad91b3161a27ddbb8ebe0cbecb + languageName: node + linkType: hard + +"fast-levenshtein@npm:^2.0.6": + version: 2.0.6 + resolution: "fast-levenshtein@npm:2.0.6" + checksum: 92cfec0a8dfafd9c7a15fba8f2cc29cd0b62b85f056d99ce448bbcd9f708e18ab2764bda4dd5158364f4145a7c72788538994f0d1787b956ef0d1062b0f7c24c + languageName: node + linkType: hard + +"fastq@npm:^1.6.0": + version: 1.13.0 + resolution: "fastq@npm:1.13.0" + dependencies: + reusify: ^1.0.4 + checksum: 32cf15c29afe622af187d12fc9cd93e160a0cb7c31a3bb6ace86b7dea3b28e7b72acde89c882663f307b2184e14782c6c664fa315973c03626c7d4bff070bb0b + languageName: node + linkType: hard + +"file-entry-cache@npm:^6.0.1": + version: 6.0.1 + resolution: "file-entry-cache@npm:6.0.1" + dependencies: + flat-cache: ^3.0.4 + checksum: f49701feaa6314c8127c3c2f6173cfefff17612f5ed2daaafc6da13b5c91fd43e3b2a58fd0d63f9f94478a501b167615931e7200e31485e320f74a33885a9c74 + languageName: node + linkType: hard + +"fill-range@npm:^7.0.1": + version: 7.0.1 + resolution: "fill-range@npm:7.0.1" + dependencies: + to-regex-range: ^5.0.1 + checksum: cc283f4e65b504259e64fd969bcf4def4eb08d85565e906b7d36516e87819db52029a76b6363d0f02d0d532f0033c9603b9e2d943d56ee3b0d4f7ad3328ff917 + languageName: node + linkType: hard + +"find-cache-dir@npm:^3.2.0": + version: 3.3.2 + resolution: "find-cache-dir@npm:3.3.2" + dependencies: + commondir: ^1.0.1 + make-dir: ^3.0.2 + pkg-dir: ^4.1.0 + checksum: 1e61c2e64f5c0b1c535bd85939ae73b0e5773142713273818cc0b393ee3555fb0fd44e1a5b161b8b6c3e03e98c2fcc9c227d784850a13a90a8ab576869576817 + languageName: node + linkType: hard + +"find-up@npm:5.0.0": + version: 5.0.0 + resolution: "find-up@npm:5.0.0" + dependencies: + locate-path: ^6.0.0 + path-exists: ^4.0.0 + checksum: 07955e357348f34660bde7920783204ff5a26ac2cafcaa28bace494027158a97b9f56faaf2d89a6106211a8174db650dd9f503f9c0d526b1202d5554a00b9095 + languageName: node + linkType: hard + +"find-up@npm:^4.0.0, find-up@npm:^4.1.0": + version: 4.1.0 + resolution: "find-up@npm:4.1.0" + dependencies: + locate-path: ^5.0.0 + path-exists: ^4.0.0 + checksum: 4c172680e8f8c1f78839486e14a43ef82e9decd0e74145f40707cc42e7420506d5ec92d9a11c22bd2c48fb0c384ea05dd30e10dd152fefeec6f2f75282a8b844 + languageName: node + linkType: hard + +"flat-cache@npm:^3.0.4": + version: 3.0.4 + resolution: "flat-cache@npm:3.0.4" + dependencies: + flatted: ^3.1.0 + rimraf: ^3.0.2 + checksum: 4fdd10ecbcbf7d520f9040dd1340eb5dfe951e6f0ecf2252edeec03ee68d989ec8b9a20f4434270e71bcfd57800dc09b3344fca3966b2eb8f613072c7d9a2365 + languageName: node + linkType: hard + +"flat@npm:^5.0.2": + version: 5.0.2 + resolution: "flat@npm:5.0.2" + bin: + flat: cli.js + checksum: 12a1536ac746db74881316a181499a78ef953632ddd28050b7a3a43c62ef5462e3357c8c29d76072bb635f147f7a9a1f0c02efef6b4be28f8db62ceb3d5c7f5d + languageName: node + linkType: hard + +"flatted@npm:^3.1.0": + version: 3.2.4 + resolution: "flatted@npm:3.2.4" + checksum: 7d33846428ab337ec81ef9b8b9103894c1c81f5f67feb32bd4ed106fbc47da60d56edb42efd36c9f1f30a010272aeccd34ec1ffacfe9dfdff19673b1d4df481b + languageName: node + linkType: hard + +"follow-redirects@npm:^1.14.4": + version: 1.14.7 + resolution: "follow-redirects@npm:1.14.7" + peerDependenciesMeta: + debug: + optional: true + checksum: f6d03e5e30877431065bca0d1b2e3db93949eb799d368a5c07ea8a4b71205f0349a3f8f0191bf13a07c93885522834dca1dc8e527dc99a772c6911fba24edc5f + languageName: node + linkType: hard + +"foreground-child@npm:^2.0.0": + version: 2.0.0 + resolution: "foreground-child@npm:2.0.0" + dependencies: + cross-spawn: ^7.0.0 + signal-exit: ^3.0.2 + checksum: f77ec9aff621abd6b754cb59e690743e7639328301fbea6ff09df27d2befaf7dd5b77cec51c32323d73a81a7d91caaf9413990d305cbe3d873eec4fe58960956 + languageName: node + linkType: hard + +"fromentries@npm:^1.2.0": + version: 1.3.2 + resolution: "fromentries@npm:1.3.2" + checksum: 33729c529ce19f5494f846f0dd4945078f4e37f4e8955f4ae8cc7385c218f600e9d93a7d225d17636c20d1889106fd87061f911550861b7072f53bf891e6b341 + languageName: node + linkType: hard + +"fs-minipass@npm:^2.0.0": + version: 2.1.0 + resolution: "fs-minipass@npm:2.1.0" + dependencies: + minipass: ^3.0.0 + checksum: 1b8d128dae2ac6cc94230cc5ead341ba3e0efaef82dab46a33d171c044caaa6ca001364178d42069b2809c35a1c3c35079a32107c770e9ffab3901b59af8c8b1 + languageName: node + linkType: hard + +"fs.realpath@npm:^1.0.0": + version: 1.0.0 + resolution: "fs.realpath@npm:1.0.0" + checksum: 99ddea01a7e75aa276c250a04eedeffe5662bce66c65c07164ad6264f9de18fb21be9433ead460e54cff20e31721c811f4fb5d70591799df5f85dce6d6746fd0 + languageName: node + linkType: hard + +"fsevents@npm:~2.3.2": + version: 2.3.2 + resolution: "fsevents@npm:2.3.2" + dependencies: + node-gyp: latest + checksum: 97ade64e75091afee5265e6956cb72ba34db7819b4c3e94c431d4be2b19b8bb7a2d4116da417950c3425f17c8fe693d25e20212cac583ac1521ad066b77ae31f + conditions: os=darwin + languageName: node + linkType: hard + +"fsevents@patch:fsevents@~2.3.2#~builtin": + version: 2.3.2 + resolution: "fsevents@patch:fsevents@npm%3A2.3.2#~builtin::version=2.3.2&hash=18f3a7" + dependencies: + node-gyp: latest + conditions: os=darwin + languageName: node + linkType: hard + +"functional-red-black-tree@npm:^1.0.1": + version: 1.0.1 + resolution: "functional-red-black-tree@npm:1.0.1" + checksum: ca6c170f37640e2d94297da8bb4bf27a1d12bea3e00e6a3e007fd7aa32e37e000f5772acf941b4e4f3cf1c95c3752033d0c509af157ad8f526e7f00723b9eb9f + languageName: node + linkType: hard + +"gauge@npm:^4.0.0": + version: 4.0.0 + resolution: "gauge@npm:4.0.0" + dependencies: + ansi-regex: ^5.0.1 + aproba: ^1.0.3 || ^2.0.0 + color-support: ^1.1.2 + console-control-strings: ^1.0.0 + has-unicode: ^2.0.1 + signal-exit: ^3.0.0 + string-width: ^4.2.3 + strip-ansi: ^6.0.1 + wide-align: ^1.1.2 + checksum: 637b34c84f518defa89319dbef68211a24e9302182ad2a619e3be1be5b7dcf2a962c8359e889294af667440f4722e7e6e61671859e00bd8ec280a136ded89b25 + languageName: node + linkType: hard + +"gensync@npm:^1.0.0-beta.2": + version: 1.0.0-beta.2 + resolution: "gensync@npm:1.0.0-beta.2" + checksum: a7437e58c6be12aa6c90f7730eac7fa9833dc78872b4ad2963d2031b00a3367a93f98aec75f9aaac7220848e4026d67a8655e870b24f20a543d103c0d65952ec + languageName: node + linkType: hard + +"get-caller-file@npm:^2.0.1, get-caller-file@npm:^2.0.5": + version: 2.0.5 + resolution: "get-caller-file@npm:2.0.5" + checksum: b9769a836d2a98c3ee734a88ba712e62703f1df31b94b784762c433c27a386dd6029ff55c2a920c392e33657d80191edbf18c61487e198844844516f843496b9 + languageName: node + linkType: hard + +"get-package-type@npm:^0.1.0": + version: 0.1.0 + resolution: "get-package-type@npm:0.1.0" + checksum: bba0811116d11e56d702682ddef7c73ba3481f114590e705fc549f4d868972263896af313c57a25c076e3c0d567e11d919a64ba1b30c879be985fc9d44f96148 + languageName: node + linkType: hard + +"glob-parent@npm:^5.1.2, glob-parent@npm:~5.1.2": + version: 5.1.2 + resolution: "glob-parent@npm:5.1.2" + dependencies: + is-glob: ^4.0.1 + checksum: f4f2bfe2425296e8a47e36864e4f42be38a996db40420fe434565e4480e3322f18eb37589617a98640c5dc8fdec1a387007ee18dbb1f3f5553409c34d17f425e + languageName: node + linkType: hard + +"glob-parent@npm:^6.0.1": + version: 6.0.2 + resolution: "glob-parent@npm:6.0.2" + dependencies: + is-glob: ^4.0.3 + checksum: c13ee97978bef4f55106b71e66428eb1512e71a7466ba49025fc2aec59a5bfb0954d5abd58fc5ee6c9b076eef4e1f6d3375c2e964b88466ca390da4419a786a8 + languageName: node + linkType: hard + +"glob@npm:7.2.0, glob@npm:^7.1.3, glob@npm:^7.1.4, glob@npm:^7.1.6": + version: 7.2.0 + resolution: "glob@npm:7.2.0" + dependencies: + fs.realpath: ^1.0.0 + inflight: ^1.0.4 + inherits: 2 + minimatch: ^3.0.4 + once: ^1.3.0 + path-is-absolute: ^1.0.0 + checksum: 78a8ea942331f08ed2e055cb5b9e40fe6f46f579d7fd3d694f3412fe5db23223d29b7fee1575440202e9a7ff9a72ab106a39fee39934c7bedafe5e5f8ae20134 + languageName: node + linkType: hard + +"globals@npm:^11.1.0": + version: 11.12.0 + resolution: "globals@npm:11.12.0" + checksum: 67051a45eca3db904aee189dfc7cd53c20c7d881679c93f6146ddd4c9f4ab2268e68a919df740d39c71f4445d2b38ee360fc234428baea1dbdfe68bbcb46979e + languageName: node + linkType: hard + +"globals@npm:^13.6.0, globals@npm:^13.9.0": + version: 13.12.0 + resolution: "globals@npm:13.12.0" + dependencies: + type-fest: ^0.20.2 + checksum: 1f959abb11117916468a1afcba527eead152900cad652c8383c4e8976daea7ec55e1ee30c086f48d1b8655719f214e9d92eca083c3a43b5543bc4056e7e5fccf + languageName: node + linkType: hard + +"globby@npm:^11.0.4": + version: 11.1.0 + resolution: "globby@npm:11.1.0" + dependencies: + array-union: ^2.1.0 + dir-glob: ^3.0.1 + fast-glob: ^3.2.9 + ignore: ^5.2.0 + merge2: ^1.4.1 + slash: ^3.0.0 + checksum: b4be8885e0cfa018fc783792942d53926c35c50b3aefd3fdcfb9d22c627639dc26bd2327a40a0b74b074100ce95bb7187bfeae2f236856aa3de183af7a02aea6 + languageName: node + linkType: hard + +"graceful-fs@npm:^4.1.15, graceful-fs@npm:^4.2.6": + version: 4.2.9 + resolution: "graceful-fs@npm:4.2.9" + checksum: 68ea4e07ff2c041ada184f9278b830375f8e0b75154e3f080af6b70f66172fabb4108d19b3863a96b53fc068a310b9b6493d86d1291acc5f3861eb4b79d26ad6 + languageName: node + linkType: hard + +"growl@npm:1.10.5": + version: 1.10.5 + resolution: "growl@npm:1.10.5" + checksum: 4b86685de6831cebcbb19f93870bea624afee61124b0a20c49017013987cd129e73a8c4baeca295728f41d21265e1f859d25ef36731b142ca59c655fea94bb1a + languageName: node + linkType: hard + +"has-flag@npm:^3.0.0": + version: 3.0.0 + resolution: "has-flag@npm:3.0.0" + checksum: 4a15638b454bf086c8148979aae044dd6e39d63904cd452d970374fa6a87623423da485dfb814e7be882e05c096a7ccf1ebd48e7e7501d0208d8384ff4dea73b + languageName: node + linkType: hard + +"has-flag@npm:^4.0.0": + version: 4.0.0 + resolution: "has-flag@npm:4.0.0" + checksum: 261a1357037ead75e338156b1f9452c016a37dcd3283a972a30d9e4a87441ba372c8b81f818cd0fbcd9c0354b4ae7e18b9e1afa1971164aef6d18c2b6095a8ad + languageName: node + linkType: hard + +"has-unicode@npm:^2.0.1": + version: 2.0.1 + resolution: "has-unicode@npm:2.0.1" + checksum: 1eab07a7436512db0be40a710b29b5dc21fa04880b7f63c9980b706683127e3c1b57cb80ea96d47991bdae2dfe479604f6a1ba410106ee1046a41d1bd0814400 + languageName: node + linkType: hard + +"hasha@npm:^5.0.0": + version: 5.2.2 + resolution: "hasha@npm:5.2.2" + dependencies: + is-stream: ^2.0.0 + type-fest: ^0.8.0 + checksum: 06cc474bed246761ff61c19d629977eb5f53fa817be4313a255a64ae0f433e831a29e83acb6555e3f4592b348497596f1d1653751008dda4f21c9c21ca60ac5a + languageName: node + linkType: hard + +"he@npm:1.2.0": + version: 1.2.0 + resolution: "he@npm:1.2.0" + bin: + he: bin/he + checksum: 3d4d6babccccd79c5c5a3f929a68af33360d6445587d628087f39a965079d84f18ce9c3d3f917ee1e3978916fc833bb8b29377c3b403f919426f91bc6965e7a7 + languageName: node + linkType: hard + +"html-escaper@npm:^2.0.0": + version: 2.0.2 + resolution: "html-escaper@npm:2.0.2" + checksum: d2df2da3ad40ca9ee3a39c5cc6475ef67c8f83c234475f24d8e9ce0dc80a2c82df8e1d6fa78ddd1e9022a586ea1bd247a615e80a5cd9273d90111ddda7d9e974 + languageName: node + linkType: hard + +"htmlencode@npm:^0.0.4": + version: 0.0.4 + resolution: "htmlencode@npm:0.0.4" + checksum: b5c5a280213569f59807d22ae2d68c77360f6337b6936cdfa4e2aeaa12e3a69bb36b426ad18ed9333a7fb3f7d55c14ea3b46040d3271af7a586f262aaf4092ad + languageName: node + linkType: hard + +"http-cache-semantics@npm:^4.1.0": + version: 4.1.0 + resolution: "http-cache-semantics@npm:4.1.0" + checksum: 974de94a81c5474be07f269f9fd8383e92ebb5a448208223bfb39e172a9dbc26feff250192ecc23b9593b3f92098e010406b0f24bd4d588d631f80214648ed42 + languageName: node + linkType: hard + +"http-proxy-agent@npm:^4.0.1": + version: 4.0.1 + resolution: "http-proxy-agent@npm:4.0.1" + dependencies: + "@tootallnate/once": 1 + agent-base: 6 + debug: 4 + checksum: c6a5da5a1929416b6bbdf77b1aca13888013fe7eb9d59fc292e25d18e041bb154a8dfada58e223fc7b76b9b2d155a87e92e608235201f77d34aa258707963a82 + languageName: node + linkType: hard + +"https-proxy-agent@npm:^5.0.0": + version: 5.0.0 + resolution: "https-proxy-agent@npm:5.0.0" + dependencies: + agent-base: 6 + debug: 4 + checksum: 165bfb090bd26d47693597661298006841ab733d0c7383a8cb2f17373387a94c903a3ac687090aa739de05e379ab6f868bae84ab4eac288ad85c328cd1ec9e53 + languageName: node + linkType: hard + +"humanize-ms@npm:^1.2.1": + version: 1.2.1 + resolution: "humanize-ms@npm:1.2.1" + dependencies: + ms: ^2.0.0 + checksum: 9c7a74a2827f9294c009266c82031030eae811ca87b0da3dceb8d6071b9bde22c9f3daef0469c3c533cc67a97d8a167cd9fc0389350e5f415f61a79b171ded16 + languageName: node + linkType: hard + +"iconv-lite@npm:^0.6.2": + version: 0.6.3 + resolution: "iconv-lite@npm:0.6.3" + dependencies: + safer-buffer: ">= 2.1.2 < 3.0.0" + checksum: 3f60d47a5c8fc3313317edfd29a00a692cc87a19cac0159e2ce711d0ebc9019064108323b5e493625e25594f11c6236647d8e256fbe7a58f4a3b33b89e6d30bf + languageName: node + linkType: hard + +"ignore@npm:^4.0.6": + version: 4.0.6 + resolution: "ignore@npm:4.0.6" + checksum: 248f82e50a430906f9ee7f35e1158e3ec4c3971451dd9f99c9bc1548261b4db2b99709f60ac6c6cac9333494384176cc4cc9b07acbe42d52ac6a09cad734d800 + languageName: node + linkType: hard + +"ignore@npm:^5.1.8, ignore@npm:^5.2.0": + version: 5.2.0 + resolution: "ignore@npm:5.2.0" + checksum: 6b1f926792d614f64c6c83da3a1f9c83f6196c2839aa41e1e32dd7b8d174cef2e329d75caabb62cb61ce9dc432f75e67d07d122a037312db7caa73166a1bdb77 + languageName: node + linkType: hard + +"import-fresh@npm:^3.0.0, import-fresh@npm:^3.2.1": + version: 3.3.0 + resolution: "import-fresh@npm:3.3.0" + dependencies: + parent-module: ^1.0.0 + resolve-from: ^4.0.0 + checksum: 2cacfad06e652b1edc50be650f7ec3be08c5e5a6f6d12d035c440a42a8cc028e60a5b99ca08a77ab4d6b1346da7d971915828f33cdab730d3d42f08242d09baa + languageName: node + linkType: hard + +"imurmurhash@npm:^0.1.4": + version: 0.1.4 + resolution: "imurmurhash@npm:0.1.4" + checksum: 7cae75c8cd9a50f57dadd77482359f659eaebac0319dd9368bcd1714f55e65badd6929ca58569da2b6494ef13fdd5598cd700b1eba23f8b79c5f19d195a3ecf7 + languageName: node + linkType: hard + +"indent-string@npm:^4.0.0": + version: 4.0.0 + resolution: "indent-string@npm:4.0.0" + checksum: 824cfb9929d031dabf059bebfe08cf3137365e112019086ed3dcff6a0a7b698cb80cf67ccccde0e25b9e2d7527aa6cc1fed1ac490c752162496caba3e6699612 + languageName: node + linkType: hard + +"infer-owner@npm:^1.0.4": + version: 1.0.4 + resolution: "infer-owner@npm:1.0.4" + checksum: 181e732764e4a0611576466b4b87dac338972b839920b2a8cde43642e4ed6bd54dc1fb0b40874728f2a2df9a1b097b8ff83b56d5f8f8e3927f837fdcb47d8a89 + languageName: node + linkType: hard + +"inflight@npm:^1.0.4": + version: 1.0.6 + resolution: "inflight@npm:1.0.6" + dependencies: + once: ^1.3.0 + wrappy: 1 + checksum: f4f76aa072ce19fae87ce1ef7d221e709afb59d445e05d47fba710e85470923a75de35bfae47da6de1b18afc3ce83d70facf44cfb0aff89f0a3f45c0a0244dfd + languageName: node + linkType: hard + +"inherits@npm:2, inherits@npm:^2.0.3": + version: 2.0.4 + resolution: "inherits@npm:2.0.4" + checksum: 4a48a733847879d6cf6691860a6b1e3f0f4754176e4d71494c41f3475553768b10f84b5ce1d40fbd0e34e6bfbb864ee35858ad4dd2cf31e02fc4a154b724d7f1 + languageName: node + linkType: hard + +"intercom-client@workspace:.": + version: 0.0.0-use.local + resolution: "intercom-client@workspace:." + dependencies: + "@istanbuljs/nyc-config-typescript": ^1.0.2 + "@types/lodash": ^4.14.176 + "@types/mocha": ^9.1.0 + "@types/node": ^16.11.6 + "@types/sinon": ^10.0.6 + "@typescript-eslint/eslint-plugin": ^5.7.0 + "@typescript-eslint/parser": ^5.7.0 + axios: ^0.24.0 + eslint: ^8.2.0 + eslint-config-prettier: ^8.3.0 + htmlencode: ^0.0.4 + lodash: ^4.17.21 + merge2: ^1.4.1 + mocha: ^9.2.0 + nock: ^13.0.11 + nyc: ^15.1.0 + prettier: ^2.5.1 + sinon: ^7.3.2 + ts-node: ^10.4.0 + tslib: ^2.3.1 + typescript: ^4.5.3 + languageName: unknown + linkType: soft + +"ip@npm:^1.1.5": + version: 1.1.5 + resolution: "ip@npm:1.1.5" + checksum: 30133981f082a060a32644f6a7746e9ba7ac9e2bc07ecc8bbdda3ee8ca9bec1190724c390e45a1ee7695e7edfd2a8f7dda2c104ec5f7ac5068c00648504c7e5a + languageName: node + linkType: hard + +"is-binary-path@npm:~2.1.0": + version: 2.1.0 + resolution: "is-binary-path@npm:2.1.0" + dependencies: + binary-extensions: ^2.0.0 + checksum: 84192eb88cff70d320426f35ecd63c3d6d495da9d805b19bc65b518984b7c0760280e57dbf119b7e9be6b161784a5a673ab2c6abe83abb5198a432232ad5b35c + languageName: node + linkType: hard + +"is-extglob@npm:^2.1.1": + version: 2.1.1 + resolution: "is-extglob@npm:2.1.1" + checksum: df033653d06d0eb567461e58a7a8c9f940bd8c22274b94bf7671ab36df5719791aae15eef6d83bbb5e23283967f2f984b8914559d4449efda578c775c4be6f85 + languageName: node + linkType: hard + +"is-fullwidth-code-point@npm:^3.0.0": + version: 3.0.0 + resolution: "is-fullwidth-code-point@npm:3.0.0" + checksum: 44a30c29457c7fb8f00297bce733f0a64cd22eca270f83e58c105e0d015e45c019491a4ab2faef91ab51d4738c670daff901c799f6a700e27f7314029e99e348 + languageName: node + linkType: hard + +"is-glob@npm:^4.0.0, is-glob@npm:^4.0.1, is-glob@npm:^4.0.3, is-glob@npm:~4.0.1": + version: 4.0.3 + resolution: "is-glob@npm:4.0.3" + dependencies: + is-extglob: ^2.1.1 + checksum: d381c1319fcb69d341cc6e6c7cd588e17cd94722d9a32dbd60660b993c4fb7d0f19438674e68dfec686d09b7c73139c9166b47597f846af387450224a8101ab4 + languageName: node + linkType: hard + +"is-lambda@npm:^1.0.1": + version: 1.0.1 + resolution: "is-lambda@npm:1.0.1" + checksum: 93a32f01940220532e5948538699ad610d5924ac86093fcee83022252b363eb0cc99ba53ab084a04e4fb62bf7b5731f55496257a4c38adf87af9c4d352c71c35 + languageName: node + linkType: hard + +"is-number@npm:^7.0.0": + version: 7.0.0 + resolution: "is-number@npm:7.0.0" + checksum: 456ac6f8e0f3111ed34668a624e45315201dff921e5ac181f8ec24923b99e9f32ca1a194912dc79d539c97d33dba17dc635202ff0b2cf98326f608323276d27a + languageName: node + linkType: hard + +"is-plain-obj@npm:^2.1.0": + version: 2.1.0 + resolution: "is-plain-obj@npm:2.1.0" + checksum: cec9100678b0a9fe0248a81743041ed990c2d4c99f893d935545cfbc42876cbe86d207f3b895700c690ad2fa520e568c44afc1605044b535a7820c1d40e38daa + languageName: node + linkType: hard + +"is-stream@npm:^2.0.0": + version: 2.0.1 + resolution: "is-stream@npm:2.0.1" + checksum: b8e05ccdf96ac330ea83c12450304d4a591f9958c11fd17bed240af8d5ffe08aedafa4c0f4cfccd4d28dc9d4d129daca1023633d5c11601a6cbc77521f6fae66 + languageName: node + linkType: hard + +"is-typedarray@npm:^1.0.0": + version: 1.0.0 + resolution: "is-typedarray@npm:1.0.0" + checksum: 3508c6cd0a9ee2e0df2fa2e9baabcdc89e911c7bd5cf64604586697212feec525aa21050e48affb5ffc3df20f0f5d2e2cf79b08caa64e1ccc9578e251763aef7 + languageName: node + linkType: hard + +"is-unicode-supported@npm:^0.1.0": + version: 0.1.0 + resolution: "is-unicode-supported@npm:0.1.0" + checksum: a2aab86ee7712f5c2f999180daaba5f361bdad1efadc9610ff5b8ab5495b86e4f627839d085c6530363c6d6d4ecbde340fb8e54bdb83da4ba8e0865ed5513c52 + languageName: node + linkType: hard + +"is-windows@npm:^1.0.2": + version: 1.0.2 + resolution: "is-windows@npm:1.0.2" + checksum: 438b7e52656fe3b9b293b180defb4e448088e7023a523ec21a91a80b9ff8cdb3377ddb5b6e60f7c7de4fa8b63ab56e121b6705fe081b3cf1b828b0a380009ad7 + languageName: node + linkType: hard + +"isarray@npm:0.0.1": + version: 0.0.1 + resolution: "isarray@npm:0.0.1" + checksum: 49191f1425681df4a18c2f0f93db3adb85573bcdd6a4482539d98eac9e705d8961317b01175627e860516a2fc45f8f9302db26e5a380a97a520e272e2a40a8d4 + languageName: node + linkType: hard + +"isexe@npm:^2.0.0": + version: 2.0.0 + resolution: "isexe@npm:2.0.0" + checksum: 26bf6c5480dda5161c820c5b5c751ae1e766c587b1f951ea3fcfc973bafb7831ae5b54a31a69bd670220e42e99ec154475025a468eae58ea262f813fdc8d1c62 + languageName: node + linkType: hard + +"istanbul-lib-coverage@npm:^3.0.0, istanbul-lib-coverage@npm:^3.0.0-alpha.1": + version: 3.2.0 + resolution: "istanbul-lib-coverage@npm:3.2.0" + checksum: a2a545033b9d56da04a8571ed05c8120bf10e9bce01cf8633a3a2b0d1d83dff4ac4fe78d6d5673c27fc29b7f21a41d75f83a36be09f82a61c367b56aa73c1ff9 + languageName: node + linkType: hard + +"istanbul-lib-hook@npm:^3.0.0": + version: 3.0.0 + resolution: "istanbul-lib-hook@npm:3.0.0" + dependencies: + append-transform: ^2.0.0 + checksum: ac4d0a0751e959cfe4c95d817df5f1f573f9b0cf892552e60d81785654291391fac1ceb667f13bb17fcc2ef23b74c89ed8cf1c6148c833c8596a2b920b079101 + languageName: node + linkType: hard + +"istanbul-lib-instrument@npm:^4.0.0": + version: 4.0.3 + resolution: "istanbul-lib-instrument@npm:4.0.3" + dependencies: + "@babel/core": ^7.7.5 + "@istanbuljs/schema": ^0.1.2 + istanbul-lib-coverage: ^3.0.0 + semver: ^6.3.0 + checksum: fa1171d3022b1bb8f6a734042620ac5d9ee7dc80f3065a0bb12863e9f0494d0eefa3d86608fcc0254ab2765d29d7dad8bdc42e5f8df2f9a1fbe85ccc59d76cb9 + languageName: node + linkType: hard + +"istanbul-lib-processinfo@npm:^2.0.2": + version: 2.0.2 + resolution: "istanbul-lib-processinfo@npm:2.0.2" + dependencies: + archy: ^1.0.0 + cross-spawn: ^7.0.0 + istanbul-lib-coverage: ^3.0.0-alpha.1 + make-dir: ^3.0.0 + p-map: ^3.0.0 + rimraf: ^3.0.0 + uuid: ^3.3.3 + checksum: 400bd0b25b623c172e48d37e5bdda7a58b2fe5beeedfeb03099aed3385223d31e4cfa6f9932be07bbf06cfd039023301bce81d3b70b9a20a79a38b0f12cb261a + languageName: node + linkType: hard + +"istanbul-lib-report@npm:^3.0.0": + version: 3.0.0 + resolution: "istanbul-lib-report@npm:3.0.0" + dependencies: + istanbul-lib-coverage: ^3.0.0 + make-dir: ^3.0.0 + supports-color: ^7.1.0 + checksum: 3f29eb3f53c59b987386e07fe772d24c7f58c6897f34c9d7a296f4000de7ae3de9eb95c3de3df91dc65b134c84dee35c54eee572a56243e8907c48064e34ff1b + languageName: node + linkType: hard + +"istanbul-lib-source-maps@npm:^4.0.0": + version: 4.0.1 + resolution: "istanbul-lib-source-maps@npm:4.0.1" + dependencies: + debug: ^4.1.1 + istanbul-lib-coverage: ^3.0.0 + source-map: ^0.6.1 + checksum: 21ad3df45db4b81852b662b8d4161f6446cd250c1ddc70ef96a585e2e85c26ed7cd9c2a396a71533cfb981d1a645508bc9618cae431e55d01a0628e7dec62ef2 + languageName: node + linkType: hard + +"istanbul-reports@npm:^3.0.2": + version: 3.1.3 + resolution: "istanbul-reports@npm:3.1.3" + dependencies: + html-escaper: ^2.0.0 + istanbul-lib-report: ^3.0.0 + checksum: ef6e0d9ed05ecab1974c6eb46cc2a12d8570911934192db4ed40cf1978449240ea80aae32c4dd5555b67407cdf860212d1a9e415443af69641aa57ed1da5ebbb + languageName: node + linkType: hard + +"js-tokens@npm:^4.0.0": + version: 4.0.0 + resolution: "js-tokens@npm:4.0.0" + checksum: 8a95213a5a77deb6cbe94d86340e8d9ace2b93bc367790b260101d2f36a2eaf4e4e22d9fa9cf459b38af3a32fb4190e638024cf82ec95ef708680e405ea7cc78 + languageName: node + linkType: hard + +"js-yaml@npm:4.1.0, js-yaml@npm:^4.1.0": + version: 4.1.0 + resolution: "js-yaml@npm:4.1.0" + dependencies: + argparse: ^2.0.1 + bin: + js-yaml: bin/js-yaml.js + checksum: c7830dfd456c3ef2c6e355cc5a92e6700ceafa1d14bba54497b34a99f0376cecbb3e9ac14d3e5849b426d5a5140709a66237a8c991c675431271c4ce5504151a + languageName: node + linkType: hard + +"js-yaml@npm:^3.13.1": + version: 3.14.1 + resolution: "js-yaml@npm:3.14.1" + dependencies: + argparse: ^1.0.7 + esprima: ^4.0.0 + bin: + js-yaml: bin/js-yaml.js + checksum: bef146085f472d44dee30ec34e5cf36bf89164f5d585435a3d3da89e52622dff0b188a580e4ad091c3341889e14cb88cac6e4deb16dc5b1e9623bb0601fc255c + languageName: node + linkType: hard + +"jsesc@npm:^2.5.1": + version: 2.5.2 + resolution: "jsesc@npm:2.5.2" + bin: + jsesc: bin/jsesc + checksum: 4dc190771129e12023f729ce20e1e0bfceac84d73a85bc3119f7f938843fe25a4aeccb54b6494dce26fcf263d815f5f31acdefac7cc9329efb8422a4f4d9fa9d + languageName: node + linkType: hard + +"json-schema-traverse@npm:^0.4.1": + version: 0.4.1 + resolution: "json-schema-traverse@npm:0.4.1" + checksum: 7486074d3ba247769fda17d5181b345c9fb7d12e0da98b22d1d71a5db9698d8b4bd900a3ec1a4ffdd60846fc2556274a5c894d0c48795f14cb03aeae7b55260b + languageName: node + linkType: hard + +"json-stable-stringify-without-jsonify@npm:^1.0.1": + version: 1.0.1 + resolution: "json-stable-stringify-without-jsonify@npm:1.0.1" + checksum: cff44156ddce9c67c44386ad5cddf91925fe06b1d217f2da9c4910d01f358c6e3989c4d5a02683c7a5667f9727ff05831f7aa8ae66c8ff691c556f0884d49215 + languageName: node + linkType: hard + +"json-stringify-safe@npm:^5.0.1": + version: 5.0.1 + resolution: "json-stringify-safe@npm:5.0.1" + checksum: 48ec0adad5280b8a96bb93f4563aa1667fd7a36334f79149abd42446d0989f2ddc58274b479f4819f1f00617957e6344c886c55d05a4e15ebb4ab931e4a6a8ee + languageName: node + linkType: hard + +"json5@npm:^2.1.2": + version: 2.2.0 + resolution: "json5@npm:2.2.0" + dependencies: + minimist: ^1.2.5 + bin: + json5: lib/cli.js + checksum: e88fc5274bb58fc99547baa777886b069d2dd96d9cfc4490b305fd16d711dabd5979e35a4f90873cefbeb552e216b041a304fe56702bedba76e19bc7845f208d + languageName: node + linkType: hard + +"just-extend@npm:^4.0.2": + version: 4.2.1 + resolution: "just-extend@npm:4.2.1" + checksum: ff9fdede240fad313efeeeb68a660b942e5586d99c0058064c78884894a2690dc09bba44c994ad4e077e45d913fef01a9240c14a72c657b53687ac58de53b39c + languageName: node + linkType: hard + +"levn@npm:^0.4.1": + version: 0.4.1 + resolution: "levn@npm:0.4.1" + dependencies: + prelude-ls: ^1.2.1 + type-check: ~0.4.0 + checksum: 12c5021c859bd0f5248561bf139121f0358285ec545ebf48bb3d346820d5c61a4309535c7f387ed7d84361cf821e124ce346c6b7cef8ee09a67c1473b46d0fc4 + languageName: node + linkType: hard + +"locate-path@npm:^5.0.0": + version: 5.0.0 + resolution: "locate-path@npm:5.0.0" + dependencies: + p-locate: ^4.1.0 + checksum: 83e51725e67517287d73e1ded92b28602e3ae5580b301fe54bfb76c0c723e3f285b19252e375712316774cf52006cb236aed5704692c32db0d5d089b69696e30 + languageName: node + linkType: hard + +"locate-path@npm:^6.0.0": + version: 6.0.0 + resolution: "locate-path@npm:6.0.0" + dependencies: + p-locate: ^5.0.0 + checksum: 72eb661788a0368c099a184c59d2fee760b3831c9c1c33955e8a19ae4a21b4116e53fa736dc086cdeb9fce9f7cc508f2f92d2d3aae516f133e16a2bb59a39f5a + languageName: node + linkType: hard + +"lodash.flattendeep@npm:^4.4.0": + version: 4.4.0 + resolution: "lodash.flattendeep@npm:4.4.0" + checksum: 8521c919acac3d4bcf0aaf040c1ca9cb35d6c617e2d72e9b4d51c9a58b4366622cd6077441a18be626c3f7b28227502b3bf042903d447b056ee7e0b11d45c722 + languageName: node + linkType: hard + +"lodash.merge@npm:^4.6.2": + version: 4.6.2 + resolution: "lodash.merge@npm:4.6.2" + checksum: ad580b4bdbb7ca1f7abf7e1bce63a9a0b98e370cf40194b03380a46b4ed799c9573029599caebc1b14e3f24b111aef72b96674a56cfa105e0f5ac70546cdc005 + languageName: node + linkType: hard + +"lodash.set@npm:^4.3.2": + version: 4.3.2 + resolution: "lodash.set@npm:4.3.2" + checksum: a9122f49eef9f2d0fc9061a33d87f8e5b8c6b23d46e8b9e9ce1529d3588d79741bd1145a3abdfa3b13082703e65af27ff18d8a07bfc22b9be32f3fc36f763f70 + languageName: node + linkType: hard + +"lodash@npm:^4.17.15, lodash@npm:^4.17.21": + version: 4.17.21 + resolution: "lodash@npm:4.17.21" + checksum: eb835a2e51d381e561e508ce932ea50a8e5a68f4ebdd771ea240d3048244a8d13658acbd502cd4829768c56f2e16bdd4340b9ea141297d472517b83868e677f7 + languageName: node + linkType: hard + +"log-symbols@npm:4.1.0": + version: 4.1.0 + resolution: "log-symbols@npm:4.1.0" + dependencies: + chalk: ^4.1.0 + is-unicode-supported: ^0.1.0 + checksum: fce1497b3135a0198803f9f07464165e9eb83ed02ceb2273930a6f8a508951178d8cf4f0378e9d28300a2ed2bc49050995d2bd5f53ab716bb15ac84d58c6ef74 + languageName: node + linkType: hard + +"lolex@npm:^4.2.0": + version: 4.2.0 + resolution: "lolex@npm:4.2.0" + checksum: 0a83bfe1748fc745515dff9b3f722422918f5f6975104d7e576fc32c06b5398ee0c58525684068d4de49cdd49874e00b5e2b2d72ce8c5d829dab86c8c08ca31f + languageName: node + linkType: hard + +"lolex@npm:^5.0.1": + version: 5.1.2 + resolution: "lolex@npm:5.1.2" + dependencies: + "@sinonjs/commons": ^1.7.0 + checksum: 7eb468d4ef4746c024d23cb2b75f679f79449a9d5cbe11abadf2f3b147c1d7ffe28816438bedfb8a75c58357a625c2f9ba197b050c226d2b3f0c4a956cf556fb + languageName: node + linkType: hard + +"lru-cache@npm:^6.0.0": + version: 6.0.0 + resolution: "lru-cache@npm:6.0.0" + dependencies: + yallist: ^4.0.0 + checksum: f97f499f898f23e4585742138a22f22526254fdba6d75d41a1c2526b3b6cc5747ef59c5612ba7375f42aca4f8461950e925ba08c991ead0651b4918b7c978297 + languageName: node + linkType: hard + +"make-dir@npm:^3.0.0, make-dir@npm:^3.0.2": + version: 3.1.0 + resolution: "make-dir@npm:3.1.0" + dependencies: + semver: ^6.0.0 + checksum: 484200020ab5a1fdf12f393fe5f385fc8e4378824c940fba1729dcd198ae4ff24867bc7a5646331e50cead8abff5d9270c456314386e629acec6dff4b8016b78 + languageName: node + linkType: hard + +"make-error@npm:^1.1.1": + version: 1.3.6 + resolution: "make-error@npm:1.3.6" + checksum: b86e5e0e25f7f777b77fabd8e2cbf15737972869d852a22b7e73c17623928fccb826d8e46b9951501d3f20e51ad74ba8c59ed584f610526a48f8ccf88aaec402 + languageName: node + linkType: hard + +"make-fetch-happen@npm:^9.1.0": + version: 9.1.0 + resolution: "make-fetch-happen@npm:9.1.0" + dependencies: + agentkeepalive: ^4.1.3 + cacache: ^15.2.0 + http-cache-semantics: ^4.1.0 + http-proxy-agent: ^4.0.1 + https-proxy-agent: ^5.0.0 + is-lambda: ^1.0.1 + lru-cache: ^6.0.0 + minipass: ^3.1.3 + minipass-collect: ^1.0.2 + minipass-fetch: ^1.3.2 + minipass-flush: ^1.0.5 + minipass-pipeline: ^1.2.4 + negotiator: ^0.6.2 + promise-retry: ^2.0.1 + socks-proxy-agent: ^6.0.0 + ssri: ^8.0.0 + checksum: 0eb371c85fdd0b1584fcfdf3dc3c62395761b3c14658be02620c310305a9a7ecf1617a5e6fb30c1d081c5c8aaf177fa133ee225024313afabb7aa6a10f1e3d04 + languageName: node + linkType: hard + +"merge2@npm:^1.3.0, merge2@npm:^1.4.1": + version: 1.4.1 + resolution: "merge2@npm:1.4.1" + checksum: 7268db63ed5169466540b6fb947aec313200bcf6d40c5ab722c22e242f651994619bcd85601602972d3c85bd2cc45a358a4c61937e9f11a061919a1da569b0c2 + languageName: node + linkType: hard + +"micromatch@npm:^4.0.4": + version: 4.0.4 + resolution: "micromatch@npm:4.0.4" + dependencies: + braces: ^3.0.1 + picomatch: ^2.2.3 + checksum: ef3d1c88e79e0a68b0e94a03137676f3324ac18a908c245a9e5936f838079fcc108ac7170a5fadc265a9c2596963462e402841406bda1a4bb7b68805601d631c + languageName: node + linkType: hard + +"minimatch@npm:3.0.4, minimatch@npm:^3.0.4": + version: 3.0.4 + resolution: "minimatch@npm:3.0.4" + dependencies: + brace-expansion: ^1.1.7 + checksum: 66ac295f8a7b59788000ea3749938b0970344c841750abd96694f80269b926ebcafad3deeb3f1da2522978b119e6ae3a5869b63b13a7859a456b3408bd18a078 + languageName: node + linkType: hard + +"minimist@npm:^1.2.5": + version: 1.2.5 + resolution: "minimist@npm:1.2.5" + checksum: 86706ce5b36c16bfc35c5fe3dbb01d5acdc9a22f2b6cc810b6680656a1d2c0e44a0159c9a3ba51fb072bb5c203e49e10b51dcd0eec39c481f4c42086719bae52 + languageName: node + linkType: hard + +"minipass-collect@npm:^1.0.2": + version: 1.0.2 + resolution: "minipass-collect@npm:1.0.2" + dependencies: + minipass: ^3.0.0 + checksum: 14df761028f3e47293aee72888f2657695ec66bd7d09cae7ad558da30415fdc4752bbfee66287dcc6fd5e6a2fa3466d6c484dc1cbd986525d9393b9523d97f10 + languageName: node + linkType: hard + +"minipass-fetch@npm:^1.3.2": + version: 1.4.1 + resolution: "minipass-fetch@npm:1.4.1" + dependencies: + encoding: ^0.1.12 + minipass: ^3.1.0 + minipass-sized: ^1.0.3 + minizlib: ^2.0.0 + dependenciesMeta: + encoding: + optional: true + checksum: ec93697bdb62129c4e6c0104138e681e30efef8c15d9429dd172f776f83898471bc76521b539ff913248cc2aa6d2b37b652c993504a51cc53282563640f29216 + languageName: node + linkType: hard + +"minipass-flush@npm:^1.0.5": + version: 1.0.5 + resolution: "minipass-flush@npm:1.0.5" + dependencies: + minipass: ^3.0.0 + checksum: 56269a0b22bad756a08a94b1ffc36b7c9c5de0735a4dd1ab2b06c066d795cfd1f0ac44a0fcae13eece5589b908ecddc867f04c745c7009be0b566421ea0944cf + languageName: node + linkType: hard + +"minipass-pipeline@npm:^1.2.2, minipass-pipeline@npm:^1.2.4": + version: 1.2.4 + resolution: "minipass-pipeline@npm:1.2.4" + dependencies: + minipass: ^3.0.0 + checksum: b14240dac0d29823c3d5911c286069e36d0b81173d7bdf07a7e4a91ecdef92cdff4baaf31ea3746f1c61e0957f652e641223970870e2353593f382112257971b + languageName: node + linkType: hard + +"minipass-sized@npm:^1.0.3": + version: 1.0.3 + resolution: "minipass-sized@npm:1.0.3" + dependencies: + minipass: ^3.0.0 + checksum: 79076749fcacf21b5d16dd596d32c3b6bf4d6e62abb43868fac21674078505c8b15eaca4e47ed844985a4514854f917d78f588fcd029693709417d8f98b2bd60 + languageName: node + linkType: hard + +"minipass@npm:^3.0.0, minipass@npm:^3.1.0, minipass@npm:^3.1.1, minipass@npm:^3.1.3": + version: 3.1.6 + resolution: "minipass@npm:3.1.6" + dependencies: + yallist: ^4.0.0 + checksum: 57a04041413a3531a65062452cb5175f93383ef245d6f4a2961d34386eb9aa8ac11ac7f16f791f5e8bbaf1dfb1ef01596870c88e8822215db57aa591a5bb0a77 + languageName: node + linkType: hard + +"minizlib@npm:^2.0.0, minizlib@npm:^2.1.1": + version: 2.1.2 + resolution: "minizlib@npm:2.1.2" + dependencies: + minipass: ^3.0.0 + yallist: ^4.0.0 + checksum: f1fdeac0b07cf8f30fcf12f4b586795b97be856edea22b5e9072707be51fc95d41487faec3f265b42973a304fe3a64acd91a44a3826a963e37b37bafde0212c3 + languageName: node + linkType: hard + +"mkdirp@npm:^1.0.3, mkdirp@npm:^1.0.4": + version: 1.0.4 + resolution: "mkdirp@npm:1.0.4" + bin: + mkdirp: bin/cmd.js + checksum: a96865108c6c3b1b8e1d5e9f11843de1e077e57737602de1b82030815f311be11f96f09cce59bd5b903d0b29834733e5313f9301e3ed6d6f6fba2eae0df4298f + languageName: node + linkType: hard + +"mocha@npm:^9.2.0": + version: 9.2.0 + resolution: "mocha@npm:9.2.0" + dependencies: + "@ungap/promise-all-settled": 1.1.2 + ansi-colors: 4.1.1 + browser-stdout: 1.3.1 + chokidar: 3.5.3 + debug: 4.3.3 + diff: 5.0.0 + escape-string-regexp: 4.0.0 + find-up: 5.0.0 + glob: 7.2.0 + growl: 1.10.5 + he: 1.2.0 + js-yaml: 4.1.0 + log-symbols: 4.1.0 + minimatch: 3.0.4 + ms: 2.1.3 + nanoid: 3.2.0 + serialize-javascript: 6.0.0 + strip-json-comments: 3.1.1 + supports-color: 8.1.1 + which: 2.0.2 + workerpool: 6.2.0 + yargs: 16.2.0 + yargs-parser: 20.2.4 + yargs-unparser: 2.0.0 + bin: + _mocha: bin/_mocha + mocha: bin/mocha + checksum: 49efc4724cf17087c7e107bc8f6890db24525e6dcc153b801da58de3c2a2f940e22f7600ef195b8ac62a0dfd7baee5cf289fc4641a6b1fdf8bc9c819efc1a8ba + languageName: node + linkType: hard + +"ms@npm:2.1.2": + version: 2.1.2 + resolution: "ms@npm:2.1.2" + checksum: 673cdb2c3133eb050c745908d8ce632ed2c02d85640e2edb3ace856a2266a813b30c613569bf3354fdf4ea7d1a1494add3bfa95e2713baa27d0c2c71fc44f58f + languageName: node + linkType: hard + +"ms@npm:2.1.3, ms@npm:^2.0.0": + version: 2.1.3 + resolution: "ms@npm:2.1.3" + checksum: aa92de608021b242401676e35cfa5aa42dd70cbdc082b916da7fb925c542173e36bce97ea3e804923fe92c0ad991434e4a38327e15a1b5b5f945d66df615ae6d + languageName: node + linkType: hard + +"nanoid@npm:3.2.0": + version: 3.2.0 + resolution: "nanoid@npm:3.2.0" + bin: + nanoid: bin/nanoid.cjs + checksum: 3d1d5a69fea84e538057cf64106e713931c4ef32af344068ecff153ff91252f39b0f2b472e09b0dfff43ac3cf520c92938d90e6455121fe93976e23660f4fccc + languageName: node + linkType: hard + +"natural-compare@npm:^1.4.0": + version: 1.4.0 + resolution: "natural-compare@npm:1.4.0" + checksum: 23ad088b08f898fc9b53011d7bb78ec48e79de7627e01ab5518e806033861bef68d5b0cd0e2205c2f36690ac9571ff6bcb05eb777ced2eeda8d4ac5b44592c3d + languageName: node + linkType: hard + +"negotiator@npm:^0.6.2": + version: 0.6.3 + resolution: "negotiator@npm:0.6.3" + checksum: b8ffeb1e262eff7968fc90a2b6767b04cfd9842582a9d0ece0af7049537266e7b2506dfb1d107a32f06dd849ab2aea834d5830f7f4d0e5cb7d36e1ae55d021d9 + languageName: node + linkType: hard + +"nise@npm:^1.5.2": + version: 1.5.3 + resolution: "nise@npm:1.5.3" + dependencies: + "@sinonjs/formatio": ^3.2.1 + "@sinonjs/text-encoding": ^0.7.1 + just-extend: ^4.0.2 + lolex: ^5.0.1 + path-to-regexp: ^1.7.0 + checksum: ec3af21345dcaf34650a6f5420a11e0fd21a836ac5960f5e8523c301ee98465abf88b958f7b3084ecc6e0a7133e5cf7963f4df176b90b423c4da4984f1ebd75e + languageName: node + linkType: hard + +"nock@npm:^13.0.11": + version: 13.2.2 + resolution: "nock@npm:13.2.2" + dependencies: + debug: ^4.1.0 + json-stringify-safe: ^5.0.1 + lodash.set: ^4.3.2 + propagate: ^2.0.0 + checksum: cc1bf6e4bbf2fb0a540aa7d5f82788a6fb2490034083ed89242becc0ff1bfb391bfd3c7a7a9c0f24dec9c085426f66441765756b279a7dd608e4630586f9cb0d + languageName: node + linkType: hard + +"node-gyp@npm:latest": + version: 8.4.1 + resolution: "node-gyp@npm:8.4.1" + dependencies: + env-paths: ^2.2.0 + glob: ^7.1.4 + graceful-fs: ^4.2.6 + make-fetch-happen: ^9.1.0 + nopt: ^5.0.0 + npmlog: ^6.0.0 + rimraf: ^3.0.2 + semver: ^7.3.5 + tar: ^6.1.2 + which: ^2.0.2 + bin: + node-gyp: bin/node-gyp.js + checksum: 341710b5da39d3660e6a886b37e210d33f8282047405c2e62c277bcc744c7552c5b8b972ebc3a7d5c2813794e60cc48c3ebd142c46d6e0321db4db6c92dd0355 + languageName: node + linkType: hard + +"node-preload@npm:^0.2.1": + version: 0.2.1 + resolution: "node-preload@npm:0.2.1" + dependencies: + process-on-spawn: ^1.0.0 + checksum: 4586f91ac7417b33accce0ac629fb60f642d0c8d212b3c536dc3dda37fe54f8a3b858273380e1036e41a65d85470332c358315d2288e6584260d620fb4b00fb3 + languageName: node + linkType: hard + +"node-releases@npm:^2.0.1": + version: 2.0.1 + resolution: "node-releases@npm:2.0.1" + checksum: b20dd8d4bced11f75060f0387e05e76b9dc4a0451f7bb3516eade6f50499ea7768ba95d8a60d520c193402df1e58cb3fe301510cc1c1ad68949c3d57b5149866 + languageName: node + linkType: hard + +"nopt@npm:^5.0.0": + version: 5.0.0 + resolution: "nopt@npm:5.0.0" + dependencies: + abbrev: 1 + bin: + nopt: bin/nopt.js + checksum: d35fdec187269503843924e0114c0c6533fb54bbf1620d0f28b4b60ba01712d6687f62565c55cc20a504eff0fbe5c63e22340c3fad549ad40469ffb611b04f2f + languageName: node + linkType: hard + +"normalize-path@npm:^3.0.0, normalize-path@npm:~3.0.0": + version: 3.0.0 + resolution: "normalize-path@npm:3.0.0" + checksum: 88eeb4da891e10b1318c4b2476b6e2ecbeb5ff97d946815ffea7794c31a89017c70d7f34b3c2ebf23ef4e9fc9fb99f7dffe36da22011b5b5c6ffa34f4873ec20 + languageName: node + linkType: hard + +"npmlog@npm:^6.0.0": + version: 6.0.0 + resolution: "npmlog@npm:6.0.0" + dependencies: + are-we-there-yet: ^2.0.0 + console-control-strings: ^1.1.0 + gauge: ^4.0.0 + set-blocking: ^2.0.0 + checksum: 33d8a7fe3d63bf83b16655b6588ae7ba10b5f37b067a661e7cab6508660d7c3204ae716ee2c5ce4eb9626fd1489cf2fa7645d789bc3b704f8c3ccb04a532a50b + languageName: node + linkType: hard + +"nyc@npm:^15.1.0": + version: 15.1.0 + resolution: "nyc@npm:15.1.0" + dependencies: + "@istanbuljs/load-nyc-config": ^1.0.0 + "@istanbuljs/schema": ^0.1.2 + caching-transform: ^4.0.0 + convert-source-map: ^1.7.0 + decamelize: ^1.2.0 + find-cache-dir: ^3.2.0 + find-up: ^4.1.0 + foreground-child: ^2.0.0 + get-package-type: ^0.1.0 + glob: ^7.1.6 + istanbul-lib-coverage: ^3.0.0 + istanbul-lib-hook: ^3.0.0 + istanbul-lib-instrument: ^4.0.0 + istanbul-lib-processinfo: ^2.0.2 + istanbul-lib-report: ^3.0.0 + istanbul-lib-source-maps: ^4.0.0 + istanbul-reports: ^3.0.2 + make-dir: ^3.0.0 + node-preload: ^0.2.1 + p-map: ^3.0.0 + process-on-spawn: ^1.0.0 + resolve-from: ^5.0.0 + rimraf: ^3.0.0 + signal-exit: ^3.0.2 + spawn-wrap: ^2.0.0 + test-exclude: ^6.0.0 + yargs: ^15.0.2 + bin: + nyc: bin/nyc.js + checksum: 82a7031982df2fd6ab185c9f1b5d032b6221846268007b45b5773c6582e776ab33e96cd22b4231520345942fcef69b4339bd967675b8483f3fa255b56326faef + languageName: node + linkType: hard + +"once@npm:^1.3.0": + version: 1.4.0 + resolution: "once@npm:1.4.0" + dependencies: + wrappy: 1 + checksum: cd0a88501333edd640d95f0d2700fbde6bff20b3d4d9bdc521bdd31af0656b5706570d6c6afe532045a20bb8dc0849f8332d6f2a416e0ba6d3d3b98806c7db68 + languageName: node + linkType: hard + +"optionator@npm:^0.9.1": + version: 0.9.1 + resolution: "optionator@npm:0.9.1" + dependencies: + deep-is: ^0.1.3 + fast-levenshtein: ^2.0.6 + levn: ^0.4.1 + prelude-ls: ^1.2.1 + type-check: ^0.4.0 + word-wrap: ^1.2.3 + checksum: dbc6fa065604b24ea57d734261914e697bd73b69eff7f18e967e8912aa2a40a19a9f599a507fa805be6c13c24c4eae8c71306c239d517d42d4c041c942f508a0 + languageName: node + linkType: hard + +"p-limit@npm:^2.2.0": + version: 2.3.0 + resolution: "p-limit@npm:2.3.0" + dependencies: + p-try: ^2.0.0 + checksum: 84ff17f1a38126c3314e91ecfe56aecbf36430940e2873dadaa773ffe072dc23b7af8e46d4b6485d302a11673fe94c6b67ca2cfbb60c989848b02100d0594ac1 + languageName: node + linkType: hard + +"p-limit@npm:^3.0.2": + version: 3.1.0 + resolution: "p-limit@npm:3.1.0" + dependencies: + yocto-queue: ^0.1.0 + checksum: 7c3690c4dbf62ef625671e20b7bdf1cbc9534e83352a2780f165b0d3ceba21907e77ad63401708145ca4e25bfc51636588d89a8c0aeb715e6c37d1c066430360 + languageName: node + linkType: hard + +"p-locate@npm:^4.1.0": + version: 4.1.0 + resolution: "p-locate@npm:4.1.0" + dependencies: + p-limit: ^2.2.0 + checksum: 513bd14a455f5da4ebfcb819ef706c54adb09097703de6aeaa5d26fe5ea16df92b48d1ac45e01e3944ce1e6aa2a66f7f8894742b8c9d6e276e16cd2049a2b870 + languageName: node + linkType: hard + +"p-locate@npm:^5.0.0": + version: 5.0.0 + resolution: "p-locate@npm:5.0.0" + dependencies: + p-limit: ^3.0.2 + checksum: 1623088f36cf1cbca58e9b61c4e62bf0c60a07af5ae1ca99a720837356b5b6c5ba3eb1b2127e47a06865fee59dd0453cad7cc844cda9d5a62ac1a5a51b7c86d3 + languageName: node + linkType: hard + +"p-map@npm:^3.0.0": + version: 3.0.0 + resolution: "p-map@npm:3.0.0" + dependencies: + aggregate-error: ^3.0.0 + checksum: 49b0fcbc66b1ef9cd379de1b4da07fa7a9f84b41509ea3f461c31903623aaba8a529d22f835e0d77c7cb9fcc16e4fae71e308fd40179aea514ba68f27032b5d5 + languageName: node + linkType: hard + +"p-map@npm:^4.0.0": + version: 4.0.0 + resolution: "p-map@npm:4.0.0" + dependencies: + aggregate-error: ^3.0.0 + checksum: cb0ab21ec0f32ddffd31dfc250e3afa61e103ef43d957cc45497afe37513634589316de4eb88abdfd969fe6410c22c0b93ab24328833b8eb1ccc087fc0442a1c + languageName: node + linkType: hard + +"p-try@npm:^2.0.0": + version: 2.2.0 + resolution: "p-try@npm:2.2.0" + checksum: f8a8e9a7693659383f06aec604ad5ead237c7a261c18048a6e1b5b85a5f8a067e469aa24f5bc009b991ea3b058a87f5065ef4176793a200d4917349881216cae + languageName: node + linkType: hard + +"package-hash@npm:^4.0.0": + version: 4.0.0 + resolution: "package-hash@npm:4.0.0" + dependencies: + graceful-fs: ^4.1.15 + hasha: ^5.0.0 + lodash.flattendeep: ^4.4.0 + release-zalgo: ^1.0.0 + checksum: 32c49e3a0e1c4a33b086a04cdd6d6e570aee019cb8402ec16476d9b3564a40e38f91ce1a1f9bc88b08f8ef2917a11e0b786c08140373bdf609ea90749031e6fc + languageName: node + linkType: hard + +"parent-module@npm:^1.0.0": + version: 1.0.1 + resolution: "parent-module@npm:1.0.1" + dependencies: + callsites: ^3.0.0 + checksum: 6ba8b255145cae9470cf5551eb74be2d22281587af787a2626683a6c20fbb464978784661478dd2a3f1dad74d1e802d403e1b03c1a31fab310259eec8ac560ff + languageName: node + linkType: hard + +"path-exists@npm:^4.0.0": + version: 4.0.0 + resolution: "path-exists@npm:4.0.0" + checksum: 505807199dfb7c50737b057dd8d351b82c033029ab94cb10a657609e00c1bc53b951cfdbccab8de04c5584d5eff31128ce6afd3db79281874a5ef2adbba55ed1 + languageName: node + linkType: hard + +"path-is-absolute@npm:^1.0.0": + version: 1.0.1 + resolution: "path-is-absolute@npm:1.0.1" + checksum: 060840f92cf8effa293bcc1bea81281bd7d363731d214cbe5c227df207c34cd727430f70c6037b5159c8a870b9157cba65e775446b0ab06fd5ecc7e54615a3b8 + languageName: node + linkType: hard + +"path-key@npm:^3.1.0": + version: 3.1.1 + resolution: "path-key@npm:3.1.1" + checksum: 55cd7a9dd4b343412a8386a743f9c746ef196e57c823d90ca3ab917f90ab9f13dd0ded27252ba49dbdfcab2b091d998bc446f6220cd3cea65db407502a740020 + languageName: node + linkType: hard + +"path-to-regexp@npm:^1.7.0": + version: 1.8.0 + resolution: "path-to-regexp@npm:1.8.0" + dependencies: + isarray: 0.0.1 + checksum: 709f6f083c0552514ef4780cb2e7e4cf49b0cc89a97439f2b7cc69a608982b7690fb5d1720a7473a59806508fc2dae0be751ba49f495ecf89fd8fbc62abccbcd + languageName: node + linkType: hard + +"path-type@npm:^4.0.0": + version: 4.0.0 + resolution: "path-type@npm:4.0.0" + checksum: 5b1e2daa247062061325b8fdbfd1fb56dde0a448fb1455453276ea18c60685bdad23a445dc148cf87bc216be1573357509b7d4060494a6fd768c7efad833ee45 + languageName: node + linkType: hard + +"picocolors@npm:^1.0.0": + version: 1.0.0 + resolution: "picocolors@npm:1.0.0" + checksum: a2e8092dd86c8396bdba9f2b5481032848525b3dc295ce9b57896f931e63fc16f79805144321f72976383fc249584672a75cc18d6777c6b757603f372f745981 + languageName: node + linkType: hard + +"picomatch@npm:^2.0.4, picomatch@npm:^2.2.1, picomatch@npm:^2.2.3": + version: 2.3.1 + resolution: "picomatch@npm:2.3.1" + checksum: 050c865ce81119c4822c45d3c84f1ced46f93a0126febae20737bd05ca20589c564d6e9226977df859ed5e03dc73f02584a2b0faad36e896936238238b0446cf + languageName: node + linkType: hard + +"pkg-dir@npm:^4.1.0": + version: 4.2.0 + resolution: "pkg-dir@npm:4.2.0" + dependencies: + find-up: ^4.0.0 + checksum: 9863e3f35132bf99ae1636d31ff1e1e3501251d480336edb1c211133c8d58906bed80f154a1d723652df1fda91e01c7442c2eeaf9dc83157c7ae89087e43c8d6 + languageName: node + linkType: hard + +"prelude-ls@npm:^1.2.1": + version: 1.2.1 + resolution: "prelude-ls@npm:1.2.1" + checksum: cd192ec0d0a8e4c6da3bb80e4f62afe336df3f76271ac6deb0e6a36187133b6073a19e9727a1ff108cd8b9982e4768850d413baa71214dd80c7979617dca827a + languageName: node + linkType: hard + +"prettier@npm:^2.5.1": + version: 2.5.1 + resolution: "prettier@npm:2.5.1" + bin: + prettier: bin-prettier.js + checksum: 21b9408476ea1c544b0e45d51ceb94a84789ff92095abb710942d780c862d0daebdb29972d47f6b4d0f7ebbfb0ffbf56cc2cfa3e3e9d1cca54864af185b15b66 + languageName: node + linkType: hard + +"process-on-spawn@npm:^1.0.0": + version: 1.0.0 + resolution: "process-on-spawn@npm:1.0.0" + dependencies: + fromentries: ^1.2.0 + checksum: 597769e3db6a8e2cb1cd64a952bbc150220588debac31c7cf1a9f620ce981e25583d8d70848d8a14953577608512984a8808c3be77e09af8ebdcdc14ec23a295 + languageName: node + linkType: hard + +"promise-inflight@npm:^1.0.1": + version: 1.0.1 + resolution: "promise-inflight@npm:1.0.1" + checksum: 22749483091d2c594261517f4f80e05226d4d5ecc1fc917e1886929da56e22b5718b7f2a75f3807e7a7d471bc3be2907fe92e6e8f373ddf5c64bae35b5af3981 + languageName: node + linkType: hard + +"promise-retry@npm:^2.0.1": + version: 2.0.1 + resolution: "promise-retry@npm:2.0.1" + dependencies: + err-code: ^2.0.2 + retry: ^0.12.0 + checksum: f96a3f6d90b92b568a26f71e966cbbc0f63ab85ea6ff6c81284dc869b41510e6cdef99b6b65f9030f0db422bf7c96652a3fff9f2e8fb4a0f069d8f4430359429 + languageName: node + linkType: hard + +"propagate@npm:^2.0.0": + version: 2.0.1 + resolution: "propagate@npm:2.0.1" + checksum: c4febaee2be0979e82fb6b3727878fd122a98d64a7fa3c9d09b0576751b88514a9e9275b1b92e76b364d488f508e223bd7e1dcdc616be4cdda876072fbc2a96c + languageName: node + linkType: hard + +"punycode@npm:^2.1.0": + version: 2.1.1 + resolution: "punycode@npm:2.1.1" + checksum: 823bf443c6dd14f669984dea25757b37993f67e8d94698996064035edd43bed8a5a17a9f12e439c2b35df1078c6bec05a6c86e336209eb1061e8025c481168e8 + languageName: node + linkType: hard + +"queue-microtask@npm:^1.2.2": + version: 1.2.3 + resolution: "queue-microtask@npm:1.2.3" + checksum: b676f8c040cdc5b12723ad2f91414d267605b26419d5c821ff03befa817ddd10e238d22b25d604920340fd73efd8ba795465a0377c4adf45a4a41e4234e42dc4 + languageName: node + linkType: hard + +"randombytes@npm:^2.1.0": + version: 2.1.0 + resolution: "randombytes@npm:2.1.0" + dependencies: + safe-buffer: ^5.1.0 + checksum: d779499376bd4cbb435ef3ab9a957006c8682f343f14089ed5f27764e4645114196e75b7f6abf1cbd84fd247c0cb0651698444df8c9bf30e62120fbbc52269d6 + languageName: node + linkType: hard + +"readable-stream@npm:^3.6.0": + version: 3.6.0 + resolution: "readable-stream@npm:3.6.0" + dependencies: + inherits: ^2.0.3 + string_decoder: ^1.1.1 + util-deprecate: ^1.0.1 + checksum: d4ea81502d3799439bb955a3a5d1d808592cf3133350ed352aeaa499647858b27b1c4013984900238b0873ec8d0d8defce72469fb7a83e61d53f5ad61cb80dc8 + languageName: node + linkType: hard + +"readdirp@npm:~3.6.0": + version: 3.6.0 + resolution: "readdirp@npm:3.6.0" + dependencies: + picomatch: ^2.2.1 + checksum: 1ced032e6e45670b6d7352d71d21ce7edf7b9b928494dcaba6f11fba63180d9da6cd7061ebc34175ffda6ff529f481818c962952004d273178acd70f7059b320 + languageName: node + linkType: hard + +"regexpp@npm:^3.2.0": + version: 3.2.0 + resolution: "regexpp@npm:3.2.0" + checksum: a78dc5c7158ad9ddcfe01aa9144f46e192ddbfa7b263895a70a5c6c73edd9ce85faf7c0430e59ac38839e1734e275b9c3de5c57ee3ab6edc0e0b1bdebefccef8 + languageName: node + linkType: hard + +"release-zalgo@npm:^1.0.0": + version: 1.0.0 + resolution: "release-zalgo@npm:1.0.0" + dependencies: + es6-error: ^4.0.1 + checksum: b59849dc310f6c426f34e308c48ba83df3d034ddef75189951723bb2aac99d29d15f5e127edad951c4095fc9025aa582053907154d68fe0c5380cd6a75365e53 + languageName: node + linkType: hard + +"require-directory@npm:^2.1.1": + version: 2.1.1 + resolution: "require-directory@npm:2.1.1" + checksum: fb47e70bf0001fdeabdc0429d431863e9475e7e43ea5f94ad86503d918423c1543361cc5166d713eaa7029dd7a3d34775af04764bebff99ef413111a5af18c80 + languageName: node + linkType: hard + +"require-main-filename@npm:^2.0.0": + version: 2.0.0 + resolution: "require-main-filename@npm:2.0.0" + checksum: e9e294695fea08b076457e9ddff854e81bffbe248ed34c1eec348b7abbd22a0d02e8d75506559e2265e96978f3c4720bd77a6dad84755de8162b357eb6c778c7 + languageName: node + linkType: hard + +"resolve-from@npm:^4.0.0": + version: 4.0.0 + resolution: "resolve-from@npm:4.0.0" + checksum: f4ba0b8494846a5066328ad33ef8ac173801a51739eb4d63408c847da9a2e1c1de1e6cbbf72699211f3d13f8fc1325648b169bd15eb7da35688e30a5fb0e4a7f + languageName: node + linkType: hard + +"resolve-from@npm:^5.0.0": + version: 5.0.0 + resolution: "resolve-from@npm:5.0.0" + checksum: 4ceeb9113e1b1372d0cd969f3468fa042daa1dd9527b1b6bb88acb6ab55d8b9cd65dbf18819f9f9ddf0db804990901dcdaade80a215e7b2c23daae38e64f5bdf + languageName: node + linkType: hard + +"retry@npm:^0.12.0": + version: 0.12.0 + resolution: "retry@npm:0.12.0" + checksum: 623bd7d2e5119467ba66202d733ec3c2e2e26568074923bc0585b6b99db14f357e79bdedb63cab56cec47491c4a0da7e6021a7465ca6dc4f481d3898fdd3158c + languageName: node + linkType: hard + +"reusify@npm:^1.0.4": + version: 1.0.4 + resolution: "reusify@npm:1.0.4" + checksum: c3076ebcc22a6bc252cb0b9c77561795256c22b757f40c0d8110b1300723f15ec0fc8685e8d4ea6d7666f36c79ccc793b1939c748bf36f18f542744a4e379fcc + languageName: node + linkType: hard + +"rimraf@npm:^3.0.0, rimraf@npm:^3.0.2": + version: 3.0.2 + resolution: "rimraf@npm:3.0.2" + dependencies: + glob: ^7.1.3 + bin: + rimraf: bin.js + checksum: 87f4164e396f0171b0a3386cc1877a817f572148ee13a7e113b238e48e8a9f2f31d009a92ec38a591ff1567d9662c6b67fd8818a2dbbaed74bc26a87a2a4a9a0 + languageName: node + linkType: hard + +"run-parallel@npm:^1.1.9": + version: 1.2.0 + resolution: "run-parallel@npm:1.2.0" + dependencies: + queue-microtask: ^1.2.2 + checksum: cb4f97ad25a75ebc11a8ef4e33bb962f8af8516bb2001082ceabd8902e15b98f4b84b4f8a9b222e5d57fc3bd1379c483886ed4619367a7680dad65316993021d + languageName: node + linkType: hard + +"safe-buffer@npm:^5.1.0, safe-buffer@npm:~5.2.0": + version: 5.2.1 + resolution: "safe-buffer@npm:5.2.1" + checksum: b99c4b41fdd67a6aaf280fcd05e9ffb0813654894223afb78a31f14a19ad220bba8aba1cb14eddce1fcfb037155fe6de4e861784eb434f7d11ed58d1e70dd491 + languageName: node + linkType: hard + +"safe-buffer@npm:~5.1.1": + version: 5.1.2 + resolution: "safe-buffer@npm:5.1.2" + checksum: f2f1f7943ca44a594893a852894055cf619c1fbcb611237fc39e461ae751187e7baf4dc391a72125e0ac4fb2d8c5c0b3c71529622e6a58f46b960211e704903c + languageName: node + linkType: hard + +"safer-buffer@npm:>= 2.1.2 < 3.0.0": + version: 2.1.2 + resolution: "safer-buffer@npm:2.1.2" + checksum: cab8f25ae6f1434abee8d80023d7e72b598cf1327164ddab31003c51215526801e40b66c5e65d658a0af1e9d6478cadcb4c745f4bd6751f97d8644786c0978b0 + languageName: node + linkType: hard + +"semver@npm:^6.0.0, semver@npm:^6.3.0": + version: 6.3.0 + resolution: "semver@npm:6.3.0" + bin: + semver: ./bin/semver.js + checksum: 1b26ecf6db9e8292dd90df4e781d91875c0dcc1b1909e70f5d12959a23c7eebb8f01ea581c00783bbee72ceeaad9505797c381756326073850dc36ed284b21b9 + languageName: node + linkType: hard + +"semver@npm:^7.3.5": + version: 7.3.5 + resolution: "semver@npm:7.3.5" + dependencies: + lru-cache: ^6.0.0 + bin: + semver: bin/semver.js + checksum: 5eafe6102bea2a7439897c1856362e31cc348ccf96efd455c8b5bc2c61e6f7e7b8250dc26b8828c1d76a56f818a7ee907a36ae9fb37a599d3d24609207001d60 + languageName: node + linkType: hard + +"serialize-javascript@npm:6.0.0": + version: 6.0.0 + resolution: "serialize-javascript@npm:6.0.0" + dependencies: + randombytes: ^2.1.0 + checksum: 56f90b562a1bdc92e55afb3e657c6397c01a902c588c0fe3d4c490efdcc97dcd2a3074ba12df9e94630f33a5ce5b76a74784a7041294628a6f4306e0ec84bf93 + languageName: node + linkType: hard + +"set-blocking@npm:^2.0.0": + version: 2.0.0 + resolution: "set-blocking@npm:2.0.0" + checksum: 6e65a05f7cf7ebdf8b7c75b101e18c0b7e3dff4940d480efed8aad3a36a4005140b660fa1d804cb8bce911cac290441dc728084a30504d3516ac2ff7ad607b02 + languageName: node + linkType: hard + +"shebang-command@npm:^2.0.0": + version: 2.0.0 + resolution: "shebang-command@npm:2.0.0" + dependencies: + shebang-regex: ^3.0.0 + checksum: 6b52fe87271c12968f6a054e60f6bde5f0f3d2db483a1e5c3e12d657c488a15474121a1d55cd958f6df026a54374ec38a4a963988c213b7570e1d51575cea7fa + languageName: node + linkType: hard + +"shebang-regex@npm:^3.0.0": + version: 3.0.0 + resolution: "shebang-regex@npm:3.0.0" + checksum: 1a2bcae50de99034fcd92ad4212d8e01eedf52c7ec7830eedcf886622804fe36884278f2be8be0ea5fde3fd1c23911643a4e0f726c8685b61871c8908af01222 + languageName: node + linkType: hard + +"signal-exit@npm:^3.0.0, signal-exit@npm:^3.0.2": + version: 3.0.6 + resolution: "signal-exit@npm:3.0.6" + checksum: b819ac81ba757af559dad0804233ae31bf6f054591cd8a671e9cbcf09f21c72ec3076fe87d1e04861f5b33b47d63f0694b568de99c99cd733ee2060515beb6d5 + languageName: node + linkType: hard + +"sinon@npm:^7.3.2": + version: 7.5.0 + resolution: "sinon@npm:7.5.0" + dependencies: + "@sinonjs/commons": ^1.4.0 + "@sinonjs/formatio": ^3.2.1 + "@sinonjs/samsam": ^3.3.3 + diff: ^3.5.0 + lolex: ^4.2.0 + nise: ^1.5.2 + supports-color: ^5.5.0 + checksum: e8cf6b3dd16e9c1ed1a2b9560c396a2d6205a4f32293b1762cb6ebb8f88cfa47db6aba45b0c1709ec396efb41d171d88c9b1ab8f32f35512eb9e5d0d0d15d307 + languageName: node + linkType: hard + +"slash@npm:^3.0.0": + version: 3.0.0 + resolution: "slash@npm:3.0.0" + checksum: 94a93fff615f25a999ad4b83c9d5e257a7280c90a32a7cb8b4a87996e4babf322e469c42b7f649fd5796edd8687652f3fb452a86dc97a816f01113183393f11c + languageName: node + linkType: hard + +"smart-buffer@npm:^4.1.0": + version: 4.2.0 + resolution: "smart-buffer@npm:4.2.0" + checksum: b5167a7142c1da704c0e3af85c402002b597081dd9575031a90b4f229ca5678e9a36e8a374f1814c8156a725d17008ae3bde63b92f9cfd132526379e580bec8b + languageName: node + linkType: hard + +"socks-proxy-agent@npm:^6.0.0": + version: 6.1.1 + resolution: "socks-proxy-agent@npm:6.1.1" + dependencies: + agent-base: ^6.0.2 + debug: ^4.3.1 + socks: ^2.6.1 + checksum: 9a8a4f791bba0060315cf7291ca6f9db37d6fc280fd0860d73d8887d3efe4c22e823aa25a8d5375f6079279f8dc91b50c075345179bf832bfe3c7c26d3582e3c + languageName: node + linkType: hard + +"socks@npm:^2.6.1": + version: 2.6.1 + resolution: "socks@npm:2.6.1" + dependencies: + ip: ^1.1.5 + smart-buffer: ^4.1.0 + checksum: 2ca9d616e424f645838ebaabb04f85d94ea999e0f8393dc07f86c435af22ed88cb83958feeabd1bb7bc537c635ed47454255635502c6808a6df61af1f41af750 + languageName: node + linkType: hard + +"source-map@npm:^0.5.0": + version: 0.5.7 + resolution: "source-map@npm:0.5.7" + checksum: 5dc2043b93d2f194142c7f38f74a24670cd7a0063acdaf4bf01d2964b402257ae843c2a8fa822ad5b71013b5fcafa55af7421383da919752f22ff488bc553f4d + languageName: node + linkType: hard + +"source-map@npm:^0.6.1": + version: 0.6.1 + resolution: "source-map@npm:0.6.1" + checksum: 59ce8640cf3f3124f64ac289012c2b8bd377c238e316fb323ea22fbfe83da07d81e000071d7242cad7a23cd91c7de98e4df8830ec3f133cb6133a5f6e9f67bc2 + languageName: node + linkType: hard + +"spawn-wrap@npm:^2.0.0": + version: 2.0.0 + resolution: "spawn-wrap@npm:2.0.0" + dependencies: + foreground-child: ^2.0.0 + is-windows: ^1.0.2 + make-dir: ^3.0.0 + rimraf: ^3.0.0 + signal-exit: ^3.0.2 + which: ^2.0.1 + checksum: 5a518e37620def6d516b86207482a4f76bcf3c37c57d8d886d9fa399b04e5668d11fd12817b178029b02002a5ebbd09010374307effa821ba39594042f0a2d96 + languageName: node + linkType: hard + +"sprintf-js@npm:~1.0.2": + version: 1.0.3 + resolution: "sprintf-js@npm:1.0.3" + checksum: 19d79aec211f09b99ec3099b5b2ae2f6e9cdefe50bc91ac4c69144b6d3928a640bb6ae5b3def70c2e85a2c3d9f5ec2719921e3a59d3ca3ef4b2fd1a4656a0df3 + languageName: node + linkType: hard + +"ssri@npm:^8.0.0, ssri@npm:^8.0.1": + version: 8.0.1 + resolution: "ssri@npm:8.0.1" + dependencies: + minipass: ^3.1.1 + checksum: bc447f5af814fa9713aa201ec2522208ae0f4d8f3bda7a1f445a797c7b929a02720436ff7c478fb5edc4045adb02b1b88d2341b436a80798734e2494f1067b36 + languageName: node + linkType: hard + +"string-width@npm:^1.0.2 || 2 || 3 || 4, string-width@npm:^4.1.0, string-width@npm:^4.2.0, string-width@npm:^4.2.3": + version: 4.2.3 + resolution: "string-width@npm:4.2.3" + dependencies: + emoji-regex: ^8.0.0 + is-fullwidth-code-point: ^3.0.0 + strip-ansi: ^6.0.1 + checksum: e52c10dc3fbfcd6c3a15f159f54a90024241d0f149cf8aed2982a2d801d2e64df0bf1dc351cf8e95c3319323f9f220c16e740b06faecd53e2462df1d2b5443fb + languageName: node + linkType: hard + +"string_decoder@npm:^1.1.1": + version: 1.3.0 + resolution: "string_decoder@npm:1.3.0" + dependencies: + safe-buffer: ~5.2.0 + checksum: 8417646695a66e73aefc4420eb3b84cc9ffd89572861fe004e6aeb13c7bc00e2f616247505d2dbbef24247c372f70268f594af7126f43548565c68c117bdeb56 + languageName: node + linkType: hard + +"strip-ansi@npm:^6.0.0, strip-ansi@npm:^6.0.1": + version: 6.0.1 + resolution: "strip-ansi@npm:6.0.1" + dependencies: + ansi-regex: ^5.0.1 + checksum: f3cd25890aef3ba6e1a74e20896c21a46f482e93df4a06567cebf2b57edabb15133f1f94e57434e0a958d61186087b1008e89c94875d019910a213181a14fc8c + languageName: node + linkType: hard + +"strip-bom@npm:^4.0.0": + version: 4.0.0 + resolution: "strip-bom@npm:4.0.0" + checksum: 9dbcfbaf503c57c06af15fe2c8176fb1bf3af5ff65003851a102749f875a6dbe0ab3b30115eccf6e805e9d756830d3e40ec508b62b3f1ddf3761a20ebe29d3f3 + languageName: node + linkType: hard + +"strip-json-comments@npm:3.1.1, strip-json-comments@npm:^3.1.0, strip-json-comments@npm:^3.1.1": + version: 3.1.1 + resolution: "strip-json-comments@npm:3.1.1" + checksum: 492f73e27268f9b1c122733f28ecb0e7e8d8a531a6662efbd08e22cccb3f9475e90a1b82cab06a392f6afae6d2de636f977e231296400d0ec5304ba70f166443 + languageName: node + linkType: hard + +"supports-color@npm:8.1.1": + version: 8.1.1 + resolution: "supports-color@npm:8.1.1" + dependencies: + has-flag: ^4.0.0 + checksum: c052193a7e43c6cdc741eb7f378df605636e01ad434badf7324f17fb60c69a880d8d8fcdcb562cf94c2350e57b937d7425ab5b8326c67c2adc48f7c87c1db406 + languageName: node + linkType: hard + +"supports-color@npm:^5.3.0, supports-color@npm:^5.5.0": + version: 5.5.0 + resolution: "supports-color@npm:5.5.0" + dependencies: + has-flag: ^3.0.0 + checksum: 95f6f4ba5afdf92f495b5a912d4abee8dcba766ae719b975c56c084f5004845f6f5a5f7769f52d53f40e21952a6d87411bafe34af4a01e65f9926002e38e1dac + languageName: node + linkType: hard + +"supports-color@npm:^7.1.0": + version: 7.2.0 + resolution: "supports-color@npm:7.2.0" + dependencies: + has-flag: ^4.0.0 + checksum: 3dda818de06ebbe5b9653e07842d9479f3555ebc77e9a0280caf5a14fb877ffee9ed57007c3b78f5a6324b8dbeec648d9e97a24e2ed9fdb81ddc69ea07100f4a + languageName: node + linkType: hard + +"tar@npm:^6.0.2, tar@npm:^6.1.2": + version: 6.1.11 + resolution: "tar@npm:6.1.11" + dependencies: + chownr: ^2.0.0 + fs-minipass: ^2.0.0 + minipass: ^3.0.0 + minizlib: ^2.1.1 + mkdirp: ^1.0.3 + yallist: ^4.0.0 + checksum: a04c07bb9e2d8f46776517d4618f2406fb977a74d914ad98b264fc3db0fe8224da5bec11e5f8902c5b9bcb8ace22d95fbe3c7b36b8593b7dfc8391a25898f32f + languageName: node + linkType: hard + +"test-exclude@npm:^6.0.0": + version: 6.0.0 + resolution: "test-exclude@npm:6.0.0" + dependencies: + "@istanbuljs/schema": ^0.1.2 + glob: ^7.1.4 + minimatch: ^3.0.4 + checksum: 3b34a3d77165a2cb82b34014b3aba93b1c4637a5011807557dc2f3da826c59975a5ccad765721c4648b39817e3472789f9b0fa98fc854c5c1c7a1e632aacdc28 + languageName: node + linkType: hard + +"text-table@npm:^0.2.0": + version: 0.2.0 + resolution: "text-table@npm:0.2.0" + checksum: b6937a38c80c7f84d9c11dd75e49d5c44f71d95e810a3250bd1f1797fc7117c57698204adf676b71497acc205d769d65c16ae8fa10afad832ae1322630aef10a + languageName: node + linkType: hard + +"to-fast-properties@npm:^2.0.0": + version: 2.0.0 + resolution: "to-fast-properties@npm:2.0.0" + checksum: be2de62fe58ead94e3e592680052683b1ec986c72d589e7b21e5697f8744cdbf48c266fa72f6c15932894c10187b5f54573a3bcf7da0bfd964d5caf23d436168 + languageName: node + linkType: hard + +"to-regex-range@npm:^5.0.1": + version: 5.0.1 + resolution: "to-regex-range@npm:5.0.1" + dependencies: + is-number: ^7.0.0 + checksum: f76fa01b3d5be85db6a2a143e24df9f60dd047d151062d0ba3df62953f2f697b16fe5dad9b0ac6191c7efc7b1d9dcaa4b768174b7b29da89d4428e64bc0a20ed + languageName: node + linkType: hard + +"ts-node@npm:^10.4.0": + version: 10.4.0 + resolution: "ts-node@npm:10.4.0" + dependencies: + "@cspotcode/source-map-support": 0.7.0 + "@tsconfig/node10": ^1.0.7 + "@tsconfig/node12": ^1.0.7 + "@tsconfig/node14": ^1.0.0 + "@tsconfig/node16": ^1.0.2 + acorn: ^8.4.1 + acorn-walk: ^8.1.1 + arg: ^4.1.0 + create-require: ^1.1.0 + diff: ^4.0.1 + make-error: ^1.1.1 + yn: 3.1.1 + peerDependencies: + "@swc/core": ">=1.2.50" + "@swc/wasm": ">=1.2.50" + "@types/node": "*" + typescript: ">=2.7" + peerDependenciesMeta: + "@swc/core": + optional: true + "@swc/wasm": + optional: true + bin: + ts-node: dist/bin.js + ts-node-cwd: dist/bin-cwd.js + ts-node-script: dist/bin-script.js + ts-node-transpile-only: dist/bin-transpile.js + ts-script: dist/bin-script-deprecated.js + checksum: 3933ac0a937d33c45e04a6750fcdd3e765eb2897d1da1307cd97ac52af093bcfb632ec0453a75000a65c8b5b7bdb32b1077050a186dcc556e62657cb592e6d49 + languageName: node + linkType: hard + +"tslib@npm:^1.8.1": + version: 1.14.1 + resolution: "tslib@npm:1.14.1" + checksum: dbe628ef87f66691d5d2959b3e41b9ca0045c3ee3c7c7b906cc1e328b39f199bb1ad9e671c39025bd56122ac57dfbf7385a94843b1cc07c60a4db74795829acd + languageName: node + linkType: hard + +"tslib@npm:^2.3.1": + version: 2.3.1 + resolution: "tslib@npm:2.3.1" + checksum: de17a98d4614481f7fcb5cd53ffc1aaf8654313be0291e1bfaee4b4bb31a20494b7d218ff2e15017883e8ea9626599b3b0e0229c18383ba9dce89da2adf15cb9 + languageName: node + linkType: hard + +"tsutils@npm:^3.21.0": + version: 3.21.0 + resolution: "tsutils@npm:3.21.0" + dependencies: + tslib: ^1.8.1 + peerDependencies: + typescript: ">=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta" + checksum: 1843f4c1b2e0f975e08c4c21caa4af4f7f65a12ac1b81b3b8489366826259323feb3fc7a243123453d2d1a02314205a7634e048d4a8009921da19f99755cdc48 + languageName: node + linkType: hard + +"type-check@npm:^0.4.0, type-check@npm:~0.4.0": + version: 0.4.0 + resolution: "type-check@npm:0.4.0" + dependencies: + prelude-ls: ^1.2.1 + checksum: ec688ebfc9c45d0c30412e41ca9c0cdbd704580eb3a9ccf07b9b576094d7b86a012baebc95681999dd38f4f444afd28504cb3a89f2ef16b31d4ab61a0739025a + languageName: node + linkType: hard + +"type-detect@npm:4.0.8": + version: 4.0.8 + resolution: "type-detect@npm:4.0.8" + checksum: 62b5628bff67c0eb0b66afa371bd73e230399a8d2ad30d852716efcc4656a7516904570cd8631a49a3ce57c10225adf5d0cbdcb47f6b0255fe6557c453925a15 + languageName: node + linkType: hard + +"type-fest@npm:^0.20.2": + version: 0.20.2 + resolution: "type-fest@npm:0.20.2" + checksum: 4fb3272df21ad1c552486f8a2f8e115c09a521ad7a8db3d56d53718d0c907b62c6e9141ba5f584af3f6830d0872c521357e512381f24f7c44acae583ad517d73 + languageName: node + linkType: hard + +"type-fest@npm:^0.8.0": + version: 0.8.1 + resolution: "type-fest@npm:0.8.1" + checksum: d61c4b2eba24009033ae4500d7d818a94fd6d1b481a8111612ee141400d5f1db46f199c014766b9fa9b31a6a7374d96fc748c6d688a78a3ce5a33123839becb7 + languageName: node + linkType: hard + +"typedarray-to-buffer@npm:^3.1.5": + version: 3.1.5 + resolution: "typedarray-to-buffer@npm:3.1.5" + dependencies: + is-typedarray: ^1.0.0 + checksum: 99c11aaa8f45189fcfba6b8a4825fd684a321caa9bd7a76a27cf0c7732c174d198b99f449c52c3818107430b5f41c0ccbbfb75cb2ee3ca4a9451710986d61a60 + languageName: node + linkType: hard + +"typescript@npm:^4.5.3": + version: 4.5.5 + resolution: "typescript@npm:4.5.5" + bin: + tsc: bin/tsc + tsserver: bin/tsserver + checksum: 506f4c919dc8aeaafa92068c997f1d213b9df4d9756d0fae1a1e7ab66b585ab3498050e236113a1c9e57ee08c21ec6814ca7a7f61378c058d79af50a4b1f5a5e + languageName: node + linkType: hard + +"typescript@patch:typescript@^4.5.3#~builtin": + version: 4.5.5 + resolution: "typescript@patch:typescript@npm%3A4.5.5#~builtin::version=4.5.5&hash=493e53" + bin: + tsc: bin/tsc + tsserver: bin/tsserver + checksum: c05c318d79c690f101d7ffb34cd6c7d6bbd884d3af9cefe7749ad0cd6be43c7082f098280982ca945dcba23fde34a08fed9602bb26540936baf8c0520727d3ba + languageName: node + linkType: hard + +"unique-filename@npm:^1.1.1": + version: 1.1.1 + resolution: "unique-filename@npm:1.1.1" + dependencies: + unique-slug: ^2.0.0 + checksum: cf4998c9228cc7647ba7814e255dec51be43673903897b1786eff2ac2d670f54d4d733357eb08dea969aa5e6875d0e1bd391d668fbdb5a179744e7c7551a6f80 + languageName: node + linkType: hard + +"unique-slug@npm:^2.0.0": + version: 2.0.2 + resolution: "unique-slug@npm:2.0.2" + dependencies: + imurmurhash: ^0.1.4 + checksum: 5b6876a645da08d505dedb970d1571f6cebdf87044cb6b740c8dbb24f0d6e1dc8bdbf46825fd09f994d7cf50760e6f6e063cfa197d51c5902c00a861702eb75a + languageName: node + linkType: hard + +"uri-js@npm:^4.2.2": + version: 4.4.1 + resolution: "uri-js@npm:4.4.1" + dependencies: + punycode: ^2.1.0 + checksum: 7167432de6817fe8e9e0c9684f1d2de2bb688c94388f7569f7dbdb1587c9f4ca2a77962f134ec90be0cc4d004c939ff0d05acc9f34a0db39a3c797dada262633 + languageName: node + linkType: hard + +"util-deprecate@npm:^1.0.1": + version: 1.0.2 + resolution: "util-deprecate@npm:1.0.2" + checksum: 474acf1146cb2701fe3b074892217553dfcf9a031280919ba1b8d651a068c9b15d863b7303cb15bd00a862b498e6cf4ad7b4a08fb134edd5a6f7641681cb54a2 + languageName: node + linkType: hard + +"uuid@npm:^3.3.3": + version: 3.4.0 + resolution: "uuid@npm:3.4.0" + bin: + uuid: ./bin/uuid + checksum: 58de2feed61c59060b40f8203c0e4ed7fd6f99d42534a499f1741218a1dd0c129f4aa1de797bcf822c8ea5da7e4137aa3673431a96dae729047f7aca7b27866f + languageName: node + linkType: hard + +"v8-compile-cache@npm:^2.0.3": + version: 2.3.0 + resolution: "v8-compile-cache@npm:2.3.0" + checksum: adb0a271eaa2297f2f4c536acbfee872d0dd26ec2d76f66921aa7fc437319132773483344207bdbeee169225f4739016d8d2dbf0553913a52bb34da6d0334f8e + languageName: node + linkType: hard + +"which-module@npm:^2.0.0": + version: 2.0.0 + resolution: "which-module@npm:2.0.0" + checksum: 809f7fd3dfcb2cdbe0180b60d68100c88785084f8f9492b0998c051d7a8efe56784492609d3f09ac161635b78ea29219eb1418a98c15ce87d085bce905705c9c + languageName: node + linkType: hard + +"which@npm:2.0.2, which@npm:^2.0.1, which@npm:^2.0.2": + version: 2.0.2 + resolution: "which@npm:2.0.2" + dependencies: + isexe: ^2.0.0 + bin: + node-which: ./bin/node-which + checksum: 1a5c563d3c1b52d5f893c8b61afe11abc3bab4afac492e8da5bde69d550de701cf9806235f20a47b5c8fa8a1d6a9135841de2596535e998027a54589000e66d1 + languageName: node + linkType: hard + +"wide-align@npm:^1.1.2": + version: 1.1.5 + resolution: "wide-align@npm:1.1.5" + dependencies: + string-width: ^1.0.2 || 2 || 3 || 4 + checksum: d5fc37cd561f9daee3c80e03b92ed3e84d80dde3365a8767263d03dacfc8fa06b065ffe1df00d8c2a09f731482fcacae745abfbb478d4af36d0a891fad4834d3 + languageName: node + linkType: hard + +"word-wrap@npm:^1.2.3": + version: 1.2.3 + resolution: "word-wrap@npm:1.2.3" + checksum: 30b48f91fcf12106ed3186ae4fa86a6a1842416df425be7b60485de14bec665a54a68e4b5156647dec3a70f25e84d270ca8bc8cd23182ed095f5c7206a938c1f + languageName: node + linkType: hard + +"workerpool@npm:6.2.0": + version: 6.2.0 + resolution: "workerpool@npm:6.2.0" + checksum: 3493b4f0ef979a23d2c1583d7ef85f62fc9463cc02f82829d3e7e663b517f8ae9707da0249b382e46ac58986deb0ca2232ee1081713741211bda9254b429c9bb + languageName: node + linkType: hard + +"wrap-ansi@npm:^6.2.0": + version: 6.2.0 + resolution: "wrap-ansi@npm:6.2.0" + dependencies: + ansi-styles: ^4.0.0 + string-width: ^4.1.0 + strip-ansi: ^6.0.0 + checksum: 6cd96a410161ff617b63581a08376f0cb9162375adeb7956e10c8cd397821f7eb2a6de24eb22a0b28401300bf228c86e50617cd568209b5f6775b93c97d2fe3a + languageName: node + linkType: hard + +"wrap-ansi@npm:^7.0.0": + version: 7.0.0 + resolution: "wrap-ansi@npm:7.0.0" + dependencies: + ansi-styles: ^4.0.0 + string-width: ^4.1.0 + strip-ansi: ^6.0.0 + checksum: a790b846fd4505de962ba728a21aaeda189b8ee1c7568ca5e817d85930e06ef8d1689d49dbf0e881e8ef84436af3a88bc49115c2e2788d841ff1b8b5b51a608b + languageName: node + linkType: hard + +"wrappy@npm:1": + version: 1.0.2 + resolution: "wrappy@npm:1.0.2" + checksum: 159da4805f7e84a3d003d8841557196034155008f817172d4e986bd591f74aa82aa7db55929a54222309e01079a65a92a9e6414da5a6aa4b01ee44a511ac3ee5 + languageName: node + linkType: hard + +"write-file-atomic@npm:^3.0.0": + version: 3.0.3 + resolution: "write-file-atomic@npm:3.0.3" + dependencies: + imurmurhash: ^0.1.4 + is-typedarray: ^1.0.0 + signal-exit: ^3.0.2 + typedarray-to-buffer: ^3.1.5 + checksum: c55b24617cc61c3a4379f425fc62a386cc51916a9b9d993f39734d005a09d5a4bb748bc251f1304e7abd71d0a26d339996c275955f527a131b1dcded67878280 + languageName: node + linkType: hard + +"y18n@npm:^4.0.0": + version: 4.0.3 + resolution: "y18n@npm:4.0.3" + checksum: 014dfcd9b5f4105c3bb397c1c8c6429a9df004aa560964fb36732bfb999bfe83d45ae40aeda5b55d21b1ee53d8291580a32a756a443e064317953f08025b1aa4 + languageName: node + linkType: hard + +"y18n@npm:^5.0.5": + version: 5.0.8 + resolution: "y18n@npm:5.0.8" + checksum: 54f0fb95621ee60898a38c572c515659e51cc9d9f787fb109cef6fde4befbe1c4602dc999d30110feee37456ad0f1660fa2edcfde6a9a740f86a290999550d30 + languageName: node + linkType: hard + +"yallist@npm:^4.0.0": + version: 4.0.0 + resolution: "yallist@npm:4.0.0" + checksum: 343617202af32df2a15a3be36a5a8c0c8545208f3d3dfbc6bb7c3e3b7e8c6f8e7485432e4f3b88da3031a6e20afa7c711eded32ddfb122896ac5d914e75848d5 + languageName: node + linkType: hard + +"yargs-parser@npm:20.2.4": + version: 20.2.4 + resolution: "yargs-parser@npm:20.2.4" + checksum: d251998a374b2743a20271c2fd752b9fbef24eb881d53a3b99a7caa5e8227fcafd9abf1f345ac5de46435821be25ec12189a11030c12ee6481fef6863ed8b924 + languageName: node + linkType: hard + +"yargs-parser@npm:^18.1.2": + version: 18.1.3 + resolution: "yargs-parser@npm:18.1.3" + dependencies: + camelcase: ^5.0.0 + decamelize: ^1.2.0 + checksum: 60e8c7d1b85814594d3719300ecad4e6ae3796748b0926137bfec1f3042581b8646d67e83c6fc80a692ef08b8390f21ddcacb9464476c39bbdf52e34961dd4d9 + languageName: node + linkType: hard + +"yargs-parser@npm:^20.2.2": + version: 20.2.9 + resolution: "yargs-parser@npm:20.2.9" + checksum: 8bb69015f2b0ff9e17b2c8e6bfe224ab463dd00ca211eece72a4cd8a906224d2703fb8a326d36fdd0e68701e201b2a60ed7cf81ce0fd9b3799f9fe7745977ae3 + languageName: node + linkType: hard + +"yargs-unparser@npm:2.0.0": + version: 2.0.0 + resolution: "yargs-unparser@npm:2.0.0" + dependencies: + camelcase: ^6.0.0 + decamelize: ^4.0.0 + flat: ^5.0.2 + is-plain-obj: ^2.1.0 + checksum: 68f9a542c6927c3768c2f16c28f71b19008710abd6b8f8efbac6dcce26bbb68ab6503bed1d5994bdbc2df9a5c87c161110c1dfe04c6a3fe5c6ad1b0e15d9a8a3 + languageName: node + linkType: hard + +"yargs@npm:16.2.0": + version: 16.2.0 + resolution: "yargs@npm:16.2.0" + dependencies: + cliui: ^7.0.2 + escalade: ^3.1.1 + get-caller-file: ^2.0.5 + require-directory: ^2.1.1 + string-width: ^4.2.0 + y18n: ^5.0.5 + yargs-parser: ^20.2.2 + checksum: b14afbb51e3251a204d81937c86a7e9d4bdbf9a2bcee38226c900d00f522969ab675703bee2a6f99f8e20103f608382936034e64d921b74df82b63c07c5e8f59 + languageName: node + linkType: hard + +"yargs@npm:^15.0.2": + version: 15.4.1 + resolution: "yargs@npm:15.4.1" + dependencies: + cliui: ^6.0.0 + decamelize: ^1.2.0 + find-up: ^4.1.0 + get-caller-file: ^2.0.1 + require-directory: ^2.1.1 + require-main-filename: ^2.0.0 + set-blocking: ^2.0.0 + string-width: ^4.2.0 + which-module: ^2.0.0 + y18n: ^4.0.0 + yargs-parser: ^18.1.2 + checksum: 40b974f508d8aed28598087720e086ecd32a5fd3e945e95ea4457da04ee9bdb8bdd17fd91acff36dc5b7f0595a735929c514c40c402416bbb87c03f6fb782373 + languageName: node + linkType: hard + +"yn@npm:3.1.1": + version: 3.1.1 + resolution: "yn@npm:3.1.1" + checksum: 2c487b0e149e746ef48cda9f8bad10fc83693cd69d7f9dcd8be4214e985de33a29c9e24f3c0d6bcf2288427040a8947406ab27f7af67ee9456e6b84854f02dd6 + languageName: node + linkType: hard + +"yocto-queue@npm:^0.1.0": + version: 0.1.0 + resolution: "yocto-queue@npm:0.1.0" + checksum: f77b3d8d00310def622123df93d4ee654fc6a0096182af8bd60679ddcdfb3474c56c6c7190817c84a2785648cdee9d721c0154eb45698c62176c322fb46fc700 + languageName: node + linkType: hard From fb6db7be8dd0e93a3a75c23d8fac48393778c4e8 Mon Sep 17 00:00:00 2001 From: Volo Date: Mon, 31 Jan 2022 12:44:29 +0200 Subject: [PATCH 030/146] Fix dist throwing error --- package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 3e3ca7aa..c5724bca 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.0.0", + "version": "3.0.1", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", @@ -43,7 +43,7 @@ "typescript": "^4.5.3" }, "scripts": { - "clean": "rm -r dist", + "clean": "rm -r -f dist", "static": "eslint .", "compile_ts": "tsc", "move_compiled_to_dist": "mv dist/lib/* dist && rmdir dist/lib", From bf9453a150c360454fe2d36004575847a8504203 Mon Sep 17 00:00:00 2001 From: Volo Date: Mon, 31 Jan 2022 12:45:28 +0200 Subject: [PATCH 031/146] Fix GH templates Fix yarn version Experiment with CircleCI Experiment with CircleCI Experiment with CircleCI Experiment with CircleCI Remove commented --- .circleci/config.yml | 13 +------------ .github/PULL_REQUEST_TEMPLATE.md | 4 ---- 2 files changed, 1 insertion(+), 16 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 6a07a9f2..3bb0c374 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -6,21 +6,10 @@ jobs: working_directory: ~/intercom-node - environment: - - YARN_VERSION: 1.22.10 - steps: - checkout - run: export PATH="${PATH}:/home/circleci/.yarn/bin" - - run: - name: Install Yarn - command: | - if [[ ! -e ~/.yarn/bin/yarn || $(yarn --version) != "${YARN_VERSION}" ]]; then - echo "Download and install Yarn." - curl -o- -L https://yarnpkg.com/install.sh | bash -s -- --version $YARN_VERSION - else - echo "The correct version of Yarn is already installed." - fi + - run: npm install --prefix=$HOME/.local --global corepack - run: yarn - run: yarn test diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index 8d3b2c35..34874cdf 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -5,7 +5,3 @@ Why are you making this change? #### How? Technical details on your change - -#### QA - -Latest QA could be found on [branch `qa/should-never-be-merged-to-master`](https://github.com/intercom/intercom-node-v2/pull/10) From bd32dda15655758ff4eb50757e4107def6ff6852 Mon Sep 17 00:00:00 2001 From: Volo Date: Mon, 31 Jan 2022 16:26:56 +0200 Subject: [PATCH 032/146] Simplify types to be compatible with TS v3.X --- lib/common/common.types.ts | 62 ++++---------------------------------- lib/contact.ts | 5 ++- lib/conversation.ts | 5 ++- 3 files changed, 10 insertions(+), 62 deletions(-) diff --git a/lib/common/common.types.ts b/lib/common/common.types.ts index caa76ce7..70eddec3 100644 --- a/lib/common/common.types.ts +++ b/lib/common/common.types.ts @@ -24,56 +24,6 @@ export type Paginated = { total_count: number; }; -type Join = K extends string | number - ? P extends string | number - ? `${K}${'' extends P ? '' : '.'}${P}` - : never - : never; - -type Prev = [ - never, - 0, - 1, - 2, - 3, - 4, - 5, - 6, - 7, - 8, - 9, - 10, - 11, - 12, - 13, - 14, - 15, - 16, - 17, - 18, - 19, - 20, - ...0[] -]; - -// D is depth, we don't want to go past 3 nested objects -export type Paths = [D] extends [never] - ? never - : T extends object - ? { - [K in keyof T]-?: K extends string | number - ? `${K}` | Join> - : never; - }[keyof T] - : ''; - -// D is depth, we don't want to go past 3 nested objects -export type Leaves = [D] extends [never] - ? never - : T extends object - ? { [K in keyof T]-?: Join> }[keyof T] - : ''; - export enum Operators { AND = 'AND', OR = 'OR', @@ -89,19 +39,19 @@ export enum Operators { ENDS_WITH = '$', } -interface FlatQuery { - field: Leaves; +interface FlatQuery { + field: string; operator: Operators; value: string | number | null; } -interface NestedQueries { +interface NestedQueries { operator: Operators; - value: Array | NestedQueries> | string | number | null; + value: Array | string | number | null; } -export interface GenericSearchFilters { - query: FlatQuery | NestedQueries; +export interface GenericSearchFilters { + query: FlatQuery | NestedQueries; } export enum Order { diff --git a/lib/contact.ts b/lib/contact.ts index 5abf8a82..830275cb 100644 --- a/lib/contact.ts +++ b/lib/contact.ts @@ -3,7 +3,6 @@ import { ContactObject } from './contact/contact.types'; import { GenericDeletedResponse, GenericSearchFilters, - Leaves, Paginated, Role, } from './common/common.types'; @@ -287,13 +286,13 @@ interface SearchContactPagination { interface SearchContactOrder { sort: { - field: Leaves; + field: string; order: SearchContactOrderBy; }; } interface SearchContactRequest { - data: GenericSearchFilters & + data: GenericSearchFilters & Partial & Partial; } diff --git a/lib/conversation.ts b/lib/conversation.ts index 223ec29b..dd43fb8f 100644 --- a/lib/conversation.ts +++ b/lib/conversation.ts @@ -3,7 +3,6 @@ import { Paginated, StringifiedTimestamp, GenericSearchFilters, - Leaves, Order, } from './common/common.types'; import { @@ -499,13 +498,13 @@ interface SearchConversationPagination { interface SearchConversationOrder { sort: { - field: Leaves; + field: string; order: SearchConversationOrderBy; }; } interface SearchConversationRequest { - data: GenericSearchFilters & + data: GenericSearchFilters & Partial & Partial; } From c21d8e30af754fb579229f56563c4e697f1ddb2d Mon Sep 17 00:00:00 2001 From: Volo Date: Mon, 31 Jan 2022 16:31:40 +0200 Subject: [PATCH 033/146] Add building step for CI --- .circleci/config.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 3bb0c374..969d0b65 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -11,6 +11,7 @@ jobs: - run: export PATH="${PATH}:/home/circleci/.yarn/bin" - run: npm install --prefix=$HOME/.local --global corepack - run: yarn + - run: yarn prepublish - run: yarn test notify: From be1e5ed09ee74fb45297eb3ab709c0b45a7dfcd8 Mon Sep 17 00:00:00 2001 From: Volo Date: Tue, 1 Feb 2022 14:28:28 +0200 Subject: [PATCH 034/146] Add Notes --- README.md | 28 ++++++++++++++++++++ lib/admin/admin.types.ts | 2 +- lib/article.ts | 10 +++---- lib/client.ts | 5 +++- lib/common/common.types.ts | 4 +++ lib/helpCenter.ts | 10 +++---- lib/index.ts | 1 + lib/note.ts | 54 ++++++++++++++++++++++++++++++++++++++ lib/note/note.types.ts | 22 ++++++++++++++++ package.json | 2 +- test/notes.ts | 51 +++++++++++++++++++++++++++++++++++ 11 files changed, 176 insertions(+), 13 deletions(-) create mode 100644 lib/note.ts create mode 100644 lib/note/note.types.ts create mode 100644 test/notes.ts diff --git a/README.md b/README.md index dd6f86ac..452be6bf 100644 --- a/README.md +++ b/README.md @@ -948,6 +948,34 @@ const response = await client.messages.create({ }); ``` +### Notes + +#### [Create a note](https://developers.intercom.com/intercom-api-reference/reference/create-note-for-contact) + +```typescript +const response = await client.notes.create({ + adminId: '12345', + body: 'Shiny', + contactId: '5678', +}); +``` + +#### [Retrieve a note](https://developers.intercom.com/intercom-api-reference/reference/view-a-note) + +```typescript +const response = await client.notes.find({ id: '123' }); +``` + +#### [List all notes](https://developers.intercom.com/intercom-api-reference/reference/list-notes-of-contact) + +```typescript +const response = await client.notes.list({ + contactId: '123', + page: 2, + perPage: 3, +}); +``` + ### Segments #### [Retrieve a segment](https://developers.intercom.com/intercom-api-reference/reference/view-a-segment) diff --git a/lib/admin/admin.types.ts b/lib/admin/admin.types.ts index b319cfdf..421a69a7 100644 --- a/lib/admin/admin.types.ts +++ b/lib/admin/admin.types.ts @@ -8,5 +8,5 @@ export interface AdminObject { away_mode_reassign: boolean; has_inbox_seat: boolean; team_ids: Array; - avatar: string; + avatar: string | { image_url: string }; } diff --git a/lib/article.ts b/lib/article.ts index cefa6a1f..82436abd 100644 --- a/lib/article.ts +++ b/lib/article.ts @@ -3,7 +3,11 @@ import { ArticleObject, TranslatedContentObject, } from './article/article.types'; -import { GenericDeletedResponse, Paginated } from './common/common.types'; +import { + GenericDeletedResponse, + OperationById, + Paginated, +} from './common/common.types'; export default class Article { public readonly baseUrl = 'articles'; @@ -99,10 +103,6 @@ interface CreateArticleData { translatedContent?: Omit; } -interface OperationById { - id: string; -} - type ArticleFindByIdData = OperationById; type UpdateArticleData = Partial & OperationById; diff --git a/lib/client.ts b/lib/client.ts index f0b093c3..2973ca8d 100644 --- a/lib/client.ts +++ b/lib/client.ts @@ -10,8 +10,9 @@ import Contact from './contact'; import DataAttribute from './dataAttribute'; import Event from './event'; import HelpCenter from './helpCenter'; -import Segment from './segment'; import Message from './message'; +import Note from './note'; +import Segment from './segment'; import Team from './team'; import Tag from './tag'; @@ -58,6 +59,7 @@ export default class Client { events: Event; helpCenter: HelpCenter; messages: Message; + notes: Note; segments: Segment; passwordPart?: string; propertiesToOmitInRequestOpts: string[]; @@ -88,6 +90,7 @@ export default class Client { this.events = new Event(this); this.helpCenter = new HelpCenter(this); this.messages = new Message(this); + this.notes = new Note(this); this.segments = new Segment(this); this.tags = new Tag(this); this.teams = new Team(this); diff --git a/lib/common/common.types.ts b/lib/common/common.types.ts index 70eddec3..d35b2f6f 100644 --- a/lib/common/common.types.ts +++ b/lib/common/common.types.ts @@ -69,3 +69,7 @@ export interface GenericDeletedResponse { object: ObjectType; deleted: boolean; } + +export interface OperationById { + id: string; +} diff --git a/lib/helpCenter.ts b/lib/helpCenter.ts index de59e22c..b15351e5 100644 --- a/lib/helpCenter.ts +++ b/lib/helpCenter.ts @@ -1,5 +1,9 @@ import { Client } from '.'; -import { GenericDeletedResponse, Paginated } from './common/common.types'; +import { + GenericDeletedResponse, + OperationById, + Paginated, +} from './common/common.types'; import { CollectionObject, GroupTranslatedContentObject, @@ -165,7 +169,3 @@ type SectionListData = { }; type SectionListResponse = Paginated; - -interface OperationById { - id: string; -} diff --git a/lib/index.ts b/lib/index.ts index 40c8d1be..b2a40fd3 100644 --- a/lib/index.ts +++ b/lib/index.ts @@ -34,6 +34,7 @@ export * from './dataAttribute/dataAttribute.types'; export * from './event/event.types'; export * from './helpCenter/helpCenter.types'; export * from './message/message.types'; +export * from './note/note.types'; export * from './segment/segment.types'; export * from './subscription/subscription.types'; export * from './tag/tag.types'; diff --git a/lib/note.ts b/lib/note.ts new file mode 100644 index 00000000..a8dae2f9 --- /dev/null +++ b/lib/note.ts @@ -0,0 +1,54 @@ +import { Client, NoteObject } from '.'; +import { OperationById, Paginated } from './common/common.types'; + +export default class Note { + public readonly baseUrl = 'notes'; + + constructor(private readonly client: Client) { + this.client = client; + } + + create({ adminId, body, contactId }: CreateNoteData) { + const data = { + admin_id: adminId, + body, + }; + + return this.client.post({ + url: `/${this.client.contacts.baseUrl}/${contactId}/${this.baseUrl}`, + data, + }); + } + find({ id }: FindNoteByIdData) { + return this.client.get({ + url: `/${this.baseUrl}/${id}`, + }); + } + list({ contactId, page, perPage: per_page }: ListNotesData) { + const params = { + page, + per_page, + }; + + return this.client.get({ + url: `/${this.client.contacts.baseUrl}/${contactId}/${this.baseUrl}`, + params, + }); + } +} + +interface CreateNoteData { + adminId: string; + body: string; + contactId: string; +} + +type FindNoteByIdData = OperationById; + +type ListNotesData = { + contactId: string; + page?: number; + perPage?: number; +}; + +type ListNotesResponse = Paginated; diff --git a/lib/note/note.types.ts b/lib/note/note.types.ts new file mode 100644 index 00000000..818c627c --- /dev/null +++ b/lib/note/note.types.ts @@ -0,0 +1,22 @@ +import { AdminObject, Timestamp } from '..'; + +export type NoteObject = { + type: 'note'; + id: string; + created_at: Timestamp; + contact: { + type: 'contact'; + id: string; + }; + author?: Pick< + AdminObject, + | 'type' + | 'id' + | 'name' + | 'email' + | 'away_mode_enabled' + | 'away_mode_reassign' + | 'avatar' + >; + body: string; +}; diff --git a/package.json b/package.json index c5724bca..b0f4e51d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.0.1", + "version": "3.1.0", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", diff --git a/test/notes.ts b/test/notes.ts new file mode 100644 index 00000000..2ce9d602 --- /dev/null +++ b/test/notes.ts @@ -0,0 +1,51 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; + +describe('notes', () => { + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + it('creates new', async () => { + const contactId = 'baz'; + const requestBody = { + body: 'Shiny', + admin_id: '12345', + }; + + nock('https://api.intercom.io') + .post(`/contacts/${contactId}/notes`, requestBody) + .reply(200, {}); + const response = await client.notes.create({ + adminId: requestBody.admin_id, + body: requestBody.body, + contactId, + }); + + assert.deepStrictEqual({}, response); + }); + it('finds by id', async () => { + const id = 'beb'; + + nock('https://api.intercom.io').get(`/notes/${id}`).reply(200, {}); + const response = await client.notes.find({ id }); + + assert.deepStrictEqual({}, response); + }); + it('lists all for specific contact by id', async () => { + const contactId = 'yoopi'; + + nock('https://api.intercom.io') + .get(`/contacts/${contactId}/notes`) + .query({ page: 2, per_page: 3 }) + .reply(200, {}); + const response = await client.notes.list({ + contactId, + page: 2, + perPage: 3, + }); + + assert.deepStrictEqual({}, response); + }); +}); From e3d8ea464c5dc9cfaea5b5e8ba401f1cefd16399 Mon Sep 17 00:00:00 2001 From: Volo Date: Tue, 1 Feb 2022 14:28:57 +0200 Subject: [PATCH 035/146] Revert package version update --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index b0f4e51d..c5724bca 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.1.0", + "version": "3.0.1", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", From b14149611a2e33a7f5e8b7aec858e95f47154cef Mon Sep 17 00:00:00 2001 From: Thibault Dalban Date: Wed, 2 Feb 2022 16:27:54 +0100 Subject: [PATCH 036/146] Convert id properties from snake_case to camelCase --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index dd6f86ac..fc7f8f6d 100644 --- a/README.md +++ b/README.md @@ -128,7 +128,7 @@ const article = await client.articles.create({ title: 'Allez les verts', description: 'French description', body: '

French body in html

', - author_id: 1, + authorId: 1, state: 'published', }, }, @@ -158,7 +158,7 @@ const article = await client.articles.update({ title: 'Allez les verts', description: 'French description', body: '

French body in html

', - author_id: 1, + authorId: 1, state: 'published', }, }, @@ -878,7 +878,7 @@ const response = client.helpCenter.collections.list({ ```typescript const collection = await client.helpCenter.sections.create({ name: 'Thanks for everything', - parent_id: '1234', + parentId: '1234', translatedContent: { fr: { name: 'Allez les verts', @@ -900,7 +900,7 @@ const response = await client.helpCenter.sections.find({ id: '123' }); const article = await client.helpCenter.sections.update({ id: '123', name: 'Thanks for everything', - parent_id: '456', + parentId: '456', translated_content: { fr: { name: 'Allez les verts', From 1e6039f80d231c9da5b80d8da61b7e4963dc367a Mon Sep 17 00:00:00 2001 From: Thibault Dalban Date: Wed, 2 Feb 2022 16:46:07 +0100 Subject: [PATCH 037/146] Convert translated_content to be camelCase --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index fc7f8f6d..70928a8c 100644 --- a/README.md +++ b/README.md @@ -845,7 +845,7 @@ const article = await client.helpCenter.collections.update({ id: '123', name: 'Thanks for everything', description: 'English description', - translated_content: { + translatedContent: { fr: { name: 'Allez les verts', description: 'French description', @@ -901,7 +901,7 @@ const article = await client.helpCenter.sections.update({ id: '123', name: 'Thanks for everything', parentId: '456', - translated_content: { + translatedContent: { fr: { name: 'Allez les verts', description: 'French description', From caa4cf5a30cfb1656b5ded1f748499ecd0a68a60 Mon Sep 17 00:00:00 2001 From: Volo Date: Wed, 2 Feb 2022 19:19:08 +0200 Subject: [PATCH 038/146] Add Visitor --- README.md | 48 ++++++++++++++++++++ lib/client.ts | 3 ++ lib/index.ts | 7 +++ lib/visitor.ts | 87 ++++++++++++++++++++++++++++++++++++ lib/visitor/visitor.types.ts | 18 ++++++++ test/visitor.ts | 85 +++++++++++++++++++++++++++++++++++ 6 files changed, 248 insertions(+) create mode 100644 lib/visitor.ts create mode 100644 lib/visitor/visitor.types.ts create mode 100644 test/visitor.ts diff --git a/README.md b/README.md index dd6f86ac..04809736 100644 --- a/README.md +++ b/README.md @@ -1067,6 +1067,54 @@ const response = await client.teams.find({ const response = await client.teams.list(); ``` +### Visitors + +#### [Retrieve a Visitor](https://developers.intercom.com/intercom-api-reference/reference/view-a-visitor) + +```typescript +const response = await client.visitors.find({ id: '123' }); +``` + +OR + +```typescript +const response = await client.visitors.find({ userId: '123' }); +``` + +#### [Update a Visitor](https://developers.intercom.com/intercom-api-reference/reference/update-a-visitor) + +```typescript +const response = await client.visitors.update({ + userId: '123', + name: 'anonymous bruh', + customAttributes: { + paid_subscriber: true, + }, +}); +``` + +#### [Delete a Visitor](https://developers.intercom.com/intercom-api-reference/reference/delete-a-visitor) + +```typescript +const response = await client.visitors.delete({ + id, +}); +``` + +#### [Convert a Visitor](https://developers.intercom.com/intercom-api-reference/reference/convert-a-visitor-to-a-user) + +```typescript +const response = await client.visitors.mergeToContact({ + visitor: { + id: '123', + }, + user: { + userId: '123', + }, + type: Role.USER, +}); +``` + ### Identity verification `intercom-node` provides a helper for using [identity verification](https://docs.intercom.com/configure-intercom-for-your-product-or-site/staying-secure/enable-identity-verification-on-your-web-product): diff --git a/lib/client.ts b/lib/client.ts index f0b093c3..b5a5feed 100644 --- a/lib/client.ts +++ b/lib/client.ts @@ -14,6 +14,7 @@ import Segment from './segment'; import Message from './message'; import Team from './team'; import Tag from './tag'; +import Visitor from './visitor'; import * as packageJson from '../package.json'; @@ -66,6 +67,7 @@ export default class Client { teams: Team; usebaseURL: (baseURL: string) => this; usernamePart?: string; + visitors: Visitor; constructor(args: Constructor) { const [usernamePart, passwordPart] = Client.getAuthDetails(args); @@ -91,6 +93,7 @@ export default class Client { this.segments = new Segment(this); this.tags = new Tag(this); this.teams = new Team(this); + this.visitors = new Visitor(this); this.requestOpts = { baseURL: 'https://api.intercom.io', }; diff --git a/lib/index.ts b/lib/index.ts index 40c8d1be..5bf626c4 100644 --- a/lib/index.ts +++ b/lib/index.ts @@ -38,6 +38,7 @@ export * from './segment/segment.types'; export * from './subscription/subscription.types'; export * from './tag/tag.types'; export * from './team/team.types'; +export * from './visitor/visitor.types'; // Export enums needed for requests export { SearchContactOrderBy } from './contact'; @@ -55,3 +56,9 @@ export { RedactConversationPartType, } from './conversation'; export { RecepientType } from './message'; +export { + ContactObjectForMerge, + MergeVisitorToContactData, + VisitorObjectForMerge, + IdentificationForVisitor, +} from './visitor'; diff --git a/lib/visitor.ts b/lib/visitor.ts new file mode 100644 index 00000000..fe6eb3f4 --- /dev/null +++ b/lib/visitor.ts @@ -0,0 +1,87 @@ +import { Client, ContactObject } from '.'; +import { Role } from './common/common.types'; +import { VisitorObject } from './visitor/visitor.types'; + +export default class Visitor { + public readonly baseUrl = 'visitors'; + + constructor(private readonly client: Client) { + this.client = client; + } + + find({ id, userId }: FindVisitorByIdData) { + const query = userId ? { user_id: userId } : {}; + const url = `/${this.baseUrl}${id ? `/${id}` : ''}`; + + return this.client.get({ + url, + params: query, + }); + } + update({ id, userId, name, customAttributes }: UpdateVisitorData) { + const data = { + id, + user_id: userId, + name, + custom_attributes: customAttributes, + }; + + return this.client.put({ + url: `/${this.baseUrl}`, + data, + }); + } + delete({ id }: DeleteVisitorByIdData) { + return this.client.delete({ + url: `/${this.baseUrl}/${id}`, + }); + } + mergeToContact({ visitor, user, type }: MergeVisitorToContactData) { + const data = { + visitor: { + id: visitor.id, + user_id: visitor.userId, + email: visitor.email, + }, + user: { + id: user.id, + user_id: user.userId, + email: user.email, + }, + type, + }; + + return this.client.post({ + url: `/${this.baseUrl}/convert`, + data, + }); + } +} + +export type IdentificationForVisitor = + | { id: string; userId?: never } + | { id?: never; userId: string }; + +type FindVisitorByIdData = IdentificationForVisitor; + +type UpdateVisitorData = IdentificationForVisitor & { + name?: string; + customAttributes?: VisitorObject['custom_attributes']; +}; + +type DeleteVisitorByIdData = { id: string }; + +export type MergeVisitorToContactData = { + visitor: VisitorObjectForMerge; + user: ContactObjectForMerge; + type: Role; +}; + +export type VisitorObjectForMerge = + | { id: string; userId?: never; email?: never } + | { id?: never; userId: string; email?: never } + | { id?: never; userId?: never; email: string }; + +export type ContactObjectForMerge = IdentificationForVisitor & { + email?: string; +}; diff --git a/lib/visitor/visitor.types.ts b/lib/visitor/visitor.types.ts new file mode 100644 index 00000000..e9f92b53 --- /dev/null +++ b/lib/visitor/visitor.types.ts @@ -0,0 +1,18 @@ +import { JavascriptObject, SegmentObject, TagObject, Timestamp } from '..'; + +export type VisitorObject = { + type: 'visitor'; + id: string; + created_at: Timestamp; + updated_at: Timestamp; + user_id: string; + name: string; + custom_attributes: JavascriptObject; + last_request_at: Timestamp; + avatar: string | { url: string }; + unsubscribed_from_emails: boolean; + location_data: JavascriptObject; + social_profiles: JavascriptObject[]; + segments: SegmentObject[]; + tags: TagObject[]; +}; diff --git a/test/visitor.ts b/test/visitor.ts new file mode 100644 index 00000000..abf11e63 --- /dev/null +++ b/test/visitor.ts @@ -0,0 +1,85 @@ +import assert from 'assert'; +import { Client, Role } from '../lib'; +import nock from 'nock'; + +describe('visitors', () => { + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + it('retrieves a visitor by id', async () => { + const id = 'baz'; + + nock('https://api.intercom.io').get(`/visitors/${id}`).reply(200, {}); + + const response = await client.visitors.find({ id }); + + assert.deepStrictEqual({}, response); + }); + it('retrieves a visitor by user id', async () => { + const userId = 'baz'; + + nock('https://api.intercom.io') + .get('/visitors') + .query({ user_id: userId }) + .reply(200, {}); + + const response = await client.visitors.find({ userId }); + + assert.deepStrictEqual({}, response); + }); + it('updates a visitor by id', async () => { + const requestData = { + user_id: '124', + name: 'Winston Smith', + custom_attributes: { + paid_subscriber: true, + monthly_spend: 155.5, + team_mates: 9, + }, + }; + nock('https://api.intercom.io').put('/visitors').reply(200, {}); + const response = await client.visitors.update({ + userId: requestData.user_id, + name: requestData.name, + customAttributes: requestData.custom_attributes, + }); + + assert.deepStrictEqual({}, response); + }); + it('deletes a visitor', async () => { + const id = 'baz'; + + nock('https://api.intercom.io') + .delete(`/visitors/${id}`) + .reply(200, {}); + + const response = await client.visitors.delete({ + id, + }); + + assert.deepStrictEqual({}, response); + }); + it('converts a visitor into contact', async () => { + const requestData = { + visitor: { id: 'baz' }, + user: { user_id: 'bez' }, + type: Role.USER, + }; + + nock('https://api.intercom.io') + .post('/visitors/convert', requestData) + .reply(200, {}); + + const response = await client.visitors.mergeToContact({ + visitor: { + id: requestData.visitor.id, + }, + user: { + userId: requestData.user.user_id, + }, + type: requestData.type, + }); + + assert.deepStrictEqual({}, response); + }); +}); From 5c9a7406ec745e59f1b83ae96e3512414ea3c9d0 Mon Sep 17 00:00:00 2001 From: Volodymyr V <14982064+hypeofpipe@users.noreply.github.com> Date: Fri, 4 Feb 2022 11:48:14 +0100 Subject: [PATCH 039/146] Revert "Add Visitors" --- README.md | 48 -------------------- lib/client.ts | 3 -- lib/index.ts | 7 --- lib/visitor.ts | 87 ------------------------------------ lib/visitor/visitor.types.ts | 18 -------- test/visitor.ts | 85 ----------------------------------- 6 files changed, 248 deletions(-) delete mode 100644 lib/visitor.ts delete mode 100644 lib/visitor/visitor.types.ts delete mode 100644 test/visitor.ts diff --git a/README.md b/README.md index 04809736..dd6f86ac 100644 --- a/README.md +++ b/README.md @@ -1067,54 +1067,6 @@ const response = await client.teams.find({ const response = await client.teams.list(); ``` -### Visitors - -#### [Retrieve a Visitor](https://developers.intercom.com/intercom-api-reference/reference/view-a-visitor) - -```typescript -const response = await client.visitors.find({ id: '123' }); -``` - -OR - -```typescript -const response = await client.visitors.find({ userId: '123' }); -``` - -#### [Update a Visitor](https://developers.intercom.com/intercom-api-reference/reference/update-a-visitor) - -```typescript -const response = await client.visitors.update({ - userId: '123', - name: 'anonymous bruh', - customAttributes: { - paid_subscriber: true, - }, -}); -``` - -#### [Delete a Visitor](https://developers.intercom.com/intercom-api-reference/reference/delete-a-visitor) - -```typescript -const response = await client.visitors.delete({ - id, -}); -``` - -#### [Convert a Visitor](https://developers.intercom.com/intercom-api-reference/reference/convert-a-visitor-to-a-user) - -```typescript -const response = await client.visitors.mergeToContact({ - visitor: { - id: '123', - }, - user: { - userId: '123', - }, - type: Role.USER, -}); -``` - ### Identity verification `intercom-node` provides a helper for using [identity verification](https://docs.intercom.com/configure-intercom-for-your-product-or-site/staying-secure/enable-identity-verification-on-your-web-product): diff --git a/lib/client.ts b/lib/client.ts index b5a5feed..f0b093c3 100644 --- a/lib/client.ts +++ b/lib/client.ts @@ -14,7 +14,6 @@ import Segment from './segment'; import Message from './message'; import Team from './team'; import Tag from './tag'; -import Visitor from './visitor'; import * as packageJson from '../package.json'; @@ -67,7 +66,6 @@ export default class Client { teams: Team; usebaseURL: (baseURL: string) => this; usernamePart?: string; - visitors: Visitor; constructor(args: Constructor) { const [usernamePart, passwordPart] = Client.getAuthDetails(args); @@ -93,7 +91,6 @@ export default class Client { this.segments = new Segment(this); this.tags = new Tag(this); this.teams = new Team(this); - this.visitors = new Visitor(this); this.requestOpts = { baseURL: 'https://api.intercom.io', }; diff --git a/lib/index.ts b/lib/index.ts index 5bf626c4..40c8d1be 100644 --- a/lib/index.ts +++ b/lib/index.ts @@ -38,7 +38,6 @@ export * from './segment/segment.types'; export * from './subscription/subscription.types'; export * from './tag/tag.types'; export * from './team/team.types'; -export * from './visitor/visitor.types'; // Export enums needed for requests export { SearchContactOrderBy } from './contact'; @@ -56,9 +55,3 @@ export { RedactConversationPartType, } from './conversation'; export { RecepientType } from './message'; -export { - ContactObjectForMerge, - MergeVisitorToContactData, - VisitorObjectForMerge, - IdentificationForVisitor, -} from './visitor'; diff --git a/lib/visitor.ts b/lib/visitor.ts deleted file mode 100644 index fe6eb3f4..00000000 --- a/lib/visitor.ts +++ /dev/null @@ -1,87 +0,0 @@ -import { Client, ContactObject } from '.'; -import { Role } from './common/common.types'; -import { VisitorObject } from './visitor/visitor.types'; - -export default class Visitor { - public readonly baseUrl = 'visitors'; - - constructor(private readonly client: Client) { - this.client = client; - } - - find({ id, userId }: FindVisitorByIdData) { - const query = userId ? { user_id: userId } : {}; - const url = `/${this.baseUrl}${id ? `/${id}` : ''}`; - - return this.client.get({ - url, - params: query, - }); - } - update({ id, userId, name, customAttributes }: UpdateVisitorData) { - const data = { - id, - user_id: userId, - name, - custom_attributes: customAttributes, - }; - - return this.client.put({ - url: `/${this.baseUrl}`, - data, - }); - } - delete({ id }: DeleteVisitorByIdData) { - return this.client.delete({ - url: `/${this.baseUrl}/${id}`, - }); - } - mergeToContact({ visitor, user, type }: MergeVisitorToContactData) { - const data = { - visitor: { - id: visitor.id, - user_id: visitor.userId, - email: visitor.email, - }, - user: { - id: user.id, - user_id: user.userId, - email: user.email, - }, - type, - }; - - return this.client.post({ - url: `/${this.baseUrl}/convert`, - data, - }); - } -} - -export type IdentificationForVisitor = - | { id: string; userId?: never } - | { id?: never; userId: string }; - -type FindVisitorByIdData = IdentificationForVisitor; - -type UpdateVisitorData = IdentificationForVisitor & { - name?: string; - customAttributes?: VisitorObject['custom_attributes']; -}; - -type DeleteVisitorByIdData = { id: string }; - -export type MergeVisitorToContactData = { - visitor: VisitorObjectForMerge; - user: ContactObjectForMerge; - type: Role; -}; - -export type VisitorObjectForMerge = - | { id: string; userId?: never; email?: never } - | { id?: never; userId: string; email?: never } - | { id?: never; userId?: never; email: string }; - -export type ContactObjectForMerge = IdentificationForVisitor & { - email?: string; -}; diff --git a/lib/visitor/visitor.types.ts b/lib/visitor/visitor.types.ts deleted file mode 100644 index e9f92b53..00000000 --- a/lib/visitor/visitor.types.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { JavascriptObject, SegmentObject, TagObject, Timestamp } from '..'; - -export type VisitorObject = { - type: 'visitor'; - id: string; - created_at: Timestamp; - updated_at: Timestamp; - user_id: string; - name: string; - custom_attributes: JavascriptObject; - last_request_at: Timestamp; - avatar: string | { url: string }; - unsubscribed_from_emails: boolean; - location_data: JavascriptObject; - social_profiles: JavascriptObject[]; - segments: SegmentObject[]; - tags: TagObject[]; -}; diff --git a/test/visitor.ts b/test/visitor.ts deleted file mode 100644 index abf11e63..00000000 --- a/test/visitor.ts +++ /dev/null @@ -1,85 +0,0 @@ -import assert from 'assert'; -import { Client, Role } from '../lib'; -import nock from 'nock'; - -describe('visitors', () => { - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - it('retrieves a visitor by id', async () => { - const id = 'baz'; - - nock('https://api.intercom.io').get(`/visitors/${id}`).reply(200, {}); - - const response = await client.visitors.find({ id }); - - assert.deepStrictEqual({}, response); - }); - it('retrieves a visitor by user id', async () => { - const userId = 'baz'; - - nock('https://api.intercom.io') - .get('/visitors') - .query({ user_id: userId }) - .reply(200, {}); - - const response = await client.visitors.find({ userId }); - - assert.deepStrictEqual({}, response); - }); - it('updates a visitor by id', async () => { - const requestData = { - user_id: '124', - name: 'Winston Smith', - custom_attributes: { - paid_subscriber: true, - monthly_spend: 155.5, - team_mates: 9, - }, - }; - nock('https://api.intercom.io').put('/visitors').reply(200, {}); - const response = await client.visitors.update({ - userId: requestData.user_id, - name: requestData.name, - customAttributes: requestData.custom_attributes, - }); - - assert.deepStrictEqual({}, response); - }); - it('deletes a visitor', async () => { - const id = 'baz'; - - nock('https://api.intercom.io') - .delete(`/visitors/${id}`) - .reply(200, {}); - - const response = await client.visitors.delete({ - id, - }); - - assert.deepStrictEqual({}, response); - }); - it('converts a visitor into contact', async () => { - const requestData = { - visitor: { id: 'baz' }, - user: { user_id: 'bez' }, - type: Role.USER, - }; - - nock('https://api.intercom.io') - .post('/visitors/convert', requestData) - .reply(200, {}); - - const response = await client.visitors.mergeToContact({ - visitor: { - id: requestData.visitor.id, - }, - user: { - userId: requestData.user.user_id, - }, - type: requestData.type, - }); - - assert.deepStrictEqual({}, response); - }); -}); From df8a5e41e9579947137e63f3d10e152d4287e017 Mon Sep 17 00:00:00 2001 From: Volo Date: Mon, 7 Feb 2022 19:29:52 +0200 Subject: [PATCH 040/146] Add Count --- README.md | 56 +++++++++++++++++++++++++ lib/client.ts | 5 ++- lib/count.ts | 86 ++++++++++++++++++++++++++++++++++++++ lib/count/count.types.ts | 90 ++++++++++++++++++++++++++++++++++++++++ lib/index.ts | 1 + test/counts.ts | 85 +++++++++++++++++++++++++++++++++++++ 6 files changed, 322 insertions(+), 1 deletion(-) create mode 100644 lib/count.ts create mode 100644 lib/count/count.types.ts create mode 100644 test/counts.ts diff --git a/README.md b/README.md index dd6f86ac..b87becef 100644 --- a/README.md +++ b/README.md @@ -746,6 +746,62 @@ const response = await client.conversations.redactConversationPart({ }); ``` +### Counts + +#### [App Total Count](https://developers.intercom.com/intercom-api-reference/reference/company-user-counts) + +```typescript +const response = await client.counts.forApp(); +``` + +#### [Conversation Count Model](https://developers.intercom.com/intercom-api-reference/reference/conversation-counts) + +```typescript +const response = await client.counts.countConversation(); +``` + +#### [Admin Conversation Count Model](https://developers.intercom.com/intercom-api-reference/reference/admin-conversations) + +```typescript +const response = await client.counts.countAdminConversation(); +``` + +#### [User Segment/Tag Count Model](https://developers.intercom.com/intercom-api-reference/reference/user-tag-counts) + +##### Count User Segment + +```typescript +const response = await client.counts.countUserSegment(); +``` + +##### Count User Tag + +```typescript +const response = await client.counts.countUserTag(); +``` + +#### [Company User/Segment/Tag Count Model](https://developers.intercom.com/intercom-api-reference/reference/company-tag-counts) + +##### Count Company Segment + +```typescript +const response = await client.counts.countCompanySegment(); +const response = await client.counts.countCompanyTag(); +const response = await client.counts.countCompanyUser(); +``` + +##### Count Company Tag + +```typescript +const response = await client.counts.countCompanyTag(); +``` + +##### Count Company User + +```typescript +const response = await client.counts.countCompanyUser(); +``` + ### Data Attributes #### [Create Data Attribute](https://developers.intercom.com/intercom-api-reference/reference/create-data-attributes) diff --git a/lib/client.ts b/lib/client.ts index f0b093c3..479970fd 100644 --- a/lib/client.ts +++ b/lib/client.ts @@ -5,8 +5,9 @@ import { merge, omit } from 'lodash'; import Article from './article'; import Admin from './admin'; import Company from './company'; -import Conversation from './conversation'; import Contact from './contact'; +import Conversation from './conversation'; +import Count from './count'; import DataAttribute from './dataAttribute'; import Event from './event'; import HelpCenter from './helpCenter'; @@ -54,6 +55,7 @@ export default class Client { companies: Company; contacts: Contact; conversations: Conversation; + counts: Count; dataAttributes: DataAttribute; events: Event; helpCenter: HelpCenter; @@ -84,6 +86,7 @@ export default class Client { this.companies = new Company(this); this.contacts = new Contact(this); this.conversations = new Conversation(this); + this.counts = new Count(this); this.dataAttributes = new DataAttribute(this); this.events = new Event(this); this.helpCenter = new HelpCenter(this); diff --git a/lib/count.ts b/lib/count.ts new file mode 100644 index 00000000..8220204d --- /dev/null +++ b/lib/count.ts @@ -0,0 +1,86 @@ +import { + Client, + CompanySegmentCountResponse, + CompanyTagCountResponse, + CompanyUserCountResponse, + UserCountResponse, + UserSegmentCountResponse, + UserTagCountResponse, +} from '.'; +import { + AdminConversationCountResponse, + AppTotalCountResponse, + CompanyCountResponse, + ConversationCountResponse, + CountEntity, + CountType, +} from './count/count.types'; + +export default class Count { + public readonly baseUrl = 'counts'; + + constructor(private readonly client: Client) { + this.client = client; + } + + forApp() { + return this.client.get({ + url: `/${this.baseUrl}`, + }); + } + + countCompany() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.COMPANY }, + }); + } + countCompanySegment() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.COMPANY, count: CountEntity.SEGMENT }, + }); + } + countCompanyTag() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.COMPANY, count: CountEntity.TAG }, + }); + } + countCompanyUser() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.COMPANY, count: CountEntity.USER }, + }); + } + countConversation() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.CONVERSATION }, + }); + } + countAdminConversation() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.CONVERSATION, count: CountEntity.ADMIN }, + }); + } + countUser() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.USER }, + }); + } + countUserSegment() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.USER, count: CountEntity.SEGMENT }, + }); + } + countUserTag() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.USER, count: CountEntity.TAG }, + }); + } +} diff --git a/lib/count/count.types.ts b/lib/count/count.types.ts new file mode 100644 index 00000000..ac2cd0fe --- /dev/null +++ b/lib/count/count.types.ts @@ -0,0 +1,90 @@ +export type AppTotalCountResponse = { + type: 'count.hash'; + company: CountObject; + user: CountObject; + lead: CountObject; + tag: CountObject; + segment: CountObject; +}; + +export type ConversationCountResponse = { + type: 'count'; + conversation: { + assigned: number; + closed: number; + open: number; + unassigned: number; + }; +}; + +export type AdminConversationCountResponse = { + type: 'count'; + conversation: { + admin: { + id: string; + name: string; + open: number; + closed: number; + }[]; + }; +}; + +export type CompanyCountResponse = { + type: 'count'; + company: CountObject; +}; + +export type CompanySegmentCountResponse = { + type: 'count'; + company: { segment: GenericCountObject[] }; +}; + +export type CompanyTagCountResponse = { + type: 'count'; + company: { tag: GenericCountObject[] }; +}; + +export type CompanyUserCountResponse = { + type: 'count'; + company: { + user: GenericCountObject & { remote_company_id: string }[]; + }; +}; + +export type UserCountResponse = { + type: 'count'; + user: { + user: CountObject; + }; +}; + +export type UserSegmentCountResponse = { + type: 'count'; + company: { segment: GenericCountObject[] }; +}; + +export type UserTagCountResponse = { + type: 'count'; + company: { tag: GenericCountObject[] }; +}; + +export type CountObject = { + count: number; +}; + +export enum CountType { + CONVERSATION = 'conversation', + USER = 'user', + COMPANY = 'company', +} + +export enum CountEntity { + ADMIN = 'admin', + SEGMENT = 'segment', + TAG = 'tag', + USER = 'user', +} + +type GenericCountObject = { + [title: string]: number; +}; diff --git a/lib/index.ts b/lib/index.ts index 40c8d1be..41225900 100644 --- a/lib/index.ts +++ b/lib/index.ts @@ -30,6 +30,7 @@ export * from './common/common.types'; export * from './company/company.types'; export * from './contact/contact.types'; export * from './conversation/conversation.types'; +export * from './count/count.types'; export * from './dataAttribute/dataAttribute.types'; export * from './event/event.types'; export * from './helpCenter/helpCenter.types'; diff --git a/test/counts.ts b/test/counts.ts new file mode 100644 index 00000000..858f9f17 --- /dev/null +++ b/test/counts.ts @@ -0,0 +1,85 @@ +import assert from 'assert'; +import { Client, CountEntity, CountType } from '../lib'; +import nock from 'nock'; + +describe.only('counts', () => { + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + it('gets total app count', async () => { + nock('https://api.intercom.io').get('/counts').reply(200, {}); + const response = await client.counts.forApp(); + + assert.deepStrictEqual({}, response); + }); + it('gets conversations count', async () => { + nock('https://api.intercom.io') + .get('/counts') + .query({ type: CountType.CONVERSATION }) + .reply(200, {}); + const response = await client.counts.countConversation(); + + assert.deepStrictEqual({}, response); + }); + it('gets admin conversations count', async () => { + nock('https://api.intercom.io') + .get('/counts') + .query({ type: CountType.CONVERSATION, count: CountEntity.ADMIN }) + .reply(200, {}); + const response = await client.counts.countAdminConversation(); + + assert.deepStrictEqual({}, response); + }); + describe('for user', () => { + it('gets segment count', async () => { + nock('https://api.intercom.io') + .get('/counts') + .query({ type: CountType.USER, count: CountEntity.SEGMENT }) + .reply(200, {}); + const response = await client.counts.countUserSegment(); + + assert.deepStrictEqual({}, response); + }); + + it('gets tags count', async () => { + nock('https://api.intercom.io') + .get('/counts') + .query({ type: CountType.USER, count: CountEntity.TAG }) + .reply(200, {}); + const response = await client.counts.countUserTag(); + + assert.deepStrictEqual({}, response); + }); + }); + describe('for company', () => { + it('gets segment count', async () => { + nock('https://api.intercom.io') + .get('/counts') + .query({ type: CountType.COMPANY, count: CountEntity.SEGMENT }) + .reply(200, {}); + const response = await client.counts.countCompanySegment(); + + assert.deepStrictEqual({}, response); + }); + + it('gets tags count', async () => { + nock('https://api.intercom.io') + .get('/counts') + .query({ type: CountType.COMPANY, count: CountEntity.TAG }) + .reply(200, {}); + const response = await client.counts.countCompanyTag(); + + assert.deepStrictEqual({}, response); + }); + + it('gets users count', async () => { + nock('https://api.intercom.io') + .get('/counts') + .query({ type: CountType.COMPANY, count: CountEntity.USER }) + .reply(200, {}); + const response = await client.counts.countCompanyUser(); + + assert.deepStrictEqual({}, response); + }); + }); +}); From 2da3daf40311ce9107ba405c2746736cc1872993 Mon Sep 17 00:00:00 2001 From: Volo Date: Mon, 7 Feb 2022 19:47:19 +0200 Subject: [PATCH 041/146] Bump minor package.json version --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index c5724bca..b0f4e51d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.0.1", + "version": "3.1.0", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", From 2f2a02f2d3b87c106bbba4b7194c41b1d7042614 Mon Sep 17 00:00:00 2001 From: Volo Date: Tue, 1 Feb 2022 14:28:28 +0200 Subject: [PATCH 042/146] Add Notes --- README.md | 28 ++++++++++++++++++++ lib/admin/admin.types.ts | 2 +- lib/article.ts | 10 +++---- lib/client.ts | 5 +++- lib/common/common.types.ts | 4 +++ lib/helpCenter.ts | 10 +++---- lib/index.ts | 1 + lib/note.ts | 54 ++++++++++++++++++++++++++++++++++++++ lib/note/note.types.ts | 22 ++++++++++++++++ package.json | 2 +- test/notes.ts | 51 +++++++++++++++++++++++++++++++++++ 11 files changed, 176 insertions(+), 13 deletions(-) create mode 100644 lib/note.ts create mode 100644 lib/note/note.types.ts create mode 100644 test/notes.ts diff --git a/README.md b/README.md index 04809736..0523c37e 100644 --- a/README.md +++ b/README.md @@ -948,6 +948,34 @@ const response = await client.messages.create({ }); ``` +### Notes + +#### [Create a note](https://developers.intercom.com/intercom-api-reference/reference/create-note-for-contact) + +```typescript +const response = await client.notes.create({ + adminId: '12345', + body: 'Shiny', + contactId: '5678', +}); +``` + +#### [Retrieve a note](https://developers.intercom.com/intercom-api-reference/reference/view-a-note) + +```typescript +const response = await client.notes.find({ id: '123' }); +``` + +#### [List all notes](https://developers.intercom.com/intercom-api-reference/reference/list-notes-of-contact) + +```typescript +const response = await client.notes.list({ + contactId: '123', + page: 2, + perPage: 3, +}); +``` + ### Segments #### [Retrieve a segment](https://developers.intercom.com/intercom-api-reference/reference/view-a-segment) diff --git a/lib/admin/admin.types.ts b/lib/admin/admin.types.ts index b319cfdf..421a69a7 100644 --- a/lib/admin/admin.types.ts +++ b/lib/admin/admin.types.ts @@ -8,5 +8,5 @@ export interface AdminObject { away_mode_reassign: boolean; has_inbox_seat: boolean; team_ids: Array; - avatar: string; + avatar: string | { image_url: string }; } diff --git a/lib/article.ts b/lib/article.ts index cefa6a1f..82436abd 100644 --- a/lib/article.ts +++ b/lib/article.ts @@ -3,7 +3,11 @@ import { ArticleObject, TranslatedContentObject, } from './article/article.types'; -import { GenericDeletedResponse, Paginated } from './common/common.types'; +import { + GenericDeletedResponse, + OperationById, + Paginated, +} from './common/common.types'; export default class Article { public readonly baseUrl = 'articles'; @@ -99,10 +103,6 @@ interface CreateArticleData { translatedContent?: Omit; } -interface OperationById { - id: string; -} - type ArticleFindByIdData = OperationById; type UpdateArticleData = Partial & OperationById; diff --git a/lib/client.ts b/lib/client.ts index b5a5feed..07d80489 100644 --- a/lib/client.ts +++ b/lib/client.ts @@ -10,8 +10,9 @@ import Contact from './contact'; import DataAttribute from './dataAttribute'; import Event from './event'; import HelpCenter from './helpCenter'; -import Segment from './segment'; import Message from './message'; +import Note from './note'; +import Segment from './segment'; import Team from './team'; import Tag from './tag'; import Visitor from './visitor'; @@ -59,6 +60,7 @@ export default class Client { events: Event; helpCenter: HelpCenter; messages: Message; + notes: Note; segments: Segment; passwordPart?: string; propertiesToOmitInRequestOpts: string[]; @@ -90,6 +92,7 @@ export default class Client { this.events = new Event(this); this.helpCenter = new HelpCenter(this); this.messages = new Message(this); + this.notes = new Note(this); this.segments = new Segment(this); this.tags = new Tag(this); this.teams = new Team(this); diff --git a/lib/common/common.types.ts b/lib/common/common.types.ts index 70eddec3..d35b2f6f 100644 --- a/lib/common/common.types.ts +++ b/lib/common/common.types.ts @@ -69,3 +69,7 @@ export interface GenericDeletedResponse { object: ObjectType; deleted: boolean; } + +export interface OperationById { + id: string; +} diff --git a/lib/helpCenter.ts b/lib/helpCenter.ts index de59e22c..b15351e5 100644 --- a/lib/helpCenter.ts +++ b/lib/helpCenter.ts @@ -1,5 +1,9 @@ import { Client } from '.'; -import { GenericDeletedResponse, Paginated } from './common/common.types'; +import { + GenericDeletedResponse, + OperationById, + Paginated, +} from './common/common.types'; import { CollectionObject, GroupTranslatedContentObject, @@ -165,7 +169,3 @@ type SectionListData = { }; type SectionListResponse = Paginated; - -interface OperationById { - id: string; -} diff --git a/lib/index.ts b/lib/index.ts index 5bf626c4..5824532a 100644 --- a/lib/index.ts +++ b/lib/index.ts @@ -34,6 +34,7 @@ export * from './dataAttribute/dataAttribute.types'; export * from './event/event.types'; export * from './helpCenter/helpCenter.types'; export * from './message/message.types'; +export * from './note/note.types'; export * from './segment/segment.types'; export * from './subscription/subscription.types'; export * from './tag/tag.types'; diff --git a/lib/note.ts b/lib/note.ts new file mode 100644 index 00000000..a8dae2f9 --- /dev/null +++ b/lib/note.ts @@ -0,0 +1,54 @@ +import { Client, NoteObject } from '.'; +import { OperationById, Paginated } from './common/common.types'; + +export default class Note { + public readonly baseUrl = 'notes'; + + constructor(private readonly client: Client) { + this.client = client; + } + + create({ adminId, body, contactId }: CreateNoteData) { + const data = { + admin_id: adminId, + body, + }; + + return this.client.post({ + url: `/${this.client.contacts.baseUrl}/${contactId}/${this.baseUrl}`, + data, + }); + } + find({ id }: FindNoteByIdData) { + return this.client.get({ + url: `/${this.baseUrl}/${id}`, + }); + } + list({ contactId, page, perPage: per_page }: ListNotesData) { + const params = { + page, + per_page, + }; + + return this.client.get({ + url: `/${this.client.contacts.baseUrl}/${contactId}/${this.baseUrl}`, + params, + }); + } +} + +interface CreateNoteData { + adminId: string; + body: string; + contactId: string; +} + +type FindNoteByIdData = OperationById; + +type ListNotesData = { + contactId: string; + page?: number; + perPage?: number; +}; + +type ListNotesResponse = Paginated; diff --git a/lib/note/note.types.ts b/lib/note/note.types.ts new file mode 100644 index 00000000..818c627c --- /dev/null +++ b/lib/note/note.types.ts @@ -0,0 +1,22 @@ +import { AdminObject, Timestamp } from '..'; + +export type NoteObject = { + type: 'note'; + id: string; + created_at: Timestamp; + contact: { + type: 'contact'; + id: string; + }; + author?: Pick< + AdminObject, + | 'type' + | 'id' + | 'name' + | 'email' + | 'away_mode_enabled' + | 'away_mode_reassign' + | 'avatar' + >; + body: string; +}; diff --git a/package.json b/package.json index c5724bca..b0f4e51d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.0.1", + "version": "3.1.0", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", diff --git a/test/notes.ts b/test/notes.ts new file mode 100644 index 00000000..2ce9d602 --- /dev/null +++ b/test/notes.ts @@ -0,0 +1,51 @@ +import assert from 'assert'; +import { Client } from '../lib'; +import nock from 'nock'; + +describe('notes', () => { + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + it('creates new', async () => { + const contactId = 'baz'; + const requestBody = { + body: 'Shiny', + admin_id: '12345', + }; + + nock('https://api.intercom.io') + .post(`/contacts/${contactId}/notes`, requestBody) + .reply(200, {}); + const response = await client.notes.create({ + adminId: requestBody.admin_id, + body: requestBody.body, + contactId, + }); + + assert.deepStrictEqual({}, response); + }); + it('finds by id', async () => { + const id = 'beb'; + + nock('https://api.intercom.io').get(`/notes/${id}`).reply(200, {}); + const response = await client.notes.find({ id }); + + assert.deepStrictEqual({}, response); + }); + it('lists all for specific contact by id', async () => { + const contactId = 'yoopi'; + + nock('https://api.intercom.io') + .get(`/contacts/${contactId}/notes`) + .query({ page: 2, per_page: 3 }) + .reply(200, {}); + const response = await client.notes.list({ + contactId, + page: 2, + perPage: 3, + }); + + assert.deepStrictEqual({}, response); + }); +}); From f5bf5ddb4f967177ac33324cf45e2e63d66c9baa Mon Sep 17 00:00:00 2001 From: Volo Date: Tue, 1 Feb 2022 14:28:57 +0200 Subject: [PATCH 043/146] Revert package version update --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index b0f4e51d..c5724bca 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.1.0", + "version": "3.0.1", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", From d4c8a4797a274e4770659c1a57c7af14cac7b2d1 Mon Sep 17 00:00:00 2001 From: Volo Date: Mon, 7 Feb 2022 19:29:52 +0200 Subject: [PATCH 044/146] Add Count --- README.md | 56 +++++++++++++++++++++++++ lib/client.ts | 5 ++- lib/count.ts | 86 ++++++++++++++++++++++++++++++++++++++ lib/count/count.types.ts | 90 ++++++++++++++++++++++++++++++++++++++++ lib/index.ts | 1 + test/counts.ts | 85 +++++++++++++++++++++++++++++++++++++ 6 files changed, 322 insertions(+), 1 deletion(-) create mode 100644 lib/count.ts create mode 100644 lib/count/count.types.ts create mode 100644 test/counts.ts diff --git a/README.md b/README.md index 0523c37e..dde26013 100644 --- a/README.md +++ b/README.md @@ -746,6 +746,62 @@ const response = await client.conversations.redactConversationPart({ }); ``` +### Counts + +#### [App Total Count](https://developers.intercom.com/intercom-api-reference/reference/company-user-counts) + +```typescript +const response = await client.counts.forApp(); +``` + +#### [Conversation Count Model](https://developers.intercom.com/intercom-api-reference/reference/conversation-counts) + +```typescript +const response = await client.counts.countConversation(); +``` + +#### [Admin Conversation Count Model](https://developers.intercom.com/intercom-api-reference/reference/admin-conversations) + +```typescript +const response = await client.counts.countAdminConversation(); +``` + +#### [User Segment/Tag Count Model](https://developers.intercom.com/intercom-api-reference/reference/user-tag-counts) + +##### Count User Segment + +```typescript +const response = await client.counts.countUserSegment(); +``` + +##### Count User Tag + +```typescript +const response = await client.counts.countUserTag(); +``` + +#### [Company User/Segment/Tag Count Model](https://developers.intercom.com/intercom-api-reference/reference/company-tag-counts) + +##### Count Company Segment + +```typescript +const response = await client.counts.countCompanySegment(); +const response = await client.counts.countCompanyTag(); +const response = await client.counts.countCompanyUser(); +``` + +##### Count Company Tag + +```typescript +const response = await client.counts.countCompanyTag(); +``` + +##### Count Company User + +```typescript +const response = await client.counts.countCompanyUser(); +``` + ### Data Attributes #### [Create Data Attribute](https://developers.intercom.com/intercom-api-reference/reference/create-data-attributes) diff --git a/lib/client.ts b/lib/client.ts index 07d80489..3dc7142c 100644 --- a/lib/client.ts +++ b/lib/client.ts @@ -5,8 +5,9 @@ import { merge, omit } from 'lodash'; import Article from './article'; import Admin from './admin'; import Company from './company'; -import Conversation from './conversation'; import Contact from './contact'; +import Conversation from './conversation'; +import Count from './count'; import DataAttribute from './dataAttribute'; import Event from './event'; import HelpCenter from './helpCenter'; @@ -56,6 +57,7 @@ export default class Client { companies: Company; contacts: Contact; conversations: Conversation; + counts: Count; dataAttributes: DataAttribute; events: Event; helpCenter: HelpCenter; @@ -88,6 +90,7 @@ export default class Client { this.companies = new Company(this); this.contacts = new Contact(this); this.conversations = new Conversation(this); + this.counts = new Count(this); this.dataAttributes = new DataAttribute(this); this.events = new Event(this); this.helpCenter = new HelpCenter(this); diff --git a/lib/count.ts b/lib/count.ts new file mode 100644 index 00000000..8220204d --- /dev/null +++ b/lib/count.ts @@ -0,0 +1,86 @@ +import { + Client, + CompanySegmentCountResponse, + CompanyTagCountResponse, + CompanyUserCountResponse, + UserCountResponse, + UserSegmentCountResponse, + UserTagCountResponse, +} from '.'; +import { + AdminConversationCountResponse, + AppTotalCountResponse, + CompanyCountResponse, + ConversationCountResponse, + CountEntity, + CountType, +} from './count/count.types'; + +export default class Count { + public readonly baseUrl = 'counts'; + + constructor(private readonly client: Client) { + this.client = client; + } + + forApp() { + return this.client.get({ + url: `/${this.baseUrl}`, + }); + } + + countCompany() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.COMPANY }, + }); + } + countCompanySegment() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.COMPANY, count: CountEntity.SEGMENT }, + }); + } + countCompanyTag() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.COMPANY, count: CountEntity.TAG }, + }); + } + countCompanyUser() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.COMPANY, count: CountEntity.USER }, + }); + } + countConversation() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.CONVERSATION }, + }); + } + countAdminConversation() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.CONVERSATION, count: CountEntity.ADMIN }, + }); + } + countUser() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.USER }, + }); + } + countUserSegment() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.USER, count: CountEntity.SEGMENT }, + }); + } + countUserTag() { + return this.client.get({ + url: `/${this.baseUrl}`, + params: { type: CountType.USER, count: CountEntity.TAG }, + }); + } +} diff --git a/lib/count/count.types.ts b/lib/count/count.types.ts new file mode 100644 index 00000000..ac2cd0fe --- /dev/null +++ b/lib/count/count.types.ts @@ -0,0 +1,90 @@ +export type AppTotalCountResponse = { + type: 'count.hash'; + company: CountObject; + user: CountObject; + lead: CountObject; + tag: CountObject; + segment: CountObject; +}; + +export type ConversationCountResponse = { + type: 'count'; + conversation: { + assigned: number; + closed: number; + open: number; + unassigned: number; + }; +}; + +export type AdminConversationCountResponse = { + type: 'count'; + conversation: { + admin: { + id: string; + name: string; + open: number; + closed: number; + }[]; + }; +}; + +export type CompanyCountResponse = { + type: 'count'; + company: CountObject; +}; + +export type CompanySegmentCountResponse = { + type: 'count'; + company: { segment: GenericCountObject[] }; +}; + +export type CompanyTagCountResponse = { + type: 'count'; + company: { tag: GenericCountObject[] }; +}; + +export type CompanyUserCountResponse = { + type: 'count'; + company: { + user: GenericCountObject & { remote_company_id: string }[]; + }; +}; + +export type UserCountResponse = { + type: 'count'; + user: { + user: CountObject; + }; +}; + +export type UserSegmentCountResponse = { + type: 'count'; + company: { segment: GenericCountObject[] }; +}; + +export type UserTagCountResponse = { + type: 'count'; + company: { tag: GenericCountObject[] }; +}; + +export type CountObject = { + count: number; +}; + +export enum CountType { + CONVERSATION = 'conversation', + USER = 'user', + COMPANY = 'company', +} + +export enum CountEntity { + ADMIN = 'admin', + SEGMENT = 'segment', + TAG = 'tag', + USER = 'user', +} + +type GenericCountObject = { + [title: string]: number; +}; diff --git a/lib/index.ts b/lib/index.ts index 5824532a..5ee488da 100644 --- a/lib/index.ts +++ b/lib/index.ts @@ -30,6 +30,7 @@ export * from './common/common.types'; export * from './company/company.types'; export * from './contact/contact.types'; export * from './conversation/conversation.types'; +export * from './count/count.types'; export * from './dataAttribute/dataAttribute.types'; export * from './event/event.types'; export * from './helpCenter/helpCenter.types'; diff --git a/test/counts.ts b/test/counts.ts new file mode 100644 index 00000000..858f9f17 --- /dev/null +++ b/test/counts.ts @@ -0,0 +1,85 @@ +import assert from 'assert'; +import { Client, CountEntity, CountType } from '../lib'; +import nock from 'nock'; + +describe.only('counts', () => { + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + it('gets total app count', async () => { + nock('https://api.intercom.io').get('/counts').reply(200, {}); + const response = await client.counts.forApp(); + + assert.deepStrictEqual({}, response); + }); + it('gets conversations count', async () => { + nock('https://api.intercom.io') + .get('/counts') + .query({ type: CountType.CONVERSATION }) + .reply(200, {}); + const response = await client.counts.countConversation(); + + assert.deepStrictEqual({}, response); + }); + it('gets admin conversations count', async () => { + nock('https://api.intercom.io') + .get('/counts') + .query({ type: CountType.CONVERSATION, count: CountEntity.ADMIN }) + .reply(200, {}); + const response = await client.counts.countAdminConversation(); + + assert.deepStrictEqual({}, response); + }); + describe('for user', () => { + it('gets segment count', async () => { + nock('https://api.intercom.io') + .get('/counts') + .query({ type: CountType.USER, count: CountEntity.SEGMENT }) + .reply(200, {}); + const response = await client.counts.countUserSegment(); + + assert.deepStrictEqual({}, response); + }); + + it('gets tags count', async () => { + nock('https://api.intercom.io') + .get('/counts') + .query({ type: CountType.USER, count: CountEntity.TAG }) + .reply(200, {}); + const response = await client.counts.countUserTag(); + + assert.deepStrictEqual({}, response); + }); + }); + describe('for company', () => { + it('gets segment count', async () => { + nock('https://api.intercom.io') + .get('/counts') + .query({ type: CountType.COMPANY, count: CountEntity.SEGMENT }) + .reply(200, {}); + const response = await client.counts.countCompanySegment(); + + assert.deepStrictEqual({}, response); + }); + + it('gets tags count', async () => { + nock('https://api.intercom.io') + .get('/counts') + .query({ type: CountType.COMPANY, count: CountEntity.TAG }) + .reply(200, {}); + const response = await client.counts.countCompanyTag(); + + assert.deepStrictEqual({}, response); + }); + + it('gets users count', async () => { + nock('https://api.intercom.io') + .get('/counts') + .query({ type: CountType.COMPANY, count: CountEntity.USER }) + .reply(200, {}); + const response = await client.counts.countCompanyUser(); + + assert.deepStrictEqual({}, response); + }); + }); +}); From 22c0d93eeec1d84737db49121f60205b4895b95c Mon Sep 17 00:00:00 2001 From: Volo Date: Mon, 7 Feb 2022 19:47:19 +0200 Subject: [PATCH 045/146] Bump minor package.json version --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index c5724bca..b0f4e51d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.0.1", + "version": "3.1.0", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", From 5d581c8df5e27d4b66e0e266b9a76dcddd69938e Mon Sep 17 00:00:00 2001 From: Volo Date: Mon, 7 Feb 2022 20:01:10 +0200 Subject: [PATCH 046/146] Remove .only from counts tests --- test/counts.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/counts.ts b/test/counts.ts index 858f9f17..a40b3017 100644 --- a/test/counts.ts +++ b/test/counts.ts @@ -2,7 +2,7 @@ import assert from 'assert'; import { Client, CountEntity, CountType } from '../lib'; import nock from 'nock'; -describe.only('counts', () => { +describe('counts', () => { const client = new Client({ usernameAuth: { username: 'foo', password: 'bar' }, }); From 8df0f39c754c8fc49277ebffd466bad03cfef24c Mon Sep 17 00:00:00 2001 From: Volodymyr V <14982064+hypeofpipe@users.noreply.github.com> Date: Tue, 8 Feb 2022 17:16:57 +0100 Subject: [PATCH 047/146] Update README.md Camelcase... --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index dde26013..acf1a93e 100644 --- a/README.md +++ b/README.md @@ -901,7 +901,7 @@ const article = await client.helpCenter.collections.update({ id: '123', name: 'Thanks for everything', description: 'English description', - translated_content: { + translatedContent: { fr: { name: 'Allez les verts', description: 'French description', @@ -934,7 +934,7 @@ const response = client.helpCenter.collections.list({ ```typescript const collection = await client.helpCenter.sections.create({ name: 'Thanks for everything', - parent_id: '1234', + parentId: '1234', translatedContent: { fr: { name: 'Allez les verts', @@ -956,8 +956,8 @@ const response = await client.helpCenter.sections.find({ id: '123' }); const article = await client.helpCenter.sections.update({ id: '123', name: 'Thanks for everything', - parent_id: '456', - translated_content: { + parentId: '456', + translatedContent: { fr: { name: 'Allez les verts', description: 'French description', From ce4db3bcb6b3ea5e4e8ce8a76f1cabb1ce7dd244 Mon Sep 17 00:00:00 2001 From: Volo Date: Tue, 8 Feb 2022 20:17:30 +0200 Subject: [PATCH 048/146] Fix invalid types for Search Conversations --- lib/common/common.types.ts | 17 +- lib/conversation.ts | 5 +- yarn.lock | 5520 +++++++++++++----------------------- 3 files changed, 1949 insertions(+), 3593 deletions(-) diff --git a/lib/common/common.types.ts b/lib/common/common.types.ts index d35b2f6f..c4bec953 100644 --- a/lib/common/common.types.ts +++ b/lib/common/common.types.ts @@ -8,9 +8,8 @@ export enum Role { LEAD = 'lead', } -export type Paginated = { +export type PaginatedBase = { type: string; - data: T[]; pages: { type: 'pages'; next?: { @@ -24,6 +23,10 @@ export type Paginated = { total_count: number; }; +export type Paginated = PaginatedBase & { + data: T[]; +}; + export enum Operators { AND = 'AND', OR = 'OR', @@ -42,12 +45,18 @@ export enum Operators { interface FlatQuery { field: string; operator: Operators; - value: string | number | null; + value: string | number | string[] | number[] | null; } interface NestedQueries { operator: Operators; - value: Array | string | number | null; + value: + | Array + | string + | number + | string[] + | number[] + | null; } export interface GenericSearchFilters { diff --git a/lib/conversation.ts b/lib/conversation.ts index dd43fb8f..c800db2c 100644 --- a/lib/conversation.ts +++ b/lib/conversation.ts @@ -4,6 +4,7 @@ import { StringifiedTimestamp, GenericSearchFilters, Order, + PaginatedBase, } from './common/common.types'; import { ContactType, @@ -509,7 +510,9 @@ interface SearchConversationRequest { Partial; } -type SearchConversationResponse = Paginated; +type SearchConversationResponse = PaginatedBase & { + conversations: ConversationObject[]; +}; // export enum SortBy { CreatedAt = 'created_at', diff --git a/yarn.lock b/yarn.lock index 9ff9500a..5f52b85d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1,3588 +1,1932 @@ -# This file is generated by running "yarn install" inside your project. -# Manual changes might be lost - proceed with caution! - -__metadata: - version: 5 - cacheKey: 8 - -"@babel/code-frame@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/code-frame@npm:7.16.7" - dependencies: - "@babel/highlight": ^7.16.7 - checksum: db2f7faa31bc2c9cf63197b481b30ea57147a5fc1a6fab60e5d6c02cdfbf6de8e17b5121f99917b3dabb5eeb572da078312e70697415940383efc140d4e0808b - languageName: node - linkType: hard - -"@babel/compat-data@npm:^7.16.4": - version: 7.16.8 - resolution: "@babel/compat-data@npm:7.16.8" - checksum: 10da2dac5ea9589c251412b00920889910e476c1ab24cd7095577635bc3a27c785151c89db4e26285fd39f509510ec29ab9d7e721f4fc16e4aec221cacde784b - languageName: node - linkType: hard - -"@babel/core@npm:^7.7.5": - version: 7.16.12 - resolution: "@babel/core@npm:7.16.12" - dependencies: - "@babel/code-frame": ^7.16.7 - "@babel/generator": ^7.16.8 - "@babel/helper-compilation-targets": ^7.16.7 - "@babel/helper-module-transforms": ^7.16.7 - "@babel/helpers": ^7.16.7 - "@babel/parser": ^7.16.12 - "@babel/template": ^7.16.7 - "@babel/traverse": ^7.16.10 - "@babel/types": ^7.16.8 - convert-source-map: ^1.7.0 - debug: ^4.1.0 - gensync: ^1.0.0-beta.2 - json5: ^2.1.2 - semver: ^6.3.0 - source-map: ^0.5.0 - checksum: 29b56f3cb7c329fc038a2efaccf64ac3025835676b3d90f57f2265b6acd477a970114d09021b38d019ac8f20b2bb1596a9e79ce1f820d6b8cf0e4a802891817c - languageName: node - linkType: hard - -"@babel/generator@npm:^7.16.8": - version: 7.16.8 - resolution: "@babel/generator@npm:7.16.8" - dependencies: - "@babel/types": ^7.16.8 - jsesc: ^2.5.1 - source-map: ^0.5.0 - checksum: 83af38b34735605c9d5f774c87a46c2cffaf666b28e9eeba883b2d7076412257e5c2264c26d9740ce44da6955fdaf857659391db02c012714a2a6dc19e403105 - languageName: node - linkType: hard - -"@babel/helper-compilation-targets@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-compilation-targets@npm:7.16.7" - dependencies: - "@babel/compat-data": ^7.16.4 - "@babel/helper-validator-option": ^7.16.7 - browserslist: ^4.17.5 - semver: ^6.3.0 - peerDependencies: - "@babel/core": ^7.0.0 - checksum: 7238aaee78c011a42fb5ca92e5eff098752f7b314c2111d7bb9cdd58792fcab1b9c819b59f6a0851dc210dc09dc06b30d130a23982753e70eb3111bc65204842 - languageName: node - linkType: hard - -"@babel/helper-environment-visitor@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-environment-visitor@npm:7.16.7" - dependencies: - "@babel/types": ^7.16.7 - checksum: c03a10105d9ebd1fe632a77356b2e6e2f3c44edba9a93b0dc3591b6a66bd7a2e323dd9502f9ce96fc6401234abff1907aa877b6674f7826b61c953f7c8204bbe - languageName: node - linkType: hard - -"@babel/helper-function-name@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-function-name@npm:7.16.7" - dependencies: - "@babel/helper-get-function-arity": ^7.16.7 - "@babel/template": ^7.16.7 - "@babel/types": ^7.16.7 - checksum: fc77cbe7b10cfa2a262d7a37dca575c037f20419dfe0c5d9317f589599ca24beb5f5c1057748011159149eaec47fe32338c6c6412376fcded68200df470161e1 - languageName: node - linkType: hard - -"@babel/helper-get-function-arity@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-get-function-arity@npm:7.16.7" - dependencies: - "@babel/types": ^7.16.7 - checksum: 25d969fb207ff2ad5f57a90d118f6c42d56a0171022e200aaa919ba7dc95ae7f92ec71cdea6c63ef3629a0dc962ab4c78e09ca2b437185ab44539193f796e0c3 - languageName: node - linkType: hard - -"@babel/helper-hoist-variables@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-hoist-variables@npm:7.16.7" - dependencies: - "@babel/types": ^7.16.7 - checksum: 6ae1641f4a751cd9045346e3f61c3d9ec1312fd779ab6d6fecfe2a96e59a481ad5d7e40d2a840894c13b3fd6114345b157f9e3062fc5f1580f284636e722de60 - languageName: node - linkType: hard - -"@babel/helper-module-imports@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-module-imports@npm:7.16.7" - dependencies: - "@babel/types": ^7.16.7 - checksum: ddd2c4a600a2e9a4fee192ab92bf35a627c5461dbab4af31b903d9ba4d6b6e59e0ff3499fde4e2e9a0eebe24906f00b636f8b4d9bd72ff24d50e6618215c3212 - languageName: node - linkType: hard - -"@babel/helper-module-transforms@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-module-transforms@npm:7.16.7" - dependencies: - "@babel/helper-environment-visitor": ^7.16.7 - "@babel/helper-module-imports": ^7.16.7 - "@babel/helper-simple-access": ^7.16.7 - "@babel/helper-split-export-declaration": ^7.16.7 - "@babel/helper-validator-identifier": ^7.16.7 - "@babel/template": ^7.16.7 - "@babel/traverse": ^7.16.7 - "@babel/types": ^7.16.7 - checksum: 6e930ce776c979f299cdbeaf80187f4ab086d75287b96ecc1c6896d392fcb561065f0d6219fc06fa79b4ceb4bbdc1a9847da8099aba9b077d0a9e583500fb673 - languageName: node - linkType: hard - -"@babel/helper-simple-access@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-simple-access@npm:7.16.7" - dependencies: - "@babel/types": ^7.16.7 - checksum: 8d22c46c5ec2ead0686c4d5a3d1d12b5190c59be676bfe0d9d89df62b437b51d1a3df2ccfb8a77dded2e585176ebf12986accb6d45a18cff229eef3b10344f4b - languageName: node - linkType: hard - -"@babel/helper-split-export-declaration@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-split-export-declaration@npm:7.16.7" - dependencies: - "@babel/types": ^7.16.7 - checksum: e10aaf135465c55114627951b79115f24bc7af72ecbb58d541d66daf1edaee5dde7cae3ec8c3639afaf74526c03ae3ce723444e3b5b3dc77140c456cd84bcaa1 - languageName: node - linkType: hard - -"@babel/helper-validator-identifier@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-validator-identifier@npm:7.16.7" - checksum: dbb3db9d184343152520a209b5684f5e0ed416109cde82b428ca9c759c29b10c7450657785a8b5c5256aa74acc6da491c1f0cf6b784939f7931ef82982051b69 - languageName: node - linkType: hard - -"@babel/helper-validator-option@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-validator-option@npm:7.16.7" - checksum: c5ccc451911883cc9f12125d47be69434f28094475c1b9d2ada7c3452e6ac98a1ee8ddd364ca9e3f9855fcdee96cdeafa32543ebd9d17fee7a1062c202e80570 - languageName: node - linkType: hard - -"@babel/helpers@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helpers@npm:7.16.7" - dependencies: - "@babel/template": ^7.16.7 - "@babel/traverse": ^7.16.7 - "@babel/types": ^7.16.7 - checksum: 75504c76b66a29b91f954fcc0867dfe275a4cfba5b44df6d64405df74ea72f967fccfa63d62c31c423c5502d113290000c581e0e4858a214f0303d7ecf55c29f - languageName: node - linkType: hard - -"@babel/highlight@npm:^7.16.7": - version: 7.16.10 - resolution: "@babel/highlight@npm:7.16.10" - dependencies: - "@babel/helper-validator-identifier": ^7.16.7 - chalk: ^2.0.0 - js-tokens: ^4.0.0 - checksum: 1f1bdd752a90844f4efc22166a46303fb651ba0fd75a06daba3ebae2575ab3edc1da9827c279872a3aaf305f50a18473c5fa1966752726a2b253065fd4c0745e - languageName: node - linkType: hard - -"@babel/parser@npm:^7.16.10, @babel/parser@npm:^7.16.12, @babel/parser@npm:^7.16.7": - version: 7.16.12 - resolution: "@babel/parser@npm:7.16.12" - bin: - parser: ./bin/babel-parser.js - checksum: af287f0f3dfa564958a7dddfeb62e08c0de9ce9bd8447fcde0997da26ec477bf19f37161b9d970e2c7e0d1f77e441258907d3347beddd0d42cae85ed46947703 - languageName: node - linkType: hard - -"@babel/template@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/template@npm:7.16.7" - dependencies: - "@babel/code-frame": ^7.16.7 - "@babel/parser": ^7.16.7 - "@babel/types": ^7.16.7 - checksum: 10cd112e89276e00f8b11b55a51c8b2f1262c318283a980f4d6cdb0286dc05734b9aaeeb9f3ad3311900b09bc913e02343fcaa9d4a4f413964aaab04eb84ac4a - languageName: node - linkType: hard - -"@babel/traverse@npm:^7.16.10, @babel/traverse@npm:^7.16.7": - version: 7.16.10 - resolution: "@babel/traverse@npm:7.16.10" - dependencies: - "@babel/code-frame": ^7.16.7 - "@babel/generator": ^7.16.8 - "@babel/helper-environment-visitor": ^7.16.7 - "@babel/helper-function-name": ^7.16.7 - "@babel/helper-hoist-variables": ^7.16.7 - "@babel/helper-split-export-declaration": ^7.16.7 - "@babel/parser": ^7.16.10 - "@babel/types": ^7.16.8 - debug: ^4.1.0 - globals: ^11.1.0 - checksum: 58f52314f8a02157cd3004712e703e6b22dff57cee4bc1ab1954c511c6f885fd7763ea68d2d5f006891bc7b77b1f2e9c8c7cb0354f580c8343d5559ed971d087 - languageName: node - linkType: hard - -"@babel/types@npm:^7.16.7, @babel/types@npm:^7.16.8, @babel/types@npm:^7.8.3": - version: 7.16.8 - resolution: "@babel/types@npm:7.16.8" - dependencies: - "@babel/helper-validator-identifier": ^7.16.7 - to-fast-properties: ^2.0.0 - checksum: 4f6a187b2924df70e21d6e6c0822f91b1b936fe060bc92bb477b93bd8a712c88fe41a73f85c0ec53b033353374fe33e773b04ffc340ad36afd8f647dd05c4ee1 - languageName: node - linkType: hard - -"@cspotcode/source-map-consumer@npm:0.8.0": - version: 0.8.0 - resolution: "@cspotcode/source-map-consumer@npm:0.8.0" - checksum: c0c16ca3d2f58898f1bd74c4f41a189dbcc202e642e60e489cbcc2e52419c4e89bdead02c886a12fb13ea37798ede9e562b2321df997ebc210ae9bd881561b4e - languageName: node - linkType: hard - -"@cspotcode/source-map-support@npm:0.7.0": - version: 0.7.0 - resolution: "@cspotcode/source-map-support@npm:0.7.0" - dependencies: - "@cspotcode/source-map-consumer": 0.8.0 - checksum: 9faddda7757cd778b5fd6812137b2cc265810043680d6399acc20441668fafcdc874053be9dccd0d9110087287bfad27eb3bf342f72bceca9aa9059f5d0c4be8 - languageName: node - linkType: hard - -"@eslint/eslintrc@npm:^1.0.5": - version: 1.0.5 - resolution: "@eslint/eslintrc@npm:1.0.5" - dependencies: - ajv: ^6.12.4 - debug: ^4.3.2 - espree: ^9.2.0 - globals: ^13.9.0 - ignore: ^4.0.6 - import-fresh: ^3.2.1 - js-yaml: ^4.1.0 - minimatch: ^3.0.4 - strip-json-comments: ^3.1.1 - checksum: b35b50d7b65bd8acd92a05b6fb15ac62c0cefa40dfef0324ca5bf8632bf3679bab6e173c53b3ad1e1d837701cecdbd9c144b35f46588cdf4e046a9caa272488d - languageName: node - linkType: hard - -"@gar/promisify@npm:^1.0.1": - version: 1.1.2 - resolution: "@gar/promisify@npm:1.1.2" - checksum: d05081e0887a49c178b75ee3067bd6ee086f73c154d121b854fb2e044e8a89cb1cbb6de3a0dd93a519b80f0531fda68b099dd7256205f7fbb3490324342f2217 - languageName: node - linkType: hard - -"@humanwhocodes/config-array@npm:^0.9.2": - version: 0.9.2 - resolution: "@humanwhocodes/config-array@npm:0.9.2" - dependencies: - "@humanwhocodes/object-schema": ^1.2.1 - debug: ^4.1.1 - minimatch: ^3.0.4 - checksum: 28a9e2974c50a86765cb6cc96e03d29187ea33fdaba62c4f35db89002e3cfbd340e64c9f6cf869e33e2e5cdcc06e78763458f4178d38a6f30aea1308787ca706 - languageName: node - linkType: hard - -"@humanwhocodes/object-schema@npm:^1.2.1": - version: 1.2.1 - resolution: "@humanwhocodes/object-schema@npm:1.2.1" - checksum: a824a1ec31591231e4bad5787641f59e9633827d0a2eaae131a288d33c9ef0290bd16fda8da6f7c0fcb014147865d12118df10db57f27f41e20da92369fcb3f1 - languageName: node - linkType: hard - -"@istanbuljs/load-nyc-config@npm:^1.0.0": - version: 1.1.0 - resolution: "@istanbuljs/load-nyc-config@npm:1.1.0" - dependencies: - camelcase: ^5.3.1 - find-up: ^4.1.0 - get-package-type: ^0.1.0 - js-yaml: ^3.13.1 - resolve-from: ^5.0.0 - checksum: d578da5e2e804d5c93228450a1380e1a3c691de4953acc162f387b717258512a3e07b83510a936d9fab03eac90817473917e24f5d16297af3867f59328d58568 - languageName: node - linkType: hard - -"@istanbuljs/nyc-config-typescript@npm:^1.0.2": - version: 1.0.2 - resolution: "@istanbuljs/nyc-config-typescript@npm:1.0.2" - dependencies: - "@istanbuljs/schema": ^0.1.2 - peerDependencies: - nyc: ">=15" - checksum: df6f9c9b17df8f1d8813f768c11ca31ec125d60bcd82d8273a467022e414d2d686ee80abb7b0f0e3c512b7ed686771fadb7fb5be8881619b9f6cb1f31b86e9f3 - languageName: node - linkType: hard - -"@istanbuljs/schema@npm:^0.1.2": - version: 0.1.3 - resolution: "@istanbuljs/schema@npm:0.1.3" - checksum: 5282759d961d61350f33d9118d16bcaed914ebf8061a52f4fa474b2cb08720c9c81d165e13b82f2e5a8a212cc5af482f0c6fc1ac27b9e067e5394c9a6ed186c9 - languageName: node - linkType: hard - -"@nodelib/fs.scandir@npm:2.1.5": - version: 2.1.5 - resolution: "@nodelib/fs.scandir@npm:2.1.5" - dependencies: - "@nodelib/fs.stat": 2.0.5 - run-parallel: ^1.1.9 - checksum: a970d595bd23c66c880e0ef1817791432dbb7acbb8d44b7e7d0e7a22f4521260d4a83f7f9fd61d44fda4610105577f8f58a60718105fb38352baed612fd79e59 - languageName: node - linkType: hard - -"@nodelib/fs.stat@npm:2.0.5, @nodelib/fs.stat@npm:^2.0.2": - version: 2.0.5 - resolution: "@nodelib/fs.stat@npm:2.0.5" - checksum: 012480b5ca9d97bff9261571dbbec7bbc6033f69cc92908bc1ecfad0792361a5a1994bc48674b9ef76419d056a03efadfce5a6cf6dbc0a36559571a7a483f6f0 - languageName: node - linkType: hard - -"@nodelib/fs.walk@npm:^1.2.3": - version: 1.2.8 - resolution: "@nodelib/fs.walk@npm:1.2.8" - dependencies: - "@nodelib/fs.scandir": 2.1.5 - fastq: ^1.6.0 - checksum: 190c643f156d8f8f277bf2a6078af1ffde1fd43f498f187c2db24d35b4b4b5785c02c7dc52e356497b9a1b65b13edc996de08de0b961c32844364da02986dc53 - languageName: node - linkType: hard - -"@npmcli/fs@npm:^1.0.0": - version: 1.1.0 - resolution: "@npmcli/fs@npm:1.1.0" - dependencies: - "@gar/promisify": ^1.0.1 - semver: ^7.3.5 - checksum: e435b883b4f8da8c95a820f458cabb7d86582406eed5ad79fc689000d3e2df17e1f475c4903627272c001357cabc70d8b4c62520cbdae8cfab1dfdd51949f408 - languageName: node - linkType: hard - -"@npmcli/move-file@npm:^1.0.1": - version: 1.1.2 - resolution: "@npmcli/move-file@npm:1.1.2" - dependencies: - mkdirp: ^1.0.4 - rimraf: ^3.0.2 - checksum: c96381d4a37448ea280951e46233f7e541058cf57a57d4094dd4bdcaae43fa5872b5f2eb6bfb004591a68e29c5877abe3cdc210cb3588cbf20ab2877f31a7de7 - languageName: node - linkType: hard - -"@sinonjs/commons@npm:^1, @sinonjs/commons@npm:^1.3.0, @sinonjs/commons@npm:^1.4.0, @sinonjs/commons@npm:^1.7.0": - version: 1.8.3 - resolution: "@sinonjs/commons@npm:1.8.3" - dependencies: - type-detect: 4.0.8 - checksum: 6159726db5ce6bf9f2297f8427f7ca5b3dff45b31e5cee23496f1fa6ef0bb4eab878b23fb2c5e6446381f6a66aba4968ef2fc255c1180d753d4b8c271636a2e5 - languageName: node - linkType: hard - -"@sinonjs/fake-timers@npm:^7.1.0": - version: 7.1.2 - resolution: "@sinonjs/fake-timers@npm:7.1.2" - dependencies: - "@sinonjs/commons": ^1.7.0 - checksum: c84773d7973edad5511a31d2cc75023447b5cf714a84de9bb50eda45dda88a0d3bd2c30bf6e6e936da50a048d5352e2151c694e13e59b97d187ba1f329e9a00c - languageName: node - linkType: hard - -"@sinonjs/formatio@npm:^3.2.1": - version: 3.2.2 - resolution: "@sinonjs/formatio@npm:3.2.2" - dependencies: - "@sinonjs/commons": ^1 - "@sinonjs/samsam": ^3.1.0 - checksum: ddc30698df9b0aa59204da93ca94fd04bc5672ac03c798c0a487c35d514d7d8e0ce0e4c72386fc80e29f59cb1cc54eeea3b7f804281b3c4e3dd2394de56c6e4a - languageName: node - linkType: hard - -"@sinonjs/samsam@npm:^3.1.0, @sinonjs/samsam@npm:^3.3.3": - version: 3.3.3 - resolution: "@sinonjs/samsam@npm:3.3.3" - dependencies: - "@sinonjs/commons": ^1.3.0 - array-from: ^2.1.1 - lodash: ^4.17.15 - checksum: 340f2f62dec3fa1e5e9300a75996bd12ab9d2da4f6b453fa5d1ee101cc5e58eb218af2e2584b496d41ba31c3c0854d47a691fd9a0d8b9092f3cb6a5c7a080856 - languageName: node - linkType: hard - -"@sinonjs/text-encoding@npm:^0.7.1": - version: 0.7.1 - resolution: "@sinonjs/text-encoding@npm:0.7.1" - checksum: 130de0bb568c5f8a611ec21d1a4e3f80ab0c5ec333010f49cfc1adc5cba6d8808699c8a587a46b0f0b016a1f4c1389bc96141e773e8460fcbb441875b2e91ba7 - languageName: node - linkType: hard - -"@tootallnate/once@npm:1": - version: 1.1.2 - resolution: "@tootallnate/once@npm:1.1.2" - checksum: e1fb1bbbc12089a0cb9433dc290f97bddd062deadb6178ce9bcb93bb7c1aecde5e60184bc7065aec42fe1663622a213493c48bbd4972d931aae48315f18e1be9 - languageName: node - linkType: hard - -"@tsconfig/node10@npm:^1.0.7": - version: 1.0.8 - resolution: "@tsconfig/node10@npm:1.0.8" - checksum: b8d5fffbc6b17ef64ef74f7fdbccee02a809a063ade785c3648dae59406bc207f70ea2c4296f92749b33019fa36a5ae716e42e49cc7f1bbf0fd147be0d6b970a - languageName: node - linkType: hard - -"@tsconfig/node12@npm:^1.0.7": - version: 1.0.9 - resolution: "@tsconfig/node12@npm:1.0.9" - checksum: a01b2400ab3582b86b589c6d31dcd0c0656f333adecde85d6d7d4086adb059808b82692380bb169546d189bf771ae21d02544a75b57bd6da4a5dd95f8567bec9 - languageName: node - linkType: hard - -"@tsconfig/node14@npm:^1.0.0": - version: 1.0.1 - resolution: "@tsconfig/node14@npm:1.0.1" - checksum: 976345e896c0f059867f94f8d0f6ddb8b1844fb62bf36b727de8a9a68f024857e5db97ed51d3325e23e0616a5e48c034ff51a8d595b3fe7e955f3587540489be - languageName: node - linkType: hard - -"@tsconfig/node16@npm:^1.0.2": - version: 1.0.2 - resolution: "@tsconfig/node16@npm:1.0.2" - checksum: ca94d3639714672bbfd55f03521d3f56bb6a25479bd425da81faf21f13e1e9d15f40f97377dedbbf477a5841c5b0c8f4cd1b391f33553d750b9202c54c2c07aa - languageName: node - linkType: hard - -"@types/json-schema@npm:^7.0.9": - version: 7.0.9 - resolution: "@types/json-schema@npm:7.0.9" - checksum: 259d0e25f11a21ba5c708f7ea47196bd396e379fddb79c76f9f4f62c945879dc21657904914313ec2754e443c5018ea8372362f323f30e0792897fdb2098a705 - languageName: node - linkType: hard - -"@types/lodash@npm:^4.14.176": - version: 4.14.178 - resolution: "@types/lodash@npm:4.14.178" - checksum: a69a04a60bfc5257c3130a554b4efa0c383f0141b7b3db8ab7cf07ad2a46ea085fce66d0242da41da7e5647b133d5dfb2c15add9cbed8d7fef955e4a1e5b3128 - languageName: node - linkType: hard - -"@types/mocha@npm:^9.1.0": - version: 9.1.0 - resolution: "@types/mocha@npm:9.1.0" - checksum: 21e1000dafcfe387c6812be41c44a47b48c27a74d5a70c3d5ef1bb5c88eadadfc74dba06e93f160e7248c8a57b3977b590f82504c801c9927816ecd4668023c0 - languageName: node - linkType: hard - -"@types/node@npm:^16.11.6": - version: 16.11.21 - resolution: "@types/node@npm:16.11.21" - checksum: 75b679dc6375cf09bc14a2d1b344be6f3fd8ea50f212b0d60970dc9e175cef45e44c284c716eb9e766ffa52d0c83b689adb3d1911b6dd8649c560b8f77442a22 - languageName: node - linkType: hard - -"@types/sinon@npm:^10.0.6": - version: 10.0.8 - resolution: "@types/sinon@npm:10.0.8" - dependencies: - "@sinonjs/fake-timers": ^7.1.0 - checksum: 76a00bc4e80a90c15b0691387703a85274d80e96a133281e993214488a47020ca0d0957a924f87468b4b6ade3465edd39ac2a451daea7d0f6f07ac352bc29309 - languageName: node - linkType: hard - -"@typescript-eslint/eslint-plugin@npm:^5.7.0": - version: 5.10.0 - resolution: "@typescript-eslint/eslint-plugin@npm:5.10.0" - dependencies: - "@typescript-eslint/scope-manager": 5.10.0 - "@typescript-eslint/type-utils": 5.10.0 - "@typescript-eslint/utils": 5.10.0 - debug: ^4.3.2 - functional-red-black-tree: ^1.0.1 - ignore: ^5.1.8 - regexpp: ^3.2.0 - semver: ^7.3.5 - tsutils: ^3.21.0 - peerDependencies: - "@typescript-eslint/parser": ^5.0.0 - eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 - peerDependenciesMeta: - typescript: - optional: true - checksum: 675b79c519e5287a184720317d309c55e308c19eb52f1f062e3851168a9b6e4768363bd31bdcbf897c080f1c21cb39736cd522408620818dd9ce483d1573bf89 - languageName: node - linkType: hard - -"@typescript-eslint/parser@npm:^5.7.0": - version: 5.10.0 - resolution: "@typescript-eslint/parser@npm:5.10.0" - dependencies: - "@typescript-eslint/scope-manager": 5.10.0 - "@typescript-eslint/types": 5.10.0 - "@typescript-eslint/typescript-estree": 5.10.0 - debug: ^4.3.2 - peerDependencies: - eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 - peerDependenciesMeta: - typescript: - optional: true - checksum: 127aaa807659bbd4b2b274263d1ef821b8d0746f0a18ae55466718d070ba43c94e5575849954271f0d6582d2114c96a0ff6645189015a6522c4d8682d4d20a1b - languageName: node - linkType: hard - -"@typescript-eslint/scope-manager@npm:5.10.0": - version: 5.10.0 - resolution: "@typescript-eslint/scope-manager@npm:5.10.0" - dependencies: - "@typescript-eslint/types": 5.10.0 - "@typescript-eslint/visitor-keys": 5.10.0 - checksum: 934cbb4a03d383537fda05b926eeba0597d63ef1c65328d55abe20a060b6559ba2017825e167dc2093a23d675c37aaa2056dec1747b17f0fbca419fba68f8d0f - languageName: node - linkType: hard - -"@typescript-eslint/type-utils@npm:5.10.0": - version: 5.10.0 - resolution: "@typescript-eslint/type-utils@npm:5.10.0" - dependencies: - "@typescript-eslint/utils": 5.10.0 - debug: ^4.3.2 - tsutils: ^3.21.0 - peerDependencies: - eslint: "*" - peerDependenciesMeta: - typescript: - optional: true - checksum: aa6bf7fcac7aa956ccf938b8d93d1ecd8956ea1f5690046967fe69f0bd2592cd8e29a992f5a252990b8e13c1e09c3f9efb6375d0551f4b4c08c69cd662be2e73 - languageName: node - linkType: hard - -"@typescript-eslint/types@npm:5.10.0": - version: 5.10.0 - resolution: "@typescript-eslint/types@npm:5.10.0" - checksum: 269988cbb1772616ade3af5f70a3c4d7871c90fa04fbc4ed8b1148ec0a6853f2d51609fe51aa797486bfe9b704a4c4a3410e6225470db18850d3469a7db5a63b - languageName: node - linkType: hard - -"@typescript-eslint/typescript-estree@npm:5.10.0": - version: 5.10.0 - resolution: "@typescript-eslint/typescript-estree@npm:5.10.0" - dependencies: - "@typescript-eslint/types": 5.10.0 - "@typescript-eslint/visitor-keys": 5.10.0 - debug: ^4.3.2 - globby: ^11.0.4 - is-glob: ^4.0.3 - semver: ^7.3.5 - tsutils: ^3.21.0 - peerDependenciesMeta: - typescript: - optional: true - checksum: 1097fd5a96857a285020a2c5ee7abb7e5984771ac44b61b5d500724dc3ff88030e4e5340fcd872779b1307fbb224240d6543babb901559675efcab20a2dc70dc - languageName: node - linkType: hard - -"@typescript-eslint/utils@npm:5.10.0": - version: 5.10.0 - resolution: "@typescript-eslint/utils@npm:5.10.0" - dependencies: - "@types/json-schema": ^7.0.9 - "@typescript-eslint/scope-manager": 5.10.0 - "@typescript-eslint/types": 5.10.0 - "@typescript-eslint/typescript-estree": 5.10.0 - eslint-scope: ^5.1.1 - eslint-utils: ^3.0.0 - peerDependencies: - eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 - checksum: 9c53b0e47b922210c5dc0c7ac045206062ad4f21f9bf03ef091894d3fcfe9fde7e72c70a97b5073a54a42b7628943dd8dcef00bd3285ebd63039909888dea84a - languageName: node - linkType: hard - -"@typescript-eslint/visitor-keys@npm:5.10.0": - version: 5.10.0 - resolution: "@typescript-eslint/visitor-keys@npm:5.10.0" - dependencies: - "@typescript-eslint/types": 5.10.0 - eslint-visitor-keys: ^3.0.0 - checksum: 9b99c6be709c59be6a1705f0244aad732a5e523af8b8eb87e5dd6a3d27a027329bf2617aa6f15a36f79bce4215ac09277e144737a0d8d674e93b073b36fd963e - languageName: node - linkType: hard - -"@ungap/promise-all-settled@npm:1.1.2": - version: 1.1.2 - resolution: "@ungap/promise-all-settled@npm:1.1.2" - checksum: 08d37fdfa23a6fe8139f1305313562ebad973f3fac01bcce2773b2bda5bcb0146dfdcf3cb6a722cf0a5f2ca0bc56a827eac8f1e7b3beddc548f654addf1fc34c - languageName: node - linkType: hard - -"abbrev@npm:1": - version: 1.1.1 - resolution: "abbrev@npm:1.1.1" - checksum: a4a97ec07d7ea112c517036882b2ac22f3109b7b19077dc656316d07d308438aac28e4d9746dc4d84bf6b1e75b4a7b0a5f3cb30592419f128ca9a8cee3bcfa17 - languageName: node - linkType: hard - -"acorn-jsx@npm:^5.3.1": - version: 5.3.2 - resolution: "acorn-jsx@npm:5.3.2" - peerDependencies: - acorn: ^6.0.0 || ^7.0.0 || ^8.0.0 - checksum: c3d3b2a89c9a056b205b69530a37b972b404ee46ec8e5b341666f9513d3163e2a4f214a71f4dfc7370f5a9c07472d2fd1c11c91c3f03d093e37637d95da98950 - languageName: node - linkType: hard - -"acorn-walk@npm:^8.1.1": - version: 8.2.0 - resolution: "acorn-walk@npm:8.2.0" - checksum: 1715e76c01dd7b2d4ca472f9c58968516a4899378a63ad5b6c2d668bba8da21a71976c14ec5f5b75f887b6317c4ae0b897ab141c831d741dc76024d8745f1ad1 - languageName: node - linkType: hard - -"acorn@npm:^8.4.1, acorn@npm:^8.7.0": - version: 8.7.0 - resolution: "acorn@npm:8.7.0" - bin: - acorn: bin/acorn - checksum: e0f79409d68923fbf1aa6d4166f3eedc47955320d25c89a20cc822e6ba7c48c5963d5bc657bc242d68f7a4ac9faf96eef033e8f73656da6c640d4219935fdfd0 - languageName: node - linkType: hard - -"agent-base@npm:6, agent-base@npm:^6.0.2": - version: 6.0.2 - resolution: "agent-base@npm:6.0.2" - dependencies: - debug: 4 - checksum: f52b6872cc96fd5f622071b71ef200e01c7c4c454ee68bc9accca90c98cfb39f2810e3e9aa330435835eedc8c23f4f8a15267f67c6e245d2b33757575bdac49d - languageName: node - linkType: hard - -"agentkeepalive@npm:^4.1.3": - version: 4.2.0 - resolution: "agentkeepalive@npm:4.2.0" - dependencies: - debug: ^4.1.0 - depd: ^1.1.2 - humanize-ms: ^1.2.1 - checksum: 89806f83ceebbcaabf6bd581a8dce4870910fd2a11f66df8f505b4cd4ce4ca5ab9e6eec8d11ce8531a6b60f6748b75b0775e0e2fa33871503ef00d535418a19a - languageName: node - linkType: hard - -"aggregate-error@npm:^3.0.0": - version: 3.1.0 - resolution: "aggregate-error@npm:3.1.0" - dependencies: - clean-stack: ^2.0.0 - indent-string: ^4.0.0 - checksum: 1101a33f21baa27a2fa8e04b698271e64616b886795fd43c31068c07533c7b3facfcaf4e9e0cab3624bd88f729a592f1c901a1a229c9e490eafce411a8644b79 - languageName: node - linkType: hard - -"ajv@npm:^6.10.0, ajv@npm:^6.12.4": - version: 6.12.6 - resolution: "ajv@npm:6.12.6" - dependencies: - fast-deep-equal: ^3.1.1 - fast-json-stable-stringify: ^2.0.0 - json-schema-traverse: ^0.4.1 - uri-js: ^4.2.2 - checksum: 874972efe5c4202ab0a68379481fbd3d1b5d0a7bd6d3cc21d40d3536ebff3352a2a1fabb632d4fd2cc7fe4cbdcd5ed6782084c9bbf7f32a1536d18f9da5007d4 - languageName: node - linkType: hard - -"ansi-colors@npm:4.1.1": - version: 4.1.1 - resolution: "ansi-colors@npm:4.1.1" - checksum: 138d04a51076cb085da0a7e2d000c5c0bb09f6e772ed5c65c53cb118d37f6c5f1637506d7155fb5f330f0abcf6f12fa2e489ac3f8cdab9da393bf1bb4f9a32b0 - languageName: node - linkType: hard - -"ansi-regex@npm:^5.0.1": - version: 5.0.1 - resolution: "ansi-regex@npm:5.0.1" - checksum: 2aa4bb54caf2d622f1afdad09441695af2a83aa3fe8b8afa581d205e57ed4261c183c4d3877cee25794443fde5876417d859c108078ab788d6af7e4fe52eb66b - languageName: node - linkType: hard - -"ansi-styles@npm:^3.2.1": - version: 3.2.1 - resolution: "ansi-styles@npm:3.2.1" - dependencies: - color-convert: ^1.9.0 - checksum: d85ade01c10e5dd77b6c89f34ed7531da5830d2cb5882c645f330079975b716438cd7ebb81d0d6e6b4f9c577f19ae41ab55f07f19786b02f9dfd9e0377395665 - languageName: node - linkType: hard - -"ansi-styles@npm:^4.0.0, ansi-styles@npm:^4.1.0": - version: 4.3.0 - resolution: "ansi-styles@npm:4.3.0" - dependencies: - color-convert: ^2.0.1 - checksum: 513b44c3b2105dd14cc42a19271e80f386466c4be574bccf60b627432f9198571ebf4ab1e4c3ba17347658f4ee1711c163d574248c0c1cdc2d5917a0ad582ec4 - languageName: node - linkType: hard - -"anymatch@npm:~3.1.2": - version: 3.1.2 - resolution: "anymatch@npm:3.1.2" - dependencies: - normalize-path: ^3.0.0 - picomatch: ^2.0.4 - checksum: 985163db2292fac9e5a1e072bf99f1b5baccf196e4de25a0b0b81865ebddeb3b3eb4480734ef0a2ac8c002845396b91aa89121f5b84f93981a4658164a9ec6e9 - languageName: node - linkType: hard - -"append-transform@npm:^2.0.0": - version: 2.0.0 - resolution: "append-transform@npm:2.0.0" - dependencies: - default-require-extensions: ^3.0.0 - checksum: f26f393bf7a428fd1bb18f2758a819830a582243310c5170edb3f98fdc5a535333d02b952f7c2d9b14522bd8ead5b132a0b15000eca18fa9f49172963ebbc231 - languageName: node - linkType: hard - -"aproba@npm:^1.0.3 || ^2.0.0": - version: 2.0.0 - resolution: "aproba@npm:2.0.0" - checksum: 5615cadcfb45289eea63f8afd064ab656006361020e1735112e346593856f87435e02d8dcc7ff0d11928bc7d425f27bc7c2a84f6c0b35ab0ff659c814c138a24 - languageName: node - linkType: hard - -"archy@npm:^1.0.0": - version: 1.0.0 - resolution: "archy@npm:1.0.0" - checksum: 504ae7af655130bab9f471343cfdb054feaec7d8e300e13348bc9fe9e660f83d422e473069584f73233c701ae37d1c8452ff2522f2a20c38849e0f406f1732ac - languageName: node - linkType: hard - -"are-we-there-yet@npm:^2.0.0": - version: 2.0.0 - resolution: "are-we-there-yet@npm:2.0.0" - dependencies: - delegates: ^1.0.0 - readable-stream: ^3.6.0 - checksum: 6c80b4fd04ecee6ba6e737e0b72a4b41bdc64b7d279edfc998678567ff583c8df27e27523bc789f2c99be603ffa9eaa612803da1d886962d2086e7ff6fa90c7c - languageName: node - linkType: hard - -"arg@npm:^4.1.0": - version: 4.1.3 - resolution: "arg@npm:4.1.3" - checksum: 544af8dd3f60546d3e4aff084d451b96961d2267d668670199692f8d054f0415d86fc5497d0e641e91546f0aa920e7c29e5250e99fc89f5552a34b5d93b77f43 - languageName: node - linkType: hard - -"argparse@npm:^1.0.7": - version: 1.0.10 - resolution: "argparse@npm:1.0.10" - dependencies: - sprintf-js: ~1.0.2 - checksum: 7ca6e45583a28de7258e39e13d81e925cfa25d7d4aacbf806a382d3c02fcb13403a07fb8aeef949f10a7cfe4a62da0e2e807b348a5980554cc28ee573ef95945 - languageName: node - linkType: hard - -"argparse@npm:^2.0.1": - version: 2.0.1 - resolution: "argparse@npm:2.0.1" - checksum: 83644b56493e89a254bae05702abf3a1101b4fa4d0ca31df1c9985275a5a5bd47b3c27b7fa0b71098d41114d8ca000e6ed90cad764b306f8a503665e4d517ced - languageName: node - linkType: hard - -"array-from@npm:^2.1.1": - version: 2.1.1 - resolution: "array-from@npm:2.1.1" - checksum: 4cd5fa27aa6133b99a57c2881d2a8a66ec59b8e17a0c900f7e8ac9a0a2fae450ed682b67435467bfa71ac9328d025a760c5c46a95586a352180c5a79fc13015d - languageName: node - linkType: hard - -"array-union@npm:^2.1.0": - version: 2.1.0 - resolution: "array-union@npm:2.1.0" - checksum: 5bee12395cba82da674931df6d0fea23c4aa4660cb3b338ced9f828782a65caa232573e6bf3968f23e0c5eb301764a382cef2f128b170a9dc59de0e36c39f98d - languageName: node - linkType: hard - -"axios@npm:^0.24.0": - version: 0.24.0 - resolution: "axios@npm:0.24.0" - dependencies: - follow-redirects: ^1.14.4 - checksum: 468cf496c08a6aadfb7e699bebdac02851e3043d4e7d282350804ea8900e30d368daa6e3cd4ab83b8ddb5a3b1e17a5a21ada13fc9cebd27b74828f47a4236316 - languageName: node - linkType: hard - -"balanced-match@npm:^1.0.0": - version: 1.0.2 - resolution: "balanced-match@npm:1.0.2" - checksum: 9706c088a283058a8a99e0bf91b0a2f75497f185980d9ffa8b304de1d9e58ebda7c72c07ebf01dadedaac5b2907b2c6f566f660d62bd336c3468e960403b9d65 - languageName: node - linkType: hard - -"binary-extensions@npm:^2.0.0": - version: 2.2.0 - resolution: "binary-extensions@npm:2.2.0" - checksum: ccd267956c58d2315f5d3ea6757cf09863c5fc703e50fbeb13a7dc849b812ef76e3cf9ca8f35a0c48498776a7478d7b4a0418e1e2b8cb9cb9731f2922aaad7f8 - languageName: node - linkType: hard - -"brace-expansion@npm:^1.1.7": - version: 1.1.11 - resolution: "brace-expansion@npm:1.1.11" - dependencies: - balanced-match: ^1.0.0 - concat-map: 0.0.1 - checksum: faf34a7bb0c3fcf4b59c7808bc5d2a96a40988addf2e7e09dfbb67a2251800e0d14cd2bfc1aa79174f2f5095c54ff27f46fb1289fe2d77dac755b5eb3434cc07 - languageName: node - linkType: hard - -"braces@npm:^3.0.1, braces@npm:~3.0.2": - version: 3.0.2 - resolution: "braces@npm:3.0.2" - dependencies: - fill-range: ^7.0.1 - checksum: e2a8e769a863f3d4ee887b5fe21f63193a891c68b612ddb4b68d82d1b5f3ff9073af066c343e9867a393fe4c2555dcb33e89b937195feb9c1613d259edfcd459 - languageName: node - linkType: hard - -"browser-stdout@npm:1.3.1": - version: 1.3.1 - resolution: "browser-stdout@npm:1.3.1" - checksum: b717b19b25952dd6af483e368f9bcd6b14b87740c3d226c2977a65e84666ffd67000bddea7d911f111a9b6ddc822b234de42d52ab6507bce4119a4cc003ef7b3 - languageName: node - linkType: hard - -"browserslist@npm:^4.17.5": - version: 4.19.1 - resolution: "browserslist@npm:4.19.1" - dependencies: - caniuse-lite: ^1.0.30001286 - electron-to-chromium: ^1.4.17 - escalade: ^3.1.1 - node-releases: ^2.0.1 - picocolors: ^1.0.0 - bin: - browserslist: cli.js - checksum: c0777fd483691638fd6801e16c9d809e1d65f6d2b06db2e806654be51045cbab1452a89841a2c5caea2cbe19d621b4f1d391cffbb24512aa33280039ab345875 - languageName: node - linkType: hard - -"cacache@npm:^15.2.0": - version: 15.3.0 - resolution: "cacache@npm:15.3.0" - dependencies: - "@npmcli/fs": ^1.0.0 - "@npmcli/move-file": ^1.0.1 - chownr: ^2.0.0 - fs-minipass: ^2.0.0 - glob: ^7.1.4 - infer-owner: ^1.0.4 - lru-cache: ^6.0.0 - minipass: ^3.1.1 - minipass-collect: ^1.0.2 - minipass-flush: ^1.0.5 - minipass-pipeline: ^1.2.2 - mkdirp: ^1.0.3 - p-map: ^4.0.0 - promise-inflight: ^1.0.1 - rimraf: ^3.0.2 - ssri: ^8.0.1 - tar: ^6.0.2 - unique-filename: ^1.1.1 - checksum: a07327c27a4152c04eb0a831c63c00390d90f94d51bb80624a66f4e14a6b6360bbf02a84421267bd4d00ca73ac9773287d8d7169e8d2eafe378d2ce140579db8 - languageName: node - linkType: hard - -"caching-transform@npm:^4.0.0": - version: 4.0.0 - resolution: "caching-transform@npm:4.0.0" - dependencies: - hasha: ^5.0.0 - make-dir: ^3.0.0 - package-hash: ^4.0.0 - write-file-atomic: ^3.0.0 - checksum: c4db6939533b677866808de67c32f0aaf8bf4fd3e3b8dc957e5d630c007c06b7f11512d44c38a38287fb068e931067e8da9019c34d787259a44121c9a6b87a1f - languageName: node - linkType: hard - -"callsites@npm:^3.0.0": - version: 3.1.0 - resolution: "callsites@npm:3.1.0" - checksum: 072d17b6abb459c2ba96598918b55868af677154bec7e73d222ef95a8fdb9bbf7dae96a8421085cdad8cd190d86653b5b6dc55a4484f2e5b2e27d5e0c3fc15b3 - languageName: node - linkType: hard - -"camelcase@npm:^5.0.0, camelcase@npm:^5.3.1": - version: 5.3.1 - resolution: "camelcase@npm:5.3.1" - checksum: e6effce26b9404e3c0f301498184f243811c30dfe6d0b9051863bd8e4034d09c8c2923794f280d6827e5aa055f6c434115ff97864a16a963366fb35fd673024b - languageName: node - linkType: hard - -"camelcase@npm:^6.0.0": - version: 6.3.0 - resolution: "camelcase@npm:6.3.0" - checksum: 8c96818a9076434998511251dcb2761a94817ea17dbdc37f47ac080bd088fc62c7369429a19e2178b993497132c8cbcf5cc1f44ba963e76782ba469c0474938d - languageName: node - linkType: hard - -"caniuse-lite@npm:^1.0.30001286": - version: 1.0.30001301 - resolution: "caniuse-lite@npm:1.0.30001301" - checksum: 0e359f2c682bed35521902ce7fc91136c485de4c1e1e33272d6fbb7cdf77178df7649960a9b69ce9da12022aadd7a0037b3c9b3594c41146d58216654dc9a236 - languageName: node - linkType: hard - -"chalk@npm:^2.0.0": - version: 2.4.2 - resolution: "chalk@npm:2.4.2" - dependencies: - ansi-styles: ^3.2.1 - escape-string-regexp: ^1.0.5 - supports-color: ^5.3.0 - checksum: ec3661d38fe77f681200f878edbd9448821924e0f93a9cefc0e26a33b145f1027a2084bf19967160d11e1f03bfe4eaffcabf5493b89098b2782c3fe0b03d80c2 - languageName: node - linkType: hard - -"chalk@npm:^4.0.0, chalk@npm:^4.1.0": - version: 4.1.2 - resolution: "chalk@npm:4.1.2" - dependencies: - ansi-styles: ^4.1.0 - supports-color: ^7.1.0 - checksum: fe75c9d5c76a7a98d45495b91b2172fa3b7a09e0cc9370e5c8feb1c567b85c4288e2b3fded7cfdd7359ac28d6b3844feb8b82b8686842e93d23c827c417e83fc - languageName: node - linkType: hard - -"chokidar@npm:3.5.3": - version: 3.5.3 - resolution: "chokidar@npm:3.5.3" - dependencies: - anymatch: ~3.1.2 - braces: ~3.0.2 - fsevents: ~2.3.2 - glob-parent: ~5.1.2 - is-binary-path: ~2.1.0 - is-glob: ~4.0.1 - normalize-path: ~3.0.0 - readdirp: ~3.6.0 - dependenciesMeta: - fsevents: - optional: true - checksum: b49fcde40176ba007ff361b198a2d35df60d9bb2a5aab228279eb810feae9294a6b4649ab15981304447afe1e6ffbf4788ad5db77235dc770ab777c6e771980c - languageName: node - linkType: hard - -"chownr@npm:^2.0.0": - version: 2.0.0 - resolution: "chownr@npm:2.0.0" - checksum: c57cf9dd0791e2f18a5ee9c1a299ae6e801ff58fee96dc8bfd0dcb4738a6ce58dd252a3605b1c93c6418fe4f9d5093b28ffbf4d66648cb2a9c67eaef9679be2f - languageName: node - linkType: hard - -"clean-stack@npm:^2.0.0": - version: 2.2.0 - resolution: "clean-stack@npm:2.2.0" - checksum: 2ac8cd2b2f5ec986a3c743935ec85b07bc174d5421a5efc8017e1f146a1cf5f781ae962618f416352103b32c9cd7e203276e8c28241bbe946160cab16149fb68 - languageName: node - linkType: hard - -"cliui@npm:^6.0.0": - version: 6.0.0 - resolution: "cliui@npm:6.0.0" - dependencies: - string-width: ^4.2.0 - strip-ansi: ^6.0.0 - wrap-ansi: ^6.2.0 - checksum: 4fcfd26d292c9f00238117f39fc797608292ae36bac2168cfee4c85923817d0607fe21b3329a8621e01aedf512c99b7eaa60e363a671ffd378df6649fb48ae42 - languageName: node - linkType: hard - -"cliui@npm:^7.0.2": - version: 7.0.4 - resolution: "cliui@npm:7.0.4" - dependencies: - string-width: ^4.2.0 - strip-ansi: ^6.0.0 - wrap-ansi: ^7.0.0 - checksum: ce2e8f578a4813806788ac399b9e866297740eecd4ad1823c27fd344d78b22c5f8597d548adbcc46f0573e43e21e751f39446c5a5e804a12aace402b7a315d7f - languageName: node - linkType: hard - -"color-convert@npm:^1.9.0": - version: 1.9.3 - resolution: "color-convert@npm:1.9.3" - dependencies: - color-name: 1.1.3 - checksum: fd7a64a17cde98fb923b1dd05c5f2e6f7aefda1b60d67e8d449f9328b4e53b228a428fd38bfeaeb2db2ff6b6503a776a996150b80cdf224062af08a5c8a3a203 - languageName: node - linkType: hard - -"color-convert@npm:^2.0.1": - version: 2.0.1 - resolution: "color-convert@npm:2.0.1" - dependencies: - color-name: ~1.1.4 - checksum: 79e6bdb9fd479a205c71d89574fccfb22bd9053bd98c6c4d870d65c132e5e904e6034978e55b43d69fcaa7433af2016ee203ce76eeba9cfa554b373e7f7db336 - languageName: node - linkType: hard - -"color-name@npm:1.1.3": - version: 1.1.3 - resolution: "color-name@npm:1.1.3" - checksum: 09c5d3e33d2105850153b14466501f2bfb30324a2f76568a408763a3b7433b0e50e5b4ab1947868e65cb101bb7cb75029553f2c333b6d4b8138a73fcc133d69d - languageName: node - linkType: hard - -"color-name@npm:~1.1.4": - version: 1.1.4 - resolution: "color-name@npm:1.1.4" - checksum: b0445859521eb4021cd0fb0cc1a75cecf67fceecae89b63f62b201cca8d345baf8b952c966862a9d9a2632987d4f6581f0ec8d957dfacece86f0a7919316f610 - languageName: node - linkType: hard - -"color-support@npm:^1.1.2": - version: 1.1.3 - resolution: "color-support@npm:1.1.3" - bin: - color-support: bin.js - checksum: 9b7356817670b9a13a26ca5af1c21615463b500783b739b7634a0c2047c16cef4b2865d7576875c31c3cddf9dd621fa19285e628f20198b233a5cfdda6d0793b - languageName: node - linkType: hard - -"commondir@npm:^1.0.1": - version: 1.0.1 - resolution: "commondir@npm:1.0.1" - checksum: 59715f2fc456a73f68826285718503340b9f0dd89bfffc42749906c5cf3d4277ef11ef1cca0350d0e79204f00f1f6d83851ececc9095dc88512a697ac0b9bdcb - languageName: node - linkType: hard - -"concat-map@npm:0.0.1": - version: 0.0.1 - resolution: "concat-map@npm:0.0.1" - checksum: 902a9f5d8967a3e2faf138d5cb784b9979bad2e6db5357c5b21c568df4ebe62bcb15108af1b2253744844eb964fc023fbd9afbbbb6ddd0bcc204c6fb5b7bf3af - languageName: node - linkType: hard - -"console-control-strings@npm:^1.0.0, console-control-strings@npm:^1.1.0": - version: 1.1.0 - resolution: "console-control-strings@npm:1.1.0" - checksum: 8755d76787f94e6cf79ce4666f0c5519906d7f5b02d4b884cf41e11dcd759ed69c57da0670afd9236d229a46e0f9cf519db0cd829c6dca820bb5a5c3def584ed - languageName: node - linkType: hard - -"convert-source-map@npm:^1.7.0": - version: 1.8.0 - resolution: "convert-source-map@npm:1.8.0" - dependencies: - safe-buffer: ~5.1.1 - checksum: 985d974a2d33e1a2543ada51c93e1ba2f73eaed608dc39f229afc78f71dcc4c8b7d7c684aa647e3c6a3a204027444d69e53e169ce94e8d1fa8d7dee80c9c8fed - languageName: node - linkType: hard - -"create-require@npm:^1.1.0": - version: 1.1.1 - resolution: "create-require@npm:1.1.1" - checksum: a9a1503d4390d8b59ad86f4607de7870b39cad43d929813599a23714831e81c520bddf61bcdd1f8e30f05fd3a2b71ae8538e946eb2786dc65c2bbc520f692eff - languageName: node - linkType: hard - -"cross-spawn@npm:^7.0.0, cross-spawn@npm:^7.0.2": - version: 7.0.3 - resolution: "cross-spawn@npm:7.0.3" - dependencies: - path-key: ^3.1.0 - shebang-command: ^2.0.0 - which: ^2.0.1 - checksum: 671cc7c7288c3a8406f3c69a3ae2fc85555c04169e9d611def9a675635472614f1c0ed0ef80955d5b6d4e724f6ced67f0ad1bb006c2ea643488fcfef994d7f52 - languageName: node - linkType: hard - -"debug@npm:4, debug@npm:4.3.3, debug@npm:^4.1.0, debug@npm:^4.1.1, debug@npm:^4.3.1, debug@npm:^4.3.2": - version: 4.3.3 - resolution: "debug@npm:4.3.3" - dependencies: - ms: 2.1.2 - peerDependenciesMeta: - supports-color: - optional: true - checksum: 14472d56fe4a94dbcfaa6dbed2dd3849f1d72ba78104a1a328047bb564643ca49df0224c3a17fa63533fd11dd3d4c8636cd861191232a2c6735af00cc2d4de16 - languageName: node - linkType: hard - -"decamelize@npm:^1.2.0": - version: 1.2.0 - resolution: "decamelize@npm:1.2.0" - checksum: ad8c51a7e7e0720c70ec2eeb1163b66da03e7616d7b98c9ef43cce2416395e84c1e9548dd94f5f6ffecfee9f8b94251fc57121a8b021f2ff2469b2bae247b8aa - languageName: node - linkType: hard - -"decamelize@npm:^4.0.0": - version: 4.0.0 - resolution: "decamelize@npm:4.0.0" - checksum: b7d09b82652c39eead4d6678bb578e3bebd848add894b76d0f6b395bc45b2d692fb88d977e7cfb93c4ed6c119b05a1347cef261174916c2e75c0a8ca57da1809 - languageName: node - linkType: hard - -"deep-is@npm:^0.1.3": - version: 0.1.4 - resolution: "deep-is@npm:0.1.4" - checksum: edb65dd0d7d1b9c40b2f50219aef30e116cedd6fc79290e740972c132c09106d2e80aa0bc8826673dd5a00222d4179c84b36a790eef63a4c4bca75a37ef90804 - languageName: node - linkType: hard - -"default-require-extensions@npm:^3.0.0": - version: 3.0.0 - resolution: "default-require-extensions@npm:3.0.0" - dependencies: - strip-bom: ^4.0.0 - checksum: 0b5bdb6786ebb0ff6ef55386f37c8d221963fbbd3009588fe71032c85ca16da05eff2ad01bfe9bfc8bac5ce95a18f66b38c50d454482e3e9d2de1142424a3e7c - languageName: node - linkType: hard - -"delegates@npm:^1.0.0": - version: 1.0.0 - resolution: "delegates@npm:1.0.0" - checksum: a51744d9b53c164ba9c0492471a1a2ffa0b6727451bdc89e31627fdf4adda9d51277cfcbfb20f0a6f08ccb3c436f341df3e92631a3440226d93a8971724771fd - languageName: node - linkType: hard - -"depd@npm:^1.1.2": - version: 1.1.2 - resolution: "depd@npm:1.1.2" - checksum: 6b406620d269619852885ce15965272b829df6f409724415e0002c8632ab6a8c0a08ec1f0bd2add05dc7bd7507606f7e2cc034fa24224ab829580040b835ecd9 - languageName: node - linkType: hard - -"diff@npm:5.0.0": - version: 5.0.0 - resolution: "diff@npm:5.0.0" - checksum: f19fe29284b633afdb2725c2a8bb7d25761ea54d321d8e67987ac851c5294be4afeab532bd84531e02583a3fe7f4014aa314a3eda84f5590e7a9e6b371ef3b46 - languageName: node - linkType: hard - -"diff@npm:^3.5.0": - version: 3.5.0 - resolution: "diff@npm:3.5.0" - checksum: 00842950a6551e26ce495bdbce11047e31667deea546527902661f25cc2e73358967ebc78cf86b1a9736ec3e14286433225f9970678155753a6291c3bca5227b - languageName: node - linkType: hard - -"diff@npm:^4.0.1": - version: 4.0.2 - resolution: "diff@npm:4.0.2" - checksum: f2c09b0ce4e6b301c221addd83bf3f454c0bc00caa3dd837cf6c127d6edf7223aa2bbe3b688feea110b7f262adbfc845b757c44c8a9f8c0c5b15d8fa9ce9d20d - languageName: node - linkType: hard - -"dir-glob@npm:^3.0.1": - version: 3.0.1 - resolution: "dir-glob@npm:3.0.1" - dependencies: - path-type: ^4.0.0 - checksum: fa05e18324510d7283f55862f3161c6759a3f2f8dbce491a2fc14c8324c498286c54282c1f0e933cb930da8419b30679389499b919122952a4f8592362ef4615 - languageName: node - linkType: hard - -"doctrine@npm:^3.0.0": - version: 3.0.0 - resolution: "doctrine@npm:3.0.0" - dependencies: - esutils: ^2.0.2 - checksum: fd7673ca77fe26cd5cba38d816bc72d641f500f1f9b25b83e8ce28827fe2da7ad583a8da26ab6af85f834138cf8dae9f69b0cd6ab925f52ddab1754db44d99ce - languageName: node - linkType: hard - -"electron-to-chromium@npm:^1.4.17": - version: 1.4.51 - resolution: "electron-to-chromium@npm:1.4.51" - checksum: dad1fd5faad1eed0206951429290ff0343eebfcabc201600dc0aeda7a2de07e0db697728fcd0b9e14f9c5f8cd5ec4841acda3179c5b2f8cdea09a5e81c634313 - languageName: node - linkType: hard - -"emoji-regex@npm:^8.0.0": - version: 8.0.0 - resolution: "emoji-regex@npm:8.0.0" - checksum: d4c5c39d5a9868b5fa152f00cada8a936868fd3367f33f71be515ecee4c803132d11b31a6222b2571b1e5f7e13890156a94880345594d0ce7e3c9895f560f192 - languageName: node - linkType: hard - -"encoding@npm:^0.1.12": - version: 0.1.13 - resolution: "encoding@npm:0.1.13" - dependencies: - iconv-lite: ^0.6.2 - checksum: bb98632f8ffa823996e508ce6a58ffcf5856330fde839ae42c9e1f436cc3b5cc651d4aeae72222916545428e54fd0f6aa8862fd8d25bdbcc4589f1e3f3715e7f - languageName: node - linkType: hard - -"env-paths@npm:^2.2.0": - version: 2.2.1 - resolution: "env-paths@npm:2.2.1" - checksum: 65b5df55a8bab92229ab2b40dad3b387fad24613263d103a97f91c9fe43ceb21965cd3392b1ccb5d77088021e525c4e0481adb309625d0cb94ade1d1fb8dc17e - languageName: node - linkType: hard - -"err-code@npm:^2.0.2": - version: 2.0.3 - resolution: "err-code@npm:2.0.3" - checksum: 8b7b1be20d2de12d2255c0bc2ca638b7af5171142693299416e6a9339bd7d88fc8d7707d913d78e0993176005405a236b066b45666b27b797252c771156ace54 - languageName: node - linkType: hard - -"es6-error@npm:^4.0.1": - version: 4.1.1 - resolution: "es6-error@npm:4.1.1" - checksum: ae41332a51ec1323da6bbc5d75b7803ccdeddfae17c41b6166ebbafc8e8beb7a7b80b884b7fab1cc80df485860ac3c59d78605e860bb4f8cd816b3d6ade0d010 - languageName: node - linkType: hard - -"escalade@npm:^3.1.1": - version: 3.1.1 - resolution: "escalade@npm:3.1.1" - checksum: a3e2a99f07acb74b3ad4989c48ca0c3140f69f923e56d0cba0526240ee470b91010f9d39001f2a4a313841d237ede70a729e92125191ba5d21e74b106800b133 - languageName: node - linkType: hard - -"escape-string-regexp@npm:4.0.0, escape-string-regexp@npm:^4.0.0": - version: 4.0.0 - resolution: "escape-string-regexp@npm:4.0.0" - checksum: 98b48897d93060f2322108bf29db0feba7dd774be96cd069458d1453347b25ce8682ecc39859d4bca2203cc0ab19c237bcc71755eff49a0f8d90beadeeba5cc5 - languageName: node - linkType: hard - -"escape-string-regexp@npm:^1.0.5": - version: 1.0.5 - resolution: "escape-string-regexp@npm:1.0.5" - checksum: 6092fda75c63b110c706b6a9bfde8a612ad595b628f0bd2147eea1d3406723020810e591effc7db1da91d80a71a737a313567c5abb3813e8d9c71f4aa595b410 - languageName: node - linkType: hard - -"eslint-config-prettier@npm:^8.3.0": - version: 8.3.0 - resolution: "eslint-config-prettier@npm:8.3.0" - peerDependencies: - eslint: ">=7.0.0" - bin: - eslint-config-prettier: bin/cli.js - checksum: df4cea3032671995bb5ab07e016169072f7fa59f44a53251664d9ca60951b66cdc872683b5c6a3729c91497c11490ca44a79654b395dd6756beb0c3903a37196 - languageName: node - linkType: hard - -"eslint-scope@npm:^5.1.1": - version: 5.1.1 - resolution: "eslint-scope@npm:5.1.1" - dependencies: - esrecurse: ^4.3.0 - estraverse: ^4.1.1 - checksum: 47e4b6a3f0cc29c7feedee6c67b225a2da7e155802c6ea13bbef4ac6b9e10c66cd2dcb987867ef176292bf4e64eccc680a49e35e9e9c669f4a02bac17e86abdb - languageName: node - linkType: hard - -"eslint-scope@npm:^7.1.0": - version: 7.1.0 - resolution: "eslint-scope@npm:7.1.0" - dependencies: - esrecurse: ^4.3.0 - estraverse: ^5.2.0 - checksum: 2070470a0725438ed47075b2574a4c03cf59aa32648da8cff9e3548c84f6b0079cfdb9ee1dd7ab0bfe97011f64b2af5bfd4b69cf14a1292130dec661eec7914a - languageName: node - linkType: hard - -"eslint-utils@npm:^3.0.0": - version: 3.0.0 - resolution: "eslint-utils@npm:3.0.0" - dependencies: - eslint-visitor-keys: ^2.0.0 - peerDependencies: - eslint: ">=5" - checksum: 0668fe02f5adab2e5a367eee5089f4c39033af20499df88fe4e6aba2015c20720404d8c3d6349b6f716b08fdf91b9da4e5d5481f265049278099c4c836ccb619 - languageName: node - linkType: hard - -"eslint-visitor-keys@npm:^2.0.0": - version: 2.1.0 - resolution: "eslint-visitor-keys@npm:2.1.0" - checksum: e3081d7dd2611a35f0388bbdc2f5da60b3a3c5b8b6e928daffff7391146b434d691577aa95064c8b7faad0b8a680266bcda0a42439c18c717b80e6718d7e267d - languageName: node - linkType: hard - -"eslint-visitor-keys@npm:^3.0.0, eslint-visitor-keys@npm:^3.1.0, eslint-visitor-keys@npm:^3.2.0": - version: 3.2.0 - resolution: "eslint-visitor-keys@npm:3.2.0" - checksum: fdadbb26f9e6417d3db7ad4f00bb0d573b6031c32fa72e8cdae32d038223faaeddff2ee443c90cb489bf774e75bff765c00912b8f9106d65e4f202ccd78c1b18 - languageName: node - linkType: hard - -"eslint@npm:^8.2.0": - version: 8.7.0 - resolution: "eslint@npm:8.7.0" - dependencies: - "@eslint/eslintrc": ^1.0.5 - "@humanwhocodes/config-array": ^0.9.2 - ajv: ^6.10.0 - chalk: ^4.0.0 - cross-spawn: ^7.0.2 - debug: ^4.3.2 - doctrine: ^3.0.0 - escape-string-regexp: ^4.0.0 - eslint-scope: ^7.1.0 - eslint-utils: ^3.0.0 - eslint-visitor-keys: ^3.2.0 - espree: ^9.3.0 - esquery: ^1.4.0 - esutils: ^2.0.2 - fast-deep-equal: ^3.1.3 - file-entry-cache: ^6.0.1 - functional-red-black-tree: ^1.0.1 - glob-parent: ^6.0.1 - globals: ^13.6.0 - ignore: ^5.2.0 - import-fresh: ^3.0.0 - imurmurhash: ^0.1.4 - is-glob: ^4.0.0 - js-yaml: ^4.1.0 - json-stable-stringify-without-jsonify: ^1.0.1 - levn: ^0.4.1 - lodash.merge: ^4.6.2 - minimatch: ^3.0.4 - natural-compare: ^1.4.0 - optionator: ^0.9.1 - regexpp: ^3.2.0 - strip-ansi: ^6.0.1 - strip-json-comments: ^3.1.0 - text-table: ^0.2.0 - v8-compile-cache: ^2.0.3 - bin: - eslint: bin/eslint.js - checksum: 1c80375a48b0fe3ccae3c6354323e4f0e92e970f23abc5b9705b90b7aef514b69ebd0a63e74962d30789986c91fa41c0e25cd2f98f19e9e2a2d36aafdfc9ccc9 - languageName: node - linkType: hard - -"espree@npm:^9.2.0, espree@npm:^9.3.0": - version: 9.3.0 - resolution: "espree@npm:9.3.0" - dependencies: - acorn: ^8.7.0 - acorn-jsx: ^5.3.1 - eslint-visitor-keys: ^3.1.0 - checksum: c0f1885c4eab652f9be08eb9228cea0df046b559b29d4aed8d6590ea9bd60177d4cb245d204a6f737a79a096861bb4ab8e480aeb8c1dbafef5beec1157353ce4 - languageName: node - linkType: hard - -"esprima@npm:^4.0.0": - version: 4.0.1 - resolution: "esprima@npm:4.0.1" - bin: - esparse: ./bin/esparse.js - esvalidate: ./bin/esvalidate.js - checksum: b45bc805a613dbea2835278c306b91aff6173c8d034223fa81498c77dcbce3b2931bf6006db816f62eacd9fd4ea975dfd85a5b7f3c6402cfd050d4ca3c13a628 - languageName: node - linkType: hard - -"esquery@npm:^1.4.0": - version: 1.4.0 - resolution: "esquery@npm:1.4.0" - dependencies: - estraverse: ^5.1.0 - checksum: a0807e17abd7fbe5fbd4fab673038d6d8a50675cdae6b04fbaa520c34581be0c5fa24582990e8acd8854f671dd291c78bb2efb9e0ed5b62f33bac4f9cf820210 - languageName: node - linkType: hard - -"esrecurse@npm:^4.3.0": - version: 4.3.0 - resolution: "esrecurse@npm:4.3.0" - dependencies: - estraverse: ^5.2.0 - checksum: ebc17b1a33c51cef46fdc28b958994b1dc43cd2e86237515cbc3b4e5d2be6a811b2315d0a1a4d9d340b6d2308b15322f5c8291059521cc5f4802f65e7ec32837 - languageName: node - linkType: hard - -"estraverse@npm:^4.1.1": - version: 4.3.0 - resolution: "estraverse@npm:4.3.0" - checksum: a6299491f9940bb246124a8d44b7b7a413a8336f5436f9837aaa9330209bd9ee8af7e91a654a3545aee9c54b3308e78ee360cef1d777d37cfef77d2fa33b5827 - languageName: node - linkType: hard - -"estraverse@npm:^5.1.0, estraverse@npm:^5.2.0": - version: 5.3.0 - resolution: "estraverse@npm:5.3.0" - checksum: 072780882dc8416ad144f8fe199628d2b3e7bbc9989d9ed43795d2c90309a2047e6bc5979d7e2322a341163d22cfad9e21f4110597fe487519697389497e4e2b - languageName: node - linkType: hard - -"esutils@npm:^2.0.2": - version: 2.0.3 - resolution: "esutils@npm:2.0.3" - checksum: 22b5b08f74737379a840b8ed2036a5fb35826c709ab000683b092d9054e5c2a82c27818f12604bfc2a9a76b90b6834ef081edbc1c7ae30d1627012e067c6ec87 - languageName: node - linkType: hard - -"fast-deep-equal@npm:^3.1.1, fast-deep-equal@npm:^3.1.3": - version: 3.1.3 - resolution: "fast-deep-equal@npm:3.1.3" - checksum: e21a9d8d84f53493b6aa15efc9cfd53dd5b714a1f23f67fb5dc8f574af80df889b3bce25dc081887c6d25457cce704e636395333abad896ccdec03abaf1f3f9d - languageName: node - linkType: hard - -"fast-glob@npm:^3.2.9": - version: 3.2.11 - resolution: "fast-glob@npm:3.2.11" - dependencies: - "@nodelib/fs.stat": ^2.0.2 - "@nodelib/fs.walk": ^1.2.3 - glob-parent: ^5.1.2 - merge2: ^1.3.0 - micromatch: ^4.0.4 - checksum: f473105324a7780a20c06de842e15ddbb41d3cb7e71d1e4fe6e8373204f22245d54f5ab9e2061e6a1c613047345954d29b022e0e76f5c28b1df9858179a0e6d7 - languageName: node - linkType: hard - -"fast-json-stable-stringify@npm:^2.0.0": - version: 2.1.0 - resolution: "fast-json-stable-stringify@npm:2.1.0" - checksum: b191531e36c607977e5b1c47811158733c34ccb3bfde92c44798929e9b4154884378536d26ad90dfecd32e1ffc09c545d23535ad91b3161a27ddbb8ebe0cbecb - languageName: node - linkType: hard - -"fast-levenshtein@npm:^2.0.6": - version: 2.0.6 - resolution: "fast-levenshtein@npm:2.0.6" - checksum: 92cfec0a8dfafd9c7a15fba8f2cc29cd0b62b85f056d99ce448bbcd9f708e18ab2764bda4dd5158364f4145a7c72788538994f0d1787b956ef0d1062b0f7c24c - languageName: node - linkType: hard - -"fastq@npm:^1.6.0": - version: 1.13.0 - resolution: "fastq@npm:1.13.0" - dependencies: - reusify: ^1.0.4 - checksum: 32cf15c29afe622af187d12fc9cd93e160a0cb7c31a3bb6ace86b7dea3b28e7b72acde89c882663f307b2184e14782c6c664fa315973c03626c7d4bff070bb0b - languageName: node - linkType: hard - -"file-entry-cache@npm:^6.0.1": - version: 6.0.1 - resolution: "file-entry-cache@npm:6.0.1" - dependencies: - flat-cache: ^3.0.4 - checksum: f49701feaa6314c8127c3c2f6173cfefff17612f5ed2daaafc6da13b5c91fd43e3b2a58fd0d63f9f94478a501b167615931e7200e31485e320f74a33885a9c74 - languageName: node - linkType: hard - -"fill-range@npm:^7.0.1": - version: 7.0.1 - resolution: "fill-range@npm:7.0.1" - dependencies: - to-regex-range: ^5.0.1 - checksum: cc283f4e65b504259e64fd969bcf4def4eb08d85565e906b7d36516e87819db52029a76b6363d0f02d0d532f0033c9603b9e2d943d56ee3b0d4f7ad3328ff917 - languageName: node - linkType: hard - -"find-cache-dir@npm:^3.2.0": - version: 3.3.2 - resolution: "find-cache-dir@npm:3.3.2" - dependencies: - commondir: ^1.0.1 - make-dir: ^3.0.2 - pkg-dir: ^4.1.0 - checksum: 1e61c2e64f5c0b1c535bd85939ae73b0e5773142713273818cc0b393ee3555fb0fd44e1a5b161b8b6c3e03e98c2fcc9c227d784850a13a90a8ab576869576817 - languageName: node - linkType: hard - -"find-up@npm:5.0.0": - version: 5.0.0 - resolution: "find-up@npm:5.0.0" - dependencies: - locate-path: ^6.0.0 - path-exists: ^4.0.0 - checksum: 07955e357348f34660bde7920783204ff5a26ac2cafcaa28bace494027158a97b9f56faaf2d89a6106211a8174db650dd9f503f9c0d526b1202d5554a00b9095 - languageName: node - linkType: hard - -"find-up@npm:^4.0.0, find-up@npm:^4.1.0": - version: 4.1.0 - resolution: "find-up@npm:4.1.0" - dependencies: - locate-path: ^5.0.0 - path-exists: ^4.0.0 - checksum: 4c172680e8f8c1f78839486e14a43ef82e9decd0e74145f40707cc42e7420506d5ec92d9a11c22bd2c48fb0c384ea05dd30e10dd152fefeec6f2f75282a8b844 - languageName: node - linkType: hard - -"flat-cache@npm:^3.0.4": - version: 3.0.4 - resolution: "flat-cache@npm:3.0.4" - dependencies: - flatted: ^3.1.0 - rimraf: ^3.0.2 - checksum: 4fdd10ecbcbf7d520f9040dd1340eb5dfe951e6f0ecf2252edeec03ee68d989ec8b9a20f4434270e71bcfd57800dc09b3344fca3966b2eb8f613072c7d9a2365 - languageName: node - linkType: hard - -"flat@npm:^5.0.2": - version: 5.0.2 - resolution: "flat@npm:5.0.2" - bin: - flat: cli.js - checksum: 12a1536ac746db74881316a181499a78ef953632ddd28050b7a3a43c62ef5462e3357c8c29d76072bb635f147f7a9a1f0c02efef6b4be28f8db62ceb3d5c7f5d - languageName: node - linkType: hard - -"flatted@npm:^3.1.0": - version: 3.2.4 - resolution: "flatted@npm:3.2.4" - checksum: 7d33846428ab337ec81ef9b8b9103894c1c81f5f67feb32bd4ed106fbc47da60d56edb42efd36c9f1f30a010272aeccd34ec1ffacfe9dfdff19673b1d4df481b - languageName: node - linkType: hard - -"follow-redirects@npm:^1.14.4": - version: 1.14.7 - resolution: "follow-redirects@npm:1.14.7" - peerDependenciesMeta: - debug: - optional: true - checksum: f6d03e5e30877431065bca0d1b2e3db93949eb799d368a5c07ea8a4b71205f0349a3f8f0191bf13a07c93885522834dca1dc8e527dc99a772c6911fba24edc5f - languageName: node - linkType: hard - -"foreground-child@npm:^2.0.0": - version: 2.0.0 - resolution: "foreground-child@npm:2.0.0" - dependencies: - cross-spawn: ^7.0.0 - signal-exit: ^3.0.2 - checksum: f77ec9aff621abd6b754cb59e690743e7639328301fbea6ff09df27d2befaf7dd5b77cec51c32323d73a81a7d91caaf9413990d305cbe3d873eec4fe58960956 - languageName: node - linkType: hard - -"fromentries@npm:^1.2.0": - version: 1.3.2 - resolution: "fromentries@npm:1.3.2" - checksum: 33729c529ce19f5494f846f0dd4945078f4e37f4e8955f4ae8cc7385c218f600e9d93a7d225d17636c20d1889106fd87061f911550861b7072f53bf891e6b341 - languageName: node - linkType: hard - -"fs-minipass@npm:^2.0.0": - version: 2.1.0 - resolution: "fs-minipass@npm:2.1.0" - dependencies: - minipass: ^3.0.0 - checksum: 1b8d128dae2ac6cc94230cc5ead341ba3e0efaef82dab46a33d171c044caaa6ca001364178d42069b2809c35a1c3c35079a32107c770e9ffab3901b59af8c8b1 - languageName: node - linkType: hard - -"fs.realpath@npm:^1.0.0": - version: 1.0.0 - resolution: "fs.realpath@npm:1.0.0" - checksum: 99ddea01a7e75aa276c250a04eedeffe5662bce66c65c07164ad6264f9de18fb21be9433ead460e54cff20e31721c811f4fb5d70591799df5f85dce6d6746fd0 - languageName: node - linkType: hard - -"fsevents@npm:~2.3.2": - version: 2.3.2 - resolution: "fsevents@npm:2.3.2" - dependencies: - node-gyp: latest - checksum: 97ade64e75091afee5265e6956cb72ba34db7819b4c3e94c431d4be2b19b8bb7a2d4116da417950c3425f17c8fe693d25e20212cac583ac1521ad066b77ae31f - conditions: os=darwin - languageName: node - linkType: hard - -"fsevents@patch:fsevents@~2.3.2#~builtin": - version: 2.3.2 - resolution: "fsevents@patch:fsevents@npm%3A2.3.2#~builtin::version=2.3.2&hash=18f3a7" - dependencies: - node-gyp: latest - conditions: os=darwin - languageName: node - linkType: hard - -"functional-red-black-tree@npm:^1.0.1": - version: 1.0.1 - resolution: "functional-red-black-tree@npm:1.0.1" - checksum: ca6c170f37640e2d94297da8bb4bf27a1d12bea3e00e6a3e007fd7aa32e37e000f5772acf941b4e4f3cf1c95c3752033d0c509af157ad8f526e7f00723b9eb9f - languageName: node - linkType: hard - -"gauge@npm:^4.0.0": - version: 4.0.0 - resolution: "gauge@npm:4.0.0" - dependencies: - ansi-regex: ^5.0.1 - aproba: ^1.0.3 || ^2.0.0 - color-support: ^1.1.2 - console-control-strings: ^1.0.0 - has-unicode: ^2.0.1 - signal-exit: ^3.0.0 - string-width: ^4.2.3 - strip-ansi: ^6.0.1 - wide-align: ^1.1.2 - checksum: 637b34c84f518defa89319dbef68211a24e9302182ad2a619e3be1be5b7dcf2a962c8359e889294af667440f4722e7e6e61671859e00bd8ec280a136ded89b25 - languageName: node - linkType: hard - -"gensync@npm:^1.0.0-beta.2": - version: 1.0.0-beta.2 - resolution: "gensync@npm:1.0.0-beta.2" - checksum: a7437e58c6be12aa6c90f7730eac7fa9833dc78872b4ad2963d2031b00a3367a93f98aec75f9aaac7220848e4026d67a8655e870b24f20a543d103c0d65952ec - languageName: node - linkType: hard - -"get-caller-file@npm:^2.0.1, get-caller-file@npm:^2.0.5": - version: 2.0.5 - resolution: "get-caller-file@npm:2.0.5" - checksum: b9769a836d2a98c3ee734a88ba712e62703f1df31b94b784762c433c27a386dd6029ff55c2a920c392e33657d80191edbf18c61487e198844844516f843496b9 - languageName: node - linkType: hard - -"get-package-type@npm:^0.1.0": - version: 0.1.0 - resolution: "get-package-type@npm:0.1.0" - checksum: bba0811116d11e56d702682ddef7c73ba3481f114590e705fc549f4d868972263896af313c57a25c076e3c0d567e11d919a64ba1b30c879be985fc9d44f96148 - languageName: node - linkType: hard - -"glob-parent@npm:^5.1.2, glob-parent@npm:~5.1.2": - version: 5.1.2 - resolution: "glob-parent@npm:5.1.2" - dependencies: - is-glob: ^4.0.1 - checksum: f4f2bfe2425296e8a47e36864e4f42be38a996db40420fe434565e4480e3322f18eb37589617a98640c5dc8fdec1a387007ee18dbb1f3f5553409c34d17f425e - languageName: node - linkType: hard - -"glob-parent@npm:^6.0.1": - version: 6.0.2 - resolution: "glob-parent@npm:6.0.2" - dependencies: - is-glob: ^4.0.3 - checksum: c13ee97978bef4f55106b71e66428eb1512e71a7466ba49025fc2aec59a5bfb0954d5abd58fc5ee6c9b076eef4e1f6d3375c2e964b88466ca390da4419a786a8 - languageName: node - linkType: hard - -"glob@npm:7.2.0, glob@npm:^7.1.3, glob@npm:^7.1.4, glob@npm:^7.1.6": - version: 7.2.0 - resolution: "glob@npm:7.2.0" - dependencies: - fs.realpath: ^1.0.0 - inflight: ^1.0.4 - inherits: 2 - minimatch: ^3.0.4 - once: ^1.3.0 - path-is-absolute: ^1.0.0 - checksum: 78a8ea942331f08ed2e055cb5b9e40fe6f46f579d7fd3d694f3412fe5db23223d29b7fee1575440202e9a7ff9a72ab106a39fee39934c7bedafe5e5f8ae20134 - languageName: node - linkType: hard - -"globals@npm:^11.1.0": - version: 11.12.0 - resolution: "globals@npm:11.12.0" - checksum: 67051a45eca3db904aee189dfc7cd53c20c7d881679c93f6146ddd4c9f4ab2268e68a919df740d39c71f4445d2b38ee360fc234428baea1dbdfe68bbcb46979e - languageName: node - linkType: hard - -"globals@npm:^13.6.0, globals@npm:^13.9.0": - version: 13.12.0 - resolution: "globals@npm:13.12.0" - dependencies: - type-fest: ^0.20.2 - checksum: 1f959abb11117916468a1afcba527eead152900cad652c8383c4e8976daea7ec55e1ee30c086f48d1b8655719f214e9d92eca083c3a43b5543bc4056e7e5fccf - languageName: node - linkType: hard - -"globby@npm:^11.0.4": - version: 11.1.0 - resolution: "globby@npm:11.1.0" - dependencies: - array-union: ^2.1.0 - dir-glob: ^3.0.1 - fast-glob: ^3.2.9 - ignore: ^5.2.0 - merge2: ^1.4.1 - slash: ^3.0.0 - checksum: b4be8885e0cfa018fc783792942d53926c35c50b3aefd3fdcfb9d22c627639dc26bd2327a40a0b74b074100ce95bb7187bfeae2f236856aa3de183af7a02aea6 - languageName: node - linkType: hard - -"graceful-fs@npm:^4.1.15, graceful-fs@npm:^4.2.6": - version: 4.2.9 - resolution: "graceful-fs@npm:4.2.9" - checksum: 68ea4e07ff2c041ada184f9278b830375f8e0b75154e3f080af6b70f66172fabb4108d19b3863a96b53fc068a310b9b6493d86d1291acc5f3861eb4b79d26ad6 - languageName: node - linkType: hard - -"growl@npm:1.10.5": - version: 1.10.5 - resolution: "growl@npm:1.10.5" - checksum: 4b86685de6831cebcbb19f93870bea624afee61124b0a20c49017013987cd129e73a8c4baeca295728f41d21265e1f859d25ef36731b142ca59c655fea94bb1a - languageName: node - linkType: hard - -"has-flag@npm:^3.0.0": - version: 3.0.0 - resolution: "has-flag@npm:3.0.0" - checksum: 4a15638b454bf086c8148979aae044dd6e39d63904cd452d970374fa6a87623423da485dfb814e7be882e05c096a7ccf1ebd48e7e7501d0208d8384ff4dea73b - languageName: node - linkType: hard - -"has-flag@npm:^4.0.0": - version: 4.0.0 - resolution: "has-flag@npm:4.0.0" - checksum: 261a1357037ead75e338156b1f9452c016a37dcd3283a972a30d9e4a87441ba372c8b81f818cd0fbcd9c0354b4ae7e18b9e1afa1971164aef6d18c2b6095a8ad - languageName: node - linkType: hard - -"has-unicode@npm:^2.0.1": - version: 2.0.1 - resolution: "has-unicode@npm:2.0.1" - checksum: 1eab07a7436512db0be40a710b29b5dc21fa04880b7f63c9980b706683127e3c1b57cb80ea96d47991bdae2dfe479604f6a1ba410106ee1046a41d1bd0814400 - languageName: node - linkType: hard - -"hasha@npm:^5.0.0": - version: 5.2.2 - resolution: "hasha@npm:5.2.2" - dependencies: - is-stream: ^2.0.0 - type-fest: ^0.8.0 - checksum: 06cc474bed246761ff61c19d629977eb5f53fa817be4313a255a64ae0f433e831a29e83acb6555e3f4592b348497596f1d1653751008dda4f21c9c21ca60ac5a - languageName: node - linkType: hard - -"he@npm:1.2.0": - version: 1.2.0 - resolution: "he@npm:1.2.0" - bin: - he: bin/he - checksum: 3d4d6babccccd79c5c5a3f929a68af33360d6445587d628087f39a965079d84f18ce9c3d3f917ee1e3978916fc833bb8b29377c3b403f919426f91bc6965e7a7 - languageName: node - linkType: hard - -"html-escaper@npm:^2.0.0": - version: 2.0.2 - resolution: "html-escaper@npm:2.0.2" - checksum: d2df2da3ad40ca9ee3a39c5cc6475ef67c8f83c234475f24d8e9ce0dc80a2c82df8e1d6fa78ddd1e9022a586ea1bd247a615e80a5cd9273d90111ddda7d9e974 - languageName: node - linkType: hard - -"htmlencode@npm:^0.0.4": - version: 0.0.4 - resolution: "htmlencode@npm:0.0.4" - checksum: b5c5a280213569f59807d22ae2d68c77360f6337b6936cdfa4e2aeaa12e3a69bb36b426ad18ed9333a7fb3f7d55c14ea3b46040d3271af7a586f262aaf4092ad - languageName: node - linkType: hard - -"http-cache-semantics@npm:^4.1.0": - version: 4.1.0 - resolution: "http-cache-semantics@npm:4.1.0" - checksum: 974de94a81c5474be07f269f9fd8383e92ebb5a448208223bfb39e172a9dbc26feff250192ecc23b9593b3f92098e010406b0f24bd4d588d631f80214648ed42 - languageName: node - linkType: hard - -"http-proxy-agent@npm:^4.0.1": - version: 4.0.1 - resolution: "http-proxy-agent@npm:4.0.1" - dependencies: - "@tootallnate/once": 1 - agent-base: 6 - debug: 4 - checksum: c6a5da5a1929416b6bbdf77b1aca13888013fe7eb9d59fc292e25d18e041bb154a8dfada58e223fc7b76b9b2d155a87e92e608235201f77d34aa258707963a82 - languageName: node - linkType: hard - -"https-proxy-agent@npm:^5.0.0": - version: 5.0.0 - resolution: "https-proxy-agent@npm:5.0.0" - dependencies: - agent-base: 6 - debug: 4 - checksum: 165bfb090bd26d47693597661298006841ab733d0c7383a8cb2f17373387a94c903a3ac687090aa739de05e379ab6f868bae84ab4eac288ad85c328cd1ec9e53 - languageName: node - linkType: hard - -"humanize-ms@npm:^1.2.1": - version: 1.2.1 - resolution: "humanize-ms@npm:1.2.1" - dependencies: - ms: ^2.0.0 - checksum: 9c7a74a2827f9294c009266c82031030eae811ca87b0da3dceb8d6071b9bde22c9f3daef0469c3c533cc67a97d8a167cd9fc0389350e5f415f61a79b171ded16 - languageName: node - linkType: hard - -"iconv-lite@npm:^0.6.2": - version: 0.6.3 - resolution: "iconv-lite@npm:0.6.3" - dependencies: - safer-buffer: ">= 2.1.2 < 3.0.0" - checksum: 3f60d47a5c8fc3313317edfd29a00a692cc87a19cac0159e2ce711d0ebc9019064108323b5e493625e25594f11c6236647d8e256fbe7a58f4a3b33b89e6d30bf - languageName: node - linkType: hard - -"ignore@npm:^4.0.6": - version: 4.0.6 - resolution: "ignore@npm:4.0.6" - checksum: 248f82e50a430906f9ee7f35e1158e3ec4c3971451dd9f99c9bc1548261b4db2b99709f60ac6c6cac9333494384176cc4cc9b07acbe42d52ac6a09cad734d800 - languageName: node - linkType: hard - -"ignore@npm:^5.1.8, ignore@npm:^5.2.0": - version: 5.2.0 - resolution: "ignore@npm:5.2.0" - checksum: 6b1f926792d614f64c6c83da3a1f9c83f6196c2839aa41e1e32dd7b8d174cef2e329d75caabb62cb61ce9dc432f75e67d07d122a037312db7caa73166a1bdb77 - languageName: node - linkType: hard - -"import-fresh@npm:^3.0.0, import-fresh@npm:^3.2.1": - version: 3.3.0 - resolution: "import-fresh@npm:3.3.0" - dependencies: - parent-module: ^1.0.0 - resolve-from: ^4.0.0 - checksum: 2cacfad06e652b1edc50be650f7ec3be08c5e5a6f6d12d035c440a42a8cc028e60a5b99ca08a77ab4d6b1346da7d971915828f33cdab730d3d42f08242d09baa - languageName: node - linkType: hard - -"imurmurhash@npm:^0.1.4": - version: 0.1.4 - resolution: "imurmurhash@npm:0.1.4" - checksum: 7cae75c8cd9a50f57dadd77482359f659eaebac0319dd9368bcd1714f55e65badd6929ca58569da2b6494ef13fdd5598cd700b1eba23f8b79c5f19d195a3ecf7 - languageName: node - linkType: hard - -"indent-string@npm:^4.0.0": - version: 4.0.0 - resolution: "indent-string@npm:4.0.0" - checksum: 824cfb9929d031dabf059bebfe08cf3137365e112019086ed3dcff6a0a7b698cb80cf67ccccde0e25b9e2d7527aa6cc1fed1ac490c752162496caba3e6699612 - languageName: node - linkType: hard - -"infer-owner@npm:^1.0.4": - version: 1.0.4 - resolution: "infer-owner@npm:1.0.4" - checksum: 181e732764e4a0611576466b4b87dac338972b839920b2a8cde43642e4ed6bd54dc1fb0b40874728f2a2df9a1b097b8ff83b56d5f8f8e3927f837fdcb47d8a89 - languageName: node - linkType: hard - -"inflight@npm:^1.0.4": - version: 1.0.6 - resolution: "inflight@npm:1.0.6" - dependencies: - once: ^1.3.0 - wrappy: 1 - checksum: f4f76aa072ce19fae87ce1ef7d221e709afb59d445e05d47fba710e85470923a75de35bfae47da6de1b18afc3ce83d70facf44cfb0aff89f0a3f45c0a0244dfd - languageName: node - linkType: hard - -"inherits@npm:2, inherits@npm:^2.0.3": - version: 2.0.4 - resolution: "inherits@npm:2.0.4" - checksum: 4a48a733847879d6cf6691860a6b1e3f0f4754176e4d71494c41f3475553768b10f84b5ce1d40fbd0e34e6bfbb864ee35858ad4dd2cf31e02fc4a154b724d7f1 - languageName: node - linkType: hard - -"intercom-client@workspace:.": - version: 0.0.0-use.local - resolution: "intercom-client@workspace:." - dependencies: - "@istanbuljs/nyc-config-typescript": ^1.0.2 - "@types/lodash": ^4.14.176 - "@types/mocha": ^9.1.0 - "@types/node": ^16.11.6 - "@types/sinon": ^10.0.6 - "@typescript-eslint/eslint-plugin": ^5.7.0 - "@typescript-eslint/parser": ^5.7.0 - axios: ^0.24.0 - eslint: ^8.2.0 - eslint-config-prettier: ^8.3.0 - htmlencode: ^0.0.4 - lodash: ^4.17.21 - merge2: ^1.4.1 - mocha: ^9.2.0 - nock: ^13.0.11 - nyc: ^15.1.0 - prettier: ^2.5.1 - sinon: ^7.3.2 - ts-node: ^10.4.0 - tslib: ^2.3.1 - typescript: ^4.5.3 - languageName: unknown - linkType: soft - -"ip@npm:^1.1.5": - version: 1.1.5 - resolution: "ip@npm:1.1.5" - checksum: 30133981f082a060a32644f6a7746e9ba7ac9e2bc07ecc8bbdda3ee8ca9bec1190724c390e45a1ee7695e7edfd2a8f7dda2c104ec5f7ac5068c00648504c7e5a - languageName: node - linkType: hard - -"is-binary-path@npm:~2.1.0": - version: 2.1.0 - resolution: "is-binary-path@npm:2.1.0" - dependencies: - binary-extensions: ^2.0.0 - checksum: 84192eb88cff70d320426f35ecd63c3d6d495da9d805b19bc65b518984b7c0760280e57dbf119b7e9be6b161784a5a673ab2c6abe83abb5198a432232ad5b35c - languageName: node - linkType: hard - -"is-extglob@npm:^2.1.1": - version: 2.1.1 - resolution: "is-extglob@npm:2.1.1" - checksum: df033653d06d0eb567461e58a7a8c9f940bd8c22274b94bf7671ab36df5719791aae15eef6d83bbb5e23283967f2f984b8914559d4449efda578c775c4be6f85 - languageName: node - linkType: hard - -"is-fullwidth-code-point@npm:^3.0.0": - version: 3.0.0 - resolution: "is-fullwidth-code-point@npm:3.0.0" - checksum: 44a30c29457c7fb8f00297bce733f0a64cd22eca270f83e58c105e0d015e45c019491a4ab2faef91ab51d4738c670daff901c799f6a700e27f7314029e99e348 - languageName: node - linkType: hard - -"is-glob@npm:^4.0.0, is-glob@npm:^4.0.1, is-glob@npm:^4.0.3, is-glob@npm:~4.0.1": - version: 4.0.3 - resolution: "is-glob@npm:4.0.3" - dependencies: - is-extglob: ^2.1.1 - checksum: d381c1319fcb69d341cc6e6c7cd588e17cd94722d9a32dbd60660b993c4fb7d0f19438674e68dfec686d09b7c73139c9166b47597f846af387450224a8101ab4 - languageName: node - linkType: hard - -"is-lambda@npm:^1.0.1": - version: 1.0.1 - resolution: "is-lambda@npm:1.0.1" - checksum: 93a32f01940220532e5948538699ad610d5924ac86093fcee83022252b363eb0cc99ba53ab084a04e4fb62bf7b5731f55496257a4c38adf87af9c4d352c71c35 - languageName: node - linkType: hard - -"is-number@npm:^7.0.0": - version: 7.0.0 - resolution: "is-number@npm:7.0.0" - checksum: 456ac6f8e0f3111ed34668a624e45315201dff921e5ac181f8ec24923b99e9f32ca1a194912dc79d539c97d33dba17dc635202ff0b2cf98326f608323276d27a - languageName: node - linkType: hard - -"is-plain-obj@npm:^2.1.0": - version: 2.1.0 - resolution: "is-plain-obj@npm:2.1.0" - checksum: cec9100678b0a9fe0248a81743041ed990c2d4c99f893d935545cfbc42876cbe86d207f3b895700c690ad2fa520e568c44afc1605044b535a7820c1d40e38daa - languageName: node - linkType: hard - -"is-stream@npm:^2.0.0": - version: 2.0.1 - resolution: "is-stream@npm:2.0.1" - checksum: b8e05ccdf96ac330ea83c12450304d4a591f9958c11fd17bed240af8d5ffe08aedafa4c0f4cfccd4d28dc9d4d129daca1023633d5c11601a6cbc77521f6fae66 - languageName: node - linkType: hard - -"is-typedarray@npm:^1.0.0": - version: 1.0.0 - resolution: "is-typedarray@npm:1.0.0" - checksum: 3508c6cd0a9ee2e0df2fa2e9baabcdc89e911c7bd5cf64604586697212feec525aa21050e48affb5ffc3df20f0f5d2e2cf79b08caa64e1ccc9578e251763aef7 - languageName: node - linkType: hard - -"is-unicode-supported@npm:^0.1.0": - version: 0.1.0 - resolution: "is-unicode-supported@npm:0.1.0" - checksum: a2aab86ee7712f5c2f999180daaba5f361bdad1efadc9610ff5b8ab5495b86e4f627839d085c6530363c6d6d4ecbde340fb8e54bdb83da4ba8e0865ed5513c52 - languageName: node - linkType: hard - -"is-windows@npm:^1.0.2": - version: 1.0.2 - resolution: "is-windows@npm:1.0.2" - checksum: 438b7e52656fe3b9b293b180defb4e448088e7023a523ec21a91a80b9ff8cdb3377ddb5b6e60f7c7de4fa8b63ab56e121b6705fe081b3cf1b828b0a380009ad7 - languageName: node - linkType: hard - -"isarray@npm:0.0.1": - version: 0.0.1 - resolution: "isarray@npm:0.0.1" - checksum: 49191f1425681df4a18c2f0f93db3adb85573bcdd6a4482539d98eac9e705d8961317b01175627e860516a2fc45f8f9302db26e5a380a97a520e272e2a40a8d4 - languageName: node - linkType: hard - -"isexe@npm:^2.0.0": - version: 2.0.0 - resolution: "isexe@npm:2.0.0" - checksum: 26bf6c5480dda5161c820c5b5c751ae1e766c587b1f951ea3fcfc973bafb7831ae5b54a31a69bd670220e42e99ec154475025a468eae58ea262f813fdc8d1c62 - languageName: node - linkType: hard - -"istanbul-lib-coverage@npm:^3.0.0, istanbul-lib-coverage@npm:^3.0.0-alpha.1": - version: 3.2.0 - resolution: "istanbul-lib-coverage@npm:3.2.0" - checksum: a2a545033b9d56da04a8571ed05c8120bf10e9bce01cf8633a3a2b0d1d83dff4ac4fe78d6d5673c27fc29b7f21a41d75f83a36be09f82a61c367b56aa73c1ff9 - languageName: node - linkType: hard - -"istanbul-lib-hook@npm:^3.0.0": - version: 3.0.0 - resolution: "istanbul-lib-hook@npm:3.0.0" - dependencies: - append-transform: ^2.0.0 - checksum: ac4d0a0751e959cfe4c95d817df5f1f573f9b0cf892552e60d81785654291391fac1ceb667f13bb17fcc2ef23b74c89ed8cf1c6148c833c8596a2b920b079101 - languageName: node - linkType: hard - -"istanbul-lib-instrument@npm:^4.0.0": - version: 4.0.3 - resolution: "istanbul-lib-instrument@npm:4.0.3" - dependencies: - "@babel/core": ^7.7.5 - "@istanbuljs/schema": ^0.1.2 - istanbul-lib-coverage: ^3.0.0 - semver: ^6.3.0 - checksum: fa1171d3022b1bb8f6a734042620ac5d9ee7dc80f3065a0bb12863e9f0494d0eefa3d86608fcc0254ab2765d29d7dad8bdc42e5f8df2f9a1fbe85ccc59d76cb9 - languageName: node - linkType: hard - -"istanbul-lib-processinfo@npm:^2.0.2": - version: 2.0.2 - resolution: "istanbul-lib-processinfo@npm:2.0.2" - dependencies: - archy: ^1.0.0 - cross-spawn: ^7.0.0 - istanbul-lib-coverage: ^3.0.0-alpha.1 - make-dir: ^3.0.0 - p-map: ^3.0.0 - rimraf: ^3.0.0 - uuid: ^3.3.3 - checksum: 400bd0b25b623c172e48d37e5bdda7a58b2fe5beeedfeb03099aed3385223d31e4cfa6f9932be07bbf06cfd039023301bce81d3b70b9a20a79a38b0f12cb261a - languageName: node - linkType: hard - -"istanbul-lib-report@npm:^3.0.0": - version: 3.0.0 - resolution: "istanbul-lib-report@npm:3.0.0" - dependencies: - istanbul-lib-coverage: ^3.0.0 - make-dir: ^3.0.0 - supports-color: ^7.1.0 - checksum: 3f29eb3f53c59b987386e07fe772d24c7f58c6897f34c9d7a296f4000de7ae3de9eb95c3de3df91dc65b134c84dee35c54eee572a56243e8907c48064e34ff1b - languageName: node - linkType: hard - -"istanbul-lib-source-maps@npm:^4.0.0": - version: 4.0.1 - resolution: "istanbul-lib-source-maps@npm:4.0.1" - dependencies: - debug: ^4.1.1 - istanbul-lib-coverage: ^3.0.0 - source-map: ^0.6.1 - checksum: 21ad3df45db4b81852b662b8d4161f6446cd250c1ddc70ef96a585e2e85c26ed7cd9c2a396a71533cfb981d1a645508bc9618cae431e55d01a0628e7dec62ef2 - languageName: node - linkType: hard - -"istanbul-reports@npm:^3.0.2": - version: 3.1.3 - resolution: "istanbul-reports@npm:3.1.3" - dependencies: - html-escaper: ^2.0.0 - istanbul-lib-report: ^3.0.0 - checksum: ef6e0d9ed05ecab1974c6eb46cc2a12d8570911934192db4ed40cf1978449240ea80aae32c4dd5555b67407cdf860212d1a9e415443af69641aa57ed1da5ebbb - languageName: node - linkType: hard - -"js-tokens@npm:^4.0.0": - version: 4.0.0 - resolution: "js-tokens@npm:4.0.0" - checksum: 8a95213a5a77deb6cbe94d86340e8d9ace2b93bc367790b260101d2f36a2eaf4e4e22d9fa9cf459b38af3a32fb4190e638024cf82ec95ef708680e405ea7cc78 - languageName: node - linkType: hard - -"js-yaml@npm:4.1.0, js-yaml@npm:^4.1.0": - version: 4.1.0 - resolution: "js-yaml@npm:4.1.0" - dependencies: - argparse: ^2.0.1 - bin: - js-yaml: bin/js-yaml.js - checksum: c7830dfd456c3ef2c6e355cc5a92e6700ceafa1d14bba54497b34a99f0376cecbb3e9ac14d3e5849b426d5a5140709a66237a8c991c675431271c4ce5504151a - languageName: node - linkType: hard - -"js-yaml@npm:^3.13.1": - version: 3.14.1 - resolution: "js-yaml@npm:3.14.1" - dependencies: - argparse: ^1.0.7 - esprima: ^4.0.0 - bin: - js-yaml: bin/js-yaml.js - checksum: bef146085f472d44dee30ec34e5cf36bf89164f5d585435a3d3da89e52622dff0b188a580e4ad091c3341889e14cb88cac6e4deb16dc5b1e9623bb0601fc255c - languageName: node - linkType: hard - -"jsesc@npm:^2.5.1": - version: 2.5.2 - resolution: "jsesc@npm:2.5.2" - bin: - jsesc: bin/jsesc - checksum: 4dc190771129e12023f729ce20e1e0bfceac84d73a85bc3119f7f938843fe25a4aeccb54b6494dce26fcf263d815f5f31acdefac7cc9329efb8422a4f4d9fa9d - languageName: node - linkType: hard - -"json-schema-traverse@npm:^0.4.1": - version: 0.4.1 - resolution: "json-schema-traverse@npm:0.4.1" - checksum: 7486074d3ba247769fda17d5181b345c9fb7d12e0da98b22d1d71a5db9698d8b4bd900a3ec1a4ffdd60846fc2556274a5c894d0c48795f14cb03aeae7b55260b - languageName: node - linkType: hard - -"json-stable-stringify-without-jsonify@npm:^1.0.1": - version: 1.0.1 - resolution: "json-stable-stringify-without-jsonify@npm:1.0.1" - checksum: cff44156ddce9c67c44386ad5cddf91925fe06b1d217f2da9c4910d01f358c6e3989c4d5a02683c7a5667f9727ff05831f7aa8ae66c8ff691c556f0884d49215 - languageName: node - linkType: hard - -"json-stringify-safe@npm:^5.0.1": - version: 5.0.1 - resolution: "json-stringify-safe@npm:5.0.1" - checksum: 48ec0adad5280b8a96bb93f4563aa1667fd7a36334f79149abd42446d0989f2ddc58274b479f4819f1f00617957e6344c886c55d05a4e15ebb4ab931e4a6a8ee - languageName: node - linkType: hard - -"json5@npm:^2.1.2": - version: 2.2.0 - resolution: "json5@npm:2.2.0" - dependencies: - minimist: ^1.2.5 - bin: - json5: lib/cli.js - checksum: e88fc5274bb58fc99547baa777886b069d2dd96d9cfc4490b305fd16d711dabd5979e35a4f90873cefbeb552e216b041a304fe56702bedba76e19bc7845f208d - languageName: node - linkType: hard - -"just-extend@npm:^4.0.2": - version: 4.2.1 - resolution: "just-extend@npm:4.2.1" - checksum: ff9fdede240fad313efeeeb68a660b942e5586d99c0058064c78884894a2690dc09bba44c994ad4e077e45d913fef01a9240c14a72c657b53687ac58de53b39c - languageName: node - linkType: hard - -"levn@npm:^0.4.1": - version: 0.4.1 - resolution: "levn@npm:0.4.1" - dependencies: - prelude-ls: ^1.2.1 - type-check: ~0.4.0 - checksum: 12c5021c859bd0f5248561bf139121f0358285ec545ebf48bb3d346820d5c61a4309535c7f387ed7d84361cf821e124ce346c6b7cef8ee09a67c1473b46d0fc4 - languageName: node - linkType: hard - -"locate-path@npm:^5.0.0": - version: 5.0.0 - resolution: "locate-path@npm:5.0.0" - dependencies: - p-locate: ^4.1.0 - checksum: 83e51725e67517287d73e1ded92b28602e3ae5580b301fe54bfb76c0c723e3f285b19252e375712316774cf52006cb236aed5704692c32db0d5d089b69696e30 - languageName: node - linkType: hard - -"locate-path@npm:^6.0.0": - version: 6.0.0 - resolution: "locate-path@npm:6.0.0" - dependencies: - p-locate: ^5.0.0 - checksum: 72eb661788a0368c099a184c59d2fee760b3831c9c1c33955e8a19ae4a21b4116e53fa736dc086cdeb9fce9f7cc508f2f92d2d3aae516f133e16a2bb59a39f5a - languageName: node - linkType: hard - -"lodash.flattendeep@npm:^4.4.0": - version: 4.4.0 - resolution: "lodash.flattendeep@npm:4.4.0" - checksum: 8521c919acac3d4bcf0aaf040c1ca9cb35d6c617e2d72e9b4d51c9a58b4366622cd6077441a18be626c3f7b28227502b3bf042903d447b056ee7e0b11d45c722 - languageName: node - linkType: hard - -"lodash.merge@npm:^4.6.2": - version: 4.6.2 - resolution: "lodash.merge@npm:4.6.2" - checksum: ad580b4bdbb7ca1f7abf7e1bce63a9a0b98e370cf40194b03380a46b4ed799c9573029599caebc1b14e3f24b111aef72b96674a56cfa105e0f5ac70546cdc005 - languageName: node - linkType: hard - -"lodash.set@npm:^4.3.2": - version: 4.3.2 - resolution: "lodash.set@npm:4.3.2" - checksum: a9122f49eef9f2d0fc9061a33d87f8e5b8c6b23d46e8b9e9ce1529d3588d79741bd1145a3abdfa3b13082703e65af27ff18d8a07bfc22b9be32f3fc36f763f70 - languageName: node - linkType: hard - -"lodash@npm:^4.17.15, lodash@npm:^4.17.21": - version: 4.17.21 - resolution: "lodash@npm:4.17.21" - checksum: eb835a2e51d381e561e508ce932ea50a8e5a68f4ebdd771ea240d3048244a8d13658acbd502cd4829768c56f2e16bdd4340b9ea141297d472517b83868e677f7 - languageName: node - linkType: hard - -"log-symbols@npm:4.1.0": - version: 4.1.0 - resolution: "log-symbols@npm:4.1.0" - dependencies: - chalk: ^4.1.0 - is-unicode-supported: ^0.1.0 - checksum: fce1497b3135a0198803f9f07464165e9eb83ed02ceb2273930a6f8a508951178d8cf4f0378e9d28300a2ed2bc49050995d2bd5f53ab716bb15ac84d58c6ef74 - languageName: node - linkType: hard - -"lolex@npm:^4.2.0": - version: 4.2.0 - resolution: "lolex@npm:4.2.0" - checksum: 0a83bfe1748fc745515dff9b3f722422918f5f6975104d7e576fc32c06b5398ee0c58525684068d4de49cdd49874e00b5e2b2d72ce8c5d829dab86c8c08ca31f - languageName: node - linkType: hard - -"lolex@npm:^5.0.1": - version: 5.1.2 - resolution: "lolex@npm:5.1.2" - dependencies: - "@sinonjs/commons": ^1.7.0 - checksum: 7eb468d4ef4746c024d23cb2b75f679f79449a9d5cbe11abadf2f3b147c1d7ffe28816438bedfb8a75c58357a625c2f9ba197b050c226d2b3f0c4a956cf556fb - languageName: node - linkType: hard - -"lru-cache@npm:^6.0.0": - version: 6.0.0 - resolution: "lru-cache@npm:6.0.0" - dependencies: - yallist: ^4.0.0 - checksum: f97f499f898f23e4585742138a22f22526254fdba6d75d41a1c2526b3b6cc5747ef59c5612ba7375f42aca4f8461950e925ba08c991ead0651b4918b7c978297 - languageName: node - linkType: hard - -"make-dir@npm:^3.0.0, make-dir@npm:^3.0.2": - version: 3.1.0 - resolution: "make-dir@npm:3.1.0" - dependencies: - semver: ^6.0.0 - checksum: 484200020ab5a1fdf12f393fe5f385fc8e4378824c940fba1729dcd198ae4ff24867bc7a5646331e50cead8abff5d9270c456314386e629acec6dff4b8016b78 - languageName: node - linkType: hard - -"make-error@npm:^1.1.1": - version: 1.3.6 - resolution: "make-error@npm:1.3.6" - checksum: b86e5e0e25f7f777b77fabd8e2cbf15737972869d852a22b7e73c17623928fccb826d8e46b9951501d3f20e51ad74ba8c59ed584f610526a48f8ccf88aaec402 - languageName: node - linkType: hard - -"make-fetch-happen@npm:^9.1.0": - version: 9.1.0 - resolution: "make-fetch-happen@npm:9.1.0" - dependencies: - agentkeepalive: ^4.1.3 - cacache: ^15.2.0 - http-cache-semantics: ^4.1.0 - http-proxy-agent: ^4.0.1 - https-proxy-agent: ^5.0.0 - is-lambda: ^1.0.1 - lru-cache: ^6.0.0 - minipass: ^3.1.3 - minipass-collect: ^1.0.2 - minipass-fetch: ^1.3.2 - minipass-flush: ^1.0.5 - minipass-pipeline: ^1.2.4 - negotiator: ^0.6.2 - promise-retry: ^2.0.1 - socks-proxy-agent: ^6.0.0 - ssri: ^8.0.0 - checksum: 0eb371c85fdd0b1584fcfdf3dc3c62395761b3c14658be02620c310305a9a7ecf1617a5e6fb30c1d081c5c8aaf177fa133ee225024313afabb7aa6a10f1e3d04 - languageName: node - linkType: hard - -"merge2@npm:^1.3.0, merge2@npm:^1.4.1": - version: 1.4.1 - resolution: "merge2@npm:1.4.1" - checksum: 7268db63ed5169466540b6fb947aec313200bcf6d40c5ab722c22e242f651994619bcd85601602972d3c85bd2cc45a358a4c61937e9f11a061919a1da569b0c2 - languageName: node - linkType: hard - -"micromatch@npm:^4.0.4": - version: 4.0.4 - resolution: "micromatch@npm:4.0.4" - dependencies: - braces: ^3.0.1 - picomatch: ^2.2.3 - checksum: ef3d1c88e79e0a68b0e94a03137676f3324ac18a908c245a9e5936f838079fcc108ac7170a5fadc265a9c2596963462e402841406bda1a4bb7b68805601d631c - languageName: node - linkType: hard - -"minimatch@npm:3.0.4, minimatch@npm:^3.0.4": - version: 3.0.4 - resolution: "minimatch@npm:3.0.4" - dependencies: - brace-expansion: ^1.1.7 - checksum: 66ac295f8a7b59788000ea3749938b0970344c841750abd96694f80269b926ebcafad3deeb3f1da2522978b119e6ae3a5869b63b13a7859a456b3408bd18a078 - languageName: node - linkType: hard - -"minimist@npm:^1.2.5": - version: 1.2.5 - resolution: "minimist@npm:1.2.5" - checksum: 86706ce5b36c16bfc35c5fe3dbb01d5acdc9a22f2b6cc810b6680656a1d2c0e44a0159c9a3ba51fb072bb5c203e49e10b51dcd0eec39c481f4c42086719bae52 - languageName: node - linkType: hard - -"minipass-collect@npm:^1.0.2": - version: 1.0.2 - resolution: "minipass-collect@npm:1.0.2" - dependencies: - minipass: ^3.0.0 - checksum: 14df761028f3e47293aee72888f2657695ec66bd7d09cae7ad558da30415fdc4752bbfee66287dcc6fd5e6a2fa3466d6c484dc1cbd986525d9393b9523d97f10 - languageName: node - linkType: hard - -"minipass-fetch@npm:^1.3.2": - version: 1.4.1 - resolution: "minipass-fetch@npm:1.4.1" - dependencies: - encoding: ^0.1.12 - minipass: ^3.1.0 - minipass-sized: ^1.0.3 - minizlib: ^2.0.0 - dependenciesMeta: - encoding: - optional: true - checksum: ec93697bdb62129c4e6c0104138e681e30efef8c15d9429dd172f776f83898471bc76521b539ff913248cc2aa6d2b37b652c993504a51cc53282563640f29216 - languageName: node - linkType: hard - -"minipass-flush@npm:^1.0.5": - version: 1.0.5 - resolution: "minipass-flush@npm:1.0.5" - dependencies: - minipass: ^3.0.0 - checksum: 56269a0b22bad756a08a94b1ffc36b7c9c5de0735a4dd1ab2b06c066d795cfd1f0ac44a0fcae13eece5589b908ecddc867f04c745c7009be0b566421ea0944cf - languageName: node - linkType: hard - -"minipass-pipeline@npm:^1.2.2, minipass-pipeline@npm:^1.2.4": - version: 1.2.4 - resolution: "minipass-pipeline@npm:1.2.4" - dependencies: - minipass: ^3.0.0 - checksum: b14240dac0d29823c3d5911c286069e36d0b81173d7bdf07a7e4a91ecdef92cdff4baaf31ea3746f1c61e0957f652e641223970870e2353593f382112257971b - languageName: node - linkType: hard - -"minipass-sized@npm:^1.0.3": - version: 1.0.3 - resolution: "minipass-sized@npm:1.0.3" - dependencies: - minipass: ^3.0.0 - checksum: 79076749fcacf21b5d16dd596d32c3b6bf4d6e62abb43868fac21674078505c8b15eaca4e47ed844985a4514854f917d78f588fcd029693709417d8f98b2bd60 - languageName: node - linkType: hard - -"minipass@npm:^3.0.0, minipass@npm:^3.1.0, minipass@npm:^3.1.1, minipass@npm:^3.1.3": - version: 3.1.6 - resolution: "minipass@npm:3.1.6" - dependencies: - yallist: ^4.0.0 - checksum: 57a04041413a3531a65062452cb5175f93383ef245d6f4a2961d34386eb9aa8ac11ac7f16f791f5e8bbaf1dfb1ef01596870c88e8822215db57aa591a5bb0a77 - languageName: node - linkType: hard - -"minizlib@npm:^2.0.0, minizlib@npm:^2.1.1": - version: 2.1.2 - resolution: "minizlib@npm:2.1.2" - dependencies: - minipass: ^3.0.0 - yallist: ^4.0.0 - checksum: f1fdeac0b07cf8f30fcf12f4b586795b97be856edea22b5e9072707be51fc95d41487faec3f265b42973a304fe3a64acd91a44a3826a963e37b37bafde0212c3 - languageName: node - linkType: hard - -"mkdirp@npm:^1.0.3, mkdirp@npm:^1.0.4": - version: 1.0.4 - resolution: "mkdirp@npm:1.0.4" - bin: - mkdirp: bin/cmd.js - checksum: a96865108c6c3b1b8e1d5e9f11843de1e077e57737602de1b82030815f311be11f96f09cce59bd5b903d0b29834733e5313f9301e3ed6d6f6fba2eae0df4298f - languageName: node - linkType: hard - -"mocha@npm:^9.2.0": - version: 9.2.0 - resolution: "mocha@npm:9.2.0" - dependencies: - "@ungap/promise-all-settled": 1.1.2 - ansi-colors: 4.1.1 - browser-stdout: 1.3.1 - chokidar: 3.5.3 - debug: 4.3.3 - diff: 5.0.0 - escape-string-regexp: 4.0.0 - find-up: 5.0.0 - glob: 7.2.0 - growl: 1.10.5 - he: 1.2.0 - js-yaml: 4.1.0 - log-symbols: 4.1.0 - minimatch: 3.0.4 - ms: 2.1.3 - nanoid: 3.2.0 - serialize-javascript: 6.0.0 - strip-json-comments: 3.1.1 - supports-color: 8.1.1 - which: 2.0.2 - workerpool: 6.2.0 - yargs: 16.2.0 - yargs-parser: 20.2.4 - yargs-unparser: 2.0.0 - bin: - _mocha: bin/_mocha - mocha: bin/mocha - checksum: 49efc4724cf17087c7e107bc8f6890db24525e6dcc153b801da58de3c2a2f940e22f7600ef195b8ac62a0dfd7baee5cf289fc4641a6b1fdf8bc9c819efc1a8ba - languageName: node - linkType: hard - -"ms@npm:2.1.2": - version: 2.1.2 - resolution: "ms@npm:2.1.2" - checksum: 673cdb2c3133eb050c745908d8ce632ed2c02d85640e2edb3ace856a2266a813b30c613569bf3354fdf4ea7d1a1494add3bfa95e2713baa27d0c2c71fc44f58f - languageName: node - linkType: hard - -"ms@npm:2.1.3, ms@npm:^2.0.0": - version: 2.1.3 - resolution: "ms@npm:2.1.3" - checksum: aa92de608021b242401676e35cfa5aa42dd70cbdc082b916da7fb925c542173e36bce97ea3e804923fe92c0ad991434e4a38327e15a1b5b5f945d66df615ae6d - languageName: node - linkType: hard - -"nanoid@npm:3.2.0": - version: 3.2.0 - resolution: "nanoid@npm:3.2.0" - bin: - nanoid: bin/nanoid.cjs - checksum: 3d1d5a69fea84e538057cf64106e713931c4ef32af344068ecff153ff91252f39b0f2b472e09b0dfff43ac3cf520c92938d90e6455121fe93976e23660f4fccc - languageName: node - linkType: hard - -"natural-compare@npm:^1.4.0": - version: 1.4.0 - resolution: "natural-compare@npm:1.4.0" - checksum: 23ad088b08f898fc9b53011d7bb78ec48e79de7627e01ab5518e806033861bef68d5b0cd0e2205c2f36690ac9571ff6bcb05eb777ced2eeda8d4ac5b44592c3d - languageName: node - linkType: hard - -"negotiator@npm:^0.6.2": - version: 0.6.3 - resolution: "negotiator@npm:0.6.3" - checksum: b8ffeb1e262eff7968fc90a2b6767b04cfd9842582a9d0ece0af7049537266e7b2506dfb1d107a32f06dd849ab2aea834d5830f7f4d0e5cb7d36e1ae55d021d9 - languageName: node - linkType: hard - -"nise@npm:^1.5.2": - version: 1.5.3 - resolution: "nise@npm:1.5.3" - dependencies: - "@sinonjs/formatio": ^3.2.1 - "@sinonjs/text-encoding": ^0.7.1 - just-extend: ^4.0.2 - lolex: ^5.0.1 - path-to-regexp: ^1.7.0 - checksum: ec3af21345dcaf34650a6f5420a11e0fd21a836ac5960f5e8523c301ee98465abf88b958f7b3084ecc6e0a7133e5cf7963f4df176b90b423c4da4984f1ebd75e - languageName: node - linkType: hard - -"nock@npm:^13.0.11": - version: 13.2.2 - resolution: "nock@npm:13.2.2" - dependencies: - debug: ^4.1.0 - json-stringify-safe: ^5.0.1 - lodash.set: ^4.3.2 - propagate: ^2.0.0 - checksum: cc1bf6e4bbf2fb0a540aa7d5f82788a6fb2490034083ed89242becc0ff1bfb391bfd3c7a7a9c0f24dec9c085426f66441765756b279a7dd608e4630586f9cb0d - languageName: node - linkType: hard - -"node-gyp@npm:latest": - version: 8.4.1 - resolution: "node-gyp@npm:8.4.1" - dependencies: - env-paths: ^2.2.0 - glob: ^7.1.4 - graceful-fs: ^4.2.6 - make-fetch-happen: ^9.1.0 - nopt: ^5.0.0 - npmlog: ^6.0.0 - rimraf: ^3.0.2 - semver: ^7.3.5 - tar: ^6.1.2 - which: ^2.0.2 - bin: - node-gyp: bin/node-gyp.js - checksum: 341710b5da39d3660e6a886b37e210d33f8282047405c2e62c277bcc744c7552c5b8b972ebc3a7d5c2813794e60cc48c3ebd142c46d6e0321db4db6c92dd0355 - languageName: node - linkType: hard - -"node-preload@npm:^0.2.1": - version: 0.2.1 - resolution: "node-preload@npm:0.2.1" - dependencies: - process-on-spawn: ^1.0.0 - checksum: 4586f91ac7417b33accce0ac629fb60f642d0c8d212b3c536dc3dda37fe54f8a3b858273380e1036e41a65d85470332c358315d2288e6584260d620fb4b00fb3 - languageName: node - linkType: hard - -"node-releases@npm:^2.0.1": - version: 2.0.1 - resolution: "node-releases@npm:2.0.1" - checksum: b20dd8d4bced11f75060f0387e05e76b9dc4a0451f7bb3516eade6f50499ea7768ba95d8a60d520c193402df1e58cb3fe301510cc1c1ad68949c3d57b5149866 - languageName: node - linkType: hard - -"nopt@npm:^5.0.0": - version: 5.0.0 - resolution: "nopt@npm:5.0.0" - dependencies: - abbrev: 1 - bin: - nopt: bin/nopt.js - checksum: d35fdec187269503843924e0114c0c6533fb54bbf1620d0f28b4b60ba01712d6687f62565c55cc20a504eff0fbe5c63e22340c3fad549ad40469ffb611b04f2f - languageName: node - linkType: hard - -"normalize-path@npm:^3.0.0, normalize-path@npm:~3.0.0": - version: 3.0.0 - resolution: "normalize-path@npm:3.0.0" - checksum: 88eeb4da891e10b1318c4b2476b6e2ecbeb5ff97d946815ffea7794c31a89017c70d7f34b3c2ebf23ef4e9fc9fb99f7dffe36da22011b5b5c6ffa34f4873ec20 - languageName: node - linkType: hard - -"npmlog@npm:^6.0.0": - version: 6.0.0 - resolution: "npmlog@npm:6.0.0" - dependencies: - are-we-there-yet: ^2.0.0 - console-control-strings: ^1.1.0 - gauge: ^4.0.0 - set-blocking: ^2.0.0 - checksum: 33d8a7fe3d63bf83b16655b6588ae7ba10b5f37b067a661e7cab6508660d7c3204ae716ee2c5ce4eb9626fd1489cf2fa7645d789bc3b704f8c3ccb04a532a50b - languageName: node - linkType: hard - -"nyc@npm:^15.1.0": - version: 15.1.0 - resolution: "nyc@npm:15.1.0" - dependencies: - "@istanbuljs/load-nyc-config": ^1.0.0 - "@istanbuljs/schema": ^0.1.2 - caching-transform: ^4.0.0 - convert-source-map: ^1.7.0 - decamelize: ^1.2.0 - find-cache-dir: ^3.2.0 - find-up: ^4.1.0 - foreground-child: ^2.0.0 - get-package-type: ^0.1.0 - glob: ^7.1.6 - istanbul-lib-coverage: ^3.0.0 - istanbul-lib-hook: ^3.0.0 - istanbul-lib-instrument: ^4.0.0 - istanbul-lib-processinfo: ^2.0.2 - istanbul-lib-report: ^3.0.0 - istanbul-lib-source-maps: ^4.0.0 - istanbul-reports: ^3.0.2 - make-dir: ^3.0.0 - node-preload: ^0.2.1 - p-map: ^3.0.0 - process-on-spawn: ^1.0.0 - resolve-from: ^5.0.0 - rimraf: ^3.0.0 - signal-exit: ^3.0.2 - spawn-wrap: ^2.0.0 - test-exclude: ^6.0.0 - yargs: ^15.0.2 - bin: - nyc: bin/nyc.js - checksum: 82a7031982df2fd6ab185c9f1b5d032b6221846268007b45b5773c6582e776ab33e96cd22b4231520345942fcef69b4339bd967675b8483f3fa255b56326faef - languageName: node - linkType: hard - -"once@npm:^1.3.0": - version: 1.4.0 - resolution: "once@npm:1.4.0" - dependencies: - wrappy: 1 - checksum: cd0a88501333edd640d95f0d2700fbde6bff20b3d4d9bdc521bdd31af0656b5706570d6c6afe532045a20bb8dc0849f8332d6f2a416e0ba6d3d3b98806c7db68 - languageName: node - linkType: hard - -"optionator@npm:^0.9.1": - version: 0.9.1 - resolution: "optionator@npm:0.9.1" - dependencies: - deep-is: ^0.1.3 - fast-levenshtein: ^2.0.6 - levn: ^0.4.1 - prelude-ls: ^1.2.1 - type-check: ^0.4.0 - word-wrap: ^1.2.3 - checksum: dbc6fa065604b24ea57d734261914e697bd73b69eff7f18e967e8912aa2a40a19a9f599a507fa805be6c13c24c4eae8c71306c239d517d42d4c041c942f508a0 - languageName: node - linkType: hard - -"p-limit@npm:^2.2.0": - version: 2.3.0 - resolution: "p-limit@npm:2.3.0" - dependencies: - p-try: ^2.0.0 - checksum: 84ff17f1a38126c3314e91ecfe56aecbf36430940e2873dadaa773ffe072dc23b7af8e46d4b6485d302a11673fe94c6b67ca2cfbb60c989848b02100d0594ac1 - languageName: node - linkType: hard - -"p-limit@npm:^3.0.2": - version: 3.1.0 - resolution: "p-limit@npm:3.1.0" - dependencies: - yocto-queue: ^0.1.0 - checksum: 7c3690c4dbf62ef625671e20b7bdf1cbc9534e83352a2780f165b0d3ceba21907e77ad63401708145ca4e25bfc51636588d89a8c0aeb715e6c37d1c066430360 - languageName: node - linkType: hard - -"p-locate@npm:^4.1.0": - version: 4.1.0 - resolution: "p-locate@npm:4.1.0" - dependencies: - p-limit: ^2.2.0 - checksum: 513bd14a455f5da4ebfcb819ef706c54adb09097703de6aeaa5d26fe5ea16df92b48d1ac45e01e3944ce1e6aa2a66f7f8894742b8c9d6e276e16cd2049a2b870 - languageName: node - linkType: hard - -"p-locate@npm:^5.0.0": - version: 5.0.0 - resolution: "p-locate@npm:5.0.0" - dependencies: - p-limit: ^3.0.2 - checksum: 1623088f36cf1cbca58e9b61c4e62bf0c60a07af5ae1ca99a720837356b5b6c5ba3eb1b2127e47a06865fee59dd0453cad7cc844cda9d5a62ac1a5a51b7c86d3 - languageName: node - linkType: hard - -"p-map@npm:^3.0.0": - version: 3.0.0 - resolution: "p-map@npm:3.0.0" - dependencies: - aggregate-error: ^3.0.0 - checksum: 49b0fcbc66b1ef9cd379de1b4da07fa7a9f84b41509ea3f461c31903623aaba8a529d22f835e0d77c7cb9fcc16e4fae71e308fd40179aea514ba68f27032b5d5 - languageName: node - linkType: hard - -"p-map@npm:^4.0.0": - version: 4.0.0 - resolution: "p-map@npm:4.0.0" - dependencies: - aggregate-error: ^3.0.0 - checksum: cb0ab21ec0f32ddffd31dfc250e3afa61e103ef43d957cc45497afe37513634589316de4eb88abdfd969fe6410c22c0b93ab24328833b8eb1ccc087fc0442a1c - languageName: node - linkType: hard - -"p-try@npm:^2.0.0": - version: 2.2.0 - resolution: "p-try@npm:2.2.0" - checksum: f8a8e9a7693659383f06aec604ad5ead237c7a261c18048a6e1b5b85a5f8a067e469aa24f5bc009b991ea3b058a87f5065ef4176793a200d4917349881216cae - languageName: node - linkType: hard - -"package-hash@npm:^4.0.0": - version: 4.0.0 - resolution: "package-hash@npm:4.0.0" - dependencies: - graceful-fs: ^4.1.15 - hasha: ^5.0.0 - lodash.flattendeep: ^4.4.0 - release-zalgo: ^1.0.0 - checksum: 32c49e3a0e1c4a33b086a04cdd6d6e570aee019cb8402ec16476d9b3564a40e38f91ce1a1f9bc88b08f8ef2917a11e0b786c08140373bdf609ea90749031e6fc - languageName: node - linkType: hard - -"parent-module@npm:^1.0.0": - version: 1.0.1 - resolution: "parent-module@npm:1.0.1" - dependencies: - callsites: ^3.0.0 - checksum: 6ba8b255145cae9470cf5551eb74be2d22281587af787a2626683a6c20fbb464978784661478dd2a3f1dad74d1e802d403e1b03c1a31fab310259eec8ac560ff - languageName: node - linkType: hard - -"path-exists@npm:^4.0.0": - version: 4.0.0 - resolution: "path-exists@npm:4.0.0" - checksum: 505807199dfb7c50737b057dd8d351b82c033029ab94cb10a657609e00c1bc53b951cfdbccab8de04c5584d5eff31128ce6afd3db79281874a5ef2adbba55ed1 - languageName: node - linkType: hard - -"path-is-absolute@npm:^1.0.0": - version: 1.0.1 - resolution: "path-is-absolute@npm:1.0.1" - checksum: 060840f92cf8effa293bcc1bea81281bd7d363731d214cbe5c227df207c34cd727430f70c6037b5159c8a870b9157cba65e775446b0ab06fd5ecc7e54615a3b8 - languageName: node - linkType: hard - -"path-key@npm:^3.1.0": - version: 3.1.1 - resolution: "path-key@npm:3.1.1" - checksum: 55cd7a9dd4b343412a8386a743f9c746ef196e57c823d90ca3ab917f90ab9f13dd0ded27252ba49dbdfcab2b091d998bc446f6220cd3cea65db407502a740020 - languageName: node - linkType: hard - -"path-to-regexp@npm:^1.7.0": - version: 1.8.0 - resolution: "path-to-regexp@npm:1.8.0" - dependencies: - isarray: 0.0.1 - checksum: 709f6f083c0552514ef4780cb2e7e4cf49b0cc89a97439f2b7cc69a608982b7690fb5d1720a7473a59806508fc2dae0be751ba49f495ecf89fd8fbc62abccbcd - languageName: node - linkType: hard - -"path-type@npm:^4.0.0": - version: 4.0.0 - resolution: "path-type@npm:4.0.0" - checksum: 5b1e2daa247062061325b8fdbfd1fb56dde0a448fb1455453276ea18c60685bdad23a445dc148cf87bc216be1573357509b7d4060494a6fd768c7efad833ee45 - languageName: node - linkType: hard - -"picocolors@npm:^1.0.0": - version: 1.0.0 - resolution: "picocolors@npm:1.0.0" - checksum: a2e8092dd86c8396bdba9f2b5481032848525b3dc295ce9b57896f931e63fc16f79805144321f72976383fc249584672a75cc18d6777c6b757603f372f745981 - languageName: node - linkType: hard - -"picomatch@npm:^2.0.4, picomatch@npm:^2.2.1, picomatch@npm:^2.2.3": - version: 2.3.1 - resolution: "picomatch@npm:2.3.1" - checksum: 050c865ce81119c4822c45d3c84f1ced46f93a0126febae20737bd05ca20589c564d6e9226977df859ed5e03dc73f02584a2b0faad36e896936238238b0446cf - languageName: node - linkType: hard - -"pkg-dir@npm:^4.1.0": - version: 4.2.0 - resolution: "pkg-dir@npm:4.2.0" - dependencies: - find-up: ^4.0.0 - checksum: 9863e3f35132bf99ae1636d31ff1e1e3501251d480336edb1c211133c8d58906bed80f154a1d723652df1fda91e01c7442c2eeaf9dc83157c7ae89087e43c8d6 - languageName: node - linkType: hard - -"prelude-ls@npm:^1.2.1": - version: 1.2.1 - resolution: "prelude-ls@npm:1.2.1" - checksum: cd192ec0d0a8e4c6da3bb80e4f62afe336df3f76271ac6deb0e6a36187133b6073a19e9727a1ff108cd8b9982e4768850d413baa71214dd80c7979617dca827a - languageName: node - linkType: hard - -"prettier@npm:^2.5.1": - version: 2.5.1 - resolution: "prettier@npm:2.5.1" - bin: - prettier: bin-prettier.js - checksum: 21b9408476ea1c544b0e45d51ceb94a84789ff92095abb710942d780c862d0daebdb29972d47f6b4d0f7ebbfb0ffbf56cc2cfa3e3e9d1cca54864af185b15b66 - languageName: node - linkType: hard - -"process-on-spawn@npm:^1.0.0": - version: 1.0.0 - resolution: "process-on-spawn@npm:1.0.0" - dependencies: - fromentries: ^1.2.0 - checksum: 597769e3db6a8e2cb1cd64a952bbc150220588debac31c7cf1a9f620ce981e25583d8d70848d8a14953577608512984a8808c3be77e09af8ebdcdc14ec23a295 - languageName: node - linkType: hard - -"promise-inflight@npm:^1.0.1": - version: 1.0.1 - resolution: "promise-inflight@npm:1.0.1" - checksum: 22749483091d2c594261517f4f80e05226d4d5ecc1fc917e1886929da56e22b5718b7f2a75f3807e7a7d471bc3be2907fe92e6e8f373ddf5c64bae35b5af3981 - languageName: node - linkType: hard - -"promise-retry@npm:^2.0.1": - version: 2.0.1 - resolution: "promise-retry@npm:2.0.1" - dependencies: - err-code: ^2.0.2 - retry: ^0.12.0 - checksum: f96a3f6d90b92b568a26f71e966cbbc0f63ab85ea6ff6c81284dc869b41510e6cdef99b6b65f9030f0db422bf7c96652a3fff9f2e8fb4a0f069d8f4430359429 - languageName: node - linkType: hard - -"propagate@npm:^2.0.0": - version: 2.0.1 - resolution: "propagate@npm:2.0.1" - checksum: c4febaee2be0979e82fb6b3727878fd122a98d64a7fa3c9d09b0576751b88514a9e9275b1b92e76b364d488f508e223bd7e1dcdc616be4cdda876072fbc2a96c - languageName: node - linkType: hard - -"punycode@npm:^2.1.0": - version: 2.1.1 - resolution: "punycode@npm:2.1.1" - checksum: 823bf443c6dd14f669984dea25757b37993f67e8d94698996064035edd43bed8a5a17a9f12e439c2b35df1078c6bec05a6c86e336209eb1061e8025c481168e8 - languageName: node - linkType: hard - -"queue-microtask@npm:^1.2.2": - version: 1.2.3 - resolution: "queue-microtask@npm:1.2.3" - checksum: b676f8c040cdc5b12723ad2f91414d267605b26419d5c821ff03befa817ddd10e238d22b25d604920340fd73efd8ba795465a0377c4adf45a4a41e4234e42dc4 - languageName: node - linkType: hard - -"randombytes@npm:^2.1.0": - version: 2.1.0 - resolution: "randombytes@npm:2.1.0" - dependencies: - safe-buffer: ^5.1.0 - checksum: d779499376bd4cbb435ef3ab9a957006c8682f343f14089ed5f27764e4645114196e75b7f6abf1cbd84fd247c0cb0651698444df8c9bf30e62120fbbc52269d6 - languageName: node - linkType: hard - -"readable-stream@npm:^3.6.0": - version: 3.6.0 - resolution: "readable-stream@npm:3.6.0" - dependencies: - inherits: ^2.0.3 - string_decoder: ^1.1.1 - util-deprecate: ^1.0.1 - checksum: d4ea81502d3799439bb955a3a5d1d808592cf3133350ed352aeaa499647858b27b1c4013984900238b0873ec8d0d8defce72469fb7a83e61d53f5ad61cb80dc8 - languageName: node - linkType: hard - -"readdirp@npm:~3.6.0": - version: 3.6.0 - resolution: "readdirp@npm:3.6.0" - dependencies: - picomatch: ^2.2.1 - checksum: 1ced032e6e45670b6d7352d71d21ce7edf7b9b928494dcaba6f11fba63180d9da6cd7061ebc34175ffda6ff529f481818c962952004d273178acd70f7059b320 - languageName: node - linkType: hard - -"regexpp@npm:^3.2.0": - version: 3.2.0 - resolution: "regexpp@npm:3.2.0" - checksum: a78dc5c7158ad9ddcfe01aa9144f46e192ddbfa7b263895a70a5c6c73edd9ce85faf7c0430e59ac38839e1734e275b9c3de5c57ee3ab6edc0e0b1bdebefccef8 - languageName: node - linkType: hard - -"release-zalgo@npm:^1.0.0": - version: 1.0.0 - resolution: "release-zalgo@npm:1.0.0" - dependencies: - es6-error: ^4.0.1 - checksum: b59849dc310f6c426f34e308c48ba83df3d034ddef75189951723bb2aac99d29d15f5e127edad951c4095fc9025aa582053907154d68fe0c5380cd6a75365e53 - languageName: node - linkType: hard - -"require-directory@npm:^2.1.1": - version: 2.1.1 - resolution: "require-directory@npm:2.1.1" - checksum: fb47e70bf0001fdeabdc0429d431863e9475e7e43ea5f94ad86503d918423c1543361cc5166d713eaa7029dd7a3d34775af04764bebff99ef413111a5af18c80 - languageName: node - linkType: hard - -"require-main-filename@npm:^2.0.0": - version: 2.0.0 - resolution: "require-main-filename@npm:2.0.0" - checksum: e9e294695fea08b076457e9ddff854e81bffbe248ed34c1eec348b7abbd22a0d02e8d75506559e2265e96978f3c4720bd77a6dad84755de8162b357eb6c778c7 - languageName: node - linkType: hard - -"resolve-from@npm:^4.0.0": - version: 4.0.0 - resolution: "resolve-from@npm:4.0.0" - checksum: f4ba0b8494846a5066328ad33ef8ac173801a51739eb4d63408c847da9a2e1c1de1e6cbbf72699211f3d13f8fc1325648b169bd15eb7da35688e30a5fb0e4a7f - languageName: node - linkType: hard - -"resolve-from@npm:^5.0.0": - version: 5.0.0 - resolution: "resolve-from@npm:5.0.0" - checksum: 4ceeb9113e1b1372d0cd969f3468fa042daa1dd9527b1b6bb88acb6ab55d8b9cd65dbf18819f9f9ddf0db804990901dcdaade80a215e7b2c23daae38e64f5bdf - languageName: node - linkType: hard - -"retry@npm:^0.12.0": - version: 0.12.0 - resolution: "retry@npm:0.12.0" - checksum: 623bd7d2e5119467ba66202d733ec3c2e2e26568074923bc0585b6b99db14f357e79bdedb63cab56cec47491c4a0da7e6021a7465ca6dc4f481d3898fdd3158c - languageName: node - linkType: hard - -"reusify@npm:^1.0.4": - version: 1.0.4 - resolution: "reusify@npm:1.0.4" - checksum: c3076ebcc22a6bc252cb0b9c77561795256c22b757f40c0d8110b1300723f15ec0fc8685e8d4ea6d7666f36c79ccc793b1939c748bf36f18f542744a4e379fcc - languageName: node - linkType: hard - -"rimraf@npm:^3.0.0, rimraf@npm:^3.0.2": - version: 3.0.2 - resolution: "rimraf@npm:3.0.2" - dependencies: - glob: ^7.1.3 - bin: - rimraf: bin.js - checksum: 87f4164e396f0171b0a3386cc1877a817f572148ee13a7e113b238e48e8a9f2f31d009a92ec38a591ff1567d9662c6b67fd8818a2dbbaed74bc26a87a2a4a9a0 - languageName: node - linkType: hard - -"run-parallel@npm:^1.1.9": - version: 1.2.0 - resolution: "run-parallel@npm:1.2.0" - dependencies: - queue-microtask: ^1.2.2 - checksum: cb4f97ad25a75ebc11a8ef4e33bb962f8af8516bb2001082ceabd8902e15b98f4b84b4f8a9b222e5d57fc3bd1379c483886ed4619367a7680dad65316993021d - languageName: node - linkType: hard - -"safe-buffer@npm:^5.1.0, safe-buffer@npm:~5.2.0": - version: 5.2.1 - resolution: "safe-buffer@npm:5.2.1" - checksum: b99c4b41fdd67a6aaf280fcd05e9ffb0813654894223afb78a31f14a19ad220bba8aba1cb14eddce1fcfb037155fe6de4e861784eb434f7d11ed58d1e70dd491 - languageName: node - linkType: hard - -"safe-buffer@npm:~5.1.1": - version: 5.1.2 - resolution: "safe-buffer@npm:5.1.2" - checksum: f2f1f7943ca44a594893a852894055cf619c1fbcb611237fc39e461ae751187e7baf4dc391a72125e0ac4fb2d8c5c0b3c71529622e6a58f46b960211e704903c - languageName: node - linkType: hard - -"safer-buffer@npm:>= 2.1.2 < 3.0.0": - version: 2.1.2 - resolution: "safer-buffer@npm:2.1.2" - checksum: cab8f25ae6f1434abee8d80023d7e72b598cf1327164ddab31003c51215526801e40b66c5e65d658a0af1e9d6478cadcb4c745f4bd6751f97d8644786c0978b0 - languageName: node - linkType: hard - -"semver@npm:^6.0.0, semver@npm:^6.3.0": - version: 6.3.0 - resolution: "semver@npm:6.3.0" - bin: - semver: ./bin/semver.js - checksum: 1b26ecf6db9e8292dd90df4e781d91875c0dcc1b1909e70f5d12959a23c7eebb8f01ea581c00783bbee72ceeaad9505797c381756326073850dc36ed284b21b9 - languageName: node - linkType: hard - -"semver@npm:^7.3.5": - version: 7.3.5 - resolution: "semver@npm:7.3.5" - dependencies: - lru-cache: ^6.0.0 - bin: - semver: bin/semver.js - checksum: 5eafe6102bea2a7439897c1856362e31cc348ccf96efd455c8b5bc2c61e6f7e7b8250dc26b8828c1d76a56f818a7ee907a36ae9fb37a599d3d24609207001d60 - languageName: node - linkType: hard - -"serialize-javascript@npm:6.0.0": - version: 6.0.0 - resolution: "serialize-javascript@npm:6.0.0" - dependencies: - randombytes: ^2.1.0 - checksum: 56f90b562a1bdc92e55afb3e657c6397c01a902c588c0fe3d4c490efdcc97dcd2a3074ba12df9e94630f33a5ce5b76a74784a7041294628a6f4306e0ec84bf93 - languageName: node - linkType: hard - -"set-blocking@npm:^2.0.0": - version: 2.0.0 - resolution: "set-blocking@npm:2.0.0" - checksum: 6e65a05f7cf7ebdf8b7c75b101e18c0b7e3dff4940d480efed8aad3a36a4005140b660fa1d804cb8bce911cac290441dc728084a30504d3516ac2ff7ad607b02 - languageName: node - linkType: hard - -"shebang-command@npm:^2.0.0": - version: 2.0.0 - resolution: "shebang-command@npm:2.0.0" - dependencies: - shebang-regex: ^3.0.0 - checksum: 6b52fe87271c12968f6a054e60f6bde5f0f3d2db483a1e5c3e12d657c488a15474121a1d55cd958f6df026a54374ec38a4a963988c213b7570e1d51575cea7fa - languageName: node - linkType: hard - -"shebang-regex@npm:^3.0.0": - version: 3.0.0 - resolution: "shebang-regex@npm:3.0.0" - checksum: 1a2bcae50de99034fcd92ad4212d8e01eedf52c7ec7830eedcf886622804fe36884278f2be8be0ea5fde3fd1c23911643a4e0f726c8685b61871c8908af01222 - languageName: node - linkType: hard - -"signal-exit@npm:^3.0.0, signal-exit@npm:^3.0.2": - version: 3.0.6 - resolution: "signal-exit@npm:3.0.6" - checksum: b819ac81ba757af559dad0804233ae31bf6f054591cd8a671e9cbcf09f21c72ec3076fe87d1e04861f5b33b47d63f0694b568de99c99cd733ee2060515beb6d5 - languageName: node - linkType: hard - -"sinon@npm:^7.3.2": - version: 7.5.0 - resolution: "sinon@npm:7.5.0" - dependencies: - "@sinonjs/commons": ^1.4.0 - "@sinonjs/formatio": ^3.2.1 - "@sinonjs/samsam": ^3.3.3 - diff: ^3.5.0 - lolex: ^4.2.0 - nise: ^1.5.2 - supports-color: ^5.5.0 - checksum: e8cf6b3dd16e9c1ed1a2b9560c396a2d6205a4f32293b1762cb6ebb8f88cfa47db6aba45b0c1709ec396efb41d171d88c9b1ab8f32f35512eb9e5d0d0d15d307 - languageName: node - linkType: hard - -"slash@npm:^3.0.0": - version: 3.0.0 - resolution: "slash@npm:3.0.0" - checksum: 94a93fff615f25a999ad4b83c9d5e257a7280c90a32a7cb8b4a87996e4babf322e469c42b7f649fd5796edd8687652f3fb452a86dc97a816f01113183393f11c - languageName: node - linkType: hard - -"smart-buffer@npm:^4.1.0": - version: 4.2.0 - resolution: "smart-buffer@npm:4.2.0" - checksum: b5167a7142c1da704c0e3af85c402002b597081dd9575031a90b4f229ca5678e9a36e8a374f1814c8156a725d17008ae3bde63b92f9cfd132526379e580bec8b - languageName: node - linkType: hard - -"socks-proxy-agent@npm:^6.0.0": - version: 6.1.1 - resolution: "socks-proxy-agent@npm:6.1.1" - dependencies: - agent-base: ^6.0.2 - debug: ^4.3.1 - socks: ^2.6.1 - checksum: 9a8a4f791bba0060315cf7291ca6f9db37d6fc280fd0860d73d8887d3efe4c22e823aa25a8d5375f6079279f8dc91b50c075345179bf832bfe3c7c26d3582e3c - languageName: node - linkType: hard - -"socks@npm:^2.6.1": - version: 2.6.1 - resolution: "socks@npm:2.6.1" - dependencies: - ip: ^1.1.5 - smart-buffer: ^4.1.0 - checksum: 2ca9d616e424f645838ebaabb04f85d94ea999e0f8393dc07f86c435af22ed88cb83958feeabd1bb7bc537c635ed47454255635502c6808a6df61af1f41af750 - languageName: node - linkType: hard - -"source-map@npm:^0.5.0": - version: 0.5.7 - resolution: "source-map@npm:0.5.7" - checksum: 5dc2043b93d2f194142c7f38f74a24670cd7a0063acdaf4bf01d2964b402257ae843c2a8fa822ad5b71013b5fcafa55af7421383da919752f22ff488bc553f4d - languageName: node - linkType: hard - -"source-map@npm:^0.6.1": - version: 0.6.1 - resolution: "source-map@npm:0.6.1" - checksum: 59ce8640cf3f3124f64ac289012c2b8bd377c238e316fb323ea22fbfe83da07d81e000071d7242cad7a23cd91c7de98e4df8830ec3f133cb6133a5f6e9f67bc2 - languageName: node - linkType: hard - -"spawn-wrap@npm:^2.0.0": - version: 2.0.0 - resolution: "spawn-wrap@npm:2.0.0" - dependencies: - foreground-child: ^2.0.0 - is-windows: ^1.0.2 - make-dir: ^3.0.0 - rimraf: ^3.0.0 - signal-exit: ^3.0.2 - which: ^2.0.1 - checksum: 5a518e37620def6d516b86207482a4f76bcf3c37c57d8d886d9fa399b04e5668d11fd12817b178029b02002a5ebbd09010374307effa821ba39594042f0a2d96 - languageName: node - linkType: hard - -"sprintf-js@npm:~1.0.2": - version: 1.0.3 - resolution: "sprintf-js@npm:1.0.3" - checksum: 19d79aec211f09b99ec3099b5b2ae2f6e9cdefe50bc91ac4c69144b6d3928a640bb6ae5b3def70c2e85a2c3d9f5ec2719921e3a59d3ca3ef4b2fd1a4656a0df3 - languageName: node - linkType: hard - -"ssri@npm:^8.0.0, ssri@npm:^8.0.1": - version: 8.0.1 - resolution: "ssri@npm:8.0.1" - dependencies: - minipass: ^3.1.1 - checksum: bc447f5af814fa9713aa201ec2522208ae0f4d8f3bda7a1f445a797c7b929a02720436ff7c478fb5edc4045adb02b1b88d2341b436a80798734e2494f1067b36 - languageName: node - linkType: hard - -"string-width@npm:^1.0.2 || 2 || 3 || 4, string-width@npm:^4.1.0, string-width@npm:^4.2.0, string-width@npm:^4.2.3": - version: 4.2.3 - resolution: "string-width@npm:4.2.3" - dependencies: - emoji-regex: ^8.0.0 - is-fullwidth-code-point: ^3.0.0 - strip-ansi: ^6.0.1 - checksum: e52c10dc3fbfcd6c3a15f159f54a90024241d0f149cf8aed2982a2d801d2e64df0bf1dc351cf8e95c3319323f9f220c16e740b06faecd53e2462df1d2b5443fb - languageName: node - linkType: hard - -"string_decoder@npm:^1.1.1": - version: 1.3.0 - resolution: "string_decoder@npm:1.3.0" - dependencies: - safe-buffer: ~5.2.0 - checksum: 8417646695a66e73aefc4420eb3b84cc9ffd89572861fe004e6aeb13c7bc00e2f616247505d2dbbef24247c372f70268f594af7126f43548565c68c117bdeb56 - languageName: node - linkType: hard - -"strip-ansi@npm:^6.0.0, strip-ansi@npm:^6.0.1": - version: 6.0.1 - resolution: "strip-ansi@npm:6.0.1" - dependencies: - ansi-regex: ^5.0.1 - checksum: f3cd25890aef3ba6e1a74e20896c21a46f482e93df4a06567cebf2b57edabb15133f1f94e57434e0a958d61186087b1008e89c94875d019910a213181a14fc8c - languageName: node - linkType: hard - -"strip-bom@npm:^4.0.0": - version: 4.0.0 - resolution: "strip-bom@npm:4.0.0" - checksum: 9dbcfbaf503c57c06af15fe2c8176fb1bf3af5ff65003851a102749f875a6dbe0ab3b30115eccf6e805e9d756830d3e40ec508b62b3f1ddf3761a20ebe29d3f3 - languageName: node - linkType: hard - -"strip-json-comments@npm:3.1.1, strip-json-comments@npm:^3.1.0, strip-json-comments@npm:^3.1.1": - version: 3.1.1 - resolution: "strip-json-comments@npm:3.1.1" - checksum: 492f73e27268f9b1c122733f28ecb0e7e8d8a531a6662efbd08e22cccb3f9475e90a1b82cab06a392f6afae6d2de636f977e231296400d0ec5304ba70f166443 - languageName: node - linkType: hard - -"supports-color@npm:8.1.1": - version: 8.1.1 - resolution: "supports-color@npm:8.1.1" - dependencies: - has-flag: ^4.0.0 - checksum: c052193a7e43c6cdc741eb7f378df605636e01ad434badf7324f17fb60c69a880d8d8fcdcb562cf94c2350e57b937d7425ab5b8326c67c2adc48f7c87c1db406 - languageName: node - linkType: hard - -"supports-color@npm:^5.3.0, supports-color@npm:^5.5.0": - version: 5.5.0 - resolution: "supports-color@npm:5.5.0" - dependencies: - has-flag: ^3.0.0 - checksum: 95f6f4ba5afdf92f495b5a912d4abee8dcba766ae719b975c56c084f5004845f6f5a5f7769f52d53f40e21952a6d87411bafe34af4a01e65f9926002e38e1dac - languageName: node - linkType: hard - -"supports-color@npm:^7.1.0": - version: 7.2.0 - resolution: "supports-color@npm:7.2.0" - dependencies: - has-flag: ^4.0.0 - checksum: 3dda818de06ebbe5b9653e07842d9479f3555ebc77e9a0280caf5a14fb877ffee9ed57007c3b78f5a6324b8dbeec648d9e97a24e2ed9fdb81ddc69ea07100f4a - languageName: node - linkType: hard - -"tar@npm:^6.0.2, tar@npm:^6.1.2": - version: 6.1.11 - resolution: "tar@npm:6.1.11" - dependencies: - chownr: ^2.0.0 - fs-minipass: ^2.0.0 - minipass: ^3.0.0 - minizlib: ^2.1.1 - mkdirp: ^1.0.3 - yallist: ^4.0.0 - checksum: a04c07bb9e2d8f46776517d4618f2406fb977a74d914ad98b264fc3db0fe8224da5bec11e5f8902c5b9bcb8ace22d95fbe3c7b36b8593b7dfc8391a25898f32f - languageName: node - linkType: hard - -"test-exclude@npm:^6.0.0": - version: 6.0.0 - resolution: "test-exclude@npm:6.0.0" - dependencies: - "@istanbuljs/schema": ^0.1.2 - glob: ^7.1.4 - minimatch: ^3.0.4 - checksum: 3b34a3d77165a2cb82b34014b3aba93b1c4637a5011807557dc2f3da826c59975a5ccad765721c4648b39817e3472789f9b0fa98fc854c5c1c7a1e632aacdc28 - languageName: node - linkType: hard - -"text-table@npm:^0.2.0": - version: 0.2.0 - resolution: "text-table@npm:0.2.0" - checksum: b6937a38c80c7f84d9c11dd75e49d5c44f71d95e810a3250bd1f1797fc7117c57698204adf676b71497acc205d769d65c16ae8fa10afad832ae1322630aef10a - languageName: node - linkType: hard - -"to-fast-properties@npm:^2.0.0": - version: 2.0.0 - resolution: "to-fast-properties@npm:2.0.0" - checksum: be2de62fe58ead94e3e592680052683b1ec986c72d589e7b21e5697f8744cdbf48c266fa72f6c15932894c10187b5f54573a3bcf7da0bfd964d5caf23d436168 - languageName: node - linkType: hard - -"to-regex-range@npm:^5.0.1": - version: 5.0.1 - resolution: "to-regex-range@npm:5.0.1" - dependencies: - is-number: ^7.0.0 - checksum: f76fa01b3d5be85db6a2a143e24df9f60dd047d151062d0ba3df62953f2f697b16fe5dad9b0ac6191c7efc7b1d9dcaa4b768174b7b29da89d4428e64bc0a20ed - languageName: node - linkType: hard - -"ts-node@npm:^10.4.0": - version: 10.4.0 - resolution: "ts-node@npm:10.4.0" - dependencies: - "@cspotcode/source-map-support": 0.7.0 - "@tsconfig/node10": ^1.0.7 - "@tsconfig/node12": ^1.0.7 - "@tsconfig/node14": ^1.0.0 - "@tsconfig/node16": ^1.0.2 - acorn: ^8.4.1 - acorn-walk: ^8.1.1 - arg: ^4.1.0 - create-require: ^1.1.0 - diff: ^4.0.1 - make-error: ^1.1.1 - yn: 3.1.1 - peerDependencies: - "@swc/core": ">=1.2.50" - "@swc/wasm": ">=1.2.50" - "@types/node": "*" - typescript: ">=2.7" - peerDependenciesMeta: - "@swc/core": - optional: true - "@swc/wasm": - optional: true - bin: - ts-node: dist/bin.js - ts-node-cwd: dist/bin-cwd.js - ts-node-script: dist/bin-script.js - ts-node-transpile-only: dist/bin-transpile.js - ts-script: dist/bin-script-deprecated.js - checksum: 3933ac0a937d33c45e04a6750fcdd3e765eb2897d1da1307cd97ac52af093bcfb632ec0453a75000a65c8b5b7bdb32b1077050a186dcc556e62657cb592e6d49 - languageName: node - linkType: hard - -"tslib@npm:^1.8.1": - version: 1.14.1 - resolution: "tslib@npm:1.14.1" - checksum: dbe628ef87f66691d5d2959b3e41b9ca0045c3ee3c7c7b906cc1e328b39f199bb1ad9e671c39025bd56122ac57dfbf7385a94843b1cc07c60a4db74795829acd - languageName: node - linkType: hard - -"tslib@npm:^2.3.1": - version: 2.3.1 - resolution: "tslib@npm:2.3.1" - checksum: de17a98d4614481f7fcb5cd53ffc1aaf8654313be0291e1bfaee4b4bb31a20494b7d218ff2e15017883e8ea9626599b3b0e0229c18383ba9dce89da2adf15cb9 - languageName: node - linkType: hard - -"tsutils@npm:^3.21.0": - version: 3.21.0 - resolution: "tsutils@npm:3.21.0" - dependencies: - tslib: ^1.8.1 - peerDependencies: - typescript: ">=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta" - checksum: 1843f4c1b2e0f975e08c4c21caa4af4f7f65a12ac1b81b3b8489366826259323feb3fc7a243123453d2d1a02314205a7634e048d4a8009921da19f99755cdc48 - languageName: node - linkType: hard - -"type-check@npm:^0.4.0, type-check@npm:~0.4.0": - version: 0.4.0 - resolution: "type-check@npm:0.4.0" - dependencies: - prelude-ls: ^1.2.1 - checksum: ec688ebfc9c45d0c30412e41ca9c0cdbd704580eb3a9ccf07b9b576094d7b86a012baebc95681999dd38f4f444afd28504cb3a89f2ef16b31d4ab61a0739025a - languageName: node - linkType: hard - -"type-detect@npm:4.0.8": - version: 4.0.8 - resolution: "type-detect@npm:4.0.8" - checksum: 62b5628bff67c0eb0b66afa371bd73e230399a8d2ad30d852716efcc4656a7516904570cd8631a49a3ce57c10225adf5d0cbdcb47f6b0255fe6557c453925a15 - languageName: node - linkType: hard - -"type-fest@npm:^0.20.2": - version: 0.20.2 - resolution: "type-fest@npm:0.20.2" - checksum: 4fb3272df21ad1c552486f8a2f8e115c09a521ad7a8db3d56d53718d0c907b62c6e9141ba5f584af3f6830d0872c521357e512381f24f7c44acae583ad517d73 - languageName: node - linkType: hard - -"type-fest@npm:^0.8.0": - version: 0.8.1 - resolution: "type-fest@npm:0.8.1" - checksum: d61c4b2eba24009033ae4500d7d818a94fd6d1b481a8111612ee141400d5f1db46f199c014766b9fa9b31a6a7374d96fc748c6d688a78a3ce5a33123839becb7 - languageName: node - linkType: hard - -"typedarray-to-buffer@npm:^3.1.5": - version: 3.1.5 - resolution: "typedarray-to-buffer@npm:3.1.5" - dependencies: - is-typedarray: ^1.0.0 - checksum: 99c11aaa8f45189fcfba6b8a4825fd684a321caa9bd7a76a27cf0c7732c174d198b99f449c52c3818107430b5f41c0ccbbfb75cb2ee3ca4a9451710986d61a60 - languageName: node - linkType: hard - -"typescript@npm:^4.5.3": - version: 4.5.5 - resolution: "typescript@npm:4.5.5" - bin: - tsc: bin/tsc - tsserver: bin/tsserver - checksum: 506f4c919dc8aeaafa92068c997f1d213b9df4d9756d0fae1a1e7ab66b585ab3498050e236113a1c9e57ee08c21ec6814ca7a7f61378c058d79af50a4b1f5a5e - languageName: node - linkType: hard - -"typescript@patch:typescript@^4.5.3#~builtin": - version: 4.5.5 - resolution: "typescript@patch:typescript@npm%3A4.5.5#~builtin::version=4.5.5&hash=493e53" - bin: - tsc: bin/tsc - tsserver: bin/tsserver - checksum: c05c318d79c690f101d7ffb34cd6c7d6bbd884d3af9cefe7749ad0cd6be43c7082f098280982ca945dcba23fde34a08fed9602bb26540936baf8c0520727d3ba - languageName: node - linkType: hard - -"unique-filename@npm:^1.1.1": - version: 1.1.1 - resolution: "unique-filename@npm:1.1.1" - dependencies: - unique-slug: ^2.0.0 - checksum: cf4998c9228cc7647ba7814e255dec51be43673903897b1786eff2ac2d670f54d4d733357eb08dea969aa5e6875d0e1bd391d668fbdb5a179744e7c7551a6f80 - languageName: node - linkType: hard - -"unique-slug@npm:^2.0.0": - version: 2.0.2 - resolution: "unique-slug@npm:2.0.2" - dependencies: - imurmurhash: ^0.1.4 - checksum: 5b6876a645da08d505dedb970d1571f6cebdf87044cb6b740c8dbb24f0d6e1dc8bdbf46825fd09f994d7cf50760e6f6e063cfa197d51c5902c00a861702eb75a - languageName: node - linkType: hard - -"uri-js@npm:^4.2.2": - version: 4.4.1 - resolution: "uri-js@npm:4.4.1" - dependencies: - punycode: ^2.1.0 - checksum: 7167432de6817fe8e9e0c9684f1d2de2bb688c94388f7569f7dbdb1587c9f4ca2a77962f134ec90be0cc4d004c939ff0d05acc9f34a0db39a3c797dada262633 - languageName: node - linkType: hard - -"util-deprecate@npm:^1.0.1": - version: 1.0.2 - resolution: "util-deprecate@npm:1.0.2" - checksum: 474acf1146cb2701fe3b074892217553dfcf9a031280919ba1b8d651a068c9b15d863b7303cb15bd00a862b498e6cf4ad7b4a08fb134edd5a6f7641681cb54a2 - languageName: node - linkType: hard - -"uuid@npm:^3.3.3": - version: 3.4.0 - resolution: "uuid@npm:3.4.0" - bin: - uuid: ./bin/uuid - checksum: 58de2feed61c59060b40f8203c0e4ed7fd6f99d42534a499f1741218a1dd0c129f4aa1de797bcf822c8ea5da7e4137aa3673431a96dae729047f7aca7b27866f - languageName: node - linkType: hard - -"v8-compile-cache@npm:^2.0.3": - version: 2.3.0 - resolution: "v8-compile-cache@npm:2.3.0" - checksum: adb0a271eaa2297f2f4c536acbfee872d0dd26ec2d76f66921aa7fc437319132773483344207bdbeee169225f4739016d8d2dbf0553913a52bb34da6d0334f8e - languageName: node - linkType: hard - -"which-module@npm:^2.0.0": - version: 2.0.0 - resolution: "which-module@npm:2.0.0" - checksum: 809f7fd3dfcb2cdbe0180b60d68100c88785084f8f9492b0998c051d7a8efe56784492609d3f09ac161635b78ea29219eb1418a98c15ce87d085bce905705c9c - languageName: node - linkType: hard - -"which@npm:2.0.2, which@npm:^2.0.1, which@npm:^2.0.2": - version: 2.0.2 - resolution: "which@npm:2.0.2" - dependencies: - isexe: ^2.0.0 - bin: - node-which: ./bin/node-which - checksum: 1a5c563d3c1b52d5f893c8b61afe11abc3bab4afac492e8da5bde69d550de701cf9806235f20a47b5c8fa8a1d6a9135841de2596535e998027a54589000e66d1 - languageName: node - linkType: hard - -"wide-align@npm:^1.1.2": - version: 1.1.5 - resolution: "wide-align@npm:1.1.5" - dependencies: - string-width: ^1.0.2 || 2 || 3 || 4 - checksum: d5fc37cd561f9daee3c80e03b92ed3e84d80dde3365a8767263d03dacfc8fa06b065ffe1df00d8c2a09f731482fcacae745abfbb478d4af36d0a891fad4834d3 - languageName: node - linkType: hard - -"word-wrap@npm:^1.2.3": - version: 1.2.3 - resolution: "word-wrap@npm:1.2.3" - checksum: 30b48f91fcf12106ed3186ae4fa86a6a1842416df425be7b60485de14bec665a54a68e4b5156647dec3a70f25e84d270ca8bc8cd23182ed095f5c7206a938c1f - languageName: node - linkType: hard - -"workerpool@npm:6.2.0": - version: 6.2.0 - resolution: "workerpool@npm:6.2.0" - checksum: 3493b4f0ef979a23d2c1583d7ef85f62fc9463cc02f82829d3e7e663b517f8ae9707da0249b382e46ac58986deb0ca2232ee1081713741211bda9254b429c9bb - languageName: node - linkType: hard - -"wrap-ansi@npm:^6.2.0": - version: 6.2.0 - resolution: "wrap-ansi@npm:6.2.0" - dependencies: - ansi-styles: ^4.0.0 - string-width: ^4.1.0 - strip-ansi: ^6.0.0 - checksum: 6cd96a410161ff617b63581a08376f0cb9162375adeb7956e10c8cd397821f7eb2a6de24eb22a0b28401300bf228c86e50617cd568209b5f6775b93c97d2fe3a - languageName: node - linkType: hard - -"wrap-ansi@npm:^7.0.0": - version: 7.0.0 - resolution: "wrap-ansi@npm:7.0.0" - dependencies: - ansi-styles: ^4.0.0 - string-width: ^4.1.0 - strip-ansi: ^6.0.0 - checksum: a790b846fd4505de962ba728a21aaeda189b8ee1c7568ca5e817d85930e06ef8d1689d49dbf0e881e8ef84436af3a88bc49115c2e2788d841ff1b8b5b51a608b - languageName: node - linkType: hard - -"wrappy@npm:1": - version: 1.0.2 - resolution: "wrappy@npm:1.0.2" - checksum: 159da4805f7e84a3d003d8841557196034155008f817172d4e986bd591f74aa82aa7db55929a54222309e01079a65a92a9e6414da5a6aa4b01ee44a511ac3ee5 - languageName: node - linkType: hard - -"write-file-atomic@npm:^3.0.0": - version: 3.0.3 - resolution: "write-file-atomic@npm:3.0.3" - dependencies: - imurmurhash: ^0.1.4 - is-typedarray: ^1.0.0 - signal-exit: ^3.0.2 - typedarray-to-buffer: ^3.1.5 - checksum: c55b24617cc61c3a4379f425fc62a386cc51916a9b9d993f39734d005a09d5a4bb748bc251f1304e7abd71d0a26d339996c275955f527a131b1dcded67878280 - languageName: node - linkType: hard - -"y18n@npm:^4.0.0": - version: 4.0.3 - resolution: "y18n@npm:4.0.3" - checksum: 014dfcd9b5f4105c3bb397c1c8c6429a9df004aa560964fb36732bfb999bfe83d45ae40aeda5b55d21b1ee53d8291580a32a756a443e064317953f08025b1aa4 - languageName: node - linkType: hard - -"y18n@npm:^5.0.5": - version: 5.0.8 - resolution: "y18n@npm:5.0.8" - checksum: 54f0fb95621ee60898a38c572c515659e51cc9d9f787fb109cef6fde4befbe1c4602dc999d30110feee37456ad0f1660fa2edcfde6a9a740f86a290999550d30 - languageName: node - linkType: hard - -"yallist@npm:^4.0.0": - version: 4.0.0 - resolution: "yallist@npm:4.0.0" - checksum: 343617202af32df2a15a3be36a5a8c0c8545208f3d3dfbc6bb7c3e3b7e8c6f8e7485432e4f3b88da3031a6e20afa7c711eded32ddfb122896ac5d914e75848d5 - languageName: node - linkType: hard - -"yargs-parser@npm:20.2.4": - version: 20.2.4 - resolution: "yargs-parser@npm:20.2.4" - checksum: d251998a374b2743a20271c2fd752b9fbef24eb881d53a3b99a7caa5e8227fcafd9abf1f345ac5de46435821be25ec12189a11030c12ee6481fef6863ed8b924 - languageName: node - linkType: hard - -"yargs-parser@npm:^18.1.2": - version: 18.1.3 - resolution: "yargs-parser@npm:18.1.3" - dependencies: - camelcase: ^5.0.0 - decamelize: ^1.2.0 - checksum: 60e8c7d1b85814594d3719300ecad4e6ae3796748b0926137bfec1f3042581b8646d67e83c6fc80a692ef08b8390f21ddcacb9464476c39bbdf52e34961dd4d9 - languageName: node - linkType: hard - -"yargs-parser@npm:^20.2.2": - version: 20.2.9 - resolution: "yargs-parser@npm:20.2.9" - checksum: 8bb69015f2b0ff9e17b2c8e6bfe224ab463dd00ca211eece72a4cd8a906224d2703fb8a326d36fdd0e68701e201b2a60ed7cf81ce0fd9b3799f9fe7745977ae3 - languageName: node - linkType: hard - -"yargs-unparser@npm:2.0.0": - version: 2.0.0 - resolution: "yargs-unparser@npm:2.0.0" - dependencies: - camelcase: ^6.0.0 - decamelize: ^4.0.0 - flat: ^5.0.2 - is-plain-obj: ^2.1.0 - checksum: 68f9a542c6927c3768c2f16c28f71b19008710abd6b8f8efbac6dcce26bbb68ab6503bed1d5994bdbc2df9a5c87c161110c1dfe04c6a3fe5c6ad1b0e15d9a8a3 - languageName: node - linkType: hard - -"yargs@npm:16.2.0": - version: 16.2.0 - resolution: "yargs@npm:16.2.0" - dependencies: - cliui: ^7.0.2 - escalade: ^3.1.1 - get-caller-file: ^2.0.5 - require-directory: ^2.1.1 - string-width: ^4.2.0 - y18n: ^5.0.5 - yargs-parser: ^20.2.2 - checksum: b14afbb51e3251a204d81937c86a7e9d4bdbf9a2bcee38226c900d00f522969ab675703bee2a6f99f8e20103f608382936034e64d921b74df82b63c07c5e8f59 - languageName: node - linkType: hard - -"yargs@npm:^15.0.2": - version: 15.4.1 - resolution: "yargs@npm:15.4.1" - dependencies: - cliui: ^6.0.0 - decamelize: ^1.2.0 - find-up: ^4.1.0 - get-caller-file: ^2.0.1 - require-directory: ^2.1.1 - require-main-filename: ^2.0.0 - set-blocking: ^2.0.0 - string-width: ^4.2.0 - which-module: ^2.0.0 - y18n: ^4.0.0 - yargs-parser: ^18.1.2 - checksum: 40b974f508d8aed28598087720e086ecd32a5fd3e945e95ea4457da04ee9bdb8bdd17fd91acff36dc5b7f0595a735929c514c40c402416bbb87c03f6fb782373 - languageName: node - linkType: hard - -"yn@npm:3.1.1": - version: 3.1.1 - resolution: "yn@npm:3.1.1" - checksum: 2c487b0e149e746ef48cda9f8bad10fc83693cd69d7f9dcd8be4214e985de33a29c9e24f3c0d6bcf2288427040a8947406ab27f7af67ee9456e6b84854f02dd6 - languageName: node - linkType: hard - -"yocto-queue@npm:^0.1.0": - version: 0.1.0 - resolution: "yocto-queue@npm:0.1.0" - checksum: f77b3d8d00310def622123df93d4ee654fc6a0096182af8bd60679ddcdfb3474c56c6c7190817c84a2785648cdee9d721c0154eb45698c62176c322fb46fc700 - languageName: node - linkType: hard +# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. +# yarn lockfile v1 + + +"@ampproject/remapping@^2.0.0": + "version" "2.1.0" + dependencies: + "@jridgewell/trace-mapping" "^0.3.0" + +"@babel/code-frame@^7.16.7": + "version" "7.16.7" + dependencies: + "@babel/highlight" "^7.16.7" + +"@babel/compat-data@^7.16.4": + "version" "7.17.0" + +"@babel/core@^7.0.0", "@babel/core@^7.7.5": + "version" "7.17.2" + dependencies: + "@ampproject/remapping" "^2.0.0" + "@babel/code-frame" "^7.16.7" + "@babel/generator" "^7.17.0" + "@babel/helper-compilation-targets" "^7.16.7" + "@babel/helper-module-transforms" "^7.16.7" + "@babel/helpers" "^7.17.2" + "@babel/parser" "^7.17.0" + "@babel/template" "^7.16.7" + "@babel/traverse" "^7.17.0" + "@babel/types" "^7.17.0" + "convert-source-map" "^1.7.0" + "debug" "^4.1.0" + "gensync" "^1.0.0-beta.2" + "json5" "^2.1.2" + "semver" "^6.3.0" + +"@babel/generator@^7.17.0": + "version" "7.17.0" + dependencies: + "@babel/types" "^7.17.0" + "jsesc" "^2.5.1" + "source-map" "^0.5.0" + +"@babel/helper-compilation-targets@^7.16.7": + "version" "7.16.7" + dependencies: + "@babel/compat-data" "^7.16.4" + "@babel/helper-validator-option" "^7.16.7" + "browserslist" "^4.17.5" + "semver" "^6.3.0" + +"@babel/helper-environment-visitor@^7.16.7": + "version" "7.16.7" + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-function-name@^7.16.7": + "version" "7.16.7" + dependencies: + "@babel/helper-get-function-arity" "^7.16.7" + "@babel/template" "^7.16.7" + "@babel/types" "^7.16.7" + +"@babel/helper-get-function-arity@^7.16.7": + "version" "7.16.7" + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-hoist-variables@^7.16.7": + "version" "7.16.7" + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-module-imports@^7.16.7": + "version" "7.16.7" + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-module-transforms@^7.16.7": + "version" "7.16.7" + dependencies: + "@babel/helper-environment-visitor" "^7.16.7" + "@babel/helper-module-imports" "^7.16.7" + "@babel/helper-simple-access" "^7.16.7" + "@babel/helper-split-export-declaration" "^7.16.7" + "@babel/helper-validator-identifier" "^7.16.7" + "@babel/template" "^7.16.7" + "@babel/traverse" "^7.16.7" + "@babel/types" "^7.16.7" + +"@babel/helper-simple-access@^7.16.7": + "version" "7.16.7" + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-split-export-declaration@^7.16.7": + "version" "7.16.7" + dependencies: + "@babel/types" "^7.16.7" + +"@babel/helper-validator-identifier@^7.16.7": + "version" "7.16.7" + +"@babel/helper-validator-option@^7.16.7": + "version" "7.16.7" + +"@babel/helpers@^7.17.2": + "version" "7.17.2" + dependencies: + "@babel/template" "^7.16.7" + "@babel/traverse" "^7.17.0" + "@babel/types" "^7.17.0" + +"@babel/highlight@^7.16.7": + "version" "7.16.10" + dependencies: + "@babel/helper-validator-identifier" "^7.16.7" + "chalk" "^2.0.0" + "js-tokens" "^4.0.0" + +"@babel/parser@^7.16.7", "@babel/parser@^7.17.0": + "version" "7.17.0" + +"@babel/template@^7.16.7": + "version" "7.16.7" + dependencies: + "@babel/code-frame" "^7.16.7" + "@babel/parser" "^7.16.7" + "@babel/types" "^7.16.7" + +"@babel/traverse@^7.16.7", "@babel/traverse@^7.17.0": + "version" "7.17.0" + dependencies: + "@babel/code-frame" "^7.16.7" + "@babel/generator" "^7.17.0" + "@babel/helper-environment-visitor" "^7.16.7" + "@babel/helper-function-name" "^7.16.7" + "@babel/helper-hoist-variables" "^7.16.7" + "@babel/helper-split-export-declaration" "^7.16.7" + "@babel/parser" "^7.17.0" + "@babel/types" "^7.17.0" + "debug" "^4.1.0" + "globals" "^11.1.0" + +"@babel/types@^7.16.7", "@babel/types@^7.17.0": + "version" "7.17.0" + dependencies: + "@babel/helper-validator-identifier" "^7.16.7" + "to-fast-properties" "^2.0.0" + +"@cspotcode/source-map-consumer@0.8.0": + "version" "0.8.0" + +"@cspotcode/source-map-support@0.7.0": + "version" "0.7.0" + dependencies: + "@cspotcode/source-map-consumer" "0.8.0" + +"@eslint/eslintrc@^1.0.5": + "version" "1.0.5" + dependencies: + "ajv" "^6.12.4" + "debug" "^4.3.2" + "espree" "^9.2.0" + "globals" "^13.9.0" + "ignore" "^4.0.6" + "import-fresh" "^3.2.1" + "js-yaml" "^4.1.0" + "minimatch" "^3.0.4" + "strip-json-comments" "^3.1.1" + +"@gar/promisify@^1.0.1": + "version" "1.1.2" + +"@humanwhocodes/config-array@^0.9.2": + "version" "0.9.3" + dependencies: + "@humanwhocodes/object-schema" "^1.2.1" + "debug" "^4.1.1" + "minimatch" "^3.0.4" + +"@humanwhocodes/object-schema@^1.2.1": + "version" "1.2.1" + +"@istanbuljs/load-nyc-config@^1.0.0": + "version" "1.1.0" + dependencies: + "camelcase" "^5.3.1" + "find-up" "^4.1.0" + "get-package-type" "^0.1.0" + "js-yaml" "^3.13.1" + "resolve-from" "^5.0.0" + +"@istanbuljs/nyc-config-typescript@^1.0.2": + "version" "1.0.2" + dependencies: + "@istanbuljs/schema" "^0.1.2" + +"@istanbuljs/schema@^0.1.2": + "version" "0.1.3" + +"@jridgewell/resolve-uri@^3.0.3": + "version" "3.0.4" + +"@jridgewell/sourcemap-codec@^1.4.10": + "version" "1.4.10" + +"@jridgewell/trace-mapping@^0.3.0": + "version" "0.3.2" + dependencies: + "@jridgewell/resolve-uri" "^3.0.3" + "@jridgewell/sourcemap-codec" "^1.4.10" + +"@nodelib/fs.scandir@2.1.5": + "version" "2.1.5" + dependencies: + "@nodelib/fs.stat" "2.0.5" + "run-parallel" "^1.1.9" + +"@nodelib/fs.stat@^2.0.2", "@nodelib/fs.stat@2.0.5": + "version" "2.0.5" + +"@nodelib/fs.walk@^1.2.3": + "version" "1.2.8" + dependencies: + "@nodelib/fs.scandir" "2.1.5" + "fastq" "^1.6.0" + +"@npmcli/fs@^1.0.0": + "version" "1.1.0" + dependencies: + "@gar/promisify" "^1.0.1" + "semver" "^7.3.5" + +"@npmcli/move-file@^1.0.1": + "version" "1.1.2" + dependencies: + "mkdirp" "^1.0.4" + "rimraf" "^3.0.2" + +"@sinonjs/commons@^1", "@sinonjs/commons@^1.3.0", "@sinonjs/commons@^1.4.0", "@sinonjs/commons@^1.7.0": + "version" "1.8.3" + dependencies: + "type-detect" "4.0.8" + +"@sinonjs/formatio@^3.2.1": + "version" "3.2.2" + dependencies: + "@sinonjs/commons" "^1" + "@sinonjs/samsam" "^3.1.0" + +"@sinonjs/samsam@^3.1.0", "@sinonjs/samsam@^3.3.3": + "version" "3.3.3" + dependencies: + "@sinonjs/commons" "^1.3.0" + "array-from" "^2.1.1" + "lodash" "^4.17.15" + +"@sinonjs/text-encoding@^0.7.1": + "version" "0.7.1" + +"@tootallnate/once@1": + "version" "1.1.2" + +"@tsconfig/node10@^1.0.7": + "version" "1.0.8" + +"@tsconfig/node12@^1.0.7": + "version" "1.0.9" + +"@tsconfig/node14@^1.0.0": + "version" "1.0.1" + +"@tsconfig/node16@^1.0.2": + "version" "1.0.2" + +"@types/json-schema@^7.0.9": + "version" "7.0.9" + +"@types/lodash@^4.14.176": + "version" "4.14.178" + +"@types/mocha@^9.1.0": + "version" "9.1.0" + +"@types/node@*", "@types/node@^16.11.6": + "version" "16.11.22" + +"@types/sinon@^10.0.6": + "version" "10.0.11" + dependencies: + "@types/sinonjs__fake-timers" "*" + +"@types/sinonjs__fake-timers@*": + "version" "8.1.1" + +"@typescript-eslint/eslint-plugin@^5.7.0": + "version" "5.11.0" + dependencies: + "@typescript-eslint/scope-manager" "5.11.0" + "@typescript-eslint/type-utils" "5.11.0" + "@typescript-eslint/utils" "5.11.0" + "debug" "^4.3.2" + "functional-red-black-tree" "^1.0.1" + "ignore" "^5.1.8" + "regexpp" "^3.2.0" + "semver" "^7.3.5" + "tsutils" "^3.21.0" + +"@typescript-eslint/parser@^5.0.0", "@typescript-eslint/parser@^5.7.0": + "version" "5.11.0" + dependencies: + "@typescript-eslint/scope-manager" "5.11.0" + "@typescript-eslint/types" "5.11.0" + "@typescript-eslint/typescript-estree" "5.11.0" + "debug" "^4.3.2" + +"@typescript-eslint/scope-manager@5.11.0": + "version" "5.11.0" + dependencies: + "@typescript-eslint/types" "5.11.0" + "@typescript-eslint/visitor-keys" "5.11.0" + +"@typescript-eslint/type-utils@5.11.0": + "version" "5.11.0" + dependencies: + "@typescript-eslint/utils" "5.11.0" + "debug" "^4.3.2" + "tsutils" "^3.21.0" + +"@typescript-eslint/types@5.11.0": + "version" "5.11.0" + +"@typescript-eslint/typescript-estree@5.11.0": + "version" "5.11.0" + dependencies: + "@typescript-eslint/types" "5.11.0" + "@typescript-eslint/visitor-keys" "5.11.0" + "debug" "^4.3.2" + "globby" "^11.0.4" + "is-glob" "^4.0.3" + "semver" "^7.3.5" + "tsutils" "^3.21.0" + +"@typescript-eslint/utils@5.11.0": + "version" "5.11.0" + dependencies: + "@types/json-schema" "^7.0.9" + "@typescript-eslint/scope-manager" "5.11.0" + "@typescript-eslint/types" "5.11.0" + "@typescript-eslint/typescript-estree" "5.11.0" + "eslint-scope" "^5.1.1" + "eslint-utils" "^3.0.0" + +"@typescript-eslint/visitor-keys@5.11.0": + "version" "5.11.0" + dependencies: + "@typescript-eslint/types" "5.11.0" + "eslint-visitor-keys" "^3.0.0" + +"@ungap/promise-all-settled@1.1.2": + "version" "1.1.2" + +"abbrev@1": + "version" "1.1.1" + +"acorn-jsx@^5.3.1": + "version" "5.3.2" + +"acorn-walk@^8.1.1": + "version" "8.2.0" + +"acorn@^6.0.0 || ^7.0.0 || ^8.0.0", "acorn@^8.4.1", "acorn@^8.7.0": + "version" "8.7.0" + +"agent-base@^6.0.2", "agent-base@6": + "version" "6.0.2" + dependencies: + "debug" "4" + +"agentkeepalive@^4.1.3": + "version" "4.2.0" + dependencies: + "debug" "^4.1.0" + "depd" "^1.1.2" + "humanize-ms" "^1.2.1" + +"aggregate-error@^3.0.0": + "version" "3.1.0" + dependencies: + "clean-stack" "^2.0.0" + "indent-string" "^4.0.0" + +"ajv@^6.10.0", "ajv@^6.12.4": + "version" "6.12.6" + dependencies: + "fast-deep-equal" "^3.1.1" + "fast-json-stable-stringify" "^2.0.0" + "json-schema-traverse" "^0.4.1" + "uri-js" "^4.2.2" + +"ansi-colors@4.1.1": + "version" "4.1.1" + +"ansi-regex@^5.0.1": + "version" "5.0.1" + +"ansi-styles@^3.2.1": + "version" "3.2.1" + dependencies: + "color-convert" "^1.9.0" + +"ansi-styles@^4.0.0", "ansi-styles@^4.1.0": + "version" "4.3.0" + dependencies: + "color-convert" "^2.0.1" + +"anymatch@~3.1.2": + "version" "3.1.2" + dependencies: + "normalize-path" "^3.0.0" + "picomatch" "^2.0.4" + +"append-transform@^2.0.0": + "version" "2.0.0" + dependencies: + "default-require-extensions" "^3.0.0" + +"aproba@^1.0.3 || ^2.0.0": + "version" "2.0.0" + +"archy@^1.0.0": + "version" "1.0.0" + +"are-we-there-yet@^2.0.0": + "version" "2.0.0" + dependencies: + "delegates" "^1.0.0" + "readable-stream" "^3.6.0" + +"arg@^4.1.0": + "version" "4.1.3" + +"argparse@^1.0.7": + "version" "1.0.10" + dependencies: + "sprintf-js" "~1.0.2" + +"argparse@^2.0.1": + "version" "2.0.1" + +"array-from@^2.1.1": + "version" "2.1.1" + +"array-union@^2.1.0": + "version" "2.1.0" + +"axios@^0.24.0": + "version" "0.24.0" + dependencies: + "follow-redirects" "^1.14.4" + +"balanced-match@^1.0.0": + "version" "1.0.2" + +"binary-extensions@^2.0.0": + "version" "2.2.0" + +"brace-expansion@^1.1.7": + "version" "1.1.11" + dependencies: + "balanced-match" "^1.0.0" + "concat-map" "0.0.1" + +"braces@^3.0.1", "braces@~3.0.2": + "version" "3.0.2" + dependencies: + "fill-range" "^7.0.1" + +"browser-stdout@1.3.1": + "version" "1.3.1" + +"browserslist@^4.17.5": + "version" "4.19.1" + dependencies: + "caniuse-lite" "^1.0.30001286" + "electron-to-chromium" "^1.4.17" + "escalade" "^3.1.1" + "node-releases" "^2.0.1" + "picocolors" "^1.0.0" + +"cacache@^15.2.0": + "version" "15.3.0" + dependencies: + "@npmcli/fs" "^1.0.0" + "@npmcli/move-file" "^1.0.1" + "chownr" "^2.0.0" + "fs-minipass" "^2.0.0" + "glob" "^7.1.4" + "infer-owner" "^1.0.4" + "lru-cache" "^6.0.0" + "minipass" "^3.1.1" + "minipass-collect" "^1.0.2" + "minipass-flush" "^1.0.5" + "minipass-pipeline" "^1.2.2" + "mkdirp" "^1.0.3" + "p-map" "^4.0.0" + "promise-inflight" "^1.0.1" + "rimraf" "^3.0.2" + "ssri" "^8.0.1" + "tar" "^6.0.2" + "unique-filename" "^1.1.1" + +"caching-transform@^4.0.0": + "version" "4.0.0" + dependencies: + "hasha" "^5.0.0" + "make-dir" "^3.0.0" + "package-hash" "^4.0.0" + "write-file-atomic" "^3.0.0" + +"callsites@^3.0.0": + "version" "3.1.0" + +"camelcase@^5.0.0", "camelcase@^5.3.1": + "version" "5.3.1" + +"camelcase@^6.0.0": + "version" "6.3.0" + +"caniuse-lite@^1.0.30001286": + "version" "1.0.30001309" + +"chalk@^2.0.0": + "version" "2.4.2" + dependencies: + "ansi-styles" "^3.2.1" + "escape-string-regexp" "^1.0.5" + "supports-color" "^5.3.0" + +"chalk@^4.0.0", "chalk@^4.1.0": + "version" "4.1.2" + dependencies: + "ansi-styles" "^4.1.0" + "supports-color" "^7.1.0" + +"chokidar@3.5.3": + "version" "3.5.3" + dependencies: + "anymatch" "~3.1.2" + "braces" "~3.0.2" + "glob-parent" "~5.1.2" + "is-binary-path" "~2.1.0" + "is-glob" "~4.0.1" + "normalize-path" "~3.0.0" + "readdirp" "~3.6.0" + optionalDependencies: + "fsevents" "~2.3.2" + +"chownr@^2.0.0": + "version" "2.0.0" + +"clean-stack@^2.0.0": + "version" "2.2.0" + +"cliui@^6.0.0": + "version" "6.0.0" + dependencies: + "string-width" "^4.2.0" + "strip-ansi" "^6.0.0" + "wrap-ansi" "^6.2.0" + +"cliui@^7.0.2": + "version" "7.0.4" + dependencies: + "string-width" "^4.2.0" + "strip-ansi" "^6.0.0" + "wrap-ansi" "^7.0.0" + +"color-convert@^1.9.0": + "version" "1.9.3" + dependencies: + "color-name" "1.1.3" + +"color-convert@^2.0.1": + "version" "2.0.1" + dependencies: + "color-name" "~1.1.4" + +"color-name@~1.1.4": + "version" "1.1.4" + +"color-name@1.1.3": + "version" "1.1.3" + +"color-support@^1.1.2": + "version" "1.1.3" + +"commondir@^1.0.1": + "version" "1.0.1" + +"concat-map@0.0.1": + "version" "0.0.1" + +"console-control-strings@^1.0.0", "console-control-strings@^1.1.0": + "version" "1.1.0" + +"convert-source-map@^1.7.0": + "version" "1.8.0" + dependencies: + "safe-buffer" "~5.1.1" + +"create-require@^1.1.0": + "version" "1.1.1" + +"cross-spawn@^7.0.0", "cross-spawn@^7.0.2": + "version" "7.0.3" + dependencies: + "path-key" "^3.1.0" + "shebang-command" "^2.0.0" + "which" "^2.0.1" + +"debug@^4.1.0", "debug@^4.1.1", "debug@^4.3.1", "debug@^4.3.2", "debug@4", "debug@4.3.3": + "version" "4.3.3" + dependencies: + "ms" "2.1.2" + +"decamelize@^1.2.0": + "version" "1.2.0" + +"decamelize@^4.0.0": + "version" "4.0.0" + +"deep-is@^0.1.3": + "version" "0.1.4" + +"default-require-extensions@^3.0.0": + "version" "3.0.0" + dependencies: + "strip-bom" "^4.0.0" + +"delegates@^1.0.0": + "version" "1.0.0" + +"depd@^1.1.2": + "version" "1.1.2" + +"diff@^3.5.0": + "version" "3.5.0" + +"diff@^4.0.1": + "version" "4.0.2" + +"diff@5.0.0": + "version" "5.0.0" + +"dir-glob@^3.0.1": + "version" "3.0.1" + dependencies: + "path-type" "^4.0.0" + +"doctrine@^3.0.0": + "version" "3.0.0" + dependencies: + "esutils" "^2.0.2" + +"electron-to-chromium@^1.4.17": + "version" "1.4.66" + +"emoji-regex@^8.0.0": + "version" "8.0.0" + +"encoding@^0.1.12": + "version" "0.1.13" + dependencies: + "iconv-lite" "^0.6.2" + +"env-paths@^2.2.0": + "version" "2.2.1" + +"err-code@^2.0.2": + "version" "2.0.3" + +"es6-error@^4.0.1": + "version" "4.1.1" + +"escalade@^3.1.1": + "version" "3.1.1" + +"escape-string-regexp@^1.0.5": + "version" "1.0.5" + +"escape-string-regexp@^4.0.0", "escape-string-regexp@4.0.0": + "version" "4.0.0" + +"eslint-config-prettier@^8.3.0": + "version" "8.3.0" + +"eslint-scope@^5.1.1": + "version" "5.1.1" + dependencies: + "esrecurse" "^4.3.0" + "estraverse" "^4.1.1" + +"eslint-scope@^7.1.0": + "version" "7.1.0" + dependencies: + "esrecurse" "^4.3.0" + "estraverse" "^5.2.0" + +"eslint-utils@^3.0.0": + "version" "3.0.0" + dependencies: + "eslint-visitor-keys" "^2.0.0" + +"eslint-visitor-keys@^2.0.0": + "version" "2.1.0" + +"eslint-visitor-keys@^3.0.0", "eslint-visitor-keys@^3.1.0", "eslint-visitor-keys@^3.2.0": + "version" "3.2.0" + +"eslint@*", "eslint@^6.0.0 || ^7.0.0 || ^8.0.0", "eslint@^8.2.0", "eslint@>=5", "eslint@>=7.0.0": + "version" "8.8.0" + dependencies: + "@eslint/eslintrc" "^1.0.5" + "@humanwhocodes/config-array" "^0.9.2" + "ajv" "^6.10.0" + "chalk" "^4.0.0" + "cross-spawn" "^7.0.2" + "debug" "^4.3.2" + "doctrine" "^3.0.0" + "escape-string-regexp" "^4.0.0" + "eslint-scope" "^7.1.0" + "eslint-utils" "^3.0.0" + "eslint-visitor-keys" "^3.2.0" + "espree" "^9.3.0" + "esquery" "^1.4.0" + "esutils" "^2.0.2" + "fast-deep-equal" "^3.1.3" + "file-entry-cache" "^6.0.1" + "functional-red-black-tree" "^1.0.1" + "glob-parent" "^6.0.1" + "globals" "^13.6.0" + "ignore" "^5.2.0" + "import-fresh" "^3.0.0" + "imurmurhash" "^0.1.4" + "is-glob" "^4.0.0" + "js-yaml" "^4.1.0" + "json-stable-stringify-without-jsonify" "^1.0.1" + "levn" "^0.4.1" + "lodash.merge" "^4.6.2" + "minimatch" "^3.0.4" + "natural-compare" "^1.4.0" + "optionator" "^0.9.1" + "regexpp" "^3.2.0" + "strip-ansi" "^6.0.1" + "strip-json-comments" "^3.1.0" + "text-table" "^0.2.0" + "v8-compile-cache" "^2.0.3" + +"espree@^9.2.0", "espree@^9.3.0": + "version" "9.3.0" + dependencies: + "acorn" "^8.7.0" + "acorn-jsx" "^5.3.1" + "eslint-visitor-keys" "^3.1.0" + +"esprima@^4.0.0": + "version" "4.0.1" + +"esquery@^1.4.0": + "version" "1.4.0" + dependencies: + "estraverse" "^5.1.0" + +"esrecurse@^4.3.0": + "version" "4.3.0" + dependencies: + "estraverse" "^5.2.0" + +"estraverse@^4.1.1": + "version" "4.3.0" + +"estraverse@^5.1.0", "estraverse@^5.2.0": + "version" "5.3.0" + +"esutils@^2.0.2": + "version" "2.0.3" + +"fast-deep-equal@^3.1.1", "fast-deep-equal@^3.1.3": + "version" "3.1.3" + +"fast-glob@^3.2.9": + "version" "3.2.11" + dependencies: + "@nodelib/fs.stat" "^2.0.2" + "@nodelib/fs.walk" "^1.2.3" + "glob-parent" "^5.1.2" + "merge2" "^1.3.0" + "micromatch" "^4.0.4" + +"fast-json-stable-stringify@^2.0.0": + "version" "2.1.0" + +"fast-levenshtein@^2.0.6": + "version" "2.0.6" + +"fastq@^1.6.0": + "version" "1.13.0" + dependencies: + "reusify" "^1.0.4" + +"file-entry-cache@^6.0.1": + "version" "6.0.1" + dependencies: + "flat-cache" "^3.0.4" + +"fill-range@^7.0.1": + "version" "7.0.1" + dependencies: + "to-regex-range" "^5.0.1" + +"find-cache-dir@^3.2.0": + "version" "3.3.2" + dependencies: + "commondir" "^1.0.1" + "make-dir" "^3.0.2" + "pkg-dir" "^4.1.0" + +"find-up@^4.0.0", "find-up@^4.1.0": + "version" "4.1.0" + dependencies: + "locate-path" "^5.0.0" + "path-exists" "^4.0.0" + +"find-up@5.0.0": + "version" "5.0.0" + dependencies: + "locate-path" "^6.0.0" + "path-exists" "^4.0.0" + +"flat-cache@^3.0.4": + "version" "3.0.4" + dependencies: + "flatted" "^3.1.0" + "rimraf" "^3.0.2" + +"flat@^5.0.2": + "version" "5.0.2" + +"flatted@^3.1.0": + "version" "3.2.5" + +"follow-redirects@^1.14.4": + "version" "1.14.8" + +"foreground-child@^2.0.0": + "version" "2.0.0" + dependencies: + "cross-spawn" "^7.0.0" + "signal-exit" "^3.0.2" + +"fromentries@^1.2.0": + "version" "1.3.2" + +"fs-minipass@^2.0.0": + "version" "2.1.0" + dependencies: + "minipass" "^3.0.0" + +"fs.realpath@^1.0.0": + "version" "1.0.0" + +"fsevents@~2.3.2": + "version" "2.3.2" + +"functional-red-black-tree@^1.0.1": + "version" "1.0.1" + +"gauge@^4.0.0": + "version" "4.0.0" + dependencies: + "ansi-regex" "^5.0.1" + "aproba" "^1.0.3 || ^2.0.0" + "color-support" "^1.1.2" + "console-control-strings" "^1.0.0" + "has-unicode" "^2.0.1" + "signal-exit" "^3.0.0" + "string-width" "^4.2.3" + "strip-ansi" "^6.0.1" + "wide-align" "^1.1.2" + +"gensync@^1.0.0-beta.2": + "version" "1.0.0-beta.2" + +"get-caller-file@^2.0.1", "get-caller-file@^2.0.5": + "version" "2.0.5" + +"get-package-type@^0.1.0": + "version" "0.1.0" + +"glob-parent@^5.1.2", "glob-parent@~5.1.2": + "version" "5.1.2" + dependencies: + "is-glob" "^4.0.1" + +"glob-parent@^6.0.1": + "version" "6.0.2" + dependencies: + "is-glob" "^4.0.3" + +"glob@^7.1.3", "glob@^7.1.4", "glob@^7.1.6", "glob@7.2.0": + "version" "7.2.0" + dependencies: + "fs.realpath" "^1.0.0" + "inflight" "^1.0.4" + "inherits" "2" + "minimatch" "^3.0.4" + "once" "^1.3.0" + "path-is-absolute" "^1.0.0" + +"globals@^11.1.0": + "version" "11.12.0" + +"globals@^13.6.0", "globals@^13.9.0": + "version" "13.12.1" + dependencies: + "type-fest" "^0.20.2" + +"globby@^11.0.4": + "version" "11.1.0" + dependencies: + "array-union" "^2.1.0" + "dir-glob" "^3.0.1" + "fast-glob" "^3.2.9" + "ignore" "^5.2.0" + "merge2" "^1.4.1" + "slash" "^3.0.0" + +"graceful-fs@^4.1.15", "graceful-fs@^4.2.6": + "version" "4.2.9" + +"growl@1.10.5": + "version" "1.10.5" + +"has-flag@^3.0.0": + "version" "3.0.0" + +"has-flag@^4.0.0": + "version" "4.0.0" + +"has-unicode@^2.0.1": + "version" "2.0.1" + +"hasha@^5.0.0": + "version" "5.2.2" + dependencies: + "is-stream" "^2.0.0" + "type-fest" "^0.8.0" + +"he@1.2.0": + "version" "1.2.0" + +"html-escaper@^2.0.0": + "version" "2.0.2" + +"htmlencode@^0.0.4": + "version" "0.0.4" + +"http-cache-semantics@^4.1.0": + "version" "4.1.0" + +"http-proxy-agent@^4.0.1": + "version" "4.0.1" + dependencies: + "@tootallnate/once" "1" + "agent-base" "6" + "debug" "4" + +"https-proxy-agent@^5.0.0": + "version" "5.0.0" + dependencies: + "agent-base" "6" + "debug" "4" + +"humanize-ms@^1.2.1": + "version" "1.2.1" + dependencies: + "ms" "^2.0.0" + +"iconv-lite@^0.6.2": + "version" "0.6.3" + dependencies: + "safer-buffer" ">= 2.1.2 < 3.0.0" + +"ignore@^4.0.6": + "version" "4.0.6" + +"ignore@^5.1.8", "ignore@^5.2.0": + "version" "5.2.0" + +"import-fresh@^3.0.0", "import-fresh@^3.2.1": + "version" "3.3.0" + dependencies: + "parent-module" "^1.0.0" + "resolve-from" "^4.0.0" + +"imurmurhash@^0.1.4": + "version" "0.1.4" + +"indent-string@^4.0.0": + "version" "4.0.0" + +"infer-owner@^1.0.4": + "version" "1.0.4" + +"inflight@^1.0.4": + "version" "1.0.6" + dependencies: + "once" "^1.3.0" + "wrappy" "1" + +"inherits@^2.0.3", "inherits@2": + "version" "2.0.4" + +"intercom-client@file:": + "resolved" "file:" + "version" "3.1.0" + dependencies: + "axios" "^0.24.0" + "htmlencode" "^0.0.4" + "intercom-client" "file:" + "lodash" "^4.17.21" + +"ip@^1.1.5": + "version" "1.1.5" + +"is-binary-path@~2.1.0": + "version" "2.1.0" + dependencies: + "binary-extensions" "^2.0.0" + +"is-extglob@^2.1.1": + "version" "2.1.1" + +"is-fullwidth-code-point@^3.0.0": + "version" "3.0.0" + +"is-glob@^4.0.0", "is-glob@^4.0.1", "is-glob@^4.0.3", "is-glob@~4.0.1": + "version" "4.0.3" + dependencies: + "is-extglob" "^2.1.1" + +"is-lambda@^1.0.1": + "version" "1.0.1" + +"is-number@^7.0.0": + "version" "7.0.0" + +"is-plain-obj@^2.1.0": + "version" "2.1.0" + +"is-stream@^2.0.0": + "version" "2.0.1" + +"is-typedarray@^1.0.0": + "version" "1.0.0" + +"is-unicode-supported@^0.1.0": + "version" "0.1.0" + +"is-windows@^1.0.2": + "version" "1.0.2" + +"isarray@0.0.1": + "version" "0.0.1" + +"isexe@^2.0.0": + "version" "2.0.0" + +"istanbul-lib-coverage@^3.0.0", "istanbul-lib-coverage@^3.0.0-alpha.1": + "version" "3.2.0" + +"istanbul-lib-hook@^3.0.0": + "version" "3.0.0" + dependencies: + "append-transform" "^2.0.0" + +"istanbul-lib-instrument@^4.0.0": + "version" "4.0.3" + dependencies: + "@babel/core" "^7.7.5" + "@istanbuljs/schema" "^0.1.2" + "istanbul-lib-coverage" "^3.0.0" + "semver" "^6.3.0" + +"istanbul-lib-processinfo@^2.0.2": + "version" "2.0.2" + dependencies: + "archy" "^1.0.0" + "cross-spawn" "^7.0.0" + "istanbul-lib-coverage" "^3.0.0-alpha.1" + "make-dir" "^3.0.0" + "p-map" "^3.0.0" + "rimraf" "^3.0.0" + "uuid" "^3.3.3" + +"istanbul-lib-report@^3.0.0": + "version" "3.0.0" + dependencies: + "istanbul-lib-coverage" "^3.0.0" + "make-dir" "^3.0.0" + "supports-color" "^7.1.0" + +"istanbul-lib-source-maps@^4.0.0": + "version" "4.0.1" + dependencies: + "debug" "^4.1.1" + "istanbul-lib-coverage" "^3.0.0" + "source-map" "^0.6.1" + +"istanbul-reports@^3.0.2": + "version" "3.1.4" + dependencies: + "html-escaper" "^2.0.0" + "istanbul-lib-report" "^3.0.0" + +"js-tokens@^4.0.0": + "version" "4.0.0" + +"js-yaml@^3.13.1": + "version" "3.14.1" + dependencies: + "argparse" "^1.0.7" + "esprima" "^4.0.0" + +"js-yaml@^4.1.0", "js-yaml@4.1.0": + "version" "4.1.0" + dependencies: + "argparse" "^2.0.1" + +"jsesc@^2.5.1": + "version" "2.5.2" + +"json-schema-traverse@^0.4.1": + "version" "0.4.1" + +"json-stable-stringify-without-jsonify@^1.0.1": + "version" "1.0.1" + +"json-stringify-safe@^5.0.1": + "version" "5.0.1" + +"json5@^2.1.2": + "version" "2.2.0" + dependencies: + "minimist" "^1.2.5" + +"just-extend@^4.0.2": + "version" "4.2.1" + +"levn@^0.4.1": + "version" "0.4.1" + dependencies: + "prelude-ls" "^1.2.1" + "type-check" "~0.4.0" + +"locate-path@^5.0.0": + "version" "5.0.0" + dependencies: + "p-locate" "^4.1.0" + +"locate-path@^6.0.0": + "version" "6.0.0" + dependencies: + "p-locate" "^5.0.0" + +"lodash.flattendeep@^4.4.0": + "version" "4.4.0" + +"lodash.merge@^4.6.2": + "version" "4.6.2" + +"lodash.set@^4.3.2": + "version" "4.3.2" + +"lodash@^4.17.15", "lodash@^4.17.21": + "version" "4.17.21" + +"log-symbols@4.1.0": + "version" "4.1.0" + dependencies: + "chalk" "^4.1.0" + "is-unicode-supported" "^0.1.0" + +"lolex@^4.2.0": + "version" "4.2.0" + +"lolex@^5.0.1": + "version" "5.1.2" + dependencies: + "@sinonjs/commons" "^1.7.0" + +"lru-cache@^6.0.0": + "version" "6.0.0" + dependencies: + "yallist" "^4.0.0" + +"make-dir@^3.0.0", "make-dir@^3.0.2": + "version" "3.1.0" + dependencies: + "semver" "^6.0.0" + +"make-error@^1.1.1": + "version" "1.3.6" + +"make-fetch-happen@^9.1.0": + "version" "9.1.0" + dependencies: + "agentkeepalive" "^4.1.3" + "cacache" "^15.2.0" + "http-cache-semantics" "^4.1.0" + "http-proxy-agent" "^4.0.1" + "https-proxy-agent" "^5.0.0" + "is-lambda" "^1.0.1" + "lru-cache" "^6.0.0" + "minipass" "^3.1.3" + "minipass-collect" "^1.0.2" + "minipass-fetch" "^1.3.2" + "minipass-flush" "^1.0.5" + "minipass-pipeline" "^1.2.4" + "negotiator" "^0.6.2" + "promise-retry" "^2.0.1" + "socks-proxy-agent" "^6.0.0" + "ssri" "^8.0.0" + +"merge2@^1.3.0", "merge2@^1.4.1": + "version" "1.4.1" + +"micromatch@^4.0.4": + "version" "4.0.4" + dependencies: + "braces" "^3.0.1" + "picomatch" "^2.2.3" + +"minimatch@^3.0.4": + "version" "3.0.5" + dependencies: + "brace-expansion" "^1.1.7" + +"minimatch@3.0.4": + "version" "3.0.4" + dependencies: + "brace-expansion" "^1.1.7" + +"minimist@^1.2.5": + "version" "1.2.5" + +"minipass-collect@^1.0.2": + "version" "1.0.2" + dependencies: + "minipass" "^3.0.0" + +"minipass-fetch@^1.3.2": + "version" "1.4.1" + dependencies: + "minipass" "^3.1.0" + "minipass-sized" "^1.0.3" + "minizlib" "^2.0.0" + optionalDependencies: + "encoding" "^0.1.12" + +"minipass-flush@^1.0.5": + "version" "1.0.5" + dependencies: + "minipass" "^3.0.0" + +"minipass-pipeline@^1.2.2", "minipass-pipeline@^1.2.4": + "version" "1.2.4" + dependencies: + "minipass" "^3.0.0" + +"minipass-sized@^1.0.3": + "version" "1.0.3" + dependencies: + "minipass" "^3.0.0" + +"minipass@^3.0.0", "minipass@^3.1.0", "minipass@^3.1.1", "minipass@^3.1.3": + "version" "3.1.6" + dependencies: + "yallist" "^4.0.0" + +"minizlib@^2.0.0", "minizlib@^2.1.1": + "version" "2.1.2" + dependencies: + "minipass" "^3.0.0" + "yallist" "^4.0.0" + +"mkdirp@^1.0.3", "mkdirp@^1.0.4": + "version" "1.0.4" + +"mocha@^9.2.0": + "version" "9.2.0" + dependencies: + "@ungap/promise-all-settled" "1.1.2" + "ansi-colors" "4.1.1" + "browser-stdout" "1.3.1" + "chokidar" "3.5.3" + "debug" "4.3.3" + "diff" "5.0.0" + "escape-string-regexp" "4.0.0" + "find-up" "5.0.0" + "glob" "7.2.0" + "growl" "1.10.5" + "he" "1.2.0" + "js-yaml" "4.1.0" + "log-symbols" "4.1.0" + "minimatch" "3.0.4" + "ms" "2.1.3" + "nanoid" "3.2.0" + "serialize-javascript" "6.0.0" + "strip-json-comments" "3.1.1" + "supports-color" "8.1.1" + "which" "2.0.2" + "workerpool" "6.2.0" + "yargs" "16.2.0" + "yargs-parser" "20.2.4" + "yargs-unparser" "2.0.0" + +"ms@^2.0.0", "ms@2.1.3": + "version" "2.1.3" + +"ms@2.1.2": + "version" "2.1.2" + +"nanoid@3.2.0": + "version" "3.2.0" + +"natural-compare@^1.4.0": + "version" "1.4.0" + +"negotiator@^0.6.2": + "version" "0.6.3" + +"nise@^1.5.2": + "version" "1.5.3" + dependencies: + "@sinonjs/formatio" "^3.2.1" + "@sinonjs/text-encoding" "^0.7.1" + "just-extend" "^4.0.2" + "lolex" "^5.0.1" + "path-to-regexp" "^1.7.0" + +"nock@^13.0.11": + "version" "13.2.4" + dependencies: + "debug" "^4.1.0" + "json-stringify-safe" "^5.0.1" + "lodash.set" "^4.3.2" + "propagate" "^2.0.0" + +"node-preload@^0.2.1": + "version" "0.2.1" + dependencies: + "process-on-spawn" "^1.0.0" + +"node-releases@^2.0.1": + "version" "2.0.2" + +"nopt@^5.0.0": + "version" "5.0.0" + dependencies: + "abbrev" "1" + +"normalize-path@^3.0.0", "normalize-path@~3.0.0": + "version" "3.0.0" + +"npmlog@^6.0.0": + "version" "6.0.0" + dependencies: + "are-we-there-yet" "^2.0.0" + "console-control-strings" "^1.1.0" + "gauge" "^4.0.0" + "set-blocking" "^2.0.0" + +"nyc@^15.1.0", "nyc@>=15": + "version" "15.1.0" + dependencies: + "@istanbuljs/load-nyc-config" "^1.0.0" + "@istanbuljs/schema" "^0.1.2" + "caching-transform" "^4.0.0" + "convert-source-map" "^1.7.0" + "decamelize" "^1.2.0" + "find-cache-dir" "^3.2.0" + "find-up" "^4.1.0" + "foreground-child" "^2.0.0" + "get-package-type" "^0.1.0" + "glob" "^7.1.6" + "istanbul-lib-coverage" "^3.0.0" + "istanbul-lib-hook" "^3.0.0" + "istanbul-lib-instrument" "^4.0.0" + "istanbul-lib-processinfo" "^2.0.2" + "istanbul-lib-report" "^3.0.0" + "istanbul-lib-source-maps" "^4.0.0" + "istanbul-reports" "^3.0.2" + "make-dir" "^3.0.0" + "node-preload" "^0.2.1" + "p-map" "^3.0.0" + "process-on-spawn" "^1.0.0" + "resolve-from" "^5.0.0" + "rimraf" "^3.0.0" + "signal-exit" "^3.0.2" + "spawn-wrap" "^2.0.0" + "test-exclude" "^6.0.0" + "yargs" "^15.0.2" + +"once@^1.3.0": + "version" "1.4.0" + dependencies: + "wrappy" "1" + +"optionator@^0.9.1": + "version" "0.9.1" + dependencies: + "deep-is" "^0.1.3" + "fast-levenshtein" "^2.0.6" + "levn" "^0.4.1" + "prelude-ls" "^1.2.1" + "type-check" "^0.4.0" + "word-wrap" "^1.2.3" + +"p-limit@^2.2.0": + "version" "2.3.0" + dependencies: + "p-try" "^2.0.0" + +"p-limit@^3.0.2": + "version" "3.1.0" + dependencies: + "yocto-queue" "^0.1.0" + +"p-locate@^4.1.0": + "version" "4.1.0" + dependencies: + "p-limit" "^2.2.0" + +"p-locate@^5.0.0": + "version" "5.0.0" + dependencies: + "p-limit" "^3.0.2" + +"p-map@^3.0.0": + "version" "3.0.0" + dependencies: + "aggregate-error" "^3.0.0" + +"p-map@^4.0.0": + "version" "4.0.0" + dependencies: + "aggregate-error" "^3.0.0" + +"p-try@^2.0.0": + "version" "2.2.0" + +"package-hash@^4.0.0": + "version" "4.0.0" + dependencies: + "graceful-fs" "^4.1.15" + "hasha" "^5.0.0" + "lodash.flattendeep" "^4.4.0" + "release-zalgo" "^1.0.0" + +"parent-module@^1.0.0": + "version" "1.0.1" + dependencies: + "callsites" "^3.0.0" + +"path-exists@^4.0.0": + "version" "4.0.0" + +"path-is-absolute@^1.0.0": + "version" "1.0.1" + +"path-key@^3.1.0": + "version" "3.1.1" + +"path-to-regexp@^1.7.0": + "version" "1.8.0" + dependencies: + "isarray" "0.0.1" + +"path-type@^4.0.0": + "version" "4.0.0" + +"picocolors@^1.0.0": + "version" "1.0.0" + +"picomatch@^2.0.4", "picomatch@^2.2.1", "picomatch@^2.2.3": + "version" "2.3.1" + +"pkg-dir@^4.1.0": + "version" "4.2.0" + dependencies: + "find-up" "^4.0.0" + +"prelude-ls@^1.2.1": + "version" "1.2.1" + +"prettier@^2.5.1": + "version" "2.5.1" + +"process-on-spawn@^1.0.0": + "version" "1.0.0" + dependencies: + "fromentries" "^1.2.0" + +"promise-inflight@^1.0.1": + "version" "1.0.1" + +"promise-retry@^2.0.1": + "version" "2.0.1" + dependencies: + "err-code" "^2.0.2" + "retry" "^0.12.0" + +"propagate@^2.0.0": + "version" "2.0.1" + +"punycode@^2.1.0": + "version" "2.1.1" + +"queue-microtask@^1.2.2": + "version" "1.2.3" + +"randombytes@^2.1.0": + "version" "2.1.0" + dependencies: + "safe-buffer" "^5.1.0" + +"readable-stream@^3.6.0": + "version" "3.6.0" + dependencies: + "inherits" "^2.0.3" + "string_decoder" "^1.1.1" + "util-deprecate" "^1.0.1" + +"readdirp@~3.6.0": + "version" "3.6.0" + dependencies: + "picomatch" "^2.2.1" + +"regexpp@^3.2.0": + "version" "3.2.0" + +"release-zalgo@^1.0.0": + "version" "1.0.0" + dependencies: + "es6-error" "^4.0.1" + +"require-directory@^2.1.1": + "version" "2.1.1" + +"require-main-filename@^2.0.0": + "version" "2.0.0" + +"resolve-from@^4.0.0": + "version" "4.0.0" + +"resolve-from@^5.0.0": + "version" "5.0.0" + +"retry@^0.12.0": + "version" "0.12.0" + +"reusify@^1.0.4": + "version" "1.0.4" + +"rimraf@^3.0.0", "rimraf@^3.0.2": + "version" "3.0.2" + dependencies: + "glob" "^7.1.3" + +"run-parallel@^1.1.9": + "version" "1.2.0" + dependencies: + "queue-microtask" "^1.2.2" + +"safe-buffer@^5.1.0", "safe-buffer@~5.2.0": + "version" "5.2.1" + +"safe-buffer@~5.1.1": + "version" "5.1.2" + +"safer-buffer@>= 2.1.2 < 3.0.0": + "version" "2.1.2" + +"semver@^6.0.0": + "version" "6.3.0" + +"semver@^6.3.0": + "version" "6.3.0" + +"semver@^7.3.5": + "version" "7.3.5" + dependencies: + "lru-cache" "^6.0.0" + +"serialize-javascript@6.0.0": + "version" "6.0.0" + dependencies: + "randombytes" "^2.1.0" + +"set-blocking@^2.0.0": + "version" "2.0.0" + +"shebang-command@^2.0.0": + "version" "2.0.0" + dependencies: + "shebang-regex" "^3.0.0" + +"shebang-regex@^3.0.0": + "version" "3.0.0" + +"signal-exit@^3.0.0", "signal-exit@^3.0.2": + "version" "3.0.7" + +"sinon@^7.3.2": + "version" "7.5.0" + dependencies: + "@sinonjs/commons" "^1.4.0" + "@sinonjs/formatio" "^3.2.1" + "@sinonjs/samsam" "^3.3.3" + "diff" "^3.5.0" + "lolex" "^4.2.0" + "nise" "^1.5.2" + "supports-color" "^5.5.0" + +"slash@^3.0.0": + "version" "3.0.0" + +"smart-buffer@^4.2.0": + "version" "4.2.0" + +"socks-proxy-agent@^6.0.0": + "version" "6.1.1" + dependencies: + "agent-base" "^6.0.2" + "debug" "^4.3.1" + "socks" "^2.6.1" + +"socks@^2.6.1": + "version" "2.6.2" + dependencies: + "ip" "^1.1.5" + "smart-buffer" "^4.2.0" + +"source-map@^0.5.0": + "version" "0.5.7" + +"source-map@^0.6.1": + "version" "0.6.1" + +"spawn-wrap@^2.0.0": + "version" "2.0.0" + dependencies: + "foreground-child" "^2.0.0" + "is-windows" "^1.0.2" + "make-dir" "^3.0.0" + "rimraf" "^3.0.0" + "signal-exit" "^3.0.2" + "which" "^2.0.1" + +"sprintf-js@~1.0.2": + "version" "1.0.3" + +"ssri@^8.0.0", "ssri@^8.0.1": + "version" "8.0.1" + dependencies: + "minipass" "^3.1.1" + +"string_decoder@^1.1.1": + "version" "1.3.0" + dependencies: + "safe-buffer" "~5.2.0" + +"string-width@^1.0.2 || 2 || 3 || 4", "string-width@^4.1.0", "string-width@^4.2.0", "string-width@^4.2.3": + "version" "4.2.3" + dependencies: + "emoji-regex" "^8.0.0" + "is-fullwidth-code-point" "^3.0.0" + "strip-ansi" "^6.0.1" + +"strip-ansi@^6.0.0", "strip-ansi@^6.0.1": + "version" "6.0.1" + dependencies: + "ansi-regex" "^5.0.1" + +"strip-bom@^4.0.0": + "version" "4.0.0" + +"strip-json-comments@^3.1.0", "strip-json-comments@^3.1.1", "strip-json-comments@3.1.1": + "version" "3.1.1" + +"supports-color@^5.3.0": + "version" "5.5.0" + dependencies: + "has-flag" "^3.0.0" + +"supports-color@^5.5.0": + "version" "5.5.0" + dependencies: + "has-flag" "^3.0.0" + +"supports-color@^7.1.0": + "version" "7.2.0" + dependencies: + "has-flag" "^4.0.0" + +"supports-color@8.1.1": + "version" "8.1.1" + dependencies: + "has-flag" "^4.0.0" + +"tar@^6.0.2", "tar@^6.1.2": + "version" "6.1.11" + dependencies: + "chownr" "^2.0.0" + "fs-minipass" "^2.0.0" + "minipass" "^3.0.0" + "minizlib" "^2.1.1" + "mkdirp" "^1.0.3" + "yallist" "^4.0.0" + +"test-exclude@^6.0.0": + "version" "6.0.0" + dependencies: + "@istanbuljs/schema" "^0.1.2" + "glob" "^7.1.4" + "minimatch" "^3.0.4" + +"text-table@^0.2.0": + "version" "0.2.0" + +"to-fast-properties@^2.0.0": + "version" "2.0.0" + +"to-regex-range@^5.0.1": + "version" "5.0.1" + dependencies: + "is-number" "^7.0.0" + +"ts-node@^10.4.0": + "version" "10.5.0" + dependencies: + "@cspotcode/source-map-support" "0.7.0" + "@tsconfig/node10" "^1.0.7" + "@tsconfig/node12" "^1.0.7" + "@tsconfig/node14" "^1.0.0" + "@tsconfig/node16" "^1.0.2" + "acorn" "^8.4.1" + "acorn-walk" "^8.1.1" + "arg" "^4.1.0" + "create-require" "^1.1.0" + "diff" "^4.0.1" + "make-error" "^1.1.1" + "v8-compile-cache-lib" "^3.0.0" + "yn" "3.1.1" + +"tslib@^1.8.1": + "version" "1.14.1" + +"tslib@^2.3.1": + "version" "2.3.1" + +"tsutils@^3.21.0": + "version" "3.21.0" + dependencies: + "tslib" "^1.8.1" + +"type-check@^0.4.0", "type-check@~0.4.0": + "version" "0.4.0" + dependencies: + "prelude-ls" "^1.2.1" + +"type-detect@4.0.8": + "version" "4.0.8" + +"type-fest@^0.20.2": + "version" "0.20.2" + +"type-fest@^0.8.0": + "version" "0.8.1" + +"typedarray-to-buffer@^3.1.5": + "version" "3.1.5" + dependencies: + "is-typedarray" "^1.0.0" + +"typescript@^4.5.3", "typescript@>=2.7", "typescript@>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta": + "version" "4.5.5" + +"unique-filename@^1.1.1": + "version" "1.1.1" + dependencies: + "unique-slug" "^2.0.0" + +"unique-slug@^2.0.0": + "version" "2.0.2" + dependencies: + "imurmurhash" "^0.1.4" + +"uri-js@^4.2.2": + "version" "4.4.1" + dependencies: + "punycode" "^2.1.0" + +"util-deprecate@^1.0.1": + "version" "1.0.2" + +"uuid@^3.3.3": + "version" "3.4.0" + +"v8-compile-cache-lib@^3.0.0": + "version" "3.0.0" + +"v8-compile-cache@^2.0.3": + "version" "2.3.0" + +"which-module@^2.0.0": + "version" "2.0.0" + +"which@^2.0.1", "which@^2.0.2", "which@2.0.2": + "version" "2.0.2" + dependencies: + "isexe" "^2.0.0" + +"wide-align@^1.1.2": + "version" "1.1.5" + dependencies: + "string-width" "^1.0.2 || 2 || 3 || 4" + +"word-wrap@^1.2.3": + "version" "1.2.3" + +"workerpool@6.2.0": + "version" "6.2.0" + +"wrap-ansi@^6.2.0": + "version" "6.2.0" + dependencies: + "ansi-styles" "^4.0.0" + "string-width" "^4.1.0" + "strip-ansi" "^6.0.0" + +"wrap-ansi@^7.0.0": + "version" "7.0.0" + dependencies: + "ansi-styles" "^4.0.0" + "string-width" "^4.1.0" + "strip-ansi" "^6.0.0" + +"wrappy@1": + "version" "1.0.2" + +"write-file-atomic@^3.0.0": + "version" "3.0.3" + dependencies: + "imurmurhash" "^0.1.4" + "is-typedarray" "^1.0.0" + "signal-exit" "^3.0.2" + "typedarray-to-buffer" "^3.1.5" + +"y18n@^4.0.0": + "version" "4.0.3" + +"y18n@^5.0.5": + "version" "5.0.8" + +"yallist@^4.0.0": + "version" "4.0.0" + +"yargs-parser@^18.1.2": + "version" "18.1.3" + dependencies: + "camelcase" "^5.0.0" + "decamelize" "^1.2.0" + +"yargs-parser@^20.2.2": + "version" "20.2.9" + +"yargs-parser@20.2.4": + "version" "20.2.4" + +"yargs-unparser@2.0.0": + "version" "2.0.0" + dependencies: + "camelcase" "^6.0.0" + "decamelize" "^4.0.0" + "flat" "^5.0.2" + "is-plain-obj" "^2.1.0" + +"yargs@^15.0.2": + "version" "15.4.1" + dependencies: + "cliui" "^6.0.0" + "decamelize" "^1.2.0" + "find-up" "^4.1.0" + "get-caller-file" "^2.0.1" + "require-directory" "^2.1.1" + "require-main-filename" "^2.0.0" + "set-blocking" "^2.0.0" + "string-width" "^4.2.0" + "which-module" "^2.0.0" + "y18n" "^4.0.0" + "yargs-parser" "^18.1.2" + +"yargs@16.2.0": + "version" "16.2.0" + dependencies: + "cliui" "^7.0.2" + "escalade" "^3.1.1" + "get-caller-file" "^2.0.5" + "require-directory" "^2.1.1" + "string-width" "^4.2.0" + "y18n" "^5.0.5" + "yargs-parser" "^20.2.2" + +"yn@3.1.1": + "version" "3.1.1" + +"yocto-queue@^0.1.0": + "version" "0.1.0" From ed30193e18405a7f92972e317a9b6af1bc3f23c3 Mon Sep 17 00:00:00 2001 From: Volo Date: Tue, 8 Feb 2022 20:17:46 +0200 Subject: [PATCH 049/146] Bump patch version --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index b0f4e51d..30096afd 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.1.0", + "version": "3.1.1", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", From 2ff8de2d14a7498ba5905932dbc42ce632e5cfad Mon Sep 17 00:00:00 2001 From: Volo Date: Tue, 8 Feb 2022 20:19:10 +0200 Subject: [PATCH 050/146] Update yarn.lock --- yarn.lock | 5568 ++++++++++++++++++++++++++++++++++------------------- 1 file changed, 3636 insertions(+), 1932 deletions(-) diff --git a/yarn.lock b/yarn.lock index 5f52b85d..7ede0102 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1,1932 +1,3636 @@ -# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. -# yarn lockfile v1 - - -"@ampproject/remapping@^2.0.0": - "version" "2.1.0" - dependencies: - "@jridgewell/trace-mapping" "^0.3.0" - -"@babel/code-frame@^7.16.7": - "version" "7.16.7" - dependencies: - "@babel/highlight" "^7.16.7" - -"@babel/compat-data@^7.16.4": - "version" "7.17.0" - -"@babel/core@^7.0.0", "@babel/core@^7.7.5": - "version" "7.17.2" - dependencies: - "@ampproject/remapping" "^2.0.0" - "@babel/code-frame" "^7.16.7" - "@babel/generator" "^7.17.0" - "@babel/helper-compilation-targets" "^7.16.7" - "@babel/helper-module-transforms" "^7.16.7" - "@babel/helpers" "^7.17.2" - "@babel/parser" "^7.17.0" - "@babel/template" "^7.16.7" - "@babel/traverse" "^7.17.0" - "@babel/types" "^7.17.0" - "convert-source-map" "^1.7.0" - "debug" "^4.1.0" - "gensync" "^1.0.0-beta.2" - "json5" "^2.1.2" - "semver" "^6.3.0" - -"@babel/generator@^7.17.0": - "version" "7.17.0" - dependencies: - "@babel/types" "^7.17.0" - "jsesc" "^2.5.1" - "source-map" "^0.5.0" - -"@babel/helper-compilation-targets@^7.16.7": - "version" "7.16.7" - dependencies: - "@babel/compat-data" "^7.16.4" - "@babel/helper-validator-option" "^7.16.7" - "browserslist" "^4.17.5" - "semver" "^6.3.0" - -"@babel/helper-environment-visitor@^7.16.7": - "version" "7.16.7" - dependencies: - "@babel/types" "^7.16.7" - -"@babel/helper-function-name@^7.16.7": - "version" "7.16.7" - dependencies: - "@babel/helper-get-function-arity" "^7.16.7" - "@babel/template" "^7.16.7" - "@babel/types" "^7.16.7" - -"@babel/helper-get-function-arity@^7.16.7": - "version" "7.16.7" - dependencies: - "@babel/types" "^7.16.7" - -"@babel/helper-hoist-variables@^7.16.7": - "version" "7.16.7" - dependencies: - "@babel/types" "^7.16.7" - -"@babel/helper-module-imports@^7.16.7": - "version" "7.16.7" - dependencies: - "@babel/types" "^7.16.7" - -"@babel/helper-module-transforms@^7.16.7": - "version" "7.16.7" - dependencies: - "@babel/helper-environment-visitor" "^7.16.7" - "@babel/helper-module-imports" "^7.16.7" - "@babel/helper-simple-access" "^7.16.7" - "@babel/helper-split-export-declaration" "^7.16.7" - "@babel/helper-validator-identifier" "^7.16.7" - "@babel/template" "^7.16.7" - "@babel/traverse" "^7.16.7" - "@babel/types" "^7.16.7" - -"@babel/helper-simple-access@^7.16.7": - "version" "7.16.7" - dependencies: - "@babel/types" "^7.16.7" - -"@babel/helper-split-export-declaration@^7.16.7": - "version" "7.16.7" - dependencies: - "@babel/types" "^7.16.7" - -"@babel/helper-validator-identifier@^7.16.7": - "version" "7.16.7" - -"@babel/helper-validator-option@^7.16.7": - "version" "7.16.7" - -"@babel/helpers@^7.17.2": - "version" "7.17.2" - dependencies: - "@babel/template" "^7.16.7" - "@babel/traverse" "^7.17.0" - "@babel/types" "^7.17.0" - -"@babel/highlight@^7.16.7": - "version" "7.16.10" - dependencies: - "@babel/helper-validator-identifier" "^7.16.7" - "chalk" "^2.0.0" - "js-tokens" "^4.0.0" - -"@babel/parser@^7.16.7", "@babel/parser@^7.17.0": - "version" "7.17.0" - -"@babel/template@^7.16.7": - "version" "7.16.7" - dependencies: - "@babel/code-frame" "^7.16.7" - "@babel/parser" "^7.16.7" - "@babel/types" "^7.16.7" - -"@babel/traverse@^7.16.7", "@babel/traverse@^7.17.0": - "version" "7.17.0" - dependencies: - "@babel/code-frame" "^7.16.7" - "@babel/generator" "^7.17.0" - "@babel/helper-environment-visitor" "^7.16.7" - "@babel/helper-function-name" "^7.16.7" - "@babel/helper-hoist-variables" "^7.16.7" - "@babel/helper-split-export-declaration" "^7.16.7" - "@babel/parser" "^7.17.0" - "@babel/types" "^7.17.0" - "debug" "^4.1.0" - "globals" "^11.1.0" - -"@babel/types@^7.16.7", "@babel/types@^7.17.0": - "version" "7.17.0" - dependencies: - "@babel/helper-validator-identifier" "^7.16.7" - "to-fast-properties" "^2.0.0" - -"@cspotcode/source-map-consumer@0.8.0": - "version" "0.8.0" - -"@cspotcode/source-map-support@0.7.0": - "version" "0.7.0" - dependencies: - "@cspotcode/source-map-consumer" "0.8.0" - -"@eslint/eslintrc@^1.0.5": - "version" "1.0.5" - dependencies: - "ajv" "^6.12.4" - "debug" "^4.3.2" - "espree" "^9.2.0" - "globals" "^13.9.0" - "ignore" "^4.0.6" - "import-fresh" "^3.2.1" - "js-yaml" "^4.1.0" - "minimatch" "^3.0.4" - "strip-json-comments" "^3.1.1" - -"@gar/promisify@^1.0.1": - "version" "1.1.2" - -"@humanwhocodes/config-array@^0.9.2": - "version" "0.9.3" - dependencies: - "@humanwhocodes/object-schema" "^1.2.1" - "debug" "^4.1.1" - "minimatch" "^3.0.4" - -"@humanwhocodes/object-schema@^1.2.1": - "version" "1.2.1" - -"@istanbuljs/load-nyc-config@^1.0.0": - "version" "1.1.0" - dependencies: - "camelcase" "^5.3.1" - "find-up" "^4.1.0" - "get-package-type" "^0.1.0" - "js-yaml" "^3.13.1" - "resolve-from" "^5.0.0" - -"@istanbuljs/nyc-config-typescript@^1.0.2": - "version" "1.0.2" - dependencies: - "@istanbuljs/schema" "^0.1.2" - -"@istanbuljs/schema@^0.1.2": - "version" "0.1.3" - -"@jridgewell/resolve-uri@^3.0.3": - "version" "3.0.4" - -"@jridgewell/sourcemap-codec@^1.4.10": - "version" "1.4.10" - -"@jridgewell/trace-mapping@^0.3.0": - "version" "0.3.2" - dependencies: - "@jridgewell/resolve-uri" "^3.0.3" - "@jridgewell/sourcemap-codec" "^1.4.10" - -"@nodelib/fs.scandir@2.1.5": - "version" "2.1.5" - dependencies: - "@nodelib/fs.stat" "2.0.5" - "run-parallel" "^1.1.9" - -"@nodelib/fs.stat@^2.0.2", "@nodelib/fs.stat@2.0.5": - "version" "2.0.5" - -"@nodelib/fs.walk@^1.2.3": - "version" "1.2.8" - dependencies: - "@nodelib/fs.scandir" "2.1.5" - "fastq" "^1.6.0" - -"@npmcli/fs@^1.0.0": - "version" "1.1.0" - dependencies: - "@gar/promisify" "^1.0.1" - "semver" "^7.3.5" - -"@npmcli/move-file@^1.0.1": - "version" "1.1.2" - dependencies: - "mkdirp" "^1.0.4" - "rimraf" "^3.0.2" - -"@sinonjs/commons@^1", "@sinonjs/commons@^1.3.0", "@sinonjs/commons@^1.4.0", "@sinonjs/commons@^1.7.0": - "version" "1.8.3" - dependencies: - "type-detect" "4.0.8" - -"@sinonjs/formatio@^3.2.1": - "version" "3.2.2" - dependencies: - "@sinonjs/commons" "^1" - "@sinonjs/samsam" "^3.1.0" - -"@sinonjs/samsam@^3.1.0", "@sinonjs/samsam@^3.3.3": - "version" "3.3.3" - dependencies: - "@sinonjs/commons" "^1.3.0" - "array-from" "^2.1.1" - "lodash" "^4.17.15" - -"@sinonjs/text-encoding@^0.7.1": - "version" "0.7.1" - -"@tootallnate/once@1": - "version" "1.1.2" - -"@tsconfig/node10@^1.0.7": - "version" "1.0.8" - -"@tsconfig/node12@^1.0.7": - "version" "1.0.9" - -"@tsconfig/node14@^1.0.0": - "version" "1.0.1" - -"@tsconfig/node16@^1.0.2": - "version" "1.0.2" - -"@types/json-schema@^7.0.9": - "version" "7.0.9" - -"@types/lodash@^4.14.176": - "version" "4.14.178" - -"@types/mocha@^9.1.0": - "version" "9.1.0" - -"@types/node@*", "@types/node@^16.11.6": - "version" "16.11.22" - -"@types/sinon@^10.0.6": - "version" "10.0.11" - dependencies: - "@types/sinonjs__fake-timers" "*" - -"@types/sinonjs__fake-timers@*": - "version" "8.1.1" - -"@typescript-eslint/eslint-plugin@^5.7.0": - "version" "5.11.0" - dependencies: - "@typescript-eslint/scope-manager" "5.11.0" - "@typescript-eslint/type-utils" "5.11.0" - "@typescript-eslint/utils" "5.11.0" - "debug" "^4.3.2" - "functional-red-black-tree" "^1.0.1" - "ignore" "^5.1.8" - "regexpp" "^3.2.0" - "semver" "^7.3.5" - "tsutils" "^3.21.0" - -"@typescript-eslint/parser@^5.0.0", "@typescript-eslint/parser@^5.7.0": - "version" "5.11.0" - dependencies: - "@typescript-eslint/scope-manager" "5.11.0" - "@typescript-eslint/types" "5.11.0" - "@typescript-eslint/typescript-estree" "5.11.0" - "debug" "^4.3.2" - -"@typescript-eslint/scope-manager@5.11.0": - "version" "5.11.0" - dependencies: - "@typescript-eslint/types" "5.11.0" - "@typescript-eslint/visitor-keys" "5.11.0" - -"@typescript-eslint/type-utils@5.11.0": - "version" "5.11.0" - dependencies: - "@typescript-eslint/utils" "5.11.0" - "debug" "^4.3.2" - "tsutils" "^3.21.0" - -"@typescript-eslint/types@5.11.0": - "version" "5.11.0" - -"@typescript-eslint/typescript-estree@5.11.0": - "version" "5.11.0" - dependencies: - "@typescript-eslint/types" "5.11.0" - "@typescript-eslint/visitor-keys" "5.11.0" - "debug" "^4.3.2" - "globby" "^11.0.4" - "is-glob" "^4.0.3" - "semver" "^7.3.5" - "tsutils" "^3.21.0" - -"@typescript-eslint/utils@5.11.0": - "version" "5.11.0" - dependencies: - "@types/json-schema" "^7.0.9" - "@typescript-eslint/scope-manager" "5.11.0" - "@typescript-eslint/types" "5.11.0" - "@typescript-eslint/typescript-estree" "5.11.0" - "eslint-scope" "^5.1.1" - "eslint-utils" "^3.0.0" - -"@typescript-eslint/visitor-keys@5.11.0": - "version" "5.11.0" - dependencies: - "@typescript-eslint/types" "5.11.0" - "eslint-visitor-keys" "^3.0.0" - -"@ungap/promise-all-settled@1.1.2": - "version" "1.1.2" - -"abbrev@1": - "version" "1.1.1" - -"acorn-jsx@^5.3.1": - "version" "5.3.2" - -"acorn-walk@^8.1.1": - "version" "8.2.0" - -"acorn@^6.0.0 || ^7.0.0 || ^8.0.0", "acorn@^8.4.1", "acorn@^8.7.0": - "version" "8.7.0" - -"agent-base@^6.0.2", "agent-base@6": - "version" "6.0.2" - dependencies: - "debug" "4" - -"agentkeepalive@^4.1.3": - "version" "4.2.0" - dependencies: - "debug" "^4.1.0" - "depd" "^1.1.2" - "humanize-ms" "^1.2.1" - -"aggregate-error@^3.0.0": - "version" "3.1.0" - dependencies: - "clean-stack" "^2.0.0" - "indent-string" "^4.0.0" - -"ajv@^6.10.0", "ajv@^6.12.4": - "version" "6.12.6" - dependencies: - "fast-deep-equal" "^3.1.1" - "fast-json-stable-stringify" "^2.0.0" - "json-schema-traverse" "^0.4.1" - "uri-js" "^4.2.2" - -"ansi-colors@4.1.1": - "version" "4.1.1" - -"ansi-regex@^5.0.1": - "version" "5.0.1" - -"ansi-styles@^3.2.1": - "version" "3.2.1" - dependencies: - "color-convert" "^1.9.0" - -"ansi-styles@^4.0.0", "ansi-styles@^4.1.0": - "version" "4.3.0" - dependencies: - "color-convert" "^2.0.1" - -"anymatch@~3.1.2": - "version" "3.1.2" - dependencies: - "normalize-path" "^3.0.0" - "picomatch" "^2.0.4" - -"append-transform@^2.0.0": - "version" "2.0.0" - dependencies: - "default-require-extensions" "^3.0.0" - -"aproba@^1.0.3 || ^2.0.0": - "version" "2.0.0" - -"archy@^1.0.0": - "version" "1.0.0" - -"are-we-there-yet@^2.0.0": - "version" "2.0.0" - dependencies: - "delegates" "^1.0.0" - "readable-stream" "^3.6.0" - -"arg@^4.1.0": - "version" "4.1.3" - -"argparse@^1.0.7": - "version" "1.0.10" - dependencies: - "sprintf-js" "~1.0.2" - -"argparse@^2.0.1": - "version" "2.0.1" - -"array-from@^2.1.1": - "version" "2.1.1" - -"array-union@^2.1.0": - "version" "2.1.0" - -"axios@^0.24.0": - "version" "0.24.0" - dependencies: - "follow-redirects" "^1.14.4" - -"balanced-match@^1.0.0": - "version" "1.0.2" - -"binary-extensions@^2.0.0": - "version" "2.2.0" - -"brace-expansion@^1.1.7": - "version" "1.1.11" - dependencies: - "balanced-match" "^1.0.0" - "concat-map" "0.0.1" - -"braces@^3.0.1", "braces@~3.0.2": - "version" "3.0.2" - dependencies: - "fill-range" "^7.0.1" - -"browser-stdout@1.3.1": - "version" "1.3.1" - -"browserslist@^4.17.5": - "version" "4.19.1" - dependencies: - "caniuse-lite" "^1.0.30001286" - "electron-to-chromium" "^1.4.17" - "escalade" "^3.1.1" - "node-releases" "^2.0.1" - "picocolors" "^1.0.0" - -"cacache@^15.2.0": - "version" "15.3.0" - dependencies: - "@npmcli/fs" "^1.0.0" - "@npmcli/move-file" "^1.0.1" - "chownr" "^2.0.0" - "fs-minipass" "^2.0.0" - "glob" "^7.1.4" - "infer-owner" "^1.0.4" - "lru-cache" "^6.0.0" - "minipass" "^3.1.1" - "minipass-collect" "^1.0.2" - "minipass-flush" "^1.0.5" - "minipass-pipeline" "^1.2.2" - "mkdirp" "^1.0.3" - "p-map" "^4.0.0" - "promise-inflight" "^1.0.1" - "rimraf" "^3.0.2" - "ssri" "^8.0.1" - "tar" "^6.0.2" - "unique-filename" "^1.1.1" - -"caching-transform@^4.0.0": - "version" "4.0.0" - dependencies: - "hasha" "^5.0.0" - "make-dir" "^3.0.0" - "package-hash" "^4.0.0" - "write-file-atomic" "^3.0.0" - -"callsites@^3.0.0": - "version" "3.1.0" - -"camelcase@^5.0.0", "camelcase@^5.3.1": - "version" "5.3.1" - -"camelcase@^6.0.0": - "version" "6.3.0" - -"caniuse-lite@^1.0.30001286": - "version" "1.0.30001309" - -"chalk@^2.0.0": - "version" "2.4.2" - dependencies: - "ansi-styles" "^3.2.1" - "escape-string-regexp" "^1.0.5" - "supports-color" "^5.3.0" - -"chalk@^4.0.0", "chalk@^4.1.0": - "version" "4.1.2" - dependencies: - "ansi-styles" "^4.1.0" - "supports-color" "^7.1.0" - -"chokidar@3.5.3": - "version" "3.5.3" - dependencies: - "anymatch" "~3.1.2" - "braces" "~3.0.2" - "glob-parent" "~5.1.2" - "is-binary-path" "~2.1.0" - "is-glob" "~4.0.1" - "normalize-path" "~3.0.0" - "readdirp" "~3.6.0" - optionalDependencies: - "fsevents" "~2.3.2" - -"chownr@^2.0.0": - "version" "2.0.0" - -"clean-stack@^2.0.0": - "version" "2.2.0" - -"cliui@^6.0.0": - "version" "6.0.0" - dependencies: - "string-width" "^4.2.0" - "strip-ansi" "^6.0.0" - "wrap-ansi" "^6.2.0" - -"cliui@^7.0.2": - "version" "7.0.4" - dependencies: - "string-width" "^4.2.0" - "strip-ansi" "^6.0.0" - "wrap-ansi" "^7.0.0" - -"color-convert@^1.9.0": - "version" "1.9.3" - dependencies: - "color-name" "1.1.3" - -"color-convert@^2.0.1": - "version" "2.0.1" - dependencies: - "color-name" "~1.1.4" - -"color-name@~1.1.4": - "version" "1.1.4" - -"color-name@1.1.3": - "version" "1.1.3" - -"color-support@^1.1.2": - "version" "1.1.3" - -"commondir@^1.0.1": - "version" "1.0.1" - -"concat-map@0.0.1": - "version" "0.0.1" - -"console-control-strings@^1.0.0", "console-control-strings@^1.1.0": - "version" "1.1.0" - -"convert-source-map@^1.7.0": - "version" "1.8.0" - dependencies: - "safe-buffer" "~5.1.1" - -"create-require@^1.1.0": - "version" "1.1.1" - -"cross-spawn@^7.0.0", "cross-spawn@^7.0.2": - "version" "7.0.3" - dependencies: - "path-key" "^3.1.0" - "shebang-command" "^2.0.0" - "which" "^2.0.1" - -"debug@^4.1.0", "debug@^4.1.1", "debug@^4.3.1", "debug@^4.3.2", "debug@4", "debug@4.3.3": - "version" "4.3.3" - dependencies: - "ms" "2.1.2" - -"decamelize@^1.2.0": - "version" "1.2.0" - -"decamelize@^4.0.0": - "version" "4.0.0" - -"deep-is@^0.1.3": - "version" "0.1.4" - -"default-require-extensions@^3.0.0": - "version" "3.0.0" - dependencies: - "strip-bom" "^4.0.0" - -"delegates@^1.0.0": - "version" "1.0.0" - -"depd@^1.1.2": - "version" "1.1.2" - -"diff@^3.5.0": - "version" "3.5.0" - -"diff@^4.0.1": - "version" "4.0.2" - -"diff@5.0.0": - "version" "5.0.0" - -"dir-glob@^3.0.1": - "version" "3.0.1" - dependencies: - "path-type" "^4.0.0" - -"doctrine@^3.0.0": - "version" "3.0.0" - dependencies: - "esutils" "^2.0.2" - -"electron-to-chromium@^1.4.17": - "version" "1.4.66" - -"emoji-regex@^8.0.0": - "version" "8.0.0" - -"encoding@^0.1.12": - "version" "0.1.13" - dependencies: - "iconv-lite" "^0.6.2" - -"env-paths@^2.2.0": - "version" "2.2.1" - -"err-code@^2.0.2": - "version" "2.0.3" - -"es6-error@^4.0.1": - "version" "4.1.1" - -"escalade@^3.1.1": - "version" "3.1.1" - -"escape-string-regexp@^1.0.5": - "version" "1.0.5" - -"escape-string-regexp@^4.0.0", "escape-string-regexp@4.0.0": - "version" "4.0.0" - -"eslint-config-prettier@^8.3.0": - "version" "8.3.0" - -"eslint-scope@^5.1.1": - "version" "5.1.1" - dependencies: - "esrecurse" "^4.3.0" - "estraverse" "^4.1.1" - -"eslint-scope@^7.1.0": - "version" "7.1.0" - dependencies: - "esrecurse" "^4.3.0" - "estraverse" "^5.2.0" - -"eslint-utils@^3.0.0": - "version" "3.0.0" - dependencies: - "eslint-visitor-keys" "^2.0.0" - -"eslint-visitor-keys@^2.0.0": - "version" "2.1.0" - -"eslint-visitor-keys@^3.0.0", "eslint-visitor-keys@^3.1.0", "eslint-visitor-keys@^3.2.0": - "version" "3.2.0" - -"eslint@*", "eslint@^6.0.0 || ^7.0.0 || ^8.0.0", "eslint@^8.2.0", "eslint@>=5", "eslint@>=7.0.0": - "version" "8.8.0" - dependencies: - "@eslint/eslintrc" "^1.0.5" - "@humanwhocodes/config-array" "^0.9.2" - "ajv" "^6.10.0" - "chalk" "^4.0.0" - "cross-spawn" "^7.0.2" - "debug" "^4.3.2" - "doctrine" "^3.0.0" - "escape-string-regexp" "^4.0.0" - "eslint-scope" "^7.1.0" - "eslint-utils" "^3.0.0" - "eslint-visitor-keys" "^3.2.0" - "espree" "^9.3.0" - "esquery" "^1.4.0" - "esutils" "^2.0.2" - "fast-deep-equal" "^3.1.3" - "file-entry-cache" "^6.0.1" - "functional-red-black-tree" "^1.0.1" - "glob-parent" "^6.0.1" - "globals" "^13.6.0" - "ignore" "^5.2.0" - "import-fresh" "^3.0.0" - "imurmurhash" "^0.1.4" - "is-glob" "^4.0.0" - "js-yaml" "^4.1.0" - "json-stable-stringify-without-jsonify" "^1.0.1" - "levn" "^0.4.1" - "lodash.merge" "^4.6.2" - "minimatch" "^3.0.4" - "natural-compare" "^1.4.0" - "optionator" "^0.9.1" - "regexpp" "^3.2.0" - "strip-ansi" "^6.0.1" - "strip-json-comments" "^3.1.0" - "text-table" "^0.2.0" - "v8-compile-cache" "^2.0.3" - -"espree@^9.2.0", "espree@^9.3.0": - "version" "9.3.0" - dependencies: - "acorn" "^8.7.0" - "acorn-jsx" "^5.3.1" - "eslint-visitor-keys" "^3.1.0" - -"esprima@^4.0.0": - "version" "4.0.1" - -"esquery@^1.4.0": - "version" "1.4.0" - dependencies: - "estraverse" "^5.1.0" - -"esrecurse@^4.3.0": - "version" "4.3.0" - dependencies: - "estraverse" "^5.2.0" - -"estraverse@^4.1.1": - "version" "4.3.0" - -"estraverse@^5.1.0", "estraverse@^5.2.0": - "version" "5.3.0" - -"esutils@^2.0.2": - "version" "2.0.3" - -"fast-deep-equal@^3.1.1", "fast-deep-equal@^3.1.3": - "version" "3.1.3" - -"fast-glob@^3.2.9": - "version" "3.2.11" - dependencies: - "@nodelib/fs.stat" "^2.0.2" - "@nodelib/fs.walk" "^1.2.3" - "glob-parent" "^5.1.2" - "merge2" "^1.3.0" - "micromatch" "^4.0.4" - -"fast-json-stable-stringify@^2.0.0": - "version" "2.1.0" - -"fast-levenshtein@^2.0.6": - "version" "2.0.6" - -"fastq@^1.6.0": - "version" "1.13.0" - dependencies: - "reusify" "^1.0.4" - -"file-entry-cache@^6.0.1": - "version" "6.0.1" - dependencies: - "flat-cache" "^3.0.4" - -"fill-range@^7.0.1": - "version" "7.0.1" - dependencies: - "to-regex-range" "^5.0.1" - -"find-cache-dir@^3.2.0": - "version" "3.3.2" - dependencies: - "commondir" "^1.0.1" - "make-dir" "^3.0.2" - "pkg-dir" "^4.1.0" - -"find-up@^4.0.0", "find-up@^4.1.0": - "version" "4.1.0" - dependencies: - "locate-path" "^5.0.0" - "path-exists" "^4.0.0" - -"find-up@5.0.0": - "version" "5.0.0" - dependencies: - "locate-path" "^6.0.0" - "path-exists" "^4.0.0" - -"flat-cache@^3.0.4": - "version" "3.0.4" - dependencies: - "flatted" "^3.1.0" - "rimraf" "^3.0.2" - -"flat@^5.0.2": - "version" "5.0.2" - -"flatted@^3.1.0": - "version" "3.2.5" - -"follow-redirects@^1.14.4": - "version" "1.14.8" - -"foreground-child@^2.0.0": - "version" "2.0.0" - dependencies: - "cross-spawn" "^7.0.0" - "signal-exit" "^3.0.2" - -"fromentries@^1.2.0": - "version" "1.3.2" - -"fs-minipass@^2.0.0": - "version" "2.1.0" - dependencies: - "minipass" "^3.0.0" - -"fs.realpath@^1.0.0": - "version" "1.0.0" - -"fsevents@~2.3.2": - "version" "2.3.2" - -"functional-red-black-tree@^1.0.1": - "version" "1.0.1" - -"gauge@^4.0.0": - "version" "4.0.0" - dependencies: - "ansi-regex" "^5.0.1" - "aproba" "^1.0.3 || ^2.0.0" - "color-support" "^1.1.2" - "console-control-strings" "^1.0.0" - "has-unicode" "^2.0.1" - "signal-exit" "^3.0.0" - "string-width" "^4.2.3" - "strip-ansi" "^6.0.1" - "wide-align" "^1.1.2" - -"gensync@^1.0.0-beta.2": - "version" "1.0.0-beta.2" - -"get-caller-file@^2.0.1", "get-caller-file@^2.0.5": - "version" "2.0.5" - -"get-package-type@^0.1.0": - "version" "0.1.0" - -"glob-parent@^5.1.2", "glob-parent@~5.1.2": - "version" "5.1.2" - dependencies: - "is-glob" "^4.0.1" - -"glob-parent@^6.0.1": - "version" "6.0.2" - dependencies: - "is-glob" "^4.0.3" - -"glob@^7.1.3", "glob@^7.1.4", "glob@^7.1.6", "glob@7.2.0": - "version" "7.2.0" - dependencies: - "fs.realpath" "^1.0.0" - "inflight" "^1.0.4" - "inherits" "2" - "minimatch" "^3.0.4" - "once" "^1.3.0" - "path-is-absolute" "^1.0.0" - -"globals@^11.1.0": - "version" "11.12.0" - -"globals@^13.6.0", "globals@^13.9.0": - "version" "13.12.1" - dependencies: - "type-fest" "^0.20.2" - -"globby@^11.0.4": - "version" "11.1.0" - dependencies: - "array-union" "^2.1.0" - "dir-glob" "^3.0.1" - "fast-glob" "^3.2.9" - "ignore" "^5.2.0" - "merge2" "^1.4.1" - "slash" "^3.0.0" - -"graceful-fs@^4.1.15", "graceful-fs@^4.2.6": - "version" "4.2.9" - -"growl@1.10.5": - "version" "1.10.5" - -"has-flag@^3.0.0": - "version" "3.0.0" - -"has-flag@^4.0.0": - "version" "4.0.0" - -"has-unicode@^2.0.1": - "version" "2.0.1" - -"hasha@^5.0.0": - "version" "5.2.2" - dependencies: - "is-stream" "^2.0.0" - "type-fest" "^0.8.0" - -"he@1.2.0": - "version" "1.2.0" - -"html-escaper@^2.0.0": - "version" "2.0.2" - -"htmlencode@^0.0.4": - "version" "0.0.4" - -"http-cache-semantics@^4.1.0": - "version" "4.1.0" - -"http-proxy-agent@^4.0.1": - "version" "4.0.1" - dependencies: - "@tootallnate/once" "1" - "agent-base" "6" - "debug" "4" - -"https-proxy-agent@^5.0.0": - "version" "5.0.0" - dependencies: - "agent-base" "6" - "debug" "4" - -"humanize-ms@^1.2.1": - "version" "1.2.1" - dependencies: - "ms" "^2.0.0" - -"iconv-lite@^0.6.2": - "version" "0.6.3" - dependencies: - "safer-buffer" ">= 2.1.2 < 3.0.0" - -"ignore@^4.0.6": - "version" "4.0.6" - -"ignore@^5.1.8", "ignore@^5.2.0": - "version" "5.2.0" - -"import-fresh@^3.0.0", "import-fresh@^3.2.1": - "version" "3.3.0" - dependencies: - "parent-module" "^1.0.0" - "resolve-from" "^4.0.0" - -"imurmurhash@^0.1.4": - "version" "0.1.4" - -"indent-string@^4.0.0": - "version" "4.0.0" - -"infer-owner@^1.0.4": - "version" "1.0.4" - -"inflight@^1.0.4": - "version" "1.0.6" - dependencies: - "once" "^1.3.0" - "wrappy" "1" - -"inherits@^2.0.3", "inherits@2": - "version" "2.0.4" - -"intercom-client@file:": - "resolved" "file:" - "version" "3.1.0" - dependencies: - "axios" "^0.24.0" - "htmlencode" "^0.0.4" - "intercom-client" "file:" - "lodash" "^4.17.21" - -"ip@^1.1.5": - "version" "1.1.5" - -"is-binary-path@~2.1.0": - "version" "2.1.0" - dependencies: - "binary-extensions" "^2.0.0" - -"is-extglob@^2.1.1": - "version" "2.1.1" - -"is-fullwidth-code-point@^3.0.0": - "version" "3.0.0" - -"is-glob@^4.0.0", "is-glob@^4.0.1", "is-glob@^4.0.3", "is-glob@~4.0.1": - "version" "4.0.3" - dependencies: - "is-extglob" "^2.1.1" - -"is-lambda@^1.0.1": - "version" "1.0.1" - -"is-number@^7.0.0": - "version" "7.0.0" - -"is-plain-obj@^2.1.0": - "version" "2.1.0" - -"is-stream@^2.0.0": - "version" "2.0.1" - -"is-typedarray@^1.0.0": - "version" "1.0.0" - -"is-unicode-supported@^0.1.0": - "version" "0.1.0" - -"is-windows@^1.0.2": - "version" "1.0.2" - -"isarray@0.0.1": - "version" "0.0.1" - -"isexe@^2.0.0": - "version" "2.0.0" - -"istanbul-lib-coverage@^3.0.0", "istanbul-lib-coverage@^3.0.0-alpha.1": - "version" "3.2.0" - -"istanbul-lib-hook@^3.0.0": - "version" "3.0.0" - dependencies: - "append-transform" "^2.0.0" - -"istanbul-lib-instrument@^4.0.0": - "version" "4.0.3" - dependencies: - "@babel/core" "^7.7.5" - "@istanbuljs/schema" "^0.1.2" - "istanbul-lib-coverage" "^3.0.0" - "semver" "^6.3.0" - -"istanbul-lib-processinfo@^2.0.2": - "version" "2.0.2" - dependencies: - "archy" "^1.0.0" - "cross-spawn" "^7.0.0" - "istanbul-lib-coverage" "^3.0.0-alpha.1" - "make-dir" "^3.0.0" - "p-map" "^3.0.0" - "rimraf" "^3.0.0" - "uuid" "^3.3.3" - -"istanbul-lib-report@^3.0.0": - "version" "3.0.0" - dependencies: - "istanbul-lib-coverage" "^3.0.0" - "make-dir" "^3.0.0" - "supports-color" "^7.1.0" - -"istanbul-lib-source-maps@^4.0.0": - "version" "4.0.1" - dependencies: - "debug" "^4.1.1" - "istanbul-lib-coverage" "^3.0.0" - "source-map" "^0.6.1" - -"istanbul-reports@^3.0.2": - "version" "3.1.4" - dependencies: - "html-escaper" "^2.0.0" - "istanbul-lib-report" "^3.0.0" - -"js-tokens@^4.0.0": - "version" "4.0.0" - -"js-yaml@^3.13.1": - "version" "3.14.1" - dependencies: - "argparse" "^1.0.7" - "esprima" "^4.0.0" - -"js-yaml@^4.1.0", "js-yaml@4.1.0": - "version" "4.1.0" - dependencies: - "argparse" "^2.0.1" - -"jsesc@^2.5.1": - "version" "2.5.2" - -"json-schema-traverse@^0.4.1": - "version" "0.4.1" - -"json-stable-stringify-without-jsonify@^1.0.1": - "version" "1.0.1" - -"json-stringify-safe@^5.0.1": - "version" "5.0.1" - -"json5@^2.1.2": - "version" "2.2.0" - dependencies: - "minimist" "^1.2.5" - -"just-extend@^4.0.2": - "version" "4.2.1" - -"levn@^0.4.1": - "version" "0.4.1" - dependencies: - "prelude-ls" "^1.2.1" - "type-check" "~0.4.0" - -"locate-path@^5.0.0": - "version" "5.0.0" - dependencies: - "p-locate" "^4.1.0" - -"locate-path@^6.0.0": - "version" "6.0.0" - dependencies: - "p-locate" "^5.0.0" - -"lodash.flattendeep@^4.4.0": - "version" "4.4.0" - -"lodash.merge@^4.6.2": - "version" "4.6.2" - -"lodash.set@^4.3.2": - "version" "4.3.2" - -"lodash@^4.17.15", "lodash@^4.17.21": - "version" "4.17.21" - -"log-symbols@4.1.0": - "version" "4.1.0" - dependencies: - "chalk" "^4.1.0" - "is-unicode-supported" "^0.1.0" - -"lolex@^4.2.0": - "version" "4.2.0" - -"lolex@^5.0.1": - "version" "5.1.2" - dependencies: - "@sinonjs/commons" "^1.7.0" - -"lru-cache@^6.0.0": - "version" "6.0.0" - dependencies: - "yallist" "^4.0.0" - -"make-dir@^3.0.0", "make-dir@^3.0.2": - "version" "3.1.0" - dependencies: - "semver" "^6.0.0" - -"make-error@^1.1.1": - "version" "1.3.6" - -"make-fetch-happen@^9.1.0": - "version" "9.1.0" - dependencies: - "agentkeepalive" "^4.1.3" - "cacache" "^15.2.0" - "http-cache-semantics" "^4.1.0" - "http-proxy-agent" "^4.0.1" - "https-proxy-agent" "^5.0.0" - "is-lambda" "^1.0.1" - "lru-cache" "^6.0.0" - "minipass" "^3.1.3" - "minipass-collect" "^1.0.2" - "minipass-fetch" "^1.3.2" - "minipass-flush" "^1.0.5" - "minipass-pipeline" "^1.2.4" - "negotiator" "^0.6.2" - "promise-retry" "^2.0.1" - "socks-proxy-agent" "^6.0.0" - "ssri" "^8.0.0" - -"merge2@^1.3.0", "merge2@^1.4.1": - "version" "1.4.1" - -"micromatch@^4.0.4": - "version" "4.0.4" - dependencies: - "braces" "^3.0.1" - "picomatch" "^2.2.3" - -"minimatch@^3.0.4": - "version" "3.0.5" - dependencies: - "brace-expansion" "^1.1.7" - -"minimatch@3.0.4": - "version" "3.0.4" - dependencies: - "brace-expansion" "^1.1.7" - -"minimist@^1.2.5": - "version" "1.2.5" - -"minipass-collect@^1.0.2": - "version" "1.0.2" - dependencies: - "minipass" "^3.0.0" - -"minipass-fetch@^1.3.2": - "version" "1.4.1" - dependencies: - "minipass" "^3.1.0" - "minipass-sized" "^1.0.3" - "minizlib" "^2.0.0" - optionalDependencies: - "encoding" "^0.1.12" - -"minipass-flush@^1.0.5": - "version" "1.0.5" - dependencies: - "minipass" "^3.0.0" - -"minipass-pipeline@^1.2.2", "minipass-pipeline@^1.2.4": - "version" "1.2.4" - dependencies: - "minipass" "^3.0.0" - -"minipass-sized@^1.0.3": - "version" "1.0.3" - dependencies: - "minipass" "^3.0.0" - -"minipass@^3.0.0", "minipass@^3.1.0", "minipass@^3.1.1", "minipass@^3.1.3": - "version" "3.1.6" - dependencies: - "yallist" "^4.0.0" - -"minizlib@^2.0.0", "minizlib@^2.1.1": - "version" "2.1.2" - dependencies: - "minipass" "^3.0.0" - "yallist" "^4.0.0" - -"mkdirp@^1.0.3", "mkdirp@^1.0.4": - "version" "1.0.4" - -"mocha@^9.2.0": - "version" "9.2.0" - dependencies: - "@ungap/promise-all-settled" "1.1.2" - "ansi-colors" "4.1.1" - "browser-stdout" "1.3.1" - "chokidar" "3.5.3" - "debug" "4.3.3" - "diff" "5.0.0" - "escape-string-regexp" "4.0.0" - "find-up" "5.0.0" - "glob" "7.2.0" - "growl" "1.10.5" - "he" "1.2.0" - "js-yaml" "4.1.0" - "log-symbols" "4.1.0" - "minimatch" "3.0.4" - "ms" "2.1.3" - "nanoid" "3.2.0" - "serialize-javascript" "6.0.0" - "strip-json-comments" "3.1.1" - "supports-color" "8.1.1" - "which" "2.0.2" - "workerpool" "6.2.0" - "yargs" "16.2.0" - "yargs-parser" "20.2.4" - "yargs-unparser" "2.0.0" - -"ms@^2.0.0", "ms@2.1.3": - "version" "2.1.3" - -"ms@2.1.2": - "version" "2.1.2" - -"nanoid@3.2.0": - "version" "3.2.0" - -"natural-compare@^1.4.0": - "version" "1.4.0" - -"negotiator@^0.6.2": - "version" "0.6.3" - -"nise@^1.5.2": - "version" "1.5.3" - dependencies: - "@sinonjs/formatio" "^3.2.1" - "@sinonjs/text-encoding" "^0.7.1" - "just-extend" "^4.0.2" - "lolex" "^5.0.1" - "path-to-regexp" "^1.7.0" - -"nock@^13.0.11": - "version" "13.2.4" - dependencies: - "debug" "^4.1.0" - "json-stringify-safe" "^5.0.1" - "lodash.set" "^4.3.2" - "propagate" "^2.0.0" - -"node-preload@^0.2.1": - "version" "0.2.1" - dependencies: - "process-on-spawn" "^1.0.0" - -"node-releases@^2.0.1": - "version" "2.0.2" - -"nopt@^5.0.0": - "version" "5.0.0" - dependencies: - "abbrev" "1" - -"normalize-path@^3.0.0", "normalize-path@~3.0.0": - "version" "3.0.0" - -"npmlog@^6.0.0": - "version" "6.0.0" - dependencies: - "are-we-there-yet" "^2.0.0" - "console-control-strings" "^1.1.0" - "gauge" "^4.0.0" - "set-blocking" "^2.0.0" - -"nyc@^15.1.0", "nyc@>=15": - "version" "15.1.0" - dependencies: - "@istanbuljs/load-nyc-config" "^1.0.0" - "@istanbuljs/schema" "^0.1.2" - "caching-transform" "^4.0.0" - "convert-source-map" "^1.7.0" - "decamelize" "^1.2.0" - "find-cache-dir" "^3.2.0" - "find-up" "^4.1.0" - "foreground-child" "^2.0.0" - "get-package-type" "^0.1.0" - "glob" "^7.1.6" - "istanbul-lib-coverage" "^3.0.0" - "istanbul-lib-hook" "^3.0.0" - "istanbul-lib-instrument" "^4.0.0" - "istanbul-lib-processinfo" "^2.0.2" - "istanbul-lib-report" "^3.0.0" - "istanbul-lib-source-maps" "^4.0.0" - "istanbul-reports" "^3.0.2" - "make-dir" "^3.0.0" - "node-preload" "^0.2.1" - "p-map" "^3.0.0" - "process-on-spawn" "^1.0.0" - "resolve-from" "^5.0.0" - "rimraf" "^3.0.0" - "signal-exit" "^3.0.2" - "spawn-wrap" "^2.0.0" - "test-exclude" "^6.0.0" - "yargs" "^15.0.2" - -"once@^1.3.0": - "version" "1.4.0" - dependencies: - "wrappy" "1" - -"optionator@^0.9.1": - "version" "0.9.1" - dependencies: - "deep-is" "^0.1.3" - "fast-levenshtein" "^2.0.6" - "levn" "^0.4.1" - "prelude-ls" "^1.2.1" - "type-check" "^0.4.0" - "word-wrap" "^1.2.3" - -"p-limit@^2.2.0": - "version" "2.3.0" - dependencies: - "p-try" "^2.0.0" - -"p-limit@^3.0.2": - "version" "3.1.0" - dependencies: - "yocto-queue" "^0.1.0" - -"p-locate@^4.1.0": - "version" "4.1.0" - dependencies: - "p-limit" "^2.2.0" - -"p-locate@^5.0.0": - "version" "5.0.0" - dependencies: - "p-limit" "^3.0.2" - -"p-map@^3.0.0": - "version" "3.0.0" - dependencies: - "aggregate-error" "^3.0.0" - -"p-map@^4.0.0": - "version" "4.0.0" - dependencies: - "aggregate-error" "^3.0.0" - -"p-try@^2.0.0": - "version" "2.2.0" - -"package-hash@^4.0.0": - "version" "4.0.0" - dependencies: - "graceful-fs" "^4.1.15" - "hasha" "^5.0.0" - "lodash.flattendeep" "^4.4.0" - "release-zalgo" "^1.0.0" - -"parent-module@^1.0.0": - "version" "1.0.1" - dependencies: - "callsites" "^3.0.0" - -"path-exists@^4.0.0": - "version" "4.0.0" - -"path-is-absolute@^1.0.0": - "version" "1.0.1" - -"path-key@^3.1.0": - "version" "3.1.1" - -"path-to-regexp@^1.7.0": - "version" "1.8.0" - dependencies: - "isarray" "0.0.1" - -"path-type@^4.0.0": - "version" "4.0.0" - -"picocolors@^1.0.0": - "version" "1.0.0" - -"picomatch@^2.0.4", "picomatch@^2.2.1", "picomatch@^2.2.3": - "version" "2.3.1" - -"pkg-dir@^4.1.0": - "version" "4.2.0" - dependencies: - "find-up" "^4.0.0" - -"prelude-ls@^1.2.1": - "version" "1.2.1" - -"prettier@^2.5.1": - "version" "2.5.1" - -"process-on-spawn@^1.0.0": - "version" "1.0.0" - dependencies: - "fromentries" "^1.2.0" - -"promise-inflight@^1.0.1": - "version" "1.0.1" - -"promise-retry@^2.0.1": - "version" "2.0.1" - dependencies: - "err-code" "^2.0.2" - "retry" "^0.12.0" - -"propagate@^2.0.0": - "version" "2.0.1" - -"punycode@^2.1.0": - "version" "2.1.1" - -"queue-microtask@^1.2.2": - "version" "1.2.3" - -"randombytes@^2.1.0": - "version" "2.1.0" - dependencies: - "safe-buffer" "^5.1.0" - -"readable-stream@^3.6.0": - "version" "3.6.0" - dependencies: - "inherits" "^2.0.3" - "string_decoder" "^1.1.1" - "util-deprecate" "^1.0.1" - -"readdirp@~3.6.0": - "version" "3.6.0" - dependencies: - "picomatch" "^2.2.1" - -"regexpp@^3.2.0": - "version" "3.2.0" - -"release-zalgo@^1.0.0": - "version" "1.0.0" - dependencies: - "es6-error" "^4.0.1" - -"require-directory@^2.1.1": - "version" "2.1.1" - -"require-main-filename@^2.0.0": - "version" "2.0.0" - -"resolve-from@^4.0.0": - "version" "4.0.0" - -"resolve-from@^5.0.0": - "version" "5.0.0" - -"retry@^0.12.0": - "version" "0.12.0" - -"reusify@^1.0.4": - "version" "1.0.4" - -"rimraf@^3.0.0", "rimraf@^3.0.2": - "version" "3.0.2" - dependencies: - "glob" "^7.1.3" - -"run-parallel@^1.1.9": - "version" "1.2.0" - dependencies: - "queue-microtask" "^1.2.2" - -"safe-buffer@^5.1.0", "safe-buffer@~5.2.0": - "version" "5.2.1" - -"safe-buffer@~5.1.1": - "version" "5.1.2" - -"safer-buffer@>= 2.1.2 < 3.0.0": - "version" "2.1.2" - -"semver@^6.0.0": - "version" "6.3.0" - -"semver@^6.3.0": - "version" "6.3.0" - -"semver@^7.3.5": - "version" "7.3.5" - dependencies: - "lru-cache" "^6.0.0" - -"serialize-javascript@6.0.0": - "version" "6.0.0" - dependencies: - "randombytes" "^2.1.0" - -"set-blocking@^2.0.0": - "version" "2.0.0" - -"shebang-command@^2.0.0": - "version" "2.0.0" - dependencies: - "shebang-regex" "^3.0.0" - -"shebang-regex@^3.0.0": - "version" "3.0.0" - -"signal-exit@^3.0.0", "signal-exit@^3.0.2": - "version" "3.0.7" - -"sinon@^7.3.2": - "version" "7.5.0" - dependencies: - "@sinonjs/commons" "^1.4.0" - "@sinonjs/formatio" "^3.2.1" - "@sinonjs/samsam" "^3.3.3" - "diff" "^3.5.0" - "lolex" "^4.2.0" - "nise" "^1.5.2" - "supports-color" "^5.5.0" - -"slash@^3.0.0": - "version" "3.0.0" - -"smart-buffer@^4.2.0": - "version" "4.2.0" - -"socks-proxy-agent@^6.0.0": - "version" "6.1.1" - dependencies: - "agent-base" "^6.0.2" - "debug" "^4.3.1" - "socks" "^2.6.1" - -"socks@^2.6.1": - "version" "2.6.2" - dependencies: - "ip" "^1.1.5" - "smart-buffer" "^4.2.0" - -"source-map@^0.5.0": - "version" "0.5.7" - -"source-map@^0.6.1": - "version" "0.6.1" - -"spawn-wrap@^2.0.0": - "version" "2.0.0" - dependencies: - "foreground-child" "^2.0.0" - "is-windows" "^1.0.2" - "make-dir" "^3.0.0" - "rimraf" "^3.0.0" - "signal-exit" "^3.0.2" - "which" "^2.0.1" - -"sprintf-js@~1.0.2": - "version" "1.0.3" - -"ssri@^8.0.0", "ssri@^8.0.1": - "version" "8.0.1" - dependencies: - "minipass" "^3.1.1" - -"string_decoder@^1.1.1": - "version" "1.3.0" - dependencies: - "safe-buffer" "~5.2.0" - -"string-width@^1.0.2 || 2 || 3 || 4", "string-width@^4.1.0", "string-width@^4.2.0", "string-width@^4.2.3": - "version" "4.2.3" - dependencies: - "emoji-regex" "^8.0.0" - "is-fullwidth-code-point" "^3.0.0" - "strip-ansi" "^6.0.1" - -"strip-ansi@^6.0.0", "strip-ansi@^6.0.1": - "version" "6.0.1" - dependencies: - "ansi-regex" "^5.0.1" - -"strip-bom@^4.0.0": - "version" "4.0.0" - -"strip-json-comments@^3.1.0", "strip-json-comments@^3.1.1", "strip-json-comments@3.1.1": - "version" "3.1.1" - -"supports-color@^5.3.0": - "version" "5.5.0" - dependencies: - "has-flag" "^3.0.0" - -"supports-color@^5.5.0": - "version" "5.5.0" - dependencies: - "has-flag" "^3.0.0" - -"supports-color@^7.1.0": - "version" "7.2.0" - dependencies: - "has-flag" "^4.0.0" - -"supports-color@8.1.1": - "version" "8.1.1" - dependencies: - "has-flag" "^4.0.0" - -"tar@^6.0.2", "tar@^6.1.2": - "version" "6.1.11" - dependencies: - "chownr" "^2.0.0" - "fs-minipass" "^2.0.0" - "minipass" "^3.0.0" - "minizlib" "^2.1.1" - "mkdirp" "^1.0.3" - "yallist" "^4.0.0" - -"test-exclude@^6.0.0": - "version" "6.0.0" - dependencies: - "@istanbuljs/schema" "^0.1.2" - "glob" "^7.1.4" - "minimatch" "^3.0.4" - -"text-table@^0.2.0": - "version" "0.2.0" - -"to-fast-properties@^2.0.0": - "version" "2.0.0" - -"to-regex-range@^5.0.1": - "version" "5.0.1" - dependencies: - "is-number" "^7.0.0" - -"ts-node@^10.4.0": - "version" "10.5.0" - dependencies: - "@cspotcode/source-map-support" "0.7.0" - "@tsconfig/node10" "^1.0.7" - "@tsconfig/node12" "^1.0.7" - "@tsconfig/node14" "^1.0.0" - "@tsconfig/node16" "^1.0.2" - "acorn" "^8.4.1" - "acorn-walk" "^8.1.1" - "arg" "^4.1.0" - "create-require" "^1.1.0" - "diff" "^4.0.1" - "make-error" "^1.1.1" - "v8-compile-cache-lib" "^3.0.0" - "yn" "3.1.1" - -"tslib@^1.8.1": - "version" "1.14.1" - -"tslib@^2.3.1": - "version" "2.3.1" - -"tsutils@^3.21.0": - "version" "3.21.0" - dependencies: - "tslib" "^1.8.1" - -"type-check@^0.4.0", "type-check@~0.4.0": - "version" "0.4.0" - dependencies: - "prelude-ls" "^1.2.1" - -"type-detect@4.0.8": - "version" "4.0.8" - -"type-fest@^0.20.2": - "version" "0.20.2" - -"type-fest@^0.8.0": - "version" "0.8.1" - -"typedarray-to-buffer@^3.1.5": - "version" "3.1.5" - dependencies: - "is-typedarray" "^1.0.0" - -"typescript@^4.5.3", "typescript@>=2.7", "typescript@>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta": - "version" "4.5.5" - -"unique-filename@^1.1.1": - "version" "1.1.1" - dependencies: - "unique-slug" "^2.0.0" - -"unique-slug@^2.0.0": - "version" "2.0.2" - dependencies: - "imurmurhash" "^0.1.4" - -"uri-js@^4.2.2": - "version" "4.4.1" - dependencies: - "punycode" "^2.1.0" - -"util-deprecate@^1.0.1": - "version" "1.0.2" - -"uuid@^3.3.3": - "version" "3.4.0" - -"v8-compile-cache-lib@^3.0.0": - "version" "3.0.0" - -"v8-compile-cache@^2.0.3": - "version" "2.3.0" - -"which-module@^2.0.0": - "version" "2.0.0" - -"which@^2.0.1", "which@^2.0.2", "which@2.0.2": - "version" "2.0.2" - dependencies: - "isexe" "^2.0.0" - -"wide-align@^1.1.2": - "version" "1.1.5" - dependencies: - "string-width" "^1.0.2 || 2 || 3 || 4" - -"word-wrap@^1.2.3": - "version" "1.2.3" - -"workerpool@6.2.0": - "version" "6.2.0" - -"wrap-ansi@^6.2.0": - "version" "6.2.0" - dependencies: - "ansi-styles" "^4.0.0" - "string-width" "^4.1.0" - "strip-ansi" "^6.0.0" - -"wrap-ansi@^7.0.0": - "version" "7.0.0" - dependencies: - "ansi-styles" "^4.0.0" - "string-width" "^4.1.0" - "strip-ansi" "^6.0.0" - -"wrappy@1": - "version" "1.0.2" - -"write-file-atomic@^3.0.0": - "version" "3.0.3" - dependencies: - "imurmurhash" "^0.1.4" - "is-typedarray" "^1.0.0" - "signal-exit" "^3.0.2" - "typedarray-to-buffer" "^3.1.5" - -"y18n@^4.0.0": - "version" "4.0.3" - -"y18n@^5.0.5": - "version" "5.0.8" - -"yallist@^4.0.0": - "version" "4.0.0" - -"yargs-parser@^18.1.2": - "version" "18.1.3" - dependencies: - "camelcase" "^5.0.0" - "decamelize" "^1.2.0" - -"yargs-parser@^20.2.2": - "version" "20.2.9" - -"yargs-parser@20.2.4": - "version" "20.2.4" - -"yargs-unparser@2.0.0": - "version" "2.0.0" - dependencies: - "camelcase" "^6.0.0" - "decamelize" "^4.0.0" - "flat" "^5.0.2" - "is-plain-obj" "^2.1.0" - -"yargs@^15.0.2": - "version" "15.4.1" - dependencies: - "cliui" "^6.0.0" - "decamelize" "^1.2.0" - "find-up" "^4.1.0" - "get-caller-file" "^2.0.1" - "require-directory" "^2.1.1" - "require-main-filename" "^2.0.0" - "set-blocking" "^2.0.0" - "string-width" "^4.2.0" - "which-module" "^2.0.0" - "y18n" "^4.0.0" - "yargs-parser" "^18.1.2" - -"yargs@16.2.0": - "version" "16.2.0" - dependencies: - "cliui" "^7.0.2" - "escalade" "^3.1.1" - "get-caller-file" "^2.0.5" - "require-directory" "^2.1.1" - "string-width" "^4.2.0" - "y18n" "^5.0.5" - "yargs-parser" "^20.2.2" - -"yn@3.1.1": - "version" "3.1.1" - -"yocto-queue@^0.1.0": - "version" "0.1.0" +# This file is generated by running "yarn install" inside your project. +# Manual changes might be lost - proceed with caution! + +__metadata: + version: 5 + cacheKey: 8 + +"@ampproject/remapping@npm:^2.0.0": + version: 2.1.0 + resolution: "@ampproject/remapping@npm:2.1.0" + dependencies: + "@jridgewell/trace-mapping": ^0.3.0 + checksum: 10ff0d4a559f930082f1a4c1b68dc521d5b1a75e0b8ab4829e9eedf6621386893e4a008f0db6c716f64db5d8eed49c0abcfbf3bd6ff11d5a00312454a9351ed4 + languageName: node + linkType: hard + +"@babel/code-frame@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/code-frame@npm:7.16.7" + dependencies: + "@babel/highlight": ^7.16.7 + checksum: db2f7faa31bc2c9cf63197b481b30ea57147a5fc1a6fab60e5d6c02cdfbf6de8e17b5121f99917b3dabb5eeb572da078312e70697415940383efc140d4e0808b + languageName: node + linkType: hard + +"@babel/compat-data@npm:^7.16.4": + version: 7.17.0 + resolution: "@babel/compat-data@npm:7.17.0" + checksum: fe5afaf529d107a223cd5937dace248464b6df1e9f4ea4031a5723e9571b46a4db1c4ff226bac6351148b1bc02ba1b39cb142662cd235aa99c1dda77882f8c9d + languageName: node + linkType: hard + +"@babel/core@npm:^7.7.5": + version: 7.17.2 + resolution: "@babel/core@npm:7.17.2" + dependencies: + "@ampproject/remapping": ^2.0.0 + "@babel/code-frame": ^7.16.7 + "@babel/generator": ^7.17.0 + "@babel/helper-compilation-targets": ^7.16.7 + "@babel/helper-module-transforms": ^7.16.7 + "@babel/helpers": ^7.17.2 + "@babel/parser": ^7.17.0 + "@babel/template": ^7.16.7 + "@babel/traverse": ^7.17.0 + "@babel/types": ^7.17.0 + convert-source-map: ^1.7.0 + debug: ^4.1.0 + gensync: ^1.0.0-beta.2 + json5: ^2.1.2 + semver: ^6.3.0 + checksum: 68ab3459f41b41feb5cb263937f15e418e1c46998d482d1b6dfe34f78064765466cfd5b10205c22fb16b69dbd1d46e7a3c26c067884ca4eb514b3dac1e09a57f + languageName: node + linkType: hard + +"@babel/generator@npm:^7.17.0": + version: 7.17.0 + resolution: "@babel/generator@npm:7.17.0" + dependencies: + "@babel/types": ^7.17.0 + jsesc: ^2.5.1 + source-map: ^0.5.0 + checksum: 2987dbebb484727a227f1ce3db90810320986cfb3ffd23e6d1d87f75bbd8e7871b5bc44252822d4d5f048a2d872a5702b2a9bf7bab7e07f087d7f306f0ea6c0a + languageName: node + linkType: hard + +"@babel/helper-compilation-targets@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-compilation-targets@npm:7.16.7" + dependencies: + "@babel/compat-data": ^7.16.4 + "@babel/helper-validator-option": ^7.16.7 + browserslist: ^4.17.5 + semver: ^6.3.0 + peerDependencies: + "@babel/core": ^7.0.0 + checksum: 7238aaee78c011a42fb5ca92e5eff098752f7b314c2111d7bb9cdd58792fcab1b9c819b59f6a0851dc210dc09dc06b30d130a23982753e70eb3111bc65204842 + languageName: node + linkType: hard + +"@babel/helper-environment-visitor@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-environment-visitor@npm:7.16.7" + dependencies: + "@babel/types": ^7.16.7 + checksum: c03a10105d9ebd1fe632a77356b2e6e2f3c44edba9a93b0dc3591b6a66bd7a2e323dd9502f9ce96fc6401234abff1907aa877b6674f7826b61c953f7c8204bbe + languageName: node + linkType: hard + +"@babel/helper-function-name@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-function-name@npm:7.16.7" + dependencies: + "@babel/helper-get-function-arity": ^7.16.7 + "@babel/template": ^7.16.7 + "@babel/types": ^7.16.7 + checksum: fc77cbe7b10cfa2a262d7a37dca575c037f20419dfe0c5d9317f589599ca24beb5f5c1057748011159149eaec47fe32338c6c6412376fcded68200df470161e1 + languageName: node + linkType: hard + +"@babel/helper-get-function-arity@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-get-function-arity@npm:7.16.7" + dependencies: + "@babel/types": ^7.16.7 + checksum: 25d969fb207ff2ad5f57a90d118f6c42d56a0171022e200aaa919ba7dc95ae7f92ec71cdea6c63ef3629a0dc962ab4c78e09ca2b437185ab44539193f796e0c3 + languageName: node + linkType: hard + +"@babel/helper-hoist-variables@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-hoist-variables@npm:7.16.7" + dependencies: + "@babel/types": ^7.16.7 + checksum: 6ae1641f4a751cd9045346e3f61c3d9ec1312fd779ab6d6fecfe2a96e59a481ad5d7e40d2a840894c13b3fd6114345b157f9e3062fc5f1580f284636e722de60 + languageName: node + linkType: hard + +"@babel/helper-module-imports@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-module-imports@npm:7.16.7" + dependencies: + "@babel/types": ^7.16.7 + checksum: ddd2c4a600a2e9a4fee192ab92bf35a627c5461dbab4af31b903d9ba4d6b6e59e0ff3499fde4e2e9a0eebe24906f00b636f8b4d9bd72ff24d50e6618215c3212 + languageName: node + linkType: hard + +"@babel/helper-module-transforms@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-module-transforms@npm:7.16.7" + dependencies: + "@babel/helper-environment-visitor": ^7.16.7 + "@babel/helper-module-imports": ^7.16.7 + "@babel/helper-simple-access": ^7.16.7 + "@babel/helper-split-export-declaration": ^7.16.7 + "@babel/helper-validator-identifier": ^7.16.7 + "@babel/template": ^7.16.7 + "@babel/traverse": ^7.16.7 + "@babel/types": ^7.16.7 + checksum: 6e930ce776c979f299cdbeaf80187f4ab086d75287b96ecc1c6896d392fcb561065f0d6219fc06fa79b4ceb4bbdc1a9847da8099aba9b077d0a9e583500fb673 + languageName: node + linkType: hard + +"@babel/helper-simple-access@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-simple-access@npm:7.16.7" + dependencies: + "@babel/types": ^7.16.7 + checksum: 8d22c46c5ec2ead0686c4d5a3d1d12b5190c59be676bfe0d9d89df62b437b51d1a3df2ccfb8a77dded2e585176ebf12986accb6d45a18cff229eef3b10344f4b + languageName: node + linkType: hard + +"@babel/helper-split-export-declaration@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-split-export-declaration@npm:7.16.7" + dependencies: + "@babel/types": ^7.16.7 + checksum: e10aaf135465c55114627951b79115f24bc7af72ecbb58d541d66daf1edaee5dde7cae3ec8c3639afaf74526c03ae3ce723444e3b5b3dc77140c456cd84bcaa1 + languageName: node + linkType: hard + +"@babel/helper-validator-identifier@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-validator-identifier@npm:7.16.7" + checksum: dbb3db9d184343152520a209b5684f5e0ed416109cde82b428ca9c759c29b10c7450657785a8b5c5256aa74acc6da491c1f0cf6b784939f7931ef82982051b69 + languageName: node + linkType: hard + +"@babel/helper-validator-option@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/helper-validator-option@npm:7.16.7" + checksum: c5ccc451911883cc9f12125d47be69434f28094475c1b9d2ada7c3452e6ac98a1ee8ddd364ca9e3f9855fcdee96cdeafa32543ebd9d17fee7a1062c202e80570 + languageName: node + linkType: hard + +"@babel/helpers@npm:^7.17.2": + version: 7.17.2 + resolution: "@babel/helpers@npm:7.17.2" + dependencies: + "@babel/template": ^7.16.7 + "@babel/traverse": ^7.17.0 + "@babel/types": ^7.17.0 + checksum: 5fa06bbf59636314fb4098bb2e70cf488e0fb6989553438abab90356357b79976102ac129fb16fc8186893c79e0809de1d90e3304426d6fcdb1750da2b6dff9d + languageName: node + linkType: hard + +"@babel/highlight@npm:^7.16.7": + version: 7.16.10 + resolution: "@babel/highlight@npm:7.16.10" + dependencies: + "@babel/helper-validator-identifier": ^7.16.7 + chalk: ^2.0.0 + js-tokens: ^4.0.0 + checksum: 1f1bdd752a90844f4efc22166a46303fb651ba0fd75a06daba3ebae2575ab3edc1da9827c279872a3aaf305f50a18473c5fa1966752726a2b253065fd4c0745e + languageName: node + linkType: hard + +"@babel/parser@npm:^7.16.7, @babel/parser@npm:^7.17.0": + version: 7.17.0 + resolution: "@babel/parser@npm:7.17.0" + bin: + parser: ./bin/babel-parser.js + checksum: d0ac5ffba0b234dde516f867edf5da5d92d6f841592b370ae3244cd7c8f27a7f5e3e3d4e90ca9c15ea58bc46823f1643f3f75b6eb9a9f676ae16e8b2365e922a + languageName: node + linkType: hard + +"@babel/template@npm:^7.16.7": + version: 7.16.7 + resolution: "@babel/template@npm:7.16.7" + dependencies: + "@babel/code-frame": ^7.16.7 + "@babel/parser": ^7.16.7 + "@babel/types": ^7.16.7 + checksum: 10cd112e89276e00f8b11b55a51c8b2f1262c318283a980f4d6cdb0286dc05734b9aaeeb9f3ad3311900b09bc913e02343fcaa9d4a4f413964aaab04eb84ac4a + languageName: node + linkType: hard + +"@babel/traverse@npm:^7.16.7, @babel/traverse@npm:^7.17.0": + version: 7.17.0 + resolution: "@babel/traverse@npm:7.17.0" + dependencies: + "@babel/code-frame": ^7.16.7 + "@babel/generator": ^7.17.0 + "@babel/helper-environment-visitor": ^7.16.7 + "@babel/helper-function-name": ^7.16.7 + "@babel/helper-hoist-variables": ^7.16.7 + "@babel/helper-split-export-declaration": ^7.16.7 + "@babel/parser": ^7.17.0 + "@babel/types": ^7.17.0 + debug: ^4.1.0 + globals: ^11.1.0 + checksum: 9b7de053d8a29453fd7b9614a028d8dc811817f02948eaee02093274b67927a1cfb0513b521bc4a9328c9b6e5b021fd343b358c3526bbb6ee61ec078d4110c0c + languageName: node + linkType: hard + +"@babel/types@npm:^7.16.7, @babel/types@npm:^7.17.0, @babel/types@npm:^7.8.3": + version: 7.17.0 + resolution: "@babel/types@npm:7.17.0" + dependencies: + "@babel/helper-validator-identifier": ^7.16.7 + to-fast-properties: ^2.0.0 + checksum: 12e5a287986fe557188e87b2c5202223f1dc83d9239a196ab936fdb9f8c1eb0be717ff19f934b5fad4e29a75586d5798f74bed209bccea1c20376b9952056f0e + languageName: node + linkType: hard + +"@cspotcode/source-map-consumer@npm:0.8.0": + version: 0.8.0 + resolution: "@cspotcode/source-map-consumer@npm:0.8.0" + checksum: c0c16ca3d2f58898f1bd74c4f41a189dbcc202e642e60e489cbcc2e52419c4e89bdead02c886a12fb13ea37798ede9e562b2321df997ebc210ae9bd881561b4e + languageName: node + linkType: hard + +"@cspotcode/source-map-support@npm:0.7.0": + version: 0.7.0 + resolution: "@cspotcode/source-map-support@npm:0.7.0" + dependencies: + "@cspotcode/source-map-consumer": 0.8.0 + checksum: 9faddda7757cd778b5fd6812137b2cc265810043680d6399acc20441668fafcdc874053be9dccd0d9110087287bfad27eb3bf342f72bceca9aa9059f5d0c4be8 + languageName: node + linkType: hard + +"@eslint/eslintrc@npm:^1.0.5": + version: 1.0.5 + resolution: "@eslint/eslintrc@npm:1.0.5" + dependencies: + ajv: ^6.12.4 + debug: ^4.3.2 + espree: ^9.2.0 + globals: ^13.9.0 + ignore: ^4.0.6 + import-fresh: ^3.2.1 + js-yaml: ^4.1.0 + minimatch: ^3.0.4 + strip-json-comments: ^3.1.1 + checksum: b35b50d7b65bd8acd92a05b6fb15ac62c0cefa40dfef0324ca5bf8632bf3679bab6e173c53b3ad1e1d837701cecdbd9c144b35f46588cdf4e046a9caa272488d + languageName: node + linkType: hard + +"@gar/promisify@npm:^1.0.1": + version: 1.1.2 + resolution: "@gar/promisify@npm:1.1.2" + checksum: d05081e0887a49c178b75ee3067bd6ee086f73c154d121b854fb2e044e8a89cb1cbb6de3a0dd93a519b80f0531fda68b099dd7256205f7fbb3490324342f2217 + languageName: node + linkType: hard + +"@humanwhocodes/config-array@npm:^0.9.2": + version: 0.9.3 + resolution: "@humanwhocodes/config-array@npm:0.9.3" + dependencies: + "@humanwhocodes/object-schema": ^1.2.1 + debug: ^4.1.1 + minimatch: ^3.0.4 + checksum: 6e5d7d274941c459bab0a14a87e372206d89fad3e4879d982edc942e8cc34da6510ea3644b8535a2a9edaa6527e91dccceabc6837ffa8ee506d66bca5d269ebc + languageName: node + linkType: hard + +"@humanwhocodes/object-schema@npm:^1.2.1": + version: 1.2.1 + resolution: "@humanwhocodes/object-schema@npm:1.2.1" + checksum: a824a1ec31591231e4bad5787641f59e9633827d0a2eaae131a288d33c9ef0290bd16fda8da6f7c0fcb014147865d12118df10db57f27f41e20da92369fcb3f1 + languageName: node + linkType: hard + +"@istanbuljs/load-nyc-config@npm:^1.0.0": + version: 1.1.0 + resolution: "@istanbuljs/load-nyc-config@npm:1.1.0" + dependencies: + camelcase: ^5.3.1 + find-up: ^4.1.0 + get-package-type: ^0.1.0 + js-yaml: ^3.13.1 + resolve-from: ^5.0.0 + checksum: d578da5e2e804d5c93228450a1380e1a3c691de4953acc162f387b717258512a3e07b83510a936d9fab03eac90817473917e24f5d16297af3867f59328d58568 + languageName: node + linkType: hard + +"@istanbuljs/nyc-config-typescript@npm:^1.0.2": + version: 1.0.2 + resolution: "@istanbuljs/nyc-config-typescript@npm:1.0.2" + dependencies: + "@istanbuljs/schema": ^0.1.2 + peerDependencies: + nyc: ">=15" + checksum: df6f9c9b17df8f1d8813f768c11ca31ec125d60bcd82d8273a467022e414d2d686ee80abb7b0f0e3c512b7ed686771fadb7fb5be8881619b9f6cb1f31b86e9f3 + languageName: node + linkType: hard + +"@istanbuljs/schema@npm:^0.1.2": + version: 0.1.3 + resolution: "@istanbuljs/schema@npm:0.1.3" + checksum: 5282759d961d61350f33d9118d16bcaed914ebf8061a52f4fa474b2cb08720c9c81d165e13b82f2e5a8a212cc5af482f0c6fc1ac27b9e067e5394c9a6ed186c9 + languageName: node + linkType: hard + +"@jridgewell/resolve-uri@npm:^3.0.3": + version: 3.0.4 + resolution: "@jridgewell/resolve-uri@npm:3.0.4" + checksum: 799bcba2730280a42f11b4d41a5d34d68ce72cb1bd23186bd3356607c93b62765b2b050e5dfb67f04ce4e817f882bfc10a4d1c43fe2d8eeb38371c98d71217b4 + languageName: node + linkType: hard + +"@jridgewell/sourcemap-codec@npm:^1.4.10": + version: 1.4.10 + resolution: "@jridgewell/sourcemap-codec@npm:1.4.10" + checksum: 247229218edbe165dcf0a5ae0c4b81bff1b5438818bb09221f756681fe158597fdf25c2a803f9260453b299c98c7e01ddebeb1555cda3157d987cd22c08605ef + languageName: node + linkType: hard + +"@jridgewell/trace-mapping@npm:^0.3.0": + version: 0.3.2 + resolution: "@jridgewell/trace-mapping@npm:0.3.2" + dependencies: + "@jridgewell/resolve-uri": ^3.0.3 + "@jridgewell/sourcemap-codec": ^1.4.10 + checksum: b58be6b4133cbcb20bfd28c9ca843b8db9efa0bf1d7e0e9e26b2228dace94ad53161c996ab1d762d7c3955dfc398a7734e7b84a2493ae36b451f232234fbb257 + languageName: node + linkType: hard + +"@nodelib/fs.scandir@npm:2.1.5": + version: 2.1.5 + resolution: "@nodelib/fs.scandir@npm:2.1.5" + dependencies: + "@nodelib/fs.stat": 2.0.5 + run-parallel: ^1.1.9 + checksum: a970d595bd23c66c880e0ef1817791432dbb7acbb8d44b7e7d0e7a22f4521260d4a83f7f9fd61d44fda4610105577f8f58a60718105fb38352baed612fd79e59 + languageName: node + linkType: hard + +"@nodelib/fs.stat@npm:2.0.5, @nodelib/fs.stat@npm:^2.0.2": + version: 2.0.5 + resolution: "@nodelib/fs.stat@npm:2.0.5" + checksum: 012480b5ca9d97bff9261571dbbec7bbc6033f69cc92908bc1ecfad0792361a5a1994bc48674b9ef76419d056a03efadfce5a6cf6dbc0a36559571a7a483f6f0 + languageName: node + linkType: hard + +"@nodelib/fs.walk@npm:^1.2.3": + version: 1.2.8 + resolution: "@nodelib/fs.walk@npm:1.2.8" + dependencies: + "@nodelib/fs.scandir": 2.1.5 + fastq: ^1.6.0 + checksum: 190c643f156d8f8f277bf2a6078af1ffde1fd43f498f187c2db24d35b4b4b5785c02c7dc52e356497b9a1b65b13edc996de08de0b961c32844364da02986dc53 + languageName: node + linkType: hard + +"@npmcli/fs@npm:^1.0.0": + version: 1.1.0 + resolution: "@npmcli/fs@npm:1.1.0" + dependencies: + "@gar/promisify": ^1.0.1 + semver: ^7.3.5 + checksum: e435b883b4f8da8c95a820f458cabb7d86582406eed5ad79fc689000d3e2df17e1f475c4903627272c001357cabc70d8b4c62520cbdae8cfab1dfdd51949f408 + languageName: node + linkType: hard + +"@npmcli/move-file@npm:^1.0.1": + version: 1.1.2 + resolution: "@npmcli/move-file@npm:1.1.2" + dependencies: + mkdirp: ^1.0.4 + rimraf: ^3.0.2 + checksum: c96381d4a37448ea280951e46233f7e541058cf57a57d4094dd4bdcaae43fa5872b5f2eb6bfb004591a68e29c5877abe3cdc210cb3588cbf20ab2877f31a7de7 + languageName: node + linkType: hard + +"@sinonjs/commons@npm:^1, @sinonjs/commons@npm:^1.3.0, @sinonjs/commons@npm:^1.4.0, @sinonjs/commons@npm:^1.7.0": + version: 1.8.3 + resolution: "@sinonjs/commons@npm:1.8.3" + dependencies: + type-detect: 4.0.8 + checksum: 6159726db5ce6bf9f2297f8427f7ca5b3dff45b31e5cee23496f1fa6ef0bb4eab878b23fb2c5e6446381f6a66aba4968ef2fc255c1180d753d4b8c271636a2e5 + languageName: node + linkType: hard + +"@sinonjs/formatio@npm:^3.2.1": + version: 3.2.2 + resolution: "@sinonjs/formatio@npm:3.2.2" + dependencies: + "@sinonjs/commons": ^1 + "@sinonjs/samsam": ^3.1.0 + checksum: ddc30698df9b0aa59204da93ca94fd04bc5672ac03c798c0a487c35d514d7d8e0ce0e4c72386fc80e29f59cb1cc54eeea3b7f804281b3c4e3dd2394de56c6e4a + languageName: node + linkType: hard + +"@sinonjs/samsam@npm:^3.1.0, @sinonjs/samsam@npm:^3.3.3": + version: 3.3.3 + resolution: "@sinonjs/samsam@npm:3.3.3" + dependencies: + "@sinonjs/commons": ^1.3.0 + array-from: ^2.1.1 + lodash: ^4.17.15 + checksum: 340f2f62dec3fa1e5e9300a75996bd12ab9d2da4f6b453fa5d1ee101cc5e58eb218af2e2584b496d41ba31c3c0854d47a691fd9a0d8b9092f3cb6a5c7a080856 + languageName: node + linkType: hard + +"@sinonjs/text-encoding@npm:^0.7.1": + version: 0.7.1 + resolution: "@sinonjs/text-encoding@npm:0.7.1" + checksum: 130de0bb568c5f8a611ec21d1a4e3f80ab0c5ec333010f49cfc1adc5cba6d8808699c8a587a46b0f0b016a1f4c1389bc96141e773e8460fcbb441875b2e91ba7 + languageName: node + linkType: hard + +"@tootallnate/once@npm:1": + version: 1.1.2 + resolution: "@tootallnate/once@npm:1.1.2" + checksum: e1fb1bbbc12089a0cb9433dc290f97bddd062deadb6178ce9bcb93bb7c1aecde5e60184bc7065aec42fe1663622a213493c48bbd4972d931aae48315f18e1be9 + languageName: node + linkType: hard + +"@tsconfig/node10@npm:^1.0.7": + version: 1.0.8 + resolution: "@tsconfig/node10@npm:1.0.8" + checksum: b8d5fffbc6b17ef64ef74f7fdbccee02a809a063ade785c3648dae59406bc207f70ea2c4296f92749b33019fa36a5ae716e42e49cc7f1bbf0fd147be0d6b970a + languageName: node + linkType: hard + +"@tsconfig/node12@npm:^1.0.7": + version: 1.0.9 + resolution: "@tsconfig/node12@npm:1.0.9" + checksum: a01b2400ab3582b86b589c6d31dcd0c0656f333adecde85d6d7d4086adb059808b82692380bb169546d189bf771ae21d02544a75b57bd6da4a5dd95f8567bec9 + languageName: node + linkType: hard + +"@tsconfig/node14@npm:^1.0.0": + version: 1.0.1 + resolution: "@tsconfig/node14@npm:1.0.1" + checksum: 976345e896c0f059867f94f8d0f6ddb8b1844fb62bf36b727de8a9a68f024857e5db97ed51d3325e23e0616a5e48c034ff51a8d595b3fe7e955f3587540489be + languageName: node + linkType: hard + +"@tsconfig/node16@npm:^1.0.2": + version: 1.0.2 + resolution: "@tsconfig/node16@npm:1.0.2" + checksum: ca94d3639714672bbfd55f03521d3f56bb6a25479bd425da81faf21f13e1e9d15f40f97377dedbbf477a5841c5b0c8f4cd1b391f33553d750b9202c54c2c07aa + languageName: node + linkType: hard + +"@types/json-schema@npm:^7.0.9": + version: 7.0.9 + resolution: "@types/json-schema@npm:7.0.9" + checksum: 259d0e25f11a21ba5c708f7ea47196bd396e379fddb79c76f9f4f62c945879dc21657904914313ec2754e443c5018ea8372362f323f30e0792897fdb2098a705 + languageName: node + linkType: hard + +"@types/lodash@npm:^4.14.176": + version: 4.14.178 + resolution: "@types/lodash@npm:4.14.178" + checksum: a69a04a60bfc5257c3130a554b4efa0c383f0141b7b3db8ab7cf07ad2a46ea085fce66d0242da41da7e5647b133d5dfb2c15add9cbed8d7fef955e4a1e5b3128 + languageName: node + linkType: hard + +"@types/mocha@npm:^9.1.0": + version: 9.1.0 + resolution: "@types/mocha@npm:9.1.0" + checksum: 21e1000dafcfe387c6812be41c44a47b48c27a74d5a70c3d5ef1bb5c88eadadfc74dba06e93f160e7248c8a57b3977b590f82504c801c9927816ecd4668023c0 + languageName: node + linkType: hard + +"@types/node@npm:^16.11.6": + version: 16.11.22 + resolution: "@types/node@npm:16.11.22" + checksum: 9d879b9b0427e21a11e3162917553d5bc3c7d68d1ef4aa631512144801fe59bc3b4da5965e7ea7c2db99394487b543d4f2499b318e12392574802ac4f975b7c4 + languageName: node + linkType: hard + +"@types/sinon@npm:^10.0.6": + version: 10.0.11 + resolution: "@types/sinon@npm:10.0.11" + dependencies: + "@types/sinonjs__fake-timers": "*" + checksum: 196f3e26985dca5dfb593592e4b64463e536c047a9f43aa2b328b16024a3b0e3fb27b7a3f3972c6ef75749f55012737eb6c63a1c2e9782b7fe5cbbd25f75fd62 + languageName: node + linkType: hard + +"@types/sinonjs__fake-timers@npm:*": + version: 8.1.1 + resolution: "@types/sinonjs__fake-timers@npm:8.1.1" + checksum: ca09d54d47091d87020824a73f026300fa06b17cd9f2f9b9387f28b549364b141ef194ee28db762f6588de71d8febcd17f753163cb7ea116b8387c18e80ebd5c + languageName: node + linkType: hard + +"@typescript-eslint/eslint-plugin@npm:^5.7.0": + version: 5.11.0 + resolution: "@typescript-eslint/eslint-plugin@npm:5.11.0" + dependencies: + "@typescript-eslint/scope-manager": 5.11.0 + "@typescript-eslint/type-utils": 5.11.0 + "@typescript-eslint/utils": 5.11.0 + debug: ^4.3.2 + functional-red-black-tree: ^1.0.1 + ignore: ^5.1.8 + regexpp: ^3.2.0 + semver: ^7.3.5 + tsutils: ^3.21.0 + peerDependencies: + "@typescript-eslint/parser": ^5.0.0 + eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + peerDependenciesMeta: + typescript: + optional: true + checksum: fa546ba4397f3e693870c39d1e8df6feccb728a7092be6312b78806a64c4ff4648cff0462503d3e510e8b173b9704c19e78d2a7af790ab1c0309782e33a89c32 + languageName: node + linkType: hard + +"@typescript-eslint/parser@npm:^5.7.0": + version: 5.11.0 + resolution: "@typescript-eslint/parser@npm:5.11.0" + dependencies: + "@typescript-eslint/scope-manager": 5.11.0 + "@typescript-eslint/types": 5.11.0 + "@typescript-eslint/typescript-estree": 5.11.0 + debug: ^4.3.2 + peerDependencies: + eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + peerDependenciesMeta: + typescript: + optional: true + checksum: 521b6e701d877dc0514c6a3992f4900aa6fea28ba7c0bc03c634dad2b50aa195401e45683dfebd9e8492a857cd84bba3b585d8fe8d0cd1d7e2720372c34c50a3 + languageName: node + linkType: hard + +"@typescript-eslint/scope-manager@npm:5.11.0": + version: 5.11.0 + resolution: "@typescript-eslint/scope-manager@npm:5.11.0" + dependencies: + "@typescript-eslint/types": 5.11.0 + "@typescript-eslint/visitor-keys": 5.11.0 + checksum: bf7feaed495ed4cafa1b89a2b73781b30061d019e1c1b3765dc8006e7f36b537f6f451e37c77400067771318b4f0c5915804084dc6299ea7c6ecde2daf0aca1c + languageName: node + linkType: hard + +"@typescript-eslint/type-utils@npm:5.11.0": + version: 5.11.0 + resolution: "@typescript-eslint/type-utils@npm:5.11.0" + dependencies: + "@typescript-eslint/utils": 5.11.0 + debug: ^4.3.2 + tsutils: ^3.21.0 + peerDependencies: + eslint: "*" + peerDependenciesMeta: + typescript: + optional: true + checksum: fd570806d82874289ded6bfd90ff5414d4365b95b4a2e911f7ff2fee6e2c7675d0f2f71580c24cb8be733c3dfe2cd33eedff99ae2aa50f61b1b5af76499074eb + languageName: node + linkType: hard + +"@typescript-eslint/types@npm:5.11.0": + version: 5.11.0 + resolution: "@typescript-eslint/types@npm:5.11.0" + checksum: b1531481da75a6c89510ad03f3db68e4797b25438bb902ee322bd1c154b83396016271cc00356dcdbc300a8ee421493aae803b8c716f36d7b4808fe045ae3a2a + languageName: node + linkType: hard + +"@typescript-eslint/typescript-estree@npm:5.11.0": + version: 5.11.0 + resolution: "@typescript-eslint/typescript-estree@npm:5.11.0" + dependencies: + "@typescript-eslint/types": 5.11.0 + "@typescript-eslint/visitor-keys": 5.11.0 + debug: ^4.3.2 + globby: ^11.0.4 + is-glob: ^4.0.3 + semver: ^7.3.5 + tsutils: ^3.21.0 + peerDependenciesMeta: + typescript: + optional: true + checksum: 7bda55501c586efd7f8065b4158016486d8af92b8419931fbea7cec9bfe074075de8cdebec8baa1ac8a5c3f973599b9dd44a51fced1792176e49cd60cc8e5442 + languageName: node + linkType: hard + +"@typescript-eslint/utils@npm:5.11.0": + version: 5.11.0 + resolution: "@typescript-eslint/utils@npm:5.11.0" + dependencies: + "@types/json-schema": ^7.0.9 + "@typescript-eslint/scope-manager": 5.11.0 + "@typescript-eslint/types": 5.11.0 + "@typescript-eslint/typescript-estree": 5.11.0 + eslint-scope: ^5.1.1 + eslint-utils: ^3.0.0 + peerDependencies: + eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + checksum: 5ab1a15db1e0a2fbb857a8a16325459ad3d5239066f2641aa93ad9f7d08252d3a4ca6ae356c51cba1c6c81a65d84883436566b01932fa55b64a69796b950900d + languageName: node + linkType: hard + +"@typescript-eslint/visitor-keys@npm:5.11.0": + version: 5.11.0 + resolution: "@typescript-eslint/visitor-keys@npm:5.11.0" + dependencies: + "@typescript-eslint/types": 5.11.0 + eslint-visitor-keys: ^3.0.0 + checksum: 8f0b6fe1e86bc93825a137be3220f57e3a4bee410cca5d35963a0cd416750b31291a73c4294676d94ed0f5066b4cfb3a8f512d409881daa550d1645f4381eb21 + languageName: node + linkType: hard + +"@ungap/promise-all-settled@npm:1.1.2": + version: 1.1.2 + resolution: "@ungap/promise-all-settled@npm:1.1.2" + checksum: 08d37fdfa23a6fe8139f1305313562ebad973f3fac01bcce2773b2bda5bcb0146dfdcf3cb6a722cf0a5f2ca0bc56a827eac8f1e7b3beddc548f654addf1fc34c + languageName: node + linkType: hard + +"abbrev@npm:1": + version: 1.1.1 + resolution: "abbrev@npm:1.1.1" + checksum: a4a97ec07d7ea112c517036882b2ac22f3109b7b19077dc656316d07d308438aac28e4d9746dc4d84bf6b1e75b4a7b0a5f3cb30592419f128ca9a8cee3bcfa17 + languageName: node + linkType: hard + +"acorn-jsx@npm:^5.3.1": + version: 5.3.2 + resolution: "acorn-jsx@npm:5.3.2" + peerDependencies: + acorn: ^6.0.0 || ^7.0.0 || ^8.0.0 + checksum: c3d3b2a89c9a056b205b69530a37b972b404ee46ec8e5b341666f9513d3163e2a4f214a71f4dfc7370f5a9c07472d2fd1c11c91c3f03d093e37637d95da98950 + languageName: node + linkType: hard + +"acorn-walk@npm:^8.1.1": + version: 8.2.0 + resolution: "acorn-walk@npm:8.2.0" + checksum: 1715e76c01dd7b2d4ca472f9c58968516a4899378a63ad5b6c2d668bba8da21a71976c14ec5f5b75f887b6317c4ae0b897ab141c831d741dc76024d8745f1ad1 + languageName: node + linkType: hard + +"acorn@npm:^8.4.1, acorn@npm:^8.7.0": + version: 8.7.0 + resolution: "acorn@npm:8.7.0" + bin: + acorn: bin/acorn + checksum: e0f79409d68923fbf1aa6d4166f3eedc47955320d25c89a20cc822e6ba7c48c5963d5bc657bc242d68f7a4ac9faf96eef033e8f73656da6c640d4219935fdfd0 + languageName: node + linkType: hard + +"agent-base@npm:6, agent-base@npm:^6.0.2": + version: 6.0.2 + resolution: "agent-base@npm:6.0.2" + dependencies: + debug: 4 + checksum: f52b6872cc96fd5f622071b71ef200e01c7c4c454ee68bc9accca90c98cfb39f2810e3e9aa330435835eedc8c23f4f8a15267f67c6e245d2b33757575bdac49d + languageName: node + linkType: hard + +"agentkeepalive@npm:^4.1.3": + version: 4.2.0 + resolution: "agentkeepalive@npm:4.2.0" + dependencies: + debug: ^4.1.0 + depd: ^1.1.2 + humanize-ms: ^1.2.1 + checksum: 89806f83ceebbcaabf6bd581a8dce4870910fd2a11f66df8f505b4cd4ce4ca5ab9e6eec8d11ce8531a6b60f6748b75b0775e0e2fa33871503ef00d535418a19a + languageName: node + linkType: hard + +"aggregate-error@npm:^3.0.0": + version: 3.1.0 + resolution: "aggregate-error@npm:3.1.0" + dependencies: + clean-stack: ^2.0.0 + indent-string: ^4.0.0 + checksum: 1101a33f21baa27a2fa8e04b698271e64616b886795fd43c31068c07533c7b3facfcaf4e9e0cab3624bd88f729a592f1c901a1a229c9e490eafce411a8644b79 + languageName: node + linkType: hard + +"ajv@npm:^6.10.0, ajv@npm:^6.12.4": + version: 6.12.6 + resolution: "ajv@npm:6.12.6" + dependencies: + fast-deep-equal: ^3.1.1 + fast-json-stable-stringify: ^2.0.0 + json-schema-traverse: ^0.4.1 + uri-js: ^4.2.2 + checksum: 874972efe5c4202ab0a68379481fbd3d1b5d0a7bd6d3cc21d40d3536ebff3352a2a1fabb632d4fd2cc7fe4cbdcd5ed6782084c9bbf7f32a1536d18f9da5007d4 + languageName: node + linkType: hard + +"ansi-colors@npm:4.1.1": + version: 4.1.1 + resolution: "ansi-colors@npm:4.1.1" + checksum: 138d04a51076cb085da0a7e2d000c5c0bb09f6e772ed5c65c53cb118d37f6c5f1637506d7155fb5f330f0abcf6f12fa2e489ac3f8cdab9da393bf1bb4f9a32b0 + languageName: node + linkType: hard + +"ansi-regex@npm:^5.0.1": + version: 5.0.1 + resolution: "ansi-regex@npm:5.0.1" + checksum: 2aa4bb54caf2d622f1afdad09441695af2a83aa3fe8b8afa581d205e57ed4261c183c4d3877cee25794443fde5876417d859c108078ab788d6af7e4fe52eb66b + languageName: node + linkType: hard + +"ansi-styles@npm:^3.2.1": + version: 3.2.1 + resolution: "ansi-styles@npm:3.2.1" + dependencies: + color-convert: ^1.9.0 + checksum: d85ade01c10e5dd77b6c89f34ed7531da5830d2cb5882c645f330079975b716438cd7ebb81d0d6e6b4f9c577f19ae41ab55f07f19786b02f9dfd9e0377395665 + languageName: node + linkType: hard + +"ansi-styles@npm:^4.0.0, ansi-styles@npm:^4.1.0": + version: 4.3.0 + resolution: "ansi-styles@npm:4.3.0" + dependencies: + color-convert: ^2.0.1 + checksum: 513b44c3b2105dd14cc42a19271e80f386466c4be574bccf60b627432f9198571ebf4ab1e4c3ba17347658f4ee1711c163d574248c0c1cdc2d5917a0ad582ec4 + languageName: node + linkType: hard + +"anymatch@npm:~3.1.2": + version: 3.1.2 + resolution: "anymatch@npm:3.1.2" + dependencies: + normalize-path: ^3.0.0 + picomatch: ^2.0.4 + checksum: 985163db2292fac9e5a1e072bf99f1b5baccf196e4de25a0b0b81865ebddeb3b3eb4480734ef0a2ac8c002845396b91aa89121f5b84f93981a4658164a9ec6e9 + languageName: node + linkType: hard + +"append-transform@npm:^2.0.0": + version: 2.0.0 + resolution: "append-transform@npm:2.0.0" + dependencies: + default-require-extensions: ^3.0.0 + checksum: f26f393bf7a428fd1bb18f2758a819830a582243310c5170edb3f98fdc5a535333d02b952f7c2d9b14522bd8ead5b132a0b15000eca18fa9f49172963ebbc231 + languageName: node + linkType: hard + +"aproba@npm:^1.0.3 || ^2.0.0": + version: 2.0.0 + resolution: "aproba@npm:2.0.0" + checksum: 5615cadcfb45289eea63f8afd064ab656006361020e1735112e346593856f87435e02d8dcc7ff0d11928bc7d425f27bc7c2a84f6c0b35ab0ff659c814c138a24 + languageName: node + linkType: hard + +"archy@npm:^1.0.0": + version: 1.0.0 + resolution: "archy@npm:1.0.0" + checksum: 504ae7af655130bab9f471343cfdb054feaec7d8e300e13348bc9fe9e660f83d422e473069584f73233c701ae37d1c8452ff2522f2a20c38849e0f406f1732ac + languageName: node + linkType: hard + +"are-we-there-yet@npm:^2.0.0": + version: 2.0.0 + resolution: "are-we-there-yet@npm:2.0.0" + dependencies: + delegates: ^1.0.0 + readable-stream: ^3.6.0 + checksum: 6c80b4fd04ecee6ba6e737e0b72a4b41bdc64b7d279edfc998678567ff583c8df27e27523bc789f2c99be603ffa9eaa612803da1d886962d2086e7ff6fa90c7c + languageName: node + linkType: hard + +"arg@npm:^4.1.0": + version: 4.1.3 + resolution: "arg@npm:4.1.3" + checksum: 544af8dd3f60546d3e4aff084d451b96961d2267d668670199692f8d054f0415d86fc5497d0e641e91546f0aa920e7c29e5250e99fc89f5552a34b5d93b77f43 + languageName: node + linkType: hard + +"argparse@npm:^1.0.7": + version: 1.0.10 + resolution: "argparse@npm:1.0.10" + dependencies: + sprintf-js: ~1.0.2 + checksum: 7ca6e45583a28de7258e39e13d81e925cfa25d7d4aacbf806a382d3c02fcb13403a07fb8aeef949f10a7cfe4a62da0e2e807b348a5980554cc28ee573ef95945 + languageName: node + linkType: hard + +"argparse@npm:^2.0.1": + version: 2.0.1 + resolution: "argparse@npm:2.0.1" + checksum: 83644b56493e89a254bae05702abf3a1101b4fa4d0ca31df1c9985275a5a5bd47b3c27b7fa0b71098d41114d8ca000e6ed90cad764b306f8a503665e4d517ced + languageName: node + linkType: hard + +"array-from@npm:^2.1.1": + version: 2.1.1 + resolution: "array-from@npm:2.1.1" + checksum: 4cd5fa27aa6133b99a57c2881d2a8a66ec59b8e17a0c900f7e8ac9a0a2fae450ed682b67435467bfa71ac9328d025a760c5c46a95586a352180c5a79fc13015d + languageName: node + linkType: hard + +"array-union@npm:^2.1.0": + version: 2.1.0 + resolution: "array-union@npm:2.1.0" + checksum: 5bee12395cba82da674931df6d0fea23c4aa4660cb3b338ced9f828782a65caa232573e6bf3968f23e0c5eb301764a382cef2f128b170a9dc59de0e36c39f98d + languageName: node + linkType: hard + +"axios@npm:^0.24.0": + version: 0.24.0 + resolution: "axios@npm:0.24.0" + dependencies: + follow-redirects: ^1.14.4 + checksum: 468cf496c08a6aadfb7e699bebdac02851e3043d4e7d282350804ea8900e30d368daa6e3cd4ab83b8ddb5a3b1e17a5a21ada13fc9cebd27b74828f47a4236316 + languageName: node + linkType: hard + +"balanced-match@npm:^1.0.0": + version: 1.0.2 + resolution: "balanced-match@npm:1.0.2" + checksum: 9706c088a283058a8a99e0bf91b0a2f75497f185980d9ffa8b304de1d9e58ebda7c72c07ebf01dadedaac5b2907b2c6f566f660d62bd336c3468e960403b9d65 + languageName: node + linkType: hard + +"binary-extensions@npm:^2.0.0": + version: 2.2.0 + resolution: "binary-extensions@npm:2.2.0" + checksum: ccd267956c58d2315f5d3ea6757cf09863c5fc703e50fbeb13a7dc849b812ef76e3cf9ca8f35a0c48498776a7478d7b4a0418e1e2b8cb9cb9731f2922aaad7f8 + languageName: node + linkType: hard + +"brace-expansion@npm:^1.1.7": + version: 1.1.11 + resolution: "brace-expansion@npm:1.1.11" + dependencies: + balanced-match: ^1.0.0 + concat-map: 0.0.1 + checksum: faf34a7bb0c3fcf4b59c7808bc5d2a96a40988addf2e7e09dfbb67a2251800e0d14cd2bfc1aa79174f2f5095c54ff27f46fb1289fe2d77dac755b5eb3434cc07 + languageName: node + linkType: hard + +"braces@npm:^3.0.1, braces@npm:~3.0.2": + version: 3.0.2 + resolution: "braces@npm:3.0.2" + dependencies: + fill-range: ^7.0.1 + checksum: e2a8e769a863f3d4ee887b5fe21f63193a891c68b612ddb4b68d82d1b5f3ff9073af066c343e9867a393fe4c2555dcb33e89b937195feb9c1613d259edfcd459 + languageName: node + linkType: hard + +"browser-stdout@npm:1.3.1": + version: 1.3.1 + resolution: "browser-stdout@npm:1.3.1" + checksum: b717b19b25952dd6af483e368f9bcd6b14b87740c3d226c2977a65e84666ffd67000bddea7d911f111a9b6ddc822b234de42d52ab6507bce4119a4cc003ef7b3 + languageName: node + linkType: hard + +"browserslist@npm:^4.17.5": + version: 4.19.1 + resolution: "browserslist@npm:4.19.1" + dependencies: + caniuse-lite: ^1.0.30001286 + electron-to-chromium: ^1.4.17 + escalade: ^3.1.1 + node-releases: ^2.0.1 + picocolors: ^1.0.0 + bin: + browserslist: cli.js + checksum: c0777fd483691638fd6801e16c9d809e1d65f6d2b06db2e806654be51045cbab1452a89841a2c5caea2cbe19d621b4f1d391cffbb24512aa33280039ab345875 + languageName: node + linkType: hard + +"cacache@npm:^15.2.0": + version: 15.3.0 + resolution: "cacache@npm:15.3.0" + dependencies: + "@npmcli/fs": ^1.0.0 + "@npmcli/move-file": ^1.0.1 + chownr: ^2.0.0 + fs-minipass: ^2.0.0 + glob: ^7.1.4 + infer-owner: ^1.0.4 + lru-cache: ^6.0.0 + minipass: ^3.1.1 + minipass-collect: ^1.0.2 + minipass-flush: ^1.0.5 + minipass-pipeline: ^1.2.2 + mkdirp: ^1.0.3 + p-map: ^4.0.0 + promise-inflight: ^1.0.1 + rimraf: ^3.0.2 + ssri: ^8.0.1 + tar: ^6.0.2 + unique-filename: ^1.1.1 + checksum: a07327c27a4152c04eb0a831c63c00390d90f94d51bb80624a66f4e14a6b6360bbf02a84421267bd4d00ca73ac9773287d8d7169e8d2eafe378d2ce140579db8 + languageName: node + linkType: hard + +"caching-transform@npm:^4.0.0": + version: 4.0.0 + resolution: "caching-transform@npm:4.0.0" + dependencies: + hasha: ^5.0.0 + make-dir: ^3.0.0 + package-hash: ^4.0.0 + write-file-atomic: ^3.0.0 + checksum: c4db6939533b677866808de67c32f0aaf8bf4fd3e3b8dc957e5d630c007c06b7f11512d44c38a38287fb068e931067e8da9019c34d787259a44121c9a6b87a1f + languageName: node + linkType: hard + +"callsites@npm:^3.0.0": + version: 3.1.0 + resolution: "callsites@npm:3.1.0" + checksum: 072d17b6abb459c2ba96598918b55868af677154bec7e73d222ef95a8fdb9bbf7dae96a8421085cdad8cd190d86653b5b6dc55a4484f2e5b2e27d5e0c3fc15b3 + languageName: node + linkType: hard + +"camelcase@npm:^5.0.0, camelcase@npm:^5.3.1": + version: 5.3.1 + resolution: "camelcase@npm:5.3.1" + checksum: e6effce26b9404e3c0f301498184f243811c30dfe6d0b9051863bd8e4034d09c8c2923794f280d6827e5aa055f6c434115ff97864a16a963366fb35fd673024b + languageName: node + linkType: hard + +"camelcase@npm:^6.0.0": + version: 6.3.0 + resolution: "camelcase@npm:6.3.0" + checksum: 8c96818a9076434998511251dcb2761a94817ea17dbdc37f47ac080bd088fc62c7369429a19e2178b993497132c8cbcf5cc1f44ba963e76782ba469c0474938d + languageName: node + linkType: hard + +"caniuse-lite@npm:^1.0.30001286": + version: 1.0.30001309 + resolution: "caniuse-lite@npm:1.0.30001309" + checksum: 95093d01dc0880a371fe6aaf54cccb01a979933181a3aad6fc08e80c4601e27e1578a44d8ab6c1d3d58526ed2a917ce5e643c0e8299a0330cdac7bc8a7b5d7f0 + languageName: node + linkType: hard + +"chalk@npm:^2.0.0": + version: 2.4.2 + resolution: "chalk@npm:2.4.2" + dependencies: + ansi-styles: ^3.2.1 + escape-string-regexp: ^1.0.5 + supports-color: ^5.3.0 + checksum: ec3661d38fe77f681200f878edbd9448821924e0f93a9cefc0e26a33b145f1027a2084bf19967160d11e1f03bfe4eaffcabf5493b89098b2782c3fe0b03d80c2 + languageName: node + linkType: hard + +"chalk@npm:^4.0.0, chalk@npm:^4.1.0": + version: 4.1.2 + resolution: "chalk@npm:4.1.2" + dependencies: + ansi-styles: ^4.1.0 + supports-color: ^7.1.0 + checksum: fe75c9d5c76a7a98d45495b91b2172fa3b7a09e0cc9370e5c8feb1c567b85c4288e2b3fded7cfdd7359ac28d6b3844feb8b82b8686842e93d23c827c417e83fc + languageName: node + linkType: hard + +"chokidar@npm:3.5.3": + version: 3.5.3 + resolution: "chokidar@npm:3.5.3" + dependencies: + anymatch: ~3.1.2 + braces: ~3.0.2 + fsevents: ~2.3.2 + glob-parent: ~5.1.2 + is-binary-path: ~2.1.0 + is-glob: ~4.0.1 + normalize-path: ~3.0.0 + readdirp: ~3.6.0 + dependenciesMeta: + fsevents: + optional: true + checksum: b49fcde40176ba007ff361b198a2d35df60d9bb2a5aab228279eb810feae9294a6b4649ab15981304447afe1e6ffbf4788ad5db77235dc770ab777c6e771980c + languageName: node + linkType: hard + +"chownr@npm:^2.0.0": + version: 2.0.0 + resolution: "chownr@npm:2.0.0" + checksum: c57cf9dd0791e2f18a5ee9c1a299ae6e801ff58fee96dc8bfd0dcb4738a6ce58dd252a3605b1c93c6418fe4f9d5093b28ffbf4d66648cb2a9c67eaef9679be2f + languageName: node + linkType: hard + +"clean-stack@npm:^2.0.0": + version: 2.2.0 + resolution: "clean-stack@npm:2.2.0" + checksum: 2ac8cd2b2f5ec986a3c743935ec85b07bc174d5421a5efc8017e1f146a1cf5f781ae962618f416352103b32c9cd7e203276e8c28241bbe946160cab16149fb68 + languageName: node + linkType: hard + +"cliui@npm:^6.0.0": + version: 6.0.0 + resolution: "cliui@npm:6.0.0" + dependencies: + string-width: ^4.2.0 + strip-ansi: ^6.0.0 + wrap-ansi: ^6.2.0 + checksum: 4fcfd26d292c9f00238117f39fc797608292ae36bac2168cfee4c85923817d0607fe21b3329a8621e01aedf512c99b7eaa60e363a671ffd378df6649fb48ae42 + languageName: node + linkType: hard + +"cliui@npm:^7.0.2": + version: 7.0.4 + resolution: "cliui@npm:7.0.4" + dependencies: + string-width: ^4.2.0 + strip-ansi: ^6.0.0 + wrap-ansi: ^7.0.0 + checksum: ce2e8f578a4813806788ac399b9e866297740eecd4ad1823c27fd344d78b22c5f8597d548adbcc46f0573e43e21e751f39446c5a5e804a12aace402b7a315d7f + languageName: node + linkType: hard + +"color-convert@npm:^1.9.0": + version: 1.9.3 + resolution: "color-convert@npm:1.9.3" + dependencies: + color-name: 1.1.3 + checksum: fd7a64a17cde98fb923b1dd05c5f2e6f7aefda1b60d67e8d449f9328b4e53b228a428fd38bfeaeb2db2ff6b6503a776a996150b80cdf224062af08a5c8a3a203 + languageName: node + linkType: hard + +"color-convert@npm:^2.0.1": + version: 2.0.1 + resolution: "color-convert@npm:2.0.1" + dependencies: + color-name: ~1.1.4 + checksum: 79e6bdb9fd479a205c71d89574fccfb22bd9053bd98c6c4d870d65c132e5e904e6034978e55b43d69fcaa7433af2016ee203ce76eeba9cfa554b373e7f7db336 + languageName: node + linkType: hard + +"color-name@npm:1.1.3": + version: 1.1.3 + resolution: "color-name@npm:1.1.3" + checksum: 09c5d3e33d2105850153b14466501f2bfb30324a2f76568a408763a3b7433b0e50e5b4ab1947868e65cb101bb7cb75029553f2c333b6d4b8138a73fcc133d69d + languageName: node + linkType: hard + +"color-name@npm:~1.1.4": + version: 1.1.4 + resolution: "color-name@npm:1.1.4" + checksum: b0445859521eb4021cd0fb0cc1a75cecf67fceecae89b63f62b201cca8d345baf8b952c966862a9d9a2632987d4f6581f0ec8d957dfacece86f0a7919316f610 + languageName: node + linkType: hard + +"color-support@npm:^1.1.2": + version: 1.1.3 + resolution: "color-support@npm:1.1.3" + bin: + color-support: bin.js + checksum: 9b7356817670b9a13a26ca5af1c21615463b500783b739b7634a0c2047c16cef4b2865d7576875c31c3cddf9dd621fa19285e628f20198b233a5cfdda6d0793b + languageName: node + linkType: hard + +"commondir@npm:^1.0.1": + version: 1.0.1 + resolution: "commondir@npm:1.0.1" + checksum: 59715f2fc456a73f68826285718503340b9f0dd89bfffc42749906c5cf3d4277ef11ef1cca0350d0e79204f00f1f6d83851ececc9095dc88512a697ac0b9bdcb + languageName: node + linkType: hard + +"concat-map@npm:0.0.1": + version: 0.0.1 + resolution: "concat-map@npm:0.0.1" + checksum: 902a9f5d8967a3e2faf138d5cb784b9979bad2e6db5357c5b21c568df4ebe62bcb15108af1b2253744844eb964fc023fbd9afbbbb6ddd0bcc204c6fb5b7bf3af + languageName: node + linkType: hard + +"console-control-strings@npm:^1.0.0, console-control-strings@npm:^1.1.0": + version: 1.1.0 + resolution: "console-control-strings@npm:1.1.0" + checksum: 8755d76787f94e6cf79ce4666f0c5519906d7f5b02d4b884cf41e11dcd759ed69c57da0670afd9236d229a46e0f9cf519db0cd829c6dca820bb5a5c3def584ed + languageName: node + linkType: hard + +"convert-source-map@npm:^1.7.0": + version: 1.8.0 + resolution: "convert-source-map@npm:1.8.0" + dependencies: + safe-buffer: ~5.1.1 + checksum: 985d974a2d33e1a2543ada51c93e1ba2f73eaed608dc39f229afc78f71dcc4c8b7d7c684aa647e3c6a3a204027444d69e53e169ce94e8d1fa8d7dee80c9c8fed + languageName: node + linkType: hard + +"create-require@npm:^1.1.0": + version: 1.1.1 + resolution: "create-require@npm:1.1.1" + checksum: a9a1503d4390d8b59ad86f4607de7870b39cad43d929813599a23714831e81c520bddf61bcdd1f8e30f05fd3a2b71ae8538e946eb2786dc65c2bbc520f692eff + languageName: node + linkType: hard + +"cross-spawn@npm:^7.0.0, cross-spawn@npm:^7.0.2": + version: 7.0.3 + resolution: "cross-spawn@npm:7.0.3" + dependencies: + path-key: ^3.1.0 + shebang-command: ^2.0.0 + which: ^2.0.1 + checksum: 671cc7c7288c3a8406f3c69a3ae2fc85555c04169e9d611def9a675635472614f1c0ed0ef80955d5b6d4e724f6ced67f0ad1bb006c2ea643488fcfef994d7f52 + languageName: node + linkType: hard + +"debug@npm:4, debug@npm:4.3.3, debug@npm:^4.1.0, debug@npm:^4.1.1, debug@npm:^4.3.1, debug@npm:^4.3.2": + version: 4.3.3 + resolution: "debug@npm:4.3.3" + dependencies: + ms: 2.1.2 + peerDependenciesMeta: + supports-color: + optional: true + checksum: 14472d56fe4a94dbcfaa6dbed2dd3849f1d72ba78104a1a328047bb564643ca49df0224c3a17fa63533fd11dd3d4c8636cd861191232a2c6735af00cc2d4de16 + languageName: node + linkType: hard + +"decamelize@npm:^1.2.0": + version: 1.2.0 + resolution: "decamelize@npm:1.2.0" + checksum: ad8c51a7e7e0720c70ec2eeb1163b66da03e7616d7b98c9ef43cce2416395e84c1e9548dd94f5f6ffecfee9f8b94251fc57121a8b021f2ff2469b2bae247b8aa + languageName: node + linkType: hard + +"decamelize@npm:^4.0.0": + version: 4.0.0 + resolution: "decamelize@npm:4.0.0" + checksum: b7d09b82652c39eead4d6678bb578e3bebd848add894b76d0f6b395bc45b2d692fb88d977e7cfb93c4ed6c119b05a1347cef261174916c2e75c0a8ca57da1809 + languageName: node + linkType: hard + +"deep-is@npm:^0.1.3": + version: 0.1.4 + resolution: "deep-is@npm:0.1.4" + checksum: edb65dd0d7d1b9c40b2f50219aef30e116cedd6fc79290e740972c132c09106d2e80aa0bc8826673dd5a00222d4179c84b36a790eef63a4c4bca75a37ef90804 + languageName: node + linkType: hard + +"default-require-extensions@npm:^3.0.0": + version: 3.0.0 + resolution: "default-require-extensions@npm:3.0.0" + dependencies: + strip-bom: ^4.0.0 + checksum: 0b5bdb6786ebb0ff6ef55386f37c8d221963fbbd3009588fe71032c85ca16da05eff2ad01bfe9bfc8bac5ce95a18f66b38c50d454482e3e9d2de1142424a3e7c + languageName: node + linkType: hard + +"delegates@npm:^1.0.0": + version: 1.0.0 + resolution: "delegates@npm:1.0.0" + checksum: a51744d9b53c164ba9c0492471a1a2ffa0b6727451bdc89e31627fdf4adda9d51277cfcbfb20f0a6f08ccb3c436f341df3e92631a3440226d93a8971724771fd + languageName: node + linkType: hard + +"depd@npm:^1.1.2": + version: 1.1.2 + resolution: "depd@npm:1.1.2" + checksum: 6b406620d269619852885ce15965272b829df6f409724415e0002c8632ab6a8c0a08ec1f0bd2add05dc7bd7507606f7e2cc034fa24224ab829580040b835ecd9 + languageName: node + linkType: hard + +"diff@npm:5.0.0": + version: 5.0.0 + resolution: "diff@npm:5.0.0" + checksum: f19fe29284b633afdb2725c2a8bb7d25761ea54d321d8e67987ac851c5294be4afeab532bd84531e02583a3fe7f4014aa314a3eda84f5590e7a9e6b371ef3b46 + languageName: node + linkType: hard + +"diff@npm:^3.5.0": + version: 3.5.0 + resolution: "diff@npm:3.5.0" + checksum: 00842950a6551e26ce495bdbce11047e31667deea546527902661f25cc2e73358967ebc78cf86b1a9736ec3e14286433225f9970678155753a6291c3bca5227b + languageName: node + linkType: hard + +"diff@npm:^4.0.1": + version: 4.0.2 + resolution: "diff@npm:4.0.2" + checksum: f2c09b0ce4e6b301c221addd83bf3f454c0bc00caa3dd837cf6c127d6edf7223aa2bbe3b688feea110b7f262adbfc845b757c44c8a9f8c0c5b15d8fa9ce9d20d + languageName: node + linkType: hard + +"dir-glob@npm:^3.0.1": + version: 3.0.1 + resolution: "dir-glob@npm:3.0.1" + dependencies: + path-type: ^4.0.0 + checksum: fa05e18324510d7283f55862f3161c6759a3f2f8dbce491a2fc14c8324c498286c54282c1f0e933cb930da8419b30679389499b919122952a4f8592362ef4615 + languageName: node + linkType: hard + +"doctrine@npm:^3.0.0": + version: 3.0.0 + resolution: "doctrine@npm:3.0.0" + dependencies: + esutils: ^2.0.2 + checksum: fd7673ca77fe26cd5cba38d816bc72d641f500f1f9b25b83e8ce28827fe2da7ad583a8da26ab6af85f834138cf8dae9f69b0cd6ab925f52ddab1754db44d99ce + languageName: node + linkType: hard + +"electron-to-chromium@npm:^1.4.17": + version: 1.4.66 + resolution: "electron-to-chromium@npm:1.4.66" + checksum: 336b02aff50f221c4df2daf4268eff32bb9ef90c9962bce46af7a0ed9f85cad74c19cdc71eddb85a5e5bd2fb94a43eb0c3720679d2e99294c33dd2d03aace013 + languageName: node + linkType: hard + +"emoji-regex@npm:^8.0.0": + version: 8.0.0 + resolution: "emoji-regex@npm:8.0.0" + checksum: d4c5c39d5a9868b5fa152f00cada8a936868fd3367f33f71be515ecee4c803132d11b31a6222b2571b1e5f7e13890156a94880345594d0ce7e3c9895f560f192 + languageName: node + linkType: hard + +"encoding@npm:^0.1.12": + version: 0.1.13 + resolution: "encoding@npm:0.1.13" + dependencies: + iconv-lite: ^0.6.2 + checksum: bb98632f8ffa823996e508ce6a58ffcf5856330fde839ae42c9e1f436cc3b5cc651d4aeae72222916545428e54fd0f6aa8862fd8d25bdbcc4589f1e3f3715e7f + languageName: node + linkType: hard + +"env-paths@npm:^2.2.0": + version: 2.2.1 + resolution: "env-paths@npm:2.2.1" + checksum: 65b5df55a8bab92229ab2b40dad3b387fad24613263d103a97f91c9fe43ceb21965cd3392b1ccb5d77088021e525c4e0481adb309625d0cb94ade1d1fb8dc17e + languageName: node + linkType: hard + +"err-code@npm:^2.0.2": + version: 2.0.3 + resolution: "err-code@npm:2.0.3" + checksum: 8b7b1be20d2de12d2255c0bc2ca638b7af5171142693299416e6a9339bd7d88fc8d7707d913d78e0993176005405a236b066b45666b27b797252c771156ace54 + languageName: node + linkType: hard + +"es6-error@npm:^4.0.1": + version: 4.1.1 + resolution: "es6-error@npm:4.1.1" + checksum: ae41332a51ec1323da6bbc5d75b7803ccdeddfae17c41b6166ebbafc8e8beb7a7b80b884b7fab1cc80df485860ac3c59d78605e860bb4f8cd816b3d6ade0d010 + languageName: node + linkType: hard + +"escalade@npm:^3.1.1": + version: 3.1.1 + resolution: "escalade@npm:3.1.1" + checksum: a3e2a99f07acb74b3ad4989c48ca0c3140f69f923e56d0cba0526240ee470b91010f9d39001f2a4a313841d237ede70a729e92125191ba5d21e74b106800b133 + languageName: node + linkType: hard + +"escape-string-regexp@npm:4.0.0, escape-string-regexp@npm:^4.0.0": + version: 4.0.0 + resolution: "escape-string-regexp@npm:4.0.0" + checksum: 98b48897d93060f2322108bf29db0feba7dd774be96cd069458d1453347b25ce8682ecc39859d4bca2203cc0ab19c237bcc71755eff49a0f8d90beadeeba5cc5 + languageName: node + linkType: hard + +"escape-string-regexp@npm:^1.0.5": + version: 1.0.5 + resolution: "escape-string-regexp@npm:1.0.5" + checksum: 6092fda75c63b110c706b6a9bfde8a612ad595b628f0bd2147eea1d3406723020810e591effc7db1da91d80a71a737a313567c5abb3813e8d9c71f4aa595b410 + languageName: node + linkType: hard + +"eslint-config-prettier@npm:^8.3.0": + version: 8.3.0 + resolution: "eslint-config-prettier@npm:8.3.0" + peerDependencies: + eslint: ">=7.0.0" + bin: + eslint-config-prettier: bin/cli.js + checksum: df4cea3032671995bb5ab07e016169072f7fa59f44a53251664d9ca60951b66cdc872683b5c6a3729c91497c11490ca44a79654b395dd6756beb0c3903a37196 + languageName: node + linkType: hard + +"eslint-scope@npm:^5.1.1": + version: 5.1.1 + resolution: "eslint-scope@npm:5.1.1" + dependencies: + esrecurse: ^4.3.0 + estraverse: ^4.1.1 + checksum: 47e4b6a3f0cc29c7feedee6c67b225a2da7e155802c6ea13bbef4ac6b9e10c66cd2dcb987867ef176292bf4e64eccc680a49e35e9e9c669f4a02bac17e86abdb + languageName: node + linkType: hard + +"eslint-scope@npm:^7.1.0": + version: 7.1.0 + resolution: "eslint-scope@npm:7.1.0" + dependencies: + esrecurse: ^4.3.0 + estraverse: ^5.2.0 + checksum: 2070470a0725438ed47075b2574a4c03cf59aa32648da8cff9e3548c84f6b0079cfdb9ee1dd7ab0bfe97011f64b2af5bfd4b69cf14a1292130dec661eec7914a + languageName: node + linkType: hard + +"eslint-utils@npm:^3.0.0": + version: 3.0.0 + resolution: "eslint-utils@npm:3.0.0" + dependencies: + eslint-visitor-keys: ^2.0.0 + peerDependencies: + eslint: ">=5" + checksum: 0668fe02f5adab2e5a367eee5089f4c39033af20499df88fe4e6aba2015c20720404d8c3d6349b6f716b08fdf91b9da4e5d5481f265049278099c4c836ccb619 + languageName: node + linkType: hard + +"eslint-visitor-keys@npm:^2.0.0": + version: 2.1.0 + resolution: "eslint-visitor-keys@npm:2.1.0" + checksum: e3081d7dd2611a35f0388bbdc2f5da60b3a3c5b8b6e928daffff7391146b434d691577aa95064c8b7faad0b8a680266bcda0a42439c18c717b80e6718d7e267d + languageName: node + linkType: hard + +"eslint-visitor-keys@npm:^3.0.0, eslint-visitor-keys@npm:^3.1.0, eslint-visitor-keys@npm:^3.2.0": + version: 3.2.0 + resolution: "eslint-visitor-keys@npm:3.2.0" + checksum: fdadbb26f9e6417d3db7ad4f00bb0d573b6031c32fa72e8cdae32d038223faaeddff2ee443c90cb489bf774e75bff765c00912b8f9106d65e4f202ccd78c1b18 + languageName: node + linkType: hard + +"eslint@npm:^8.2.0": + version: 8.8.0 + resolution: "eslint@npm:8.8.0" + dependencies: + "@eslint/eslintrc": ^1.0.5 + "@humanwhocodes/config-array": ^0.9.2 + ajv: ^6.10.0 + chalk: ^4.0.0 + cross-spawn: ^7.0.2 + debug: ^4.3.2 + doctrine: ^3.0.0 + escape-string-regexp: ^4.0.0 + eslint-scope: ^7.1.0 + eslint-utils: ^3.0.0 + eslint-visitor-keys: ^3.2.0 + espree: ^9.3.0 + esquery: ^1.4.0 + esutils: ^2.0.2 + fast-deep-equal: ^3.1.3 + file-entry-cache: ^6.0.1 + functional-red-black-tree: ^1.0.1 + glob-parent: ^6.0.1 + globals: ^13.6.0 + ignore: ^5.2.0 + import-fresh: ^3.0.0 + imurmurhash: ^0.1.4 + is-glob: ^4.0.0 + js-yaml: ^4.1.0 + json-stable-stringify-without-jsonify: ^1.0.1 + levn: ^0.4.1 + lodash.merge: ^4.6.2 + minimatch: ^3.0.4 + natural-compare: ^1.4.0 + optionator: ^0.9.1 + regexpp: ^3.2.0 + strip-ansi: ^6.0.1 + strip-json-comments: ^3.1.0 + text-table: ^0.2.0 + v8-compile-cache: ^2.0.3 + bin: + eslint: bin/eslint.js + checksum: 41a7e85bf84cf9f2d758ef3e8d08020a39a2836703728b59535684681349bd021c2c6e24174462b844a914870d707d2151e0371198899d957b444de91adaa435 + languageName: node + linkType: hard + +"espree@npm:^9.2.0, espree@npm:^9.3.0": + version: 9.3.0 + resolution: "espree@npm:9.3.0" + dependencies: + acorn: ^8.7.0 + acorn-jsx: ^5.3.1 + eslint-visitor-keys: ^3.1.0 + checksum: c0f1885c4eab652f9be08eb9228cea0df046b559b29d4aed8d6590ea9bd60177d4cb245d204a6f737a79a096861bb4ab8e480aeb8c1dbafef5beec1157353ce4 + languageName: node + linkType: hard + +"esprima@npm:^4.0.0": + version: 4.0.1 + resolution: "esprima@npm:4.0.1" + bin: + esparse: ./bin/esparse.js + esvalidate: ./bin/esvalidate.js + checksum: b45bc805a613dbea2835278c306b91aff6173c8d034223fa81498c77dcbce3b2931bf6006db816f62eacd9fd4ea975dfd85a5b7f3c6402cfd050d4ca3c13a628 + languageName: node + linkType: hard + +"esquery@npm:^1.4.0": + version: 1.4.0 + resolution: "esquery@npm:1.4.0" + dependencies: + estraverse: ^5.1.0 + checksum: a0807e17abd7fbe5fbd4fab673038d6d8a50675cdae6b04fbaa520c34581be0c5fa24582990e8acd8854f671dd291c78bb2efb9e0ed5b62f33bac4f9cf820210 + languageName: node + linkType: hard + +"esrecurse@npm:^4.3.0": + version: 4.3.0 + resolution: "esrecurse@npm:4.3.0" + dependencies: + estraverse: ^5.2.0 + checksum: ebc17b1a33c51cef46fdc28b958994b1dc43cd2e86237515cbc3b4e5d2be6a811b2315d0a1a4d9d340b6d2308b15322f5c8291059521cc5f4802f65e7ec32837 + languageName: node + linkType: hard + +"estraverse@npm:^4.1.1": + version: 4.3.0 + resolution: "estraverse@npm:4.3.0" + checksum: a6299491f9940bb246124a8d44b7b7a413a8336f5436f9837aaa9330209bd9ee8af7e91a654a3545aee9c54b3308e78ee360cef1d777d37cfef77d2fa33b5827 + languageName: node + linkType: hard + +"estraverse@npm:^5.1.0, estraverse@npm:^5.2.0": + version: 5.3.0 + resolution: "estraverse@npm:5.3.0" + checksum: 072780882dc8416ad144f8fe199628d2b3e7bbc9989d9ed43795d2c90309a2047e6bc5979d7e2322a341163d22cfad9e21f4110597fe487519697389497e4e2b + languageName: node + linkType: hard + +"esutils@npm:^2.0.2": + version: 2.0.3 + resolution: "esutils@npm:2.0.3" + checksum: 22b5b08f74737379a840b8ed2036a5fb35826c709ab000683b092d9054e5c2a82c27818f12604bfc2a9a76b90b6834ef081edbc1c7ae30d1627012e067c6ec87 + languageName: node + linkType: hard + +"fast-deep-equal@npm:^3.1.1, fast-deep-equal@npm:^3.1.3": + version: 3.1.3 + resolution: "fast-deep-equal@npm:3.1.3" + checksum: e21a9d8d84f53493b6aa15efc9cfd53dd5b714a1f23f67fb5dc8f574af80df889b3bce25dc081887c6d25457cce704e636395333abad896ccdec03abaf1f3f9d + languageName: node + linkType: hard + +"fast-glob@npm:^3.2.9": + version: 3.2.11 + resolution: "fast-glob@npm:3.2.11" + dependencies: + "@nodelib/fs.stat": ^2.0.2 + "@nodelib/fs.walk": ^1.2.3 + glob-parent: ^5.1.2 + merge2: ^1.3.0 + micromatch: ^4.0.4 + checksum: f473105324a7780a20c06de842e15ddbb41d3cb7e71d1e4fe6e8373204f22245d54f5ab9e2061e6a1c613047345954d29b022e0e76f5c28b1df9858179a0e6d7 + languageName: node + linkType: hard + +"fast-json-stable-stringify@npm:^2.0.0": + version: 2.1.0 + resolution: "fast-json-stable-stringify@npm:2.1.0" + checksum: b191531e36c607977e5b1c47811158733c34ccb3bfde92c44798929e9b4154884378536d26ad90dfecd32e1ffc09c545d23535ad91b3161a27ddbb8ebe0cbecb + languageName: node + linkType: hard + +"fast-levenshtein@npm:^2.0.6": + version: 2.0.6 + resolution: "fast-levenshtein@npm:2.0.6" + checksum: 92cfec0a8dfafd9c7a15fba8f2cc29cd0b62b85f056d99ce448bbcd9f708e18ab2764bda4dd5158364f4145a7c72788538994f0d1787b956ef0d1062b0f7c24c + languageName: node + linkType: hard + +"fastq@npm:^1.6.0": + version: 1.13.0 + resolution: "fastq@npm:1.13.0" + dependencies: + reusify: ^1.0.4 + checksum: 32cf15c29afe622af187d12fc9cd93e160a0cb7c31a3bb6ace86b7dea3b28e7b72acde89c882663f307b2184e14782c6c664fa315973c03626c7d4bff070bb0b + languageName: node + linkType: hard + +"file-entry-cache@npm:^6.0.1": + version: 6.0.1 + resolution: "file-entry-cache@npm:6.0.1" + dependencies: + flat-cache: ^3.0.4 + checksum: f49701feaa6314c8127c3c2f6173cfefff17612f5ed2daaafc6da13b5c91fd43e3b2a58fd0d63f9f94478a501b167615931e7200e31485e320f74a33885a9c74 + languageName: node + linkType: hard + +"fill-range@npm:^7.0.1": + version: 7.0.1 + resolution: "fill-range@npm:7.0.1" + dependencies: + to-regex-range: ^5.0.1 + checksum: cc283f4e65b504259e64fd969bcf4def4eb08d85565e906b7d36516e87819db52029a76b6363d0f02d0d532f0033c9603b9e2d943d56ee3b0d4f7ad3328ff917 + languageName: node + linkType: hard + +"find-cache-dir@npm:^3.2.0": + version: 3.3.2 + resolution: "find-cache-dir@npm:3.3.2" + dependencies: + commondir: ^1.0.1 + make-dir: ^3.0.2 + pkg-dir: ^4.1.0 + checksum: 1e61c2e64f5c0b1c535bd85939ae73b0e5773142713273818cc0b393ee3555fb0fd44e1a5b161b8b6c3e03e98c2fcc9c227d784850a13a90a8ab576869576817 + languageName: node + linkType: hard + +"find-up@npm:5.0.0": + version: 5.0.0 + resolution: "find-up@npm:5.0.0" + dependencies: + locate-path: ^6.0.0 + path-exists: ^4.0.0 + checksum: 07955e357348f34660bde7920783204ff5a26ac2cafcaa28bace494027158a97b9f56faaf2d89a6106211a8174db650dd9f503f9c0d526b1202d5554a00b9095 + languageName: node + linkType: hard + +"find-up@npm:^4.0.0, find-up@npm:^4.1.0": + version: 4.1.0 + resolution: "find-up@npm:4.1.0" + dependencies: + locate-path: ^5.0.0 + path-exists: ^4.0.0 + checksum: 4c172680e8f8c1f78839486e14a43ef82e9decd0e74145f40707cc42e7420506d5ec92d9a11c22bd2c48fb0c384ea05dd30e10dd152fefeec6f2f75282a8b844 + languageName: node + linkType: hard + +"flat-cache@npm:^3.0.4": + version: 3.0.4 + resolution: "flat-cache@npm:3.0.4" + dependencies: + flatted: ^3.1.0 + rimraf: ^3.0.2 + checksum: 4fdd10ecbcbf7d520f9040dd1340eb5dfe951e6f0ecf2252edeec03ee68d989ec8b9a20f4434270e71bcfd57800dc09b3344fca3966b2eb8f613072c7d9a2365 + languageName: node + linkType: hard + +"flat@npm:^5.0.2": + version: 5.0.2 + resolution: "flat@npm:5.0.2" + bin: + flat: cli.js + checksum: 12a1536ac746db74881316a181499a78ef953632ddd28050b7a3a43c62ef5462e3357c8c29d76072bb635f147f7a9a1f0c02efef6b4be28f8db62ceb3d5c7f5d + languageName: node + linkType: hard + +"flatted@npm:^3.1.0": + version: 3.2.5 + resolution: "flatted@npm:3.2.5" + checksum: 3c436e9695ccca29620b4be5671dd72e5dd0a7500e0856611b7ca9bd8169f177f408c3b9abfa78dfe1493ee2d873e2c119080a8a9bee4e1a186a9e60ca6c89f1 + languageName: node + linkType: hard + +"follow-redirects@npm:^1.14.4": + version: 1.14.8 + resolution: "follow-redirects@npm:1.14.8" + peerDependenciesMeta: + debug: + optional: true + checksum: 40c67899c2e3149a27e8b6498a338ff27f39fe138fde8d7f0756cb44b073ba0bfec3d52af28f20c5bdd67263d564d0d8d7b5efefd431de95c18c42f7b4aef457 + languageName: node + linkType: hard + +"foreground-child@npm:^2.0.0": + version: 2.0.0 + resolution: "foreground-child@npm:2.0.0" + dependencies: + cross-spawn: ^7.0.0 + signal-exit: ^3.0.2 + checksum: f77ec9aff621abd6b754cb59e690743e7639328301fbea6ff09df27d2befaf7dd5b77cec51c32323d73a81a7d91caaf9413990d305cbe3d873eec4fe58960956 + languageName: node + linkType: hard + +"fromentries@npm:^1.2.0": + version: 1.3.2 + resolution: "fromentries@npm:1.3.2" + checksum: 33729c529ce19f5494f846f0dd4945078f4e37f4e8955f4ae8cc7385c218f600e9d93a7d225d17636c20d1889106fd87061f911550861b7072f53bf891e6b341 + languageName: node + linkType: hard + +"fs-minipass@npm:^2.0.0": + version: 2.1.0 + resolution: "fs-minipass@npm:2.1.0" + dependencies: + minipass: ^3.0.0 + checksum: 1b8d128dae2ac6cc94230cc5ead341ba3e0efaef82dab46a33d171c044caaa6ca001364178d42069b2809c35a1c3c35079a32107c770e9ffab3901b59af8c8b1 + languageName: node + linkType: hard + +"fs.realpath@npm:^1.0.0": + version: 1.0.0 + resolution: "fs.realpath@npm:1.0.0" + checksum: 99ddea01a7e75aa276c250a04eedeffe5662bce66c65c07164ad6264f9de18fb21be9433ead460e54cff20e31721c811f4fb5d70591799df5f85dce6d6746fd0 + languageName: node + linkType: hard + +"fsevents@npm:~2.3.2": + version: 2.3.2 + resolution: "fsevents@npm:2.3.2" + dependencies: + node-gyp: latest + checksum: 97ade64e75091afee5265e6956cb72ba34db7819b4c3e94c431d4be2b19b8bb7a2d4116da417950c3425f17c8fe693d25e20212cac583ac1521ad066b77ae31f + conditions: os=darwin + languageName: node + linkType: hard + +"fsevents@patch:fsevents@~2.3.2#~builtin": + version: 2.3.2 + resolution: "fsevents@patch:fsevents@npm%3A2.3.2#~builtin::version=2.3.2&hash=18f3a7" + dependencies: + node-gyp: latest + conditions: os=darwin + languageName: node + linkType: hard + +"functional-red-black-tree@npm:^1.0.1": + version: 1.0.1 + resolution: "functional-red-black-tree@npm:1.0.1" + checksum: ca6c170f37640e2d94297da8bb4bf27a1d12bea3e00e6a3e007fd7aa32e37e000f5772acf941b4e4f3cf1c95c3752033d0c509af157ad8f526e7f00723b9eb9f + languageName: node + linkType: hard + +"gauge@npm:^4.0.0": + version: 4.0.0 + resolution: "gauge@npm:4.0.0" + dependencies: + ansi-regex: ^5.0.1 + aproba: ^1.0.3 || ^2.0.0 + color-support: ^1.1.2 + console-control-strings: ^1.0.0 + has-unicode: ^2.0.1 + signal-exit: ^3.0.0 + string-width: ^4.2.3 + strip-ansi: ^6.0.1 + wide-align: ^1.1.2 + checksum: 637b34c84f518defa89319dbef68211a24e9302182ad2a619e3be1be5b7dcf2a962c8359e889294af667440f4722e7e6e61671859e00bd8ec280a136ded89b25 + languageName: node + linkType: hard + +"gensync@npm:^1.0.0-beta.2": + version: 1.0.0-beta.2 + resolution: "gensync@npm:1.0.0-beta.2" + checksum: a7437e58c6be12aa6c90f7730eac7fa9833dc78872b4ad2963d2031b00a3367a93f98aec75f9aaac7220848e4026d67a8655e870b24f20a543d103c0d65952ec + languageName: node + linkType: hard + +"get-caller-file@npm:^2.0.1, get-caller-file@npm:^2.0.5": + version: 2.0.5 + resolution: "get-caller-file@npm:2.0.5" + checksum: b9769a836d2a98c3ee734a88ba712e62703f1df31b94b784762c433c27a386dd6029ff55c2a920c392e33657d80191edbf18c61487e198844844516f843496b9 + languageName: node + linkType: hard + +"get-package-type@npm:^0.1.0": + version: 0.1.0 + resolution: "get-package-type@npm:0.1.0" + checksum: bba0811116d11e56d702682ddef7c73ba3481f114590e705fc549f4d868972263896af313c57a25c076e3c0d567e11d919a64ba1b30c879be985fc9d44f96148 + languageName: node + linkType: hard + +"glob-parent@npm:^5.1.2, glob-parent@npm:~5.1.2": + version: 5.1.2 + resolution: "glob-parent@npm:5.1.2" + dependencies: + is-glob: ^4.0.1 + checksum: f4f2bfe2425296e8a47e36864e4f42be38a996db40420fe434565e4480e3322f18eb37589617a98640c5dc8fdec1a387007ee18dbb1f3f5553409c34d17f425e + languageName: node + linkType: hard + +"glob-parent@npm:^6.0.1": + version: 6.0.2 + resolution: "glob-parent@npm:6.0.2" + dependencies: + is-glob: ^4.0.3 + checksum: c13ee97978bef4f55106b71e66428eb1512e71a7466ba49025fc2aec59a5bfb0954d5abd58fc5ee6c9b076eef4e1f6d3375c2e964b88466ca390da4419a786a8 + languageName: node + linkType: hard + +"glob@npm:7.2.0, glob@npm:^7.1.3, glob@npm:^7.1.4, glob@npm:^7.1.6": + version: 7.2.0 + resolution: "glob@npm:7.2.0" + dependencies: + fs.realpath: ^1.0.0 + inflight: ^1.0.4 + inherits: 2 + minimatch: ^3.0.4 + once: ^1.3.0 + path-is-absolute: ^1.0.0 + checksum: 78a8ea942331f08ed2e055cb5b9e40fe6f46f579d7fd3d694f3412fe5db23223d29b7fee1575440202e9a7ff9a72ab106a39fee39934c7bedafe5e5f8ae20134 + languageName: node + linkType: hard + +"globals@npm:^11.1.0": + version: 11.12.0 + resolution: "globals@npm:11.12.0" + checksum: 67051a45eca3db904aee189dfc7cd53c20c7d881679c93f6146ddd4c9f4ab2268e68a919df740d39c71f4445d2b38ee360fc234428baea1dbdfe68bbcb46979e + languageName: node + linkType: hard + +"globals@npm:^13.6.0, globals@npm:^13.9.0": + version: 13.12.1 + resolution: "globals@npm:13.12.1" + dependencies: + type-fest: ^0.20.2 + checksum: cf7877629c8f2a293b0a7d09d1dcce7f2d426ec2528600c481c5b3f3d070b0a120eb2499439ac0404990fb8a5742c0165b1bf1f52603364001ddc89bea3dda24 + languageName: node + linkType: hard + +"globby@npm:^11.0.4": + version: 11.1.0 + resolution: "globby@npm:11.1.0" + dependencies: + array-union: ^2.1.0 + dir-glob: ^3.0.1 + fast-glob: ^3.2.9 + ignore: ^5.2.0 + merge2: ^1.4.1 + slash: ^3.0.0 + checksum: b4be8885e0cfa018fc783792942d53926c35c50b3aefd3fdcfb9d22c627639dc26bd2327a40a0b74b074100ce95bb7187bfeae2f236856aa3de183af7a02aea6 + languageName: node + linkType: hard + +"graceful-fs@npm:^4.1.15, graceful-fs@npm:^4.2.6": + version: 4.2.9 + resolution: "graceful-fs@npm:4.2.9" + checksum: 68ea4e07ff2c041ada184f9278b830375f8e0b75154e3f080af6b70f66172fabb4108d19b3863a96b53fc068a310b9b6493d86d1291acc5f3861eb4b79d26ad6 + languageName: node + linkType: hard + +"growl@npm:1.10.5": + version: 1.10.5 + resolution: "growl@npm:1.10.5" + checksum: 4b86685de6831cebcbb19f93870bea624afee61124b0a20c49017013987cd129e73a8c4baeca295728f41d21265e1f859d25ef36731b142ca59c655fea94bb1a + languageName: node + linkType: hard + +"has-flag@npm:^3.0.0": + version: 3.0.0 + resolution: "has-flag@npm:3.0.0" + checksum: 4a15638b454bf086c8148979aae044dd6e39d63904cd452d970374fa6a87623423da485dfb814e7be882e05c096a7ccf1ebd48e7e7501d0208d8384ff4dea73b + languageName: node + linkType: hard + +"has-flag@npm:^4.0.0": + version: 4.0.0 + resolution: "has-flag@npm:4.0.0" + checksum: 261a1357037ead75e338156b1f9452c016a37dcd3283a972a30d9e4a87441ba372c8b81f818cd0fbcd9c0354b4ae7e18b9e1afa1971164aef6d18c2b6095a8ad + languageName: node + linkType: hard + +"has-unicode@npm:^2.0.1": + version: 2.0.1 + resolution: "has-unicode@npm:2.0.1" + checksum: 1eab07a7436512db0be40a710b29b5dc21fa04880b7f63c9980b706683127e3c1b57cb80ea96d47991bdae2dfe479604f6a1ba410106ee1046a41d1bd0814400 + languageName: node + linkType: hard + +"hasha@npm:^5.0.0": + version: 5.2.2 + resolution: "hasha@npm:5.2.2" + dependencies: + is-stream: ^2.0.0 + type-fest: ^0.8.0 + checksum: 06cc474bed246761ff61c19d629977eb5f53fa817be4313a255a64ae0f433e831a29e83acb6555e3f4592b348497596f1d1653751008dda4f21c9c21ca60ac5a + languageName: node + linkType: hard + +"he@npm:1.2.0": + version: 1.2.0 + resolution: "he@npm:1.2.0" + bin: + he: bin/he + checksum: 3d4d6babccccd79c5c5a3f929a68af33360d6445587d628087f39a965079d84f18ce9c3d3f917ee1e3978916fc833bb8b29377c3b403f919426f91bc6965e7a7 + languageName: node + linkType: hard + +"html-escaper@npm:^2.0.0": + version: 2.0.2 + resolution: "html-escaper@npm:2.0.2" + checksum: d2df2da3ad40ca9ee3a39c5cc6475ef67c8f83c234475f24d8e9ce0dc80a2c82df8e1d6fa78ddd1e9022a586ea1bd247a615e80a5cd9273d90111ddda7d9e974 + languageName: node + linkType: hard + +"htmlencode@npm:^0.0.4": + version: 0.0.4 + resolution: "htmlencode@npm:0.0.4" + checksum: b5c5a280213569f59807d22ae2d68c77360f6337b6936cdfa4e2aeaa12e3a69bb36b426ad18ed9333a7fb3f7d55c14ea3b46040d3271af7a586f262aaf4092ad + languageName: node + linkType: hard + +"http-cache-semantics@npm:^4.1.0": + version: 4.1.0 + resolution: "http-cache-semantics@npm:4.1.0" + checksum: 974de94a81c5474be07f269f9fd8383e92ebb5a448208223bfb39e172a9dbc26feff250192ecc23b9593b3f92098e010406b0f24bd4d588d631f80214648ed42 + languageName: node + linkType: hard + +"http-proxy-agent@npm:^4.0.1": + version: 4.0.1 + resolution: "http-proxy-agent@npm:4.0.1" + dependencies: + "@tootallnate/once": 1 + agent-base: 6 + debug: 4 + checksum: c6a5da5a1929416b6bbdf77b1aca13888013fe7eb9d59fc292e25d18e041bb154a8dfada58e223fc7b76b9b2d155a87e92e608235201f77d34aa258707963a82 + languageName: node + linkType: hard + +"https-proxy-agent@npm:^5.0.0": + version: 5.0.0 + resolution: "https-proxy-agent@npm:5.0.0" + dependencies: + agent-base: 6 + debug: 4 + checksum: 165bfb090bd26d47693597661298006841ab733d0c7383a8cb2f17373387a94c903a3ac687090aa739de05e379ab6f868bae84ab4eac288ad85c328cd1ec9e53 + languageName: node + linkType: hard + +"humanize-ms@npm:^1.2.1": + version: 1.2.1 + resolution: "humanize-ms@npm:1.2.1" + dependencies: + ms: ^2.0.0 + checksum: 9c7a74a2827f9294c009266c82031030eae811ca87b0da3dceb8d6071b9bde22c9f3daef0469c3c533cc67a97d8a167cd9fc0389350e5f415f61a79b171ded16 + languageName: node + linkType: hard + +"iconv-lite@npm:^0.6.2": + version: 0.6.3 + resolution: "iconv-lite@npm:0.6.3" + dependencies: + safer-buffer: ">= 2.1.2 < 3.0.0" + checksum: 3f60d47a5c8fc3313317edfd29a00a692cc87a19cac0159e2ce711d0ebc9019064108323b5e493625e25594f11c6236647d8e256fbe7a58f4a3b33b89e6d30bf + languageName: node + linkType: hard + +"ignore@npm:^4.0.6": + version: 4.0.6 + resolution: "ignore@npm:4.0.6" + checksum: 248f82e50a430906f9ee7f35e1158e3ec4c3971451dd9f99c9bc1548261b4db2b99709f60ac6c6cac9333494384176cc4cc9b07acbe42d52ac6a09cad734d800 + languageName: node + linkType: hard + +"ignore@npm:^5.1.8, ignore@npm:^5.2.0": + version: 5.2.0 + resolution: "ignore@npm:5.2.0" + checksum: 6b1f926792d614f64c6c83da3a1f9c83f6196c2839aa41e1e32dd7b8d174cef2e329d75caabb62cb61ce9dc432f75e67d07d122a037312db7caa73166a1bdb77 + languageName: node + linkType: hard + +"import-fresh@npm:^3.0.0, import-fresh@npm:^3.2.1": + version: 3.3.0 + resolution: "import-fresh@npm:3.3.0" + dependencies: + parent-module: ^1.0.0 + resolve-from: ^4.0.0 + checksum: 2cacfad06e652b1edc50be650f7ec3be08c5e5a6f6d12d035c440a42a8cc028e60a5b99ca08a77ab4d6b1346da7d971915828f33cdab730d3d42f08242d09baa + languageName: node + linkType: hard + +"imurmurhash@npm:^0.1.4": + version: 0.1.4 + resolution: "imurmurhash@npm:0.1.4" + checksum: 7cae75c8cd9a50f57dadd77482359f659eaebac0319dd9368bcd1714f55e65badd6929ca58569da2b6494ef13fdd5598cd700b1eba23f8b79c5f19d195a3ecf7 + languageName: node + linkType: hard + +"indent-string@npm:^4.0.0": + version: 4.0.0 + resolution: "indent-string@npm:4.0.0" + checksum: 824cfb9929d031dabf059bebfe08cf3137365e112019086ed3dcff6a0a7b698cb80cf67ccccde0e25b9e2d7527aa6cc1fed1ac490c752162496caba3e6699612 + languageName: node + linkType: hard + +"infer-owner@npm:^1.0.4": + version: 1.0.4 + resolution: "infer-owner@npm:1.0.4" + checksum: 181e732764e4a0611576466b4b87dac338972b839920b2a8cde43642e4ed6bd54dc1fb0b40874728f2a2df9a1b097b8ff83b56d5f8f8e3927f837fdcb47d8a89 + languageName: node + linkType: hard + +"inflight@npm:^1.0.4": + version: 1.0.6 + resolution: "inflight@npm:1.0.6" + dependencies: + once: ^1.3.0 + wrappy: 1 + checksum: f4f76aa072ce19fae87ce1ef7d221e709afb59d445e05d47fba710e85470923a75de35bfae47da6de1b18afc3ce83d70facf44cfb0aff89f0a3f45c0a0244dfd + languageName: node + linkType: hard + +"inherits@npm:2, inherits@npm:^2.0.3": + version: 2.0.4 + resolution: "inherits@npm:2.0.4" + checksum: 4a48a733847879d6cf6691860a6b1e3f0f4754176e4d71494c41f3475553768b10f84b5ce1d40fbd0e34e6bfbb864ee35858ad4dd2cf31e02fc4a154b724d7f1 + languageName: node + linkType: hard + +"intercom-client@workspace:.": + version: 0.0.0-use.local + resolution: "intercom-client@workspace:." + dependencies: + "@istanbuljs/nyc-config-typescript": ^1.0.2 + "@types/lodash": ^4.14.176 + "@types/mocha": ^9.1.0 + "@types/node": ^16.11.6 + "@types/sinon": ^10.0.6 + "@typescript-eslint/eslint-plugin": ^5.7.0 + "@typescript-eslint/parser": ^5.7.0 + axios: ^0.24.0 + eslint: ^8.2.0 + eslint-config-prettier: ^8.3.0 + htmlencode: ^0.0.4 + lodash: ^4.17.21 + merge2: ^1.4.1 + mocha: ^9.2.0 + nock: ^13.0.11 + nyc: ^15.1.0 + prettier: ^2.5.1 + sinon: ^7.3.2 + ts-node: ^10.4.0 + tslib: ^2.3.1 + typescript: ^4.5.3 + languageName: unknown + linkType: soft + +"ip@npm:^1.1.5": + version: 1.1.5 + resolution: "ip@npm:1.1.5" + checksum: 30133981f082a060a32644f6a7746e9ba7ac9e2bc07ecc8bbdda3ee8ca9bec1190724c390e45a1ee7695e7edfd2a8f7dda2c104ec5f7ac5068c00648504c7e5a + languageName: node + linkType: hard + +"is-binary-path@npm:~2.1.0": + version: 2.1.0 + resolution: "is-binary-path@npm:2.1.0" + dependencies: + binary-extensions: ^2.0.0 + checksum: 84192eb88cff70d320426f35ecd63c3d6d495da9d805b19bc65b518984b7c0760280e57dbf119b7e9be6b161784a5a673ab2c6abe83abb5198a432232ad5b35c + languageName: node + linkType: hard + +"is-extglob@npm:^2.1.1": + version: 2.1.1 + resolution: "is-extglob@npm:2.1.1" + checksum: df033653d06d0eb567461e58a7a8c9f940bd8c22274b94bf7671ab36df5719791aae15eef6d83bbb5e23283967f2f984b8914559d4449efda578c775c4be6f85 + languageName: node + linkType: hard + +"is-fullwidth-code-point@npm:^3.0.0": + version: 3.0.0 + resolution: "is-fullwidth-code-point@npm:3.0.0" + checksum: 44a30c29457c7fb8f00297bce733f0a64cd22eca270f83e58c105e0d015e45c019491a4ab2faef91ab51d4738c670daff901c799f6a700e27f7314029e99e348 + languageName: node + linkType: hard + +"is-glob@npm:^4.0.0, is-glob@npm:^4.0.1, is-glob@npm:^4.0.3, is-glob@npm:~4.0.1": + version: 4.0.3 + resolution: "is-glob@npm:4.0.3" + dependencies: + is-extglob: ^2.1.1 + checksum: d381c1319fcb69d341cc6e6c7cd588e17cd94722d9a32dbd60660b993c4fb7d0f19438674e68dfec686d09b7c73139c9166b47597f846af387450224a8101ab4 + languageName: node + linkType: hard + +"is-lambda@npm:^1.0.1": + version: 1.0.1 + resolution: "is-lambda@npm:1.0.1" + checksum: 93a32f01940220532e5948538699ad610d5924ac86093fcee83022252b363eb0cc99ba53ab084a04e4fb62bf7b5731f55496257a4c38adf87af9c4d352c71c35 + languageName: node + linkType: hard + +"is-number@npm:^7.0.0": + version: 7.0.0 + resolution: "is-number@npm:7.0.0" + checksum: 456ac6f8e0f3111ed34668a624e45315201dff921e5ac181f8ec24923b99e9f32ca1a194912dc79d539c97d33dba17dc635202ff0b2cf98326f608323276d27a + languageName: node + linkType: hard + +"is-plain-obj@npm:^2.1.0": + version: 2.1.0 + resolution: "is-plain-obj@npm:2.1.0" + checksum: cec9100678b0a9fe0248a81743041ed990c2d4c99f893d935545cfbc42876cbe86d207f3b895700c690ad2fa520e568c44afc1605044b535a7820c1d40e38daa + languageName: node + linkType: hard + +"is-stream@npm:^2.0.0": + version: 2.0.1 + resolution: "is-stream@npm:2.0.1" + checksum: b8e05ccdf96ac330ea83c12450304d4a591f9958c11fd17bed240af8d5ffe08aedafa4c0f4cfccd4d28dc9d4d129daca1023633d5c11601a6cbc77521f6fae66 + languageName: node + linkType: hard + +"is-typedarray@npm:^1.0.0": + version: 1.0.0 + resolution: "is-typedarray@npm:1.0.0" + checksum: 3508c6cd0a9ee2e0df2fa2e9baabcdc89e911c7bd5cf64604586697212feec525aa21050e48affb5ffc3df20f0f5d2e2cf79b08caa64e1ccc9578e251763aef7 + languageName: node + linkType: hard + +"is-unicode-supported@npm:^0.1.0": + version: 0.1.0 + resolution: "is-unicode-supported@npm:0.1.0" + checksum: a2aab86ee7712f5c2f999180daaba5f361bdad1efadc9610ff5b8ab5495b86e4f627839d085c6530363c6d6d4ecbde340fb8e54bdb83da4ba8e0865ed5513c52 + languageName: node + linkType: hard + +"is-windows@npm:^1.0.2": + version: 1.0.2 + resolution: "is-windows@npm:1.0.2" + checksum: 438b7e52656fe3b9b293b180defb4e448088e7023a523ec21a91a80b9ff8cdb3377ddb5b6e60f7c7de4fa8b63ab56e121b6705fe081b3cf1b828b0a380009ad7 + languageName: node + linkType: hard + +"isarray@npm:0.0.1": + version: 0.0.1 + resolution: "isarray@npm:0.0.1" + checksum: 49191f1425681df4a18c2f0f93db3adb85573bcdd6a4482539d98eac9e705d8961317b01175627e860516a2fc45f8f9302db26e5a380a97a520e272e2a40a8d4 + languageName: node + linkType: hard + +"isexe@npm:^2.0.0": + version: 2.0.0 + resolution: "isexe@npm:2.0.0" + checksum: 26bf6c5480dda5161c820c5b5c751ae1e766c587b1f951ea3fcfc973bafb7831ae5b54a31a69bd670220e42e99ec154475025a468eae58ea262f813fdc8d1c62 + languageName: node + linkType: hard + +"istanbul-lib-coverage@npm:^3.0.0, istanbul-lib-coverage@npm:^3.0.0-alpha.1": + version: 3.2.0 + resolution: "istanbul-lib-coverage@npm:3.2.0" + checksum: a2a545033b9d56da04a8571ed05c8120bf10e9bce01cf8633a3a2b0d1d83dff4ac4fe78d6d5673c27fc29b7f21a41d75f83a36be09f82a61c367b56aa73c1ff9 + languageName: node + linkType: hard + +"istanbul-lib-hook@npm:^3.0.0": + version: 3.0.0 + resolution: "istanbul-lib-hook@npm:3.0.0" + dependencies: + append-transform: ^2.0.0 + checksum: ac4d0a0751e959cfe4c95d817df5f1f573f9b0cf892552e60d81785654291391fac1ceb667f13bb17fcc2ef23b74c89ed8cf1c6148c833c8596a2b920b079101 + languageName: node + linkType: hard + +"istanbul-lib-instrument@npm:^4.0.0": + version: 4.0.3 + resolution: "istanbul-lib-instrument@npm:4.0.3" + dependencies: + "@babel/core": ^7.7.5 + "@istanbuljs/schema": ^0.1.2 + istanbul-lib-coverage: ^3.0.0 + semver: ^6.3.0 + checksum: fa1171d3022b1bb8f6a734042620ac5d9ee7dc80f3065a0bb12863e9f0494d0eefa3d86608fcc0254ab2765d29d7dad8bdc42e5f8df2f9a1fbe85ccc59d76cb9 + languageName: node + linkType: hard + +"istanbul-lib-processinfo@npm:^2.0.2": + version: 2.0.2 + resolution: "istanbul-lib-processinfo@npm:2.0.2" + dependencies: + archy: ^1.0.0 + cross-spawn: ^7.0.0 + istanbul-lib-coverage: ^3.0.0-alpha.1 + make-dir: ^3.0.0 + p-map: ^3.0.0 + rimraf: ^3.0.0 + uuid: ^3.3.3 + checksum: 400bd0b25b623c172e48d37e5bdda7a58b2fe5beeedfeb03099aed3385223d31e4cfa6f9932be07bbf06cfd039023301bce81d3b70b9a20a79a38b0f12cb261a + languageName: node + linkType: hard + +"istanbul-lib-report@npm:^3.0.0": + version: 3.0.0 + resolution: "istanbul-lib-report@npm:3.0.0" + dependencies: + istanbul-lib-coverage: ^3.0.0 + make-dir: ^3.0.0 + supports-color: ^7.1.0 + checksum: 3f29eb3f53c59b987386e07fe772d24c7f58c6897f34c9d7a296f4000de7ae3de9eb95c3de3df91dc65b134c84dee35c54eee572a56243e8907c48064e34ff1b + languageName: node + linkType: hard + +"istanbul-lib-source-maps@npm:^4.0.0": + version: 4.0.1 + resolution: "istanbul-lib-source-maps@npm:4.0.1" + dependencies: + debug: ^4.1.1 + istanbul-lib-coverage: ^3.0.0 + source-map: ^0.6.1 + checksum: 21ad3df45db4b81852b662b8d4161f6446cd250c1ddc70ef96a585e2e85c26ed7cd9c2a396a71533cfb981d1a645508bc9618cae431e55d01a0628e7dec62ef2 + languageName: node + linkType: hard + +"istanbul-reports@npm:^3.0.2": + version: 3.1.4 + resolution: "istanbul-reports@npm:3.1.4" + dependencies: + html-escaper: ^2.0.0 + istanbul-lib-report: ^3.0.0 + checksum: 2132983355710c522f6b26808015cab9a0ee8b9f5ae0db0d3edeff40b886dd83cb670fb123cb7b32dbe59473d7c00cdde2ba6136bc0acdb20a865fccea64dfe1 + languageName: node + linkType: hard + +"js-tokens@npm:^4.0.0": + version: 4.0.0 + resolution: "js-tokens@npm:4.0.0" + checksum: 8a95213a5a77deb6cbe94d86340e8d9ace2b93bc367790b260101d2f36a2eaf4e4e22d9fa9cf459b38af3a32fb4190e638024cf82ec95ef708680e405ea7cc78 + languageName: node + linkType: hard + +"js-yaml@npm:4.1.0, js-yaml@npm:^4.1.0": + version: 4.1.0 + resolution: "js-yaml@npm:4.1.0" + dependencies: + argparse: ^2.0.1 + bin: + js-yaml: bin/js-yaml.js + checksum: c7830dfd456c3ef2c6e355cc5a92e6700ceafa1d14bba54497b34a99f0376cecbb3e9ac14d3e5849b426d5a5140709a66237a8c991c675431271c4ce5504151a + languageName: node + linkType: hard + +"js-yaml@npm:^3.13.1": + version: 3.14.1 + resolution: "js-yaml@npm:3.14.1" + dependencies: + argparse: ^1.0.7 + esprima: ^4.0.0 + bin: + js-yaml: bin/js-yaml.js + checksum: bef146085f472d44dee30ec34e5cf36bf89164f5d585435a3d3da89e52622dff0b188a580e4ad091c3341889e14cb88cac6e4deb16dc5b1e9623bb0601fc255c + languageName: node + linkType: hard + +"jsesc@npm:^2.5.1": + version: 2.5.2 + resolution: "jsesc@npm:2.5.2" + bin: + jsesc: bin/jsesc + checksum: 4dc190771129e12023f729ce20e1e0bfceac84d73a85bc3119f7f938843fe25a4aeccb54b6494dce26fcf263d815f5f31acdefac7cc9329efb8422a4f4d9fa9d + languageName: node + linkType: hard + +"json-schema-traverse@npm:^0.4.1": + version: 0.4.1 + resolution: "json-schema-traverse@npm:0.4.1" + checksum: 7486074d3ba247769fda17d5181b345c9fb7d12e0da98b22d1d71a5db9698d8b4bd900a3ec1a4ffdd60846fc2556274a5c894d0c48795f14cb03aeae7b55260b + languageName: node + linkType: hard + +"json-stable-stringify-without-jsonify@npm:^1.0.1": + version: 1.0.1 + resolution: "json-stable-stringify-without-jsonify@npm:1.0.1" + checksum: cff44156ddce9c67c44386ad5cddf91925fe06b1d217f2da9c4910d01f358c6e3989c4d5a02683c7a5667f9727ff05831f7aa8ae66c8ff691c556f0884d49215 + languageName: node + linkType: hard + +"json-stringify-safe@npm:^5.0.1": + version: 5.0.1 + resolution: "json-stringify-safe@npm:5.0.1" + checksum: 48ec0adad5280b8a96bb93f4563aa1667fd7a36334f79149abd42446d0989f2ddc58274b479f4819f1f00617957e6344c886c55d05a4e15ebb4ab931e4a6a8ee + languageName: node + linkType: hard + +"json5@npm:^2.1.2": + version: 2.2.0 + resolution: "json5@npm:2.2.0" + dependencies: + minimist: ^1.2.5 + bin: + json5: lib/cli.js + checksum: e88fc5274bb58fc99547baa777886b069d2dd96d9cfc4490b305fd16d711dabd5979e35a4f90873cefbeb552e216b041a304fe56702bedba76e19bc7845f208d + languageName: node + linkType: hard + +"just-extend@npm:^4.0.2": + version: 4.2.1 + resolution: "just-extend@npm:4.2.1" + checksum: ff9fdede240fad313efeeeb68a660b942e5586d99c0058064c78884894a2690dc09bba44c994ad4e077e45d913fef01a9240c14a72c657b53687ac58de53b39c + languageName: node + linkType: hard + +"levn@npm:^0.4.1": + version: 0.4.1 + resolution: "levn@npm:0.4.1" + dependencies: + prelude-ls: ^1.2.1 + type-check: ~0.4.0 + checksum: 12c5021c859bd0f5248561bf139121f0358285ec545ebf48bb3d346820d5c61a4309535c7f387ed7d84361cf821e124ce346c6b7cef8ee09a67c1473b46d0fc4 + languageName: node + linkType: hard + +"locate-path@npm:^5.0.0": + version: 5.0.0 + resolution: "locate-path@npm:5.0.0" + dependencies: + p-locate: ^4.1.0 + checksum: 83e51725e67517287d73e1ded92b28602e3ae5580b301fe54bfb76c0c723e3f285b19252e375712316774cf52006cb236aed5704692c32db0d5d089b69696e30 + languageName: node + linkType: hard + +"locate-path@npm:^6.0.0": + version: 6.0.0 + resolution: "locate-path@npm:6.0.0" + dependencies: + p-locate: ^5.0.0 + checksum: 72eb661788a0368c099a184c59d2fee760b3831c9c1c33955e8a19ae4a21b4116e53fa736dc086cdeb9fce9f7cc508f2f92d2d3aae516f133e16a2bb59a39f5a + languageName: node + linkType: hard + +"lodash.flattendeep@npm:^4.4.0": + version: 4.4.0 + resolution: "lodash.flattendeep@npm:4.4.0" + checksum: 8521c919acac3d4bcf0aaf040c1ca9cb35d6c617e2d72e9b4d51c9a58b4366622cd6077441a18be626c3f7b28227502b3bf042903d447b056ee7e0b11d45c722 + languageName: node + linkType: hard + +"lodash.merge@npm:^4.6.2": + version: 4.6.2 + resolution: "lodash.merge@npm:4.6.2" + checksum: ad580b4bdbb7ca1f7abf7e1bce63a9a0b98e370cf40194b03380a46b4ed799c9573029599caebc1b14e3f24b111aef72b96674a56cfa105e0f5ac70546cdc005 + languageName: node + linkType: hard + +"lodash.set@npm:^4.3.2": + version: 4.3.2 + resolution: "lodash.set@npm:4.3.2" + checksum: a9122f49eef9f2d0fc9061a33d87f8e5b8c6b23d46e8b9e9ce1529d3588d79741bd1145a3abdfa3b13082703e65af27ff18d8a07bfc22b9be32f3fc36f763f70 + languageName: node + linkType: hard + +"lodash@npm:^4.17.15, lodash@npm:^4.17.21": + version: 4.17.21 + resolution: "lodash@npm:4.17.21" + checksum: eb835a2e51d381e561e508ce932ea50a8e5a68f4ebdd771ea240d3048244a8d13658acbd502cd4829768c56f2e16bdd4340b9ea141297d472517b83868e677f7 + languageName: node + linkType: hard + +"log-symbols@npm:4.1.0": + version: 4.1.0 + resolution: "log-symbols@npm:4.1.0" + dependencies: + chalk: ^4.1.0 + is-unicode-supported: ^0.1.0 + checksum: fce1497b3135a0198803f9f07464165e9eb83ed02ceb2273930a6f8a508951178d8cf4f0378e9d28300a2ed2bc49050995d2bd5f53ab716bb15ac84d58c6ef74 + languageName: node + linkType: hard + +"lolex@npm:^4.2.0": + version: 4.2.0 + resolution: "lolex@npm:4.2.0" + checksum: 0a83bfe1748fc745515dff9b3f722422918f5f6975104d7e576fc32c06b5398ee0c58525684068d4de49cdd49874e00b5e2b2d72ce8c5d829dab86c8c08ca31f + languageName: node + linkType: hard + +"lolex@npm:^5.0.1": + version: 5.1.2 + resolution: "lolex@npm:5.1.2" + dependencies: + "@sinonjs/commons": ^1.7.0 + checksum: 7eb468d4ef4746c024d23cb2b75f679f79449a9d5cbe11abadf2f3b147c1d7ffe28816438bedfb8a75c58357a625c2f9ba197b050c226d2b3f0c4a956cf556fb + languageName: node + linkType: hard + +"lru-cache@npm:^6.0.0": + version: 6.0.0 + resolution: "lru-cache@npm:6.0.0" + dependencies: + yallist: ^4.0.0 + checksum: f97f499f898f23e4585742138a22f22526254fdba6d75d41a1c2526b3b6cc5747ef59c5612ba7375f42aca4f8461950e925ba08c991ead0651b4918b7c978297 + languageName: node + linkType: hard + +"make-dir@npm:^3.0.0, make-dir@npm:^3.0.2": + version: 3.1.0 + resolution: "make-dir@npm:3.1.0" + dependencies: + semver: ^6.0.0 + checksum: 484200020ab5a1fdf12f393fe5f385fc8e4378824c940fba1729dcd198ae4ff24867bc7a5646331e50cead8abff5d9270c456314386e629acec6dff4b8016b78 + languageName: node + linkType: hard + +"make-error@npm:^1.1.1": + version: 1.3.6 + resolution: "make-error@npm:1.3.6" + checksum: b86e5e0e25f7f777b77fabd8e2cbf15737972869d852a22b7e73c17623928fccb826d8e46b9951501d3f20e51ad74ba8c59ed584f610526a48f8ccf88aaec402 + languageName: node + linkType: hard + +"make-fetch-happen@npm:^9.1.0": + version: 9.1.0 + resolution: "make-fetch-happen@npm:9.1.0" + dependencies: + agentkeepalive: ^4.1.3 + cacache: ^15.2.0 + http-cache-semantics: ^4.1.0 + http-proxy-agent: ^4.0.1 + https-proxy-agent: ^5.0.0 + is-lambda: ^1.0.1 + lru-cache: ^6.0.0 + minipass: ^3.1.3 + minipass-collect: ^1.0.2 + minipass-fetch: ^1.3.2 + minipass-flush: ^1.0.5 + minipass-pipeline: ^1.2.4 + negotiator: ^0.6.2 + promise-retry: ^2.0.1 + socks-proxy-agent: ^6.0.0 + ssri: ^8.0.0 + checksum: 0eb371c85fdd0b1584fcfdf3dc3c62395761b3c14658be02620c310305a9a7ecf1617a5e6fb30c1d081c5c8aaf177fa133ee225024313afabb7aa6a10f1e3d04 + languageName: node + linkType: hard + +"merge2@npm:^1.3.0, merge2@npm:^1.4.1": + version: 1.4.1 + resolution: "merge2@npm:1.4.1" + checksum: 7268db63ed5169466540b6fb947aec313200bcf6d40c5ab722c22e242f651994619bcd85601602972d3c85bd2cc45a358a4c61937e9f11a061919a1da569b0c2 + languageName: node + linkType: hard + +"micromatch@npm:^4.0.4": + version: 4.0.4 + resolution: "micromatch@npm:4.0.4" + dependencies: + braces: ^3.0.1 + picomatch: ^2.2.3 + checksum: ef3d1c88e79e0a68b0e94a03137676f3324ac18a908c245a9e5936f838079fcc108ac7170a5fadc265a9c2596963462e402841406bda1a4bb7b68805601d631c + languageName: node + linkType: hard + +"minimatch@npm:3.0.4": + version: 3.0.4 + resolution: "minimatch@npm:3.0.4" + dependencies: + brace-expansion: ^1.1.7 + checksum: 66ac295f8a7b59788000ea3749938b0970344c841750abd96694f80269b926ebcafad3deeb3f1da2522978b119e6ae3a5869b63b13a7859a456b3408bd18a078 + languageName: node + linkType: hard + +"minimatch@npm:^3.0.4": + version: 3.0.5 + resolution: "minimatch@npm:3.0.5" + dependencies: + brace-expansion: ^1.1.7 + checksum: a3b84b426eafca947741b864502cee02860c4e7b145de11ad98775cfcf3066fef422583bc0ffce0952ddf4750c1ccf4220b1556430d4ce10139f66247d87d69e + languageName: node + linkType: hard + +"minimist@npm:^1.2.5": + version: 1.2.5 + resolution: "minimist@npm:1.2.5" + checksum: 86706ce5b36c16bfc35c5fe3dbb01d5acdc9a22f2b6cc810b6680656a1d2c0e44a0159c9a3ba51fb072bb5c203e49e10b51dcd0eec39c481f4c42086719bae52 + languageName: node + linkType: hard + +"minipass-collect@npm:^1.0.2": + version: 1.0.2 + resolution: "minipass-collect@npm:1.0.2" + dependencies: + minipass: ^3.0.0 + checksum: 14df761028f3e47293aee72888f2657695ec66bd7d09cae7ad558da30415fdc4752bbfee66287dcc6fd5e6a2fa3466d6c484dc1cbd986525d9393b9523d97f10 + languageName: node + linkType: hard + +"minipass-fetch@npm:^1.3.2": + version: 1.4.1 + resolution: "minipass-fetch@npm:1.4.1" + dependencies: + encoding: ^0.1.12 + minipass: ^3.1.0 + minipass-sized: ^1.0.3 + minizlib: ^2.0.0 + dependenciesMeta: + encoding: + optional: true + checksum: ec93697bdb62129c4e6c0104138e681e30efef8c15d9429dd172f776f83898471bc76521b539ff913248cc2aa6d2b37b652c993504a51cc53282563640f29216 + languageName: node + linkType: hard + +"minipass-flush@npm:^1.0.5": + version: 1.0.5 + resolution: "minipass-flush@npm:1.0.5" + dependencies: + minipass: ^3.0.0 + checksum: 56269a0b22bad756a08a94b1ffc36b7c9c5de0735a4dd1ab2b06c066d795cfd1f0ac44a0fcae13eece5589b908ecddc867f04c745c7009be0b566421ea0944cf + languageName: node + linkType: hard + +"minipass-pipeline@npm:^1.2.2, minipass-pipeline@npm:^1.2.4": + version: 1.2.4 + resolution: "minipass-pipeline@npm:1.2.4" + dependencies: + minipass: ^3.0.0 + checksum: b14240dac0d29823c3d5911c286069e36d0b81173d7bdf07a7e4a91ecdef92cdff4baaf31ea3746f1c61e0957f652e641223970870e2353593f382112257971b + languageName: node + linkType: hard + +"minipass-sized@npm:^1.0.3": + version: 1.0.3 + resolution: "minipass-sized@npm:1.0.3" + dependencies: + minipass: ^3.0.0 + checksum: 79076749fcacf21b5d16dd596d32c3b6bf4d6e62abb43868fac21674078505c8b15eaca4e47ed844985a4514854f917d78f588fcd029693709417d8f98b2bd60 + languageName: node + linkType: hard + +"minipass@npm:^3.0.0, minipass@npm:^3.1.0, minipass@npm:^3.1.1, minipass@npm:^3.1.3": + version: 3.1.6 + resolution: "minipass@npm:3.1.6" + dependencies: + yallist: ^4.0.0 + checksum: 57a04041413a3531a65062452cb5175f93383ef245d6f4a2961d34386eb9aa8ac11ac7f16f791f5e8bbaf1dfb1ef01596870c88e8822215db57aa591a5bb0a77 + languageName: node + linkType: hard + +"minizlib@npm:^2.0.0, minizlib@npm:^2.1.1": + version: 2.1.2 + resolution: "minizlib@npm:2.1.2" + dependencies: + minipass: ^3.0.0 + yallist: ^4.0.0 + checksum: f1fdeac0b07cf8f30fcf12f4b586795b97be856edea22b5e9072707be51fc95d41487faec3f265b42973a304fe3a64acd91a44a3826a963e37b37bafde0212c3 + languageName: node + linkType: hard + +"mkdirp@npm:^1.0.3, mkdirp@npm:^1.0.4": + version: 1.0.4 + resolution: "mkdirp@npm:1.0.4" + bin: + mkdirp: bin/cmd.js + checksum: a96865108c6c3b1b8e1d5e9f11843de1e077e57737602de1b82030815f311be11f96f09cce59bd5b903d0b29834733e5313f9301e3ed6d6f6fba2eae0df4298f + languageName: node + linkType: hard + +"mocha@npm:^9.2.0": + version: 9.2.0 + resolution: "mocha@npm:9.2.0" + dependencies: + "@ungap/promise-all-settled": 1.1.2 + ansi-colors: 4.1.1 + browser-stdout: 1.3.1 + chokidar: 3.5.3 + debug: 4.3.3 + diff: 5.0.0 + escape-string-regexp: 4.0.0 + find-up: 5.0.0 + glob: 7.2.0 + growl: 1.10.5 + he: 1.2.0 + js-yaml: 4.1.0 + log-symbols: 4.1.0 + minimatch: 3.0.4 + ms: 2.1.3 + nanoid: 3.2.0 + serialize-javascript: 6.0.0 + strip-json-comments: 3.1.1 + supports-color: 8.1.1 + which: 2.0.2 + workerpool: 6.2.0 + yargs: 16.2.0 + yargs-parser: 20.2.4 + yargs-unparser: 2.0.0 + bin: + _mocha: bin/_mocha + mocha: bin/mocha + checksum: 49efc4724cf17087c7e107bc8f6890db24525e6dcc153b801da58de3c2a2f940e22f7600ef195b8ac62a0dfd7baee5cf289fc4641a6b1fdf8bc9c819efc1a8ba + languageName: node + linkType: hard + +"ms@npm:2.1.2": + version: 2.1.2 + resolution: "ms@npm:2.1.2" + checksum: 673cdb2c3133eb050c745908d8ce632ed2c02d85640e2edb3ace856a2266a813b30c613569bf3354fdf4ea7d1a1494add3bfa95e2713baa27d0c2c71fc44f58f + languageName: node + linkType: hard + +"ms@npm:2.1.3, ms@npm:^2.0.0": + version: 2.1.3 + resolution: "ms@npm:2.1.3" + checksum: aa92de608021b242401676e35cfa5aa42dd70cbdc082b916da7fb925c542173e36bce97ea3e804923fe92c0ad991434e4a38327e15a1b5b5f945d66df615ae6d + languageName: node + linkType: hard + +"nanoid@npm:3.2.0": + version: 3.2.0 + resolution: "nanoid@npm:3.2.0" + bin: + nanoid: bin/nanoid.cjs + checksum: 3d1d5a69fea84e538057cf64106e713931c4ef32af344068ecff153ff91252f39b0f2b472e09b0dfff43ac3cf520c92938d90e6455121fe93976e23660f4fccc + languageName: node + linkType: hard + +"natural-compare@npm:^1.4.0": + version: 1.4.0 + resolution: "natural-compare@npm:1.4.0" + checksum: 23ad088b08f898fc9b53011d7bb78ec48e79de7627e01ab5518e806033861bef68d5b0cd0e2205c2f36690ac9571ff6bcb05eb777ced2eeda8d4ac5b44592c3d + languageName: node + linkType: hard + +"negotiator@npm:^0.6.2": + version: 0.6.3 + resolution: "negotiator@npm:0.6.3" + checksum: b8ffeb1e262eff7968fc90a2b6767b04cfd9842582a9d0ece0af7049537266e7b2506dfb1d107a32f06dd849ab2aea834d5830f7f4d0e5cb7d36e1ae55d021d9 + languageName: node + linkType: hard + +"nise@npm:^1.5.2": + version: 1.5.3 + resolution: "nise@npm:1.5.3" + dependencies: + "@sinonjs/formatio": ^3.2.1 + "@sinonjs/text-encoding": ^0.7.1 + just-extend: ^4.0.2 + lolex: ^5.0.1 + path-to-regexp: ^1.7.0 + checksum: ec3af21345dcaf34650a6f5420a11e0fd21a836ac5960f5e8523c301ee98465abf88b958f7b3084ecc6e0a7133e5cf7963f4df176b90b423c4da4984f1ebd75e + languageName: node + linkType: hard + +"nock@npm:^13.0.11": + version: 13.2.4 + resolution: "nock@npm:13.2.4" + dependencies: + debug: ^4.1.0 + json-stringify-safe: ^5.0.1 + lodash.set: ^4.3.2 + propagate: ^2.0.0 + checksum: 2750a82ea22eebd8203eb1d7669ae09c3daae1fd573026372bad2515adad48d723a804f647bd45d7a499eb3a9a632560da406bde05bca9df762d3027db9099b5 + languageName: node + linkType: hard + +"node-gyp@npm:latest": + version: 8.4.1 + resolution: "node-gyp@npm:8.4.1" + dependencies: + env-paths: ^2.2.0 + glob: ^7.1.4 + graceful-fs: ^4.2.6 + make-fetch-happen: ^9.1.0 + nopt: ^5.0.0 + npmlog: ^6.0.0 + rimraf: ^3.0.2 + semver: ^7.3.5 + tar: ^6.1.2 + which: ^2.0.2 + bin: + node-gyp: bin/node-gyp.js + checksum: 341710b5da39d3660e6a886b37e210d33f8282047405c2e62c277bcc744c7552c5b8b972ebc3a7d5c2813794e60cc48c3ebd142c46d6e0321db4db6c92dd0355 + languageName: node + linkType: hard + +"node-preload@npm:^0.2.1": + version: 0.2.1 + resolution: "node-preload@npm:0.2.1" + dependencies: + process-on-spawn: ^1.0.0 + checksum: 4586f91ac7417b33accce0ac629fb60f642d0c8d212b3c536dc3dda37fe54f8a3b858273380e1036e41a65d85470332c358315d2288e6584260d620fb4b00fb3 + languageName: node + linkType: hard + +"node-releases@npm:^2.0.1": + version: 2.0.2 + resolution: "node-releases@npm:2.0.2" + checksum: da858bf86b4d512842379749f5a5e4196ddab05ba18ffcf29f05bf460beceaca927f070f4430bb5046efec18941ddbc85e4c5fdbb83afc28a38dd6069a2f255e + languageName: node + linkType: hard + +"nopt@npm:^5.0.0": + version: 5.0.0 + resolution: "nopt@npm:5.0.0" + dependencies: + abbrev: 1 + bin: + nopt: bin/nopt.js + checksum: d35fdec187269503843924e0114c0c6533fb54bbf1620d0f28b4b60ba01712d6687f62565c55cc20a504eff0fbe5c63e22340c3fad549ad40469ffb611b04f2f + languageName: node + linkType: hard + +"normalize-path@npm:^3.0.0, normalize-path@npm:~3.0.0": + version: 3.0.0 + resolution: "normalize-path@npm:3.0.0" + checksum: 88eeb4da891e10b1318c4b2476b6e2ecbeb5ff97d946815ffea7794c31a89017c70d7f34b3c2ebf23ef4e9fc9fb99f7dffe36da22011b5b5c6ffa34f4873ec20 + languageName: node + linkType: hard + +"npmlog@npm:^6.0.0": + version: 6.0.0 + resolution: "npmlog@npm:6.0.0" + dependencies: + are-we-there-yet: ^2.0.0 + console-control-strings: ^1.1.0 + gauge: ^4.0.0 + set-blocking: ^2.0.0 + checksum: 33d8a7fe3d63bf83b16655b6588ae7ba10b5f37b067a661e7cab6508660d7c3204ae716ee2c5ce4eb9626fd1489cf2fa7645d789bc3b704f8c3ccb04a532a50b + languageName: node + linkType: hard + +"nyc@npm:^15.1.0": + version: 15.1.0 + resolution: "nyc@npm:15.1.0" + dependencies: + "@istanbuljs/load-nyc-config": ^1.0.0 + "@istanbuljs/schema": ^0.1.2 + caching-transform: ^4.0.0 + convert-source-map: ^1.7.0 + decamelize: ^1.2.0 + find-cache-dir: ^3.2.0 + find-up: ^4.1.0 + foreground-child: ^2.0.0 + get-package-type: ^0.1.0 + glob: ^7.1.6 + istanbul-lib-coverage: ^3.0.0 + istanbul-lib-hook: ^3.0.0 + istanbul-lib-instrument: ^4.0.0 + istanbul-lib-processinfo: ^2.0.2 + istanbul-lib-report: ^3.0.0 + istanbul-lib-source-maps: ^4.0.0 + istanbul-reports: ^3.0.2 + make-dir: ^3.0.0 + node-preload: ^0.2.1 + p-map: ^3.0.0 + process-on-spawn: ^1.0.0 + resolve-from: ^5.0.0 + rimraf: ^3.0.0 + signal-exit: ^3.0.2 + spawn-wrap: ^2.0.0 + test-exclude: ^6.0.0 + yargs: ^15.0.2 + bin: + nyc: bin/nyc.js + checksum: 82a7031982df2fd6ab185c9f1b5d032b6221846268007b45b5773c6582e776ab33e96cd22b4231520345942fcef69b4339bd967675b8483f3fa255b56326faef + languageName: node + linkType: hard + +"once@npm:^1.3.0": + version: 1.4.0 + resolution: "once@npm:1.4.0" + dependencies: + wrappy: 1 + checksum: cd0a88501333edd640d95f0d2700fbde6bff20b3d4d9bdc521bdd31af0656b5706570d6c6afe532045a20bb8dc0849f8332d6f2a416e0ba6d3d3b98806c7db68 + languageName: node + linkType: hard + +"optionator@npm:^0.9.1": + version: 0.9.1 + resolution: "optionator@npm:0.9.1" + dependencies: + deep-is: ^0.1.3 + fast-levenshtein: ^2.0.6 + levn: ^0.4.1 + prelude-ls: ^1.2.1 + type-check: ^0.4.0 + word-wrap: ^1.2.3 + checksum: dbc6fa065604b24ea57d734261914e697bd73b69eff7f18e967e8912aa2a40a19a9f599a507fa805be6c13c24c4eae8c71306c239d517d42d4c041c942f508a0 + languageName: node + linkType: hard + +"p-limit@npm:^2.2.0": + version: 2.3.0 + resolution: "p-limit@npm:2.3.0" + dependencies: + p-try: ^2.0.0 + checksum: 84ff17f1a38126c3314e91ecfe56aecbf36430940e2873dadaa773ffe072dc23b7af8e46d4b6485d302a11673fe94c6b67ca2cfbb60c989848b02100d0594ac1 + languageName: node + linkType: hard + +"p-limit@npm:^3.0.2": + version: 3.1.0 + resolution: "p-limit@npm:3.1.0" + dependencies: + yocto-queue: ^0.1.0 + checksum: 7c3690c4dbf62ef625671e20b7bdf1cbc9534e83352a2780f165b0d3ceba21907e77ad63401708145ca4e25bfc51636588d89a8c0aeb715e6c37d1c066430360 + languageName: node + linkType: hard + +"p-locate@npm:^4.1.0": + version: 4.1.0 + resolution: "p-locate@npm:4.1.0" + dependencies: + p-limit: ^2.2.0 + checksum: 513bd14a455f5da4ebfcb819ef706c54adb09097703de6aeaa5d26fe5ea16df92b48d1ac45e01e3944ce1e6aa2a66f7f8894742b8c9d6e276e16cd2049a2b870 + languageName: node + linkType: hard + +"p-locate@npm:^5.0.0": + version: 5.0.0 + resolution: "p-locate@npm:5.0.0" + dependencies: + p-limit: ^3.0.2 + checksum: 1623088f36cf1cbca58e9b61c4e62bf0c60a07af5ae1ca99a720837356b5b6c5ba3eb1b2127e47a06865fee59dd0453cad7cc844cda9d5a62ac1a5a51b7c86d3 + languageName: node + linkType: hard + +"p-map@npm:^3.0.0": + version: 3.0.0 + resolution: "p-map@npm:3.0.0" + dependencies: + aggregate-error: ^3.0.0 + checksum: 49b0fcbc66b1ef9cd379de1b4da07fa7a9f84b41509ea3f461c31903623aaba8a529d22f835e0d77c7cb9fcc16e4fae71e308fd40179aea514ba68f27032b5d5 + languageName: node + linkType: hard + +"p-map@npm:^4.0.0": + version: 4.0.0 + resolution: "p-map@npm:4.0.0" + dependencies: + aggregate-error: ^3.0.0 + checksum: cb0ab21ec0f32ddffd31dfc250e3afa61e103ef43d957cc45497afe37513634589316de4eb88abdfd969fe6410c22c0b93ab24328833b8eb1ccc087fc0442a1c + languageName: node + linkType: hard + +"p-try@npm:^2.0.0": + version: 2.2.0 + resolution: "p-try@npm:2.2.0" + checksum: f8a8e9a7693659383f06aec604ad5ead237c7a261c18048a6e1b5b85a5f8a067e469aa24f5bc009b991ea3b058a87f5065ef4176793a200d4917349881216cae + languageName: node + linkType: hard + +"package-hash@npm:^4.0.0": + version: 4.0.0 + resolution: "package-hash@npm:4.0.0" + dependencies: + graceful-fs: ^4.1.15 + hasha: ^5.0.0 + lodash.flattendeep: ^4.4.0 + release-zalgo: ^1.0.0 + checksum: 32c49e3a0e1c4a33b086a04cdd6d6e570aee019cb8402ec16476d9b3564a40e38f91ce1a1f9bc88b08f8ef2917a11e0b786c08140373bdf609ea90749031e6fc + languageName: node + linkType: hard + +"parent-module@npm:^1.0.0": + version: 1.0.1 + resolution: "parent-module@npm:1.0.1" + dependencies: + callsites: ^3.0.0 + checksum: 6ba8b255145cae9470cf5551eb74be2d22281587af787a2626683a6c20fbb464978784661478dd2a3f1dad74d1e802d403e1b03c1a31fab310259eec8ac560ff + languageName: node + linkType: hard + +"path-exists@npm:^4.0.0": + version: 4.0.0 + resolution: "path-exists@npm:4.0.0" + checksum: 505807199dfb7c50737b057dd8d351b82c033029ab94cb10a657609e00c1bc53b951cfdbccab8de04c5584d5eff31128ce6afd3db79281874a5ef2adbba55ed1 + languageName: node + linkType: hard + +"path-is-absolute@npm:^1.0.0": + version: 1.0.1 + resolution: "path-is-absolute@npm:1.0.1" + checksum: 060840f92cf8effa293bcc1bea81281bd7d363731d214cbe5c227df207c34cd727430f70c6037b5159c8a870b9157cba65e775446b0ab06fd5ecc7e54615a3b8 + languageName: node + linkType: hard + +"path-key@npm:^3.1.0": + version: 3.1.1 + resolution: "path-key@npm:3.1.1" + checksum: 55cd7a9dd4b343412a8386a743f9c746ef196e57c823d90ca3ab917f90ab9f13dd0ded27252ba49dbdfcab2b091d998bc446f6220cd3cea65db407502a740020 + languageName: node + linkType: hard + +"path-to-regexp@npm:^1.7.0": + version: 1.8.0 + resolution: "path-to-regexp@npm:1.8.0" + dependencies: + isarray: 0.0.1 + checksum: 709f6f083c0552514ef4780cb2e7e4cf49b0cc89a97439f2b7cc69a608982b7690fb5d1720a7473a59806508fc2dae0be751ba49f495ecf89fd8fbc62abccbcd + languageName: node + linkType: hard + +"path-type@npm:^4.0.0": + version: 4.0.0 + resolution: "path-type@npm:4.0.0" + checksum: 5b1e2daa247062061325b8fdbfd1fb56dde0a448fb1455453276ea18c60685bdad23a445dc148cf87bc216be1573357509b7d4060494a6fd768c7efad833ee45 + languageName: node + linkType: hard + +"picocolors@npm:^1.0.0": + version: 1.0.0 + resolution: "picocolors@npm:1.0.0" + checksum: a2e8092dd86c8396bdba9f2b5481032848525b3dc295ce9b57896f931e63fc16f79805144321f72976383fc249584672a75cc18d6777c6b757603f372f745981 + languageName: node + linkType: hard + +"picomatch@npm:^2.0.4, picomatch@npm:^2.2.1, picomatch@npm:^2.2.3": + version: 2.3.1 + resolution: "picomatch@npm:2.3.1" + checksum: 050c865ce81119c4822c45d3c84f1ced46f93a0126febae20737bd05ca20589c564d6e9226977df859ed5e03dc73f02584a2b0faad36e896936238238b0446cf + languageName: node + linkType: hard + +"pkg-dir@npm:^4.1.0": + version: 4.2.0 + resolution: "pkg-dir@npm:4.2.0" + dependencies: + find-up: ^4.0.0 + checksum: 9863e3f35132bf99ae1636d31ff1e1e3501251d480336edb1c211133c8d58906bed80f154a1d723652df1fda91e01c7442c2eeaf9dc83157c7ae89087e43c8d6 + languageName: node + linkType: hard + +"prelude-ls@npm:^1.2.1": + version: 1.2.1 + resolution: "prelude-ls@npm:1.2.1" + checksum: cd192ec0d0a8e4c6da3bb80e4f62afe336df3f76271ac6deb0e6a36187133b6073a19e9727a1ff108cd8b9982e4768850d413baa71214dd80c7979617dca827a + languageName: node + linkType: hard + +"prettier@npm:^2.5.1": + version: 2.5.1 + resolution: "prettier@npm:2.5.1" + bin: + prettier: bin-prettier.js + checksum: 21b9408476ea1c544b0e45d51ceb94a84789ff92095abb710942d780c862d0daebdb29972d47f6b4d0f7ebbfb0ffbf56cc2cfa3e3e9d1cca54864af185b15b66 + languageName: node + linkType: hard + +"process-on-spawn@npm:^1.0.0": + version: 1.0.0 + resolution: "process-on-spawn@npm:1.0.0" + dependencies: + fromentries: ^1.2.0 + checksum: 597769e3db6a8e2cb1cd64a952bbc150220588debac31c7cf1a9f620ce981e25583d8d70848d8a14953577608512984a8808c3be77e09af8ebdcdc14ec23a295 + languageName: node + linkType: hard + +"promise-inflight@npm:^1.0.1": + version: 1.0.1 + resolution: "promise-inflight@npm:1.0.1" + checksum: 22749483091d2c594261517f4f80e05226d4d5ecc1fc917e1886929da56e22b5718b7f2a75f3807e7a7d471bc3be2907fe92e6e8f373ddf5c64bae35b5af3981 + languageName: node + linkType: hard + +"promise-retry@npm:^2.0.1": + version: 2.0.1 + resolution: "promise-retry@npm:2.0.1" + dependencies: + err-code: ^2.0.2 + retry: ^0.12.0 + checksum: f96a3f6d90b92b568a26f71e966cbbc0f63ab85ea6ff6c81284dc869b41510e6cdef99b6b65f9030f0db422bf7c96652a3fff9f2e8fb4a0f069d8f4430359429 + languageName: node + linkType: hard + +"propagate@npm:^2.0.0": + version: 2.0.1 + resolution: "propagate@npm:2.0.1" + checksum: c4febaee2be0979e82fb6b3727878fd122a98d64a7fa3c9d09b0576751b88514a9e9275b1b92e76b364d488f508e223bd7e1dcdc616be4cdda876072fbc2a96c + languageName: node + linkType: hard + +"punycode@npm:^2.1.0": + version: 2.1.1 + resolution: "punycode@npm:2.1.1" + checksum: 823bf443c6dd14f669984dea25757b37993f67e8d94698996064035edd43bed8a5a17a9f12e439c2b35df1078c6bec05a6c86e336209eb1061e8025c481168e8 + languageName: node + linkType: hard + +"queue-microtask@npm:^1.2.2": + version: 1.2.3 + resolution: "queue-microtask@npm:1.2.3" + checksum: b676f8c040cdc5b12723ad2f91414d267605b26419d5c821ff03befa817ddd10e238d22b25d604920340fd73efd8ba795465a0377c4adf45a4a41e4234e42dc4 + languageName: node + linkType: hard + +"randombytes@npm:^2.1.0": + version: 2.1.0 + resolution: "randombytes@npm:2.1.0" + dependencies: + safe-buffer: ^5.1.0 + checksum: d779499376bd4cbb435ef3ab9a957006c8682f343f14089ed5f27764e4645114196e75b7f6abf1cbd84fd247c0cb0651698444df8c9bf30e62120fbbc52269d6 + languageName: node + linkType: hard + +"readable-stream@npm:^3.6.0": + version: 3.6.0 + resolution: "readable-stream@npm:3.6.0" + dependencies: + inherits: ^2.0.3 + string_decoder: ^1.1.1 + util-deprecate: ^1.0.1 + checksum: d4ea81502d3799439bb955a3a5d1d808592cf3133350ed352aeaa499647858b27b1c4013984900238b0873ec8d0d8defce72469fb7a83e61d53f5ad61cb80dc8 + languageName: node + linkType: hard + +"readdirp@npm:~3.6.0": + version: 3.6.0 + resolution: "readdirp@npm:3.6.0" + dependencies: + picomatch: ^2.2.1 + checksum: 1ced032e6e45670b6d7352d71d21ce7edf7b9b928494dcaba6f11fba63180d9da6cd7061ebc34175ffda6ff529f481818c962952004d273178acd70f7059b320 + languageName: node + linkType: hard + +"regexpp@npm:^3.2.0": + version: 3.2.0 + resolution: "regexpp@npm:3.2.0" + checksum: a78dc5c7158ad9ddcfe01aa9144f46e192ddbfa7b263895a70a5c6c73edd9ce85faf7c0430e59ac38839e1734e275b9c3de5c57ee3ab6edc0e0b1bdebefccef8 + languageName: node + linkType: hard + +"release-zalgo@npm:^1.0.0": + version: 1.0.0 + resolution: "release-zalgo@npm:1.0.0" + dependencies: + es6-error: ^4.0.1 + checksum: b59849dc310f6c426f34e308c48ba83df3d034ddef75189951723bb2aac99d29d15f5e127edad951c4095fc9025aa582053907154d68fe0c5380cd6a75365e53 + languageName: node + linkType: hard + +"require-directory@npm:^2.1.1": + version: 2.1.1 + resolution: "require-directory@npm:2.1.1" + checksum: fb47e70bf0001fdeabdc0429d431863e9475e7e43ea5f94ad86503d918423c1543361cc5166d713eaa7029dd7a3d34775af04764bebff99ef413111a5af18c80 + languageName: node + linkType: hard + +"require-main-filename@npm:^2.0.0": + version: 2.0.0 + resolution: "require-main-filename@npm:2.0.0" + checksum: e9e294695fea08b076457e9ddff854e81bffbe248ed34c1eec348b7abbd22a0d02e8d75506559e2265e96978f3c4720bd77a6dad84755de8162b357eb6c778c7 + languageName: node + linkType: hard + +"resolve-from@npm:^4.0.0": + version: 4.0.0 + resolution: "resolve-from@npm:4.0.0" + checksum: f4ba0b8494846a5066328ad33ef8ac173801a51739eb4d63408c847da9a2e1c1de1e6cbbf72699211f3d13f8fc1325648b169bd15eb7da35688e30a5fb0e4a7f + languageName: node + linkType: hard + +"resolve-from@npm:^5.0.0": + version: 5.0.0 + resolution: "resolve-from@npm:5.0.0" + checksum: 4ceeb9113e1b1372d0cd969f3468fa042daa1dd9527b1b6bb88acb6ab55d8b9cd65dbf18819f9f9ddf0db804990901dcdaade80a215e7b2c23daae38e64f5bdf + languageName: node + linkType: hard + +"retry@npm:^0.12.0": + version: 0.12.0 + resolution: "retry@npm:0.12.0" + checksum: 623bd7d2e5119467ba66202d733ec3c2e2e26568074923bc0585b6b99db14f357e79bdedb63cab56cec47491c4a0da7e6021a7465ca6dc4f481d3898fdd3158c + languageName: node + linkType: hard + +"reusify@npm:^1.0.4": + version: 1.0.4 + resolution: "reusify@npm:1.0.4" + checksum: c3076ebcc22a6bc252cb0b9c77561795256c22b757f40c0d8110b1300723f15ec0fc8685e8d4ea6d7666f36c79ccc793b1939c748bf36f18f542744a4e379fcc + languageName: node + linkType: hard + +"rimraf@npm:^3.0.0, rimraf@npm:^3.0.2": + version: 3.0.2 + resolution: "rimraf@npm:3.0.2" + dependencies: + glob: ^7.1.3 + bin: + rimraf: bin.js + checksum: 87f4164e396f0171b0a3386cc1877a817f572148ee13a7e113b238e48e8a9f2f31d009a92ec38a591ff1567d9662c6b67fd8818a2dbbaed74bc26a87a2a4a9a0 + languageName: node + linkType: hard + +"run-parallel@npm:^1.1.9": + version: 1.2.0 + resolution: "run-parallel@npm:1.2.0" + dependencies: + queue-microtask: ^1.2.2 + checksum: cb4f97ad25a75ebc11a8ef4e33bb962f8af8516bb2001082ceabd8902e15b98f4b84b4f8a9b222e5d57fc3bd1379c483886ed4619367a7680dad65316993021d + languageName: node + linkType: hard + +"safe-buffer@npm:^5.1.0, safe-buffer@npm:~5.2.0": + version: 5.2.1 + resolution: "safe-buffer@npm:5.2.1" + checksum: b99c4b41fdd67a6aaf280fcd05e9ffb0813654894223afb78a31f14a19ad220bba8aba1cb14eddce1fcfb037155fe6de4e861784eb434f7d11ed58d1e70dd491 + languageName: node + linkType: hard + +"safe-buffer@npm:~5.1.1": + version: 5.1.2 + resolution: "safe-buffer@npm:5.1.2" + checksum: f2f1f7943ca44a594893a852894055cf619c1fbcb611237fc39e461ae751187e7baf4dc391a72125e0ac4fb2d8c5c0b3c71529622e6a58f46b960211e704903c + languageName: node + linkType: hard + +"safer-buffer@npm:>= 2.1.2 < 3.0.0": + version: 2.1.2 + resolution: "safer-buffer@npm:2.1.2" + checksum: cab8f25ae6f1434abee8d80023d7e72b598cf1327164ddab31003c51215526801e40b66c5e65d658a0af1e9d6478cadcb4c745f4bd6751f97d8644786c0978b0 + languageName: node + linkType: hard + +"semver@npm:^6.0.0, semver@npm:^6.3.0": + version: 6.3.0 + resolution: "semver@npm:6.3.0" + bin: + semver: ./bin/semver.js + checksum: 1b26ecf6db9e8292dd90df4e781d91875c0dcc1b1909e70f5d12959a23c7eebb8f01ea581c00783bbee72ceeaad9505797c381756326073850dc36ed284b21b9 + languageName: node + linkType: hard + +"semver@npm:^7.3.5": + version: 7.3.5 + resolution: "semver@npm:7.3.5" + dependencies: + lru-cache: ^6.0.0 + bin: + semver: bin/semver.js + checksum: 5eafe6102bea2a7439897c1856362e31cc348ccf96efd455c8b5bc2c61e6f7e7b8250dc26b8828c1d76a56f818a7ee907a36ae9fb37a599d3d24609207001d60 + languageName: node + linkType: hard + +"serialize-javascript@npm:6.0.0": + version: 6.0.0 + resolution: "serialize-javascript@npm:6.0.0" + dependencies: + randombytes: ^2.1.0 + checksum: 56f90b562a1bdc92e55afb3e657c6397c01a902c588c0fe3d4c490efdcc97dcd2a3074ba12df9e94630f33a5ce5b76a74784a7041294628a6f4306e0ec84bf93 + languageName: node + linkType: hard + +"set-blocking@npm:^2.0.0": + version: 2.0.0 + resolution: "set-blocking@npm:2.0.0" + checksum: 6e65a05f7cf7ebdf8b7c75b101e18c0b7e3dff4940d480efed8aad3a36a4005140b660fa1d804cb8bce911cac290441dc728084a30504d3516ac2ff7ad607b02 + languageName: node + linkType: hard + +"shebang-command@npm:^2.0.0": + version: 2.0.0 + resolution: "shebang-command@npm:2.0.0" + dependencies: + shebang-regex: ^3.0.0 + checksum: 6b52fe87271c12968f6a054e60f6bde5f0f3d2db483a1e5c3e12d657c488a15474121a1d55cd958f6df026a54374ec38a4a963988c213b7570e1d51575cea7fa + languageName: node + linkType: hard + +"shebang-regex@npm:^3.0.0": + version: 3.0.0 + resolution: "shebang-regex@npm:3.0.0" + checksum: 1a2bcae50de99034fcd92ad4212d8e01eedf52c7ec7830eedcf886622804fe36884278f2be8be0ea5fde3fd1c23911643a4e0f726c8685b61871c8908af01222 + languageName: node + linkType: hard + +"signal-exit@npm:^3.0.0, signal-exit@npm:^3.0.2": + version: 3.0.7 + resolution: "signal-exit@npm:3.0.7" + checksum: a2f098f247adc367dffc27845853e9959b9e88b01cb301658cfe4194352d8d2bb32e18467c786a7fe15f1d44b233ea35633d076d5e737870b7139949d1ab6318 + languageName: node + linkType: hard + +"sinon@npm:^7.3.2": + version: 7.5.0 + resolution: "sinon@npm:7.5.0" + dependencies: + "@sinonjs/commons": ^1.4.0 + "@sinonjs/formatio": ^3.2.1 + "@sinonjs/samsam": ^3.3.3 + diff: ^3.5.0 + lolex: ^4.2.0 + nise: ^1.5.2 + supports-color: ^5.5.0 + checksum: e8cf6b3dd16e9c1ed1a2b9560c396a2d6205a4f32293b1762cb6ebb8f88cfa47db6aba45b0c1709ec396efb41d171d88c9b1ab8f32f35512eb9e5d0d0d15d307 + languageName: node + linkType: hard + +"slash@npm:^3.0.0": + version: 3.0.0 + resolution: "slash@npm:3.0.0" + checksum: 94a93fff615f25a999ad4b83c9d5e257a7280c90a32a7cb8b4a87996e4babf322e469c42b7f649fd5796edd8687652f3fb452a86dc97a816f01113183393f11c + languageName: node + linkType: hard + +"smart-buffer@npm:^4.2.0": + version: 4.2.0 + resolution: "smart-buffer@npm:4.2.0" + checksum: b5167a7142c1da704c0e3af85c402002b597081dd9575031a90b4f229ca5678e9a36e8a374f1814c8156a725d17008ae3bde63b92f9cfd132526379e580bec8b + languageName: node + linkType: hard + +"socks-proxy-agent@npm:^6.0.0": + version: 6.1.1 + resolution: "socks-proxy-agent@npm:6.1.1" + dependencies: + agent-base: ^6.0.2 + debug: ^4.3.1 + socks: ^2.6.1 + checksum: 9a8a4f791bba0060315cf7291ca6f9db37d6fc280fd0860d73d8887d3efe4c22e823aa25a8d5375f6079279f8dc91b50c075345179bf832bfe3c7c26d3582e3c + languageName: node + linkType: hard + +"socks@npm:^2.6.1": + version: 2.6.2 + resolution: "socks@npm:2.6.2" + dependencies: + ip: ^1.1.5 + smart-buffer: ^4.2.0 + checksum: dd9194293059d737759d5c69273850ad4149f448426249325c4bea0e340d1cf3d266c3b022694b0dcf5d31f759de23657244c481fc1e8322add80b7985c36b5e + languageName: node + linkType: hard + +"source-map@npm:^0.5.0": + version: 0.5.7 + resolution: "source-map@npm:0.5.7" + checksum: 5dc2043b93d2f194142c7f38f74a24670cd7a0063acdaf4bf01d2964b402257ae843c2a8fa822ad5b71013b5fcafa55af7421383da919752f22ff488bc553f4d + languageName: node + linkType: hard + +"source-map@npm:^0.6.1": + version: 0.6.1 + resolution: "source-map@npm:0.6.1" + checksum: 59ce8640cf3f3124f64ac289012c2b8bd377c238e316fb323ea22fbfe83da07d81e000071d7242cad7a23cd91c7de98e4df8830ec3f133cb6133a5f6e9f67bc2 + languageName: node + linkType: hard + +"spawn-wrap@npm:^2.0.0": + version: 2.0.0 + resolution: "spawn-wrap@npm:2.0.0" + dependencies: + foreground-child: ^2.0.0 + is-windows: ^1.0.2 + make-dir: ^3.0.0 + rimraf: ^3.0.0 + signal-exit: ^3.0.2 + which: ^2.0.1 + checksum: 5a518e37620def6d516b86207482a4f76bcf3c37c57d8d886d9fa399b04e5668d11fd12817b178029b02002a5ebbd09010374307effa821ba39594042f0a2d96 + languageName: node + linkType: hard + +"sprintf-js@npm:~1.0.2": + version: 1.0.3 + resolution: "sprintf-js@npm:1.0.3" + checksum: 19d79aec211f09b99ec3099b5b2ae2f6e9cdefe50bc91ac4c69144b6d3928a640bb6ae5b3def70c2e85a2c3d9f5ec2719921e3a59d3ca3ef4b2fd1a4656a0df3 + languageName: node + linkType: hard + +"ssri@npm:^8.0.0, ssri@npm:^8.0.1": + version: 8.0.1 + resolution: "ssri@npm:8.0.1" + dependencies: + minipass: ^3.1.1 + checksum: bc447f5af814fa9713aa201ec2522208ae0f4d8f3bda7a1f445a797c7b929a02720436ff7c478fb5edc4045adb02b1b88d2341b436a80798734e2494f1067b36 + languageName: node + linkType: hard + +"string-width@npm:^1.0.2 || 2 || 3 || 4, string-width@npm:^4.1.0, string-width@npm:^4.2.0, string-width@npm:^4.2.3": + version: 4.2.3 + resolution: "string-width@npm:4.2.3" + dependencies: + emoji-regex: ^8.0.0 + is-fullwidth-code-point: ^3.0.0 + strip-ansi: ^6.0.1 + checksum: e52c10dc3fbfcd6c3a15f159f54a90024241d0f149cf8aed2982a2d801d2e64df0bf1dc351cf8e95c3319323f9f220c16e740b06faecd53e2462df1d2b5443fb + languageName: node + linkType: hard + +"string_decoder@npm:^1.1.1": + version: 1.3.0 + resolution: "string_decoder@npm:1.3.0" + dependencies: + safe-buffer: ~5.2.0 + checksum: 8417646695a66e73aefc4420eb3b84cc9ffd89572861fe004e6aeb13c7bc00e2f616247505d2dbbef24247c372f70268f594af7126f43548565c68c117bdeb56 + languageName: node + linkType: hard + +"strip-ansi@npm:^6.0.0, strip-ansi@npm:^6.0.1": + version: 6.0.1 + resolution: "strip-ansi@npm:6.0.1" + dependencies: + ansi-regex: ^5.0.1 + checksum: f3cd25890aef3ba6e1a74e20896c21a46f482e93df4a06567cebf2b57edabb15133f1f94e57434e0a958d61186087b1008e89c94875d019910a213181a14fc8c + languageName: node + linkType: hard + +"strip-bom@npm:^4.0.0": + version: 4.0.0 + resolution: "strip-bom@npm:4.0.0" + checksum: 9dbcfbaf503c57c06af15fe2c8176fb1bf3af5ff65003851a102749f875a6dbe0ab3b30115eccf6e805e9d756830d3e40ec508b62b3f1ddf3761a20ebe29d3f3 + languageName: node + linkType: hard + +"strip-json-comments@npm:3.1.1, strip-json-comments@npm:^3.1.0, strip-json-comments@npm:^3.1.1": + version: 3.1.1 + resolution: "strip-json-comments@npm:3.1.1" + checksum: 492f73e27268f9b1c122733f28ecb0e7e8d8a531a6662efbd08e22cccb3f9475e90a1b82cab06a392f6afae6d2de636f977e231296400d0ec5304ba70f166443 + languageName: node + linkType: hard + +"supports-color@npm:8.1.1": + version: 8.1.1 + resolution: "supports-color@npm:8.1.1" + dependencies: + has-flag: ^4.0.0 + checksum: c052193a7e43c6cdc741eb7f378df605636e01ad434badf7324f17fb60c69a880d8d8fcdcb562cf94c2350e57b937d7425ab5b8326c67c2adc48f7c87c1db406 + languageName: node + linkType: hard + +"supports-color@npm:^5.3.0, supports-color@npm:^5.5.0": + version: 5.5.0 + resolution: "supports-color@npm:5.5.0" + dependencies: + has-flag: ^3.0.0 + checksum: 95f6f4ba5afdf92f495b5a912d4abee8dcba766ae719b975c56c084f5004845f6f5a5f7769f52d53f40e21952a6d87411bafe34af4a01e65f9926002e38e1dac + languageName: node + linkType: hard + +"supports-color@npm:^7.1.0": + version: 7.2.0 + resolution: "supports-color@npm:7.2.0" + dependencies: + has-flag: ^4.0.0 + checksum: 3dda818de06ebbe5b9653e07842d9479f3555ebc77e9a0280caf5a14fb877ffee9ed57007c3b78f5a6324b8dbeec648d9e97a24e2ed9fdb81ddc69ea07100f4a + languageName: node + linkType: hard + +"tar@npm:^6.0.2, tar@npm:^6.1.2": + version: 6.1.11 + resolution: "tar@npm:6.1.11" + dependencies: + chownr: ^2.0.0 + fs-minipass: ^2.0.0 + minipass: ^3.0.0 + minizlib: ^2.1.1 + mkdirp: ^1.0.3 + yallist: ^4.0.0 + checksum: a04c07bb9e2d8f46776517d4618f2406fb977a74d914ad98b264fc3db0fe8224da5bec11e5f8902c5b9bcb8ace22d95fbe3c7b36b8593b7dfc8391a25898f32f + languageName: node + linkType: hard + +"test-exclude@npm:^6.0.0": + version: 6.0.0 + resolution: "test-exclude@npm:6.0.0" + dependencies: + "@istanbuljs/schema": ^0.1.2 + glob: ^7.1.4 + minimatch: ^3.0.4 + checksum: 3b34a3d77165a2cb82b34014b3aba93b1c4637a5011807557dc2f3da826c59975a5ccad765721c4648b39817e3472789f9b0fa98fc854c5c1c7a1e632aacdc28 + languageName: node + linkType: hard + +"text-table@npm:^0.2.0": + version: 0.2.0 + resolution: "text-table@npm:0.2.0" + checksum: b6937a38c80c7f84d9c11dd75e49d5c44f71d95e810a3250bd1f1797fc7117c57698204adf676b71497acc205d769d65c16ae8fa10afad832ae1322630aef10a + languageName: node + linkType: hard + +"to-fast-properties@npm:^2.0.0": + version: 2.0.0 + resolution: "to-fast-properties@npm:2.0.0" + checksum: be2de62fe58ead94e3e592680052683b1ec986c72d589e7b21e5697f8744cdbf48c266fa72f6c15932894c10187b5f54573a3bcf7da0bfd964d5caf23d436168 + languageName: node + linkType: hard + +"to-regex-range@npm:^5.0.1": + version: 5.0.1 + resolution: "to-regex-range@npm:5.0.1" + dependencies: + is-number: ^7.0.0 + checksum: f76fa01b3d5be85db6a2a143e24df9f60dd047d151062d0ba3df62953f2f697b16fe5dad9b0ac6191c7efc7b1d9dcaa4b768174b7b29da89d4428e64bc0a20ed + languageName: node + linkType: hard + +"ts-node@npm:^10.4.0": + version: 10.5.0 + resolution: "ts-node@npm:10.5.0" + dependencies: + "@cspotcode/source-map-support": 0.7.0 + "@tsconfig/node10": ^1.0.7 + "@tsconfig/node12": ^1.0.7 + "@tsconfig/node14": ^1.0.0 + "@tsconfig/node16": ^1.0.2 + acorn: ^8.4.1 + acorn-walk: ^8.1.1 + arg: ^4.1.0 + create-require: ^1.1.0 + diff: ^4.0.1 + make-error: ^1.1.1 + v8-compile-cache-lib: ^3.0.0 + yn: 3.1.1 + peerDependencies: + "@swc/core": ">=1.2.50" + "@swc/wasm": ">=1.2.50" + "@types/node": "*" + typescript: ">=2.7" + peerDependenciesMeta: + "@swc/core": + optional: true + "@swc/wasm": + optional: true + bin: + ts-node: dist/bin.js + ts-node-cwd: dist/bin-cwd.js + ts-node-script: dist/bin-script.js + ts-node-transpile-only: dist/bin-transpile.js + ts-script: dist/bin-script-deprecated.js + checksum: d51ac8a9b3582ce3705cef8d35f3372e40caa277dbd7c7baeb651961538f13d2f11f22402614348f78d9b10501bd1cb5f05ec4f2ec9a74bd0e288de769c32335 + languageName: node + linkType: hard + +"tslib@npm:^1.8.1": + version: 1.14.1 + resolution: "tslib@npm:1.14.1" + checksum: dbe628ef87f66691d5d2959b3e41b9ca0045c3ee3c7c7b906cc1e328b39f199bb1ad9e671c39025bd56122ac57dfbf7385a94843b1cc07c60a4db74795829acd + languageName: node + linkType: hard + +"tslib@npm:^2.3.1": + version: 2.3.1 + resolution: "tslib@npm:2.3.1" + checksum: de17a98d4614481f7fcb5cd53ffc1aaf8654313be0291e1bfaee4b4bb31a20494b7d218ff2e15017883e8ea9626599b3b0e0229c18383ba9dce89da2adf15cb9 + languageName: node + linkType: hard + +"tsutils@npm:^3.21.0": + version: 3.21.0 + resolution: "tsutils@npm:3.21.0" + dependencies: + tslib: ^1.8.1 + peerDependencies: + typescript: ">=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta" + checksum: 1843f4c1b2e0f975e08c4c21caa4af4f7f65a12ac1b81b3b8489366826259323feb3fc7a243123453d2d1a02314205a7634e048d4a8009921da19f99755cdc48 + languageName: node + linkType: hard + +"type-check@npm:^0.4.0, type-check@npm:~0.4.0": + version: 0.4.0 + resolution: "type-check@npm:0.4.0" + dependencies: + prelude-ls: ^1.2.1 + checksum: ec688ebfc9c45d0c30412e41ca9c0cdbd704580eb3a9ccf07b9b576094d7b86a012baebc95681999dd38f4f444afd28504cb3a89f2ef16b31d4ab61a0739025a + languageName: node + linkType: hard + +"type-detect@npm:4.0.8": + version: 4.0.8 + resolution: "type-detect@npm:4.0.8" + checksum: 62b5628bff67c0eb0b66afa371bd73e230399a8d2ad30d852716efcc4656a7516904570cd8631a49a3ce57c10225adf5d0cbdcb47f6b0255fe6557c453925a15 + languageName: node + linkType: hard + +"type-fest@npm:^0.20.2": + version: 0.20.2 + resolution: "type-fest@npm:0.20.2" + checksum: 4fb3272df21ad1c552486f8a2f8e115c09a521ad7a8db3d56d53718d0c907b62c6e9141ba5f584af3f6830d0872c521357e512381f24f7c44acae583ad517d73 + languageName: node + linkType: hard + +"type-fest@npm:^0.8.0": + version: 0.8.1 + resolution: "type-fest@npm:0.8.1" + checksum: d61c4b2eba24009033ae4500d7d818a94fd6d1b481a8111612ee141400d5f1db46f199c014766b9fa9b31a6a7374d96fc748c6d688a78a3ce5a33123839becb7 + languageName: node + linkType: hard + +"typedarray-to-buffer@npm:^3.1.5": + version: 3.1.5 + resolution: "typedarray-to-buffer@npm:3.1.5" + dependencies: + is-typedarray: ^1.0.0 + checksum: 99c11aaa8f45189fcfba6b8a4825fd684a321caa9bd7a76a27cf0c7732c174d198b99f449c52c3818107430b5f41c0ccbbfb75cb2ee3ca4a9451710986d61a60 + languageName: node + linkType: hard + +"typescript@npm:^4.5.3": + version: 4.5.5 + resolution: "typescript@npm:4.5.5" + bin: + tsc: bin/tsc + tsserver: bin/tsserver + checksum: 506f4c919dc8aeaafa92068c997f1d213b9df4d9756d0fae1a1e7ab66b585ab3498050e236113a1c9e57ee08c21ec6814ca7a7f61378c058d79af50a4b1f5a5e + languageName: node + linkType: hard + +"typescript@patch:typescript@^4.5.3#~builtin": + version: 4.5.5 + resolution: "typescript@patch:typescript@npm%3A4.5.5#~builtin::version=4.5.5&hash=493e53" + bin: + tsc: bin/tsc + tsserver: bin/tsserver + checksum: c05c318d79c690f101d7ffb34cd6c7d6bbd884d3af9cefe7749ad0cd6be43c7082f098280982ca945dcba23fde34a08fed9602bb26540936baf8c0520727d3ba + languageName: node + linkType: hard + +"unique-filename@npm:^1.1.1": + version: 1.1.1 + resolution: "unique-filename@npm:1.1.1" + dependencies: + unique-slug: ^2.0.0 + checksum: cf4998c9228cc7647ba7814e255dec51be43673903897b1786eff2ac2d670f54d4d733357eb08dea969aa5e6875d0e1bd391d668fbdb5a179744e7c7551a6f80 + languageName: node + linkType: hard + +"unique-slug@npm:^2.0.0": + version: 2.0.2 + resolution: "unique-slug@npm:2.0.2" + dependencies: + imurmurhash: ^0.1.4 + checksum: 5b6876a645da08d505dedb970d1571f6cebdf87044cb6b740c8dbb24f0d6e1dc8bdbf46825fd09f994d7cf50760e6f6e063cfa197d51c5902c00a861702eb75a + languageName: node + linkType: hard + +"uri-js@npm:^4.2.2": + version: 4.4.1 + resolution: "uri-js@npm:4.4.1" + dependencies: + punycode: ^2.1.0 + checksum: 7167432de6817fe8e9e0c9684f1d2de2bb688c94388f7569f7dbdb1587c9f4ca2a77962f134ec90be0cc4d004c939ff0d05acc9f34a0db39a3c797dada262633 + languageName: node + linkType: hard + +"util-deprecate@npm:^1.0.1": + version: 1.0.2 + resolution: "util-deprecate@npm:1.0.2" + checksum: 474acf1146cb2701fe3b074892217553dfcf9a031280919ba1b8d651a068c9b15d863b7303cb15bd00a862b498e6cf4ad7b4a08fb134edd5a6f7641681cb54a2 + languageName: node + linkType: hard + +"uuid@npm:^3.3.3": + version: 3.4.0 + resolution: "uuid@npm:3.4.0" + bin: + uuid: ./bin/uuid + checksum: 58de2feed61c59060b40f8203c0e4ed7fd6f99d42534a499f1741218a1dd0c129f4aa1de797bcf822c8ea5da7e4137aa3673431a96dae729047f7aca7b27866f + languageName: node + linkType: hard + +"v8-compile-cache-lib@npm:^3.0.0": + version: 3.0.0 + resolution: "v8-compile-cache-lib@npm:3.0.0" + checksum: 674e312bbca796584b61dc915f33c7e7dc4e06d196e0048cb772c8964493a1ec723f1dd014d9419fd55c24a6eae148f60769da23f622e05cd13268063fa1ed6b + languageName: node + linkType: hard + +"v8-compile-cache@npm:^2.0.3": + version: 2.3.0 + resolution: "v8-compile-cache@npm:2.3.0" + checksum: adb0a271eaa2297f2f4c536acbfee872d0dd26ec2d76f66921aa7fc437319132773483344207bdbeee169225f4739016d8d2dbf0553913a52bb34da6d0334f8e + languageName: node + linkType: hard + +"which-module@npm:^2.0.0": + version: 2.0.0 + resolution: "which-module@npm:2.0.0" + checksum: 809f7fd3dfcb2cdbe0180b60d68100c88785084f8f9492b0998c051d7a8efe56784492609d3f09ac161635b78ea29219eb1418a98c15ce87d085bce905705c9c + languageName: node + linkType: hard + +"which@npm:2.0.2, which@npm:^2.0.1, which@npm:^2.0.2": + version: 2.0.2 + resolution: "which@npm:2.0.2" + dependencies: + isexe: ^2.0.0 + bin: + node-which: ./bin/node-which + checksum: 1a5c563d3c1b52d5f893c8b61afe11abc3bab4afac492e8da5bde69d550de701cf9806235f20a47b5c8fa8a1d6a9135841de2596535e998027a54589000e66d1 + languageName: node + linkType: hard + +"wide-align@npm:^1.1.2": + version: 1.1.5 + resolution: "wide-align@npm:1.1.5" + dependencies: + string-width: ^1.0.2 || 2 || 3 || 4 + checksum: d5fc37cd561f9daee3c80e03b92ed3e84d80dde3365a8767263d03dacfc8fa06b065ffe1df00d8c2a09f731482fcacae745abfbb478d4af36d0a891fad4834d3 + languageName: node + linkType: hard + +"word-wrap@npm:^1.2.3": + version: 1.2.3 + resolution: "word-wrap@npm:1.2.3" + checksum: 30b48f91fcf12106ed3186ae4fa86a6a1842416df425be7b60485de14bec665a54a68e4b5156647dec3a70f25e84d270ca8bc8cd23182ed095f5c7206a938c1f + languageName: node + linkType: hard + +"workerpool@npm:6.2.0": + version: 6.2.0 + resolution: "workerpool@npm:6.2.0" + checksum: 3493b4f0ef979a23d2c1583d7ef85f62fc9463cc02f82829d3e7e663b517f8ae9707da0249b382e46ac58986deb0ca2232ee1081713741211bda9254b429c9bb + languageName: node + linkType: hard + +"wrap-ansi@npm:^6.2.0": + version: 6.2.0 + resolution: "wrap-ansi@npm:6.2.0" + dependencies: + ansi-styles: ^4.0.0 + string-width: ^4.1.0 + strip-ansi: ^6.0.0 + checksum: 6cd96a410161ff617b63581a08376f0cb9162375adeb7956e10c8cd397821f7eb2a6de24eb22a0b28401300bf228c86e50617cd568209b5f6775b93c97d2fe3a + languageName: node + linkType: hard + +"wrap-ansi@npm:^7.0.0": + version: 7.0.0 + resolution: "wrap-ansi@npm:7.0.0" + dependencies: + ansi-styles: ^4.0.0 + string-width: ^4.1.0 + strip-ansi: ^6.0.0 + checksum: a790b846fd4505de962ba728a21aaeda189b8ee1c7568ca5e817d85930e06ef8d1689d49dbf0e881e8ef84436af3a88bc49115c2e2788d841ff1b8b5b51a608b + languageName: node + linkType: hard + +"wrappy@npm:1": + version: 1.0.2 + resolution: "wrappy@npm:1.0.2" + checksum: 159da4805f7e84a3d003d8841557196034155008f817172d4e986bd591f74aa82aa7db55929a54222309e01079a65a92a9e6414da5a6aa4b01ee44a511ac3ee5 + languageName: node + linkType: hard + +"write-file-atomic@npm:^3.0.0": + version: 3.0.3 + resolution: "write-file-atomic@npm:3.0.3" + dependencies: + imurmurhash: ^0.1.4 + is-typedarray: ^1.0.0 + signal-exit: ^3.0.2 + typedarray-to-buffer: ^3.1.5 + checksum: c55b24617cc61c3a4379f425fc62a386cc51916a9b9d993f39734d005a09d5a4bb748bc251f1304e7abd71d0a26d339996c275955f527a131b1dcded67878280 + languageName: node + linkType: hard + +"y18n@npm:^4.0.0": + version: 4.0.3 + resolution: "y18n@npm:4.0.3" + checksum: 014dfcd9b5f4105c3bb397c1c8c6429a9df004aa560964fb36732bfb999bfe83d45ae40aeda5b55d21b1ee53d8291580a32a756a443e064317953f08025b1aa4 + languageName: node + linkType: hard + +"y18n@npm:^5.0.5": + version: 5.0.8 + resolution: "y18n@npm:5.0.8" + checksum: 54f0fb95621ee60898a38c572c515659e51cc9d9f787fb109cef6fde4befbe1c4602dc999d30110feee37456ad0f1660fa2edcfde6a9a740f86a290999550d30 + languageName: node + linkType: hard + +"yallist@npm:^4.0.0": + version: 4.0.0 + resolution: "yallist@npm:4.0.0" + checksum: 343617202af32df2a15a3be36a5a8c0c8545208f3d3dfbc6bb7c3e3b7e8c6f8e7485432e4f3b88da3031a6e20afa7c711eded32ddfb122896ac5d914e75848d5 + languageName: node + linkType: hard + +"yargs-parser@npm:20.2.4": + version: 20.2.4 + resolution: "yargs-parser@npm:20.2.4" + checksum: d251998a374b2743a20271c2fd752b9fbef24eb881d53a3b99a7caa5e8227fcafd9abf1f345ac5de46435821be25ec12189a11030c12ee6481fef6863ed8b924 + languageName: node + linkType: hard + +"yargs-parser@npm:^18.1.2": + version: 18.1.3 + resolution: "yargs-parser@npm:18.1.3" + dependencies: + camelcase: ^5.0.0 + decamelize: ^1.2.0 + checksum: 60e8c7d1b85814594d3719300ecad4e6ae3796748b0926137bfec1f3042581b8646d67e83c6fc80a692ef08b8390f21ddcacb9464476c39bbdf52e34961dd4d9 + languageName: node + linkType: hard + +"yargs-parser@npm:^20.2.2": + version: 20.2.9 + resolution: "yargs-parser@npm:20.2.9" + checksum: 8bb69015f2b0ff9e17b2c8e6bfe224ab463dd00ca211eece72a4cd8a906224d2703fb8a326d36fdd0e68701e201b2a60ed7cf81ce0fd9b3799f9fe7745977ae3 + languageName: node + linkType: hard + +"yargs-unparser@npm:2.0.0": + version: 2.0.0 + resolution: "yargs-unparser@npm:2.0.0" + dependencies: + camelcase: ^6.0.0 + decamelize: ^4.0.0 + flat: ^5.0.2 + is-plain-obj: ^2.1.0 + checksum: 68f9a542c6927c3768c2f16c28f71b19008710abd6b8f8efbac6dcce26bbb68ab6503bed1d5994bdbc2df9a5c87c161110c1dfe04c6a3fe5c6ad1b0e15d9a8a3 + languageName: node + linkType: hard + +"yargs@npm:16.2.0": + version: 16.2.0 + resolution: "yargs@npm:16.2.0" + dependencies: + cliui: ^7.0.2 + escalade: ^3.1.1 + get-caller-file: ^2.0.5 + require-directory: ^2.1.1 + string-width: ^4.2.0 + y18n: ^5.0.5 + yargs-parser: ^20.2.2 + checksum: b14afbb51e3251a204d81937c86a7e9d4bdbf9a2bcee38226c900d00f522969ab675703bee2a6f99f8e20103f608382936034e64d921b74df82b63c07c5e8f59 + languageName: node + linkType: hard + +"yargs@npm:^15.0.2": + version: 15.4.1 + resolution: "yargs@npm:15.4.1" + dependencies: + cliui: ^6.0.0 + decamelize: ^1.2.0 + find-up: ^4.1.0 + get-caller-file: ^2.0.1 + require-directory: ^2.1.1 + require-main-filename: ^2.0.0 + set-blocking: ^2.0.0 + string-width: ^4.2.0 + which-module: ^2.0.0 + y18n: ^4.0.0 + yargs-parser: ^18.1.2 + checksum: 40b974f508d8aed28598087720e086ecd32a5fd3e945e95ea4457da04ee9bdb8bdd17fd91acff36dc5b7f0595a735929c514c40c402416bbb87c03f6fb782373 + languageName: node + linkType: hard + +"yn@npm:3.1.1": + version: 3.1.1 + resolution: "yn@npm:3.1.1" + checksum: 2c487b0e149e746ef48cda9f8bad10fc83693cd69d7f9dcd8be4214e985de33a29c9e24f3c0d6bcf2288427040a8947406ab27f7af67ee9456e6b84854f02dd6 + languageName: node + linkType: hard + +"yocto-queue@npm:^0.1.0": + version: 0.1.0 + resolution: "yocto-queue@npm:0.1.0" + checksum: f77b3d8d00310def622123df93d4ee654fc6a0096182af8bd60679ddcdfb3474c56c6c7190817c84a2785648cdee9d721c0154eb45698c62176c322fb46fc700 + languageName: node + linkType: hard From bce55c37f69e457e3b6311275d5def0544a7e76a Mon Sep 17 00:00:00 2001 From: Volodymyr V <14982064+hypeofpipe@users.noreply.github.com> Date: Wed, 9 Feb 2022 11:13:57 +0100 Subject: [PATCH 051/146] Update README.md Update link for Intercom Javascript --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index acf1a93e..5098d3b9 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ The Node SDK has been updated to support latest API version (2.4). The update al yarn add intercom-client ``` -**This client is intended for server side use only. Please use the [Intercom Javascript SDK](https://developers.intercom.com/v2.4/docs/intercom-javascript) for client-side operations.** +**This client is intended for server side use only. Please use the [Intercom Javascript SDK](https://developers.intercom.com/installing-intercom/docs/intercom-javascript) for client-side operations.** ## Testing From aed25b253cdd53f366348f4a14064c6f7357d8f0 Mon Sep 17 00:00:00 2001 From: Volodymyr V <14982064+hypeofpipe@users.noreply.github.com> Date: Wed, 9 Feb 2022 11:24:07 +0100 Subject: [PATCH 052/146] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 5098d3b9..ad0b2026 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ The Node SDK has been updated to support latest API version (2.4). The update al yarn add intercom-client ``` -**This client is intended for server side use only. Please use the [Intercom Javascript SDK](https://developers.intercom.com/installing-intercom/docs/intercom-javascript) for client-side operations.** +**This client is intended for server side use only. Please use the [Intercom Javascript SDK](https://developers.intercom.com/installing-intercom/docs/intercom-for-web) for client-side operations.** ## Testing From 8763fa70022698e76e3c0c9799b40dedfa0a9dd7 Mon Sep 17 00:00:00 2001 From: Volo Date: Thu, 10 Feb 2022 11:52:03 +0200 Subject: [PATCH 053/146] Fix no email in creating contact params --- lib/contact.ts | 21 +++++++++------------ package.json | 2 +- test/contact.ts | 39 ++++++++++++++++++++++++++++++++++++++- 3 files changed, 48 insertions(+), 14 deletions(-) diff --git a/lib/contact.ts b/lib/contact.ts index 830275cb..00480a2e 100644 --- a/lib/contact.ts +++ b/lib/contact.ts @@ -19,6 +19,7 @@ export default class Contact { } createUser({ externalId, + email, phone, name, avatar, @@ -31,6 +32,7 @@ export default class Contact { const requestData: CreateContactRequest = { role: Role.USER, external_id: externalId, + email, phone, name, avatar, @@ -55,7 +57,7 @@ export default class Contact { signed_up_at: data?.signedUpAt, last_seen_at: data?.lastSeenAt, owner_id: data?.ownerId, - unsubscribed_from_emails: data?.isUnsubscribedFromMails, + unsubscribed_from_emails: data?.isUnsubscribedFromEmails, custom_attributes: data?.customAttributes, }; return this.client.post({ @@ -185,8 +187,7 @@ type CreateContactRequest = Pick & > >; -interface CreateUserData { - externalId?: CreateContactRequest['external_id']; +interface CreateUserDataBase { phone?: CreateContactRequest['phone']; name?: CreateContactRequest['name']; avatar?: CreateContactRequest['avatar']; @@ -197,16 +198,12 @@ interface CreateUserData { customAttributes?: CreateContactRequest['custom_attributes']; } -interface CreateLeadData { - phone?: CreateContactRequest['phone']; - name?: CreateContactRequest['name']; - avatar?: CreateContactRequest['avatar']; - signedUpAt?: CreateContactRequest['signed_up_at']; - lastSeenAt?: CreateContactRequest['last_seen_at']; - ownerId?: CreateContactRequest['owner_id']; - isUnsubscribedFromMails?: CreateContactRequest['unsubscribed_from_emails']; - customAttributes?: CreateContactRequest['custom_attributes']; +interface CreateUserData extends CreateUserDataBase { + email?: string; + externalId?: string; } + +type CreateLeadData = CreateUserDataBase; // interface RetrieveContactData { id: string; diff --git a/package.json b/package.json index 30096afd..65fe08e3 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.1.1", + "version": "3.1.2", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", diff --git a/test/contact.ts b/test/contact.ts index d23e0ecc..1d666781 100644 --- a/test/contact.ts +++ b/test/contact.ts @@ -5,7 +5,7 @@ import { Operators, Role } from '../lib/common/common.types'; import { SearchContactOrderBy } from '../lib/contact'; describe('contacts', () => { - it('should create a contact with user role', async () => { + it('should create a contact with user role with external id', async () => { const id = '536e564f316c83104c000020'; const contact = { @@ -44,6 +44,43 @@ describe('contacts', () => { assert.deepStrictEqual(expectedReply, response); }); + it('should create a contact with user role with email', async () => { + const contact = { + role: 'user', + email: 'niko_bellic@mail.com', + phone: '+48370044567', + name: 'Niko Bellic', + avatar: 'https://nico-from-gta-iv.com/lets_go_bowling.jpg', + signed_up_at: 1638203719, + last_seen_at: 1638203719, + owner_id: 1, + unsubscribed_from_emails: true, + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post('/contacts', contact) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.createUser({ + email: contact.email, + phone: contact.phone, + name: contact.name, + avatar: contact.avatar, + signedUpAt: contact.signed_up_at, + lastSeenAt: contact.last_seen_at, + ownerId: contact.owner_id, + isUnsubscribedFromEmails: contact.unsubscribed_from_emails, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + it('should create a contact with lead role', async () => { const contact = { role: 'lead', From c3bbe4797b910d1722456faa89da67b90f7e0461 Mon Sep 17 00:00:00 2001 From: Volo Date: Thu, 10 Feb 2022 12:21:49 +0200 Subject: [PATCH 054/146] Fix issue #308 --- tsconfig.json | 1 - 1 file changed, 1 deletion(-) diff --git a/tsconfig.json b/tsconfig.json index 94d0069f..aa3a2e02 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -7,7 +7,6 @@ "target": "es5", "module": "commonjs", "moduleResolution": "node", - "importHelpers": true, "emitDecoratorMetadata": true, "experimentalDecorators": true, "sourceMap": true, From 757c38ec341cf9dcce5bb855901774f857dd04a0 Mon Sep 17 00:00:00 2001 From: Volo Date: Thu, 10 Feb 2022 12:26:57 +0200 Subject: [PATCH 055/146] Fix issue #309 --- lib/conversation.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/conversation.ts b/lib/conversation.ts index c800db2c..1364a969 100644 --- a/lib/conversation.ts +++ b/lib/conversation.ts @@ -406,7 +406,7 @@ interface SnoozeConversationData { } // export enum CloseConversationMessageType { - CLOSED = 'closed', + CLOSED = 'close', } export enum CloseConversationType { ADMIN = 'admin', From 58db454796cd9b87ff2e41718a636d4b3fe02ac9 Mon Sep 17 00:00:00 2001 From: Volo Date: Wed, 9 Feb 2022 17:36:48 +0200 Subject: [PATCH 056/146] WIP: Split building and unit testing into two separate jobs WIP: Split building and unit testing into two separate jobs WIP: Split building and unit testing into two separate jobs WIP: Split building and unit testing into two separate jobs WIP: Split building and unit testing into two separate jobs WIP: Split building and unit testing into two separate jobs WIP: Split building and unit testing into two separate jobs --- .circleci/config.yml | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 969d0b65..7ee3caf9 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -3,17 +3,38 @@ jobs: build: docker: - image: circleci/node:14-browsers - working_directory: ~/intercom-node - steps: - checkout - run: export PATH="${PATH}:/home/circleci/.yarn/bin" - run: npm install --prefix=$HOME/.local --global corepack + - restore_cache: + key: dependency-cache-{{ checksum "yarn.lock" }} - run: yarn + - save_cache: + key: dependency-cache-{{ checksum "yarn.lock" }} + paths: + - node_modules - run: yarn prepublish + unit_test: + docker: + - image: circleci/node:14-browsers + working_directory: ~/intercom-node + steps: + - checkout + - restore_cache: + key: dependency-cache-{{ checksum "yarn.lock" }} - run: yarn test +workflows: + version: 2 + build_and_test: + jobs: + - build + - unit_test: + requires: + - build + notify: webhooks: - url: https://muster.intercom.io/circle_webhooks From bff65aaf62a9c7739961eb17507333bc3e504c54 Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 16:12:40 +0200 Subject: [PATCH 057/146] Add integration tests; Separate commands for tests; Delete only one deprecated method --- test/integration/admins.test.ts | 43 +++++ test/integration/articles.test.ts | 63 +++++++ test/integration/companies.test.ts | 111 +++++++++++ test/integration/contacts.test.ts | 113 +++++++++++ test/integration/conversations.test.ts | 176 ++++++++++++++++++ test/integration/counts.test.ts | 48 +++++ test/integration/dataAttributes.test.ts | 44 +++++ test/integration/events.test.ts | 32 ++++ .../helpCenter/collections.test.ts | 56 ++++++ test/integration/helpCenter/sections.test.ts | 57 ++++++ test/integration/integration.test.ts | 73 ++++++++ test/integration/notes.test.ts | 36 ++++ test/integration/segments.test.ts | 18 ++ test/integration/tags.test.ts | 90 +++++++++ test/integration/teams.test.ts | 18 ++ test/integration/utils/config.ts | 25 +++ test/integration/utils/date.ts | 2 + test/integration/utils/random.ts | 6 + test/integration/visitors.test.ts | 87 +++++++++ 19 files changed, 1098 insertions(+) create mode 100644 test/integration/admins.test.ts create mode 100644 test/integration/articles.test.ts create mode 100644 test/integration/companies.test.ts create mode 100644 test/integration/contacts.test.ts create mode 100644 test/integration/conversations.test.ts create mode 100644 test/integration/counts.test.ts create mode 100644 test/integration/dataAttributes.test.ts create mode 100644 test/integration/events.test.ts create mode 100644 test/integration/helpCenter/collections.test.ts create mode 100644 test/integration/helpCenter/sections.test.ts create mode 100644 test/integration/integration.test.ts create mode 100644 test/integration/notes.test.ts create mode 100644 test/integration/segments.test.ts create mode 100644 test/integration/tags.test.ts create mode 100644 test/integration/teams.test.ts create mode 100644 test/integration/utils/config.ts create mode 100644 test/integration/utils/date.ts create mode 100644 test/integration/utils/random.ts create mode 100644 test/integration/visitors.test.ts diff --git a/test/integration/admins.test.ts b/test/integration/admins.test.ts new file mode 100644 index 00000000..f5669c78 --- /dev/null +++ b/test/integration/admins.test.ts @@ -0,0 +1,43 @@ +import { adminId, token } from './utils/config'; +import { Client } from '../../dist'; +import assert from 'assert'; + +describe('Admins', () => { + const client = new Client({ tokenAuth: { token } }); + + it('find', async () => { + const response = await client.admins.find({ id: adminId }); + + assert.notEqual(response, undefined); + }); + it('list', async () => { + const response = await client.admins.list(); + + assert.notEqual(response, undefined); + }); + it('listAllActivityLogs', async () => { + const response = await client.admins.listAllActivityLogs({ + after: new Date('2021-12-12'), + }); + + assert.notEqual(response, undefined); + }); + it('away - ON', async () => { + const response = await client.admins.away({ + adminId, + enableAwayMode: true, + enableReassignMode: true, + }); + + assert.notEqual(response, undefined); + }); + it('away - OFF', async () => { + const response = await client.admins.away({ + adminId, + enableAwayMode: false, + enableReassignMode: false, + }); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/articles.test.ts b/test/integration/articles.test.ts new file mode 100644 index 00000000..ab8d172e --- /dev/null +++ b/test/integration/articles.test.ts @@ -0,0 +1,63 @@ +import { Client } from '../../dist'; +import assert from 'assert'; +import { + adminId as adminIdString, + token, + parentId as parentIdString, +} from './utils/config'; +import { randomString } from './utils/random'; + +describe('Articles', () => { + let newArticleId = '0'; + const adminId = parseInt(adminIdString, 10); + const parentId = parseInt(parentIdString, 10); + + const client = new Client({ tokenAuth: { token } }); + + it('create', async () => { + const response = await client.articles.create({ + title: randomString(), + description: randomString(), + body: 'Eins Zwei', + authorId: adminId, + state: 'draft', + parentId, + parentType: 'collection', + translatedContent: { + fr: { + title: 'Allez les verts', + description: 'French description', + body: '

French body in html

', + author_id: adminId, + state: 'draft', + }, + }, + }); + + newArticleId = response.id; + assert.notEqual(response, undefined); + }); + it('find', async () => { + const response = await client.articles.find({ id: newArticleId }); + + assert.notEqual(response, undefined); + }); + it('update', async () => { + const response = await client.articles.update({ + id: newArticleId, + title: 'Biba & Boba', + }); + + assert.notEqual(response, undefined); + }); + it('delete', async () => { + const response = await client.articles.delete({ id: newArticleId }); + + assert.notEqual(response, undefined); + }); + it('list', async () => { + const response = await client.articles.list({ page: 1, perPage: 12 }); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/companies.test.ts b/test/integration/companies.test.ts new file mode 100644 index 00000000..b564a293 --- /dev/null +++ b/test/integration/companies.test.ts @@ -0,0 +1,111 @@ +import { Client, CompanyObject, Order } from '../../dist'; +import assert from 'assert'; +import { contactId, token } from './utils/config'; +import { dateToUnixTimestamp } from '../../lib/util/time'; + +describe('Companies', () => { + let createdCompany: CompanyObject; + const client = new Client({ tokenAuth: { token } }); + + it('create', async () => { + const response = await client.companies.create({ + createdAt: dateToUnixTimestamp(new Date()), + companyId: '46029', + name: 'BestCompanyInc.', + monthlySpend: 9001, + plan: '1. Get pizzaid', + size: 62049, + website: 'http://the-best.one', + industry: 'The Best One', + customAttributes: {}, + }); + + createdCompany = response; + + assert.notEqual(response, undefined); + }); + it('update', async () => { + const response = await client.companies.update({ + createdAt: dateToUnixTimestamp(new Date()), + companyId: createdCompany.id, + name: 'BestCompanyInc', + monthlySpend: 9001, + plan: '1. Get pizzaid', + size: 62049, + website: 'http://the-best.one', + industry: 'The Best One', + customAttributes: {}, + }); + + assert.notEqual(response, undefined); + }); + it('find - by id', async () => { + const response = await client.companies.find({ + companyId: createdCompany.company_id, + }); + + assert.notEqual(response, undefined); + }); + // TO-DO: Create issue on API. Doesn't work on API.. + // it('find - by name', async () => { + // const response = await client.companies.find({ + // name: 'BestCompanyInc', + // }); + + // assert.notEqual(response, undefined); + // }); + it('list', async () => { + const response = await client.companies.list({ + page: 1, + perPage: 35, + order: Order.DESC, + tagId: '2084335', + }); + + assert.notEqual(response, undefined); + }); + it('scroll - infinite one', async () => { + const response = await client.companies.scroll.each({}); + + assert.notEqual(response, undefined); + }); + it('attachContact', async () => { + const response = await client.companies.attachContact({ + contactId, + companyId: createdCompany.id, + }); + + assert.notEqual(response, undefined); + }); + it('detachContact', async () => { + const response = await client.companies.detachContact({ + contactId, + companyId: createdCompany.id, + }); + + assert.notEqual(response, undefined); + }); + it('listAttachedContacts', async () => { + const response = await client.companies.listAttachedContacts({ + companyId: createdCompany.id, + page: 1, + perPage: 25, + }); + + assert.notEqual(response, undefined); + }); + it('listAttachedSegments', async () => { + const response = await client.companies.listAttachedSegments({ + companyId: createdCompany.id, + }); + + assert.notEqual(response, undefined); + }); + it('delete', async () => { + const response = await client.companies.delete({ + id: createdCompany.id, + }); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/contacts.test.ts b/test/integration/contacts.test.ts new file mode 100644 index 00000000..b2eb718d --- /dev/null +++ b/test/integration/contacts.test.ts @@ -0,0 +1,113 @@ +import { Client, ContactObject } from '../../dist'; +import assert from 'assert'; +import { token } from './utils/config'; +import { randomString } from './utils/random'; + +describe('Contacts', () => { + let randomContact: ContactObject; + let createdUser: ContactObject; + let createdLead: ContactObject; + let mergedLeadAndUser: ContactObject; + + const client = new Client({ tokenAuth: { token } }); + + it('list', async () => { + const response = await client.contacts.list({ perPage: 5 }); + + randomContact = response && response.data[2]; + + assert.notEqual(response, undefined); + }); + it('createUser', async () => { + const response = await client.contacts.createUser({ + externalId: randomString(), + phone: randomContact.phone, + }); + + createdUser = response; + + assert.notEqual(response, undefined); + }); + it('createLead', async () => { + const response = await client.contacts.createLead({ + name: 'Roman Bowling', + }); + + createdLead = response; + + assert.notEqual(response, undefined); + }); + it('find - by id', async () => { + const response = await client.contacts.find({ + id: randomContact.id, + }); + + assert.notEqual(response, undefined); + }); + it('update', async () => { + const response = await client.contacts.update({ + id: randomContact.id, + name: 'Nico Bellic', + }); + + assert.notEqual(response, undefined); + }); + it('archive', async () => { + const response = await client.contacts.archive({ + id: randomContact.id, + }); + assert.notEqual(response, undefined); + }); + it('unarchive', async () => { + const response = await client.contacts.unarchive({ + id: randomContact.id, + }); + + assert.notEqual(response, undefined); + }); + it('mergeLeadInUser', async () => { + const response = await client.contacts.mergeLeadInUser({ + leadId: createdLead && createdLead.id, + userId: createdUser && createdUser.id, + }); + + mergedLeadAndUser = response; + + assert.notEqual(response, undefined); + }); + it('delete', async () => { + const response = await client.contacts.delete({ + id: mergedLeadAndUser.id, + }); + + assert.notEqual(response, undefined); + }); + it('listAttachedCompanies', async () => { + const response = await client.contacts.listAttachedCompanies({ + id: randomContact.id, + }); + + assert.notEqual(response, undefined); + }); + it('listAttachedEmailSubscriptions', async () => { + const response = await client.contacts.listAttachedEmailSubscriptions({ + id: randomContact.id, + }); + + assert.notEqual(response, undefined); + }); + it('listAttachedSegments', async () => { + const response = await client.contacts.listAttachedSegments({ + id: randomContact.id, + }); + + assert.notEqual(response, undefined); + }); + it('listAttachedTags', async () => { + const response = await client.contacts.listAttachedTags({ + id: randomContact.id, + }); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/conversations.test.ts b/test/integration/conversations.test.ts new file mode 100644 index 00000000..71428f78 --- /dev/null +++ b/test/integration/conversations.test.ts @@ -0,0 +1,176 @@ +import { + Client, + AssignToConversationUserType, + RedactConversationPartType, + ReplyToConversationMessageType, + Operators, + ContactObject, + ConversationObject, + MessageObject, +} from '../../dist'; +import assert from 'assert'; +import { token, adminId } from './utils/config'; +import { randomString } from './utils/random'; + +describe('Conversations', () => { + let user: ContactObject; + let secondUser: ContactObject; + let createdConversation: MessageObject; + let foundConversation: ConversationObject; + + const anotherAdminId = '4868'; + + const client = new Client({ tokenAuth: { token } }); + + before(async () => { + user = await client.contacts.createUser({ + externalId: randomString(), + name: 'Baba Booey', + }); + secondUser = await client.contacts.createUser({ + externalId: randomString(), + name: 'Babushka Boy', + email: 'babushka_boy@bababooey.com', + }); + }); + + it('create', async () => { + const response = await client.conversations.create({ + userId: user.id, + body: 'Raz-dwa-try kalyna, czorniawaja diwczyna', + }); + + createdConversation = response; + + assert.notEqual(response, undefined); + }); + + it('find - by id', async () => { + const response = await client.conversations.find({ + id: createdConversation.conversation_id as string, + }); + + foundConversation = response; + + assert.notEqual(response, undefined); + }); + it('update', async () => { + const response = await client.conversations.update({ + id: foundConversation.id, + markRead: false, + }); + + assert.notEqual(response, undefined); + }); + // TO-DO: Fix on API side. + // it('replyToLastConversationAsAdmin', async () => { + // const response = await client.conversations.replyByLastAsAdmin({ + // adminId, + // messageType: ReplyToConversationMessageType.COMMENT, + // body: 'test', + // }); + // assert.notEqual(response, undefined); + // }); + it('replyByIdAsAdmin', async () => { + const response = await client.conversations.replyByIdAsAdmin({ + id: foundConversation.id, + adminId, + body: 'test', + messageType: ReplyToConversationMessageType.COMMENT, + }); + + assert.notEqual(response, undefined); + }); + it('replyByIdAsUser', async () => { + const response = await client.conversations.replyByIdAsUser({ + id: foundConversation.id, + intercomUserId: user.id, + body: '*click* Nice!', + }); + + foundConversation = response; + + assert.notEqual(response, undefined); + }); + it('assign', async () => { + const response = await client.conversations.assign({ + id: foundConversation.id, + assigneeId: anotherAdminId, + adminId, + type: AssignToConversationUserType.ADMIN, + }); + assert.notEqual(response, undefined); + }); + it('snooze', async () => { + const response = await client.conversations.snooze({ + id: foundConversation.id, + adminId, + snoozedUntil: `${new Date('2040.06.19').getTime() / 1000}`, + }); + + assert.notEqual(response, undefined); + }); + it('open', async () => { + const response = await client.conversations.open({ + id: foundConversation.id, + adminId, + }); + + assert.notEqual(response, undefined); + }); + it('attachContactAsAdmin', async () => { + const response = await client.conversations.attachContactAsAdmin({ + id: foundConversation.id, + adminId, + customer: { intercomUserId: secondUser.id }, + }); + + assert.notEqual(response, undefined); + }); + it('detachContactAsAdmin', async () => { + const response = await client.conversations.detachContactAsAdmin({ + conversationId: foundConversation.id, + adminId, + contactId: user.id, + }); + + assert.notEqual(response, undefined); + }); + it('redactConversationPart', async () => { + const response = await client.conversations.redactConversationPart({ + conversationId: foundConversation.id, + conversationPartId: + foundConversation.conversation_parts.conversation_parts[0].id, + type: RedactConversationPartType.CONVERSATION_PART, + }); + + assert.notEqual(response, undefined); + }); + it('close', async () => { + const response = await client.conversations.close({ + id: foundConversation.id, + adminId, + body: 'Hasta la vista, baby', + }); + + assert.notEqual(response, undefined); + }); + it('search', async () => { + const response = await client.conversations.search({ + data: { + query: { + operator: Operators.AND, + value: [ + { + field: 'id', + operator: Operators.NOT_EQUALS, + value: '123', + }, + ], + }, + }, + }); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/counts.test.ts b/test/integration/counts.test.ts new file mode 100644 index 00000000..2eb3679f --- /dev/null +++ b/test/integration/counts.test.ts @@ -0,0 +1,48 @@ +import { Client } from '../../dist'; +import assert from 'assert'; +import { token } from './utils/config'; + +describe('Counts', () => { + const client = new Client({ tokenAuth: { token } }); + + it('forApp', async () => { + const response = await client.counts.forApp(); + + assert.notEqual(response, undefined); + }); + it('countConversation', async () => { + const response = await client.counts.countConversation(); + + assert.notEqual(response, undefined); + }); + it('countAdminConversation', async () => { + const response = await client.counts.countAdminConversation(); + + assert.notEqual(response, undefined); + }); + it('countUserSegment', async () => { + const response = await client.counts.countUserSegment(); + + assert.notEqual(response, undefined); + }); + it('countUserTag', async () => { + const response = await client.counts.countUserTag(); + + assert.notEqual(response, undefined); + }); + it('countCompanySegment', async () => { + const response = await client.counts.countCompanySegment(); + + assert.notEqual(response, undefined); + }); + it('countCompanyTag', async () => { + const response = await client.counts.countCompanyTag(); + + assert.notEqual(response, undefined); + }); + it('countCompanyUser', async () => { + const response = await client.counts.countCompanyUser(); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/dataAttributes.test.ts b/test/integration/dataAttributes.test.ts new file mode 100644 index 00000000..077a86a4 --- /dev/null +++ b/test/integration/dataAttributes.test.ts @@ -0,0 +1,44 @@ +import { Client, DataAttributeObject, DataType, ModelType } from '../../dist'; +import assert from 'assert'; +import { token } from './utils/config'; +import { randomInt } from './utils/random'; + +describe('Data Attributes', () => { + let createdDataAttribute: DataAttributeObject; + + const client = new Client({ tokenAuth: { token } }); + + it('create', async () => { + const response = await client.dataAttributes.create({ + name: `Bebech${randomInt(0, 999)},${randomInt( + randomInt(0, 999) + )},${randomInt(0, 999)},${randomInt(randomInt(0, 999))}`, + model: ModelType.CONTACT, + dataType: DataType.STRING, + description: 'Dummy description', + options: [{ value: 'yey' }, { value: 'yoy' }], + }); + + createdDataAttribute = response; + + assert.notEqual(response, undefined); + }); + it('update', async () => { + const response = await client.dataAttributes.update({ + id: createdDataAttribute.id, + archived: false, + description: 'Woo-aaa', + options: [{ value: 'yey' }, { value: 'yoy' }], + }); + + assert.notEqual(response, undefined); + }); + it('list', async () => { + const response = await client.dataAttributes.list({ + includeArchived: true, + model: ModelType.CONVERSATION, + }); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/events.test.ts b/test/integration/events.test.ts new file mode 100644 index 00000000..e230b09b --- /dev/null +++ b/test/integration/events.test.ts @@ -0,0 +1,32 @@ +import { Client } from '../../dist'; +import { dateToUnixTimestamp } from '../../dist/util/time'; +import assert from 'assert'; +import { token, userId } from './utils/config'; + +describe('Events', () => { + const client = new Client({ tokenAuth: { token } }); + + it('create', async () => { + const response = await client.events.create({ + userId, + eventName: 'opinion-rejected', + createdAt: dateToUnixTimestamp(new Date()), + metadata: { + guidance: 'provided', + wereall: 'gonna make it', + price: { amount: 9001, currency: 'eur' }, + }, + }); + + assert.notEqual(response, undefined); + }); + it('listBy', async () => { + const response = await client.events.listBy({ + userId, + perPage: 2, + summary: true, + }); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/helpCenter/collections.test.ts b/test/integration/helpCenter/collections.test.ts new file mode 100644 index 00000000..7dfb92ed --- /dev/null +++ b/test/integration/helpCenter/collections.test.ts @@ -0,0 +1,56 @@ +import { Client, CollectionObject } from '../../../dist'; +import assert from 'assert'; +import { token } from '../utils/config'; + +describe('Collections', () => { + let collection: CollectionObject; + + const client = new Client({ tokenAuth: { token } }); + + it('create', async () => { + const response = await client.helpCenter.collections.create({ + name: 'The Bruh Moment', + description: 'Bruuuuuh', + translatedContent: { + fr: { + name: 'Le Moment Frère', + description: 'Frèèèèère', + }, + }, + }); + + collection = response; + + assert.notEqual(response, undefined); + }); + it('find', async () => { + const response = await client.helpCenter.collections.find({ + id: collection.id, + }); + + assert.notEqual(response, undefined); + }); + it('update', async () => { + const response = await client.helpCenter.collections.update({ + id: collection.id, + name: 'People of future, tell us if NFTs make sense in 2026', + }); + + assert.notEqual(response, undefined); + }); + it('delete', async () => { + const response = await client.helpCenter.collections.delete({ + id: collection.id, + }); + + assert.notEqual(response, undefined); + }); + it('list', async () => { + const response = await client.helpCenter.collections.list({ + perPage: 25, + page: 1, + }); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/helpCenter/sections.test.ts b/test/integration/helpCenter/sections.test.ts new file mode 100644 index 00000000..d02b075e --- /dev/null +++ b/test/integration/helpCenter/sections.test.ts @@ -0,0 +1,57 @@ +import { Client, SectionObject } from '../../../dist'; +import assert from 'assert'; +import { parentId, token } from '../utils/config'; +import { randomString } from '../utils/random'; + +describe('Collections', () => { + let section: SectionObject; + + const client = new Client({ tokenAuth: { token } }); + + it('create', async () => { + const response = await client.helpCenter.sections.create({ + name: randomString(), + parentId, + translatedContent: { + fr: { + name: randomString(), + description: randomString(), + }, + }, + }); + + section = response; + + assert.notEqual(response, undefined); + }); + it('find', async () => { + const response = await client.helpCenter.sections.find({ + id: section.id, + }); + + assert.notEqual(response, undefined); + }); + it('update', async () => { + const response = await client.helpCenter.sections.update({ + id: section.id, + name: 'People of future, tell us if blockchain makes sense in 2026', + }); + + assert.notEqual(response, undefined); + }); + it('delete', async () => { + const response = await client.helpCenter.sections.delete({ + id: section.id, + }); + + assert.notEqual(response, undefined); + }); + it('list', async () => { + const response = await client.helpCenter.sections.list({ + perPage: 25, + page: 1, + }); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/integration.test.ts b/test/integration/integration.test.ts new file mode 100644 index 00000000..bb952956 --- /dev/null +++ b/test/integration/integration.test.ts @@ -0,0 +1,73 @@ +import { Client, ContactObject, MessageObject } from '../../dist'; +import assert from 'assert'; +import { adminId, companyId, token } from './utils/config'; +import { randomInt } from 'crypto'; + +describe('Integration between Contact, Conversation, Company and Tag APIs', () => { + let user: ContactObject; + let lead: ContactObject; + let contact: ContactObject; + let conversation: MessageObject; + + const client = new Client({ tokenAuth: { token } }); + + it('Create User', async () => { + const response = await client.contacts.createUser({ + externalId: `${randomInt(9999)}-${randomInt(9999)}-${randomInt( + 9999 + )}`, + }); + + user = response; + + assert.notEqual(response, undefined); + }); + + it('Create Lead', async () => { + const response = await client.contacts.createLead({ + name: 'Marek Barek', + }); + + lead = response; + + assert.notEqual(response, undefined); + }); + it('Convert Lead to Contact', async () => { + const response = await client.contacts.mergeLeadInUser({ + leadId: lead.id, + userId: user.id, + }); + + contact = response; + + assert.notEqual(response, undefined); + }); + it('Add Contact to Company', async () => { + const response = await client.companies.attachContact({ + contactId: contact.id, + companyId, + }); + + assert.notEqual(response, undefined); + }); + it('Create Conversation with Contact', async () => { + const response = await client.conversations.create({ + userId: contact.id, + body: 'Welcome to the club, buddy!', + }); + + conversation = response; + + assert.notEqual(response, undefined); + }); + it('Tag the Conversation', async () => { + const tags = await client.tags.list(); + const response = await client.tags.tagConversation({ + conversationId: conversation.conversation_id as string, + tagId: tags.data[0].id, + adminId, + }); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/notes.test.ts b/test/integration/notes.test.ts new file mode 100644 index 00000000..1c578e7a --- /dev/null +++ b/test/integration/notes.test.ts @@ -0,0 +1,36 @@ +import { Client, NoteObject } from '../../dist'; +import assert from 'assert'; +import { adminId, contactId, token } from './utils/config'; +import { randomString } from './utils/random'; + +describe('Notes', () => { + let note: NoteObject; + + const client = new Client({ tokenAuth: { token } }); + + it('create', async () => { + const response = await client.notes.create({ + adminId, + body: randomString(), + contactId, + }); + + note = response; + + assert.notEqual(response, undefined); + }); + it('find', async () => { + const response = await client.notes.find({ id: note.id }); + + assert.notEqual(response, undefined); + }); + it('list', async () => { + const response = await client.notes.list({ + contactId, + perPage: 25, + page: 1, + }); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/segments.test.ts b/test/integration/segments.test.ts new file mode 100644 index 00000000..64aeef4b --- /dev/null +++ b/test/integration/segments.test.ts @@ -0,0 +1,18 @@ +import { Client } from '../../dist'; +import assert from 'assert'; +import { segmentId, token } from './utils/config'; + +describe('Segments', () => { + const client = new Client({ tokenAuth: { token } }); + + it('find', async () => { + const response = await client.segments.find({ id: segmentId }); + + assert.notEqual(response, undefined); + }); + it('list', async () => { + const response = await client.segments.list({ includeCount: true }); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/tags.test.ts b/test/integration/tags.test.ts new file mode 100644 index 00000000..f276abfc --- /dev/null +++ b/test/integration/tags.test.ts @@ -0,0 +1,90 @@ +import { Client, TagObject } from '../../dist'; +import assert from 'assert'; +import { + token, + adminId, + contactId, + conversationId, + companyId, +} from './utils/config'; + +describe('Tags', () => { + let tag: TagObject; + + const client = new Client({ tokenAuth: { token } }); + + it('create', async () => { + const response = await client.tags.create({ + name: 'Bellic and Partners', + }); + + tag = response; + + assert.notEqual(response, undefined); + }); + it('update', async () => { + const response = await client.tags.update({ id: tag.id, name: 'Poor' }); + + assert.notEqual(response, undefined); + }); + it('tagContact', async () => { + const response = await client.tags.tagContact({ + contactId, + tagId: tag.id, + }); + + assert.notEqual(response, undefined); + }); + it('tagConversation', async () => { + const response = await client.tags.tagConversation({ + conversationId, + tagId: tag.id, + adminId, + }); + + assert.notEqual(response, undefined); + }); + it('tagCompanies', async () => { + const response = await client.tags.tagCompanies({ + tagName: 'Poor', + companiesIds: [companyId], + }); + + assert.notEqual(response, undefined); + }); + it('untagContact', async () => { + const response = await client.tags.untagContact({ + contactId, + tagId: tag.id, + }); + + assert.notEqual(response, undefined); + }); + it('untagConversation', async () => { + const response = await client.tags.untagConversation({ + conversationId, + tagId: tag.id, + adminId, + }); + + assert.notEqual(response, undefined); + }); + it('untagCompanies', async () => { + const response = await client.tags.untagCompanies({ + tagName: 'Poor', + companiesIds: [companyId], + }); + + assert.notEqual(response, undefined); + }); + it('list', async () => { + const response = await client.tags.list(); + + assert.notEqual(response, undefined); + }); + it('delete', async () => { + const response = await client.tags.delete({ id: tag.id }); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/teams.test.ts b/test/integration/teams.test.ts new file mode 100644 index 00000000..f8c0710c --- /dev/null +++ b/test/integration/teams.test.ts @@ -0,0 +1,18 @@ +import { Client } from '../../dist'; +import assert from 'assert'; +import { teamId, token } from './utils/config'; + +describe('Teams', () => { + const client = new Client({ tokenAuth: { token } }); + + it('find', async () => { + const response = client.teams.find({ id: teamId }); + + assert.notEqual(response, undefined); + }); + it('list', async () => { + const response = client.teams.list(); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/utils/config.ts b/test/integration/utils/config.ts new file mode 100644 index 00000000..43cbdb66 --- /dev/null +++ b/test/integration/utils/config.ts @@ -0,0 +1,25 @@ +const apiToken = process.env.API_TOKEN; + +if (!apiToken) { + throw new Error('API_TOKEN is required in env to run integration tests!'); +} + +export const token = apiToken; + +export const adminId = '318887'; +export const contactId = '618d3ff1daf39156d7c017b3'; +export const userId = 'f4ca124298'; +export const companyId = '6197d0070d0f186b6ff0db28'; +export const conversationId = '8179903837'; +export const teamId = '971209'; +export const segmentId = '5887658cc813e66156622510'; +export const dataAttributeId = '8774749'; +export const parentId = '3173119'; + +export const logWithBreaks = (...args: any) => { + console.log('///////////////////////////////////////n'); + console.dir(args[1], { depth: null }); + console.log('///////////////////////////////////////n'); + console.dir(args[0], { depth: null }); + console.log('///////////////////////////////////////n'); +}; diff --git a/test/integration/utils/date.ts b/test/integration/utils/date.ts new file mode 100644 index 00000000..0c9f7406 --- /dev/null +++ b/test/integration/utils/date.ts @@ -0,0 +1,2 @@ +export const dateToUnixTimestamp = (date: Date): number => + Math.floor(date.getTime() / 1000); diff --git a/test/integration/utils/random.ts b/test/integration/utils/random.ts new file mode 100644 index 00000000..f74fe680 --- /dev/null +++ b/test/integration/utils/random.ts @@ -0,0 +1,6 @@ +export const randomString = () => + Buffer.from(Math.random().toString()).toString('base64').substring(10, 5); + +export const randomInt = (min = 0, max = 999): number => + Math.floor(Math.random() * (Math.floor(max) - Math.ceil(min) + 1)) + + Math.ceil(min); diff --git a/test/integration/visitors.test.ts b/test/integration/visitors.test.ts new file mode 100644 index 00000000..c1c90e71 --- /dev/null +++ b/test/integration/visitors.test.ts @@ -0,0 +1,87 @@ +// import { logWithBreaks } from './utils/config'; +// import { Client } from 'intercom-client'; + +// // TIP: get client_matches > user_id field from ping request here: https://app.intercom.io/client/test/ecahpwf5 + +// const visitorForDelete = { +// visitorId: '6202ae4c4caf6a35860f843c', // those has to be updated every time before running QA script +// userId: '0a5c7c01-db82-4794-96ef-ab26c855a88f', // those has to be updated every time before running QA script +// }; + +// const visitorForConvertingToContact = { +// visitorId: '6202ae94928cb83fbca343f1', // those has to be updated every time before running QA script +// }; + +// const testVisitors = async (client: Client) => { +// const actions = actionsWithData( +// client, +// data( +// visitorForDelete.visitorId, +// visitorForDelete.userId, +// visitorForConvertingToContact.visitorId +// ) +// ); + +// for (const action of actions) { +// try { +// const response = await action.promise; +// logWithBreaks(response, action.name); +// } catch (e) { +// logWithBreaks(e, action.name); +// throw e; +// } +// } +// }; + +// const data = ( +// idForDelete: string, +// userIdForDelete: string, +// idForConvertingToContact: string +// ) => ({ +// findById: { id: idForDelete }, +// findByUserId: { userId: userIdForDelete }, +// update: { +// userId: userIdForDelete, +// name: 'Winston Smith', +// custom_attributes: {}, +// }, +// delete: { +// id: idForDelete, +// }, +// mergeToContact: { +// visitor: { +// id: idForConvertingToContact, +// }, +// user: { +// email: 'mcboxford@intercom-test.com', +// }, +// type: 'user', +// }, +// }); + +// const actionsWithData = (client: Client, data: any) => [ +// { promise: client.visitors.find(data.findById), name: 'find by id' }, +// { +// promise: client.visitors.find(data.findByUserId), +// name: 'find by user id', +// }, +// { promise: client.visitors.update(data.update), name: 'update' }, +// { promise: client.visitors.delete(data.delete), name: 'delete' }, +// { +// promise: client.visitors.mergeToContact(data.mergeToContact), +// name: 'merge to contaact', +// }, +// ]; + +// (async () => { +// const token = + +// const client = new Client({ tokenAuth: { token } }); + +// try { +// await testVisitors(client); +// } catch (e) { +// console.dir(e, { depth: null }); +// return; +// } +// })(); From 7caa83e562c2f999c3abc331d00ef922504c190e Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 16:15:29 +0200 Subject: [PATCH 058/146] Add QA --- lib/client.ts | 7 ------- package.json | 3 ++- test/{admin.ts => unit/admin.test.ts} | 2 +- test/{article.ts => unit/article.test.ts} | 2 +- test/{client.ts => unit/client.test.ts} | 2 +- test/{company.ts => unit/company.test.ts} | 6 +++--- test/{contact.ts => unit/contact.test.ts} | 6 +++--- .../conversation.test.ts} | 6 +++--- test/{counts.ts => unit/counts.test.ts} | 2 +- .../dataAttribute.test.ts} | 7 +++++-- test/{errors.ts => unit/errors.test.ts} | 2 +- test/{event.ts => unit/event.test.ts} | 2 +- test/{helpCenter.ts => unit/helpCenter.test.ts} | 2 +- test/{index.ts => unit/index.test.ts} | 2 +- test/{message.ts => unit/message.test.ts} | 6 +++--- test/{notes.ts => unit/notes.test.ts} | 2 +- .../request-opts.test.ts} | 16 +--------------- test/{segment.ts => unit/segment.test.ts} | 2 +- test/{tag.ts => unit/tag.test.ts} | 2 +- test/{team.ts => unit/team.test.ts} | 2 +- test/{visitor.ts => unit/visitor.test.ts} | 2 +- 21 files changed, 33 insertions(+), 50 deletions(-) rename test/{admin.ts => unit/admin.test.ts} (98%) rename test/{article.ts => unit/article.test.ts} (99%) rename test/{client.ts => unit/client.test.ts} (98%) rename test/{company.ts => unit/company.test.ts} (98%) rename test/{contact.ts => unit/contact.test.ts} (98%) rename test/{conversation.ts => unit/conversation.test.ts} (99%) rename test/{counts.ts => unit/counts.test.ts} (98%) rename test/{dataAttribute.ts => unit/dataAttribute.test.ts} (94%) rename test/{errors.ts => unit/errors.test.ts} (99%) rename test/{event.ts => unit/event.test.ts} (98%) rename test/{helpCenter.ts => unit/helpCenter.test.ts} (99%) rename test/{index.ts => unit/index.test.ts} (95%) rename test/{message.ts => unit/message.test.ts} (88%) rename test/{notes.ts => unit/notes.test.ts} (97%) rename test/{request-opts.ts => unit/request-opts.test.ts} (84%) rename test/{segment.ts => unit/segment.test.ts} (96%) rename test/{tag.ts => unit/tag.test.ts} (99%) rename test/{team.ts => unit/team.test.ts} (95%) rename test/{visitor.ts => unit/visitor.test.ts} (98%) diff --git a/lib/client.ts b/lib/client.ts index 3dc7142c..e6a1753f 100644 --- a/lib/client.ts +++ b/lib/client.ts @@ -1,4 +1,3 @@ -import { deprecate } from 'util'; import axios, { Axios, AxiosDefaults, AxiosResponse } from 'axios'; import { merge, omit } from 'lodash'; @@ -69,7 +68,6 @@ export default class Client { requestOpts: Partial; tags: Tag; teams: Team; - usebaseURL: (baseURL: string) => this; usernamePart?: string; visitors: Visitor; @@ -105,11 +103,6 @@ export default class Client { }; this.propertiesToOmitInRequestOpts = ['headers.common.Accept']; - this.usebaseURL = deprecate( - (baseURL) => this.useRequestOpts({ baseURL }), - 'intercom-client - client.usebaseURL(url): Use client.useRequestOpts({ baseURL: url }) instead' - ); - this.axiosInstance = this.initiateAxiosInstance(); } initiateAxiosInstance(): Axios { diff --git a/package.json b/package.json index 65fe08e3..e1ef9f4b 100644 --- a/package.json +++ b/package.json @@ -48,7 +48,8 @@ "compile_ts": "tsc", "move_compiled_to_dist": "mv dist/lib/* dist && rmdir dist/lib", "prepublish": "yarn clean && yarn static && yarn compile_ts && yarn move_compiled_to_dist", - "test": "mocha -r ts-node/register test/*.ts", + "test:unit": "mocha -r ts-node/register test/unit/*.test.ts --reporter=nyan", + "test:integration": "mocha -r ts-node/register test/integration/**/*.test.ts --timeout=30000", "coverage": "nyc yarn test" }, "engines": { diff --git a/test/admin.ts b/test/unit/admin.test.ts similarity index 98% rename from test/admin.ts rename to test/unit/admin.test.ts index 90246842..c0ae2c91 100644 --- a/test/admin.ts +++ b/test/unit/admin.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client } from '../lib'; +import { Client } from '../../lib'; import nock from 'nock'; describe('admins', () => { diff --git a/test/article.ts b/test/unit/article.test.ts similarity index 99% rename from test/article.ts rename to test/unit/article.test.ts index b52028a0..a52a873c 100644 --- a/test/article.ts +++ b/test/unit/article.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client } from '../lib'; +import { Client } from '../../lib'; import nock from 'nock'; describe('articles', () => { diff --git a/test/client.ts b/test/unit/client.test.ts similarity index 98% rename from test/client.ts rename to test/unit/client.test.ts index 79f5bc94..7dda2498 100644 --- a/test/client.ts +++ b/test/unit/client.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client } from '../lib'; +import { Client } from '../../lib'; import nock from 'nock'; describe('clients', () => { diff --git a/test/company.ts b/test/unit/company.test.ts similarity index 98% rename from test/company.ts rename to test/unit/company.test.ts index 8725f965..48e3e4b2 100644 --- a/test/company.ts +++ b/test/unit/company.test.ts @@ -1,8 +1,8 @@ import assert from 'assert'; -import { Client } from '../lib'; +import { Client } from '../../lib'; import nock from 'nock'; -import { dateToUnixTimestamp } from '../lib/util/time'; -import { Order } from '../lib/common/common.types'; +import { dateToUnixTimestamp } from '../../lib/util/time'; +import { Order } from '../../lib/common/common.types'; const dummyCompany = { type: 'company', diff --git a/test/contact.ts b/test/unit/contact.test.ts similarity index 98% rename from test/contact.ts rename to test/unit/contact.test.ts index 1d666781..d31105df 100644 --- a/test/contact.ts +++ b/test/unit/contact.test.ts @@ -1,8 +1,8 @@ import assert from 'assert'; -import { Client } from '../lib'; +import { Client } from '../../lib'; import nock from 'nock'; -import { Operators, Role } from '../lib/common/common.types'; -import { SearchContactOrderBy } from '../lib/contact'; +import { Operators, Role } from '../../lib/common/common.types'; +import { SearchContactOrderBy } from '../../lib/contact'; describe('contacts', () => { it('should create a contact with user role with external id', async () => { diff --git a/test/conversation.ts b/test/unit/conversation.test.ts similarity index 99% rename from test/conversation.ts rename to test/unit/conversation.test.ts index 90fe3a9b..2218ff5d 100644 --- a/test/conversation.ts +++ b/test/unit/conversation.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client } from '../lib'; +import { Client } from '../../lib'; import nock from 'nock'; import { AssignToConversationMessageType, @@ -13,8 +13,8 @@ import { SearchConversationOrderBy, SnoozeConversationMessageType, SortBy, -} from '../lib/conversation'; -import { Operators, Order } from '../lib/common/common.types'; +} from '../../lib/conversation'; +import { Operators, Order } from '../../lib/common/common.types'; describe('conversations', () => { it('should create a conversation', async () => { diff --git a/test/counts.ts b/test/unit/counts.test.ts similarity index 98% rename from test/counts.ts rename to test/unit/counts.test.ts index a40b3017..47bb3c26 100644 --- a/test/counts.ts +++ b/test/unit/counts.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client, CountEntity, CountType } from '../lib'; +import { Client, CountEntity, CountType } from '../../lib'; import nock from 'nock'; describe('counts', () => { diff --git a/test/dataAttribute.ts b/test/unit/dataAttribute.test.ts similarity index 94% rename from test/dataAttribute.ts rename to test/unit/dataAttribute.test.ts index 9c4c01cf..b130f3c8 100644 --- a/test/dataAttribute.ts +++ b/test/unit/dataAttribute.test.ts @@ -1,6 +1,9 @@ import assert from 'assert'; -import { Client } from '../lib'; -import { DataType, ModelType } from '../lib/dataAttribute/dataAttribute.types'; +import { Client } from '../../lib'; +import { + DataType, + ModelType, +} from '../../lib/dataAttribute/dataAttribute.types'; import nock from 'nock'; describe('data attributes', () => { diff --git a/test/errors.ts b/test/unit/errors.test.ts similarity index 99% rename from test/errors.ts rename to test/unit/errors.test.ts index 1efc0337..533d0f73 100644 --- a/test/errors.ts +++ b/test/unit/errors.test.ts @@ -1,6 +1,6 @@ import assert from 'assert'; import nock from 'nock'; -import { Client } from '../lib'; +import { Client } from '../../lib'; describe('errors', () => { it('should fail with unauthorized (401) error', async () => { diff --git a/test/event.ts b/test/unit/event.test.ts similarity index 98% rename from test/event.ts rename to test/unit/event.test.ts index 187d9a39..2e40158f 100644 --- a/test/event.ts +++ b/test/unit/event.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client } from '../lib'; +import { Client } from '../../lib'; import nock from 'nock'; describe('events', () => { diff --git a/test/helpCenter.ts b/test/unit/helpCenter.test.ts similarity index 99% rename from test/helpCenter.ts rename to test/unit/helpCenter.test.ts index 8978bff2..668b1be0 100644 --- a/test/helpCenter.ts +++ b/test/unit/helpCenter.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client } from '../lib'; +import { Client } from '../../lib'; import nock from 'nock'; describe('help center', () => { diff --git a/test/index.ts b/test/unit/index.test.ts similarity index 95% rename from test/index.ts rename to test/unit/index.test.ts index cd324c05..fe6e82c9 100644 --- a/test/index.ts +++ b/test/unit/index.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client, IdentityVerification } from '../lib'; +import { Client, IdentityVerification } from '../../lib'; import nock from 'nock'; describe('clients', () => { diff --git a/test/message.ts b/test/unit/message.test.ts similarity index 88% rename from test/message.ts rename to test/unit/message.test.ts index 7306eb1d..9d7ca3ea 100644 --- a/test/message.ts +++ b/test/unit/message.test.ts @@ -1,8 +1,8 @@ import assert from 'assert'; -import { Client } from '../lib'; +import { Client } from '../../lib'; import nock from 'nock'; -import { MessageType } from '../lib/message/message.types'; -import { RecepientType } from '../lib/message'; +import { MessageType } from '../../lib/message/message.types'; +import { RecepientType } from '../../lib/message'; describe('messages', () => { it('should be created', async () => { diff --git a/test/notes.ts b/test/unit/notes.test.ts similarity index 97% rename from test/notes.ts rename to test/unit/notes.test.ts index 2ce9d602..52ee81d8 100644 --- a/test/notes.ts +++ b/test/unit/notes.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client } from '../lib'; +import { Client } from '../../lib'; import nock from 'nock'; describe('notes', () => { diff --git a/test/request-opts.ts b/test/unit/request-opts.test.ts similarity index 84% rename from test/request-opts.ts rename to test/unit/request-opts.test.ts index 7d88ef1e..c66b4e39 100644 --- a/test/request-opts.ts +++ b/test/unit/request-opts.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client } from '../lib'; +import { Client } from '../../lib'; import nock from 'nock'; import sinon from 'sinon'; import { HeadersDefaults } from 'axios'; @@ -72,17 +72,3 @@ describe('request-opts', function () { sinon.assert.calledWithExactly(customHeaderCheck, 'bar'); }); }); - -describe('base-url', function () { - it('should be able to change base url (using old .usebaseURL method)', async () => { - nock('http://local.test-server.com').get('/admins').reply(200, {}); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }).usebaseURL('http://local.test-server.com'); - - const response = await client.admins.list(); - - assert.deepStrictEqual({}, response); - }); -}); diff --git a/test/segment.ts b/test/unit/segment.test.ts similarity index 96% rename from test/segment.ts rename to test/unit/segment.test.ts index 718df81a..85ceae8d 100644 --- a/test/segment.ts +++ b/test/unit/segment.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client } from '../lib'; +import { Client } from '../../lib'; import nock from 'nock'; describe('segments', () => { diff --git a/test/tag.ts b/test/unit/tag.test.ts similarity index 99% rename from test/tag.ts rename to test/unit/tag.test.ts index 8fa5d39a..396fca74 100644 --- a/test/tag.ts +++ b/test/unit/tag.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client } from '../lib'; +import { Client } from '../../lib'; import nock from 'nock'; describe('tags', () => { diff --git a/test/team.ts b/test/unit/team.test.ts similarity index 95% rename from test/team.ts rename to test/unit/team.test.ts index 123ce6fd..53c9b721 100644 --- a/test/team.ts +++ b/test/unit/team.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client } from '../lib'; +import { Client } from '../../lib'; import nock from 'nock'; describe('teams', () => { diff --git a/test/visitor.ts b/test/unit/visitor.test.ts similarity index 98% rename from test/visitor.ts rename to test/unit/visitor.test.ts index abf11e63..3b2745f5 100644 --- a/test/visitor.ts +++ b/test/unit/visitor.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client, Role } from '../lib'; +import { Client, Role } from '../../lib'; import nock from 'nock'; describe('visitors', () => { From 8e38d0ce775327087dcb894e11ea7c9b142e9f67 Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 16:20:18 +0200 Subject: [PATCH 059/146] Fix pipeline; Remove unused logging method --- test/integration/utils/config.ts | 8 -------- 1 file changed, 8 deletions(-) diff --git a/test/integration/utils/config.ts b/test/integration/utils/config.ts index 43cbdb66..47fa3307 100644 --- a/test/integration/utils/config.ts +++ b/test/integration/utils/config.ts @@ -15,11 +15,3 @@ export const teamId = '971209'; export const segmentId = '5887658cc813e66156622510'; export const dataAttributeId = '8774749'; export const parentId = '3173119'; - -export const logWithBreaks = (...args: any) => { - console.log('///////////////////////////////////////n'); - console.dir(args[1], { depth: null }); - console.log('///////////////////////////////////////n'); - console.dir(args[0], { depth: null }); - console.log('///////////////////////////////////////n'); -}; From c7bc99ddb32457b5f495da1070dd2c60e887c362 Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 16:38:15 +0200 Subject: [PATCH 060/146] Fix pipeline --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 7ee3caf9..e0b8dfca 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -24,7 +24,7 @@ jobs: - checkout - restore_cache: key: dependency-cache-{{ checksum "yarn.lock" }} - - run: yarn test + - run: yarn test:unit workflows: version: 2 From 5b516ae41ca7c4c974f0e71d04a5eeacc3390363 Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 16:38:54 +0200 Subject: [PATCH 061/146] Remove unnecessary field query from conversations.list params --- README.md | 10 ++++------ lib/conversation.ts | 14 +++++--------- test/unit/conversation.test.ts | 10 ++++------ 3 files changed, 13 insertions(+), 21 deletions(-) diff --git a/README.md b/README.md index ad0b2026..fec333b9 100644 --- a/README.md +++ b/README.md @@ -727,12 +727,10 @@ const response = await client.conversations.search({ ```typescript const response = await client.conversations.list({ - query: { - order: Order.DESC, - sort: SortBy.UpdatedAt, - page: 1, - perPage: 10, - }, + order: Order.DESC, + sort: SortBy.UpdatedAt, + page: 1, + perPage: 10, }); ``` diff --git a/lib/conversation.ts b/lib/conversation.ts index 1364a969..e9853568 100644 --- a/lib/conversation.ts +++ b/lib/conversation.ts @@ -257,9 +257,7 @@ export default class Conversation { data, }); } - list({ - query: { order, sort, page, perPage: per_page }, - }: ListConversationData) { + list({ order, sort, page, perPage: per_page }: ListConversationData) { const params = { order, sort, page, per_page }; return this.client.get({ @@ -521,12 +519,10 @@ export enum SortBy { } interface ListConversationData { - query: { - order: Order; - sort: SortBy; - page?: number; - perPage?: number; - }; + order?: Order; + sort?: SortBy; + page?: number; + perPage?: number; } type ListConversationResponse = Paginated; diff --git a/test/unit/conversation.test.ts b/test/unit/conversation.test.ts index 2218ff5d..6caa844b 100644 --- a/test/unit/conversation.test.ts +++ b/test/unit/conversation.test.ts @@ -557,12 +557,10 @@ describe('conversations', () => { }); const response = await client.conversations.list({ - query: { - order: Order.DESC, - sort: SortBy.UpdatedAt, - page: 1, - perPage: 10, - }, + order: Order.DESC, + sort: SortBy.UpdatedAt, + page: 1, + perPage: 10, }); assert.deepStrictEqual(expectedReply, response); From 15ecc95f40a3b5534537a0dec035b71cd536d697 Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 16:39:32 +0200 Subject: [PATCH 062/146] Add new Eslint rules: no .only in tests and require await if function is async --- .eslintrc | 6 ++++-- package.json | 3 ++- yarn.lock | 8 ++++++++ 3 files changed, 14 insertions(+), 3 deletions(-) diff --git a/.eslintrc b/.eslintrc index 2c36b550..74f843d4 100644 --- a/.eslintrc +++ b/.eslintrc @@ -1,7 +1,7 @@ { "root": true, "parser": "@typescript-eslint/parser", - "plugins": ["@typescript-eslint"], + "plugins": ["@typescript-eslint", "no-only-tests"], "rules": { "keyword-spacing": 2, "array-bracket-spacing": [2, "never"], @@ -33,7 +33,9 @@ "no-sparse-arrays": 2, "no-unreachable": 2, "use-isnan": 2, - "valid-typeof": 2 + "valid-typeof": 2, + "require-await": "error", + "no-only-tests/no-only-tests": "error" }, "extends": [ "eslint:recommended", diff --git a/package.json b/package.json index e1ef9f4b..cd2c541c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.1.2", + "version": "3.1.3", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", @@ -32,6 +32,7 @@ "@typescript-eslint/parser": "^5.7.0", "eslint": "^8.2.0", "eslint-config-prettier": "^8.3.0", + "eslint-plugin-no-only-tests": "^2.6.0", "merge2": "^1.4.1", "mocha": "^9.2.0", "nock": "^13.0.11", diff --git a/yarn.lock b/yarn.lock index 7ede0102..86f1ba69 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1295,6 +1295,13 @@ __metadata: languageName: node linkType: hard +"eslint-plugin-no-only-tests@npm:^2.6.0": + version: 2.6.0 + resolution: "eslint-plugin-no-only-tests@npm:2.6.0" + checksum: 4e3c9cc7e09c13e855fd7af4a8969128f766dcf32a0680715ebcaa903c7fe44db8e45e994c8b908443a6019cbd9ea1b51f413bf968a0c58214aded930a863df9 + languageName: node + linkType: hard + "eslint-scope@npm:^5.1.1": version: 5.1.1 resolution: "eslint-scope@npm:5.1.1" @@ -1922,6 +1929,7 @@ __metadata: axios: ^0.24.0 eslint: ^8.2.0 eslint-config-prettier: ^8.3.0 + eslint-plugin-no-only-tests: ^2.6.0 htmlencode: ^0.0.4 lodash: ^4.17.21 merge2: ^1.4.1 From 7c8ba90832960232d18f5394b7f96b86c16ee314 Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 16:43:04 +0200 Subject: [PATCH 063/146] Add ESLint rule - no unused vars --- .eslintrc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.eslintrc b/.eslintrc index 74f843d4..3b782aa6 100644 --- a/.eslintrc +++ b/.eslintrc @@ -35,7 +35,8 @@ "use-isnan": 2, "valid-typeof": 2, "require-await": "error", - "no-only-tests/no-only-tests": "error" + "no-only-tests/no-only-tests": "error", + "no-unused-vars": "error" }, "extends": [ "eslint:recommended", From c9fc5bfb43e9fee864639cbd60df40d193c3af56 Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 16:44:46 +0200 Subject: [PATCH 064/146] Remove no-unused-vars rule --- .eslintrc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.eslintrc b/.eslintrc index 3b782aa6..74f843d4 100644 --- a/.eslintrc +++ b/.eslintrc @@ -35,8 +35,7 @@ "use-isnan": 2, "valid-typeof": 2, "require-await": "error", - "no-only-tests/no-only-tests": "error", - "no-unused-vars": "error" + "no-only-tests/no-only-tests": "error" }, "extends": [ "eslint:recommended", From b628c9c90113517cba6d008bd797fcfdcf45eb1b Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 16:49:03 +0200 Subject: [PATCH 065/146] Fix wrong type for Conversation list; Ignore no await in scroll --- lib/conversation.ts | 5 +++-- lib/scroll.ts | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/conversation.ts b/lib/conversation.ts index e9853568..03ee9c0c 100644 --- a/lib/conversation.ts +++ b/lib/conversation.ts @@ -1,6 +1,5 @@ import Client from './client'; import { - Paginated, StringifiedTimestamp, GenericSearchFilters, Order, @@ -525,7 +524,9 @@ interface ListConversationData { perPage?: number; } -type ListConversationResponse = Paginated; +type ListConversationResponse = PaginatedBase & { + conversations: ConversationObjectWithoutParts[]; +}; // export enum RedactConversationPartType { CONVERSATION_PART = 'conversation_part', diff --git a/lib/scroll.ts b/lib/scroll.ts index 0657f0c4..8aff02b5 100644 --- a/lib/scroll.ts +++ b/lib/scroll.ts @@ -10,6 +10,7 @@ export default class Scroll { this.scrollParam = scrollParam; } + // eslint-disable-next-line require-await async each(params: EachData): Promise { this.scrollParam = params.scrollParam ?? undefined; From 29c4dda8d42ecb451f8522f3745bd1b26bafe1c3 Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 17:37:32 +0200 Subject: [PATCH 066/146] Make QA config workspace independent --- test/integration/admins.test.ts | 13 +++++--- test/integration/articles.test.ts | 22 ++++++++----- test/integration/companies.test.ts | 12 ++++++- test/integration/conversations.test.ts | 10 ++++-- test/integration/events.test.ts | 33 ++++++++++++++++++-- test/integration/helpCenter/sections.test.ts | 13 ++++++-- test/integration/integration.test.ts | 18 +++++++++-- test/integration/notes.test.ts | 14 ++++++++- test/integration/segments.test.ts | 14 ++++++--- test/integration/tags.test.ts | 30 +++++++++++++----- test/integration/teams.test.ts | 14 ++++++--- test/integration/utils/config.ts | 10 ------ 12 files changed, 152 insertions(+), 51 deletions(-) diff --git a/test/integration/admins.test.ts b/test/integration/admins.test.ts index f5669c78..96ecfaf9 100644 --- a/test/integration/admins.test.ts +++ b/test/integration/admins.test.ts @@ -1,17 +1,20 @@ -import { adminId, token } from './utils/config'; +import { token } from './utils/config'; import { Client } from '../../dist'; import assert from 'assert'; describe('Admins', () => { + let adminId: string; const client = new Client({ tokenAuth: { token } }); - it('find', async () => { - const response = await client.admins.find({ id: adminId }); + it('list', async () => { + const response = await client.admins.list(); + + adminId = response.admins[0].id; assert.notEqual(response, undefined); }); - it('list', async () => { - const response = await client.admins.list(); + it('find', async () => { + const response = await client.admins.find({ id: adminId }); assert.notEqual(response, undefined); }); diff --git a/test/integration/articles.test.ts b/test/integration/articles.test.ts index ab8d172e..11730e76 100644 --- a/test/integration/articles.test.ts +++ b/test/integration/articles.test.ts @@ -1,16 +1,22 @@ import { Client } from '../../dist'; import assert from 'assert'; -import { - adminId as adminIdString, - token, - parentId as parentIdString, -} from './utils/config'; +import { token } from './utils/config'; import { randomString } from './utils/random'; describe('Articles', () => { - let newArticleId = '0'; - const adminId = parseInt(adminIdString, 10); - const parentId = parseInt(parentIdString, 10); + let newArticleId: string; + let parentId: number; + let adminId: number; + + before(async () => { + const randomCollections = await client.helpCenter.collections.list({ + perPage: 1, + }); + const randomAdmins = await client.admins.list(); + + parentId = parseInt(randomCollections.data[0].id, 10); + adminId = parseInt(randomAdmins.admins[0].id, 10); + }); const client = new Client({ tokenAuth: { token } }); diff --git a/test/integration/companies.test.ts b/test/integration/companies.test.ts index b564a293..445b1cdc 100644 --- a/test/integration/companies.test.ts +++ b/test/integration/companies.test.ts @@ -1,10 +1,20 @@ import { Client, CompanyObject, Order } from '../../dist'; import assert from 'assert'; -import { contactId, token } from './utils/config'; +import { token } from './utils/config'; import { dateToUnixTimestamp } from '../../lib/util/time'; describe('Companies', () => { let createdCompany: CompanyObject; + let contactId: string; + + before(async () => { + const randomContacts = await client.contacts.list({ + perPage: 1, + }); + + contactId = randomContacts.data[0].id; + }); + const client = new Client({ tokenAuth: { token } }); it('create', async () => { diff --git a/test/integration/conversations.test.ts b/test/integration/conversations.test.ts index 71428f78..d5cdb05a 100644 --- a/test/integration/conversations.test.ts +++ b/test/integration/conversations.test.ts @@ -9,7 +9,7 @@ import { MessageObject, } from '../../dist'; import assert from 'assert'; -import { token, adminId } from './utils/config'; +import { token } from './utils/config'; import { randomString } from './utils/random'; describe('Conversations', () => { @@ -18,11 +18,17 @@ describe('Conversations', () => { let createdConversation: MessageObject; let foundConversation: ConversationObject; - const anotherAdminId = '4868'; + let adminId: string; + let anotherAdminId: string; const client = new Client({ tokenAuth: { token } }); before(async () => { + const admins = await client.admins.list(); + + adminId = admins.admins[0].id; + anotherAdminId = admins.admins[1].id; + user = await client.contacts.createUser({ externalId: randomString(), name: 'Baba Booey', diff --git a/test/integration/events.test.ts b/test/integration/events.test.ts index e230b09b..c60bbf39 100644 --- a/test/integration/events.test.ts +++ b/test/integration/events.test.ts @@ -1,9 +1,38 @@ -import { Client } from '../../dist'; +import { Client, Operators, Role } from '../../dist'; import { dateToUnixTimestamp } from '../../dist/util/time'; import assert from 'assert'; -import { token, userId } from './utils/config'; +import { token } from './utils/config'; describe('Events', () => { + let userId: string; + + before(async () => { + const randomUsers = await client.contacts.search({ + data: { + query: { + operator: Operators.AND, + value: [ + { + field: 'role', + operator: Operators.EQUALS, + value: Role.USER, + }, + { + field: 'external_id', + operator: Operators.NOT_EQUALS, + value: null, + }, + ], + }, + pagination: { + per_page: 1, + }, + }, + }); + + userId = randomUsers.data[0].external_id; + }); + const client = new Client({ tokenAuth: { token } }); it('create', async () => { diff --git a/test/integration/helpCenter/sections.test.ts b/test/integration/helpCenter/sections.test.ts index d02b075e..6fdc2acb 100644 --- a/test/integration/helpCenter/sections.test.ts +++ b/test/integration/helpCenter/sections.test.ts @@ -1,10 +1,19 @@ import { Client, SectionObject } from '../../../dist'; import assert from 'assert'; -import { parentId, token } from '../utils/config'; +import { token } from '../utils/config'; import { randomString } from '../utils/random'; -describe('Collections', () => { +describe('Sections', () => { let section: SectionObject; + let parentId: string; + + before(async () => { + const randomCollections = await client.helpCenter.collections.list({ + perPage: 1, + }); + + parentId = randomCollections.data[0].id; + }); const client = new Client({ tokenAuth: { token } }); diff --git a/test/integration/integration.test.ts b/test/integration/integration.test.ts index bb952956..7b6f1b98 100644 --- a/test/integration/integration.test.ts +++ b/test/integration/integration.test.ts @@ -1,13 +1,25 @@ import { Client, ContactObject, MessageObject } from '../../dist'; import assert from 'assert'; -import { adminId, companyId, token } from './utils/config'; +import { token } from './utils/config'; import { randomInt } from 'crypto'; describe('Integration between Contact, Conversation, Company and Tag APIs', () => { - let user: ContactObject; - let lead: ContactObject; + let adminId: string; let contact: ContactObject; let conversation: MessageObject; + let companyId: string; + let lead: ContactObject; + let user: ContactObject; + + before(async () => { + const randomCompanies = await client.companies.list({ + perPage: 1, + }); + const admins = await client.admins.list(); + + adminId = admins.admins[0].id; + companyId = randomCompanies.data[0].id; + }); const client = new Client({ tokenAuth: { token } }); diff --git a/test/integration/notes.test.ts b/test/integration/notes.test.ts index 1c578e7a..d681ad93 100644 --- a/test/integration/notes.test.ts +++ b/test/integration/notes.test.ts @@ -1,11 +1,23 @@ import { Client, NoteObject } from '../../dist'; import assert from 'assert'; -import { adminId, contactId, token } from './utils/config'; +import { token } from './utils/config'; import { randomString } from './utils/random'; describe('Notes', () => { + let adminId: string; + let contactId: string; let note: NoteObject; + before(async () => { + const randomContacts = await client.contacts.list({ + perPage: 1, + }); + const admins = await client.admins.list(); + + adminId = admins.admins[0].id; + contactId = randomContacts.data[0].id; + }); + const client = new Client({ tokenAuth: { token } }); it('create', async () => { diff --git a/test/integration/segments.test.ts b/test/integration/segments.test.ts index 64aeef4b..1869edb9 100644 --- a/test/integration/segments.test.ts +++ b/test/integration/segments.test.ts @@ -1,17 +1,21 @@ import { Client } from '../../dist'; import assert from 'assert'; -import { segmentId, token } from './utils/config'; +import { token } from './utils/config'; describe('Segments', () => { + let segmentId: string; + const client = new Client({ tokenAuth: { token } }); - it('find', async () => { - const response = await client.segments.find({ id: segmentId }); + it('list', async () => { + const response = await client.segments.list({ includeCount: true }); + + segmentId = response.segments[0].id; assert.notEqual(response, undefined); }); - it('list', async () => { - const response = await client.segments.list({ includeCount: true }); + it('find', async () => { + const response = await client.segments.find({ id: segmentId }); assert.notEqual(response, undefined); }); diff --git a/test/integration/tags.test.ts b/test/integration/tags.test.ts index f276abfc..31314935 100644 --- a/test/integration/tags.test.ts +++ b/test/integration/tags.test.ts @@ -1,16 +1,32 @@ import { Client, TagObject } from '../../dist'; import assert from 'assert'; -import { - token, - adminId, - contactId, - conversationId, - companyId, -} from './utils/config'; +import { token } from './utils/config'; describe('Tags', () => { + let adminId: string; + let conversationId: string; + let companyId: string; + let contactId: string; let tag: TagObject; + before(async () => { + const randomAdmins = await client.admins.list(); + const randomConversations = await client.conversations.list({ + perPage: 1, + }); + const randomCompanies = await client.companies.list({ + perPage: 1, + }); + const randomContacts = await client.contacts.list({ + perPage: 1, + }); + + adminId = randomAdmins.admins[0].id; + conversationId = randomConversations.conversations[0].id; + companyId = randomCompanies.data[0].id; + contactId = randomContacts.data[0].id; + }); + const client = new Client({ tokenAuth: { token } }); it('create', async () => { diff --git a/test/integration/teams.test.ts b/test/integration/teams.test.ts index f8c0710c..5fffa617 100644 --- a/test/integration/teams.test.ts +++ b/test/integration/teams.test.ts @@ -1,17 +1,21 @@ import { Client } from '../../dist'; import assert from 'assert'; -import { teamId, token } from './utils/config'; +import { token } from './utils/config'; describe('Teams', () => { + let teamId: string; + const client = new Client({ tokenAuth: { token } }); - it('find', async () => { - const response = client.teams.find({ id: teamId }); + it('list', async () => { + const response = await client.teams.list(); + + teamId = response.teams[0].id; assert.notEqual(response, undefined); }); - it('list', async () => { - const response = client.teams.list(); + it('find', async () => { + const response = await client.teams.find({ id: teamId }); assert.notEqual(response, undefined); }); diff --git a/test/integration/utils/config.ts b/test/integration/utils/config.ts index 47fa3307..24850846 100644 --- a/test/integration/utils/config.ts +++ b/test/integration/utils/config.ts @@ -5,13 +5,3 @@ if (!apiToken) { } export const token = apiToken; - -export const adminId = '318887'; -export const contactId = '618d3ff1daf39156d7c017b3'; -export const userId = 'f4ca124298'; -export const companyId = '6197d0070d0f186b6ff0db28'; -export const conversationId = '8179903837'; -export const teamId = '971209'; -export const segmentId = '5887658cc813e66156622510'; -export const dataAttributeId = '8774749'; -export const parentId = '3173119'; From 95c55caa4c42447e4a3ca15620a63de0110b5634 Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 17:41:13 +0200 Subject: [PATCH 067/146] Add integration tests job Add integration tests job --- .circleci/config.yml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index e0b8dfca..8e1ffa39 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -25,6 +25,16 @@ jobs: - restore_cache: key: dependency-cache-{{ checksum "yarn.lock" }} - run: yarn test:unit + integration_test: + docker: + - image: circleci/node:14-browsers + working_directory: ~/intercom-node + steps: + - checkout + - restore_cache: + key: dependency-cache-{{ checksum "yarn.lock" }} + - export $API_TOKEN + - run: yarn test:integration workflows: version: 2 @@ -34,6 +44,11 @@ workflows: - unit_test: requires: - build + - integration_test_approval: + type: approval + - integration_test: + requires: + - integration_test_approval notify: webhooks: From e378f7ef1244015de794246ecf6e90c9ee896fef Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 17:51:41 +0200 Subject: [PATCH 068/146] Fix pipeline --- .circleci/config.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 8e1ffa39..fa7b1694 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -33,7 +33,7 @@ jobs: - checkout - restore_cache: key: dependency-cache-{{ checksum "yarn.lock" }} - - export $API_TOKEN + - run: export $API_TOKEN - run: yarn test:integration workflows: @@ -45,6 +45,8 @@ workflows: requires: - build - integration_test_approval: + requires: + - build type: approval - integration_test: requires: From a8f99e14104379e5c94acad88f5f4d21878b8cd6 Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 17:57:29 +0200 Subject: [PATCH 069/146] Fix pipeline Fix pipeline Fix pipeline Fix pipeline Fix pipeline Fix pipeline Fix pipeline Fix pipeline Fix pipeline Fix pipeline --- .circleci/config.yml | 14 ++++++++++++-- test/integration/utils/config.ts | 8 +------- 2 files changed, 13 insertions(+), 9 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index fa7b1694..1b3638ac 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -15,7 +15,13 @@ jobs: key: dependency-cache-{{ checksum "yarn.lock" }} paths: - node_modules + - restore_cache: + key: dist-cache-{{ .Environment.CIRCLE_SHA1 }} - run: yarn prepublish + - save_cache: + key: dist-cache-{{ .Environment.CIRCLE_SHA1 }} + paths: + - dist unit_test: docker: - image: circleci/node:14-browsers @@ -29,11 +35,15 @@ jobs: docker: - image: circleci/node:14-browsers working_directory: ~/intercom-node + environment: + API_TOKEN: $API_TOKEN steps: - checkout - restore_cache: key: dependency-cache-{{ checksum "yarn.lock" }} - - run: export $API_TOKEN + - restore_cache: + key: dist-cache-{{ .Environment.CIRCLE_SHA1 }} + # - run: export $API_TOKEN - run: yarn test:integration workflows: @@ -46,7 +56,7 @@ workflows: - build - integration_test_approval: requires: - - build + - unit_test type: approval - integration_test: requires: diff --git a/test/integration/utils/config.ts b/test/integration/utils/config.ts index 24850846..f75a218a 100644 --- a/test/integration/utils/config.ts +++ b/test/integration/utils/config.ts @@ -1,7 +1 @@ -const apiToken = process.env.API_TOKEN; - -if (!apiToken) { - throw new Error('API_TOKEN is required in env to run integration tests!'); -} - -export const token = apiToken; +export const token = process.env.API_TOKEN; From 2feb2aa31091042a8630716c04f2f8d07fc5c238 Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 19:19:15 +0200 Subject: [PATCH 070/146] Add Visitors QA Add Visitors QA --- test/integration/utils/config.ts | 2 +- test/integration/visitors.test.ts | 139 +++++++++++------------------- 2 files changed, 53 insertions(+), 88 deletions(-) diff --git a/test/integration/utils/config.ts b/test/integration/utils/config.ts index f75a218a..ecd6093b 100644 --- a/test/integration/utils/config.ts +++ b/test/integration/utils/config.ts @@ -1 +1 @@ -export const token = process.env.API_TOKEN; +export const token = process.env.API_TOKEN as string; diff --git a/test/integration/visitors.test.ts b/test/integration/visitors.test.ts index c1c90e71..edeb9a77 100644 --- a/test/integration/visitors.test.ts +++ b/test/integration/visitors.test.ts @@ -1,87 +1,52 @@ -// import { logWithBreaks } from './utils/config'; -// import { Client } from 'intercom-client'; - -// // TIP: get client_matches > user_id field from ping request here: https://app.intercom.io/client/test/ecahpwf5 - -// const visitorForDelete = { -// visitorId: '6202ae4c4caf6a35860f843c', // those has to be updated every time before running QA script -// userId: '0a5c7c01-db82-4794-96ef-ab26c855a88f', // those has to be updated every time before running QA script -// }; - -// const visitorForConvertingToContact = { -// visitorId: '6202ae94928cb83fbca343f1', // those has to be updated every time before running QA script -// }; - -// const testVisitors = async (client: Client) => { -// const actions = actionsWithData( -// client, -// data( -// visitorForDelete.visitorId, -// visitorForDelete.userId, -// visitorForConvertingToContact.visitorId -// ) -// ); - -// for (const action of actions) { -// try { -// const response = await action.promise; -// logWithBreaks(response, action.name); -// } catch (e) { -// logWithBreaks(e, action.name); -// throw e; -// } -// } -// }; - -// const data = ( -// idForDelete: string, -// userIdForDelete: string, -// idForConvertingToContact: string -// ) => ({ -// findById: { id: idForDelete }, -// findByUserId: { userId: userIdForDelete }, -// update: { -// userId: userIdForDelete, -// name: 'Winston Smith', -// custom_attributes: {}, -// }, -// delete: { -// id: idForDelete, -// }, -// mergeToContact: { -// visitor: { -// id: idForConvertingToContact, -// }, -// user: { -// email: 'mcboxford@intercom-test.com', -// }, -// type: 'user', -// }, -// }); - -// const actionsWithData = (client: Client, data: any) => [ -// { promise: client.visitors.find(data.findById), name: 'find by id' }, -// { -// promise: client.visitors.find(data.findByUserId), -// name: 'find by user id', -// }, -// { promise: client.visitors.update(data.update), name: 'update' }, -// { promise: client.visitors.delete(data.delete), name: 'delete' }, -// { -// promise: client.visitors.mergeToContact(data.mergeToContact), -// name: 'merge to contaact', -// }, -// ]; - -// (async () => { -// const token = - -// const client = new Client({ tokenAuth: { token } }); - -// try { -// await testVisitors(client); -// } catch (e) { -// console.dir(e, { depth: null }); -// return; -// } -// })(); +import { Client, Role } from '../../dist'; +import assert from 'assert'; +import { token } from './utils/config'; + +// Skip by default, because there is no automation yet +describe.skip('Visitors', () => { + // Info: should be set manually. Find a way to automate it. + // Tip: headless browser to visit test application and get visitorId from ping request. + const visitorId = '0'; + const userId = '0'; + + const client = new Client({ tokenAuth: { token } }); + + it('find by id', async () => { + const response = await client.visitors.find({ id: visitorId }); + + assert.notEqual(response, undefined); + }); + it('find by user id', async () => { + const response = await client.visitors.find({ userId }); + + assert.notEqual(response, undefined); + }); + it('update', async () => { + const response = await client.visitors.update({ + userId, + name: 'Winston Smith', + }); + + assert.notEqual(response, undefined); + }); + it('delete', async () => { + const response = await client.visitors.delete({ + id: visitorId, + }); + + assert.notEqual(response, undefined); + }); + it('mergeToContact', async () => { + const response = await client.visitors.mergeToContact({ + visitor: { + id: visitorId, + }, + user: { + email: 'mcboxford@intercom-test.com', + } as any, + type: Role.USER, + }); + + assert.notEqual(response, undefined); + }); +}); From ffb9cf03dd927b0456db10925f797080a1ad8b4d Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 19:22:51 +0200 Subject: [PATCH 071/146] Fix pipeline Fix pipeline Fix pipeline Fix pipeline Fix pipeline Fix pipeline Fix pipeline Fix pipeline Fix pipeline Fix pipeline Fix pipeline Fix pipeline Remove unneded step from CI --- .circleci/config.yml | 7 ++++--- test/integration/admins.test.ts | 4 +++- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 1b3638ac..0c87ea15 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -15,6 +15,7 @@ jobs: key: dependency-cache-{{ checksum "yarn.lock" }} paths: - node_modules + - .yarn/cache - restore_cache: key: dist-cache-{{ .Environment.CIRCLE_SHA1 }} - run: yarn prepublish @@ -34,16 +35,16 @@ jobs: integration_test: docker: - image: circleci/node:14-browsers + environment: + API_TOKEN: $API_TOKEN working_directory: ~/intercom-node - environment: - API_TOKEN: $API_TOKEN + steps: - checkout - restore_cache: key: dependency-cache-{{ checksum "yarn.lock" }} - restore_cache: key: dist-cache-{{ .Environment.CIRCLE_SHA1 }} - # - run: export $API_TOKEN - run: yarn test:integration workflows: diff --git a/test/integration/admins.test.ts b/test/integration/admins.test.ts index 96ecfaf9..e8d55c06 100644 --- a/test/integration/admins.test.ts +++ b/test/integration/admins.test.ts @@ -4,7 +4,9 @@ import assert from 'assert'; describe('Admins', () => { let adminId: string; - const client = new Client({ tokenAuth: { token } }); + const client = new Client({ + tokenAuth: { token }, + }); it('list', async () => { const response = await client.admins.list(); From ad6fc931f5e1aeb31599339e46c4875efea52116 Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 20:00:33 +0200 Subject: [PATCH 072/146] Add skipped tests --- test/integration/companies.test.ts | 12 ++++++------ test/integration/conversations.test.ts | 16 ++++++++-------- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/test/integration/companies.test.ts b/test/integration/companies.test.ts index 445b1cdc..403e62f1 100644 --- a/test/integration/companies.test.ts +++ b/test/integration/companies.test.ts @@ -57,13 +57,13 @@ describe('Companies', () => { assert.notEqual(response, undefined); }); // TO-DO: Create issue on API. Doesn't work on API.. - // it('find - by name', async () => { - // const response = await client.companies.find({ - // name: 'BestCompanyInc', - // }); + it.skip('find - by name', async () => { + const response = await client.companies.find({ + name: 'BestCompanyInc', + }); - // assert.notEqual(response, undefined); - // }); + assert.notEqual(response, undefined); + }); it('list', async () => { const response = await client.companies.list({ page: 1, diff --git a/test/integration/conversations.test.ts b/test/integration/conversations.test.ts index d5cdb05a..5e69c8ae 100644 --- a/test/integration/conversations.test.ts +++ b/test/integration/conversations.test.ts @@ -69,14 +69,14 @@ describe('Conversations', () => { assert.notEqual(response, undefined); }); // TO-DO: Fix on API side. - // it('replyToLastConversationAsAdmin', async () => { - // const response = await client.conversations.replyByLastAsAdmin({ - // adminId, - // messageType: ReplyToConversationMessageType.COMMENT, - // body: 'test', - // }); - // assert.notEqual(response, undefined); - // }); + it.skip('replyToLastConversationAsAdmin', async () => { + const response = await client.conversations.replyByLastAsAdmin({ + adminId, + messageType: ReplyToConversationMessageType.COMMENT, + body: 'test', + }); + assert.notEqual(response, undefined); + }); it('replyByIdAsAdmin', async () => { const response = await client.conversations.replyByIdAsAdmin({ id: foundConversation.id, From 6464cbed4ee49053e1a238ace3047110a0df7b7b Mon Sep 17 00:00:00 2001 From: Volo Date: Fri, 11 Feb 2022 20:36:20 +0200 Subject: [PATCH 073/146] Bump package version --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index cd2c541c..ff798949 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.1.3", + "version": "3.1.4", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", From e66e530f742b1b9ba873ec147c355adb5c238587 Mon Sep 17 00:00:00 2001 From: Enrico Marugliano Date: Thu, 17 Feb 2022 12:44:08 +0000 Subject: [PATCH 074/146] Add FOSSA workflow to enable license scanning --- .github/workflows/fossa-license-scan.yml | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 .github/workflows/fossa-license-scan.yml diff --git a/.github/workflows/fossa-license-scan.yml b/.github/workflows/fossa-license-scan.yml new file mode 100644 index 00000000..310a9a71 --- /dev/null +++ b/.github/workflows/fossa-license-scan.yml @@ -0,0 +1,24 @@ +# More information on this workflow can be found here: https://stackoverflow.com/c/intercom/questions/1270 + +name: FOSSA License Scan + +on: + push: + branches: + - master + +jobs: + fossa: + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v2 + - name: Attempt build + uses: intercom/attempt-build-action@main + continue-on-error: true + - name: Run FOSSA + uses: intercom/fossa-action@main + with: + fossa-api-key: ${{ secrets.FOSSA_API_KEY }} + fossa-event-receiver-token: ${{ secrets.FOSSA_EVENT_RECEIVER_TOKEN }} + datadog-api-key: ${{ secrets.DATADOG_API_KEY }} From 2e3fa9bea9e6921568bb441c1c1d77348973c4c2 Mon Sep 17 00:00:00 2001 From: MangeFre <32870254+MangeFre@users.noreply.github.com> Date: Tue, 24 May 2022 04:10:27 -0500 Subject: [PATCH 075/146] Create conversation without contact reply (#319) * Added "create_conversation_without_admin_reply" to messages.create * Made createConversation ... optional * Add integration test * Documentation updated to reflect addition * Message can be created without conversation + clean up --- README.md | 18 +++++++ lib/message.ts | 11 +++- test/integration/messages.test.ts | 85 +++++++++++++++++++++++++++++++ 3 files changed, 113 insertions(+), 1 deletion(-) create mode 100644 test/integration/messages.test.ts diff --git a/README.md b/README.md index dc6273f1..47b31934 100644 --- a/README.md +++ b/README.md @@ -1013,6 +1013,24 @@ const response = await client.messages.create({ }); ``` +#### [Create conversation without contact reply](https://developers.intercom.com/intercom-api-reference/reference/admin-initiated-conversation) + +```typescript +const response = await client.messages.create({ + messageType: 'inapp', + body: 'Look at me, I am a conversation now', + from: { + type: 'admin', + id: '394051', + }, + to: { + type: 'user', + id: '536e564f316c83104c000020', + }, + createConversationWithoutContactReply: true, +}); +``` + ### Notes #### [Create a note](https://developers.intercom.com/intercom-api-reference/reference/create-note-for-contact) diff --git a/lib/message.ts b/lib/message.ts index 550e43b7..096850d5 100644 --- a/lib/message.ts +++ b/lib/message.ts @@ -15,6 +15,8 @@ export default class Message { template, from, to, + createConversationWithoutContactReply: + create_conversation_without_contact_reply, }: CreateMessageBody) { const data: CreateMessageRequest = { message_type, @@ -23,6 +25,7 @@ export default class Message { template, from, to, + create_conversation_without_contact_reply, }; return this.client.post({ @@ -39,10 +42,16 @@ interface CreateMessageRequest { to: Recepient; subject?: string; template?: string; + create_conversation_without_contact_reply?: boolean; } -interface CreateMessageBody extends Omit { +interface CreateMessageBody + extends Omit< + CreateMessageRequest, + 'message_type' | 'create_conversation_without_contact_reply' + > { messageType: MessageType; + createConversationWithoutContactReply?: boolean; } type Recepient = { diff --git a/test/integration/messages.test.ts b/test/integration/messages.test.ts new file mode 100644 index 00000000..61db456f --- /dev/null +++ b/test/integration/messages.test.ts @@ -0,0 +1,85 @@ +import { token } from './utils/config'; +import { Client, Operators } from '../../dist'; +import { randomString } from './utils/random'; +import { MessageType } from '../../lib/message/message.types'; +import { RecepientType } from '../../lib/message'; +import assert from 'assert'; + +describe('Messages', () => { + let adminId: string; + let userIntercomId: string; + const client = new Client({ + tokenAuth: { token }, + }); + + before(async () => { + const adminList = await client.admins.list(); + adminId = adminList.admins[0].id; + + const createdUser = await client.contacts.createUser({ + externalId: randomString(), + name: 'Message Test User', + }); + userIntercomId = createdUser.id; + }); + + it('Message that creates a converation', async () => { + const requestBody = { + message_type: MessageType.INAPP, + body: 'Hey, look at me! I am the conversations creator now!', + from: { + type: RecepientType.ADMIN, + id: adminId, + }, + to: { + type: RecepientType.USER, + id: userIntercomId, + }, + }; + const response = await client.messages.create({ + messageType: requestBody.message_type, + body: requestBody.body, + from: requestBody.from, + to: requestBody.to, + createConversationWithoutContactReply: true, + }); + + const messageId = response.id; + + // Give Intercom a few seconds to index conversation + await new Promise((resolve) => setTimeout(resolve, 5000)); + + const searchResults = await client.conversations.search({ + data: { + query: { + field: 'source.id', + operator: Operators.EQUALS, + value: messageId, + }, + }, + }); + assert.equal(searchResults.total_count > 0, true); + }); + + it('Create message, no conversation', async () => { + const requestBody = { + message_type: MessageType.INAPP, + body: 'Message without creating conversation', + from: { + type: RecepientType.ADMIN, + id: adminId, + }, + to: { + type: RecepientType.USER, + id: userIntercomId, + }, + }; + const response = await client.messages.create({ + messageType: requestBody.message_type, + body: requestBody.body, + from: requestBody.from, + to: requestBody.to, + }); + assert.notEqual(response, undefined); + }); +}); From 74bd5f3847264f6f38b9002c956772c43463055d Mon Sep 17 00:00:00 2001 From: Drew Watkins <1772482+drewwatkins11@users.noreply.github.com> Date: Tue, 24 May 2022 05:43:15 -0400 Subject: [PATCH 076/146] Permit creating leads with email (#316) * Allow adding leads with email - Create interface CreateLeadData * Add test for creating lead with email address * rm email from CreateUserData & CreateLeadData Co-authored-by: Johnny Nader <30523158+johnnynader@users.noreply.github.com> Co-authored-by: Johnny Nader --- lib/contact.ts | 8 +++++--- test/unit/contact.test.ts | 23 +++++++++++++++++++++++ 2 files changed, 28 insertions(+), 3 deletions(-) diff --git a/lib/contact.ts b/lib/contact.ts index 00480a2e..73b87a9b 100644 --- a/lib/contact.ts +++ b/lib/contact.ts @@ -52,6 +52,7 @@ export default class Contact { const requestData: CreateContactRequest = { role: Role.LEAD, phone: data?.phone, + email: data?.email, name: data?.name, avatar: data?.avatar, signed_up_at: data?.signedUpAt, @@ -190,6 +191,7 @@ type CreateContactRequest = Pick & interface CreateUserDataBase { phone?: CreateContactRequest['phone']; name?: CreateContactRequest['name']; + email?: CreateContactRequest['email']; avatar?: CreateContactRequest['avatar']; signedUpAt?: CreateContactRequest['signed_up_at']; lastSeenAt?: CreateContactRequest['last_seen_at']; @@ -199,11 +201,11 @@ interface CreateUserDataBase { } interface CreateUserData extends CreateUserDataBase { - email?: string; externalId?: string; } type CreateLeadData = CreateUserDataBase; + // interface RetrieveContactData { id: string; @@ -290,8 +292,8 @@ interface SearchContactOrder { interface SearchContactRequest { data: GenericSearchFilters & - Partial & - Partial; + Partial & + Partial; } type SearchContactResponse = Paginated; diff --git a/test/unit/contact.test.ts b/test/unit/contact.test.ts index d31105df..6abe4543 100644 --- a/test/unit/contact.test.ts +++ b/test/unit/contact.test.ts @@ -101,6 +101,29 @@ describe('contacts', () => { assert.deepStrictEqual(expectedReply, response); }); + it('should create a contact with lead role with email', async () => { + const contact = { + role: 'lead', + email: 'niko_bellic@mail.com', + }; + + const expectedReply = {}; + + nock('https://api.intercom.io') + .post('/contacts', contact) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.contacts.createLead({ + email: contact.email, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + it('should retrieve a contact by id', async () => { const id = '536e564f316c83104c000020'; From 771d0bec465d9b8f22f66e97901c66ea94954ea5 Mon Sep 17 00:00:00 2001 From: Johnny Nader <30523158+johnnynader@users.noreply.github.com> Date: Thu, 26 May 2022 12:13:22 +0100 Subject: [PATCH 077/146] add email to contact update (#323) --- lib/contact.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/contact.ts b/lib/contact.ts index 73b87a9b..e4bf16b4 100644 --- a/lib/contact.ts +++ b/lib/contact.ts @@ -75,6 +75,7 @@ export default class Contact { id, role, externalId, + email, phone, name, avatar, @@ -87,6 +88,7 @@ export default class Contact { const data: UpdateContactRequest = { role, external_id: externalId, + email, phone, name, avatar, @@ -232,6 +234,7 @@ type UpdateContactData = { id: string; role?: UpdateContactRequest['role']; externalId?: UpdateContactRequest['external_id']; + email?: UpdateContactRequest['email']; phone?: UpdateContactRequest['phone']; name?: UpdateContactRequest['name']; avatar?: UpdateContactRequest['avatar']; From 9ef9ff36e3dd2586a248e99bb2dd4b9a5fe39362 Mon Sep 17 00:00:00 2001 From: Johnny Nader <30523158+johnnynader@users.noreply.github.com> Date: Thu, 26 May 2022 12:18:42 +0100 Subject: [PATCH 078/146] 3.1.5 (#324) --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index ff798949..02062b5c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.1.4", + "version": "3.1.5", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", From e1d2b13c67bf0478d9d89f4bfe598676070be295 Mon Sep 17 00:00:00 2001 From: aghArdeshir Date: Wed, 8 Jun 2022 16:07:06 +0400 Subject: [PATCH 079/146] Move contribution-related topics altogether to the end of README For me, as a user of `intercom-node` package, when I open README.md, the first thing I need to see, is how to install and use this package. If I ever happen to need to contribute to this package, I will probably look elsewhere; a CONTRIBUTING.md file probably. But for now, just to make it easier for other developers to follow the usage guide, I moved it to the end of README.md, next to **Pull Requests** section --- README.md | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/README.md b/README.md index 47b31934..352bad7d 100644 --- a/README.md +++ b/README.md @@ -21,19 +21,6 @@ yarn add intercom-client **This client is intended for server side use only. Please use the [Intercom Javascript SDK](https://developers.intercom.com/installing-intercom/docs/intercom-for-web) for client-side operations.** -## Testing - -```bash -yarn test -``` - -## Running the code locally - -Compile using babel: - -```bash -yarn prepublish -``` ## Usage @@ -1243,6 +1230,20 @@ IdentityVerification.userHash({ Apache-2.0 +## Testing + +```bash +yarn test +``` + +## Running the code locally + +Compile using babel: + +```bash +yarn prepublish +``` + ## Pull Requests - **Add tests!** Your patch won't be accepted if it doesn't have tests. From 0be4cf5b523f5fd573126ac43c323956de97cb42 Mon Sep 17 00:00:00 2001 From: Lukas Bals Date: Thu, 30 Jun 2022 15:04:33 +0200 Subject: [PATCH 080/146] Implement the list all subscripition types functionality --- README.md | 12 ++++++++++-- lib/client.ts | 3 +++ lib/subscription.ts | 20 ++++++++++++++++++++ test/integration/subscriptions.test.ts | 13 +++++++++++++ test/unit/subscription.test.ts | 18 ++++++++++++++++++ 5 files changed, 64 insertions(+), 2 deletions(-) create mode 100644 lib/subscription.ts create mode 100644 test/integration/subscriptions.test.ts create mode 100644 test/unit/subscription.test.ts diff --git a/README.md b/README.md index 47b31934..1f95b6b5 100644 --- a/README.md +++ b/README.md @@ -82,8 +82,8 @@ If you are using the european instance of intercom and would like to call it dir ```typescript const client = new Client({ tokenAuth: { token: 'my_token' } }); client.useRequestOpts({ - baseUrl: 'https://api.eu.intercom.io' -}) + baseUrl: 'https://api.eu.intercom.io', +}); ``` ## Examples @@ -1078,6 +1078,14 @@ const response = await client.segments.list({ }); ``` +### Subscriptions + +#### [List all subscription types](https://developers.intercom.com/intercom-api-reference/reference/list-all-subscription-types) + +```typescript +const response = await client.subscriptions.listTypes(); +``` + ### Tags #### [Create or update a tag](https://developers.intercom.com/intercom-api-reference/reference/create-and-update-tags) diff --git a/lib/client.ts b/lib/client.ts index e6a1753f..8fef6918 100644 --- a/lib/client.ts +++ b/lib/client.ts @@ -13,6 +13,7 @@ import HelpCenter from './helpCenter'; import Message from './message'; import Note from './note'; import Segment from './segment'; +import Subscription from './subscription'; import Team from './team'; import Tag from './tag'; import Visitor from './visitor'; @@ -63,6 +64,7 @@ export default class Client { messages: Message; notes: Note; segments: Segment; + subscriptions: Subscription; passwordPart?: string; propertiesToOmitInRequestOpts: string[]; requestOpts: Partial; @@ -95,6 +97,7 @@ export default class Client { this.messages = new Message(this); this.notes = new Note(this); this.segments = new Segment(this); + this.subscriptions = new Subscription(this); this.tags = new Tag(this); this.teams = new Team(this); this.visitors = new Visitor(this); diff --git a/lib/subscription.ts b/lib/subscription.ts new file mode 100644 index 00000000..012e8071 --- /dev/null +++ b/lib/subscription.ts @@ -0,0 +1,20 @@ +import { Client } from '.'; +import { SubscriptionObject } from './subscription/subscription.types'; + +export default class Subscription { + public readonly baseUrl = 'subscription_types'; + + constructor(private readonly client: Client) { + this.client = client; + } + listTypes() { + return this.client.get({ + url: `/${this.baseUrl}`, + }); + } +} + +interface ListResponse { + type: 'list'; + data: SubscriptionObject[]; +} diff --git a/test/integration/subscriptions.test.ts b/test/integration/subscriptions.test.ts new file mode 100644 index 00000000..5c57f1ff --- /dev/null +++ b/test/integration/subscriptions.test.ts @@ -0,0 +1,13 @@ +import { Client } from '../../dist'; +import assert from 'assert'; +import { token } from './utils/config'; + +describe('Subscriptions', () => { + const client = new Client({ tokenAuth: { token } }); + + it('listTypes', async () => { + const response = await client.subscriptions.listTypes(); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/unit/subscription.test.ts b/test/unit/subscription.test.ts new file mode 100644 index 00000000..5cc5ecc3 --- /dev/null +++ b/test/unit/subscription.test.ts @@ -0,0 +1,18 @@ +import assert from 'assert'; +import { Client } from '../../lib'; +import nock from 'nock'; + +describe('subscriptions', () => { + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + it('should be listed', async () => { + nock('https://api.intercom.io') + .get('/subscription_types') + .reply(200, { type: 'list', data: [] }); + const response = await client.subscriptions.listTypes(); + + assert.deepStrictEqual({ type: 'list', data: [] }, response); + }); +}); From 04573775449c7a52fdbfafa663e3af301f5a018e Mon Sep 17 00:00:00 2001 From: Sean Healy Date: Mon, 28 Nov 2022 16:35:33 +0000 Subject: [PATCH 081/146] Add switch api --- README.md | 37 +++++++++++++++- lib/client.ts | 6 +++ lib/dataExport.ts | 43 +++++++++++++++++++ lib/dataExport/dataExport.types.ts | 6 +++ lib/phoneCallRedirect.ts | 27 ++++++++++++ .../phoneCallRedirect.types.ts | 4 ++ test/integration/dataExport.test.ts | 29 +++++++++++++ test/integration/phoneCallRedirect.test.ts | 15 +++++++ 8 files changed, 165 insertions(+), 2 deletions(-) create mode 100644 lib/dataExport.ts create mode 100644 lib/dataExport/dataExport.types.ts create mode 100644 lib/phoneCallRedirect.ts create mode 100644 lib/phoneCallRedirect/phoneCallRedirect.types.ts create mode 100644 test/integration/dataExport.test.ts create mode 100644 test/integration/phoneCallRedirect.test.ts diff --git a/README.md b/README.md index 47b31934..3d6698cf 100644 --- a/README.md +++ b/README.md @@ -82,8 +82,8 @@ If you are using the european instance of intercom and would like to call it dir ```typescript const client = new Client({ tokenAuth: { token: 'my_token' } }); client.useRequestOpts({ - baseUrl: 'https://api.eu.intercom.io' -}) + baseUrl: 'https://api.eu.intercom.io', +}); ``` ## Examples @@ -845,6 +845,29 @@ const response = await client.dataAttributes.list({ }); ``` +### Data Exports + +#### [Create a export job](https://developers.intercom.com/intercom-api-reference/reference/creating-an-export-job) + +```typescript +const response = await client.dataExport.create({ + createdAtAfter: 1527811200, + createdAtBefore: 1530316800, +}); +``` + +#### [Retrieve a job status](https://developers.intercom.com/intercom-api-reference/reference/retrieve-a-job-status) + +```typescript +const response = await client.dataExport.find({id: export.id}) +``` + +#### [Cancel a job](https://developers.intercom.com/intercom-api-reference/reference/the-export-job-model) + +```typescript +const response = await client.dataExport.cancel({id: export.id}) +``` + ### Events #### [Submit a data event](https://developers.intercom.com/intercom-api-reference/reference/list-data-attributes) @@ -1078,6 +1101,16 @@ const response = await client.segments.list({ }); ``` +### PhoneCallRedirects + +#### [Create a phone call redirect](https://developers.intercom.com/intercom-api-reference/reference/create-a-phone-switch) + +```typescript +const response = await client.phoneCallRedirect.create({ + phone: '+353871234567', +}); +``` + ### Tags #### [Create or update a tag](https://developers.intercom.com/intercom-api-reference/reference/create-and-update-tags) diff --git a/lib/client.ts b/lib/client.ts index e6a1753f..851798de 100644 --- a/lib/client.ts +++ b/lib/client.ts @@ -8,6 +8,7 @@ import Contact from './contact'; import Conversation from './conversation'; import Count from './count'; import DataAttribute from './dataAttribute'; +import DataExport from './dataExport'; import Event from './event'; import HelpCenter from './helpCenter'; import Message from './message'; @@ -16,6 +17,7 @@ import Segment from './segment'; import Team from './team'; import Tag from './tag'; import Visitor from './visitor'; +import PhoneCallRedirect from './phoneCallRedirect'; import * as packageJson from '../package.json'; @@ -58,6 +60,7 @@ export default class Client { conversations: Conversation; counts: Count; dataAttributes: DataAttribute; + dataExport: DataExport; events: Event; helpCenter: HelpCenter; messages: Message; @@ -70,6 +73,7 @@ export default class Client { teams: Team; usernamePart?: string; visitors: Visitor; + phoneCallRedirect: PhoneCallRedirect; constructor(args: Constructor) { const [usernamePart, passwordPart] = Client.getAuthDetails(args); @@ -90,6 +94,7 @@ export default class Client { this.conversations = new Conversation(this); this.counts = new Count(this); this.dataAttributes = new DataAttribute(this); + this.dataExport = new DataExport(this); this.events = new Event(this); this.helpCenter = new HelpCenter(this); this.messages = new Message(this); @@ -98,6 +103,7 @@ export default class Client { this.tags = new Tag(this); this.teams = new Team(this); this.visitors = new Visitor(this); + this.phoneCallRedirect = new PhoneCallRedirect(this); this.requestOpts = { baseURL: 'https://api.intercom.io', }; diff --git a/lib/dataExport.ts b/lib/dataExport.ts new file mode 100644 index 00000000..af68f3d2 --- /dev/null +++ b/lib/dataExport.ts @@ -0,0 +1,43 @@ +import { Client } from '.'; +import { DataExportObject } from './dataExport/dataExport.types'; +import { OperationById } from './common/common.types'; + +export default class DataExport { + public readonly baseUrl = 'export'; + + constructor(private readonly client: Client) { + this.client = client; + } + + find({ id }: DataExportByIdData) { + return this.client.get({ + url: `/${this.baseUrl}/content/data/${id}`, + }); + } + + create({ createdAtBefore, createdAtAfter }: CreateDataExportData) { + const data = { + created_at_before: createdAtBefore, + created_at_after: createdAtAfter, + }; + + return this.client.post({ + url: `/${this.client.dataExport.baseUrl}/content/data/`, + data, + }); + } + + cancel({ id }: DataExportByIdData) { + return this.client.post({ + url: `/${this.baseUrl}/cancel/${id}`, + data: {}, + }); + } +} + +interface CreateDataExportData { + createdAtBefore: string; + createdAtAfter: string; +} + +type DataExportByIdData = OperationById; diff --git a/lib/dataExport/dataExport.types.ts b/lib/dataExport/dataExport.types.ts new file mode 100644 index 00000000..88a482cf --- /dev/null +++ b/lib/dataExport/dataExport.types.ts @@ -0,0 +1,6 @@ +export type DataExportObject = { + job_identifier: string; + status: string; + download_url: string; + download_expires_at: string; +}; diff --git a/lib/phoneCallRedirect.ts b/lib/phoneCallRedirect.ts new file mode 100644 index 00000000..9e546ad3 --- /dev/null +++ b/lib/phoneCallRedirect.ts @@ -0,0 +1,27 @@ +import { Client } from '.'; +import { PhoneCallRedirectObject } from './phoneCallRedirect/phoneCallRedirect.types'; +import { JavascriptObject } from './common/common.types'; + +export default class PhoneCallRedirect { + public readonly baseUrl = 'phone_call_redirects'; + + constructor(private readonly client: Client) { + this.client = client; + } + + create({ phone, customAttributes }: CreatePhoneRedirectData) { + const data = { + phone, + customAttributes, + }; + return this.client.post({ + url: `/${this.client.phoneCallRedirect.baseUrl}/`, + data, + }); + } +} + +interface CreatePhoneRedirectData { + phone: string; + customAttributes: JavascriptObject; +} diff --git a/lib/phoneCallRedirect/phoneCallRedirect.types.ts b/lib/phoneCallRedirect/phoneCallRedirect.types.ts new file mode 100644 index 00000000..45359aeb --- /dev/null +++ b/lib/phoneCallRedirect/phoneCallRedirect.types.ts @@ -0,0 +1,4 @@ +export type PhoneCallRedirectObject = { + type: 'phone_call_redirect'; + url: string; +}; diff --git a/test/integration/dataExport.test.ts b/test/integration/dataExport.test.ts new file mode 100644 index 00000000..eb29733b --- /dev/null +++ b/test/integration/dataExport.test.ts @@ -0,0 +1,29 @@ +import { Client} from '../../dist'; +import assert from 'assert'; +import { token } from './utils/config'; + +describe('dataExport', () => { + const client = new Client({ tokenAuth: { token } }); + let dataExport: string; + + it('create', async () => { + const response = await client.dataExport.create({ + phone: '+353871234567' + }); + dataExport = response.id; + + assert.notEqual(response, undefined); + }); + + it('find', async () => { + const response = await client.dataExport.find({ id: dataExport }); + + assert.notEqual(response, undefined); + }); + + it('delete', async () => { + const response = await client.dataExport.cancel({ id: dataExport }); + + assert.notEqual(response, undefined); + }); +}); diff --git a/test/integration/phoneCallRedirect.test.ts b/test/integration/phoneCallRedirect.test.ts new file mode 100644 index 00000000..f926711c --- /dev/null +++ b/test/integration/phoneCallRedirect.test.ts @@ -0,0 +1,15 @@ +import { Client} from '../../dist'; +import assert from 'assert'; +import { token } from './utils/config'; + +describe('phoneCallRedirect', () => { + const client = new Client({ tokenAuth: { token } }); + + it('create', async () => { + const response = await client.phoneCallRedirect.create({ + phone: '+353871234567' + }); + + assert.notEqual(response, undefined); + }); +}); From 2fb68b85501748c66155cafb0283c2dc31ad02cd Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Tue, 13 Dec 2022 13:27:10 +0000 Subject: [PATCH 082/146] Fix typo in Enum --- lib/conversation/conversation.types.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/conversation/conversation.types.ts b/lib/conversation/conversation.types.ts index f1c370a9..c82f2975 100644 --- a/lib/conversation/conversation.types.ts +++ b/lib/conversation/conversation.types.ts @@ -123,7 +123,7 @@ enum ConversationPriority { } enum ConversationSourceType { - CONVERASTION = 'conversation', + CONVERSATION = 'conversation', PUSH = 'push', FACEBOOK = 'facebook', TWITTER = 'twitter', From 962081493f5250cb16db12522fc15bb8db389d8c Mon Sep 17 00:00:00 2001 From: Sean Healy Date: Tue, 13 Dec 2022 14:25:59 +0000 Subject: [PATCH 083/146] Fix typescript errors --- lib/dataExport.ts | 4 ++-- lib/phoneCallRedirect.ts | 2 +- test/integration/dataExport.test.ts | 7 ++++--- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/lib/dataExport.ts b/lib/dataExport.ts index af68f3d2..bd704d48 100644 --- a/lib/dataExport.ts +++ b/lib/dataExport.ts @@ -36,8 +36,8 @@ export default class DataExport { } interface CreateDataExportData { - createdAtBefore: string; - createdAtAfter: string; + createdAtBefore: number; + createdAtAfter: number; } type DataExportByIdData = OperationById; diff --git a/lib/phoneCallRedirect.ts b/lib/phoneCallRedirect.ts index 9e546ad3..44073d6a 100644 --- a/lib/phoneCallRedirect.ts +++ b/lib/phoneCallRedirect.ts @@ -23,5 +23,5 @@ export default class PhoneCallRedirect { interface CreatePhoneRedirectData { phone: string; - customAttributes: JavascriptObject; + customAttributes?: JavascriptObject; } diff --git a/test/integration/dataExport.test.ts b/test/integration/dataExport.test.ts index eb29733b..90ce304e 100644 --- a/test/integration/dataExport.test.ts +++ b/test/integration/dataExport.test.ts @@ -1,4 +1,4 @@ -import { Client} from '../../dist'; +import { Client } from '../../dist'; import assert from 'assert'; import { token } from './utils/config'; @@ -8,9 +8,10 @@ describe('dataExport', () => { it('create', async () => { const response = await client.dataExport.create({ - phone: '+353871234567' + createdAtAfter: 1670000000, + createdAtBefore: 1670940528, }); - dataExport = response.id; + dataExport = response.job_identifier; assert.notEqual(response, undefined); }); From ae37042bc66c1e7815754bd55c5bfb8aad691805 Mon Sep 17 00:00:00 2001 From: Sean Healy Date: Wed, 14 Dec 2022 13:55:05 +0000 Subject: [PATCH 084/146] Update package to version 3.2 --- README.md | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 65761dac..cb4f7f25 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ [![Circle CI](https://circleci.com/gh/intercom/intercom-node.png?style=shield)](https://circleci.com/gh/intercom/intercom-node) [![npm](https://img.shields.io/npm/v/intercom-client)](https://www.npmjs.com/package/intercom-client) -![Intercom API Version](https://img.shields.io/badge/Intercom%20API%20Version-2.4-blue) +![Intercom API Version](https://img.shields.io/badge/Intercom%20API%20Version-2.5-blue) ![Typescript Supported](https://img.shields.io/badge/Typescript-Supported-lightgrey) > Official Node bindings to the [Intercom API](https://api.intercom.io/docs) @@ -11,7 +11,7 @@ ## Breaking changes -The Node SDK has been updated to support latest API version (2.4). The update also contains requested features, such like Typescript support. You can find more information on how-to migrate and what has changed in the [migration guide](https://github.com/intercom/intercom-node/wiki/Migration-guide). +The Node SDK has been updated to support latest API version (2.5). The update also contains requested features, such like Typescript support. You can find more information on how-to migrate and what has changed in the [migration guide](https://github.com/intercom/intercom-node/wiki/Migration-guide). ## Installation diff --git a/package.json b/package.json index 02062b5c..2b14d8d2 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.1.5", + "version": "3.2.0", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", From 20310ca4bb4eac90505f4c0f2588a0454ea695cd Mon Sep 17 00:00:00 2001 From: Sean Healy Date: Wed, 14 Dec 2022 18:32:55 +0000 Subject: [PATCH 085/146] Update to 3.2.1 due to bad npm publish --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 2b14d8d2..c0a9661e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.2.0", + "version": "3.2.1", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", From 5cacf746a438b7d66834d1d45f1546dff55c2a65 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 14 Dec 2022 18:39:36 +0000 Subject: [PATCH 086/146] Bump minimist from 1.2.5 to 1.2.7 Bumps [minimist](https://github.com/minimistjs/minimist) from 1.2.5 to 1.2.7. - [Release notes](https://github.com/minimistjs/minimist/releases) - [Changelog](https://github.com/minimistjs/minimist/blob/main/CHANGELOG.md) - [Commits](https://github.com/minimistjs/minimist/compare/v1.2.5...v1.2.7) --- updated-dependencies: - dependency-name: minimist dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 86f1ba69..6b01cb85 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2366,9 +2366,9 @@ __metadata: linkType: hard "minimist@npm:^1.2.5": - version: 1.2.5 - resolution: "minimist@npm:1.2.5" - checksum: 86706ce5b36c16bfc35c5fe3dbb01d5acdc9a22f2b6cc810b6680656a1d2c0e44a0159c9a3ba51fb072bb5c203e49e10b51dcd0eec39c481f4c42086719bae52 + version: 1.2.7 + resolution: "minimist@npm:1.2.7" + checksum: 7346574a1038ca23c32e02252f603801f09384dd1d78b69a943a4e8c2c28730b80e96193882d3d3b22a063445f460e48316b29b8a25addca2d7e5e8f75478bec languageName: node linkType: hard From a3f4fa5ee446ce87cd856a7378d1b7d208016239 Mon Sep 17 00:00:00 2001 From: Sean Healy Date: Mon, 12 Dec 2022 16:45:30 +0000 Subject: [PATCH 087/146] Update conversation list to use 2.6 cursor pagination --- README.md | 11 +++------ lib/contact/contact.types.ts | 2 ++ lib/conversation.ts | 12 ++++----- test/unit/conversation.test.ts | 45 ++++++++++++++++++++++++++++------ 4 files changed, 50 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index 24c47b13..7b4d2b0c 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ [![Circle CI](https://circleci.com/gh/intercom/intercom-node.png?style=shield)](https://circleci.com/gh/intercom/intercom-node) [![npm](https://img.shields.io/npm/v/intercom-client)](https://www.npmjs.com/package/intercom-client) -![Intercom API Version](https://img.shields.io/badge/Intercom%20API%20Version-2.5-blue) +![Intercom API Version](https://img.shields.io/badge/Intercom%20API%20Version-2.6-blue) ![Typescript Supported](https://img.shields.io/badge/Typescript-Supported-lightgrey) > Official Node bindings to the [Intercom API](https://api.intercom.io/docs) @@ -21,7 +21,6 @@ yarn add intercom-client **This client is intended for server side use only. Please use the [Intercom Javascript SDK](https://developers.intercom.com/installing-intercom/docs/intercom-for-web) for client-side operations.** - ## Usage Import Intercom: @@ -57,7 +56,7 @@ We version our API (see the "Choose Version" section of the [API & Webhooks Refe const client = new Client({ tokenAuth: { token: 'my_token' } }); client.useRequestOpts({ headers: { - 'Intercom-Version': 2.4, + 'Intercom-Version': 2.6, }, }); ``` @@ -725,9 +724,7 @@ const response = await client.conversations.search({ ```typescript const response = await client.conversations.list({ - order: Order.DESC, - sort: SortBy.UpdatedAt, - page: 1, + startingAfter: 'WzE2NzA0MjI1MjkwMDAsMjQzMTY3NzA2ODcsMl0=', perPage: 10, }); ``` @@ -1088,7 +1085,6 @@ const response = await client.segments.list({ }); ``` - ### Subscriptions #### [List all subscription types](https://developers.intercom.com/intercom-api-reference/reference/list-all-subscription-types) @@ -1096,6 +1092,7 @@ const response = await client.segments.list({ ```typescript const response = await client.subscriptions.listTypes(); ``` + ### PhoneCallRedirects #### [Create a phone call redirect](https://developers.intercom.com/intercom-api-reference/reference/create-a-phone-switch) diff --git a/lib/contact/contact.types.ts b/lib/contact/contact.types.ts index 3df2d720..ce7384a6 100644 --- a/lib/contact/contact.types.ts +++ b/lib/contact/contact.types.ts @@ -45,6 +45,8 @@ export interface ContactObject { tags: AddressableList; notes: AddressableList; companies: AddressableList; + opted_in_subscription_types: AddressableList; + opted_out_subscription_tyes: AddressableList; referrer: string; utm_campaign: string | null; utm_content: string | null; diff --git a/lib/conversation.ts b/lib/conversation.ts index 03ee9c0c..884169c6 100644 --- a/lib/conversation.ts +++ b/lib/conversation.ts @@ -2,7 +2,6 @@ import Client from './client'; import { StringifiedTimestamp, GenericSearchFilters, - Order, PaginatedBase, } from './common/common.types'; import { @@ -256,8 +255,11 @@ export default class Conversation { data, }); } - list({ order, sort, page, perPage: per_page }: ListConversationData) { - const params = { order, sort, page, per_page }; + list({ + startingAfter: starting_after, + perPage: per_page, + }: ListConversationData) { + const params = { starting_after, per_page }; return this.client.get({ url: `/${this.baseUrl}`, @@ -518,9 +520,7 @@ export enum SortBy { } interface ListConversationData { - order?: Order; - sort?: SortBy; - page?: number; + startingAfter?: string; perPage?: number; } diff --git a/test/unit/conversation.test.ts b/test/unit/conversation.test.ts index 6caa844b..95d642d1 100644 --- a/test/unit/conversation.test.ts +++ b/test/unit/conversation.test.ts @@ -12,9 +12,8 @@ import { ReplyToConversationUserType, SearchConversationOrderBy, SnoozeConversationMessageType, - SortBy, } from '../../lib/conversation'; -import { Operators, Order } from '../../lib/common/common.types'; +import { Operators } from '../../lib/common/common.types'; describe('conversations', () => { it('should create a conversation', async () => { @@ -545,11 +544,45 @@ describe('conversations', () => { assert.deepStrictEqual(expectedReply, response); }); - it('should list all conversations', async () => { + it('should list all conversations with', async () => { const expectedReply = {}; nock('https://api.intercom.io') - .get(`/conversations?order=desc&sort=updated_at&page=1&per_page=10`) + .get(`/conversations`) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.list({}); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should list all conversations with per_page param', async () => { + const expectedReply = {}; + + nock('https://api.intercom.io') + .get(`/conversations?per_page=10`) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.list({ + perPage: 10, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should list all conversations with starting_after', async () => { + const expectedReply = {}; + + nock('https://api.intercom.io') + .get(`/conversations?starting_after=asdf123&per_page=10`) .reply(200, expectedReply); const client = new Client({ @@ -557,9 +590,7 @@ describe('conversations', () => { }); const response = await client.conversations.list({ - order: Order.DESC, - sort: SortBy.UpdatedAt, - page: 1, + startingAfter: 'asdf123', perPage: 10, }); From 5a05d3f740ebe2efc8acfcdedc807089fe590cae Mon Sep 17 00:00:00 2001 From: Sean Healy Date: Fri, 16 Dec 2022 11:28:06 +0000 Subject: [PATCH 088/146] Update intercom-node to 4.0.0 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index c0a9661e..8a897581 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "3.2.1", + "version": "4.0.0", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", From 5ae8c50b4b3b096ca5a5e89f4056cee6206f12ef Mon Sep 17 00:00:00 2001 From: Marin Martinic Date: Fri, 6 Jan 2023 16:52:02 +0000 Subject: [PATCH 089/146] remove integration tests approval step --- .circleci/config.yml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 0c87ea15..0cd1bb32 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -55,13 +55,9 @@ workflows: - unit_test: requires: - build - - integration_test_approval: - requires: - - unit_test - type: approval - integration_test: requires: - - integration_test_approval + - unit_test notify: webhooks: From 0d1f707ca4d563c8db5b1effca169a0a207d8f5a Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Tue, 7 Feb 2023 09:57:17 +0000 Subject: [PATCH 090/146] Documentation Error Fixes #347 --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 7b4d2b0c..293af040 100644 --- a/README.md +++ b/README.md @@ -1156,7 +1156,7 @@ const response = await client.tags.tagCompanies({ #### [Untag companies](https://developers.intercom.com/intercom-api-reference/reference/untag-companies) ```typescript -const response = await client.tags.tagCompanies({ +const response = await client.tags.untagCompanies({ tagName: 'gutenTag', companiesIds: ['123', '234', '456'], }); From 8fc20b70d1c44e290f7093352295db045eefe4eb Mon Sep 17 00:00:00 2001 From: Danny Fallon Date: Tue, 21 Feb 2023 15:41:27 +0000 Subject: [PATCH 091/146] Revert "Add FOSSA workflow to enable license scanning" --- .github/workflows/fossa-license-scan.yml | 24 ------------------------ 1 file changed, 24 deletions(-) delete mode 100644 .github/workflows/fossa-license-scan.yml diff --git a/.github/workflows/fossa-license-scan.yml b/.github/workflows/fossa-license-scan.yml deleted file mode 100644 index 310a9a71..00000000 --- a/.github/workflows/fossa-license-scan.yml +++ /dev/null @@ -1,24 +0,0 @@ -# More information on this workflow can be found here: https://stackoverflow.com/c/intercom/questions/1270 - -name: FOSSA License Scan - -on: - push: - branches: - - master - -jobs: - fossa: - runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v2 - - name: Attempt build - uses: intercom/attempt-build-action@main - continue-on-error: true - - name: Run FOSSA - uses: intercom/fossa-action@main - with: - fossa-api-key: ${{ secrets.FOSSA_API_KEY }} - fossa-event-receiver-token: ${{ secrets.FOSSA_EVENT_RECEIVER_TOKEN }} - datadog-api-key: ${{ secrets.DATADOG_API_KEY }} From 187ab8dfbc8366c0981d3bc691642d7dd37c510e Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Thu, 9 Mar 2023 13:19:37 +0000 Subject: [PATCH 092/146] Fix typo in Recepient and RecepientType Updates spelling from Recepient to Recipient closes #352 --- lib/index.ts | 2 +- lib/message.ts | 10 +++++----- test/integration/messages.test.ts | 10 +++++----- test/unit/message.test.ts | 6 +++--- 4 files changed, 14 insertions(+), 14 deletions(-) diff --git a/lib/index.ts b/lib/index.ts index 5ee488da..fe4bbc3b 100644 --- a/lib/index.ts +++ b/lib/index.ts @@ -57,7 +57,7 @@ export { SortBy, RedactConversationPartType, } from './conversation'; -export { RecepientType } from './message'; +export { RecipientType } from './message'; export { ContactObjectForMerge, MergeVisitorToContactData, diff --git a/lib/message.ts b/lib/message.ts index 096850d5..e941ae65 100644 --- a/lib/message.ts +++ b/lib/message.ts @@ -38,8 +38,8 @@ export default class Message { interface CreateMessageRequest { message_type: MessageType; body: string; - from: Recepient; - to: Recepient; + from: Recipient; + to: Recipient; subject?: string; template?: string; create_conversation_without_contact_reply?: boolean; @@ -54,12 +54,12 @@ interface CreateMessageBody createConversationWithoutContactReply?: boolean; } -type Recepient = { +type Recipient = { id: string; - type: RecepientType; + type: RecipientType; }; -export enum RecepientType { +export enum RecipientType { ADMIN = 'admin', USER = 'user', LEAD = 'lead', diff --git a/test/integration/messages.test.ts b/test/integration/messages.test.ts index 61db456f..5e07d2b6 100644 --- a/test/integration/messages.test.ts +++ b/test/integration/messages.test.ts @@ -2,7 +2,7 @@ import { token } from './utils/config'; import { Client, Operators } from '../../dist'; import { randomString } from './utils/random'; import { MessageType } from '../../lib/message/message.types'; -import { RecepientType } from '../../lib/message'; +import { RecipientType } from '../../lib/message'; import assert from 'assert'; describe('Messages', () => { @@ -28,11 +28,11 @@ describe('Messages', () => { message_type: MessageType.INAPP, body: 'Hey, look at me! I am the conversations creator now!', from: { - type: RecepientType.ADMIN, + type: RecipientType.ADMIN, id: adminId, }, to: { - type: RecepientType.USER, + type: RecipientType.USER, id: userIntercomId, }, }; @@ -66,11 +66,11 @@ describe('Messages', () => { message_type: MessageType.INAPP, body: 'Message without creating conversation', from: { - type: RecepientType.ADMIN, + type: RecipientType.ADMIN, id: adminId, }, to: { - type: RecepientType.USER, + type: RecipientType.USER, id: userIntercomId, }, }; diff --git a/test/unit/message.test.ts b/test/unit/message.test.ts index 9d7ca3ea..a10dda8d 100644 --- a/test/unit/message.test.ts +++ b/test/unit/message.test.ts @@ -2,7 +2,7 @@ import assert from 'assert'; import { Client } from '../../lib'; import nock from 'nock'; import { MessageType } from '../../lib/message/message.types'; -import { RecepientType } from '../../lib/message'; +import { RecipientType } from '../../lib/message'; describe('messages', () => { it('should be created', async () => { @@ -12,11 +12,11 @@ describe('messages', () => { body: 'Destroy ponies', template: 'plain', from: { - type: RecepientType.ADMIN, + type: RecipientType.ADMIN, id: '394051', }, to: { - type: RecepientType.USER, + type: RecipientType.USER, id: '536e564f316c83104c000020', }, }; From ca69c6bbbf37d142c1c5a0280e50f231bc579acc Mon Sep 17 00:00:00 2001 From: Vanley Date: Tue, 2 May 2023 12:01:50 +0100 Subject: [PATCH 093/146] typo in README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 293af040..a7b71f58 100644 --- a/README.md +++ b/README.md @@ -198,7 +198,7 @@ const company = await client.companies.create({ #### [Update a company](https://developers.intercom.com/intercom-api-reference/reference/update-a-company) ```typescript -const company = await client.companies.create({ +const company = await client.companies.update({ createdAt: dateToUnixTimestamp(new Date()), companyId: '46029', name: 'BestCompanyInc.', From 1559d466bb6386b4a1405edf2949a298b988a8ca Mon Sep 17 00:00:00 2001 From: mhnpd Date: Thu, 1 Jun 2023 11:22:10 +0545 Subject: [PATCH 094/146] Update README file --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index a7b71f58..c55b9a98 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ yarn add intercom-client Import Intercom: ```typescript -import { Client } from './dist/index'; +import { Client } from 'intercom-client'; ``` Create a client using access tokens: @@ -68,7 +68,7 @@ If you are using the european instance of intercom and would like to call it dir ```typescript const client = new Client({ tokenAuth: { token: 'my_token' } }); client.useRequestOpts({ - baseUrl: 'https://api.eu.intercom.io', + baseURL: 'https://api.eu.intercom.io', }); ``` From e84247214b27832efb369c108a094675ac00e75c Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Fri, 7 Jul 2023 17:15:18 +0100 Subject: [PATCH 095/146] Make the company fields optional --- lib/company.ts | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/company.ts b/lib/company.ts index c4f4f346..e1d3b98f 100644 --- a/lib/company.ts +++ b/lib/company.ts @@ -149,15 +149,15 @@ export default class Company { } interface CreateCompanyData { - createdAt: Timestamp; + createdAt?: Timestamp; companyId: string; - name: string; - monthlySpend: number; - plan: string; - size: number; - website: string; - industry: string; - customAttributes: JavascriptObject; + name?: string; + monthlySpend?: number; + plan?: string; + size?: number; + website?: string; + industry?: string; + customAttributes?: JavascriptObject; } // type UpdateCompanyData = CreateCompanyData; From e08e99289e938cea3762765d99fec3e12b96e3ff Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Fri, 7 Jul 2023 17:20:25 +0100 Subject: [PATCH 096/146] yarn install --- yarn.lock | 1694 ++++++++++++++++++++++++++++++----------------------- 1 file changed, 970 insertions(+), 724 deletions(-) diff --git a/yarn.lock b/yarn.lock index 6b01cb85..5ec7c347 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5,292 +5,316 @@ __metadata: version: 5 cacheKey: 8 -"@ampproject/remapping@npm:^2.0.0": - version: 2.1.0 - resolution: "@ampproject/remapping@npm:2.1.0" +"@aashutoshrathi/word-wrap@npm:^1.2.3": + version: 1.2.6 + resolution: "@aashutoshrathi/word-wrap@npm:1.2.6" + checksum: ada901b9e7c680d190f1d012c84217ce0063d8f5c5a7725bb91ec3c5ed99bb7572680eb2d2938a531ccbaec39a95422fcd8a6b4a13110c7d98dd75402f66a0cd + languageName: node + linkType: hard + +"@ampproject/remapping@npm:^2.2.0": + version: 2.2.1 + resolution: "@ampproject/remapping@npm:2.2.1" dependencies: - "@jridgewell/trace-mapping": ^0.3.0 - checksum: 10ff0d4a559f930082f1a4c1b68dc521d5b1a75e0b8ab4829e9eedf6621386893e4a008f0db6c716f64db5d8eed49c0abcfbf3bd6ff11d5a00312454a9351ed4 + "@jridgewell/gen-mapping": ^0.3.0 + "@jridgewell/trace-mapping": ^0.3.9 + checksum: 03c04fd526acc64a1f4df22651186f3e5ef0a9d6d6530ce4482ec9841269cf7a11dbb8af79237c282d721c5312024ff17529cd72cc4768c11e999b58e2302079 languageName: node linkType: hard -"@babel/code-frame@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/code-frame@npm:7.16.7" +"@babel/code-frame@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/code-frame@npm:7.22.5" dependencies: - "@babel/highlight": ^7.16.7 - checksum: db2f7faa31bc2c9cf63197b481b30ea57147a5fc1a6fab60e5d6c02cdfbf6de8e17b5121f99917b3dabb5eeb572da078312e70697415940383efc140d4e0808b + "@babel/highlight": ^7.22.5 + checksum: cfe804f518f53faaf9a1d3e0f9f74127ab9a004912c3a16fda07fb6a633393ecb9918a053cb71804204c1b7ec3d49e1699604715e2cfb0c9f7bc4933d324ebb6 languageName: node linkType: hard -"@babel/compat-data@npm:^7.16.4": - version: 7.17.0 - resolution: "@babel/compat-data@npm:7.17.0" - checksum: fe5afaf529d107a223cd5937dace248464b6df1e9f4ea4031a5723e9571b46a4db1c4ff226bac6351148b1bc02ba1b39cb142662cd235aa99c1dda77882f8c9d +"@babel/compat-data@npm:^7.22.6": + version: 7.22.6 + resolution: "@babel/compat-data@npm:7.22.6" + checksum: b88631143a2ebdb75e5bac47984e950983294f1739c2133f32569c6f2fcee85f83634bb6cf4378afb44fa8eb7877d11e48811d1e6a52afa161f82276ffdc3fb4 languageName: node linkType: hard "@babel/core@npm:^7.7.5": - version: 7.17.2 - resolution: "@babel/core@npm:7.17.2" - dependencies: - "@ampproject/remapping": ^2.0.0 - "@babel/code-frame": ^7.16.7 - "@babel/generator": ^7.17.0 - "@babel/helper-compilation-targets": ^7.16.7 - "@babel/helper-module-transforms": ^7.16.7 - "@babel/helpers": ^7.17.2 - "@babel/parser": ^7.17.0 - "@babel/template": ^7.16.7 - "@babel/traverse": ^7.17.0 - "@babel/types": ^7.17.0 + version: 7.22.8 + resolution: "@babel/core@npm:7.22.8" + dependencies: + "@ampproject/remapping": ^2.2.0 + "@babel/code-frame": ^7.22.5 + "@babel/generator": ^7.22.7 + "@babel/helper-compilation-targets": ^7.22.6 + "@babel/helper-module-transforms": ^7.22.5 + "@babel/helpers": ^7.22.6 + "@babel/parser": ^7.22.7 + "@babel/template": ^7.22.5 + "@babel/traverse": ^7.22.8 + "@babel/types": ^7.22.5 + "@nicolo-ribaudo/semver-v6": ^6.3.3 convert-source-map: ^1.7.0 debug: ^4.1.0 gensync: ^1.0.0-beta.2 - json5: ^2.1.2 - semver: ^6.3.0 - checksum: 68ab3459f41b41feb5cb263937f15e418e1c46998d482d1b6dfe34f78064765466cfd5b10205c22fb16b69dbd1d46e7a3c26c067884ca4eb514b3dac1e09a57f + json5: ^2.2.2 + checksum: 75ed701c14ad17070382ae1dd166f7534b31f2c71e00995a5f261ee2398ee96335b0736573b8ff24ab6e3e6f5814ee2a48fa11ab90fabcd3dfc70ea87c5f30a6 languageName: node linkType: hard -"@babel/generator@npm:^7.17.0": - version: 7.17.0 - resolution: "@babel/generator@npm:7.17.0" +"@babel/generator@npm:^7.22.7": + version: 7.22.7 + resolution: "@babel/generator@npm:7.22.7" dependencies: - "@babel/types": ^7.17.0 + "@babel/types": ^7.22.5 + "@jridgewell/gen-mapping": ^0.3.2 + "@jridgewell/trace-mapping": ^0.3.17 jsesc: ^2.5.1 - source-map: ^0.5.0 - checksum: 2987dbebb484727a227f1ce3db90810320986cfb3ffd23e6d1d87f75bbd8e7871b5bc44252822d4d5f048a2d872a5702b2a9bf7bab7e07f087d7f306f0ea6c0a + checksum: cee15558888bdf5564e19cfaf95101b2910fa425f30cc1a25ac9b8621bd62b63544eb1b36ad89c80b5e41915699219f78712cab128d1f7e3da6a21fbf4143927 languageName: node linkType: hard -"@babel/helper-compilation-targets@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-compilation-targets@npm:7.16.7" +"@babel/helper-compilation-targets@npm:^7.22.6": + version: 7.22.6 + resolution: "@babel/helper-compilation-targets@npm:7.22.6" dependencies: - "@babel/compat-data": ^7.16.4 - "@babel/helper-validator-option": ^7.16.7 - browserslist: ^4.17.5 - semver: ^6.3.0 + "@babel/compat-data": ^7.22.6 + "@babel/helper-validator-option": ^7.22.5 + "@nicolo-ribaudo/semver-v6": ^6.3.3 + browserslist: ^4.21.9 + lru-cache: ^5.1.1 peerDependencies: "@babel/core": ^7.0.0 - checksum: 7238aaee78c011a42fb5ca92e5eff098752f7b314c2111d7bb9cdd58792fcab1b9c819b59f6a0851dc210dc09dc06b30d130a23982753e70eb3111bc65204842 + checksum: c7788c48099c4f0edf2adeb367a941a930d39ed7453140ceb10d7114c4091922adf56d3cdd832050fd4501f25e872886390629042ddd365d3bce2ecad69ed394 languageName: node linkType: hard -"@babel/helper-environment-visitor@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-environment-visitor@npm:7.16.7" - dependencies: - "@babel/types": ^7.16.7 - checksum: c03a10105d9ebd1fe632a77356b2e6e2f3c44edba9a93b0dc3591b6a66bd7a2e323dd9502f9ce96fc6401234abff1907aa877b6674f7826b61c953f7c8204bbe +"@babel/helper-environment-visitor@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-environment-visitor@npm:7.22.5" + checksum: 248532077d732a34cd0844eb7b078ff917c3a8ec81a7f133593f71a860a582f05b60f818dc5049c2212e5baa12289c27889a4b81d56ef409b4863db49646c4b1 languageName: node linkType: hard -"@babel/helper-function-name@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-function-name@npm:7.16.7" +"@babel/helper-function-name@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-function-name@npm:7.22.5" dependencies: - "@babel/helper-get-function-arity": ^7.16.7 - "@babel/template": ^7.16.7 - "@babel/types": ^7.16.7 - checksum: fc77cbe7b10cfa2a262d7a37dca575c037f20419dfe0c5d9317f589599ca24beb5f5c1057748011159149eaec47fe32338c6c6412376fcded68200df470161e1 + "@babel/template": ^7.22.5 + "@babel/types": ^7.22.5 + checksum: 6b1f6ce1b1f4e513bf2c8385a557ea0dd7fa37971b9002ad19268ca4384bbe90c09681fe4c076013f33deabc63a53b341ed91e792de741b4b35e01c00238177a languageName: node linkType: hard -"@babel/helper-get-function-arity@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-get-function-arity@npm:7.16.7" +"@babel/helper-hoist-variables@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-hoist-variables@npm:7.22.5" dependencies: - "@babel/types": ^7.16.7 - checksum: 25d969fb207ff2ad5f57a90d118f6c42d56a0171022e200aaa919ba7dc95ae7f92ec71cdea6c63ef3629a0dc962ab4c78e09ca2b437185ab44539193f796e0c3 + "@babel/types": ^7.22.5 + checksum: 394ca191b4ac908a76e7c50ab52102669efe3a1c277033e49467913c7ed6f7c64d7eacbeabf3bed39ea1f41731e22993f763b1edce0f74ff8563fd1f380d92cc languageName: node linkType: hard -"@babel/helper-hoist-variables@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-hoist-variables@npm:7.16.7" +"@babel/helper-module-imports@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-module-imports@npm:7.22.5" dependencies: - "@babel/types": ^7.16.7 - checksum: 6ae1641f4a751cd9045346e3f61c3d9ec1312fd779ab6d6fecfe2a96e59a481ad5d7e40d2a840894c13b3fd6114345b157f9e3062fc5f1580f284636e722de60 + "@babel/types": ^7.22.5 + checksum: 9ac2b0404fa38b80bdf2653fbeaf8e8a43ccb41bd505f9741d820ed95d3c4e037c62a1bcdcb6c9527d7798d2e595924c4d025daed73283badc180ada2c9c49ad languageName: node linkType: hard -"@babel/helper-module-imports@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-module-imports@npm:7.16.7" +"@babel/helper-module-transforms@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-module-transforms@npm:7.22.5" dependencies: - "@babel/types": ^7.16.7 - checksum: ddd2c4a600a2e9a4fee192ab92bf35a627c5461dbab4af31b903d9ba4d6b6e59e0ff3499fde4e2e9a0eebe24906f00b636f8b4d9bd72ff24d50e6618215c3212 + "@babel/helper-environment-visitor": ^7.22.5 + "@babel/helper-module-imports": ^7.22.5 + "@babel/helper-simple-access": ^7.22.5 + "@babel/helper-split-export-declaration": ^7.22.5 + "@babel/helper-validator-identifier": ^7.22.5 + "@babel/template": ^7.22.5 + "@babel/traverse": ^7.22.5 + "@babel/types": ^7.22.5 + checksum: 8985dc0d971fd17c467e8b84fe0f50f3dd8610e33b6c86e5b3ca8e8859f9448bcc5c84e08a2a14285ef388351c0484797081c8f05a03770bf44fc27bf4900e68 languageName: node linkType: hard -"@babel/helper-module-transforms@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-module-transforms@npm:7.16.7" +"@babel/helper-simple-access@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-simple-access@npm:7.22.5" dependencies: - "@babel/helper-environment-visitor": ^7.16.7 - "@babel/helper-module-imports": ^7.16.7 - "@babel/helper-simple-access": ^7.16.7 - "@babel/helper-split-export-declaration": ^7.16.7 - "@babel/helper-validator-identifier": ^7.16.7 - "@babel/template": ^7.16.7 - "@babel/traverse": ^7.16.7 - "@babel/types": ^7.16.7 - checksum: 6e930ce776c979f299cdbeaf80187f4ab086d75287b96ecc1c6896d392fcb561065f0d6219fc06fa79b4ceb4bbdc1a9847da8099aba9b077d0a9e583500fb673 + "@babel/types": ^7.22.5 + checksum: fe9686714caf7d70aedb46c3cce090f8b915b206e09225f1e4dbc416786c2fdbbee40b38b23c268b7ccef749dd2db35f255338fb4f2444429874d900dede5ad2 languageName: node linkType: hard -"@babel/helper-simple-access@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-simple-access@npm:7.16.7" +"@babel/helper-split-export-declaration@npm:^7.22.5, @babel/helper-split-export-declaration@npm:^7.22.6": + version: 7.22.6 + resolution: "@babel/helper-split-export-declaration@npm:7.22.6" dependencies: - "@babel/types": ^7.16.7 - checksum: 8d22c46c5ec2ead0686c4d5a3d1d12b5190c59be676bfe0d9d89df62b437b51d1a3df2ccfb8a77dded2e585176ebf12986accb6d45a18cff229eef3b10344f4b + "@babel/types": ^7.22.5 + checksum: e141cace583b19d9195f9c2b8e17a3ae913b7ee9b8120246d0f9ca349ca6f03cb2c001fd5ec57488c544347c0bb584afec66c936511e447fd20a360e591ac921 languageName: node linkType: hard -"@babel/helper-split-export-declaration@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-split-export-declaration@npm:7.16.7" - dependencies: - "@babel/types": ^7.16.7 - checksum: e10aaf135465c55114627951b79115f24bc7af72ecbb58d541d66daf1edaee5dde7cae3ec8c3639afaf74526c03ae3ce723444e3b5b3dc77140c456cd84bcaa1 +"@babel/helper-string-parser@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-string-parser@npm:7.22.5" + checksum: 836851ca5ec813077bbb303acc992d75a360267aa3b5de7134d220411c852a6f17de7c0d0b8c8dcc0f567f67874c00f4528672b2a4f1bc978a3ada64c8c78467 languageName: node linkType: hard -"@babel/helper-validator-identifier@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-validator-identifier@npm:7.16.7" - checksum: dbb3db9d184343152520a209b5684f5e0ed416109cde82b428ca9c759c29b10c7450657785a8b5c5256aa74acc6da491c1f0cf6b784939f7931ef82982051b69 +"@babel/helper-validator-identifier@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-validator-identifier@npm:7.22.5" + checksum: 7f0f30113474a28298c12161763b49de5018732290ca4de13cdaefd4fd0d635a6fe3f6686c37a02905fb1e64f21a5ee2b55140cf7b070e729f1bd66866506aea languageName: node linkType: hard -"@babel/helper-validator-option@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/helper-validator-option@npm:7.16.7" - checksum: c5ccc451911883cc9f12125d47be69434f28094475c1b9d2ada7c3452e6ac98a1ee8ddd364ca9e3f9855fcdee96cdeafa32543ebd9d17fee7a1062c202e80570 +"@babel/helper-validator-option@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-validator-option@npm:7.22.5" + checksum: bbeca8a85ee86990215c0424997438b388b8d642d69b9f86c375a174d3cdeb270efafd1ff128bc7a1d370923d13b6e45829ba8581c027620e83e3a80c5c414b3 languageName: node linkType: hard -"@babel/helpers@npm:^7.17.2": - version: 7.17.2 - resolution: "@babel/helpers@npm:7.17.2" +"@babel/helpers@npm:^7.22.6": + version: 7.22.6 + resolution: "@babel/helpers@npm:7.22.6" dependencies: - "@babel/template": ^7.16.7 - "@babel/traverse": ^7.17.0 - "@babel/types": ^7.17.0 - checksum: 5fa06bbf59636314fb4098bb2e70cf488e0fb6989553438abab90356357b79976102ac129fb16fc8186893c79e0809de1d90e3304426d6fcdb1750da2b6dff9d + "@babel/template": ^7.22.5 + "@babel/traverse": ^7.22.6 + "@babel/types": ^7.22.5 + checksum: 5c1f33241fe7bf7709868c2105134a0a86dca26a0fbd508af10a89312b1f77ca38ebae43e50be3b208613c5eacca1559618af4ca236f0abc55d294800faeff30 languageName: node linkType: hard -"@babel/highlight@npm:^7.16.7": - version: 7.16.10 - resolution: "@babel/highlight@npm:7.16.10" +"@babel/highlight@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/highlight@npm:7.22.5" dependencies: - "@babel/helper-validator-identifier": ^7.16.7 + "@babel/helper-validator-identifier": ^7.22.5 chalk: ^2.0.0 js-tokens: ^4.0.0 - checksum: 1f1bdd752a90844f4efc22166a46303fb651ba0fd75a06daba3ebae2575ab3edc1da9827c279872a3aaf305f50a18473c5fa1966752726a2b253065fd4c0745e + checksum: f61ae6de6ee0ea8d9b5bcf2a532faec5ab0a1dc0f7c640e5047fc61630a0edb88b18d8c92eb06566d30da7a27db841aca11820ecd3ebe9ce514c9350fbed39c4 languageName: node linkType: hard -"@babel/parser@npm:^7.16.7, @babel/parser@npm:^7.17.0": - version: 7.17.0 - resolution: "@babel/parser@npm:7.17.0" +"@babel/parser@npm:^7.22.5, @babel/parser@npm:^7.22.7": + version: 7.22.7 + resolution: "@babel/parser@npm:7.22.7" bin: parser: ./bin/babel-parser.js - checksum: d0ac5ffba0b234dde516f867edf5da5d92d6f841592b370ae3244cd7c8f27a7f5e3e3d4e90ca9c15ea58bc46823f1643f3f75b6eb9a9f676ae16e8b2365e922a + checksum: 02209ddbd445831ee8bf966fdf7c29d189ed4b14343a68eb2479d940e7e3846340d7cc6bd654a5f3d87d19dc84f49f50a58cf9363bee249dc5409ff3ba3dab54 languageName: node linkType: hard -"@babel/template@npm:^7.16.7": - version: 7.16.7 - resolution: "@babel/template@npm:7.16.7" +"@babel/template@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/template@npm:7.22.5" dependencies: - "@babel/code-frame": ^7.16.7 - "@babel/parser": ^7.16.7 - "@babel/types": ^7.16.7 - checksum: 10cd112e89276e00f8b11b55a51c8b2f1262c318283a980f4d6cdb0286dc05734b9aaeeb9f3ad3311900b09bc913e02343fcaa9d4a4f413964aaab04eb84ac4a + "@babel/code-frame": ^7.22.5 + "@babel/parser": ^7.22.5 + "@babel/types": ^7.22.5 + checksum: c5746410164039aca61829cdb42e9a55410f43cace6f51ca443313f3d0bdfa9a5a330d0b0df73dc17ef885c72104234ae05efede37c1cc8a72dc9f93425977a3 languageName: node linkType: hard -"@babel/traverse@npm:^7.16.7, @babel/traverse@npm:^7.17.0": - version: 7.17.0 - resolution: "@babel/traverse@npm:7.17.0" +"@babel/traverse@npm:^7.22.5, @babel/traverse@npm:^7.22.6, @babel/traverse@npm:^7.22.8": + version: 7.22.8 + resolution: "@babel/traverse@npm:7.22.8" dependencies: - "@babel/code-frame": ^7.16.7 - "@babel/generator": ^7.17.0 - "@babel/helper-environment-visitor": ^7.16.7 - "@babel/helper-function-name": ^7.16.7 - "@babel/helper-hoist-variables": ^7.16.7 - "@babel/helper-split-export-declaration": ^7.16.7 - "@babel/parser": ^7.17.0 - "@babel/types": ^7.17.0 + "@babel/code-frame": ^7.22.5 + "@babel/generator": ^7.22.7 + "@babel/helper-environment-visitor": ^7.22.5 + "@babel/helper-function-name": ^7.22.5 + "@babel/helper-hoist-variables": ^7.22.5 + "@babel/helper-split-export-declaration": ^7.22.6 + "@babel/parser": ^7.22.7 + "@babel/types": ^7.22.5 debug: ^4.1.0 globals: ^11.1.0 - checksum: 9b7de053d8a29453fd7b9614a028d8dc811817f02948eaee02093274b67927a1cfb0513b521bc4a9328c9b6e5b021fd343b358c3526bbb6ee61ec078d4110c0c + checksum: a381369bc3eedfd13ed5fef7b884657f1c29024ea7388198149f0edc34bd69ce3966e9f40188d15f56490a5e12ba250ccc485f2882b53d41b054fccefb233e33 languageName: node linkType: hard -"@babel/types@npm:^7.16.7, @babel/types@npm:^7.17.0, @babel/types@npm:^7.8.3": - version: 7.17.0 - resolution: "@babel/types@npm:7.17.0" +"@babel/types@npm:^7.22.5, @babel/types@npm:^7.8.3": + version: 7.22.5 + resolution: "@babel/types@npm:7.22.5" dependencies: - "@babel/helper-validator-identifier": ^7.16.7 + "@babel/helper-string-parser": ^7.22.5 + "@babel/helper-validator-identifier": ^7.22.5 to-fast-properties: ^2.0.0 - checksum: 12e5a287986fe557188e87b2c5202223f1dc83d9239a196ab936fdb9f8c1eb0be717ff19f934b5fad4e29a75586d5798f74bed209bccea1c20376b9952056f0e + checksum: c13a9c1dc7d2d1a241a2f8363540cb9af1d66e978e8984b400a20c4f38ba38ca29f06e26a0f2d49a70bad9e57615dac09c35accfddf1bb90d23cd3e0a0bab892 languageName: node linkType: hard -"@cspotcode/source-map-consumer@npm:0.8.0": - version: 0.8.0 - resolution: "@cspotcode/source-map-consumer@npm:0.8.0" - checksum: c0c16ca3d2f58898f1bd74c4f41a189dbcc202e642e60e489cbcc2e52419c4e89bdead02c886a12fb13ea37798ede9e562b2321df997ebc210ae9bd881561b4e +"@cspotcode/source-map-support@npm:^0.8.0": + version: 0.8.1 + resolution: "@cspotcode/source-map-support@npm:0.8.1" + dependencies: + "@jridgewell/trace-mapping": 0.3.9 + checksum: 5718f267085ed8edb3e7ef210137241775e607ee18b77d95aa5bd7514f47f5019aa2d82d96b3bf342ef7aa890a346fa1044532ff7cc3009e7d24fce3ce6200fa languageName: node linkType: hard -"@cspotcode/source-map-support@npm:0.7.0": - version: 0.7.0 - resolution: "@cspotcode/source-map-support@npm:0.7.0" +"@eslint-community/eslint-utils@npm:^4.2.0": + version: 4.4.0 + resolution: "@eslint-community/eslint-utils@npm:4.4.0" dependencies: - "@cspotcode/source-map-consumer": 0.8.0 - checksum: 9faddda7757cd778b5fd6812137b2cc265810043680d6399acc20441668fafcdc874053be9dccd0d9110087287bfad27eb3bf342f72bceca9aa9059f5d0c4be8 + eslint-visitor-keys: ^3.3.0 + peerDependencies: + eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 + checksum: cdfe3ae42b4f572cbfb46d20edafe6f36fc5fb52bf2d90875c58aefe226892b9677fef60820e2832caf864a326fe4fc225714c46e8389ccca04d5f9288aabd22 languageName: node linkType: hard -"@eslint/eslintrc@npm:^1.0.5": - version: 1.0.5 - resolution: "@eslint/eslintrc@npm:1.0.5" +"@eslint-community/regexpp@npm:^4.4.0": + version: 4.5.1 + resolution: "@eslint-community/regexpp@npm:4.5.1" + checksum: 6d901166d64998d591fab4db1c2f872981ccd5f6fe066a1ad0a93d4e11855ecae6bfb76660869a469563e8882d4307228cebd41142adb409d182f2966771e57e + languageName: node + linkType: hard + +"@eslint/eslintrc@npm:^2.1.0": + version: 2.1.0 + resolution: "@eslint/eslintrc@npm:2.1.0" dependencies: ajv: ^6.12.4 debug: ^4.3.2 - espree: ^9.2.0 - globals: ^13.9.0 - ignore: ^4.0.6 + espree: ^9.6.0 + globals: ^13.19.0 + ignore: ^5.2.0 import-fresh: ^3.2.1 js-yaml: ^4.1.0 - minimatch: ^3.0.4 + minimatch: ^3.1.2 strip-json-comments: ^3.1.1 - checksum: b35b50d7b65bd8acd92a05b6fb15ac62c0cefa40dfef0324ca5bf8632bf3679bab6e173c53b3ad1e1d837701cecdbd9c144b35f46588cdf4e046a9caa272488d + checksum: d5ed0adbe23f6571d8c9bb0ca6edf7618dc6aed4046aa56df7139f65ae7b578874e0d9c796df784c25bda648ceb754b6320277d828c8b004876d7443b8dc018c languageName: node linkType: hard -"@gar/promisify@npm:^1.0.1": - version: 1.1.2 - resolution: "@gar/promisify@npm:1.1.2" - checksum: d05081e0887a49c178b75ee3067bd6ee086f73c154d121b854fb2e044e8a89cb1cbb6de3a0dd93a519b80f0531fda68b099dd7256205f7fbb3490324342f2217 +"@eslint/js@npm:8.44.0": + version: 8.44.0 + resolution: "@eslint/js@npm:8.44.0" + checksum: fc539583226a28f5677356e9f00d2789c34253f076643d2e32888250e509a4e13aafe0880cb2425139051de0f3a48d25bfc5afa96b7304f203b706c17340e3cf languageName: node linkType: hard -"@humanwhocodes/config-array@npm:^0.9.2": - version: 0.9.3 - resolution: "@humanwhocodes/config-array@npm:0.9.3" +"@humanwhocodes/config-array@npm:^0.11.10": + version: 0.11.10 + resolution: "@humanwhocodes/config-array@npm:0.11.10" dependencies: "@humanwhocodes/object-schema": ^1.2.1 debug: ^4.1.1 - minimatch: ^3.0.4 - checksum: 6e5d7d274941c459bab0a14a87e372206d89fad3e4879d982edc942e8cc34da6510ea3644b8535a2a9edaa6527e91dccceabc6837ffa8ee506d66bca5d269ebc + minimatch: ^3.0.5 + checksum: 1b1302e2403d0e35bc43e66d67a2b36b0ad1119efc704b5faff68c41f791a052355b010fb2d27ef022670f550de24cd6d08d5ecf0821c16326b7dcd0ee5d5d8a + languageName: node + linkType: hard + +"@humanwhocodes/module-importer@npm:^1.0.1": + version: 1.0.1 + resolution: "@humanwhocodes/module-importer@npm:1.0.1" + checksum: 0fd22007db8034a2cdf2c764b140d37d9020bbfce8a49d3ec5c05290e77d4b0263b1b972b752df8c89e5eaa94073408f2b7d977aed131faf6cf396ebb5d7fb61 languageName: node linkType: hard @@ -301,6 +325,20 @@ __metadata: languageName: node linkType: hard +"@isaacs/cliui@npm:^8.0.2": + version: 8.0.2 + resolution: "@isaacs/cliui@npm:8.0.2" + dependencies: + string-width: ^5.1.2 + string-width-cjs: "npm:string-width@^4.2.0" + strip-ansi: ^7.0.1 + strip-ansi-cjs: "npm:strip-ansi@^6.0.1" + wrap-ansi: ^8.1.0 + wrap-ansi-cjs: "npm:wrap-ansi@^7.0.0" + checksum: 4a473b9b32a7d4d3cfb7a614226e555091ff0c5a29a1734c28c72a182c2f6699b26fc6b5c2131dfd841e86b185aea714c72201d7c98c2fba5f17709333a67aeb + languageName: node + linkType: hard + "@istanbuljs/load-nyc-config@npm:^1.0.0": version: 1.1.0 resolution: "@istanbuljs/load-nyc-config@npm:1.1.0" @@ -332,27 +370,78 @@ __metadata: languageName: node linkType: hard +"@jridgewell/gen-mapping@npm:^0.3.0, @jridgewell/gen-mapping@npm:^0.3.2": + version: 0.3.3 + resolution: "@jridgewell/gen-mapping@npm:0.3.3" + dependencies: + "@jridgewell/set-array": ^1.0.1 + "@jridgewell/sourcemap-codec": ^1.4.10 + "@jridgewell/trace-mapping": ^0.3.9 + checksum: 4a74944bd31f22354fc01c3da32e83c19e519e3bbadafa114f6da4522ea77dd0c2842607e923a591d60a76699d819a2fbb6f3552e277efdb9b58b081390b60ab + languageName: node + linkType: hard + +"@jridgewell/resolve-uri@npm:3.1.0": + version: 3.1.0 + resolution: "@jridgewell/resolve-uri@npm:3.1.0" + checksum: b5ceaaf9a110fcb2780d1d8f8d4a0bfd216702f31c988d8042e5f8fbe353c55d9b0f55a1733afdc64806f8e79c485d2464680ac48a0d9fcadb9548ee6b81d267 + languageName: node + linkType: hard + "@jridgewell/resolve-uri@npm:^3.0.3": - version: 3.0.4 - resolution: "@jridgewell/resolve-uri@npm:3.0.4" - checksum: 799bcba2730280a42f11b4d41a5d34d68ce72cb1bd23186bd3356607c93b62765b2b050e5dfb67f04ce4e817f882bfc10a4d1c43fe2d8eeb38371c98d71217b4 + version: 3.1.1 + resolution: "@jridgewell/resolve-uri@npm:3.1.1" + checksum: f5b441fe7900eab4f9155b3b93f9800a916257f4e8563afbcd3b5a5337b55e52bd8ae6735453b1b745457d9f6cdb16d74cd6220bbdd98cf153239e13f6cbb653 + languageName: node + linkType: hard + +"@jridgewell/set-array@npm:^1.0.1": + version: 1.1.2 + resolution: "@jridgewell/set-array@npm:1.1.2" + checksum: 69a84d5980385f396ff60a175f7177af0b8da4ddb81824cb7016a9ef914eee9806c72b6b65942003c63f7983d4f39a5c6c27185bbca88eb4690b62075602e28e + languageName: node + linkType: hard + +"@jridgewell/sourcemap-codec@npm:1.4.14": + version: 1.4.14 + resolution: "@jridgewell/sourcemap-codec@npm:1.4.14" + checksum: 61100637b6d173d3ba786a5dff019e1a74b1f394f323c1fee337ff390239f053b87266c7a948777f4b1ee68c01a8ad0ab61e5ff4abb5a012a0b091bec391ab97 languageName: node linkType: hard "@jridgewell/sourcemap-codec@npm:^1.4.10": - version: 1.4.10 - resolution: "@jridgewell/sourcemap-codec@npm:1.4.10" - checksum: 247229218edbe165dcf0a5ae0c4b81bff1b5438818bb09221f756681fe158597fdf25c2a803f9260453b299c98c7e01ddebeb1555cda3157d987cd22c08605ef + version: 1.4.15 + resolution: "@jridgewell/sourcemap-codec@npm:1.4.15" + checksum: b881c7e503db3fc7f3c1f35a1dd2655a188cc51a3612d76efc8a6eb74728bef5606e6758ee77423e564092b4a518aba569bbb21c9bac5ab7a35b0c6ae7e344c8 languageName: node linkType: hard -"@jridgewell/trace-mapping@npm:^0.3.0": - version: 0.3.2 - resolution: "@jridgewell/trace-mapping@npm:0.3.2" +"@jridgewell/trace-mapping@npm:0.3.9": + version: 0.3.9 + resolution: "@jridgewell/trace-mapping@npm:0.3.9" dependencies: "@jridgewell/resolve-uri": ^3.0.3 "@jridgewell/sourcemap-codec": ^1.4.10 - checksum: b58be6b4133cbcb20bfd28c9ca843b8db9efa0bf1d7e0e9e26b2228dace94ad53161c996ab1d762d7c3955dfc398a7734e7b84a2493ae36b451f232234fbb257 + checksum: d89597752fd88d3f3480845691a05a44bd21faac18e2185b6f436c3b0fd0c5a859fbbd9aaa92050c4052caf325ad3e10e2e1d1b64327517471b7d51babc0ddef + languageName: node + linkType: hard + +"@jridgewell/trace-mapping@npm:^0.3.17, @jridgewell/trace-mapping@npm:^0.3.9": + version: 0.3.18 + resolution: "@jridgewell/trace-mapping@npm:0.3.18" + dependencies: + "@jridgewell/resolve-uri": 3.1.0 + "@jridgewell/sourcemap-codec": 1.4.14 + checksum: 0572669f855260808c16fe8f78f5f1b4356463b11d3f2c7c0b5580c8ba1cbf4ae53efe9f627595830856e57dbac2325ac17eb0c3dd0ec42102e6f227cc289c02 + languageName: node + linkType: hard + +"@nicolo-ribaudo/semver-v6@npm:^6.3.3": + version: 6.3.3 + resolution: "@nicolo-ribaudo/semver-v6@npm:6.3.3" + bin: + semver: bin/semver.js + checksum: 8290855b1591477d2298364541fda64fafd4acc110b387067a71c9b05f4105c0a4ac079857ae9cd107c42ee884e8724a406b5116f069575e02d7ab87a35a5272 languageName: node linkType: hard @@ -373,7 +462,7 @@ __metadata: languageName: node linkType: hard -"@nodelib/fs.walk@npm:^1.2.3": +"@nodelib/fs.walk@npm:^1.2.3, @nodelib/fs.walk@npm:^1.2.8": version: 1.2.8 resolution: "@nodelib/fs.walk@npm:1.2.8" dependencies: @@ -383,32 +472,28 @@ __metadata: languageName: node linkType: hard -"@npmcli/fs@npm:^1.0.0": - version: 1.1.0 - resolution: "@npmcli/fs@npm:1.1.0" +"@npmcli/fs@npm:^3.1.0": + version: 3.1.0 + resolution: "@npmcli/fs@npm:3.1.0" dependencies: - "@gar/promisify": ^1.0.1 semver: ^7.3.5 - checksum: e435b883b4f8da8c95a820f458cabb7d86582406eed5ad79fc689000d3e2df17e1f475c4903627272c001357cabc70d8b4c62520cbdae8cfab1dfdd51949f408 + checksum: a50a6818de5fc557d0b0e6f50ec780a7a02ab8ad07e5ac8b16bf519e0ad60a144ac64f97d05c443c3367235d337182e1d012bbac0eb8dbae8dc7b40b193efd0e languageName: node linkType: hard -"@npmcli/move-file@npm:^1.0.1": - version: 1.1.2 - resolution: "@npmcli/move-file@npm:1.1.2" - dependencies: - mkdirp: ^1.0.4 - rimraf: ^3.0.2 - checksum: c96381d4a37448ea280951e46233f7e541058cf57a57d4094dd4bdcaae43fa5872b5f2eb6bfb004591a68e29c5877abe3cdc210cb3588cbf20ab2877f31a7de7 +"@pkgjs/parseargs@npm:^0.11.0": + version: 0.11.0 + resolution: "@pkgjs/parseargs@npm:0.11.0" + checksum: 6ad6a00fc4f2f2cfc6bff76fb1d88b8ee20bc0601e18ebb01b6d4be583733a860239a521a7fbca73b612e66705078809483549d2b18f370eb346c5155c8e4a0f languageName: node linkType: hard "@sinonjs/commons@npm:^1, @sinonjs/commons@npm:^1.3.0, @sinonjs/commons@npm:^1.4.0, @sinonjs/commons@npm:^1.7.0": - version: 1.8.3 - resolution: "@sinonjs/commons@npm:1.8.3" + version: 1.8.6 + resolution: "@sinonjs/commons@npm:1.8.6" dependencies: type-detect: 4.0.8 - checksum: 6159726db5ce6bf9f2297f8427f7ca5b3dff45b31e5cee23496f1fa6ef0bb4eab878b23fb2c5e6446381f6a66aba4968ef2fc255c1180d753d4b8c271636a2e5 + checksum: 7d3f8c1e85f30cd4e83594fc19b7a657f14d49eb8d95a30095631ce15e906c869e0eff96c5b93dffea7490c00418b07f54582ba49c6560feb2a8c34c0b16832d languageName: node linkType: hard @@ -434,103 +519,111 @@ __metadata: linkType: hard "@sinonjs/text-encoding@npm:^0.7.1": - version: 0.7.1 - resolution: "@sinonjs/text-encoding@npm:0.7.1" - checksum: 130de0bb568c5f8a611ec21d1a4e3f80ab0c5ec333010f49cfc1adc5cba6d8808699c8a587a46b0f0b016a1f4c1389bc96141e773e8460fcbb441875b2e91ba7 + version: 0.7.2 + resolution: "@sinonjs/text-encoding@npm:0.7.2" + checksum: fe690002a32ba06906cf87e2e8fe84d1590294586f2a7fd180a65355b53660c155c3273d8011a5f2b77209b819aa7306678ae6e4aea0df014bd7ffd4bbbcf1ab languageName: node linkType: hard -"@tootallnate/once@npm:1": - version: 1.1.2 - resolution: "@tootallnate/once@npm:1.1.2" - checksum: e1fb1bbbc12089a0cb9433dc290f97bddd062deadb6178ce9bcb93bb7c1aecde5e60184bc7065aec42fe1663622a213493c48bbd4972d931aae48315f18e1be9 +"@tootallnate/once@npm:2": + version: 2.0.0 + resolution: "@tootallnate/once@npm:2.0.0" + checksum: ad87447820dd3f24825d2d947ebc03072b20a42bfc96cbafec16bff8bbda6c1a81fcb0be56d5b21968560c5359a0af4038a68ba150c3e1694fe4c109a063bed8 languageName: node linkType: hard "@tsconfig/node10@npm:^1.0.7": - version: 1.0.8 - resolution: "@tsconfig/node10@npm:1.0.8" - checksum: b8d5fffbc6b17ef64ef74f7fdbccee02a809a063ade785c3648dae59406bc207f70ea2c4296f92749b33019fa36a5ae716e42e49cc7f1bbf0fd147be0d6b970a + version: 1.0.9 + resolution: "@tsconfig/node10@npm:1.0.9" + checksum: a33ae4dc2a621c0678ac8ac4bceb8e512ae75dac65417a2ad9b022d9b5411e863c4c198b6ba9ef659e14b9fb609bbec680841a2e84c1172df7a5ffcf076539df languageName: node linkType: hard "@tsconfig/node12@npm:^1.0.7": - version: 1.0.9 - resolution: "@tsconfig/node12@npm:1.0.9" - checksum: a01b2400ab3582b86b589c6d31dcd0c0656f333adecde85d6d7d4086adb059808b82692380bb169546d189bf771ae21d02544a75b57bd6da4a5dd95f8567bec9 + version: 1.0.11 + resolution: "@tsconfig/node12@npm:1.0.11" + checksum: 5ce29a41b13e7897a58b8e2df11269c5395999e588b9a467386f99d1d26f6c77d1af2719e407621412520ea30517d718d5192a32403b8dfcc163bf33e40a338a languageName: node linkType: hard "@tsconfig/node14@npm:^1.0.0": - version: 1.0.1 - resolution: "@tsconfig/node14@npm:1.0.1" - checksum: 976345e896c0f059867f94f8d0f6ddb8b1844fb62bf36b727de8a9a68f024857e5db97ed51d3325e23e0616a5e48c034ff51a8d595b3fe7e955f3587540489be + version: 1.0.3 + resolution: "@tsconfig/node14@npm:1.0.3" + checksum: 19275fe80c4c8d0ad0abed6a96dbf00642e88b220b090418609c4376e1cef81bf16237bf170ad1b341452feddb8115d8dd2e5acdfdea1b27422071163dc9ba9d languageName: node linkType: hard "@tsconfig/node16@npm:^1.0.2": - version: 1.0.2 - resolution: "@tsconfig/node16@npm:1.0.2" - checksum: ca94d3639714672bbfd55f03521d3f56bb6a25479bd425da81faf21f13e1e9d15f40f97377dedbbf477a5841c5b0c8f4cd1b391f33553d750b9202c54c2c07aa + version: 1.0.4 + resolution: "@tsconfig/node16@npm:1.0.4" + checksum: 202319785901f942a6e1e476b872d421baec20cf09f4b266a1854060efbf78cde16a4d256e8bc949d31e6cd9a90f1e8ef8fb06af96a65e98338a2b6b0de0a0ff languageName: node linkType: hard "@types/json-schema@npm:^7.0.9": - version: 7.0.9 - resolution: "@types/json-schema@npm:7.0.9" - checksum: 259d0e25f11a21ba5c708f7ea47196bd396e379fddb79c76f9f4f62c945879dc21657904914313ec2754e443c5018ea8372362f323f30e0792897fdb2098a705 + version: 7.0.12 + resolution: "@types/json-schema@npm:7.0.12" + checksum: 00239e97234eeb5ceefb0c1875d98ade6e922bfec39dd365ec6bd360b5c2f825e612ac4f6e5f1d13601b8b30f378f15e6faa805a3a732f4a1bbe61915163d293 languageName: node linkType: hard "@types/lodash@npm:^4.14.176": - version: 4.14.178 - resolution: "@types/lodash@npm:4.14.178" - checksum: a69a04a60bfc5257c3130a554b4efa0c383f0141b7b3db8ab7cf07ad2a46ea085fce66d0242da41da7e5647b133d5dfb2c15add9cbed8d7fef955e4a1e5b3128 + version: 4.14.195 + resolution: "@types/lodash@npm:4.14.195" + checksum: 39b75ca635b3fa943d17d3d3aabc750babe4c8212485a4df166fe0516e39288e14b0c60afc6e21913cc0e5a84734633c71e617e2bd14eaa1cf51b8d7799c432e languageName: node linkType: hard "@types/mocha@npm:^9.1.0": - version: 9.1.0 - resolution: "@types/mocha@npm:9.1.0" - checksum: 21e1000dafcfe387c6812be41c44a47b48c27a74d5a70c3d5ef1bb5c88eadadfc74dba06e93f160e7248c8a57b3977b590f82504c801c9927816ecd4668023c0 + version: 9.1.1 + resolution: "@types/mocha@npm:9.1.1" + checksum: 516077c0acd9806dc78317f88aaac0df5aaf0bdc2f63dfdadeabdf0b0137953b6ca65472e6ff7c30bc93ce4e0ae76eae70e8d46764b9a8eae4877a928b6ef49a languageName: node linkType: hard "@types/node@npm:^16.11.6": - version: 16.11.22 - resolution: "@types/node@npm:16.11.22" - checksum: 9d879b9b0427e21a11e3162917553d5bc3c7d68d1ef4aa631512144801fe59bc3b4da5965e7ea7c2db99394487b543d4f2499b318e12392574802ac4f975b7c4 + version: 16.18.38 + resolution: "@types/node@npm:16.18.38" + checksum: a3baa141e49ce94486f083eea1240cf38479a73ba663e1bf3f52f85b466125821b6e3ea85ded38fde3901530aca4601291395a50eefcea533a4f3b45171bda28 + languageName: node + linkType: hard + +"@types/semver@npm:^7.3.12": + version: 7.5.0 + resolution: "@types/semver@npm:7.5.0" + checksum: 0a64b9b9c7424d9a467658b18dd70d1d781c2d6f033096a6e05762d20ebbad23c1b69b0083b0484722aabf35640b78ccc3de26368bcae1129c87e9df028a22e2 languageName: node linkType: hard "@types/sinon@npm:^10.0.6": - version: 10.0.11 - resolution: "@types/sinon@npm:10.0.11" + version: 10.0.15 + resolution: "@types/sinon@npm:10.0.15" dependencies: "@types/sinonjs__fake-timers": "*" - checksum: 196f3e26985dca5dfb593592e4b64463e536c047a9f43aa2b328b16024a3b0e3fb27b7a3f3972c6ef75749f55012737eb6c63a1c2e9782b7fe5cbbd25f75fd62 + checksum: cec6d7d9d5582ca3ac851b029d5d90451bfe6d376164253792a6eb6ddcd609a0411a7fac9ed92e1879e7d3ec091d2ea2e8dbb4f6140a1065439b81dc20cafa7c languageName: node linkType: hard "@types/sinonjs__fake-timers@npm:*": - version: 8.1.1 - resolution: "@types/sinonjs__fake-timers@npm:8.1.1" - checksum: ca09d54d47091d87020824a73f026300fa06b17cd9f2f9b9387f28b549364b141ef194ee28db762f6588de71d8febcd17f753163cb7ea116b8387c18e80ebd5c + version: 8.1.2 + resolution: "@types/sinonjs__fake-timers@npm:8.1.2" + checksum: bbc73a5ab6c0ec974929392f3d6e1e8db4ebad97ec506d785301e1c3d8a4f98a35b1aa95b97035daef02886fd8efd7788a2fa3ced2ec7105988bfd8dce61eedd languageName: node linkType: hard "@typescript-eslint/eslint-plugin@npm:^5.7.0": - version: 5.11.0 - resolution: "@typescript-eslint/eslint-plugin@npm:5.11.0" - dependencies: - "@typescript-eslint/scope-manager": 5.11.0 - "@typescript-eslint/type-utils": 5.11.0 - "@typescript-eslint/utils": 5.11.0 - debug: ^4.3.2 - functional-red-black-tree: ^1.0.1 - ignore: ^5.1.8 - regexpp: ^3.2.0 - semver: ^7.3.5 + version: 5.61.0 + resolution: "@typescript-eslint/eslint-plugin@npm:5.61.0" + dependencies: + "@eslint-community/regexpp": ^4.4.0 + "@typescript-eslint/scope-manager": 5.61.0 + "@typescript-eslint/type-utils": 5.61.0 + "@typescript-eslint/utils": 5.61.0 + debug: ^4.3.4 + graphemer: ^1.4.0 + ignore: ^5.2.0 + natural-compare-lite: ^1.4.0 + semver: ^7.3.7 tsutils: ^3.21.0 peerDependencies: "@typescript-eslint/parser": ^5.0.0 @@ -538,101 +631,104 @@ __metadata: peerDependenciesMeta: typescript: optional: true - checksum: fa546ba4397f3e693870c39d1e8df6feccb728a7092be6312b78806a64c4ff4648cff0462503d3e510e8b173b9704c19e78d2a7af790ab1c0309782e33a89c32 + checksum: d9e891fb43ccb75322fc40d58d02479f98bd3c962db71075438868b13f579643d714a24b5477a827be7ca2e7e9f6058c406241b6696a6395c6fcbd6de76e015c languageName: node linkType: hard "@typescript-eslint/parser@npm:^5.7.0": - version: 5.11.0 - resolution: "@typescript-eslint/parser@npm:5.11.0" + version: 5.61.0 + resolution: "@typescript-eslint/parser@npm:5.61.0" dependencies: - "@typescript-eslint/scope-manager": 5.11.0 - "@typescript-eslint/types": 5.11.0 - "@typescript-eslint/typescript-estree": 5.11.0 - debug: ^4.3.2 + "@typescript-eslint/scope-manager": 5.61.0 + "@typescript-eslint/types": 5.61.0 + "@typescript-eslint/typescript-estree": 5.61.0 + debug: ^4.3.4 peerDependencies: eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 peerDependenciesMeta: typescript: optional: true - checksum: 521b6e701d877dc0514c6a3992f4900aa6fea28ba7c0bc03c634dad2b50aa195401e45683dfebd9e8492a857cd84bba3b585d8fe8d0cd1d7e2720372c34c50a3 + checksum: 2422bca03ecc6830700aaa739ec46b8e9ab6c0a47a67f140dc6b62a42a8b98997e73bce52c6a010b8a9b461211c46ba865d5b7f680a7823cf5c245d3b61f7fd5 languageName: node linkType: hard -"@typescript-eslint/scope-manager@npm:5.11.0": - version: 5.11.0 - resolution: "@typescript-eslint/scope-manager@npm:5.11.0" +"@typescript-eslint/scope-manager@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/scope-manager@npm:5.61.0" dependencies: - "@typescript-eslint/types": 5.11.0 - "@typescript-eslint/visitor-keys": 5.11.0 - checksum: bf7feaed495ed4cafa1b89a2b73781b30061d019e1c1b3765dc8006e7f36b537f6f451e37c77400067771318b4f0c5915804084dc6299ea7c6ecde2daf0aca1c + "@typescript-eslint/types": 5.61.0 + "@typescript-eslint/visitor-keys": 5.61.0 + checksum: 6dfbb42c4b7d796ae3c395398bdfd2e5a4ae8aaf1448381278ecc39a1d1045af2cb452da5a00519d265bc1a5997523de22d5021acb4dbe1648502fe61512d3c6 languageName: node linkType: hard -"@typescript-eslint/type-utils@npm:5.11.0": - version: 5.11.0 - resolution: "@typescript-eslint/type-utils@npm:5.11.0" +"@typescript-eslint/type-utils@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/type-utils@npm:5.61.0" dependencies: - "@typescript-eslint/utils": 5.11.0 - debug: ^4.3.2 + "@typescript-eslint/typescript-estree": 5.61.0 + "@typescript-eslint/utils": 5.61.0 + debug: ^4.3.4 tsutils: ^3.21.0 peerDependencies: eslint: "*" peerDependenciesMeta: typescript: optional: true - checksum: fd570806d82874289ded6bfd90ff5414d4365b95b4a2e911f7ff2fee6e2c7675d0f2f71580c24cb8be733c3dfe2cd33eedff99ae2aa50f61b1b5af76499074eb + checksum: f0203fd48c6218f004dd73a9a71ba4cf97f015d0f13a7b3c821a3ba7ec814839bae270a1db589184ca7091fe54815a3171d1993e8a25200bf33e131bd6e855d4 languageName: node linkType: hard -"@typescript-eslint/types@npm:5.11.0": - version: 5.11.0 - resolution: "@typescript-eslint/types@npm:5.11.0" - checksum: b1531481da75a6c89510ad03f3db68e4797b25438bb902ee322bd1c154b83396016271cc00356dcdbc300a8ee421493aae803b8c716f36d7b4808fe045ae3a2a +"@typescript-eslint/types@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/types@npm:5.61.0" + checksum: d311ca2141f6bcb5f0f8f97ddbc218c9911e0735aaa30f0f2e64d518fb33568410754e1b04bf157175f8783504f8ec62a7ab53a66a18507f43edb1e21fe69e90 languageName: node linkType: hard -"@typescript-eslint/typescript-estree@npm:5.11.0": - version: 5.11.0 - resolution: "@typescript-eslint/typescript-estree@npm:5.11.0" +"@typescript-eslint/typescript-estree@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/typescript-estree@npm:5.61.0" dependencies: - "@typescript-eslint/types": 5.11.0 - "@typescript-eslint/visitor-keys": 5.11.0 - debug: ^4.3.2 - globby: ^11.0.4 + "@typescript-eslint/types": 5.61.0 + "@typescript-eslint/visitor-keys": 5.61.0 + debug: ^4.3.4 + globby: ^11.1.0 is-glob: ^4.0.3 - semver: ^7.3.5 + semver: ^7.3.7 tsutils: ^3.21.0 peerDependenciesMeta: typescript: optional: true - checksum: 7bda55501c586efd7f8065b4158016486d8af92b8419931fbea7cec9bfe074075de8cdebec8baa1ac8a5c3f973599b9dd44a51fced1792176e49cd60cc8e5442 + checksum: efe25a1b2774939c02cb9b388cf72efa672811f1c39a87ddd617937f63c2320551ce459ba69c6d022e33322594d40b9f2d2c6bc9937387718adc40dc5e57ea8e languageName: node linkType: hard -"@typescript-eslint/utils@npm:5.11.0": - version: 5.11.0 - resolution: "@typescript-eslint/utils@npm:5.11.0" +"@typescript-eslint/utils@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/utils@npm:5.61.0" dependencies: + "@eslint-community/eslint-utils": ^4.2.0 "@types/json-schema": ^7.0.9 - "@typescript-eslint/scope-manager": 5.11.0 - "@typescript-eslint/types": 5.11.0 - "@typescript-eslint/typescript-estree": 5.11.0 + "@types/semver": ^7.3.12 + "@typescript-eslint/scope-manager": 5.61.0 + "@typescript-eslint/types": 5.61.0 + "@typescript-eslint/typescript-estree": 5.61.0 eslint-scope: ^5.1.1 - eslint-utils: ^3.0.0 + semver: ^7.3.7 peerDependencies: eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 - checksum: 5ab1a15db1e0a2fbb857a8a16325459ad3d5239066f2641aa93ad9f7d08252d3a4ca6ae356c51cba1c6c81a65d84883436566b01932fa55b64a69796b950900d + checksum: 24efc1964e6c92db96fe0d9a390550e4f27e8f353e51a9b46bda03e6692ea5d40f398d539235a4ff0894e9e45dfcfb51df953ade2ae9d17a1421449625ce6f5a languageName: node linkType: hard -"@typescript-eslint/visitor-keys@npm:5.11.0": - version: 5.11.0 - resolution: "@typescript-eslint/visitor-keys@npm:5.11.0" +"@typescript-eslint/visitor-keys@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/visitor-keys@npm:5.61.0" dependencies: - "@typescript-eslint/types": 5.11.0 - eslint-visitor-keys: ^3.0.0 - checksum: 8f0b6fe1e86bc93825a137be3220f57e3a4bee410cca5d35963a0cd416750b31291a73c4294676d94ed0f5066b4cfb3a8f512d409881daa550d1645f4381eb21 + "@typescript-eslint/types": 5.61.0 + eslint-visitor-keys: ^3.3.0 + checksum: a8d589f61ddfc380787218da4d347e8f9aef0f82f4a93f1daee46786bda889a90961c7ec1b470db5e3261438a728fdfd956f5bda6ee2de22c4be2d2152d6e270 languageName: node linkType: hard @@ -643,14 +739,14 @@ __metadata: languageName: node linkType: hard -"abbrev@npm:1": +"abbrev@npm:^1.0.0": version: 1.1.1 resolution: "abbrev@npm:1.1.1" checksum: a4a97ec07d7ea112c517036882b2ac22f3109b7b19077dc656316d07d308438aac28e4d9746dc4d84bf6b1e75b4a7b0a5f3cb30592419f128ca9a8cee3bcfa17 languageName: node linkType: hard -"acorn-jsx@npm:^5.3.1": +"acorn-jsx@npm:^5.3.2": version: 5.3.2 resolution: "acorn-jsx@npm:5.3.2" peerDependencies: @@ -666,12 +762,12 @@ __metadata: languageName: node linkType: hard -"acorn@npm:^8.4.1, acorn@npm:^8.7.0": - version: 8.7.0 - resolution: "acorn@npm:8.7.0" +"acorn@npm:^8.4.1, acorn@npm:^8.9.0": + version: 8.10.0 + resolution: "acorn@npm:8.10.0" bin: acorn: bin/acorn - checksum: e0f79409d68923fbf1aa6d4166f3eedc47955320d25c89a20cc822e6ba7c48c5963d5bc657bc242d68f7a4ac9faf96eef033e8f73656da6c640d4219935fdfd0 + checksum: 538ba38af0cc9e5ef983aee196c4b8b4d87c0c94532334fa7e065b2c8a1f85863467bb774231aae91613fcda5e68740c15d97b1967ae3394d20faddddd8af61d languageName: node linkType: hard @@ -684,14 +780,14 @@ __metadata: languageName: node linkType: hard -"agentkeepalive@npm:^4.1.3": - version: 4.2.0 - resolution: "agentkeepalive@npm:4.2.0" +"agentkeepalive@npm:^4.2.1": + version: 4.3.0 + resolution: "agentkeepalive@npm:4.3.0" dependencies: debug: ^4.1.0 - depd: ^1.1.2 + depd: ^2.0.0 humanize-ms: ^1.2.1 - checksum: 89806f83ceebbcaabf6bd581a8dce4870910fd2a11f66df8f505b4cd4ce4ca5ab9e6eec8d11ce8531a6b60f6748b75b0775e0e2fa33871503ef00d535418a19a + checksum: 982453aa44c11a06826c836025e5162c846e1200adb56f2d075400da7d32d87021b3b0a58768d949d824811f5654223d5a8a3dad120921a2439625eb847c6260 languageName: node linkType: hard @@ -731,6 +827,13 @@ __metadata: languageName: node linkType: hard +"ansi-regex@npm:^6.0.1": + version: 6.0.1 + resolution: "ansi-regex@npm:6.0.1" + checksum: 1ff8b7667cded1de4fa2c9ae283e979fc87036864317da86a2e546725f96406746411d0d85e87a2d12fa5abd715d90006de7fa4fa0477c92321ad3b4c7d4e169 + languageName: node + linkType: hard + "ansi-styles@npm:^3.2.1": version: 3.2.1 resolution: "ansi-styles@npm:3.2.1" @@ -749,13 +852,20 @@ __metadata: languageName: node linkType: hard +"ansi-styles@npm:^6.1.0": + version: 6.2.1 + resolution: "ansi-styles@npm:6.2.1" + checksum: ef940f2f0ced1a6347398da88a91da7930c33ecac3c77b72c5905f8b8fe402c52e6fde304ff5347f616e27a742da3f1dc76de98f6866c69251ad0b07a66776d9 + languageName: node + linkType: hard + "anymatch@npm:~3.1.2": - version: 3.1.2 - resolution: "anymatch@npm:3.1.2" + version: 3.1.3 + resolution: "anymatch@npm:3.1.3" dependencies: normalize-path: ^3.0.0 picomatch: ^2.0.4 - checksum: 985163db2292fac9e5a1e072bf99f1b5baccf196e4de25a0b0b81865ebddeb3b3eb4480734ef0a2ac8c002845396b91aa89121f5b84f93981a4658164a9ec6e9 + checksum: 3e044fd6d1d26545f235a9fe4d7a534e2029d8e59fa7fd9f2a6eb21230f6b5380ea1eaf55136e60cbf8e613544b3b766e7a6fa2102e2a3a117505466e3025dc2 languageName: node linkType: hard @@ -782,13 +892,13 @@ __metadata: languageName: node linkType: hard -"are-we-there-yet@npm:^2.0.0": - version: 2.0.0 - resolution: "are-we-there-yet@npm:2.0.0" +"are-we-there-yet@npm:^3.0.0": + version: 3.0.1 + resolution: "are-we-there-yet@npm:3.0.1" dependencies: delegates: ^1.0.0 readable-stream: ^3.6.0 - checksum: 6c80b4fd04ecee6ba6e737e0b72a4b41bdc64b7d279edfc998678567ff583c8df27e27523bc789f2c99be603ffa9eaa612803da1d886962d2086e7ff6fa90c7c + checksum: 52590c24860fa7173bedeb69a4c05fb573473e860197f618b9a28432ee4379049336727ae3a1f9c4cb083114601c1140cee578376164d0e651217a9843f9fe83 languageName: node linkType: hard @@ -862,7 +972,16 @@ __metadata: languageName: node linkType: hard -"braces@npm:^3.0.1, braces@npm:~3.0.2": +"brace-expansion@npm:^2.0.1": + version: 2.0.1 + resolution: "brace-expansion@npm:2.0.1" + dependencies: + balanced-match: ^1.0.0 + checksum: a61e7cd2e8a8505e9f0036b3b6108ba5e926b4b55089eeb5550cd04a471fe216c96d4fe7e4c7f995c728c554ae20ddfc4244cad10aef255e72b62930afd233d1 + languageName: node + linkType: hard + +"braces@npm:^3.0.2, braces@npm:~3.0.2": version: 3.0.2 resolution: "braces@npm:3.0.2" dependencies: @@ -878,44 +997,37 @@ __metadata: languageName: node linkType: hard -"browserslist@npm:^4.17.5": - version: 4.19.1 - resolution: "browserslist@npm:4.19.1" +"browserslist@npm:^4.21.9": + version: 4.21.9 + resolution: "browserslist@npm:4.21.9" dependencies: - caniuse-lite: ^1.0.30001286 - electron-to-chromium: ^1.4.17 - escalade: ^3.1.1 - node-releases: ^2.0.1 - picocolors: ^1.0.0 + caniuse-lite: ^1.0.30001503 + electron-to-chromium: ^1.4.431 + node-releases: ^2.0.12 + update-browserslist-db: ^1.0.11 bin: browserslist: cli.js - checksum: c0777fd483691638fd6801e16c9d809e1d65f6d2b06db2e806654be51045cbab1452a89841a2c5caea2cbe19d621b4f1d391cffbb24512aa33280039ab345875 + checksum: 80d3820584e211484ad1b1a5cfdeca1dd00442f47be87e117e1dda34b628c87e18b81ae7986fa5977b3e6a03154f6d13cd763baa6b8bf5dd9dd19f4926603698 languageName: node linkType: hard -"cacache@npm:^15.2.0": - version: 15.3.0 - resolution: "cacache@npm:15.3.0" +"cacache@npm:^17.0.0": + version: 17.1.3 + resolution: "cacache@npm:17.1.3" dependencies: - "@npmcli/fs": ^1.0.0 - "@npmcli/move-file": ^1.0.1 - chownr: ^2.0.0 - fs-minipass: ^2.0.0 - glob: ^7.1.4 - infer-owner: ^1.0.4 - lru-cache: ^6.0.0 - minipass: ^3.1.1 + "@npmcli/fs": ^3.1.0 + fs-minipass: ^3.0.0 + glob: ^10.2.2 + lru-cache: ^7.7.1 + minipass: ^5.0.0 minipass-collect: ^1.0.2 minipass-flush: ^1.0.5 - minipass-pipeline: ^1.2.2 - mkdirp: ^1.0.3 + minipass-pipeline: ^1.2.4 p-map: ^4.0.0 - promise-inflight: ^1.0.1 - rimraf: ^3.0.2 - ssri: ^8.0.1 - tar: ^6.0.2 - unique-filename: ^1.1.1 - checksum: a07327c27a4152c04eb0a831c63c00390d90f94d51bb80624a66f4e14a6b6360bbf02a84421267bd4d00ca73ac9773287d8d7169e8d2eafe378d2ce140579db8 + ssri: ^10.0.0 + tar: ^6.1.11 + unique-filename: ^3.0.0 + checksum: 385756781e1e21af089160d89d7462b7ed9883c978e848c7075b90b73cb823680e66092d61513050164588387d2ca87dd6d910e28d64bc13a9ac82cd8580c796 languageName: node linkType: hard @@ -952,10 +1064,10 @@ __metadata: languageName: node linkType: hard -"caniuse-lite@npm:^1.0.30001286": - version: 1.0.30001309 - resolution: "caniuse-lite@npm:1.0.30001309" - checksum: 95093d01dc0880a371fe6aaf54cccb01a979933181a3aad6fc08e80c4601e27e1578a44d8ab6c1d3d58526ed2a917ce5e643c0e8299a0330cdac7bc8a7b5d7f0 +"caniuse-lite@npm:^1.0.30001503": + version: 1.0.30001513 + resolution: "caniuse-lite@npm:1.0.30001513" + checksum: 7d783f4f40584e7bdeda3f3abc23ffff21f14c37e1fadf1a6b3d2e299727fe9d5a61096101d9d4e4174f881d4ff4c62204fc41f3bc950f4da1b0edfdea025fa4 languageName: node linkType: hard @@ -1067,7 +1179,7 @@ __metadata: languageName: node linkType: hard -"color-support@npm:^1.1.2": +"color-support@npm:^1.1.3": version: 1.1.3 resolution: "color-support@npm:1.1.3" bin: @@ -1090,7 +1202,7 @@ __metadata: languageName: node linkType: hard -"console-control-strings@npm:^1.0.0, console-control-strings@npm:^1.1.0": +"console-control-strings@npm:^1.1.0": version: 1.1.0 resolution: "console-control-strings@npm:1.1.0" checksum: 8755d76787f94e6cf79ce4666f0c5519906d7f5b02d4b884cf41e11dcd759ed69c57da0670afd9236d229a46e0f9cf519db0cd829c6dca820bb5a5c3def584ed @@ -1098,11 +1210,9 @@ __metadata: linkType: hard "convert-source-map@npm:^1.7.0": - version: 1.8.0 - resolution: "convert-source-map@npm:1.8.0" - dependencies: - safe-buffer: ~5.1.1 - checksum: 985d974a2d33e1a2543ada51c93e1ba2f73eaed608dc39f229afc78f71dcc4c8b7d7c684aa647e3c6a3a204027444d69e53e169ce94e8d1fa8d7dee80c9c8fed + version: 1.9.0 + resolution: "convert-source-map@npm:1.9.0" + checksum: dc55a1f28ddd0e9485ef13565f8f756b342f9a46c4ae18b843fe3c30c675d058d6a4823eff86d472f187b176f0adf51ea7b69ea38be34be4a63cbbf91b0593c8 languageName: node linkType: hard @@ -1113,7 +1223,7 @@ __metadata: languageName: node linkType: hard -"cross-spawn@npm:^7.0.0, cross-spawn@npm:^7.0.2": +"cross-spawn@npm:^7.0.0, cross-spawn@npm:^7.0.2, cross-spawn@npm:^7.0.3": version: 7.0.3 resolution: "cross-spawn@npm:7.0.3" dependencies: @@ -1124,7 +1234,19 @@ __metadata: languageName: node linkType: hard -"debug@npm:4, debug@npm:4.3.3, debug@npm:^4.1.0, debug@npm:^4.1.1, debug@npm:^4.3.1, debug@npm:^4.3.2": +"debug@npm:4, debug@npm:^4.1.0, debug@npm:^4.1.1, debug@npm:^4.3.2, debug@npm:^4.3.3, debug@npm:^4.3.4": + version: 4.3.4 + resolution: "debug@npm:4.3.4" + dependencies: + ms: 2.1.2 + peerDependenciesMeta: + supports-color: + optional: true + checksum: 3dbad3f94ea64f34431a9cbf0bafb61853eda57bff2880036153438f50fb5a84f27683ba0d8e5426bf41a8c6ff03879488120cf5b3a761e77953169c0600a708 + languageName: node + linkType: hard + +"debug@npm:4.3.3": version: 4.3.3 resolution: "debug@npm:4.3.3" dependencies: @@ -1158,11 +1280,11 @@ __metadata: linkType: hard "default-require-extensions@npm:^3.0.0": - version: 3.0.0 - resolution: "default-require-extensions@npm:3.0.0" + version: 3.0.1 + resolution: "default-require-extensions@npm:3.0.1" dependencies: strip-bom: ^4.0.0 - checksum: 0b5bdb6786ebb0ff6ef55386f37c8d221963fbbd3009588fe71032c85ca16da05eff2ad01bfe9bfc8bac5ce95a18f66b38c50d454482e3e9d2de1142424a3e7c + checksum: 45882fc971dd157faf6716ced04c15cf252c0a2d6f5c5844b66ca49f46ed03396a26cd940771aa569927aee22923a961bab789e74b25aabc94d90742c9dd1217 languageName: node linkType: hard @@ -1173,10 +1295,10 @@ __metadata: languageName: node linkType: hard -"depd@npm:^1.1.2": - version: 1.1.2 - resolution: "depd@npm:1.1.2" - checksum: 6b406620d269619852885ce15965272b829df6f409724415e0002c8632ab6a8c0a08ec1f0bd2add05dc7bd7507606f7e2cc034fa24224ab829580040b835ecd9 +"depd@npm:^2.0.0": + version: 2.0.0 + resolution: "depd@npm:2.0.0" + checksum: abbe19c768c97ee2eed6282d8ce3031126662252c58d711f646921c9623f9052e3e1906443066beec1095832f534e57c523b7333f8e7e0d93051ab6baef5ab3a languageName: node linkType: hard @@ -1219,10 +1341,17 @@ __metadata: languageName: node linkType: hard -"electron-to-chromium@npm:^1.4.17": - version: 1.4.66 - resolution: "electron-to-chromium@npm:1.4.66" - checksum: 336b02aff50f221c4df2daf4268eff32bb9ef90c9962bce46af7a0ed9f85cad74c19cdc71eddb85a5e5bd2fb94a43eb0c3720679d2e99294c33dd2d03aace013 +"eastasianwidth@npm:^0.2.0": + version: 0.2.0 + resolution: "eastasianwidth@npm:0.2.0" + checksum: 7d00d7cd8e49b9afa762a813faac332dee781932d6f2c848dc348939c4253f1d4564341b7af1d041853bc3f32c2ef141b58e0a4d9862c17a7f08f68df1e0f1ed + languageName: node + linkType: hard + +"electron-to-chromium@npm:^1.4.431": + version: 1.4.453 + resolution: "electron-to-chromium@npm:1.4.453" + checksum: dcd354388b2b60fb0158a6daf7a3a93796b9f6e0045bc507021bcbbf72790cb94c5bb549f699150e18d090321bca0583d729bc479d2d48a0c94a29b1a2f0165e languageName: node linkType: hard @@ -1233,7 +1362,14 @@ __metadata: languageName: node linkType: hard -"encoding@npm:^0.1.12": +"emoji-regex@npm:^9.2.2": + version: 9.2.2 + resolution: "emoji-regex@npm:9.2.2" + checksum: 8487182da74aabd810ac6d6f1994111dfc0e331b01271ae01ec1eb0ad7b5ecc2bbbbd2f053c05cb55a1ac30449527d819bbfbf0e3de1023db308cbcb47f86601 + languageName: node + linkType: hard + +"encoding@npm:^0.1.13": version: 0.1.13 resolution: "encoding@npm:0.1.13" dependencies: @@ -1285,13 +1421,13 @@ __metadata: linkType: hard "eslint-config-prettier@npm:^8.3.0": - version: 8.3.0 - resolution: "eslint-config-prettier@npm:8.3.0" + version: 8.8.0 + resolution: "eslint-config-prettier@npm:8.8.0" peerDependencies: eslint: ">=7.0.0" bin: eslint-config-prettier: bin/cli.js - checksum: df4cea3032671995bb5ab07e016169072f7fa59f44a53251664d9ca60951b66cdc872683b5c6a3729c91497c11490ca44a79654b395dd6756beb0c3903a37196 + checksum: 1e94c3882c4d5e41e1dcfa2c368dbccbfe3134f6ac7d40101644d3bfbe3eb2f2ffac757f3145910b5eacf20c0e85e02b91293d3126d770cbf3dc390b3564681c languageName: node linkType: hard @@ -1312,94 +1448,80 @@ __metadata: languageName: node linkType: hard -"eslint-scope@npm:^7.1.0": - version: 7.1.0 - resolution: "eslint-scope@npm:7.1.0" +"eslint-scope@npm:^7.2.0": + version: 7.2.0 + resolution: "eslint-scope@npm:7.2.0" dependencies: esrecurse: ^4.3.0 estraverse: ^5.2.0 - checksum: 2070470a0725438ed47075b2574a4c03cf59aa32648da8cff9e3548c84f6b0079cfdb9ee1dd7ab0bfe97011f64b2af5bfd4b69cf14a1292130dec661eec7914a - languageName: node - linkType: hard - -"eslint-utils@npm:^3.0.0": - version: 3.0.0 - resolution: "eslint-utils@npm:3.0.0" - dependencies: - eslint-visitor-keys: ^2.0.0 - peerDependencies: - eslint: ">=5" - checksum: 0668fe02f5adab2e5a367eee5089f4c39033af20499df88fe4e6aba2015c20720404d8c3d6349b6f716b08fdf91b9da4e5d5481f265049278099c4c836ccb619 - languageName: node - linkType: hard - -"eslint-visitor-keys@npm:^2.0.0": - version: 2.1.0 - resolution: "eslint-visitor-keys@npm:2.1.0" - checksum: e3081d7dd2611a35f0388bbdc2f5da60b3a3c5b8b6e928daffff7391146b434d691577aa95064c8b7faad0b8a680266bcda0a42439c18c717b80e6718d7e267d + checksum: 64591a2d8b244ade9c690b59ef238a11d5c721a98bcee9e9f445454f442d03d3e04eda88e95a4daec558220a99fa384309d9faae3d459bd40e7a81b4063980ae languageName: node linkType: hard -"eslint-visitor-keys@npm:^3.0.0, eslint-visitor-keys@npm:^3.1.0, eslint-visitor-keys@npm:^3.2.0": - version: 3.2.0 - resolution: "eslint-visitor-keys@npm:3.2.0" - checksum: fdadbb26f9e6417d3db7ad4f00bb0d573b6031c32fa72e8cdae32d038223faaeddff2ee443c90cb489bf774e75bff765c00912b8f9106d65e4f202ccd78c1b18 +"eslint-visitor-keys@npm:^3.3.0, eslint-visitor-keys@npm:^3.4.1": + version: 3.4.1 + resolution: "eslint-visitor-keys@npm:3.4.1" + checksum: f05121d868202736b97de7d750847a328fcfa8593b031c95ea89425333db59676ac087fa905eba438d0a3c5769632f828187e0c1a0d271832a2153c1d3661c2c languageName: node linkType: hard "eslint@npm:^8.2.0": - version: 8.8.0 - resolution: "eslint@npm:8.8.0" - dependencies: - "@eslint/eslintrc": ^1.0.5 - "@humanwhocodes/config-array": ^0.9.2 + version: 8.44.0 + resolution: "eslint@npm:8.44.0" + dependencies: + "@eslint-community/eslint-utils": ^4.2.0 + "@eslint-community/regexpp": ^4.4.0 + "@eslint/eslintrc": ^2.1.0 + "@eslint/js": 8.44.0 + "@humanwhocodes/config-array": ^0.11.10 + "@humanwhocodes/module-importer": ^1.0.1 + "@nodelib/fs.walk": ^1.2.8 ajv: ^6.10.0 chalk: ^4.0.0 cross-spawn: ^7.0.2 debug: ^4.3.2 doctrine: ^3.0.0 escape-string-regexp: ^4.0.0 - eslint-scope: ^7.1.0 - eslint-utils: ^3.0.0 - eslint-visitor-keys: ^3.2.0 - espree: ^9.3.0 - esquery: ^1.4.0 + eslint-scope: ^7.2.0 + eslint-visitor-keys: ^3.4.1 + espree: ^9.6.0 + esquery: ^1.4.2 esutils: ^2.0.2 fast-deep-equal: ^3.1.3 file-entry-cache: ^6.0.1 - functional-red-black-tree: ^1.0.1 - glob-parent: ^6.0.1 - globals: ^13.6.0 + find-up: ^5.0.0 + glob-parent: ^6.0.2 + globals: ^13.19.0 + graphemer: ^1.4.0 ignore: ^5.2.0 import-fresh: ^3.0.0 imurmurhash: ^0.1.4 is-glob: ^4.0.0 + is-path-inside: ^3.0.3 js-yaml: ^4.1.0 json-stable-stringify-without-jsonify: ^1.0.1 levn: ^0.4.1 lodash.merge: ^4.6.2 - minimatch: ^3.0.4 + minimatch: ^3.1.2 natural-compare: ^1.4.0 - optionator: ^0.9.1 - regexpp: ^3.2.0 + optionator: ^0.9.3 strip-ansi: ^6.0.1 strip-json-comments: ^3.1.0 text-table: ^0.2.0 - v8-compile-cache: ^2.0.3 bin: eslint: bin/eslint.js - checksum: 41a7e85bf84cf9f2d758ef3e8d08020a39a2836703728b59535684681349bd021c2c6e24174462b844a914870d707d2151e0371198899d957b444de91adaa435 + checksum: d06309ce4aafb9d27d558c8e5e5aa5cba3bbec3ce8ceccbc7d4b7a35f2b67fd40189159155553270e2e6febeb69bd8a3b60d6241c8f5ddc2ef1702ccbd328501 languageName: node linkType: hard -"espree@npm:^9.2.0, espree@npm:^9.3.0": - version: 9.3.0 - resolution: "espree@npm:9.3.0" +"espree@npm:^9.6.0": + version: 9.6.0 + resolution: "espree@npm:9.6.0" dependencies: - acorn: ^8.7.0 - acorn-jsx: ^5.3.1 - eslint-visitor-keys: ^3.1.0 - checksum: c0f1885c4eab652f9be08eb9228cea0df046b559b29d4aed8d6590ea9bd60177d4cb245d204a6f737a79a096861bb4ab8e480aeb8c1dbafef5beec1157353ce4 + acorn: ^8.9.0 + acorn-jsx: ^5.3.2 + eslint-visitor-keys: ^3.4.1 + checksum: 1287979510efb052a6a97c73067ea5d0a40701b29adde87bbe2d3eb1667e39ca55e8129e20e2517fed3da570150e7ef470585228459a8f3e3755f45007a1c662 languageName: node linkType: hard @@ -1413,12 +1535,12 @@ __metadata: languageName: node linkType: hard -"esquery@npm:^1.4.0": - version: 1.4.0 - resolution: "esquery@npm:1.4.0" +"esquery@npm:^1.4.2": + version: 1.5.0 + resolution: "esquery@npm:1.5.0" dependencies: estraverse: ^5.1.0 - checksum: a0807e17abd7fbe5fbd4fab673038d6d8a50675cdae6b04fbaa520c34581be0c5fa24582990e8acd8854f671dd291c78bb2efb9e0ed5b62f33bac4f9cf820210 + checksum: aefb0d2596c230118656cd4ec7532d447333a410a48834d80ea648b1e7b5c9bc9ed8b5e33a89cb04e487b60d622f44cf5713bf4abed7c97343edefdc84a35900 languageName: node linkType: hard @@ -1452,6 +1574,13 @@ __metadata: languageName: node linkType: hard +"exponential-backoff@npm:^3.1.1": + version: 3.1.1 + resolution: "exponential-backoff@npm:3.1.1" + checksum: 3d21519a4f8207c99f7457287291316306255a328770d320b401114ec8481986e4e467e854cb9914dd965e0a1ca810a23ccb559c642c88f4c7f55c55778a9b48 + languageName: node + linkType: hard + "fast-deep-equal@npm:^3.1.1, fast-deep-equal@npm:^3.1.3": version: 3.1.3 resolution: "fast-deep-equal@npm:3.1.3" @@ -1460,15 +1589,15 @@ __metadata: linkType: hard "fast-glob@npm:^3.2.9": - version: 3.2.11 - resolution: "fast-glob@npm:3.2.11" + version: 3.3.0 + resolution: "fast-glob@npm:3.3.0" dependencies: "@nodelib/fs.stat": ^2.0.2 "@nodelib/fs.walk": ^1.2.3 glob-parent: ^5.1.2 merge2: ^1.3.0 micromatch: ^4.0.4 - checksum: f473105324a7780a20c06de842e15ddbb41d3cb7e71d1e4fe6e8373204f22245d54f5ab9e2061e6a1c613047345954d29b022e0e76f5c28b1df9858179a0e6d7 + checksum: 20df62be28eb5426fe8e40e0d05601a63b1daceb7c3d87534afcad91bdcf1e4b1743cf2d5247d6e225b120b46df0b9053a032b2691ba34ee121e033acd81f547 languageName: node linkType: hard @@ -1487,11 +1616,11 @@ __metadata: linkType: hard "fastq@npm:^1.6.0": - version: 1.13.0 - resolution: "fastq@npm:1.13.0" + version: 1.15.0 + resolution: "fastq@npm:1.15.0" dependencies: reusify: ^1.0.4 - checksum: 32cf15c29afe622af187d12fc9cd93e160a0cb7c31a3bb6ace86b7dea3b28e7b72acde89c882663f307b2184e14782c6c664fa315973c03626c7d4bff070bb0b + checksum: 0170e6bfcd5d57a70412440b8ef600da6de3b2a6c5966aeaf0a852d542daff506a0ee92d6de7679d1de82e644bce69d7a574a6c93f0b03964b5337eed75ada1a languageName: node linkType: hard @@ -1524,7 +1653,7 @@ __metadata: languageName: node linkType: hard -"find-up@npm:5.0.0": +"find-up@npm:5.0.0, find-up@npm:^5.0.0": version: 5.0.0 resolution: "find-up@npm:5.0.0" dependencies: @@ -1564,19 +1693,19 @@ __metadata: linkType: hard "flatted@npm:^3.1.0": - version: 3.2.5 - resolution: "flatted@npm:3.2.5" - checksum: 3c436e9695ccca29620b4be5671dd72e5dd0a7500e0856611b7ca9bd8169f177f408c3b9abfa78dfe1493ee2d873e2c119080a8a9bee4e1a186a9e60ca6c89f1 + version: 3.2.7 + resolution: "flatted@npm:3.2.7" + checksum: 427633049d55bdb80201c68f7eb1cbd533e03eac541f97d3aecab8c5526f12a20ccecaeede08b57503e772c769e7f8680b37e8d482d1e5f8d7e2194687f9ea35 languageName: node linkType: hard "follow-redirects@npm:^1.14.4": - version: 1.14.8 - resolution: "follow-redirects@npm:1.14.8" + version: 1.15.2 + resolution: "follow-redirects@npm:1.15.2" peerDependenciesMeta: debug: optional: true - checksum: 40c67899c2e3149a27e8b6498a338ff27f39fe138fde8d7f0756cb44b073ba0bfec3d52af28f20c5bdd67263d564d0d8d7b5efefd431de95c18c42f7b4aef457 + checksum: faa66059b66358ba65c234c2f2a37fcec029dc22775f35d9ad6abac56003268baf41e55f9ee645957b32c7d9f62baf1f0b906e68267276f54ec4b4c597c2b190 languageName: node linkType: hard @@ -1590,6 +1719,16 @@ __metadata: languageName: node linkType: hard +"foreground-child@npm:^3.1.0": + version: 3.1.1 + resolution: "foreground-child@npm:3.1.1" + dependencies: + cross-spawn: ^7.0.0 + signal-exit: ^4.0.1 + checksum: 139d270bc82dc9e6f8bc045fe2aae4001dc2472157044fdfad376d0a3457f77857fa883c1c8b21b491c6caade9a926a4bed3d3d2e8d3c9202b151a4cbbd0bcd5 + languageName: node + linkType: hard + "fromentries@npm:^1.2.0": version: 1.3.2 resolution: "fromentries@npm:1.3.2" @@ -1606,6 +1745,15 @@ __metadata: languageName: node linkType: hard +"fs-minipass@npm:^3.0.0": + version: 3.0.2 + resolution: "fs-minipass@npm:3.0.2" + dependencies: + minipass: ^5.0.0 + checksum: e9cc0e1f2d01c6f6f62f567aee59530aba65c6c7b2ae88c5027bc34c711ebcfcfaefd0caf254afa6adfe7d1fba16bc2537508a6235196bac7276747d078aef0a + languageName: node + linkType: hard + "fs.realpath@npm:^1.0.0": version: 1.0.0 resolution: "fs.realpath@npm:1.0.0" @@ -1632,27 +1780,19 @@ __metadata: languageName: node linkType: hard -"functional-red-black-tree@npm:^1.0.1": - version: 1.0.1 - resolution: "functional-red-black-tree@npm:1.0.1" - checksum: ca6c170f37640e2d94297da8bb4bf27a1d12bea3e00e6a3e007fd7aa32e37e000f5772acf941b4e4f3cf1c95c3752033d0c509af157ad8f526e7f00723b9eb9f - languageName: node - linkType: hard - -"gauge@npm:^4.0.0": - version: 4.0.0 - resolution: "gauge@npm:4.0.0" +"gauge@npm:^4.0.3": + version: 4.0.4 + resolution: "gauge@npm:4.0.4" dependencies: - ansi-regex: ^5.0.1 aproba: ^1.0.3 || ^2.0.0 - color-support: ^1.1.2 - console-control-strings: ^1.0.0 + color-support: ^1.1.3 + console-control-strings: ^1.1.0 has-unicode: ^2.0.1 - signal-exit: ^3.0.0 + signal-exit: ^3.0.7 string-width: ^4.2.3 strip-ansi: ^6.0.1 - wide-align: ^1.1.2 - checksum: 637b34c84f518defa89319dbef68211a24e9302182ad2a619e3be1be5b7dcf2a962c8359e889294af667440f4722e7e6e61671859e00bd8ec280a136ded89b25 + wide-align: ^1.1.5 + checksum: 788b6bfe52f1dd8e263cda800c26ac0ca2ff6de0b6eee2fe0d9e3abf15e149b651bd27bf5226be10e6e3edb5c4e5d5985a5a1a98137e7a892f75eff76467ad2d languageName: node linkType: hard @@ -1686,7 +1826,7 @@ __metadata: languageName: node linkType: hard -"glob-parent@npm:^6.0.1": +"glob-parent@npm:^6.0.2": version: 6.0.2 resolution: "glob-parent@npm:6.0.2" dependencies: @@ -1695,7 +1835,7 @@ __metadata: languageName: node linkType: hard -"glob@npm:7.2.0, glob@npm:^7.1.3, glob@npm:^7.1.4, glob@npm:^7.1.6": +"glob@npm:7.2.0": version: 7.2.0 resolution: "glob@npm:7.2.0" dependencies: @@ -1709,6 +1849,35 @@ __metadata: languageName: node linkType: hard +"glob@npm:^10.2.2": + version: 10.3.1 + resolution: "glob@npm:10.3.1" + dependencies: + foreground-child: ^3.1.0 + jackspeak: ^2.0.3 + minimatch: ^9.0.1 + minipass: ^5.0.0 || ^6.0.2 + path-scurry: ^1.10.0 + bin: + glob: dist/cjs/src/bin.js + checksum: 19c8c2805658b1002fecf0722cd609a33153d756a0d5260676bd0e9c5e6ef889ec9cce6d3dac0411aa90bce8de3d14f25b6f5589a3292582cccbfeddd0e98cc4 + languageName: node + linkType: hard + +"glob@npm:^7.1.3, glob@npm:^7.1.4, glob@npm:^7.1.6": + version: 7.2.3 + resolution: "glob@npm:7.2.3" + dependencies: + fs.realpath: ^1.0.0 + inflight: ^1.0.4 + inherits: 2 + minimatch: ^3.1.1 + once: ^1.3.0 + path-is-absolute: ^1.0.0 + checksum: 29452e97b38fa704dabb1d1045350fb2467cf0277e155aa9ff7077e90ad81d1ea9d53d3ee63bd37c05b09a065e90f16aec4a65f5b8de401d1dac40bc5605d133 + languageName: node + linkType: hard + "globals@npm:^11.1.0": version: 11.12.0 resolution: "globals@npm:11.12.0" @@ -1716,16 +1885,16 @@ __metadata: languageName: node linkType: hard -"globals@npm:^13.6.0, globals@npm:^13.9.0": - version: 13.12.1 - resolution: "globals@npm:13.12.1" +"globals@npm:^13.19.0": + version: 13.20.0 + resolution: "globals@npm:13.20.0" dependencies: type-fest: ^0.20.2 - checksum: cf7877629c8f2a293b0a7d09d1dcce7f2d426ec2528600c481c5b3f3d070b0a120eb2499439ac0404990fb8a5742c0165b1bf1f52603364001ddc89bea3dda24 + checksum: ad1ecf914bd051325faad281d02ea2c0b1df5d01bd94d368dcc5513340eac41d14b3c61af325768e3c7f8d44576e72780ec0b6f2d366121f8eec6e03c3a3b97a languageName: node linkType: hard -"globby@npm:^11.0.4": +"globby@npm:^11.1.0": version: 11.1.0 resolution: "globby@npm:11.1.0" dependencies: @@ -1740,9 +1909,16 @@ __metadata: linkType: hard "graceful-fs@npm:^4.1.15, graceful-fs@npm:^4.2.6": - version: 4.2.9 - resolution: "graceful-fs@npm:4.2.9" - checksum: 68ea4e07ff2c041ada184f9278b830375f8e0b75154e3f080af6b70f66172fabb4108d19b3863a96b53fc068a310b9b6493d86d1291acc5f3861eb4b79d26ad6 + version: 4.2.11 + resolution: "graceful-fs@npm:4.2.11" + checksum: ac85f94da92d8eb6b7f5a8b20ce65e43d66761c55ce85ac96df6865308390da45a8d3f0296dd3a663de65d30ba497bd46c696cc1e248c72b13d6d567138a4fc7 + languageName: node + linkType: hard + +"graphemer@npm:^1.4.0": + version: 1.4.0 + resolution: "graphemer@npm:1.4.0" + checksum: bab8f0be9b568857c7bec9fda95a89f87b783546d02951c40c33f84d05bb7da3fd10f863a9beb901463669b6583173a8c8cc6d6b306ea2b9b9d5d3d943c3a673 languageName: node linkType: hard @@ -1807,31 +1983,31 @@ __metadata: languageName: node linkType: hard -"http-cache-semantics@npm:^4.1.0": - version: 4.1.0 - resolution: "http-cache-semantics@npm:4.1.0" - checksum: 974de94a81c5474be07f269f9fd8383e92ebb5a448208223bfb39e172a9dbc26feff250192ecc23b9593b3f92098e010406b0f24bd4d588d631f80214648ed42 +"http-cache-semantics@npm:^4.1.1": + version: 4.1.1 + resolution: "http-cache-semantics@npm:4.1.1" + checksum: 83ac0bc60b17a3a36f9953e7be55e5c8f41acc61b22583060e8dedc9dd5e3607c823a88d0926f9150e571f90946835c7fe150732801010845c72cd8bbff1a236 languageName: node linkType: hard -"http-proxy-agent@npm:^4.0.1": - version: 4.0.1 - resolution: "http-proxy-agent@npm:4.0.1" +"http-proxy-agent@npm:^5.0.0": + version: 5.0.0 + resolution: "http-proxy-agent@npm:5.0.0" dependencies: - "@tootallnate/once": 1 + "@tootallnate/once": 2 agent-base: 6 debug: 4 - checksum: c6a5da5a1929416b6bbdf77b1aca13888013fe7eb9d59fc292e25d18e041bb154a8dfada58e223fc7b76b9b2d155a87e92e608235201f77d34aa258707963a82 + checksum: e2ee1ff1656a131953839b2a19cd1f3a52d97c25ba87bd2559af6ae87114abf60971e498021f9b73f9fd78aea8876d1fb0d4656aac8a03c6caa9fc175f22b786 languageName: node linkType: hard "https-proxy-agent@npm:^5.0.0": - version: 5.0.0 - resolution: "https-proxy-agent@npm:5.0.0" + version: 5.0.1 + resolution: "https-proxy-agent@npm:5.0.1" dependencies: agent-base: 6 debug: 4 - checksum: 165bfb090bd26d47693597661298006841ab733d0c7383a8cb2f17373387a94c903a3ac687090aa739de05e379ab6f868bae84ab4eac288ad85c328cd1ec9e53 + checksum: 571fccdf38184f05943e12d37d6ce38197becdd69e58d03f43637f7fa1269cf303a7d228aa27e5b27bbd3af8f09fd938e1c91dcfefff2df7ba77c20ed8dfc765 languageName: node linkType: hard @@ -1853,17 +2029,10 @@ __metadata: languageName: node linkType: hard -"ignore@npm:^4.0.6": - version: 4.0.6 - resolution: "ignore@npm:4.0.6" - checksum: 248f82e50a430906f9ee7f35e1158e3ec4c3971451dd9f99c9bc1548261b4db2b99709f60ac6c6cac9333494384176cc4cc9b07acbe42d52ac6a09cad734d800 - languageName: node - linkType: hard - -"ignore@npm:^5.1.8, ignore@npm:^5.2.0": - version: 5.2.0 - resolution: "ignore@npm:5.2.0" - checksum: 6b1f926792d614f64c6c83da3a1f9c83f6196c2839aa41e1e32dd7b8d174cef2e329d75caabb62cb61ce9dc432f75e67d07d122a037312db7caa73166a1bdb77 +"ignore@npm:^5.2.0": + version: 5.2.4 + resolution: "ignore@npm:5.2.4" + checksum: 3d4c309c6006e2621659311783eaea7ebcd41fe4ca1d78c91c473157ad6666a57a2df790fe0d07a12300d9aac2888204d7be8d59f9aaf665b1c7fcdb432517ef languageName: node linkType: hard @@ -1891,13 +2060,6 @@ __metadata: languageName: node linkType: hard -"infer-owner@npm:^1.0.4": - version: 1.0.4 - resolution: "infer-owner@npm:1.0.4" - checksum: 181e732764e4a0611576466b4b87dac338972b839920b2a8cde43642e4ed6bd54dc1fb0b40874728f2a2df9a1b097b8ff83b56d5f8f8e3927f837fdcb47d8a89 - languageName: node - linkType: hard - "inflight@npm:^1.0.4": version: 1.0.6 resolution: "inflight@npm:1.0.6" @@ -1944,10 +2106,10 @@ __metadata: languageName: unknown linkType: soft -"ip@npm:^1.1.5": - version: 1.1.5 - resolution: "ip@npm:1.1.5" - checksum: 30133981f082a060a32644f6a7746e9ba7ac9e2bc07ecc8bbdda3ee8ca9bec1190724c390e45a1ee7695e7edfd2a8f7dda2c104ec5f7ac5068c00648504c7e5a +"ip@npm:^2.0.0": + version: 2.0.0 + resolution: "ip@npm:2.0.0" + checksum: cfcfac6b873b701996d71ec82a7dd27ba92450afdb421e356f44044ed688df04567344c36cbacea7d01b1c39a4c732dc012570ebe9bebfb06f27314bca625349 languageName: node linkType: hard @@ -1997,6 +2159,13 @@ __metadata: languageName: node linkType: hard +"is-path-inside@npm:^3.0.3": + version: 3.0.3 + resolution: "is-path-inside@npm:3.0.3" + checksum: abd50f06186a052b349c15e55b182326f1936c89a78bf6c8f2b707412517c097ce04bc49a0ca221787bc44e1049f51f09a2ffb63d22899051988d3a618ba13e9 + languageName: node + linkType: hard + "is-plain-obj@npm:^2.1.0": version: 2.1.0 resolution: "is-plain-obj@npm:2.1.0" @@ -2046,7 +2215,7 @@ __metadata: languageName: node linkType: hard -"istanbul-lib-coverage@npm:^3.0.0, istanbul-lib-coverage@npm:^3.0.0-alpha.1": +"istanbul-lib-coverage@npm:^3.0.0, istanbul-lib-coverage@npm:^3.2.0": version: 3.2.0 resolution: "istanbul-lib-coverage@npm:3.2.0" checksum: a2a545033b9d56da04a8571ed05c8120bf10e9bce01cf8633a3a2b0d1d83dff4ac4fe78d6d5673c27fc29b7f21a41d75f83a36be09f82a61c367b56aa73c1ff9 @@ -2075,17 +2244,16 @@ __metadata: linkType: hard "istanbul-lib-processinfo@npm:^2.0.2": - version: 2.0.2 - resolution: "istanbul-lib-processinfo@npm:2.0.2" + version: 2.0.3 + resolution: "istanbul-lib-processinfo@npm:2.0.3" dependencies: archy: ^1.0.0 - cross-spawn: ^7.0.0 - istanbul-lib-coverage: ^3.0.0-alpha.1 - make-dir: ^3.0.0 + cross-spawn: ^7.0.3 + istanbul-lib-coverage: ^3.2.0 p-map: ^3.0.0 rimraf: ^3.0.0 - uuid: ^3.3.3 - checksum: 400bd0b25b623c172e48d37e5bdda7a58b2fe5beeedfeb03099aed3385223d31e4cfa6f9932be07bbf06cfd039023301bce81d3b70b9a20a79a38b0f12cb261a + uuid: ^8.3.2 + checksum: 501729e809a4e98bbb9f62f89cae924be81655a7ff8118661f8834a10bb89ed5d3a5099ea0b6555e1a8ee15a0099cb64f7170b89aae155ab2afacfe8dd94421a languageName: node linkType: hard @@ -2112,12 +2280,25 @@ __metadata: linkType: hard "istanbul-reports@npm:^3.0.2": - version: 3.1.4 - resolution: "istanbul-reports@npm:3.1.4" + version: 3.1.5 + resolution: "istanbul-reports@npm:3.1.5" dependencies: html-escaper: ^2.0.0 istanbul-lib-report: ^3.0.0 - checksum: 2132983355710c522f6b26808015cab9a0ee8b9f5ae0db0d3edeff40b886dd83cb670fb123cb7b32dbe59473d7c00cdde2ba6136bc0acdb20a865fccea64dfe1 + checksum: 7867228f83ed39477b188ea07e7ccb9b4f5320b6f73d1db93a0981b7414fa4ef72d3f80c4692c442f90fc250d9406e71d8d7ab65bb615cb334e6292b73192b89 + languageName: node + linkType: hard + +"jackspeak@npm:^2.0.3": + version: 2.2.1 + resolution: "jackspeak@npm:2.2.1" + dependencies: + "@isaacs/cliui": ^8.0.2 + "@pkgjs/parseargs": ^0.11.0 + dependenciesMeta: + "@pkgjs/parseargs": + optional: true + checksum: e29291c0d0f280a063fa18fbd1e891ab8c2d7519fd34052c0ebde38538a15c603140d60c2c7f432375ff7ee4c5f1c10daa8b2ae19a97c3d4affe308c8360c1df languageName: node linkType: hard @@ -2181,14 +2362,12 @@ __metadata: languageName: node linkType: hard -"json5@npm:^2.1.2": - version: 2.2.0 - resolution: "json5@npm:2.2.0" - dependencies: - minimist: ^1.2.5 +"json5@npm:^2.2.2": + version: 2.2.3 + resolution: "json5@npm:2.2.3" bin: json5: lib/cli.js - checksum: e88fc5274bb58fc99547baa777886b069d2dd96d9cfc4490b305fd16d711dabd5979e35a4f90873cefbeb552e216b041a304fe56702bedba76e19bc7845f208d + checksum: 2a7436a93393830bce797d4626275152e37e877b265e94ca69c99e3d20c2b9dab021279146a39cdb700e71b2dd32a4cebd1514cd57cee102b1af906ce5040349 languageName: node linkType: hard @@ -2241,13 +2420,6 @@ __metadata: languageName: node linkType: hard -"lodash.set@npm:^4.3.2": - version: 4.3.2 - resolution: "lodash.set@npm:4.3.2" - checksum: a9122f49eef9f2d0fc9061a33d87f8e5b8c6b23d46e8b9e9ce1529d3588d79741bd1145a3abdfa3b13082703e65af27ff18d8a07bfc22b9be32f3fc36f763f70 - languageName: node - linkType: hard - "lodash@npm:^4.17.15, lodash@npm:^4.17.21": version: 4.17.21 resolution: "lodash@npm:4.17.21" @@ -2281,6 +2453,15 @@ __metadata: languageName: node linkType: hard +"lru-cache@npm:^5.1.1": + version: 5.1.1 + resolution: "lru-cache@npm:5.1.1" + dependencies: + yallist: ^3.0.2 + checksum: c154ae1cbb0c2206d1501a0e94df349653c92c8cbb25236d7e85190bcaf4567a03ac6eb43166fabfa36fd35623694da7233e88d9601fbf411a9a481d85dbd2cb + languageName: node + linkType: hard + "lru-cache@npm:^6.0.0": version: 6.0.0 resolution: "lru-cache@npm:6.0.0" @@ -2290,6 +2471,20 @@ __metadata: languageName: node linkType: hard +"lru-cache@npm:^7.7.1": + version: 7.18.3 + resolution: "lru-cache@npm:7.18.3" + checksum: e550d772384709deea3f141af34b6d4fa392e2e418c1498c078de0ee63670f1f46f5eee746e8ef7e69e1c895af0d4224e62ee33e66a543a14763b0f2e74c1356 + languageName: node + linkType: hard + +"lru-cache@npm:^9.1.1 || ^10.0.0": + version: 10.0.0 + resolution: "lru-cache@npm:10.0.0" + checksum: 18f101675fe283bc09cda0ef1e3cc83781aeb8373b439f086f758d1d91b28730950db785999cd060d3c825a8571c03073e8c14512b6655af2188d623031baf50 + languageName: node + linkType: hard + "make-dir@npm:^3.0.0, make-dir@npm:^3.0.2": version: 3.1.0 resolution: "make-dir@npm:3.1.0" @@ -2306,27 +2501,26 @@ __metadata: languageName: node linkType: hard -"make-fetch-happen@npm:^9.1.0": - version: 9.1.0 - resolution: "make-fetch-happen@npm:9.1.0" +"make-fetch-happen@npm:^11.0.3": + version: 11.1.1 + resolution: "make-fetch-happen@npm:11.1.1" dependencies: - agentkeepalive: ^4.1.3 - cacache: ^15.2.0 - http-cache-semantics: ^4.1.0 - http-proxy-agent: ^4.0.1 + agentkeepalive: ^4.2.1 + cacache: ^17.0.0 + http-cache-semantics: ^4.1.1 + http-proxy-agent: ^5.0.0 https-proxy-agent: ^5.0.0 is-lambda: ^1.0.1 - lru-cache: ^6.0.0 - minipass: ^3.1.3 - minipass-collect: ^1.0.2 - minipass-fetch: ^1.3.2 + lru-cache: ^7.7.1 + minipass: ^5.0.0 + minipass-fetch: ^3.0.0 minipass-flush: ^1.0.5 minipass-pipeline: ^1.2.4 - negotiator: ^0.6.2 + negotiator: ^0.6.3 promise-retry: ^2.0.1 - socks-proxy-agent: ^6.0.0 - ssri: ^8.0.0 - checksum: 0eb371c85fdd0b1584fcfdf3dc3c62395761b3c14658be02620c310305a9a7ecf1617a5e6fb30c1d081c5c8aaf177fa133ee225024313afabb7aa6a10f1e3d04 + socks-proxy-agent: ^7.0.0 + ssri: ^10.0.0 + checksum: 7268bf274a0f6dcf0343829489a4506603ff34bd0649c12058753900b0eb29191dce5dba12680719a5d0a983d3e57810f594a12f3c18494e93a1fbc6348a4540 languageName: node linkType: hard @@ -2338,37 +2532,39 @@ __metadata: linkType: hard "micromatch@npm:^4.0.4": - version: 4.0.4 - resolution: "micromatch@npm:4.0.4" + version: 4.0.5 + resolution: "micromatch@npm:4.0.5" dependencies: - braces: ^3.0.1 - picomatch: ^2.2.3 - checksum: ef3d1c88e79e0a68b0e94a03137676f3324ac18a908c245a9e5936f838079fcc108ac7170a5fadc265a9c2596963462e402841406bda1a4bb7b68805601d631c + braces: ^3.0.2 + picomatch: ^2.3.1 + checksum: 02a17b671c06e8fefeeb6ef996119c1e597c942e632a21ef589154f23898c9c6a9858526246abb14f8bca6e77734aa9dcf65476fca47cedfb80d9577d52843fc languageName: node linkType: hard -"minimatch@npm:3.0.4": - version: 3.0.4 - resolution: "minimatch@npm:3.0.4" +"minimatch@npm:4.2.1": + version: 4.2.1 + resolution: "minimatch@npm:4.2.1" dependencies: brace-expansion: ^1.1.7 - checksum: 66ac295f8a7b59788000ea3749938b0970344c841750abd96694f80269b926ebcafad3deeb3f1da2522978b119e6ae3a5869b63b13a7859a456b3408bd18a078 + checksum: 2b1514e3d0f29a549912f0db7ae7b82c5cab4a8f2dd0369f1c6451a325b3f12b2cf473c95873b6157bb8df183d6cf6db82ff03614b6adaaf1d7e055beccdfd01 languageName: node linkType: hard -"minimatch@npm:^3.0.4": - version: 3.0.5 - resolution: "minimatch@npm:3.0.5" +"minimatch@npm:^3.0.4, minimatch@npm:^3.0.5, minimatch@npm:^3.1.1, minimatch@npm:^3.1.2": + version: 3.1.2 + resolution: "minimatch@npm:3.1.2" dependencies: brace-expansion: ^1.1.7 - checksum: a3b84b426eafca947741b864502cee02860c4e7b145de11ad98775cfcf3066fef422583bc0ffce0952ddf4750c1ccf4220b1556430d4ce10139f66247d87d69e + checksum: c154e566406683e7bcb746e000b84d74465b3a832c45d59912b9b55cd50dee66e5c4b1e5566dba26154040e51672f9aa450a9aef0c97cfc7336b78b7afb9540a languageName: node linkType: hard -"minimist@npm:^1.2.5": - version: 1.2.7 - resolution: "minimist@npm:1.2.7" - checksum: 7346574a1038ca23c32e02252f603801f09384dd1d78b69a943a4e8c2c28730b80e96193882d3d3b22a063445f460e48316b29b8a25addca2d7e5e8f75478bec +"minimatch@npm:^9.0.1": + version: 9.0.3 + resolution: "minimatch@npm:9.0.3" + dependencies: + brace-expansion: ^2.0.1 + checksum: 253487976bf485b612f16bf57463520a14f512662e592e95c571afdab1442a6a6864b6c88f248ce6fc4ff0b6de04ac7aa6c8bb51e868e99d1d65eb0658a708b5 languageName: node linkType: hard @@ -2381,18 +2577,18 @@ __metadata: languageName: node linkType: hard -"minipass-fetch@npm:^1.3.2": - version: 1.4.1 - resolution: "minipass-fetch@npm:1.4.1" +"minipass-fetch@npm:^3.0.0": + version: 3.0.3 + resolution: "minipass-fetch@npm:3.0.3" dependencies: - encoding: ^0.1.12 - minipass: ^3.1.0 + encoding: ^0.1.13 + minipass: ^5.0.0 minipass-sized: ^1.0.3 - minizlib: ^2.0.0 + minizlib: ^2.1.2 dependenciesMeta: encoding: optional: true - checksum: ec93697bdb62129c4e6c0104138e681e30efef8c15d9429dd172f776f83898471bc76521b539ff913248cc2aa6d2b37b652c993504a51cc53282563640f29216 + checksum: af5ab2552a16fcf505d35fd7ffb84b57f4a0eeb269e6e1d9a2a75824dda48b36e527083250b7cca4a4def21d9544e2ade441e4730e233c0bc2133f6abda31e18 languageName: node linkType: hard @@ -2405,7 +2601,7 @@ __metadata: languageName: node linkType: hard -"minipass-pipeline@npm:^1.2.2, minipass-pipeline@npm:^1.2.4": +"minipass-pipeline@npm:^1.2.4": version: 1.2.4 resolution: "minipass-pipeline@npm:1.2.4" dependencies: @@ -2423,16 +2619,30 @@ __metadata: languageName: node linkType: hard -"minipass@npm:^3.0.0, minipass@npm:^3.1.0, minipass@npm:^3.1.1, minipass@npm:^3.1.3": - version: 3.1.6 - resolution: "minipass@npm:3.1.6" +"minipass@npm:^3.0.0": + version: 3.3.6 + resolution: "minipass@npm:3.3.6" dependencies: yallist: ^4.0.0 - checksum: 57a04041413a3531a65062452cb5175f93383ef245d6f4a2961d34386eb9aa8ac11ac7f16f791f5e8bbaf1dfb1ef01596870c88e8822215db57aa591a5bb0a77 + checksum: a30d083c8054cee83cdcdc97f97e4641a3f58ae743970457b1489ce38ee1167b3aaf7d815cd39ec7a99b9c40397fd4f686e83750e73e652b21cb516f6d845e48 + languageName: node + linkType: hard + +"minipass@npm:^5.0.0": + version: 5.0.0 + resolution: "minipass@npm:5.0.0" + checksum: 425dab288738853fded43da3314a0b5c035844d6f3097a8e3b5b29b328da8f3c1af6fc70618b32c29ff906284cf6406b6841376f21caaadd0793c1d5a6a620ea + languageName: node + linkType: hard + +"minipass@npm:^5.0.0 || ^6.0.2": + version: 6.0.2 + resolution: "minipass@npm:6.0.2" + checksum: d140b91f4ab2e5ce5a9b6c468c0e82223504acc89114c1a120d4495188b81fedf8cade72a9f4793642b4e66672f990f1e0d902dd858485216a07cd3c8a62fac9 languageName: node linkType: hard -"minizlib@npm:^2.0.0, minizlib@npm:^2.1.1": +"minizlib@npm:^2.1.1, minizlib@npm:^2.1.2": version: 2.1.2 resolution: "minizlib@npm:2.1.2" dependencies: @@ -2442,7 +2652,7 @@ __metadata: languageName: node linkType: hard -"mkdirp@npm:^1.0.3, mkdirp@npm:^1.0.4": +"mkdirp@npm:^1.0.3": version: 1.0.4 resolution: "mkdirp@npm:1.0.4" bin: @@ -2452,8 +2662,8 @@ __metadata: linkType: hard "mocha@npm:^9.2.0": - version: 9.2.0 - resolution: "mocha@npm:9.2.0" + version: 9.2.2 + resolution: "mocha@npm:9.2.2" dependencies: "@ungap/promise-all-settled": 1.1.2 ansi-colors: 4.1.1 @@ -2468,9 +2678,9 @@ __metadata: he: 1.2.0 js-yaml: 4.1.0 log-symbols: 4.1.0 - minimatch: 3.0.4 + minimatch: 4.2.1 ms: 2.1.3 - nanoid: 3.2.0 + nanoid: 3.3.1 serialize-javascript: 6.0.0 strip-json-comments: 3.1.1 supports-color: 8.1.1 @@ -2482,7 +2692,7 @@ __metadata: bin: _mocha: bin/_mocha mocha: bin/mocha - checksum: 49efc4724cf17087c7e107bc8f6890db24525e6dcc153b801da58de3c2a2f940e22f7600ef195b8ac62a0dfd7baee5cf289fc4641a6b1fdf8bc9c819efc1a8ba + checksum: 4d5ca4ce33fc66627e63acdf09a634e2358c9a00f61de7788b1091b6aad430da04f97f9ecb82d56dc034b623cb833b65576136fd010d77679c03fcea5bc1e12d languageName: node linkType: hard @@ -2500,12 +2710,19 @@ __metadata: languageName: node linkType: hard -"nanoid@npm:3.2.0": - version: 3.2.0 - resolution: "nanoid@npm:3.2.0" +"nanoid@npm:3.3.1": + version: 3.3.1 + resolution: "nanoid@npm:3.3.1" bin: nanoid: bin/nanoid.cjs - checksum: 3d1d5a69fea84e538057cf64106e713931c4ef32af344068ecff153ff91252f39b0f2b472e09b0dfff43ac3cf520c92938d90e6455121fe93976e23660f4fccc + checksum: 4ef0969e1bbe866fc223eb32276cbccb0961900bfe79104fa5abe34361979dead8d0e061410a5c03bc3d47455685adf32c09d6f27790f4a6898fb51f7df7ec86 + languageName: node + linkType: hard + +"natural-compare-lite@npm:^1.4.0": + version: 1.4.0 + resolution: "natural-compare-lite@npm:1.4.0" + checksum: 5222ac3986a2b78dd6069ac62cbb52a7bf8ffc90d972ab76dfe7b01892485d229530ed20d0c62e79a6b363a663b273db3bde195a1358ce9e5f779d4453887225 languageName: node linkType: hard @@ -2516,7 +2733,7 @@ __metadata: languageName: node linkType: hard -"negotiator@npm:^0.6.2": +"negotiator@npm:^0.6.3": version: 0.6.3 resolution: "negotiator@npm:0.6.3" checksum: b8ffeb1e262eff7968fc90a2b6767b04cfd9842582a9d0ece0af7049537266e7b2506dfb1d107a32f06dd849ab2aea834d5830f7f4d0e5cb7d36e1ae55d021d9 @@ -2537,26 +2754,27 @@ __metadata: linkType: hard "nock@npm:^13.0.11": - version: 13.2.4 - resolution: "nock@npm:13.2.4" + version: 13.3.1 + resolution: "nock@npm:13.3.1" dependencies: debug: ^4.1.0 json-stringify-safe: ^5.0.1 - lodash.set: ^4.3.2 + lodash: ^4.17.21 propagate: ^2.0.0 - checksum: 2750a82ea22eebd8203eb1d7669ae09c3daae1fd573026372bad2515adad48d723a804f647bd45d7a499eb3a9a632560da406bde05bca9df762d3027db9099b5 + checksum: 0f2a73e8432f6b5650656c53eef99f9e5bbde3df538dc2f07057edc4438cfc61a394c9d06dd82e60f6e86d42433f20f3c04364a1f088beee7bf03a24e3f0fdd0 languageName: node linkType: hard "node-gyp@npm:latest": - version: 8.4.1 - resolution: "node-gyp@npm:8.4.1" + version: 9.4.0 + resolution: "node-gyp@npm:9.4.0" dependencies: env-paths: ^2.2.0 + exponential-backoff: ^3.1.1 glob: ^7.1.4 graceful-fs: ^4.2.6 - make-fetch-happen: ^9.1.0 - nopt: ^5.0.0 + make-fetch-happen: ^11.0.3 + nopt: ^6.0.0 npmlog: ^6.0.0 rimraf: ^3.0.2 semver: ^7.3.5 @@ -2564,7 +2782,7 @@ __metadata: which: ^2.0.2 bin: node-gyp: bin/node-gyp.js - checksum: 341710b5da39d3660e6a886b37e210d33f8282047405c2e62c277bcc744c7552c5b8b972ebc3a7d5c2813794e60cc48c3ebd142c46d6e0321db4db6c92dd0355 + checksum: 78b404e2e0639d64e145845f7f5a3cb20c0520cdaf6dda2f6e025e9b644077202ea7de1232396ba5bde3fee84cdc79604feebe6ba3ec84d464c85d407bb5da99 languageName: node linkType: hard @@ -2577,21 +2795,21 @@ __metadata: languageName: node linkType: hard -"node-releases@npm:^2.0.1": - version: 2.0.2 - resolution: "node-releases@npm:2.0.2" - checksum: da858bf86b4d512842379749f5a5e4196ddab05ba18ffcf29f05bf460beceaca927f070f4430bb5046efec18941ddbc85e4c5fdbb83afc28a38dd6069a2f255e +"node-releases@npm:^2.0.12": + version: 2.0.13 + resolution: "node-releases@npm:2.0.13" + checksum: 17ec8f315dba62710cae71a8dad3cd0288ba943d2ece43504b3b1aa8625bf138637798ab470b1d9035b0545996f63000a8a926e0f6d35d0996424f8b6d36dda3 languageName: node linkType: hard -"nopt@npm:^5.0.0": - version: 5.0.0 - resolution: "nopt@npm:5.0.0" +"nopt@npm:^6.0.0": + version: 6.0.0 + resolution: "nopt@npm:6.0.0" dependencies: - abbrev: 1 + abbrev: ^1.0.0 bin: nopt: bin/nopt.js - checksum: d35fdec187269503843924e0114c0c6533fb54bbf1620d0f28b4b60ba01712d6687f62565c55cc20a504eff0fbe5c63e22340c3fad549ad40469ffb611b04f2f + checksum: 82149371f8be0c4b9ec2f863cc6509a7fd0fa729929c009f3a58e4eb0c9e4cae9920e8f1f8eb46e7d032fec8fb01bede7f0f41a67eb3553b7b8e14fa53de1dac languageName: node linkType: hard @@ -2603,14 +2821,14 @@ __metadata: linkType: hard "npmlog@npm:^6.0.0": - version: 6.0.0 - resolution: "npmlog@npm:6.0.0" + version: 6.0.2 + resolution: "npmlog@npm:6.0.2" dependencies: - are-we-there-yet: ^2.0.0 + are-we-there-yet: ^3.0.0 console-control-strings: ^1.1.0 - gauge: ^4.0.0 + gauge: ^4.0.3 set-blocking: ^2.0.0 - checksum: 33d8a7fe3d63bf83b16655b6588ae7ba10b5f37b067a661e7cab6508660d7c3204ae716ee2c5ce4eb9626fd1489cf2fa7645d789bc3b704f8c3ccb04a532a50b + checksum: ae238cd264a1c3f22091cdd9e2b106f684297d3c184f1146984ecbe18aaa86343953f26b9520dedd1b1372bc0316905b736c1932d778dbeb1fcf5a1001390e2a languageName: node linkType: hard @@ -2660,17 +2878,17 @@ __metadata: languageName: node linkType: hard -"optionator@npm:^0.9.1": - version: 0.9.1 - resolution: "optionator@npm:0.9.1" +"optionator@npm:^0.9.3": + version: 0.9.3 + resolution: "optionator@npm:0.9.3" dependencies: + "@aashutoshrathi/word-wrap": ^1.2.3 deep-is: ^0.1.3 fast-levenshtein: ^2.0.6 levn: ^0.4.1 prelude-ls: ^1.2.1 type-check: ^0.4.0 - word-wrap: ^1.2.3 - checksum: dbc6fa065604b24ea57d734261914e697bd73b69eff7f18e967e8912aa2a40a19a9f599a507fa805be6c13c24c4eae8c71306c239d517d42d4c041c942f508a0 + checksum: 09281999441f2fe9c33a5eeab76700795365a061563d66b098923eb719251a42bdbe432790d35064d0816ead9296dbeb1ad51a733edf4167c96bd5d0882e428a languageName: node linkType: hard @@ -2777,6 +2995,16 @@ __metadata: languageName: node linkType: hard +"path-scurry@npm:^1.10.0": + version: 1.10.0 + resolution: "path-scurry@npm:1.10.0" + dependencies: + lru-cache: ^9.1.1 || ^10.0.0 + minipass: ^5.0.0 || ^6.0.2 + checksum: 3b66a4a6ab66e45755b577c966ecf0da92d3e068b3c992d8f69aa2cc908ef4eda9358253e9b4f86cad43d3ad810ec445be164105975f5cb3fdab68459c59dc6e + languageName: node + linkType: hard + "path-to-regexp@npm:^1.7.0": version: 1.8.0 resolution: "path-to-regexp@npm:1.8.0" @@ -2800,7 +3028,7 @@ __metadata: languageName: node linkType: hard -"picomatch@npm:^2.0.4, picomatch@npm:^2.2.1, picomatch@npm:^2.2.3": +"picomatch@npm:^2.0.4, picomatch@npm:^2.2.1, picomatch@npm:^2.3.1": version: 2.3.1 resolution: "picomatch@npm:2.3.1" checksum: 050c865ce81119c4822c45d3c84f1ced46f93a0126febae20737bd05ca20589c564d6e9226977df859ed5e03dc73f02584a2b0faad36e896936238238b0446cf @@ -2824,11 +3052,11 @@ __metadata: linkType: hard "prettier@npm:^2.5.1": - version: 2.5.1 - resolution: "prettier@npm:2.5.1" + version: 2.8.8 + resolution: "prettier@npm:2.8.8" bin: prettier: bin-prettier.js - checksum: 21b9408476ea1c544b0e45d51ceb94a84789ff92095abb710942d780c862d0daebdb29972d47f6b4d0f7ebbfb0ffbf56cc2cfa3e3e9d1cca54864af185b15b66 + checksum: b49e409431bf129dd89238d64299ba80717b57ff5a6d1c1a8b1a28b590d998a34e083fa13573bc732bb8d2305becb4c9a4407f8486c81fa7d55100eb08263cf8 languageName: node linkType: hard @@ -2841,13 +3069,6 @@ __metadata: languageName: node linkType: hard -"promise-inflight@npm:^1.0.1": - version: 1.0.1 - resolution: "promise-inflight@npm:1.0.1" - checksum: 22749483091d2c594261517f4f80e05226d4d5ecc1fc917e1886929da56e22b5718b7f2a75f3807e7a7d471bc3be2907fe92e6e8f373ddf5c64bae35b5af3981 - languageName: node - linkType: hard - "promise-retry@npm:^2.0.1": version: 2.0.1 resolution: "promise-retry@npm:2.0.1" @@ -2866,9 +3087,9 @@ __metadata: linkType: hard "punycode@npm:^2.1.0": - version: 2.1.1 - resolution: "punycode@npm:2.1.1" - checksum: 823bf443c6dd14f669984dea25757b37993f67e8d94698996064035edd43bed8a5a17a9f12e439c2b35df1078c6bec05a6c86e336209eb1061e8025c481168e8 + version: 2.3.0 + resolution: "punycode@npm:2.3.0" + checksum: 39f760e09a2a3bbfe8f5287cf733ecdad69d6af2fe6f97ca95f24b8921858b91e9ea3c9eeec6e08cede96181b3bb33f95c6ffd8c77e63986508aa2e8159fa200 languageName: node linkType: hard @@ -2889,13 +3110,13 @@ __metadata: linkType: hard "readable-stream@npm:^3.6.0": - version: 3.6.0 - resolution: "readable-stream@npm:3.6.0" + version: 3.6.2 + resolution: "readable-stream@npm:3.6.2" dependencies: inherits: ^2.0.3 string_decoder: ^1.1.1 util-deprecate: ^1.0.1 - checksum: d4ea81502d3799439bb955a3a5d1d808592cf3133350ed352aeaa499647858b27b1c4013984900238b0873ec8d0d8defce72469fb7a83e61d53f5ad61cb80dc8 + checksum: bdcbe6c22e846b6af075e32cf8f4751c2576238c5043169a1c221c92ee2878458a816a4ea33f4c67623c0b6827c8a400409bfb3cf0bf3381392d0b1dfb52ac8d languageName: node linkType: hard @@ -2908,13 +3129,6 @@ __metadata: languageName: node linkType: hard -"regexpp@npm:^3.2.0": - version: 3.2.0 - resolution: "regexpp@npm:3.2.0" - checksum: a78dc5c7158ad9ddcfe01aa9144f46e192ddbfa7b263895a70a5c6c73edd9ce85faf7c0430e59ac38839e1734e275b9c3de5c57ee3ab6edc0e0b1bdebefccef8 - languageName: node - linkType: hard - "release-zalgo@npm:^1.0.0": version: 1.0.0 resolution: "release-zalgo@npm:1.0.0" @@ -2993,13 +3207,6 @@ __metadata: languageName: node linkType: hard -"safe-buffer@npm:~5.1.1": - version: 5.1.2 - resolution: "safe-buffer@npm:5.1.2" - checksum: f2f1f7943ca44a594893a852894055cf619c1fbcb611237fc39e461ae751187e7baf4dc391a72125e0ac4fb2d8c5c0b3c71529622e6a58f46b960211e704903c - languageName: node - linkType: hard - "safer-buffer@npm:>= 2.1.2 < 3.0.0": version: 2.1.2 resolution: "safer-buffer@npm:2.1.2" @@ -3016,14 +3223,14 @@ __metadata: languageName: node linkType: hard -"semver@npm:^7.3.5": - version: 7.3.5 - resolution: "semver@npm:7.3.5" +"semver@npm:^7.3.5, semver@npm:^7.3.7": + version: 7.5.3 + resolution: "semver@npm:7.5.3" dependencies: lru-cache: ^6.0.0 bin: semver: bin/semver.js - checksum: 5eafe6102bea2a7439897c1856362e31cc348ccf96efd455c8b5bc2c61e6f7e7b8250dc26b8828c1d76a56f818a7ee907a36ae9fb37a599d3d24609207001d60 + checksum: 9d58db16525e9f749ad0a696a1f27deabaa51f66e91d2fa2b0db3de3e9644e8677de3b7d7a03f4c15bc81521e0c3916d7369e0572dbde250d9bedf5194e2a8a7 languageName: node linkType: hard @@ -3059,13 +3266,20 @@ __metadata: languageName: node linkType: hard -"signal-exit@npm:^3.0.0, signal-exit@npm:^3.0.2": +"signal-exit@npm:^3.0.2, signal-exit@npm:^3.0.7": version: 3.0.7 resolution: "signal-exit@npm:3.0.7" checksum: a2f098f247adc367dffc27845853e9959b9e88b01cb301658cfe4194352d8d2bb32e18467c786a7fe15f1d44b233ea35633d076d5e737870b7139949d1ab6318 languageName: node linkType: hard +"signal-exit@npm:^4.0.1": + version: 4.0.2 + resolution: "signal-exit@npm:4.0.2" + checksum: 41f5928431cc6e91087bf0343db786a6313dd7c6fd7e551dbc141c95bb5fb26663444fd9df8ea47c5d7fc202f60aa7468c3162a9365cbb0615fc5e1b1328fe31 + languageName: node + linkType: hard + "sinon@npm:^7.3.2": version: 7.5.0 resolution: "sinon@npm:7.5.0" @@ -3095,31 +3309,24 @@ __metadata: languageName: node linkType: hard -"socks-proxy-agent@npm:^6.0.0": - version: 6.1.1 - resolution: "socks-proxy-agent@npm:6.1.1" +"socks-proxy-agent@npm:^7.0.0": + version: 7.0.0 + resolution: "socks-proxy-agent@npm:7.0.0" dependencies: agent-base: ^6.0.2 - debug: ^4.3.1 - socks: ^2.6.1 - checksum: 9a8a4f791bba0060315cf7291ca6f9db37d6fc280fd0860d73d8887d3efe4c22e823aa25a8d5375f6079279f8dc91b50c075345179bf832bfe3c7c26d3582e3c + debug: ^4.3.3 + socks: ^2.6.2 + checksum: 720554370154cbc979e2e9ce6a6ec6ced205d02757d8f5d93fe95adae454fc187a5cbfc6b022afab850a5ce9b4c7d73e0f98e381879cf45f66317a4895953846 languageName: node linkType: hard -"socks@npm:^2.6.1": - version: 2.6.2 - resolution: "socks@npm:2.6.2" +"socks@npm:^2.6.2": + version: 2.7.1 + resolution: "socks@npm:2.7.1" dependencies: - ip: ^1.1.5 + ip: ^2.0.0 smart-buffer: ^4.2.0 - checksum: dd9194293059d737759d5c69273850ad4149f448426249325c4bea0e340d1cf3d266c3b022694b0dcf5d31f759de23657244c481fc1e8322add80b7985c36b5e - languageName: node - linkType: hard - -"source-map@npm:^0.5.0": - version: 0.5.7 - resolution: "source-map@npm:0.5.7" - checksum: 5dc2043b93d2f194142c7f38f74a24670cd7a0063acdaf4bf01d2964b402257ae843c2a8fa822ad5b71013b5fcafa55af7421383da919752f22ff488bc553f4d + checksum: 259d9e3e8e1c9809a7f5c32238c3d4d2a36b39b83851d0f573bfde5f21c4b1288417ce1af06af1452569cd1eb0841169afd4998f0e04ba04656f6b7f0e46d748 languageName: node linkType: hard @@ -3151,16 +3358,16 @@ __metadata: languageName: node linkType: hard -"ssri@npm:^8.0.0, ssri@npm:^8.0.1": - version: 8.0.1 - resolution: "ssri@npm:8.0.1" +"ssri@npm:^10.0.0": + version: 10.0.4 + resolution: "ssri@npm:10.0.4" dependencies: - minipass: ^3.1.1 - checksum: bc447f5af814fa9713aa201ec2522208ae0f4d8f3bda7a1f445a797c7b929a02720436ff7c478fb5edc4045adb02b1b88d2341b436a80798734e2494f1067b36 + minipass: ^5.0.0 + checksum: fb14da9f8a72b04eab163eb13a9dda11d5962cd2317f85457c4e0b575e9a6e0e3a6a87b5bf122c75cb36565830cd5f263fb457571bf6f1587eb5f95d095d6165 languageName: node linkType: hard -"string-width@npm:^1.0.2 || 2 || 3 || 4, string-width@npm:^4.1.0, string-width@npm:^4.2.0, string-width@npm:^4.2.3": +"string-width-cjs@npm:string-width@^4.2.0, string-width@npm:^1.0.2 || 2 || 3 || 4, string-width@npm:^4.1.0, string-width@npm:^4.2.0, string-width@npm:^4.2.3": version: 4.2.3 resolution: "string-width@npm:4.2.3" dependencies: @@ -3171,6 +3378,17 @@ __metadata: languageName: node linkType: hard +"string-width@npm:^5.0.1, string-width@npm:^5.1.2": + version: 5.1.2 + resolution: "string-width@npm:5.1.2" + dependencies: + eastasianwidth: ^0.2.0 + emoji-regex: ^9.2.2 + strip-ansi: ^7.0.1 + checksum: 7369deaa29f21dda9a438686154b62c2c5f661f8dda60449088f9f980196f7908fc39fdd1803e3e01541970287cf5deae336798337e9319a7055af89dafa7193 + languageName: node + linkType: hard + "string_decoder@npm:^1.1.1": version: 1.3.0 resolution: "string_decoder@npm:1.3.0" @@ -3180,7 +3398,7 @@ __metadata: languageName: node linkType: hard -"strip-ansi@npm:^6.0.0, strip-ansi@npm:^6.0.1": +"strip-ansi-cjs@npm:strip-ansi@^6.0.1, strip-ansi@npm:^6.0.0, strip-ansi@npm:^6.0.1": version: 6.0.1 resolution: "strip-ansi@npm:6.0.1" dependencies: @@ -3189,6 +3407,15 @@ __metadata: languageName: node linkType: hard +"strip-ansi@npm:^7.0.1": + version: 7.1.0 + resolution: "strip-ansi@npm:7.1.0" + dependencies: + ansi-regex: ^6.0.1 + checksum: 859c73fcf27869c22a4e4d8c6acfe690064659e84bef9458aa6d13719d09ca88dcfd40cbf31fd0be63518ea1a643fe070b4827d353e09533a5b0b9fd4553d64d + languageName: node + linkType: hard + "strip-bom@npm:^4.0.0": version: 4.0.0 resolution: "strip-bom@npm:4.0.0" @@ -3230,17 +3457,17 @@ __metadata: languageName: node linkType: hard -"tar@npm:^6.0.2, tar@npm:^6.1.2": - version: 6.1.11 - resolution: "tar@npm:6.1.11" +"tar@npm:^6.1.11, tar@npm:^6.1.2": + version: 6.1.15 + resolution: "tar@npm:6.1.15" dependencies: chownr: ^2.0.0 fs-minipass: ^2.0.0 - minipass: ^3.0.0 + minipass: ^5.0.0 minizlib: ^2.1.1 mkdirp: ^1.0.3 yallist: ^4.0.0 - checksum: a04c07bb9e2d8f46776517d4618f2406fb977a74d914ad98b264fc3db0fe8224da5bec11e5f8902c5b9bcb8ace22d95fbe3c7b36b8593b7dfc8391a25898f32f + checksum: f23832fceeba7578bf31907aac744ae21e74a66f4a17a9e94507acf460e48f6db598c7023882db33bab75b80e027c21f276d405e4a0322d58f51c7088d428268 languageName: node linkType: hard @@ -3279,10 +3506,10 @@ __metadata: linkType: hard "ts-node@npm:^10.4.0": - version: 10.5.0 - resolution: "ts-node@npm:10.5.0" + version: 10.9.1 + resolution: "ts-node@npm:10.9.1" dependencies: - "@cspotcode/source-map-support": 0.7.0 + "@cspotcode/source-map-support": ^0.8.0 "@tsconfig/node10": ^1.0.7 "@tsconfig/node12": ^1.0.7 "@tsconfig/node14": ^1.0.0 @@ -3293,7 +3520,7 @@ __metadata: create-require: ^1.1.0 diff: ^4.0.1 make-error: ^1.1.1 - v8-compile-cache-lib: ^3.0.0 + v8-compile-cache-lib: ^3.0.1 yn: 3.1.1 peerDependencies: "@swc/core": ">=1.2.50" @@ -3308,10 +3535,11 @@ __metadata: bin: ts-node: dist/bin.js ts-node-cwd: dist/bin-cwd.js + ts-node-esm: dist/bin-esm.js ts-node-script: dist/bin-script.js ts-node-transpile-only: dist/bin-transpile.js ts-script: dist/bin-script-deprecated.js - checksum: d51ac8a9b3582ce3705cef8d35f3372e40caa277dbd7c7baeb651961538f13d2f11f22402614348f78d9b10501bd1cb5f05ec4f2ec9a74bd0e288de769c32335 + checksum: 090adff1302ab20bd3486e6b4799e90f97726ed39e02b39e566f8ab674fd5bd5f727f43615debbfc580d33c6d9d1c6b1b3ce7d8e3cca3e20530a145ffa232c35 languageName: node linkType: hard @@ -3323,9 +3551,9 @@ __metadata: linkType: hard "tslib@npm:^2.3.1": - version: 2.3.1 - resolution: "tslib@npm:2.3.1" - checksum: de17a98d4614481f7fcb5cd53ffc1aaf8654313be0291e1bfaee4b4bb31a20494b7d218ff2e15017883e8ea9626599b3b0e0229c18383ba9dce89da2adf15cb9 + version: 2.6.0 + resolution: "tslib@npm:2.6.0" + checksum: c01066038f950016a18106ddeca4649b4d76caa76ec5a31e2a26e10586a59fceb4ee45e96719bf6c715648e7c14085a81fee5c62f7e9ebee68e77a5396e5538f languageName: node linkType: hard @@ -3380,40 +3608,54 @@ __metadata: linkType: hard "typescript@npm:^4.5.3": - version: 4.5.5 - resolution: "typescript@npm:4.5.5" + version: 4.9.5 + resolution: "typescript@npm:4.9.5" bin: tsc: bin/tsc tsserver: bin/tsserver - checksum: 506f4c919dc8aeaafa92068c997f1d213b9df4d9756d0fae1a1e7ab66b585ab3498050e236113a1c9e57ee08c21ec6814ca7a7f61378c058d79af50a4b1f5a5e + checksum: ee000bc26848147ad423b581bd250075662a354d84f0e06eb76d3b892328d8d4440b7487b5a83e851b12b255f55d71835b008a66cbf8f255a11e4400159237db languageName: node linkType: hard "typescript@patch:typescript@^4.5.3#~builtin": - version: 4.5.5 - resolution: "typescript@patch:typescript@npm%3A4.5.5#~builtin::version=4.5.5&hash=493e53" + version: 4.9.5 + resolution: "typescript@patch:typescript@npm%3A4.9.5#~builtin::version=4.9.5&hash=493e53" bin: tsc: bin/tsc tsserver: bin/tsserver - checksum: c05c318d79c690f101d7ffb34cd6c7d6bbd884d3af9cefe7749ad0cd6be43c7082f098280982ca945dcba23fde34a08fed9602bb26540936baf8c0520727d3ba + checksum: 2eee5c37cad4390385db5db5a8e81470e42e8f1401b0358d7390095d6f681b410f2c4a0c496c6ff9ebd775423c7785cdace7bcdad76c7bee283df3d9718c0f20 languageName: node linkType: hard -"unique-filename@npm:^1.1.1": - version: 1.1.1 - resolution: "unique-filename@npm:1.1.1" +"unique-filename@npm:^3.0.0": + version: 3.0.0 + resolution: "unique-filename@npm:3.0.0" dependencies: - unique-slug: ^2.0.0 - checksum: cf4998c9228cc7647ba7814e255dec51be43673903897b1786eff2ac2d670f54d4d733357eb08dea969aa5e6875d0e1bd391d668fbdb5a179744e7c7551a6f80 + unique-slug: ^4.0.0 + checksum: 8e2f59b356cb2e54aab14ff98a51ac6c45781d15ceaab6d4f1c2228b780193dc70fae4463ce9e1df4479cb9d3304d7c2043a3fb905bdeca71cc7e8ce27e063df languageName: node linkType: hard -"unique-slug@npm:^2.0.0": - version: 2.0.2 - resolution: "unique-slug@npm:2.0.2" +"unique-slug@npm:^4.0.0": + version: 4.0.0 + resolution: "unique-slug@npm:4.0.0" dependencies: imurmurhash: ^0.1.4 - checksum: 5b6876a645da08d505dedb970d1571f6cebdf87044cb6b740c8dbb24f0d6e1dc8bdbf46825fd09f994d7cf50760e6f6e063cfa197d51c5902c00a861702eb75a + checksum: 0884b58365af59f89739e6f71e3feacb5b1b41f2df2d842d0757933620e6de08eff347d27e9d499b43c40476cbaf7988638d3acb2ffbcb9d35fd035591adfd15 + languageName: node + linkType: hard + +"update-browserslist-db@npm:^1.0.11": + version: 1.0.11 + resolution: "update-browserslist-db@npm:1.0.11" + dependencies: + escalade: ^3.1.1 + picocolors: ^1.0.0 + peerDependencies: + browserslist: ">= 4.21.0" + bin: + update-browserslist-db: cli.js + checksum: b98327518f9a345c7cad5437afae4d2ae7d865f9779554baf2a200fdf4bac4969076b679b1115434bd6557376bdd37ca7583d0f9b8f8e302d7d4cc1e91b5f231 languageName: node linkType: hard @@ -3433,33 +3675,26 @@ __metadata: languageName: node linkType: hard -"uuid@npm:^3.3.3": - version: 3.4.0 - resolution: "uuid@npm:3.4.0" +"uuid@npm:^8.3.2": + version: 8.3.2 + resolution: "uuid@npm:8.3.2" bin: - uuid: ./bin/uuid - checksum: 58de2feed61c59060b40f8203c0e4ed7fd6f99d42534a499f1741218a1dd0c129f4aa1de797bcf822c8ea5da7e4137aa3673431a96dae729047f7aca7b27866f - languageName: node - linkType: hard - -"v8-compile-cache-lib@npm:^3.0.0": - version: 3.0.0 - resolution: "v8-compile-cache-lib@npm:3.0.0" - checksum: 674e312bbca796584b61dc915f33c7e7dc4e06d196e0048cb772c8964493a1ec723f1dd014d9419fd55c24a6eae148f60769da23f622e05cd13268063fa1ed6b + uuid: dist/bin/uuid + checksum: 5575a8a75c13120e2f10e6ddc801b2c7ed7d8f3c8ac22c7ed0c7b2ba6383ec0abda88c905085d630e251719e0777045ae3236f04c812184b7c765f63a70e58df languageName: node linkType: hard -"v8-compile-cache@npm:^2.0.3": - version: 2.3.0 - resolution: "v8-compile-cache@npm:2.3.0" - checksum: adb0a271eaa2297f2f4c536acbfee872d0dd26ec2d76f66921aa7fc437319132773483344207bdbeee169225f4739016d8d2dbf0553913a52bb34da6d0334f8e +"v8-compile-cache-lib@npm:^3.0.1": + version: 3.0.1 + resolution: "v8-compile-cache-lib@npm:3.0.1" + checksum: 78089ad549e21bcdbfca10c08850022b22024cdcc2da9b168bcf5a73a6ed7bf01a9cebb9eac28e03cd23a684d81e0502797e88f3ccd27a32aeab1cfc44c39da0 languageName: node linkType: hard "which-module@npm:^2.0.0": - version: 2.0.0 - resolution: "which-module@npm:2.0.0" - checksum: 809f7fd3dfcb2cdbe0180b60d68100c88785084f8f9492b0998c051d7a8efe56784492609d3f09ac161635b78ea29219eb1418a98c15ce87d085bce905705c9c + version: 2.0.1 + resolution: "which-module@npm:2.0.1" + checksum: 1967b7ce17a2485544a4fdd9063599f0f773959cca24176dbe8f405e55472d748b7c549cd7920ff6abb8f1ab7db0b0f1b36de1a21c57a8ff741f4f1e792c52be languageName: node linkType: hard @@ -3474,7 +3709,7 @@ __metadata: languageName: node linkType: hard -"wide-align@npm:^1.1.2": +"wide-align@npm:^1.1.5": version: 1.1.5 resolution: "wide-align@npm:1.1.5" dependencies: @@ -3483,13 +3718,6 @@ __metadata: languageName: node linkType: hard -"word-wrap@npm:^1.2.3": - version: 1.2.3 - resolution: "word-wrap@npm:1.2.3" - checksum: 30b48f91fcf12106ed3186ae4fa86a6a1842416df425be7b60485de14bec665a54a68e4b5156647dec3a70f25e84d270ca8bc8cd23182ed095f5c7206a938c1f - languageName: node - linkType: hard - "workerpool@npm:6.2.0": version: 6.2.0 resolution: "workerpool@npm:6.2.0" @@ -3497,6 +3725,17 @@ __metadata: languageName: node linkType: hard +"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0, wrap-ansi@npm:^7.0.0": + version: 7.0.0 + resolution: "wrap-ansi@npm:7.0.0" + dependencies: + ansi-styles: ^4.0.0 + string-width: ^4.1.0 + strip-ansi: ^6.0.0 + checksum: a790b846fd4505de962ba728a21aaeda189b8ee1c7568ca5e817d85930e06ef8d1689d49dbf0e881e8ef84436af3a88bc49115c2e2788d841ff1b8b5b51a608b + languageName: node + linkType: hard + "wrap-ansi@npm:^6.2.0": version: 6.2.0 resolution: "wrap-ansi@npm:6.2.0" @@ -3508,14 +3747,14 @@ __metadata: languageName: node linkType: hard -"wrap-ansi@npm:^7.0.0": - version: 7.0.0 - resolution: "wrap-ansi@npm:7.0.0" +"wrap-ansi@npm:^8.1.0": + version: 8.1.0 + resolution: "wrap-ansi@npm:8.1.0" dependencies: - ansi-styles: ^4.0.0 - string-width: ^4.1.0 - strip-ansi: ^6.0.0 - checksum: a790b846fd4505de962ba728a21aaeda189b8ee1c7568ca5e817d85930e06ef8d1689d49dbf0e881e8ef84436af3a88bc49115c2e2788d841ff1b8b5b51a608b + ansi-styles: ^6.1.0 + string-width: ^5.0.1 + strip-ansi: ^7.0.1 + checksum: 371733296dc2d616900ce15a0049dca0ef67597d6394c57347ba334393599e800bab03c41d4d45221b6bc967b8c453ec3ae4749eff3894202d16800fdfe0e238 languageName: node linkType: hard @@ -3552,6 +3791,13 @@ __metadata: languageName: node linkType: hard +"yallist@npm:^3.0.2": + version: 3.1.1 + resolution: "yallist@npm:3.1.1" + checksum: 48f7bb00dc19fc635a13a39fe547f527b10c9290e7b3e836b9a8f1ca04d4d342e85714416b3c2ab74949c9c66f9cebb0473e6bc353b79035356103b47641285d + languageName: node + linkType: hard + "yallist@npm:^4.0.0": version: 4.0.0 resolution: "yallist@npm:4.0.0" From 178b39b632925182b05ee9e8e6e46004daef0405 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Fri, 7 Jul 2023 17:25:17 +0100 Subject: [PATCH 097/146] bump image in CircleCI --- .circleci/config.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 0cd1bb32..2f1c8d53 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -2,7 +2,7 @@ version: 2 jobs: build: docker: - - image: circleci/node:14-browsers + - image: cimg/node:20.4.0 working_directory: ~/intercom-node steps: - checkout @@ -25,7 +25,7 @@ jobs: - dist unit_test: docker: - - image: circleci/node:14-browsers + - image: cimg/node:20.4.0 working_directory: ~/intercom-node steps: - checkout @@ -34,7 +34,7 @@ jobs: - run: yarn test:unit integration_test: docker: - - image: circleci/node:14-browsers + - image: cimg/node:20.4.0 environment: API_TOKEN: $API_TOKEN working_directory: ~/intercom-node From 8449cd9e615d5160e2e3fd2455e84b3c9a228528 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Fri, 7 Jul 2023 17:56:04 +0100 Subject: [PATCH 098/146] fix tests --- package.json | 6 +++--- test/integration/admins.test.ts | 2 +- test/integration/articles.test.ts | 2 +- test/integration/companies.test.ts | 2 +- test/integration/contacts.test.ts | 2 +- test/integration/conversations.test.ts | 2 +- test/integration/counts.test.ts | 2 +- test/integration/dataAttributes.test.ts | 2 +- test/integration/dataExport.test.ts | 2 +- test/integration/events.test.ts | 4 ++-- test/integration/helpCenter/collections.test.ts | 2 +- test/integration/helpCenter/sections.test.ts | 2 +- test/integration/integration.test.ts | 2 +- test/integration/messages.test.ts | 2 +- test/integration/notes.test.ts | 2 +- test/integration/phoneCallRedirect.test.ts | 6 +++--- test/integration/segments.test.ts | 2 +- test/integration/subscriptions.test.ts | 2 +- test/integration/tags.test.ts | 2 +- test/integration/teams.test.ts | 2 +- test/integration/visitors.test.ts | 2 +- 21 files changed, 26 insertions(+), 26 deletions(-) diff --git a/package.json b/package.json index 8a897581..0ee56466 100644 --- a/package.json +++ b/package.json @@ -49,8 +49,8 @@ "compile_ts": "tsc", "move_compiled_to_dist": "mv dist/lib/* dist && rmdir dist/lib", "prepublish": "yarn clean && yarn static && yarn compile_ts && yarn move_compiled_to_dist", - "test:unit": "mocha -r ts-node/register test/unit/*.test.ts --reporter=nyan", - "test:integration": "mocha -r ts-node/register test/integration/**/*.test.ts --timeout=30000", + "test:unit": "yarn compile_ts && mocha -r ts-node/register test/unit/*.test.ts --reporter=nyan", + "test:integration": "yarn compile_ts && mocha -r ts-node/register test/integration/**/*.test.ts --timeout=30000", "coverage": "nyc yarn test" }, "engines": { @@ -58,4 +58,4 @@ }, "license": "Apache-2.0", "packageManager": "yarn@3.1.1" -} +} \ No newline at end of file diff --git a/test/integration/admins.test.ts b/test/integration/admins.test.ts index e8d55c06..cbfc62b7 100644 --- a/test/integration/admins.test.ts +++ b/test/integration/admins.test.ts @@ -1,5 +1,5 @@ import { token } from './utils/config'; -import { Client } from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; describe('Admins', () => { diff --git a/test/integration/articles.test.ts b/test/integration/articles.test.ts index 11730e76..9839a5bb 100644 --- a/test/integration/articles.test.ts +++ b/test/integration/articles.test.ts @@ -1,4 +1,4 @@ -import { Client } from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { randomString } from './utils/random'; diff --git a/test/integration/companies.test.ts b/test/integration/companies.test.ts index 403e62f1..49e00f7c 100644 --- a/test/integration/companies.test.ts +++ b/test/integration/companies.test.ts @@ -1,4 +1,4 @@ -import { Client, CompanyObject, Order } from '../../dist'; +import { Client, CompanyObject, Order } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { dateToUnixTimestamp } from '../../lib/util/time'; diff --git a/test/integration/contacts.test.ts b/test/integration/contacts.test.ts index b2eb718d..938811b7 100644 --- a/test/integration/contacts.test.ts +++ b/test/integration/contacts.test.ts @@ -1,4 +1,4 @@ -import { Client, ContactObject } from '../../dist'; +import { Client, ContactObject } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { randomString } from './utils/random'; diff --git a/test/integration/conversations.test.ts b/test/integration/conversations.test.ts index 5e69c8ae..04fc43b9 100644 --- a/test/integration/conversations.test.ts +++ b/test/integration/conversations.test.ts @@ -7,7 +7,7 @@ import { ContactObject, ConversationObject, MessageObject, -} from '../../dist'; +} from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { randomString } from './utils/random'; diff --git a/test/integration/counts.test.ts b/test/integration/counts.test.ts index 2eb3679f..a7da50d4 100644 --- a/test/integration/counts.test.ts +++ b/test/integration/counts.test.ts @@ -1,4 +1,4 @@ -import { Client } from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; diff --git a/test/integration/dataAttributes.test.ts b/test/integration/dataAttributes.test.ts index 077a86a4..d359a0c8 100644 --- a/test/integration/dataAttributes.test.ts +++ b/test/integration/dataAttributes.test.ts @@ -1,4 +1,4 @@ -import { Client, DataAttributeObject, DataType, ModelType } from '../../dist'; +import { Client, DataAttributeObject, DataType, ModelType } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { randomInt } from './utils/random'; diff --git a/test/integration/dataExport.test.ts b/test/integration/dataExport.test.ts index 90ce304e..475a5fa0 100644 --- a/test/integration/dataExport.test.ts +++ b/test/integration/dataExport.test.ts @@ -1,4 +1,4 @@ -import { Client } from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; diff --git a/test/integration/events.test.ts b/test/integration/events.test.ts index c60bbf39..1157fbc5 100644 --- a/test/integration/events.test.ts +++ b/test/integration/events.test.ts @@ -1,5 +1,5 @@ -import { Client, Operators, Role } from '../../dist'; -import { dateToUnixTimestamp } from '../../dist/util/time'; +import { Client, Operators, Role } from '../../lib'; +import { dateToUnixTimestamp } from '../../lib/util/time'; import assert from 'assert'; import { token } from './utils/config'; diff --git a/test/integration/helpCenter/collections.test.ts b/test/integration/helpCenter/collections.test.ts index 7dfb92ed..3f309bc6 100644 --- a/test/integration/helpCenter/collections.test.ts +++ b/test/integration/helpCenter/collections.test.ts @@ -1,4 +1,4 @@ -import { Client, CollectionObject } from '../../../dist'; +import { Client, CollectionObject } from '../../../lib'; import assert from 'assert'; import { token } from '../utils/config'; diff --git a/test/integration/helpCenter/sections.test.ts b/test/integration/helpCenter/sections.test.ts index 6fdc2acb..f9a58476 100644 --- a/test/integration/helpCenter/sections.test.ts +++ b/test/integration/helpCenter/sections.test.ts @@ -1,4 +1,4 @@ -import { Client, SectionObject } from '../../../dist'; +import { Client, SectionObject } from '../../../lib'; import assert from 'assert'; import { token } from '../utils/config'; import { randomString } from '../utils/random'; diff --git a/test/integration/integration.test.ts b/test/integration/integration.test.ts index 7b6f1b98..30141078 100644 --- a/test/integration/integration.test.ts +++ b/test/integration/integration.test.ts @@ -1,4 +1,4 @@ -import { Client, ContactObject, MessageObject } from '../../dist'; +import { Client, ContactObject, MessageObject } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { randomInt } from 'crypto'; diff --git a/test/integration/messages.test.ts b/test/integration/messages.test.ts index 5e07d2b6..d4efef97 100644 --- a/test/integration/messages.test.ts +++ b/test/integration/messages.test.ts @@ -1,5 +1,5 @@ import { token } from './utils/config'; -import { Client, Operators } from '../../dist'; +import { Client, Operators } from '../../lib'; import { randomString } from './utils/random'; import { MessageType } from '../../lib/message/message.types'; import { RecipientType } from '../../lib/message'; diff --git a/test/integration/notes.test.ts b/test/integration/notes.test.ts index d681ad93..7ee0d04e 100644 --- a/test/integration/notes.test.ts +++ b/test/integration/notes.test.ts @@ -1,4 +1,4 @@ -import { Client, NoteObject } from '../../dist'; +import { Client, NoteObject } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { randomString } from './utils/random'; diff --git a/test/integration/phoneCallRedirect.test.ts b/test/integration/phoneCallRedirect.test.ts index f926711c..9f960a6c 100644 --- a/test/integration/phoneCallRedirect.test.ts +++ b/test/integration/phoneCallRedirect.test.ts @@ -1,4 +1,4 @@ -import { Client} from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; @@ -6,8 +6,8 @@ describe('phoneCallRedirect', () => { const client = new Client({ tokenAuth: { token } }); it('create', async () => { - const response = await client.phoneCallRedirect.create({ - phone: '+353871234567' + const response = client.phoneCallRedirect.create({ + phone: '+353871234567', }); assert.notEqual(response, undefined); diff --git a/test/integration/segments.test.ts b/test/integration/segments.test.ts index 1869edb9..44e6239c 100644 --- a/test/integration/segments.test.ts +++ b/test/integration/segments.test.ts @@ -1,4 +1,4 @@ -import { Client } from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; diff --git a/test/integration/subscriptions.test.ts b/test/integration/subscriptions.test.ts index 5c57f1ff..2dde2816 100644 --- a/test/integration/subscriptions.test.ts +++ b/test/integration/subscriptions.test.ts @@ -1,4 +1,4 @@ -import { Client } from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; diff --git a/test/integration/tags.test.ts b/test/integration/tags.test.ts index 31314935..dfa61456 100644 --- a/test/integration/tags.test.ts +++ b/test/integration/tags.test.ts @@ -1,4 +1,4 @@ -import { Client, TagObject } from '../../dist'; +import { Client, TagObject } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; diff --git a/test/integration/teams.test.ts b/test/integration/teams.test.ts index 5fffa617..e276f4cb 100644 --- a/test/integration/teams.test.ts +++ b/test/integration/teams.test.ts @@ -1,4 +1,4 @@ -import { Client } from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; diff --git a/test/integration/visitors.test.ts b/test/integration/visitors.test.ts index edeb9a77..9f4829d3 100644 --- a/test/integration/visitors.test.ts +++ b/test/integration/visitors.test.ts @@ -1,4 +1,4 @@ -import { Client, Role } from '../../dist'; +import { Client, Role } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; From b464db7f926052e0a945c18358c93da27a46f9f4 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Fri, 7 Jul 2023 17:58:13 +0100 Subject: [PATCH 099/146] fix lint --- test/integration/phoneCallRedirect.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/integration/phoneCallRedirect.test.ts b/test/integration/phoneCallRedirect.test.ts index 9f960a6c..faf4148e 100644 --- a/test/integration/phoneCallRedirect.test.ts +++ b/test/integration/phoneCallRedirect.test.ts @@ -5,7 +5,7 @@ import { token } from './utils/config'; describe('phoneCallRedirect', () => { const client = new Client({ tokenAuth: { token } }); - it('create', async () => { + it('create', () => { const response = client.phoneCallRedirect.create({ phone: '+353871234567', }); From 353a2e888524c24960504b70f7b577e75e31cbec Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Mon, 10 Jul 2023 11:38:55 +0100 Subject: [PATCH 100/146] limit results for test listAllActivityLogs can take a long time to execute, so limit the search --- test/integration/admins.test.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/test/integration/admins.test.ts b/test/integration/admins.test.ts index cbfc62b7..6e258b60 100644 --- a/test/integration/admins.test.ts +++ b/test/integration/admins.test.ts @@ -23,6 +23,7 @@ describe('Admins', () => { it('listAllActivityLogs', async () => { const response = await client.admins.listAllActivityLogs({ after: new Date('2021-12-12'), + before: new Date('2022-01-01'), }); assert.notEqual(response, undefined); From 029b6ad2c005b38ae475161542a0529794378d26 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Fri, 7 Jul 2023 17:25:17 +0100 Subject: [PATCH 101/146] bump image in CircleCI --- .circleci/config.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 0cd1bb32..2f1c8d53 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -2,7 +2,7 @@ version: 2 jobs: build: docker: - - image: circleci/node:14-browsers + - image: cimg/node:20.4.0 working_directory: ~/intercom-node steps: - checkout @@ -25,7 +25,7 @@ jobs: - dist unit_test: docker: - - image: circleci/node:14-browsers + - image: cimg/node:20.4.0 working_directory: ~/intercom-node steps: - checkout @@ -34,7 +34,7 @@ jobs: - run: yarn test:unit integration_test: docker: - - image: circleci/node:14-browsers + - image: cimg/node:20.4.0 environment: API_TOKEN: $API_TOKEN working_directory: ~/intercom-node From 6a59c8737b04d7a32d86537c3d70ac012d454b80 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Fri, 7 Jul 2023 17:56:04 +0100 Subject: [PATCH 102/146] fix tests --- package.json | 6 +++--- test/integration/admins.test.ts | 2 +- test/integration/articles.test.ts | 2 +- test/integration/companies.test.ts | 2 +- test/integration/contacts.test.ts | 2 +- test/integration/conversations.test.ts | 2 +- test/integration/counts.test.ts | 2 +- test/integration/dataAttributes.test.ts | 2 +- test/integration/dataExport.test.ts | 2 +- test/integration/events.test.ts | 4 ++-- test/integration/helpCenter/collections.test.ts | 2 +- test/integration/helpCenter/sections.test.ts | 2 +- test/integration/integration.test.ts | 2 +- test/integration/messages.test.ts | 2 +- test/integration/notes.test.ts | 2 +- test/integration/phoneCallRedirect.test.ts | 6 +++--- test/integration/segments.test.ts | 2 +- test/integration/subscriptions.test.ts | 2 +- test/integration/tags.test.ts | 2 +- test/integration/teams.test.ts | 2 +- test/integration/visitors.test.ts | 2 +- 21 files changed, 26 insertions(+), 26 deletions(-) diff --git a/package.json b/package.json index 8a897581..0ee56466 100644 --- a/package.json +++ b/package.json @@ -49,8 +49,8 @@ "compile_ts": "tsc", "move_compiled_to_dist": "mv dist/lib/* dist && rmdir dist/lib", "prepublish": "yarn clean && yarn static && yarn compile_ts && yarn move_compiled_to_dist", - "test:unit": "mocha -r ts-node/register test/unit/*.test.ts --reporter=nyan", - "test:integration": "mocha -r ts-node/register test/integration/**/*.test.ts --timeout=30000", + "test:unit": "yarn compile_ts && mocha -r ts-node/register test/unit/*.test.ts --reporter=nyan", + "test:integration": "yarn compile_ts && mocha -r ts-node/register test/integration/**/*.test.ts --timeout=30000", "coverage": "nyc yarn test" }, "engines": { @@ -58,4 +58,4 @@ }, "license": "Apache-2.0", "packageManager": "yarn@3.1.1" -} +} \ No newline at end of file diff --git a/test/integration/admins.test.ts b/test/integration/admins.test.ts index e8d55c06..cbfc62b7 100644 --- a/test/integration/admins.test.ts +++ b/test/integration/admins.test.ts @@ -1,5 +1,5 @@ import { token } from './utils/config'; -import { Client } from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; describe('Admins', () => { diff --git a/test/integration/articles.test.ts b/test/integration/articles.test.ts index 11730e76..9839a5bb 100644 --- a/test/integration/articles.test.ts +++ b/test/integration/articles.test.ts @@ -1,4 +1,4 @@ -import { Client } from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { randomString } from './utils/random'; diff --git a/test/integration/companies.test.ts b/test/integration/companies.test.ts index 403e62f1..49e00f7c 100644 --- a/test/integration/companies.test.ts +++ b/test/integration/companies.test.ts @@ -1,4 +1,4 @@ -import { Client, CompanyObject, Order } from '../../dist'; +import { Client, CompanyObject, Order } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { dateToUnixTimestamp } from '../../lib/util/time'; diff --git a/test/integration/contacts.test.ts b/test/integration/contacts.test.ts index b2eb718d..938811b7 100644 --- a/test/integration/contacts.test.ts +++ b/test/integration/contacts.test.ts @@ -1,4 +1,4 @@ -import { Client, ContactObject } from '../../dist'; +import { Client, ContactObject } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { randomString } from './utils/random'; diff --git a/test/integration/conversations.test.ts b/test/integration/conversations.test.ts index 5e69c8ae..04fc43b9 100644 --- a/test/integration/conversations.test.ts +++ b/test/integration/conversations.test.ts @@ -7,7 +7,7 @@ import { ContactObject, ConversationObject, MessageObject, -} from '../../dist'; +} from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { randomString } from './utils/random'; diff --git a/test/integration/counts.test.ts b/test/integration/counts.test.ts index 2eb3679f..a7da50d4 100644 --- a/test/integration/counts.test.ts +++ b/test/integration/counts.test.ts @@ -1,4 +1,4 @@ -import { Client } from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; diff --git a/test/integration/dataAttributes.test.ts b/test/integration/dataAttributes.test.ts index 077a86a4..d359a0c8 100644 --- a/test/integration/dataAttributes.test.ts +++ b/test/integration/dataAttributes.test.ts @@ -1,4 +1,4 @@ -import { Client, DataAttributeObject, DataType, ModelType } from '../../dist'; +import { Client, DataAttributeObject, DataType, ModelType } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { randomInt } from './utils/random'; diff --git a/test/integration/dataExport.test.ts b/test/integration/dataExport.test.ts index 90ce304e..475a5fa0 100644 --- a/test/integration/dataExport.test.ts +++ b/test/integration/dataExport.test.ts @@ -1,4 +1,4 @@ -import { Client } from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; diff --git a/test/integration/events.test.ts b/test/integration/events.test.ts index c60bbf39..1157fbc5 100644 --- a/test/integration/events.test.ts +++ b/test/integration/events.test.ts @@ -1,5 +1,5 @@ -import { Client, Operators, Role } from '../../dist'; -import { dateToUnixTimestamp } from '../../dist/util/time'; +import { Client, Operators, Role } from '../../lib'; +import { dateToUnixTimestamp } from '../../lib/util/time'; import assert from 'assert'; import { token } from './utils/config'; diff --git a/test/integration/helpCenter/collections.test.ts b/test/integration/helpCenter/collections.test.ts index 7dfb92ed..3f309bc6 100644 --- a/test/integration/helpCenter/collections.test.ts +++ b/test/integration/helpCenter/collections.test.ts @@ -1,4 +1,4 @@ -import { Client, CollectionObject } from '../../../dist'; +import { Client, CollectionObject } from '../../../lib'; import assert from 'assert'; import { token } from '../utils/config'; diff --git a/test/integration/helpCenter/sections.test.ts b/test/integration/helpCenter/sections.test.ts index 6fdc2acb..f9a58476 100644 --- a/test/integration/helpCenter/sections.test.ts +++ b/test/integration/helpCenter/sections.test.ts @@ -1,4 +1,4 @@ -import { Client, SectionObject } from '../../../dist'; +import { Client, SectionObject } from '../../../lib'; import assert from 'assert'; import { token } from '../utils/config'; import { randomString } from '../utils/random'; diff --git a/test/integration/integration.test.ts b/test/integration/integration.test.ts index 7b6f1b98..30141078 100644 --- a/test/integration/integration.test.ts +++ b/test/integration/integration.test.ts @@ -1,4 +1,4 @@ -import { Client, ContactObject, MessageObject } from '../../dist'; +import { Client, ContactObject, MessageObject } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { randomInt } from 'crypto'; diff --git a/test/integration/messages.test.ts b/test/integration/messages.test.ts index 5e07d2b6..d4efef97 100644 --- a/test/integration/messages.test.ts +++ b/test/integration/messages.test.ts @@ -1,5 +1,5 @@ import { token } from './utils/config'; -import { Client, Operators } from '../../dist'; +import { Client, Operators } from '../../lib'; import { randomString } from './utils/random'; import { MessageType } from '../../lib/message/message.types'; import { RecipientType } from '../../lib/message'; diff --git a/test/integration/notes.test.ts b/test/integration/notes.test.ts index d681ad93..7ee0d04e 100644 --- a/test/integration/notes.test.ts +++ b/test/integration/notes.test.ts @@ -1,4 +1,4 @@ -import { Client, NoteObject } from '../../dist'; +import { Client, NoteObject } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { randomString } from './utils/random'; diff --git a/test/integration/phoneCallRedirect.test.ts b/test/integration/phoneCallRedirect.test.ts index f926711c..9f960a6c 100644 --- a/test/integration/phoneCallRedirect.test.ts +++ b/test/integration/phoneCallRedirect.test.ts @@ -1,4 +1,4 @@ -import { Client} from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; @@ -6,8 +6,8 @@ describe('phoneCallRedirect', () => { const client = new Client({ tokenAuth: { token } }); it('create', async () => { - const response = await client.phoneCallRedirect.create({ - phone: '+353871234567' + const response = client.phoneCallRedirect.create({ + phone: '+353871234567', }); assert.notEqual(response, undefined); diff --git a/test/integration/segments.test.ts b/test/integration/segments.test.ts index 1869edb9..44e6239c 100644 --- a/test/integration/segments.test.ts +++ b/test/integration/segments.test.ts @@ -1,4 +1,4 @@ -import { Client } from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; diff --git a/test/integration/subscriptions.test.ts b/test/integration/subscriptions.test.ts index 5c57f1ff..2dde2816 100644 --- a/test/integration/subscriptions.test.ts +++ b/test/integration/subscriptions.test.ts @@ -1,4 +1,4 @@ -import { Client } from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; diff --git a/test/integration/tags.test.ts b/test/integration/tags.test.ts index 31314935..dfa61456 100644 --- a/test/integration/tags.test.ts +++ b/test/integration/tags.test.ts @@ -1,4 +1,4 @@ -import { Client, TagObject } from '../../dist'; +import { Client, TagObject } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; diff --git a/test/integration/teams.test.ts b/test/integration/teams.test.ts index 5fffa617..e276f4cb 100644 --- a/test/integration/teams.test.ts +++ b/test/integration/teams.test.ts @@ -1,4 +1,4 @@ -import { Client } from '../../dist'; +import { Client } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; diff --git a/test/integration/visitors.test.ts b/test/integration/visitors.test.ts index edeb9a77..9f4829d3 100644 --- a/test/integration/visitors.test.ts +++ b/test/integration/visitors.test.ts @@ -1,4 +1,4 @@ -import { Client, Role } from '../../dist'; +import { Client, Role } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; From 466d49088b3f1de2982080cedb880278128bd226 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Fri, 7 Jul 2023 17:58:13 +0100 Subject: [PATCH 103/146] fix lint --- test/integration/phoneCallRedirect.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/integration/phoneCallRedirect.test.ts b/test/integration/phoneCallRedirect.test.ts index 9f960a6c..faf4148e 100644 --- a/test/integration/phoneCallRedirect.test.ts +++ b/test/integration/phoneCallRedirect.test.ts @@ -5,7 +5,7 @@ import { token } from './utils/config'; describe('phoneCallRedirect', () => { const client = new Client({ tokenAuth: { token } }); - it('create', async () => { + it('create', () => { const response = client.phoneCallRedirect.create({ phone: '+353871234567', }); From 8d0b79f3bb35c7fdf980f99f8a23d41187872139 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Mon, 10 Jul 2023 11:38:55 +0100 Subject: [PATCH 104/146] limit results for test listAllActivityLogs can take a long time to execute, so limit the search --- test/integration/admins.test.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/test/integration/admins.test.ts b/test/integration/admins.test.ts index cbfc62b7..6e258b60 100644 --- a/test/integration/admins.test.ts +++ b/test/integration/admins.test.ts @@ -23,6 +23,7 @@ describe('Admins', () => { it('listAllActivityLogs', async () => { const response = await client.admins.listAllActivityLogs({ after: new Date('2021-12-12'), + before: new Date('2022-01-01'), }); assert.notEqual(response, undefined); From 0755c9eb81e0fde33877c6fac11a8e04a5a9bed7 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Mon, 10 Jul 2023 12:00:53 +0100 Subject: [PATCH 105/146] Update tag_id --- test/integration/companies.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/integration/companies.test.ts b/test/integration/companies.test.ts index 49e00f7c..24ab0b79 100644 --- a/test/integration/companies.test.ts +++ b/test/integration/companies.test.ts @@ -69,7 +69,7 @@ describe('Companies', () => { page: 1, perPage: 35, order: Order.DESC, - tagId: '2084335', + tagId: '7882526', }); assert.notEqual(response, undefined); From b12c5fd397ec1482427af5a216d8ab7a27729431 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 10 Jul 2023 11:08:03 +0000 Subject: [PATCH 106/146] Bump http-cache-semantics from 4.1.0 to 4.1.1 Bumps [http-cache-semantics](https://github.com/kornelski/http-cache-semantics) from 4.1.0 to 4.1.1. - [Commits](https://github.com/kornelski/http-cache-semantics/compare/v4.1.0...v4.1.1) --- updated-dependencies: - dependency-name: http-cache-semantics dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 6b01cb85..23dc2485 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1808,9 +1808,9 @@ __metadata: linkType: hard "http-cache-semantics@npm:^4.1.0": - version: 4.1.0 - resolution: "http-cache-semantics@npm:4.1.0" - checksum: 974de94a81c5474be07f269f9fd8383e92ebb5a448208223bfb39e172a9dbc26feff250192ecc23b9593b3f92098e010406b0f24bd4d588d631f80214648ed42 + version: 4.1.1 + resolution: "http-cache-semantics@npm:4.1.1" + checksum: 83ac0bc60b17a3a36f9953e7be55e5c8f41acc61b22583060e8dedc9dd5e3607c823a88d0926f9150e571f90946835c7fe150732801010845c72cd8bbff1a236 languageName: node linkType: hard From 99f47ce3af9e9275d03823a1fac6e1cbc53b2296 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 10 Jul 2023 11:08:10 +0000 Subject: [PATCH 107/146] Bump json5 from 2.2.0 to 2.2.3 Bumps [json5](https://github.com/json5/json5) from 2.2.0 to 2.2.3. - [Release notes](https://github.com/json5/json5/releases) - [Changelog](https://github.com/json5/json5/blob/main/CHANGELOG.md) - [Commits](https://github.com/json5/json5/compare/v2.2.0...v2.2.3) --- updated-dependencies: - dependency-name: json5 dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/yarn.lock b/yarn.lock index 6b01cb85..143bd158 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2182,13 +2182,11 @@ __metadata: linkType: hard "json5@npm:^2.1.2": - version: 2.2.0 - resolution: "json5@npm:2.2.0" - dependencies: - minimist: ^1.2.5 + version: 2.2.3 + resolution: "json5@npm:2.2.3" bin: json5: lib/cli.js - checksum: e88fc5274bb58fc99547baa777886b069d2dd96d9cfc4490b305fd16d711dabd5979e35a4f90873cefbeb552e216b041a304fe56702bedba76e19bc7845f208d + checksum: 2a7436a93393830bce797d4626275152e37e877b265e94ca69c99e3d20c2b9dab021279146a39cdb700e71b2dd32a4cebd1514cd57cee102b1af906ce5040349 languageName: node linkType: hard @@ -2365,13 +2363,6 @@ __metadata: languageName: node linkType: hard -"minimist@npm:^1.2.5": - version: 1.2.7 - resolution: "minimist@npm:1.2.7" - checksum: 7346574a1038ca23c32e02252f603801f09384dd1d78b69a943a4e8c2c28730b80e96193882d3d3b22a063445f460e48316b29b8a25addca2d7e5e8f75478bec - languageName: node - linkType: hard - "minipass-collect@npm:^1.0.2": version: 1.0.2 resolution: "minipass-collect@npm:1.0.2" From dd48ce5514b9882676ba1ad2259307cffb8d0ae5 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Mon, 10 Jul 2023 12:19:03 +0100 Subject: [PATCH 108/146] fix yarn --- package.json | 2 +- yarn.lock | 61 ++++++++++++++++++++++++++++++---------------------- 2 files changed, 36 insertions(+), 27 deletions(-) diff --git a/package.json b/package.json index 0ee56466..f3bbfe81 100644 --- a/package.json +++ b/package.json @@ -58,4 +58,4 @@ }, "license": "Apache-2.0", "packageManager": "yarn@3.1.1" -} \ No newline at end of file +} diff --git a/yarn.lock b/yarn.lock index c4be0d64..0b696776 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1065,9 +1065,9 @@ __metadata: linkType: hard "caniuse-lite@npm:^1.0.30001503": - version: 1.0.30001513 - resolution: "caniuse-lite@npm:1.0.30001513" - checksum: 7d783f4f40584e7bdeda3f3abc23ffff21f14c37e1fadf1a6b3d2e299727fe9d5a61096101d9d4e4174f881d4ff4c62204fc41f3bc950f4da1b0edfdea025fa4 + version: 1.0.30001514 + resolution: "caniuse-lite@npm:1.0.30001514" + checksum: ee2e90fe63cb59fb4a1515eb6b157f1c26d3ccba496b994b0f03088c39c282ee2fb8c160ad7b677ee196b5bb078b23f2f9474c32e4e47724f4d782de92bb8bbe languageName: node linkType: hard @@ -1349,9 +1349,9 @@ __metadata: linkType: hard "electron-to-chromium@npm:^1.4.431": - version: 1.4.453 - resolution: "electron-to-chromium@npm:1.4.453" - checksum: dcd354388b2b60fb0158a6daf7a3a93796b9f6e0045bc507021bcbbf72790cb94c5bb549f699150e18d090321bca0583d729bc479d2d48a0c94a29b1a2f0165e + version: 1.4.454 + resolution: "electron-to-chromium@npm:1.4.454" + checksum: 26a756485b442be04a640b8733c3e0d1ad9630541e56906332b1a5f25ec0027647561ec98d0d2a5069a1aae3875c9751c6d1c6cb9ef400b2beabedc36da14ba1 languageName: node linkType: hard @@ -1850,17 +1850,17 @@ __metadata: linkType: hard "glob@npm:^10.2.2": - version: 10.3.1 - resolution: "glob@npm:10.3.1" + version: 10.3.3 + resolution: "glob@npm:10.3.3" dependencies: foreground-child: ^3.1.0 jackspeak: ^2.0.3 minimatch: ^9.0.1 - minipass: ^5.0.0 || ^6.0.2 - path-scurry: ^1.10.0 + minipass: ^5.0.0 || ^6.0.2 || ^7.0.0 + path-scurry: ^1.10.1 bin: glob: dist/cjs/src/bin.js - checksum: 19c8c2805658b1002fecf0722cd609a33153d756a0d5260676bd0e9c5e6ef889ec9cce6d3dac0411aa90bce8de3d14f25b6f5589a3292582cccbfeddd0e98cc4 + checksum: 29190d3291f422da0cb40b77a72fc8d2c51a36524e99b8bf412548b7676a6627489528b57250429612b6eec2e6fe7826d328451d3e694a9d15e575389308ec53 languageName: node linkType: hard @@ -1983,7 +1983,7 @@ __metadata: languageName: node linkType: hard -"http-cache-semantics@npm:^4.1.0": +"http-cache-semantics@npm:^4.1.1": version: 4.1.1 resolution: "http-cache-semantics@npm:4.1.1" checksum: 83ac0bc60b17a3a36f9953e7be55e5c8f41acc61b22583060e8dedc9dd5e3607c823a88d0926f9150e571f90946835c7fe150732801010845c72cd8bbff1a236 @@ -2362,7 +2362,7 @@ __metadata: languageName: node linkType: hard -"json5@npm:^2.1.2": +"json5@npm:^2.2.2": version: 2.2.3 resolution: "json5@npm:2.2.3" bin: @@ -2555,7 +2555,16 @@ __metadata: resolution: "minimatch@npm:3.1.2" dependencies: brace-expansion: ^1.1.7 - checksum: a3b84b426eafca947741b864502cee02860c4e7b145de11ad98775cfcf3066fef422583bc0ffce0952ddf4750c1ccf4220b1556430d4ce10139f66247d87d69e + checksum: c154e566406683e7bcb746e000b84d74465b3a832c45d59912b9b55cd50dee66e5c4b1e5566dba26154040e51672f9aa450a9aef0c97cfc7336b78b7afb9540a + languageName: node + linkType: hard + +"minimatch@npm:^9.0.1": + version: 9.0.3 + resolution: "minimatch@npm:9.0.3" + dependencies: + brace-expansion: ^2.0.1 + checksum: 253487976bf485b612f16bf57463520a14f512662e592e95c571afdab1442a6a6864b6c88f248ce6fc4ff0b6de04ac7aa6c8bb51e868e99d1d65eb0658a708b5 languageName: node linkType: hard @@ -2626,10 +2635,10 @@ __metadata: languageName: node linkType: hard -"minipass@npm:^5.0.0 || ^6.0.2": - version: 6.0.2 - resolution: "minipass@npm:6.0.2" - checksum: d140b91f4ab2e5ce5a9b6c468c0e82223504acc89114c1a120d4495188b81fedf8cade72a9f4793642b4e66672f990f1e0d902dd858485216a07cd3c8a62fac9 +"minipass@npm:^5.0.0 || ^6.0.2 || ^7.0.0": + version: 7.0.1 + resolution: "minipass@npm:7.0.1" + checksum: fedd1293f6a1b4e406c242a1cecfb75d0a81422bb2c365d999e33a88642fb68d70a89d95b550e08c640b3c0d9162829310e0c58b9b846b9218de25779818c709 languageName: node linkType: hard @@ -2986,13 +2995,13 @@ __metadata: languageName: node linkType: hard -"path-scurry@npm:^1.10.0": - version: 1.10.0 - resolution: "path-scurry@npm:1.10.0" +"path-scurry@npm:^1.10.1": + version: 1.10.1 + resolution: "path-scurry@npm:1.10.1" dependencies: lru-cache: ^9.1.1 || ^10.0.0 - minipass: ^5.0.0 || ^6.0.2 - checksum: 3b66a4a6ab66e45755b577c966ecf0da92d3e068b3c992d8f69aa2cc908ef4eda9358253e9b4f86cad43d3ad810ec445be164105975f5cb3fdab68459c59dc6e + minipass: ^5.0.0 || ^6.0.2 || ^7.0.0 + checksum: e2557cff3a8fb8bc07afdd6ab163a92587884f9969b05bbbaf6fe7379348bfb09af9ed292af12ed32398b15fb443e81692047b786d1eeb6d898a51eb17ed7d90 languageName: node linkType: hard @@ -3215,13 +3224,13 @@ __metadata: linkType: hard "semver@npm:^7.3.5, semver@npm:^7.3.7": - version: 7.5.3 - resolution: "semver@npm:7.5.3" + version: 7.5.4 + resolution: "semver@npm:7.5.4" dependencies: lru-cache: ^6.0.0 bin: semver: bin/semver.js - checksum: 9d58db16525e9f749ad0a696a1f27deabaa51f66e91d2fa2b0db3de3e9644e8677de3b7d7a03f4c15bc81521e0c3916d7369e0572dbde250d9bedf5194e2a8a7 + checksum: 12d8ad952fa353b0995bf180cdac205a4068b759a140e5d3c608317098b3575ac2f1e09182206bf2eb26120e1c0ed8fb92c48c592f6099680de56bb071423ca3 languageName: node linkType: hard From e9d77bb53890a79c4e680d0a7b0a56fdb4b4b8ae Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Mon, 10 Jul 2023 12:33:04 +0100 Subject: [PATCH 109/146] bump versions --- package.json | 32 +-- yarn.lock | 610 ++++++++++++++++++++++++++++----------------------- 2 files changed, 351 insertions(+), 291 deletions(-) diff --git a/package.json b/package.json index 0ee56466..1cc3dd27 100644 --- a/package.json +++ b/package.json @@ -24,24 +24,24 @@ }, "devDependencies": { "@istanbuljs/nyc-config-typescript": "^1.0.2", - "@types/lodash": "^4.14.176", - "@types/mocha": "^9.1.0", - "@types/node": "^16.11.6", - "@types/sinon": "^10.0.6", - "@typescript-eslint/eslint-plugin": "^5.7.0", - "@typescript-eslint/parser": "^5.7.0", - "eslint": "^8.2.0", - "eslint-config-prettier": "^8.3.0", + "@types/lodash": "^4.14.195", + "@types/mocha": "^9.1.1", + "@types/node": "^16.18.38", + "@types/sinon": "^10.0.15", + "@typescript-eslint/eslint-plugin": "^5.61.0", + "@typescript-eslint/parser": "^5.61.0", + "eslint": "^8.44.0", + "eslint-config-prettier": "^8.8.0", "eslint-plugin-no-only-tests": "^2.6.0", "merge2": "^1.4.1", - "mocha": "^9.2.0", - "nock": "^13.0.11", + "mocha": "^9.2.2", + "nock": "^13.3.1", "nyc": "^15.1.0", - "prettier": "^2.5.1", - "sinon": "^7.3.2", - "ts-node": "^10.4.0", - "tslib": "^2.3.1", - "typescript": "^4.5.3" + "prettier": "^2.8.8", + "sinon": "^7.5.0", + "ts-node": "^10.9.1", + "tslib": "^2.6.0", + "typescript": "^4.9.5" }, "scripts": { "clean": "rm -r -f dist", @@ -58,4 +58,4 @@ }, "license": "Apache-2.0", "packageManager": "yarn@3.1.1" -} \ No newline at end of file +} diff --git a/yarn.lock b/yarn.lock index af05f0af..38730f34 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5,6 +5,13 @@ __metadata: version: 5 cacheKey: 8 +"@aashutoshrathi/word-wrap@npm:^1.2.3": + version: 1.2.6 + resolution: "@aashutoshrathi/word-wrap@npm:1.2.6" + checksum: ada901b9e7c680d190f1d012c84217ce0063d8f5c5a7725bb91ec3c5ed99bb7572680eb2d2938a531ccbaec39a95422fcd8a6b4a13110c7d98dd75402f66a0cd + languageName: node + linkType: hard + "@ampproject/remapping@npm:^2.0.0": version: 2.1.0 resolution: "@ampproject/remapping@npm:2.1.0" @@ -243,36 +250,54 @@ __metadata: languageName: node linkType: hard -"@cspotcode/source-map-consumer@npm:0.8.0": - version: 0.8.0 - resolution: "@cspotcode/source-map-consumer@npm:0.8.0" - checksum: c0c16ca3d2f58898f1bd74c4f41a189dbcc202e642e60e489cbcc2e52419c4e89bdead02c886a12fb13ea37798ede9e562b2321df997ebc210ae9bd881561b4e +"@cspotcode/source-map-support@npm:^0.8.0": + version: 0.8.1 + resolution: "@cspotcode/source-map-support@npm:0.8.1" + dependencies: + "@jridgewell/trace-mapping": 0.3.9 + checksum: 5718f267085ed8edb3e7ef210137241775e607ee18b77d95aa5bd7514f47f5019aa2d82d96b3bf342ef7aa890a346fa1044532ff7cc3009e7d24fce3ce6200fa languageName: node linkType: hard -"@cspotcode/source-map-support@npm:0.7.0": - version: 0.7.0 - resolution: "@cspotcode/source-map-support@npm:0.7.0" +"@eslint-community/eslint-utils@npm:^4.2.0": + version: 4.4.0 + resolution: "@eslint-community/eslint-utils@npm:4.4.0" dependencies: - "@cspotcode/source-map-consumer": 0.8.0 - checksum: 9faddda7757cd778b5fd6812137b2cc265810043680d6399acc20441668fafcdc874053be9dccd0d9110087287bfad27eb3bf342f72bceca9aa9059f5d0c4be8 + eslint-visitor-keys: ^3.3.0 + peerDependencies: + eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 + checksum: cdfe3ae42b4f572cbfb46d20edafe6f36fc5fb52bf2d90875c58aefe226892b9677fef60820e2832caf864a326fe4fc225714c46e8389ccca04d5f9288aabd22 languageName: node linkType: hard -"@eslint/eslintrc@npm:^1.0.5": - version: 1.0.5 - resolution: "@eslint/eslintrc@npm:1.0.5" +"@eslint-community/regexpp@npm:^4.4.0": + version: 4.5.1 + resolution: "@eslint-community/regexpp@npm:4.5.1" + checksum: 6d901166d64998d591fab4db1c2f872981ccd5f6fe066a1ad0a93d4e11855ecae6bfb76660869a469563e8882d4307228cebd41142adb409d182f2966771e57e + languageName: node + linkType: hard + +"@eslint/eslintrc@npm:^2.1.0": + version: 2.1.0 + resolution: "@eslint/eslintrc@npm:2.1.0" dependencies: ajv: ^6.12.4 debug: ^4.3.2 - espree: ^9.2.0 - globals: ^13.9.0 - ignore: ^4.0.6 + espree: ^9.6.0 + globals: ^13.19.0 + ignore: ^5.2.0 import-fresh: ^3.2.1 js-yaml: ^4.1.0 - minimatch: ^3.0.4 + minimatch: ^3.1.2 strip-json-comments: ^3.1.1 - checksum: b35b50d7b65bd8acd92a05b6fb15ac62c0cefa40dfef0324ca5bf8632bf3679bab6e173c53b3ad1e1d837701cecdbd9c144b35f46588cdf4e046a9caa272488d + checksum: d5ed0adbe23f6571d8c9bb0ca6edf7618dc6aed4046aa56df7139f65ae7b578874e0d9c796df784c25bda648ceb754b6320277d828c8b004876d7443b8dc018c + languageName: node + linkType: hard + +"@eslint/js@npm:8.44.0": + version: 8.44.0 + resolution: "@eslint/js@npm:8.44.0" + checksum: fc539583226a28f5677356e9f00d2789c34253f076643d2e32888250e509a4e13aafe0880cb2425139051de0f3a48d25bfc5afa96b7304f203b706c17340e3cf languageName: node linkType: hard @@ -283,14 +308,21 @@ __metadata: languageName: node linkType: hard -"@humanwhocodes/config-array@npm:^0.9.2": - version: 0.9.3 - resolution: "@humanwhocodes/config-array@npm:0.9.3" +"@humanwhocodes/config-array@npm:^0.11.10": + version: 0.11.10 + resolution: "@humanwhocodes/config-array@npm:0.11.10" dependencies: "@humanwhocodes/object-schema": ^1.2.1 debug: ^4.1.1 - minimatch: ^3.0.4 - checksum: 6e5d7d274941c459bab0a14a87e372206d89fad3e4879d982edc942e8cc34da6510ea3644b8535a2a9edaa6527e91dccceabc6837ffa8ee506d66bca5d269ebc + minimatch: ^3.0.5 + checksum: 1b1302e2403d0e35bc43e66d67a2b36b0ad1119efc704b5faff68c41f791a052355b010fb2d27ef022670f550de24cd6d08d5ecf0821c16326b7dcd0ee5d5d8a + languageName: node + linkType: hard + +"@humanwhocodes/module-importer@npm:^1.0.1": + version: 1.0.1 + resolution: "@humanwhocodes/module-importer@npm:1.0.1" + checksum: 0fd22007db8034a2cdf2c764b140d37d9020bbfce8a49d3ec5c05290e77d4b0263b1b972b752df8c89e5eaa94073408f2b7d977aed131faf6cf396ebb5d7fb61 languageName: node linkType: hard @@ -346,6 +378,16 @@ __metadata: languageName: node linkType: hard +"@jridgewell/trace-mapping@npm:0.3.9": + version: 0.3.9 + resolution: "@jridgewell/trace-mapping@npm:0.3.9" + dependencies: + "@jridgewell/resolve-uri": ^3.0.3 + "@jridgewell/sourcemap-codec": ^1.4.10 + checksum: d89597752fd88d3f3480845691a05a44bd21faac18e2185b6f436c3b0fd0c5a859fbbd9aaa92050c4052caf325ad3e10e2e1d1b64327517471b7d51babc0ddef + languageName: node + linkType: hard + "@jridgewell/trace-mapping@npm:^0.3.0": version: 0.3.2 resolution: "@jridgewell/trace-mapping@npm:0.3.2" @@ -373,7 +415,7 @@ __metadata: languageName: node linkType: hard -"@nodelib/fs.walk@npm:^1.2.3": +"@nodelib/fs.walk@npm:^1.2.3, @nodelib/fs.walk@npm:^1.2.8": version: 1.2.8 resolution: "@nodelib/fs.walk@npm:1.2.8" dependencies: @@ -482,33 +524,40 @@ __metadata: languageName: node linkType: hard -"@types/lodash@npm:^4.14.176": - version: 4.14.178 - resolution: "@types/lodash@npm:4.14.178" - checksum: a69a04a60bfc5257c3130a554b4efa0c383f0141b7b3db8ab7cf07ad2a46ea085fce66d0242da41da7e5647b133d5dfb2c15add9cbed8d7fef955e4a1e5b3128 +"@types/lodash@npm:^4.14.195": + version: 4.14.195 + resolution: "@types/lodash@npm:4.14.195" + checksum: 39b75ca635b3fa943d17d3d3aabc750babe4c8212485a4df166fe0516e39288e14b0c60afc6e21913cc0e5a84734633c71e617e2bd14eaa1cf51b8d7799c432e languageName: node linkType: hard -"@types/mocha@npm:^9.1.0": - version: 9.1.0 - resolution: "@types/mocha@npm:9.1.0" - checksum: 21e1000dafcfe387c6812be41c44a47b48c27a74d5a70c3d5ef1bb5c88eadadfc74dba06e93f160e7248c8a57b3977b590f82504c801c9927816ecd4668023c0 +"@types/mocha@npm:^9.1.1": + version: 9.1.1 + resolution: "@types/mocha@npm:9.1.1" + checksum: 516077c0acd9806dc78317f88aaac0df5aaf0bdc2f63dfdadeabdf0b0137953b6ca65472e6ff7c30bc93ce4e0ae76eae70e8d46764b9a8eae4877a928b6ef49a languageName: node linkType: hard -"@types/node@npm:^16.11.6": - version: 16.11.22 - resolution: "@types/node@npm:16.11.22" - checksum: 9d879b9b0427e21a11e3162917553d5bc3c7d68d1ef4aa631512144801fe59bc3b4da5965e7ea7c2db99394487b543d4f2499b318e12392574802ac4f975b7c4 +"@types/node@npm:^16.18.38": + version: 16.18.38 + resolution: "@types/node@npm:16.18.38" + checksum: a3baa141e49ce94486f083eea1240cf38479a73ba663e1bf3f52f85b466125821b6e3ea85ded38fde3901530aca4601291395a50eefcea533a4f3b45171bda28 languageName: node linkType: hard -"@types/sinon@npm:^10.0.6": - version: 10.0.11 - resolution: "@types/sinon@npm:10.0.11" +"@types/semver@npm:^7.3.12": + version: 7.5.0 + resolution: "@types/semver@npm:7.5.0" + checksum: 0a64b9b9c7424d9a467658b18dd70d1d781c2d6f033096a6e05762d20ebbad23c1b69b0083b0484722aabf35640b78ccc3de26368bcae1129c87e9df028a22e2 + languageName: node + linkType: hard + +"@types/sinon@npm:^10.0.15": + version: 10.0.15 + resolution: "@types/sinon@npm:10.0.15" dependencies: "@types/sinonjs__fake-timers": "*" - checksum: 196f3e26985dca5dfb593592e4b64463e536c047a9f43aa2b328b16024a3b0e3fb27b7a3f3972c6ef75749f55012737eb6c63a1c2e9782b7fe5cbbd25f75fd62 + checksum: cec6d7d9d5582ca3ac851b029d5d90451bfe6d376164253792a6eb6ddcd609a0411a7fac9ed92e1879e7d3ec091d2ea2e8dbb4f6140a1065439b81dc20cafa7c languageName: node linkType: hard @@ -519,18 +568,19 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/eslint-plugin@npm:^5.7.0": - version: 5.11.0 - resolution: "@typescript-eslint/eslint-plugin@npm:5.11.0" +"@typescript-eslint/eslint-plugin@npm:^5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/eslint-plugin@npm:5.61.0" dependencies: - "@typescript-eslint/scope-manager": 5.11.0 - "@typescript-eslint/type-utils": 5.11.0 - "@typescript-eslint/utils": 5.11.0 - debug: ^4.3.2 - functional-red-black-tree: ^1.0.1 - ignore: ^5.1.8 - regexpp: ^3.2.0 - semver: ^7.3.5 + "@eslint-community/regexpp": ^4.4.0 + "@typescript-eslint/scope-manager": 5.61.0 + "@typescript-eslint/type-utils": 5.61.0 + "@typescript-eslint/utils": 5.61.0 + debug: ^4.3.4 + graphemer: ^1.4.0 + ignore: ^5.2.0 + natural-compare-lite: ^1.4.0 + semver: ^7.3.7 tsutils: ^3.21.0 peerDependencies: "@typescript-eslint/parser": ^5.0.0 @@ -538,101 +588,104 @@ __metadata: peerDependenciesMeta: typescript: optional: true - checksum: fa546ba4397f3e693870c39d1e8df6feccb728a7092be6312b78806a64c4ff4648cff0462503d3e510e8b173b9704c19e78d2a7af790ab1c0309782e33a89c32 + checksum: d9e891fb43ccb75322fc40d58d02479f98bd3c962db71075438868b13f579643d714a24b5477a827be7ca2e7e9f6058c406241b6696a6395c6fcbd6de76e015c languageName: node linkType: hard -"@typescript-eslint/parser@npm:^5.7.0": - version: 5.11.0 - resolution: "@typescript-eslint/parser@npm:5.11.0" +"@typescript-eslint/parser@npm:^5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/parser@npm:5.61.0" dependencies: - "@typescript-eslint/scope-manager": 5.11.0 - "@typescript-eslint/types": 5.11.0 - "@typescript-eslint/typescript-estree": 5.11.0 - debug: ^4.3.2 + "@typescript-eslint/scope-manager": 5.61.0 + "@typescript-eslint/types": 5.61.0 + "@typescript-eslint/typescript-estree": 5.61.0 + debug: ^4.3.4 peerDependencies: eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 peerDependenciesMeta: typescript: optional: true - checksum: 521b6e701d877dc0514c6a3992f4900aa6fea28ba7c0bc03c634dad2b50aa195401e45683dfebd9e8492a857cd84bba3b585d8fe8d0cd1d7e2720372c34c50a3 + checksum: 2422bca03ecc6830700aaa739ec46b8e9ab6c0a47a67f140dc6b62a42a8b98997e73bce52c6a010b8a9b461211c46ba865d5b7f680a7823cf5c245d3b61f7fd5 languageName: node linkType: hard -"@typescript-eslint/scope-manager@npm:5.11.0": - version: 5.11.0 - resolution: "@typescript-eslint/scope-manager@npm:5.11.0" +"@typescript-eslint/scope-manager@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/scope-manager@npm:5.61.0" dependencies: - "@typescript-eslint/types": 5.11.0 - "@typescript-eslint/visitor-keys": 5.11.0 - checksum: bf7feaed495ed4cafa1b89a2b73781b30061d019e1c1b3765dc8006e7f36b537f6f451e37c77400067771318b4f0c5915804084dc6299ea7c6ecde2daf0aca1c + "@typescript-eslint/types": 5.61.0 + "@typescript-eslint/visitor-keys": 5.61.0 + checksum: 6dfbb42c4b7d796ae3c395398bdfd2e5a4ae8aaf1448381278ecc39a1d1045af2cb452da5a00519d265bc1a5997523de22d5021acb4dbe1648502fe61512d3c6 languageName: node linkType: hard -"@typescript-eslint/type-utils@npm:5.11.0": - version: 5.11.0 - resolution: "@typescript-eslint/type-utils@npm:5.11.0" +"@typescript-eslint/type-utils@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/type-utils@npm:5.61.0" dependencies: - "@typescript-eslint/utils": 5.11.0 - debug: ^4.3.2 + "@typescript-eslint/typescript-estree": 5.61.0 + "@typescript-eslint/utils": 5.61.0 + debug: ^4.3.4 tsutils: ^3.21.0 peerDependencies: eslint: "*" peerDependenciesMeta: typescript: optional: true - checksum: fd570806d82874289ded6bfd90ff5414d4365b95b4a2e911f7ff2fee6e2c7675d0f2f71580c24cb8be733c3dfe2cd33eedff99ae2aa50f61b1b5af76499074eb + checksum: f0203fd48c6218f004dd73a9a71ba4cf97f015d0f13a7b3c821a3ba7ec814839bae270a1db589184ca7091fe54815a3171d1993e8a25200bf33e131bd6e855d4 languageName: node linkType: hard -"@typescript-eslint/types@npm:5.11.0": - version: 5.11.0 - resolution: "@typescript-eslint/types@npm:5.11.0" - checksum: b1531481da75a6c89510ad03f3db68e4797b25438bb902ee322bd1c154b83396016271cc00356dcdbc300a8ee421493aae803b8c716f36d7b4808fe045ae3a2a +"@typescript-eslint/types@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/types@npm:5.61.0" + checksum: d311ca2141f6bcb5f0f8f97ddbc218c9911e0735aaa30f0f2e64d518fb33568410754e1b04bf157175f8783504f8ec62a7ab53a66a18507f43edb1e21fe69e90 languageName: node linkType: hard -"@typescript-eslint/typescript-estree@npm:5.11.0": - version: 5.11.0 - resolution: "@typescript-eslint/typescript-estree@npm:5.11.0" +"@typescript-eslint/typescript-estree@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/typescript-estree@npm:5.61.0" dependencies: - "@typescript-eslint/types": 5.11.0 - "@typescript-eslint/visitor-keys": 5.11.0 - debug: ^4.3.2 - globby: ^11.0.4 + "@typescript-eslint/types": 5.61.0 + "@typescript-eslint/visitor-keys": 5.61.0 + debug: ^4.3.4 + globby: ^11.1.0 is-glob: ^4.0.3 - semver: ^7.3.5 + semver: ^7.3.7 tsutils: ^3.21.0 peerDependenciesMeta: typescript: optional: true - checksum: 7bda55501c586efd7f8065b4158016486d8af92b8419931fbea7cec9bfe074075de8cdebec8baa1ac8a5c3f973599b9dd44a51fced1792176e49cd60cc8e5442 + checksum: efe25a1b2774939c02cb9b388cf72efa672811f1c39a87ddd617937f63c2320551ce459ba69c6d022e33322594d40b9f2d2c6bc9937387718adc40dc5e57ea8e languageName: node linkType: hard -"@typescript-eslint/utils@npm:5.11.0": - version: 5.11.0 - resolution: "@typescript-eslint/utils@npm:5.11.0" +"@typescript-eslint/utils@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/utils@npm:5.61.0" dependencies: + "@eslint-community/eslint-utils": ^4.2.0 "@types/json-schema": ^7.0.9 - "@typescript-eslint/scope-manager": 5.11.0 - "@typescript-eslint/types": 5.11.0 - "@typescript-eslint/typescript-estree": 5.11.0 + "@types/semver": ^7.3.12 + "@typescript-eslint/scope-manager": 5.61.0 + "@typescript-eslint/types": 5.61.0 + "@typescript-eslint/typescript-estree": 5.61.0 eslint-scope: ^5.1.1 - eslint-utils: ^3.0.0 + semver: ^7.3.7 peerDependencies: eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 - checksum: 5ab1a15db1e0a2fbb857a8a16325459ad3d5239066f2641aa93ad9f7d08252d3a4ca6ae356c51cba1c6c81a65d84883436566b01932fa55b64a69796b950900d + checksum: 24efc1964e6c92db96fe0d9a390550e4f27e8f353e51a9b46bda03e6692ea5d40f398d539235a4ff0894e9e45dfcfb51df953ade2ae9d17a1421449625ce6f5a languageName: node linkType: hard -"@typescript-eslint/visitor-keys@npm:5.11.0": - version: 5.11.0 - resolution: "@typescript-eslint/visitor-keys@npm:5.11.0" +"@typescript-eslint/visitor-keys@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/visitor-keys@npm:5.61.0" dependencies: - "@typescript-eslint/types": 5.11.0 - eslint-visitor-keys: ^3.0.0 - checksum: 8f0b6fe1e86bc93825a137be3220f57e3a4bee410cca5d35963a0cd416750b31291a73c4294676d94ed0f5066b4cfb3a8f512d409881daa550d1645f4381eb21 + "@typescript-eslint/types": 5.61.0 + eslint-visitor-keys: ^3.3.0 + checksum: a8d589f61ddfc380787218da4d347e8f9aef0f82f4a93f1daee46786bda889a90961c7ec1b470db5e3261438a728fdfd956f5bda6ee2de22c4be2d2152d6e270 languageName: node linkType: hard @@ -650,7 +703,7 @@ __metadata: languageName: node linkType: hard -"acorn-jsx@npm:^5.3.1": +"acorn-jsx@npm:^5.3.2": version: 5.3.2 resolution: "acorn-jsx@npm:5.3.2" peerDependencies: @@ -666,7 +719,7 @@ __metadata: languageName: node linkType: hard -"acorn@npm:^8.4.1, acorn@npm:^8.7.0": +"acorn@npm:^8.4.1": version: 8.7.0 resolution: "acorn@npm:8.7.0" bin: @@ -675,6 +728,15 @@ __metadata: languageName: node linkType: hard +"acorn@npm:^8.9.0": + version: 8.10.0 + resolution: "acorn@npm:8.10.0" + bin: + acorn: bin/acorn + checksum: 538ba38af0cc9e5ef983aee196c4b8b4d87c0c94532334fa7e065b2c8a1f85863467bb774231aae91613fcda5e68740c15d97b1967ae3394d20faddddd8af61d + languageName: node + linkType: hard + "agent-base@npm:6, agent-base@npm:^6.0.2": version: 6.0.2 resolution: "agent-base@npm:6.0.2" @@ -1136,6 +1198,18 @@ __metadata: languageName: node linkType: hard +"debug@npm:^4.3.4": + version: 4.3.4 + resolution: "debug@npm:4.3.4" + dependencies: + ms: 2.1.2 + peerDependenciesMeta: + supports-color: + optional: true + checksum: 3dbad3f94ea64f34431a9cbf0bafb61853eda57bff2880036153438f50fb5a84f27683ba0d8e5426bf41a8c6ff03879488120cf5b3a761e77953169c0600a708 + languageName: node + linkType: hard + "decamelize@npm:^1.2.0": version: 1.2.0 resolution: "decamelize@npm:1.2.0" @@ -1284,14 +1358,14 @@ __metadata: languageName: node linkType: hard -"eslint-config-prettier@npm:^8.3.0": - version: 8.3.0 - resolution: "eslint-config-prettier@npm:8.3.0" +"eslint-config-prettier@npm:^8.8.0": + version: 8.8.0 + resolution: "eslint-config-prettier@npm:8.8.0" peerDependencies: eslint: ">=7.0.0" bin: eslint-config-prettier: bin/cli.js - checksum: df4cea3032671995bb5ab07e016169072f7fa59f44a53251664d9ca60951b66cdc872683b5c6a3729c91497c11490ca44a79654b395dd6756beb0c3903a37196 + checksum: 1e94c3882c4d5e41e1dcfa2c368dbccbfe3134f6ac7d40101644d3bfbe3eb2f2ffac757f3145910b5eacf20c0e85e02b91293d3126d770cbf3dc390b3564681c languageName: node linkType: hard @@ -1312,94 +1386,80 @@ __metadata: languageName: node linkType: hard -"eslint-scope@npm:^7.1.0": - version: 7.1.0 - resolution: "eslint-scope@npm:7.1.0" +"eslint-scope@npm:^7.2.0": + version: 7.2.0 + resolution: "eslint-scope@npm:7.2.0" dependencies: esrecurse: ^4.3.0 estraverse: ^5.2.0 - checksum: 2070470a0725438ed47075b2574a4c03cf59aa32648da8cff9e3548c84f6b0079cfdb9ee1dd7ab0bfe97011f64b2af5bfd4b69cf14a1292130dec661eec7914a - languageName: node - linkType: hard - -"eslint-utils@npm:^3.0.0": - version: 3.0.0 - resolution: "eslint-utils@npm:3.0.0" - dependencies: - eslint-visitor-keys: ^2.0.0 - peerDependencies: - eslint: ">=5" - checksum: 0668fe02f5adab2e5a367eee5089f4c39033af20499df88fe4e6aba2015c20720404d8c3d6349b6f716b08fdf91b9da4e5d5481f265049278099c4c836ccb619 - languageName: node - linkType: hard - -"eslint-visitor-keys@npm:^2.0.0": - version: 2.1.0 - resolution: "eslint-visitor-keys@npm:2.1.0" - checksum: e3081d7dd2611a35f0388bbdc2f5da60b3a3c5b8b6e928daffff7391146b434d691577aa95064c8b7faad0b8a680266bcda0a42439c18c717b80e6718d7e267d + checksum: 64591a2d8b244ade9c690b59ef238a11d5c721a98bcee9e9f445454f442d03d3e04eda88e95a4daec558220a99fa384309d9faae3d459bd40e7a81b4063980ae languageName: node linkType: hard -"eslint-visitor-keys@npm:^3.0.0, eslint-visitor-keys@npm:^3.1.0, eslint-visitor-keys@npm:^3.2.0": - version: 3.2.0 - resolution: "eslint-visitor-keys@npm:3.2.0" - checksum: fdadbb26f9e6417d3db7ad4f00bb0d573b6031c32fa72e8cdae32d038223faaeddff2ee443c90cb489bf774e75bff765c00912b8f9106d65e4f202ccd78c1b18 +"eslint-visitor-keys@npm:^3.3.0, eslint-visitor-keys@npm:^3.4.1": + version: 3.4.1 + resolution: "eslint-visitor-keys@npm:3.4.1" + checksum: f05121d868202736b97de7d750847a328fcfa8593b031c95ea89425333db59676ac087fa905eba438d0a3c5769632f828187e0c1a0d271832a2153c1d3661c2c languageName: node linkType: hard -"eslint@npm:^8.2.0": - version: 8.8.0 - resolution: "eslint@npm:8.8.0" +"eslint@npm:^8.44.0": + version: 8.44.0 + resolution: "eslint@npm:8.44.0" dependencies: - "@eslint/eslintrc": ^1.0.5 - "@humanwhocodes/config-array": ^0.9.2 + "@eslint-community/eslint-utils": ^4.2.0 + "@eslint-community/regexpp": ^4.4.0 + "@eslint/eslintrc": ^2.1.0 + "@eslint/js": 8.44.0 + "@humanwhocodes/config-array": ^0.11.10 + "@humanwhocodes/module-importer": ^1.0.1 + "@nodelib/fs.walk": ^1.2.8 ajv: ^6.10.0 chalk: ^4.0.0 cross-spawn: ^7.0.2 debug: ^4.3.2 doctrine: ^3.0.0 escape-string-regexp: ^4.0.0 - eslint-scope: ^7.1.0 - eslint-utils: ^3.0.0 - eslint-visitor-keys: ^3.2.0 - espree: ^9.3.0 - esquery: ^1.4.0 + eslint-scope: ^7.2.0 + eslint-visitor-keys: ^3.4.1 + espree: ^9.6.0 + esquery: ^1.4.2 esutils: ^2.0.2 fast-deep-equal: ^3.1.3 file-entry-cache: ^6.0.1 - functional-red-black-tree: ^1.0.1 - glob-parent: ^6.0.1 - globals: ^13.6.0 + find-up: ^5.0.0 + glob-parent: ^6.0.2 + globals: ^13.19.0 + graphemer: ^1.4.0 ignore: ^5.2.0 import-fresh: ^3.0.0 imurmurhash: ^0.1.4 is-glob: ^4.0.0 + is-path-inside: ^3.0.3 js-yaml: ^4.1.0 json-stable-stringify-without-jsonify: ^1.0.1 levn: ^0.4.1 lodash.merge: ^4.6.2 - minimatch: ^3.0.4 + minimatch: ^3.1.2 natural-compare: ^1.4.0 - optionator: ^0.9.1 - regexpp: ^3.2.0 + optionator: ^0.9.3 strip-ansi: ^6.0.1 strip-json-comments: ^3.1.0 text-table: ^0.2.0 - v8-compile-cache: ^2.0.3 bin: eslint: bin/eslint.js - checksum: 41a7e85bf84cf9f2d758ef3e8d08020a39a2836703728b59535684681349bd021c2c6e24174462b844a914870d707d2151e0371198899d957b444de91adaa435 + checksum: d06309ce4aafb9d27d558c8e5e5aa5cba3bbec3ce8ceccbc7d4b7a35f2b67fd40189159155553270e2e6febeb69bd8a3b60d6241c8f5ddc2ef1702ccbd328501 languageName: node linkType: hard -"espree@npm:^9.2.0, espree@npm:^9.3.0": - version: 9.3.0 - resolution: "espree@npm:9.3.0" +"espree@npm:^9.6.0": + version: 9.6.0 + resolution: "espree@npm:9.6.0" dependencies: - acorn: ^8.7.0 - acorn-jsx: ^5.3.1 - eslint-visitor-keys: ^3.1.0 - checksum: c0f1885c4eab652f9be08eb9228cea0df046b559b29d4aed8d6590ea9bd60177d4cb245d204a6f737a79a096861bb4ab8e480aeb8c1dbafef5beec1157353ce4 + acorn: ^8.9.0 + acorn-jsx: ^5.3.2 + eslint-visitor-keys: ^3.4.1 + checksum: 1287979510efb052a6a97c73067ea5d0a40701b29adde87bbe2d3eb1667e39ca55e8129e20e2517fed3da570150e7ef470585228459a8f3e3755f45007a1c662 languageName: node linkType: hard @@ -1413,12 +1473,12 @@ __metadata: languageName: node linkType: hard -"esquery@npm:^1.4.0": - version: 1.4.0 - resolution: "esquery@npm:1.4.0" +"esquery@npm:^1.4.2": + version: 1.5.0 + resolution: "esquery@npm:1.5.0" dependencies: estraverse: ^5.1.0 - checksum: a0807e17abd7fbe5fbd4fab673038d6d8a50675cdae6b04fbaa520c34581be0c5fa24582990e8acd8854f671dd291c78bb2efb9e0ed5b62f33bac4f9cf820210 + checksum: aefb0d2596c230118656cd4ec7532d447333a410a48834d80ea648b1e7b5c9bc9ed8b5e33a89cb04e487b60d622f44cf5713bf4abed7c97343edefdc84a35900 languageName: node linkType: hard @@ -1524,7 +1584,7 @@ __metadata: languageName: node linkType: hard -"find-up@npm:5.0.0": +"find-up@npm:5.0.0, find-up@npm:^5.0.0": version: 5.0.0 resolution: "find-up@npm:5.0.0" dependencies: @@ -1632,13 +1692,6 @@ __metadata: languageName: node linkType: hard -"functional-red-black-tree@npm:^1.0.1": - version: 1.0.1 - resolution: "functional-red-black-tree@npm:1.0.1" - checksum: ca6c170f37640e2d94297da8bb4bf27a1d12bea3e00e6a3e007fd7aa32e37e000f5772acf941b4e4f3cf1c95c3752033d0c509af157ad8f526e7f00723b9eb9f - languageName: node - linkType: hard - "gauge@npm:^4.0.0": version: 4.0.0 resolution: "gauge@npm:4.0.0" @@ -1686,7 +1739,7 @@ __metadata: languageName: node linkType: hard -"glob-parent@npm:^6.0.1": +"glob-parent@npm:^6.0.2": version: 6.0.2 resolution: "glob-parent@npm:6.0.2" dependencies: @@ -1716,16 +1769,16 @@ __metadata: languageName: node linkType: hard -"globals@npm:^13.6.0, globals@npm:^13.9.0": - version: 13.12.1 - resolution: "globals@npm:13.12.1" +"globals@npm:^13.19.0": + version: 13.20.0 + resolution: "globals@npm:13.20.0" dependencies: type-fest: ^0.20.2 - checksum: cf7877629c8f2a293b0a7d09d1dcce7f2d426ec2528600c481c5b3f3d070b0a120eb2499439ac0404990fb8a5742c0165b1bf1f52603364001ddc89bea3dda24 + checksum: ad1ecf914bd051325faad281d02ea2c0b1df5d01bd94d368dcc5513340eac41d14b3c61af325768e3c7f8d44576e72780ec0b6f2d366121f8eec6e03c3a3b97a languageName: node linkType: hard -"globby@npm:^11.0.4": +"globby@npm:^11.1.0": version: 11.1.0 resolution: "globby@npm:11.1.0" dependencies: @@ -1746,6 +1799,13 @@ __metadata: languageName: node linkType: hard +"graphemer@npm:^1.4.0": + version: 1.4.0 + resolution: "graphemer@npm:1.4.0" + checksum: bab8f0be9b568857c7bec9fda95a89f87b783546d02951c40c33f84d05bb7da3fd10f863a9beb901463669b6583173a8c8cc6d6b306ea2b9b9d5d3d943c3a673 + languageName: node + linkType: hard + "growl@npm:1.10.5": version: 1.10.5 resolution: "growl@npm:1.10.5" @@ -1853,14 +1913,7 @@ __metadata: languageName: node linkType: hard -"ignore@npm:^4.0.6": - version: 4.0.6 - resolution: "ignore@npm:4.0.6" - checksum: 248f82e50a430906f9ee7f35e1158e3ec4c3971451dd9f99c9bc1548261b4db2b99709f60ac6c6cac9333494384176cc4cc9b07acbe42d52ac6a09cad734d800 - languageName: node - linkType: hard - -"ignore@npm:^5.1.8, ignore@npm:^5.2.0": +"ignore@npm:^5.2.0": version: 5.2.0 resolution: "ignore@npm:5.2.0" checksum: 6b1f926792d614f64c6c83da3a1f9c83f6196c2839aa41e1e32dd7b8d174cef2e329d75caabb62cb61ce9dc432f75e67d07d122a037312db7caa73166a1bdb77 @@ -1920,27 +1973,27 @@ __metadata: resolution: "intercom-client@workspace:." dependencies: "@istanbuljs/nyc-config-typescript": ^1.0.2 - "@types/lodash": ^4.14.176 - "@types/mocha": ^9.1.0 - "@types/node": ^16.11.6 - "@types/sinon": ^10.0.6 - "@typescript-eslint/eslint-plugin": ^5.7.0 - "@typescript-eslint/parser": ^5.7.0 + "@types/lodash": ^4.14.195 + "@types/mocha": ^9.1.1 + "@types/node": ^16.18.38 + "@types/sinon": ^10.0.15 + "@typescript-eslint/eslint-plugin": ^5.61.0 + "@typescript-eslint/parser": ^5.61.0 axios: ^0.24.0 - eslint: ^8.2.0 - eslint-config-prettier: ^8.3.0 + eslint: ^8.44.0 + eslint-config-prettier: ^8.8.0 eslint-plugin-no-only-tests: ^2.6.0 htmlencode: ^0.0.4 lodash: ^4.17.21 merge2: ^1.4.1 - mocha: ^9.2.0 - nock: ^13.0.11 + mocha: ^9.2.2 + nock: ^13.3.1 nyc: ^15.1.0 - prettier: ^2.5.1 - sinon: ^7.3.2 - ts-node: ^10.4.0 - tslib: ^2.3.1 - typescript: ^4.5.3 + prettier: ^2.8.8 + sinon: ^7.5.0 + ts-node: ^10.9.1 + tslib: ^2.6.0 + typescript: ^4.9.5 languageName: unknown linkType: soft @@ -1997,6 +2050,13 @@ __metadata: languageName: node linkType: hard +"is-path-inside@npm:^3.0.3": + version: 3.0.3 + resolution: "is-path-inside@npm:3.0.3" + checksum: abd50f06186a052b349c15e55b182326f1936c89a78bf6c8f2b707412517c097ce04bc49a0ca221787bc44e1049f51f09a2ffb63d22899051988d3a618ba13e9 + languageName: node + linkType: hard + "is-plain-obj@npm:^2.1.0": version: 2.1.0 resolution: "is-plain-obj@npm:2.1.0" @@ -2239,13 +2299,6 @@ __metadata: languageName: node linkType: hard -"lodash.set@npm:^4.3.2": - version: 4.3.2 - resolution: "lodash.set@npm:4.3.2" - checksum: a9122f49eef9f2d0fc9061a33d87f8e5b8c6b23d46e8b9e9ce1529d3588d79741bd1145a3abdfa3b13082703e65af27ff18d8a07bfc22b9be32f3fc36f763f70 - languageName: node - linkType: hard - "lodash@npm:^4.17.15, lodash@npm:^4.17.21": version: 4.17.21 resolution: "lodash@npm:4.17.21" @@ -2345,12 +2398,12 @@ __metadata: languageName: node linkType: hard -"minimatch@npm:3.0.4": - version: 3.0.4 - resolution: "minimatch@npm:3.0.4" +"minimatch@npm:4.2.1": + version: 4.2.1 + resolution: "minimatch@npm:4.2.1" dependencies: brace-expansion: ^1.1.7 - checksum: 66ac295f8a7b59788000ea3749938b0970344c841750abd96694f80269b926ebcafad3deeb3f1da2522978b119e6ae3a5869b63b13a7859a456b3408bd18a078 + checksum: 2b1514e3d0f29a549912f0db7ae7b82c5cab4a8f2dd0369f1c6451a325b3f12b2cf473c95873b6157bb8df183d6cf6db82ff03614b6adaaf1d7e055beccdfd01 languageName: node linkType: hard @@ -2363,6 +2416,15 @@ __metadata: languageName: node linkType: hard +"minimatch@npm:^3.0.5, minimatch@npm:^3.1.2": + version: 3.1.2 + resolution: "minimatch@npm:3.1.2" + dependencies: + brace-expansion: ^1.1.7 + checksum: c154e566406683e7bcb746e000b84d74465b3a832c45d59912b9b55cd50dee66e5c4b1e5566dba26154040e51672f9aa450a9aef0c97cfc7336b78b7afb9540a + languageName: node + linkType: hard + "minipass-collect@npm:^1.0.2": version: 1.0.2 resolution: "minipass-collect@npm:1.0.2" @@ -2442,9 +2504,9 @@ __metadata: languageName: node linkType: hard -"mocha@npm:^9.2.0": - version: 9.2.0 - resolution: "mocha@npm:9.2.0" +"mocha@npm:^9.2.2": + version: 9.2.2 + resolution: "mocha@npm:9.2.2" dependencies: "@ungap/promise-all-settled": 1.1.2 ansi-colors: 4.1.1 @@ -2459,9 +2521,9 @@ __metadata: he: 1.2.0 js-yaml: 4.1.0 log-symbols: 4.1.0 - minimatch: 3.0.4 + minimatch: 4.2.1 ms: 2.1.3 - nanoid: 3.2.0 + nanoid: 3.3.1 serialize-javascript: 6.0.0 strip-json-comments: 3.1.1 supports-color: 8.1.1 @@ -2473,7 +2535,7 @@ __metadata: bin: _mocha: bin/_mocha mocha: bin/mocha - checksum: 49efc4724cf17087c7e107bc8f6890db24525e6dcc153b801da58de3c2a2f940e22f7600ef195b8ac62a0dfd7baee5cf289fc4641a6b1fdf8bc9c819efc1a8ba + checksum: 4d5ca4ce33fc66627e63acdf09a634e2358c9a00f61de7788b1091b6aad430da04f97f9ecb82d56dc034b623cb833b65576136fd010d77679c03fcea5bc1e12d languageName: node linkType: hard @@ -2491,12 +2553,19 @@ __metadata: languageName: node linkType: hard -"nanoid@npm:3.2.0": - version: 3.2.0 - resolution: "nanoid@npm:3.2.0" +"nanoid@npm:3.3.1": + version: 3.3.1 + resolution: "nanoid@npm:3.3.1" bin: nanoid: bin/nanoid.cjs - checksum: 3d1d5a69fea84e538057cf64106e713931c4ef32af344068ecff153ff91252f39b0f2b472e09b0dfff43ac3cf520c92938d90e6455121fe93976e23660f4fccc + checksum: 4ef0969e1bbe866fc223eb32276cbccb0961900bfe79104fa5abe34361979dead8d0e061410a5c03bc3d47455685adf32c09d6f27790f4a6898fb51f7df7ec86 + languageName: node + linkType: hard + +"natural-compare-lite@npm:^1.4.0": + version: 1.4.0 + resolution: "natural-compare-lite@npm:1.4.0" + checksum: 5222ac3986a2b78dd6069ac62cbb52a7bf8ffc90d972ab76dfe7b01892485d229530ed20d0c62e79a6b363a663b273db3bde195a1358ce9e5f779d4453887225 languageName: node linkType: hard @@ -2527,15 +2596,15 @@ __metadata: languageName: node linkType: hard -"nock@npm:^13.0.11": - version: 13.2.4 - resolution: "nock@npm:13.2.4" +"nock@npm:^13.3.1": + version: 13.3.1 + resolution: "nock@npm:13.3.1" dependencies: debug: ^4.1.0 json-stringify-safe: ^5.0.1 - lodash.set: ^4.3.2 + lodash: ^4.17.21 propagate: ^2.0.0 - checksum: 2750a82ea22eebd8203eb1d7669ae09c3daae1fd573026372bad2515adad48d723a804f647bd45d7a499eb3a9a632560da406bde05bca9df762d3027db9099b5 + checksum: 0f2a73e8432f6b5650656c53eef99f9e5bbde3df538dc2f07057edc4438cfc61a394c9d06dd82e60f6e86d42433f20f3c04364a1f088beee7bf03a24e3f0fdd0 languageName: node linkType: hard @@ -2651,17 +2720,17 @@ __metadata: languageName: node linkType: hard -"optionator@npm:^0.9.1": - version: 0.9.1 - resolution: "optionator@npm:0.9.1" +"optionator@npm:^0.9.3": + version: 0.9.3 + resolution: "optionator@npm:0.9.3" dependencies: + "@aashutoshrathi/word-wrap": ^1.2.3 deep-is: ^0.1.3 fast-levenshtein: ^2.0.6 levn: ^0.4.1 prelude-ls: ^1.2.1 type-check: ^0.4.0 - word-wrap: ^1.2.3 - checksum: dbc6fa065604b24ea57d734261914e697bd73b69eff7f18e967e8912aa2a40a19a9f599a507fa805be6c13c24c4eae8c71306c239d517d42d4c041c942f508a0 + checksum: 09281999441f2fe9c33a5eeab76700795365a061563d66b098923eb719251a42bdbe432790d35064d0816ead9296dbeb1ad51a733edf4167c96bd5d0882e428a languageName: node linkType: hard @@ -2814,12 +2883,12 @@ __metadata: languageName: node linkType: hard -"prettier@npm:^2.5.1": - version: 2.5.1 - resolution: "prettier@npm:2.5.1" +"prettier@npm:^2.8.8": + version: 2.8.8 + resolution: "prettier@npm:2.8.8" bin: prettier: bin-prettier.js - checksum: 21b9408476ea1c544b0e45d51ceb94a84789ff92095abb710942d780c862d0daebdb29972d47f6b4d0f7ebbfb0ffbf56cc2cfa3e3e9d1cca54864af185b15b66 + checksum: b49e409431bf129dd89238d64299ba80717b57ff5a6d1c1a8b1a28b590d998a34e083fa13573bc732bb8d2305becb4c9a4407f8486c81fa7d55100eb08263cf8 languageName: node linkType: hard @@ -2899,13 +2968,6 @@ __metadata: languageName: node linkType: hard -"regexpp@npm:^3.2.0": - version: 3.2.0 - resolution: "regexpp@npm:3.2.0" - checksum: a78dc5c7158ad9ddcfe01aa9144f46e192ddbfa7b263895a70a5c6c73edd9ce85faf7c0430e59ac38839e1734e275b9c3de5c57ee3ab6edc0e0b1bdebefccef8 - languageName: node - linkType: hard - "release-zalgo@npm:^1.0.0": version: 1.0.0 resolution: "release-zalgo@npm:1.0.0" @@ -3018,6 +3080,17 @@ __metadata: languageName: node linkType: hard +"semver@npm:^7.3.7": + version: 7.5.4 + resolution: "semver@npm:7.5.4" + dependencies: + lru-cache: ^6.0.0 + bin: + semver: bin/semver.js + checksum: 12d8ad952fa353b0995bf180cdac205a4068b759a140e5d3c608317098b3575ac2f1e09182206bf2eb26120e1c0ed8fb92c48c592f6099680de56bb071423ca3 + languageName: node + linkType: hard + "serialize-javascript@npm:6.0.0": version: 6.0.0 resolution: "serialize-javascript@npm:6.0.0" @@ -3057,7 +3130,7 @@ __metadata: languageName: node linkType: hard -"sinon@npm:^7.3.2": +"sinon@npm:^7.5.0": version: 7.5.0 resolution: "sinon@npm:7.5.0" dependencies: @@ -3269,11 +3342,11 @@ __metadata: languageName: node linkType: hard -"ts-node@npm:^10.4.0": - version: 10.5.0 - resolution: "ts-node@npm:10.5.0" +"ts-node@npm:^10.9.1": + version: 10.9.1 + resolution: "ts-node@npm:10.9.1" dependencies: - "@cspotcode/source-map-support": 0.7.0 + "@cspotcode/source-map-support": ^0.8.0 "@tsconfig/node10": ^1.0.7 "@tsconfig/node12": ^1.0.7 "@tsconfig/node14": ^1.0.0 @@ -3284,7 +3357,7 @@ __metadata: create-require: ^1.1.0 diff: ^4.0.1 make-error: ^1.1.1 - v8-compile-cache-lib: ^3.0.0 + v8-compile-cache-lib: ^3.0.1 yn: 3.1.1 peerDependencies: "@swc/core": ">=1.2.50" @@ -3299,10 +3372,11 @@ __metadata: bin: ts-node: dist/bin.js ts-node-cwd: dist/bin-cwd.js + ts-node-esm: dist/bin-esm.js ts-node-script: dist/bin-script.js ts-node-transpile-only: dist/bin-transpile.js ts-script: dist/bin-script-deprecated.js - checksum: d51ac8a9b3582ce3705cef8d35f3372e40caa277dbd7c7baeb651961538f13d2f11f22402614348f78d9b10501bd1cb5f05ec4f2ec9a74bd0e288de769c32335 + checksum: 090adff1302ab20bd3486e6b4799e90f97726ed39e02b39e566f8ab674fd5bd5f727f43615debbfc580d33c6d9d1c6b1b3ce7d8e3cca3e20530a145ffa232c35 languageName: node linkType: hard @@ -3313,10 +3387,10 @@ __metadata: languageName: node linkType: hard -"tslib@npm:^2.3.1": - version: 2.3.1 - resolution: "tslib@npm:2.3.1" - checksum: de17a98d4614481f7fcb5cd53ffc1aaf8654313be0291e1bfaee4b4bb31a20494b7d218ff2e15017883e8ea9626599b3b0e0229c18383ba9dce89da2adf15cb9 +"tslib@npm:^2.6.0": + version: 2.6.0 + resolution: "tslib@npm:2.6.0" + checksum: c01066038f950016a18106ddeca4649b4d76caa76ec5a31e2a26e10586a59fceb4ee45e96719bf6c715648e7c14085a81fee5c62f7e9ebee68e77a5396e5538f languageName: node linkType: hard @@ -3370,23 +3444,23 @@ __metadata: languageName: node linkType: hard -"typescript@npm:^4.5.3": - version: 4.5.5 - resolution: "typescript@npm:4.5.5" +"typescript@npm:^4.9.5": + version: 4.9.5 + resolution: "typescript@npm:4.9.5" bin: tsc: bin/tsc tsserver: bin/tsserver - checksum: 506f4c919dc8aeaafa92068c997f1d213b9df4d9756d0fae1a1e7ab66b585ab3498050e236113a1c9e57ee08c21ec6814ca7a7f61378c058d79af50a4b1f5a5e + checksum: ee000bc26848147ad423b581bd250075662a354d84f0e06eb76d3b892328d8d4440b7487b5a83e851b12b255f55d71835b008a66cbf8f255a11e4400159237db languageName: node linkType: hard -"typescript@patch:typescript@^4.5.3#~builtin": - version: 4.5.5 - resolution: "typescript@patch:typescript@npm%3A4.5.5#~builtin::version=4.5.5&hash=493e53" +"typescript@patch:typescript@^4.9.5#~builtin": + version: 4.9.5 + resolution: "typescript@patch:typescript@npm%3A4.9.5#~builtin::version=4.9.5&hash=493e53" bin: tsc: bin/tsc tsserver: bin/tsserver - checksum: c05c318d79c690f101d7ffb34cd6c7d6bbd884d3af9cefe7749ad0cd6be43c7082f098280982ca945dcba23fde34a08fed9602bb26540936baf8c0520727d3ba + checksum: 2eee5c37cad4390385db5db5a8e81470e42e8f1401b0358d7390095d6f681b410f2c4a0c496c6ff9ebd775423c7785cdace7bcdad76c7bee283df3d9718c0f20 languageName: node linkType: hard @@ -3433,17 +3507,10 @@ __metadata: languageName: node linkType: hard -"v8-compile-cache-lib@npm:^3.0.0": - version: 3.0.0 - resolution: "v8-compile-cache-lib@npm:3.0.0" - checksum: 674e312bbca796584b61dc915f33c7e7dc4e06d196e0048cb772c8964493a1ec723f1dd014d9419fd55c24a6eae148f60769da23f622e05cd13268063fa1ed6b - languageName: node - linkType: hard - -"v8-compile-cache@npm:^2.0.3": - version: 2.3.0 - resolution: "v8-compile-cache@npm:2.3.0" - checksum: adb0a271eaa2297f2f4c536acbfee872d0dd26ec2d76f66921aa7fc437319132773483344207bdbeee169225f4739016d8d2dbf0553913a52bb34da6d0334f8e +"v8-compile-cache-lib@npm:^3.0.1": + version: 3.0.1 + resolution: "v8-compile-cache-lib@npm:3.0.1" + checksum: 78089ad549e21bcdbfca10c08850022b22024cdcc2da9b168bcf5a73a6ed7bf01a9cebb9eac28e03cd23a684d81e0502797e88f3ccd27a32aeab1cfc44c39da0 languageName: node linkType: hard @@ -3474,13 +3541,6 @@ __metadata: languageName: node linkType: hard -"word-wrap@npm:^1.2.3": - version: 1.2.3 - resolution: "word-wrap@npm:1.2.3" - checksum: 30b48f91fcf12106ed3186ae4fa86a6a1842416df425be7b60485de14bec665a54a68e4b5156647dec3a70f25e84d270ca8bc8cd23182ed095f5c7206a938c1f - languageName: node - linkType: hard - "workerpool@npm:6.2.0": version: 6.2.0 resolution: "workerpool@npm:6.2.0" From 7652a9db435cc0b6af7e39b7c5a4d43d8bfdf138 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Mon, 10 Jul 2023 14:25:51 +0100 Subject: [PATCH 110/146] yarn lock --- yarn.lock | 3890 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 3890 insertions(+) create mode 100644 yarn.lock diff --git a/yarn.lock b/yarn.lock new file mode 100644 index 00000000..e280b7c0 --- /dev/null +++ b/yarn.lock @@ -0,0 +1,3890 @@ +# This file is generated by running "yarn install" inside your project. +# Manual changes might be lost - proceed with caution! + +__metadata: + version: 5 + cacheKey: 8 + +"@aashutoshrathi/word-wrap@npm:^1.2.3": + version: 1.2.6 + resolution: "@aashutoshrathi/word-wrap@npm:1.2.6" + checksum: ada901b9e7c680d190f1d012c84217ce0063d8f5c5a7725bb91ec3c5ed99bb7572680eb2d2938a531ccbaec39a95422fcd8a6b4a13110c7d98dd75402f66a0cd + languageName: node + linkType: hard + +"@ampproject/remapping@npm:^2.2.0": + version: 2.2.1 + resolution: "@ampproject/remapping@npm:2.2.1" + dependencies: + "@jridgewell/gen-mapping": ^0.3.0 + "@jridgewell/trace-mapping": ^0.3.9 + checksum: 03c04fd526acc64a1f4df22651186f3e5ef0a9d6d6530ce4482ec9841269cf7a11dbb8af79237c282d721c5312024ff17529cd72cc4768c11e999b58e2302079 + languageName: node + linkType: hard + +"@babel/code-frame@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/code-frame@npm:7.22.5" + dependencies: + "@babel/highlight": ^7.22.5 + checksum: cfe804f518f53faaf9a1d3e0f9f74127ab9a004912c3a16fda07fb6a633393ecb9918a053cb71804204c1b7ec3d49e1699604715e2cfb0c9f7bc4933d324ebb6 + languageName: node + linkType: hard + +"@babel/compat-data@npm:^7.22.6": + version: 7.22.6 + resolution: "@babel/compat-data@npm:7.22.6" + checksum: b88631143a2ebdb75e5bac47984e950983294f1739c2133f32569c6f2fcee85f83634bb6cf4378afb44fa8eb7877d11e48811d1e6a52afa161f82276ffdc3fb4 + languageName: node + linkType: hard + +"@babel/core@npm:^7.7.5": + version: 7.22.8 + resolution: "@babel/core@npm:7.22.8" + dependencies: + "@ampproject/remapping": ^2.2.0 + "@babel/code-frame": ^7.22.5 + "@babel/generator": ^7.22.7 + "@babel/helper-compilation-targets": ^7.22.6 + "@babel/helper-module-transforms": ^7.22.5 + "@babel/helpers": ^7.22.6 + "@babel/parser": ^7.22.7 + "@babel/template": ^7.22.5 + "@babel/traverse": ^7.22.8 + "@babel/types": ^7.22.5 + "@nicolo-ribaudo/semver-v6": ^6.3.3 + convert-source-map: ^1.7.0 + debug: ^4.1.0 + gensync: ^1.0.0-beta.2 + json5: ^2.2.2 + checksum: 75ed701c14ad17070382ae1dd166f7534b31f2c71e00995a5f261ee2398ee96335b0736573b8ff24ab6e3e6f5814ee2a48fa11ab90fabcd3dfc70ea87c5f30a6 + languageName: node + linkType: hard + +"@babel/generator@npm:^7.22.7": + version: 7.22.7 + resolution: "@babel/generator@npm:7.22.7" + dependencies: + "@babel/types": ^7.22.5 + "@jridgewell/gen-mapping": ^0.3.2 + "@jridgewell/trace-mapping": ^0.3.17 + jsesc: ^2.5.1 + checksum: cee15558888bdf5564e19cfaf95101b2910fa425f30cc1a25ac9b8621bd62b63544eb1b36ad89c80b5e41915699219f78712cab128d1f7e3da6a21fbf4143927 + languageName: node + linkType: hard + +"@babel/helper-compilation-targets@npm:^7.22.6": + version: 7.22.6 + resolution: "@babel/helper-compilation-targets@npm:7.22.6" + dependencies: + "@babel/compat-data": ^7.22.6 + "@babel/helper-validator-option": ^7.22.5 + "@nicolo-ribaudo/semver-v6": ^6.3.3 + browserslist: ^4.21.9 + lru-cache: ^5.1.1 + peerDependencies: + "@babel/core": ^7.0.0 + checksum: c7788c48099c4f0edf2adeb367a941a930d39ed7453140ceb10d7114c4091922adf56d3cdd832050fd4501f25e872886390629042ddd365d3bce2ecad69ed394 + languageName: node + linkType: hard + +"@babel/helper-environment-visitor@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-environment-visitor@npm:7.22.5" + checksum: 248532077d732a34cd0844eb7b078ff917c3a8ec81a7f133593f71a860a582f05b60f818dc5049c2212e5baa12289c27889a4b81d56ef409b4863db49646c4b1 + languageName: node + linkType: hard + +"@babel/helper-function-name@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-function-name@npm:7.22.5" + dependencies: + "@babel/template": ^7.22.5 + "@babel/types": ^7.22.5 + checksum: 6b1f6ce1b1f4e513bf2c8385a557ea0dd7fa37971b9002ad19268ca4384bbe90c09681fe4c076013f33deabc63a53b341ed91e792de741b4b35e01c00238177a + languageName: node + linkType: hard + +"@babel/helper-hoist-variables@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-hoist-variables@npm:7.22.5" + dependencies: + "@babel/types": ^7.22.5 + checksum: 394ca191b4ac908a76e7c50ab52102669efe3a1c277033e49467913c7ed6f7c64d7eacbeabf3bed39ea1f41731e22993f763b1edce0f74ff8563fd1f380d92cc + languageName: node + linkType: hard + +"@babel/helper-module-imports@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-module-imports@npm:7.22.5" + dependencies: + "@babel/types": ^7.22.5 + checksum: 9ac2b0404fa38b80bdf2653fbeaf8e8a43ccb41bd505f9741d820ed95d3c4e037c62a1bcdcb6c9527d7798d2e595924c4d025daed73283badc180ada2c9c49ad + languageName: node + linkType: hard + +"@babel/helper-module-transforms@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-module-transforms@npm:7.22.5" + dependencies: + "@babel/helper-environment-visitor": ^7.22.5 + "@babel/helper-module-imports": ^7.22.5 + "@babel/helper-simple-access": ^7.22.5 + "@babel/helper-split-export-declaration": ^7.22.5 + "@babel/helper-validator-identifier": ^7.22.5 + "@babel/template": ^7.22.5 + "@babel/traverse": ^7.22.5 + "@babel/types": ^7.22.5 + checksum: 8985dc0d971fd17c467e8b84fe0f50f3dd8610e33b6c86e5b3ca8e8859f9448bcc5c84e08a2a14285ef388351c0484797081c8f05a03770bf44fc27bf4900e68 + languageName: node + linkType: hard + +"@babel/helper-simple-access@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-simple-access@npm:7.22.5" + dependencies: + "@babel/types": ^7.22.5 + checksum: fe9686714caf7d70aedb46c3cce090f8b915b206e09225f1e4dbc416786c2fdbbee40b38b23c268b7ccef749dd2db35f255338fb4f2444429874d900dede5ad2 + languageName: node + linkType: hard + +"@babel/helper-split-export-declaration@npm:^7.22.5, @babel/helper-split-export-declaration@npm:^7.22.6": + version: 7.22.6 + resolution: "@babel/helper-split-export-declaration@npm:7.22.6" + dependencies: + "@babel/types": ^7.22.5 + checksum: e141cace583b19d9195f9c2b8e17a3ae913b7ee9b8120246d0f9ca349ca6f03cb2c001fd5ec57488c544347c0bb584afec66c936511e447fd20a360e591ac921 + languageName: node + linkType: hard + +"@babel/helper-string-parser@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-string-parser@npm:7.22.5" + checksum: 836851ca5ec813077bbb303acc992d75a360267aa3b5de7134d220411c852a6f17de7c0d0b8c8dcc0f567f67874c00f4528672b2a4f1bc978a3ada64c8c78467 + languageName: node + linkType: hard + +"@babel/helper-validator-identifier@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-validator-identifier@npm:7.22.5" + checksum: 7f0f30113474a28298c12161763b49de5018732290ca4de13cdaefd4fd0d635a6fe3f6686c37a02905fb1e64f21a5ee2b55140cf7b070e729f1bd66866506aea + languageName: node + linkType: hard + +"@babel/helper-validator-option@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/helper-validator-option@npm:7.22.5" + checksum: bbeca8a85ee86990215c0424997438b388b8d642d69b9f86c375a174d3cdeb270efafd1ff128bc7a1d370923d13b6e45829ba8581c027620e83e3a80c5c414b3 + languageName: node + linkType: hard + +"@babel/helpers@npm:^7.22.6": + version: 7.22.6 + resolution: "@babel/helpers@npm:7.22.6" + dependencies: + "@babel/template": ^7.22.5 + "@babel/traverse": ^7.22.6 + "@babel/types": ^7.22.5 + checksum: 5c1f33241fe7bf7709868c2105134a0a86dca26a0fbd508af10a89312b1f77ca38ebae43e50be3b208613c5eacca1559618af4ca236f0abc55d294800faeff30 + languageName: node + linkType: hard + +"@babel/highlight@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/highlight@npm:7.22.5" + dependencies: + "@babel/helper-validator-identifier": ^7.22.5 + chalk: ^2.0.0 + js-tokens: ^4.0.0 + checksum: f61ae6de6ee0ea8d9b5bcf2a532faec5ab0a1dc0f7c640e5047fc61630a0edb88b18d8c92eb06566d30da7a27db841aca11820ecd3ebe9ce514c9350fbed39c4 + languageName: node + linkType: hard + +"@babel/parser@npm:^7.22.5, @babel/parser@npm:^7.22.7": + version: 7.22.7 + resolution: "@babel/parser@npm:7.22.7" + bin: + parser: ./bin/babel-parser.js + checksum: 02209ddbd445831ee8bf966fdf7c29d189ed4b14343a68eb2479d940e7e3846340d7cc6bd654a5f3d87d19dc84f49f50a58cf9363bee249dc5409ff3ba3dab54 + languageName: node + linkType: hard + +"@babel/template@npm:^7.22.5": + version: 7.22.5 + resolution: "@babel/template@npm:7.22.5" + dependencies: + "@babel/code-frame": ^7.22.5 + "@babel/parser": ^7.22.5 + "@babel/types": ^7.22.5 + checksum: c5746410164039aca61829cdb42e9a55410f43cace6f51ca443313f3d0bdfa9a5a330d0b0df73dc17ef885c72104234ae05efede37c1cc8a72dc9f93425977a3 + languageName: node + linkType: hard + +"@babel/traverse@npm:^7.22.5, @babel/traverse@npm:^7.22.6, @babel/traverse@npm:^7.22.8": + version: 7.22.8 + resolution: "@babel/traverse@npm:7.22.8" + dependencies: + "@babel/code-frame": ^7.22.5 + "@babel/generator": ^7.22.7 + "@babel/helper-environment-visitor": ^7.22.5 + "@babel/helper-function-name": ^7.22.5 + "@babel/helper-hoist-variables": ^7.22.5 + "@babel/helper-split-export-declaration": ^7.22.6 + "@babel/parser": ^7.22.7 + "@babel/types": ^7.22.5 + debug: ^4.1.0 + globals: ^11.1.0 + checksum: a381369bc3eedfd13ed5fef7b884657f1c29024ea7388198149f0edc34bd69ce3966e9f40188d15f56490a5e12ba250ccc485f2882b53d41b054fccefb233e33 + languageName: node + linkType: hard + +"@babel/types@npm:^7.22.5, @babel/types@npm:^7.8.3": + version: 7.22.5 + resolution: "@babel/types@npm:7.22.5" + dependencies: + "@babel/helper-string-parser": ^7.22.5 + "@babel/helper-validator-identifier": ^7.22.5 + to-fast-properties: ^2.0.0 + checksum: c13a9c1dc7d2d1a241a2f8363540cb9af1d66e978e8984b400a20c4f38ba38ca29f06e26a0f2d49a70bad9e57615dac09c35accfddf1bb90d23cd3e0a0bab892 + languageName: node + linkType: hard + +"@cspotcode/source-map-support@npm:^0.8.0": + version: 0.8.1 + resolution: "@cspotcode/source-map-support@npm:0.8.1" + dependencies: + "@jridgewell/trace-mapping": 0.3.9 + checksum: 5718f267085ed8edb3e7ef210137241775e607ee18b77d95aa5bd7514f47f5019aa2d82d96b3bf342ef7aa890a346fa1044532ff7cc3009e7d24fce3ce6200fa + languageName: node + linkType: hard + +"@eslint-community/eslint-utils@npm:^4.2.0": + version: 4.4.0 + resolution: "@eslint-community/eslint-utils@npm:4.4.0" + dependencies: + eslint-visitor-keys: ^3.3.0 + peerDependencies: + eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 + checksum: cdfe3ae42b4f572cbfb46d20edafe6f36fc5fb52bf2d90875c58aefe226892b9677fef60820e2832caf864a326fe4fc225714c46e8389ccca04d5f9288aabd22 + languageName: node + linkType: hard + +"@eslint-community/regexpp@npm:^4.4.0": + version: 4.5.1 + resolution: "@eslint-community/regexpp@npm:4.5.1" + checksum: 6d901166d64998d591fab4db1c2f872981ccd5f6fe066a1ad0a93d4e11855ecae6bfb76660869a469563e8882d4307228cebd41142adb409d182f2966771e57e + languageName: node + linkType: hard + +"@eslint/eslintrc@npm:^2.1.0": + version: 2.1.0 + resolution: "@eslint/eslintrc@npm:2.1.0" + dependencies: + ajv: ^6.12.4 + debug: ^4.3.2 + espree: ^9.6.0 + globals: ^13.19.0 + ignore: ^5.2.0 + import-fresh: ^3.2.1 + js-yaml: ^4.1.0 + minimatch: ^3.1.2 + strip-json-comments: ^3.1.1 + checksum: d5ed0adbe23f6571d8c9bb0ca6edf7618dc6aed4046aa56df7139f65ae7b578874e0d9c796df784c25bda648ceb754b6320277d828c8b004876d7443b8dc018c + languageName: node + linkType: hard + +"@eslint/js@npm:8.44.0": + version: 8.44.0 + resolution: "@eslint/js@npm:8.44.0" + checksum: fc539583226a28f5677356e9f00d2789c34253f076643d2e32888250e509a4e13aafe0880cb2425139051de0f3a48d25bfc5afa96b7304f203b706c17340e3cf + languageName: node + linkType: hard + +"@humanwhocodes/config-array@npm:^0.11.10": + version: 0.11.10 + resolution: "@humanwhocodes/config-array@npm:0.11.10" + dependencies: + "@humanwhocodes/object-schema": ^1.2.1 + debug: ^4.1.1 + minimatch: ^3.0.5 + checksum: 1b1302e2403d0e35bc43e66d67a2b36b0ad1119efc704b5faff68c41f791a052355b010fb2d27ef022670f550de24cd6d08d5ecf0821c16326b7dcd0ee5d5d8a + languageName: node + linkType: hard + +"@humanwhocodes/module-importer@npm:^1.0.1": + version: 1.0.1 + resolution: "@humanwhocodes/module-importer@npm:1.0.1" + checksum: 0fd22007db8034a2cdf2c764b140d37d9020bbfce8a49d3ec5c05290e77d4b0263b1b972b752df8c89e5eaa94073408f2b7d977aed131faf6cf396ebb5d7fb61 + languageName: node + linkType: hard + +"@humanwhocodes/object-schema@npm:^1.2.1": + version: 1.2.1 + resolution: "@humanwhocodes/object-schema@npm:1.2.1" + checksum: a824a1ec31591231e4bad5787641f59e9633827d0a2eaae131a288d33c9ef0290bd16fda8da6f7c0fcb014147865d12118df10db57f27f41e20da92369fcb3f1 + languageName: node + linkType: hard + +"@isaacs/cliui@npm:^8.0.2": + version: 8.0.2 + resolution: "@isaacs/cliui@npm:8.0.2" + dependencies: + string-width: ^5.1.2 + string-width-cjs: "npm:string-width@^4.2.0" + strip-ansi: ^7.0.1 + strip-ansi-cjs: "npm:strip-ansi@^6.0.1" + wrap-ansi: ^8.1.0 + wrap-ansi-cjs: "npm:wrap-ansi@^7.0.0" + checksum: 4a473b9b32a7d4d3cfb7a614226e555091ff0c5a29a1734c28c72a182c2f6699b26fc6b5c2131dfd841e86b185aea714c72201d7c98c2fba5f17709333a67aeb + languageName: node + linkType: hard + +"@istanbuljs/load-nyc-config@npm:^1.0.0": + version: 1.1.0 + resolution: "@istanbuljs/load-nyc-config@npm:1.1.0" + dependencies: + camelcase: ^5.3.1 + find-up: ^4.1.0 + get-package-type: ^0.1.0 + js-yaml: ^3.13.1 + resolve-from: ^5.0.0 + checksum: d578da5e2e804d5c93228450a1380e1a3c691de4953acc162f387b717258512a3e07b83510a936d9fab03eac90817473917e24f5d16297af3867f59328d58568 + languageName: node + linkType: hard + +"@istanbuljs/nyc-config-typescript@npm:^1.0.2": + version: 1.0.2 + resolution: "@istanbuljs/nyc-config-typescript@npm:1.0.2" + dependencies: + "@istanbuljs/schema": ^0.1.2 + peerDependencies: + nyc: ">=15" + checksum: df6f9c9b17df8f1d8813f768c11ca31ec125d60bcd82d8273a467022e414d2d686ee80abb7b0f0e3c512b7ed686771fadb7fb5be8881619b9f6cb1f31b86e9f3 + languageName: node + linkType: hard + +"@istanbuljs/schema@npm:^0.1.2": + version: 0.1.3 + resolution: "@istanbuljs/schema@npm:0.1.3" + checksum: 5282759d961d61350f33d9118d16bcaed914ebf8061a52f4fa474b2cb08720c9c81d165e13b82f2e5a8a212cc5af482f0c6fc1ac27b9e067e5394c9a6ed186c9 + languageName: node + linkType: hard + +"@jridgewell/gen-mapping@npm:^0.3.0, @jridgewell/gen-mapping@npm:^0.3.2": + version: 0.3.3 + resolution: "@jridgewell/gen-mapping@npm:0.3.3" + dependencies: + "@jridgewell/set-array": ^1.0.1 + "@jridgewell/sourcemap-codec": ^1.4.10 + "@jridgewell/trace-mapping": ^0.3.9 + checksum: 4a74944bd31f22354fc01c3da32e83c19e519e3bbadafa114f6da4522ea77dd0c2842607e923a591d60a76699d819a2fbb6f3552e277efdb9b58b081390b60ab + languageName: node + linkType: hard + +"@jridgewell/resolve-uri@npm:3.1.0": + version: 3.1.0 + resolution: "@jridgewell/resolve-uri@npm:3.1.0" + checksum: b5ceaaf9a110fcb2780d1d8f8d4a0bfd216702f31c988d8042e5f8fbe353c55d9b0f55a1733afdc64806f8e79c485d2464680ac48a0d9fcadb9548ee6b81d267 + languageName: node + linkType: hard + +"@jridgewell/resolve-uri@npm:^3.0.3": + version: 3.1.1 + resolution: "@jridgewell/resolve-uri@npm:3.1.1" + checksum: f5b441fe7900eab4f9155b3b93f9800a916257f4e8563afbcd3b5a5337b55e52bd8ae6735453b1b745457d9f6cdb16d74cd6220bbdd98cf153239e13f6cbb653 + languageName: node + linkType: hard + +"@jridgewell/set-array@npm:^1.0.1": + version: 1.1.2 + resolution: "@jridgewell/set-array@npm:1.1.2" + checksum: 69a84d5980385f396ff60a175f7177af0b8da4ddb81824cb7016a9ef914eee9806c72b6b65942003c63f7983d4f39a5c6c27185bbca88eb4690b62075602e28e + languageName: node + linkType: hard + +"@jridgewell/sourcemap-codec@npm:1.4.14": + version: 1.4.14 + resolution: "@jridgewell/sourcemap-codec@npm:1.4.14" + checksum: 61100637b6d173d3ba786a5dff019e1a74b1f394f323c1fee337ff390239f053b87266c7a948777f4b1ee68c01a8ad0ab61e5ff4abb5a012a0b091bec391ab97 + languageName: node + linkType: hard + +"@jridgewell/sourcemap-codec@npm:^1.4.10": + version: 1.4.15 + resolution: "@jridgewell/sourcemap-codec@npm:1.4.15" + checksum: b881c7e503db3fc7f3c1f35a1dd2655a188cc51a3612d76efc8a6eb74728bef5606e6758ee77423e564092b4a518aba569bbb21c9bac5ab7a35b0c6ae7e344c8 + languageName: node + linkType: hard + +"@jridgewell/trace-mapping@npm:0.3.9": + version: 0.3.9 + resolution: "@jridgewell/trace-mapping@npm:0.3.9" + dependencies: + "@jridgewell/resolve-uri": ^3.0.3 + "@jridgewell/sourcemap-codec": ^1.4.10 + checksum: d89597752fd88d3f3480845691a05a44bd21faac18e2185b6f436c3b0fd0c5a859fbbd9aaa92050c4052caf325ad3e10e2e1d1b64327517471b7d51babc0ddef + languageName: node + linkType: hard + +"@jridgewell/trace-mapping@npm:^0.3.17, @jridgewell/trace-mapping@npm:^0.3.9": + version: 0.3.18 + resolution: "@jridgewell/trace-mapping@npm:0.3.18" + dependencies: + "@jridgewell/resolve-uri": 3.1.0 + "@jridgewell/sourcemap-codec": 1.4.14 + checksum: 0572669f855260808c16fe8f78f5f1b4356463b11d3f2c7c0b5580c8ba1cbf4ae53efe9f627595830856e57dbac2325ac17eb0c3dd0ec42102e6f227cc289c02 + languageName: node + linkType: hard + +"@nicolo-ribaudo/semver-v6@npm:^6.3.3": + version: 6.3.3 + resolution: "@nicolo-ribaudo/semver-v6@npm:6.3.3" + bin: + semver: bin/semver.js + checksum: 8290855b1591477d2298364541fda64fafd4acc110b387067a71c9b05f4105c0a4ac079857ae9cd107c42ee884e8724a406b5116f069575e02d7ab87a35a5272 + languageName: node + linkType: hard + +"@nodelib/fs.scandir@npm:2.1.5": + version: 2.1.5 + resolution: "@nodelib/fs.scandir@npm:2.1.5" + dependencies: + "@nodelib/fs.stat": 2.0.5 + run-parallel: ^1.1.9 + checksum: a970d595bd23c66c880e0ef1817791432dbb7acbb8d44b7e7d0e7a22f4521260d4a83f7f9fd61d44fda4610105577f8f58a60718105fb38352baed612fd79e59 + languageName: node + linkType: hard + +"@nodelib/fs.stat@npm:2.0.5, @nodelib/fs.stat@npm:^2.0.2": + version: 2.0.5 + resolution: "@nodelib/fs.stat@npm:2.0.5" + checksum: 012480b5ca9d97bff9261571dbbec7bbc6033f69cc92908bc1ecfad0792361a5a1994bc48674b9ef76419d056a03efadfce5a6cf6dbc0a36559571a7a483f6f0 + languageName: node + linkType: hard + +"@nodelib/fs.walk@npm:^1.2.3, @nodelib/fs.walk@npm:^1.2.8": + version: 1.2.8 + resolution: "@nodelib/fs.walk@npm:1.2.8" + dependencies: + "@nodelib/fs.scandir": 2.1.5 + fastq: ^1.6.0 + checksum: 190c643f156d8f8f277bf2a6078af1ffde1fd43f498f187c2db24d35b4b4b5785c02c7dc52e356497b9a1b65b13edc996de08de0b961c32844364da02986dc53 + languageName: node + linkType: hard + +"@npmcli/fs@npm:^3.1.0": + version: 3.1.0 + resolution: "@npmcli/fs@npm:3.1.0" + dependencies: + semver: ^7.3.5 + checksum: a50a6818de5fc557d0b0e6f50ec780a7a02ab8ad07e5ac8b16bf519e0ad60a144ac64f97d05c443c3367235d337182e1d012bbac0eb8dbae8dc7b40b193efd0e + languageName: node + linkType: hard + +"@pkgjs/parseargs@npm:^0.11.0": + version: 0.11.0 + resolution: "@pkgjs/parseargs@npm:0.11.0" + checksum: 6ad6a00fc4f2f2cfc6bff76fb1d88b8ee20bc0601e18ebb01b6d4be583733a860239a521a7fbca73b612e66705078809483549d2b18f370eb346c5155c8e4a0f + languageName: node + linkType: hard + +"@sinonjs/commons@npm:^1, @sinonjs/commons@npm:^1.3.0, @sinonjs/commons@npm:^1.4.0, @sinonjs/commons@npm:^1.7.0": + version: 1.8.6 + resolution: "@sinonjs/commons@npm:1.8.6" + dependencies: + type-detect: 4.0.8 + checksum: 7d3f8c1e85f30cd4e83594fc19b7a657f14d49eb8d95a30095631ce15e906c869e0eff96c5b93dffea7490c00418b07f54582ba49c6560feb2a8c34c0b16832d + languageName: node + linkType: hard + +"@sinonjs/formatio@npm:^3.2.1": + version: 3.2.2 + resolution: "@sinonjs/formatio@npm:3.2.2" + dependencies: + "@sinonjs/commons": ^1 + "@sinonjs/samsam": ^3.1.0 + checksum: ddc30698df9b0aa59204da93ca94fd04bc5672ac03c798c0a487c35d514d7d8e0ce0e4c72386fc80e29f59cb1cc54eeea3b7f804281b3c4e3dd2394de56c6e4a + languageName: node + linkType: hard + +"@sinonjs/samsam@npm:^3.1.0, @sinonjs/samsam@npm:^3.3.3": + version: 3.3.3 + resolution: "@sinonjs/samsam@npm:3.3.3" + dependencies: + "@sinonjs/commons": ^1.3.0 + array-from: ^2.1.1 + lodash: ^4.17.15 + checksum: 340f2f62dec3fa1e5e9300a75996bd12ab9d2da4f6b453fa5d1ee101cc5e58eb218af2e2584b496d41ba31c3c0854d47a691fd9a0d8b9092f3cb6a5c7a080856 + languageName: node + linkType: hard + +"@sinonjs/text-encoding@npm:^0.7.1": + version: 0.7.2 + resolution: "@sinonjs/text-encoding@npm:0.7.2" + checksum: fe690002a32ba06906cf87e2e8fe84d1590294586f2a7fd180a65355b53660c155c3273d8011a5f2b77209b819aa7306678ae6e4aea0df014bd7ffd4bbbcf1ab + languageName: node + linkType: hard + +"@tootallnate/once@npm:2": + version: 2.0.0 + resolution: "@tootallnate/once@npm:2.0.0" + checksum: ad87447820dd3f24825d2d947ebc03072b20a42bfc96cbafec16bff8bbda6c1a81fcb0be56d5b21968560c5359a0af4038a68ba150c3e1694fe4c109a063bed8 + languageName: node + linkType: hard + +"@tsconfig/node10@npm:^1.0.7": + version: 1.0.9 + resolution: "@tsconfig/node10@npm:1.0.9" + checksum: a33ae4dc2a621c0678ac8ac4bceb8e512ae75dac65417a2ad9b022d9b5411e863c4c198b6ba9ef659e14b9fb609bbec680841a2e84c1172df7a5ffcf076539df + languageName: node + linkType: hard + +"@tsconfig/node12@npm:^1.0.7": + version: 1.0.11 + resolution: "@tsconfig/node12@npm:1.0.11" + checksum: 5ce29a41b13e7897a58b8e2df11269c5395999e588b9a467386f99d1d26f6c77d1af2719e407621412520ea30517d718d5192a32403b8dfcc163bf33e40a338a + languageName: node + linkType: hard + +"@tsconfig/node14@npm:^1.0.0": + version: 1.0.3 + resolution: "@tsconfig/node14@npm:1.0.3" + checksum: 19275fe80c4c8d0ad0abed6a96dbf00642e88b220b090418609c4376e1cef81bf16237bf170ad1b341452feddb8115d8dd2e5acdfdea1b27422071163dc9ba9d + languageName: node + linkType: hard + +"@tsconfig/node16@npm:^1.0.2": + version: 1.0.4 + resolution: "@tsconfig/node16@npm:1.0.4" + checksum: 202319785901f942a6e1e476b872d421baec20cf09f4b266a1854060efbf78cde16a4d256e8bc949d31e6cd9a90f1e8ef8fb06af96a65e98338a2b6b0de0a0ff + languageName: node + linkType: hard + +"@types/json-schema@npm:^7.0.9": + version: 7.0.12 + resolution: "@types/json-schema@npm:7.0.12" + checksum: 00239e97234eeb5ceefb0c1875d98ade6e922bfec39dd365ec6bd360b5c2f825e612ac4f6e5f1d13601b8b30f378f15e6faa805a3a732f4a1bbe61915163d293 + languageName: node + linkType: hard + +"@types/lodash@npm:^4.14.195": + version: 4.14.195 + resolution: "@types/lodash@npm:4.14.195" + checksum: 39b75ca635b3fa943d17d3d3aabc750babe4c8212485a4df166fe0516e39288e14b0c60afc6e21913cc0e5a84734633c71e617e2bd14eaa1cf51b8d7799c432e + languageName: node + linkType: hard + +"@types/mocha@npm:^9.1.1": + version: 9.1.1 + resolution: "@types/mocha@npm:9.1.1" + checksum: 516077c0acd9806dc78317f88aaac0df5aaf0bdc2f63dfdadeabdf0b0137953b6ca65472e6ff7c30bc93ce4e0ae76eae70e8d46764b9a8eae4877a928b6ef49a + languageName: node + linkType: hard + +"@types/node@npm:^16.18.38": + version: 16.18.38 + resolution: "@types/node@npm:16.18.38" + checksum: a3baa141e49ce94486f083eea1240cf38479a73ba663e1bf3f52f85b466125821b6e3ea85ded38fde3901530aca4601291395a50eefcea533a4f3b45171bda28 + languageName: node + linkType: hard + +"@types/semver@npm:^7.3.12": + version: 7.5.0 + resolution: "@types/semver@npm:7.5.0" + checksum: 0a64b9b9c7424d9a467658b18dd70d1d781c2d6f033096a6e05762d20ebbad23c1b69b0083b0484722aabf35640b78ccc3de26368bcae1129c87e9df028a22e2 + languageName: node + linkType: hard + +"@types/sinon@npm:^10.0.15": + version: 10.0.15 + resolution: "@types/sinon@npm:10.0.15" + dependencies: + "@types/sinonjs__fake-timers": "*" + checksum: cec6d7d9d5582ca3ac851b029d5d90451bfe6d376164253792a6eb6ddcd609a0411a7fac9ed92e1879e7d3ec091d2ea2e8dbb4f6140a1065439b81dc20cafa7c + languageName: node + linkType: hard + +"@types/sinonjs__fake-timers@npm:*": + version: 8.1.2 + resolution: "@types/sinonjs__fake-timers@npm:8.1.2" + checksum: bbc73a5ab6c0ec974929392f3d6e1e8db4ebad97ec506d785301e1c3d8a4f98a35b1aa95b97035daef02886fd8efd7788a2fa3ced2ec7105988bfd8dce61eedd + languageName: node + linkType: hard + +"@typescript-eslint/eslint-plugin@npm:^5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/eslint-plugin@npm:5.61.0" + dependencies: + "@eslint-community/regexpp": ^4.4.0 + "@typescript-eslint/scope-manager": 5.61.0 + "@typescript-eslint/type-utils": 5.61.0 + "@typescript-eslint/utils": 5.61.0 + debug: ^4.3.4 + graphemer: ^1.4.0 + ignore: ^5.2.0 + natural-compare-lite: ^1.4.0 + semver: ^7.3.7 + tsutils: ^3.21.0 + peerDependencies: + "@typescript-eslint/parser": ^5.0.0 + eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + peerDependenciesMeta: + typescript: + optional: true + checksum: d9e891fb43ccb75322fc40d58d02479f98bd3c962db71075438868b13f579643d714a24b5477a827be7ca2e7e9f6058c406241b6696a6395c6fcbd6de76e015c + languageName: node + linkType: hard + +"@typescript-eslint/parser@npm:^5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/parser@npm:5.61.0" + dependencies: + "@typescript-eslint/scope-manager": 5.61.0 + "@typescript-eslint/types": 5.61.0 + "@typescript-eslint/typescript-estree": 5.61.0 + debug: ^4.3.4 + peerDependencies: + eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + peerDependenciesMeta: + typescript: + optional: true + checksum: 2422bca03ecc6830700aaa739ec46b8e9ab6c0a47a67f140dc6b62a42a8b98997e73bce52c6a010b8a9b461211c46ba865d5b7f680a7823cf5c245d3b61f7fd5 + languageName: node + linkType: hard + +"@typescript-eslint/scope-manager@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/scope-manager@npm:5.61.0" + dependencies: + "@typescript-eslint/types": 5.61.0 + "@typescript-eslint/visitor-keys": 5.61.0 + checksum: 6dfbb42c4b7d796ae3c395398bdfd2e5a4ae8aaf1448381278ecc39a1d1045af2cb452da5a00519d265bc1a5997523de22d5021acb4dbe1648502fe61512d3c6 + languageName: node + linkType: hard + +"@typescript-eslint/type-utils@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/type-utils@npm:5.61.0" + dependencies: + "@typescript-eslint/typescript-estree": 5.61.0 + "@typescript-eslint/utils": 5.61.0 + debug: ^4.3.4 + tsutils: ^3.21.0 + peerDependencies: + eslint: "*" + peerDependenciesMeta: + typescript: + optional: true + checksum: f0203fd48c6218f004dd73a9a71ba4cf97f015d0f13a7b3c821a3ba7ec814839bae270a1db589184ca7091fe54815a3171d1993e8a25200bf33e131bd6e855d4 + languageName: node + linkType: hard + +"@typescript-eslint/types@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/types@npm:5.61.0" + checksum: d311ca2141f6bcb5f0f8f97ddbc218c9911e0735aaa30f0f2e64d518fb33568410754e1b04bf157175f8783504f8ec62a7ab53a66a18507f43edb1e21fe69e90 + languageName: node + linkType: hard + +"@typescript-eslint/typescript-estree@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/typescript-estree@npm:5.61.0" + dependencies: + "@typescript-eslint/types": 5.61.0 + "@typescript-eslint/visitor-keys": 5.61.0 + debug: ^4.3.4 + globby: ^11.1.0 + is-glob: ^4.0.3 + semver: ^7.3.7 + tsutils: ^3.21.0 + peerDependenciesMeta: + typescript: + optional: true + checksum: efe25a1b2774939c02cb9b388cf72efa672811f1c39a87ddd617937f63c2320551ce459ba69c6d022e33322594d40b9f2d2c6bc9937387718adc40dc5e57ea8e + languageName: node + linkType: hard + +"@typescript-eslint/utils@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/utils@npm:5.61.0" + dependencies: + "@eslint-community/eslint-utils": ^4.2.0 + "@types/json-schema": ^7.0.9 + "@types/semver": ^7.3.12 + "@typescript-eslint/scope-manager": 5.61.0 + "@typescript-eslint/types": 5.61.0 + "@typescript-eslint/typescript-estree": 5.61.0 + eslint-scope: ^5.1.1 + semver: ^7.3.7 + peerDependencies: + eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 + checksum: 24efc1964e6c92db96fe0d9a390550e4f27e8f353e51a9b46bda03e6692ea5d40f398d539235a4ff0894e9e45dfcfb51df953ade2ae9d17a1421449625ce6f5a + languageName: node + linkType: hard + +"@typescript-eslint/visitor-keys@npm:5.61.0": + version: 5.61.0 + resolution: "@typescript-eslint/visitor-keys@npm:5.61.0" + dependencies: + "@typescript-eslint/types": 5.61.0 + eslint-visitor-keys: ^3.3.0 + checksum: a8d589f61ddfc380787218da4d347e8f9aef0f82f4a93f1daee46786bda889a90961c7ec1b470db5e3261438a728fdfd956f5bda6ee2de22c4be2d2152d6e270 + languageName: node + linkType: hard + +"@ungap/promise-all-settled@npm:1.1.2": + version: 1.1.2 + resolution: "@ungap/promise-all-settled@npm:1.1.2" + checksum: 08d37fdfa23a6fe8139f1305313562ebad973f3fac01bcce2773b2bda5bcb0146dfdcf3cb6a722cf0a5f2ca0bc56a827eac8f1e7b3beddc548f654addf1fc34c + languageName: node + linkType: hard + +"abbrev@npm:^1.0.0": + version: 1.1.1 + resolution: "abbrev@npm:1.1.1" + checksum: a4a97ec07d7ea112c517036882b2ac22f3109b7b19077dc656316d07d308438aac28e4d9746dc4d84bf6b1e75b4a7b0a5f3cb30592419f128ca9a8cee3bcfa17 + languageName: node + linkType: hard + +"acorn-jsx@npm:^5.3.2": + version: 5.3.2 + resolution: "acorn-jsx@npm:5.3.2" + peerDependencies: + acorn: ^6.0.0 || ^7.0.0 || ^8.0.0 + checksum: c3d3b2a89c9a056b205b69530a37b972b404ee46ec8e5b341666f9513d3163e2a4f214a71f4dfc7370f5a9c07472d2fd1c11c91c3f03d093e37637d95da98950 + languageName: node + linkType: hard + +"acorn-walk@npm:^8.1.1": + version: 8.2.0 + resolution: "acorn-walk@npm:8.2.0" + checksum: 1715e76c01dd7b2d4ca472f9c58968516a4899378a63ad5b6c2d668bba8da21a71976c14ec5f5b75f887b6317c4ae0b897ab141c831d741dc76024d8745f1ad1 + languageName: node + linkType: hard + +"acorn@npm:^8.4.1, acorn@npm:^8.9.0": + version: 8.10.0 + resolution: "acorn@npm:8.10.0" + bin: + acorn: bin/acorn + checksum: 538ba38af0cc9e5ef983aee196c4b8b4d87c0c94532334fa7e065b2c8a1f85863467bb774231aae91613fcda5e68740c15d97b1967ae3394d20faddddd8af61d + languageName: node + linkType: hard + +"agent-base@npm:6, agent-base@npm:^6.0.2": + version: 6.0.2 + resolution: "agent-base@npm:6.0.2" + dependencies: + debug: 4 + checksum: f52b6872cc96fd5f622071b71ef200e01c7c4c454ee68bc9accca90c98cfb39f2810e3e9aa330435835eedc8c23f4f8a15267f67c6e245d2b33757575bdac49d + languageName: node + linkType: hard + +"agentkeepalive@npm:^4.2.1": + version: 4.3.0 + resolution: "agentkeepalive@npm:4.3.0" + dependencies: + debug: ^4.1.0 + depd: ^2.0.0 + humanize-ms: ^1.2.1 + checksum: 982453aa44c11a06826c836025e5162c846e1200adb56f2d075400da7d32d87021b3b0a58768d949d824811f5654223d5a8a3dad120921a2439625eb847c6260 + languageName: node + linkType: hard + +"aggregate-error@npm:^3.0.0": + version: 3.1.0 + resolution: "aggregate-error@npm:3.1.0" + dependencies: + clean-stack: ^2.0.0 + indent-string: ^4.0.0 + checksum: 1101a33f21baa27a2fa8e04b698271e64616b886795fd43c31068c07533c7b3facfcaf4e9e0cab3624bd88f729a592f1c901a1a229c9e490eafce411a8644b79 + languageName: node + linkType: hard + +"ajv@npm:^6.10.0, ajv@npm:^6.12.4": + version: 6.12.6 + resolution: "ajv@npm:6.12.6" + dependencies: + fast-deep-equal: ^3.1.1 + fast-json-stable-stringify: ^2.0.0 + json-schema-traverse: ^0.4.1 + uri-js: ^4.2.2 + checksum: 874972efe5c4202ab0a68379481fbd3d1b5d0a7bd6d3cc21d40d3536ebff3352a2a1fabb632d4fd2cc7fe4cbdcd5ed6782084c9bbf7f32a1536d18f9da5007d4 + languageName: node + linkType: hard + +"ansi-colors@npm:4.1.1": + version: 4.1.1 + resolution: "ansi-colors@npm:4.1.1" + checksum: 138d04a51076cb085da0a7e2d000c5c0bb09f6e772ed5c65c53cb118d37f6c5f1637506d7155fb5f330f0abcf6f12fa2e489ac3f8cdab9da393bf1bb4f9a32b0 + languageName: node + linkType: hard + +"ansi-regex@npm:^5.0.1": + version: 5.0.1 + resolution: "ansi-regex@npm:5.0.1" + checksum: 2aa4bb54caf2d622f1afdad09441695af2a83aa3fe8b8afa581d205e57ed4261c183c4d3877cee25794443fde5876417d859c108078ab788d6af7e4fe52eb66b + languageName: node + linkType: hard + +"ansi-regex@npm:^6.0.1": + version: 6.0.1 + resolution: "ansi-regex@npm:6.0.1" + checksum: 1ff8b7667cded1de4fa2c9ae283e979fc87036864317da86a2e546725f96406746411d0d85e87a2d12fa5abd715d90006de7fa4fa0477c92321ad3b4c7d4e169 + languageName: node + linkType: hard + +"ansi-styles@npm:^3.2.1": + version: 3.2.1 + resolution: "ansi-styles@npm:3.2.1" + dependencies: + color-convert: ^1.9.0 + checksum: d85ade01c10e5dd77b6c89f34ed7531da5830d2cb5882c645f330079975b716438cd7ebb81d0d6e6b4f9c577f19ae41ab55f07f19786b02f9dfd9e0377395665 + languageName: node + linkType: hard + +"ansi-styles@npm:^4.0.0, ansi-styles@npm:^4.1.0": + version: 4.3.0 + resolution: "ansi-styles@npm:4.3.0" + dependencies: + color-convert: ^2.0.1 + checksum: 513b44c3b2105dd14cc42a19271e80f386466c4be574bccf60b627432f9198571ebf4ab1e4c3ba17347658f4ee1711c163d574248c0c1cdc2d5917a0ad582ec4 + languageName: node + linkType: hard + +"ansi-styles@npm:^6.1.0": + version: 6.2.1 + resolution: "ansi-styles@npm:6.2.1" + checksum: ef940f2f0ced1a6347398da88a91da7930c33ecac3c77b72c5905f8b8fe402c52e6fde304ff5347f616e27a742da3f1dc76de98f6866c69251ad0b07a66776d9 + languageName: node + linkType: hard + +"anymatch@npm:~3.1.2": + version: 3.1.3 + resolution: "anymatch@npm:3.1.3" + dependencies: + normalize-path: ^3.0.0 + picomatch: ^2.0.4 + checksum: 3e044fd6d1d26545f235a9fe4d7a534e2029d8e59fa7fd9f2a6eb21230f6b5380ea1eaf55136e60cbf8e613544b3b766e7a6fa2102e2a3a117505466e3025dc2 + languageName: node + linkType: hard + +"append-transform@npm:^2.0.0": + version: 2.0.0 + resolution: "append-transform@npm:2.0.0" + dependencies: + default-require-extensions: ^3.0.0 + checksum: f26f393bf7a428fd1bb18f2758a819830a582243310c5170edb3f98fdc5a535333d02b952f7c2d9b14522bd8ead5b132a0b15000eca18fa9f49172963ebbc231 + languageName: node + linkType: hard + +"aproba@npm:^1.0.3 || ^2.0.0": + version: 2.0.0 + resolution: "aproba@npm:2.0.0" + checksum: 5615cadcfb45289eea63f8afd064ab656006361020e1735112e346593856f87435e02d8dcc7ff0d11928bc7d425f27bc7c2a84f6c0b35ab0ff659c814c138a24 + languageName: node + linkType: hard + +"archy@npm:^1.0.0": + version: 1.0.0 + resolution: "archy@npm:1.0.0" + checksum: 504ae7af655130bab9f471343cfdb054feaec7d8e300e13348bc9fe9e660f83d422e473069584f73233c701ae37d1c8452ff2522f2a20c38849e0f406f1732ac + languageName: node + linkType: hard + +"are-we-there-yet@npm:^3.0.0": + version: 3.0.1 + resolution: "are-we-there-yet@npm:3.0.1" + dependencies: + delegates: ^1.0.0 + readable-stream: ^3.6.0 + checksum: 52590c24860fa7173bedeb69a4c05fb573473e860197f618b9a28432ee4379049336727ae3a1f9c4cb083114601c1140cee578376164d0e651217a9843f9fe83 + languageName: node + linkType: hard + +"arg@npm:^4.1.0": + version: 4.1.3 + resolution: "arg@npm:4.1.3" + checksum: 544af8dd3f60546d3e4aff084d451b96961d2267d668670199692f8d054f0415d86fc5497d0e641e91546f0aa920e7c29e5250e99fc89f5552a34b5d93b77f43 + languageName: node + linkType: hard + +"argparse@npm:^1.0.7": + version: 1.0.10 + resolution: "argparse@npm:1.0.10" + dependencies: + sprintf-js: ~1.0.2 + checksum: 7ca6e45583a28de7258e39e13d81e925cfa25d7d4aacbf806a382d3c02fcb13403a07fb8aeef949f10a7cfe4a62da0e2e807b348a5980554cc28ee573ef95945 + languageName: node + linkType: hard + +"argparse@npm:^2.0.1": + version: 2.0.1 + resolution: "argparse@npm:2.0.1" + checksum: 83644b56493e89a254bae05702abf3a1101b4fa4d0ca31df1c9985275a5a5bd47b3c27b7fa0b71098d41114d8ca000e6ed90cad764b306f8a503665e4d517ced + languageName: node + linkType: hard + +"array-from@npm:^2.1.1": + version: 2.1.1 + resolution: "array-from@npm:2.1.1" + checksum: 4cd5fa27aa6133b99a57c2881d2a8a66ec59b8e17a0c900f7e8ac9a0a2fae450ed682b67435467bfa71ac9328d025a760c5c46a95586a352180c5a79fc13015d + languageName: node + linkType: hard + +"array-union@npm:^2.1.0": + version: 2.1.0 + resolution: "array-union@npm:2.1.0" + checksum: 5bee12395cba82da674931df6d0fea23c4aa4660cb3b338ced9f828782a65caa232573e6bf3968f23e0c5eb301764a382cef2f128b170a9dc59de0e36c39f98d + languageName: node + linkType: hard + +"axios@npm:^0.24.0": + version: 0.24.0 + resolution: "axios@npm:0.24.0" + dependencies: + follow-redirects: ^1.14.4 + checksum: 468cf496c08a6aadfb7e699bebdac02851e3043d4e7d282350804ea8900e30d368daa6e3cd4ab83b8ddb5a3b1e17a5a21ada13fc9cebd27b74828f47a4236316 + languageName: node + linkType: hard + +"balanced-match@npm:^1.0.0": + version: 1.0.2 + resolution: "balanced-match@npm:1.0.2" + checksum: 9706c088a283058a8a99e0bf91b0a2f75497f185980d9ffa8b304de1d9e58ebda7c72c07ebf01dadedaac5b2907b2c6f566f660d62bd336c3468e960403b9d65 + languageName: node + linkType: hard + +"binary-extensions@npm:^2.0.0": + version: 2.2.0 + resolution: "binary-extensions@npm:2.2.0" + checksum: ccd267956c58d2315f5d3ea6757cf09863c5fc703e50fbeb13a7dc849b812ef76e3cf9ca8f35a0c48498776a7478d7b4a0418e1e2b8cb9cb9731f2922aaad7f8 + languageName: node + linkType: hard + +"brace-expansion@npm:^1.1.7": + version: 1.1.11 + resolution: "brace-expansion@npm:1.1.11" + dependencies: + balanced-match: ^1.0.0 + concat-map: 0.0.1 + checksum: faf34a7bb0c3fcf4b59c7808bc5d2a96a40988addf2e7e09dfbb67a2251800e0d14cd2bfc1aa79174f2f5095c54ff27f46fb1289fe2d77dac755b5eb3434cc07 + languageName: node + linkType: hard + +"brace-expansion@npm:^2.0.1": + version: 2.0.1 + resolution: "brace-expansion@npm:2.0.1" + dependencies: + balanced-match: ^1.0.0 + checksum: a61e7cd2e8a8505e9f0036b3b6108ba5e926b4b55089eeb5550cd04a471fe216c96d4fe7e4c7f995c728c554ae20ddfc4244cad10aef255e72b62930afd233d1 + languageName: node + linkType: hard + +"braces@npm:^3.0.2, braces@npm:~3.0.2": + version: 3.0.2 + resolution: "braces@npm:3.0.2" + dependencies: + fill-range: ^7.0.1 + checksum: e2a8e769a863f3d4ee887b5fe21f63193a891c68b612ddb4b68d82d1b5f3ff9073af066c343e9867a393fe4c2555dcb33e89b937195feb9c1613d259edfcd459 + languageName: node + linkType: hard + +"browser-stdout@npm:1.3.1": + version: 1.3.1 + resolution: "browser-stdout@npm:1.3.1" + checksum: b717b19b25952dd6af483e368f9bcd6b14b87740c3d226c2977a65e84666ffd67000bddea7d911f111a9b6ddc822b234de42d52ab6507bce4119a4cc003ef7b3 + languageName: node + linkType: hard + +"browserslist@npm:^4.21.9": + version: 4.21.9 + resolution: "browserslist@npm:4.21.9" + dependencies: + caniuse-lite: ^1.0.30001503 + electron-to-chromium: ^1.4.431 + node-releases: ^2.0.12 + update-browserslist-db: ^1.0.11 + bin: + browserslist: cli.js + checksum: 80d3820584e211484ad1b1a5cfdeca1dd00442f47be87e117e1dda34b628c87e18b81ae7986fa5977b3e6a03154f6d13cd763baa6b8bf5dd9dd19f4926603698 + languageName: node + linkType: hard + +"cacache@npm:^17.0.0": + version: 17.1.3 + resolution: "cacache@npm:17.1.3" + dependencies: + "@npmcli/fs": ^3.1.0 + fs-minipass: ^3.0.0 + glob: ^10.2.2 + lru-cache: ^7.7.1 + minipass: ^5.0.0 + minipass-collect: ^1.0.2 + minipass-flush: ^1.0.5 + minipass-pipeline: ^1.2.4 + p-map: ^4.0.0 + ssri: ^10.0.0 + tar: ^6.1.11 + unique-filename: ^3.0.0 + checksum: 385756781e1e21af089160d89d7462b7ed9883c978e848c7075b90b73cb823680e66092d61513050164588387d2ca87dd6d910e28d64bc13a9ac82cd8580c796 + languageName: node + linkType: hard + +"caching-transform@npm:^4.0.0": + version: 4.0.0 + resolution: "caching-transform@npm:4.0.0" + dependencies: + hasha: ^5.0.0 + make-dir: ^3.0.0 + package-hash: ^4.0.0 + write-file-atomic: ^3.0.0 + checksum: c4db6939533b677866808de67c32f0aaf8bf4fd3e3b8dc957e5d630c007c06b7f11512d44c38a38287fb068e931067e8da9019c34d787259a44121c9a6b87a1f + languageName: node + linkType: hard + +"callsites@npm:^3.0.0": + version: 3.1.0 + resolution: "callsites@npm:3.1.0" + checksum: 072d17b6abb459c2ba96598918b55868af677154bec7e73d222ef95a8fdb9bbf7dae96a8421085cdad8cd190d86653b5b6dc55a4484f2e5b2e27d5e0c3fc15b3 + languageName: node + linkType: hard + +"camelcase@npm:^5.0.0, camelcase@npm:^5.3.1": + version: 5.3.1 + resolution: "camelcase@npm:5.3.1" + checksum: e6effce26b9404e3c0f301498184f243811c30dfe6d0b9051863bd8e4034d09c8c2923794f280d6827e5aa055f6c434115ff97864a16a963366fb35fd673024b + languageName: node + linkType: hard + +"camelcase@npm:^6.0.0": + version: 6.3.0 + resolution: "camelcase@npm:6.3.0" + checksum: 8c96818a9076434998511251dcb2761a94817ea17dbdc37f47ac080bd088fc62c7369429a19e2178b993497132c8cbcf5cc1f44ba963e76782ba469c0474938d + languageName: node + linkType: hard + +"caniuse-lite@npm:^1.0.30001503": + version: 1.0.30001514 + resolution: "caniuse-lite@npm:1.0.30001514" + checksum: ee2e90fe63cb59fb4a1515eb6b157f1c26d3ccba496b994b0f03088c39c282ee2fb8c160ad7b677ee196b5bb078b23f2f9474c32e4e47724f4d782de92bb8bbe + languageName: node + linkType: hard + +"chalk@npm:^2.0.0": + version: 2.4.2 + resolution: "chalk@npm:2.4.2" + dependencies: + ansi-styles: ^3.2.1 + escape-string-regexp: ^1.0.5 + supports-color: ^5.3.0 + checksum: ec3661d38fe77f681200f878edbd9448821924e0f93a9cefc0e26a33b145f1027a2084bf19967160d11e1f03bfe4eaffcabf5493b89098b2782c3fe0b03d80c2 + languageName: node + linkType: hard + +"chalk@npm:^4.0.0, chalk@npm:^4.1.0": + version: 4.1.2 + resolution: "chalk@npm:4.1.2" + dependencies: + ansi-styles: ^4.1.0 + supports-color: ^7.1.0 + checksum: fe75c9d5c76a7a98d45495b91b2172fa3b7a09e0cc9370e5c8feb1c567b85c4288e2b3fded7cfdd7359ac28d6b3844feb8b82b8686842e93d23c827c417e83fc + languageName: node + linkType: hard + +"chokidar@npm:3.5.3": + version: 3.5.3 + resolution: "chokidar@npm:3.5.3" + dependencies: + anymatch: ~3.1.2 + braces: ~3.0.2 + fsevents: ~2.3.2 + glob-parent: ~5.1.2 + is-binary-path: ~2.1.0 + is-glob: ~4.0.1 + normalize-path: ~3.0.0 + readdirp: ~3.6.0 + dependenciesMeta: + fsevents: + optional: true + checksum: b49fcde40176ba007ff361b198a2d35df60d9bb2a5aab228279eb810feae9294a6b4649ab15981304447afe1e6ffbf4788ad5db77235dc770ab777c6e771980c + languageName: node + linkType: hard + +"chownr@npm:^2.0.0": + version: 2.0.0 + resolution: "chownr@npm:2.0.0" + checksum: c57cf9dd0791e2f18a5ee9c1a299ae6e801ff58fee96dc8bfd0dcb4738a6ce58dd252a3605b1c93c6418fe4f9d5093b28ffbf4d66648cb2a9c67eaef9679be2f + languageName: node + linkType: hard + +"clean-stack@npm:^2.0.0": + version: 2.2.0 + resolution: "clean-stack@npm:2.2.0" + checksum: 2ac8cd2b2f5ec986a3c743935ec85b07bc174d5421a5efc8017e1f146a1cf5f781ae962618f416352103b32c9cd7e203276e8c28241bbe946160cab16149fb68 + languageName: node + linkType: hard + +"cliui@npm:^6.0.0": + version: 6.0.0 + resolution: "cliui@npm:6.0.0" + dependencies: + string-width: ^4.2.0 + strip-ansi: ^6.0.0 + wrap-ansi: ^6.2.0 + checksum: 4fcfd26d292c9f00238117f39fc797608292ae36bac2168cfee4c85923817d0607fe21b3329a8621e01aedf512c99b7eaa60e363a671ffd378df6649fb48ae42 + languageName: node + linkType: hard + +"cliui@npm:^7.0.2": + version: 7.0.4 + resolution: "cliui@npm:7.0.4" + dependencies: + string-width: ^4.2.0 + strip-ansi: ^6.0.0 + wrap-ansi: ^7.0.0 + checksum: ce2e8f578a4813806788ac399b9e866297740eecd4ad1823c27fd344d78b22c5f8597d548adbcc46f0573e43e21e751f39446c5a5e804a12aace402b7a315d7f + languageName: node + linkType: hard + +"color-convert@npm:^1.9.0": + version: 1.9.3 + resolution: "color-convert@npm:1.9.3" + dependencies: + color-name: 1.1.3 + checksum: fd7a64a17cde98fb923b1dd05c5f2e6f7aefda1b60d67e8d449f9328b4e53b228a428fd38bfeaeb2db2ff6b6503a776a996150b80cdf224062af08a5c8a3a203 + languageName: node + linkType: hard + +"color-convert@npm:^2.0.1": + version: 2.0.1 + resolution: "color-convert@npm:2.0.1" + dependencies: + color-name: ~1.1.4 + checksum: 79e6bdb9fd479a205c71d89574fccfb22bd9053bd98c6c4d870d65c132e5e904e6034978e55b43d69fcaa7433af2016ee203ce76eeba9cfa554b373e7f7db336 + languageName: node + linkType: hard + +"color-name@npm:1.1.3": + version: 1.1.3 + resolution: "color-name@npm:1.1.3" + checksum: 09c5d3e33d2105850153b14466501f2bfb30324a2f76568a408763a3b7433b0e50e5b4ab1947868e65cb101bb7cb75029553f2c333b6d4b8138a73fcc133d69d + languageName: node + linkType: hard + +"color-name@npm:~1.1.4": + version: 1.1.4 + resolution: "color-name@npm:1.1.4" + checksum: b0445859521eb4021cd0fb0cc1a75cecf67fceecae89b63f62b201cca8d345baf8b952c966862a9d9a2632987d4f6581f0ec8d957dfacece86f0a7919316f610 + languageName: node + linkType: hard + +"color-support@npm:^1.1.3": + version: 1.1.3 + resolution: "color-support@npm:1.1.3" + bin: + color-support: bin.js + checksum: 9b7356817670b9a13a26ca5af1c21615463b500783b739b7634a0c2047c16cef4b2865d7576875c31c3cddf9dd621fa19285e628f20198b233a5cfdda6d0793b + languageName: node + linkType: hard + +"commondir@npm:^1.0.1": + version: 1.0.1 + resolution: "commondir@npm:1.0.1" + checksum: 59715f2fc456a73f68826285718503340b9f0dd89bfffc42749906c5cf3d4277ef11ef1cca0350d0e79204f00f1f6d83851ececc9095dc88512a697ac0b9bdcb + languageName: node + linkType: hard + +"concat-map@npm:0.0.1": + version: 0.0.1 + resolution: "concat-map@npm:0.0.1" + checksum: 902a9f5d8967a3e2faf138d5cb784b9979bad2e6db5357c5b21c568df4ebe62bcb15108af1b2253744844eb964fc023fbd9afbbbb6ddd0bcc204c6fb5b7bf3af + languageName: node + linkType: hard + +"console-control-strings@npm:^1.1.0": + version: 1.1.0 + resolution: "console-control-strings@npm:1.1.0" + checksum: 8755d76787f94e6cf79ce4666f0c5519906d7f5b02d4b884cf41e11dcd759ed69c57da0670afd9236d229a46e0f9cf519db0cd829c6dca820bb5a5c3def584ed + languageName: node + linkType: hard + +"convert-source-map@npm:^1.7.0": + version: 1.9.0 + resolution: "convert-source-map@npm:1.9.0" + checksum: dc55a1f28ddd0e9485ef13565f8f756b342f9a46c4ae18b843fe3c30c675d058d6a4823eff86d472f187b176f0adf51ea7b69ea38be34be4a63cbbf91b0593c8 + languageName: node + linkType: hard + +"create-require@npm:^1.1.0": + version: 1.1.1 + resolution: "create-require@npm:1.1.1" + checksum: a9a1503d4390d8b59ad86f4607de7870b39cad43d929813599a23714831e81c520bddf61bcdd1f8e30f05fd3a2b71ae8538e946eb2786dc65c2bbc520f692eff + languageName: node + linkType: hard + +"cross-spawn@npm:^7.0.0, cross-spawn@npm:^7.0.2, cross-spawn@npm:^7.0.3": + version: 7.0.3 + resolution: "cross-spawn@npm:7.0.3" + dependencies: + path-key: ^3.1.0 + shebang-command: ^2.0.0 + which: ^2.0.1 + checksum: 671cc7c7288c3a8406f3c69a3ae2fc85555c04169e9d611def9a675635472614f1c0ed0ef80955d5b6d4e724f6ced67f0ad1bb006c2ea643488fcfef994d7f52 + languageName: node + linkType: hard + +"debug@npm:4, debug@npm:^4.1.0, debug@npm:^4.1.1, debug@npm:^4.3.2, debug@npm:^4.3.3, debug@npm:^4.3.4": + version: 4.3.4 + resolution: "debug@npm:4.3.4" + dependencies: + ms: 2.1.2 + peerDependenciesMeta: + supports-color: + optional: true + checksum: 3dbad3f94ea64f34431a9cbf0bafb61853eda57bff2880036153438f50fb5a84f27683ba0d8e5426bf41a8c6ff03879488120cf5b3a761e77953169c0600a708 + languageName: node + linkType: hard + +"debug@npm:4.3.3": + version: 4.3.3 + resolution: "debug@npm:4.3.3" + dependencies: + ms: 2.1.2 + peerDependenciesMeta: + supports-color: + optional: true + checksum: 14472d56fe4a94dbcfaa6dbed2dd3849f1d72ba78104a1a328047bb564643ca49df0224c3a17fa63533fd11dd3d4c8636cd861191232a2c6735af00cc2d4de16 + languageName: node + linkType: hard + +"decamelize@npm:^1.2.0": + version: 1.2.0 + resolution: "decamelize@npm:1.2.0" + checksum: ad8c51a7e7e0720c70ec2eeb1163b66da03e7616d7b98c9ef43cce2416395e84c1e9548dd94f5f6ffecfee9f8b94251fc57121a8b021f2ff2469b2bae247b8aa + languageName: node + linkType: hard + +"decamelize@npm:^4.0.0": + version: 4.0.0 + resolution: "decamelize@npm:4.0.0" + checksum: b7d09b82652c39eead4d6678bb578e3bebd848add894b76d0f6b395bc45b2d692fb88d977e7cfb93c4ed6c119b05a1347cef261174916c2e75c0a8ca57da1809 + languageName: node + linkType: hard + +"deep-is@npm:^0.1.3": + version: 0.1.4 + resolution: "deep-is@npm:0.1.4" + checksum: edb65dd0d7d1b9c40b2f50219aef30e116cedd6fc79290e740972c132c09106d2e80aa0bc8826673dd5a00222d4179c84b36a790eef63a4c4bca75a37ef90804 + languageName: node + linkType: hard + +"default-require-extensions@npm:^3.0.0": + version: 3.0.1 + resolution: "default-require-extensions@npm:3.0.1" + dependencies: + strip-bom: ^4.0.0 + checksum: 45882fc971dd157faf6716ced04c15cf252c0a2d6f5c5844b66ca49f46ed03396a26cd940771aa569927aee22923a961bab789e74b25aabc94d90742c9dd1217 + languageName: node + linkType: hard + +"delegates@npm:^1.0.0": + version: 1.0.0 + resolution: "delegates@npm:1.0.0" + checksum: a51744d9b53c164ba9c0492471a1a2ffa0b6727451bdc89e31627fdf4adda9d51277cfcbfb20f0a6f08ccb3c436f341df3e92631a3440226d93a8971724771fd + languageName: node + linkType: hard + +"depd@npm:^2.0.0": + version: 2.0.0 + resolution: "depd@npm:2.0.0" + checksum: abbe19c768c97ee2eed6282d8ce3031126662252c58d711f646921c9623f9052e3e1906443066beec1095832f534e57c523b7333f8e7e0d93051ab6baef5ab3a + languageName: node + linkType: hard + +"diff@npm:5.0.0": + version: 5.0.0 + resolution: "diff@npm:5.0.0" + checksum: f19fe29284b633afdb2725c2a8bb7d25761ea54d321d8e67987ac851c5294be4afeab532bd84531e02583a3fe7f4014aa314a3eda84f5590e7a9e6b371ef3b46 + languageName: node + linkType: hard + +"diff@npm:^3.5.0": + version: 3.5.0 + resolution: "diff@npm:3.5.0" + checksum: 00842950a6551e26ce495bdbce11047e31667deea546527902661f25cc2e73358967ebc78cf86b1a9736ec3e14286433225f9970678155753a6291c3bca5227b + languageName: node + linkType: hard + +"diff@npm:^4.0.1": + version: 4.0.2 + resolution: "diff@npm:4.0.2" + checksum: f2c09b0ce4e6b301c221addd83bf3f454c0bc00caa3dd837cf6c127d6edf7223aa2bbe3b688feea110b7f262adbfc845b757c44c8a9f8c0c5b15d8fa9ce9d20d + languageName: node + linkType: hard + +"dir-glob@npm:^3.0.1": + version: 3.0.1 + resolution: "dir-glob@npm:3.0.1" + dependencies: + path-type: ^4.0.0 + checksum: fa05e18324510d7283f55862f3161c6759a3f2f8dbce491a2fc14c8324c498286c54282c1f0e933cb930da8419b30679389499b919122952a4f8592362ef4615 + languageName: node + linkType: hard + +"doctrine@npm:^3.0.0": + version: 3.0.0 + resolution: "doctrine@npm:3.0.0" + dependencies: + esutils: ^2.0.2 + checksum: fd7673ca77fe26cd5cba38d816bc72d641f500f1f9b25b83e8ce28827fe2da7ad583a8da26ab6af85f834138cf8dae9f69b0cd6ab925f52ddab1754db44d99ce + languageName: node + linkType: hard + +"eastasianwidth@npm:^0.2.0": + version: 0.2.0 + resolution: "eastasianwidth@npm:0.2.0" + checksum: 7d00d7cd8e49b9afa762a813faac332dee781932d6f2c848dc348939c4253f1d4564341b7af1d041853bc3f32c2ef141b58e0a4d9862c17a7f08f68df1e0f1ed + languageName: node + linkType: hard + +"electron-to-chromium@npm:^1.4.431": + version: 1.4.454 + resolution: "electron-to-chromium@npm:1.4.454" + checksum: 26a756485b442be04a640b8733c3e0d1ad9630541e56906332b1a5f25ec0027647561ec98d0d2a5069a1aae3875c9751c6d1c6cb9ef400b2beabedc36da14ba1 + languageName: node + linkType: hard + +"emoji-regex@npm:^8.0.0": + version: 8.0.0 + resolution: "emoji-regex@npm:8.0.0" + checksum: d4c5c39d5a9868b5fa152f00cada8a936868fd3367f33f71be515ecee4c803132d11b31a6222b2571b1e5f7e13890156a94880345594d0ce7e3c9895f560f192 + languageName: node + linkType: hard + +"emoji-regex@npm:^9.2.2": + version: 9.2.2 + resolution: "emoji-regex@npm:9.2.2" + checksum: 8487182da74aabd810ac6d6f1994111dfc0e331b01271ae01ec1eb0ad7b5ecc2bbbbd2f053c05cb55a1ac30449527d819bbfbf0e3de1023db308cbcb47f86601 + languageName: node + linkType: hard + +"encoding@npm:^0.1.13": + version: 0.1.13 + resolution: "encoding@npm:0.1.13" + dependencies: + iconv-lite: ^0.6.2 + checksum: bb98632f8ffa823996e508ce6a58ffcf5856330fde839ae42c9e1f436cc3b5cc651d4aeae72222916545428e54fd0f6aa8862fd8d25bdbcc4589f1e3f3715e7f + languageName: node + linkType: hard + +"env-paths@npm:^2.2.0": + version: 2.2.1 + resolution: "env-paths@npm:2.2.1" + checksum: 65b5df55a8bab92229ab2b40dad3b387fad24613263d103a97f91c9fe43ceb21965cd3392b1ccb5d77088021e525c4e0481adb309625d0cb94ade1d1fb8dc17e + languageName: node + linkType: hard + +"err-code@npm:^2.0.2": + version: 2.0.3 + resolution: "err-code@npm:2.0.3" + checksum: 8b7b1be20d2de12d2255c0bc2ca638b7af5171142693299416e6a9339bd7d88fc8d7707d913d78e0993176005405a236b066b45666b27b797252c771156ace54 + languageName: node + linkType: hard + +"es6-error@npm:^4.0.1": + version: 4.1.1 + resolution: "es6-error@npm:4.1.1" + checksum: ae41332a51ec1323da6bbc5d75b7803ccdeddfae17c41b6166ebbafc8e8beb7a7b80b884b7fab1cc80df485860ac3c59d78605e860bb4f8cd816b3d6ade0d010 + languageName: node + linkType: hard + +"escalade@npm:^3.1.1": + version: 3.1.1 + resolution: "escalade@npm:3.1.1" + checksum: a3e2a99f07acb74b3ad4989c48ca0c3140f69f923e56d0cba0526240ee470b91010f9d39001f2a4a313841d237ede70a729e92125191ba5d21e74b106800b133 + languageName: node + linkType: hard + +"escape-string-regexp@npm:4.0.0, escape-string-regexp@npm:^4.0.0": + version: 4.0.0 + resolution: "escape-string-regexp@npm:4.0.0" + checksum: 98b48897d93060f2322108bf29db0feba7dd774be96cd069458d1453347b25ce8682ecc39859d4bca2203cc0ab19c237bcc71755eff49a0f8d90beadeeba5cc5 + languageName: node + linkType: hard + +"escape-string-regexp@npm:^1.0.5": + version: 1.0.5 + resolution: "escape-string-regexp@npm:1.0.5" + checksum: 6092fda75c63b110c706b6a9bfde8a612ad595b628f0bd2147eea1d3406723020810e591effc7db1da91d80a71a737a313567c5abb3813e8d9c71f4aa595b410 + languageName: node + linkType: hard + +"eslint-config-prettier@npm:^8.8.0": + version: 8.8.0 + resolution: "eslint-config-prettier@npm:8.8.0" + peerDependencies: + eslint: ">=7.0.0" + bin: + eslint-config-prettier: bin/cli.js + checksum: 1e94c3882c4d5e41e1dcfa2c368dbccbfe3134f6ac7d40101644d3bfbe3eb2f2ffac757f3145910b5eacf20c0e85e02b91293d3126d770cbf3dc390b3564681c + languageName: node + linkType: hard + +"eslint-plugin-no-only-tests@npm:^2.6.0": + version: 2.6.0 + resolution: "eslint-plugin-no-only-tests@npm:2.6.0" + checksum: 4e3c9cc7e09c13e855fd7af4a8969128f766dcf32a0680715ebcaa903c7fe44db8e45e994c8b908443a6019cbd9ea1b51f413bf968a0c58214aded930a863df9 + languageName: node + linkType: hard + +"eslint-scope@npm:^5.1.1": + version: 5.1.1 + resolution: "eslint-scope@npm:5.1.1" + dependencies: + esrecurse: ^4.3.0 + estraverse: ^4.1.1 + checksum: 47e4b6a3f0cc29c7feedee6c67b225a2da7e155802c6ea13bbef4ac6b9e10c66cd2dcb987867ef176292bf4e64eccc680a49e35e9e9c669f4a02bac17e86abdb + languageName: node + linkType: hard + +"eslint-scope@npm:^7.2.0": + version: 7.2.0 + resolution: "eslint-scope@npm:7.2.0" + dependencies: + esrecurse: ^4.3.0 + estraverse: ^5.2.0 + checksum: 64591a2d8b244ade9c690b59ef238a11d5c721a98bcee9e9f445454f442d03d3e04eda88e95a4daec558220a99fa384309d9faae3d459bd40e7a81b4063980ae + languageName: node + linkType: hard + +"eslint-visitor-keys@npm:^3.3.0, eslint-visitor-keys@npm:^3.4.1": + version: 3.4.1 + resolution: "eslint-visitor-keys@npm:3.4.1" + checksum: f05121d868202736b97de7d750847a328fcfa8593b031c95ea89425333db59676ac087fa905eba438d0a3c5769632f828187e0c1a0d271832a2153c1d3661c2c + languageName: node + linkType: hard + +"eslint@npm:^8.44.0": + version: 8.44.0 + resolution: "eslint@npm:8.44.0" + dependencies: + "@eslint-community/eslint-utils": ^4.2.0 + "@eslint-community/regexpp": ^4.4.0 + "@eslint/eslintrc": ^2.1.0 + "@eslint/js": 8.44.0 + "@humanwhocodes/config-array": ^0.11.10 + "@humanwhocodes/module-importer": ^1.0.1 + "@nodelib/fs.walk": ^1.2.8 + ajv: ^6.10.0 + chalk: ^4.0.0 + cross-spawn: ^7.0.2 + debug: ^4.3.2 + doctrine: ^3.0.0 + escape-string-regexp: ^4.0.0 + eslint-scope: ^7.2.0 + eslint-visitor-keys: ^3.4.1 + espree: ^9.6.0 + esquery: ^1.4.2 + esutils: ^2.0.2 + fast-deep-equal: ^3.1.3 + file-entry-cache: ^6.0.1 + find-up: ^5.0.0 + glob-parent: ^6.0.2 + globals: ^13.19.0 + graphemer: ^1.4.0 + ignore: ^5.2.0 + import-fresh: ^3.0.0 + imurmurhash: ^0.1.4 + is-glob: ^4.0.0 + is-path-inside: ^3.0.3 + js-yaml: ^4.1.0 + json-stable-stringify-without-jsonify: ^1.0.1 + levn: ^0.4.1 + lodash.merge: ^4.6.2 + minimatch: ^3.1.2 + natural-compare: ^1.4.0 + optionator: ^0.9.3 + strip-ansi: ^6.0.1 + strip-json-comments: ^3.1.0 + text-table: ^0.2.0 + bin: + eslint: bin/eslint.js + checksum: d06309ce4aafb9d27d558c8e5e5aa5cba3bbec3ce8ceccbc7d4b7a35f2b67fd40189159155553270e2e6febeb69bd8a3b60d6241c8f5ddc2ef1702ccbd328501 + languageName: node + linkType: hard + +"espree@npm:^9.6.0": + version: 9.6.0 + resolution: "espree@npm:9.6.0" + dependencies: + acorn: ^8.9.0 + acorn-jsx: ^5.3.2 + eslint-visitor-keys: ^3.4.1 + checksum: 1287979510efb052a6a97c73067ea5d0a40701b29adde87bbe2d3eb1667e39ca55e8129e20e2517fed3da570150e7ef470585228459a8f3e3755f45007a1c662 + languageName: node + linkType: hard + +"esprima@npm:^4.0.0": + version: 4.0.1 + resolution: "esprima@npm:4.0.1" + bin: + esparse: ./bin/esparse.js + esvalidate: ./bin/esvalidate.js + checksum: b45bc805a613dbea2835278c306b91aff6173c8d034223fa81498c77dcbce3b2931bf6006db816f62eacd9fd4ea975dfd85a5b7f3c6402cfd050d4ca3c13a628 + languageName: node + linkType: hard + +"esquery@npm:^1.4.2": + version: 1.5.0 + resolution: "esquery@npm:1.5.0" + dependencies: + estraverse: ^5.1.0 + checksum: aefb0d2596c230118656cd4ec7532d447333a410a48834d80ea648b1e7b5c9bc9ed8b5e33a89cb04e487b60d622f44cf5713bf4abed7c97343edefdc84a35900 + languageName: node + linkType: hard + +"esrecurse@npm:^4.3.0": + version: 4.3.0 + resolution: "esrecurse@npm:4.3.0" + dependencies: + estraverse: ^5.2.0 + checksum: ebc17b1a33c51cef46fdc28b958994b1dc43cd2e86237515cbc3b4e5d2be6a811b2315d0a1a4d9d340b6d2308b15322f5c8291059521cc5f4802f65e7ec32837 + languageName: node + linkType: hard + +"estraverse@npm:^4.1.1": + version: 4.3.0 + resolution: "estraverse@npm:4.3.0" + checksum: a6299491f9940bb246124a8d44b7b7a413a8336f5436f9837aaa9330209bd9ee8af7e91a654a3545aee9c54b3308e78ee360cef1d777d37cfef77d2fa33b5827 + languageName: node + linkType: hard + +"estraverse@npm:^5.1.0, estraverse@npm:^5.2.0": + version: 5.3.0 + resolution: "estraverse@npm:5.3.0" + checksum: 072780882dc8416ad144f8fe199628d2b3e7bbc9989d9ed43795d2c90309a2047e6bc5979d7e2322a341163d22cfad9e21f4110597fe487519697389497e4e2b + languageName: node + linkType: hard + +"esutils@npm:^2.0.2": + version: 2.0.3 + resolution: "esutils@npm:2.0.3" + checksum: 22b5b08f74737379a840b8ed2036a5fb35826c709ab000683b092d9054e5c2a82c27818f12604bfc2a9a76b90b6834ef081edbc1c7ae30d1627012e067c6ec87 + languageName: node + linkType: hard + +"exponential-backoff@npm:^3.1.1": + version: 3.1.1 + resolution: "exponential-backoff@npm:3.1.1" + checksum: 3d21519a4f8207c99f7457287291316306255a328770d320b401114ec8481986e4e467e854cb9914dd965e0a1ca810a23ccb559c642c88f4c7f55c55778a9b48 + languageName: node + linkType: hard + +"fast-deep-equal@npm:^3.1.1, fast-deep-equal@npm:^3.1.3": + version: 3.1.3 + resolution: "fast-deep-equal@npm:3.1.3" + checksum: e21a9d8d84f53493b6aa15efc9cfd53dd5b714a1f23f67fb5dc8f574af80df889b3bce25dc081887c6d25457cce704e636395333abad896ccdec03abaf1f3f9d + languageName: node + linkType: hard + +"fast-glob@npm:^3.2.9": + version: 3.3.0 + resolution: "fast-glob@npm:3.3.0" + dependencies: + "@nodelib/fs.stat": ^2.0.2 + "@nodelib/fs.walk": ^1.2.3 + glob-parent: ^5.1.2 + merge2: ^1.3.0 + micromatch: ^4.0.4 + checksum: 20df62be28eb5426fe8e40e0d05601a63b1daceb7c3d87534afcad91bdcf1e4b1743cf2d5247d6e225b120b46df0b9053a032b2691ba34ee121e033acd81f547 + languageName: node + linkType: hard + +"fast-json-stable-stringify@npm:^2.0.0": + version: 2.1.0 + resolution: "fast-json-stable-stringify@npm:2.1.0" + checksum: b191531e36c607977e5b1c47811158733c34ccb3bfde92c44798929e9b4154884378536d26ad90dfecd32e1ffc09c545d23535ad91b3161a27ddbb8ebe0cbecb + languageName: node + linkType: hard + +"fast-levenshtein@npm:^2.0.6": + version: 2.0.6 + resolution: "fast-levenshtein@npm:2.0.6" + checksum: 92cfec0a8dfafd9c7a15fba8f2cc29cd0b62b85f056d99ce448bbcd9f708e18ab2764bda4dd5158364f4145a7c72788538994f0d1787b956ef0d1062b0f7c24c + languageName: node + linkType: hard + +"fastq@npm:^1.6.0": + version: 1.15.0 + resolution: "fastq@npm:1.15.0" + dependencies: + reusify: ^1.0.4 + checksum: 0170e6bfcd5d57a70412440b8ef600da6de3b2a6c5966aeaf0a852d542daff506a0ee92d6de7679d1de82e644bce69d7a574a6c93f0b03964b5337eed75ada1a + languageName: node + linkType: hard + +"file-entry-cache@npm:^6.0.1": + version: 6.0.1 + resolution: "file-entry-cache@npm:6.0.1" + dependencies: + flat-cache: ^3.0.4 + checksum: f49701feaa6314c8127c3c2f6173cfefff17612f5ed2daaafc6da13b5c91fd43e3b2a58fd0d63f9f94478a501b167615931e7200e31485e320f74a33885a9c74 + languageName: node + linkType: hard + +"fill-range@npm:^7.0.1": + version: 7.0.1 + resolution: "fill-range@npm:7.0.1" + dependencies: + to-regex-range: ^5.0.1 + checksum: cc283f4e65b504259e64fd969bcf4def4eb08d85565e906b7d36516e87819db52029a76b6363d0f02d0d532f0033c9603b9e2d943d56ee3b0d4f7ad3328ff917 + languageName: node + linkType: hard + +"find-cache-dir@npm:^3.2.0": + version: 3.3.2 + resolution: "find-cache-dir@npm:3.3.2" + dependencies: + commondir: ^1.0.1 + make-dir: ^3.0.2 + pkg-dir: ^4.1.0 + checksum: 1e61c2e64f5c0b1c535bd85939ae73b0e5773142713273818cc0b393ee3555fb0fd44e1a5b161b8b6c3e03e98c2fcc9c227d784850a13a90a8ab576869576817 + languageName: node + linkType: hard + +"find-up@npm:5.0.0, find-up@npm:^5.0.0": + version: 5.0.0 + resolution: "find-up@npm:5.0.0" + dependencies: + locate-path: ^6.0.0 + path-exists: ^4.0.0 + checksum: 07955e357348f34660bde7920783204ff5a26ac2cafcaa28bace494027158a97b9f56faaf2d89a6106211a8174db650dd9f503f9c0d526b1202d5554a00b9095 + languageName: node + linkType: hard + +"find-up@npm:^4.0.0, find-up@npm:^4.1.0": + version: 4.1.0 + resolution: "find-up@npm:4.1.0" + dependencies: + locate-path: ^5.0.0 + path-exists: ^4.0.0 + checksum: 4c172680e8f8c1f78839486e14a43ef82e9decd0e74145f40707cc42e7420506d5ec92d9a11c22bd2c48fb0c384ea05dd30e10dd152fefeec6f2f75282a8b844 + languageName: node + linkType: hard + +"flat-cache@npm:^3.0.4": + version: 3.0.4 + resolution: "flat-cache@npm:3.0.4" + dependencies: + flatted: ^3.1.0 + rimraf: ^3.0.2 + checksum: 4fdd10ecbcbf7d520f9040dd1340eb5dfe951e6f0ecf2252edeec03ee68d989ec8b9a20f4434270e71bcfd57800dc09b3344fca3966b2eb8f613072c7d9a2365 + languageName: node + linkType: hard + +"flat@npm:^5.0.2": + version: 5.0.2 + resolution: "flat@npm:5.0.2" + bin: + flat: cli.js + checksum: 12a1536ac746db74881316a181499a78ef953632ddd28050b7a3a43c62ef5462e3357c8c29d76072bb635f147f7a9a1f0c02efef6b4be28f8db62ceb3d5c7f5d + languageName: node + linkType: hard + +"flatted@npm:^3.1.0": + version: 3.2.7 + resolution: "flatted@npm:3.2.7" + checksum: 427633049d55bdb80201c68f7eb1cbd533e03eac541f97d3aecab8c5526f12a20ccecaeede08b57503e772c769e7f8680b37e8d482d1e5f8d7e2194687f9ea35 + languageName: node + linkType: hard + +"follow-redirects@npm:^1.14.4": + version: 1.15.2 + resolution: "follow-redirects@npm:1.15.2" + peerDependenciesMeta: + debug: + optional: true + checksum: faa66059b66358ba65c234c2f2a37fcec029dc22775f35d9ad6abac56003268baf41e55f9ee645957b32c7d9f62baf1f0b906e68267276f54ec4b4c597c2b190 + languageName: node + linkType: hard + +"foreground-child@npm:^2.0.0": + version: 2.0.0 + resolution: "foreground-child@npm:2.0.0" + dependencies: + cross-spawn: ^7.0.0 + signal-exit: ^3.0.2 + checksum: f77ec9aff621abd6b754cb59e690743e7639328301fbea6ff09df27d2befaf7dd5b77cec51c32323d73a81a7d91caaf9413990d305cbe3d873eec4fe58960956 + languageName: node + linkType: hard + +"foreground-child@npm:^3.1.0": + version: 3.1.1 + resolution: "foreground-child@npm:3.1.1" + dependencies: + cross-spawn: ^7.0.0 + signal-exit: ^4.0.1 + checksum: 139d270bc82dc9e6f8bc045fe2aae4001dc2472157044fdfad376d0a3457f77857fa883c1c8b21b491c6caade9a926a4bed3d3d2e8d3c9202b151a4cbbd0bcd5 + languageName: node + linkType: hard + +"fromentries@npm:^1.2.0": + version: 1.3.2 + resolution: "fromentries@npm:1.3.2" + checksum: 33729c529ce19f5494f846f0dd4945078f4e37f4e8955f4ae8cc7385c218f600e9d93a7d225d17636c20d1889106fd87061f911550861b7072f53bf891e6b341 + languageName: node + linkType: hard + +"fs-minipass@npm:^2.0.0": + version: 2.1.0 + resolution: "fs-minipass@npm:2.1.0" + dependencies: + minipass: ^3.0.0 + checksum: 1b8d128dae2ac6cc94230cc5ead341ba3e0efaef82dab46a33d171c044caaa6ca001364178d42069b2809c35a1c3c35079a32107c770e9ffab3901b59af8c8b1 + languageName: node + linkType: hard + +"fs-minipass@npm:^3.0.0": + version: 3.0.2 + resolution: "fs-minipass@npm:3.0.2" + dependencies: + minipass: ^5.0.0 + checksum: e9cc0e1f2d01c6f6f62f567aee59530aba65c6c7b2ae88c5027bc34c711ebcfcfaefd0caf254afa6adfe7d1fba16bc2537508a6235196bac7276747d078aef0a + languageName: node + linkType: hard + +"fs.realpath@npm:^1.0.0": + version: 1.0.0 + resolution: "fs.realpath@npm:1.0.0" + checksum: 99ddea01a7e75aa276c250a04eedeffe5662bce66c65c07164ad6264f9de18fb21be9433ead460e54cff20e31721c811f4fb5d70591799df5f85dce6d6746fd0 + languageName: node + linkType: hard + +"fsevents@npm:~2.3.2": + version: 2.3.2 + resolution: "fsevents@npm:2.3.2" + dependencies: + node-gyp: latest + checksum: 97ade64e75091afee5265e6956cb72ba34db7819b4c3e94c431d4be2b19b8bb7a2d4116da417950c3425f17c8fe693d25e20212cac583ac1521ad066b77ae31f + conditions: os=darwin + languageName: node + linkType: hard + +"fsevents@patch:fsevents@~2.3.2#~builtin": + version: 2.3.2 + resolution: "fsevents@patch:fsevents@npm%3A2.3.2#~builtin::version=2.3.2&hash=18f3a7" + dependencies: + node-gyp: latest + conditions: os=darwin + languageName: node + linkType: hard + +"gauge@npm:^4.0.3": + version: 4.0.4 + resolution: "gauge@npm:4.0.4" + dependencies: + aproba: ^1.0.3 || ^2.0.0 + color-support: ^1.1.3 + console-control-strings: ^1.1.0 + has-unicode: ^2.0.1 + signal-exit: ^3.0.7 + string-width: ^4.2.3 + strip-ansi: ^6.0.1 + wide-align: ^1.1.5 + checksum: 788b6bfe52f1dd8e263cda800c26ac0ca2ff6de0b6eee2fe0d9e3abf15e149b651bd27bf5226be10e6e3edb5c4e5d5985a5a1a98137e7a892f75eff76467ad2d + languageName: node + linkType: hard + +"gensync@npm:^1.0.0-beta.2": + version: 1.0.0-beta.2 + resolution: "gensync@npm:1.0.0-beta.2" + checksum: a7437e58c6be12aa6c90f7730eac7fa9833dc78872b4ad2963d2031b00a3367a93f98aec75f9aaac7220848e4026d67a8655e870b24f20a543d103c0d65952ec + languageName: node + linkType: hard + +"get-caller-file@npm:^2.0.1, get-caller-file@npm:^2.0.5": + version: 2.0.5 + resolution: "get-caller-file@npm:2.0.5" + checksum: b9769a836d2a98c3ee734a88ba712e62703f1df31b94b784762c433c27a386dd6029ff55c2a920c392e33657d80191edbf18c61487e198844844516f843496b9 + languageName: node + linkType: hard + +"get-package-type@npm:^0.1.0": + version: 0.1.0 + resolution: "get-package-type@npm:0.1.0" + checksum: bba0811116d11e56d702682ddef7c73ba3481f114590e705fc549f4d868972263896af313c57a25c076e3c0d567e11d919a64ba1b30c879be985fc9d44f96148 + languageName: node + linkType: hard + +"glob-parent@npm:^5.1.2, glob-parent@npm:~5.1.2": + version: 5.1.2 + resolution: "glob-parent@npm:5.1.2" + dependencies: + is-glob: ^4.0.1 + checksum: f4f2bfe2425296e8a47e36864e4f42be38a996db40420fe434565e4480e3322f18eb37589617a98640c5dc8fdec1a387007ee18dbb1f3f5553409c34d17f425e + languageName: node + linkType: hard + +"glob-parent@npm:^6.0.2": + version: 6.0.2 + resolution: "glob-parent@npm:6.0.2" + dependencies: + is-glob: ^4.0.3 + checksum: c13ee97978bef4f55106b71e66428eb1512e71a7466ba49025fc2aec59a5bfb0954d5abd58fc5ee6c9b076eef4e1f6d3375c2e964b88466ca390da4419a786a8 + languageName: node + linkType: hard + +"glob@npm:7.2.0": + version: 7.2.0 + resolution: "glob@npm:7.2.0" + dependencies: + fs.realpath: ^1.0.0 + inflight: ^1.0.4 + inherits: 2 + minimatch: ^3.0.4 + once: ^1.3.0 + path-is-absolute: ^1.0.0 + checksum: 78a8ea942331f08ed2e055cb5b9e40fe6f46f579d7fd3d694f3412fe5db23223d29b7fee1575440202e9a7ff9a72ab106a39fee39934c7bedafe5e5f8ae20134 + languageName: node + linkType: hard + +"glob@npm:^10.2.2": + version: 10.3.3 + resolution: "glob@npm:10.3.3" + dependencies: + foreground-child: ^3.1.0 + jackspeak: ^2.0.3 + minimatch: ^9.0.1 + minipass: ^5.0.0 || ^6.0.2 || ^7.0.0 + path-scurry: ^1.10.1 + bin: + glob: dist/cjs/src/bin.js + checksum: 29190d3291f422da0cb40b77a72fc8d2c51a36524e99b8bf412548b7676a6627489528b57250429612b6eec2e6fe7826d328451d3e694a9d15e575389308ec53 + languageName: node + linkType: hard + +"glob@npm:^7.1.3, glob@npm:^7.1.4, glob@npm:^7.1.6": + version: 7.2.3 + resolution: "glob@npm:7.2.3" + dependencies: + fs.realpath: ^1.0.0 + inflight: ^1.0.4 + inherits: 2 + minimatch: ^3.1.1 + once: ^1.3.0 + path-is-absolute: ^1.0.0 + checksum: 29452e97b38fa704dabb1d1045350fb2467cf0277e155aa9ff7077e90ad81d1ea9d53d3ee63bd37c05b09a065e90f16aec4a65f5b8de401d1dac40bc5605d133 + languageName: node + linkType: hard + +"globals@npm:^11.1.0": + version: 11.12.0 + resolution: "globals@npm:11.12.0" + checksum: 67051a45eca3db904aee189dfc7cd53c20c7d881679c93f6146ddd4c9f4ab2268e68a919df740d39c71f4445d2b38ee360fc234428baea1dbdfe68bbcb46979e + languageName: node + linkType: hard + +"globals@npm:^13.19.0": + version: 13.20.0 + resolution: "globals@npm:13.20.0" + dependencies: + type-fest: ^0.20.2 + checksum: ad1ecf914bd051325faad281d02ea2c0b1df5d01bd94d368dcc5513340eac41d14b3c61af325768e3c7f8d44576e72780ec0b6f2d366121f8eec6e03c3a3b97a + languageName: node + linkType: hard + +"globby@npm:^11.1.0": + version: 11.1.0 + resolution: "globby@npm:11.1.0" + dependencies: + array-union: ^2.1.0 + dir-glob: ^3.0.1 + fast-glob: ^3.2.9 + ignore: ^5.2.0 + merge2: ^1.4.1 + slash: ^3.0.0 + checksum: b4be8885e0cfa018fc783792942d53926c35c50b3aefd3fdcfb9d22c627639dc26bd2327a40a0b74b074100ce95bb7187bfeae2f236856aa3de183af7a02aea6 + languageName: node + linkType: hard + +"graceful-fs@npm:^4.1.15, graceful-fs@npm:^4.2.6": + version: 4.2.11 + resolution: "graceful-fs@npm:4.2.11" + checksum: ac85f94da92d8eb6b7f5a8b20ce65e43d66761c55ce85ac96df6865308390da45a8d3f0296dd3a663de65d30ba497bd46c696cc1e248c72b13d6d567138a4fc7 + languageName: node + linkType: hard + +"graphemer@npm:^1.4.0": + version: 1.4.0 + resolution: "graphemer@npm:1.4.0" + checksum: bab8f0be9b568857c7bec9fda95a89f87b783546d02951c40c33f84d05bb7da3fd10f863a9beb901463669b6583173a8c8cc6d6b306ea2b9b9d5d3d943c3a673 + languageName: node + linkType: hard + +"growl@npm:1.10.5": + version: 1.10.5 + resolution: "growl@npm:1.10.5" + checksum: 4b86685de6831cebcbb19f93870bea624afee61124b0a20c49017013987cd129e73a8c4baeca295728f41d21265e1f859d25ef36731b142ca59c655fea94bb1a + languageName: node + linkType: hard + +"has-flag@npm:^3.0.0": + version: 3.0.0 + resolution: "has-flag@npm:3.0.0" + checksum: 4a15638b454bf086c8148979aae044dd6e39d63904cd452d970374fa6a87623423da485dfb814e7be882e05c096a7ccf1ebd48e7e7501d0208d8384ff4dea73b + languageName: node + linkType: hard + +"has-flag@npm:^4.0.0": + version: 4.0.0 + resolution: "has-flag@npm:4.0.0" + checksum: 261a1357037ead75e338156b1f9452c016a37dcd3283a972a30d9e4a87441ba372c8b81f818cd0fbcd9c0354b4ae7e18b9e1afa1971164aef6d18c2b6095a8ad + languageName: node + linkType: hard + +"has-unicode@npm:^2.0.1": + version: 2.0.1 + resolution: "has-unicode@npm:2.0.1" + checksum: 1eab07a7436512db0be40a710b29b5dc21fa04880b7f63c9980b706683127e3c1b57cb80ea96d47991bdae2dfe479604f6a1ba410106ee1046a41d1bd0814400 + languageName: node + linkType: hard + +"hasha@npm:^5.0.0": + version: 5.2.2 + resolution: "hasha@npm:5.2.2" + dependencies: + is-stream: ^2.0.0 + type-fest: ^0.8.0 + checksum: 06cc474bed246761ff61c19d629977eb5f53fa817be4313a255a64ae0f433e831a29e83acb6555e3f4592b348497596f1d1653751008dda4f21c9c21ca60ac5a + languageName: node + linkType: hard + +"he@npm:1.2.0": + version: 1.2.0 + resolution: "he@npm:1.2.0" + bin: + he: bin/he + checksum: 3d4d6babccccd79c5c5a3f929a68af33360d6445587d628087f39a965079d84f18ce9c3d3f917ee1e3978916fc833bb8b29377c3b403f919426f91bc6965e7a7 + languageName: node + linkType: hard + +"html-escaper@npm:^2.0.0": + version: 2.0.2 + resolution: "html-escaper@npm:2.0.2" + checksum: d2df2da3ad40ca9ee3a39c5cc6475ef67c8f83c234475f24d8e9ce0dc80a2c82df8e1d6fa78ddd1e9022a586ea1bd247a615e80a5cd9273d90111ddda7d9e974 + languageName: node + linkType: hard + +"htmlencode@npm:^0.0.4": + version: 0.0.4 + resolution: "htmlencode@npm:0.0.4" + checksum: b5c5a280213569f59807d22ae2d68c77360f6337b6936cdfa4e2aeaa12e3a69bb36b426ad18ed9333a7fb3f7d55c14ea3b46040d3271af7a586f262aaf4092ad + languageName: node + linkType: hard + +"http-cache-semantics@npm:^4.1.1": + version: 4.1.1 + resolution: "http-cache-semantics@npm:4.1.1" + checksum: 83ac0bc60b17a3a36f9953e7be55e5c8f41acc61b22583060e8dedc9dd5e3607c823a88d0926f9150e571f90946835c7fe150732801010845c72cd8bbff1a236 + languageName: node + linkType: hard + +"http-proxy-agent@npm:^5.0.0": + version: 5.0.0 + resolution: "http-proxy-agent@npm:5.0.0" + dependencies: + "@tootallnate/once": 2 + agent-base: 6 + debug: 4 + checksum: e2ee1ff1656a131953839b2a19cd1f3a52d97c25ba87bd2559af6ae87114abf60971e498021f9b73f9fd78aea8876d1fb0d4656aac8a03c6caa9fc175f22b786 + languageName: node + linkType: hard + +"https-proxy-agent@npm:^5.0.0": + version: 5.0.1 + resolution: "https-proxy-agent@npm:5.0.1" + dependencies: + agent-base: 6 + debug: 4 + checksum: 571fccdf38184f05943e12d37d6ce38197becdd69e58d03f43637f7fa1269cf303a7d228aa27e5b27bbd3af8f09fd938e1c91dcfefff2df7ba77c20ed8dfc765 + languageName: node + linkType: hard + +"humanize-ms@npm:^1.2.1": + version: 1.2.1 + resolution: "humanize-ms@npm:1.2.1" + dependencies: + ms: ^2.0.0 + checksum: 9c7a74a2827f9294c009266c82031030eae811ca87b0da3dceb8d6071b9bde22c9f3daef0469c3c533cc67a97d8a167cd9fc0389350e5f415f61a79b171ded16 + languageName: node + linkType: hard + +"iconv-lite@npm:^0.6.2": + version: 0.6.3 + resolution: "iconv-lite@npm:0.6.3" + dependencies: + safer-buffer: ">= 2.1.2 < 3.0.0" + checksum: 3f60d47a5c8fc3313317edfd29a00a692cc87a19cac0159e2ce711d0ebc9019064108323b5e493625e25594f11c6236647d8e256fbe7a58f4a3b33b89e6d30bf + languageName: node + linkType: hard + +"ignore@npm:^5.2.0": + version: 5.2.4 + resolution: "ignore@npm:5.2.4" + checksum: 3d4c309c6006e2621659311783eaea7ebcd41fe4ca1d78c91c473157ad6666a57a2df790fe0d07a12300d9aac2888204d7be8d59f9aaf665b1c7fcdb432517ef + languageName: node + linkType: hard + +"import-fresh@npm:^3.0.0, import-fresh@npm:^3.2.1": + version: 3.3.0 + resolution: "import-fresh@npm:3.3.0" + dependencies: + parent-module: ^1.0.0 + resolve-from: ^4.0.0 + checksum: 2cacfad06e652b1edc50be650f7ec3be08c5e5a6f6d12d035c440a42a8cc028e60a5b99ca08a77ab4d6b1346da7d971915828f33cdab730d3d42f08242d09baa + languageName: node + linkType: hard + +"imurmurhash@npm:^0.1.4": + version: 0.1.4 + resolution: "imurmurhash@npm:0.1.4" + checksum: 7cae75c8cd9a50f57dadd77482359f659eaebac0319dd9368bcd1714f55e65badd6929ca58569da2b6494ef13fdd5598cd700b1eba23f8b79c5f19d195a3ecf7 + languageName: node + linkType: hard + +"indent-string@npm:^4.0.0": + version: 4.0.0 + resolution: "indent-string@npm:4.0.0" + checksum: 824cfb9929d031dabf059bebfe08cf3137365e112019086ed3dcff6a0a7b698cb80cf67ccccde0e25b9e2d7527aa6cc1fed1ac490c752162496caba3e6699612 + languageName: node + linkType: hard + +"inflight@npm:^1.0.4": + version: 1.0.6 + resolution: "inflight@npm:1.0.6" + dependencies: + once: ^1.3.0 + wrappy: 1 + checksum: f4f76aa072ce19fae87ce1ef7d221e709afb59d445e05d47fba710e85470923a75de35bfae47da6de1b18afc3ce83d70facf44cfb0aff89f0a3f45c0a0244dfd + languageName: node + linkType: hard + +"inherits@npm:2, inherits@npm:^2.0.3": + version: 2.0.4 + resolution: "inherits@npm:2.0.4" + checksum: 4a48a733847879d6cf6691860a6b1e3f0f4754176e4d71494c41f3475553768b10f84b5ce1d40fbd0e34e6bfbb864ee35858ad4dd2cf31e02fc4a154b724d7f1 + languageName: node + linkType: hard + +"intercom-client@workspace:.": + version: 0.0.0-use.local + resolution: "intercom-client@workspace:." + dependencies: + "@istanbuljs/nyc-config-typescript": ^1.0.2 + "@types/lodash": ^4.14.195 + "@types/mocha": ^9.1.1 + "@types/node": ^16.18.38 + "@types/sinon": ^10.0.15 + "@typescript-eslint/eslint-plugin": ^5.61.0 + "@typescript-eslint/parser": ^5.61.0 + axios: ^0.24.0 + eslint: ^8.44.0 + eslint-config-prettier: ^8.8.0 + eslint-plugin-no-only-tests: ^2.6.0 + htmlencode: ^0.0.4 + lodash: ^4.17.21 + merge2: ^1.4.1 + mocha: ^9.2.2 + nock: ^13.3.1 + nyc: ^15.1.0 + prettier: ^2.8.8 + sinon: ^7.5.0 + ts-node: ^10.9.1 + tslib: ^2.6.0 + typescript: ^4.9.5 + languageName: unknown + linkType: soft + +"ip@npm:^2.0.0": + version: 2.0.0 + resolution: "ip@npm:2.0.0" + checksum: cfcfac6b873b701996d71ec82a7dd27ba92450afdb421e356f44044ed688df04567344c36cbacea7d01b1c39a4c732dc012570ebe9bebfb06f27314bca625349 + languageName: node + linkType: hard + +"is-binary-path@npm:~2.1.0": + version: 2.1.0 + resolution: "is-binary-path@npm:2.1.0" + dependencies: + binary-extensions: ^2.0.0 + checksum: 84192eb88cff70d320426f35ecd63c3d6d495da9d805b19bc65b518984b7c0760280e57dbf119b7e9be6b161784a5a673ab2c6abe83abb5198a432232ad5b35c + languageName: node + linkType: hard + +"is-extglob@npm:^2.1.1": + version: 2.1.1 + resolution: "is-extglob@npm:2.1.1" + checksum: df033653d06d0eb567461e58a7a8c9f940bd8c22274b94bf7671ab36df5719791aae15eef6d83bbb5e23283967f2f984b8914559d4449efda578c775c4be6f85 + languageName: node + linkType: hard + +"is-fullwidth-code-point@npm:^3.0.0": + version: 3.0.0 + resolution: "is-fullwidth-code-point@npm:3.0.0" + checksum: 44a30c29457c7fb8f00297bce733f0a64cd22eca270f83e58c105e0d015e45c019491a4ab2faef91ab51d4738c670daff901c799f6a700e27f7314029e99e348 + languageName: node + linkType: hard + +"is-glob@npm:^4.0.0, is-glob@npm:^4.0.1, is-glob@npm:^4.0.3, is-glob@npm:~4.0.1": + version: 4.0.3 + resolution: "is-glob@npm:4.0.3" + dependencies: + is-extglob: ^2.1.1 + checksum: d381c1319fcb69d341cc6e6c7cd588e17cd94722d9a32dbd60660b993c4fb7d0f19438674e68dfec686d09b7c73139c9166b47597f846af387450224a8101ab4 + languageName: node + linkType: hard + +"is-lambda@npm:^1.0.1": + version: 1.0.1 + resolution: "is-lambda@npm:1.0.1" + checksum: 93a32f01940220532e5948538699ad610d5924ac86093fcee83022252b363eb0cc99ba53ab084a04e4fb62bf7b5731f55496257a4c38adf87af9c4d352c71c35 + languageName: node + linkType: hard + +"is-number@npm:^7.0.0": + version: 7.0.0 + resolution: "is-number@npm:7.0.0" + checksum: 456ac6f8e0f3111ed34668a624e45315201dff921e5ac181f8ec24923b99e9f32ca1a194912dc79d539c97d33dba17dc635202ff0b2cf98326f608323276d27a + languageName: node + linkType: hard + +"is-path-inside@npm:^3.0.3": + version: 3.0.3 + resolution: "is-path-inside@npm:3.0.3" + checksum: abd50f06186a052b349c15e55b182326f1936c89a78bf6c8f2b707412517c097ce04bc49a0ca221787bc44e1049f51f09a2ffb63d22899051988d3a618ba13e9 + languageName: node + linkType: hard + +"is-plain-obj@npm:^2.1.0": + version: 2.1.0 + resolution: "is-plain-obj@npm:2.1.0" + checksum: cec9100678b0a9fe0248a81743041ed990c2d4c99f893d935545cfbc42876cbe86d207f3b895700c690ad2fa520e568c44afc1605044b535a7820c1d40e38daa + languageName: node + linkType: hard + +"is-stream@npm:^2.0.0": + version: 2.0.1 + resolution: "is-stream@npm:2.0.1" + checksum: b8e05ccdf96ac330ea83c12450304d4a591f9958c11fd17bed240af8d5ffe08aedafa4c0f4cfccd4d28dc9d4d129daca1023633d5c11601a6cbc77521f6fae66 + languageName: node + linkType: hard + +"is-typedarray@npm:^1.0.0": + version: 1.0.0 + resolution: "is-typedarray@npm:1.0.0" + checksum: 3508c6cd0a9ee2e0df2fa2e9baabcdc89e911c7bd5cf64604586697212feec525aa21050e48affb5ffc3df20f0f5d2e2cf79b08caa64e1ccc9578e251763aef7 + languageName: node + linkType: hard + +"is-unicode-supported@npm:^0.1.0": + version: 0.1.0 + resolution: "is-unicode-supported@npm:0.1.0" + checksum: a2aab86ee7712f5c2f999180daaba5f361bdad1efadc9610ff5b8ab5495b86e4f627839d085c6530363c6d6d4ecbde340fb8e54bdb83da4ba8e0865ed5513c52 + languageName: node + linkType: hard + +"is-windows@npm:^1.0.2": + version: 1.0.2 + resolution: "is-windows@npm:1.0.2" + checksum: 438b7e52656fe3b9b293b180defb4e448088e7023a523ec21a91a80b9ff8cdb3377ddb5b6e60f7c7de4fa8b63ab56e121b6705fe081b3cf1b828b0a380009ad7 + languageName: node + linkType: hard + +"isarray@npm:0.0.1": + version: 0.0.1 + resolution: "isarray@npm:0.0.1" + checksum: 49191f1425681df4a18c2f0f93db3adb85573bcdd6a4482539d98eac9e705d8961317b01175627e860516a2fc45f8f9302db26e5a380a97a520e272e2a40a8d4 + languageName: node + linkType: hard + +"isexe@npm:^2.0.0": + version: 2.0.0 + resolution: "isexe@npm:2.0.0" + checksum: 26bf6c5480dda5161c820c5b5c751ae1e766c587b1f951ea3fcfc973bafb7831ae5b54a31a69bd670220e42e99ec154475025a468eae58ea262f813fdc8d1c62 + languageName: node + linkType: hard + +"istanbul-lib-coverage@npm:^3.0.0, istanbul-lib-coverage@npm:^3.2.0": + version: 3.2.0 + resolution: "istanbul-lib-coverage@npm:3.2.0" + checksum: a2a545033b9d56da04a8571ed05c8120bf10e9bce01cf8633a3a2b0d1d83dff4ac4fe78d6d5673c27fc29b7f21a41d75f83a36be09f82a61c367b56aa73c1ff9 + languageName: node + linkType: hard + +"istanbul-lib-hook@npm:^3.0.0": + version: 3.0.0 + resolution: "istanbul-lib-hook@npm:3.0.0" + dependencies: + append-transform: ^2.0.0 + checksum: ac4d0a0751e959cfe4c95d817df5f1f573f9b0cf892552e60d81785654291391fac1ceb667f13bb17fcc2ef23b74c89ed8cf1c6148c833c8596a2b920b079101 + languageName: node + linkType: hard + +"istanbul-lib-instrument@npm:^4.0.0": + version: 4.0.3 + resolution: "istanbul-lib-instrument@npm:4.0.3" + dependencies: + "@babel/core": ^7.7.5 + "@istanbuljs/schema": ^0.1.2 + istanbul-lib-coverage: ^3.0.0 + semver: ^6.3.0 + checksum: fa1171d3022b1bb8f6a734042620ac5d9ee7dc80f3065a0bb12863e9f0494d0eefa3d86608fcc0254ab2765d29d7dad8bdc42e5f8df2f9a1fbe85ccc59d76cb9 + languageName: node + linkType: hard + +"istanbul-lib-processinfo@npm:^2.0.2": + version: 2.0.3 + resolution: "istanbul-lib-processinfo@npm:2.0.3" + dependencies: + archy: ^1.0.0 + cross-spawn: ^7.0.3 + istanbul-lib-coverage: ^3.2.0 + p-map: ^3.0.0 + rimraf: ^3.0.0 + uuid: ^8.3.2 + checksum: 501729e809a4e98bbb9f62f89cae924be81655a7ff8118661f8834a10bb89ed5d3a5099ea0b6555e1a8ee15a0099cb64f7170b89aae155ab2afacfe8dd94421a + languageName: node + linkType: hard + +"istanbul-lib-report@npm:^3.0.0": + version: 3.0.0 + resolution: "istanbul-lib-report@npm:3.0.0" + dependencies: + istanbul-lib-coverage: ^3.0.0 + make-dir: ^3.0.0 + supports-color: ^7.1.0 + checksum: 3f29eb3f53c59b987386e07fe772d24c7f58c6897f34c9d7a296f4000de7ae3de9eb95c3de3df91dc65b134c84dee35c54eee572a56243e8907c48064e34ff1b + languageName: node + linkType: hard + +"istanbul-lib-source-maps@npm:^4.0.0": + version: 4.0.1 + resolution: "istanbul-lib-source-maps@npm:4.0.1" + dependencies: + debug: ^4.1.1 + istanbul-lib-coverage: ^3.0.0 + source-map: ^0.6.1 + checksum: 21ad3df45db4b81852b662b8d4161f6446cd250c1ddc70ef96a585e2e85c26ed7cd9c2a396a71533cfb981d1a645508bc9618cae431e55d01a0628e7dec62ef2 + languageName: node + linkType: hard + +"istanbul-reports@npm:^3.0.2": + version: 3.1.5 + resolution: "istanbul-reports@npm:3.1.5" + dependencies: + html-escaper: ^2.0.0 + istanbul-lib-report: ^3.0.0 + checksum: 7867228f83ed39477b188ea07e7ccb9b4f5320b6f73d1db93a0981b7414fa4ef72d3f80c4692c442f90fc250d9406e71d8d7ab65bb615cb334e6292b73192b89 + languageName: node + linkType: hard + +"jackspeak@npm:^2.0.3": + version: 2.2.1 + resolution: "jackspeak@npm:2.2.1" + dependencies: + "@isaacs/cliui": ^8.0.2 + "@pkgjs/parseargs": ^0.11.0 + dependenciesMeta: + "@pkgjs/parseargs": + optional: true + checksum: e29291c0d0f280a063fa18fbd1e891ab8c2d7519fd34052c0ebde38538a15c603140d60c2c7f432375ff7ee4c5f1c10daa8b2ae19a97c3d4affe308c8360c1df + languageName: node + linkType: hard + +"js-tokens@npm:^4.0.0": + version: 4.0.0 + resolution: "js-tokens@npm:4.0.0" + checksum: 8a95213a5a77deb6cbe94d86340e8d9ace2b93bc367790b260101d2f36a2eaf4e4e22d9fa9cf459b38af3a32fb4190e638024cf82ec95ef708680e405ea7cc78 + languageName: node + linkType: hard + +"js-yaml@npm:4.1.0, js-yaml@npm:^4.1.0": + version: 4.1.0 + resolution: "js-yaml@npm:4.1.0" + dependencies: + argparse: ^2.0.1 + bin: + js-yaml: bin/js-yaml.js + checksum: c7830dfd456c3ef2c6e355cc5a92e6700ceafa1d14bba54497b34a99f0376cecbb3e9ac14d3e5849b426d5a5140709a66237a8c991c675431271c4ce5504151a + languageName: node + linkType: hard + +"js-yaml@npm:^3.13.1": + version: 3.14.1 + resolution: "js-yaml@npm:3.14.1" + dependencies: + argparse: ^1.0.7 + esprima: ^4.0.0 + bin: + js-yaml: bin/js-yaml.js + checksum: bef146085f472d44dee30ec34e5cf36bf89164f5d585435a3d3da89e52622dff0b188a580e4ad091c3341889e14cb88cac6e4deb16dc5b1e9623bb0601fc255c + languageName: node + linkType: hard + +"jsesc@npm:^2.5.1": + version: 2.5.2 + resolution: "jsesc@npm:2.5.2" + bin: + jsesc: bin/jsesc + checksum: 4dc190771129e12023f729ce20e1e0bfceac84d73a85bc3119f7f938843fe25a4aeccb54b6494dce26fcf263d815f5f31acdefac7cc9329efb8422a4f4d9fa9d + languageName: node + linkType: hard + +"json-schema-traverse@npm:^0.4.1": + version: 0.4.1 + resolution: "json-schema-traverse@npm:0.4.1" + checksum: 7486074d3ba247769fda17d5181b345c9fb7d12e0da98b22d1d71a5db9698d8b4bd900a3ec1a4ffdd60846fc2556274a5c894d0c48795f14cb03aeae7b55260b + languageName: node + linkType: hard + +"json-stable-stringify-without-jsonify@npm:^1.0.1": + version: 1.0.1 + resolution: "json-stable-stringify-without-jsonify@npm:1.0.1" + checksum: cff44156ddce9c67c44386ad5cddf91925fe06b1d217f2da9c4910d01f358c6e3989c4d5a02683c7a5667f9727ff05831f7aa8ae66c8ff691c556f0884d49215 + languageName: node + linkType: hard + +"json-stringify-safe@npm:^5.0.1": + version: 5.0.1 + resolution: "json-stringify-safe@npm:5.0.1" + checksum: 48ec0adad5280b8a96bb93f4563aa1667fd7a36334f79149abd42446d0989f2ddc58274b479f4819f1f00617957e6344c886c55d05a4e15ebb4ab931e4a6a8ee + languageName: node + linkType: hard + +"json5@npm:^2.2.2": + version: 2.2.3 + resolution: "json5@npm:2.2.3" + bin: + json5: lib/cli.js + checksum: 2a7436a93393830bce797d4626275152e37e877b265e94ca69c99e3d20c2b9dab021279146a39cdb700e71b2dd32a4cebd1514cd57cee102b1af906ce5040349 + languageName: node + linkType: hard + +"just-extend@npm:^4.0.2": + version: 4.2.1 + resolution: "just-extend@npm:4.2.1" + checksum: ff9fdede240fad313efeeeb68a660b942e5586d99c0058064c78884894a2690dc09bba44c994ad4e077e45d913fef01a9240c14a72c657b53687ac58de53b39c + languageName: node + linkType: hard + +"levn@npm:^0.4.1": + version: 0.4.1 + resolution: "levn@npm:0.4.1" + dependencies: + prelude-ls: ^1.2.1 + type-check: ~0.4.0 + checksum: 12c5021c859bd0f5248561bf139121f0358285ec545ebf48bb3d346820d5c61a4309535c7f387ed7d84361cf821e124ce346c6b7cef8ee09a67c1473b46d0fc4 + languageName: node + linkType: hard + +"locate-path@npm:^5.0.0": + version: 5.0.0 + resolution: "locate-path@npm:5.0.0" + dependencies: + p-locate: ^4.1.0 + checksum: 83e51725e67517287d73e1ded92b28602e3ae5580b301fe54bfb76c0c723e3f285b19252e375712316774cf52006cb236aed5704692c32db0d5d089b69696e30 + languageName: node + linkType: hard + +"locate-path@npm:^6.0.0": + version: 6.0.0 + resolution: "locate-path@npm:6.0.0" + dependencies: + p-locate: ^5.0.0 + checksum: 72eb661788a0368c099a184c59d2fee760b3831c9c1c33955e8a19ae4a21b4116e53fa736dc086cdeb9fce9f7cc508f2f92d2d3aae516f133e16a2bb59a39f5a + languageName: node + linkType: hard + +"lodash.flattendeep@npm:^4.4.0": + version: 4.4.0 + resolution: "lodash.flattendeep@npm:4.4.0" + checksum: 8521c919acac3d4bcf0aaf040c1ca9cb35d6c617e2d72e9b4d51c9a58b4366622cd6077441a18be626c3f7b28227502b3bf042903d447b056ee7e0b11d45c722 + languageName: node + linkType: hard + +"lodash.merge@npm:^4.6.2": + version: 4.6.2 + resolution: "lodash.merge@npm:4.6.2" + checksum: ad580b4bdbb7ca1f7abf7e1bce63a9a0b98e370cf40194b03380a46b4ed799c9573029599caebc1b14e3f24b111aef72b96674a56cfa105e0f5ac70546cdc005 + languageName: node + linkType: hard + +"lodash@npm:^4.17.15, lodash@npm:^4.17.21": + version: 4.17.21 + resolution: "lodash@npm:4.17.21" + checksum: eb835a2e51d381e561e508ce932ea50a8e5a68f4ebdd771ea240d3048244a8d13658acbd502cd4829768c56f2e16bdd4340b9ea141297d472517b83868e677f7 + languageName: node + linkType: hard + +"log-symbols@npm:4.1.0": + version: 4.1.0 + resolution: "log-symbols@npm:4.1.0" + dependencies: + chalk: ^4.1.0 + is-unicode-supported: ^0.1.0 + checksum: fce1497b3135a0198803f9f07464165e9eb83ed02ceb2273930a6f8a508951178d8cf4f0378e9d28300a2ed2bc49050995d2bd5f53ab716bb15ac84d58c6ef74 + languageName: node + linkType: hard + +"lolex@npm:^4.2.0": + version: 4.2.0 + resolution: "lolex@npm:4.2.0" + checksum: 0a83bfe1748fc745515dff9b3f722422918f5f6975104d7e576fc32c06b5398ee0c58525684068d4de49cdd49874e00b5e2b2d72ce8c5d829dab86c8c08ca31f + languageName: node + linkType: hard + +"lolex@npm:^5.0.1": + version: 5.1.2 + resolution: "lolex@npm:5.1.2" + dependencies: + "@sinonjs/commons": ^1.7.0 + checksum: 7eb468d4ef4746c024d23cb2b75f679f79449a9d5cbe11abadf2f3b147c1d7ffe28816438bedfb8a75c58357a625c2f9ba197b050c226d2b3f0c4a956cf556fb + languageName: node + linkType: hard + +"lru-cache@npm:^5.1.1": + version: 5.1.1 + resolution: "lru-cache@npm:5.1.1" + dependencies: + yallist: ^3.0.2 + checksum: c154ae1cbb0c2206d1501a0e94df349653c92c8cbb25236d7e85190bcaf4567a03ac6eb43166fabfa36fd35623694da7233e88d9601fbf411a9a481d85dbd2cb + languageName: node + linkType: hard + +"lru-cache@npm:^6.0.0": + version: 6.0.0 + resolution: "lru-cache@npm:6.0.0" + dependencies: + yallist: ^4.0.0 + checksum: f97f499f898f23e4585742138a22f22526254fdba6d75d41a1c2526b3b6cc5747ef59c5612ba7375f42aca4f8461950e925ba08c991ead0651b4918b7c978297 + languageName: node + linkType: hard + +"lru-cache@npm:^7.7.1": + version: 7.18.3 + resolution: "lru-cache@npm:7.18.3" + checksum: e550d772384709deea3f141af34b6d4fa392e2e418c1498c078de0ee63670f1f46f5eee746e8ef7e69e1c895af0d4224e62ee33e66a543a14763b0f2e74c1356 + languageName: node + linkType: hard + +"lru-cache@npm:^9.1.1 || ^10.0.0": + version: 10.0.0 + resolution: "lru-cache@npm:10.0.0" + checksum: 18f101675fe283bc09cda0ef1e3cc83781aeb8373b439f086f758d1d91b28730950db785999cd060d3c825a8571c03073e8c14512b6655af2188d623031baf50 + languageName: node + linkType: hard + +"make-dir@npm:^3.0.0, make-dir@npm:^3.0.2": + version: 3.1.0 + resolution: "make-dir@npm:3.1.0" + dependencies: + semver: ^6.0.0 + checksum: 484200020ab5a1fdf12f393fe5f385fc8e4378824c940fba1729dcd198ae4ff24867bc7a5646331e50cead8abff5d9270c456314386e629acec6dff4b8016b78 + languageName: node + linkType: hard + +"make-error@npm:^1.1.1": + version: 1.3.6 + resolution: "make-error@npm:1.3.6" + checksum: b86e5e0e25f7f777b77fabd8e2cbf15737972869d852a22b7e73c17623928fccb826d8e46b9951501d3f20e51ad74ba8c59ed584f610526a48f8ccf88aaec402 + languageName: node + linkType: hard + +"make-fetch-happen@npm:^11.0.3": + version: 11.1.1 + resolution: "make-fetch-happen@npm:11.1.1" + dependencies: + agentkeepalive: ^4.2.1 + cacache: ^17.0.0 + http-cache-semantics: ^4.1.1 + http-proxy-agent: ^5.0.0 + https-proxy-agent: ^5.0.0 + is-lambda: ^1.0.1 + lru-cache: ^7.7.1 + minipass: ^5.0.0 + minipass-fetch: ^3.0.0 + minipass-flush: ^1.0.5 + minipass-pipeline: ^1.2.4 + negotiator: ^0.6.3 + promise-retry: ^2.0.1 + socks-proxy-agent: ^7.0.0 + ssri: ^10.0.0 + checksum: 7268bf274a0f6dcf0343829489a4506603ff34bd0649c12058753900b0eb29191dce5dba12680719a5d0a983d3e57810f594a12f3c18494e93a1fbc6348a4540 + languageName: node + linkType: hard + +"merge2@npm:^1.3.0, merge2@npm:^1.4.1": + version: 1.4.1 + resolution: "merge2@npm:1.4.1" + checksum: 7268db63ed5169466540b6fb947aec313200bcf6d40c5ab722c22e242f651994619bcd85601602972d3c85bd2cc45a358a4c61937e9f11a061919a1da569b0c2 + languageName: node + linkType: hard + +"micromatch@npm:^4.0.4": + version: 4.0.5 + resolution: "micromatch@npm:4.0.5" + dependencies: + braces: ^3.0.2 + picomatch: ^2.3.1 + checksum: 02a17b671c06e8fefeeb6ef996119c1e597c942e632a21ef589154f23898c9c6a9858526246abb14f8bca6e77734aa9dcf65476fca47cedfb80d9577d52843fc + languageName: node + linkType: hard + +"minimatch@npm:4.2.1": + version: 4.2.1 + resolution: "minimatch@npm:4.2.1" + dependencies: + brace-expansion: ^1.1.7 + checksum: 2b1514e3d0f29a549912f0db7ae7b82c5cab4a8f2dd0369f1c6451a325b3f12b2cf473c95873b6157bb8df183d6cf6db82ff03614b6adaaf1d7e055beccdfd01 + languageName: node + linkType: hard + +"minimatch@npm:^3.0.4, minimatch@npm:^3.0.5, minimatch@npm:^3.1.1, minimatch@npm:^3.1.2": + version: 3.1.2 + resolution: "minimatch@npm:3.1.2" + dependencies: + brace-expansion: ^1.1.7 + checksum: c154e566406683e7bcb746e000b84d74465b3a832c45d59912b9b55cd50dee66e5c4b1e5566dba26154040e51672f9aa450a9aef0c97cfc7336b78b7afb9540a + languageName: node + linkType: hard + +"minimatch@npm:^9.0.1": + version: 9.0.3 + resolution: "minimatch@npm:9.0.3" + dependencies: + brace-expansion: ^2.0.1 + checksum: 253487976bf485b612f16bf57463520a14f512662e592e95c571afdab1442a6a6864b6c88f248ce6fc4ff0b6de04ac7aa6c8bb51e868e99d1d65eb0658a708b5 + languageName: node + linkType: hard + +"minipass-collect@npm:^1.0.2": + version: 1.0.2 + resolution: "minipass-collect@npm:1.0.2" + dependencies: + minipass: ^3.0.0 + checksum: 14df761028f3e47293aee72888f2657695ec66bd7d09cae7ad558da30415fdc4752bbfee66287dcc6fd5e6a2fa3466d6c484dc1cbd986525d9393b9523d97f10 + languageName: node + linkType: hard + +"minipass-fetch@npm:^3.0.0": + version: 3.0.3 + resolution: "minipass-fetch@npm:3.0.3" + dependencies: + encoding: ^0.1.13 + minipass: ^5.0.0 + minipass-sized: ^1.0.3 + minizlib: ^2.1.2 + dependenciesMeta: + encoding: + optional: true + checksum: af5ab2552a16fcf505d35fd7ffb84b57f4a0eeb269e6e1d9a2a75824dda48b36e527083250b7cca4a4def21d9544e2ade441e4730e233c0bc2133f6abda31e18 + languageName: node + linkType: hard + +"minipass-flush@npm:^1.0.5": + version: 1.0.5 + resolution: "minipass-flush@npm:1.0.5" + dependencies: + minipass: ^3.0.0 + checksum: 56269a0b22bad756a08a94b1ffc36b7c9c5de0735a4dd1ab2b06c066d795cfd1f0ac44a0fcae13eece5589b908ecddc867f04c745c7009be0b566421ea0944cf + languageName: node + linkType: hard + +"minipass-pipeline@npm:^1.2.4": + version: 1.2.4 + resolution: "minipass-pipeline@npm:1.2.4" + dependencies: + minipass: ^3.0.0 + checksum: b14240dac0d29823c3d5911c286069e36d0b81173d7bdf07a7e4a91ecdef92cdff4baaf31ea3746f1c61e0957f652e641223970870e2353593f382112257971b + languageName: node + linkType: hard + +"minipass-sized@npm:^1.0.3": + version: 1.0.3 + resolution: "minipass-sized@npm:1.0.3" + dependencies: + minipass: ^3.0.0 + checksum: 79076749fcacf21b5d16dd596d32c3b6bf4d6e62abb43868fac21674078505c8b15eaca4e47ed844985a4514854f917d78f588fcd029693709417d8f98b2bd60 + languageName: node + linkType: hard + +"minipass@npm:^3.0.0": + version: 3.3.6 + resolution: "minipass@npm:3.3.6" + dependencies: + yallist: ^4.0.0 + checksum: a30d083c8054cee83cdcdc97f97e4641a3f58ae743970457b1489ce38ee1167b3aaf7d815cd39ec7a99b9c40397fd4f686e83750e73e652b21cb516f6d845e48 + languageName: node + linkType: hard + +"minipass@npm:^5.0.0": + version: 5.0.0 + resolution: "minipass@npm:5.0.0" + checksum: 425dab288738853fded43da3314a0b5c035844d6f3097a8e3b5b29b328da8f3c1af6fc70618b32c29ff906284cf6406b6841376f21caaadd0793c1d5a6a620ea + languageName: node + linkType: hard + +"minipass@npm:^5.0.0 || ^6.0.2 || ^7.0.0": + version: 7.0.1 + resolution: "minipass@npm:7.0.1" + checksum: fedd1293f6a1b4e406c242a1cecfb75d0a81422bb2c365d999e33a88642fb68d70a89d95b550e08c640b3c0d9162829310e0c58b9b846b9218de25779818c709 + languageName: node + linkType: hard + +"minizlib@npm:^2.1.1, minizlib@npm:^2.1.2": + version: 2.1.2 + resolution: "minizlib@npm:2.1.2" + dependencies: + minipass: ^3.0.0 + yallist: ^4.0.0 + checksum: f1fdeac0b07cf8f30fcf12f4b586795b97be856edea22b5e9072707be51fc95d41487faec3f265b42973a304fe3a64acd91a44a3826a963e37b37bafde0212c3 + languageName: node + linkType: hard + +"mkdirp@npm:^1.0.3": + version: 1.0.4 + resolution: "mkdirp@npm:1.0.4" + bin: + mkdirp: bin/cmd.js + checksum: a96865108c6c3b1b8e1d5e9f11843de1e077e57737602de1b82030815f311be11f96f09cce59bd5b903d0b29834733e5313f9301e3ed6d6f6fba2eae0df4298f + languageName: node + linkType: hard + +"mocha@npm:^9.2.2": + version: 9.2.2 + resolution: "mocha@npm:9.2.2" + dependencies: + "@ungap/promise-all-settled": 1.1.2 + ansi-colors: 4.1.1 + browser-stdout: 1.3.1 + chokidar: 3.5.3 + debug: 4.3.3 + diff: 5.0.0 + escape-string-regexp: 4.0.0 + find-up: 5.0.0 + glob: 7.2.0 + growl: 1.10.5 + he: 1.2.0 + js-yaml: 4.1.0 + log-symbols: 4.1.0 + minimatch: 4.2.1 + ms: 2.1.3 + nanoid: 3.3.1 + serialize-javascript: 6.0.0 + strip-json-comments: 3.1.1 + supports-color: 8.1.1 + which: 2.0.2 + workerpool: 6.2.0 + yargs: 16.2.0 + yargs-parser: 20.2.4 + yargs-unparser: 2.0.0 + bin: + _mocha: bin/_mocha + mocha: bin/mocha + checksum: 4d5ca4ce33fc66627e63acdf09a634e2358c9a00f61de7788b1091b6aad430da04f97f9ecb82d56dc034b623cb833b65576136fd010d77679c03fcea5bc1e12d + languageName: node + linkType: hard + +"ms@npm:2.1.2": + version: 2.1.2 + resolution: "ms@npm:2.1.2" + checksum: 673cdb2c3133eb050c745908d8ce632ed2c02d85640e2edb3ace856a2266a813b30c613569bf3354fdf4ea7d1a1494add3bfa95e2713baa27d0c2c71fc44f58f + languageName: node + linkType: hard + +"ms@npm:2.1.3, ms@npm:^2.0.0": + version: 2.1.3 + resolution: "ms@npm:2.1.3" + checksum: aa92de608021b242401676e35cfa5aa42dd70cbdc082b916da7fb925c542173e36bce97ea3e804923fe92c0ad991434e4a38327e15a1b5b5f945d66df615ae6d + languageName: node + linkType: hard + +"nanoid@npm:3.3.1": + version: 3.3.1 + resolution: "nanoid@npm:3.3.1" + bin: + nanoid: bin/nanoid.cjs + checksum: 4ef0969e1bbe866fc223eb32276cbccb0961900bfe79104fa5abe34361979dead8d0e061410a5c03bc3d47455685adf32c09d6f27790f4a6898fb51f7df7ec86 + languageName: node + linkType: hard + +"natural-compare-lite@npm:^1.4.0": + version: 1.4.0 + resolution: "natural-compare-lite@npm:1.4.0" + checksum: 5222ac3986a2b78dd6069ac62cbb52a7bf8ffc90d972ab76dfe7b01892485d229530ed20d0c62e79a6b363a663b273db3bde195a1358ce9e5f779d4453887225 + languageName: node + linkType: hard + +"natural-compare@npm:^1.4.0": + version: 1.4.0 + resolution: "natural-compare@npm:1.4.0" + checksum: 23ad088b08f898fc9b53011d7bb78ec48e79de7627e01ab5518e806033861bef68d5b0cd0e2205c2f36690ac9571ff6bcb05eb777ced2eeda8d4ac5b44592c3d + languageName: node + linkType: hard + +"negotiator@npm:^0.6.3": + version: 0.6.3 + resolution: "negotiator@npm:0.6.3" + checksum: b8ffeb1e262eff7968fc90a2b6767b04cfd9842582a9d0ece0af7049537266e7b2506dfb1d107a32f06dd849ab2aea834d5830f7f4d0e5cb7d36e1ae55d021d9 + languageName: node + linkType: hard + +"nise@npm:^1.5.2": + version: 1.5.3 + resolution: "nise@npm:1.5.3" + dependencies: + "@sinonjs/formatio": ^3.2.1 + "@sinonjs/text-encoding": ^0.7.1 + just-extend: ^4.0.2 + lolex: ^5.0.1 + path-to-regexp: ^1.7.0 + checksum: ec3af21345dcaf34650a6f5420a11e0fd21a836ac5960f5e8523c301ee98465abf88b958f7b3084ecc6e0a7133e5cf7963f4df176b90b423c4da4984f1ebd75e + languageName: node + linkType: hard + +"nock@npm:^13.3.1": + version: 13.3.1 + resolution: "nock@npm:13.3.1" + dependencies: + debug: ^4.1.0 + json-stringify-safe: ^5.0.1 + lodash: ^4.17.21 + propagate: ^2.0.0 + checksum: 0f2a73e8432f6b5650656c53eef99f9e5bbde3df538dc2f07057edc4438cfc61a394c9d06dd82e60f6e86d42433f20f3c04364a1f088beee7bf03a24e3f0fdd0 + languageName: node + linkType: hard + +"node-gyp@npm:latest": + version: 9.4.0 + resolution: "node-gyp@npm:9.4.0" + dependencies: + env-paths: ^2.2.0 + exponential-backoff: ^3.1.1 + glob: ^7.1.4 + graceful-fs: ^4.2.6 + make-fetch-happen: ^11.0.3 + nopt: ^6.0.0 + npmlog: ^6.0.0 + rimraf: ^3.0.2 + semver: ^7.3.5 + tar: ^6.1.2 + which: ^2.0.2 + bin: + node-gyp: bin/node-gyp.js + checksum: 78b404e2e0639d64e145845f7f5a3cb20c0520cdaf6dda2f6e025e9b644077202ea7de1232396ba5bde3fee84cdc79604feebe6ba3ec84d464c85d407bb5da99 + languageName: node + linkType: hard + +"node-preload@npm:^0.2.1": + version: 0.2.1 + resolution: "node-preload@npm:0.2.1" + dependencies: + process-on-spawn: ^1.0.0 + checksum: 4586f91ac7417b33accce0ac629fb60f642d0c8d212b3c536dc3dda37fe54f8a3b858273380e1036e41a65d85470332c358315d2288e6584260d620fb4b00fb3 + languageName: node + linkType: hard + +"node-releases@npm:^2.0.12": + version: 2.0.13 + resolution: "node-releases@npm:2.0.13" + checksum: 17ec8f315dba62710cae71a8dad3cd0288ba943d2ece43504b3b1aa8625bf138637798ab470b1d9035b0545996f63000a8a926e0f6d35d0996424f8b6d36dda3 + languageName: node + linkType: hard + +"nopt@npm:^6.0.0": + version: 6.0.0 + resolution: "nopt@npm:6.0.0" + dependencies: + abbrev: ^1.0.0 + bin: + nopt: bin/nopt.js + checksum: 82149371f8be0c4b9ec2f863cc6509a7fd0fa729929c009f3a58e4eb0c9e4cae9920e8f1f8eb46e7d032fec8fb01bede7f0f41a67eb3553b7b8e14fa53de1dac + languageName: node + linkType: hard + +"normalize-path@npm:^3.0.0, normalize-path@npm:~3.0.0": + version: 3.0.0 + resolution: "normalize-path@npm:3.0.0" + checksum: 88eeb4da891e10b1318c4b2476b6e2ecbeb5ff97d946815ffea7794c31a89017c70d7f34b3c2ebf23ef4e9fc9fb99f7dffe36da22011b5b5c6ffa34f4873ec20 + languageName: node + linkType: hard + +"npmlog@npm:^6.0.0": + version: 6.0.2 + resolution: "npmlog@npm:6.0.2" + dependencies: + are-we-there-yet: ^3.0.0 + console-control-strings: ^1.1.0 + gauge: ^4.0.3 + set-blocking: ^2.0.0 + checksum: ae238cd264a1c3f22091cdd9e2b106f684297d3c184f1146984ecbe18aaa86343953f26b9520dedd1b1372bc0316905b736c1932d778dbeb1fcf5a1001390e2a + languageName: node + linkType: hard + +"nyc@npm:^15.1.0": + version: 15.1.0 + resolution: "nyc@npm:15.1.0" + dependencies: + "@istanbuljs/load-nyc-config": ^1.0.0 + "@istanbuljs/schema": ^0.1.2 + caching-transform: ^4.0.0 + convert-source-map: ^1.7.0 + decamelize: ^1.2.0 + find-cache-dir: ^3.2.0 + find-up: ^4.1.0 + foreground-child: ^2.0.0 + get-package-type: ^0.1.0 + glob: ^7.1.6 + istanbul-lib-coverage: ^3.0.0 + istanbul-lib-hook: ^3.0.0 + istanbul-lib-instrument: ^4.0.0 + istanbul-lib-processinfo: ^2.0.2 + istanbul-lib-report: ^3.0.0 + istanbul-lib-source-maps: ^4.0.0 + istanbul-reports: ^3.0.2 + make-dir: ^3.0.0 + node-preload: ^0.2.1 + p-map: ^3.0.0 + process-on-spawn: ^1.0.0 + resolve-from: ^5.0.0 + rimraf: ^3.0.0 + signal-exit: ^3.0.2 + spawn-wrap: ^2.0.0 + test-exclude: ^6.0.0 + yargs: ^15.0.2 + bin: + nyc: bin/nyc.js + checksum: 82a7031982df2fd6ab185c9f1b5d032b6221846268007b45b5773c6582e776ab33e96cd22b4231520345942fcef69b4339bd967675b8483f3fa255b56326faef + languageName: node + linkType: hard + +"once@npm:^1.3.0": + version: 1.4.0 + resolution: "once@npm:1.4.0" + dependencies: + wrappy: 1 + checksum: cd0a88501333edd640d95f0d2700fbde6bff20b3d4d9bdc521bdd31af0656b5706570d6c6afe532045a20bb8dc0849f8332d6f2a416e0ba6d3d3b98806c7db68 + languageName: node + linkType: hard + +"optionator@npm:^0.9.3": + version: 0.9.3 + resolution: "optionator@npm:0.9.3" + dependencies: + "@aashutoshrathi/word-wrap": ^1.2.3 + deep-is: ^0.1.3 + fast-levenshtein: ^2.0.6 + levn: ^0.4.1 + prelude-ls: ^1.2.1 + type-check: ^0.4.0 + checksum: 09281999441f2fe9c33a5eeab76700795365a061563d66b098923eb719251a42bdbe432790d35064d0816ead9296dbeb1ad51a733edf4167c96bd5d0882e428a + languageName: node + linkType: hard + +"p-limit@npm:^2.2.0": + version: 2.3.0 + resolution: "p-limit@npm:2.3.0" + dependencies: + p-try: ^2.0.0 + checksum: 84ff17f1a38126c3314e91ecfe56aecbf36430940e2873dadaa773ffe072dc23b7af8e46d4b6485d302a11673fe94c6b67ca2cfbb60c989848b02100d0594ac1 + languageName: node + linkType: hard + +"p-limit@npm:^3.0.2": + version: 3.1.0 + resolution: "p-limit@npm:3.1.0" + dependencies: + yocto-queue: ^0.1.0 + checksum: 7c3690c4dbf62ef625671e20b7bdf1cbc9534e83352a2780f165b0d3ceba21907e77ad63401708145ca4e25bfc51636588d89a8c0aeb715e6c37d1c066430360 + languageName: node + linkType: hard + +"p-locate@npm:^4.1.0": + version: 4.1.0 + resolution: "p-locate@npm:4.1.0" + dependencies: + p-limit: ^2.2.0 + checksum: 513bd14a455f5da4ebfcb819ef706c54adb09097703de6aeaa5d26fe5ea16df92b48d1ac45e01e3944ce1e6aa2a66f7f8894742b8c9d6e276e16cd2049a2b870 + languageName: node + linkType: hard + +"p-locate@npm:^5.0.0": + version: 5.0.0 + resolution: "p-locate@npm:5.0.0" + dependencies: + p-limit: ^3.0.2 + checksum: 1623088f36cf1cbca58e9b61c4e62bf0c60a07af5ae1ca99a720837356b5b6c5ba3eb1b2127e47a06865fee59dd0453cad7cc844cda9d5a62ac1a5a51b7c86d3 + languageName: node + linkType: hard + +"p-map@npm:^3.0.0": + version: 3.0.0 + resolution: "p-map@npm:3.0.0" + dependencies: + aggregate-error: ^3.0.0 + checksum: 49b0fcbc66b1ef9cd379de1b4da07fa7a9f84b41509ea3f461c31903623aaba8a529d22f835e0d77c7cb9fcc16e4fae71e308fd40179aea514ba68f27032b5d5 + languageName: node + linkType: hard + +"p-map@npm:^4.0.0": + version: 4.0.0 + resolution: "p-map@npm:4.0.0" + dependencies: + aggregate-error: ^3.0.0 + checksum: cb0ab21ec0f32ddffd31dfc250e3afa61e103ef43d957cc45497afe37513634589316de4eb88abdfd969fe6410c22c0b93ab24328833b8eb1ccc087fc0442a1c + languageName: node + linkType: hard + +"p-try@npm:^2.0.0": + version: 2.2.0 + resolution: "p-try@npm:2.2.0" + checksum: f8a8e9a7693659383f06aec604ad5ead237c7a261c18048a6e1b5b85a5f8a067e469aa24f5bc009b991ea3b058a87f5065ef4176793a200d4917349881216cae + languageName: node + linkType: hard + +"package-hash@npm:^4.0.0": + version: 4.0.0 + resolution: "package-hash@npm:4.0.0" + dependencies: + graceful-fs: ^4.1.15 + hasha: ^5.0.0 + lodash.flattendeep: ^4.4.0 + release-zalgo: ^1.0.0 + checksum: 32c49e3a0e1c4a33b086a04cdd6d6e570aee019cb8402ec16476d9b3564a40e38f91ce1a1f9bc88b08f8ef2917a11e0b786c08140373bdf609ea90749031e6fc + languageName: node + linkType: hard + +"parent-module@npm:^1.0.0": + version: 1.0.1 + resolution: "parent-module@npm:1.0.1" + dependencies: + callsites: ^3.0.0 + checksum: 6ba8b255145cae9470cf5551eb74be2d22281587af787a2626683a6c20fbb464978784661478dd2a3f1dad74d1e802d403e1b03c1a31fab310259eec8ac560ff + languageName: node + linkType: hard + +"path-exists@npm:^4.0.0": + version: 4.0.0 + resolution: "path-exists@npm:4.0.0" + checksum: 505807199dfb7c50737b057dd8d351b82c033029ab94cb10a657609e00c1bc53b951cfdbccab8de04c5584d5eff31128ce6afd3db79281874a5ef2adbba55ed1 + languageName: node + linkType: hard + +"path-is-absolute@npm:^1.0.0": + version: 1.0.1 + resolution: "path-is-absolute@npm:1.0.1" + checksum: 060840f92cf8effa293bcc1bea81281bd7d363731d214cbe5c227df207c34cd727430f70c6037b5159c8a870b9157cba65e775446b0ab06fd5ecc7e54615a3b8 + languageName: node + linkType: hard + +"path-key@npm:^3.1.0": + version: 3.1.1 + resolution: "path-key@npm:3.1.1" + checksum: 55cd7a9dd4b343412a8386a743f9c746ef196e57c823d90ca3ab917f90ab9f13dd0ded27252ba49dbdfcab2b091d998bc446f6220cd3cea65db407502a740020 + languageName: node + linkType: hard + +"path-scurry@npm:^1.10.1": + version: 1.10.1 + resolution: "path-scurry@npm:1.10.1" + dependencies: + lru-cache: ^9.1.1 || ^10.0.0 + minipass: ^5.0.0 || ^6.0.2 || ^7.0.0 + checksum: e2557cff3a8fb8bc07afdd6ab163a92587884f9969b05bbbaf6fe7379348bfb09af9ed292af12ed32398b15fb443e81692047b786d1eeb6d898a51eb17ed7d90 + languageName: node + linkType: hard + +"path-to-regexp@npm:^1.7.0": + version: 1.8.0 + resolution: "path-to-regexp@npm:1.8.0" + dependencies: + isarray: 0.0.1 + checksum: 709f6f083c0552514ef4780cb2e7e4cf49b0cc89a97439f2b7cc69a608982b7690fb5d1720a7473a59806508fc2dae0be751ba49f495ecf89fd8fbc62abccbcd + languageName: node + linkType: hard + +"path-type@npm:^4.0.0": + version: 4.0.0 + resolution: "path-type@npm:4.0.0" + checksum: 5b1e2daa247062061325b8fdbfd1fb56dde0a448fb1455453276ea18c60685bdad23a445dc148cf87bc216be1573357509b7d4060494a6fd768c7efad833ee45 + languageName: node + linkType: hard + +"picocolors@npm:^1.0.0": + version: 1.0.0 + resolution: "picocolors@npm:1.0.0" + checksum: a2e8092dd86c8396bdba9f2b5481032848525b3dc295ce9b57896f931e63fc16f79805144321f72976383fc249584672a75cc18d6777c6b757603f372f745981 + languageName: node + linkType: hard + +"picomatch@npm:^2.0.4, picomatch@npm:^2.2.1, picomatch@npm:^2.3.1": + version: 2.3.1 + resolution: "picomatch@npm:2.3.1" + checksum: 050c865ce81119c4822c45d3c84f1ced46f93a0126febae20737bd05ca20589c564d6e9226977df859ed5e03dc73f02584a2b0faad36e896936238238b0446cf + languageName: node + linkType: hard + +"pkg-dir@npm:^4.1.0": + version: 4.2.0 + resolution: "pkg-dir@npm:4.2.0" + dependencies: + find-up: ^4.0.0 + checksum: 9863e3f35132bf99ae1636d31ff1e1e3501251d480336edb1c211133c8d58906bed80f154a1d723652df1fda91e01c7442c2eeaf9dc83157c7ae89087e43c8d6 + languageName: node + linkType: hard + +"prelude-ls@npm:^1.2.1": + version: 1.2.1 + resolution: "prelude-ls@npm:1.2.1" + checksum: cd192ec0d0a8e4c6da3bb80e4f62afe336df3f76271ac6deb0e6a36187133b6073a19e9727a1ff108cd8b9982e4768850d413baa71214dd80c7979617dca827a + languageName: node + linkType: hard + +"prettier@npm:^2.8.8": + version: 2.8.8 + resolution: "prettier@npm:2.8.8" + bin: + prettier: bin-prettier.js + checksum: b49e409431bf129dd89238d64299ba80717b57ff5a6d1c1a8b1a28b590d998a34e083fa13573bc732bb8d2305becb4c9a4407f8486c81fa7d55100eb08263cf8 + languageName: node + linkType: hard + +"process-on-spawn@npm:^1.0.0": + version: 1.0.0 + resolution: "process-on-spawn@npm:1.0.0" + dependencies: + fromentries: ^1.2.0 + checksum: 597769e3db6a8e2cb1cd64a952bbc150220588debac31c7cf1a9f620ce981e25583d8d70848d8a14953577608512984a8808c3be77e09af8ebdcdc14ec23a295 + languageName: node + linkType: hard + +"promise-retry@npm:^2.0.1": + version: 2.0.1 + resolution: "promise-retry@npm:2.0.1" + dependencies: + err-code: ^2.0.2 + retry: ^0.12.0 + checksum: f96a3f6d90b92b568a26f71e966cbbc0f63ab85ea6ff6c81284dc869b41510e6cdef99b6b65f9030f0db422bf7c96652a3fff9f2e8fb4a0f069d8f4430359429 + languageName: node + linkType: hard + +"propagate@npm:^2.0.0": + version: 2.0.1 + resolution: "propagate@npm:2.0.1" + checksum: c4febaee2be0979e82fb6b3727878fd122a98d64a7fa3c9d09b0576751b88514a9e9275b1b92e76b364d488f508e223bd7e1dcdc616be4cdda876072fbc2a96c + languageName: node + linkType: hard + +"punycode@npm:^2.1.0": + version: 2.3.0 + resolution: "punycode@npm:2.3.0" + checksum: 39f760e09a2a3bbfe8f5287cf733ecdad69d6af2fe6f97ca95f24b8921858b91e9ea3c9eeec6e08cede96181b3bb33f95c6ffd8c77e63986508aa2e8159fa200 + languageName: node + linkType: hard + +"queue-microtask@npm:^1.2.2": + version: 1.2.3 + resolution: "queue-microtask@npm:1.2.3" + checksum: b676f8c040cdc5b12723ad2f91414d267605b26419d5c821ff03befa817ddd10e238d22b25d604920340fd73efd8ba795465a0377c4adf45a4a41e4234e42dc4 + languageName: node + linkType: hard + +"randombytes@npm:^2.1.0": + version: 2.1.0 + resolution: "randombytes@npm:2.1.0" + dependencies: + safe-buffer: ^5.1.0 + checksum: d779499376bd4cbb435ef3ab9a957006c8682f343f14089ed5f27764e4645114196e75b7f6abf1cbd84fd247c0cb0651698444df8c9bf30e62120fbbc52269d6 + languageName: node + linkType: hard + +"readable-stream@npm:^3.6.0": + version: 3.6.2 + resolution: "readable-stream@npm:3.6.2" + dependencies: + inherits: ^2.0.3 + string_decoder: ^1.1.1 + util-deprecate: ^1.0.1 + checksum: bdcbe6c22e846b6af075e32cf8f4751c2576238c5043169a1c221c92ee2878458a816a4ea33f4c67623c0b6827c8a400409bfb3cf0bf3381392d0b1dfb52ac8d + languageName: node + linkType: hard + +"readdirp@npm:~3.6.0": + version: 3.6.0 + resolution: "readdirp@npm:3.6.0" + dependencies: + picomatch: ^2.2.1 + checksum: 1ced032e6e45670b6d7352d71d21ce7edf7b9b928494dcaba6f11fba63180d9da6cd7061ebc34175ffda6ff529f481818c962952004d273178acd70f7059b320 + languageName: node + linkType: hard + +"release-zalgo@npm:^1.0.0": + version: 1.0.0 + resolution: "release-zalgo@npm:1.0.0" + dependencies: + es6-error: ^4.0.1 + checksum: b59849dc310f6c426f34e308c48ba83df3d034ddef75189951723bb2aac99d29d15f5e127edad951c4095fc9025aa582053907154d68fe0c5380cd6a75365e53 + languageName: node + linkType: hard + +"require-directory@npm:^2.1.1": + version: 2.1.1 + resolution: "require-directory@npm:2.1.1" + checksum: fb47e70bf0001fdeabdc0429d431863e9475e7e43ea5f94ad86503d918423c1543361cc5166d713eaa7029dd7a3d34775af04764bebff99ef413111a5af18c80 + languageName: node + linkType: hard + +"require-main-filename@npm:^2.0.0": + version: 2.0.0 + resolution: "require-main-filename@npm:2.0.0" + checksum: e9e294695fea08b076457e9ddff854e81bffbe248ed34c1eec348b7abbd22a0d02e8d75506559e2265e96978f3c4720bd77a6dad84755de8162b357eb6c778c7 + languageName: node + linkType: hard + +"resolve-from@npm:^4.0.0": + version: 4.0.0 + resolution: "resolve-from@npm:4.0.0" + checksum: f4ba0b8494846a5066328ad33ef8ac173801a51739eb4d63408c847da9a2e1c1de1e6cbbf72699211f3d13f8fc1325648b169bd15eb7da35688e30a5fb0e4a7f + languageName: node + linkType: hard + +"resolve-from@npm:^5.0.0": + version: 5.0.0 + resolution: "resolve-from@npm:5.0.0" + checksum: 4ceeb9113e1b1372d0cd969f3468fa042daa1dd9527b1b6bb88acb6ab55d8b9cd65dbf18819f9f9ddf0db804990901dcdaade80a215e7b2c23daae38e64f5bdf + languageName: node + linkType: hard + +"retry@npm:^0.12.0": + version: 0.12.0 + resolution: "retry@npm:0.12.0" + checksum: 623bd7d2e5119467ba66202d733ec3c2e2e26568074923bc0585b6b99db14f357e79bdedb63cab56cec47491c4a0da7e6021a7465ca6dc4f481d3898fdd3158c + languageName: node + linkType: hard + +"reusify@npm:^1.0.4": + version: 1.0.4 + resolution: "reusify@npm:1.0.4" + checksum: c3076ebcc22a6bc252cb0b9c77561795256c22b757f40c0d8110b1300723f15ec0fc8685e8d4ea6d7666f36c79ccc793b1939c748bf36f18f542744a4e379fcc + languageName: node + linkType: hard + +"rimraf@npm:^3.0.0, rimraf@npm:^3.0.2": + version: 3.0.2 + resolution: "rimraf@npm:3.0.2" + dependencies: + glob: ^7.1.3 + bin: + rimraf: bin.js + checksum: 87f4164e396f0171b0a3386cc1877a817f572148ee13a7e113b238e48e8a9f2f31d009a92ec38a591ff1567d9662c6b67fd8818a2dbbaed74bc26a87a2a4a9a0 + languageName: node + linkType: hard + +"run-parallel@npm:^1.1.9": + version: 1.2.0 + resolution: "run-parallel@npm:1.2.0" + dependencies: + queue-microtask: ^1.2.2 + checksum: cb4f97ad25a75ebc11a8ef4e33bb962f8af8516bb2001082ceabd8902e15b98f4b84b4f8a9b222e5d57fc3bd1379c483886ed4619367a7680dad65316993021d + languageName: node + linkType: hard + +"safe-buffer@npm:^5.1.0, safe-buffer@npm:~5.2.0": + version: 5.2.1 + resolution: "safe-buffer@npm:5.2.1" + checksum: b99c4b41fdd67a6aaf280fcd05e9ffb0813654894223afb78a31f14a19ad220bba8aba1cb14eddce1fcfb037155fe6de4e861784eb434f7d11ed58d1e70dd491 + languageName: node + linkType: hard + +"safer-buffer@npm:>= 2.1.2 < 3.0.0": + version: 2.1.2 + resolution: "safer-buffer@npm:2.1.2" + checksum: cab8f25ae6f1434abee8d80023d7e72b598cf1327164ddab31003c51215526801e40b66c5e65d658a0af1e9d6478cadcb4c745f4bd6751f97d8644786c0978b0 + languageName: node + linkType: hard + +"semver@npm:^6.0.0, semver@npm:^6.3.0": + version: 6.3.0 + resolution: "semver@npm:6.3.0" + bin: + semver: ./bin/semver.js + checksum: 1b26ecf6db9e8292dd90df4e781d91875c0dcc1b1909e70f5d12959a23c7eebb8f01ea581c00783bbee72ceeaad9505797c381756326073850dc36ed284b21b9 + languageName: node + linkType: hard + +"semver@npm:^7.3.5, semver@npm:^7.3.7": + version: 7.5.4 + resolution: "semver@npm:7.5.4" + dependencies: + lru-cache: ^6.0.0 + bin: + semver: bin/semver.js + checksum: 12d8ad952fa353b0995bf180cdac205a4068b759a140e5d3c608317098b3575ac2f1e09182206bf2eb26120e1c0ed8fb92c48c592f6099680de56bb071423ca3 + languageName: node + linkType: hard + +"serialize-javascript@npm:6.0.0": + version: 6.0.0 + resolution: "serialize-javascript@npm:6.0.0" + dependencies: + randombytes: ^2.1.0 + checksum: 56f90b562a1bdc92e55afb3e657c6397c01a902c588c0fe3d4c490efdcc97dcd2a3074ba12df9e94630f33a5ce5b76a74784a7041294628a6f4306e0ec84bf93 + languageName: node + linkType: hard + +"set-blocking@npm:^2.0.0": + version: 2.0.0 + resolution: "set-blocking@npm:2.0.0" + checksum: 6e65a05f7cf7ebdf8b7c75b101e18c0b7e3dff4940d480efed8aad3a36a4005140b660fa1d804cb8bce911cac290441dc728084a30504d3516ac2ff7ad607b02 + languageName: node + linkType: hard + +"shebang-command@npm:^2.0.0": + version: 2.0.0 + resolution: "shebang-command@npm:2.0.0" + dependencies: + shebang-regex: ^3.0.0 + checksum: 6b52fe87271c12968f6a054e60f6bde5f0f3d2db483a1e5c3e12d657c488a15474121a1d55cd958f6df026a54374ec38a4a963988c213b7570e1d51575cea7fa + languageName: node + linkType: hard + +"shebang-regex@npm:^3.0.0": + version: 3.0.0 + resolution: "shebang-regex@npm:3.0.0" + checksum: 1a2bcae50de99034fcd92ad4212d8e01eedf52c7ec7830eedcf886622804fe36884278f2be8be0ea5fde3fd1c23911643a4e0f726c8685b61871c8908af01222 + languageName: node + linkType: hard + +"signal-exit@npm:^3.0.2, signal-exit@npm:^3.0.7": + version: 3.0.7 + resolution: "signal-exit@npm:3.0.7" + checksum: a2f098f247adc367dffc27845853e9959b9e88b01cb301658cfe4194352d8d2bb32e18467c786a7fe15f1d44b233ea35633d076d5e737870b7139949d1ab6318 + languageName: node + linkType: hard + +"signal-exit@npm:^4.0.1": + version: 4.0.2 + resolution: "signal-exit@npm:4.0.2" + checksum: 41f5928431cc6e91087bf0343db786a6313dd7c6fd7e551dbc141c95bb5fb26663444fd9df8ea47c5d7fc202f60aa7468c3162a9365cbb0615fc5e1b1328fe31 + languageName: node + linkType: hard + +"sinon@npm:^7.5.0": + version: 7.5.0 + resolution: "sinon@npm:7.5.0" + dependencies: + "@sinonjs/commons": ^1.4.0 + "@sinonjs/formatio": ^3.2.1 + "@sinonjs/samsam": ^3.3.3 + diff: ^3.5.0 + lolex: ^4.2.0 + nise: ^1.5.2 + supports-color: ^5.5.0 + checksum: e8cf6b3dd16e9c1ed1a2b9560c396a2d6205a4f32293b1762cb6ebb8f88cfa47db6aba45b0c1709ec396efb41d171d88c9b1ab8f32f35512eb9e5d0d0d15d307 + languageName: node + linkType: hard + +"slash@npm:^3.0.0": + version: 3.0.0 + resolution: "slash@npm:3.0.0" + checksum: 94a93fff615f25a999ad4b83c9d5e257a7280c90a32a7cb8b4a87996e4babf322e469c42b7f649fd5796edd8687652f3fb452a86dc97a816f01113183393f11c + languageName: node + linkType: hard + +"smart-buffer@npm:^4.2.0": + version: 4.2.0 + resolution: "smart-buffer@npm:4.2.0" + checksum: b5167a7142c1da704c0e3af85c402002b597081dd9575031a90b4f229ca5678e9a36e8a374f1814c8156a725d17008ae3bde63b92f9cfd132526379e580bec8b + languageName: node + linkType: hard + +"socks-proxy-agent@npm:^7.0.0": + version: 7.0.0 + resolution: "socks-proxy-agent@npm:7.0.0" + dependencies: + agent-base: ^6.0.2 + debug: ^4.3.3 + socks: ^2.6.2 + checksum: 720554370154cbc979e2e9ce6a6ec6ced205d02757d8f5d93fe95adae454fc187a5cbfc6b022afab850a5ce9b4c7d73e0f98e381879cf45f66317a4895953846 + languageName: node + linkType: hard + +"socks@npm:^2.6.2": + version: 2.7.1 + resolution: "socks@npm:2.7.1" + dependencies: + ip: ^2.0.0 + smart-buffer: ^4.2.0 + checksum: 259d9e3e8e1c9809a7f5c32238c3d4d2a36b39b83851d0f573bfde5f21c4b1288417ce1af06af1452569cd1eb0841169afd4998f0e04ba04656f6b7f0e46d748 + languageName: node + linkType: hard + +"source-map@npm:^0.6.1": + version: 0.6.1 + resolution: "source-map@npm:0.6.1" + checksum: 59ce8640cf3f3124f64ac289012c2b8bd377c238e316fb323ea22fbfe83da07d81e000071d7242cad7a23cd91c7de98e4df8830ec3f133cb6133a5f6e9f67bc2 + languageName: node + linkType: hard + +"spawn-wrap@npm:^2.0.0": + version: 2.0.0 + resolution: "spawn-wrap@npm:2.0.0" + dependencies: + foreground-child: ^2.0.0 + is-windows: ^1.0.2 + make-dir: ^3.0.0 + rimraf: ^3.0.0 + signal-exit: ^3.0.2 + which: ^2.0.1 + checksum: 5a518e37620def6d516b86207482a4f76bcf3c37c57d8d886d9fa399b04e5668d11fd12817b178029b02002a5ebbd09010374307effa821ba39594042f0a2d96 + languageName: node + linkType: hard + +"sprintf-js@npm:~1.0.2": + version: 1.0.3 + resolution: "sprintf-js@npm:1.0.3" + checksum: 19d79aec211f09b99ec3099b5b2ae2f6e9cdefe50bc91ac4c69144b6d3928a640bb6ae5b3def70c2e85a2c3d9f5ec2719921e3a59d3ca3ef4b2fd1a4656a0df3 + languageName: node + linkType: hard + +"ssri@npm:^10.0.0": + version: 10.0.4 + resolution: "ssri@npm:10.0.4" + dependencies: + minipass: ^5.0.0 + checksum: fb14da9f8a72b04eab163eb13a9dda11d5962cd2317f85457c4e0b575e9a6e0e3a6a87b5bf122c75cb36565830cd5f263fb457571bf6f1587eb5f95d095d6165 + languageName: node + linkType: hard + +"string-width-cjs@npm:string-width@^4.2.0, string-width@npm:^1.0.2 || 2 || 3 || 4, string-width@npm:^4.1.0, string-width@npm:^4.2.0, string-width@npm:^4.2.3": + version: 4.2.3 + resolution: "string-width@npm:4.2.3" + dependencies: + emoji-regex: ^8.0.0 + is-fullwidth-code-point: ^3.0.0 + strip-ansi: ^6.0.1 + checksum: e52c10dc3fbfcd6c3a15f159f54a90024241d0f149cf8aed2982a2d801d2e64df0bf1dc351cf8e95c3319323f9f220c16e740b06faecd53e2462df1d2b5443fb + languageName: node + linkType: hard + +"string-width@npm:^5.0.1, string-width@npm:^5.1.2": + version: 5.1.2 + resolution: "string-width@npm:5.1.2" + dependencies: + eastasianwidth: ^0.2.0 + emoji-regex: ^9.2.2 + strip-ansi: ^7.0.1 + checksum: 7369deaa29f21dda9a438686154b62c2c5f661f8dda60449088f9f980196f7908fc39fdd1803e3e01541970287cf5deae336798337e9319a7055af89dafa7193 + languageName: node + linkType: hard + +"string_decoder@npm:^1.1.1": + version: 1.3.0 + resolution: "string_decoder@npm:1.3.0" + dependencies: + safe-buffer: ~5.2.0 + checksum: 8417646695a66e73aefc4420eb3b84cc9ffd89572861fe004e6aeb13c7bc00e2f616247505d2dbbef24247c372f70268f594af7126f43548565c68c117bdeb56 + languageName: node + linkType: hard + +"strip-ansi-cjs@npm:strip-ansi@^6.0.1, strip-ansi@npm:^6.0.0, strip-ansi@npm:^6.0.1": + version: 6.0.1 + resolution: "strip-ansi@npm:6.0.1" + dependencies: + ansi-regex: ^5.0.1 + checksum: f3cd25890aef3ba6e1a74e20896c21a46f482e93df4a06567cebf2b57edabb15133f1f94e57434e0a958d61186087b1008e89c94875d019910a213181a14fc8c + languageName: node + linkType: hard + +"strip-ansi@npm:^7.0.1": + version: 7.1.0 + resolution: "strip-ansi@npm:7.1.0" + dependencies: + ansi-regex: ^6.0.1 + checksum: 859c73fcf27869c22a4e4d8c6acfe690064659e84bef9458aa6d13719d09ca88dcfd40cbf31fd0be63518ea1a643fe070b4827d353e09533a5b0b9fd4553d64d + languageName: node + linkType: hard + +"strip-bom@npm:^4.0.0": + version: 4.0.0 + resolution: "strip-bom@npm:4.0.0" + checksum: 9dbcfbaf503c57c06af15fe2c8176fb1bf3af5ff65003851a102749f875a6dbe0ab3b30115eccf6e805e9d756830d3e40ec508b62b3f1ddf3761a20ebe29d3f3 + languageName: node + linkType: hard + +"strip-json-comments@npm:3.1.1, strip-json-comments@npm:^3.1.0, strip-json-comments@npm:^3.1.1": + version: 3.1.1 + resolution: "strip-json-comments@npm:3.1.1" + checksum: 492f73e27268f9b1c122733f28ecb0e7e8d8a531a6662efbd08e22cccb3f9475e90a1b82cab06a392f6afae6d2de636f977e231296400d0ec5304ba70f166443 + languageName: node + linkType: hard + +"supports-color@npm:8.1.1": + version: 8.1.1 + resolution: "supports-color@npm:8.1.1" + dependencies: + has-flag: ^4.0.0 + checksum: c052193a7e43c6cdc741eb7f378df605636e01ad434badf7324f17fb60c69a880d8d8fcdcb562cf94c2350e57b937d7425ab5b8326c67c2adc48f7c87c1db406 + languageName: node + linkType: hard + +"supports-color@npm:^5.3.0, supports-color@npm:^5.5.0": + version: 5.5.0 + resolution: "supports-color@npm:5.5.0" + dependencies: + has-flag: ^3.0.0 + checksum: 95f6f4ba5afdf92f495b5a912d4abee8dcba766ae719b975c56c084f5004845f6f5a5f7769f52d53f40e21952a6d87411bafe34af4a01e65f9926002e38e1dac + languageName: node + linkType: hard + +"supports-color@npm:^7.1.0": + version: 7.2.0 + resolution: "supports-color@npm:7.2.0" + dependencies: + has-flag: ^4.0.0 + checksum: 3dda818de06ebbe5b9653e07842d9479f3555ebc77e9a0280caf5a14fb877ffee9ed57007c3b78f5a6324b8dbeec648d9e97a24e2ed9fdb81ddc69ea07100f4a + languageName: node + linkType: hard + +"tar@npm:^6.1.11, tar@npm:^6.1.2": + version: 6.1.15 + resolution: "tar@npm:6.1.15" + dependencies: + chownr: ^2.0.0 + fs-minipass: ^2.0.0 + minipass: ^5.0.0 + minizlib: ^2.1.1 + mkdirp: ^1.0.3 + yallist: ^4.0.0 + checksum: f23832fceeba7578bf31907aac744ae21e74a66f4a17a9e94507acf460e48f6db598c7023882db33bab75b80e027c21f276d405e4a0322d58f51c7088d428268 + languageName: node + linkType: hard + +"test-exclude@npm:^6.0.0": + version: 6.0.0 + resolution: "test-exclude@npm:6.0.0" + dependencies: + "@istanbuljs/schema": ^0.1.2 + glob: ^7.1.4 + minimatch: ^3.0.4 + checksum: 3b34a3d77165a2cb82b34014b3aba93b1c4637a5011807557dc2f3da826c59975a5ccad765721c4648b39817e3472789f9b0fa98fc854c5c1c7a1e632aacdc28 + languageName: node + linkType: hard + +"text-table@npm:^0.2.0": + version: 0.2.0 + resolution: "text-table@npm:0.2.0" + checksum: b6937a38c80c7f84d9c11dd75e49d5c44f71d95e810a3250bd1f1797fc7117c57698204adf676b71497acc205d769d65c16ae8fa10afad832ae1322630aef10a + languageName: node + linkType: hard + +"to-fast-properties@npm:^2.0.0": + version: 2.0.0 + resolution: "to-fast-properties@npm:2.0.0" + checksum: be2de62fe58ead94e3e592680052683b1ec986c72d589e7b21e5697f8744cdbf48c266fa72f6c15932894c10187b5f54573a3bcf7da0bfd964d5caf23d436168 + languageName: node + linkType: hard + +"to-regex-range@npm:^5.0.1": + version: 5.0.1 + resolution: "to-regex-range@npm:5.0.1" + dependencies: + is-number: ^7.0.0 + checksum: f76fa01b3d5be85db6a2a143e24df9f60dd047d151062d0ba3df62953f2f697b16fe5dad9b0ac6191c7efc7b1d9dcaa4b768174b7b29da89d4428e64bc0a20ed + languageName: node + linkType: hard + +"ts-node@npm:^10.9.1": + version: 10.9.1 + resolution: "ts-node@npm:10.9.1" + dependencies: + "@cspotcode/source-map-support": ^0.8.0 + "@tsconfig/node10": ^1.0.7 + "@tsconfig/node12": ^1.0.7 + "@tsconfig/node14": ^1.0.0 + "@tsconfig/node16": ^1.0.2 + acorn: ^8.4.1 + acorn-walk: ^8.1.1 + arg: ^4.1.0 + create-require: ^1.1.0 + diff: ^4.0.1 + make-error: ^1.1.1 + v8-compile-cache-lib: ^3.0.1 + yn: 3.1.1 + peerDependencies: + "@swc/core": ">=1.2.50" + "@swc/wasm": ">=1.2.50" + "@types/node": "*" + typescript: ">=2.7" + peerDependenciesMeta: + "@swc/core": + optional: true + "@swc/wasm": + optional: true + bin: + ts-node: dist/bin.js + ts-node-cwd: dist/bin-cwd.js + ts-node-esm: dist/bin-esm.js + ts-node-script: dist/bin-script.js + ts-node-transpile-only: dist/bin-transpile.js + ts-script: dist/bin-script-deprecated.js + checksum: 090adff1302ab20bd3486e6b4799e90f97726ed39e02b39e566f8ab674fd5bd5f727f43615debbfc580d33c6d9d1c6b1b3ce7d8e3cca3e20530a145ffa232c35 + languageName: node + linkType: hard + +"tslib@npm:^1.8.1": + version: 1.14.1 + resolution: "tslib@npm:1.14.1" + checksum: dbe628ef87f66691d5d2959b3e41b9ca0045c3ee3c7c7b906cc1e328b39f199bb1ad9e671c39025bd56122ac57dfbf7385a94843b1cc07c60a4db74795829acd + languageName: node + linkType: hard + +"tslib@npm:^2.6.0": + version: 2.6.0 + resolution: "tslib@npm:2.6.0" + checksum: c01066038f950016a18106ddeca4649b4d76caa76ec5a31e2a26e10586a59fceb4ee45e96719bf6c715648e7c14085a81fee5c62f7e9ebee68e77a5396e5538f + languageName: node + linkType: hard + +"tsutils@npm:^3.21.0": + version: 3.21.0 + resolution: "tsutils@npm:3.21.0" + dependencies: + tslib: ^1.8.1 + peerDependencies: + typescript: ">=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta" + checksum: 1843f4c1b2e0f975e08c4c21caa4af4f7f65a12ac1b81b3b8489366826259323feb3fc7a243123453d2d1a02314205a7634e048d4a8009921da19f99755cdc48 + languageName: node + linkType: hard + +"type-check@npm:^0.4.0, type-check@npm:~0.4.0": + version: 0.4.0 + resolution: "type-check@npm:0.4.0" + dependencies: + prelude-ls: ^1.2.1 + checksum: ec688ebfc9c45d0c30412e41ca9c0cdbd704580eb3a9ccf07b9b576094d7b86a012baebc95681999dd38f4f444afd28504cb3a89f2ef16b31d4ab61a0739025a + languageName: node + linkType: hard + +"type-detect@npm:4.0.8": + version: 4.0.8 + resolution: "type-detect@npm:4.0.8" + checksum: 62b5628bff67c0eb0b66afa371bd73e230399a8d2ad30d852716efcc4656a7516904570cd8631a49a3ce57c10225adf5d0cbdcb47f6b0255fe6557c453925a15 + languageName: node + linkType: hard + +"type-fest@npm:^0.20.2": + version: 0.20.2 + resolution: "type-fest@npm:0.20.2" + checksum: 4fb3272df21ad1c552486f8a2f8e115c09a521ad7a8db3d56d53718d0c907b62c6e9141ba5f584af3f6830d0872c521357e512381f24f7c44acae583ad517d73 + languageName: node + linkType: hard + +"type-fest@npm:^0.8.0": + version: 0.8.1 + resolution: "type-fest@npm:0.8.1" + checksum: d61c4b2eba24009033ae4500d7d818a94fd6d1b481a8111612ee141400d5f1db46f199c014766b9fa9b31a6a7374d96fc748c6d688a78a3ce5a33123839becb7 + languageName: node + linkType: hard + +"typedarray-to-buffer@npm:^3.1.5": + version: 3.1.5 + resolution: "typedarray-to-buffer@npm:3.1.5" + dependencies: + is-typedarray: ^1.0.0 + checksum: 99c11aaa8f45189fcfba6b8a4825fd684a321caa9bd7a76a27cf0c7732c174d198b99f449c52c3818107430b5f41c0ccbbfb75cb2ee3ca4a9451710986d61a60 + languageName: node + linkType: hard + +"typescript@npm:^4.9.5": + version: 4.9.5 + resolution: "typescript@npm:4.9.5" + bin: + tsc: bin/tsc + tsserver: bin/tsserver + checksum: ee000bc26848147ad423b581bd250075662a354d84f0e06eb76d3b892328d8d4440b7487b5a83e851b12b255f55d71835b008a66cbf8f255a11e4400159237db + languageName: node + linkType: hard + +"typescript@patch:typescript@^4.9.5#~builtin": + version: 4.9.5 + resolution: "typescript@patch:typescript@npm%3A4.9.5#~builtin::version=4.9.5&hash=493e53" + bin: + tsc: bin/tsc + tsserver: bin/tsserver + checksum: 2eee5c37cad4390385db5db5a8e81470e42e8f1401b0358d7390095d6f681b410f2c4a0c496c6ff9ebd775423c7785cdace7bcdad76c7bee283df3d9718c0f20 + languageName: node + linkType: hard + +"unique-filename@npm:^3.0.0": + version: 3.0.0 + resolution: "unique-filename@npm:3.0.0" + dependencies: + unique-slug: ^4.0.0 + checksum: 8e2f59b356cb2e54aab14ff98a51ac6c45781d15ceaab6d4f1c2228b780193dc70fae4463ce9e1df4479cb9d3304d7c2043a3fb905bdeca71cc7e8ce27e063df + languageName: node + linkType: hard + +"unique-slug@npm:^4.0.0": + version: 4.0.0 + resolution: "unique-slug@npm:4.0.0" + dependencies: + imurmurhash: ^0.1.4 + checksum: 0884b58365af59f89739e6f71e3feacb5b1b41f2df2d842d0757933620e6de08eff347d27e9d499b43c40476cbaf7988638d3acb2ffbcb9d35fd035591adfd15 + languageName: node + linkType: hard + +"update-browserslist-db@npm:^1.0.11": + version: 1.0.11 + resolution: "update-browserslist-db@npm:1.0.11" + dependencies: + escalade: ^3.1.1 + picocolors: ^1.0.0 + peerDependencies: + browserslist: ">= 4.21.0" + bin: + update-browserslist-db: cli.js + checksum: b98327518f9a345c7cad5437afae4d2ae7d865f9779554baf2a200fdf4bac4969076b679b1115434bd6557376bdd37ca7583d0f9b8f8e302d7d4cc1e91b5f231 + languageName: node + linkType: hard + +"uri-js@npm:^4.2.2": + version: 4.4.1 + resolution: "uri-js@npm:4.4.1" + dependencies: + punycode: ^2.1.0 + checksum: 7167432de6817fe8e9e0c9684f1d2de2bb688c94388f7569f7dbdb1587c9f4ca2a77962f134ec90be0cc4d004c939ff0d05acc9f34a0db39a3c797dada262633 + languageName: node + linkType: hard + +"util-deprecate@npm:^1.0.1": + version: 1.0.2 + resolution: "util-deprecate@npm:1.0.2" + checksum: 474acf1146cb2701fe3b074892217553dfcf9a031280919ba1b8d651a068c9b15d863b7303cb15bd00a862b498e6cf4ad7b4a08fb134edd5a6f7641681cb54a2 + languageName: node + linkType: hard + +"uuid@npm:^8.3.2": + version: 8.3.2 + resolution: "uuid@npm:8.3.2" + bin: + uuid: dist/bin/uuid + checksum: 5575a8a75c13120e2f10e6ddc801b2c7ed7d8f3c8ac22c7ed0c7b2ba6383ec0abda88c905085d630e251719e0777045ae3236f04c812184b7c765f63a70e58df + languageName: node + linkType: hard + +"v8-compile-cache-lib@npm:^3.0.1": + version: 3.0.1 + resolution: "v8-compile-cache-lib@npm:3.0.1" + checksum: 78089ad549e21bcdbfca10c08850022b22024cdcc2da9b168bcf5a73a6ed7bf01a9cebb9eac28e03cd23a684d81e0502797e88f3ccd27a32aeab1cfc44c39da0 + languageName: node + linkType: hard + +"which-module@npm:^2.0.0": + version: 2.0.1 + resolution: "which-module@npm:2.0.1" + checksum: 1967b7ce17a2485544a4fdd9063599f0f773959cca24176dbe8f405e55472d748b7c549cd7920ff6abb8f1ab7db0b0f1b36de1a21c57a8ff741f4f1e792c52be + languageName: node + linkType: hard + +"which@npm:2.0.2, which@npm:^2.0.1, which@npm:^2.0.2": + version: 2.0.2 + resolution: "which@npm:2.0.2" + dependencies: + isexe: ^2.0.0 + bin: + node-which: ./bin/node-which + checksum: 1a5c563d3c1b52d5f893c8b61afe11abc3bab4afac492e8da5bde69d550de701cf9806235f20a47b5c8fa8a1d6a9135841de2596535e998027a54589000e66d1 + languageName: node + linkType: hard + +"wide-align@npm:^1.1.5": + version: 1.1.5 + resolution: "wide-align@npm:1.1.5" + dependencies: + string-width: ^1.0.2 || 2 || 3 || 4 + checksum: d5fc37cd561f9daee3c80e03b92ed3e84d80dde3365a8767263d03dacfc8fa06b065ffe1df00d8c2a09f731482fcacae745abfbb478d4af36d0a891fad4834d3 + languageName: node + linkType: hard + +"workerpool@npm:6.2.0": + version: 6.2.0 + resolution: "workerpool@npm:6.2.0" + checksum: 3493b4f0ef979a23d2c1583d7ef85f62fc9463cc02f82829d3e7e663b517f8ae9707da0249b382e46ac58986deb0ca2232ee1081713741211bda9254b429c9bb + languageName: node + linkType: hard + +"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0, wrap-ansi@npm:^7.0.0": + version: 7.0.0 + resolution: "wrap-ansi@npm:7.0.0" + dependencies: + ansi-styles: ^4.0.0 + string-width: ^4.1.0 + strip-ansi: ^6.0.0 + checksum: a790b846fd4505de962ba728a21aaeda189b8ee1c7568ca5e817d85930e06ef8d1689d49dbf0e881e8ef84436af3a88bc49115c2e2788d841ff1b8b5b51a608b + languageName: node + linkType: hard + +"wrap-ansi@npm:^6.2.0": + version: 6.2.0 + resolution: "wrap-ansi@npm:6.2.0" + dependencies: + ansi-styles: ^4.0.0 + string-width: ^4.1.0 + strip-ansi: ^6.0.0 + checksum: 6cd96a410161ff617b63581a08376f0cb9162375adeb7956e10c8cd397821f7eb2a6de24eb22a0b28401300bf228c86e50617cd568209b5f6775b93c97d2fe3a + languageName: node + linkType: hard + +"wrap-ansi@npm:^8.1.0": + version: 8.1.0 + resolution: "wrap-ansi@npm:8.1.0" + dependencies: + ansi-styles: ^6.1.0 + string-width: ^5.0.1 + strip-ansi: ^7.0.1 + checksum: 371733296dc2d616900ce15a0049dca0ef67597d6394c57347ba334393599e800bab03c41d4d45221b6bc967b8c453ec3ae4749eff3894202d16800fdfe0e238 + languageName: node + linkType: hard + +"wrappy@npm:1": + version: 1.0.2 + resolution: "wrappy@npm:1.0.2" + checksum: 159da4805f7e84a3d003d8841557196034155008f817172d4e986bd591f74aa82aa7db55929a54222309e01079a65a92a9e6414da5a6aa4b01ee44a511ac3ee5 + languageName: node + linkType: hard + +"write-file-atomic@npm:^3.0.0": + version: 3.0.3 + resolution: "write-file-atomic@npm:3.0.3" + dependencies: + imurmurhash: ^0.1.4 + is-typedarray: ^1.0.0 + signal-exit: ^3.0.2 + typedarray-to-buffer: ^3.1.5 + checksum: c55b24617cc61c3a4379f425fc62a386cc51916a9b9d993f39734d005a09d5a4bb748bc251f1304e7abd71d0a26d339996c275955f527a131b1dcded67878280 + languageName: node + linkType: hard + +"y18n@npm:^4.0.0": + version: 4.0.3 + resolution: "y18n@npm:4.0.3" + checksum: 014dfcd9b5f4105c3bb397c1c8c6429a9df004aa560964fb36732bfb999bfe83d45ae40aeda5b55d21b1ee53d8291580a32a756a443e064317953f08025b1aa4 + languageName: node + linkType: hard + +"y18n@npm:^5.0.5": + version: 5.0.8 + resolution: "y18n@npm:5.0.8" + checksum: 54f0fb95621ee60898a38c572c515659e51cc9d9f787fb109cef6fde4befbe1c4602dc999d30110feee37456ad0f1660fa2edcfde6a9a740f86a290999550d30 + languageName: node + linkType: hard + +"yallist@npm:^3.0.2": + version: 3.1.1 + resolution: "yallist@npm:3.1.1" + checksum: 48f7bb00dc19fc635a13a39fe547f527b10c9290e7b3e836b9a8f1ca04d4d342e85714416b3c2ab74949c9c66f9cebb0473e6bc353b79035356103b47641285d + languageName: node + linkType: hard + +"yallist@npm:^4.0.0": + version: 4.0.0 + resolution: "yallist@npm:4.0.0" + checksum: 343617202af32df2a15a3be36a5a8c0c8545208f3d3dfbc6bb7c3e3b7e8c6f8e7485432e4f3b88da3031a6e20afa7c711eded32ddfb122896ac5d914e75848d5 + languageName: node + linkType: hard + +"yargs-parser@npm:20.2.4": + version: 20.2.4 + resolution: "yargs-parser@npm:20.2.4" + checksum: d251998a374b2743a20271c2fd752b9fbef24eb881d53a3b99a7caa5e8227fcafd9abf1f345ac5de46435821be25ec12189a11030c12ee6481fef6863ed8b924 + languageName: node + linkType: hard + +"yargs-parser@npm:^18.1.2": + version: 18.1.3 + resolution: "yargs-parser@npm:18.1.3" + dependencies: + camelcase: ^5.0.0 + decamelize: ^1.2.0 + checksum: 60e8c7d1b85814594d3719300ecad4e6ae3796748b0926137bfec1f3042581b8646d67e83c6fc80a692ef08b8390f21ddcacb9464476c39bbdf52e34961dd4d9 + languageName: node + linkType: hard + +"yargs-parser@npm:^20.2.2": + version: 20.2.9 + resolution: "yargs-parser@npm:20.2.9" + checksum: 8bb69015f2b0ff9e17b2c8e6bfe224ab463dd00ca211eece72a4cd8a906224d2703fb8a326d36fdd0e68701e201b2a60ed7cf81ce0fd9b3799f9fe7745977ae3 + languageName: node + linkType: hard + +"yargs-unparser@npm:2.0.0": + version: 2.0.0 + resolution: "yargs-unparser@npm:2.0.0" + dependencies: + camelcase: ^6.0.0 + decamelize: ^4.0.0 + flat: ^5.0.2 + is-plain-obj: ^2.1.0 + checksum: 68f9a542c6927c3768c2f16c28f71b19008710abd6b8f8efbac6dcce26bbb68ab6503bed1d5994bdbc2df9a5c87c161110c1dfe04c6a3fe5c6ad1b0e15d9a8a3 + languageName: node + linkType: hard + +"yargs@npm:16.2.0": + version: 16.2.0 + resolution: "yargs@npm:16.2.0" + dependencies: + cliui: ^7.0.2 + escalade: ^3.1.1 + get-caller-file: ^2.0.5 + require-directory: ^2.1.1 + string-width: ^4.2.0 + y18n: ^5.0.5 + yargs-parser: ^20.2.2 + checksum: b14afbb51e3251a204d81937c86a7e9d4bdbf9a2bcee38226c900d00f522969ab675703bee2a6f99f8e20103f608382936034e64d921b74df82b63c07c5e8f59 + languageName: node + linkType: hard + +"yargs@npm:^15.0.2": + version: 15.4.1 + resolution: "yargs@npm:15.4.1" + dependencies: + cliui: ^6.0.0 + decamelize: ^1.2.0 + find-up: ^4.1.0 + get-caller-file: ^2.0.1 + require-directory: ^2.1.1 + require-main-filename: ^2.0.0 + set-blocking: ^2.0.0 + string-width: ^4.2.0 + which-module: ^2.0.0 + y18n: ^4.0.0 + yargs-parser: ^18.1.2 + checksum: 40b974f508d8aed28598087720e086ecd32a5fd3e945e95ea4457da04ee9bdb8bdd17fd91acff36dc5b7f0595a735929c514c40c402416bbb87c03f6fb782373 + languageName: node + linkType: hard + +"yn@npm:3.1.1": + version: 3.1.1 + resolution: "yn@npm:3.1.1" + checksum: 2c487b0e149e746ef48cda9f8bad10fc83693cd69d7f9dcd8be4214e985de33a29c9e24f3c0d6bcf2288427040a8947406ab27f7af67ee9456e6b84854f02dd6 + languageName: node + linkType: hard + +"yocto-queue@npm:^0.1.0": + version: 0.1.0 + resolution: "yocto-queue@npm:0.1.0" + checksum: f77b3d8d00310def622123df93d4ee654fc6a0096182af8bd60679ddcdfb3474c56c6c7190817c84a2785648cdee9d721c0154eb45698c62176c322fb46fc700 + languageName: node + linkType: hard From 31a4aa592135a4704ba33530c0660cd82fca7d03 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Mon, 10 Jul 2023 14:29:05 +0100 Subject: [PATCH 111/146] run tests in parallel --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 2f1c8d53..25cfd6d3 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -57,7 +57,7 @@ workflows: - build - integration_test: requires: - - unit_test + - build notify: webhooks: From d80fc6f1746e870315a3432673d36d314707d243 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Mon, 10 Jul 2023 16:50:09 +0100 Subject: [PATCH 112/146] Update create conversations endpoint with 2.6 typing --- README.md | 2 +- lib/conversation.ts | 7 +++-- package.json | 4 +-- test/integration/conversations.test.ts | 30 +++++++++++++++++- test/integration/integration.test.ts | 3 +- test/unit/conversation.test.ts | 42 ++++++++++++++++++++++++-- 6 files changed, 78 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index c55b9a98..3d004d20 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,7 @@ ## Breaking changes -The Node SDK has been updated to support latest API version (2.5). The update also contains requested features, such like Typescript support. You can find more information on how-to migrate and what has changed in the [migration guide](https://github.com/intercom/intercom-node/wiki/Migration-guide). +The Node SDK has been updated to support latest API version (2.6). The update also contains requested features, such like Typescript support. You can find more information on how-to migrate and what has changed in the [migration guide](https://github.com/intercom/intercom-node/wiki/Migration-guide). ## Installation diff --git a/lib/conversation.ts b/lib/conversation.ts index 884169c6..060e96e9 100644 --- a/lib/conversation.ts +++ b/lib/conversation.ts @@ -17,11 +17,11 @@ export default class Conversation { constructor(private readonly client: Client) { this.client = client; } - create({ userId, body }: CreateConversationData) { + create({ userId, type = ContactType.USER, body }: CreateConversationData) { const requestData: CreateConversationRequest = { from: { id: userId, - type: 'user', + type, }, body, }; @@ -288,7 +288,7 @@ export default class Conversation { interface CreateConversationRequest { from: { - type: 'user' | string; + type: ContactType; id: string; }; body: string; @@ -296,6 +296,7 @@ interface CreateConversationRequest { interface CreateConversationData { userId: string; + type?: ContactType; body: string; } // diff --git a/package.json b/package.json index f3bbfe81..2b3b392e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "4.0.0", + "version": "4.0.1", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", @@ -58,4 +58,4 @@ }, "license": "Apache-2.0", "packageManager": "yarn@3.1.1" -} +} \ No newline at end of file diff --git a/test/integration/conversations.test.ts b/test/integration/conversations.test.ts index 04fc43b9..65769052 100644 --- a/test/integration/conversations.test.ts +++ b/test/integration/conversations.test.ts @@ -7,6 +7,7 @@ import { ContactObject, ConversationObject, MessageObject, + ContactType, } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; @@ -15,6 +16,7 @@ import { randomString } from './utils/random'; describe('Conversations', () => { let user: ContactObject; let secondUser: ContactObject; + let leadUser: ContactObject; let createdConversation: MessageObject; let foundConversation: ConversationObject; @@ -38,12 +40,28 @@ describe('Conversations', () => { name: 'Babushka Boy', email: 'babushka_boy@bababooey.com', }); + leadUser = await client.contacts.createLead({ + name: 'Babushka Lead', + email: 'babushka_lead@bababooey.com', + }); + }); + + it('create conversation with user as default', async () => { + const response = await client.conversations.create({ + userId: user.id, + body: 'Raz-dwa-try kalyna, czorniawaja diwczyna', + }); + + createdConversation = response; + + assert.notEqual(response, undefined); }); - it('create', async () => { + it('create conversation with user', async () => { const response = await client.conversations.create({ userId: user.id, body: 'Raz-dwa-try kalyna, czorniawaja diwczyna', + type: ContactType.USER, }); createdConversation = response; @@ -51,6 +69,16 @@ describe('Conversations', () => { assert.notEqual(response, undefined); }); + it('create conversation with lead', async () => { + const response = await client.conversations.create({ + userId: leadUser.id, + body: 'Raz-dwa-try kalyna, czorniawaja diwczyna', + type: ContactType.LEAD, + }); + + assert.notEqual(response, undefined); + }); + it('find - by id', async () => { const response = await client.conversations.find({ id: createdConversation.conversation_id as string, diff --git a/test/integration/integration.test.ts b/test/integration/integration.test.ts index 30141078..d576355a 100644 --- a/test/integration/integration.test.ts +++ b/test/integration/integration.test.ts @@ -1,4 +1,4 @@ -import { Client, ContactObject, MessageObject } from '../../lib'; +import { Client, ContactObject, ContactType, MessageObject } from '../../lib'; import assert from 'assert'; import { token } from './utils/config'; import { randomInt } from 'crypto'; @@ -66,6 +66,7 @@ describe('Integration between Contact, Conversation, Company and Tag APIs', () = const response = await client.conversations.create({ userId: contact.id, body: 'Welcome to the club, buddy!', + type: ContactType.USER, }); conversation = response; diff --git a/test/unit/conversation.test.ts b/test/unit/conversation.test.ts index 95d642d1..3a3c628d 100644 --- a/test/unit/conversation.test.ts +++ b/test/unit/conversation.test.ts @@ -1,5 +1,5 @@ import assert from 'assert'; -import { Client } from '../../lib'; +import { Client, ContactType } from '../../lib'; import nock from 'nock'; import { AssignToConversationMessageType, @@ -16,7 +16,7 @@ import { import { Operators } from '../../lib/common/common.types'; describe('conversations', () => { - it('should create a conversation', async () => { + it('should create a conversation from a user', async () => { const id = '536e564f316c83104c000020'; const message = { @@ -46,6 +46,44 @@ describe('conversations', () => { const response = await client.conversations.create({ userId: id, + type: ContactType.USER, + body: message.body, + }); + + assert.deepStrictEqual(expectedReply, response); + }); + + it('should create a conversation from a lead', async () => { + const id = '536e564f316c83104c000020'; + + const message = { + from: { + type: 'lead', + id, + }, + body: 'Hello darkness my old friend', + }; + + const expectedReply = { + type: 'user_message', + id: '2001', + created_at: 1401917202, + body: 'Hello darkness my old friend', + message_type: 'inapp', + conversation_id: '36000324324', + }; + + nock('https://api.intercom.io') + .post('/conversations', message) + .reply(200, expectedReply); + + const client = new Client({ + usernameAuth: { username: 'foo', password: 'bar' }, + }); + + const response = await client.conversations.create({ + userId: id, + type: ContactType.LEAD, body: message.body, }); From 7aadf4d06ba61d83c55b7658d118b18dbdbb03fb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 11 Jul 2023 00:58:43 +0000 Subject: [PATCH 113/146] Bump semver from 6.3.0 to 6.3.1 Bumps [semver](https://github.com/npm/node-semver) from 6.3.0 to 6.3.1. - [Release notes](https://github.com/npm/node-semver/releases) - [Changelog](https://github.com/npm/node-semver/blob/v6.3.1/CHANGELOG.md) - [Commits](https://github.com/npm/node-semver/compare/v6.3.0...v6.3.1) --- updated-dependencies: - dependency-name: semver dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/yarn.lock b/yarn.lock index 0b696776..a805f47d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3215,11 +3215,11 @@ __metadata: linkType: hard "semver@npm:^6.0.0, semver@npm:^6.3.0": - version: 6.3.0 - resolution: "semver@npm:6.3.0" + version: 6.3.1 + resolution: "semver@npm:6.3.1" bin: - semver: ./bin/semver.js - checksum: 1b26ecf6db9e8292dd90df4e781d91875c0dcc1b1909e70f5d12959a23c7eebb8f01ea581c00783bbee72ceeaad9505797c381756326073850dc36ed284b21b9 + semver: bin/semver.js + checksum: ae47d06de28836adb9d3e25f22a92943477371292d9b665fb023fae278d345d508ca1958232af086d85e0155aee22e313e100971898bbb8d5d89b8b1d4054ca2 languageName: node linkType: hard From b08f93a8127006c5042763617f050c78910f361a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 29 Nov 2023 14:32:29 +0000 Subject: [PATCH 114/146] Bump axios from 0.24.0 to 1.6.0 (#388) --- package.json | 2 +- yarn.lock | 79 +++++++++++++++++++++++++++++++++++++++++++++------- 2 files changed, 70 insertions(+), 11 deletions(-) diff --git a/package.json b/package.json index 358dedda..e25a5f40 100644 --- a/package.json +++ b/package.json @@ -18,7 +18,7 @@ "api" ], "dependencies": { - "axios": "^0.24.0", + "axios": "^1.6.0", "htmlencode": "^0.0.4", "lodash": "^4.17.21" }, diff --git a/yarn.lock b/yarn.lock index ac7cb107..9b92e6c9 100644 --- a/yarn.lock +++ b/yarn.lock @@ -939,12 +939,21 @@ __metadata: languageName: node linkType: hard -"axios@npm:^0.24.0": - version: 0.24.0 - resolution: "axios@npm:0.24.0" +"asynckit@npm:^0.4.0": + version: 0.4.0 + resolution: "asynckit@npm:0.4.0" + checksum: 7b78c451df768adba04e2d02e63e2d0bf3b07adcd6e42b4cf665cb7ce899bedd344c69a1dcbce355b5f972d597b25aaa1c1742b52cffd9caccb22f348114f6be + languageName: node + linkType: hard + +"axios@npm:^1.6.0": + version: 1.6.1 + resolution: "axios@npm:1.6.1" dependencies: - follow-redirects: ^1.14.4 - checksum: 468cf496c08a6aadfb7e699bebdac02851e3043d4e7d282350804ea8900e30d368daa6e3cd4ab83b8ddb5a3b1e17a5a21ada13fc9cebd27b74828f47a4236316 + follow-redirects: ^1.15.0 + form-data: ^4.0.0 + proxy-from-env: ^1.1.0 + checksum: 573f03f59b7487d54551b16f5e155d1d130ad4864ed32d1da93d522b78a57123b34e3bde37f822a65ee297e79f1db840f9ad6514addff50d3cbf5caeed39e8dc languageName: node linkType: hard @@ -1188,6 +1197,15 @@ __metadata: languageName: node linkType: hard +"combined-stream@npm:^1.0.8": + version: 1.0.8 + resolution: "combined-stream@npm:1.0.8" + dependencies: + delayed-stream: ~1.0.0 + checksum: 49fa4aeb4916567e33ea81d088f6584749fc90c7abec76fd516bf1c5aa5c79f3584b5ba3de6b86d26ddd64bae5329c4c7479343250cfe71c75bb366eae53bb7c + languageName: node + linkType: hard + "commondir@npm:^1.0.1": version: 1.0.1 resolution: "commondir@npm:1.0.1" @@ -1288,6 +1306,13 @@ __metadata: languageName: node linkType: hard +"delayed-stream@npm:~1.0.0": + version: 1.0.0 + resolution: "delayed-stream@npm:1.0.0" + checksum: 46fe6e83e2cb1d85ba50bd52803c68be9bd953282fa7096f51fc29edd5d67ff84ff753c51966061e5ba7cb5e47ef6d36a91924eddb7f3f3483b1c560f77a0020 + languageName: node + linkType: hard + "delegates@npm:^1.0.0": version: 1.0.0 resolution: "delegates@npm:1.0.0" @@ -1699,13 +1724,13 @@ __metadata: languageName: node linkType: hard -"follow-redirects@npm:^1.14.4": - version: 1.15.2 - resolution: "follow-redirects@npm:1.15.2" +"follow-redirects@npm:^1.15.0": + version: 1.15.3 + resolution: "follow-redirects@npm:1.15.3" peerDependenciesMeta: debug: optional: true - checksum: faa66059b66358ba65c234c2f2a37fcec029dc22775f35d9ad6abac56003268baf41e55f9ee645957b32c7d9f62baf1f0b906e68267276f54ec4b4c597c2b190 + checksum: 584da22ec5420c837bd096559ebfb8fe69d82512d5585004e36a3b4a6ef6d5905780e0c74508c7b72f907d1fa2b7bd339e613859e9c304d0dc96af2027fd0231 languageName: node linkType: hard @@ -1729,6 +1754,17 @@ __metadata: languageName: node linkType: hard +"form-data@npm:^4.0.0": + version: 4.0.0 + resolution: "form-data@npm:4.0.0" + dependencies: + asynckit: ^0.4.0 + combined-stream: ^1.0.8 + mime-types: ^2.1.12 + checksum: 01135bf8675f9d5c61ff18e2e2932f719ca4de964e3be90ef4c36aacfc7b9cb2fceb5eca0b7e0190e3383fe51c5b37f4cb80b62ca06a99aaabfcfd6ac7c9328c + languageName: node + linkType: hard + "fromentries@npm:^1.2.0": version: 1.3.2 resolution: "fromentries@npm:1.3.2" @@ -2088,7 +2124,7 @@ __metadata: "@types/sinon": ^10.0.15 "@typescript-eslint/eslint-plugin": ^5.61.0 "@typescript-eslint/parser": ^5.61.0 - axios: ^0.24.0 + axios: ^1.6.0 eslint: ^8.44.0 eslint-config-prettier: ^8.8.0 eslint-plugin-no-only-tests: ^2.6.0 @@ -2541,6 +2577,22 @@ __metadata: languageName: node linkType: hard +"mime-db@npm:1.52.0": + version: 1.52.0 + resolution: "mime-db@npm:1.52.0" + checksum: 0d99a03585f8b39d68182803b12ac601d9c01abfa28ec56204fa330bc9f3d1c5e14beb049bafadb3dbdf646dfb94b87e24d4ec7b31b7279ef906a8ea9b6a513f + languageName: node + linkType: hard + +"mime-types@npm:^2.1.12": + version: 2.1.35 + resolution: "mime-types@npm:2.1.35" + dependencies: + mime-db: 1.52.0 + checksum: 89a5b7f1def9f3af5dad6496c5ed50191ae4331cc5389d7c521c8ad28d5fdad2d06fd81baf38fed813dc4e46bb55c8145bb0ff406330818c9cf712fb2e9b3836 + languageName: node + linkType: hard + "minimatch@npm:4.2.1": version: 4.2.1 resolution: "minimatch@npm:4.2.1" @@ -3086,6 +3138,13 @@ __metadata: languageName: node linkType: hard +"proxy-from-env@npm:^1.1.0": + version: 1.1.0 + resolution: "proxy-from-env@npm:1.1.0" + checksum: ed7fcc2ba0a33404958e34d95d18638249a68c430e30fcb6c478497d72739ba64ce9810a24f53a7d921d0c065e5b78e3822759800698167256b04659366ca4d4 + languageName: node + linkType: hard + "punycode@npm:^2.1.0": version: 2.3.0 resolution: "punycode@npm:2.3.0" From 87cde318944205d1e36cebd77ce6bb33c88f9f29 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Tue, 12 Dec 2023 14:39:29 +0000 Subject: [PATCH 115/146] Fix tests on Node SDK (#392) * Remove tagId parameter from companies test * Fix admin filtering in conversations.test.ts * Refactor adminId assignment in messages.test.ts * Disable create and update tests for dataAttributes --- test/integration/companies.test.ts | 1 - test/integration/conversations.test.ts | 9 +++++---- test/integration/dataAttributes.test.ts | 6 ++++-- test/integration/messages.test.ts | 6 ++++-- 4 files changed, 13 insertions(+), 9 deletions(-) diff --git a/test/integration/companies.test.ts b/test/integration/companies.test.ts index 24ab0b79..0be07f80 100644 --- a/test/integration/companies.test.ts +++ b/test/integration/companies.test.ts @@ -69,7 +69,6 @@ describe('Companies', () => { page: 1, perPage: 35, order: Order.DESC, - tagId: '7882526', }); assert.notEqual(response, undefined); diff --git a/test/integration/conversations.test.ts b/test/integration/conversations.test.ts index 65769052..7954e926 100644 --- a/test/integration/conversations.test.ts +++ b/test/integration/conversations.test.ts @@ -28,9 +28,10 @@ describe('Conversations', () => { before(async () => { const admins = await client.admins.list(); - adminId = admins.admins[0].id; - anotherAdminId = admins.admins[1].id; - + const adminList = admins.admins.filter((admin) => admin.has_inbox_seat); + // Only admins with inbox seat can interact with conversations. + adminId = adminList[0].id; + anotherAdminId = adminList[1].id; user = await client.contacts.createUser({ externalId: randomString(), name: 'Baba Booey', @@ -174,7 +175,7 @@ describe('Conversations', () => { const response = await client.conversations.redactConversationPart({ conversationId: foundConversation.id, conversationPartId: - foundConversation.conversation_parts.conversation_parts[0].id, + foundConversation.conversation_parts.conversation_parts[2].id, type: RedactConversationPartType.CONVERSATION_PART, }); diff --git a/test/integration/dataAttributes.test.ts b/test/integration/dataAttributes.test.ts index d359a0c8..d0b055df 100644 --- a/test/integration/dataAttributes.test.ts +++ b/test/integration/dataAttributes.test.ts @@ -8,7 +8,9 @@ describe('Data Attributes', () => { const client = new Client({ tokenAuth: { token } }); - it('create', async () => { + xit('create', async () => { + // The workspace we test on has hit the CDA limit, so we can't create any more + // for now. We should reenable this test once we have a new workspace. const response = await client.dataAttributes.create({ name: `Bebech${randomInt(0, 999)},${randomInt( randomInt(0, 999) @@ -23,7 +25,7 @@ describe('Data Attributes', () => { assert.notEqual(response, undefined); }); - it('update', async () => { + xit('update', async () => { const response = await client.dataAttributes.update({ id: createdDataAttribute.id, archived: false, diff --git a/test/integration/messages.test.ts b/test/integration/messages.test.ts index d4efef97..73dc71a2 100644 --- a/test/integration/messages.test.ts +++ b/test/integration/messages.test.ts @@ -13,8 +13,10 @@ describe('Messages', () => { }); before(async () => { - const adminList = await client.admins.list(); - adminId = adminList.admins[0].id; + const admins = await client.admins.list(); + const adminList = admins.admins.filter((admin) => admin.has_inbox_seat); + + adminId = adminList[0].id; const createdUser = await client.contacts.createUser({ externalId: randomString(), From 2e8ba69a38d9da6d7e1c98d55ccf8609076d500c Mon Sep 17 00:00:00 2001 From: Kevin O'Sullivan Date: Tue, 12 Dec 2023 14:45:24 +0000 Subject: [PATCH 116/146] Create REPO_OWNER (#385) Adding REPO_OWNER file --- REPO_OWNER | 1 + 1 file changed, 1 insertion(+) create mode 100644 REPO_OWNER diff --git a/REPO_OWNER b/REPO_OWNER new file mode 100644 index 00000000..caf9a1b8 --- /dev/null +++ b/REPO_OWNER @@ -0,0 +1 @@ +team-app-ecosystem From 6c73a4eaaa5b2e3687cccfcb8b2f583052bf9439 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 12 Dec 2023 14:46:27 +0000 Subject: [PATCH 117/146] Bump @babel/traverse from 7.22.8 to 7.23.2 (#383) Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.22.8 to 7.23.2. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse) --- updated-dependencies: - dependency-name: "@babel/traverse" dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Colm Doyle --- yarn.lock | 110 ++++++++++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 94 insertions(+), 16 deletions(-) diff --git a/yarn.lock b/yarn.lock index 9b92e6c9..925d65d1 100644 --- a/yarn.lock +++ b/yarn.lock @@ -22,6 +22,16 @@ __metadata: languageName: node linkType: hard +"@babel/code-frame@npm:^7.22.13": + version: 7.22.13 + resolution: "@babel/code-frame@npm:7.22.13" + dependencies: + "@babel/highlight": ^7.22.13 + chalk: ^2.4.2 + checksum: 22e342c8077c8b77eeb11f554ecca2ba14153f707b85294fcf6070b6f6150aae88a7b7436dd88d8c9289970585f3fe5b9b941c5aa3aa26a6d5a8ef3f292da058 + languageName: node + linkType: hard + "@babel/code-frame@npm:^7.22.5": version: 7.22.5 resolution: "@babel/code-frame@npm:7.22.5" @@ -73,6 +83,18 @@ __metadata: languageName: node linkType: hard +"@babel/generator@npm:^7.23.0": + version: 7.23.0 + resolution: "@babel/generator@npm:7.23.0" + dependencies: + "@babel/types": ^7.23.0 + "@jridgewell/gen-mapping": ^0.3.2 + "@jridgewell/trace-mapping": ^0.3.17 + jsesc: ^2.5.1 + checksum: 8efe24adad34300f1f8ea2add420b28171a646edc70f2a1b3e1683842f23b8b7ffa7e35ef0119294e1901f45bfea5b3dc70abe1f10a1917ccdfb41bed69be5f1 + languageName: node + linkType: hard + "@babel/helper-compilation-targets@npm:^7.22.6": version: 7.22.6 resolution: "@babel/helper-compilation-targets@npm:7.22.6" @@ -88,6 +110,13 @@ __metadata: languageName: node linkType: hard +"@babel/helper-environment-visitor@npm:^7.22.20": + version: 7.22.20 + resolution: "@babel/helper-environment-visitor@npm:7.22.20" + checksum: d80ee98ff66f41e233f36ca1921774c37e88a803b2f7dca3db7c057a5fea0473804db9fb6729e5dbfd07f4bed722d60f7852035c2c739382e84c335661590b69 + languageName: node + linkType: hard + "@babel/helper-environment-visitor@npm:^7.22.5": version: 7.22.5 resolution: "@babel/helper-environment-visitor@npm:7.22.5" @@ -95,13 +124,13 @@ __metadata: languageName: node linkType: hard -"@babel/helper-function-name@npm:^7.22.5": - version: 7.22.5 - resolution: "@babel/helper-function-name@npm:7.22.5" +"@babel/helper-function-name@npm:^7.23.0": + version: 7.23.0 + resolution: "@babel/helper-function-name@npm:7.23.0" dependencies: - "@babel/template": ^7.22.5 - "@babel/types": ^7.22.5 - checksum: 6b1f6ce1b1f4e513bf2c8385a557ea0dd7fa37971b9002ad19268ca4384bbe90c09681fe4c076013f33deabc63a53b341ed91e792de741b4b35e01c00238177a + "@babel/template": ^7.22.15 + "@babel/types": ^7.23.0 + checksum: e44542257b2d4634a1f979244eb2a4ad8e6d75eb6761b4cfceb56b562f7db150d134bc538c8e6adca3783e3bc31be949071527aa8e3aab7867d1ad2d84a26e10 languageName: node linkType: hard @@ -164,6 +193,13 @@ __metadata: languageName: node linkType: hard +"@babel/helper-validator-identifier@npm:^7.22.20": + version: 7.22.20 + resolution: "@babel/helper-validator-identifier@npm:7.22.20" + checksum: 136412784d9428266bcdd4d91c32bcf9ff0e8d25534a9d94b044f77fe76bc50f941a90319b05aafd1ec04f7d127cd57a179a3716009ff7f3412ef835ada95bdc + languageName: node + linkType: hard + "@babel/helper-validator-identifier@npm:^7.22.5": version: 7.22.5 resolution: "@babel/helper-validator-identifier@npm:7.22.5" @@ -189,6 +225,17 @@ __metadata: languageName: node linkType: hard +"@babel/highlight@npm:^7.22.13": + version: 7.22.20 + resolution: "@babel/highlight@npm:7.22.20" + dependencies: + "@babel/helper-validator-identifier": ^7.22.20 + chalk: ^2.4.2 + js-tokens: ^4.0.0 + checksum: 84bd034dca309a5e680083cd827a766780ca63cef37308404f17653d32366ea76262bd2364b2d38776232f2d01b649f26721417d507e8b4b6da3e4e739f6d134 + languageName: node + linkType: hard + "@babel/highlight@npm:^7.22.5": version: 7.22.5 resolution: "@babel/highlight@npm:7.22.5" @@ -200,6 +247,15 @@ __metadata: languageName: node linkType: hard +"@babel/parser@npm:^7.22.15, @babel/parser@npm:^7.23.0": + version: 7.23.0 + resolution: "@babel/parser@npm:7.23.0" + bin: + parser: ./bin/babel-parser.js + checksum: 453fdf8b9e2c2b7d7b02139e0ce003d1af21947bbc03eb350fb248ee335c9b85e4ab41697ddbdd97079698de825a265e45a0846bb2ed47a2c7c1df833f42a354 + languageName: node + linkType: hard + "@babel/parser@npm:^7.22.5, @babel/parser@npm:^7.22.7": version: 7.22.7 resolution: "@babel/parser@npm:7.22.7" @@ -209,6 +265,17 @@ __metadata: languageName: node linkType: hard +"@babel/template@npm:^7.22.15": + version: 7.22.15 + resolution: "@babel/template@npm:7.22.15" + dependencies: + "@babel/code-frame": ^7.22.13 + "@babel/parser": ^7.22.15 + "@babel/types": ^7.22.15 + checksum: 1f3e7dcd6c44f5904c184b3f7fe280394b191f2fed819919ffa1e529c259d5b197da8981b6ca491c235aee8dbad4a50b7e31304aa531271cb823a4a24a0dd8fd + languageName: node + linkType: hard + "@babel/template@npm:^7.22.5": version: 7.22.5 resolution: "@babel/template@npm:7.22.5" @@ -221,20 +288,31 @@ __metadata: linkType: hard "@babel/traverse@npm:^7.22.5, @babel/traverse@npm:^7.22.6, @babel/traverse@npm:^7.22.8": - version: 7.22.8 - resolution: "@babel/traverse@npm:7.22.8" + version: 7.23.2 + resolution: "@babel/traverse@npm:7.23.2" dependencies: - "@babel/code-frame": ^7.22.5 - "@babel/generator": ^7.22.7 - "@babel/helper-environment-visitor": ^7.22.5 - "@babel/helper-function-name": ^7.22.5 + "@babel/code-frame": ^7.22.13 + "@babel/generator": ^7.23.0 + "@babel/helper-environment-visitor": ^7.22.20 + "@babel/helper-function-name": ^7.23.0 "@babel/helper-hoist-variables": ^7.22.5 "@babel/helper-split-export-declaration": ^7.22.6 - "@babel/parser": ^7.22.7 - "@babel/types": ^7.22.5 + "@babel/parser": ^7.23.0 + "@babel/types": ^7.23.0 debug: ^4.1.0 globals: ^11.1.0 - checksum: a381369bc3eedfd13ed5fef7b884657f1c29024ea7388198149f0edc34bd69ce3966e9f40188d15f56490a5e12ba250ccc485f2882b53d41b054fccefb233e33 + checksum: 26a1eea0dde41ab99dde8b9773a013a0dc50324e5110a049f5d634e721ff08afffd54940b3974a20308d7952085ac769689369e9127dea655f868c0f6e1ab35d + languageName: node + linkType: hard + +"@babel/types@npm:^7.22.15, @babel/types@npm:^7.23.0": + version: 7.23.0 + resolution: "@babel/types@npm:7.23.0" + dependencies: + "@babel/helper-string-parser": ^7.22.5 + "@babel/helper-validator-identifier": ^7.22.20 + to-fast-properties: ^2.0.0 + checksum: 215fe04bd7feef79eeb4d33374b39909ce9cad1611c4135a4f7fdf41fe3280594105af6d7094354751514625ea92d0875aba355f53e86a92600f290e77b0e604 languageName: node linkType: hard @@ -1080,7 +1158,7 @@ __metadata: languageName: node linkType: hard -"chalk@npm:^2.0.0": +"chalk@npm:^2.0.0, chalk@npm:^2.4.2": version: 2.4.2 resolution: "chalk@npm:2.4.2" dependencies: From 168c2552a260ddcd98a4954daf43c305d9b6a504 Mon Sep 17 00:00:00 2001 From: John Ferlito Date: Wed, 13 Dec 2023 02:40:01 +1100 Subject: [PATCH 118/146] Fix type in ContactObject: opted_out_subscription_tyes (#380) types was mispelt. --- lib/contact/contact.types.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/contact/contact.types.ts b/lib/contact/contact.types.ts index ce7384a6..97560159 100644 --- a/lib/contact/contact.types.ts +++ b/lib/contact/contact.types.ts @@ -46,7 +46,7 @@ export interface ContactObject { notes: AddressableList; companies: AddressableList; opted_in_subscription_types: AddressableList; - opted_out_subscription_tyes: AddressableList; + opted_out_subscription_types: AddressableList; referrer: string; utm_campaign: string | null; utm_content: string | null; From ddfa94d65bec8d6885e987f5f3998b2caeebc500 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Tue, 12 Dec 2023 15:55:22 +0000 Subject: [PATCH 119/146] Update the company.update method (#375) * Update the company.update method Makes it clearer that this endpoint uses the Intercom ID for a company, and not the companyID that is optionally provided during creation closes #356 * Add a createOrUpdate company method This method actually creates or updates, so add a more appropriately named method and mark the old one as deprecated/ --- lib/company.ts | 53 ++++++++++++++++++++++++++++-- test/integration/companies.test.ts | 19 ++++++++++- test/unit/company.test.ts | 6 ++-- 3 files changed, 71 insertions(+), 7 deletions(-) diff --git a/lib/company.ts b/lib/company.ts index e1d3b98f..3704a457 100644 --- a/lib/company.ts +++ b/lib/company.ts @@ -21,6 +21,9 @@ export default class Company { this.client = client; this.scroll = new Scroll(this.client, this.baseUrl); } + /** + * @deprecated Use `client.companies.createOrUpdate()` instead. + */ create({ createdAt, companyId, @@ -31,6 +34,34 @@ export default class Company { website, industry, customAttributes, + }: CreateCompanyData) { + return this.createOrUpdate({ + createdAt, + companyId, + name, + monthlySpend, + plan, + size, + website, + industry, + customAttributes, + }); + } + /** + * Create or update a company by its `companyId`. + * + * Companies are looked up via the `companyId` field. If a company with the given `companyId` does not exist, it will be created. If a company with the given `companyId` does exist, it will be updated. + **/ + createOrUpdate({ + createdAt, + companyId, + name, + monthlySpend, + plan, + size, + website, + industry, + customAttributes, }: CreateCompanyData) { const data = { remote_created_at: createdAt, @@ -49,9 +80,23 @@ export default class Company { data, }); } + + /** + * Update a single company by its `id`. + * @param id - The `id` field is required for updating a company. This is distinct from the `companyId` field on the Company object , which is an identifier for the company in your database. + * @param createdAt - The time the company was created by you. + * @param name - The name of the company. + * @param monthlySpend - The amount the company spends on your product each month. How much revenue the company generates for your business. + * Note that this will truncate floats. i.e. it only allow for whole integers, 155.98 will be truncated to 155. Note that this has an upper limit of 2**31-1 or 2147483647.. + * @param plan - The name of the plan you have associated with the company. + * @param size - The number of employees the company has. + * @param website -The URL for this company's website. Please note that the value specified here is not validated. Accepts any string. + * @param industry - The industry the company operates in. + * @param customAttributes - A hash of key/value pairs containing any other data about the company you want Intercom to store. + */ update({ + id, createdAt, - companyId, name, monthlySpend, plan, @@ -72,7 +117,7 @@ export default class Company { }; return this.client.put({ - url: `/${this.baseUrl}/${companyId}`, + url: `/${this.baseUrl}/${id}`, data, }); } @@ -160,7 +205,9 @@ interface CreateCompanyData { customAttributes?: JavascriptObject; } // -type UpdateCompanyData = CreateCompanyData; +interface UpdateCompanyData extends Omit { + id: string; +} // interface FindCompanyData { companyId?: string; diff --git a/test/integration/companies.test.ts b/test/integration/companies.test.ts index 0be07f80..be79c26a 100644 --- a/test/integration/companies.test.ts +++ b/test/integration/companies.test.ts @@ -34,10 +34,27 @@ describe('Companies', () => { assert.notEqual(response, undefined); }); + it('createOrUpdate', async () => { + const response = await client.companies.createOrUpdate({ + createdAt: dateToUnixTimestamp(new Date()), + companyId: '46029', + name: 'BestCompanyInc.', + monthlySpend: 9001, + plan: '1. Get pizzaid', + size: 62049, + website: 'http://the-best.one', + industry: 'The Best One', + customAttributes: {}, + }); + + createdCompany = response; + + assert.notEqual(response, undefined); + }); it('update', async () => { const response = await client.companies.update({ createdAt: dateToUnixTimestamp(new Date()), - companyId: createdCompany.id, + id: createdCompany.id, name: 'BestCompanyInc', monthlySpend: 9001, plan: '1. Get pizzaid', diff --git a/test/unit/company.test.ts b/test/unit/company.test.ts index 48e3e4b2..19665cb6 100644 --- a/test/unit/company.test.ts +++ b/test/unit/company.test.ts @@ -64,7 +64,7 @@ describe('companies', () => { assert.deepStrictEqual({}, response); }); it('should be updated', async () => { - const company_id = '46029'; + const id = '625e90fc55ab113b6d92175f'; const requestBody = { remote_created_at: dateToUnixTimestamp(new Date()), name: 'BestCompanyInc.', @@ -77,12 +77,12 @@ describe('companies', () => { }; nock('https://api.intercom.io') - .put(`/companies/${company_id}`, requestBody) + .put(`/companies/${id}`, requestBody) .reply(200, {}); const response = await client.companies.update({ createdAt: requestBody.remote_created_at, - companyId: company_id, + id: id, name: requestBody.name, monthlySpend: requestBody.monthly_spend, plan: requestBody.plan, From 48276f393d95e579f9d5b60cd6ddfbf0a945715f Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Tue, 12 Dec 2023 16:01:50 +0000 Subject: [PATCH 120/146] Revert "Update the company.update method (#375)" (#393) This reverts commit ddfa94d65bec8d6885e987f5f3998b2caeebc500. --- lib/company.ts | 53 ++---------------------------- test/integration/companies.test.ts | 19 +---------- test/unit/company.test.ts | 6 ++-- 3 files changed, 7 insertions(+), 71 deletions(-) diff --git a/lib/company.ts b/lib/company.ts index 3704a457..e1d3b98f 100644 --- a/lib/company.ts +++ b/lib/company.ts @@ -21,9 +21,6 @@ export default class Company { this.client = client; this.scroll = new Scroll(this.client, this.baseUrl); } - /** - * @deprecated Use `client.companies.createOrUpdate()` instead. - */ create({ createdAt, companyId, @@ -34,34 +31,6 @@ export default class Company { website, industry, customAttributes, - }: CreateCompanyData) { - return this.createOrUpdate({ - createdAt, - companyId, - name, - monthlySpend, - plan, - size, - website, - industry, - customAttributes, - }); - } - /** - * Create or update a company by its `companyId`. - * - * Companies are looked up via the `companyId` field. If a company with the given `companyId` does not exist, it will be created. If a company with the given `companyId` does exist, it will be updated. - **/ - createOrUpdate({ - createdAt, - companyId, - name, - monthlySpend, - plan, - size, - website, - industry, - customAttributes, }: CreateCompanyData) { const data = { remote_created_at: createdAt, @@ -80,23 +49,9 @@ export default class Company { data, }); } - - /** - * Update a single company by its `id`. - * @param id - The `id` field is required for updating a company. This is distinct from the `companyId` field on the Company object , which is an identifier for the company in your database. - * @param createdAt - The time the company was created by you. - * @param name - The name of the company. - * @param monthlySpend - The amount the company spends on your product each month. How much revenue the company generates for your business. - * Note that this will truncate floats. i.e. it only allow for whole integers, 155.98 will be truncated to 155. Note that this has an upper limit of 2**31-1 or 2147483647.. - * @param plan - The name of the plan you have associated with the company. - * @param size - The number of employees the company has. - * @param website -The URL for this company's website. Please note that the value specified here is not validated. Accepts any string. - * @param industry - The industry the company operates in. - * @param customAttributes - A hash of key/value pairs containing any other data about the company you want Intercom to store. - */ update({ - id, createdAt, + companyId, name, monthlySpend, plan, @@ -117,7 +72,7 @@ export default class Company { }; return this.client.put({ - url: `/${this.baseUrl}/${id}`, + url: `/${this.baseUrl}/${companyId}`, data, }); } @@ -205,9 +160,7 @@ interface CreateCompanyData { customAttributes?: JavascriptObject; } // -interface UpdateCompanyData extends Omit { - id: string; -} +type UpdateCompanyData = CreateCompanyData; // interface FindCompanyData { companyId?: string; diff --git a/test/integration/companies.test.ts b/test/integration/companies.test.ts index be79c26a..0be07f80 100644 --- a/test/integration/companies.test.ts +++ b/test/integration/companies.test.ts @@ -34,27 +34,10 @@ describe('Companies', () => { assert.notEqual(response, undefined); }); - it('createOrUpdate', async () => { - const response = await client.companies.createOrUpdate({ - createdAt: dateToUnixTimestamp(new Date()), - companyId: '46029', - name: 'BestCompanyInc.', - monthlySpend: 9001, - plan: '1. Get pizzaid', - size: 62049, - website: 'http://the-best.one', - industry: 'The Best One', - customAttributes: {}, - }); - - createdCompany = response; - - assert.notEqual(response, undefined); - }); it('update', async () => { const response = await client.companies.update({ createdAt: dateToUnixTimestamp(new Date()), - id: createdCompany.id, + companyId: createdCompany.id, name: 'BestCompanyInc', monthlySpend: 9001, plan: '1. Get pizzaid', diff --git a/test/unit/company.test.ts b/test/unit/company.test.ts index 19665cb6..48e3e4b2 100644 --- a/test/unit/company.test.ts +++ b/test/unit/company.test.ts @@ -64,7 +64,7 @@ describe('companies', () => { assert.deepStrictEqual({}, response); }); it('should be updated', async () => { - const id = '625e90fc55ab113b6d92175f'; + const company_id = '46029'; const requestBody = { remote_created_at: dateToUnixTimestamp(new Date()), name: 'BestCompanyInc.', @@ -77,12 +77,12 @@ describe('companies', () => { }; nock('https://api.intercom.io') - .put(`/companies/${id}`, requestBody) + .put(`/companies/${company_id}`, requestBody) .reply(200, {}); const response = await client.companies.update({ createdAt: requestBody.remote_created_at, - id: id, + companyId: company_id, name: requestBody.name, monthlySpend: requestBody.monthly_spend, plan: requestBody.plan, From f7426ea45fa0b7422bd03cbecfc5e09f5fd0cb14 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Tue, 12 Dec 2023 16:07:29 +0000 Subject: [PATCH 121/146] Update package.json (#394) --- package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index e25a5f40..028941d4 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "4.0.1", + "version": "5.0.0", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", "bugs:": "https://github.com/intercom/intercom-node/issues", @@ -58,4 +58,4 @@ }, "license": "Apache-2.0", "packageManager": "yarn@3.1.1" -} \ No newline at end of file +} From 7d52a55cfc32e48831a016cb6fee128653e80ec5 Mon Sep 17 00:00:00 2001 From: Colm Doyle Date: Tue, 12 Dec 2023 16:19:02 +0000 Subject: [PATCH 122/146] Update README.md with maintenance mode information (#395) --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index 3d004d20..b8118cd0 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,9 @@ # intercom-node +## Maintenance mode + +The Intercom Node SDK is currently in maintenance mode whilst we consider the best way to support it. We are not currently accepting new feature requests or actively working on the SDK. + [![Circle CI](https://circleci.com/gh/intercom/intercom-node.png?style=shield)](https://circleci.com/gh/intercom/intercom-node) [![npm](https://img.shields.io/npm/v/intercom-client)](https://www.npmjs.com/package/intercom-client) ![Intercom API Version](https://img.shields.io/badge/Intercom%20API%20Version-2.6-blue) From 9a782cfc4e3388491d1e5087b650b44e0ecfcd55 Mon Sep 17 00:00:00 2001 From: suma-prakash <107560946+suma-prakash@users.noreply.github.com> Date: Thu, 25 Apr 2024 13:45:41 +0100 Subject: [PATCH 123/146] updating the repo owner (#398) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Suma Prakash <”suma.prakash”@intercom.io> --- REPO_OWNER | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/REPO_OWNER b/REPO_OWNER index caf9a1b8..4ab21abd 100644 --- a/REPO_OWNER +++ b/REPO_OWNER @@ -1 +1 @@ -team-app-ecosystem +team-data-interop From 185d4eea22cec664cafbecf05e586a29ddda8134 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 12 Nov 2024 13:10:03 +0000 Subject: [PATCH 124/146] Bump path-to-regexp from 1.8.0 to 1.9.0 (#441) --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 925d65d1..ccf47422 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3136,11 +3136,11 @@ __metadata: linkType: hard "path-to-regexp@npm:^1.7.0": - version: 1.8.0 - resolution: "path-to-regexp@npm:1.8.0" + version: 1.9.0 + resolution: "path-to-regexp@npm:1.9.0" dependencies: isarray: 0.0.1 - checksum: 709f6f083c0552514ef4780cb2e7e4cf49b0cc89a97439f2b7cc69a608982b7690fb5d1720a7473a59806508fc2dae0be751ba49f495ecf89fd8fbc62abccbcd + checksum: 5b2ac9cab2a9f82effd30a35164b20998b18d99d96608281dd2cab6e66c0e4536187970369b185ab21d3815da1ecb7dcb2d5f97a4bf0ee6e31a9612299fca147 languageName: node linkType: hard From dd45735c9b07bbd753b75b45c415abf0b54c63ce Mon Sep 17 00:00:00 2001 From: Fern Support <126544928+fern-support@users.noreply.github.com> Date: Thu, 19 Dec 2024 15:55:09 -0800 Subject: [PATCH 125/146] Add .fernignore file (#450) Co-authored-by: Niels Swimberghe <3382717+Swimburger@users.noreply.github.com> --- .fernignore | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 .fernignore diff --git a/.fernignore b/.fernignore new file mode 100644 index 00000000..41e2e168 --- /dev/null +++ b/.fernignore @@ -0,0 +1,6 @@ +# Specify files that shouldn't be modified by Fern +.github/ISSUE_TEMPLATE.md +.github/PULL_REQUEST_TEMPLATE.md +.gitattributes +LICENSE +REPO_OWNER \ No newline at end of file From 56655c1c141d7b7f0edcbf7ba84615dda3b0183d Mon Sep 17 00:00:00 2001 From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com> Date: Sun, 22 Dec 2024 12:08:03 -0500 Subject: [PATCH 126/146] :herb: Fern Regeneration -- December 20, 2024 (#451) * SDK regeneration * Add integration tests * update ci.yml * give "Message that creates a converation" test more time * add package.json name back * Add publish to ci.yml * Manually update types to not wrap body params in a body property --------- Co-authored-by: fern-api <115122769+fern-api[bot]@users.noreply.github.com> Co-authored-by: Niels Swimberghe <3382717+Swimburger@users.noreply.github.com> --- .circleci/config.yml | 64 - .editorconfig | 16 - .eslintignore | 3 - .eslintrc | 46 - .fernignore | 4 +- .github/workflows/ci.yml | 62 + .gitignore | 45 +- .npmignore | 11 +- .nycrc | 17 - .prettierignore | 3 - .prettierrc.json | 8 - .prettierrc.yml | 2 + .vscode/settings.json | 4 - .yarn/releases/yarn-3.1.1.cjs | 768 -- .yarnrc.yml | 3 - README.md | 1322 +-- jest.config.js | 5 + lib/admin.ts | 82 - lib/admin/admin.types.ts | 12 - lib/article.ts | 119 - lib/article/article.types.ts | 92 - lib/client.ts | 290 - lib/common/common.types.ts | 84 - lib/company.ts | 198 - lib/company/company.types.ts | 39 - lib/contact.ts | 335 - lib/contact/contact.types.ts | 85 - lib/conversation.ts | 549 -- lib/conversation/conversation.types.ts | 163 - lib/count.ts | 86 - lib/count/count.types.ts | 90 - lib/dataAttribute.ts | 82 - lib/dataAttribute/dataAttribute.types.ts | 34 - lib/dataExport.ts | 43 - lib/dataExport/dataExport.types.ts | 6 - lib/errors/badResponse.error.ts | 15 - lib/event.ts | 87 - lib/event/event.types.ts | 29 - lib/helpCenter.ts | 171 - lib/helpCenter/helpCenter.types.ts | 37 - lib/index.ts | 66 - lib/message.ts | 66 - lib/message/message.types.ts | 18 - lib/note.ts | 54 - lib/note/note.types.ts | 22 - lib/phoneCallRedirect.ts | 27 - .../phoneCallRedirect.types.ts | 4 - lib/scroll.ts | 68 - lib/segment.ts | 39 - lib/segment/segment.types.ts | 11 - lib/subscription.ts | 20 - lib/subscription/subscription.types.ts | 20 - lib/tag.ts | 142 - lib/tag/tag.types.ts | 5 - lib/team.ts | 31 - lib/team/team.types.ts | 6 - lib/util/time.ts | 3 - lib/util/url.ts | 10 - lib/visitor.ts | 87 - lib/visitor/visitor.types.ts | 18 - package.json | 88 +- reference.md | 7819 +++++++++++++++++ src/Client.ts | 190 + src/api/errors/BadRequestError.ts | 16 + src/api/errors/ForbiddenError.ts | 17 + src/api/errors/NotFoundError.ts | 16 + src/api/errors/UnauthorizedError.ts | 17 + src/api/errors/UnprocessableEntityError.ts | 16 + src/api/errors/index.ts | 5 + src/api/index.ts | 4 + src/api/resources/admins/client/Client.ts | 447 + src/api/resources/admins/client/index.ts | 1 + .../requests/ConfigureAwayAdminRequest.ts | 36 + .../client/requests/FindAdminRequest.ts | 16 + .../requests/ListAllActivityLogsRequest.ts | 21 + .../resources/admins/client/requests/index.ts | 3 + src/api/resources/admins/index.ts | 2 + src/api/resources/admins/types/Admin.ts | 32 + src/api/resources/admins/types/index.ts | 1 + src/api/resources/aiAgent/index.ts | 1 + src/api/resources/aiAgent/types/AiAgent.ts | 38 + src/api/resources/aiAgent/types/index.ts | 1 + src/api/resources/aiContentSource/index.ts | 1 + .../aiContentSource/types/ContentSource.ts | 31 + .../resources/aiContentSource/types/index.ts | 1 + src/api/resources/articles/client/Client.ts | 598 ++ src/api/resources/articles/client/index.ts | 1 + .../client/requests/CreateArticleRequest.ts | 65 + .../client/requests/DeleteArticleRequest.ts | 16 + .../client/requests/FindArticleRequest.ts | 16 + .../client/requests/ListArticlesRequest.ts | 18 + .../client/requests/SearchArticlesRequest.ts | 29 + .../client/requests/UpdateArticleRequest.ts | 53 + .../articles/client/requests/index.ts | 6 + src/api/resources/articles/index.ts | 2 + src/api/resources/articles/types/Article.ts | 12 + .../articles/types/ArticleListItem.ts | 53 + .../articles/types/ArticleSearchHighlights.ts | 67 + .../articles/types/SearchArticlesResponse.ts | 30 + src/api/resources/articles/types/index.ts | 4 + src/api/resources/companies/client/Client.ts | 1053 +++ src/api/resources/companies/client/index.ts | 1 + .../requests/AttachContactToCompanyRequest.ts | 31 + .../requests/CreateOrUpdateCompanyRequest.ts | 35 + .../client/requests/DeleteCompanyRequest.ts | 16 + .../DetachContactFromCompanyRequest.ts | 21 + .../client/requests/FindCompanyRequest.ts | 16 + .../requests/ListAttachedContactsRequest.ts | 24 + .../client/requests/ListCompaniesRequest.ts | 24 + .../ListSegmentsAttachedToCompanyRequest.ts | 16 + .../client/requests/RetrieveCompanyRequest.ts | 39 + .../client/requests/ScrollCompaniesRequest.ts | 14 + .../client/requests/UpdateCompanyRequest.ts | 16 + .../companies/client/requests/index.ts | 11 + src/api/resources/companies/index.ts | 2 + src/api/resources/companies/types/Company.ts | 77 + src/api/resources/companies/types/index.ts | 1 + src/api/resources/contacts/client/Client.ts | 1374 +++ src/api/resources/contacts/client/index.ts | 1 + .../client/requests/ArchiveContactRequest.ts | 16 + .../AttachSubscriptionToContactRequest.ts | 36 + .../client/requests/DeleteContactRequest.ts | 16 + .../DetachSubscriptionFromContactRequest.ts | 21 + .../client/requests/FindContactRequest.ts | 16 + .../requests/ListAttachedCompaniesRequest.ts | 24 + .../ListAttachedSubscriptionsRequest.ts | 16 + .../client/requests/ListContactsRequest.ts | 22 + .../ListSegmentsAttachedToContactRequest.ts | 16 + .../ListTagsAttachedToContactRequest.ts | 16 + .../client/requests/MergeContactsRequest.ts | 17 + .../requests/UnarchiveContactRequest.ts | 16 + .../client/requests/UpdateContactRequest.ts | 40 + .../contacts/client/requests/index.ts | 13 + src/api/resources/contacts/index.ts | 2 + src/api/resources/contacts/types/Contact.ts | 106 + src/api/resources/contacts/types/index.ts | 1 + .../resources/conversations/client/Client.ts | 1331 +++ .../resources/conversations/client/index.ts | 1 + .../AttachContactToConversationRequest.ts | 50 + .../requests/AutoAssignConversationRequest.ts | 16 + .../ConvertConversationToTicketRequest.ts | 28 + .../requests/CreateConversationRequest.ts | 49 + .../DetachContactFromConversationRequest.ts | 45 + .../requests/FindConversationRequest.ts | 21 + .../requests/ListConversationsRequest.ts | 18 + .../ManageConversationPartsRequest.ts | 74 + .../requests/ReplyToConversationRequest.ts | 91 + .../requests/UpdateConversationRequest.ts | 42 + .../conversations/client/requests/index.ts | 10 + src/api/resources/conversations/index.ts | 2 + .../conversations/types/Conversation.ts | 71 + .../types/ConversationsManageRequestBody.ts | 29 + .../resources/conversations/types/index.ts | 2 + .../resources/customObjectInstances/index.ts | 1 + .../types/CustomObjectInstance.ts | 17 + .../customObjectInstances/types/index.ts | 1 + .../resources/dataAttributes/client/Client.ts | 395 + .../resources/dataAttributes/client/index.ts | 1 + .../requests/CreateDataAttributeRequest.ts | 86 + .../requests/ListDataAttributesRequest.ts | 20 + .../requests/UpdateDataAttributeRequest.ts | 72 + .../dataAttributes/client/requests/index.ts | 3 + src/api/resources/dataAttributes/index.ts | 2 + .../dataAttributes/types/DataAttribute.ts | 65 + .../types/DataAttributesListRequestModel.ts | 10 + .../resources/dataAttributes/types/index.ts | 2 + src/api/resources/dataEvents/index.ts | 1 + .../resources/dataEvents/types/DataEvent.ts | 25 + src/api/resources/dataEvents/types/index.ts | 1 + src/api/resources/dataExport/client/Client.ts | 377 + src/api/resources/dataExport/client/index.ts | 1 + .../requests/CancelDataExportRequest.ts | 16 + .../requests/CreateDataExportRequest.ts | 17 + .../requests/DownloadDataExportRequest.ts | 16 + .../client/requests/FindDataExportRequest.ts | 16 + .../dataExport/client/requests/index.ts | 4 + src/api/resources/dataExport/index.ts | 2 + .../resources/dataExport/types/DataExport.ts | 32 + src/api/resources/dataExport/types/index.ts | 1 + src/api/resources/events/client/Client.ts | 384 + src/api/resources/events/client/index.ts | 1 + .../requests/ListEventSummariesRequest.ts | 30 + .../client/requests/ListEventsRequest.ts | 36 + .../resources/events/client/requests/index.ts | 2 + src/api/resources/events/index.ts | 1 + src/api/resources/helpCenter/index.ts | 1 + .../resources/helpCenter/types/Collection.ts | 36 + .../resources/helpCenter/types/HelpCenter.ts | 23 + .../helpCenter/types/HelpCenterList.ts | 15 + src/api/resources/helpCenter/types/index.ts | 3 + .../resources/helpCenters/client/Client.ts | 258 + src/api/resources/helpCenters/client/index.ts | 1 + .../client/requests/FindHelpCenterRequest.ts | 16 + .../client/requests/ListHelpCentersRequest.ts | 18 + .../helpCenters/client/requests/index.ts | 2 + src/api/resources/helpCenters/index.ts | 2 + .../resources/collections/client/Client.ts | 490 ++ .../resources/collections/client/index.ts | 1 + .../requests/CreateCollectionRequest.ts | 29 + .../requests/DeleteCollectionRequest.ts | 16 + .../client/requests/FindCollectionRequest.ts | 16 + .../client/requests/ListCollectionsRequest.ts | 18 + .../requests/UpdateCollectionRequest.ts | 32 + .../collections/client/requests/index.ts | 5 + .../resources/collections/index.ts | 1 + .../resources/helpCenters/resources/index.ts | 2 + src/api/resources/index.ts | 62 + src/api/resources/messages/client/Client.ts | 262 + src/api/resources/messages/client/index.ts | 1 + src/api/resources/messages/index.ts | 2 + src/api/resources/messages/types/Message.ts | 36 + src/api/resources/messages/types/index.ts | 1 + src/api/resources/news/client/Client.ts | 82 + src/api/resources/news/client/index.ts | 1 + src/api/resources/news/index.ts | 3 + .../news/resources/feeds/client/Client.ts | 296 + .../news/resources/feeds/client/index.ts | 1 + .../client/requests/FindNewsFeedRequest.ts | 16 + .../requests/ListNewsFeedItemsRequest.ts | 16 + .../resources/feeds/client/requests/index.ts | 2 + .../resources/news/resources/feeds/index.ts | 1 + src/api/resources/news/resources/index.ts | 4 + .../news/resources/items/client/Client.ts | 477 + .../news/resources/items/client/index.ts | 1 + .../client/requests/DeleteNewsItemRequest.ts | 16 + .../client/requests/FindNewsItemRequest.ts | 16 + .../client/requests/UpdateNewsItemRequest.ts | 36 + .../resources/items/client/requests/index.ts | 3 + .../resources/news/resources/items/index.ts | 1 + src/api/resources/news/types/NewsItem.ts | 50 + src/api/resources/news/types/Newsfeed.ts | 21 + .../news/types/NewsfeedAssignment.ts | 13 + src/api/resources/news/types/index.ts | 3 + src/api/resources/notes/client/Client.ts | 331 + src/api/resources/notes/client/index.ts | 1 + .../requests/CreateContactNoteRequest.ts | 36 + .../notes/client/requests/FindNoteRequest.ts | 16 + .../requests/ListContactNotesRequest.ts | 24 + .../resources/notes/client/requests/index.ts | 3 + src/api/resources/notes/index.ts | 2 + src/api/resources/notes/types/Note.ts | 35 + src/api/resources/notes/types/index.ts | 1 + .../phoneCallRedirects/client/Client.ts | 177 + .../phoneCallRedirects/client/index.ts | 1 + .../CreatePhoneCallRedirectRequest.ts | 48 + .../client/requests/index.ts | 1 + src/api/resources/phoneCallRedirects/index.ts | 1 + src/api/resources/segments/client/Client.ts | 237 + src/api/resources/segments/client/index.ts | 1 + .../client/requests/FindSegmentRequest.ts | 16 + .../client/requests/ListSegmentsRequest.ts | 14 + .../segments/client/requests/index.ts | 2 + src/api/resources/segments/index.ts | 2 + src/api/resources/segments/types/Segment.ts | 34 + src/api/resources/segments/types/index.ts | 1 + .../subscriptionTypes/client/Client.ts | 151 + .../subscriptionTypes/client/index.ts | 1 + src/api/resources/subscriptionTypes/index.ts | 2 + .../types/SubscriptionType.ts | 53 + .../subscriptionTypes/types/index.ts | 1 + src/api/resources/tags/client/Client.ts | 892 ++ src/api/resources/tags/client/index.ts | 1 + .../tags/client/requests/DeleteTagRequest.ts | 16 + .../tags/client/requests/FindTagRequest.ts | 16 + .../tags/client/requests/TagContactRequest.ts | 31 + .../client/requests/TagConversationRequest.ts | 29 + .../tags/client/requests/TagTicketRequest.ts | 29 + .../client/requests/UntagContactRequest.ts | 21 + .../requests/UntagConversationRequest.ts | 38 + .../client/requests/UntagTicketRequest.ts | 38 + .../resources/tags/client/requests/index.ts | 8 + src/api/resources/tags/index.ts | 2 + src/api/resources/tags/types/Tag.ts | 20 + .../tags/types/TagsCreateRequestBody.ts | 11 + src/api/resources/tags/types/index.ts | 2 + src/api/resources/teams/client/Client.ts | 226 + src/api/resources/teams/client/index.ts | 1 + .../teams/client/requests/FindTeamRequest.ts | 16 + .../resources/teams/client/requests/index.ts | 1 + src/api/resources/teams/index.ts | 2 + src/api/resources/teams/types/Team.ts | 20 + src/api/resources/teams/types/index.ts | 1 + .../resources/ticketTypes/client/Client.ts | 392 + src/api/resources/ticketTypes/client/index.ts | 1 + .../requests/CreateTicketTypeRequest.ts | 37 + .../client/requests/FindTicketTypeRequest.ts | 16 + .../requests/UpdateTicketTypeRequest.ts | 41 + .../ticketTypes/client/requests/index.ts | 3 + src/api/resources/ticketTypes/index.ts | 2 + .../resources/attributes/client/Client.ts | 239 + .../resources/attributes/client/index.ts | 1 + .../CreateTicketTypeAttributeRequest.ts | 56 + .../UpdateTicketTypeAttributeRequest.ts | 42 + .../attributes/client/requests/index.ts | 2 + .../ticketTypes/resources/attributes/index.ts | 1 + .../resources/ticketTypes/resources/index.ts | 2 + src/api/resources/tickets/client/Client.ts | 622 ++ src/api/resources/tickets/client/index.ts | 1 + .../client/requests/CreateTicketRequest.ts | 47 + .../client/requests/FindTicketRequest.ts | 16 + .../client/requests/ReplyToTicketRequest.ts | 83 + .../client/requests/UpdateTicketRequest.ts | 85 + .../tickets/client/requests/index.ts | 4 + src/api/resources/tickets/index.ts | 2 + src/api/resources/tickets/types/Ticket.ts | 66 + .../resources/tickets/types/TicketContacts.ts | 15 + src/api/resources/tickets/types/TicketPart.ts | 59 + src/api/resources/tickets/types/TicketType.ts | 44 + .../tickets/types/TicketsReplyRequestBody.ts | 7 + src/api/resources/tickets/types/index.ts | 5 + src/api/resources/visitors/client/Client.ts | 333 + src/api/resources/visitors/client/index.ts | 1 + .../client/requests/FindVisitorRequest.ts | 16 + .../requests/MergeVisitorToContactRequest.ts | 53 + .../visitors/client/requests/index.ts | 2 + src/api/resources/visitors/index.ts | 1 + src/api/types/ActivityLog.ts | 175 + src/api/types/ActivityLogList.ts | 16 + src/api/types/ActivityLogMetadata.ts | 27 + src/api/types/AddressableList.ts | 15 + src/api/types/AdminList.ts | 15 + src/api/types/AdminPriorityLevel.ts | 13 + .../types/AdminReplyConversationRequest.ts | 31 + src/api/types/AdminReplyTicketRequest.ts | 40 + src/api/types/AdminWithApp.ts | 47 + src/api/types/App.ts | 23 + src/api/types/ArticleContent.ts | 38 + src/api/types/ArticleList.ts | 18 + src/api/types/ArticleStatistics.ts | 23 + src/api/types/ArticleTranslatedContent.ts | 87 + src/api/types/AssignConversationRequest.ts | 24 + src/api/types/CloseConversationRequest.ts | 14 + src/api/types/CollectionList.ts | 18 + src/api/types/CompanyAttachedContacts.ts | 18 + src/api/types/CompanyAttachedSegments.ts | 15 + src/api/types/CompanyList.ts | 18 + src/api/types/CompanyScroll.ts | 19 + src/api/types/ContactArchived.ts | 17 + src/api/types/ContactAttachedCompanies.ts | 18 + src/api/types/ContactCompanies.ts | 15 + src/api/types/ContactDeleted.ts | 17 + src/api/types/ContactList.ts | 18 + src/api/types/ContactLocation.ts | 17 + src/api/types/ContactNotes.ts | 19 + src/api/types/ContactReference.ts | 15 + src/api/types/ContactReplyBaseRequest.ts | 14 + .../types/ContactReplyConversationRequest.ts | 10 + src/api/types/ContactReplyEmailRequest.ts | 15 + .../ContactReplyIntercomUserIdRequest.ts | 15 + .../types/ContactReplyTicketEmailRequest.ts | 13 + ...ContactReplyTicketIntercomUserIdRequest.ts | 13 + src/api/types/ContactReplyTicketRequest.ts | 10 + .../types/ContactReplyTicketUserIdRequest.ts | 13 + src/api/types/ContactReplyUserIdRequest.ts | 15 + src/api/types/ContactSegments.ts | 15 + src/api/types/ContactSocialProfiles.ts | 13 + src/api/types/ContactSubscriptionTypes.ts | 19 + src/api/types/ContactTags.ts | 19 + src/api/types/ContactUnarchived.ts | 17 + src/api/types/ContentSourcesList.ts | 13 + src/api/types/ConversationAttachmentFiles.ts | 15 + src/api/types/ConversationContacts.ts | 14 + .../types/ConversationFirstContactReply.ts | 15 + src/api/types/ConversationPart.ts | 34 + src/api/types/ConversationPartAuthor.ts | 17 + src/api/types/ConversationParts.ts | 17 + src/api/types/ConversationRating.ts | 19 + src/api/types/ConversationSource.ts | 28 + src/api/types/ConversationStatistics.ts | 47 + src/api/types/ConversationTeammates.ts | 15 + src/api/types/CreateContactRequest.ts | 41 + src/api/types/CreateDataEventRequest.ts | 26 + src/api/types/CreateMessageRequest.ts | 114 + src/api/types/CreateOrUpdateTagRequest.ts | 13 + .../CreateTicketReplyWithCommentRequest.ts | 7 + src/api/types/CursorPages.ts | 21 + src/api/types/CustomAttributes.ts | 14 + src/api/types/CustomerRequest.ts | 14 + src/api/types/DataAttributeList.ts | 15 + src/api/types/DataEventList.ts | 27 + src/api/types/DataEventSummary.ts | 21 + src/api/types/DataEventSummaryItem.ts | 19 + src/api/types/DataExportCsv.ts | 61 + src/api/types/DeletedArticleObject.ts | 15 + src/api/types/DeletedCollectionObject.ts | 15 + src/api/types/DeletedCompanyObject.ts | 15 + src/api/types/DeletedObject.ts | 15 + src/api/types/Error_.ts | 30 + src/api/types/FileAttribute.ts | 22 + src/api/types/GroupContent.ts | 15 + src/api/types/GroupTranslatedContent.ts | 87 + src/api/types/LinkedObject.ts | 26 + src/api/types/LinkedObjectList.ts | 19 + src/api/types/MultipleFilterSearchRequest.ts | 32 + src/api/types/NewsItemRequest.ts | 38 + src/api/types/NoteList.ts | 18 + src/api/types/OpenConversationRequest.ts | 11 + src/api/types/PagesLink.ts | 17 + .../types/PaginatedConversationResponse.ts | 18 + src/api/types/PaginatedNewsItemResponse.ts | 18 + src/api/types/PaginatedNewsfeedResponse.ts | 18 + src/api/types/PartAttachment.ts | 23 + src/api/types/PhoneSwitch.ts | 13 + src/api/types/RedactConversationRequest.ts | 31 + src/api/types/Reference.ts | 13 + src/api/types/ReplyConversationRequest.ts | 9 + src/api/types/SearchRequest.ts | 17 + src/api/types/SegmentList.ts | 17 + src/api/types/SingleFilterSearchRequest.ts | 34 + src/api/types/SlaApplied.ts | 37 + src/api/types/SnoozeConversationRequest.ts | 13 + src/api/types/SocialProfile.ts | 15 + src/api/types/StartingAfterPaging.ts | 10 + src/api/types/SubscriptionTypeList.ts | 15 + src/api/types/TagCompanyRequest.ts | 26 + src/api/types/TagList.ts | 15 + src/api/types/TagMultipleUsersRequest.ts | 23 + src/api/types/Tags.ts | 15 + src/api/types/TeamList.ts | 15 + src/api/types/TeamPriorityLevel.ts | 13 + src/api/types/TicketCustomAttributes.ts | 14 + src/api/types/TicketList.ts | 18 + src/api/types/TicketPartAuthor.ts | 30 + src/api/types/TicketParts.ts | 17 + src/api/types/TicketReply.ts | 40 + .../types/TicketRequestCustomAttributes.ts | 12 + src/api/types/TicketTypeAttribute.ts | 43 + src/api/types/TicketTypeAttributeList.ts | 15 + src/api/types/TicketTypeList.ts | 15 + src/api/types/Translation.ts | 15 + src/api/types/UntagCompanyRequest.ts | 28 + src/api/types/UpdateVisitorRequest.ts | 18 + src/api/types/Visitor.ts | 138 + src/api/types/VisitorDeletedObject.ts | 15 + src/api/types/index.ts | 118 + src/api/version.ts | 24 + src/core/auth/BasicAuth.ts | 31 + src/core/auth/BearerToken.ts | 15 + src/core/auth/index.ts | 2 + src/core/fetcher/APIResponse.ts | 12 + src/core/fetcher/Fetcher.ts | 143 + src/core/fetcher/Supplier.ts | 11 + src/core/fetcher/createRequestUrl.ts | 10 + src/core/fetcher/getFetchFn.ts | 25 + src/core/fetcher/getHeader.ts | 8 + src/core/fetcher/getRequestBody.ts | 14 + src/core/fetcher/getResponseBody.ts | 34 + src/core/fetcher/index.ts | 5 + src/core/fetcher/makeRequest.ts | 44 + src/core/fetcher/requestWithRetries.ts | 33 + src/core/fetcher/signals.ts | 38 + .../Node18UniversalStreamWrapper.ts | 256 + .../stream-wrappers/NodePre18StreamWrapper.ts | 106 + .../stream-wrappers/UndiciStreamWrapper.ts | 243 + .../stream-wrappers/chooseStreamWrapper.ts | 33 + src/core/index.ts | 5 + src/core/pagination/Page.ts | 67 + src/core/pagination/Pageable.ts | 16 + src/core/pagination/index.ts | 2 + src/core/runtime/index.ts | 1 + src/core/runtime/runtime.ts | 126 + src/core/utils/index.ts | 1 + src/core/utils/setObjectProperty.ts | 43 + src/environments.ts | 14 + src/errors/IntercomError.ts | 45 + src/errors/IntercomTimeoutError.ts | 10 + src/errors/index.ts | 2 + src/index.ts | 4 + src/version.ts | 1 + test/integration/admins.test.ts | 49 - test/integration/articles.test.ts | 69 - test/integration/companies.test.ts | 120 - test/integration/contacts.test.ts | 113 - test/integration/conversations.test.ts | 211 - test/integration/counts.test.ts | 48 - test/integration/dataAttributes.test.ts | 46 - test/integration/dataExport.test.ts | 30 - test/integration/events.test.ts | 61 - .../helpCenter/collections.test.ts | 56 - test/integration/helpCenter/sections.test.ts | 66 - test/integration/integration.test.ts | 86 - test/integration/messages.test.ts | 87 - test/integration/notes.test.ts | 48 - test/integration/phoneCallRedirect.test.ts | 15 - test/integration/segments.test.ts | 22 - test/integration/subscriptions.test.ts | 13 - test/integration/tags.test.ts | 106 - test/integration/teams.test.ts | 22 - test/integration/utils/config.ts | 1 - test/integration/utils/date.ts | 2 - test/integration/utils/random.ts | 6 - test/integration/visitors.test.ts | 52 - test/unit/admin.test.ts | 64 - test/unit/article.test.ts | 113 - test/unit/client.test.ts | 69 - test/unit/company.test.ts | 260 - test/unit/contact.test.ts | 421 - test/unit/conversation.test.ts | 665 -- test/unit/counts.test.ts | 85 - test/unit/dataAttribute.test.ts | 73 - test/unit/errors.test.ts | 109 - test/unit/event.test.ts | 65 - test/unit/helpCenter.test.ts | 181 - test/unit/index.test.ts | 39 - test/unit/message.test.ts | 42 - test/unit/notes.test.ts | 51 - test/unit/request-opts.test.ts | 74 - test/unit/segment.test.ts | 43 - test/unit/subscription.test.ts | 18 - test/unit/tag.test.ts | 175 - test/unit/team.test.ts | 33 - test/unit/visitor.test.ts | 85 - tests/custom.test.ts | 13 + tests/integration/admins.test.ts | 61 + tests/integration/articles.test.ts | 114 + tests/integration/companies.test.ts | 148 + tests/integration/contacts.test.ts | 243 + tests/integration/conversations.test.ts | 286 + tests/integration/dataAttributes.test.ts | 67 + tests/integration/dataExport.test.ts | 57 + tests/integration/events.test.ts | 69 + .../helpCenter/collections.test.ts | 105 + tests/integration/helpers.ts | 87 + tests/integration/integration.test.ts | 86 + tests/integration/messages.test.ts | 81 + tests/integration/notes.test.ts | 65 + tests/integration/pagination.test.ts | 148 + tests/integration/phoneCallRedirect.test.ts | 20 + tests/integration/segments.test.ts | 31 + tests/integration/subscriptions.test.ts | 13 + tests/integration/tags.test.ts | 217 + tests/integration/teams.test.ts | 29 + tests/integration/utils/createClient.ts | 5 + tests/integration/utils/date.ts | 1 + tests/integration/utils/random.ts | 6 + tests/integration/utils/wait.ts | 3 + tests/integration/visitors.test.ts | 53 + tests/unit/auth/BasicAuth.test.ts | 22 + tests/unit/auth/BearerToken.test.ts | 14 + tests/unit/fetcher/Fetcher.test.ts | 73 + tests/unit/fetcher/createRequestUrl.test.ts | 51 + tests/unit/fetcher/getFetchFn.test.ts | 22 + tests/unit/fetcher/getRequestBody.test.ts | 77 + tests/unit/fetcher/getResponseBody.test.ts | 64 + tests/unit/fetcher/makeRequest.test.ts | 54 + tests/unit/fetcher/requestWithRetries.test.ts | 133 + tests/unit/fetcher/signals.test.ts | 69 + .../Node18UniversalStreamWrapper.test.ts | 178 + .../NodePre18StreamWrapper.test.ts | 124 + .../UndiciStreamWrapper.test.ts | 153 + .../chooseStreamWrapper.test.ts | 43 + .../fetcher/stream-wrappers/webpack.test.ts | 38 + tests/unit/fetcher/test-file.txt | 1 + tsconfig.json | 34 +- yarn.lock | 7192 +++++++-------- 555 files changed, 34636 insertions(+), 13729 deletions(-) delete mode 100644 .circleci/config.yml delete mode 100644 .editorconfig delete mode 100644 .eslintignore delete mode 100644 .eslintrc create mode 100644 .github/workflows/ci.yml delete mode 100644 .nycrc delete mode 100644 .prettierignore delete mode 100644 .prettierrc.json create mode 100644 .prettierrc.yml delete mode 100644 .vscode/settings.json delete mode 100755 .yarn/releases/yarn-3.1.1.cjs delete mode 100644 .yarnrc.yml create mode 100644 jest.config.js delete mode 100644 lib/admin.ts delete mode 100644 lib/admin/admin.types.ts delete mode 100644 lib/article.ts delete mode 100644 lib/article/article.types.ts delete mode 100644 lib/client.ts delete mode 100644 lib/common/common.types.ts delete mode 100644 lib/company.ts delete mode 100644 lib/company/company.types.ts delete mode 100644 lib/contact.ts delete mode 100644 lib/contact/contact.types.ts delete mode 100644 lib/conversation.ts delete mode 100644 lib/conversation/conversation.types.ts delete mode 100644 lib/count.ts delete mode 100644 lib/count/count.types.ts delete mode 100644 lib/dataAttribute.ts delete mode 100644 lib/dataAttribute/dataAttribute.types.ts delete mode 100644 lib/dataExport.ts delete mode 100644 lib/dataExport/dataExport.types.ts delete mode 100644 lib/errors/badResponse.error.ts delete mode 100644 lib/event.ts delete mode 100644 lib/event/event.types.ts delete mode 100644 lib/helpCenter.ts delete mode 100644 lib/helpCenter/helpCenter.types.ts delete mode 100644 lib/index.ts delete mode 100644 lib/message.ts delete mode 100644 lib/message/message.types.ts delete mode 100644 lib/note.ts delete mode 100644 lib/note/note.types.ts delete mode 100644 lib/phoneCallRedirect.ts delete mode 100644 lib/phoneCallRedirect/phoneCallRedirect.types.ts delete mode 100644 lib/scroll.ts delete mode 100644 lib/segment.ts delete mode 100644 lib/segment/segment.types.ts delete mode 100644 lib/subscription.ts delete mode 100644 lib/subscription/subscription.types.ts delete mode 100644 lib/tag.ts delete mode 100644 lib/tag/tag.types.ts delete mode 100644 lib/team.ts delete mode 100644 lib/team/team.types.ts delete mode 100644 lib/util/time.ts delete mode 100644 lib/util/url.ts delete mode 100644 lib/visitor.ts delete mode 100644 lib/visitor/visitor.types.ts create mode 100644 reference.md create mode 100644 src/Client.ts create mode 100644 src/api/errors/BadRequestError.ts create mode 100644 src/api/errors/ForbiddenError.ts create mode 100644 src/api/errors/NotFoundError.ts create mode 100644 src/api/errors/UnauthorizedError.ts create mode 100644 src/api/errors/UnprocessableEntityError.ts create mode 100644 src/api/errors/index.ts create mode 100644 src/api/index.ts create mode 100644 src/api/resources/admins/client/Client.ts create mode 100644 src/api/resources/admins/client/index.ts create mode 100644 src/api/resources/admins/client/requests/ConfigureAwayAdminRequest.ts create mode 100644 src/api/resources/admins/client/requests/FindAdminRequest.ts create mode 100644 src/api/resources/admins/client/requests/ListAllActivityLogsRequest.ts create mode 100644 src/api/resources/admins/client/requests/index.ts create mode 100644 src/api/resources/admins/index.ts create mode 100644 src/api/resources/admins/types/Admin.ts create mode 100644 src/api/resources/admins/types/index.ts create mode 100644 src/api/resources/aiAgent/index.ts create mode 100644 src/api/resources/aiAgent/types/AiAgent.ts create mode 100644 src/api/resources/aiAgent/types/index.ts create mode 100644 src/api/resources/aiContentSource/index.ts create mode 100644 src/api/resources/aiContentSource/types/ContentSource.ts create mode 100644 src/api/resources/aiContentSource/types/index.ts create mode 100644 src/api/resources/articles/client/Client.ts create mode 100644 src/api/resources/articles/client/index.ts create mode 100644 src/api/resources/articles/client/requests/CreateArticleRequest.ts create mode 100644 src/api/resources/articles/client/requests/DeleteArticleRequest.ts create mode 100644 src/api/resources/articles/client/requests/FindArticleRequest.ts create mode 100644 src/api/resources/articles/client/requests/ListArticlesRequest.ts create mode 100644 src/api/resources/articles/client/requests/SearchArticlesRequest.ts create mode 100644 src/api/resources/articles/client/requests/UpdateArticleRequest.ts create mode 100644 src/api/resources/articles/client/requests/index.ts create mode 100644 src/api/resources/articles/index.ts create mode 100644 src/api/resources/articles/types/Article.ts create mode 100644 src/api/resources/articles/types/ArticleListItem.ts create mode 100644 src/api/resources/articles/types/ArticleSearchHighlights.ts create mode 100644 src/api/resources/articles/types/SearchArticlesResponse.ts create mode 100644 src/api/resources/articles/types/index.ts create mode 100644 src/api/resources/companies/client/Client.ts create mode 100644 src/api/resources/companies/client/index.ts create mode 100644 src/api/resources/companies/client/requests/AttachContactToCompanyRequest.ts create mode 100644 src/api/resources/companies/client/requests/CreateOrUpdateCompanyRequest.ts create mode 100644 src/api/resources/companies/client/requests/DeleteCompanyRequest.ts create mode 100644 src/api/resources/companies/client/requests/DetachContactFromCompanyRequest.ts create mode 100644 src/api/resources/companies/client/requests/FindCompanyRequest.ts create mode 100644 src/api/resources/companies/client/requests/ListAttachedContactsRequest.ts create mode 100644 src/api/resources/companies/client/requests/ListCompaniesRequest.ts create mode 100644 src/api/resources/companies/client/requests/ListSegmentsAttachedToCompanyRequest.ts create mode 100644 src/api/resources/companies/client/requests/RetrieveCompanyRequest.ts create mode 100644 src/api/resources/companies/client/requests/ScrollCompaniesRequest.ts create mode 100644 src/api/resources/companies/client/requests/UpdateCompanyRequest.ts create mode 100644 src/api/resources/companies/client/requests/index.ts create mode 100644 src/api/resources/companies/index.ts create mode 100644 src/api/resources/companies/types/Company.ts create mode 100644 src/api/resources/companies/types/index.ts create mode 100644 src/api/resources/contacts/client/Client.ts create mode 100644 src/api/resources/contacts/client/index.ts create mode 100644 src/api/resources/contacts/client/requests/ArchiveContactRequest.ts create mode 100644 src/api/resources/contacts/client/requests/AttachSubscriptionToContactRequest.ts create mode 100644 src/api/resources/contacts/client/requests/DeleteContactRequest.ts create mode 100644 src/api/resources/contacts/client/requests/DetachSubscriptionFromContactRequest.ts create mode 100644 src/api/resources/contacts/client/requests/FindContactRequest.ts create mode 100644 src/api/resources/contacts/client/requests/ListAttachedCompaniesRequest.ts create mode 100644 src/api/resources/contacts/client/requests/ListAttachedSubscriptionsRequest.ts create mode 100644 src/api/resources/contacts/client/requests/ListContactsRequest.ts create mode 100644 src/api/resources/contacts/client/requests/ListSegmentsAttachedToContactRequest.ts create mode 100644 src/api/resources/contacts/client/requests/ListTagsAttachedToContactRequest.ts create mode 100644 src/api/resources/contacts/client/requests/MergeContactsRequest.ts create mode 100644 src/api/resources/contacts/client/requests/UnarchiveContactRequest.ts create mode 100644 src/api/resources/contacts/client/requests/UpdateContactRequest.ts create mode 100644 src/api/resources/contacts/client/requests/index.ts create mode 100644 src/api/resources/contacts/index.ts create mode 100644 src/api/resources/contacts/types/Contact.ts create mode 100644 src/api/resources/contacts/types/index.ts create mode 100644 src/api/resources/conversations/client/Client.ts create mode 100644 src/api/resources/conversations/client/index.ts create mode 100644 src/api/resources/conversations/client/requests/AttachContactToConversationRequest.ts create mode 100644 src/api/resources/conversations/client/requests/AutoAssignConversationRequest.ts create mode 100644 src/api/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts create mode 100644 src/api/resources/conversations/client/requests/CreateConversationRequest.ts create mode 100644 src/api/resources/conversations/client/requests/DetachContactFromConversationRequest.ts create mode 100644 src/api/resources/conversations/client/requests/FindConversationRequest.ts create mode 100644 src/api/resources/conversations/client/requests/ListConversationsRequest.ts create mode 100644 src/api/resources/conversations/client/requests/ManageConversationPartsRequest.ts create mode 100644 src/api/resources/conversations/client/requests/ReplyToConversationRequest.ts create mode 100644 src/api/resources/conversations/client/requests/UpdateConversationRequest.ts create mode 100644 src/api/resources/conversations/client/requests/index.ts create mode 100644 src/api/resources/conversations/index.ts create mode 100644 src/api/resources/conversations/types/Conversation.ts create mode 100644 src/api/resources/conversations/types/ConversationsManageRequestBody.ts create mode 100644 src/api/resources/conversations/types/index.ts create mode 100644 src/api/resources/customObjectInstances/index.ts create mode 100644 src/api/resources/customObjectInstances/types/CustomObjectInstance.ts create mode 100644 src/api/resources/customObjectInstances/types/index.ts create mode 100644 src/api/resources/dataAttributes/client/Client.ts create mode 100644 src/api/resources/dataAttributes/client/index.ts create mode 100644 src/api/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts create mode 100644 src/api/resources/dataAttributes/client/requests/ListDataAttributesRequest.ts create mode 100644 src/api/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts create mode 100644 src/api/resources/dataAttributes/client/requests/index.ts create mode 100644 src/api/resources/dataAttributes/index.ts create mode 100644 src/api/resources/dataAttributes/types/DataAttribute.ts create mode 100644 src/api/resources/dataAttributes/types/DataAttributesListRequestModel.ts create mode 100644 src/api/resources/dataAttributes/types/index.ts create mode 100644 src/api/resources/dataEvents/index.ts create mode 100644 src/api/resources/dataEvents/types/DataEvent.ts create mode 100644 src/api/resources/dataEvents/types/index.ts create mode 100644 src/api/resources/dataExport/client/Client.ts create mode 100644 src/api/resources/dataExport/client/index.ts create mode 100644 src/api/resources/dataExport/client/requests/CancelDataExportRequest.ts create mode 100644 src/api/resources/dataExport/client/requests/CreateDataExportRequest.ts create mode 100644 src/api/resources/dataExport/client/requests/DownloadDataExportRequest.ts create mode 100644 src/api/resources/dataExport/client/requests/FindDataExportRequest.ts create mode 100644 src/api/resources/dataExport/client/requests/index.ts create mode 100644 src/api/resources/dataExport/index.ts create mode 100644 src/api/resources/dataExport/types/DataExport.ts create mode 100644 src/api/resources/dataExport/types/index.ts create mode 100644 src/api/resources/events/client/Client.ts create mode 100644 src/api/resources/events/client/index.ts create mode 100644 src/api/resources/events/client/requests/ListEventSummariesRequest.ts create mode 100644 src/api/resources/events/client/requests/ListEventsRequest.ts create mode 100644 src/api/resources/events/client/requests/index.ts create mode 100644 src/api/resources/events/index.ts create mode 100644 src/api/resources/helpCenter/index.ts create mode 100644 src/api/resources/helpCenter/types/Collection.ts create mode 100644 src/api/resources/helpCenter/types/HelpCenter.ts create mode 100644 src/api/resources/helpCenter/types/HelpCenterList.ts create mode 100644 src/api/resources/helpCenter/types/index.ts create mode 100644 src/api/resources/helpCenters/client/Client.ts create mode 100644 src/api/resources/helpCenters/client/index.ts create mode 100644 src/api/resources/helpCenters/client/requests/FindHelpCenterRequest.ts create mode 100644 src/api/resources/helpCenters/client/requests/ListHelpCentersRequest.ts create mode 100644 src/api/resources/helpCenters/client/requests/index.ts create mode 100644 src/api/resources/helpCenters/index.ts create mode 100644 src/api/resources/helpCenters/resources/collections/client/Client.ts create mode 100644 src/api/resources/helpCenters/resources/collections/client/index.ts create mode 100644 src/api/resources/helpCenters/resources/collections/client/requests/CreateCollectionRequest.ts create mode 100644 src/api/resources/helpCenters/resources/collections/client/requests/DeleteCollectionRequest.ts create mode 100644 src/api/resources/helpCenters/resources/collections/client/requests/FindCollectionRequest.ts create mode 100644 src/api/resources/helpCenters/resources/collections/client/requests/ListCollectionsRequest.ts create mode 100644 src/api/resources/helpCenters/resources/collections/client/requests/UpdateCollectionRequest.ts create mode 100644 src/api/resources/helpCenters/resources/collections/client/requests/index.ts create mode 100644 src/api/resources/helpCenters/resources/collections/index.ts create mode 100644 src/api/resources/helpCenters/resources/index.ts create mode 100644 src/api/resources/index.ts create mode 100644 src/api/resources/messages/client/Client.ts create mode 100644 src/api/resources/messages/client/index.ts create mode 100644 src/api/resources/messages/index.ts create mode 100644 src/api/resources/messages/types/Message.ts create mode 100644 src/api/resources/messages/types/index.ts create mode 100644 src/api/resources/news/client/Client.ts create mode 100644 src/api/resources/news/client/index.ts create mode 100644 src/api/resources/news/index.ts create mode 100644 src/api/resources/news/resources/feeds/client/Client.ts create mode 100644 src/api/resources/news/resources/feeds/client/index.ts create mode 100644 src/api/resources/news/resources/feeds/client/requests/FindNewsFeedRequest.ts create mode 100644 src/api/resources/news/resources/feeds/client/requests/ListNewsFeedItemsRequest.ts create mode 100644 src/api/resources/news/resources/feeds/client/requests/index.ts create mode 100644 src/api/resources/news/resources/feeds/index.ts create mode 100644 src/api/resources/news/resources/index.ts create mode 100644 src/api/resources/news/resources/items/client/Client.ts create mode 100644 src/api/resources/news/resources/items/client/index.ts create mode 100644 src/api/resources/news/resources/items/client/requests/DeleteNewsItemRequest.ts create mode 100644 src/api/resources/news/resources/items/client/requests/FindNewsItemRequest.ts create mode 100644 src/api/resources/news/resources/items/client/requests/UpdateNewsItemRequest.ts create mode 100644 src/api/resources/news/resources/items/client/requests/index.ts create mode 100644 src/api/resources/news/resources/items/index.ts create mode 100644 src/api/resources/news/types/NewsItem.ts create mode 100644 src/api/resources/news/types/Newsfeed.ts create mode 100644 src/api/resources/news/types/NewsfeedAssignment.ts create mode 100644 src/api/resources/news/types/index.ts create mode 100644 src/api/resources/notes/client/Client.ts create mode 100644 src/api/resources/notes/client/index.ts create mode 100644 src/api/resources/notes/client/requests/CreateContactNoteRequest.ts create mode 100644 src/api/resources/notes/client/requests/FindNoteRequest.ts create mode 100644 src/api/resources/notes/client/requests/ListContactNotesRequest.ts create mode 100644 src/api/resources/notes/client/requests/index.ts create mode 100644 src/api/resources/notes/index.ts create mode 100644 src/api/resources/notes/types/Note.ts create mode 100644 src/api/resources/notes/types/index.ts create mode 100644 src/api/resources/phoneCallRedirects/client/Client.ts create mode 100644 src/api/resources/phoneCallRedirects/client/index.ts create mode 100644 src/api/resources/phoneCallRedirects/client/requests/CreatePhoneCallRedirectRequest.ts create mode 100644 src/api/resources/phoneCallRedirects/client/requests/index.ts create mode 100644 src/api/resources/phoneCallRedirects/index.ts create mode 100644 src/api/resources/segments/client/Client.ts create mode 100644 src/api/resources/segments/client/index.ts create mode 100644 src/api/resources/segments/client/requests/FindSegmentRequest.ts create mode 100644 src/api/resources/segments/client/requests/ListSegmentsRequest.ts create mode 100644 src/api/resources/segments/client/requests/index.ts create mode 100644 src/api/resources/segments/index.ts create mode 100644 src/api/resources/segments/types/Segment.ts create mode 100644 src/api/resources/segments/types/index.ts create mode 100644 src/api/resources/subscriptionTypes/client/Client.ts create mode 100644 src/api/resources/subscriptionTypes/client/index.ts create mode 100644 src/api/resources/subscriptionTypes/index.ts create mode 100644 src/api/resources/subscriptionTypes/types/SubscriptionType.ts create mode 100644 src/api/resources/subscriptionTypes/types/index.ts create mode 100644 src/api/resources/tags/client/Client.ts create mode 100644 src/api/resources/tags/client/index.ts create mode 100644 src/api/resources/tags/client/requests/DeleteTagRequest.ts create mode 100644 src/api/resources/tags/client/requests/FindTagRequest.ts create mode 100644 src/api/resources/tags/client/requests/TagContactRequest.ts create mode 100644 src/api/resources/tags/client/requests/TagConversationRequest.ts create mode 100644 src/api/resources/tags/client/requests/TagTicketRequest.ts create mode 100644 src/api/resources/tags/client/requests/UntagContactRequest.ts create mode 100644 src/api/resources/tags/client/requests/UntagConversationRequest.ts create mode 100644 src/api/resources/tags/client/requests/UntagTicketRequest.ts create mode 100644 src/api/resources/tags/client/requests/index.ts create mode 100644 src/api/resources/tags/index.ts create mode 100644 src/api/resources/tags/types/Tag.ts create mode 100644 src/api/resources/tags/types/TagsCreateRequestBody.ts create mode 100644 src/api/resources/tags/types/index.ts create mode 100644 src/api/resources/teams/client/Client.ts create mode 100644 src/api/resources/teams/client/index.ts create mode 100644 src/api/resources/teams/client/requests/FindTeamRequest.ts create mode 100644 src/api/resources/teams/client/requests/index.ts create mode 100644 src/api/resources/teams/index.ts create mode 100644 src/api/resources/teams/types/Team.ts create mode 100644 src/api/resources/teams/types/index.ts create mode 100644 src/api/resources/ticketTypes/client/Client.ts create mode 100644 src/api/resources/ticketTypes/client/index.ts create mode 100644 src/api/resources/ticketTypes/client/requests/CreateTicketTypeRequest.ts create mode 100644 src/api/resources/ticketTypes/client/requests/FindTicketTypeRequest.ts create mode 100644 src/api/resources/ticketTypes/client/requests/UpdateTicketTypeRequest.ts create mode 100644 src/api/resources/ticketTypes/client/requests/index.ts create mode 100644 src/api/resources/ticketTypes/index.ts create mode 100644 src/api/resources/ticketTypes/resources/attributes/client/Client.ts create mode 100644 src/api/resources/ticketTypes/resources/attributes/client/index.ts create mode 100644 src/api/resources/ticketTypes/resources/attributes/client/requests/CreateTicketTypeAttributeRequest.ts create mode 100644 src/api/resources/ticketTypes/resources/attributes/client/requests/UpdateTicketTypeAttributeRequest.ts create mode 100644 src/api/resources/ticketTypes/resources/attributes/client/requests/index.ts create mode 100644 src/api/resources/ticketTypes/resources/attributes/index.ts create mode 100644 src/api/resources/ticketTypes/resources/index.ts create mode 100644 src/api/resources/tickets/client/Client.ts create mode 100644 src/api/resources/tickets/client/index.ts create mode 100644 src/api/resources/tickets/client/requests/CreateTicketRequest.ts create mode 100644 src/api/resources/tickets/client/requests/FindTicketRequest.ts create mode 100644 src/api/resources/tickets/client/requests/ReplyToTicketRequest.ts create mode 100644 src/api/resources/tickets/client/requests/UpdateTicketRequest.ts create mode 100644 src/api/resources/tickets/client/requests/index.ts create mode 100644 src/api/resources/tickets/index.ts create mode 100644 src/api/resources/tickets/types/Ticket.ts create mode 100644 src/api/resources/tickets/types/TicketContacts.ts create mode 100644 src/api/resources/tickets/types/TicketPart.ts create mode 100644 src/api/resources/tickets/types/TicketType.ts create mode 100644 src/api/resources/tickets/types/TicketsReplyRequestBody.ts create mode 100644 src/api/resources/tickets/types/index.ts create mode 100644 src/api/resources/visitors/client/Client.ts create mode 100644 src/api/resources/visitors/client/index.ts create mode 100644 src/api/resources/visitors/client/requests/FindVisitorRequest.ts create mode 100644 src/api/resources/visitors/client/requests/MergeVisitorToContactRequest.ts create mode 100644 src/api/resources/visitors/client/requests/index.ts create mode 100644 src/api/resources/visitors/index.ts create mode 100644 src/api/types/ActivityLog.ts create mode 100644 src/api/types/ActivityLogList.ts create mode 100644 src/api/types/ActivityLogMetadata.ts create mode 100644 src/api/types/AddressableList.ts create mode 100644 src/api/types/AdminList.ts create mode 100644 src/api/types/AdminPriorityLevel.ts create mode 100644 src/api/types/AdminReplyConversationRequest.ts create mode 100644 src/api/types/AdminReplyTicketRequest.ts create mode 100644 src/api/types/AdminWithApp.ts create mode 100644 src/api/types/App.ts create mode 100644 src/api/types/ArticleContent.ts create mode 100644 src/api/types/ArticleList.ts create mode 100644 src/api/types/ArticleStatistics.ts create mode 100644 src/api/types/ArticleTranslatedContent.ts create mode 100644 src/api/types/AssignConversationRequest.ts create mode 100644 src/api/types/CloseConversationRequest.ts create mode 100644 src/api/types/CollectionList.ts create mode 100644 src/api/types/CompanyAttachedContacts.ts create mode 100644 src/api/types/CompanyAttachedSegments.ts create mode 100644 src/api/types/CompanyList.ts create mode 100644 src/api/types/CompanyScroll.ts create mode 100644 src/api/types/ContactArchived.ts create mode 100644 src/api/types/ContactAttachedCompanies.ts create mode 100644 src/api/types/ContactCompanies.ts create mode 100644 src/api/types/ContactDeleted.ts create mode 100644 src/api/types/ContactList.ts create mode 100644 src/api/types/ContactLocation.ts create mode 100644 src/api/types/ContactNotes.ts create mode 100644 src/api/types/ContactReference.ts create mode 100644 src/api/types/ContactReplyBaseRequest.ts create mode 100644 src/api/types/ContactReplyConversationRequest.ts create mode 100644 src/api/types/ContactReplyEmailRequest.ts create mode 100644 src/api/types/ContactReplyIntercomUserIdRequest.ts create mode 100644 src/api/types/ContactReplyTicketEmailRequest.ts create mode 100644 src/api/types/ContactReplyTicketIntercomUserIdRequest.ts create mode 100644 src/api/types/ContactReplyTicketRequest.ts create mode 100644 src/api/types/ContactReplyTicketUserIdRequest.ts create mode 100644 src/api/types/ContactReplyUserIdRequest.ts create mode 100644 src/api/types/ContactSegments.ts create mode 100644 src/api/types/ContactSocialProfiles.ts create mode 100644 src/api/types/ContactSubscriptionTypes.ts create mode 100644 src/api/types/ContactTags.ts create mode 100644 src/api/types/ContactUnarchived.ts create mode 100644 src/api/types/ContentSourcesList.ts create mode 100644 src/api/types/ConversationAttachmentFiles.ts create mode 100644 src/api/types/ConversationContacts.ts create mode 100644 src/api/types/ConversationFirstContactReply.ts create mode 100644 src/api/types/ConversationPart.ts create mode 100644 src/api/types/ConversationPartAuthor.ts create mode 100644 src/api/types/ConversationParts.ts create mode 100644 src/api/types/ConversationRating.ts create mode 100644 src/api/types/ConversationSource.ts create mode 100644 src/api/types/ConversationStatistics.ts create mode 100644 src/api/types/ConversationTeammates.ts create mode 100644 src/api/types/CreateContactRequest.ts create mode 100644 src/api/types/CreateDataEventRequest.ts create mode 100644 src/api/types/CreateMessageRequest.ts create mode 100644 src/api/types/CreateOrUpdateTagRequest.ts create mode 100644 src/api/types/CreateTicketReplyWithCommentRequest.ts create mode 100644 src/api/types/CursorPages.ts create mode 100644 src/api/types/CustomAttributes.ts create mode 100644 src/api/types/CustomerRequest.ts create mode 100644 src/api/types/DataAttributeList.ts create mode 100644 src/api/types/DataEventList.ts create mode 100644 src/api/types/DataEventSummary.ts create mode 100644 src/api/types/DataEventSummaryItem.ts create mode 100644 src/api/types/DataExportCsv.ts create mode 100644 src/api/types/DeletedArticleObject.ts create mode 100644 src/api/types/DeletedCollectionObject.ts create mode 100644 src/api/types/DeletedCompanyObject.ts create mode 100644 src/api/types/DeletedObject.ts create mode 100644 src/api/types/Error_.ts create mode 100644 src/api/types/FileAttribute.ts create mode 100644 src/api/types/GroupContent.ts create mode 100644 src/api/types/GroupTranslatedContent.ts create mode 100644 src/api/types/LinkedObject.ts create mode 100644 src/api/types/LinkedObjectList.ts create mode 100644 src/api/types/MultipleFilterSearchRequest.ts create mode 100644 src/api/types/NewsItemRequest.ts create mode 100644 src/api/types/NoteList.ts create mode 100644 src/api/types/OpenConversationRequest.ts create mode 100644 src/api/types/PagesLink.ts create mode 100644 src/api/types/PaginatedConversationResponse.ts create mode 100644 src/api/types/PaginatedNewsItemResponse.ts create mode 100644 src/api/types/PaginatedNewsfeedResponse.ts create mode 100644 src/api/types/PartAttachment.ts create mode 100644 src/api/types/PhoneSwitch.ts create mode 100644 src/api/types/RedactConversationRequest.ts create mode 100644 src/api/types/Reference.ts create mode 100644 src/api/types/ReplyConversationRequest.ts create mode 100644 src/api/types/SearchRequest.ts create mode 100644 src/api/types/SegmentList.ts create mode 100644 src/api/types/SingleFilterSearchRequest.ts create mode 100644 src/api/types/SlaApplied.ts create mode 100644 src/api/types/SnoozeConversationRequest.ts create mode 100644 src/api/types/SocialProfile.ts create mode 100644 src/api/types/StartingAfterPaging.ts create mode 100644 src/api/types/SubscriptionTypeList.ts create mode 100644 src/api/types/TagCompanyRequest.ts create mode 100644 src/api/types/TagList.ts create mode 100644 src/api/types/TagMultipleUsersRequest.ts create mode 100644 src/api/types/Tags.ts create mode 100644 src/api/types/TeamList.ts create mode 100644 src/api/types/TeamPriorityLevel.ts create mode 100644 src/api/types/TicketCustomAttributes.ts create mode 100644 src/api/types/TicketList.ts create mode 100644 src/api/types/TicketPartAuthor.ts create mode 100644 src/api/types/TicketParts.ts create mode 100644 src/api/types/TicketReply.ts create mode 100644 src/api/types/TicketRequestCustomAttributes.ts create mode 100644 src/api/types/TicketTypeAttribute.ts create mode 100644 src/api/types/TicketTypeAttributeList.ts create mode 100644 src/api/types/TicketTypeList.ts create mode 100644 src/api/types/Translation.ts create mode 100644 src/api/types/UntagCompanyRequest.ts create mode 100644 src/api/types/UpdateVisitorRequest.ts create mode 100644 src/api/types/Visitor.ts create mode 100644 src/api/types/VisitorDeletedObject.ts create mode 100644 src/api/types/index.ts create mode 100644 src/api/version.ts create mode 100644 src/core/auth/BasicAuth.ts create mode 100644 src/core/auth/BearerToken.ts create mode 100644 src/core/auth/index.ts create mode 100644 src/core/fetcher/APIResponse.ts create mode 100644 src/core/fetcher/Fetcher.ts create mode 100644 src/core/fetcher/Supplier.ts create mode 100644 src/core/fetcher/createRequestUrl.ts create mode 100644 src/core/fetcher/getFetchFn.ts create mode 100644 src/core/fetcher/getHeader.ts create mode 100644 src/core/fetcher/getRequestBody.ts create mode 100644 src/core/fetcher/getResponseBody.ts create mode 100644 src/core/fetcher/index.ts create mode 100644 src/core/fetcher/makeRequest.ts create mode 100644 src/core/fetcher/requestWithRetries.ts create mode 100644 src/core/fetcher/signals.ts create mode 100644 src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts create mode 100644 src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts create mode 100644 src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts create mode 100644 src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts create mode 100644 src/core/index.ts create mode 100644 src/core/pagination/Page.ts create mode 100644 src/core/pagination/Pageable.ts create mode 100644 src/core/pagination/index.ts create mode 100644 src/core/runtime/index.ts create mode 100644 src/core/runtime/runtime.ts create mode 100644 src/core/utils/index.ts create mode 100644 src/core/utils/setObjectProperty.ts create mode 100644 src/environments.ts create mode 100644 src/errors/IntercomError.ts create mode 100644 src/errors/IntercomTimeoutError.ts create mode 100644 src/errors/index.ts create mode 100644 src/index.ts create mode 100644 src/version.ts delete mode 100644 test/integration/admins.test.ts delete mode 100644 test/integration/articles.test.ts delete mode 100644 test/integration/companies.test.ts delete mode 100644 test/integration/contacts.test.ts delete mode 100644 test/integration/conversations.test.ts delete mode 100644 test/integration/counts.test.ts delete mode 100644 test/integration/dataAttributes.test.ts delete mode 100644 test/integration/dataExport.test.ts delete mode 100644 test/integration/events.test.ts delete mode 100644 test/integration/helpCenter/collections.test.ts delete mode 100644 test/integration/helpCenter/sections.test.ts delete mode 100644 test/integration/integration.test.ts delete mode 100644 test/integration/messages.test.ts delete mode 100644 test/integration/notes.test.ts delete mode 100644 test/integration/phoneCallRedirect.test.ts delete mode 100644 test/integration/segments.test.ts delete mode 100644 test/integration/subscriptions.test.ts delete mode 100644 test/integration/tags.test.ts delete mode 100644 test/integration/teams.test.ts delete mode 100644 test/integration/utils/config.ts delete mode 100644 test/integration/utils/date.ts delete mode 100644 test/integration/utils/random.ts delete mode 100644 test/integration/visitors.test.ts delete mode 100644 test/unit/admin.test.ts delete mode 100644 test/unit/article.test.ts delete mode 100644 test/unit/client.test.ts delete mode 100644 test/unit/company.test.ts delete mode 100644 test/unit/contact.test.ts delete mode 100644 test/unit/conversation.test.ts delete mode 100644 test/unit/counts.test.ts delete mode 100644 test/unit/dataAttribute.test.ts delete mode 100644 test/unit/errors.test.ts delete mode 100644 test/unit/event.test.ts delete mode 100644 test/unit/helpCenter.test.ts delete mode 100644 test/unit/index.test.ts delete mode 100644 test/unit/message.test.ts delete mode 100644 test/unit/notes.test.ts delete mode 100644 test/unit/request-opts.test.ts delete mode 100644 test/unit/segment.test.ts delete mode 100644 test/unit/subscription.test.ts delete mode 100644 test/unit/tag.test.ts delete mode 100644 test/unit/team.test.ts delete mode 100644 test/unit/visitor.test.ts create mode 100644 tests/custom.test.ts create mode 100644 tests/integration/admins.test.ts create mode 100644 tests/integration/articles.test.ts create mode 100644 tests/integration/companies.test.ts create mode 100644 tests/integration/contacts.test.ts create mode 100644 tests/integration/conversations.test.ts create mode 100644 tests/integration/dataAttributes.test.ts create mode 100644 tests/integration/dataExport.test.ts create mode 100644 tests/integration/events.test.ts create mode 100644 tests/integration/helpCenter/collections.test.ts create mode 100644 tests/integration/helpers.ts create mode 100644 tests/integration/integration.test.ts create mode 100644 tests/integration/messages.test.ts create mode 100644 tests/integration/notes.test.ts create mode 100644 tests/integration/pagination.test.ts create mode 100644 tests/integration/phoneCallRedirect.test.ts create mode 100644 tests/integration/segments.test.ts create mode 100644 tests/integration/subscriptions.test.ts create mode 100644 tests/integration/tags.test.ts create mode 100644 tests/integration/teams.test.ts create mode 100644 tests/integration/utils/createClient.ts create mode 100644 tests/integration/utils/date.ts create mode 100644 tests/integration/utils/random.ts create mode 100644 tests/integration/utils/wait.ts create mode 100644 tests/integration/visitors.test.ts create mode 100644 tests/unit/auth/BasicAuth.test.ts create mode 100644 tests/unit/auth/BearerToken.test.ts create mode 100644 tests/unit/fetcher/Fetcher.test.ts create mode 100644 tests/unit/fetcher/createRequestUrl.test.ts create mode 100644 tests/unit/fetcher/getFetchFn.test.ts create mode 100644 tests/unit/fetcher/getRequestBody.test.ts create mode 100644 tests/unit/fetcher/getResponseBody.test.ts create mode 100644 tests/unit/fetcher/makeRequest.test.ts create mode 100644 tests/unit/fetcher/requestWithRetries.test.ts create mode 100644 tests/unit/fetcher/signals.test.ts create mode 100644 tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts create mode 100644 tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts create mode 100644 tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts create mode 100644 tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts create mode 100644 tests/unit/fetcher/stream-wrappers/webpack.test.ts create mode 100644 tests/unit/fetcher/test-file.txt diff --git a/.circleci/config.yml b/.circleci/config.yml deleted file mode 100644 index 25cfd6d3..00000000 --- a/.circleci/config.yml +++ /dev/null @@ -1,64 +0,0 @@ -version: 2 -jobs: - build: - docker: - - image: cimg/node:20.4.0 - working_directory: ~/intercom-node - steps: - - checkout - - run: export PATH="${PATH}:/home/circleci/.yarn/bin" - - run: npm install --prefix=$HOME/.local --global corepack - - restore_cache: - key: dependency-cache-{{ checksum "yarn.lock" }} - - run: yarn - - save_cache: - key: dependency-cache-{{ checksum "yarn.lock" }} - paths: - - node_modules - - .yarn/cache - - restore_cache: - key: dist-cache-{{ .Environment.CIRCLE_SHA1 }} - - run: yarn prepublish - - save_cache: - key: dist-cache-{{ .Environment.CIRCLE_SHA1 }} - paths: - - dist - unit_test: - docker: - - image: cimg/node:20.4.0 - working_directory: ~/intercom-node - steps: - - checkout - - restore_cache: - key: dependency-cache-{{ checksum "yarn.lock" }} - - run: yarn test:unit - integration_test: - docker: - - image: cimg/node:20.4.0 - environment: - API_TOKEN: $API_TOKEN - working_directory: ~/intercom-node - - steps: - - checkout - - restore_cache: - key: dependency-cache-{{ checksum "yarn.lock" }} - - restore_cache: - key: dist-cache-{{ .Environment.CIRCLE_SHA1 }} - - run: yarn test:integration - -workflows: - version: 2 - build_and_test: - jobs: - - build - - unit_test: - requires: - - build - - integration_test: - requires: - - build - -notify: - webhooks: - - url: https://muster.intercom.io/circle_webhooks diff --git a/.editorconfig b/.editorconfig deleted file mode 100644 index ec7cea79..00000000 --- a/.editorconfig +++ /dev/null @@ -1,16 +0,0 @@ -root = true - -[*] -end_of_line = lf -insert_final_newline = true -trim_trailing_whitespace = true -charset = utf-8 -indent_style = space -indent_size = 4 - -[*.md] -trim_trailing_whitespace = false - -[*.{json,yml}] -indent_style = space -indent_size = 2 diff --git a/.eslintignore b/.eslintignore deleted file mode 100644 index b354c747..00000000 --- a/.eslintignore +++ /dev/null @@ -1,3 +0,0 @@ -# Temporary workaround for Gulp's ESLint -dist/ -node_modules/ diff --git a/.eslintrc b/.eslintrc deleted file mode 100644 index 74f843d4..00000000 --- a/.eslintrc +++ /dev/null @@ -1,46 +0,0 @@ -{ - "root": true, - "parser": "@typescript-eslint/parser", - "plugins": ["@typescript-eslint", "no-only-tests"], - "rules": { - "keyword-spacing": 2, - "array-bracket-spacing": [2, "never"], - "space-in-parens": [2, "never"], - "no-multiple-empty-lines": [ - 2, - { - "max": 2 - } - ], - "no-eval": 2, - "no-with": 2, - "no-debugger": 2, - "no-dupe-args": 2, - "no-dupe-keys": 2, - "no-duplicate-case": 2, - "no-empty-character-class": 2, - "no-empty": 2, - "no-ex-assign": 2, - "no-extra-boolean-cast": 2, - "no-extra-semi": 2, - "no-func-assign": 2, - "no-inner-declarations": [2, "functions"], - "no-invalid-regexp": 2, - "no-irregular-whitespace": 2, - "no-negated-in-lhs": 2, - "no-obj-calls": 2, - "no-regex-spaces": 2, - "no-sparse-arrays": 2, - "no-unreachable": 2, - "use-isnan": 2, - "valid-typeof": 2, - "require-await": "error", - "no-only-tests/no-only-tests": "error" - }, - "extends": [ - "eslint:recommended", - "plugin:@typescript-eslint/eslint-recommended", - "plugin:@typescript-eslint/recommended", - "prettier" - ] -} diff --git a/.fernignore b/.fernignore index 41e2e168..4c7324f1 100644 --- a/.fernignore +++ b/.fernignore @@ -3,4 +3,6 @@ .github/PULL_REQUEST_TEMPLATE.md .gitattributes LICENSE -REPO_OWNER \ No newline at end of file +REPO_OWNER +tests/integration +.github/workflows/ci.yml \ No newline at end of file diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 00000000..58483329 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,62 @@ +name: ci + +on: [push] + +jobs: + compile: + runs-on: ubuntu-latest + + steps: + - name: Checkout repo + uses: actions/checkout@v3 + + - name: Set up node + uses: actions/setup-node@v3 + + - name: Compile + run: yarn && yarn build + + test: + runs-on: ubuntu-latest + + steps: + - name: Checkout repo + uses: actions/checkout@v3 + + - name: Set up node + uses: actions/setup-node@v3 + + - name: Compile + run: yarn + + - name: Test + run: yarn test + env: + INTERCOM_API_KEY: ${{ secrets.INTERCOM_API_KEY }} + + publish: + needs: [ compile, test ] + if: github.event_name == 'push' && contains(github.ref, 'refs/tags/') + runs-on: ubuntu-latest + steps: + - name: Checkout repo + uses: actions/checkout@v3 + - name: Set up node + uses: actions/setup-node@v3 + - name: Install dependencies + run: yarn install + - name: Build + run: yarn build + + - name: Publish to npm + run: | + npm config set //registry.npmjs.org/:_authToken ${NPM_TOKEN} + if [[ ${GITHUB_REF} == *alpha* ]]; then + npm publish --access public --tag alpha + elif [[ ${GITHUB_REF} == *beta* ]]; then + npm publish --access public --tag beta + else + npm publish --access public + fi + env: + NPM_TOKEN: ${{ secrets.FERN_NPM_TOKEN }} \ No newline at end of file diff --git a/.gitignore b/.gitignore index 243c86ed..72271e04 100644 --- a/.gitignore +++ b/.gitignore @@ -1,44 +1,3 @@ -### Node ### -# Logs -logs -*.log -npm-debug.log* - -# Runtime data -pids -*.pid -*.seed - -# Coverage directory used by nyc -.nyc_output - -# node-waf configuration -.lock-wscript - -# Dependency directory -# https://docs.npmjs.com/misc/faq#should-i-check-my-node-modules-folder-into-git node_modules - -# Compiled version -dist - -# Yarn 3.x -.pnp.* -.yarn/* -!.yarn/patches -!.yarn/plugins -!.yarn/releases -!.yarn/sdks -!.yarn/versions - -# Typescript mappings for lib -lib/*.map -lib/**/*.map -# Typescript mappings for test -test/*.map -test/**/*.map -# Generated Javascript -lib/*.js -lib/**/*.js -test/*.js -test/**/*.js +.DS_Store +/dist \ No newline at end of file diff --git a/.npmignore b/.npmignore index 4b88ae94..6db0876c 100644 --- a/.npmignore +++ b/.npmignore @@ -1,2 +1,9 @@ -# Should exist, because dist is in .gitignore -# More here: https://docs.npmjs.com/cli/v8/using-npm/developers#keeping-files-out-of-your-package +node_modules +src +tests +.gitignore +.github +.fernignore +.prettierrc.yml +tsconfig.json +yarn.lock \ No newline at end of file diff --git a/.nycrc b/.nycrc deleted file mode 100644 index 1fab4bc8..00000000 --- a/.nycrc +++ /dev/null @@ -1,17 +0,0 @@ -{ - "extends": "@istanbuljs/nyc-config-typescript", - "include": [ - "lib/**/*.ts" - ], - "exclude": [ - "lib/**/*.types.ts" - ], - "require": [ - "ts-node/register" - ], - "sourceMap": true, - "instrument": true, - "cache": true, - "all": true, - "check-coverage": true -} diff --git a/.prettierignore b/.prettierignore deleted file mode 100644 index ed1e58ee..00000000 --- a/.prettierignore +++ /dev/null @@ -1,3 +0,0 @@ -# Ignore artifacts: -dist -node_modules diff --git a/.prettierrc.json b/.prettierrc.json deleted file mode 100644 index b4ed29b5..00000000 --- a/.prettierrc.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "trailingComma": "es5", - "endOfLine": "lf", - "useTabs": false, - "tabWidth": 4, - "semi": true, - "singleQuote": true -} diff --git a/.prettierrc.yml b/.prettierrc.yml new file mode 100644 index 00000000..0c06786b --- /dev/null +++ b/.prettierrc.yml @@ -0,0 +1,2 @@ +tabWidth: 4 +printWidth: 120 diff --git a/.vscode/settings.json b/.vscode/settings.json deleted file mode 100644 index 324a9612..00000000 --- a/.vscode/settings.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "editor.defaultFormatter": "esbenp.prettier-vscode", - "editor.formatOnSave": true -} diff --git a/.yarn/releases/yarn-3.1.1.cjs b/.yarn/releases/yarn-3.1.1.cjs deleted file mode 100755 index f5f2adca..00000000 --- a/.yarn/releases/yarn-3.1.1.cjs +++ /dev/null @@ -1,768 +0,0 @@ -#!/usr/bin/env node -/* eslint-disable */ -//prettier-ignore -(()=>{var Mfe=Object.create,Vf=Object.defineProperty,Ofe=Object.defineProperties,Kfe=Object.getOwnPropertyDescriptor,Ufe=Object.getOwnPropertyDescriptors,Hfe=Object.getOwnPropertyNames,hE=Object.getOwnPropertySymbols,Gfe=Object.getPrototypeOf,eb=Object.prototype.hasOwnProperty,lO=Object.prototype.propertyIsEnumerable;var cO=(t,e,r)=>e in t?Vf(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,P=(t,e)=>{for(var r in e||(e={}))eb.call(e,r)&&cO(t,r,e[r]);if(hE)for(var r of hE(e))lO.call(e,r)&&cO(t,r,e[r]);return t},_=(t,e)=>Ofe(t,Ufe(e)),jfe=t=>Vf(t,"__esModule",{value:!0});var qr=(t,e)=>{var r={};for(var i in t)eb.call(t,i)&&e.indexOf(i)<0&&(r[i]=t[i]);if(t!=null&&hE)for(var i of hE(t))e.indexOf(i)<0&&lO.call(t,i)&&(r[i]=t[i]);return r},Yfe=(t,e)=>()=>(t&&(e=t(t=0)),e),E=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),it=(t,e)=>{for(var r in e)Vf(t,r,{get:e[r],enumerable:!0})},qfe=(t,e,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Hfe(e))!eb.call(t,i)&&i!=="default"&&Vf(t,i,{get:()=>e[i],enumerable:!(r=Kfe(e,i))||r.enumerable});return t},ie=t=>qfe(jfe(Vf(t!=null?Mfe(Gfe(t)):{},"default",t&&t.__esModule&&"default"in t?{get:()=>t.default,enumerable:!0}:{value:t,enumerable:!0})),t);var MO=E((i$e,FO)=>{FO.exports=NO;NO.sync=Ahe;var LO=require("fs");function lhe(t,e){var r=e.pathExt!==void 0?e.pathExt:process.env.PATHEXT;if(!r||(r=r.split(";"),r.indexOf("")!==-1))return!0;for(var i=0;i{OO.exports=KO;KO.sync=che;var UO=require("fs");function KO(t,e,r){UO.stat(t,function(i,n){r(i,i?!1:HO(n,e))})}function che(t,e){return HO(UO.statSync(t),e)}function HO(t,e){return t.isFile()&&uhe(t,e)}function uhe(t,e){var r=t.mode,i=t.uid,n=t.gid,s=e.uid!==void 0?e.uid:process.getuid&&process.getuid(),o=e.gid!==void 0?e.gid:process.getgid&&process.getgid(),a=parseInt("100",8),l=parseInt("010",8),c=parseInt("001",8),u=a|l,g=r&c||r&l&&n===o||r&a&&i===s||r&u&&s===0;return g}});var YO=E((o$e,jO)=>{var s$e=require("fs"),xE;process.platform==="win32"||global.TESTING_WINDOWS?xE=MO():xE=GO();jO.exports=db;db.sync=ghe;function db(t,e,r){if(typeof e=="function"&&(r=e,e={}),!r){if(typeof Promise!="function")throw new TypeError("callback not provided");return new Promise(function(i,n){db(t,e||{},function(s,o){s?n(s):i(o)})})}xE(t,e||{},function(i,n){i&&(i.code==="EACCES"||e&&e.ignoreErrors)&&(i=null,n=!1),r(i,n)})}function ghe(t,e){try{return xE.sync(t,e||{})}catch(r){if(e&&e.ignoreErrors||r.code==="EACCES")return!1;throw r}}});var XO=E((a$e,qO)=>{var eu=process.platform==="win32"||process.env.OSTYPE==="cygwin"||process.env.OSTYPE==="msys",JO=require("path"),fhe=eu?";":":",WO=YO(),zO=t=>Object.assign(new Error(`not found: ${t}`),{code:"ENOENT"}),VO=(t,e)=>{let r=e.colon||fhe,i=t.match(/\//)||eu&&t.match(/\\/)?[""]:[...eu?[process.cwd()]:[],...(e.path||process.env.PATH||"").split(r)],n=eu?e.pathExt||process.env.PATHEXT||".EXE;.CMD;.BAT;.COM":"",s=eu?n.split(r):[""];return eu&&t.indexOf(".")!==-1&&s[0]!==""&&s.unshift(""),{pathEnv:i,pathExt:s,pathExtExe:n}},_O=(t,e,r)=>{typeof e=="function"&&(r=e,e={}),e||(e={});let{pathEnv:i,pathExt:n,pathExtExe:s}=VO(t,e),o=[],a=c=>new Promise((u,g)=>{if(c===i.length)return e.all&&o.length?u(o):g(zO(t));let f=i[c],h=/^".*"$/.test(f)?f.slice(1,-1):f,p=JO.join(h,t),d=!h&&/^\.[\\\/]/.test(t)?t.slice(0,2)+p:p;u(l(d,c,0))}),l=(c,u,g)=>new Promise((f,h)=>{if(g===n.length)return f(a(u+1));let p=n[g];WO(c+p,{pathExt:s},(d,m)=>{if(!d&&m)if(e.all)o.push(c+p);else return f(c+p);return f(l(c,u,g+1))})});return r?a(0).then(c=>r(null,c),r):a(0)},hhe=(t,e)=>{e=e||{};let{pathEnv:r,pathExt:i,pathExtExe:n}=VO(t,e),s=[];for(let o=0;o{"use strict";var ZO=(t={})=>{let e=t.env||process.env;return(t.platform||process.platform)!=="win32"?"PATH":Object.keys(e).reverse().find(i=>i.toUpperCase()==="PATH")||"Path"};Cb.exports=ZO;Cb.exports.default=ZO});var iK=E((l$e,eK)=>{"use strict";var tK=require("path"),phe=XO(),dhe=$O();function rK(t,e){let r=t.options.env||process.env,i=process.cwd(),n=t.options.cwd!=null,s=n&&process.chdir!==void 0&&!process.chdir.disabled;if(s)try{process.chdir(t.options.cwd)}catch(a){}let o;try{o=phe.sync(t.command,{path:r[dhe({env:r})],pathExt:e?tK.delimiter:void 0})}catch(a){}finally{s&&process.chdir(i)}return o&&(o=tK.resolve(n?t.options.cwd:"",o)),o}function Che(t){return rK(t)||rK(t,!0)}eK.exports=Che});var nK=E((c$e,mb)=>{"use strict";var Eb=/([()\][%!^"`<>&|;, *?])/g;function mhe(t){return t=t.replace(Eb,"^$1"),t}function Ehe(t,e){return t=`${t}`,t=t.replace(/(\\*)"/g,'$1$1\\"'),t=t.replace(/(\\*)$/,"$1$1"),t=`"${t}"`,t=t.replace(Eb,"^$1"),e&&(t=t.replace(Eb,"^$1")),t}mb.exports.command=mhe;mb.exports.argument=Ehe});var oK=E((u$e,sK)=>{"use strict";sK.exports=/^#!(.*)/});var AK=E((g$e,aK)=>{"use strict";var Ihe=oK();aK.exports=(t="")=>{let e=t.match(Ihe);if(!e)return null;let[r,i]=e[0].replace(/#! ?/,"").split(" "),n=r.split("/").pop();return n==="env"?i:i?`${n} ${i}`:n}});var cK=E((f$e,lK)=>{"use strict";var Ib=require("fs"),yhe=AK();function whe(t){let e=150,r=Buffer.alloc(e),i;try{i=Ib.openSync(t,"r"),Ib.readSync(i,r,0,e,0),Ib.closeSync(i)}catch(n){}return yhe(r.toString())}lK.exports=whe});var hK=E((h$e,uK)=>{"use strict";var Bhe=require("path"),gK=iK(),fK=nK(),Qhe=cK(),bhe=process.platform==="win32",vhe=/\.(?:com|exe)$/i,She=/node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;function xhe(t){t.file=gK(t);let e=t.file&&Qhe(t.file);return e?(t.args.unshift(t.file),t.command=e,gK(t)):t.file}function khe(t){if(!bhe)return t;let e=xhe(t),r=!vhe.test(e);if(t.options.forceShell||r){let i=She.test(e);t.command=Bhe.normalize(t.command),t.command=fK.command(t.command),t.args=t.args.map(s=>fK.argument(s,i));let n=[t.command].concat(t.args).join(" ");t.args=["/d","/s","/c",`"${n}"`],t.command=process.env.comspec||"cmd.exe",t.options.windowsVerbatimArguments=!0}return t}function Phe(t,e,r){e&&!Array.isArray(e)&&(r=e,e=null),e=e?e.slice(0):[],r=Object.assign({},r);let i={command:t,args:e,options:r,file:void 0,original:{command:t,args:e}};return r.shell?i:khe(i)}uK.exports=Phe});var CK=E((p$e,pK)=>{"use strict";var yb=process.platform==="win32";function wb(t,e){return Object.assign(new Error(`${e} ${t.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${e} ${t.command}`,path:t.command,spawnargs:t.args})}function Dhe(t,e){if(!yb)return;let r=t.emit;t.emit=function(i,n){if(i==="exit"){let s=dK(n,e,"spawn");if(s)return r.call(t,"error",s)}return r.apply(t,arguments)}}function dK(t,e){return yb&&t===1&&!e.file?wb(e.original,"spawn"):null}function Rhe(t,e){return yb&&t===1&&!e.file?wb(e.original,"spawnSync"):null}pK.exports={hookChildProcess:Dhe,verifyENOENT:dK,verifyENOENTSync:Rhe,notFoundError:wb}});var bb=E((d$e,tu)=>{"use strict";var mK=require("child_process"),Bb=hK(),Qb=CK();function EK(t,e,r){let i=Bb(t,e,r),n=mK.spawn(i.command,i.args,i.options);return Qb.hookChildProcess(n,i),n}function Fhe(t,e,r){let i=Bb(t,e,r),n=mK.spawnSync(i.command,i.args,i.options);return n.error=n.error||Qb.verifyENOENTSync(n.status,i),n}tu.exports=EK;tu.exports.spawn=EK;tu.exports.sync=Fhe;tu.exports._parse=Bb;tu.exports._enoent=Qb});var yK=E((y$e,IK)=>{"use strict";IK.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}});var Nb=E((w$e,wK)=>{var gh=yK(),BK={};for(let t of Object.keys(gh))BK[gh[t]]=t;var Xe={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};wK.exports=Xe;for(let t of Object.keys(Xe)){if(!("channels"in Xe[t]))throw new Error("missing channels property: "+t);if(!("labels"in Xe[t]))throw new Error("missing channel labels property: "+t);if(Xe[t].labels.length!==Xe[t].channels)throw new Error("channel and label counts mismatch: "+t);let{channels:e,labels:r}=Xe[t];delete Xe[t].channels,delete Xe[t].labels,Object.defineProperty(Xe[t],"channels",{value:e}),Object.defineProperty(Xe[t],"labels",{value:r})}Xe.rgb.hsl=function(t){let e=t[0]/255,r=t[1]/255,i=t[2]/255,n=Math.min(e,r,i),s=Math.max(e,r,i),o=s-n,a,l;s===n?a=0:e===s?a=(r-i)/o:r===s?a=2+(i-e)/o:i===s&&(a=4+(e-r)/o),a=Math.min(a*60,360),a<0&&(a+=360);let c=(n+s)/2;return s===n?l=0:c<=.5?l=o/(s+n):l=o/(2-s-n),[a,l*100,c*100]};Xe.rgb.hsv=function(t){let e,r,i,n,s,o=t[0]/255,a=t[1]/255,l=t[2]/255,c=Math.max(o,a,l),u=c-Math.min(o,a,l),g=function(f){return(c-f)/6/u+1/2};return u===0?(n=0,s=0):(s=u/c,e=g(o),r=g(a),i=g(l),o===c?n=i-r:a===c?n=1/3+e-i:l===c&&(n=2/3+r-e),n<0?n+=1:n>1&&(n-=1)),[n*360,s*100,c*100]};Xe.rgb.hwb=function(t){let e=t[0],r=t[1],i=t[2],n=Xe.rgb.hsl(t)[0],s=1/255*Math.min(e,Math.min(r,i));return i=1-1/255*Math.max(e,Math.max(r,i)),[n,s*100,i*100]};Xe.rgb.cmyk=function(t){let e=t[0]/255,r=t[1]/255,i=t[2]/255,n=Math.min(1-e,1-r,1-i),s=(1-e-n)/(1-n)||0,o=(1-r-n)/(1-n)||0,a=(1-i-n)/(1-n)||0;return[s*100,o*100,a*100,n*100]};function The(t,e){return(t[0]-e[0])**2+(t[1]-e[1])**2+(t[2]-e[2])**2}Xe.rgb.keyword=function(t){let e=BK[t];if(e)return e;let r=Infinity,i;for(let n of Object.keys(gh)){let s=gh[n],o=The(t,s);o.04045?((e+.055)/1.055)**2.4:e/12.92,r=r>.04045?((r+.055)/1.055)**2.4:r/12.92,i=i>.04045?((i+.055)/1.055)**2.4:i/12.92;let n=e*.4124+r*.3576+i*.1805,s=e*.2126+r*.7152+i*.0722,o=e*.0193+r*.1192+i*.9505;return[n*100,s*100,o*100]};Xe.rgb.lab=function(t){let e=Xe.rgb.xyz(t),r=e[0],i=e[1],n=e[2];r/=95.047,i/=100,n/=108.883,r=r>.008856?r**(1/3):7.787*r+16/116,i=i>.008856?i**(1/3):7.787*i+16/116,n=n>.008856?n**(1/3):7.787*n+16/116;let s=116*i-16,o=500*(r-i),a=200*(i-n);return[s,o,a]};Xe.hsl.rgb=function(t){let e=t[0]/360,r=t[1]/100,i=t[2]/100,n,s,o;if(r===0)return o=i*255,[o,o,o];i<.5?n=i*(1+r):n=i+r-i*r;let a=2*i-n,l=[0,0,0];for(let c=0;c<3;c++)s=e+1/3*-(c-1),s<0&&s++,s>1&&s--,6*s<1?o=a+(n-a)*6*s:2*s<1?o=n:3*s<2?o=a+(n-a)*(2/3-s)*6:o=a,l[c]=o*255;return l};Xe.hsl.hsv=function(t){let e=t[0],r=t[1]/100,i=t[2]/100,n=r,s=Math.max(i,.01);i*=2,r*=i<=1?i:2-i,n*=s<=1?s:2-s;let o=(i+r)/2,a=i===0?2*n/(s+n):2*r/(i+r);return[e,a*100,o*100]};Xe.hsv.rgb=function(t){let e=t[0]/60,r=t[1]/100,i=t[2]/100,n=Math.floor(e)%6,s=e-Math.floor(e),o=255*i*(1-r),a=255*i*(1-r*s),l=255*i*(1-r*(1-s));switch(i*=255,n){case 0:return[i,l,o];case 1:return[a,i,o];case 2:return[o,i,l];case 3:return[o,a,i];case 4:return[l,o,i];case 5:return[i,o,a]}};Xe.hsv.hsl=function(t){let e=t[0],r=t[1]/100,i=t[2]/100,n=Math.max(i,.01),s,o;o=(2-r)*i;let a=(2-r)*n;return s=r*n,s/=a<=1?a:2-a,s=s||0,o/=2,[e,s*100,o*100]};Xe.hwb.rgb=function(t){let e=t[0]/360,r=t[1]/100,i=t[2]/100,n=r+i,s;n>1&&(r/=n,i/=n);let o=Math.floor(6*e),a=1-i;s=6*e-o,(o&1)!=0&&(s=1-s);let l=r+s*(a-r),c,u,g;switch(o){default:case 6:case 0:c=a,u=l,g=r;break;case 1:c=l,u=a,g=r;break;case 2:c=r,u=a,g=l;break;case 3:c=r,u=l,g=a;break;case 4:c=l,u=r,g=a;break;case 5:c=a,u=r,g=l;break}return[c*255,u*255,g*255]};Xe.cmyk.rgb=function(t){let e=t[0]/100,r=t[1]/100,i=t[2]/100,n=t[3]/100,s=1-Math.min(1,e*(1-n)+n),o=1-Math.min(1,r*(1-n)+n),a=1-Math.min(1,i*(1-n)+n);return[s*255,o*255,a*255]};Xe.xyz.rgb=function(t){let e=t[0]/100,r=t[1]/100,i=t[2]/100,n,s,o;return n=e*3.2406+r*-1.5372+i*-.4986,s=e*-.9689+r*1.8758+i*.0415,o=e*.0557+r*-.204+i*1.057,n=n>.0031308?1.055*n**(1/2.4)-.055:n*12.92,s=s>.0031308?1.055*s**(1/2.4)-.055:s*12.92,o=o>.0031308?1.055*o**(1/2.4)-.055:o*12.92,n=Math.min(Math.max(0,n),1),s=Math.min(Math.max(0,s),1),o=Math.min(Math.max(0,o),1),[n*255,s*255,o*255]};Xe.xyz.lab=function(t){let e=t[0],r=t[1],i=t[2];e/=95.047,r/=100,i/=108.883,e=e>.008856?e**(1/3):7.787*e+16/116,r=r>.008856?r**(1/3):7.787*r+16/116,i=i>.008856?i**(1/3):7.787*i+16/116;let n=116*r-16,s=500*(e-r),o=200*(r-i);return[n,s,o]};Xe.lab.xyz=function(t){let e=t[0],r=t[1],i=t[2],n,s,o;s=(e+16)/116,n=r/500+s,o=s-i/200;let a=s**3,l=n**3,c=o**3;return s=a>.008856?a:(s-16/116)/7.787,n=l>.008856?l:(n-16/116)/7.787,o=c>.008856?c:(o-16/116)/7.787,n*=95.047,s*=100,o*=108.883,[n,s,o]};Xe.lab.lch=function(t){let e=t[0],r=t[1],i=t[2],n;n=Math.atan2(i,r)*360/2/Math.PI,n<0&&(n+=360);let o=Math.sqrt(r*r+i*i);return[e,o,n]};Xe.lch.lab=function(t){let e=t[0],r=t[1],n=t[2]/360*2*Math.PI,s=r*Math.cos(n),o=r*Math.sin(n);return[e,s,o]};Xe.rgb.ansi16=function(t,e=null){let[r,i,n]=t,s=e===null?Xe.rgb.hsv(t)[2]:e;if(s=Math.round(s/50),s===0)return 30;let o=30+(Math.round(n/255)<<2|Math.round(i/255)<<1|Math.round(r/255));return s===2&&(o+=60),o};Xe.hsv.ansi16=function(t){return Xe.rgb.ansi16(Xe.hsv.rgb(t),t[2])};Xe.rgb.ansi256=function(t){let e=t[0],r=t[1],i=t[2];return e===r&&r===i?e<8?16:e>248?231:Math.round((e-8)/247*24)+232:16+36*Math.round(e/255*5)+6*Math.round(r/255*5)+Math.round(i/255*5)};Xe.ansi16.rgb=function(t){let e=t%10;if(e===0||e===7)return t>50&&(e+=3.5),e=e/10.5*255,[e,e,e];let r=(~~(t>50)+1)*.5,i=(e&1)*r*255,n=(e>>1&1)*r*255,s=(e>>2&1)*r*255;return[i,n,s]};Xe.ansi256.rgb=function(t){if(t>=232){let s=(t-232)*10+8;return[s,s,s]}t-=16;let e,r=Math.floor(t/36)/5*255,i=Math.floor((e=t%36)/6)/5*255,n=e%6/5*255;return[r,i,n]};Xe.rgb.hex=function(t){let r=(((Math.round(t[0])&255)<<16)+((Math.round(t[1])&255)<<8)+(Math.round(t[2])&255)).toString(16).toUpperCase();return"000000".substring(r.length)+r};Xe.hex.rgb=function(t){let e=t.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!e)return[0,0,0];let r=e[0];e[0].length===3&&(r=r.split("").map(a=>a+a).join(""));let i=parseInt(r,16),n=i>>16&255,s=i>>8&255,o=i&255;return[n,s,o]};Xe.rgb.hcg=function(t){let e=t[0]/255,r=t[1]/255,i=t[2]/255,n=Math.max(Math.max(e,r),i),s=Math.min(Math.min(e,r),i),o=n-s,a,l;return o<1?a=s/(1-o):a=0,o<=0?l=0:n===e?l=(r-i)/o%6:n===r?l=2+(i-e)/o:l=4+(e-r)/o,l/=6,l%=1,[l*360,o*100,a*100]};Xe.hsl.hcg=function(t){let e=t[1]/100,r=t[2]/100,i=r<.5?2*e*r:2*e*(1-r),n=0;return i<1&&(n=(r-.5*i)/(1-i)),[t[0],i*100,n*100]};Xe.hsv.hcg=function(t){let e=t[1]/100,r=t[2]/100,i=e*r,n=0;return i<1&&(n=(r-i)/(1-i)),[t[0],i*100,n*100]};Xe.hcg.rgb=function(t){let e=t[0]/360,r=t[1]/100,i=t[2]/100;if(r===0)return[i*255,i*255,i*255];let n=[0,0,0],s=e%1*6,o=s%1,a=1-o,l=0;switch(Math.floor(s)){case 0:n[0]=1,n[1]=o,n[2]=0;break;case 1:n[0]=a,n[1]=1,n[2]=0;break;case 2:n[0]=0,n[1]=1,n[2]=o;break;case 3:n[0]=0,n[1]=a,n[2]=1;break;case 4:n[0]=o,n[1]=0,n[2]=1;break;default:n[0]=1,n[1]=0,n[2]=a}return l=(1-r)*i,[(r*n[0]+l)*255,(r*n[1]+l)*255,(r*n[2]+l)*255]};Xe.hcg.hsv=function(t){let e=t[1]/100,r=t[2]/100,i=e+r*(1-e),n=0;return i>0&&(n=e/i),[t[0],n*100,i*100]};Xe.hcg.hsl=function(t){let e=t[1]/100,i=t[2]/100*(1-e)+.5*e,n=0;return i>0&&i<.5?n=e/(2*i):i>=.5&&i<1&&(n=e/(2*(1-i))),[t[0],n*100,i*100]};Xe.hcg.hwb=function(t){let e=t[1]/100,r=t[2]/100,i=e+r*(1-e);return[t[0],(i-e)*100,(1-i)*100]};Xe.hwb.hcg=function(t){let e=t[1]/100,r=t[2]/100,i=1-r,n=i-e,s=0;return n<1&&(s=(i-n)/(1-n)),[t[0],n*100,s*100]};Xe.apple.rgb=function(t){return[t[0]/65535*255,t[1]/65535*255,t[2]/65535*255]};Xe.rgb.apple=function(t){return[t[0]/255*65535,t[1]/255*65535,t[2]/255*65535]};Xe.gray.rgb=function(t){return[t[0]/100*255,t[0]/100*255,t[0]/100*255]};Xe.gray.hsl=function(t){return[0,0,t[0]]};Xe.gray.hsv=Xe.gray.hsl;Xe.gray.hwb=function(t){return[0,100,t[0]]};Xe.gray.cmyk=function(t){return[0,0,0,t[0]]};Xe.gray.lab=function(t){return[t[0],0,0]};Xe.gray.hex=function(t){let e=Math.round(t[0]/100*255)&255,i=((e<<16)+(e<<8)+e).toString(16).toUpperCase();return"000000".substring(i.length)+i};Xe.rgb.gray=function(t){return[(t[0]+t[1]+t[2])/3/255*100]}});var bK=E((B$e,QK)=>{var kE=Nb();function Mhe(){let t={},e=Object.keys(kE);for(let r=e.length,i=0;i{var Lb=Nb(),Hhe=bK(),ru={},Ghe=Object.keys(Lb);function jhe(t){let e=function(...r){let i=r[0];return i==null?i:(i.length>1&&(r=i),t(r))};return"conversion"in t&&(e.conversion=t.conversion),e}function Yhe(t){let e=function(...r){let i=r[0];if(i==null)return i;i.length>1&&(r=i);let n=t(r);if(typeof n=="object")for(let s=n.length,o=0;o{ru[t]={},Object.defineProperty(ru[t],"channels",{value:Lb[t].channels}),Object.defineProperty(ru[t],"labels",{value:Lb[t].labels});let e=Hhe(t);Object.keys(e).forEach(i=>{let n=e[i];ru[t][i]=Yhe(n),ru[t][i].raw=jhe(n)})});vK.exports=ru});var FK=E((b$e,xK)=>{"use strict";var kK=(t,e)=>(...r)=>`[${t(...r)+e}m`,PK=(t,e)=>(...r)=>{let i=t(...r);return`[${38+e};5;${i}m`},DK=(t,e)=>(...r)=>{let i=t(...r);return`[${38+e};2;${i[0]};${i[1]};${i[2]}m`},PE=t=>t,RK=(t,e,r)=>[t,e,r],iu=(t,e,r)=>{Object.defineProperty(t,e,{get:()=>{let i=r();return Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0}),i},enumerable:!0,configurable:!0})},Tb,nu=(t,e,r,i)=>{Tb===void 0&&(Tb=SK());let n=i?10:0,s={};for(let[o,a]of Object.entries(Tb)){let l=o==="ansi16"?"ansi":o;o===e?s[l]=t(r,n):typeof a=="object"&&(s[l]=t(a[e],n))}return s};function qhe(){let t=new Map,e={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}};e.color.gray=e.color.blackBright,e.bgColor.bgGray=e.bgColor.bgBlackBright,e.color.grey=e.color.blackBright,e.bgColor.bgGrey=e.bgColor.bgBlackBright;for(let[r,i]of Object.entries(e)){for(let[n,s]of Object.entries(i))e[n]={open:`[${s[0]}m`,close:`[${s[1]}m`},i[n]=e[n],t.set(s[0],s[1]);Object.defineProperty(e,r,{value:i,enumerable:!1})}return Object.defineProperty(e,"codes",{value:t,enumerable:!1}),e.color.close="",e.bgColor.close="",iu(e.color,"ansi",()=>nu(kK,"ansi16",PE,!1)),iu(e.color,"ansi256",()=>nu(PK,"ansi256",PE,!1)),iu(e.color,"ansi16m",()=>nu(DK,"rgb",RK,!1)),iu(e.bgColor,"ansi",()=>nu(kK,"ansi16",PE,!0)),iu(e.bgColor,"ansi256",()=>nu(PK,"ansi256",PE,!0)),iu(e.bgColor,"ansi16m",()=>nu(DK,"rgb",RK,!0)),e}Object.defineProperty(xK,"exports",{enumerable:!0,get:qhe})});var LK=E((v$e,NK)=>{"use strict";NK.exports=(t,e=process.argv)=>{let r=t.startsWith("-")?"":t.length===1?"-":"--",i=e.indexOf(r+t),n=e.indexOf("--");return i!==-1&&(n===-1||i{"use strict";var Jhe=require("os"),MK=require("tty"),Wn=LK(),{env:Wr}=process,tA;Wn("no-color")||Wn("no-colors")||Wn("color=false")||Wn("color=never")?tA=0:(Wn("color")||Wn("colors")||Wn("color=true")||Wn("color=always"))&&(tA=1);"FORCE_COLOR"in Wr&&(Wr.FORCE_COLOR==="true"?tA=1:Wr.FORCE_COLOR==="false"?tA=0:tA=Wr.FORCE_COLOR.length===0?1:Math.min(parseInt(Wr.FORCE_COLOR,10),3));function Mb(t){return t===0?!1:{level:t,hasBasic:!0,has256:t>=2,has16m:t>=3}}function Ob(t,e){if(tA===0)return 0;if(Wn("color=16m")||Wn("color=full")||Wn("color=truecolor"))return 3;if(Wn("color=256"))return 2;if(t&&!e&&tA===void 0)return 0;let r=tA||0;if(Wr.TERM==="dumb")return r;if(process.platform==="win32"){let i=Jhe.release().split(".");return Number(i[0])>=10&&Number(i[2])>=10586?Number(i[2])>=14931?3:2:1}if("CI"in Wr)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI"].some(i=>i in Wr)||Wr.CI_NAME==="codeship"?1:r;if("TEAMCITY_VERSION"in Wr)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(Wr.TEAMCITY_VERSION)?1:0;if("GITHUB_ACTIONS"in Wr)return 1;if(Wr.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in Wr){let i=parseInt((Wr.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(Wr.TERM_PROGRAM){case"iTerm.app":return i>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(Wr.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(Wr.TERM)||"COLORTERM"in Wr?1:r}function Whe(t){let e=Ob(t,t&&t.isTTY);return Mb(e)}TK.exports={supportsColor:Whe,stdout:Mb(Ob(!0,MK.isatty(1))),stderr:Mb(Ob(!0,MK.isatty(2)))}});var UK=E((x$e,KK)=>{"use strict";var zhe=(t,e,r)=>{let i=t.indexOf(e);if(i===-1)return t;let n=e.length,s=0,o="";do o+=t.substr(s,i-s)+e+r,s=i+n,i=t.indexOf(e,s);while(i!==-1);return o+=t.substr(s),o},Vhe=(t,e,r,i)=>{let n=0,s="";do{let o=t[i-1]==="\r";s+=t.substr(n,(o?i-1:i)-n)+e+(o?`\r -`:` -`)+r,n=i+1,i=t.indexOf(` -`,n)}while(i!==-1);return s+=t.substr(n),s};KK.exports={stringReplaceAll:zhe,stringEncaseCRLFWithFirstIndex:Vhe}});var qK=E((k$e,HK)=>{"use strict";var _he=/(?:\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.))|(?:\{(~)?(\w+(?:\([^)]*\))?(?:\.\w+(?:\([^)]*\))?)*)(?:[ \t]|(?=\r?\n)))|(\})|((?:.|[\r\n\f])+?)/gi,GK=/(?:^|\.)(\w+)(?:\(([^)]*)\))?/g,Xhe=/^(['"])((?:\\.|(?!\1)[^\\])*)\1$/,Zhe=/\\(u(?:[a-f\d]{4}|\{[a-f\d]{1,6}\})|x[a-f\d]{2}|.)|([^\\])/gi,$he=new Map([["n",` -`],["r","\r"],["t"," "],["b","\b"],["f","\f"],["v","\v"],["0","\0"],["\\","\\"],["e",""],["a","\x07"]]);function jK(t){let e=t[0]==="u",r=t[1]==="{";return e&&!r&&t.length===5||t[0]==="x"&&t.length===3?String.fromCharCode(parseInt(t.slice(1),16)):e&&r?String.fromCodePoint(parseInt(t.slice(2,-1),16)):$he.get(t)||t}function epe(t,e){let r=[],i=e.trim().split(/\s*,\s*/g),n;for(let s of i){let o=Number(s);if(!Number.isNaN(o))r.push(o);else if(n=s.match(Xhe))r.push(n[2].replace(Zhe,(a,l,c)=>l?jK(l):c));else throw new Error(`Invalid Chalk template style argument: ${s} (in style '${t}')`)}return r}function tpe(t){GK.lastIndex=0;let e=[],r;for(;(r=GK.exec(t))!==null;){let i=r[1];if(r[2]){let n=epe(i,r[2]);e.push([i].concat(n))}else e.push([i])}return e}function YK(t,e){let r={};for(let n of e)for(let s of n.styles)r[s[0]]=n.inverse?null:s.slice(1);let i=t;for(let[n,s]of Object.entries(r))if(!!Array.isArray(s)){if(!(n in i))throw new Error(`Unknown Chalk style: ${n}`);i=s.length>0?i[n](...s):i[n]}return i}HK.exports=(t,e)=>{let r=[],i=[],n=[];if(e.replace(_he,(s,o,a,l,c,u)=>{if(o)n.push(jK(o));else if(l){let g=n.join("");n=[],i.push(r.length===0?g:YK(t,r)(g)),r.push({inverse:a,styles:tpe(l)})}else if(c){if(r.length===0)throw new Error("Found extraneous } in Chalk template literal");i.push(YK(t,r)(n.join(""))),n=[],r.pop()}else n.push(u)}),i.push(n.join("")),r.length>0){let s=`Chalk template literal is missing ${r.length} closing bracket${r.length===1?"":"s"} (\`}\`)`;throw new Error(s)}return i.join("")}});var jb=E((P$e,JK)=>{"use strict";var fh=FK(),{stdout:Kb,stderr:Ub}=OK(),{stringReplaceAll:rpe,stringEncaseCRLFWithFirstIndex:ipe}=UK(),WK=["ansi","ansi","ansi256","ansi16m"],su=Object.create(null),npe=(t,e={})=>{if(e.level>3||e.level<0)throw new Error("The `level` option should be an integer from 0 to 3");let r=Kb?Kb.level:0;t.level=e.level===void 0?r:e.level},zK=class{constructor(e){return VK(e)}},VK=t=>{let e={};return npe(e,t),e.template=(...r)=>spe(e.template,...r),Object.setPrototypeOf(e,DE.prototype),Object.setPrototypeOf(e.template,e),e.template.constructor=()=>{throw new Error("`chalk.constructor()` is deprecated. Use `new chalk.Instance()` instead.")},e.template.Instance=zK,e.template};function DE(t){return VK(t)}for(let[t,e]of Object.entries(fh))su[t]={get(){let r=RE(this,Hb(e.open,e.close,this._styler),this._isEmpty);return Object.defineProperty(this,t,{value:r}),r}};su.visible={get(){let t=RE(this,this._styler,!0);return Object.defineProperty(this,"visible",{value:t}),t}};var _K=["rgb","hex","keyword","hsl","hsv","hwb","ansi","ansi256"];for(let t of _K)su[t]={get(){let{level:e}=this;return function(...r){let i=Hb(fh.color[WK[e]][t](...r),fh.color.close,this._styler);return RE(this,i,this._isEmpty)}}};for(let t of _K){let e="bg"+t[0].toUpperCase()+t.slice(1);su[e]={get(){let{level:r}=this;return function(...i){let n=Hb(fh.bgColor[WK[r]][t](...i),fh.bgColor.close,this._styler);return RE(this,n,this._isEmpty)}}}}var ope=Object.defineProperties(()=>{},_(P({},su),{level:{enumerable:!0,get(){return this._generator.level},set(t){this._generator.level=t}}})),Hb=(t,e,r)=>{let i,n;return r===void 0?(i=t,n=e):(i=r.openAll+t,n=e+r.closeAll),{open:t,close:e,openAll:i,closeAll:n,parent:r}},RE=(t,e,r)=>{let i=(...n)=>ape(i,n.length===1?""+n[0]:n.join(" "));return i.__proto__=ope,i._generator=t,i._styler=e,i._isEmpty=r,i},ape=(t,e)=>{if(t.level<=0||!e)return t._isEmpty?"":e;let r=t._styler;if(r===void 0)return e;let{openAll:i,closeAll:n}=r;if(e.indexOf("")!==-1)for(;r!==void 0;)e=rpe(e,r.close,r.open),r=r.parent;let s=e.indexOf(` -`);return s!==-1&&(e=ipe(e,n,i,s)),i+e+n},Gb,spe=(t,...e)=>{let[r]=e;if(!Array.isArray(r))return e.join(" ");let i=e.slice(1),n=[r.raw[0]];for(let s=1;s{XK.exports=[{name:"AppVeyor",constant:"APPVEYOR",env:"APPVEYOR",pr:"APPVEYOR_PULL_REQUEST_NUMBER"},{name:"Azure Pipelines",constant:"AZURE_PIPELINES",env:"SYSTEM_TEAMFOUNDATIONCOLLECTIONURI",pr:"SYSTEM_PULLREQUEST_PULLREQUESTID"},{name:"Appcircle",constant:"APPCIRCLE",env:"AC_APPCIRCLE"},{name:"Bamboo",constant:"BAMBOO",env:"bamboo_planKey"},{name:"Bitbucket Pipelines",constant:"BITBUCKET",env:"BITBUCKET_COMMIT",pr:"BITBUCKET_PR_ID"},{name:"Bitrise",constant:"BITRISE",env:"BITRISE_IO",pr:"BITRISE_PULL_REQUEST"},{name:"Buddy",constant:"BUDDY",env:"BUDDY_WORKSPACE_ID",pr:"BUDDY_EXECUTION_PULL_REQUEST_ID"},{name:"Buildkite",constant:"BUILDKITE",env:"BUILDKITE",pr:{env:"BUILDKITE_PULL_REQUEST",ne:"false"}},{name:"CircleCI",constant:"CIRCLE",env:"CIRCLECI",pr:"CIRCLE_PULL_REQUEST"},{name:"Cirrus CI",constant:"CIRRUS",env:"CIRRUS_CI",pr:"CIRRUS_PR"},{name:"AWS CodeBuild",constant:"CODEBUILD",env:"CODEBUILD_BUILD_ARN"},{name:"Codefresh",constant:"CODEFRESH",env:"CF_BUILD_ID",pr:{any:["CF_PULL_REQUEST_NUMBER","CF_PULL_REQUEST_ID"]}},{name:"Codeship",constant:"CODESHIP",env:{CI_NAME:"codeship"}},{name:"Drone",constant:"DRONE",env:"DRONE",pr:{DRONE_BUILD_EVENT:"pull_request"}},{name:"dsari",constant:"DSARI",env:"DSARI"},{name:"GitHub Actions",constant:"GITHUB_ACTIONS",env:"GITHUB_ACTIONS",pr:{GITHUB_EVENT_NAME:"pull_request"}},{name:"GitLab CI",constant:"GITLAB",env:"GITLAB_CI",pr:"CI_MERGE_REQUEST_ID"},{name:"GoCD",constant:"GOCD",env:"GO_PIPELINE_LABEL"},{name:"LayerCI",constant:"LAYERCI",env:"LAYERCI",pr:"LAYERCI_PULL_REQUEST"},{name:"Hudson",constant:"HUDSON",env:"HUDSON_URL"},{name:"Jenkins",constant:"JENKINS",env:["JENKINS_URL","BUILD_ID"],pr:{any:["ghprbPullId","CHANGE_ID"]}},{name:"Magnum CI",constant:"MAGNUM",env:"MAGNUM"},{name:"Netlify CI",constant:"NETLIFY",env:"NETLIFY",pr:{env:"PULL_REQUEST",ne:"false"}},{name:"Nevercode",constant:"NEVERCODE",env:"NEVERCODE",pr:{env:"NEVERCODE_PULL_REQUEST",ne:"false"}},{name:"Render",constant:"RENDER",env:"RENDER",pr:{IS_PULL_REQUEST:"true"}},{name:"Sail CI",constant:"SAIL",env:"SAILCI",pr:"SAIL_PULL_REQUEST_NUMBER"},{name:"Semaphore",constant:"SEMAPHORE",env:"SEMAPHORE",pr:"PULL_REQUEST_NUMBER"},{name:"Screwdriver",constant:"SCREWDRIVER",env:"SCREWDRIVER",pr:{env:"SD_PULL_REQUEST",ne:"false"}},{name:"Shippable",constant:"SHIPPABLE",env:"SHIPPABLE",pr:{IS_PULL_REQUEST:"true"}},{name:"Solano CI",constant:"SOLANO",env:"TDDIUM",pr:"TDDIUM_PR_ID"},{name:"Strider CD",constant:"STRIDER",env:"STRIDER"},{name:"TaskCluster",constant:"TASKCLUSTER",env:["TASK_ID","RUN_ID"]},{name:"TeamCity",constant:"TEAMCITY",env:"TEAMCITY_VERSION"},{name:"Travis CI",constant:"TRAVIS",env:"TRAVIS",pr:{env:"TRAVIS_PULL_REQUEST",ne:"false"}},{name:"Vercel",constant:"VERCEL",env:"NOW_BUILDER"},{name:"Visual Studio App Center",constant:"APPCENTER",env:"APPCENTER_BUILD_ID"}]});var ml=E(Dn=>{"use strict";var $K=ZK(),ro=process.env;Object.defineProperty(Dn,"_vendors",{value:$K.map(function(t){return t.constant})});Dn.name=null;Dn.isPR=null;$K.forEach(function(t){let r=(Array.isArray(t.env)?t.env:[t.env]).every(function(i){return e1(i)});if(Dn[t.constant]=r,r)switch(Dn.name=t.name,typeof t.pr){case"string":Dn.isPR=!!ro[t.pr];break;case"object":"env"in t.pr?Dn.isPR=t.pr.env in ro&&ro[t.pr.env]!==t.pr.ne:"any"in t.pr?Dn.isPR=t.pr.any.some(function(i){return!!ro[i]}):Dn.isPR=e1(t.pr);break;default:Dn.isPR=null}});Dn.isCI=!!(ro.CI||ro.CONTINUOUS_INTEGRATION||ro.BUILD_NUMBER||ro.RUN_ID||Dn.name);function e1(t){return typeof t=="string"?!!ro[t]:Object.keys(t).every(function(e){return ro[e]===t[e]})}});var FE=E(zn=>{"use strict";zn.isInteger=t=>typeof t=="number"?Number.isInteger(t):typeof t=="string"&&t.trim()!==""?Number.isInteger(Number(t)):!1;zn.find=(t,e)=>t.nodes.find(r=>r.type===e);zn.exceedsLimit=(t,e,r=1,i)=>i===!1||!zn.isInteger(t)||!zn.isInteger(e)?!1:(Number(e)-Number(t))/Number(r)>=i;zn.escapeNode=(t,e=0,r)=>{let i=t.nodes[e];!i||(r&&i.type===r||i.type==="open"||i.type==="close")&&i.escaped!==!0&&(i.value="\\"+i.value,i.escaped=!0)};zn.encloseBrace=t=>t.type!=="brace"?!1:t.commas>>0+t.ranges>>0==0?(t.invalid=!0,!0):!1;zn.isInvalidBrace=t=>t.type!=="brace"?!1:t.invalid===!0||t.dollar?!0:t.commas>>0+t.ranges>>0==0||t.open!==!0||t.close!==!0?(t.invalid=!0,!0):!1;zn.isOpenOrClose=t=>t.type==="open"||t.type==="close"?!0:t.open===!0||t.close===!0;zn.reduce=t=>t.reduce((e,r)=>(r.type==="text"&&e.push(r.value),r.type==="range"&&(r.type="text"),e),[]);zn.flatten=(...t)=>{let e=[],r=i=>{for(let n=0;n{"use strict";var r1=FE();t1.exports=(t,e={})=>{let r=(i,n={})=>{let s=e.escapeInvalid&&r1.isInvalidBrace(n),o=i.invalid===!0&&e.escapeInvalid===!0,a="";if(i.value)return(s||o)&&r1.isOpenOrClose(i)?"\\"+i.value:i.value;if(i.value)return i.value;if(i.nodes)for(let l of i.nodes)a+=r(l);return a};return r(t)}});var n1=E((L$e,i1)=>{"use strict";i1.exports=function(t){return typeof t=="number"?t-t==0:typeof t=="string"&&t.trim()!==""?Number.isFinite?Number.isFinite(+t):isFinite(+t):!1}});var f1=E((T$e,s1)=>{"use strict";var o1=n1(),El=(t,e,r)=>{if(o1(t)===!1)throw new TypeError("toRegexRange: expected the first argument to be a number");if(e===void 0||t===e)return String(t);if(o1(e)===!1)throw new TypeError("toRegexRange: expected the second argument to be a number.");let i=P({relaxZeros:!0},r);typeof i.strictZeros=="boolean"&&(i.relaxZeros=i.strictZeros===!1);let n=String(i.relaxZeros),s=String(i.shorthand),o=String(i.capture),a=String(i.wrap),l=t+":"+e+"="+n+s+o+a;if(El.cache.hasOwnProperty(l))return El.cache[l].result;let c=Math.min(t,e),u=Math.max(t,e);if(Math.abs(c-u)===1){let d=t+"|"+e;return i.capture?`(${d})`:i.wrap===!1?d:`(?:${d})`}let g=A1(t)||A1(e),f={min:t,max:e,a:c,b:u},h=[],p=[];if(g&&(f.isPadded=g,f.maxLen=String(f.max).length),c<0){let d=u<0?Math.abs(u):1;p=a1(d,Math.abs(c),f,i),c=f.a=0}return u>=0&&(h=a1(c,u,f,i)),f.negatives=p,f.positives=h,f.result=Ape(p,h,i),i.capture===!0?f.result=`(${f.result})`:i.wrap!==!1&&h.length+p.length>1&&(f.result=`(?:${f.result})`),El.cache[l]=f,f.result};function Ape(t,e,r){let i=Yb(t,e,"-",!1,r)||[],n=Yb(e,t,"",!1,r)||[],s=Yb(t,e,"-?",!0,r)||[];return i.concat(s).concat(n).join("|")}function cpe(t,e){let r=1,i=1,n=l1(t,r),s=new Set([e]);for(;t<=n&&n<=e;)s.add(n),r+=1,n=l1(t,r);for(n=c1(e+1,i)-1;t1&&a.count.pop(),a.count.push(u.count[0]),a.string=a.pattern+u1(a.count),o=c+1;continue}r.isPadded&&(g=hpe(c,r,i)),u.string=g+u.pattern+u1(u.count),s.push(u),o=c+1,a=u}return s}function Yb(t,e,r,i,n){let s=[];for(let o of t){let{string:a}=o;!i&&!g1(e,"string",a)&&s.push(r+a),i&&g1(e,"string",a)&&s.push(r+a)}return s}function upe(t,e){let r=[];for(let i=0;ie?1:e>t?-1:0}function g1(t,e,r){return t.some(i=>i[e]===r)}function l1(t,e){return Number(String(t).slice(0,-e)+"9".repeat(e))}function c1(t,e){return t-t%Math.pow(10,e)}function u1(t){let[e=0,r=""]=t;return r||e>1?`{${e+(r?","+r:"")}}`:""}function gpe(t,e,r){return`[${t}${e-t==1?"":"-"}${e}]`}function A1(t){return/^-?(0+)\d/.test(t)}function hpe(t,e,r){if(!e.isPadded)return t;let i=Math.abs(e.maxLen-String(t).length),n=r.relaxZeros!==!1;switch(i){case 0:return"";case 1:return n?"0?":"0";case 2:return n?"0{0,2}":"00";default:return n?`0{0,${i}}`:`0{${i}}`}}El.cache={};El.clearCache=()=>El.cache={};s1.exports=El});var Wb=E((M$e,h1)=>{"use strict";var ppe=require("util"),p1=f1(),d1=t=>t!==null&&typeof t=="object"&&!Array.isArray(t),dpe=t=>e=>t===!0?Number(e):String(e),qb=t=>typeof t=="number"||typeof t=="string"&&t!=="",ph=t=>Number.isInteger(+t),Jb=t=>{let e=`${t}`,r=-1;if(e[0]==="-"&&(e=e.slice(1)),e==="0")return!1;for(;e[++r]==="0";);return r>0},Cpe=(t,e,r)=>typeof t=="string"||typeof e=="string"?!0:r.stringify===!0,mpe=(t,e,r)=>{if(e>0){let i=t[0]==="-"?"-":"";i&&(t=t.slice(1)),t=i+t.padStart(i?e-1:e,"0")}return r===!1?String(t):t},C1=(t,e)=>{let r=t[0]==="-"?"-":"";for(r&&(t=t.slice(1),e--);t.length{t.negatives.sort((o,a)=>oa?1:0),t.positives.sort((o,a)=>oa?1:0);let r=e.capture?"":"?:",i="",n="",s;return t.positives.length&&(i=t.positives.join("|")),t.negatives.length&&(n=`-(${r}${t.negatives.join("|")})`),i&&n?s=`${i}|${n}`:s=i||n,e.wrap?`(${r}${s})`:s},m1=(t,e,r,i)=>{if(r)return p1(t,e,P({wrap:!1},i));let n=String.fromCharCode(t);if(t===e)return n;let s=String.fromCharCode(e);return`[${n}-${s}]`},E1=(t,e,r)=>{if(Array.isArray(t)){let i=r.wrap===!0,n=r.capture?"":"?:";return i?`(${n}${t.join("|")})`:t.join("|")}return p1(t,e,r)},I1=(...t)=>new RangeError("Invalid range arguments: "+ppe.inspect(...t)),y1=(t,e,r)=>{if(r.strictRanges===!0)throw I1([t,e]);return[]},Ipe=(t,e)=>{if(e.strictRanges===!0)throw new TypeError(`Expected step "${t}" to be a number`);return[]},ype=(t,e,r=1,i={})=>{let n=Number(t),s=Number(e);if(!Number.isInteger(n)||!Number.isInteger(s)){if(i.strictRanges===!0)throw I1([t,e]);return[]}n===0&&(n=0),s===0&&(s=0);let o=n>s,a=String(t),l=String(e),c=String(r);r=Math.max(Math.abs(r),1);let u=Jb(a)||Jb(l)||Jb(c),g=u?Math.max(a.length,l.length,c.length):0,f=u===!1&&Cpe(t,e,i)===!1,h=i.transform||dpe(f);if(i.toRegex&&r===1)return m1(C1(t,g),C1(e,g),!0,i);let p={negatives:[],positives:[]},d=B=>p[B<0?"negatives":"positives"].push(Math.abs(B)),m=[],I=0;for(;o?n>=s:n<=s;)i.toRegex===!0&&r>1?d(n):m.push(mpe(h(n,I),g,f)),n=o?n-r:n+r,I++;return i.toRegex===!0?r>1?Epe(p,i):E1(m,null,P({wrap:!1},i)):m},wpe=(t,e,r=1,i={})=>{if(!ph(t)&&t.length>1||!ph(e)&&e.length>1)return y1(t,e,i);let n=i.transform||(f=>String.fromCharCode(f)),s=`${t}`.charCodeAt(0),o=`${e}`.charCodeAt(0),a=s>o,l=Math.min(s,o),c=Math.max(s,o);if(i.toRegex&&r===1)return m1(l,c,!1,i);let u=[],g=0;for(;a?s>=o:s<=o;)u.push(n(s,g)),s=a?s-r:s+r,g++;return i.toRegex===!0?E1(u,null,{wrap:!1,options:i}):u},LE=(t,e,r,i={})=>{if(e==null&&qb(t))return[t];if(!qb(t)||!qb(e))return y1(t,e,i);if(typeof r=="function")return LE(t,e,1,{transform:r});if(d1(r))return LE(t,e,0,r);let n=P({},i);return n.capture===!0&&(n.wrap=!0),r=r||n.step||1,ph(r)?ph(t)&&ph(e)?ype(t,e,r,n):wpe(t,e,Math.max(Math.abs(r),1),n):r!=null&&!d1(r)?Ipe(r,n):LE(t,e,1,r)};h1.exports=LE});var Q1=E((O$e,w1)=>{"use strict";var Bpe=Wb(),B1=FE(),Qpe=(t,e={})=>{let r=(i,n={})=>{let s=B1.isInvalidBrace(n),o=i.invalid===!0&&e.escapeInvalid===!0,a=s===!0||o===!0,l=e.escapeInvalid===!0?"\\":"",c="";if(i.isOpen===!0||i.isClose===!0)return l+i.value;if(i.type==="open")return a?l+i.value:"(";if(i.type==="close")return a?l+i.value:")";if(i.type==="comma")return i.prev.type==="comma"?"":a?i.value:"|";if(i.value)return i.value;if(i.nodes&&i.ranges>0){let u=B1.reduce(i.nodes),g=Bpe(...u,_(P({},e),{wrap:!1,toRegex:!0}));if(g.length!==0)return u.length>1&&g.length>1?`(${g})`:g}if(i.nodes)for(let u of i.nodes)c+=r(u,i);return c};return r(t)};w1.exports=Qpe});var S1=E((K$e,b1)=>{"use strict";var bpe=Wb(),v1=NE(),ou=FE(),Il=(t="",e="",r=!1)=>{let i=[];if(t=[].concat(t),e=[].concat(e),!e.length)return t;if(!t.length)return r?ou.flatten(e).map(n=>`{${n}}`):e;for(let n of t)if(Array.isArray(n))for(let s of n)i.push(Il(s,e,r));else for(let s of e)r===!0&&typeof s=="string"&&(s=`{${s}}`),i.push(Array.isArray(s)?Il(n,s,r):n+s);return ou.flatten(i)},vpe=(t,e={})=>{let r=e.rangeLimit===void 0?1e3:e.rangeLimit,i=(n,s={})=>{n.queue=[];let o=s,a=s.queue;for(;o.type!=="brace"&&o.type!=="root"&&o.parent;)o=o.parent,a=o.queue;if(n.invalid||n.dollar){a.push(Il(a.pop(),v1(n,e)));return}if(n.type==="brace"&&n.invalid!==!0&&n.nodes.length===2){a.push(Il(a.pop(),["{}"]));return}if(n.nodes&&n.ranges>0){let g=ou.reduce(n.nodes);if(ou.exceedsLimit(...g,e.step,r))throw new RangeError("expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.");let f=bpe(...g,e);f.length===0&&(f=v1(n,e)),a.push(Il(a.pop(),f)),n.nodes=[];return}let l=ou.encloseBrace(n),c=n.queue,u=n;for(;u.type!=="brace"&&u.type!=="root"&&u.parent;)u=u.parent,c=u.queue;for(let g=0;g{"use strict";x1.exports={MAX_LENGTH:1024*64,CHAR_0:"0",CHAR_9:"9",CHAR_UPPERCASE_A:"A",CHAR_LOWERCASE_A:"a",CHAR_UPPERCASE_Z:"Z",CHAR_LOWERCASE_Z:"z",CHAR_LEFT_PARENTHESES:"(",CHAR_RIGHT_PARENTHESES:")",CHAR_ASTERISK:"*",CHAR_AMPERSAND:"&",CHAR_AT:"@",CHAR_BACKSLASH:"\\",CHAR_BACKTICK:"`",CHAR_CARRIAGE_RETURN:"\r",CHAR_CIRCUMFLEX_ACCENT:"^",CHAR_COLON:":",CHAR_COMMA:",",CHAR_DOLLAR:"$",CHAR_DOT:".",CHAR_DOUBLE_QUOTE:'"',CHAR_EQUAL:"=",CHAR_EXCLAMATION_MARK:"!",CHAR_FORM_FEED:"\f",CHAR_FORWARD_SLASH:"/",CHAR_HASH:"#",CHAR_HYPHEN_MINUS:"-",CHAR_LEFT_ANGLE_BRACKET:"<",CHAR_LEFT_CURLY_BRACE:"{",CHAR_LEFT_SQUARE_BRACKET:"[",CHAR_LINE_FEED:` -`,CHAR_NO_BREAK_SPACE:"\xA0",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:" ",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\uFEFF"}});var N1=E((H$e,P1)=>{"use strict";var Spe=NE(),{MAX_LENGTH:D1,CHAR_BACKSLASH:zb,CHAR_BACKTICK:xpe,CHAR_COMMA:kpe,CHAR_DOT:Ppe,CHAR_LEFT_PARENTHESES:Dpe,CHAR_RIGHT_PARENTHESES:Rpe,CHAR_LEFT_CURLY_BRACE:Fpe,CHAR_RIGHT_CURLY_BRACE:Npe,CHAR_LEFT_SQUARE_BRACKET:R1,CHAR_RIGHT_SQUARE_BRACKET:F1,CHAR_DOUBLE_QUOTE:Lpe,CHAR_SINGLE_QUOTE:Tpe,CHAR_NO_BREAK_SPACE:Mpe,CHAR_ZERO_WIDTH_NOBREAK_SPACE:Ope}=k1(),Kpe=(t,e={})=>{if(typeof t!="string")throw new TypeError("Expected a string");let r=e||{},i=typeof r.maxLength=="number"?Math.min(D1,r.maxLength):D1;if(t.length>i)throw new SyntaxError(`Input length (${t.length}), exceeds max characters (${i})`);let n={type:"root",input:t,nodes:[]},s=[n],o=n,a=n,l=0,c=t.length,u=0,g=0,f,h={},p=()=>t[u++],d=m=>{if(m.type==="text"&&a.type==="dot"&&(a.type="text"),a&&a.type==="text"&&m.type==="text"){a.value+=m.value;return}return o.nodes.push(m),m.parent=o,m.prev=a,a=m,m};for(d({type:"bos"});u0){if(o.ranges>0){o.ranges=0;let m=o.nodes.shift();o.nodes=[m,{type:"text",value:Spe(o)}]}d({type:"comma",value:f}),o.commas++;continue}if(f===Ppe&&g>0&&o.commas===0){let m=o.nodes;if(g===0||m.length===0){d({type:"text",value:f});continue}if(a.type==="dot"){if(o.range=[],a.value+=f,a.type="range",o.nodes.length!==3&&o.nodes.length!==5){o.invalid=!0,o.ranges=0,a.type="text";continue}o.ranges++,o.args=[];continue}if(a.type==="range"){m.pop();let I=m[m.length-1];I.value+=a.value+f,a=I,o.ranges--;continue}d({type:"dot",value:f});continue}d({type:"text",value:f})}do if(o=s.pop(),o.type!=="root"){o.nodes.forEach(B=>{B.nodes||(B.type==="open"&&(B.isOpen=!0),B.type==="close"&&(B.isClose=!0),B.nodes||(B.type="text"),B.invalid=!0)});let m=s[s.length-1],I=m.nodes.indexOf(o);m.nodes.splice(I,1,...o.nodes)}while(s.length>0);return d({type:"eos"}),n};P1.exports=Kpe});var M1=E((G$e,L1)=>{"use strict";var T1=NE(),Upe=Q1(),Hpe=S1(),Gpe=N1(),Rn=(t,e={})=>{let r=[];if(Array.isArray(t))for(let i of t){let n=Rn.create(i,e);Array.isArray(n)?r.push(...n):r.push(n)}else r=[].concat(Rn.create(t,e));return e&&e.expand===!0&&e.nodupes===!0&&(r=[...new Set(r)]),r};Rn.parse=(t,e={})=>Gpe(t,e);Rn.stringify=(t,e={})=>typeof t=="string"?T1(Rn.parse(t,e),e):T1(t,e);Rn.compile=(t,e={})=>(typeof t=="string"&&(t=Rn.parse(t,e)),Upe(t,e));Rn.expand=(t,e={})=>{typeof t=="string"&&(t=Rn.parse(t,e));let r=Hpe(t,e);return e.noempty===!0&&(r=r.filter(Boolean)),e.nodupes===!0&&(r=[...new Set(r)]),r};Rn.create=(t,e={})=>t===""||t.length<3?[t]:e.expand!==!0?Rn.compile(t,e):Rn.expand(t,e);L1.exports=Rn});var dh=E((j$e,O1)=>{"use strict";var jpe=require("path"),io="\\\\/",K1=`[^${io}]`,ea="\\.",Ype="\\+",qpe="\\?",TE="\\/",Jpe="(?=.)",U1="[^/]",Vb=`(?:${TE}|$)`,H1=`(?:^|${TE})`,_b=`${ea}{1,2}${Vb}`,Wpe=`(?!${ea})`,zpe=`(?!${H1}${_b})`,Vpe=`(?!${ea}{0,1}${Vb})`,_pe=`(?!${_b})`,Xpe=`[^.${TE}]`,Zpe=`${U1}*?`,G1={DOT_LITERAL:ea,PLUS_LITERAL:Ype,QMARK_LITERAL:qpe,SLASH_LITERAL:TE,ONE_CHAR:Jpe,QMARK:U1,END_ANCHOR:Vb,DOTS_SLASH:_b,NO_DOT:Wpe,NO_DOTS:zpe,NO_DOT_SLASH:Vpe,NO_DOTS_SLASH:_pe,QMARK_NO_DOT:Xpe,STAR:Zpe,START_ANCHOR:H1},$pe=_(P({},G1),{SLASH_LITERAL:`[${io}]`,QMARK:K1,STAR:`${K1}*?`,DOTS_SLASH:`${ea}{1,2}(?:[${io}]|$)`,NO_DOT:`(?!${ea})`,NO_DOTS:`(?!(?:^|[${io}])${ea}{1,2}(?:[${io}]|$))`,NO_DOT_SLASH:`(?!${ea}{0,1}(?:[${io}]|$))`,NO_DOTS_SLASH:`(?!${ea}{1,2}(?:[${io}]|$))`,QMARK_NO_DOT:`[^.${io}]`,START_ANCHOR:`(?:^|[${io}])`,END_ANCHOR:`(?:[${io}]|$)`}),ede={alnum:"a-zA-Z0-9",alpha:"a-zA-Z",ascii:"\\x00-\\x7F",blank:" \\t",cntrl:"\\x00-\\x1F\\x7F",digit:"0-9",graph:"\\x21-\\x7E",lower:"a-z",print:"\\x20-\\x7E ",punct:"\\-!\"#$%&'()\\*+,./:;<=>?@[\\]^_`{|}~",space:" \\t\\r\\n\\v\\f",upper:"A-Z",word:"A-Za-z0-9_",xdigit:"A-Fa-f0-9"};O1.exports={MAX_LENGTH:1024*64,POSIX_REGEX_SOURCE:ede,REGEX_BACKSLASH:/\\(?![*+?^${}(|)[\]])/g,REGEX_NON_SPECIAL_CHARS:/^[^@![\].,$*+?^{}()|\\/]+/,REGEX_SPECIAL_CHARS:/[-*+?.^${}(|)[\]]/,REGEX_SPECIAL_CHARS_BACKREF:/(\\?)((\W)(\3*))/g,REGEX_SPECIAL_CHARS_GLOBAL:/([-*+?.^${}(|)[\]])/g,REGEX_REMOVE_BACKSLASH:/(?:\[.*?[^\\]\]|\\(?=.))/g,REPLACEMENTS:{"***":"*","**/**":"**","**/**/**":"**"},CHAR_0:48,CHAR_9:57,CHAR_UPPERCASE_A:65,CHAR_LOWERCASE_A:97,CHAR_UPPERCASE_Z:90,CHAR_LOWERCASE_Z:122,CHAR_LEFT_PARENTHESES:40,CHAR_RIGHT_PARENTHESES:41,CHAR_ASTERISK:42,CHAR_AMPERSAND:38,CHAR_AT:64,CHAR_BACKWARD_SLASH:92,CHAR_CARRIAGE_RETURN:13,CHAR_CIRCUMFLEX_ACCENT:94,CHAR_COLON:58,CHAR_COMMA:44,CHAR_DOT:46,CHAR_DOUBLE_QUOTE:34,CHAR_EQUAL:61,CHAR_EXCLAMATION_MARK:33,CHAR_FORM_FEED:12,CHAR_FORWARD_SLASH:47,CHAR_GRAVE_ACCENT:96,CHAR_HASH:35,CHAR_HYPHEN_MINUS:45,CHAR_LEFT_ANGLE_BRACKET:60,CHAR_LEFT_CURLY_BRACE:123,CHAR_LEFT_SQUARE_BRACKET:91,CHAR_LINE_FEED:10,CHAR_NO_BREAK_SPACE:160,CHAR_PERCENT:37,CHAR_PLUS:43,CHAR_QUESTION_MARK:63,CHAR_RIGHT_ANGLE_BRACKET:62,CHAR_RIGHT_CURLY_BRACE:125,CHAR_RIGHT_SQUARE_BRACKET:93,CHAR_SEMICOLON:59,CHAR_SINGLE_QUOTE:39,CHAR_SPACE:32,CHAR_TAB:9,CHAR_UNDERSCORE:95,CHAR_VERTICAL_LINE:124,CHAR_ZERO_WIDTH_NOBREAK_SPACE:65279,SEP:jpe.sep,extglobChars(t){return{"!":{type:"negate",open:"(?:(?!(?:",close:`))${t.STAR})`},"?":{type:"qmark",open:"(?:",close:")?"},"+":{type:"plus",open:"(?:",close:")+"},"*":{type:"star",open:"(?:",close:")*"},"@":{type:"at",open:"(?:",close:")"}}},globChars(t){return t===!0?$pe:G1}}});var Ch=E(cn=>{"use strict";var tde=require("path"),rde=process.platform==="win32",{REGEX_BACKSLASH:ide,REGEX_REMOVE_BACKSLASH:nde,REGEX_SPECIAL_CHARS:sde,REGEX_SPECIAL_CHARS_GLOBAL:ode}=dh();cn.isObject=t=>t!==null&&typeof t=="object"&&!Array.isArray(t);cn.hasRegexChars=t=>sde.test(t);cn.isRegexChar=t=>t.length===1&&cn.hasRegexChars(t);cn.escapeRegex=t=>t.replace(ode,"\\$1");cn.toPosixSlashes=t=>t.replace(ide,"/");cn.removeBackslashes=t=>t.replace(nde,e=>e==="\\"?"":e);cn.supportsLookbehinds=()=>{let t=process.version.slice(1).split(".").map(Number);return t.length===3&&t[0]>=9||t[0]===8&&t[1]>=10};cn.isWindows=t=>t&&typeof t.windows=="boolean"?t.windows:rde===!0||tde.sep==="\\";cn.escapeLast=(t,e,r)=>{let i=t.lastIndexOf(e,r);return i===-1?t:t[i-1]==="\\"?cn.escapeLast(t,e,i-1):`${t.slice(0,i)}\\${t.slice(i)}`};cn.removePrefix=(t,e={})=>{let r=t;return r.startsWith("./")&&(r=r.slice(2),e.prefix="./"),r};cn.wrapOutput=(t,e={},r={})=>{let i=r.contains?"":"^",n=r.contains?"":"$",s=`${i}(?:${t})${n}`;return e.negated===!0&&(s=`(?:^(?!${s}).*$)`),s}});var X1=E((q$e,j1)=>{"use strict";var Y1=Ch(),{CHAR_ASTERISK:Xb,CHAR_AT:ade,CHAR_BACKWARD_SLASH:mh,CHAR_COMMA:Ade,CHAR_DOT:Zb,CHAR_EXCLAMATION_MARK:q1,CHAR_FORWARD_SLASH:J1,CHAR_LEFT_CURLY_BRACE:$b,CHAR_LEFT_PARENTHESES:ev,CHAR_LEFT_SQUARE_BRACKET:lde,CHAR_PLUS:cde,CHAR_QUESTION_MARK:W1,CHAR_RIGHT_CURLY_BRACE:ude,CHAR_RIGHT_PARENTHESES:z1,CHAR_RIGHT_SQUARE_BRACKET:gde}=dh(),V1=t=>t===J1||t===mh,_1=t=>{t.isPrefix!==!0&&(t.depth=t.isGlobstar?Infinity:1)},fde=(t,e)=>{let r=e||{},i=t.length-1,n=r.parts===!0||r.scanToEnd===!0,s=[],o=[],a=[],l=t,c=-1,u=0,g=0,f=!1,h=!1,p=!1,d=!1,m=!1,I=!1,B=!1,b=!1,R=!1,H=0,L,K,J={value:"",depth:0,isGlob:!1},ne=()=>c>=i,q=()=>l.charCodeAt(c+1),A=()=>(L=K,l.charCodeAt(++c));for(;c0&&(W=l.slice(0,u),l=l.slice(u),g-=u),V&&p===!0&&g>0?(V=l.slice(0,g),X=l.slice(g)):p===!0?(V="",X=l):V=l,V&&V!==""&&V!=="/"&&V!==l&&V1(V.charCodeAt(V.length-1))&&(V=V.slice(0,-1)),r.unescape===!0&&(X&&(X=Y1.removeBackslashes(X)),V&&B===!0&&(V=Y1.removeBackslashes(V)));let F={prefix:W,input:t,start:u,base:V,glob:X,isBrace:f,isBracket:h,isGlob:p,isExtglob:d,isGlobstar:m,negated:b};if(r.tokens===!0&&(F.maxDepth=0,V1(K)||o.push(J),F.tokens=o),r.parts===!0||r.tokens===!0){let D;for(let he=0;he{"use strict";var ME=dh(),Fn=Ch(),{MAX_LENGTH:OE,POSIX_REGEX_SOURCE:hde,REGEX_NON_SPECIAL_CHARS:pde,REGEX_SPECIAL_CHARS_BACKREF:dde,REPLACEMENTS:$1}=ME,Cde=(t,e)=>{if(typeof e.expandRange=="function")return e.expandRange(...t,e);t.sort();let r=`[${t.join("-")}]`;try{new RegExp(r)}catch(i){return t.map(n=>Fn.escapeRegex(n)).join("..")}return r},au=(t,e)=>`Missing ${t}: "${e}" - use "\\\\${e}" to match literal characters`,eU=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");t=$1[t]||t;let r=P({},e),i=typeof r.maxLength=="number"?Math.min(OE,r.maxLength):OE,n=t.length;if(n>i)throw new SyntaxError(`Input length: ${n}, exceeds maximum allowed length: ${i}`);let s={type:"bos",value:"",output:r.prepend||""},o=[s],a=r.capture?"":"?:",l=Fn.isWindows(e),c=ME.globChars(l),u=ME.extglobChars(c),{DOT_LITERAL:g,PLUS_LITERAL:f,SLASH_LITERAL:h,ONE_CHAR:p,DOTS_SLASH:d,NO_DOT:m,NO_DOT_SLASH:I,NO_DOTS_SLASH:B,QMARK:b,QMARK_NO_DOT:R,STAR:H,START_ANCHOR:L}=c,K=G=>`(${a}(?:(?!${L}${G.dot?d:g}).)*?)`,J=r.dot?"":m,ne=r.dot?b:R,q=r.bash===!0?K(r):H;r.capture&&(q=`(${q})`),typeof r.noext=="boolean"&&(r.noextglob=r.noext);let A={input:t,index:-1,start:0,dot:r.dot===!0,consumed:"",output:"",prefix:"",backtrack:!1,negated:!1,brackets:0,braces:0,parens:0,quotes:0,globstar:!1,tokens:o};t=Fn.removePrefix(t,A),n=t.length;let V=[],W=[],X=[],F=s,D,he=()=>A.index===n-1,pe=A.peek=(G=1)=>t[A.index+G],Ne=A.advance=()=>t[++A.index],Pe=()=>t.slice(A.index+1),qe=(G="",Ce=0)=>{A.consumed+=G,A.index+=Ce},re=G=>{A.output+=G.output!=null?G.output:G.value,qe(G.value)},se=()=>{let G=1;for(;pe()==="!"&&(pe(2)!=="("||pe(3)==="?");)Ne(),A.start++,G++;return G%2==0?!1:(A.negated=!0,A.start++,!0)},be=G=>{A[G]++,X.push(G)},ae=G=>{A[G]--,X.pop()},Ae=G=>{if(F.type==="globstar"){let Ce=A.braces>0&&(G.type==="comma"||G.type==="brace"),ee=G.extglob===!0||V.length&&(G.type==="pipe"||G.type==="paren");G.type!=="slash"&&G.type!=="paren"&&!Ce&&!ee&&(A.output=A.output.slice(0,-F.output.length),F.type="star",F.value="*",F.output=q,A.output+=F.output)}if(V.length&&G.type!=="paren"&&!u[G.value]&&(V[V.length-1].inner+=G.value),(G.value||G.output)&&re(G),F&&F.type==="text"&&G.type==="text"){F.value+=G.value,F.output=(F.output||"")+G.value;return}G.prev=F,o.push(G),F=G},De=(G,Ce)=>{let ee=_(P({},u[Ce]),{conditions:1,inner:""});ee.prev=F,ee.parens=A.parens,ee.output=A.output;let Ue=(r.capture?"(":"")+ee.open;be("parens"),Ae({type:G,value:Ce,output:A.output?"":p}),Ae({type:"paren",extglob:!0,value:Ne(),output:Ue}),V.push(ee)},$=G=>{let Ce=G.close+(r.capture?")":"");if(G.type==="negate"){let ee=q;G.inner&&G.inner.length>1&&G.inner.includes("/")&&(ee=K(r)),(ee!==q||he()||/^\)+$/.test(Pe()))&&(Ce=G.close=`)$))${ee}`),G.prev.type==="bos"&&(A.negatedExtglob=!0)}Ae({type:"paren",extglob:!0,value:D,output:Ce}),ae("parens")};if(r.fastpaths!==!1&&!/(^[*!]|[/()[\]{}"])/.test(t)){let G=!1,Ce=t.replace(dde,(ee,Ue,Oe,vt,dt,ri)=>vt==="\\"?(G=!0,ee):vt==="?"?Ue?Ue+vt+(dt?b.repeat(dt.length):""):ri===0?ne+(dt?b.repeat(dt.length):""):b.repeat(Oe.length):vt==="."?g.repeat(Oe.length):vt==="*"?Ue?Ue+vt+(dt?q:""):q:Ue?ee:`\\${ee}`);return G===!0&&(r.unescape===!0?Ce=Ce.replace(/\\/g,""):Ce=Ce.replace(/\\+/g,ee=>ee.length%2==0?"\\\\":ee?"\\":"")),Ce===t&&r.contains===!0?(A.output=t,A):(A.output=Fn.wrapOutput(Ce,A,e),A)}for(;!he();){if(D=Ne(),D==="\0")continue;if(D==="\\"){let ee=pe();if(ee==="/"&&r.bash!==!0||ee==="."||ee===";")continue;if(!ee){D+="\\",Ae({type:"text",value:D});continue}let Ue=/^\\+/.exec(Pe()),Oe=0;if(Ue&&Ue[0].length>2&&(Oe=Ue[0].length,A.index+=Oe,Oe%2!=0&&(D+="\\")),r.unescape===!0?D=Ne()||"":D+=Ne()||"",A.brackets===0){Ae({type:"text",value:D});continue}}if(A.brackets>0&&(D!=="]"||F.value==="["||F.value==="[^")){if(r.posix!==!1&&D===":"){let ee=F.value.slice(1);if(ee.includes("[")&&(F.posix=!0,ee.includes(":"))){let Ue=F.value.lastIndexOf("["),Oe=F.value.slice(0,Ue),vt=F.value.slice(Ue+2),dt=hde[vt];if(dt){F.value=Oe+dt,A.backtrack=!0,Ne(),!s.output&&o.indexOf(F)===1&&(s.output=p);continue}}}(D==="["&&pe()!==":"||D==="-"&&pe()==="]")&&(D=`\\${D}`),D==="]"&&(F.value==="["||F.value==="[^")&&(D=`\\${D}`),r.posix===!0&&D==="!"&&F.value==="["&&(D="^"),F.value+=D,re({value:D});continue}if(A.quotes===1&&D!=='"'){D=Fn.escapeRegex(D),F.value+=D,re({value:D});continue}if(D==='"'){A.quotes=A.quotes===1?0:1,r.keepQuotes===!0&&Ae({type:"text",value:D});continue}if(D==="("){be("parens"),Ae({type:"paren",value:D});continue}if(D===")"){if(A.parens===0&&r.strictBrackets===!0)throw new SyntaxError(au("opening","("));let ee=V[V.length-1];if(ee&&A.parens===ee.parens+1){$(V.pop());continue}Ae({type:"paren",value:D,output:A.parens?")":"\\)"}),ae("parens");continue}if(D==="["){if(r.nobracket===!0||!Pe().includes("]")){if(r.nobracket!==!0&&r.strictBrackets===!0)throw new SyntaxError(au("closing","]"));D=`\\${D}`}else be("brackets");Ae({type:"bracket",value:D});continue}if(D==="]"){if(r.nobracket===!0||F&&F.type==="bracket"&&F.value.length===1){Ae({type:"text",value:D,output:`\\${D}`});continue}if(A.brackets===0){if(r.strictBrackets===!0)throw new SyntaxError(au("opening","["));Ae({type:"text",value:D,output:`\\${D}`});continue}ae("brackets");let ee=F.value.slice(1);if(F.posix!==!0&&ee[0]==="^"&&!ee.includes("/")&&(D=`/${D}`),F.value+=D,re({value:D}),r.literalBrackets===!1||Fn.hasRegexChars(ee))continue;let Ue=Fn.escapeRegex(F.value);if(A.output=A.output.slice(0,-F.value.length),r.literalBrackets===!0){A.output+=Ue,F.value=Ue;continue}F.value=`(${a}${Ue}|${F.value})`,A.output+=F.value;continue}if(D==="{"&&r.nobrace!==!0){be("braces");let ee={type:"brace",value:D,output:"(",outputIndex:A.output.length,tokensIndex:A.tokens.length};W.push(ee),Ae(ee);continue}if(D==="}"){let ee=W[W.length-1];if(r.nobrace===!0||!ee){Ae({type:"text",value:D,output:D});continue}let Ue=")";if(ee.dots===!0){let Oe=o.slice(),vt=[];for(let dt=Oe.length-1;dt>=0&&(o.pop(),Oe[dt].type!=="brace");dt--)Oe[dt].type!=="dots"&&vt.unshift(Oe[dt].value);Ue=Cde(vt,r),A.backtrack=!0}if(ee.comma!==!0&&ee.dots!==!0){let Oe=A.output.slice(0,ee.outputIndex),vt=A.tokens.slice(ee.tokensIndex);ee.value=ee.output="\\{",D=Ue="\\}",A.output=Oe;for(let dt of vt)A.output+=dt.output||dt.value}Ae({type:"brace",value:D,output:Ue}),ae("braces"),W.pop();continue}if(D==="|"){V.length>0&&V[V.length-1].conditions++,Ae({type:"text",value:D});continue}if(D===","){let ee=D,Ue=W[W.length-1];Ue&&X[X.length-1]==="braces"&&(Ue.comma=!0,ee="|"),Ae({type:"comma",value:D,output:ee});continue}if(D==="/"){if(F.type==="dot"&&A.index===A.start+1){A.start=A.index+1,A.consumed="",A.output="",o.pop(),F=s;continue}Ae({type:"slash",value:D,output:h});continue}if(D==="."){if(A.braces>0&&F.type==="dot"){F.value==="."&&(F.output=g);let ee=W[W.length-1];F.type="dots",F.output+=D,F.value+=D,ee.dots=!0;continue}if(A.braces+A.parens===0&&F.type!=="bos"&&F.type!=="slash"){Ae({type:"text",value:D,output:g});continue}Ae({type:"dot",value:D,output:g});continue}if(D==="?"){if(!(F&&F.value==="(")&&r.noextglob!==!0&&pe()==="("&&pe(2)!=="?"){De("qmark",D);continue}if(F&&F.type==="paren"){let Ue=pe(),Oe=D;if(Ue==="<"&&!Fn.supportsLookbehinds())throw new Error("Node.js v10 or higher is required for regex lookbehinds");(F.value==="("&&!/[!=<:]/.test(Ue)||Ue==="<"&&!/<([!=]|\w+>)/.test(Pe()))&&(Oe=`\\${D}`),Ae({type:"text",value:D,output:Oe});continue}if(r.dot!==!0&&(F.type==="slash"||F.type==="bos")){Ae({type:"qmark",value:D,output:R});continue}Ae({type:"qmark",value:D,output:b});continue}if(D==="!"){if(r.noextglob!==!0&&pe()==="("&&(pe(2)!=="?"||!/[!=<:]/.test(pe(3)))){De("negate",D);continue}if(r.nonegate!==!0&&A.index===0){se();continue}}if(D==="+"){if(r.noextglob!==!0&&pe()==="("&&pe(2)!=="?"){De("plus",D);continue}if(F&&F.value==="("||r.regex===!1){Ae({type:"plus",value:D,output:f});continue}if(F&&(F.type==="bracket"||F.type==="paren"||F.type==="brace")||A.parens>0){Ae({type:"plus",value:D});continue}Ae({type:"plus",value:f});continue}if(D==="@"){if(r.noextglob!==!0&&pe()==="("&&pe(2)!=="?"){Ae({type:"at",extglob:!0,value:D,output:""});continue}Ae({type:"text",value:D});continue}if(D!=="*"){(D==="$"||D==="^")&&(D=`\\${D}`);let ee=pde.exec(Pe());ee&&(D+=ee[0],A.index+=ee[0].length),Ae({type:"text",value:D});continue}if(F&&(F.type==="globstar"||F.star===!0)){F.type="star",F.star=!0,F.value+=D,F.output=q,A.backtrack=!0,A.globstar=!0,qe(D);continue}let G=Pe();if(r.noextglob!==!0&&/^\([^?]/.test(G)){De("star",D);continue}if(F.type==="star"){if(r.noglobstar===!0){qe(D);continue}let ee=F.prev,Ue=ee.prev,Oe=ee.type==="slash"||ee.type==="bos",vt=Ue&&(Ue.type==="star"||Ue.type==="globstar");if(r.bash===!0&&(!Oe||G[0]&&G[0]!=="/")){Ae({type:"star",value:D,output:""});continue}let dt=A.braces>0&&(ee.type==="comma"||ee.type==="brace"),ri=V.length&&(ee.type==="pipe"||ee.type==="paren");if(!Oe&&ee.type!=="paren"&&!dt&&!ri){Ae({type:"star",value:D,output:""});continue}for(;G.slice(0,3)==="/**";){let ii=t[A.index+4];if(ii&&ii!=="/")break;G=G.slice(3),qe("/**",3)}if(ee.type==="bos"&&he()){F.type="globstar",F.value+=D,F.output=K(r),A.output=F.output,A.globstar=!0,qe(D);continue}if(ee.type==="slash"&&ee.prev.type!=="bos"&&!vt&&he()){A.output=A.output.slice(0,-(ee.output+F.output).length),ee.output=`(?:${ee.output}`,F.type="globstar",F.output=K(r)+(r.strictSlashes?")":"|$)"),F.value+=D,A.globstar=!0,A.output+=ee.output+F.output,qe(D);continue}if(ee.type==="slash"&&ee.prev.type!=="bos"&&G[0]==="/"){let ii=G[1]!==void 0?"|$":"";A.output=A.output.slice(0,-(ee.output+F.output).length),ee.output=`(?:${ee.output}`,F.type="globstar",F.output=`${K(r)}${h}|${h}${ii})`,F.value+=D,A.output+=ee.output+F.output,A.globstar=!0,qe(D+Ne()),Ae({type:"slash",value:"/",output:""});continue}if(ee.type==="bos"&&G[0]==="/"){F.type="globstar",F.value+=D,F.output=`(?:^|${h}|${K(r)}${h})`,A.output=F.output,A.globstar=!0,qe(D+Ne()),Ae({type:"slash",value:"/",output:""});continue}A.output=A.output.slice(0,-F.output.length),F.type="globstar",F.output=K(r),F.value+=D,A.output+=F.output,A.globstar=!0,qe(D);continue}let Ce={type:"star",value:D,output:q};if(r.bash===!0){Ce.output=".*?",(F.type==="bos"||F.type==="slash")&&(Ce.output=J+Ce.output),Ae(Ce);continue}if(F&&(F.type==="bracket"||F.type==="paren")&&r.regex===!0){Ce.output=D,Ae(Ce);continue}(A.index===A.start||F.type==="slash"||F.type==="dot")&&(F.type==="dot"?(A.output+=I,F.output+=I):r.dot===!0?(A.output+=B,F.output+=B):(A.output+=J,F.output+=J),pe()!=="*"&&(A.output+=p,F.output+=p)),Ae(Ce)}for(;A.brackets>0;){if(r.strictBrackets===!0)throw new SyntaxError(au("closing","]"));A.output=Fn.escapeLast(A.output,"["),ae("brackets")}for(;A.parens>0;){if(r.strictBrackets===!0)throw new SyntaxError(au("closing",")"));A.output=Fn.escapeLast(A.output,"("),ae("parens")}for(;A.braces>0;){if(r.strictBrackets===!0)throw new SyntaxError(au("closing","}"));A.output=Fn.escapeLast(A.output,"{"),ae("braces")}if(r.strictSlashes!==!0&&(F.type==="star"||F.type==="bracket")&&Ae({type:"maybe_slash",value:"",output:`${h}?`}),A.backtrack===!0){A.output="";for(let G of A.tokens)A.output+=G.output!=null?G.output:G.value,G.suffix&&(A.output+=G.suffix)}return A};eU.fastpaths=(t,e)=>{let r=P({},e),i=typeof r.maxLength=="number"?Math.min(OE,r.maxLength):OE,n=t.length;if(n>i)throw new SyntaxError(`Input length: ${n}, exceeds maximum allowed length: ${i}`);t=$1[t]||t;let s=Fn.isWindows(e),{DOT_LITERAL:o,SLASH_LITERAL:a,ONE_CHAR:l,DOTS_SLASH:c,NO_DOT:u,NO_DOTS:g,NO_DOTS_SLASH:f,STAR:h,START_ANCHOR:p}=ME.globChars(s),d=r.dot?g:u,m=r.dot?f:u,I=r.capture?"":"?:",B={negated:!1,prefix:""},b=r.bash===!0?".*?":h;r.capture&&(b=`(${b})`);let R=J=>J.noglobstar===!0?b:`(${I}(?:(?!${p}${J.dot?c:o}).)*?)`,H=J=>{switch(J){case"*":return`${d}${l}${b}`;case".*":return`${o}${l}${b}`;case"*.*":return`${d}${b}${o}${l}${b}`;case"*/*":return`${d}${b}${a}${l}${m}${b}`;case"**":return d+R(r);case"**/*":return`(?:${d}${R(r)}${a})?${m}${l}${b}`;case"**/*.*":return`(?:${d}${R(r)}${a})?${m}${b}${o}${l}${b}`;case"**/.*":return`(?:${d}${R(r)}${a})?${o}${l}${b}`;default:{let ne=/^(.*?)\.(\w+)$/.exec(J);if(!ne)return;let q=H(ne[1]);return q?q+o+ne[2]:void 0}}},L=Fn.removePrefix(t,B),K=H(L);return K&&r.strictSlashes!==!0&&(K+=`${a}?`),K};Z1.exports=eU});var iU=E((W$e,rU)=>{"use strict";var mde=require("path"),Ede=X1(),tv=tU(),rv=Ch(),Ide=dh(),yde=t=>t&&typeof t=="object"&&!Array.isArray(t),Dr=(t,e,r=!1)=>{if(Array.isArray(t)){let u=t.map(f=>Dr(f,e,r));return f=>{for(let h of u){let p=h(f);if(p)return p}return!1}}let i=yde(t)&&t.tokens&&t.input;if(t===""||typeof t!="string"&&!i)throw new TypeError("Expected pattern to be a non-empty string");let n=e||{},s=rv.isWindows(e),o=i?Dr.compileRe(t,e):Dr.makeRe(t,e,!1,!0),a=o.state;delete o.state;let l=()=>!1;if(n.ignore){let u=_(P({},e),{ignore:null,onMatch:null,onResult:null});l=Dr(n.ignore,u,r)}let c=(u,g=!1)=>{let{isMatch:f,match:h,output:p}=Dr.test(u,o,e,{glob:t,posix:s}),d={glob:t,state:a,regex:o,posix:s,input:u,output:p,match:h,isMatch:f};return typeof n.onResult=="function"&&n.onResult(d),f===!1?(d.isMatch=!1,g?d:!1):l(u)?(typeof n.onIgnore=="function"&&n.onIgnore(d),d.isMatch=!1,g?d:!1):(typeof n.onMatch=="function"&&n.onMatch(d),g?d:!0)};return r&&(c.state=a),c};Dr.test=(t,e,r,{glob:i,posix:n}={})=>{if(typeof t!="string")throw new TypeError("Expected input to be a string");if(t==="")return{isMatch:!1,output:""};let s=r||{},o=s.format||(n?rv.toPosixSlashes:null),a=t===i,l=a&&o?o(t):t;return a===!1&&(l=o?o(t):t,a=l===i),(a===!1||s.capture===!0)&&(s.matchBase===!0||s.basename===!0?a=Dr.matchBase(t,e,r,n):a=e.exec(l)),{isMatch:Boolean(a),match:a,output:l}};Dr.matchBase=(t,e,r,i=rv.isWindows(r))=>(e instanceof RegExp?e:Dr.makeRe(e,r)).test(mde.basename(t));Dr.isMatch=(t,e,r)=>Dr(e,r)(t);Dr.parse=(t,e)=>Array.isArray(t)?t.map(r=>Dr.parse(r,e)):tv(t,_(P({},e),{fastpaths:!1}));Dr.scan=(t,e)=>Ede(t,e);Dr.compileRe=(t,e,r=!1,i=!1)=>{if(r===!0)return t.output;let n=e||{},s=n.contains?"":"^",o=n.contains?"":"$",a=`${s}(?:${t.output})${o}`;t&&t.negated===!0&&(a=`^(?!${a}).*$`);let l=Dr.toRegex(a,e);return i===!0&&(l.state=t),l};Dr.makeRe=(t,e,r=!1,i=!1)=>{if(!t||typeof t!="string")throw new TypeError("Expected a non-empty string");let n=e||{},s={negated:!1,fastpaths:!0},o="",a;return t.startsWith("./")&&(t=t.slice(2),o=s.prefix="./"),n.fastpaths!==!1&&(t[0]==="."||t[0]==="*")&&(a=tv.fastpaths(t,e)),a===void 0?(s=tv(t,e),s.prefix=o+(s.prefix||"")):s.output=a,Dr.compileRe(s,e,r,i)};Dr.toRegex=(t,e)=>{try{let r=e||{};return new RegExp(t,r.flags||(r.nocase?"i":""))}catch(r){if(e&&e.debug===!0)throw r;return/$^/}};Dr.constants=Ide;rU.exports=Dr});var iv=E((z$e,nU)=>{"use strict";nU.exports=iU()});var Nn=E((V$e,sU)=>{"use strict";var oU=require("util"),aU=M1(),no=iv(),nv=Ch(),AU=t=>typeof t=="string"&&(t===""||t==="./"),pr=(t,e,r)=>{e=[].concat(e),t=[].concat(t);let i=new Set,n=new Set,s=new Set,o=0,a=u=>{s.add(u.output),r&&r.onResult&&r.onResult(u)};for(let u=0;u!i.has(u));if(r&&c.length===0){if(r.failglob===!0)throw new Error(`No matches found for "${e.join(", ")}"`);if(r.nonull===!0||r.nullglob===!0)return r.unescape?e.map(u=>u.replace(/\\/g,"")):e}return c};pr.match=pr;pr.matcher=(t,e)=>no(t,e);pr.isMatch=(t,e,r)=>no(e,r)(t);pr.any=pr.isMatch;pr.not=(t,e,r={})=>{e=[].concat(e).map(String);let i=new Set,n=[],s=a=>{r.onResult&&r.onResult(a),n.push(a.output)},o=pr(t,e,_(P({},r),{onResult:s}));for(let a of n)o.includes(a)||i.add(a);return[...i]};pr.contains=(t,e,r)=>{if(typeof t!="string")throw new TypeError(`Expected a string: "${oU.inspect(t)}"`);if(Array.isArray(e))return e.some(i=>pr.contains(t,i,r));if(typeof e=="string"){if(AU(t)||AU(e))return!1;if(t.includes(e)||t.startsWith("./")&&t.slice(2).includes(e))return!0}return pr.isMatch(t,e,_(P({},r),{contains:!0}))};pr.matchKeys=(t,e,r)=>{if(!nv.isObject(t))throw new TypeError("Expected the first argument to be an object");let i=pr(Object.keys(t),e,r),n={};for(let s of i)n[s]=t[s];return n};pr.some=(t,e,r)=>{let i=[].concat(t);for(let n of[].concat(e)){let s=no(String(n),r);if(i.some(o=>s(o)))return!0}return!1};pr.every=(t,e,r)=>{let i=[].concat(t);for(let n of[].concat(e)){let s=no(String(n),r);if(!i.every(o=>s(o)))return!1}return!0};pr.all=(t,e,r)=>{if(typeof t!="string")throw new TypeError(`Expected a string: "${oU.inspect(t)}"`);return[].concat(e).every(i=>no(i,r)(t))};pr.capture=(t,e,r)=>{let i=nv.isWindows(r),s=no.makeRe(String(t),_(P({},r),{capture:!0})).exec(i?nv.toPosixSlashes(e):e);if(s)return s.slice(1).map(o=>o===void 0?"":o)};pr.makeRe=(...t)=>no.makeRe(...t);pr.scan=(...t)=>no.scan(...t);pr.parse=(t,e)=>{let r=[];for(let i of[].concat(t||[]))for(let n of aU(String(i),e))r.push(no.parse(n,e));return r};pr.braces=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");return e&&e.nobrace===!0||!/\{.*\}/.test(t)?[t]:aU(t,e)};pr.braceExpand=(t,e)=>{if(typeof t!="string")throw new TypeError("Expected a string");return pr.braces(t,_(P({},e),{expand:!0}))};sU.exports=pr});var cU=E((_$e,lU)=>{"use strict";lU.exports=({onlyFirst:t=!1}={})=>{let e=["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:[a-zA-Z\\d]*(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)","(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");return new RegExp(e,t?void 0:"g")}});var gU=E((X$e,uU)=>{"use strict";var wde=cU();uU.exports=t=>typeof t=="string"?t.replace(wde(),""):t});var lu={};it(lu,{KeyRelationship:()=>Bl,applyCascade:()=>fv,base64RegExp:()=>CU,colorStringAlphaRegExp:()=>dU,colorStringRegExp:()=>pU,computeKey:()=>rA,getPrintable:()=>Mr,hasExactLength:()=>wU,hasForbiddenKeys:()=>eCe,hasKeyRelationship:()=>pv,hasMaxLength:()=>Mde,hasMinLength:()=>Tde,hasMutuallyExclusiveKeys:()=>tCe,hasRequiredKeys:()=>$de,hasUniqueItems:()=>Ode,isArray:()=>xde,isAtLeast:()=>Hde,isAtMost:()=>Gde,isBase64:()=>Xde,isBoolean:()=>bde,isDate:()=>Sde,isDict:()=>Pde,isEnum:()=>Yi,isHexColor:()=>_de,isISO8601:()=>Vde,isInExclusiveRange:()=>Yde,isInInclusiveRange:()=>jde,isInstanceOf:()=>Rde,isInteger:()=>qde,isJSON:()=>Zde,isLiteral:()=>Bde,isLowerCase:()=>Jde,isNegative:()=>Kde,isNullable:()=>Lde,isNumber:()=>vde,isObject:()=>Dde,isOneOf:()=>Fde,isOptional:()=>Nde,isPositive:()=>Ude,isString:()=>gv,isTuple:()=>kde,isUUID4:()=>zde,isUnknown:()=>yU,isUpperCase:()=>Wde,iso8601RegExp:()=>uv,makeCoercionFn:()=>wl,makeSetter:()=>IU,makeTrait:()=>EU,makeValidator:()=>Ct,matchesRegExp:()=>hv,plural:()=>GE,pushError:()=>at,simpleKeyRegExp:()=>hU,uuid4RegExp:()=>mU});function Ct({test:t}){return EU(t)()}function Mr(t){return t===null?"null":t===void 0?"undefined":t===""?"an empty string":JSON.stringify(t)}function rA(t,e){var r,i,n;return typeof e=="number"?`${(r=t==null?void 0:t.p)!==null&&r!==void 0?r:"."}[${e}]`:hU.test(e)?`${(i=t==null?void 0:t.p)!==null&&i!==void 0?i:""}.${e}`:`${(n=t==null?void 0:t.p)!==null&&n!==void 0?n:"."}[${JSON.stringify(e)}]`}function wl(t,e){return r=>{let i=t[e];return t[e]=r,wl(t,e).bind(null,i)}}function IU(t,e){return r=>{t[e]=r}}function GE(t,e,r){return t===1?e:r}function at({errors:t,p:e}={},r){return t==null||t.push(`${e!=null?e:"."}: ${r}`),!1}function Bde(t){return Ct({test:(e,r)=>e!==t?at(r,`Expected a literal (got ${Mr(t)})`):!0})}function Yi(t){let e=Array.isArray(t)?t:Object.values(t),r=new Set(e);return Ct({test:(i,n)=>r.has(i)?!0:at(n,`Expected a valid enumeration value (got ${Mr(i)})`)})}var hU,pU,dU,CU,mU,uv,EU,yU,gv,Qde,bde,vde,Sde,xde,kde,Pde,Dde,Rde,Fde,fv,Nde,Lde,Tde,Mde,wU,Ode,Kde,Ude,Hde,Gde,jde,Yde,qde,hv,Jde,Wde,zde,Vde,_de,Xde,Zde,$de,eCe,tCe,Bl,rCe,pv,Ss=Yfe(()=>{hU=/^[a-zA-Z_][a-zA-Z0-9_]*$/,pU=/^#[0-9a-f]{6}$/i,dU=/^#[0-9a-f]{6}([0-9a-f]{2})?$/i,CU=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/,mU=/^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89aAbB][a-f0-9]{3}-[a-f0-9]{12}$/i,uv=/^(?:[1-9]\d{3}(-?)(?:(?:0[1-9]|1[0-2])\1(?:0[1-9]|1\d|2[0-8])|(?:0[13-9]|1[0-2])\1(?:29|30)|(?:0[13578]|1[02])(?:\1)31|00[1-9]|0[1-9]\d|[12]\d{2}|3(?:[0-5]\d|6[0-5]))|(?:[1-9]\d(?:0[48]|[2468][048]|[13579][26])|(?:[2468][048]|[13579][26])00)(?:(-?)02(?:\2)29|-?366))T(?:[01]\d|2[0-3])(:?)[0-5]\d(?:\3[0-5]\d)?(?:Z|[+-][01]\d(?:\3[0-5]\d)?)$/,EU=t=>()=>t;yU=()=>Ct({test:(t,e)=>!0});gv=()=>Ct({test:(t,e)=>typeof t!="string"?at(e,`Expected a string (got ${Mr(t)})`):!0});Qde=new Map([["true",!0],["True",!0],["1",!0],[1,!0],["false",!1],["False",!1],["0",!1],[0,!1]]),bde=()=>Ct({test:(t,e)=>{var r;if(typeof t!="boolean"){if(typeof(e==null?void 0:e.coercions)!="undefined"){if(typeof(e==null?void 0:e.coercion)=="undefined")return at(e,"Unbound coercion result");let i=Qde.get(t);if(typeof i!="undefined")return e.coercions.push([(r=e.p)!==null&&r!==void 0?r:".",e.coercion.bind(null,i)]),!0}return at(e,`Expected a boolean (got ${Mr(t)})`)}return!0}}),vde=()=>Ct({test:(t,e)=>{var r;if(typeof t!="number"){if(typeof(e==null?void 0:e.coercions)!="undefined"){if(typeof(e==null?void 0:e.coercion)=="undefined")return at(e,"Unbound coercion result");let i;if(typeof t=="string"){let n;try{n=JSON.parse(t)}catch(s){}if(typeof n=="number")if(JSON.stringify(n)===t)i=n;else return at(e,`Received a number that can't be safely represented by the runtime (${t})`)}if(typeof i!="undefined")return e.coercions.push([(r=e.p)!==null&&r!==void 0?r:".",e.coercion.bind(null,i)]),!0}return at(e,`Expected a number (got ${Mr(t)})`)}return!0}}),Sde=()=>Ct({test:(t,e)=>{var r;if(!(t instanceof Date)){if(typeof(e==null?void 0:e.coercions)!="undefined"){if(typeof(e==null?void 0:e.coercion)=="undefined")return at(e,"Unbound coercion result");let i;if(typeof t=="string"&&uv.test(t))i=new Date(t);else{let n;if(typeof t=="string"){let s;try{s=JSON.parse(t)}catch(o){}typeof s=="number"&&(n=s)}else typeof t=="number"&&(n=t);if(typeof n!="undefined")if(Number.isSafeInteger(n)||!Number.isSafeInteger(n*1e3))i=new Date(n*1e3);else return at(e,`Received a timestamp that can't be safely represented by the runtime (${t})`)}if(typeof i!="undefined")return e.coercions.push([(r=e.p)!==null&&r!==void 0?r:".",e.coercion.bind(null,i)]),!0}return at(e,`Expected a date (got ${Mr(t)})`)}return!0}}),xde=(t,{delimiter:e}={})=>Ct({test:(r,i)=>{var n;if(typeof r=="string"&&typeof e!="undefined"&&typeof(i==null?void 0:i.coercions)!="undefined"){if(typeof(i==null?void 0:i.coercion)=="undefined")return at(i,"Unbound coercion result");r=r.split(e),i.coercions.push([(n=i.p)!==null&&n!==void 0?n:".",i.coercion.bind(null,r)])}if(!Array.isArray(r))return at(i,`Expected an array (got ${Mr(r)})`);let s=!0;for(let o=0,a=r.length;o{let r=wU(t.length);return Ct({test:(i,n)=>{var s;if(typeof i=="string"&&typeof e!="undefined"&&typeof(n==null?void 0:n.coercions)!="undefined"){if(typeof(n==null?void 0:n.coercion)=="undefined")return at(n,"Unbound coercion result");i=i.split(e),n.coercions.push([(s=n.p)!==null&&s!==void 0?s:".",n.coercion.bind(null,i)])}if(!Array.isArray(i))return at(n,`Expected a tuple (got ${Mr(i)})`);let o=r(i,Object.assign({},n));for(let a=0,l=i.length;aCt({test:(r,i)=>{if(typeof r!="object"||r===null)return at(i,`Expected an object (got ${Mr(r)})`);let n=Object.keys(r),s=!0;for(let o=0,a=n.length;o{let r=Object.keys(t);return Ct({test:(i,n)=>{if(typeof i!="object"||i===null)return at(n,`Expected an object (got ${Mr(i)})`);let s=new Set([...r,...Object.keys(i)]),o={},a=!0;for(let l of s){if(l==="constructor"||l==="__proto__")a=at(Object.assign(Object.assign({},n),{p:rA(n,l)}),"Unsafe property name");else{let c=Object.prototype.hasOwnProperty.call(t,l)?t[l]:void 0,u=Object.prototype.hasOwnProperty.call(i,l)?i[l]:void 0;typeof c!="undefined"?a=c(u,Object.assign(Object.assign({},n),{p:rA(n,l),coercion:wl(i,l)}))&&a:e===null?a=at(Object.assign(Object.assign({},n),{p:rA(n,l)}),`Extraneous property (got ${Mr(u)})`):Object.defineProperty(o,l,{enumerable:!0,get:()=>u,set:IU(i,l)})}if(!a&&(n==null?void 0:n.errors)==null)break}return e!==null&&(a||(n==null?void 0:n.errors)!=null)&&(a=e(o,n)&&a),a}})},Rde=t=>Ct({test:(e,r)=>e instanceof t?!0:at(r,`Expected an instance of ${t.name} (got ${Mr(e)})`)}),Fde=(t,{exclusive:e=!1}={})=>Ct({test:(r,i)=>{var n,s,o;let a=[],l=typeof(i==null?void 0:i.errors)!="undefined"?[]:void 0;for(let c=0,u=t.length;c1?at(i,`Expected to match exactly a single predicate (matched ${a.join(", ")})`):(o=i==null?void 0:i.errors)===null||o===void 0||o.push(...l),!1}}),fv=(t,e)=>Ct({test:(r,i)=>{var n,s;let o={value:r},a=typeof(i==null?void 0:i.coercions)!="undefined"?wl(o,"value"):void 0,l=typeof(i==null?void 0:i.coercions)!="undefined"?[]:void 0;if(!t(r,Object.assign(Object.assign({},i),{coercion:a,coercions:l})))return!1;let c=[];if(typeof l!="undefined")for(let[,u]of l)c.push(u());try{if(typeof(i==null?void 0:i.coercions)!="undefined"){if(o.value!==r){if(typeof(i==null?void 0:i.coercion)=="undefined")return at(i,"Unbound coercion result");i.coercions.push([(n=i.p)!==null&&n!==void 0?n:".",i.coercion.bind(null,o.value)])}(s=i==null?void 0:i.coercions)===null||s===void 0||s.push(...l)}return e.every(u=>u(o.value,i))}finally{for(let u of c)u()}}}),Nde=t=>Ct({test:(e,r)=>typeof e=="undefined"?!0:t(e,r)}),Lde=t=>Ct({test:(e,r)=>e===null?!0:t(e,r)}),Tde=t=>Ct({test:(e,r)=>e.length>=t?!0:at(r,`Expected to have a length of at least ${t} elements (got ${e.length})`)}),Mde=t=>Ct({test:(e,r)=>e.length<=t?!0:at(r,`Expected to have a length of at most ${t} elements (got ${e.length})`)}),wU=t=>Ct({test:(e,r)=>e.length!==t?at(r,`Expected to have a length of exactly ${t} elements (got ${e.length})`):!0}),Ode=({map:t}={})=>Ct({test:(e,r)=>{let i=new Set,n=new Set;for(let s=0,o=e.length;sCt({test:(t,e)=>t<=0?!0:at(e,`Expected to be negative (got ${t})`)}),Ude=()=>Ct({test:(t,e)=>t>=0?!0:at(e,`Expected to be positive (got ${t})`)}),Hde=t=>Ct({test:(e,r)=>e>=t?!0:at(r,`Expected to be at least ${t} (got ${e})`)}),Gde=t=>Ct({test:(e,r)=>e<=t?!0:at(r,`Expected to be at most ${t} (got ${e})`)}),jde=(t,e)=>Ct({test:(r,i)=>r>=t&&r<=e?!0:at(i,`Expected to be in the [${t}; ${e}] range (got ${r})`)}),Yde=(t,e)=>Ct({test:(r,i)=>r>=t&&rCt({test:(e,r)=>e!==Math.round(e)?at(r,`Expected to be an integer (got ${e})`):Number.isSafeInteger(e)?!0:at(r,`Expected to be a safe integer (got ${e})`)}),hv=t=>Ct({test:(e,r)=>t.test(e)?!0:at(r,`Expected to match the pattern ${t.toString()} (got ${Mr(e)})`)}),Jde=()=>Ct({test:(t,e)=>t!==t.toLowerCase()?at(e,`Expected to be all-lowercase (got ${t})`):!0}),Wde=()=>Ct({test:(t,e)=>t!==t.toUpperCase()?at(e,`Expected to be all-uppercase (got ${t})`):!0}),zde=()=>Ct({test:(t,e)=>mU.test(t)?!0:at(e,`Expected to be a valid UUID v4 (got ${Mr(t)})`)}),Vde=()=>Ct({test:(t,e)=>uv.test(t)?!1:at(e,`Expected to be a valid ISO 8601 date string (got ${Mr(t)})`)}),_de=({alpha:t=!1})=>Ct({test:(e,r)=>(t?pU.test(e):dU.test(e))?!0:at(r,`Expected to be a valid hexadecimal color string (got ${Mr(e)})`)}),Xde=()=>Ct({test:(t,e)=>CU.test(t)?!0:at(e,`Expected to be a valid base 64 string (got ${Mr(t)})`)}),Zde=(t=yU())=>Ct({test:(e,r)=>{let i;try{i=JSON.parse(e)}catch(n){return at(r,`Expected to be a valid JSON string (got ${Mr(e)})`)}return t(i,r)}}),$de=t=>{let e=new Set(t);return Ct({test:(r,i)=>{let n=new Set(Object.keys(r)),s=[];for(let o of e)n.has(o)||s.push(o);return s.length>0?at(i,`Missing required ${GE(s.length,"property","properties")} ${s.map(o=>`"${o}"`).join(", ")}`):!0}})},eCe=t=>{let e=new Set(t);return Ct({test:(r,i)=>{let n=new Set(Object.keys(r)),s=[];for(let o of e)n.has(o)&&s.push(o);return s.length>0?at(i,`Forbidden ${GE(s.length,"property","properties")} ${s.map(o=>`"${o}"`).join(", ")}`):!0}})},tCe=t=>{let e=new Set(t);return Ct({test:(r,i)=>{let n=new Set(Object.keys(r)),s=[];for(let o of e)n.has(o)&&s.push(o);return s.length>1?at(i,`Mutually exclusive properties ${s.map(o=>`"${o}"`).join(", ")}`):!0}})};(function(t){t.Forbids="Forbids",t.Requires="Requires"})(Bl||(Bl={}));rCe={[Bl.Forbids]:{expect:!1,message:"forbids using"},[Bl.Requires]:{expect:!0,message:"requires using"}},pv=(t,e,r,{ignore:i=[]}={})=>{let n=new Set(i),s=new Set(r),o=rCe[e];return Ct({test:(a,l)=>{let c=new Set(Object.keys(a));if(!c.has(t)||n.has(a[t]))return!0;let u=[];for(let g of s)(c.has(g)&&!n.has(a[g]))!==o.expect&&u.push(g);return u.length>=1?at(l,`Property "${t}" ${o.message} ${GE(u.length,"property","properties")} ${u.map(g=>`"${g}"`).join(", ")}`):!0}})}});var Sh=E(($et,OU)=>{var mCe="2.0.0",ECe=256,ICe=Number.MAX_SAFE_INTEGER||9007199254740991,yCe=16;OU.exports={SEMVER_SPEC_VERSION:mCe,MAX_LENGTH:ECe,MAX_SAFE_INTEGER:ICe,MAX_SAFE_COMPONENT_LENGTH:yCe}});var xh=E((ett,KU)=>{var wCe=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...t)=>console.error("SEMVER",...t):()=>{};KU.exports=wCe});var Ql=E((iA,UU)=>{var{MAX_SAFE_COMPONENT_LENGTH:yv}=Sh(),BCe=xh();iA=UU.exports={};var QCe=iA.re=[],Je=iA.src=[],We=iA.t={},bCe=0,mt=(t,e,r)=>{let i=bCe++;BCe(i,e),We[t]=i,Je[i]=e,QCe[i]=new RegExp(e,r?"g":void 0)};mt("NUMERICIDENTIFIER","0|[1-9]\\d*");mt("NUMERICIDENTIFIERLOOSE","[0-9]+");mt("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*");mt("MAINVERSION",`(${Je[We.NUMERICIDENTIFIER]})\\.(${Je[We.NUMERICIDENTIFIER]})\\.(${Je[We.NUMERICIDENTIFIER]})`);mt("MAINVERSIONLOOSE",`(${Je[We.NUMERICIDENTIFIERLOOSE]})\\.(${Je[We.NUMERICIDENTIFIERLOOSE]})\\.(${Je[We.NUMERICIDENTIFIERLOOSE]})`);mt("PRERELEASEIDENTIFIER",`(?:${Je[We.NUMERICIDENTIFIER]}|${Je[We.NONNUMERICIDENTIFIER]})`);mt("PRERELEASEIDENTIFIERLOOSE",`(?:${Je[We.NUMERICIDENTIFIERLOOSE]}|${Je[We.NONNUMERICIDENTIFIER]})`);mt("PRERELEASE",`(?:-(${Je[We.PRERELEASEIDENTIFIER]}(?:\\.${Je[We.PRERELEASEIDENTIFIER]})*))`);mt("PRERELEASELOOSE",`(?:-?(${Je[We.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${Je[We.PRERELEASEIDENTIFIERLOOSE]})*))`);mt("BUILDIDENTIFIER","[0-9A-Za-z-]+");mt("BUILD",`(?:\\+(${Je[We.BUILDIDENTIFIER]}(?:\\.${Je[We.BUILDIDENTIFIER]})*))`);mt("FULLPLAIN",`v?${Je[We.MAINVERSION]}${Je[We.PRERELEASE]}?${Je[We.BUILD]}?`);mt("FULL",`^${Je[We.FULLPLAIN]}$`);mt("LOOSEPLAIN",`[v=\\s]*${Je[We.MAINVERSIONLOOSE]}${Je[We.PRERELEASELOOSE]}?${Je[We.BUILD]}?`);mt("LOOSE",`^${Je[We.LOOSEPLAIN]}$`);mt("GTLT","((?:<|>)?=?)");mt("XRANGEIDENTIFIERLOOSE",`${Je[We.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`);mt("XRANGEIDENTIFIER",`${Je[We.NUMERICIDENTIFIER]}|x|X|\\*`);mt("XRANGEPLAIN",`[v=\\s]*(${Je[We.XRANGEIDENTIFIER]})(?:\\.(${Je[We.XRANGEIDENTIFIER]})(?:\\.(${Je[We.XRANGEIDENTIFIER]})(?:${Je[We.PRERELEASE]})?${Je[We.BUILD]}?)?)?`);mt("XRANGEPLAINLOOSE",`[v=\\s]*(${Je[We.XRANGEIDENTIFIERLOOSE]})(?:\\.(${Je[We.XRANGEIDENTIFIERLOOSE]})(?:\\.(${Je[We.XRANGEIDENTIFIERLOOSE]})(?:${Je[We.PRERELEASELOOSE]})?${Je[We.BUILD]}?)?)?`);mt("XRANGE",`^${Je[We.GTLT]}\\s*${Je[We.XRANGEPLAIN]}$`);mt("XRANGELOOSE",`^${Je[We.GTLT]}\\s*${Je[We.XRANGEPLAINLOOSE]}$`);mt("COERCE",`(^|[^\\d])(\\d{1,${yv}})(?:\\.(\\d{1,${yv}}))?(?:\\.(\\d{1,${yv}}))?(?:$|[^\\d])`);mt("COERCERTL",Je[We.COERCE],!0);mt("LONETILDE","(?:~>?)");mt("TILDETRIM",`(\\s*)${Je[We.LONETILDE]}\\s+`,!0);iA.tildeTrimReplace="$1~";mt("TILDE",`^${Je[We.LONETILDE]}${Je[We.XRANGEPLAIN]}$`);mt("TILDELOOSE",`^${Je[We.LONETILDE]}${Je[We.XRANGEPLAINLOOSE]}$`);mt("LONECARET","(?:\\^)");mt("CARETTRIM",`(\\s*)${Je[We.LONECARET]}\\s+`,!0);iA.caretTrimReplace="$1^";mt("CARET",`^${Je[We.LONECARET]}${Je[We.XRANGEPLAIN]}$`);mt("CARETLOOSE",`^${Je[We.LONECARET]}${Je[We.XRANGEPLAINLOOSE]}$`);mt("COMPARATORLOOSE",`^${Je[We.GTLT]}\\s*(${Je[We.LOOSEPLAIN]})$|^$`);mt("COMPARATOR",`^${Je[We.GTLT]}\\s*(${Je[We.FULLPLAIN]})$|^$`);mt("COMPARATORTRIM",`(\\s*)${Je[We.GTLT]}\\s*(${Je[We.LOOSEPLAIN]}|${Je[We.XRANGEPLAIN]})`,!0);iA.comparatorTrimReplace="$1$2$3";mt("HYPHENRANGE",`^\\s*(${Je[We.XRANGEPLAIN]})\\s+-\\s+(${Je[We.XRANGEPLAIN]})\\s*$`);mt("HYPHENRANGELOOSE",`^\\s*(${Je[We.XRANGEPLAINLOOSE]})\\s+-\\s+(${Je[We.XRANGEPLAINLOOSE]})\\s*$`);mt("STAR","(<|>)?=?\\s*\\*");mt("GTE0","^\\s*>=\\s*0.0.0\\s*$");mt("GTE0PRE","^\\s*>=\\s*0.0.0-0\\s*$")});var kh=E((ttt,HU)=>{var vCe=["includePrerelease","loose","rtl"],SCe=t=>t?typeof t!="object"?{loose:!0}:vCe.filter(e=>t[e]).reduce((e,r)=>(e[r]=!0,e),{}):{};HU.exports=SCe});var zE=E((rtt,GU)=>{var jU=/^[0-9]+$/,YU=(t,e)=>{let r=jU.test(t),i=jU.test(e);return r&&i&&(t=+t,e=+e),t===e?0:r&&!i?-1:i&&!r?1:tYU(e,t);GU.exports={compareIdentifiers:YU,rcompareIdentifiers:xCe}});var bi=E((itt,qU)=>{var VE=xh(),{MAX_LENGTH:JU,MAX_SAFE_INTEGER:_E}=Sh(),{re:WU,t:zU}=Ql(),kCe=kh(),{compareIdentifiers:Ph}=zE(),_n=class{constructor(e,r){if(r=kCe(r),e instanceof _n){if(e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease)return e;e=e.version}else if(typeof e!="string")throw new TypeError(`Invalid Version: ${e}`);if(e.length>JU)throw new TypeError(`version is longer than ${JU} characters`);VE("SemVer",e,r),this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease;let i=e.trim().match(r.loose?WU[zU.LOOSE]:WU[zU.FULL]);if(!i)throw new TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+i[1],this.minor=+i[2],this.patch=+i[3],this.major>_E||this.major<0)throw new TypeError("Invalid major version");if(this.minor>_E||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>_E||this.patch<0)throw new TypeError("Invalid patch version");i[4]?this.prerelease=i[4].split(".").map(n=>{if(/^[0-9]+$/.test(n)){let s=+n;if(s>=0&&s<_E)return s}return n}):this.prerelease=[],this.build=i[5]?i[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(e){if(VE("SemVer.compare",this.version,this.options,e),!(e instanceof _n)){if(typeof e=="string"&&e===this.version)return 0;e=new _n(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof _n||(e=new _n(e,this.options)),Ph(this.major,e.major)||Ph(this.minor,e.minor)||Ph(this.patch,e.patch)}comparePre(e){if(e instanceof _n||(e=new _n(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;let r=0;do{let i=this.prerelease[r],n=e.prerelease[r];if(VE("prerelease compare",r,i,n),i===void 0&&n===void 0)return 0;if(n===void 0)return 1;if(i===void 0)return-1;if(i===n)continue;return Ph(i,n)}while(++r)}compareBuild(e){e instanceof _n||(e=new _n(e,this.options));let r=0;do{let i=this.build[r],n=e.build[r];if(VE("prerelease compare",r,i,n),i===void 0&&n===void 0)return 0;if(n===void 0)return 1;if(i===void 0)return-1;if(i===n)continue;return Ph(i,n)}while(++r)}inc(e,r){switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",r);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",r);break;case"prepatch":this.prerelease.length=0,this.inc("patch",r),this.inc("pre",r);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",r),this.inc("pre",r);break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{let i=this.prerelease.length;for(;--i>=0;)typeof this.prerelease[i]=="number"&&(this.prerelease[i]++,i=-2);i===-1&&this.prerelease.push(0)}r&&(this.prerelease[0]===r?isNaN(this.prerelease[1])&&(this.prerelease=[r,0]):this.prerelease=[r,0]);break;default:throw new Error(`invalid increment argument: ${e}`)}return this.format(),this.raw=this.version,this}};qU.exports=_n});var bl=E((ntt,VU)=>{var{MAX_LENGTH:PCe}=Sh(),{re:_U,t:XU}=Ql(),ZU=bi(),DCe=kh(),RCe=(t,e)=>{if(e=DCe(e),t instanceof ZU)return t;if(typeof t!="string"||t.length>PCe||!(e.loose?_U[XU.LOOSE]:_U[XU.FULL]).test(t))return null;try{return new ZU(t,e)}catch(i){return null}};VU.exports=RCe});var e2=E((stt,$U)=>{var FCe=bl(),NCe=(t,e)=>{let r=FCe(t,e);return r?r.version:null};$U.exports=NCe});var r2=E((ott,t2)=>{var LCe=bl(),TCe=(t,e)=>{let r=LCe(t.trim().replace(/^[=v]+/,""),e);return r?r.version:null};t2.exports=TCe});var n2=E((att,i2)=>{var MCe=bi(),OCe=(t,e,r,i)=>{typeof r=="string"&&(i=r,r=void 0);try{return new MCe(t,r).inc(e,i).version}catch(n){return null}};i2.exports=OCe});var Xn=E((Att,s2)=>{var o2=bi(),KCe=(t,e,r)=>new o2(t,r).compare(new o2(e,r));s2.exports=KCe});var XE=E((ltt,a2)=>{var UCe=Xn(),HCe=(t,e,r)=>UCe(t,e,r)===0;a2.exports=HCe});var c2=E((ctt,A2)=>{var l2=bl(),GCe=XE(),jCe=(t,e)=>{if(GCe(t,e))return null;{let r=l2(t),i=l2(e),n=r.prerelease.length||i.prerelease.length,s=n?"pre":"",o=n?"prerelease":"";for(let a in r)if((a==="major"||a==="minor"||a==="patch")&&r[a]!==i[a])return s+a;return o}};A2.exports=jCe});var g2=E((utt,u2)=>{var YCe=bi(),qCe=(t,e)=>new YCe(t,e).major;u2.exports=qCe});var h2=E((gtt,f2)=>{var JCe=bi(),WCe=(t,e)=>new JCe(t,e).minor;f2.exports=WCe});var d2=E((ftt,p2)=>{var zCe=bi(),VCe=(t,e)=>new zCe(t,e).patch;p2.exports=VCe});var m2=E((htt,C2)=>{var _Ce=bl(),XCe=(t,e)=>{let r=_Ce(t,e);return r&&r.prerelease.length?r.prerelease:null};C2.exports=XCe});var I2=E((ptt,E2)=>{var ZCe=Xn(),$Ce=(t,e,r)=>ZCe(e,t,r);E2.exports=$Ce});var w2=E((dtt,y2)=>{var eme=Xn(),tme=(t,e)=>eme(t,e,!0);y2.exports=tme});var ZE=E((Ctt,B2)=>{var Q2=bi(),rme=(t,e,r)=>{let i=new Q2(t,r),n=new Q2(e,r);return i.compare(n)||i.compareBuild(n)};B2.exports=rme});var v2=E((mtt,b2)=>{var ime=ZE(),nme=(t,e)=>t.sort((r,i)=>ime(r,i,e));b2.exports=nme});var x2=E((Ett,S2)=>{var sme=ZE(),ome=(t,e)=>t.sort((r,i)=>sme(i,r,e));S2.exports=ome});var Dh=E((Itt,k2)=>{var ame=Xn(),Ame=(t,e,r)=>ame(t,e,r)>0;k2.exports=Ame});var $E=E((ytt,P2)=>{var lme=Xn(),cme=(t,e,r)=>lme(t,e,r)<0;P2.exports=cme});var wv=E((wtt,D2)=>{var ume=Xn(),gme=(t,e,r)=>ume(t,e,r)!==0;D2.exports=gme});var eI=E((Btt,R2)=>{var fme=Xn(),hme=(t,e,r)=>fme(t,e,r)>=0;R2.exports=hme});var tI=E((Qtt,F2)=>{var pme=Xn(),dme=(t,e,r)=>pme(t,e,r)<=0;F2.exports=dme});var Bv=E((btt,N2)=>{var Cme=XE(),mme=wv(),Eme=Dh(),Ime=eI(),yme=$E(),wme=tI(),Bme=(t,e,r,i)=>{switch(e){case"===":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t===r;case"!==":return typeof t=="object"&&(t=t.version),typeof r=="object"&&(r=r.version),t!==r;case"":case"=":case"==":return Cme(t,r,i);case"!=":return mme(t,r,i);case">":return Eme(t,r,i);case">=":return Ime(t,r,i);case"<":return yme(t,r,i);case"<=":return wme(t,r,i);default:throw new TypeError(`Invalid operator: ${e}`)}};N2.exports=Bme});var T2=E((vtt,L2)=>{var Qme=bi(),bme=bl(),{re:rI,t:iI}=Ql(),vme=(t,e)=>{if(t instanceof Qme)return t;if(typeof t=="number"&&(t=String(t)),typeof t!="string")return null;e=e||{};let r=null;if(!e.rtl)r=t.match(rI[iI.COERCE]);else{let i;for(;(i=rI[iI.COERCERTL].exec(t))&&(!r||r.index+r[0].length!==t.length);)(!r||i.index+i[0].length!==r.index+r[0].length)&&(r=i),rI[iI.COERCERTL].lastIndex=i.index+i[1].length+i[2].length;rI[iI.COERCERTL].lastIndex=-1}return r===null?null:bme(`${r[2]}.${r[3]||"0"}.${r[4]||"0"}`,e)};L2.exports=vme});var O2=E((Stt,M2)=>{"use strict";M2.exports=function(t){t.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}});var Rh=E((xtt,K2)=>{"use strict";K2.exports=Pt;Pt.Node=vl;Pt.create=Pt;function Pt(t){var e=this;if(e instanceof Pt||(e=new Pt),e.tail=null,e.head=null,e.length=0,t&&typeof t.forEach=="function")t.forEach(function(n){e.push(n)});else if(arguments.length>0)for(var r=0,i=arguments.length;r1)r=e;else if(this.head)i=this.head.next,r=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var n=0;i!==null;n++)r=t(r,i.value,n),i=i.next;return r};Pt.prototype.reduceReverse=function(t,e){var r,i=this.tail;if(arguments.length>1)r=e;else if(this.tail)i=this.tail.prev,r=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var n=this.length-1;i!==null;n--)r=t(r,i.value,n),i=i.prev;return r};Pt.prototype.toArray=function(){for(var t=new Array(this.length),e=0,r=this.head;r!==null;e++)t[e]=r.value,r=r.next;return t};Pt.prototype.toArrayReverse=function(){for(var t=new Array(this.length),e=0,r=this.tail;r!==null;e++)t[e]=r.value,r=r.prev;return t};Pt.prototype.slice=function(t,e){e=e||this.length,e<0&&(e+=this.length),t=t||0,t<0&&(t+=this.length);var r=new Pt;if(ethis.length&&(e=this.length);for(var i=0,n=this.head;n!==null&&ithis.length&&(e=this.length);for(var i=this.length,n=this.tail;n!==null&&i>e;i--)n=n.prev;for(;n!==null&&i>t;i--,n=n.prev)r.push(n.value);return r};Pt.prototype.splice=function(t,e,...r){t>this.length&&(t=this.length-1),t<0&&(t=this.length+t);for(var i=0,n=this.head;n!==null&&i{"use strict";var Pme=Rh(),Sl=Symbol("max"),ra=Symbol("length"),uu=Symbol("lengthCalculator"),Fh=Symbol("allowStale"),xl=Symbol("maxAge"),ia=Symbol("dispose"),H2=Symbol("noDisposeOnSet"),si=Symbol("lruList"),ks=Symbol("cache"),G2=Symbol("updateAgeOnGet"),Qv=()=>1,j2=class{constructor(e){if(typeof e=="number"&&(e={max:e}),e||(e={}),e.max&&(typeof e.max!="number"||e.max<0))throw new TypeError("max must be a non-negative number");let r=this[Sl]=e.max||Infinity,i=e.length||Qv;if(this[uu]=typeof i!="function"?Qv:i,this[Fh]=e.stale||!1,e.maxAge&&typeof e.maxAge!="number")throw new TypeError("maxAge must be a number");this[xl]=e.maxAge||0,this[ia]=e.dispose,this[H2]=e.noDisposeOnSet||!1,this[G2]=e.updateAgeOnGet||!1,this.reset()}set max(e){if(typeof e!="number"||e<0)throw new TypeError("max must be a non-negative number");this[Sl]=e||Infinity,Nh(this)}get max(){return this[Sl]}set allowStale(e){this[Fh]=!!e}get allowStale(){return this[Fh]}set maxAge(e){if(typeof e!="number")throw new TypeError("maxAge must be a non-negative number");this[xl]=e,Nh(this)}get maxAge(){return this[xl]}set lengthCalculator(e){typeof e!="function"&&(e=Qv),e!==this[uu]&&(this[uu]=e,this[ra]=0,this[si].forEach(r=>{r.length=this[uu](r.value,r.key),this[ra]+=r.length})),Nh(this)}get lengthCalculator(){return this[uu]}get length(){return this[ra]}get itemCount(){return this[si].length}rforEach(e,r){r=r||this;for(let i=this[si].tail;i!==null;){let n=i.prev;q2(this,e,i,r),i=n}}forEach(e,r){r=r||this;for(let i=this[si].head;i!==null;){let n=i.next;q2(this,e,i,r),i=n}}keys(){return this[si].toArray().map(e=>e.key)}values(){return this[si].toArray().map(e=>e.value)}reset(){this[ia]&&this[si]&&this[si].length&&this[si].forEach(e=>this[ia](e.key,e.value)),this[ks]=new Map,this[si]=new Pme,this[ra]=0}dump(){return this[si].map(e=>nI(this,e)?!1:{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter(e=>e)}dumpLru(){return this[si]}set(e,r,i){if(i=i||this[xl],i&&typeof i!="number")throw new TypeError("maxAge must be a number");let n=i?Date.now():0,s=this[uu](r,e);if(this[ks].has(e)){if(s>this[Sl])return gu(this,this[ks].get(e)),!1;let l=this[ks].get(e).value;return this[ia]&&(this[H2]||this[ia](e,l.value)),l.now=n,l.maxAge=i,l.value=r,this[ra]+=s-l.length,l.length=s,this.get(e),Nh(this),!0}let o=new Y2(e,r,s,n,i);return o.length>this[Sl]?(this[ia]&&this[ia](e,r),!1):(this[ra]+=o.length,this[si].unshift(o),this[ks].set(e,this[si].head),Nh(this),!0)}has(e){if(!this[ks].has(e))return!1;let r=this[ks].get(e).value;return!nI(this,r)}get(e){return bv(this,e,!0)}peek(e){return bv(this,e,!1)}pop(){let e=this[si].tail;return e?(gu(this,e),e.value):null}del(e){gu(this,this[ks].get(e))}load(e){this.reset();let r=Date.now();for(let i=e.length-1;i>=0;i--){let n=e[i],s=n.e||0;if(s===0)this.set(n.k,n.v);else{let o=s-r;o>0&&this.set(n.k,n.v,o)}}}prune(){this[ks].forEach((e,r)=>bv(this,r,!1))}},bv=(t,e,r)=>{let i=t[ks].get(e);if(i){let n=i.value;if(nI(t,n)){if(gu(t,i),!t[Fh])return}else r&&(t[G2]&&(i.value.now=Date.now()),t[si].unshiftNode(i));return n.value}},nI=(t,e)=>{if(!e||!e.maxAge&&!t[xl])return!1;let r=Date.now()-e.now;return e.maxAge?r>e.maxAge:t[xl]&&r>t[xl]},Nh=t=>{if(t[ra]>t[Sl])for(let e=t[si].tail;t[ra]>t[Sl]&&e!==null;){let r=e.prev;gu(t,e),e=r}},gu=(t,e)=>{if(e){let r=e.value;t[ia]&&t[ia](r.key,r.value),t[ra]-=r.length,t[ks].delete(r.key),t[si].removeNode(e)}},Y2=class{constructor(e,r,i,n,s){this.key=e,this.value=r,this.length=i,this.now=n,this.maxAge=s||0}},q2=(t,e,r,i)=>{let n=r.value;nI(t,n)&&(gu(t,r),t[Fh]||(n=void 0)),n&&e.call(i,n.value,n.key,t)};U2.exports=j2});var Zn=E((Ptt,W2)=>{var fu=class{constructor(e,r){if(r=Dme(r),e instanceof fu)return e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease?e:new fu(e.raw,r);if(e instanceof vv)return this.raw=e.value,this.set=[[e]],this.format(),this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=e,this.set=e.split(/\s*\|\|\s*/).map(i=>this.parseRange(i.trim())).filter(i=>i.length),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${e}`);if(this.set.length>1){let i=this.set[0];if(this.set=this.set.filter(n=>!V2(n[0])),this.set.length===0)this.set=[i];else if(this.set.length>1){for(let n of this.set)if(n.length===1&&Tme(n[0])){this.set=[n];break}}}this.format()}format(){return this.range=this.set.map(e=>e.join(" ").trim()).join("||").trim(),this.range}toString(){return this.range}parseRange(e){e=e.trim();let i=`parseRange:${Object.keys(this.options).join(",")}:${e}`,n=z2.get(i);if(n)return n;let s=this.options.loose,o=s?vi[di.HYPHENRANGELOOSE]:vi[di.HYPHENRANGE];e=e.replace(o,Kme(this.options.includePrerelease)),Rr("hyphen replace",e),e=e.replace(vi[di.COMPARATORTRIM],Fme),Rr("comparator trim",e,vi[di.COMPARATORTRIM]),e=e.replace(vi[di.TILDETRIM],Nme),e=e.replace(vi[di.CARETTRIM],Lme),e=e.split(/\s+/).join(" ");let a=s?vi[di.COMPARATORLOOSE]:vi[di.COMPARATOR],l=e.split(" ").map(f=>Mme(f,this.options)).join(" ").split(/\s+/).map(f=>Ome(f,this.options)).filter(this.options.loose?f=>!!f.match(a):()=>!0).map(f=>new vv(f,this.options)),c=l.length,u=new Map;for(let f of l){if(V2(f))return[f];u.set(f.value,f)}u.size>1&&u.has("")&&u.delete("");let g=[...u.values()];return z2.set(i,g),g}intersects(e,r){if(!(e instanceof fu))throw new TypeError("a Range is required");return this.set.some(i=>_2(i,r)&&e.set.some(n=>_2(n,r)&&i.every(s=>n.every(o=>s.intersects(o,r)))))}test(e){if(!e)return!1;if(typeof e=="string")try{e=new Rme(e,this.options)}catch(r){return!1}for(let r=0;rt.value==="<0.0.0-0",Tme=t=>t.value==="",_2=(t,e)=>{let r=!0,i=t.slice(),n=i.pop();for(;r&&i.length;)r=i.every(s=>n.intersects(s,e)),n=i.pop();return r},Mme=(t,e)=>(Rr("comp",t,e),t=jme(t,e),Rr("caret",t),t=Gme(t,e),Rr("tildes",t),t=Yme(t,e),Rr("xrange",t),t=qme(t,e),Rr("stars",t),t),Ji=t=>!t||t.toLowerCase()==="x"||t==="*",Gme=(t,e)=>t.trim().split(/\s+/).map(r=>Jme(r,e)).join(" "),Jme=(t,e)=>{let r=e.loose?vi[di.TILDELOOSE]:vi[di.TILDE];return t.replace(r,(i,n,s,o,a)=>{Rr("tilde",t,i,n,s,o,a);let l;return Ji(n)?l="":Ji(s)?l=`>=${n}.0.0 <${+n+1}.0.0-0`:Ji(o)?l=`>=${n}.${s}.0 <${n}.${+s+1}.0-0`:a?(Rr("replaceTilde pr",a),l=`>=${n}.${s}.${o}-${a} <${n}.${+s+1}.0-0`):l=`>=${n}.${s}.${o} <${n}.${+s+1}.0-0`,Rr("tilde return",l),l})},jme=(t,e)=>t.trim().split(/\s+/).map(r=>Wme(r,e)).join(" "),Wme=(t,e)=>{Rr("caret",t,e);let r=e.loose?vi[di.CARETLOOSE]:vi[di.CARET],i=e.includePrerelease?"-0":"";return t.replace(r,(n,s,o,a,l)=>{Rr("caret",t,n,s,o,a,l);let c;return Ji(s)?c="":Ji(o)?c=`>=${s}.0.0${i} <${+s+1}.0.0-0`:Ji(a)?s==="0"?c=`>=${s}.${o}.0${i} <${s}.${+o+1}.0-0`:c=`>=${s}.${o}.0${i} <${+s+1}.0.0-0`:l?(Rr("replaceCaret pr",l),s==="0"?o==="0"?c=`>=${s}.${o}.${a}-${l} <${s}.${o}.${+a+1}-0`:c=`>=${s}.${o}.${a}-${l} <${s}.${+o+1}.0-0`:c=`>=${s}.${o}.${a}-${l} <${+s+1}.0.0-0`):(Rr("no pr"),s==="0"?o==="0"?c=`>=${s}.${o}.${a}${i} <${s}.${o}.${+a+1}-0`:c=`>=${s}.${o}.${a}${i} <${s}.${+o+1}.0-0`:c=`>=${s}.${o}.${a} <${+s+1}.0.0-0`),Rr("caret return",c),c})},Yme=(t,e)=>(Rr("replaceXRanges",t,e),t.split(/\s+/).map(r=>zme(r,e)).join(" ")),zme=(t,e)=>{t=t.trim();let r=e.loose?vi[di.XRANGELOOSE]:vi[di.XRANGE];return t.replace(r,(i,n,s,o,a,l)=>{Rr("xRange",t,i,n,s,o,a,l);let c=Ji(s),u=c||Ji(o),g=u||Ji(a),f=g;return n==="="&&f&&(n=""),l=e.includePrerelease?"-0":"",c?n===">"||n==="<"?i="<0.0.0-0":i="*":n&&f?(u&&(o=0),a=0,n===">"?(n=">=",u?(s=+s+1,o=0,a=0):(o=+o+1,a=0)):n==="<="&&(n="<",u?s=+s+1:o=+o+1),n==="<"&&(l="-0"),i=`${n+s}.${o}.${a}${l}`):u?i=`>=${s}.0.0${l} <${+s+1}.0.0-0`:g&&(i=`>=${s}.${o}.0${l} <${s}.${+o+1}.0-0`),Rr("xRange return",i),i})},qme=(t,e)=>(Rr("replaceStars",t,e),t.trim().replace(vi[di.STAR],"")),Ome=(t,e)=>(Rr("replaceGTE0",t,e),t.trim().replace(vi[e.includePrerelease?di.GTE0PRE:di.GTE0],"")),Kme=t=>(e,r,i,n,s,o,a,l,c,u,g,f,h)=>(Ji(i)?r="":Ji(n)?r=`>=${i}.0.0${t?"-0":""}`:Ji(s)?r=`>=${i}.${n}.0${t?"-0":""}`:o?r=`>=${r}`:r=`>=${r}${t?"-0":""}`,Ji(c)?l="":Ji(u)?l=`<${+c+1}.0.0-0`:Ji(g)?l=`<${c}.${+u+1}.0-0`:f?l=`<=${c}.${u}.${g}-${f}`:t?l=`<${c}.${u}.${+g+1}-0`:l=`<=${l}`,`${r} ${l}`.trim()),Ume=(t,e,r)=>{for(let i=0;i0){let n=t[i].semver;if(n.major===e.major&&n.minor===e.minor&&n.patch===e.patch)return!0}return!1}return!0}});var Lh=E((Dtt,X2)=>{var Th=Symbol("SemVer ANY"),Mh=class{static get ANY(){return Th}constructor(e,r){if(r=Vme(r),e instanceof Mh){if(e.loose===!!r.loose)return e;e=e.value}xv("comparator",e,r),this.options=r,this.loose=!!r.loose,this.parse(e),this.semver===Th?this.value="":this.value=this.operator+this.semver.version,xv("comp",this)}parse(e){let r=this.options.loose?Z2[$2.COMPARATORLOOSE]:Z2[$2.COMPARATOR],i=e.match(r);if(!i)throw new TypeError(`Invalid comparator: ${e}`);this.operator=i[1]!==void 0?i[1]:"",this.operator==="="&&(this.operator=""),i[2]?this.semver=new eH(i[2],this.options.loose):this.semver=Th}toString(){return this.value}test(e){if(xv("Comparator.test",e,this.options.loose),this.semver===Th||e===Th)return!0;if(typeof e=="string")try{e=new eH(e,this.options)}catch(r){return!1}return Sv(e,this.operator,this.semver,this.options)}intersects(e,r){if(!(e instanceof Mh))throw new TypeError("a Comparator is required");if((!r||typeof r!="object")&&(r={loose:!!r,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new tH(e.value,r).test(this.value);if(e.operator==="")return e.value===""?!0:new tH(this.value,r).test(e.semver);let i=(this.operator===">="||this.operator===">")&&(e.operator===">="||e.operator===">"),n=(this.operator==="<="||this.operator==="<")&&(e.operator==="<="||e.operator==="<"),s=this.semver.version===e.semver.version,o=(this.operator===">="||this.operator==="<=")&&(e.operator===">="||e.operator==="<="),a=Sv(this.semver,"<",e.semver,r)&&(this.operator===">="||this.operator===">")&&(e.operator==="<="||e.operator==="<"),l=Sv(this.semver,">",e.semver,r)&&(this.operator==="<="||this.operator==="<")&&(e.operator===">="||e.operator===">");return i||n||s&&o||a||l}};X2.exports=Mh;var Vme=kh(),{re:Z2,t:$2}=Ql(),Sv=Bv(),xv=xh(),eH=bi(),tH=Zn()});var Oh=E((Rtt,rH)=>{var _me=Zn(),Xme=(t,e,r)=>{try{e=new _me(e,r)}catch(i){return!1}return e.test(t)};rH.exports=Xme});var nH=E((Ftt,iH)=>{var Zme=Zn(),$me=(t,e)=>new Zme(t,e).set.map(r=>r.map(i=>i.value).join(" ").trim().split(" "));iH.exports=$me});var oH=E((Ntt,sH)=>{var eEe=bi(),tEe=Zn(),rEe=(t,e,r)=>{let i=null,n=null,s=null;try{s=new tEe(e,r)}catch(o){return null}return t.forEach(o=>{s.test(o)&&(!i||n.compare(o)===-1)&&(i=o,n=new eEe(i,r))}),i};sH.exports=rEe});var AH=E((Ltt,aH)=>{var iEe=bi(),nEe=Zn(),sEe=(t,e,r)=>{let i=null,n=null,s=null;try{s=new nEe(e,r)}catch(o){return null}return t.forEach(o=>{s.test(o)&&(!i||n.compare(o)===1)&&(i=o,n=new iEe(i,r))}),i};aH.exports=sEe});var uH=E((Ttt,lH)=>{var kv=bi(),oEe=Zn(),cH=Dh(),aEe=(t,e)=>{t=new oEe(t,e);let r=new kv("0.0.0");if(t.test(r)||(r=new kv("0.0.0-0"),t.test(r)))return r;r=null;for(let i=0;i{let a=new kv(o.semver.version);switch(o.operator){case">":a.prerelease.length===0?a.patch++:a.prerelease.push(0),a.raw=a.format();case"":case">=":(!s||cH(a,s))&&(s=a);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${o.operator}`)}}),s&&(!r||cH(r,s))&&(r=s)}return r&&t.test(r)?r:null};lH.exports=aEe});var fH=E((Mtt,gH)=>{var AEe=Zn(),lEe=(t,e)=>{try{return new AEe(t,e).range||"*"}catch(r){return null}};gH.exports=lEe});var sI=E((Ott,hH)=>{var cEe=bi(),pH=Lh(),{ANY:uEe}=pH,gEe=Zn(),fEe=Oh(),dH=Dh(),CH=$E(),hEe=tI(),pEe=eI(),dEe=(t,e,r,i)=>{t=new cEe(t,i),e=new gEe(e,i);let n,s,o,a,l;switch(r){case">":n=dH,s=hEe,o=CH,a=">",l=">=";break;case"<":n=CH,s=pEe,o=dH,a="<",l="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(fEe(t,e,i))return!1;for(let c=0;c{h.semver===uEe&&(h=new pH(">=0.0.0")),g=g||h,f=f||h,n(h.semver,g.semver,i)?g=h:o(h.semver,f.semver,i)&&(f=h)}),g.operator===a||g.operator===l||(!f.operator||f.operator===a)&&s(t,f.semver))return!1;if(f.operator===l&&o(t,f.semver))return!1}return!0};hH.exports=dEe});var EH=E((Ktt,mH)=>{var CEe=sI(),mEe=(t,e,r)=>CEe(t,e,">",r);mH.exports=mEe});var yH=E((Utt,IH)=>{var EEe=sI(),IEe=(t,e,r)=>EEe(t,e,"<",r);IH.exports=IEe});var QH=E((Htt,wH)=>{var BH=Zn(),yEe=(t,e,r)=>(t=new BH(t,r),e=new BH(e,r),t.intersects(e));wH.exports=yEe});var vH=E((Gtt,bH)=>{var wEe=Oh(),BEe=Xn();bH.exports=(t,e,r)=>{let i=[],n=null,s=null,o=t.sort((u,g)=>BEe(u,g,r));for(let u of o)wEe(u,e,r)?(s=u,n||(n=u)):(s&&i.push([n,s]),s=null,n=null);n&&i.push([n,null]);let a=[];for(let[u,g]of i)u===g?a.push(u):!g&&u===o[0]?a.push("*"):g?u===o[0]?a.push(`<=${g}`):a.push(`${u} - ${g}`):a.push(`>=${u}`);let l=a.join(" || "),c=typeof e.raw=="string"?e.raw:String(e);return l.length{var xH=Zn(),oI=Lh(),{ANY:Pv}=oI,Kh=Oh(),Dv=Xn(),bEe=(t,e,r={})=>{if(t===e)return!0;t=new xH(t,r),e=new xH(e,r);let i=!1;e:for(let n of t.set){for(let s of e.set){let o=QEe(n,s,r);if(i=i||o!==null,o)continue e}if(i)return!1}return!0},QEe=(t,e,r)=>{if(t===e)return!0;if(t.length===1&&t[0].semver===Pv){if(e.length===1&&e[0].semver===Pv)return!0;r.includePrerelease?t=[new oI(">=0.0.0-0")]:t=[new oI(">=0.0.0")]}if(e.length===1&&e[0].semver===Pv){if(r.includePrerelease)return!0;e=[new oI(">=0.0.0")]}let i=new Set,n,s;for(let h of t)h.operator===">"||h.operator===">="?n=kH(n,h,r):h.operator==="<"||h.operator==="<="?s=PH(s,h,r):i.add(h.semver);if(i.size>1)return null;let o;if(n&&s){if(o=Dv(n.semver,s.semver,r),o>0)return null;if(o===0&&(n.operator!==">="||s.operator!=="<="))return null}for(let h of i){if(n&&!Kh(h,String(n),r)||s&&!Kh(h,String(s),r))return null;for(let p of e)if(!Kh(h,String(p),r))return!1;return!0}let a,l,c,u,g=s&&!r.includePrerelease&&s.semver.prerelease.length?s.semver:!1,f=n&&!r.includePrerelease&&n.semver.prerelease.length?n.semver:!1;g&&g.prerelease.length===1&&s.operator==="<"&&g.prerelease[0]===0&&(g=!1);for(let h of e){if(u=u||h.operator===">"||h.operator===">=",c=c||h.operator==="<"||h.operator==="<=",n){if(f&&h.semver.prerelease&&h.semver.prerelease.length&&h.semver.major===f.major&&h.semver.minor===f.minor&&h.semver.patch===f.patch&&(f=!1),h.operator===">"||h.operator===">="){if(a=kH(n,h,r),a===h&&a!==n)return!1}else if(n.operator===">="&&!Kh(n.semver,String(h),r))return!1}if(s){if(g&&h.semver.prerelease&&h.semver.prerelease.length&&h.semver.major===g.major&&h.semver.minor===g.minor&&h.semver.patch===g.patch&&(g=!1),h.operator==="<"||h.operator==="<="){if(l=PH(s,h,r),l===h&&l!==s)return!1}else if(s.operator==="<="&&!Kh(s.semver,String(h),r))return!1}if(!h.operator&&(s||n)&&o!==0)return!1}return!(n&&c&&!s&&o!==0||s&&u&&!n&&o!==0||f||g)},kH=(t,e,r)=>{if(!t)return e;let i=Dv(t.semver,e.semver,r);return i>0?t:i<0||e.operator===">"&&t.operator===">="?e:t},PH=(t,e,r)=>{if(!t)return e;let i=Dv(t.semver,e.semver,r);return i<0?t:i>0||e.operator==="<"&&t.operator==="<="?e:t};SH.exports=bEe});var Or=E((Ytt,RH)=>{var Rv=Ql();RH.exports={re:Rv.re,src:Rv.src,tokens:Rv.t,SEMVER_SPEC_VERSION:Sh().SEMVER_SPEC_VERSION,SemVer:bi(),compareIdentifiers:zE().compareIdentifiers,rcompareIdentifiers:zE().rcompareIdentifiers,parse:bl(),valid:e2(),clean:r2(),inc:n2(),diff:c2(),major:g2(),minor:h2(),patch:d2(),prerelease:m2(),compare:Xn(),rcompare:I2(),compareLoose:w2(),compareBuild:ZE(),sort:v2(),rsort:x2(),gt:Dh(),lt:$E(),eq:XE(),neq:wv(),gte:eI(),lte:tI(),cmp:Bv(),coerce:T2(),Comparator:Lh(),Range:Zn(),satisfies:Oh(),toComparators:nH(),maxSatisfying:oH(),minSatisfying:AH(),minVersion:uH(),validRange:fH(),outside:sI(),gtr:EH(),ltr:yH(),intersects:QH(),simplifyRange:vH(),subset:DH()}});var Uv=E(AI=>{"use strict";Object.defineProperty(AI,"__esModule",{value:!0});AI.VERSION=void 0;AI.VERSION="9.1.0"});var Dt=E((exports,module)=>{"use strict";var __spreadArray=exports&&exports.__spreadArray||function(t,e,r){if(r||arguments.length===2)for(var i=0,n=e.length,s;i{(function(t,e){typeof define=="function"&&define.amd?define([],e):typeof lI=="object"&&lI.exports?lI.exports=e():t.regexpToAst=e()})(typeof self!="undefined"?self:YH,function(){function t(){}t.prototype.saveState=function(){return{idx:this.idx,input:this.input,groupIdx:this.groupIdx}},t.prototype.restoreState=function(p){this.idx=p.idx,this.input=p.input,this.groupIdx=p.groupIdx},t.prototype.pattern=function(p){this.idx=0,this.input=p,this.groupIdx=0,this.consumeChar("/");var d=this.disjunction();this.consumeChar("/");for(var m={type:"Flags",loc:{begin:this.idx,end:p.length},global:!1,ignoreCase:!1,multiLine:!1,unicode:!1,sticky:!1};this.isRegExpFlag();)switch(this.popChar()){case"g":o(m,"global");break;case"i":o(m,"ignoreCase");break;case"m":o(m,"multiLine");break;case"u":o(m,"unicode");break;case"y":o(m,"sticky");break}if(this.idx!==this.input.length)throw Error("Redundant input: "+this.input.substring(this.idx));return{type:"Pattern",flags:m,value:d,loc:this.loc(0)}},t.prototype.disjunction=function(){var p=[],d=this.idx;for(p.push(this.alternative());this.peekChar()==="|";)this.consumeChar("|"),p.push(this.alternative());return{type:"Disjunction",value:p,loc:this.loc(d)}},t.prototype.alternative=function(){for(var p=[],d=this.idx;this.isTerm();)p.push(this.term());return{type:"Alternative",value:p,loc:this.loc(d)}},t.prototype.term=function(){return this.isAssertion()?this.assertion():this.atom()},t.prototype.assertion=function(){var p=this.idx;switch(this.popChar()){case"^":return{type:"StartAnchor",loc:this.loc(p)};case"$":return{type:"EndAnchor",loc:this.loc(p)};case"\\":switch(this.popChar()){case"b":return{type:"WordBoundary",loc:this.loc(p)};case"B":return{type:"NonWordBoundary",loc:this.loc(p)}}throw Error("Invalid Assertion Escape");case"(":this.consumeChar("?");var d;switch(this.popChar()){case"=":d="Lookahead";break;case"!":d="NegativeLookahead";break}a(d);var m=this.disjunction();return this.consumeChar(")"),{type:d,value:m,loc:this.loc(p)}}l()},t.prototype.quantifier=function(p){var d,m=this.idx;switch(this.popChar()){case"*":d={atLeast:0,atMost:Infinity};break;case"+":d={atLeast:1,atMost:Infinity};break;case"?":d={atLeast:0,atMost:1};break;case"{":var I=this.integerIncludingZero();switch(this.popChar()){case"}":d={atLeast:I,atMost:I};break;case",":var B;this.isDigit()?(B=this.integerIncludingZero(),d={atLeast:I,atMost:B}):d={atLeast:I,atMost:Infinity},this.consumeChar("}");break}if(p===!0&&d===void 0)return;a(d);break}if(!(p===!0&&d===void 0))return a(d),this.peekChar(0)==="?"?(this.consumeChar("?"),d.greedy=!1):d.greedy=!0,d.type="Quantifier",d.loc=this.loc(m),d},t.prototype.atom=function(){var p,d=this.idx;switch(this.peekChar()){case".":p=this.dotAll();break;case"\\":p=this.atomEscape();break;case"[":p=this.characterClass();break;case"(":p=this.group();break}return p===void 0&&this.isPatternCharacter()&&(p=this.patternCharacter()),a(p),p.loc=this.loc(d),this.isQuantifier()&&(p.quantifier=this.quantifier()),p},t.prototype.dotAll=function(){return this.consumeChar("."),{type:"Set",complement:!0,value:[n(` -`),n("\r"),n("\u2028"),n("\u2029")]}},t.prototype.atomEscape=function(){switch(this.consumeChar("\\"),this.peekChar()){case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":return this.decimalEscapeAtom();case"d":case"D":case"s":case"S":case"w":case"W":return this.characterClassEscape();case"f":case"n":case"r":case"t":case"v":return this.controlEscapeAtom();case"c":return this.controlLetterEscapeAtom();case"0":return this.nulCharacterAtom();case"x":return this.hexEscapeSequenceAtom();case"u":return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}},t.prototype.decimalEscapeAtom=function(){var p=this.positiveInteger();return{type:"GroupBackReference",value:p}},t.prototype.characterClassEscape=function(){var p,d=!1;switch(this.popChar()){case"d":p=u;break;case"D":p=u,d=!0;break;case"s":p=f;break;case"S":p=f,d=!0;break;case"w":p=g;break;case"W":p=g,d=!0;break}return a(p),{type:"Set",value:p,complement:d}},t.prototype.controlEscapeAtom=function(){var p;switch(this.popChar()){case"f":p=n("\f");break;case"n":p=n(` -`);break;case"r":p=n("\r");break;case"t":p=n(" ");break;case"v":p=n("\v");break}return a(p),{type:"Character",value:p}},t.prototype.controlLetterEscapeAtom=function(){this.consumeChar("c");var p=this.popChar();if(/[a-zA-Z]/.test(p)===!1)throw Error("Invalid ");var d=p.toUpperCase().charCodeAt(0)-64;return{type:"Character",value:d}},t.prototype.nulCharacterAtom=function(){return this.consumeChar("0"),{type:"Character",value:n("\0")}},t.prototype.hexEscapeSequenceAtom=function(){return this.consumeChar("x"),this.parseHexDigits(2)},t.prototype.regExpUnicodeEscapeSequenceAtom=function(){return this.consumeChar("u"),this.parseHexDigits(4)},t.prototype.identityEscapeAtom=function(){var p=this.popChar();return{type:"Character",value:n(p)}},t.prototype.classPatternCharacterAtom=function(){switch(this.peekChar()){case` -`:case"\r":case"\u2028":case"\u2029":case"\\":case"]":throw Error("TBD");default:var p=this.popChar();return{type:"Character",value:n(p)}}},t.prototype.characterClass=function(){var p=[],d=!1;for(this.consumeChar("["),this.peekChar(0)==="^"&&(this.consumeChar("^"),d=!0);this.isClassAtom();){var m=this.classAtom(),I=m.type==="Character";if(I&&this.isRangeDash()){this.consumeChar("-");var B=this.classAtom(),b=B.type==="Character";if(b){if(B.value=this.input.length)throw Error("Unexpected end of input");this.idx++},t.prototype.loc=function(p){return{begin:p,end:this.idx}};var e=/[0-9a-fA-F]/,r=/[0-9]/,i=/[1-9]/;function n(p){return p.charCodeAt(0)}function s(p,d){p.length!==void 0?p.forEach(function(m){d.push(m)}):d.push(p)}function o(p,d){if(p[d]===!0)throw"duplicate flag "+d;p[d]=!0}function a(p){if(p===void 0)throw Error("Internal Error - Should never get here!")}function l(){throw Error("Internal Error - Should never get here!")}var c,u=[];for(c=n("0");c<=n("9");c++)u.push(c);var g=[n("_")].concat(u);for(c=n("a");c<=n("z");c++)g.push(c);for(c=n("A");c<=n("Z");c++)g.push(c);var f=[n(" "),n("\f"),n(` -`),n("\r"),n(" "),n("\v"),n(" "),n("\xA0"),n("\u1680"),n("\u2000"),n("\u2001"),n("\u2002"),n("\u2003"),n("\u2004"),n("\u2005"),n("\u2006"),n("\u2007"),n("\u2008"),n("\u2009"),n("\u200A"),n("\u2028"),n("\u2029"),n("\u202F"),n("\u205F"),n("\u3000"),n("\uFEFF")];function h(){}return h.prototype.visitChildren=function(p){for(var d in p){var m=p[d];p.hasOwnProperty(d)&&(m.type!==void 0?this.visit(m):Array.isArray(m)&&m.forEach(function(I){this.visit(I)},this))}},h.prototype.visit=function(p){switch(p.type){case"Pattern":this.visitPattern(p);break;case"Flags":this.visitFlags(p);break;case"Disjunction":this.visitDisjunction(p);break;case"Alternative":this.visitAlternative(p);break;case"StartAnchor":this.visitStartAnchor(p);break;case"EndAnchor":this.visitEndAnchor(p);break;case"WordBoundary":this.visitWordBoundary(p);break;case"NonWordBoundary":this.visitNonWordBoundary(p);break;case"Lookahead":this.visitLookahead(p);break;case"NegativeLookahead":this.visitNegativeLookahead(p);break;case"Character":this.visitCharacter(p);break;case"Set":this.visitSet(p);break;case"Group":this.visitGroup(p);break;case"GroupBackReference":this.visitGroupBackReference(p);break;case"Quantifier":this.visitQuantifier(p);break}this.visitChildren(p)},h.prototype.visitPattern=function(p){},h.prototype.visitFlags=function(p){},h.prototype.visitDisjunction=function(p){},h.prototype.visitAlternative=function(p){},h.prototype.visitStartAnchor=function(p){},h.prototype.visitEndAnchor=function(p){},h.prototype.visitWordBoundary=function(p){},h.prototype.visitNonWordBoundary=function(p){},h.prototype.visitLookahead=function(p){},h.prototype.visitNegativeLookahead=function(p){},h.prototype.visitCharacter=function(p){},h.prototype.visitSet=function(p){},h.prototype.visitGroup=function(p){},h.prototype.visitGroupBackReference=function(p){},h.prototype.visitQuantifier=function(p){},{RegExpParser:t,BaseRegExpVisitor:h,VERSION:"0.5.0"}})});var gI=E(Eu=>{"use strict";Object.defineProperty(Eu,"__esModule",{value:!0});Eu.clearRegExpParserCache=Eu.getRegExpAst=void 0;var FEe=cI(),uI={},NEe=new FEe.RegExpParser;function LEe(t){var e=t.toString();if(uI.hasOwnProperty(e))return uI[e];var r=NEe.pattern(e);return uI[e]=r,r}Eu.getRegExpAst=LEe;function TEe(){uI={}}Eu.clearRegExpParserCache=TEe});var VH=E(fn=>{"use strict";var MEe=fn&&fn.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(fn,"__esModule",{value:!0});fn.canMatchCharCode=fn.firstCharOptimizedIndices=fn.getOptimizedStartCodesIndices=fn.failedOptimizationPrefixMsg=void 0;var qH=cI(),$n=Dt(),JH=gI(),sa=Hv(),WH="Complement Sets are not supported for first char optimization";fn.failedOptimizationPrefixMsg=`Unable to use "first char" lexer optimizations: -`;function OEe(t,e){e===void 0&&(e=!1);try{var r=(0,JH.getRegExpAst)(t),i=fI(r.value,{},r.flags.ignoreCase);return i}catch(s){if(s.message===WH)e&&(0,$n.PRINT_WARNING)(""+fn.failedOptimizationPrefixMsg+(" Unable to optimize: < "+t.toString()+` > -`)+` Complement Sets cannot be automatically optimized. - This will disable the lexer's first char optimizations. - See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#COMPLEMENT for details.`);else{var n="";e&&(n=` - This will disable the lexer's first char optimizations. - See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#REGEXP_PARSING for details.`),(0,$n.PRINT_ERROR)(fn.failedOptimizationPrefixMsg+` -`+(" Failed parsing: < "+t.toString()+` > -`)+(" Using the regexp-to-ast library version: "+qH.VERSION+` -`)+" Please open an issue at: https://github.com/bd82/regexp-to-ast/issues"+n)}}return[]}fn.getOptimizedStartCodesIndices=OEe;function fI(t,e,r){switch(t.type){case"Disjunction":for(var i=0;i=sa.minOptimizationVal)for(var f=u.from>=sa.minOptimizationVal?u.from:sa.minOptimizationVal,h=u.to,p=(0,sa.charCodeToOptimizedIndex)(f),d=(0,sa.charCodeToOptimizedIndex)(h),m=p;m<=d;m++)e[m]=m}}});break;case"Group":fI(o.value,e,r);break;default:throw Error("Non Exhaustive Match")}var a=o.quantifier!==void 0&&o.quantifier.atLeast===0;if(o.type==="Group"&&Gv(o)===!1||o.type!=="Group"&&a===!1)break}break;default:throw Error("non exhaustive match!")}return(0,$n.values)(e)}fn.firstCharOptimizedIndices=fI;function hI(t,e,r){var i=(0,sa.charCodeToOptimizedIndex)(t);e[i]=i,r===!0&&KEe(t,e)}function KEe(t,e){var r=String.fromCharCode(t),i=r.toUpperCase();if(i!==r){var n=(0,sa.charCodeToOptimizedIndex)(i.charCodeAt(0));e[n]=n}else{var s=r.toLowerCase();if(s!==r){var n=(0,sa.charCodeToOptimizedIndex)(s.charCodeAt(0));e[n]=n}}}function zH(t,e){return(0,$n.find)(t.value,function(r){if(typeof r=="number")return(0,$n.contains)(e,r);var i=r;return(0,$n.find)(e,function(n){return i.from<=n&&n<=i.to})!==void 0})}function Gv(t){return t.quantifier&&t.quantifier.atLeast===0?!0:t.value?(0,$n.isArray)(t.value)?(0,$n.every)(t.value,Gv):Gv(t.value):!1}var UEe=function(t){MEe(e,t);function e(r){var i=t.call(this)||this;return i.targetCharCodes=r,i.found=!1,i}return e.prototype.visitChildren=function(r){if(this.found!==!0){switch(r.type){case"Lookahead":this.visitLookahead(r);return;case"NegativeLookahead":this.visitNegativeLookahead(r);return}t.prototype.visitChildren.call(this,r)}},e.prototype.visitCharacter=function(r){(0,$n.contains)(this.targetCharCodes,r.value)&&(this.found=!0)},e.prototype.visitSet=function(r){r.complement?zH(r,this.targetCharCodes)===void 0&&(this.found=!0):zH(r,this.targetCharCodes)!==void 0&&(this.found=!0)},e}(qH.BaseRegExpVisitor);function HEe(t,e){if(e instanceof RegExp){var r=(0,JH.getRegExpAst)(e),i=new UEe(t);return i.visit(r),i.found}else return(0,$n.find)(e,function(n){return(0,$n.contains)(t,n.charCodeAt(0))})!==void 0}fn.canMatchCharCode=HEe});var Hv=E(je=>{"use strict";var _H=je&&je.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(je,"__esModule",{value:!0});je.charCodeToOptimizedIndex=je.minOptimizationVal=je.buildLineBreakIssueMessage=je.LineTerminatorOptimizedTester=je.isShortPattern=je.isCustomPattern=je.cloneEmptyGroups=je.performWarningRuntimeChecks=je.performRuntimeChecks=je.addStickyFlag=je.addStartOfInput=je.findUnreachablePatterns=je.findModesThatDoNotExist=je.findInvalidGroupType=je.findDuplicatePatterns=je.findUnsupportedFlags=je.findStartOfInputAnchor=je.findEmptyMatchRegExps=je.findEndOfInputAnchor=je.findInvalidPatterns=je.findMissingPatterns=je.validatePatterns=je.analyzeTokenTypes=je.enableSticky=je.disableSticky=je.SUPPORT_STICKY=je.MODES=je.DEFAULT_MODE=void 0;var XH=cI(),zt=Gh(),Ie=Dt(),Iu=VH(),ZH=gI(),ao="PATTERN";je.DEFAULT_MODE="defaultMode";je.MODES="modes";je.SUPPORT_STICKY=typeof new RegExp("(?:)").sticky=="boolean";function GEe(){je.SUPPORT_STICKY=!1}je.disableSticky=GEe;function jEe(){je.SUPPORT_STICKY=!0}je.enableSticky=jEe;function qEe(t,e){e=(0,Ie.defaults)(e,{useSticky:je.SUPPORT_STICKY,debug:!1,safeMode:!1,positionTracking:"full",lineTerminatorCharacters:["\r",` -`],tracer:function(B,b){return b()}});var r=e.tracer;r("initCharCodeToOptimizedIndexMap",function(){YEe()});var i;r("Reject Lexer.NA",function(){i=(0,Ie.reject)(t,function(B){return B[ao]===zt.Lexer.NA})});var n=!1,s;r("Transform Patterns",function(){n=!1,s=(0,Ie.map)(i,function(B){var b=B[ao];if((0,Ie.isRegExp)(b)){var R=b.source;return R.length===1&&R!=="^"&&R!=="$"&&R!=="."&&!b.ignoreCase?R:R.length===2&&R[0]==="\\"&&!(0,Ie.contains)(["d","D","s","S","t","r","n","t","0","c","b","B","f","v","w","W"],R[1])?R[1]:e.useSticky?Yv(b):jv(b)}else{if((0,Ie.isFunction)(b))return n=!0,{exec:b};if((0,Ie.has)(b,"exec"))return n=!0,b;if(typeof b=="string"){if(b.length===1)return b;var H=b.replace(/[\\^$.*+?()[\]{}|]/g,"\\$&"),L=new RegExp(H);return e.useSticky?Yv(L):jv(L)}else throw Error("non exhaustive match")}})});var o,a,l,c,u;r("misc mapping",function(){o=(0,Ie.map)(i,function(B){return B.tokenTypeIdx}),a=(0,Ie.map)(i,function(B){var b=B.GROUP;if(b!==zt.Lexer.SKIPPED){if((0,Ie.isString)(b))return b;if((0,Ie.isUndefined)(b))return!1;throw Error("non exhaustive match")}}),l=(0,Ie.map)(i,function(B){var b=B.LONGER_ALT;if(b){var R=(0,Ie.isArray)(b)?(0,Ie.map)(b,function(H){return(0,Ie.indexOf)(i,H)}):[(0,Ie.indexOf)(i,b)];return R}}),c=(0,Ie.map)(i,function(B){return B.PUSH_MODE}),u=(0,Ie.map)(i,function(B){return(0,Ie.has)(B,"POP_MODE")})});var g;r("Line Terminator Handling",function(){var B=tG(e.lineTerminatorCharacters);g=(0,Ie.map)(i,function(b){return!1}),e.positionTracking!=="onlyOffset"&&(g=(0,Ie.map)(i,function(b){if((0,Ie.has)(b,"LINE_BREAKS"))return b.LINE_BREAKS;if(eG(b,B)===!1)return(0,Iu.canMatchCharCode)(B,b.PATTERN)}))});var f,h,p,d;r("Misc Mapping #2",function(){f=(0,Ie.map)(i,qv),h=(0,Ie.map)(s,$H),p=(0,Ie.reduce)(i,function(B,b){var R=b.GROUP;return(0,Ie.isString)(R)&&R!==zt.Lexer.SKIPPED&&(B[R]=[]),B},{}),d=(0,Ie.map)(s,function(B,b){return{pattern:s[b],longerAlt:l[b],canLineTerminator:g[b],isCustom:f[b],short:h[b],group:a[b],push:c[b],pop:u[b],tokenTypeIdx:o[b],tokenType:i[b]}})});var m=!0,I=[];return e.safeMode||r("First Char Optimization",function(){I=(0,Ie.reduce)(i,function(B,b,R){if(typeof b.PATTERN=="string"){var H=b.PATTERN.charCodeAt(0),L=Wv(H);Jv(B,L,d[R])}else if((0,Ie.isArray)(b.START_CHARS_HINT)){var K;(0,Ie.forEach)(b.START_CHARS_HINT,function(ne){var q=typeof ne=="string"?ne.charCodeAt(0):ne,A=Wv(q);K!==A&&(K=A,Jv(B,A,d[R]))})}else if((0,Ie.isRegExp)(b.PATTERN))if(b.PATTERN.unicode)m=!1,e.ensureOptimizations&&(0,Ie.PRINT_ERROR)(""+Iu.failedOptimizationPrefixMsg+(" Unable to analyze < "+b.PATTERN.toString()+` > pattern. -`)+` The regexp unicode flag is not currently supported by the regexp-to-ast library. - This will disable the lexer's first char optimizations. - For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNICODE_OPTIMIZE`);else{var J=(0,Iu.getOptimizedStartCodesIndices)(b.PATTERN,e.ensureOptimizations);(0,Ie.isEmpty)(J)&&(m=!1),(0,Ie.forEach)(J,function(ne){Jv(B,ne,d[R])})}else e.ensureOptimizations&&(0,Ie.PRINT_ERROR)(""+Iu.failedOptimizationPrefixMsg+(" TokenType: <"+b.name+`> is using a custom token pattern without providing parameter. -`)+` This will disable the lexer's first char optimizations. - For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_OPTIMIZE`),m=!1;return B},[])}),r("ArrayPacking",function(){I=(0,Ie.packArray)(I)}),{emptyGroups:p,patternIdxToConfig:d,charCodeToPatternIdxToConfig:I,hasCustom:n,canBeOptimized:m}}je.analyzeTokenTypes=qEe;function WEe(t,e){var r=[],i=rG(t);r=r.concat(i.errors);var n=iG(i.valid),s=n.valid;return r=r.concat(n.errors),r=r.concat(JEe(s)),r=r.concat(nG(s)),r=r.concat(sG(s,e)),r=r.concat(oG(s)),r}je.validatePatterns=WEe;function JEe(t){var e=[],r=(0,Ie.filter)(t,function(i){return(0,Ie.isRegExp)(i[ao])});return e=e.concat(aG(r)),e=e.concat(lG(r)),e=e.concat(cG(r)),e=e.concat(uG(r)),e=e.concat(AG(r)),e}function rG(t){var e=(0,Ie.filter)(t,function(n){return!(0,Ie.has)(n,ao)}),r=(0,Ie.map)(e,function(n){return{message:"Token Type: ->"+n.name+"<- missing static 'PATTERN' property",type:zt.LexerDefinitionErrorType.MISSING_PATTERN,tokenTypes:[n]}}),i=(0,Ie.difference)(t,e);return{errors:r,valid:i}}je.findMissingPatterns=rG;function iG(t){var e=(0,Ie.filter)(t,function(n){var s=n[ao];return!(0,Ie.isRegExp)(s)&&!(0,Ie.isFunction)(s)&&!(0,Ie.has)(s,"exec")&&!(0,Ie.isString)(s)}),r=(0,Ie.map)(e,function(n){return{message:"Token Type: ->"+n.name+"<- static 'PATTERN' can only be a RegExp, a Function matching the {CustomPatternMatcherFunc} type or an Object matching the {ICustomPattern} interface.",type:zt.LexerDefinitionErrorType.INVALID_PATTERN,tokenTypes:[n]}}),i=(0,Ie.difference)(t,e);return{errors:r,valid:i}}je.findInvalidPatterns=iG;var zEe=/[^\\][\$]/;function aG(t){var e=function(n){_H(s,n);function s(){var o=n!==null&&n.apply(this,arguments)||this;return o.found=!1,o}return s.prototype.visitEndAnchor=function(o){this.found=!0},s}(XH.BaseRegExpVisitor),r=(0,Ie.filter)(t,function(n){var s=n[ao];try{var o=(0,ZH.getRegExpAst)(s),a=new e;return a.visit(o),a.found}catch(l){return zEe.test(s.source)}}),i=(0,Ie.map)(r,function(n){return{message:`Unexpected RegExp Anchor Error: - Token Type: ->`+n.name+`<- static 'PATTERN' cannot contain end of input anchor '$' - See chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:zt.LexerDefinitionErrorType.EOI_ANCHOR_FOUND,tokenTypes:[n]}});return i}je.findEndOfInputAnchor=aG;function AG(t){var e=(0,Ie.filter)(t,function(i){var n=i[ao];return n.test("")}),r=(0,Ie.map)(e,function(i){return{message:"Token Type: ->"+i.name+"<- static 'PATTERN' must not match an empty string",type:zt.LexerDefinitionErrorType.EMPTY_MATCH_PATTERN,tokenTypes:[i]}});return r}je.findEmptyMatchRegExps=AG;var VEe=/[^\\[][\^]|^\^/;function lG(t){var e=function(n){_H(s,n);function s(){var o=n!==null&&n.apply(this,arguments)||this;return o.found=!1,o}return s.prototype.visitStartAnchor=function(o){this.found=!0},s}(XH.BaseRegExpVisitor),r=(0,Ie.filter)(t,function(n){var s=n[ao];try{var o=(0,ZH.getRegExpAst)(s),a=new e;return a.visit(o),a.found}catch(l){return VEe.test(s.source)}}),i=(0,Ie.map)(r,function(n){return{message:`Unexpected RegExp Anchor Error: - Token Type: ->`+n.name+`<- static 'PATTERN' cannot contain start of input anchor '^' - See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS for details.`,type:zt.LexerDefinitionErrorType.SOI_ANCHOR_FOUND,tokenTypes:[n]}});return i}je.findStartOfInputAnchor=lG;function cG(t){var e=(0,Ie.filter)(t,function(i){var n=i[ao];return n instanceof RegExp&&(n.multiline||n.global)}),r=(0,Ie.map)(e,function(i){return{message:"Token Type: ->"+i.name+"<- static 'PATTERN' may NOT contain global('g') or multiline('m')",type:zt.LexerDefinitionErrorType.UNSUPPORTED_FLAGS_FOUND,tokenTypes:[i]}});return r}je.findUnsupportedFlags=cG;function uG(t){var e=[],r=(0,Ie.map)(t,function(s){return(0,Ie.reduce)(t,function(o,a){return s.PATTERN.source===a.PATTERN.source&&!(0,Ie.contains)(e,a)&&a.PATTERN!==zt.Lexer.NA&&(e.push(a),o.push(a)),o},[])});r=(0,Ie.compact)(r);var i=(0,Ie.filter)(r,function(s){return s.length>1}),n=(0,Ie.map)(i,function(s){var o=(0,Ie.map)(s,function(l){return l.name}),a=(0,Ie.first)(s).PATTERN;return{message:"The same RegExp pattern ->"+a+"<-"+("has been used in all of the following Token Types: "+o.join(", ")+" <-"),type:zt.LexerDefinitionErrorType.DUPLICATE_PATTERNS_FOUND,tokenTypes:s}});return n}je.findDuplicatePatterns=uG;function nG(t){var e=(0,Ie.filter)(t,function(i){if(!(0,Ie.has)(i,"GROUP"))return!1;var n=i.GROUP;return n!==zt.Lexer.SKIPPED&&n!==zt.Lexer.NA&&!(0,Ie.isString)(n)}),r=(0,Ie.map)(e,function(i){return{message:"Token Type: ->"+i.name+"<- static 'GROUP' can only be Lexer.SKIPPED/Lexer.NA/A String",type:zt.LexerDefinitionErrorType.INVALID_GROUP_TYPE_FOUND,tokenTypes:[i]}});return r}je.findInvalidGroupType=nG;function sG(t,e){var r=(0,Ie.filter)(t,function(n){return n.PUSH_MODE!==void 0&&!(0,Ie.contains)(e,n.PUSH_MODE)}),i=(0,Ie.map)(r,function(n){var s="Token Type: ->"+n.name+"<- static 'PUSH_MODE' value cannot refer to a Lexer Mode ->"+n.PUSH_MODE+"<-which does not exist";return{message:s,type:zt.LexerDefinitionErrorType.PUSH_MODE_DOES_NOT_EXIST,tokenTypes:[n]}});return i}je.findModesThatDoNotExist=sG;function oG(t){var e=[],r=(0,Ie.reduce)(t,function(i,n,s){var o=n.PATTERN;return o===zt.Lexer.NA||((0,Ie.isString)(o)?i.push({str:o,idx:s,tokenType:n}):(0,Ie.isRegExp)(o)&&XEe(o)&&i.push({str:o.source,idx:s,tokenType:n})),i},[]);return(0,Ie.forEach)(t,function(i,n){(0,Ie.forEach)(r,function(s){var o=s.str,a=s.idx,l=s.tokenType;if(n"+i.name+"<-")+`in the lexer's definition. -See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNREACHABLE`;e.push({message:c,type:zt.LexerDefinitionErrorType.UNREACHABLE_PATTERN,tokenTypes:[i,l]})}})}),e}je.findUnreachablePatterns=oG;function _Ee(t,e){if((0,Ie.isRegExp)(e)){var r=e.exec(t);return r!==null&&r.index===0}else{if((0,Ie.isFunction)(e))return e(t,0,[],{});if((0,Ie.has)(e,"exec"))return e.exec(t,0,[],{});if(typeof e=="string")return e===t;throw Error("non exhaustive match")}}function XEe(t){var e=[".","\\","[","]","|","^","$","(",")","?","*","+","{"];return(0,Ie.find)(e,function(r){return t.source.indexOf(r)!==-1})===void 0}function jv(t){var e=t.ignoreCase?"i":"";return new RegExp("^(?:"+t.source+")",e)}je.addStartOfInput=jv;function Yv(t){var e=t.ignoreCase?"iy":"y";return new RegExp(""+t.source,e)}je.addStickyFlag=Yv;function ZEe(t,e,r){var i=[];return(0,Ie.has)(t,je.DEFAULT_MODE)||i.push({message:"A MultiMode Lexer cannot be initialized without a <"+je.DEFAULT_MODE+`> property in its definition -`,type:zt.LexerDefinitionErrorType.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE}),(0,Ie.has)(t,je.MODES)||i.push({message:"A MultiMode Lexer cannot be initialized without a <"+je.MODES+`> property in its definition -`,type:zt.LexerDefinitionErrorType.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY}),(0,Ie.has)(t,je.MODES)&&(0,Ie.has)(t,je.DEFAULT_MODE)&&!(0,Ie.has)(t.modes,t.defaultMode)&&i.push({message:"A MultiMode Lexer cannot be initialized with a "+je.DEFAULT_MODE+": <"+t.defaultMode+`>which does not exist -`,type:zt.LexerDefinitionErrorType.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST}),(0,Ie.has)(t,je.MODES)&&(0,Ie.forEach)(t.modes,function(n,s){(0,Ie.forEach)(n,function(o,a){(0,Ie.isUndefined)(o)&&i.push({message:"A Lexer cannot be initialized using an undefined Token Type. Mode:"+("<"+s+"> at index: <"+a+`> -`),type:zt.LexerDefinitionErrorType.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED})})}),i}je.performRuntimeChecks=ZEe;function $Ee(t,e,r){var i=[],n=!1,s=(0,Ie.compact)((0,Ie.flatten)((0,Ie.mapValues)(t.modes,function(l){return l}))),o=(0,Ie.reject)(s,function(l){return l[ao]===zt.Lexer.NA}),a=tG(r);return e&&(0,Ie.forEach)(o,function(l){var c=eG(l,a);if(c!==!1){var u=gG(l,c),g={message:u,type:c.issue,tokenType:l};i.push(g)}else(0,Ie.has)(l,"LINE_BREAKS")?l.LINE_BREAKS===!0&&(n=!0):(0,Iu.canMatchCharCode)(a,l.PATTERN)&&(n=!0)}),e&&!n&&i.push({message:`Warning: No LINE_BREAKS Found. - This Lexer has been defined to track line and column information, - But none of the Token Types can be identified as matching a line terminator. - See https://chevrotain.io/docs/guide/resolving_lexer_errors.html#LINE_BREAKS - for details.`,type:zt.LexerDefinitionErrorType.NO_LINE_BREAKS_FLAGS}),i}je.performWarningRuntimeChecks=$Ee;function eIe(t){var e={},r=(0,Ie.keys)(t);return(0,Ie.forEach)(r,function(i){var n=t[i];if((0,Ie.isArray)(n))e[i]=[];else throw Error("non exhaustive match")}),e}je.cloneEmptyGroups=eIe;function qv(t){var e=t.PATTERN;if((0,Ie.isRegExp)(e))return!1;if((0,Ie.isFunction)(e))return!0;if((0,Ie.has)(e,"exec"))return!0;if((0,Ie.isString)(e))return!1;throw Error("non exhaustive match")}je.isCustomPattern=qv;function $H(t){return(0,Ie.isString)(t)&&t.length===1?t.charCodeAt(0):!1}je.isShortPattern=$H;je.LineTerminatorOptimizedTester={test:function(t){for(var e=t.length,r=this.lastIndex;r Token Type -`)+(" Root cause: "+e.errMsg+`. -`)+" For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#IDENTIFY_TERMINATOR";if(e.issue===zt.LexerDefinitionErrorType.CUSTOM_LINE_BREAK)return`Warning: A Custom Token Pattern should specify the option. -`+(" The problem is in the <"+t.name+`> Token Type -`)+" For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_LINE_BREAK";throw Error("non exhaustive match")}je.buildLineBreakIssueMessage=gG;function tG(t){var e=(0,Ie.map)(t,function(r){return(0,Ie.isString)(r)&&r.length>0?r.charCodeAt(0):r});return e}function Jv(t,e,r){t[e]===void 0?t[e]=[r]:t[e].push(r)}je.minOptimizationVal=256;var pI=[];function Wv(t){return t255?255+~~(t/255):t}}});var yu=E(Bt=>{"use strict";Object.defineProperty(Bt,"__esModule",{value:!0});Bt.isTokenType=Bt.hasExtendingTokensTypesMapProperty=Bt.hasExtendingTokensTypesProperty=Bt.hasCategoriesProperty=Bt.hasShortKeyProperty=Bt.singleAssignCategoriesToksMap=Bt.assignCategoriesMapProp=Bt.assignCategoriesTokensProp=Bt.assignTokenDefaultProps=Bt.expandCategories=Bt.augmentTokenTypes=Bt.tokenIdxToClass=Bt.tokenShortNameIdx=Bt.tokenStructuredMatcherNoCategories=Bt.tokenStructuredMatcher=void 0;var Kr=Dt();function tIe(t,e){var r=t.tokenTypeIdx;return r===e.tokenTypeIdx?!0:e.isParent===!0&&e.categoryMatchesMap[r]===!0}Bt.tokenStructuredMatcher=tIe;function rIe(t,e){return t.tokenTypeIdx===e.tokenTypeIdx}Bt.tokenStructuredMatcherNoCategories=rIe;Bt.tokenShortNameIdx=1;Bt.tokenIdxToClass={};function iIe(t){var e=fG(t);hG(e),dG(e),pG(e),(0,Kr.forEach)(e,function(r){r.isParent=r.categoryMatches.length>0})}Bt.augmentTokenTypes=iIe;function fG(t){for(var e=(0,Kr.cloneArr)(t),r=t,i=!0;i;){r=(0,Kr.compact)((0,Kr.flatten)((0,Kr.map)(r,function(s){return s.CATEGORIES})));var n=(0,Kr.difference)(r,e);e=e.concat(n),(0,Kr.isEmpty)(n)?i=!1:r=n}return e}Bt.expandCategories=fG;function hG(t){(0,Kr.forEach)(t,function(e){CG(e)||(Bt.tokenIdxToClass[Bt.tokenShortNameIdx]=e,e.tokenTypeIdx=Bt.tokenShortNameIdx++),zv(e)&&!(0,Kr.isArray)(e.CATEGORIES)&&(e.CATEGORIES=[e.CATEGORIES]),zv(e)||(e.CATEGORIES=[]),mG(e)||(e.categoryMatches=[]),EG(e)||(e.categoryMatchesMap={})})}Bt.assignTokenDefaultProps=hG;function pG(t){(0,Kr.forEach)(t,function(e){e.categoryMatches=[],(0,Kr.forEach)(e.categoryMatchesMap,function(r,i){e.categoryMatches.push(Bt.tokenIdxToClass[i].tokenTypeIdx)})})}Bt.assignCategoriesTokensProp=pG;function dG(t){(0,Kr.forEach)(t,function(e){Vv([],e)})}Bt.assignCategoriesMapProp=dG;function Vv(t,e){(0,Kr.forEach)(t,function(r){e.categoryMatchesMap[r.tokenTypeIdx]=!0}),(0,Kr.forEach)(e.CATEGORIES,function(r){var i=t.concat(e);(0,Kr.contains)(i,r)||Vv(i,r)})}Bt.singleAssignCategoriesToksMap=Vv;function CG(t){return(0,Kr.has)(t,"tokenTypeIdx")}Bt.hasShortKeyProperty=CG;function zv(t){return(0,Kr.has)(t,"CATEGORIES")}Bt.hasCategoriesProperty=zv;function mG(t){return(0,Kr.has)(t,"categoryMatches")}Bt.hasExtendingTokensTypesProperty=mG;function EG(t){return(0,Kr.has)(t,"categoryMatchesMap")}Bt.hasExtendingTokensTypesMapProperty=EG;function nIe(t){return(0,Kr.has)(t,"tokenTypeIdx")}Bt.isTokenType=nIe});var _v=E(dI=>{"use strict";Object.defineProperty(dI,"__esModule",{value:!0});dI.defaultLexerErrorProvider=void 0;dI.defaultLexerErrorProvider={buildUnableToPopLexerModeMessage:function(t){return"Unable to pop Lexer Mode after encountering Token ->"+t.image+"<- The Mode Stack is empty"},buildUnexpectedCharactersMessage:function(t,e,r,i,n){return"unexpected character: ->"+t.charAt(e)+"<- at offset: "+e+","+(" skipped "+r+" characters.")}}});var Gh=E(Rl=>{"use strict";Object.defineProperty(Rl,"__esModule",{value:!0});Rl.Lexer=Rl.LexerDefinitionErrorType=void 0;var Ps=Hv(),Vt=Dt(),sIe=yu(),oIe=_v(),aIe=gI(),AIe;(function(t){t[t.MISSING_PATTERN=0]="MISSING_PATTERN",t[t.INVALID_PATTERN=1]="INVALID_PATTERN",t[t.EOI_ANCHOR_FOUND=2]="EOI_ANCHOR_FOUND",t[t.UNSUPPORTED_FLAGS_FOUND=3]="UNSUPPORTED_FLAGS_FOUND",t[t.DUPLICATE_PATTERNS_FOUND=4]="DUPLICATE_PATTERNS_FOUND",t[t.INVALID_GROUP_TYPE_FOUND=5]="INVALID_GROUP_TYPE_FOUND",t[t.PUSH_MODE_DOES_NOT_EXIST=6]="PUSH_MODE_DOES_NOT_EXIST",t[t.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE=7]="MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE",t[t.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY=8]="MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY",t[t.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST=9]="MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST",t[t.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED=10]="LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED",t[t.SOI_ANCHOR_FOUND=11]="SOI_ANCHOR_FOUND",t[t.EMPTY_MATCH_PATTERN=12]="EMPTY_MATCH_PATTERN",t[t.NO_LINE_BREAKS_FLAGS=13]="NO_LINE_BREAKS_FLAGS",t[t.UNREACHABLE_PATTERN=14]="UNREACHABLE_PATTERN",t[t.IDENTIFY_TERMINATOR=15]="IDENTIFY_TERMINATOR",t[t.CUSTOM_LINE_BREAK=16]="CUSTOM_LINE_BREAK"})(AIe=Rl.LexerDefinitionErrorType||(Rl.LexerDefinitionErrorType={}));var jh={deferDefinitionErrorsHandling:!1,positionTracking:"full",lineTerminatorsPattern:/\n|\r\n?/g,lineTerminatorCharacters:[` -`,"\r"],ensureOptimizations:!1,safeMode:!1,errorMessageProvider:oIe.defaultLexerErrorProvider,traceInitPerf:!1,skipValidations:!1};Object.freeze(jh);var lIe=function(){function t(e,r){var i=this;if(r===void 0&&(r=jh),this.lexerDefinition=e,this.lexerDefinitionErrors=[],this.lexerDefinitionWarning=[],this.patternIdxToConfig={},this.charCodeToPatternIdxToConfig={},this.modes=[],this.emptyGroups={},this.config=void 0,this.trackStartLines=!0,this.trackEndLines=!0,this.hasCustom=!1,this.canModeBeOptimized={},typeof r=="boolean")throw Error(`The second argument to the Lexer constructor is now an ILexerConfig Object. -a boolean 2nd argument is no longer supported`);this.config=(0,Vt.merge)(jh,r);var n=this.config.traceInitPerf;n===!0?(this.traceInitMaxIdent=Infinity,this.traceInitPerf=!0):typeof n=="number"&&(this.traceInitMaxIdent=n,this.traceInitPerf=!0),this.traceInitIndent=-1,this.TRACE_INIT("Lexer Constructor",function(){var s,o=!0;i.TRACE_INIT("Lexer Config handling",function(){if(i.config.lineTerminatorsPattern===jh.lineTerminatorsPattern)i.config.lineTerminatorsPattern=Ps.LineTerminatorOptimizedTester;else if(i.config.lineTerminatorCharacters===jh.lineTerminatorCharacters)throw Error(`Error: Missing property on the Lexer config. - For details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#MISSING_LINE_TERM_CHARS`);if(r.safeMode&&r.ensureOptimizations)throw Error('"safeMode" and "ensureOptimizations" flags are mutually exclusive.');i.trackStartLines=/full|onlyStart/i.test(i.config.positionTracking),i.trackEndLines=/full/i.test(i.config.positionTracking),(0,Vt.isArray)(e)?(s={modes:{}},s.modes[Ps.DEFAULT_MODE]=(0,Vt.cloneArr)(e),s[Ps.DEFAULT_MODE]=Ps.DEFAULT_MODE):(o=!1,s=(0,Vt.cloneObj)(e))}),i.config.skipValidations===!1&&(i.TRACE_INIT("performRuntimeChecks",function(){i.lexerDefinitionErrors=i.lexerDefinitionErrors.concat((0,Ps.performRuntimeChecks)(s,i.trackStartLines,i.config.lineTerminatorCharacters))}),i.TRACE_INIT("performWarningRuntimeChecks",function(){i.lexerDefinitionWarning=i.lexerDefinitionWarning.concat((0,Ps.performWarningRuntimeChecks)(s,i.trackStartLines,i.config.lineTerminatorCharacters))})),s.modes=s.modes?s.modes:{},(0,Vt.forEach)(s.modes,function(u,g){s.modes[g]=(0,Vt.reject)(u,function(f){return(0,Vt.isUndefined)(f)})});var a=(0,Vt.keys)(s.modes);if((0,Vt.forEach)(s.modes,function(u,g){i.TRACE_INIT("Mode: <"+g+"> processing",function(){if(i.modes.push(g),i.config.skipValidations===!1&&i.TRACE_INIT("validatePatterns",function(){i.lexerDefinitionErrors=i.lexerDefinitionErrors.concat((0,Ps.validatePatterns)(u,a))}),(0,Vt.isEmpty)(i.lexerDefinitionErrors)){(0,sIe.augmentTokenTypes)(u);var f;i.TRACE_INIT("analyzeTokenTypes",function(){f=(0,Ps.analyzeTokenTypes)(u,{lineTerminatorCharacters:i.config.lineTerminatorCharacters,positionTracking:r.positionTracking,ensureOptimizations:r.ensureOptimizations,safeMode:r.safeMode,tracer:i.TRACE_INIT.bind(i)})}),i.patternIdxToConfig[g]=f.patternIdxToConfig,i.charCodeToPatternIdxToConfig[g]=f.charCodeToPatternIdxToConfig,i.emptyGroups=(0,Vt.merge)(i.emptyGroups,f.emptyGroups),i.hasCustom=f.hasCustom||i.hasCustom,i.canModeBeOptimized[g]=f.canBeOptimized}})}),i.defaultMode=s.defaultMode,!(0,Vt.isEmpty)(i.lexerDefinitionErrors)&&!i.config.deferDefinitionErrorsHandling){var l=(0,Vt.map)(i.lexerDefinitionErrors,function(u){return u.message}),c=l.join(`----------------------- -`);throw new Error(`Errors detected in definition of Lexer: -`+c)}(0,Vt.forEach)(i.lexerDefinitionWarning,function(u){(0,Vt.PRINT_WARNING)(u.message)}),i.TRACE_INIT("Choosing sub-methods implementations",function(){if(Ps.SUPPORT_STICKY?(i.chopInput=Vt.IDENTITY,i.match=i.matchWithTest):(i.updateLastIndex=Vt.NOOP,i.match=i.matchWithExec),o&&(i.handleModes=Vt.NOOP),i.trackStartLines===!1&&(i.computeNewColumn=Vt.IDENTITY),i.trackEndLines===!1&&(i.updateTokenEndLineColumnLocation=Vt.NOOP),/full/i.test(i.config.positionTracking))i.createTokenInstance=i.createFullToken;else if(/onlyStart/i.test(i.config.positionTracking))i.createTokenInstance=i.createStartOnlyToken;else if(/onlyOffset/i.test(i.config.positionTracking))i.createTokenInstance=i.createOffsetOnlyToken;else throw Error('Invalid config option: "'+i.config.positionTracking+'"');i.hasCustom?(i.addToken=i.addTokenUsingPush,i.handlePayload=i.handlePayloadWithCustom):(i.addToken=i.addTokenUsingMemberAccess,i.handlePayload=i.handlePayloadNoCustom)}),i.TRACE_INIT("Failed Optimization Warnings",function(){var u=(0,Vt.reduce)(i.canModeBeOptimized,function(g,f,h){return f===!1&&g.push(h),g},[]);if(r.ensureOptimizations&&!(0,Vt.isEmpty)(u))throw Error("Lexer Modes: < "+u.join(", ")+` > cannot be optimized. - Disable the "ensureOptimizations" lexer config flag to silently ignore this and run the lexer in an un-optimized mode. - Or inspect the console log for details on how to resolve these issues.`)}),i.TRACE_INIT("clearRegExpParserCache",function(){(0,aIe.clearRegExpParserCache)()}),i.TRACE_INIT("toFastProperties",function(){(0,Vt.toFastProperties)(i)})})}return t.prototype.tokenize=function(e,r){if(r===void 0&&(r=this.defaultMode),!(0,Vt.isEmpty)(this.lexerDefinitionErrors)){var i=(0,Vt.map)(this.lexerDefinitionErrors,function(o){return o.message}),n=i.join(`----------------------- -`);throw new Error(`Unable to Tokenize because Errors detected in definition of Lexer: -`+n)}var s=this.tokenizeInternal(e,r);return s},t.prototype.tokenizeInternal=function(e,r){var i=this,n,s,o,a,l,c,u,g,f,h,p,d,m,I,B,b,R=e,H=R.length,L=0,K=0,J=this.hasCustom?0:Math.floor(e.length/10),ne=new Array(J),q=[],A=this.trackStartLines?1:void 0,V=this.trackStartLines?1:void 0,W=(0,Ps.cloneEmptyGroups)(this.emptyGroups),X=this.trackStartLines,F=this.config.lineTerminatorsPattern,D=0,he=[],pe=[],Ne=[],Pe=[];Object.freeze(Pe);var qe=void 0;function re(){return he}function se(wr){var Ui=(0,Ps.charCodeToOptimizedIndex)(wr),ws=pe[Ui];return ws===void 0?Pe:ws}var be=function(wr){if(Ne.length===1&&wr.tokenType.PUSH_MODE===void 0){var Ui=i.config.errorMessageProvider.buildUnableToPopLexerModeMessage(wr);q.push({offset:wr.startOffset,line:wr.startLine!==void 0?wr.startLine:void 0,column:wr.startColumn!==void 0?wr.startColumn:void 0,length:wr.image.length,message:Ui})}else{Ne.pop();var ws=(0,Vt.last)(Ne);he=i.patternIdxToConfig[ws],pe=i.charCodeToPatternIdxToConfig[ws],D=he.length;var Tf=i.canModeBeOptimized[ws]&&i.config.safeMode===!1;pe&&Tf?qe=se:qe=re}};function ae(wr){Ne.push(wr),pe=this.charCodeToPatternIdxToConfig[wr],he=this.patternIdxToConfig[wr],D=he.length,D=he.length;var Ui=this.canModeBeOptimized[wr]&&this.config.safeMode===!1;pe&&Ui?qe=se:qe=re}ae.call(this,r);for(var Ae;Lc.length){c=a,u=g,Ae=Oe;break}}}break}}if(c!==null){if(f=c.length,h=Ae.group,h!==void 0&&(p=Ae.tokenTypeIdx,d=this.createTokenInstance(c,L,p,Ae.tokenType,A,V,f),this.handlePayload(d,u),h===!1?K=this.addToken(ne,K,d):W[h].push(d)),e=this.chopInput(e,f),L=L+f,V=this.computeNewColumn(V,f),X===!0&&Ae.canLineTerminator===!0){var dt=0,ri=void 0,ii=void 0;F.lastIndex=0;do ri=F.test(c),ri===!0&&(ii=F.lastIndex-1,dt++);while(ri===!0);dt!==0&&(A=A+dt,V=f-ii,this.updateTokenEndLineColumnLocation(d,h,ii,dt,A,V,f))}this.handleModes(Ae,be,ae,d)}else{for(var an=L,yr=A,Ki=V,Qi=!1;!Qi&&L <"+e+">");var n=(0,Vt.timer)(r),s=n.time,o=n.value,a=s>10?console.warn:console.log;return this.traceInitIndent time: "+s+"ms"),this.traceInitIndent--,o}else return r()},t.SKIPPED="This marks a skipped Token pattern, this means each token identified by it willbe consumed and then thrown into oblivion, this can be used to for example to completely ignore whitespace.",t.NA=/NOT_APPLICABLE/,t}();Rl.Lexer=lIe});var nA=E(Ci=>{"use strict";Object.defineProperty(Ci,"__esModule",{value:!0});Ci.tokenMatcher=Ci.createTokenInstance=Ci.EOF=Ci.createToken=Ci.hasTokenLabel=Ci.tokenName=Ci.tokenLabel=void 0;var Ds=Dt(),cIe=Gh(),Xv=yu();function uIe(t){return IG(t)?t.LABEL:t.name}Ci.tokenLabel=uIe;function gIe(t){return t.name}Ci.tokenName=gIe;function IG(t){return(0,Ds.isString)(t.LABEL)&&t.LABEL!==""}Ci.hasTokenLabel=IG;var fIe="parent",yG="categories",wG="label",BG="group",QG="push_mode",bG="pop_mode",vG="longer_alt",SG="line_breaks",xG="start_chars_hint";function kG(t){return hIe(t)}Ci.createToken=kG;function hIe(t){var e=t.pattern,r={};if(r.name=t.name,(0,Ds.isUndefined)(e)||(r.PATTERN=e),(0,Ds.has)(t,fIe))throw`The parent property is no longer supported. -See: https://github.com/chevrotain/chevrotain/issues/564#issuecomment-349062346 for details.`;return(0,Ds.has)(t,yG)&&(r.CATEGORIES=t[yG]),(0,Xv.augmentTokenTypes)([r]),(0,Ds.has)(t,wG)&&(r.LABEL=t[wG]),(0,Ds.has)(t,BG)&&(r.GROUP=t[BG]),(0,Ds.has)(t,bG)&&(r.POP_MODE=t[bG]),(0,Ds.has)(t,QG)&&(r.PUSH_MODE=t[QG]),(0,Ds.has)(t,vG)&&(r.LONGER_ALT=t[vG]),(0,Ds.has)(t,SG)&&(r.LINE_BREAKS=t[SG]),(0,Ds.has)(t,xG)&&(r.START_CHARS_HINT=t[xG]),r}Ci.EOF=kG({name:"EOF",pattern:cIe.Lexer.NA});(0,Xv.augmentTokenTypes)([Ci.EOF]);function pIe(t,e,r,i,n,s,o,a){return{image:e,startOffset:r,endOffset:i,startLine:n,endLine:s,startColumn:o,endColumn:a,tokenTypeIdx:t.tokenTypeIdx,tokenType:t}}Ci.createTokenInstance=pIe;function dIe(t,e){return(0,Xv.tokenStructuredMatcher)(t,e)}Ci.tokenMatcher=dIe});var hn=E(Tt=>{"use strict";var oa=Tt&&Tt.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Tt,"__esModule",{value:!0});Tt.serializeProduction=Tt.serializeGrammar=Tt.Terminal=Tt.Alternation=Tt.RepetitionWithSeparator=Tt.Repetition=Tt.RepetitionMandatoryWithSeparator=Tt.RepetitionMandatory=Tt.Option=Tt.Alternative=Tt.Rule=Tt.NonTerminal=Tt.AbstractProduction=void 0;var $t=Dt(),CIe=nA(),Ao=function(){function t(e){this._definition=e}return Object.defineProperty(t.prototype,"definition",{get:function(){return this._definition},set:function(e){this._definition=e},enumerable:!1,configurable:!0}),t.prototype.accept=function(e){e.visit(this),(0,$t.forEach)(this.definition,function(r){r.accept(e)})},t}();Tt.AbstractProduction=Ao;var PG=function(t){oa(e,t);function e(r){var i=t.call(this,[])||this;return i.idx=1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return Object.defineProperty(e.prototype,"definition",{get:function(){return this.referencedRule!==void 0?this.referencedRule.definition:[]},set:function(r){},enumerable:!1,configurable:!0}),e.prototype.accept=function(r){r.visit(this)},e}(Ao);Tt.NonTerminal=PG;var DG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.orgText="",(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return e}(Ao);Tt.Rule=DG;var RG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.ignoreAmbiguities=!1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return e}(Ao);Tt.Alternative=RG;var FG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return e}(Ao);Tt.Option=FG;var NG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return e}(Ao);Tt.RepetitionMandatory=NG;var LG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return e}(Ao);Tt.RepetitionMandatoryWithSeparator=LG;var TG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return e}(Ao);Tt.Repetition=TG;var MG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return e}(Ao);Tt.RepetitionWithSeparator=MG;var OG=function(t){oa(e,t);function e(r){var i=t.call(this,r.definition)||this;return i.idx=1,i.ignoreAmbiguities=!1,i.hasPredicates=!1,(0,$t.assign)(i,(0,$t.pick)(r,function(n){return n!==void 0})),i}return Object.defineProperty(e.prototype,"definition",{get:function(){return this._definition},set:function(r){this._definition=r},enumerable:!1,configurable:!0}),e}(Ao);Tt.Alternation=OG;var CI=function(){function t(e){this.idx=1,(0,$t.assign)(this,(0,$t.pick)(e,function(r){return r!==void 0}))}return t.prototype.accept=function(e){e.visit(this)},t}();Tt.Terminal=CI;function mIe(t){return(0,$t.map)(t,Yh)}Tt.serializeGrammar=mIe;function Yh(t){function e(s){return(0,$t.map)(s,Yh)}if(t instanceof PG){var r={type:"NonTerminal",name:t.nonTerminalName,idx:t.idx};return(0,$t.isString)(t.label)&&(r.label=t.label),r}else{if(t instanceof RG)return{type:"Alternative",definition:e(t.definition)};if(t instanceof FG)return{type:"Option",idx:t.idx,definition:e(t.definition)};if(t instanceof NG)return{type:"RepetitionMandatory",idx:t.idx,definition:e(t.definition)};if(t instanceof LG)return{type:"RepetitionMandatoryWithSeparator",idx:t.idx,separator:Yh(new CI({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof MG)return{type:"RepetitionWithSeparator",idx:t.idx,separator:Yh(new CI({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof TG)return{type:"Repetition",idx:t.idx,definition:e(t.definition)};if(t instanceof OG)return{type:"Alternation",idx:t.idx,definition:e(t.definition)};if(t instanceof CI){var i={type:"Terminal",name:t.terminalType.name,label:(0,CIe.tokenLabel)(t.terminalType),idx:t.idx};(0,$t.isString)(t.label)&&(i.terminalLabel=t.label);var n=t.terminalType.PATTERN;return t.terminalType.PATTERN&&(i.pattern=(0,$t.isRegExp)(n)?n.source:n),i}else{if(t instanceof DG)return{type:"Rule",name:t.name,orgText:t.orgText,definition:e(t.definition)};throw Error("non exhaustive match")}}}Tt.serializeProduction=Yh});var EI=E(mI=>{"use strict";Object.defineProperty(mI,"__esModule",{value:!0});mI.RestWalker=void 0;var Zv=Dt(),pn=hn(),EIe=function(){function t(){}return t.prototype.walk=function(e,r){var i=this;r===void 0&&(r=[]),(0,Zv.forEach)(e.definition,function(n,s){var o=(0,Zv.drop)(e.definition,s+1);if(n instanceof pn.NonTerminal)i.walkProdRef(n,o,r);else if(n instanceof pn.Terminal)i.walkTerminal(n,o,r);else if(n instanceof pn.Alternative)i.walkFlat(n,o,r);else if(n instanceof pn.Option)i.walkOption(n,o,r);else if(n instanceof pn.RepetitionMandatory)i.walkAtLeastOne(n,o,r);else if(n instanceof pn.RepetitionMandatoryWithSeparator)i.walkAtLeastOneSep(n,o,r);else if(n instanceof pn.RepetitionWithSeparator)i.walkManySep(n,o,r);else if(n instanceof pn.Repetition)i.walkMany(n,o,r);else if(n instanceof pn.Alternation)i.walkOr(n,o,r);else throw Error("non exhaustive match")})},t.prototype.walkTerminal=function(e,r,i){},t.prototype.walkProdRef=function(e,r,i){},t.prototype.walkFlat=function(e,r,i){var n=r.concat(i);this.walk(e,n)},t.prototype.walkOption=function(e,r,i){var n=r.concat(i);this.walk(e,n)},t.prototype.walkAtLeastOne=function(e,r,i){var n=[new pn.Option({definition:e.definition})].concat(r,i);this.walk(e,n)},t.prototype.walkAtLeastOneSep=function(e,r,i){var n=KG(e,r,i);this.walk(e,n)},t.prototype.walkMany=function(e,r,i){var n=[new pn.Option({definition:e.definition})].concat(r,i);this.walk(e,n)},t.prototype.walkManySep=function(e,r,i){var n=KG(e,r,i);this.walk(e,n)},t.prototype.walkOr=function(e,r,i){var n=this,s=r.concat(i);(0,Zv.forEach)(e.definition,function(o){var a=new pn.Alternative({definition:[o]});n.walk(a,s)})},t}();mI.RestWalker=EIe;function KG(t,e,r){var i=[new pn.Option({definition:[new pn.Terminal({terminalType:t.separator})].concat(t.definition)})],n=i.concat(e,r);return n}});var wu=E(II=>{"use strict";Object.defineProperty(II,"__esModule",{value:!0});II.GAstVisitor=void 0;var lo=hn(),IIe=function(){function t(){}return t.prototype.visit=function(e){var r=e;switch(r.constructor){case lo.NonTerminal:return this.visitNonTerminal(r);case lo.Alternative:return this.visitAlternative(r);case lo.Option:return this.visitOption(r);case lo.RepetitionMandatory:return this.visitRepetitionMandatory(r);case lo.RepetitionMandatoryWithSeparator:return this.visitRepetitionMandatoryWithSeparator(r);case lo.RepetitionWithSeparator:return this.visitRepetitionWithSeparator(r);case lo.Repetition:return this.visitRepetition(r);case lo.Alternation:return this.visitAlternation(r);case lo.Terminal:return this.visitTerminal(r);case lo.Rule:return this.visitRule(r);default:throw Error("non exhaustive match")}},t.prototype.visitNonTerminal=function(e){},t.prototype.visitAlternative=function(e){},t.prototype.visitOption=function(e){},t.prototype.visitRepetition=function(e){},t.prototype.visitRepetitionMandatory=function(e){},t.prototype.visitRepetitionMandatoryWithSeparator=function(e){},t.prototype.visitRepetitionWithSeparator=function(e){},t.prototype.visitAlternation=function(e){},t.prototype.visitTerminal=function(e){},t.prototype.visitRule=function(e){},t}();II.GAstVisitor=IIe});var Jh=E(Si=>{"use strict";var yIe=Si&&Si.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Si,"__esModule",{value:!0});Si.collectMethods=Si.DslMethodsCollectorVisitor=Si.getProductionDslName=Si.isBranchingProd=Si.isOptionalProd=Si.isSequenceProd=void 0;var qh=Dt(),dr=hn(),wIe=wu();function BIe(t){return t instanceof dr.Alternative||t instanceof dr.Option||t instanceof dr.Repetition||t instanceof dr.RepetitionMandatory||t instanceof dr.RepetitionMandatoryWithSeparator||t instanceof dr.RepetitionWithSeparator||t instanceof dr.Terminal||t instanceof dr.Rule}Si.isSequenceProd=BIe;function $v(t,e){e===void 0&&(e=[]);var r=t instanceof dr.Option||t instanceof dr.Repetition||t instanceof dr.RepetitionWithSeparator;return r?!0:t instanceof dr.Alternation?(0,qh.some)(t.definition,function(i){return $v(i,e)}):t instanceof dr.NonTerminal&&(0,qh.contains)(e,t)?!1:t instanceof dr.AbstractProduction?(t instanceof dr.NonTerminal&&e.push(t),(0,qh.every)(t.definition,function(i){return $v(i,e)})):!1}Si.isOptionalProd=$v;function QIe(t){return t instanceof dr.Alternation}Si.isBranchingProd=QIe;function bIe(t){if(t instanceof dr.NonTerminal)return"SUBRULE";if(t instanceof dr.Option)return"OPTION";if(t instanceof dr.Alternation)return"OR";if(t instanceof dr.RepetitionMandatory)return"AT_LEAST_ONE";if(t instanceof dr.RepetitionMandatoryWithSeparator)return"AT_LEAST_ONE_SEP";if(t instanceof dr.RepetitionWithSeparator)return"MANY_SEP";if(t instanceof dr.Repetition)return"MANY";if(t instanceof dr.Terminal)return"CONSUME";throw Error("non exhaustive match")}Si.getProductionDslName=bIe;var UG=function(t){yIe(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.separator="-",r.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]},r}return e.prototype.reset=function(){this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}},e.prototype.visitTerminal=function(r){var i=r.terminalType.name+this.separator+"Terminal";(0,qh.has)(this.dslMethods,i)||(this.dslMethods[i]=[]),this.dslMethods[i].push(r)},e.prototype.visitNonTerminal=function(r){var i=r.nonTerminalName+this.separator+"Terminal";(0,qh.has)(this.dslMethods,i)||(this.dslMethods[i]=[]),this.dslMethods[i].push(r)},e.prototype.visitOption=function(r){this.dslMethods.option.push(r)},e.prototype.visitRepetitionWithSeparator=function(r){this.dslMethods.repetitionWithSeparator.push(r)},e.prototype.visitRepetitionMandatory=function(r){this.dslMethods.repetitionMandatory.push(r)},e.prototype.visitRepetitionMandatoryWithSeparator=function(r){this.dslMethods.repetitionMandatoryWithSeparator.push(r)},e.prototype.visitRepetition=function(r){this.dslMethods.repetition.push(r)},e.prototype.visitAlternation=function(r){this.dslMethods.alternation.push(r)},e}(wIe.GAstVisitor);Si.DslMethodsCollectorVisitor=UG;var yI=new UG;function vIe(t){yI.reset(),t.accept(yI);var e=yI.dslMethods;return yI.reset(),e}Si.collectMethods=vIe});var tS=E(co=>{"use strict";Object.defineProperty(co,"__esModule",{value:!0});co.firstForTerminal=co.firstForBranching=co.firstForSequence=co.first=void 0;var wI=Dt(),HG=hn(),eS=Jh();function BI(t){if(t instanceof HG.NonTerminal)return BI(t.referencedRule);if(t instanceof HG.Terminal)return YG(t);if((0,eS.isSequenceProd)(t))return GG(t);if((0,eS.isBranchingProd)(t))return jG(t);throw Error("non exhaustive match")}co.first=BI;function GG(t){for(var e=[],r=t.definition,i=0,n=r.length>i,s,o=!0;n&&o;)s=r[i],o=(0,eS.isOptionalProd)(s),e=e.concat(BI(s)),i=i+1,n=r.length>i;return(0,wI.uniq)(e)}co.firstForSequence=GG;function jG(t){var e=(0,wI.map)(t.definition,function(r){return BI(r)});return(0,wI.uniq)((0,wI.flatten)(e))}co.firstForBranching=jG;function YG(t){return[t.terminalType]}co.firstForTerminal=YG});var rS=E(QI=>{"use strict";Object.defineProperty(QI,"__esModule",{value:!0});QI.IN=void 0;QI.IN="_~IN~_"});var VG=E(es=>{"use strict";var SIe=es&&es.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(es,"__esModule",{value:!0});es.buildInProdFollowPrefix=es.buildBetweenProdsFollowPrefix=es.computeAllProdsFollows=es.ResyncFollowsWalker=void 0;var xIe=EI(),kIe=tS(),qG=Dt(),JG=rS(),PIe=hn(),zG=function(t){SIe(e,t);function e(r){var i=t.call(this)||this;return i.topProd=r,i.follows={},i}return e.prototype.startWalking=function(){return this.walk(this.topProd),this.follows},e.prototype.walkTerminal=function(r,i,n){},e.prototype.walkProdRef=function(r,i,n){var s=WG(r.referencedRule,r.idx)+this.topProd.name,o=i.concat(n),a=new PIe.Alternative({definition:o}),l=(0,kIe.first)(a);this.follows[s]=l},e}(xIe.RestWalker);es.ResyncFollowsWalker=zG;function DIe(t){var e={};return(0,qG.forEach)(t,function(r){var i=new zG(r).startWalking();(0,qG.assign)(e,i)}),e}es.computeAllProdsFollows=DIe;function WG(t,e){return t.name+e+JG.IN}es.buildBetweenProdsFollowPrefix=WG;function RIe(t){var e=t.terminalType.name;return e+t.idx+JG.IN}es.buildInProdFollowPrefix=RIe});var Wh=E(aa=>{"use strict";Object.defineProperty(aa,"__esModule",{value:!0});aa.defaultGrammarValidatorErrorProvider=aa.defaultGrammarResolverErrorProvider=aa.defaultParserErrorProvider=void 0;var Bu=nA(),FIe=Dt(),Rs=Dt(),iS=hn(),_G=Jh();aa.defaultParserErrorProvider={buildMismatchTokenMessage:function(t){var e=t.expected,r=t.actual,i=t.previous,n=t.ruleName,s=(0,Bu.hasTokenLabel)(e),o=s?"--> "+(0,Bu.tokenLabel)(e)+" <--":"token of type --> "+e.name+" <--",a="Expecting "+o+" but found --> '"+r.image+"' <--";return a},buildNotAllInputParsedMessage:function(t){var e=t.firstRedundant,r=t.ruleName;return"Redundant input, expecting EOF but found: "+e.image},buildNoViableAltMessage:function(t){var e=t.expectedPathsPerAlt,r=t.actual,i=t.previous,n=t.customUserDescription,s=t.ruleName,o="Expecting: ",a=(0,Rs.first)(r).image,l=` -but found: '`+a+"'";if(n)return o+n+l;var c=(0,Rs.reduce)(e,function(h,p){return h.concat(p)},[]),u=(0,Rs.map)(c,function(h){return"["+(0,Rs.map)(h,function(p){return(0,Bu.tokenLabel)(p)}).join(", ")+"]"}),g=(0,Rs.map)(u,function(h,p){return" "+(p+1)+". "+h}),f=`one of these possible Token sequences: -`+g.join(` -`);return o+f+l},buildEarlyExitMessage:function(t){var e=t.expectedIterationPaths,r=t.actual,i=t.customUserDescription,n=t.ruleName,s="Expecting: ",o=(0,Rs.first)(r).image,a=` -but found: '`+o+"'";if(i)return s+i+a;var l=(0,Rs.map)(e,function(u){return"["+(0,Rs.map)(u,function(g){return(0,Bu.tokenLabel)(g)}).join(",")+"]"}),c=`expecting at least one iteration which starts with one of these possible Token sequences:: - `+("<"+l.join(" ,")+">");return s+c+a}};Object.freeze(aa.defaultParserErrorProvider);aa.defaultGrammarResolverErrorProvider={buildRuleNotFoundError:function(t,e){var r="Invalid grammar, reference to a rule which is not defined: ->"+e.nonTerminalName+`<- -inside top level rule: ->`+t.name+"<-";return r}};aa.defaultGrammarValidatorErrorProvider={buildDuplicateFoundError:function(t,e){function r(u){return u instanceof iS.Terminal?u.terminalType.name:u instanceof iS.NonTerminal?u.nonTerminalName:""}var i=t.name,n=(0,Rs.first)(e),s=n.idx,o=(0,_G.getProductionDslName)(n),a=r(n),l=s>0,c="->"+o+(l?s:"")+"<- "+(a?"with argument: ->"+a+"<-":"")+` - appears more than once (`+e.length+" times) in the top level rule: ->"+i+`<-. - For further details see: https://chevrotain.io/docs/FAQ.html#NUMERICAL_SUFFIXES - `;return c=c.replace(/[ \t]+/g," "),c=c.replace(/\s\s+/g,` -`),c},buildNamespaceConflictError:function(t){var e=`Namespace conflict found in grammar. -`+("The grammar has both a Terminal(Token) and a Non-Terminal(Rule) named: <"+t.name+`>. -`)+`To resolve this make sure each Terminal and Non-Terminal names are unique -This is easy to accomplish by using the convention that Terminal names start with an uppercase letter -and Non-Terminal names start with a lower case letter.`;return e},buildAlternationPrefixAmbiguityError:function(t){var e=(0,Rs.map)(t.prefixPath,function(n){return(0,Bu.tokenLabel)(n)}).join(", "),r=t.alternation.idx===0?"":t.alternation.idx,i="Ambiguous alternatives: <"+t.ambiguityIndices.join(" ,")+`> due to common lookahead prefix -`+("in inside <"+t.topLevelRule.name+`> Rule, -`)+("<"+e+`> may appears as a prefix path in all these alternatives. -`)+`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#COMMON_PREFIX -For Further details.`;return i},buildAlternationAmbiguityError:function(t){var e=(0,Rs.map)(t.prefixPath,function(n){return(0,Bu.tokenLabel)(n)}).join(", "),r=t.alternation.idx===0?"":t.alternation.idx,i="Ambiguous Alternatives Detected: <"+t.ambiguityIndices.join(" ,")+"> in "+(" inside <"+t.topLevelRule.name+`> Rule, -`)+("<"+e+`> may appears as a prefix path in all these alternatives. -`);return i=i+`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES -For Further details.`,i},buildEmptyRepetitionError:function(t){var e=(0,_G.getProductionDslName)(t.repetition);t.repetition.idx!==0&&(e+=t.repetition.idx);var r="The repetition <"+e+"> within Rule <"+t.topLevelRule.name+`> can never consume any tokens. -This could lead to an infinite loop.`;return r},buildTokenNameError:function(t){return"deprecated"},buildEmptyAlternationError:function(t){var e="Ambiguous empty alternative: <"+(t.emptyChoiceIdx+1)+">"+(" in inside <"+t.topLevelRule.name+`> Rule. -`)+"Only the last alternative may be an empty alternative.";return e},buildTooManyAlternativesError:function(t){var e=`An Alternation cannot have more than 256 alternatives: -`+(" inside <"+t.topLevelRule.name+`> Rule. - has `+(t.alternation.definition.length+1)+" alternatives.");return e},buildLeftRecursionError:function(t){var e=t.topLevelRule.name,r=FIe.map(t.leftRecursionPath,function(s){return s.name}),i=e+" --> "+r.concat([e]).join(" --> "),n=`Left Recursion found in grammar. -`+("rule: <"+e+`> can be invoked from itself (directly or indirectly) -`)+(`without consuming any Tokens. The grammar path that causes this is: - `+i+` -`)+` To fix this refactor your grammar to remove the left recursion. -see: https://en.wikipedia.org/wiki/LL_parser#Left_Factoring.`;return n},buildInvalidRuleNameError:function(t){return"deprecated"},buildDuplicateRuleNameError:function(t){var e;t.topLevelRule instanceof iS.Rule?e=t.topLevelRule.name:e=t.topLevelRule;var r="Duplicate definition, rule: ->"+e+"<- is already defined in the grammar: ->"+t.grammarName+"<-";return r}}});var $G=E(sA=>{"use strict";var NIe=sA&&sA.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(sA,"__esModule",{value:!0});sA.GastRefResolverVisitor=sA.resolveGrammar=void 0;var LIe=Tn(),XG=Dt(),TIe=wu();function MIe(t,e){var r=new ZG(t,e);return r.resolveRefs(),r.errors}sA.resolveGrammar=MIe;var ZG=function(t){NIe(e,t);function e(r,i){var n=t.call(this)||this;return n.nameToTopRule=r,n.errMsgProvider=i,n.errors=[],n}return e.prototype.resolveRefs=function(){var r=this;(0,XG.forEach)((0,XG.values)(this.nameToTopRule),function(i){r.currTopLevel=i,i.accept(r)})},e.prototype.visitNonTerminal=function(r){var i=this.nameToTopRule[r.nonTerminalName];if(i)r.referencedRule=i;else{var n=this.errMsgProvider.buildRuleNotFoundError(this.currTopLevel,r);this.errors.push({message:n,type:LIe.ParserDefinitionErrorType.UNRESOLVED_SUBRULE_REF,ruleName:this.currTopLevel.name,unresolvedRefName:r.nonTerminalName})}},e}(TIe.GAstVisitor);sA.GastRefResolverVisitor=ZG});var Vh=E(Br=>{"use strict";var Fl=Br&&Br.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Br,"__esModule",{value:!0});Br.nextPossibleTokensAfter=Br.possiblePathsFrom=Br.NextTerminalAfterAtLeastOneSepWalker=Br.NextTerminalAfterAtLeastOneWalker=Br.NextTerminalAfterManySepWalker=Br.NextTerminalAfterManyWalker=Br.AbstractNextTerminalAfterProductionWalker=Br.NextAfterTokenWalker=Br.AbstractNextPossibleTokensWalker=void 0;var ej=EI(),xt=Dt(),OIe=tS(),It=hn(),tj=function(t){Fl(e,t);function e(r,i){var n=t.call(this)||this;return n.topProd=r,n.path=i,n.possibleTokTypes=[],n.nextProductionName="",n.nextProductionOccurrence=0,n.found=!1,n.isAtEndOfPath=!1,n}return e.prototype.startWalking=function(){if(this.found=!1,this.path.ruleStack[0]!==this.topProd.name)throw Error("The path does not start with the walker's top Rule!");return this.ruleStack=(0,xt.cloneArr)(this.path.ruleStack).reverse(),this.occurrenceStack=(0,xt.cloneArr)(this.path.occurrenceStack).reverse(),this.ruleStack.pop(),this.occurrenceStack.pop(),this.updateExpectedNext(),this.walk(this.topProd),this.possibleTokTypes},e.prototype.walk=function(r,i){i===void 0&&(i=[]),this.found||t.prototype.walk.call(this,r,i)},e.prototype.walkProdRef=function(r,i,n){if(r.referencedRule.name===this.nextProductionName&&r.idx===this.nextProductionOccurrence){var s=i.concat(n);this.updateExpectedNext(),this.walk(r.referencedRule,s)}},e.prototype.updateExpectedNext=function(){(0,xt.isEmpty)(this.ruleStack)?(this.nextProductionName="",this.nextProductionOccurrence=0,this.isAtEndOfPath=!0):(this.nextProductionName=this.ruleStack.pop(),this.nextProductionOccurrence=this.occurrenceStack.pop())},e}(ej.RestWalker);Br.AbstractNextPossibleTokensWalker=tj;var KIe=function(t){Fl(e,t);function e(r,i){var n=t.call(this,r,i)||this;return n.path=i,n.nextTerminalName="",n.nextTerminalOccurrence=0,n.nextTerminalName=n.path.lastTok.name,n.nextTerminalOccurrence=n.path.lastTokOccurrence,n}return e.prototype.walkTerminal=function(r,i,n){if(this.isAtEndOfPath&&r.terminalType.name===this.nextTerminalName&&r.idx===this.nextTerminalOccurrence&&!this.found){var s=i.concat(n),o=new It.Alternative({definition:s});this.possibleTokTypes=(0,OIe.first)(o),this.found=!0}},e}(tj);Br.NextAfterTokenWalker=KIe;var zh=function(t){Fl(e,t);function e(r,i){var n=t.call(this)||this;return n.topRule=r,n.occurrence=i,n.result={token:void 0,occurrence:void 0,isEndOfRule:void 0},n}return e.prototype.startWalking=function(){return this.walk(this.topRule),this.result},e}(ej.RestWalker);Br.AbstractNextTerminalAfterProductionWalker=zh;var UIe=function(t){Fl(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.walkMany=function(r,i,n){if(r.idx===this.occurrence){var s=(0,xt.first)(i.concat(n));this.result.isEndOfRule=s===void 0,s instanceof It.Terminal&&(this.result.token=s.terminalType,this.result.occurrence=s.idx)}else t.prototype.walkMany.call(this,r,i,n)},e}(zh);Br.NextTerminalAfterManyWalker=UIe;var HIe=function(t){Fl(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.walkManySep=function(r,i,n){if(r.idx===this.occurrence){var s=(0,xt.first)(i.concat(n));this.result.isEndOfRule=s===void 0,s instanceof It.Terminal&&(this.result.token=s.terminalType,this.result.occurrence=s.idx)}else t.prototype.walkManySep.call(this,r,i,n)},e}(zh);Br.NextTerminalAfterManySepWalker=HIe;var GIe=function(t){Fl(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.walkAtLeastOne=function(r,i,n){if(r.idx===this.occurrence){var s=(0,xt.first)(i.concat(n));this.result.isEndOfRule=s===void 0,s instanceof It.Terminal&&(this.result.token=s.terminalType,this.result.occurrence=s.idx)}else t.prototype.walkAtLeastOne.call(this,r,i,n)},e}(zh);Br.NextTerminalAfterAtLeastOneWalker=GIe;var jIe=function(t){Fl(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.prototype.walkAtLeastOneSep=function(r,i,n){if(r.idx===this.occurrence){var s=(0,xt.first)(i.concat(n));this.result.isEndOfRule=s===void 0,s instanceof It.Terminal&&(this.result.token=s.terminalType,this.result.occurrence=s.idx)}else t.prototype.walkAtLeastOneSep.call(this,r,i,n)},e}(zh);Br.NextTerminalAfterAtLeastOneSepWalker=jIe;function rj(t,e,r){r===void 0&&(r=[]),r=(0,xt.cloneArr)(r);var i=[],n=0;function s(c){return c.concat((0,xt.drop)(t,n+1))}function o(c){var u=rj(s(c),e,r);return i.concat(u)}for(;r.length=0;W--){var X=I.definition[W],F={idx:p,def:X.definition.concat((0,xt.drop)(h)),ruleStack:d,occurrenceStack:m};g.push(F),g.push(o)}else if(I instanceof It.Alternative)g.push({idx:p,def:I.definition.concat((0,xt.drop)(h)),ruleStack:d,occurrenceStack:m});else if(I instanceof It.Rule)g.push(YIe(I,p,d,m));else throw Error("non exhaustive match")}}return u}Br.nextPossibleTokensAfter=qIe;function YIe(t,e,r,i){var n=(0,xt.cloneArr)(r);n.push(t.name);var s=(0,xt.cloneArr)(i);return s.push(1),{idx:e,def:t.definition,ruleStack:n,occurrenceStack:s}}});var _h=E(Gt=>{"use strict";var ij=Gt&&Gt.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Gt,"__esModule",{value:!0});Gt.areTokenCategoriesNotUsed=Gt.isStrictPrefixOfPath=Gt.containsPath=Gt.getLookaheadPathsForOptionalProd=Gt.getLookaheadPathsForOr=Gt.lookAheadSequenceFromAlternatives=Gt.buildSingleAlternativeLookaheadFunction=Gt.buildAlternativesLookAheadFunc=Gt.buildLookaheadFuncForOptionalProd=Gt.buildLookaheadFuncForOr=Gt.getProdType=Gt.PROD_TYPE=void 0;var _t=Dt(),nj=Vh(),JIe=EI(),bI=yu(),oA=hn(),WIe=wu(),zr;(function(t){t[t.OPTION=0]="OPTION",t[t.REPETITION=1]="REPETITION",t[t.REPETITION_MANDATORY=2]="REPETITION_MANDATORY",t[t.REPETITION_MANDATORY_WITH_SEPARATOR=3]="REPETITION_MANDATORY_WITH_SEPARATOR",t[t.REPETITION_WITH_SEPARATOR=4]="REPETITION_WITH_SEPARATOR",t[t.ALTERNATION=5]="ALTERNATION"})(zr=Gt.PROD_TYPE||(Gt.PROD_TYPE={}));function zIe(t){if(t instanceof oA.Option)return zr.OPTION;if(t instanceof oA.Repetition)return zr.REPETITION;if(t instanceof oA.RepetitionMandatory)return zr.REPETITION_MANDATORY;if(t instanceof oA.RepetitionMandatoryWithSeparator)return zr.REPETITION_MANDATORY_WITH_SEPARATOR;if(t instanceof oA.RepetitionWithSeparator)return zr.REPETITION_WITH_SEPARATOR;if(t instanceof oA.Alternation)return zr.ALTERNATION;throw Error("non exhaustive match")}Gt.getProdType=zIe;function VIe(t,e,r,i,n,s){var o=sj(t,e,r),a=nS(o)?bI.tokenStructuredMatcherNoCategories:bI.tokenStructuredMatcher;return s(o,i,a,n)}Gt.buildLookaheadFuncForOr=VIe;function _Ie(t,e,r,i,n,s){var o=oj(t,e,n,r),a=nS(o)?bI.tokenStructuredMatcherNoCategories:bI.tokenStructuredMatcher;return s(o[0],a,i)}Gt.buildLookaheadFuncForOptionalProd=_Ie;function XIe(t,e,r,i){var n=t.length,s=(0,_t.every)(t,function(l){return(0,_t.every)(l,function(c){return c.length===1})});if(e)return function(l){for(var c=(0,_t.map)(l,function(b){return b.GATE}),u=0;u{"use strict";var aS=Mt&&Mt.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(Mt,"__esModule",{value:!0});Mt.checkPrefixAlternativesAmbiguities=Mt.validateSomeNonEmptyLookaheadPath=Mt.validateTooManyAlts=Mt.RepetionCollector=Mt.validateAmbiguousAlternationAlternatives=Mt.validateEmptyOrAlternative=Mt.getFirstNoneTerminal=Mt.validateNoLeftRecursion=Mt.validateRuleIsOverridden=Mt.validateRuleDoesNotAlreadyExist=Mt.OccurrenceValidationCollector=Mt.identifyProductionForDuplicates=Mt.validateGrammar=void 0;var jt=Dt(),Cr=Dt(),uo=Tn(),AS=Jh(),Qu=_h(),rye=Vh(),Fs=hn(),lS=wu();function sye(t,e,r,i,n){var s=jt.map(t,function(h){return iye(h,i)}),o=jt.map(t,function(h){return cS(h,h,i)}),a=[],l=[],c=[];(0,Cr.every)(o,Cr.isEmpty)&&(a=(0,Cr.map)(t,function(h){return uj(h,i)}),l=(0,Cr.map)(t,function(h){return gj(h,e,i)}),c=hj(t,e,i));var u=nye(t,r,i),g=(0,Cr.map)(t,function(h){return fj(h,i)}),f=(0,Cr.map)(t,function(h){return cj(h,t,n,i)});return jt.flatten(s.concat(c,o,a,l,u,g,f))}Mt.validateGrammar=sye;function iye(t,e){var r=new Cj;t.accept(r);var i=r.allProductions,n=jt.groupBy(i,pj),s=jt.pick(n,function(a){return a.length>1}),o=jt.map(jt.values(s),function(a){var l=jt.first(a),c=e.buildDuplicateFoundError(t,a),u=(0,AS.getProductionDslName)(l),g={message:c,type:uo.ParserDefinitionErrorType.DUPLICATE_PRODUCTIONS,ruleName:t.name,dslName:u,occurrence:l.idx},f=dj(l);return f&&(g.parameter=f),g});return o}function pj(t){return(0,AS.getProductionDslName)(t)+"_#_"+t.idx+"_#_"+dj(t)}Mt.identifyProductionForDuplicates=pj;function dj(t){return t instanceof Fs.Terminal?t.terminalType.name:t instanceof Fs.NonTerminal?t.nonTerminalName:""}var Cj=function(t){aS(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.allProductions=[],r}return e.prototype.visitNonTerminal=function(r){this.allProductions.push(r)},e.prototype.visitOption=function(r){this.allProductions.push(r)},e.prototype.visitRepetitionWithSeparator=function(r){this.allProductions.push(r)},e.prototype.visitRepetitionMandatory=function(r){this.allProductions.push(r)},e.prototype.visitRepetitionMandatoryWithSeparator=function(r){this.allProductions.push(r)},e.prototype.visitRepetition=function(r){this.allProductions.push(r)},e.prototype.visitAlternation=function(r){this.allProductions.push(r)},e.prototype.visitTerminal=function(r){this.allProductions.push(r)},e}(lS.GAstVisitor);Mt.OccurrenceValidationCollector=Cj;function cj(t,e,r,i){var n=[],s=(0,Cr.reduce)(e,function(a,l){return l.name===t.name?a+1:a},0);if(s>1){var o=i.buildDuplicateRuleNameError({topLevelRule:t,grammarName:r});n.push({message:o,type:uo.ParserDefinitionErrorType.DUPLICATE_RULE_NAME,ruleName:t.name})}return n}Mt.validateRuleDoesNotAlreadyExist=cj;function oye(t,e,r){var i=[],n;return jt.contains(e,t)||(n="Invalid rule override, rule: ->"+t+"<- cannot be overridden in the grammar: ->"+r+"<-as it is not defined in any of the super grammars ",i.push({message:n,type:uo.ParserDefinitionErrorType.INVALID_RULE_OVERRIDE,ruleName:t})),i}Mt.validateRuleIsOverridden=oye;function cS(t,e,r,i){i===void 0&&(i=[]);var n=[],s=Xh(e.definition);if(jt.isEmpty(s))return[];var o=t.name,a=jt.contains(s,t);a&&n.push({message:r.buildLeftRecursionError({topLevelRule:t,leftRecursionPath:i}),type:uo.ParserDefinitionErrorType.LEFT_RECURSION,ruleName:o});var l=jt.difference(s,i.concat([t])),c=jt.map(l,function(u){var g=jt.cloneArr(i);return g.push(u),cS(t,u,r,g)});return n.concat(jt.flatten(c))}Mt.validateNoLeftRecursion=cS;function Xh(t){var e=[];if(jt.isEmpty(t))return e;var r=jt.first(t);if(r instanceof Fs.NonTerminal)e.push(r.referencedRule);else if(r instanceof Fs.Alternative||r instanceof Fs.Option||r instanceof Fs.RepetitionMandatory||r instanceof Fs.RepetitionMandatoryWithSeparator||r instanceof Fs.RepetitionWithSeparator||r instanceof Fs.Repetition)e=e.concat(Xh(r.definition));else if(r instanceof Fs.Alternation)e=jt.flatten(jt.map(r.definition,function(o){return Xh(o.definition)}));else if(!(r instanceof Fs.Terminal))throw Error("non exhaustive match");var i=(0,AS.isOptionalProd)(r),n=t.length>1;if(i&&n){var s=jt.drop(t);return e.concat(Xh(s))}else return e}Mt.getFirstNoneTerminal=Xh;var uS=function(t){aS(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.alternations=[],r}return e.prototype.visitAlternation=function(r){this.alternations.push(r)},e}(lS.GAstVisitor);function uj(t,e){var r=new uS;t.accept(r);var i=r.alternations,n=jt.reduce(i,function(s,o){var a=jt.dropRight(o.definition),l=jt.map(a,function(c,u){var g=(0,rye.nextPossibleTokensAfter)([c],[],null,1);return jt.isEmpty(g)?{message:e.buildEmptyAlternationError({topLevelRule:t,alternation:o,emptyChoiceIdx:u}),type:uo.ParserDefinitionErrorType.NONE_LAST_EMPTY_ALT,ruleName:t.name,occurrence:o.idx,alternative:u+1}:null});return s.concat(jt.compact(l))},[]);return n}Mt.validateEmptyOrAlternative=uj;function gj(t,e,r){var i=new uS;t.accept(i);var n=i.alternations;n=(0,Cr.reject)(n,function(o){return o.ignoreAmbiguities===!0});var s=jt.reduce(n,function(o,a){var l=a.idx,c=a.maxLookahead||e,u=(0,Qu.getLookaheadPathsForOr)(l,t,c,a),g=aye(u,a,t,r),f=mj(u,a,t,r);return o.concat(g,f)},[]);return s}Mt.validateAmbiguousAlternationAlternatives=gj;var Ej=function(t){aS(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.allProductions=[],r}return e.prototype.visitRepetitionWithSeparator=function(r){this.allProductions.push(r)},e.prototype.visitRepetitionMandatory=function(r){this.allProductions.push(r)},e.prototype.visitRepetitionMandatoryWithSeparator=function(r){this.allProductions.push(r)},e.prototype.visitRepetition=function(r){this.allProductions.push(r)},e}(lS.GAstVisitor);Mt.RepetionCollector=Ej;function fj(t,e){var r=new uS;t.accept(r);var i=r.alternations,n=jt.reduce(i,function(s,o){return o.definition.length>255&&s.push({message:e.buildTooManyAlternativesError({topLevelRule:t,alternation:o}),type:uo.ParserDefinitionErrorType.TOO_MANY_ALTS,ruleName:t.name,occurrence:o.idx}),s},[]);return n}Mt.validateTooManyAlts=fj;function hj(t,e,r){var i=[];return(0,Cr.forEach)(t,function(n){var s=new Ej;n.accept(s);var o=s.allProductions;(0,Cr.forEach)(o,function(a){var l=(0,Qu.getProdType)(a),c=a.maxLookahead||e,u=a.idx,g=(0,Qu.getLookaheadPathsForOptionalProd)(u,n,l,c),f=g[0];if((0,Cr.isEmpty)((0,Cr.flatten)(f))){var h=r.buildEmptyRepetitionError({topLevelRule:n,repetition:a});i.push({message:h,type:uo.ParserDefinitionErrorType.NO_NON_EMPTY_LOOKAHEAD,ruleName:n.name})}})}),i}Mt.validateSomeNonEmptyLookaheadPath=hj;function aye(t,e,r,i){var n=[],s=(0,Cr.reduce)(t,function(a,l,c){return e.definition[c].ignoreAmbiguities===!0||(0,Cr.forEach)(l,function(u){var g=[c];(0,Cr.forEach)(t,function(f,h){c!==h&&(0,Qu.containsPath)(f,u)&&e.definition[h].ignoreAmbiguities!==!0&&g.push(h)}),g.length>1&&!(0,Qu.containsPath)(n,u)&&(n.push(u),a.push({alts:g,path:u}))}),a},[]),o=jt.map(s,function(a){var l=(0,Cr.map)(a.alts,function(u){return u+1}),c=i.buildAlternationAmbiguityError({topLevelRule:r,alternation:e,ambiguityIndices:l,prefixPath:a.path});return{message:c,type:uo.ParserDefinitionErrorType.AMBIGUOUS_ALTS,ruleName:r.name,occurrence:e.idx,alternatives:[a.alts]}});return o}function mj(t,e,r,i){var n=[],s=(0,Cr.reduce)(t,function(o,a,l){var c=(0,Cr.map)(a,function(u){return{idx:l,path:u}});return o.concat(c)},[]);return(0,Cr.forEach)(s,function(o){var a=e.definition[o.idx];if(a.ignoreAmbiguities!==!0){var l=o.idx,c=o.path,u=(0,Cr.findAll)(s,function(f){return e.definition[f.idx].ignoreAmbiguities!==!0&&f.idx{"use strict";Object.defineProperty(bu,"__esModule",{value:!0});bu.validateGrammar=bu.resolveGrammar=void 0;var fS=Dt(),Aye=$G(),lye=gS(),Ij=Wh();function cye(t){t=(0,fS.defaults)(t,{errMsgProvider:Ij.defaultGrammarResolverErrorProvider});var e={};return(0,fS.forEach)(t.rules,function(r){e[r.name]=r}),(0,Aye.resolveGrammar)(e,t.errMsgProvider)}bu.resolveGrammar=cye;function uye(t){return t=(0,fS.defaults)(t,{errMsgProvider:Ij.defaultGrammarValidatorErrorProvider}),(0,lye.validateGrammar)(t.rules,t.maxLookahead,t.tokenTypes,t.errMsgProvider,t.grammarName)}bu.validateGrammar=uye});var vu=E(dn=>{"use strict";var Zh=dn&&dn.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(dn,"__esModule",{value:!0});dn.EarlyExitException=dn.NotAllInputParsedException=dn.NoViableAltException=dn.MismatchedTokenException=dn.isRecognitionException=void 0;var gye=Dt(),wj="MismatchedTokenException",Bj="NoViableAltException",Qj="EarlyExitException",bj="NotAllInputParsedException",vj=[wj,Bj,Qj,bj];Object.freeze(vj);function fye(t){return(0,gye.contains)(vj,t.name)}dn.isRecognitionException=fye;var vI=function(t){Zh(e,t);function e(r,i){var n=this.constructor,s=t.call(this,r)||this;return s.token=i,s.resyncedTokens=[],Object.setPrototypeOf(s,n.prototype),Error.captureStackTrace&&Error.captureStackTrace(s,s.constructor),s}return e}(Error),hye=function(t){Zh(e,t);function e(r,i,n){var s=t.call(this,r,i)||this;return s.previousToken=n,s.name=wj,s}return e}(vI);dn.MismatchedTokenException=hye;var pye=function(t){Zh(e,t);function e(r,i,n){var s=t.call(this,r,i)||this;return s.previousToken=n,s.name=Bj,s}return e}(vI);dn.NoViableAltException=pye;var dye=function(t){Zh(e,t);function e(r,i){var n=t.call(this,r,i)||this;return n.name=bj,n}return e}(vI);dn.NotAllInputParsedException=dye;var Cye=function(t){Zh(e,t);function e(r,i,n){var s=t.call(this,r,i)||this;return s.previousToken=n,s.name=Qj,s}return e}(vI);dn.EarlyExitException=Cye});var pS=E(xi=>{"use strict";Object.defineProperty(xi,"__esModule",{value:!0});xi.attemptInRepetitionRecovery=xi.Recoverable=xi.InRuleRecoveryException=xi.IN_RULE_RECOVERY_EXCEPTION=xi.EOF_FOLLOW_KEY=void 0;var SI=nA(),ts=Dt(),mye=vu(),Eye=rS(),Iye=Tn();xi.EOF_FOLLOW_KEY={};xi.IN_RULE_RECOVERY_EXCEPTION="InRuleRecoveryException";function hS(t){this.name=xi.IN_RULE_RECOVERY_EXCEPTION,this.message=t}xi.InRuleRecoveryException=hS;hS.prototype=Error.prototype;var yye=function(){function t(){}return t.prototype.initRecoverable=function(e){this.firstAfterRepMap={},this.resyncFollows={},this.recoveryEnabled=(0,ts.has)(e,"recoveryEnabled")?e.recoveryEnabled:Iye.DEFAULT_PARSER_CONFIG.recoveryEnabled,this.recoveryEnabled&&(this.attemptInRepetitionRecovery=Sj)},t.prototype.getTokenToInsert=function(e){var r=(0,SI.createTokenInstance)(e,"",NaN,NaN,NaN,NaN,NaN,NaN);return r.isInsertedInRecovery=!0,r},t.prototype.canTokenTypeBeInsertedInRecovery=function(e){return!0},t.prototype.tryInRepetitionRecovery=function(e,r,i,n){for(var s=this,o=this.findReSyncTokenType(),a=this.exportLexerState(),l=[],c=!1,u=this.LA(1),g=this.LA(1),f=function(){var h=s.LA(0),p=s.errorMessageProvider.buildMismatchTokenMessage({expected:n,actual:u,previous:h,ruleName:s.getCurrRuleFullName()}),d=new mye.MismatchedTokenException(p,u,s.LA(0));d.resyncedTokens=(0,ts.dropRight)(l),s.SAVE_ERROR(d)};!c;)if(this.tokenMatcher(g,n)){f();return}else if(i.call(this)){f(),e.apply(this,r);return}else this.tokenMatcher(g,o)?c=!0:(g=this.SKIP_TOKEN(),this.addToResyncTokens(g,l));this.importLexerState(a)},t.prototype.shouldInRepetitionRecoveryBeTried=function(e,r,i){return!(i===!1||e===void 0||r===void 0||this.tokenMatcher(this.LA(1),e)||this.isBackTracking()||this.canPerformInRuleRecovery(e,this.getFollowsForInRuleRecovery(e,r)))},t.prototype.getFollowsForInRuleRecovery=function(e,r){var i=this.getCurrentGrammarPath(e,r),n=this.getNextPossibleTokenTypes(i);return n},t.prototype.tryInRuleRecovery=function(e,r){if(this.canRecoverWithSingleTokenInsertion(e,r)){var i=this.getTokenToInsert(e);return i}if(this.canRecoverWithSingleTokenDeletion(e)){var n=this.SKIP_TOKEN();return this.consumeToken(),n}throw new hS("sad sad panda")},t.prototype.canPerformInRuleRecovery=function(e,r){return this.canRecoverWithSingleTokenInsertion(e,r)||this.canRecoverWithSingleTokenDeletion(e)},t.prototype.canRecoverWithSingleTokenInsertion=function(e,r){var i=this;if(!this.canTokenTypeBeInsertedInRecovery(e)||(0,ts.isEmpty)(r))return!1;var n=this.LA(1),s=(0,ts.find)(r,function(o){return i.tokenMatcher(n,o)})!==void 0;return s},t.prototype.canRecoverWithSingleTokenDeletion=function(e){var r=this.tokenMatcher(this.LA(2),e);return r},t.prototype.isInCurrentRuleReSyncSet=function(e){var r=this.getCurrFollowKey(),i=this.getFollowSetFromFollowKey(r);return(0,ts.contains)(i,e)},t.prototype.findReSyncTokenType=function(){for(var e=this.flattenFollowSet(),r=this.LA(1),i=2;;){var n=r.tokenType;if((0,ts.contains)(e,n))return n;r=this.LA(i),i++}},t.prototype.getCurrFollowKey=function(){if(this.RULE_STACK.length===1)return xi.EOF_FOLLOW_KEY;var e=this.getLastExplicitRuleShortName(),r=this.getLastExplicitRuleOccurrenceIndex(),i=this.getPreviousExplicitRuleShortName();return{ruleName:this.shortRuleNameToFullName(e),idxInCallingRule:r,inRule:this.shortRuleNameToFullName(i)}},t.prototype.buildFullFollowKeyStack=function(){var e=this,r=this.RULE_STACK,i=this.RULE_OCCURRENCE_STACK;return(0,ts.map)(r,function(n,s){return s===0?xi.EOF_FOLLOW_KEY:{ruleName:e.shortRuleNameToFullName(n),idxInCallingRule:i[s],inRule:e.shortRuleNameToFullName(r[s-1])}})},t.prototype.flattenFollowSet=function(){var e=this,r=(0,ts.map)(this.buildFullFollowKeyStack(),function(i){return e.getFollowSetFromFollowKey(i)});return(0,ts.flatten)(r)},t.prototype.getFollowSetFromFollowKey=function(e){if(e===xi.EOF_FOLLOW_KEY)return[SI.EOF];var r=e.ruleName+e.idxInCallingRule+Eye.IN+e.inRule;return this.resyncFollows[r]},t.prototype.addToResyncTokens=function(e,r){return this.tokenMatcher(e,SI.EOF)||r.push(e),r},t.prototype.reSyncTo=function(e){for(var r=[],i=this.LA(1);this.tokenMatcher(i,e)===!1;)i=this.SKIP_TOKEN(),this.addToResyncTokens(i,r);return(0,ts.dropRight)(r)},t.prototype.attemptInRepetitionRecovery=function(e,r,i,n,s,o,a){},t.prototype.getCurrentGrammarPath=function(e,r){var i=this.getHumanReadableRuleStack(),n=(0,ts.cloneArr)(this.RULE_OCCURRENCE_STACK),s={ruleStack:i,occurrenceStack:n,lastTok:e,lastTokOccurrence:r};return s},t.prototype.getHumanReadableRuleStack=function(){var e=this;return(0,ts.map)(this.RULE_STACK,function(r){return e.shortRuleNameToFullName(r)})},t}();xi.Recoverable=yye;function Sj(t,e,r,i,n,s,o){var a=this.getKeyForAutomaticLookahead(i,n),l=this.firstAfterRepMap[a];if(l===void 0){var c=this.getCurrRuleFullName(),u=this.getGAstProductions()[c],g=new s(u,n);l=g.startWalking(),this.firstAfterRepMap[a]=l}var f=l.token,h=l.occurrence,p=l.isEndOfRule;this.RULE_STACK.length===1&&p&&f===void 0&&(f=SI.EOF,h=1),this.shouldInRepetitionRecoveryBeTried(f,h,o)&&this.tryInRepetitionRecovery(t,e,r,f)}xi.attemptInRepetitionRecovery=Sj});var xI=E(Nt=>{"use strict";Object.defineProperty(Nt,"__esModule",{value:!0});Nt.getKeyForAutomaticLookahead=Nt.AT_LEAST_ONE_SEP_IDX=Nt.MANY_SEP_IDX=Nt.AT_LEAST_ONE_IDX=Nt.MANY_IDX=Nt.OPTION_IDX=Nt.OR_IDX=Nt.BITS_FOR_ALT_IDX=Nt.BITS_FOR_RULE_IDX=Nt.BITS_FOR_OCCURRENCE_IDX=Nt.BITS_FOR_METHOD_TYPE=void 0;Nt.BITS_FOR_METHOD_TYPE=4;Nt.BITS_FOR_OCCURRENCE_IDX=8;Nt.BITS_FOR_RULE_IDX=12;Nt.BITS_FOR_ALT_IDX=8;Nt.OR_IDX=1<{"use strict";Object.defineProperty(kI,"__esModule",{value:!0});kI.LooksAhead=void 0;var Aa=_h(),Ns=Dt(),xj=Tn(),la=xI(),Nl=Jh(),Bye=function(){function t(){}return t.prototype.initLooksAhead=function(e){this.dynamicTokensEnabled=(0,Ns.has)(e,"dynamicTokensEnabled")?e.dynamicTokensEnabled:xj.DEFAULT_PARSER_CONFIG.dynamicTokensEnabled,this.maxLookahead=(0,Ns.has)(e,"maxLookahead")?e.maxLookahead:xj.DEFAULT_PARSER_CONFIG.maxLookahead,this.lookAheadFuncsCache=(0,Ns.isES2015MapSupported)()?new Map:[],(0,Ns.isES2015MapSupported)()?(this.getLaFuncFromCache=this.getLaFuncFromMap,this.setLaFuncCache=this.setLaFuncCacheUsingMap):(this.getLaFuncFromCache=this.getLaFuncFromObj,this.setLaFuncCache=this.setLaFuncUsingObj)},t.prototype.preComputeLookaheadFunctions=function(e){var r=this;(0,Ns.forEach)(e,function(i){r.TRACE_INIT(i.name+" Rule Lookahead",function(){var n=(0,Nl.collectMethods)(i),s=n.alternation,o=n.repetition,a=n.option,l=n.repetitionMandatory,c=n.repetitionMandatoryWithSeparator,u=n.repetitionWithSeparator;(0,Ns.forEach)(s,function(g){var f=g.idx===0?"":g.idx;r.TRACE_INIT(""+(0,Nl.getProductionDslName)(g)+f,function(){var h=(0,Aa.buildLookaheadFuncForOr)(g.idx,i,g.maxLookahead||r.maxLookahead,g.hasPredicates,r.dynamicTokensEnabled,r.lookAheadBuilderForAlternatives),p=(0,la.getKeyForAutomaticLookahead)(r.fullRuleNameToShort[i.name],la.OR_IDX,g.idx);r.setLaFuncCache(p,h)})}),(0,Ns.forEach)(o,function(g){r.computeLookaheadFunc(i,g.idx,la.MANY_IDX,Aa.PROD_TYPE.REPETITION,g.maxLookahead,(0,Nl.getProductionDslName)(g))}),(0,Ns.forEach)(a,function(g){r.computeLookaheadFunc(i,g.idx,la.OPTION_IDX,Aa.PROD_TYPE.OPTION,g.maxLookahead,(0,Nl.getProductionDslName)(g))}),(0,Ns.forEach)(l,function(g){r.computeLookaheadFunc(i,g.idx,la.AT_LEAST_ONE_IDX,Aa.PROD_TYPE.REPETITION_MANDATORY,g.maxLookahead,(0,Nl.getProductionDslName)(g))}),(0,Ns.forEach)(c,function(g){r.computeLookaheadFunc(i,g.idx,la.AT_LEAST_ONE_SEP_IDX,Aa.PROD_TYPE.REPETITION_MANDATORY_WITH_SEPARATOR,g.maxLookahead,(0,Nl.getProductionDslName)(g))}),(0,Ns.forEach)(u,function(g){r.computeLookaheadFunc(i,g.idx,la.MANY_SEP_IDX,Aa.PROD_TYPE.REPETITION_WITH_SEPARATOR,g.maxLookahead,(0,Nl.getProductionDslName)(g))})})})},t.prototype.computeLookaheadFunc=function(e,r,i,n,s,o){var a=this;this.TRACE_INIT(""+o+(r===0?"":r),function(){var l=(0,Aa.buildLookaheadFuncForOptionalProd)(r,e,s||a.maxLookahead,a.dynamicTokensEnabled,n,a.lookAheadBuilderForOptional),c=(0,la.getKeyForAutomaticLookahead)(a.fullRuleNameToShort[e.name],i,r);a.setLaFuncCache(c,l)})},t.prototype.lookAheadBuilderForOptional=function(e,r,i){return(0,Aa.buildSingleAlternativeLookaheadFunction)(e,r,i)},t.prototype.lookAheadBuilderForAlternatives=function(e,r,i,n){return(0,Aa.buildAlternativesLookAheadFunc)(e,r,i,n)},t.prototype.getKeyForAutomaticLookahead=function(e,r){var i=this.getLastExplicitRuleShortName();return(0,la.getKeyForAutomaticLookahead)(i,e,r)},t.prototype.getLaFuncFromCache=function(e){},t.prototype.getLaFuncFromMap=function(e){return this.lookAheadFuncsCache.get(e)},t.prototype.getLaFuncFromObj=function(e){return this.lookAheadFuncsCache[e]},t.prototype.setLaFuncCache=function(e,r){},t.prototype.setLaFuncCacheUsingMap=function(e,r){this.lookAheadFuncsCache.set(e,r)},t.prototype.setLaFuncUsingObj=function(e,r){this.lookAheadFuncsCache[e]=r},t}();kI.LooksAhead=Bye});var Pj=E(go=>{"use strict";Object.defineProperty(go,"__esModule",{value:!0});go.addNoneTerminalToCst=go.addTerminalToCst=go.setNodeLocationFull=go.setNodeLocationOnlyOffset=void 0;function Qye(t,e){isNaN(t.startOffset)===!0?(t.startOffset=e.startOffset,t.endOffset=e.endOffset):t.endOffset{"use strict";Object.defineProperty(aA,"__esModule",{value:!0});aA.defineNameProp=aA.functionName=aA.classNameFromInstance=void 0;var xye=Dt();function kye(t){return Dj(t.constructor)}aA.classNameFromInstance=kye;var Rj="name";function Dj(t){var e=t.name;return e||"anonymous"}aA.functionName=Dj;function Pye(t,e){var r=Object.getOwnPropertyDescriptor(t,Rj);return(0,xye.isUndefined)(r)||r.configurable?(Object.defineProperty(t,Rj,{enumerable:!1,configurable:!0,writable:!1,value:e}),!0):!1}aA.defineNameProp=Pye});var Mj=E(mi=>{"use strict";Object.defineProperty(mi,"__esModule",{value:!0});mi.validateRedundantMethods=mi.validateMissingCstMethods=mi.validateVisitor=mi.CstVisitorDefinitionError=mi.createBaseVisitorConstructorWithDefaults=mi.createBaseSemanticVisitorConstructor=mi.defaultVisit=void 0;var rs=Dt(),$h=dS();function Fj(t,e){for(var r=(0,rs.keys)(t),i=r.length,n=0;n: - `+(""+s.join(` - -`).replace(/\n/g,` - `)))}}};return r.prototype=i,r.prototype.constructor=r,r._RULE_NAMES=e,r}mi.createBaseSemanticVisitorConstructor=Dye;function Rye(t,e,r){var i=function(){};(0,$h.defineNameProp)(i,t+"BaseSemanticsWithDefaults");var n=Object.create(r.prototype);return(0,rs.forEach)(e,function(s){n[s]=Fj}),i.prototype=n,i.prototype.constructor=i,i}mi.createBaseVisitorConstructorWithDefaults=Rye;var CS;(function(t){t[t.REDUNDANT_METHOD=0]="REDUNDANT_METHOD",t[t.MISSING_METHOD=1]="MISSING_METHOD"})(CS=mi.CstVisitorDefinitionError||(mi.CstVisitorDefinitionError={}));function Nj(t,e){var r=Lj(t,e),i=Tj(t,e);return r.concat(i)}mi.validateVisitor=Nj;function Lj(t,e){var r=(0,rs.map)(e,function(i){if(!(0,rs.isFunction)(t[i]))return{msg:"Missing visitor method: <"+i+"> on "+(0,$h.functionName)(t.constructor)+" CST Visitor.",type:CS.MISSING_METHOD,methodName:i}});return(0,rs.compact)(r)}mi.validateMissingCstMethods=Lj;var Fye=["constructor","visit","validateVisitor"];function Tj(t,e){var r=[];for(var i in t)(0,rs.isFunction)(t[i])&&!(0,rs.contains)(Fye,i)&&!(0,rs.contains)(e,i)&&r.push({msg:"Redundant visitor method: <"+i+"> on "+(0,$h.functionName)(t.constructor)+` CST Visitor -There is no Grammar Rule corresponding to this method's name. -`,type:CS.REDUNDANT_METHOD,methodName:i});return r}mi.validateRedundantMethods=Tj});var Kj=E(PI=>{"use strict";Object.defineProperty(PI,"__esModule",{value:!0});PI.TreeBuilder=void 0;var Su=Pj(),Ur=Dt(),Oj=Mj(),Nye=Tn(),Lye=function(){function t(){}return t.prototype.initTreeBuilder=function(e){if(this.CST_STACK=[],this.outputCst=e.outputCst,this.nodeLocationTracking=(0,Ur.has)(e,"nodeLocationTracking")?e.nodeLocationTracking:Nye.DEFAULT_PARSER_CONFIG.nodeLocationTracking,!this.outputCst)this.cstInvocationStateUpdate=Ur.NOOP,this.cstFinallyStateUpdate=Ur.NOOP,this.cstPostTerminal=Ur.NOOP,this.cstPostNonTerminal=Ur.NOOP,this.cstPostRule=Ur.NOOP;else if(/full/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=Su.setNodeLocationFull,this.setNodeLocationFromNode=Su.setNodeLocationFull,this.cstPostRule=Ur.NOOP,this.setInitialNodeLocation=this.setInitialNodeLocationFullRecovery):(this.setNodeLocationFromToken=Ur.NOOP,this.setNodeLocationFromNode=Ur.NOOP,this.cstPostRule=this.cstPostRuleFull,this.setInitialNodeLocation=this.setInitialNodeLocationFullRegular);else if(/onlyOffset/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=Su.setNodeLocationOnlyOffset,this.setNodeLocationFromNode=Su.setNodeLocationOnlyOffset,this.cstPostRule=Ur.NOOP,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRecovery):(this.setNodeLocationFromToken=Ur.NOOP,this.setNodeLocationFromNode=Ur.NOOP,this.cstPostRule=this.cstPostRuleOnlyOffset,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRegular);else if(/none/i.test(this.nodeLocationTracking))this.setNodeLocationFromToken=Ur.NOOP,this.setNodeLocationFromNode=Ur.NOOP,this.cstPostRule=Ur.NOOP,this.setInitialNodeLocation=Ur.NOOP;else throw Error('Invalid config option: "'+e.nodeLocationTracking+'"')},t.prototype.setInitialNodeLocationOnlyOffsetRecovery=function(e){e.location={startOffset:NaN,endOffset:NaN}},t.prototype.setInitialNodeLocationOnlyOffsetRegular=function(e){e.location={startOffset:this.LA(1).startOffset,endOffset:NaN}},t.prototype.setInitialNodeLocationFullRecovery=function(e){e.location={startOffset:NaN,startLine:NaN,startColumn:NaN,endOffset:NaN,endLine:NaN,endColumn:NaN}},t.prototype.setInitialNodeLocationFullRegular=function(e){var r=this.LA(1);e.location={startOffset:r.startOffset,startLine:r.startLine,startColumn:r.startColumn,endOffset:NaN,endLine:NaN,endColumn:NaN}},t.prototype.cstInvocationStateUpdate=function(e,r){var i={name:e,children:{}};this.setInitialNodeLocation(i),this.CST_STACK.push(i)},t.prototype.cstFinallyStateUpdate=function(){this.CST_STACK.pop()},t.prototype.cstPostRuleFull=function(e){var r=this.LA(0),i=e.location;i.startOffset<=r.startOffset?(i.endOffset=r.endOffset,i.endLine=r.endLine,i.endColumn=r.endColumn):(i.startOffset=NaN,i.startLine=NaN,i.startColumn=NaN)},t.prototype.cstPostRuleOnlyOffset=function(e){var r=this.LA(0),i=e.location;i.startOffset<=r.startOffset?i.endOffset=r.endOffset:i.startOffset=NaN},t.prototype.cstPostTerminal=function(e,r){var i=this.CST_STACK[this.CST_STACK.length-1];(0,Su.addTerminalToCst)(i,r,e),this.setNodeLocationFromToken(i.location,r)},t.prototype.cstPostNonTerminal=function(e,r){var i=this.CST_STACK[this.CST_STACK.length-1];(0,Su.addNoneTerminalToCst)(i,r,e),this.setNodeLocationFromNode(i.location,e.location)},t.prototype.getBaseCstVisitorConstructor=function(){if((0,Ur.isUndefined)(this.baseCstVisitorConstructor)){var e=(0,Oj.createBaseSemanticVisitorConstructor)(this.className,(0,Ur.keys)(this.gastProductionsCache));return this.baseCstVisitorConstructor=e,e}return this.baseCstVisitorConstructor},t.prototype.getBaseCstVisitorConstructorWithDefaults=function(){if((0,Ur.isUndefined)(this.baseCstVisitorWithDefaultsConstructor)){var e=(0,Oj.createBaseVisitorConstructorWithDefaults)(this.className,(0,Ur.keys)(this.gastProductionsCache),this.getBaseCstVisitorConstructor());return this.baseCstVisitorWithDefaultsConstructor=e,e}return this.baseCstVisitorWithDefaultsConstructor},t.prototype.getLastExplicitRuleShortName=function(){var e=this.RULE_STACK;return e[e.length-1]},t.prototype.getPreviousExplicitRuleShortName=function(){var e=this.RULE_STACK;return e[e.length-2]},t.prototype.getLastExplicitRuleOccurrenceIndex=function(){var e=this.RULE_OCCURRENCE_STACK;return e[e.length-1]},t}();PI.TreeBuilder=Lye});var Hj=E(DI=>{"use strict";Object.defineProperty(DI,"__esModule",{value:!0});DI.LexerAdapter=void 0;var Uj=Tn(),Tye=function(){function t(){}return t.prototype.initLexerAdapter=function(){this.tokVector=[],this.tokVectorLength=0,this.currIdx=-1},Object.defineProperty(t.prototype,"input",{get:function(){return this.tokVector},set:function(e){if(this.selfAnalysisDone!==!0)throw Error("Missing invocation at the end of the Parser's constructor.");this.reset(),this.tokVector=e,this.tokVectorLength=e.length},enumerable:!1,configurable:!0}),t.prototype.SKIP_TOKEN=function(){return this.currIdx<=this.tokVector.length-2?(this.consumeToken(),this.LA(1)):Uj.END_OF_FILE},t.prototype.LA=function(e){var r=this.currIdx+e;return r<0||this.tokVectorLength<=r?Uj.END_OF_FILE:this.tokVector[r]},t.prototype.consumeToken=function(){this.currIdx++},t.prototype.exportLexerState=function(){return this.currIdx},t.prototype.importLexerState=function(e){this.currIdx=e},t.prototype.resetLexerState=function(){this.currIdx=-1},t.prototype.moveToTerminatedState=function(){this.currIdx=this.tokVector.length-1},t.prototype.getLexerPosition=function(){return this.exportLexerState()},t}();DI.LexerAdapter=Tye});var jj=E(RI=>{"use strict";Object.defineProperty(RI,"__esModule",{value:!0});RI.RecognizerApi=void 0;var Gj=Dt(),Mye=vu(),mS=Tn(),Oye=Wh(),Kye=gS(),Uye=hn(),Hye=function(){function t(){}return t.prototype.ACTION=function(e){return e.call(this)},t.prototype.consume=function(e,r,i){return this.consumeInternal(r,e,i)},t.prototype.subrule=function(e,r,i){return this.subruleInternal(r,e,i)},t.prototype.option=function(e,r){return this.optionInternal(r,e)},t.prototype.or=function(e,r){return this.orInternal(r,e)},t.prototype.many=function(e,r){return this.manyInternal(e,r)},t.prototype.atLeastOne=function(e,r){return this.atLeastOneInternal(e,r)},t.prototype.CONSUME=function(e,r){return this.consumeInternal(e,0,r)},t.prototype.CONSUME1=function(e,r){return this.consumeInternal(e,1,r)},t.prototype.CONSUME2=function(e,r){return this.consumeInternal(e,2,r)},t.prototype.CONSUME3=function(e,r){return this.consumeInternal(e,3,r)},t.prototype.CONSUME4=function(e,r){return this.consumeInternal(e,4,r)},t.prototype.CONSUME5=function(e,r){return this.consumeInternal(e,5,r)},t.prototype.CONSUME6=function(e,r){return this.consumeInternal(e,6,r)},t.prototype.CONSUME7=function(e,r){return this.consumeInternal(e,7,r)},t.prototype.CONSUME8=function(e,r){return this.consumeInternal(e,8,r)},t.prototype.CONSUME9=function(e,r){return this.consumeInternal(e,9,r)},t.prototype.SUBRULE=function(e,r){return this.subruleInternal(e,0,r)},t.prototype.SUBRULE1=function(e,r){return this.subruleInternal(e,1,r)},t.prototype.SUBRULE2=function(e,r){return this.subruleInternal(e,2,r)},t.prototype.SUBRULE3=function(e,r){return this.subruleInternal(e,3,r)},t.prototype.SUBRULE4=function(e,r){return this.subruleInternal(e,4,r)},t.prototype.SUBRULE5=function(e,r){return this.subruleInternal(e,5,r)},t.prototype.SUBRULE6=function(e,r){return this.subruleInternal(e,6,r)},t.prototype.SUBRULE7=function(e,r){return this.subruleInternal(e,7,r)},t.prototype.SUBRULE8=function(e,r){return this.subruleInternal(e,8,r)},t.prototype.SUBRULE9=function(e,r){return this.subruleInternal(e,9,r)},t.prototype.OPTION=function(e){return this.optionInternal(e,0)},t.prototype.OPTION1=function(e){return this.optionInternal(e,1)},t.prototype.OPTION2=function(e){return this.optionInternal(e,2)},t.prototype.OPTION3=function(e){return this.optionInternal(e,3)},t.prototype.OPTION4=function(e){return this.optionInternal(e,4)},t.prototype.OPTION5=function(e){return this.optionInternal(e,5)},t.prototype.OPTION6=function(e){return this.optionInternal(e,6)},t.prototype.OPTION7=function(e){return this.optionInternal(e,7)},t.prototype.OPTION8=function(e){return this.optionInternal(e,8)},t.prototype.OPTION9=function(e){return this.optionInternal(e,9)},t.prototype.OR=function(e){return this.orInternal(e,0)},t.prototype.OR1=function(e){return this.orInternal(e,1)},t.prototype.OR2=function(e){return this.orInternal(e,2)},t.prototype.OR3=function(e){return this.orInternal(e,3)},t.prototype.OR4=function(e){return this.orInternal(e,4)},t.prototype.OR5=function(e){return this.orInternal(e,5)},t.prototype.OR6=function(e){return this.orInternal(e,6)},t.prototype.OR7=function(e){return this.orInternal(e,7)},t.prototype.OR8=function(e){return this.orInternal(e,8)},t.prototype.OR9=function(e){return this.orInternal(e,9)},t.prototype.MANY=function(e){this.manyInternal(0,e)},t.prototype.MANY1=function(e){this.manyInternal(1,e)},t.prototype.MANY2=function(e){this.manyInternal(2,e)},t.prototype.MANY3=function(e){this.manyInternal(3,e)},t.prototype.MANY4=function(e){this.manyInternal(4,e)},t.prototype.MANY5=function(e){this.manyInternal(5,e)},t.prototype.MANY6=function(e){this.manyInternal(6,e)},t.prototype.MANY7=function(e){this.manyInternal(7,e)},t.prototype.MANY8=function(e){this.manyInternal(8,e)},t.prototype.MANY9=function(e){this.manyInternal(9,e)},t.prototype.MANY_SEP=function(e){this.manySepFirstInternal(0,e)},t.prototype.MANY_SEP1=function(e){this.manySepFirstInternal(1,e)},t.prototype.MANY_SEP2=function(e){this.manySepFirstInternal(2,e)},t.prototype.MANY_SEP3=function(e){this.manySepFirstInternal(3,e)},t.prototype.MANY_SEP4=function(e){this.manySepFirstInternal(4,e)},t.prototype.MANY_SEP5=function(e){this.manySepFirstInternal(5,e)},t.prototype.MANY_SEP6=function(e){this.manySepFirstInternal(6,e)},t.prototype.MANY_SEP7=function(e){this.manySepFirstInternal(7,e)},t.prototype.MANY_SEP8=function(e){this.manySepFirstInternal(8,e)},t.prototype.MANY_SEP9=function(e){this.manySepFirstInternal(9,e)},t.prototype.AT_LEAST_ONE=function(e){this.atLeastOneInternal(0,e)},t.prototype.AT_LEAST_ONE1=function(e){return this.atLeastOneInternal(1,e)},t.prototype.AT_LEAST_ONE2=function(e){this.atLeastOneInternal(2,e)},t.prototype.AT_LEAST_ONE3=function(e){this.atLeastOneInternal(3,e)},t.prototype.AT_LEAST_ONE4=function(e){this.atLeastOneInternal(4,e)},t.prototype.AT_LEAST_ONE5=function(e){this.atLeastOneInternal(5,e)},t.prototype.AT_LEAST_ONE6=function(e){this.atLeastOneInternal(6,e)},t.prototype.AT_LEAST_ONE7=function(e){this.atLeastOneInternal(7,e)},t.prototype.AT_LEAST_ONE8=function(e){this.atLeastOneInternal(8,e)},t.prototype.AT_LEAST_ONE9=function(e){this.atLeastOneInternal(9,e)},t.prototype.AT_LEAST_ONE_SEP=function(e){this.atLeastOneSepFirstInternal(0,e)},t.prototype.AT_LEAST_ONE_SEP1=function(e){this.atLeastOneSepFirstInternal(1,e)},t.prototype.AT_LEAST_ONE_SEP2=function(e){this.atLeastOneSepFirstInternal(2,e)},t.prototype.AT_LEAST_ONE_SEP3=function(e){this.atLeastOneSepFirstInternal(3,e)},t.prototype.AT_LEAST_ONE_SEP4=function(e){this.atLeastOneSepFirstInternal(4,e)},t.prototype.AT_LEAST_ONE_SEP5=function(e){this.atLeastOneSepFirstInternal(5,e)},t.prototype.AT_LEAST_ONE_SEP6=function(e){this.atLeastOneSepFirstInternal(6,e)},t.prototype.AT_LEAST_ONE_SEP7=function(e){this.atLeastOneSepFirstInternal(7,e)},t.prototype.AT_LEAST_ONE_SEP8=function(e){this.atLeastOneSepFirstInternal(8,e)},t.prototype.AT_LEAST_ONE_SEP9=function(e){this.atLeastOneSepFirstInternal(9,e)},t.prototype.RULE=function(e,r,i){if(i===void 0&&(i=mS.DEFAULT_RULE_CONFIG),(0,Gj.contains)(this.definedRulesNames,e)){var n=Oye.defaultGrammarValidatorErrorProvider.buildDuplicateRuleNameError({topLevelRule:e,grammarName:this.className}),s={message:n,type:mS.ParserDefinitionErrorType.DUPLICATE_RULE_NAME,ruleName:e};this.definitionErrors.push(s)}this.definedRulesNames.push(e);var o=this.defineRule(e,r,i);return this[e]=o,o},t.prototype.OVERRIDE_RULE=function(e,r,i){i===void 0&&(i=mS.DEFAULT_RULE_CONFIG);var n=[];n=n.concat((0,Kye.validateRuleIsOverridden)(e,this.definedRulesNames,this.className)),this.definitionErrors=this.definitionErrors.concat(n);var s=this.defineRule(e,r,i);return this[e]=s,s},t.prototype.BACKTRACK=function(e,r){return function(){this.isBackTrackingStack.push(1);var i=this.saveRecogState();try{return e.apply(this,r),!0}catch(n){if((0,Mye.isRecognitionException)(n))return!1;throw n}finally{this.reloadRecogState(i),this.isBackTrackingStack.pop()}}},t.prototype.getGAstProductions=function(){return this.gastProductionsCache},t.prototype.getSerializedGastProductions=function(){return(0,Uye.serializeGrammar)((0,Gj.values)(this.gastProductionsCache))},t}();RI.RecognizerApi=Hye});var Wj=E(FI=>{"use strict";Object.defineProperty(FI,"__esModule",{value:!0});FI.RecognizerEngine=void 0;var Er=Dt(),Mn=xI(),NI=vu(),Yj=_h(),xu=Vh(),qj=Tn(),Gye=pS(),Jj=nA(),ep=yu(),jye=dS(),Yye=function(){function t(){}return t.prototype.initRecognizerEngine=function(e,r){if(this.className=(0,jye.classNameFromInstance)(this),this.shortRuleNameToFull={},this.fullRuleNameToShort={},this.ruleShortNameIdx=256,this.tokenMatcher=ep.tokenStructuredMatcherNoCategories,this.definedRulesNames=[],this.tokensMap={},this.isBackTrackingStack=[],this.RULE_STACK=[],this.RULE_OCCURRENCE_STACK=[],this.gastProductionsCache={},(0,Er.has)(r,"serializedGrammar"))throw Error(`The Parser's configuration can no longer contain a property. - See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_6-0-0 - For Further details.`);if((0,Er.isArray)(e)){if((0,Er.isEmpty)(e))throw Error(`A Token Vocabulary cannot be empty. - Note that the first argument for the parser constructor - is no longer a Token vector (since v4.0).`);if(typeof e[0].startOffset=="number")throw Error(`The Parser constructor no longer accepts a token vector as the first argument. - See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_4-0-0 - For Further details.`)}if((0,Er.isArray)(e))this.tokensMap=(0,Er.reduce)(e,function(o,a){return o[a.name]=a,o},{});else if((0,Er.has)(e,"modes")&&(0,Er.every)((0,Er.flatten)((0,Er.values)(e.modes)),ep.isTokenType)){var i=(0,Er.flatten)((0,Er.values)(e.modes)),n=(0,Er.uniq)(i);this.tokensMap=(0,Er.reduce)(n,function(o,a){return o[a.name]=a,o},{})}else if((0,Er.isObject)(e))this.tokensMap=(0,Er.cloneObj)(e);else throw new Error(" argument must be An Array of Token constructors, A dictionary of Token constructors or an IMultiModeLexerDefinition");this.tokensMap.EOF=Jj.EOF;var s=(0,Er.every)((0,Er.values)(e),function(o){return(0,Er.isEmpty)(o.categoryMatches)});this.tokenMatcher=s?ep.tokenStructuredMatcherNoCategories:ep.tokenStructuredMatcher,(0,ep.augmentTokenTypes)((0,Er.values)(this.tokensMap))},t.prototype.defineRule=function(e,r,i){if(this.selfAnalysisDone)throw Error("Grammar rule <"+e+`> may not be defined after the 'performSelfAnalysis' method has been called' -Make sure that all grammar rule definitions are done before 'performSelfAnalysis' is called.`);var n=(0,Er.has)(i,"resyncEnabled")?i.resyncEnabled:qj.DEFAULT_RULE_CONFIG.resyncEnabled,s=(0,Er.has)(i,"recoveryValueFunc")?i.recoveryValueFunc:qj.DEFAULT_RULE_CONFIG.recoveryValueFunc,o=this.ruleShortNameIdx<r},t.prototype.orInternal=function(e,r){var i=this.getKeyForAutomaticLookahead(Mn.OR_IDX,r),n=(0,Er.isArray)(e)?e:e.DEF,s=this.getLaFuncFromCache(i),o=s.call(this,n);if(o!==void 0){var a=n[o];return a.ALT.call(this)}this.raiseNoAltException(r,e.ERR_MSG)},t.prototype.ruleFinallyStateUpdate=function(){if(this.RULE_STACK.pop(),this.RULE_OCCURRENCE_STACK.pop(),this.cstFinallyStateUpdate(),this.RULE_STACK.length===0&&this.isAtEndOfInput()===!1){var e=this.LA(1),r=this.errorMessageProvider.buildNotAllInputParsedMessage({firstRedundant:e,ruleName:this.getCurrRuleFullName()});this.SAVE_ERROR(new NI.NotAllInputParsedException(r,e))}},t.prototype.subruleInternal=function(e,r,i){var n;try{var s=i!==void 0?i.ARGS:void 0;return n=e.call(this,r,s),this.cstPostNonTerminal(n,i!==void 0&&i.LABEL!==void 0?i.LABEL:e.ruleName),n}catch(o){this.subruleInternalError(o,i,e.ruleName)}},t.prototype.subruleInternalError=function(e,r,i){throw(0,NI.isRecognitionException)(e)&&e.partialCstResult!==void 0&&(this.cstPostNonTerminal(e.partialCstResult,r!==void 0&&r.LABEL!==void 0?r.LABEL:i),delete e.partialCstResult),e},t.prototype.consumeInternal=function(e,r,i){var n;try{var s=this.LA(1);this.tokenMatcher(s,e)===!0?(this.consumeToken(),n=s):this.consumeInternalError(e,s,i)}catch(o){n=this.consumeInternalRecovery(e,r,o)}return this.cstPostTerminal(i!==void 0&&i.LABEL!==void 0?i.LABEL:e.name,n),n},t.prototype.consumeInternalError=function(e,r,i){var n,s=this.LA(0);throw i!==void 0&&i.ERR_MSG?n=i.ERR_MSG:n=this.errorMessageProvider.buildMismatchTokenMessage({expected:e,actual:r,previous:s,ruleName:this.getCurrRuleFullName()}),this.SAVE_ERROR(new NI.MismatchedTokenException(n,r,s))},t.prototype.consumeInternalRecovery=function(e,r,i){if(this.recoveryEnabled&&i.name==="MismatchedTokenException"&&!this.isBackTracking()){var n=this.getFollowsForInRuleRecovery(e,r);try{return this.tryInRuleRecovery(e,n)}catch(s){throw s.name===Gye.IN_RULE_RECOVERY_EXCEPTION?i:s}}else throw i},t.prototype.saveRecogState=function(){var e=this.errors,r=(0,Er.cloneArr)(this.RULE_STACK);return{errors:e,lexerState:this.exportLexerState(),RULE_STACK:r,CST_STACK:this.CST_STACK}},t.prototype.reloadRecogState=function(e){this.errors=e.errors,this.importLexerState(e.lexerState),this.RULE_STACK=e.RULE_STACK},t.prototype.ruleInvocationStateUpdate=function(e,r,i){this.RULE_OCCURRENCE_STACK.push(i),this.RULE_STACK.push(e),this.cstInvocationStateUpdate(r,e)},t.prototype.isBackTracking=function(){return this.isBackTrackingStack.length!==0},t.prototype.getCurrRuleFullName=function(){var e=this.getLastExplicitRuleShortName();return this.shortRuleNameToFull[e]},t.prototype.shortRuleNameToFullName=function(e){return this.shortRuleNameToFull[e]},t.prototype.isAtEndOfInput=function(){return this.tokenMatcher(this.LA(1),Jj.EOF)},t.prototype.reset=function(){this.resetLexerState(),this.isBackTrackingStack=[],this.errors=[],this.RULE_STACK=[],this.CST_STACK=[],this.RULE_OCCURRENCE_STACK=[]},t}();FI.RecognizerEngine=Yye});var Vj=E(LI=>{"use strict";Object.defineProperty(LI,"__esModule",{value:!0});LI.ErrorHandler=void 0;var ES=vu(),IS=Dt(),zj=_h(),qye=Tn(),Jye=function(){function t(){}return t.prototype.initErrorHandler=function(e){this._errors=[],this.errorMessageProvider=(0,IS.has)(e,"errorMessageProvider")?e.errorMessageProvider:qye.DEFAULT_PARSER_CONFIG.errorMessageProvider},t.prototype.SAVE_ERROR=function(e){if((0,ES.isRecognitionException)(e))return e.context={ruleStack:this.getHumanReadableRuleStack(),ruleOccurrenceStack:(0,IS.cloneArr)(this.RULE_OCCURRENCE_STACK)},this._errors.push(e),e;throw Error("Trying to save an Error which is not a RecognitionException")},Object.defineProperty(t.prototype,"errors",{get:function(){return(0,IS.cloneArr)(this._errors)},set:function(e){this._errors=e},enumerable:!1,configurable:!0}),t.prototype.raiseEarlyExitException=function(e,r,i){for(var n=this.getCurrRuleFullName(),s=this.getGAstProductions()[n],o=(0,zj.getLookaheadPathsForOptionalProd)(e,s,r,this.maxLookahead),a=o[0],l=[],c=1;c<=this.maxLookahead;c++)l.push(this.LA(c));var u=this.errorMessageProvider.buildEarlyExitMessage({expectedIterationPaths:a,actual:l,previous:this.LA(0),customUserDescription:i,ruleName:n});throw this.SAVE_ERROR(new ES.EarlyExitException(u,this.LA(1),this.LA(0)))},t.prototype.raiseNoAltException=function(e,r){for(var i=this.getCurrRuleFullName(),n=this.getGAstProductions()[i],s=(0,zj.getLookaheadPathsForOr)(e,n,this.maxLookahead),o=[],a=1;a<=this.maxLookahead;a++)o.push(this.LA(a));var l=this.LA(0),c=this.errorMessageProvider.buildNoViableAltMessage({expectedPathsPerAlt:s,actual:o,previous:l,customUserDescription:r,ruleName:this.getCurrRuleFullName()});throw this.SAVE_ERROR(new ES.NoViableAltException(c,this.LA(1),l))},t}();LI.ErrorHandler=Jye});var Zj=E(TI=>{"use strict";Object.defineProperty(TI,"__esModule",{value:!0});TI.ContentAssist=void 0;var _j=Vh(),Xj=Dt(),Wye=function(){function t(){}return t.prototype.initContentAssist=function(){},t.prototype.computeContentAssist=function(e,r){var i=this.gastProductionsCache[e];if((0,Xj.isUndefined)(i))throw Error("Rule ->"+e+"<- does not exist in this grammar.");return(0,_j.nextPossibleTokensAfter)([i],r,this.tokenMatcher,this.maxLookahead)},t.prototype.getNextPossibleTokenTypes=function(e){var r=(0,Xj.first)(e.ruleStack),i=this.getGAstProductions(),n=i[r],s=new _j.NextAfterTokenWalker(n,e).startWalking();return s},t}();TI.ContentAssist=Wye});var oY=E(MI=>{"use strict";Object.defineProperty(MI,"__esModule",{value:!0});MI.GastRecorder=void 0;var Cn=Dt(),fo=hn(),zye=Gh(),$j=yu(),eY=nA(),Vye=Tn(),_ye=xI(),OI={description:"This Object indicates the Parser is during Recording Phase"};Object.freeze(OI);var tY=!0,rY=Math.pow(2,_ye.BITS_FOR_OCCURRENCE_IDX)-1,iY=(0,eY.createToken)({name:"RECORDING_PHASE_TOKEN",pattern:zye.Lexer.NA});(0,$j.augmentTokenTypes)([iY]);var nY=(0,eY.createTokenInstance)(iY,`This IToken indicates the Parser is in Recording Phase - See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,-1,-1,-1,-1,-1,-1);Object.freeze(nY);var Xye={name:`This CSTNode indicates the Parser is in Recording Phase - See: https://chevrotain.io/docs/guide/internals.html#grammar-recording for details`,children:{}},$ye=function(){function t(){}return t.prototype.initGastRecorder=function(e){this.recordingProdStack=[],this.RECORDING_PHASE=!1},t.prototype.enableRecording=function(){var e=this;this.RECORDING_PHASE=!0,this.TRACE_INIT("Enable Recording",function(){for(var r=function(n){var s=n>0?n:"";e["CONSUME"+s]=function(o,a){return this.consumeInternalRecord(o,n,a)},e["SUBRULE"+s]=function(o,a){return this.subruleInternalRecord(o,n,a)},e["OPTION"+s]=function(o){return this.optionInternalRecord(o,n)},e["OR"+s]=function(o){return this.orInternalRecord(o,n)},e["MANY"+s]=function(o){this.manyInternalRecord(n,o)},e["MANY_SEP"+s]=function(o){this.manySepFirstInternalRecord(n,o)},e["AT_LEAST_ONE"+s]=function(o){this.atLeastOneInternalRecord(n,o)},e["AT_LEAST_ONE_SEP"+s]=function(o){this.atLeastOneSepFirstInternalRecord(n,o)}},i=0;i<10;i++)r(i);e.consume=function(n,s,o){return this.consumeInternalRecord(s,n,o)},e.subrule=function(n,s,o){return this.subruleInternalRecord(s,n,o)},e.option=function(n,s){return this.optionInternalRecord(s,n)},e.or=function(n,s){return this.orInternalRecord(s,n)},e.many=function(n,s){this.manyInternalRecord(n,s)},e.atLeastOne=function(n,s){this.atLeastOneInternalRecord(n,s)},e.ACTION=e.ACTION_RECORD,e.BACKTRACK=e.BACKTRACK_RECORD,e.LA=e.LA_RECORD})},t.prototype.disableRecording=function(){var e=this;this.RECORDING_PHASE=!1,this.TRACE_INIT("Deleting Recording methods",function(){for(var r=0;r<10;r++){var i=r>0?r:"";delete e["CONSUME"+i],delete e["SUBRULE"+i],delete e["OPTION"+i],delete e["OR"+i],delete e["MANY"+i],delete e["MANY_SEP"+i],delete e["AT_LEAST_ONE"+i],delete e["AT_LEAST_ONE_SEP"+i]}delete e.consume,delete e.subrule,delete e.option,delete e.or,delete e.many,delete e.atLeastOne,delete e.ACTION,delete e.BACKTRACK,delete e.LA})},t.prototype.ACTION_RECORD=function(e){},t.prototype.BACKTRACK_RECORD=function(e,r){return function(){return!0}},t.prototype.LA_RECORD=function(e){return Vye.END_OF_FILE},t.prototype.topLevelRuleRecord=function(e,r){try{var i=new fo.Rule({definition:[],name:e});return i.name=e,this.recordingProdStack.push(i),r.call(this),this.recordingProdStack.pop(),i}catch(n){if(n.KNOWN_RECORDER_ERROR!==!0)try{n.message=n.message+` - This error was thrown during the "grammar recording phase" For more info see: - https://chevrotain.io/docs/guide/internals.html#grammar-recording`}catch(s){throw n}throw n}},t.prototype.optionInternalRecord=function(e,r){return tp.call(this,fo.Option,e,r)},t.prototype.atLeastOneInternalRecord=function(e,r){tp.call(this,fo.RepetitionMandatory,r,e)},t.prototype.atLeastOneSepFirstInternalRecord=function(e,r){tp.call(this,fo.RepetitionMandatoryWithSeparator,r,e,tY)},t.prototype.manyInternalRecord=function(e,r){tp.call(this,fo.Repetition,r,e)},t.prototype.manySepFirstInternalRecord=function(e,r){tp.call(this,fo.RepetitionWithSeparator,r,e,tY)},t.prototype.orInternalRecord=function(e,r){return Zye.call(this,e,r)},t.prototype.subruleInternalRecord=function(e,r,i){if(KI(r),!e||(0,Cn.has)(e,"ruleName")===!1){var n=new Error(" argument is invalid"+(" expecting a Parser method reference but got: <"+JSON.stringify(e)+">")+(` - inside top level rule: <`+this.recordingProdStack[0].name+">"));throw n.KNOWN_RECORDER_ERROR=!0,n}var s=(0,Cn.peek)(this.recordingProdStack),o=e.ruleName,a=new fo.NonTerminal({idx:r,nonTerminalName:o,label:i==null?void 0:i.LABEL,referencedRule:void 0});return s.definition.push(a),this.outputCst?Xye:OI},t.prototype.consumeInternalRecord=function(e,r,i){if(KI(r),!(0,$j.hasShortKeyProperty)(e)){var n=new Error(" argument is invalid"+(" expecting a TokenType reference but got: <"+JSON.stringify(e)+">")+(` - inside top level rule: <`+this.recordingProdStack[0].name+">"));throw n.KNOWN_RECORDER_ERROR=!0,n}var s=(0,Cn.peek)(this.recordingProdStack),o=new fo.Terminal({idx:r,terminalType:e,label:i==null?void 0:i.LABEL});return s.definition.push(o),nY},t}();MI.GastRecorder=$ye;function tp(t,e,r,i){i===void 0&&(i=!1),KI(r);var n=(0,Cn.peek)(this.recordingProdStack),s=(0,Cn.isFunction)(e)?e:e.DEF,o=new t({definition:[],idx:r});return i&&(o.separator=e.SEP),(0,Cn.has)(e,"MAX_LOOKAHEAD")&&(o.maxLookahead=e.MAX_LOOKAHEAD),this.recordingProdStack.push(o),s.call(this),n.definition.push(o),this.recordingProdStack.pop(),OI}function Zye(t,e){var r=this;KI(e);var i=(0,Cn.peek)(this.recordingProdStack),n=(0,Cn.isArray)(t)===!1,s=n===!1?t:t.DEF,o=new fo.Alternation({definition:[],idx:e,ignoreAmbiguities:n&&t.IGNORE_AMBIGUITIES===!0});(0,Cn.has)(t,"MAX_LOOKAHEAD")&&(o.maxLookahead=t.MAX_LOOKAHEAD);var a=(0,Cn.some)(s,function(l){return(0,Cn.isFunction)(l.GATE)});return o.hasPredicates=a,i.definition.push(o),(0,Cn.forEach)(s,function(l){var c=new fo.Alternative({definition:[]});o.definition.push(c),(0,Cn.has)(l,"IGNORE_AMBIGUITIES")?c.ignoreAmbiguities=l.IGNORE_AMBIGUITIES:(0,Cn.has)(l,"GATE")&&(c.ignoreAmbiguities=!0),r.recordingProdStack.push(c),l.ALT.call(r),r.recordingProdStack.pop()}),OI}function sY(t){return t===0?"":""+t}function KI(t){if(t<0||t>rY){var e=new Error("Invalid DSL Method idx value: <"+t+`> - `+("Idx value must be a none negative value smaller than "+(rY+1)));throw e.KNOWN_RECORDER_ERROR=!0,e}}});var AY=E(UI=>{"use strict";Object.defineProperty(UI,"__esModule",{value:!0});UI.PerformanceTracer=void 0;var aY=Dt(),ewe=Tn(),twe=function(){function t(){}return t.prototype.initPerformanceTracer=function(e){if((0,aY.has)(e,"traceInitPerf")){var r=e.traceInitPerf,i=typeof r=="number";this.traceInitMaxIdent=i?r:Infinity,this.traceInitPerf=i?r>0:r}else this.traceInitMaxIdent=0,this.traceInitPerf=ewe.DEFAULT_PARSER_CONFIG.traceInitPerf;this.traceInitIndent=-1},t.prototype.TRACE_INIT=function(e,r){if(this.traceInitPerf===!0){this.traceInitIndent++;var i=new Array(this.traceInitIndent+1).join(" ");this.traceInitIndent <"+e+">");var n=(0,aY.timer)(r),s=n.time,o=n.value,a=s>10?console.warn:console.log;return this.traceInitIndent time: "+s+"ms"),this.traceInitIndent--,o}else return r()},t}();UI.PerformanceTracer=twe});var lY=E(HI=>{"use strict";Object.defineProperty(HI,"__esModule",{value:!0});HI.applyMixins=void 0;function rwe(t,e){e.forEach(function(r){var i=r.prototype;Object.getOwnPropertyNames(i).forEach(function(n){if(n!=="constructor"){var s=Object.getOwnPropertyDescriptor(i,n);s&&(s.get||s.set)?Object.defineProperty(t.prototype,n,s):t.prototype[n]=r.prototype[n]}})})}HI.applyMixins=rwe});var Tn=E(or=>{"use strict";var cY=or&&or.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(i[s]=n[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();Object.defineProperty(or,"__esModule",{value:!0});or.EmbeddedActionsParser=or.CstParser=or.Parser=or.EMPTY_ALT=or.ParserDefinitionErrorType=or.DEFAULT_RULE_CONFIG=or.DEFAULT_PARSER_CONFIG=or.END_OF_FILE=void 0;var Wi=Dt(),iwe=VG(),uY=nA(),gY=Wh(),fY=yj(),nwe=pS(),swe=kj(),owe=Kj(),awe=Hj(),Awe=jj(),lwe=Wj(),cwe=Vj(),uwe=Zj(),gwe=oY(),fwe=AY(),hwe=lY();or.END_OF_FILE=(0,uY.createTokenInstance)(uY.EOF,"",NaN,NaN,NaN,NaN,NaN,NaN);Object.freeze(or.END_OF_FILE);or.DEFAULT_PARSER_CONFIG=Object.freeze({recoveryEnabled:!1,maxLookahead:3,dynamicTokensEnabled:!1,outputCst:!0,errorMessageProvider:gY.defaultParserErrorProvider,nodeLocationTracking:"none",traceInitPerf:!1,skipValidations:!1});or.DEFAULT_RULE_CONFIG=Object.freeze({recoveryValueFunc:function(){},resyncEnabled:!0});var pwe;(function(t){t[t.INVALID_RULE_NAME=0]="INVALID_RULE_NAME",t[t.DUPLICATE_RULE_NAME=1]="DUPLICATE_RULE_NAME",t[t.INVALID_RULE_OVERRIDE=2]="INVALID_RULE_OVERRIDE",t[t.DUPLICATE_PRODUCTIONS=3]="DUPLICATE_PRODUCTIONS",t[t.UNRESOLVED_SUBRULE_REF=4]="UNRESOLVED_SUBRULE_REF",t[t.LEFT_RECURSION=5]="LEFT_RECURSION",t[t.NONE_LAST_EMPTY_ALT=6]="NONE_LAST_EMPTY_ALT",t[t.AMBIGUOUS_ALTS=7]="AMBIGUOUS_ALTS",t[t.CONFLICT_TOKENS_RULES_NAMESPACE=8]="CONFLICT_TOKENS_RULES_NAMESPACE",t[t.INVALID_TOKEN_NAME=9]="INVALID_TOKEN_NAME",t[t.NO_NON_EMPTY_LOOKAHEAD=10]="NO_NON_EMPTY_LOOKAHEAD",t[t.AMBIGUOUS_PREFIX_ALTS=11]="AMBIGUOUS_PREFIX_ALTS",t[t.TOO_MANY_ALTS=12]="TOO_MANY_ALTS"})(pwe=or.ParserDefinitionErrorType||(or.ParserDefinitionErrorType={}));function dwe(t){return t===void 0&&(t=void 0),function(){return t}}or.EMPTY_ALT=dwe;var GI=function(){function t(e,r){this.definitionErrors=[],this.selfAnalysisDone=!1;var i=this;if(i.initErrorHandler(r),i.initLexerAdapter(),i.initLooksAhead(r),i.initRecognizerEngine(e,r),i.initRecoverable(r),i.initTreeBuilder(r),i.initContentAssist(),i.initGastRecorder(r),i.initPerformanceTracer(r),(0,Wi.has)(r,"ignoredIssues"))throw new Error(`The IParserConfig property has been deprecated. - Please use the flag on the relevant DSL method instead. - See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#IGNORING_AMBIGUITIES - For further details.`);this.skipValidations=(0,Wi.has)(r,"skipValidations")?r.skipValidations:or.DEFAULT_PARSER_CONFIG.skipValidations}return t.performSelfAnalysis=function(e){throw Error("The **static** `performSelfAnalysis` method has been deprecated. \nUse the **instance** method with the same name instead.")},t.prototype.performSelfAnalysis=function(){var e=this;this.TRACE_INIT("performSelfAnalysis",function(){var r;e.selfAnalysisDone=!0;var i=e.className;e.TRACE_INIT("toFastProps",function(){(0,Wi.toFastProperties)(e)}),e.TRACE_INIT("Grammar Recording",function(){try{e.enableRecording(),(0,Wi.forEach)(e.definedRulesNames,function(s){var o=e[s],a=o.originalGrammarAction,l=void 0;e.TRACE_INIT(s+" Rule",function(){l=e.topLevelRuleRecord(s,a)}),e.gastProductionsCache[s]=l})}finally{e.disableRecording()}});var n=[];if(e.TRACE_INIT("Grammar Resolving",function(){n=(0,fY.resolveGrammar)({rules:(0,Wi.values)(e.gastProductionsCache)}),e.definitionErrors=e.definitionErrors.concat(n)}),e.TRACE_INIT("Grammar Validations",function(){if((0,Wi.isEmpty)(n)&&e.skipValidations===!1){var s=(0,fY.validateGrammar)({rules:(0,Wi.values)(e.gastProductionsCache),maxLookahead:e.maxLookahead,tokenTypes:(0,Wi.values)(e.tokensMap),errMsgProvider:gY.defaultGrammarValidatorErrorProvider,grammarName:i});e.definitionErrors=e.definitionErrors.concat(s)}}),(0,Wi.isEmpty)(e.definitionErrors)&&(e.recoveryEnabled&&e.TRACE_INIT("computeAllProdsFollows",function(){var s=(0,iwe.computeAllProdsFollows)((0,Wi.values)(e.gastProductionsCache));e.resyncFollows=s}),e.TRACE_INIT("ComputeLookaheadFunctions",function(){e.preComputeLookaheadFunctions((0,Wi.values)(e.gastProductionsCache))})),!t.DEFER_DEFINITION_ERRORS_HANDLING&&!(0,Wi.isEmpty)(e.definitionErrors))throw r=(0,Wi.map)(e.definitionErrors,function(s){return s.message}),new Error(`Parser Definition Errors detected: - `+r.join(` -------------------------------- -`))})},t.DEFER_DEFINITION_ERRORS_HANDLING=!1,t}();or.Parser=GI;(0,hwe.applyMixins)(GI,[nwe.Recoverable,swe.LooksAhead,owe.TreeBuilder,awe.LexerAdapter,lwe.RecognizerEngine,Awe.RecognizerApi,cwe.ErrorHandler,uwe.ContentAssist,gwe.GastRecorder,fwe.PerformanceTracer]);var Cwe=function(t){cY(e,t);function e(r,i){i===void 0&&(i=or.DEFAULT_PARSER_CONFIG);var n=this,s=(0,Wi.cloneObj)(i);return s.outputCst=!0,n=t.call(this,r,s)||this,n}return e}(GI);or.CstParser=Cwe;var mwe=function(t){cY(e,t);function e(r,i){i===void 0&&(i=or.DEFAULT_PARSER_CONFIG);var n=this,s=(0,Wi.cloneObj)(i);return s.outputCst=!1,n=t.call(this,r,s)||this,n}return e}(GI);or.EmbeddedActionsParser=mwe});var pY=E(jI=>{"use strict";Object.defineProperty(jI,"__esModule",{value:!0});jI.createSyntaxDiagramsCode=void 0;var hY=Uv();function Ewe(t,e){var r=e===void 0?{}:e,i=r.resourceBase,n=i===void 0?"https://unpkg.com/chevrotain@"+hY.VERSION+"/diagrams/":i,s=r.css,o=s===void 0?"https://unpkg.com/chevrotain@"+hY.VERSION+"/diagrams/diagrams.css":s,a=` - - - - - -`,l=` - -`,c=` - - - - -`,u=` -
-`,g=` - -`,f=` - -`;return a+l+c+u+g+f}jI.createSyntaxDiagramsCode=Ewe});var mY=E(He=>{"use strict";Object.defineProperty(He,"__esModule",{value:!0});He.Parser=He.createSyntaxDiagramsCode=He.clearCache=He.GAstVisitor=He.serializeProduction=He.serializeGrammar=He.Terminal=He.Rule=He.RepetitionWithSeparator=He.RepetitionMandatoryWithSeparator=He.RepetitionMandatory=He.Repetition=He.Option=He.NonTerminal=He.Alternative=He.Alternation=He.defaultLexerErrorProvider=He.NoViableAltException=He.NotAllInputParsedException=He.MismatchedTokenException=He.isRecognitionException=He.EarlyExitException=He.defaultParserErrorProvider=He.tokenName=He.tokenMatcher=He.tokenLabel=He.EOF=He.createTokenInstance=He.createToken=He.LexerDefinitionErrorType=He.Lexer=He.EMPTY_ALT=He.ParserDefinitionErrorType=He.EmbeddedActionsParser=He.CstParser=He.VERSION=void 0;var Iwe=Uv();Object.defineProperty(He,"VERSION",{enumerable:!0,get:function(){return Iwe.VERSION}});var YI=Tn();Object.defineProperty(He,"CstParser",{enumerable:!0,get:function(){return YI.CstParser}});Object.defineProperty(He,"EmbeddedActionsParser",{enumerable:!0,get:function(){return YI.EmbeddedActionsParser}});Object.defineProperty(He,"ParserDefinitionErrorType",{enumerable:!0,get:function(){return YI.ParserDefinitionErrorType}});Object.defineProperty(He,"EMPTY_ALT",{enumerable:!0,get:function(){return YI.EMPTY_ALT}});var dY=Gh();Object.defineProperty(He,"Lexer",{enumerable:!0,get:function(){return dY.Lexer}});Object.defineProperty(He,"LexerDefinitionErrorType",{enumerable:!0,get:function(){return dY.LexerDefinitionErrorType}});var ku=nA();Object.defineProperty(He,"createToken",{enumerable:!0,get:function(){return ku.createToken}});Object.defineProperty(He,"createTokenInstance",{enumerable:!0,get:function(){return ku.createTokenInstance}});Object.defineProperty(He,"EOF",{enumerable:!0,get:function(){return ku.EOF}});Object.defineProperty(He,"tokenLabel",{enumerable:!0,get:function(){return ku.tokenLabel}});Object.defineProperty(He,"tokenMatcher",{enumerable:!0,get:function(){return ku.tokenMatcher}});Object.defineProperty(He,"tokenName",{enumerable:!0,get:function(){return ku.tokenName}});var ywe=Wh();Object.defineProperty(He,"defaultParserErrorProvider",{enumerable:!0,get:function(){return ywe.defaultParserErrorProvider}});var rp=vu();Object.defineProperty(He,"EarlyExitException",{enumerable:!0,get:function(){return rp.EarlyExitException}});Object.defineProperty(He,"isRecognitionException",{enumerable:!0,get:function(){return rp.isRecognitionException}});Object.defineProperty(He,"MismatchedTokenException",{enumerable:!0,get:function(){return rp.MismatchedTokenException}});Object.defineProperty(He,"NotAllInputParsedException",{enumerable:!0,get:function(){return rp.NotAllInputParsedException}});Object.defineProperty(He,"NoViableAltException",{enumerable:!0,get:function(){return rp.NoViableAltException}});var wwe=_v();Object.defineProperty(He,"defaultLexerErrorProvider",{enumerable:!0,get:function(){return wwe.defaultLexerErrorProvider}});var ho=hn();Object.defineProperty(He,"Alternation",{enumerable:!0,get:function(){return ho.Alternation}});Object.defineProperty(He,"Alternative",{enumerable:!0,get:function(){return ho.Alternative}});Object.defineProperty(He,"NonTerminal",{enumerable:!0,get:function(){return ho.NonTerminal}});Object.defineProperty(He,"Option",{enumerable:!0,get:function(){return ho.Option}});Object.defineProperty(He,"Repetition",{enumerable:!0,get:function(){return ho.Repetition}});Object.defineProperty(He,"RepetitionMandatory",{enumerable:!0,get:function(){return ho.RepetitionMandatory}});Object.defineProperty(He,"RepetitionMandatoryWithSeparator",{enumerable:!0,get:function(){return ho.RepetitionMandatoryWithSeparator}});Object.defineProperty(He,"RepetitionWithSeparator",{enumerable:!0,get:function(){return ho.RepetitionWithSeparator}});Object.defineProperty(He,"Rule",{enumerable:!0,get:function(){return ho.Rule}});Object.defineProperty(He,"Terminal",{enumerable:!0,get:function(){return ho.Terminal}});var CY=hn();Object.defineProperty(He,"serializeGrammar",{enumerable:!0,get:function(){return CY.serializeGrammar}});Object.defineProperty(He,"serializeProduction",{enumerable:!0,get:function(){return CY.serializeProduction}});var Bwe=wu();Object.defineProperty(He,"GAstVisitor",{enumerable:!0,get:function(){return Bwe.GAstVisitor}});function Qwe(){console.warn(`The clearCache function was 'soft' removed from the Chevrotain API. - It performs no action other than printing this message. - Please avoid using it as it will be completely removed in the future`)}He.clearCache=Qwe;var bwe=pY();Object.defineProperty(He,"createSyntaxDiagramsCode",{enumerable:!0,get:function(){return bwe.createSyntaxDiagramsCode}});var vwe=function(){function t(){throw new Error(`The Parser class has been deprecated, use CstParser or EmbeddedActionsParser instead. -See: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_7-0-0`)}return t}();He.Parser=vwe});var yY=E((Trt,EY)=>{var qI=mY(),ca=qI.createToken,IY=qI.tokenMatcher,yS=qI.Lexer,Swe=qI.EmbeddedActionsParser;EY.exports=t=>{let e=ca({name:"LogicalOperator",pattern:yS.NA}),r=ca({name:"Or",pattern:/\|/,categories:e}),i=ca({name:"Xor",pattern:/\^/,categories:e}),n=ca({name:"And",pattern:/&/,categories:e}),s=ca({name:"Not",pattern:/!/}),o=ca({name:"LParen",pattern:/\(/}),a=ca({name:"RParen",pattern:/\)/}),l=ca({name:"Query",pattern:t}),u=[ca({name:"WhiteSpace",pattern:/\s+/,group:yS.SKIPPED}),r,i,n,o,a,s,e,l],g=new yS(u);class f extends Swe{constructor(p){super(u);this.RULE("expression",()=>this.SUBRULE(this.logicalExpression)),this.RULE("logicalExpression",()=>{let m=this.SUBRULE(this.atomicExpression);return this.MANY(()=>{let I=m,B=this.CONSUME(e),b=this.SUBRULE2(this.atomicExpression);IY(B,r)?m=R=>I(R)||b(R):IY(B,i)?m=R=>!!(I(R)^b(R)):m=R=>I(R)&&b(R)}),m}),this.RULE("atomicExpression",()=>this.OR([{ALT:()=>this.SUBRULE(this.parenthesisExpression)},{ALT:()=>{let{image:d}=this.CONSUME(l);return m=>m(d)}},{ALT:()=>{this.CONSUME(s);let d=this.SUBRULE(this.atomicExpression);return m=>!d(m)}}])),this.RULE("parenthesisExpression",()=>{let d;return this.CONSUME(o),d=this.SUBRULE(this.expression),this.CONSUME(a),d}),this.performSelfAnalysis()}}return{TinylogicLexer:g,TinylogicParser:f}}});var wY=E(JI=>{var xwe=yY();JI.makeParser=(t=/[a-z]+/)=>{let{TinylogicLexer:e,TinylogicParser:r}=xwe(t),i=new r;return(n,s)=>{let o=e.tokenize(n);return i.input=o.tokens,i.expression()(s)}};JI.parse=JI.makeParser()});var QY=E((Ort,BY)=>{"use strict";BY.exports=(...t)=>[...new Set([].concat(...t))]});var wS=E((Krt,bY)=>{"use strict";var kwe=require("stream"),vY=kwe.PassThrough,Pwe=Array.prototype.slice;bY.exports=Dwe;function Dwe(){let t=[],e=!1,r=Pwe.call(arguments),i=r[r.length-1];i&&!Array.isArray(i)&&i.pipe==null?r.pop():i={};let n=i.end!==!1;i.objectMode==null&&(i.objectMode=!0),i.highWaterMark==null&&(i.highWaterMark=64*1024);let s=vY(i);function o(){for(let c=0,u=arguments.length;c0||(e=!1,a())}function f(h){function p(){h.removeListener("merge2UnpipeEnd",p),h.removeListener("end",p),g()}if(h._readableState.endEmitted)return g();h.on("merge2UnpipeEnd",p),h.on("end",p),h.pipe(s,{end:!1}),h.resume()}for(let h=0;h{"use strict";Object.defineProperty(WI,"__esModule",{value:!0});function Rwe(t){return t.reduce((e,r)=>[].concat(e,r),[])}WI.flatten=Rwe;function Fwe(t,e){let r=[[]],i=0;for(let n of t)e(n)?(i++,r[i]=[]):r[i].push(n);return r}WI.splitWhen=Fwe});var kY=E(BS=>{"use strict";Object.defineProperty(BS,"__esModule",{value:!0});function Nwe(t){return t.code==="ENOENT"}BS.isEnoentCodeError=Nwe});var DY=E(QS=>{"use strict";Object.defineProperty(QS,"__esModule",{value:!0});var PY=class{constructor(e,r){this.name=e,this.isBlockDevice=r.isBlockDevice.bind(r),this.isCharacterDevice=r.isCharacterDevice.bind(r),this.isDirectory=r.isDirectory.bind(r),this.isFIFO=r.isFIFO.bind(r),this.isFile=r.isFile.bind(r),this.isSocket=r.isSocket.bind(r),this.isSymbolicLink=r.isSymbolicLink.bind(r)}};function Lwe(t,e){return new PY(t,e)}QS.createDirentFromStats=Lwe});var RY=E(Pu=>{"use strict";Object.defineProperty(Pu,"__esModule",{value:!0});var Twe=require("path"),Mwe=2,Owe=/(\\?)([()*?[\]{|}]|^!|[!+@](?=\())/g;function Kwe(t){return t.replace(/\\/g,"/")}Pu.unixify=Kwe;function Uwe(t,e){return Twe.resolve(t,e)}Pu.makeAbsolute=Uwe;function Hwe(t){return t.replace(Owe,"\\$2")}Pu.escape=Hwe;function Gwe(t){if(t.charAt(0)==="."){let e=t.charAt(1);if(e==="/"||e==="\\")return t.slice(Mwe)}return t}Pu.removeLeadingDotSegment=Gwe});var NY=E((Yrt,FY)=>{FY.exports=function(e){if(typeof e!="string"||e==="")return!1;for(var r;r=/(\\).|([@?!+*]\(.*\))/g.exec(e);){if(r[2])return!0;e=e.slice(r.index+r[0].length)}return!1}});var TY=E((qrt,LY)=>{var jwe=NY(),Ywe={"{":"}","(":")","[":"]"},qwe=/\\(.)|(^!|\*|[\].+)]\?|\[[^\\\]]+\]|\{[^\\}]+\}|\(\?[:!=][^\\)]+\)|\([^|]+\|[^\\)]+\))/,Jwe=/\\(.)|(^!|[*?{}()[\]]|\(\?)/;LY.exports=function(e,r){if(typeof e!="string"||e==="")return!1;if(jwe(e))return!0;var i=qwe,n;for(r&&r.strict===!1&&(i=Jwe);n=i.exec(e);){if(n[2])return!0;var s=n.index+n[0].length,o=n[1],a=o?Ywe[o]:null;if(o&&a){var l=e.indexOf(a,s);l!==-1&&(s=l+1)}e=e.slice(s)}return!1}});var OY=E((Jrt,MY)=>{"use strict";var Wwe=TY(),zwe=require("path").posix.dirname,Vwe=require("os").platform()==="win32",bS="/",_we=/\\/g,Xwe=/[\{\[].*[\}\]]$/,Zwe=/(^|[^\\])([\{\[]|\([^\)]+$)/,$we=/\\([\!\*\?\|\[\]\(\)\{\}])/g;MY.exports=function(e,r){var i=Object.assign({flipBackslashes:!0},r);i.flipBackslashes&&Vwe&&e.indexOf(bS)<0&&(e=e.replace(_we,bS)),Xwe.test(e)&&(e+=bS),e+="a";do e=zwe(e);while(Wwe(e)||Zwe.test(e));return e.replace($we,"$1")}});var WY=E(Hr=>{"use strict";Object.defineProperty(Hr,"__esModule",{value:!0});var eBe=require("path"),tBe=OY(),KY=Nn(),rBe=iv(),UY="**",iBe="\\",nBe=/[*?]|^!/,sBe=/\[.*]/,oBe=/(?:^|[^!*+?@])\(.*\|.*\)/,aBe=/[!*+?@]\(.*\)/,ABe=/{.*(?:,|\.\.).*}/;function GY(t,e={}){return!HY(t,e)}Hr.isStaticPattern=GY;function HY(t,e={}){return!!(e.caseSensitiveMatch===!1||t.includes(iBe)||nBe.test(t)||sBe.test(t)||oBe.test(t)||e.extglob!==!1&&aBe.test(t)||e.braceExpansion!==!1&&ABe.test(t))}Hr.isDynamicPattern=HY;function lBe(t){return zI(t)?t.slice(1):t}Hr.convertToPositivePattern=lBe;function cBe(t){return"!"+t}Hr.convertToNegativePattern=cBe;function zI(t){return t.startsWith("!")&&t[1]!=="("}Hr.isNegativePattern=zI;function jY(t){return!zI(t)}Hr.isPositivePattern=jY;function uBe(t){return t.filter(zI)}Hr.getNegativePatterns=uBe;function gBe(t){return t.filter(jY)}Hr.getPositivePatterns=gBe;function fBe(t){return tBe(t,{flipBackslashes:!1})}Hr.getBaseDirectory=fBe;function hBe(t){return t.includes(UY)}Hr.hasGlobStar=hBe;function YY(t){return t.endsWith("/"+UY)}Hr.endsWithSlashGlobStar=YY;function pBe(t){let e=eBe.basename(t);return YY(t)||GY(e)}Hr.isAffectDepthOfReadingPattern=pBe;function dBe(t){return t.reduce((e,r)=>e.concat(qY(r)),[])}Hr.expandPatternsWithBraceExpansion=dBe;function qY(t){return KY.braces(t,{expand:!0,nodupes:!0})}Hr.expandBraceExpansion=qY;function CBe(t,e){let r=rBe.scan(t,Object.assign(Object.assign({},e),{parts:!0}));return r.parts.length===0?[t]:r.parts}Hr.getPatternParts=CBe;function JY(t,e){return KY.makeRe(t,e)}Hr.makeRe=JY;function mBe(t,e){return t.map(r=>JY(r,e))}Hr.convertPatternsToRe=mBe;function EBe(t,e){return e.some(r=>r.test(t))}Hr.matchAny=EBe});var VY=E(vS=>{"use strict";Object.defineProperty(vS,"__esModule",{value:!0});var IBe=wS();function yBe(t){let e=IBe(t);return t.forEach(r=>{r.once("error",i=>e.emit("error",i))}),e.once("close",()=>zY(t)),e.once("end",()=>zY(t)),e}vS.merge=yBe;function zY(t){t.forEach(e=>e.emit("close"))}});var _Y=E(VI=>{"use strict";Object.defineProperty(VI,"__esModule",{value:!0});function wBe(t){return typeof t=="string"}VI.isString=wBe;function BBe(t){return t===""}VI.isEmpty=BBe});var ga=E(ua=>{"use strict";Object.defineProperty(ua,"__esModule",{value:!0});var QBe=xY();ua.array=QBe;var bBe=kY();ua.errno=bBe;var vBe=DY();ua.fs=vBe;var SBe=RY();ua.path=SBe;var xBe=WY();ua.pattern=xBe;var kBe=VY();ua.stream=kBe;var PBe=_Y();ua.string=PBe});var tq=E(fa=>{"use strict";Object.defineProperty(fa,"__esModule",{value:!0});var Ll=ga();function DBe(t,e){let r=XY(t),i=ZY(t,e.ignore),n=r.filter(l=>Ll.pattern.isStaticPattern(l,e)),s=r.filter(l=>Ll.pattern.isDynamicPattern(l,e)),o=SS(n,i,!1),a=SS(s,i,!0);return o.concat(a)}fa.generate=DBe;function SS(t,e,r){let i=$Y(t);return"."in i?[xS(".",t,e,r)]:eq(i,e,r)}fa.convertPatternsToTasks=SS;function XY(t){return Ll.pattern.getPositivePatterns(t)}fa.getPositivePatterns=XY;function ZY(t,e){return Ll.pattern.getNegativePatterns(t).concat(e).map(Ll.pattern.convertToPositivePattern)}fa.getNegativePatternsAsPositive=ZY;function $Y(t){let e={};return t.reduce((r,i)=>{let n=Ll.pattern.getBaseDirectory(i);return n in r?r[n].push(i):r[n]=[i],r},e)}fa.groupPatternsByBaseDirectory=$Y;function eq(t,e,r){return Object.keys(t).map(i=>xS(i,t[i],e,r))}fa.convertPatternGroupsToTasks=eq;function xS(t,e,r,i){return{dynamic:i,positive:e,negative:r,base:t,patterns:[].concat(e,r.map(Ll.pattern.convertToNegativePattern))}}fa.convertPatternGroupToTask=xS});var iq=E(_I=>{"use strict";Object.defineProperty(_I,"__esModule",{value:!0});_I.read=void 0;function RBe(t,e,r){e.fs.lstat(t,(i,n)=>{if(i!==null){rq(r,i);return}if(!n.isSymbolicLink()||!e.followSymbolicLink){kS(r,n);return}e.fs.stat(t,(s,o)=>{if(s!==null){if(e.throwErrorOnBrokenSymbolicLink){rq(r,s);return}kS(r,n);return}e.markSymbolicLink&&(o.isSymbolicLink=()=>!0),kS(r,o)})})}_I.read=RBe;function rq(t,e){t(e)}function kS(t,e){t(null,e)}});var nq=E(XI=>{"use strict";Object.defineProperty(XI,"__esModule",{value:!0});XI.read=void 0;function FBe(t,e){let r=e.fs.lstatSync(t);if(!r.isSymbolicLink()||!e.followSymbolicLink)return r;try{let i=e.fs.statSync(t);return e.markSymbolicLink&&(i.isSymbolicLink=()=>!0),i}catch(i){if(!e.throwErrorOnBrokenSymbolicLink)return r;throw i}}XI.read=FBe});var sq=E(AA=>{"use strict";Object.defineProperty(AA,"__esModule",{value:!0});AA.createFileSystemAdapter=AA.FILE_SYSTEM_ADAPTER=void 0;var ZI=require("fs");AA.FILE_SYSTEM_ADAPTER={lstat:ZI.lstat,stat:ZI.stat,lstatSync:ZI.lstatSync,statSync:ZI.statSync};function NBe(t){return t===void 0?AA.FILE_SYSTEM_ADAPTER:Object.assign(Object.assign({},AA.FILE_SYSTEM_ADAPTER),t)}AA.createFileSystemAdapter=NBe});var aq=E(PS=>{"use strict";Object.defineProperty(PS,"__esModule",{value:!0});var LBe=sq(),oq=class{constructor(e={}){this._options=e,this.followSymbolicLink=this._getValue(this._options.followSymbolicLink,!0),this.fs=LBe.createFileSystemAdapter(this._options.fs),this.markSymbolicLink=this._getValue(this._options.markSymbolicLink,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!0)}_getValue(e,r){return e!=null?e:r}};PS.default=oq});var Tl=E(lA=>{"use strict";Object.defineProperty(lA,"__esModule",{value:!0});lA.statSync=lA.stat=lA.Settings=void 0;var Aq=iq(),TBe=nq(),DS=aq();lA.Settings=DS.default;function MBe(t,e,r){if(typeof e=="function"){Aq.read(t,RS(),e);return}Aq.read(t,RS(e),r)}lA.stat=MBe;function OBe(t,e){let r=RS(e);return TBe.read(t,r)}lA.statSync=OBe;function RS(t={}){return t instanceof DS.default?t:new DS.default(t)}});var cq=E((iit,lq)=>{lq.exports=KBe;function KBe(t,e){var r,i,n,s=!0;Array.isArray(t)?(r=[],i=t.length):(n=Object.keys(t),r={},i=n.length);function o(l){function c(){e&&e(l,r),e=null}s?process.nextTick(c):c()}function a(l,c,u){r[l]=u,(--i==0||c)&&o(c)}i?n?n.forEach(function(l){t[l](function(c,u){a(l,c,u)})}):t.forEach(function(l,c){l(function(u,g){a(c,u,g)})}):o(null),s=!1}});var FS=E($I=>{"use strict";Object.defineProperty($I,"__esModule",{value:!0});$I.IS_SUPPORT_READDIR_WITH_FILE_TYPES=void 0;var ey=process.versions.node.split(".");if(ey[0]===void 0||ey[1]===void 0)throw new Error(`Unexpected behavior. The 'process.versions.node' variable has invalid value: ${process.versions.node}`);var uq=Number.parseInt(ey[0],10),UBe=Number.parseInt(ey[1],10),gq=10,HBe=10,GBe=uq>gq,jBe=uq===gq&&UBe>=HBe;$I.IS_SUPPORT_READDIR_WITH_FILE_TYPES=GBe||jBe});var hq=E(ty=>{"use strict";Object.defineProperty(ty,"__esModule",{value:!0});ty.createDirentFromStats=void 0;var fq=class{constructor(e,r){this.name=e,this.isBlockDevice=r.isBlockDevice.bind(r),this.isCharacterDevice=r.isCharacterDevice.bind(r),this.isDirectory=r.isDirectory.bind(r),this.isFIFO=r.isFIFO.bind(r),this.isFile=r.isFile.bind(r),this.isSocket=r.isSocket.bind(r),this.isSymbolicLink=r.isSymbolicLink.bind(r)}};function YBe(t,e){return new fq(t,e)}ty.createDirentFromStats=YBe});var NS=E(ry=>{"use strict";Object.defineProperty(ry,"__esModule",{value:!0});ry.fs=void 0;var qBe=hq();ry.fs=qBe});var LS=E(iy=>{"use strict";Object.defineProperty(iy,"__esModule",{value:!0});iy.joinPathSegments=void 0;function JBe(t,e,r){return t.endsWith(r)?t+e:t+r+e}iy.joinPathSegments=JBe});var Iq=E(cA=>{"use strict";Object.defineProperty(cA,"__esModule",{value:!0});cA.readdir=cA.readdirWithFileTypes=cA.read=void 0;var WBe=Tl(),pq=cq(),zBe=FS(),dq=NS(),Cq=LS();function VBe(t,e,r){if(!e.stats&&zBe.IS_SUPPORT_READDIR_WITH_FILE_TYPES){mq(t,e,r);return}Eq(t,e,r)}cA.read=VBe;function mq(t,e,r){e.fs.readdir(t,{withFileTypes:!0},(i,n)=>{if(i!==null){ny(r,i);return}let s=n.map(a=>({dirent:a,name:a.name,path:Cq.joinPathSegments(t,a.name,e.pathSegmentSeparator)}));if(!e.followSymbolicLinks){TS(r,s);return}let o=s.map(a=>_Be(a,e));pq(o,(a,l)=>{if(a!==null){ny(r,a);return}TS(r,l)})})}cA.readdirWithFileTypes=mq;function _Be(t,e){return r=>{if(!t.dirent.isSymbolicLink()){r(null,t);return}e.fs.stat(t.path,(i,n)=>{if(i!==null){if(e.throwErrorOnBrokenSymbolicLink){r(i);return}r(null,t);return}t.dirent=dq.fs.createDirentFromStats(t.name,n),r(null,t)})}}function Eq(t,e,r){e.fs.readdir(t,(i,n)=>{if(i!==null){ny(r,i);return}let s=n.map(o=>{let a=Cq.joinPathSegments(t,o,e.pathSegmentSeparator);return l=>{WBe.stat(a,e.fsStatSettings,(c,u)=>{if(c!==null){l(c);return}let g={name:o,path:a,dirent:dq.fs.createDirentFromStats(o,u)};e.stats&&(g.stats=u),l(null,g)})}});pq(s,(o,a)=>{if(o!==null){ny(r,o);return}TS(r,a)})})}cA.readdir=Eq;function ny(t,e){t(e)}function TS(t,e){t(null,e)}});var bq=E(uA=>{"use strict";Object.defineProperty(uA,"__esModule",{value:!0});uA.readdir=uA.readdirWithFileTypes=uA.read=void 0;var XBe=Tl(),ZBe=FS(),yq=NS(),wq=LS();function $Be(t,e){return!e.stats&&ZBe.IS_SUPPORT_READDIR_WITH_FILE_TYPES?Bq(t,e):Qq(t,e)}uA.read=$Be;function Bq(t,e){return e.fs.readdirSync(t,{withFileTypes:!0}).map(i=>{let n={dirent:i,name:i.name,path:wq.joinPathSegments(t,i.name,e.pathSegmentSeparator)};if(n.dirent.isSymbolicLink()&&e.followSymbolicLinks)try{let s=e.fs.statSync(n.path);n.dirent=yq.fs.createDirentFromStats(n.name,s)}catch(s){if(e.throwErrorOnBrokenSymbolicLink)throw s}return n})}uA.readdirWithFileTypes=Bq;function Qq(t,e){return e.fs.readdirSync(t).map(i=>{let n=wq.joinPathSegments(t,i,e.pathSegmentSeparator),s=XBe.statSync(n,e.fsStatSettings),o={name:i,path:n,dirent:yq.fs.createDirentFromStats(i,s)};return e.stats&&(o.stats=s),o})}uA.readdir=Qq});var vq=E(gA=>{"use strict";Object.defineProperty(gA,"__esModule",{value:!0});gA.createFileSystemAdapter=gA.FILE_SYSTEM_ADAPTER=void 0;var Du=require("fs");gA.FILE_SYSTEM_ADAPTER={lstat:Du.lstat,stat:Du.stat,lstatSync:Du.lstatSync,statSync:Du.statSync,readdir:Du.readdir,readdirSync:Du.readdirSync};function e0e(t){return t===void 0?gA.FILE_SYSTEM_ADAPTER:Object.assign(Object.assign({},gA.FILE_SYSTEM_ADAPTER),t)}gA.createFileSystemAdapter=e0e});var xq=E(MS=>{"use strict";Object.defineProperty(MS,"__esModule",{value:!0});var t0e=require("path"),r0e=Tl(),i0e=vq(),Sq=class{constructor(e={}){this._options=e,this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,!1),this.fs=i0e.createFileSystemAdapter(this._options.fs),this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,t0e.sep),this.stats=this._getValue(this._options.stats,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!0),this.fsStatSettings=new r0e.Settings({followSymbolicLink:this.followSymbolicLinks,fs:this.fs,throwErrorOnBrokenSymbolicLink:this.throwErrorOnBrokenSymbolicLink})}_getValue(e,r){return e!=null?e:r}};MS.default=Sq});var sy=E(fA=>{"use strict";Object.defineProperty(fA,"__esModule",{value:!0});fA.Settings=fA.scandirSync=fA.scandir=void 0;var kq=Iq(),n0e=bq(),OS=xq();fA.Settings=OS.default;function s0e(t,e,r){if(typeof e=="function"){kq.read(t,KS(),e);return}kq.read(t,KS(e),r)}fA.scandir=s0e;function o0e(t,e){let r=KS(e);return n0e.read(t,r)}fA.scandirSync=o0e;function KS(t={}){return t instanceof OS.default?t:new OS.default(t)}});var Dq=E((fit,Pq)=>{"use strict";function a0e(t){var e=new t,r=e;function i(){var s=e;return s.next?e=s.next:(e=new t,r=e),s.next=null,s}function n(s){r.next=s,r=s}return{get:i,release:n}}Pq.exports=a0e});var Fq=E((hit,US)=>{"use strict";var A0e=Dq();function Rq(t,e,r){if(typeof t=="function"&&(r=e,e=t,t=null),r<1)throw new Error("fastqueue concurrency must be greater than 1");var i=A0e(l0e),n=null,s=null,o=0,a=null,l={push:d,drain:po,saturated:po,pause:u,paused:!1,concurrency:r,running:c,resume:h,idle:p,length:g,getQueue:f,unshift:m,empty:po,kill:B,killAndDrain:b,error:R};return l;function c(){return o}function u(){l.paused=!0}function g(){for(var H=n,L=0;H;)H=H.next,L++;return L}function f(){for(var H=n,L=[];H;)L.push(H.value),H=H.next;return L}function h(){if(!!l.paused){l.paused=!1;for(var H=0;H{"use strict";Object.defineProperty(Co,"__esModule",{value:!0});Co.joinPathSegments=Co.replacePathSegmentSeparator=Co.isAppliedFilter=Co.isFatalError=void 0;function u0e(t,e){return t.errorFilter===null?!0:!t.errorFilter(e)}Co.isFatalError=u0e;function g0e(t,e){return t===null||t(e)}Co.isAppliedFilter=g0e;function f0e(t,e){return t.split(/[/\\]/).join(e)}Co.replacePathSegmentSeparator=f0e;function h0e(t,e,r){return t===""?e:t.endsWith(r)?t+e:t+r+e}Co.joinPathSegments=h0e});var GS=E(HS=>{"use strict";Object.defineProperty(HS,"__esModule",{value:!0});var p0e=oy(),Nq=class{constructor(e,r){this._root=e,this._settings=r,this._root=p0e.replacePathSegmentSeparator(e,r.pathSegmentSeparator)}};HS.default=Nq});var YS=E(jS=>{"use strict";Object.defineProperty(jS,"__esModule",{value:!0});var d0e=require("events"),C0e=sy(),m0e=Fq(),ay=oy(),E0e=GS(),Lq=class extends E0e.default{constructor(e,r){super(e,r);this._settings=r,this._scandir=C0e.scandir,this._emitter=new d0e.EventEmitter,this._queue=m0e(this._worker.bind(this),this._settings.concurrency),this._isFatalError=!1,this._isDestroyed=!1,this._queue.drain=()=>{this._isFatalError||this._emitter.emit("end")}}read(){return this._isFatalError=!1,this._isDestroyed=!1,setImmediate(()=>{this._pushToQueue(this._root,this._settings.basePath)}),this._emitter}get isDestroyed(){return this._isDestroyed}destroy(){if(this._isDestroyed)throw new Error("The reader is already destroyed");this._isDestroyed=!0,this._queue.killAndDrain()}onEntry(e){this._emitter.on("entry",e)}onError(e){this._emitter.once("error",e)}onEnd(e){this._emitter.once("end",e)}_pushToQueue(e,r){let i={directory:e,base:r};this._queue.push(i,n=>{n!==null&&this._handleError(n)})}_worker(e,r){this._scandir(e.directory,this._settings.fsScandirSettings,(i,n)=>{if(i!==null){r(i,void 0);return}for(let s of n)this._handleEntry(s,e.base);r(null,void 0)})}_handleError(e){this._isDestroyed||!ay.isFatalError(this._settings,e)||(this._isFatalError=!0,this._isDestroyed=!0,this._emitter.emit("error",e))}_handleEntry(e,r){if(this._isDestroyed||this._isFatalError)return;let i=e.path;r!==void 0&&(e.path=ay.joinPathSegments(r,e.name,this._settings.pathSegmentSeparator)),ay.isAppliedFilter(this._settings.entryFilter,e)&&this._emitEntry(e),e.dirent.isDirectory()&&ay.isAppliedFilter(this._settings.deepFilter,e)&&this._pushToQueue(i,e.path)}_emitEntry(e){this._emitter.emit("entry",e)}};jS.default=Lq});var Mq=E(qS=>{"use strict";Object.defineProperty(qS,"__esModule",{value:!0});var I0e=YS(),Tq=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new I0e.default(this._root,this._settings),this._storage=new Set}read(e){this._reader.onError(r=>{y0e(e,r)}),this._reader.onEntry(r=>{this._storage.add(r)}),this._reader.onEnd(()=>{w0e(e,[...this._storage])}),this._reader.read()}};qS.default=Tq;function y0e(t,e){t(e)}function w0e(t,e){t(null,e)}});var Kq=E(JS=>{"use strict";Object.defineProperty(JS,"__esModule",{value:!0});var B0e=require("stream"),Q0e=YS(),Oq=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new Q0e.default(this._root,this._settings),this._stream=new B0e.Readable({objectMode:!0,read:()=>{},destroy:()=>{this._reader.isDestroyed||this._reader.destroy()}})}read(){return this._reader.onError(e=>{this._stream.emit("error",e)}),this._reader.onEntry(e=>{this._stream.push(e)}),this._reader.onEnd(()=>{this._stream.push(null)}),this._reader.read(),this._stream}};JS.default=Oq});var Hq=E(WS=>{"use strict";Object.defineProperty(WS,"__esModule",{value:!0});var b0e=sy(),Ay=oy(),v0e=GS(),Uq=class extends v0e.default{constructor(){super(...arguments);this._scandir=b0e.scandirSync,this._storage=new Set,this._queue=new Set}read(){return this._pushToQueue(this._root,this._settings.basePath),this._handleQueue(),[...this._storage]}_pushToQueue(e,r){this._queue.add({directory:e,base:r})}_handleQueue(){for(let e of this._queue.values())this._handleDirectory(e.directory,e.base)}_handleDirectory(e,r){try{let i=this._scandir(e,this._settings.fsScandirSettings);for(let n of i)this._handleEntry(n,r)}catch(i){this._handleError(i)}}_handleError(e){if(!!Ay.isFatalError(this._settings,e))throw e}_handleEntry(e,r){let i=e.path;r!==void 0&&(e.path=Ay.joinPathSegments(r,e.name,this._settings.pathSegmentSeparator)),Ay.isAppliedFilter(this._settings.entryFilter,e)&&this._pushToStorage(e),e.dirent.isDirectory()&&Ay.isAppliedFilter(this._settings.deepFilter,e)&&this._pushToQueue(i,e.path)}_pushToStorage(e){this._storage.add(e)}};WS.default=Uq});var jq=E(zS=>{"use strict";Object.defineProperty(zS,"__esModule",{value:!0});var S0e=Hq(),Gq=class{constructor(e,r){this._root=e,this._settings=r,this._reader=new S0e.default(this._root,this._settings)}read(){return this._reader.read()}};zS.default=Gq});var qq=E(VS=>{"use strict";Object.defineProperty(VS,"__esModule",{value:!0});var x0e=require("path"),k0e=sy(),Yq=class{constructor(e={}){this._options=e,this.basePath=this._getValue(this._options.basePath,void 0),this.concurrency=this._getValue(this._options.concurrency,Number.POSITIVE_INFINITY),this.deepFilter=this._getValue(this._options.deepFilter,null),this.entryFilter=this._getValue(this._options.entryFilter,null),this.errorFilter=this._getValue(this._options.errorFilter,null),this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,x0e.sep),this.fsScandirSettings=new k0e.Settings({followSymbolicLinks:this._options.followSymbolicLinks,fs:this._options.fs,pathSegmentSeparator:this._options.pathSegmentSeparator,stats:this._options.stats,throwErrorOnBrokenSymbolicLink:this._options.throwErrorOnBrokenSymbolicLink})}_getValue(e,r){return e!=null?e:r}};VS.default=Yq});var XS=E(mo=>{"use strict";Object.defineProperty(mo,"__esModule",{value:!0});mo.Settings=mo.walkStream=mo.walkSync=mo.walk=void 0;var Jq=Mq(),P0e=Kq(),D0e=jq(),_S=qq();mo.Settings=_S.default;function R0e(t,e,r){if(typeof e=="function"){new Jq.default(t,ly()).read(e);return}new Jq.default(t,ly(e)).read(r)}mo.walk=R0e;function F0e(t,e){let r=ly(e);return new D0e.default(t,r).read()}mo.walkSync=F0e;function N0e(t,e){let r=ly(e);return new P0e.default(t,r).read()}mo.walkStream=N0e;function ly(t={}){return t instanceof _S.default?t:new _S.default(t)}});var $S=E(ZS=>{"use strict";Object.defineProperty(ZS,"__esModule",{value:!0});var L0e=require("path"),T0e=Tl(),Wq=ga(),zq=class{constructor(e){this._settings=e,this._fsStatSettings=new T0e.Settings({followSymbolicLink:this._settings.followSymbolicLinks,fs:this._settings.fs,throwErrorOnBrokenSymbolicLink:this._settings.followSymbolicLinks})}_getFullEntryPath(e){return L0e.resolve(this._settings.cwd,e)}_makeEntry(e,r){let i={name:r,path:r,dirent:Wq.fs.createDirentFromStats(r,e)};return this._settings.stats&&(i.stats=e),i}_isFatalError(e){return!Wq.errno.isEnoentCodeError(e)&&!this._settings.suppressErrors}};ZS.default=zq});var tx=E(ex=>{"use strict";Object.defineProperty(ex,"__esModule",{value:!0});var M0e=require("stream"),O0e=Tl(),K0e=XS(),U0e=$S(),Vq=class extends U0e.default{constructor(){super(...arguments);this._walkStream=K0e.walkStream,this._stat=O0e.stat}dynamic(e,r){return this._walkStream(e,r)}static(e,r){let i=e.map(this._getFullEntryPath,this),n=new M0e.PassThrough({objectMode:!0});n._write=(s,o,a)=>this._getEntry(i[s],e[s],r).then(l=>{l!==null&&r.entryFilter(l)&&n.push(l),s===i.length-1&&n.end(),a()}).catch(a);for(let s=0;sthis._makeEntry(n,r)).catch(n=>{if(i.errorFilter(n))return null;throw n})}_getStat(e){return new Promise((r,i)=>{this._stat(e,this._fsStatSettings,(n,s)=>n===null?r(s):i(n))})}};ex.default=Vq});var Xq=E(rx=>{"use strict";Object.defineProperty(rx,"__esModule",{value:!0});var Ru=ga(),_q=class{constructor(e,r,i){this._patterns=e,this._settings=r,this._micromatchOptions=i,this._storage=[],this._fillStorage()}_fillStorage(){let e=Ru.pattern.expandPatternsWithBraceExpansion(this._patterns);for(let r of e){let i=this._getPatternSegments(r),n=this._splitSegmentsIntoSections(i);this._storage.push({complete:n.length<=1,pattern:r,segments:i,sections:n})}}_getPatternSegments(e){return Ru.pattern.getPatternParts(e,this._micromatchOptions).map(i=>Ru.pattern.isDynamicPattern(i,this._settings)?{dynamic:!0,pattern:i,patternRe:Ru.pattern.makeRe(i,this._micromatchOptions)}:{dynamic:!1,pattern:i})}_splitSegmentsIntoSections(e){return Ru.array.splitWhen(e,r=>r.dynamic&&Ru.pattern.hasGlobStar(r.pattern))}};rx.default=_q});var $q=E(ix=>{"use strict";Object.defineProperty(ix,"__esModule",{value:!0});var H0e=Xq(),Zq=class extends H0e.default{match(e){let r=e.split("/"),i=r.length,n=this._storage.filter(s=>!s.complete||s.segments.length>i);for(let s of n){let o=s.sections[0];if(!s.complete&&i>o.length||r.every((l,c)=>{let u=s.segments[c];return!!(u.dynamic&&u.patternRe.test(l)||!u.dynamic&&u.pattern===l)}))return!0}return!1}};ix.default=Zq});var tJ=E(nx=>{"use strict";Object.defineProperty(nx,"__esModule",{value:!0});var cy=ga(),G0e=$q(),eJ=class{constructor(e,r){this._settings=e,this._micromatchOptions=r}getFilter(e,r,i){let n=this._getMatcher(r),s=this._getNegativePatternsRe(i);return o=>this._filter(e,o,n,s)}_getMatcher(e){return new G0e.default(e,this._settings,this._micromatchOptions)}_getNegativePatternsRe(e){let r=e.filter(cy.pattern.isAffectDepthOfReadingPattern);return cy.pattern.convertPatternsToRe(r,this._micromatchOptions)}_filter(e,r,i,n){let s=this._getEntryLevel(e,r.path);if(this._isSkippedByDeep(s)||this._isSkippedSymbolicLink(r))return!1;let o=cy.path.removeLeadingDotSegment(r.path);return this._isSkippedByPositivePatterns(o,i)?!1:this._isSkippedByNegativePatterns(o,n)}_isSkippedByDeep(e){return e>=this._settings.deep}_isSkippedSymbolicLink(e){return!this._settings.followSymbolicLinks&&e.dirent.isSymbolicLink()}_getEntryLevel(e,r){let i=e.split("/").length;return r.split("/").length-(e===""?0:i)}_isSkippedByPositivePatterns(e,r){return!this._settings.baseNameMatch&&!r.match(e)}_isSkippedByNegativePatterns(e,r){return!cy.pattern.matchAny(e,r)}};nx.default=eJ});var iJ=E(sx=>{"use strict";Object.defineProperty(sx,"__esModule",{value:!0});var ip=ga(),rJ=class{constructor(e,r){this._settings=e,this._micromatchOptions=r,this.index=new Map}getFilter(e,r){let i=ip.pattern.convertPatternsToRe(e,this._micromatchOptions),n=ip.pattern.convertPatternsToRe(r,this._micromatchOptions);return s=>this._filter(s,i,n)}_filter(e,r,i){if(this._settings.unique){if(this._isDuplicateEntry(e))return!1;this._createIndexRecord(e)}if(this._onlyFileFilter(e)||this._onlyDirectoryFilter(e)||this._isSkippedByAbsoluteNegativePatterns(e,i))return!1;let n=this._settings.baseNameMatch?e.name:e.path;return this._isMatchToPatterns(n,r)&&!this._isMatchToPatterns(e.path,i)}_isDuplicateEntry(e){return this.index.has(e.path)}_createIndexRecord(e){this.index.set(e.path,void 0)}_onlyFileFilter(e){return this._settings.onlyFiles&&!e.dirent.isFile()}_onlyDirectoryFilter(e){return this._settings.onlyDirectories&&!e.dirent.isDirectory()}_isSkippedByAbsoluteNegativePatterns(e,r){if(!this._settings.absolute)return!1;let i=ip.path.makeAbsolute(this._settings.cwd,e.path);return this._isMatchToPatterns(i,r)}_isMatchToPatterns(e,r){let i=ip.path.removeLeadingDotSegment(e);return ip.pattern.matchAny(i,r)}};sx.default=rJ});var sJ=E(ox=>{"use strict";Object.defineProperty(ox,"__esModule",{value:!0});var j0e=ga(),nJ=class{constructor(e){this._settings=e}getFilter(){return e=>this._isNonFatalError(e)}_isNonFatalError(e){return j0e.errno.isEnoentCodeError(e)||this._settings.suppressErrors}};ox.default=nJ});var AJ=E(ax=>{"use strict";Object.defineProperty(ax,"__esModule",{value:!0});var oJ=ga(),aJ=class{constructor(e){this._settings=e}getTransformer(){return e=>this._transform(e)}_transform(e){let r=e.path;return this._settings.absolute&&(r=oJ.path.makeAbsolute(this._settings.cwd,r),r=oJ.path.unixify(r)),this._settings.markDirectories&&e.dirent.isDirectory()&&(r+="/"),this._settings.objectMode?Object.assign(Object.assign({},e),{path:r}):r}};ax.default=aJ});var uy=E(Ax=>{"use strict";Object.defineProperty(Ax,"__esModule",{value:!0});var Y0e=require("path"),q0e=tJ(),J0e=iJ(),W0e=sJ(),z0e=AJ(),lJ=class{constructor(e){this._settings=e,this.errorFilter=new W0e.default(this._settings),this.entryFilter=new J0e.default(this._settings,this._getMicromatchOptions()),this.deepFilter=new q0e.default(this._settings,this._getMicromatchOptions()),this.entryTransformer=new z0e.default(this._settings)}_getRootDirectory(e){return Y0e.resolve(this._settings.cwd,e.base)}_getReaderOptions(e){let r=e.base==="."?"":e.base;return{basePath:r,pathSegmentSeparator:"/",concurrency:this._settings.concurrency,deepFilter:this.deepFilter.getFilter(r,e.positive,e.negative),entryFilter:this.entryFilter.getFilter(e.positive,e.negative),errorFilter:this.errorFilter.getFilter(),followSymbolicLinks:this._settings.followSymbolicLinks,fs:this._settings.fs,stats:this._settings.stats,throwErrorOnBrokenSymbolicLink:this._settings.throwErrorOnBrokenSymbolicLink,transform:this.entryTransformer.getTransformer()}}_getMicromatchOptions(){return{dot:this._settings.dot,matchBase:this._settings.baseNameMatch,nobrace:!this._settings.braceExpansion,nocase:!this._settings.caseSensitiveMatch,noext:!this._settings.extglob,noglobstar:!this._settings.globstar,posix:!0,strictSlashes:!1}}};Ax.default=lJ});var uJ=E(lx=>{"use strict";Object.defineProperty(lx,"__esModule",{value:!0});var V0e=tx(),_0e=uy(),cJ=class extends _0e.default{constructor(){super(...arguments);this._reader=new V0e.default(this._settings)}read(e){let r=this._getRootDirectory(e),i=this._getReaderOptions(e),n=[];return new Promise((s,o)=>{let a=this.api(r,e,i);a.once("error",o),a.on("data",l=>n.push(i.transform(l))),a.once("end",()=>s(n))})}api(e,r,i){return r.dynamic?this._reader.dynamic(e,i):this._reader.static(r.patterns,i)}};lx.default=cJ});var fJ=E(cx=>{"use strict";Object.defineProperty(cx,"__esModule",{value:!0});var X0e=require("stream"),Z0e=tx(),$0e=uy(),gJ=class extends $0e.default{constructor(){super(...arguments);this._reader=new Z0e.default(this._settings)}read(e){let r=this._getRootDirectory(e),i=this._getReaderOptions(e),n=this.api(r,e,i),s=new X0e.Readable({objectMode:!0,read:()=>{}});return n.once("error",o=>s.emit("error",o)).on("data",o=>s.emit("data",i.transform(o))).once("end",()=>s.emit("end")),s.once("close",()=>n.destroy()),s}api(e,r,i){return r.dynamic?this._reader.dynamic(e,i):this._reader.static(r.patterns,i)}};cx.default=gJ});var pJ=E(ux=>{"use strict";Object.defineProperty(ux,"__esModule",{value:!0});var eQe=Tl(),tQe=XS(),rQe=$S(),hJ=class extends rQe.default{constructor(){super(...arguments);this._walkSync=tQe.walkSync,this._statSync=eQe.statSync}dynamic(e,r){return this._walkSync(e,r)}static(e,r){let i=[];for(let n of e){let s=this._getFullEntryPath(n),o=this._getEntry(s,n,r);o===null||!r.entryFilter(o)||i.push(o)}return i}_getEntry(e,r,i){try{let n=this._getStat(e);return this._makeEntry(n,r)}catch(n){if(i.errorFilter(n))return null;throw n}}_getStat(e){return this._statSync(e,this._fsStatSettings)}};ux.default=hJ});var CJ=E(gx=>{"use strict";Object.defineProperty(gx,"__esModule",{value:!0});var iQe=pJ(),nQe=uy(),dJ=class extends nQe.default{constructor(){super(...arguments);this._reader=new iQe.default(this._settings)}read(e){let r=this._getRootDirectory(e),i=this._getReaderOptions(e);return this.api(r,e,i).map(i.transform)}api(e,r,i){return r.dynamic?this._reader.dynamic(e,i):this._reader.static(r.patterns,i)}};gx.default=dJ});var EJ=E(np=>{"use strict";Object.defineProperty(np,"__esModule",{value:!0});var Fu=require("fs"),sQe=require("os"),oQe=sQe.cpus().length;np.DEFAULT_FILE_SYSTEM_ADAPTER={lstat:Fu.lstat,lstatSync:Fu.lstatSync,stat:Fu.stat,statSync:Fu.statSync,readdir:Fu.readdir,readdirSync:Fu.readdirSync};var mJ=class{constructor(e={}){this._options=e,this.absolute=this._getValue(this._options.absolute,!1),this.baseNameMatch=this._getValue(this._options.baseNameMatch,!1),this.braceExpansion=this._getValue(this._options.braceExpansion,!0),this.caseSensitiveMatch=this._getValue(this._options.caseSensitiveMatch,!0),this.concurrency=this._getValue(this._options.concurrency,oQe),this.cwd=this._getValue(this._options.cwd,process.cwd()),this.deep=this._getValue(this._options.deep,Infinity),this.dot=this._getValue(this._options.dot,!1),this.extglob=this._getValue(this._options.extglob,!0),this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,!0),this.fs=this._getFileSystemMethods(this._options.fs),this.globstar=this._getValue(this._options.globstar,!0),this.ignore=this._getValue(this._options.ignore,[]),this.markDirectories=this._getValue(this._options.markDirectories,!1),this.objectMode=this._getValue(this._options.objectMode,!1),this.onlyDirectories=this._getValue(this._options.onlyDirectories,!1),this.onlyFiles=this._getValue(this._options.onlyFiles,!0),this.stats=this._getValue(this._options.stats,!1),this.suppressErrors=this._getValue(this._options.suppressErrors,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!1),this.unique=this._getValue(this._options.unique,!0),this.onlyDirectories&&(this.onlyFiles=!1),this.stats&&(this.objectMode=!0)}_getValue(e,r){return e===void 0?r:e}_getFileSystemMethods(e={}){return Object.assign(Object.assign({},np.DEFAULT_FILE_SYSTEM_ADAPTER),e)}};np.default=mJ});var gy=E((Oit,IJ)=>{"use strict";var yJ=tq(),aQe=uJ(),AQe=fJ(),lQe=CJ(),fx=EJ(),Ml=ga();async function px(t,e){Nu(t);let r=hx(t,aQe.default,e),i=await Promise.all(r);return Ml.array.flatten(i)}(function(t){function e(o,a){Nu(o);let l=hx(o,lQe.default,a);return Ml.array.flatten(l)}t.sync=e;function r(o,a){Nu(o);let l=hx(o,AQe.default,a);return Ml.stream.merge(l)}t.stream=r;function i(o,a){Nu(o);let l=[].concat(o),c=new fx.default(a);return yJ.generate(l,c)}t.generateTasks=i;function n(o,a){Nu(o);let l=new fx.default(a);return Ml.pattern.isDynamicPattern(o,l)}t.isDynamicPattern=n;function s(o){return Nu(o),Ml.path.escape(o)}t.escapePath=s})(px||(px={}));function hx(t,e,r){let i=[].concat(t),n=new fx.default(r),s=yJ.generate(i,n),o=new e(n);return s.map(o.read,o)}function Nu(t){if(![].concat(t).every(i=>Ml.string.isString(i)&&!Ml.string.isEmpty(i)))throw new TypeError("Patterns must be a string (non empty) or an array of strings")}IJ.exports=px});var BJ=E(Ol=>{"use strict";var{promisify:cQe}=require("util"),wJ=require("fs");async function dx(t,e,r){if(typeof r!="string")throw new TypeError(`Expected a string, got ${typeof r}`);try{return(await cQe(wJ[t])(r))[e]()}catch(i){if(i.code==="ENOENT")return!1;throw i}}function Cx(t,e,r){if(typeof r!="string")throw new TypeError(`Expected a string, got ${typeof r}`);try{return wJ[t](r)[e]()}catch(i){if(i.code==="ENOENT")return!1;throw i}}Ol.isFile=dx.bind(null,"stat","isFile");Ol.isDirectory=dx.bind(null,"stat","isDirectory");Ol.isSymlink=dx.bind(null,"lstat","isSymbolicLink");Ol.isFileSync=Cx.bind(null,"statSync","isFile");Ol.isDirectorySync=Cx.bind(null,"statSync","isDirectory");Ol.isSymlinkSync=Cx.bind(null,"lstatSync","isSymbolicLink")});var xJ=E((Uit,mx)=>{"use strict";var Kl=require("path"),QJ=BJ(),bJ=t=>t.length>1?`{${t.join(",")}}`:t[0],vJ=(t,e)=>{let r=t[0]==="!"?t.slice(1):t;return Kl.isAbsolute(r)?r:Kl.join(e,r)},uQe=(t,e)=>Kl.extname(t)?`**/${t}`:`**/${t}.${bJ(e)}`,SJ=(t,e)=>{if(e.files&&!Array.isArray(e.files))throw new TypeError(`Expected \`files\` to be of type \`Array\` but received type \`${typeof e.files}\``);if(e.extensions&&!Array.isArray(e.extensions))throw new TypeError(`Expected \`extensions\` to be of type \`Array\` but received type \`${typeof e.extensions}\``);return e.files&&e.extensions?e.files.map(r=>Kl.posix.join(t,uQe(r,e.extensions))):e.files?e.files.map(r=>Kl.posix.join(t,`**/${r}`)):e.extensions?[Kl.posix.join(t,`**/*.${bJ(e.extensions)}`)]:[Kl.posix.join(t,"**")]};mx.exports=async(t,e)=>{if(e=P({cwd:process.cwd()},e),typeof e.cwd!="string")throw new TypeError(`Expected \`cwd\` to be of type \`string\` but received type \`${typeof e.cwd}\``);let r=await Promise.all([].concat(t).map(async i=>await QJ.isDirectory(vJ(i,e.cwd))?SJ(i,e):i));return[].concat.apply([],r)};mx.exports.sync=(t,e)=>{if(e=P({cwd:process.cwd()},e),typeof e.cwd!="string")throw new TypeError(`Expected \`cwd\` to be of type \`string\` but received type \`${typeof e.cwd}\``);let r=[].concat(t).map(i=>QJ.isDirectorySync(vJ(i,e.cwd))?SJ(i,e):i);return[].concat.apply([],r)}});var TJ=E((Hit,kJ)=>{function PJ(t){return Array.isArray(t)?t:[t]}var gQe=/^\s+$/,fQe=/^\\!/,hQe=/^\\#/,pQe=/\r?\n/g,dQe=/^\.*\/|^\.+$/,Ex="/",DJ=typeof Symbol!="undefined"?Symbol.for("node-ignore"):"node-ignore",CQe=(t,e,r)=>Object.defineProperty(t,e,{value:r}),mQe=/([0-z])-([0-z])/g,EQe=t=>t.replace(mQe,(e,r,i)=>r.charCodeAt(0)<=i.charCodeAt(0)?e:""),IQe=[[/\\?\s+$/,t=>t.indexOf("\\")===0?" ":""],[/\\\s/g,()=>" "],[/[\\^$.|*+(){]/g,t=>`\\${t}`],[/\[([^\]/]*)($|\])/g,(t,e,r)=>r==="]"?`[${EQe(e)}]`:`\\${t}`],[/(?!\\)\?/g,()=>"[^/]"],[/^\//,()=>"^"],[/\//g,()=>"\\/"],[/^\^*\\\*\\\*\\\//,()=>"^(?:.*\\/)?"],[/(?:[^*])$/,t=>/\/$/.test(t)?`${t}$`:`${t}(?=$|\\/$)`],[/^(?=[^^])/,function(){return/\/(?!$)/.test(this)?"^":"(?:^|\\/)"}],[/\\\/\\\*\\\*(?=\\\/|$)/g,(t,e,r)=>e+6`${e}[^\\/]*`],[/(\^|\\\/)?\\\*$/,(t,e)=>`${e?`${e}[^/]+`:"[^/]*"}(?=$|\\/$)`],[/\\\\\\/g,()=>"\\"]],RJ=Object.create(null),yQe=(t,e,r)=>{let i=RJ[t];if(i)return i;let n=IQe.reduce((s,o)=>s.replace(o[0],o[1].bind(t)),t);return RJ[t]=r?new RegExp(n,"i"):new RegExp(n)},Ix=t=>typeof t=="string",wQe=t=>t&&Ix(t)&&!gQe.test(t)&&t.indexOf("#")!==0,BQe=t=>t.split(pQe),FJ=class{constructor(e,r,i,n){this.origin=e,this.pattern=r,this.negative=i,this.regex=n}},QQe=(t,e)=>{let r=t,i=!1;t.indexOf("!")===0&&(i=!0,t=t.substr(1)),t=t.replace(fQe,"!").replace(hQe,"#");let n=yQe(t,i,e);return new FJ(r,t,i,n)},bQe=(t,e)=>{throw new e(t)},ha=(t,e,r)=>Ix(t)?t?ha.isNotRelative(t)?r(`path should be a \`path.relative()\`d string, but got "${e}"`,RangeError):!0:r("path must not be empty",TypeError):r(`path must be a string, but got \`${e}\``,TypeError),NJ=t=>dQe.test(t);ha.isNotRelative=NJ;ha.convert=t=>t;var LJ=class{constructor({ignorecase:e=!0}={}){this._rules=[],this._ignorecase=e,CQe(this,DJ,!0),this._initCache()}_initCache(){this._ignoreCache=Object.create(null),this._testCache=Object.create(null)}_addPattern(e){if(e&&e[DJ]){this._rules=this._rules.concat(e._rules),this._added=!0;return}if(wQe(e)){let r=QQe(e,this._ignorecase);this._added=!0,this._rules.push(r)}}add(e){return this._added=!1,PJ(Ix(e)?BQe(e):e).forEach(this._addPattern,this),this._added&&this._initCache(),this}addPattern(e){return this.add(e)}_testOne(e,r){let i=!1,n=!1;return this._rules.forEach(s=>{let{negative:o}=s;if(n===o&&i!==n||o&&!i&&!n&&!r)return;s.regex.test(e)&&(i=!o,n=o)}),{ignored:i,unignored:n}}_test(e,r,i,n){let s=e&&ha.convert(e);return ha(s,e,bQe),this._t(s,r,i,n)}_t(e,r,i,n){if(e in r)return r[e];if(n||(n=e.split(Ex)),n.pop(),!n.length)return r[e]=this._testOne(e,i);let s=this._t(n.join(Ex)+Ex,r,i,n);return r[e]=s.ignored?s:this._testOne(e,i)}ignores(e){return this._test(e,this._ignoreCache,!1).ignored}createFilter(){return e=>!this.ignores(e)}filter(e){return PJ(e).filter(this.createFilter())}test(e){return this._test(e,this._testCache,!0)}},fy=t=>new LJ(t),vQe=()=>!1,SQe=t=>ha(t&&ha.convert(t),t,vQe);fy.isPathValid=SQe;fy.default=fy;kJ.exports=fy;if(typeof process!="undefined"&&(process.env&&process.env.IGNORE_TEST_WIN32||process.platform==="win32")){let t=r=>/^\\\\\?\\/.test(r)||/["<>|\u0000-\u001F]+/u.test(r)?r:r.replace(/\\/g,"/");ha.convert=t;let e=/^[a-z]:\//i;ha.isNotRelative=r=>e.test(r)||NJ(r)}});var OJ=E((Git,MJ)=>{"use strict";MJ.exports=t=>{let e=/^\\\\\?\\/.test(t),r=/[^\u0000-\u0080]+/.test(t);return e||r?t:t.replace(/\\/g,"/")}});var qJ=E((jit,yx)=>{"use strict";var{promisify:xQe}=require("util"),KJ=require("fs"),pa=require("path"),UJ=gy(),kQe=TJ(),sp=OJ(),HJ=["**/node_modules/**","**/flow-typed/**","**/coverage/**","**/.git"],PQe=xQe(KJ.readFile),DQe=t=>e=>e.startsWith("!")?"!"+pa.posix.join(t,e.slice(1)):pa.posix.join(t,e),RQe=(t,e)=>{let r=sp(pa.relative(e.cwd,pa.dirname(e.fileName)));return t.split(/\r?\n/).filter(Boolean).filter(i=>!i.startsWith("#")).map(DQe(r))},GJ=t=>{let e=kQe();for(let r of t)e.add(RQe(r.content,{cwd:r.cwd,fileName:r.filePath}));return e},FQe=(t,e)=>{if(t=sp(t),pa.isAbsolute(e)){if(sp(e).startsWith(t))return e;throw new Error(`Path ${e} is not in cwd ${t}`)}return pa.join(t,e)},jJ=(t,e)=>r=>t.ignores(sp(pa.relative(e,FQe(e,r.path||r)))),NQe=async(t,e)=>{let r=pa.join(e,t),i=await PQe(r,"utf8");return{cwd:e,filePath:r,content:i}},LQe=(t,e)=>{let r=pa.join(e,t),i=KJ.readFileSync(r,"utf8");return{cwd:e,filePath:r,content:i}},YJ=({ignore:t=[],cwd:e=sp(process.cwd())}={})=>({ignore:t,cwd:e});yx.exports=async t=>{t=YJ(t);let e=await UJ("**/.gitignore",{ignore:HJ.concat(t.ignore),cwd:t.cwd}),r=await Promise.all(e.map(n=>NQe(n,t.cwd))),i=GJ(r);return jJ(i,t.cwd)};yx.exports.sync=t=>{t=YJ(t);let r=UJ.sync("**/.gitignore",{ignore:HJ.concat(t.ignore),cwd:t.cwd}).map(n=>LQe(n,t.cwd)),i=GJ(r);return jJ(i,t.cwd)}});var VJ=E((Yit,JJ)=>{"use strict";var{Transform:TQe}=require("stream"),wx=class extends TQe{constructor(){super({objectMode:!0})}},WJ=class extends wx{constructor(e){super();this._filter=e}_transform(e,r,i){this._filter(e)&&this.push(e),i()}},zJ=class extends wx{constructor(){super();this._pushed=new Set}_transform(e,r,i){this._pushed.has(e)||(this.push(e),this._pushed.add(e)),i()}};JJ.exports={FilterStream:WJ,UniqueStream:zJ}});var vx=E((qit,Ul)=>{"use strict";var _J=require("fs"),hy=QY(),MQe=wS(),py=gy(),dy=xJ(),Bx=qJ(),{FilterStream:OQe,UniqueStream:KQe}=VJ(),XJ=()=>!1,ZJ=t=>t[0]==="!",UQe=t=>{if(!t.every(e=>typeof e=="string"))throw new TypeError("Patterns must be a string or an array of strings")},HQe=(t={})=>{if(!t.cwd)return;let e;try{e=_J.statSync(t.cwd)}catch{return}if(!e.isDirectory())throw new Error("The `cwd` option must be a path to a directory")},GQe=t=>t.stats instanceof _J.Stats?t.path:t,Cy=(t,e)=>{t=hy([].concat(t)),UQe(t),HQe(e);let r=[];e=P({ignore:[],expandDirectories:!0},e);for(let[i,n]of t.entries()){if(ZJ(n))continue;let s=t.slice(i).filter(a=>ZJ(a)).map(a=>a.slice(1)),o=_(P({},e),{ignore:e.ignore.concat(s)});r.push({pattern:n,options:o})}return r},jQe=(t,e)=>{let r={};return t.options.cwd&&(r.cwd=t.options.cwd),Array.isArray(t.options.expandDirectories)?r=_(P({},r),{files:t.options.expandDirectories}):typeof t.options.expandDirectories=="object"&&(r=P(P({},r),t.options.expandDirectories)),e(t.pattern,r)},Qx=(t,e)=>t.options.expandDirectories?jQe(t,e):[t.pattern],$J=t=>t&&t.gitignore?Bx.sync({cwd:t.cwd,ignore:t.ignore}):XJ,bx=t=>e=>{let{options:r}=t;return r.ignore&&Array.isArray(r.ignore)&&r.expandDirectories&&(r.ignore=dy.sync(r.ignore)),{pattern:e,options:r}};Ul.exports=async(t,e)=>{let r=Cy(t,e),i=async()=>e&&e.gitignore?Bx({cwd:e.cwd,ignore:e.ignore}):XJ,n=async()=>{let l=await Promise.all(r.map(async c=>{let u=await Qx(c,dy);return Promise.all(u.map(bx(c)))}));return hy(...l)},[s,o]=await Promise.all([i(),n()]),a=await Promise.all(o.map(l=>py(l.pattern,l.options)));return hy(...a).filter(l=>!s(GQe(l)))};Ul.exports.sync=(t,e)=>{let r=Cy(t,e),i=[];for(let o of r){let a=Qx(o,dy.sync).map(bx(o));i.push(...a)}let n=$J(e),s=[];for(let o of i)s=hy(s,py.sync(o.pattern,o.options));return s.filter(o=>!n(o))};Ul.exports.stream=(t,e)=>{let r=Cy(t,e),i=[];for(let a of r){let l=Qx(a,dy.sync).map(bx(a));i.push(...l)}let n=$J(e),s=new OQe(a=>!n(a)),o=new KQe;return MQe(i.map(a=>py.stream(a.pattern,a.options))).pipe(s).pipe(o)};Ul.exports.generateGlobTasks=Cy;Ul.exports.hasMagic=(t,e)=>[].concat(t).some(r=>py.isDynamicPattern(r,e));Ul.exports.gitignore=Bx});var Ca=E((da,Dy)=>{"use strict";Object.defineProperty(da,"__esModule",{value:!0});var A3=["Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Uint16Array","Int32Array","Uint32Array","Float32Array","Float64Array","BigInt64Array","BigUint64Array"];function ibe(t){return A3.includes(t)}var nbe=["Function","Generator","AsyncGenerator","GeneratorFunction","AsyncGeneratorFunction","AsyncFunction","Observable","Array","Buffer","Object","RegExp","Date","Error","Map","Set","WeakMap","WeakSet","ArrayBuffer","SharedArrayBuffer","DataView","Promise","URL","FormData","URLSearchParams","HTMLElement",...A3];function sbe(t){return nbe.includes(t)}var obe=["null","undefined","string","number","bigint","boolean","symbol"];function abe(t){return obe.includes(t)}function Hu(t){return e=>typeof e===t}var{toString:l3}=Object.prototype,mp=t=>{let e=l3.call(t).slice(8,-1);if(/HTML\w+Element/.test(e)&&j.domElement(t))return"HTMLElement";if(sbe(e))return e},er=t=>e=>mp(e)===t;function j(t){if(t===null)return"null";switch(typeof t){case"undefined":return"undefined";case"string":return"string";case"number":return"number";case"boolean":return"boolean";case"function":return"Function";case"bigint":return"bigint";case"symbol":return"symbol";default:}if(j.observable(t))return"Observable";if(j.array(t))return"Array";if(j.buffer(t))return"Buffer";let e=mp(t);if(e)return e;if(t instanceof String||t instanceof Boolean||t instanceof Number)throw new TypeError("Please don't use object wrappers for primitive types");return"Object"}j.undefined=Hu("undefined");j.string=Hu("string");var Abe=Hu("number");j.number=t=>Abe(t)&&!j.nan(t);j.bigint=Hu("bigint");j.function_=Hu("function");j.null_=t=>t===null;j.class_=t=>j.function_(t)&&t.toString().startsWith("class ");j.boolean=t=>t===!0||t===!1;j.symbol=Hu("symbol");j.numericString=t=>j.string(t)&&!j.emptyStringOrWhitespace(t)&&!Number.isNaN(Number(t));j.array=(t,e)=>Array.isArray(t)?j.function_(e)?t.every(e):!0:!1;j.buffer=t=>{var e,r,i,n;return(n=(i=(r=(e=t)===null||e===void 0?void 0:e.constructor)===null||r===void 0?void 0:r.isBuffer)===null||i===void 0?void 0:i.call(r,t))!==null&&n!==void 0?n:!1};j.nullOrUndefined=t=>j.null_(t)||j.undefined(t);j.object=t=>!j.null_(t)&&(typeof t=="object"||j.function_(t));j.iterable=t=>{var e;return j.function_((e=t)===null||e===void 0?void 0:e[Symbol.iterator])};j.asyncIterable=t=>{var e;return j.function_((e=t)===null||e===void 0?void 0:e[Symbol.asyncIterator])};j.generator=t=>j.iterable(t)&&j.function_(t.next)&&j.function_(t.throw);j.asyncGenerator=t=>j.asyncIterable(t)&&j.function_(t.next)&&j.function_(t.throw);j.nativePromise=t=>er("Promise")(t);var lbe=t=>{var e,r;return j.function_((e=t)===null||e===void 0?void 0:e.then)&&j.function_((r=t)===null||r===void 0?void 0:r.catch)};j.promise=t=>j.nativePromise(t)||lbe(t);j.generatorFunction=er("GeneratorFunction");j.asyncGeneratorFunction=t=>mp(t)==="AsyncGeneratorFunction";j.asyncFunction=t=>mp(t)==="AsyncFunction";j.boundFunction=t=>j.function_(t)&&!t.hasOwnProperty("prototype");j.regExp=er("RegExp");j.date=er("Date");j.error=er("Error");j.map=t=>er("Map")(t);j.set=t=>er("Set")(t);j.weakMap=t=>er("WeakMap")(t);j.weakSet=t=>er("WeakSet")(t);j.int8Array=er("Int8Array");j.uint8Array=er("Uint8Array");j.uint8ClampedArray=er("Uint8ClampedArray");j.int16Array=er("Int16Array");j.uint16Array=er("Uint16Array");j.int32Array=er("Int32Array");j.uint32Array=er("Uint32Array");j.float32Array=er("Float32Array");j.float64Array=er("Float64Array");j.bigInt64Array=er("BigInt64Array");j.bigUint64Array=er("BigUint64Array");j.arrayBuffer=er("ArrayBuffer");j.sharedArrayBuffer=er("SharedArrayBuffer");j.dataView=er("DataView");j.directInstanceOf=(t,e)=>Object.getPrototypeOf(t)===e.prototype;j.urlInstance=t=>er("URL")(t);j.urlString=t=>{if(!j.string(t))return!1;try{return new URL(t),!0}catch(e){return!1}};j.truthy=t=>Boolean(t);j.falsy=t=>!t;j.nan=t=>Number.isNaN(t);j.primitive=t=>j.null_(t)||abe(typeof t);j.integer=t=>Number.isInteger(t);j.safeInteger=t=>Number.isSafeInteger(t);j.plainObject=t=>{if(l3.call(t)!=="[object Object]")return!1;let e=Object.getPrototypeOf(t);return e===null||e===Object.getPrototypeOf({})};j.typedArray=t=>ibe(mp(t));var cbe=t=>j.safeInteger(t)&&t>=0;j.arrayLike=t=>!j.nullOrUndefined(t)&&!j.function_(t)&&cbe(t.length);j.inRange=(t,e)=>{if(j.number(e))return t>=Math.min(0,e)&&t<=Math.max(e,0);if(j.array(e)&&e.length===2)return t>=Math.min(...e)&&t<=Math.max(...e);throw new TypeError(`Invalid range: ${JSON.stringify(e)}`)};var ube=1,gbe=["innerHTML","ownerDocument","style","attributes","nodeValue"];j.domElement=t=>j.object(t)&&t.nodeType===ube&&j.string(t.nodeName)&&!j.plainObject(t)&&gbe.every(e=>e in t);j.observable=t=>{var e,r,i,n;return t?t===((r=(e=t)[Symbol.observable])===null||r===void 0?void 0:r.call(e))||t===((n=(i=t)["@@observable"])===null||n===void 0?void 0:n.call(i)):!1};j.nodeStream=t=>j.object(t)&&j.function_(t.pipe)&&!j.observable(t);j.infinite=t=>t===Infinity||t===-Infinity;var c3=t=>e=>j.integer(e)&&Math.abs(e%2)===t;j.evenInteger=c3(0);j.oddInteger=c3(1);j.emptyArray=t=>j.array(t)&&t.length===0;j.nonEmptyArray=t=>j.array(t)&&t.length>0;j.emptyString=t=>j.string(t)&&t.length===0;j.nonEmptyString=t=>j.string(t)&&t.length>0;var fbe=t=>j.string(t)&&!/\S/.test(t);j.emptyStringOrWhitespace=t=>j.emptyString(t)||fbe(t);j.emptyObject=t=>j.object(t)&&!j.map(t)&&!j.set(t)&&Object.keys(t).length===0;j.nonEmptyObject=t=>j.object(t)&&!j.map(t)&&!j.set(t)&&Object.keys(t).length>0;j.emptySet=t=>j.set(t)&&t.size===0;j.nonEmptySet=t=>j.set(t)&&t.size>0;j.emptyMap=t=>j.map(t)&&t.size===0;j.nonEmptyMap=t=>j.map(t)&&t.size>0;j.propertyKey=t=>j.any([j.string,j.number,j.symbol],t);j.formData=t=>er("FormData")(t);j.urlSearchParams=t=>er("URLSearchParams")(t);var u3=(t,e,r)=>{if(!j.function_(e))throw new TypeError(`Invalid predicate: ${JSON.stringify(e)}`);if(r.length===0)throw new TypeError("Invalid number of values");return t.call(r,e)};j.any=(t,...e)=>(j.array(t)?t:[t]).some(i=>u3(Array.prototype.some,i,e));j.all=(t,...e)=>u3(Array.prototype.every,t,e);var Te=(t,e,r,i={})=>{if(!t){let{multipleValues:n}=i,s=n?`received values of types ${[...new Set(r.map(o=>`\`${j(o)}\``))].join(", ")}`:`received value of type \`${j(r)}\``;throw new TypeError(`Expected value which is \`${e}\`, ${s}.`)}};da.assert={undefined:t=>Te(j.undefined(t),"undefined",t),string:t=>Te(j.string(t),"string",t),number:t=>Te(j.number(t),"number",t),bigint:t=>Te(j.bigint(t),"bigint",t),function_:t=>Te(j.function_(t),"Function",t),null_:t=>Te(j.null_(t),"null",t),class_:t=>Te(j.class_(t),"Class",t),boolean:t=>Te(j.boolean(t),"boolean",t),symbol:t=>Te(j.symbol(t),"symbol",t),numericString:t=>Te(j.numericString(t),"string with a number",t),array:(t,e)=>{Te(j.array(t),"Array",t),e&&t.forEach(e)},buffer:t=>Te(j.buffer(t),"Buffer",t),nullOrUndefined:t=>Te(j.nullOrUndefined(t),"null or undefined",t),object:t=>Te(j.object(t),"Object",t),iterable:t=>Te(j.iterable(t),"Iterable",t),asyncIterable:t=>Te(j.asyncIterable(t),"AsyncIterable",t),generator:t=>Te(j.generator(t),"Generator",t),asyncGenerator:t=>Te(j.asyncGenerator(t),"AsyncGenerator",t),nativePromise:t=>Te(j.nativePromise(t),"native Promise",t),promise:t=>Te(j.promise(t),"Promise",t),generatorFunction:t=>Te(j.generatorFunction(t),"GeneratorFunction",t),asyncGeneratorFunction:t=>Te(j.asyncGeneratorFunction(t),"AsyncGeneratorFunction",t),asyncFunction:t=>Te(j.asyncFunction(t),"AsyncFunction",t),boundFunction:t=>Te(j.boundFunction(t),"Function",t),regExp:t=>Te(j.regExp(t),"RegExp",t),date:t=>Te(j.date(t),"Date",t),error:t=>Te(j.error(t),"Error",t),map:t=>Te(j.map(t),"Map",t),set:t=>Te(j.set(t),"Set",t),weakMap:t=>Te(j.weakMap(t),"WeakMap",t),weakSet:t=>Te(j.weakSet(t),"WeakSet",t),int8Array:t=>Te(j.int8Array(t),"Int8Array",t),uint8Array:t=>Te(j.uint8Array(t),"Uint8Array",t),uint8ClampedArray:t=>Te(j.uint8ClampedArray(t),"Uint8ClampedArray",t),int16Array:t=>Te(j.int16Array(t),"Int16Array",t),uint16Array:t=>Te(j.uint16Array(t),"Uint16Array",t),int32Array:t=>Te(j.int32Array(t),"Int32Array",t),uint32Array:t=>Te(j.uint32Array(t),"Uint32Array",t),float32Array:t=>Te(j.float32Array(t),"Float32Array",t),float64Array:t=>Te(j.float64Array(t),"Float64Array",t),bigInt64Array:t=>Te(j.bigInt64Array(t),"BigInt64Array",t),bigUint64Array:t=>Te(j.bigUint64Array(t),"BigUint64Array",t),arrayBuffer:t=>Te(j.arrayBuffer(t),"ArrayBuffer",t),sharedArrayBuffer:t=>Te(j.sharedArrayBuffer(t),"SharedArrayBuffer",t),dataView:t=>Te(j.dataView(t),"DataView",t),urlInstance:t=>Te(j.urlInstance(t),"URL",t),urlString:t=>Te(j.urlString(t),"string with a URL",t),truthy:t=>Te(j.truthy(t),"truthy",t),falsy:t=>Te(j.falsy(t),"falsy",t),nan:t=>Te(j.nan(t),"NaN",t),primitive:t=>Te(j.primitive(t),"primitive",t),integer:t=>Te(j.integer(t),"integer",t),safeInteger:t=>Te(j.safeInteger(t),"integer",t),plainObject:t=>Te(j.plainObject(t),"plain object",t),typedArray:t=>Te(j.typedArray(t),"TypedArray",t),arrayLike:t=>Te(j.arrayLike(t),"array-like",t),domElement:t=>Te(j.domElement(t),"HTMLElement",t),observable:t=>Te(j.observable(t),"Observable",t),nodeStream:t=>Te(j.nodeStream(t),"Node.js Stream",t),infinite:t=>Te(j.infinite(t),"infinite number",t),emptyArray:t=>Te(j.emptyArray(t),"empty array",t),nonEmptyArray:t=>Te(j.nonEmptyArray(t),"non-empty array",t),emptyString:t=>Te(j.emptyString(t),"empty string",t),nonEmptyString:t=>Te(j.nonEmptyString(t),"non-empty string",t),emptyStringOrWhitespace:t=>Te(j.emptyStringOrWhitespace(t),"empty string or whitespace",t),emptyObject:t=>Te(j.emptyObject(t),"empty object",t),nonEmptyObject:t=>Te(j.nonEmptyObject(t),"non-empty object",t),emptySet:t=>Te(j.emptySet(t),"empty set",t),nonEmptySet:t=>Te(j.nonEmptySet(t),"non-empty set",t),emptyMap:t=>Te(j.emptyMap(t),"empty map",t),nonEmptyMap:t=>Te(j.nonEmptyMap(t),"non-empty map",t),propertyKey:t=>Te(j.propertyKey(t),"PropertyKey",t),formData:t=>Te(j.formData(t),"FormData",t),urlSearchParams:t=>Te(j.urlSearchParams(t),"URLSearchParams",t),evenInteger:t=>Te(j.evenInteger(t),"even integer",t),oddInteger:t=>Te(j.oddInteger(t),"odd integer",t),directInstanceOf:(t,e)=>Te(j.directInstanceOf(t,e),"T",t),inRange:(t,e)=>Te(j.inRange(t,e),"in range",t),any:(t,...e)=>Te(j.any(t,...e),"predicate returns truthy for any value",e,{multipleValues:!0}),all:(t,...e)=>Te(j.all(t,...e),"predicate returns truthy for all values",e,{multipleValues:!0})};Object.defineProperties(j,{class:{value:j.class_},function:{value:j.function_},null:{value:j.null_}});Object.defineProperties(da.assert,{class:{value:da.assert.class_},function:{value:da.assert.function_},null:{value:da.assert.null_}});da.default=j;Dy.exports=j;Dy.exports.default=j;Dy.exports.assert=da.assert});var g3=E((gnt,Ux)=>{"use strict";var Hx=class extends Error{constructor(e){super(e||"Promise was canceled");this.name="CancelError"}get isCanceled(){return!0}},Ep=class{static fn(e){return(...r)=>new Ep((i,n,s)=>{r.push(s),e(...r).then(i,n)})}constructor(e){this._cancelHandlers=[],this._isPending=!0,this._isCanceled=!1,this._rejectOnCancel=!0,this._promise=new Promise((r,i)=>{this._reject=i;let n=a=>{this._isPending=!1,r(a)},s=a=>{this._isPending=!1,i(a)},o=a=>{if(!this._isPending)throw new Error("The `onCancel` handler was attached after the promise settled.");this._cancelHandlers.push(a)};return Object.defineProperties(o,{shouldReject:{get:()=>this._rejectOnCancel,set:a=>{this._rejectOnCancel=a}}}),e(n,s,o)})}then(e,r){return this._promise.then(e,r)}catch(e){return this._promise.catch(e)}finally(e){return this._promise.finally(e)}cancel(e){if(!(!this._isPending||this._isCanceled)){if(this._cancelHandlers.length>0)try{for(let r of this._cancelHandlers)r()}catch(r){this._reject(r)}this._isCanceled=!0,this._rejectOnCancel&&this._reject(new Hx(e))}}get isCanceled(){return this._isCanceled}};Object.setPrototypeOf(Ep.prototype,Promise.prototype);Ux.exports=Ep;Ux.exports.CancelError=Hx});var f3=E((Gx,jx)=>{"use strict";Object.defineProperty(Gx,"__esModule",{value:!0});var hbe=require("tls"),Yx=(t,e)=>{let r;typeof e=="function"?r={connect:e}:r=e;let i=typeof r.connect=="function",n=typeof r.secureConnect=="function",s=typeof r.close=="function",o=()=>{i&&r.connect(),t instanceof hbe.TLSSocket&&n&&(t.authorized?r.secureConnect():t.authorizationError||t.once("secureConnect",r.secureConnect)),s&&t.once("close",r.close)};t.writable&&!t.connecting?o():t.connecting?t.once("connect",o):t.destroyed&&s&&r.close(t._hadError)};Gx.default=Yx;jx.exports=Yx;jx.exports.default=Yx});var h3=E((qx,Jx)=>{"use strict";Object.defineProperty(qx,"__esModule",{value:!0});var pbe=f3(),dbe=Number(process.versions.node.split(".")[0]),Wx=t=>{let e={start:Date.now(),socket:void 0,lookup:void 0,connect:void 0,secureConnect:void 0,upload:void 0,response:void 0,end:void 0,error:void 0,abort:void 0,phases:{wait:void 0,dns:void 0,tcp:void 0,tls:void 0,request:void 0,firstByte:void 0,download:void 0,total:void 0}};t.timings=e;let r=o=>{let a=o.emit.bind(o);o.emit=(l,...c)=>(l==="error"&&(e.error=Date.now(),e.phases.total=e.error-e.start,o.emit=a),a(l,...c))};r(t),t.prependOnceListener("abort",()=>{e.abort=Date.now(),(!e.response||dbe>=13)&&(e.phases.total=Date.now()-e.start)});let i=o=>{e.socket=Date.now(),e.phases.wait=e.socket-e.start;let a=()=>{e.lookup=Date.now(),e.phases.dns=e.lookup-e.socket};o.prependOnceListener("lookup",a),pbe.default(o,{connect:()=>{e.connect=Date.now(),e.lookup===void 0&&(o.removeListener("lookup",a),e.lookup=e.connect,e.phases.dns=e.lookup-e.socket),e.phases.tcp=e.connect-e.lookup},secureConnect:()=>{e.secureConnect=Date.now(),e.phases.tls=e.secureConnect-e.connect}})};t.socket?i(t.socket):t.prependOnceListener("socket",i);let n=()=>{var o;e.upload=Date.now(),e.phases.request=e.upload-(o=e.secureConnect,o!=null?o:e.connect)};return(()=>typeof t.writableFinished=="boolean"?t.writableFinished:t.finished&&t.outputSize===0&&(!t.socket||t.socket.writableLength===0))()?n():t.prependOnceListener("finish",n),t.prependOnceListener("response",o=>{e.response=Date.now(),e.phases.firstByte=e.response-e.upload,o.timings=e,r(o),o.prependOnceListener("end",()=>{e.end=Date.now(),e.phases.download=e.end-e.response,e.phases.total=e.end-e.start})}),e};qx.default=Wx;Jx.exports=Wx;Jx.exports.default=Wx});var y3=E((fnt,zx)=>{"use strict";var{V4MAPPED:Cbe,ADDRCONFIG:mbe,ALL:p3,promises:{Resolver:d3},lookup:Ebe}=require("dns"),{promisify:Vx}=require("util"),Ibe=require("os"),Gu=Symbol("cacheableLookupCreateConnection"),_x=Symbol("cacheableLookupInstance"),C3=Symbol("expires"),ybe=typeof p3=="number",m3=t=>{if(!(t&&typeof t.createConnection=="function"))throw new Error("Expected an Agent instance as the first argument")},wbe=t=>{for(let e of t)e.family!==6&&(e.address=`::ffff:${e.address}`,e.family=6)},E3=()=>{let t=!1,e=!1;for(let r of Object.values(Ibe.networkInterfaces()))for(let i of r)if(!i.internal&&(i.family==="IPv6"?e=!0:t=!0,t&&e))return{has4:t,has6:e};return{has4:t,has6:e}},Bbe=t=>Symbol.iterator in t,I3={ttl:!0},Qbe={all:!0},Xx=class{constructor({cache:e=new Map,maxTtl:r=Infinity,fallbackDuration:i=3600,errorTtl:n=.15,resolver:s=new d3,lookup:o=Ebe}={}){if(this.maxTtl=r,this.errorTtl=n,this._cache=e,this._resolver=s,this._dnsLookup=Vx(o),this._resolver instanceof d3?(this._resolve4=this._resolver.resolve4.bind(this._resolver),this._resolve6=this._resolver.resolve6.bind(this._resolver)):(this._resolve4=Vx(this._resolver.resolve4.bind(this._resolver)),this._resolve6=Vx(this._resolver.resolve6.bind(this._resolver))),this._iface=E3(),this._pending={},this._nextRemovalTime=!1,this._hostnamesToFallback=new Set,i<1)this._fallback=!1;else{this._fallback=!0;let a=setInterval(()=>{this._hostnamesToFallback.clear()},i*1e3);a.unref&&a.unref()}this.lookup=this.lookup.bind(this),this.lookupAsync=this.lookupAsync.bind(this)}set servers(e){this.clear(),this._resolver.setServers(e)}get servers(){return this._resolver.getServers()}lookup(e,r,i){if(typeof r=="function"?(i=r,r={}):typeof r=="number"&&(r={family:r}),!i)throw new Error("Callback must be a function.");this.lookupAsync(e,r).then(n=>{r.all?i(null,n):i(null,n.address,n.family,n.expires,n.ttl)},i)}async lookupAsync(e,r={}){typeof r=="number"&&(r={family:r});let i=await this.query(e);if(r.family===6){let n=i.filter(s=>s.family===6);r.hints&Cbe&&(ybe&&r.hints&p3||n.length===0)?wbe(i):i=n}else r.family===4&&(i=i.filter(n=>n.family===4));if(r.hints&mbe){let{_iface:n}=this;i=i.filter(s=>s.family===6?n.has6:n.has4)}if(i.length===0){let n=new Error(`cacheableLookup ENOTFOUND ${e}`);throw n.code="ENOTFOUND",n.hostname=e,n}return r.all?i:i[0]}async query(e){let r=await this._cache.get(e);if(!r){let i=this._pending[e];if(i)r=await i;else{let n=this.queryAndCache(e);this._pending[e]=n,r=await n}}return r=r.map(i=>P({},i)),r}async _resolve(e){let r=async c=>{try{return await c}catch(u){if(u.code==="ENODATA"||u.code==="ENOTFOUND")return[];throw u}},[i,n]=await Promise.all([this._resolve4(e,I3),this._resolve6(e,I3)].map(c=>r(c))),s=0,o=0,a=0,l=Date.now();for(let c of i)c.family=4,c.expires=l+c.ttl*1e3,s=Math.max(s,c.ttl);for(let c of n)c.family=6,c.expires=l+c.ttl*1e3,o=Math.max(o,c.ttl);return i.length>0?n.length>0?a=Math.min(s,o):a=s:a=o,{entries:[...i,...n],cacheTtl:a}}async _lookup(e){try{return{entries:await this._dnsLookup(e,{all:!0}),cacheTtl:0}}catch(r){return{entries:[],cacheTtl:0}}}async _set(e,r,i){if(this.maxTtl>0&&i>0){i=Math.min(i,this.maxTtl)*1e3,r[C3]=Date.now()+i;try{await this._cache.set(e,r,i)}catch(n){this.lookupAsync=async()=>{let s=new Error("Cache Error. Please recreate the CacheableLookup instance.");throw s.cause=n,s}}Bbe(this._cache)&&this._tick(i)}}async queryAndCache(e){if(this._hostnamesToFallback.has(e))return this._dnsLookup(e,Qbe);try{let r=await this._resolve(e);r.entries.length===0&&this._fallback&&(r=await this._lookup(e),r.entries.length!==0&&this._hostnamesToFallback.add(e));let i=r.entries.length===0?this.errorTtl:r.cacheTtl;return await this._set(e,r.entries,i),delete this._pending[e],r.entries}catch(r){throw delete this._pending[e],r}}_tick(e){let r=this._nextRemovalTime;(!r||e{this._nextRemovalTime=!1;let i=Infinity,n=Date.now();for(let[s,o]of this._cache){let a=o[C3];n>=a?this._cache.delete(s):a("lookup"in r||(r.lookup=this.lookup),e[Gu](r,i))}uninstall(e){if(m3(e),e[Gu]){if(e[_x]!==this)throw new Error("The agent is not owned by this CacheableLookup instance");e.createConnection=e[Gu],delete e[Gu],delete e[_x]}}updateInterfaceInfo(){let{_iface:e}=this;this._iface=E3(),(e.has4&&!this._iface.has4||e.has6&&!this._iface.has6)&&this._cache.clear()}clear(e){if(e){this._cache.delete(e);return}this._cache.clear()}};zx.exports=Xx;zx.exports.default=Xx});var Q3=E((hnt,Zx)=>{"use strict";var bbe=typeof URL=="undefined"?require("url").URL:URL,vbe="text/plain",Sbe="us-ascii",w3=(t,e)=>e.some(r=>r instanceof RegExp?r.test(t):r===t),xbe=(t,{stripHash:e})=>{let r=t.match(/^data:([^,]*?),([^#]*?)(?:#(.*))?$/);if(!r)throw new Error(`Invalid URL: ${t}`);let i=r[1].split(";"),n=r[2],s=e?"":r[3],o=!1;i[i.length-1]==="base64"&&(i.pop(),o=!0);let a=(i.shift()||"").toLowerCase(),c=[...i.map(u=>{let[g,f=""]=u.split("=").map(h=>h.trim());return g==="charset"&&(f=f.toLowerCase(),f===Sbe)?"":`${g}${f?`=${f}`:""}`}).filter(Boolean)];return o&&c.push("base64"),(c.length!==0||a&&a!==vbe)&&c.unshift(a),`data:${c.join(";")},${o?n.trim():n}${s?`#${s}`:""}`},B3=(t,e)=>{if(e=P({defaultProtocol:"http:",normalizeProtocol:!0,forceHttp:!1,forceHttps:!1,stripAuthentication:!0,stripHash:!1,stripWWW:!0,removeQueryParameters:[/^utm_\w+/i],removeTrailingSlash:!0,removeDirectoryIndex:!1,sortQueryParameters:!0},e),Reflect.has(e,"normalizeHttps"))throw new Error("options.normalizeHttps is renamed to options.forceHttp");if(Reflect.has(e,"normalizeHttp"))throw new Error("options.normalizeHttp is renamed to options.forceHttps");if(Reflect.has(e,"stripFragment"))throw new Error("options.stripFragment is renamed to options.stripHash");if(t=t.trim(),/^data:/i.test(t))return xbe(t,e);let r=t.startsWith("//");!r&&/^\.*\//.test(t)||(t=t.replace(/^(?!(?:\w+:)?\/\/)|^\/\//,e.defaultProtocol));let n=new bbe(t);if(e.forceHttp&&e.forceHttps)throw new Error("The `forceHttp` and `forceHttps` options cannot be used together");if(e.forceHttp&&n.protocol==="https:"&&(n.protocol="http:"),e.forceHttps&&n.protocol==="http:"&&(n.protocol="https:"),e.stripAuthentication&&(n.username="",n.password=""),e.stripHash&&(n.hash=""),n.pathname&&(n.pathname=n.pathname.replace(/((?!:).|^)\/{2,}/g,(s,o)=>/^(?!\/)/g.test(o)?`${o}/`:"/")),n.pathname&&(n.pathname=decodeURI(n.pathname)),e.removeDirectoryIndex===!0&&(e.removeDirectoryIndex=[/^index\.[a-z]+$/]),Array.isArray(e.removeDirectoryIndex)&&e.removeDirectoryIndex.length>0){let s=n.pathname.split("/"),o=s[s.length-1];w3(o,e.removeDirectoryIndex)&&(s=s.slice(0,s.length-1),n.pathname=s.slice(1).join("/")+"/")}if(n.hostname&&(n.hostname=n.hostname.replace(/\.$/,""),e.stripWWW&&/^www\.([a-z\-\d]{2,63})\.([a-z.]{2,5})$/.test(n.hostname)&&(n.hostname=n.hostname.replace(/^www\./,""))),Array.isArray(e.removeQueryParameters))for(let s of[...n.searchParams.keys()])w3(s,e.removeQueryParameters)&&n.searchParams.delete(s);return e.sortQueryParameters&&n.searchParams.sort(),e.removeTrailingSlash&&(n.pathname=n.pathname.replace(/\/$/,"")),t=n.toString(),(e.removeTrailingSlash||n.pathname==="/")&&n.hash===""&&(t=t.replace(/\/$/,"")),r&&!e.normalizeProtocol&&(t=t.replace(/^http:\/\//,"//")),e.stripProtocol&&(t=t.replace(/^(?:https?:)?\/\//,"")),t};Zx.exports=B3;Zx.exports.default=B3});var S3=E((pnt,b3)=>{b3.exports=v3;function v3(t,e){if(t&&e)return v3(t)(e);if(typeof t!="function")throw new TypeError("need wrapper function");return Object.keys(t).forEach(function(i){r[i]=t[i]}),r;function r(){for(var i=new Array(arguments.length),n=0;n{var x3=S3();$x.exports=x3(Ry);$x.exports.strict=x3(k3);Ry.proto=Ry(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return Ry(this)},configurable:!0}),Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return k3(this)},configurable:!0})});function Ry(t){var e=function(){return e.called?e.value:(e.called=!0,e.value=t.apply(this,arguments))};return e.called=!1,e}function k3(t){var e=function(){if(e.called)throw new Error(e.onceError);return e.called=!0,e.value=t.apply(this,arguments)},r=t.name||"Function wrapped with `once`";return e.onceError=r+" shouldn't be called more than once",e.called=!1,e}});var tk=E((Cnt,P3)=>{var kbe=ek(),Pbe=function(){},Dbe=function(t){return t.setHeader&&typeof t.abort=="function"},Rbe=function(t){return t.stdio&&Array.isArray(t.stdio)&&t.stdio.length===3},D3=function(t,e,r){if(typeof e=="function")return D3(t,null,e);e||(e={}),r=kbe(r||Pbe);var i=t._writableState,n=t._readableState,s=e.readable||e.readable!==!1&&t.readable,o=e.writable||e.writable!==!1&&t.writable,a=function(){t.writable||l()},l=function(){o=!1,s||r.call(t)},c=function(){s=!1,o||r.call(t)},u=function(p){r.call(t,p?new Error("exited with error code: "+p):null)},g=function(p){r.call(t,p)},f=function(){if(s&&!(n&&n.ended))return r.call(t,new Error("premature close"));if(o&&!(i&&i.ended))return r.call(t,new Error("premature close"))},h=function(){t.req.on("finish",l)};return Dbe(t)?(t.on("complete",l),t.on("abort",f),t.req?h():t.on("request",h)):o&&!i&&(t.on("end",a),t.on("close",a)),Rbe(t)&&t.on("exit",u),t.on("end",c),t.on("finish",l),e.error!==!1&&t.on("error",g),t.on("close",f),function(){t.removeListener("complete",l),t.removeListener("abort",f),t.removeListener("request",h),t.req&&t.req.removeListener("finish",l),t.removeListener("end",a),t.removeListener("close",a),t.removeListener("finish",l),t.removeListener("exit",u),t.removeListener("end",c),t.removeListener("error",g),t.removeListener("close",f)}};P3.exports=D3});var N3=E((mnt,R3)=>{var Fbe=ek(),Nbe=tk(),rk=require("fs"),Ip=function(){},Lbe=/^v?\.0/.test(process.version),Fy=function(t){return typeof t=="function"},Tbe=function(t){return!Lbe||!rk?!1:(t instanceof(rk.ReadStream||Ip)||t instanceof(rk.WriteStream||Ip))&&Fy(t.close)},Mbe=function(t){return t.setHeader&&Fy(t.abort)},Obe=function(t,e,r,i){i=Fbe(i);var n=!1;t.on("close",function(){n=!0}),Nbe(t,{readable:e,writable:r},function(o){if(o)return i(o);n=!0,i()});var s=!1;return function(o){if(!n&&!s){if(s=!0,Tbe(t))return t.close(Ip);if(Mbe(t))return t.abort();if(Fy(t.destroy))return t.destroy();i(o||new Error("stream was destroyed"))}}},F3=function(t){t()},Kbe=function(t,e){return t.pipe(e)},Ube=function(){var t=Array.prototype.slice.call(arguments),e=Fy(t[t.length-1]||Ip)&&t.pop()||Ip;if(Array.isArray(t[0])&&(t=t[0]),t.length<2)throw new Error("pump requires two streams per minimum");var r,i=t.map(function(n,s){var o=s0;return Obe(n,o,a,function(l){r||(r=l),l&&i.forEach(F3),!o&&(i.forEach(F3),e(r))})});return t.reduce(Kbe)};R3.exports=Ube});var T3=E((Ent,L3)=>{"use strict";var{PassThrough:Hbe}=require("stream");L3.exports=t=>{t=P({},t);let{array:e}=t,{encoding:r}=t,i=r==="buffer",n=!1;e?n=!(r||i):r=r||"utf8",i&&(r=null);let s=new Hbe({objectMode:n});r&&s.setEncoding(r);let o=0,a=[];return s.on("data",l=>{a.push(l),n?o=a.length:o+=l.length}),s.getBufferedValue=()=>e?a:i?Buffer.concat(a,o):a.join(""),s.getBufferedLength=()=>o,s}});var M3=E((Int,ju)=>{"use strict";var Gbe=N3(),jbe=T3(),ik=class extends Error{constructor(){super("maxBuffer exceeded");this.name="MaxBufferError"}};async function Ny(t,e){if(!t)return Promise.reject(new Error("Expected a stream"));e=P({maxBuffer:Infinity},e);let{maxBuffer:r}=e,i;return await new Promise((n,s)=>{let o=a=>{a&&(a.bufferedData=i.getBufferedValue()),s(a)};i=Gbe(t,jbe(e),a=>{if(a){o(a);return}n()}),i.on("data",()=>{i.getBufferedLength()>r&&o(new ik)})}),i.getBufferedValue()}ju.exports=Ny;ju.exports.default=Ny;ju.exports.buffer=(t,e)=>Ny(t,_(P({},e),{encoding:"buffer"}));ju.exports.array=(t,e)=>Ny(t,_(P({},e),{array:!0}));ju.exports.MaxBufferError=ik});var K3=E((wnt,O3)=>{"use strict";var Ybe=[200,203,204,206,300,301,404,405,410,414,501],qbe=[200,203,204,300,301,302,303,307,308,404,405,410,414,501],Jbe={date:!0,connection:!0,"keep-alive":!0,"proxy-authenticate":!0,"proxy-authorization":!0,te:!0,trailer:!0,"transfer-encoding":!0,upgrade:!0},Wbe={"content-length":!0,"content-encoding":!0,"transfer-encoding":!0,"content-range":!0};function nk(t){let e={};if(!t)return e;let r=t.trim().split(/\s*,\s*/);for(let i of r){let[n,s]=i.split(/\s*=\s*/,2);e[n]=s===void 0?!0:s.replace(/^"|"$/g,"")}return e}function zbe(t){let e=[];for(let r in t){let i=t[r];e.push(i===!0?r:r+"="+i)}if(!!e.length)return e.join(", ")}O3.exports=class{constructor(e,r,{shared:i,cacheHeuristic:n,immutableMinTimeToLive:s,ignoreCargoCult:o,trustServerDate:a,_fromObject:l}={}){if(l){this._fromObject(l);return}if(!r||!r.headers)throw Error("Response headers missing");this._assertRequestHasHeaders(e),this._responseTime=this.now(),this._isShared=i!==!1,this._trustServerDate=a!==void 0?a:!0,this._cacheHeuristic=n!==void 0?n:.1,this._immutableMinTtl=s!==void 0?s:24*3600*1e3,this._status="status"in r?r.status:200,this._resHeaders=r.headers,this._rescc=nk(r.headers["cache-control"]),this._method="method"in e?e.method:"GET",this._url=e.url,this._host=e.headers.host,this._noAuthorization=!e.headers.authorization,this._reqHeaders=r.headers.vary?e.headers:null,this._reqcc=nk(e.headers["cache-control"]),o&&"pre-check"in this._rescc&&"post-check"in this._rescc&&(delete this._rescc["pre-check"],delete this._rescc["post-check"],delete this._rescc["no-cache"],delete this._rescc["no-store"],delete this._rescc["must-revalidate"],this._resHeaders=Object.assign({},this._resHeaders,{"cache-control":zbe(this._rescc)}),delete this._resHeaders.expires,delete this._resHeaders.pragma),!r.headers["cache-control"]&&/no-cache/.test(r.headers.pragma)&&(this._rescc["no-cache"]=!0)}now(){return Date.now()}storable(){return!!(!this._reqcc["no-store"]&&(this._method==="GET"||this._method==="HEAD"||this._method==="POST"&&this._hasExplicitExpiration())&&qbe.indexOf(this._status)!==-1&&!this._rescc["no-store"]&&(!this._isShared||!this._rescc.private)&&(!this._isShared||this._noAuthorization||this._allowsStoringAuthenticated())&&(this._resHeaders.expires||this._rescc.public||this._rescc["max-age"]||this._rescc["s-maxage"]||Ybe.indexOf(this._status)!==-1))}_hasExplicitExpiration(){return this._isShared&&this._rescc["s-maxage"]||this._rescc["max-age"]||this._resHeaders.expires}_assertRequestHasHeaders(e){if(!e||!e.headers)throw Error("Request headers missing")}satisfiesWithoutRevalidation(e){this._assertRequestHasHeaders(e);let r=nk(e.headers["cache-control"]);return r["no-cache"]||/no-cache/.test(e.headers.pragma)||r["max-age"]&&this.age()>r["max-age"]||r["min-fresh"]&&this.timeToLive()<1e3*r["min-fresh"]||this.stale()&&!(r["max-stale"]&&!this._rescc["must-revalidate"]&&(r["max-stale"]===!0||r["max-stale"]>this.age()-this.maxAge()))?!1:this._requestMatches(e,!1)}_requestMatches(e,r){return(!this._url||this._url===e.url)&&this._host===e.headers.host&&(!e.method||this._method===e.method||r&&e.method==="HEAD")&&this._varyMatches(e)}_allowsStoringAuthenticated(){return this._rescc["must-revalidate"]||this._rescc.public||this._rescc["s-maxage"]}_varyMatches(e){if(!this._resHeaders.vary)return!0;if(this._resHeaders.vary==="*")return!1;let r=this._resHeaders.vary.trim().toLowerCase().split(/\s*,\s*/);for(let i of r)if(e.headers[i]!==this._reqHeaders[i])return!1;return!0}_copyWithoutHopByHopHeaders(e){let r={};for(let i in e)Jbe[i]||(r[i]=e[i]);if(e.connection){let i=e.connection.trim().split(/\s*,\s*/);for(let n of i)delete r[n]}if(r.warning){let i=r.warning.split(/,/).filter(n=>!/^\s*1[0-9][0-9]/.test(n));i.length?r.warning=i.join(",").trim():delete r.warning}return r}responseHeaders(){let e=this._copyWithoutHopByHopHeaders(this._resHeaders),r=this.age();return r>3600*24&&!this._hasExplicitExpiration()&&this.maxAge()>3600*24&&(e.warning=(e.warning?`${e.warning}, `:"")+'113 - "rfc7234 5.5.4"'),e.age=`${Math.round(r)}`,e.date=new Date(this.now()).toUTCString(),e}date(){return this._trustServerDate?this._serverDate():this._responseTime}_serverDate(){let e=Date.parse(this._resHeaders.date);if(isFinite(e)){let r=8*3600*1e3;if(Math.abs(this._responseTime-e)e&&(e=i)}let r=(this.now()-this._responseTime)/1e3;return e+r}_ageValue(){let e=parseInt(this._resHeaders.age);return isFinite(e)?e:0}maxAge(){if(!this.storable()||this._rescc["no-cache"]||this._isShared&&this._resHeaders["set-cookie"]&&!this._rescc.public&&!this._rescc.immutable||this._resHeaders.vary==="*")return 0;if(this._isShared){if(this._rescc["proxy-revalidate"])return 0;if(this._rescc["s-maxage"])return parseInt(this._rescc["s-maxage"],10)}if(this._rescc["max-age"])return parseInt(this._rescc["max-age"],10);let e=this._rescc.immutable?this._immutableMinTtl:0,r=this._serverDate();if(this._resHeaders.expires){let i=Date.parse(this._resHeaders.expires);return Number.isNaN(i)||ii)return Math.max(e,(r-i)/1e3*this._cacheHeuristic)}return e}timeToLive(){return Math.max(0,this.maxAge()-this.age())*1e3}stale(){return this.maxAge()<=this.age()}static fromObject(e){return new this(void 0,void 0,{_fromObject:e})}_fromObject(e){if(this._responseTime)throw Error("Reinitialized");if(!e||e.v!==1)throw Error("Invalid serialization");this._responseTime=e.t,this._isShared=e.sh,this._cacheHeuristic=e.ch,this._immutableMinTtl=e.imm!==void 0?e.imm:24*3600*1e3,this._status=e.st,this._resHeaders=e.resh,this._rescc=e.rescc,this._method=e.m,this._url=e.u,this._host=e.h,this._noAuthorization=e.a,this._reqHeaders=e.reqh,this._reqcc=e.reqcc}toObject(){return{v:1,t:this._responseTime,sh:this._isShared,ch:this._cacheHeuristic,imm:this._immutableMinTtl,st:this._status,resh:this._resHeaders,rescc:this._rescc,m:this._method,u:this._url,h:this._host,a:this._noAuthorization,reqh:this._reqHeaders,reqcc:this._reqcc}}revalidationHeaders(e){this._assertRequestHasHeaders(e);let r=this._copyWithoutHopByHopHeaders(e.headers);if(delete r["if-range"],!this._requestMatches(e,!0)||!this.storable())return delete r["if-none-match"],delete r["if-modified-since"],r;if(this._resHeaders.etag&&(r["if-none-match"]=r["if-none-match"]?`${r["if-none-match"]}, ${this._resHeaders.etag}`:this._resHeaders.etag),r["accept-ranges"]||r["if-match"]||r["if-unmodified-since"]||this._method&&this._method!="GET"){if(delete r["if-modified-since"],r["if-none-match"]){let n=r["if-none-match"].split(/,/).filter(s=>!/^\s*W\//.test(s));n.length?r["if-none-match"]=n.join(",").trim():delete r["if-none-match"]}}else this._resHeaders["last-modified"]&&!r["if-modified-since"]&&(r["if-modified-since"]=this._resHeaders["last-modified"]);return r}revalidatedPolicy(e,r){if(this._assertRequestHasHeaders(e),!r||!r.headers)throw Error("Response headers missing");let i=!1;if(r.status!==void 0&&r.status!=304?i=!1:r.headers.etag&&!/^\s*W\//.test(r.headers.etag)?i=this._resHeaders.etag&&this._resHeaders.etag.replace(/^\s*W\//,"")===r.headers.etag:this._resHeaders.etag&&r.headers.etag?i=this._resHeaders.etag.replace(/^\s*W\//,"")===r.headers.etag.replace(/^\s*W\//,""):this._resHeaders["last-modified"]?i=this._resHeaders["last-modified"]===r.headers["last-modified"]:!this._resHeaders.etag&&!this._resHeaders["last-modified"]&&!r.headers.etag&&!r.headers["last-modified"]&&(i=!0),!i)return{policy:new this.constructor(e,r),modified:r.status!=304,matches:!1};let n={};for(let o in this._resHeaders)n[o]=o in r.headers&&!Wbe[o]?r.headers[o]:this._resHeaders[o];let s=Object.assign({},r,{status:this._status,method:this._method,headers:n});return{policy:new this.constructor(e,s,{shared:this._isShared,cacheHeuristic:this._cacheHeuristic,immutableMinTimeToLive:this._immutableMinTtl,trustServerDate:this._trustServerDate}),modified:!1,matches:!0}}}});var Ly=E((Bnt,U3)=>{"use strict";U3.exports=t=>{let e={};for(let[r,i]of Object.entries(t))e[r.toLowerCase()]=i;return e}});var j3=E((Qnt,H3)=>{"use strict";var Vbe=require("stream").Readable,_be=Ly(),G3=class extends Vbe{constructor(e,r,i,n){if(typeof e!="number")throw new TypeError("Argument `statusCode` should be a number");if(typeof r!="object")throw new TypeError("Argument `headers` should be an object");if(!(i instanceof Buffer))throw new TypeError("Argument `body` should be a buffer");if(typeof n!="string")throw new TypeError("Argument `url` should be a string");super();this.statusCode=e,this.headers=_be(r),this.body=i,this.url=n}_read(){this.push(this.body),this.push(null)}};H3.exports=G3});var q3=E((bnt,Y3)=>{"use strict";var Xbe=["destroy","setTimeout","socket","headers","trailers","rawHeaders","statusCode","httpVersion","httpVersionMinor","httpVersionMajor","rawTrailers","statusMessage"];Y3.exports=(t,e)=>{let r=new Set(Object.keys(t).concat(Xbe));for(let i of r)i in e||(e[i]=typeof t[i]=="function"?t[i].bind(t):t[i])}});var W3=E((vnt,J3)=>{"use strict";var Zbe=require("stream").PassThrough,$be=q3(),eve=t=>{if(!(t&&t.pipe))throw new TypeError("Parameter `response` must be a response stream.");let e=new Zbe;return $be(t,e),t.pipe(e)};J3.exports=eve});var z3=E(sk=>{sk.stringify=function t(e){if(typeof e=="undefined")return e;if(e&&Buffer.isBuffer(e))return JSON.stringify(":base64:"+e.toString("base64"));if(e&&e.toJSON&&(e=e.toJSON()),e&&typeof e=="object"){var r="",i=Array.isArray(e);r=i?"[":"{";var n=!0;for(var s in e){var o=typeof e[s]=="function"||!i&&typeof e[s]=="undefined";Object.hasOwnProperty.call(e,s)&&!o&&(n||(r+=","),n=!1,i?e[s]==null?r+="null":r+=t(e[s]):e[s]!==void 0&&(r+=t(s)+":"+t(e[s])))}return r+=i?"]":"}",r}else return typeof e=="string"?JSON.stringify(/^:/.test(e)?":"+e:e):typeof e=="undefined"?"null":JSON.stringify(e)};sk.parse=function(t){return JSON.parse(t,function(e,r){return typeof r=="string"?/^:base64:/.test(r)?Buffer.from(r.substring(8),"base64"):/^:/.test(r)?r.substring(1):r:r})}});var Z3=E((xnt,V3)=>{"use strict";var tve=require("events"),_3=z3(),rve=t=>{let e={redis:"@keyv/redis",mongodb:"@keyv/mongo",mongo:"@keyv/mongo",sqlite:"@keyv/sqlite",postgresql:"@keyv/postgres",postgres:"@keyv/postgres",mysql:"@keyv/mysql"};if(t.adapter||t.uri){let r=t.adapter||/^[^:]*/.exec(t.uri)[0];return new(require(e[r]))(t)}return new Map},X3=class extends tve{constructor(e,r){super();if(this.opts=Object.assign({namespace:"keyv",serialize:_3.stringify,deserialize:_3.parse},typeof e=="string"?{uri:e}:e,r),!this.opts.store){let i=Object.assign({},this.opts);this.opts.store=rve(i)}typeof this.opts.store.on=="function"&&this.opts.store.on("error",i=>this.emit("error",i)),this.opts.store.namespace=this.opts.namespace}_getKeyPrefix(e){return`${this.opts.namespace}:${e}`}get(e,r){e=this._getKeyPrefix(e);let{store:i}=this.opts;return Promise.resolve().then(()=>i.get(e)).then(n=>typeof n=="string"?this.opts.deserialize(n):n).then(n=>{if(n!==void 0){if(typeof n.expires=="number"&&Date.now()>n.expires){this.delete(e);return}return r&&r.raw?n:n.value}})}set(e,r,i){e=this._getKeyPrefix(e),typeof i=="undefined"&&(i=this.opts.ttl),i===0&&(i=void 0);let{store:n}=this.opts;return Promise.resolve().then(()=>{let s=typeof i=="number"?Date.now()+i:null;return r={value:r,expires:s},this.opts.serialize(r)}).then(s=>n.set(e,s,i)).then(()=>!0)}delete(e){e=this._getKeyPrefix(e);let{store:r}=this.opts;return Promise.resolve().then(()=>r.delete(e))}clear(){let{store:e}=this.opts;return Promise.resolve().then(()=>e.clear())}};V3.exports=X3});var tW=E((knt,$3)=>{"use strict";var ive=require("events"),Ty=require("url"),nve=Q3(),sve=M3(),ok=K3(),eW=j3(),ove=Ly(),ave=W3(),Ave=Z3(),yo=class{constructor(e,r){if(typeof e!="function")throw new TypeError("Parameter `request` must be a function");return this.cache=new Ave({uri:typeof r=="string"&&r,store:typeof r!="string"&&r,namespace:"cacheable-request"}),this.createCacheableRequest(e)}createCacheableRequest(e){return(r,i)=>{let n;if(typeof r=="string")n=ak(Ty.parse(r)),r={};else if(r instanceof Ty.URL)n=ak(Ty.parse(r.toString())),r={};else{let[g,...f]=(r.path||"").split("?"),h=f.length>0?`?${f.join("?")}`:"";n=ak(_(P({},r),{pathname:g,search:h}))}r=P(P({headers:{},method:"GET",cache:!0,strictTtl:!1,automaticFailover:!1},r),lve(n)),r.headers=ove(r.headers);let s=new ive,o=nve(Ty.format(n),{stripWWW:!1,removeTrailingSlash:!1,stripAuthentication:!1}),a=`${r.method}:${o}`,l=!1,c=!1,u=g=>{c=!0;let f=!1,h,p=new Promise(m=>{h=()=>{f||(f=!0,m())}}),d=m=>{if(l&&!g.forceRefresh){m.status=m.statusCode;let B=ok.fromObject(l.cachePolicy).revalidatedPolicy(g,m);if(!B.modified){let b=B.policy.responseHeaders();m=new eW(l.statusCode,b,l.body,l.url),m.cachePolicy=B.policy,m.fromCache=!0}}m.fromCache||(m.cachePolicy=new ok(g,m,g),m.fromCache=!1);let I;g.cache&&m.cachePolicy.storable()?(I=ave(m),(async()=>{try{let B=sve.buffer(m);if(await Promise.race([p,new Promise(L=>m.once("end",L))]),f)return;let b=await B,R={cachePolicy:m.cachePolicy.toObject(),url:m.url,statusCode:m.fromCache?l.statusCode:m.statusCode,body:b},H=g.strictTtl?m.cachePolicy.timeToLive():void 0;g.maxTtl&&(H=H?Math.min(H,g.maxTtl):g.maxTtl),await this.cache.set(a,R,H)}catch(B){s.emit("error",new yo.CacheError(B))}})()):g.cache&&l&&(async()=>{try{await this.cache.delete(a)}catch(B){s.emit("error",new yo.CacheError(B))}})(),s.emit("response",I||m),typeof i=="function"&&i(I||m)};try{let m=e(g,d);m.once("error",h),m.once("abort",h),s.emit("request",m)}catch(m){s.emit("error",new yo.RequestError(m))}};return(async()=>{let g=async h=>{await Promise.resolve();let p=h.cache?await this.cache.get(a):void 0;if(typeof p=="undefined")return u(h);let d=ok.fromObject(p.cachePolicy);if(d.satisfiesWithoutRevalidation(h)&&!h.forceRefresh){let m=d.responseHeaders(),I=new eW(p.statusCode,m,p.body,p.url);I.cachePolicy=d,I.fromCache=!0,s.emit("response",I),typeof i=="function"&&i(I)}else l=p,h.headers=d.revalidationHeaders(h),u(h)},f=h=>s.emit("error",new yo.CacheError(h));this.cache.once("error",f),s.on("response",()=>this.cache.removeListener("error",f));try{await g(r)}catch(h){r.automaticFailover&&!c&&u(r),s.emit("error",new yo.CacheError(h))}})(),s}}};function lve(t){let e=P({},t);return e.path=`${t.pathname||"/"}${t.search||""}`,delete e.pathname,delete e.search,e}function ak(t){return{protocol:t.protocol,auth:t.auth,hostname:t.hostname||t.host||"localhost",port:t.port,pathname:t.pathname,search:t.search}}yo.RequestError=class extends Error{constructor(t){super(t.message);this.name="RequestError",Object.assign(this,t)}};yo.CacheError=class extends Error{constructor(t){super(t.message);this.name="CacheError",Object.assign(this,t)}};$3.exports=yo});var iW=E((Pnt,rW)=>{"use strict";var cve=["aborted","complete","headers","httpVersion","httpVersionMinor","httpVersionMajor","method","rawHeaders","rawTrailers","setTimeout","socket","statusCode","statusMessage","trailers","url"];rW.exports=(t,e)=>{if(e._readableState.autoDestroy)throw new Error("The second stream must have the `autoDestroy` option set to `false`");let r=new Set(Object.keys(t).concat(cve)),i={};for(let n of r)n in e||(i[n]={get(){let s=t[n];return typeof s=="function"?s.bind(t):s},set(s){t[n]=s},enumerable:!0,configurable:!1});return Object.defineProperties(e,i),t.once("aborted",()=>{e.destroy(),e.emit("aborted")}),t.once("close",()=>{t.complete&&e.readable?e.once("end",()=>{e.emit("close")}):e.emit("close")}),e}});var sW=E((Dnt,nW)=>{"use strict";var{Transform:uve,PassThrough:gve}=require("stream"),Ak=require("zlib"),fve=iW();nW.exports=t=>{let e=(t.headers["content-encoding"]||"").toLowerCase();if(!["gzip","deflate","br"].includes(e))return t;let r=e==="br";if(r&&typeof Ak.createBrotliDecompress!="function")return t.destroy(new Error("Brotli is not supported on Node.js < 12")),t;let i=!0,n=new uve({transform(a,l,c){i=!1,c(null,a)},flush(a){a()}}),s=new gve({autoDestroy:!1,destroy(a,l){t.destroy(),l(a)}}),o=r?Ak.createBrotliDecompress():Ak.createUnzip();return o.once("error",a=>{if(i&&!t.readable){s.end();return}s.destroy(a)}),fve(t,s),t.pipe(n).pipe(o).pipe(s),s}});var lk=E((Rnt,oW)=>{"use strict";var aW=class{constructor(e={}){if(!(e.maxSize&&e.maxSize>0))throw new TypeError("`maxSize` must be a number greater than 0");this.maxSize=e.maxSize,this.onEviction=e.onEviction,this.cache=new Map,this.oldCache=new Map,this._size=0}_set(e,r){if(this.cache.set(e,r),this._size++,this._size>=this.maxSize){if(this._size=0,typeof this.onEviction=="function")for(let[i,n]of this.oldCache.entries())this.onEviction(i,n);this.oldCache=this.cache,this.cache=new Map}}get(e){if(this.cache.has(e))return this.cache.get(e);if(this.oldCache.has(e)){let r=this.oldCache.get(e);return this.oldCache.delete(e),this._set(e,r),r}}set(e,r){return this.cache.has(e)?this.cache.set(e,r):this._set(e,r),this}has(e){return this.cache.has(e)||this.oldCache.has(e)}peek(e){if(this.cache.has(e))return this.cache.get(e);if(this.oldCache.has(e))return this.oldCache.get(e)}delete(e){let r=this.cache.delete(e);return r&&this._size--,this.oldCache.delete(e)||r}clear(){this.cache.clear(),this.oldCache.clear(),this._size=0}*keys(){for(let[e]of this)yield e}*values(){for(let[,e]of this)yield e}*[Symbol.iterator](){for(let e of this.cache)yield e;for(let e of this.oldCache){let[r]=e;this.cache.has(r)||(yield e)}}get size(){let e=0;for(let r of this.oldCache.keys())this.cache.has(r)||e++;return Math.min(this._size+e,this.maxSize)}};oW.exports=aW});var uk=E((Fnt,AW)=>{"use strict";var hve=require("events"),pve=require("tls"),dve=require("http2"),Cve=lk(),_i=Symbol("currentStreamsCount"),lW=Symbol("request"),ns=Symbol("cachedOriginSet"),Yu=Symbol("gracefullyClosing"),mve=["maxDeflateDynamicTableSize","maxSessionMemory","maxHeaderListPairs","maxOutstandingPings","maxReservedRemoteStreams","maxSendHeaderBlockLength","paddingStrategy","localAddress","path","rejectUnauthorized","minDHSize","ca","cert","clientCertEngine","ciphers","key","pfx","servername","minVersion","maxVersion","secureProtocol","crl","honorCipherOrder","ecdhCurve","dhparam","secureOptions","sessionIdContext"],Eve=(t,e,r)=>{let i=0,n=t.length;for(;i>>1;r(t[s],e)?i=s+1:n=s}return i},Ive=(t,e)=>t.remoteSettings.maxConcurrentStreams>e.remoteSettings.maxConcurrentStreams,ck=(t,e)=>{for(let r of t)r[ns].lengthe[ns].includes(i))&&r[_i]+e[_i]<=e.remoteSettings.maxConcurrentStreams&&cW(r)},yve=(t,e)=>{for(let r of t)e[ns].lengthr[ns].includes(i))&&e[_i]+r[_i]<=r.remoteSettings.maxConcurrentStreams&&cW(e)},uW=({agent:t,isFree:e})=>{let r={};for(let i in t.sessions){let s=t.sessions[i].filter(o=>{let a=o[ma.kCurrentStreamsCount]{t[Yu]=!0,t[_i]===0&&t.close()},ma=class extends hve{constructor({timeout:e=6e4,maxSessions:r=Infinity,maxFreeSessions:i=10,maxCachedTlsSessions:n=100}={}){super();this.sessions={},this.queue={},this.timeout=e,this.maxSessions=r,this.maxFreeSessions=i,this._freeSessionsCount=0,this._sessionsCount=0,this.settings={enablePush:!1},this.tlsSessionCache=new Cve({maxSize:n})}static normalizeOrigin(e,r){return typeof e=="string"&&(e=new URL(e)),r&&e.hostname!==r&&(e.hostname=r),e.origin}normalizeOptions(e){let r="";if(e)for(let i of mve)e[i]&&(r+=`:${e[i]}`);return r}_tryToCreateNewSession(e,r){if(!(e in this.queue)||!(r in this.queue[e]))return;let i=this.queue[e][r];this._sessionsCount{Array.isArray(i)?(i=[...i],n()):i=[{resolve:n,reject:s}];let o=this.normalizeOptions(r),a=ma.normalizeOrigin(e,r&&r.servername);if(a===void 0){for(let{reject:u}of i)u(new TypeError("The `origin` argument needs to be a string or an URL object"));return}if(o in this.sessions){let u=this.sessions[o],g=-1,f=-1,h;for(let p of u){let d=p.remoteSettings.maxConcurrentStreams;if(d=d||p[Yu]||p.destroyed)continue;h||(g=d),m>f&&(h=p,f=m)}}if(h){if(i.length!==1){for(let{reject:p}of i){let d=new Error(`Expected the length of listeners to be 1, got ${i.length}. -Please report this to https://github.com/szmarczak/http2-wrapper/`);p(d)}return}i[0].resolve(h);return}}if(o in this.queue){if(a in this.queue[o]){this.queue[o][a].listeners.push(...i),this._tryToCreateNewSession(o,a);return}}else this.queue[o]={};let l=()=>{o in this.queue&&this.queue[o][a]===c&&(delete this.queue[o][a],Object.keys(this.queue[o]).length===0&&delete this.queue[o])},c=()=>{let u=`${a}:${o}`,g=!1;try{let f=dve.connect(e,P({createConnection:this.createConnection,settings:this.settings,session:this.tlsSessionCache.get(u)},r));f[_i]=0,f[Yu]=!1;let h=()=>f[_i]{this.tlsSessionCache.set(u,m)}),f.once("error",m=>{for(let{reject:I}of i)I(m);this.tlsSessionCache.delete(u)}),f.setTimeout(this.timeout,()=>{f.destroy()}),f.once("close",()=>{if(g){p&&this._freeSessionsCount--,this._sessionsCount--;let m=this.sessions[o];m.splice(m.indexOf(f),1),m.length===0&&delete this.sessions[o]}else{let m=new Error("Session closed without receiving a SETTINGS frame");m.code="HTTP2WRAPPER_NOSETTINGS";for(let{reject:I}of i)I(m);l()}this._tryToCreateNewSession(o,a)});let d=()=>{if(!(!(o in this.queue)||!h())){for(let m of f[ns])if(m in this.queue[o]){let{listeners:I}=this.queue[o][m];for(;I.length!==0&&h();)I.shift().resolve(f);let B=this.queue[o];if(B[m].listeners.length===0&&(delete B[m],Object.keys(B).length===0)){delete this.queue[o];break}if(!h())break}}};f.on("origin",()=>{f[ns]=f.originSet,!!h()&&(d(),ck(this.sessions[o],f))}),f.once("remoteSettings",()=>{if(f.ref(),f.unref(),this._sessionsCount++,c.destroyed){let m=new Error("Agent has been destroyed");for(let I of i)I.reject(m);f.destroy();return}f[ns]=f.originSet;{let m=this.sessions;if(o in m){let I=m[o];I.splice(Eve(I,f,Ive),0,f)}else m[o]=[f]}this._freeSessionsCount+=1,g=!0,this.emit("session",f),d(),l(),f[_i]===0&&this._freeSessionsCount>this.maxFreeSessions&&f.close(),i.length!==0&&(this.getSession(a,r,i),i.length=0),f.on("remoteSettings",()=>{d(),ck(this.sessions[o],f)})}),f[lW]=f.request,f.request=(m,I)=>{if(f[Yu])throw new Error("The session is gracefully closing. No new streams are allowed.");let B=f[lW](m,I);return f.ref(),++f[_i],f[_i]===f.remoteSettings.maxConcurrentStreams&&this._freeSessionsCount--,B.once("close",()=>{if(p=h(),--f[_i],!f.destroyed&&!f.closed&&(yve(this.sessions[o],f),h()&&!f.closed)){p||(this._freeSessionsCount++,p=!0);let b=f[_i]===0;b&&f.unref(),b&&(this._freeSessionsCount>this.maxFreeSessions||f[Yu])?f.close():(ck(this.sessions[o],f),d())}}),B}}catch(f){for(let h of i)h.reject(f);l()}};c.listeners=i,c.completed=!1,c.destroyed=!1,this.queue[o][a]=c,this._tryToCreateNewSession(o,a)})}request(e,r,i,n){return new Promise((s,o)=>{this.getSession(e,r,[{reject:o,resolve:a=>{try{s(a.request(i,n))}catch(l){o(l)}}}])})}createConnection(e,r){return ma.connect(e,r)}static connect(e,r){r.ALPNProtocols=["h2"];let i=e.port||443,n=e.hostname||e.host;return typeof r.servername=="undefined"&&(r.servername=n),pve.connect(i,n,r)}closeFreeSessions(){for(let e of Object.values(this.sessions))for(let r of e)r[_i]===0&&r.close()}destroy(e){for(let r of Object.values(this.sessions))for(let i of r)i.destroy(e);for(let r of Object.values(this.queue))for(let i of Object.values(r))i.destroyed=!0;this.queue={}}get freeSessions(){return uW({agent:this,isFree:!0})}get busySessions(){return uW({agent:this,isFree:!1})}};ma.kCurrentStreamsCount=_i;ma.kGracefullyClosing=Yu;AW.exports={Agent:ma,globalAgent:new ma}});var gk=E((Nnt,gW)=>{"use strict";var{Readable:wve}=require("stream"),fW=class extends wve{constructor(e,r){super({highWaterMark:r,autoDestroy:!1});this.statusCode=null,this.statusMessage="",this.httpVersion="2.0",this.httpVersionMajor=2,this.httpVersionMinor=0,this.headers={},this.trailers={},this.req=null,this.aborted=!1,this.complete=!1,this.upgrade=null,this.rawHeaders=[],this.rawTrailers=[],this.socket=e,this.connection=e,this._dumped=!1}_destroy(e){this.req._request.destroy(e)}setTimeout(e,r){return this.req.setTimeout(e,r),this}_dump(){this._dumped||(this._dumped=!0,this.removeAllListeners("data"),this.resume())}_read(){this.req&&this.req._request.resume()}};gW.exports=fW});var fk=E((Lnt,hW)=>{"use strict";hW.exports=t=>{let e={protocol:t.protocol,hostname:typeof t.hostname=="string"&&t.hostname.startsWith("[")?t.hostname.slice(1,-1):t.hostname,host:t.host,hash:t.hash,search:t.search,pathname:t.pathname,href:t.href,path:`${t.pathname||""}${t.search||""}`};return typeof t.port=="string"&&t.port.length!==0&&(e.port=Number(t.port)),(t.username||t.password)&&(e.auth=`${t.username||""}:${t.password||""}`),e}});var dW=E((Tnt,pW)=>{"use strict";pW.exports=(t,e,r)=>{for(let i of r)t.on(i,(...n)=>e.emit(i,...n))}});var mW=E((Mnt,CW)=>{"use strict";CW.exports=t=>{switch(t){case":method":case":scheme":case":authority":case":path":return!0;default:return!1}}});var IW=E((Knt,EW)=>{"use strict";var qu=(t,e,r)=>{EW.exports[e]=class extends t{constructor(...n){super(typeof r=="string"?r:r(n));this.name=`${super.name} [${e}]`,this.code=e}}};qu(TypeError,"ERR_INVALID_ARG_TYPE",t=>{let e=t[0].includes(".")?"property":"argument",r=t[1],i=Array.isArray(r);return i&&(r=`${r.slice(0,-1).join(", ")} or ${r.slice(-1)}`),`The "${t[0]}" ${e} must be ${i?"one of":"of"} type ${r}. Received ${typeof t[2]}`});qu(TypeError,"ERR_INVALID_PROTOCOL",t=>`Protocol "${t[0]}" not supported. Expected "${t[1]}"`);qu(Error,"ERR_HTTP_HEADERS_SENT",t=>`Cannot ${t[0]} headers after they are sent to the client`);qu(TypeError,"ERR_INVALID_HTTP_TOKEN",t=>`${t[0]} must be a valid HTTP token [${t[1]}]`);qu(TypeError,"ERR_HTTP_INVALID_HEADER_VALUE",t=>`Invalid value "${t[0]} for header "${t[1]}"`);qu(TypeError,"ERR_INVALID_CHAR",t=>`Invalid character in ${t[0]} [${t[1]}]`)});var Ck=E((Unt,yW)=>{"use strict";var Bve=require("http2"),{Writable:Qve}=require("stream"),{Agent:wW,globalAgent:bve}=uk(),vve=gk(),Sve=fk(),xve=dW(),kve=mW(),{ERR_INVALID_ARG_TYPE:hk,ERR_INVALID_PROTOCOL:Pve,ERR_HTTP_HEADERS_SENT:BW,ERR_INVALID_HTTP_TOKEN:Dve,ERR_HTTP_INVALID_HEADER_VALUE:Rve,ERR_INVALID_CHAR:Fve}=IW(),{HTTP2_HEADER_STATUS:QW,HTTP2_HEADER_METHOD:bW,HTTP2_HEADER_PATH:vW,HTTP2_METHOD_CONNECT:Nve}=Bve.constants,Pi=Symbol("headers"),pk=Symbol("origin"),dk=Symbol("session"),SW=Symbol("options"),My=Symbol("flushedHeaders"),yp=Symbol("jobs"),Lve=/^[\^`\-\w!#$%&*+.|~]+$/,Tve=/[^\t\u0020-\u007E\u0080-\u00FF]/,xW=class extends Qve{constructor(e,r,i){super({autoDestroy:!1});let n=typeof e=="string"||e instanceof URL;if(n&&(e=Sve(e instanceof URL?e:new URL(e))),typeof r=="function"||r===void 0?(i=r,r=n?e:P({},e)):r=P(P({},e),r),r.h2session)this[dk]=r.h2session;else if(r.agent===!1)this.agent=new wW({maxFreeSessions:0});else if(typeof r.agent=="undefined"||r.agent===null)typeof r.createConnection=="function"?(this.agent=new wW({maxFreeSessions:0}),this.agent.createConnection=r.createConnection):this.agent=bve;else if(typeof r.agent.request=="function")this.agent=r.agent;else throw new hk("options.agent",["Agent-like Object","undefined","false"],r.agent);if(r.protocol&&r.protocol!=="https:")throw new Pve(r.protocol,"https:");let s=r.port||r.defaultPort||this.agent&&this.agent.defaultPort||443,o=r.hostname||r.host||"localhost";delete r.hostname,delete r.host,delete r.port;let{timeout:a}=r;if(r.timeout=void 0,this[Pi]=Object.create(null),this[yp]=[],this.socket=null,this.connection=null,this.method=r.method||"GET",this.path=r.path,this.res=null,this.aborted=!1,this.reusedSocket=!1,r.headers)for(let[l,c]of Object.entries(r.headers))this.setHeader(l,c);r.auth&&!("authorization"in this[Pi])&&(this[Pi].authorization="Basic "+Buffer.from(r.auth).toString("base64")),r.session=r.tlsSession,r.path=r.socketPath,this[SW]=r,s===443?(this[pk]=`https://${o}`,":authority"in this[Pi]||(this[Pi][":authority"]=o)):(this[pk]=`https://${o}:${s}`,":authority"in this[Pi]||(this[Pi][":authority"]=`${o}:${s}`)),a&&this.setTimeout(a),i&&this.once("response",i),this[My]=!1}get method(){return this[Pi][bW]}set method(e){e&&(this[Pi][bW]=e.toUpperCase())}get path(){return this[Pi][vW]}set path(e){e&&(this[Pi][vW]=e)}get _mustNotHaveABody(){return this.method==="GET"||this.method==="HEAD"||this.method==="DELETE"}_write(e,r,i){if(this._mustNotHaveABody){i(new Error("The GET, HEAD and DELETE methods must NOT have a body"));return}this.flushHeaders();let n=()=>this._request.write(e,r,i);this._request?n():this[yp].push(n)}_final(e){if(this.destroyed)return;this.flushHeaders();let r=()=>{if(this._mustNotHaveABody){e();return}this._request.end(e)};this._request?r():this[yp].push(r)}abort(){this.res&&this.res.complete||(this.aborted||process.nextTick(()=>this.emit("abort")),this.aborted=!0,this.destroy())}_destroy(e,r){this.res&&this.res._dump(),this._request&&this._request.destroy(),r(e)}async flushHeaders(){if(this[My]||this.destroyed)return;this[My]=!0;let e=this.method===Nve,r=i=>{if(this._request=i,this.destroyed){i.destroy();return}e||xve(i,this,["timeout","continue","close","error"]);let n=o=>(...a)=>{!this.writable&&!this.destroyed?o(...a):this.once("finish",()=>{o(...a)})};i.once("response",n((o,a,l)=>{let c=new vve(this.socket,i.readableHighWaterMark);this.res=c,c.req=this,c.statusCode=o[QW],c.headers=o,c.rawHeaders=l,c.once("end",()=>{this.aborted?(c.aborted=!0,c.emit("aborted")):(c.complete=!0,c.socket=null,c.connection=null)}),e?(c.upgrade=!0,this.emit("connect",c,i,Buffer.alloc(0))?this.emit("close"):i.destroy()):(i.on("data",u=>{!c._dumped&&!c.push(u)&&i.pause()}),i.once("end",()=>{c.push(null)}),this.emit("response",c)||c._dump())})),i.once("headers",n(o=>this.emit("information",{statusCode:o[QW]}))),i.once("trailers",n((o,a,l)=>{let{res:c}=this;c.trailers=o,c.rawTrailers=l}));let{socket:s}=i.session;this.socket=s,this.connection=s;for(let o of this[yp])o();this.emit("socket",this.socket)};if(this[dk])try{r(this[dk].request(this[Pi]))}catch(i){this.emit("error",i)}else{this.reusedSocket=!0;try{r(await this.agent.request(this[pk],this[SW],this[Pi]))}catch(i){this.emit("error",i)}}}getHeader(e){if(typeof e!="string")throw new hk("name","string",e);return this[Pi][e.toLowerCase()]}get headersSent(){return this[My]}removeHeader(e){if(typeof e!="string")throw new hk("name","string",e);if(this.headersSent)throw new BW("remove");delete this[Pi][e.toLowerCase()]}setHeader(e,r){if(this.headersSent)throw new BW("set");if(typeof e!="string"||!Lve.test(e)&&!kve(e))throw new Dve("Header name",e);if(typeof r=="undefined")throw new Rve(r,e);if(Tve.test(r))throw new Fve("header content",e);this[Pi][e.toLowerCase()]=r}setNoDelay(){}setSocketKeepAlive(){}setTimeout(e,r){let i=()=>this._request.setTimeout(e,r);return this._request?i():this[yp].push(i),this}get maxHeadersCount(){if(!this.destroyed&&this._request)return this._request.session.localSettings.maxHeaderListSize}set maxHeadersCount(e){}};yW.exports=xW});var PW=E((Hnt,kW)=>{"use strict";var Mve=require("tls");kW.exports=(t={})=>new Promise((e,r)=>{let i=Mve.connect(t,()=>{t.resolveSocket?(i.off("error",r),e({alpnProtocol:i.alpnProtocol,socket:i})):(i.destroy(),e({alpnProtocol:i.alpnProtocol}))});i.on("error",r)})});var RW=E((Gnt,DW)=>{"use strict";var Ove=require("net");DW.exports=t=>{let e=t.host,r=t.headers&&t.headers.host;return r&&(r.startsWith("[")?r.indexOf("]")===-1?e=r:e=r.slice(1,-1):e=r.split(":",1)[0]),Ove.isIP(e)?"":e}});var LW=E((jnt,mk)=>{"use strict";var FW=require("http"),Ek=require("https"),Kve=PW(),Uve=lk(),Hve=Ck(),Gve=RW(),jve=fk(),Oy=new Uve({maxSize:100}),wp=new Map,NW=(t,e,r)=>{e._httpMessage={shouldKeepAlive:!0};let i=()=>{t.emit("free",e,r)};e.on("free",i);let n=()=>{t.removeSocket(e,r)};e.on("close",n);let s=()=>{t.removeSocket(e,r),e.off("close",n),e.off("free",i),e.off("agentRemove",s)};e.on("agentRemove",s),t.emit("free",e,r)},Yve=async t=>{let e=`${t.host}:${t.port}:${t.ALPNProtocols.sort()}`;if(!Oy.has(e)){if(wp.has(e))return(await wp.get(e)).alpnProtocol;let{path:r,agent:i}=t;t.path=t.socketPath;let n=Kve(t);wp.set(e,n);try{let{socket:s,alpnProtocol:o}=await n;if(Oy.set(e,o),t.path=r,o==="h2")s.destroy();else{let{globalAgent:a}=Ek,l=Ek.Agent.prototype.createConnection;i?i.createConnection===l?NW(i,s,t):s.destroy():a.createConnection===l?NW(a,s,t):s.destroy()}return wp.delete(e),o}catch(s){throw wp.delete(e),s}}return Oy.get(e)};mk.exports=async(t,e,r)=>{if((typeof t=="string"||t instanceof URL)&&(t=jve(new URL(t))),typeof e=="function"&&(r=e,e=void 0),e=_(P(P({ALPNProtocols:["h2","http/1.1"]},t),e),{resolveSocket:!0}),!Array.isArray(e.ALPNProtocols)||e.ALPNProtocols.length===0)throw new Error("The `ALPNProtocols` option must be an Array with at least one entry");e.protocol=e.protocol||"https:";let i=e.protocol==="https:";e.host=e.hostname||e.host||"localhost",e.session=e.tlsSession,e.servername=e.servername||Gve(e),e.port=e.port||(i?443:80),e._defaultAgent=i?Ek.globalAgent:FW.globalAgent;let n=e.agent;if(n){if(n.addRequest)throw new Error("The `options.agent` object can contain only `http`, `https` or `http2` properties");e.agent=n[i?"https":"http"]}return i&&await Yve(e)==="h2"?(n&&(e.agent=n.http2),new Hve(e,r)):FW.request(e,r)};mk.exports.protocolCache=Oy});var MW=E((Ynt,TW)=>{"use strict";var qve=require("http2"),Jve=uk(),Ik=Ck(),Wve=gk(),zve=LW(),Vve=(t,e,r)=>new Ik(t,e,r),_ve=(t,e,r)=>{let i=new Ik(t,e,r);return i.end(),i};TW.exports=_(P(_(P({},qve),{ClientRequest:Ik,IncomingMessage:Wve}),Jve),{request:Vve,get:_ve,auto:zve})});var wk=E(yk=>{"use strict";Object.defineProperty(yk,"__esModule",{value:!0});var OW=Ca();yk.default=t=>OW.default.nodeStream(t)&&OW.default.function_(t.getBoundary)});var GW=E(Bk=>{"use strict";Object.defineProperty(Bk,"__esModule",{value:!0});var KW=require("fs"),UW=require("util"),HW=Ca(),Xve=wk(),Zve=UW.promisify(KW.stat);Bk.default=async(t,e)=>{if(e&&"content-length"in e)return Number(e["content-length"]);if(!t)return 0;if(HW.default.string(t))return Buffer.byteLength(t);if(HW.default.buffer(t))return t.length;if(Xve.default(t))return UW.promisify(t.getLength.bind(t))();if(t instanceof KW.ReadStream){let{size:r}=await Zve(t.path);return r===0?void 0:r}}});var bk=E(Qk=>{"use strict";Object.defineProperty(Qk,"__esModule",{value:!0});function $ve(t,e,r){let i={};for(let n of r)i[n]=(...s)=>{e.emit(n,...s)},t.on(n,i[n]);return()=>{for(let n of r)t.off(n,i[n])}}Qk.default=$ve});var jW=E(vk=>{"use strict";Object.defineProperty(vk,"__esModule",{value:!0});vk.default=()=>{let t=[];return{once(e,r,i){e.once(r,i),t.push({origin:e,event:r,fn:i})},unhandleAll(){for(let e of t){let{origin:r,event:i,fn:n}=e;r.removeListener(i,n)}t.length=0}}}});var qW=E(Bp=>{"use strict";Object.defineProperty(Bp,"__esModule",{value:!0});Bp.TimeoutError=void 0;var eSe=require("net"),tSe=jW(),YW=Symbol("reentry"),rSe=()=>{},Sk=class extends Error{constructor(e,r){super(`Timeout awaiting '${r}' for ${e}ms`);this.event=r,this.name="TimeoutError",this.code="ETIMEDOUT"}};Bp.TimeoutError=Sk;Bp.default=(t,e,r)=>{if(YW in t)return rSe;t[YW]=!0;let i=[],{once:n,unhandleAll:s}=tSe.default(),o=(g,f,h)=>{var p;let d=setTimeout(f,g,g,h);(p=d.unref)===null||p===void 0||p.call(d);let m=()=>{clearTimeout(d)};return i.push(m),m},{host:a,hostname:l}=r,c=(g,f)=>{t.destroy(new Sk(g,f))},u=()=>{for(let g of i)g();s()};if(t.once("error",g=>{if(u(),t.listenerCount("error")===0)throw g}),t.once("close",u),n(t,"response",g=>{n(g,"end",u)}),typeof e.request!="undefined"&&o(e.request,c,"request"),typeof e.socket!="undefined"){let g=()=>{c(e.socket,"socket")};t.setTimeout(e.socket,g),i.push(()=>{t.removeListener("timeout",g)})}return n(t,"socket",g=>{var f;let{socketPath:h}=t;if(g.connecting){let p=Boolean(h!=null?h:eSe.isIP((f=l!=null?l:a)!==null&&f!==void 0?f:"")!==0);if(typeof e.lookup!="undefined"&&!p&&typeof g.address().address=="undefined"){let d=o(e.lookup,c,"lookup");n(g,"lookup",d)}if(typeof e.connect!="undefined"){let d=()=>o(e.connect,c,"connect");p?n(g,"connect",d()):n(g,"lookup",m=>{m===null&&n(g,"connect",d())})}typeof e.secureConnect!="undefined"&&r.protocol==="https:"&&n(g,"connect",()=>{let d=o(e.secureConnect,c,"secureConnect");n(g,"secureConnect",d)})}if(typeof e.send!="undefined"){let p=()=>o(e.send,c,"send");g.connecting?n(g,"connect",()=>{n(t,"upload-complete",p())}):n(t,"upload-complete",p())}}),typeof e.response!="undefined"&&n(t,"upload-complete",()=>{let g=o(e.response,c,"response");n(t,"response",g)}),u}});var WW=E(xk=>{"use strict";Object.defineProperty(xk,"__esModule",{value:!0});var JW=Ca();xk.default=t=>{t=t;let e={protocol:t.protocol,hostname:JW.default.string(t.hostname)&&t.hostname.startsWith("[")?t.hostname.slice(1,-1):t.hostname,host:t.host,hash:t.hash,search:t.search,pathname:t.pathname,href:t.href,path:`${t.pathname||""}${t.search||""}`};return JW.default.string(t.port)&&t.port.length>0&&(e.port=Number(t.port)),(t.username||t.password)&&(e.auth=`${t.username||""}:${t.password||""}`),e}});var zW=E(kk=>{"use strict";Object.defineProperty(kk,"__esModule",{value:!0});var iSe=require("url"),nSe=["protocol","host","hostname","port","pathname","search"];kk.default=(t,e)=>{var r,i;if(e.path){if(e.pathname)throw new TypeError("Parameters `path` and `pathname` are mutually exclusive.");if(e.search)throw new TypeError("Parameters `path` and `search` are mutually exclusive.");if(e.searchParams)throw new TypeError("Parameters `path` and `searchParams` are mutually exclusive.")}if(e.search&&e.searchParams)throw new TypeError("Parameters `search` and `searchParams` are mutually exclusive.");if(!t){if(!e.protocol)throw new TypeError("No URL protocol specified");t=`${e.protocol}//${(i=(r=e.hostname)!==null&&r!==void 0?r:e.host)!==null&&i!==void 0?i:""}`}let n=new iSe.URL(t);if(e.path){let s=e.path.indexOf("?");s===-1?e.pathname=e.path:(e.pathname=e.path.slice(0,s),e.search=e.path.slice(s+1)),delete e.path}for(let s of nSe)e[s]&&(n[s]=e[s].toString());return n}});var _W=E(Pk=>{"use strict";Object.defineProperty(Pk,"__esModule",{value:!0});var VW=class{constructor(){this.weakMap=new WeakMap,this.map=new Map}set(e,r){typeof e=="object"?this.weakMap.set(e,r):this.map.set(e,r)}get(e){return typeof e=="object"?this.weakMap.get(e):this.map.get(e)}has(e){return typeof e=="object"?this.weakMap.has(e):this.map.has(e)}};Pk.default=VW});var Rk=E(Dk=>{"use strict";Object.defineProperty(Dk,"__esModule",{value:!0});var sSe=async t=>{let e=[],r=0;for await(let i of t)e.push(i),r+=Buffer.byteLength(i);return Buffer.isBuffer(e[0])?Buffer.concat(e,r):Buffer.from(e.join(""))};Dk.default=sSe});var ZW=E(ql=>{"use strict";Object.defineProperty(ql,"__esModule",{value:!0});ql.dnsLookupIpVersionToFamily=ql.isDnsLookupIpVersion=void 0;var XW={auto:0,ipv4:4,ipv6:6};ql.isDnsLookupIpVersion=t=>t in XW;ql.dnsLookupIpVersionToFamily=t=>{if(ql.isDnsLookupIpVersion(t))return XW[t];throw new Error("Invalid DNS lookup IP version")}});var Fk=E(Ky=>{"use strict";Object.defineProperty(Ky,"__esModule",{value:!0});Ky.isResponseOk=void 0;Ky.isResponseOk=t=>{let{statusCode:e}=t,r=t.request.options.followRedirect?299:399;return e>=200&&e<=r||e===304}});var e8=E(Nk=>{"use strict";Object.defineProperty(Nk,"__esModule",{value:!0});var $W=new Set;Nk.default=t=>{$W.has(t)||($W.add(t),process.emitWarning(`Got: ${t}`,{type:"DeprecationWarning"}))}});var t8=E(Lk=>{"use strict";Object.defineProperty(Lk,"__esModule",{value:!0});var ar=Ca(),oSe=(t,e)=>{if(ar.default.null_(t.encoding))throw new TypeError("To get a Buffer, set `options.responseType` to `buffer` instead");ar.assert.any([ar.default.string,ar.default.undefined],t.encoding),ar.assert.any([ar.default.boolean,ar.default.undefined],t.resolveBodyOnly),ar.assert.any([ar.default.boolean,ar.default.undefined],t.methodRewriting),ar.assert.any([ar.default.boolean,ar.default.undefined],t.isStream),ar.assert.any([ar.default.string,ar.default.undefined],t.responseType),t.responseType===void 0&&(t.responseType="text");let{retry:r}=t;if(e?t.retry=P({},e.retry):t.retry={calculateDelay:i=>i.computedValue,limit:0,methods:[],statusCodes:[],errorCodes:[],maxRetryAfter:void 0},ar.default.object(r)?(t.retry=P(P({},t.retry),r),t.retry.methods=[...new Set(t.retry.methods.map(i=>i.toUpperCase()))],t.retry.statusCodes=[...new Set(t.retry.statusCodes)],t.retry.errorCodes=[...new Set(t.retry.errorCodes)]):ar.default.number(r)&&(t.retry.limit=r),ar.default.undefined(t.retry.maxRetryAfter)&&(t.retry.maxRetryAfter=Math.min(...[t.timeout.request,t.timeout.connect].filter(ar.default.number))),ar.default.object(t.pagination)){e&&(t.pagination=P(P({},e.pagination),t.pagination));let{pagination:i}=t;if(!ar.default.function_(i.transform))throw new Error("`options.pagination.transform` must be implemented");if(!ar.default.function_(i.shouldContinue))throw new Error("`options.pagination.shouldContinue` must be implemented");if(!ar.default.function_(i.filter))throw new TypeError("`options.pagination.filter` must be implemented");if(!ar.default.function_(i.paginate))throw new Error("`options.pagination.paginate` must be implemented")}return t.responseType==="json"&&t.headers.accept===void 0&&(t.headers.accept="application/json"),t};Lk.default=oSe});var r8=E(Qp=>{"use strict";Object.defineProperty(Qp,"__esModule",{value:!0});Qp.retryAfterStatusCodes=void 0;Qp.retryAfterStatusCodes=new Set([413,429,503]);var aSe=({attemptCount:t,retryOptions:e,error:r,retryAfter:i})=>{if(t>e.limit)return 0;let n=e.methods.includes(r.options.method),s=e.errorCodes.includes(r.code),o=r.response&&e.statusCodes.includes(r.response.statusCode);if(!n||!s&&!o)return 0;if(r.response){if(i)return e.maxRetryAfter===void 0||i>e.maxRetryAfter?0:i;if(r.response.statusCode===413)return 0}let a=Math.random()*100;return 2**(t-1)*1e3+a};Qp.default=aSe});var vp=E(Rt=>{"use strict";Object.defineProperty(Rt,"__esModule",{value:!0});Rt.UnsupportedProtocolError=Rt.ReadError=Rt.TimeoutError=Rt.UploadError=Rt.CacheError=Rt.HTTPError=Rt.MaxRedirectsError=Rt.RequestError=Rt.setNonEnumerableProperties=Rt.knownHookEvents=Rt.withoutBody=Rt.kIsNormalizedAlready=void 0;var i8=require("util"),n8=require("stream"),ASe=require("fs"),dA=require("url"),s8=require("http"),Tk=require("http"),lSe=require("https"),cSe=h3(),uSe=y3(),o8=tW(),gSe=sW(),fSe=MW(),hSe=Ly(),ce=Ca(),pSe=GW(),a8=wk(),dSe=bk(),A8=qW(),CSe=WW(),l8=zW(),mSe=_W(),ESe=Rk(),c8=ZW(),ISe=Fk(),CA=e8(),ySe=t8(),wSe=r8(),Mk,Ei=Symbol("request"),Uy=Symbol("response"),Ju=Symbol("responseSize"),Wu=Symbol("downloadedSize"),zu=Symbol("bodySize"),Vu=Symbol("uploadedSize"),Hy=Symbol("serverResponsesPiped"),u8=Symbol("unproxyEvents"),g8=Symbol("isFromCache"),Ok=Symbol("cancelTimeouts"),f8=Symbol("startedReading"),_u=Symbol("stopReading"),Gy=Symbol("triggerRead"),mA=Symbol("body"),bp=Symbol("jobs"),h8=Symbol("originalResponse"),p8=Symbol("retryTimeout");Rt.kIsNormalizedAlready=Symbol("isNormalizedAlready");var BSe=ce.default.string(process.versions.brotli);Rt.withoutBody=new Set(["GET","HEAD"]);Rt.knownHookEvents=["init","beforeRequest","beforeRedirect","beforeError","beforeRetry","afterResponse"];function QSe(t){for(let e in t){let r=t[e];if(!ce.default.string(r)&&!ce.default.number(r)&&!ce.default.boolean(r)&&!ce.default.null_(r)&&!ce.default.undefined(r))throw new TypeError(`The \`searchParams\` value '${String(r)}' must be a string, number, boolean or null`)}}function bSe(t){return ce.default.object(t)&&!("statusCode"in t)}var Kk=new mSe.default,vSe=async t=>new Promise((e,r)=>{let i=n=>{r(n)};t.pending||e(),t.once("error",i),t.once("ready",()=>{t.off("error",i),e()})}),SSe=new Set([300,301,302,303,304,307,308]),xSe=["context","body","json","form"];Rt.setNonEnumerableProperties=(t,e)=>{let r={};for(let i of t)if(!!i)for(let n of xSe)n in i&&(r[n]={writable:!0,configurable:!0,enumerable:!1,value:i[n]});Object.defineProperties(e,r)};var _r=class extends Error{constructor(e,r,i){var n;super(e);if(Error.captureStackTrace(this,this.constructor),this.name="RequestError",this.code=r.code,i instanceof Uk?(Object.defineProperty(this,"request",{enumerable:!1,value:i}),Object.defineProperty(this,"response",{enumerable:!1,value:i[Uy]}),Object.defineProperty(this,"options",{enumerable:!1,value:i.options})):Object.defineProperty(this,"options",{enumerable:!1,value:i}),this.timings=(n=this.request)===null||n===void 0?void 0:n.timings,ce.default.string(r.stack)&&ce.default.string(this.stack)){let s=this.stack.indexOf(this.message)+this.message.length,o=this.stack.slice(s).split(` -`).reverse(),a=r.stack.slice(r.stack.indexOf(r.message)+r.message.length).split(` -`).reverse();for(;a.length!==0&&a[0]===o[0];)o.shift();this.stack=`${this.stack.slice(0,s)}${o.reverse().join(` -`)}${a.reverse().join(` -`)}`}}};Rt.RequestError=_r;var Hk=class extends _r{constructor(e){super(`Redirected ${e.options.maxRedirects} times. Aborting.`,{},e);this.name="MaxRedirectsError"}};Rt.MaxRedirectsError=Hk;var Gk=class extends _r{constructor(e){super(`Response code ${e.statusCode} (${e.statusMessage})`,{},e.request);this.name="HTTPError"}};Rt.HTTPError=Gk;var jk=class extends _r{constructor(e,r){super(e.message,e,r);this.name="CacheError"}};Rt.CacheError=jk;var Yk=class extends _r{constructor(e,r){super(e.message,e,r);this.name="UploadError"}};Rt.UploadError=Yk;var qk=class extends _r{constructor(e,r,i){super(e.message,e,i);this.name="TimeoutError",this.event=e.event,this.timings=r}};Rt.TimeoutError=qk;var jy=class extends _r{constructor(e,r){super(e.message,e,r);this.name="ReadError"}};Rt.ReadError=jy;var Jk=class extends _r{constructor(e){super(`Unsupported protocol "${e.url.protocol}"`,{},e);this.name="UnsupportedProtocolError"}};Rt.UnsupportedProtocolError=Jk;var kSe=["socket","connect","continue","information","upgrade","timeout"],Uk=class extends n8.Duplex{constructor(e,r={},i){super({autoDestroy:!1,highWaterMark:0});this[Wu]=0,this[Vu]=0,this.requestInitialized=!1,this[Hy]=new Set,this.redirects=[],this[_u]=!1,this[Gy]=!1,this[bp]=[],this.retryCount=0,this._progressCallbacks=[];let n=()=>this._unlockWrite(),s=()=>this._lockWrite();this.on("pipe",c=>{c.prependListener("data",n),c.on("data",s),c.prependListener("end",n),c.on("end",s)}),this.on("unpipe",c=>{c.off("data",n),c.off("data",s),c.off("end",n),c.off("end",s)}),this.on("pipe",c=>{c instanceof Tk.IncomingMessage&&(this.options.headers=P(P({},c.headers),this.options.headers))});let{json:o,body:a,form:l}=r;if((o||a||l)&&this._lockWrite(),Rt.kIsNormalizedAlready in r)this.options=r;else try{this.options=this.constructor.normalizeArguments(e,r,i)}catch(c){ce.default.nodeStream(r.body)&&r.body.destroy(),this.destroy(c);return}(async()=>{var c;try{this.options.body instanceof ASe.ReadStream&&await vSe(this.options.body);let{url:u}=this.options;if(!u)throw new TypeError("Missing `url` property");if(this.requestUrl=u.toString(),decodeURI(this.requestUrl),await this._finalizeBody(),await this._makeRequest(),this.destroyed){(c=this[Ei])===null||c===void 0||c.destroy();return}for(let g of this[bp])g();this[bp].length=0,this.requestInitialized=!0}catch(u){if(u instanceof _r){this._beforeError(u);return}this.destroyed||this.destroy(u)}})()}static normalizeArguments(e,r,i){var n,s,o,a,l;let c=r;if(ce.default.object(e)&&!ce.default.urlInstance(e))r=P(P(P({},i),e),r);else{if(e&&r&&r.url!==void 0)throw new TypeError("The `url` option is mutually exclusive with the `input` argument");r=P(P({},i),r),e!==void 0&&(r.url=e),ce.default.urlInstance(r.url)&&(r.url=new dA.URL(r.url.toString()))}if(r.cache===!1&&(r.cache=void 0),r.dnsCache===!1&&(r.dnsCache=void 0),ce.assert.any([ce.default.string,ce.default.undefined],r.method),ce.assert.any([ce.default.object,ce.default.undefined],r.headers),ce.assert.any([ce.default.string,ce.default.urlInstance,ce.default.undefined],r.prefixUrl),ce.assert.any([ce.default.object,ce.default.undefined],r.cookieJar),ce.assert.any([ce.default.object,ce.default.string,ce.default.undefined],r.searchParams),ce.assert.any([ce.default.object,ce.default.string,ce.default.undefined],r.cache),ce.assert.any([ce.default.object,ce.default.number,ce.default.undefined],r.timeout),ce.assert.any([ce.default.object,ce.default.undefined],r.context),ce.assert.any([ce.default.object,ce.default.undefined],r.hooks),ce.assert.any([ce.default.boolean,ce.default.undefined],r.decompress),ce.assert.any([ce.default.boolean,ce.default.undefined],r.ignoreInvalidCookies),ce.assert.any([ce.default.boolean,ce.default.undefined],r.followRedirect),ce.assert.any([ce.default.number,ce.default.undefined],r.maxRedirects),ce.assert.any([ce.default.boolean,ce.default.undefined],r.throwHttpErrors),ce.assert.any([ce.default.boolean,ce.default.undefined],r.http2),ce.assert.any([ce.default.boolean,ce.default.undefined],r.allowGetBody),ce.assert.any([ce.default.string,ce.default.undefined],r.localAddress),ce.assert.any([c8.isDnsLookupIpVersion,ce.default.undefined],r.dnsLookupIpVersion),ce.assert.any([ce.default.object,ce.default.undefined],r.https),ce.assert.any([ce.default.boolean,ce.default.undefined],r.rejectUnauthorized),r.https&&(ce.assert.any([ce.default.boolean,ce.default.undefined],r.https.rejectUnauthorized),ce.assert.any([ce.default.function_,ce.default.undefined],r.https.checkServerIdentity),ce.assert.any([ce.default.string,ce.default.object,ce.default.array,ce.default.undefined],r.https.certificateAuthority),ce.assert.any([ce.default.string,ce.default.object,ce.default.array,ce.default.undefined],r.https.key),ce.assert.any([ce.default.string,ce.default.object,ce.default.array,ce.default.undefined],r.https.certificate),ce.assert.any([ce.default.string,ce.default.undefined],r.https.passphrase),ce.assert.any([ce.default.string,ce.default.buffer,ce.default.array,ce.default.undefined],r.https.pfx)),ce.assert.any([ce.default.object,ce.default.undefined],r.cacheOptions),ce.default.string(r.method)?r.method=r.method.toUpperCase():r.method="GET",r.headers===(i==null?void 0:i.headers)?r.headers=P({},r.headers):r.headers=hSe(P(P({},i==null?void 0:i.headers),r.headers)),"slashes"in r)throw new TypeError("The legacy `url.Url` has been deprecated. Use `URL` instead.");if("auth"in r)throw new TypeError("Parameter `auth` is deprecated. Use `username` / `password` instead.");if("searchParams"in r&&r.searchParams&&r.searchParams!==(i==null?void 0:i.searchParams)){let h;if(ce.default.string(r.searchParams)||r.searchParams instanceof dA.URLSearchParams)h=new dA.URLSearchParams(r.searchParams);else{QSe(r.searchParams),h=new dA.URLSearchParams;for(let p in r.searchParams){let d=r.searchParams[p];d===null?h.append(p,""):d!==void 0&&h.append(p,d)}}(n=i==null?void 0:i.searchParams)===null||n===void 0||n.forEach((p,d)=>{h.has(d)||h.append(d,p)}),r.searchParams=h}if(r.username=(s=r.username)!==null&&s!==void 0?s:"",r.password=(o=r.password)!==null&&o!==void 0?o:"",ce.default.undefined(r.prefixUrl)?r.prefixUrl=(a=i==null?void 0:i.prefixUrl)!==null&&a!==void 0?a:"":(r.prefixUrl=r.prefixUrl.toString(),r.prefixUrl!==""&&!r.prefixUrl.endsWith("/")&&(r.prefixUrl+="/")),ce.default.string(r.url)){if(r.url.startsWith("/"))throw new Error("`input` must not start with a slash when using `prefixUrl`");r.url=l8.default(r.prefixUrl+r.url,r)}else(ce.default.undefined(r.url)&&r.prefixUrl!==""||r.protocol)&&(r.url=l8.default(r.prefixUrl,r));if(r.url){"port"in r&&delete r.port;let{prefixUrl:h}=r;Object.defineProperty(r,"prefixUrl",{set:d=>{let m=r.url;if(!m.href.startsWith(d))throw new Error(`Cannot change \`prefixUrl\` from ${h} to ${d}: ${m.href}`);r.url=new dA.URL(d+m.href.slice(h.length)),h=d},get:()=>h});let{protocol:p}=r.url;if(p==="unix:"&&(p="http:",r.url=new dA.URL(`http://unix${r.url.pathname}${r.url.search}`)),r.searchParams&&(r.url.search=r.searchParams.toString()),p!=="http:"&&p!=="https:")throw new Jk(r);r.username===""?r.username=r.url.username:r.url.username=r.username,r.password===""?r.password=r.url.password:r.url.password=r.password}let{cookieJar:u}=r;if(u){let{setCookie:h,getCookieString:p}=u;ce.assert.function_(h),ce.assert.function_(p),h.length===4&&p.length===0&&(h=i8.promisify(h.bind(r.cookieJar)),p=i8.promisify(p.bind(r.cookieJar)),r.cookieJar={setCookie:h,getCookieString:p})}let{cache:g}=r;if(g&&(Kk.has(g)||Kk.set(g,new o8((h,p)=>{let d=h[Ei](h,p);return ce.default.promise(d)&&(d.once=(m,I)=>{if(m==="error")d.catch(I);else if(m==="abort")(async()=>{try{(await d).once("abort",I)}catch(B){}})();else throw new Error(`Unknown HTTP2 promise event: ${m}`);return d}),d},g))),r.cacheOptions=P({},r.cacheOptions),r.dnsCache===!0)Mk||(Mk=new uSe.default),r.dnsCache=Mk;else if(!ce.default.undefined(r.dnsCache)&&!r.dnsCache.lookup)throw new TypeError(`Parameter \`dnsCache\` must be a CacheableLookup instance or a boolean, got ${ce.default(r.dnsCache)}`);ce.default.number(r.timeout)?r.timeout={request:r.timeout}:i&&r.timeout!==i.timeout?r.timeout=P(P({},i.timeout),r.timeout):r.timeout=P({},r.timeout),r.context||(r.context={});let f=r.hooks===(i==null?void 0:i.hooks);r.hooks=P({},r.hooks);for(let h of Rt.knownHookEvents)if(h in r.hooks)if(ce.default.array(r.hooks[h]))r.hooks[h]=[...r.hooks[h]];else throw new TypeError(`Parameter \`${h}\` must be an Array, got ${ce.default(r.hooks[h])}`);else r.hooks[h]=[];if(i&&!f)for(let h of Rt.knownHookEvents)i.hooks[h].length>0&&(r.hooks[h]=[...i.hooks[h],...r.hooks[h]]);if("family"in r&&CA.default('"options.family" was never documented, please use "options.dnsLookupIpVersion"'),(i==null?void 0:i.https)&&(r.https=P(P({},i.https),r.https)),"rejectUnauthorized"in r&&CA.default('"options.rejectUnauthorized" is now deprecated, please use "options.https.rejectUnauthorized"'),"checkServerIdentity"in r&&CA.default('"options.checkServerIdentity" was never documented, please use "options.https.checkServerIdentity"'),"ca"in r&&CA.default('"options.ca" was never documented, please use "options.https.certificateAuthority"'),"key"in r&&CA.default('"options.key" was never documented, please use "options.https.key"'),"cert"in r&&CA.default('"options.cert" was never documented, please use "options.https.certificate"'),"passphrase"in r&&CA.default('"options.passphrase" was never documented, please use "options.https.passphrase"'),"pfx"in r&&CA.default('"options.pfx" was never documented, please use "options.https.pfx"'),"followRedirects"in r)throw new TypeError("The `followRedirects` option does not exist. Use `followRedirect` instead.");if(r.agent){for(let h in r.agent)if(h!=="http"&&h!=="https"&&h!=="http2")throw new TypeError(`Expected the \`options.agent\` properties to be \`http\`, \`https\` or \`http2\`, got \`${h}\``)}return r.maxRedirects=(l=r.maxRedirects)!==null&&l!==void 0?l:0,Rt.setNonEnumerableProperties([i,c],r),ySe.default(r,i)}_lockWrite(){let e=()=>{throw new TypeError("The payload has been already provided")};this.write=e,this.end=e}_unlockWrite(){this.write=super.write,this.end=super.end}async _finalizeBody(){let{options:e}=this,{headers:r}=e,i=!ce.default.undefined(e.form),n=!ce.default.undefined(e.json),s=!ce.default.undefined(e.body),o=i||n||s,a=Rt.withoutBody.has(e.method)&&!(e.method==="GET"&&e.allowGetBody);if(this._cannotHaveBody=a,o){if(a)throw new TypeError(`The \`${e.method}\` method cannot be used with a body`);if([s,i,n].filter(l=>l).length>1)throw new TypeError("The `body`, `json` and `form` options are mutually exclusive");if(s&&!(e.body instanceof n8.Readable)&&!ce.default.string(e.body)&&!ce.default.buffer(e.body)&&!a8.default(e.body))throw new TypeError("The `body` option must be a stream.Readable, string or Buffer");if(i&&!ce.default.object(e.form))throw new TypeError("The `form` option must be an Object");{let l=!ce.default.string(r["content-type"]);s?(a8.default(e.body)&&l&&(r["content-type"]=`multipart/form-data; boundary=${e.body.getBoundary()}`),this[mA]=e.body):i?(l&&(r["content-type"]="application/x-www-form-urlencoded"),this[mA]=new dA.URLSearchParams(e.form).toString()):(l&&(r["content-type"]="application/json"),this[mA]=e.stringifyJson(e.json));let c=await pSe.default(this[mA],e.headers);ce.default.undefined(r["content-length"])&&ce.default.undefined(r["transfer-encoding"])&&!a&&!ce.default.undefined(c)&&(r["content-length"]=String(c))}}else a?this._lockWrite():this._unlockWrite();this[zu]=Number(r["content-length"])||void 0}async _onResponseBase(e){let{options:r}=this,{url:i}=r;this[h8]=e,r.decompress&&(e=gSe(e));let n=e.statusCode,s=e;s.statusMessage=s.statusMessage?s.statusMessage:s8.STATUS_CODES[n],s.url=r.url.toString(),s.requestUrl=this.requestUrl,s.redirectUrls=this.redirects,s.request=this,s.isFromCache=e.fromCache||!1,s.ip=this.ip,s.retryCount=this.retryCount,this[g8]=s.isFromCache,this[Ju]=Number(e.headers["content-length"])||void 0,this[Uy]=e,e.once("end",()=>{this[Ju]=this[Wu],this.emit("downloadProgress",this.downloadProgress)}),e.once("error",a=>{e.destroy(),this._beforeError(new jy(a,this))}),e.once("aborted",()=>{this._beforeError(new jy({name:"Error",message:"The server aborted pending request",code:"ECONNRESET"},this))}),this.emit("downloadProgress",this.downloadProgress);let o=e.headers["set-cookie"];if(ce.default.object(r.cookieJar)&&o){let a=o.map(async l=>r.cookieJar.setCookie(l,i.toString()));r.ignoreInvalidCookies&&(a=a.map(async l=>l.catch(()=>{})));try{await Promise.all(a)}catch(l){this._beforeError(l);return}}if(r.followRedirect&&e.headers.location&&SSe.has(n)){if(e.resume(),this[Ei]&&(this[Ok](),delete this[Ei],this[u8]()),(n===303&&r.method!=="GET"&&r.method!=="HEAD"||!r.methodRewriting)&&(r.method="GET","body"in r&&delete r.body,"json"in r&&delete r.json,"form"in r&&delete r.form,this[mA]=void 0,delete r.headers["content-length"]),this.redirects.length>=r.maxRedirects){this._beforeError(new Hk(this));return}try{let l=Buffer.from(e.headers.location,"binary").toString(),c=new dA.URL(l,i),u=c.toString();decodeURI(u),c.hostname!==i.hostname||c.port!==i.port?("host"in r.headers&&delete r.headers.host,"cookie"in r.headers&&delete r.headers.cookie,"authorization"in r.headers&&delete r.headers.authorization,(r.username||r.password)&&(r.username="",r.password="")):(c.username=r.username,c.password=r.password),this.redirects.push(u),r.url=c;for(let g of r.hooks.beforeRedirect)await g(r,s);this.emit("redirect",s,r),await this._makeRequest()}catch(l){this._beforeError(l);return}return}if(r.isStream&&r.throwHttpErrors&&!ISe.isResponseOk(s)){this._beforeError(new Gk(s));return}e.on("readable",()=>{this[Gy]&&this._read()}),this.on("resume",()=>{e.resume()}),this.on("pause",()=>{e.pause()}),e.once("end",()=>{this.push(null)}),this.emit("response",e);for(let a of this[Hy])if(!a.headersSent){for(let l in e.headers){let c=r.decompress?l!=="content-encoding":!0,u=e.headers[l];c&&a.setHeader(l,u)}a.statusCode=n}}async _onResponse(e){try{await this._onResponseBase(e)}catch(r){this._beforeError(r)}}_onRequest(e){let{options:r}=this,{timeout:i,url:n}=r;cSe.default(e),this[Ok]=A8.default(e,i,n);let s=r.cache?"cacheableResponse":"response";e.once(s,l=>{this._onResponse(l)}),e.once("error",l=>{var c;e.destroy(),(c=e.res)===null||c===void 0||c.removeAllListeners("end"),l=l instanceof A8.TimeoutError?new qk(l,this.timings,this):new _r(l.message,l,this),this._beforeError(l)}),this[u8]=dSe.default(e,this,kSe),this[Ei]=e,this.emit("uploadProgress",this.uploadProgress);let o=this[mA],a=this.redirects.length===0?this:e;ce.default.nodeStream(o)?(o.pipe(a),o.once("error",l=>{this._beforeError(new Yk(l,this))})):(this._unlockWrite(),ce.default.undefined(o)?(this._cannotHaveBody||this._noPipe)&&(a.end(),this._lockWrite()):(this._writeRequest(o,void 0,()=>{}),a.end(),this._lockWrite())),this.emit("request",e)}async _createCacheableRequest(e,r){return new Promise((i,n)=>{Object.assign(r,CSe.default(e)),delete r.url;let s,o=Kk.get(r.cache)(r,async a=>{a._readableState.autoDestroy=!1,s&&(await s).emit("cacheableResponse",a),i(a)});r.url=e,o.once("error",n),o.once("request",async a=>{s=a,i(s)})})}async _makeRequest(){var e,r,i,n,s;let{options:o}=this,{headers:a}=o;for(let I in a)if(ce.default.undefined(a[I]))delete a[I];else if(ce.default.null_(a[I]))throw new TypeError(`Use \`undefined\` instead of \`null\` to delete the \`${I}\` header`);if(o.decompress&&ce.default.undefined(a["accept-encoding"])&&(a["accept-encoding"]=BSe?"gzip, deflate, br":"gzip, deflate"),o.cookieJar){let I=await o.cookieJar.getCookieString(o.url.toString());ce.default.nonEmptyString(I)&&(o.headers.cookie=I)}for(let I of o.hooks.beforeRequest){let B=await I(o);if(!ce.default.undefined(B)){o.request=()=>B;break}}o.body&&this[mA]!==o.body&&(this[mA]=o.body);let{agent:l,request:c,timeout:u,url:g}=o;if(o.dnsCache&&!("lookup"in o)&&(o.lookup=o.dnsCache.lookup),g.hostname==="unix"){let I=/(?.+?):(?.+)/.exec(`${g.pathname}${g.search}`);if(I==null?void 0:I.groups){let{socketPath:B,path:b}=I.groups;Object.assign(o,{socketPath:B,path:b,host:""})}}let f=g.protocol==="https:",h;o.http2?h=fSe.auto:h=f?lSe.request:s8.request;let p=(e=o.request)!==null&&e!==void 0?e:h,d=o.cache?this._createCacheableRequest:p;l&&!o.http2&&(o.agent=l[f?"https":"http"]),o[Ei]=p,delete o.request,delete o.timeout;let m=o;if(m.shared=(r=o.cacheOptions)===null||r===void 0?void 0:r.shared,m.cacheHeuristic=(i=o.cacheOptions)===null||i===void 0?void 0:i.cacheHeuristic,m.immutableMinTimeToLive=(n=o.cacheOptions)===null||n===void 0?void 0:n.immutableMinTimeToLive,m.ignoreCargoCult=(s=o.cacheOptions)===null||s===void 0?void 0:s.ignoreCargoCult,o.dnsLookupIpVersion!==void 0)try{m.family=c8.dnsLookupIpVersionToFamily(o.dnsLookupIpVersion)}catch(I){throw new Error("Invalid `dnsLookupIpVersion` option value")}o.https&&("rejectUnauthorized"in o.https&&(m.rejectUnauthorized=o.https.rejectUnauthorized),o.https.checkServerIdentity&&(m.checkServerIdentity=o.https.checkServerIdentity),o.https.certificateAuthority&&(m.ca=o.https.certificateAuthority),o.https.certificate&&(m.cert=o.https.certificate),o.https.key&&(m.key=o.https.key),o.https.passphrase&&(m.passphrase=o.https.passphrase),o.https.pfx&&(m.pfx=o.https.pfx));try{let I=await d(g,m);ce.default.undefined(I)&&(I=h(g,m)),o.request=c,o.timeout=u,o.agent=l,o.https&&("rejectUnauthorized"in o.https&&delete m.rejectUnauthorized,o.https.checkServerIdentity&&delete m.checkServerIdentity,o.https.certificateAuthority&&delete m.ca,o.https.certificate&&delete m.cert,o.https.key&&delete m.key,o.https.passphrase&&delete m.passphrase,o.https.pfx&&delete m.pfx),bSe(I)?this._onRequest(I):this.writable?(this.once("finish",()=>{this._onResponse(I)}),this._unlockWrite(),this.end(),this._lockWrite()):this._onResponse(I)}catch(I){throw I instanceof o8.CacheError?new jk(I,this):new _r(I.message,I,this)}}async _error(e){try{for(let r of this.options.hooks.beforeError)e=await r(e)}catch(r){e=new _r(r.message,r,this)}this.destroy(e)}_beforeError(e){if(this[_u])return;let{options:r}=this,i=this.retryCount+1;this[_u]=!0,e instanceof _r||(e=new _r(e.message,e,this));let n=e,{response:s}=n;(async()=>{if(s&&!s.body){s.setEncoding(this._readableState.encoding);try{s.rawBody=await ESe.default(s),s.body=s.rawBody.toString()}catch(o){}}if(this.listenerCount("retry")!==0){let o;try{let a;s&&"retry-after"in s.headers&&(a=Number(s.headers["retry-after"]),Number.isNaN(a)?(a=Date.parse(s.headers["retry-after"])-Date.now(),a<=0&&(a=1)):a*=1e3),o=await r.retry.calculateDelay({attemptCount:i,retryOptions:r.retry,error:n,retryAfter:a,computedValue:wSe.default({attemptCount:i,retryOptions:r.retry,error:n,retryAfter:a,computedValue:0})})}catch(a){this._error(new _r(a.message,a,this));return}if(o){let a=async()=>{try{for(let l of this.options.hooks.beforeRetry)await l(this.options,n,i)}catch(l){this._error(new _r(l.message,e,this));return}this.destroyed||(this.destroy(),this.emit("retry",i,e))};this[p8]=setTimeout(a,o);return}}this._error(n)})()}_read(){this[Gy]=!0;let e=this[Uy];if(e&&!this[_u]){e.readableLength&&(this[Gy]=!1);let r;for(;(r=e.read())!==null;){this[Wu]+=r.length,this[f8]=!0;let i=this.downloadProgress;i.percent<1&&this.emit("downloadProgress",i),this.push(r)}}}_write(e,r,i){let n=()=>{this._writeRequest(e,r,i)};this.requestInitialized?n():this[bp].push(n)}_writeRequest(e,r,i){this[Ei].destroyed||(this._progressCallbacks.push(()=>{this[Vu]+=Buffer.byteLength(e,r);let n=this.uploadProgress;n.percent<1&&this.emit("uploadProgress",n)}),this[Ei].write(e,r,n=>{!n&&this._progressCallbacks.length>0&&this._progressCallbacks.shift()(),i(n)}))}_final(e){let r=()=>{for(;this._progressCallbacks.length!==0;)this._progressCallbacks.shift()();if(!(Ei in this)){e();return}if(this[Ei].destroyed){e();return}this[Ei].end(i=>{i||(this[zu]=this[Vu],this.emit("uploadProgress",this.uploadProgress),this[Ei].emit("upload-complete")),e(i)})};this.requestInitialized?r():this[bp].push(r)}_destroy(e,r){var i;this[_u]=!0,clearTimeout(this[p8]),Ei in this&&(this[Ok](),((i=this[Uy])===null||i===void 0?void 0:i.complete)||this[Ei].destroy()),e!==null&&!ce.default.undefined(e)&&!(e instanceof _r)&&(e=new _r(e.message,e,this)),r(e)}get _isAboutToError(){return this[_u]}get ip(){var e;return(e=this.socket)===null||e===void 0?void 0:e.remoteAddress}get aborted(){var e,r,i;return((r=(e=this[Ei])===null||e===void 0?void 0:e.destroyed)!==null&&r!==void 0?r:this.destroyed)&&!((i=this[h8])===null||i===void 0?void 0:i.complete)}get socket(){var e,r;return(r=(e=this[Ei])===null||e===void 0?void 0:e.socket)!==null&&r!==void 0?r:void 0}get downloadProgress(){let e;return this[Ju]?e=this[Wu]/this[Ju]:this[Ju]===this[Wu]?e=1:e=0,{percent:e,transferred:this[Wu],total:this[Ju]}}get uploadProgress(){let e;return this[zu]?e=this[Vu]/this[zu]:this[zu]===this[Vu]?e=1:e=0,{percent:e,transferred:this[Vu],total:this[zu]}}get timings(){var e;return(e=this[Ei])===null||e===void 0?void 0:e.timings}get isFromCache(){return this[g8]}pipe(e,r){if(this[f8])throw new Error("Failed to pipe. The response has been emitted already.");return e instanceof Tk.ServerResponse&&this[Hy].add(e),super.pipe(e,r)}unpipe(e){return e instanceof Tk.ServerResponse&&this[Hy].delete(e),super.unpipe(e),this}};Rt.default=Uk});var Sp=E(Ms=>{"use strict";var PSe=Ms&&Ms.__createBinding||(Object.create?function(t,e,r,i){i===void 0&&(i=r),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,i){i===void 0&&(i=r),t[i]=e[r]}),DSe=Ms&&Ms.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&PSe(e,t,r)};Object.defineProperty(Ms,"__esModule",{value:!0});Ms.CancelError=Ms.ParseError=void 0;var d8=vp(),C8=class extends d8.RequestError{constructor(e,r){let{options:i}=r.request;super(`${e.message} in "${i.url.toString()}"`,e,r.request);this.name="ParseError"}};Ms.ParseError=C8;var m8=class extends d8.RequestError{constructor(e){super("Promise was canceled",{},e);this.name="CancelError"}get isCanceled(){return!0}};Ms.CancelError=m8;DSe(vp(),Ms)});var I8=E(Wk=>{"use strict";Object.defineProperty(Wk,"__esModule",{value:!0});var E8=Sp(),RSe=(t,e,r,i)=>{let{rawBody:n}=t;try{if(e==="text")return n.toString(i);if(e==="json")return n.length===0?"":r(n.toString());if(e==="buffer")return n;throw new E8.ParseError({message:`Unknown body type '${e}'`,name:"Error"},t)}catch(s){throw new E8.ParseError(s,t)}};Wk.default=RSe});var zk=E(EA=>{"use strict";var FSe=EA&&EA.__createBinding||(Object.create?function(t,e,r,i){i===void 0&&(i=r),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,i){i===void 0&&(i=r),t[i]=e[r]}),NSe=EA&&EA.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&FSe(e,t,r)};Object.defineProperty(EA,"__esModule",{value:!0});var LSe=require("events"),TSe=Ca(),MSe=g3(),Yy=Sp(),y8=I8(),w8=vp(),OSe=bk(),KSe=Rk(),B8=Fk(),USe=["request","response","redirect","uploadProgress","downloadProgress"];function Q8(t){let e,r,i=new LSe.EventEmitter,n=new MSe((o,a,l)=>{let c=u=>{let g=new w8.default(void 0,t);g.retryCount=u,g._noPipe=!0,l(()=>g.destroy()),l.shouldReject=!1,l(()=>a(new Yy.CancelError(g))),e=g,g.once("response",async p=>{var d;if(p.retryCount=u,p.request.aborted)return;let m;try{m=await KSe.default(g),p.rawBody=m}catch(R){return}if(g._isAboutToError)return;let I=((d=p.headers["content-encoding"])!==null&&d!==void 0?d:"").toLowerCase(),B=["gzip","deflate","br"].includes(I),{options:b}=g;if(B&&!b.decompress)p.body=m;else try{p.body=y8.default(p,b.responseType,b.parseJson,b.encoding)}catch(R){if(p.body=m.toString(),B8.isResponseOk(p)){g._beforeError(R);return}}try{for(let[R,H]of b.hooks.afterResponse.entries())p=await H(p,async L=>{let K=w8.default.normalizeArguments(void 0,_(P({},L),{retry:{calculateDelay:()=>0},throwHttpErrors:!1,resolveBodyOnly:!1}),b);K.hooks.afterResponse=K.hooks.afterResponse.slice(0,R);for(let ne of K.hooks.beforeRetry)await ne(K);let J=Q8(K);return l(()=>{J.catch(()=>{}),J.cancel()}),J})}catch(R){g._beforeError(new Yy.RequestError(R.message,R,g));return}if(!B8.isResponseOk(p)){g._beforeError(new Yy.HTTPError(p));return}r=p,o(g.options.resolveBodyOnly?p.body:p)});let f=p=>{if(n.isCanceled)return;let{options:d}=g;if(p instanceof Yy.HTTPError&&!d.throwHttpErrors){let{response:m}=p;o(g.options.resolveBodyOnly?m.body:m);return}a(p)};g.once("error",f);let h=g.options.body;g.once("retry",(p,d)=>{var m,I;if(h===((m=d.request)===null||m===void 0?void 0:m.options.body)&&TSe.default.nodeStream((I=d.request)===null||I===void 0?void 0:I.options.body)){f(d);return}c(p)}),OSe.default(g,i,USe)};c(0)});n.on=(o,a)=>(i.on(o,a),n);let s=o=>{let a=(async()=>{await n;let{options:l}=r.request;return y8.default(r,o,l.parseJson,l.encoding)})();return Object.defineProperties(a,Object.getOwnPropertyDescriptors(n)),a};return n.json=()=>{let{headers:o}=e.options;return!e.writableFinished&&o.accept===void 0&&(o.accept="application/json"),s("json")},n.buffer=()=>s("buffer"),n.text=()=>s("text"),n}EA.default=Q8;NSe(Sp(),EA)});var b8=E(Vk=>{"use strict";Object.defineProperty(Vk,"__esModule",{value:!0});var HSe=Sp();function GSe(t,...e){let r=(async()=>{if(t instanceof HSe.RequestError)try{for(let n of e)if(n)for(let s of n)t=await s(t)}catch(n){t=n}throw t})(),i=()=>r;return r.json=i,r.text=i,r.buffer=i,r.on=i,r}Vk.default=GSe});var x8=E(_k=>{"use strict";Object.defineProperty(_k,"__esModule",{value:!0});var v8=Ca();function S8(t){for(let e of Object.values(t))(v8.default.plainObject(e)||v8.default.array(e))&&S8(e);return Object.freeze(t)}_k.default=S8});var P8=E(k8=>{"use strict";Object.defineProperty(k8,"__esModule",{value:!0})});var Xk=E(ss=>{"use strict";var jSe=ss&&ss.__createBinding||(Object.create?function(t,e,r,i){i===void 0&&(i=r),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,i){i===void 0&&(i=r),t[i]=e[r]}),YSe=ss&&ss.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&jSe(e,t,r)};Object.defineProperty(ss,"__esModule",{value:!0});ss.defaultHandler=void 0;var D8=Ca(),os=zk(),qSe=b8(),qy=vp(),JSe=x8(),WSe={RequestError:os.RequestError,CacheError:os.CacheError,ReadError:os.ReadError,HTTPError:os.HTTPError,MaxRedirectsError:os.MaxRedirectsError,TimeoutError:os.TimeoutError,ParseError:os.ParseError,CancelError:os.CancelError,UnsupportedProtocolError:os.UnsupportedProtocolError,UploadError:os.UploadError},zSe=async t=>new Promise(e=>{setTimeout(e,t)}),{normalizeArguments:Jy}=qy.default,R8=(...t)=>{let e;for(let r of t)e=Jy(void 0,r,e);return e},VSe=t=>t.isStream?new qy.default(void 0,t):os.default(t),_Se=t=>"defaults"in t&&"options"in t.defaults,XSe=["get","post","put","patch","head","delete"];ss.defaultHandler=(t,e)=>e(t);var F8=(t,e)=>{if(t)for(let r of t)r(e)},N8=t=>{t._rawHandlers=t.handlers,t.handlers=t.handlers.map(i=>(n,s)=>{let o,a=i(n,l=>(o=s(l),o));if(a!==o&&!n.isStream&&o){let l=a,{then:c,catch:u,finally:g}=l;Object.setPrototypeOf(l,Object.getPrototypeOf(o)),Object.defineProperties(l,Object.getOwnPropertyDescriptors(o)),l.then=c,l.catch=u,l.finally=g}return a});let e=(i,n={},s)=>{var o,a;let l=0,c=u=>t.handlers[l++](u,l===t.handlers.length?VSe:c);if(D8.default.plainObject(i)){let u=P(P({},i),n);qy.setNonEnumerableProperties([i,n],u),n=u,i=void 0}try{let u;try{F8(t.options.hooks.init,n),F8((o=n.hooks)===null||o===void 0?void 0:o.init,n)}catch(f){u=f}let g=Jy(i,n,s!=null?s:t.options);if(g[qy.kIsNormalizedAlready]=!0,u)throw new os.RequestError(u.message,u,g);return c(g)}catch(u){if(n.isStream)throw u;return qSe.default(u,t.options.hooks.beforeError,(a=n.hooks)===null||a===void 0?void 0:a.beforeError)}};e.extend=(...i)=>{let n=[t.options],s=[...t._rawHandlers],o;for(let a of i)_Se(a)?(n.push(a.defaults.options),s.push(...a.defaults._rawHandlers),o=a.defaults.mutableDefaults):(n.push(a),"handlers"in a&&s.push(...a.handlers),o=a.mutableDefaults);return s=s.filter(a=>a!==ss.defaultHandler),s.length===0&&s.push(ss.defaultHandler),N8({options:R8(...n),handlers:s,mutableDefaults:Boolean(o)})};let r=async function*(i,n){let s=Jy(i,n,t.options);s.resolveBodyOnly=!1;let o=s.pagination;if(!D8.default.object(o))throw new TypeError("`options.pagination` must be implemented");let a=[],{countLimit:l}=o,c=0;for(;c{let s=[];for await(let o of r(i,n))s.push(o);return s},e.paginate.each=r,e.stream=(i,n)=>e(i,_(P({},n),{isStream:!0}));for(let i of XSe)e[i]=(n,s)=>e(n,_(P({},s),{method:i})),e.stream[i]=(n,s)=>e(n,_(P({},s),{method:i,isStream:!0}));return Object.assign(e,WSe),Object.defineProperty(e,"defaults",{value:t.mutableDefaults?t:JSe.default(t),writable:t.mutableDefaults,configurable:t.mutableDefaults,enumerable:!0}),e.mergeOptions=R8,e};ss.default=N8;YSe(P8(),ss)});var zy=E((Ea,Wy)=>{"use strict";var ZSe=Ea&&Ea.__createBinding||(Object.create?function(t,e,r,i){i===void 0&&(i=r),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,i){i===void 0&&(i=r),t[i]=e[r]}),L8=Ea&&Ea.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&ZSe(e,t,r)};Object.defineProperty(Ea,"__esModule",{value:!0});var $Se=require("url"),T8=Xk(),exe={options:{method:"GET",retry:{limit:2,methods:["GET","PUT","HEAD","DELETE","OPTIONS","TRACE"],statusCodes:[408,413,429,500,502,503,504,521,522,524],errorCodes:["ETIMEDOUT","ECONNRESET","EADDRINUSE","ECONNREFUSED","EPIPE","ENOTFOUND","ENETUNREACH","EAI_AGAIN"],maxRetryAfter:void 0,calculateDelay:({computedValue:t})=>t},timeout:{},headers:{"user-agent":"got (https://github.com/sindresorhus/got)"},hooks:{init:[],beforeRequest:[],beforeRedirect:[],beforeRetry:[],beforeError:[],afterResponse:[]},cache:void 0,dnsCache:void 0,decompress:!0,throwHttpErrors:!0,followRedirect:!0,isStream:!1,responseType:"text",resolveBodyOnly:!1,maxRedirects:10,prefixUrl:"",methodRewriting:!0,ignoreInvalidCookies:!1,context:{},http2:!1,allowGetBody:!1,https:void 0,pagination:{transform:t=>t.request.options.responseType==="json"?t.body:JSON.parse(t.body),paginate:t=>{if(!Reflect.has(t.headers,"link"))return!1;let e=t.headers.link.split(","),r;for(let i of e){let n=i.split(";");if(n[1].includes("next")){r=n[0].trimStart().trim(),r=r.slice(1,-1);break}}return r?{url:new $Se.URL(r)}:!1},filter:()=>!0,shouldContinue:()=>!0,countLimit:Infinity,backoff:0,requestLimit:1e4,stackAllItems:!0},parseJson:t=>JSON.parse(t),stringifyJson:t=>JSON.stringify(t),cacheOptions:{}},handlers:[T8.defaultHandler],mutableDefaults:!1},Zk=T8.default(exe);Ea.default=Zk;Wy.exports=Zk;Wy.exports.default=Zk;Wy.exports.__esModule=!0;L8(Xk(),Ea);L8(zk(),Ea)});var U8=E(Xu=>{"use strict";var fst=require("net"),txe=require("tls"),$k=require("http"),M8=require("https"),rxe=require("events"),hst=require("assert"),ixe=require("util");Xu.httpOverHttp=nxe;Xu.httpsOverHttp=sxe;Xu.httpOverHttps=oxe;Xu.httpsOverHttps=axe;function nxe(t){var e=new Ia(t);return e.request=$k.request,e}function sxe(t){var e=new Ia(t);return e.request=$k.request,e.createSocket=O8,e.defaultPort=443,e}function oxe(t){var e=new Ia(t);return e.request=M8.request,e}function axe(t){var e=new Ia(t);return e.request=M8.request,e.createSocket=O8,e.defaultPort=443,e}function Ia(t){var e=this;e.options=t||{},e.proxyOptions=e.options.proxy||{},e.maxSockets=e.options.maxSockets||$k.Agent.defaultMaxSockets,e.requests=[],e.sockets=[],e.on("free",function(i,n,s,o){for(var a=K8(n,s,o),l=0,c=e.requests.length;l=this.maxSockets){s.requests.push(o);return}s.createSocket(o,function(a){a.on("free",l),a.on("close",c),a.on("agentRemove",c),e.onSocket(a);function l(){s.emit("free",a,o)}function c(u){s.removeSocket(a),a.removeListener("free",l),a.removeListener("close",c),a.removeListener("agentRemove",c)}})};Ia.prototype.createSocket=function(e,r){var i=this,n={};i.sockets.push(n);var s=eP({},i.proxyOptions,{method:"CONNECT",path:e.host+":"+e.port,agent:!1,headers:{host:e.host+":"+e.port}});e.localAddress&&(s.localAddress=e.localAddress),s.proxyAuth&&(s.headers=s.headers||{},s.headers["Proxy-Authorization"]="Basic "+new Buffer(s.proxyAuth).toString("base64")),IA("making CONNECT request");var o=i.request(s);o.useChunkedEncodingByDefault=!1,o.once("response",a),o.once("upgrade",l),o.once("connect",c),o.once("error",u),o.end();function a(g){g.upgrade=!0}function l(g,f,h){process.nextTick(function(){c(g,f,h)})}function c(g,f,h){if(o.removeAllListeners(),f.removeAllListeners(),g.statusCode!==200){IA("tunneling socket could not be established, statusCode=%d",g.statusCode),f.destroy();var p=new Error("tunneling socket could not be established, statusCode="+g.statusCode);p.code="ECONNRESET",e.request.emit("error",p),i.removeSocket(n);return}if(h.length>0){IA("got illegal response body from proxy"),f.destroy();var p=new Error("got illegal response body from proxy");p.code="ECONNRESET",e.request.emit("error",p),i.removeSocket(n);return}return IA("tunneling connection has established"),i.sockets[i.sockets.indexOf(n)]=f,r(f)}function u(g){o.removeAllListeners(),IA(`tunneling socket could not be established, cause=%s -`,g.message,g.stack);var f=new Error("tunneling socket could not be established, cause="+g.message);f.code="ECONNRESET",e.request.emit("error",f),i.removeSocket(n)}};Ia.prototype.removeSocket=function(e){var r=this.sockets.indexOf(e);if(r!==-1){this.sockets.splice(r,1);var i=this.requests.shift();i&&this.createSocket(i,function(n){i.request.onSocket(n)})}};function O8(t,e){var r=this;Ia.prototype.createSocket.call(r,t,function(i){var n=t.request.getHeader("host"),s=eP({},r.options,{socket:i,servername:n?n.replace(/:.*$/,""):t.host}),o=txe.connect(0,s);r.sockets[r.sockets.indexOf(i)]=o,e(o)})}function K8(t,e,r){return typeof t=="string"?{host:t,port:e,localAddress:r}:t}function eP(t){for(var e=1,r=arguments.length;e{H8.exports=U8()});var b4=E((xot,sP)=>{var e4=Object.assign({},require("fs")),oe=typeof oe!="undefined"?oe:{},kp={},wA;for(wA in oe)oe.hasOwnProperty(wA)&&(kp[wA]=oe[wA]);var oP=[],t4="./this.program",r4=function(t,e){throw e},i4=!1,Wl=!0,Pp="";function dxe(t){return oe.locateFile?oe.locateFile(t,Pp):Pp+t}var Xy,aP,Zy,AP;Wl&&(i4?Pp=require("path").dirname(Pp)+"/":Pp=__dirname+"/",Xy=function(e,r){var i=s4(e);return i?r?i:i.toString():(Zy||(Zy=e4),AP||(AP=require("path")),e=AP.normalize(e),Zy.readFileSync(e,r?null:"utf8"))},aP=function(e){var r=Xy(e,!0);return r.buffer||(r=new Uint8Array(r)),n4(r.buffer),r},process.argv.length>1&&(t4=process.argv[1].replace(/\\/g,"/")),oP=process.argv.slice(2),typeof sP!="undefined"&&(sP.exports=oe),r4=function(t){process.exit(t)},oe.inspect=function(){return"[Emscripten Module object]"});var $y=oe.print||console.log.bind(console),Di=oe.printErr||console.warn.bind(console);for(wA in kp)kp.hasOwnProperty(wA)&&(oe[wA]=kp[wA]);kp=null;oe.arguments&&(oP=oe.arguments);oe.thisProgram&&(t4=oe.thisProgram);oe.quit&&(r4=oe.quit);var Cxe=16;function mxe(t,e){return e||(e=Cxe),Math.ceil(t/e)*e}var Exe=0,Ixe=function(t){Exe=t},lP;oe.wasmBinary&&(lP=oe.wasmBinary);var Pst=oe.noExitRuntime||!0;typeof WebAssembly!="object"&&Gr("no native wasm support detected");function yxe(t,e,r){switch(e=e||"i8",e.charAt(e.length-1)==="*"&&(e="i32"),e){case"i1":return Zi[t>>0];case"i8":return Zi[t>>0];case"i16":return cP[t>>1];case"i32":return _e[t>>2];case"i64":return _e[t>>2];case"float":return o4[t>>2];case"double":return a4[t>>3];default:Gr("invalid type for getValue: "+e)}return null}var ew,A4=!1,wxe;function n4(t,e){t||Gr("Assertion failed: "+e)}function l4(t){var e=oe["_"+t];return n4(e,"Cannot call unknown function "+t+", make sure it is exported"),e}function vxe(t,e,r,i,n){var s={string:function(h){var p=0;if(h!=null&&h!==0){var d=(h.length<<2)+1;p=g4(d),u4(h,p,d)}return p},array:function(h){var p=g4(h.length);return Bxe(h,p),p}};function o(h){return e==="string"?c4(h):e==="boolean"?Boolean(h):h}var a=l4(t),l=[],c=0;if(i)for(var u=0;u=i);)++n;if(n-e>16&&t.subarray&&f4)return f4.decode(t.subarray(e,n));for(var s="";e>10,56320|c&1023)}}return s}function c4(t,e){return t?Zu($u,t,e):""}function tw(t,e,r,i){if(!(i>0))return 0;for(var n=r,s=r+i-1,o=0;o=55296&&a<=57343){var l=t.charCodeAt(++o);a=65536+((a&1023)<<10)|l&1023}if(a<=127){if(r>=s)break;e[r++]=a}else if(a<=2047){if(r+1>=s)break;e[r++]=192|a>>6,e[r++]=128|a&63}else if(a<=65535){if(r+2>=s)break;e[r++]=224|a>>12,e[r++]=128|a>>6&63,e[r++]=128|a&63}else{if(r+3>=s)break;e[r++]=240|a>>18,e[r++]=128|a>>12&63,e[r++]=128|a>>6&63,e[r++]=128|a&63}}return e[r]=0,r-n}function u4(t,e,r){return tw(t,$u,e,r)}function rw(t){for(var e=0,r=0;r=55296&&i<=57343&&(i=65536+((i&1023)<<10)|t.charCodeAt(++r)&1023),i<=127?++e:i<=2047?e+=2:i<=65535?e+=3:e+=4}return e}function uP(t){var e=rw(t)+1,r=h4(e);return r&&tw(t,Zi,r,e),r}function Bxe(t,e){Zi.set(t,e)}function xxe(t,e){return t%e>0&&(t+=e-t%e),t}var gP,Zi,$u,cP,kxe,_e,Pxe,o4,a4;function p4(t){gP=t,oe.HEAP8=Zi=new Int8Array(t),oe.HEAP16=cP=new Int16Array(t),oe.HEAP32=_e=new Int32Array(t),oe.HEAPU8=$u=new Uint8Array(t),oe.HEAPU16=kxe=new Uint16Array(t),oe.HEAPU32=Pxe=new Uint32Array(t),oe.HEAPF32=o4=new Float32Array(t),oe.HEAPF64=a4=new Float64Array(t)}var Dst=oe.INITIAL_MEMORY||16777216,fP,d4=[],C4=[],m4=[],Dxe=!1;function Fxe(){if(oe.preRun)for(typeof oe.preRun=="function"&&(oe.preRun=[oe.preRun]);oe.preRun.length;)Rxe(oe.preRun.shift());hP(d4)}function Nxe(){Dxe=!0,!oe.noFSInit&&!y.init.initialized&&y.init(),BA.init(),hP(C4)}function Txe(){if(oe.postRun)for(typeof oe.postRun=="function"&&(oe.postRun=[oe.postRun]);oe.postRun.length;)Lxe(oe.postRun.shift());hP(m4)}function Rxe(t){d4.unshift(t)}function Mxe(t){C4.unshift(t)}function Lxe(t){m4.unshift(t)}var zl=0,pP=null,Dp=null;function Oxe(t){return t}function E4(t){zl++,oe.monitorRunDependencies&&oe.monitorRunDependencies(zl)}function dP(t){if(zl--,oe.monitorRunDependencies&&oe.monitorRunDependencies(zl),zl==0&&(pP!==null&&(clearInterval(pP),pP=null),Dp)){var e=Dp;Dp=null,e()}}oe.preloadedImages={};oe.preloadedAudios={};function Gr(t){oe.onAbort&&oe.onAbort(t),t+="",Di(t),A4=!0,wxe=1,t="abort("+t+"). Build with -s ASSERTIONS=1 for more info.";var e=new WebAssembly.RuntimeError(t);throw e}var I4="data:application/octet-stream;base64,";function y4(t){return t.startsWith(I4)}var Rp="data:application/octet-stream;base64,AGFzbQEAAAABlAInYAF/AX9gA39/fwF/YAF/AGACf38Bf2ACf38AYAV/f39/fwF/YAR/f39/AX9gA39/fwBgBH9+f38Bf2AAAX9gBX9/f35/AX5gA39+fwF/YAF/AX5gAn9+AX9gBH9/fn8BfmADf35/AX5gA39/fgF/YAR/f35/AX9gBn9/f39/fwF/YAR/f39/AGADf39+AX5gAn5/AX9gA398fwBgBH9/f38BfmADf39/AX5gBn98f39/fwF/YAV/f35/fwF/YAV/fn9/fwF/YAV/f39/fwBgAn9+AGACf38BfmACf3wAYAh/fn5/f39+fwF/YAV/f39+fwBgAABgBX5+f35/AX5gAnx/AXxgAn9+AX5gBX9/f39/AX4CeRQBYQFhAAIBYQFiAAABYQFjAAMBYQFkAAYBYQFlAAEBYQFmAAABYQFnAAYBYQFoAAABYQFpAAMBYQFqAAMBYQFrAAMBYQFsAAMBYQFtAAABYQFuAAUBYQFvAAEBYQFwAAMBYQFxAAEBYQFyAAABYQFzAAEBYQF0AAADggKAAgcCAgQAAQECAgANBAQOBwICAhwLEw0AAA0dFAwMAAcCDBAeAgMCAwIAAgEABwgUBBUIBgADAAwABAgIAgEGBgABAB8XAQEDAhMCAwUFEQICIA8GAgMYAQgCAQAABwUBGAAaAxIBAAcEAyERCCIHAQsVAQMABQ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CBCADIAZqIAM2AgAgA0H/AU0EQCADQQN2IgBBA3RB4JsBaiECAn9BuJsBKAIAIgFBASAAdCIAcUUEQEG4mwEgACABcjYCACACDAELIAIoAggLIQAgAiAGNgIIIAAgBjYCDCAGIAI2AgwgBiAANgIIDAELQR8hACADQf///wdNBEAgA0EIdiIAIABBgP4/akEQdkEIcSICdCIAIABBgOAfakEQdkEEcSIBdCIAIABBgIAPakEQdkECcSIAdEEPdiABIAJyIAByayIAQQF0IAMgAEEVanZBAXFyQRxqIQALIAYgADYCHCAGQgA3AhAgAEECdEHonQFqIQICQAJAIAlBASAAdCIBcUUEQEG8mwEgASAJcjYCACACIAY2AgAgBiACNgIYDAELIANBAEEZIABBAXZrIABBH0YbdCEAIAIoAgAhCANAIAgiASgCBEF4cSADRg0CIABBHXYhAiAAQQF0IQAgASACQQRxaiICKAIQIggNAAsgAiAGNgIQIAYgATYCGAsgBiAGNgIMIAYgBjYCCAwBCyABKAIIIgAgBjYCDCABIAY2AgggBkEANgIYIAYgATYCDCAGIAA2AggLIARBCGohAAwBCwJAIAtFDQACQCABKAIcIgJBAnRB6J0BaiIAKAIAIAFGBEAgACAENgIAIAQNAUG8mwEgBkF+IAJ3cTYCAAwCCyALQRBBFCALKAIQIAFGG2ogBDYCACAERQ0BCyAEIAs2AhggASgCECIABEAgBCAANgIQIAAgBDYCGAsgASgCFCIARQ0AIAQgADYCFCAAIAQ2AhgLAkAgA0EPTQRAIAEgAyAIaiIAQQNyNgIEIAAgAWoiACAAKAIEQQFyNgIEDAELIAEgCEEDcjYCBCAJIANBAXI2AgQgAyAJaiADNgIAIAoEQCAKQQN2IgBBA3RB4JsBaiEEQcybASgCACECAn9BASAAdCIAIAVxRQRAQbibASAAIAVyNgIAIAQMAQsgBCgCCAshACAEIAI2AgggACACNgIMIAIgBDYCDCACIAA2AggLQcybASAJNgIAQcCbASADNgIACyABQQhqIQALIAxBEGokACAAC4MEAQN/IAJBgARPBEAgACABIAIQEhogAA8LIAAgAmohAw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KAIELQACIAEoAgQtAANBCHRqQQh0akEIdGo2AgwLIAEoAgwhACABQRBqJAAgAAt/AQN/IAAhAQJAIABBA3EEQANAIAEtAABFDQIgAUEBaiIBQQNxDQALCwNAIAEiAkEEaiEBIAIoAgAiA0F/cyADQYGChAhrcUGAgYKEeHFFDQALIANB/wFxRQRAIAIgAGsPCwNAIAItAAEhAyACQQFqIgEhAiADDQALCyABIABrC2EBAX8jAEEQayICIAA2AgggAiABNwMAAkAgAikDACACKAIIKQMIVgRAIAIoAghBADoAACACQX82AgwMAQsgAigCCEEBOgAAIAIoAgggAikDADcDECACQQA2AgwLIAIoAgwL7wEBAX8jAEEgayICJAAgAiAANgIYIAIgATcDECACIAIoAhhCCBAeNgIMAkAgAigCDEUEQCACQX82AhwMAQsgAigCDCACKQMQQv8BgzwAACACKAIMIAIpAxBCCIhC/wGDPAABIAIoAgwgAikDEEIQiEL/AYM8AAIgAigCDCACKQMQQhiIQv8BgzwAAyACKAIMIAIpAxBCIIhC/wGDPAAEIAIoAgwgAikDEEIoiEL/AYM8AAUgAigCDCACKQMQQjCIQv8BgzwABiACKAIMIAIpAxBCOIhC/wGDPAAHIAJBADYCHAsgAigCHBogAkEgaiQAC4cDAQF/IwBBMGsiAyQAIAMgADYCJCADIAE2AiAgAyACNwMYAkAgAygCJC0AKEEBcQRAIANCfzcDKAwBCwJAAkAgAygCJCgCIEUNACADKQMYQv///////////wBWDQAgAykDGFANASADKAIgDQELIAMoAiRBDGpBEkEAEBQgA0J/NwMoDAELIAMoAiQtADVBAXEEQCADQn83AygMAQsCfyMAQRBrIgAgAygCJDYCDCAAKAIMLQA0QQFxCwRAIANCADcDKAwBCyADKQMYUARAIANCADcDKAwBCyADQgA3AxADQCADKQMQIAMpAxhUBEAgAyADKAIkIAMoAiAgAykDEKdqIAMpAxggAykDEH1BARAhIgI3AwggAkIAUwRAIAMoAiRBAToANSADKQMQUARAIANCfzcDKAwECyADIAMpAxA3AygMAwsgAykDCFAEQCADKAIkQQE6ADQFIAMgAykDCCADKQMQfDcDEAwCCwsLIAMgAykDEDcDKAsgAykDKCECIANBMGokACACCzYBAX8jAEEQayIBIAA2AgwCfiABKAIMLQAAQQFxBEAgASgCDCkDCCABKAIMKQMQfQwBC0IACwuyAQIBfwF+IwBBEGsiASQAIAEgADYCBCABIAEoAgRCCBAeNgIAAkAgASgCAEUEQCABQgA3AwgMAQsgASABKAIALQAArSABKAIALQAHrUI4hiABKAIALQAGrUIwhnwgASgCAC0ABa1CKIZ8IAEoAgAtAAStQiCGfCABKAIALQADrUIYhnwgASgCAC0AAq1CEIZ8IAEoAgAtAAGtQgiGfHw3AwgLIAEpAwghAiABQRBqJAAgAgumAQEBfyMAQRBrIgEkACABIAA2AggCQCABKAIIKAIgRQRAIAEoAghBDGpBEkEAEBQgAUF/NgIMDAELIAEoAggiACAAKAIgQQFrNgIgIAEoAggoAiBFBEAgASgCCEEAQgBBAhAhGiABKAIIKAIABEAgASgCCCgCABAxQQBIBEAgASgCCEEMakEUQQAQFAsLCyABQQA2AgwLIAEoAgwhACABQRBqJAAgAAvwAgICfwF+AkAgAkUNACAAIAJqIgNBAWsgAToAACAAIAE6AAAgAkEDSQ0AIANBAmsgAToAACAAIAE6AAEgA0EDayABOgAAIAAgAToAAiACQQdJDQAgA0EEayABOgAAIAAgAToAAyACQQlJDQAgAEEAIABrQQNxIgRqIgMgAUH/AXFBgYKECGwiADYCACADIAIgBGtBfHEiAmoiAUEEayAANgIAIAJBCUkNACADIAA2AgggAyAANgIEIAFBCGsgADYCACABQQxrIAA2AgAgAkEZSQ0AIAMgADYCGCADIAA2AhQgAyAANgIQIAMgADYCDCABQRBrIAA2AgAgAUEUayAANgIAIAFBGGsgADYCACABQRxrIAA2AgAgAiADQQRxQRhyIgFrIgJBIEkNACAArUKBgICAEH4hBSABIANqIQEDQCABIAU3AxggASAFNwMQIAEgBTcDCCABIAU3AwAgAUEgaiEBIAJBIGsiAkEfSw0ACwsL3AEBAX8jAEEQayIBJAAgASAANgI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GDQAaQQEgAygCpAEvAVJBggJGDQAaIAMoAqQBLwFSQYMCRgtBAXE6AIUBIAMtAIcBQQFxBEAgAyADQSBqQhwQKTYCHCADKAIcRQRAIAMoAqgBQQhqQQ5BABAUIAMoApABECMgA0F/NgKsAQwCCwJAIAMoAqABQYACcQRAAkAgAygCoAFBgAhxDQAgAygCpAEpAyBC/////w9WDQAgAygCpAEpAyhC/////w9YDQILIAMoAhwgAygCpAEpAygQLSADKAIcIAMoAqQBKQMgEC0MAQsCQAJAIAMoAqABQYAIcQ0AIAMoAqQBKQMgQv////8PVg0AIAMoAqQBKQMoQv////8PVg0AIAMoAqQBKQNIQv////8PWA0BCyADKAKkASkDKEL/////D1oEQCADKAIcIAMoAqQBKQMoEC0LIAMoAqQBKQMgQv////8PWgRAIAMoAhwgAygCpAEpAyAQLQsgAygCpAEpA0hC/////w9aBEAgAygCHCADKAKkASkDSBAtCwsLAn8jAEEQayIAIAMoAhw2AgwgACgCDC0AAEEBcUULBEAgAygCqAFBCGpBFEEAEBQgAygCHBAWIAMoApABECMgA0F/NgKsAQwCCyADQQECfyMAQRBrIgAgAygCHDYCDAJ+IAAoAgwtAABBAXEEQCAAKAIMKQMQDAELQgALp0H//wNxCyADQSBqQYAGEFE2AowBIAMoAhwQFiADKAKMASADKAKQATYCACADIAMoAowBNgKQAQsgAy0AhQFBAXEEQCADIANBFWpCBxApNgIQIAMoAhBFBEAgAygCqAFBCGpBDkEAEBQgAygCkAEQIyADQX82AqwBDAILIAMoAhBBAhAfIAMoAhBBvRJBAhBAIAMoAhAgAygCpAEvAVJB/wFxEI4BIAMoAhAgAygCpAEoAhBB//8DcRAfAn8jAEEQayIAIAMoAhA2AgwgACgCDC0AAEEBcUULBEAgAygCqAFBCGpBFEEAEBQgAygCEBAWIAMoApABECMgA0F/NgKsAQwCCyADQYGyAkEHIANBFWpBgAYQUTYCDCADKAIQEBYgAygCDCADKAKQATYCACADIAMoAgw2ApABCyADIANB0ABqQi4QKSIANgJMIABFBE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AG0EBcRtIBEAgACAAKAIIEB1B//8DcSAAKAIcajYCHCAAIAAoAhRBAWo2AhQMAQsLIAAoAggQR0EBcUUEQCAAKAIgQRRBABAUIAAoAggQFiAAQX82AiwMAQsgACgCCBAWIAAgACgCHDYCLAsgACgCLCECIABBMGokACADIAIiADYCBCAAQQBIBEAgA0IANwMoDAELIAMpAwggAygCBK18Qv///////////wBWBEAgAygCFEEEQRYQFCADQgA3AygMAQsgAyADKQMIIAMoAgStfDcDKAsgAykDKCEBIANBMGokACABC20BAX8jAEEgayIEJAAgBCAANgIYIAQgATYCFCAEIAI2AhAgBCADNgIMAkAgBCgCGEUEQCAEQQA2AhwMAQsgBCAEKAIUIAQoAhAgBCgCDCAEKAIYQQhqEJIBNgIcCyAEKAIcIQAgBEEgaiQAIAALVQEBfyMAQRBrIgEkACABIAA2AgwCQAJAIAEoAgwoAiRBAUYNACABKAIMKAIkQQJGDQAMAQsgASgCDEEAQgBBChAhGiABKAIMQQA2AiQLIAFBEGokAAumAQEBfyMAQRBrIgIkACACIAA2AgggAiABNgIEAkAgAigCCC0AKEEBcQRAIAJBfzYCDAwBCyACKAIIKAIABEAgAigCCCgCACACKAIEEGhBAEgEQCACKAIIQQxqIAIoAggoAgAQFyACQX82AgwMAgsLIAIoAgggAkEEakIEQRMQIUIAUwRAIAJBfzYCDAwBCyACQQA2AgwLIAIoAgwhACACQRBqJAAgAAuNCAIBfwF+IwBBkAFrIgMkACADIAA2AoQBIAMgATYCgAEgAyACNgJ8IAMQTwJAIAMoAoABKQMIQgBSBEAgAyADKAKAASgCACgCACkDSDcDYCADIAMoAoABKAIAKAIAKQNINwNoDAELIANCADcDYCADQgA3A2gLIANCADcDcAJAA0AgAykDcCADKAKAASkDCFQEQCADKAKAASgCACADKQNwp0EEdGooAgApA0ggAykDaFQEQCADIAMoAoABKAIAIAMpA3CnQQR0aigCACkDSDcDaAsgAykDaCADKAKAASkDIFYEQCADKAJ8QRNBABAUIANCfzcDiAEMAwsgAyADKAKA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BZqIAMoAgxBAnRqKAIAQQJ0ai8BAEcNACADKAIQIAMoAhxB2Chqai0AACADKAIcQdwWaiADKAIMQQJ0aigCACADKAIcQdgoamotAABKDQAMAQsgAygCHEHcFmogAygCFEECdGogAygCHEHcFmogAygCDEECdGooAgA2AgAgAyADKAIMNgIUIAMgAygCDEEBdDYCDAwBCwsgAygCHEHcFmogAygCFEECdGogAygCEDYCAAvXEwEDfyMAQTBrIgIkACACIAA2AiwgAiABNgIoIAIgAigCKCgCADYCJCACIAIoAigoAggoAgA2AiAgAiACKAIoKAIIKAIMNgIcIAJBfzYCECACKAIsQQA2AtAoIAIoAixBvQQ2AtQoIAJBADYCGANAIAIoAhggAigCHEgEQAJAIAIoAiQgAigCGEECdGovAQAEQCACIAIoAhgiATYCECACKAIsQdwWaiEDIAIoAiwiBCgC0ChBAWohACAEIAA2AtAoIABBAnQgA2ogATYCACACKAIYIAIoAixB2ChqakEAOgAADAELIAIoAiQgAigCGEECdGpBADsBAgsgAiACKAIYQQFqNgIYDAELCwNAIAIoAiwoAtAoQQJIBEACQCACKAIQQQJIBEAgAiACKAIQQQFqIgA2AhAMAQtBACEACyACKAIsQdwWaiEDIAIoAiwiBCgC0ChBAWohASAEIAE2AtAoIAFBAnQgA2ogADYCACACIAA2AgwgAigCJCACKAIMQQJ0akEBOwEAIAIoAgwgAigCLEHYKGpqQQA6AAAgAigCLCIAIAAoAqgtQQFrNgKoLSACKAIgBEAgAigCLCIAIAAoAqwtIAIoAiAgAigCDEECdGovAQJrNgKsLQsMAQsLIAIoAiggAigCEDYCBCACIAIoAiwoAtAoQQJtNgIYA0AgAigCGEEBTgRAIAIoAiwgAigCJCACKAIYEHogAiACKAIYQQFrNgIYDAELCyACIAIoAhw2AgwDQCACIAIoAiwoAuAWNgIYIAIoAixB3BZqIQEgAigCLCIDKALQKCEAIAMgAEEBazYC0CggAigCLCAAQQJ0IAFqKAIANgLgFiACKAIsIAIoAiRBARB6IAIgAigCLCgC4BY2AhQgAigCGCEBIAIoAixB3BZqIQMgAigCLCIEKALUKEEBayEAIAQgADYC1CggAEECdCADaiABNgIAIAIoAhQhASACKAIsQdwWaiEDIAIoAiwiBCgC1ChBAWshACAEIAA2AtQoIABBAnQgA2ogATYCACACKAIkIAIoAgxBAnRqIAIoAiQgAigCGEECdGovAQAgAigCJCACKAIUQQJ0ai8BAGo7AQAgAigCDCACKAIsQdgoamoCfyACKAIYIAIoAixB2Chqai0AACACKAIUIAIoAixB2Chqai0AAE4EQCACKAIYIAIoAixB2Chqai0AAAwBCyACKAIUIAIoAixB2Chqai0AAAtBAWo6AAAgAigCJCACKAIUQQJ0aiACKAIMIgA7AQIgAigCJCACKAIYQQJ0aiAAOwECIAIgAigCDCIAQQFqNgIMIAIoAiwgADYC4BYgAigCLCACKAIkQQEQeiACKAIsKALQKEECTg0ACyACKAIsKALgFiEBIAIoAixB3BZqIQMgAigCLCIEKALUKEEBayEAIAQgADYC1CggAEECdCADaiABNgIAIAIoAighASMAQUBqIgAgAigCLDYCPCAAIAE2AjggACAAKAI4KAIANgI0IAAgACgCOCgCBDYCMCAAIAAoAjgoAggoAgA2AiwgACAAKAI4KAIIKAIENgIoIAAgACgCOCgCCCgCCDYCJCAAIAAoAjgoAggoAhA2AiAgAEEANgIEIABBADYCEANAIAAoAhBBD0wEQCAAKAI8QbwWaiAAKAIQQQF0akEAOwEAIAAgACgCEEEBajYCEAwBCwsgACgCNCAAKAI8QdwWaiAAKAI8KALUKEECdGooAgBBAnRqQQA7AQIgACAAKAI8KALUKEEBajYCHANAIAAoAhxBvQRIBEAgACAAKAI8QdwWaiAAKAIcQQJ0aigCADYCGCAAIAAoAjQgACgCNCAAKAIYQQJ0ai8BAkECdGovAQJBAWo2AhAgACgCECAAKAIgSgRAIAAgACgCIDYCECAAIAAoAgRBAWo2AgQLIAAoAjQgACgCGEECdGogACgCEDsBAiAAKAIYIAAoAjBMBEAgACgCPCAAKAIQQQF0akG8FmoiASABLwEAQQFqOwEAIABBADYCDCAAKAIY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gCDCkDEAwBC0IAC6dB//8DcQsCfyMAQRBrIgAgAygCBDYCDCAAKAIMKAIEC0GABhBRNgIAIAMoAgQQFiADIAMoAgA2AhwLIAMoAhwhACADQSBqJAAgAAu0AgEBfyMAQTBrIgMkACADIAA2AiggAyABNwMgIAMgAjYCHAJAIAMpAyBQBEAgA0EBOgAvDAELIAMgAygCKCkDECADKQMgfDcDCAJAIAMpAwggAykDIFoEQCADKQMIQv////8AWA0BCyADKAIcQQ5BABAUIANBADoALwwBCyADIAMoAigoAgAgAykDCKdBBHQQSCIANgIEIABFBEAgAygCHEEOQQAQFCADQQA6AC8MAQsgAygCKCADKAIENgIAIAMgAygCKCkDCDcDEANAIAMpAxAgAykDCFpFBEAgAygCKCgCACADKQMQp0EEdGoQkAEgAyADKQMQQgF8NwMQDAELCyADKAIoIAMpAwgiATcDECADKAIoIAE3AwggA0EBOgAvCyADLQAvQQFxIQAgA0EwaiQAIAALzAEBAX8jAEEgayICJAAgAiAANwMQIAIgATYCDCACQTAQGCIBNgIIAkAgAUUEQCACKAIMQQ5BABAUIAJBADYCHAwBCyACKAIIQQA2AgAgAigCCEIANwMQIAIoAghCADcDCCACKAIIQgA3AyAgAigCCEIANwMYIAIoAghBADYCKCACKAIIQQA6ACwgAigCCCACKQMQIAIoAgwQgwFBAXFFBEAgAigCCBAkIAJBADYCHAwBCyACIAIoAgg2AhwLIAIoAhwhASACQSBqJAAgAQvWAgEBfyMAQSBrIgMkACADIAA2AhggAyABNgIUIAMgAjYCECADIANBDGpCBBApNgIIAkAgAygCCEUEQCADQX82AhwMAQsDQCADKAIUBEAgAygCFCgCBCADKAIQcUGABnEEQCADKAIIQgAQLBogAygCCCADKAIULwEIEB8gAygCCCADKAIULwEKEB8CfyMAQRBrIgAgAygCCDYCDCAAKAIMLQAAQQFxRQsEQCADKAIYQQhqQRRBABAUIAMoAggQFiADQX82AhwMBAsgAygCGCADQQxqQgQQNUEASARAIAMoAggQFiADQX82AhwMBAsgAygCFC8BCgRAI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IUVA0AIwBBEGsiASAAKAJkNgIMIAEoAgwoAgQgACkDMKdqQRRrKAAAQdCWmThHDQAgACgCZCAAKQMwQhR9ECwaIAAoAmgoAgAhBSAAKAJkIQYgACkDWCEJIAAoAmgoAhQhByAAKAJUIQgjAEGwAWsiASQAIAEgBTYCqAEgASAGNgKkASABIAk3A5gBIAEgBzYClAEgASAINgKQASMAQRBrIgUgASgCpAE2AgwgAQJ+IAUoAgwtAABBAXEEQCAFKAIMKQMQDAELQgALNwMYIAEoAqQBQgQQHhogASABKAKkARAdQf//A3E2AhAgASABKAKkARAdQf//A3E2AgggASABKAKkARAwNwM4AkAgASkDOEL///////////8AVgRAIAEoApABQQRBFhAUIAFBADYCrAEMAQsgASkDOEI4fCABKQMYIAEpA5gBfFYEQCABKAKQAUEVQQAQFCABQQA2AqwBDAELAkACQCABKQM4IAEpA5gBVA0AIAEpAzhCOHwgASkDmAECfiMAQRBrIgUgASgCpAE2AgwgBSgCDCkDCAt8Vg0AIAEoAqQBIAEpAzggASkDmAF9ECwaIAFBADoAFwwBCyABKAKoASABKQM4QQAQJ0EASARAIAEoApABIAEoAqgBEBcgAUEANgKsAQwCCyABIAEoAqgBQjggAUFAayABKAKQARBBIgU2AqQBIAVFBEAgAUEANgKsAQwCCyABQQE6ABcLIAEoAqQBQgQQHigAAEHQlpkwRwRAIAEoApABQRVBABAUIAEtABdBAXEEQCABKAKkARAWCyABQQA2AqwBDAELIAEgASgCpAEQMDcDMAJAIAEoApQBQQRxRQ0AIAEpAzAgASkDOHxCDHwgASkDmAEgASkDGHxRDQAgASgCkAFBFUEAEBQgAS0AF0EBcQRAIAEoAqQBEBYLIAFBADYCrAEMAQsgASgCpAFCBBAeGiABIAEoAqQBECo2AgwgASABKAKkARAqNgIEIAEoAhBB//8DRgRAIAEgASgCDDYCEAsgASgCCEH//wNGBEAgASABKAIENgIICwJAIAEoApQBQQRxRQ0AIAEoAgggASgCBEYEQCABKAIQIAEoAgxGDQELIAEoApABQRVBABAUIAEtABdBAXEEQCABKAKkARAWCyABQQA2AqwBDAELAkAgASgCEEUEQCABKAIIRQ0BCyABKAKQAUEBQQAQFCABLQAXQQFxBEAgASgCpAEQFgsgAUEANgKsAQwBCyABIAEoAqQBEDA3AyggASABKAKkARAwNwMgIAEpAyggASkDIFIEQCABKAKQAUEBQQAQFCABLQAXQQFxBEAgASgCpAEQFgsgAUEANgKsAQwBCyABIAEoAqQBEDA3AzAgASABKAKkARAwNwOAAQJ/IwBBEGsiBSABKAKkATYCDCAFKAIMLQAAQQFxRQsEQCABKAKQAUEUQQAQFCABLQAXQQFxBEAgASgCpAEQFgsgAUEANgKsAQwBCyABLQAXQQFxBEAgASgCpAEQFgsCQCABKQOAAUL///////////8AWARAIAEpA4ABIAEpA4ABIAEpAzB8WA0BCyABKAKQAUEEQRYQFCABQQA2AqwBDAELIAEpA4ABIAEpAzB8IAEpA5gBIAEpAzh8VgRAIAEoApABQRVBABAUIAFBADYCrAEMAQsCQCABKAKUAUEEcUUNACABKQOAASABKQMwfCABKQOYASABKQM4fFENACABKAKQAUEVQQAQFCABQQA2AqwBDAELIAEpAyggASkDMEIugFYEQCABKAKQAUEVQQAQFCABQQA2AqwBDAELIAEgASkDKCABKAKQARCEASIFNgKMASAFRQRAIAFBADYCrAEMAQsgASgCjAFBAToALCABKAKMASABKQMwNwMYIAEoAowBIAEpA4ABNwMgIAEgASgCjAE2AqwBCyABKAKsASEFIAFBsAFqJAAgACAFNgJQDAELIAAoAmQgACkDMBAsGiAAKAJkIQUgACkDWCEJIAAoAmgoAhQhBiAAKAJUIQcjAEHQAGsiASQAIAEgBTYCSCABIAk3A0AgASAGNgI8IAEgBzYCOAJAIAEoAkgQL0IWVARAIAEoAjhBFUEAEBQgAUEANgJMDAELIwBBEGsiBSABKAJINgIMIAECfiAFKAIMLQAAQQFxBEAgBSgCDCkDEAwBC0IACzcDCCABKAJIQgQQHhogASgCSBAqBEAgASgCOEEBQQAQFCABQQA2AkwMAQsgASABKAJIEB1B//8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QDYCFCACIAIoAjgoAjQ2AhAgAiACKAI4KAI4IAIoAjgoAmxqQYICajYCDCACIAIoAiwgAigCIEEBa2otAAA6AAsgAiACKAIsIAIoAiBqLQAAOgAKIAIoAjgoAnggAigCOCgCjAFPBEAgAiACKAIwQQJ2NgIwCyACKAIcIAIoAjgoAnRLBEAgAiACKAI4KAJ0NgIcCwNAAkAgAiACKAI4KAI4IAIoAjRqNgIoAkAgAigCKCACKAIgai0AACACLQAKRw0AIAIoAiggAigCIEEBa2otAAAgAi0AC0cNACACKAIoLQAAIAIoAiwtAABHDQAgAiACKAIoIgBBAWo2AiggAC0AASACKAIsLQABRwRADAELIAIgAigCLEECajYCLCACIAIoAihBAWo2AigDQCACIAIoAiwiAEEBajYCLCAALQABIQEgAiACKAIoIgBBAWo2AigCf0EAIAAtAAEgAUcNABogAiACKAIsIgBBAWo2AiwgAC0AASEBIAIgAigCKCIAQQFqNgIoQQAgAC0AASABRw0AGiACIAIoAiwiAEEBajYCLCAALQABIQEgAiACKAIoIgBBAWo2AihBACAALQABIAFHDQAaIAIgAigCLCIAQQFqNgIsIAAtAAEhASACIAIoAigiAEEBajYCKEEAIAAtAAEgAUcNABogAiACKAIsIgBBAWo2AiwgAC0AASEBIAIgAigCKCIAQQFqNgIoQQAgAC0AASABRw0AGiACIAIoAiwiAEEBajYCLCAALQABIQEgAiACKAIoIgBBAWo2AihBACAALQABIAFHDQAaIAIgAigCLCIAQQFqNgIsIAAtAAEhASACIAIoAigiAEEBajYCKEEAIAAtAAEgAUcNABogAiACKAIsIgBBAWo2AiwgAC0AASEBIAIgAigCKCIAQQFqNgIoQQAgAC0AASABRw0AGiACKAIsIAIoAgxJC0EBcQ0ACyACQYICIAIoAgwgAigCLGtrNgIkIAIgAigCDEGCAms2AiwgAigCJCACKAIgSgRAIAIoAjggAigCNDYCcCACIAIoAiQ2AiAgAigCJCACKAIcTg0CIAIgAigCLCACKAIgQQFrai0AADoACyACIAIoAiwgAigCIGotAAA6AAoLCyACIAIoAhQgAigCNCACKAIQcUEBdGovAQAiATYCNEEAIQAgASACKAIYSwR/IAIgAigCMEEBayIANgIwIABBAEcFQQALQQFxDQELCwJAIAIoAiAgAigCOCgCdE0EQCACIAIoAiA2AjwMAQsgAiACKAI4KAJ0NgI8CyACKAI8C5IQAQF/IwBBMGsiAiQAIAIgADYCKCACIAE2AiQgAgJ/IAIoAigoAiwgAigCKCgCDEEFa0kEQCACKAIoKAIsDAELIAIoAigoAgxBBWsLNgIgIAJBADYCECACIAIoAigoAgAoAgQ2AgwDQAJAIAJB//8DNgIcIAIgAigCKCgCvC1BKmpBA3U2AhQgAigCKCgCACgCECACKAIUSQ0AIAIgAigCKCgCACgCECACKAIUazYCFCACIAIoAigoAmwgAigCKCgCXGs2AhggAigCHCACKAIYIAIoAigoAgAoAgRqSwRAIAIgAigCGCACKAIoKAIAKAIEajYCHAsgAigCHCACKAIUSwRAIAIgAigCFDYCHAsCQCACKAIcIAIoAiBPDQACQCACKAIcRQRAIAIoAiRBBEcNAQsgAigCJEUNACACKAIcIAIoAhggAigCKCgCACgCBGpGDQELDAELQQAhACACIAIoAiRBBEYEfyACKAIcIAIoAhggAigCKCgCACgCBGpGBUEAC0EBcTYCECACKAIoQQBBACACKAIQEFwgAigCKCgCCCACKAIoKAIUQQRraiACKAIcOgAAIAIoAigoAgggAigCKCgCFEEDa2ogAigCHEEIdjoAACACKAIoKAIIIAIoAigoAhRBAmtqIAIoAhxBf3M6AAAgAigCKCgCCCACKAIoKAIUQQFraiACKAIcQX9zQQh2OgAAIAIoAigoAgAQHCACKAIYBEAgAigCGCACKAIcSwRAIAIgAigCHDYCGAsgAigCKCgCACgCDCACKAIoKAI4IAIoAigoAlxqIAIoAhgQGRogAigCKCgCACIAIAIoAhggACgCDGo2AgwgAigCKCgCACIAIAAoAhAgAigCGGs2AhAgAigCKCgCACIAIAIoAhggACgCFGo2AhQgAigCKCIAIAIoAhggACgCXGo2AlwgAiACKAIcIAIoAhhrNgIcCyACKAIcBEA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AiACKAIoKAIAKAIENgIUCyACKAIUBEAgAigCKCgCACACKAIoKAI4IAIoAigoAmxqIAIoAhQQeBogAigCKCIAIAIoAhQgACgCbGo2AmwLIAIoAigoAsAtIAIoAigoAmxJBEAgAigCKCACKAIoKAJsNgLALQsgAiACKAIoKAK8LUEqakEDdTYCFCACIAIoAigoAgwgAigCFGtB//8DSwR/Qf//AwUgAigCKCgCDCACKAIUaws2AhQgAgJ/IAIoAhQgAigCKCgCLEsEQCACKAIoKAIsDAELIAIoAhQLNgIgIAIgAigCKCgCbCACKAIoKAJcazYCGAJAIAIoAhggAigCIEkEQCACKAIYRQRAIAIoAiRBBEcNAgsgAigCJEUNASACKAIoKAIAKAIEDQEgAigCGCACKAIUSw0BCyACAn8gAigCGCACKAIUSwRAIAIoAhQMAQsgAigCGAs2AhwgAgJ/QQAgAigCJEEERw0AGkEAIAIoAigoAgAoAgQNABogAigCHCACKAIYRgtBAXE2AhAgAigCKCACKAIoKAI4IAIoAigoAlxqIAIoAhwgAigCEBBcIAIoAigiACACKAIcIAAoAlxqNgJcIAIoAigoAgAQHAsgAkECQQAgAigCEBs2AiwLIAIoAiwhACACQTBqJAAgAAuyAgEBfyMAQRBrIgEkACABIAA2AggCQCABKAIIEHkEQCABQX42AgwMAQsgASABKAIIKAIcKAIENgIEIAEoAggoAhwoAggEQCABKAIIKAIoIAEoAggoAhwoAgggASgCCCgCJBEEAAsgASgCCCgCHCgCRARAIAEoAggoAiggASgCCCgCHCgCRCABKAIIKAIkEQQACyABKAIIKAIcKAJABEAgASgCCCgCKCABKAIIKAIcKAJAIAEoAggoAiQRBAALIAEoAggoAhwoAjgEQCABKAIIKAIoIAEoAggoAhwoAjggASgCCCgCJBEEAAsgASgCCCgCKCABKAIIKAIcIAEoAggoAiQRBAAgASgCCEEANgIcIAFBfUEAIAEoAgRB8QBGGzYCDAsgASgCDCEAIAFBEGokACAAC+sXAQJ/IwBB8ABrIgMgADYCbCADIAE2AmggAyACNgJkIANBfzYCXCADI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83AygMAgsCQAJAIAMoAgwiASADKAIgIgBzQQNxDQAgAEEDcQRAA0AgASAALQAAIgI6AAAgAkUNAyABQQFqIQEgAEEBaiIAQQNxDQALCyAAKAIAIgJBf3MgAkGBgoQIa3FBgIGChHhxDQADQCABIAI2AgAgACgCBCECIAFBBGohASAAQQRqIQAgAkGBgoQIayACQX9zcUGAgYKEeHFFDQALCyABIAAtAAAiAjoAACACRQ0AA0AgASAALQABIgI6AAEgAUEBaiEBIABBAWohACACDQALCyADKAIMIAMoAhhqQS86AAAgAygCDCADKAIYQQFqakEAOgAACyADIAMoAiRBAEIAQQAQfiIANgIIIABFBEAgAygCDBAVIANCfzcDKAwBCyADIAMoAiQCfyADKAIMBEAgAygCDAwBCyADKAIgCyADKAIIIAMoAhwQmgE3AxAgAygCDBAVAkAgAykDEEIAUwRAIAMoAggQGwwBCyADKAIkIAMpAxBBAEEDQYCA/I8EEJkBQQBIBEAgAygCJCADKQMQEJgBGiADQn83AygMAgsLIAMgAykDEDcDKAsgAykDKCEEIANBMGokACAEQiCIpwsQACAEpwsRACAAIAGtIAKtQiCGhBCYAQt/AgF/AX4jAEEgayIDJAAgAyAANgIYIAMgATYCFCADIAI2AhAgAyADKAIYIAMoAhQgAygCEBBzIgQ3AwgCQCAEQgBTBEAgA0EANgIcDAELIAMgAygCGCADKQMIIAMoAhAgAygCGCgCHBCtATYCHAsgAygCHCEAIANBIGokACAAC8QBAQF/IwBBMGsiASQAIAEgADYCKCABQQA2AiQgAUIANwMYAkADQCABKQMYIAEoAigpAzBUBEAgASABKAIoIAEpAxhBACABQRdqIAFBEGoQlwE2AgwgASgCDEF/RgRAIAFBfzYCLAwDBQJAIAEtABdBA0cNACABKAIQQRB2QYDgA3FBgMACRw0AIAEgASgCJEEBajYCJAsgASABKQMYQgF8NwMYDAILAAsLIAEgASgCJDYCLAsgASgCLCEAIAFBMGokACAACxAAIwAgAGtBcHEiACQAIAALBgAgACQACwQAIwALggECAX8BfiMAQSBrIgQkACAEIAA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AKoASgCAEGAFCgCAEgNAQsgASABKAKoASgCADYCECABQSBqQY8SIAFBEGoQcCABQQA2AqQBIAEgAUEgajYCoAEMAQsgASABKAKoASgCAEECdEGAE2ooAgA2AqQBAkACQAJAAkAgASgCqAEoAgBBAnRBkBRqKAIAQQFrDgIAAQILIAEoAqgBKAIEIQJBkJkBKAIAIQRBACEAAkACQANAIAIgAEGgiAFqLQAARwRAQdcAIQMgAEEBaiIAQdcARw0BDAILCyAAIgMNAEGAiQEhAgwBC0GAiQEhAANAIAAtAAAhBSAAQQFqIgIhACAFDQAgAiEAIANBAWsiAw0ACwsgBCgCFBogASACNgKgAQwCCyMAQRBrIgAgASgCqAEoAgQ2AgwgAUEAIAAoAgxrQQJ0QajZAGooAgA2AqABDAELIAFBADYCoAELCwJAIAEoAqABRQRAIAEgASgCpAE2AqwBDAELIAEgASgCoAEQKwJ/IAEoAqQBBEAgASgCpAEQK0ECagwBC0EAC2pBAWoQGCIANgIcIABFBEAgAUG4EygCADYCrAEMAQsgASgCHCEAAn8gASgCpAEEQCABKAKkAQwBC0H6EgshA0HfEkH6EiABKAKkARshAiABIAEoAqABNgIIIAEgAjYCBCABIAM2AgAgAEG+CiABEHAgASgCqAEgASgCHDYCCCABIAEoAhw2AqwBCyABKAKsASEAIAFBsAFqJAAgAAszAQF/IAAoAhQiAyABIAIgACgCECADayIBIAEgAksbIgEQGRogACAAKAIUIAFqNgIUIAILjwUCBn4BfyABIAEoAgBBD2pBcHEiAUEQajYCACAAAnwgASkDACEDIAEpAwghBiMAQSBrIggkAAJAIAZC////////////AIMiBEKAgICAgIDAgDx9IARCgICAgICAwP/DAH1UBEAgBkIEhiADQjyIhCEEIANC//////////8PgyIDQoGAgICAgICACFoEQCAEQoGAgICAgICAwAB8IQIMAgsgBEKAgICAgICAgEB9IQIgA0KAgICAgICAgAiFQgBSDQEgAiAEQgGDfCECDAELIANQIARCgICAgICAwP//AFQgBEKAgICAgIDA//8AURtFBEAgBkIEhiADQjyIhEL/////////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AigoAjggASgCKCgCbGpBggJqNgIUA0AgASgCHCECIAEgASgCGCIDQQFqNgIYAn9BACADLQABIAJHDQAaIAEoAhwhAiABIAEoAhgiA0EBajYCGEEAIAMtAAEgAkcNABogASgCHCECIAEgASgCGCIDQQFqNgIYQQAgAy0AASACRw0AGiABKAIcIQIgASABKAIYIgNBAWo2AhhBACADLQABIAJHDQAaIAEoAhwhAiABIAEoAhgiA0EBajYCGEEAIAMtAAEgAkcNABogASgCHCECIAEgASgCGCIDQQFqNgIYQQAgAy0AASACRw0AGiABKAIcIQIgASABKAIYIgNBAWo2AhhBACADLQABIAJHDQAaIAEoAhwhAiABIAEoAhgiA0EBajYCGEEAIAMtAAEgAkcNABogASgCGCABKAIUSQtBAXENAAsgASgCKEGCAiABKAIUIAEoAhhrazYCYCABKAIoKAJgIAEoAigoAnRLBEAgASgCKCABKAIoKAJ0NgJgCwsLAkAgASgCKCgCYEEDTwRAIAEgASgCKCgCYEEDazoAEyABQQE7ARAgASgCKCICKAKkLSACKAKgLUEBdGogAS8BEDsBACABLQATIQMgASgCKCICKAKYLSEEIAIgAigCoC0iAkEBajYCoC0gAiAEaiADOgAAIAEgAS8BEEEBazsBECABKAIoIAEtABNB0N0Aai0AAEECdGpBmAlqIgIgAi8BAEEBajsBACABKAIoQYgTagJ/IAEvARBBgAJJBEAgAS8BEC0A0FkMAQsgAS8BEEEHdkGAAmotANBZC0ECdGoiAiACLwEAQQFqOwEAIAEgASgCKCgCoC0gASgCKCgCnC1BAWtGNgIgIAEoAigiAiACKAJ0IAEoAigoAmBrNgJ0IAEoAigiAiABKAIoKAJgIAIoAmxqNgJsIAEoAihBADYCYAwBCyABIAEoAigiAigCOCACKAJsai0AADoADyABKAIoIgIoAqQtIAIoAqAtQQF0akEAOwEAIAEtAA8hAyABKAIoIgIoApgtIQQgAiACKAKgLSICQQFqNgKgLSACIARqIAM6AAAgASgCKCABLQAPQQJ0aiICIAIvAZQBQQFqOwGUASABIAEoAigoAqAtIAEoAigoAp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AIQa2s2AkQgASABKAJIIAEoAlwoAhBBgQJrajYCQCABIAEoAlQoAiw2AjwgASABKAJUKAIwNgI4IAEgASgCVCgCNDYCNCABIAEoAlQoAjg2AjAgASABKAJUKAI8NgIsIAEgASgCVCgCQDYCKCABIAEoAlQoAlA2AiQgASABKAJUKAJUNgIgIAFBASABKAJUKAJYdEEBazYCHCABQQEgASgCVCgCXHRBAWs2AhgDQCABKAIoQQ9JBEAgASABKAJQIgJBAWo2AlAgASABKAIsIAItAAAgASgCKHRqNgIsIAEgASgCKEEIajYCKCABIAEoAlAiAkEBajYCUCABIAEoAiwgAi0AACABKAIodGo2AiwgASABKAIoQQhqNgIoCyABIAEoAiQgASgCLCABKAIccUECdGooAQA2ARACQAJAA0AgASABLQARNgIMIAEgASgCLCABKAIMdjYCLCABIAEoAiggASgCDGs2AiggASABLQAQNgIMIAEoAgxFBEAgAS8BEiECIAEgASgCSCIDQQFqNgJIIAMgAjoAAAwCCyABKAIMQRBxBEAgASABLwESNgIIIAEgASgCDEEPcTYCDCABKAIMBEAgASgCKCABKAIMSQRAIAEgASgCUCICQQFqNgJQIAEgASgCLCACLQAAIAEoAih0ajYCLCABIAEoAihBCGo2AigLIAEgASgCCCABKAIsQQEgASgCDHRBAWtxajYCCCABIAEoAiwgASgCDHY2AiwgASABKAIoIAEoAgxrNgIoCyABKAIoQQ9JBEAgASABKAJQIgJBAWo2AlAgASABKAIsIAItAAAgASgCKHRqNgIsIAEgASgCKEEIajYCKCABIAEoAlAiAkEBajYCUCABIAEoAiwgAi0AACABKAIodGo2AiwgASABKAIoQQhqNgIoCyABIAEoAiAgASgCLCABKAIYcUECdGooAQA2ARACQANAIAEgAS0AETYCDCABIAEoAiwgASgCDHY2AiwgASABKAIoIAEoAgxrNgIoIAEgAS0AEDYCDCABKAIMQRBxBEAgASABLwESNgIEIAEgASgCDEEPcTYCDCABKAIoIAEoAgxJBEAgASABKAJQIgJBAWo2AlAgASABKAIsIAItAAAgASgCKHRqNgIsIAEgASgCKEEIajYCKCABKAIoIAEoAgxJBEAgASABKAJQIgJBAWo2AlAgASABKAIsIAItAAAgASgCKHRqNgIsIAEgASgCKEEIajYCKAsLIAEgASgCBCABKAIsQQEgASgCDHRBAWtxajYCBCABIAEoAiwgASgCDHY2AiwgASABKAIoIAEoAgxrNgIoIAEgASgCSCABKAJEazYCDAJAIAEoAgQgASgCDEsEQCABIAEoAgQgASgCDGs2AgwgASgCDCABKAI4SwRAIAEoAlQoAsQ3BEAgASgCXEHdDDYCGCABKAJUQdH+ADYCBAwKCwsgASABKAIwNgIAAkAgASgCNEUEQCABIAEoAgAgASgCPCABKAIMa2o2AgAgASgCDCABKAIISQRAIAEgASgCCCABKAIMazYCCANAIAEgASgCACICQQFqNgIAIAItAAAhAiABIAEoAkgiA0EBajYCSCADIAI6AAAgASABKAIMQQFrIgI2AgwgAg0ACyABIAEoAkggASgCBGs2AgALDAELAkAgASgCNCABKAIMSQRAIAEgASgCACABKAI8IAEoAjRqIAEoAgxrajYCACABIAEoAgwgASgCNGs2AgwgASgCDCABKAIISQRAIAEgASgCCCABKAIMazYCCANAIAEgASgCACICQQFqNgIAIAItAAAhAiABIAEoAkgiA0EBajYCSCADIAI6AAAgASABKAIMQQFrIgI2AgwgAg0ACyABIAEoAjA2AgAgASgCNCABKAIISQRAIAEgASgCNDYCDCABIAEoAgggASgCDGs2AggDQCABIAEoAgAiAkEBajYCACACLQAAIQIgASABKAJIIgNBAWo2AkggAyACOgAAIAEgASgCDEEBayICNgIMIAINAAsgASABKAJIIAEoAgRrNgIACwsMAQsgASABKAIAIAEoAjQgASgCDGtqNgIAIAEoAgwgASgCCEkEQCABIAEoAgggASgCDGs2AggDQCABIAEoAgAiAkEBajYCACACLQAAIQIgASABKAJIIgNBAWo2AkggAyACOgAAIAEgASgCDEEBayICNgIMIAINAAsgASABKAJIIAEoAgRrNgIACwsLA0AgASgCCEECSwRAIAEgASgCACICQQFqNgIAIAItAAAhAiABIAEoAkgiA0EBajYCSCADIAI6AAAgASABKAIAIgJBAWo2AgAgAi0AACECIAEgASgCSCIDQQFqNgJIIAMgAjoAACABIAEoAgAiAkEBajYCACACLQAAIQIgASABKAJIIgNBAWo2AkggAyACOgAAIAEgASgCCEEDazYCCAwBCwsMAQsgASABKAJIIAEoAgRrNgIAA0AgASABKAIAIgJBAWo2AgAgAi0AACECIAEgASgCSCIDQQFqNgJIIAMgAjoAACABIAEoAgAiAkEBajYCACACLQAAIQIgASABKAJIIgNBAWo2AkggAyACOgAAIAEgASgCACICQQFqNgIAIAItAAAhAiABIAEoAkgiA0EBajYCSCADIAI6AAAgASABKAIIQQNrNgIIIAEoAghBAksNAAsLIAEoAggEQCABIAEoAgAiAkEBajYCACACLQAAIQIgASABKAJIIgNBAWo2AkggAyACOgAAIAEoAghBAUsEQCABIAEoAgAiAkEBajYCACACLQAAIQIgASABKAJIIgNBAWo2AkggAyACOgAACwsMAgsgASgCDEHAAHFFBEAgASABKAIgIAEvARIgASgCLEEBIAEoAgx0QQFrcWpBAnRqKAEANgEQDAELCyABKAJcQYUPNgIYIAEoAlRB0f4ANgIEDAQLDAILIAEoAgxBwABxRQRAIAEgASgCJCABLwESIAEoAixBASABKAIMdEEBa3FqQQJ0aigBADYBEAwBCwsgASgCDEEgcQRAIAEoAlRBv/4ANgIEDAILIAEoAlxB6Q42AhggASgCVEHR/gA2AgQMAQsgASgCUCABKAJMSQR/IAEoAkggASgCQEkFQQALQQFxDQELCyABIAEoAihBA3Y2AgggASABKAJQIAEoAghrNgJQIAEgASgCKCABKAIIQQN0azYCKCABIAEoAixBASABKAIodEEBa3E2AiwgASgCXCABKAJQNgIAIAEoAlwgASgCSDYCDCABKAJcAn8gASgCUCABKAJMSQRAIAEoAkwgASgCUGtBBWoMAQtBBSABKAJQIAEoAkxraws2AgQgASgCXAJ/IAEoAkggASgCQEkEQCABKAJAIAEoAkhrQYECagwBC0GBAiABKAJIIAEoAkBraws2AhAgASgCVCABKAIsNgI8IAEoAlQgASgCKDYCQCAAIAA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NvY2tldCBpcyBjb25uZWN0ZWQAU29ja2V0IG5vdCBjb25uZWN0ZWQAQ2Fubm90IHNlbmQgYWZ0ZXIgc29ja2V0IHNodXRkb3duAE9wZXJhdGlvbiBhbHJlYWR5IGluIHByb2dyZXNzAE9wZXJhdGlvbiBpbiBwcm9ncmVzcwBTdGFsZSBmaWxlIGhhbmRsZQBSZW1vdGUgSS9PIGVycm9yAFF1b3RhIGV4Y2VlZGVkAE5vIG1lZGl1bSBmb3VuZABXcm9uZyBtZWRpdW0gdHlwZQBObyBlcnJvciBpbmZvcm1hdGlvbgBBkJcBC1JQUFAACgAAAAsAAAAMAAAADQAAAA4AAAAPAAAAEAAAABEAAAASAAAACwAAAAwAAAANAAAADgAAAA8AAAAQAAAAEQAAAAEAAAAIAAAAlEsAALRLAEGQmQELAgxQAEHImQELCR8AAADkTAAAAwBB5JkBC4wBLfRRWM+MscBG9rXLKTEDxwRbcDC0Xf0geH+LmthZKVBoSImrp1YDbP+3zYg/1He0K6WjcPG65Kj8QYP92W/hinovLXSWBx8NCV4Ddixw90ClLKdvV0GoqnTfoFhkA0rHxDxTrq9fGAQVseNtKIarDKS/Q/DpUIE5VxZSN/////////////////////8=";y4(Rp)||(Rp=dxe(Rp));function Kxe(t){try{if(t==Rp&&lP)return new Uint8Array(lP);var e=s4(t);if(e)return e;if(aP)return aP(t);throw"sync fetching of the wasm failed: you can preload it to Module['wasmBinary'] manually, or emcc.py will do that for you when generating HTML (but not JS)"}catch(r){Gr(r)}}function Uxe(t,e){var r,i,n;try{n=Kxe(t),i=new WebAssembly.Module(n),r=new WebAssembly.Instance(i,e)}catch(o){var s=o.toString();throw Di("failed to compile wasm module: "+s),(s.includes("imported Memory")||s.includes("memory import"))&&Di("Memory size incompatibility issues may be due to changing INITIAL_MEMORY at runtime to something too large. Use ALLOW_MEMORY_GROWTH to allow any size memory (and also make sure not to set INITIAL_MEMORY at runtime to something smaller than it was at compile time)."),o}return[r,i]}function Gxe(){var t={a:Hxe};function e(n,s){var o=n.exports;oe.asm=o,ew=oe.asm.u,p4(ew.buffer),fP=oe.asm.za,Mxe(oe.asm.v),dP("wasm-instantiate")}if(E4("wasm-instantiate"),oe.instantiateWasm)try{var r=oe.instantiateWasm(t,e);return r}catch(n){return Di("Module.instantiateWasm callback failed with error: "+n),!1}var i=Uxe(Rp,t);return e(i[0]),oe.asm}var ai,ya;function hP(t){for(;t.length>0;){var e=t.shift();if(typeof e=="function"){e(oe);continue}var r=e.func;typeof r=="number"?e.arg===void 0?fP.get(r)():fP.get(r)(e.arg):r(e.arg===void 0?null:e.arg)}}function iw(t,e){var r=new Date(_e[t>>2]*1e3);_e[e>>2]=r.getUTCSeconds(),_e[e+4>>2]=r.getUTCMinutes(),_e[e+8>>2]=r.getUTCHours(),_e[e+12>>2]=r.getUTCDate(),_e[e+16>>2]=r.getUTCMonth(),_e[e+20>>2]=r.getUTCFullYear()-1900,_e[e+24>>2]=r.getUTCDay(),_e[e+36>>2]=0,_e[e+32>>2]=0;var i=Date.UTC(r.getUTCFullYear(),0,1,0,0,0,0),n=(r.getTime()-i)/(1e3*60*60*24)|0;return _e[e+28>>2]=n,iw.GMTString||(iw.GMTString=uP("GMT")),_e[e+40>>2]=iw.GMTString,e}function jxe(t,e){return iw(t,e)}var yt={splitPath:function(t){var e=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/;return e.exec(t).slice(1)},normalizeArray:function(t,e){for(var r=0,i=t.length-1;i>=0;i--){var n=t[i];n==="."?t.splice(i,1):n===".."?(t.splice(i,1),r++):r&&(t.splice(i,1),r--)}if(e)for(;r;r--)t.unshift("..");return t},normalize:function(t){var e=t.charAt(0)==="/",r=t.substr(-1)==="/";return t=yt.normalizeArray(t.split("/").filter(function(i){return!!i}),!e).join("/"),!t&&!e&&(t="."),t&&r&&(t+="/"),(e?"/":"")+t},dirname:function(t){var e=yt.splitPath(t),r=e[0],i=e[1];return!r&&!i?".":(i&&(i=i.substr(0,i.length-1)),r+i)},basename:function(t){if(t==="/")return"/";t=yt.normalize(t),t=t.replace(/\/$/,"");var e=t.lastIndexOf("/");return e===-1?t:t.substr(e+1)},extname:function(t){return yt.splitPath(t)[3]},join:function(){var t=Array.prototype.slice.call(arguments,0);return yt.normalize(t.join("/"))},join2:function(t,e){return yt.normalize(t+"/"+e)}};function Yxe(){if(typeof crypto=="object"&&typeof crypto.getRandomValues=="function"){var t=new Uint8Array(1);return function(){return crypto.getRandomValues(t),t[0]}}else if(Wl)try{var e=require("crypto");return function(){return e.randomBytes(1)[0]}}catch(r){}return function(){Gr("randomDevice")}}var wa={resolve:function(){for(var t="",e=!1,r=arguments.length-1;r>=-1&&!e;r--){var i=r>=0?arguments[r]:y.cwd();if(typeof i!="string")throw new TypeError("Arguments to path.resolve must be strings");if(!i)return"";t=i+"/"+t,e=i.charAt(0)==="/"}return t=yt.normalizeArray(t.split("/").filter(function(n){return!!n}),!e).join("/"),(e?"/":"")+t||"."},relative:function(t,e){t=wa.resolve(t).substr(1),e=wa.resolve(e).substr(1);function r(c){for(var u=0;u=0&&c[g]==="";g--);return u>g?[]:c.slice(u,g-u+1)}for(var i=r(t.split("/")),n=r(e.split("/")),s=Math.min(i.length,n.length),o=s,a=0;a0?e=i.slice(0,n).toString("utf-8"):e=null}else typeof window!="undefined"&&typeof window.prompt=="function"?(e=window.prompt("Input: "),e!==null&&(e+=` -`)):typeof readline=="function"&&(e=readline(),e!==null&&(e+=` -`));if(!e)return null;t.input=CP(e,!0)}return t.input.shift()},put_char:function(t,e){e===null||e===10?($y(Zu(t.output,0)),t.output=[]):e!=0&&t.output.push(e)},flush:function(t){t.output&&t.output.length>0&&($y(Zu(t.output,0)),t.output=[])}},default_tty1_ops:{put_char:function(t,e){e===null||e===10?(Di(Zu(t.output,0)),t.output=[]):e!=0&&t.output.push(e)},flush:function(t){t.output&&t.output.length>0&&(Di(Zu(t.output,0)),t.output=[])}}};function mP(t){for(var e=mxe(t,65536),r=h4(e);t=e)){var i=1024*1024;e=Math.max(e,r*(r>>0),r!=0&&(e=Math.max(e,256));var n=t.contents;t.contents=new Uint8Array(e),t.usedBytes>0&&t.contents.set(n.subarray(0,t.usedBytes),0)}},resizeFileStorage:function(t,e){if(t.usedBytes!=e)if(e==0)t.contents=null,t.usedBytes=0;else{var r=t.contents;t.contents=new Uint8Array(e),r&&t.contents.set(r.subarray(0,Math.min(e,t.usedBytes))),t.usedBytes=e}},node_ops:{getattr:function(t){var e={};return e.dev=y.isChrdev(t.mode)?t.id:1,e.ino=t.id,e.mode=t.mode,e.nlink=1,e.uid=0,e.gid=0,e.rdev=t.rdev,y.isDir(t.mode)?e.size=4096:y.isFile(t.mode)?e.size=t.usedBytes:y.isLink(t.mode)?e.size=t.link.length:e.size=0,e.atime=new Date(t.timestamp),e.mtime=new Date(t.timestamp),e.ctime=new Date(t.timestamp),e.blksize=4096,e.blocks=Math.ceil(e.size/e.blksize),e},setattr:function(t,e){e.mode!==void 0&&(t.mode=e.mode),e.timestamp!==void 0&&(t.timestamp=e.timestamp),e.size!==void 0&&pt.resizeFileStorage(t,e.size)},lookup:function(t,e){throw y.genericErrors[44]},mknod:function(t,e,r,i){return pt.createNode(t,e,r,i)},rename:function(t,e,r){if(y.isDir(t.mode)){var i;try{i=y.lookupNode(e,r)}catch(s){}if(i)for(var n in i.contents)throw new y.ErrnoError(55)}delete t.parent.contents[t.name],t.parent.timestamp=Date.now(),t.name=r,e.contents[r]=t,e.timestamp=t.parent.timestamp,t.parent=e},unlink:function(t,e){delete t.contents[e],t.timestamp=Date.now()},rmdir:function(t,e){var r=y.lookupNode(t,e);for(var i in r.contents)throw new y.ErrnoError(55);delete t.contents[e],t.timestamp=Date.now()},readdir:function(t){var e=[".",".."];for(var r in t.contents)!t.contents.hasOwnProperty(r)||e.push(r);return e},symlink:function(t,e,r){var i=pt.createNode(t,e,511|40960,0);return i.link=r,i},readlink:function(t){if(!y.isLink(t.mode))throw new y.ErrnoError(28);return t.link}},stream_ops:{read:function(t,e,r,i,n){var s=t.node.contents;if(n>=t.node.usedBytes)return 0;var o=Math.min(t.node.usedBytes-n,i);if(o>8&&s.subarray)e.set(s.subarray(n,n+o),r);else for(var a=0;a0||i+r>2)}catch(r){throw r.code?new y.ErrnoError(tt.convertNodeCode(r)):r}return e.mode},realPath:function(t){for(var e=[];t.parent!==t;)e.push(t.name),t=t.parent;return e.push(t.mount.opts.root),e.reverse(),yt.join.apply(null,e)},flagsForNode:function(t){t&=~2097152,t&=~2048,t&=~32768,t&=~524288;var e=0;for(var r in tt.flagsForNodeMap)t&r&&(e|=tt.flagsForNodeMap[r],t^=r);if(t)throw new y.ErrnoError(28);return e},node_ops:{getattr:function(t){var e=tt.realPath(t),r;try{r=ft.lstatSync(e)}catch(i){throw i.code?new y.ErrnoError(tt.convertNodeCode(i)):i}return tt.isWindows&&!r.blksize&&(r.blksize=4096),tt.isWindows&&!r.blocks&&(r.blocks=(r.size+r.blksize-1)/r.blksize|0),{dev:r.dev,ino:r.ino,mode:r.mode,nlink:r.nlink,uid:r.uid,gid:r.gid,rdev:r.rdev,size:r.size,atime:r.atime,mtime:r.mtime,ctime:r.ctime,blksize:r.blksize,blocks:r.blocks}},setattr:function(t,e){var r=tt.realPath(t);try{if(e.mode!==void 0&&(ft.chmodSync(r,e.mode),t.mode=e.mode),e.timestamp!==void 0){var i=new Date(e.timestamp);ft.utimesSync(r,i,i)}e.size!==void 0&&ft.truncateSync(r,e.size)}catch(n){throw n.code?new y.ErrnoError(tt.convertNodeCode(n)):n}},lookup:function(t,e){var r=yt.join2(tt.realPath(t),e),i=tt.getMode(r);return tt.createNode(t,e,i)},mknod:function(t,e,r,i){var n=tt.createNode(t,e,r,i),s=tt.realPath(n);try{y.isDir(n.mode)?ft.mkdirSync(s,n.mode):ft.writeFileSync(s,"",{mode:n.mode})}catch(o){throw o.code?new y.ErrnoError(tt.convertNodeCode(o)):o}return n},rename:function(t,e,r){var i=tt.realPath(t),n=yt.join2(tt.realPath(e),r);try{ft.renameSync(i,n)}catch(s){throw s.code?new y.ErrnoError(tt.convertNodeCode(s)):s}t.name=r},unlink:function(t,e){var r=yt.join2(tt.realPath(t),e);try{ft.unlinkSync(r)}catch(i){throw i.code?new y.ErrnoError(tt.convertNodeCode(i)):i}},rmdir:function(t,e){var r=yt.join2(tt.realPath(t),e);try{ft.rmdirSync(r)}catch(i){throw i.code?new y.ErrnoError(tt.convertNodeCode(i)):i}},readdir:function(t){var e=tt.realPath(t);try{return ft.readdirSync(e)}catch(r){throw r.code?new y.ErrnoError(tt.convertNodeCode(r)):r}},symlink:function(t,e,r){var i=yt.join2(tt.realPath(t),e);try{ft.symlinkSync(r,i)}catch(n){throw n.code?new y.ErrnoError(tt.convertNodeCode(n)):n}},readlink:function(t){var e=tt.realPath(t);try{return e=ft.readlinkSync(e),e=EP.relative(EP.resolve(t.mount.opts.root),e),e}catch(r){throw r.code?new y.ErrnoError(tt.convertNodeCode(r)):r}}},stream_ops:{open:function(t){var e=tt.realPath(t.node);try{y.isFile(t.node.mode)&&(t.nfd=ft.openSync(e,tt.flagsForNode(t.flags)))}catch(r){throw r.code?new y.ErrnoError(tt.convertNodeCode(r)):r}},close:function(t){try{y.isFile(t.node.mode)&&t.nfd&&ft.closeSync(t.nfd)}catch(e){throw e.code?new y.ErrnoError(tt.convertNodeCode(e)):e}},read:function(t,e,r,i,n){if(i===0)return 0;try{return ft.readSync(t.nfd,tt.bufferFrom(e.buffer),r,i,n)}catch(s){throw new y.ErrnoError(tt.convertNodeCode(s))}},write:function(t,e,r,i,n){try{return ft.writeSync(t.nfd,tt.bufferFrom(e.buffer),r,i,n)}catch(s){throw new y.ErrnoError(tt.convertNodeCode(s))}},llseek:function(t,e,r){var i=e;if(r===1)i+=t.position;else if(r===2&&y.isFile(t.node.mode))try{var n=ft.fstatSync(t.nfd);i+=n.size}catch(s){throw new y.ErrnoError(tt.convertNodeCode(s))}if(i<0)throw new y.ErrnoError(28);return i},mmap:function(t,e,r,i,n,s){if(e!==0)throw new y.ErrnoError(28);if(!y.isFile(t.node.mode))throw new y.ErrnoError(43);var o=mP(r);return tt.stream_ops.read(t,Zi,o,r,i),{ptr:o,allocated:!0}},msync:function(t,e,r,i,n){if(!y.isFile(t.node.mode))throw new y.ErrnoError(43);if(n&2)return 0;var s=tt.stream_ops.write(t,e,0,i,r,!1);return 0}}},w4={lookupPath:function(t){return{path:t,node:{mode:tt.getMode(t)}}},createStandardStreams:function(){y.streams[0]={fd:0,nfd:0,position:0,path:"",flags:0,tty:!0,seekable:!1};for(var t=1;t<3;t++)y.streams[t]={fd:t,nfd:t,position:0,path:"",flags:577,tty:!0,seekable:!1}},cwd:function(){return process.cwd()},chdir:function(){process.chdir.apply(void 0,arguments)},mknod:function(t,e){y.isDir(t)?ft.mkdirSync(t,e):ft.writeFileSync(t,"",{mode:e})},mkdir:function(){ft.mkdirSync.apply(void 0,arguments)},symlink:function(){ft.symlinkSync.apply(void 0,arguments)},rename:function(){ft.renameSync.apply(void 0,arguments)},rmdir:function(){ft.rmdirSync.apply(void 0,arguments)},readdir:function(){ft.readdirSync.apply(void 0,arguments)},unlink:function(){ft.unlinkSync.apply(void 0,arguments)},readlink:function(){return ft.readlinkSync.apply(void 0,arguments)},stat:function(){return ft.statSync.apply(void 0,arguments)},lstat:function(){return ft.lstatSync.apply(void 0,arguments)},chmod:function(){ft.chmodSync.apply(void 0,arguments)},fchmod:function(){ft.fchmodSync.apply(void 0,arguments)},chown:function(){ft.chownSync.apply(void 0,arguments)},fchown:function(){ft.fchownSync.apply(void 0,arguments)},truncate:function(){ft.truncateSync.apply(void 0,arguments)},ftruncate:function(t,e){if(e<0)throw new y.ErrnoError(28);ft.ftruncateSync.apply(void 0,arguments)},utime:function(){ft.utimesSync.apply(void 0,arguments)},open:function(t,e,r,i){typeof e=="string"&&(e=Vl.modeStringToFlags(e));var n=ft.openSync(t,tt.flagsForNode(e),r),s=i!=null?i:y.nextfd(n),o={fd:s,nfd:n,position:0,path:t,flags:e,seekable:!0};return y.streams[s]=o,o},close:function(t){t.stream_ops||ft.closeSync(t.nfd),y.closeStream(t.fd)},llseek:function(t,e,r){if(t.stream_ops)return Vl.llseek(t,e,r);var i=e;if(r===1)i+=t.position;else if(r===2)i+=ft.fstatSync(t.nfd).size;else if(r!==0)throw new y.ErrnoError(eg.EINVAL);if(i<0)throw new y.ErrnoError(eg.EINVAL);return t.position=i,i},read:function(t,e,r,i,n){if(t.stream_ops)return Vl.read(t,e,r,i,n);var s=typeof n!="undefined";!s&&t.seekable&&(n=t.position);var o=ft.readSync(t.nfd,tt.bufferFrom(e.buffer),r,i,n);return s||(t.position+=o),o},write:function(t,e,r,i,n){if(t.stream_ops)return Vl.write(t,e,r,i,n);t.flags&+"1024"&&y.llseek(t,0,+"2");var s=typeof n!="undefined";!s&&t.seekable&&(n=t.position);var o=ft.writeSync(t.nfd,tt.bufferFrom(e.buffer),r,i,n);return s||(t.position+=o),o},allocate:function(){throw new y.ErrnoError(eg.EOPNOTSUPP)},mmap:function(t,e,r,i,n,s){if(t.stream_ops)return Vl.mmap(t,e,r,i,n,s);if(e!==0)throw new y.ErrnoError(28);var o=mP(r);return y.read(t,Zi,o,r,i),{ptr:o,allocated:!0}},msync:function(t,e,r,i,n){return t.stream_ops?Vl.msync(t,e,r,i,n):(n&2||y.write(t,e,0,i,r),0)},munmap:function(){return 0},ioctl:function(){throw new y.ErrnoError(eg.ENOTTY)}},y={root:null,mounts:[],devices:{},streams:[],nextInode:1,nameTable:null,currentPath:"/",initialized:!1,ignorePermissions:!0,trackingDelegate:{},tracking:{openFlags:{READ:1,WRITE:2}},ErrnoError:null,genericErrors:{},filesystems:null,syncFSRequests:0,lookupPath:function(t,e){if(t=wa.resolve(y.cwd(),t),e=e||{},!t)return{path:"",node:null};var r={follow_mount:!0,recurse_count:0};for(var i in r)e[i]===void 0&&(e[i]=r[i]);if(e.recurse_count>8)throw new y.ErrnoError(32);for(var n=yt.normalizeArray(t.split("/").filter(function(f){return!!f}),!1),s=y.root,o="/",a=0;a40)throw new y.ErrnoError(32)}}return{path:o,node:s}},getPath:function(t){for(var e;;){if(y.isRoot(t)){var r=t.mount.mountpoint;return e?r[r.length-1]!=="/"?r+"/"+e:r+e:r}e=e?t.name+"/"+e:t.name,t=t.parent}},hashName:function(t,e){for(var r=0,i=0;i>>0)%y.nameTable.length},hashAddNode:function(t){var e=y.hashName(t.parent.id,t.name);t.name_next=y.nameTable[e],y.nameTable[e]=t},hashRemoveNode:function(t){var e=y.hashName(t.parent.id,t.name);if(y.nameTable[e]===t)y.nameTable[e]=t.name_next;else for(var r=y.nameTable[e];r;){if(r.name_next===t){r.name_next=t.name_next;break}r=r.name_next}},lookupNode:function(t,e){var r=y.mayLookup(t);if(r)throw new y.ErrnoError(r,t);for(var i=y.hashName(t.id,e),n=y.nameTable[i];n;n=n.name_next){var s=n.name;if(n.parent.id===t.id&&s===e)return n}return y.lookup(t,e)},createNode:function(t,e,r,i){var n=new y.FSNode(t,e,r,i);return y.hashAddNode(n),n},destroyNode:function(t){y.hashRemoveNode(t)},isRoot:function(t){return t===t.parent},isMountpoint:function(t){return!!t.mounted},isFile:function(t){return(t&61440)==32768},isDir:function(t){return(t&61440)==16384},isLink:function(t){return(t&61440)==40960},isChrdev:function(t){return(t&61440)==8192},isBlkdev:function(t){return(t&61440)==24576},isFIFO:function(t){return(t&61440)==4096},isSocket:function(t){return(t&49152)==49152},flagModes:{r:0,"r+":2,w:577,"w+":578,a:1089,"a+":1090},modeStringToFlags:function(t){var e=y.flagModes[t];if(typeof e=="undefined")throw new Error("Unknown file open mode: "+t);return e},flagsToPermissionString:function(t){var e=["r","w","rw"][t&3];return t&512&&(e+="w"),e},nodePermissions:function(t,e){return y.ignorePermissions?0:e.includes("r")&&!(t.mode&292)||e.includes("w")&&!(t.mode&146)||e.includes("x")&&!(t.mode&73)?2:0},mayLookup:function(t){var e=y.nodePermissions(t,"x");return e||(t.node_ops.lookup?0:2)},mayCreate:function(t,e){try{var r=y.lookupNode(t,e);return 20}catch(i){}return y.nodePermissions(t,"wx")},mayDelete:function(t,e,r){var i;try{i=y.lookupNode(t,e)}catch(s){return s.errno}var n=y.nodePermissions(t,"wx");if(n)return n;if(r){if(!y.isDir(i.mode))return 54;if(y.isRoot(i)||y.getPath(i)===y.cwd())return 10}else if(y.isDir(i.mode))return 31;return 0},mayOpen:function(t,e){return t?y.isLink(t.mode)?32:y.isDir(t.mode)&&(y.flagsToPermissionString(e)!=="r"||e&512)?31:y.nodePermissions(t,y.flagsToPermissionString(e)):44},MAX_OPEN_FDS:4096,nextfd:function(t,e){t=t||0,e=e||y.MAX_OPEN_FDS;for(var r=t;r<=e;r++)if(!y.streams[r])return r;throw new y.ErrnoError(33)},getStream:function(t){return y.streams[t]},createStream:function(t,e,r){y.FSStream||(y.FSStream=function(){},y.FSStream.prototype={object:{get:function(){return this.node},set:function(o){this.node=o}},isRead:{get:function(){return(this.flags&2097155)!=1}},isWrite:{get:function(){return(this.flags&2097155)!=0}},isAppend:{get:function(){return this.flags&1024}}});var i=new y.FSStream;for(var n in t)i[n]=t[n];t=i;var s=y.nextfd(e,r);return t.fd=s,y.streams[s]=t,t},closeStream:function(t){y.streams[t]=null},chrdev_stream_ops:{open:function(t){var e=y.getDevice(t.node.rdev);t.stream_ops=e.stream_ops,t.stream_ops.open&&t.stream_ops.open(t)},llseek:function(){throw new y.ErrnoError(70)}},major:function(t){return t>>8},minor:function(t){return t&255},makedev:function(t,e){return t<<8|e},registerDevice:function(t,e){y.devices[t]={stream_ops:e}},getDevice:function(t){return y.devices[t]},getMounts:function(t){for(var e=[],r=[t];r.length;){var i=r.pop();e.push(i),r.push.apply(r,i.mounts)}return e},syncfs:function(t,e){typeof t=="function"&&(e=t,t=!1),y.syncFSRequests++,y.syncFSRequests>1&&Di("warning: "+y.syncFSRequests+" FS.syncfs operations in flight at once, probably just doing extra work");var r=y.getMounts(y.root.mount),i=0;function n(o){return y.syncFSRequests--,e(o)}function s(o){if(o)return s.errored?void 0:(s.errored=!0,n(o));++i>=r.length&&n(null)}r.forEach(function(o){if(!o.type.syncfs)return s(null);o.type.syncfs(o,t,s)})},mount:function(t,e,r){var i=r==="/",n=!r,s;if(i&&y.root)throw new y.ErrnoError(10);if(!i&&!n){var o=y.lookupPath(r,{follow_mount:!1});if(r=o.path,s=o.node,y.isMountpoint(s))throw new y.ErrnoError(10);if(!y.isDir(s.mode))throw new y.ErrnoError(54)}var a={type:t,opts:e,mountpoint:r,mounts:[]},l=t.mount(a);return l.mount=a,a.root=l,i?y.root=l:s&&(s.mounted=a,s.mount&&s.mount.mounts.push(a)),l},unmount:function(t){var e=y.lookupPath(t,{follow_mount:!1});if(!y.isMountpoint(e.node))throw new y.ErrnoError(28);var r=e.node,i=r.mounted,n=y.getMounts(i);Object.keys(y.nameTable).forEach(function(o){for(var a=y.nameTable[o];a;){var l=a.name_next;n.includes(a.mount)&&y.destroyNode(a),a=l}}),r.mounted=null;var s=r.mount.mounts.indexOf(i);r.mount.mounts.splice(s,1)},lookup:function(t,e){return t.node_ops.lookup(t,e)},mknod:function(t,e,r){var i=y.lookupPath(t,{parent:!0}),n=i.node,s=yt.basename(t);if(!s||s==="."||s==="..")throw new y.ErrnoError(28);var o=y.mayCreate(n,s);if(o)throw new y.ErrnoError(o);if(!n.node_ops.mknod)throw new y.ErrnoError(63);return n.node_ops.mknod(n,s,e,r)},create:function(t,e){return e=e!==void 0?e:438,e&=4095,e|=32768,y.mknod(t,e,0)},mkdir:function(t,e){return e=e!==void 0?e:511,e&=511|512,e|=16384,y.mknod(t,e,0)},mkdirTree:function(t,e){for(var r=t.split("/"),i="",n=0;nthis.length-1||f<0)){var h=f%this.chunkSize,p=f/this.chunkSize|0;return this.getter(p)[h]}},s.prototype.setDataGetter=function(f){this.getter=f},s.prototype.cacheLength=function(){var f=new XMLHttpRequest;if(f.open("HEAD",r,!1),f.send(null),!(f.status>=200&&f.status<300||f.status===304))throw new Error("Couldn't load "+r+". Status: "+f.status);var h=Number(f.getResponseHeader("Content-length")),p,d=(p=f.getResponseHeader("Accept-Ranges"))&&p==="bytes",m=(p=f.getResponseHeader("Content-Encoding"))&&p==="gzip",I=1024*1024;d||(I=h);var B=function(R,H){if(R>H)throw new Error("invalid range ("+R+", "+H+") or no bytes requested!");if(H>h-1)throw new Error("only "+h+" bytes available! programmer error!");var L=new XMLHttpRequest;if(L.open("GET",r,!1),h!==I&&L.setRequestHeader("Range","bytes="+R+"-"+H),typeof Uint8Array!="undefined"&&(L.responseType="arraybuffer"),L.overrideMimeType&&L.overrideMimeType("text/plain; charset=x-user-defined"),L.send(null),!(L.status>=200&&L.status<300||L.status===304))throw new Error("Couldn't load "+r+". Status: "+L.status);return L.response!==void 0?new Uint8Array(L.response||[]):CP(L.responseText||"",!0)},b=this;b.setDataGetter(function(R){var H=R*I,L=(R+1)*I-1;if(L=Math.min(L,h-1),typeof b.chunks[R]=="undefined"&&(b.chunks[R]=B(H,L)),typeof b.chunks[R]=="undefined")throw new Error("doXHR failed!");return b.chunks[R]}),(m||!h)&&(I=h=1,h=this.getter(0).length,I=h,$y("LazyFiles on gzip forces download of the whole file when length is accessed")),this._length=h,this._chunkSize=I,this.lengthKnown=!0},typeof XMLHttpRequest!="undefined"){if(!i4)throw"Cannot do synchronous binary XHRs outside webworkers in modern browsers. Use --embed-file or --preload-file in emcc";var o=new s;Object.defineProperties(o,{length:{get:function(){return this.lengthKnown||this.cacheLength(),this._length}},chunkSize:{get:function(){return this.lengthKnown||this.cacheLength(),this._chunkSize}}});var a={isDevice:!1,contents:o}}else var a={isDevice:!1,url:r};var l=y.createFile(t,e,a,i,n);a.contents?l.contents=a.contents:a.url&&(l.contents=null,l.url=a.url),Object.defineProperties(l,{usedBytes:{get:function(){return this.contents.length}}});var c={},u=Object.keys(l.stream_ops);return u.forEach(function(g){var f=l.stream_ops[g];c[g]=function(){return y.forceLoadFile(l),f.apply(null,arguments)}}),c.read=function(f,h,p,d,m){y.forceLoadFile(l);var I=f.node.contents;if(m>=I.length)return 0;var B=Math.min(I.length-m,d);if(I.slice)for(var b=0;b>2]=i.dev,_e[r+4>>2]=0,_e[r+8>>2]=i.ino,_e[r+12>>2]=i.mode,_e[r+16>>2]=i.nlink,_e[r+20>>2]=i.uid,_e[r+24>>2]=i.gid,_e[r+28>>2]=i.rdev,_e[r+32>>2]=0,ya=[i.size>>>0,(ai=i.size,+Math.abs(ai)>=1?ai>0?(Math.min(+Math.floor(ai/4294967296),4294967295)|0)>>>0:~~+Math.ceil((ai-+(~~ai>>>0))/4294967296)>>>0:0)],_e[r+40>>2]=ya[0],_e[r+44>>2]=ya[1],_e[r+48>>2]=4096,_e[r+52>>2]=i.blocks,_e[r+56>>2]=i.atime.getTime()/1e3|0,_e[r+60>>2]=0,_e[r+64>>2]=i.mtime.getTime()/1e3|0,_e[r+68>>2]=0,_e[r+72>>2]=i.ctime.getTime()/1e3|0,_e[r+76>>2]=0,ya=[i.ino>>>0,(ai=i.ino,+Math.abs(ai)>=1?ai>0?(Math.min(+Math.floor(ai/4294967296),4294967295)|0)>>>0:~~+Math.ceil((ai-+(~~ai>>>0))/4294967296)>>>0:0)],_e[r+80>>2]=ya[0],_e[r+84>>2]=ya[1],0},doMsync:function(t,e,r,i,n){var s=$u.slice(t,t+r);y.msync(e,s,n,r,i)},doMkdir:function(t,e){return t=yt.normalize(t),t[t.length-1]==="/"&&(t=t.substr(0,t.length-1)),y.mkdir(t,e,0),0},doMknod:function(t,e,r){switch(e&61440){case 32768:case 8192:case 24576:case 4096:case 49152:break;default:return-28}return y.mknod(t,e,r),0},doReadlink:function(t,e,r){if(r<=0)return-28;var i=y.readlink(t),n=Math.min(r,rw(i)),s=Zi[e+n];return u4(i,e,r+1),Zi[e+n]=s,n},doAccess:function(t,e){if(e&~7)return-28;var r,i=y.lookupPath(t,{follow:!0});if(r=i.node,!r)return-44;var n="";return e&4&&(n+="r"),e&2&&(n+="w"),e&1&&(n+="x"),n&&y.nodePermissions(r,n)?-2:0},doDup:function(t,e,r){var i=y.getStream(r);return i&&y.close(i),y.open(t,e,0,r,r).fd},doReadv:function(t,e,r,i){for(var n=0,s=0;s>2],a=_e[e+(s*8+4)>>2],l=y.read(t,Zi,o,a,i);if(l<0)return-1;if(n+=l,l>2],a=_e[e+(s*8+4)>>2],l=y.write(t,Zi,o,a,i);if(l<0)return-1;n+=l}return n},varargs:void 0,get:function(){Ot.varargs+=4;var t=_e[Ot.varargs-4>>2];return t},getStr:function(t){var e=c4(t);return e},getStreamFromFD:function(t){var e=y.getStream(t);if(!e)throw new y.ErrnoError(8);return e},get64:function(t,e){return t}};function qxe(t,e){try{return t=Ot.getStr(t),y.chmod(t,e),0}catch(r){return(typeof y=="undefined"||!(r instanceof y.ErrnoError))&&Gr(r),-r.errno}}function Wxe(t){return _e[Jxe()>>2]=t,t}function zxe(t,e,r){Ot.varargs=r;try{var i=Ot.getStreamFromFD(t);switch(e){case 0:{var n=Ot.get();if(n<0)return-28;var s;return s=y.open(i.path,i.flags,0,n),s.fd}case 1:case 2:return 0;case 3:return i.flags;case 4:{var n=Ot.get();return i.flags|=n,0}case 12:{var n=Ot.get(),o=0;return cP[n+o>>1]=2,0}case 13:case 14:return 0;case 16:case 8:return-28;case 9:return Wxe(28),-1;default:return-28}}catch(a){return(typeof y=="undefined"||!(a instanceof y.ErrnoError))&&Gr(a),-a.errno}}function Vxe(t,e){try{var r=Ot.getStreamFromFD(t);return Ot.doStat(y.stat,r.path,e)}catch(i){return(typeof y=="undefined"||!(i instanceof y.ErrnoError))&&Gr(i),-i.errno}}function _xe(t,e,r){Ot.varargs=r;try{var i=Ot.getStreamFromFD(t);switch(e){case 21509:case 21505:return i.tty?0:-59;case 21510:case 21511:case 21512:case 21506:case 21507:case 21508:return i.tty?0:-59;case 21519:{if(!i.tty)return-59;var n=Ot.get();return _e[n>>2]=0,0}case 21520:return i.tty?-28:-59;case 21531:{var n=Ot.get();return y.ioctl(i,e,n)}case 21523:return i.tty?0:-59;case 21524:return i.tty?0:-59;default:Gr("bad ioctl syscall "+e)}}catch(s){return(typeof y=="undefined"||!(s instanceof y.ErrnoError))&&Gr(s),-s.errno}}function Xxe(t,e,r){Ot.varargs=r;try{var i=Ot.getStr(t),n=r?Ot.get():0,s=y.open(i,e,n);return s.fd}catch(o){return(typeof y=="undefined"||!(o instanceof y.ErrnoError))&&Gr(o),-o.errno}}function Zxe(t,e){try{return t=Ot.getStr(t),e=Ot.getStr(e),y.rename(t,e),0}catch(r){return(typeof y=="undefined"||!(r instanceof y.ErrnoError))&&Gr(r),-r.errno}}function $xe(t){try{return t=Ot.getStr(t),y.rmdir(t),0}catch(e){return(typeof y=="undefined"||!(e instanceof y.ErrnoError))&&Gr(e),-e.errno}}function eke(t,e){try{return t=Ot.getStr(t),Ot.doStat(y.stat,t,e)}catch(r){return(typeof y=="undefined"||!(r instanceof y.ErrnoError))&&Gr(r),-r.errno}}function tke(t){try{return t=Ot.getStr(t),y.unlink(t),0}catch(e){return(typeof y=="undefined"||!(e instanceof y.ErrnoError))&&Gr(e),-e.errno}}function rke(t,e,r){$u.copyWithin(t,e,e+r)}function ike(t){try{return ew.grow(t-gP.byteLength+65535>>>16),p4(ew.buffer),1}catch(e){}}function nke(t){var e=$u.length;t=t>>>0;var r=2147483648;if(t>r)return!1;for(var i=1;i<=4;i*=2){var n=e*(1+.2/i);n=Math.min(n,t+100663296);var s=Math.min(r,xxe(Math.max(t,n),65536)),o=ike(s);if(o)return!0}return!1}function ske(t){try{var e=Ot.getStreamFromFD(t);return y.close(e),0}catch(r){return(typeof y=="undefined"||!(r instanceof y.ErrnoError))&&Gr(r),r.errno}}function oke(t,e){try{var r=Ot.getStreamFromFD(t),i=r.tty?2:y.isDir(r.mode)?3:y.isLink(r.mode)?7:4;return Zi[e>>0]=i,0}catch(n){return(typeof y=="undefined"||!(n instanceof y.ErrnoError))&&Gr(n),n.errno}}function ake(t,e,r,i){try{var n=Ot.getStreamFromFD(t),s=Ot.doReadv(n,e,r);return _e[i>>2]=s,0}catch(o){return(typeof y=="undefined"||!(o instanceof y.ErrnoError))&&Gr(o),o.errno}}function Ake(t,e,r,i,n){try{var s=Ot.getStreamFromFD(t),o=4294967296,a=r*o+(e>>>0),l=9007199254740992;return a<=-l||a>=l?-61:(y.llseek(s,a,i),ya=[s.position>>>0,(ai=s.position,+Math.abs(ai)>=1?ai>0?(Math.min(+Math.floor(ai/4294967296),4294967295)|0)>>>0:~~+Math.ceil((ai-+(~~ai>>>0))/4294967296)>>>0:0)],_e[n>>2]=ya[0],_e[n+4>>2]=ya[1],s.getdents&&a===0&&i===0&&(s.getdents=null),0)}catch(c){return(typeof y=="undefined"||!(c instanceof y.ErrnoError))&&Gr(c),c.errno}}function lke(t,e,r,i){try{var n=Ot.getStreamFromFD(t),s=Ot.doWritev(n,e,r);return _e[i>>2]=s,0}catch(o){return(typeof y=="undefined"||!(o instanceof y.ErrnoError))&&Gr(o),o.errno}}function cke(t){Ixe(t)}function uke(t){var e=Date.now()/1e3|0;return t&&(_e[t>>2]=e),e}function IP(){if(IP.called)return;IP.called=!0;var t=new Date().getFullYear(),e=new Date(t,0,1),r=new Date(t,6,1),i=e.getTimezoneOffset(),n=r.getTimezoneOffset(),s=Math.max(i,n);_e[fke()>>2]=s*60,_e[gke()>>2]=Number(i!=n);function o(g){var f=g.toTimeString().match(/\(([A-Za-z ]+)\)$/);return f?f[1]:"GMT"}var a=o(e),l=o(r),c=uP(a),u=uP(l);n>2]=c,_e[nw()+4>>2]=u):(_e[nw()>>2]=u,_e[nw()+4>>2]=c)}function hke(t){IP();var e=Date.UTC(_e[t+20>>2]+1900,_e[t+16>>2],_e[t+12>>2],_e[t+8>>2],_e[t+4>>2],_e[t>>2],0),r=new Date(e);_e[t+24>>2]=r.getUTCDay();var i=Date.UTC(r.getUTCFullYear(),0,1,0,0,0,0),n=(r.getTime()-i)/(1e3*60*60*24)|0;return _e[t+28>>2]=n,r.getTime()/1e3|0}var B4=function(t,e,r,i){t||(t=this),this.parent=t,this.mount=t.mount,this.mounted=null,this.id=y.nextInode++,this.name=e,this.mode=r,this.node_ops={},this.stream_ops={},this.rdev=i},sw=292|73,ow=146;Object.defineProperties(B4.prototype,{read:{get:function(){return(this.mode&sw)===sw},set:function(t){t?this.mode|=sw:this.mode&=~sw}},write:{get:function(){return(this.mode&ow)===ow},set:function(t){t?this.mode|=ow:this.mode&=~ow}},isFolder:{get:function(){return y.isDir(this.mode)}},isDevice:{get:function(){return y.isChrdev(this.mode)}}});y.FSNode=B4;y.staticInit();Wl&&(ft=e4,EP=require("path"),tt.staticInit());var ft,EP;if(Wl){Q4=function(t){return function(){try{return t.apply(this,arguments)}catch(e){throw e.code?new y.ErrnoError(eg[e.code]):e}}},Vl=Object.assign({},y);for(yP in w4)y[yP]=Q4(w4[yP])}else throw new Error("NODERAWFS is currently only supported on Node.js environment.");var Q4,Vl,yP;function CP(t,e,r){var i=r>0?r:rw(t)+1,n=new Array(i),s=tw(t,n,0,n.length);return e&&(n.length=s),n}var pke=typeof atob=="function"?atob:function(t){var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",r="",i,n,s,o,a,l,c,u=0;t=t.replace(/[^A-Za-z0-9\+\/\=]/g,"");do o=e.indexOf(t.charAt(u++)),a=e.indexOf(t.charAt(u++)),l=e.indexOf(t.charAt(u++)),c=e.indexOf(t.charAt(u++)),i=o<<2|a>>4,n=(a&15)<<4|l>>2,s=(l&3)<<6|c,r=r+String.fromCharCode(i),l!==64&&(r=r+String.fromCharCode(n)),c!==64&&(r=r+String.fromCharCode(s));while(u0||(Fxe(),zl>0))return;function e(){aw||(aw=!0,oe.calledRun=!0,!A4&&(Nxe(),oe.onRuntimeInitialized&&oe.onRuntimeInitialized(),Txe()))}oe.setStatus?(oe.setStatus("Running..."),setTimeout(function(){setTimeout(function(){oe.setStatus("")},1),e()},1)):e()}oe.run=wP;if(oe.preInit)for(typeof oe.preInit=="function"&&(oe.preInit=[oe.preInit]);oe.preInit.length>0;)oe.preInit.pop()();wP()});var x4=E((Dot,S4)=>{"use strict";function Cke(t,e){function r(){this.constructor=t}r.prototype=e.prototype,t.prototype=new r}function _l(t,e,r,i){this.message=t,this.expected=e,this.found=r,this.location=i,this.name="SyntaxError",typeof Error.captureStackTrace=="function"&&Error.captureStackTrace(this,_l)}Cke(_l,Error);_l.buildMessage=function(t,e){var r={literal:function(c){return'"'+n(c.text)+'"'},class:function(c){var u="",g;for(g=0;g0){for(g=1,f=1;g>",ee=At(">>",!1),Ue=">&",Oe=At(">&",!1),vt=">",dt=At(">",!1),ri="<<<",ii=At("<<<",!1),an="<&",yr=At("<&",!1),Ki="<",Qi=At("<",!1),Go=function(C){return{type:"argument",segments:[].concat(...C)}},wr=function(C){return C},Ui="'",ws=At("'",!1),Tf=function(C){return[{type:"text",text:C}]},Mf='"',Rm=At('"',!1),Fm=function(C){return C},Nm=function(C){return{type:"arithmetic",arithmetic:C,quoted:!0}},DQ=function(C){return{type:"shell",shell:C,quoted:!0}},RQ=function(C){return _(P({type:"variable"},C),{quoted:!0})},Of=function(C){return{type:"text",text:C}},FQ=function(C){return{type:"arithmetic",arithmetic:C,quoted:!1}},NQ=function(C){return{type:"shell",shell:C,quoted:!1}},Lm=function(C){return _(P({type:"variable"},C),{quoted:!1})},LQ=function(C){return{type:"glob",pattern:C}},Va="\\",jo=At("\\",!1),Tm=/^[\\']/,Mm=Qs(["\\","'"],!1,!1),te=function(C){return C},Om=/^[^']/,Km=Qs(["'"],!0,!1),il=function(C){return C.join("")},Um=/^[\\$"]/,Hm=Qs(["\\","$",'"'],!1,!1),Kf=/^[^$"]/,Gm=Qs(["$",'"'],!0,!1),jm="\\0",TQ=At("\\0",!1),MQ=function(){return"\0"},Ym="\\a",qm=At("\\a",!1),Jm=function(){return"a"},Wm="\\b",zm=At("\\b",!1),Vm=function(){return"\b"},Uf="\\e",OQ=At("\\e",!1),KQ=function(){return""},_m="\\f",UQ=At("\\f",!1),HQ=function(){return"\f"},O="\\n",ht=At("\\n",!1),Vc=function(){return` -`},xn="\\r",Hf=At("\\r",!1),Ye=function(){return"\r"},nl="\\t",Xm=At("\\t",!1),MM=function(){return" "},GQ="\\v",OM=At("\\v",!1),fr=function(){return"\v"},Bs="\\x",jQ=At("\\x",!1),Zm=function(C){return String.fromCharCode(parseInt(C,16))},Yo="\\u",$m=At("\\u",!1),_a="\\U",et=At("\\U",!1),YQ=function(C){return String.fromCodePoint(parseInt(C,16))},eE=/^[0-9a-fA-f]/,tE=Qs([["0","9"],["a","f"],["A","f"]],!1,!1),Xa=Cfe(),sl="-",ol=At("-",!1),al="+",qo=At("+",!1),Al=".",qQ=At(".",!1),rE=function(C,Q,k){return{type:"number",value:(C==="-"?-1:1)*parseFloat(Q.join("")+"."+k.join(""))}},iE=function(C,Q){return{type:"number",value:(C==="-"?-1:1)*parseInt(Q.join(""))}},JQ=function(C){return P({type:"variable"},C)},ll=function(C){return{type:"variable",name:C}},WQ=function(C){return C},nE="*",Gf=At("*",!1),_c="/",jf=At("/",!1),sE=function(C,Q,k){return{type:Q==="*"?"multiplication":"division",right:k}},cl=function(C,Q){return Q.reduce((k,N)=>P({left:k},N),C)},oE=function(C,Q,k){return{type:Q==="+"?"addition":"subtraction",right:k}},Yf="$((",Xc=At("$((",!1),xr="))",KM=At("))",!1),Jo=function(C){return C},Zs="$(",aE=At("$(",!1),Zc=function(C){return C},x="${",U=At("${",!1),le=":-",xe=At(":-",!1),Qe=function(C,Q){return{name:C,defaultValue:Q}},Ge=":-}",ct=At(":-}",!1),sr=function(C){return{name:C,defaultValue:[]}},Wo=function(C){return{name:C}},Afe="$",lfe=At("$",!1),cfe=function(C){return e.isGlobPattern(C)},ufe=function(C){return C},UM=/^[a-zA-Z0-9_]/,HM=Qs([["a","z"],["A","Z"],["0","9"],"_"],!1,!1),GM=function(){return dfe()},jM=/^[$@*?#a-zA-Z0-9_\-]/,YM=Qs(["$","@","*","?","#",["a","z"],["A","Z"],["0","9"],"_","-"],!1,!1),gfe=/^[(){}<>$|&; \t"']/,ffe=Qs(["(",")","{","}","<",">","$","|","&",";"," "," ",'"',"'"],!1,!1),hfe=/^[<>&; \t"']/,pfe=Qs(["<",">","&",";"," "," ",'"',"'"],!1,!1),qM=/^[ \t]/,JM=Qs([" "," "],!1,!1),w=0,Re=0,AE=[{line:1,column:1}],$s=0,zQ=[],we=0,lE;if("startRule"in e){if(!(e.startRule in i))throw new Error(`Can't start parsing from rule "`+e.startRule+'".');n=i[e.startRule]}function dfe(){return t.substring(Re,w)}function P_e(){return qf(Re,w)}function D_e(C,Q){throw Q=Q!==void 0?Q:qf(Re,w),zM([Efe(C)],t.substring(Re,w),Q)}function R_e(C,Q){throw Q=Q!==void 0?Q:qf(Re,w),Ife(C,Q)}function At(C,Q){return{type:"literal",text:C,ignoreCase:Q}}function Qs(C,Q,k){return{type:"class",parts:C,inverted:Q,ignoreCase:k}}function Cfe(){return{type:"any"}}function mfe(){return{type:"end"}}function Efe(C){return{type:"other",description:C}}function WM(C){var Q=AE[C],k;if(Q)return Q;for(k=C-1;!AE[k];)k--;for(Q=AE[k],Q={line:Q.line,column:Q.column};k$s&&($s=w,zQ=[]),zQ.push(C))}function Ife(C,Q){return new _l(C,null,null,Q)}function zM(C,Q,k){return new _l(_l.buildMessage(C,Q),C,Q,k)}function VM(){var C,Q;return C=w,Q=Jf(),Q===r&&(Q=null),Q!==r&&(Re=C,Q=s(Q)),C=Q,C}function Jf(){var C,Q,k,N,Z;if(C=w,Q=VQ(),Q!==r){for(k=[],N=ke();N!==r;)k.push(N),N=ke();k!==r?(N=_M(),N!==r?(Z=yfe(),Z===r&&(Z=null),Z!==r?(Re=C,Q=o(Q,N,Z),C=Q):(w=C,C=r)):(w=C,C=r)):(w=C,C=r)}else w=C,C=r;if(C===r)if(C=w,Q=VQ(),Q!==r){for(k=[],N=ke();N!==r;)k.push(N),N=ke();k!==r?(N=_M(),N===r&&(N=null),N!==r?(Re=C,Q=a(Q,N),C=Q):(w=C,C=r)):(w=C,C=r)}else w=C,C=r;return C}function yfe(){var C,Q,k,N,Z;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r)if(k=Jf(),k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();N!==r?(Re=C,Q=l(k),C=Q):(w=C,C=r)}else w=C,C=r;else w=C,C=r;return C}function _M(){var C;return t.charCodeAt(w)===59?(C=c,w++):(C=r,we===0&&ve(u)),C===r&&(t.charCodeAt(w)===38?(C=g,w++):(C=r,we===0&&ve(f))),C}function VQ(){var C,Q,k;return C=w,Q=XM(),Q!==r?(k=wfe(),k===r&&(k=null),k!==r?(Re=C,Q=h(Q,k),C=Q):(w=C,C=r)):(w=C,C=r),C}function wfe(){var C,Q,k,N,Z,Ee,ot;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r)if(k=Bfe(),k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();if(N!==r)if(Z=VQ(),Z!==r){for(Ee=[],ot=ke();ot!==r;)Ee.push(ot),ot=ke();Ee!==r?(Re=C,Q=p(k,Z),C=Q):(w=C,C=r)}else w=C,C=r;else w=C,C=r}else w=C,C=r;else w=C,C=r;return C}function Bfe(){var C;return t.substr(w,2)===d?(C=d,w+=2):(C=r,we===0&&ve(m)),C===r&&(t.substr(w,2)===I?(C=I,w+=2):(C=r,we===0&&ve(B))),C}function XM(){var C,Q,k;return C=w,Q=vfe(),Q!==r?(k=Qfe(),k===r&&(k=null),k!==r?(Re=C,Q=b(Q,k),C=Q):(w=C,C=r)):(w=C,C=r),C}function Qfe(){var C,Q,k,N,Z,Ee,ot;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r)if(k=bfe(),k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();if(N!==r)if(Z=XM(),Z!==r){for(Ee=[],ot=ke();ot!==r;)Ee.push(ot),ot=ke();Ee!==r?(Re=C,Q=R(k,Z),C=Q):(w=C,C=r)}else w=C,C=r;else w=C,C=r}else w=C,C=r;else w=C,C=r;return C}function bfe(){var C;return t.substr(w,2)===H?(C=H,w+=2):(C=r,we===0&&ve(L)),C===r&&(t.charCodeAt(w)===124?(C=K,w++):(C=r,we===0&&ve(J))),C}function cE(){var C,Q,k,N,Z,Ee;if(C=w,Q=oO(),Q!==r)if(t.charCodeAt(w)===61?(k=ne,w++):(k=r,we===0&&ve(q)),k!==r)if(N=$M(),N!==r){for(Z=[],Ee=ke();Ee!==r;)Z.push(Ee),Ee=ke();Z!==r?(Re=C,Q=A(Q,N),C=Q):(w=C,C=r)}else w=C,C=r;else w=C,C=r;else w=C,C=r;if(C===r)if(C=w,Q=oO(),Q!==r)if(t.charCodeAt(w)===61?(k=ne,w++):(k=r,we===0&&ve(q)),k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();N!==r?(Re=C,Q=V(Q),C=Q):(w=C,C=r)}else w=C,C=r;else w=C,C=r;return C}function vfe(){var C,Q,k,N,Z,Ee,ot,ut,Tr,ni,Yn;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r)if(t.charCodeAt(w)===40?(k=W,w++):(k=r,we===0&&ve(X)),k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();if(N!==r)if(Z=Jf(),Z!==r){for(Ee=[],ot=ke();ot!==r;)Ee.push(ot),ot=ke();if(Ee!==r)if(t.charCodeAt(w)===41?(ot=F,w++):(ot=r,we===0&&ve(D)),ot!==r){for(ut=[],Tr=ke();Tr!==r;)ut.push(Tr),Tr=ke();if(ut!==r){for(Tr=[],ni=Wf();ni!==r;)Tr.push(ni),ni=Wf();if(Tr!==r){for(ni=[],Yn=ke();Yn!==r;)ni.push(Yn),Yn=ke();ni!==r?(Re=C,Q=he(Z,Tr),C=Q):(w=C,C=r)}else w=C,C=r}else w=C,C=r}else w=C,C=r;else w=C,C=r}else w=C,C=r;else w=C,C=r}else w=C,C=r;else w=C,C=r;if(C===r){for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r)if(t.charCodeAt(w)===123?(k=pe,w++):(k=r,we===0&&ve(Ne)),k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();if(N!==r)if(Z=Jf(),Z!==r){for(Ee=[],ot=ke();ot!==r;)Ee.push(ot),ot=ke();if(Ee!==r)if(t.charCodeAt(w)===125?(ot=Pe,w++):(ot=r,we===0&&ve(qe)),ot!==r){for(ut=[],Tr=ke();Tr!==r;)ut.push(Tr),Tr=ke();if(ut!==r){for(Tr=[],ni=Wf();ni!==r;)Tr.push(ni),ni=Wf();if(Tr!==r){for(ni=[],Yn=ke();Yn!==r;)ni.push(Yn),Yn=ke();ni!==r?(Re=C,Q=re(Z,Tr),C=Q):(w=C,C=r)}else w=C,C=r}else w=C,C=r}else w=C,C=r;else w=C,C=r}else w=C,C=r;else w=C,C=r}else w=C,C=r;else w=C,C=r;if(C===r){for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r){for(k=[],N=cE();N!==r;)k.push(N),N=cE();if(k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();if(N!==r){if(Z=[],Ee=ZM(),Ee!==r)for(;Ee!==r;)Z.push(Ee),Ee=ZM();else Z=r;if(Z!==r){for(Ee=[],ot=ke();ot!==r;)Ee.push(ot),ot=ke();Ee!==r?(Re=C,Q=se(k,Z),C=Q):(w=C,C=r)}else w=C,C=r}else w=C,C=r}else w=C,C=r}else w=C,C=r;if(C===r){for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r){if(k=[],N=cE(),N!==r)for(;N!==r;)k.push(N),N=cE();else k=r;if(k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();N!==r?(Re=C,Q=be(k),C=Q):(w=C,C=r)}else w=C,C=r}else w=C,C=r}}}return C}function Sfe(){var C,Q,k,N,Z;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r){if(k=[],N=uE(),N!==r)for(;N!==r;)k.push(N),N=uE();else k=r;if(k!==r){for(N=[],Z=ke();Z!==r;)N.push(Z),Z=ke();N!==r?(Re=C,Q=ae(k),C=Q):(w=C,C=r)}else w=C,C=r}else w=C,C=r;return C}function ZM(){var C,Q,k;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();if(Q!==r?(k=Wf(),k!==r?(Re=C,Q=Ae(k),C=Q):(w=C,C=r)):(w=C,C=r),C===r){for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();Q!==r?(k=uE(),k!==r?(Re=C,Q=Ae(k),C=Q):(w=C,C=r)):(w=C,C=r)}return C}function Wf(){var C,Q,k,N,Z;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();return Q!==r?(De.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve($)),k===r&&(k=null),k!==r?(N=xfe(),N!==r?(Z=uE(),Z!==r?(Re=C,Q=G(k,N,Z),C=Q):(w=C,C=r)):(w=C,C=r)):(w=C,C=r)):(w=C,C=r),C}function xfe(){var C;return t.substr(w,2)===Ce?(C=Ce,w+=2):(C=r,we===0&&ve(ee)),C===r&&(t.substr(w,2)===Ue?(C=Ue,w+=2):(C=r,we===0&&ve(Oe)),C===r&&(t.charCodeAt(w)===62?(C=vt,w++):(C=r,we===0&&ve(dt)),C===r&&(t.substr(w,3)===ri?(C=ri,w+=3):(C=r,we===0&&ve(ii)),C===r&&(t.substr(w,2)===an?(C=an,w+=2):(C=r,we===0&&ve(yr)),C===r&&(t.charCodeAt(w)===60?(C=Ki,w++):(C=r,we===0&&ve(Qi))))))),C}function uE(){var C,Q,k;for(C=w,Q=[],k=ke();k!==r;)Q.push(k),k=ke();return Q!==r?(k=$M(),k!==r?(Re=C,Q=Ae(k),C=Q):(w=C,C=r)):(w=C,C=r),C}function $M(){var C,Q,k;if(C=w,Q=[],k=eO(),k!==r)for(;k!==r;)Q.push(k),k=eO();else Q=r;return Q!==r&&(Re=C,Q=Go(Q)),C=Q,C}function eO(){var C,Q;return C=w,Q=kfe(),Q!==r&&(Re=C,Q=wr(Q)),C=Q,C===r&&(C=w,Q=Pfe(),Q!==r&&(Re=C,Q=wr(Q)),C=Q,C===r&&(C=w,Q=Dfe(),Q!==r&&(Re=C,Q=wr(Q)),C=Q)),C}function kfe(){var C,Q,k,N;return C=w,t.charCodeAt(w)===39?(Q=Ui,w++):(Q=r,we===0&&ve(ws)),Q!==r?(k=Rfe(),k!==r?(t.charCodeAt(w)===39?(N=Ui,w++):(N=r,we===0&&ve(ws)),N!==r?(Re=C,Q=Tf(k),C=Q):(w=C,C=r)):(w=C,C=r)):(w=C,C=r),C}function Pfe(){var C,Q,k,N;if(C=w,t.charCodeAt(w)===34?(Q=Mf,w++):(Q=r,we===0&&ve(Rm)),Q!==r){for(k=[],N=tO();N!==r;)k.push(N),N=tO();k!==r?(t.charCodeAt(w)===34?(N=Mf,w++):(N=r,we===0&&ve(Rm)),N!==r?(Re=C,Q=Fm(k),C=Q):(w=C,C=r)):(w=C,C=r)}else w=C,C=r;return C}function Dfe(){var C,Q,k;if(C=w,Q=[],k=rO(),k!==r)for(;k!==r;)Q.push(k),k=rO();else Q=r;return Q!==r&&(Re=C,Q=Fm(Q)),C=Q,C}function tO(){var C,Q;return C=w,Q=nO(),Q!==r&&(Re=C,Q=Nm(Q)),C=Q,C===r&&(C=w,Q=sO(),Q!==r&&(Re=C,Q=DQ(Q)),C=Q,C===r&&(C=w,Q=ZQ(),Q!==r&&(Re=C,Q=RQ(Q)),C=Q,C===r&&(C=w,Q=Ffe(),Q!==r&&(Re=C,Q=Of(Q)),C=Q))),C}function rO(){var C,Q;return C=w,Q=nO(),Q!==r&&(Re=C,Q=FQ(Q)),C=Q,C===r&&(C=w,Q=sO(),Q!==r&&(Re=C,Q=NQ(Q)),C=Q,C===r&&(C=w,Q=ZQ(),Q!==r&&(Re=C,Q=Lm(Q)),C=Q,C===r&&(C=w,Q=Lfe(),Q!==r&&(Re=C,Q=LQ(Q)),C=Q,C===r&&(C=w,Q=Nfe(),Q!==r&&(Re=C,Q=Of(Q)),C=Q)))),C}function Rfe(){var C,Q,k,N,Z;for(C=w,Q=[],k=gE(),k===r&&(k=fE(),k===r&&(k=w,t.charCodeAt(w)===92?(N=Va,w++):(N=r,we===0&&ve(jo)),N!==r?(Tm.test(t.charAt(w))?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Mm)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r),k===r&&(Om.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(Km)))));k!==r;)Q.push(k),k=gE(),k===r&&(k=fE(),k===r&&(k=w,t.charCodeAt(w)===92?(N=Va,w++):(N=r,we===0&&ve(jo)),N!==r?(Tm.test(t.charAt(w))?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Mm)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r),k===r&&(Om.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(Km)))));return Q!==r&&(Re=C,Q=il(Q)),C=Q,C}function Ffe(){var C,Q,k,N,Z;if(C=w,Q=[],k=gE(),k===r&&(k=fE(),k===r&&(k=w,t.charCodeAt(w)===92?(N=Va,w++):(N=r,we===0&&ve(jo)),N!==r?(Um.test(t.charAt(w))?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Hm)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r),k===r&&(Kf.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(Gm))))),k!==r)for(;k!==r;)Q.push(k),k=gE(),k===r&&(k=fE(),k===r&&(k=w,t.charCodeAt(w)===92?(N=Va,w++):(N=r,we===0&&ve(jo)),N!==r?(Um.test(t.charAt(w))?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Hm)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r),k===r&&(Kf.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(Gm)))));else Q=r;return Q!==r&&(Re=C,Q=il(Q)),C=Q,C}function gE(){var C,Q;return C=w,t.substr(w,2)===jm?(Q=jm,w+=2):(Q=r,we===0&&ve(TQ)),Q!==r&&(Re=C,Q=MQ()),C=Q,C===r&&(C=w,t.substr(w,2)===Ym?(Q=Ym,w+=2):(Q=r,we===0&&ve(qm)),Q!==r&&(Re=C,Q=Jm()),C=Q,C===r&&(C=w,t.substr(w,2)===Wm?(Q=Wm,w+=2):(Q=r,we===0&&ve(zm)),Q!==r&&(Re=C,Q=Vm()),C=Q,C===r&&(C=w,t.substr(w,2)===Uf?(Q=Uf,w+=2):(Q=r,we===0&&ve(OQ)),Q!==r&&(Re=C,Q=KQ()),C=Q,C===r&&(C=w,t.substr(w,2)===_m?(Q=_m,w+=2):(Q=r,we===0&&ve(UQ)),Q!==r&&(Re=C,Q=HQ()),C=Q,C===r&&(C=w,t.substr(w,2)===O?(Q=O,w+=2):(Q=r,we===0&&ve(ht)),Q!==r&&(Re=C,Q=Vc()),C=Q,C===r&&(C=w,t.substr(w,2)===xn?(Q=xn,w+=2):(Q=r,we===0&&ve(Hf)),Q!==r&&(Re=C,Q=Ye()),C=Q,C===r&&(C=w,t.substr(w,2)===nl?(Q=nl,w+=2):(Q=r,we===0&&ve(Xm)),Q!==r&&(Re=C,Q=MM()),C=Q,C===r&&(C=w,t.substr(w,2)===GQ?(Q=GQ,w+=2):(Q=r,we===0&&ve(OM)),Q!==r&&(Re=C,Q=fr()),C=Q)))))))),C}function fE(){var C,Q,k,N,Z,Ee,ot,ut,Tr,ni,Yn,$Q;return C=w,t.substr(w,2)===Bs?(Q=Bs,w+=2):(Q=r,we===0&&ve(jQ)),Q!==r?(k=w,N=w,Z=An(),Z!==r?(Ee=An(),Ee!==r?(Z=[Z,Ee],N=Z):(w=N,N=r)):(w=N,N=r),N!==r?k=t.substring(k,w):k=N,k!==r?(Re=C,Q=Zm(k),C=Q):(w=C,C=r)):(w=C,C=r),C===r&&(C=w,t.substr(w,2)===Yo?(Q=Yo,w+=2):(Q=r,we===0&&ve($m)),Q!==r?(k=w,N=w,Z=An(),Z!==r?(Ee=An(),Ee!==r?(ot=An(),ot!==r?(ut=An(),ut!==r?(Z=[Z,Ee,ot,ut],N=Z):(w=N,N=r)):(w=N,N=r)):(w=N,N=r)):(w=N,N=r),N!==r?k=t.substring(k,w):k=N,k!==r?(Re=C,Q=Zm(k),C=Q):(w=C,C=r)):(w=C,C=r),C===r&&(C=w,t.substr(w,2)===_a?(Q=_a,w+=2):(Q=r,we===0&&ve(et)),Q!==r?(k=w,N=w,Z=An(),Z!==r?(Ee=An(),Ee!==r?(ot=An(),ot!==r?(ut=An(),ut!==r?(Tr=An(),Tr!==r?(ni=An(),ni!==r?(Yn=An(),Yn!==r?($Q=An(),$Q!==r?(Z=[Z,Ee,ot,ut,Tr,ni,Yn,$Q],N=Z):(w=N,N=r)):(w=N,N=r)):(w=N,N=r)):(w=N,N=r)):(w=N,N=r)):(w=N,N=r)):(w=N,N=r)):(w=N,N=r),N!==r?k=t.substring(k,w):k=N,k!==r?(Re=C,Q=YQ(k),C=Q):(w=C,C=r)):(w=C,C=r))),C}function An(){var C;return eE.test(t.charAt(w))?(C=t.charAt(w),w++):(C=r,we===0&&ve(tE)),C}function Nfe(){var C,Q,k,N,Z;if(C=w,Q=[],k=w,t.charCodeAt(w)===92?(N=Va,w++):(N=r,we===0&&ve(jo)),N!==r?(t.length>w?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Xa)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r),k===r&&(k=w,N=w,we++,Z=aO(),we--,Z===r?N=void 0:(w=N,N=r),N!==r?(t.length>w?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Xa)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r)),k!==r)for(;k!==r;)Q.push(k),k=w,t.charCodeAt(w)===92?(N=Va,w++):(N=r,we===0&&ve(jo)),N!==r?(t.length>w?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Xa)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r),k===r&&(k=w,N=w,we++,Z=aO(),we--,Z===r?N=void 0:(w=N,N=r),N!==r?(t.length>w?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Xa)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r));else Q=r;return Q!==r&&(Re=C,Q=il(Q)),C=Q,C}function _Q(){var C,Q,k,N,Z,Ee;if(C=w,t.charCodeAt(w)===45?(Q=sl,w++):(Q=r,we===0&&ve(ol)),Q===r&&(t.charCodeAt(w)===43?(Q=al,w++):(Q=r,we===0&&ve(qo))),Q===r&&(Q=null),Q!==r){if(k=[],De.test(t.charAt(w))?(N=t.charAt(w),w++):(N=r,we===0&&ve($)),N!==r)for(;N!==r;)k.push(N),De.test(t.charAt(w))?(N=t.charAt(w),w++):(N=r,we===0&&ve($));else k=r;if(k!==r)if(t.charCodeAt(w)===46?(N=Al,w++):(N=r,we===0&&ve(qQ)),N!==r){if(Z=[],De.test(t.charAt(w))?(Ee=t.charAt(w),w++):(Ee=r,we===0&&ve($)),Ee!==r)for(;Ee!==r;)Z.push(Ee),De.test(t.charAt(w))?(Ee=t.charAt(w),w++):(Ee=r,we===0&&ve($));else Z=r;Z!==r?(Re=C,Q=rE(Q,k,Z),C=Q):(w=C,C=r)}else w=C,C=r;else w=C,C=r}else w=C,C=r;if(C===r){if(C=w,t.charCodeAt(w)===45?(Q=sl,w++):(Q=r,we===0&&ve(ol)),Q===r&&(t.charCodeAt(w)===43?(Q=al,w++):(Q=r,we===0&&ve(qo))),Q===r&&(Q=null),Q!==r){if(k=[],De.test(t.charAt(w))?(N=t.charAt(w),w++):(N=r,we===0&&ve($)),N!==r)for(;N!==r;)k.push(N),De.test(t.charAt(w))?(N=t.charAt(w),w++):(N=r,we===0&&ve($));else k=r;k!==r?(Re=C,Q=iE(Q,k),C=Q):(w=C,C=r)}else w=C,C=r;if(C===r&&(C=w,Q=ZQ(),Q!==r&&(Re=C,Q=JQ(Q)),C=Q,C===r&&(C=w,Q=zf(),Q!==r&&(Re=C,Q=ll(Q)),C=Q,C===r)))if(C=w,t.charCodeAt(w)===40?(Q=W,w++):(Q=r,we===0&&ve(X)),Q!==r){for(k=[],N=ke();N!==r;)k.push(N),N=ke();if(k!==r)if(N=iO(),N!==r){for(Z=[],Ee=ke();Ee!==r;)Z.push(Ee),Ee=ke();Z!==r?(t.charCodeAt(w)===41?(Ee=F,w++):(Ee=r,we===0&&ve(D)),Ee!==r?(Re=C,Q=WQ(N),C=Q):(w=C,C=r)):(w=C,C=r)}else w=C,C=r;else w=C,C=r}else w=C,C=r}return C}function XQ(){var C,Q,k,N,Z,Ee,ot,ut;if(C=w,Q=_Q(),Q!==r){for(k=[],N=w,Z=[],Ee=ke();Ee!==r;)Z.push(Ee),Ee=ke();if(Z!==r)if(t.charCodeAt(w)===42?(Ee=nE,w++):(Ee=r,we===0&&ve(Gf)),Ee===r&&(t.charCodeAt(w)===47?(Ee=_c,w++):(Ee=r,we===0&&ve(jf))),Ee!==r){for(ot=[],ut=ke();ut!==r;)ot.push(ut),ut=ke();ot!==r?(ut=_Q(),ut!==r?(Re=N,Z=sE(Q,Ee,ut),N=Z):(w=N,N=r)):(w=N,N=r)}else w=N,N=r;else w=N,N=r;for(;N!==r;){for(k.push(N),N=w,Z=[],Ee=ke();Ee!==r;)Z.push(Ee),Ee=ke();if(Z!==r)if(t.charCodeAt(w)===42?(Ee=nE,w++):(Ee=r,we===0&&ve(Gf)),Ee===r&&(t.charCodeAt(w)===47?(Ee=_c,w++):(Ee=r,we===0&&ve(jf))),Ee!==r){for(ot=[],ut=ke();ut!==r;)ot.push(ut),ut=ke();ot!==r?(ut=_Q(),ut!==r?(Re=N,Z=sE(Q,Ee,ut),N=Z):(w=N,N=r)):(w=N,N=r)}else w=N,N=r;else w=N,N=r}k!==r?(Re=C,Q=cl(Q,k),C=Q):(w=C,C=r)}else w=C,C=r;return C}function iO(){var C,Q,k,N,Z,Ee,ot,ut;if(C=w,Q=XQ(),Q!==r){for(k=[],N=w,Z=[],Ee=ke();Ee!==r;)Z.push(Ee),Ee=ke();if(Z!==r)if(t.charCodeAt(w)===43?(Ee=al,w++):(Ee=r,we===0&&ve(qo)),Ee===r&&(t.charCodeAt(w)===45?(Ee=sl,w++):(Ee=r,we===0&&ve(ol))),Ee!==r){for(ot=[],ut=ke();ut!==r;)ot.push(ut),ut=ke();ot!==r?(ut=XQ(),ut!==r?(Re=N,Z=oE(Q,Ee,ut),N=Z):(w=N,N=r)):(w=N,N=r)}else w=N,N=r;else w=N,N=r;for(;N!==r;){for(k.push(N),N=w,Z=[],Ee=ke();Ee!==r;)Z.push(Ee),Ee=ke();if(Z!==r)if(t.charCodeAt(w)===43?(Ee=al,w++):(Ee=r,we===0&&ve(qo)),Ee===r&&(t.charCodeAt(w)===45?(Ee=sl,w++):(Ee=r,we===0&&ve(ol))),Ee!==r){for(ot=[],ut=ke();ut!==r;)ot.push(ut),ut=ke();ot!==r?(ut=XQ(),ut!==r?(Re=N,Z=oE(Q,Ee,ut),N=Z):(w=N,N=r)):(w=N,N=r)}else w=N,N=r;else w=N,N=r}k!==r?(Re=C,Q=cl(Q,k),C=Q):(w=C,C=r)}else w=C,C=r;return C}function nO(){var C,Q,k,N,Z,Ee;if(C=w,t.substr(w,3)===Yf?(Q=Yf,w+=3):(Q=r,we===0&&ve(Xc)),Q!==r){for(k=[],N=ke();N!==r;)k.push(N),N=ke();if(k!==r)if(N=iO(),N!==r){for(Z=[],Ee=ke();Ee!==r;)Z.push(Ee),Ee=ke();Z!==r?(t.substr(w,2)===xr?(Ee=xr,w+=2):(Ee=r,we===0&&ve(KM)),Ee!==r?(Re=C,Q=Jo(N),C=Q):(w=C,C=r)):(w=C,C=r)}else w=C,C=r;else w=C,C=r}else w=C,C=r;return C}function sO(){var C,Q,k,N;return C=w,t.substr(w,2)===Zs?(Q=Zs,w+=2):(Q=r,we===0&&ve(aE)),Q!==r?(k=Jf(),k!==r?(t.charCodeAt(w)===41?(N=F,w++):(N=r,we===0&&ve(D)),N!==r?(Re=C,Q=Zc(k),C=Q):(w=C,C=r)):(w=C,C=r)):(w=C,C=r),C}function ZQ(){var C,Q,k,N,Z,Ee;return C=w,t.substr(w,2)===x?(Q=x,w+=2):(Q=r,we===0&&ve(U)),Q!==r?(k=zf(),k!==r?(t.substr(w,2)===le?(N=le,w+=2):(N=r,we===0&&ve(xe)),N!==r?(Z=Sfe(),Z!==r?(t.charCodeAt(w)===125?(Ee=Pe,w++):(Ee=r,we===0&&ve(qe)),Ee!==r?(Re=C,Q=Qe(k,Z),C=Q):(w=C,C=r)):(w=C,C=r)):(w=C,C=r)):(w=C,C=r)):(w=C,C=r),C===r&&(C=w,t.substr(w,2)===x?(Q=x,w+=2):(Q=r,we===0&&ve(U)),Q!==r?(k=zf(),k!==r?(t.substr(w,3)===Ge?(N=Ge,w+=3):(N=r,we===0&&ve(ct)),N!==r?(Re=C,Q=sr(k),C=Q):(w=C,C=r)):(w=C,C=r)):(w=C,C=r),C===r&&(C=w,t.substr(w,2)===x?(Q=x,w+=2):(Q=r,we===0&&ve(U)),Q!==r?(k=zf(),k!==r?(t.charCodeAt(w)===125?(N=Pe,w++):(N=r,we===0&&ve(qe)),N!==r?(Re=C,Q=Wo(k),C=Q):(w=C,C=r)):(w=C,C=r)):(w=C,C=r),C===r&&(C=w,t.charCodeAt(w)===36?(Q=Afe,w++):(Q=r,we===0&&ve(lfe)),Q!==r?(k=zf(),k!==r?(Re=C,Q=Wo(k),C=Q):(w=C,C=r)):(w=C,C=r)))),C}function Lfe(){var C,Q,k;return C=w,Q=Tfe(),Q!==r?(Re=w,k=cfe(Q),k?k=void 0:k=r,k!==r?(Re=C,Q=ufe(Q),C=Q):(w=C,C=r)):(w=C,C=r),C}function Tfe(){var C,Q,k,N,Z;if(C=w,Q=[],k=w,N=w,we++,Z=AO(),we--,Z===r?N=void 0:(w=N,N=r),N!==r?(t.length>w?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Xa)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r),k!==r)for(;k!==r;)Q.push(k),k=w,N=w,we++,Z=AO(),we--,Z===r?N=void 0:(w=N,N=r),N!==r?(t.length>w?(Z=t.charAt(w),w++):(Z=r,we===0&&ve(Xa)),Z!==r?(Re=k,N=te(Z),k=N):(w=k,k=r)):(w=k,k=r);else Q=r;return Q!==r&&(Re=C,Q=il(Q)),C=Q,C}function oO(){var C,Q,k;if(C=w,Q=[],UM.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(HM)),k!==r)for(;k!==r;)Q.push(k),UM.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(HM));else Q=r;return Q!==r&&(Re=C,Q=GM()),C=Q,C}function zf(){var C,Q,k;if(C=w,Q=[],jM.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(YM)),k!==r)for(;k!==r;)Q.push(k),jM.test(t.charAt(w))?(k=t.charAt(w),w++):(k=r,we===0&&ve(YM));else Q=r;return Q!==r&&(Re=C,Q=GM()),C=Q,C}function aO(){var C;return gfe.test(t.charAt(w))?(C=t.charAt(w),w++):(C=r,we===0&&ve(ffe)),C}function AO(){var C;return hfe.test(t.charAt(w))?(C=t.charAt(w),w++):(C=r,we===0&&ve(pfe)),C}function ke(){var C,Q;if(C=[],qM.test(t.charAt(w))?(Q=t.charAt(w),w++):(Q=r,we===0&&ve(JM)),Q!==r)for(;Q!==r;)C.push(Q),qM.test(t.charAt(w))?(Q=t.charAt(w),w++):(Q=r,we===0&&ve(JM));else C=r;return C}if(lE=n(),lE!==r&&w===t.length)return lE;throw lE!==r&&w{"use strict";function Eke(t,e){function r(){this.constructor=t}r.prototype=e.prototype,t.prototype=new r}function Xl(t,e,r,i){this.message=t,this.expected=e,this.found=r,this.location=i,this.name="SyntaxError",typeof Error.captureStackTrace=="function"&&Error.captureStackTrace(this,Xl)}Eke(Xl,Error);Xl.buildMessage=function(t,e){var r={literal:function(c){return'"'+n(c.text)+'"'},class:function(c){var u="",g;for(g=0;g0){for(g=1,f=1;gH&&(H=B,L=[]),L.push($))}function qe($,G){return new Xl($,null,null,G)}function re($,G,Ce){return new Xl(Xl.buildMessage($,G),$,G,Ce)}function se(){var $,G,Ce,ee;return $=B,G=be(),G!==r?(t.charCodeAt(B)===47?(Ce=s,B++):(Ce=r,K===0&&Pe(o)),Ce!==r?(ee=be(),ee!==r?(b=$,G=a(G,ee),$=G):(B=$,$=r)):(B=$,$=r)):(B=$,$=r),$===r&&($=B,G=be(),G!==r&&(b=$,G=l(G)),$=G),$}function be(){var $,G,Ce,ee;return $=B,G=ae(),G!==r?(t.charCodeAt(B)===64?(Ce=c,B++):(Ce=r,K===0&&Pe(u)),Ce!==r?(ee=De(),ee!==r?(b=$,G=g(G,ee),$=G):(B=$,$=r)):(B=$,$=r)):(B=$,$=r),$===r&&($=B,G=ae(),G!==r&&(b=$,G=f(G)),$=G),$}function ae(){var $,G,Ce,ee,Ue;return $=B,t.charCodeAt(B)===64?(G=c,B++):(G=r,K===0&&Pe(u)),G!==r?(Ce=Ae(),Ce!==r?(t.charCodeAt(B)===47?(ee=s,B++):(ee=r,K===0&&Pe(o)),ee!==r?(Ue=Ae(),Ue!==r?(b=$,G=h(),$=G):(B=$,$=r)):(B=$,$=r)):(B=$,$=r)):(B=$,$=r),$===r&&($=B,G=Ae(),G!==r&&(b=$,G=h()),$=G),$}function Ae(){var $,G,Ce;if($=B,G=[],p.test(t.charAt(B))?(Ce=t.charAt(B),B++):(Ce=r,K===0&&Pe(d)),Ce!==r)for(;Ce!==r;)G.push(Ce),p.test(t.charAt(B))?(Ce=t.charAt(B),B++):(Ce=r,K===0&&Pe(d));else G=r;return G!==r&&(b=$,G=h()),$=G,$}function De(){var $,G,Ce;if($=B,G=[],m.test(t.charAt(B))?(Ce=t.charAt(B),B++):(Ce=r,K===0&&Pe(I)),Ce!==r)for(;Ce!==r;)G.push(Ce),m.test(t.charAt(B))?(Ce=t.charAt(B),B++):(Ce=r,K===0&&Pe(I));else G=r;return G!==r&&(b=$,G=h()),$=G,$}if(J=n(),J!==r&&B===t.length)return J;throw J!==r&&B{"use strict";function F4(t){return typeof t=="undefined"||t===null}function yke(t){return typeof t=="object"&&t!==null}function wke(t){return Array.isArray(t)?t:F4(t)?[]:[t]}function Bke(t,e){var r,i,n,s;if(e)for(s=Object.keys(e),r=0,i=s.length;r{"use strict";function Lp(t,e){Error.call(this),this.name="YAMLException",this.reason=t,this.mark=e,this.message=(this.reason||"(unknown reason)")+(this.mark?" "+this.mark.toString():""),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}Lp.prototype=Object.create(Error.prototype);Lp.prototype.constructor=Lp;Lp.prototype.toString=function(e){var r=this.name+": ";return r+=this.reason||"(unknown reason)",!e&&this.mark&&(r+=" "+this.mark.toString()),r};N4.exports=Lp});var M4=E((Vot,L4)=>{"use strict";var T4=$l();function kP(t,e,r,i,n){this.name=t,this.buffer=e,this.position=r,this.line=i,this.column=n}kP.prototype.getSnippet=function(e,r){var i,n,s,o,a;if(!this.buffer)return null;for(e=e||4,r=r||75,i="",n=this.position;n>0&&`\0\r -\x85\u2028\u2029`.indexOf(this.buffer.charAt(n-1))===-1;)if(n-=1,this.position-n>r/2-1){i=" ... ",n+=5;break}for(s="",o=this.position;or/2-1){s=" ... ",o-=5;break}return a=this.buffer.slice(n,o),T4.repeat(" ",e)+i+a+s+` -`+T4.repeat(" ",e+this.position-n+i.length)+"^"};kP.prototype.toString=function(e){var r,i="";return this.name&&(i+='in "'+this.name+'" '),i+="at line "+(this.line+1)+", column "+(this.column+1),e||(r=this.getSnippet(),r&&(i+=`: -`+r)),i};L4.exports=kP});var Xr=E((_ot,O4)=>{"use strict";var K4=ng(),vke=["kind","resolve","construct","instanceOf","predicate","represent","defaultStyle","styleAliases"],Ske=["scalar","sequence","mapping"];function xke(t){var e={};return t!==null&&Object.keys(t).forEach(function(r){t[r].forEach(function(i){e[String(i)]=r})}),e}function kke(t,e){if(e=e||{},Object.keys(e).forEach(function(r){if(vke.indexOf(r)===-1)throw new K4('Unknown option "'+r+'" is met in definition of "'+t+'" YAML type.')}),this.tag=t,this.kind=e.kind||null,this.resolve=e.resolve||function(){return!0},this.construct=e.construct||function(r){return r},this.instanceOf=e.instanceOf||null,this.predicate=e.predicate||null,this.represent=e.represent||null,this.defaultStyle=e.defaultStyle||null,this.styleAliases=xke(e.styleAliases||null),Ske.indexOf(this.kind)===-1)throw new K4('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}O4.exports=kke});var ec=E((Xot,U4)=>{"use strict";var H4=$l(),hw=ng(),Pke=Xr();function PP(t,e,r){var i=[];return t.include.forEach(function(n){r=PP(n,e,r)}),t[e].forEach(function(n){r.forEach(function(s,o){s.tag===n.tag&&s.kind===n.kind&&i.push(o)}),r.push(n)}),r.filter(function(n,s){return i.indexOf(s)===-1})}function Dke(){var t={scalar:{},sequence:{},mapping:{},fallback:{}},e,r;function i(n){t[n.kind][n.tag]=t.fallback[n.tag]=n}for(e=0,r=arguments.length;e{"use strict";var Rke=Xr();G4.exports=new Rke("tag:yaml.org,2002:str",{kind:"scalar",construct:function(t){return t!==null?t:""}})});var q4=E(($ot,Y4)=>{"use strict";var Fke=Xr();Y4.exports=new Fke("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(t){return t!==null?t:[]}})});var W4=E((eat,J4)=>{"use strict";var Nke=Xr();J4.exports=new Nke("tag:yaml.org,2002:map",{kind:"mapping",construct:function(t){return t!==null?t:{}}})});var pw=E((tat,z4)=>{"use strict";var Lke=ec();z4.exports=new Lke({explicit:[j4(),q4(),W4()]})});var _4=E((rat,V4)=>{"use strict";var Tke=Xr();function Mke(t){if(t===null)return!0;var e=t.length;return e===1&&t==="~"||e===4&&(t==="null"||t==="Null"||t==="NULL")}function Oke(){return null}function Kke(t){return t===null}V4.exports=new Tke("tag:yaml.org,2002:null",{kind:"scalar",resolve:Mke,construct:Oke,predicate:Kke,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"}},defaultStyle:"lowercase"})});var Z4=E((iat,X4)=>{"use strict";var Uke=Xr();function Hke(t){if(t===null)return!1;var e=t.length;return e===4&&(t==="true"||t==="True"||t==="TRUE")||e===5&&(t==="false"||t==="False"||t==="FALSE")}function Gke(t){return t==="true"||t==="True"||t==="TRUE"}function jke(t){return Object.prototype.toString.call(t)==="[object Boolean]"}X4.exports=new Uke("tag:yaml.org,2002:bool",{kind:"scalar",resolve:Hke,construct:Gke,predicate:jke,represent:{lowercase:function(t){return t?"true":"false"},uppercase:function(t){return t?"TRUE":"FALSE"},camelcase:function(t){return t?"True":"False"}},defaultStyle:"lowercase"})});var ez=E((nat,$4)=>{"use strict";var Yke=$l(),qke=Xr();function Jke(t){return 48<=t&&t<=57||65<=t&&t<=70||97<=t&&t<=102}function Wke(t){return 48<=t&&t<=55}function zke(t){return 48<=t&&t<=57}function Vke(t){if(t===null)return!1;var e=t.length,r=0,i=!1,n;if(!e)return!1;if(n=t[r],(n==="-"||n==="+")&&(n=t[++r]),n==="0"){if(r+1===e)return!0;if(n=t[++r],n==="b"){for(r++;r=0?"0b"+t.toString(2):"-0b"+t.toString(2).slice(1)},octal:function(t){return t>=0?"0"+t.toString(8):"-0"+t.toString(8).slice(1)},decimal:function(t){return t.toString(10)},hexadecimal:function(t){return t>=0?"0x"+t.toString(16).toUpperCase():"-0x"+t.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}})});var iz=E((sat,tz)=>{"use strict";var rz=$l(),Zke=Xr(),$ke=new RegExp("^(?:[-+]?(?:0|[1-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\\.[0-9_]*|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function ePe(t){return!(t===null||!$ke.test(t)||t[t.length-1]==="_")}function tPe(t){var e,r,i,n;return e=t.replace(/_/g,"").toLowerCase(),r=e[0]==="-"?-1:1,n=[],"+-".indexOf(e[0])>=0&&(e=e.slice(1)),e===".inf"?r===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:e===".nan"?NaN:e.indexOf(":")>=0?(e.split(":").forEach(function(s){n.unshift(parseFloat(s,10))}),e=0,i=1,n.forEach(function(s){e+=s*i,i*=60}),r*e):r*parseFloat(e,10)}var rPe=/^[-+]?[0-9]+e/;function iPe(t,e){var r;if(isNaN(t))switch(e){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===t)switch(e){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===t)switch(e){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(rz.isNegativeZero(t))return"-0.0";return r=t.toString(10),rPe.test(r)?r.replace("e",".e"):r}function nPe(t){return Object.prototype.toString.call(t)==="[object Number]"&&(t%1!=0||rz.isNegativeZero(t))}tz.exports=new Zke("tag:yaml.org,2002:float",{kind:"scalar",resolve:ePe,construct:tPe,predicate:nPe,represent:iPe,defaultStyle:"lowercase"})});var DP=E((oat,nz)=>{"use strict";var sPe=ec();nz.exports=new sPe({include:[pw()],implicit:[_4(),Z4(),ez(),iz()]})});var RP=E((aat,sz)=>{"use strict";var oPe=ec();sz.exports=new oPe({include:[DP()]})});var lz=E((Aat,oz)=>{"use strict";var aPe=Xr(),az=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),Az=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function APe(t){return t===null?!1:az.exec(t)!==null||Az.exec(t)!==null}function lPe(t){var e,r,i,n,s,o,a,l=0,c=null,u,g,f;if(e=az.exec(t),e===null&&(e=Az.exec(t)),e===null)throw new Error("Date resolve error");if(r=+e[1],i=+e[2]-1,n=+e[3],!e[4])return new Date(Date.UTC(r,i,n));if(s=+e[4],o=+e[5],a=+e[6],e[7]){for(l=e[7].slice(0,3);l.length<3;)l+="0";l=+l}return e[9]&&(u=+e[10],g=+(e[11]||0),c=(u*60+g)*6e4,e[9]==="-"&&(c=-c)),f=new Date(Date.UTC(r,i,n,s,o,a,l)),c&&f.setTime(f.getTime()-c),f}function cPe(t){return t.toISOString()}oz.exports=new aPe("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:APe,construct:lPe,instanceOf:Date,represent:cPe})});var uz=E((lat,cz)=>{"use strict";var uPe=Xr();function gPe(t){return t==="<<"||t===null}cz.exports=new uPe("tag:yaml.org,2002:merge",{kind:"scalar",resolve:gPe})});var hz=E((cat,gz)=>{"use strict";var tc;try{fz=require,tc=fz("buffer").Buffer}catch(t){}var fz,fPe=Xr(),FP=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/= -\r`;function hPe(t){if(t===null)return!1;var e,r,i=0,n=t.length,s=FP;for(r=0;r64)){if(e<0)return!1;i+=6}return i%8==0}function pPe(t){var e,r,i=t.replace(/[\r\n=]/g,""),n=i.length,s=FP,o=0,a=[];for(e=0;e>16&255),a.push(o>>8&255),a.push(o&255)),o=o<<6|s.indexOf(i.charAt(e));return r=n%4*6,r===0?(a.push(o>>16&255),a.push(o>>8&255),a.push(o&255)):r===18?(a.push(o>>10&255),a.push(o>>2&255)):r===12&&a.push(o>>4&255),tc?tc.from?tc.from(a):new tc(a):a}function dPe(t){var e="",r=0,i,n,s=t.length,o=FP;for(i=0;i>18&63],e+=o[r>>12&63],e+=o[r>>6&63],e+=o[r&63]),r=(r<<8)+t[i];return n=s%3,n===0?(e+=o[r>>18&63],e+=o[r>>12&63],e+=o[r>>6&63],e+=o[r&63]):n===2?(e+=o[r>>10&63],e+=o[r>>4&63],e+=o[r<<2&63],e+=o[64]):n===1&&(e+=o[r>>2&63],e+=o[r<<4&63],e+=o[64],e+=o[64]),e}function CPe(t){return tc&&tc.isBuffer(t)}gz.exports=new fPe("tag:yaml.org,2002:binary",{kind:"scalar",resolve:hPe,construct:pPe,predicate:CPe,represent:dPe})});var dz=E((uat,pz)=>{"use strict";var mPe=Xr(),EPe=Object.prototype.hasOwnProperty,IPe=Object.prototype.toString;function yPe(t){if(t===null)return!0;var e=[],r,i,n,s,o,a=t;for(r=0,i=a.length;r{"use strict";var BPe=Xr(),QPe=Object.prototype.toString;function bPe(t){if(t===null)return!0;var e,r,i,n,s,o=t;for(s=new Array(o.length),e=0,r=o.length;e{"use strict";var SPe=Xr(),xPe=Object.prototype.hasOwnProperty;function kPe(t){if(t===null)return!0;var e,r=t;for(e in r)if(xPe.call(r,e)&&r[e]!==null)return!1;return!0}function PPe(t){return t!==null?t:{}}Ez.exports=new SPe("tag:yaml.org,2002:set",{kind:"mapping",resolve:kPe,construct:PPe})});var og=E((hat,yz)=>{"use strict";var DPe=ec();yz.exports=new DPe({include:[RP()],implicit:[lz(),uz()],explicit:[hz(),dz(),mz(),Iz()]})});var Bz=E((pat,wz)=>{"use strict";var RPe=Xr();function FPe(){return!0}function NPe(){}function LPe(){return""}function TPe(t){return typeof t=="undefined"}wz.exports=new RPe("tag:yaml.org,2002:js/undefined",{kind:"scalar",resolve:FPe,construct:NPe,predicate:TPe,represent:LPe})});var bz=E((dat,Qz)=>{"use strict";var MPe=Xr();function OPe(t){if(t===null||t.length===0)return!1;var e=t,r=/\/([gim]*)$/.exec(t),i="";return!(e[0]==="/"&&(r&&(i=r[1]),i.length>3||e[e.length-i.length-1]!=="/"))}function KPe(t){var e=t,r=/\/([gim]*)$/.exec(t),i="";return e[0]==="/"&&(r&&(i=r[1]),e=e.slice(1,e.length-i.length-1)),new RegExp(e,i)}function UPe(t){var e="/"+t.source+"/";return t.global&&(e+="g"),t.multiline&&(e+="m"),t.ignoreCase&&(e+="i"),e}function HPe(t){return Object.prototype.toString.call(t)==="[object RegExp]"}Qz.exports=new MPe("tag:yaml.org,2002:js/regexp",{kind:"scalar",resolve:OPe,construct:KPe,predicate:HPe,represent:UPe})});var xz=E((Cat,vz)=>{"use strict";var dw;try{Sz=require,dw=Sz("esprima")}catch(t){typeof window!="undefined"&&(dw=window.esprima)}var Sz,GPe=Xr();function jPe(t){if(t===null)return!1;try{var e="("+t+")",r=dw.parse(e,{range:!0});return!(r.type!=="Program"||r.body.length!==1||r.body[0].type!=="ExpressionStatement"||r.body[0].expression.type!=="ArrowFunctionExpression"&&r.body[0].expression.type!=="FunctionExpression")}catch(i){return!1}}function YPe(t){var e="("+t+")",r=dw.parse(e,{range:!0}),i=[],n;if(r.type!=="Program"||r.body.length!==1||r.body[0].type!=="ExpressionStatement"||r.body[0].expression.type!=="ArrowFunctionExpression"&&r.body[0].expression.type!=="FunctionExpression")throw new Error("Failed to resolve function");return r.body[0].expression.params.forEach(function(s){i.push(s.name)}),n=r.body[0].expression.body.range,r.body[0].expression.body.type==="BlockStatement"?new Function(i,e.slice(n[0]+1,n[1]-1)):new Function(i,"return "+e.slice(n[0],n[1]))}function qPe(t){return t.toString()}function JPe(t){return Object.prototype.toString.call(t)==="[object Function]"}vz.exports=new GPe("tag:yaml.org,2002:js/function",{kind:"scalar",resolve:jPe,construct:YPe,predicate:JPe,represent:qPe})});var Tp=E((mat,kz)=>{"use strict";var Pz=ec();kz.exports=Pz.DEFAULT=new Pz({include:[og()],explicit:[Bz(),bz(),xz()]})});var Vz=E((Eat,Mp)=>{"use strict";var Ba=$l(),Dz=ng(),WPe=M4(),Rz=og(),zPe=Tp(),QA=Object.prototype.hasOwnProperty,Cw=1,Fz=2,Nz=3,mw=4,NP=1,VPe=2,Lz=3,_Pe=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,XPe=/[\x85\u2028\u2029]/,ZPe=/[,\[\]\{\}]/,Tz=/^(?:!|!!|![a-z\-]+!)$/i,Mz=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function Oz(t){return Object.prototype.toString.call(t)}function wo(t){return t===10||t===13}function rc(t){return t===9||t===32}function yn(t){return t===9||t===32||t===10||t===13}function ag(t){return t===44||t===91||t===93||t===123||t===125}function $Pe(t){var e;return 48<=t&&t<=57?t-48:(e=t|32,97<=e&&e<=102?e-97+10:-1)}function eDe(t){return t===120?2:t===117?4:t===85?8:0}function tDe(t){return 48<=t&&t<=57?t-48:-1}function Kz(t){return t===48?"\0":t===97?"\x07":t===98?"\b":t===116||t===9?" ":t===110?` -`:t===118?"\v":t===102?"\f":t===114?"\r":t===101?"":t===32?" ":t===34?'"':t===47?"/":t===92?"\\":t===78?"\x85":t===95?"\xA0":t===76?"\u2028":t===80?"\u2029":""}function rDe(t){return t<=65535?String.fromCharCode(t):String.fromCharCode((t-65536>>10)+55296,(t-65536&1023)+56320)}var Uz=new Array(256),Hz=new Array(256);for(var Ag=0;Ag<256;Ag++)Uz[Ag]=Kz(Ag)?1:0,Hz[Ag]=Kz(Ag);function iDe(t,e){this.input=t,this.filename=e.filename||null,this.schema=e.schema||zPe,this.onWarning=e.onWarning||null,this.legacy=e.legacy||!1,this.json=e.json||!1,this.listener=e.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=t.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.documents=[]}function Gz(t,e){return new Dz(e,new WPe(t.filename,t.input,t.position,t.line,t.position-t.lineStart))}function st(t,e){throw Gz(t,e)}function Ew(t,e){t.onWarning&&t.onWarning.call(null,Gz(t,e))}var jz={YAML:function(e,r,i){var n,s,o;e.version!==null&&st(e,"duplication of %YAML directive"),i.length!==1&&st(e,"YAML directive accepts exactly one argument"),n=/^([0-9]+)\.([0-9]+)$/.exec(i[0]),n===null&&st(e,"ill-formed argument of the YAML directive"),s=parseInt(n[1],10),o=parseInt(n[2],10),s!==1&&st(e,"unacceptable YAML version of the document"),e.version=i[0],e.checkLineBreaks=o<2,o!==1&&o!==2&&Ew(e,"unsupported YAML version of the document")},TAG:function(e,r,i){var n,s;i.length!==2&&st(e,"TAG directive accepts exactly two arguments"),n=i[0],s=i[1],Tz.test(n)||st(e,"ill-formed tag handle (first argument) of the TAG directive"),QA.call(e.tagMap,n)&&st(e,'there is a previously declared suffix for "'+n+'" tag handle'),Mz.test(s)||st(e,"ill-formed tag prefix (second argument) of the TAG directive"),e.tagMap[n]=s}};function bA(t,e,r,i){var n,s,o,a;if(e1&&(t.result+=Ba.repeat(` -`,e-1))}function nDe(t,e,r){var i,n,s,o,a,l,c,u,g=t.kind,f=t.result,h;if(h=t.input.charCodeAt(t.position),yn(h)||ag(h)||h===35||h===38||h===42||h===33||h===124||h===62||h===39||h===34||h===37||h===64||h===96||(h===63||h===45)&&(n=t.input.charCodeAt(t.position+1),yn(n)||r&&ag(n)))return!1;for(t.kind="scalar",t.result="",s=o=t.position,a=!1;h!==0;){if(h===58){if(n=t.input.charCodeAt(t.position+1),yn(n)||r&&ag(n))break}else if(h===35){if(i=t.input.charCodeAt(t.position-1),yn(i))break}else{if(t.position===t.lineStart&&Iw(t)||r&&ag(h))break;if(wo(h))if(l=t.line,c=t.lineStart,u=t.lineIndent,jr(t,!1,-1),t.lineIndent>=e){a=!0,h=t.input.charCodeAt(t.position);continue}else{t.position=o,t.line=l,t.lineStart=c,t.lineIndent=u;break}}a&&(bA(t,s,o,!1),TP(t,t.line-l),s=o=t.position,a=!1),rc(h)||(o=t.position+1),h=t.input.charCodeAt(++t.position)}return bA(t,s,o,!1),t.result?!0:(t.kind=g,t.result=f,!1)}function sDe(t,e){var r,i,n;if(r=t.input.charCodeAt(t.position),r!==39)return!1;for(t.kind="scalar",t.result="",t.position++,i=n=t.position;(r=t.input.charCodeAt(t.position))!==0;)if(r===39)if(bA(t,i,t.position,!0),r=t.input.charCodeAt(++t.position),r===39)i=t.position,t.position++,n=t.position;else return!0;else wo(r)?(bA(t,i,n,!0),TP(t,jr(t,!1,e)),i=n=t.position):t.position===t.lineStart&&Iw(t)?st(t,"unexpected end of the document within a single quoted scalar"):(t.position++,n=t.position);st(t,"unexpected end of the stream within a single quoted scalar")}function oDe(t,e){var r,i,n,s,o,a;if(a=t.input.charCodeAt(t.position),a!==34)return!1;for(t.kind="scalar",t.result="",t.position++,r=i=t.position;(a=t.input.charCodeAt(t.position))!==0;){if(a===34)return bA(t,r,t.position,!0),t.position++,!0;if(a===92){if(bA(t,r,t.position,!0),a=t.input.charCodeAt(++t.position),wo(a))jr(t,!1,e);else if(a<256&&Uz[a])t.result+=Hz[a],t.position++;else if((o=eDe(a))>0){for(n=o,s=0;n>0;n--)a=t.input.charCodeAt(++t.position),(o=$Pe(a))>=0?s=(s<<4)+o:st(t,"expected hexadecimal character");t.result+=rDe(s),t.position++}else st(t,"unknown escape sequence");r=i=t.position}else wo(a)?(bA(t,r,i,!0),TP(t,jr(t,!1,e)),r=i=t.position):t.position===t.lineStart&&Iw(t)?st(t,"unexpected end of the document within a double quoted scalar"):(t.position++,i=t.position)}st(t,"unexpected end of the stream within a double quoted scalar")}function aDe(t,e){var r=!0,i,n=t.tag,s,o=t.anchor,a,l,c,u,g,f={},h,p,d,m;if(m=t.input.charCodeAt(t.position),m===91)l=93,g=!1,s=[];else if(m===123)l=125,g=!0,s={};else return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=s),m=t.input.charCodeAt(++t.position);m!==0;){if(jr(t,!0,e),m=t.input.charCodeAt(t.position),m===l)return t.position++,t.tag=n,t.anchor=o,t.kind=g?"mapping":"sequence",t.result=s,!0;r||st(t,"missed comma between flow collection entries"),p=h=d=null,c=u=!1,m===63&&(a=t.input.charCodeAt(t.position+1),yn(a)&&(c=u=!0,t.position++,jr(t,!0,e))),i=t.line,cg(t,e,Cw,!1,!0),p=t.tag,h=t.result,jr(t,!0,e),m=t.input.charCodeAt(t.position),(u||t.line===i)&&m===58&&(c=!0,m=t.input.charCodeAt(++t.position),jr(t,!0,e),cg(t,e,Cw,!1,!0),d=t.result),g?lg(t,s,f,p,h,d):c?s.push(lg(t,null,f,p,h,d)):s.push(h),jr(t,!0,e),m=t.input.charCodeAt(t.position),m===44?(r=!0,m=t.input.charCodeAt(++t.position)):r=!1}st(t,"unexpected end of the stream within a flow collection")}function ADe(t,e){var r,i,n=NP,s=!1,o=!1,a=e,l=0,c=!1,u,g;if(g=t.input.charCodeAt(t.position),g===124)i=!1;else if(g===62)i=!0;else return!1;for(t.kind="scalar",t.result="";g!==0;)if(g=t.input.charCodeAt(++t.position),g===43||g===45)NP===n?n=g===43?Lz:VPe:st(t,"repeat of a chomping mode identifier");else if((u=tDe(g))>=0)u===0?st(t,"bad explicit indentation width of a block scalar; it cannot be less than one"):o?st(t,"repeat of an indentation width identifier"):(a=e+u-1,o=!0);else break;if(rc(g)){do g=t.input.charCodeAt(++t.position);while(rc(g));if(g===35)do g=t.input.charCodeAt(++t.position);while(!wo(g)&&g!==0)}for(;g!==0;){for(LP(t),t.lineIndent=0,g=t.input.charCodeAt(t.position);(!o||t.lineIndenta&&(a=t.lineIndent),wo(g)){l++;continue}if(t.lineIndente)&&l!==0)st(t,"bad indentation of a sequence entry");else if(t.lineIndente)&&(cg(t,e,mw,!0,n)&&(p?f=t.result:h=t.result),p||(lg(t,c,u,g,f,h,s,o),g=f=h=null),jr(t,!0,-1),m=t.input.charCodeAt(t.position)),t.lineIndent>e&&m!==0)st(t,"bad indentation of a mapping entry");else if(t.lineIndente?l=1:t.lineIndent===e?l=0:t.lineIndente?l=1:t.lineIndent===e?l=0:t.lineIndent tag; it should be "scalar", not "'+t.kind+'"'),g=0,f=t.implicitTypes.length;g tag; it should be "'+h.kind+'", not "'+t.kind+'"'),h.resolve(t.result)?(t.result=h.construct(t.result),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):st(t,"cannot resolve a node with !<"+t.tag+"> explicit tag")):st(t,"unknown tag !<"+t.tag+">");return t.listener!==null&&t.listener("close",t),t.tag!==null||t.anchor!==null||u}function fDe(t){var e=t.position,r,i,n,s=!1,o;for(t.version=null,t.checkLineBreaks=t.legacy,t.tagMap={},t.anchorMap={};(o=t.input.charCodeAt(t.position))!==0&&(jr(t,!0,-1),o=t.input.charCodeAt(t.position),!(t.lineIndent>0||o!==37));){for(s=!0,o=t.input.charCodeAt(++t.position),r=t.position;o!==0&&!yn(o);)o=t.input.charCodeAt(++t.position);for(i=t.input.slice(r,t.position),n=[],i.length<1&&st(t,"directive name must not be less than one character in length");o!==0;){for(;rc(o);)o=t.input.charCodeAt(++t.position);if(o===35){do o=t.input.charCodeAt(++t.position);while(o!==0&&!wo(o));break}if(wo(o))break;for(r=t.position;o!==0&&!yn(o);)o=t.input.charCodeAt(++t.position);n.push(t.input.slice(r,t.position))}o!==0&&LP(t),QA.call(jz,i)?jz[i](t,i,n):Ew(t,'unknown document directive "'+i+'"')}if(jr(t,!0,-1),t.lineIndent===0&&t.input.charCodeAt(t.position)===45&&t.input.charCodeAt(t.position+1)===45&&t.input.charCodeAt(t.position+2)===45?(t.position+=3,jr(t,!0,-1)):s&&st(t,"directives end mark is expected"),cg(t,t.lineIndent-1,mw,!1,!0),jr(t,!0,-1),t.checkLineBreaks&&XPe.test(t.input.slice(e,t.position))&&Ew(t,"non-ASCII line breaks are interpreted as content"),t.documents.push(t.result),t.position===t.lineStart&&Iw(t)){t.input.charCodeAt(t.position)===46&&(t.position+=3,jr(t,!0,-1));return}if(t.position{"use strict";var Op=$l(),Kp=ng(),dDe=Tp(),CDe=og(),_z=Object.prototype.toString,Xz=Object.prototype.hasOwnProperty,mDe=9,Up=10,EDe=13,IDe=32,yDe=33,wDe=34,Zz=35,BDe=37,QDe=38,bDe=39,vDe=42,$z=44,SDe=45,e5=58,xDe=61,kDe=62,PDe=63,DDe=64,t5=91,r5=93,RDe=96,i5=123,FDe=124,n5=125,Ri={};Ri[0]="\\0";Ri[7]="\\a";Ri[8]="\\b";Ri[9]="\\t";Ri[10]="\\n";Ri[11]="\\v";Ri[12]="\\f";Ri[13]="\\r";Ri[27]="\\e";Ri[34]='\\"';Ri[92]="\\\\";Ri[133]="\\N";Ri[160]="\\_";Ri[8232]="\\L";Ri[8233]="\\P";var NDe=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"];function LDe(t,e){var r,i,n,s,o,a,l;if(e===null)return{};for(r={},i=Object.keys(e),n=0,s=i.length;n0?t.charCodeAt(s-1):null,f=f&&a5(o,a)}else{for(s=0;si&&t[g+1]!==" ",g=s);else if(!ug(o))return yw;a=s>0?t.charCodeAt(s-1):null,f=f&&a5(o,a)}c=c||u&&s-g-1>i&&t[g+1]!==" "}return!l&&!c?f&&!n(t)?l5:c5:r>9&&A5(t)?yw:c?g5:u5}function jDe(t,e,r,i){t.dump=function(){if(e.length===0)return"''";if(!t.noCompatMode&&NDe.indexOf(e)!==-1)return"'"+e+"'";var n=t.indent*Math.max(1,r),s=t.lineWidth===-1?-1:Math.max(Math.min(t.lineWidth,40),t.lineWidth-n),o=i||t.flowLevel>-1&&r>=t.flowLevel;function a(l){return MDe(t,l)}switch(UDe(e,o,t.indent,s,a)){case l5:return e;case c5:return"'"+e.replace(/'/g,"''")+"'";case u5:return"|"+f5(e,t.indent)+h5(o5(e,n));case g5:return">"+f5(e,t.indent)+h5(o5(HDe(e,s),n));case yw:return'"'+GDe(e,s)+'"';default:throw new Kp("impossible error: invalid scalar style")}}()}function f5(t,e){var r=A5(t)?String(e):"",i=t[t.length-1]===` -`,n=i&&(t[t.length-2]===` -`||t===` -`),s=n?"+":i?"":"-";return r+s+` -`}function h5(t){return t[t.length-1]===` -`?t.slice(0,-1):t}function HDe(t,e){for(var r=/(\n+)([^\n]*)/g,i=function(){var c=t.indexOf(` -`);return c=c!==-1?c:t.length,r.lastIndex=c,p5(t.slice(0,c),e)}(),n=t[0]===` -`||t[0]===" ",s,o;o=r.exec(t);){var a=o[1],l=o[2];s=l[0]===" ",i+=a+(!n&&!s&&l!==""?` -`:"")+p5(l,e),n=s}return i}function p5(t,e){if(t===""||t[0]===" ")return t;for(var r=/ [^ ]/g,i,n=0,s,o=0,a=0,l="";i=r.exec(t);)a=i.index,a-n>e&&(s=o>n?o:a,l+=` -`+t.slice(n,s),n=s+1),o=a;return l+=` -`,t.length-n>e&&o>n?l+=t.slice(n,o)+` -`+t.slice(o+1):l+=t.slice(n),l.slice(1)}function GDe(t){for(var e="",r,i,n,s=0;s=55296&&r<=56319&&(i=t.charCodeAt(s+1),i>=56320&&i<=57343)){e+=s5((r-55296)*1024+i-56320+65536),s++;continue}n=Ri[r],e+=!n&&ug(r)?t[s]:n||s5(r)}return e}function YDe(t,e,r){var i="",n=t.tag,s,o;for(s=0,o=r.length;s1024&&(u+="? "),u+=t.dump+(t.condenseFlow?'"':"")+":"+(t.condenseFlow?"":" "),!!ic(t,e,c,!1,!1)&&(u+=t.dump,i+=u));t.tag=n,t.dump="{"+i+"}"}function WDe(t,e,r,i){var n="",s=t.tag,o=Object.keys(r),a,l,c,u,g,f;if(t.sortKeys===!0)o.sort();else if(typeof t.sortKeys=="function")o.sort(t.sortKeys);else if(t.sortKeys)throw new Kp("sortKeys must be a boolean or a function");for(a=0,l=o.length;a1024,g&&(t.dump&&Up===t.dump.charCodeAt(0)?f+="?":f+="? "),f+=t.dump,g&&(f+=OP(t,e)),!!ic(t,e+1,u,!0,g)&&(t.dump&&Up===t.dump.charCodeAt(0)?f+=":":f+=": ",f+=t.dump,n+=f));t.tag=s,t.dump=n||"{}"}function d5(t,e,r){var i,n,s,o,a,l;for(n=r?t.explicitTypes:t.implicitTypes,s=0,o=n.length;s tag resolver accepts not "'+l+'" style');t.dump=i}return!0}return!1}function ic(t,e,r,i,n,s){t.tag=null,t.dump=r,d5(t,r,!1)||d5(t,r,!0);var o=_z.call(t.dump);i&&(i=t.flowLevel<0||t.flowLevel>e);var a=o==="[object Object]"||o==="[object Array]",l,c;if(a&&(l=t.duplicates.indexOf(r),c=l!==-1),(t.tag!==null&&t.tag!=="?"||c||t.indent!==2&&e>0)&&(n=!1),c&&t.usedDuplicates[l])t.dump="*ref_"+l;else{if(a&&c&&!t.usedDuplicates[l]&&(t.usedDuplicates[l]=!0),o==="[object Object]")i&&Object.keys(t.dump).length!==0?(WDe(t,e,t.dump,n),c&&(t.dump="&ref_"+l+t.dump)):(JDe(t,e,t.dump),c&&(t.dump="&ref_"+l+" "+t.dump));else if(o==="[object Array]"){var u=t.noArrayIndent&&e>0?e-1:e;i&&t.dump.length!==0?(qDe(t,u,t.dump,n),c&&(t.dump="&ref_"+l+t.dump)):(YDe(t,u,t.dump),c&&(t.dump="&ref_"+l+" "+t.dump))}else if(o==="[object String]")t.tag!=="?"&&jDe(t,t.dump,e,s);else{if(t.skipInvalid)return!1;throw new Kp("unacceptable kind of an object to dump "+o)}t.tag!==null&&t.tag!=="?"&&(t.dump="!<"+t.tag+"> "+t.dump)}return!0}function zDe(t,e){var r=[],i=[],n,s;for(UP(t,r,i),n=0,s=i.length;n{"use strict";var ww=Vz(),E5=m5();function Bw(t){return function(){throw new Error("Function "+t+" is deprecated and cannot be used.")}}Qr.exports.Type=Xr();Qr.exports.Schema=ec();Qr.exports.FAILSAFE_SCHEMA=pw();Qr.exports.JSON_SCHEMA=DP();Qr.exports.CORE_SCHEMA=RP();Qr.exports.DEFAULT_SAFE_SCHEMA=og();Qr.exports.DEFAULT_FULL_SCHEMA=Tp();Qr.exports.load=ww.load;Qr.exports.loadAll=ww.loadAll;Qr.exports.safeLoad=ww.safeLoad;Qr.exports.safeLoadAll=ww.safeLoadAll;Qr.exports.dump=E5.dump;Qr.exports.safeDump=E5.safeDump;Qr.exports.YAMLException=ng();Qr.exports.MINIMAL_SCHEMA=pw();Qr.exports.SAFE_SCHEMA=og();Qr.exports.DEFAULT_SCHEMA=Tp();Qr.exports.scan=Bw("scan");Qr.exports.parse=Bw("parse");Qr.exports.compose=Bw("compose");Qr.exports.addConstructor=Bw("addConstructor")});var w5=E((wat,y5)=>{"use strict";var _De=I5();y5.exports=_De});var Q5=E((Bat,B5)=>{"use strict";function XDe(t,e){function r(){this.constructor=t}r.prototype=e.prototype,t.prototype=new r}function nc(t,e,r,i){this.message=t,this.expected=e,this.found=r,this.location=i,this.name="SyntaxError",typeof Error.captureStackTrace=="function"&&Error.captureStackTrace(this,nc)}XDe(nc,Error);nc.buildMessage=function(t,e){var r={literal:function(c){return'"'+n(c.text)+'"'},class:function(c){var u="",g;for(g=0;g0){for(g=1,f=1;g({[xe]:le})))},H=function(x){return x},L=function(x){return x},K=Yo("correct indentation"),J=" ",ne=fr(" ",!1),q=function(x){return x.length===Zc*aE},A=function(x){return x.length===(Zc+1)*aE},V=function(){return Zc++,!0},W=function(){return Zc--,!0},X=function(){return Xm()},F=Yo("pseudostring"),D=/^[^\r\n\t ?:,\][{}#&*!|>'"%@`\-]/,he=Bs(["\r",` -`," "," ","?",":",",","]","[","{","}","#","&","*","!","|",">","'",'"',"%","@","`","-"],!0,!1),pe=/^[^\r\n\t ,\][{}:#"']/,Ne=Bs(["\r",` -`," "," ",",","]","[","{","}",":","#",'"',"'"],!0,!1),Pe=function(){return Xm().replace(/^ *| *$/g,"")},qe="--",re=fr("--",!1),se=/^[a-zA-Z\/0-9]/,be=Bs([["a","z"],["A","Z"],"/",["0","9"]],!1,!1),ae=/^[^\r\n\t :,]/,Ae=Bs(["\r",` -`," "," ",":",","],!0,!1),De="null",$=fr("null",!1),G=function(){return null},Ce="true",ee=fr("true",!1),Ue=function(){return!0},Oe="false",vt=fr("false",!1),dt=function(){return!1},ri=Yo("string"),ii='"',an=fr('"',!1),yr=function(){return""},Ki=function(x){return x},Qi=function(x){return x.join("")},Go=/^[^"\\\0-\x1F\x7F]/,wr=Bs(['"',"\\",["\0",""],"\x7F"],!0,!1),Ui='\\"',ws=fr('\\"',!1),Tf=function(){return'"'},Mf="\\\\",Rm=fr("\\\\",!1),Fm=function(){return"\\"},Nm="\\/",DQ=fr("\\/",!1),RQ=function(){return"/"},Of="\\b",FQ=fr("\\b",!1),NQ=function(){return"\b"},Lm="\\f",LQ=fr("\\f",!1),Va=function(){return"\f"},jo="\\n",Tm=fr("\\n",!1),Mm=function(){return` -`},te="\\r",Om=fr("\\r",!1),Km=function(){return"\r"},il="\\t",Um=fr("\\t",!1),Hm=function(){return" "},Kf="\\u",Gm=fr("\\u",!1),jm=function(x,U,le,xe){return String.fromCharCode(parseInt(`0x${x}${U}${le}${xe}`))},TQ=/^[0-9a-fA-F]/,MQ=Bs([["0","9"],["a","f"],["A","F"]],!1,!1),Ym=Yo("blank space"),qm=/^[ \t]/,Jm=Bs([" "," "],!1,!1),Wm=Yo("white space"),zm=/^[ \t\n\r]/,Vm=Bs([" "," ",` -`,"\r"],!1,!1),Uf=`\r -`,OQ=fr(`\r -`,!1),KQ=` -`,_m=fr(` -`,!1),UQ="\r",HQ=fr("\r",!1),O=0,ht=0,Vc=[{line:1,column:1}],xn=0,Hf=[],Ye=0,nl;if("startRule"in e){if(!(e.startRule in i))throw new Error(`Can't start parsing from rule "`+e.startRule+'".');n=i[e.startRule]}function Xm(){return t.substring(ht,O)}function MM(){return _a(ht,O)}function GQ(x,U){throw U=U!==void 0?U:_a(ht,O),eE([Yo(x)],t.substring(ht,O),U)}function OM(x,U){throw U=U!==void 0?U:_a(ht,O),YQ(x,U)}function fr(x,U){return{type:"literal",text:x,ignoreCase:U}}function Bs(x,U,le){return{type:"class",parts:x,inverted:U,ignoreCase:le}}function jQ(){return{type:"any"}}function Zm(){return{type:"end"}}function Yo(x){return{type:"other",description:x}}function $m(x){var U=Vc[x],le;if(U)return U;for(le=x-1;!Vc[le];)le--;for(U=Vc[le],U={line:U.line,column:U.column};lexn&&(xn=O,Hf=[]),Hf.push(x))}function YQ(x,U){return new nc(x,null,null,U)}function eE(x,U,le){return new nc(nc.buildMessage(x,U),x,U,le)}function tE(){var x;return x=ol(),x}function Xa(){var x,U,le;for(x=O,U=[],le=sl();le!==r;)U.push(le),le=sl();return U!==r&&(ht=x,U=s(U)),x=U,x}function sl(){var x,U,le,xe,Qe;return x=O,U=Al(),U!==r?(t.charCodeAt(O)===45?(le=o,O++):(le=r,Ye===0&&et(a)),le!==r?(xe=xr(),xe!==r?(Qe=qo(),Qe!==r?(ht=x,U=l(Qe),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r),x}function ol(){var x,U,le;for(x=O,U=[],le=al();le!==r;)U.push(le),le=al();return U!==r&&(ht=x,U=c(U)),x=U,x}function al(){var x,U,le,xe,Qe,Ge,ct,sr,Wo;if(x=O,U=xr(),U===r&&(U=null),U!==r){if(le=O,t.charCodeAt(O)===35?(xe=u,O++):(xe=r,Ye===0&&et(g)),xe!==r){if(Qe=[],Ge=O,ct=O,Ye++,sr=Zs(),Ye--,sr===r?ct=void 0:(O=ct,ct=r),ct!==r?(t.length>O?(sr=t.charAt(O),O++):(sr=r,Ye===0&&et(f)),sr!==r?(ct=[ct,sr],Ge=ct):(O=Ge,Ge=r)):(O=Ge,Ge=r),Ge!==r)for(;Ge!==r;)Qe.push(Ge),Ge=O,ct=O,Ye++,sr=Zs(),Ye--,sr===r?ct=void 0:(O=ct,ct=r),ct!==r?(t.length>O?(sr=t.charAt(O),O++):(sr=r,Ye===0&&et(f)),sr!==r?(ct=[ct,sr],Ge=ct):(O=Ge,Ge=r)):(O=Ge,Ge=r);else Qe=r;Qe!==r?(xe=[xe,Qe],le=xe):(O=le,le=r)}else O=le,le=r;if(le===r&&(le=null),le!==r){if(xe=[],Qe=Jo(),Qe!==r)for(;Qe!==r;)xe.push(Qe),Qe=Jo();else xe=r;xe!==r?(ht=x,U=h(),x=U):(O=x,x=r)}else O=x,x=r}else O=x,x=r;if(x===r&&(x=O,U=Al(),U!==r?(le=JQ(),le!==r?(xe=xr(),xe===r&&(xe=null),xe!==r?(t.charCodeAt(O)===58?(Qe=p,O++):(Qe=r,Ye===0&&et(d)),Qe!==r?(Ge=xr(),Ge===r&&(Ge=null),Ge!==r?(ct=qo(),ct!==r?(ht=x,U=m(le,ct),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r),x===r&&(x=O,U=Al(),U!==r?(le=ll(),le!==r?(xe=xr(),xe===r&&(xe=null),xe!==r?(t.charCodeAt(O)===58?(Qe=p,O++):(Qe=r,Ye===0&&et(d)),Qe!==r?(Ge=xr(),Ge===r&&(Ge=null),Ge!==r?(ct=qo(),ct!==r?(ht=x,U=m(le,ct),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r),x===r))){if(x=O,U=Al(),U!==r)if(le=ll(),le!==r)if(xe=xr(),xe!==r)if(Qe=nE(),Qe!==r){if(Ge=[],ct=Jo(),ct!==r)for(;ct!==r;)Ge.push(ct),ct=Jo();else Ge=r;Ge!==r?(ht=x,U=m(le,Qe),x=U):(O=x,x=r)}else O=x,x=r;else O=x,x=r;else O=x,x=r;else O=x,x=r;if(x===r)if(x=O,U=Al(),U!==r)if(le=ll(),le!==r){if(xe=[],Qe=O,Ge=xr(),Ge===r&&(Ge=null),Ge!==r?(t.charCodeAt(O)===44?(ct=I,O++):(ct=r,Ye===0&&et(B)),ct!==r?(sr=xr(),sr===r&&(sr=null),sr!==r?(Wo=ll(),Wo!==r?(ht=Qe,Ge=b(le,Wo),Qe=Ge):(O=Qe,Qe=r)):(O=Qe,Qe=r)):(O=Qe,Qe=r)):(O=Qe,Qe=r),Qe!==r)for(;Qe!==r;)xe.push(Qe),Qe=O,Ge=xr(),Ge===r&&(Ge=null),Ge!==r?(t.charCodeAt(O)===44?(ct=I,O++):(ct=r,Ye===0&&et(B)),ct!==r?(sr=xr(),sr===r&&(sr=null),sr!==r?(Wo=ll(),Wo!==r?(ht=Qe,Ge=b(le,Wo),Qe=Ge):(O=Qe,Qe=r)):(O=Qe,Qe=r)):(O=Qe,Qe=r)):(O=Qe,Qe=r);else xe=r;xe!==r?(Qe=xr(),Qe===r&&(Qe=null),Qe!==r?(t.charCodeAt(O)===58?(Ge=p,O++):(Ge=r,Ye===0&&et(d)),Ge!==r?(ct=xr(),ct===r&&(ct=null),ct!==r?(sr=qo(),sr!==r?(ht=x,U=R(le,xe,sr),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)}else O=x,x=r;else O=x,x=r}return x}function qo(){var x,U,le,xe,Qe,Ge,ct;if(x=O,U=O,Ye++,le=O,xe=Zs(),xe!==r?(Qe=qQ(),Qe!==r?(t.charCodeAt(O)===45?(Ge=o,O++):(Ge=r,Ye===0&&et(a)),Ge!==r?(ct=xr(),ct!==r?(xe=[xe,Qe,Ge,ct],le=xe):(O=le,le=r)):(O=le,le=r)):(O=le,le=r)):(O=le,le=r),Ye--,le!==r?(O=U,U=void 0):U=r,U!==r?(le=Jo(),le!==r?(xe=rE(),xe!==r?(Qe=Xa(),Qe!==r?(Ge=iE(),Ge!==r?(ht=x,U=H(Qe),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r),x===r&&(x=O,U=Zs(),U!==r?(le=rE(),le!==r?(xe=ol(),xe!==r?(Qe=iE(),Qe!==r?(ht=x,U=H(xe),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r),x===r))if(x=O,U=WQ(),U!==r){if(le=[],xe=Jo(),xe!==r)for(;xe!==r;)le.push(xe),xe=Jo();else le=r;le!==r?(ht=x,U=L(U),x=U):(O=x,x=r)}else O=x,x=r;return x}function Al(){var x,U,le;for(Ye++,x=O,U=[],t.charCodeAt(O)===32?(le=J,O++):(le=r,Ye===0&&et(ne));le!==r;)U.push(le),t.charCodeAt(O)===32?(le=J,O++):(le=r,Ye===0&&et(ne));return U!==r?(ht=O,le=q(U),le?le=void 0:le=r,le!==r?(U=[U,le],x=U):(O=x,x=r)):(O=x,x=r),Ye--,x===r&&(U=r,Ye===0&&et(K)),x}function qQ(){var x,U,le;for(x=O,U=[],t.charCodeAt(O)===32?(le=J,O++):(le=r,Ye===0&&et(ne));le!==r;)U.push(le),t.charCodeAt(O)===32?(le=J,O++):(le=r,Ye===0&&et(ne));return U!==r?(ht=O,le=A(U),le?le=void 0:le=r,le!==r?(U=[U,le],x=U):(O=x,x=r)):(O=x,x=r),x}function rE(){var x;return ht=O,x=V(),x?x=void 0:x=r,x}function iE(){var x;return ht=O,x=W(),x?x=void 0:x=r,x}function JQ(){var x;return x=cl(),x===r&&(x=Gf()),x}function ll(){var x,U,le;if(x=cl(),x===r){if(x=O,U=[],le=_c(),le!==r)for(;le!==r;)U.push(le),le=_c();else U=r;U!==r&&(ht=x,U=X()),x=U}return x}function WQ(){var x;return x=jf(),x===r&&(x=sE(),x===r&&(x=cl(),x===r&&(x=Gf()))),x}function nE(){var x;return x=jf(),x===r&&(x=cl(),x===r&&(x=_c())),x}function Gf(){var x,U,le,xe,Qe,Ge;if(Ye++,x=O,D.test(t.charAt(O))?(U=t.charAt(O),O++):(U=r,Ye===0&&et(he)),U!==r){for(le=[],xe=O,Qe=xr(),Qe===r&&(Qe=null),Qe!==r?(pe.test(t.charAt(O))?(Ge=t.charAt(O),O++):(Ge=r,Ye===0&&et(Ne)),Ge!==r?(Qe=[Qe,Ge],xe=Qe):(O=xe,xe=r)):(O=xe,xe=r);xe!==r;)le.push(xe),xe=O,Qe=xr(),Qe===r&&(Qe=null),Qe!==r?(pe.test(t.charAt(O))?(Ge=t.charAt(O),O++):(Ge=r,Ye===0&&et(Ne)),Ge!==r?(Qe=[Qe,Ge],xe=Qe):(O=xe,xe=r)):(O=xe,xe=r);le!==r?(ht=x,U=Pe(),x=U):(O=x,x=r)}else O=x,x=r;return Ye--,x===r&&(U=r,Ye===0&&et(F)),x}function _c(){var x,U,le,xe,Qe;if(x=O,t.substr(O,2)===qe?(U=qe,O+=2):(U=r,Ye===0&&et(re)),U===r&&(U=null),U!==r)if(se.test(t.charAt(O))?(le=t.charAt(O),O++):(le=r,Ye===0&&et(be)),le!==r){for(xe=[],ae.test(t.charAt(O))?(Qe=t.charAt(O),O++):(Qe=r,Ye===0&&et(Ae));Qe!==r;)xe.push(Qe),ae.test(t.charAt(O))?(Qe=t.charAt(O),O++):(Qe=r,Ye===0&&et(Ae));xe!==r?(ht=x,U=Pe(),x=U):(O=x,x=r)}else O=x,x=r;else O=x,x=r;return x}function jf(){var x,U;return x=O,t.substr(O,4)===De?(U=De,O+=4):(U=r,Ye===0&&et($)),U!==r&&(ht=x,U=G()),x=U,x}function sE(){var x,U;return x=O,t.substr(O,4)===Ce?(U=Ce,O+=4):(U=r,Ye===0&&et(ee)),U!==r&&(ht=x,U=Ue()),x=U,x===r&&(x=O,t.substr(O,5)===Oe?(U=Oe,O+=5):(U=r,Ye===0&&et(vt)),U!==r&&(ht=x,U=dt()),x=U),x}function cl(){var x,U,le,xe;return Ye++,x=O,t.charCodeAt(O)===34?(U=ii,O++):(U=r,Ye===0&&et(an)),U!==r?(t.charCodeAt(O)===34?(le=ii,O++):(le=r,Ye===0&&et(an)),le!==r?(ht=x,U=yr(),x=U):(O=x,x=r)):(O=x,x=r),x===r&&(x=O,t.charCodeAt(O)===34?(U=ii,O++):(U=r,Ye===0&&et(an)),U!==r?(le=oE(),le!==r?(t.charCodeAt(O)===34?(xe=ii,O++):(xe=r,Ye===0&&et(an)),xe!==r?(ht=x,U=Ki(le),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)),Ye--,x===r&&(U=r,Ye===0&&et(ri)),x}function oE(){var x,U,le;if(x=O,U=[],le=Yf(),le!==r)for(;le!==r;)U.push(le),le=Yf();else U=r;return U!==r&&(ht=x,U=Qi(U)),x=U,x}function Yf(){var x,U,le,xe,Qe,Ge;return Go.test(t.charAt(O))?(x=t.charAt(O),O++):(x=r,Ye===0&&et(wr)),x===r&&(x=O,t.substr(O,2)===Ui?(U=Ui,O+=2):(U=r,Ye===0&&et(ws)),U!==r&&(ht=x,U=Tf()),x=U,x===r&&(x=O,t.substr(O,2)===Mf?(U=Mf,O+=2):(U=r,Ye===0&&et(Rm)),U!==r&&(ht=x,U=Fm()),x=U,x===r&&(x=O,t.substr(O,2)===Nm?(U=Nm,O+=2):(U=r,Ye===0&&et(DQ)),U!==r&&(ht=x,U=RQ()),x=U,x===r&&(x=O,t.substr(O,2)===Of?(U=Of,O+=2):(U=r,Ye===0&&et(FQ)),U!==r&&(ht=x,U=NQ()),x=U,x===r&&(x=O,t.substr(O,2)===Lm?(U=Lm,O+=2):(U=r,Ye===0&&et(LQ)),U!==r&&(ht=x,U=Va()),x=U,x===r&&(x=O,t.substr(O,2)===jo?(U=jo,O+=2):(U=r,Ye===0&&et(Tm)),U!==r&&(ht=x,U=Mm()),x=U,x===r&&(x=O,t.substr(O,2)===te?(U=te,O+=2):(U=r,Ye===0&&et(Om)),U!==r&&(ht=x,U=Km()),x=U,x===r&&(x=O,t.substr(O,2)===il?(U=il,O+=2):(U=r,Ye===0&&et(Um)),U!==r&&(ht=x,U=Hm()),x=U,x===r&&(x=O,t.substr(O,2)===Kf?(U=Kf,O+=2):(U=r,Ye===0&&et(Gm)),U!==r?(le=Xc(),le!==r?(xe=Xc(),xe!==r?(Qe=Xc(),Qe!==r?(Ge=Xc(),Ge!==r?(ht=x,U=jm(le,xe,Qe,Ge),x=U):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)):(O=x,x=r)))))))))),x}function Xc(){var x;return TQ.test(t.charAt(O))?(x=t.charAt(O),O++):(x=r,Ye===0&&et(MQ)),x}function xr(){var x,U;if(Ye++,x=[],qm.test(t.charAt(O))?(U=t.charAt(O),O++):(U=r,Ye===0&&et(Jm)),U!==r)for(;U!==r;)x.push(U),qm.test(t.charAt(O))?(U=t.charAt(O),O++):(U=r,Ye===0&&et(Jm));else x=r;return Ye--,x===r&&(U=r,Ye===0&&et(Ym)),x}function KM(){var x,U;if(Ye++,x=[],zm.test(t.charAt(O))?(U=t.charAt(O),O++):(U=r,Ye===0&&et(Vm)),U!==r)for(;U!==r;)x.push(U),zm.test(t.charAt(O))?(U=t.charAt(O),O++):(U=r,Ye===0&&et(Vm));else x=r;return Ye--,x===r&&(U=r,Ye===0&&et(Wm)),x}function Jo(){var x,U,le,xe,Qe,Ge;if(x=O,U=Zs(),U!==r){for(le=[],xe=O,Qe=xr(),Qe===r&&(Qe=null),Qe!==r?(Ge=Zs(),Ge!==r?(Qe=[Qe,Ge],xe=Qe):(O=xe,xe=r)):(O=xe,xe=r);xe!==r;)le.push(xe),xe=O,Qe=xr(),Qe===r&&(Qe=null),Qe!==r?(Ge=Zs(),Ge!==r?(Qe=[Qe,Ge],xe=Qe):(O=xe,xe=r)):(O=xe,xe=r);le!==r?(U=[U,le],x=U):(O=x,x=r)}else O=x,x=r;return x}function Zs(){var x;return t.substr(O,2)===Uf?(x=Uf,O+=2):(x=r,Ye===0&&et(OQ)),x===r&&(t.charCodeAt(O)===10?(x=KQ,O++):(x=r,Ye===0&&et(_m)),x===r&&(t.charCodeAt(O)===13?(x=UQ,O++):(x=r,Ye===0&&et(HQ)))),x}let aE=2,Zc=0;if(nl=n(),nl!==r&&O===t.length)return nl;throw nl!==r&&O{var fRe=typeof global=="object"&&global&&global.Object===Object&&global;V5.exports=fRe});var Ks=E((Zat,_5)=>{var hRe=WP(),pRe=typeof self=="object"&&self&&self.Object===Object&&self,dRe=hRe||pRe||Function("return this")();_5.exports=dRe});var ac=E(($at,X5)=>{var CRe=Ks(),mRe=CRe.Symbol;X5.exports=mRe});var $5=E((eAt,Z5)=>{function ERe(t,e){for(var r=-1,i=t==null?0:t.length,n=Array(i);++r{var IRe=Array.isArray;e6.exports=IRe});var n6=E((rAt,t6)=>{var r6=ac(),i6=Object.prototype,yRe=i6.hasOwnProperty,wRe=i6.toString,Jp=r6?r6.toStringTag:void 0;function BRe(t){var e=yRe.call(t,Jp),r=t[Jp];try{t[Jp]=void 0;var i=!0}catch(s){}var n=wRe.call(t);return i&&(e?t[Jp]=r:delete t[Jp]),n}t6.exports=BRe});var o6=E((iAt,s6)=>{var QRe=Object.prototype,bRe=QRe.toString;function vRe(t){return bRe.call(t)}s6.exports=vRe});var Ac=E((nAt,a6)=>{var A6=ac(),SRe=n6(),xRe=o6(),kRe="[object Null]",PRe="[object Undefined]",l6=A6?A6.toStringTag:void 0;function DRe(t){return t==null?t===void 0?PRe:kRe:l6&&l6 in Object(t)?SRe(t):xRe(t)}a6.exports=DRe});var Qo=E((sAt,c6)=>{function RRe(t){return t!=null&&typeof t=="object"}c6.exports=RRe});var Nw=E((oAt,u6)=>{var FRe=Ac(),NRe=Qo(),LRe="[object Symbol]";function TRe(t){return typeof t=="symbol"||NRe(t)&&FRe(t)==LRe}u6.exports=TRe});var C6=E((aAt,g6)=>{var f6=ac(),MRe=$5(),ORe=As(),KRe=Nw(),URe=1/0,h6=f6?f6.prototype:void 0,p6=h6?h6.toString:void 0;function d6(t){if(typeof t=="string")return t;if(ORe(t))return MRe(t,d6)+"";if(KRe(t))return p6?p6.call(t):"";var e=t+"";return e=="0"&&1/t==-URe?"-0":e}g6.exports=d6});var gg=E((AAt,m6)=>{var HRe=C6();function GRe(t){return t==null?"":HRe(t)}m6.exports=GRe});var zP=E((lAt,E6)=>{function jRe(t,e,r){var i=-1,n=t.length;e<0&&(e=-e>n?0:n+e),r=r>n?n:r,r<0&&(r+=n),n=e>r?0:r-e>>>0,e>>>=0;for(var s=Array(n);++i{var YRe=zP();function qRe(t,e,r){var i=t.length;return r=r===void 0?i:r,!e&&r>=i?t:YRe(t,e,r)}I6.exports=qRe});var VP=E((uAt,w6)=>{var JRe="\\ud800-\\udfff",WRe="\\u0300-\\u036f",zRe="\\ufe20-\\ufe2f",VRe="\\u20d0-\\u20ff",_Re=WRe+zRe+VRe,XRe="\\ufe0e\\ufe0f",ZRe="\\u200d",$Re=RegExp("["+ZRe+JRe+_Re+XRe+"]");function eFe(t){return $Re.test(t)}w6.exports=eFe});var Q6=E((gAt,B6)=>{function tFe(t){return t.split("")}B6.exports=tFe});var R6=E((fAt,b6)=>{var v6="\\ud800-\\udfff",rFe="\\u0300-\\u036f",iFe="\\ufe20-\\ufe2f",nFe="\\u20d0-\\u20ff",sFe=rFe+iFe+nFe,oFe="\\ufe0e\\ufe0f",aFe="["+v6+"]",_P="["+sFe+"]",XP="\\ud83c[\\udffb-\\udfff]",AFe="(?:"+_P+"|"+XP+")",S6="[^"+v6+"]",x6="(?:\\ud83c[\\udde6-\\uddff]){2}",k6="[\\ud800-\\udbff][\\udc00-\\udfff]",lFe="\\u200d",P6=AFe+"?",D6="["+oFe+"]?",cFe="(?:"+lFe+"(?:"+[S6,x6,k6].join("|")+")"+D6+P6+")*",uFe=D6+P6+cFe,gFe="(?:"+[S6+_P+"?",_P,x6,k6,aFe].join("|")+")",fFe=RegExp(XP+"(?="+XP+")|"+gFe+uFe,"g");function hFe(t){return t.match(fFe)||[]}b6.exports=hFe});var N6=E((hAt,F6)=>{var pFe=Q6(),dFe=VP(),CFe=R6();function mFe(t){return dFe(t)?CFe(t):pFe(t)}F6.exports=mFe});var T6=E((pAt,L6)=>{var EFe=y6(),IFe=VP(),yFe=N6(),wFe=gg();function BFe(t){return function(e){e=wFe(e);var r=IFe(e)?yFe(e):void 0,i=r?r[0]:e.charAt(0),n=r?EFe(r,1).join(""):e.slice(1);return i[t]()+n}}L6.exports=BFe});var O6=E((dAt,M6)=>{var QFe=T6(),bFe=QFe("toUpperCase");M6.exports=bFe});var ZP=E((CAt,K6)=>{var vFe=gg(),SFe=O6();function xFe(t){return SFe(vFe(t).toLowerCase())}K6.exports=xFe});var H6=E((mAt,U6)=>{"use strict";U6.exports=(t,...e)=>new Promise(r=>{r(t(...e))})});var Wp=E((EAt,$P)=>{"use strict";var kFe=H6(),G6=t=>{if(t<1)throw new TypeError("Expected `concurrency` to be a number from 1 and up");let e=[],r=0,i=()=>{r--,e.length>0&&e.shift()()},n=(a,l,...c)=>{r++;let u=kFe(a,...c);l(u),u.then(i,i)},s=(a,l,...c)=>{rnew Promise(c=>s(a,c,...l));return Object.defineProperties(o,{activeCount:{get:()=>r},pendingCount:{get:()=>e.length}}),o};$P.exports=G6;$P.exports.default=G6});var X6=E((FAt,Mw)=>{function PFe(){var t=0,e=1,r=2,i=3,n=4,s=5,o=6,a=7,l=8,c=9,u=10,g=11,f=12,h=13,p=14,d=15,m=16,I=17,B=0,b=1,R=2,H=3,L=4;function K(A,V){return 55296<=A.charCodeAt(V)&&A.charCodeAt(V)<=56319&&56320<=A.charCodeAt(V+1)&&A.charCodeAt(V+1)<=57343}function J(A,V){V===void 0&&(V=0);var W=A.charCodeAt(V);if(55296<=W&&W<=56319&&V=1){var X=A.charCodeAt(V-1),F=W;return 55296<=X&&X<=56319?(X-55296)*1024+(F-56320)+65536:F}return W}function ne(A,V,W){var X=[A].concat(V).concat([W]),F=X[X.length-2],D=W,he=X.lastIndexOf(p);if(he>1&&X.slice(1,he).every(function(Pe){return Pe==i})&&[i,h,I].indexOf(A)==-1)return R;var pe=X.lastIndexOf(n);if(pe>0&&X.slice(1,pe).every(function(Pe){return Pe==n})&&[f,n].indexOf(F)==-1)return X.filter(function(Pe){return Pe==n}).length%2==1?H:L;if(F==t&&D==e)return B;if(F==r||F==t||F==e)return D==p&&V.every(function(Pe){return Pe==i})?R:b;if(D==r||D==t||D==e)return b;if(F==o&&(D==o||D==a||D==c||D==u))return B;if((F==c||F==a)&&(D==a||D==l))return B;if((F==u||F==l)&&D==l)return B;if(D==i||D==d)return B;if(D==s)return B;if(F==f)return B;var Ne=X.indexOf(i)!=-1?X.lastIndexOf(i)-1:X.length-2;return[h,I].indexOf(X[Ne])!=-1&&X.slice(Ne+1,-1).every(function(Pe){return Pe==i})&&D==p||F==d&&[m,I].indexOf(D)!=-1?B:V.indexOf(n)!=-1?R:F==n&&D==n?B:b}this.nextBreak=function(A,V){if(V===void 0&&(V=0),V<0)return 0;if(V>=A.length-1)return A.length;for(var W=q(J(A,V)),X=[],F=V+1;F{var DFe=X6(),RFe=/^(.*?)(\x1b\[[^m]+m|\x1b\]8;;.*?(\x1b\\|\u0007))/,FFe=new DFe;Z6.exports=(t,e=0,r=t.length)=>{if(e<0||r<0)throw new RangeError("Negative indices aren't supported by this implementation");let i=r-e,n="",s=0,o=0;for(;t.length>0;){let a=t.match(RFe)||[t,t,void 0],l=FFe.splitGraphemes(a[1]),c=Math.min(e-s,l.length);l=l.slice(c);let u=Math.min(i-o,l.length);n+=l.slice(0,u).join(""),s+=c,o+=u,typeof a[2]!="undefined"&&(n+=a[2]),t=t.slice(a[0].length)}return n}});var fg=E((alt,f9)=>{"use strict";var h9=new Map([["C","cwd"],["f","file"],["z","gzip"],["P","preservePaths"],["U","unlink"],["strip-components","strip"],["stripComponents","strip"],["keep-newer","newer"],["keepNewer","newer"],["keep-newer-files","newer"],["keepNewerFiles","newer"],["k","keep"],["keep-existing","keep"],["keepExisting","keep"],["m","noMtime"],["no-mtime","noMtime"],["p","preserveOwner"],["L","follow"],["h","follow"]]),olt=f9.exports=t=>t?Object.keys(t).map(e=>[h9.has(e)?h9.get(e):e,t[e]]).reduce((e,r)=>(e[r[0]]=r[1],e),Object.create(null)):{}});var hg=E((Alt,p9)=>{"use strict";var JFe=require("events"),d9=require("stream"),_p=Rh(),C9=require("string_decoder").StringDecoder,va=Symbol("EOF"),Xp=Symbol("maybeEmitEnd"),xA=Symbol("emittedEnd"),Gw=Symbol("emittingEnd"),jw=Symbol("closed"),m9=Symbol("read"),iD=Symbol("flush"),E9=Symbol("flushChunk"),Bn=Symbol("encoding"),Sa=Symbol("decoder"),Yw=Symbol("flowing"),Zp=Symbol("paused"),$p=Symbol("resume"),rn=Symbol("bufferLength"),I9=Symbol("bufferPush"),nD=Symbol("bufferShift"),Ni=Symbol("objectMode"),Li=Symbol("destroyed"),y9=global._MP_NO_ITERATOR_SYMBOLS_!=="1",WFe=y9&&Symbol.asyncIterator||Symbol("asyncIterator not implemented"),zFe=y9&&Symbol.iterator||Symbol("iterator not implemented"),w9=t=>t==="end"||t==="finish"||t==="prefinish",VFe=t=>t instanceof ArrayBuffer||typeof t=="object"&&t.constructor&&t.constructor.name==="ArrayBuffer"&&t.byteLength>=0,_Fe=t=>!Buffer.isBuffer(t)&&ArrayBuffer.isView(t);p9.exports=class B9 extends d9{constructor(e){super();this[Yw]=!1,this[Zp]=!1,this.pipes=new _p,this.buffer=new _p,this[Ni]=e&&e.objectMode||!1,this[Ni]?this[Bn]=null:this[Bn]=e&&e.encoding||null,this[Bn]==="buffer"&&(this[Bn]=null),this[Sa]=this[Bn]?new C9(this[Bn]):null,this[va]=!1,this[xA]=!1,this[Gw]=!1,this[jw]=!1,this.writable=!0,this.readable=!0,this[rn]=0,this[Li]=!1}get bufferLength(){return this[rn]}get encoding(){return this[Bn]}set encoding(e){if(this[Ni])throw new Error("cannot set encoding in objectMode");if(this[Bn]&&e!==this[Bn]&&(this[Sa]&&this[Sa].lastNeed||this[rn]))throw new Error("cannot change encoding");this[Bn]!==e&&(this[Sa]=e?new C9(e):null,this.buffer.length&&(this.buffer=this.buffer.map(r=>this[Sa].write(r)))),this[Bn]=e}setEncoding(e){this.encoding=e}get objectMode(){return this[Ni]}set objectMode(e){this[Ni]=this[Ni]||!!e}write(e,r,i){if(this[va])throw new Error("write after end");return this[Li]?(this.emit("error",Object.assign(new Error("Cannot call write after a stream was destroyed"),{code:"ERR_STREAM_DESTROYED"})),!0):(typeof r=="function"&&(i=r,r="utf8"),r||(r="utf8"),!this[Ni]&&!Buffer.isBuffer(e)&&(_Fe(e)?e=Buffer.from(e.buffer,e.byteOffset,e.byteLength):VFe(e)?e=Buffer.from(e):typeof e!="string"&&(this.objectMode=!0)),!this.objectMode&&!e.length?(this[rn]!==0&&this.emit("readable"),i&&i(),this.flowing):(typeof e=="string"&&!this[Ni]&&!(r===this[Bn]&&!this[Sa].lastNeed)&&(e=Buffer.from(e,r)),Buffer.isBuffer(e)&&this[Bn]&&(e=this[Sa].write(e)),this.flowing?(this[rn]!==0&&this[iD](!0),this.emit("data",e)):this[I9](e),this[rn]!==0&&this.emit("readable"),i&&i(),this.flowing))}read(e){if(this[Li])return null;try{return this[rn]===0||e===0||e>this[rn]?null:(this[Ni]&&(e=null),this.buffer.length>1&&!this[Ni]&&(this.encoding?this.buffer=new _p([Array.from(this.buffer).join("")]):this.buffer=new _p([Buffer.concat(Array.from(this.buffer),this[rn])])),this[m9](e||null,this.buffer.head.value))}finally{this[Xp]()}}[m9](e,r){return e===r.length||e===null?this[nD]():(this.buffer.head.value=r.slice(e),r=r.slice(0,e),this[rn]-=e),this.emit("data",r),!this.buffer.length&&!this[va]&&this.emit("drain"),r}end(e,r,i){return typeof e=="function"&&(i=e,e=null),typeof r=="function"&&(i=r,r="utf8"),e&&this.write(e,r),i&&this.once("end",i),this[va]=!0,this.writable=!1,(this.flowing||!this[Zp])&&this[Xp](),this}[$p](){this[Li]||(this[Zp]=!1,this[Yw]=!0,this.emit("resume"),this.buffer.length?this[iD]():this[va]?this[Xp]():this.emit("drain"))}resume(){return this[$p]()}pause(){this[Yw]=!1,this[Zp]=!0}get destroyed(){return this[Li]}get flowing(){return this[Yw]}get paused(){return this[Zp]}[I9](e){return this[Ni]?this[rn]+=1:this[rn]+=e.length,this.buffer.push(e)}[nD](){return this.buffer.length&&(this[Ni]?this[rn]-=1:this[rn]-=this.buffer.head.value.length),this.buffer.shift()}[iD](e){do;while(this[E9](this[nD]()));!e&&!this.buffer.length&&!this[va]&&this.emit("drain")}[E9](e){return e?(this.emit("data",e),this.flowing):!1}pipe(e,r){if(this[Li])return;let i=this[xA];r=r||{},e===process.stdout||e===process.stderr?r.end=!1:r.end=r.end!==!1;let n={dest:e,opts:r,ondrain:s=>this[$p]()};return this.pipes.push(n),e.on("drain",n.ondrain),this[$p](),i&&n.opts.end&&n.dest.end(),e}addListener(e,r){return this.on(e,r)}on(e,r){try{return super.on(e,r)}finally{e==="data"&&!this.pipes.length&&!this.flowing?this[$p]():w9(e)&&this[xA]&&(super.emit(e),this.removeAllListeners(e))}}get emittedEnd(){return this[xA]}[Xp](){!this[Gw]&&!this[xA]&&!this[Li]&&this.buffer.length===0&&this[va]&&(this[Gw]=!0,this.emit("end"),this.emit("prefinish"),this.emit("finish"),this[jw]&&this.emit("close"),this[Gw]=!1)}emit(e,r){if(e!=="error"&&e!=="close"&&e!==Li&&this[Li])return;if(e==="data"){if(!r)return;this.pipes.length&&this.pipes.forEach(n=>n.dest.write(r)===!1&&this.pause())}else if(e==="end"){if(this[xA]===!0)return;this[xA]=!0,this.readable=!1,this[Sa]&&(r=this[Sa].end(),r&&(this.pipes.forEach(n=>n.dest.write(r)),super.emit("data",r))),this.pipes.forEach(n=>{n.dest.removeListener("drain",n.ondrain),n.opts.end&&n.dest.end()})}else if(e==="close"&&(this[jw]=!0,!this[xA]&&!this[Li]))return;let i=new Array(arguments.length);if(i[0]=e,i[1]=r,arguments.length>2)for(let n=2;n{e.push(i),this[Ni]||(e.dataLength+=i.length)}),r.then(()=>e)}concat(){return this[Ni]?Promise.reject(new Error("cannot concat in objectMode")):this.collect().then(e=>this[Ni]?Promise.reject(new Error("cannot concat in objectMode")):this[Bn]?e.join(""):Buffer.concat(e,e.dataLength))}promise(){return new Promise((e,r)=>{this.on(Li,()=>r(new Error("stream destroyed"))),this.on("end",()=>e()),this.on("error",i=>r(i))})}[WFe](){return{next:()=>{let r=this.read();if(r!==null)return Promise.resolve({done:!1,value:r});if(this[va])return Promise.resolve({done:!0});let i=null,n=null,s=c=>{this.removeListener("data",o),this.removeListener("end",a),n(c)},o=c=>{this.removeListener("error",s),this.removeListener("end",a),this.pause(),i({value:c,done:!!this[va]})},a=()=>{this.removeListener("error",s),this.removeListener("data",o),i({done:!0})},l=()=>s(new Error("stream destroyed"));return new Promise((c,u)=>{n=u,i=c,this.once(Li,l),this.once("error",s),this.once("end",a),this.once("data",o)})}}}[zFe](){return{next:()=>{let r=this.read();return{value:r,done:r===null}}}}destroy(e){return this[Li]?(e?this.emit("error",e):this.emit(Li),this):(this[Li]=!0,this.buffer=new _p,this[rn]=0,typeof this.close=="function"&&!this[jw]&&this.close(),e?this.emit("error",e):this.emit(Li),this)}static isStream(e){return!!e&&(e instanceof B9||e instanceof d9||e instanceof JFe&&(typeof e.pipe=="function"||typeof e.write=="function"&&typeof e.end=="function"))}}});var b9=E((llt,Q9)=>{var XFe=require("zlib").constants||{ZLIB_VERNUM:4736};Q9.exports=Object.freeze(Object.assign(Object.create(null),{Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_VERSION_ERROR:-6,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,DEFLATE:1,INFLATE:2,GZIP:3,GUNZIP:4,DEFLATERAW:5,INFLATERAW:6,UNZIP:7,BROTLI_DECODE:8,BROTLI_ENCODE:9,Z_MIN_WINDOWBITS:8,Z_MAX_WINDOWBITS:15,Z_DEFAULT_WINDOWBITS:15,Z_MIN_CHUNK:64,Z_MAX_CHUNK:Infinity,Z_DEFAULT_CHUNK:16384,Z_MIN_MEMLEVEL:1,Z_MAX_MEMLEVEL:9,Z_DEFAULT_MEMLEVEL:8,Z_MIN_LEVEL:-1,Z_MAX_LEVEL:9,Z_DEFAULT_LEVEL:-1,BROTLI_OPERATION_PROCESS:0,BROTLI_OPERATION_FLUSH:1,BROTLI_OPERATION_FINISH:2,BROTLI_OPERATION_EMIT_METADATA:3,BROTLI_MODE_GENERIC:0,BROTLI_MODE_TEXT:1,BROTLI_MODE_FONT:2,BROTLI_DEFAULT_MODE:0,BROTLI_MIN_QUALITY:0,BROTLI_MAX_QUALITY:11,BROTLI_DEFAULT_QUALITY:11,BROTLI_MIN_WINDOW_BITS:10,BROTLI_MAX_WINDOW_BITS:24,BROTLI_LARGE_MAX_WINDOW_BITS:30,BROTLI_DEFAULT_WINDOW:22,BROTLI_MIN_INPUT_BLOCK_BITS:16,BROTLI_MAX_INPUT_BLOCK_BITS:24,BROTLI_PARAM_MODE:0,BROTLI_PARAM_QUALITY:1,BROTLI_PARAM_LGWIN:2,BROTLI_PARAM_LGBLOCK:3,BROTLI_PARAM_DISABLE_LITERAL_CONTEXT_MODELING:4,BROTLI_PARAM_SIZE_HINT:5,BROTLI_PARAM_LARGE_WINDOW:6,BROTLI_PARAM_NPOSTFIX:7,BROTLI_PARAM_NDIRECT:8,BROTLI_DECODER_RESULT_ERROR:0,BROTLI_DECODER_RESULT_SUCCESS:1,BROTLI_DECODER_RESULT_NEEDS_MORE_INPUT:2,BROTLI_DECODER_RESULT_NEEDS_MORE_OUTPUT:3,BROTLI_DECODER_PARAM_DISABLE_RING_BUFFER_REALLOCATION:0,BROTLI_DECODER_PARAM_LARGE_WINDOW:1,BROTLI_DECODER_NO_ERROR:0,BROTLI_DECODER_SUCCESS:1,BROTLI_DECODER_NEEDS_MORE_INPUT:2,BROTLI_DECODER_NEEDS_MORE_OUTPUT:3,BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_NIBBLE:-1,BROTLI_DECODER_ERROR_FORMAT_RESERVED:-2,BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_META_NIBBLE:-3,BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_ALPHABET:-4,BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_SAME:-5,BROTLI_DECODER_ERROR_FORMAT_CL_SPACE:-6,BROTLI_DECODER_ERROR_FORMAT_HUFFMAN_SPACE:-7,BROTLI_DECODER_ERROR_FORMAT_CONTEXT_MAP_REPEAT:-8,BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_1:-9,BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_2:-10,BROTLI_DECODER_ERROR_FORMAT_TRANSFORM:-11,BROTLI_DECODER_ERROR_FORMAT_DICTIONARY:-12,BROTLI_DECODER_ERROR_FORMAT_WINDOW_BITS:-13,BROTLI_DECODER_ERROR_FORMAT_PADDING_1:-14,BROTLI_DECODER_ERROR_FORMAT_PADDING_2:-15,BROTLI_DECODER_ERROR_FORMAT_DISTANCE:-16,BROTLI_DECODER_ERROR_DICTIONARY_NOT_SET:-19,BROTLI_DECODER_ERROR_INVALID_ARGUMENTS:-20,BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MODES:-21,BROTLI_DECODER_ERROR_ALLOC_TREE_GROUPS:-22,BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MAP:-25,BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_1:-26,BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_2:-27,BROTLI_DECODER_ERROR_ALLOC_BLOCK_TYPE_TREES:-30,BROTLI_DECODER_ERROR_UNREACHABLE:-31},XFe))});var fD=E(Un=>{"use strict";var sD=require("assert"),kA=require("buffer").Buffer,v9=require("zlib"),uc=Un.constants=b9(),ZFe=hg(),S9=kA.concat,gc=Symbol("_superWrite"),ed=class extends Error{constructor(e){super("zlib: "+e.message);this.code=e.code,this.errno=e.errno,this.code||(this.code="ZLIB_ERROR"),this.message="zlib: "+e.message,Error.captureStackTrace(this,this.constructor)}get name(){return"ZlibError"}},$Fe=Symbol("opts"),td=Symbol("flushFlag"),x9=Symbol("finishFlushFlag"),oD=Symbol("fullFlushFlag"),tr=Symbol("handle"),qw=Symbol("onError"),pg=Symbol("sawError"),aD=Symbol("level"),AD=Symbol("strategy"),lD=Symbol("ended"),clt=Symbol("_defaultFullFlush"),cD=class extends ZFe{constructor(e,r){if(!e||typeof e!="object")throw new TypeError("invalid options for ZlibBase constructor");super(e);this[pg]=!1,this[lD]=!1,this[$Fe]=e,this[td]=e.flush,this[x9]=e.finishFlush;try{this[tr]=new v9[r](e)}catch(i){throw new ed(i)}this[qw]=i=>{this[pg]||(this[pg]=!0,this.close(),this.emit("error",i))},this[tr].on("error",i=>this[qw](new ed(i))),this.once("end",()=>this.close)}close(){this[tr]&&(this[tr].close(),this[tr]=null,this.emit("close"))}reset(){if(!this[pg])return sD(this[tr],"zlib binding closed"),this[tr].reset()}flush(e){this.ended||(typeof e!="number"&&(e=this[oD]),this.write(Object.assign(kA.alloc(0),{[td]:e})))}end(e,r,i){return e&&this.write(e,r),this.flush(this[x9]),this[lD]=!0,super.end(null,null,i)}get ended(){return this[lD]}write(e,r,i){if(typeof r=="function"&&(i=r,r="utf8"),typeof e=="string"&&(e=kA.from(e,r)),this[pg])return;sD(this[tr],"zlib binding closed");let n=this[tr]._handle,s=n.close;n.close=()=>{};let o=this[tr].close;this[tr].close=()=>{},kA.concat=c=>c;let a;try{let c=typeof e[td]=="number"?e[td]:this[td];a=this[tr]._processChunk(e,c),kA.concat=S9}catch(c){kA.concat=S9,this[qw](new ed(c))}finally{this[tr]&&(this[tr]._handle=n,n.close=s,this[tr].close=o,this[tr].removeAllListeners("error"))}this[tr]&&this[tr].on("error",c=>this[qw](new ed(c)));let l;if(a)if(Array.isArray(a)&&a.length>0){l=this[gc](kA.from(a[0]));for(let c=1;c{this.flush(n),s()};try{this[tr].params(e,r)}finally{this[tr].flush=i}this[tr]&&(this[aD]=e,this[AD]=r)}}}},k9=class extends PA{constructor(e){super(e,"Deflate")}},P9=class extends PA{constructor(e){super(e,"Inflate")}},uD=Symbol("_portable"),D9=class extends PA{constructor(e){super(e,"Gzip");this[uD]=e&&!!e.portable}[gc](e){return this[uD]?(this[uD]=!1,e[9]=255,super[gc](e)):super[gc](e)}},R9=class extends PA{constructor(e){super(e,"Gunzip")}},F9=class extends PA{constructor(e){super(e,"DeflateRaw")}},N9=class extends PA{constructor(e){super(e,"InflateRaw")}},L9=class extends PA{constructor(e){super(e,"Unzip")}},gD=class extends cD{constructor(e,r){e=e||{},e.flush=e.flush||uc.BROTLI_OPERATION_PROCESS,e.finishFlush=e.finishFlush||uc.BROTLI_OPERATION_FINISH,super(e,r),this[oD]=uc.BROTLI_OPERATION_FLUSH}},T9=class extends gD{constructor(e){super(e,"BrotliCompress")}},M9=class extends gD{constructor(e){super(e,"BrotliDecompress")}};Un.Deflate=k9;Un.Inflate=P9;Un.Gzip=D9;Un.Gunzip=R9;Un.DeflateRaw=F9;Un.InflateRaw=N9;Un.Unzip=L9;typeof v9.BrotliCompress=="function"?(Un.BrotliCompress=T9,Un.BrotliDecompress=M9):Un.BrotliCompress=Un.BrotliDecompress=class{constructor(){throw new Error("Brotli is not supported in this version of Node.js")}}});var rd=E(Jw=>{"use strict";Jw.name=new Map([["0","File"],["","OldFile"],["1","Link"],["2","SymbolicLink"],["3","CharacterDevice"],["4","BlockDevice"],["5","Directory"],["6","FIFO"],["7","ContiguousFile"],["g","GlobalExtendedHeader"],["x","ExtendedHeader"],["A","SolarisACL"],["D","GNUDumpDir"],["I","Inode"],["K","NextFileHasLongLinkpath"],["L","NextFileHasLongPath"],["M","ContinuationFile"],["N","OldGnuLongPath"],["S","SparseFile"],["V","TapeVolumeHeader"],["X","OldExtendedHeader"]]);Jw.code=new Map(Array.from(Jw.name).map(t=>[t[1],t[0]]))});var id=E((plt,O9)=>{"use strict";var flt=rd(),eNe=hg(),hD=Symbol("slurp");O9.exports=class extends eNe{constructor(e,r,i){super();switch(this.pause(),this.extended=r,this.globalExtended=i,this.header=e,this.startBlockSize=512*Math.ceil(e.size/512),this.blockRemain=this.startBlockSize,this.remain=e.size,this.type=e.type,this.meta=!1,this.ignore=!1,this.type){case"File":case"OldFile":case"Link":case"SymbolicLink":case"CharacterDevice":case"BlockDevice":case"Directory":case"FIFO":case"ContiguousFile":case"GNUDumpDir":break;case"NextFileHasLongLinkpath":case"NextFileHasLongPath":case"OldGnuLongPath":case"GlobalExtendedHeader":case"ExtendedHeader":case"OldExtendedHeader":this.meta=!0;break;default:this.ignore=!0}this.path=e.path,this.mode=e.mode,this.mode&&(this.mode=this.mode&4095),this.uid=e.uid,this.gid=e.gid,this.uname=e.uname,this.gname=e.gname,this.size=e.size,this.mtime=e.mtime,this.atime=e.atime,this.ctime=e.ctime,this.linkpath=e.linkpath,this.uname=e.uname,this.gname=e.gname,r&&this[hD](r),i&&this[hD](i,!0)}write(e){let r=e.length;if(r>this.blockRemain)throw new Error("writing more to entry than is appropriate");let i=this.remain,n=this.blockRemain;return this.remain=Math.max(0,i-r),this.blockRemain=Math.max(0,n-r),this.ignore?!0:i>=r?super.write(e):super.write(e.slice(0,i))}[hD](e,r){for(let i in e)e[i]!==null&&e[i]!==void 0&&!(r&&i==="path")&&(this[i]=e[i])}}});var H9=E(pD=>{"use strict";var dlt=pD.encode=(t,e)=>{if(Number.isSafeInteger(t))t<0?rNe(t,e):tNe(t,e);else throw Error("cannot encode number outside of javascript safe integer range");return e},tNe=(t,e)=>{e[0]=128;for(var r=e.length;r>1;r--)e[r-1]=t&255,t=Math.floor(t/256)},rNe=(t,e)=>{e[0]=255;var r=!1;t=t*-1;for(var i=e.length;i>1;i--){var n=t&255;t=Math.floor(t/256),r?e[i-1]=K9(n):n===0?e[i-1]=0:(r=!0,e[i-1]=U9(n))}},Clt=pD.parse=t=>{var e=t[t.length-1],r=t[0],i;if(r===128)i=nNe(t.slice(1,t.length));else if(r===255)i=iNe(t);else throw Error("invalid base256 encoding");if(!Number.isSafeInteger(i))throw Error("parsed number outside of javascript safe integer range");return i},iNe=t=>{for(var e=t.length,r=0,i=!1,n=e-1;n>-1;n--){var s=t[n],o;i?o=K9(s):s===0?o=s:(i=!0,o=U9(s)),o!==0&&(r-=o*Math.pow(256,e-n-1))}return r},nNe=t=>{for(var e=t.length,r=0,i=e-1;i>-1;i--){var n=t[i];n!==0&&(r+=n*Math.pow(256,e-i-1))}return r},K9=t=>(255^t)&255,U9=t=>(255^t)+1&255});var Cg=E((Elt,G9)=>{"use strict";var dD=rd(),dg=require("path").posix,j9=H9(),CD=Symbol("slurp"),Hn=Symbol("type"),Y9=class{constructor(e,r,i,n){this.cksumValid=!1,this.needPax=!1,this.nullBlock=!1,this.block=null,this.path=null,this.mode=null,this.uid=null,this.gid=null,this.size=null,this.mtime=null,this.cksum=null,this[Hn]="0",this.linkpath=null,this.uname=null,this.gname=null,this.devmaj=0,this.devmin=0,this.atime=null,this.ctime=null,Buffer.isBuffer(e)?this.decode(e,r||0,i,n):e&&this.set(e)}decode(e,r,i,n){if(r||(r=0),!e||!(e.length>=r+512))throw new Error("need 512 bytes for header");if(this.path=fc(e,r,100),this.mode=DA(e,r+100,8),this.uid=DA(e,r+108,8),this.gid=DA(e,r+116,8),this.size=DA(e,r+124,12),this.mtime=mD(e,r+136,12),this.cksum=DA(e,r+148,12),this[CD](i),this[CD](n,!0),this[Hn]=fc(e,r+156,1),this[Hn]===""&&(this[Hn]="0"),this[Hn]==="0"&&this.path.substr(-1)==="/"&&(this[Hn]="5"),this[Hn]==="5"&&(this.size=0),this.linkpath=fc(e,r+157,100),e.slice(r+257,r+265).toString()==="ustar\x0000")if(this.uname=fc(e,r+265,32),this.gname=fc(e,r+297,32),this.devmaj=DA(e,r+329,8),this.devmin=DA(e,r+337,8),e[r+475]!==0){let o=fc(e,r+345,155);this.path=o+"/"+this.path}else{let o=fc(e,r+345,130);o&&(this.path=o+"/"+this.path),this.atime=mD(e,r+476,12),this.ctime=mD(e,r+488,12)}let s=8*32;for(let o=r;o=r+512))throw new Error("need 512 bytes for header");let i=this.ctime||this.atime?130:155,n=sNe(this.path||"",i),s=n[0],o=n[1];this.needPax=n[2],this.needPax=hc(e,r,100,s)||this.needPax,this.needPax=RA(e,r+100,8,this.mode)||this.needPax,this.needPax=RA(e,r+108,8,this.uid)||this.needPax,this.needPax=RA(e,r+116,8,this.gid)||this.needPax,this.needPax=RA(e,r+124,12,this.size)||this.needPax,this.needPax=ED(e,r+136,12,this.mtime)||this.needPax,e[r+156]=this[Hn].charCodeAt(0),this.needPax=hc(e,r+157,100,this.linkpath)||this.needPax,e.write("ustar\x0000",r+257,8),this.needPax=hc(e,r+265,32,this.uname)||this.needPax,this.needPax=hc(e,r+297,32,this.gname)||this.needPax,this.needPax=RA(e,r+329,8,this.devmaj)||this.needPax,this.needPax=RA(e,r+337,8,this.devmin)||this.needPax,this.needPax=hc(e,r+345,i,o)||this.needPax,e[r+475]!==0?this.needPax=hc(e,r+345,155,o)||this.needPax:(this.needPax=hc(e,r+345,130,o)||this.needPax,this.needPax=ED(e,r+476,12,this.atime)||this.needPax,this.needPax=ED(e,r+488,12,this.ctime)||this.needPax);let a=8*32;for(let l=r;l{let r=100,i=t,n="",s,o=dg.parse(t).root||".";if(Buffer.byteLength(i)r&&Buffer.byteLength(n)<=e?s=[i.substr(0,r-1),n,!0]:(i=dg.join(dg.basename(n),i),n=dg.dirname(n));while(n!==o&&!s);s||(s=[t.substr(0,r-1),"",!0])}return s},fc=(t,e,r)=>t.slice(e,e+r).toString("utf8").replace(/\0.*/,""),mD=(t,e,r)=>oNe(DA(t,e,r)),oNe=t=>t===null?null:new Date(t*1e3),DA=(t,e,r)=>t[e]&128?j9.parse(t.slice(e,e+r)):aNe(t,e,r),ANe=t=>isNaN(t)?null:t,aNe=(t,e,r)=>ANe(parseInt(t.slice(e,e+r).toString("utf8").replace(/\0.*$/,"").trim(),8)),lNe={12:8589934591,8:2097151},RA=(t,e,r,i)=>i===null?!1:i>lNe[r]||i<0?(j9.encode(i,t.slice(e,e+r)),!0):(cNe(t,e,r,i),!1),cNe=(t,e,r,i)=>t.write(uNe(i,r),e,r,"ascii"),uNe=(t,e)=>gNe(Math.floor(t).toString(8),e),gNe=(t,e)=>(t.length===e-1?t:new Array(e-t.length-1).join("0")+t+" ")+"\0",ED=(t,e,r,i)=>i===null?!1:RA(t,e,r,i.getTime()/1e3),fNe=new Array(156).join("\0"),hc=(t,e,r,i)=>i===null?!1:(t.write(i+fNe,e,r,"utf8"),i.length!==Buffer.byteLength(i)||i.length>r);G9.exports=Y9});var zw=E((Ilt,q9)=>{"use strict";var hNe=Cg(),pNe=require("path"),Ww=class{constructor(e,r){this.atime=e.atime||null,this.charset=e.charset||null,this.comment=e.comment||null,this.ctime=e.ctime||null,this.gid=e.gid||null,this.gname=e.gname||null,this.linkpath=e.linkpath||null,this.mtime=e.mtime||null,this.path=e.path||null,this.size=e.size||null,this.uid=e.uid||null,this.uname=e.uname||null,this.dev=e.dev||null,this.ino=e.ino||null,this.nlink=e.nlink||null,this.global=r||!1}encode(){let e=this.encodeBody();if(e==="")return null;let r=Buffer.byteLength(e),i=512*Math.ceil(1+r/512),n=Buffer.allocUnsafe(i);for(let s=0;s<512;s++)n[s]=0;new hNe({path:("PaxHeader/"+pNe.basename(this.path)).slice(0,99),mode:this.mode||420,uid:this.uid||null,gid:this.gid||null,size:r,mtime:this.mtime||null,type:this.global?"GlobalExtendedHeader":"ExtendedHeader",linkpath:"",uname:this.uname||"",gname:this.gname||"",devmaj:0,devmin:0,atime:this.atime||null,ctime:this.ctime||null}).encode(n),n.write(e,512,r,"utf8");for(let s=r+512;s=Math.pow(10,s)&&(s+=1),s+n+i}};Ww.parse=(t,e,r)=>new Ww(dNe(CNe(t),e),r);var dNe=(t,e)=>e?Object.keys(t).reduce((r,i)=>(r[i]=t[i],r),e):t,CNe=t=>t.replace(/\n$/,"").split(` -`).reduce(mNe,Object.create(null)),mNe=(t,e)=>{let r=parseInt(e,10);if(r!==Buffer.byteLength(e)+1)return t;e=e.substr((r+" ").length);let i=e.split("="),n=i.shift().replace(/^SCHILY\.(dev|ino|nlink)/,"$1");if(!n)return t;let s=i.join("=");return t[n]=/^([A-Z]+\.)?([mac]|birth|creation)time$/.test(n)?new Date(s*1e3):/^[0-9]+$/.test(s)?+s:s,t};q9.exports=Ww});var Vw=E((ylt,J9)=>{"use strict";J9.exports=t=>class extends t{warn(e,r,i={}){this.file&&(i.file=this.file),this.cwd&&(i.cwd=this.cwd),i.code=r instanceof Error&&r.code||e,i.tarCode=e,!this.strict&&i.recoverable!==!1?(r instanceof Error&&(i=Object.assign(r,i),r=r.message),this.emit("warn",i.tarCode,r,i)):r instanceof Error?this.emit("error",Object.assign(r,i)):this.emit("error",Object.assign(new Error(`${e}: ${r}`),i))}}});var yD=E((wlt,W9)=>{"use strict";var _w=["|","<",">","?",":"],ID=_w.map(t=>String.fromCharCode(61440+t.charCodeAt(0))),ENe=new Map(_w.map((t,e)=>[t,ID[e]])),INe=new Map(ID.map((t,e)=>[t,_w[e]]));W9.exports={encode:t=>_w.reduce((e,r)=>e.split(r).join(ENe.get(r)),t),decode:t=>ID.reduce((e,r)=>e.split(r).join(INe.get(r)),t)}});var V9=E((Blt,z9)=>{"use strict";z9.exports=(t,e,r)=>(t&=4095,r&&(t=(t|384)&~18),e&&(t&256&&(t|=64),t&32&&(t|=8),t&4&&(t|=1)),t)});var xD=E((xlt,_9)=>{"use strict";var X9=hg(),Z9=zw(),$9=Cg(),Qlt=id(),bo=require("fs"),mg=require("path"),blt=rd(),yNe=16*1024*1024,eV=Symbol("process"),tV=Symbol("file"),rV=Symbol("directory"),wD=Symbol("symlink"),iV=Symbol("hardlink"),nd=Symbol("header"),Xw=Symbol("read"),BD=Symbol("lstat"),Zw=Symbol("onlstat"),QD=Symbol("onread"),bD=Symbol("onreadlink"),vD=Symbol("openfile"),SD=Symbol("onopenfile"),pc=Symbol("close"),$w=Symbol("mode"),nV=Vw(),wNe=yD(),sV=V9(),eB=nV(class extends X9{constructor(e,r){if(r=r||{},super(r),typeof e!="string")throw new TypeError("path is required");this.path=e,this.portable=!!r.portable,this.myuid=process.getuid&&process.getuid(),this.myuser=process.env.USER||"",this.maxReadSize=r.maxReadSize||yNe,this.linkCache=r.linkCache||new Map,this.statCache=r.statCache||new Map,this.preservePaths=!!r.preservePaths,this.cwd=r.cwd||process.cwd(),this.strict=!!r.strict,this.noPax=!!r.noPax,this.noMtime=!!r.noMtime,this.mtime=r.mtime||null,typeof r.onwarn=="function"&&this.on("warn",r.onwarn);let i=!1;if(!this.preservePaths&&mg.win32.isAbsolute(e)){let n=mg.win32.parse(e);this.path=e.substr(n.root.length),i=n.root}this.win32=!!r.win32||process.platform==="win32",this.win32&&(this.path=wNe.decode(this.path.replace(/\\/g,"/")),e=e.replace(/\\/g,"/")),this.absolute=r.absolute||mg.resolve(this.cwd,e),this.path===""&&(this.path="./"),i&&this.warn("TAR_ENTRY_INFO",`stripping ${i} from absolute path`,{entry:this,path:i+this.path}),this.statCache.has(this.absolute)?this[Zw](this.statCache.get(this.absolute)):this[BD]()}[BD](){bo.lstat(this.absolute,(e,r)=>{if(e)return this.emit("error",e);this[Zw](r)})}[Zw](e){this.statCache.set(this.absolute,e),this.stat=e,e.isFile()||(e.size=0),this.type=BNe(e),this.emit("stat",e),this[eV]()}[eV](){switch(this.type){case"File":return this[tV]();case"Directory":return this[rV]();case"SymbolicLink":return this[wD]();default:return this.end()}}[$w](e){return sV(e,this.type==="Directory",this.portable)}[nd](){this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.header=new $9({path:this.path,linkpath:this.linkpath,mode:this[$w](this.stat.mode),uid:this.portable?null:this.stat.uid,gid:this.portable?null:this.stat.gid,size:this.stat.size,mtime:this.noMtime?null:this.mtime||this.stat.mtime,type:this.type,uname:this.portable?null:this.stat.uid===this.myuid?this.myuser:"",atime:this.portable?null:this.stat.atime,ctime:this.portable?null:this.stat.ctime}),this.header.encode()&&!this.noPax&&this.write(new Z9({atime:this.portable?null:this.header.atime,ctime:this.portable?null:this.header.ctime,gid:this.portable?null:this.header.gid,mtime:this.noMtime?null:this.mtime||this.header.mtime,path:this.path,linkpath:this.linkpath,size:this.header.size,uid:this.portable?null:this.header.uid,uname:this.portable?null:this.header.uname,dev:this.portable?null:this.stat.dev,ino:this.portable?null:this.stat.ino,nlink:this.portable?null:this.stat.nlink}).encode()),this.write(this.header.block)}[rV](){this.path.substr(-1)!=="/"&&(this.path+="/"),this.stat.size=0,this[nd](),this.end()}[wD](){bo.readlink(this.absolute,(e,r)=>{if(e)return this.emit("error",e);this[bD](r)})}[bD](e){this.linkpath=e.replace(/\\/g,"/"),this[nd](),this.end()}[iV](e){this.type="Link",this.linkpath=mg.relative(this.cwd,e).replace(/\\/g,"/"),this.stat.size=0,this[nd](),this.end()}[tV](){if(this.stat.nlink>1){let e=this.stat.dev+":"+this.stat.ino;if(this.linkCache.has(e)){let r=this.linkCache.get(e);if(r.indexOf(this.cwd)===0)return this[iV](r)}this.linkCache.set(e,this.absolute)}if(this[nd](),this.stat.size===0)return this.end();this[vD]()}[vD](){bo.open(this.absolute,"r",(e,r)=>{if(e)return this.emit("error",e);this[SD](r)})}[SD](e){let r=512*Math.ceil(this.stat.size/512),i=Math.min(r,this.maxReadSize),n=Buffer.allocUnsafe(i);this[Xw](e,n,0,n.length,0,this.stat.size,r)}[Xw](e,r,i,n,s,o,a){bo.read(e,r,i,n,s,(l,c)=>{if(l)return this[pc](e,()=>this.emit("error",l));this[QD](e,r,i,n,s,o,a,c)})}[pc](e,r){bo.close(e,r)}[QD](e,r,i,n,s,o,a,l){if(l<=0&&o>0){let u=new Error("encountered unexpected EOF");return u.path=this.absolute,u.syscall="read",u.code="EOF",this[pc](e,()=>this.emit("error",u))}if(l>o){let u=new Error("did not encounter expected EOF");return u.path=this.absolute,u.syscall="read",u.code="EOF",this[pc](e,()=>this.emit("error",u))}if(l===o)for(let u=l;uu?this.emit("error",u):this.end());i>=n&&(r=Buffer.allocUnsafe(n),i=0),n=r.length-i,this[Xw](e,r,i,n,s,o,a)}}),oV=class extends eB{constructor(e,r){super(e,r)}[BD](){this[Zw](bo.lstatSync(this.absolute))}[wD](){this[bD](bo.readlinkSync(this.absolute))}[vD](){this[SD](bo.openSync(this.absolute,"r"))}[Xw](e,r,i,n,s,o,a){let l=!0;try{let c=bo.readSync(e,r,i,n,s);this[QD](e,r,i,n,s,o,a,c),l=!1}finally{if(l)try{this[pc](e,()=>{})}catch(c){}}}[pc](e,r){bo.closeSync(e),r()}},QNe=nV(class extends X9{constructor(e,r){r=r||{},super(r),this.preservePaths=!!r.preservePaths,this.portable=!!r.portable,this.strict=!!r.strict,this.noPax=!!r.noPax,this.noMtime=!!r.noMtime,this.readEntry=e,this.type=e.type,this.type==="Directory"&&this.portable&&(this.noMtime=!0),this.path=e.path,this.mode=this[$w](e.mode),this.uid=this.portable?null:e.uid,this.gid=this.portable?null:e.gid,this.uname=this.portable?null:e.uname,this.gname=this.portable?null:e.gname,this.size=e.size,this.mtime=this.noMtime?null:r.mtime||e.mtime,this.atime=this.portable?null:e.atime,this.ctime=this.portable?null:e.ctime,this.linkpath=e.linkpath,typeof r.onwarn=="function"&&this.on("warn",r.onwarn);let i=!1;if(mg.isAbsolute(this.path)&&!this.preservePaths){let n=mg.parse(this.path);i=n.root,this.path=this.path.substr(n.root.length)}this.remain=e.size,this.blockRemain=e.startBlockSize,this.header=new $9({path:this.path,linkpath:this.linkpath,mode:this.mode,uid:this.portable?null:this.uid,gid:this.portable?null:this.gid,size:this.size,mtime:this.noMtime?null:this.mtime,type:this.type,uname:this.portable?null:this.uname,atime:this.portable?null:this.atime,ctime:this.portable?null:this.ctime}),i&&this.warn("TAR_ENTRY_INFO",`stripping ${i} from absolute path`,{entry:this,path:i+this.path}),this.header.encode()&&!this.noPax&&super.write(new Z9({atime:this.portable?null:this.atime,ctime:this.portable?null:this.ctime,gid:this.portable?null:this.gid,mtime:this.noMtime?null:this.mtime,path:this.path,linkpath:this.linkpath,size:this.size,uid:this.portable?null:this.uid,uname:this.portable?null:this.uname,dev:this.portable?null:this.readEntry.dev,ino:this.portable?null:this.readEntry.ino,nlink:this.portable?null:this.readEntry.nlink}).encode()),super.write(this.header.block),e.pipe(this)}[$w](e){return sV(e,this.type==="Directory",this.portable)}write(e){let r=e.length;if(r>this.blockRemain)throw new Error("writing more to entry than is appropriate");return this.blockRemain-=r,super.write(e)}end(){return this.blockRemain&&this.write(Buffer.alloc(this.blockRemain)),super.end()}});eB.Sync=oV;eB.Tar=QNe;var BNe=t=>t.isFile()?"File":t.isDirectory()?"Directory":t.isSymbolicLink()?"SymbolicLink":"Unsupported";_9.exports=eB});var AB=E((Plt,aV)=>{"use strict";var kD=class{constructor(e,r){this.path=e||"./",this.absolute=r,this.entry=null,this.stat=null,this.readdir=null,this.pending=!1,this.ignore=!1,this.piped=!1}},bNe=hg(),vNe=fD(),SNe=id(),PD=xD(),xNe=PD.Sync,kNe=PD.Tar,PNe=Rh(),AV=Buffer.alloc(1024),tB=Symbol("onStat"),rB=Symbol("ended"),vo=Symbol("queue"),Eg=Symbol("current"),dc=Symbol("process"),iB=Symbol("processing"),lV=Symbol("processJob"),So=Symbol("jobs"),DD=Symbol("jobDone"),nB=Symbol("addFSEntry"),cV=Symbol("addTarEntry"),RD=Symbol("stat"),FD=Symbol("readdir"),sB=Symbol("onreaddir"),oB=Symbol("pipe"),uV=Symbol("entry"),ND=Symbol("entryOpt"),LD=Symbol("writeEntryClass"),gV=Symbol("write"),TD=Symbol("ondrain"),aB=require("fs"),fV=require("path"),DNe=Vw(),MD=DNe(class extends bNe{constructor(e){super(e);e=e||Object.create(null),this.opt=e,this.file=e.file||"",this.cwd=e.cwd||process.cwd(),this.maxReadSize=e.maxReadSize,this.preservePaths=!!e.preservePaths,this.strict=!!e.strict,this.noPax=!!e.noPax,this.prefix=(e.prefix||"").replace(/(\\|\/)+$/,""),this.linkCache=e.linkCache||new Map,this.statCache=e.statCache||new Map,this.readdirCache=e.readdirCache||new Map,this[LD]=PD,typeof e.onwarn=="function"&&this.on("warn",e.onwarn),this.portable=!!e.portable,this.zip=null,e.gzip?(typeof e.gzip!="object"&&(e.gzip={}),this.portable&&(e.gzip.portable=!0),this.zip=new vNe.Gzip(e.gzip),this.zip.on("data",r=>super.write(r)),this.zip.on("end",r=>super.end()),this.zip.on("drain",r=>this[TD]()),this.on("resume",r=>this.zip.resume())):this.on("drain",this[TD]),this.noDirRecurse=!!e.noDirRecurse,this.follow=!!e.follow,this.noMtime=!!e.noMtime,this.mtime=e.mtime||null,this.filter=typeof e.filter=="function"?e.filter:r=>!0,this[vo]=new PNe,this[So]=0,this.jobs=+e.jobs||4,this[iB]=!1,this[rB]=!1}[gV](e){return super.write(e)}add(e){return this.write(e),this}end(e){return e&&this.write(e),this[rB]=!0,this[dc](),this}write(e){if(this[rB])throw new Error("write after end");return e instanceof SNe?this[cV](e):this[nB](e),this.flowing}[cV](e){let r=fV.resolve(this.cwd,e.path);if(this.prefix&&(e.path=this.prefix+"/"+e.path.replace(/^\.(\/+|$)/,"")),!this.filter(e.path,e))e.resume();else{let i=new kD(e.path,r,!1);i.entry=new kNe(e,this[ND](i)),i.entry.on("end",n=>this[DD](i)),this[So]+=1,this[vo].push(i)}this[dc]()}[nB](e){let r=fV.resolve(this.cwd,e);this.prefix&&(e=this.prefix+"/"+e.replace(/^\.(\/+|$)/,"")),this[vo].push(new kD(e,r)),this[dc]()}[RD](e){e.pending=!0,this[So]+=1;let r=this.follow?"stat":"lstat";aB[r](e.absolute,(i,n)=>{e.pending=!1,this[So]-=1,i?this.emit("error",i):this[tB](e,n)})}[tB](e,r){this.statCache.set(e.absolute,r),e.stat=r,this.filter(e.path,r)||(e.ignore=!0),this[dc]()}[FD](e){e.pending=!0,this[So]+=1,aB.readdir(e.absolute,(r,i)=>{if(e.pending=!1,this[So]-=1,r)return this.emit("error",r);this[sB](e,i)})}[sB](e,r){this.readdirCache.set(e.absolute,r),e.readdir=r,this[dc]()}[dc](){if(!this[iB]){this[iB]=!0;for(let e=this[vo].head;e!==null&&this[So]this.warn(r,i,n),noPax:this.noPax,cwd:this.cwd,absolute:e.absolute,preservePaths:this.preservePaths,maxReadSize:this.maxReadSize,strict:this.strict,portable:this.portable,linkCache:this.linkCache,statCache:this.statCache,noMtime:this.noMtime,mtime:this.mtime}}[uV](e){this[So]+=1;try{return new this[LD](e.path,this[ND](e)).on("end",()=>this[DD](e)).on("error",r=>this.emit("error",r))}catch(r){this.emit("error",r)}}[TD](){this[Eg]&&this[Eg].entry&&this[Eg].entry.resume()}[oB](e){e.piped=!0,e.readdir&&e.readdir.forEach(n=>{let s=this.prefix?e.path.slice(this.prefix.length+1)||"./":e.path,o=s==="./"?"":s.replace(/\/*$/,"/");this[nB](o+n)});let r=e.entry,i=this.zip;i?r.on("data",n=>{i.write(n)||r.pause()}):r.on("data",n=>{super.write(n)||r.pause()})}pause(){return this.zip&&this.zip.pause(),super.pause()}}),hV=class extends MD{constructor(e){super(e);this[LD]=xNe}pause(){}resume(){}[RD](e){let r=this.follow?"statSync":"lstatSync";this[tB](e,aB[r](e.absolute))}[FD](e,r){this[sB](e,aB.readdirSync(e.absolute))}[oB](e){let r=e.entry,i=this.zip;e.readdir&&e.readdir.forEach(n=>{let s=this.prefix?e.path.slice(this.prefix.length+1)||"./":e.path,o=s==="./"?"":s.replace(/\/*$/,"/");this[nB](o+n)}),i?r.on("data",n=>{i.write(n)}):r.on("data",n=>{super[gV](n)})}};MD.Sync=hV;aV.exports=MD});var bg=E(sd=>{"use strict";var RNe=hg(),FNe=require("events").EventEmitter,ls=require("fs"),lB=process.binding("fs"),Dlt=lB.writeBuffers,NNe=lB.FSReqWrap||lB.FSReqCallback,Ig=Symbol("_autoClose"),xo=Symbol("_close"),od=Symbol("_ended"),Jt=Symbol("_fd"),pV=Symbol("_finished"),Cc=Symbol("_flags"),OD=Symbol("_flush"),KD=Symbol("_handleChunk"),UD=Symbol("_makeBuf"),HD=Symbol("_mode"),cB=Symbol("_needDrain"),yg=Symbol("_onerror"),wg=Symbol("_onopen"),GD=Symbol("_onread"),mc=Symbol("_onwrite"),FA=Symbol("_open"),NA=Symbol("_path"),Ec=Symbol("_pos"),ko=Symbol("_queue"),Bg=Symbol("_read"),dV=Symbol("_readSize"),LA=Symbol("_reading"),uB=Symbol("_remain"),CV=Symbol("_size"),gB=Symbol("_write"),Qg=Symbol("_writing"),fB=Symbol("_defaultFlag"),jD=class extends RNe{constructor(e,r){if(r=r||{},super(r),this.writable=!1,typeof e!="string")throw new TypeError("path must be a string");this[Jt]=typeof r.fd=="number"?r.fd:null,this[NA]=e,this[dV]=r.readSize||16*1024*1024,this[LA]=!1,this[CV]=typeof r.size=="number"?r.size:Infinity,this[uB]=this[CV],this[Ig]=typeof r.autoClose=="boolean"?r.autoClose:!0,typeof this[Jt]=="number"?this[Bg]():this[FA]()}get fd(){return this[Jt]}get path(){return this[NA]}write(){throw new TypeError("this is a readable stream")}end(){throw new TypeError("this is a readable stream")}[FA](){ls.open(this[NA],"r",(e,r)=>this[wg](e,r))}[wg](e,r){e?this[yg](e):(this[Jt]=r,this.emit("open",r),this[Bg]())}[UD](){return Buffer.allocUnsafe(Math.min(this[dV],this[uB]))}[Bg](){if(!this[LA]){this[LA]=!0;let e=this[UD]();if(e.length===0)return process.nextTick(()=>this[GD](null,0,e));ls.read(this[Jt],e,0,e.length,null,(r,i,n)=>this[GD](r,i,n))}}[GD](e,r,i){this[LA]=!1,e?this[yg](e):this[KD](r,i)&&this[Bg]()}[xo](){this[Ig]&&typeof this[Jt]=="number"&&(ls.close(this[Jt],e=>this.emit("close")),this[Jt]=null)}[yg](e){this[LA]=!0,this[xo](),this.emit("error",e)}[KD](e,r){let i=!1;return this[uB]-=e,e>0&&(i=super.write(ethis[wg](e,r))}[wg](e,r){this[fB]&&this[Cc]==="r+"&&e&&e.code==="ENOENT"?(this[Cc]="w",this[FA]()):e?this[yg](e):(this[Jt]=r,this.emit("open",r),this[OD]())}end(e,r){e&&this.write(e,r),this[od]=!0,!this[Qg]&&!this[ko].length&&typeof this[Jt]=="number"&&this[mc](null,0)}write(e,r){return typeof e=="string"&&(e=new Buffer(e,r)),this[od]?(this.emit("error",new Error("write() after end()")),!1):this[Jt]===null||this[Qg]||this[ko].length?(this[ko].push(e),this[cB]=!0,!1):(this[Qg]=!0,this[gB](e),!0)}[gB](e){ls.write(this[Jt],e,0,e.length,this[Ec],(r,i)=>this[mc](r,i))}[mc](e,r){e?this[yg](e):(this[Ec]!==null&&(this[Ec]+=r),this[ko].length?this[OD]():(this[Qg]=!1,this[od]&&!this[pV]?(this[pV]=!0,this[xo](),this.emit("finish")):this[cB]&&(this[cB]=!1,this.emit("drain"))))}[OD](){if(this[ko].length===0)this[od]&&this[mc](null,0);else if(this[ko].length===1)this[gB](this[ko].pop());else{let e=this[ko];this[ko]=[],LNe(this[Jt],e,this[Ec],(r,i)=>this[mc](r,i))}}[xo](){this[Ig]&&typeof this[Jt]=="number"&&(ls.close(this[Jt],e=>this.emit("close")),this[Jt]=null)}},EV=class extends YD{[FA](){let e;try{e=ls.openSync(this[NA],this[Cc],this[HD])}catch(r){if(this[fB]&&this[Cc]==="r+"&&r&&r.code==="ENOENT")return this[Cc]="w",this[FA]();throw r}this[wg](null,e)}[xo](){if(this[Ig]&&typeof this[Jt]=="number"){try{ls.closeSync(this[Jt])}catch(e){}this[Jt]=null,this.emit("close")}}[gB](e){try{this[mc](null,ls.writeSync(this[Jt],e,0,e.length,this[Ec]))}catch(r){this[mc](r,0)}}},LNe=(t,e,r,i)=>{let n=(o,a)=>i(o,a,e),s=new NNe;s.oncomplete=n,lB.writeBuffers(t,e,r,s)};sd.ReadStream=jD;sd.ReadStreamSync=mV;sd.WriteStream=YD;sd.WriteStreamSync=EV});var ld=E((Llt,IV)=>{"use strict";var TNe=Vw(),Flt=require("path"),MNe=Cg(),ONe=require("events"),KNe=Rh(),UNe=1024*1024,HNe=id(),yV=zw(),GNe=fD(),qD=Buffer.from([31,139]),cs=Symbol("state"),Ic=Symbol("writeEntry"),xa=Symbol("readEntry"),JD=Symbol("nextEntry"),wV=Symbol("processEntry"),us=Symbol("extendedHeader"),ad=Symbol("globalExtendedHeader"),TA=Symbol("meta"),BV=Symbol("emitMeta"),Ar=Symbol("buffer"),ka=Symbol("queue"),yc=Symbol("ended"),QV=Symbol("emittedEnd"),wc=Symbol("emit"),Qn=Symbol("unzip"),hB=Symbol("consumeChunk"),pB=Symbol("consumeChunkSub"),WD=Symbol("consumeBody"),bV=Symbol("consumeMeta"),vV=Symbol("consumeHeader"),dB=Symbol("consuming"),zD=Symbol("bufferConcat"),VD=Symbol("maybeEnd"),Ad=Symbol("writing"),MA=Symbol("aborted"),CB=Symbol("onDone"),Bc=Symbol("sawValidEntry"),mB=Symbol("sawNullBlock"),EB=Symbol("sawEOF"),jNe=t=>!0;IV.exports=TNe(class extends ONe{constructor(e){e=e||{},super(e),this.file=e.file||"",this[Bc]=null,this.on(CB,r=>{(this[cs]==="begin"||this[Bc]===!1)&&this.warn("TAR_BAD_ARCHIVE","Unrecognized archive format")}),e.ondone?this.on(CB,e.ondone):this.on(CB,r=>{this.emit("prefinish"),this.emit("finish"),this.emit("end"),this.emit("close")}),this.strict=!!e.strict,this.maxMetaEntrySize=e.maxMetaEntrySize||UNe,this.filter=typeof e.filter=="function"?e.filter:jNe,this.writable=!0,this.readable=!1,this[ka]=new KNe,this[Ar]=null,this[xa]=null,this[Ic]=null,this[cs]="begin",this[TA]="",this[us]=null,this[ad]=null,this[yc]=!1,this[Qn]=null,this[MA]=!1,this[mB]=!1,this[EB]=!1,typeof e.onwarn=="function"&&this.on("warn",e.onwarn),typeof e.onentry=="function"&&this.on("entry",e.onentry)}[vV](e,r){this[Bc]===null&&(this[Bc]=!1);let i;try{i=new MNe(e,r,this[us],this[ad])}catch(n){return this.warn("TAR_ENTRY_INVALID",n)}if(i.nullBlock)this[mB]?(this[EB]=!0,this[cs]==="begin"&&(this[cs]="header"),this[wc]("eof")):(this[mB]=!0,this[wc]("nullBlock"));else if(this[mB]=!1,!i.cksumValid)this.warn("TAR_ENTRY_INVALID","checksum failure",{header:i});else if(!i.path)this.warn("TAR_ENTRY_INVALID","path is required",{header:i});else{let n=i.type;if(/^(Symbolic)?Link$/.test(n)&&!i.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath required",{header:i});else if(!/^(Symbolic)?Link$/.test(n)&&i.linkpath)this.warn("TAR_ENTRY_INVALID","linkpath forbidden",{header:i});else{let s=this[Ic]=new HNe(i,this[us],this[ad]);if(!this[Bc])if(s.remain){let o=()=>{s.invalid||(this[Bc]=!0)};s.on("end",o)}else this[Bc]=!0;s.meta?s.size>this.maxMetaEntrySize?(s.ignore=!0,this[wc]("ignoredEntry",s),this[cs]="ignore",s.resume()):s.size>0&&(this[TA]="",s.on("data",o=>this[TA]+=o),this[cs]="meta"):(this[us]=null,s.ignore=s.ignore||!this.filter(s.path,s),s.ignore?(this[wc]("ignoredEntry",s),this[cs]=s.remain?"ignore":"header",s.resume()):(s.remain?this[cs]="body":(this[cs]="header",s.end()),this[xa]?this[ka].push(s):(this[ka].push(s),this[JD]())))}}}[wV](e){let r=!0;return e?Array.isArray(e)?this.emit.apply(this,e):(this[xa]=e,this.emit("entry",e),e.emittedEnd||(e.on("end",i=>this[JD]()),r=!1)):(this[xa]=null,r=!1),r}[JD](){do;while(this[wV](this[ka].shift()));if(!this[ka].length){let e=this[xa];!e||e.flowing||e.size===e.remain?this[Ad]||this.emit("drain"):e.once("drain",i=>this.emit("drain"))}}[WD](e,r){let i=this[Ic],n=i.blockRemain,s=n>=e.length&&r===0?e:e.slice(r,r+n);return i.write(s),i.blockRemain||(this[cs]="header",this[Ic]=null,i.end()),s.length}[bV](e,r){let i=this[Ic],n=this[WD](e,r);return this[Ic]||this[BV](i),n}[wc](e,r,i){!this[ka].length&&!this[xa]?this.emit(e,r,i):this[ka].push([e,r,i])}[BV](e){switch(this[wc]("meta",this[TA]),e.type){case"ExtendedHeader":case"OldExtendedHeader":this[us]=yV.parse(this[TA],this[us],!1);break;case"GlobalExtendedHeader":this[ad]=yV.parse(this[TA],this[ad],!0);break;case"NextFileHasLongPath":case"OldGnuLongPath":this[us]=this[us]||Object.create(null),this[us].path=this[TA].replace(/\0.*/,"");break;case"NextFileHasLongLinkpath":this[us]=this[us]||Object.create(null),this[us].linkpath=this[TA].replace(/\0.*/,"");break;default:throw new Error("unknown meta: "+e.type)}}abort(e){this[MA]=!0,this.emit("abort",e),this.warn("TAR_ABORT",e,{recoverable:!1})}write(e){if(this[MA])return;if(this[Qn]===null&&e){if(this[Ar]&&(e=Buffer.concat([this[Ar],e]),this[Ar]=null),e.lengththis[hB](s)),this[Qn].on("error",s=>this.abort(s)),this[Qn].on("end",s=>{this[yc]=!0,this[hB]()}),this[Ad]=!0;let n=this[Qn][i?"end":"write"](e);return this[Ad]=!1,n}}this[Ad]=!0,this[Qn]?this[Qn].write(e):this[hB](e),this[Ad]=!1;let r=this[ka].length?!1:this[xa]?this[xa].flowing:!0;return!r&&!this[ka].length&&this[xa].once("drain",i=>this.emit("drain")),r}[zD](e){e&&!this[MA]&&(this[Ar]=this[Ar]?Buffer.concat([this[Ar],e]):e)}[VD](){if(this[yc]&&!this[QV]&&!this[MA]&&!this[dB]){this[QV]=!0;let e=this[Ic];if(e&&e.blockRemain){let r=this[Ar]?this[Ar].length:0;this.warn("TAR_BAD_ARCHIVE",`Truncated input (needed ${e.blockRemain} more bytes, only ${r} available)`,{entry:e}),this[Ar]&&e.write(this[Ar]),e.end()}this[wc](CB)}}[hB](e){if(this[dB])this[zD](e);else if(!e&&!this[Ar])this[VD]();else{if(this[dB]=!0,this[Ar]){this[zD](e);let r=this[Ar];this[Ar]=null,this[pB](r)}else this[pB](e);for(;this[Ar]&&this[Ar].length>=512&&!this[MA]&&!this[EB];){let r=this[Ar];this[Ar]=null,this[pB](r)}this[dB]=!1}(!this[Ar]||this[yc])&&this[VD]()}[pB](e){let r=0,i=e.length;for(;r+512<=i&&!this[MA]&&!this[EB];)switch(this[cs]){case"begin":case"header":this[vV](e,r),r+=512;break;case"ignore":case"body":r+=this[WD](e,r);break;case"meta":r+=this[bV](e,r);break;default:throw new Error("invalid state: "+this[cs])}r{"use strict";var YNe=fg(),xV=ld(),vg=require("fs"),qNe=bg(),kV=require("path"),Tlt=SV.exports=(t,e,r)=>{typeof t=="function"?(r=t,e=null,t={}):Array.isArray(t)&&(e=t,t={}),typeof e=="function"&&(r=e,e=null),e?e=Array.from(e):e=[];let i=YNe(t);if(i.sync&&typeof r=="function")throw new TypeError("callback not supported for sync tar functions");if(!i.file&&typeof r=="function")throw new TypeError("callback only supported with file option");return e.length&&WNe(i,e),i.noResume||JNe(i),i.file&&i.sync?zNe(i):i.file?VNe(i,r):PV(i)},JNe=t=>{let e=t.onentry;t.onentry=e?r=>{e(r),r.resume()}:r=>r.resume()},WNe=(t,e)=>{let r=new Map(e.map(s=>[s.replace(/\/+$/,""),!0])),i=t.filter,n=(s,o)=>{let a=o||kV.parse(s).root||".",l=s===a?!1:r.has(s)?r.get(s):n(kV.dirname(s),a);return r.set(s,l),l};t.filter=i?(s,o)=>i(s,o)&&n(s.replace(/\/+$/,"")):s=>n(s.replace(/\/+$/,""))},zNe=t=>{let e=PV(t),r=t.file,i=!0,n;try{let s=vg.statSync(r),o=t.maxReadSize||16*1024*1024;if(s.size{let r=new xV(t),i=t.maxReadSize||16*1024*1024,n=t.file,s=new Promise((o,a)=>{r.on("error",a),r.on("end",o),vg.stat(n,(l,c)=>{if(l)a(l);else{let u=new qNe.ReadStream(n,{readSize:i,size:c.size});u.on("error",a),u.pipe(r)}})});return e?s.then(e,e):s},PV=t=>new xV(t)});var TV=E((Ult,DV)=>{"use strict";var _Ne=fg(),yB=AB(),Olt=require("fs"),RV=bg(),FV=IB(),NV=require("path"),Klt=DV.exports=(t,e,r)=>{if(typeof e=="function"&&(r=e),Array.isArray(t)&&(e=t,t={}),!e||!Array.isArray(e)||!e.length)throw new TypeError("no files or directories specified");e=Array.from(e);let i=_Ne(t);if(i.sync&&typeof r=="function")throw new TypeError("callback not supported for sync tar functions");if(!i.file&&typeof r=="function")throw new TypeError("callback only supported with file option");return i.file&&i.sync?XNe(i,e):i.file?ZNe(i,e,r):i.sync?$Ne(i,e):eLe(i,e)},XNe=(t,e)=>{let r=new yB.Sync(t),i=new RV.WriteStreamSync(t.file,{mode:t.mode||438});r.pipe(i),LV(r,e)},ZNe=(t,e,r)=>{let i=new yB(t),n=new RV.WriteStream(t.file,{mode:t.mode||438});i.pipe(n);let s=new Promise((o,a)=>{n.on("error",a),n.on("close",o),i.on("error",a)});return _D(i,e),r?s.then(r,r):s},LV=(t,e)=>{e.forEach(r=>{r.charAt(0)==="@"?FV({file:NV.resolve(t.cwd,r.substr(1)),sync:!0,noResume:!0,onentry:i=>t.add(i)}):t.add(r)}),t.end()},_D=(t,e)=>{for(;e.length;){let r=e.shift();if(r.charAt(0)==="@")return FV({file:NV.resolve(t.cwd,r.substr(1)),noResume:!0,onentry:i=>t.add(i)}).then(i=>_D(t,e));t.add(r)}t.end()},$Ne=(t,e)=>{let r=new yB.Sync(t);return LV(r,e),r},eLe=(t,e)=>{let r=new yB(t);return _D(r,e),r}});var XD=E((jlt,MV)=>{"use strict";var tLe=fg(),OV=AB(),Hlt=ld(),gs=require("fs"),KV=bg(),UV=IB(),HV=require("path"),GV=Cg(),Glt=MV.exports=(t,e,r)=>{let i=tLe(t);if(!i.file)throw new TypeError("file is required");if(i.gzip)throw new TypeError("cannot append to compressed archives");if(!e||!Array.isArray(e)||!e.length)throw new TypeError("no files or directories specified");return e=Array.from(e),i.sync?rLe(i,e):iLe(i,e,r)},rLe=(t,e)=>{let r=new OV.Sync(t),i=!0,n,s;try{try{n=gs.openSync(t.file,"r+")}catch(l){if(l.code==="ENOENT")n=gs.openSync(t.file,"w+");else throw l}let o=gs.fstatSync(n),a=Buffer.alloc(512);e:for(s=0;so.size)break;s+=c,t.mtimeCache&&t.mtimeCache.set(l.path,l.mtime)}i=!1,nLe(t,r,s,n,e)}finally{if(i)try{gs.closeSync(n)}catch(o){}}},nLe=(t,e,r,i,n)=>{let s=new KV.WriteStreamSync(t.file,{fd:i,start:r});e.pipe(s),sLe(e,n)},iLe=(t,e,r)=>{e=Array.from(e);let i=new OV(t),n=(o,a,l)=>{let c=(p,d)=>{p?gs.close(o,m=>l(p)):l(null,d)},u=0;if(a===0)return c(null,0);let g=0,f=Buffer.alloc(512),h=(p,d)=>{if(p)return c(p);if(g+=d,g<512&&d)return gs.read(o,f,g,f.length-g,u+g,h);if(u===0&&f[0]===31&&f[1]===139)return c(new Error("cannot append to compressed archives"));if(g<512)return c(null,u);let m=new GV(f);if(!m.cksumValid)return c(null,u);let I=512*Math.ceil(m.size/512);if(u+I+512>a||(u+=I+512,u>=a))return c(null,u);t.mtimeCache&&t.mtimeCache.set(m.path,m.mtime),g=0,gs.read(o,f,0,512,u,h)};gs.read(o,f,0,512,u,h)},s=new Promise((o,a)=>{i.on("error",a);let l="r+",c=(u,g)=>{if(u&&u.code==="ENOENT"&&l==="r+")return l="w+",gs.open(t.file,l,c);if(u)return a(u);gs.fstat(g,(f,h)=>{if(f)return a(f);n(g,h.size,(p,d)=>{if(p)return a(p);let m=new KV.WriteStream(t.file,{fd:g,start:d});i.pipe(m),m.on("error",a),m.on("close",o),jV(i,e)})})};gs.open(t.file,l,c)});return r?s.then(r,r):s},sLe=(t,e)=>{e.forEach(r=>{r.charAt(0)==="@"?UV({file:HV.resolve(t.cwd,r.substr(1)),sync:!0,noResume:!0,onentry:i=>t.add(i)}):t.add(r)}),t.end()},jV=(t,e)=>{for(;e.length;){let r=e.shift();if(r.charAt(0)==="@")return UV({file:HV.resolve(t.cwd,r.substr(1)),noResume:!0,onentry:i=>t.add(i)}).then(i=>jV(t,e));t.add(r)}t.end()}});var qV=E((qlt,YV)=>{"use strict";var oLe=fg(),aLe=XD(),Ylt=YV.exports=(t,e,r)=>{let i=oLe(t);if(!i.file)throw new TypeError("file is required");if(i.gzip)throw new TypeError("cannot append to compressed archives");if(!e||!Array.isArray(e)||!e.length)throw new TypeError("no files or directories specified");return e=Array.from(e),ALe(i),aLe(i,e,r)},ALe=t=>{let e=t.filter;t.mtimeCache||(t.mtimeCache=new Map),t.filter=e?(r,i)=>e(r,i)&&!(t.mtimeCache.get(r)>i.mtime):(r,i)=>!(t.mtimeCache.get(r)>i.mtime)}});var zV=E((Jlt,JV)=>{var{promisify:WV}=require("util"),OA=require("fs"),lLe=t=>{if(!t)t={mode:511,fs:OA};else if(typeof t=="object")t=P({mode:511,fs:OA},t);else if(typeof t=="number")t={mode:t,fs:OA};else if(typeof t=="string")t={mode:parseInt(t,8),fs:OA};else throw new TypeError("invalid options argument");return t.mkdir=t.mkdir||t.fs.mkdir||OA.mkdir,t.mkdirAsync=WV(t.mkdir),t.stat=t.stat||t.fs.stat||OA.stat,t.statAsync=WV(t.stat),t.statSync=t.statSync||t.fs.statSync||OA.statSync,t.mkdirSync=t.mkdirSync||t.fs.mkdirSync||OA.mkdirSync,t};JV.exports=lLe});var _V=E((Wlt,VV)=>{var cLe=process.env.__TESTING_MKDIRP_PLATFORM__||process.platform,{resolve:uLe,parse:gLe}=require("path"),fLe=t=>{if(/\0/.test(t))throw Object.assign(new TypeError("path must be a string without null bytes"),{path:t,code:"ERR_INVALID_ARG_VALUE"});if(t=uLe(t),cLe==="win32"){let e=/[*|"<>?:]/,{root:r}=gLe(t);if(e.test(t.substr(r.length)))throw Object.assign(new Error("Illegal characters in path."),{path:t,code:"EINVAL"})}return t};VV.exports=fLe});var t7=E((zlt,XV)=>{var{dirname:ZV}=require("path"),$V=(t,e,r=void 0)=>r===e?Promise.resolve():t.statAsync(e).then(i=>i.isDirectory()?r:void 0,i=>i.code==="ENOENT"?$V(t,ZV(e),e):void 0),e7=(t,e,r=void 0)=>{if(r!==e)try{return t.statSync(e).isDirectory()?r:void 0}catch(i){return i.code==="ENOENT"?e7(t,ZV(e),e):void 0}};XV.exports={findMade:$V,findMadeSync:e7}});var eR=E((Vlt,r7)=>{var{dirname:i7}=require("path"),ZD=(t,e,r)=>{e.recursive=!1;let i=i7(t);return i===t?e.mkdirAsync(t,e).catch(n=>{if(n.code!=="EISDIR")throw n}):e.mkdirAsync(t,e).then(()=>r||t,n=>{if(n.code==="ENOENT")return ZD(i,e).then(s=>ZD(t,e,s));if(n.code!=="EEXIST"&&n.code!=="EROFS")throw n;return e.statAsync(t).then(s=>{if(s.isDirectory())return r;throw n},()=>{throw n})})},$D=(t,e,r)=>{let i=i7(t);if(e.recursive=!1,i===t)try{return e.mkdirSync(t,e)}catch(n){if(n.code!=="EISDIR")throw n;return}try{return e.mkdirSync(t,e),r||t}catch(n){if(n.code==="ENOENT")return $D(t,e,$D(i,e,r));if(n.code!=="EEXIST"&&n.code!=="EROFS")throw n;try{if(!e.statSync(t).isDirectory())throw n}catch(s){throw n}}};r7.exports={mkdirpManual:ZD,mkdirpManualSync:$D}});var o7=E((_lt,n7)=>{var{dirname:s7}=require("path"),{findMade:hLe,findMadeSync:pLe}=t7(),{mkdirpManual:dLe,mkdirpManualSync:CLe}=eR(),mLe=(t,e)=>(e.recursive=!0,s7(t)===t?e.mkdirAsync(t,e):hLe(e,t).then(i=>e.mkdirAsync(t,e).then(()=>i).catch(n=>{if(n.code==="ENOENT")return dLe(t,e);throw n}))),ELe=(t,e)=>{if(e.recursive=!0,s7(t)===t)return e.mkdirSync(t,e);let i=pLe(e,t);try{return e.mkdirSync(t,e),i}catch(n){if(n.code==="ENOENT")return CLe(t,e);throw n}};n7.exports={mkdirpNative:mLe,mkdirpNativeSync:ELe}});var c7=E((Xlt,a7)=>{var A7=require("fs"),ILe=process.env.__TESTING_MKDIRP_NODE_VERSION__||process.version,tR=ILe.replace(/^v/,"").split("."),l7=+tR[0]>10||+tR[0]==10&&+tR[1]>=12,yLe=l7?t=>t.mkdir===A7.mkdir:()=>!1,wLe=l7?t=>t.mkdirSync===A7.mkdirSync:()=>!1;a7.exports={useNative:yLe,useNativeSync:wLe}});var d7=E((Zlt,u7)=>{var Sg=zV(),xg=_V(),{mkdirpNative:g7,mkdirpNativeSync:f7}=o7(),{mkdirpManual:h7,mkdirpManualSync:p7}=eR(),{useNative:BLe,useNativeSync:QLe}=c7(),kg=(t,e)=>(t=xg(t),e=Sg(e),BLe(e)?g7(t,e):h7(t,e)),bLe=(t,e)=>(t=xg(t),e=Sg(e),QLe(e)?f7(t,e):p7(t,e));kg.sync=bLe;kg.native=(t,e)=>g7(xg(t),Sg(e));kg.manual=(t,e)=>h7(xg(t),Sg(e));kg.nativeSync=(t,e)=>f7(xg(t),Sg(e));kg.manualSync=(t,e)=>p7(xg(t),Sg(e));u7.exports=kg});var B7=E(($lt,C7)=>{"use strict";var fs=require("fs"),Qc=require("path"),vLe=fs.lchown?"lchown":"chown",SLe=fs.lchownSync?"lchownSync":"chownSync",m7=fs.lchown&&!process.version.match(/v1[1-9]+\./)&&!process.version.match(/v10\.[6-9]/),E7=(t,e,r)=>{try{return fs[SLe](t,e,r)}catch(i){if(i.code!=="ENOENT")throw i}},xLe=(t,e,r)=>{try{return fs.chownSync(t,e,r)}catch(i){if(i.code!=="ENOENT")throw i}},kLe=m7?(t,e,r,i)=>n=>{!n||n.code!=="EISDIR"?i(n):fs.chown(t,e,r,i)}:(t,e,r,i)=>i,rR=m7?(t,e,r)=>{try{return E7(t,e,r)}catch(i){if(i.code!=="EISDIR")throw i;xLe(t,e,r)}}:(t,e,r)=>E7(t,e,r),PLe=process.version,I7=(t,e,r)=>fs.readdir(t,e,r),DLe=(t,e)=>fs.readdirSync(t,e);/^v4\./.test(PLe)&&(I7=(t,e,r)=>fs.readdir(t,r));var wB=(t,e,r,i)=>{fs[vLe](t,e,r,kLe(t,e,r,n=>{i(n&&n.code!=="ENOENT"?n:null)}))},y7=(t,e,r,i,n)=>{if(typeof e=="string")return fs.lstat(Qc.resolve(t,e),(s,o)=>{if(s)return n(s.code!=="ENOENT"?s:null);o.name=e,y7(t,o,r,i,n)});if(e.isDirectory())iR(Qc.resolve(t,e.name),r,i,s=>{if(s)return n(s);let o=Qc.resolve(t,e.name);wB(o,r,i,n)});else{let s=Qc.resolve(t,e.name);wB(s,r,i,n)}},iR=(t,e,r,i)=>{I7(t,{withFileTypes:!0},(n,s)=>{if(n){if(n.code==="ENOENT")return i();if(n.code!=="ENOTDIR"&&n.code!=="ENOTSUP")return i(n)}if(n||!s.length)return wB(t,e,r,i);let o=s.length,a=null,l=c=>{if(!a){if(c)return i(a=c);if(--o==0)return wB(t,e,r,i)}};s.forEach(c=>y7(t,c,e,r,l))})},RLe=(t,e,r,i)=>{if(typeof e=="string")try{let n=fs.lstatSync(Qc.resolve(t,e));n.name=e,e=n}catch(n){if(n.code==="ENOENT")return;throw n}e.isDirectory()&&w7(Qc.resolve(t,e.name),r,i),rR(Qc.resolve(t,e.name),r,i)},w7=(t,e,r)=>{let i;try{i=DLe(t,{withFileTypes:!0})}catch(n){if(n.code==="ENOENT")return;if(n.code==="ENOTDIR"||n.code==="ENOTSUP")return rR(t,e,r);throw n}return i&&i.length&&i.forEach(n=>RLe(t,n,e,r)),rR(t,e,r)};C7.exports=iR;iR.sync=w7});var S7=E((rct,nR)=>{"use strict";var Q7=d7(),hs=require("fs"),BB=require("path"),b7=B7(),sR=class extends Error{constructor(e,r){super("Cannot extract through symbolic link");this.path=r,this.symlink=e}get name(){return"SylinkError"}},cd=class extends Error{constructor(e,r){super(r+": Cannot cd into '"+e+"'");this.path=e,this.code=r}get name(){return"CwdError"}},ect=nR.exports=(t,e,r)=>{let i=e.umask,n=e.mode|448,s=(n&i)!=0,o=e.uid,a=e.gid,l=typeof o=="number"&&typeof a=="number"&&(o!==e.processUid||a!==e.processGid),c=e.preserve,u=e.unlink,g=e.cache,f=e.cwd,h=(m,I)=>{m?r(m):(g.set(t,!0),I&&l?b7(I,o,a,B=>h(B)):s?hs.chmod(t,n,r):r())};if(g&&g.get(t)===!0)return h();if(t===f)return hs.stat(t,(m,I)=>{(m||!I.isDirectory())&&(m=new cd(t,m&&m.code||"ENOTDIR")),h(m)});if(c)return Q7(t,{mode:n}).then(m=>h(null,m),h);let d=BB.relative(f,t).split(/\/|\\/);QB(f,d,n,g,u,f,null,h)},QB=(t,e,r,i,n,s,o,a)=>{if(!e.length)return a(null,o);let l=e.shift(),c=t+"/"+l;if(i.get(c))return QB(c,e,r,i,n,s,o,a);hs.mkdir(c,r,v7(c,e,r,i,n,s,o,a))},v7=(t,e,r,i,n,s,o,a)=>l=>{if(l){if(l.path&&BB.dirname(l.path)===s&&(l.code==="ENOTDIR"||l.code==="ENOENT"))return a(new cd(s,l.code));hs.lstat(t,(c,u)=>{if(c)a(c);else if(u.isDirectory())QB(t,e,r,i,n,s,o,a);else if(n)hs.unlink(t,g=>{if(g)return a(g);hs.mkdir(t,r,v7(t,e,r,i,n,s,o,a))});else{if(u.isSymbolicLink())return a(new sR(t,t+"/"+e.join("/")));a(l)}})}else o=o||t,QB(t,e,r,i,n,s,o,a)},tct=nR.exports.sync=(t,e)=>{let r=e.umask,i=e.mode|448,n=(i&r)!=0,s=e.uid,o=e.gid,a=typeof s=="number"&&typeof o=="number"&&(s!==e.processUid||o!==e.processGid),l=e.preserve,c=e.unlink,u=e.cache,g=e.cwd,f=m=>{u.set(t,!0),m&&a&&b7.sync(m,s,o),n&&hs.chmodSync(t,i)};if(u&&u.get(t)===!0)return f();if(t===g){let m=!1,I="ENOTDIR";try{m=hs.statSync(t).isDirectory()}catch(B){I=B.code}finally{if(!m)throw new cd(t,I)}f();return}if(l)return f(Q7.sync(t,i));let p=BB.relative(g,t).split(/\/|\\/),d=null;for(let m=p.shift(),I=g;m&&(I+="/"+m);m=p.shift())if(!u.get(I))try{hs.mkdirSync(I,i),d=d||I,u.set(I,!0)}catch(B){if(B.path&&BB.dirname(B.path)===g&&(B.code==="ENOTDIR"||B.code==="ENOENT"))return new cd(g,B.code);let b=hs.lstatSync(I);if(b.isDirectory()){u.set(I,!0);continue}else if(c){hs.unlinkSync(I),hs.mkdirSync(I,i),d=d||I,u.set(I,!0);continue}else if(b.isSymbolicLink())return new sR(I,I+"/"+p.join("/"))}return f(d)}});var P7=E((ict,x7)=>{var k7=require("assert");x7.exports=()=>{let t=new Map,e=new Map,{join:r}=require("path"),i=u=>r(u).split(/[\\\/]/).slice(0,-1).reduce((g,f)=>g.length?g.concat(r(g[g.length-1],f)):[f],[]),n=new Set,s=u=>{let g=e.get(u);if(!g)throw new Error("function does not have any path reservations");return{paths:g.paths.map(f=>t.get(f)),dirs:[...g.dirs].map(f=>t.get(f))}},o=u=>{let{paths:g,dirs:f}=s(u);return g.every(h=>h[0]===u)&&f.every(h=>h[0]instanceof Set&&h[0].has(u))},a=u=>n.has(u)||!o(u)?!1:(n.add(u),u(()=>l(u)),!0),l=u=>{if(!n.has(u))return!1;let{paths:g,dirs:f}=e.get(u),h=new Set;return g.forEach(p=>{let d=t.get(p);k7.equal(d[0],u),d.length===1?t.delete(p):(d.shift(),typeof d[0]=="function"?h.add(d[0]):d[0].forEach(m=>h.add(m)))}),f.forEach(p=>{let d=t.get(p);k7(d[0]instanceof Set),d[0].size===1&&d.length===1?t.delete(p):d[0].size===1?(d.shift(),h.add(d[0])):d[0].delete(u)}),n.delete(u),h.forEach(p=>a(p)),!0};return{check:o,reserve:(u,g)=>{let f=new Set(u.map(h=>i(h)).reduce((h,p)=>h.concat(p)));return e.set(g,{dirs:f,paths:u}),u.forEach(h=>{let p=t.get(h);p?p.push(g):t.set(h,[g])}),f.forEach(h=>{let p=t.get(h);p?p[p.length-1]instanceof Set?p[p.length-1].add(g):p.push(new Set([g])):t.set(h,[new Set([g])])}),a(g)}}}});var F7=E((nct,D7)=>{var FLe=process.env.__FAKE_PLATFORM__||process.platform,NLe=FLe==="win32",LLe=global.__FAKE_TESTING_FS__||require("fs"),{O_CREAT:TLe,O_TRUNC:MLe,O_WRONLY:OLe,UV_FS_O_FILEMAP:R7=0}=LLe.constants,KLe=NLe&&!!R7,ULe=512*1024,HLe=R7|MLe|TLe|OLe;D7.exports=KLe?t=>t"w"});var hR=E((Act,N7)=>{"use strict";var GLe=require("assert"),sct=require("events").EventEmitter,jLe=ld(),Ut=require("fs"),YLe=bg(),Pa=require("path"),oR=S7(),oct=oR.sync,L7=yD(),qLe=P7(),T7=Symbol("onEntry"),aR=Symbol("checkFs"),M7=Symbol("checkFs2"),AR=Symbol("isReusable"),Da=Symbol("makeFs"),lR=Symbol("file"),cR=Symbol("directory"),bB=Symbol("link"),O7=Symbol("symlink"),K7=Symbol("hardlink"),U7=Symbol("unsupported"),act=Symbol("unknown"),H7=Symbol("checkPath"),Pg=Symbol("mkdir"),nn=Symbol("onError"),vB=Symbol("pending"),G7=Symbol("pend"),Dg=Symbol("unpend"),uR=Symbol("ended"),gR=Symbol("maybeClose"),fR=Symbol("skip"),ud=Symbol("doChown"),gd=Symbol("uid"),fd=Symbol("gid"),j7=require("crypto"),Y7=F7(),SB=()=>{throw new Error("sync function called cb somehow?!?")},JLe=(t,e)=>{if(process.platform!=="win32")return Ut.unlink(t,e);let r=t+".DELETE."+j7.randomBytes(16).toString("hex");Ut.rename(t,r,i=>{if(i)return e(i);Ut.unlink(r,e)})},WLe=t=>{if(process.platform!=="win32")return Ut.unlinkSync(t);let e=t+".DELETE."+j7.randomBytes(16).toString("hex");Ut.renameSync(t,e),Ut.unlinkSync(e)},q7=(t,e,r)=>t===t>>>0?t:e===e>>>0?e:r,xB=class extends jLe{constructor(e){if(e||(e={}),e.ondone=r=>{this[uR]=!0,this[gR]()},super(e),this.reservations=qLe(),this.transform=typeof e.transform=="function"?e.transform:null,this.writable=!0,this.readable=!1,this[vB]=0,this[uR]=!1,this.dirCache=e.dirCache||new Map,typeof e.uid=="number"||typeof e.gid=="number"){if(typeof e.uid!="number"||typeof e.gid!="number")throw new TypeError("cannot set owner without number uid and gid");if(e.preserveOwner)throw new TypeError("cannot preserve owner in archive and also set owner explicitly");this.uid=e.uid,this.gid=e.gid,this.setOwner=!0}else this.uid=null,this.gid=null,this.setOwner=!1;e.preserveOwner===void 0&&typeof e.uid!="number"?this.preserveOwner=process.getuid&&process.getuid()===0:this.preserveOwner=!!e.preserveOwner,this.processUid=(this.preserveOwner||this.setOwner)&&process.getuid?process.getuid():null,this.processGid=(this.preserveOwner||this.setOwner)&&process.getgid?process.getgid():null,this.forceChown=e.forceChown===!0,this.win32=!!e.win32||process.platform==="win32",this.newer=!!e.newer,this.keep=!!e.keep,this.noMtime=!!e.noMtime,this.preservePaths=!!e.preservePaths,this.unlink=!!e.unlink,this.cwd=Pa.resolve(e.cwd||process.cwd()),this.strip=+e.strip||0,this.processUmask=process.umask(),this.umask=typeof e.umask=="number"?e.umask:this.processUmask,this.dmode=e.dmode||511&~this.umask,this.fmode=e.fmode||438&~this.umask,this.on("entry",r=>this[T7](r))}warn(e,r,i={}){return(e==="TAR_BAD_ARCHIVE"||e==="TAR_ABORT")&&(i.recoverable=!1),super.warn(e,r,i)}[gR](){this[uR]&&this[vB]===0&&(this.emit("prefinish"),this.emit("finish"),this.emit("end"),this.emit("close"))}[H7](e){if(this.strip){let r=e.path.split(/\/|\\/);if(r.length=this.strip&&(e.linkpath=i.slice(this.strip).join("/"))}}if(!this.preservePaths){let r=e.path;if(r.match(/(^|\/|\\)\.\.(\\|\/|$)/))return this.warn("TAR_ENTRY_ERROR","path contains '..'",{entry:e,path:r}),!1;if(Pa.win32.isAbsolute(r)){let i=Pa.win32.parse(r);e.path=r.substr(i.root.length);let n=i.root;this.warn("TAR_ENTRY_INFO",`stripping ${n} from absolute path`,{entry:e,path:r})}}if(this.win32){let r=Pa.win32.parse(e.path);e.path=r.root===""?L7.encode(e.path):r.root+L7.encode(e.path.substr(r.root.length))}return Pa.isAbsolute(e.path)?e.absolute=e.path:e.absolute=Pa.resolve(this.cwd,e.path),!0}[T7](e){if(!this[H7](e))return e.resume();switch(GLe.equal(typeof e.absolute,"string"),e.type){case"Directory":case"GNUDumpDir":e.mode&&(e.mode=e.mode|448);case"File":case"OldFile":case"ContiguousFile":case"Link":case"SymbolicLink":return this[aR](e);case"CharacterDevice":case"BlockDevice":case"FIFO":return this[U7](e)}}[nn](e,r){e.name==="CwdError"?this.emit("error",e):(this.warn("TAR_ENTRY_ERROR",e,{entry:r}),this[Dg](),r.resume())}[Pg](e,r,i){oR(e,{uid:this.uid,gid:this.gid,processUid:this.processUid,processGid:this.processGid,umask:this.processUmask,preserve:this.preservePaths,unlink:this.unlink,cache:this.dirCache,cwd:this.cwd,mode:r},i)}[ud](e){return this.forceChown||this.preserveOwner&&(typeof e.uid=="number"&&e.uid!==this.processUid||typeof e.gid=="number"&&e.gid!==this.processGid)||typeof this.uid=="number"&&this.uid!==this.processUid||typeof this.gid=="number"&&this.gid!==this.processGid}[gd](e){return q7(this.uid,e.uid,this.processUid)}[fd](e){return q7(this.gid,e.gid,this.processGid)}[lR](e,r){let i=e.mode&4095||this.fmode,n=new YLe.WriteStream(e.absolute,{flags:Y7(e.size),mode:i,autoClose:!1});n.on("error",l=>this[nn](l,e));let s=1,o=l=>{if(l)return this[nn](l,e);--s==0&&Ut.close(n.fd,c=>{r(),c?this[nn](c,e):this[Dg]()})};n.on("finish",l=>{let c=e.absolute,u=n.fd;if(e.mtime&&!this.noMtime){s++;let g=e.atime||new Date,f=e.mtime;Ut.futimes(u,g,f,h=>h?Ut.utimes(c,g,f,p=>o(p&&h)):o())}if(this[ud](e)){s++;let g=this[gd](e),f=this[fd](e);Ut.fchown(u,g,f,h=>h?Ut.chown(c,g,f,p=>o(p&&h)):o())}o()});let a=this.transform&&this.transform(e)||e;a!==e&&(a.on("error",l=>this[nn](l,e)),e.pipe(a)),a.pipe(n)}[cR](e,r){let i=e.mode&4095||this.dmode;this[Pg](e.absolute,i,n=>{if(n)return r(),this[nn](n,e);let s=1,o=a=>{--s==0&&(r(),this[Dg](),e.resume())};e.mtime&&!this.noMtime&&(s++,Ut.utimes(e.absolute,e.atime||new Date,e.mtime,o)),this[ud](e)&&(s++,Ut.chown(e.absolute,this[gd](e),this[fd](e),o)),o()})}[U7](e){e.unsupported=!0,this.warn("TAR_ENTRY_UNSUPPORTED",`unsupported entry type: ${e.type}`,{entry:e}),e.resume()}[O7](e,r){this[bB](e,e.linkpath,"symlink",r)}[K7](e,r){this[bB](e,Pa.resolve(this.cwd,e.linkpath),"link",r)}[G7](){this[vB]++}[Dg](){this[vB]--,this[gR]()}[fR](e){this[Dg](),e.resume()}[AR](e,r){return e.type==="File"&&!this.unlink&&r.isFile()&&r.nlink<=1&&process.platform!=="win32"}[aR](e){this[G7]();let r=[e.path];e.linkpath&&r.push(e.linkpath),this.reservations.reserve(r,i=>this[M7](e,i))}[M7](e,r){this[Pg](Pa.dirname(e.absolute),this.dmode,i=>{if(i)return r(),this[nn](i,e);Ut.lstat(e.absolute,(n,s)=>{s&&(this.keep||this.newer&&s.mtime>e.mtime)?(this[fR](e),r()):n||this[AR](e,s)?this[Da](null,e,r):s.isDirectory()?e.type==="Directory"?!e.mode||(s.mode&4095)===e.mode?this[Da](null,e,r):Ut.chmod(e.absolute,e.mode,o=>this[Da](o,e,r)):Ut.rmdir(e.absolute,o=>this[Da](o,e,r)):JLe(e.absolute,o=>this[Da](o,e,r))})})}[Da](e,r,i){if(e)return this[nn](e,r);switch(r.type){case"File":case"OldFile":case"ContiguousFile":return this[lR](r,i);case"Link":return this[K7](r,i);case"SymbolicLink":return this[O7](r,i);case"Directory":case"GNUDumpDir":return this[cR](r,i)}}[bB](e,r,i,n){Ut[i](r,e.absolute,s=>{if(s)return this[nn](s,e);n(),this[Dg](),e.resume()})}},J7=class extends xB{constructor(e){super(e)}[aR](e){let r=this[Pg](Pa.dirname(e.absolute),this.dmode,SB);if(r)return this[nn](r,e);try{let i=Ut.lstatSync(e.absolute);if(this.keep||this.newer&&i.mtime>e.mtime)return this[fR](e);if(this[AR](e,i))return this[Da](null,e,SB);try{return i.isDirectory()?e.type==="Directory"?e.mode&&(i.mode&4095)!==e.mode&&Ut.chmodSync(e.absolute,e.mode):Ut.rmdirSync(e.absolute):WLe(e.absolute),this[Da](null,e,SB)}catch(n){return this[nn](n,e)}}catch(i){return this[Da](null,e,SB)}}[lR](e,r){let i=e.mode&4095||this.fmode,n=l=>{let c;try{Ut.closeSync(o)}catch(u){c=u}(l||c)&&this[nn](l||c,e)},s,o;try{o=Ut.openSync(e.absolute,Y7(e.size),i)}catch(l){return n(l)}let a=this.transform&&this.transform(e)||e;a!==e&&(a.on("error",l=>this[nn](l,e)),e.pipe(a)),a.on("data",l=>{try{Ut.writeSync(o,l,0,l.length)}catch(c){n(c)}}),a.on("end",l=>{let c=null;if(e.mtime&&!this.noMtime){let u=e.atime||new Date,g=e.mtime;try{Ut.futimesSync(o,u,g)}catch(f){try{Ut.utimesSync(e.absolute,u,g)}catch(h){c=f}}}if(this[ud](e)){let u=this[gd](e),g=this[fd](e);try{Ut.fchownSync(o,u,g)}catch(f){try{Ut.chownSync(e.absolute,u,g)}catch(h){c=c||f}}}n(c)})}[cR](e,r){let i=e.mode&4095||this.dmode,n=this[Pg](e.absolute,i);if(n)return this[nn](n,e);if(e.mtime&&!this.noMtime)try{Ut.utimesSync(e.absolute,e.atime||new Date,e.mtime)}catch(s){}if(this[ud](e))try{Ut.chownSync(e.absolute,this[gd](e),this[fd](e))}catch(s){}e.resume()}[Pg](e,r){try{return oR.sync(e,{uid:this.uid,gid:this.gid,processUid:this.processUid,processGid:this.processGid,umask:this.processUmask,preserve:this.preservePaths,unlink:this.unlink,cache:this.dirCache,cwd:this.cwd,mode:r})}catch(i){return i}}[bB](e,r,i,n){try{Ut[i+"Sync"](r,e.absolute),e.resume()}catch(s){return this[nn](s,e)}}};xB.Sync=J7;N7.exports=xB});var X7=E((cct,W7)=>{"use strict";var zLe=fg(),kB=hR(),z7=require("fs"),V7=bg(),_7=require("path"),lct=W7.exports=(t,e,r)=>{typeof t=="function"?(r=t,e=null,t={}):Array.isArray(t)&&(e=t,t={}),typeof e=="function"&&(r=e,e=null),e?e=Array.from(e):e=[];let i=zLe(t);if(i.sync&&typeof r=="function")throw new TypeError("callback not supported for sync tar functions");if(!i.file&&typeof r=="function")throw new TypeError("callback only supported with file option");return e.length&&VLe(i,e),i.file&&i.sync?_Le(i):i.file?XLe(i,r):i.sync?ZLe(i):$Le(i)},VLe=(t,e)=>{let r=new Map(e.map(s=>[s.replace(/\/+$/,""),!0])),i=t.filter,n=(s,o)=>{let a=o||_7.parse(s).root||".",l=s===a?!1:r.has(s)?r.get(s):n(_7.dirname(s),a);return r.set(s,l),l};t.filter=i?(s,o)=>i(s,o)&&n(s.replace(/\/+$/,"")):s=>n(s.replace(/\/+$/,""))},_Le=t=>{let e=new kB.Sync(t),r=t.file,i=!0,n,s=z7.statSync(r),o=t.maxReadSize||16*1024*1024;new V7.ReadStreamSync(r,{readSize:o,size:s.size}).pipe(e)},XLe=(t,e)=>{let r=new kB(t),i=t.maxReadSize||16*1024*1024,n=t.file,s=new Promise((o,a)=>{r.on("error",a),r.on("close",o),z7.stat(n,(l,c)=>{if(l)a(l);else{let u=new V7.ReadStream(n,{readSize:i,size:c.size});u.on("error",a),u.pipe(r)}})});return e?s.then(e,e):s},ZLe=t=>new kB.Sync(t),$Le=t=>new kB(t)});var Z7=E($r=>{"use strict";$r.c=$r.create=TV();$r.r=$r.replace=XD();$r.t=$r.list=IB();$r.u=$r.update=qV();$r.x=$r.extract=X7();$r.Pack=AB();$r.Unpack=hR();$r.Parse=ld();$r.ReadEntry=id();$r.WriteEntry=xD();$r.Header=Cg();$r.Pax=zw();$r.types=rd()});var e_=E((gct,pR)=>{"use strict";var eTe=Object.prototype.hasOwnProperty,sn="~";function hd(){}Object.create&&(hd.prototype=Object.create(null),new hd().__proto__||(sn=!1));function tTe(t,e,r){this.fn=t,this.context=e,this.once=r||!1}function $7(t,e,r,i,n){if(typeof r!="function")throw new TypeError("The listener must be a function");var s=new tTe(r,i||t,n),o=sn?sn+e:e;return t._events[o]?t._events[o].fn?t._events[o]=[t._events[o],s]:t._events[o].push(s):(t._events[o]=s,t._eventsCount++),t}function PB(t,e){--t._eventsCount==0?t._events=new hd:delete t._events[e]}function Ti(){this._events=new hd,this._eventsCount=0}Ti.prototype.eventNames=function(){var e=[],r,i;if(this._eventsCount===0)return e;for(i in r=this._events)eTe.call(r,i)&&e.push(sn?i.slice(1):i);return Object.getOwnPropertySymbols?e.concat(Object.getOwnPropertySymbols(r)):e};Ti.prototype.listeners=function(e){var r=sn?sn+e:e,i=this._events[r];if(!i)return[];if(i.fn)return[i.fn];for(var n=0,s=i.length,o=new Array(s);n{"use strict";t_.exports=(t,e)=>(e=e||(()=>{}),t.then(r=>new Promise(i=>{i(e())}).then(()=>r),r=>new Promise(i=>{i(e())}).then(()=>{throw r})))});var n_=E((hct,DB)=>{"use strict";var rTe=r_(),dR=class extends Error{constructor(e){super(e);this.name="TimeoutError"}},i_=(t,e,r)=>new Promise((i,n)=>{if(typeof e!="number"||e<0)throw new TypeError("Expected `milliseconds` to be a positive number");if(e===Infinity){i(t);return}let s=setTimeout(()=>{if(typeof r=="function"){try{i(r())}catch(l){n(l)}return}let o=typeof r=="string"?r:`Promise timed out after ${e} milliseconds`,a=r instanceof Error?r:new dR(o);typeof t.cancel=="function"&&t.cancel(),n(a)},e);rTe(t.then(i,n),()=>{clearTimeout(s)})});DB.exports=i_;DB.exports.default=i_;DB.exports.TimeoutError=dR});var s_=E(CR=>{"use strict";Object.defineProperty(CR,"__esModule",{value:!0});function iTe(t,e,r){let i=0,n=t.length;for(;n>0;){let s=n/2|0,o=i+s;r(t[o],e)<=0?(i=++o,n-=s+1):n=s}return i}CR.default=iTe});var a_=E(mR=>{"use strict";Object.defineProperty(mR,"__esModule",{value:!0});var nTe=s_(),o_=class{constructor(){this._queue=[]}enqueue(e,r){r=Object.assign({priority:0},r);let i={priority:r.priority,run:e};if(this.size&&this._queue[this.size-1].priority>=r.priority){this._queue.push(i);return}let n=nTe.default(this._queue,i,(s,o)=>o.priority-s.priority);this._queue.splice(n,0,i)}dequeue(){let e=this._queue.shift();return e==null?void 0:e.run}filter(e){return this._queue.filter(r=>r.priority===e.priority).map(r=>r.run)}get size(){return this._queue.length}};mR.default=o_});var c_=E(ER=>{"use strict";Object.defineProperty(ER,"__esModule",{value:!0});var sTe=e_(),A_=n_(),oTe=a_(),RB=()=>{},aTe=new A_.TimeoutError,l_=class extends sTe{constructor(e){var r,i,n,s;super();if(this._intervalCount=0,this._intervalEnd=0,this._pendingCount=0,this._resolveEmpty=RB,this._resolveIdle=RB,e=Object.assign({carryoverConcurrencyCount:!1,intervalCap:Infinity,interval:0,concurrency:Infinity,autoStart:!0,queueClass:oTe.default},e),!(typeof e.intervalCap=="number"&&e.intervalCap>=1))throw new TypeError(`Expected \`intervalCap\` to be a number from 1 and up, got \`${(i=(r=e.intervalCap)===null||r===void 0?void 0:r.toString())!==null&&i!==void 0?i:""}\` (${typeof e.intervalCap})`);if(e.interval===void 0||!(Number.isFinite(e.interval)&&e.interval>=0))throw new TypeError(`Expected \`interval\` to be a finite number >= 0, got \`${(s=(n=e.interval)===null||n===void 0?void 0:n.toString())!==null&&s!==void 0?s:""}\` (${typeof e.interval})`);this._carryoverConcurrencyCount=e.carryoverConcurrencyCount,this._isIntervalIgnored=e.intervalCap===Infinity||e.interval===0,this._intervalCap=e.intervalCap,this._interval=e.interval,this._queue=new e.queueClass,this._queueClass=e.queueClass,this.concurrency=e.concurrency,this._timeout=e.timeout,this._throwOnTimeout=e.throwOnTimeout===!0,this._isPaused=e.autoStart===!1}get _doesIntervalAllowAnother(){return this._isIntervalIgnored||this._intervalCount{this._onResumeInterval()},r)),!0}return!1}_tryToStartAnother(){if(this._queue.size===0)return this._intervalId&&clearInterval(this._intervalId),this._intervalId=void 0,this._resolvePromises(),!1;if(!this._isPaused){let e=!this._isIntervalPaused();if(this._doesIntervalAllowAnother&&this._doesConcurrentAllowAnother){let r=this._queue.dequeue();return r?(this.emit("active"),r(),e&&this._initializeIntervalIfNeeded(),!0):!1}}return!1}_initializeIntervalIfNeeded(){this._isIntervalIgnored||this._intervalId!==void 0||(this._intervalId=setInterval(()=>{this._onInterval()},this._interval),this._intervalEnd=Date.now()+this._interval)}_onInterval(){this._intervalCount===0&&this._pendingCount===0&&this._intervalId&&(clearInterval(this._intervalId),this._intervalId=void 0),this._intervalCount=this._carryoverConcurrencyCount?this._pendingCount:0,this._processQueue()}_processQueue(){for(;this._tryToStartAnother(););}get concurrency(){return this._concurrency}set concurrency(e){if(!(typeof e=="number"&&e>=1))throw new TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${e}\` (${typeof e})`);this._concurrency=e,this._processQueue()}async add(e,r={}){return new Promise((i,n)=>{let s=async()=>{this._pendingCount++,this._intervalCount++;try{let o=this._timeout===void 0&&r.timeout===void 0?e():A_.default(Promise.resolve(e()),r.timeout===void 0?this._timeout:r.timeout,()=>{(r.throwOnTimeout===void 0?this._throwOnTimeout:r.throwOnTimeout)&&n(aTe)});i(await o)}catch(o){n(o)}this._next()};this._queue.enqueue(s,r),this._tryToStartAnother(),this.emit("add")})}async addAll(e,r){return Promise.all(e.map(async i=>this.add(i,r)))}start(){return this._isPaused?(this._isPaused=!1,this._processQueue(),this):this}pause(){this._isPaused=!0}clear(){this._queue=new this._queueClass}async onEmpty(){if(this._queue.size!==0)return new Promise(e=>{let r=this._resolveEmpty;this._resolveEmpty=()=>{r(),e()}})}async onIdle(){if(!(this._pendingCount===0&&this._queue.size===0))return new Promise(e=>{let r=this._resolveIdle;this._resolveIdle=()=>{r(),e()}})}get size(){return this._queue.size}sizeBy(e){return this._queue.filter(e).length}get pending(){return this._pendingCount}get isPaused(){return this._isPaused}get timeout(){return this._timeout}set timeout(e){this._timeout=e}};ER.default=l_});var p_=E((Ect,h_)=>{var yR;h_.exports.getContent=()=>(typeof yR=="undefined"&&(yR=require("zlib").brotliDecompressSync(Buffer.from("W4IvekBxw2bzwtWbVf5fyX2AzAPMISJEY/fbMcKtepRTQlBXjG63eijJbQN4ALzvTBt+EVRVTTsqQ1wCS1oAYPuvqgWZIinRemQXGoWk4C5BOebq1CAsym3ILBoVZ6LpLswKQ4VNE6OQ3IoPxtM31ikJr/0aapiJOVzKMZJvVs7xyhEPb7LomEWn5rAew20WdiSC78J8645T+pzTZd2xBeNUftH3D/KCqIvf9WM4TH9KLFd/FF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g0/Dcb7AJvu2f/AV7CkWPPAWX14rPiYP5Bh1/ryqVKN07xqFXGVJIuEDtMGz9DtMU5BgNahpB5TD5Z9M/vPCYW1vGN2b/cBMKrGVf+gp/u9nk9Y4hRxMF18iZpG05oz4TsHX4psYDy2rjSZR857hzFrR2VNTa6+wq6SzulSjHa3noQGQne9xHMlpmKhEQcBdIUsRAcmGC8vSEpM1ZjEXYmnp3jWBG4/Ghe4VJjYuxH6344nnFnT9midsCN8xgxESC1x2yB6Mi/Lw+IWUmDTQvK4PCY280BUBYREFXgydMTEUsAeW1UWzMLSutQo7EuuKokYIijcgEk+w322B11QPNdsI6GbKueCneic77NY/HwxlWbj7/nnYiYKjKUTKBmtBi7ws3hAuRIZ18/L4oVsbZnczZ9FcbOkiNolgHGNC44Ojgp+bhP/YXuKA5As6KZ9yRpviXZzr3XbsxR6uAxXh7jDZaBbpii0NNetxTbhNK2xx5JGgQkWXMeAlXa0Xf9PRIYtsaTyh5F4Iy7Hn2n6CDfbg19UDne3DdytglcmFKS/vKOpWLMYfqbKyMRfszSBnCgIpJoRqtAngSE1jV3MTCsAcz3hQs3cozb+YPpcST0sgh7zj8O+SxT7j9/oI4ezNJWw3eEn2GALDw3DyCsy3lS3Jzy8lkLvqYsxEn2niP0z9HK+bsvETqtmlzBYjvst/ayEPzFMCY6Cbd8jzMKAZafHiI6sh8tbBQcpz83TvHzx2rHU5ICEAcBDXctnJHArUy/oZ9+eLW5jPtVMuKB33QQ=","base64")).toString()),yR)});var y_=E((wR,I_)=>{(function(t,e){typeof wR=="object"?I_.exports=e():typeof define=="function"&&define.amd?define(e):t.treeify=e()})(wR,function(){function t(n,s){var o=s?"\u2514":"\u251C";return n?o+="\u2500 ":o+="\u2500\u2500\u2510",o}function e(n,s){var o=[];for(var a in n)!n.hasOwnProperty(a)||s&&typeof n[a]=="function"||o.push(a);return o}function r(n,s,o,a,l,c,u){var g="",f=0,h,p,d=a.slice(0);if(d.push([s,o])&&a.length>0&&(a.forEach(function(I,B){B>0&&(g+=(I[1]?" ":"\u2502")+" "),!p&&I[0]===s&&(p=!0)}),g+=t(n,o)+n,l&&(typeof s!="object"||s instanceof Date)&&(g+=": "+s),p&&(g+=" (circular ref.)"),u(g)),!p&&typeof s=="object"){var m=e(s,c);m.forEach(function(I){h=++f===m.length,r(I,s[I],h,d,l,c,u)})}}var i={};return i.asLines=function(n,s,o,a){var l=typeof o!="function"?o:!1;r(".",n,!1,[],s,l,a||o)},i.asTree=function(n,s,o){var a="";return r(".",n,!1,[],s,o,function(l){a+=l+` -`}),a},i})});var x_=E((Uct,bR)=>{"use strict";var pTe=t=>{let e=!1,r=!1,i=!1;for(let n=0;n{if(!(typeof t=="string"||Array.isArray(t)))throw new TypeError("Expected the input to be `string | string[]`");e=Object.assign({pascalCase:!1},e);let r=n=>e.pascalCase?n.charAt(0).toUpperCase()+n.slice(1):n;return Array.isArray(t)?t=t.map(n=>n.trim()).filter(n=>n.length).join("-"):t=t.trim(),t.length===0?"":t.length===1?e.pascalCase?t.toUpperCase():t.toLowerCase():(t!==t.toLowerCase()&&(t=pTe(t)),t=t.replace(/^[_.\- ]+/,"").toLowerCase().replace(/[_.\- ]+(\w|$)/g,(n,s)=>s.toUpperCase()).replace(/\d+(\w|$)/g,n=>n.toUpperCase()),r(t))};bR.exports=S_;bR.exports.default=S_});var Na=E(TR=>{"use strict";Object.defineProperty(TR,"__esModule",{value:!0});TR.default=L_;function L_(){}L_.prototype={diff:function(e,r){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},n=i.callback;typeof i=="function"&&(n=i,i={}),this.options=i;var s=this;function o(d){return n?(setTimeout(function(){n(void 0,d)},0),!0):d}e=this.castInput(e),r=this.castInput(r),e=this.removeEmpty(this.tokenize(e)),r=this.removeEmpty(this.tokenize(r));var a=r.length,l=e.length,c=1,u=a+l,g=[{newPos:-1,components:[]}],f=this.extractCommon(g[0],r,e,0);if(g[0].newPos+1>=a&&f+1>=l)return o([{value:this.join(r),count:r.length}]);function h(){for(var d=-1*c;d<=c;d+=2){var m=void 0,I=g[d-1],B=g[d+1],b=(B?B.newPos:0)-d;I&&(g[d-1]=void 0);var R=I&&I.newPos+1=a&&b+1>=l)return o(yTe(s,m.components,r,e,s.useLongestToken));g[d]=m}c++}if(n)(function d(){setTimeout(function(){if(c>u)return n();h()||d()},0)})();else for(;c<=u;){var p=h();if(p)return p}},pushComponent:function(e,r,i){var n=e[e.length-1];n&&n.added===r&&n.removed===i?e[e.length-1]={count:n.count+1,added:r,removed:i}:e.push({count:1,added:r,removed:i})},extractCommon:function(e,r,i,n){for(var s=r.length,o=i.length,a=e.newPos,l=a-n,c=0;a+1h.length?d:h}),c.value=t.join(u)}else c.value=t.join(r.slice(a,a+c.count));a+=c.count,c.added||(l+=c.count)}}var f=e[o-1];return o>1&&typeof f.value=="string"&&(f.added||f.removed)&&t.equals("",f.value)&&(e[o-2].value+=f.value,e.pop()),e}function wTe(t){return{newPos:t.newPos,components:t.components.slice(0)}}});var M_=E(Cd=>{"use strict";Object.defineProperty(Cd,"__esModule",{value:!0});Cd.diffChars=BTe;Cd.characterDiff=void 0;var bTe=QTe(Na());function QTe(t){return t&&t.__esModule?t:{default:t}}var T_=new bTe.default;Cd.characterDiff=T_;function BTe(t,e,r){return T_.diff(t,e,r)}});var OR=E(MR=>{"use strict";Object.defineProperty(MR,"__esModule",{value:!0});MR.generateOptions=vTe;function vTe(t,e){if(typeof t=="function")e.callback=t;else if(t)for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r]);return e}});var U_=E(Ng=>{"use strict";Object.defineProperty(Ng,"__esModule",{value:!0});Ng.diffWords=STe;Ng.diffWordsWithSpace=xTe;Ng.wordDiff=void 0;var PTe=kTe(Na()),DTe=OR();function kTe(t){return t&&t.__esModule?t:{default:t}}var O_=/^[A-Za-z\xC0-\u02C6\u02C8-\u02D7\u02DE-\u02FF\u1E00-\u1EFF]+$/,K_=/\S/,md=new PTe.default;Ng.wordDiff=md;md.equals=function(t,e){return this.options.ignoreCase&&(t=t.toLowerCase(),e=e.toLowerCase()),t===e||this.options.ignoreWhitespace&&!K_.test(t)&&!K_.test(e)};md.tokenize=function(t){for(var e=t.split(/(\s+|[()[\]{}'"]|\b)/),r=0;r{"use strict";Object.defineProperty(Lg,"__esModule",{value:!0});Lg.diffLines=RTe;Lg.diffTrimmedLines=FTe;Lg.lineDiff=void 0;var LTe=NTe(Na()),TTe=OR();function NTe(t){return t&&t.__esModule?t:{default:t}}var OB=new LTe.default;Lg.lineDiff=OB;OB.tokenize=function(t){var e=[],r=t.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(var i=0;i{"use strict";Object.defineProperty(Ed,"__esModule",{value:!0});Ed.diffSentences=MTe;Ed.sentenceDiff=void 0;var KTe=OTe(Na());function OTe(t){return t&&t.__esModule?t:{default:t}}var KR=new KTe.default;Ed.sentenceDiff=KR;KR.tokenize=function(t){return t.split(/(\S.+?[.!?])(?=\s+|$)/)};function MTe(t,e,r){return KR.diff(t,e,r)}});var G_=E(Id=>{"use strict";Object.defineProperty(Id,"__esModule",{value:!0});Id.diffCss=UTe;Id.cssDiff=void 0;var GTe=HTe(Na());function HTe(t){return t&&t.__esModule?t:{default:t}}var UR=new GTe.default;Id.cssDiff=UR;UR.tokenize=function(t){return t.split(/([{}:;,]|\s+)/)};function UTe(t,e,r){return UR.diff(t,e,r)}});var Y_=E(Tg=>{"use strict";Object.defineProperty(Tg,"__esModule",{value:!0});Tg.diffJson=jTe;Tg.canonicalize=UB;Tg.jsonDiff=void 0;var j_=YTe(Na()),qTe=KB();function YTe(t){return t&&t.__esModule?t:{default:t}}function HB(t){return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?HB=function(r){return typeof r}:HB=function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r},HB(t)}var JTe=Object.prototype.toString,bc=new j_.default;Tg.jsonDiff=bc;bc.useLongestToken=!0;bc.tokenize=qTe.lineDiff.tokenize;bc.castInput=function(t){var e=this.options,r=e.undefinedReplacement,i=e.stringifyReplacer,n=i===void 0?function(s,o){return typeof o=="undefined"?r:o}:i;return typeof t=="string"?t:JSON.stringify(UB(t,null,null,n),n," ")};bc.equals=function(t,e){return j_.default.prototype.equals.call(bc,t.replace(/,([\r\n])/g,"$1"),e.replace(/,([\r\n])/g,"$1"))};function jTe(t,e,r){return bc.diff(t,e,r)}function UB(t,e,r,i,n){e=e||[],r=r||[],i&&(t=i(n,t));var s;for(s=0;s{"use strict";Object.defineProperty(yd,"__esModule",{value:!0});yd.diffArrays=WTe;yd.arrayDiff=void 0;var VTe=zTe(Na());function zTe(t){return t&&t.__esModule?t:{default:t}}var wd=new VTe.default;yd.arrayDiff=wd;wd.tokenize=function(t){return t.slice()};wd.join=wd.removeEmpty=function(t){return t};function WTe(t,e,r){return wd.diff(t,e,r)}});var GB=E(HR=>{"use strict";Object.defineProperty(HR,"__esModule",{value:!0});HR.parsePatch=_Te;function _Te(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=t.split(/\r\n|[\n\v\f\r\x85]/),i=t.match(/\r\n|[\n\v\f\r\x85]/g)||[],n=[],s=0;function o(){var c={};for(n.push(c);s{"use strict";Object.defineProperty(GR,"__esModule",{value:!0});GR.default=XTe;function XTe(t,e,r){var i=!0,n=!1,s=!1,o=1;return function a(){if(i&&!s){if(n?o++:i=!1,t+o<=r)return o;s=!0}if(!n)return s||(i=!0),e<=t-o?-o++:(n=!0,a())}}});var V_=E(jB=>{"use strict";Object.defineProperty(jB,"__esModule",{value:!0});jB.applyPatch=W_;jB.applyPatches=ZTe;var z_=GB(),eMe=$Te(J_());function $Te(t){return t&&t.__esModule?t:{default:t}}function W_(t,e){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(typeof e=="string"&&(e=(0,z_.parsePatch)(e)),Array.isArray(e)){if(e.length>1)throw new Error("applyPatch only works with a single input.");e=e[0]}var i=t.split(/\r\n|[\n\v\f\r\x85]/),n=t.match(/\r\n|[\n\v\f\r\x85]/g)||[],s=e.hunks,o=r.compareLine||function(F,D,he,pe){return D===pe},a=0,l=r.fuzzFactor||0,c=0,u=0,g,f;function h(F,D){for(var he=0;he0?pe[0]:" ",Pe=pe.length>0?pe.substr(1):pe;if(Ne===" "||Ne==="-"){if(!o(D+1,i[D],Ne,Pe)&&(a++,a>l))return!1;D++}}return!0}for(var p=0;p0?ne[0]:" ",A=ne.length>0?ne.substr(1):ne,V=L.linedelimiters[J];if(q===" ")K++;else if(q==="-")i.splice(K,1),n.splice(K,1);else if(q==="+")i.splice(K,0,A),n.splice(K,0,V),K++;else if(q==="\\"){var W=L.lines[J-1]?L.lines[J-1][0]:null;W==="+"?g=!0:W==="-"&&(f=!0)}}}if(g)for(;!i[i.length-1];)i.pop(),n.pop();else f&&(i.push(""),n.push(` -`));for(var X=0;X{"use strict";Object.defineProperty(Bd,"__esModule",{value:!0});Bd.structuredPatch=__;Bd.createTwoFilesPatch=X_;Bd.createPatch=tMe;var rMe=KB();function jR(t){return sMe(t)||nMe(t)||iMe()}function iMe(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function nMe(t){if(Symbol.iterator in Object(t)||Object.prototype.toString.call(t)==="[object Arguments]")return Array.from(t)}function sMe(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e0?l(L.lines.slice(-o.context)):[],u-=f.length,g-=f.length)}(H=f).push.apply(H,jR(R.map(function(X){return(b.added?"+":"-")+X}))),b.added?p+=R.length:h+=R.length}else{if(u)if(R.length<=o.context*2&&B=a.length-2&&R.length<=o.context){var A=/\n$/.test(r),V=/\n$/.test(i),W=R.length==0&&f.length>q.oldLines;!A&&W&&f.splice(q.oldLines,0,"\\ No newline at end of file"),(!A&&!W||!V)&&f.push("\\ No newline at end of file")}c.push(q),u=0,g=0,f=[]}h+=R.length,p+=R.length}},m=0;m{"use strict";Object.defineProperty(YB,"__esModule",{value:!0});YB.arrayEqual=oMe;YB.arrayStartsWith=Z_;function oMe(t,e){return t.length!==e.length?!1:Z_(t,e)}function Z_(t,e){if(e.length>t.length)return!1;for(var r=0;r{"use strict";Object.defineProperty(qB,"__esModule",{value:!0});qB.calcLineCount=eX;qB.merge=aMe;var AMe=YR(),lMe=GB(),qR=$_();function Mg(t){return gMe(t)||uMe(t)||cMe()}function cMe(){throw new TypeError("Invalid attempt to spread non-iterable instance")}function uMe(t){if(Symbol.iterator in Object(t)||Object.prototype.toString.call(t)==="[object Arguments]")return Array.from(t)}function gMe(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e{"use strict";Object.defineProperty(zR,"__esModule",{value:!0});zR.convertChangesToDMP=dMe;function dMe(t){for(var e=[],r,i,n=0;n{"use strict";Object.defineProperty(VR,"__esModule",{value:!0});VR.convertChangesToXML=CMe;function CMe(t){for(var e=[],r=0;r"):i.removed&&e.push(""),e.push(mMe(i.value)),i.added?e.push(""):i.removed&&e.push("")}return e.join("")}function mMe(t){var e=t;return e=e.replace(/&/g,"&"),e=e.replace(//g,">"),e=e.replace(/"/g,"""),e}});var CX=E(br=>{"use strict";Object.defineProperty(br,"__esModule",{value:!0});Object.defineProperty(br,"Diff",{enumerable:!0,get:function(){return EMe.default}});Object.defineProperty(br,"diffChars",{enumerable:!0,get:function(){return IMe.diffChars}});Object.defineProperty(br,"diffWords",{enumerable:!0,get:function(){return fX.diffWords}});Object.defineProperty(br,"diffWordsWithSpace",{enumerable:!0,get:function(){return fX.diffWordsWithSpace}});Object.defineProperty(br,"diffLines",{enumerable:!0,get:function(){return hX.diffLines}});Object.defineProperty(br,"diffTrimmedLines",{enumerable:!0,get:function(){return hX.diffTrimmedLines}});Object.defineProperty(br,"diffSentences",{enumerable:!0,get:function(){return yMe.diffSentences}});Object.defineProperty(br,"diffCss",{enumerable:!0,get:function(){return wMe.diffCss}});Object.defineProperty(br,"diffJson",{enumerable:!0,get:function(){return pX.diffJson}});Object.defineProperty(br,"canonicalize",{enumerable:!0,get:function(){return pX.canonicalize}});Object.defineProperty(br,"diffArrays",{enumerable:!0,get:function(){return BMe.diffArrays}});Object.defineProperty(br,"applyPatch",{enumerable:!0,get:function(){return dX.applyPatch}});Object.defineProperty(br,"applyPatches",{enumerable:!0,get:function(){return dX.applyPatches}});Object.defineProperty(br,"parsePatch",{enumerable:!0,get:function(){return QMe.parsePatch}});Object.defineProperty(br,"merge",{enumerable:!0,get:function(){return bMe.merge}});Object.defineProperty(br,"structuredPatch",{enumerable:!0,get:function(){return _R.structuredPatch}});Object.defineProperty(br,"createTwoFilesPatch",{enumerable:!0,get:function(){return _R.createTwoFilesPatch}});Object.defineProperty(br,"createPatch",{enumerable:!0,get:function(){return _R.createPatch}});Object.defineProperty(br,"convertChangesToDMP",{enumerable:!0,get:function(){return vMe.convertChangesToDMP}});Object.defineProperty(br,"convertChangesToXML",{enumerable:!0,get:function(){return SMe.convertChangesToXML}});var EMe=xMe(Na()),IMe=M_(),fX=U_(),hX=KB(),yMe=H_(),wMe=G_(),pX=Y_(),BMe=q_(),dX=V_(),QMe=GB(),bMe=cX(),_R=YR(),vMe=uX(),SMe=gX();function xMe(t){return t&&t.__esModule?t:{default:t}}});var WB=E((agt,mX)=>{var kMe=As(),PMe=Nw(),DMe=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,RMe=/^\w*$/;function FMe(t,e){if(kMe(t))return!1;var r=typeof t;return r=="number"||r=="symbol"||r=="boolean"||t==null||PMe(t)?!0:RMe.test(t)||!DMe.test(t)||e!=null&&t in Object(e)}mX.exports=FMe});var Gs=E((Agt,EX)=>{function NMe(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}EX.exports=NMe});var zB=E((lgt,IX)=>{var LMe=Ac(),TMe=Gs(),MMe="[object AsyncFunction]",OMe="[object Function]",KMe="[object GeneratorFunction]",UMe="[object Proxy]";function HMe(t){if(!TMe(t))return!1;var e=LMe(t);return e==OMe||e==KMe||e==MMe||e==UMe}IX.exports=HMe});var wX=E((cgt,yX)=>{var GMe=Ks(),jMe=GMe["__core-js_shared__"];yX.exports=jMe});var bX=E((ugt,BX)=>{var XR=wX(),QX=function(){var t=/[^.]+$/.exec(XR&&XR.keys&&XR.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function YMe(t){return!!QX&&QX in t}BX.exports=YMe});var ZR=E((ggt,vX)=>{var qMe=Function.prototype,JMe=qMe.toString;function WMe(t){if(t!=null){try{return JMe.call(t)}catch(e){}try{return t+""}catch(e){}}return""}vX.exports=WMe});var xX=E((fgt,SX)=>{var zMe=zB(),VMe=bX(),_Me=Gs(),XMe=ZR(),ZMe=/[\\^$.*+?()[\]{}|]/g,$Me=/^\[object .+?Constructor\]$/,eOe=Function.prototype,tOe=Object.prototype,rOe=eOe.toString,iOe=tOe.hasOwnProperty,nOe=RegExp("^"+rOe.call(iOe).replace(ZMe,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function sOe(t){if(!_Me(t)||VMe(t))return!1;var e=zMe(t)?nOe:$Me;return e.test(XMe(t))}SX.exports=sOe});var PX=E((hgt,kX)=>{function oOe(t,e){return t==null?void 0:t[e]}kX.exports=oOe});var UA=E((pgt,DX)=>{var aOe=xX(),AOe=PX();function lOe(t,e){var r=AOe(t,e);return aOe(r)?r:void 0}DX.exports=lOe});var Qd=E((dgt,RX)=>{var cOe=UA(),uOe=cOe(Object,"create");RX.exports=uOe});var LX=E((Cgt,FX)=>{var NX=Qd();function gOe(){this.__data__=NX?NX(null):{},this.size=0}FX.exports=gOe});var MX=E((mgt,TX)=>{function fOe(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}TX.exports=fOe});var KX=E((Egt,OX)=>{var hOe=Qd(),pOe="__lodash_hash_undefined__",dOe=Object.prototype,COe=dOe.hasOwnProperty;function mOe(t){var e=this.__data__;if(hOe){var r=e[t];return r===pOe?void 0:r}return COe.call(e,t)?e[t]:void 0}OX.exports=mOe});var HX=E((Igt,UX)=>{var EOe=Qd(),IOe=Object.prototype,yOe=IOe.hasOwnProperty;function wOe(t){var e=this.__data__;return EOe?e[t]!==void 0:yOe.call(e,t)}UX.exports=wOe});var jX=E((ygt,GX)=>{var BOe=Qd(),QOe="__lodash_hash_undefined__";function bOe(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=BOe&&e===void 0?QOe:e,this}GX.exports=bOe});var qX=E((wgt,YX)=>{var vOe=LX(),SOe=MX(),xOe=KX(),kOe=HX(),POe=jX();function Og(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e{function DOe(){this.__data__=[],this.size=0}JX.exports=DOe});var Kg=E((Qgt,zX)=>{function ROe(t,e){return t===e||t!==t&&e!==e}zX.exports=ROe});var bd=E((bgt,VX)=>{var FOe=Kg();function NOe(t,e){for(var r=t.length;r--;)if(FOe(t[r][0],e))return r;return-1}VX.exports=NOe});var XX=E((vgt,_X)=>{var LOe=bd(),TOe=Array.prototype,MOe=TOe.splice;function OOe(t){var e=this.__data__,r=LOe(e,t);if(r<0)return!1;var i=e.length-1;return r==i?e.pop():MOe.call(e,r,1),--this.size,!0}_X.exports=OOe});var $X=E((Sgt,ZX)=>{var KOe=bd();function UOe(t){var e=this.__data__,r=KOe(e,t);return r<0?void 0:e[r][1]}ZX.exports=UOe});var tZ=E((xgt,eZ)=>{var HOe=bd();function GOe(t){return HOe(this.__data__,t)>-1}eZ.exports=GOe});var iZ=E((kgt,rZ)=>{var jOe=bd();function YOe(t,e){var r=this.__data__,i=jOe(r,t);return i<0?(++this.size,r.push([t,e])):r[i][1]=e,this}rZ.exports=YOe});var vd=E((Pgt,nZ)=>{var qOe=WX(),JOe=XX(),WOe=$X(),zOe=tZ(),VOe=iZ();function Ug(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e{var _Oe=UA(),XOe=Ks(),ZOe=_Oe(XOe,"Map");sZ.exports=ZOe});var AZ=E((Rgt,oZ)=>{var aZ=qX(),$Oe=vd(),eKe=VB();function tKe(){this.size=0,this.__data__={hash:new aZ,map:new(eKe||$Oe),string:new aZ}}oZ.exports=tKe});var cZ=E((Fgt,lZ)=>{function rKe(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}lZ.exports=rKe});var Sd=E((Ngt,uZ)=>{var iKe=cZ();function nKe(t,e){var r=t.__data__;return iKe(e)?r[typeof e=="string"?"string":"hash"]:r.map}uZ.exports=nKe});var fZ=E((Lgt,gZ)=>{var sKe=Sd();function oKe(t){var e=sKe(this,t).delete(t);return this.size-=e?1:0,e}gZ.exports=oKe});var pZ=E((Tgt,hZ)=>{var aKe=Sd();function AKe(t){return aKe(this,t).get(t)}hZ.exports=AKe});var CZ=E((Mgt,dZ)=>{var lKe=Sd();function cKe(t){return lKe(this,t).has(t)}dZ.exports=cKe});var EZ=E((Ogt,mZ)=>{var uKe=Sd();function gKe(t,e){var r=uKe(this,t),i=r.size;return r.set(t,e),this.size+=r.size==i?0:1,this}mZ.exports=gKe});var _B=E((Kgt,IZ)=>{var fKe=AZ(),hKe=fZ(),pKe=pZ(),dKe=CZ(),CKe=EZ();function Hg(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e{var wZ=_B(),mKe="Expected a function";function $R(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(mKe);var r=function(){var i=arguments,n=e?e.apply(this,i):i[0],s=r.cache;if(s.has(n))return s.get(n);var o=t.apply(this,i);return r.cache=s.set(n,o)||s,o};return r.cache=new($R.Cache||wZ),r}$R.Cache=wZ;yZ.exports=$R});var bZ=E((Hgt,QZ)=>{var EKe=BZ(),IKe=500;function yKe(t){var e=EKe(t,function(i){return r.size===IKe&&r.clear(),i}),r=e.cache;return e}QZ.exports=yKe});var SZ=E((Ggt,vZ)=>{var wKe=bZ(),BKe=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,QKe=/\\(\\)?/g,bKe=wKe(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(BKe,function(r,i,n,s){e.push(n?s.replace(QKe,"$1"):i||r)}),e});vZ.exports=bKe});var Gg=E((jgt,xZ)=>{var vKe=As(),SKe=WB(),xKe=SZ(),kKe=gg();function PKe(t,e){return vKe(t)?t:SKe(t,e)?[t]:xKe(kKe(t))}xZ.exports=PKe});var Sc=E((Ygt,kZ)=>{var DKe=Nw(),RKe=1/0;function FKe(t){if(typeof t=="string"||DKe(t))return t;var e=t+"";return e=="0"&&1/t==-RKe?"-0":e}kZ.exports=FKe});var xd=E((qgt,PZ)=>{var NKe=Gg(),LKe=Sc();function TKe(t,e){e=NKe(e,t);for(var r=0,i=e.length;t!=null&&r{var MKe=UA(),OKe=function(){try{var t=MKe(Object,"defineProperty");return t({},"",{}),t}catch(e){}}();DZ.exports=OKe});var jg=E((Wgt,RZ)=>{var FZ=eF();function KKe(t,e,r){e=="__proto__"&&FZ?FZ(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}RZ.exports=KKe});var XB=E((zgt,NZ)=>{var UKe=jg(),HKe=Kg(),GKe=Object.prototype,jKe=GKe.hasOwnProperty;function YKe(t,e,r){var i=t[e];(!(jKe.call(t,e)&&HKe(i,r))||r===void 0&&!(e in t))&&UKe(t,e,r)}NZ.exports=YKe});var kd=E((Vgt,LZ)=>{var qKe=9007199254740991,JKe=/^(?:0|[1-9]\d*)$/;function WKe(t,e){var r=typeof t;return e=e==null?qKe:e,!!e&&(r=="number"||r!="symbol"&&JKe.test(t))&&t>-1&&t%1==0&&t{var zKe=XB(),VKe=Gg(),_Ke=kd(),MZ=Gs(),XKe=Sc();function ZKe(t,e,r,i){if(!MZ(t))return t;e=VKe(e,t);for(var n=-1,s=e.length,o=s-1,a=t;a!=null&&++n{var $Ke=xd(),e1e=tF(),t1e=Gg();function r1e(t,e,r){for(var i=-1,n=e.length,s={};++i{function i1e(t,e){return t!=null&&e in Object(t)}UZ.exports=i1e});var jZ=E(($gt,GZ)=>{var n1e=Ac(),s1e=Qo(),o1e="[object Arguments]";function a1e(t){return s1e(t)&&n1e(t)==o1e}GZ.exports=a1e});var Pd=E((eft,YZ)=>{var qZ=jZ(),A1e=Qo(),JZ=Object.prototype,l1e=JZ.hasOwnProperty,c1e=JZ.propertyIsEnumerable,u1e=qZ(function(){return arguments}())?qZ:function(t){return A1e(t)&&l1e.call(t,"callee")&&!c1e.call(t,"callee")};YZ.exports=u1e});var ZB=E((tft,WZ)=>{var g1e=9007199254740991;function f1e(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=g1e}WZ.exports=f1e});var rF=E((rft,zZ)=>{var h1e=Gg(),p1e=Pd(),d1e=As(),C1e=kd(),m1e=ZB(),E1e=Sc();function I1e(t,e,r){e=h1e(e,t);for(var i=-1,n=e.length,s=!1;++i{var y1e=HZ(),w1e=rF();function B1e(t,e){return t!=null&&w1e(t,e,y1e)}VZ.exports=B1e});var XZ=E((nft,_Z)=>{var Q1e=KZ(),b1e=iF();function v1e(t,e){return Q1e(t,e,function(r,i){return b1e(t,i)})}_Z.exports=v1e});var $B=E((sft,ZZ)=>{function S1e(t,e){for(var r=-1,i=e.length,n=t.length;++r{var e$=ac(),x1e=Pd(),k1e=As(),t$=e$?e$.isConcatSpreadable:void 0;function P1e(t){return k1e(t)||x1e(t)||!!(t$&&t&&t[t$])}$Z.exports=P1e});var s$=E((aft,i$)=>{var D1e=$B(),R1e=r$();function n$(t,e,r,i,n){var s=-1,o=t.length;for(r||(r=R1e),n||(n=[]);++s0&&r(a)?e>1?n$(a,e-1,r,i,n):D1e(n,a):i||(n[n.length]=a)}return n}i$.exports=n$});var a$=E((Aft,o$)=>{var F1e=s$();function N1e(t){var e=t==null?0:t.length;return e?F1e(t,1):[]}o$.exports=N1e});var l$=E((lft,A$)=>{function L1e(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}A$.exports=L1e});var nF=E((cft,c$)=>{var T1e=l$(),u$=Math.max;function M1e(t,e,r){return e=u$(e===void 0?t.length-1:e,0),function(){for(var i=arguments,n=-1,s=u$(i.length-e,0),o=Array(s);++n{function O1e(t){return function(){return t}}g$.exports=O1e});var e0=E((gft,h$)=>{function K1e(t){return t}h$.exports=K1e});var C$=E((fft,p$)=>{var U1e=f$(),d$=eF(),H1e=e0(),G1e=d$?function(t,e){return d$(t,"toString",{configurable:!0,enumerable:!1,value:U1e(e),writable:!0})}:H1e;p$.exports=G1e});var E$=E((hft,m$)=>{var j1e=800,Y1e=16,q1e=Date.now;function J1e(t){var e=0,r=0;return function(){var i=q1e(),n=Y1e-(i-r);if(r=i,n>0){if(++e>=j1e)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}m$.exports=J1e});var sF=E((pft,I$)=>{var W1e=C$(),z1e=E$(),V1e=z1e(W1e);I$.exports=V1e});var w$=E((dft,y$)=>{var _1e=a$(),X1e=nF(),Z1e=sF();function $1e(t){return Z1e(X1e(t,void 0,_1e),t+"")}y$.exports=$1e});var Q$=E((Cft,B$)=>{var eUe=XZ(),tUe=w$(),rUe=tUe(function(t,e){return t==null?{}:eUe(t,e)});B$.exports=rUe});var M$=E((lpt,N$)=>{"use strict";var pF;try{pF=Map}catch(t){}var dF;try{dF=Set}catch(t){}function L$(t,e,r){if(!t||typeof t!="object"||typeof t=="function")return t;if(t.nodeType&&"cloneNode"in t)return t.cloneNode(!0);if(t instanceof Date)return new Date(t.getTime());if(t instanceof RegExp)return new RegExp(t);if(Array.isArray(t))return t.map(T$);if(pF&&t instanceof pF)return new Map(Array.from(t.entries()));if(dF&&t instanceof dF)return new Set(Array.from(t.values()));if(t instanceof Object){e.push(t);var i=Object.create(t);r.push(i);for(var n in t){var s=e.findIndex(function(o){return o===t[n]});i[n]=s>-1?r[s]:L$(t[n],e,r)}return i}return t}function T$(t){return L$(t,[],[])}N$.exports=T$});var Nd=E(CF=>{"use strict";Object.defineProperty(CF,"__esModule",{value:!0});CF.default=uUe;var gUe=Object.prototype.toString,fUe=Error.prototype.toString,hUe=RegExp.prototype.toString,pUe=typeof Symbol!="undefined"?Symbol.prototype.toString:()=>"",dUe=/^Symbol\((.*)\)(.*)$/;function CUe(t){return t!=+t?"NaN":t===0&&1/t<0?"-0":""+t}function O$(t,e=!1){if(t==null||t===!0||t===!1)return""+t;let r=typeof t;if(r==="number")return CUe(t);if(r==="string")return e?`"${t}"`:t;if(r==="function")return"[Function "+(t.name||"anonymous")+"]";if(r==="symbol")return pUe.call(t).replace(dUe,"Symbol($1)");let i=gUe.call(t).slice(8,-1);return i==="Date"?isNaN(t.getTime())?""+t:t.toISOString(t):i==="Error"||t instanceof Error?"["+fUe.call(t)+"]":i==="RegExp"?hUe.call(t):null}function uUe(t,e){let r=O$(t,e);return r!==null?r:JSON.stringify(t,function(i,n){let s=O$(this[i],e);return s!==null?s:n},2)}});var La=E(ci=>{"use strict";Object.defineProperty(ci,"__esModule",{value:!0});ci.default=ci.array=ci.object=ci.boolean=ci.date=ci.number=ci.string=ci.mixed=void 0;var K$=mUe(Nd());function mUe(t){return t&&t.__esModule?t:{default:t}}var U$={default:"${path} is invalid",required:"${path} is a required field",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:t,type:e,value:r,originalValue:i})=>{let n=i!=null&&i!==r,s=`${t} must be a \`${e}\` type, but the final value was: \`${(0,K$.default)(r,!0)}\``+(n?` (cast from the value \`${(0,K$.default)(i,!0)}\`).`:".");return r===null&&(s+='\n If "null" is intended as an empty value be sure to mark the schema as `.nullable()`'),s},defined:"${path} must be defined"};ci.mixed=U$;var H$={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"};ci.string=H$;var G$={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"};ci.number=G$;var j$={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"};ci.date=j$;var Y$={isValue:"${path} field must be ${value}"};ci.boolean=Y$;var q$={noUnknown:"${path} field has unspecified keys: ${unknown}"};ci.object=q$;var J$={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must be have ${length} items"};ci.array=J$;var EUe=Object.assign(Object.create(null),{mixed:U$,string:H$,number:G$,date:j$,object:q$,array:J$,boolean:Y$});ci.default=EUe});var z$=E((gpt,W$)=>{var IUe=Object.prototype,yUe=IUe.hasOwnProperty;function wUe(t,e){return t!=null&&yUe.call(t,e)}W$.exports=wUe});var Ld=E((fpt,V$)=>{var BUe=z$(),QUe=rF();function bUe(t,e){return t!=null&&QUe(t,e,BUe)}V$.exports=bUe});var qg=E(n0=>{"use strict";Object.defineProperty(n0,"__esModule",{value:!0});n0.default=void 0;var vUe=t=>t&&t.__isYupSchema__;n0.default=vUe});var Z$=E(s0=>{"use strict";Object.defineProperty(s0,"__esModule",{value:!0});s0.default=void 0;var SUe=_$(Ld()),xUe=_$(qg());function _$(t){return t&&t.__esModule?t:{default:t}}var X$=class{constructor(e,r){if(this.refs=e,this.refs=e,typeof r=="function"){this.fn=r;return}if(!(0,SUe.default)(r,"is"))throw new TypeError("`is:` is required for `when()` conditions");if(!r.then&&!r.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:i,then:n,otherwise:s}=r,o=typeof i=="function"?i:(...a)=>a.every(l=>l===i);this.fn=function(...a){let l=a.pop(),c=a.pop(),u=o(...a)?n:s;if(!!u)return typeof u=="function"?u(c):c.concat(u.resolve(l))}}resolve(e,r){let i=this.refs.map(s=>s.getValue(r==null?void 0:r.value,r==null?void 0:r.parent,r==null?void 0:r.context)),n=this.fn.apply(e,i.concat(e,r));if(n===void 0||n===e)return e;if(!(0,xUe.default)(n))throw new TypeError("conditions must return a schema object");return n.resolve(r)}},kUe=X$;s0.default=kUe});var EF=E(mF=>{"use strict";Object.defineProperty(mF,"__esModule",{value:!0});mF.default=PUe;function PUe(t){return t==null?[]:[].concat(t)}});var xc=E(o0=>{"use strict";Object.defineProperty(o0,"__esModule",{value:!0});o0.default=void 0;var DUe=$$(Nd()),RUe=$$(EF());function $$(t){return t&&t.__esModule?t:{default:t}}function IF(){return IF=Object.assign||function(t){for(var e=1;e(0,DUe.default)(r[s])):typeof e=="function"?e(r):e}static isError(e){return e&&e.name==="ValidationError"}constructor(e,r,i,n){super();this.name="ValidationError",this.value=r,this.path=i,this.type=n,this.errors=[],this.inner=[],(0,RUe.default)(e).forEach(s=>{Td.isError(s)?(this.errors.push(...s.errors),this.inner=this.inner.concat(s.inner.length?s.inner:s)):this.errors.push(s)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0],Error.captureStackTrace&&Error.captureStackTrace(this,Td)}};o0.default=Td});var a0=E(yF=>{"use strict";Object.defineProperty(yF,"__esModule",{value:!0});yF.default=NUe;var wF=LUe(xc());function LUe(t){return t&&t.__esModule?t:{default:t}}var TUe=t=>{let e=!1;return(...r)=>{e||(e=!0,t(...r))}};function NUe(t,e){let{endEarly:r,tests:i,args:n,value:s,errors:o,sort:a,path:l}=t,c=TUe(e),u=i.length,g=[];if(o=o||[],!u)return o.length?c(new wF.default(o,s,l)):c(null,s);for(let f=0;f{function MUe(t){return function(e,r,i){for(var n=-1,s=Object(e),o=i(e),a=o.length;a--;){var l=o[t?a:++n];if(r(s[l],l,s)===!1)break}return e}}eee.exports=MUe});var BF=E((Ipt,ree)=>{var OUe=tee(),KUe=OUe();ree.exports=KUe});var nee=E((ypt,iee)=>{function UUe(t,e){for(var r=-1,i=Array(t);++r{function HUe(){return!1}see.exports=HUe});var Od=E((Md,Jg)=>{var GUe=Ks(),jUe=oee(),aee=typeof Md=="object"&&Md&&!Md.nodeType&&Md,Aee=aee&&typeof Jg=="object"&&Jg&&!Jg.nodeType&&Jg,YUe=Aee&&Aee.exports===aee,lee=YUe?GUe.Buffer:void 0,qUe=lee?lee.isBuffer:void 0,JUe=qUe||jUe;Jg.exports=JUe});var uee=E((Bpt,cee)=>{var WUe=Ac(),zUe=ZB(),VUe=Qo(),_Ue="[object Arguments]",XUe="[object Array]",ZUe="[object Boolean]",$Ue="[object Date]",e2e="[object Error]",t2e="[object Function]",r2e="[object Map]",i2e="[object Number]",n2e="[object Object]",s2e="[object RegExp]",o2e="[object Set]",a2e="[object String]",A2e="[object WeakMap]",l2e="[object ArrayBuffer]",c2e="[object DataView]",u2e="[object Float32Array]",g2e="[object Float64Array]",f2e="[object Int8Array]",h2e="[object Int16Array]",p2e="[object Int32Array]",d2e="[object Uint8Array]",C2e="[object Uint8ClampedArray]",m2e="[object Uint16Array]",E2e="[object Uint32Array]",lr={};lr[u2e]=lr[g2e]=lr[f2e]=lr[h2e]=lr[p2e]=lr[d2e]=lr[C2e]=lr[m2e]=lr[E2e]=!0;lr[_Ue]=lr[XUe]=lr[l2e]=lr[ZUe]=lr[c2e]=lr[$Ue]=lr[e2e]=lr[t2e]=lr[r2e]=lr[i2e]=lr[n2e]=lr[s2e]=lr[o2e]=lr[a2e]=lr[A2e]=!1;function I2e(t){return VUe(t)&&zUe(t.length)&&!!lr[WUe(t)]}cee.exports=I2e});var A0=E((Qpt,gee)=>{function y2e(t){return function(e){return t(e)}}gee.exports=y2e});var l0=E((Kd,Wg)=>{var w2e=WP(),fee=typeof Kd=="object"&&Kd&&!Kd.nodeType&&Kd,Ud=fee&&typeof Wg=="object"&&Wg&&!Wg.nodeType&&Wg,B2e=Ud&&Ud.exports===fee,QF=B2e&&w2e.process,Q2e=function(){try{var t=Ud&&Ud.require&&Ud.require("util").types;return t||QF&&QF.binding&&QF.binding("util")}catch(e){}}();Wg.exports=Q2e});var c0=E((bpt,hee)=>{var b2e=uee(),v2e=A0(),pee=l0(),dee=pee&&pee.isTypedArray,S2e=dee?v2e(dee):b2e;hee.exports=S2e});var bF=E((vpt,Cee)=>{var x2e=nee(),k2e=Pd(),P2e=As(),D2e=Od(),R2e=kd(),F2e=c0(),N2e=Object.prototype,L2e=N2e.hasOwnProperty;function T2e(t,e){var r=P2e(t),i=!r&&k2e(t),n=!r&&!i&&D2e(t),s=!r&&!i&&!n&&F2e(t),o=r||i||n||s,a=o?x2e(t.length,String):[],l=a.length;for(var c in t)(e||L2e.call(t,c))&&!(o&&(c=="length"||n&&(c=="offset"||c=="parent")||s&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||R2e(c,l)))&&a.push(c);return a}Cee.exports=T2e});var u0=E((Spt,mee)=>{var M2e=Object.prototype;function O2e(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||M2e;return t===r}mee.exports=O2e});var vF=E((xpt,Eee)=>{function K2e(t,e){return function(r){return t(e(r))}}Eee.exports=K2e});var yee=E((kpt,Iee)=>{var U2e=vF(),H2e=U2e(Object.keys,Object);Iee.exports=H2e});var Bee=E((Ppt,wee)=>{var G2e=u0(),j2e=yee(),Y2e=Object.prototype,q2e=Y2e.hasOwnProperty;function J2e(t){if(!G2e(t))return j2e(t);var e=[];for(var r in Object(t))q2e.call(t,r)&&r!="constructor"&&e.push(r);return e}wee.exports=J2e});var Hd=E((Dpt,Qee)=>{var W2e=zB(),z2e=ZB();function V2e(t){return t!=null&&z2e(t.length)&&!W2e(t)}Qee.exports=V2e});var zg=E((Rpt,bee)=>{var _2e=bF(),X2e=Bee(),Z2e=Hd();function $2e(t){return Z2e(t)?_2e(t):X2e(t)}bee.exports=$2e});var SF=E((Fpt,vee)=>{var eHe=BF(),tHe=zg();function rHe(t,e){return t&&eHe(t,e,tHe)}vee.exports=rHe});var xee=E((Npt,See)=>{var iHe=vd();function nHe(){this.__data__=new iHe,this.size=0}See.exports=nHe});var Pee=E((Lpt,kee)=>{function sHe(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}kee.exports=sHe});var Ree=E((Tpt,Dee)=>{function oHe(t){return this.__data__.get(t)}Dee.exports=oHe});var Nee=E((Mpt,Fee)=>{function aHe(t){return this.__data__.has(t)}Fee.exports=aHe});var Tee=E((Opt,Lee)=>{var AHe=vd(),lHe=VB(),cHe=_B(),uHe=200;function gHe(t,e){var r=this.__data__;if(r instanceof AHe){var i=r.__data__;if(!lHe||i.length{var fHe=vd(),hHe=xee(),pHe=Pee(),dHe=Ree(),CHe=Nee(),mHe=Tee();function Vg(t){var e=this.__data__=new fHe(t);this.size=e.size}Vg.prototype.clear=hHe;Vg.prototype.delete=pHe;Vg.prototype.get=dHe;Vg.prototype.has=CHe;Vg.prototype.set=mHe;Mee.exports=Vg});var Kee=E((Upt,Oee)=>{var EHe="__lodash_hash_undefined__";function IHe(t){return this.__data__.set(t,EHe),this}Oee.exports=IHe});var Hee=E((Hpt,Uee)=>{function yHe(t){return this.__data__.has(t)}Uee.exports=yHe});var jee=E((Gpt,Gee)=>{var wHe=_B(),BHe=Kee(),QHe=Hee();function g0(t){var e=-1,r=t==null?0:t.length;for(this.__data__=new wHe;++e{function bHe(t,e){for(var r=-1,i=t==null?0:t.length;++r{function vHe(t,e){return t.has(e)}Jee.exports=vHe});var xF=E((qpt,zee)=>{var SHe=jee(),xHe=qee(),kHe=Wee(),PHe=1,DHe=2;function RHe(t,e,r,i,n,s){var o=r&PHe,a=t.length,l=e.length;if(a!=l&&!(o&&l>a))return!1;var c=s.get(t),u=s.get(e);if(c&&u)return c==e&&u==t;var g=-1,f=!0,h=r&DHe?new SHe:void 0;for(s.set(t,e),s.set(e,t);++g{var FHe=Ks(),NHe=FHe.Uint8Array;Vee.exports=NHe});var Xee=E((Wpt,_ee)=>{function LHe(t){var e=-1,r=Array(t.size);return t.forEach(function(i,n){r[++e]=[n,i]}),r}_ee.exports=LHe});var $ee=E((zpt,Zee)=>{function THe(t){var e=-1,r=Array(t.size);return t.forEach(function(i){r[++e]=i}),r}Zee.exports=THe});var nte=E((Vpt,ete)=>{var tte=ac(),rte=kF(),MHe=Kg(),OHe=xF(),KHe=Xee(),UHe=$ee(),HHe=1,GHe=2,jHe="[object Boolean]",YHe="[object Date]",qHe="[object Error]",JHe="[object Map]",WHe="[object Number]",zHe="[object RegExp]",VHe="[object Set]",_He="[object String]",XHe="[object Symbol]",ZHe="[object ArrayBuffer]",$He="[object DataView]",ite=tte?tte.prototype:void 0,PF=ite?ite.valueOf:void 0;function eGe(t,e,r,i,n,s,o){switch(r){case $He:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case ZHe:return!(t.byteLength!=e.byteLength||!s(new rte(t),new rte(e)));case jHe:case YHe:case WHe:return MHe(+t,+e);case qHe:return t.name==e.name&&t.message==e.message;case zHe:case _He:return t==e+"";case JHe:var a=KHe;case VHe:var l=i&HHe;if(a||(a=UHe),t.size!=e.size&&!l)return!1;var c=o.get(t);if(c)return c==e;i|=GHe,o.set(t,e);var u=OHe(a(t),a(e),i,n,s,o);return o.delete(t),u;case XHe:if(PF)return PF.call(t)==PF.call(e)}return!1}ete.exports=eGe});var DF=E((_pt,ste)=>{var tGe=$B(),rGe=As();function iGe(t,e,r){var i=e(t);return rGe(t)?i:tGe(i,r(t))}ste.exports=iGe});var ate=E((Xpt,ote)=>{function nGe(t,e){for(var r=-1,i=t==null?0:t.length,n=0,s=[];++r{function sGe(){return[]}Ate.exports=sGe});var f0=E(($pt,lte)=>{var oGe=ate(),aGe=RF(),AGe=Object.prototype,lGe=AGe.propertyIsEnumerable,cte=Object.getOwnPropertySymbols,cGe=cte?function(t){return t==null?[]:(t=Object(t),oGe(cte(t),function(e){return lGe.call(t,e)}))}:aGe;lte.exports=cGe});var FF=E((edt,ute)=>{var uGe=DF(),gGe=f0(),fGe=zg();function hGe(t){return uGe(t,fGe,gGe)}ute.exports=hGe});var hte=E((tdt,gte)=>{var fte=FF(),pGe=1,dGe=Object.prototype,CGe=dGe.hasOwnProperty;function mGe(t,e,r,i,n,s){var o=r&pGe,a=fte(t),l=a.length,c=fte(e),u=c.length;if(l!=u&&!o)return!1;for(var g=l;g--;){var f=a[g];if(!(o?f in e:CGe.call(e,f)))return!1}var h=s.get(t),p=s.get(e);if(h&&p)return h==e&&p==t;var d=!0;s.set(t,e),s.set(e,t);for(var m=o;++g{var EGe=UA(),IGe=Ks(),yGe=EGe(IGe,"DataView");pte.exports=yGe});var mte=E((idt,Cte)=>{var wGe=UA(),BGe=Ks(),QGe=wGe(BGe,"Promise");Cte.exports=QGe});var Ite=E((ndt,Ete)=>{var bGe=UA(),vGe=Ks(),SGe=bGe(vGe,"Set");Ete.exports=SGe});var wte=E((sdt,yte)=>{var xGe=UA(),kGe=Ks(),PGe=xGe(kGe,"WeakMap");yte.exports=PGe});var jd=E((odt,Bte)=>{var NF=dte(),LF=VB(),TF=mte(),MF=Ite(),OF=wte(),Qte=Ac(),_g=ZR(),bte="[object Map]",DGe="[object Object]",vte="[object Promise]",Ste="[object Set]",xte="[object WeakMap]",kte="[object DataView]",RGe=_g(NF),FGe=_g(LF),NGe=_g(TF),LGe=_g(MF),TGe=_g(OF),kc=Qte;(NF&&kc(new NF(new ArrayBuffer(1)))!=kte||LF&&kc(new LF)!=bte||TF&&kc(TF.resolve())!=vte||MF&&kc(new MF)!=Ste||OF&&kc(new OF)!=xte)&&(kc=function(t){var e=Qte(t),r=e==DGe?t.constructor:void 0,i=r?_g(r):"";if(i)switch(i){case RGe:return kte;case FGe:return bte;case NGe:return vte;case LGe:return Ste;case TGe:return xte}return e});Bte.exports=kc});var Mte=E((adt,Pte)=>{var KF=Gd(),MGe=xF(),OGe=nte(),KGe=hte(),Dte=jd(),Rte=As(),Fte=Od(),UGe=c0(),HGe=1,Nte="[object Arguments]",Lte="[object Array]",h0="[object Object]",GGe=Object.prototype,Tte=GGe.hasOwnProperty;function jGe(t,e,r,i,n,s){var o=Rte(t),a=Rte(e),l=o?Lte:Dte(t),c=a?Lte:Dte(e);l=l==Nte?h0:l,c=c==Nte?h0:c;var u=l==h0,g=c==h0,f=l==c;if(f&&Fte(t)){if(!Fte(e))return!1;o=!0,u=!1}if(f&&!u)return s||(s=new KF),o||UGe(t)?MGe(t,e,r,i,n,s):OGe(t,e,l,r,i,n,s);if(!(r&HGe)){var h=u&&Tte.call(t,"__wrapped__"),p=g&&Tte.call(e,"__wrapped__");if(h||p){var d=h?t.value():t,m=p?e.value():e;return s||(s=new KF),n(d,m,r,i,s)}}return f?(s||(s=new KF),KGe(t,e,r,i,n,s)):!1}Pte.exports=jGe});var UF=E((Adt,Ote)=>{var YGe=Mte(),Kte=Qo();function Ute(t,e,r,i,n){return t===e?!0:t==null||e==null||!Kte(t)&&!Kte(e)?t!==t&&e!==e:YGe(t,e,r,i,Ute,n)}Ote.exports=Ute});var Gte=E((ldt,Hte)=>{var qGe=Gd(),JGe=UF(),WGe=1,zGe=2;function VGe(t,e,r,i){var n=r.length,s=n,o=!i;if(t==null)return!s;for(t=Object(t);n--;){var a=r[n];if(o&&a[2]?a[1]!==t[a[0]]:!(a[0]in t))return!1}for(;++n{var _Ge=Gs();function XGe(t){return t===t&&!_Ge(t)}jte.exports=XGe});var qte=E((udt,Yte)=>{var ZGe=HF(),$Ge=zg();function eje(t){for(var e=$Ge(t),r=e.length;r--;){var i=e[r],n=t[i];e[r]=[i,n,ZGe(n)]}return e}Yte.exports=eje});var GF=E((gdt,Jte)=>{function tje(t,e){return function(r){return r==null?!1:r[t]===e&&(e!==void 0||t in Object(r))}}Jte.exports=tje});var zte=E((fdt,Wte)=>{var rje=Gte(),ije=qte(),nje=GF();function sje(t){var e=ije(t);return e.length==1&&e[0][2]?nje(e[0][0],e[0][1]):function(r){return r===t||rje(r,t,e)}}Wte.exports=sje});var p0=E((hdt,Vte)=>{var oje=xd();function aje(t,e,r){var i=t==null?void 0:oje(t,e);return i===void 0?r:i}Vte.exports=aje});var Xte=E((pdt,_te)=>{var Aje=UF(),lje=p0(),cje=iF(),uje=WB(),gje=HF(),fje=GF(),hje=Sc(),pje=1,dje=2;function Cje(t,e){return uje(t)&&gje(e)?fje(hje(t),e):function(r){var i=lje(r,t);return i===void 0&&i===e?cje(r,t):Aje(e,i,pje|dje)}}_te.exports=Cje});var $te=E((ddt,Zte)=>{function mje(t){return function(e){return e==null?void 0:e[t]}}Zte.exports=mje});var tre=E((Cdt,ere)=>{var Eje=xd();function Ije(t){return function(e){return Eje(e,t)}}ere.exports=Ije});var ire=E((mdt,rre)=>{var yje=$te(),wje=tre(),Bje=WB(),Qje=Sc();function bje(t){return Bje(t)?yje(Qje(t)):wje(t)}rre.exports=bje});var jF=E((Edt,nre)=>{var vje=zte(),Sje=Xte(),xje=e0(),kje=As(),Pje=ire();function Dje(t){return typeof t=="function"?t:t==null?xje:typeof t=="object"?kje(t)?Sje(t[0],t[1]):vje(t):Pje(t)}nre.exports=Dje});var YF=E((Idt,sre)=>{var Rje=jg(),Fje=SF(),Nje=jF();function Lje(t,e){var r={};return e=Nje(e,3),Fje(t,function(i,n,s){Rje(r,n,e(i,n,s))}),r}sre.exports=Lje});var Yd=E((ydt,ore)=>{"use strict";function Pc(t){this._maxSize=t,this.clear()}Pc.prototype.clear=function(){this._size=0,this._values=Object.create(null)};Pc.prototype.get=function(t){return this._values[t]};Pc.prototype.set=function(t,e){return this._size>=this._maxSize&&this.clear(),t in this._values||this._size++,this._values[t]=e};var Tje=/[^.^\]^[]+|(?=\[\]|\.\.)/g,are=/^\d+$/,Mje=/^\d/,Oje=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,Kje=/^\s*(['"]?)(.*?)(\1)\s*$/,qF=512,Are=new Pc(qF),lre=new Pc(qF),cre=new Pc(qF);ore.exports={Cache:Pc,split:WF,normalizePath:JF,setter:function(t){var e=JF(t);return lre.get(t)||lre.set(t,function(i,n){for(var s=0,o=e.length,a=i;s{"use strict";Object.defineProperty(qd,"__esModule",{value:!0});qd.create=Yje;qd.default=void 0;var qje=Yd(),d0={context:"$",value:"."};function Yje(t,e){return new C0(t,e)}var C0=class{constructor(e,r={}){if(typeof e!="string")throw new TypeError("ref must be a string, got: "+e);if(this.key=e.trim(),e==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===d0.context,this.isValue=this.key[0]===d0.value,this.isSibling=!this.isContext&&!this.isValue;let i=this.isContext?d0.context:this.isValue?d0.value:"";this.path=this.key.slice(i.length),this.getter=this.path&&(0,qje.getter)(this.path,!0),this.map=r.map}getValue(e,r,i){let n=this.isContext?i:this.isValue?e:r;return this.getter&&(n=this.getter(n||{})),this.map&&(n=this.map(n)),n}cast(e,r){return this.getValue(e,r==null?void 0:r.parent,r==null?void 0:r.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(e){return e&&e.__isYupRef}};qd.default=C0;C0.prototype.__isYupRef=!0});var ure=E(VF=>{"use strict";Object.defineProperty(VF,"__esModule",{value:!0});VF.default=Jje;var Wje=_F(YF()),m0=_F(xc()),zje=_F(Dc());function _F(t){return t&&t.__esModule?t:{default:t}}function E0(){return E0=Object.assign||function(t){for(var e=1;e=0)&&(r[n]=t[n]);return r}function Jje(t){function e(r,i){let{value:n,path:s="",label:o,options:a,originalValue:l,sync:c}=r,u=Vje(r,["value","path","label","options","originalValue","sync"]),{name:g,test:f,params:h,message:p}=t,{parent:d,context:m}=a;function I(L){return zje.default.isRef(L)?L.getValue(n,d,m):L}function B(L={}){let K=(0,Wje.default)(E0({value:n,originalValue:l,label:o,path:L.path||s},h,L.params),I),J=new m0.default(m0.default.formatError(L.message||p,K),n,K.path,L.type||g);return J.params=K,J}let b=E0({path:s,parent:d,type:g,createError:B,resolve:I,options:a,originalValue:l},u);if(!c){try{Promise.resolve(f.call(b,n,b)).then(L=>{m0.default.isError(L)?i(L):L?i(null,L):i(B())})}catch(L){i(L)}return}let R;try{var H;if(R=f.call(b,n,b),typeof((H=R)==null?void 0:H.then)=="function")throw new Error(`Validation test of type: "${b.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`)}catch(L){i(L);return}m0.default.isError(R)?i(R):R?i(null,R):i(B())}return e.OPTIONS=t,e}});var XF=E(Jd=>{"use strict";Object.defineProperty(Jd,"__esModule",{value:!0});Jd.getIn=gre;Jd.default=void 0;var _je=Yd(),Xje=t=>t.substr(0,t.length-1).substr(1);function gre(t,e,r,i=r){let n,s,o;return e?((0,_je.forEach)(e,(a,l,c)=>{let u=l?Xje(a):a;if(t=t.resolve({context:i,parent:n,value:r}),t.innerType){let g=c?parseInt(u,10):0;if(r&&g>=r.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${a}, in the path: ${e}. because there is no value at that index. `);n=r,r=r&&r[g],t=t.innerType}if(!c){if(!t.fields||!t.fields[u])throw new Error(`The schema does not contain the path: ${e}. (failed at: ${o} which is a type: "${t._type}")`);n=r,r=r&&r[u],t=t.fields[u]}s=u,o=l?"["+a+"]":"."+a}),{schema:t,parent:n,parentPath:s}):{parent:n,parentPath:e,schema:t}}var Zje=(t,e,r,i)=>gre(t,e,r,i).schema,$je=Zje;Jd.default=$je});var hre=E(I0=>{"use strict";Object.defineProperty(I0,"__esModule",{value:!0});I0.default=void 0;var fre=eYe(Dc());function eYe(t){return t&&t.__esModule?t:{default:t}}var y0=class{constructor(){this.list=new Set,this.refs=new Map}get size(){return this.list.size+this.refs.size}describe(){let e=[];for(let r of this.list)e.push(r);for(let[,r]of this.refs)e.push(r.describe());return e}toArray(){return Array.from(this.list).concat(Array.from(this.refs.values()))}add(e){fre.default.isRef(e)?this.refs.set(e.key,e):this.list.add(e)}delete(e){fre.default.isRef(e)?this.refs.delete(e.key):this.list.delete(e)}has(e,r){if(this.list.has(e))return!0;let i,n=this.refs.values();for(;i=n.next(),!i.done;)if(r(i.value)===e)return!0;return!1}clone(){let e=new y0;return e.list=new Set(this.list),e.refs=new Map(this.refs),e}merge(e,r){let i=this.clone();return e.list.forEach(n=>i.add(n)),e.refs.forEach(n=>i.add(n)),r.list.forEach(n=>i.delete(n)),r.refs.forEach(n=>i.delete(n)),i}};I0.default=y0});var Ma=E(w0=>{"use strict";Object.defineProperty(w0,"__esModule",{value:!0});w0.default=void 0;var pre=Ta(M$()),Xg=La(),tYe=Ta(Z$()),dre=Ta(a0()),B0=Ta(ure()),Cre=Ta(Nd()),rYe=Ta(Dc()),iYe=XF(),nYe=Ta(EF()),mre=Ta(xc()),Ere=Ta(hre());function Ta(t){return t&&t.__esModule?t:{default:t}}function ds(){return ds=Object.assign||function(t){for(var e=1;e{this.typeError(Xg.mixed.notType)}),this.type=(e==null?void 0:e.type)||"mixed",this.spec=ds({strip:!1,strict:!1,abortEarly:!0,recursive:!0,nullable:!1,presence:"optional"},e==null?void 0:e.spec)}get _type(){return this.type}_typeCheck(e){return!0}clone(e){if(this._mutate)return e&&Object.assign(this.spec,e),this;let r=Object.create(Object.getPrototypeOf(this));return r.type=this.type,r._typeError=this._typeError,r._whitelistError=this._whitelistError,r._blacklistError=this._blacklistError,r._whitelist=this._whitelist.clone(),r._blacklist=this._blacklist.clone(),r.exclusiveTests=ds({},this.exclusiveTests),r.deps=[...this.deps],r.conditions=[...this.conditions],r.tests=[...this.tests],r.transforms=[...this.transforms],r.spec=(0,pre.default)(ds({},this.spec,e)),r}label(e){var r=this.clone();return r.spec.label=e,r}meta(...e){if(e.length===0)return this.spec.meta;let r=this.clone();return r.spec.meta=Object.assign(r.spec.meta||{},e[0]),r}withMutation(e){let r=this._mutate;this._mutate=!0;let i=e(this);return this._mutate=r,i}concat(e){if(!e||e===this)return this;if(e.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${e.type}`);let r=this,i=e.clone(),n=ds({},r.spec,i.spec);return i.spec=n,i._typeError||(i._typeError=r._typeError),i._whitelistError||(i._whitelistError=r._whitelistError),i._blacklistError||(i._blacklistError=r._blacklistError),i._whitelist=r._whitelist.merge(e._whitelist,e._blacklist),i._blacklist=r._blacklist.merge(e._blacklist,e._whitelist),i.tests=r.tests,i.exclusiveTests=r.exclusiveTests,i.withMutation(s=>{e.tests.forEach(o=>{s.test(o.OPTIONS)})}),i}isType(e){return this.spec.nullable&&e===null?!0:this._typeCheck(e)}resolve(e){let r=this;if(r.conditions.length){let i=r.conditions;r=r.clone(),r.conditions=[],r=i.reduce((n,s)=>s.resolve(n,e),r),r=r.resolve(e)}return r}cast(e,r={}){let i=this.resolve(ds({value:e},r)),n=i._cast(e,r);if(e!==void 0&&r.assert!==!1&&i.isType(n)!==!0){let s=(0,Cre.default)(e),o=(0,Cre.default)(n);throw new TypeError(`The value of ${r.path||"field"} could not be cast to a value that satisfies the schema type: "${i._type}". - -attempted value: ${s} -`+(o!==s?`result of cast: ${o}`:""))}return n}_cast(e,r){let i=e===void 0?e:this.transforms.reduce((n,s)=>s.call(this,n,e,this),e);return i===void 0&&(i=this.getDefault()),i}_validate(e,r={},i){let{sync:n,path:s,from:o=[],originalValue:a=e,strict:l=this.spec.strict,abortEarly:c=this.spec.abortEarly}=r,u=e;l||(u=this._cast(u,ds({assert:!1},r)));let g={value:u,path:s,options:r,originalValue:a,schema:this,label:this.spec.label,sync:n,from:o},f=[];this._typeError&&f.push(this._typeError),this._whitelistError&&f.push(this._whitelistError),this._blacklistError&&f.push(this._blacklistError),(0,dre.default)({args:g,value:u,path:s,sync:n,tests:f,endEarly:c},h=>{if(h)return void i(h,u);(0,dre.default)({tests:this.tests,args:g,path:s,sync:n,value:u,endEarly:c},i)})}validate(e,r,i){let n=this.resolve(ds({},r,{value:e}));return typeof i=="function"?n._validate(e,r,i):new Promise((s,o)=>n._validate(e,r,(a,l)=>{a?o(a):s(l)}))}validateSync(e,r){let i=this.resolve(ds({},r,{value:e})),n;return i._validate(e,ds({},r,{sync:!0}),(s,o)=>{if(s)throw s;n=o}),n}isValid(e,r){return this.validate(e,r).then(()=>!0,i=>{if(mre.default.isError(i))return!1;throw i})}isValidSync(e,r){try{return this.validateSync(e,r),!0}catch(i){if(mre.default.isError(i))return!1;throw i}}_getDefault(){let e=this.spec.default;return e==null?e:typeof e=="function"?e.call(this):(0,pre.default)(e)}getDefault(e){return this.resolve(e||{})._getDefault()}default(e){return arguments.length===0?this._getDefault():this.clone({default:e})}strict(e=!0){var r=this.clone();return r.spec.strict=e,r}_isPresent(e){return e!=null}defined(e=Xg.mixed.defined){return this.test({message:e,name:"defined",exclusive:!0,test(r){return r!==void 0}})}required(e=Xg.mixed.required){return this.clone({presence:"required"}).withMutation(r=>r.test({message:e,name:"required",exclusive:!0,test(i){return this.schema._isPresent(i)}}))}notRequired(){var e=this.clone({presence:"optional"});return e.tests=e.tests.filter(r=>r.OPTIONS.name!=="required"),e}nullable(e=!0){var r=this.clone({nullable:e!==!1});return r}transform(e){var r=this.clone();return r.transforms.push(e),r}test(...e){let r;if(e.length===1?typeof e[0]=="function"?r={test:e[0]}:r=e[0]:e.length===2?r={name:e[0],test:e[1]}:r={name:e[0],message:e[1],test:e[2]},r.message===void 0&&(r.message=Xg.mixed.default),typeof r.test!="function")throw new TypeError("`test` is a required parameters");let i=this.clone(),n=(0,B0.default)(r),s=r.exclusive||r.name&&i.exclusiveTests[r.name]===!0;if(r.exclusive&&!r.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return r.name&&(i.exclusiveTests[r.name]=!!r.exclusive),i.tests=i.tests.filter(o=>!(o.OPTIONS.name===r.name&&(s||o.OPTIONS.test===n.OPTIONS.test))),i.tests.push(n),i}when(e,r){!Array.isArray(e)&&typeof e!="string"&&(r=e,e=".");let i=this.clone(),n=(0,nYe.default)(e).map(s=>new rYe.default(s));return n.forEach(s=>{s.isSibling&&i.deps.push(s.key)}),i.conditions.push(new tYe.default(n,r)),i}typeError(e){var r=this.clone();return r._typeError=(0,B0.default)({message:e,name:"typeError",test(i){return i!==void 0&&!this.schema.isType(i)?this.createError({params:{type:this.schema._type}}):!0}}),r}oneOf(e,r=Xg.mixed.oneOf){var i=this.clone();return e.forEach(n=>{i._whitelist.add(n),i._blacklist.delete(n)}),i._whitelistError=(0,B0.default)({message:r,name:"oneOf",test(n){if(n===void 0)return!0;let s=this.schema._whitelist;return s.has(n,this.resolve)?!0:this.createError({params:{values:s.toArray().join(", ")}})}}),i}notOneOf(e,r=Xg.mixed.notOneOf){var i=this.clone();return e.forEach(n=>{i._blacklist.add(n),i._whitelist.delete(n)}),i._blacklistError=(0,B0.default)({message:r,name:"notOneOf",test(n){let s=this.schema._blacklist;return s.has(n,this.resolve)?this.createError({params:{values:s.toArray().join(", ")}}):!0}}),i}strip(e=!0){let r=this.clone();return r.spec.strip=e,r}describe(){let e=this.clone(),{label:r,meta:i}=e.spec;return{meta:i,label:r,type:e.type,oneOf:e._whitelist.describe(),notOneOf:e._blacklist.describe(),tests:e.tests.map(s=>({name:s.OPTIONS.name,params:s.OPTIONS.params})).filter((s,o,a)=>a.findIndex(l=>l.name===s.name)===o)}}};w0.default=Do;Do.prototype.__isYupSchema__=!0;for(let t of["validate","validateSync"])Do.prototype[`${t}At`]=function(e,r,i={}){let{parent:n,parentPath:s,schema:o}=(0,iYe.getIn)(this,e,r,i.context);return o[t](n&&n[s],ds({},i,{parent:n,path:e}))};for(let t of["equals","is"])Do.prototype[t]=Do.prototype.oneOf;for(let t of["not","nope"])Do.prototype[t]=Do.prototype.notOneOf;Do.prototype.optional=Do.prototype.notRequired});var yre=E(Wd=>{"use strict";Object.defineProperty(Wd,"__esModule",{value:!0});Wd.create=Ire;Wd.default=void 0;var oYe=sYe(Ma());function sYe(t){return t&&t.__esModule?t:{default:t}}var ZF=oYe.default,aYe=ZF;Wd.default=aYe;function Ire(){return new ZF}Ire.prototype=ZF.prototype});var Zg=E(Q0=>{"use strict";Object.defineProperty(Q0,"__esModule",{value:!0});Q0.default=void 0;var AYe=t=>t==null;Q0.default=AYe});var vre=E(zd=>{"use strict";Object.defineProperty(zd,"__esModule",{value:!0});zd.create=wre;zd.default=void 0;var lYe=Bre(Ma()),Qre=La(),bre=Bre(Zg());function Bre(t){return t&&t.__esModule?t:{default:t}}function wre(){return new b0}var b0=class extends lYe.default{constructor(){super({type:"boolean"});this.withMutation(()=>{this.transform(function(e){if(!this.isType(e)){if(/^(true|1)$/i.test(String(e)))return!0;if(/^(false|0)$/i.test(String(e)))return!1}return e})})}_typeCheck(e){return e instanceof Boolean&&(e=e.valueOf()),typeof e=="boolean"}isTrue(e=Qre.boolean.isValue){return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"true"},test(r){return(0,bre.default)(r)||r===!0}})}isFalse(e=Qre.boolean.isValue){return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"false"},test(r){return(0,bre.default)(r)||r===!1}})}};zd.default=b0;wre.prototype=b0.prototype});var kre=E(Vd=>{"use strict";Object.defineProperty(Vd,"__esModule",{value:!0});Vd.create=Sre;Vd.default=void 0;var Ro=La(),Oa=xre(Zg()),cYe=xre(Ma());function xre(t){return t&&t.__esModule?t:{default:t}}var uYe=/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))$/i,gYe=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,fYe=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,hYe=t=>(0,Oa.default)(t)||t===t.trim(),pYe={}.toString();function Sre(){return new v0}var v0=class extends cYe.default{constructor(){super({type:"string"});this.withMutation(()=>{this.transform(function(e){if(this.isType(e)||Array.isArray(e))return e;let r=e!=null&&e.toString?e.toString():e;return r===pYe?e:r})})}_typeCheck(e){return e instanceof String&&(e=e.valueOf()),typeof e=="string"}_isPresent(e){return super._isPresent(e)&&!!e.length}length(e,r=Ro.string.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:e},test(i){return(0,Oa.default)(i)||i.length===this.resolve(e)}})}min(e,r=Ro.string.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:e},test(i){return(0,Oa.default)(i)||i.length>=this.resolve(e)}})}max(e,r=Ro.string.max){return this.test({name:"max",exclusive:!0,message:r,params:{max:e},test(i){return(0,Oa.default)(i)||i.length<=this.resolve(e)}})}matches(e,r){let i=!1,n,s;return r&&(typeof r=="object"?{excludeEmptyString:i=!1,message:n,name:s}=r:n=r),this.test({name:s||"matches",message:n||Ro.string.matches,params:{regex:e},test:o=>(0,Oa.default)(o)||o===""&&i||o.search(e)!==-1})}email(e=Ro.string.email){return this.matches(uYe,{name:"email",message:e,excludeEmptyString:!0})}url(e=Ro.string.url){return this.matches(gYe,{name:"url",message:e,excludeEmptyString:!0})}uuid(e=Ro.string.uuid){return this.matches(fYe,{name:"uuid",message:e,excludeEmptyString:!1})}ensure(){return this.default("").transform(e=>e===null?"":e)}trim(e=Ro.string.trim){return this.transform(r=>r!=null?r.trim():r).test({message:e,name:"trim",test:hYe})}lowercase(e=Ro.string.lowercase){return this.transform(r=>(0,Oa.default)(r)?r:r.toLowerCase()).test({message:e,name:"string_case",exclusive:!0,test:r=>(0,Oa.default)(r)||r===r.toLowerCase()})}uppercase(e=Ro.string.uppercase){return this.transform(r=>(0,Oa.default)(r)?r:r.toUpperCase()).test({message:e,name:"string_case",exclusive:!0,test:r=>(0,Oa.default)(r)||r===r.toUpperCase()})}};Vd.default=v0;Sre.prototype=v0.prototype});var Rre=E(_d=>{"use strict";Object.defineProperty(_d,"__esModule",{value:!0});_d.create=Pre;_d.default=void 0;var Rc=La(),Fc=Dre(Zg()),dYe=Dre(Ma());function Dre(t){return t&&t.__esModule?t:{default:t}}var CYe=t=>t!=+t;function Pre(){return new S0}var S0=class extends dYe.default{constructor(){super({type:"number"});this.withMutation(()=>{this.transform(function(e){let r=e;if(typeof r=="string"){if(r=r.replace(/\s/g,""),r==="")return NaN;r=+r}return this.isType(r)?r:parseFloat(r)})})}_typeCheck(e){return e instanceof Number&&(e=e.valueOf()),typeof e=="number"&&!CYe(e)}min(e,r=Rc.number.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:e},test(i){return(0,Fc.default)(i)||i>=this.resolve(e)}})}max(e,r=Rc.number.max){return this.test({message:r,name:"max",exclusive:!0,params:{max:e},test(i){return(0,Fc.default)(i)||i<=this.resolve(e)}})}lessThan(e,r=Rc.number.lessThan){return this.test({message:r,name:"max",exclusive:!0,params:{less:e},test(i){return(0,Fc.default)(i)||ithis.resolve(e)}})}positive(e=Rc.number.positive){return this.moreThan(0,e)}negative(e=Rc.number.negative){return this.lessThan(0,e)}integer(e=Rc.number.integer){return this.test({name:"integer",message:e,test:r=>(0,Fc.default)(r)||Number.isInteger(r)})}truncate(){return this.transform(e=>(0,Fc.default)(e)?e:e|0)}round(e){var r,i=["ceil","floor","round","trunc"];if(e=((r=e)==null?void 0:r.toLowerCase())||"round",e==="trunc")return this.truncate();if(i.indexOf(e.toLowerCase())===-1)throw new TypeError("Only valid options for round() are: "+i.join(", "));return this.transform(n=>(0,Fc.default)(n)?n:Math[e](n))}};_d.default=S0;Pre.prototype=S0.prototype});var Fre=E($F=>{"use strict";Object.defineProperty($F,"__esModule",{value:!0});$F.default=mYe;var EYe=/^(\d{4}|[+\-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,\.](\d{1,}))?)?(?:(Z)|([+\-])(\d{2})(?::?(\d{2}))?)?)?$/;function mYe(t){var e=[1,4,5,6,7,10,11],r=0,i,n;if(n=EYe.exec(t)){for(var s=0,o;o=e[s];++s)n[o]=+n[o]||0;n[2]=(+n[2]||1)-1,n[3]=+n[3]||1,n[7]=n[7]?String(n[7]).substr(0,3):0,(n[8]===void 0||n[8]==="")&&(n[9]===void 0||n[9]==="")?i=+new Date(n[1],n[2],n[3],n[4],n[5],n[6],n[7]):(n[8]!=="Z"&&n[9]!==void 0&&(r=n[10]*60+n[11],n[9]==="+"&&(r=0-r)),i=Date.UTC(n[1],n[2],n[3],n[4],n[5]+r,n[6],n[7]))}else i=Date.parse?Date.parse(t):NaN;return i}});var Tre=E(Xd=>{"use strict";Object.defineProperty(Xd,"__esModule",{value:!0});Xd.create=eN;Xd.default=void 0;var IYe=x0(Fre()),Nre=La(),Lre=x0(Zg()),yYe=x0(Dc()),wYe=x0(Ma());function x0(t){return t&&t.__esModule?t:{default:t}}var tN=new Date(""),BYe=t=>Object.prototype.toString.call(t)==="[object Date]";function eN(){return new Zd}var Zd=class extends wYe.default{constructor(){super({type:"date"});this.withMutation(()=>{this.transform(function(e){return this.isType(e)?e:(e=(0,IYe.default)(e),isNaN(e)?tN:new Date(e))})})}_typeCheck(e){return BYe(e)&&!isNaN(e.getTime())}prepareParam(e,r){let i;if(yYe.default.isRef(e))i=e;else{let n=this.cast(e);if(!this._typeCheck(n))throw new TypeError(`\`${r}\` must be a Date or a value that can be \`cast()\` to a Date`);i=n}return i}min(e,r=Nre.date.min){let i=this.prepareParam(e,"min");return this.test({message:r,name:"min",exclusive:!0,params:{min:e},test(n){return(0,Lre.default)(n)||n>=this.resolve(i)}})}max(e,r=Nre.date.max){var i=this.prepareParam(e,"max");return this.test({message:r,name:"max",exclusive:!0,params:{max:e},test(n){return(0,Lre.default)(n)||n<=this.resolve(i)}})}};Xd.default=Zd;Zd.INVALID_DATE=tN;eN.prototype=Zd.prototype;eN.INVALID_DATE=tN});var Ore=E((Ndt,Mre)=>{function QYe(t,e,r,i){var n=-1,s=t==null?0:t.length;for(i&&s&&(r=t[++n]);++n{function bYe(t){return function(e){return t==null?void 0:t[e]}}Kre.exports=bYe});var Gre=E((Tdt,Hre)=>{var vYe=Ure(),SYe={\u00C0:"A",\u00C1:"A",\u00C2:"A",\u00C3:"A",\u00C4:"A",\u00C5:"A",\u00E0:"a",\u00E1:"a",\u00E2:"a",\u00E3:"a",\u00E4:"a",\u00E5:"a",\u00C7:"C",\u00E7:"c",\u00D0:"D",\u00F0:"d",\u00C8:"E",\u00C9:"E",\u00CA:"E",\u00CB:"E",\u00E8:"e",\u00E9:"e",\u00EA:"e",\u00EB:"e",\u00CC:"I",\u00CD:"I",\u00CE:"I",\u00CF:"I",\u00EC:"i",\u00ED:"i",\u00EE:"i",\u00EF:"i",\u00D1:"N",\u00F1:"n",\u00D2:"O",\u00D3:"O",\u00D4:"O",\u00D5:"O",\u00D6:"O",\u00D8:"O",\u00F2:"o",\u00F3:"o",\u00F4:"o",\u00F5:"o",\u00F6:"o",\u00F8:"o",\u00D9:"U",\u00DA:"U",\u00DB:"U",\u00DC:"U",\u00F9:"u",\u00FA:"u",\u00FB:"u",\u00FC:"u",\u00DD:"Y",\u00FD:"y",\u00FF:"y",\u00C6:"Ae",\u00E6:"ae",\u00DE:"Th",\u00FE:"th",\u00DF:"ss",\u0100:"A",\u0102:"A",\u0104:"A",\u0101:"a",\u0103:"a",\u0105:"a",\u0106:"C",\u0108:"C",\u010A:"C",\u010C:"C",\u0107:"c",\u0109:"c",\u010B:"c",\u010D:"c",\u010E:"D",\u0110:"D",\u010F:"d",\u0111:"d",\u0112:"E",\u0114:"E",\u0116:"E",\u0118:"E",\u011A:"E",\u0113:"e",\u0115:"e",\u0117:"e",\u0119:"e",\u011B:"e",\u011C:"G",\u011E:"G",\u0120:"G",\u0122:"G",\u011D:"g",\u011F:"g",\u0121:"g",\u0123:"g",\u0124:"H",\u0126:"H",\u0125:"h",\u0127:"h",\u0128:"I",\u012A:"I",\u012C:"I",\u012E:"I",\u0130:"I",\u0129:"i",\u012B:"i",\u012D:"i",\u012F:"i",\u0131:"i",\u0134:"J",\u0135:"j",\u0136:"K",\u0137:"k",\u0138:"k",\u0139:"L",\u013B:"L",\u013D:"L",\u013F:"L",\u0141:"L",\u013A:"l",\u013C:"l",\u013E:"l",\u0140:"l",\u0142:"l",\u0143:"N",\u0145:"N",\u0147:"N",\u014A:"N",\u0144:"n",\u0146:"n",\u0148:"n",\u014B:"n",\u014C:"O",\u014E:"O",\u0150:"O",\u014D:"o",\u014F:"o",\u0151:"o",\u0154:"R",\u0156:"R",\u0158:"R",\u0155:"r",\u0157:"r",\u0159:"r",\u015A:"S",\u015C:"S",\u015E:"S",\u0160:"S",\u015B:"s",\u015D:"s",\u015F:"s",\u0161:"s",\u0162:"T",\u0164:"T",\u0166:"T",\u0163:"t",\u0165:"t",\u0167:"t",\u0168:"U",\u016A:"U",\u016C:"U",\u016E:"U",\u0170:"U",\u0172:"U",\u0169:"u",\u016B:"u",\u016D:"u",\u016F:"u",\u0171:"u",\u0173:"u",\u0174:"W",\u0175:"w",\u0176:"Y",\u0177:"y",\u0178:"Y",\u0179:"Z",\u017B:"Z",\u017D:"Z",\u017A:"z",\u017C:"z",\u017E:"z",\u0132:"IJ",\u0133:"ij",\u0152:"Oe",\u0153:"oe",\u0149:"'n",\u017F:"s"},xYe=vYe(SYe);Hre.exports=xYe});var Yre=E((Mdt,jre)=>{var kYe=Gre(),PYe=gg(),DYe=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,RYe="\\u0300-\\u036f",FYe="\\ufe20-\\ufe2f",NYe="\\u20d0-\\u20ff",LYe=RYe+FYe+NYe,TYe="["+LYe+"]",MYe=RegExp(TYe,"g");function OYe(t){return t=PYe(t),t&&t.replace(DYe,kYe).replace(MYe,"")}jre.exports=OYe});var Jre=E((Odt,qre)=>{var KYe=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function UYe(t){return t.match(KYe)||[]}qre.exports=UYe});var zre=E((Kdt,Wre)=>{var HYe=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function GYe(t){return HYe.test(t)}Wre.exports=GYe});var fie=E((Udt,Vre)=>{var _re="\\ud800-\\udfff",jYe="\\u0300-\\u036f",YYe="\\ufe20-\\ufe2f",qYe="\\u20d0-\\u20ff",JYe=jYe+YYe+qYe,Xre="\\u2700-\\u27bf",Zre="a-z\\xdf-\\xf6\\xf8-\\xff",WYe="\\xac\\xb1\\xd7\\xf7",zYe="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",VYe="\\u2000-\\u206f",_Ye=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",$re="A-Z\\xc0-\\xd6\\xd8-\\xde",XYe="\\ufe0e\\ufe0f",eie=WYe+zYe+VYe+_Ye,tie="['\u2019]",rie="["+eie+"]",ZYe="["+JYe+"]",iie="\\d+",$Ye="["+Xre+"]",nie="["+Zre+"]",sie="[^"+_re+eie+iie+Xre+Zre+$re+"]",eqe="\\ud83c[\\udffb-\\udfff]",tqe="(?:"+ZYe+"|"+eqe+")",rqe="[^"+_re+"]",oie="(?:\\ud83c[\\udde6-\\uddff]){2}",aie="[\\ud800-\\udbff][\\udc00-\\udfff]",$g="["+$re+"]",iqe="\\u200d",Aie="(?:"+nie+"|"+sie+")",nqe="(?:"+$g+"|"+sie+")",lie="(?:"+tie+"(?:d|ll|m|re|s|t|ve))?",cie="(?:"+tie+"(?:D|LL|M|RE|S|T|VE))?",uie=tqe+"?",gie="["+XYe+"]?",sqe="(?:"+iqe+"(?:"+[rqe,oie,aie].join("|")+")"+gie+uie+")*",oqe="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",aqe="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Aqe=gie+uie+sqe,lqe="(?:"+[$Ye,oie,aie].join("|")+")"+Aqe,cqe=RegExp([$g+"?"+nie+"+"+lie+"(?="+[rie,$g,"$"].join("|")+")",nqe+"+"+cie+"(?="+[rie,$g+Aie,"$"].join("|")+")",$g+"?"+Aie+"+"+lie,$g+"+"+cie,aqe,oqe,iie,lqe].join("|"),"g");function uqe(t){return t.match(cqe)||[]}Vre.exports=uqe});var pie=E((Hdt,hie)=>{var gqe=Jre(),fqe=zre(),hqe=gg(),pqe=fie();function dqe(t,e,r){return t=hqe(t),e=r?void 0:e,e===void 0?fqe(t)?pqe(t):gqe(t):t.match(e)||[]}hie.exports=dqe});var rN=E((Gdt,die)=>{var Cqe=Ore(),mqe=Yre(),Eqe=pie(),Iqe="['\u2019]",yqe=RegExp(Iqe,"g");function wqe(t){return function(e){return Cqe(Eqe(mqe(e).replace(yqe,"")),t,"")}}die.exports=wqe});var mie=E((jdt,Cie)=>{var Bqe=rN(),Qqe=Bqe(function(t,e,r){return t+(r?"_":"")+e.toLowerCase()});Cie.exports=Qqe});var Iie=E((Ydt,Eie)=>{var bqe=ZP(),vqe=rN(),Sqe=vqe(function(t,e,r){return e=e.toLowerCase(),t+(r?bqe(e):e)});Eie.exports=Sqe});var wie=E((qdt,yie)=>{var xqe=jg(),kqe=SF(),Pqe=jF();function Dqe(t,e){var r={};return e=Pqe(e,3),kqe(t,function(i,n,s){xqe(r,e(i,n,s),i)}),r}yie.exports=Dqe});var Qie=E((Jdt,iN)=>{iN.exports=function(t){return Bie(Rqe(t),t)};iN.exports.array=Bie;function Bie(t,e){var r=t.length,i=new Array(r),n={},s=r,o=Fqe(e),a=Nqe(t);for(e.forEach(function(c){if(!a.has(c[0])||!a.has(c[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});s--;)n[s]||l(t[s],s,new Set);return i;function l(c,u,g){if(g.has(c)){var f;try{f=", node was:"+JSON.stringify(c)}catch(d){f=""}throw new Error("Cyclic dependency"+f)}if(!a.has(c))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(c));if(!n[u]){n[u]=!0;var h=o.get(c)||new Set;if(h=Array.from(h),u=h.length){g.add(c);do{var p=h[--u];l(p,a.get(p),g)}while(u);g.delete(c)}i[--r]=c}}}function Rqe(t){for(var e=new Set,r=0,i=t.length;r{"use strict";Object.defineProperty(nN,"__esModule",{value:!0});nN.default=Lqe;var Tqe=k0(Ld()),Mqe=k0(Qie()),Oqe=Yd(),Kqe=k0(Dc()),Uqe=k0(qg());function k0(t){return t&&t.__esModule?t:{default:t}}function Lqe(t,e=[]){let r=[],i=[];function n(s,o){var a=(0,Oqe.split)(s)[0];~i.indexOf(a)||i.push(a),~e.indexOf(`${o}-${a}`)||r.push([o,a])}for(let s in t)if((0,Tqe.default)(t,s)){let o=t[s];~i.indexOf(s)||i.push(s),Kqe.default.isRef(o)&&o.isSibling?n(o.path,s):(0,Uqe.default)(o)&&"deps"in o&&o.deps.forEach(a=>n(a,s))}return Mqe.default.array(i,r).reverse()}});var Sie=E(sN=>{"use strict";Object.defineProperty(sN,"__esModule",{value:!0});sN.default=Hqe;function vie(t,e){let r=Infinity;return t.some((i,n)=>{var s;if(((s=e.path)==null?void 0:s.indexOf(i))!==-1)return r=n,!0}),r}function Hqe(t){return(e,r)=>vie(t,e)-vie(t,r)}});var Nie=E($d=>{"use strict";Object.defineProperty($d,"__esModule",{value:!0});$d.create=xie;$d.default=void 0;var kie=Fo(Ld()),Pie=Fo(mie()),Gqe=Fo(Iie()),jqe=Fo(wie()),Yqe=Fo(YF()),qqe=Yd(),Die=La(),Jqe=Fo(bie()),Rie=Fo(Sie()),Wqe=Fo(a0()),zqe=Fo(xc()),oN=Fo(Ma());function Fo(t){return t&&t.__esModule?t:{default:t}}function ef(){return ef=Object.assign||function(t){for(var e=1;eObject.prototype.toString.call(t)==="[object Object]";function Vqe(t,e){let r=Object.keys(t.fields);return Object.keys(e).filter(i=>r.indexOf(i)===-1)}var _qe=(0,Rie.default)([]),P0=class extends oN.default{constructor(e){super({type:"object"});this.fields=Object.create(null),this._sortErrors=_qe,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{this.transform(function(i){if(typeof i=="string")try{i=JSON.parse(i)}catch(n){i=null}return this.isType(i)?i:null}),e&&this.shape(e)})}_typeCheck(e){return Fie(e)||typeof e=="function"}_cast(e,r={}){var i;let n=super._cast(e,r);if(n===void 0)return this.getDefault();if(!this._typeCheck(n))return n;let s=this.fields,o=(i=r.stripUnknown)!=null?i:this.spec.noUnknown,a=this._nodes.concat(Object.keys(n).filter(g=>this._nodes.indexOf(g)===-1)),l={},c=ef({},r,{parent:l,__validating:r.__validating||!1}),u=!1;for(let g of a){let f=s[g],h=(0,kie.default)(n,g);if(f){let p,d=n[g];c.path=(r.path?`${r.path}.`:"")+g,f=f.resolve({value:d,context:r.context,parent:l});let m="spec"in f?f.spec:void 0,I=m==null?void 0:m.strict;if(m==null?void 0:m.strip){u=u||g in n;continue}p=!r.__validating||!I?f.cast(n[g],c):n[g],p!==void 0&&(l[g]=p)}else h&&!o&&(l[g]=n[g]);l[g]!==n[g]&&(u=!0)}return u?l:n}_validate(e,r={},i){let n=[],{sync:s,from:o=[],originalValue:a=e,abortEarly:l=this.spec.abortEarly,recursive:c=this.spec.recursive}=r;o=[{schema:this,value:a},...o],r.__validating=!0,r.originalValue=a,r.from=o,super._validate(e,r,(u,g)=>{if(u){if(!zqe.default.isError(u)||l)return void i(u,g);n.push(u)}if(!c||!Fie(g)){i(n[0]||null,g);return}a=a||g;let f=this._nodes.map(h=>(p,d)=>{let m=h.indexOf(".")===-1?(r.path?`${r.path}.`:"")+h:`${r.path||""}["${h}"]`,I=this.fields[h];if(I&&"validate"in I){I.validate(g[h],ef({},r,{path:m,from:o,strict:!0,parent:g,originalValue:a[h]}),d);return}d(null)});(0,Wqe.default)({sync:s,tests:f,value:g,errors:n,endEarly:l,sort:this._sortErrors,path:r.path},i)})}clone(e){let r=super.clone(e);return r.fields=ef({},this.fields),r._nodes=this._nodes,r._excludedEdges=this._excludedEdges,r._sortErrors=this._sortErrors,r}concat(e){let r=super.concat(e),i=r.fields;for(let[n,s]of Object.entries(this.fields)){let o=i[n];o===void 0?i[n]=s:o instanceof oN.default&&s instanceof oN.default&&(i[n]=s.concat(o))}return r.withMutation(()=>r.shape(i))}getDefaultFromShape(){let e={};return this._nodes.forEach(r=>{let i=this.fields[r];e[r]="default"in i?i.getDefault():void 0}),e}_getDefault(){if("default"in this.spec)return super._getDefault();if(!!this._nodes.length)return this.getDefaultFromShape()}shape(e,r=[]){let i=this.clone(),n=Object.assign(i.fields,e);if(i.fields=n,i._sortErrors=(0,Rie.default)(Object.keys(n)),r.length){Array.isArray(r[0])||(r=[r]);let s=r.map(([o,a])=>`${o}-${a}`);i._excludedEdges=i._excludedEdges.concat(s)}return i._nodes=(0,Jqe.default)(n,i._excludedEdges),i}pick(e){let r={};for(let i of e)this.fields[i]&&(r[i]=this.fields[i]);return this.clone().withMutation(i=>(i.fields={},i.shape(r)))}omit(e){let r=this.clone(),i=r.fields;r.fields={};for(let n of e)delete i[n];return r.withMutation(()=>r.shape(i))}from(e,r,i){let n=(0,qqe.getter)(e,!0);return this.transform(s=>{if(s==null)return s;let o=s;return(0,kie.default)(s,e)&&(o=ef({},s),i||delete o[e],o[r]=n(s)),o})}noUnknown(e=!0,r=Die.object.noUnknown){typeof e=="string"&&(r=e,e=!0);let i=this.test({name:"noUnknown",exclusive:!0,message:r,test(n){if(n==null)return!0;let s=Vqe(this.schema,n);return!e||s.length===0||this.createError({params:{unknown:s.join(", ")}})}});return i.spec.noUnknown=e,i}unknown(e=!0,r=Die.object.noUnknown){return this.noUnknown(!e,r)}transformKeys(e){return this.transform(r=>r&&(0,jqe.default)(r,(i,n)=>e(n)))}camelCase(){return this.transformKeys(Gqe.default)}snakeCase(){return this.transformKeys(Pie.default)}constantCase(){return this.transformKeys(e=>(0,Pie.default)(e).toUpperCase())}describe(){let e=super.describe();return e.fields=(0,Yqe.default)(this.fields,r=>r.describe()),e}};$d.default=P0;function xie(t){return new P0(t)}xie.prototype=P0.prototype});var Tie=E(eC=>{"use strict";Object.defineProperty(eC,"__esModule",{value:!0});eC.create=Lie;eC.default=void 0;var aN=tf(Zg()),Xqe=tf(qg()),Zqe=tf(Nd()),AN=La(),$qe=tf(a0()),eJe=tf(xc()),tJe=tf(Ma());function tf(t){return t&&t.__esModule?t:{default:t}}function D0(){return D0=Object.assign||function(t){for(var e=1;e{this.transform(function(r){if(typeof r=="string")try{r=JSON.parse(r)}catch(i){r=null}return this.isType(r)?r:null})})}_typeCheck(e){return Array.isArray(e)}get _subType(){return this.innerType}_cast(e,r){let i=super._cast(e,r);if(!this._typeCheck(i)||!this.innerType)return i;let n=!1,s=i.map((o,a)=>{let l=this.innerType.cast(o,D0({},r,{path:`${r.path||""}[${a}]`}));return l!==o&&(n=!0),l});return n?s:i}_validate(e,r={},i){var n,s;let o=[],a=r.sync,l=r.path,c=this.innerType,u=(n=r.abortEarly)!=null?n:this.spec.abortEarly,g=(s=r.recursive)!=null?s:this.spec.recursive,f=r.originalValue!=null?r.originalValue:e;super._validate(e,r,(h,p)=>{if(h){if(!eJe.default.isError(h)||u)return void i(h,p);o.push(h)}if(!g||!c||!this._typeCheck(p)){i(o[0]||null,p);return}f=f||p;let d=new Array(p.length);for(let m=0;mc.validate(I,b,H)}(0,$qe.default)({sync:a,path:l,value:p,errors:o,endEarly:u,tests:d},i)})}clone(e){let r=super.clone(e);return r.innerType=this.innerType,r}concat(e){let r=super.concat(e);return r.innerType=this.innerType,e.innerType&&(r.innerType=r.innerType?r.innerType.concat(e.innerType):e.innerType),r}of(e){let r=this.clone();if(!(0,Xqe.default)(e))throw new TypeError("`array.of()` sub-schema must be a valid yup schema not: "+(0,Zqe.default)(e));return r.innerType=e,r}length(e,r=AN.array.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:e},test(i){return(0,aN.default)(i)||i.length===this.resolve(e)}})}min(e,r){return r=r||AN.array.min,this.test({message:r,name:"min",exclusive:!0,params:{min:e},test(i){return(0,aN.default)(i)||i.length>=this.resolve(e)}})}max(e,r){return r=r||AN.array.max,this.test({message:r,name:"max",exclusive:!0,params:{max:e},test(i){return(0,aN.default)(i)||i.length<=this.resolve(e)}})}ensure(){return this.default(()=>[]).transform((e,r)=>this._typeCheck(e)?e:r==null?[]:[].concat(r))}compact(e){let r=e?(i,n,s)=>!e(i,n,s):i=>!!i;return this.transform(i=>i!=null?i.filter(r):i)}describe(){let e=super.describe();return this.innerType&&(e.innerType=this.innerType.describe()),e}nullable(e=!0){return super.nullable(e)}defined(){return super.defined()}required(e){return super.required(e)}};eC.default=R0;Lie.prototype=R0.prototype});var Mie=E(tC=>{"use strict";Object.defineProperty(tC,"__esModule",{value:!0});tC.create=rJe;tC.default=void 0;var nJe=iJe(qg());function iJe(t){return t&&t.__esModule?t:{default:t}}function rJe(t){return new lN(t)}var lN=class{constructor(e){this.type="lazy",this.__isYupSchema__=!0,this._resolve=(r,i={})=>{let n=this.builder(r,i);if(!(0,nJe.default)(n))throw new TypeError("lazy() functions must return a valid schema");return n.resolve(i)},this.builder=e}resolve(e){return this._resolve(e.value,e)}cast(e,r){return this._resolve(e,r).cast(e,r)}validate(e,r,i){return this._resolve(e,r).validate(e,r,i)}validateSync(e,r){return this._resolve(e,r).validateSync(e,r)}validateAt(e,r,i){return this._resolve(r,i).validateAt(e,r,i)}validateSyncAt(e,r,i){return this._resolve(r,i).validateSyncAt(e,r,i)}describe(){return null}isValid(e,r){return this._resolve(e,r).isValid(e,r)}isValidSync(e,r){return this._resolve(e,r).isValidSync(e,r)}},sJe=lN;tC.default=sJe});var Oie=E(cN=>{"use strict";Object.defineProperty(cN,"__esModule",{value:!0});cN.default=oJe;var AJe=aJe(La());function aJe(t){return t&&t.__esModule?t:{default:t}}function oJe(t){Object.keys(t).forEach(e=>{Object.keys(t[e]).forEach(r=>{AJe.default[e][r]=t[e][r]})})}});var gN=E(cr=>{"use strict";Object.defineProperty(cr,"__esModule",{value:!0});cr.addMethod=lJe;Object.defineProperty(cr,"MixedSchema",{enumerable:!0,get:function(){return Kie.default}});Object.defineProperty(cr,"mixed",{enumerable:!0,get:function(){return Kie.create}});Object.defineProperty(cr,"BooleanSchema",{enumerable:!0,get:function(){return uN.default}});Object.defineProperty(cr,"bool",{enumerable:!0,get:function(){return uN.create}});Object.defineProperty(cr,"boolean",{enumerable:!0,get:function(){return uN.create}});Object.defineProperty(cr,"StringSchema",{enumerable:!0,get:function(){return Uie.default}});Object.defineProperty(cr,"string",{enumerable:!0,get:function(){return Uie.create}});Object.defineProperty(cr,"NumberSchema",{enumerable:!0,get:function(){return Hie.default}});Object.defineProperty(cr,"number",{enumerable:!0,get:function(){return Hie.create}});Object.defineProperty(cr,"DateSchema",{enumerable:!0,get:function(){return Gie.default}});Object.defineProperty(cr,"date",{enumerable:!0,get:function(){return Gie.create}});Object.defineProperty(cr,"ObjectSchema",{enumerable:!0,get:function(){return jie.default}});Object.defineProperty(cr,"object",{enumerable:!0,get:function(){return jie.create}});Object.defineProperty(cr,"ArraySchema",{enumerable:!0,get:function(){return Yie.default}});Object.defineProperty(cr,"array",{enumerable:!0,get:function(){return Yie.create}});Object.defineProperty(cr,"ref",{enumerable:!0,get:function(){return cJe.create}});Object.defineProperty(cr,"lazy",{enumerable:!0,get:function(){return uJe.create}});Object.defineProperty(cr,"ValidationError",{enumerable:!0,get:function(){return gJe.default}});Object.defineProperty(cr,"reach",{enumerable:!0,get:function(){return fJe.default}});Object.defineProperty(cr,"isSchema",{enumerable:!0,get:function(){return qie.default}});Object.defineProperty(cr,"setLocale",{enumerable:!0,get:function(){return hJe.default}});Object.defineProperty(cr,"BaseSchema",{enumerable:!0,get:function(){return pJe.default}});var Kie=Nc(yre()),uN=Nc(vre()),Uie=Nc(kre()),Hie=Nc(Rre()),Gie=Nc(Tre()),jie=Nc(Nie()),Yie=Nc(Tie()),cJe=Dc(),uJe=Mie(),gJe=rC(xc()),fJe=rC(XF()),qie=rC(qg()),hJe=rC(Oie()),pJe=rC(Ma());function rC(t){return t&&t.__esModule?t:{default:t}}function Jie(){if(typeof WeakMap!="function")return null;var t=new WeakMap;return Jie=function(){return t},t}function Nc(t){if(t&&t.__esModule)return t;if(t===null||typeof t!="object"&&typeof t!="function")return{default:t};var e=Jie();if(e&&e.has(t))return e.get(t);var r={},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n)){var s=i?Object.getOwnPropertyDescriptor(t,n):null;s&&(s.get||s.set)?Object.defineProperty(r,n,s):r[n]=t[n]}return r.default=t,e&&e.set(t,r),r}function lJe(t,e,r){if(!t||!(0,qie.default)(t.prototype))throw new TypeError("You must provide a yup schema constructor function");if(typeof e!="string")throw new TypeError("A Method name must be provided");if(typeof r!="function")throw new TypeError("Method function must be provided");t.prototype[e]=r}});var Xie=E((gCt,nC)=>{"use strict";var mJe=process.env.TERM_PROGRAM==="Hyper",EJe=process.platform==="win32",zie=process.platform==="linux",fN={ballotDisabled:"\u2612",ballotOff:"\u2610",ballotOn:"\u2611",bullet:"\u2022",bulletWhite:"\u25E6",fullBlock:"\u2588",heart:"\u2764",identicalTo:"\u2261",line:"\u2500",mark:"\u203B",middot:"\xB7",minus:"\uFF0D",multiplication:"\xD7",obelus:"\xF7",pencilDownRight:"\u270E",pencilRight:"\u270F",pencilUpRight:"\u2710",percent:"%",pilcrow2:"\u2761",pilcrow:"\xB6",plusMinus:"\xB1",section:"\xA7",starsOff:"\u2606",starsOn:"\u2605",upDownArrow:"\u2195"},Vie=Object.assign({},fN,{check:"\u221A",cross:"\xD7",ellipsisLarge:"...",ellipsis:"...",info:"i",question:"?",questionSmall:"?",pointer:">",pointerSmall:"\xBB",radioOff:"( )",radioOn:"(*)",warning:"\u203C"}),_ie=Object.assign({},fN,{ballotCross:"\u2718",check:"\u2714",cross:"\u2716",ellipsisLarge:"\u22EF",ellipsis:"\u2026",info:"\u2139",question:"?",questionFull:"\uFF1F",questionSmall:"\uFE56",pointer:zie?"\u25B8":"\u276F",pointerSmall:zie?"\u2023":"\u203A",radioOff:"\u25EF",radioOn:"\u25C9",warning:"\u26A0"});nC.exports=EJe&&!mJe?Vie:_ie;Reflect.defineProperty(nC.exports,"common",{enumerable:!1,value:fN});Reflect.defineProperty(nC.exports,"windows",{enumerable:!1,value:Vie});Reflect.defineProperty(nC.exports,"other",{enumerable:!1,value:_ie})});var js=E((fCt,hN)=>{"use strict";var IJe=t=>t!==null&&typeof t=="object"&&!Array.isArray(t),yJe=/[\u001b\u009b][[\]#;?()]*(?:(?:(?:[^\W_]*;?[^\W_]*)\u0007)|(?:(?:[0-9]{1,4}(;[0-9]{0,4})*)?[~0-9=<>cf-nqrtyA-PRZ]))/g,Zie=()=>{let t={enabled:!0,visible:!0,styles:{},keys:{}};"FORCE_COLOR"in process.env&&(t.enabled=process.env.FORCE_COLOR!=="0");let e=s=>{let o=s.open=`[${s.codes[0]}m`,a=s.close=`[${s.codes[1]}m`,l=s.regex=new RegExp(`\\u001b\\[${s.codes[1]}m`,"g");return s.wrap=(c,u)=>{c.includes(a)&&(c=c.replace(l,a+o));let g=o+c+a;return u?g.replace(/\r*\n/g,`${a}$&${o}`):g},s},r=(s,o,a)=>typeof s=="function"?s(o):s.wrap(o,a),i=(s,o)=>{if(s===""||s==null)return"";if(t.enabled===!1)return s;if(t.visible===!1)return"";let a=""+s,l=a.includes(` -`),c=o.length;for(c>0&&o.includes("unstyle")&&(o=[...new Set(["unstyle",...o])].reverse());c-- >0;)a=r(t.styles[o[c]],a,l);return a},n=(s,o,a)=>{t.styles[s]=e({name:s,codes:o}),(t.keys[a]||(t.keys[a]=[])).push(s),Reflect.defineProperty(t,s,{configurable:!0,enumerable:!0,set(c){t.alias(s,c)},get(){let c=u=>i(u,c.stack);return Reflect.setPrototypeOf(c,t),c.stack=this.stack?this.stack.concat(s):[s],c}})};return n("reset",[0,0],"modifier"),n("bold",[1,22],"modifier"),n("dim",[2,22],"modifier"),n("italic",[3,23],"modifier"),n("underline",[4,24],"modifier"),n("inverse",[7,27],"modifier"),n("hidden",[8,28],"modifier"),n("strikethrough",[9,29],"modifier"),n("black",[30,39],"color"),n("red",[31,39],"color"),n("green",[32,39],"color"),n("yellow",[33,39],"color"),n("blue",[34,39],"color"),n("magenta",[35,39],"color"),n("cyan",[36,39],"color"),n("white",[37,39],"color"),n("gray",[90,39],"color"),n("grey",[90,39],"color"),n("bgBlack",[40,49],"bg"),n("bgRed",[41,49],"bg"),n("bgGreen",[42,49],"bg"),n("bgYellow",[43,49],"bg"),n("bgBlue",[44,49],"bg"),n("bgMagenta",[45,49],"bg"),n("bgCyan",[46,49],"bg"),n("bgWhite",[47,49],"bg"),n("blackBright",[90,39],"bright"),n("redBright",[91,39],"bright"),n("greenBright",[92,39],"bright"),n("yellowBright",[93,39],"bright"),n("blueBright",[94,39],"bright"),n("magentaBright",[95,39],"bright"),n("cyanBright",[96,39],"bright"),n("whiteBright",[97,39],"bright"),n("bgBlackBright",[100,49],"bgBright"),n("bgRedBright",[101,49],"bgBright"),n("bgGreenBright",[102,49],"bgBright"),n("bgYellowBright",[103,49],"bgBright"),n("bgBlueBright",[104,49],"bgBright"),n("bgMagentaBright",[105,49],"bgBright"),n("bgCyanBright",[106,49],"bgBright"),n("bgWhiteBright",[107,49],"bgBright"),t.ansiRegex=yJe,t.hasColor=t.hasAnsi=s=>(t.ansiRegex.lastIndex=0,typeof s=="string"&&s!==""&&t.ansiRegex.test(s)),t.alias=(s,o)=>{let a=typeof o=="string"?t[o]:o;if(typeof a!="function")throw new TypeError("Expected alias to be the name of an existing color (string) or a function");a.stack||(Reflect.defineProperty(a,"name",{value:s}),t.styles[s]=a,a.stack=[s]),Reflect.defineProperty(t,s,{configurable:!0,enumerable:!0,set(l){t.alias(s,l)},get(){let l=c=>i(c,l.stack);return Reflect.setPrototypeOf(l,t),l.stack=this.stack?this.stack.concat(a.stack):a.stack,l}})},t.theme=s=>{if(!IJe(s))throw new TypeError("Expected theme to be an object");for(let o of Object.keys(s))t.alias(o,s[o]);return t},t.alias("unstyle",s=>typeof s=="string"&&s!==""?(t.ansiRegex.lastIndex=0,s.replace(t.ansiRegex,"")):""),t.alias("noop",s=>s),t.none=t.clear=t.noop,t.stripColor=t.unstyle,t.symbols=Xie(),t.define=n,t};hN.exports=Zie();hN.exports.create=Zie});var Mi=E(bt=>{"use strict";var wJe=Object.prototype.toString,Cs=js(),$ie=!1,pN=[],ene={yellow:"blue",cyan:"red",green:"magenta",black:"white",blue:"yellow",red:"cyan",magenta:"green",white:"black"};bt.longest=(t,e)=>t.reduce((r,i)=>Math.max(r,e?i[e].length:i.length),0);bt.hasColor=t=>!!t&&Cs.hasColor(t);var N0=bt.isObject=t=>t!==null&&typeof t=="object"&&!Array.isArray(t);bt.nativeType=t=>wJe.call(t).slice(8,-1).toLowerCase().replace(/\s/g,"");bt.isAsyncFn=t=>bt.nativeType(t)==="asyncfunction";bt.isPrimitive=t=>t!=null&&typeof t!="object"&&typeof t!="function";bt.resolve=(t,e,...r)=>typeof e=="function"?e.call(t,...r):e;bt.scrollDown=(t=[])=>[...t.slice(1),t[0]];bt.scrollUp=(t=[])=>[t.pop(),...t];bt.reorder=(t=[])=>{let e=t.slice();return e.sort((r,i)=>r.index>i.index?1:r.index{let i=t.length,n=r===i?0:r<0?i-1:r,s=t[e];t[e]=t[n],t[n]=s};bt.width=(t,e=80)=>{let r=t&&t.columns?t.columns:e;return t&&typeof t.getWindowSize=="function"&&(r=t.getWindowSize()[0]),process.platform==="win32"?r-1:r};bt.height=(t,e=20)=>{let r=t&&t.rows?t.rows:e;return t&&typeof t.getWindowSize=="function"&&(r=t.getWindowSize()[1]),r};bt.wordWrap=(t,e={})=>{if(!t)return t;typeof e=="number"&&(e={width:e});let{indent:r="",newline:i=` -`+r,width:n=80}=e;n-=((i+r).match(/[^\S\n]/g)||[]).length;let o=`.{1,${n}}([\\s\\u200B]+|$)|[^\\s\\u200B]+?([\\s\\u200B]+|$)`,a=t.trim(),l=new RegExp(o,"g"),c=a.match(l)||[];return c=c.map(u=>u.replace(/\n$/,"")),e.padEnd&&(c=c.map(u=>u.padEnd(n," "))),e.padStart&&(c=c.map(u=>u.padStart(n," "))),r+c.join(i)};bt.unmute=t=>{let e=t.stack.find(i=>Cs.keys.color.includes(i));return e?Cs[e]:t.stack.find(i=>i.slice(2)==="bg")?Cs[e.slice(2)]:i=>i};bt.pascal=t=>t?t[0].toUpperCase()+t.slice(1):"";bt.inverse=t=>{if(!t||!t.stack)return t;let e=t.stack.find(i=>Cs.keys.color.includes(i));if(e){let i=Cs["bg"+bt.pascal(e)];return i?i.black:t}let r=t.stack.find(i=>i.slice(0,2)==="bg");return r?Cs[r.slice(2).toLowerCase()]||t:Cs.none};bt.complement=t=>{if(!t||!t.stack)return t;let e=t.stack.find(i=>Cs.keys.color.includes(i)),r=t.stack.find(i=>i.slice(0,2)==="bg");if(e&&!r)return Cs[ene[e]||e];if(r){let i=r.slice(2).toLowerCase(),n=ene[i];return n&&Cs["bg"+bt.pascal(n)]||t}return Cs.none};bt.meridiem=t=>{let e=t.getHours(),r=t.getMinutes(),i=e>=12?"pm":"am";e=e%12;let n=e===0?12:e,s=r<10?"0"+r:r;return n+":"+s+" "+i};bt.set=(t={},e="",r)=>e.split(".").reduce((i,n,s,o)=>{let a=o.length-1>s?i[n]||{}:r;return!bt.isObject(a)&&s{let i=t[e]==null?e.split(".").reduce((n,s)=>n&&n[s],t):t[e];return i==null?r:i};bt.mixin=(t,e)=>{if(!N0(t))return e;if(!N0(e))return t;for(let r of Object.keys(e)){let i=Object.getOwnPropertyDescriptor(e,r);if(i.hasOwnProperty("value"))if(t.hasOwnProperty(r)&&N0(i.value)){let n=Object.getOwnPropertyDescriptor(t,r);N0(n.value)?t[r]=bt.merge({},t[r],e[r]):Reflect.defineProperty(t,r,i)}else Reflect.defineProperty(t,r,i);else Reflect.defineProperty(t,r,i)}return t};bt.merge=(...t)=>{let e={};for(let r of t)bt.mixin(e,r);return e};bt.mixinEmitter=(t,e)=>{let r=e.constructor.prototype;for(let i of Object.keys(r)){let n=r[i];typeof n=="function"?bt.define(t,i,n.bind(e)):bt.define(t,i,n)}};bt.onExit=t=>{let e=(r,i)=>{$ie||($ie=!0,pN.forEach(n=>n()),r===!0&&process.exit(128+i))};pN.length===0&&(process.once("SIGTERM",e.bind(null,!0,15)),process.once("SIGINT",e.bind(null,!0,2)),process.once("exit",e)),pN.push(t)};bt.define=(t,e,r)=>{Reflect.defineProperty(t,e,{value:r})};bt.defineExport=(t,e,r)=>{let i;Reflect.defineProperty(t,e,{enumerable:!0,configurable:!0,set(n){i=n},get(){return i?i():r()}})}});var tne=E(nf=>{"use strict";nf.ctrl={a:"first",b:"backward",c:"cancel",d:"deleteForward",e:"last",f:"forward",g:"reset",i:"tab",k:"cutForward",l:"reset",n:"newItem",m:"cancel",j:"submit",p:"search",r:"remove",s:"save",u:"undo",w:"cutLeft",x:"toggleCursor",v:"paste"};nf.shift={up:"shiftUp",down:"shiftDown",left:"shiftLeft",right:"shiftRight",tab:"prev"};nf.fn={up:"pageUp",down:"pageDown",left:"pageLeft",right:"pageRight",delete:"deleteForward"};nf.option={b:"backward",f:"forward",d:"cutRight",left:"cutLeft",up:"altUp",down:"altDown"};nf.keys={pageup:"pageUp",pagedown:"pageDown",home:"home",end:"end",cancel:"cancel",delete:"deleteForward",backspace:"delete",down:"down",enter:"submit",escape:"cancel",left:"left",space:"space",number:"number",return:"submit",right:"right",tab:"next",up:"up"}});var nne=E((dCt,rne)=>{"use strict";var ine=require("readline"),BJe=tne(),QJe=/^(?:\x1b)([a-zA-Z0-9])$/,bJe=/^(?:\x1b+)(O|N|\[|\[\[)(?:(\d+)(?:;(\d+))?([~^$])|(?:1;)?(\d+)?([a-zA-Z]))/,vJe={OP:"f1",OQ:"f2",OR:"f3",OS:"f4","[11~":"f1","[12~":"f2","[13~":"f3","[14~":"f4","[[A":"f1","[[B":"f2","[[C":"f3","[[D":"f4","[[E":"f5","[15~":"f5","[17~":"f6","[18~":"f7","[19~":"f8","[20~":"f9","[21~":"f10","[23~":"f11","[24~":"f12","[A":"up","[B":"down","[C":"right","[D":"left","[E":"clear","[F":"end","[H":"home",OA:"up",OB:"down",OC:"right",OD:"left",OE:"clear",OF:"end",OH:"home","[1~":"home","[2~":"insert","[3~":"delete","[4~":"end","[5~":"pageup","[6~":"pagedown","[[5~":"pageup","[[6~":"pagedown","[7~":"home","[8~":"end","[a":"up","[b":"down","[c":"right","[d":"left","[e":"clear","[2$":"insert","[3$":"delete","[5$":"pageup","[6$":"pagedown","[7$":"home","[8$":"end",Oa:"up",Ob:"down",Oc:"right",Od:"left",Oe:"clear","[2^":"insert","[3^":"delete","[5^":"pageup","[6^":"pagedown","[7^":"home","[8^":"end","[Z":"tab"};function SJe(t){return["[a","[b","[c","[d","[e","[2$","[3$","[5$","[6$","[7$","[8$","[Z"].includes(t)}function xJe(t){return["Oa","Ob","Oc","Od","Oe","[2^","[3^","[5^","[6^","[7^","[8^"].includes(t)}var L0=(t="",e={})=>{let r,i=P({name:e.name,ctrl:!1,meta:!1,shift:!1,option:!1,sequence:t,raw:t},e);if(Buffer.isBuffer(t)?t[0]>127&&t[1]===void 0?(t[0]-=128,t=""+String(t)):t=String(t):t!==void 0&&typeof t!="string"?t=String(t):t||(t=i.sequence||""),i.sequence=i.sequence||t||i.name,t==="\r")i.raw=void 0,i.name="return";else if(t===` -`)i.name="enter";else if(t===" ")i.name="tab";else if(t==="\b"||t==="\x7F"||t==="\x7F"||t==="\b")i.name="backspace",i.meta=t.charAt(0)==="";else if(t===""||t==="")i.name="escape",i.meta=t.length===2;else if(t===" "||t===" ")i.name="space",i.meta=t.length===2;else if(t<="")i.name=String.fromCharCode(t.charCodeAt(0)+"a".charCodeAt(0)-1),i.ctrl=!0;else if(t.length===1&&t>="0"&&t<="9")i.name="number";else if(t.length===1&&t>="a"&&t<="z")i.name=t;else if(t.length===1&&t>="A"&&t<="Z")i.name=t.toLowerCase(),i.shift=!0;else if(r=QJe.exec(t))i.meta=!0,i.shift=/^[A-Z]$/.test(r[1]);else if(r=bJe.exec(t)){let n=[...t];n[0]===""&&n[1]===""&&(i.option=!0);let s=[r[1],r[2],r[4],r[6]].filter(Boolean).join(""),o=(r[3]||r[5]||1)-1;i.ctrl=!!(o&4),i.meta=!!(o&10),i.shift=!!(o&1),i.code=s,i.name=vJe[s],i.shift=SJe(s)||i.shift,i.ctrl=xJe(s)||i.ctrl}return i};L0.listen=(t={},e)=>{let{stdin:r}=t;if(!r||r!==process.stdin&&!r.isTTY)throw new Error("Invalid stream passed");let i=ine.createInterface({terminal:!0,input:r});ine.emitKeypressEvents(r,i);let n=(a,l)=>e(a,L0(a,l),i),s=r.isRaw;return r.isTTY&&r.setRawMode(!0),r.on("keypress",n),i.resume(),()=>{r.isTTY&&r.setRawMode(s),r.removeListener("keypress",n),i.pause(),i.close()}};L0.action=(t,e,r)=>{let i=P(P({},BJe),r);return e.ctrl?(e.action=i.ctrl[e.name],e):e.option&&i.option?(e.action=i.option[e.name],e):e.shift?(e.action=i.shift[e.name],e):(e.action=i.keys[e.name],e)};rne.exports=L0});var one=E((CCt,sne)=>{"use strict";sne.exports=t=>{t.timers=t.timers||{};let e=t.options.timers;if(!!e)for(let r of Object.keys(e)){let i=e[r];typeof i=="number"&&(i={interval:i}),kJe(t,r,i)}};function kJe(t,e,r={}){let i=t.timers[e]={name:e,start:Date.now(),ms:0,tick:0},n=r.interval||120;i.frames=r.frames||[],i.loading=!0;let s=setInterval(()=>{i.ms=Date.now()-i.start,i.tick++,t.render()},n);return i.stop=()=>{i.loading=!1,clearInterval(s)},Reflect.defineProperty(i,"interval",{value:s}),t.once("close",()=>i.stop()),i.stop}});var lne=E((mCt,ane)=>{"use strict";var{define:PJe,width:DJe}=Mi(),Ane=class{constructor(e){let r=e.options;PJe(this,"_prompt",e),this.type=e.type,this.name=e.name,this.message="",this.header="",this.footer="",this.error="",this.hint="",this.input="",this.cursor=0,this.index=0,this.lines=0,this.tick=0,this.prompt="",this.buffer="",this.width=DJe(r.stdout||process.stdout),Object.assign(this,r),this.name=this.name||this.message,this.message=this.message||this.name,this.symbols=e.symbols,this.styles=e.styles,this.required=new Set,this.cancelled=!1,this.submitted=!1}clone(){let e=P({},this);return e.status=this.status,e.buffer=Buffer.from(e.buffer),delete e.clone,e}set color(e){this._color=e}get color(){let e=this.prompt.styles;if(this.cancelled)return e.cancelled;if(this.submitted)return e.submitted;let r=this._color||e[this.status];return typeof r=="function"?r:e.pending}set loading(e){this._loading=e}get loading(){return typeof this._loading=="boolean"?this._loading:this.loadingChoices?"choices":!1}get status(){return this.cancelled?"cancelled":this.submitted?"submitted":"pending"}};ane.exports=Ane});var une=E((ECt,cne)=>{"use strict";var dN=Mi(),yi=js(),CN={default:yi.noop,noop:yi.noop,set inverse(t){this._inverse=t},get inverse(){return this._inverse||dN.inverse(this.primary)},set complement(t){this._complement=t},get complement(){return this._complement||dN.complement(this.primary)},primary:yi.cyan,success:yi.green,danger:yi.magenta,strong:yi.bold,warning:yi.yellow,muted:yi.dim,disabled:yi.gray,dark:yi.dim.gray,underline:yi.underline,set info(t){this._info=t},get info(){return this._info||this.primary},set em(t){this._em=t},get em(){return this._em||this.primary.underline},set heading(t){this._heading=t},get heading(){return this._heading||this.muted.underline},set pending(t){this._pending=t},get pending(){return this._pending||this.primary},set submitted(t){this._submitted=t},get submitted(){return this._submitted||this.success},set cancelled(t){this._cancelled=t},get cancelled(){return this._cancelled||this.danger},set typing(t){this._typing=t},get typing(){return this._typing||this.dim},set placeholder(t){this._placeholder=t},get placeholder(){return this._placeholder||this.primary.dim},set highlight(t){this._highlight=t},get highlight(){return this._highlight||this.inverse}};CN.merge=(t={})=>{t.styles&&typeof t.styles.enabled=="boolean"&&(yi.enabled=t.styles.enabled),t.styles&&typeof t.styles.visible=="boolean"&&(yi.visible=t.styles.visible);let e=dN.merge({},CN,t.styles);delete e.merge;for(let r of Object.keys(yi))e.hasOwnProperty(r)||Reflect.defineProperty(e,r,{get:()=>yi[r]});for(let r of Object.keys(yi.styles))e.hasOwnProperty(r)||Reflect.defineProperty(e,r,{get:()=>yi[r]});return e};cne.exports=CN});var fne=E((ICt,gne)=>{"use strict";var mN=process.platform==="win32",Ka=js(),RJe=Mi(),EN=_(P({},Ka.symbols),{upDownDoubleArrow:"\u21D5",upDownDoubleArrow2:"\u2B0D",upDownArrow:"\u2195",asterisk:"*",asterism:"\u2042",bulletWhite:"\u25E6",electricArrow:"\u2301",ellipsisLarge:"\u22EF",ellipsisSmall:"\u2026",fullBlock:"\u2588",identicalTo:"\u2261",indicator:Ka.symbols.check,leftAngle:"\u2039",mark:"\u203B",minus:"\u2212",multiplication:"\xD7",obelus:"\xF7",percent:"%",pilcrow:"\xB6",pilcrow2:"\u2761",pencilUpRight:"\u2710",pencilDownRight:"\u270E",pencilRight:"\u270F",plus:"+",plusMinus:"\xB1",pointRight:"\u261E",rightAngle:"\u203A",section:"\xA7",hexagon:{off:"\u2B21",on:"\u2B22",disabled:"\u2B22"},ballot:{on:"\u2611",off:"\u2610",disabled:"\u2612"},stars:{on:"\u2605",off:"\u2606",disabled:"\u2606"},folder:{on:"\u25BC",off:"\u25B6",disabled:"\u25B6"},prefix:{pending:Ka.symbols.question,submitted:Ka.symbols.check,cancelled:Ka.symbols.cross},separator:{pending:Ka.symbols.pointerSmall,submitted:Ka.symbols.middot,cancelled:Ka.symbols.middot},radio:{off:mN?"( )":"\u25EF",on:mN?"(*)":"\u25C9",disabled:mN?"(|)":"\u24BE"},numbers:["\u24EA","\u2460","\u2461","\u2462","\u2463","\u2464","\u2465","\u2466","\u2467","\u2468","\u2469","\u246A","\u246B","\u246C","\u246D","\u246E","\u246F","\u2470","\u2471","\u2472","\u2473","\u3251","\u3252","\u3253","\u3254","\u3255","\u3256","\u3257","\u3258","\u3259","\u325A","\u325B","\u325C","\u325D","\u325E","\u325F","\u32B1","\u32B2","\u32B3","\u32B4","\u32B5","\u32B6","\u32B7","\u32B8","\u32B9","\u32BA","\u32BB","\u32BC","\u32BD","\u32BE","\u32BF"]});EN.merge=t=>{let e=RJe.merge({},Ka.symbols,EN,t.symbols);return delete e.merge,e};gne.exports=EN});var pne=E((yCt,hne)=>{"use strict";var FJe=une(),NJe=fne(),LJe=Mi();hne.exports=t=>{t.options=LJe.merge({},t.options.theme,t.options),t.symbols=NJe.merge(t.options),t.styles=FJe.merge(t.options)}});var Ine=E((dne,Cne)=>{"use strict";var mne=process.env.TERM_PROGRAM==="Apple_Terminal",TJe=js(),IN=Mi(),Ys=Cne.exports=dne,Ir="[",Ene="\x07",yN=!1,HA=Ys.code={bell:Ene,beep:Ene,beginning:`${Ir}G`,down:`${Ir}J`,esc:Ir,getPosition:`${Ir}6n`,hide:`${Ir}?25l`,line:`${Ir}2K`,lineEnd:`${Ir}K`,lineStart:`${Ir}1K`,restorePosition:Ir+(mne?"8":"u"),savePosition:Ir+(mne?"7":"s"),screen:`${Ir}2J`,show:`${Ir}?25h`,up:`${Ir}1J`},Lc=Ys.cursor={get hidden(){return yN},hide(){return yN=!0,HA.hide},show(){return yN=!1,HA.show},forward:(t=1)=>`${Ir}${t}C`,backward:(t=1)=>`${Ir}${t}D`,nextLine:(t=1)=>`${Ir}E`.repeat(t),prevLine:(t=1)=>`${Ir}F`.repeat(t),up:(t=1)=>t?`${Ir}${t}A`:"",down:(t=1)=>t?`${Ir}${t}B`:"",right:(t=1)=>t?`${Ir}${t}C`:"",left:(t=1)=>t?`${Ir}${t}D`:"",to(t,e){return e?`${Ir}${e+1};${t+1}H`:`${Ir}${t+1}G`},move(t=0,e=0){let r="";return r+=t<0?Lc.left(-t):t>0?Lc.right(t):"",r+=e<0?Lc.up(-e):e>0?Lc.down(e):"",r},restore(t={}){let{after:e,cursor:r,initial:i,input:n,prompt:s,size:o,value:a}=t;if(i=IN.isPrimitive(i)?String(i):"",n=IN.isPrimitive(n)?String(n):"",a=IN.isPrimitive(a)?String(a):"",o){let l=Ys.cursor.up(o)+Ys.cursor.to(s.length),c=n.length-r;return c>0&&(l+=Ys.cursor.left(c)),l}if(a||e){let l=!n&&!!i?-i.length:-n.length+r;return e&&(l-=e.length),n===""&&i&&!s.includes(i)&&(l+=i.length),Ys.cursor.move(l)}}},wN=Ys.erase={screen:HA.screen,up:HA.up,down:HA.down,line:HA.line,lineEnd:HA.lineEnd,lineStart:HA.lineStart,lines(t){let e="";for(let r=0;r{if(!e)return wN.line+Lc.to(0);let r=s=>[...TJe.unstyle(s)].length,i=t.split(/\r?\n/),n=0;for(let s of i)n+=1+Math.floor(Math.max(r(s)-1,0)/e);return(wN.line+Lc.prevLine()).repeat(n-1)+wN.line+Lc.to(0)}});var sf=E((wCt,yne)=>{"use strict";var MJe=require("events"),wne=js(),BN=nne(),OJe=one(),KJe=lne(),UJe=pne(),bn=Mi(),Tc=Ine(),T0=class extends MJe{constructor(e={}){super();this.name=e.name,this.type=e.type,this.options=e,UJe(this),OJe(this),this.state=new KJe(this),this.initial=[e.initial,e.default].find(r=>r!=null),this.stdout=e.stdout||process.stdout,this.stdin=e.stdin||process.stdin,this.scale=e.scale||1,this.term=this.options.term||process.env.TERM_PROGRAM,this.margin=GJe(this.options.margin),this.setMaxListeners(0),HJe(this)}async keypress(e,r={}){this.keypressed=!0;let i=BN.action(e,BN(e,r),this.options.actions);this.state.keypress=i,this.emit("keypress",e,i),this.emit("state",this.state.clone());let n=this.options[i.action]||this[i.action]||this.dispatch;if(typeof n=="function")return await n.call(this,e,i);this.alert()}alert(){delete this.state.alert,this.options.show===!1?this.emit("alert"):this.stdout.write(Tc.code.beep)}cursorHide(){this.stdout.write(Tc.cursor.hide()),bn.onExit(()=>this.cursorShow())}cursorShow(){this.stdout.write(Tc.cursor.show())}write(e){!e||(this.stdout&&this.state.show!==!1&&this.stdout.write(e),this.state.buffer+=e)}clear(e=0){let r=this.state.buffer;this.state.buffer="",!(!r&&!e||this.options.show===!1)&&this.stdout.write(Tc.cursor.down(e)+Tc.clear(r,this.width))}restore(){if(this.state.closed||this.options.show===!1)return;let{prompt:e,after:r,rest:i}=this.sections(),{cursor:n,initial:s="",input:o="",value:a=""}=this,l=this.state.size=i.length,c={after:r,cursor:n,initial:s,input:o,prompt:e,size:l,value:a},u=Tc.cursor.restore(c);u&&this.stdout.write(u)}sections(){let{buffer:e,input:r,prompt:i}=this.state;i=wne.unstyle(i);let n=wne.unstyle(e),s=n.indexOf(i),o=n.slice(0,s),l=n.slice(s).split(` -`),c=l[0],u=l[l.length-1],f=(i+(r?" "+r:"")).length,h=fe.call(this,this.value),this.result=()=>i.call(this,this.value),typeof r.initial=="function"&&(this.initial=await r.initial.call(this,this)),typeof r.onRun=="function"&&await r.onRun.call(this,this),typeof r.onSubmit=="function"){let n=r.onSubmit.bind(this),s=this.submit.bind(this);delete this.options.onSubmit,this.submit=async()=>(await n(this.name,this.value,this),s())}await this.start(),await this.render()}render(){throw new Error("expected prompt to have a custom render method")}run(){return new Promise(async(e,r)=>{if(this.once("submit",e),this.once("cancel",r),await this.skip())return this.render=()=>{},this.submit();await this.initialize(),this.emit("run")})}async element(e,r,i){let{options:n,state:s,symbols:o,timers:a}=this,l=a&&a[e];s.timer=l;let c=n[e]||s[e]||o[e],u=r&&r[e]!=null?r[e]:await c;if(u==="")return u;let g=await this.resolve(u,s,r,i);return!g&&r&&r[e]?this.resolve(c,s,r,i):g}async prefix(){let e=await this.element("prefix")||this.symbols,r=this.timers&&this.timers.prefix,i=this.state;return i.timer=r,bn.isObject(e)&&(e=e[i.status]||e.pending),bn.hasColor(e)?e:(this.styles[i.status]||this.styles.pending)(e)}async message(){let e=await this.element("message");return bn.hasColor(e)?e:this.styles.strong(e)}async separator(){let e=await this.element("separator")||this.symbols,r=this.timers&&this.timers.separator,i=this.state;i.timer=r;let n=e[i.status]||e.pending||i.separator,s=await this.resolve(n,i);return bn.isObject(s)&&(s=s[i.status]||s.pending),bn.hasColor(s)?s:this.styles.muted(s)}async pointer(e,r){let i=await this.element("pointer",e,r);if(typeof i=="string"&&bn.hasColor(i))return i;if(i){let n=this.styles,s=this.index===r,o=s?n.primary:c=>c,a=await this.resolve(i[s?"on":"off"]||i,this.state),l=bn.hasColor(a)?a:o(a);return s?l:" ".repeat(a.length)}}async indicator(e,r){let i=await this.element("indicator",e,r);if(typeof i=="string"&&bn.hasColor(i))return i;if(i){let n=this.styles,s=e.enabled===!0,o=s?n.success:n.dark,a=i[s?"on":"off"]||i;return bn.hasColor(a)?a:o(a)}return""}body(){return null}footer(){if(this.state.status==="pending")return this.element("footer")}header(){if(this.state.status==="pending")return this.element("header")}async hint(){if(this.state.status==="pending"&&!this.isValue(this.state.input)){let e=await this.element("hint");return bn.hasColor(e)?e:this.styles.muted(e)}}error(e){return this.state.submitted?"":e||this.state.error}format(e){return e}result(e){return e}validate(e){return this.options.required===!0?this.isValue(e):!0}isValue(e){return e!=null&&e!==""}resolve(e,...r){return bn.resolve(this,e,...r)}get base(){return T0.prototype}get style(){return this.styles[this.state.status]}get height(){return this.options.rows||bn.height(this.stdout,25)}get width(){return this.options.columns||bn.width(this.stdout,80)}get size(){return{width:this.width,height:this.height}}set cursor(e){this.state.cursor=e}get cursor(){return this.state.cursor}set input(e){this.state.input=e}get input(){return this.state.input}set value(e){this.state.value=e}get value(){let{input:e,value:r}=this.state,i=[r,e].find(this.isValue.bind(this));return this.isValue(i)?i:this.initial}static get prompt(){return e=>new this(e).run()}};function HJe(t){let e=n=>t[n]===void 0||typeof t[n]=="function",r=["actions","choices","initial","margin","roles","styles","symbols","theme","timers","value"],i=["body","footer","error","header","hint","indicator","message","prefix","separator","skip"];for(let n of Object.keys(t.options)){if(r.includes(n)||/^on[A-Z]/.test(n))continue;let s=t.options[n];typeof s=="function"&&e(n)?i.includes(n)||(t[n]=s.bind(t)):typeof t[n]!="function"&&(t[n]=s)}}function GJe(t){typeof t=="number"&&(t=[t,t,t,t]);let e=[].concat(t||[]),r=n=>n%2==0?` -`:" ",i=[];for(let n=0;n<4;n++){let s=r(n);e[n]?i.push(s.repeat(e[n])):i.push("")}return i}yne.exports=T0});var bne=E((BCt,Bne)=>{"use strict";var jJe=Mi(),Qne={default(t,e){return e},checkbox(t,e){throw new Error("checkbox role is not implemented yet")},editable(t,e){throw new Error("editable role is not implemented yet")},expandable(t,e){throw new Error("expandable role is not implemented yet")},heading(t,e){return e.disabled="",e.indicator=[e.indicator," "].find(r=>r!=null),e.message=e.message||"",e},input(t,e){throw new Error("input role is not implemented yet")},option(t,e){return Qne.default(t,e)},radio(t,e){throw new Error("radio role is not implemented yet")},separator(t,e){return e.disabled="",e.indicator=[e.indicator," "].find(r=>r!=null),e.message=e.message||t.symbols.line.repeat(5),e},spacer(t,e){return e}};Bne.exports=(t,e={})=>{let r=jJe.merge({},Qne,e.roles);return r[t]||r.default}});var sC=E((QCt,vne)=>{"use strict";var YJe=js(),qJe=sf(),JJe=bne(),M0=Mi(),{reorder:QN,scrollUp:WJe,scrollDown:zJe,isObject:Sne,swap:VJe}=M0,xne=class extends qJe{constructor(e){super(e);this.cursorHide(),this.maxSelected=e.maxSelected||Infinity,this.multiple=e.multiple||!1,this.initial=e.initial||0,this.delay=e.delay||0,this.longest=0,this.num=""}async initialize(){typeof this.options.initial=="function"&&(this.initial=await this.options.initial.call(this)),await this.reset(!0),await super.initialize()}async reset(){let{choices:e,initial:r,autofocus:i,suggest:n}=this.options;if(this.state._choices=[],this.state.choices=[],this.choices=await Promise.all(await this.toChoices(e)),this.choices.forEach(s=>s.enabled=!1),typeof n!="function"&&this.selectable.length===0)throw new Error("At least one choice must be selectable");Sne(r)&&(r=Object.keys(r)),Array.isArray(r)?(i!=null&&(this.index=this.findIndex(i)),r.forEach(s=>this.enable(this.find(s))),await this.render()):(i!=null&&(r=i),typeof r=="string"&&(r=this.findIndex(r)),typeof r=="number"&&r>-1&&(this.index=Math.max(0,Math.min(r,this.choices.length)),this.enable(this.find(this.index)))),this.isDisabled(this.focused)&&await this.down()}async toChoices(e,r){this.state.loadingChoices=!0;let i=[],n=0,s=async(o,a)=>{typeof o=="function"&&(o=await o.call(this)),o instanceof Promise&&(o=await o);for(let l=0;l(this.state.loadingChoices=!1,o))}async toChoice(e,r,i){if(typeof e=="function"&&(e=await e.call(this,this)),e instanceof Promise&&(e=await e),typeof e=="string"&&(e={name:e}),e.normalized)return e;e.normalized=!0;let n=e.value;if(e=JJe(e.role,this.options)(this,e),typeof e.disabled=="string"&&!e.hint&&(e.hint=e.disabled,e.disabled=!0),e.disabled===!0&&e.hint==null&&(e.hint="(disabled)"),e.index!=null)return e;e.name=e.name||e.key||e.title||e.value||e.message,e.message=e.message||e.name||"",e.value=[e.value,e.name].find(this.isValue.bind(this)),e.input="",e.index=r,e.cursor=0,M0.define(e,"parent",i),e.level=i?i.level+1:1,e.indent==null&&(e.indent=i?i.indent+" ":e.indent||""),e.path=i?i.path+"."+e.name:e.name,e.enabled=!!(this.multiple&&!this.isDisabled(e)&&(e.enabled||this.isSelected(e))),this.isDisabled(e)||(this.longest=Math.max(this.longest,YJe.unstyle(e.message).length));let o=P({},e);return e.reset=(a=o.input,l=o.value)=>{for(let c of Object.keys(o))e[c]=o[c];e.input=a,e.value=l},n==null&&typeof e.initial=="function"&&(e.input=await e.initial.call(this,this.state,e,r)),e}async onChoice(e,r){this.emit("choice",e,r,this),typeof e.onChoice=="function"&&await e.onChoice.call(this,this.state,e,r)}async addChoice(e,r,i){let n=await this.toChoice(e,r,i);return this.choices.push(n),this.index=this.choices.length-1,this.limit=this.choices.length,n}async newItem(e,r,i){let n=P({name:"New choice name?",editable:!0,newChoice:!0},e),s=await this.addChoice(n,r,i);return s.updateChoice=()=>{delete s.newChoice,s.name=s.message=s.input,s.input="",s.cursor=0},this.render()}indent(e){return e.indent==null?e.level>1?" ".repeat(e.level-1):"":e.indent}dispatch(e,r){if(this.multiple&&this[r.name])return this[r.name]();this.alert()}focus(e,r){return typeof r!="boolean"&&(r=e.enabled),r&&!e.enabled&&this.selected.length>=this.maxSelected?this.alert():(this.index=e.index,e.enabled=r&&!this.isDisabled(e),e)}space(){return this.multiple?(this.toggle(this.focused),this.render()):this.alert()}a(){if(this.maxSelectedr.enabled);return this.choices.forEach(r=>r.enabled=!e),this.render()}i(){return this.choices.length-this.selected.length>this.maxSelected?this.alert():(this.choices.forEach(e=>e.enabled=!e.enabled),this.render())}g(e=this.focused){return this.choices.some(r=>!!r.parent)?(this.toggle(e.parent&&!e.choices?e.parent:e),this.render()):this.a()}toggle(e,r){if(!e.enabled&&this.selected.length>=this.maxSelected)return this.alert();typeof r!="boolean"&&(r=!e.enabled),e.enabled=r,e.choices&&e.choices.forEach(n=>this.toggle(n,r));let i=e.parent;for(;i;){let n=i.choices.filter(s=>this.isDisabled(s));i.enabled=n.every(s=>s.enabled===!0),i=i.parent}return kne(this,this.choices),this.emit("toggle",e,this),e}enable(e){return this.selected.length>=this.maxSelected?this.alert():(e.enabled=!this.isDisabled(e),e.choices&&e.choices.forEach(this.enable.bind(this)),e)}disable(e){return e.enabled=!1,e.choices&&e.choices.forEach(this.disable.bind(this)),e}number(e){this.num+=e;let r=i=>{let n=Number(i);if(n>this.choices.length-1)return this.alert();let s=this.focused,o=this.choices.find(a=>n===a.index);if(!o.enabled&&this.selected.length>=this.maxSelected)return this.alert();if(this.visible.indexOf(o)===-1){let a=QN(this.choices),l=a.indexOf(o);if(s.index>l){let c=a.slice(l,l+this.limit),u=a.filter(g=>!c.includes(g));this.choices=c.concat(u)}else{let c=l-this.limit+1;this.choices=a.slice(c).concat(a.slice(0,c))}}return this.index=this.choices.indexOf(o),this.toggle(this.focused),this.render()};return clearTimeout(this.numberTimeout),new Promise(i=>{let n=this.choices.length,s=this.num,o=(a=!1,l)=>{clearTimeout(this.numberTimeout),a&&(l=r(s)),this.num="",i(l)};if(s==="0"||s.length===1&&Number(s+"0")>n)return o(!0);if(Number(s)>n)return o(!1,this.alert());this.numberTimeout=setTimeout(()=>o(!0),this.delay)})}home(){return this.choices=QN(this.choices),this.index=0,this.render()}end(){let e=this.choices.length-this.limit,r=QN(this.choices);return this.choices=r.slice(e).concat(r.slice(0,e)),this.index=this.limit-1,this.render()}first(){return this.index=0,this.render()}last(){return this.index=this.visible.length-1,this.render()}prev(){return this.visible.length<=1?this.alert():this.up()}next(){return this.visible.length<=1?this.alert():this.down()}right(){return this.cursor>=this.input.length?this.alert():(this.cursor++,this.render())}left(){return this.cursor<=0?this.alert():(this.cursor--,this.render())}up(){let e=this.choices.length,r=this.visible.length,i=this.index;return this.options.scroll===!1&&i===0?this.alert():e>r&&i===0?this.scrollUp():(this.index=(i-1%e+e)%e,this.isDisabled()?this.up():this.render())}down(){let e=this.choices.length,r=this.visible.length,i=this.index;return this.options.scroll===!1&&i===r-1?this.alert():e>r&&i===r-1?this.scrollDown():(this.index=(i+1)%e,this.isDisabled()?this.down():this.render())}scrollUp(e=0){return this.choices=WJe(this.choices),this.index=e,this.isDisabled()?this.up():this.render()}scrollDown(e=this.visible.length-1){return this.choices=zJe(this.choices),this.index=e,this.isDisabled()?this.down():this.render()}async shiftUp(){if(this.options.sort===!0){this.sorting=!0,this.swap(this.index-1),await this.up(),this.sorting=!1;return}return this.scrollUp(this.index)}async shiftDown(){if(this.options.sort===!0){this.sorting=!0,this.swap(this.index+1),await this.down(),this.sorting=!1;return}return this.scrollDown(this.index)}pageUp(){return this.visible.length<=1?this.alert():(this.limit=Math.max(this.limit-1,0),this.index=Math.min(this.limit-1,this.index),this._limit=this.limit,this.isDisabled()?this.up():this.render())}pageDown(){return this.visible.length>=this.choices.length?this.alert():(this.index=Math.max(0,this.index),this.limit=Math.min(this.limit+1,this.choices.length),this._limit=this.limit,this.isDisabled()?this.down():this.render())}swap(e){VJe(this.choices,this.index,e)}isDisabled(e=this.focused){return e&&["disabled","collapsed","hidden","completing","readonly"].some(i=>e[i]===!0)?!0:e&&e.role==="heading"}isEnabled(e=this.focused){if(Array.isArray(e))return e.every(r=>this.isEnabled(r));if(e.choices){let r=e.choices.filter(i=>!this.isDisabled(i));return e.enabled&&r.every(i=>this.isEnabled(i))}return e.enabled&&!this.isDisabled(e)}isChoice(e,r){return e.name===r||e.index===Number(r)}isSelected(e){return Array.isArray(this.initial)?this.initial.some(r=>this.isChoice(e,r)):this.isChoice(e,this.initial)}map(e=[],r="value"){return[].concat(e||[]).reduce((i,n)=>(i[n]=this.find(n,r),i),{})}filter(e,r){let i=(a,l)=>[a.name,l].includes(e),n=typeof e=="function"?e:i,o=(this.options.multiple?this.state._choices:this.choices).filter(n);return r?o.map(a=>a[r]):o}find(e,r){if(Sne(e))return r?e[r]:e;let i=(o,a)=>[o.name,a].includes(e),n=typeof e=="function"?e:i,s=this.choices.find(n);if(s)return r?s[r]:s}findIndex(e){return this.choices.indexOf(this.find(e))}async submit(){let e=this.focused;if(!e)return this.alert();if(e.newChoice)return e.input?(e.updateChoice(),this.render()):this.alert();if(this.choices.some(o=>o.newChoice))return this.alert();let{reorder:r,sort:i}=this.options,n=this.multiple===!0,s=this.selected;return s===void 0?this.alert():(Array.isArray(s)&&r!==!1&&i!==!0&&(s=M0.reorder(s)),this.value=n?s.map(o=>o.name):s.name,super.submit())}set choices(e=[]){this.state._choices=this.state._choices||[],this.state.choices=e;for(let r of e)this.state._choices.some(i=>i.name===r.name)||this.state._choices.push(r);if(!this._initial&&this.options.initial){this._initial=!0;let r=this.initial;if(typeof r=="string"||typeof r=="number"){let i=this.find(r);i&&(this.initial=i.index,this.focus(i,!0))}}}get choices(){return kne(this,this.state.choices||[])}set visible(e){this.state.visible=e}get visible(){return(this.state.visible||this.choices).slice(0,this.limit)}set limit(e){this.state.limit=e}get limit(){let{state:e,options:r,choices:i}=this,n=e.limit||this._limit||r.limit||i.length;return Math.min(n,this.height)}set value(e){super.value=e}get value(){return typeof super.value!="string"&&super.value===this.initial?this.input:super.value}set index(e){this.state.index=e}get index(){return Math.max(0,this.state?this.state.index:0)}get enabled(){return this.filter(this.isEnabled.bind(this))}get focused(){let e=this.choices[this.index];return e&&this.state.submitted&&this.multiple!==!0&&(e.enabled=!0),e}get selectable(){return this.choices.filter(e=>!this.isDisabled(e))}get selected(){return this.multiple?this.enabled:this.focused}};function kne(t,e){if(e instanceof Promise)return e;if(typeof e=="function"){if(M0.isAsyncFn(e))return e;e=e.call(t,t)}for(let r of e){if(Array.isArray(r.choices)){let i=r.choices.filter(n=>!t.isDisabled(n));r.enabled=i.every(n=>n.enabled===!0)}t.isDisabled(r)===!0&&delete r.enabled}return e}vne.exports=xne});var GA=E((bCt,Pne)=>{"use strict";var _Je=sC(),bN=Mi(),Dne=class extends _Je{constructor(e){super(e);this.emptyError=this.options.emptyError||"No items were selected"}async dispatch(e,r){if(this.multiple)return this[r.name]?await this[r.name](e,r):await super.dispatch(e,r);this.alert()}separator(){if(this.options.separator)return super.separator();let e=this.styles.muted(this.symbols.ellipsis);return this.state.submitted?super.separator():e}pointer(e,r){return!this.multiple||this.options.pointer?super.pointer(e,r):""}indicator(e,r){return this.multiple?super.indicator(e,r):""}choiceMessage(e,r){let i=this.resolve(e.message,this.state,e,r);return e.role==="heading"&&!bN.hasColor(i)&&(i=this.styles.strong(i)),this.resolve(i,this.state,e,r)}choiceSeparator(){return":"}async renderChoice(e,r){await this.onChoice(e,r);let i=this.index===r,n=await this.pointer(e,r),s=await this.indicator(e,r)+(e.pad||""),o=await this.resolve(e.hint,this.state,e,r);o&&!bN.hasColor(o)&&(o=this.styles.muted(o));let a=this.indent(e),l=await this.choiceMessage(e,r),c=()=>[this.margin[3],a+n+s,l,this.margin[1],o].filter(Boolean).join(" ");return e.role==="heading"?c():e.disabled?(bN.hasColor(l)||(l=this.styles.disabled(l)),c()):(i&&(l=this.styles.em(l)),c())}async renderChoices(){if(this.state.loading==="choices")return this.styles.warning("Loading choices");if(this.state.submitted)return"";let e=this.visible.map(async(s,o)=>await this.renderChoice(s,o)),r=await Promise.all(e);r.length||r.push(this.styles.danger("No matching choices"));let i=this.margin[0]+r.join(` -`),n;return this.options.choicesHeader&&(n=await this.resolve(this.options.choicesHeader,this.state)),[n,i].filter(Boolean).join(` -`)}format(){return!this.state.submitted||this.state.cancelled?"":Array.isArray(this.selected)?this.selected.map(e=>this.styles.primary(e.name)).join(", "):this.styles.primary(this.selected.name)}async render(){let{submitted:e,size:r}=this.state,i="",n=await this.header(),s=await this.prefix(),o=await this.separator(),a=await this.message();this.options.promptLine!==!1&&(i=[s,a,o,""].join(" "),this.state.prompt=i);let l=await this.format(),c=await this.error()||await this.hint(),u=await this.renderChoices(),g=await this.footer();l&&(i+=l),c&&!i.includes(c)&&(i+=" "+c),e&&!l&&!u.trim()&&this.multiple&&this.emptyError!=null&&(i+=this.styles.danger(this.emptyError)),this.clear(r),this.write([n,i,u,g].filter(Boolean).join(` -`)),this.write(this.margin[2]),this.restore()}};Pne.exports=Dne});var Nne=E((vCt,Rne)=>{"use strict";var XJe=GA(),ZJe=(t,e)=>{let r=t.toLowerCase();return i=>{let s=i.toLowerCase().indexOf(r),o=e(i.slice(s,s+r.length));return s>=0?i.slice(0,s)+o+i.slice(s+r.length):i}},Fne=class extends XJe{constructor(e){super(e);this.cursorShow()}moveCursor(e){this.state.cursor+=e}dispatch(e){return this.append(e)}space(e){return this.options.multiple?super.space(e):this.append(e)}append(e){let{cursor:r,input:i}=this.state;return this.input=i.slice(0,r)+e+i.slice(r),this.moveCursor(1),this.complete()}delete(){let{cursor:e,input:r}=this.state;return r?(this.input=r.slice(0,e-1)+r.slice(e),this.moveCursor(-1),this.complete()):this.alert()}deleteForward(){let{cursor:e,input:r}=this.state;return r[e]===void 0?this.alert():(this.input=`${r}`.slice(0,e)+`${r}`.slice(e+1),this.complete())}number(e){return this.append(e)}async complete(){this.completing=!0,this.choices=await this.suggest(this.input,this.state._choices),this.state.limit=void 0,this.index=Math.min(Math.max(this.visible.length-1,0),this.index),await this.render(),this.completing=!1}suggest(e=this.input,r=this.state._choices){if(typeof this.options.suggest=="function")return this.options.suggest.call(this,e,r);let i=e.toLowerCase();return r.filter(n=>n.message.toLowerCase().includes(i))}pointer(){return""}format(){if(!this.focused)return this.input;if(this.options.multiple&&this.state.submitted)return this.selected.map(e=>this.styles.primary(e.message)).join(", ");if(this.state.submitted){let e=this.value=this.input=this.focused.value;return this.styles.primary(e)}return this.input}async render(){if(this.state.status!=="pending")return super.render();let e=this.options.highlight?this.options.highlight.bind(this):this.styles.placeholder,r=ZJe(this.input,e),i=this.choices;this.choices=i.map(n=>_(P({},n),{message:r(n.message)})),await super.render(),this.choices=i}submit(){return this.options.multiple&&(this.value=this.selected.map(e=>e.name)),super.submit()}};Rne.exports=Fne});var SN=E((SCt,Lne)=>{"use strict";var vN=Mi();Lne.exports=(t,e={})=>{t.cursorHide();let{input:r="",initial:i="",pos:n,showCursor:s=!0,color:o}=e,a=o||t.styles.placeholder,l=vN.inverse(t.styles.primary),c=d=>l(t.styles.black(d)),u=r,g=" ",f=c(g);if(t.blink&&t.blink.off===!0&&(c=d=>d,f=""),s&&n===0&&i===""&&r==="")return c(g);if(s&&n===0&&(r===i||r===""))return c(i[0])+a(i.slice(1));i=vN.isPrimitive(i)?`${i}`:"",r=vN.isPrimitive(r)?`${r}`:"";let h=i&&i.startsWith(r)&&i!==r,p=h?c(i[r.length]):f;if(n!==r.length&&s===!0&&(u=r.slice(0,n)+c(r[n])+r.slice(n+1),p=""),s===!1&&(p=""),h){let d=t.styles.unstyle(u+p);return u+p+a(i.slice(d.length))}return u+p}});var O0=E((xCt,Tne)=>{"use strict";var $Je=js(),e3e=GA(),t3e=SN(),Mne=class extends e3e{constructor(e){super(_(P({},e),{multiple:!0}));this.type="form",this.initial=this.options.initial,this.align=[this.options.align,"right"].find(r=>r!=null),this.emptyError="",this.values={}}async reset(e){return await super.reset(),e===!0&&(this._index=this.index),this.index=this._index,this.values={},this.choices.forEach(r=>r.reset&&r.reset()),this.render()}dispatch(e){return!!e&&this.append(e)}append(e){let r=this.focused;if(!r)return this.alert();let{cursor:i,input:n}=r;return r.value=r.input=n.slice(0,i)+e+n.slice(i),r.cursor++,this.render()}delete(){let e=this.focused;if(!e||e.cursor<=0)return this.alert();let{cursor:r,input:i}=e;return e.value=e.input=i.slice(0,r-1)+i.slice(r),e.cursor--,this.render()}deleteForward(){let e=this.focused;if(!e)return this.alert();let{cursor:r,input:i}=e;if(i[r]===void 0)return this.alert();let n=`${i}`.slice(0,r)+`${i}`.slice(r+1);return e.value=e.input=n,this.render()}right(){let e=this.focused;return e?e.cursor>=e.input.length?this.alert():(e.cursor++,this.render()):this.alert()}left(){let e=this.focused;return e?e.cursor<=0?this.alert():(e.cursor--,this.render()):this.alert()}space(e,r){return this.dispatch(e,r)}number(e,r){return this.dispatch(e,r)}next(){let e=this.focused;if(!e)return this.alert();let{initial:r,input:i}=e;return r&&r.startsWith(i)&&i!==r?(e.value=e.input=r,e.cursor=e.value.length,this.render()):super.next()}prev(){let e=this.focused;return e?e.cursor===0?super.prev():(e.value=e.input="",e.cursor=0,this.render()):this.alert()}separator(){return""}format(e){return this.state.submitted?"":super.format(e)}pointer(){return""}indicator(e){return e.input?"\u29BF":"\u2299"}async choiceSeparator(e,r){let i=await this.resolve(e.separator,this.state,e,r)||":";return i?" "+this.styles.disabled(i):""}async renderChoice(e,r){await this.onChoice(e,r);let{state:i,styles:n}=this,{cursor:s,initial:o="",name:a,hint:l,input:c=""}=e,{muted:u,submitted:g,primary:f,danger:h}=n,p=l,d=this.index===r,m=e.validate||(()=>!0),I=await this.choiceSeparator(e,r),B=e.message;this.align==="right"&&(B=B.padStart(this.longest+1," ")),this.align==="left"&&(B=B.padEnd(this.longest+1," "));let b=this.values[a]=c||o,R=c?"success":"dark";await m.call(e,b,this.state)!==!0&&(R="danger");let L=n[R](await this.indicator(e,r))+(e.pad||""),K=this.indent(e),J=()=>[K,L,B+I,c,p].filter(Boolean).join(" ");if(i.submitted)return B=$Je.unstyle(B),c=g(c),p="",J();if(e.format)c=await e.format.call(this,c,e,r);else{let ne=this.styles.muted;c=t3e(this,{input:c,initial:o,pos:s,showCursor:d,color:ne})}return this.isValue(c)||(c=this.styles.muted(this.symbols.ellipsis)),e.result&&(this.values[a]=await e.result.call(this,b,e,r)),d&&(B=f(B)),e.error?c+=(c?" ":"")+h(e.error.trim()):e.hint&&(c+=(c?" ":"")+u(e.hint.trim())),J()}async submit(){return this.value=this.values,super.base.submit.call(this)}};Tne.exports=Mne});var xN=E((kCt,One)=>{"use strict";var r3e=O0(),i3e=()=>{throw new Error("expected prompt to have a custom authenticate method")},Kne=(t=i3e)=>{class e extends r3e{constructor(i){super(i)}async submit(){this.value=await t.call(this,this.values,this.state),super.base.submit.call(this)}static create(i){return Kne(i)}}return e};One.exports=Kne()});var Gne=E((PCt,Une)=>{"use strict";var n3e=xN();function s3e(t,e){return t.username===this.options.username&&t.password===this.options.password}var Hne=(t=s3e)=>{let e=[{name:"username",message:"username"},{name:"password",message:"password",format(i){return this.options.showPassword?i:(this.state.submitted?this.styles.primary:this.styles.muted)(this.symbols.asterisk.repeat(i.length))}}];class r extends n3e.create(t){constructor(n){super(_(P({},n),{choices:e}))}static create(n){return Hne(n)}}return r};Une.exports=Hne()});var K0=E((DCt,jne)=>{"use strict";var o3e=sf(),{isPrimitive:a3e,hasColor:A3e}=Mi(),Yne=class extends o3e{constructor(e){super(e);this.cursorHide()}async initialize(){let e=await this.resolve(this.initial,this.state);this.input=await this.cast(e),await super.initialize()}dispatch(e){return this.isValue(e)?(this.input=e,this.submit()):this.alert()}format(e){let{styles:r,state:i}=this;return i.submitted?r.success(e):r.primary(e)}cast(e){return this.isTrue(e)}isTrue(e){return/^[ty1]/i.test(e)}isFalse(e){return/^[fn0]/i.test(e)}isValue(e){return a3e(e)&&(this.isTrue(e)||this.isFalse(e))}async hint(){if(this.state.status==="pending"){let e=await this.element("hint");return A3e(e)?e:this.styles.muted(e)}}async render(){let{input:e,size:r}=this.state,i=await this.prefix(),n=await this.separator(),s=await this.message(),o=this.styles.muted(this.default),a=[i,s,o,n].filter(Boolean).join(" ");this.state.prompt=a;let l=await this.header(),c=this.value=this.cast(e),u=await this.format(c),g=await this.error()||await this.hint(),f=await this.footer();g&&!a.includes(g)&&(u+=" "+g),a+=" "+u,this.clear(r),this.write([l,a,f].filter(Boolean).join(` -`)),this.restore()}set value(e){super.value=e}get value(){return this.cast(super.value)}};jne.exports=Yne});var Wne=E((RCt,qne)=>{"use strict";var l3e=K0(),Jne=class extends l3e{constructor(e){super(e);this.default=this.options.default||(this.initial?"(Y/n)":"(y/N)")}};qne.exports=Jne});var _ne=E((FCt,zne)=>{"use strict";var c3e=GA(),u3e=O0(),of=u3e.prototype,Vne=class extends c3e{constructor(e){super(_(P({},e),{multiple:!0}));this.align=[this.options.align,"left"].find(r=>r!=null),this.emptyError="",this.values={}}dispatch(e,r){let i=this.focused,n=i.parent||{};return!i.editable&&!n.editable&&(e==="a"||e==="i")?super[e]():of.dispatch.call(this,e,r)}append(e,r){return of.append.call(this,e,r)}delete(e,r){return of.delete.call(this,e,r)}space(e){return this.focused.editable?this.append(e):super.space()}number(e){return this.focused.editable?this.append(e):super.number(e)}next(){return this.focused.editable?of.next.call(this):super.next()}prev(){return this.focused.editable?of.prev.call(this):super.prev()}async indicator(e,r){let i=e.indicator||"",n=e.editable?i:super.indicator(e,r);return await this.resolve(n,this.state,e,r)||""}indent(e){return e.role==="heading"?"":e.editable?" ":" "}async renderChoice(e,r){return e.indent="",e.editable?of.renderChoice.call(this,e,r):super.renderChoice(e,r)}error(){return""}footer(){return this.state.error}async validate(){let e=!0;for(let r of this.choices){if(typeof r.validate!="function"||r.role==="heading")continue;let i=r.parent?this.value[r.parent.name]:this.value;if(r.editable?i=r.value===r.name?r.initial||"":r.value:this.isDisabled(r)||(i=r.enabled===!0),e=await r.validate(i,this.state),e!==!0)break}return e!==!0&&(this.state.error=typeof e=="string"?e:"Invalid Input"),e}submit(){if(this.focused.newChoice===!0)return super.submit();if(this.choices.some(e=>e.newChoice))return this.alert();this.value={};for(let e of this.choices){let r=e.parent?this.value[e.parent.name]:this.value;if(e.role==="heading"){this.value[e.name]={};continue}e.editable?r[e.name]=e.value===e.name?e.initial||"":e.value:this.isDisabled(e)||(r[e.name]=e.enabled===!0)}return this.base.submit.call(this)}};zne.exports=Vne});var Mc=E((NCt,Xne)=>{"use strict";var g3e=sf(),f3e=SN(),{isPrimitive:h3e}=Mi(),Zne=class extends g3e{constructor(e){super(e);this.initial=h3e(this.initial)?String(this.initial):"",this.initial&&this.cursorHide(),this.state.prevCursor=0,this.state.clipboard=[]}async keypress(e,r={}){let i=this.state.prevKeypress;return this.state.prevKeypress=r,this.options.multiline===!0&&r.name==="return"&&(!i||i.name!=="return")?this.append(` -`,r):super.keypress(e,r)}moveCursor(e){this.cursor+=e}reset(){return this.input=this.value="",this.cursor=0,this.render()}dispatch(e,r){if(!e||r.ctrl||r.code)return this.alert();this.append(e)}append(e){let{cursor:r,input:i}=this.state;this.input=`${i}`.slice(0,r)+e+`${i}`.slice(r),this.moveCursor(String(e).length),this.render()}insert(e){this.append(e)}delete(){let{cursor:e,input:r}=this.state;if(e<=0)return this.alert();this.input=`${r}`.slice(0,e-1)+`${r}`.slice(e),this.moveCursor(-1),this.render()}deleteForward(){let{cursor:e,input:r}=this.state;if(r[e]===void 0)return this.alert();this.input=`${r}`.slice(0,e)+`${r}`.slice(e+1),this.render()}cutForward(){let e=this.cursor;if(this.input.length<=e)return this.alert();this.state.clipboard.push(this.input.slice(e)),this.input=this.input.slice(0,e),this.render()}cutLeft(){let e=this.cursor;if(e===0)return this.alert();let r=this.input.slice(0,e),i=this.input.slice(e),n=r.split(" ");this.state.clipboard.push(n.pop()),this.input=n.join(" "),this.cursor=this.input.length,this.input+=i,this.render()}paste(){if(!this.state.clipboard.length)return this.alert();this.insert(this.state.clipboard.pop()),this.render()}toggleCursor(){this.state.prevCursor?(this.cursor=this.state.prevCursor,this.state.prevCursor=0):(this.state.prevCursor=this.cursor,this.cursor=0),this.render()}first(){this.cursor=0,this.render()}last(){this.cursor=this.input.length-1,this.render()}next(){let e=this.initial!=null?String(this.initial):"";if(!e||!e.startsWith(this.input))return this.alert();this.input=this.initial,this.cursor=this.initial.length,this.render()}prev(){if(!this.input)return this.alert();this.reset()}backward(){return this.left()}forward(){return this.right()}right(){return this.cursor>=this.input.length?this.alert():(this.moveCursor(1),this.render())}left(){return this.cursor<=0?this.alert():(this.moveCursor(-1),this.render())}isValue(e){return!!e}async format(e=this.value){let r=await this.resolve(this.initial,this.state);return this.state.submitted?this.styles.submitted(e||r):f3e(this,{input:e,initial:r,pos:this.cursor})}async render(){let e=this.state.size,r=await this.prefix(),i=await this.separator(),n=await this.message(),s=[r,n,i].filter(Boolean).join(" ");this.state.prompt=s;let o=await this.header(),a=await this.format(),l=await this.error()||await this.hint(),c=await this.footer();l&&!a.includes(l)&&(a+=" "+l),s+=" "+a,this.clear(e),this.write([o,s,c].filter(Boolean).join(` -`)),this.restore()}};Xne.exports=Zne});var ese=E((LCt,$ne)=>{"use strict";var p3e=t=>t.filter((e,r)=>t.lastIndexOf(e)===r),U0=t=>p3e(t).filter(Boolean);$ne.exports=(t,e={},r="")=>{let{past:i=[],present:n=""}=e,s,o;switch(t){case"prev":case"undo":return s=i.slice(0,i.length-1),o=i[i.length-1]||"",{past:U0([r,...s]),present:o};case"next":case"redo":return s=i.slice(1),o=i[0]||"",{past:U0([...s,r]),present:o};case"save":return{past:U0([...i,r]),present:""};case"remove":return o=U0(i.filter(a=>a!==r)),n="",o.length&&(n=o.pop()),{past:o,present:n};default:throw new Error(`Invalid action: "${t}"`)}}});var kN=E((TCt,tse)=>{"use strict";var d3e=Mc(),rse=ese(),ise=class extends d3e{constructor(e){super(e);let r=this.options.history;if(r&&r.store){let i=r.values||this.initial;this.autosave=!!r.autosave,this.store=r.store,this.data=this.store.get("values")||{past:[],present:i},this.initial=this.data.present||this.data.past[this.data.past.length-1]}}completion(e){return this.store?(this.data=rse(e,this.data,this.input),this.data.present?(this.input=this.data.present,this.cursor=this.input.length,this.render()):this.alert()):this.alert()}altUp(){return this.completion("prev")}altDown(){return this.completion("next")}prev(){return this.save(),super.prev()}save(){!this.store||(this.data=rse("save",this.data,this.input),this.store.set("values",this.data))}submit(){return this.store&&this.autosave===!0&&this.save(),super.submit()}};tse.exports=ise});var ose=E((MCt,nse)=>{"use strict";var C3e=Mc(),sse=class extends C3e{format(){return""}};nse.exports=sse});var lse=E((OCt,ase)=>{"use strict";var m3e=Mc(),Ase=class extends m3e{constructor(e={}){super(e);this.sep=this.options.separator||/, */,this.initial=e.initial||""}split(e=this.value){return e?String(e).split(this.sep):[]}format(){let e=this.state.submitted?this.styles.primary:r=>r;return this.list.map(e).join(", ")}async submit(e){let r=this.state.error||await this.validate(this.list,this.state);return r!==!0?(this.state.error=r,super.submit()):(this.value=this.list,super.submit())}get list(){return this.split()}};ase.exports=Ase});var gse=E((KCt,cse)=>{"use strict";var E3e=GA(),use=class extends E3e{constructor(e){super(_(P({},e),{multiple:!0}))}};cse.exports=use});var PN=E((UCt,fse)=>{"use strict";var I3e=Mc(),hse=class extends I3e{constructor(e={}){super(P({style:"number"},e));this.min=this.isValue(e.min)?this.toNumber(e.min):-Infinity,this.max=this.isValue(e.max)?this.toNumber(e.max):Infinity,this.delay=e.delay!=null?e.delay:1e3,this.float=e.float!==!1,this.round=e.round===!0||e.float===!1,this.major=e.major||10,this.minor=e.minor||1,this.initial=e.initial!=null?e.initial:"",this.input=String(this.initial),this.cursor=this.input.length,this.cursorShow()}append(e){return!/[-+.]/.test(e)||e==="."&&this.input.includes(".")?this.alert("invalid number"):super.append(e)}number(e){return super.append(e)}next(){return this.input&&this.input!==this.initial?this.alert():this.isValue(this.initial)?(this.input=this.initial,this.cursor=String(this.initial).length,this.render()):this.alert()}up(e){let r=e||this.minor,i=this.toNumber(this.input);return i>this.max+r?this.alert():(this.input=`${i+r}`,this.render())}down(e){let r=e||this.minor,i=this.toNumber(this.input);return ithis.isValue(r));return this.value=this.toNumber(e||0),super.submit()}};fse.exports=hse});var dse=E((HCt,pse)=>{pse.exports=PN()});var Ese=E((GCt,Cse)=>{"use strict";var y3e=Mc(),mse=class extends y3e{constructor(e){super(e);this.cursorShow()}format(e=this.input){return this.keypressed?(this.state.submitted?this.styles.primary:this.styles.muted)(this.symbols.asterisk.repeat(e.length)):""}};Cse.exports=mse});var Bse=E((jCt,Ise)=>{"use strict";var w3e=js(),B3e=sC(),yse=Mi(),wse=class extends B3e{constructor(e={}){super(e);this.widths=[].concat(e.messageWidth||50),this.align=[].concat(e.align||"left"),this.linebreak=e.linebreak||!1,this.edgeLength=e.edgeLength||3,this.newline=e.newline||` - `;let r=e.startNumber||1;typeof this.scale=="number"&&(this.scaleKey=!1,this.scale=Array(this.scale).fill(0).map((i,n)=>({name:n+r})))}async reset(){return this.tableized=!1,await super.reset(),this.render()}tableize(){if(this.tableized===!0)return;this.tableized=!0;let e=0;for(let r of this.choices){e=Math.max(e,r.message.length),r.scaleIndex=r.initial||2,r.scale=[];for(let i=0;i=this.scale.length-1?this.alert():(e.scaleIndex++,this.render())}left(){let e=this.focused;return e.scaleIndex<=0?this.alert():(e.scaleIndex--,this.render())}indent(){return""}format(){return this.state.submitted?this.choices.map(r=>this.styles.info(r.index)).join(", "):""}pointer(){return""}renderScaleKey(){if(this.scaleKey===!1||this.state.submitted)return"";let e=this.scale.map(i=>` ${i.name} - ${i.message}`);return["",...e].map(i=>this.styles.muted(i)).join(` -`)}renderScaleHeading(e){let r=this.scale.map(l=>l.name);typeof this.options.renderScaleHeading=="function"&&(r=this.options.renderScaleHeading.call(this,e));let i=this.scaleLength-r.join("").length,n=Math.round(i/(r.length-1)),o=r.map(l=>this.styles.strong(l)).join(" ".repeat(n)),a=" ".repeat(this.widths[0]);return this.margin[3]+a+this.margin[1]+o}scaleIndicator(e,r,i){if(typeof this.options.scaleIndicator=="function")return this.options.scaleIndicator.call(this,e,r,i);let n=e.scaleIndex===r.index;return r.disabled?this.styles.hint(this.symbols.radio.disabled):n?this.styles.success(this.symbols.radio.on):this.symbols.radio.off}renderScale(e,r){let i=e.scale.map(s=>this.scaleIndicator(e,s,r)),n=this.term==="Hyper"?"":" ";return i.join(n+this.symbols.line.repeat(this.edgeLength))}async renderChoice(e,r){await this.onChoice(e,r);let i=this.index===r,n=await this.pointer(e,r),s=await e.hint;s&&!yse.hasColor(s)&&(s=this.styles.muted(s));let o=p=>this.margin[3]+p.replace(/\s+$/,"").padEnd(this.widths[0]," "),a=this.newline,l=this.indent(e),c=await this.resolve(e.message,this.state,e,r),u=await this.renderScale(e,r),g=this.margin[1]+this.margin[3];this.scaleLength=w3e.unstyle(u).length,this.widths[0]=Math.min(this.widths[0],this.width-this.scaleLength-g.length);let h=yse.wordWrap(c,{width:this.widths[0],newline:a}).split(` -`).map(p=>o(p)+this.margin[1]);return i&&(u=this.styles.info(u),h=h.map(p=>this.styles.info(p))),h[0]+=u,this.linebreak&&h.push(""),[l+n,h.join(` -`)].filter(Boolean)}async renderChoices(){if(this.state.submitted)return"";this.tableize();let e=this.visible.map(async(n,s)=>await this.renderChoice(n,s)),r=await Promise.all(e),i=await this.renderScaleHeading();return this.margin[0]+[i,...r.map(n=>n.join(" "))].join(` -`)}async render(){let{submitted:e,size:r}=this.state,i=await this.prefix(),n=await this.separator(),s=await this.message(),o="";this.options.promptLine!==!1&&(o=[i,s,n,""].join(" "),this.state.prompt=o);let a=await this.header(),l=await this.format(),c=await this.renderScaleKey(),u=await this.error()||await this.hint(),g=await this.renderChoices(),f=await this.footer(),h=this.emptyError;l&&(o+=l),u&&!o.includes(u)&&(o+=" "+u),e&&!l&&!g.trim()&&this.multiple&&h!=null&&(o+=this.styles.danger(h)),this.clear(r),this.write([a,o,c,g,f].filter(Boolean).join(` -`)),this.state.submitted||this.write(this.margin[2]),this.restore()}submit(){this.value={};for(let e of this.choices)this.value[e.name]=e.scaleIndex;return this.base.submit.call(this)}};Ise.exports=wse});var Sse=E((YCt,Qse)=>{"use strict";var bse=js(),Q3e=(t="")=>typeof t=="string"?t.replace(/^['"]|['"]$/g,""):"",vse=class{constructor(e){this.name=e.key,this.field=e.field||{},this.value=Q3e(e.initial||this.field.initial||""),this.message=e.message||this.name,this.cursor=0,this.input="",this.lines=[]}},b3e=async(t={},e={},r=i=>i)=>{let i=new Set,n=t.fields||[],s=t.template,o=[],a=[],l=[],c=1;typeof s=="function"&&(s=await s());let u=-1,g=()=>s[++u],f=()=>s[u+1],h=p=>{p.line=c,o.push(p)};for(h({type:"bos",value:""});uR.name===I.key);I.field=n.find(R=>R.name===I.key),b||(b=new vse(I),a.push(b)),b.lines.push(I.line-1);continue}let d=o[o.length-1];d.type==="text"&&d.line===c?d.value+=p:h({type:"text",value:p})}return h({type:"eos",value:""}),{input:s,tabstops:o,unique:i,keys:l,items:a}};Qse.exports=async t=>{let e=t.options,r=new Set(e.required===!0?[]:e.required||[]),i=P(P({},e.values),e.initial),{tabstops:n,items:s,keys:o}=await b3e(e,i),a=DN("result",t,e),l=DN("format",t,e),c=DN("validate",t,e,!0),u=t.isValue.bind(t);return async(g={},f=!1)=>{let h=0;g.required=r,g.items=s,g.keys=o,g.output="";let p=async(B,b,R,H)=>{let L=await c(B,b,R,H);return L===!1?"Invalid field "+R.name:L};for(let B of n){let b=B.value,R=B.key;if(B.type!=="template"){b&&(g.output+=b);continue}if(B.type==="template"){let H=s.find(q=>q.name===R);e.required===!0&&g.required.add(H.name);let L=[H.input,g.values[H.value],H.value,b].find(u),J=(H.field||{}).message||B.inner;if(f){let q=await p(g.values[R],g,H,h);if(q&&typeof q=="string"||q===!1){g.invalid.set(R,q);continue}g.invalid.delete(R);let A=await a(g.values[R],g,H,h);g.output+=bse.unstyle(A);continue}H.placeholder=!1;let ne=b;b=await l(b,g,H,h),L!==b?(g.values[R]=L,b=t.styles.typing(L),g.missing.delete(J)):(g.values[R]=void 0,L=`<${J}>`,b=t.styles.primary(L),H.placeholder=!0,g.required.has(R)&&g.missing.add(J)),g.missing.has(J)&&g.validating&&(b=t.styles.warning(L)),g.invalid.has(R)&&g.validating&&(b=t.styles.danger(L)),h===g.index&&(ne!==b?b=t.styles.underline(b):b=t.styles.heading(bse.unstyle(b))),h++}b&&(g.output+=b)}let d=g.output.split(` -`).map(B=>" "+B),m=s.length,I=0;for(let B of s)g.invalid.has(B.name)&&B.lines.forEach(b=>{d[b][0]===" "&&(d[b]=g.styles.danger(g.symbols.bullet)+d[b].slice(1))}),t.isValue(g.values[B.name])&&I++;return g.completed=(I/m*100).toFixed(0),g.output=d.join(` -`),g.output}};function DN(t,e,r,i){return(n,s,o,a)=>typeof o.field[t]=="function"?o.field[t].call(e,n,s,o,a):[i,n].find(l=>e.isValue(l))}});var Pse=E((qCt,xse)=>{"use strict";var v3e=js(),S3e=Sse(),x3e=sf(),kse=class extends x3e{constructor(e){super(e);this.cursorHide(),this.reset(!0)}async initialize(){this.interpolate=await S3e(this),await super.initialize()}async reset(e){this.state.keys=[],this.state.invalid=new Map,this.state.missing=new Set,this.state.completed=0,this.state.values={},e!==!0&&(await this.initialize(),await this.render())}moveCursor(e){let r=this.getItem();this.cursor+=e,r.cursor+=e}dispatch(e,r){if(!r.code&&!r.ctrl&&e!=null&&this.getItem()){this.append(e,r);return}this.alert()}append(e,r){let i=this.getItem(),n=i.input.slice(0,this.cursor),s=i.input.slice(this.cursor);this.input=i.input=`${n}${e}${s}`,this.moveCursor(1),this.render()}delete(){let e=this.getItem();if(this.cursor<=0||!e.input)return this.alert();let r=e.input.slice(this.cursor),i=e.input.slice(0,this.cursor-1);this.input=e.input=`${i}${r}`,this.moveCursor(-1),this.render()}increment(e){return e>=this.state.keys.length-1?0:e+1}decrement(e){return e<=0?this.state.keys.length-1:e-1}first(){this.state.index=0,this.render()}last(){this.state.index=this.state.keys.length-1,this.render()}right(){if(this.cursor>=this.input.length)return this.alert();this.moveCursor(1),this.render()}left(){if(this.cursor<=0)return this.alert();this.moveCursor(-1),this.render()}prev(){this.state.index=this.decrement(this.state.index),this.getItem(),this.render()}next(){this.state.index=this.increment(this.state.index),this.getItem(),this.render()}up(){this.prev()}down(){this.next()}format(e){let r=this.state.completed<100?this.styles.warning:this.styles.success;return this.state.submitted===!0&&this.state.completed!==100&&(r=this.styles.danger),r(`${this.state.completed}% completed`)}async render(){let{index:e,keys:r=[],submitted:i,size:n}=this.state,s=[this.options.newline,` -`].find(B=>B!=null),o=await this.prefix(),a=await this.separator(),l=await this.message(),c=[o,l,a].filter(Boolean).join(" ");this.state.prompt=c;let u=await this.header(),g=await this.error()||"",f=await this.hint()||"",h=i?"":await this.interpolate(this.state),p=this.state.key=r[e]||"",d=await this.format(p),m=await this.footer();d&&(c+=" "+d),f&&!d&&this.state.completed===0&&(c+=" "+f),this.clear(n);let I=[u,c,h,m,g.trim()];this.write(I.filter(Boolean).join(s)),this.restore()}getItem(e){let{items:r,keys:i,index:n}=this.state,s=r.find(o=>o.name===i[n]);return s&&s.input!=null&&(this.input=s.input,this.cursor=s.cursor),s}async submit(){typeof this.interpolate!="function"&&await this.initialize(),await this.interpolate(this.state,!0);let{invalid:e,missing:r,output:i,values:n}=this.state;if(e.size){let a="";for(let[l,c]of e)a+=`Invalid ${l}: ${c} -`;return this.state.error=a,super.submit()}if(r.size)return this.state.error="Required: "+[...r.keys()].join(", "),super.submit();let o=v3e.unstyle(i).split(` -`).map(a=>a.slice(1)).join(` -`);return this.value={values:n,result:o},super.submit()}};xse.exports=kse});var Fse=E((JCt,Dse)=>{"use strict";var k3e="(Use + to sort)",P3e=GA(),Rse=class extends P3e{constructor(e){super(_(P({},e),{reorder:!1,sort:!0,multiple:!0}));this.state.hint=[this.options.hint,k3e].find(this.isValue.bind(this))}indicator(){return""}async renderChoice(e,r){let i=await super.renderChoice(e,r),n=this.symbols.identicalTo+" ",s=this.index===r&&this.sorting?this.styles.muted(n):" ";return this.options.drag===!1&&(s=""),this.options.numbered===!0?s+`${r+1} - `+i:s+i}get selected(){return this.choices}submit(){return this.value=this.choices.map(e=>e.value),super.submit()}};Dse.exports=Rse});var Tse=E((WCt,Nse)=>{"use strict";var D3e=sC(),Lse=class extends D3e{constructor(e={}){super(e);if(this.emptyError=e.emptyError||"No items were selected",this.term=process.env.TERM_PROGRAM,!this.options.header){let r=["","4 - Strongly Agree","3 - Agree","2 - Neutral","1 - Disagree","0 - Strongly Disagree",""];r=r.map(i=>this.styles.muted(i)),this.state.header=r.join(` - `)}}async toChoices(...e){if(this.createdScales)return!1;this.createdScales=!0;let r=await super.toChoices(...e);for(let i of r)i.scale=R3e(5,this.options),i.scaleIdx=2;return r}dispatch(){this.alert()}space(){let e=this.focused,r=e.scale[e.scaleIdx],i=r.selected;return e.scale.forEach(n=>n.selected=!1),r.selected=!i,this.render()}indicator(){return""}pointer(){return""}separator(){return this.styles.muted(this.symbols.ellipsis)}right(){let e=this.focused;return e.scaleIdx>=e.scale.length-1?this.alert():(e.scaleIdx++,this.render())}left(){let e=this.focused;return e.scaleIdx<=0?this.alert():(e.scaleIdx--,this.render())}indent(){return" "}async renderChoice(e,r){await this.onChoice(e,r);let i=this.index===r,n=this.term==="Hyper",s=n?9:8,o=n?"":" ",a=this.symbols.line.repeat(s),l=" ".repeat(s+(n?0:1)),c=b=>(b?this.styles.success("\u25C9"):"\u25EF")+o,u=r+1+".",g=i?this.styles.heading:this.styles.noop,f=await this.resolve(e.message,this.state,e,r),h=this.indent(e),p=h+e.scale.map((b,R)=>c(R===e.scaleIdx)).join(a),d=b=>b===e.scaleIdx?g(b):b,m=h+e.scale.map((b,R)=>d(R)).join(l),I=()=>[u,f].filter(Boolean).join(" "),B=()=>[I(),p,m," "].filter(Boolean).join(` -`);return i&&(p=this.styles.cyan(p),m=this.styles.cyan(m)),B()}async renderChoices(){if(this.state.submitted)return"";let e=this.visible.map(async(i,n)=>await this.renderChoice(i,n)),r=await Promise.all(e);return r.length||r.push(this.styles.danger("No matching choices")),r.join(` -`)}format(){return this.state.submitted?this.choices.map(r=>this.styles.info(r.scaleIdx)).join(", "):""}async render(){let{submitted:e,size:r}=this.state,i=await this.prefix(),n=await this.separator(),s=await this.message(),o=[i,s,n].filter(Boolean).join(" ");this.state.prompt=o;let a=await this.header(),l=await this.format(),c=await this.error()||await this.hint(),u=await this.renderChoices(),g=await this.footer();(l||!c)&&(o+=" "+l),c&&!o.includes(c)&&(o+=" "+c),e&&!l&&!u&&this.multiple&&this.type!=="form"&&(o+=this.styles.danger(this.emptyError)),this.clear(r),this.write([o,a,u,g].filter(Boolean).join(` -`)),this.restore()}submit(){this.value={};for(let e of this.choices)this.value[e.name]=e.scaleIdx;return this.base.submit.call(this)}};function R3e(t,e={}){if(Array.isArray(e.scale))return e.scale.map(i=>P({},i));let r=[];for(let i=1;i{Mse.exports=kN()});var Hse=E((VCt,Kse)=>{"use strict";var F3e=K0(),Use=class extends F3e{async initialize(){await super.initialize(),this.value=this.initial=!!this.options.initial,this.disabled=this.options.disabled||"no",this.enabled=this.options.enabled||"yes",await this.render()}reset(){this.value=this.initial,this.render()}delete(){this.alert()}toggle(){this.value=!this.value,this.render()}enable(){if(this.value===!0)return this.alert();this.value=!0,this.render()}disable(){if(this.value===!1)return this.alert();this.value=!1,this.render()}up(){this.toggle()}down(){this.toggle()}right(){this.toggle()}left(){this.toggle()}next(){this.toggle()}prev(){this.toggle()}dispatch(e="",r){switch(e.toLowerCase()){case" ":return this.toggle();case"1":case"y":case"t":return this.enable();case"0":case"n":case"f":return this.disable();default:return this.alert()}}format(){let e=i=>this.styles.primary.underline(i);return[this.value?this.disabled:e(this.disabled),this.value?e(this.enabled):this.enabled].join(this.styles.muted(" / "))}async render(){let{size:e}=this.state,r=await this.header(),i=await this.prefix(),n=await this.separator(),s=await this.message(),o=await this.format(),a=await this.error()||await this.hint(),l=await this.footer(),c=[i,s,n,o].join(" ");this.state.prompt=c,a&&!c.includes(a)&&(c+=" "+a),this.clear(e),this.write([r,c,l].filter(Boolean).join(` -`)),this.write(this.margin[2]),this.restore()}};Kse.exports=Use});var Yse=E((_Ct,Gse)=>{"use strict";var N3e=GA(),jse=class extends N3e{constructor(e){super(e);if(typeof this.options.correctChoice!="number"||this.options.correctChoice<0)throw new Error("Please specify the index of the correct answer from the list of choices")}async toChoices(e,r){let i=await super.toChoices(e,r);if(i.length<2)throw new Error("Please give at least two choices to the user");if(this.options.correctChoice>i.length)throw new Error("Please specify the index of the correct answer from the list of choices");return i}check(e){return e.index===this.options.correctChoice}async result(e){return{selectedAnswer:e,correctAnswer:this.options.choices[this.options.correctChoice].value,correct:await this.check(this.state)}}};Gse.exports=jse});var Jse=E(RN=>{"use strict";var qse=Mi(),ti=(t,e)=>{qse.defineExport(RN,t,e),qse.defineExport(RN,t.toLowerCase(),e)};ti("AutoComplete",()=>Nne());ti("BasicAuth",()=>Gne());ti("Confirm",()=>Wne());ti("Editable",()=>_ne());ti("Form",()=>O0());ti("Input",()=>kN());ti("Invisible",()=>ose());ti("List",()=>lse());ti("MultiSelect",()=>gse());ti("Numeral",()=>dse());ti("Password",()=>Ese());ti("Scale",()=>Bse());ti("Select",()=>GA());ti("Snippet",()=>Pse());ti("Sort",()=>Fse());ti("Survey",()=>Tse());ti("Text",()=>Ose());ti("Toggle",()=>Hse());ti("Quiz",()=>Yse())});var zse=E((ZCt,Wse)=>{Wse.exports={ArrayPrompt:sC(),AuthPrompt:xN(),BooleanPrompt:K0(),NumberPrompt:PN(),StringPrompt:Mc()}});var aC=E(($Ct,Vse)=>{"use strict";var _se=require("assert"),FN=require("events"),jA=Mi(),No=class extends FN{constructor(e,r){super();this.options=jA.merge({},e),this.answers=P({},r)}register(e,r){if(jA.isObject(e)){for(let n of Object.keys(e))this.register(n,e[n]);return this}_se.equal(typeof r,"function","expected a function");let i=e.toLowerCase();return r.prototype instanceof this.Prompt?this.prompts[i]=r:this.prompts[i]=r(this.Prompt,this),this}async prompt(e=[]){for(let r of[].concat(e))try{typeof r=="function"&&(r=await r.call(this)),await this.ask(jA.merge({},this.options,r))}catch(i){return Promise.reject(i)}return this.answers}async ask(e){typeof e=="function"&&(e=await e.call(this));let r=jA.merge({},this.options,e),{type:i,name:n}=e,{set:s,get:o}=jA;if(typeof i=="function"&&(i=await i.call(this,e,this.answers)),!i)return this.answers[n];_se(this.prompts[i],`Prompt "${i}" is not registered`);let a=new this.prompts[i](r),l=o(this.answers,n);a.state.answers=this.answers,a.enquirer=this,n&&a.on("submit",u=>{this.emit("answer",n,u,a),s(this.answers,n,u)});let c=a.emit.bind(a);return a.emit=(...u)=>(this.emit.call(this,...u),c(...u)),this.emit("prompt",a,this),r.autofill&&l!=null?(a.value=a.input=l,r.autofill==="show"&&await a.submit()):l=a.value=await a.run(),l}use(e){return e.call(this,this),this}set Prompt(e){this._Prompt=e}get Prompt(){return this._Prompt||this.constructor.Prompt}get prompts(){return this.constructor.prompts}static set Prompt(e){this._Prompt=e}static get Prompt(){return this._Prompt||sf()}static get prompts(){return Jse()}static get types(){return zse()}static get prompt(){let e=(r,...i)=>{let n=new this(...i),s=n.emit.bind(n);return n.emit=(...o)=>(e.emit(...o),s(...o)),n.prompt(r)};return jA.mixinEmitter(e,new FN),e}};jA.mixinEmitter(No,new FN);var NN=No.prompts;for(let t of Object.keys(NN)){let e=t.toLowerCase(),r=i=>new NN[t](i).run();No.prompt[e]=r,No[e]=r,No[t]||Reflect.defineProperty(No,t,{get:()=>NN[t]})}var oC=t=>{jA.defineExport(No,t,()=>No.types[t])};oC("ArrayPrompt");oC("AuthPrompt");oC("BooleanPrompt");oC("NumberPrompt");oC("StringPrompt");Vse.exports=No});var loe=E((Gmt,Aoe)=>{function K3e(t,e){for(var r=-1,i=t==null?0:t.length;++r{var U3e=XB(),H3e=jg();function G3e(t,e,r,i){var n=!r;r||(r={});for(var s=-1,o=e.length;++s{var j3e=Af(),Y3e=zg();function q3e(t,e){return t&&j3e(e,Y3e(e),t)}uoe.exports=q3e});var hoe=E((qmt,foe)=>{function J3e(t){var e=[];if(t!=null)for(var r in Object(t))e.push(r);return e}foe.exports=J3e});var doe=E((Jmt,poe)=>{var W3e=Gs(),z3e=u0(),V3e=hoe(),_3e=Object.prototype,X3e=_3e.hasOwnProperty;function Z3e(t){if(!W3e(t))return V3e(t);var e=z3e(t),r=[];for(var i in t)i=="constructor"&&(e||!X3e.call(t,i))||r.push(i);return r}poe.exports=Z3e});var lf=E((Wmt,Coe)=>{var $3e=bF(),eWe=doe(),tWe=Hd();function rWe(t){return tWe(t)?$3e(t,!0):eWe(t)}Coe.exports=rWe});var Eoe=E((zmt,moe)=>{var iWe=Af(),nWe=lf();function sWe(t,e){return t&&iWe(e,nWe(e),t)}moe.exports=sWe});var UN=E((hC,cf)=>{var oWe=Ks(),Ioe=typeof hC=="object"&&hC&&!hC.nodeType&&hC,yoe=Ioe&&typeof cf=="object"&&cf&&!cf.nodeType&&cf,aWe=yoe&&yoe.exports===Ioe,woe=aWe?oWe.Buffer:void 0,Boe=woe?woe.allocUnsafe:void 0;function AWe(t,e){if(e)return t.slice();var r=t.length,i=Boe?Boe(r):new t.constructor(r);return t.copy(i),i}cf.exports=AWe});var HN=E((Vmt,Qoe)=>{function lWe(t,e){var r=-1,i=t.length;for(e||(e=Array(i));++r{var cWe=Af(),uWe=f0();function gWe(t,e){return cWe(t,uWe(t),e)}boe.exports=gWe});var H0=E((Xmt,Soe)=>{var fWe=vF(),hWe=fWe(Object.getPrototypeOf,Object);Soe.exports=hWe});var GN=E((Zmt,xoe)=>{var pWe=$B(),dWe=H0(),CWe=f0(),mWe=RF(),EWe=Object.getOwnPropertySymbols,IWe=EWe?function(t){for(var e=[];t;)pWe(e,CWe(t)),t=dWe(t);return e}:mWe;xoe.exports=IWe});var Poe=E(($mt,koe)=>{var yWe=Af(),wWe=GN();function BWe(t,e){return yWe(t,wWe(t),e)}koe.exports=BWe});var Roe=E((eEt,Doe)=>{var QWe=DF(),bWe=GN(),vWe=lf();function SWe(t){return QWe(t,vWe,bWe)}Doe.exports=SWe});var Noe=E((tEt,Foe)=>{var xWe=Object.prototype,kWe=xWe.hasOwnProperty;function PWe(t){var e=t.length,r=new t.constructor(e);return e&&typeof t[0]=="string"&&kWe.call(t,"index")&&(r.index=t.index,r.input=t.input),r}Foe.exports=PWe});var G0=E((rEt,Loe)=>{var Toe=kF();function DWe(t){var e=new t.constructor(t.byteLength);return new Toe(e).set(new Toe(t)),e}Loe.exports=DWe});var Ooe=E((iEt,Moe)=>{var RWe=G0();function FWe(t,e){var r=e?RWe(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}Moe.exports=FWe});var Uoe=E((nEt,Koe)=>{var NWe=/\w*$/;function LWe(t){var e=new t.constructor(t.source,NWe.exec(t));return e.lastIndex=t.lastIndex,e}Koe.exports=LWe});var qoe=E((sEt,Hoe)=>{var Goe=ac(),joe=Goe?Goe.prototype:void 0,Yoe=joe?joe.valueOf:void 0;function TWe(t){return Yoe?Object(Yoe.call(t)):{}}Hoe.exports=TWe});var jN=E((oEt,Joe)=>{var MWe=G0();function OWe(t,e){var r=e?MWe(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}Joe.exports=OWe});var zoe=E((aEt,Woe)=>{var KWe=G0(),UWe=Ooe(),HWe=Uoe(),GWe=qoe(),jWe=jN(),YWe="[object Boolean]",qWe="[object Date]",JWe="[object Map]",WWe="[object Number]",zWe="[object RegExp]",VWe="[object Set]",_We="[object String]",XWe="[object Symbol]",ZWe="[object ArrayBuffer]",$We="[object DataView]",e8e="[object Float32Array]",t8e="[object Float64Array]",r8e="[object Int8Array]",i8e="[object Int16Array]",n8e="[object Int32Array]",s8e="[object Uint8Array]",o8e="[object Uint8ClampedArray]",a8e="[object Uint16Array]",A8e="[object Uint32Array]";function l8e(t,e,r){var i=t.constructor;switch(e){case ZWe:return KWe(t);case YWe:case qWe:return new i(+t);case $We:return UWe(t,r);case e8e:case t8e:case r8e:case i8e:case n8e:case s8e:case o8e:case a8e:case A8e:return jWe(t,r);case JWe:return new i;case WWe:case _We:return new i(t);case zWe:return HWe(t);case VWe:return new i;case XWe:return GWe(t)}}Woe.exports=l8e});var Xoe=E((AEt,Voe)=>{var c8e=Gs(),_oe=Object.create,u8e=function(){function t(){}return function(e){if(!c8e(e))return{};if(_oe)return _oe(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}}();Voe.exports=u8e});var YN=E((lEt,Zoe)=>{var g8e=Xoe(),f8e=H0(),h8e=u0();function p8e(t){return typeof t.constructor=="function"&&!h8e(t)?g8e(f8e(t)):{}}Zoe.exports=p8e});var eae=E((cEt,$oe)=>{var d8e=jd(),C8e=Qo(),m8e="[object Map]";function E8e(t){return C8e(t)&&d8e(t)==m8e}$oe.exports=E8e});var nae=E((uEt,tae)=>{var I8e=eae(),y8e=A0(),rae=l0(),iae=rae&&rae.isMap,w8e=iae?y8e(iae):I8e;tae.exports=w8e});var oae=E((gEt,sae)=>{var B8e=jd(),Q8e=Qo(),b8e="[object Set]";function v8e(t){return Q8e(t)&&B8e(t)==b8e}sae.exports=v8e});var cae=E((fEt,aae)=>{var S8e=oae(),x8e=A0(),Aae=l0(),lae=Aae&&Aae.isSet,k8e=lae?x8e(lae):S8e;aae.exports=k8e});var pae=E((hEt,uae)=>{var P8e=Gd(),D8e=loe(),R8e=XB(),F8e=goe(),N8e=Eoe(),L8e=UN(),T8e=HN(),M8e=voe(),O8e=Poe(),K8e=FF(),U8e=Roe(),H8e=jd(),G8e=Noe(),j8e=zoe(),Y8e=YN(),q8e=As(),J8e=Od(),W8e=nae(),z8e=Gs(),V8e=cae(),_8e=zg(),X8e=lf(),Z8e=1,$8e=2,e4e=4,gae="[object Arguments]",t4e="[object Array]",r4e="[object Boolean]",i4e="[object Date]",n4e="[object Error]",fae="[object Function]",s4e="[object GeneratorFunction]",o4e="[object Map]",a4e="[object Number]",hae="[object Object]",A4e="[object RegExp]",l4e="[object Set]",c4e="[object String]",u4e="[object Symbol]",g4e="[object WeakMap]",f4e="[object ArrayBuffer]",h4e="[object DataView]",p4e="[object Float32Array]",d4e="[object Float64Array]",C4e="[object Int8Array]",m4e="[object Int16Array]",E4e="[object Int32Array]",I4e="[object Uint8Array]",y4e="[object Uint8ClampedArray]",w4e="[object Uint16Array]",B4e="[object Uint32Array]",rr={};rr[gae]=rr[t4e]=rr[f4e]=rr[h4e]=rr[r4e]=rr[i4e]=rr[p4e]=rr[d4e]=rr[C4e]=rr[m4e]=rr[E4e]=rr[o4e]=rr[a4e]=rr[hae]=rr[A4e]=rr[l4e]=rr[c4e]=rr[u4e]=rr[I4e]=rr[y4e]=rr[w4e]=rr[B4e]=!0;rr[n4e]=rr[fae]=rr[g4e]=!1;function j0(t,e,r,i,n,s){var o,a=e&Z8e,l=e&$8e,c=e&e4e;if(r&&(o=n?r(t,i,n,s):r(t)),o!==void 0)return o;if(!z8e(t))return t;var u=q8e(t);if(u){if(o=G8e(t),!a)return T8e(t,o)}else{var g=H8e(t),f=g==fae||g==s4e;if(J8e(t))return L8e(t,a);if(g==hae||g==gae||f&&!n){if(o=l||f?{}:Y8e(t),!a)return l?O8e(t,N8e(o,t)):M8e(t,F8e(o,t))}else{if(!rr[g])return n?t:{};o=j8e(t,g,a)}}s||(s=new P8e);var h=s.get(t);if(h)return h;s.set(t,o),V8e(t)?t.forEach(function(m){o.add(j0(m,e,r,m,t,s))}):W8e(t)&&t.forEach(function(m,I){o.set(I,j0(m,e,r,I,t,s))});var p=c?l?U8e:K8e:l?X8e:_8e,d=u?void 0:p(t);return D8e(d||t,function(m,I){d&&(I=m,m=t[I]),R8e(o,I,j0(m,e,r,I,t,s))}),o}uae.exports=j0});var qN=E((pEt,dae)=>{var Q4e=pae(),b4e=1,v4e=4;function S4e(t){return Q4e(t,b4e|v4e)}dae.exports=S4e});var mae=E((dEt,Cae)=>{var x4e=tF();function k4e(t,e,r){return t==null?t:x4e(t,e,r)}Cae.exports=k4e});var Qae=E((wEt,Bae)=>{function P4e(t){var e=t==null?0:t.length;return e?t[e-1]:void 0}Bae.exports=P4e});var vae=E((BEt,bae)=>{var D4e=xd(),R4e=zP();function F4e(t,e){return e.length<2?t:D4e(t,R4e(e,0,-1))}bae.exports=F4e});var xae=E((QEt,Sae)=>{var N4e=Gg(),L4e=Qae(),T4e=vae(),M4e=Sc();function O4e(t,e){return e=N4e(e,t),t=T4e(t,e),t==null||delete t[M4e(L4e(e))]}Sae.exports=O4e});var Pae=E((bEt,kae)=>{var K4e=xae();function U4e(t,e){return t==null?!0:K4e(t,e)}kae.exports=U4e});var Kae=E((tIt,Oae)=>{Oae.exports={name:"@yarnpkg/cli",version:"3.1.1",license:"BSD-2-Clause",main:"./sources/index.ts",dependencies:{"@yarnpkg/core":"workspace:^","@yarnpkg/fslib":"workspace:^","@yarnpkg/libzip":"workspace:^","@yarnpkg/parsers":"workspace:^","@yarnpkg/plugin-compat":"workspace:^","@yarnpkg/plugin-dlx":"workspace:^","@yarnpkg/plugin-essentials":"workspace:^","@yarnpkg/plugin-file":"workspace:^","@yarnpkg/plugin-git":"workspace:^","@yarnpkg/plugin-github":"workspace:^","@yarnpkg/plugin-http":"workspace:^","@yarnpkg/plugin-init":"workspace:^","@yarnpkg/plugin-link":"workspace:^","@yarnpkg/plugin-nm":"workspace:^","@yarnpkg/plugin-npm":"workspace:^","@yarnpkg/plugin-npm-cli":"workspace:^","@yarnpkg/plugin-pack":"workspace:^","@yarnpkg/plugin-patch":"workspace:^","@yarnpkg/plugin-pnp":"workspace:^","@yarnpkg/plugin-pnpm":"workspace:^","@yarnpkg/shell":"workspace:^",chalk:"^3.0.0","ci-info":"^3.2.0",clipanion:"^3.0.1",semver:"^7.1.2",tslib:"^1.13.0",typanion:"^3.3.0",yup:"^0.32.9"},devDependencies:{"@types/semver":"^7.1.0","@types/yup":"^0","@yarnpkg/builder":"workspace:^","@yarnpkg/monorepo":"workspace:^","@yarnpkg/pnpify":"workspace:^",micromatch:"^4.0.2",typescript:"^4.5.2"},peerDependencies:{"@yarnpkg/core":"workspace:^"},scripts:{postpack:"rm -rf lib",prepack:'run build:compile "$(pwd)"',"build:cli+hook":"run build:pnp:hook && builder build bundle","build:cli":"builder build bundle","run:cli":"builder run","update-local":"run build:cli --no-git-hash && rsync -a --delete bundles/ bin/"},publishConfig:{main:"./lib/index.js",types:"./lib/index.d.ts",bin:null},files:["/lib/**/*","!/lib/pluginConfiguration.*","!/lib/cli.*"],"@yarnpkg/builder":{bundles:{standard:["@yarnpkg/plugin-essentials","@yarnpkg/plugin-compat","@yarnpkg/plugin-dlx","@yarnpkg/plugin-file","@yarnpkg/plugin-git","@yarnpkg/plugin-github","@yarnpkg/plugin-http","@yarnpkg/plugin-init","@yarnpkg/plugin-link","@yarnpkg/plugin-nm","@yarnpkg/plugin-npm","@yarnpkg/plugin-npm-cli","@yarnpkg/plugin-pack","@yarnpkg/plugin-patch","@yarnpkg/plugin-pnp","@yarnpkg/plugin-pnpm"]}},repository:{type:"git",url:"ssh://git@github.com/yarnpkg/berry.git",directory:"packages/yarnpkg-cli"},engines:{node:">=12 <14 || 14.2 - 14.9 || >14.10.0"}}});var iL=E((SBt,QAe)=>{"use strict";QAe.exports=function(e,r){r===!0&&(r=0);var i=e.indexOf("://"),n=e.substring(0,i).split("+").filter(Boolean);return typeof r=="number"?n[r]:n}});var nL=E((xBt,bAe)=>{"use strict";var sze=iL();function vAe(t){if(Array.isArray(t))return t.indexOf("ssh")!==-1||t.indexOf("rsync")!==-1;if(typeof t!="string")return!1;var e=sze(t);return t=t.substring(t.indexOf("://")+3),vAe(e)?!0:t.indexOf("@"){"use strict";var oze=iL(),aze=nL(),Aze=require("querystring");function lze(t){t=(t||"").trim();var e={protocols:oze(t),protocol:null,port:null,resource:"",user:"",pathname:"",hash:"",search:"",href:t,query:Object.create(null)},r=t.indexOf("://"),i=-1,n=null,s=null;t.startsWith(".")&&(t.startsWith("./")&&(t=t.substring(2)),e.pathname=t,e.protocol="file");var o=t.charAt(1);return e.protocol||(e.protocol=e.protocols[0],e.protocol||(aze(t)?e.protocol="ssh":((o==="/"||o==="~")&&(t=t.substring(2)),e.protocol="file"))),r!==-1&&(t=t.substring(r+3)),s=t.split("/"),e.protocol!=="file"?e.resource=s.shift():e.resource="",n=e.resource.split("@"),n.length===2&&(e.user=n[0],e.resource=n[1]),n=e.resource.split(":"),n.length===2&&(e.resource=n[0],n[1]?(e.port=Number(n[1]),isNaN(e.port)&&(e.port=null,s.unshift(n[1]))):e.port=null),s=s.filter(Boolean),e.protocol==="file"?e.pathname=e.href:e.pathname=e.pathname||(e.protocol!=="file"||e.href[0]==="/"?"/":"")+s.join("/"),n=e.pathname.split("#"),n.length===2&&(e.pathname=n[0],e.hash=n[1]),n=e.pathname.split("?"),n.length===2&&(e.pathname=n[0],e.search=n[1]),e.query=Aze.parse(e.search),e.href=e.href.replace(/\/$/,""),e.pathname=e.pathname.replace(/\/$/,""),e}SAe.exports=lze});var DAe=E((PBt,kAe)=>{"use strict";var cze=typeof URL=="undefined"?require("url").URL:URL,PAe=(t,e)=>e.some(r=>r instanceof RegExp?r.test(t):r===t);kAe.exports=(t,e)=>{e=Object.assign({defaultProtocol:"http:",normalizeProtocol:!0,forceHttp:!1,forceHttps:!1,stripHash:!0,stripWWW:!0,removeQueryParameters:[/^utm_\w+/i],removeTrailingSlash:!0,removeDirectoryIndex:!1,sortQueryParameters:!0},e),Reflect.has(e,"normalizeHttps")&&(e.forceHttp=e.normalizeHttps),Reflect.has(e,"normalizeHttp")&&(e.forceHttps=e.normalizeHttp),Reflect.has(e,"stripFragment")&&(e.stripHash=e.stripFragment),t=t.trim();let r=t.startsWith("//");!r&&/^\.*\//.test(t)||(t=t.replace(/^(?!(?:\w+:)?\/\/)|^\/\//,e.defaultProtocol));let n=new cze(t);if(e.forceHttp&&e.forceHttps)throw new Error("The `forceHttp` and `forceHttps` options cannot be used together");if(e.forceHttp&&n.protocol==="https:"&&(n.protocol="http:"),e.forceHttps&&n.protocol==="http:"&&(n.protocol="https:"),e.stripHash&&(n.hash=""),n.pathname&&(n.pathname=n.pathname.replace(/((?![https?:]).)\/{2,}/g,(s,o)=>/^(?!\/)/g.test(o)?`${o}/`:"/")),n.pathname&&(n.pathname=decodeURI(n.pathname)),e.removeDirectoryIndex===!0&&(e.removeDirectoryIndex=[/^index\.[a-z]+$/]),Array.isArray(e.removeDirectoryIndex)&&e.removeDirectoryIndex.length>0){let s=n.pathname.split("/"),o=s[s.length-1];PAe(o,e.removeDirectoryIndex)&&(s=s.slice(0,s.length-1),n.pathname=s.slice(1).join("/")+"/")}if(n.hostname&&(n.hostname=n.hostname.replace(/\.$/,""),e.stripWWW&&/^www\.([a-z\-\d]{2,63})\.([a-z\.]{2,5})$/.test(n.hostname)&&(n.hostname=n.hostname.replace(/^www\./,""))),Array.isArray(e.removeQueryParameters))for(let s of[...n.searchParams.keys()])PAe(s,e.removeQueryParameters)&&n.searchParams.delete(s);return e.sortQueryParameters&&n.searchParams.sort(),t=n.toString(),(e.removeTrailingSlash||n.pathname==="/")&&(t=t.replace(/\/$/,"")),r&&!e.normalizeProtocol&&(t=t.replace(/^http:\/\//,"//")),t}});var FAe=E((DBt,RAe)=>{"use strict";var uze=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},gze=xAe(),fze=DAe();function hze(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(typeof t!="string"||!t.trim())throw new Error("Invalid url.");e&&((typeof e=="undefined"?"undefined":uze(e))!=="object"&&(e={stripFragment:!1}),t=fze(t,e));var r=gze(t);return r}RAe.exports=hze});var TAe=E((RBt,NAe)=>{"use strict";var pze=FAe(),LAe=nL();function dze(t){var e=pze(t);e.token="";var r=e.user.split(":");return r.length===2&&(r[1]==="x-oauth-basic"?e.token=r[0]:r[0]==="x-token-auth"&&(e.token=r[1])),LAe(e.protocols)||LAe(t)?e.protocol="ssh":e.protocols.length?e.protocol=e.protocols[0]:e.protocol="file",e.href=e.href.replace(/\/$/,""),e}NAe.exports=dze});var OAe=E((FBt,MAe)=>{"use strict";var Cze=TAe();function sL(t){if(typeof t!="string")throw new Error("The url must be a string.");var e=Cze(t),r=e.resource.split("."),i=null;switch(e.toString=function(l){return sL.stringify(this,l)},e.source=r.length>2?r.slice(1-r.length).join("."):e.source=e.resource,e.git_suffix=/\.git$/.test(e.pathname),e.name=decodeURIComponent(e.pathname.replace(/^\//,"").replace(/\.git$/,"")),e.owner=decodeURIComponent(e.user),e.source){case"git.cloudforge.com":e.owner=e.user,e.organization=r[0],e.source="cloudforge.com";break;case"visualstudio.com":if(e.resource==="vs-ssh.visualstudio.com"){i=e.name.split("/"),i.length===4&&(e.organization=i[1],e.owner=i[2],e.name=i[3],e.full_name=i[2]+"/"+i[3]);break}else{i=e.name.split("/"),i.length===2?(e.owner=i[1],e.name=i[1],e.full_name="_git/"+e.name):i.length===3?(e.name=i[2],i[0]==="DefaultCollection"?(e.owner=i[2],e.organization=i[0],e.full_name=e.organization+"/_git/"+e.name):(e.owner=i[0],e.full_name=e.owner+"/_git/"+e.name)):i.length===4&&(e.organization=i[0],e.owner=i[1],e.name=i[3],e.full_name=e.organization+"/"+e.owner+"/_git/"+e.name);break}case"dev.azure.com":case"azure.com":if(e.resource==="ssh.dev.azure.com"){i=e.name.split("/"),i.length===4&&(e.organization=i[1],e.owner=i[2],e.name=i[3]);break}else{i=e.name.split("/"),i.length===5?(e.organization=i[0],e.owner=i[1],e.name=i[4],e.full_name="_git/"+e.name):i.length===3?(e.name=i[2],i[0]==="DefaultCollection"?(e.owner=i[2],e.organization=i[0],e.full_name=e.organization+"/_git/"+e.name):(e.owner=i[0],e.full_name=e.owner+"/_git/"+e.name)):i.length===4&&(e.organization=i[0],e.owner=i[1],e.name=i[3],e.full_name=e.organization+"/"+e.owner+"/_git/"+e.name);break}default:i=e.name.split("/");var n=i.length-1;if(i.length>=2){var s=i.indexOf("blob",2),o=i.indexOf("tree",2),a=i.indexOf("commit",2);n=s>0?s-1:o>0?o-1:a>0?a-1:n,e.owner=i.slice(0,n).join("/"),e.name=i[n],a&&(e.commit=i[n+2])}e.ref="",e.filepathtype="",e.filepath="",i.length>n+2&&["blob","tree"].indexOf(i[n+1])>=0&&(e.filepathtype=i[n+1],e.ref=i[n+2],i.length>n+3&&(e.filepath=i.slice(n+3).join("/"))),e.organization=e.owner;break}return e.full_name||(e.full_name=e.owner,e.name&&(e.full_name&&(e.full_name+="/"),e.full_name+=e.name)),e}sL.stringify=function(t,e){e=e||(t.protocols&&t.protocols.length?t.protocols.join("+"):t.protocol);var r=t.port?":"+t.port:"",i=t.user||"git",n=t.git_suffix?".git":"";switch(e){case"ssh":return r?"ssh://"+i+"@"+t.resource+r+"/"+t.full_name+n:i+"@"+t.resource+":"+t.full_name+n;case"git+ssh":case"ssh+git":case"ftp":case"ftps":return e+"://"+i+"@"+t.resource+r+"/"+t.full_name+n;case"http":case"https":var s=t.token?mze(t):t.user&&(t.protocols.includes("http")||t.protocols.includes("https"))?t.user+"@":"";return e+"://"+s+t.resource+r+"/"+t.full_name+n;default:return t.href}};function mze(t){switch(t.source){case"bitbucket.org":return"x-token-auth:"+t.token+"@";default:return t.token+"@"}}MAe.exports=sL});var NL=E((Obt,ole)=>{var Mze=jg(),Oze=Kg();function Kze(t,e,r){(r!==void 0&&!Oze(t[e],r)||r===void 0&&!(e in t))&&Mze(t,e,r)}ole.exports=Kze});var Ale=E((Kbt,ale)=>{var Uze=Hd(),Hze=Qo();function Gze(t){return Hze(t)&&Uze(t)}ale.exports=Gze});var ule=E((Ubt,lle)=>{var jze=Ac(),Yze=H0(),qze=Qo(),Jze="[object Object]",Wze=Function.prototype,zze=Object.prototype,cle=Wze.toString,Vze=zze.hasOwnProperty,_ze=cle.call(Object);function Xze(t){if(!qze(t)||jze(t)!=Jze)return!1;var e=Yze(t);if(e===null)return!0;var r=Vze.call(e,"constructor")&&e.constructor;return typeof r=="function"&&r instanceof r&&cle.call(r)==_ze}lle.exports=Xze});var LL=E((Hbt,gle)=>{function Zze(t,e){if(!(e==="constructor"&&typeof t[e]=="function")&&e!="__proto__")return t[e]}gle.exports=Zze});var hle=E((Gbt,fle)=>{var $ze=Af(),e5e=lf();function t5e(t){return $ze(t,e5e(t))}fle.exports=t5e});var Ile=E((jbt,ple)=>{var dle=NL(),r5e=UN(),i5e=jN(),n5e=HN(),s5e=YN(),Cle=Pd(),mle=As(),o5e=Ale(),a5e=Od(),A5e=zB(),l5e=Gs(),c5e=ule(),u5e=c0(),Ele=LL(),g5e=hle();function f5e(t,e,r,i,n,s,o){var a=Ele(t,r),l=Ele(e,r),c=o.get(l);if(c){dle(t,r,c);return}var u=s?s(a,l,r+"",t,e,o):void 0,g=u===void 0;if(g){var f=mle(l),h=!f&&a5e(l),p=!f&&!h&&u5e(l);u=l,f||h||p?mle(a)?u=a:o5e(a)?u=n5e(a):h?(g=!1,u=r5e(l,!0)):p?(g=!1,u=i5e(l,!0)):u=[]:c5e(l)||Cle(l)?(u=a,Cle(a)?u=g5e(a):(!l5e(a)||A5e(a))&&(u=s5e(l))):g=!1}g&&(o.set(l,u),n(u,l,i,s,o),o.delete(l)),dle(t,r,u)}ple.exports=f5e});var Ble=E((Ybt,yle)=>{var h5e=Gd(),p5e=NL(),d5e=BF(),C5e=Ile(),m5e=Gs(),E5e=lf(),I5e=LL();function wle(t,e,r,i,n){t!==e&&d5e(e,function(s,o){if(n||(n=new h5e),m5e(s))C5e(t,e,o,r,wle,i,n);else{var a=i?i(I5e(t,o),s,o+"",t,e,n):void 0;a===void 0&&(a=s),p5e(t,o,a)}},E5e)}yle.exports=wle});var ble=E((qbt,Qle)=>{var y5e=e0(),w5e=nF(),B5e=sF();function Q5e(t,e){return B5e(w5e(t,e,y5e),t+"")}Qle.exports=Q5e});var Sle=E((Jbt,vle)=>{var b5e=Kg(),v5e=Hd(),S5e=kd(),x5e=Gs();function k5e(t,e,r){if(!x5e(r))return!1;var i=typeof e;return(i=="number"?v5e(r)&&S5e(e,r.length):i=="string"&&e in r)?b5e(r[e],t):!1}vle.exports=k5e});var kle=E((Wbt,xle)=>{var P5e=ble(),D5e=Sle();function R5e(t){return P5e(function(e,r){var i=-1,n=r.length,s=n>1?r[n-1]:void 0,o=n>2?r[2]:void 0;for(s=t.length>3&&typeof s=="function"?(n--,s):void 0,o&&D5e(r[0],r[1],o)&&(s=n<3?void 0:s,n=1),e=Object(e);++i{var F5e=Ble(),N5e=kle(),L5e=N5e(function(t,e,r){F5e(t,e,r)});Ple.exports=L5e});var Wle=E(($vt,Jle)=>{var VL;Jle.exports=()=>(typeof VL=="undefined"&&(VL=require("zlib").brotliDecompressSync(Buffer.from("WxSteIBtDGp/1Rsko1+37VeQEmWILAWus2NIX9GQfXTamdxQ3DAVQZm/czI4dZrL7m2taiqoqpqbVIbMBngCLTBU/Z3f9icopIlQyRwSW0LmAd1xJBp0KShTakLvhLqFls9ECISbkeazt+a3Oz6WDcIQ0rgyHJrpCa+V4cmVQ2z4oM2JfN4j+7vMT96CNwkkkPaSsvdW3AmkfVxAApnLX5aOBjpOc3P7TNjG17v+MIABlUDmOqzCLLLbv11H5fHeze26jjOpgJE6N40WFR11m5pRVZE27TUgwrj1KxBDRB2mWGZPkat662N5RXbtr37ttfl5OkO+WOsjtp6CdnBKLX6mPgUXYbPeQnK4HXKv21cNTTU/x/thkJk1y4lIlXAEX2X5tnKBomsuEuC/3L/Kl6Djv67fzqYtzB3ZIfxZGZV/UVGEKpxXKOofHL63VOt0JTRRECeeZkOI2lsusUvit9l8Rgd4KcD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eUKk3oXWSe30Z+mFkUrj65mhkdvFhQaP9qMIp2oFdWalk5gL4+m91OP1Kb2yg8kdmqj59aWw8Ecg+rGnS4Jm6SyswobqNOwiI8l3JiwHeUldFRrJJmeeIsj1bOp60lbwGFo+G7mcxq4uxrMuTNIE4D9wxL+XqS1PjqwUH0Sl53JwLb53lflHwWW+UifWrwfAEWJk/TdOnxk3oO3S2uxHIFovxx5nNGnBqITh3xcuEvLz+9FJbwlRKwz2kasmk/Q1bOYL7yOheR14xB4Hrj/o24KyTaT2oTB/zvNN+kBS0c0az5+Dwc3QqW8kb/v/g494aJXZU+ikv4Bt/efbwreM5DURtjLGLuPh8Mr8Y/pukoIvINsj+o6xGobt3MCJ1CMpFYvaQfEUCkAHHdKG2naXUQ91xouSsiGQmrb9bxYFfwcQ6iCxx+IwM7dlGHgZnhxtXr4z3Lga/x7zBJquMwXS4wdx4HswKGpHqPPvG0RYhMrOUfs6U/riWRF8MO21wqvGKSO1Xkk08HfxaQb9B69clyEorTUG1uyyVBfsRqmltf4CCwx/TYvXe/zB3P9aIr6dyzXufkNPl4Uc/XdUDjrCywVM9Nn0Zn9VNZu+89x71cA+cgC1yXlCZremcn+D9wJZz+4v3j3/9KEqul87dklTfICvP4J/tkKSYAkp6S2/qidd8o1EXNSraYXIZ+UN9HAMg9ezqYizSLSrkVKC4HZ+JfExqOVGA7xLxxd97aN4YoNmCpcmk2o3CPoNTbJl6HSQHJaIVhyMGBVSGTANcrmCfvo754uZcA+lavfki67M584Fn1L5bcwncusGNdCe2OqVzreua1K0pRsJ3z8W5aOrhR7Ra+7qEXhdAw=","base64")).toString()),VL)});var $le=E(XL=>{function pf(t,e){if(typeof t=="string")return t;if(t){let r,i;if(Array.isArray(t)){for(r=0;r0)return(f=pf(n[g],u))?f.replace("*",c.substring(g.length-1)):Gc(i,c,1)}return Gc(i,c)}}function l6e(t,e={}){let r=0,i,n=e.browser,s=e.fields||["module","main"];for(n&&!s.includes("browser")&&s.unshift("browser");r{var eT;nce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7QgeDoNUJs6WBjulWCLnS29IwW3qVVJ9anKKqokl94u/gvCpDMtwqH61i1g/zIK7qtZEzOYKjaiktuVO40kvz0vWoM3YaQm79KqmRf1q/BNHghpvQCDCJ4iz1ak/K/ks+edjG5ipd81BCGdq5QJLHvrJZK2WYvhOoiYKXnolnv1UN5++EqZpRXJCKPLrVMFKpl5hB6b0je+Oms3eSFyxbAOE3pIjqCg6UvCi/QVKYVv8YZ0RABb9rmNFmEOr7t1Fk11d24+zCS9gc5CVTclE909oExrTXHhBS0x3CP4TJ59GTvih5K5coxfcUy58EzjWFkWMDfdSjlq59pFEU7iIpD7HbtgufaEpv5we7xKwhb3XC5SbMkm5FcW2oLW5RobgTRFrsy1KawVNedhCvjvvp5cjw73QRgOlteW15dWl9e9oIMOi3dxzqO60K7MyX6eMo3Odhn2NUyd/Q8Bap7MljyFWW7ksXB/jSGuAVHarS0CEQRKhDC7oPaqzCFfpsdCy0pV+8HcxINa7qGHHyoyq8v7VrX0YQqg8iaeZl8sGD2r0TEr+1Wj4x0bmZ6WUHSr2bx3/PGu5d/zsmmxKglKna2lnstwta3+nqyEhQZBe4QKV+1KkZp5HS1l75WuhJZuvd9bmt6KHrwf2f7kE8iR8s+oImRLwXVi6Fum4EeYQb9lUh8LyKgqe9A/FpksPVbqXYPY7G3ansEqdF3IClEzzIKkmQubjcGQlnUTOq9KF1u98uogWAaJ3eBDErzN3rzz0Y5UGZggNlcV6uBKsdqrl1VeAq04LUyMnCENsPVETgA=","base64")).toString()),eT)});var gce=E((aT,AT)=>{(function(t){aT&&typeof aT=="object"&&typeof AT!="undefined"?AT.exports=t():typeof define=="function"&&define.amd?define([],t):typeof window!="undefined"?window.isWindows=t():typeof global!="undefined"?global.isWindows=t():typeof self!="undefined"?self.isWindows=t():this.isWindows=t()})(function(){"use strict";return function(){return process&&(process.platform==="win32"||/^(msys|cygwin)$/.test(process.env.OSTYPE))}})});var dce=E((Dxt,fce)=>{"use strict";lT.ifExists=E6e;var mf=require("util"),Es=require("path"),hce=gce(),I6e=/^#!\s*(?:\/usr\/bin\/env)?\s*([^ \t]+)(.*)$/,y6e={createPwshFile:!0,createCmdFile:hce(),fs:require("fs")},w6e=new Map([[".js","node"],[".cjs","node"],[".mjs","node"],[".cmd","cmd"],[".bat","cmd"],[".ps1","pwsh"],[".sh","sh"]]);function pce(t){let e=P(P({},y6e),t),r=e.fs;return e.fs_={chmod:r.chmod?mf.promisify(r.chmod):async()=>{},mkdir:mf.promisify(r.mkdir),readFile:mf.promisify(r.readFile),stat:mf.promisify(r.stat),unlink:mf.promisify(r.unlink),writeFile:mf.promisify(r.writeFile)},e}async function lT(t,e,r){let i=pce(r);await i.fs_.stat(t),await B6e(t,e,i)}function E6e(t,e,r){return lT(t,e,r).catch(()=>{})}function Q6e(t,e){return e.fs_.unlink(t).catch(()=>{})}async function B6e(t,e,r){let i=await S6e(t,r);return await b6e(e,r),v6e(t,e,i,r)}function b6e(t,e){return e.fs_.mkdir(Es.dirname(t),{recursive:!0})}function v6e(t,e,r,i){let n=pce(i),s=[{generator:P6e,extension:""}];return n.createCmdFile&&s.push({generator:k6e,extension:".cmd"}),n.createPwshFile&&s.push({generator:D6e,extension:".ps1"}),Promise.all(s.map(o=>x6e(t,e+o.extension,r,o.generator,n)))}function R6e(t,e){return Q6e(t,e)}function N6e(t,e){return F6e(t,e)}async function S6e(t,e){let n=(await e.fs_.readFile(t,"utf8")).trim().split(/\r*\n/)[0].match(I6e);if(!n){let s=Es.extname(t).toLowerCase();return{program:w6e.get(s)||null,additionalArgs:""}}return{program:n[1],additionalArgs:n[2]}}async function x6e(t,e,r,i,n){let s=n.preserveSymlinks?"--preserve-symlinks":"",o=[r.additionalArgs,s].filter(a=>a).join(" ");return n=Object.assign({},n,{prog:r.program,args:o}),await R6e(e,n),await n.fs_.writeFile(e,i(t,e,n),"utf8"),N6e(e,n)}function k6e(t,e,r){let n=Es.relative(Es.dirname(e),t).split("/").join("\\"),s=Es.isAbsolute(n)?`"${n}"`:`"%~dp0\\${n}"`,o,a=r.prog,l=r.args||"",c=cT(r.nodePath).win32;a?(o=`"%~dp0\\${a}.exe"`,n=s):(a=s,l="",n="");let u=r.progArgs?`${r.progArgs.join(" ")} `:"",g=c?`@SET NODE_PATH=${c}\r -`:"";return o?g+=`@IF EXIST ${o} (\r - ${o} ${l} ${n} ${u}%*\r -) ELSE (\r - @SETLOCAL\r - @SET PATHEXT=%PATHEXT:;.JS;=;%\r - ${a} ${l} ${n} ${u}%*\r -)\r -`:g+=`@${a} ${l} ${n} ${u}%*\r -`,g}function P6e(t,e,r){let i=Es.relative(Es.dirname(e),t),n=r.prog&&r.prog.split("\\").join("/"),s;i=i.split("\\").join("/");let o=Es.isAbsolute(i)?`"${i}"`:`"$basedir/${i}"`,a=r.args||"",l=cT(r.nodePath).posix;n?(s=`"$basedir/${r.prog}"`,i=o):(n=o,a="",i="");let c=r.progArgs?`${r.progArgs.join(" ")} `:"",u=`#!/bin/sh -basedir=$(dirname "$(echo "$0" | sed -e 's,\\\\,/,g')") - -case \`uname\` in - *CYGWIN*) basedir=\`cygpath -w "$basedir"\`;; -esac - -`,g=r.nodePath?`export NODE_PATH="${l}" -`:"";return s?u+=`${g}if [ -x ${s} ]; then - exec ${s} ${a} ${i} ${c}"$@" -else - exec ${n} ${a} ${i} ${c}"$@" -fi -`:u+=`${g}${n} ${a} ${i} ${c}"$@" -exit $? -`,u}function D6e(t,e,r){let i=Es.relative(Es.dirname(e),t),n=r.prog&&r.prog.split("\\").join("/"),s=n&&`"${n}$exe"`,o;i=i.split("\\").join("/");let a=Es.isAbsolute(i)?`"${i}"`:`"$basedir/${i}"`,l=r.args||"",c=cT(r.nodePath),u=c.win32,g=c.posix;s?(o=`"$basedir/${r.prog}$exe"`,i=a):(s=a,l="",i="");let f=r.progArgs?`${r.progArgs.join(" ")} `:"",h=`#!/usr/bin/env pwsh -$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent - -$exe="" -${r.nodePath?`$env_node_path=$env:NODE_PATH -$env:NODE_PATH="${u}" -`:""}if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) { - # Fix case when both the Windows and Linux builds of Node - # are installed in the same directory - $exe=".exe" -}`;return r.nodePath&&(h+=` else { - $env:NODE_PATH="${g}" -}`),o?h+=` -$ret=0 -if (Test-Path ${o}) { - # Support pipeline input - if ($MyInvocation.ExpectingInput) { - $input | & ${o} ${l} ${i} ${f}$args - } else { - & ${o} ${l} ${i} ${f}$args - } - $ret=$LASTEXITCODE -} else { - # Support pipeline input - if ($MyInvocation.ExpectingInput) { - $input | & ${s} ${l} ${i} ${f}$args - } else { - & ${s} ${l} ${i} ${f}$args - } - $ret=$LASTEXITCODE -} -${r.nodePath?`$env:NODE_PATH=$env_node_path -`:""}exit $ret -`:h+=` -# Support pipeline input -if ($MyInvocation.ExpectingInput) { - $input | & ${s} ${l} ${i} ${f}$args -} else { - & ${s} ${l} ${i} ${f}$args -} -${r.nodePath?`$env:NODE_PATH=$env_node_path -`:""}exit $LASTEXITCODE -`,h}function F6e(t,e){return e.fs_.chmod(t,493)}function cT(t){if(!t)return{win32:"",posix:""};let e=typeof t=="string"?t.split(Es.delimiter):Array.from(t),r={};for(let i=0;i`/mnt/${a.toLowerCase()}`):e[i];r.win32=r.win32?`${r.win32};${n}`:n,r.posix=r.posix?`${r.posix}:${s}`:s,r[i]={win32:n,posix:s}}return r}fce.exports=lT});var PT=E((fPt,Nce)=>{Nce.exports=require("stream")});var Oce=E((hPt,Lce)=>{"use strict";function Tce(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),r.push.apply(r,i)}return r}function e9e(t){for(var e=1;e0?this.tail.next=i:this.head=i,this.tail=i,++this.length}},{key:"unshift",value:function(r){var i={data:r,next:this.head};this.length===0&&(this.tail=i),this.head=i,++this.length}},{key:"shift",value:function(){if(this.length!==0){var r=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,r}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(r){if(this.length===0)return"";for(var i=this.head,n=""+i.data;i=i.next;)n+=r+i.data;return n}},{key:"concat",value:function(r){if(this.length===0)return iQ.alloc(0);for(var i=iQ.allocUnsafe(r>>>0),n=this.head,s=0;n;)o9e(n.data,i,s),s+=n.data.length,n=n.next;return i}},{key:"consume",value:function(r,i){var n;return ro.length?o.length:r;if(a===o.length?s+=o:s+=o.slice(0,r),r-=a,r===0){a===o.length?(++n,i.next?this.head=i.next:this.head=this.tail=null):(this.head=i,i.data=o.slice(a));break}++n}return this.length-=n,s}},{key:"_getBuffer",value:function(r){var i=iQ.allocUnsafe(r),n=this.head,s=1;for(n.data.copy(i),r-=n.data.length;n=n.next;){var o=n.data,a=r>o.length?o.length:r;if(o.copy(i,i.length-r,0,a),r-=a,r===0){a===o.length?(++s,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=o.slice(a));break}++s}return this.length-=s,i}},{key:s9e,value:function(r,i){return DT(this,e9e({},i,{depth:0,customInspect:!1}))}}]),t}()});var FT=E((pPt,Kce)=>{"use strict";function a9e(t,e){var r=this,i=this._readableState&&this._readableState.destroyed,n=this._writableState&&this._writableState.destroyed;return i||n?(e?e(t):t&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(RT,this,t)):process.nextTick(RT,this,t)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,function(s){!e&&s?r._writableState?r._writableState.errorEmitted?process.nextTick(nQ,r):(r._writableState.errorEmitted=!0,process.nextTick(Uce,r,s)):process.nextTick(Uce,r,s):e?(process.nextTick(nQ,r),e(s)):process.nextTick(nQ,r)}),this)}function Uce(t,e){RT(t,e),nQ(t)}function nQ(t){t._writableState&&!t._writableState.emitClose||t._readableState&&!t._readableState.emitClose||t.emit("close")}function A9e(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function RT(t,e){t.emit("error",e)}function l9e(t,e){var r=t._readableState,i=t._writableState;r&&r.autoDestroy||i&&i.autoDestroy?t.destroy(e):t.emit("error",e)}Kce.exports={destroy:a9e,undestroy:A9e,errorOrDestroy:l9e}});var VA=E((dPt,Hce)=>{"use strict";var Gce={};function Is(t,e,r){r||(r=Error);function i(s,o,a){return typeof e=="string"?e:e(s,o,a)}class n extends r{constructor(o,a,l){super(i(o,a,l))}}n.prototype.name=r.name,n.prototype.code=t,Gce[t]=n}function jce(t,e){if(Array.isArray(t)){let r=t.length;return t=t.map(i=>String(i)),r>2?`one of ${e} ${t.slice(0,r-1).join(", ")}, or `+t[r-1]:r===2?`one of ${e} ${t[0]} or ${t[1]}`:`of ${e} ${t[0]}`}else return`of ${e} ${String(t)}`}function c9e(t,e,r){return t.substr(!r||r<0?0:+r,e.length)===e}function u9e(t,e,r){return(r===void 0||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}function g9e(t,e,r){return typeof r!="number"&&(r=0),r+e.length>t.length?!1:t.indexOf(e,r)!==-1}Is("ERR_INVALID_OPT_VALUE",function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'},TypeError);Is("ERR_INVALID_ARG_TYPE",function(t,e,r){let i;typeof e=="string"&&c9e(e,"not ")?(i="must not be",e=e.replace(/^not /,"")):i="must be";let n;if(u9e(t," argument"))n=`The ${t} ${i} ${jce(e,"type")}`;else{let s=g9e(t,".")?"property":"argument";n=`The "${t}" ${s} ${i} ${jce(e,"type")}`}return n+=`. Received type ${typeof r}`,n},TypeError);Is("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");Is("ERR_METHOD_NOT_IMPLEMENTED",function(t){return"The "+t+" method is not implemented"});Is("ERR_STREAM_PREMATURE_CLOSE","Premature close");Is("ERR_STREAM_DESTROYED",function(t){return"Cannot call "+t+" after a stream was destroyed"});Is("ERR_MULTIPLE_CALLBACK","Callback called multiple times");Is("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");Is("ERR_STREAM_WRITE_AFTER_END","write after end");Is("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);Is("ERR_UNKNOWN_ENCODING",function(t){return"Unknown encoding: "+t},TypeError);Is("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");Hce.exports.codes=Gce});var NT=E((CPt,Yce)=>{"use strict";var f9e=VA().codes.ERR_INVALID_OPT_VALUE;function h9e(t,e,r){return t.highWaterMark!=null?t.highWaterMark:e?t[r]:null}function p9e(t,e,r,i){var n=h9e(e,i,r);if(n!=null){if(!(isFinite(n)&&Math.floor(n)===n)||n<0){var s=i?r:"highWaterMark";throw new f9e(s,n)}return Math.floor(n)}return t.objectMode?16:16*1024}Yce.exports={getHighWaterMark:p9e}});var qce=E((mPt,LT)=>{typeof Object.create=="function"?LT.exports=function(e,r){r&&(e.super_=r,e.prototype=Object.create(r.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:LT.exports=function(e,r){if(r){e.super_=r;var i=function(){};i.prototype=r.prototype,e.prototype=new i,e.prototype.constructor=e}}});var _A=E((EPt,TT)=>{try{if(MT=require("util"),typeof MT.inherits!="function")throw"";TT.exports=MT.inherits}catch(t){TT.exports=qce()}var MT});var Wce=E((IPt,Jce)=>{Jce.exports=require("util").deprecate});var UT=E((yPt,zce)=>{"use strict";zce.exports=Sr;function Vce(t){var e=this;this.next=null,this.entry=null,this.finish=function(){d9e(e,t)}}var If;Sr.WritableState=em;var C9e={deprecate:Wce()},_ce=PT(),sQ=require("buffer").Buffer,m9e=global.Uint8Array||function(){};function E9e(t){return sQ.from(t)}function I9e(t){return sQ.isBuffer(t)||t instanceof m9e}var OT=FT(),y9e=NT(),w9e=y9e.getHighWaterMark,XA=VA().codes,B9e=XA.ERR_INVALID_ARG_TYPE,Q9e=XA.ERR_METHOD_NOT_IMPLEMENTED,b9e=XA.ERR_MULTIPLE_CALLBACK,v9e=XA.ERR_STREAM_CANNOT_PIPE,S9e=XA.ERR_STREAM_DESTROYED,x9e=XA.ERR_STREAM_NULL_VALUES,k9e=XA.ERR_STREAM_WRITE_AFTER_END,P9e=XA.ERR_UNKNOWN_ENCODING,yf=OT.errorOrDestroy;_A()(Sr,_ce);function D9e(){}function em(t,e,r){If=If||Yc(),t=t||{},typeof r!="boolean"&&(r=e instanceof If),this.objectMode=!!t.objectMode,r&&(this.objectMode=this.objectMode||!!t.writableObjectMode),this.highWaterMark=w9e(this,t,"writableHighWaterMark",r),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var i=t.decodeStrings===!1;this.decodeStrings=!i,this.defaultEncoding=t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(n){R9e(e,n)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=t.emitClose!==!1,this.autoDestroy=!!t.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new Vce(this)}em.prototype.getBuffer=function(){for(var e=this.bufferedRequest,r=[];e;)r.push(e),e=e.next;return r};(function(){try{Object.defineProperty(em.prototype,"buffer",{get:C9e.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(t){}})();var oQ;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(oQ=Function.prototype[Symbol.hasInstance],Object.defineProperty(Sr,Symbol.hasInstance,{value:function(e){return oQ.call(this,e)?!0:this!==Sr?!1:e&&e._writableState instanceof em}})):oQ=function(e){return e instanceof this};function Sr(t){If=If||Yc();var e=this instanceof If;if(!e&&!oQ.call(Sr,this))return new Sr(t);this._writableState=new em(t,this,e),this.writable=!0,t&&(typeof t.write=="function"&&(this._write=t.write),typeof t.writev=="function"&&(this._writev=t.writev),typeof t.destroy=="function"&&(this._destroy=t.destroy),typeof t.final=="function"&&(this._final=t.final)),_ce.call(this)}Sr.prototype.pipe=function(){yf(this,new v9e)};function F9e(t,e){var r=new k9e;yf(t,r),process.nextTick(e,r)}function N9e(t,e,r,i){var n;return r===null?n=new x9e:typeof r!="string"&&!e.objectMode&&(n=new B9e("chunk",["string","Buffer"],r)),n?(yf(t,n),process.nextTick(i,n),!1):!0}Sr.prototype.write=function(t,e,r){var i=this._writableState,n=!1,s=!i.objectMode&&I9e(t);return s&&!sQ.isBuffer(t)&&(t=E9e(t)),typeof e=="function"&&(r=e,e=null),s?e="buffer":e||(e=i.defaultEncoding),typeof r!="function"&&(r=D9e),i.ending?F9e(this,r):(s||N9e(this,i,t,r))&&(i.pendingcb++,n=L9e(this,i,s,t,e,r)),n};Sr.prototype.cork=function(){this._writableState.corked++};Sr.prototype.uncork=function(){var t=this._writableState;t.corked&&(t.corked--,!t.writing&&!t.corked&&!t.bufferProcessing&&t.bufferedRequest&&Xce(this,t))};Sr.prototype.setDefaultEncoding=function(e){if(typeof e=="string"&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new P9e(e);return this._writableState.defaultEncoding=e,this};Object.defineProperty(Sr.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function T9e(t,e,r){return!t.objectMode&&t.decodeStrings!==!1&&typeof e=="string"&&(e=sQ.from(e,r)),e}Object.defineProperty(Sr.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function L9e(t,e,r,i,n,s){if(!r){var o=T9e(e,i,n);i!==o&&(r=!0,n="buffer",i=o)}var a=e.objectMode?1:i.length;e.length+=a;var l=e.length{"use strict";var j9e=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};eue.exports=Mo;var tue=HT(),GT=UT();_A()(Mo,tue);for(jT=j9e(GT.prototype),aQ=0;aQ{var lQ=require("buffer"),qa=lQ.Buffer;function iue(t,e){for(var r in t)e[r]=t[r]}qa.from&&qa.alloc&&qa.allocUnsafe&&qa.allocUnsafeSlow?rue.exports=lQ:(iue(lQ,YT),YT.Buffer=wf);function wf(t,e,r){return qa(t,e,r)}iue(qa,wf);wf.from=function(t,e,r){if(typeof t=="number")throw new TypeError("Argument must not be a number");return qa(t,e,r)};wf.alloc=function(t,e,r){if(typeof t!="number")throw new TypeError("Argument must be a number");var i=qa(t);return e!==void 0?typeof r=="string"?i.fill(e,r):i.fill(e):i.fill(0),i};wf.allocUnsafe=function(t){if(typeof t!="number")throw new TypeError("Argument must be a number");return qa(t)};wf.allocUnsafeSlow=function(t){if(typeof t!="number")throw new TypeError("Argument must be a number");return lQ.SlowBuffer(t)}});var WT=E(sue=>{"use strict";var qT=nue().Buffer,oue=qT.isEncoding||function(t){switch(t=""+t,t&&t.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function J9e(t){if(!t)return"utf8";for(var e;;)switch(t){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return t;default:if(e)return;t=(""+t).toLowerCase(),e=!0}}function W9e(t){var e=J9e(t);if(typeof e!="string"&&(qT.isEncoding===oue||!oue(t)))throw new Error("Unknown encoding: "+t);return e||t}sue.StringDecoder=rm;function rm(t){this.encoding=W9e(t);var e;switch(this.encoding){case"utf16le":this.text=V9e,this.end=_9e,e=4;break;case"utf8":this.fillLast=z9e,e=4;break;case"base64":this.text=X9e,this.end=Z9e,e=3;break;default:this.write=$9e,this.end=eVe;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=qT.allocUnsafe(e)}rm.prototype.write=function(t){if(t.length===0)return"";var e,r;if(this.lastNeed){if(e=this.fillLast(t),e===void 0)return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r>5==6?2:t>>4==14?3:t>>3==30?4:t>>6==2?-1:-2}function iVe(t,e,r){var i=e.length-1;if(i=0?(n>0&&(t.lastNeed=n-1),n):--i=0?(n>0&&(t.lastNeed=n-2),n):--i=0?(n>0&&(n===2?n=0:t.lastNeed=n-3),n):0))}function nVe(t,e,r){if((e[0]&192)!=128)return t.lastNeed=0,"\uFFFD";if(t.lastNeed>1&&e.length>1){if((e[1]&192)!=128)return t.lastNeed=1,"\uFFFD";if(t.lastNeed>2&&e.length>2&&(e[2]&192)!=128)return t.lastNeed=2,"\uFFFD"}}function z9e(t){var e=this.lastTotal-this.lastNeed,r=nVe(this,t,e);if(r!==void 0)return r;if(this.lastNeed<=t.length)return t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,e,0,t.length),this.lastNeed-=t.length}function rVe(t,e){var r=iVe(this,t,e);if(!this.lastNeed)return t.toString("utf8",e);this.lastTotal=r;var i=t.length-(r-this.lastNeed);return t.copy(this.lastChar,0,i),t.toString("utf8",e,i)}function tVe(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+"\uFFFD":e}function V9e(t,e){if((t.length-e)%2==0){var r=t.toString("utf16le",e);if(r){var i=r.charCodeAt(r.length-1);if(i>=55296&&i<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=t[t.length-1],t.toString("utf16le",e,t.length-1)}function _9e(t){var e=t&&t.length?this.write(t):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return e+this.lastChar.toString("utf16le",0,r)}return e}function X9e(t,e){var r=(t.length-e)%3;return r===0?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,r===1?this.lastChar[0]=t[t.length-1]:(this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1]),t.toString("base64",e,t.length-r))}function Z9e(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function $9e(t){return t.toString(this.encoding)}function eVe(t){return t&&t.length?this.write(t):""}});var cQ=E((QPt,aue)=>{"use strict";var Aue=VA().codes.ERR_STREAM_PREMATURE_CLOSE;function sVe(t){var e=!1;return function(){if(!e){e=!0;for(var r=arguments.length,i=new Array(r),n=0;n{"use strict";var uQ;function ZA(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var AVe=cQ(),$A=Symbol("lastResolve"),qc=Symbol("lastReject"),im=Symbol("error"),gQ=Symbol("ended"),Jc=Symbol("lastPromise"),zT=Symbol("handlePromise"),Wc=Symbol("stream");function el(t,e){return{value:t,done:e}}function lVe(t){var e=t[$A];if(e!==null){var r=t[Wc].read();r!==null&&(t[Jc]=null,t[$A]=null,t[qc]=null,e(el(r,!1)))}}function cVe(t){process.nextTick(lVe,t)}function uVe(t,e){return function(r,i){t.then(function(){if(e[gQ]){r(el(void 0,!0));return}e[zT](r,i)},i)}}var gVe=Object.getPrototypeOf(function(){}),fVe=Object.setPrototypeOf((uQ={get stream(){return this[Wc]},next:function(){var e=this,r=this[im];if(r!==null)return Promise.reject(r);if(this[gQ])return Promise.resolve(el(void 0,!0));if(this[Wc].destroyed)return new Promise(function(o,a){process.nextTick(function(){e[im]?a(e[im]):o(el(void 0,!0))})});var i=this[Jc],n;if(i)n=new Promise(uVe(i,this));else{var s=this[Wc].read();if(s!==null)return Promise.resolve(el(s,!1));n=new Promise(this[zT])}return this[Jc]=n,n}},ZA(uQ,Symbol.asyncIterator,function(){return this}),ZA(uQ,"return",function(){var e=this;return new Promise(function(r,i){e[Wc].destroy(null,function(n){if(n){i(n);return}r(el(void 0,!0))})})}),uQ),gVe),hVe=function(e){var r,i=Object.create(fVe,(r={},ZA(r,Wc,{value:e,writable:!0}),ZA(r,$A,{value:null,writable:!0}),ZA(r,qc,{value:null,writable:!0}),ZA(r,im,{value:null,writable:!0}),ZA(r,gQ,{value:e._readableState.endEmitted,writable:!0}),ZA(r,zT,{value:function(s,o){var a=i[Wc].read();a?(i[Jc]=null,i[$A]=null,i[qc]=null,s(el(a,!1))):(i[$A]=s,i[qc]=o)},writable:!0}),r));return i[Jc]=null,AVe(e,function(n){if(n&&n.code!=="ERR_STREAM_PREMATURE_CLOSE"){var s=i[qc];s!==null&&(i[Jc]=null,i[$A]=null,i[qc]=null,s(n)),i[im]=n;return}var o=i[$A];o!==null&&(i[Jc]=null,i[$A]=null,i[qc]=null,o(el(void 0,!0))),i[gQ]=!0}),e.on("readable",cVe.bind(null,i)),i};cue.exports=hVe});var pue=E((vPt,gue)=>{"use strict";function fue(t,e,r,i,n,s,o){try{var a=t[s](o),l=a.value}catch(c){r(c);return}a.done?e(l):Promise.resolve(l).then(i,n)}function pVe(t){return function(){var e=this,r=arguments;return new Promise(function(i,n){var s=t.apply(e,r);function o(l){fue(s,i,n,o,a,"next",l)}function a(l){fue(s,i,n,o,a,"throw",l)}o(void 0)})}}function hue(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable})),r.push.apply(r,i)}return r}function CVe(t){for(var e=1;e{"use strict";due.exports=kt;var Bf;kt.ReadableState=Cue;var SPt=require("events").EventEmitter,mue=function(e,r){return e.listeners(r).length},nm=PT(),fQ=require("buffer").Buffer,IVe=global.Uint8Array||function(){};function yVe(t){return fQ.from(t)}function wVe(t){return fQ.isBuffer(t)||t instanceof IVe}var VT=require("util"),Et;VT&&VT.debuglog?Et=VT.debuglog("stream"):Et=function(){};var BVe=Oce(),_T=FT(),QVe=NT(),bVe=QVe.getHighWaterMark,hQ=VA().codes,vVe=hQ.ERR_INVALID_ARG_TYPE,SVe=hQ.ERR_STREAM_PUSH_AFTER_EOF,xVe=hQ.ERR_METHOD_NOT_IMPLEMENTED,kVe=hQ.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,Qf,XT,ZT;_A()(kt,nm);var sm=_T.errorOrDestroy,$T=["error","close","destroy","pause","resume"];function PVe(t,e,r){if(typeof t.prependListener=="function")return t.prependListener(e,r);!t._events||!t._events[e]?t.on(e,r):Array.isArray(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]}function Cue(t,e,r){Bf=Bf||Yc(),t=t||{},typeof r!="boolean"&&(r=e instanceof Bf),this.objectMode=!!t.objectMode,r&&(this.objectMode=this.objectMode||!!t.readableObjectMode),this.highWaterMark=bVe(this,t,"readableHighWaterMark",r),this.buffer=new BVe,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=t.emitClose!==!1,this.autoDestroy=!!t.autoDestroy,this.destroyed=!1,this.defaultEncoding=t.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,t.encoding&&(Qf||(Qf=WT().StringDecoder),this.decoder=new Qf(t.encoding),this.encoding=t.encoding)}function kt(t){if(Bf=Bf||Yc(),!(this instanceof kt))return new kt(t);var e=this instanceof Bf;this._readableState=new Cue(t,this,e),this.readable=!0,t&&(typeof t.read=="function"&&(this._read=t.read),typeof t.destroy=="function"&&(this._destroy=t.destroy)),nm.call(this)}Object.defineProperty(kt.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(e){!this._readableState||(this._readableState.destroyed=e)}});kt.prototype.destroy=_T.destroy;kt.prototype._undestroy=_T.undestroy;kt.prototype._destroy=function(t,e){e(t)};kt.prototype.push=function(t,e){var r=this._readableState,i;return r.objectMode?i=!0:typeof t=="string"&&(e=e||r.defaultEncoding,e!==r.encoding&&(t=fQ.from(t,e),e=""),i=!0),Eue(this,t,e,!1,i)};kt.prototype.unshift=function(t){return Eue(this,t,null,!0,!1)};function Eue(t,e,r,i,n){Et("readableAddChunk",e);var s=t._readableState;if(e===null)s.reading=!1,RVe(t,s);else{var o;if(n||(o=DVe(s,e)),o)sm(t,o);else if(s.objectMode||e&&e.length>0)if(typeof e!="string"&&!s.objectMode&&Object.getPrototypeOf(e)!==fQ.prototype&&(e=yVe(e)),i)s.endEmitted?sm(t,new kVe):eM(t,s,e,!0);else if(s.ended)sm(t,new SVe);else{if(s.destroyed)return!1;s.reading=!1,s.decoder&&!r?(e=s.decoder.write(e),s.objectMode||e.length!==0?eM(t,s,e,!1):tM(t,s)):eM(t,s,e,!1)}else i||(s.reading=!1,tM(t,s))}return!s.ended&&(s.length=Iue?t=Iue:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}function yue(t,e){return t<=0||e.length===0&&e.ended?0:e.objectMode?1:t!==t?e.flowing&&e.length?e.buffer.head.data.length:e.length:(t>e.highWaterMark&&(e.highWaterMark=FVe(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}kt.prototype.read=function(t){Et("read",t),t=parseInt(t,10);var e=this._readableState,r=t;if(t!==0&&(e.emittedReadable=!1),t===0&&e.needReadable&&((e.highWaterMark!==0?e.length>=e.highWaterMark:e.length>0)||e.ended))return Et("read: emitReadable",e.length,e.ended),e.length===0&&e.ended?rM(this):pQ(this),null;if(t=yue(t,e),t===0&&e.ended)return e.length===0&&rM(this),null;var i=e.needReadable;Et("need readable",i),(e.length===0||e.length-t0?n=wue(t,e):n=null,n===null?(e.needReadable=e.length<=e.highWaterMark,t=0):(e.length-=t,e.awaitDrain=0),e.length===0&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&rM(this)),n!==null&&this.emit("data",n),n};function RVe(t,e){if(Et("onEofChunk"),!e.ended){if(e.decoder){var r=e.decoder.end();r&&r.length&&(e.buffer.push(r),e.length+=e.objectMode?1:r.length)}e.ended=!0,e.sync?pQ(t):(e.needReadable=!1,e.emittedReadable||(e.emittedReadable=!0,Bue(t)))}}function pQ(t){var e=t._readableState;Et("emitReadable",e.needReadable,e.emittedReadable),e.needReadable=!1,e.emittedReadable||(Et("emitReadable",e.flowing),e.emittedReadable=!0,process.nextTick(Bue,t))}function Bue(t){var e=t._readableState;Et("emitReadable_",e.destroyed,e.length,e.ended),!e.destroyed&&(e.length||e.ended)&&(t.emit("readable"),e.emittedReadable=!1),e.needReadable=!e.flowing&&!e.ended&&e.length<=e.highWaterMark,iM(t)}function tM(t,e){e.readingMore||(e.readingMore=!0,process.nextTick(NVe,t,e))}function NVe(t,e){for(;!e.reading&&!e.ended&&(e.length1&&Que(i.pipes,t)!==-1)&&!c&&(Et("false write response, pause",i.awaitDrain),i.awaitDrain++),r.pause())}function f(m){Et("onerror",m),d(),t.removeListener("error",f),mue(t,"error")===0&&sm(t,m)}PVe(t,"error",f);function h(){t.removeListener("finish",p),d()}t.once("close",h);function p(){Et("onfinish"),t.removeListener("close",h),d()}t.once("finish",p);function d(){Et("unpipe"),r.unpipe(t)}return t.emit("pipe",r),i.flowing||(Et("pipe resume"),r.resume()),t};function LVe(t){return function(){var r=t._readableState;Et("pipeOnDrain",r.awaitDrain),r.awaitDrain&&r.awaitDrain--,r.awaitDrain===0&&mue(t,"data")&&(r.flowing=!0,iM(t))}}kt.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(e.pipesCount===0)return this;if(e.pipesCount===1)return t&&t!==e.pipes?this:(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r),this);if(!t){var i=e.pipes,n=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var s=0;s0,i.flowing!==!1&&this.resume()):t==="readable"&&!i.endEmitted&&!i.readableListening&&(i.readableListening=i.needReadable=!0,i.flowing=!1,i.emittedReadable=!1,Et("on readable",i.length,i.reading),i.length?pQ(this):i.reading||process.nextTick(TVe,this)),r};kt.prototype.addListener=kt.prototype.on;kt.prototype.removeListener=function(t,e){var r=nm.prototype.removeListener.call(this,t,e);return t==="readable"&&process.nextTick(bue,this),r};kt.prototype.removeAllListeners=function(t){var e=nm.prototype.removeAllListeners.apply(this,arguments);return(t==="readable"||t===void 0)&&process.nextTick(bue,this),e};function bue(t){var e=t._readableState;e.readableListening=t.listenerCount("readable")>0,e.resumeScheduled&&!e.paused?e.flowing=!0:t.listenerCount("data")>0&&t.resume()}function TVe(t){Et("readable nexttick read 0"),t.read(0)}kt.prototype.resume=function(){var t=this._readableState;return t.flowing||(Et("resume"),t.flowing=!t.readableListening,MVe(this,t)),t.paused=!1,this};function MVe(t,e){e.resumeScheduled||(e.resumeScheduled=!0,process.nextTick(OVe,t,e))}function OVe(t,e){Et("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),iM(t),e.flowing&&!e.reading&&t.read(0)}kt.prototype.pause=function(){return Et("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(Et("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function iM(t){var e=t._readableState;for(Et("flow",e.flowing);e.flowing&&t.read()!==null;);}kt.prototype.wrap=function(t){var e=this,r=this._readableState,i=!1;t.on("end",function(){if(Et("wrapped end"),r.decoder&&!r.ended){var o=r.decoder.end();o&&o.length&&e.push(o)}e.push(null)}),t.on("data",function(o){if(Et("wrapped data"),r.decoder&&(o=r.decoder.write(o)),!(r.objectMode&&o==null)&&!(!r.objectMode&&(!o||!o.length))){var a=e.push(o);a||(i=!0,t.pause())}});for(var n in t)this[n]===void 0&&typeof t[n]=="function"&&(this[n]=function(a){return function(){return t[a].apply(t,arguments)}}(n));for(var s=0;s<$T.length;s++)t.on($T[s],this.emit.bind(this,$T[s]));return this._read=function(o){Et("wrapped _read",o),i&&(i=!1,t.resume())},this};typeof Symbol=="function"&&(kt.prototype[Symbol.asyncIterator]=function(){return XT===void 0&&(XT=uue()),XT(this)});Object.defineProperty(kt.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}});Object.defineProperty(kt.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}});Object.defineProperty(kt.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(e){this._readableState&&(this._readableState.flowing=e)}});kt._fromList=wue;Object.defineProperty(kt.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function wue(t,e){if(e.length===0)return null;var r;return e.objectMode?r=e.buffer.shift():!t||t>=e.length?(e.decoder?r=e.buffer.join(""):e.buffer.length===1?r=e.buffer.first():r=e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r}function rM(t){var e=t._readableState;Et("endReadable",e.endEmitted),e.endEmitted||(e.ended=!0,process.nextTick(KVe,e,t))}function KVe(t,e){if(Et("endReadableNT",t.endEmitted,t.length),!t.endEmitted&&t.length===0&&(t.endEmitted=!0,e.readable=!1,e.emit("end"),t.autoDestroy)){var r=e._writableState;(!r||r.autoDestroy&&r.finished)&&e.destroy()}}typeof Symbol=="function"&&(kt.from=function(t,e){return ZT===void 0&&(ZT=pue()),ZT(kt,t,e)});function Que(t,e){for(var r=0,i=t.length;r{"use strict";vue.exports=Ja;var dQ=VA().codes,UVe=dQ.ERR_METHOD_NOT_IMPLEMENTED,HVe=dQ.ERR_MULTIPLE_CALLBACK,GVe=dQ.ERR_TRANSFORM_ALREADY_TRANSFORMING,jVe=dQ.ERR_TRANSFORM_WITH_LENGTH_0,CQ=Yc();_A()(Ja,CQ);function YVe(t,e){var r=this._transformState;r.transforming=!1;var i=r.writecb;if(i===null)return this.emit("error",new HVe);r.writechunk=null,r.writecb=null,e!=null&&this.push(e),i(t);var n=this._readableState;n.reading=!1,(n.needReadable||n.length{"use strict";xue.exports=om;var kue=nM();_A()(om,kue);function om(t){if(!(this instanceof om))return new om(t);kue.call(this,t)}om.prototype._transform=function(t,e,r){r(null,t)}});var Lue=E((DPt,Due)=>{"use strict";var sM;function JVe(t){var e=!1;return function(){e||(e=!0,t.apply(void 0,arguments))}}var Rue=VA().codes,WVe=Rue.ERR_MISSING_ARGS,zVe=Rue.ERR_STREAM_DESTROYED;function Fue(t){if(t)throw t}function VVe(t){return t.setHeader&&typeof t.abort=="function"}function _Ve(t,e,r,i){i=JVe(i);var n=!1;t.on("close",function(){n=!0}),sM===void 0&&(sM=cQ()),sM(t,{readable:e,writable:r},function(o){if(o)return i(o);n=!0,i()});var s=!1;return function(o){if(!n&&!s){if(s=!0,VVe(t))return t.abort();if(typeof t.destroy=="function")return t.destroy();i(o||new zVe("pipe"))}}}function Nue(t){t()}function XVe(t,e){return t.pipe(e)}function ZVe(t){return!t.length||typeof t[t.length-1]!="function"?Fue:t.pop()}function $Ve(){for(var t=arguments.length,e=new Array(t),r=0;r0;return _Ve(o,l,c,function(u){n||(n=u),u&&s.forEach(Nue),!l&&(s.forEach(Nue),i(n))})});return e.reduce(XVe)}Due.exports=$Ve});var bf=E((ys,am)=>{var Am=require("stream");process.env.READABLE_STREAM==="disable"&&Am?(am.exports=Am.Readable,Object.assign(am.exports,Am),am.exports.Stream=Am):(ys=am.exports=HT(),ys.Stream=Am||ys,ys.Readable=ys,ys.Writable=UT(),ys.Duplex=Yc(),ys.Transform=nM(),ys.PassThrough=Pue(),ys.finished=cQ(),ys.pipeline=Lue())});var Oue=E((RPt,Tue)=>{"use strict";var{Buffer:_s}=require("buffer"),Mue=Symbol.for("BufferList");function nr(t){if(!(this instanceof nr))return new nr(t);nr._init.call(this,t)}nr._init=function(e){Object.defineProperty(this,Mue,{value:!0}),this._bufs=[],this.length=0,e&&this.append(e)};nr.prototype._new=function(e){return new nr(e)};nr.prototype._offset=function(e){if(e===0)return[0,0];let r=0;for(let i=0;ithis.length||e<0)return;let r=this._offset(e);return this._bufs[r[0]][r[1]]};nr.prototype.slice=function(e,r){return typeof e=="number"&&e<0&&(e+=this.length),typeof r=="number"&&r<0&&(r+=this.length),this.copy(null,0,e,r)};nr.prototype.copy=function(e,r,i,n){if((typeof i!="number"||i<0)&&(i=0),(typeof n!="number"||n>this.length)&&(n=this.length),i>=this.length||n<=0)return e||_s.alloc(0);let s=!!e,o=this._offset(i),a=n-i,l=a,c=s&&r||0,u=o[1];if(i===0&&n===this.length){if(!s)return this._bufs.length===1?this._bufs[0]:_s.concat(this._bufs,this.length);for(let g=0;gf)this._bufs[g].copy(e,c,u),c+=f;else{this._bufs[g].copy(e,c,u,u+l),c+=f;break}l-=f,u&&(u=0)}return e.length>c?e.slice(0,c):e};nr.prototype.shallowSlice=function(e,r){if(e=e||0,r=typeof r!="number"?this.length:r,e<0&&(e+=this.length),r<0&&(r+=this.length),e===r)return this._new();let i=this._offset(e),n=this._offset(r),s=this._bufs.slice(i[0],n[0]+1);return n[1]===0?s.pop():s[s.length-1]=s[s.length-1].slice(0,n[1]),i[1]!==0&&(s[0]=s[0].slice(i[1])),this._new(s)};nr.prototype.toString=function(e,r,i){return this.slice(r,i).toString(e)};nr.prototype.consume=function(e){if(e=Math.trunc(e),Number.isNaN(e)||e<=0)return this;for(;this._bufs.length;)if(e>=this._bufs[0].length)e-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift();else{this._bufs[0]=this._bufs[0].slice(e),this.length-=e;break}return this};nr.prototype.duplicate=function(){let e=this._new();for(let r=0;rthis.length?this.length:e;let i=this._offset(e),n=i[0],s=i[1];for(;n=t.length){let l=o.indexOf(t,s);if(l!==-1)return this._reverseOffset([n,l]);s=o.length-t.length+1}else{let l=this._reverseOffset([n,s]);if(this._match(l,t))return l;s++}s=0}return-1};nr.prototype._match=function(t,e){if(this.length-t{"use strict";var oM=bf().Duplex,e7e=_A(),lm=Oue();function Oi(t){if(!(this instanceof Oi))return new Oi(t);if(typeof t=="function"){this._callback=t;let e=function(i){this._callback&&(this._callback(i),this._callback=null)}.bind(this);this.on("pipe",function(i){i.on("error",e)}),this.on("unpipe",function(i){i.removeListener("error",e)}),t=null}lm._init.call(this,t),oM.call(this)}e7e(Oi,oM);Object.assign(Oi.prototype,lm.prototype);Oi.prototype._new=function(e){return new Oi(e)};Oi.prototype._write=function(e,r,i){this._appendBuffer(e),typeof i=="function"&&i()};Oi.prototype._read=function(e){if(!this.length)return this.push(null);e=Math.min(e,this.length),this.push(this.slice(0,e)),this.consume(e)};Oi.prototype.end=function(e){oM.prototype.end.call(this,e),this._callback&&(this._callback(null,this.slice()),this._callback=null)};Oi.prototype._destroy=function(e,r){this._bufs.length=0,this.length=0,r(e)};Oi.prototype._isBufferList=function(e){return e instanceof Oi||e instanceof lm||Oi.isBufferList(e)};Oi.isBufferList=lm.isBufferList;mQ.exports=Oi;mQ.exports.BufferListStream=Oi;mQ.exports.BufferList=lm});var lM=E(vf=>{var t7e=Buffer.alloc,r7e="0000000000000000000",i7e="7777777777777777777",Uue="0".charCodeAt(0),Hue=Buffer.from("ustar\0","binary"),n7e=Buffer.from("00","binary"),s7e=Buffer.from("ustar ","binary"),o7e=Buffer.from(" \0","binary"),a7e=parseInt("7777",8),cm=257,aM=263,A7e=function(t,e,r){return typeof t!="number"?r:(t=~~t,t>=e?e:t>=0||(t+=e,t>=0)?t:0)},l7e=function(t){switch(t){case 0:return"file";case 1:return"link";case 2:return"symlink";case 3:return"character-device";case 4:return"block-device";case 5:return"directory";case 6:return"fifo";case 7:return"contiguous-file";case 72:return"pax-header";case 55:return"pax-global-header";case 27:return"gnu-long-link-path";case 28:case 30:return"gnu-long-path"}return null},c7e=function(t){switch(t){case"file":return 0;case"link":return 1;case"symlink":return 2;case"character-device":return 3;case"block-device":return 4;case"directory":return 5;case"fifo":return 6;case"contiguous-file":return 7;case"pax-header":return 72}return 0},Gue=function(t,e,r,i){for(;re?i7e.slice(0,e)+" ":r7e.slice(0,e-t.length)+t+" "};function u7e(t){var e;if(t[0]===128)e=!0;else if(t[0]===255)e=!1;else return null;for(var r=[],i=t.length-1;i>0;i--){var n=t[i];e?r.push(n):r.push(255-n)}var s=0,o=r.length;for(i=0;i=Math.pow(10,r)&&r++,e+r+t};vf.decodeLongPath=function(t,e){return Sf(t,0,t.length,e)};vf.encodePax=function(t){var e="";t.name&&(e+=AM(" path="+t.name+` -`)),t.linkname&&(e+=AM(" linkpath="+t.linkname+` -`));var r=t.pax;if(r)for(var i in r)e+=AM(" "+i+"="+r[i]+` -`);return Buffer.from(e)};vf.decodePax=function(t){for(var e={};t.length;){for(var r=0;r100;){var n=r.indexOf("/");if(n===-1)return null;i+=i?"/"+r.slice(0,n):r.slice(0,n),r=r.slice(n+1)}return Buffer.byteLength(r)>100||Buffer.byteLength(i)>155||t.linkname&&Buffer.byteLength(t.linkname)>100?null:(e.write(r),e.write(tl(t.mode&a7e,6),100),e.write(tl(t.uid,6),108),e.write(tl(t.gid,6),116),e.write(tl(t.size,11),124),e.write(tl(t.mtime.getTime()/1e3|0,11),136),e[156]=Uue+c7e(t.type),t.linkname&&e.write(t.linkname,157),Hue.copy(e,cm),n7e.copy(e,aM),t.uname&&e.write(t.uname,265),t.gname&&e.write(t.gname,297),e.write(tl(t.devmajor||0,6),329),e.write(tl(t.devminor||0,6),337),i&&e.write(i,345),e.write(tl(jue(e),6),148),e)};vf.decode=function(t,e,r){var i=t[156]===0?0:t[156]-Uue,n=Sf(t,0,100,e),s=rl(t,100,8),o=rl(t,108,8),a=rl(t,116,8),l=rl(t,124,12),c=rl(t,136,12),u=l7e(i),g=t[157]===0?null:Sf(t,157,100,e),f=Sf(t,265,32),h=Sf(t,297,32),p=rl(t,329,8),d=rl(t,337,8),m=jue(t);if(m===8*32)return null;if(m!==rl(t,148,8))throw new Error("Invalid tar header. Maybe the tar is corrupted or it needs to be gunzipped?");if(Hue.compare(t,cm,cm+6)===0)t[345]&&(n=Sf(t,345,155,e)+"/"+n);else if(!(s7e.compare(t,cm,cm+6)===0&&o7e.compare(t,aM,aM+2)===0)){if(!r)throw new Error("Invalid tar header: unknown format.")}return i===0&&n&&n[n.length-1]==="/"&&(i=5),{name:n,mode:s,uid:o,gid:a,size:l,mtime:new Date(1e3*c),type:u,linkname:g,uname:f,gname:h,devmajor:p,devminor:d}}});var _ue=E((LPt,Yue)=>{var que=require("util"),g7e=Kue(),um=lM(),Jue=bf().Writable,Wue=bf().PassThrough,zue=function(){},Vue=function(t){return t&=511,t&&512-t},f7e=function(t,e){var r=new EQ(t,e);return r.end(),r},h7e=function(t,e){return e.path&&(t.name=e.path),e.linkpath&&(t.linkname=e.linkpath),e.size&&(t.size=parseInt(e.size,10)),t.pax=e,t},EQ=function(t,e){this._parent=t,this.offset=e,Wue.call(this,{autoDestroy:!1})};que.inherits(EQ,Wue);EQ.prototype.destroy=function(t){this._parent.destroy(t)};var Wa=function(t){if(!(this instanceof Wa))return new Wa(t);Jue.call(this,t),t=t||{},this._offset=0,this._buffer=g7e(),this._missing=0,this._partial=!1,this._onparse=zue,this._header=null,this._stream=null,this._overflow=null,this._cb=null,this._locked=!1,this._destroyed=!1,this._pax=null,this._paxGlobal=null,this._gnuLongPath=null,this._gnuLongLinkPath=null;var e=this,r=e._buffer,i=function(){e._continue()},n=function(f){if(e._locked=!1,f)return e.destroy(f);e._stream||i()},s=function(){e._stream=null;var f=Vue(e._header.size);f?e._parse(f,o):e._parse(512,g),e._locked||i()},o=function(){e._buffer.consume(Vue(e._header.size)),e._parse(512,g),i()},a=function(){var f=e._header.size;e._paxGlobal=um.decodePax(r.slice(0,f)),r.consume(f),s()},l=function(){var f=e._header.size;e._pax=um.decodePax(r.slice(0,f)),e._paxGlobal&&(e._pax=Object.assign({},e._paxGlobal,e._pax)),r.consume(f),s()},c=function(){var f=e._header.size;this._gnuLongPath=um.decodeLongPath(r.slice(0,f),t.filenameEncoding),r.consume(f),s()},u=function(){var f=e._header.size;this._gnuLongLinkPath=um.decodeLongPath(r.slice(0,f),t.filenameEncoding),r.consume(f),s()},g=function(){var f=e._offset,h;try{h=e._header=um.decode(r.slice(0,512),t.filenameEncoding,t.allowUnknownFormat)}catch(p){e.emit("error",p)}if(r.consume(512),!h){e._parse(512,g),i();return}if(h.type==="gnu-long-path"){e._parse(h.size,c),i();return}if(h.type==="gnu-long-link-path"){e._parse(h.size,u),i();return}if(h.type==="pax-global-header"){e._parse(h.size,a),i();return}if(h.type==="pax-header"){e._parse(h.size,l),i();return}if(e._gnuLongPath&&(h.name=e._gnuLongPath,e._gnuLongPath=null),e._gnuLongLinkPath&&(h.linkname=e._gnuLongLinkPath,e._gnuLongLinkPath=null),e._pax&&(e._header=h=h7e(h,e._pax),e._pax=null),e._locked=!0,!h.size||h.type==="directory"){e._parse(512,g),e.emit("entry",h,f7e(e,f),n);return}e._stream=new EQ(e,f),e.emit("entry",h,e._stream,n),e._parse(h.size,s),i()};this._onheader=g,this._parse(512,g)};que.inherits(Wa,Jue);Wa.prototype.destroy=function(t){this._destroyed||(this._destroyed=!0,t&&this.emit("error",t),this.emit("close"),this._stream&&this._stream.emit("close"))};Wa.prototype._parse=function(t,e){this._destroyed||(this._offset+=t,this._missing=t,e===this._onheader&&(this._partial=!1),this._onparse=e)};Wa.prototype._continue=function(){if(!this._destroyed){var t=this._cb;this._cb=zue,this._overflow?this._write(this._overflow,void 0,t):t()}};Wa.prototype._write=function(t,e,r){if(!this._destroyed){var i=this._stream,n=this._buffer,s=this._missing;if(t.length&&(this._partial=!0),t.lengths&&(o=t.slice(s),t=t.slice(0,s)),i?i.end(t):n.append(t),this._overflow=o,this._onparse()}};Wa.prototype._final=function(t){if(this._partial)return this.destroy(new Error("Unexpected end of data"));t()};Yue.exports=Wa});var Zue=E((TPt,Xue)=>{Xue.exports=require("fs").constants||require("constants")});var ige=E((MPt,$ue)=>{var xf=Zue(),ege=tk(),IQ=_A(),p7e=Buffer.alloc,tge=bf().Readable,kf=bf().Writable,d7e=require("string_decoder").StringDecoder,yQ=lM(),C7e=parseInt("755",8),m7e=parseInt("644",8),rge=p7e(1024),cM=function(){},uM=function(t,e){e&=511,e&&t.push(rge.slice(0,512-e))};function E7e(t){switch(t&xf.S_IFMT){case xf.S_IFBLK:return"block-device";case xf.S_IFCHR:return"character-device";case xf.S_IFDIR:return"directory";case xf.S_IFIFO:return"fifo";case xf.S_IFLNK:return"symlink"}return"file"}var wQ=function(t){kf.call(this),this.written=0,this._to=t,this._destroyed=!1};IQ(wQ,kf);wQ.prototype._write=function(t,e,r){if(this.written+=t.length,this._to.push(t))return r();this._to._drain=r};wQ.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var BQ=function(){kf.call(this),this.linkname="",this._decoder=new d7e("utf-8"),this._destroyed=!1};IQ(BQ,kf);BQ.prototype._write=function(t,e,r){this.linkname+=this._decoder.write(t),r()};BQ.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var gm=function(){kf.call(this),this._destroyed=!1};IQ(gm,kf);gm.prototype._write=function(t,e,r){r(new Error("No body allowed for this entry"))};gm.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var Oo=function(t){if(!(this instanceof Oo))return new Oo(t);tge.call(this,t),this._drain=cM,this._finalized=!1,this._finalizing=!1,this._destroyed=!1,this._stream=null};IQ(Oo,tge);Oo.prototype.entry=function(t,e,r){if(this._stream)throw new Error("already piping an entry");if(!(this._finalized||this._destroyed)){typeof e=="function"&&(r=e,e=null),r||(r=cM);var i=this;if((!t.size||t.type==="symlink")&&(t.size=0),t.type||(t.type=E7e(t.mode)),t.mode||(t.mode=t.type==="directory"?C7e:m7e),t.uid||(t.uid=0),t.gid||(t.gid=0),t.mtime||(t.mtime=new Date),typeof e=="string"&&(e=Buffer.from(e)),Buffer.isBuffer(e)){t.size=e.length,this._encode(t);var n=this.push(e);return uM(i,t.size),n?process.nextTick(r):this._drain=r,new gm}if(t.type==="symlink"&&!t.linkname){var s=new BQ;return ege(s,function(a){if(a)return i.destroy(),r(a);t.linkname=s.linkname,i._encode(t),r()}),s}if(this._encode(t),t.type!=="file"&&t.type!=="contiguous-file")return process.nextTick(r),new gm;var o=new wQ(this);return this._stream=o,ege(o,function(a){if(i._stream=null,a)return i.destroy(),r(a);if(o.written!==t.size)return i.destroy(),r(new Error("size mismatch"));uM(i,t.size),i._finalizing&&i.finalize(),r()}),o}};Oo.prototype.finalize=function(){if(this._stream){this._finalizing=!0;return}this._finalized||(this._finalized=!0,this.push(rge),this.push(null))};Oo.prototype.destroy=function(t){this._destroyed||(this._destroyed=!0,t&&this.emit("error",t),this.emit("close"),this._stream&&this._stream.destroy&&this._stream.destroy())};Oo.prototype._encode=function(t){if(!t.pax){var e=yQ.encode(t);if(e){this.push(e);return}}this._encodePax(t)};Oo.prototype._encodePax=function(t){var e=yQ.encodePax({name:t.name,linkname:t.linkname,pax:t.pax}),r={name:"PaxHeader",mode:t.mode,uid:t.uid,gid:t.gid,size:e.length,mtime:t.mtime,type:"pax-header",linkname:t.linkname&&"PaxHeader",uname:t.uname,gname:t.gname,devmajor:t.devmajor,devminor:t.devminor};this.push(yQ.encode(r)),this.push(e),uM(this,e.length),r.size=t.size,r.type=t.type,this.push(yQ.encode(r))};Oo.prototype._read=function(t){var e=this._drain;this._drain=cM,e()};$ue.exports=Oo});var nge=E(gM=>{gM.extract=_ue();gM.pack=ige()});var Cge=E((oDt,fge)=>{"use strict";var Pf=class{constructor(e,r,i){this.__specs=e||{},Object.keys(this.__specs).forEach(n=>{if(typeof this.__specs[n]=="string"){let s=this.__specs[n],o=this.__specs[s];if(o){let a=o.aliases||[];a.push(n,s),o.aliases=[...new Set(a)],this.__specs[n]=o}else throw new Error(`Alias refers to invalid key: ${s} -> ${n}`)}}),this.__opts=r||{},this.__providers=pge(i.filter(n=>n!=null&&typeof n=="object")),this.__isFiggyPudding=!0}get(e){return mM(this,e,!0)}get[Symbol.toStringTag](){return"FiggyPudding"}forEach(e,r=this){for(let[i,n]of this.entries())e.call(r,n,i,this)}toJSON(){let e={};return this.forEach((r,i)=>{e[i]=r}),e}*entries(e){for(let i of Object.keys(this.__specs))yield[i,this.get(i)];let r=e||this.__opts.other;if(r){let i=new Set;for(let n of this.__providers){let s=n.entries?n.entries(r):R7e(n);for(let[o,a]of s)r(o)&&!i.has(o)&&(i.add(o),yield[o,a])}}}*[Symbol.iterator](){for(let[e,r]of this.entries())yield[e,r]}*keys(){for(let[e]of this.entries())yield e}*values(){for(let[,e]of this.entries())yield e}concat(...e){return new Proxy(new Pf(this.__specs,this.__opts,pge(this.__providers).concat(e)),hge)}};try{let t=require("util");Pf.prototype[t.inspect.custom]=function(e,r){return this[Symbol.toStringTag]+" "+t.inspect(this.toJSON(),r)}}catch(t){}function F7e(t){throw Object.assign(new Error(`invalid config key requested: ${t}`),{code:"EBADKEY"})}function mM(t,e,r){let i=t.__specs[e];if(r&&!i&&(!t.__opts.other||!t.__opts.other(e)))F7e(e);else{i||(i={});let n;for(let s of t.__providers){if(n=dge(e,s),n===void 0&&i.aliases&&i.aliases.length){for(let o of i.aliases)if(o!==e&&(n=dge(o,s),n!==void 0))break}if(n!==void 0)break}return n===void 0&&i.default!==void 0?typeof i.default=="function"?i.default(t):i.default:n}}function dge(t,e){let r;return e.__isFiggyPudding?r=mM(e,t,!1):typeof e.get=="function"?r=e.get(t):r=e[t],r}var hge={has(t,e){return e in t.__specs&&mM(t,e,!1)!==void 0},ownKeys(t){return Object.keys(t.__specs)},get(t,e){return typeof e=="symbol"||e.slice(0,2)==="__"||e in Pf.prototype?t[e]:t.get(e)},set(t,e,r){if(typeof e=="symbol"||e.slice(0,2)==="__")return t[e]=r,!0;throw new Error("figgyPudding options cannot be modified. Use .concat() instead.")},deleteProperty(){throw new Error("figgyPudding options cannot be deleted. Use .concat() and shadow them instead.")}};fge.exports=N7e;function N7e(t,e){function r(...i){return new Proxy(new Pf(t,e,i),hge)}return r}function pge(t){let e=[];return t.forEach(r=>e.unshift(r)),e}function R7e(t){return Object.keys(t).map(e=>[e,t[e]])}});var Ige=E((aDt,Ko)=>{"use strict";var hm=require("crypto"),L7e=Cge(),T7e=require("stream").Transform,mge=["sha256","sha384","sha512"],M7e=/^[a-z0-9+/]+(?:=?=?)$/i,O7e=/^([^-]+)-([^?]+)([?\S*]*)$/,K7e=/^([^-]+)-([A-Za-z0-9+/=]{44,88})(\?[\x21-\x7E]*)*$/,U7e=/^[\x21-\x7E]+$/,on=L7e({algorithms:{default:["sha512"]},error:{default:!1},integrity:{},options:{default:[]},pickAlgorithm:{default:()=>H7e},Promise:{default:()=>Promise},sep:{default:" "},single:{default:!1},size:{},strict:{default:!1}}),zc=class{get isHash(){return!0}constructor(e,r){r=on(r);let i=!!r.strict;this.source=e.trim();let n=this.source.match(i?K7e:O7e);if(!n||i&&!mge.some(o=>o===n[1]))return;this.algorithm=n[1],this.digest=n[2];let s=n[3];this.options=s?s.slice(1).split("?"):[]}hexDigest(){return this.digest&&Buffer.from(this.digest,"base64").toString("hex")}toJSON(){return this.toString()}toString(e){if(e=on(e),e.strict&&!(mge.some(i=>i===this.algorithm)&&this.digest.match(M7e)&&(this.options||[]).every(i=>i.match(U7e))))return"";let r=this.options&&this.options.length?`?${this.options.join("?")}`:"";return`${this.algorithm}-${this.digest}${r}`}},Df=class{get isIntegrity(){return!0}toJSON(){return this.toString()}toString(e){e=on(e);let r=e.sep||" ";return e.strict&&(r=r.replace(/\S+/g," ")),Object.keys(this).map(i=>this[i].map(n=>zc.prototype.toString.call(n,e)).filter(n=>n.length).join(r)).filter(i=>i.length).join(r)}concat(e,r){r=on(r);let i=typeof e=="string"?e:pm(e,r);return Uo(`${this.toString(r)} ${i}`,r)}hexDigest(){return Uo(this,{single:!0}).hexDigest()}match(e,r){r=on(r);let i=Uo(e,r),n=i.pickAlgorithm(r);return this[n]&&i[n]&&this[n].find(s=>i[n].find(o=>s.digest===o.digest))||!1}pickAlgorithm(e){e=on(e);let r=e.pickAlgorithm,i=Object.keys(this);if(!i.length)throw new Error(`No algorithms available for ${JSON.stringify(this.toString())}`);return i.reduce((n,s)=>r(n,s)||n)}};Ko.exports.parse=Uo;function Uo(t,e){if(e=on(e),typeof t=="string")return EM(t,e);if(t.algorithm&&t.digest){let r=new Df;return r[t.algorithm]=[t],EM(pm(r,e),e)}else return EM(pm(t,e),e)}function EM(t,e){return e.single?new zc(t,e):t.trim().split(/\s+/).reduce((r,i)=>{let n=new zc(i,e);if(n.algorithm&&n.digest){let s=n.algorithm;r[s]||(r[s]=[]),r[s].push(n)}return r},new Df)}Ko.exports.stringify=pm;function pm(t,e){return e=on(e),t.algorithm&&t.digest?zc.prototype.toString.call(t,e):typeof t=="string"?pm(Uo(t,e),e):Df.prototype.toString.call(t,e)}Ko.exports.fromHex=G7e;function G7e(t,e,r){r=on(r);let i=r.options&&r.options.length?`?${r.options.join("?")}`:"";return Uo(`${e}-${Buffer.from(t,"hex").toString("base64")}${i}`,r)}Ko.exports.fromData=j7e;function j7e(t,e){e=on(e);let r=e.algorithms,i=e.options&&e.options.length?`?${e.options.join("?")}`:"";return r.reduce((n,s)=>{let o=hm.createHash(s).update(t).digest("base64"),a=new zc(`${s}-${o}${i}`,e);if(a.algorithm&&a.digest){let l=a.algorithm;n[l]||(n[l]=[]),n[l].push(a)}return n},new Df)}Ko.exports.fromStream=Y7e;function Y7e(t,e){e=on(e);let r=e.Promise||Promise,i=IM(e);return new r((n,s)=>{t.pipe(i),t.on("error",s),i.on("error",s);let o;i.on("integrity",a=>{o=a}),i.on("end",()=>n(o)),i.on("data",()=>{})})}Ko.exports.checkData=q7e;function q7e(t,e,r){if(r=on(r),e=Uo(e,r),!Object.keys(e).length){if(r.error)throw Object.assign(new Error("No valid integrity hashes to check against"),{code:"EINTEGRITY"});return!1}let i=e.pickAlgorithm(r),n=hm.createHash(i).update(t).digest("base64"),s=Uo({algorithm:i,digest:n}),o=s.match(e,r);if(o||!r.error)return o;if(typeof r.size=="number"&&t.length!==r.size){let a=new Error(`data size mismatch when checking ${e}. - Wanted: ${r.size} - Found: ${t.length}`);throw a.code="EBADSIZE",a.found=t.length,a.expected=r.size,a.sri=e,a}else{let a=new Error(`Integrity checksum failed when using ${i}: Wanted ${e}, but got ${s}. (${t.length} bytes)`);throw a.code="EINTEGRITY",a.found=s,a.expected=e,a.algorithm=i,a.sri=e,a}}Ko.exports.checkStream=J7e;function J7e(t,e,r){r=on(r);let i=r.Promise||Promise,n=IM(r.concat({integrity:e}));return new i((s,o)=>{t.pipe(n),t.on("error",o),n.on("error",o);let a;n.on("verified",l=>{a=l}),n.on("end",()=>s(a)),n.on("data",()=>{})})}Ko.exports.integrityStream=IM;function IM(t){t=on(t);let e=t.integrity&&Uo(t.integrity,t),r=e&&Object.keys(e).length,i=r&&e.pickAlgorithm(t),n=r&&e[i],s=Array.from(new Set(t.algorithms.concat(i?[i]:[]))),o=s.map(hm.createHash),a=0,l=new T7e({transform(c,u,g){a+=c.length,o.forEach(f=>f.update(c,u)),g(null,c,u)}}).on("end",()=>{let c=t.options&&t.options.length?`?${t.options.join("?")}`:"",u=Uo(o.map((f,h)=>`${s[h]}-${f.digest("base64")}${c}`).join(" "),t),g=r&&u.match(e,t);if(typeof t.size=="number"&&a!==t.size){let f=new Error(`stream size mismatch when checking ${e}. - Wanted: ${t.size} - Found: ${a}`);f.code="EBADSIZE",f.found=a,f.expected=t.size,f.sri=e,l.emit("error",f)}else if(t.integrity&&!g){let f=new Error(`${e} integrity checksum failed when using ${i}: wanted ${n} but got ${u}. (${a} bytes)`);f.code="EINTEGRITY",f.found=u,f.expected=n,f.algorithm=i,f.sri=e,l.emit("error",f)}else l.emit("size",a),l.emit("integrity",u),g&&l.emit("verified",g)});return l}Ko.exports.create=W7e;function W7e(t){t=on(t);let e=t.algorithms,r=t.options.length?`?${t.options.join("?")}`:"",i=e.map(hm.createHash);return{update:function(n,s){return i.forEach(o=>o.update(n,s)),this},digest:function(n){return e.reduce((o,a)=>{let l=i.shift().digest("base64"),c=new zc(`${a}-${l}${r}`,t);if(c.algorithm&&c.digest){let u=c.algorithm;o[u]||(o[u]=[]),o[u].push(c)}return o},new Df)}}}var z7e=new Set(hm.getHashes()),Ege=["md5","whirlpool","sha1","sha224","sha256","sha384","sha512","sha3","sha3-256","sha3-384","sha3-512","sha3_256","sha3_384","sha3_512"].filter(t=>z7e.has(t));function H7e(t,e){return Ege.indexOf(t.toLowerCase())>=Ege.indexOf(e.toLowerCase())?t:e}});var Fd={};it(Fd,{BuildType:()=>Gn,Cache:()=>Qt,Configuration:()=>fe,DEFAULT_LOCK_FILENAME:()=>DR,DEFAULT_RC_FILENAME:()=>PR,FormatType:()=>ps,InstallMode:()=>li,LightReport:()=>Fa,LinkType:()=>gt,Manifest:()=>Ze,MessageName:()=>z,PackageExtensionStatus:()=>ki,PackageExtensionType:()=>oi,Project:()=>Ke,ProjectLookup:()=>KA,Report:()=>Xi,ReportError:()=>nt,SettingsType:()=>ge,StreamReport:()=>Fe,TAG_REGEXP:()=>Rg,TelemetryManager:()=>Rd,ThrowReport:()=>ei,VirtualFetcher:()=>dd,Workspace:()=>Dd,WorkspaceResolver:()=>Yr,YarnVersion:()=>Zr,execUtils:()=>hr,folderUtils:()=>Pb,formatUtils:()=>ue,hashUtils:()=>mn,httpUtils:()=>Zt,miscUtils:()=>de,scriptUtils:()=>Kt,semverUtils:()=>qt,structUtils:()=>S,tgzUtils:()=>Ai,treeUtils:()=>Hs});var hr={};it(hr,{EndStrategy:()=>Pn,execvp:()=>Nhe,pipevp:()=>to});var ch={};it(ch,{AliasFS:()=>Xo,CwdFS:()=>Ft,DEFAULT_COMPRESSION_LEVEL:()=>pl,FakeFS:()=>eA,Filename:()=>wt,JailFS:()=>Zo,LazyFS:()=>oh,LinkStrategy:()=>eh,NoFS:()=>bE,NodeFS:()=>Wt,PortablePath:()=>Se,PosixFS:()=>ah,ProxiedFS:()=>fi,VirtualFS:()=>Pr,ZipFS:()=>Jr,ZipOpenFS:()=>Jn,constants:()=>mr,extendFs:()=>SE,normalizeLineEndings:()=>ul,npath:()=>M,opendir:()=>wE,patchFs:()=>pb,ppath:()=>v,statUtils:()=>rb,toFilename:()=>kr,xfs:()=>T});var mr={};it(mr,{SAFE_TIME:()=>tb,S_IFDIR:()=>zo,S_IFLNK:()=>_o,S_IFMT:()=>kn,S_IFREG:()=>Vo});var kn=61440,zo=16384,Vo=32768,_o=40960,tb=456789e3;var rb={};it(rb,{BigIntStatsEntry:()=>Xf,DEFAULT_MODE:()=>_f,DirEntry:()=>uO,StatEntry:()=>Za,areStatsEqual:()=>nb,clearStats:()=>pE,convertToBigIntStats:()=>dE,makeDefaultStats:()=>Zf,makeEmptyStats:()=>Jfe});var ib=ie(require("util"));var _f=Vo|420,uO=class{constructor(){this.name="";this.mode=0}isBlockDevice(){return!1}isCharacterDevice(){return!1}isDirectory(){return(this.mode&kn)===zo}isFIFO(){return!1}isFile(){return(this.mode&kn)===Vo}isSocket(){return!1}isSymbolicLink(){return(this.mode&kn)===_o}},Za=class{constructor(){this.uid=0;this.gid=0;this.size=0;this.blksize=0;this.atimeMs=0;this.mtimeMs=0;this.ctimeMs=0;this.birthtimeMs=0;this.atime=new Date(0);this.mtime=new Date(0);this.ctime=new Date(0);this.birthtime=new Date(0);this.dev=0;this.ino=0;this.mode=_f;this.nlink=1;this.rdev=0;this.blocks=1}isBlockDevice(){return!1}isCharacterDevice(){return!1}isDirectory(){return(this.mode&kn)===zo}isFIFO(){return!1}isFile(){return(this.mode&kn)===Vo}isSocket(){return!1}isSymbolicLink(){return(this.mode&kn)===_o}},Xf=class{constructor(){this.uid=BigInt(0);this.gid=BigInt(0);this.size=BigInt(0);this.blksize=BigInt(0);this.atimeMs=BigInt(0);this.mtimeMs=BigInt(0);this.ctimeMs=BigInt(0);this.birthtimeMs=BigInt(0);this.atimeNs=BigInt(0);this.mtimeNs=BigInt(0);this.ctimeNs=BigInt(0);this.birthtimeNs=BigInt(0);this.atime=new Date(0);this.mtime=new Date(0);this.ctime=new Date(0);this.birthtime=new Date(0);this.dev=BigInt(0);this.ino=BigInt(0);this.mode=BigInt(_f);this.nlink=BigInt(1);this.rdev=BigInt(0);this.blocks=BigInt(1)}isBlockDevice(){return!1}isCharacterDevice(){return!1}isDirectory(){return(this.mode&BigInt(kn))===BigInt(zo)}isFIFO(){return!1}isFile(){return(this.mode&BigInt(kn))===BigInt(Vo)}isSocket(){return!1}isSymbolicLink(){return(this.mode&BigInt(kn))===BigInt(_o)}};function Zf(){return new Za}function Jfe(){return pE(Zf())}function pE(t){for(let e in t)if(Object.prototype.hasOwnProperty.call(t,e)){let r=t[e];typeof r=="number"?t[e]=0:typeof r=="bigint"?t[e]=BigInt(0):ib.types.isDate(r)&&(t[e]=new Date(0))}return t}function dE(t){let e=new Xf;for(let r in t)if(Object.prototype.hasOwnProperty.call(t,r)){let i=t[r];typeof i=="number"?e[r]=BigInt(i):ib.types.isDate(i)&&(e[r]=new Date(i))}return e.atimeNs=e.atimeMs*BigInt(1e6),e.mtimeNs=e.mtimeMs*BigInt(1e6),e.ctimeNs=e.ctimeMs*BigInt(1e6),e.birthtimeNs=e.birthtimeMs*BigInt(1e6),e}function nb(t,e){if(t.atimeMs!==e.atimeMs||t.birthtimeMs!==e.birthtimeMs||t.blksize!==e.blksize||t.blocks!==e.blocks||t.ctimeMs!==e.ctimeMs||t.dev!==e.dev||t.gid!==e.gid||t.ino!==e.ino||t.isBlockDevice()!==e.isBlockDevice()||t.isCharacterDevice()!==e.isCharacterDevice()||t.isDirectory()!==e.isDirectory()||t.isFIFO()!==e.isFIFO()||t.isFile()!==e.isFile()||t.isSocket()!==e.isSocket()||t.isSymbolicLink()!==e.isSymbolicLink()||t.mode!==e.mode||t.mtimeMs!==e.mtimeMs||t.nlink!==e.nlink||t.rdev!==e.rdev||t.size!==e.size||t.uid!==e.uid)return!1;let r=t,i=e;return!(r.atimeNs!==i.atimeNs||r.mtimeNs!==i.mtimeNs||r.ctimeNs!==i.ctimeNs||r.birthtimeNs!==i.birthtimeNs)}var mE=ie(require("fs"));var $f=ie(require("path")),gO;(function(i){i[i.File=0]="File",i[i.Portable=1]="Portable",i[i.Native=2]="Native"})(gO||(gO={}));var Se={root:"/",dot:"."},wt={nodeModules:"node_modules",manifest:"package.json",lockfile:"yarn.lock",virtual:"__virtual__",pnpJs:".pnp.js",pnpCjs:".pnp.cjs",rc:".yarnrc.yml"},M=Object.create($f.default),v=Object.create($f.default.posix);M.cwd=()=>process.cwd();v.cwd=()=>sb(process.cwd());v.resolve=(...t)=>t.length>0&&v.isAbsolute(t[0])?$f.default.posix.resolve(...t):$f.default.posix.resolve(v.cwd(),...t);var fO=function(t,e,r){return e=t.normalize(e),r=t.normalize(r),e===r?".":(e.endsWith(t.sep)||(e=e+t.sep),r.startsWith(e)?r.slice(e.length):null)};M.fromPortablePath=hO;M.toPortablePath=sb;M.contains=(t,e)=>fO(M,t,e);v.contains=(t,e)=>fO(v,t,e);var Wfe=/^([a-zA-Z]:.*)$/,zfe=/^\\\\(\.\\)?(.*)$/,Vfe=/^\/([a-zA-Z]:.*)$/,_fe=/^\/unc\/(\.dot\/)?(.*)$/;function hO(t){if(process.platform!=="win32")return t;let e,r;if(e=t.match(Vfe))t=e[1];else if(r=t.match(_fe))t=`\\\\${r[1]?".\\":""}${r[2]}`;else return t;return t.replace(/\//g,"\\")}function sb(t){if(process.platform!=="win32")return t;let e,r;return(e=t.match(Wfe))?t=`/${e[1]}`:(r=t.match(zfe))&&(t=`/unc/${r[1]?".dot/":""}${r[2]}`),t.replace(/\\/g,"/")}function CE(t,e){return t===M?hO(e):sb(e)}function kr(t){if(M.parse(t).dir!==""||v.parse(t).dir!=="")throw new Error(`Invalid filename: "${t}"`);return t}var EE=new Date(tb*1e3),eh;(function(r){r.Allow="allow",r.ReadOnly="readOnly"})(eh||(eh={}));async function pO(t,e,r,i,n){let s=t.pathUtils.normalize(e),o=r.pathUtils.normalize(i),a=[],l=[],c=n.stableTime?{mtime:EE,atime:EE}:await r.lstatPromise(o);await t.mkdirpPromise(t.pathUtils.dirname(e),{utimes:[c.atime,c.mtime]});let u=typeof t.lutimesPromise=="function"?t.lutimesPromise.bind(t):t.utimesPromise.bind(t);await ob(a,l,u,t,s,r,o,n);for(let g of a)await g();await Promise.all(l.map(g=>g()))}async function ob(t,e,r,i,n,s,o,a){var f,h;let l=await Xfe(i,n),c=await s.lstatPromise(o),u=a.stableTime?{mtime:EE,atime:EE}:c,g;switch(!0){case c.isDirectory():g=await Zfe(t,e,r,i,n,l,s,o,c,a);break;case c.isFile():g=await $fe(t,e,r,i,n,l,s,o,c,a);break;case c.isSymbolicLink():g=await ehe(t,e,r,i,n,l,s,o,c,a);break;default:throw new Error(`Unsupported file type (${c.mode})`)}return(g||((f=l==null?void 0:l.mtime)==null?void 0:f.getTime())!==u.mtime.getTime()||((h=l==null?void 0:l.atime)==null?void 0:h.getTime())!==u.atime.getTime())&&(e.push(()=>r(n,u.atime,u.mtime)),g=!0),(l===null||(l.mode&511)!=(c.mode&511))&&(e.push(()=>i.chmodPromise(n,c.mode&511)),g=!0),g}async function Xfe(t,e){try{return await t.lstatPromise(e)}catch(r){return null}}async function Zfe(t,e,r,i,n,s,o,a,l,c){if(s!==null&&!s.isDirectory())if(c.overwrite)t.push(async()=>i.removePromise(n)),s=null;else return!1;let u=!1;s===null&&(t.push(async()=>{try{await i.mkdirPromise(n,{mode:l.mode})}catch(f){if(f.code!=="EEXIST")throw f}}),u=!0);let g=await o.readdirPromise(a);if(c.stableSort)for(let f of g.sort())await ob(t,e,r,i,i.pathUtils.join(n,f),o,o.pathUtils.join(a,f),c)&&(u=!0);else(await Promise.all(g.map(async h=>{await ob(t,e,r,i,i.pathUtils.join(n,h),o,o.pathUtils.join(a,h),c)}))).some(h=>h)&&(u=!0);return u}var ab=new WeakMap;function Ab(t,e,r,i,n){return async()=>{await t.linkPromise(r,e),n===eh.ReadOnly&&(i.mode&=~146,await t.chmodPromise(e,i.mode))}}function the(t,e,r,i,n){let s=ab.get(t);return typeof s=="undefined"?async()=>{try{await t.copyFilePromise(r,e,mE.default.constants.COPYFILE_FICLONE_FORCE),ab.set(t,!0)}catch(o){if(o.code==="ENOSYS"||o.code==="ENOTSUP")ab.set(t,!1),await Ab(t,e,r,i,n)();else throw o}}:s?async()=>t.copyFilePromise(r,e,mE.default.constants.COPYFILE_FICLONE_FORCE):Ab(t,e,r,i,n)}async function $fe(t,e,r,i,n,s,o,a,l,c){var f;if(s!==null)if(c.overwrite)t.push(async()=>i.removePromise(n)),s=null;else return!1;let u=(f=c.linkStrategy)!=null?f:null,g=i===o?u!==null?the(i,n,a,l,u):async()=>i.copyFilePromise(a,n,mE.default.constants.COPYFILE_FICLONE):u!==null?Ab(i,n,a,l,u):async()=>i.writeFilePromise(n,await o.readFilePromise(a));return t.push(async()=>g()),!0}async function ehe(t,e,r,i,n,s,o,a,l,c){if(s!==null)if(c.overwrite)t.push(async()=>i.removePromise(n)),s=null;else return!1;return t.push(async()=>{await i.symlinkPromise(CE(i.pathUtils,await o.readlinkPromise(a)),n)}),!0}function qn(t,e){return Object.assign(new Error(`${t}: ${e}`),{code:t})}function IE(t){return qn("EBUSY",t)}function th(t,e){return qn("ENOSYS",`${t}, ${e}`)}function $a(t){return qn("EINVAL",`invalid argument, ${t}`)}function Hi(t){return qn("EBADF",`bad file descriptor, ${t}`)}function bs(t){return qn("ENOENT",`no such file or directory, ${t}`)}function eo(t){return qn("ENOTDIR",`not a directory, ${t}`)}function rh(t){return qn("EISDIR",`illegal operation on a directory, ${t}`)}function yE(t){return qn("EEXIST",`file already exists, ${t}`)}function ln(t){return qn("EROFS",`read-only filesystem, ${t}`)}function dO(t){return qn("ENOTEMPTY",`directory not empty, ${t}`)}function CO(t){return qn("EOPNOTSUPP",`operation not supported, ${t}`)}function mO(){return qn("ERR_DIR_CLOSED","Directory handle was closed")}var lb=class extends Error{constructor(e,r){super(e);this.name="Libzip Error",this.code=r}};var EO=class{constructor(e,r,i={}){this.path=e;this.nextDirent=r;this.opts=i;this.closed=!1}throwIfClosed(){if(this.closed)throw mO()}async*[Symbol.asyncIterator](){try{let e;for(;(e=await this.read())!==null;)yield e}finally{await this.close()}}read(e){let r=this.readSync();return typeof e!="undefined"?e(null,r):Promise.resolve(r)}readSync(){return this.throwIfClosed(),this.nextDirent()}close(e){return this.closeSync(),typeof e!="undefined"?e(null):Promise.resolve()}closeSync(){var e,r;this.throwIfClosed(),(r=(e=this.opts).onClose)==null||r.call(e),this.closed=!0}};function wE(t,e,r,i){let n=()=>{let s=r.shift();return typeof s=="undefined"?null:Object.assign(t.statSync(t.pathUtils.join(e,s)),{name:s})};return new EO(e,n,i)}var IO=ie(require("os"));var eA=class{constructor(e){this.pathUtils=e}async*genTraversePromise(e,{stableSort:r=!1}={}){let i=[e];for(;i.length>0;){let n=i.shift();if((await this.lstatPromise(n)).isDirectory()){let o=await this.readdirPromise(n);if(r)for(let a of o.sort())i.push(this.pathUtils.join(n,a));else throw new Error("Not supported")}else yield n}}async removePromise(e,{recursive:r=!0,maxRetries:i=5}={}){let n;try{n=await this.lstatPromise(e)}catch(s){if(s.code==="ENOENT")return;throw s}if(n.isDirectory()){if(r){let o=await this.readdirPromise(e);await Promise.all(o.map(a=>this.removePromise(this.pathUtils.resolve(e,a))))}let s=0;do try{await this.rmdirPromise(e);break}catch(o){if(o.code==="EBUSY"||o.code==="ENOTEMPTY"){if(i===0)break;await new Promise(a=>setTimeout(a,s*100));continue}else throw o}while(s++{let l;try{[l]=await this.readJsonPromise(i)}catch(c){return Date.now()-s<500}try{return process.kill(l,0),!0}catch(c){return!1}};for(;o===null;)try{o=await this.openPromise(i,"wx")}catch(l){if(l.code==="EEXIST"){if(!await a())try{await this.unlinkPromise(i);continue}catch(c){}if(Date.now()-s<60*1e3)await new Promise(c=>setTimeout(c,n));else throw new Error(`Couldn't acquire a lock in a reasonable time (via ${i})`)}else throw l}await this.writePromise(o,JSON.stringify([process.pid]));try{return await r()}finally{try{await this.closePromise(o),await this.unlinkPromise(i)}catch(l){}}}async readJsonPromise(e){let r=await this.readFilePromise(e,"utf8");try{return JSON.parse(r)}catch(i){throw i.message+=` (in ${e})`,i}}readJsonSync(e){let r=this.readFileSync(e,"utf8");try{return JSON.parse(r)}catch(i){throw i.message+=` (in ${e})`,i}}async writeJsonPromise(e,r){return await this.writeFilePromise(e,`${JSON.stringify(r,null,2)} -`)}writeJsonSync(e,r){return this.writeFileSync(e,`${JSON.stringify(r,null,2)} -`)}async preserveTimePromise(e,r){let i=await this.lstatPromise(e),n=await r();typeof n!="undefined"&&(e=n),this.lutimesPromise?await this.lutimesPromise(e,i.atime,i.mtime):i.isSymbolicLink()||await this.utimesPromise(e,i.atime,i.mtime)}async preserveTimeSync(e,r){let i=this.lstatSync(e),n=r();typeof n!="undefined"&&(e=n),this.lutimesSync?this.lutimesSync(e,i.atime,i.mtime):i.isSymbolicLink()||this.utimesSync(e,i.atime,i.mtime)}},gl=class extends eA{constructor(){super(v)}};function rhe(t){let e=t.match(/\r?\n/g);if(e===null)return IO.EOL;let r=e.filter(n=>n===`\r -`).length,i=e.length-r;return r>i?`\r -`:` -`}function ul(t,e){return e.replace(/\r?\n/g,rhe(t))}var $c=ie(require("fs")),cb=ie(require("stream")),QO=ie(require("util")),ub=ie(require("zlib"));var yO=ie(require("fs"));var Wt=class extends gl{constructor(e=yO.default){super();this.realFs=e,typeof this.realFs.lutimes!="undefined"&&(this.lutimesPromise=this.lutimesPromiseImpl,this.lutimesSync=this.lutimesSyncImpl)}getExtractHint(){return!1}getRealPath(){return Se.root}resolve(e){return v.resolve(e)}async openPromise(e,r,i){return await new Promise((n,s)=>{this.realFs.open(M.fromPortablePath(e),r,i,this.makeCallback(n,s))})}openSync(e,r,i){return this.realFs.openSync(M.fromPortablePath(e),r,i)}async opendirPromise(e,r){return await new Promise((i,n)=>{typeof r!="undefined"?this.realFs.opendir(M.fromPortablePath(e),r,this.makeCallback(i,n)):this.realFs.opendir(M.fromPortablePath(e),this.makeCallback(i,n))}).then(i=>Object.defineProperty(i,"path",{value:e,configurable:!0,writable:!0}))}opendirSync(e,r){let i=typeof r!="undefined"?this.realFs.opendirSync(M.fromPortablePath(e),r):this.realFs.opendirSync(M.fromPortablePath(e));return Object.defineProperty(i,"path",{value:e,configurable:!0,writable:!0})}async readPromise(e,r,i=0,n=0,s=-1){return await new Promise((o,a)=>{this.realFs.read(e,r,i,n,s,(l,c)=>{l?a(l):o(c)})})}readSync(e,r,i,n,s){return this.realFs.readSync(e,r,i,n,s)}async writePromise(e,r,i,n,s){return await new Promise((o,a)=>typeof r=="string"?this.realFs.write(e,r,i,this.makeCallback(o,a)):this.realFs.write(e,r,i,n,s,this.makeCallback(o,a)))}writeSync(e,r,i,n,s){return typeof r=="string"?this.realFs.writeSync(e,r,i):this.realFs.writeSync(e,r,i,n,s)}async closePromise(e){await new Promise((r,i)=>{this.realFs.close(e,this.makeCallback(r,i))})}closeSync(e){this.realFs.closeSync(e)}createReadStream(e,r){let i=e!==null?M.fromPortablePath(e):e;return this.realFs.createReadStream(i,r)}createWriteStream(e,r){let i=e!==null?M.fromPortablePath(e):e;return this.realFs.createWriteStream(i,r)}async realpathPromise(e){return await new Promise((r,i)=>{this.realFs.realpath(M.fromPortablePath(e),{},this.makeCallback(r,i))}).then(r=>M.toPortablePath(r))}realpathSync(e){return M.toPortablePath(this.realFs.realpathSync(M.fromPortablePath(e),{}))}async existsPromise(e){return await new Promise(r=>{this.realFs.exists(M.fromPortablePath(e),r)})}accessSync(e,r){return this.realFs.accessSync(M.fromPortablePath(e),r)}async accessPromise(e,r){return await new Promise((i,n)=>{this.realFs.access(M.fromPortablePath(e),r,this.makeCallback(i,n))})}existsSync(e){return this.realFs.existsSync(M.fromPortablePath(e))}async statPromise(e,r){return await new Promise((i,n)=>{r?this.realFs.stat(M.fromPortablePath(e),r,this.makeCallback(i,n)):this.realFs.stat(M.fromPortablePath(e),this.makeCallback(i,n))})}statSync(e,r){return r?this.realFs.statSync(M.fromPortablePath(e),r):this.realFs.statSync(M.fromPortablePath(e))}async fstatPromise(e,r){return await new Promise((i,n)=>{r?this.realFs.fstat(e,r,this.makeCallback(i,n)):this.realFs.fstat(e,this.makeCallback(i,n))})}fstatSync(e,r){return r?this.realFs.fstatSync(e,r):this.realFs.fstatSync(e)}async lstatPromise(e,r){return await new Promise((i,n)=>{r?this.realFs.lstat(M.fromPortablePath(e),r,this.makeCallback(i,n)):this.realFs.lstat(M.fromPortablePath(e),this.makeCallback(i,n))})}lstatSync(e,r){return r?this.realFs.lstatSync(M.fromPortablePath(e),r):this.realFs.lstatSync(M.fromPortablePath(e))}async chmodPromise(e,r){return await new Promise((i,n)=>{this.realFs.chmod(M.fromPortablePath(e),r,this.makeCallback(i,n))})}chmodSync(e,r){return this.realFs.chmodSync(M.fromPortablePath(e),r)}async chownPromise(e,r,i){return await new Promise((n,s)=>{this.realFs.chown(M.fromPortablePath(e),r,i,this.makeCallback(n,s))})}chownSync(e,r,i){return this.realFs.chownSync(M.fromPortablePath(e),r,i)}async renamePromise(e,r){return await new Promise((i,n)=>{this.realFs.rename(M.fromPortablePath(e),M.fromPortablePath(r),this.makeCallback(i,n))})}renameSync(e,r){return this.realFs.renameSync(M.fromPortablePath(e),M.fromPortablePath(r))}async copyFilePromise(e,r,i=0){return await new Promise((n,s)=>{this.realFs.copyFile(M.fromPortablePath(e),M.fromPortablePath(r),i,this.makeCallback(n,s))})}copyFileSync(e,r,i=0){return this.realFs.copyFileSync(M.fromPortablePath(e),M.fromPortablePath(r),i)}async appendFilePromise(e,r,i){return await new Promise((n,s)=>{let o=typeof e=="string"?M.fromPortablePath(e):e;i?this.realFs.appendFile(o,r,i,this.makeCallback(n,s)):this.realFs.appendFile(o,r,this.makeCallback(n,s))})}appendFileSync(e,r,i){let n=typeof e=="string"?M.fromPortablePath(e):e;i?this.realFs.appendFileSync(n,r,i):this.realFs.appendFileSync(n,r)}async writeFilePromise(e,r,i){return await new Promise((n,s)=>{let o=typeof e=="string"?M.fromPortablePath(e):e;i?this.realFs.writeFile(o,r,i,this.makeCallback(n,s)):this.realFs.writeFile(o,r,this.makeCallback(n,s))})}writeFileSync(e,r,i){let n=typeof e=="string"?M.fromPortablePath(e):e;i?this.realFs.writeFileSync(n,r,i):this.realFs.writeFileSync(n,r)}async unlinkPromise(e){return await new Promise((r,i)=>{this.realFs.unlink(M.fromPortablePath(e),this.makeCallback(r,i))})}unlinkSync(e){return this.realFs.unlinkSync(M.fromPortablePath(e))}async utimesPromise(e,r,i){return await new Promise((n,s)=>{this.realFs.utimes(M.fromPortablePath(e),r,i,this.makeCallback(n,s))})}utimesSync(e,r,i){this.realFs.utimesSync(M.fromPortablePath(e),r,i)}async lutimesPromiseImpl(e,r,i){let n=this.realFs.lutimes;if(typeof n=="undefined")throw th("unavailable Node binding",`lutimes '${e}'`);return await new Promise((s,o)=>{n.call(this.realFs,M.fromPortablePath(e),r,i,this.makeCallback(s,o))})}lutimesSyncImpl(e,r,i){let n=this.realFs.lutimesSync;if(typeof n=="undefined")throw th("unavailable Node binding",`lutimes '${e}'`);n.call(this.realFs,M.fromPortablePath(e),r,i)}async mkdirPromise(e,r){return await new Promise((i,n)=>{this.realFs.mkdir(M.fromPortablePath(e),r,this.makeCallback(i,n))})}mkdirSync(e,r){return this.realFs.mkdirSync(M.fromPortablePath(e),r)}async rmdirPromise(e,r){return await new Promise((i,n)=>{r?this.realFs.rmdir(M.fromPortablePath(e),r,this.makeCallback(i,n)):this.realFs.rmdir(M.fromPortablePath(e),this.makeCallback(i,n))})}rmdirSync(e,r){return this.realFs.rmdirSync(M.fromPortablePath(e),r)}async linkPromise(e,r){return await new Promise((i,n)=>{this.realFs.link(M.fromPortablePath(e),M.fromPortablePath(r),this.makeCallback(i,n))})}linkSync(e,r){return this.realFs.linkSync(M.fromPortablePath(e),M.fromPortablePath(r))}async symlinkPromise(e,r,i){return await new Promise((n,s)=>{this.realFs.symlink(M.fromPortablePath(e.replace(/\/+$/,"")),M.fromPortablePath(r),i,this.makeCallback(n,s))})}symlinkSync(e,r,i){return this.realFs.symlinkSync(M.fromPortablePath(e.replace(/\/+$/,"")),M.fromPortablePath(r),i)}async readFilePromise(e,r){return await new Promise((i,n)=>{let s=typeof e=="string"?M.fromPortablePath(e):e;this.realFs.readFile(s,r,this.makeCallback(i,n))})}readFileSync(e,r){let i=typeof e=="string"?M.fromPortablePath(e):e;return this.realFs.readFileSync(i,r)}async readdirPromise(e,r){return await new Promise((i,n)=>{(r==null?void 0:r.withFileTypes)?this.realFs.readdir(M.fromPortablePath(e),{withFileTypes:!0},this.makeCallback(i,n)):this.realFs.readdir(M.fromPortablePath(e),this.makeCallback(s=>i(s),n))})}readdirSync(e,r){return(r==null?void 0:r.withFileTypes)?this.realFs.readdirSync(M.fromPortablePath(e),{withFileTypes:!0}):this.realFs.readdirSync(M.fromPortablePath(e))}async readlinkPromise(e){return await new Promise((r,i)=>{this.realFs.readlink(M.fromPortablePath(e),this.makeCallback(r,i))}).then(r=>M.toPortablePath(r))}readlinkSync(e){return M.toPortablePath(this.realFs.readlinkSync(M.fromPortablePath(e)))}async truncatePromise(e,r){return await new Promise((i,n)=>{this.realFs.truncate(M.fromPortablePath(e),r,this.makeCallback(i,n))})}truncateSync(e,r){return this.realFs.truncateSync(M.fromPortablePath(e),r)}watch(e,r,i){return this.realFs.watch(M.fromPortablePath(e),r,i)}watchFile(e,r,i){return this.realFs.watchFile(M.fromPortablePath(e),r,i)}unwatchFile(e,r){return this.realFs.unwatchFile(M.fromPortablePath(e),r)}makeCallback(e,r){return(i,n)=>{i?r(i):e(n)}}};var wO=ie(require("events"));var fl;(function(r){r.Change="change",r.Stop="stop"})(fl||(fl={}));var hl;(function(i){i.Ready="ready",i.Running="running",i.Stopped="stopped"})(hl||(hl={}));function BO(t,e){if(t!==e)throw new Error(`Invalid StatWatcher status: expected '${e}', got '${t}'`)}var ih=class extends wO.EventEmitter{constructor(e,r,{bigint:i=!1}={}){super();this.status=hl.Ready;this.changeListeners=new Map;this.startTimeout=null;this.fakeFs=e,this.path=r,this.bigint=i,this.lastStats=this.stat()}static create(e,r,i){let n=new ih(e,r,i);return n.start(),n}start(){BO(this.status,hl.Ready),this.status=hl.Running,this.startTimeout=setTimeout(()=>{this.startTimeout=null,this.fakeFs.existsSync(this.path)||this.emit(fl.Change,this.lastStats,this.lastStats)},3)}stop(){BO(this.status,hl.Running),this.status=hl.Stopped,this.startTimeout!==null&&(clearTimeout(this.startTimeout),this.startTimeout=null),this.emit(fl.Stop)}stat(){try{return this.fakeFs.statSync(this.path,{bigint:this.bigint})}catch(e){let r=this.bigint?new Xf:new Za;return pE(r)}}makeInterval(e){let r=setInterval(()=>{let i=this.stat(),n=this.lastStats;nb(i,n)||(this.lastStats=i,this.emit(fl.Change,i,n))},e.interval);return e.persistent?r:r.unref()}registerChangeListener(e,r){this.addListener(fl.Change,e),this.changeListeners.set(e,this.makeInterval(r))}unregisterChangeListener(e){this.removeListener(fl.Change,e);let r=this.changeListeners.get(e);typeof r!="undefined"&&clearInterval(r),this.changeListeners.delete(e)}unregisterAllChangeListeners(){for(let e of this.changeListeners.keys())this.unregisterChangeListener(e)}hasChangeListeners(){return this.changeListeners.size>0}ref(){for(let e of this.changeListeners.values())e.ref();return this}unref(){for(let e of this.changeListeners.values())e.unref();return this}};var BE=new WeakMap;function QE(t,e,r,i){let n,s,o,a;switch(typeof r){case"function":n=!1,s=!0,o=5007,a=r;break;default:({bigint:n=!1,persistent:s=!0,interval:o=5007}=r),a=i;break}let l=BE.get(t);typeof l=="undefined"&&BE.set(t,l=new Map);let c=l.get(e);return typeof c=="undefined"&&(c=ih.create(t,e,{bigint:n}),l.set(e,c)),c.registerChangeListener(a,{persistent:s,interval:o}),c}function nh(t,e,r){let i=BE.get(t);if(typeof i=="undefined")return;let n=i.get(e);typeof n!="undefined"&&(typeof r=="undefined"?n.unregisterAllChangeListeners():n.unregisterChangeListener(r),n.hasChangeListeners()||(n.stop(),i.delete(e)))}function sh(t){let e=BE.get(t);if(typeof e!="undefined")for(let r of e.keys())nh(t,r)}var pl="mixed";function ihe(t){if(typeof t=="string"&&String(+t)===t)return+t;if(Number.isFinite(t))return t<0?Date.now()/1e3:t;if((0,QO.isDate)(t))return t.getTime()/1e3;throw new Error("Invalid time")}function bO(){return Buffer.from([80,75,5,6,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0])}var Jr=class extends gl{constructor(e,r){super();this.lzSource=null;this.listings=new Map;this.entries=new Map;this.fileSources=new Map;this.fds=new Map;this.nextFd=0;this.ready=!1;this.readOnly=!1;this.libzip=r.libzip;let i=r;if(this.level=typeof i.level!="undefined"?i.level:pl,e!=null||(e=bO()),typeof e=="string"){let{baseFs:o=new Wt}=i;this.baseFs=o,this.path=e}else this.path=null,this.baseFs=null;if(r.stats)this.stats=r.stats;else if(typeof e=="string")try{this.stats=this.baseFs.statSync(e)}catch(o){if(o.code==="ENOENT"&&i.create)this.stats=Zf();else throw o}else this.stats=Zf();let n=this.libzip.malloc(4);try{let o=0;if(typeof e=="string"&&i.create&&(o|=this.libzip.ZIP_CREATE|this.libzip.ZIP_TRUNCATE),r.readOnly&&(o|=this.libzip.ZIP_RDONLY,this.readOnly=!0),typeof e=="string")this.zip=this.libzip.open(M.fromPortablePath(e),o,n);else{let a=this.allocateUnattachedSource(e);try{this.zip=this.libzip.openFromSource(a,o,n),this.lzSource=a}catch(l){throw this.libzip.source.free(a),l}}if(this.zip===0){let a=this.libzip.struct.errorS();throw this.libzip.error.initWithCode(a,this.libzip.getValue(n,"i32")),this.makeLibzipError(a)}}finally{this.libzip.free(n)}this.listings.set(Se.root,new Set);let s=this.libzip.getNumEntries(this.zip,0);for(let o=0;oe)throw new Error("Overread");let n=this.libzip.HEAPU8.subarray(r,r+e);return Buffer.from(n)}finally{this.libzip.free(r)}}finally{this.libzip.source.close(this.lzSource),this.libzip.source.free(this.lzSource),this.ready=!1}}prepareClose(){if(!this.ready)throw IE("archive closed, close");sh(this)}saveAndClose(){if(!this.path||!this.baseFs)throw new Error("ZipFS cannot be saved and must be discarded when loaded from a buffer");if(this.prepareClose(),this.readOnly){this.discardAndClose();return}let e=this.baseFs.existsSync(this.path)||this.stats.mode===_f?void 0:this.stats.mode;if(this.entries.size===0)this.discardAndClose(),this.baseFs.writeFileSync(this.path,bO(),{mode:e});else{if(this.libzip.close(this.zip)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));typeof e!="undefined"&&this.baseFs.chmodSync(this.path,e)}this.ready=!1}discardAndClose(){this.prepareClose(),this.libzip.discard(this.zip),this.ready=!1}resolve(e){return v.resolve(Se.root,e)}async openPromise(e,r,i){return this.openSync(e,r,i)}openSync(e,r,i){let n=this.nextFd++;return this.fds.set(n,{cursor:0,p:e}),n}hasOpenFileHandles(){return!!this.fds.size}async opendirPromise(e,r){return this.opendirSync(e,r)}opendirSync(e,r={}){let i=this.resolveFilename(`opendir '${e}'`,e);if(!this.entries.has(i)&&!this.listings.has(i))throw bs(`opendir '${e}'`);let n=this.listings.get(i);if(!n)throw eo(`opendir '${e}'`);let s=[...n],o=this.openSync(i,"r");return wE(this,i,s,{onClose:()=>{this.closeSync(o)}})}async readPromise(e,r,i,n,s){return this.readSync(e,r,i,n,s)}readSync(e,r,i=0,n=r.byteLength,s=-1){let o=this.fds.get(e);if(typeof o=="undefined")throw Hi("read");let a;s===-1||s===null?a=o.cursor:a=s;let l=this.readFileSync(o.p);l.copy(r,i,a,a+n);let c=Math.max(0,Math.min(l.length-a,n));return(s===-1||s===null)&&(o.cursor+=c),c}async writePromise(e,r,i,n,s){return typeof r=="string"?this.writeSync(e,r,s):this.writeSync(e,r,i,n,s)}writeSync(e,r,i,n,s){throw typeof this.fds.get(e)=="undefined"?Hi("read"):new Error("Unimplemented")}async closePromise(e){return this.closeSync(e)}closeSync(e){if(typeof this.fds.get(e)=="undefined")throw Hi("read");this.fds.delete(e)}createReadStream(e,{encoding:r}={}){if(e===null)throw new Error("Unimplemented");let i=this.openSync(e,"r"),n=Object.assign(new cb.PassThrough({emitClose:!0,autoDestroy:!0,destroy:(o,a)=>{clearImmediate(s),this.closeSync(i),a(o)}}),{close(){n.destroy()},bytesRead:0,path:e}),s=setImmediate(async()=>{try{let o=await this.readFilePromise(e,r);n.bytesRead=o.length,n.end(o)}catch(o){n.destroy(o)}});return n}createWriteStream(e,{encoding:r}={}){if(this.readOnly)throw ln(`open '${e}'`);if(e===null)throw new Error("Unimplemented");let i=[],n=this.openSync(e,"w"),s=Object.assign(new cb.PassThrough({autoDestroy:!0,emitClose:!0,destroy:(o,a)=>{try{o?a(o):(this.writeFileSync(e,Buffer.concat(i),r),a(null))}catch(l){a(l)}finally{this.closeSync(n)}}}),{bytesWritten:0,path:e,close(){s.destroy()}});return s.on("data",o=>{let a=Buffer.from(o);s.bytesWritten+=a.length,i.push(a)}),s}async realpathPromise(e){return this.realpathSync(e)}realpathSync(e){let r=this.resolveFilename(`lstat '${e}'`,e);if(!this.entries.has(r)&&!this.listings.has(r))throw bs(`lstat '${e}'`);return r}async existsPromise(e){return this.existsSync(e)}existsSync(e){if(!this.ready)throw IE(`archive closed, existsSync '${e}'`);if(this.symlinkCount===0){let i=v.resolve(Se.root,e);return this.entries.has(i)||this.listings.has(i)}let r;try{r=this.resolveFilename(`stat '${e}'`,e)}catch(i){return!1}return this.entries.has(r)||this.listings.has(r)}async accessPromise(e,r){return this.accessSync(e,r)}accessSync(e,r=$c.constants.F_OK){let i=this.resolveFilename(`access '${e}'`,e);if(!this.entries.has(i)&&!this.listings.has(i))throw bs(`access '${e}'`);if(this.readOnly&&r&$c.constants.W_OK)throw ln(`access '${e}'`)}async statPromise(e,r){return this.statSync(e,r)}statSync(e,r){let i=this.resolveFilename(`stat '${e}'`,e);if(!this.entries.has(i)&&!this.listings.has(i))throw bs(`stat '${e}'`);if(e[e.length-1]==="/"&&!this.listings.has(i))throw eo(`stat '${e}'`);return this.statImpl(`stat '${e}'`,i,r)}async fstatPromise(e,r){return this.fstatSync(e,r)}fstatSync(e,r){let i=this.fds.get(e);if(typeof i=="undefined")throw Hi("fstatSync");let{p:n}=i,s=this.resolveFilename(`stat '${n}'`,n);if(!this.entries.has(s)&&!this.listings.has(s))throw bs(`stat '${n}'`);if(n[n.length-1]==="/"&&!this.listings.has(s))throw eo(`stat '${n}'`);return this.statImpl(`fstat '${n}'`,s,r)}async lstatPromise(e,r){return this.lstatSync(e,r)}lstatSync(e,r){let i=this.resolveFilename(`lstat '${e}'`,e,!1);if(!this.entries.has(i)&&!this.listings.has(i))throw bs(`lstat '${e}'`);if(e[e.length-1]==="/"&&!this.listings.has(i))throw eo(`lstat '${e}'`);return this.statImpl(`lstat '${e}'`,i,r)}statImpl(e,r,i={}){let n=this.entries.get(r);if(typeof n!="undefined"){let s=this.libzip.struct.statS();if(this.libzip.statIndex(this.zip,n,0,0,s)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));let a=this.stats.uid,l=this.stats.gid,c=this.libzip.struct.statSize(s)>>>0,u=512,g=Math.ceil(c/u),f=(this.libzip.struct.statMtime(s)>>>0)*1e3,h=f,p=f,d=f,m=new Date(h),I=new Date(p),B=new Date(d),b=new Date(f),R=this.listings.has(r)?zo:this.isSymbolicLink(n)?_o:Vo,H=R===zo?493:420,L=R|this.getUnixMode(n,H)&511,K=this.libzip.struct.statCrc(s),J=Object.assign(new Za,{uid:a,gid:l,size:c,blksize:u,blocks:g,atime:m,birthtime:I,ctime:B,mtime:b,atimeMs:h,birthtimeMs:p,ctimeMs:d,mtimeMs:f,mode:L,crc:K});return i.bigint===!0?dE(J):J}if(this.listings.has(r)){let s=this.stats.uid,o=this.stats.gid,a=0,l=512,c=0,u=this.stats.mtimeMs,g=this.stats.mtimeMs,f=this.stats.mtimeMs,h=this.stats.mtimeMs,p=new Date(u),d=new Date(g),m=new Date(f),I=new Date(h),B=zo|493,b=0,R=Object.assign(new Za,{uid:s,gid:o,size:a,blksize:l,blocks:c,atime:p,birthtime:d,ctime:m,mtime:I,atimeMs:u,birthtimeMs:g,ctimeMs:f,mtimeMs:h,mode:B,crc:b});return i.bigint===!0?dE(R):R}throw new Error("Unreachable")}getUnixMode(e,r){if(this.libzip.file.getExternalAttributes(this.zip,e,0,0,this.libzip.uint08S,this.libzip.uint32S)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));return this.libzip.getValue(this.libzip.uint08S,"i8")>>>0!==this.libzip.ZIP_OPSYS_UNIX?r:this.libzip.getValue(this.libzip.uint32S,"i32")>>>16}registerListing(e){let r=this.listings.get(e);if(r)return r;let i=this.registerListing(v.dirname(e));return r=new Set,i.add(v.basename(e)),this.listings.set(e,r),r}registerEntry(e,r){this.registerListing(v.dirname(e)).add(v.basename(e)),this.entries.set(e,r)}unregisterListing(e){this.listings.delete(e);let r=this.listings.get(v.dirname(e));r==null||r.delete(v.basename(e))}unregisterEntry(e){this.unregisterListing(e);let r=this.entries.get(e);this.entries.delete(e),typeof r!="undefined"&&(this.fileSources.delete(r),this.isSymbolicLink(r)&&this.symlinkCount--)}deleteEntry(e,r){if(this.unregisterEntry(e),this.libzip.delete(this.zip,r)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip))}resolveFilename(e,r,i=!0){if(!this.ready)throw IE(`archive closed, ${e}`);let n=v.resolve(Se.root,r);if(n==="/")return Se.root;let s=this.entries.get(n);if(i&&s!==void 0)if(this.symlinkCount!==0&&this.isSymbolicLink(s)){let o=this.getFileSource(s).toString();return this.resolveFilename(e,v.resolve(v.dirname(n),o),!0)}else return n;for(;;){let o=this.resolveFilename(e,v.dirname(n),!0),a=this.listings.has(o),l=this.entries.has(o);if(!a&&!l)throw bs(e);if(!a)throw eo(e);if(n=v.resolve(o,v.basename(n)),!i||this.symlinkCount===0)break;let c=this.libzip.name.locate(this.zip,n.slice(1));if(c===-1)break;if(this.isSymbolicLink(c)){let u=this.getFileSource(c).toString();n=v.resolve(v.dirname(n),u)}else break}return n}allocateBuffer(e){Buffer.isBuffer(e)||(e=Buffer.from(e));let r=this.libzip.malloc(e.byteLength);if(!r)throw new Error("Couldn't allocate enough memory");return new Uint8Array(this.libzip.HEAPU8.buffer,r,e.byteLength).set(e),{buffer:r,byteLength:e.byteLength}}allocateUnattachedSource(e){let r=this.libzip.struct.errorS(),{buffer:i,byteLength:n}=this.allocateBuffer(e),s=this.libzip.source.fromUnattachedBuffer(i,n,0,!0,r);if(s===0)throw this.libzip.free(r),this.makeLibzipError(r);return s}allocateSource(e){let{buffer:r,byteLength:i}=this.allocateBuffer(e),n=this.libzip.source.fromBuffer(this.zip,r,i,0,!0);if(n===0)throw this.libzip.free(r),this.makeLibzipError(this.libzip.getError(this.zip));return n}setFileSource(e,r){let i=Buffer.isBuffer(r)?r:Buffer.from(r),n=v.relative(Se.root,e),s=this.allocateSource(r);try{let o=this.libzip.file.add(this.zip,n,s,this.libzip.ZIP_FL_OVERWRITE);if(o===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));if(this.level!=="mixed"){let a;if(this.level===0?a=this.libzip.ZIP_CM_STORE:a=this.libzip.ZIP_CM_DEFLATE,this.libzip.file.setCompression(this.zip,o,0,a,this.level)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip))}return this.fileSources.set(o,i),o}catch(o){throw this.libzip.source.free(s),o}}isSymbolicLink(e){if(this.symlinkCount===0)return!1;if(this.libzip.file.getExternalAttributes(this.zip,e,0,0,this.libzip.uint08S,this.libzip.uint32S)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));return this.libzip.getValue(this.libzip.uint08S,"i8")>>>0!==this.libzip.ZIP_OPSYS_UNIX?!1:(this.libzip.getValue(this.libzip.uint32S,"i32")>>>16&kn)===_o}getFileSource(e,r={asyncDecompress:!1}){let i=this.fileSources.get(e);if(typeof i!="undefined")return i;let n=this.libzip.struct.statS();if(this.libzip.statIndex(this.zip,e,0,0,n)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));let o=this.libzip.struct.statCompSize(n),a=this.libzip.struct.statCompMethod(n),l=this.libzip.malloc(o);try{let c=this.libzip.fopenIndex(this.zip,e,0,this.libzip.ZIP_FL_COMPRESSED);if(c===0)throw this.makeLibzipError(this.libzip.getError(this.zip));try{let u=this.libzip.fread(c,l,o,0);if(u===-1)throw this.makeLibzipError(this.libzip.file.getError(c));if(uo)throw new Error("Overread");let g=this.libzip.HEAPU8.subarray(l,l+o),f=Buffer.from(g);if(a===0)return this.fileSources.set(e,f),f;if(r.asyncDecompress)return new Promise((h,p)=>{ub.default.inflateRaw(f,(d,m)=>{d?p(d):(this.fileSources.set(e,m),h(m))})});{let h=ub.default.inflateRawSync(f);return this.fileSources.set(e,h),h}}finally{this.libzip.fclose(c)}}finally{this.libzip.free(l)}}async chmodPromise(e,r){return this.chmodSync(e,r)}chmodSync(e,r){if(this.readOnly)throw ln(`chmod '${e}'`);r&=493;let i=this.resolveFilename(`chmod '${e}'`,e,!1),n=this.entries.get(i);if(typeof n=="undefined")throw new Error(`Assertion failed: The entry should have been registered (${i})`);let o=this.getUnixMode(n,Vo|0)&~511|r;if(this.libzip.file.setExternalAttributes(this.zip,n,0,0,this.libzip.ZIP_OPSYS_UNIX,o<<16)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip))}async chownPromise(e,r,i){return this.chownSync(e,r,i)}chownSync(e,r,i){throw new Error("Unimplemented")}async renamePromise(e,r){return this.renameSync(e,r)}renameSync(e,r){throw new Error("Unimplemented")}async copyFilePromise(e,r,i){let{indexSource:n,indexDest:s,resolvedDestP:o}=this.prepareCopyFile(e,r,i),a=await this.getFileSource(n,{asyncDecompress:!0}),l=this.setFileSource(o,a);l!==s&&this.registerEntry(o,l)}copyFileSync(e,r,i=0){let{indexSource:n,indexDest:s,resolvedDestP:o}=this.prepareCopyFile(e,r,i),a=this.getFileSource(n),l=this.setFileSource(o,a);l!==s&&this.registerEntry(o,l)}prepareCopyFile(e,r,i=0){if(this.readOnly)throw ln(`copyfile '${e} -> '${r}'`);if((i&$c.constants.COPYFILE_FICLONE_FORCE)!=0)throw th("unsupported clone operation",`copyfile '${e}' -> ${r}'`);let n=this.resolveFilename(`copyfile '${e} -> ${r}'`,e),s=this.entries.get(n);if(typeof s=="undefined")throw $a(`copyfile '${e}' -> '${r}'`);let o=this.resolveFilename(`copyfile '${e}' -> ${r}'`,r),a=this.entries.get(o);if((i&($c.constants.COPYFILE_EXCL|$c.constants.COPYFILE_FICLONE_FORCE))!=0&&typeof a!="undefined")throw yE(`copyfile '${e}' -> '${r}'`);return{indexSource:s,resolvedDestP:o,indexDest:a}}async appendFilePromise(e,r,i){if(this.readOnly)throw ln(`open '${e}'`);return typeof i=="undefined"?i={flag:"a"}:typeof i=="string"?i={flag:"a",encoding:i}:typeof i.flag=="undefined"&&(i=P({flag:"a"},i)),this.writeFilePromise(e,r,i)}appendFileSync(e,r,i={}){if(this.readOnly)throw ln(`open '${e}'`);return typeof i=="undefined"?i={flag:"a"}:typeof i=="string"?i={flag:"a",encoding:i}:typeof i.flag=="undefined"&&(i=P({flag:"a"},i)),this.writeFileSync(e,r,i)}fdToPath(e,r){var n;let i=(n=this.fds.get(e))==null?void 0:n.p;if(typeof i=="undefined")throw Hi(r);return i}async writeFilePromise(e,r,i){let{encoding:n,mode:s,index:o,resolvedP:a}=this.prepareWriteFile(e,i);o!==void 0&&typeof i=="object"&&i.flag&&i.flag.includes("a")&&(r=Buffer.concat([await this.getFileSource(o,{asyncDecompress:!0}),Buffer.from(r)])),n!==null&&(r=r.toString(n));let l=this.setFileSource(a,r);l!==o&&this.registerEntry(a,l),s!==null&&await this.chmodPromise(a,s)}writeFileSync(e,r,i){let{encoding:n,mode:s,index:o,resolvedP:a}=this.prepareWriteFile(e,i);o!==void 0&&typeof i=="object"&&i.flag&&i.flag.includes("a")&&(r=Buffer.concat([this.getFileSource(o),Buffer.from(r)])),n!==null&&(r=r.toString(n));let l=this.setFileSource(a,r);l!==o&&this.registerEntry(a,l),s!==null&&this.chmodSync(a,s)}prepareWriteFile(e,r){if(typeof e=="number"&&(e=this.fdToPath(e,"read")),this.readOnly)throw ln(`open '${e}'`);let i=this.resolveFilename(`open '${e}'`,e);if(this.listings.has(i))throw rh(`open '${e}'`);let n=null,s=null;typeof r=="string"?n=r:typeof r=="object"&&({encoding:n=null,mode:s=null}=r);let o=this.entries.get(i);return{encoding:n,mode:s,resolvedP:i,index:o}}async unlinkPromise(e){return this.unlinkSync(e)}unlinkSync(e){if(this.readOnly)throw ln(`unlink '${e}'`);let r=this.resolveFilename(`unlink '${e}'`,e);if(this.listings.has(r))throw rh(`unlink '${e}'`);let i=this.entries.get(r);if(typeof i=="undefined")throw $a(`unlink '${e}'`);this.deleteEntry(r,i)}async utimesPromise(e,r,i){return this.utimesSync(e,r,i)}utimesSync(e,r,i){if(this.readOnly)throw ln(`utimes '${e}'`);let n=this.resolveFilename(`utimes '${e}'`,e);this.utimesImpl(n,i)}async lutimesPromise(e,r,i){return this.lutimesSync(e,r,i)}lutimesSync(e,r,i){if(this.readOnly)throw ln(`lutimes '${e}'`);let n=this.resolveFilename(`utimes '${e}'`,e,!1);this.utimesImpl(n,i)}utimesImpl(e,r){this.listings.has(e)&&(this.entries.has(e)||this.hydrateDirectory(e));let i=this.entries.get(e);if(i===void 0)throw new Error("Unreachable");if(this.libzip.file.setMtime(this.zip,i,0,ihe(r),0)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip))}async mkdirPromise(e,r){return this.mkdirSync(e,r)}mkdirSync(e,{mode:r=493,recursive:i=!1}={}){if(i){this.mkdirpSync(e,{chmod:r});return}if(this.readOnly)throw ln(`mkdir '${e}'`);let n=this.resolveFilename(`mkdir '${e}'`,e);if(this.entries.has(n)||this.listings.has(n))throw yE(`mkdir '${e}'`);this.hydrateDirectory(n),this.chmodSync(n,r)}async rmdirPromise(e,r){return this.rmdirSync(e,r)}rmdirSync(e,{recursive:r=!1}={}){if(this.readOnly)throw ln(`rmdir '${e}'`);if(r){this.removeSync(e);return}let i=this.resolveFilename(`rmdir '${e}'`,e),n=this.listings.get(i);if(!n)throw eo(`rmdir '${e}'`);if(n.size>0)throw dO(`rmdir '${e}'`);let s=this.entries.get(i);if(typeof s=="undefined")throw $a(`rmdir '${e}'`);this.deleteEntry(e,s)}hydrateDirectory(e){let r=this.libzip.dir.add(this.zip,v.relative(Se.root,e));if(r===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));return this.registerListing(e),this.registerEntry(e,r),r}async linkPromise(e,r){return this.linkSync(e,r)}linkSync(e,r){throw CO(`link '${e}' -> '${r}'`)}async symlinkPromise(e,r){return this.symlinkSync(e,r)}symlinkSync(e,r){if(this.readOnly)throw ln(`symlink '${e}' -> '${r}'`);let i=this.resolveFilename(`symlink '${e}' -> '${r}'`,r);if(this.listings.has(i))throw rh(`symlink '${e}' -> '${r}'`);if(this.entries.has(i))throw yE(`symlink '${e}' -> '${r}'`);let n=this.setFileSource(i,e);if(this.registerEntry(i,n),this.libzip.file.setExternalAttributes(this.zip,n,0,0,this.libzip.ZIP_OPSYS_UNIX,(_o|511)<<16)===-1)throw this.makeLibzipError(this.libzip.getError(this.zip));this.symlinkCount+=1}async readFilePromise(e,r){typeof r=="object"&&(r=r?r.encoding:void 0);let i=await this.readFileBuffer(e,{asyncDecompress:!0});return r?i.toString(r):i}readFileSync(e,r){typeof r=="object"&&(r=r?r.encoding:void 0);let i=this.readFileBuffer(e);return r?i.toString(r):i}readFileBuffer(e,r={asyncDecompress:!1}){typeof e=="number"&&(e=this.fdToPath(e,"read"));let i=this.resolveFilename(`open '${e}'`,e);if(!this.entries.has(i)&&!this.listings.has(i))throw bs(`open '${e}'`);if(e[e.length-1]==="/"&&!this.listings.has(i))throw eo(`open '${e}'`);if(this.listings.has(i))throw rh("read");let n=this.entries.get(i);if(n===void 0)throw new Error("Unreachable");return this.getFileSource(n,r)}async readdirPromise(e,r){return this.readdirSync(e,r)}readdirSync(e,r){let i=this.resolveFilename(`scandir '${e}'`,e);if(!this.entries.has(i)&&!this.listings.has(i))throw bs(`scandir '${e}'`);let n=this.listings.get(i);if(!n)throw eo(`scandir '${e}'`);let s=[...n];return(r==null?void 0:r.withFileTypes)?s.map(o=>Object.assign(this.statImpl("lstat",v.join(e,o)),{name:o})):s}async readlinkPromise(e){let r=this.prepareReadlink(e);return(await this.getFileSource(r,{asyncDecompress:!0})).toString()}readlinkSync(e){let r=this.prepareReadlink(e);return this.getFileSource(r).toString()}prepareReadlink(e){let r=this.resolveFilename(`readlink '${e}'`,e,!1);if(!this.entries.has(r)&&!this.listings.has(r))throw bs(`readlink '${e}'`);if(e[e.length-1]==="/"&&!this.listings.has(r))throw eo(`open '${e}'`);if(this.listings.has(r))throw $a(`readlink '${e}'`);let i=this.entries.get(r);if(i===void 0)throw new Error("Unreachable");if(!this.isSymbolicLink(i))throw $a(`readlink '${e}'`);return i}async truncatePromise(e,r=0){let i=this.resolveFilename(`open '${e}'`,e),n=this.entries.get(i);if(typeof n=="undefined")throw $a(`open '${e}'`);let s=await this.getFileSource(n,{asyncDecompress:!0}),o=Buffer.alloc(r,0);return s.copy(o),await this.writeFilePromise(e,o)}truncateSync(e,r=0){let i=this.resolveFilename(`open '${e}'`,e),n=this.entries.get(i);if(typeof n=="undefined")throw $a(`open '${e}'`);let s=this.getFileSource(n),o=Buffer.alloc(r,0);return s.copy(o),this.writeFileSync(e,o)}watch(e,r,i){let n;switch(typeof r){case"function":case"string":case"undefined":n=!0;break;default:({persistent:n=!0}=r);break}if(!n)return{on:()=>{},close:()=>{}};let s=setInterval(()=>{},24*60*60*1e3);return{on:()=>{},close:()=>{clearInterval(s)}}}watchFile(e,r,i){let n=v.resolve(Se.root,e);return QE(this,n,r,i)}unwatchFile(e,r){let i=v.resolve(Se.root,e);return nh(this,i,r)}};var fi=class extends eA{getExtractHint(e){return this.baseFs.getExtractHint(e)}resolve(e){return this.mapFromBase(this.baseFs.resolve(this.mapToBase(e)))}getRealPath(){return this.mapFromBase(this.baseFs.getRealPath())}async openPromise(e,r,i){return this.baseFs.openPromise(this.mapToBase(e),r,i)}openSync(e,r,i){return this.baseFs.openSync(this.mapToBase(e),r,i)}async opendirPromise(e,r){return Object.assign(await this.baseFs.opendirPromise(this.mapToBase(e),r),{path:e})}opendirSync(e,r){return Object.assign(this.baseFs.opendirSync(this.mapToBase(e),r),{path:e})}async readPromise(e,r,i,n,s){return await this.baseFs.readPromise(e,r,i,n,s)}readSync(e,r,i,n,s){return this.baseFs.readSync(e,r,i,n,s)}async writePromise(e,r,i,n,s){return typeof r=="string"?await this.baseFs.writePromise(e,r,i):await this.baseFs.writePromise(e,r,i,n,s)}writeSync(e,r,i,n,s){return typeof r=="string"?this.baseFs.writeSync(e,r,i):this.baseFs.writeSync(e,r,i,n,s)}async closePromise(e){return this.baseFs.closePromise(e)}closeSync(e){this.baseFs.closeSync(e)}createReadStream(e,r){return this.baseFs.createReadStream(e!==null?this.mapToBase(e):e,r)}createWriteStream(e,r){return this.baseFs.createWriteStream(e!==null?this.mapToBase(e):e,r)}async realpathPromise(e){return this.mapFromBase(await this.baseFs.realpathPromise(this.mapToBase(e)))}realpathSync(e){return this.mapFromBase(this.baseFs.realpathSync(this.mapToBase(e)))}async existsPromise(e){return this.baseFs.existsPromise(this.mapToBase(e))}existsSync(e){return this.baseFs.existsSync(this.mapToBase(e))}accessSync(e,r){return this.baseFs.accessSync(this.mapToBase(e),r)}async accessPromise(e,r){return this.baseFs.accessPromise(this.mapToBase(e),r)}async statPromise(e,r){return this.baseFs.statPromise(this.mapToBase(e),r)}statSync(e,r){return this.baseFs.statSync(this.mapToBase(e),r)}async fstatPromise(e,r){return this.baseFs.fstatPromise(e,r)}fstatSync(e,r){return this.baseFs.fstatSync(e,r)}async lstatPromise(e,r){return this.baseFs.lstatPromise(this.mapToBase(e),r)}lstatSync(e,r){return this.baseFs.lstatSync(this.mapToBase(e),r)}async chmodPromise(e,r){return this.baseFs.chmodPromise(this.mapToBase(e),r)}chmodSync(e,r){return this.baseFs.chmodSync(this.mapToBase(e),r)}async chownPromise(e,r,i){return this.baseFs.chownPromise(this.mapToBase(e),r,i)}chownSync(e,r,i){return this.baseFs.chownSync(this.mapToBase(e),r,i)}async renamePromise(e,r){return this.baseFs.renamePromise(this.mapToBase(e),this.mapToBase(r))}renameSync(e,r){return this.baseFs.renameSync(this.mapToBase(e),this.mapToBase(r))}async copyFilePromise(e,r,i=0){return this.baseFs.copyFilePromise(this.mapToBase(e),this.mapToBase(r),i)}copyFileSync(e,r,i=0){return this.baseFs.copyFileSync(this.mapToBase(e),this.mapToBase(r),i)}async appendFilePromise(e,r,i){return this.baseFs.appendFilePromise(this.fsMapToBase(e),r,i)}appendFileSync(e,r,i){return this.baseFs.appendFileSync(this.fsMapToBase(e),r,i)}async writeFilePromise(e,r,i){return this.baseFs.writeFilePromise(this.fsMapToBase(e),r,i)}writeFileSync(e,r,i){return this.baseFs.writeFileSync(this.fsMapToBase(e),r,i)}async unlinkPromise(e){return this.baseFs.unlinkPromise(this.mapToBase(e))}unlinkSync(e){return this.baseFs.unlinkSync(this.mapToBase(e))}async utimesPromise(e,r,i){return this.baseFs.utimesPromise(this.mapToBase(e),r,i)}utimesSync(e,r,i){return this.baseFs.utimesSync(this.mapToBase(e),r,i)}async mkdirPromise(e,r){return this.baseFs.mkdirPromise(this.mapToBase(e),r)}mkdirSync(e,r){return this.baseFs.mkdirSync(this.mapToBase(e),r)}async rmdirPromise(e,r){return this.baseFs.rmdirPromise(this.mapToBase(e),r)}rmdirSync(e,r){return this.baseFs.rmdirSync(this.mapToBase(e),r)}async linkPromise(e,r){return this.baseFs.linkPromise(this.mapToBase(e),this.mapToBase(r))}linkSync(e,r){return this.baseFs.linkSync(this.mapToBase(e),this.mapToBase(r))}async symlinkPromise(e,r,i){let n=this.mapToBase(r);if(this.pathUtils.isAbsolute(e))return this.baseFs.symlinkPromise(this.mapToBase(e),n,i);let s=this.mapToBase(this.pathUtils.join(this.pathUtils.dirname(r),e)),o=this.baseFs.pathUtils.relative(this.baseFs.pathUtils.dirname(n),s);return this.baseFs.symlinkPromise(o,n,i)}symlinkSync(e,r,i){let n=this.mapToBase(r);if(this.pathUtils.isAbsolute(e))return this.baseFs.symlinkSync(this.mapToBase(e),n,i);let s=this.mapToBase(this.pathUtils.join(this.pathUtils.dirname(r),e)),o=this.baseFs.pathUtils.relative(this.baseFs.pathUtils.dirname(n),s);return this.baseFs.symlinkSync(o,n,i)}async readFilePromise(e,r){return r==="utf8"?this.baseFs.readFilePromise(this.fsMapToBase(e),r):this.baseFs.readFilePromise(this.fsMapToBase(e),r)}readFileSync(e,r){return r==="utf8"?this.baseFs.readFileSync(this.fsMapToBase(e),r):this.baseFs.readFileSync(this.fsMapToBase(e),r)}async readdirPromise(e,r){return this.baseFs.readdirPromise(this.mapToBase(e),r)}readdirSync(e,r){return this.baseFs.readdirSync(this.mapToBase(e),r)}async readlinkPromise(e){return this.mapFromBase(await this.baseFs.readlinkPromise(this.mapToBase(e)))}readlinkSync(e){return this.mapFromBase(this.baseFs.readlinkSync(this.mapToBase(e)))}async truncatePromise(e,r){return this.baseFs.truncatePromise(this.mapToBase(e),r)}truncateSync(e,r){return this.baseFs.truncateSync(this.mapToBase(e),r)}watch(e,r,i){return this.baseFs.watch(this.mapToBase(e),r,i)}watchFile(e,r,i){return this.baseFs.watchFile(this.mapToBase(e),r,i)}unwatchFile(e,r){return this.baseFs.unwatchFile(this.mapToBase(e),r)}fsMapToBase(e){return typeof e=="number"?e:this.mapToBase(e)}};var Xo=class extends fi{constructor(e,{baseFs:r,pathUtils:i}){super(i);this.target=e,this.baseFs=r}getRealPath(){return this.target}getBaseFs(){return this.baseFs}mapFromBase(e){return e}mapToBase(e){return e}};var Ft=class extends fi{constructor(e,{baseFs:r=new Wt}={}){super(v);this.target=this.pathUtils.normalize(e),this.baseFs=r}getRealPath(){return this.pathUtils.resolve(this.baseFs.getRealPath(),this.target)}resolve(e){return this.pathUtils.isAbsolute(e)?v.normalize(e):this.baseFs.resolve(v.join(this.target,e))}mapFromBase(e){return e}mapToBase(e){return this.pathUtils.isAbsolute(e)?e:this.pathUtils.join(this.target,e)}};var vO=Se.root,Zo=class extends fi{constructor(e,{baseFs:r=new Wt}={}){super(v);this.target=this.pathUtils.resolve(Se.root,e),this.baseFs=r}getRealPath(){return this.pathUtils.resolve(this.baseFs.getRealPath(),this.pathUtils.relative(Se.root,this.target))}getTarget(){return this.target}getBaseFs(){return this.baseFs}mapToBase(e){let r=this.pathUtils.normalize(e);if(this.pathUtils.isAbsolute(e))return this.pathUtils.resolve(this.target,this.pathUtils.relative(vO,e));if(r.match(/^\.\.\/?/))throw new Error(`Resolving this path (${e}) would escape the jail`);return this.pathUtils.resolve(this.target,e)}mapFromBase(e){return this.pathUtils.resolve(vO,this.pathUtils.relative(this.target,e))}};var oh=class extends fi{constructor(e,r){super(r);this.instance=null;this.factory=e}get baseFs(){return this.instance||(this.instance=this.factory()),this.instance}set baseFs(e){this.instance=e}mapFromBase(e){return e}mapToBase(e){return e}};var ze=()=>Object.assign(new Error("ENOSYS: unsupported filesystem access"),{code:"ENOSYS"}),gb=class extends eA{constructor(){super(v)}getExtractHint(){throw ze()}getRealPath(){throw ze()}resolve(){throw ze()}async openPromise(){throw ze()}openSync(){throw ze()}async opendirPromise(){throw ze()}opendirSync(){throw ze()}async readPromise(){throw ze()}readSync(){throw ze()}async writePromise(){throw ze()}writeSync(){throw ze()}async closePromise(){throw ze()}closeSync(){throw ze()}createWriteStream(){throw ze()}createReadStream(){throw ze()}async realpathPromise(){throw ze()}realpathSync(){throw ze()}async readdirPromise(){throw ze()}readdirSync(){throw ze()}async existsPromise(e){throw ze()}existsSync(e){throw ze()}async accessPromise(){throw ze()}accessSync(){throw ze()}async statPromise(){throw ze()}statSync(){throw ze()}async fstatPromise(e){throw ze()}fstatSync(e){throw ze()}async lstatPromise(e){throw ze()}lstatSync(e){throw ze()}async chmodPromise(){throw ze()}chmodSync(){throw ze()}async chownPromise(){throw ze()}chownSync(){throw ze()}async mkdirPromise(){throw ze()}mkdirSync(){throw ze()}async rmdirPromise(){throw ze()}rmdirSync(){throw ze()}async linkPromise(){throw ze()}linkSync(){throw ze()}async symlinkPromise(){throw ze()}symlinkSync(){throw ze()}async renamePromise(){throw ze()}renameSync(){throw ze()}async copyFilePromise(){throw ze()}copyFileSync(){throw ze()}async appendFilePromise(){throw ze()}appendFileSync(){throw ze()}async writeFilePromise(){throw ze()}writeFileSync(){throw ze()}async unlinkPromise(){throw ze()}unlinkSync(){throw ze()}async utimesPromise(){throw ze()}utimesSync(){throw ze()}async readFilePromise(){throw ze()}readFileSync(){throw ze()}async readlinkPromise(){throw ze()}readlinkSync(){throw ze()}async truncatePromise(){throw ze()}truncateSync(){throw ze()}watch(){throw ze()}watchFile(){throw ze()}unwatchFile(){throw ze()}},bE=gb;bE.instance=new gb;var ah=class extends fi{constructor(e){super(M);this.baseFs=e}mapFromBase(e){return M.fromPortablePath(e)}mapToBase(e){return M.toPortablePath(e)}};var nhe=/^[0-9]+$/,fb=/^(\/(?:[^/]+\/)*?(?:\$\$virtual|__virtual__))((?:\/((?:[^/]+-)?[a-f0-9]+)(?:\/([^/]+))?)?((?:\/.*)?))$/,she=/^([^/]+-)?[a-f0-9]+$/,Pr=class extends fi{static makeVirtualPath(e,r,i){if(v.basename(e)!=="__virtual__")throw new Error('Assertion failed: Virtual folders must be named "__virtual__"');if(!v.basename(r).match(she))throw new Error("Assertion failed: Virtual components must be ended by an hexadecimal hash");let s=v.relative(v.dirname(e),i).split("/"),o=0;for(;o{let r=t.indexOf(e);if(r<=0)return null;let i=r;for(;r>=0&&(i=r+e.length,t[i]!==v.sep);){if(t[r-1]===v.sep)return null;r=t.indexOf(e,i)}return t.length>i&&t[i]!==v.sep?null:t.slice(0,i)},Jn=class extends gl{constructor({libzip:e,baseFs:r=new Wt,filter:i=null,maxOpenFiles:n=Infinity,readOnlyArchives:s=!1,useCache:o=!0,maxAge:a=5e3,fileExtensions:l=null}){super();this.fdMap=new Map;this.nextFd=3;this.isZip=new Set;this.notZip=new Set;this.realPaths=new Map;this.limitOpenFilesTimeout=null;this.libzipFactory=typeof e!="function"?()=>e:e,this.baseFs=r,this.zipInstances=o?new Map:null,this.filter=i,this.maxOpenFiles=n,this.readOnlyArchives=s,this.maxAge=a,this.fileExtensions=l}static async openPromise(e,r){let i=new Jn(r);try{return await e(i)}finally{i.saveAndClose()}}get libzip(){return typeof this.libzipInstance=="undefined"&&(this.libzipInstance=this.libzipFactory()),this.libzipInstance}getExtractHint(e){return this.baseFs.getExtractHint(e)}getRealPath(){return this.baseFs.getRealPath()}saveAndClose(){if(sh(this),this.zipInstances)for(let[e,{zipFs:r}]of this.zipInstances.entries())r.saveAndClose(),this.zipInstances.delete(e)}discardAndClose(){if(sh(this),this.zipInstances)for(let[e,{zipFs:r}]of this.zipInstances.entries())r.discardAndClose(),this.zipInstances.delete(e)}resolve(e){return this.baseFs.resolve(e)}remapFd(e,r){let i=this.nextFd++|$o;return this.fdMap.set(i,[e,r]),i}async openPromise(e,r,i){return await this.makeCallPromise(e,async()=>await this.baseFs.openPromise(e,r,i),async(n,{subPath:s})=>this.remapFd(n,await n.openPromise(s,r,i)))}openSync(e,r,i){return this.makeCallSync(e,()=>this.baseFs.openSync(e,r,i),(n,{subPath:s})=>this.remapFd(n,n.openSync(s,r,i)))}async opendirPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.opendirPromise(e,r),async(i,{subPath:n})=>await i.opendirPromise(n,r),{requireSubpath:!1})}opendirSync(e,r){return this.makeCallSync(e,()=>this.baseFs.opendirSync(e,r),(i,{subPath:n})=>i.opendirSync(n,r),{requireSubpath:!1})}async readPromise(e,r,i,n,s){if((e&$o)==0)return await this.baseFs.readPromise(e,r,i,n,s);let o=this.fdMap.get(e);if(typeof o=="undefined")throw Hi("read");let[a,l]=o;return await a.readPromise(l,r,i,n,s)}readSync(e,r,i,n,s){if((e&$o)==0)return this.baseFs.readSync(e,r,i,n,s);let o=this.fdMap.get(e);if(typeof o=="undefined")throw Hi("readSync");let[a,l]=o;return a.readSync(l,r,i,n,s)}async writePromise(e,r,i,n,s){if((e&$o)==0)return typeof r=="string"?await this.baseFs.writePromise(e,r,i):await this.baseFs.writePromise(e,r,i,n,s);let o=this.fdMap.get(e);if(typeof o=="undefined")throw Hi("write");let[a,l]=o;return typeof r=="string"?await a.writePromise(l,r,i):await a.writePromise(l,r,i,n,s)}writeSync(e,r,i,n,s){if((e&$o)==0)return typeof r=="string"?this.baseFs.writeSync(e,r,i):this.baseFs.writeSync(e,r,i,n,s);let o=this.fdMap.get(e);if(typeof o=="undefined")throw Hi("writeSync");let[a,l]=o;return typeof r=="string"?a.writeSync(l,r,i):a.writeSync(l,r,i,n,s)}async closePromise(e){if((e&$o)==0)return await this.baseFs.closePromise(e);let r=this.fdMap.get(e);if(typeof r=="undefined")throw Hi("close");this.fdMap.delete(e);let[i,n]=r;return await i.closePromise(n)}closeSync(e){if((e&$o)==0)return this.baseFs.closeSync(e);let r=this.fdMap.get(e);if(typeof r=="undefined")throw Hi("closeSync");this.fdMap.delete(e);let[i,n]=r;return i.closeSync(n)}createReadStream(e,r){return e===null?this.baseFs.createReadStream(e,r):this.makeCallSync(e,()=>this.baseFs.createReadStream(e,r),(i,{subPath:n})=>i.createReadStream(n,r))}createWriteStream(e,r){return e===null?this.baseFs.createWriteStream(e,r):this.makeCallSync(e,()=>this.baseFs.createWriteStream(e,r),(i,{subPath:n})=>i.createWriteStream(n,r))}async realpathPromise(e){return await this.makeCallPromise(e,async()=>await this.baseFs.realpathPromise(e),async(r,{archivePath:i,subPath:n})=>{let s=this.realPaths.get(i);return typeof s=="undefined"&&(s=await this.baseFs.realpathPromise(i),this.realPaths.set(i,s)),this.pathUtils.join(s,this.pathUtils.relative(Se.root,await r.realpathPromise(n)))})}realpathSync(e){return this.makeCallSync(e,()=>this.baseFs.realpathSync(e),(r,{archivePath:i,subPath:n})=>{let s=this.realPaths.get(i);return typeof s=="undefined"&&(s=this.baseFs.realpathSync(i),this.realPaths.set(i,s)),this.pathUtils.join(s,this.pathUtils.relative(Se.root,r.realpathSync(n)))})}async existsPromise(e){return await this.makeCallPromise(e,async()=>await this.baseFs.existsPromise(e),async(r,{subPath:i})=>await r.existsPromise(i))}existsSync(e){return this.makeCallSync(e,()=>this.baseFs.existsSync(e),(r,{subPath:i})=>r.existsSync(i))}async accessPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.accessPromise(e,r),async(i,{subPath:n})=>await i.accessPromise(n,r))}accessSync(e,r){return this.makeCallSync(e,()=>this.baseFs.accessSync(e,r),(i,{subPath:n})=>i.accessSync(n,r))}async statPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.statPromise(e,r),async(i,{subPath:n})=>await i.statPromise(n,r))}statSync(e,r){return this.makeCallSync(e,()=>this.baseFs.statSync(e,r),(i,{subPath:n})=>i.statSync(n,r))}async fstatPromise(e,r){if((e&$o)==0)return this.baseFs.fstatPromise(e,r);let i=this.fdMap.get(e);if(typeof i=="undefined")throw Hi("fstat");let[n,s]=i;return n.fstatPromise(s,r)}fstatSync(e,r){if((e&$o)==0)return this.baseFs.fstatSync(e,r);let i=this.fdMap.get(e);if(typeof i=="undefined")throw Hi("fstatSync");let[n,s]=i;return n.fstatSync(s,r)}async lstatPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.lstatPromise(e,r),async(i,{subPath:n})=>await i.lstatPromise(n,r))}lstatSync(e,r){return this.makeCallSync(e,()=>this.baseFs.lstatSync(e,r),(i,{subPath:n})=>i.lstatSync(n,r))}async chmodPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.chmodPromise(e,r),async(i,{subPath:n})=>await i.chmodPromise(n,r))}chmodSync(e,r){return this.makeCallSync(e,()=>this.baseFs.chmodSync(e,r),(i,{subPath:n})=>i.chmodSync(n,r))}async chownPromise(e,r,i){return await this.makeCallPromise(e,async()=>await this.baseFs.chownPromise(e,r,i),async(n,{subPath:s})=>await n.chownPromise(s,r,i))}chownSync(e,r,i){return this.makeCallSync(e,()=>this.baseFs.chownSync(e,r,i),(n,{subPath:s})=>n.chownSync(s,r,i))}async renamePromise(e,r){return await this.makeCallPromise(e,async()=>await this.makeCallPromise(r,async()=>await this.baseFs.renamePromise(e,r),async()=>{throw Object.assign(new Error("EEXDEV: cross-device link not permitted"),{code:"EEXDEV"})}),async(i,{subPath:n})=>await this.makeCallPromise(r,async()=>{throw Object.assign(new Error("EEXDEV: cross-device link not permitted"),{code:"EEXDEV"})},async(s,{subPath:o})=>{if(i!==s)throw Object.assign(new Error("EEXDEV: cross-device link not permitted"),{code:"EEXDEV"});return await i.renamePromise(n,o)}))}renameSync(e,r){return this.makeCallSync(e,()=>this.makeCallSync(r,()=>this.baseFs.renameSync(e,r),()=>{throw Object.assign(new Error("EEXDEV: cross-device link not permitted"),{code:"EEXDEV"})}),(i,{subPath:n})=>this.makeCallSync(r,()=>{throw Object.assign(new Error("EEXDEV: cross-device link not permitted"),{code:"EEXDEV"})},(s,{subPath:o})=>{if(i!==s)throw Object.assign(new Error("EEXDEV: cross-device link not permitted"),{code:"EEXDEV"});return i.renameSync(n,o)}))}async copyFilePromise(e,r,i=0){let n=async(s,o,a,l)=>{if((i&Ah.constants.COPYFILE_FICLONE_FORCE)!=0)throw Object.assign(new Error(`EXDEV: cross-device clone not permitted, copyfile '${o}' -> ${l}'`),{code:"EXDEV"});if(i&Ah.constants.COPYFILE_EXCL&&await this.existsPromise(o))throw Object.assign(new Error(`EEXIST: file already exists, copyfile '${o}' -> '${l}'`),{code:"EEXIST"});let c;try{c=await s.readFilePromise(o)}catch(u){throw Object.assign(new Error(`EINVAL: invalid argument, copyfile '${o}' -> '${l}'`),{code:"EINVAL"})}await a.writeFilePromise(l,c)};return await this.makeCallPromise(e,async()=>await this.makeCallPromise(r,async()=>await this.baseFs.copyFilePromise(e,r,i),async(s,{subPath:o})=>await n(this.baseFs,e,s,o)),async(s,{subPath:o})=>await this.makeCallPromise(r,async()=>await n(s,o,this.baseFs,r),async(a,{subPath:l})=>s!==a?await n(s,o,a,l):await s.copyFilePromise(o,l,i)))}copyFileSync(e,r,i=0){let n=(s,o,a,l)=>{if((i&Ah.constants.COPYFILE_FICLONE_FORCE)!=0)throw Object.assign(new Error(`EXDEV: cross-device clone not permitted, copyfile '${o}' -> ${l}'`),{code:"EXDEV"});if(i&Ah.constants.COPYFILE_EXCL&&this.existsSync(o))throw Object.assign(new Error(`EEXIST: file already exists, copyfile '${o}' -> '${l}'`),{code:"EEXIST"});let c;try{c=s.readFileSync(o)}catch(u){throw Object.assign(new Error(`EINVAL: invalid argument, copyfile '${o}' -> '${l}'`),{code:"EINVAL"})}a.writeFileSync(l,c)};return this.makeCallSync(e,()=>this.makeCallSync(r,()=>this.baseFs.copyFileSync(e,r,i),(s,{subPath:o})=>n(this.baseFs,e,s,o)),(s,{subPath:o})=>this.makeCallSync(r,()=>n(s,o,this.baseFs,r),(a,{subPath:l})=>s!==a?n(s,o,a,l):s.copyFileSync(o,l,i)))}async appendFilePromise(e,r,i){return await this.makeCallPromise(e,async()=>await this.baseFs.appendFilePromise(e,r,i),async(n,{subPath:s})=>await n.appendFilePromise(s,r,i))}appendFileSync(e,r,i){return this.makeCallSync(e,()=>this.baseFs.appendFileSync(e,r,i),(n,{subPath:s})=>n.appendFileSync(s,r,i))}async writeFilePromise(e,r,i){return await this.makeCallPromise(e,async()=>await this.baseFs.writeFilePromise(e,r,i),async(n,{subPath:s})=>await n.writeFilePromise(s,r,i))}writeFileSync(e,r,i){return this.makeCallSync(e,()=>this.baseFs.writeFileSync(e,r,i),(n,{subPath:s})=>n.writeFileSync(s,r,i))}async unlinkPromise(e){return await this.makeCallPromise(e,async()=>await this.baseFs.unlinkPromise(e),async(r,{subPath:i})=>await r.unlinkPromise(i))}unlinkSync(e){return this.makeCallSync(e,()=>this.baseFs.unlinkSync(e),(r,{subPath:i})=>r.unlinkSync(i))}async utimesPromise(e,r,i){return await this.makeCallPromise(e,async()=>await this.baseFs.utimesPromise(e,r,i),async(n,{subPath:s})=>await n.utimesPromise(s,r,i))}utimesSync(e,r,i){return this.makeCallSync(e,()=>this.baseFs.utimesSync(e,r,i),(n,{subPath:s})=>n.utimesSync(s,r,i))}async mkdirPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.mkdirPromise(e,r),async(i,{subPath:n})=>await i.mkdirPromise(n,r))}mkdirSync(e,r){return this.makeCallSync(e,()=>this.baseFs.mkdirSync(e,r),(i,{subPath:n})=>i.mkdirSync(n,r))}async rmdirPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.rmdirPromise(e,r),async(i,{subPath:n})=>await i.rmdirPromise(n,r))}rmdirSync(e,r){return this.makeCallSync(e,()=>this.baseFs.rmdirSync(e,r),(i,{subPath:n})=>i.rmdirSync(n,r))}async linkPromise(e,r){return await this.makeCallPromise(r,async()=>await this.baseFs.linkPromise(e,r),async(i,{subPath:n})=>await i.linkPromise(e,n))}linkSync(e,r){return this.makeCallSync(r,()=>this.baseFs.linkSync(e,r),(i,{subPath:n})=>i.linkSync(e,n))}async symlinkPromise(e,r,i){return await this.makeCallPromise(r,async()=>await this.baseFs.symlinkPromise(e,r,i),async(n,{subPath:s})=>await n.symlinkPromise(e,s))}symlinkSync(e,r,i){return this.makeCallSync(r,()=>this.baseFs.symlinkSync(e,r,i),(n,{subPath:s})=>n.symlinkSync(e,s))}async readFilePromise(e,r){return this.makeCallPromise(e,async()=>{switch(r){case"utf8":return await this.baseFs.readFilePromise(e,r);default:return await this.baseFs.readFilePromise(e,r)}},async(i,{subPath:n})=>await i.readFilePromise(n,r))}readFileSync(e,r){return this.makeCallSync(e,()=>{switch(r){case"utf8":return this.baseFs.readFileSync(e,r);default:return this.baseFs.readFileSync(e,r)}},(i,{subPath:n})=>i.readFileSync(n,r))}async readdirPromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.readdirPromise(e,r),async(i,{subPath:n})=>await i.readdirPromise(n,r),{requireSubpath:!1})}readdirSync(e,r){return this.makeCallSync(e,()=>this.baseFs.readdirSync(e,r),(i,{subPath:n})=>i.readdirSync(n,r),{requireSubpath:!1})}async readlinkPromise(e){return await this.makeCallPromise(e,async()=>await this.baseFs.readlinkPromise(e),async(r,{subPath:i})=>await r.readlinkPromise(i))}readlinkSync(e){return this.makeCallSync(e,()=>this.baseFs.readlinkSync(e),(r,{subPath:i})=>r.readlinkSync(i))}async truncatePromise(e,r){return await this.makeCallPromise(e,async()=>await this.baseFs.truncatePromise(e,r),async(i,{subPath:n})=>await i.truncatePromise(n,r))}truncateSync(e,r){return this.makeCallSync(e,()=>this.baseFs.truncateSync(e,r),(i,{subPath:n})=>i.truncateSync(n,r))}watch(e,r,i){return this.makeCallSync(e,()=>this.baseFs.watch(e,r,i),(n,{subPath:s})=>n.watch(s,r,i))}watchFile(e,r,i){return this.makeCallSync(e,()=>this.baseFs.watchFile(e,r,i),()=>QE(this,e,r,i))}unwatchFile(e,r){return this.makeCallSync(e,()=>this.baseFs.unwatchFile(e,r),()=>nh(this,e,r))}async makeCallPromise(e,r,i,{requireSubpath:n=!0}={}){if(typeof e!="string")return await r();let s=this.resolve(e),o=this.findZip(s);return o?n&&o.subPath==="/"?await r():await this.getZipPromise(o.archivePath,async a=>await i(a,o)):await r()}makeCallSync(e,r,i,{requireSubpath:n=!0}={}){if(typeof e!="string")return r();let s=this.resolve(e),o=this.findZip(s);return!o||n&&o.subPath==="/"?r():this.getZipSync(o.archivePath,a=>i(a,o))}findZip(e){if(this.filter&&!this.filter.test(e))return null;let r="";for(;;){let i=e.substr(r.length),n;if(!this.fileExtensions)n=SO(i,".zip");else for(let s of this.fileExtensions)if(n=SO(i,s),n)break;if(!n)return null;if(r=this.pathUtils.join(r,n),this.isZip.has(r)===!1){if(this.notZip.has(r))continue;try{if(!this.baseFs.lstatSync(r).isFile()){this.notZip.add(r);continue}}catch{return null}this.isZip.add(r)}return{archivePath:r,subPath:this.pathUtils.join(Se.root,e.substr(r.length))}}}limitOpenFiles(e){if(this.zipInstances===null)return;let r=Date.now(),i=r+this.maxAge,n=e===null?0:this.zipInstances.size-e;for(let[s,{zipFs:o,expiresAt:a,refCount:l}]of this.zipInstances.entries())if(!(l!==0||o.hasOpenFileHandles())){if(r>=a){o.saveAndClose(),this.zipInstances.delete(s),n-=1;continue}else if(e===null||n<=0){i=a;break}o.saveAndClose(),this.zipInstances.delete(s),n-=1}this.limitOpenFilesTimeout===null&&(e===null&&this.zipInstances.size>0||e!==null)&&(this.limitOpenFilesTimeout=setTimeout(()=>{this.limitOpenFilesTimeout=null,this.limitOpenFiles(null)},i-r).unref())}async getZipPromise(e,r){let i=async()=>({baseFs:this.baseFs,libzip:this.libzip,readOnly:this.readOnlyArchives,stats:await this.baseFs.statPromise(e)});if(this.zipInstances){let n=this.zipInstances.get(e);if(!n){let s=await i();n=this.zipInstances.get(e),n||(n={zipFs:new Jr(e,s),expiresAt:0,refCount:0})}this.zipInstances.delete(e),this.limitOpenFiles(this.maxOpenFiles-1),this.zipInstances.set(e,n),n.expiresAt=Date.now()+this.maxAge,n.refCount+=1;try{return await r(n.zipFs)}finally{n.refCount-=1}}else{let n=new Jr(e,await i());try{return await r(n)}finally{n.saveAndClose()}}}getZipSync(e,r){let i=()=>({baseFs:this.baseFs,libzip:this.libzip,readOnly:this.readOnlyArchives,stats:this.baseFs.statSync(e)});if(this.zipInstances){let n=this.zipInstances.get(e);return n||(n={zipFs:new Jr(e,i()),expiresAt:0,refCount:0}),this.zipInstances.delete(e),this.limitOpenFiles(this.maxOpenFiles-1),this.zipInstances.set(e,n),n.expiresAt=Date.now()+this.maxAge,r(n.zipFs)}else{let n=new Jr(e,i());try{return r(n)}finally{n.saveAndClose()}}}};var lh=ie(require("util"));var vE=ie(require("url"));var hb=class extends fi{constructor(e){super(M);this.baseFs=e}mapFromBase(e){return e}mapToBase(e){return e instanceof vE.URL?(0,vE.fileURLToPath)(e):e}};var ohe=new Set(["accessSync","appendFileSync","createReadStream","createWriteStream","chmodSync","chownSync","closeSync","copyFileSync","linkSync","lstatSync","fstatSync","lutimesSync","mkdirSync","openSync","opendirSync","readSync","readlinkSync","readFileSync","readdirSync","readlinkSync","realpathSync","renameSync","rmdirSync","statSync","symlinkSync","truncateSync","unlinkSync","unwatchFile","utimesSync","watch","watchFile","writeFileSync","writeSync"]),xO=new Set(["accessPromise","appendFilePromise","chmodPromise","chownPromise","closePromise","copyFilePromise","linkPromise","fstatPromise","lstatPromise","lutimesPromise","mkdirPromise","openPromise","opendirPromise","readdirPromise","realpathPromise","readFilePromise","readdirPromise","readlinkPromise","renamePromise","rmdirPromise","statPromise","symlinkPromise","truncatePromise","unlinkPromise","utimesPromise","writeFilePromise","writeSync"]),ahe=new Set(["appendFilePromise","chmodPromise","chownPromise","closePromise","readPromise","readFilePromise","statPromise","truncatePromise","utimesPromise","writePromise","writeFilePromise"]);function pb(t,e){e=new hb(e);let r=(i,n,s)=>{let o=i[n];i[n]=s,typeof(o==null?void 0:o[lh.promisify.custom])!="undefined"&&(s[lh.promisify.custom]=o[lh.promisify.custom])};{r(t,"exists",(i,...n)=>{let o=typeof n[n.length-1]=="function"?n.pop():()=>{};process.nextTick(()=>{e.existsPromise(i).then(a=>{o(a)},()=>{o(!1)})})}),r(t,"read",(i,n,...s)=>{let a=typeof s[s.length-1]=="function"?s.pop():()=>{};process.nextTick(()=>{e.readPromise(i,n,...s).then(l=>{a(null,l,n)},l=>{a(l,0,n)})})});for(let i of xO){let n=i.replace(/Promise$/,"");if(typeof t[n]=="undefined")continue;let s=e[i];if(typeof s=="undefined")continue;r(t,n,(...a)=>{let c=typeof a[a.length-1]=="function"?a.pop():()=>{};process.nextTick(()=>{s.apply(e,a).then(u=>{c(null,u)},u=>{c(u)})})})}t.realpath.native=t.realpath}{r(t,"existsSync",i=>{try{return e.existsSync(i)}catch(n){return!1}});for(let i of ohe){let n=i;if(typeof t[n]=="undefined")continue;let s=e[i];typeof s!="undefined"&&r(t,n,s.bind(e))}t.realpathSync.native=t.realpathSync}{let i=process.emitWarning;process.emitWarning=()=>{};let n;try{n=t.promises}finally{process.emitWarning=i}if(typeof n!="undefined"){for(let o of xO){let a=o.replace(/Promise$/,"");if(typeof n[a]=="undefined")continue;let l=e[o];typeof l!="undefined"&&o!=="open"&&r(n,a,l.bind(e))}class s{constructor(a){this.fd=a}}for(let o of ahe){let a=o.replace(/Promise$/,""),l=e[o];typeof l!="undefined"&&r(s.prototype,a,function(...c){return l.call(e,this.fd,...c)})}r(n,"open",async(...o)=>{let a=await e.openPromise(...o);return new s(a)})}}t.read[lh.promisify.custom]=async(i,n,...s)=>({bytesRead:await e.readPromise(i,n,...s),buffer:n})}function SE(t,e){let r=Object.create(t);return pb(r,e),r}var kO=ie(require("os"));function PO(t){let e=M.toPortablePath(kO.default.tmpdir()),r=Math.ceil(Math.random()*4294967296).toString(16).padStart(8,"0");return v.join(e,`${t}${r}`)}var vs=new Set,DO=!1;function RO(){DO||(DO=!0,process.once("exit",()=>{T.rmtempSync()}))}var T=Object.assign(new Wt,{detachTemp(t){vs.delete(t)},mktempSync(t){for(RO();;){let e=PO("xfs-");try{this.mkdirSync(e)}catch(i){if(i.code==="EEXIST")continue;throw i}let r=this.realpathSync(e);if(vs.add(r),typeof t!="undefined")try{return t(r)}finally{if(vs.has(r)){vs.delete(r);try{this.removeSync(r)}catch{}}}else return r}},async mktempPromise(t){for(RO();;){let e=PO("xfs-");try{await this.mkdirPromise(e)}catch(i){if(i.code==="EEXIST")continue;throw i}let r=await this.realpathPromise(e);if(vs.add(r),typeof t!="undefined")try{return await t(r)}finally{if(vs.has(r)){vs.delete(r);try{await this.removePromise(r)}catch{}}}else return r}},async rmtempPromise(){await Promise.all(Array.from(vs.values()).map(async t=>{try{await T.removePromise(t,{maxRetries:0}),vs.delete(t)}catch{}}))},rmtempSync(){for(let t of vs)try{T.removeSync(t),vs.delete(t)}catch{}}});var vb=ie(bb()),Pn;(function(i){i[i.Never=0]="Never",i[i.ErrorCode=1]="ErrorCode",i[i.Always=2]="Always"})(Pn||(Pn={}));function dl(t){return t!==null&&typeof t.fd=="number"}var Cl=new Set;function Sb(){}function xb(){for(let t of Cl)t.kill()}async function to(t,e,{cwd:r,env:i=process.env,strict:n=!1,stdin:s=null,stdout:o,stderr:a,end:l=2}){let c=["pipe","pipe","pipe"];s===null?c[0]="ignore":dl(s)&&(c[0]=s),dl(o)&&(c[1]=o),dl(a)&&(c[2]=a);let u=(0,vb.default)(t,e,{cwd:M.fromPortablePath(r),env:_(P({},i),{PWD:M.fromPortablePath(r)}),stdio:c});Cl.add(u),Cl.size===1&&(process.on("SIGINT",Sb),process.on("SIGTERM",xb)),!dl(s)&&s!==null&&s.pipe(u.stdin),dl(o)||u.stdout.pipe(o,{end:!1}),dl(a)||u.stderr.pipe(a,{end:!1});let g=()=>{for(let f of new Set([o,a]))dl(f)||f.end()};return new Promise((f,h)=>{u.on("error",p=>{Cl.delete(u),Cl.size===0&&(process.off("SIGINT",Sb),process.off("SIGTERM",xb)),(l===2||l===1)&&g(),h(p)}),u.on("close",(p,d)=>{Cl.delete(u),Cl.size===0&&(process.off("SIGINT",Sb),process.off("SIGTERM",xb)),(l===2||l===1&&p>0)&&g(),p===0||!n?f({code:kb(p,d)}):h(p!==null?new Error(`Child "${t}" exited with exit code ${p}`):new Error(`Child "${t}" exited with signal ${d}`))})})}async function Nhe(t,e,{cwd:r,env:i=process.env,encoding:n="utf8",strict:s=!1}){let o=["ignore","pipe","pipe"],a=[],l=[],c=M.fromPortablePath(r);typeof i.PWD!="undefined"&&(i=_(P({},i),{PWD:c}));let u=(0,vb.default)(t,e,{cwd:c,env:i,stdio:o});return u.stdout.on("data",g=>{a.push(g)}),u.stderr.on("data",g=>{l.push(g)}),await new Promise((g,f)=>{u.on("error",()=>{f()}),u.on("close",(h,p)=>{let d=n==="buffer"?Buffer.concat(a):Buffer.concat(a).toString(n),m=n==="buffer"?Buffer.concat(l):Buffer.concat(l).toString(n);h===0||!s?g({code:kb(h,p),stdout:d,stderr:m}):f(Object.assign(new Error(`Child "${t}" exited with exit code ${h} - -${m}`),{code:kb(h,p),stdout:d,stderr:m}))})})}var Lhe=new Map([["SIGINT",2],["SIGQUIT",3],["SIGKILL",9],["SIGTERM",15]]);function kb(t,e){let r=Lhe.get(e);return typeof r!="undefined"?128+r:t!=null?t:1}var Pb={};it(Pb,{getDefaultGlobalFolder:()=>Rb,getHomeFolder:()=>uh,isFolderInside:()=>Fb});var Db=ie(require("os"));function Rb(){if(process.platform==="win32"){let t=M.toPortablePath(process.env.LOCALAPPDATA||M.join((0,Db.homedir)(),"AppData","Local"));return v.resolve(t,"Yarn/Berry")}if(process.env.XDG_DATA_HOME){let t=M.toPortablePath(process.env.XDG_DATA_HOME);return v.resolve(t,"yarn/berry")}return v.resolve(uh(),".yarn/berry")}function uh(){return M.toPortablePath((0,Db.homedir)()||"/usr/local/share")}function Fb(t,e){let r=v.relative(e,t);return r&&!r.startsWith("..")&&!v.isAbsolute(r)}var ue={};it(ue,{LogLevel:()=>Ts,Style:()=>Gl,Type:()=>Le,addLogFilterSupport:()=>Cp,applyColor:()=>On,applyHyperlink:()=>Ku,applyStyle:()=>Py,json:()=>Uu,mark:()=>xx,pretty:()=>Ve,prettyField:()=>Yl,prettyList:()=>Kx,supportsColor:()=>xy,supportsHyperlinks:()=>Mx,tuple:()=>jl});var pp=ie(jb()),dp=ie(ml()),o3=ie(Nn()),a3=ie(gU());var z;(function(te){te[te.UNNAMED=0]="UNNAMED",te[te.EXCEPTION=1]="EXCEPTION",te[te.MISSING_PEER_DEPENDENCY=2]="MISSING_PEER_DEPENDENCY",te[te.CYCLIC_DEPENDENCIES=3]="CYCLIC_DEPENDENCIES",te[te.DISABLED_BUILD_SCRIPTS=4]="DISABLED_BUILD_SCRIPTS",te[te.BUILD_DISABLED=5]="BUILD_DISABLED",te[te.SOFT_LINK_BUILD=6]="SOFT_LINK_BUILD",te[te.MUST_BUILD=7]="MUST_BUILD",te[te.MUST_REBUILD=8]="MUST_REBUILD",te[te.BUILD_FAILED=9]="BUILD_FAILED",te[te.RESOLVER_NOT_FOUND=10]="RESOLVER_NOT_FOUND",te[te.FETCHER_NOT_FOUND=11]="FETCHER_NOT_FOUND",te[te.LINKER_NOT_FOUND=12]="LINKER_NOT_FOUND",te[te.FETCH_NOT_CACHED=13]="FETCH_NOT_CACHED",te[te.YARN_IMPORT_FAILED=14]="YARN_IMPORT_FAILED",te[te.REMOTE_INVALID=15]="REMOTE_INVALID",te[te.REMOTE_NOT_FOUND=16]="REMOTE_NOT_FOUND",te[te.RESOLUTION_PACK=17]="RESOLUTION_PACK",te[te.CACHE_CHECKSUM_MISMATCH=18]="CACHE_CHECKSUM_MISMATCH",te[te.UNUSED_CACHE_ENTRY=19]="UNUSED_CACHE_ENTRY",te[te.MISSING_LOCKFILE_ENTRY=20]="MISSING_LOCKFILE_ENTRY",te[te.WORKSPACE_NOT_FOUND=21]="WORKSPACE_NOT_FOUND",te[te.TOO_MANY_MATCHING_WORKSPACES=22]="TOO_MANY_MATCHING_WORKSPACES",te[te.CONSTRAINTS_MISSING_DEPENDENCY=23]="CONSTRAINTS_MISSING_DEPENDENCY",te[te.CONSTRAINTS_INCOMPATIBLE_DEPENDENCY=24]="CONSTRAINTS_INCOMPATIBLE_DEPENDENCY",te[te.CONSTRAINTS_EXTRANEOUS_DEPENDENCY=25]="CONSTRAINTS_EXTRANEOUS_DEPENDENCY",te[te.CONSTRAINTS_INVALID_DEPENDENCY=26]="CONSTRAINTS_INVALID_DEPENDENCY",te[te.CANT_SUGGEST_RESOLUTIONS=27]="CANT_SUGGEST_RESOLUTIONS",te[te.FROZEN_LOCKFILE_EXCEPTION=28]="FROZEN_LOCKFILE_EXCEPTION",te[te.CROSS_DRIVE_VIRTUAL_LOCAL=29]="CROSS_DRIVE_VIRTUAL_LOCAL",te[te.FETCH_FAILED=30]="FETCH_FAILED",te[te.DANGEROUS_NODE_MODULES=31]="DANGEROUS_NODE_MODULES",te[te.NODE_GYP_INJECTED=32]="NODE_GYP_INJECTED",te[te.AUTHENTICATION_NOT_FOUND=33]="AUTHENTICATION_NOT_FOUND",te[te.INVALID_CONFIGURATION_KEY=34]="INVALID_CONFIGURATION_KEY",te[te.NETWORK_ERROR=35]="NETWORK_ERROR",te[te.LIFECYCLE_SCRIPT=36]="LIFECYCLE_SCRIPT",te[te.CONSTRAINTS_MISSING_FIELD=37]="CONSTRAINTS_MISSING_FIELD",te[te.CONSTRAINTS_INCOMPATIBLE_FIELD=38]="CONSTRAINTS_INCOMPATIBLE_FIELD",te[te.CONSTRAINTS_EXTRANEOUS_FIELD=39]="CONSTRAINTS_EXTRANEOUS_FIELD",te[te.CONSTRAINTS_INVALID_FIELD=40]="CONSTRAINTS_INVALID_FIELD",te[te.AUTHENTICATION_INVALID=41]="AUTHENTICATION_INVALID",te[te.PROLOG_UNKNOWN_ERROR=42]="PROLOG_UNKNOWN_ERROR",te[te.PROLOG_SYNTAX_ERROR=43]="PROLOG_SYNTAX_ERROR",te[te.PROLOG_EXISTENCE_ERROR=44]="PROLOG_EXISTENCE_ERROR",te[te.STACK_OVERFLOW_RESOLUTION=45]="STACK_OVERFLOW_RESOLUTION",te[te.AUTOMERGE_FAILED_TO_PARSE=46]="AUTOMERGE_FAILED_TO_PARSE",te[te.AUTOMERGE_IMMUTABLE=47]="AUTOMERGE_IMMUTABLE",te[te.AUTOMERGE_SUCCESS=48]="AUTOMERGE_SUCCESS",te[te.AUTOMERGE_REQUIRED=49]="AUTOMERGE_REQUIRED",te[te.DEPRECATED_CLI_SETTINGS=50]="DEPRECATED_CLI_SETTINGS",te[te.PLUGIN_NAME_NOT_FOUND=51]="PLUGIN_NAME_NOT_FOUND",te[te.INVALID_PLUGIN_REFERENCE=52]="INVALID_PLUGIN_REFERENCE",te[te.CONSTRAINTS_AMBIGUITY=53]="CONSTRAINTS_AMBIGUITY",te[te.CACHE_OUTSIDE_PROJECT=54]="CACHE_OUTSIDE_PROJECT",te[te.IMMUTABLE_INSTALL=55]="IMMUTABLE_INSTALL",te[te.IMMUTABLE_CACHE=56]="IMMUTABLE_CACHE",te[te.INVALID_MANIFEST=57]="INVALID_MANIFEST",te[te.PACKAGE_PREPARATION_FAILED=58]="PACKAGE_PREPARATION_FAILED",te[te.INVALID_RANGE_PEER_DEPENDENCY=59]="INVALID_RANGE_PEER_DEPENDENCY",te[te.INCOMPATIBLE_PEER_DEPENDENCY=60]="INCOMPATIBLE_PEER_DEPENDENCY",te[te.DEPRECATED_PACKAGE=61]="DEPRECATED_PACKAGE",te[te.INCOMPATIBLE_OS=62]="INCOMPATIBLE_OS",te[te.INCOMPATIBLE_CPU=63]="INCOMPATIBLE_CPU",te[te.FROZEN_ARTIFACT_EXCEPTION=64]="FROZEN_ARTIFACT_EXCEPTION",te[te.TELEMETRY_NOTICE=65]="TELEMETRY_NOTICE",te[te.PATCH_HUNK_FAILED=66]="PATCH_HUNK_FAILED",te[te.INVALID_CONFIGURATION_VALUE=67]="INVALID_CONFIGURATION_VALUE",te[te.UNUSED_PACKAGE_EXTENSION=68]="UNUSED_PACKAGE_EXTENSION",te[te.REDUNDANT_PACKAGE_EXTENSION=69]="REDUNDANT_PACKAGE_EXTENSION",te[te.AUTO_NM_SUCCESS=70]="AUTO_NM_SUCCESS",te[te.NM_CANT_INSTALL_EXTERNAL_SOFT_LINK=71]="NM_CANT_INSTALL_EXTERNAL_SOFT_LINK",te[te.NM_PRESERVE_SYMLINKS_REQUIRED=72]="NM_PRESERVE_SYMLINKS_REQUIRED",te[te.UPDATE_LOCKFILE_ONLY_SKIP_LINK=73]="UPDATE_LOCKFILE_ONLY_SKIP_LINK",te[te.NM_HARDLINKS_MODE_DOWNGRADED=74]="NM_HARDLINKS_MODE_DOWNGRADED",te[te.PROLOG_INSTANTIATION_ERROR=75]="PROLOG_INSTANTIATION_ERROR",te[te.INCOMPATIBLE_ARCHITECTURE=76]="INCOMPATIBLE_ARCHITECTURE",te[te.GHOST_ARCHITECTURE=77]="GHOST_ARCHITECTURE"})(z||(z={}));function KE(t){return`YN${t.toString(10).padStart(4,"0")}`}var de={};it(de,{BufferStream:()=>OH,CachingStrategy:()=>Dl,DefaultStream:()=>KH,assertNever:()=>Lv,bufferStream:()=>Cu,buildIgnorePattern:()=>DEe,convertMapsToIndexableObjects:()=>aI,dynamicRequire:()=>mu,escapeRegExp:()=>SEe,getArrayWithDefault:()=>hu,getFactoryWithDefault:()=>na,getMapWithDefault:()=>pu,getSetWithDefault:()=>Pl,isIndexableObject:()=>Tv,isPathLike:()=>REe,isTaggedYarnVersion:()=>vEe,mapAndFilter:()=>kl,mapAndFind:()=>MH,overrideType:()=>Nv,parseBoolean:()=>Hh,parseOptionalBoolean:()=>jH,prettifyAsyncErrors:()=>du,prettifySyncErrors:()=>Mv,releaseAfterUseAsync:()=>kEe,replaceEnvVariables:()=>Ov,sortMap:()=>gn,tryParseOptionalBoolean:()=>Kv,validateEnum:()=>xEe});var vh={};it(vh,{Builtins:()=>Iv,Cli:()=>oo,Command:()=>ye,Option:()=>Y,UsageError:()=>me});var yl=0,Eh=1,Gi=2,sv="",hi="\0",Au=-1,ov=/^(-h|--help)(?:=([0-9]+))?$/,UE=/^(--[a-z]+(?:-[a-z]+)*|-[a-zA-Z]+)$/,fU=/^-[a-zA-Z]{2,}$/,av=/^([^=]+)=([\s\S]*)$/,Av=process.env.DEBUG_CLI==="1";var me=class extends Error{constructor(e){super(e);this.clipanion={type:"usage"},this.name="UsageError"}},Ih=class extends Error{constructor(e,r){super();if(this.input=e,this.candidates=r,this.clipanion={type:"none"},this.name="UnknownSyntaxError",this.candidates.length===0)this.message="Command not found, but we're not sure what's the alternative.";else if(this.candidates.every(i=>i.reason!==null&&i.reason===r[0].reason)){let[{reason:i}]=this.candidates;this.message=`${i} - -${this.candidates.map(({usage:n})=>`$ ${n}`).join(` -`)}`}else if(this.candidates.length===1){let[{usage:i}]=this.candidates;this.message=`Command not found; did you mean: - -$ ${i} -${lv(e)}`}else this.message=`Command not found; did you mean one of: - -${this.candidates.map(({usage:i},n)=>`${`${n}.`.padStart(4)} ${i}`).join(` -`)} - -${lv(e)}`}},cv=class extends Error{constructor(e,r){super();this.input=e,this.usages=r,this.clipanion={type:"none"},this.name="AmbiguousSyntaxError",this.message=`Cannot find which to pick amongst the following alternatives: - -${this.usages.map((i,n)=>`${`${n}.`.padStart(4)} ${i}`).join(` -`)} - -${lv(e)}`}},lv=t=>`While running ${t.filter(e=>e!==hi).map(e=>{let r=JSON.stringify(e);return e.match(/\s/)||e.length===0||r!==`"${e}"`?r:e}).join(" ")}`;var yh=Symbol("clipanion/isOption");function ji(t){return _(P({},t),{[yh]:!0})}function so(t,e){return typeof t=="undefined"?[t,e]:typeof t=="object"&&t!==null&&!Array.isArray(t)?[void 0,t]:[t,e]}function HE(t,e=!1){let r=t.replace(/^\.: /,"");return e&&(r=r[0].toLowerCase()+r.slice(1)),r}function wh(t,e){return e.length===1?new me(`${t}: ${HE(e[0],!0)}`):new me(`${t}: -${e.map(r=>` -- ${HE(r)}`).join("")}`)}function Bh(t,e,r){if(typeof r=="undefined")return e;let i=[],n=[],s=a=>{let l=e;return e=a,s.bind(null,l)};if(!r(e,{errors:i,coercions:n,coercion:s}))throw wh(`Invalid value for ${t}`,i);for(let[,a]of n)a();return e}var ye=class{constructor(){this.help=!1}static Usage(e){return e}async catch(e){throw e}async validateAndExecute(){let r=this.constructor.schema;if(typeof r!="undefined"){let{isDict:n,isUnknown:s,applyCascade:o}=await Promise.resolve().then(()=>(Ss(),lu)),a=o(n(s()),r),l=[],c=[];if(!a(this,{errors:l,coercions:c}))throw wh("Invalid option schema",l);for(let[,g]of c)g()}let i=await this.execute();return typeof i!="undefined"?i:0}};ye.isOption=yh;ye.Default=[];function un(t){Av&&console.log(t)}var BU={candidateUsage:null,requiredOptions:[],errorMessage:null,ignoreOptions:!1,path:[],positionals:[],options:[],remainder:null,selectedIndex:Au};function QU(){return{nodes:[qi(),qi(),qi()]}}function nCe(t){let e=QU(),r=[],i=e.nodes.length;for(let n of t){r.push(i);for(let s=0;s{if(e.has(i))return;e.add(i);let n=t.nodes[i];for(let o of Object.values(n.statics))for(let{to:a}of o)r(a);for(let[,{to:o}]of n.dynamics)r(o);for(let{to:o}of n.shortcuts)r(o);let s=new Set(n.shortcuts.map(({to:o})=>o));for(;n.shortcuts.length>0;){let{to:o}=n.shortcuts.shift(),a=t.nodes[o];for(let[l,c]of Object.entries(a.statics)){let u=Object.prototype.hasOwnProperty.call(n.statics,l)?n.statics[l]:n.statics[l]=[];for(let g of c)u.some(({to:f})=>g.to===f)||u.push(g)}for(let[l,c]of a.dynamics)n.dynamics.some(([u,{to:g}])=>l===u&&c.to===g)||n.dynamics.push([l,c]);for(let l of a.shortcuts)s.has(l.to)||(n.shortcuts.push(l),s.add(l.to))}};r(yl)}function oCe(t,{prefix:e=""}={}){if(Av){un(`${e}Nodes are:`);for(let r=0;rl!==Gi).map(({state:l})=>({usage:l.candidateUsage,reason:null})));if(a.every(({node:l})=>l===Gi))throw new Ih(e,a.map(({state:l})=>({usage:l.candidateUsage,reason:l.errorMessage})));i=aCe(a)}if(i.length>0){un(" Results:");for(let s of i)un(` - ${s.node} -> ${JSON.stringify(s.state)}`)}else un(" No results");return i}function ACe(t,e){if(e.selectedIndex!==null)return!0;if(Object.prototype.hasOwnProperty.call(t.statics,hi)){for(let{to:r}of t.statics[hi])if(r===Eh)return!0}return!1}function cCe(t,e,r){let i=r&&e.length>0?[""]:[],n=vU(t,e,r),s=[],o=new Set,a=(l,c,u=!0)=>{let g=[c];for(;g.length>0;){let h=g;g=[];for(let p of h){let d=t.nodes[p],m=Object.keys(d.statics);for(let I of Object.keys(d.statics)){let B=m[0];for(let{to:b,reducer:R}of d.statics[B])R==="pushPath"&&(u||l.push(B),g.push(b))}}u=!1}let f=JSON.stringify(l);o.has(f)||(s.push(l),o.add(f))};for(let{node:l,state:c}of n){if(c.remainder!==null){a([c.remainder],l);continue}let u=t.nodes[l],g=ACe(u,c);for(let[f,h]of Object.entries(u.statics))(g&&f!==hi||!f.startsWith("-")&&h.some(({reducer:p})=>p==="pushPath"))&&a([...i,f],l);if(!!g)for(let[f,{to:h}]of u.dynamics){if(h===Gi)continue;let p=lCe(f,c);if(p!==null)for(let d of p)a([...i,d],l)}}return[...s].sort()}function gCe(t,e){let r=vU(t,[...e,hi]);return uCe(e,r.map(({state:i})=>i))}function aCe(t){let e=0;for(let{state:r}of t)r.path.length>e&&(e=r.path.length);return t.filter(({state:r})=>r.path.length===e)}function uCe(t,e){let r=e.filter(g=>g.selectedIndex!==null);if(r.length===0)throw new Error;let i=r.filter(g=>g.requiredOptions.every(f=>f.some(h=>g.options.find(p=>p.name===h))));if(i.length===0)throw new Ih(t,r.map(g=>({usage:g.candidateUsage,reason:null})));let n=0;for(let g of i)g.path.length>n&&(n=g.path.length);let s=i.filter(g=>g.path.length===n),o=g=>g.positionals.filter(({extra:f})=>!f).length+g.options.length,a=s.map(g=>({state:g,positionalCount:o(g)})),l=0;for(let{positionalCount:g}of a)g>l&&(l=g);let c=a.filter(({positionalCount:g})=>g===l).map(({state:g})=>g),u=fCe(c);if(u.length>1)throw new cv(t,u.map(g=>g.candidateUsage));return u[0]}function fCe(t){let e=[],r=[];for(let i of t)i.selectedIndex===Au?r.push(i):e.push(i);return r.length>0&&e.push(_(P({},BU),{path:SU(...r.map(i=>i.path)),options:r.reduce((i,n)=>i.concat(n.options),[])})),e}function SU(t,e,...r){return e===void 0?Array.from(t):SU(t.filter((i,n)=>i===e[n]),...r)}function qi(){return{dynamics:[],shortcuts:[],statics:{}}}function bU(t){return t===Eh||t===Gi}function Cv(t,e=0){return{to:bU(t.to)?t.to:t.to>2?t.to+e-2:t.to+e,reducer:t.reducer}}function iCe(t,e=0){let r=qi();for(let[i,n]of t.dynamics)r.dynamics.push([i,Cv(n,e)]);for(let i of t.shortcuts)r.shortcuts.push(Cv(i,e));for(let[i,n]of Object.entries(t.statics))r.statics[i]=n.map(s=>Cv(s,e));return r}function pi(t,e,r,i,n){t.nodes[e].dynamics.push([r,{to:i,reducer:n}])}function cu(t,e,r,i){t.nodes[e].shortcuts.push({to:r,reducer:i})}function ta(t,e,r,i,n){(Object.prototype.hasOwnProperty.call(t.nodes[e].statics,r)?t.nodes[e].statics[r]:t.nodes[e].statics[r]=[]).push({to:i,reducer:n})}function jE(t,e,r,i){if(Array.isArray(e)){let[n,...s]=e;return t[n](r,i,...s)}else return t[e](r,i)}function lCe(t,e){let r=Array.isArray(t)?YE[t[0]]:YE[t];if(typeof r.suggest=="undefined")return null;let i=Array.isArray(t)?t.slice(1):[];return r.suggest(e,...i)}var YE={always:()=>!0,isOptionLike:(t,e)=>!t.ignoreOptions&&e!=="-"&&e.startsWith("-"),isNotOptionLike:(t,e)=>t.ignoreOptions||e==="-"||!e.startsWith("-"),isOption:(t,e,r,i)=>!t.ignoreOptions&&e===r,isBatchOption:(t,e,r)=>!t.ignoreOptions&&fU.test(e)&&[...e.slice(1)].every(i=>r.includes(`-${i}`)),isBoundOption:(t,e,r,i)=>{let n=e.match(av);return!t.ignoreOptions&&!!n&&UE.test(n[1])&&r.includes(n[1])&&i.filter(s=>s.names.includes(n[1])).every(s=>s.allowBinding)},isNegatedOption:(t,e,r)=>!t.ignoreOptions&&e===`--no-${r.slice(2)}`,isHelp:(t,e)=>!t.ignoreOptions&&ov.test(e),isUnsupportedOption:(t,e,r)=>!t.ignoreOptions&&e.startsWith("-")&&UE.test(e)&&!r.includes(e),isInvalidOption:(t,e)=>!t.ignoreOptions&&e.startsWith("-")&&!UE.test(e)};YE.isOption.suggest=(t,e,r=!0)=>r?null:[e];var dv={setCandidateState:(t,e,r)=>P(P({},t),r),setSelectedIndex:(t,e,r)=>_(P({},t),{selectedIndex:r}),pushBatch:(t,e)=>_(P({},t),{options:t.options.concat([...e.slice(1)].map(r=>({name:`-${r}`,value:!0})))}),pushBound:(t,e)=>{let[,r,i]=e.match(av);return _(P({},t),{options:t.options.concat({name:r,value:i})})},pushPath:(t,e)=>_(P({},t),{path:t.path.concat(e)}),pushPositional:(t,e)=>_(P({},t),{positionals:t.positionals.concat({value:e,extra:!1})}),pushExtra:(t,e)=>_(P({},t),{positionals:t.positionals.concat({value:e,extra:!0})}),pushExtraNoLimits:(t,e)=>_(P({},t),{positionals:t.positionals.concat({value:e,extra:Ln})}),pushTrue:(t,e,r=e)=>_(P({},t),{options:t.options.concat({name:e,value:!0})}),pushFalse:(t,e,r=e)=>_(P({},t),{options:t.options.concat({name:r,value:!1})}),pushUndefined:(t,e)=>_(P({},t),{options:t.options.concat({name:e,value:void 0})}),pushStringValue:(t,e)=>{var r;let i=_(P({},t),{options:[...t.options]}),n=t.options[t.options.length-1];return n.value=((r=n.value)!==null&&r!==void 0?r:[]).concat([e]),i},setStringValue:(t,e)=>{let r=_(P({},t),{options:[...t.options]}),i=t.options[t.options.length-1];return i.value=e,r},inhibateOptions:t=>_(P({},t),{ignoreOptions:!0}),useHelp:(t,e,r)=>{let[,,i]=e.match(ov);return typeof i!="undefined"?_(P({},t),{options:[{name:"-c",value:String(r)},{name:"-i",value:i}]}):_(P({},t),{options:[{name:"-c",value:String(r)}]})},setError:(t,e,r)=>e===hi?_(P({},t),{errorMessage:`${r}.`}):_(P({},t),{errorMessage:`${r} ("${e}").`}),setOptionArityError:(t,e)=>{let r=t.options[t.options.length-1];return _(P({},t),{errorMessage:`Not enough arguments to option ${r.name}.`})}},Ln=Symbol(),xU=class{constructor(e,r){this.allOptionNames=[],this.arity={leading:[],trailing:[],extra:[],proxy:!1},this.options=[],this.paths=[],this.cliIndex=e,this.cliOpts=r}addPath(e){this.paths.push(e)}setArity({leading:e=this.arity.leading,trailing:r=this.arity.trailing,extra:i=this.arity.extra,proxy:n=this.arity.proxy}){Object.assign(this.arity,{leading:e,trailing:r,extra:i,proxy:n})}addPositional({name:e="arg",required:r=!0}={}){if(!r&&this.arity.extra===Ln)throw new Error("Optional parameters cannot be declared when using .rest() or .proxy()");if(!r&&this.arity.trailing.length>0)throw new Error("Optional parameters cannot be declared after the required trailing positional arguments");!r&&this.arity.extra!==Ln?this.arity.extra.push(e):this.arity.extra!==Ln&&this.arity.extra.length===0?this.arity.leading.push(e):this.arity.trailing.push(e)}addRest({name:e="arg",required:r=0}={}){if(this.arity.extra===Ln)throw new Error("Infinite lists cannot be declared multiple times in the same command");if(this.arity.trailing.length>0)throw new Error("Infinite lists cannot be declared after the required trailing positional arguments");for(let i=0;i1)throw new Error("The arity cannot be higher than 1 when the option only supports the --arg=value syntax");if(!Number.isInteger(i))throw new Error(`The arity must be an integer, got ${i}`);if(i<0)throw new Error(`The arity must be positive, got ${i}`);this.allOptionNames.push(...e),this.options.push({names:e,description:r,arity:i,hidden:n,required:s,allowBinding:o})}setContext(e){this.context=e}usage({detailed:e=!0,inlineOptions:r=!0}={}){let i=[this.cliOpts.binaryName],n=[];if(this.paths.length>0&&i.push(...this.paths[0]),e){for(let{names:o,arity:a,hidden:l,description:c,required:u}of this.options){if(l)continue;let g=[];for(let h=0;h`:`[${f}]`)}i.push(...this.arity.leading.map(o=>`<${o}>`)),this.arity.extra===Ln?i.push("..."):i.push(...this.arity.extra.map(o=>`[${o}]`)),i.push(...this.arity.trailing.map(o=>`<${o}>`))}return{usage:i.join(" "),options:n}}compile(){if(typeof this.context=="undefined")throw new Error("Assertion failed: No context attached");let e=QU(),r=yl,i=this.usage().usage,n=this.options.filter(a=>a.required).map(a=>a.names);r=xs(e,qi()),ta(e,yl,sv,r,["setCandidateState",{candidateUsage:i,requiredOptions:n}]);let s=this.arity.proxy?"always":"isNotOptionLike",o=this.paths.length>0?this.paths:[[]];for(let a of o){let l=r;if(a.length>0){let f=xs(e,qi());cu(e,l,f),this.registerOptions(e,f),l=f}for(let f=0;f0||!this.arity.proxy){let f=xs(e,qi());pi(e,l,"isHelp",f,["useHelp",this.cliIndex]),ta(e,f,hi,Eh,["setSelectedIndex",Au]),this.registerOptions(e,l)}this.arity.leading.length>0&&ta(e,l,hi,Gi,["setError","Not enough positional arguments"]);let c=l;for(let f=0;f0||f+1!==this.arity.leading.length)&&ta(e,h,hi,Gi,["setError","Not enough positional arguments"]),pi(e,c,"isNotOptionLike",h,"pushPositional"),c=h}let u=c;if(this.arity.extra===Ln||this.arity.extra.length>0){let f=xs(e,qi());if(cu(e,c,f),this.arity.extra===Ln){let h=xs(e,qi());this.arity.proxy||this.registerOptions(e,h),pi(e,c,s,h,"pushExtraNoLimits"),pi(e,h,s,h,"pushExtraNoLimits"),cu(e,h,f)}else for(let h=0;h0&&ta(e,u,hi,Gi,["setError","Not enough positional arguments"]);let g=u;for(let f=0;fo.length>s.length?o:s,"");if(i.arity===0)for(let s of i.names)pi(e,r,["isOption",s,i.hidden||s!==n],r,"pushTrue"),s.startsWith("--")&&!s.startsWith("--no-")&&pi(e,r,["isNegatedOption",s],r,["pushFalse",s]);else{let s=xs(e,qi());for(let o of i.names)pi(e,r,["isOption",o,i.hidden||o!==n],s,"pushUndefined");for(let o=0;o=0&&egCe(i,n),suggest:(n,s)=>cCe(i,n,s)}}};var kU=80,mv=Array(kU).fill("\u2501");for(let t=0;t<=24;++t)mv[mv.length-t]=`[38;5;${232+t}m\u2501`;var Ev={header:t=>`\u2501\u2501\u2501 ${t}${t.length`${t}`,error:t=>`${t}`,code:t=>`${t}`},PU={header:t=>t,bold:t=>t,error:t=>t,code:t=>t};function hCe(t){let e=t.split(` -`),r=e.filter(n=>n.match(/\S/)),i=r.length>0?r.reduce((n,s)=>Math.min(n,s.length-s.trimStart().length),Number.MAX_VALUE):0;return e.map(n=>n.slice(i).trimRight()).join(` -`)}function Vn(t,{format:e,paragraphs:r}){return t=t.replace(/\r\n?/g,` -`),t=hCe(t),t=t.replace(/^\n+|\n+$/g,""),t=t.replace(/^(\s*)-([^\n]*?)\n+/gm,`$1-$2 - -`),t=t.replace(/\n(\n)?\n*/g,"$1"),r&&(t=t.split(/\n/).map(i=>{let n=i.match(/^\s*[*-][\t ]+(.*)/);if(!n)return i.match(/(.{1,80})(?: |$)/g).join(` -`);let s=i.length-i.trimStart().length;return n[1].match(new RegExp(`(.{1,${78-s}})(?: |$)`,"g")).map((o,a)=>" ".repeat(s)+(a===0?"- ":" ")+o).join(` -`)}).join(` - -`)),t=t.replace(/(`+)((?:.|[\n])*?)\1/g,(i,n,s)=>e.code(n+s+n)),t=t.replace(/(\*\*)((?:.|[\n])*?)\1/g,(i,n,s)=>e.bold(n+s+n)),t?`${t} -`:""}var bh=class extends ye{constructor(e){super();this.contexts=e,this.commands=[]}static from(e,r){let i=new bh(r);i.path=e.path;for(let n of e.options)switch(n.name){case"-c":i.commands.push(Number(n.value));break;case"-i":i.index=Number(n.value);break}return i}async execute(){let e=this.commands;if(typeof this.index!="undefined"&&this.index>=0&&this.index1){this.context.stdout.write(`Multiple commands match your selection: -`),this.context.stdout.write(` -`);let r=0;for(let i of this.commands)this.context.stdout.write(this.cli.usage(this.contexts[i].commandClass,{prefix:`${r++}. `.padStart(5)}));this.context.stdout.write(` -`),this.context.stdout.write(`Run again with -h= to see the longer details of any of those commands. -`)}}};var DU=Symbol("clipanion/errorCommand");function pCe(){return process.env.FORCE_COLOR==="0"?!1:!!(process.env.FORCE_COLOR==="1"||typeof process.stdout!="undefined"&&process.stdout.isTTY)}var oo=class{constructor({binaryLabel:e,binaryName:r="...",binaryVersion:i,enableColors:n=pCe()}={}){this.registrations=new Map,this.builder=new Qh({binaryName:r}),this.binaryLabel=e,this.binaryName=r,this.binaryVersion=i,this.enableColors=n}static from(e,r={}){let i=new oo(r);for(let n of e)i.register(n);return i}register(e){var r;let i=new Map,n=new e;for(let l in n){let c=n[l];typeof c=="object"&&c!==null&&c[ye.isOption]&&i.set(l,c)}let s=this.builder.command(),o=s.cliIndex,a=(r=e.paths)!==null&&r!==void 0?r:n.paths;if(typeof a!="undefined")for(let l of a)s.addPath(l);this.registrations.set(e,{specs:i,builder:s,index:o});for(let[l,{definition:c}]of i.entries())c(s,l);s.setContext({commandClass:e})}process(e){let{contexts:r,process:i}=this.builder.compile(),n=i(e);switch(n.selectedIndex){case Au:return bh.from(n,r);default:{let{commandClass:s}=r[n.selectedIndex],o=this.registrations.get(s);if(typeof o=="undefined")throw new Error("Assertion failed: Expected the command class to have been registered.");let a=new s;a.path=n.path;try{for(let[l,{transformer:c}]of o.specs.entries())a[l]=c(o.builder,l,n);return a}catch(l){throw l[DU]=a,l}}break}}async run(e,r){let i;if(!Array.isArray(e))i=e;else try{i=this.process(e)}catch(s){return r.stdout.write(this.error(s)),1}if(i.help)return r.stdout.write(this.usage(i,{detailed:!0})),0;i.context=r,i.cli={binaryLabel:this.binaryLabel,binaryName:this.binaryName,binaryVersion:this.binaryVersion,enableColors:this.enableColors,definitions:()=>this.definitions(),error:(s,o)=>this.error(s,o),process:s=>this.process(s),run:(s,o)=>this.run(s,P(P({},r),o)),usage:(s,o)=>this.usage(s,o)};let n;try{n=await i.validateAndExecute().catch(s=>i.catch(s).then(()=>0))}catch(s){return r.stdout.write(this.error(s,{command:i})),1}return n}async runExit(e,r){process.exitCode=await this.run(e,r)}suggest(e,r){let{suggest:i}=this.builder.compile();return i(e,r)}definitions({colored:e=!1}={}){let r=[];for(let[i,{index:n}]of this.registrations){if(typeof i.usage=="undefined")continue;let{usage:s}=this.getUsageByIndex(n,{detailed:!1}),{usage:o,options:a}=this.getUsageByIndex(n,{detailed:!0,inlineOptions:!1}),l=typeof i.usage.category!="undefined"?Vn(i.usage.category,{format:this.format(e),paragraphs:!1}):void 0,c=typeof i.usage.description!="undefined"?Vn(i.usage.description,{format:this.format(e),paragraphs:!1}):void 0,u=typeof i.usage.details!="undefined"?Vn(i.usage.details,{format:this.format(e),paragraphs:!0}):void 0,g=typeof i.usage.examples!="undefined"?i.usage.examples.map(([f,h])=>[Vn(f,{format:this.format(e),paragraphs:!1}),h.replace(/\$0/g,this.binaryName)]):void 0;r.push({path:s,usage:o,category:l,description:c,details:u,examples:g,options:a})}return r}usage(e=null,{colored:r,detailed:i=!1,prefix:n="$ "}={}){var s;if(e===null){for(let l of this.registrations.keys()){let c=l.paths,u=typeof l.usage!="undefined";if(!c||c.length===0||c.length===1&&c[0].length===0||((s=c==null?void 0:c.some(h=>h.length===0))!==null&&s!==void 0?s:!1))if(e){e=null;break}else e=l;else if(u){e=null;continue}}e&&(i=!0)}let o=e!==null&&e instanceof ye?e.constructor:e,a="";if(o)if(i){let{description:l="",details:c="",examples:u=[]}=o.usage||{};l!==""&&(a+=Vn(l,{format:this.format(r),paragraphs:!1}).replace(/^./,h=>h.toUpperCase()),a+=` -`),(c!==""||u.length>0)&&(a+=`${this.format(r).header("Usage")} -`,a+=` -`);let{usage:g,options:f}=this.getUsageByRegistration(o,{inlineOptions:!1});if(a+=`${this.format(r).bold(n)}${g} -`,f.length>0){a+=` -`,a+=`${Ev.header("Options")} -`;let h=f.reduce((p,d)=>Math.max(p,d.definition.length),0);a+=` -`;for(let{definition:p,description:d}of f)a+=` ${this.format(r).bold(p.padEnd(h))} ${Vn(d,{format:this.format(r),paragraphs:!1})}`}if(c!==""&&(a+=` -`,a+=`${this.format(r).header("Details")} -`,a+=` -`,a+=Vn(c,{format:this.format(r),paragraphs:!0})),u.length>0){a+=` -`,a+=`${this.format(r).header("Examples")} -`;for(let[h,p]of u)a+=` -`,a+=Vn(h,{format:this.format(r),paragraphs:!1}),a+=`${p.replace(/^/m,` ${this.format(r).bold(n)}`).replace(/\$0/g,this.binaryName)} -`}}else{let{usage:l}=this.getUsageByRegistration(o);a+=`${this.format(r).bold(n)}${l} -`}else{let l=new Map;for(let[f,{index:h}]of this.registrations.entries()){if(typeof f.usage=="undefined")continue;let p=typeof f.usage.category!="undefined"?Vn(f.usage.category,{format:this.format(r),paragraphs:!1}):null,d=l.get(p);typeof d=="undefined"&&l.set(p,d=[]);let{usage:m}=this.getUsageByIndex(h);d.push({commandClass:f,usage:m})}let c=Array.from(l.keys()).sort((f,h)=>f===null?-1:h===null?1:f.localeCompare(h,"en",{usage:"sort",caseFirst:"upper"})),u=typeof this.binaryLabel!="undefined",g=typeof this.binaryVersion!="undefined";u||g?(u&&g?a+=`${this.format(r).header(`${this.binaryLabel} - ${this.binaryVersion}`)} - -`:u?a+=`${this.format(r).header(`${this.binaryLabel}`)} -`:a+=`${this.format(r).header(`${this.binaryVersion}`)} -`,a+=` ${this.format(r).bold(n)}${this.binaryName} -`):a+=`${this.format(r).bold(n)}${this.binaryName} -`;for(let f of c){let h=l.get(f).slice().sort((d,m)=>d.usage.localeCompare(m.usage,"en",{usage:"sort",caseFirst:"upper"})),p=f!==null?f.trim():"General commands";a+=` -`,a+=`${this.format(r).header(`${p}`)} -`;for(let{commandClass:d,usage:m}of h){let I=d.usage.description||"undocumented";a+=` -`,a+=` ${this.format(r).bold(m)} -`,a+=` ${Vn(I,{format:this.format(r),paragraphs:!1})}`}}a+=` -`,a+=Vn("You can also print more details about any of these commands by calling them with the `-h,--help` flag right after the command name.",{format:this.format(r),paragraphs:!0})}return a}error(e,r){var i,{colored:n,command:s=(i=e[DU])!==null&&i!==void 0?i:null}=r===void 0?{}:r;e instanceof Error||(e=new Error(`Execution failed with a non-error rejection (rejected value: ${JSON.stringify(e)})`));let o="",a=e.name.replace(/([a-z])([A-Z])/g,"$1 $2");a==="Error"&&(a="Internal Error"),o+=`${this.format(n).error(a)}: ${e.message} -`;let l=e.clipanion;return typeof l!="undefined"?l.type==="usage"&&(o+=` -`,o+=this.usage(s)):e.stack&&(o+=`${e.stack.replace(/^.*\n/,"")} -`),o}getUsageByRegistration(e,r){let i=this.registrations.get(e);if(typeof i=="undefined")throw new Error("Assertion failed: Unregistered command");return this.getUsageByIndex(i.index,r)}getUsageByIndex(e,r){return this.builder.getBuilderByIndex(e).usage(r)}format(e=this.enableColors){return e?Ev:PU}};oo.defaultContext={stdin:process.stdin,stdout:process.stdout,stderr:process.stderr};var Iv={};it(Iv,{DefinitionsCommand:()=>qE,HelpCommand:()=>JE,VersionCommand:()=>WE});var qE=class extends ye{async execute(){this.context.stdout.write(`${JSON.stringify(this.cli.definitions(),null,2)} -`)}};qE.paths=[["--clipanion=definitions"]];var JE=class extends ye{async execute(){this.context.stdout.write(this.cli.usage())}};JE.paths=[["-h"],["--help"]];var WE=class extends ye{async execute(){var e;this.context.stdout.write(`${(e=this.cli.binaryVersion)!==null&&e!==void 0?e:""} -`)}};WE.paths=[["-v"],["--version"]];var Y={};it(Y,{Array:()=>RU,Boolean:()=>FU,Counter:()=>NU,Proxy:()=>LU,Rest:()=>TU,String:()=>MU,applyValidator:()=>Bh,cleanValidationError:()=>HE,formatError:()=>wh,isOptionSymbol:()=>yh,makeCommandOption:()=>ji,rerouteArguments:()=>so});function RU(t,e,r){let[i,n]=so(e,r!=null?r:{}),{arity:s=1}=n,o=t.split(","),a=new Set(o);return ji({definition(l){l.addOption({names:o,arity:s,hidden:n==null?void 0:n.hidden,description:n==null?void 0:n.description,required:n.required})},transformer(l,c,u){let g=typeof i!="undefined"?[...i]:void 0;for(let{name:f,value:h}of u.options)!a.has(f)||(g=g!=null?g:[],g.push(h));return g}})}function FU(t,e,r){let[i,n]=so(e,r!=null?r:{}),s=t.split(","),o=new Set(s);return ji({definition(a){a.addOption({names:s,allowBinding:!1,arity:0,hidden:n.hidden,description:n.description,required:n.required})},transformer(a,l,c){let u=i;for(let{name:g,value:f}of c.options)!o.has(g)||(u=f);return u}})}function NU(t,e,r){let[i,n]=so(e,r!=null?r:{}),s=t.split(","),o=new Set(s);return ji({definition(a){a.addOption({names:s,allowBinding:!1,arity:0,hidden:n.hidden,description:n.description,required:n.required})},transformer(a,l,c){let u=i;for(let{name:g,value:f}of c.options)!o.has(g)||(u!=null||(u=0),f?u+=1:u=0);return u}})}function LU(t={}){return ji({definition(e,r){var i;e.addProxy({name:(i=t.name)!==null&&i!==void 0?i:r,required:t.required})},transformer(e,r,i){return i.positionals.map(({value:n})=>n)}})}function TU(t={}){return ji({definition(e,r){var i;e.addRest({name:(i=t.name)!==null&&i!==void 0?i:r,required:t.required})},transformer(e,r,i){let n=o=>{let a=i.positionals[o];return a.extra===Ln||a.extra===!1&&oo)}})}function dCe(t,e,r){let[i,n]=so(e,r!=null?r:{}),{arity:s=1}=n,o=t.split(","),a=new Set(o);return ji({definition(l){l.addOption({names:o,arity:n.tolerateBoolean?0:s,hidden:n.hidden,description:n.description,required:n.required})},transformer(l,c,u){let g,f=i;for(let{name:h,value:p}of u.options)!a.has(h)||(g=h,f=p);return typeof f=="string"?Bh(g!=null?g:c,f,n.validator):f}})}function CCe(t={}){let{required:e=!0}=t;return ji({definition(r,i){var n;r.addPositional({name:(n=t.name)!==null&&n!==void 0?n:i,required:t.required})},transformer(r,i,n){var s;for(let o=0;oJSON.stringify(i)).join(", ")})`);return e}function kl(t,e){let r=[];for(let i of t){let n=e(i);n!==LH&&r.push(n)}return r}var LH=Symbol();kl.skip=LH;function MH(t,e){for(let r of t){let i=e(r);if(i!==TH)return i}}var TH=Symbol();MH.skip=TH;function Tv(t){return typeof t=="object"&&t!==null}function aI(t){if(t instanceof Map&&(t=Object.fromEntries(t)),Tv(t))for(let e of Object.keys(t)){let r=t[e];Tv(r)&&(t[e]=aI(r))}return t}function na(t,e,r){let i=t.get(e);return typeof i=="undefined"&&t.set(e,i=r()),i}function hu(t,e){let r=t.get(e);return typeof r=="undefined"&&t.set(e,r=[]),r}function Pl(t,e){let r=t.get(e);return typeof r=="undefined"&&t.set(e,r=new Set),r}function pu(t,e){let r=t.get(e);return typeof r=="undefined"&&t.set(e,r=new Map),r}async function kEe(t,e){if(e==null)return await t();try{return await t()}finally{await e()}}async function du(t,e){try{return await t()}catch(r){throw r.message=e(r.message),r}}function Mv(t,e){try{return t()}catch(r){throw r.message=e(r.message),r}}async function Cu(t){return await new Promise((e,r)=>{let i=[];t.on("error",n=>{r(n)}),t.on("data",n=>{i.push(n)}),t.on("end",()=>{e(Buffer.concat(i))})})}var OH=class extends Fv.Transform{constructor(){super(...arguments);this.chunks=[]}_transform(e,r,i){if(r!=="buffer"||!Buffer.isBuffer(e))throw new Error("Assertion failed: BufferStream only accept buffers");this.chunks.push(e),i(null,null)}_flush(e){e(null,Buffer.concat(this.chunks))}},KH=class extends Fv.Transform{constructor(e=Buffer.alloc(0)){super();this.active=!0;this.ifEmpty=e}_transform(e,r,i){if(r!=="buffer"||!Buffer.isBuffer(e))throw new Error("Assertion failed: DefaultStream only accept buffers");this.active=!1,i(null,e)}_flush(e){this.active&&this.ifEmpty.length>0?e(null,this.ifEmpty):e(null)}},Uh=eval("require");function UH(t){return Uh(M.fromPortablePath(t))}function HH(path){let physicalPath=M.fromPortablePath(path),currentCacheEntry=Uh.cache[physicalPath];delete Uh.cache[physicalPath];let result;try{result=UH(physicalPath);let freshCacheEntry=Uh.cache[physicalPath],dynamicModule=eval("module"),freshCacheIndex=dynamicModule.children.indexOf(freshCacheEntry);freshCacheIndex!==-1&&dynamicModule.children.splice(freshCacheIndex,1)}finally{Uh.cache[physicalPath]=currentCacheEntry}return result}var GH=new Map;function PEe(t){let e=GH.get(t),r=T.statSync(t);if((e==null?void 0:e.mtime)===r.mtimeMs)return e.instance;let i=HH(t);return GH.set(t,{mtime:r.mtimeMs,instance:i}),i}var Dl;(function(i){i[i.NoCache=0]="NoCache",i[i.FsTime=1]="FsTime",i[i.Node=2]="Node"})(Dl||(Dl={}));function mu(t,{cachingStrategy:e=2}={}){switch(e){case 0:return HH(t);case 1:return PEe(t);case 2:return UH(t);default:throw new Error("Unsupported caching strategy")}}function gn(t,e){let r=Array.from(t);Array.isArray(e)||(e=[e]);let i=[];for(let s of e)i.push(r.map(o=>s(o)));let n=r.map((s,o)=>o);return n.sort((s,o)=>{for(let a of i){let l=a[s]a[o]?1:0;if(l!==0)return l}return 0}),n.map(s=>r[s])}function DEe(t){return t.length===0?null:t.map(e=>`(${FH.default.makeRe(e,{windows:!1,dot:!0}).source})`).join("|")}function Ov(t,{env:e}){let r=/\${(?[\d\w_]+)(?:)?(?:-(?[^}]*))?}/g;return t.replace(r,(...i)=>{let{variableName:n,colon:s,fallback:o}=i[i.length-1],a=Object.prototype.hasOwnProperty.call(e,n),l=e[n];if(l||a&&!s)return l;if(o!=null)return o;throw new me(`Environment variable not found (${n})`)})}function Hh(t){switch(t){case"true":case"1":case 1:case!0:return!0;case"false":case"0":case 0:case!1:return!1;default:throw new Error(`Couldn't parse "${t}" as a boolean`)}}function jH(t){return typeof t=="undefined"?t:Hh(t)}function Kv(t){try{return jH(t)}catch{return null}}function REe(t){return!!(M.isAbsolute(t)||t.match(/^(\.{1,2}|~)\//))}var S={};it(S,{areDescriptorsEqual:()=>i3,areIdentsEqual:()=>cp,areLocatorsEqual:()=>up,areVirtualPackagesEquivalent:()=>XQe,bindDescriptor:()=>VQe,bindLocator:()=>_Qe,convertDescriptorToLocator:()=>By,convertLocatorToDescriptor:()=>WQe,convertPackageToLocator:()=>zQe,convertToIdent:()=>JQe,convertToManifestRange:()=>ebe,copyPackage:()=>ap,devirtualizeDescriptor:()=>Ap,devirtualizeLocator:()=>lp,getIdentVendorPath:()=>Lx,isPackageCompatible:()=>Sy,isVirtualDescriptor:()=>hA,isVirtualLocator:()=>Io,makeDescriptor:()=>Yt,makeIdent:()=>Eo,makeLocator:()=>Vi,makeRange:()=>by,parseDescriptor:()=>pA,parseFileStyleRange:()=>ZQe,parseIdent:()=>En,parseLocator:()=>Hl,parseRange:()=>Tu,prettyDependent:()=>Nx,prettyDescriptor:()=>Xt,prettyIdent:()=>Vr,prettyLocator:()=>lt,prettyLocatorNoColors:()=>Rx,prettyRange:()=>yy,prettyReference:()=>fp,prettyResolution:()=>Fx,prettyWorkspace:()=>hp,renamePackage:()=>op,slugifyIdent:()=>Dx,slugifyLocator:()=>Mu,sortDescriptors:()=>Ou,stringifyDescriptor:()=>In,stringifyIdent:()=>St,stringifyLocator:()=>is,tryParseDescriptor:()=>gp,tryParseIdent:()=>n3,tryParseLocator:()=>Qy,virtualizeDescriptor:()=>kx,virtualizePackage:()=>Px});var Lu=ie(require("querystring")),e3=ie(Or()),t3=ie(wY());var mn={};it(mn,{checksumFile:()=>Ey,checksumPattern:()=>Iy,makeHash:()=>zi});var my=ie(require("crypto")),Sx=ie(vx());function zi(...t){let e=(0,my.createHash)("sha512"),r="";for(let i of t)typeof i=="string"?r+=i:i&&(r&&(e.update(r),r=""),e.update(i));return r&&e.update(r),e.digest("hex")}async function Ey(t,{baseFs:e,algorithm:r}={baseFs:T,algorithm:"sha512"}){let i=await e.openPromise(t,"r");try{let n=65536,s=Buffer.allocUnsafeSlow(n),o=(0,my.createHash)(r),a=0;for(;(a=await e.readPromise(i,s,0,n))!==0;)o.update(a===n?s:s.slice(0,a));return o.digest("hex")}finally{await e.closePromise(i)}}async function Iy(t,{cwd:e}){let i=(await(0,Sx.default)(t,{cwd:M.fromPortablePath(e),expandDirectories:!1,onlyDirectories:!0,unique:!0})).map(a=>`${a}/**/*`),n=await(0,Sx.default)([t,...i],{cwd:M.fromPortablePath(e),expandDirectories:!1,onlyFiles:!1,unique:!0});n.sort();let s=await Promise.all(n.map(async a=>{let l=[Buffer.from(a)],c=M.toPortablePath(a),u=await T.lstatPromise(c);return u.isSymbolicLink()?l.push(Buffer.from(await T.readlinkPromise(c))):u.isFile()&&l.push(await T.readFilePromise(c)),l.join("\0")})),o=(0,my.createHash)("sha512");for(let a of s)o.update(a);return o.digest("hex")}var wy="virtual:",YQe=5,r3=/(os|cpu)=([a-z0-9_-]+)/,qQe=(0,t3.makeParser)(r3);function Eo(t,e){if(t==null?void 0:t.startsWith("@"))throw new Error("Invalid scope: don't prefix it with '@'");return{identHash:zi(t,e),scope:t,name:e}}function Yt(t,e){return{identHash:t.identHash,scope:t.scope,name:t.name,descriptorHash:zi(t.identHash,e),range:e}}function Vi(t,e){return{identHash:t.identHash,scope:t.scope,name:t.name,locatorHash:zi(t.identHash,e),reference:e}}function JQe(t){return{identHash:t.identHash,scope:t.scope,name:t.name}}function By(t){return{identHash:t.identHash,scope:t.scope,name:t.name,locatorHash:t.descriptorHash,reference:t.range}}function WQe(t){return{identHash:t.identHash,scope:t.scope,name:t.name,descriptorHash:t.locatorHash,range:t.reference}}function zQe(t){return{identHash:t.identHash,scope:t.scope,name:t.name,locatorHash:t.locatorHash,reference:t.reference}}function op(t,e){return{identHash:e.identHash,scope:e.scope,name:e.name,locatorHash:e.locatorHash,reference:e.reference,version:t.version,languageName:t.languageName,linkType:t.linkType,conditions:t.conditions,dependencies:new Map(t.dependencies),peerDependencies:new Map(t.peerDependencies),dependenciesMeta:new Map(t.dependenciesMeta),peerDependenciesMeta:new Map(t.peerDependenciesMeta),bin:new Map(t.bin)}}function ap(t){return op(t,t)}function kx(t,e){if(e.includes("#"))throw new Error("Invalid entropy");return Yt(t,`virtual:${e}#${t.range}`)}function Px(t,e){if(e.includes("#"))throw new Error("Invalid entropy");return op(t,Vi(t,`virtual:${e}#${t.reference}`))}function hA(t){return t.range.startsWith(wy)}function Io(t){return t.reference.startsWith(wy)}function Ap(t){if(!hA(t))throw new Error("Not a virtual descriptor");return Yt(t,t.range.replace(/^[^#]*#/,""))}function lp(t){if(!Io(t))throw new Error("Not a virtual descriptor");return Vi(t,t.reference.replace(/^[^#]*#/,""))}function VQe(t,e){return t.range.includes("::")?t:Yt(t,`${t.range}::${Lu.default.stringify(e)}`)}function _Qe(t,e){return t.reference.includes("::")?t:Vi(t,`${t.reference}::${Lu.default.stringify(e)}`)}function cp(t,e){return t.identHash===e.identHash}function i3(t,e){return t.descriptorHash===e.descriptorHash}function up(t,e){return t.locatorHash===e.locatorHash}function XQe(t,e){if(!Io(t))throw new Error("Invalid package type");if(!Io(e))throw new Error("Invalid package type");if(!cp(t,e)||t.dependencies.size!==e.dependencies.size)return!1;for(let r of t.dependencies.values()){let i=e.dependencies.get(r.identHash);if(!i||!i3(r,i))return!1}return!0}function En(t){let e=n3(t);if(!e)throw new Error(`Invalid ident (${t})`);return e}function n3(t){let e=t.match(/^(?:@([^/]+?)\/)?([^/]+)$/);if(!e)return null;let[,r,i]=e,n=typeof r!="undefined"?r:null;return Eo(n,i)}function pA(t,e=!1){let r=gp(t,e);if(!r)throw new Error(`Invalid descriptor (${t})`);return r}function gp(t,e=!1){let r=e?t.match(/^(?:@([^/]+?)\/)?([^/]+?)(?:@(.+))$/):t.match(/^(?:@([^/]+?)\/)?([^/]+?)(?:@(.+))?$/);if(!r)return null;let[,i,n,s]=r;if(s==="unknown")throw new Error(`Invalid range (${t})`);let o=typeof i!="undefined"?i:null,a=typeof s!="undefined"?s:"unknown";return Yt(Eo(o,n),a)}function Hl(t,e=!1){let r=Qy(t,e);if(!r)throw new Error(`Invalid locator (${t})`);return r}function Qy(t,e=!1){let r=e?t.match(/^(?:@([^/]+?)\/)?([^/]+?)(?:@(.+))$/):t.match(/^(?:@([^/]+?)\/)?([^/]+?)(?:@(.+))?$/);if(!r)return null;let[,i,n,s]=r;if(s==="unknown")throw new Error(`Invalid reference (${t})`);let o=typeof i!="undefined"?i:null,a=typeof s!="undefined"?s:"unknown";return Vi(Eo(o,n),a)}function Tu(t,e){let r=t.match(/^([^#:]*:)?((?:(?!::)[^#])*)(?:#((?:(?!::).)*))?(?:::(.*))?$/);if(r===null)throw new Error(`Invalid range (${t})`);let i=typeof r[1]!="undefined"?r[1]:null;if(typeof(e==null?void 0:e.requireProtocol)=="string"&&i!==e.requireProtocol)throw new Error(`Invalid protocol (${i})`);if((e==null?void 0:e.requireProtocol)&&i===null)throw new Error(`Missing protocol (${i})`);let n=typeof r[3]!="undefined"?decodeURIComponent(r[2]):null;if((e==null?void 0:e.requireSource)&&n===null)throw new Error(`Missing source (${t})`);let s=typeof r[3]!="undefined"?decodeURIComponent(r[3]):decodeURIComponent(r[2]),o=(e==null?void 0:e.parseSelector)?Lu.default.parse(s):s,a=typeof r[4]!="undefined"?Lu.default.parse(r[4]):null;return{protocol:i,source:n,selector:o,params:a}}function ZQe(t,{protocol:e}){let{selector:r,params:i}=Tu(t,{requireProtocol:e,requireBindings:!0});if(typeof i.locator!="string")throw new Error(`Assertion failed: Invalid bindings for ${t}`);return{parentLocator:Hl(i.locator,!0),path:r}}function s3(t){return t=t.replace(/%/g,"%25"),t=t.replace(/:/g,"%3A"),t=t.replace(/#/g,"%23"),t}function $Qe(t){return t===null?!1:Object.entries(t).length>0}function by({protocol:t,source:e,selector:r,params:i}){let n="";return t!==null&&(n+=`${t}`),e!==null&&(n+=`${s3(e)}#`),n+=s3(r),$Qe(i)&&(n+=`::${Lu.default.stringify(i)}`),n}function ebe(t){let{params:e,protocol:r,source:i,selector:n}=Tu(t);for(let s in e)s.startsWith("__")&&delete e[s];return by({protocol:r,source:i,params:e,selector:n})}function St(t){return t.scope?`@${t.scope}/${t.name}`:`${t.name}`}function In(t){return t.scope?`@${t.scope}/${t.name}@${t.range}`:`${t.name}@${t.range}`}function is(t){return t.scope?`@${t.scope}/${t.name}@${t.reference}`:`${t.name}@${t.reference}`}function Dx(t){return t.scope!==null?`@${t.scope}-${t.name}`:t.name}function Mu(t){let{protocol:e,selector:r}=Tu(t.reference),i=e!==null?e.replace(/:$/,""):"exotic",n=e3.default.valid(r),s=n!==null?`${i}-${n}`:`${i}`,o=10,a=t.scope?`${Dx(t)}-${s}-${t.locatorHash.slice(0,o)}`:`${Dx(t)}-${s}-${t.locatorHash.slice(0,o)}`;return kr(a)}function Vr(t,e){return e.scope?`${Ve(t,`@${e.scope}/`,Le.SCOPE)}${Ve(t,e.name,Le.NAME)}`:`${Ve(t,e.name,Le.NAME)}`}function vy(t){if(t.startsWith(wy)){let e=vy(t.substr(t.indexOf("#")+1)),r=t.substr(wy.length,YQe);return`${e} [${r}]`}else return t.replace(/\?.*/,"?[...]")}function yy(t,e){return`${Ve(t,vy(e),Le.RANGE)}`}function Xt(t,e){return`${Vr(t,e)}${Ve(t,"@",Le.RANGE)}${yy(t,e.range)}`}function fp(t,e){return`${Ve(t,vy(e),Le.REFERENCE)}`}function lt(t,e){return`${Vr(t,e)}${Ve(t,"@",Le.REFERENCE)}${fp(t,e.reference)}`}function Rx(t){return`${St(t)}@${vy(t.reference)}`}function Ou(t){return gn(t,[e=>St(e),e=>e.range])}function hp(t,e){return Vr(t,e.locator)}function Fx(t,e,r){let i=hA(e)?Ap(e):e;return r===null?`${Xt(t,i)} \u2192 ${xx(t).Cross}`:i.identHash===r.identHash?`${Xt(t,i)} \u2192 ${fp(t,r.reference)}`:`${Xt(t,i)} \u2192 ${lt(t,r)}`}function Nx(t,e,r){return r===null?`${lt(t,e)}`:`${lt(t,e)} (via ${yy(t,r.range)})`}function Lx(t){return`node_modules/${St(t)}`}function Sy(t,e){return t.conditions?qQe(t.conditions,r=>{let[,i,n]=r.match(r3),s=e[i];return s?s.includes(n):!0}):!0}var gt;(function(r){r.HARD="HARD",r.SOFT="SOFT"})(gt||(gt={}));var oi;(function(i){i.Dependency="Dependency",i.PeerDependency="PeerDependency",i.PeerDependencyMeta="PeerDependencyMeta"})(oi||(oi={}));var ki;(function(i){i.Inactive="inactive",i.Redundant="redundant",i.Active="active"})(ki||(ki={}));var Le={NO_HINT:"NO_HINT",NULL:"NULL",SCOPE:"SCOPE",NAME:"NAME",RANGE:"RANGE",REFERENCE:"REFERENCE",NUMBER:"NUMBER",PATH:"PATH",URL:"URL",ADDED:"ADDED",REMOVED:"REMOVED",CODE:"CODE",DURATION:"DURATION",SIZE:"SIZE",IDENT:"IDENT",DESCRIPTOR:"DESCRIPTOR",LOCATOR:"LOCATOR",RESOLUTION:"RESOLUTION",DEPENDENT:"DEPENDENT",PACKAGE_EXTENSION:"PACKAGE_EXTENSION",SETTING:"SETTING"},Gl;(function(e){e[e.BOLD=2]="BOLD"})(Gl||(Gl={}));var Tx=dp.default.GITHUB_ACTIONS?{level:2}:pp.default.supportsColor?{level:pp.default.supportsColor.level}:{level:0},xy=Tx.level!==0,Mx=xy&&!dp.default.GITHUB_ACTIONS&&!dp.default.CIRCLE&&!dp.default.GITLAB,Ox=new pp.default.Instance(Tx),tbe=new Map([[Le.NO_HINT,null],[Le.NULL,["#a853b5",129]],[Le.SCOPE,["#d75f00",166]],[Le.NAME,["#d7875f",173]],[Le.RANGE,["#00afaf",37]],[Le.REFERENCE,["#87afff",111]],[Le.NUMBER,["#ffd700",220]],[Le.PATH,["#d75fd7",170]],[Le.URL,["#d75fd7",170]],[Le.ADDED,["#5faf00",70]],[Le.REMOVED,["#d70000",160]],[Le.CODE,["#87afff",111]],[Le.SIZE,["#ffd700",220]]]),Ls=t=>t,ky={[Le.NUMBER]:Ls({pretty:(t,e)=>`${e}`,json:t=>t}),[Le.IDENT]:Ls({pretty:(t,e)=>Vr(t,e),json:t=>St(t)}),[Le.LOCATOR]:Ls({pretty:(t,e)=>lt(t,e),json:t=>is(t)}),[Le.DESCRIPTOR]:Ls({pretty:(t,e)=>Xt(t,e),json:t=>In(t)}),[Le.RESOLUTION]:Ls({pretty:(t,{descriptor:e,locator:r})=>Fx(t,e,r),json:({descriptor:t,locator:e})=>({descriptor:In(t),locator:e!==null?is(e):null})}),[Le.DEPENDENT]:Ls({pretty:(t,{locator:e,descriptor:r})=>Nx(t,e,r),json:({locator:t,descriptor:e})=>({locator:is(t),descriptor:In(e)})}),[Le.PACKAGE_EXTENSION]:Ls({pretty:(t,e)=>{switch(e.type){case oi.Dependency:return`${Vr(t,e.parentDescriptor)} \u27A4 ${On(t,"dependencies",Le.CODE)} \u27A4 ${Vr(t,e.descriptor)}`;case oi.PeerDependency:return`${Vr(t,e.parentDescriptor)} \u27A4 ${On(t,"peerDependencies",Le.CODE)} \u27A4 ${Vr(t,e.descriptor)}`;case oi.PeerDependencyMeta:return`${Vr(t,e.parentDescriptor)} \u27A4 ${On(t,"peerDependenciesMeta",Le.CODE)} \u27A4 ${Vr(t,En(e.selector))} \u27A4 ${On(t,e.key,Le.CODE)}`;default:throw new Error(`Assertion failed: Unsupported package extension type: ${e.type}`)}},json:t=>{switch(t.type){case oi.Dependency:return`${St(t.parentDescriptor)} > ${St(t.descriptor)}`;case oi.PeerDependency:return`${St(t.parentDescriptor)} >> ${St(t.descriptor)}`;case oi.PeerDependencyMeta:return`${St(t.parentDescriptor)} >> ${t.selector} / ${t.key}`;default:throw new Error(`Assertion failed: Unsupported package extension type: ${t.type}`)}}}),[Le.SETTING]:Ls({pretty:(t,e)=>(t.get(e),Ku(t,On(t,e,Le.CODE),`https://yarnpkg.com/configuration/yarnrc#${e}`)),json:t=>t}),[Le.DURATION]:Ls({pretty:(t,e)=>{if(e>1e3*60){let r=Math.floor(e/1e3/60),i=Math.ceil((e-r*60*1e3)/1e3);return i===0?`${r}m`:`${r}m ${i}s`}else{let r=Math.floor(e/1e3),i=e-r*1e3;return i===0?`${r}s`:`${r}s ${i}ms`}},json:t=>t}),[Le.SIZE]:Ls({pretty:(t,e)=>{let r=["KB","MB","GB","TB"],i=r.length;for(;i>1&&e<1024**i;)i-=1;let n=1024**i,s=Math.floor(e*100/n)/100;return On(t,`${s} ${r[i-1]}`,Le.NUMBER)},json:t=>t}),[Le.PATH]:Ls({pretty:(t,e)=>On(t,M.fromPortablePath(e),Le.PATH),json:t=>M.fromPortablePath(t)})};function jl(t,e){return[e,t]}function Py(t,e,r){return t.get("enableColors")&&r&2&&(e=pp.default.bold(e)),e}function On(t,e,r){if(!t.get("enableColors"))return e;let i=tbe.get(r);if(i===null)return e;let n=typeof i=="undefined"?r:Tx.level>=3?i[0]:i[1],s=typeof n=="number"?Ox.ansi256(n):n.startsWith("#")?Ox.hex(n):Ox[n];if(typeof s!="function")throw new Error(`Invalid format type ${n}`);return s(e)}var rbe=!!process.env.KONSOLE_VERSION;function Ku(t,e,r){return t.get("enableHyperlinks")?rbe?`]8;;${r}\\${e}]8;;\\`:`]8;;${r}\x07${e}]8;;\x07`:e}function Ve(t,e,r){if(e===null)return On(t,"null",Le.NULL);if(Object.prototype.hasOwnProperty.call(ky,r))return ky[r].pretty(t,e);if(typeof e!="string")throw new Error(`Assertion failed: Expected the value to be a string, got ${typeof e}`);return On(t,e,r)}function Kx(t,e,r,{separator:i=", "}={}){return[...e].map(n=>Ve(t,n,r)).join(i)}function Uu(t,e){if(t===null)return null;if(Object.prototype.hasOwnProperty.call(ky,e))return Nv(e),ky[e].json(t);if(typeof t!="string")throw new Error(`Assertion failed: Expected the value to be a string, got ${typeof t}`);return t}function xx(t){return{Check:On(t,"\u2713","green"),Cross:On(t,"\u2718","red"),Question:On(t,"?","cyan")}}function Yl(t,{label:e,value:[r,i]}){return`${Ve(t,e,Le.CODE)}: ${Ve(t,r,i)}`}var Ts;(function(n){n.Error="error",n.Warning="warning",n.Info="info",n.Discard="discard"})(Ts||(Ts={}));function Cp(t,{configuration:e}){let r=e.get("logFilters"),i=new Map,n=new Map,s=[];for(let g of r){let f=g.get("level");if(typeof f=="undefined")continue;let h=g.get("code");typeof h!="undefined"&&i.set(h,f);let p=g.get("text");typeof p!="undefined"&&n.set(p,f);let d=g.get("pattern");typeof d!="undefined"&&s.push([o3.default.matcher(d,{contains:!0}),f])}s.reverse();let o=(g,f,h)=>{if(g===null||g===z.UNNAMED)return h;let p=n.size>0||s.length>0?(0,a3.default)(f):f;if(n.size>0){let d=n.get(p);if(typeof d!="undefined")return d!=null?d:h}if(s.length>0){for(let[d,m]of s)if(d(p))return m!=null?m:h}if(i.size>0){let d=i.get(KE(g));if(typeof d!="undefined")return d!=null?d:h}return h},a=t.reportInfo,l=t.reportWarning,c=t.reportError,u=function(g,f,h,p){switch(o(f,h,p)){case Ts.Info:a.call(g,f,h);break;case Ts.Warning:l.call(g,f!=null?f:z.UNNAMED,h);break;case Ts.Error:c.call(g,f!=null?f:z.UNNAMED,h);break}};t.reportInfo=function(...g){return u(this,...g,Ts.Info)},t.reportWarning=function(...g){return u(this,...g,Ts.Warning)},t.reportError=function(...g){return u(this,...g,Ts.Error)}}var Zt={};it(Zt,{Method:()=>Jl,RequestError:()=>z8.RequestError,del:()=>pxe,get:()=>fxe,getNetworkSettings:()=>Z8,post:()=>iP,put:()=>hxe,request:()=>xp});var q8=ie(zy()),J8=ie(require("https")),W8=ie(require("http")),tP=ie(Nn()),rP=ie(G8()),Vy=ie(require("url"));var j8=ie(require("stream")),Y8=ie(require("string_decoder"));var nt=class extends Error{constructor(e,r,i){super(r);this.reportExtra=i;this.reportCode=e}};function Axe(t){return typeof t.reportCode!="undefined"}var Xi=class{constructor(){this.reportedInfos=new Set;this.reportedWarnings=new Set;this.reportedErrors=new Set}static progressViaCounter(e){let r=0,i,n=new Promise(l=>{i=l}),s=l=>{let c=i;n=new Promise(u=>{i=u}),r=l,c()},o=(l=0)=>{s(r+1)},a=async function*(){for(;r{let o=i.write(s),a;do if(a=o.indexOf(` -`),a!==-1){let l=n+o.substr(0,a);o=o.substr(a+1),n="",e!==null?this.reportInfo(null,`${e} ${l}`):this.reportInfo(null,l)}while(a!==-1);n+=o}),r.on("end",()=>{let s=i.end();s!==""&&(e!==null?this.reportInfo(null,`${e} ${s}`):this.reportInfo(null,s))}),r}};var z8=ie(zy()),V8=new Map,_8=new Map,lxe=new W8.Agent({keepAlive:!0}),cxe=new J8.Agent({keepAlive:!0});function X8(t){let e=new Vy.URL(t),r={host:e.hostname,headers:{}};return e.port&&(r.port=Number(e.port)),{proxy:r}}async function uxe(t){return na(_8,t,()=>T.readFilePromise(t).then(e=>(_8.set(t,e),e)))}function gxe({statusCode:t,statusMessage:e},r){let i=Ve(r,t,Le.NUMBER),n=`https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/${t}`;return Ku(r,`${i}${e?` (${e})`:""}`,n)}async function _y(t,{configuration:e,customErrorMessage:r}){var i,n;try{return await t}catch(s){if(s.name!=="HTTPError")throw s;let o=(n=r==null?void 0:r(s))!=null?n:(i=s.response.body)==null?void 0:i.error;o==null&&(s.message.startsWith("Response code")?o="The remote server failed to provide the requested resource":o=s.message),s instanceof q8.TimeoutError&&s.event==="socket"&&(o+=`(can be increased via ${Ve(e,"httpTimeout",Le.SETTING)})`);let a=new nt(z.NETWORK_ERROR,o,l=>{s.response&&l.reportError(z.NETWORK_ERROR,` ${Yl(e,{label:"Response Code",value:jl(Le.NO_HINT,gxe(s.response,e))})}`),s.request&&(l.reportError(z.NETWORK_ERROR,` ${Yl(e,{label:"Request Method",value:jl(Le.NO_HINT,s.request.options.method)})}`),l.reportError(z.NETWORK_ERROR,` ${Yl(e,{label:"Request URL",value:jl(Le.URL,s.request.requestUrl)})}`)),s.request.redirects.length>0&&l.reportError(z.NETWORK_ERROR,` ${Yl(e,{label:"Request Redirects",value:jl(Le.NO_HINT,Kx(e,s.request.redirects,Le.URL))})}`),s.request.retryCount===s.request.options.retry.limit&&l.reportError(z.NETWORK_ERROR,` ${Yl(e,{label:"Request Retry Count",value:jl(Le.NO_HINT,`${Ve(e,s.request.retryCount,Le.NUMBER)} (can be increased via ${Ve(e,"httpRetry",Le.SETTING)})`)})}`)});throw a.originalError=s,a}}function Z8(t,e){let r=[...e.configuration.get("networkSettings")].sort(([o],[a])=>a.length-o.length),i={enableNetwork:void 0,caFilePath:void 0,httpProxy:void 0,httpsProxy:void 0},n=Object.keys(i),s=typeof t=="string"?new Vy.URL(t):t;for(let[o,a]of r)if(tP.default.isMatch(s.hostname,o))for(let l of n){let c=a.get(l);c!==null&&typeof i[l]=="undefined"&&(i[l]=c)}for(let o of n)typeof i[o]=="undefined"&&(i[o]=e.configuration.get(o));return i}var Jl;(function(n){n.GET="GET",n.PUT="PUT",n.POST="POST",n.DELETE="DELETE"})(Jl||(Jl={}));async function xp(t,e,{configuration:r,headers:i,jsonRequest:n,jsonResponse:s,method:o=Jl.GET}){let a=typeof t=="string"?new Vy.URL(t):t,l=Z8(a,{configuration:r});if(l.enableNetwork===!1)throw new Error(`Request to '${a.href}' has been blocked because of your configuration settings`);if(a.protocol==="http:"&&!tP.default.isMatch(a.hostname,r.get("unsafeHttpWhitelist")))throw new Error(`Unsafe http requests must be explicitly whitelisted in your configuration (${a.hostname})`);let u={agent:{http:l.httpProxy?rP.default.httpOverHttp(X8(l.httpProxy)):lxe,https:l.httpsProxy?rP.default.httpsOverHttp(X8(l.httpsProxy)):cxe},headers:i,method:o};u.responseType=s?"json":"buffer",e!==null&&(Buffer.isBuffer(e)||!n&&typeof e=="string"?u.body=e:u.json=e);let g=r.get("httpTimeout"),f=r.get("httpRetry"),h=r.get("enableStrictSsl"),p=l.caFilePath,{default:d}=await Promise.resolve().then(()=>ie(zy())),m=p?await uxe(p):void 0,I=d.extend(P({timeout:{socket:g},retry:f,https:{rejectUnauthorized:h,certificateAuthority:m}},u));return r.getLimit("networkConcurrency")(()=>I(a))}async function fxe(t,n){var s=n,{configuration:e,jsonResponse:r}=s,i=qr(s,["configuration","jsonResponse"]);let o=na(V8,t,()=>_y(xp(t,null,P({configuration:e},i)),{configuration:e}).then(a=>(V8.set(t,a.body),a.body)));return Buffer.isBuffer(o)===!1&&(o=await o),r?JSON.parse(o.toString()):o}async function hxe(t,e,n){var s=n,{customErrorMessage:r}=s,i=qr(s,["customErrorMessage"]);return(await _y(xp(t,e,_(P({},i),{method:Jl.PUT})),i)).body}async function iP(t,e,n){var s=n,{customErrorMessage:r}=s,i=qr(s,["customErrorMessage"]);return(await _y(xp(t,e,_(P({},i),{method:Jl.POST})),i)).body}async function pxe(t,i){var n=i,{customErrorMessage:e}=n,r=qr(n,["customErrorMessage"]);return(await _y(xp(t,null,_(P({},r),{method:Jl.DELETE})),r)).body}var Kt={};it(Kt,{PackageManager:()=>tn,detectPackageManager:()=>a9,executePackageAccessibleBinary:()=>g9,executePackageScript:()=>Uw,executePackageShellcode:()=>rD,executeWorkspaceAccessibleBinary:()=>qFe,executeWorkspaceLifecycleScript:()=>u9,executeWorkspaceScript:()=>c9,getPackageAccessibleBinaries:()=>Hw,getWorkspaceAccessibleBinaries:()=>l9,hasPackageScript:()=>GFe,hasWorkspaceScript:()=>tD,makeScriptEnv:()=>Vp,maybeExecuteWorkspaceLifecycleScript:()=>YFe,prepareExternalProject:()=>HFe});var Fp={};it(Fp,{getLibzipPromise:()=>$i,getLibzipSync:()=>v4});var yA=["number","number"],nP;(function(D){D[D.ZIP_ER_OK=0]="ZIP_ER_OK",D[D.ZIP_ER_MULTIDISK=1]="ZIP_ER_MULTIDISK",D[D.ZIP_ER_RENAME=2]="ZIP_ER_RENAME",D[D.ZIP_ER_CLOSE=3]="ZIP_ER_CLOSE",D[D.ZIP_ER_SEEK=4]="ZIP_ER_SEEK",D[D.ZIP_ER_READ=5]="ZIP_ER_READ",D[D.ZIP_ER_WRITE=6]="ZIP_ER_WRITE",D[D.ZIP_ER_CRC=7]="ZIP_ER_CRC",D[D.ZIP_ER_ZIPCLOSED=8]="ZIP_ER_ZIPCLOSED",D[D.ZIP_ER_NOENT=9]="ZIP_ER_NOENT",D[D.ZIP_ER_EXISTS=10]="ZIP_ER_EXISTS",D[D.ZIP_ER_OPEN=11]="ZIP_ER_OPEN",D[D.ZIP_ER_TMPOPEN=12]="ZIP_ER_TMPOPEN",D[D.ZIP_ER_ZLIB=13]="ZIP_ER_ZLIB",D[D.ZIP_ER_MEMORY=14]="ZIP_ER_MEMORY",D[D.ZIP_ER_CHANGED=15]="ZIP_ER_CHANGED",D[D.ZIP_ER_COMPNOTSUPP=16]="ZIP_ER_COMPNOTSUPP",D[D.ZIP_ER_EOF=17]="ZIP_ER_EOF",D[D.ZIP_ER_INVAL=18]="ZIP_ER_INVAL",D[D.ZIP_ER_NOZIP=19]="ZIP_ER_NOZIP",D[D.ZIP_ER_INTERNAL=20]="ZIP_ER_INTERNAL",D[D.ZIP_ER_INCONS=21]="ZIP_ER_INCONS",D[D.ZIP_ER_REMOVE=22]="ZIP_ER_REMOVE",D[D.ZIP_ER_DELETED=23]="ZIP_ER_DELETED",D[D.ZIP_ER_ENCRNOTSUPP=24]="ZIP_ER_ENCRNOTSUPP",D[D.ZIP_ER_RDONLY=25]="ZIP_ER_RDONLY",D[D.ZIP_ER_NOPASSWD=26]="ZIP_ER_NOPASSWD",D[D.ZIP_ER_WRONGPASSWD=27]="ZIP_ER_WRONGPASSWD",D[D.ZIP_ER_OPNOTSUPP=28]="ZIP_ER_OPNOTSUPP",D[D.ZIP_ER_INUSE=29]="ZIP_ER_INUSE",D[D.ZIP_ER_TELL=30]="ZIP_ER_TELL",D[D.ZIP_ER_COMPRESSED_DATA=31]="ZIP_ER_COMPRESSED_DATA"})(nP||(nP={}));var $8=t=>({get HEAP8(){return t.HEAP8},get HEAPU8(){return t.HEAPU8},errors:nP,SEEK_SET:0,SEEK_CUR:1,SEEK_END:2,ZIP_CHECKCONS:4,ZIP_CREATE:1,ZIP_EXCL:2,ZIP_TRUNCATE:8,ZIP_RDONLY:16,ZIP_FL_OVERWRITE:8192,ZIP_FL_COMPRESSED:4,ZIP_OPSYS_DOS:0,ZIP_OPSYS_AMIGA:1,ZIP_OPSYS_OPENVMS:2,ZIP_OPSYS_UNIX:3,ZIP_OPSYS_VM_CMS:4,ZIP_OPSYS_ATARI_ST:5,ZIP_OPSYS_OS_2:6,ZIP_OPSYS_MACINTOSH:7,ZIP_OPSYS_Z_SYSTEM:8,ZIP_OPSYS_CPM:9,ZIP_OPSYS_WINDOWS_NTFS:10,ZIP_OPSYS_MVS:11,ZIP_OPSYS_VSE:12,ZIP_OPSYS_ACORN_RISC:13,ZIP_OPSYS_VFAT:14,ZIP_OPSYS_ALTERNATE_MVS:15,ZIP_OPSYS_BEOS:16,ZIP_OPSYS_TANDEM:17,ZIP_OPSYS_OS_400:18,ZIP_OPSYS_OS_X:19,ZIP_CM_DEFAULT:-1,ZIP_CM_STORE:0,ZIP_CM_DEFLATE:8,uint08S:t._malloc(1),uint16S:t._malloc(2),uint32S:t._malloc(4),uint64S:t._malloc(8),malloc:t._malloc,free:t._free,getValue:t.getValue,open:t.cwrap("zip_open","number",["string","number","number"]),openFromSource:t.cwrap("zip_open_from_source","number",["number","number","number"]),close:t.cwrap("zip_close","number",["number"]),discard:t.cwrap("zip_discard",null,["number"]),getError:t.cwrap("zip_get_error","number",["number"]),getName:t.cwrap("zip_get_name","string",["number","number","number"]),getNumEntries:t.cwrap("zip_get_num_entries","number",["number","number"]),delete:t.cwrap("zip_delete","number",["number","number"]),stat:t.cwrap("zip_stat","number",["number","string","number","number"]),statIndex:t.cwrap("zip_stat_index","number",["number",...yA,"number","number"]),fopen:t.cwrap("zip_fopen","number",["number","string","number"]),fopenIndex:t.cwrap("zip_fopen_index","number",["number",...yA,"number"]),fread:t.cwrap("zip_fread","number",["number","number","number","number"]),fclose:t.cwrap("zip_fclose","number",["number"]),dir:{add:t.cwrap("zip_dir_add","number",["number","string"])},file:{add:t.cwrap("zip_file_add","number",["number","string","number","number"]),getError:t.cwrap("zip_file_get_error","number",["number"]),getExternalAttributes:t.cwrap("zip_file_get_external_attributes","number",["number",...yA,"number","number","number"]),setExternalAttributes:t.cwrap("zip_file_set_external_attributes","number",["number",...yA,"number","number","number"]),setMtime:t.cwrap("zip_file_set_mtime","number",["number",...yA,"number","number"]),setCompression:t.cwrap("zip_set_file_compression","number",["number",...yA,"number","number"])},ext:{countSymlinks:t.cwrap("zip_ext_count_symlinks","number",["number"])},error:{initWithCode:t.cwrap("zip_error_init_with_code",null,["number","number"]),strerror:t.cwrap("zip_error_strerror","string",["number"])},name:{locate:t.cwrap("zip_name_locate","number",["number","string","number"])},source:{fromUnattachedBuffer:t.cwrap("zip_source_buffer_create","number",["number","number","number","number"]),fromBuffer:t.cwrap("zip_source_buffer","number",["number","number",...yA,"number"]),free:t.cwrap("zip_source_free",null,["number"]),keep:t.cwrap("zip_source_keep",null,["number"]),open:t.cwrap("zip_source_open","number",["number"]),close:t.cwrap("zip_source_close","number",["number"]),seek:t.cwrap("zip_source_seek","number",["number",...yA,"number"]),tell:t.cwrap("zip_source_tell","number",["number"]),read:t.cwrap("zip_source_read","number",["number","number","number"]),error:t.cwrap("zip_source_error","number",["number"]),setMtime:t.cwrap("zip_source_set_mtime","number",["number","number"])},struct:{stat:t.cwrap("zipstruct_stat","number",[]),statS:t.cwrap("zipstruct_statS","number",[]),statName:t.cwrap("zipstruct_stat_name","string",["number"]),statIndex:t.cwrap("zipstruct_stat_index","number",["number"]),statSize:t.cwrap("zipstruct_stat_size","number",["number"]),statCompSize:t.cwrap("zipstruct_stat_comp_size","number",["number"]),statCompMethod:t.cwrap("zipstruct_stat_comp_method","number",["number"]),statMtime:t.cwrap("zipstruct_stat_mtime","number",["number"]),statCrc:t.cwrap("zipstruct_stat_crc","number",["number"]),error:t.cwrap("zipstruct_error","number",[]),errorS:t.cwrap("zipstruct_errorS","number",[]),errorCodeZip:t.cwrap("zipstruct_error_code_zip","number",["number"])}});var BP=null;function v4(){return BP===null&&(BP=$8(b4())),BP}async function $i(){return v4()}var jp={};it(jp,{ShellError:()=>as,execute:()=>Fw,globUtils:()=>bw});var Hp={};it(Hp,{parseResolution:()=>gw,parseShell:()=>Aw,parseSyml:()=>Ii,stringifyArgument:()=>SP,stringifyArgumentSegment:()=>xP,stringifyArithmeticExpression:()=>uw,stringifyCommand:()=>vP,stringifyCommandChain:()=>rg,stringifyCommandChainThen:()=>bP,stringifyCommandLine:()=>lw,stringifyCommandLineThen:()=>QP,stringifyEnvSegment:()=>cw,stringifyRedirectArgument:()=>Np,stringifyResolution:()=>fw,stringifyShell:()=>tg,stringifyShellLine:()=>tg,stringifySyml:()=>Qa,stringifyValueArgument:()=>ig});var k4=ie(x4());function Aw(t,e={isGlobPattern:()=>!1}){try{return(0,k4.parse)(t,e)}catch(r){throw r.location&&(r.message=r.message.replace(/(\.)?$/,` (line ${r.location.start.line}, column ${r.location.start.column})$1`)),r}}function tg(t,{endSemicolon:e=!1}={}){return t.map(({command:r,type:i},n)=>`${lw(r)}${i===";"?n!==t.length-1||e?";":"":" &"}`).join(" ")}function lw(t){return`${rg(t.chain)}${t.then?` ${QP(t.then)}`:""}`}function QP(t){return`${t.type} ${lw(t.line)}`}function rg(t){return`${vP(t)}${t.then?` ${bP(t.then)}`:""}`}function bP(t){return`${t.type} ${rg(t.chain)}`}function vP(t){switch(t.type){case"command":return`${t.envs.length>0?`${t.envs.map(e=>cw(e)).join(" ")} `:""}${t.args.map(e=>SP(e)).join(" ")}`;case"subshell":return`(${tg(t.subshell)})${t.args.length>0?` ${t.args.map(e=>Np(e)).join(" ")}`:""}`;case"group":return`{ ${tg(t.group,{endSemicolon:!0})} }${t.args.length>0?` ${t.args.map(e=>Np(e)).join(" ")}`:""}`;case"envs":return t.envs.map(e=>cw(e)).join(" ");default:throw new Error(`Unsupported command type: "${t.type}"`)}}function cw(t){return`${t.name}=${t.args[0]?ig(t.args[0]):""}`}function SP(t){switch(t.type){case"redirection":return Np(t);case"argument":return ig(t);default:throw new Error(`Unsupported argument type: "${t.type}"`)}}function Np(t){return`${t.subtype} ${t.args.map(e=>ig(e)).join(" ")}`}function ig(t){return t.segments.map(e=>xP(e)).join("")}function xP(t){let e=(i,n)=>n?`"${i}"`:i,r=i=>i===""?'""':i.match(/[(){}<>$|&; \t"']/)?`$'${i.replace(/\\/g,"\\\\").replace(/'/g,"\\'").replace(/\f/g,"\\f").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\t/g,"\\t").replace(/\v/g,"\\v").replace(/\0/g,"\\0")}'`:i;switch(t.type){case"text":return r(t.text);case"glob":return t.pattern;case"shell":return e(`\${${tg(t.shell)}}`,t.quoted);case"variable":return e(typeof t.defaultValue=="undefined"?`\${${t.name}}`:t.defaultValue.length===0?`\${${t.name}:-}`:`\${${t.name}:-${t.defaultValue.map(i=>ig(i)).join(" ")}}`,t.quoted);case"arithmetic":return`$(( ${uw(t.arithmetic)} ))`;default:throw new Error(`Unsupported argument segment type: "${t.type}"`)}}function uw(t){let e=n=>{switch(n){case"addition":return"+";case"subtraction":return"-";case"multiplication":return"*";case"division":return"/";default:throw new Error(`Can't extract operator from arithmetic expression of type "${n}"`)}},r=(n,s)=>s?`( ${n} )`:n,i=n=>r(uw(n),!["number","variable"].includes(n.type));switch(t.type){case"number":return String(t.value);case"variable":return t.name;default:return`${i(t.left)} ${e(t.type)} ${i(t.right)}`}}var R4=ie(D4());function gw(t){let e=t.match(/^\*{1,2}\/(.*)/);if(e)throw new Error(`The override for '${t}' includes a glob pattern. Glob patterns have been removed since their behaviours don't match what you'd expect. Set the override to '${e[1]}' instead.`);try{return(0,R4.parse)(t)}catch(r){throw r.location&&(r.message=r.message.replace(/(\.)?$/,` (line ${r.location.start.line}, column ${r.location.start.column})$1`)),r}}function fw(t){let e="";return t.from&&(e+=t.from.fullName,t.from.description&&(e+=`@${t.from.description}`),e+="/"),e+=t.descriptor.fullName,t.descriptor.description&&(e+=`@${t.descriptor.description}`),e}var Qw=ie(w5()),b5=ie(Q5()),$De=/^(?![-?:,\][{}#&*!|>'"%@` \t\r\n]).([ \t]*(?![,\][{}:# \t\r\n]).)*$/,v5=["__metadata","version","resolution","dependencies","peerDependencies","dependenciesMeta","peerDependenciesMeta","binaries"],HP=class{constructor(e){this.data=e}};function S5(t){return t.match($De)?t:JSON.stringify(t)}function x5(t){return typeof t=="undefined"?!0:typeof t=="object"&&t!==null?Object.keys(t).every(e=>x5(t[e])):!1}function GP(t,e,r){if(t===null)return`null -`;if(typeof t=="number"||typeof t=="boolean")return`${t.toString()} -`;if(typeof t=="string")return`${S5(t)} -`;if(Array.isArray(t)){if(t.length===0)return`[] -`;let i=" ".repeat(e);return` -${t.map(s=>`${i}- ${GP(s,e+1,!1)}`).join("")}`}if(typeof t=="object"&&t){let i,n;t instanceof HP?(i=t.data,n=!1):(i=t,n=!0);let s=" ".repeat(e),o=Object.keys(i);n&&o.sort((l,c)=>{let u=v5.indexOf(l),g=v5.indexOf(c);return u===-1&&g===-1?lc?1:0:u!==-1&&g===-1?-1:u===-1&&g!==-1?1:u-g});let a=o.filter(l=>!x5(i[l])).map((l,c)=>{let u=i[l],g=S5(l),f=GP(u,e+1,!0),h=c>0||r?s:"";return f.startsWith(` -`)?`${h}${g}:${f}`:`${h}${g}: ${f}`}).join(e===0?` -`:"")||` -`;return r?` -${a}`:`${a}`}throw new Error(`Unsupported value type (${t})`)}function Qa(t){try{let e=GP(t,0,!1);return e!==` -`?e:""}catch(e){throw e.location&&(e.message=e.message.replace(/(\.)?$/,` (line ${e.location.start.line}, column ${e.location.start.column})$1`)),e}}Qa.PreserveOrdering=HP;function eRe(t){return t.endsWith(` -`)||(t+=` -`),(0,b5.parse)(t)}var tRe=/^(#.*(\r?\n))*?#\s+yarn\s+lockfile\s+v1\r?\n/i;function rRe(t){if(tRe.test(t))return eRe(t);let e=(0,Qw.safeLoad)(t,{schema:Qw.FAILSAFE_SCHEMA,json:!0});if(e==null)return{};if(typeof e!="object")throw new Error(`Expected an indexed object, got a ${typeof e} instead. Does your file follow Yaml's rules?`);if(Array.isArray(e))throw new Error("Expected an indexed object, got an array instead. Does your file follow Yaml's rules?");return e}function Ii(t){return rRe(t)}var U5=ie(jb()),H5=ie(require("os")),Kn=ie(require("stream")),G5=ie(require("util"));var as=class extends Error{constructor(e){super(e);this.name="ShellError"}};var bw={};it(bw,{fastGlobOptions:()=>D5,isBraceExpansion:()=>R5,isGlobPattern:()=>iRe,match:()=>nRe,micromatchOptions:()=>Sw});var k5=ie(gy()),P5=ie(require("fs")),vw=ie(Nn()),Sw={strictBrackets:!0},D5={onlyDirectories:!1,onlyFiles:!1};function iRe(t){if(!vw.default.scan(t,Sw).isGlob)return!1;try{vw.default.parse(t,Sw)}catch{return!1}return!0}function nRe(t,{cwd:e,baseFs:r}){return(0,k5.default)(t,_(P({},D5),{cwd:M.fromPortablePath(e),fs:SE(P5.default,new ah(r))}))}function R5(t){return vw.default.scan(t,Sw).isBrace}var F5=ie(bb()),Bo=ie(require("stream")),N5=ie(require("string_decoder")),wn;(function(i){i[i.STDIN=0]="STDIN",i[i.STDOUT=1]="STDOUT",i[i.STDERR=2]="STDERR"})(wn||(wn={}));var sc=new Set;function jP(){}function YP(){for(let t of sc)t.kill()}function L5(t,e,r,i){return n=>{let s=n[0]instanceof Bo.Transform?"pipe":n[0],o=n[1]instanceof Bo.Transform?"pipe":n[1],a=n[2]instanceof Bo.Transform?"pipe":n[2],l=(0,F5.default)(t,e,_(P({},i),{stdio:[s,o,a]}));return sc.add(l),sc.size===1&&(process.on("SIGINT",jP),process.on("SIGTERM",YP)),n[0]instanceof Bo.Transform&&n[0].pipe(l.stdin),n[1]instanceof Bo.Transform&&l.stdout.pipe(n[1],{end:!1}),n[2]instanceof Bo.Transform&&l.stderr.pipe(n[2],{end:!1}),{stdin:l.stdin,promise:new Promise(c=>{l.on("error",u=>{switch(sc.delete(l),sc.size===0&&(process.off("SIGINT",jP),process.off("SIGTERM",YP)),u.code){case"ENOENT":n[2].write(`command not found: ${t} -`),c(127);break;case"EACCES":n[2].write(`permission denied: ${t} -`),c(128);break;default:n[2].write(`uncaught error: ${u.message} -`),c(1);break}}),l.on("exit",u=>{sc.delete(l),sc.size===0&&(process.off("SIGINT",jP),process.off("SIGTERM",YP)),c(u!==null?u:129)})})}}}function T5(t){return e=>{let r=e[0]==="pipe"?new Bo.PassThrough:e[0];return{stdin:r,promise:Promise.resolve().then(()=>t({stdin:r,stdout:e[1],stderr:e[2]}))}}}var Os=class{constructor(e){this.stream=e}close(){}get(){return this.stream}},M5=class{constructor(){this.stream=null}close(){if(this.stream===null)throw new Error("Assertion failed: No stream attached");this.stream.end()}attach(e){this.stream=e}get(){if(this.stream===null)throw new Error("Assertion failed: No stream attached");return this.stream}},Gp=class{constructor(e,r){this.stdin=null;this.stdout=null;this.stderr=null;this.pipe=null;this.ancestor=e,this.implementation=r}static start(e,{stdin:r,stdout:i,stderr:n}){let s=new Gp(null,e);return s.stdin=r,s.stdout=i,s.stderr=n,s}pipeTo(e,r=1){let i=new Gp(this,e),n=new M5;return i.pipe=n,i.stdout=this.stdout,i.stderr=this.stderr,(r&1)==1?this.stdout=n:this.ancestor!==null&&(this.stderr=this.ancestor.stdout),(r&2)==2?this.stderr=n:this.ancestor!==null&&(this.stderr=this.ancestor.stderr),i}async exec(){let e=["ignore","ignore","ignore"];if(this.pipe)e[0]="pipe";else{if(this.stdin===null)throw new Error("Assertion failed: No input stream registered");e[0]=this.stdin.get()}let r;if(this.stdout===null)throw new Error("Assertion failed: No output stream registered");r=this.stdout,e[1]=r.get();let i;if(this.stderr===null)throw new Error("Assertion failed: No error stream registered");i=this.stderr,e[2]=i.get();let n=this.implementation(e);return this.pipe&&this.pipe.attach(n.stdin),await n.promise.then(s=>(r.close(),i.close(),s))}async run(){let e=[];for(let i=this;i;i=i.ancestor)e.push(i.exec());return(await Promise.all(e))[0]}};function xw(t,e){return Gp.start(t,e)}function O5(t,e=null){let r=new Bo.PassThrough,i=new N5.StringDecoder,n="";return r.on("data",s=>{let o=i.write(s),a;do if(a=o.indexOf(` -`),a!==-1){let l=n+o.substr(0,a);o=o.substr(a+1),n="",t(e!==null?`${e} ${l}`:l)}while(a!==-1);n+=o}),r.on("end",()=>{let s=i.end();s!==""&&t(e!==null?`${e} ${s}`:s)}),r}function K5(t,{prefix:e}){return{stdout:O5(r=>t.stdout.write(`${r} -`),t.stdout.isTTY?e:null),stderr:O5(r=>t.stderr.write(`${r} -`),t.stderr.isTTY?e:null)}}var sRe=(0,G5.promisify)(setTimeout);var Fi;(function(r){r[r.Readable=1]="Readable",r[r.Writable=2]="Writable"})(Fi||(Fi={}));function j5(t,e,r){let i=new Kn.PassThrough({autoDestroy:!0});switch(t){case wn.STDIN:(e&1)==1&&r.stdin.pipe(i,{end:!1}),(e&2)==2&&r.stdin instanceof Kn.Writable&&i.pipe(r.stdin,{end:!1});break;case wn.STDOUT:(e&1)==1&&r.stdout.pipe(i,{end:!1}),(e&2)==2&&i.pipe(r.stdout,{end:!1});break;case wn.STDERR:(e&1)==1&&r.stderr.pipe(i,{end:!1}),(e&2)==2&&i.pipe(r.stderr,{end:!1});break;default:throw new as(`Bad file descriptor: "${t}"`)}return i}function kw(t,e={}){let r=P(P({},t),e);return r.environment=P(P({},t.environment),e.environment),r.variables=P(P({},t.variables),e.variables),r}var oRe=new Map([["cd",async([t=(0,H5.homedir)(),...e],r,i)=>{let n=v.resolve(i.cwd,M.toPortablePath(t));if(!(await r.baseFs.statPromise(n).catch(o=>{throw o.code==="ENOENT"?new as(`cd: no such file or directory: ${t}`):o})).isDirectory())throw new as(`cd: not a directory: ${t}`);return i.cwd=n,0}],["pwd",async(t,e,r)=>(r.stdout.write(`${M.fromPortablePath(r.cwd)} -`),0)],[":",async(t,e,r)=>0],["true",async(t,e,r)=>0],["false",async(t,e,r)=>1],["exit",async([t,...e],r,i)=>i.exitCode=parseInt(t!=null?t:i.variables["?"],10)],["echo",async(t,e,r)=>(r.stdout.write(`${t.join(" ")} -`),0)],["sleep",async([t],e,r)=>{if(typeof t=="undefined")throw new as("sleep: missing operand");let i=Number(t);if(Number.isNaN(i))throw new as(`sleep: invalid time interval '${t}'`);return await sRe(1e3*i,0)}],["__ysh_run_procedure",async(t,e,r)=>{let i=r.procedures[t[0]];return await xw(i,{stdin:new Os(r.stdin),stdout:new Os(r.stdout),stderr:new Os(r.stderr)}).run()}],["__ysh_set_redirects",async(t,e,r)=>{let i=r.stdin,n=r.stdout,s=r.stderr,o=[],a=[],l=[],c=0;for(;t[c]!=="--";){let g=t[c++],{type:f,fd:h}=JSON.parse(g),p=B=>{switch(h){case null:case 0:o.push(B);break;default:throw new Error(`Unsupported file descriptor: "${h}"`)}},d=B=>{switch(h){case null:case 1:a.push(B);break;case 2:l.push(B);break;default:throw new Error(`Unsupported file descriptor: "${h}"`)}},m=Number(t[c++]),I=c+m;for(let B=c;Be.baseFs.createReadStream(v.resolve(r.cwd,M.toPortablePath(t[B]))));break;case"<<<":p(()=>{let b=new Kn.PassThrough;return process.nextTick(()=>{b.write(`${t[B]} -`),b.end()}),b});break;case"<&":p(()=>j5(Number(t[B]),1,r));break;case">":case">>":{let b=v.resolve(r.cwd,M.toPortablePath(t[B]));d(b==="/dev/null"?new Kn.Writable({autoDestroy:!0,emitClose:!0,write(R,H,L){setImmediate(L)}}):e.baseFs.createWriteStream(b,f===">>"?{flags:"a"}:void 0))}break;case">&":d(j5(Number(t[B]),2,r));break;default:throw new Error(`Assertion failed: Unsupported redirection type: "${f}"`)}}if(o.length>0){let g=new Kn.PassThrough;i=g;let f=h=>{if(h===o.length)g.end();else{let p=o[h]();p.pipe(g,{end:!1}),p.on("end",()=>{f(h+1)})}};f(0)}if(a.length>0){let g=new Kn.PassThrough;n=g;for(let f of a)g.pipe(f)}if(l.length>0){let g=new Kn.PassThrough;s=g;for(let f of l)g.pipe(f)}let u=await xw(Yp(t.slice(c+1),e,r),{stdin:new Os(i),stdout:new Os(n),stderr:new Os(s)}).run();return await Promise.all(a.map(g=>new Promise((f,h)=>{g.on("error",p=>{h(p)}),g.on("close",()=>{f()}),g.end()}))),await Promise.all(l.map(g=>new Promise((f,h)=>{g.on("error",p=>{h(p)}),g.on("close",()=>{f()}),g.end()}))),u}]]);async function aRe(t,e,r){let i=[],n=new Kn.PassThrough;return n.on("data",s=>i.push(s)),await Pw(t,e,kw(r,{stdout:n})),Buffer.concat(i).toString().replace(/[\r\n]+$/,"")}async function Y5(t,e,r){let i=t.map(async s=>{let o=await oc(s.args,e,r);return{name:s.name,value:o.join(" ")}});return(await Promise.all(i)).reduce((s,o)=>(s[o.name]=o.value,s),{})}function Dw(t){return t.match(/[^ \r\n\t]+/g)||[]}async function q5(t,e,r,i,n=i){switch(t.name){case"$":i(String(process.pid));break;case"#":i(String(e.args.length));break;case"@":if(t.quoted)for(let s of e.args)n(s);else for(let s of e.args){let o=Dw(s);for(let a=0;a=0&&st+e,subtraction:(t,e)=>t-e,multiplication:(t,e)=>t*e,division:(t,e)=>Math.trunc(t/e)};async function qp(t,e,r){if(t.type==="number"){if(Number.isInteger(t.value))return t.value;throw new Error(`Invalid number: "${t.value}", only integers are allowed`)}else if(t.type==="variable"){let i=[];await q5(_(P({},t),{quoted:!0}),e,r,s=>i.push(s));let n=Number(i.join(" "));return Number.isNaN(n)?qp({type:"variable",name:i.join(" ")},e,r):qp({type:"number",value:n},e,r)}else return ARe[t.type](await qp(t.left,e,r),await qp(t.right,e,r))}async function oc(t,e,r){let i=new Map,n=[],s=[],o=u=>{s.push(u)},a=()=>{s.length>0&&n.push(s.join("")),s=[]},l=u=>{o(u),a()},c=(u,g,f)=>{let h=JSON.stringify({type:u,fd:g}),p=i.get(h);typeof p=="undefined"&&i.set(h,p=[]),p.push(f)};for(let u of t){let g=!1;switch(u.type){case"redirection":{let f=await oc(u.args,e,r);for(let h of f)c(u.subtype,u.fd,h)}break;case"argument":for(let f of u.segments)switch(f.type){case"text":o(f.text);break;case"glob":o(f.pattern),g=!0;break;case"shell":{let h=await aRe(f.shell,e,r);if(f.quoted)o(h);else{let p=Dw(h);for(let d=0;d0){let u=[];for(let[g,f]of i.entries())u.splice(u.length,0,g,String(f.length),...f);n.splice(0,0,"__ysh_set_redirects",...u,"--")}return n}function Yp(t,e,r){e.builtins.has(t[0])||(t=["command",...t]);let i=M.fromPortablePath(r.cwd),n=r.environment;typeof n.PWD!="undefined"&&(n=_(P({},n),{PWD:i}));let[s,...o]=t;if(s==="command")return L5(o[0],o.slice(1),e,{cwd:i,env:n});let a=e.builtins.get(s);if(typeof a=="undefined")throw new Error(`Assertion failed: A builtin should exist for "${s}"`);return T5(async({stdin:l,stdout:c,stderr:u})=>{let{stdin:g,stdout:f,stderr:h}=r;r.stdin=l,r.stdout=c,r.stderr=u;try{return await a(o,e,r)}finally{r.stdin=g,r.stdout=f,r.stderr=h}})}function lRe(t,e,r){return i=>{let n=new Kn.PassThrough,s=Pw(t,e,kw(r,{stdin:n}));return{stdin:n,promise:s}}}function cRe(t,e,r){return i=>{let n=new Kn.PassThrough,s=Pw(t,e,r);return{stdin:n,promise:s}}}function J5(t,e,r,i){if(e.length===0)return t;{let n;do n=String(Math.random());while(Object.prototype.hasOwnProperty.call(i.procedures,n));return i.procedures=P({},i.procedures),i.procedures[n]=t,Yp([...e,"__ysh_run_procedure",n],r,i)}}async function W5(t,e,r){let i=t,n=null,s=null;for(;i;){let o=i.then?P({},r):r,a;switch(i.type){case"command":{let l=await oc(i.args,e,r),c=await Y5(i.envs,e,r);a=i.envs.length?Yp(l,e,kw(o,{environment:c})):Yp(l,e,o)}break;case"subshell":{let l=await oc(i.args,e,r),c=lRe(i.subshell,e,o);a=J5(c,l,e,o)}break;case"group":{let l=await oc(i.args,e,r),c=cRe(i.group,e,o);a=J5(c,l,e,o)}break;case"envs":{let l=await Y5(i.envs,e,r);o.environment=P(P({},o.environment),l),a=Yp(["true"],e,o)}break}if(typeof a=="undefined")throw new Error("Assertion failed: An action should have been generated");if(n===null)s=xw(a,{stdin:new Os(o.stdin),stdout:new Os(o.stdout),stderr:new Os(o.stderr)});else{if(s===null)throw new Error("Assertion failed: The execution pipeline should have been setup");switch(n){case"|":s=s.pipeTo(a,wn.STDOUT);break;case"|&":s=s.pipeTo(a,wn.STDOUT|wn.STDERR);break}}i.then?(n=i.then.type,i=i.then.chain):i=null}if(s===null)throw new Error("Assertion failed: The execution pipeline should have been setup");return await s.run()}async function uRe(t,e,r,{background:i=!1}={}){function n(s){let o=["#2E86AB","#A23B72","#F18F01","#C73E1D","#CCE2A3"],a=o[s%o.length];return U5.default.hex(a)}if(i){let s=r.nextBackgroundJobIndex++,o=n(s),a=`[${s}]`,l=o(a),{stdout:c,stderr:u}=K5(r,{prefix:l});return r.backgroundJobs.push(W5(t,e,kw(r,{stdout:c,stderr:u})).catch(g=>u.write(`${g.message} -`)).finally(()=>{r.stdout.isTTY&&r.stdout.write(`Job ${l}, '${o(rg(t))}' has ended -`)})),0}return await W5(t,e,r)}async function gRe(t,e,r,{background:i=!1}={}){let n,s=a=>{n=a,r.variables["?"]=String(a)},o=async a=>{try{return await uRe(a.chain,e,r,{background:i&&typeof a.then=="undefined"})}catch(l){if(!(l instanceof as))throw l;return r.stderr.write(`${l.message} -`),1}};for(s(await o(t));t.then;){if(r.exitCode!==null)return r.exitCode;switch(t.then.type){case"&&":n===0&&s(await o(t.then.line));break;case"||":n!==0&&s(await o(t.then.line));break;default:throw new Error(`Assertion failed: Unsupported command type: "${t.then.type}"`)}t=t.then.line}return n}async function Pw(t,e,r){let i=r.backgroundJobs;r.backgroundJobs=[];let n=0;for(let{command:s,type:o}of t){if(n=await gRe(s,e,r,{background:o==="&"}),r.exitCode!==null)return r.exitCode;r.variables["?"]=String(n)}return await Promise.all(r.backgroundJobs),r.backgroundJobs=i,n}function z5(t){switch(t.type){case"variable":return t.name==="@"||t.name==="#"||t.name==="*"||Number.isFinite(parseInt(t.name,10))||"defaultValue"in t&&!!t.defaultValue&&t.defaultValue.some(e=>Rw(e));case"arithmetic":return qP(t.arithmetic);case"shell":return JP(t.shell);default:return!1}}function Rw(t){switch(t.type){case"redirection":return t.args.some(e=>Rw(e));case"argument":return t.segments.some(e=>z5(e));default:throw new Error(`Assertion failed: Unsupported argument type: "${t.type}"`)}}function qP(t){switch(t.type){case"variable":return z5(t);case"number":return!1;default:return qP(t.left)||qP(t.right)}}function JP(t){return t.some(({command:e})=>{for(;e;){let r=e.chain;for(;r;){let i;switch(r.type){case"subshell":i=JP(r.subshell);break;case"command":i=r.envs.some(n=>n.args.some(s=>Rw(s)))||r.args.some(n=>Rw(n));break}if(i)return!0;if(!r.then)break;r=r.then.chain}if(!e.then)break;e=e.then.line}return!1})}async function Fw(t,e=[],{baseFs:r=new Wt,builtins:i={},cwd:n=M.toPortablePath(process.cwd()),env:s=process.env,stdin:o=process.stdin,stdout:a=process.stdout,stderr:l=process.stderr,variables:c={},glob:u=bw}={}){let g={};for(let[p,d]of Object.entries(s))typeof d!="undefined"&&(g[p]=d);let f=new Map(oRe);for(let[p,d]of Object.entries(i))f.set(p,d);o===null&&(o=new Kn.PassThrough,o.end());let h=Aw(t,u);if(!JP(h)&&h.length>0&&e.length>0){let{command:p}=h[h.length-1];for(;p.then;)p=p.then.line;let d=p.chain;for(;d.then;)d=d.then.chain;d.type==="command"&&(d.args=d.args.concat(e.map(m=>({type:"argument",segments:[{type:"text",text:m}]}))))}return await Pw(h,{args:e,baseFs:r,builtins:f,initialStdin:o,initialStdout:a,initialStderr:l,glob:u},{cwd:n,environment:g,exitCode:null,procedures:{},stdin:o,stdout:a,stderr:l,variables:Object.assign({},c,{["?"]:0}),nextBackgroundJobIndex:1,backgroundJobs:[]})}var s9=ie(ZP()),o9=ie(Wp()),cc=ie(require("stream"));var J6=ie(Or());var zp=class{supportsDescriptor(e,r){return!!(e.range.startsWith(zp.protocol)||r.project.tryWorkspaceByDescriptor(e)!==null)}supportsLocator(e,r){return!!e.reference.startsWith(zp.protocol)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){return[i.project.getWorkspaceByDescriptor(e).anchoredLocator]}async getSatisfying(e,r,i){return null}async resolve(e,r){let i=r.project.getWorkspaceByCwd(e.reference.slice(zp.protocol.length));return _(P({},e),{version:i.manifest.version||"0.0.0",languageName:"unknown",linkType:gt.SOFT,conditions:null,dependencies:new Map([...i.manifest.dependencies,...i.manifest.devDependencies]),peerDependencies:new Map([...i.manifest.peerDependencies]),dependenciesMeta:i.manifest.dependenciesMeta,peerDependenciesMeta:i.manifest.peerDependenciesMeta,bin:i.manifest.bin})}},Yr=zp;Yr.protocol="workspace:";var qt={};it(qt,{SemVer:()=>j6.SemVer,satisfiesWithPrereleases:()=>lc,validRange:()=>Us});var Lw=ie(Or()),j6=ie(Or()),Y6=new Map;function lc(t,e,r=!1){if(!t)return!1;let i=`${e}${r}`,n=Y6.get(i);if(typeof n=="undefined")try{n=new Lw.default.Range(e,{includePrerelease:!0,loose:r})}catch{return!1}finally{Y6.set(i,n||null)}else if(n===null)return!1;let s;try{s=new Lw.default.SemVer(t,n)}catch(o){return!1}return n.test(s)?!0:(s.prerelease&&(s.prerelease=[]),n.set.some(o=>{for(let a of o)a.semver.prerelease&&(a.semver.prerelease=[]);return o.every(a=>a.test(s))}))}var q6=new Map;function Us(t){if(t.indexOf(":")!==-1)return null;let e=q6.get(t);if(typeof e!="undefined")return e;try{e=new Lw.default.Range(t)}catch{e=null}return q6.set(t,e),e}var vA=class{constructor(){this.indent=" ";this.name=null;this.version=null;this.os=null;this.cpu=null;this.type=null;this.packageManager=null;this.private=!1;this.license=null;this.main=null;this.module=null;this.browser=null;this.languageName=null;this.bin=new Map;this.scripts=new Map;this.dependencies=new Map;this.devDependencies=new Map;this.peerDependencies=new Map;this.workspaceDefinitions=[];this.dependenciesMeta=new Map;this.peerDependenciesMeta=new Map;this.resolutions=[];this.files=null;this.publishConfig=null;this.installConfig=null;this.preferUnplugged=null;this.raw={};this.errors=[]}static async tryFind(e,{baseFs:r=new Wt}={}){let i=v.join(e,"package.json");return await r.existsPromise(i)?await vA.fromFile(i,{baseFs:r}):null}static async find(e,{baseFs:r}={}){let i=await vA.tryFind(e,{baseFs:r});if(i===null)throw new Error("Manifest not found");return i}static async fromFile(e,{baseFs:r=new Wt}={}){let i=new vA;return await i.loadFile(e,{baseFs:r}),i}static fromText(e){let r=new vA;return r.loadFromText(e),r}static isManifestFieldCompatible(e,r){if(e===null)return!0;let i=!0,n=!1;for(let s of e)if(s[0]==="!"){if(n=!0,r===s.slice(1))return!1}else if(i=!1,s===r)return!0;return n&&i}loadFromText(e){let r;try{r=JSON.parse(z6(e)||"{}")}catch(i){throw i.message+=` (when parsing ${e})`,i}this.load(r),this.indent=W6(e)}async loadFile(e,{baseFs:r=new Wt}){let i=await r.readFilePromise(e,"utf8"),n;try{n=JSON.parse(z6(i)||"{}")}catch(s){throw s.message+=` (when parsing ${e})`,s}this.load(n),this.indent=W6(i)}load(e,{yamlCompatibilityMode:r=!1}={}){if(typeof e!="object"||e===null)throw new Error(`Utterly invalid manifest data (${e})`);this.raw=e;let i=[];if(this.name=null,typeof e.name=="string")try{this.name=En(e.name)}catch(s){i.push(new Error("Parsing failed for the 'name' field"))}if(typeof e.version=="string"?this.version=e.version:this.version=null,Array.isArray(e.os)){let s=[];this.os=s;for(let o of e.os)typeof o!="string"?i.push(new Error("Parsing failed for the 'os' field")):s.push(o)}else this.os=null;if(Array.isArray(e.cpu)){let s=[];this.cpu=s;for(let o of e.cpu)typeof o!="string"?i.push(new Error("Parsing failed for the 'cpu' field")):s.push(o)}else this.cpu=null;if(typeof e.type=="string"?this.type=e.type:this.type=null,typeof e.packageManager=="string"?this.packageManager=e.packageManager:this.packageManager=null,typeof e.private=="boolean"?this.private=e.private:this.private=!1,typeof e.license=="string"?this.license=e.license:this.license=null,typeof e.languageName=="string"?this.languageName=e.languageName:this.languageName=null,typeof e.main=="string"?this.main=en(e.main):this.main=null,typeof e.module=="string"?this.module=en(e.module):this.module=null,e.browser!=null)if(typeof e.browser=="string")this.browser=en(e.browser);else{this.browser=new Map;for(let[s,o]of Object.entries(e.browser))this.browser.set(en(s),typeof o=="string"?en(o):o)}else this.browser=null;if(this.bin=new Map,typeof e.bin=="string")this.name!==null?this.bin.set(this.name.name,en(e.bin)):i.push(new Error("String bin field, but no attached package name"));else if(typeof e.bin=="object"&&e.bin!==null)for(let[s,o]of Object.entries(e.bin)){if(typeof o!="string"){i.push(new Error(`Invalid bin definition for '${s}'`));continue}this.bin.set(s,en(o))}if(this.scripts=new Map,typeof e.scripts=="object"&&e.scripts!==null)for(let[s,o]of Object.entries(e.scripts)){if(typeof o!="string"){i.push(new Error(`Invalid script definition for '${s}'`));continue}this.scripts.set(s,o)}if(this.dependencies=new Map,typeof e.dependencies=="object"&&e.dependencies!==null)for(let[s,o]of Object.entries(e.dependencies)){if(typeof o!="string"){i.push(new Error(`Invalid dependency range for '${s}'`));continue}let a;try{a=En(s)}catch(c){i.push(new Error(`Parsing failed for the dependency name '${s}'`));continue}let l=Yt(a,o);this.dependencies.set(l.identHash,l)}if(this.devDependencies=new Map,typeof e.devDependencies=="object"&&e.devDependencies!==null)for(let[s,o]of Object.entries(e.devDependencies)){if(typeof o!="string"){i.push(new Error(`Invalid dependency range for '${s}'`));continue}let a;try{a=En(s)}catch(c){i.push(new Error(`Parsing failed for the dependency name '${s}'`));continue}let l=Yt(a,o);this.devDependencies.set(l.identHash,l)}if(this.peerDependencies=new Map,typeof e.peerDependencies=="object"&&e.peerDependencies!==null)for(let[s,o]of Object.entries(e.peerDependencies)){let a;try{a=En(s)}catch(c){i.push(new Error(`Parsing failed for the dependency name '${s}'`));continue}(typeof o!="string"||!o.startsWith(Yr.protocol)&&!Us(o))&&(i.push(new Error(`Invalid dependency range for '${s}'`)),o="*");let l=Yt(a,o);this.peerDependencies.set(l.identHash,l)}typeof e.workspaces=="object"&&e.workspaces.nohoist&&i.push(new Error("'nohoist' is deprecated, please use 'installConfig.hoistingLimits' instead"));let n=Array.isArray(e.workspaces)?e.workspaces:typeof e.workspaces=="object"&&e.workspaces!==null&&Array.isArray(e.workspaces.packages)?e.workspaces.packages:[];this.workspaceDefinitions=[];for(let s of n){if(typeof s!="string"){i.push(new Error(`Invalid workspace definition for '${s}'`));continue}this.workspaceDefinitions.push({pattern:s})}if(this.dependenciesMeta=new Map,typeof e.dependenciesMeta=="object"&&e.dependenciesMeta!==null)for(let[s,o]of Object.entries(e.dependenciesMeta)){if(typeof o!="object"||o===null){i.push(new Error(`Invalid meta field for '${s}`));continue}let a=pA(s),l=this.ensureDependencyMeta(a),c=Tw(o.built,{yamlCompatibilityMode:r});if(c===null){i.push(new Error(`Invalid built meta field for '${s}'`));continue}let u=Tw(o.optional,{yamlCompatibilityMode:r});if(u===null){i.push(new Error(`Invalid optional meta field for '${s}'`));continue}let g=Tw(o.unplugged,{yamlCompatibilityMode:r});if(g===null){i.push(new Error(`Invalid unplugged meta field for '${s}'`));continue}Object.assign(l,{built:c,optional:u,unplugged:g})}if(this.peerDependenciesMeta=new Map,typeof e.peerDependenciesMeta=="object"&&e.peerDependenciesMeta!==null)for(let[s,o]of Object.entries(e.peerDependenciesMeta)){if(typeof o!="object"||o===null){i.push(new Error(`Invalid meta field for '${s}'`));continue}let a=pA(s),l=this.ensurePeerDependencyMeta(a),c=Tw(o.optional,{yamlCompatibilityMode:r});if(c===null){i.push(new Error(`Invalid optional meta field for '${s}'`));continue}Object.assign(l,{optional:c})}if(this.resolutions=[],typeof e.resolutions=="object"&&e.resolutions!==null)for(let[s,o]of Object.entries(e.resolutions)){if(typeof o!="string"){i.push(new Error(`Invalid resolution entry for '${s}'`));continue}try{this.resolutions.push({pattern:gw(s),reference:o})}catch(a){i.push(a);continue}}if(Array.isArray(e.files)){this.files=new Set;for(let s of e.files){if(typeof s!="string"){i.push(new Error(`Invalid files entry for '${s}'`));continue}this.files.add(s)}}else this.files=null;if(typeof e.publishConfig=="object"&&e.publishConfig!==null){if(this.publishConfig={},typeof e.publishConfig.access=="string"&&(this.publishConfig.access=e.publishConfig.access),typeof e.publishConfig.main=="string"&&(this.publishConfig.main=en(e.publishConfig.main)),typeof e.publishConfig.module=="string"&&(this.publishConfig.module=en(e.publishConfig.module)),e.publishConfig.browser!=null)if(typeof e.publishConfig.browser=="string")this.publishConfig.browser=en(e.publishConfig.browser);else{this.publishConfig.browser=new Map;for(let[s,o]of Object.entries(e.publishConfig.browser))this.publishConfig.browser.set(en(s),typeof o=="string"?en(o):o)}if(typeof e.publishConfig.registry=="string"&&(this.publishConfig.registry=e.publishConfig.registry),typeof e.publishConfig.bin=="string")this.name!==null?this.publishConfig.bin=new Map([[this.name.name,en(e.publishConfig.bin)]]):i.push(new Error("String bin field, but no attached package name"));else if(typeof e.publishConfig.bin=="object"&&e.publishConfig.bin!==null){this.publishConfig.bin=new Map;for(let[s,o]of Object.entries(e.publishConfig.bin)){if(typeof o!="string"){i.push(new Error(`Invalid bin definition for '${s}'`));continue}this.publishConfig.bin.set(s,en(o))}}if(Array.isArray(e.publishConfig.executableFiles)){this.publishConfig.executableFiles=new Set;for(let s of e.publishConfig.executableFiles){if(typeof s!="string"){i.push(new Error("Invalid executable file definition"));continue}this.publishConfig.executableFiles.add(en(s))}}}else this.publishConfig=null;if(typeof e.installConfig=="object"&&e.installConfig!==null){this.installConfig={};for(let s of Object.keys(e.installConfig))s==="hoistingLimits"?typeof e.installConfig.hoistingLimits=="string"?this.installConfig.hoistingLimits=e.installConfig.hoistingLimits:i.push(new Error("Invalid hoisting limits definition")):s=="selfReferences"?typeof e.installConfig.selfReferences=="boolean"?this.installConfig.selfReferences=e.installConfig.selfReferences:i.push(new Error("Invalid selfReferences definition, must be a boolean value")):i.push(new Error(`Unrecognized installConfig key: ${s}`))}else this.installConfig=null;if(typeof e.optionalDependencies=="object"&&e.optionalDependencies!==null)for(let[s,o]of Object.entries(e.optionalDependencies)){if(typeof o!="string"){i.push(new Error(`Invalid dependency range for '${s}'`));continue}let a;try{a=En(s)}catch(g){i.push(new Error(`Parsing failed for the dependency name '${s}'`));continue}let l=Yt(a,o);this.dependencies.set(l.identHash,l);let c=Yt(a,"unknown"),u=this.ensureDependencyMeta(c);Object.assign(u,{optional:!0})}typeof e.preferUnplugged=="boolean"?this.preferUnplugged=e.preferUnplugged:this.preferUnplugged=null,this.errors=i}getForScope(e){switch(e){case"dependencies":return this.dependencies;case"devDependencies":return this.devDependencies;case"peerDependencies":return this.peerDependencies;default:throw new Error(`Unsupported value ("${e}")`)}}hasConsumerDependency(e){return!!(this.dependencies.has(e.identHash)||this.peerDependencies.has(e.identHash))}hasHardDependency(e){return!!(this.dependencies.has(e.identHash)||this.devDependencies.has(e.identHash))}hasSoftDependency(e){return!!this.peerDependencies.has(e.identHash)}hasDependency(e){return!!(this.hasHardDependency(e)||this.hasSoftDependency(e))}getConditions(){let e=[];return this.os&&this.os.length>0&&e.push(V6("os",this.os)),this.cpu&&this.cpu.length>0&&e.push(V6("cpu",this.cpu)),e.length>0?e.join(" & "):null}isCompatibleWithOS(e){return vA.isManifestFieldCompatible(this.os,e)}isCompatibleWithCPU(e){return vA.isManifestFieldCompatible(this.cpu,e)}ensureDependencyMeta(e){if(e.range!=="unknown"&&!J6.default.valid(e.range))throw new Error(`Invalid meta field range for '${In(e)}'`);let r=St(e),i=e.range!=="unknown"?e.range:null,n=this.dependenciesMeta.get(r);n||this.dependenciesMeta.set(r,n=new Map);let s=n.get(i);return s||n.set(i,s={}),s}ensurePeerDependencyMeta(e){if(e.range!=="unknown")throw new Error(`Invalid meta field range for '${In(e)}'`);let r=St(e),i=this.peerDependenciesMeta.get(r);return i||this.peerDependenciesMeta.set(r,i={}),i}setRawField(e,r,{after:i=[]}={}){let n=new Set(i.filter(s=>Object.prototype.hasOwnProperty.call(this.raw,s)));if(n.size===0||Object.prototype.hasOwnProperty.call(this.raw,e))this.raw[e]=r;else{let s=this.raw,o=this.raw={},a=!1;for(let l of Object.keys(s))o[l]=s[l],a||(n.delete(l),n.size===0&&(o[e]=r,a=!0))}}exportTo(e,{compatibilityMode:r=!0}={}){var s;if(Object.assign(e,this.raw),this.name!==null?e.name=St(this.name):delete e.name,this.version!==null?e.version=this.version:delete e.version,this.os!==null?e.os=this.os:delete e.os,this.cpu!==null?e.cpu=this.cpu:delete e.cpu,this.type!==null?e.type=this.type:delete e.type,this.packageManager!==null?e.packageManager=this.packageManager:delete e.packageManager,this.private?e.private=!0:delete e.private,this.license!==null?e.license=this.license:delete e.license,this.languageName!==null?e.languageName=this.languageName:delete e.languageName,this.main!==null?e.main=this.main:delete e.main,this.module!==null?e.module=this.module:delete e.module,this.browser!==null){let o=this.browser;typeof o=="string"?e.browser=o:o instanceof Map&&(e.browser=Object.assign({},...Array.from(o.keys()).sort().map(a=>({[a]:o.get(a)}))))}else delete e.browser;this.bin.size===1&&this.name!==null&&this.bin.has(this.name.name)?e.bin=this.bin.get(this.name.name):this.bin.size>0?e.bin=Object.assign({},...Array.from(this.bin.keys()).sort().map(o=>({[o]:this.bin.get(o)}))):delete e.bin,this.workspaceDefinitions.length>0?this.raw.workspaces&&!Array.isArray(this.raw.workspaces)?e.workspaces=_(P({},this.raw.workspaces),{packages:this.workspaceDefinitions.map(({pattern:o})=>o)}):e.workspaces=this.workspaceDefinitions.map(({pattern:o})=>o):this.raw.workspaces&&!Array.isArray(this.raw.workspaces)&&Object.keys(this.raw.workspaces).length>0?e.workspaces=this.raw.workspaces:delete e.workspaces;let i=[],n=[];for(let o of this.dependencies.values()){let a=this.dependenciesMeta.get(St(o)),l=!1;if(r&&a){let c=a.get(null);c&&c.optional&&(l=!0)}l?n.push(o):i.push(o)}i.length>0?e.dependencies=Object.assign({},...Ou(i).map(o=>({[St(o)]:o.range}))):delete e.dependencies,n.length>0?e.optionalDependencies=Object.assign({},...Ou(n).map(o=>({[St(o)]:o.range}))):delete e.optionalDependencies,this.devDependencies.size>0?e.devDependencies=Object.assign({},...Ou(this.devDependencies.values()).map(o=>({[St(o)]:o.range}))):delete e.devDependencies,this.peerDependencies.size>0?e.peerDependencies=Object.assign({},...Ou(this.peerDependencies.values()).map(o=>({[St(o)]:o.range}))):delete e.peerDependencies,e.dependenciesMeta={};for(let[o,a]of gn(this.dependenciesMeta.entries(),([l,c])=>l))for(let[l,c]of gn(a.entries(),([u,g])=>u!==null?`0${u}`:"1")){let u=l!==null?In(Yt(En(o),l)):o,g=P({},c);r&&l===null&&delete g.optional,Object.keys(g).length!==0&&(e.dependenciesMeta[u]=g)}if(Object.keys(e.dependenciesMeta).length===0&&delete e.dependenciesMeta,this.peerDependenciesMeta.size>0?e.peerDependenciesMeta=Object.assign({},...gn(this.peerDependenciesMeta.entries(),([o,a])=>o).map(([o,a])=>({[o]:a}))):delete e.peerDependenciesMeta,this.resolutions.length>0?e.resolutions=Object.assign({},...this.resolutions.map(({pattern:o,reference:a})=>({[fw(o)]:a}))):delete e.resolutions,this.files!==null?e.files=Array.from(this.files):delete e.files,this.preferUnplugged!==null?e.preferUnplugged=this.preferUnplugged:delete e.preferUnplugged,this.scripts!==null&&this.scripts.size>0){(s=e.scripts)!=null||(e.scripts={});for(let o of Object.keys(e.scripts))this.scripts.has(o)||delete e.scripts[o];for(let[o,a]of this.scripts.entries())e.scripts[o]=a}else delete e.scripts;return e}},Ze=vA;Ze.fileName="package.json",Ze.allDependencies=["dependencies","devDependencies","peerDependencies"],Ze.hardDependencies=["dependencies","devDependencies"];function W6(t){let e=t.match(/^[ \t]+/m);return e?e[0]:" "}function z6(t){return t.charCodeAt(0)===65279?t.slice(1):t}function en(t){return t.replace(/\\/g,"/")}function Tw(t,{yamlCompatibilityMode:e}){return e?Kv(t):typeof t=="undefined"||typeof t=="boolean"?t:null}function _6(t,e){let r=e.search(/[^!]/);if(r===-1)return"invalid";let i=r%2==0?"":"!",n=e.slice(r);return`${i}${t}=${n}`}function V6(t,e){return e.length===1?_6(t,e[0]):`(${e.map(r=>_6(t,r)).join(" | ")})`}var e9=ie($6()),Ow=ie(ml());var t9=["\u280B","\u2819","\u2839","\u2838","\u283C","\u2834","\u2826","\u2827","\u2807","\u280F"],r9=80,NFe=new Set([z.FETCH_NOT_CACHED,z.UNUSED_CACHE_ENTRY]),LFe=5,SA=Ow.default.GITHUB_ACTIONS?{start:t=>`::group::${t} -`,end:t=>`::endgroup:: -`}:Ow.default.TRAVIS?{start:t=>`travis_fold:start:${t} -`,end:t=>`travis_fold:end:${t} -`}:Ow.default.GITLAB?{start:t=>`section_start:${Math.floor(Date.now()/1e3)}:${t.toLowerCase().replace(/\W+/g,"_")}[collapsed=true]\r${t} -`,end:t=>`section_end:${Math.floor(Date.now()/1e3)}:${t.toLowerCase().replace(/\W+/g,"_")}\r`}:null,i9=new Date,TFe=["iTerm.app","Apple_Terminal"].includes(process.env.TERM_PROGRAM)||!!process.env.WT_SESSION,MFe=t=>t,Kw=MFe({patrick:{date:[17,3],chars:["\u{1F340}","\u{1F331}"],size:40},simba:{date:[19,7],chars:["\u{1F981}","\u{1F334}"],size:40},jack:{date:[31,10],chars:["\u{1F383}","\u{1F987}"],size:40},hogsfather:{date:[31,12],chars:["\u{1F389}","\u{1F384}"],size:40},default:{chars:["=","-"],size:80}}),OFe=TFe&&Object.keys(Kw).find(t=>{let e=Kw[t];return!(e.date&&(e.date[0]!==i9.getDate()||e.date[1]!==i9.getMonth()+1))})||"default";function n9(t,{configuration:e,json:r}){if(!e.get("enableMessageNames"))return"";let n=KE(t===null?0:t);return!r&&t===null?Ve(e,n,"grey"):n}function eD(t,{configuration:e,json:r}){let i=n9(t,{configuration:e,json:r});if(!i||t===null||t===z.UNNAMED)return i;let n=z[t],s=`https://yarnpkg.com/advanced/error-codes#${i}---${n}`.toLowerCase();return Ku(e,i,s)}var Fe=class extends Xi{constructor({configuration:e,stdout:r,json:i=!1,includeFooter:n=!0,includeLogs:s=!i,includeInfos:o=s,includeWarnings:a=s,forgettableBufferSize:l=LFe,forgettableNames:c=new Set}){super();this.uncommitted=new Set;this.cacheHitCount=0;this.cacheMissCount=0;this.lastCacheMiss=null;this.warningCount=0;this.errorCount=0;this.startTime=Date.now();this.indent=0;this.progress=new Map;this.progressTime=0;this.progressFrame=0;this.progressTimeout=null;this.forgettableLines=[];Cp(this,{configuration:e}),this.configuration=e,this.forgettableBufferSize=l,this.forgettableNames=new Set([...c,...NFe]),this.includeFooter=n,this.includeInfos=o,this.includeWarnings=a,this.json=i,this.stdout=r;let u=this.configuration.get("progressBarStyle")||OFe;if(!Object.prototype.hasOwnProperty.call(Kw,u))throw new Error("Assertion failed: Invalid progress bar style");this.progressStyle=Kw[u];let g="\u27A4 YN0000: \u250C ".length,f=Math.max(0,Math.min(process.stdout.columns-g,80));this.progressMaxScaledSize=Math.floor(this.progressStyle.size*f/80)}static async start(e,r){let i=new this(e),n=process.emitWarning;process.emitWarning=(s,o)=>{if(typeof s!="string"){let l=s;s=l.message,o=o!=null?o:l.name}let a=typeof o!="undefined"?`${o}: ${s}`:s;i.reportWarning(z.UNNAMED,a)};try{await r(i)}catch(s){i.reportExceptionOnce(s)}finally{await i.finalize(),process.emitWarning=n}return i}hasErrors(){return this.errorCount>0}exitCode(){return this.hasErrors()?1:0}reportCacheHit(e){this.cacheHitCount+=1}reportCacheMiss(e,r){this.lastCacheMiss=e,this.cacheMissCount+=1,typeof r!="undefined"&&!this.configuration.get("preferAggregateCacheInfo")&&this.reportInfo(z.FETCH_NOT_CACHED,r)}startTimerSync(e,r,i){let n=typeof r=="function"?{}:r,s=typeof r=="function"?r:i,o={committed:!1,action:()=>{this.reportInfo(null,`\u250C ${e}`),this.indent+=1,SA!==null&&!this.json&&this.includeInfos&&this.stdout.write(SA.start(e))}};n.skipIfEmpty?this.uncommitted.add(o):(o.action(),o.committed=!0);let a=Date.now();try{return s()}catch(l){throw this.reportExceptionOnce(l),l}finally{let l=Date.now();this.uncommitted.delete(o),o.committed&&(this.indent-=1,SA!==null&&!this.json&&this.includeInfos&&this.stdout.write(SA.end(e)),this.configuration.get("enableTimers")&&l-a>200?this.reportInfo(null,`\u2514 Completed in ${Ve(this.configuration,l-a,Le.DURATION)}`):this.reportInfo(null,"\u2514 Completed"))}}async startTimerPromise(e,r,i){let n=typeof r=="function"?{}:r,s=typeof r=="function"?r:i,o={committed:!1,action:()=>{this.reportInfo(null,`\u250C ${e}`),this.indent+=1,SA!==null&&!this.json&&this.includeInfos&&this.stdout.write(SA.start(e))}};n.skipIfEmpty?this.uncommitted.add(o):(o.action(),o.committed=!0);let a=Date.now();try{return await s()}catch(l){throw this.reportExceptionOnce(l),l}finally{let l=Date.now();this.uncommitted.delete(o),o.committed&&(this.indent-=1,SA!==null&&!this.json&&this.includeInfos&&this.stdout.write(SA.end(e)),this.configuration.get("enableTimers")&&l-a>200?this.reportInfo(null,`\u2514 Completed in ${Ve(this.configuration,l-a,Le.DURATION)}`):this.reportInfo(null,"\u2514 Completed"))}}async startCacheReport(e){let r=this.configuration.get("preferAggregateCacheInfo")?{cacheHitCount:this.cacheHitCount,cacheMissCount:this.cacheMissCount}:null;try{return await e()}catch(i){throw this.reportExceptionOnce(i),i}finally{r!==null&&this.reportCacheChanges(r)}}reportSeparator(){this.indent===0?this.writeLineWithForgettableReset(""):this.reportInfo(null,"")}reportInfo(e,r){if(!this.includeInfos)return;this.commit();let i=this.formatNameWithHyperlink(e),n=i?`${i}: `:"",s=`${Ve(this.configuration,"\u27A4","blueBright")} ${n}${this.formatIndent()}${r}`;if(this.json)this.reportJson({type:"info",name:e,displayName:this.formatName(e),indent:this.formatIndent(),data:r});else if(this.forgettableNames.has(e))if(this.forgettableLines.push(s),this.forgettableLines.length>this.forgettableBufferSize){for(;this.forgettableLines.length>this.forgettableBufferSize;)this.forgettableLines.shift();this.writeLines(this.forgettableLines,{truncate:!0})}else this.writeLine(s,{truncate:!0});else this.writeLineWithForgettableReset(s)}reportWarning(e,r){if(this.warningCount+=1,!this.includeWarnings)return;this.commit();let i=this.formatNameWithHyperlink(e),n=i?`${i}: `:"";this.json?this.reportJson({type:"warning",name:e,displayName:this.formatName(e),indent:this.formatIndent(),data:r}):this.writeLineWithForgettableReset(`${Ve(this.configuration,"\u27A4","yellowBright")} ${n}${this.formatIndent()}${r}`)}reportError(e,r){this.errorCount+=1,this.commit();let i=this.formatNameWithHyperlink(e),n=i?`${i}: `:"";this.json?this.reportJson({type:"error",name:e,displayName:this.formatName(e),indent:this.formatIndent(),data:r}):this.writeLineWithForgettableReset(`${Ve(this.configuration,"\u27A4","redBright")} ${n}${this.formatIndent()}${r}`,{truncate:!1})}reportProgress(e){let r=!1,i=Promise.resolve().then(async()=>{let s={progress:0,title:void 0};this.progress.set(e,{definition:s,lastScaledSize:-1}),this.refreshProgress(-1);for await(let{progress:o,title:a}of e)r||s.progress===o&&s.title===a||(s.progress=o,s.title=a,this.refreshProgress());n()}),n=()=>{r||(r=!0,this.progress.delete(e),this.refreshProgress(1))};return _(P({},i),{stop:n})}reportJson(e){this.json&&this.writeLineWithForgettableReset(`${JSON.stringify(e)}`)}async finalize(){if(!this.includeFooter)return;let e="";this.errorCount>0?e="Failed with errors":this.warningCount>0?e="Done with warnings":e="Done";let r=Ve(this.configuration,Date.now()-this.startTime,Le.DURATION),i=this.configuration.get("enableTimers")?`${e} in ${r}`:e;this.errorCount>0?this.reportError(z.UNNAMED,i):this.warningCount>0?this.reportWarning(z.UNNAMED,i):this.reportInfo(z.UNNAMED,i)}writeLine(e,{truncate:r}={}){this.clearProgress({clear:!0}),this.stdout.write(`${this.truncate(e,{truncate:r})} -`),this.writeProgress()}writeLineWithForgettableReset(e,{truncate:r}={}){this.forgettableLines=[],this.writeLine(e,{truncate:r})}writeLines(e,{truncate:r}={}){this.clearProgress({delta:e.length});for(let i of e)this.stdout.write(`${this.truncate(i,{truncate:r})} -`);this.writeProgress()}reportCacheChanges({cacheHitCount:e,cacheMissCount:r}){let i=this.cacheHitCount-e,n=this.cacheMissCount-r;if(i===0&&n===0)return;let s="";this.cacheHitCount>1?s+=`${this.cacheHitCount} packages were already cached`:this.cacheHitCount===1?s+=" - one package was already cached":s+="No packages were cached",this.cacheHitCount>0?this.cacheMissCount>1?s+=`, ${this.cacheMissCount} had to be fetched`:this.cacheMissCount===1&&(s+=`, one had to be fetched (${lt(this.configuration,this.lastCacheMiss)})`):this.cacheMissCount>1?s+=` - ${this.cacheMissCount} packages had to be fetched`:this.cacheMissCount===1&&(s+=` - one package had to be fetched (${lt(this.configuration,this.lastCacheMiss)})`),this.reportInfo(z.FETCH_NOT_CACHED,s)}commit(){let e=this.uncommitted;this.uncommitted=new Set;for(let r of e)r.committed=!0,r.action()}clearProgress({delta:e=0,clear:r=!1}){!this.configuration.get("enableProgressBars")||this.json||this.progress.size+e>0&&(this.stdout.write(`[${this.progress.size+e}A`),(e>0||r)&&this.stdout.write(""))}writeProgress(){if(!this.configuration.get("enableProgressBars")||this.json||(this.progressTimeout!==null&&clearTimeout(this.progressTimeout),this.progressTimeout=null,this.progress.size===0))return;let e=Date.now();e-this.progressTime>r9&&(this.progressFrame=(this.progressFrame+1)%t9.length,this.progressTime=e);let r=t9[this.progressFrame];for(let i of this.progress.values()){let n=this.progressStyle.chars[0].repeat(i.lastScaledSize),s=this.progressStyle.chars[1].repeat(this.progressMaxScaledSize-i.lastScaledSize),o=this.formatName(null),a=o?`${o}: `:"";this.stdout.write(`${Ve(this.configuration,"\u27A4","blueBright")} ${a}${r} ${n}${s} -`)}this.progressTimeout=setTimeout(()=>{this.refreshProgress()},r9)}refreshProgress(e=0){let r=!1;if(this.progress.size===0)r=!0;else for(let i of this.progress.values()){let n=Math.trunc(this.progressMaxScaledSize*i.definition.progress),s=i.lastScaledSize;if(i.lastScaledSize=n,n!==s){r=!0;break}}r&&(this.clearProgress({delta:e}),this.writeProgress())}truncate(e,{truncate:r}={}){return this.configuration.get("enableProgressBars")||(r=!1),typeof r=="undefined"&&(r=this.configuration.get("preferTruncatedLines")),r&&(e=(0,e9.default)(e,0,process.stdout.columns-1)),e}formatName(e){return n9(e,{configuration:this.configuration,json:this.json})}formatNameWithHyperlink(e){return eD(e,{configuration:this.configuration,json:this.json})}formatIndent(){return"\u2502 ".repeat(this.indent)}};var Zr="3.1.1";var tn;(function(n){n.Yarn1="Yarn Classic",n.Yarn2="Yarn",n.Npm="npm",n.Pnpm="pnpm"})(tn||(tn={}));async function ba(t,e,r,i=[]){if(process.platform==="win32"){let n=`@goto #_undefined_# 2>NUL || @title %COMSPEC% & @setlocal & @"${r}" ${i.map(s=>`"${s.replace('"','""')}"`).join(" ")} %*`;await T.writeFilePromise(v.format({dir:t,name:e,ext:".cmd"}),n)}await T.writeFilePromise(v.join(t,e),`#!/bin/sh -exec "${r}" ${i.map(n=>`'${n.replace(/'/g,`'"'"'`)}'`).join(" ")} "$@" -`,{mode:493})}async function a9(t){let e=await Ze.tryFind(t);if(e==null?void 0:e.packageManager){let i=Qy(e.packageManager);if(i==null?void 0:i.name){let n=`found ${JSON.stringify({packageManager:e.packageManager})} in manifest`,[s]=i.reference.split(".");switch(i.name){case"yarn":return{packageManager:Number(s)===1?tn.Yarn1:tn.Yarn2,reason:n};case"npm":return{packageManager:tn.Npm,reason:n};case"pnpm":return{packageManager:tn.Pnpm,reason:n}}}}let r;try{r=await T.readFilePromise(v.join(t,wt.lockfile),"utf8")}catch{}return r!==void 0?r.match(/^__metadata:$/m)?{packageManager:tn.Yarn2,reason:'"__metadata" key found in yarn.lock'}:{packageManager:tn.Yarn1,reason:'"__metadata" key not found in yarn.lock, must be a Yarn classic lockfile'}:T.existsSync(v.join(t,"package-lock.json"))?{packageManager:tn.Npm,reason:`found npm's "package-lock.json" lockfile`}:T.existsSync(v.join(t,"pnpm-lock.yaml"))?{packageManager:tn.Pnpm,reason:`found pnpm's "pnpm-lock.yaml" lockfile`}:null}async function Vp({project:t,locator:e,binFolder:r,lifecycleScript:i}){var l,c;let n={};for(let[u,g]of Object.entries(process.env))typeof g!="undefined"&&(n[u.toLowerCase()!=="path"?u:"PATH"]=g);let s=M.fromPortablePath(r);n.BERRY_BIN_FOLDER=M.fromPortablePath(s);let o=process.env.COREPACK_ROOT?M.join(process.env.COREPACK_ROOT,"dist/yarn.js"):process.argv[1];if(await Promise.all([ba(r,"node",process.execPath),...Zr!==null?[ba(r,"run",process.execPath,[o,"run"]),ba(r,"yarn",process.execPath,[o]),ba(r,"yarnpkg",process.execPath,[o]),ba(r,"node-gyp",process.execPath,[o,"run","--top-level","node-gyp"])]:[]]),t&&(n.INIT_CWD=M.fromPortablePath(t.configuration.startingCwd),n.PROJECT_CWD=M.fromPortablePath(t.cwd)),n.PATH=n.PATH?`${s}${M.delimiter}${n.PATH}`:`${s}`,n.npm_execpath=`${s}${M.sep}yarn`,n.npm_node_execpath=`${s}${M.sep}node`,e){if(!t)throw new Error("Assertion failed: Missing project");let u=t.tryWorkspaceByLocator(e),g=u?(l=u.manifest.version)!=null?l:"":(c=t.storedPackages.get(e.locatorHash).version)!=null?c:"";n.npm_package_name=St(e),n.npm_package_version=g}let a=Zr!==null?`yarn/${Zr}`:`yarn/${mu("@yarnpkg/core").version}-core`;return n.npm_config_user_agent=`${a} npm/? node/${process.versions.node} ${process.platform} ${process.arch}`,i&&(n.npm_lifecycle_event=i),t&&await t.configuration.triggerHook(u=>u.setupScriptEnvironment,t,n,async(u,g,f)=>await ba(r,kr(u),g,f)),n}var KFe=2,UFe=(0,o9.default)(KFe);async function HFe(t,e,{configuration:r,report:i,workspace:n=null,locator:s=null}){await UFe(async()=>{await T.mktempPromise(async o=>{let a=v.join(o,"pack.log"),l=null,{stdout:c,stderr:u}=r.getSubprocessStreams(a,{prefix:M.fromPortablePath(t),report:i}),g=s&&Io(s)?lp(s):s,f=g?is(g):"an external project";c.write(`Packing ${f} from sources -`);let h=await a9(t),p;h!==null?(c.write(`Using ${h.packageManager} for bootstrap. Reason: ${h.reason} - -`),p=h.packageManager):(c.write(`No package manager configuration detected; defaulting to Yarn - -`),p=tn.Yarn2),await T.mktempPromise(async d=>{let m=await Vp({binFolder:d}),B=new Map([[tn.Yarn1,async()=>{let R=n!==null?["workspace",n]:[],H=await to("yarn",["set","version","classic","--only-if-needed"],{cwd:t,env:m,stdin:l,stdout:c,stderr:u,end:Pn.ErrorCode});if(H.code!==0)return H.code;await T.appendFilePromise(v.join(t,".npmignore"),`/.yarn -`),c.write(` -`);let L=await to("yarn",["install"],{cwd:t,env:m,stdin:l,stdout:c,stderr:u,end:Pn.ErrorCode});if(L.code!==0)return L.code;c.write(` -`);let K=await to("yarn",[...R,"pack","--filename",M.fromPortablePath(e)],{cwd:t,env:m,stdin:l,stdout:c,stderr:u});return K.code!==0?K.code:0}],[tn.Yarn2,async()=>{let R=n!==null?["workspace",n]:[];m.YARN_ENABLE_INLINE_BUILDS="1";let H=v.join(t,wt.lockfile);await T.existsPromise(H)||await T.writeFilePromise(H,"");let L=await to("yarn",[...R,"pack","--install-if-needed","--filename",M.fromPortablePath(e)],{cwd:t,env:m,stdin:l,stdout:c,stderr:u});return L.code!==0?L.code:0}],[tn.Npm,async()=>{if(n!==null){let A=new cc.PassThrough,V=Cu(A);A.pipe(c,{end:!1});let W=await to("npm",["--version"],{cwd:t,env:m,stdin:l,stdout:A,stderr:u,end:Pn.Never});if(A.end(),W.code!==0)return c.end(),u.end(),W.code;let X=(await V).toString().trim();if(!lc(X,">=7.x")){let F=Eo(null,"npm"),D=Yt(F,X),he=Yt(F,">=7.x");throw new Error(`Workspaces aren't supported by ${Xt(r,D)}; please upgrade to ${Xt(r,he)} (npm has been detected as the primary package manager for ${Ve(r,t,Le.PATH)})`)}}let R=n!==null?["--workspace",n]:[];delete m.npm_config_user_agent;let H=await to("npm",["install"],{cwd:t,env:m,stdin:l,stdout:c,stderr:u,end:Pn.ErrorCode});if(H.code!==0)return H.code;let L=new cc.PassThrough,K=Cu(L);L.pipe(c);let J=await to("npm",["pack","--silent",...R],{cwd:t,env:m,stdin:l,stdout:L,stderr:u});if(J.code!==0)return J.code;let ne=(await K).toString().trim().replace(/^.*\n/s,""),q=v.resolve(t,M.toPortablePath(ne));return await T.renamePromise(q,e),0}]]).get(p);if(typeof B=="undefined")throw new Error("Assertion failed: Unsupported workflow");let b=await B();if(!(b===0||typeof b=="undefined"))throw T.detachTemp(o),new nt(z.PACKAGE_PREPARATION_FAILED,`Packing the package failed (exit code ${b}, logs can be found here: ${Ve(r,a,Le.PATH)})`)})})})}async function GFe(t,e,{project:r}){let i=r.tryWorkspaceByLocator(t);if(i!==null)return tD(i,e);let n=r.storedPackages.get(t.locatorHash);if(!n)throw new Error(`Package for ${lt(r.configuration,t)} not found in the project`);return await Jn.openPromise(async s=>{let o=r.configuration,a=r.configuration.getLinkers(),l={project:r,report:new Fe({stdout:new cc.PassThrough,configuration:o})},c=a.find(h=>h.supportsPackage(n,l));if(!c)throw new Error(`The package ${lt(r.configuration,n)} isn't supported by any of the available linkers`);let u=await c.findPackageLocation(n,l),g=new Ft(u,{baseFs:s});return(await Ze.find(Se.dot,{baseFs:g})).scripts.has(e)},{libzip:await $i()})}async function Uw(t,e,r,{cwd:i,project:n,stdin:s,stdout:o,stderr:a}){return await T.mktempPromise(async l=>{let{manifest:c,env:u,cwd:g}=await A9(t,{project:n,binFolder:l,cwd:i,lifecycleScript:e}),f=c.scripts.get(e);if(typeof f=="undefined")return 1;let h=async()=>await Fw(f,r,{cwd:g,env:u,stdin:s,stdout:o,stderr:a});return await(await n.configuration.reduceHook(d=>d.wrapScriptExecution,h,n,t,e,{script:f,args:r,cwd:g,env:u,stdin:s,stdout:o,stderr:a}))()})}async function rD(t,e,r,{cwd:i,project:n,stdin:s,stdout:o,stderr:a}){return await T.mktempPromise(async l=>{let{env:c,cwd:u}=await A9(t,{project:n,binFolder:l,cwd:i});return await Fw(e,r,{cwd:u,env:c,stdin:s,stdout:o,stderr:a})})}async function jFe(t,{binFolder:e,cwd:r,lifecycleScript:i}){let n=await Vp({project:t.project,locator:t.anchoredLocator,binFolder:e,lifecycleScript:i});return await Promise.all(Array.from(await l9(t),([s,[,o]])=>ba(e,kr(s),process.execPath,[o]))),typeof r=="undefined"&&(r=v.dirname(await T.realpathPromise(v.join(t.cwd,"package.json")))),{manifest:t.manifest,binFolder:e,env:n,cwd:r}}async function A9(t,{project:e,binFolder:r,cwd:i,lifecycleScript:n}){let s=e.tryWorkspaceByLocator(t);if(s!==null)return jFe(s,{binFolder:r,cwd:i,lifecycleScript:n});let o=e.storedPackages.get(t.locatorHash);if(!o)throw new Error(`Package for ${lt(e.configuration,t)} not found in the project`);return await Jn.openPromise(async a=>{let l=e.configuration,c=e.configuration.getLinkers(),u={project:e,report:new Fe({stdout:new cc.PassThrough,configuration:l})},g=c.find(m=>m.supportsPackage(o,u));if(!g)throw new Error(`The package ${lt(e.configuration,o)} isn't supported by any of the available linkers`);let f=await Vp({project:e,locator:t,binFolder:r,lifecycleScript:n});await Promise.all(Array.from(await Hw(t,{project:e}),([m,[,I]])=>ba(r,kr(m),process.execPath,[I])));let h=await g.findPackageLocation(o,u),p=new Ft(h,{baseFs:a}),d=await Ze.find(Se.dot,{baseFs:p});return typeof i=="undefined"&&(i=h),{manifest:d,binFolder:r,env:f,cwd:i}},{libzip:await $i()})}async function c9(t,e,r,{cwd:i,stdin:n,stdout:s,stderr:o}){return await Uw(t.anchoredLocator,e,r,{cwd:i,project:t.project,stdin:n,stdout:s,stderr:o})}function tD(t,e){return t.manifest.scripts.has(e)}async function u9(t,e,{cwd:r,report:i}){let{configuration:n}=t.project,s=null;await T.mktempPromise(async o=>{let a=v.join(o,`${e}.log`),l=`# This file contains the result of Yarn calling the "${e}" lifecycle script inside a workspace ("${M.fromPortablePath(t.cwd)}") -`,{stdout:c,stderr:u}=n.getSubprocessStreams(a,{report:i,prefix:lt(n,t.anchoredLocator),header:l});i.reportInfo(z.LIFECYCLE_SCRIPT,`Calling the "${e}" lifecycle script`);let g=await c9(t,e,[],{cwd:r,stdin:s,stdout:c,stderr:u});if(c.end(),u.end(),g!==0)throw T.detachTemp(o),new nt(z.LIFECYCLE_SCRIPT,`${(0,s9.default)(e)} script failed (exit code ${Ve(n,g,Le.NUMBER)}, logs can be found here: ${Ve(n,a,Le.PATH)}); run ${Ve(n,`yarn ${e}`,Le.CODE)} to investigate`)})}async function YFe(t,e,r){tD(t,e)&&await u9(t,e,r)}async function Hw(t,{project:e}){let r=e.configuration,i=new Map,n=e.storedPackages.get(t.locatorHash);if(!n)throw new Error(`Package for ${lt(r,t)} not found in the project`);let s=new cc.Writable,o=r.getLinkers(),a={project:e,report:new Fe({configuration:r,stdout:s})},l=new Set([t.locatorHash]);for(let u of n.dependencies.values()){let g=e.storedResolutions.get(u.descriptorHash);if(!g)throw new Error(`Assertion failed: The resolution (${Xt(r,u)}) should have been registered`);l.add(g)}let c=await Promise.all(Array.from(l,async u=>{let g=e.storedPackages.get(u);if(!g)throw new Error(`Assertion failed: The package (${u}) should have been registered`);if(g.bin.size===0)return kl.skip;let f=o.find(p=>p.supportsPackage(g,a));if(!f)return kl.skip;let h=null;try{h=await f.findPackageLocation(g,a)}catch(p){if(p.code==="LOCATOR_NOT_INSTALLED")return kl.skip;throw p}return{dependency:g,packageLocation:h}}));for(let u of c){if(u===kl.skip)continue;let{dependency:g,packageLocation:f}=u;for(let[h,p]of g.bin)i.set(h,[g,M.fromPortablePath(v.resolve(f,p))])}return i}async function l9(t){return await Hw(t.anchoredLocator,{project:t.project})}async function g9(t,e,r,{cwd:i,project:n,stdin:s,stdout:o,stderr:a,nodeArgs:l=[],packageAccessibleBinaries:c}){c!=null||(c=await Hw(t,{project:n}));let u=c.get(e);if(!u)throw new Error(`Binary not found (${e}) for ${lt(n.configuration,t)}`);return await T.mktempPromise(async g=>{let[,f]=u,h=await Vp({project:n,locator:t,binFolder:g});await Promise.all(Array.from(c,([d,[,m]])=>ba(h.BERRY_BIN_FOLDER,kr(d),process.execPath,[m])));let p;try{p=await to(process.execPath,[...l,f,...r],{cwd:i,env:h,stdin:s,stdout:o,stderr:a})}finally{await T.removePromise(h.BERRY_BIN_FOLDER)}return p.code})}async function qFe(t,e,r,{cwd:i,stdin:n,stdout:s,stderr:o,packageAccessibleBinaries:a}){return await g9(t.anchoredLocator,e,r,{project:t.project,cwd:i,stdin:n,stdout:s,stderr:o,packageAccessibleBinaries:a})}var Ai={};it(Ai,{convertToZip:()=>lTe,extractArchiveTo:()=>uTe,makeArchiveFromDirectory:()=>ATe});var d_=ie(require("stream")),C_=ie(Z7());var u_=ie(require("os")),g_=ie(c_()),f_=ie(require("worker_threads")),IR=class{constructor(e){this.source=e;this.pool=[];this.queue=new g_.default({concurrency:Math.max(1,(0,u_.cpus)().length)});let r=setTimeout(()=>{if(!(this.queue.size!==0||this.queue.pending!==0)){for(let i of this.pool)i.terminate();this.pool=[]}},1e3).unref();this.queue.on("idle",()=>{r.refresh()})}run(e){return this.queue.add(()=>{var i;let r=(i=this.pool.pop())!=null?i:new f_.Worker(this.source,{eval:!0,execArgv:[...process.execArgv,"--unhandled-rejections=strict"]});return r.ref(),new Promise((n,s)=>{let o=a=>{a!==0&&s(new Error(`Worker exited with code ${a}`))};r.once("message",a=>{this.pool.push(r),r.unref(),r.off("error",s),r.off("exit",o),n(a)}),r.once("error",s),r.once("exit",o),r.postMessage(e)})})}};var m_=ie(p_());async function ATe(t,{baseFs:e=new Wt,prefixPath:r=Se.root,compressionLevel:i,inMemory:n=!1}={}){let s=await $i(),o;if(n)o=new Jr(null,{libzip:s,level:i});else{let l=await T.mktempPromise(),c=v.join(l,"archive.zip");o=new Jr(c,{create:!0,libzip:s,level:i})}let a=v.resolve(Se.root,r);return await o.copyPromise(a,t,{baseFs:e,stableTime:!0,stableSort:!0}),o}var E_;async function lTe(t,e){let r=await T.mktempPromise(),i=v.join(r,"archive.zip");return E_||(E_=new IR((0,m_.getContent)())),await E_.run({tmpFile:i,tgz:t,opts:e}),new Jr(i,{libzip:await $i(),level:e.compressionLevel})}async function*cTe(t){let e=new C_.default.Parse,r=new d_.PassThrough({objectMode:!0,autoDestroy:!0,emitClose:!0});e.on("entry",i=>{r.write(i)}),e.on("error",i=>{r.destroy(i)}),e.on("close",()=>{r.destroyed||r.end()}),e.end(t);for await(let i of r){let n=i;yield n,n.resume()}}async function uTe(t,e,{stripComponents:r=0,prefixPath:i=Se.dot}={}){var s,o;function n(a){if(a.path[0]==="/")return!0;let l=a.path.split(/\//g);return!!(l.some(c=>c==="..")||l.length<=r)}for await(let a of cTe(t)){if(n(a))continue;let l=v.normalize(M.toPortablePath(a.path)).replace(/\/$/,"").split(/\//g);if(l.length<=r)continue;let c=l.slice(r).join("/"),u=v.join(i,c),g=420;switch((a.type==="Directory"||(((s=a.mode)!=null?s:0)&73)!=0)&&(g|=73),a.type){case"Directory":e.mkdirpSync(v.dirname(u),{chmod:493,utimes:[mr.SAFE_TIME,mr.SAFE_TIME]}),e.mkdirSync(u,{mode:g}),e.utimesSync(u,mr.SAFE_TIME,mr.SAFE_TIME);break;case"OldFile":case"File":e.mkdirpSync(v.dirname(u),{chmod:493,utimes:[mr.SAFE_TIME,mr.SAFE_TIME]}),e.writeFileSync(u,await Cu(a),{mode:g}),e.utimesSync(u,mr.SAFE_TIME,mr.SAFE_TIME);break;case"SymbolicLink":e.mkdirpSync(v.dirname(u),{chmod:493,utimes:[mr.SAFE_TIME,mr.SAFE_TIME]}),e.symlinkSync(a.linkpath,u),(o=e.lutimesSync)==null||o.call(e,u,mr.SAFE_TIME,mr.SAFE_TIME);break}}return e}var Hs={};it(Hs,{emitList:()=>gTe,emitTree:()=>b_,treeNodeToJson:()=>Q_,treeNodeToTreeify:()=>B_});var w_=ie(y_());function B_(t,{configuration:e}){let r={},i=(n,s)=>{let o=Array.isArray(n)?n.entries():Object.entries(n);for(let[a,{label:l,value:c,children:u}]of o){let g=[];typeof l!="undefined"&&g.push(Py(e,l,Gl.BOLD)),typeof c!="undefined"&&g.push(Ve(e,c[0],c[1])),g.length===0&&g.push(Py(e,`${a}`,Gl.BOLD));let f=g.join(": "),h=s[f]={};typeof u!="undefined"&&i(u,h)}};if(typeof t.children=="undefined")throw new Error("The root node must only contain children");return i(t.children,r),r}function Q_(t){let e=r=>{var s;if(typeof r.children=="undefined"){if(typeof r.value=="undefined")throw new Error("Assertion failed: Expected a value to be set if the children are missing");return Uu(r.value[0],r.value[1])}let i=Array.isArray(r.children)?r.children.entries():Object.entries((s=r.children)!=null?s:{}),n=Array.isArray(r.children)?[]:{};for(let[o,a]of i)n[o]=e(a);return typeof r.value=="undefined"?n:{value:Uu(r.value[0],r.value[1]),children:n}};return e(t)}function gTe(t,{configuration:e,stdout:r,json:i}){let n=t.map(s=>({value:s}));b_({children:n},{configuration:e,stdout:r,json:i})}function b_(t,{configuration:e,stdout:r,json:i,separators:n=0}){var o;if(i){let a=Array.isArray(t.children)?t.children.values():Object.values((o=t.children)!=null?o:{});for(let l of a)r.write(`${JSON.stringify(Q_(l))} -`);return}let s=(0,w_.asTree)(B_(t,{configuration:e}),!1,!1);if(n>=1&&(s=s.replace(/^([├└]─)/gm,`\u2502 -$1`).replace(/^│\n/,"")),n>=2)for(let a=0;a<2;++a)s=s.replace(/^([│ ].{2}[├│ ].{2}[^\n]+\n)(([│ ]).{2}[├└].{2}[^\n]*\n[│ ].{2}[│ ].{2}[├└]─)/gm,`$1$3 \u2502 -$2`).replace(/^│\n/,"");if(n>=3)throw new Error("Only the first two levels are accepted by treeUtils.emitTree");r.write(s)}var v_=ie(require("crypto")),BR=ie(require("fs"));var fTe=8,Qt=class{constructor(e,{configuration:r,immutable:i=r.get("enableImmutableCache"),check:n=!1}){this.markedFiles=new Set;this.mutexes=new Map;this.cacheId=`-${(0,v_.randomBytes)(8).toString("hex")}.tmp`;this.configuration=r,this.cwd=e,this.immutable=i,this.check=n;let s=r.get("cacheKeyOverride");if(s!==null)this.cacheKey=`${s}`;else{let o=r.get("compressionLevel"),a=o!==pl?`c${o}`:"";this.cacheKey=[fTe,a].join("")}}static async find(e,{immutable:r,check:i}={}){let n=new Qt(e.get("cacheFolder"),{configuration:e,immutable:r,check:i});return await n.setup(),n}get mirrorCwd(){if(!this.configuration.get("enableMirror"))return null;let e=`${this.configuration.get("globalFolder")}/cache`;return e!==this.cwd?e:null}getVersionFilename(e){return`${Mu(e)}-${this.cacheKey}.zip`}getChecksumFilename(e,r){let n=hTe(r).slice(0,10);return`${Mu(e)}-${n}.zip`}getLocatorPath(e,r,i={}){var s;return this.mirrorCwd===null||((s=i.unstablePackages)==null?void 0:s.has(e.locatorHash))?v.resolve(this.cwd,this.getVersionFilename(e)):r===null||QR(r)!==this.cacheKey?null:v.resolve(this.cwd,this.getChecksumFilename(e,r))}getLocatorMirrorPath(e){let r=this.mirrorCwd;return r!==null?v.resolve(r,this.getVersionFilename(e)):null}async setup(){if(!this.configuration.get("enableGlobalCache"))if(this.immutable){if(!await T.existsPromise(this.cwd))throw new nt(z.IMMUTABLE_CACHE,"Cache path does not exist.")}else{await T.mkdirPromise(this.cwd,{recursive:!0});let e=v.resolve(this.cwd,".gitignore");await T.changeFilePromise(e,`/.gitignore -*.flock -*.tmp -`)}(this.mirrorCwd||!this.immutable)&&await T.mkdirPromise(this.mirrorCwd||this.cwd,{recursive:!0})}async fetchPackageFromCache(e,r,a){var l=a,{onHit:i,onMiss:n,loader:s}=l,o=qr(l,["onHit","onMiss","loader"]);var A;let c=this.getLocatorMirrorPath(e),u=new Wt,g=()=>{let V=new Jr(null,{libzip:H}),W=v.join(Se.root,Lx(e));return V.mkdirSync(W,{recursive:!0}),V.writeJsonSync(v.join(W,wt.manifest),{name:St(e),mocked:!0}),V},f=async(V,W=null)=>{let X=!o.skipIntegrityCheck||!r?`${this.cacheKey}/${await Ey(V)}`:r;if(W!==null){let F=!o.skipIntegrityCheck||!r?`${this.cacheKey}/${await Ey(W)}`:r;if(X!==F)throw new nt(z.CACHE_CHECKSUM_MISMATCH,"The remote archive doesn't match the local checksum - has the local cache been corrupted?")}if(r!==null&&X!==r){let F;switch(this.check?F="throw":QR(r)!==QR(X)?F="update":F=this.configuration.get("checksumBehavior"),F){case"ignore":return r;case"update":return X;default:case"throw":throw new nt(z.CACHE_CHECKSUM_MISMATCH,"The remote archive doesn't match the expected checksum")}}return X},h=async V=>{if(!s)throw new Error(`Cache check required but no loader configured for ${lt(this.configuration,e)}`);let W=await s(),X=W.getRealPath();return W.saveAndClose(),await T.chmodPromise(X,420),await f(V,X)},p=async()=>{if(c===null||!await T.existsPromise(c)){let V=await s(),W=V.getRealPath();return V.saveAndClose(),{source:"loader",path:W}}return{source:"mirror",path:c}},d=async()=>{if(!s)throw new Error(`Cache entry required but missing for ${lt(this.configuration,e)}`);if(this.immutable)throw new nt(z.IMMUTABLE_CACHE,`Cache entry required but missing for ${lt(this.configuration,e)}`);let{path:V,source:W}=await p(),X=await f(V),F=this.getLocatorPath(e,X,o);if(!F)throw new Error("Assertion failed: Expected the cache path to be available");let D=[];W!=="mirror"&&c!==null&&D.push(async()=>{let pe=`${c}${this.cacheId}`;await T.copyFilePromise(V,pe,BR.default.constants.COPYFILE_FICLONE),await T.chmodPromise(pe,420),await T.renamePromise(pe,c)}),(!o.mirrorWriteOnly||c===null)&&D.push(async()=>{let pe=`${F}${this.cacheId}`;await T.copyFilePromise(V,pe,BR.default.constants.COPYFILE_FICLONE),await T.chmodPromise(pe,420),await T.renamePromise(pe,F)});let he=o.mirrorWriteOnly&&c!=null?c:F;return await Promise.all(D.map(pe=>pe())),[!1,he,X]},m=async()=>{let W=(async()=>{var Ne;let X=this.getLocatorPath(e,r,o),F=X!==null?await u.existsPromise(X):!1,D=!!((Ne=o.mockedPackages)==null?void 0:Ne.has(e.locatorHash))&&(!this.check||!F),he=D||F,pe=he?i:n;if(pe&&pe(),he){let Pe=null,qe=X;return D||(Pe=this.check?await h(qe):await f(qe)),[D,qe,Pe]}else return d()})();this.mutexes.set(e.locatorHash,W);try{return await W}finally{this.mutexes.delete(e.locatorHash)}};for(let V;V=this.mutexes.get(e.locatorHash);)await V;let[I,B,b]=await m();this.markedFiles.add(B);let R,H=await $i(),L=I?()=>g():()=>new Jr(B,{baseFs:u,libzip:H,readOnly:!0}),K=new oh(()=>Mv(()=>R=L(),V=>`Failed to open the cache entry for ${lt(this.configuration,e)}: ${V}`),v),J=new Xo(B,{baseFs:K,pathUtils:v}),ne=()=>{R==null||R.discardAndClose()},q=((A=o.unstablePackages)==null?void 0:A.has(e.locatorHash))?null:b;return[J,ne,q]}};function QR(t){let e=t.indexOf("/");return e!==-1?t.slice(0,e):null}function hTe(t){let e=t.indexOf("/");return e!==-1?t.slice(e+1):t}var F_=ie(x_()),NB=ie(ml());var N_=ie(Wp()),kR=ie(require("stream"));var k_={hooks:{reduceDependency:(t,e,r,i,{resolver:n,resolveOptions:s})=>{for(let{pattern:o,reference:a}of e.topLevelWorkspace.manifest.resolutions){if(o.from&&o.from.fullName!==St(r)||o.from&&o.from.description&&o.from.description!==r.reference||o.descriptor.fullName!==St(t)||o.descriptor.description&&o.descriptor.description!==t.range)continue;return n.bindDescriptor(Yt(t,a),e.topLevelWorkspace.anchoredLocator,s)}return t},validateProject:async(t,e)=>{for(let r of t.workspaces){let i=hp(t.configuration,r);await t.configuration.triggerHook(n=>n.validateWorkspace,r,{reportWarning:(n,s)=>e.reportWarning(n,`${i}: ${s}`),reportError:(n,s)=>e.reportError(n,`${i}: ${s}`)})}},validateWorkspace:async(t,e)=>{let{manifest:r}=t;r.resolutions.length&&t.cwd!==t.project.cwd&&r.errors.push(new Error("Resolutions field will be ignored"));for(let i of r.errors)e.reportWarning(z.INVALID_MANIFEST,i.message)}}};var vR=class{constructor(e){this.fetchers=e}supports(e,r){return!!this.tryFetcher(e,r)}getLocalPath(e,r){return this.getFetcher(e,r).getLocalPath(e,r)}async fetch(e,r){return await this.getFetcher(e,r).fetch(e,r)}tryFetcher(e,r){let i=this.fetchers.find(n=>n.supports(e,r));return i||null}getFetcher(e,r){let i=this.fetchers.find(n=>n.supports(e,r));if(!i)throw new nt(z.FETCHER_NOT_FOUND,`${lt(r.project.configuration,e)} isn't supported by any available fetcher`);return i}};var pd=class{constructor(e){this.resolvers=e.filter(r=>r)}supportsDescriptor(e,r){return!!this.tryResolverByDescriptor(e,r)}supportsLocator(e,r){return!!this.tryResolverByLocator(e,r)}shouldPersistResolution(e,r){return this.getResolverByLocator(e,r).shouldPersistResolution(e,r)}bindDescriptor(e,r,i){return this.getResolverByDescriptor(e,i).bindDescriptor(e,r,i)}getResolutionDependencies(e,r){return this.getResolverByDescriptor(e,r).getResolutionDependencies(e,r)}async getCandidates(e,r,i){return await this.getResolverByDescriptor(e,i).getCandidates(e,r,i)}async getSatisfying(e,r,i){return this.getResolverByDescriptor(e,i).getSatisfying(e,r,i)}async resolve(e,r){return await this.getResolverByLocator(e,r).resolve(e,r)}tryResolverByDescriptor(e,r){let i=this.resolvers.find(n=>n.supportsDescriptor(e,r));return i||null}getResolverByDescriptor(e,r){let i=this.resolvers.find(n=>n.supportsDescriptor(e,r));if(!i)throw new Error(`${Xt(r.project.configuration,e)} isn't supported by any available resolver`);return i}tryResolverByLocator(e,r){let i=this.resolvers.find(n=>n.supportsLocator(e,r));return i||null}getResolverByLocator(e,r){let i=this.resolvers.find(n=>n.supportsLocator(e,r));if(!i)throw new Error(`${lt(r.project.configuration,e)} isn't supported by any available resolver`);return i}};var P_=ie(Or());var Rg=/^(?!v)[a-z0-9._-]+$/i,SR=class{supportsDescriptor(e,r){return!!(Us(e.range)||Rg.test(e.range))}supportsLocator(e,r){return!!(P_.default.valid(e.reference)||Rg.test(e.reference))}shouldPersistResolution(e,r){return r.resolver.shouldPersistResolution(this.forwardLocator(e,r),r)}bindDescriptor(e,r,i){return i.resolver.bindDescriptor(this.forwardDescriptor(e,i),r,i)}getResolutionDependencies(e,r){return r.resolver.getResolutionDependencies(this.forwardDescriptor(e,r),r)}async getCandidates(e,r,i){return await i.resolver.getCandidates(this.forwardDescriptor(e,i),r,i)}async getSatisfying(e,r,i){return await i.resolver.getSatisfying(this.forwardDescriptor(e,i),r,i)}async resolve(e,r){let i=await r.resolver.resolve(this.forwardLocator(e,r),r);return op(i,e)}forwardDescriptor(e,r){return Yt(e,`${r.project.configuration.get("defaultProtocol")}${e.range}`)}forwardLocator(e,r){return Vi(e,`${r.project.configuration.get("defaultProtocol")}${e.reference}`)}};var dd=class{supports(e){return!!e.reference.startsWith("virtual:")}getLocalPath(e,r){let i=e.reference.indexOf("#");if(i===-1)throw new Error("Invalid virtual package reference");let n=e.reference.slice(i+1),s=Vi(e,n);return r.fetcher.getLocalPath(s,r)}async fetch(e,r){let i=e.reference.indexOf("#");if(i===-1)throw new Error("Invalid virtual package reference");let n=e.reference.slice(i+1),s=Vi(e,n),o=await r.fetcher.fetch(s,r);return await this.ensureVirtualLink(e,o,r)}getLocatorFilename(e){return Mu(e)}async ensureVirtualLink(e,r,i){let n=r.packageFs.getRealPath(),s=i.project.configuration.get("virtualFolder"),o=this.getLocatorFilename(e),a=Pr.makeVirtualPath(s,o,n),l=new Xo(a,{baseFs:r.packageFs,pathUtils:v});return _(P({},r),{packageFs:l})}};var Fg=class{static isVirtualDescriptor(e){return!!e.range.startsWith(Fg.protocol)}static isVirtualLocator(e){return!!e.reference.startsWith(Fg.protocol)}supportsDescriptor(e,r){return Fg.isVirtualDescriptor(e)}supportsLocator(e,r){return Fg.isVirtualLocator(e)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){throw new Error('Assertion failed: calling "bindDescriptor" on a virtual descriptor is unsupported')}getResolutionDependencies(e,r){throw new Error('Assertion failed: calling "getResolutionDependencies" on a virtual descriptor is unsupported')}async getCandidates(e,r,i){throw new Error('Assertion failed: calling "getCandidates" on a virtual descriptor is unsupported')}async getSatisfying(e,r,i){throw new Error('Assertion failed: calling "getSatisfying" on a virtual descriptor is unsupported')}async resolve(e,r){throw new Error('Assertion failed: calling "resolve" on a virtual locator is unsupported')}},FB=Fg;FB.protocol="virtual:";var xR=class{supports(e){return!!e.reference.startsWith(Yr.protocol)}getLocalPath(e,r){return this.getWorkspace(e,r).cwd}async fetch(e,r){let i=this.getWorkspace(e,r).cwd;return{packageFs:new Ft(i),prefixPath:Se.dot,localPath:i}}getWorkspace(e,r){return r.project.getWorkspaceByCwd(e.reference.slice(Yr.protocol.length))}};var D_=ie(require("module"));function R_(){return new Set(D_.default.builtinModules||Object.keys(process.binding("natives")))}var dTe=new Set(["binFolder","version","flags","profile","gpg","ignoreNode","wrapOutput","home","confDir"]),LB="yarn_",PR=".yarnrc.yml",DR="yarn.lock",CTe="********",ge;(function(u){u.ANY="ANY",u.BOOLEAN="BOOLEAN",u.ABSOLUTE_PATH="ABSOLUTE_PATH",u.LOCATOR="LOCATOR",u.LOCATOR_LOOSE="LOCATOR_LOOSE",u.NUMBER="NUMBER",u.STRING="STRING",u.SECRET="SECRET",u.SHAPE="SHAPE",u.MAP="MAP"})(ge||(ge={}));var ps=Le,RR={lastUpdateCheck:{description:"Last timestamp we checked whether new Yarn versions were available",type:ge.STRING,default:null},yarnPath:{description:"Path to the local executable that must be used over the global one",type:ge.ABSOLUTE_PATH,default:null},ignorePath:{description:"If true, the local executable will be ignored when using the global one",type:ge.BOOLEAN,default:!1},ignoreCwd:{description:"If true, the `--cwd` flag will be ignored",type:ge.BOOLEAN,default:!1},cacheKeyOverride:{description:"A global cache key override; used only for test purposes",type:ge.STRING,default:null},globalFolder:{description:"Folder where are stored the system-wide settings",type:ge.ABSOLUTE_PATH,default:Rb()},cacheFolder:{description:"Folder where the cache files must be written",type:ge.ABSOLUTE_PATH,default:"./.yarn/cache"},compressionLevel:{description:"Zip files compression level, from 0 to 9 or mixed (a variant of 9, which stores some files uncompressed, when compression doesn't yield good results)",type:ge.NUMBER,values:["mixed",0,1,2,3,4,5,6,7,8,9],default:pl},virtualFolder:{description:"Folder where the virtual packages (cf doc) will be mapped on the disk (must be named __virtual__)",type:ge.ABSOLUTE_PATH,default:"./.yarn/__virtual__"},lockfileFilename:{description:"Name of the files where the Yarn dependency tree entries must be stored",type:ge.STRING,default:DR},installStatePath:{description:"Path of the file where the install state will be persisted",type:ge.ABSOLUTE_PATH,default:"./.yarn/install-state.gz"},immutablePatterns:{description:"Array of glob patterns; files matching them won't be allowed to change during immutable installs",type:ge.STRING,default:[],isArray:!0},rcFilename:{description:"Name of the files where the configuration can be found",type:ge.STRING,default:TB()},enableGlobalCache:{description:"If true, the system-wide cache folder will be used regardless of `cache-folder`",type:ge.BOOLEAN,default:!1},enableColors:{description:"If true, the CLI is allowed to use colors in its output",type:ge.BOOLEAN,default:xy,defaultText:""},enableHyperlinks:{description:"If true, the CLI is allowed to use hyperlinks in its output",type:ge.BOOLEAN,default:Mx,defaultText:""},enableInlineBuilds:{description:"If true, the CLI will print the build output on the command line",type:ge.BOOLEAN,default:NB.isCI,defaultText:""},enableMessageNames:{description:"If true, the CLI will prefix most messages with codes suitable for search engines",type:ge.BOOLEAN,default:!0},enableProgressBars:{description:"If true, the CLI is allowed to show a progress bar for long-running events",type:ge.BOOLEAN,default:!NB.isCI&&process.stdout.isTTY&&process.stdout.columns>22,defaultText:""},enableTimers:{description:"If true, the CLI is allowed to print the time spent executing commands",type:ge.BOOLEAN,default:!0},preferAggregateCacheInfo:{description:"If true, the CLI will only print a one-line report of any cache changes",type:ge.BOOLEAN,default:NB.isCI},preferInteractive:{description:"If true, the CLI will automatically use the interactive mode when called from a TTY",type:ge.BOOLEAN,default:!1},preferTruncatedLines:{description:"If true, the CLI will truncate lines that would go beyond the size of the terminal",type:ge.BOOLEAN,default:!1},progressBarStyle:{description:"Which style of progress bar should be used (only when progress bars are enabled)",type:ge.STRING,default:void 0,defaultText:""},defaultLanguageName:{description:"Default language mode that should be used when a package doesn't offer any insight",type:ge.STRING,default:"node"},defaultProtocol:{description:"Default resolution protocol used when resolving pure semver and tag ranges",type:ge.STRING,default:"npm:"},enableTransparentWorkspaces:{description:"If false, Yarn won't automatically resolve workspace dependencies unless they use the `workspace:` protocol",type:ge.BOOLEAN,default:!0},supportedArchitectures:{description:"Architectures that Yarn will fetch and inject into the resolver",type:ge.SHAPE,properties:{os:{description:"Array of supported process.platform strings, or null to target them all",type:ge.STRING,isArray:!0,isNullable:!0,default:["current"]},cpu:{description:"Array of supported process.arch strings, or null to target them all",type:ge.STRING,isArray:!0,isNullable:!0,default:["current"]}}},enableMirror:{description:"If true, the downloaded packages will be retrieved and stored in both the local and global folders",type:ge.BOOLEAN,default:!0},enableNetwork:{description:"If false, the package manager will refuse to use the network if required to",type:ge.BOOLEAN,default:!0},httpProxy:{description:"URL of the http proxy that must be used for outgoing http requests",type:ge.STRING,default:null},httpsProxy:{description:"URL of the http proxy that must be used for outgoing https requests",type:ge.STRING,default:null},unsafeHttpWhitelist:{description:"List of the hostnames for which http queries are allowed (glob patterns are supported)",type:ge.STRING,default:[],isArray:!0},httpTimeout:{description:"Timeout of each http request in milliseconds",type:ge.NUMBER,default:6e4},httpRetry:{description:"Retry times on http failure",type:ge.NUMBER,default:3},networkConcurrency:{description:"Maximal number of concurrent requests",type:ge.NUMBER,default:50},networkSettings:{description:"Network settings per hostname (glob patterns are supported)",type:ge.MAP,valueDefinition:{description:"",type:ge.SHAPE,properties:{caFilePath:{description:"Path to file containing one or multiple Certificate Authority signing certificates",type:ge.ABSOLUTE_PATH,default:null},enableNetwork:{description:"If false, the package manager will refuse to use the network if required to",type:ge.BOOLEAN,default:null},httpProxy:{description:"URL of the http proxy that must be used for outgoing http requests",type:ge.STRING,default:null},httpsProxy:{description:"URL of the http proxy that must be used for outgoing https requests",type:ge.STRING,default:null}}}},caFilePath:{description:"A path to a file containing one or multiple Certificate Authority signing certificates",type:ge.ABSOLUTE_PATH,default:null},enableStrictSsl:{description:"If false, SSL certificate errors will be ignored",type:ge.BOOLEAN,default:!0},logFilters:{description:"Overrides for log levels",type:ge.SHAPE,isArray:!0,concatenateValues:!0,properties:{code:{description:"Code of the messages covered by this override",type:ge.STRING,default:void 0},text:{description:"Code of the texts covered by this override",type:ge.STRING,default:void 0},pattern:{description:"Code of the patterns covered by this override",type:ge.STRING,default:void 0},level:{description:"Log level override, set to null to remove override",type:ge.STRING,values:Object.values(Ts),isNullable:!0,default:void 0}}},enableTelemetry:{description:"If true, telemetry will be periodically sent, following the rules in https://yarnpkg.com/advanced/telemetry",type:ge.BOOLEAN,default:!0},telemetryInterval:{description:"Minimal amount of time between two telemetry uploads, in days",type:ge.NUMBER,default:7},telemetryUserId:{description:"If you desire to tell us which project you are, you can set this field. Completely optional and opt-in.",type:ge.STRING,default:null},enableScripts:{description:"If true, packages are allowed to have install scripts by default",type:ge.BOOLEAN,default:!0},enableStrictSettings:{description:"If true, unknown settings will cause Yarn to abort",type:ge.BOOLEAN,default:!0},enableImmutableCache:{description:"If true, the cache is reputed immutable and actions that would modify it will throw",type:ge.BOOLEAN,default:!1},checksumBehavior:{description:"Enumeration defining what to do when a checksum doesn't match expectations",type:ge.STRING,default:"throw"},packageExtensions:{description:"Map of package corrections to apply on the dependency tree",type:ge.MAP,valueDefinition:{description:"The extension that will be applied to any package whose version matches the specified range",type:ge.SHAPE,properties:{dependencies:{description:"The set of dependencies that must be made available to the current package in order for it to work properly",type:ge.MAP,valueDefinition:{description:"A range",type:ge.STRING}},peerDependencies:{description:"Inherited dependencies - the consumer of the package will be tasked to provide them",type:ge.MAP,valueDefinition:{description:"A semver range",type:ge.STRING}},peerDependenciesMeta:{description:"Extra information related to the dependencies listed in the peerDependencies field",type:ge.MAP,valueDefinition:{description:"The peerDependency meta",type:ge.SHAPE,properties:{optional:{description:"If true, the selected peer dependency will be marked as optional by the package manager and the consumer omitting it won't be reported as an error",type:ge.BOOLEAN,default:!1}}}}}}}};function NR(t,e,r,i,n){if(i.isArray||i.type===ge.ANY&&Array.isArray(r))return Array.isArray(r)?r.map((s,o)=>FR(t,`${e}[${o}]`,s,i,n)):String(r).split(/,/).map(s=>FR(t,e,s,i,n));if(Array.isArray(r))throw new Error(`Non-array configuration settings "${e}" cannot be an array`);return FR(t,e,r,i,n)}function FR(t,e,r,i,n){var a;switch(i.type){case ge.ANY:return r;case ge.SHAPE:return mTe(t,e,r,i,n);case ge.MAP:return ETe(t,e,r,i,n)}if(r===null&&!i.isNullable&&i.default!==null)throw new Error(`Non-nullable configuration settings "${e}" cannot be set to null`);if((a=i.values)==null?void 0:a.includes(r))return r;let o=(()=>{if(i.type===ge.BOOLEAN&&typeof r!="string")return Hh(r);if(typeof r!="string")throw new Error(`Expected value (${r}) to be a string`);let l=Ov(r,{env:process.env});switch(i.type){case ge.ABSOLUTE_PATH:return v.resolve(n,M.toPortablePath(l));case ge.LOCATOR_LOOSE:return Hl(l,!1);case ge.NUMBER:return parseInt(l);case ge.LOCATOR:return Hl(l);case ge.BOOLEAN:return Hh(l);default:return l}})();if(i.values&&!i.values.includes(o))throw new Error(`Invalid value, expected one of ${i.values.join(", ")}`);return o}function mTe(t,e,r,i,n){if(typeof r!="object"||Array.isArray(r))throw new me(`Object configuration settings "${e}" must be an object`);let s=LR(t,i,{ignoreArrays:!0});if(r===null)return s;for(let[o,a]of Object.entries(r)){let l=`${e}.${o}`;if(!i.properties[o])throw new me(`Unrecognized configuration settings found: ${e}.${o} - run "yarn config -v" to see the list of settings supported in Yarn`);s.set(o,NR(t,l,a,i.properties[o],n))}return s}function ETe(t,e,r,i,n){let s=new Map;if(typeof r!="object"||Array.isArray(r))throw new me(`Map configuration settings "${e}" must be an object`);if(r===null)return s;for(let[o,a]of Object.entries(r)){let l=i.normalizeKeys?i.normalizeKeys(o):o,c=`${e}['${l}']`,u=i.valueDefinition;s.set(l,NR(t,c,a,u,n))}return s}function LR(t,e,{ignoreArrays:r=!1}={}){switch(e.type){case ge.SHAPE:{if(e.isArray&&!r)return[];let i=new Map;for(let[n,s]of Object.entries(e.properties))i.set(n,LR(t,s));return i}break;case ge.MAP:return e.isArray&&!r?[]:new Map;case ge.ABSOLUTE_PATH:return e.default===null?null:t.projectCwd===null?v.isAbsolute(e.default)?v.normalize(e.default):e.isNullable?null:void 0:Array.isArray(e.default)?e.default.map(i=>v.resolve(t.projectCwd,i)):v.resolve(t.projectCwd,e.default);default:return e.default}}function MB(t,e,r){if(e.type===ge.SECRET&&typeof t=="string"&&r.hideSecrets)return CTe;if(e.type===ge.ABSOLUTE_PATH&&typeof t=="string"&&r.getNativePaths)return M.fromPortablePath(t);if(e.isArray&&Array.isArray(t)){let i=[];for(let n of t)i.push(MB(n,e,r));return i}if(e.type===ge.MAP&&t instanceof Map){let i=new Map;for(let[n,s]of t.entries())i.set(n,MB(s,e.valueDefinition,r));return i}if(e.type===ge.SHAPE&&t instanceof Map){let i=new Map;for(let[n,s]of t.entries()){let o=e.properties[n];i.set(n,MB(s,o,r))}return i}return t}function ITe(){let t={};for(let[e,r]of Object.entries(process.env))e=e.toLowerCase(),!!e.startsWith(LB)&&(e=(0,F_.default)(e.slice(LB.length)),t[e]=r);return t}function TB(){let t=`${LB}rc_filename`;for(let[e,r]of Object.entries(process.env))if(e.toLowerCase()===t&&typeof r=="string")return r;return PR}var KA;(function(i){i[i.LOCKFILE=0]="LOCKFILE",i[i.MANIFEST=1]="MANIFEST",i[i.NONE=2]="NONE"})(KA||(KA={}));var Ra=class{constructor(e){this.projectCwd=null;this.plugins=new Map;this.settings=new Map;this.values=new Map;this.sources=new Map;this.invalid=new Map;this.packageExtensions=new Map;this.limits=new Map;this.startingCwd=e}static create(e,r,i){let n=new Ra(e);typeof r!="undefined"&&!(r instanceof Map)&&(n.projectCwd=r),n.importSettings(RR);let s=typeof i!="undefined"?i:r instanceof Map?r:new Map;for(let[o,a]of s)n.activatePlugin(o,a);return n}static async find(e,r,{lookup:i=0,strict:n=!0,usePath:s=!1,useRc:o=!0}={}){let a=ITe();delete a.rcFilename;let l=await Ra.findRcFiles(e),c=await Ra.findHomeRcFile();if(c){let I=l.find(B=>B.path===c.path);I?I.strict=!1:l.push(_(P({},c),{strict:!1}))}let u=({ignoreCwd:I,yarnPath:B,ignorePath:b,lockfileFilename:R})=>({ignoreCwd:I,yarnPath:B,ignorePath:b,lockfileFilename:R}),g=L=>{var K=L,{ignoreCwd:I,yarnPath:B,ignorePath:b,lockfileFilename:R}=K,H=qr(K,["ignoreCwd","yarnPath","ignorePath","lockfileFilename"]);return H},f=new Ra(e);f.importSettings(u(RR)),f.useWithSource("",u(a),e,{strict:!1});for(let{path:I,cwd:B,data:b}of l)f.useWithSource(I,u(b),B,{strict:!1});if(s){let I=f.get("yarnPath"),B=f.get("ignorePath");if(I!==null&&!B)return f}let h=f.get("lockfileFilename"),p;switch(i){case 0:p=await Ra.findProjectCwd(e,h);break;case 1:p=await Ra.findProjectCwd(e,null);break;case 2:T.existsSync(v.join(e,"package.json"))?p=v.resolve(e):p=null;break}f.startingCwd=e,f.projectCwd=p,f.importSettings(g(RR));let d=new Map([["@@core",k_]]),m=I=>"default"in I?I.default:I;if(r!==null){for(let R of r.plugins.keys())d.set(R,m(r.modules.get(R)));let I=new Map;for(let R of R_())I.set(R,()=>mu(R));for(let[R,H]of r.modules)I.set(R,()=>H);let B=new Set,b=async(R,H)=>{let{factory:L,name:K}=mu(R);if(B.has(K))return;let J=new Map(I),ne=A=>{if(J.has(A))return J.get(A)();throw new me(`This plugin cannot access the package referenced via ${A} which is neither a builtin, nor an exposed entry`)},q=await du(async()=>m(await L(ne)),A=>`${A} (when initializing ${K}, defined in ${H})`);I.set(K,()=>q),B.add(K),d.set(K,q)};if(a.plugins)for(let R of a.plugins.split(";")){let H=v.resolve(e,M.toPortablePath(R));await b(H,"")}for(let{path:R,cwd:H,data:L}of l)if(!!o&&!!Array.isArray(L.plugins))for(let K of L.plugins){let J=typeof K!="string"?K.path:K,ne=v.resolve(H,M.toPortablePath(J));await b(ne,R)}}for(let[I,B]of d)f.activatePlugin(I,B);f.useWithSource("",g(a),e,{strict:n});for(let{path:I,cwd:B,data:b,strict:R}of l)f.useWithSource(I,g(b),B,{strict:R!=null?R:n});return f.get("enableGlobalCache")&&(f.values.set("cacheFolder",`${f.get("globalFolder")}/cache`),f.sources.set("cacheFolder","")),await f.refreshPackageExtensions(),f}static async findRcFiles(e){let r=TB(),i=[],n=e,s=null;for(;n!==s;){s=n;let o=v.join(s,r);if(T.existsSync(o)){let a=await T.readFilePromise(o,"utf8"),l;try{l=Ii(a)}catch(c){let u="";throw a.match(/^\s+(?!-)[^:]+\s+\S+/m)&&(u=" (in particular, make sure you list the colons after each key name)"),new me(`Parse error when loading ${o}; please check it's proper Yaml${u}`)}i.push({path:o,cwd:s,data:l})}n=v.dirname(s)}return i}static async findHomeRcFile(){let e=TB(),r=uh(),i=v.join(r,e);if(T.existsSync(i)){let n=await T.readFilePromise(i,"utf8"),s=Ii(n);return{path:i,cwd:r,data:s}}return null}static async findProjectCwd(e,r){let i=null,n=e,s=null;for(;n!==s;){if(s=n,T.existsSync(v.join(s,"package.json"))&&(i=s),r!==null){if(T.existsSync(v.join(s,r))){i=s;break}}else if(i!==null)break;n=v.dirname(s)}return i}static async updateConfiguration(e,r){let i=TB(),n=v.join(e,i),s=T.existsSync(n)?Ii(await T.readFilePromise(n,"utf8")):{},o=!1,a;if(typeof r=="function"){try{a=r(s)}catch{a=r({})}if(a===s)return}else{a=s;for(let l of Object.keys(r)){let c=s[l],u=r[l],g;if(typeof u=="function")try{g=u(c)}catch{g=u(void 0)}else g=u;c!==g&&(a[l]=g,o=!0)}if(!o)return}await T.changeFilePromise(n,Qa(a),{automaticNewlines:!0})}static async updateHomeConfiguration(e){let r=uh();return await Ra.updateConfiguration(r,e)}activatePlugin(e,r){this.plugins.set(e,r),typeof r.configuration!="undefined"&&this.importSettings(r.configuration)}importSettings(e){for(let[r,i]of Object.entries(e))if(i!=null){if(this.settings.has(r))throw new Error(`Cannot redefine settings "${r}"`);this.settings.set(r,i),this.values.set(r,LR(this,i))}}useWithSource(e,r,i,n){try{this.use(e,r,i,n)}catch(s){throw s.message+=` (in ${Ve(this,e,Le.PATH)})`,s}}use(e,r,i,{strict:n=!0,overwrite:s=!1}={}){n=n&&this.get("enableStrictSettings");for(let o of["enableStrictSettings",...Object.keys(r)]){if(typeof r[o]=="undefined"||o==="plugins"||e===""&&dTe.has(o))continue;if(o==="rcFilename")throw new me(`The rcFilename settings can only be set via ${`${LB}RC_FILENAME`.toUpperCase()}, not via a rc file`);let l=this.settings.get(o);if(!l){if(n)throw new me(`Unrecognized or legacy configuration settings found: ${o} - run "yarn config -v" to see the list of settings supported in Yarn`);this.invalid.set(o,e);continue}if(this.sources.has(o)&&!(s||l.type===ge.MAP||l.isArray&&l.concatenateValues))continue;let c;try{c=NR(this,o,r[o],l,i)}catch(u){throw u.message+=` in ${Ve(this,e,Le.PATH)}`,u}if(o==="enableStrictSettings"&&e!==""){n=c;continue}if(l.type===ge.MAP){let u=this.values.get(o);this.values.set(o,new Map(s?[...u,...c]:[...c,...u])),this.sources.set(o,`${this.sources.get(o)}, ${e}`)}else if(l.isArray&&l.concatenateValues){let u=this.values.get(o);this.values.set(o,s?[...u,...c]:[...c,...u]),this.sources.set(o,`${this.sources.get(o)}, ${e}`)}else this.values.set(o,c),this.sources.set(o,e)}}get(e){if(!this.values.has(e))throw new Error(`Invalid configuration key "${e}"`);return this.values.get(e)}getSpecial(e,{hideSecrets:r=!1,getNativePaths:i=!1}){let n=this.get(e),s=this.settings.get(e);if(typeof s=="undefined")throw new me(`Couldn't find a configuration settings named "${e}"`);return MB(n,s,{hideSecrets:r,getNativePaths:i})}getSubprocessStreams(e,{header:r,prefix:i,report:n}){let s,o,a=T.createWriteStream(e);if(this.get("enableInlineBuilds")){let l=n.createStreamReporter(`${i} ${Ve(this,"STDOUT","green")}`),c=n.createStreamReporter(`${i} ${Ve(this,"STDERR","red")}`);s=new kR.PassThrough,s.pipe(l),s.pipe(a),o=new kR.PassThrough,o.pipe(c),o.pipe(a)}else s=a,o=a,typeof r!="undefined"&&s.write(`${r} -`);return{stdout:s,stderr:o}}makeResolver(){let e=[];for(let r of this.plugins.values())for(let i of r.resolvers||[])e.push(new i);return new pd([new FB,new Yr,new SR,...e])}makeFetcher(){let e=[];for(let r of this.plugins.values())for(let i of r.fetchers||[])e.push(new i);return new vR([new dd,new xR,...e])}getLinkers(){let e=[];for(let r of this.plugins.values())for(let i of r.linkers||[])e.push(new i);return e}getSupportedArchitectures(){let e=this.get("supportedArchitectures"),r=e.get("os");r!==null&&(r=r.map(n=>n==="current"?process.platform:n));let i=e.get("cpu");return i!==null&&(i=i.map(n=>n==="current"?process.arch:n)),{os:r,cpu:i}}async refreshPackageExtensions(){this.packageExtensions=new Map;let e=this.packageExtensions,r=(i,n,{userProvided:s=!1}={})=>{if(!Us(i.range))throw new Error("Only semver ranges are allowed as keys for the packageExtensions setting");let o=new Ze;o.load(n,{yamlCompatibilityMode:!0});let a=hu(e,i.identHash),l=[];a.push([i.range,l]);let c={status:ki.Inactive,userProvided:s,parentDescriptor:i};for(let u of o.dependencies.values())l.push(_(P({},c),{type:oi.Dependency,descriptor:u}));for(let u of o.peerDependencies.values())l.push(_(P({},c),{type:oi.PeerDependency,descriptor:u}));for(let[u,g]of o.peerDependenciesMeta)for(let[f,h]of Object.entries(g))l.push(_(P({},c),{type:oi.PeerDependencyMeta,selector:u,key:f,value:h}))};await this.triggerHook(i=>i.registerPackageExtensions,this,r);for(let[i,n]of this.get("packageExtensions"))r(pA(i,!0),aI(n),{userProvided:!0})}normalizePackage(e){let r=ap(e);if(this.packageExtensions==null)throw new Error("refreshPackageExtensions has to be called before normalizing packages");let i=this.packageExtensions.get(e.identHash);if(typeof i!="undefined"){let s=e.version;if(s!==null){for(let[o,a]of i)if(!!lc(s,o))for(let l of a)switch(l.status===ki.Inactive&&(l.status=ki.Redundant),l.type){case oi.Dependency:typeof r.dependencies.get(l.descriptor.identHash)=="undefined"&&(l.status=ki.Active,r.dependencies.set(l.descriptor.identHash,l.descriptor));break;case oi.PeerDependency:typeof r.peerDependencies.get(l.descriptor.identHash)=="undefined"&&(l.status=ki.Active,r.peerDependencies.set(l.descriptor.identHash,l.descriptor));break;case oi.PeerDependencyMeta:{let c=r.peerDependenciesMeta.get(l.selector);(typeof c=="undefined"||!Object.prototype.hasOwnProperty.call(c,l.key)||c[l.key]!==l.value)&&(l.status=ki.Active,na(r.peerDependenciesMeta,l.selector,()=>({}))[l.key]=l.value)}break;default:Lv(l);break}}}let n=s=>s.scope?`${s.scope}__${s.name}`:`${s.name}`;for(let s of r.peerDependenciesMeta.keys()){let o=En(s);r.peerDependencies.has(o.identHash)||r.peerDependencies.set(o.identHash,Yt(o,"*"))}for(let s of r.peerDependencies.values()){if(s.scope==="types")continue;let o=n(s),a=Eo("types",o),l=St(a);r.peerDependencies.has(a.identHash)||r.peerDependenciesMeta.has(l)||(r.peerDependencies.set(a.identHash,Yt(a,"*")),r.peerDependenciesMeta.set(l,{optional:!0}))}return r.dependencies=new Map(gn(r.dependencies,([,s])=>In(s))),r.peerDependencies=new Map(gn(r.peerDependencies,([,s])=>In(s))),r}getLimit(e){return na(this.limits,e,()=>(0,N_.default)(this.get(e)))}async triggerHook(e,...r){for(let i of this.plugins.values()){let n=i.hooks;if(!n)continue;let s=e(n);!s||await s(...r)}}async triggerMultipleHooks(e,r){for(let i of r)await this.triggerHook(e,...i)}async reduceHook(e,r,...i){let n=r;for(let s of this.plugins.values()){let o=s.hooks;if(!o)continue;let a=e(o);!a||(n=await a(n,...i))}return n}async firstHook(e,...r){for(let i of this.plugins.values()){let n=i.hooks;if(!n)continue;let s=e(n);if(!s)continue;let o=await s(...r);if(typeof o!="undefined")return o}return null}},fe=Ra;fe.telemetry=null;var Gn;(function(r){r[r.SCRIPT=0]="SCRIPT",r[r.SHELLCODE=1]="SHELLCODE"})(Gn||(Gn={}));var Fa=class extends Xi{constructor({configuration:e,stdout:r,suggestInstall:i=!0}){super();this.errorCount=0;Cp(this,{configuration:e}),this.configuration=e,this.stdout=r,this.suggestInstall=i}static async start(e,r){let i=new this(e);try{await r(i)}catch(n){i.reportExceptionOnce(n)}finally{await i.finalize()}return i}hasErrors(){return this.errorCount>0}exitCode(){return this.hasErrors()?1:0}reportCacheHit(e){}reportCacheMiss(e){}startTimerSync(e,r,i){return(typeof r=="function"?r:i)()}async startTimerPromise(e,r,i){return await(typeof r=="function"?r:i)()}async startCacheReport(e){return await e()}reportSeparator(){}reportInfo(e,r){}reportWarning(e,r){}reportError(e,r){this.errorCount+=1,this.stdout.write(`${Ve(this.configuration,"\u27A4","redBright")} ${this.formatNameWithHyperlink(e)}: ${r} -`)}reportProgress(e){let r=Promise.resolve().then(async()=>{for await(let{}of e);}),i=()=>{};return _(P({},r),{stop:i})}reportJson(e){}async finalize(){this.errorCount>0&&(this.stdout.write(` -`),this.stdout.write(`${Ve(this.configuration,"\u27A4","redBright")} Errors happened when preparing the environment required to run this command. -`),this.suggestInstall&&this.stdout.write(`${Ve(this.configuration,"\u27A4","redBright")} This might be caused by packages being missing from the lockfile, in which case running "yarn install" might help. -`))}formatNameWithHyperlink(e){return eD(e,{configuration:this.configuration,json:!1})}};var t0=ie(require("crypto")),v$=ie(CX()),r0=ie(Q$()),S$=ie(Wp()),x$=ie(Or()),lF=ie(require("util")),cF=ie(require("v8")),uF=ie(require("zlib"));var iUe=[[/^(git(?:\+(?:https|ssh))?:\/\/.*(?:\.git)?)#(.*)$/,(t,e,r,i)=>`${r}#commit=${i}`],[/^https:\/\/((?:[^/]+?)@)?codeload\.github\.com\/([^/]+\/[^/]+)\/tar\.gz\/([0-9a-f]+)$/,(t,e,r="",i,n)=>`https://${r}github.com/${i}.git#commit=${n}`],[/^https:\/\/((?:[^/]+?)@)?github\.com\/([^/]+\/[^/]+?)(?:\.git)?#([0-9a-f]+)$/,(t,e,r="",i,n)=>`https://${r}github.com/${i}.git#commit=${n}`],[/^https?:\/\/[^/]+\/(?:[^/]+\/)*(?:@.+(?:\/|(?:%2f)))?([^/]+)\/(?:-|download)\/\1-[^/]+\.tgz(?:#|$)/,t=>`npm:${t}`],[/^https:\/\/npm\.pkg\.github\.com\/download\/(?:@[^/]+)\/(?:[^/]+)\/(?:[^/]+)\/(?:[0-9a-f]+)(?:#|$)/,t=>`npm:${t}`],[/^https:\/\/npm\.fontawesome\.com\/(?:@[^/]+)\/([^/]+)\/-\/([^/]+)\/\1-\2.tgz(?:#|$)/,t=>`npm:${t}`],[/^https?:\/\/(?:[^\\.]+)\.jfrog\.io\/.*\/(@[^/]+)\/([^/]+)\/-\/\1\/\2-(?:[.\d\w-]+)\.tgz(?:#|$)/,(t,e)=>by({protocol:"npm:",source:null,selector:t,params:{__archiveUrl:e}})],[/^[^/]+\.tgz#[0-9a-f]+$/,t=>`npm:${t}`]],oF=class{constructor(){this.resolutions=null}async setup(e,{report:r}){let i=v.join(e.cwd,e.configuration.get("lockfileFilename"));if(!T.existsSync(i))return;let n=await T.readFilePromise(i,"utf8"),s=Ii(n);if(Object.prototype.hasOwnProperty.call(s,"__metadata"))return;let o=this.resolutions=new Map;for(let a of Object.keys(s)){let l=gp(a);if(!l){r.reportWarning(z.YARN_IMPORT_FAILED,`Failed to parse the string "${a}" into a proper descriptor`);continue}Us(l.range)&&(l=Yt(l,`npm:${l.range}`));let{version:c,resolved:u}=s[a];if(!u)continue;let g;for(let[h,p]of iUe){let d=u.match(h);if(d){g=p(c,...d);break}}if(!g){r.reportWarning(z.YARN_IMPORT_FAILED,`${Xt(e.configuration,l)}: Only some patterns can be imported from legacy lockfiles (not "${u}")`);continue}let f=l;try{let h=Tu(l.range),p=gp(h.selector,!0);p&&(f=p)}catch{}o.set(l.descriptorHash,Vi(f,g))}}supportsDescriptor(e,r){return this.resolutions?this.resolutions.has(e.descriptorHash):!1}supportsLocator(e,r){return!1}shouldPersistResolution(e,r){throw new Error("Assertion failed: This resolver doesn't support resolving locators to packages")}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){if(!this.resolutions)throw new Error("Assertion failed: The resolution store should have been setup");let n=this.resolutions.get(e.descriptorHash);if(!n)throw new Error("Assertion failed: The resolution should have been registered");return[n]}async getSatisfying(e,r,i){return null}async resolve(e,r){throw new Error("Assertion failed: This resolver doesn't support resolving locators to packages")}};var aF=class{constructor(e){this.resolver=e}supportsDescriptor(e,r){return!!(r.project.storedResolutions.get(e.descriptorHash)||r.project.originalPackages.has(By(e).locatorHash))}supportsLocator(e,r){return!!(r.project.originalPackages.has(e.locatorHash)&&!r.project.lockfileNeedsRefresh)}shouldPersistResolution(e,r){throw new Error("The shouldPersistResolution method shouldn't be called on the lockfile resolver, which would always answer yes")}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return this.resolver.getResolutionDependencies(e,r)}async getCandidates(e,r,i){let n=i.project.originalPackages.get(By(e).locatorHash);if(n)return[n];let s=i.project.storedResolutions.get(e.descriptorHash);if(!s)throw new Error("Expected the resolution to have been successful - resolution not found");if(n=i.project.originalPackages.get(s),!n)throw new Error("Expected the resolution to have been successful - package not found");return[n]}async getSatisfying(e,r,i){return null}async resolve(e,r){let i=r.project.originalPackages.get(e.locatorHash);if(!i)throw new Error("The lockfile resolver isn't meant to resolve packages - they should already have been stored into a cache");return i}};var AF=class{constructor(e){this.resolver=e}supportsDescriptor(e,r){return this.resolver.supportsDescriptor(e,r)}supportsLocator(e,r){return this.resolver.supportsLocator(e,r)}shouldPersistResolution(e,r){return this.resolver.shouldPersistResolution(e,r)}bindDescriptor(e,r,i){return this.resolver.bindDescriptor(e,r,i)}getResolutionDependencies(e,r){return this.resolver.getResolutionDependencies(e,r)}async getCandidates(e,r,i){throw new nt(z.MISSING_LOCKFILE_ENTRY,`This package doesn't seem to be present in your lockfile; run "yarn install" to update the lockfile`)}async getSatisfying(e,r,i){throw new nt(z.MISSING_LOCKFILE_ENTRY,`This package doesn't seem to be present in your lockfile; run "yarn install" to update the lockfile`)}async resolve(e,r){throw new nt(z.MISSING_LOCKFILE_ENTRY,`This package doesn't seem to be present in your lockfile; run "yarn install" to update the lockfile`)}};var ei=class extends Xi{reportCacheHit(e){}reportCacheMiss(e){}startTimerSync(e,r,i){return(typeof r=="function"?r:i)()}async startTimerPromise(e,r,i){return await(typeof r=="function"?r:i)()}async startCacheReport(e){return await e()}reportSeparator(){}reportInfo(e,r){}reportWarning(e,r){}reportError(e,r){}reportProgress(e){let r=Promise.resolve().then(async()=>{for await(let{}of e);}),i=()=>{};return _(P({},r),{stop:i})}reportJson(e){}async finalize(){}};var b$=ie(vx());var Dd=class{constructor(e,{project:r}){this.workspacesCwds=new Set;this.dependencies=new Map;this.project=r,this.cwd=e}async setup(){this.manifest=T.existsSync(v.join(this.cwd,Ze.fileName))?await Ze.find(this.cwd):new Ze,this.relativeCwd=v.relative(this.project.cwd,this.cwd)||Se.dot;let e=this.manifest.name?this.manifest.name:Eo(null,`${this.computeCandidateName()}-${zi(this.relativeCwd).substr(0,6)}`),r=this.manifest.version?this.manifest.version:"0.0.0";this.locator=Vi(e,r),this.anchoredDescriptor=Yt(this.locator,`${Yr.protocol}${this.relativeCwd}`),this.anchoredLocator=Vi(this.locator,`${Yr.protocol}${this.relativeCwd}`);let i=this.manifest.workspaceDefinitions.map(({pattern:s})=>s),n=await(0,b$.default)(i,{cwd:M.fromPortablePath(this.cwd),expandDirectories:!1,onlyDirectories:!0,onlyFiles:!1,ignore:["**/node_modules","**/.git","**/.yarn"]});n.sort();for(let s of n){let o=v.resolve(this.cwd,M.toPortablePath(s));T.existsSync(v.join(o,"package.json"))&&this.workspacesCwds.add(o)}}accepts(e){var o;let r=e.indexOf(":"),i=r!==-1?e.slice(0,r+1):null,n=r!==-1?e.slice(r+1):e;if(i===Yr.protocol&&v.normalize(n)===this.relativeCwd||i===Yr.protocol&&(n==="*"||n==="^"||n==="~"))return!0;let s=Us(n);return s?i===Yr.protocol?s.test((o=this.manifest.version)!=null?o:"0.0.0"):this.project.configuration.get("enableTransparentWorkspaces")&&this.manifest.version!==null?s.test(this.manifest.version):!1:!1}computeCandidateName(){return this.cwd===this.project.cwd?"root-workspace":`${v.basename(this.cwd)}`||"unnamed-workspace"}getRecursiveWorkspaceDependencies({dependencies:e=Ze.hardDependencies}={}){let r=new Set,i=n=>{for(let s of e)for(let o of n.manifest[s].values()){let a=this.project.tryWorkspaceByDescriptor(o);a===null||r.has(a)||(r.add(a),i(a))}};return i(this),r}getRecursiveWorkspaceDependents({dependencies:e=Ze.hardDependencies}={}){let r=new Set,i=n=>{for(let s of this.project.workspaces)e.some(a=>[...s.manifest[a].values()].some(l=>{let c=this.project.tryWorkspaceByDescriptor(l);return c!==null&&up(c.anchoredLocator,n.anchoredLocator)}))&&!r.has(s)&&(r.add(s),i(s))};return i(this),r}getRecursiveWorkspaceChildren(){let e=[];for(let r of this.workspacesCwds){let i=this.project.workspacesByCwd.get(r);i&&e.push(i,...i.getRecursiveWorkspaceChildren())}return e}async persistManifest(){let e={};this.manifest.exportTo(e);let r=v.join(this.cwd,Ze.fileName),i=`${JSON.stringify(e,null,this.manifest.indent)} -`;await T.changeFilePromise(r,i,{automaticNewlines:!0}),this.manifest.raw=e}};var k$=5,nUe=1,sUe=/ *, */g,P$=/\/$/,oUe=32,aUe=(0,lF.promisify)(uF.default.gzip),AUe=(0,lF.promisify)(uF.default.gunzip),li;(function(r){r.UpdateLockfile="update-lockfile",r.SkipBuild="skip-build"})(li||(li={}));var gF={restoreInstallersCustomData:["installersCustomData"],restoreResolutions:["accessibleLocators","conditionalLocators","disabledLocators","optionalBuilds","storedDescriptors","storedResolutions","storedPackages","lockFileChecksum"],restoreBuildState:["storedBuildState"]},D$=t=>zi(`${nUe}`,t),Ke=class{constructor(e,{configuration:r}){this.resolutionAliases=new Map;this.workspaces=[];this.workspacesByCwd=new Map;this.workspacesByIdent=new Map;this.storedResolutions=new Map;this.storedDescriptors=new Map;this.storedPackages=new Map;this.storedChecksums=new Map;this.storedBuildState=new Map;this.accessibleLocators=new Set;this.conditionalLocators=new Set;this.disabledLocators=new Set;this.originalPackages=new Map;this.optionalBuilds=new Set;this.lockfileNeedsRefresh=!1;this.peerRequirements=new Map;this.installersCustomData=new Map;this.lockFileChecksum=null;this.installStateChecksum=null;this.configuration=r,this.cwd=e}static async find(e,r){var c,u,g;if(!e.projectCwd)throw new me(`No project found in ${r}`);let i=e.projectCwd,n=r,s=null;for(;s!==e.projectCwd;){if(s=n,T.existsSync(v.join(s,wt.manifest))){i=s;break}n=v.dirname(s)}let o=new Ke(e.projectCwd,{configuration:e});(c=fe.telemetry)==null||c.reportProject(o.cwd),await o.setupResolutions(),await o.setupWorkspaces(),(u=fe.telemetry)==null||u.reportWorkspaceCount(o.workspaces.length),(g=fe.telemetry)==null||g.reportDependencyCount(o.workspaces.reduce((f,h)=>f+h.manifest.dependencies.size+h.manifest.devDependencies.size,0));let a=o.tryWorkspaceByCwd(i);if(a)return{project:o,workspace:a,locator:a.anchoredLocator};let l=await o.findLocatorForLocation(`${i}/`,{strict:!0});if(l)return{project:o,locator:l,workspace:null};throw new me(`The nearest package directory (${Ve(e,i,Le.PATH)}) doesn't seem to be part of the project declared in ${Ve(e,o.cwd,Le.PATH)}. - -- If the project directory is right, it might be that you forgot to list ${Ve(e,v.relative(o.cwd,i),Le.PATH)} as a workspace. -- If it isn't, it's likely because you have a yarn.lock or package.json file there, confusing the project root detection.`)}async setupResolutions(){var i;this.storedResolutions=new Map,this.storedDescriptors=new Map,this.storedPackages=new Map,this.lockFileChecksum=null;let e=v.join(this.cwd,this.configuration.get("lockfileFilename")),r=this.configuration.get("defaultLanguageName");if(T.existsSync(e)){let n=await T.readFilePromise(e,"utf8");this.lockFileChecksum=D$(n);let s=Ii(n);if(s.__metadata){let o=s.__metadata.version,a=s.__metadata.cacheKey;this.lockfileNeedsRefresh=o0;){let r=e;e=[];for(let i of r){if(this.workspacesByCwd.has(i))continue;let n=await this.addWorkspace(i),s=this.storedPackages.get(n.anchoredLocator.locatorHash);s&&(n.dependencies=s.dependencies);for(let o of n.workspacesCwds)e.push(o)}}}async addWorkspace(e){let r=new Dd(e,{project:this});await r.setup();let i=this.workspacesByIdent.get(r.locator.identHash);if(typeof i!="undefined")throw new Error(`Duplicate workspace name ${Vr(this.configuration,r.locator)}: ${M.fromPortablePath(e)} conflicts with ${M.fromPortablePath(i.cwd)}`);return this.workspaces.push(r),this.workspacesByCwd.set(e,r),this.workspacesByIdent.set(r.locator.identHash,r),r}get topLevelWorkspace(){return this.getWorkspaceByCwd(this.cwd)}tryWorkspaceByCwd(e){v.isAbsolute(e)||(e=v.resolve(this.cwd,e)),e=v.normalize(e).replace(/\/+$/,"");let r=this.workspacesByCwd.get(e);return r||null}getWorkspaceByCwd(e){let r=this.tryWorkspaceByCwd(e);if(!r)throw new Error(`Workspace not found (${e})`);return r}tryWorkspaceByFilePath(e){let r=null;for(let i of this.workspaces)v.relative(i.cwd,e).startsWith("../")||r&&r.cwd.length>=i.cwd.length||(r=i);return r||null}getWorkspaceByFilePath(e){let r=this.tryWorkspaceByFilePath(e);if(!r)throw new Error(`Workspace not found (${e})`);return r}tryWorkspaceByIdent(e){let r=this.workspacesByIdent.get(e.identHash);return typeof r=="undefined"?null:r}getWorkspaceByIdent(e){let r=this.tryWorkspaceByIdent(e);if(!r)throw new Error(`Workspace not found (${Vr(this.configuration,e)})`);return r}tryWorkspaceByDescriptor(e){let r=this.tryWorkspaceByIdent(e);return r===null||(hA(e)&&(e=Ap(e)),!r.accepts(e.range))?null:r}getWorkspaceByDescriptor(e){let r=this.tryWorkspaceByDescriptor(e);if(r===null)throw new Error(`Workspace not found (${Xt(this.configuration,e)})`);return r}tryWorkspaceByLocator(e){let r=this.tryWorkspaceByIdent(e);return r===null||(Io(e)&&(e=lp(e)),r.locator.locatorHash!==e.locatorHash&&r.anchoredLocator.locatorHash!==e.locatorHash)?null:r}getWorkspaceByLocator(e){let r=this.tryWorkspaceByLocator(e);if(!r)throw new Error(`Workspace not found (${lt(this.configuration,e)})`);return r}refreshWorkspaceDependencies(){for(let e of this.workspaces){let r=this.storedPackages.get(e.anchoredLocator.locatorHash);if(!r)throw new Error(`Assertion failed: Expected workspace ${hp(this.configuration,e)} (${Ve(this.configuration,v.join(e.cwd,wt.manifest),Le.PATH)}) to have been resolved. Run "yarn install" to update the lockfile`);e.dependencies=new Map(r.dependencies)}}forgetResolution(e){let r=n=>{this.storedResolutions.delete(n),this.storedDescriptors.delete(n)},i=n=>{this.originalPackages.delete(n),this.storedPackages.delete(n),this.accessibleLocators.delete(n)};if("descriptorHash"in e){let n=this.storedResolutions.get(e.descriptorHash);r(e.descriptorHash);let s=new Set(this.storedResolutions.values());typeof n!="undefined"&&!s.has(n)&&i(n)}if("locatorHash"in e){i(e.locatorHash);for(let[n,s]of this.storedResolutions)s===e.locatorHash&&r(n)}}forgetTransientResolutions(){let e=this.configuration.makeResolver();for(let r of this.originalPackages.values()){let i;try{i=e.shouldPersistResolution(r,{project:this,resolver:e})}catch{i=!1}i||this.forgetResolution(r)}}forgetVirtualResolutions(){for(let e of this.storedPackages.values())for(let[r,i]of e.dependencies)hA(i)&&e.dependencies.set(r,Ap(i))}getDependencyMeta(e,r){let i={},s=this.topLevelWorkspace.manifest.dependenciesMeta.get(St(e));if(!s)return i;let o=s.get(null);if(o&&Object.assign(i,o),r===null||!x$.default.valid(r))return i;for(let[a,l]of s)a!==null&&a===r&&Object.assign(i,l);return i}async findLocatorForLocation(e,{strict:r=!1}={}){let i=new ei,n=this.configuration.getLinkers(),s={project:this,report:i};for(let o of n){let a=await o.findPackageLocator(e,s);if(a){if(r&&(await o.findPackageLocation(a,s)).replace(P$,"")!==e.replace(P$,""))continue;return a}}return null}async resolveEverything(e){if(!this.workspacesByCwd||!this.workspacesByIdent)throw new Error("Workspaces must have been setup before calling this function");this.forgetVirtualResolutions(),e.lockfileOnly||this.forgetTransientResolutions();let r=e.resolver||this.configuration.makeResolver(),i=new oF;await i.setup(this,{report:e.report});let n=e.lockfileOnly?[new AF(r)]:[i,r],s=new pd([new aF(r),...n]),o=this.configuration.makeFetcher(),a=e.lockfileOnly?{project:this,report:e.report,resolver:s}:{project:this,report:e.report,resolver:s,fetchOptions:{project:this,cache:e.cache,checksums:this.storedChecksums,report:e.report,fetcher:o,cacheOptions:{mirrorWriteOnly:!0}}},l=new Map,c=new Map,u=new Map,g=new Map,f=new Map,h=new Map,p=this.topLevelWorkspace.anchoredLocator,d=new Set,m=[],I=async W=>{let X=await du(async()=>await s.resolve(W,a),D=>`${lt(this.configuration,W)}: ${D}`);if(!up(W,X))throw new Error(`Assertion failed: The locator cannot be changed by the resolver (went from ${lt(this.configuration,W)} to ${lt(this.configuration,X)})`);g.set(X.locatorHash,X);let F=this.configuration.normalizePackage(X);for(let[D,he]of F.dependencies){let pe=await this.configuration.reduceHook(Pe=>Pe.reduceDependency,he,this,F,he,{resolver:s,resolveOptions:a});if(!cp(he,pe))throw new Error("Assertion failed: The descriptor ident cannot be changed through aliases");let Ne=s.bindDescriptor(pe,W,a);F.dependencies.set(D,Ne)}return m.push(Promise.all([...F.dependencies.values()].map(D=>H(D)))),c.set(F.locatorHash,F),F},B=async W=>{let X=f.get(W.locatorHash);if(typeof X!="undefined")return X;let F=Promise.resolve().then(()=>I(W));return f.set(W.locatorHash,F),F},b=async(W,X)=>{let F=await H(X);return l.set(W.descriptorHash,W),u.set(W.descriptorHash,F.locatorHash),F},R=async W=>{let X=this.resolutionAliases.get(W.descriptorHash);if(typeof X!="undefined")return b(W,this.storedDescriptors.get(X));let F=s.getResolutionDependencies(W,a),D=new Map(await Promise.all(F.map(async Ne=>{let Pe=s.bindDescriptor(Ne,p,a),qe=await H(Pe);return d.add(qe.locatorHash),[Ne.descriptorHash,qe]}))),pe=(await du(async()=>await s.getCandidates(W,D,a),Ne=>`${Xt(this.configuration,W)}: ${Ne}`))[0];if(typeof pe=="undefined")throw new Error(`${Xt(this.configuration,W)}: No candidates found`);return l.set(W.descriptorHash,W),u.set(W.descriptorHash,pe.locatorHash),B(pe)},H=W=>{let X=h.get(W.descriptorHash);if(typeof X!="undefined")return X;l.set(W.descriptorHash,W);let F=Promise.resolve().then(()=>R(W));return h.set(W.descriptorHash,F),F};for(let W of this.workspaces){let X=W.anchoredDescriptor;m.push(H(X))}for(;m.length>0;){let W=[...m];m.length=0,await Promise.all(W)}let L=new Set(this.resolutionAliases.values()),K=new Set(c.keys()),J=new Set,ne=new Map;lUe({project:this,report:e.report,accessibleLocators:J,volatileDescriptors:L,optionalBuilds:K,peerRequirements:ne,allDescriptors:l,allResolutions:u,allPackages:c});for(let W of d)K.delete(W);for(let W of L)l.delete(W),u.delete(W);let q=this.configuration.getSupportedArchitectures(),A=new Set,V=new Set;for(let W of c.values())W.conditions!=null&&(!K.has(W.locatorHash)||(Sy(W,q)||(Sy(W,{os:[process.platform],cpu:[process.arch]})&&e.report.reportWarningOnce(z.GHOST_ARCHITECTURE,`${lt(this.configuration,W)}: Your current architecture (${process.platform}-${process.arch}) is supported by this package, but is missing from the ${Ve(this.configuration,"supportedArchitectures",ps.SETTING)} setting`),V.add(W.locatorHash)),A.add(W.locatorHash)));this.storedResolutions=u,this.storedDescriptors=l,this.storedPackages=c,this.accessibleLocators=J,this.conditionalLocators=A,this.disabledLocators=V,this.originalPackages=g,this.optionalBuilds=K,this.peerRequirements=ne,this.refreshWorkspaceDependencies()}async fetchEverything({cache:e,report:r,fetcher:i,mode:n}){let s={mockedPackages:this.disabledLocators,unstablePackages:this.conditionalLocators},o=i||this.configuration.makeFetcher(),a={checksums:this.storedChecksums,project:this,cache:e,fetcher:o,report:r,cacheOptions:s},l=Array.from(new Set(gn(this.storedResolutions.values(),[f=>{let h=this.storedPackages.get(f);if(!h)throw new Error("Assertion failed: The locator should have been registered");return is(h)}])));n===li.UpdateLockfile&&(l=l.filter(f=>!this.storedChecksums.has(f)));let c=!1,u=Xi.progressViaCounter(l.length);r.reportProgress(u);let g=(0,S$.default)(oUe);if(await r.startCacheReport(async()=>{await Promise.all(l.map(f=>g(async()=>{let h=this.storedPackages.get(f);if(!h)throw new Error("Assertion failed: The locator should have been registered");if(Io(h))return;let p;try{p=await o.fetch(h,a)}catch(d){d.message=`${lt(this.configuration,h)}: ${d.message}`,r.reportExceptionOnce(d),c=d;return}p.checksum!=null?this.storedChecksums.set(h.locatorHash,p.checksum):this.storedChecksums.delete(h.locatorHash),p.releaseFs&&p.releaseFs()}).finally(()=>{u.tick()})))}),c)throw c}async linkEverything({cache:e,report:r,fetcher:i,mode:n}){var A,V,W;let s={mockedPackages:this.disabledLocators,unstablePackages:this.conditionalLocators,skipIntegrityCheck:!0},o=i||this.configuration.makeFetcher(),a={checksums:this.storedChecksums,project:this,cache:e,fetcher:o,report:r,skipIntegrityCheck:!0,cacheOptions:s},l=this.configuration.getLinkers(),c={project:this,report:r},u=new Map(l.map(X=>{let F=X.makeInstaller(c),D=F.getCustomDataKey(),he=this.installersCustomData.get(D);return typeof he!="undefined"&&F.attachCustomData(he),[X,F]})),g=new Map,f=new Map,h=new Map,p=new Map(await Promise.all([...this.accessibleLocators].map(async X=>{let F=this.storedPackages.get(X);if(!F)throw new Error("Assertion failed: The locator should have been registered");return[X,await o.fetch(F,a)]}))),d=[];for(let X of this.accessibleLocators){let F=this.storedPackages.get(X);if(typeof F=="undefined")throw new Error("Assertion failed: The locator should have been registered");let D=p.get(F.locatorHash);if(typeof D=="undefined")throw new Error("Assertion failed: The fetch result should have been registered");let he=[],pe=Pe=>{he.push(Pe)},Ne=this.tryWorkspaceByLocator(F);if(Ne!==null){let Pe=[],{scripts:qe}=Ne.manifest;for(let se of["preinstall","install","postinstall"])qe.has(se)&&Pe.push([Gn.SCRIPT,se]);try{for(let[se,be]of u)if(se.supportsPackage(F,c)&&(await be.installPackage(F,D,{holdFetchResult:pe})).buildDirective!==null)throw new Error("Assertion failed: Linkers can't return build directives for workspaces; this responsibility befalls to the Yarn core")}finally{he.length===0?(A=D.releaseFs)==null||A.call(D):d.push(Promise.all(he).catch(()=>{}).then(()=>{var se;(se=D.releaseFs)==null||se.call(D)}))}let re=v.join(D.packageFs.getRealPath(),D.prefixPath);f.set(F.locatorHash,re),!Io(F)&&Pe.length>0&&h.set(F.locatorHash,{directives:Pe,buildLocations:[re]})}else{let Pe=l.find(se=>se.supportsPackage(F,c));if(!Pe)throw new nt(z.LINKER_NOT_FOUND,`${lt(this.configuration,F)} isn't supported by any available linker`);let qe=u.get(Pe);if(!qe)throw new Error("Assertion failed: The installer should have been registered");let re;try{re=await qe.installPackage(F,D,{holdFetchResult:pe})}finally{he.length===0?(V=D.releaseFs)==null||V.call(D):d.push(Promise.all(he).then(()=>{}).then(()=>{var se;(se=D.releaseFs)==null||se.call(D)}))}g.set(F.locatorHash,Pe),f.set(F.locatorHash,re.packageLocation),re.buildDirective&&re.buildDirective.length>0&&re.packageLocation&&h.set(F.locatorHash,{directives:re.buildDirective,buildLocations:[re.packageLocation]})}}let m=new Map;for(let X of this.accessibleLocators){let F=this.storedPackages.get(X);if(!F)throw new Error("Assertion failed: The locator should have been registered");let D=this.tryWorkspaceByLocator(F)!==null,he=async(pe,Ne)=>{let Pe=f.get(F.locatorHash);if(typeof Pe=="undefined")throw new Error(`Assertion failed: The package (${lt(this.configuration,F)}) should have been registered`);let qe=[];for(let re of F.dependencies.values()){let se=this.storedResolutions.get(re.descriptorHash);if(typeof se=="undefined")throw new Error(`Assertion failed: The resolution (${Xt(this.configuration,re)}, from ${lt(this.configuration,F)})should have been registered`);let be=this.storedPackages.get(se);if(typeof be=="undefined")throw new Error(`Assertion failed: The package (${se}, resolved from ${Xt(this.configuration,re)}) should have been registered`);let ae=this.tryWorkspaceByLocator(be)===null?g.get(se):null;if(typeof ae=="undefined")throw new Error(`Assertion failed: The package (${se}, resolved from ${Xt(this.configuration,re)}) should have been registered`);ae===pe||ae===null?f.get(be.locatorHash)!==null&&qe.push([re,be]):!D&&Pe!==null&&hu(m,se).push(Pe)}Pe!==null&&await Ne.attachInternalDependencies(F,qe)};if(D)for(let[pe,Ne]of u)pe.supportsPackage(F,c)&&await he(pe,Ne);else{let pe=g.get(F.locatorHash);if(!pe)throw new Error("Assertion failed: The linker should have been found");let Ne=u.get(pe);if(!Ne)throw new Error("Assertion failed: The installer should have been registered");await he(pe,Ne)}}for(let[X,F]of m){let D=this.storedPackages.get(X);if(!D)throw new Error("Assertion failed: The package should have been registered");let he=g.get(D.locatorHash);if(!he)throw new Error("Assertion failed: The linker should have been found");let pe=u.get(he);if(!pe)throw new Error("Assertion failed: The installer should have been registered");await pe.attachExternalDependents(D,F)}let I=new Map;for(let X of u.values()){let F=await X.finalizeInstall();for(let D of(W=F==null?void 0:F.records)!=null?W:[])h.set(D.locatorHash,{directives:D.buildDirective,buildLocations:D.buildLocations});typeof(F==null?void 0:F.customData)!="undefined"&&I.set(X.getCustomDataKey(),F.customData)}if(this.installersCustomData=I,await Promise.all(d),n===li.SkipBuild)return;let B=new Set(this.storedPackages.keys()),b=new Set(h.keys());for(let X of b)B.delete(X);let R=(0,t0.createHash)("sha512");R.update(process.versions.node),await this.configuration.triggerHook(X=>X.globalHashGeneration,this,X=>{R.update("\0"),R.update(X)});let H=R.digest("hex"),L=new Map,K=X=>{let F=L.get(X.locatorHash);if(typeof F!="undefined")return F;let D=this.storedPackages.get(X.locatorHash);if(typeof D=="undefined")throw new Error("Assertion failed: The package should have been registered");let he=(0,t0.createHash)("sha512");he.update(X.locatorHash),L.set(X.locatorHash,"");for(let pe of D.dependencies.values()){let Ne=this.storedResolutions.get(pe.descriptorHash);if(typeof Ne=="undefined")throw new Error(`Assertion failed: The resolution (${Xt(this.configuration,pe)}) should have been registered`);let Pe=this.storedPackages.get(Ne);if(typeof Pe=="undefined")throw new Error("Assertion failed: The package should have been registered");he.update(K(Pe))}return F=he.digest("hex"),L.set(X.locatorHash,F),F},J=(X,F)=>{let D=(0,t0.createHash)("sha512");D.update(H),D.update(K(X));for(let he of F)D.update(he);return D.digest("hex")},ne=new Map,q=!1;for(;b.size>0;){let X=b.size,F=[];for(let D of b){let he=this.storedPackages.get(D);if(!he)throw new Error("Assertion failed: The package should have been registered");let pe=!0;for(let qe of he.dependencies.values()){let re=this.storedResolutions.get(qe.descriptorHash);if(!re)throw new Error(`Assertion failed: The resolution (${Xt(this.configuration,qe)}) should have been registered`);if(b.has(re)){pe=!1;break}}if(!pe)continue;b.delete(D);let Ne=h.get(he.locatorHash);if(!Ne)throw new Error("Assertion failed: The build directive should have been registered");let Pe=J(he,Ne.buildLocations);if(this.storedBuildState.get(he.locatorHash)===Pe){ne.set(he.locatorHash,Pe);continue}q||(await this.persistInstallStateFile(),q=!0),this.storedBuildState.has(he.locatorHash)?r.reportInfo(z.MUST_REBUILD,`${lt(this.configuration,he)} must be rebuilt because its dependency tree changed`):r.reportInfo(z.MUST_BUILD,`${lt(this.configuration,he)} must be built because it never has been before or the last one failed`);for(let qe of Ne.buildLocations){if(!v.isAbsolute(qe))throw new Error(`Assertion failed: Expected the build location to be absolute (not ${qe})`);F.push((async()=>{for(let[re,se]of Ne.directives){let be=`# This file contains the result of Yarn building a package (${is(he)}) -`;switch(re){case Gn.SCRIPT:be+=`# Script name: ${se} -`;break;case Gn.SHELLCODE:be+=`# Script code: ${se} -`;break}let ae=null;if(!await T.mktempPromise(async De=>{let $=v.join(De,"build.log"),{stdout:G,stderr:Ce}=this.configuration.getSubprocessStreams($,{header:be,prefix:lt(this.configuration,he),report:r}),ee;try{switch(re){case Gn.SCRIPT:ee=await Uw(he,se,[],{cwd:qe,project:this,stdin:ae,stdout:G,stderr:Ce});break;case Gn.SHELLCODE:ee=await rD(he,se,[],{cwd:qe,project:this,stdin:ae,stdout:G,stderr:Ce});break}}catch(Oe){Ce.write(Oe.stack),ee=1}if(G.end(),Ce.end(),ee===0)return ne.set(he.locatorHash,Pe),!0;T.detachTemp(De);let Ue=`${lt(this.configuration,he)} couldn't be built successfully (exit code ${Ve(this.configuration,ee,Le.NUMBER)}, logs can be found here: ${Ve(this.configuration,$,Le.PATH)})`;return this.optionalBuilds.has(he.locatorHash)?(r.reportInfo(z.BUILD_FAILED,Ue),ne.set(he.locatorHash,Pe),!0):(r.reportError(z.BUILD_FAILED,Ue),!1)}))return}})())}}if(await Promise.all(F),X===b.size){let D=Array.from(b).map(he=>{let pe=this.storedPackages.get(he);if(!pe)throw new Error("Assertion failed: The package should have been registered");return lt(this.configuration,pe)}).join(", ");r.reportError(z.CYCLIC_DEPENDENCIES,`Some packages have circular dependencies that make their build order unsatisfiable - as a result they won't be built (affected packages are: ${D})`);break}}this.storedBuildState=ne}async install(e){var a,l;let r=this.configuration.get("nodeLinker");(a=fe.telemetry)==null||a.reportInstall(r),await e.report.startTimerPromise("Project validation",{skipIfEmpty:!0},async()=>{await this.configuration.triggerHook(c=>c.validateProject,this,{reportWarning:e.report.reportWarning.bind(e.report),reportError:e.report.reportError.bind(e.report)})});for(let c of this.configuration.packageExtensions.values())for(let[,u]of c)for(let g of u)g.status=ki.Inactive;let i=v.join(this.cwd,this.configuration.get("lockfileFilename")),n=null;if(e.immutable)try{n=await T.readFilePromise(i,"utf8")}catch(c){throw c.code==="ENOENT"?new nt(z.FROZEN_LOCKFILE_EXCEPTION,"The lockfile would have been created by this install, which is explicitly forbidden."):c}await e.report.startTimerPromise("Resolution step",async()=>{await this.resolveEverything(e)}),await e.report.startTimerPromise("Post-resolution validation",{skipIfEmpty:!0},async()=>{for(let[,c]of this.configuration.packageExtensions)for(let[,u]of c)for(let g of u)if(g.userProvided){let f=Ve(this.configuration,g,Le.PACKAGE_EXTENSION);switch(g.status){case ki.Inactive:e.report.reportWarning(z.UNUSED_PACKAGE_EXTENSION,`${f}: No matching package in the dependency tree; you may not need this rule anymore.`);break;case ki.Redundant:e.report.reportWarning(z.REDUNDANT_PACKAGE_EXTENSION,`${f}: This rule seems redundant when applied on the original package; the extension may have been applied upstream.`);break}}if(n!==null){let c=ul(n,this.generateLockfile());if(c!==n){let u=(0,v$.structuredPatch)(i,i,n,c);e.report.reportSeparator();for(let g of u.hunks){e.report.reportInfo(null,`@@ -${g.oldStart},${g.oldLines} +${g.newStart},${g.newLines} @@`);for(let f of g.lines)f.startsWith("+")?e.report.reportError(z.FROZEN_LOCKFILE_EXCEPTION,Ve(this.configuration,f,Le.ADDED)):f.startsWith("-")?e.report.reportError(z.FROZEN_LOCKFILE_EXCEPTION,Ve(this.configuration,f,Le.REMOVED)):e.report.reportInfo(null,Ve(this.configuration,f,"grey"))}throw e.report.reportSeparator(),new nt(z.FROZEN_LOCKFILE_EXCEPTION,"The lockfile would have been modified by this install, which is explicitly forbidden.")}}});for(let c of this.configuration.packageExtensions.values())for(let[,u]of c)for(let g of u)g.userProvided&&g.status===ki.Active&&((l=fe.telemetry)==null||l.reportPackageExtension(Uu(g,Le.PACKAGE_EXTENSION)));await e.report.startTimerPromise("Fetch step",async()=>{await this.fetchEverything(e),(typeof e.persistProject=="undefined"||e.persistProject)&&e.mode!==li.UpdateLockfile&&await this.cacheCleanup(e)});let s=e.immutable?[...new Set(this.configuration.get("immutablePatterns"))].sort():[],o=await Promise.all(s.map(async c=>Iy(c,{cwd:this.cwd})));(typeof e.persistProject=="undefined"||e.persistProject)&&await this.persist(),await e.report.startTimerPromise("Link step",async()=>{if(e.mode===li.UpdateLockfile){e.report.reportWarning(z.UPDATE_LOCKFILE_ONLY_SKIP_LINK,`Skipped due to ${Ve(this.configuration,"mode=update-lockfile",Le.CODE)}`);return}await this.linkEverything(e);let c=await Promise.all(s.map(async u=>Iy(u,{cwd:this.cwd})));for(let u=0;uc.afterAllInstalled,this,e)}generateLockfile(){let e=new Map;for(let[n,s]of this.storedResolutions.entries()){let o=e.get(s);o||e.set(s,o=new Set),o.add(n)}let r={};r.__metadata={version:k$,cacheKey:void 0};for(let[n,s]of e.entries()){let o=this.originalPackages.get(n);if(!o)continue;let a=[];for(let f of s){let h=this.storedDescriptors.get(f);if(!h)throw new Error("Assertion failed: The descriptor should have been registered");a.push(h)}let l=a.map(f=>In(f)).sort().join(", "),c=new Ze;c.version=o.linkType===gt.HARD?o.version:"0.0.0-use.local",c.languageName=o.languageName,c.dependencies=new Map(o.dependencies),c.peerDependencies=new Map(o.peerDependencies),c.dependenciesMeta=new Map(o.dependenciesMeta),c.peerDependenciesMeta=new Map(o.peerDependenciesMeta),c.bin=new Map(o.bin);let u,g=this.storedChecksums.get(o.locatorHash);if(typeof g!="undefined"){let f=g.indexOf("/");if(f===-1)throw new Error("Assertion failed: Expected the checksum to reference its cache key");let h=g.slice(0,f),p=g.slice(f+1);typeof r.__metadata.cacheKey=="undefined"&&(r.__metadata.cacheKey=h),h===r.__metadata.cacheKey?u=p:u=g}r[l]=_(P({},c.exportTo({},{compatibilityMode:!1})),{linkType:o.linkType.toLowerCase(),resolution:is(o),checksum:u,conditions:o.conditions||void 0})}return`${[`# This file is generated by running "yarn install" inside your project. -`,`# Manual changes might be lost - proceed with caution! -`].join("")} -`+Qa(r)}async persistLockfile(){let e=v.join(this.cwd,this.configuration.get("lockfileFilename")),r="";try{r=await T.readFilePromise(e,"utf8")}catch(s){}let i=this.generateLockfile(),n=ul(r,i);n!==r&&(await T.writeFilePromise(e,n),this.lockFileChecksum=D$(n),this.lockfileNeedsRefresh=!1)}async persistInstallStateFile(){let e=[];for(let o of Object.values(gF))e.push(...o);let r=(0,r0.default)(this,e),i=cF.default.serialize(r),n=zi(i);if(this.installStateChecksum===n)return;let s=this.configuration.get("installStatePath");await T.mkdirPromise(v.dirname(s),{recursive:!0}),await T.writeFilePromise(s,await aUe(i)),this.installStateChecksum=n}async restoreInstallState({restoreInstallersCustomData:e=!0,restoreResolutions:r=!0,restoreBuildState:i=!0}={}){let n=this.configuration.get("installStatePath");if(!T.existsSync(n)){r&&await this.applyLightResolution();return}let s=await AUe(await T.readFilePromise(n));this.installStateChecksum=zi(s);let o=cF.default.deserialize(s);e&&typeof o.installersCustomData!="undefined"&&(this.installersCustomData=o.installersCustomData),i&&Object.assign(this,(0,r0.default)(o,gF.restoreBuildState)),r&&(o.lockFileChecksum===this.lockFileChecksum?(Object.assign(this,(0,r0.default)(o,gF.restoreResolutions)),this.refreshWorkspaceDependencies()):await this.applyLightResolution())}async applyLightResolution(){await this.resolveEverything({lockfileOnly:!0,report:new ei}),await this.persistInstallStateFile()}async persist(){await this.persistLockfile();for(let e of this.workspacesByCwd.values())await e.persistManifest()}async cacheCleanup({cache:e,report:r}){let i=new Set([".gitignore"]);if(!Fb(e.cwd,this.cwd)||!await T.existsPromise(e.cwd))return;let n=this.configuration.get("preferAggregateCacheInfo"),s=0,o=null;for(let a of await T.readdirPromise(e.cwd)){if(i.has(a))continue;let l=v.resolve(e.cwd,a);e.markedFiles.has(l)||(o=a,e.immutable?r.reportError(z.IMMUTABLE_CACHE,`${Ve(this.configuration,v.basename(l),"magenta")} appears to be unused and would be marked for deletion, but the cache is immutable`):(n?s+=1:r.reportInfo(z.UNUSED_CACHE_ENTRY,`${Ve(this.configuration,v.basename(l),"magenta")} appears to be unused - removing`),await T.removePromise(l)))}n&&s!==0&&r.reportInfo(z.UNUSED_CACHE_ENTRY,s>1?`${s} packages appeared to be unused and were removed`:`${o} appeared to be unused and was removed`),e.markedFiles.clear()}};function lUe({project:t,allDescriptors:e,allResolutions:r,allPackages:i,accessibleLocators:n=new Set,optionalBuilds:s=new Set,volatileDescriptors:o=new Set,peerRequirements:a=new Map,report:l,tolerateMissingPackages:c=!1}){var ne;let u=new Map,g=[],f=new Map,h=new Map,p=new Map,d=new Map,m=new Map,I=new Map(t.workspaces.map(q=>{let A=q.anchoredLocator.locatorHash,V=i.get(A);if(typeof V=="undefined"){if(c)return[A,null];throw new Error("Assertion failed: The workspace should have an associated package")}return[A,ap(V)]})),B=()=>{let q=T.mktempSync(),A=v.join(q,"stacktrace.log"),V=String(g.length+1).length,W=g.map((X,F)=>`${`${F+1}.`.padStart(V," ")} ${is(X)} -`).join("");throw T.writeFileSync(A,W),T.detachTemp(q),new nt(z.STACK_OVERFLOW_RESOLUTION,`Encountered a stack overflow when resolving peer dependencies; cf ${M.fromPortablePath(A)}`)},b=q=>{let A=r.get(q.descriptorHash);if(typeof A=="undefined")throw new Error("Assertion failed: The resolution should have been registered");let V=i.get(A);if(!V)throw new Error("Assertion failed: The package could not be found");return V},R=(q,A,V,{top:W,optional:X})=>{g.length>1e3&&B(),g.push(A);let F=H(q,A,V,{top:W,optional:X});return g.pop(),F},H=(q,A,V,{top:W,optional:X})=>{if(n.has(A.locatorHash))return;n.add(A.locatorHash),X||s.delete(A.locatorHash);let F=i.get(A.locatorHash);if(!F){if(c)return;throw new Error(`Assertion failed: The package (${lt(t.configuration,A)}) should have been registered`)}let D=[],he=[],pe=[],Ne=[],Pe=[];for(let re of Array.from(F.dependencies.values())){if(F.peerDependencies.has(re.identHash)&&F.locatorHash!==W)continue;if(hA(re))throw new Error("Assertion failed: Virtual packages shouldn't be encountered when virtualizing a branch");o.delete(re.descriptorHash);let se=X;if(!se){let ee=F.dependenciesMeta.get(St(re));if(typeof ee!="undefined"){let Ue=ee.get(null);typeof Ue!="undefined"&&Ue.optional&&(se=!0)}}let be=r.get(re.descriptorHash);if(!be){if(c)continue;throw new Error(`Assertion failed: The resolution (${Xt(t.configuration,re)}) should have been registered`)}let ae=I.get(be)||i.get(be);if(!ae)throw new Error(`Assertion failed: The package (${be}, resolved from ${Xt(t.configuration,re)}) should have been registered`);if(ae.peerDependencies.size===0){R(re,ae,new Map,{top:W,optional:se});continue}let Ae=u.get(ae.locatorHash);typeof Ae=="number"&&Ae>=2&&B();let De,$,G=new Set,Ce;he.push(()=>{De=kx(re,A.locatorHash),$=Px(ae,A.locatorHash),F.dependencies.delete(re.identHash),F.dependencies.set(De.identHash,De),r.set(De.descriptorHash,$.locatorHash),e.set(De.descriptorHash,De),i.set($.locatorHash,$),D.push([ae,De,$])}),pe.push(()=>{var ee;Ce=new Map;for(let Ue of $.peerDependencies.values()){let Oe=F.dependencies.get(Ue.identHash);if(!Oe&&cp(A,Ue)&&(Oe=q),(!Oe||Oe.range==="missing:")&&$.dependencies.has(Ue.identHash)){$.peerDependencies.delete(Ue.identHash);continue}Oe||(Oe=Yt(Ue,"missing:")),$.dependencies.set(Oe.identHash,Oe),hA(Oe)&&Pl(p,Oe.descriptorHash).add($.locatorHash),f.set(Oe.identHash,Oe),Oe.range==="missing:"&&G.add(Oe.identHash),Ce.set(Ue.identHash,(ee=V.get(Ue.identHash))!=null?ee:$.locatorHash)}$.dependencies=new Map(gn($.dependencies,([Ue,Oe])=>St(Oe)))}),Ne.push(()=>{if(!i.has($.locatorHash))return;let ee=u.get(ae.locatorHash),Ue=typeof ee!="undefined"?ee+1:1;u.set(ae.locatorHash,Ue),R(De,$,Ce,{top:W,optional:se}),u.set(ae.locatorHash,Ue-1)}),Pe.push(()=>{let ee=F.dependencies.get(re.identHash);if(typeof ee=="undefined")throw new Error("Assertion failed: Expected the peer dependency to have been turned into a dependency");let Ue=r.get(ee.descriptorHash);if(typeof Ue=="undefined")throw new Error("Assertion failed: Expected the descriptor to be registered");if(Pl(m,Ue).add(A.locatorHash),!!i.has($.locatorHash)){for(let Oe of $.peerDependencies.values()){let vt=Ce.get(Oe.identHash);if(typeof vt=="undefined")throw new Error("Assertion failed: Expected the peer dependency ident to be registered");hu(pu(d,vt),St(Oe)).push($.locatorHash)}for(let Oe of G)$.dependencies.delete(Oe)}})}for(let re of[...he,...pe])re();let qe;do{qe=!0;for(let[re,se,be]of D){if(!i.has(be.locatorHash))continue;let ae=pu(h,re.locatorHash),Ae=zi(...[...be.dependencies.values()].map(Ce=>{let ee=Ce.range!=="missing:"?r.get(Ce.descriptorHash):"missing:";if(typeof ee=="undefined")throw new Error(`Assertion failed: Expected the resolution for ${Xt(t.configuration,Ce)} to have been registered`);return ee===W?`${ee} (top)`:ee}),se.identHash),De=ae.get(Ae);if(typeof De=="undefined"){ae.set(Ae,se);continue}if(De===se)continue;qe=!1,i.delete(be.locatorHash),e.delete(se.descriptorHash),r.delete(se.descriptorHash),n.delete(be.locatorHash);let $=p.get(se.descriptorHash)||[],G=[F.locatorHash,...$];p.delete(se.descriptorHash);for(let Ce of G){let ee=i.get(Ce);typeof ee!="undefined"&&ee.dependencies.set(se.identHash,De)}}}while(!qe);for(let re of[...Ne,...Pe])re()};for(let q of t.workspaces){let A=q.anchoredLocator;o.delete(q.anchoredDescriptor.descriptorHash),R(q.anchoredDescriptor,A,new Map,{top:A.locatorHash,optional:!1})}var L;(function(V){V[V.NotProvided=0]="NotProvided",V[V.NotCompatible=1]="NotCompatible"})(L||(L={}));let K=[];for(let[q,A]of m){let V=i.get(q);if(typeof V=="undefined")throw new Error("Assertion failed: Expected the root to be registered");let W=d.get(q);if(typeof W!="undefined")for(let X of A){let F=i.get(X);if(typeof F!="undefined")for(let[D,he]of W){let pe=En(D);if(F.peerDependencies.has(pe.identHash))continue;let Ne=`p${zi(X,D,q).slice(0,5)}`;a.set(Ne,{subject:X,requested:pe,rootRequester:q,allRequesters:he});let Pe=V.dependencies.get(pe.identHash);if(typeof Pe!="undefined"){let qe=b(Pe),re=(ne=qe.version)!=null?ne:"0.0.0",se=new Set;for(let ae of he){let Ae=i.get(ae);if(typeof Ae=="undefined")throw new Error("Assertion failed: Expected the link to be registered");let De=Ae.peerDependencies.get(pe.identHash);if(typeof De=="undefined")throw new Error("Assertion failed: Expected the ident to be registered");se.add(De.range)}[...se].every(ae=>{if(ae.startsWith(Yr.protocol)){if(!t.tryWorkspaceByLocator(qe))return!1;ae=ae.slice(Yr.protocol.length),(ae==="^"||ae==="~")&&(ae="*")}return lc(re,ae)})||K.push({type:1,subject:F,requested:pe,requester:V,version:re,hash:Ne,requirementCount:he.length})}else{let qe=V.peerDependenciesMeta.get(D);(qe==null?void 0:qe.optional)||K.push({type:0,subject:F,requested:pe,requester:V,hash:Ne})}}}}let J=[q=>Rx(q.subject),q=>St(q.requested),q=>`${q.type}`];for(let q of gn(K,J))switch(q.type){case 0:l==null||l.reportWarning(z.MISSING_PEER_DEPENDENCY,`${lt(t.configuration,q.subject)} doesn't provide ${Vr(t.configuration,q.requested)} (${Ve(t.configuration,q.hash,Le.CODE)}), requested by ${Vr(t.configuration,q.requester)}`);break;case 1:{let A=q.requirementCount>1?"and some of its descendants request":"requests";l==null||l.reportWarning(z.INCOMPATIBLE_PEER_DEPENDENCY,`${lt(t.configuration,q.subject)} provides ${Vr(t.configuration,q.requested)} (${Ve(t.configuration,q.hash,Le.CODE)}) with version ${fp(t.configuration,q.version)}, which doesn't satisfy what ${Vr(t.configuration,q.requester)} ${A}`)}break}K.length>0&&(l==null||l.reportWarning(z.UNNAMED,`Some peer dependencies are incorrectly met; run ${Ve(t.configuration,"yarn explain peer-requirements ",Le.CODE)} for details, where ${Ve(t.configuration,"",Le.CODE)} is the six-letter p-prefixed code`))}var Po;(function(l){l.VERSION="version",l.COMMAND_NAME="commandName",l.PLUGIN_NAME="pluginName",l.INSTALL_COUNT="installCount",l.PROJECT_COUNT="projectCount",l.WORKSPACE_COUNT="workspaceCount",l.DEPENDENCY_COUNT="dependencyCount",l.EXTENSION="packageExtension"})(Po||(Po={}));var Rd=class{constructor(e,r){this.values=new Map;this.hits=new Map;this.enumerators=new Map;this.configuration=e;let i=this.getRegistryPath();this.isNew=!T.existsSync(i),this.sendReport(r),this.startBuffer()}reportVersion(e){this.reportValue(Po.VERSION,e.replace(/-git\..*/,"-git"))}reportCommandName(e){this.reportValue(Po.COMMAND_NAME,e||"")}reportPluginName(e){this.reportValue(Po.PLUGIN_NAME,e)}reportProject(e){this.reportEnumerator(Po.PROJECT_COUNT,e)}reportInstall(e){this.reportHit(Po.INSTALL_COUNT,e)}reportPackageExtension(e){this.reportValue(Po.EXTENSION,e)}reportWorkspaceCount(e){this.reportValue(Po.WORKSPACE_COUNT,String(e))}reportDependencyCount(e){this.reportValue(Po.DEPENDENCY_COUNT,String(e))}reportValue(e,r){Pl(this.values,e).add(r)}reportEnumerator(e,r){Pl(this.enumerators,e).add(zi(r))}reportHit(e,r="*"){let i=pu(this.hits,e),n=na(i,r,()=>0);i.set(r,n+1)}getRegistryPath(){let e=this.configuration.get("globalFolder");return v.join(e,"telemetry.json")}sendReport(e){var u,g,f;let r=this.getRegistryPath(),i;try{i=T.readJsonSync(r)}catch{i={}}let n=Date.now(),s=this.configuration.get("telemetryInterval")*24*60*60*1e3,a=((u=i.lastUpdate)!=null?u:n+s+Math.floor(s*Math.random()))+s;if(a>n&&i.lastUpdate!=null)return;try{T.mkdirSync(v.dirname(r),{recursive:!0}),T.writeJsonSync(r,{lastUpdate:n})}catch{return}if(a>n||!i.blocks)return;let l=`https://browser-http-intake.logs.datadoghq.eu/v1/input/${e}?ddsource=yarn`,c=h=>iP(l,h,{configuration:this.configuration}).catch(()=>{});for(let[h,p]of Object.entries((g=i.blocks)!=null?g:{})){if(Object.keys(p).length===0)continue;let d=p;d.userId=h,d.reportType="primary";for(let B of Object.keys((f=d.enumerators)!=null?f:{}))d.enumerators[B]=d.enumerators[B].length;c(d);let m=new Map,I=20;for(let[B,b]of Object.entries(d.values))b.length>0&&m.set(B,b.slice(0,I));for(;m.size>0;){let B={};B.userId=h,B.reportType="secondary",B.metrics={};for(let[b,R]of m)B.metrics[b]=R.shift(),R.length===0&&m.delete(b);c(B)}}}applyChanges(){var o,a,l,c,u,g,f,h,p;let e=this.getRegistryPath(),r;try{r=T.readJsonSync(e)}catch{r={}}let i=(o=this.configuration.get("telemetryUserId"))!=null?o:"*",n=r.blocks=(a=r.blocks)!=null?a:{},s=n[i]=(l=n[i])!=null?l:{};for(let d of this.hits.keys()){let m=s.hits=(c=s.hits)!=null?c:{},I=m[d]=(u=m[d])!=null?u:{};for(let[B,b]of this.hits.get(d))I[B]=((g=I[B])!=null?g:0)+b}for(let d of["values","enumerators"])for(let m of this[d].keys()){let I=s[d]=(f=s[d])!=null?f:{};I[m]=[...new Set([...(h=I[m])!=null?h:[],...(p=this[d].get(m))!=null?p:[]])]}T.mkdirSync(v.dirname(e),{recursive:!0}),T.writeJsonSync(e,r)}startBuffer(){process.on("exit",()=>{try{this.applyChanges()}catch{}})}};var fF=ie(require("child_process")),R$=ie(ml());var hF=ie(require("fs"));var Yg=new Map([["constraints",[["constraints","query"],["constraints","source"],["constraints"]]],["exec",[]],["interactive-tools",[["search"],["upgrade-interactive"]]],["stage",[["stage"]]],["typescript",[]],["version",[["version","apply"],["version","check"],["version"]]],["workspace-tools",[["workspaces","focus"],["workspaces","foreach"]]]]);function cUe(t){let e=M.fromPortablePath(t);process.on("SIGINT",()=>{}),e?(0,fF.execFileSync)(process.execPath,[e,...process.argv.slice(2)],{stdio:"inherit",env:_(P({},process.env),{YARN_IGNORE_PATH:"1",YARN_IGNORE_CWD:"1"})}):(0,fF.execFileSync)(e,process.argv.slice(2),{stdio:"inherit",env:_(P({},process.env),{YARN_IGNORE_PATH:"1",YARN_IGNORE_CWD:"1"})})}async function i0({binaryVersion:t,pluginConfiguration:e}){async function r(){let n=new oo({binaryLabel:"Yarn Package Manager",binaryName:"yarn",binaryVersion:t});try{await i(n)}catch(s){process.stdout.write(n.error(s)),process.exitCode=1}}async function i(n){var p,d,m,I,B;let s=process.versions.node,o=">=12 <14 || 14.2 - 14.9 || >14.10.0";if(process.env.YARN_IGNORE_NODE!=="1"&&!qt.satisfiesWithPrereleases(s,o))throw new me(`This tool requires a Node version compatible with ${o} (got ${s}). Upgrade Node, or set \`YARN_IGNORE_NODE=1\` in your environment.`);let a=await fe.find(M.toPortablePath(process.cwd()),e,{usePath:!0,strict:!1}),l=a.get("yarnPath"),c=a.get("ignorePath"),u=a.get("ignoreCwd"),g=M.toPortablePath(M.resolve(process.argv[1])),f=b=>T.readFilePromise(b).catch(()=>Buffer.of());if(!c&&!u&&await(async()=>l===g||Buffer.compare(...await Promise.all([f(l),f(g)]))===0)()){process.env.YARN_IGNORE_PATH="1",process.env.YARN_IGNORE_CWD="1",await i(n);return}else if(l!==null&&!c)if(!T.existsSync(l))process.stdout.write(n.error(new Error(`The "yarn-path" option has been set (in ${a.sources.get("yarnPath")}), but the specified location doesn't exist (${l}).`))),process.exitCode=1;else try{cUe(l)}catch(b){process.exitCode=b.code||1}else{c&&delete process.env.YARN_IGNORE_PATH,a.get("enableTelemetry")&&!R$.isCI&&process.stdout.isTTY&&(fe.telemetry=new Rd(a,"puba9cdc10ec5790a2cf4969dd413a47270")),(p=fe.telemetry)==null||p.reportVersion(t);for(let[L,K]of a.plugins.entries()){Yg.has((m=(d=L.match(/^@yarnpkg\/plugin-(.*)$/))==null?void 0:d[1])!=null?m:"")&&((I=fe.telemetry)==null||I.reportPluginName(L));for(let J of K.commands||[])n.register(J)}let R=n.process(process.argv.slice(2));R.help||(B=fe.telemetry)==null||B.reportCommandName(R.path.join(" "));let H=R.cwd;if(typeof H!="undefined"&&!u){let L=(0,hF.realpathSync)(process.cwd()),K=(0,hF.realpathSync)(H);if(L!==K){process.chdir(H),await r();return}}await n.runExit(R,{cwd:M.toPortablePath(process.cwd()),plugins:e,quiet:!1,stdin:process.stdin,stdout:process.stdout,stderr:process.stderr})}}return r().catch(n=>{process.stdout.write(n.stack||n.message),process.exitCode=1}).finally(()=>T.rmtempPromise())}function F$(t){t.Command.Path=(...e)=>r=>{r.paths=r.paths||[],r.paths.push(e)};for(let e of["Array","Boolean","String","Proxy","Rest","Counter"])t.Command[e]=(...r)=>(i,n)=>{let s=t.Option[e](...r);Object.defineProperty(i,`__${n}`,{configurable:!1,enumerable:!0,get(){return s},set(o){this[n]=o}})};return t}var iC={};it(iC,{BaseCommand:()=>Be,WorkspaceRequiredError:()=>rt,getDynamicLibs:()=>Wie,getPluginConfiguration:()=>F0,main:()=>i0,openWorkspace:()=>rf,pluginCommands:()=>Yg});var Be=class extends ye{constructor(){super(...arguments);this.cwd=Y.String("--cwd",{hidden:!0})}};var rt=class extends me{constructor(e,r){let i=v.relative(e,r),n=v.join(e,Ze.fileName);super(`This command can only be run from within a workspace of your project (${i} isn't a workspace of ${n}).`)}};var dJe=ie(Or());Ss();var CJe=ie(gN()),Wie=()=>new Map([["@yarnpkg/cli",iC],["@yarnpkg/core",Fd],["@yarnpkg/fslib",ch],["@yarnpkg/libzip",Fp],["@yarnpkg/parsers",Hp],["@yarnpkg/shell",jp],["clipanion",vh],["semver",dJe],["typanion",lu],["yup",CJe]]);async function rf(t,e){let{project:r,workspace:i}=await Ke.find(t,e);if(!i)throw new rt(r.cwd,e);return i}var x_e=ie(Or());Ss();var k_e=ie(gN());var hL={};it(hL,{dedupeUtils:()=>zN,default:()=>Qze,suggestUtils:()=>LN});var WAe=ie(ml());var roe=ie(aC());Ss();var LN={};it(LN,{Modifier:()=>Lo,Strategy:()=>Fr,Target:()=>vr,WorkspaceModifier:()=>af,applyModifier:()=>Zse,extractDescriptorFromPath:()=>ON,extractRangeModifier:()=>Xse,fetchDescriptorFrom:()=>MN,findProjectDescriptors:()=>toe,getModifier:()=>AC,getSuggestedDescriptors:()=>lC,makeWorkspaceDescriptor:()=>eoe,toWorkspaceModifier:()=>$se});var TN=ie(Or()),L3e="workspace:",vr;(function(i){i.REGULAR="dependencies",i.DEVELOPMENT="devDependencies",i.PEER="peerDependencies"})(vr||(vr={}));var Lo;(function(i){i.CARET="^",i.TILDE="~",i.EXACT=""})(Lo||(Lo={}));var af;(function(i){i.CARET="^",i.TILDE="~",i.EXACT="*"})(af||(af={}));var Fr;(function(s){s.KEEP="keep",s.REUSE="reuse",s.PROJECT="project",s.LATEST="latest",s.CACHE="cache"})(Fr||(Fr={}));function AC(t,e){return t.exact?Lo.EXACT:t.caret?Lo.CARET:t.tilde?Lo.TILDE:e.configuration.get("defaultSemverRangePrefix")}var T3e=/^([\^~]?)[0-9]+(?:\.[0-9]+){0,2}(?:-\S+)?$/;function Xse(t,{project:e}){let r=t.match(T3e);return r?r[1]:e.configuration.get("defaultSemverRangePrefix")}function Zse(t,e){let{protocol:r,source:i,params:n,selector:s}=S.parseRange(t.range);return TN.default.valid(s)&&(s=`${e}${t.range}`),S.makeDescriptor(t,S.makeRange({protocol:r,source:i,params:n,selector:s}))}function $se(t){switch(t){case Lo.CARET:return af.CARET;case Lo.TILDE:return af.TILDE;case Lo.EXACT:return af.EXACT;default:throw new Error(`Assertion failed: Unknown modifier: "${t}"`)}}function eoe(t,e){return S.makeDescriptor(t.anchoredDescriptor,`${L3e}${$se(e)}`)}async function toe(t,{project:e,target:r}){let i=new Map,n=s=>{let o=i.get(s.descriptorHash);return o||i.set(s.descriptorHash,o={descriptor:s,locators:[]}),o};for(let s of e.workspaces)if(r===vr.PEER){let o=s.manifest.peerDependencies.get(t.identHash);o!==void 0&&n(o).locators.push(s.locator)}else{let o=s.manifest.dependencies.get(t.identHash),a=s.manifest.devDependencies.get(t.identHash);r===vr.DEVELOPMENT?a!==void 0?n(a).locators.push(s.locator):o!==void 0&&n(o).locators.push(s.locator):o!==void 0?n(o).locators.push(s.locator):a!==void 0&&n(a).locators.push(s.locator)}return i}async function ON(t,{cwd:e,workspace:r}){return await M3e(async i=>{v.isAbsolute(t)||(t=v.relative(r.cwd,v.resolve(e,t)),t.match(/^\.{0,2}\//)||(t=`./${t}`));let{project:n}=r,s=await MN(S.makeIdent(null,"archive"),t,{project:r.project,cache:i,workspace:r});if(!s)throw new Error("Assertion failed: The descriptor should have been found");let o=new ei,a=n.configuration.makeResolver(),l=n.configuration.makeFetcher(),c={checksums:n.storedChecksums,project:n,cache:i,fetcher:l,report:o,resolver:a},u=a.bindDescriptor(s,r.anchoredLocator,c),g=S.convertDescriptorToLocator(u),f=await l.fetch(g,c),h=await Ze.find(f.prefixPath,{baseFs:f.packageFs});if(!h.name)throw new Error("Target path doesn't have a name");return S.makeDescriptor(h.name,t)})}async function lC(t,{project:e,workspace:r,cache:i,target:n,modifier:s,strategies:o,maxResults:a=Infinity}){if(!(a>=0))throw new Error(`Invalid maxResults (${a})`);if(t.range!=="unknown")return{suggestions:[{descriptor:t,name:`Use ${S.prettyDescriptor(e.configuration,t)}`,reason:"(unambiguous explicit request)"}],rejections:[]};let l=typeof r!="undefined"&&r!==null&&r.manifest[n].get(t.identHash)||null,c=[],u=[],g=async f=>{try{await f()}catch(h){u.push(h)}};for(let f of o){if(c.length>=a)break;switch(f){case Fr.KEEP:await g(async()=>{l&&c.push({descriptor:l,name:`Keep ${S.prettyDescriptor(e.configuration,l)}`,reason:"(no changes)"})});break;case Fr.REUSE:await g(async()=>{for(let{descriptor:h,locators:p}of(await toe(t,{project:e,target:n})).values()){if(p.length===1&&p[0].locatorHash===r.anchoredLocator.locatorHash&&o.includes(Fr.KEEP))continue;let d=`(originally used by ${S.prettyLocator(e.configuration,p[0])}`;d+=p.length>1?` and ${p.length-1} other${p.length>2?"s":""})`:")",c.push({descriptor:h,name:`Reuse ${S.prettyDescriptor(e.configuration,h)}`,reason:d})}});break;case Fr.CACHE:await g(async()=>{for(let h of e.storedDescriptors.values())h.identHash===t.identHash&&c.push({descriptor:h,name:`Reuse ${S.prettyDescriptor(e.configuration,h)}`,reason:"(already used somewhere in the lockfile)"})});break;case Fr.PROJECT:await g(async()=>{if(r.manifest.name!==null&&t.identHash===r.manifest.name.identHash)return;let h=e.tryWorkspaceByIdent(t);if(h===null)return;let p=eoe(h,s);c.push({descriptor:p,name:`Attach ${S.prettyDescriptor(e.configuration,p)}`,reason:`(local workspace at ${ue.pretty(e.configuration,h.relativeCwd,ue.Type.PATH)})`})});break;case Fr.LATEST:await g(async()=>{if(t.range!=="unknown")c.push({descriptor:t,name:`Use ${S.prettyRange(e.configuration,t.range)}`,reason:"(explicit range requested)"});else if(n===vr.PEER)c.push({descriptor:S.makeDescriptor(t,"*"),name:"Use *",reason:"(catch-all peer dependency pattern)"});else if(!e.configuration.get("enableNetwork"))c.push({descriptor:null,name:"Resolve from latest",reason:ue.pretty(e.configuration,"(unavailable because enableNetwork is toggled off)","grey")});else{let h=await MN(t,"latest",{project:e,cache:i,workspace:r,preserveModifier:!1});h&&(h=Zse(h,s),c.push({descriptor:h,name:`Use ${S.prettyDescriptor(e.configuration,h)}`,reason:"(resolved from latest)"}))}});break}}return{suggestions:c.slice(0,a),rejections:u.slice(0,a)}}async function MN(t,e,{project:r,cache:i,workspace:n,preserveModifier:s=!0}){let o=S.makeDescriptor(t,e),a=new ei,l=r.configuration.makeFetcher(),c=r.configuration.makeResolver(),u={project:r,fetcher:l,cache:i,checksums:r.storedChecksums,report:a,cacheOptions:{skipIntegrityCheck:!0},skipIntegrityCheck:!0},g=_(P({},u),{resolver:c,fetchOptions:u}),f=c.bindDescriptor(o,n.anchoredLocator,g),h=await c.getCandidates(f,new Map,g);if(h.length===0)return null;let p=h[0],{protocol:d,source:m,params:I,selector:B}=S.parseRange(S.convertToManifestRange(p.reference));if(d===r.configuration.get("defaultProtocol")&&(d=null),TN.default.valid(B)&&s!==!1){let b=typeof s=="string"?s:o.range;B=Xse(b,{project:r})+B}return S.makeDescriptor(p,S.makeRange({protocol:d,source:m,params:I,selector:B}))}async function M3e(t){return await T.mktempPromise(async e=>{let r=fe.create(e);return r.useWithSource(e,{enableMirror:!1,compressionLevel:0},e,{overwrite:!0}),await t(new Qt(e,{configuration:r,check:!1,immutable:!1}))})}var cC=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.exact=Y.Boolean("-E,--exact",!1,{description:"Don't use any semver modifier on the resolved range"});this.tilde=Y.Boolean("-T,--tilde",!1,{description:"Use the `~` semver modifier on the resolved range"});this.caret=Y.Boolean("-C,--caret",!1,{description:"Use the `^` semver modifier on the resolved range"});this.dev=Y.Boolean("-D,--dev",!1,{description:"Add a package as a dev dependency"});this.peer=Y.Boolean("-P,--peer",!1,{description:"Add a package as a peer dependency"});this.optional=Y.Boolean("-O,--optional",!1,{description:"Add / upgrade a package to an optional regular / peer dependency"});this.preferDev=Y.Boolean("--prefer-dev",!1,{description:"Add / upgrade a package to a dev dependency"});this.interactive=Y.Boolean("-i,--interactive",{description:"Reuse the specified package from other workspaces in the project"});this.cached=Y.Boolean("--cached",!1,{description:"Reuse the highest version already used somewhere within the project"});this.mode=Y.String("--mode",{description:"Change what artifacts installs generate",validator:Yi(li)});this.silent=Y.Boolean("--silent",{hidden:!0});this.packages=Y.Rest()}async execute(){var d;let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState({restoreResolutions:!1});let s=(d=this.interactive)!=null?d:e.get("preferInteractive"),o=AC(this,r),a=[...s?[Fr.REUSE]:[],Fr.PROJECT,...this.cached?[Fr.CACHE]:[],Fr.LATEST],l=s?Infinity:1,c=await Promise.all(this.packages.map(async m=>{let I=m.match(/^\.{0,2}\//)?await ON(m,{cwd:this.context.cwd,workspace:i}):S.parseDescriptor(m),B=O3e(i,I,{dev:this.dev,peer:this.peer,preferDev:this.preferDev,optional:this.optional}),b=await lC(I,{project:r,workspace:i,cache:n,target:B,modifier:o,strategies:a,maxResults:l});return[I,b,B]})),u=await Fa.start({configuration:e,stdout:this.context.stdout,suggestInstall:!1},async m=>{for(let[I,{suggestions:B,rejections:b}]of c)if(B.filter(H=>H.descriptor!==null).length===0){let[H]=b;if(typeof H=="undefined")throw new Error("Assertion failed: Expected an error to have been set");r.configuration.get("enableNetwork")?m.reportError(z.CANT_SUGGEST_RESOLUTIONS,`${S.prettyDescriptor(e,I)} can't be resolved to a satisfying range`):m.reportError(z.CANT_SUGGEST_RESOLUTIONS,`${S.prettyDescriptor(e,I)} can't be resolved to a satisfying range (note: network resolution has been disabled)`),m.reportSeparator(),m.reportExceptionOnce(H)}});if(u.hasErrors())return u.exitCode();let g=!1,f=[],h=[];for(let[,{suggestions:m},I]of c){let B,b=m.filter(K=>K.descriptor!==null),R=b[0].descriptor,H=b.every(K=>S.areDescriptorsEqual(K.descriptor,R));b.length===1||H?B=R:(g=!0,{answer:B}=await(0,roe.prompt)({type:"select",name:"answer",message:"Which range do you want to use?",choices:m.map(({descriptor:K,name:J,reason:ne})=>K?{name:J,hint:ne,descriptor:K}:{name:J,hint:ne,disabled:!0}),onCancel:()=>process.exit(130),result(K){return this.find(K,"descriptor")},stdin:this.context.stdin,stdout:this.context.stdout}));let L=i.manifest[I].get(B.identHash);(typeof L=="undefined"||L.descriptorHash!==B.descriptorHash)&&(i.manifest[I].set(B.identHash,B),this.optional&&(I==="dependencies"?i.manifest.ensureDependencyMeta(_(P({},B),{range:"unknown"})).optional=!0:I==="peerDependencies"&&(i.manifest.ensurePeerDependencyMeta(_(P({},B),{range:"unknown"})).optional=!0)),typeof L=="undefined"?f.push([i,I,B,a]):h.push([i,I,L,B]))}return await e.triggerMultipleHooks(m=>m.afterWorkspaceDependencyAddition,f),await e.triggerMultipleHooks(m=>m.afterWorkspaceDependencyReplacement,h),g&&this.context.stdout.write(` -`),(await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout,includeLogs:!this.context.quiet},async m=>{await r.install({cache:n,report:m,mode:this.mode})})).exitCode()}};cC.paths=[["add"]],cC.usage=ye.Usage({description:"add dependencies to the project",details:"\n This command adds a package to the package.json for the nearest workspace.\n\n - If it didn't exist before, the package will by default be added to the regular `dependencies` field, but this behavior can be overriden thanks to the `-D,--dev` flag (which will cause the dependency to be added to the `devDependencies` field instead) and the `-P,--peer` flag (which will do the same but for `peerDependencies`).\n\n - If the package was already listed in your dependencies, it will by default be upgraded whether it's part of your `dependencies` or `devDependencies` (it won't ever update `peerDependencies`, though).\n\n - If set, the `--prefer-dev` flag will operate as a more flexible `-D,--dev` in that it will add the package to your `devDependencies` if it isn't already listed in either `dependencies` or `devDependencies`, but it will also happily upgrade your `dependencies` if that's what you already use (whereas `-D,--dev` would throw an exception).\n\n - If set, the `-O,--optional` flag will add the package to the `optionalDependencies` field and, in combination with the `-P,--peer` flag, it will add the package as an optional peer dependency. If the package was already listed in your `dependencies`, it will be upgraded to `optionalDependencies`. If the package was already listed in your `peerDependencies`, in combination with the `-P,--peer` flag, it will be upgraded to an optional peer dependency: `\"peerDependenciesMeta\": { \"\": { \"optional\": true } }`\n\n - If the added package doesn't specify a range at all its `latest` tag will be resolved and the returned version will be used to generate a new semver range (using the `^` modifier by default unless otherwise configured via the `defaultSemverRangePrefix` configuration, or the `~` modifier if `-T,--tilde` is specified, or no modifier at all if `-E,--exact` is specified). Two exceptions to this rule: the first one is that if the package is a workspace then its local version will be used, and the second one is that if you use `-P,--peer` the default range will be `*` and won't be resolved at all.\n\n - If the added package specifies a range (such as `^1.0.0`, `latest`, or `rc`), Yarn will add this range as-is in the resulting package.json entry (in particular, tags such as `rc` will be encoded as-is rather than being converted into a semver range).\n\n If the `--cached` option is used, Yarn will preferably reuse the highest version already used somewhere within the project, even if through a transitive dependency.\n\n If the `-i,--interactive` option is used (or if the `preferInteractive` settings is toggled on) the command will first try to check whether other workspaces in the project use the specified package and, if so, will offer to reuse them.\n\n If the `--mode=` option is set, Yarn will change which artifacts are generated. The modes currently supported are:\n\n - `skip-build` will not run the build scripts at all. Note that this is different from setting `enableScripts` to false because the later will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run.\n\n - `update-lockfile` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost.\n\n For a compilation of all the supported protocols, please consult the dedicated page from our website: https://yarnpkg.com/features/protocols.\n ",examples:[["Add a regular package to the current workspace","$0 add lodash"],["Add a specific version for a package to the current workspace","$0 add lodash@1.2.3"],["Add a package from a GitHub repository (the master branch) to the current workspace using a URL","$0 add lodash@https://github.com/lodash/lodash"],["Add a package from a GitHub repository (the master branch) to the current workspace using the GitHub protocol","$0 add lodash@github:lodash/lodash"],["Add a package from a GitHub repository (the master branch) to the current workspace using the GitHub protocol (shorthand)","$0 add lodash@lodash/lodash"],["Add a package from a specific branch of a GitHub repository to the current workspace using the GitHub protocol (shorthand)","$0 add lodash-es@lodash/lodash#es"]]});var ioe=cC;function O3e(t,e,{dev:r,peer:i,preferDev:n,optional:s}){let o=t.manifest[vr.REGULAR].has(e.identHash),a=t.manifest[vr.DEVELOPMENT].has(e.identHash),l=t.manifest[vr.PEER].has(e.identHash);if((r||i)&&o)throw new me(`Package "${S.prettyIdent(t.project.configuration,e)}" is already listed as a regular dependency - remove the -D,-P flags or remove it from your dependencies first`);if(!r&&!i&&l)throw new me(`Package "${S.prettyIdent(t.project.configuration,e)}" is already listed as a peer dependency - use either of -D or -P, or remove it from your peer dependencies first`);if(s&&a)throw new me(`Package "${S.prettyIdent(t.project.configuration,e)}" is already listed as a dev dependency - remove the -O flag or remove it from your dev dependencies first`);if(s&&!i&&l)throw new me(`Package "${S.prettyIdent(t.project.configuration,e)}" is already listed as a peer dependency - remove the -O flag or add the -P flag or remove it from your peer dependencies first`);if((r||n)&&s)throw new me(`Package "${S.prettyIdent(t.project.configuration,e)}" cannot simultaneously be a dev dependency and an optional dependency`);return i?vr.PEER:r||n?vr.DEVELOPMENT:o?vr.REGULAR:a?vr.DEVELOPMENT:vr.REGULAR}var uC=class extends Be{constructor(){super(...arguments);this.verbose=Y.Boolean("-v,--verbose",!1,{description:"Print both the binary name and the locator of the package that provides the binary"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.name=Y.String({required:!1})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,locator:i}=await Ke.find(e,this.context.cwd);if(await r.restoreInstallState(),this.name){let o=(await Kt.getPackageAccessibleBinaries(i,{project:r})).get(this.name);if(!o)throw new me(`Couldn't find a binary named "${this.name}" for package "${S.prettyLocator(e,i)}"`);let[,a]=o;return this.context.stdout.write(`${a} -`),0}return(await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout},async s=>{let o=await Kt.getPackageAccessibleBinaries(i,{project:r}),l=Array.from(o.keys()).reduce((c,u)=>Math.max(c,u.length),0);for(let[c,[u,g]]of o)s.reportJson({name:c,source:S.stringifyIdent(u),path:g});if(this.verbose)for(let[c,[u]]of o)s.reportInfo(null,`${c.padEnd(l," ")} ${S.prettyLocator(e,u)}`);else for(let c of o.keys())s.reportInfo(null,c)})).exitCode()}};uC.paths=[["bin"]],uC.usage=ye.Usage({description:"get the path to a binary script",details:` - When used without arguments, this command will print the list of all the binaries available in the current workspace. Adding the \`-v,--verbose\` flag will cause the output to contain both the binary name and the locator of the package that provides the binary. - - When an argument is specified, this command will just print the path to the binary on the standard output and exit. Note that the reported path may be stored within a zip archive. - `,examples:[["List all the available binaries","$0 bin"],["Print the path to a specific binary","$0 bin eslint"]]});var noe=uC;var gC=class extends Be{constructor(){super(...arguments);this.mirror=Y.Boolean("--mirror",!1,{description:"Remove the global cache files instead of the local cache files"});this.all=Y.Boolean("--all",!1,{description:"Remove both the global cache files and the local cache files of the current project"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=await Qt.find(e);return(await Fe.start({configuration:e,stdout:this.context.stdout},async()=>{let n=(this.all||this.mirror)&&r.mirrorCwd!==null,s=!this.mirror;n&&(await T.removePromise(r.mirrorCwd),await e.triggerHook(o=>o.cleanGlobalArtifacts,e)),s&&await T.removePromise(r.cwd)})).exitCode()}};gC.paths=[["cache","clean"],["cache","clear"]],gC.usage=ye.Usage({description:"remove the shared cache files",details:` - This command will remove all the files from the cache. - `,examples:[["Remove all the local archives","$0 cache clean"],["Remove all the archives stored in the ~/.yarn directory","$0 cache clean --mirror"]]});var soe=gC;var ooe=ie(p0()),KN=ie(require("util")),fC=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.unsafe=Y.Boolean("--no-redacted",!1,{description:"Don't redact secrets (such as tokens) from the output"});this.name=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=this.name.replace(/[.[].*$/,""),i=this.name.replace(/^[^.[]*/,"");if(typeof e.settings.get(r)=="undefined")throw new me(`Couldn't find a configuration settings named "${r}"`);let s=e.getSpecial(r,{hideSecrets:!this.unsafe,getNativePaths:!0}),o=de.convertMapsToIndexableObjects(s),a=i?(0,ooe.default)(o,i):o,l=await Fe.start({configuration:e,includeFooter:!1,json:this.json,stdout:this.context.stdout},async c=>{c.reportJson(a)});if(!this.json){if(typeof a=="string")return this.context.stdout.write(`${a} -`),l.exitCode();KN.inspect.styles.name="cyan",this.context.stdout.write(`${(0,KN.inspect)(a,{depth:Infinity,colors:e.get("enableColors"),compact:!1})} -`)}return l.exitCode()}};fC.paths=[["config","get"]],fC.usage=ye.Usage({description:"read a configuration settings",details:` - This command will print a configuration setting. - - Secrets (such as tokens) will be redacted from the output by default. If this behavior isn't desired, set the \`--no-redacted\` to get the untransformed value. - `,examples:[["Print a simple configuration setting","yarn config get yarnPath"],["Print a complex configuration setting","yarn config get packageExtensions"],["Print a nested field from the configuration",`yarn config get 'npmScopes["my-company"].npmRegistryServer'`],["Print a token from the configuration","yarn config get npmAuthToken --no-redacted"],["Print a configuration setting as JSON","yarn config get packageExtensions --json"]]});var aoe=fC;var Eae=ie(qN()),Iae=ie(p0()),yae=ie(mae()),JN=ie(require("util")),pC=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Set complex configuration settings to JSON values"});this.home=Y.Boolean("-H,--home",!1,{description:"Update the home configuration instead of the project configuration"});this.name=Y.String();this.value=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=()=>{if(!e.projectCwd)throw new me("This command must be run from within a project folder");return e.projectCwd},i=this.name.replace(/[.[].*$/,""),n=this.name.replace(/^[^.[]*\.?/,"");if(typeof e.settings.get(i)=="undefined")throw new me(`Couldn't find a configuration settings named "${i}"`);if(i==="enableStrictSettings")throw new me("This setting only affects the file it's in, and thus cannot be set from the CLI");let o=this.json?JSON.parse(this.value):this.value;await(this.home?h=>fe.updateHomeConfiguration(h):h=>fe.updateConfiguration(r(),h))(h=>{if(n){let p=(0,Eae.default)(h);return(0,yae.default)(p,this.name,o),p}else return _(P({},h),{[i]:o})});let c=(await fe.find(this.context.cwd,this.context.plugins)).getSpecial(i,{hideSecrets:!0,getNativePaths:!0}),u=de.convertMapsToIndexableObjects(c),g=n?(0,Iae.default)(u,n):u;return(await Fe.start({configuration:e,includeFooter:!1,stdout:this.context.stdout},async h=>{JN.inspect.styles.name="cyan",h.reportInfo(z.UNNAMED,`Successfully set ${this.name} to ${(0,JN.inspect)(g,{depth:Infinity,colors:e.get("enableColors"),compact:!1})}`)})).exitCode()}};pC.paths=[["config","set"]],pC.usage=ye.Usage({description:"change a configuration settings",details:` - This command will set a configuration setting. - - When used without the \`--json\` flag, it can only set a simple configuration setting (a string, a number, or a boolean). - - When used with the \`--json\` flag, it can set both simple and complex configuration settings, including Arrays and Objects. - `,examples:[["Set a simple configuration setting (a string, a number, or a boolean)","yarn config set initScope myScope"],["Set a simple configuration setting (a string, a number, or a boolean) using the `--json` flag",'yarn config set initScope --json \\"myScope\\"'],["Set a complex configuration setting (an Array) using the `--json` flag",`yarn config set unsafeHttpWhitelist --json '["*.example.com", "example.com"]'`],["Set a complex configuration setting (an Object) using the `--json` flag",`yarn config set packageExtensions --json '{ "@babel/parser@*": { "dependencies": { "@babel/types": "*" } } }'`],["Set a nested configuration setting",'yarn config set npmScopes.company.npmRegistryServer "https://npm.example.com"'],["Set a nested configuration setting using indexed access for non-simple keys",`yarn config set 'npmRegistries["//npm.example.com"].npmAuthToken' "ffffffff-ffff-ffff-ffff-ffffffffffff"`]]});var wae=pC;var Dae=ie(qN()),Rae=ie(Ld()),Fae=ie(Pae()),dC=class extends Be{constructor(){super(...arguments);this.home=Y.Boolean("-H,--home",!1,{description:"Update the home configuration instead of the project configuration"});this.name=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=()=>{if(!e.projectCwd)throw new me("This command must be run from within a project folder");return e.projectCwd},i=this.name.replace(/[.[].*$/,""),n=this.name.replace(/^[^.[]*\.?/,"");if(typeof e.settings.get(i)=="undefined")throw new me(`Couldn't find a configuration settings named "${i}"`);let o=this.home?l=>fe.updateHomeConfiguration(l):l=>fe.updateConfiguration(r(),l);return(await Fe.start({configuration:e,includeFooter:!1,stdout:this.context.stdout},async l=>{let c=!1;await o(u=>{if(!(0,Rae.default)(u,this.name))return l.reportWarning(z.UNNAMED,`Configuration doesn't contain setting ${this.name}; there is nothing to unset`),c=!0,u;let g=n?(0,Dae.default)(u):P({},u);return(0,Fae.default)(g,this.name),g}),c||l.reportInfo(z.UNNAMED,`Successfully unset ${this.name}`)})).exitCode()}};dC.paths=[["config","unset"]],dC.usage=ye.Usage({description:"unset a configuration setting",details:` - This command will unset a configuration setting. - `,examples:[["Unset a simple configuration setting","yarn config unset initScope"],["Unset a complex configuration setting","yarn config unset packageExtensions"],["Unset a nested configuration setting","yarn config unset npmScopes.company.npmRegistryServer"]]});var Nae=dC;var WN=ie(require("util")),CC=class extends Be{constructor(){super(...arguments);this.verbose=Y.Boolean("-v,--verbose",!1,{description:"Print the setting description on top of the regular key/value information"});this.why=Y.Boolean("--why",!1,{description:"Print the reason why a setting is set a particular way"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins,{strict:!1});return(await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout},async i=>{if(e.invalid.size>0&&!this.json){for(let[n,s]of e.invalid)i.reportError(z.INVALID_CONFIGURATION_KEY,`Invalid configuration key "${n}" in ${s}`);i.reportSeparator()}if(this.json){let n=de.sortMap(e.settings.keys(),s=>s);for(let s of n){let o=e.settings.get(s),a=e.getSpecial(s,{hideSecrets:!0,getNativePaths:!0}),l=e.sources.get(s);this.verbose?i.reportJson({key:s,effective:a,source:l}):i.reportJson(P({key:s,effective:a,source:l},o))}}else{let n=de.sortMap(e.settings.keys(),a=>a),s=n.reduce((a,l)=>Math.max(a,l.length),0),o={breakLength:Infinity,colors:e.get("enableColors"),maxArrayLength:2};if(this.why||this.verbose){let a=n.map(c=>{let u=e.settings.get(c);if(!u)throw new Error(`Assertion failed: This settings ("${c}") should have been registered`);let g=this.why?e.sources.get(c)||"":u.description;return[c,g]}),l=a.reduce((c,[,u])=>Math.max(c,u.length),0);for(let[c,u]of a)i.reportInfo(null,`${c.padEnd(s," ")} ${u.padEnd(l," ")} ${(0,WN.inspect)(e.getSpecial(c,{hideSecrets:!0,getNativePaths:!0}),o)}`)}else for(let a of n)i.reportInfo(null,`${a.padEnd(s," ")} ${(0,WN.inspect)(e.getSpecial(a,{hideSecrets:!0,getNativePaths:!0}),o)}`)}})).exitCode()}};CC.paths=[["config"]],CC.usage=ye.Usage({description:"display the current configuration",details:` - This command prints the current active configuration settings. - `,examples:[["Print the active configuration settings","$0 config"]]});var Lae=CC;Ss();var zN={};it(zN,{Strategy:()=>Oc,acceptedStrategies:()=>H4e,dedupe:()=>VN});var Tae=ie(Nn()),Oc;(function(e){e.HIGHEST="highest"})(Oc||(Oc={}));var H4e=new Set(Object.values(Oc)),G4e={highest:async(t,e,{resolver:r,fetcher:i,resolveOptions:n,fetchOptions:s})=>{let o=new Map;for(let[a,l]of t.storedResolutions){let c=t.storedDescriptors.get(a);if(typeof c=="undefined")throw new Error(`Assertion failed: The descriptor (${a}) should have been registered`);de.getSetWithDefault(o,c.identHash).add(l)}return Array.from(t.storedDescriptors.values(),async a=>{if(e.length&&!Tae.default.isMatch(S.stringifyIdent(a),e))return null;let l=t.storedResolutions.get(a.descriptorHash);if(typeof l=="undefined")throw new Error(`Assertion failed: The resolution (${a.descriptorHash}) should have been registered`);let c=t.originalPackages.get(l);if(typeof c=="undefined"||!r.shouldPersistResolution(c,n))return null;let u=o.get(a.identHash);if(typeof u=="undefined")throw new Error(`Assertion failed: The resolutions (${a.identHash}) should have been registered`);if(u.size===1)return null;let g=[...u].map(m=>{let I=t.originalPackages.get(m);if(typeof I=="undefined")throw new Error(`Assertion failed: The package (${m}) should have been registered`);return I.reference}),f=await r.getSatisfying(a,g,n),h=f==null?void 0:f[0];if(typeof h=="undefined")return null;let p=h.locatorHash,d=t.originalPackages.get(p);if(typeof d=="undefined")throw new Error(`Assertion failed: The package (${p}) should have been registered`);return p===l?null:{descriptor:a,currentPackage:c,updatedPackage:d}})}};async function VN(t,{strategy:e,patterns:r,cache:i,report:n}){let{configuration:s}=t,o=new ei,a=s.makeResolver(),l=s.makeFetcher(),c={cache:i,checksums:t.storedChecksums,fetcher:l,project:t,report:o,skipIntegrityCheck:!0,cacheOptions:{skipIntegrityCheck:!0}},u={project:t,resolver:a,report:o,fetchOptions:c};return await n.startTimerPromise("Deduplication step",async()=>{let f=await G4e[e](t,r,{resolver:a,resolveOptions:u,fetcher:l,fetchOptions:c}),h=Xi.progressViaCounter(f.length);n.reportProgress(h);let p=0;await Promise.all(f.map(I=>I.then(B=>{if(B===null)return;p++;let{descriptor:b,currentPackage:R,updatedPackage:H}=B;n.reportInfo(z.UNNAMED,`${S.prettyDescriptor(s,b)} can be deduped from ${S.prettyLocator(s,R)} to ${S.prettyLocator(s,H)}`),n.reportJson({descriptor:S.stringifyDescriptor(b),currentResolution:S.stringifyLocator(R),updatedResolution:S.stringifyLocator(H)}),t.storedResolutions.set(b.descriptorHash,H.locatorHash)}).finally(()=>h.tick())));let d;switch(p){case 0:d="No packages";break;case 1:d="One package";break;default:d=`${p} packages`}let m=ue.pretty(s,e,ue.Type.CODE);return n.reportInfo(z.UNNAMED,`${d} can be deduped using the ${m} strategy`),p})}var mC=class extends Be{constructor(){super(...arguments);this.strategy=Y.String("-s,--strategy",Oc.HIGHEST,{description:"The strategy to use when deduping dependencies",validator:Yi(Oc)});this.check=Y.Boolean("-c,--check",!1,{description:"Exit with exit code 1 when duplicates are found, without persisting the dependency tree"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.mode=Y.String("--mode",{description:"Change what artifacts installs generate",validator:Yi(li)});this.patterns=Y.Rest()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r}=await Ke.find(e,this.context.cwd),i=await Qt.find(e);await r.restoreInstallState({restoreResolutions:!1});let n=0,s=await Fe.start({configuration:e,includeFooter:!1,stdout:this.context.stdout,json:this.json},async o=>{n=await VN(r,{strategy:this.strategy,patterns:this.patterns,cache:i,report:o})});return s.hasErrors()?s.exitCode():this.check?n?1:0:(await Fe.start({configuration:e,stdout:this.context.stdout,json:this.json},async a=>{await r.install({cache:i,report:a,mode:this.mode})})).exitCode()}};mC.paths=[["dedupe"]],mC.usage=ye.Usage({description:"deduplicate dependencies with overlapping ranges",details:"\n Duplicates are defined as descriptors with overlapping ranges being resolved and locked to different locators. They are a natural consequence of Yarn's deterministic installs, but they can sometimes pile up and unnecessarily increase the size of your project.\n\n This command dedupes dependencies in the current project using different strategies (only one is implemented at the moment):\n\n - `highest`: Reuses (where possible) the locators with the highest versions. This means that dependencies can only be upgraded, never downgraded. It's also guaranteed that it never takes more than a single pass to dedupe the entire dependency tree.\n\n **Note:** Even though it never produces a wrong dependency tree, this command should be used with caution, as it modifies the dependency tree, which can sometimes cause problems when packages don't strictly follow semver recommendations. Because of this, it is recommended to also review the changes manually.\n\n If set, the `-c,--check` flag will only report the found duplicates, without persisting the modified dependency tree. If changes are found, the command will exit with a non-zero exit code, making it suitable for CI purposes.\n\n If the `--mode=` option is set, Yarn will change which artifacts are generated. The modes currently supported are:\n\n - `skip-build` will not run the build scripts at all. Note that this is different from setting `enableScripts` to false because the later will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run.\n\n - `update-lockfile` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost.\n\n This command accepts glob patterns as arguments (if valid Idents and supported by [micromatch](https://github.com/micromatch/micromatch)). Make sure to escape the patterns, to prevent your own shell from trying to expand them.\n\n ### In-depth explanation:\n\n Yarn doesn't deduplicate dependencies by default, otherwise installs wouldn't be deterministic and the lockfile would be useless. What it actually does is that it tries to not duplicate dependencies in the first place.\n\n **Example:** If `foo@^2.3.4` (a dependency of a dependency) has already been resolved to `foo@2.3.4`, running `yarn add foo@*`will cause Yarn to reuse `foo@2.3.4`, even if the latest `foo` is actually `foo@2.10.14`, thus preventing unnecessary duplication.\n\n Duplication happens when Yarn can't unlock dependencies that have already been locked inside the lockfile.\n\n **Example:** If `foo@^2.3.4` (a dependency of a dependency) has already been resolved to `foo@2.3.4`, running `yarn add foo@2.10.14` will cause Yarn to install `foo@2.10.14` because the existing resolution doesn't satisfy the range `2.10.14`. This behavior can lead to (sometimes) unwanted duplication, since now the lockfile contains 2 separate resolutions for the 2 `foo` descriptors, even though they have overlapping ranges, which means that the lockfile can be simplified so that both descriptors resolve to `foo@2.10.14`.\n ",examples:[["Dedupe all packages","$0 dedupe"],["Dedupe all packages using a specific strategy","$0 dedupe --strategy highest"],["Dedupe a specific package","$0 dedupe lodash"],["Dedupe all packages with the `@babel/*` scope","$0 dedupe '@babel/*'"],["Check for duplicates (can be used as a CI step)","$0 dedupe --check"]]});var Mae=mC;var Y0=class extends Be{async execute(){let{plugins:e}=await fe.find(this.context.cwd,this.context.plugins),r=[];for(let o of e){let{commands:a}=o[1];if(a){let c=oo.from(a).definitions();r.push([o[0],c])}}let i=this.cli.definitions(),n=(o,a)=>o.split(" ").slice(1).join()===a.split(" ").slice(1).join(),s=Kae()["@yarnpkg/builder"].bundles.standard;for(let o of r){let a=o[1];for(let l of a)i.find(c=>n(c.path,l.path)).plugin={name:o[0],isDefault:s.includes(o[0])}}this.context.stdout.write(`${JSON.stringify(i,null,2)} -`)}};Y0.paths=[["--clipanion=definitions"]];var Uae=Y0;var q0=class extends Be{async execute(){this.context.stdout.write(this.cli.usage(null))}};q0.paths=[["help"],["--help"],["-h"]];var Hae=q0;var _N=class extends Be{constructor(){super(...arguments);this.leadingArgument=Y.String();this.args=Y.Proxy()}async execute(){if(this.leadingArgument.match(/[\\/]/)&&!S.tryParseIdent(this.leadingArgument)){let e=v.resolve(this.context.cwd,M.toPortablePath(this.leadingArgument));return await this.cli.run(this.args,{cwd:e})}else return await this.cli.run(["run",this.leadingArgument,...this.args])}},Gae=_N;var J0=class extends Be{async execute(){this.context.stdout.write(`${Zr||""} -`)}};J0.paths=[["-v"],["--version"]];var jae=J0;var EC=class extends Be{constructor(){super(...arguments);this.commandName=Y.String();this.args=Y.Proxy()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,locator:i}=await Ke.find(e,this.context.cwd);return await r.restoreInstallState(),await Kt.executePackageShellcode(i,this.commandName,this.args,{cwd:this.context.cwd,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr,project:r})}};EC.paths=[["exec"]],EC.usage=ye.Usage({description:"execute a shell script",details:` - This command simply executes a shell script within the context of the root directory of the active workspace using the portable shell. - - It also makes sure to call it in a way that's compatible with the current project (for example, on PnP projects the environment will be setup in such a way that PnP will be correctly injected into the environment). - `,examples:[["Execute a single shell command","$0 exec echo Hello World"],["Execute a shell script",'$0 exec "tsc & babel src --out-dir lib"']]});var Yae=EC;Ss();var IC=class extends Be{constructor(){super(...arguments);this.hash=Y.String({required:!1,validator:fv(gv(),[hv(/^p[0-9a-f]{5}$/)])})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r}=await Ke.find(e,this.context.cwd);return await r.restoreInstallState({restoreResolutions:!1}),await r.applyLightResolution(),typeof this.hash!="undefined"?await j4e(this.hash,r,{stdout:this.context.stdout}):(await Fe.start({configuration:e,stdout:this.context.stdout,includeFooter:!1},async n=>{var o;let s=[([,a])=>S.stringifyLocator(r.storedPackages.get(a.subject)),([,a])=>S.stringifyIdent(a.requested)];for(let[a,l]of de.sortMap(r.peerRequirements,s)){let c=r.storedPackages.get(l.subject);if(typeof c=="undefined")throw new Error("Assertion failed: Expected the subject package to have been registered");let u=r.storedPackages.get(l.rootRequester);if(typeof u=="undefined")throw new Error("Assertion failed: Expected the root package to have been registered");let g=(o=c.dependencies.get(l.requested.identHash))!=null?o:null,f=ue.pretty(e,a,ue.Type.CODE),h=S.prettyLocator(e,c),p=S.prettyIdent(e,l.requested),d=S.prettyIdent(e,u),m=l.allRequesters.length-1,I=`descendant${m===1?"":"s"}`,B=m>0?` and ${m} ${I}`:"",b=g!==null?"provides":"doesn't provide";n.reportInfo(null,`${f} \u2192 ${h} ${b} ${p} to ${d}${B}`)}})).exitCode()}};IC.paths=[["explain","peer-requirements"]],IC.usage=ye.Usage({description:"explain a set of peer requirements",details:` - A set of peer requirements represents all peer requirements that a dependent must satisfy when providing a given peer request to a requester and its descendants. - - When the hash argument is specified, this command prints a detailed explanation of all requirements of the set corresponding to the hash and whether they're satisfied or not. - - When used without arguments, this command lists all sets of peer requirements and the corresponding hash that can be used to get detailed information about a given set. - - **Note:** A hash is a six-letter p-prefixed code that can be obtained from peer dependency warnings or from the list of all peer requirements (\`yarn explain peer-requirements\`). - `,examples:[["Explain the corresponding set of peer requirements for a hash","$0 explain peer-requirements p1a4ed"],["List all sets of peer requirements","$0 explain peer-requirements"]]});var qae=IC;async function j4e(t,e,r){let{configuration:i}=e,n=e.peerRequirements.get(t);if(typeof n=="undefined")throw new Error(`No peerDependency requirements found for hash: "${t}"`);return(await Fe.start({configuration:i,stdout:r.stdout,includeFooter:!1},async o=>{var I,B;let a=e.storedPackages.get(n.subject);if(typeof a=="undefined")throw new Error("Assertion failed: Expected the subject package to have been registered");let l=e.storedPackages.get(n.rootRequester);if(typeof l=="undefined")throw new Error("Assertion failed: Expected the root package to have been registered");let c=(I=a.dependencies.get(n.requested.identHash))!=null?I:null,u=c!==null?e.storedResolutions.get(c.descriptorHash):null;if(typeof u=="undefined")throw new Error("Assertion failed: Expected the resolution to have been registered");let g=u!==null?e.storedPackages.get(u):null;if(typeof g=="undefined")throw new Error("Assertion failed: Expected the provided package to have been registered");let f=[...n.allRequesters.values()].map(b=>{let R=e.storedPackages.get(b);if(typeof R=="undefined")throw new Error("Assertion failed: Expected the package to be registered");let H=S.devirtualizeLocator(R),L=e.storedPackages.get(H.locatorHash);if(typeof L=="undefined")throw new Error("Assertion failed: Expected the package to be registered");let K=L.peerDependencies.get(n.requested.identHash);if(typeof K=="undefined")throw new Error("Assertion failed: Expected the peer dependency to be registered");return{pkg:R,peerDependency:K}});if(g!==null){let b=f.every(({peerDependency:R})=>qt.satisfiesWithPrereleases(g.version,R.range));o.reportInfo(z.UNNAMED,`${S.prettyLocator(i,a)} provides ${S.prettyLocator(i,g)} with version ${S.prettyReference(i,(B=g.version)!=null?B:"")}, which ${b?"satisfies":"doesn't satisfy"} the following requirements:`)}else o.reportInfo(z.UNNAMED,`${S.prettyLocator(i,a)} doesn't provide ${S.prettyIdent(i,n.requested)}, breaking the following requirements:`);o.reportSeparator();let h=ue.mark(i),p=[];for(let{pkg:b,peerDependency:R}of de.sortMap(f,H=>S.stringifyLocator(H.pkg))){let L=(g!==null?qt.satisfiesWithPrereleases(g.version,R.range):!1)?h.Check:h.Cross;p.push({stringifiedLocator:S.stringifyLocator(b),prettyLocator:S.prettyLocator(i,b),prettyRange:S.prettyRange(i,R.range),mark:L})}let d=Math.max(...p.map(({stringifiedLocator:b})=>b.length)),m=Math.max(...p.map(({prettyRange:b})=>b.length));for(let{stringifiedLocator:b,prettyLocator:R,prettyRange:H,mark:L}of de.sortMap(p,({stringifiedLocator:K})=>K))o.reportInfo(null,`${R.padEnd(d+(R.length-b.length)," ")} \u2192 ${H.padEnd(m," ")} ${L}`);p.length>1&&(o.reportSeparator(),o.reportInfo(z.UNNAMED,`Note: these requirements start with ${S.prettyLocator(e.configuration,l)}`))})).exitCode()}var Jae=ie(Nn()),yC=class extends Be{constructor(){super(...arguments);this.all=Y.Boolean("-A,--all",!1,{description:"Print versions of a package from the whole project"});this.recursive=Y.Boolean("-R,--recursive",!1,{description:"Print information for all packages, including transitive dependencies"});this.extra=Y.Array("-X,--extra",[],{description:"An array of requests of extra data provided by plugins"});this.cache=Y.Boolean("--cache",!1,{description:"Print information about the cache entry of a package (path, size, checksum)"});this.dependents=Y.Boolean("--dependents",!1,{description:"Print all dependents for each matching package"});this.manifest=Y.Boolean("--manifest",!1,{description:"Print data obtained by looking at the package archive (license, homepage, ...)"});this.nameOnly=Y.Boolean("--name-only",!1,{description:"Only print the name for the matching packages"});this.virtuals=Y.Boolean("--virtuals",!1,{description:"Print each instance of the virtual packages"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.patterns=Y.Rest()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i&&!this.all)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState();let s=new Set(this.extra);this.cache&&s.add("cache"),this.dependents&&s.add("dependents"),this.manifest&&s.add("manifest");let o=(b,{recursive:R})=>{let H=b.anchoredLocator.locatorHash,L=new Map,K=[H];for(;K.length>0;){let J=K.shift();if(L.has(J))continue;let ne=r.storedPackages.get(J);if(typeof ne=="undefined")throw new Error("Assertion failed: Expected the package to be registered");if(L.set(J,ne),S.isVirtualLocator(ne)&&K.push(S.devirtualizeLocator(ne).locatorHash),!(!R&&J!==H))for(let q of ne.dependencies.values()){let A=r.storedResolutions.get(q.descriptorHash);if(typeof A=="undefined")throw new Error("Assertion failed: Expected the resolution to be registered");K.push(A)}}return L.values()},a=({recursive:b})=>{let R=new Map;for(let H of r.workspaces)for(let L of o(H,{recursive:b}))R.set(L.locatorHash,L);return R.values()},l=({all:b,recursive:R})=>b&&R?r.storedPackages.values():b?a({recursive:R}):o(i,{recursive:R}),c=({all:b,recursive:R})=>{let H=l({all:b,recursive:R}),L=this.patterns.map(ne=>{let q=S.parseLocator(ne),A=Jae.default.makeRe(S.stringifyIdent(q)),V=S.isVirtualLocator(q),W=V?S.devirtualizeLocator(q):q;return X=>{let F=S.stringifyIdent(X);if(!A.test(F))return!1;if(q.reference==="unknown")return!0;let D=S.isVirtualLocator(X),he=D?S.devirtualizeLocator(X):X;return!(V&&D&&q.reference!==X.reference||W.reference!==he.reference)}}),K=de.sortMap([...H],ne=>S.stringifyLocator(ne));return{selection:K.filter(ne=>L.length===0||L.some(q=>q(ne))),sortedLookup:K}},{selection:u,sortedLookup:g}=c({all:this.all,recursive:this.recursive});if(u.length===0)throw new me("No package matched your request");let f=new Map;if(this.dependents)for(let b of g)for(let R of b.dependencies.values()){let H=r.storedResolutions.get(R.descriptorHash);if(typeof H=="undefined")throw new Error("Assertion failed: Expected the resolution to be registered");de.getArrayWithDefault(f,H).push(b)}let h=new Map;for(let b of g){if(!S.isVirtualLocator(b))continue;let R=S.devirtualizeLocator(b);de.getArrayWithDefault(h,R.locatorHash).push(b)}let p={},d={children:p},m=e.makeFetcher(),I={project:r,fetcher:m,cache:n,checksums:r.storedChecksums,report:new ei,cacheOptions:{skipIntegrityCheck:!0},skipIntegrityCheck:!0},B=[async(b,R,H)=>{var J,ne;if(!R.has("manifest"))return;let L=await m.fetch(b,I),K;try{K=await Ze.find(L.prefixPath,{baseFs:L.packageFs})}finally{(J=L.releaseFs)==null||J.call(L)}H("Manifest",{License:ue.tuple(ue.Type.NO_HINT,K.license),Homepage:ue.tuple(ue.Type.URL,(ne=K.raw.homepage)!=null?ne:null)})},async(b,R,H)=>{var A;if(!R.has("cache"))return;let L={mockedPackages:r.disabledLocators,unstablePackages:r.conditionalLocators},K=(A=r.storedChecksums.get(b.locatorHash))!=null?A:null,J=n.getLocatorPath(b,K,L),ne;if(J!==null)try{ne=T.statSync(J)}catch{}let q=typeof ne!="undefined"?[ne.size,ue.Type.SIZE]:void 0;H("Cache",{Checksum:ue.tuple(ue.Type.NO_HINT,K),Path:ue.tuple(ue.Type.PATH,J),Size:q})}];for(let b of u){let R=S.isVirtualLocator(b);if(!this.virtuals&&R)continue;let H={},L={value:[b,ue.Type.LOCATOR],children:H};if(p[S.stringifyLocator(b)]=L,this.nameOnly){delete L.children;continue}let K=h.get(b.locatorHash);typeof K!="undefined"&&(H.Instances={label:"Instances",value:ue.tuple(ue.Type.NUMBER,K.length)}),H.Version={label:"Version",value:ue.tuple(ue.Type.NO_HINT,b.version)};let J=(q,A)=>{let V={};if(H[q]=V,Array.isArray(A))V.children=A.map(W=>({value:W}));else{let W={};V.children=W;for(let[X,F]of Object.entries(A))typeof F!="undefined"&&(W[X]={label:X,value:F})}};if(!R){for(let q of B)await q(b,s,J);await e.triggerHook(q=>q.fetchPackageInfo,b,s,J)}b.bin.size>0&&!R&&J("Exported Binaries",[...b.bin.keys()].map(q=>ue.tuple(ue.Type.PATH,q)));let ne=f.get(b.locatorHash);typeof ne!="undefined"&&ne.length>0&&J("Dependents",ne.map(q=>ue.tuple(ue.Type.LOCATOR,q))),b.dependencies.size>0&&!R&&J("Dependencies",[...b.dependencies.values()].map(q=>{var W;let A=r.storedResolutions.get(q.descriptorHash),V=typeof A!="undefined"&&(W=r.storedPackages.get(A))!=null?W:null;return ue.tuple(ue.Type.RESOLUTION,{descriptor:q,locator:V})})),b.peerDependencies.size>0&&R&&J("Peer dependencies",[...b.peerDependencies.values()].map(q=>{var X,F;let A=b.dependencies.get(q.identHash),V=typeof A!="undefined"&&(X=r.storedResolutions.get(A.descriptorHash))!=null?X:null,W=V!==null&&(F=r.storedPackages.get(V))!=null?F:null;return ue.tuple(ue.Type.RESOLUTION,{descriptor:q,locator:W})}))}Hs.emitTree(d,{configuration:e,json:this.json,stdout:this.context.stdout,separators:this.nameOnly?0:2})}};yC.paths=[["info"]],yC.usage=ye.Usage({description:"see information related to packages",details:"\n This command prints various information related to the specified packages, accepting glob patterns.\n\n By default, if the locator reference is missing, Yarn will default to print the information about all the matching direct dependencies of the package for the active workspace. To instead print all versions of the package that are direct dependencies of any of your workspaces, use the `-A,--all` flag. Adding the `-R,--recursive` flag will also report transitive dependencies.\n\n Some fields will be hidden by default in order to keep the output readable, but can be selectively displayed by using additional options (`--dependents`, `--manifest`, `--virtuals`, ...) described in the option descriptions.\n\n Note that this command will only print the information directly related to the selected packages - if you wish to know why the package is there in the first place, use `yarn why` which will do just that (it also provides a `-R,--recursive` flag that may be of some help).\n ",examples:[["Show information about Lodash","$0 info lodash"]]});var Wae=yC;var W0=ie(ml());Ss();var wC=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.immutable=Y.Boolean("--immutable",{description:"Abort with an error exit code if the lockfile was to be modified"});this.immutableCache=Y.Boolean("--immutable-cache",{description:"Abort with an error exit code if the cache folder was to be modified"});this.checkCache=Y.Boolean("--check-cache",!1,{description:"Always refetch the packages and ensure that their checksums are consistent"});this.inlineBuilds=Y.Boolean("--inline-builds",{description:"Verbosely print the output of the build steps of dependencies"});this.mode=Y.String("--mode",{description:"Change what artifacts installs generate",validator:Yi(li)});this.cacheFolder=Y.String("--cache-folder",{hidden:!0});this.frozenLockfile=Y.Boolean("--frozen-lockfile",{hidden:!0});this.ignoreEngines=Y.Boolean("--ignore-engines",{hidden:!0});this.nonInteractive=Y.Boolean("--non-interactive",{hidden:!0});this.preferOffline=Y.Boolean("--prefer-offline",{hidden:!0});this.production=Y.Boolean("--production",{hidden:!0});this.registry=Y.String("--registry",{hidden:!0});this.silent=Y.Boolean("--silent",{hidden:!0});this.networkTimeout=Y.String("--network-timeout",{hidden:!0})}async execute(){var c;let e=await fe.find(this.context.cwd,this.context.plugins);typeof this.inlineBuilds!="undefined"&&e.useWithSource("",{enableInlineBuilds:this.inlineBuilds},e.startingCwd,{overwrite:!0});let r=!!process.env.FUNCTION_TARGET||!!process.env.GOOGLE_RUNTIME,i=async(u,{error:g})=>{let f=await Fe.start({configuration:e,stdout:this.context.stdout,includeFooter:!1},async h=>{g?h.reportError(z.DEPRECATED_CLI_SETTINGS,u):h.reportWarning(z.DEPRECATED_CLI_SETTINGS,u)});return f.hasErrors()?f.exitCode():null};if(typeof this.ignoreEngines!="undefined"){let u=await i("The --ignore-engines option is deprecated; engine checking isn't a core feature anymore",{error:!W0.default.VERCEL});if(u!==null)return u}if(typeof this.registry!="undefined"){let u=await i("The --registry option is deprecated; prefer setting npmRegistryServer in your .yarnrc.yml file",{error:!1});if(u!==null)return u}if(typeof this.preferOffline!="undefined"){let u=await i("The --prefer-offline flag is deprecated; use the --cached flag with 'yarn add' instead",{error:!W0.default.VERCEL});if(u!==null)return u}if(typeof this.production!="undefined"){let u=await i("The --production option is deprecated on 'install'; use 'yarn workspaces focus' instead",{error:!0});if(u!==null)return u}if(typeof this.nonInteractive!="undefined"){let u=await i("The --non-interactive option is deprecated",{error:!r});if(u!==null)return u}if(typeof this.frozenLockfile!="undefined"&&(await i("The --frozen-lockfile option is deprecated; use --immutable and/or --immutable-cache instead",{error:!1}),this.immutable=this.frozenLockfile),typeof this.cacheFolder!="undefined"){let u=await i("The cache-folder option has been deprecated; use rc settings instead",{error:!W0.default.NETLIFY});if(u!==null)return u}let n=(c=this.immutable)!=null?c:e.get("enableImmutableInstalls");if(e.projectCwd!==null){let u=await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout,includeFooter:!1},async g=>{await Y4e(e,n)&&(g.reportInfo(z.AUTOMERGE_SUCCESS,"Automatically fixed merge conflicts \u{1F44D}"),g.reportSeparator())});if(u.hasErrors())return u.exitCode()}if(e.projectCwd!==null&&typeof e.sources.get("nodeLinker")=="undefined"){let u=e.projectCwd,g;try{g=await T.readFilePromise(v.join(u,wt.lockfile),"utf8")}catch{}if(g==null?void 0:g.includes("yarn lockfile v1")){let f=await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout,includeFooter:!1},async h=>{h.reportInfo(z.AUTO_NM_SUCCESS,"Migrating from Yarn 1; automatically enabling the compatibility node-modules linker \u{1F44D}"),h.reportSeparator(),e.use("",{nodeLinker:"node-modules"},u,{overwrite:!0}),await fe.updateConfiguration(u,{nodeLinker:"node-modules"})});if(f.hasErrors())return f.exitCode()}}if(e.projectCwd!==null){let u=await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout,includeFooter:!1},async g=>{var f;((f=fe.telemetry)==null?void 0:f.isNew)&&(g.reportInfo(z.TELEMETRY_NOTICE,"Yarn will periodically gather anonymous telemetry: https://yarnpkg.com/advanced/telemetry"),g.reportInfo(z.TELEMETRY_NOTICE,`Run ${ue.pretty(e,"yarn config set --home enableTelemetry 0",ue.Type.CODE)} to disable`),g.reportSeparator())});if(u.hasErrors())return u.exitCode()}let{project:s,workspace:o}=await Ke.find(e,this.context.cwd),a=await Qt.find(e,{immutable:this.immutableCache,check:this.checkCache});if(!o)throw new rt(s.cwd,this.context.cwd);return await s.restoreInstallState({restoreResolutions:!1}),(await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout,includeLogs:!0},async u=>{await s.install({cache:a,report:u,immutable:n,mode:this.mode})})).exitCode()}};wC.paths=[["install"],ye.Default],wC.usage=ye.Usage({description:"install the project dependencies",details:` - This command sets up your project if needed. The installation is split into four different steps that each have their own characteristics: - - - **Resolution:** First the package manager will resolve your dependencies. The exact way a dependency version is privileged over another isn't standardized outside of the regular semver guarantees. If a package doesn't resolve to what you would expect, check that all dependencies are correctly declared (also check our website for more information: ). - - - **Fetch:** Then we download all the dependencies if needed, and make sure that they're all stored within our cache (check the value of \`cacheFolder\` in \`yarn config\` to see where the cache files are stored). - - - **Link:** Then we send the dependency tree information to internal plugins tasked with writing them on the disk in some form (for example by generating the .pnp.cjs file you might know). - - - **Build:** Once the dependency tree has been written on the disk, the package manager will now be free to run the build scripts for all packages that might need it, in a topological order compatible with the way they depend on one another. See https://yarnpkg.com/advanced/lifecycle-scripts for detail. - - Note that running this command is not part of the recommended workflow. Yarn supports zero-installs, which means that as long as you store your cache and your .pnp.cjs file inside your repository, everything will work without requiring any install right after cloning your repository or switching branches. - - If the \`--immutable\` option is set (defaults to true on CI), Yarn will abort with an error exit code if the lockfile was to be modified (other paths can be added using the \`immutablePatterns\` configuration setting). For backward compatibility we offer an alias under the name of \`--frozen-lockfile\`, but it will be removed in a later release. - - If the \`--immutable-cache\` option is set, Yarn will abort with an error exit code if the cache folder was to be modified (either because files would be added, or because they'd be removed). - - If the \`--check-cache\` option is set, Yarn will always refetch the packages and will ensure that their checksum matches what's 1/ described in the lockfile 2/ inside the existing cache files (if present). This is recommended as part of your CI workflow if you're both following the Zero-Installs model and accepting PRs from third-parties, as they'd otherwise have the ability to alter the checked-in packages before submitting them. - - If the \`--inline-builds\` option is set, Yarn will verbosely print the output of the build steps of your dependencies (instead of writing them into individual files). This is likely useful mostly for debug purposes only when using Docker-like environments. - - If the \`--mode=\` option is set, Yarn will change which artifacts are generated. The modes currently supported are: - - - \`skip-build\` will not run the build scripts at all. Note that this is different from setting \`enableScripts\` to false because the later will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run. - - - \`update-lockfile\` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost. - `,examples:[["Install the project","$0 install"],["Validate a project when using Zero-Installs","$0 install --immutable --immutable-cache"],["Validate a project when using Zero-Installs (slightly safer if you accept external PRs)","$0 install --immutable --immutable-cache --check-cache"]]});var zae=wC,q4e="|||||||",J4e=">>>>>>>",W4e="=======",Vae="<<<<<<<";async function Y4e(t,e){if(!t.projectCwd)return!1;let r=v.join(t.projectCwd,t.get("lockfileFilename"));if(!await T.existsPromise(r))return!1;let i=await T.readFilePromise(r,"utf8");if(!i.includes(Vae))return!1;if(e)throw new nt(z.AUTOMERGE_IMMUTABLE,"Cannot autofix a lockfile when running an immutable install");let[n,s]=z4e(i),o,a;try{o=Ii(n),a=Ii(s)}catch(c){throw new nt(z.AUTOMERGE_FAILED_TO_PARSE,"The individual variants of the lockfile failed to parse")}let l=P(P({},o),a);for(let[c,u]of Object.entries(l))typeof u=="string"&&delete l[c];return await T.changeFilePromise(r,Qa(l),{automaticNewlines:!0}),!0}function z4e(t){let e=[[],[]],r=t.split(/\r?\n/g),i=!1;for(;r.length>0;){let n=r.shift();if(typeof n=="undefined")throw new Error("Assertion failed: Some lines should remain");if(n.startsWith(Vae)){for(;r.length>0;){let s=r.shift();if(typeof s=="undefined")throw new Error("Assertion failed: Some lines should remain");if(s===W4e){i=!1;break}else if(i||s.startsWith(q4e)){i=!0;continue}else e[0].push(s)}for(;r.length>0;){let s=r.shift();if(typeof s=="undefined")throw new Error("Assertion failed: Some lines should remain");if(s.startsWith(J4e))break;e[1].push(s)}}else e[0].push(n),e[1].push(n)}return[e[0].join(` -`),e[1].join(` -`)]}var BC=class extends Be{constructor(){super(...arguments);this.all=Y.Boolean("-A,--all",!1,{description:"Link all workspaces belonging to the target project to the current one"});this.private=Y.Boolean("-p,--private",!1,{description:"Also link private workspaces belonging to the target project to the current one"});this.relative=Y.Boolean("-r,--relative",!1,{description:"Link workspaces using relative paths instead of absolute paths"});this.destination=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState({restoreResolutions:!1});let s=v.resolve(this.context.cwd,M.toPortablePath(this.destination)),o=await fe.find(s,this.context.plugins,{useRc:!1,strict:!1}),{project:a,workspace:l}=await Ke.find(o,s);if(r.cwd===a.cwd)throw new me("Invalid destination; Can't link the project to itself");if(!l)throw new rt(a.cwd,s);let c=r.topLevelWorkspace,u=[];if(this.all){for(let f of a.workspaces)f.manifest.name&&(!f.manifest.private||this.private)&&u.push(f);if(u.length===0)throw new me("No workspace found to be linked in the target project")}else{if(!l.manifest.name)throw new me("The target workspace doesn't have a name and thus cannot be linked");if(l.manifest.private&&!this.private)throw new me("The target workspace is marked private - use the --private flag to link it anyway");u.push(l)}for(let f of u){let h=S.stringifyIdent(f.locator),p=this.relative?v.relative(r.cwd,f.cwd):f.cwd;c.manifest.resolutions.push({pattern:{descriptor:{fullName:h}},reference:`portal:${p}`})}return(await Fe.start({configuration:e,stdout:this.context.stdout},async f=>{await r.install({cache:n,report:f})})).exitCode()}};BC.paths=[["link"]],BC.usage=ye.Usage({description:"connect the local project to another one",details:"\n This command will set a new `resolutions` field in the project-level manifest and point it to the workspace at the specified location (even if part of another project).\n ",examples:[["Register a remote workspace for use in the current project","$0 link ~/ts-loader"],["Register all workspaces from a remote project for use in the current project","$0 link ~/jest --all"]]});var _ae=BC;var QC=class extends Be{constructor(){super(...arguments);this.args=Y.Proxy()}async execute(){return this.cli.run(["exec","node",...this.args])}};QC.paths=[["node"]],QC.usage=ye.Usage({description:"run node with the hook already setup",details:` - This command simply runs Node. It also makes sure to call it in a way that's compatible with the current project (for example, on PnP projects the environment will be setup in such a way that PnP will be correctly injected into the environment). - - The Node process will use the exact same version of Node as the one used to run Yarn itself, which might be a good way to ensure that your commands always use a consistent Node version. - `,examples:[["Run a Node script","$0 node ./my-script.js"]]});var Xae=QC;var lAe=ie(require("os"));var rAe=ie(require("os"));var V4e="https://raw.githubusercontent.com/yarnpkg/berry/master/plugins.yml";async function Kc(t){let e=await Zt.get(V4e,{configuration:t});return Ii(e.toString())}var bC=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins);return(await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout},async i=>{let n=await Kc(e);for(let s of Object.entries(n)){let[l,o]=s,a=o,{experimental:c}=a,u=qr(a,["experimental"]);let g=l;c&&(g+=" [experimental]"),i.reportJson(P({name:l,experimental:c},u)),i.reportInfo(null,g)}})).exitCode()}};bC.paths=[["plugin","list"]],bC.usage=ye.Usage({category:"Plugin-related commands",description:"list the available official plugins",details:"\n This command prints the plugins available directly from the Yarn repository. Only those plugins can be referenced by name in `yarn plugin import`.\n ",examples:[["List the official plugins","$0 plugin list"]]});var Zae=bC;var $ae=ie(Or()),vC=class extends Be{constructor(){super(...arguments);this.onlyIfNeeded=Y.Boolean("--only-if-needed",!1,{description:"Only lock the Yarn version if it isn't already locked"});this.version=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins);if(e.get("yarnPath")&&this.onlyIfNeeded)return 0;let r=()=>{if(typeof Zr=="undefined")throw new me("The --install flag can only be used without explicit version specifier from the Yarn CLI");return`file://${process.argv[1]}`},i;if(this.version==="self")i=r();else if(this.version==="latest"||this.version==="berry"||this.version==="stable")i=`https://repo.yarnpkg.com/${await eAe(e,"stable")}/packages/yarnpkg-cli/bin/yarn.js`;else if(this.version==="canary")i=`https://repo.yarnpkg.com/${await eAe(e,"canary")}/packages/yarnpkg-cli/bin/yarn.js`;else if(this.version==="classic")i="https://nightly.yarnpkg.com/latest.js";else if(this.version.match(/^\.{0,2}[\\/]/)||M.isAbsolute(this.version))i=`file://${M.resolve(this.version)}`;else if(qt.satisfiesWithPrereleases(this.version,">=2.0.0"))i=`https://repo.yarnpkg.com/${this.version}/packages/yarnpkg-cli/bin/yarn.js`;else if(qt.satisfiesWithPrereleases(this.version,"^0.x || ^1.x"))i=`https://github.com/yarnpkg/yarn/releases/download/v${this.version}/yarn-${this.version}.js`;else if(qt.validRange(this.version))i=`https://repo.yarnpkg.com/${await _4e(e,this.version)}/packages/yarnpkg-cli/bin/yarn.js`;else throw new me(`Invalid version descriptor "${this.version}"`);return(await Fe.start({configuration:e,stdout:this.context.stdout,includeLogs:!this.context.quiet},async s=>{let o="file://",a;i.startsWith(o)?(s.reportInfo(z.UNNAMED,`Downloading ${ue.pretty(e,i,ps.URL)}`),a=await T.readFilePromise(M.toPortablePath(i.slice(o.length)))):(s.reportInfo(z.UNNAMED,`Retrieving ${ue.pretty(e,i,ps.PATH)}`),a=await Zt.get(i,{configuration:e})),await XN(e,null,a,{report:s})})).exitCode()}};vC.paths=[["set","version"]],vC.usage=ye.Usage({description:"lock the Yarn version used by the project",details:"\n This command will download a specific release of Yarn directly from the Yarn GitHub repository, will store it inside your project, and will change the `yarnPath` settings from your project `.yarnrc.yml` file to point to the new file.\n\n A very good use case for this command is to enforce the version of Yarn used by the any single member of your team inside a same project - by doing this you ensure that you have control on Yarn upgrades and downgrades (including on your deployment servers), and get rid of most of the headaches related to someone using a slightly different version and getting a different behavior than you.\n\n The version specifier can be:\n\n - a tag:\n - `latest` / `berry` / `stable` -> the most recent stable berry (`>=2.0.0`) release\n - `canary` -> the most recent canary (release candidate) berry (`>=2.0.0`) release\n - `classic` -> the most recent classic (`^0.x || ^1.x`) release\n\n - a semver range (e.g. `2.x`) -> the most recent version satisfying the range (limited to berry releases)\n\n - a semver version (e.g. `2.4.1`, `1.22.1`)\n\n - a local file referenced through either a relative or absolute path\n\n - `self` -> the version used to invoke the command\n ",examples:[["Download the latest release from the Yarn repository","$0 set version latest"],["Download the latest canary release from the Yarn repository","$0 set version canary"],["Download the latest classic release from the Yarn repository","$0 set version classic"],["Download the most recent Yarn 3 build","$0 set version 3.x"],["Download a specific Yarn 2 build","$0 set version 2.0.0-rc.30"],["Switch back to a specific Yarn 1 release","$0 set version 1.22.1"],["Use a release from the local filesystem","$0 set version ./yarn.cjs"],["Download the version used to invoke the command","$0 set version self"]]});var tAe=vC;async function _4e(t,e){let i=(await Zt.get("https://repo.yarnpkg.com/tags",{configuration:t,jsonResponse:!0})).tags.filter(n=>qt.satisfiesWithPrereleases(n,e));if(i.length===0)throw new me(`No matching release found for range ${ue.pretty(t,e,ue.Type.RANGE)}.`);return i[0]}async function eAe(t,e){let r=await Zt.get("https://repo.yarnpkg.com/tags",{configuration:t,jsonResponse:!0});if(!r.latest[e])throw new me(`Tag ${ue.pretty(t,e,ue.Type.RANGE)} not found`);return r.latest[e]}async function XN(t,e,r,{report:i}){var g;e===null&&await T.mktempPromise(async f=>{let h=v.join(f,"yarn.cjs");await T.writeFilePromise(h,r);let{stdout:p}=await hr.execvp(process.execPath,[M.fromPortablePath(h),"--version"],{cwd:f,env:_(P({},process.env),{YARN_IGNORE_PATH:"1"})});if(e=p.trim(),!$ae.default.valid(e))throw new Error(`Invalid semver version. ${ue.pretty(t,"yarn --version",ue.Type.CODE)} returned: -${e}`)});let n=(g=t.projectCwd)!=null?g:t.startingCwd,s=v.resolve(n,".yarn/releases"),o=v.resolve(s,`yarn-${e}.cjs`),a=v.relative(t.startingCwd,o),l=v.relative(n,o),c=t.get("yarnPath"),u=c===null||c.startsWith(`${s}/`);if(i.reportInfo(z.UNNAMED,`Saving the new release in ${ue.pretty(t,a,"magenta")}`),await T.removePromise(v.dirname(o)),await T.mkdirPromise(v.dirname(o),{recursive:!0}),await T.writeFilePromise(o,r,{mode:493}),u){await fe.updateConfiguration(n,{yarnPath:l});let f=await Ze.tryFind(n)||new Ze;e&&de.isTaggedYarnVersion(e)&&(f.packageManager=`yarn@${e}`);let h={};f.exportTo(h);let p=v.join(n,Ze.fileName),d=`${JSON.stringify(h,null,f.indent)} -`;await T.changeFilePromise(p,d,{automaticNewlines:!0})}}var X4e=/^[0-9]+$/;function iAe(t){return X4e.test(t)?`pull/${t}/head`:t}var Z4e=({repository:t,branch:e},r)=>[["git","init",M.fromPortablePath(r)],["git","remote","add","origin",t],["git","fetch","origin",iAe(e)],["git","reset","--hard","FETCH_HEAD"]],$4e=({branch:t})=>[["git","fetch","origin",iAe(t),"--force"],["git","reset","--hard","FETCH_HEAD"],["git","clean","-dfx"]],eze=({plugins:t,noMinify:e},r)=>[["yarn","build:cli",...new Array().concat(...t.map(i=>["--plugin",v.resolve(r,i)])),...e?["--no-minify"]:[],"|"]],SC=class extends Be{constructor(){super(...arguments);this.installPath=Y.String("--path",{description:"The path where the repository should be cloned to"});this.repository=Y.String("--repository","https://github.com/yarnpkg/berry.git",{description:"The repository that should be cloned"});this.branch=Y.String("--branch","master",{description:"The branch of the repository that should be cloned"});this.plugins=Y.Array("--plugin",[],{description:"An array of additional plugins that should be included in the bundle"});this.noMinify=Y.Boolean("--no-minify",!1,{description:"Build a bundle for development (debugging) - non-minified and non-mangled"});this.force=Y.Boolean("-f,--force",!1,{description:"Always clone the repository instead of trying to fetch the latest commits"});this.skipPlugins=Y.Boolean("--skip-plugins",!1,{description:"Skip updating the contrib plugins"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r}=await Ke.find(e,this.context.cwd),i=typeof this.installPath!="undefined"?v.resolve(this.context.cwd,M.toPortablePath(this.installPath)):v.resolve(M.toPortablePath((0,rAe.tmpdir)()),"yarnpkg-sources",mn.makeHash(this.repository).slice(0,6));return(await Fe.start({configuration:e,stdout:this.context.stdout},async s=>{await $N(this,{configuration:e,report:s,target:i}),s.reportSeparator(),s.reportInfo(z.UNNAMED,"Building a fresh bundle"),s.reportSeparator(),await xC(eze(this,i),{configuration:e,context:this.context,target:i}),s.reportSeparator();let o=v.resolve(i,"packages/yarnpkg-cli/bundles/yarn.js"),a=await T.readFilePromise(o);await XN(e,"sources",a,{report:s}),this.skipPlugins||await tze(this,{project:r,report:s,target:i})})).exitCode()}};SC.paths=[["set","version","from","sources"]],SC.usage=ye.Usage({description:"build Yarn from master",details:` - This command will clone the Yarn repository into a temporary folder, then build it. The resulting bundle will then be copied into the local project. - - By default, it also updates all contrib plugins to the same commit the bundle is built from. This behavior can be disabled by using the \`--skip-plugins\` flag. - `,examples:[["Build Yarn from master","$0 set version from sources"]]});var nAe=SC;async function xC(t,{configuration:e,context:r,target:i}){for(let[n,...s]of t){let o=s[s.length-1]==="|";if(o&&s.pop(),o)await hr.pipevp(n,s,{cwd:i,stdin:r.stdin,stdout:r.stdout,stderr:r.stderr,strict:!0});else{r.stdout.write(`${ue.pretty(e,` $ ${[n,...s].join(" ")}`,"grey")} -`);try{await hr.execvp(n,s,{cwd:i,strict:!0})}catch(a){throw r.stdout.write(a.stdout||a.stack),a}}}}async function $N(t,{configuration:e,report:r,target:i}){let n=!1;if(!t.force&&T.existsSync(v.join(i,".git"))){r.reportInfo(z.UNNAMED,"Fetching the latest commits"),r.reportSeparator();try{await xC($4e(t),{configuration:e,context:t.context,target:i}),n=!0}catch(s){r.reportSeparator(),r.reportWarning(z.UNNAMED,"Repository update failed; we'll try to regenerate it")}}n||(r.reportInfo(z.UNNAMED,"Cloning the remote repository"),r.reportSeparator(),await T.removePromise(i),await T.mkdirPromise(i,{recursive:!0}),await xC(Z4e(t,i),{configuration:e,context:t.context,target:i}))}async function tze(t,{project:e,report:r,target:i}){let n=await Kc(e.configuration),s=new Set(Object.keys(n));for(let o of e.configuration.plugins.keys())!s.has(o)||await ZN(o,t,{project:e,report:r,target:i})}var sAe=ie(Or()),oAe=ie(require("url")),aAe=ie(require("vm"));var kC=class extends Be{constructor(){super(...arguments);this.name=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins);return(await Fe.start({configuration:e,stdout:this.context.stdout},async i=>{let{project:n}=await Ke.find(e,this.context.cwd),s,o;if(this.name.match(/^\.{0,2}[\\/]/)||M.isAbsolute(this.name)){let a=v.resolve(this.context.cwd,M.toPortablePath(this.name));i.reportInfo(z.UNNAMED,`Reading ${ue.pretty(e,a,ue.Type.PATH)}`),s=v.relative(n.cwd,a),o=await T.readFilePromise(a)}else{let a;if(this.name.match(/^https?:/)){try{new oAe.URL(this.name)}catch{throw new nt(z.INVALID_PLUGIN_REFERENCE,`Plugin specifier "${this.name}" is neither a plugin name nor a valid url`)}s=this.name,a=this.name}else{let l=S.parseLocator(this.name.replace(/^((@yarnpkg\/)?plugin-)?/,"@yarnpkg/plugin-"));if(l.reference!=="unknown"&&!sAe.default.valid(l.reference))throw new nt(z.UNNAMED,"Official plugins only accept strict version references. Use an explicit URL if you wish to download them from another location.");let c=S.stringifyIdent(l),u=await Kc(e);if(!Object.prototype.hasOwnProperty.call(u,c))throw new nt(z.PLUGIN_NAME_NOT_FOUND,`Couldn't find a plugin named "${c}" on the remote registry. Note that only the plugins referenced on our website (https://github.com/yarnpkg/berry/blob/master/plugins.yml) can be referenced by their name; any other plugin will have to be referenced through its public url (for example https://github.com/yarnpkg/berry/raw/master/packages/plugin-typescript/bin/%40yarnpkg/plugin-typescript.js).`);s=c,a=u[c].url,l.reference!=="unknown"?a=a.replace(/\/master\//,`/${c}/${l.reference}/`):Zr!==null&&(a=a.replace(/\/master\//,`/@yarnpkg/cli/${Zr}/`))}i.reportInfo(z.UNNAMED,`Downloading ${ue.pretty(e,a,"green")}`),o=await Zt.get(a,{configuration:e})}await eL(s,o,{project:n,report:i})})).exitCode()}};kC.paths=[["plugin","import"]],kC.usage=ye.Usage({category:"Plugin-related commands",description:"download a plugin",details:` - This command downloads the specified plugin from its remote location and updates the configuration to reference it in further CLI invocations. - - Three types of plugin references are accepted: - - - If the plugin is stored within the Yarn repository, it can be referenced by name. - - Third-party plugins can be referenced directly through their public urls. - - Local plugins can be referenced by their path on the disk. - - Plugins cannot be downloaded from the npm registry, and aren't allowed to have dependencies (they need to be bundled into a single file, possibly thanks to the \`@yarnpkg/builder\` package). - `,examples:[['Download and activate the "@yarnpkg/plugin-exec" plugin',"$0 plugin import @yarnpkg/plugin-exec"],['Download and activate the "@yarnpkg/plugin-exec" plugin (shorthand)',"$0 plugin import exec"],["Download and activate a community plugin","$0 plugin import https://example.org/path/to/plugin.js"],["Activate a local plugin","$0 plugin import ./path/to/plugin.js"]]});var AAe=kC;async function eL(t,e,{project:r,report:i}){let{configuration:n}=r,s={},o={exports:s};(0,aAe.runInNewContext)(e.toString(),{module:o,exports:s});let a=o.exports.name,l=`.yarn/plugins/${a}.cjs`,c=v.resolve(r.cwd,l);i.reportInfo(z.UNNAMED,`Saving the new plugin in ${ue.pretty(n,l,"magenta")}`),await T.mkdirPromise(v.dirname(c),{recursive:!0}),await T.writeFilePromise(c,e);let u={path:l,spec:t};await fe.updateConfiguration(r.cwd,g=>{let f=[],h=!1;for(let p of g.plugins||[]){let d=typeof p!="string"?p.path:p,m=v.resolve(r.cwd,M.toPortablePath(d)),{name:I}=de.dynamicRequire(m);I!==a?f.push(p):(f.push(u),h=!0)}return h||f.push(u),_(P({},g),{plugins:f})})}var rze=({pluginName:t,noMinify:e},r)=>[["yarn",`build:${t}`,...e?["--no-minify"]:[],"|"]],PC=class extends Be{constructor(){super(...arguments);this.installPath=Y.String("--path",{description:"The path where the repository should be cloned to"});this.repository=Y.String("--repository","https://github.com/yarnpkg/berry.git",{description:"The repository that should be cloned"});this.branch=Y.String("--branch","master",{description:"The branch of the repository that should be cloned"});this.noMinify=Y.Boolean("--no-minify",!1,{description:"Build a plugin for development (debugging) - non-minified and non-mangled"});this.force=Y.Boolean("-f,--force",!1,{description:"Always clone the repository instead of trying to fetch the latest commits"});this.name=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=typeof this.installPath!="undefined"?v.resolve(this.context.cwd,M.toPortablePath(this.installPath)):v.resolve(M.toPortablePath((0,lAe.tmpdir)()),"yarnpkg-sources",mn.makeHash(this.repository).slice(0,6));return(await Fe.start({configuration:e,stdout:this.context.stdout},async n=>{let{project:s}=await Ke.find(e,this.context.cwd),o=S.parseIdent(this.name.replace(/^((@yarnpkg\/)?plugin-)?/,"@yarnpkg/plugin-")),a=S.stringifyIdent(o),l=await Kc(e);if(!Object.prototype.hasOwnProperty.call(l,a))throw new nt(z.PLUGIN_NAME_NOT_FOUND,`Couldn't find a plugin named "${a}" on the remote registry. Note that only the plugins referenced on our website (https://github.com/yarnpkg/berry/blob/master/plugins.yml) can be built and imported from sources.`);let c=a;await $N(this,{configuration:e,report:n,target:r}),await ZN(c,this,{project:s,report:n,target:r})})).exitCode()}};PC.paths=[["plugin","import","from","sources"]],PC.usage=ye.Usage({category:"Plugin-related commands",description:"build a plugin from sources",details:` - This command clones the Yarn repository into a temporary folder, builds the specified contrib plugin and updates the configuration to reference it in further CLI invocations. - - The plugins can be referenced by their short name if sourced from the official Yarn repository. - `,examples:[['Build and activate the "@yarnpkg/plugin-exec" plugin',"$0 plugin import from sources @yarnpkg/plugin-exec"],['Build and activate the "@yarnpkg/plugin-exec" plugin (shorthand)',"$0 plugin import from sources exec"]]});var cAe=PC;async function ZN(t,{context:e,noMinify:r},{project:i,report:n,target:s}){let o=t.replace(/@yarnpkg\//,""),{configuration:a}=i;n.reportSeparator(),n.reportInfo(z.UNNAMED,`Building a fresh ${o}`),n.reportSeparator(),await xC(rze({pluginName:o,noMinify:r},s),{configuration:a,context:e,target:s}),n.reportSeparator();let l=v.resolve(s,`packages/${o}/bundles/${t}.js`),c=await T.readFilePromise(l);await eL(t,c,{project:i,report:n})}var DC=class extends Be{constructor(){super(...arguments);this.name=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r}=await Ke.find(e,this.context.cwd);return(await Fe.start({configuration:e,stdout:this.context.stdout},async n=>{let s=this.name,o=S.parseIdent(s);if(!e.plugins.has(s))throw new me(`${S.prettyIdent(e,o)} isn't referenced by the current configuration`);let a=`.yarn/plugins/${s}.cjs`,l=v.resolve(r.cwd,a);T.existsSync(l)&&(n.reportInfo(z.UNNAMED,`Removing ${ue.pretty(e,a,ue.Type.PATH)}...`),await T.removePromise(l)),n.reportInfo(z.UNNAMED,"Updating the configuration..."),await fe.updateConfiguration(r.cwd,c=>{if(!Array.isArray(c.plugins))return c;let u=c.plugins.filter(g=>g.path!==a);return c.plugins.length===u.length?c:_(P({},c),{plugins:u})})})).exitCode()}};DC.paths=[["plugin","remove"]],DC.usage=ye.Usage({category:"Plugin-related commands",description:"remove a plugin",details:` - This command deletes the specified plugin from the .yarn/plugins folder and removes it from the configuration. - - **Note:** The plugins have to be referenced by their name property, which can be obtained using the \`yarn plugin runtime\` command. Shorthands are not allowed. - `,examples:[["Remove a plugin imported from the Yarn repository","$0 plugin remove @yarnpkg/plugin-typescript"],["Remove a plugin imported from a local file","$0 plugin remove my-local-plugin"]]});var uAe=DC;var RC=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins);return(await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout},async i=>{for(let n of e.plugins.keys()){let s=this.context.plugins.plugins.has(n),o=n;s&&(o+=" [builtin]"),i.reportJson({name:n,builtin:s}),i.reportInfo(null,`${o}`)}})).exitCode()}};RC.paths=[["plugin","runtime"]],RC.usage=ye.Usage({category:"Plugin-related commands",description:"list the active plugins",details:` - This command prints the currently active plugins. Will be displayed both builtin plugins and external plugins. - `,examples:[["List the currently active plugins","$0 plugin runtime"]]});var gAe=RC;var FC=class extends Be{constructor(){super(...arguments);this.idents=Y.Rest()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);let s=new Set;for(let a of this.idents)s.add(S.parseIdent(a).identHash);if(await r.restoreInstallState({restoreResolutions:!1}),await r.resolveEverything({cache:n,report:new ei}),s.size>0)for(let a of r.storedPackages.values())s.has(a.identHash)&&r.storedBuildState.delete(a.locatorHash);else r.storedBuildState.clear();return(await Fe.start({configuration:e,stdout:this.context.stdout,includeLogs:!this.context.quiet},async a=>{await r.install({cache:n,report:a})})).exitCode()}};FC.paths=[["rebuild"]],FC.usage=ye.Usage({description:"rebuild the project's native packages",details:` - This command will automatically cause Yarn to forget about previous compilations of the given packages and to run them again. - - Note that while Yarn forgets the compilation, the previous artifacts aren't erased from the filesystem and may affect the next builds (in good or bad). To avoid this, you may remove the .yarn/unplugged folder, or any other relevant location where packages might have been stored (Yarn may offer a way to do that automatically in the future). - - By default all packages will be rebuilt, but you can filter the list by specifying the names of the packages you want to clear from memory. - `,examples:[["Rebuild all packages","$0 rebuild"],["Rebuild fsevents only","$0 rebuild fsevents"]]});var fAe=FC;var tL=ie(Nn());Ss();var NC=class extends Be{constructor(){super(...arguments);this.all=Y.Boolean("-A,--all",!1,{description:"Apply the operation to all workspaces from the current project"});this.mode=Y.String("--mode",{description:"Change what artifacts installs generate",validator:Yi(li)});this.patterns=Y.Rest()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState({restoreResolutions:!1});let s=this.all?r.workspaces:[i],o=[vr.REGULAR,vr.DEVELOPMENT,vr.PEER],a=[],l=!1,c=[];for(let h of this.patterns){let p=!1,d=S.parseIdent(h);for(let m of s){let I=[...m.manifest.peerDependenciesMeta.keys()];for(let B of(0,tL.default)(I,h))m.manifest.peerDependenciesMeta.delete(B),l=!0,p=!0;for(let B of o){let b=m.manifest.getForScope(B),R=[...b.values()].map(H=>S.stringifyIdent(H));for(let H of(0,tL.default)(R,S.stringifyIdent(d))){let{identHash:L}=S.parseIdent(H),K=b.get(L);if(typeof K=="undefined")throw new Error("Assertion failed: Expected the descriptor to be registered");m.manifest[B].delete(L),c.push([m,B,K]),l=!0,p=!0}}}p||a.push(h)}let u=a.length>1?"Patterns":"Pattern",g=a.length>1?"don't":"doesn't",f=this.all?"any":"this";if(a.length>0)throw new me(`${u} ${ue.prettyList(e,a,ps.CODE)} ${g} match any packages referenced by ${f} workspace`);return l?(await e.triggerMultipleHooks(p=>p.afterWorkspaceDependencyRemoval,c),(await Fe.start({configuration:e,stdout:this.context.stdout},async p=>{await r.install({cache:n,report:p,mode:this.mode})})).exitCode()):0}};NC.paths=[["remove"]],NC.usage=ye.Usage({description:"remove dependencies from the project",details:` - This command will remove the packages matching the specified patterns from the current workspace. - - If the \`--mode=\` option is set, Yarn will change which artifacts are generated. The modes currently supported are: - - - \`skip-build\` will not run the build scripts at all. Note that this is different from setting \`enableScripts\` to false because the later will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run. - - - \`update-lockfile\` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost. - - This command accepts glob patterns as arguments (if valid Idents and supported by [micromatch](https://github.com/micromatch/micromatch)). Make sure to escape the patterns, to prevent your own shell from trying to expand them. - `,examples:[["Remove a dependency from the current project","$0 remove lodash"],["Remove a dependency from all workspaces at once","$0 remove lodash --all"],["Remove all dependencies starting with `eslint-`","$0 remove 'eslint-*'"],["Remove all dependencies with the `@babel` scope","$0 remove '@babel/*'"],["Remove all dependencies matching `react-dom` or `react-helmet`","$0 remove 'react-{dom,helmet}'"]]});var hAe=NC;var pAe=ie(require("util")),z0=class extends Be{async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);return(await Fe.start({configuration:e,stdout:this.context.stdout},async s=>{let o=i.manifest.scripts,a=de.sortMap(o.keys(),u=>u),l={breakLength:Infinity,colors:e.get("enableColors"),maxArrayLength:2},c=a.reduce((u,g)=>Math.max(u,g.length),0);for(let[u,g]of o.entries())s.reportInfo(null,`${u.padEnd(c," ")} ${(0,pAe.inspect)(g,l)}`)})).exitCode()}};z0.paths=[["run"]];var dAe=z0;var LC=class extends Be{constructor(){super(...arguments);this.inspect=Y.String("--inspect",!1,{tolerateBoolean:!0,description:"Forwarded to the underlying Node process when executing a binary"});this.inspectBrk=Y.String("--inspect-brk",!1,{tolerateBoolean:!0,description:"Forwarded to the underlying Node process when executing a binary"});this.topLevel=Y.Boolean("-T,--top-level",!1,{description:"Check the root workspace for scripts and/or binaries instead of the current one"});this.binariesOnly=Y.Boolean("-B,--binaries-only",!1,{description:"Ignore any user defined scripts and only check for binaries"});this.silent=Y.Boolean("--silent",{hidden:!0});this.scriptName=Y.String();this.args=Y.Proxy()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i,locator:n}=await Ke.find(e,this.context.cwd);await r.restoreInstallState();let s=this.topLevel?r.topLevelWorkspace.anchoredLocator:n;if(!this.binariesOnly&&await Kt.hasPackageScript(s,this.scriptName,{project:r}))return await Kt.executePackageScript(s,this.scriptName,this.args,{project:r,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr});let o=await Kt.getPackageAccessibleBinaries(s,{project:r});if(o.get(this.scriptName)){let l=[];return this.inspect&&(typeof this.inspect=="string"?l.push(`--inspect=${this.inspect}`):l.push("--inspect")),this.inspectBrk&&(typeof this.inspectBrk=="string"?l.push(`--inspect-brk=${this.inspectBrk}`):l.push("--inspect-brk")),await Kt.executePackageAccessibleBinary(s,this.scriptName,this.args,{cwd:this.context.cwd,project:r,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr,nodeArgs:l,packageAccessibleBinaries:o})}if(!this.topLevel&&!this.binariesOnly&&i&&this.scriptName.includes(":")){let c=(await Promise.all(r.workspaces.map(async u=>u.manifest.scripts.has(this.scriptName)?u:null))).filter(u=>u!==null);if(c.length===1)return await Kt.executeWorkspaceScript(c[0],this.scriptName,this.args,{stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr})}if(this.topLevel)throw this.scriptName==="node-gyp"?new me(`Couldn't find a script name "${this.scriptName}" in the top-level (used by ${S.prettyLocator(e,n)}). This typically happens because some package depends on "node-gyp" to build itself, but didn't list it in their dependencies. To fix that, please run "yarn add node-gyp" into your top-level workspace. You also can open an issue on the repository of the specified package to suggest them to use an optional peer dependency.`):new me(`Couldn't find a script name "${this.scriptName}" in the top-level (used by ${S.prettyLocator(e,n)}).`);{if(this.scriptName==="global")throw new me("The 'yarn global' commands have been removed in 2.x - consider using 'yarn dlx' or a third-party plugin instead");let l=[this.scriptName].concat(this.args);for(let[c,u]of Yg)for(let g of u)if(l.length>=g.length&&JSON.stringify(l.slice(0,g.length))===JSON.stringify(g))throw new me(`Couldn't find a script named "${this.scriptName}", but a matching command can be found in the ${c} plugin. You can install it with "yarn plugin import ${c}".`);throw new me(`Couldn't find a script named "${this.scriptName}".`)}}};LC.paths=[["run"]],LC.usage=ye.Usage({description:"run a script defined in the package.json",details:` - This command will run a tool. The exact tool that will be executed will depend on the current state of your workspace: - - - If the \`scripts\` field from your local package.json contains a matching script name, its definition will get executed. - - - Otherwise, if one of the local workspace's dependencies exposes a binary with a matching name, this binary will get executed. - - - Otherwise, if the specified name contains a colon character and if one of the workspaces in the project contains exactly one script with a matching name, then this script will get executed. - - Whatever happens, the cwd of the spawned process will be the workspace that declares the script (which makes it possible to call commands cross-workspaces using the third syntax). - `,examples:[["Run the tests from the local workspace","$0 run test"],['Same thing, but without the "run" keyword',"$0 test"],["Inspect Webpack while running","$0 run --inspect-brk webpack"]]});var CAe=LC;var TC=class extends Be{constructor(){super(...arguments);this.save=Y.Boolean("-s,--save",!1,{description:"Persist the resolution inside the top-level manifest"});this.descriptor=Y.String();this.resolution=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(await r.restoreInstallState({restoreResolutions:!1}),!i)throw new rt(r.cwd,this.context.cwd);let s=S.parseDescriptor(this.descriptor,!0),o=S.makeDescriptor(s,this.resolution);return r.storedDescriptors.set(s.descriptorHash,s),r.storedDescriptors.set(o.descriptorHash,o),r.resolutionAliases.set(s.descriptorHash,o.descriptorHash),(await Fe.start({configuration:e,stdout:this.context.stdout},async l=>{await r.install({cache:n,report:l})})).exitCode()}};TC.paths=[["set","resolution"]],TC.usage=ye.Usage({description:"enforce a package resolution",details:'\n This command updates the resolution table so that `descriptor` is resolved by `resolution`.\n\n Note that by default this command only affect the current resolution table - meaning that this "manual override" will disappear if you remove the lockfile, or if the package disappear from the table. If you wish to make the enforced resolution persist whatever happens, add the `-s,--save` flag which will also edit the `resolutions` field from your top-level manifest.\n\n Note that no attempt is made at validating that `resolution` is a valid resolution entry for `descriptor`.\n ',examples:[["Force all instances of lodash@npm:^1.2.3 to resolve to 1.5.0","$0 set resolution lodash@npm:^1.2.3 1.5.0"]]});var mAe=TC;var EAe=ie(Nn()),MC=class extends Be{constructor(){super(...arguments);this.all=Y.Boolean("-A,--all",!1,{description:"Unlink all workspaces belonging to the target project from the current one"});this.leadingArguments=Y.Rest()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);let s=r.topLevelWorkspace,o=new Set;if(this.leadingArguments.length===0&&this.all)for(let{pattern:l,reference:c}of s.manifest.resolutions)c.startsWith("portal:")&&o.add(l.descriptor.fullName);if(this.leadingArguments.length>0)for(let l of this.leadingArguments){let c=v.resolve(this.context.cwd,M.toPortablePath(l));if(de.isPathLike(l)){let u=await fe.find(c,this.context.plugins,{useRc:!1,strict:!1}),{project:g,workspace:f}=await Ke.find(u,c);if(!f)throw new rt(g.cwd,c);if(this.all){for(let h of g.workspaces)h.manifest.name&&o.add(S.stringifyIdent(h.locator));if(o.size===0)throw new me("No workspace found to be unlinked in the target project")}else{if(!f.manifest.name)throw new me("The target workspace doesn't have a name and thus cannot be unlinked");o.add(S.stringifyIdent(f.locator))}}else{let u=[...s.manifest.resolutions.map(({pattern:g})=>g.descriptor.fullName)];for(let g of(0,EAe.default)(u,l))o.add(g)}}return s.manifest.resolutions=s.manifest.resolutions.filter(({pattern:l})=>!o.has(l.descriptor.fullName)),(await Fe.start({configuration:e,stdout:this.context.stdout},async l=>{await r.install({cache:n,report:l})})).exitCode()}};MC.paths=[["unlink"]],MC.usage=ye.Usage({description:"disconnect the local project from another one",details:` - This command will remove any resolutions in the project-level manifest that would have been added via a yarn link with similar arguments. - `,examples:[["Unregister a remote workspace in the current project","$0 unlink ~/ts-loader"],["Unregister all workspaces from a remote project in the current project","$0 unlink ~/jest --all"],["Unregister all previously linked workspaces","$0 unlink --all"],["Unregister all workspaces matching a glob","$0 unlink '@babel/*' 'pkg-{a,b}'"]]});var IAe=MC;var yAe=ie(aC()),rL=ie(Nn());Ss();var uf=class extends Be{constructor(){super(...arguments);this.interactive=Y.Boolean("-i,--interactive",{description:"Offer various choices, depending on the detected upgrade paths"});this.exact=Y.Boolean("-E,--exact",!1,{description:"Don't use any semver modifier on the resolved range"});this.tilde=Y.Boolean("-T,--tilde",!1,{description:"Use the `~` semver modifier on the resolved range"});this.caret=Y.Boolean("-C,--caret",!1,{description:"Use the `^` semver modifier on the resolved range"});this.recursive=Y.Boolean("-R,--recursive",!1,{description:"Resolve again ALL resolutions for those packages"});this.mode=Y.String("--mode",{description:"Change what artifacts installs generate",validator:Yi(li)});this.patterns=Y.Rest()}async execute(){return this.recursive?await this.executeUpRecursive():await this.executeUpClassic()}async executeUpRecursive(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState({restoreResolutions:!1});let s=[...r.storedDescriptors.values()],o=s.map(u=>S.stringifyIdent(u)),a=new Set;for(let u of this.patterns){if(S.parseDescriptor(u).range!=="unknown")throw new me("Ranges aren't allowed when using --recursive");for(let g of(0,rL.default)(o,u)){let f=S.parseIdent(g);a.add(f.identHash)}}let l=s.filter(u=>a.has(u.identHash));for(let u of l)r.storedDescriptors.delete(u.descriptorHash),r.storedResolutions.delete(u.descriptorHash);return(await Fe.start({configuration:e,stdout:this.context.stdout},async u=>{await r.install({cache:n,report:u})})).exitCode()}async executeUpClassic(){var d;let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState({restoreResolutions:!1});let s=(d=this.interactive)!=null?d:e.get("preferInteractive"),o=AC(this,r),a=s?[Fr.KEEP,Fr.REUSE,Fr.PROJECT,Fr.LATEST]:[Fr.PROJECT,Fr.LATEST],l=[],c=[];for(let m of this.patterns){let I=!1,B=S.parseDescriptor(m);for(let b of r.workspaces)for(let R of[vr.REGULAR,vr.DEVELOPMENT]){let L=[...b.manifest.getForScope(R).values()].map(K=>S.stringifyIdent(K));for(let K of(0,rL.default)(L,S.stringifyIdent(B))){let J=S.parseIdent(K),ne=b.manifest[R].get(J.identHash);if(typeof ne=="undefined")throw new Error("Assertion failed: Expected the descriptor to be registered");let q=S.makeDescriptor(J,B.range);l.push(Promise.resolve().then(async()=>[b,R,ne,await lC(q,{project:r,workspace:b,cache:n,target:R,modifier:o,strategies:a})])),I=!0}}I||c.push(m)}if(c.length>1)throw new me(`Patterns ${ue.prettyList(e,c,ps.CODE)} don't match any packages referenced by any workspace`);if(c.length>0)throw new me(`Pattern ${ue.prettyList(e,c,ps.CODE)} doesn't match any packages referenced by any workspace`);let u=await Promise.all(l),g=await Fa.start({configuration:e,stdout:this.context.stdout,suggestInstall:!1},async m=>{for(let[,,I,{suggestions:B,rejections:b}]of u){let R=B.filter(H=>H.descriptor!==null);if(R.length===0){let[H]=b;if(typeof H=="undefined")throw new Error("Assertion failed: Expected an error to have been set");let L=this.cli.error(H);r.configuration.get("enableNetwork")?m.reportError(z.CANT_SUGGEST_RESOLUTIONS,`${S.prettyDescriptor(e,I)} can't be resolved to a satisfying range - -${L}`):m.reportError(z.CANT_SUGGEST_RESOLUTIONS,`${S.prettyDescriptor(e,I)} can't be resolved to a satisfying range (note: network resolution has been disabled) - -${L}`)}else R.length>1&&!s&&m.reportError(z.CANT_SUGGEST_RESOLUTIONS,`${S.prettyDescriptor(e,I)} has multiple possible upgrade strategies; use -i to disambiguate manually`)}});if(g.hasErrors())return g.exitCode();let f=!1,h=[];for(let[m,I,,{suggestions:B}]of u){let b,R=B.filter(J=>J.descriptor!==null),H=R[0].descriptor,L=R.every(J=>S.areDescriptorsEqual(J.descriptor,H));R.length===1||L?b=H:(f=!0,{answer:b}=await(0,yAe.prompt)({type:"select",name:"answer",message:`Which range to you want to use in ${S.prettyWorkspace(e,m)} \u276F ${I}?`,choices:B.map(({descriptor:J,name:ne,reason:q})=>J?{name:ne,hint:q,descriptor:J}:{name:ne,hint:q,disabled:!0}),onCancel:()=>process.exit(130),result(J){return this.find(J,"descriptor")},stdin:this.context.stdin,stdout:this.context.stdout}));let K=m.manifest[I].get(b.identHash);if(typeof K=="undefined")throw new Error("Assertion failed: This descriptor should have a matching entry");if(K.descriptorHash!==b.descriptorHash)m.manifest[I].set(b.identHash,b),h.push([m,I,K,b]);else{let J=e.makeResolver(),ne={project:r,resolver:J},q=J.bindDescriptor(K,m.anchoredLocator,ne);r.forgetResolution(q)}}return await e.triggerMultipleHooks(m=>m.afterWorkspaceDependencyReplacement,h),f&&this.context.stdout.write(` -`),(await Fe.start({configuration:e,stdout:this.context.stdout},async m=>{await r.install({cache:n,report:m,mode:this.mode})})).exitCode()}};uf.paths=[["up"]],uf.usage=ye.Usage({description:"upgrade dependencies across the project",details:"\n This command upgrades the packages matching the list of specified patterns to their latest available version across the whole project (regardless of whether they're part of `dependencies` or `devDependencies` - `peerDependencies` won't be affected). This is a project-wide command: all workspaces will be upgraded in the process.\n\n If `-R,--recursive` is set the command will change behavior and no other switch will be allowed. When operating under this mode `yarn up` will force all ranges matching the selected packages to be resolved again (often to the highest available versions) before being stored in the lockfile. It however won't touch your manifests anymore, so depending on your needs you might want to run both `yarn up` and `yarn up -R` to cover all bases.\n\n If `-i,--interactive` is set (or if the `preferInteractive` settings is toggled on) the command will offer various choices, depending on the detected upgrade paths. Some upgrades require this flag in order to resolve ambiguities.\n\n The, `-C,--caret`, `-E,--exact` and `-T,--tilde` options have the same meaning as in the `add` command (they change the modifier used when the range is missing or a tag, and are ignored when the range is explicitly set).\n\n If the `--mode=` option is set, Yarn will change which artifacts are generated. The modes currently supported are:\n\n - `skip-build` will not run the build scripts at all. Note that this is different from setting `enableScripts` to false because the later will disable build scripts, and thus affect the content of the artifacts generated on disk, whereas the former will just disable the build step - but not the scripts themselves, which just won't run.\n\n - `update-lockfile` will skip the link step altogether, and only fetch packages that are missing from the lockfile (or that have no associated checksums). This mode is typically used by tools like Renovate or Dependabot to keep a lockfile up-to-date without incurring the full install cost.\n\n Generally you can see `yarn up` as a counterpart to what was `yarn upgrade --latest` in Yarn 1 (ie it ignores the ranges previously listed in your manifests), but unlike `yarn upgrade` which only upgraded dependencies in the current workspace, `yarn up` will upgrade all workspaces at the same time.\n\n This command accepts glob patterns as arguments (if valid Descriptors and supported by [micromatch](https://github.com/micromatch/micromatch)). Make sure to escape the patterns, to prevent your own shell from trying to expand them.\n\n **Note:** The ranges have to be static, only the package scopes and names can contain glob patterns.\n ",examples:[["Upgrade all instances of lodash to the latest release","$0 up lodash"],["Upgrade all instances of lodash to the latest release, but ask confirmation for each","$0 up lodash -i"],["Upgrade all instances of lodash to 1.2.3","$0 up lodash@1.2.3"],["Upgrade all instances of packages with the `@babel` scope to the latest release","$0 up '@babel/*'"],["Upgrade all instances of packages containing the word `jest` to the latest release","$0 up '*jest*'"],["Upgrade all instances of packages with the `@babel` scope to 7.0.0","$0 up '@babel/*@7.0.0'"]]}),uf.schema=[pv("recursive",Bl.Forbids,["interactive","exact","tilde","caret"],{ignore:[void 0,!1]})];var wAe=uf;var OC=class extends Be{constructor(){super(...arguments);this.recursive=Y.Boolean("-R,--recursive",!1,{description:"List, for each workspace, what are all the paths that lead to the dependency"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.peers=Y.Boolean("--peers",!1,{description:"Also print the peer dependencies that match the specified name"});this.package=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState();let n=S.parseIdent(this.package).identHash,s=this.recursive?nze(r,n,{configuration:e,peers:this.peers}):ize(r,n,{configuration:e,peers:this.peers});Hs.emitTree(s,{configuration:e,stdout:this.context.stdout,json:this.json,separators:1})}};OC.paths=[["why"]],OC.usage=ye.Usage({description:"display the reason why a package is needed",details:` - This command prints the exact reasons why a package appears in the dependency tree. - - If \`-R,--recursive\` is set, the listing will go in depth and will list, for each workspaces, what are all the paths that lead to the dependency. Note that the display is somewhat optimized in that it will not print the package listing twice for a single package, so if you see a leaf named "Foo" when looking for "Bar", it means that "Foo" already got printed higher in the tree. - `,examples:[["Explain why lodash is used in your project","$0 why lodash"]]});var BAe=OC;function ize(t,e,{configuration:r,peers:i}){let n=de.sortMap(t.storedPackages.values(),a=>S.stringifyLocator(a)),s={},o={children:s};for(let a of n){let l={},c=null;for(let u of a.dependencies.values()){if(!i&&a.peerDependencies.has(u.identHash))continue;let g=t.storedResolutions.get(u.descriptorHash);if(!g)throw new Error("Assertion failed: The resolution should have been registered");let f=t.storedPackages.get(g);if(!f)throw new Error("Assertion failed: The package should have been registered");if(f.identHash!==e)continue;if(c===null){let p=S.stringifyLocator(a);s[p]={value:[a,ue.Type.LOCATOR],children:l}}let h=S.stringifyLocator(f);l[h]={value:[{descriptor:u,locator:f},ue.Type.DEPENDENT]}}}return o}function nze(t,e,{configuration:r,peers:i}){let n=de.sortMap(t.workspaces,f=>S.stringifyLocator(f.anchoredLocator)),s=new Set,o=new Set,a=f=>{if(s.has(f.locatorHash))return o.has(f.locatorHash);if(s.add(f.locatorHash),f.identHash===e)return o.add(f.locatorHash),!0;let h=!1;f.identHash===e&&(h=!0);for(let p of f.dependencies.values()){if(!i&&f.peerDependencies.has(p.identHash))continue;let d=t.storedResolutions.get(p.descriptorHash);if(!d)throw new Error("Assertion failed: The resolution should have been registered");let m=t.storedPackages.get(d);if(!m)throw new Error("Assertion failed: The package should have been registered");a(m)&&(h=!0)}return h&&o.add(f.locatorHash),h};for(let f of n){let h=t.storedPackages.get(f.anchoredLocator.locatorHash);if(!h)throw new Error("Assertion failed: The package should have been registered");a(h)}let l=new Set,c={},u={children:c},g=(f,h,p)=>{if(!o.has(f.locatorHash))return;let d=p!==null?ue.tuple(ue.Type.DEPENDENT,{locator:f,descriptor:p}):ue.tuple(ue.Type.LOCATOR,f),m={},I={value:d,children:m},B=S.stringifyLocator(f);if(h[B]=I,!l.has(f.locatorHash)&&(l.add(f.locatorHash),!(p!==null&&t.tryWorkspaceByLocator(f))))for(let b of f.dependencies.values()){if(!i&&f.peerDependencies.has(b.identHash))continue;let R=t.storedResolutions.get(b.descriptorHash);if(!R)throw new Error("Assertion failed: The resolution should have been registered");let H=t.storedPackages.get(R);if(!H)throw new Error("Assertion failed: The package should have been registered");g(H,m,b)}};for(let f of n){let h=t.storedPackages.get(f.anchoredLocator.locatorHash);if(!h)throw new Error("Assertion failed: The package should have been registered");g(h,c,null)}return u}var fL={};it(fL,{default:()=>wze,gitUtils:()=>Uc});var Uc={};it(Uc,{TreeishProtocols:()=>vn,clone:()=>cL,fetchBase:()=>jAe,fetchChangedFiles:()=>YAe,fetchChangedWorkspaces:()=>Ize,fetchRoot:()=>GAe,isGitUrl:()=>ff,lsRemote:()=>HAe,normalizeLocator:()=>AL,normalizeRepoUrl:()=>KC,resolveUrl:()=>lL,splitRepoUrl:()=>UC});var oL=ie(OAe()),gf=ie(require("querystring")),aL=ie(Or()),KAe=ie(require("url"));function UAe(){return _(P({},process.env),{GIT_SSH_COMMAND:"ssh -o BatchMode=yes"})}var Eze=[/^ssh:/,/^git(?:\+[^:]+)?:/,/^(?:git\+)?https?:[^#]+\/[^#]+(?:\.git)(?:#.*)?$/,/^git@[^#]+\/[^#]+\.git(?:#.*)?$/,/^(?:github:|https:\/\/github\.com\/)?(?!\.{1,2}\/)([a-zA-Z._0-9-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z._0-9-]+?)(?:\.git)?(?:#.*)?$/,/^https:\/\/github\.com\/(?!\.{1,2}\/)([a-zA-Z0-9._-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z0-9._-]+?)\/tarball\/(.+)?$/],vn;(function(n){n.Commit="commit",n.Head="head",n.Tag="tag",n.Semver="semver"})(vn||(vn={}));function ff(t){return t?Eze.some(e=>!!t.match(e)):!1}function UC(t){t=KC(t);let e=t.indexOf("#");if(e===-1)return{repo:t,treeish:{protocol:vn.Head,request:"HEAD"},extra:{}};let r=t.slice(0,e),i=t.slice(e+1);if(i.match(/^[a-z]+=/)){let n=gf.default.parse(i);for(let[l,c]of Object.entries(n))if(typeof c!="string")throw new Error(`Assertion failed: The ${l} parameter must be a literal string`);let s=Object.values(vn).find(l=>Object.prototype.hasOwnProperty.call(n,l)),o,a;typeof s!="undefined"?(o=s,a=n[s]):(o=vn.Head,a="HEAD");for(let l of Object.values(vn))delete n[l];return{repo:r,treeish:{protocol:o,request:a},extra:n}}else{let n=i.indexOf(":"),s,o;return n===-1?(s=null,o=i):(s=i.slice(0,n),o=i.slice(n+1)),{repo:r,treeish:{protocol:s,request:o},extra:{}}}}function KC(t,{git:e=!1}={}){var r;if(t=t.replace(/^git\+https:/,"https:"),t=t.replace(/^(?:github:|https:\/\/github\.com\/)?(?!\.{1,2}\/)([a-zA-Z0-9._-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z0-9._-]+?)(?:\.git)?(#.*)?$/,"https://github.com/$1/$2.git$3"),t=t.replace(/^https:\/\/github\.com\/(?!\.{1,2}\/)([a-zA-Z0-9._-]+)\/(?!\.{1,2}(?:#|$))([a-zA-Z0-9._-]+?)\/tarball\/(.+)?$/,"https://github.com/$1/$2.git#$3"),e){t=t.replace(/^git\+([^:]+):/,"$1:");let i;try{i=KAe.default.parse(t)}catch{i=null}i&&i.protocol==="ssh:"&&((r=i.path)==null?void 0:r.startsWith("/:"))&&(t=t.replace(/^ssh:\/\//,""))}return t}function AL(t){return S.makeLocator(t,KC(t.reference))}async function HAe(t,e){let r=KC(t,{git:!0});if(!Zt.getNetworkSettings(`https://${(0,oL.default)(r).resource}`,{configuration:e}).enableNetwork)throw new Error(`Request to '${r}' has been blocked because of your configuration settings`);let n;try{n=await hr.execvp("git",["ls-remote",r],{cwd:e.startingCwd,env:UAe(),strict:!0})}catch(l){throw l.message=`Listing the refs for ${t} failed`,l}let s=new Map,o=/^([a-f0-9]{40})\t([^\n]+)/gm,a;for(;(a=o.exec(n.stdout))!==null;)s.set(a[2],a[1]);return s}async function lL(t,e){let{repo:r,treeish:{protocol:i,request:n},extra:s}=UC(t),o=await HAe(r,e),a=(c,u)=>{switch(c){case vn.Commit:{if(!u.match(/^[a-f0-9]{40}$/))throw new Error("Invalid commit hash");return gf.default.stringify(_(P({},s),{commit:u}))}case vn.Head:{let g=o.get(u==="HEAD"?u:`refs/heads/${u}`);if(typeof g=="undefined")throw new Error(`Unknown head ("${u}")`);return gf.default.stringify(_(P({},s),{commit:g}))}case vn.Tag:{let g=o.get(`refs/tags/${u}`);if(typeof g=="undefined")throw new Error(`Unknown tag ("${u}")`);return gf.default.stringify(_(P({},s),{commit:g}))}case vn.Semver:{let g=qt.validRange(u);if(!g)throw new Error(`Invalid range ("${u}")`);let f=new Map([...o.entries()].filter(([p])=>p.startsWith("refs/tags/")).map(([p,d])=>[aL.default.parse(p.slice(10)),d]).filter(p=>p[0]!==null)),h=aL.default.maxSatisfying([...f.keys()],g);if(h===null)throw new Error(`No matching range ("${u}")`);return gf.default.stringify(_(P({},s),{commit:f.get(h)}))}case null:{let g;if((g=l(vn.Commit,u))!==null||(g=l(vn.Tag,u))!==null||(g=l(vn.Head,u))!==null)return g;throw u.match(/^[a-f0-9]+$/)?new Error(`Couldn't resolve "${u}" as either a commit, a tag, or a head - if a commit, use the 40-characters commit hash`):new Error(`Couldn't resolve "${u}" as either a commit, a tag, or a head`)}default:throw new Error(`Invalid Git resolution protocol ("${c}")`)}},l=(c,u)=>{try{return a(c,u)}catch(g){return null}};return`${r}#${a(i,n)}`}async function cL(t,e){return await e.getLimit("cloneConcurrency")(async()=>{let{repo:r,treeish:{protocol:i,request:n}}=UC(t);if(i!=="commit")throw new Error("Invalid treeish protocol when cloning");let s=KC(r,{git:!0});if(Zt.getNetworkSettings(`https://${(0,oL.default)(s).resource}`,{configuration:e}).enableNetwork===!1)throw new Error(`Request to '${s}' has been blocked because of your configuration settings`);let o=await T.mktempPromise(),a={cwd:o,env:UAe(),strict:!0};try{await hr.execvp("git",["clone","-c core.autocrlf=false",s,M.fromPortablePath(o)],a),await hr.execvp("git",["checkout",`${n}`],a)}catch(l){throw l.message=`Repository clone failed: ${l.message}`,l}return o})}async function GAe(t){let e=null,r,i=t;do r=i,await T.existsPromise(v.join(r,".git"))&&(e=r),i=v.dirname(r);while(e===null&&i!==r);return e}async function jAe(t,{baseRefs:e}){if(e.length===0)throw new me("Can't run this command with zero base refs specified.");let r=[];for(let a of e){let{code:l}=await hr.execvp("git",["merge-base",a,"HEAD"],{cwd:t});l===0&&r.push(a)}if(r.length===0)throw new me(`No ancestor could be found between any of HEAD and ${e.join(", ")}`);let{stdout:i}=await hr.execvp("git",["merge-base","HEAD",...r],{cwd:t,strict:!0}),n=i.trim(),{stdout:s}=await hr.execvp("git",["show","--quiet","--pretty=format:%s",n],{cwd:t,strict:!0}),o=s.trim();return{hash:n,title:o}}async function YAe(t,{base:e,project:r}){let i=de.buildIgnorePattern(r.configuration.get("changesetIgnorePatterns")),{stdout:n}=await hr.execvp("git",["diff","--name-only",`${e}`],{cwd:t,strict:!0}),s=n.split(/\r\n|\r|\n/).filter(c=>c.length>0).map(c=>v.resolve(t,M.toPortablePath(c))),{stdout:o}=await hr.execvp("git",["ls-files","--others","--exclude-standard"],{cwd:t,strict:!0}),a=o.split(/\r\n|\r|\n/).filter(c=>c.length>0).map(c=>v.resolve(t,M.toPortablePath(c))),l=[...new Set([...s,...a].sort())];return i?l.filter(c=>!v.relative(r.cwd,c).match(i)):l}async function Ize({ref:t,project:e}){if(e.configuration.projectCwd===null)throw new me("This command can only be run from within a Yarn project");let r=[v.resolve(e.cwd,e.configuration.get("cacheFolder")),v.resolve(e.cwd,e.configuration.get("installStatePath")),v.resolve(e.cwd,e.configuration.get("lockfileFilename")),v.resolve(e.cwd,e.configuration.get("virtualFolder"))];await e.configuration.triggerHook(o=>o.populateYarnPaths,e,o=>{o!=null&&r.push(o)});let i=await GAe(e.configuration.projectCwd);if(i==null)throw new me("This command can only be run on Git repositories");let n=await jAe(i,{baseRefs:typeof t=="string"?[t]:e.configuration.get("changesetBaseRefs")}),s=await YAe(i,{base:n.hash,project:e});return new Set(de.mapAndFilter(s,o=>{let a=e.tryWorkspaceByFilePath(o);return a===null?de.mapAndFilter.skip:r.some(l=>o.startsWith(l))?de.mapAndFilter.skip:a}))}var uL=class{supports(e,r){return ff(e.reference)}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,n=AL(e),s=new Map(r.checksums);s.set(n.locatorHash,i);let o=_(P({},r),{checksums:s}),a=await this.downloadHosted(n,o);if(a!==null)return a;let[l,c,u]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the remote repository`),loader:()=>this.cloneFromRemote(n,o),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:l,releaseFs:c,prefixPath:S.getIdentVendorPath(e),checksum:u}}async downloadHosted(e,r){return r.project.configuration.reduceHook(i=>i.fetchHostedRepository,null,e,r)}async cloneFromRemote(e,r){let i=await cL(e.reference,r.project.configuration),n=UC(e.reference),s=v.join(i,"package.tgz");await Kt.prepareExternalProject(i,s,{configuration:r.project.configuration,report:r.report,workspace:n.extra.workspace,locator:e});let o=await T.readFilePromise(s);return await de.releaseAfterUseAsync(async()=>await Ai.convertToZip(o,{compressionLevel:r.project.configuration.get("compressionLevel"),prefixPath:S.getIdentVendorPath(e),stripComponents:1}))}};var gL=class{supportsDescriptor(e,r){return ff(e.range)}supportsLocator(e,r){return ff(e.reference)}shouldPersistResolution(e,r){return!0}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){let n=await lL(e.range,i.project.configuration);return[S.makeLocator(e,n)]}async getSatisfying(e,r,i){return null}async resolve(e,r){if(!r.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let i=await r.fetchOptions.fetcher.fetch(e,r.fetchOptions),n=await de.releaseAfterUseAsync(async()=>await Ze.find(i.prefixPath,{baseFs:i.packageFs}),i.releaseFs);return _(P({},e),{version:n.version||"0.0.0",languageName:n.languageName||r.project.configuration.get("defaultLanguageName"),linkType:gt.HARD,conditions:n.getConditions(),dependencies:n.dependencies,peerDependencies:n.peerDependencies,dependenciesMeta:n.dependenciesMeta,peerDependenciesMeta:n.peerDependenciesMeta,bin:n.bin})}};var yze={configuration:{changesetBaseRefs:{description:"The base git refs that the current HEAD is compared against when detecting changes. Supports git branches, tags, and commits.",type:ge.STRING,isArray:!0,isNullable:!1,default:["master","origin/master","upstream/master","main","origin/main","upstream/main"]},changesetIgnorePatterns:{description:"Array of glob patterns; files matching them will be ignored when fetching the changed files",type:ge.STRING,default:[],isArray:!0},cloneConcurrency:{description:"Maximal number of concurrent clones",type:ge.NUMBER,default:2}},fetchers:[uL],resolvers:[gL]};var wze=yze;var HC=class extends Be{constructor(){super(...arguments);this.since=Y.String("--since",{description:"Only include workspaces that have been changed since the specified ref.",tolerateBoolean:!0});this.recursive=Y.Boolean("-R,--recursive",!1,{description:"Find packages via dependencies/devDependencies instead of using the workspaces field"});this.verbose=Y.Boolean("-v,--verbose",!1,{description:"Also return the cross-dependencies between workspaces"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r}=await Ke.find(e,this.context.cwd);return(await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout},async n=>{let s=this.since?await Uc.fetchChangedWorkspaces({ref:this.since,project:r}):r.workspaces,o=new Set(s);if(this.recursive)for(let a of[...s].map(l=>l.getRecursiveWorkspaceDependents()))for(let l of a)o.add(l);for(let a of o){let{manifest:l}=a,c;if(this.verbose){let u=new Set,g=new Set;for(let f of Ze.hardDependencies)for(let[h,p]of l.getForScope(f)){let d=r.tryWorkspaceByDescriptor(p);d===null?r.workspacesByIdent.has(h)&&g.add(p):u.add(d)}c={workspaceDependencies:Array.from(u).map(f=>f.relativeCwd),mismatchedWorkspaceDependencies:Array.from(g).map(f=>S.stringifyDescriptor(f))}}n.reportInfo(null,`${a.relativeCwd}`),n.reportJson(P({location:a.relativeCwd,name:l.name?S.stringifyIdent(l.name):null},c))}})).exitCode()}};HC.paths=[["workspaces","list"]],HC.usage=ye.Usage({category:"Workspace-related commands",description:"list all available workspaces",details:"\n This command will print the list of all workspaces in the project.\n\n - If `--since` is set, Yarn will only list workspaces that have been modified since the specified ref. By default Yarn will use the refs specified by the `changesetBaseRefs` configuration option.\n\n - If `-R,--recursive` is set, Yarn will find workspaces to run the command on by recursively evaluating `dependencies` and `devDependencies` fields, instead of looking at the `workspaces` fields.\n\n - If both the `-v,--verbose` and `--json` options are set, Yarn will also return the cross-dependencies between each workspaces (useful when you wish to automatically generate Buck / Bazel rules).\n "});var qAe=HC;var GC=class extends Be{constructor(){super(...arguments);this.workspaceName=Y.String();this.commandName=Y.String();this.args=Y.Proxy()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);let n=r.workspaces,s=new Map(n.map(a=>{let l=S.convertToIdent(a.locator);return[S.stringifyIdent(l),a]})),o=s.get(this.workspaceName);if(o===void 0){let a=Array.from(s.keys()).sort();throw new me(`Workspace '${this.workspaceName}' not found. Did you mean any of the following: - - ${a.join(` - - `)}?`)}return this.cli.run([this.commandName,...this.args],{cwd:o.cwd})}};GC.paths=[["workspace"]],GC.usage=ye.Usage({category:"Workspace-related commands",description:"run a command within the specified workspace",details:` - This command will run a given sub-command on a single workspace. - `,examples:[["Add a package to a single workspace","yarn workspace components add -D react"],["Run build script on a single workspace","yarn workspace components run build"]]});var JAe=GC;var Bze={configuration:{enableImmutableInstalls:{description:"If true (the default on CI), prevents the install command from modifying the lockfile",type:ge.BOOLEAN,default:WAe.isCI},defaultSemverRangePrefix:{description:"The default save prefix: '^', '~' or ''",type:ge.STRING,values:["^","~",""],default:Lo.CARET}},commands:[soe,aoe,wae,Nae,mAe,nAe,tAe,qAe,Uae,Hae,Gae,jae,ioe,noe,Lae,Mae,Yae,qae,Wae,zae,_ae,IAe,Xae,cAe,AAe,uAe,Zae,gAe,fAe,hAe,dAe,CAe,wAe,BAe,JAe]},Qze=Bze;var mL={};it(mL,{default:()=>vze});var Me={optional:!0},zAe=[["@tailwindcss/aspect-ratio@<0.2.1",{peerDependencies:{tailwindcss:"^2.0.2"}}],["@tailwindcss/line-clamp@<0.2.1",{peerDependencies:{tailwindcss:"^2.0.2"}}],["@fullhuman/postcss-purgecss@3.1.3 || 3.1.3-alpha.0",{peerDependencies:{postcss:"^8.0.0"}}],["@samverschueren/stream-to-observable@<0.3.1",{peerDependenciesMeta:{rxjs:Me,zenObservable:Me}}],["any-observable@<0.5.1",{peerDependenciesMeta:{rxjs:Me,zenObservable:Me}}],["@pm2/agent@<1.0.4",{dependencies:{debug:"*"}}],["debug@<4.2.0",{peerDependenciesMeta:{["supports-color"]:Me}}],["got@<11",{dependencies:{["@types/responselike"]:"^1.0.0",["@types/keyv"]:"^3.1.1"}}],["cacheable-lookup@<4.1.2",{dependencies:{["@types/keyv"]:"^3.1.1"}}],["http-link-dataloader@*",{peerDependencies:{graphql:"^0.13.1 || ^14.0.0"}}],["typescript-language-server@*",{dependencies:{["vscode-jsonrpc"]:"^5.0.1",["vscode-languageserver-protocol"]:"^3.15.0"}}],["postcss-syntax@*",{peerDependenciesMeta:{["postcss-html"]:Me,["postcss-jsx"]:Me,["postcss-less"]:Me,["postcss-markdown"]:Me,["postcss-scss"]:Me}}],["jss-plugin-rule-value-function@<=10.1.1",{dependencies:{["tiny-warning"]:"^1.0.2"}}],["ink-select-input@<4.1.0",{peerDependencies:{react:"^16.8.2"}}],["license-webpack-plugin@<2.3.18",{peerDependenciesMeta:{webpack:Me}}],["snowpack@>=3.3.0",{dependencies:{["node-gyp"]:"^7.1.0"}}],["promise-inflight@*",{peerDependenciesMeta:{bluebird:Me}}],["reactcss@*",{peerDependencies:{react:"*"}}],["react-color@<=2.19.0",{peerDependencies:{react:"*"}}],["gatsby-plugin-i18n@*",{dependencies:{ramda:"^0.24.1"}}],["useragent@^2.0.0",{dependencies:{request:"^2.88.0",yamlparser:"0.0.x",semver:"5.5.x"}}],["@apollographql/apollo-tools@*",{peerDependencies:{graphql:"^14.2.1 || ^15.0.0"}}],["material-table@^2.0.0",{dependencies:{"@babel/runtime":"^7.11.2"}}],["@babel/parser@*",{dependencies:{"@babel/types":"^7.8.3"}}],["fork-ts-checker-webpack-plugin@<=6.3.4",{peerDependencies:{eslint:">= 6",typescript:">= 2.7",webpack:">= 4","vue-template-compiler":"*"},peerDependenciesMeta:{eslint:Me,"vue-template-compiler":Me}}],["rc-animate@<=3.1.1",{peerDependencies:{react:">=16.9.0","react-dom":">=16.9.0"}}],["react-bootstrap-table2-paginator@*",{dependencies:{classnames:"^2.2.6"}}],["react-draggable@<=4.4.3",{peerDependencies:{react:">= 16.3.0","react-dom":">= 16.3.0"}}],["apollo-upload-client@<14",{peerDependencies:{graphql:"14 - 15"}}],["react-instantsearch-core@<=6.7.0",{peerDependencies:{algoliasearch:">= 3.1 < 5"}}],["react-instantsearch-dom@<=6.7.0",{dependencies:{"react-fast-compare":"^3.0.0"}}],["ws@<7.2.1",{peerDependencies:{bufferutil:"^4.0.1","utf-8-validate":"^5.0.2"},peerDependenciesMeta:{bufferutil:Me,"utf-8-validate":Me}}],["react-portal@*",{peerDependencies:{"react-dom":"^15.0.0-0 || ^16.0.0-0 || ^17.0.0-0"}}],["react-scripts@<=4.0.1",{peerDependencies:{react:"*"}}],["testcafe@<=1.10.1",{dependencies:{"@babel/plugin-transform-for-of":"^7.12.1","@babel/runtime":"^7.12.5"}}],["testcafe-legacy-api@<=4.2.0",{dependencies:{"testcafe-hammerhead":"^17.0.1","read-file-relative":"^1.2.0"}}],["@google-cloud/firestore@<=4.9.3",{dependencies:{protobufjs:"^6.8.6"}}],["gatsby-source-apiserver@*",{dependencies:{["babel-polyfill"]:"^6.26.0"}}],["@webpack-cli/package-utils@<=1.0.1-alpha.4",{dependencies:{["cross-spawn"]:"^7.0.3"}}],["gatsby-remark-prismjs@<3.3.28",{dependencies:{lodash:"^4"}}],["gatsby-plugin-favicon@*",{peerDependencies:{webpack:"*"}}],["gatsby-plugin-sharp@*",{dependencies:{debug:"^4.3.1"}}],["gatsby-react-router-scroll@*",{dependencies:{["prop-types"]:"^15.7.2"}}],["@rebass/forms@*",{dependencies:{["@styled-system/should-forward-prop"]:"^5.0.0"},peerDependencies:{react:"^16.8.6"}}],["rebass@*",{peerDependencies:{react:"^16.8.6"}}],["@ant-design/react-slick@<=0.28.3",{peerDependencies:{react:">=16.0.0"}}],["mqtt@<4.2.7",{dependencies:{duplexify:"^4.1.1"}}],["vue-cli-plugin-vuetify@<=2.0.3",{dependencies:{semver:"^6.3.0"},peerDependenciesMeta:{"sass-loader":Me,"vuetify-loader":Me}}],["vue-cli-plugin-vuetify@<=2.0.4",{dependencies:{"null-loader":"^3.0.0"}}],["@vuetify/cli-plugin-utils@<=0.0.4",{dependencies:{semver:"^6.3.0"},peerDependenciesMeta:{"sass-loader":Me}}],["@vue/cli-plugin-typescript@<=5.0.0-alpha.0",{dependencies:{"babel-loader":"^8.1.0"}}],["@vue/cli-plugin-typescript@<=5.0.0-beta.0",{dependencies:{"@babel/core":"^7.12.16"},peerDependencies:{"vue-template-compiler":"^2.0.0"},peerDependenciesMeta:{"vue-template-compiler":Me}}],["cordova-ios@<=6.3.0",{dependencies:{underscore:"^1.9.2"}}],["cordova-lib@<=10.0.1",{dependencies:{underscore:"^1.9.2"}}],["git-node-fs@*",{peerDependencies:{"js-git":"^0.7.8"},peerDependenciesMeta:{"js-git":Me}}],["consolidate@*",{peerDependencies:{velocityjs:"^2.0.1",tinyliquid:"^0.2.34","liquid-node":"^3.0.1",jade:"^1.11.0","then-jade":"*",dust:"^0.3.0","dustjs-helpers":"^1.7.4","dustjs-linkedin":"^2.7.5",swig:"^1.4.2","swig-templates":"^2.0.3","razor-tmpl":"^1.3.1",atpl:">=0.7.6",liquor:"^0.0.5",twig:"^1.15.2",ejs:"^3.1.5",eco:"^1.1.0-rc-3",jazz:"^0.0.18",jqtpl:"~1.1.0",hamljs:"^0.6.2",hamlet:"^0.3.3",whiskers:"^0.4.0","haml-coffee":"^1.14.1","hogan.js":"^3.0.2",templayed:">=0.2.3",handlebars:"^4.7.6",underscore:"^1.11.0",lodash:"^4.17.20",pug:"^3.0.0","then-pug":"*",qejs:"^3.0.5",walrus:"^0.10.1",mustache:"^4.0.1",just:"^0.1.8",ect:"^0.5.9",mote:"^0.2.0",toffee:"^0.3.6",dot:"^1.1.3","bracket-template":"^1.1.5",ractive:"^1.3.12",nunjucks:"^3.2.2",htmling:"^0.0.8","babel-core":"^6.26.3",plates:"~0.4.11","react-dom":"^16.13.1",react:"^16.13.1","arc-templates":"^0.5.3",vash:"^0.13.0",slm:"^2.0.0",marko:"^3.14.4",teacup:"^2.0.0","coffee-script":"^1.12.7",squirrelly:"^5.1.0",twing:"^5.0.2"},peerDependenciesMeta:{velocityjs:Me,tinyliquid:Me,"liquid-node":Me,jade:Me,"then-jade":Me,dust:Me,"dustjs-helpers":Me,"dustjs-linkedin":Me,swig:Me,"swig-templates":Me,"razor-tmpl":Me,atpl:Me,liquor:Me,twig:Me,ejs:Me,eco:Me,jazz:Me,jqtpl:Me,hamljs:Me,hamlet:Me,whiskers:Me,"haml-coffee":Me,"hogan.js":Me,templayed:Me,handlebars:Me,underscore:Me,lodash:Me,pug:Me,"then-pug":Me,qejs:Me,walrus:Me,mustache:Me,just:Me,ect:Me,mote:Me,toffee:Me,dot:Me,"bracket-template":Me,ractive:Me,nunjucks:Me,htmling:Me,"babel-core":Me,plates:Me,"react-dom":Me,react:Me,"arc-templates":Me,vash:Me,slm:Me,marko:Me,teacup:Me,"coffee-script":Me,squirrelly:Me,twing:Me}}],["vue-loader@<=16.3.1",{peerDependencies:{"@vue/compiler-sfc":"^3.0.8",webpack:"^4.1.0 || ^5.0.0-0"}}],["scss-parser@*",{dependencies:{lodash:"^4.17.21"}}],["query-ast@*",{dependencies:{lodash:"^4.17.21"}}],["redux-thunk@<=2.3.0",{peerDependencies:{redux:"^4.0.0"}}],["skypack@<=0.3.2",{dependencies:{tar:"^6.1.0"}}],["@npmcli/metavuln-calculator@*",{dependencies:{"json-parse-even-better-errors":"^2.3.1"}}],["bin-links@*",{dependencies:{"mkdirp-infer-owner":"^1.0.2"}}],["rollup-plugin-polyfill-node@*",{peerDependencies:{rollup:"^1.20.0 || ^2.0.0"}}],["snowpack@*",{dependencies:{"magic-string":"^0.25.7"}}],["elm-webpack-loader@*",{dependencies:{temp:"^0.9.4"}}],["winston-transport@<=4.4.0",{dependencies:{logform:"^2.2.0"}}],["jest-vue-preprocessor@*",{dependencies:{"@babel/core":"7.8.7","@babel/template":"7.8.6"},peerDependencies:{pug:"^2.0.4"},peerDependenciesMeta:{pug:Me}}],["redux-persist@*",{peerDependencies:{react:">=16"},peerDependenciesMeta:{react:Me}}],["sodium@>=3",{dependencies:{"node-gyp":"^3.8.0"}}],["babel-plugin-graphql-tag@<=3.1.0",{peerDependencies:{graphql:"^14.0.0 || ^15.0.0"}}],["@playwright/test@<=1.14.1",{dependencies:{"jest-matcher-utils":"^26.4.2"}}],...["babel-plugin-remove-graphql-queries@<3.14.0-next.1","babel-preset-gatsby-package@<1.14.0-next.1","create-gatsby@<1.14.0-next.1","gatsby-admin@<0.24.0-next.1","gatsby-cli@<3.14.0-next.1","gatsby-core-utils@<2.14.0-next.1","gatsby-design-tokens@<3.14.0-next.1","gatsby-legacy-polyfills@<1.14.0-next.1","gatsby-plugin-benchmark-reporting@<1.14.0-next.1","gatsby-plugin-graphql-config@<0.23.0-next.1","gatsby-plugin-image@<1.14.0-next.1","gatsby-plugin-mdx@<2.14.0-next.1","gatsby-plugin-netlify-cms@<5.14.0-next.1","gatsby-plugin-no-sourcemaps@<3.14.0-next.1","gatsby-plugin-page-creator@<3.14.0-next.1","gatsby-plugin-preact@<5.14.0-next.1","gatsby-plugin-preload-fonts@<2.14.0-next.1","gatsby-plugin-schema-snapshot@<2.14.0-next.1","gatsby-plugin-styletron@<6.14.0-next.1","gatsby-plugin-subfont@<3.14.0-next.1","gatsby-plugin-utils@<1.14.0-next.1","gatsby-recipes@<0.25.0-next.1","gatsby-source-shopify@<5.6.0-next.1","gatsby-source-wikipedia@<3.14.0-next.1","gatsby-transformer-screenshot@<3.14.0-next.1","gatsby-worker@<0.5.0-next.1"].map(t=>[t,{dependencies:{"@babel/runtime":"^7.14.8"}}]),["gatsby-core-utils@<2.14.0-next.1",{dependencies:{got:"8.3.2"}}],["gatsby-plugin-gatsby-cloud@<=3.1.0-next.0",{dependencies:{"gatsby-core-utils":"^2.13.0-next.0"}}],["gatsby-plugin-gatsby-cloud@<=3.2.0-next.1",{peerDependencies:{webpack:"*"}}],["babel-plugin-remove-graphql-queries@<=3.14.0-next.1",{dependencies:{"gatsby-core-utils":"^2.8.0-next.1"}}],["gatsby-plugin-netlify@3.13.0-next.1",{dependencies:{"gatsby-core-utils":"^2.13.0-next.0"}}],["clipanion-v3-codemod@<=0.2.0",{peerDependencies:{jscodeshift:"^0.11.0"}}],["react-live@*",{peerDependencies:{"react-dom":"*",react:"*"}}],["webpack@<4.44.1",{peerDependenciesMeta:{"webpack-cli":Me,"webpack-command":Me}}],["webpack@<5.0.0-beta.23",{peerDependenciesMeta:{"webpack-cli":Me}}],["webpack-dev-server@<3.10.2",{peerDependenciesMeta:{"webpack-cli":Me}}]];var pL;function VAe(){return typeof pL=="undefined"&&(pL=require("zlib").brotliDecompressSync(Buffer.from("G7weAByFTVk3Vs7UfHhq4yykgEM7pbW7TI43SG2S5tvGrwHBAzdz+s/npQ6tgEvobvxisrPIadkXeUAJotBn5bDZ5kAhcRqsIHe3F75Walet5hNalwgFDtxb0BiDUjiUQkjG0yW2hto9HPgiCkm316d6bC0kST72YN7D7rfkhCE9x4J0XwB0yavalxpUu2t9xszHrmtwalOxT7VslsxWcB1qpqZ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M9Mk3Q7aCNiZONXllhqq24DmoLbQfW2rYWsOgHWjtOmIQMyMKdiHZDjoyIq5+U700nZ6odJAoYXPQBvFNiQ78d5jaXliBqLTJEqUCwi+LiH2mx92EmNKDsJL74Z613+3lf20pxkV1+erOrjj8pW00vsPaahKUM+05ssd5uwM7K482KWEf3TCwlg/o3e5ngto7qSMz7YteIgCsF1UOcsLk7F7MxWbvrPMY473ew0G+noVL8EPbkmEMftMSeL6HFub/zy+2JQ==","base64")).toString()),pL}var dL;function _Ae(){return typeof dL=="undefined"&&(dL=require("zlib").brotliDecompressSync(Buffer.from("G8MSIIzURnVBnObTcvb3XE6v2S9Qgc2K801Oa5otNKEtK8BINZNcaQHy+9/vf/WXBimwutXC33P2DPc64pps5rz7NGGWaOKNSPL4Y2KRE8twut2lFOIN+OXPtRmPMRhMTILib2bEQx43az2I5d3YS8Roa5UZpF/ujHb3Djd3GDvYUfvFYSUQ39vb2cmifp/rgB4J/65JK3wRBTvMBoNBmn3mbXC63/gbBkW/2IRPri0O8bcsRBsmarF328pAln04nyJFkwUAvNu934supAqLtyerZZpJ8I8suJHhf/ocMV+scKwa8NOiDKIPXw6Ex/EEZD6TEGaW8N5zvNHYF10l6Lfooj7D5W2k3dgvQSbp2Wv8TGOayS978gxlOLVjTGXs66ozewbrjwElLtyrYNnWTfzzdEutgROUFPVMhnMoy8EjJLLlWwIEoySxliim9kYW30JUHiPVyjt0iAw/ZpPmCbUCltYPnq6ZNblIKhTNhqS/oqC9iya5sGKZTOVsTEg34n92uZTf2iPpcZih8rPW8CzA+adIGmyCPcKdLMsBLShd+zuEbTrqpwuh+DLmracZcjPC5Sdf5odDAhKpFuOsQS67RT+1VgWWygSv3YwxDnylc04/PYuaMeIzhBkLrvs7e/OUzRTF56MmfY6rI63QtEjEQzq637zQqJ39nNhu3NmoRRhW/086bHGBUtx0PE0j3aEGvkdh9WJC8y8j8mqqke9/dQ5la+Q3ba4RlhvTbnfQhPDDab3tUifkjKuOsp13mXEmO00Mu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JUpqDohJJOysL1t1uNiHESlvsxPb5cpbW0+ICZqJmUZus1BMW0F5IVBODLIo2zHHjA0=","base64")).toString()),dL}var CL;function XAe(){return typeof CL=="undefined"&&(CL=require("zlib").brotliDecompressSync(Buffer.from("m3wJE1GkN6sQTGg/U6NIb0aTKMP9bivYNuU6vRmRrSm//3UCehrg5OrrHCrSWkCREhF890RJt8fjR4A2EeX46L4IrTIWP/affkbbukX9rgdYBpRx68FI2tVZV558HxxDbdbwcwWkxS9fTf/18/XcF+clrnTSdsJrlW6VKgApOBTI2YUuI09ioW31NNUEPOEYwiH60pTg2ci7Zluqr7fVRbadjqmOuYgcHJcM4LBSeue6QXpmFJpjz6uvUY+qiVCSyyWXY8pujLb8Gjf4fk5Utq7UVA2mJ3RlmbiNgx50eZC/iKz6+5zWK7EBdVOHtfr7yYnjEryCuaayo/JNKQnrzulnbmJV2VwuioDYlbOf/59vWqYk1hgD7K7EWdmIR0GEwwFlnM2UyaNvvVeP0w4roAGcQQMcw+GsoZF19ape/d8OpJcIynmfREpSBaF8FrfDOEt5UsaYTBsEif5XtbLV8UISsUH42gBo3z5ytsc0jVR051TU7o42iUnOubqQZh0rV0okHHIbi9JVSDNXNJ27WhJJ0UFcOQCkA0A5iJRTrGzicT+2A9iMpBpP9K/HMLPdevu+NgYUUYmgecbBv1vifxR6qHpJYLfJLqGa2UoINqVGZPuVV+svIMHCEHvGtE9vL3s1v0alNAHhhbLgmAxd6s/VspNCKKOK/lVFdCXfzx14GtKyVZdT5m/8pmnQKq6SQOv3ma6/18z+LqQ/ayOsvyZQz599+mevPz784zO+/Nr6RpK55Jt68eAFQw9+E0NaYfv1P/Asy495y4oCw5cxMsZg+QUuLtAaYLSBesyzG3nPFvLjJFex/jgrj/75Kd7Ltk5WUKA7zLy+PAVaBmAze3IiIBde+dQgisrwU+TX12lQVqwPWzmaYmnbCkMSAv6tqiVy8As0b5QOuQp0k259vNcVQ4ApWBJRh4lPrUzRTjU/adf4GdE1oEp/y44CfcDw1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aN5NoyK1Us144d5wr0JplvvgO4qrSbOxeQMoAAwM0WzR/cQAO5uYKcFXG/tR4JoD2lFKvLXK5gqvEaQMWVvwI=","base64")).toString()),CL}var ZAe=new Map([[S.makeIdent(null,"fsevents").identHash,VAe],[S.makeIdent(null,"resolve").identHash,_Ae],[S.makeIdent(null,"typescript").identHash,XAe]]),bze={hooks:{registerPackageExtensions:async(t,e)=>{for(let[r,i]of zAe)e(S.parseDescriptor(r,!0),i)},getBuiltinPatch:async(t,e)=>{var s;let r="compat/";if(!e.startsWith(r))return;let i=S.parseIdent(e.slice(r.length)),n=(s=ZAe.get(i.identHash))==null?void 0:s();return typeof n!="undefined"?n:null},reduceDependency:async(t,e,r,i)=>typeof ZAe.get(t.identHash)=="undefined"?t:S.makeDescriptor(t,S.makeRange({protocol:"patch:",source:S.stringifyDescriptor(t),selector:`~builtin`,params:null}))}},vze=bze;var EL={};it(EL,{default:()=>xze});var V0=class extends Be{constructor(){super(...arguments);this.pkg=Y.String("-p,--package",{description:"The package to run the provided command from"});this.quiet=Y.Boolean("-q,--quiet",!1,{description:"Only report critical errors instead of printing the full install logs"});this.command=Y.String();this.args=Y.Proxy()}async execute(){let e=[];this.pkg&&e.push("--package",this.pkg),this.quiet&&e.push("--quiet");let r=S.parseIdent(this.command),i=S.makeIdent(r.scope,`create-${r.name}`);return this.cli.run(["dlx",...e,S.stringifyIdent(i),...this.args])}};V0.paths=[["create"]];var $Ae=V0;var jC=class extends Be{constructor(){super(...arguments);this.packages=Y.Array("-p,--package",{description:"The package(s) to install before running the command"});this.quiet=Y.Boolean("-q,--quiet",!1,{description:"Only report critical errors instead of printing the full install logs"});this.command=Y.String();this.args=Y.Proxy()}async execute(){return fe.telemetry=null,await T.mktempPromise(async e=>{var p;let r=v.join(e,`dlx-${process.pid}`);await T.mkdirPromise(r),await T.writeFilePromise(v.join(r,"package.json"),`{} -`),await T.writeFilePromise(v.join(r,"yarn.lock"),"");let i=v.join(r,".yarnrc.yml"),n=await fe.findProjectCwd(this.context.cwd,wt.lockfile),s=!(await fe.find(this.context.cwd,null,{strict:!1})).get("enableGlobalCache"),o=n!==null?v.join(n,".yarnrc.yml"):null;o!==null&&T.existsSync(o)?(await T.copyFilePromise(o,i),await fe.updateConfiguration(r,d=>{let m=_(P({},d),{enableGlobalCache:s,enableTelemetry:!1});return Array.isArray(d.plugins)&&(m.plugins=d.plugins.map(I=>{let B=typeof I=="string"?I:I.path,b=M.isAbsolute(B)?B:M.resolve(M.fromPortablePath(n),B);return typeof I=="string"?b:{path:b,spec:I.spec}})),m})):await T.writeFilePromise(i,`enableGlobalCache: ${s} -enableTelemetry: false -`);let a=(p=this.packages)!=null?p:[this.command],l=S.parseDescriptor(this.command).name,c=await this.cli.run(["add","--",...a],{cwd:r,quiet:this.quiet});if(c!==0)return c;this.quiet||this.context.stdout.write(` -`);let u=await fe.find(r,this.context.plugins),{project:g,workspace:f}=await Ke.find(u,r);if(f===null)throw new rt(g.cwd,r);await g.restoreInstallState();let h=await Kt.getWorkspaceAccessibleBinaries(f);return h.has(l)===!1&&h.size===1&&typeof this.packages=="undefined"&&(l=Array.from(h)[0][0]),await Kt.executeWorkspaceAccessibleBinary(f,l,this.args,{packageAccessibleBinaries:h,cwd:this.context.cwd,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr})})}};jC.paths=[["dlx"]],jC.usage=ye.Usage({description:"run a package in a temporary environment",details:"\n This command will install a package within a temporary environment, and run its binary script if it contains any. The binary will run within the current cwd.\n\n By default Yarn will download the package named `command`, but this can be changed through the use of the `-p,--package` flag which will instruct Yarn to still run the same command but from a different package.\n\n Using `yarn dlx` as a replacement of `yarn add` isn't recommended, as it makes your project non-deterministic (Yarn doesn't keep track of the packages installed through `dlx` - neither their name, nor their version).\n ",examples:[["Use create-react-app to create a new React app","yarn dlx create-react-app ./my-app"],["Install multiple packages for a single command",`yarn dlx -p typescript -p ts-node ts-node --transpile-only -e "console.log('hello!')"`]]});var ele=jC;var Sze={commands:[$Ae,ele]},xze=Sze;var xL={};it(xL,{default:()=>Dze,fileUtils:()=>IL});var hf=/^(?:[a-zA-Z]:[\\/]|\.{0,2}\/)/,YC=/^[^?]*\.(?:tar\.gz|tgz)(?:::.*)?$/,Nr="file:";var IL={};it(IL,{makeArchiveFromLocator:()=>_0,makeBufferFromLocator:()=>BL,makeLocator:()=>wL,makeSpec:()=>tle,parseSpec:()=>yL});function yL(t){let{params:e,selector:r}=S.parseRange(t),i=M.toPortablePath(r);return{parentLocator:e&&typeof e.locator=="string"?S.parseLocator(e.locator):null,path:i}}function tle({parentLocator:t,path:e,folderHash:r,protocol:i}){let n=t!==null?{locator:S.stringifyLocator(t)}:{},s=typeof r!="undefined"?{hash:r}:{};return S.makeRange({protocol:i,source:e,selector:e,params:P(P({},s),n)})}function wL(t,{parentLocator:e,path:r,folderHash:i,protocol:n}){return S.makeLocator(t,tle({parentLocator:e,path:r,folderHash:i,protocol:n}))}async function _0(t,{protocol:e,fetchOptions:r,inMemory:i=!1}){let{parentLocator:n,path:s}=S.parseFileStyleRange(t.reference,{protocol:e}),o=v.isAbsolute(s)?{packageFs:new Ft(Se.root),prefixPath:Se.dot,localPath:Se.root}:await r.fetcher.fetch(n,r),a=o.localPath?{packageFs:new Ft(Se.root),prefixPath:v.relative(Se.root,o.localPath)}:o;o!==a&&o.releaseFs&&o.releaseFs();let l=a.packageFs,c=v.join(a.prefixPath,s);return await de.releaseAfterUseAsync(async()=>await Ai.makeArchiveFromDirectory(c,{baseFs:l,prefixPath:S.getIdentVendorPath(t),compressionLevel:r.project.configuration.get("compressionLevel"),inMemory:i}),a.releaseFs)}async function BL(t,{protocol:e,fetchOptions:r}){return(await _0(t,{protocol:e,fetchOptions:r,inMemory:!0})).getBufferAndClose()}var QL=class{supports(e,r){return!!e.reference.startsWith(Nr)}getLocalPath(e,r){let{parentLocator:i,path:n}=S.parseFileStyleRange(e.reference,{protocol:Nr});if(v.isAbsolute(n))return n;let s=r.fetcher.getLocalPath(i,r);return s===null?null:v.resolve(s,n)}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the disk`),loader:()=>this.fetchFromDisk(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:S.getIdentVendorPath(e),localPath:this.getLocalPath(e,r),checksum:o}}async fetchFromDisk(e,r){return _0(e,{protocol:Nr,fetchOptions:r})}};var kze=2,bL=class{supportsDescriptor(e,r){return e.range.match(hf)?!0:!!e.range.startsWith(Nr)}supportsLocator(e,r){return!!e.reference.startsWith(Nr)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){return hf.test(e.range)&&(e=S.makeDescriptor(e,`${Nr}${e.range}`)),S.bindDescriptor(e,{locator:S.stringifyLocator(r)})}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){if(!i.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let{path:n,parentLocator:s}=yL(e.range);if(s===null)throw new Error("Assertion failed: The descriptor should have been bound");let o=await BL(S.makeLocator(e,S.makeRange({protocol:Nr,source:n,selector:n,params:{locator:S.stringifyLocator(s)}})),{protocol:Nr,fetchOptions:i.fetchOptions}),a=mn.makeHash(`${kze}`,o).slice(0,6);return[wL(e,{parentLocator:s,path:n,folderHash:a,protocol:Nr})]}async getSatisfying(e,r,i){return null}async resolve(e,r){if(!r.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let i=await r.fetchOptions.fetcher.fetch(e,r.fetchOptions),n=await de.releaseAfterUseAsync(async()=>await Ze.find(i.prefixPath,{baseFs:i.packageFs}),i.releaseFs);return _(P({},e),{version:n.version||"0.0.0",languageName:n.languageName||r.project.configuration.get("defaultLanguageName"),linkType:gt.HARD,conditions:n.getConditions(),dependencies:n.dependencies,peerDependencies:n.peerDependencies,dependenciesMeta:n.dependenciesMeta,peerDependenciesMeta:n.peerDependenciesMeta,bin:n.bin})}};var vL=class{supports(e,r){return YC.test(e.reference)?!!e.reference.startsWith(Nr):!1}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the disk`),loader:()=>this.fetchFromDisk(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:S.getIdentVendorPath(e),checksum:o}}async fetchFromDisk(e,r){let{parentLocator:i,path:n}=S.parseFileStyleRange(e.reference,{protocol:Nr}),s=v.isAbsolute(n)?{packageFs:new Ft(Se.root),prefixPath:Se.dot,localPath:Se.root}:await r.fetcher.fetch(i,r),o=s.localPath?{packageFs:new Ft(Se.root),prefixPath:v.relative(Se.root,s.localPath)}:s;s!==o&&s.releaseFs&&s.releaseFs();let a=o.packageFs,l=v.join(o.prefixPath,n),c=await a.readFilePromise(l);return await de.releaseAfterUseAsync(async()=>await Ai.convertToZip(c,{compressionLevel:r.project.configuration.get("compressionLevel"),prefixPath:S.getIdentVendorPath(e),stripComponents:1}),o.releaseFs)}};var SL=class{supportsDescriptor(e,r){return YC.test(e.range)?!!(e.range.startsWith(Nr)||hf.test(e.range)):!1}supportsLocator(e,r){return YC.test(e.reference)?!!e.reference.startsWith(Nr):!1}shouldPersistResolution(e,r){return!0}bindDescriptor(e,r,i){return hf.test(e.range)&&(e=S.makeDescriptor(e,`${Nr}${e.range}`)),S.bindDescriptor(e,{locator:S.stringifyLocator(r)})}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){let n=e.range;return n.startsWith(Nr)&&(n=n.slice(Nr.length)),[S.makeLocator(e,`${Nr}${M.toPortablePath(n)}`)]}async getSatisfying(e,r,i){return null}async resolve(e,r){if(!r.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let i=await r.fetchOptions.fetcher.fetch(e,r.fetchOptions),n=await de.releaseAfterUseAsync(async()=>await Ze.find(i.prefixPath,{baseFs:i.packageFs}),i.releaseFs);return _(P({},e),{version:n.version||"0.0.0",languageName:n.languageName||r.project.configuration.get("defaultLanguageName"),linkType:gt.HARD,conditions:n.getConditions(),dependencies:n.dependencies,peerDependencies:n.peerDependencies,dependenciesMeta:n.dependenciesMeta,peerDependenciesMeta:n.peerDependenciesMeta,bin:n.bin})}};var Pze={fetchers:[vL,QL],resolvers:[SL,bL]},Dze=Pze;var PL={};it(PL,{default:()=>Nze});var rle=ie(require("querystring")),ile=[/^https?:\/\/(?:([^/]+?)@)?github.com\/([^/#]+)\/([^/#]+)\/tarball\/([^/#]+)(?:#(.*))?$/,/^https?:\/\/(?:([^/]+?)@)?github.com\/([^/#]+)\/([^/#]+?)(?:\.git)?(?:#(.*))?$/];function nle(t){return t?ile.some(e=>!!t.match(e)):!1}function sle(t){let e;for(let a of ile)if(e=t.match(a),e)break;if(!e)throw new Error(Rze(t));let[,r,i,n,s="master"]=e,{commit:o}=rle.default.parse(s);return s=o||s.replace(/[^:]*:/,""),{auth:r,username:i,reponame:n,treeish:s}}function Rze(t){return`Input cannot be parsed as a valid GitHub URL ('${t}').`}var kL=class{supports(e,r){return!!nle(e.reference)}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from GitHub`),loader:()=>this.fetchFromNetwork(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:S.getIdentVendorPath(e),checksum:o}}async fetchFromNetwork(e,r){let i=await Zt.get(this.getLocatorUrl(e,r),{configuration:r.project.configuration});return await T.mktempPromise(async n=>{let s=new Ft(n);await Ai.extractArchiveTo(i,s,{stripComponents:1});let o=Uc.splitRepoUrl(e.reference),a=v.join(n,"package.tgz");await Kt.prepareExternalProject(n,a,{configuration:r.project.configuration,report:r.report,workspace:o.extra.workspace,locator:e});let l=await T.readFilePromise(a);return await Ai.convertToZip(l,{compressionLevel:r.project.configuration.get("compressionLevel"),prefixPath:S.getIdentVendorPath(e),stripComponents:1})})}getLocatorUrl(e,r){let{auth:i,username:n,reponame:s,treeish:o}=sle(e.reference);return`https://${i?`${i}@`:""}github.com/${n}/${s}/archive/${o}.tar.gz`}};var Fze={hooks:{async fetchHostedRepository(t,e,r){if(t!==null)return t;let i=new kL;if(!i.supports(e,r))return null;try{return await i.fetch(e,r)}catch(n){return null}}}},Nze=Fze;var FL={};it(FL,{default:()=>Tze});var qC=/^[^?]*\.(?:tar\.gz|tgz)(?:\?.*)?$/,JC=/^https?:/;var DL=class{supports(e,r){return qC.test(e.reference)?!!JC.test(e.reference):!1}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the remote server`),loader:()=>this.fetchFromNetwork(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:S.getIdentVendorPath(e),checksum:o}}async fetchFromNetwork(e,r){let i=await Zt.get(e.reference,{configuration:r.project.configuration});return await Ai.convertToZip(i,{compressionLevel:r.project.configuration.get("compressionLevel"),prefixPath:S.getIdentVendorPath(e),stripComponents:1})}};var RL=class{supportsDescriptor(e,r){return qC.test(e.range)?!!JC.test(e.range):!1}supportsLocator(e,r){return qC.test(e.reference)?!!JC.test(e.reference):!1}shouldPersistResolution(e,r){return!0}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){return[S.convertDescriptorToLocator(e)]}async getSatisfying(e,r,i){return null}async resolve(e,r){if(!r.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let i=await r.fetchOptions.fetcher.fetch(e,r.fetchOptions),n=await de.releaseAfterUseAsync(async()=>await Ze.find(i.prefixPath,{baseFs:i.packageFs}),i.releaseFs);return _(P({},e),{version:n.version||"0.0.0",languageName:n.languageName||r.project.configuration.get("defaultLanguageName"),linkType:gt.HARD,conditions:n.getConditions(),dependencies:n.dependencies,peerDependencies:n.peerDependencies,dependenciesMeta:n.dependenciesMeta,peerDependenciesMeta:n.peerDependenciesMeta,bin:n.bin})}};var Lze={fetchers:[DL],resolvers:[RL]},Tze=Lze;var ML={};it(ML,{default:()=>M5e});var Rle=ie(Dle()),TL=ie(require("util")),WC=class extends Be{constructor(){super(...arguments);this.private=Y.Boolean("-p,--private",!1,{description:"Initialize a private package"});this.workspace=Y.Boolean("-w,--workspace",!1,{description:"Initialize a workspace root with a `packages/` directory"});this.install=Y.String("-i,--install",!1,{tolerateBoolean:!0,description:"Initialize a package with a specific bundle that will be locked in the project"});this.usev2=Y.Boolean("-2",!1,{hidden:!0});this.yes=Y.Boolean("-y,--yes",{hidden:!0});this.assumeFreshProject=Y.Boolean("--assume-fresh-project",!1,{hidden:!0})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=typeof this.install=="string"?this.install:this.usev2||this.install===!0?"latest":null;return r!==null?await this.executeProxy(e,r):await this.executeRegular(e)}async executeProxy(e,r){if(e.projectCwd!==null&&e.projectCwd!==this.context.cwd)throw new me("Cannot use the --install flag from within a project subdirectory");T.existsSync(this.context.cwd)||await T.mkdirPromise(this.context.cwd,{recursive:!0});let i=v.join(this.context.cwd,e.get("lockfileFilename"));T.existsSync(i)||await T.writeFilePromise(i,"");let n=await this.cli.run(["set","version",r],{quiet:!0});if(n!==0)return n;let s=[];return this.private&&s.push("-p"),this.workspace&&s.push("-w"),this.yes&&s.push("-y"),await T.mktempPromise(async o=>{let{code:a}=await hr.pipevp("yarn",["init",...s],{cwd:this.context.cwd,stdin:this.context.stdin,stdout:this.context.stdout,stderr:this.context.stderr,env:await Kt.makeScriptEnv({binFolder:o})});return a})}async executeRegular(e){var l;let r=null;try{r=(await Ke.find(e,this.context.cwd)).project}catch{r=null}T.existsSync(this.context.cwd)||await T.mkdirPromise(this.context.cwd,{recursive:!0});let i=await Ze.tryFind(this.context.cwd)||new Ze,n=Object.fromEntries(e.get("initFields").entries());i.load(n),i.name=(l=i.name)!=null?l:S.makeIdent(e.get("initScope"),v.basename(this.context.cwd)),i.packageManager=Zr&&de.isTaggedYarnVersion(Zr)?`yarn@${Zr}`:null,typeof i.raw.private=="undefined"&&(this.private||this.workspace&&i.workspaceDefinitions.length===0)&&(i.private=!0),this.workspace&&i.workspaceDefinitions.length===0&&(await T.mkdirPromise(v.join(this.context.cwd,"packages"),{recursive:!0}),i.workspaceDefinitions=[{pattern:"packages/*"}]);let s={};i.exportTo(s),TL.inspect.styles.name="cyan",this.context.stdout.write(`${(0,TL.inspect)(s,{depth:Infinity,colors:!0,compact:!1})} -`);let o=v.join(this.context.cwd,Ze.fileName);await T.changeFilePromise(o,`${JSON.stringify(s,null,2)} -`,{automaticNewlines:!0});let a=v.join(this.context.cwd,"README.md");if(T.existsSync(a)||await T.writeFilePromise(a,`# ${S.stringifyIdent(i.name)} -`),!r||r.cwd===this.context.cwd){let c=v.join(this.context.cwd,wt.lockfile);T.existsSync(c)||await T.writeFilePromise(c,"");let g=["/.yarn/*","!/.yarn/patches","!/.yarn/plugins","!/.yarn/releases","!/.yarn/sdks","","# Swap the comments on the following lines if you don't wish to use zero-installs","# Documentation here: https://yarnpkg.com/features/zero-installs","!/.yarn/cache","#/.pnp.*"].map(m=>`${m} -`).join(""),f=v.join(this.context.cwd,".gitignore");T.existsSync(f)||await T.writeFilePromise(f,g);let h={["*"]:{endOfLine:"lf",insertFinalNewline:!0},["*.{js,json,yml}"]:{charset:"utf-8",indentStyle:"space",indentSize:2}};(0,Rle.default)(h,e.get("initEditorConfig"));let p=`root = true -`;for(let[m,I]of Object.entries(h)){p+=` -[${m}] -`;for(let[B,b]of Object.entries(I))p+=`${B.replace(/[A-Z]/g,H=>`_${H.toLowerCase()}`)} = ${b} -`}let d=v.join(this.context.cwd,".editorconfig");T.existsSync(d)||await T.writeFilePromise(d,p),T.existsSync(v.join(this.context.cwd,".git"))||await hr.execvp("git",["init"],{cwd:this.context.cwd})}}};WC.paths=[["init"]],WC.usage=ye.Usage({description:"create a new package",details:"\n This command will setup a new package in your local directory.\n\n If the `-p,--private` or `-w,--workspace` options are set, the package will be private by default.\n\n If the `-w,--workspace` option is set, the package will be configured to accept a set of workspaces in the `packages/` directory.\n\n If the `-i,--install` option is given a value, Yarn will first download it using `yarn set version` and only then forward the init call to the newly downloaded bundle. Without arguments, the downloaded bundle will be `latest`.\n\n The initial settings of the manifest can be changed by using the `initScope` and `initFields` configuration values. Additionally, Yarn will generate an EditorConfig file whose rules can be altered via `initEditorConfig`, and will initialize a Git repository in the current directory.\n ",examples:[["Create a new package in the local directory","yarn init"],["Create a new private package in the local directory","yarn init -p"],["Create a new package and store the Yarn release inside","yarn init -i=latest"],["Create a new private package and defines it as a workspace root","yarn init -w"]]});var Fle=WC;var T5e={configuration:{initScope:{description:"Scope used when creating packages via the init command",type:ge.STRING,default:null},initFields:{description:"Additional fields to set when creating packages via the init command",type:ge.MAP,valueDefinition:{description:"",type:ge.ANY}},initEditorConfig:{description:"Extra rules to define in the generator editorconfig",type:ge.MAP,valueDefinition:{description:"",type:ge.ANY}}},commands:[Fle]},M5e=T5e;var GL={};it(GL,{default:()=>K5e});var Ua="portal:",Ha="link:";var OL=class{supports(e,r){return!!e.reference.startsWith(Ua)}getLocalPath(e,r){let{parentLocator:i,path:n}=S.parseFileStyleRange(e.reference,{protocol:Ua});if(v.isAbsolute(n))return n;let s=r.fetcher.getLocalPath(i,r);return s===null?null:v.resolve(s,n)}async fetch(e,r){var c;let{parentLocator:i,path:n}=S.parseFileStyleRange(e.reference,{protocol:Ua}),s=v.isAbsolute(n)?{packageFs:new Ft(Se.root),prefixPath:Se.dot,localPath:Se.root}:await r.fetcher.fetch(i,r),o=s.localPath?{packageFs:new Ft(Se.root),prefixPath:v.relative(Se.root,s.localPath),localPath:Se.root}:s;s!==o&&s.releaseFs&&s.releaseFs();let a=o.packageFs,l=v.resolve((c=o.localPath)!=null?c:o.packageFs.getRealPath(),o.prefixPath,n);return s.localPath?{packageFs:new Ft(l,{baseFs:a}),releaseFs:o.releaseFs,prefixPath:Se.dot,localPath:l}:{packageFs:new Zo(l,{baseFs:a}),releaseFs:o.releaseFs,prefixPath:Se.dot}}};var KL=class{supportsDescriptor(e,r){return!!e.range.startsWith(Ua)}supportsLocator(e,r){return!!e.reference.startsWith(Ua)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){return S.bindDescriptor(e,{locator:S.stringifyLocator(r)})}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){let n=e.range.slice(Ua.length);return[S.makeLocator(e,`${Ua}${M.toPortablePath(n)}`)]}async getSatisfying(e,r,i){return null}async resolve(e,r){if(!r.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let i=await r.fetchOptions.fetcher.fetch(e,r.fetchOptions),n=await de.releaseAfterUseAsync(async()=>await Ze.find(i.prefixPath,{baseFs:i.packageFs}),i.releaseFs);return _(P({},e),{version:n.version||"0.0.0",languageName:n.languageName||r.project.configuration.get("defaultLanguageName"),linkType:gt.SOFT,conditions:n.getConditions(),dependencies:new Map([...n.dependencies]),peerDependencies:n.peerDependencies,dependenciesMeta:n.dependenciesMeta,peerDependenciesMeta:n.peerDependenciesMeta,bin:n.bin})}};var UL=class{supports(e,r){return!!e.reference.startsWith(Ha)}getLocalPath(e,r){let{parentLocator:i,path:n}=S.parseFileStyleRange(e.reference,{protocol:Ha});if(v.isAbsolute(n))return n;let s=r.fetcher.getLocalPath(i,r);return s===null?null:v.resolve(s,n)}async fetch(e,r){var c;let{parentLocator:i,path:n}=S.parseFileStyleRange(e.reference,{protocol:Ha}),s=v.isAbsolute(n)?{packageFs:new Ft(Se.root),prefixPath:Se.dot,localPath:Se.root}:await r.fetcher.fetch(i,r),o=s.localPath?{packageFs:new Ft(Se.root),prefixPath:v.relative(Se.root,s.localPath),localPath:Se.root}:s;s!==o&&s.releaseFs&&s.releaseFs();let a=o.packageFs,l=v.resolve((c=o.localPath)!=null?c:o.packageFs.getRealPath(),o.prefixPath,n);return s.localPath?{packageFs:new Ft(l,{baseFs:a}),releaseFs:o.releaseFs,prefixPath:Se.dot,discardFromLookup:!0,localPath:l}:{packageFs:new Zo(l,{baseFs:a}),releaseFs:o.releaseFs,prefixPath:Se.dot,discardFromLookup:!0}}};var HL=class{supportsDescriptor(e,r){return!!e.range.startsWith(Ha)}supportsLocator(e,r){return!!e.reference.startsWith(Ha)}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){return S.bindDescriptor(e,{locator:S.stringifyLocator(r)})}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){let n=e.range.slice(Ha.length);return[S.makeLocator(e,`${Ha}${M.toPortablePath(n)}`)]}async getSatisfying(e,r,i){return null}async resolve(e,r){return _(P({},e),{version:"0.0.0",languageName:r.project.configuration.get("defaultLanguageName"),linkType:gt.SOFT,conditions:null,dependencies:new Map,peerDependencies:new Map,dependenciesMeta:new Map,peerDependenciesMeta:new Map,bin:new Map})}};var O5e={fetchers:[UL,OL],resolvers:[HL,KL]},K5e=O5e;var mT={};it(mT,{default:()=>Y6e});var Ga;(function(i){i[i.YES=0]="YES",i[i.NO=1]="NO",i[i.DEPENDS=2]="DEPENDS"})(Ga||(Ga={}));var jL=(t,e)=>`${t}@${e}`,Nle=(t,e)=>{let r=e.indexOf("#"),i=r>=0?e.substring(r+1):e;return jL(t,i)},qs;(function(s){s[s.NONE=-1]="NONE",s[s.PERF=0]="PERF",s[s.CHECK=1]="CHECK",s[s.REASONS=2]="REASONS",s[s.INTENSIVE_CHECK=9]="INTENSIVE_CHECK"})(qs||(qs={}));var Tle=(t,e={})=>{let r=e.debugLevel||Number(process.env.NM_DEBUG_LEVEL||-1),i=e.check||r>=9,n=e.hoistingLimits||new Map,s={check:i,debugLevel:r,hoistingLimits:n,fastLookupPossible:!0},o;s.debugLevel>=0&&(o=Date.now());let a=U5e(t,s),l=!1,c=0;do l=YL(a,[a],new Set([a.locator]),new Map,s).anotherRoundNeeded,s.fastLookupPossible=!1,c++;while(l);if(s.debugLevel>=0&&console.log(`hoist time: ${Date.now()-o}ms, rounds: ${c}`),s.debugLevel>=1){let u=zC(a);if(YL(a,[a],new Set([a.locator]),new Map,s).isGraphChanged)throw new Error(`The hoisting result is not terminal, prev tree: -${u}, next tree: -${zC(a)}`);let f=Lle(a);if(f)throw new Error(`${f}, after hoisting finished: -${zC(a)}`)}return s.debugLevel>=2&&console.log(zC(a)),H5e(a)},G5e=t=>{let e=t[t.length-1],r=new Map,i=new Set,n=s=>{if(!i.has(s)){i.add(s);for(let o of s.hoistedDependencies.values())r.set(o.name,o);for(let o of s.dependencies.values())s.peerNames.has(o.name)||n(o)}};return n(e),r},j5e=t=>{let e=t[t.length-1],r=new Map,i=new Set,n=new Set,s=(o,a)=>{if(i.has(o))return;i.add(o);for(let c of o.hoistedDependencies.values())if(!a.has(c.name)){let u;for(let g of t)u=g.dependencies.get(c.name),u&&r.set(u.name,u)}let l=new Set;for(let c of o.dependencies.values())l.add(c.name);for(let c of o.dependencies.values())o.peerNames.has(c.name)||s(c,l)};return s(e,n),r},Mle=(t,e)=>{if(e.decoupled)return e;let{name:r,references:i,ident:n,locator:s,dependencies:o,originalDependencies:a,hoistedDependencies:l,peerNames:c,reasons:u,isHoistBorder:g,hoistPriority:f,isWorkspace:h,hoistedFrom:p,hoistedTo:d}=e,m={name:r,references:new Set(i),ident:n,locator:s,dependencies:new Map(o),originalDependencies:new Map(a),hoistedDependencies:new Map(l),peerNames:new Set(c),reasons:new Map(u),decoupled:!0,isHoistBorder:g,hoistPriority:f,isWorkspace:h,hoistedFrom:new Map(p),hoistedTo:new Map(d)},I=m.dependencies.get(r);return I&&I.ident==m.ident&&m.dependencies.set(r,m),t.dependencies.set(m.name,m),m},Y5e=(t,e)=>{let r=new Map([[t.name,[t.ident]]]);for(let n of t.dependencies.values())t.peerNames.has(n.name)||r.set(n.name,[n.ident]);let i=Array.from(e.keys());i.sort((n,s)=>{let o=e.get(n),a=e.get(s);return a.hoistPriority!==o.hoistPriority?a.hoistPriority-o.hoistPriority:a.peerDependents.size!==o.peerDependents.size?a.peerDependents.size-o.peerDependents.size:a.dependents.size-o.dependents.size});for(let n of i){let s=n.substring(0,n.indexOf("@",1)),o=n.substring(s.length+1);if(!t.peerNames.has(s)){let a=r.get(s);a||(a=[],r.set(s,a)),a.indexOf(o)<0&&a.push(o)}}return r},qL=t=>{let e=new Set,r=(i,n=new Set)=>{if(!n.has(i)){n.add(i);for(let s of i.peerNames)if(!t.peerNames.has(s)){let o=t.dependencies.get(s);o&&!e.has(o)&&r(o,n)}e.add(i)}};for(let i of t.dependencies.values())t.peerNames.has(i.name)||r(i);return e},YL=(t,e,r,i,n,s=new Set)=>{let o=e[e.length-1];if(s.has(o))return{anotherRoundNeeded:!1,isGraphChanged:!1};s.add(o);let a=J5e(o),l=Y5e(o,a),c=t==o?new Map:n.fastLookupPossible?G5e(e):j5e(e),u,g=!1,f=!1,h=new Map(Array.from(l.entries()).map(([d,m])=>[d,m[0]])),p=new Map;do{let d=q5e(t,e,r,c,h,l,i,p,n);d.isGraphChanged&&(f=!0),d.anotherRoundNeeded&&(g=!0),u=!1;for(let[m,I]of l)I.length>1&&!o.dependencies.has(m)&&(h.delete(m),I.shift(),h.set(m,I[0]),u=!0)}while(u);for(let d of o.dependencies.values())if(!o.peerNames.has(d.name)&&!r.has(d.locator)){r.add(d.locator);let m=YL(t,[...e,d],r,p,n);m.isGraphChanged&&(f=!0),m.anotherRoundNeeded&&(g=!0),r.delete(d.locator)}return{anotherRoundNeeded:g,isGraphChanged:f}},W5e=(t,e,r,i,n,s,o,a,{outputReason:l,fastLookupPossible:c})=>{let u,g=null,f=new Set;l&&(u=`${Array.from(e).map(m=>wi(m)).join("\u2192")}`);let h=r[r.length-1],d=!(i.ident===h.ident);if(l&&!d&&(g="- self-reference"),d&&(d=!i.isWorkspace,l&&!d&&(g="- workspace")),d&&(d=!h.isWorkspace||h.hoistedFrom.has(i.name)||e.size===1,l&&!d&&(g=h.reasons.get(i.name))),d&&(d=!t.peerNames.has(i.name),l&&!d&&(g=`- cannot shadow peer: ${wi(t.originalDependencies.get(i.name).locator)} at ${u}`)),d){let m=!1,I=n.get(i.name);if(m=!I||I.ident===i.ident,l&&!m&&(g=`- filled by: ${wi(I.locator)} at ${u}`),m)for(let B=r.length-1;B>=1;B--){let R=r[B].dependencies.get(i.name);if(R&&R.ident!==i.ident){m=!1;let H=a.get(h);H||(H=new Set,a.set(h,H)),H.add(i.name),l&&(g=`- filled by ${wi(R.locator)} at ${r.slice(0,B).map(L=>wi(L.locator)).join("\u2192")}`);break}}d=m}if(d&&(d=s.get(i.name)===i.ident,l&&!d&&(g=`- filled by: ${wi(o.get(i.name)[0])} at ${u}`)),d){let m=!0,I=new Set(i.peerNames);for(let B=r.length-1;B>=1;B--){let b=r[B];for(let R of I){if(b.peerNames.has(R)&&b.originalDependencies.has(R))continue;let H=b.dependencies.get(R);H&&t.dependencies.get(R)!==H&&(B===r.length-1?f.add(H):(f=null,m=!1,l&&(g=`- peer dependency ${wi(H.locator)} from parent ${wi(b.locator)} was not hoisted to ${u}`))),I.delete(R)}if(!m)break}d=m}if(d&&!c)for(let m of i.hoistedDependencies.values()){let I=n.get(m.name);if(!I||m.ident!==I.ident){d=!1,l&&(g=`- previously hoisted dependency mismatch, needed: ${wi(m.locator)}, available: ${wi(I==null?void 0:I.locator)}`);break}}return f!==null&&f.size>0?{isHoistable:2,dependsOn:f,reason:g}:{isHoistable:d?0:1,reason:g}},q5e=(t,e,r,i,n,s,o,a,l)=>{let c=e[e.length-1],u=new Set,g=!1,f=!1,h=(m,I,B,b)=>{if(u.has(B))return;let R=[...I,B.locator],H=new Map,L=new Map;for(let q of qL(B)){let A=W5e(c,r,[c,...m,B],q,i,n,s,a,{outputReason:l.debugLevel>=2,fastLookupPossible:l.fastLookupPossible});if(L.set(q,A),A.isHoistable===2)for(let V of A.dependsOn){let W=H.get(V.name)||new Set;W.add(q.name),H.set(V.name,W)}}let K=new Set,J=(q,A,V)=>{if(!K.has(q)){K.add(q),L.set(q,{isHoistable:1,reason:V});for(let W of H.get(q.name)||[])J(B.dependencies.get(W),A,l.debugLevel>=2?`- peer dependency ${wi(q.locator)} from parent ${wi(B.locator)} was not hoisted`:"")}};for(let[q,A]of L)A.isHoistable===1&&J(q,A,A.reason);for(let q of L.keys())if(!K.has(q)){f=!0;let A=o.get(B);A&&A.has(q.name)&&(g=!0),B.dependencies.delete(q.name),B.hoistedDependencies.set(q.name,q),B.reasons.delete(q.name);let V=c.dependencies.get(q.name);if(l.debugLevel>=2){let W=Array.from(I).concat([B.locator]).map(F=>wi(F)).join("\u2192"),X=c.hoistedFrom.get(q.name);X||(X=[],c.hoistedFrom.set(q.name,X)),X.push(W),B.hoistedTo.set(q.name,Array.from(e).map(F=>wi(F.locator)).join("\u2192"))}if(!V)c.ident!==q.ident&&(c.dependencies.set(q.name,q),b.add(q));else for(let W of q.references)V.references.add(W)}if(l.check){let q=Lle(t);if(q)throw new Error(`${q}, after hoisting dependencies of ${[c,...m,B].map(A=>wi(A.locator)).join("\u2192")}: -${zC(t)}`)}let ne=qL(B);for(let q of ne)if(K.has(q)){let A=L.get(q);if((n.get(q.name)===q.ident||!B.reasons.has(q.name))&&A.isHoistable!==0&&B.reasons.set(q.name,A.reason),!q.isHoistBorder&&R.indexOf(q.locator)<0){u.add(B);let W=Mle(B,q);h([...m,B],[...I,B.locator],W,d),u.delete(B)}}},p,d=new Set(qL(c));do{p=d,d=new Set;for(let m of p){if(m.locator===c.locator||m.isHoistBorder)continue;let I=Mle(c,m);h([],Array.from(r),I,d)}}while(d.size>0);return{anotherRoundNeeded:g,isGraphChanged:f}},Lle=t=>{let e=[],r=new Set,i=new Set,n=(s,o,a)=>{if(r.has(s)||(r.add(s),i.has(s)))return;let l=new Map(o);for(let c of s.dependencies.values())s.peerNames.has(c.name)||l.set(c.name,c);for(let c of s.originalDependencies.values()){let u=l.get(c.name),g=()=>`${Array.from(i).concat([s]).map(f=>wi(f.locator)).join("\u2192")}`;if(s.peerNames.has(c.name)){let f=o.get(c.name);(f!==u||!f||f.ident!==c.ident)&&e.push(`${g()} - broken peer promise: expected ${c.ident} but found ${f&&f.ident}`)}else{let f=a.hoistedFrom.get(s.name),h=s.hoistedTo.get(c.name),p=`${f?` hoisted from ${f.join(", ")}`:""}`,d=`${h?` hoisted to ${h}`:""}`,m=`${g()}${p}`;u?u.ident!==c.ident&&e.push(`${m} - broken require promise for ${c.name}${d}: expected ${c.ident}, but found: ${u.ident}`):e.push(`${m} - broken require promise: no required dependency ${c.name}${d} found`)}}i.add(s);for(let c of s.dependencies.values())s.peerNames.has(c.name)||n(c,l,s);i.delete(s)};return n(t,t.dependencies,t),e.join(` -`)},U5e=(t,e)=>{let{identName:r,name:i,reference:n,peerNames:s}=t,o={name:i,references:new Set([n]),locator:jL(r,n),ident:Nle(r,n),dependencies:new Map,originalDependencies:new Map,hoistedDependencies:new Map,peerNames:new Set(s),reasons:new Map,decoupled:!0,isHoistBorder:!0,hoistPriority:0,isWorkspace:!0,hoistedFrom:new Map,hoistedTo:new Map},a=new Map([[t,o]]),l=(c,u)=>{let g=a.get(c),f=!!g;if(!g){let{name:h,identName:p,reference:d,peerNames:m,hoistPriority:I,isWorkspace:B}=c,b=e.hoistingLimits.get(u.locator);g={name:h,references:new Set([d]),locator:jL(p,d),ident:Nle(p,d),dependencies:new Map,originalDependencies:new Map,hoistedDependencies:new Map,peerNames:new Set(m),reasons:new Map,decoupled:!0,isHoistBorder:b?b.has(h):!1,hoistPriority:I||0,isWorkspace:B||!1,hoistedFrom:new Map,hoistedTo:new Map},a.set(c,g)}if(u.dependencies.set(c.name,g),u.originalDependencies.set(c.name,g),f){let h=new Set,p=d=>{if(!h.has(d)){h.add(d),d.decoupled=!1;for(let m of d.dependencies.values())d.peerNames.has(m.name)||p(m)}};p(g)}else for(let h of c.dependencies)l(h,g)};for(let c of t.dependencies)l(c,o);return o},JL=t=>t.substring(0,t.indexOf("@",1)),H5e=t=>{let e={name:t.name,identName:JL(t.locator),references:new Set(t.references),dependencies:new Set},r=new Set([t]),i=(n,s,o)=>{let a=r.has(n),l;if(s===n)l=o;else{let{name:c,references:u,locator:g}=n;l={name:c,identName:JL(g),references:u,dependencies:new Set}}if(o.dependencies.add(l),!a){r.add(n);for(let c of n.dependencies.values())n.peerNames.has(c.name)||i(c,n,l);r.delete(n)}};for(let n of t.dependencies.values())i(n,t,e);return e},J5e=t=>{let e=new Map,r=new Set([t]),i=o=>`${o.name}@${o.ident}`,n=o=>{let a=i(o),l=e.get(a);return l||(l={dependents:new Set,peerDependents:new Set,hoistPriority:0},e.set(a,l)),l},s=(o,a)=>{let l=!!r.has(a);if(n(a).dependents.add(o.ident),!l){r.add(a);for(let u of a.dependencies.values()){let g=n(u);g.hoistPriority=Math.max(g.hoistPriority,u.hoistPriority),a.peerNames.has(u.name)?g.peerDependents.add(a.ident):s(a,u)}}};for(let o of t.dependencies.values())t.peerNames.has(o.name)||s(t,o);return e},wi=t=>{if(!t)return"none";let e=t.indexOf("@",1),r=t.substring(0,e);r.endsWith("$wsroot$")&&(r=`wh:${r.replace("$wsroot$","")}`);let i=t.substring(e+1);if(i==="workspace:.")return".";if(i){let n=(i.indexOf("#")>0?i.split("#")[1]:i).replace("npm:","");return i.startsWith("virtual")&&(r=`v:${r}`),n.startsWith("workspace")&&(r=`w:${r}`,n=""),`${r}${n?`@${n}`:""}`}else return`${r}`},Ole=5e4,zC=t=>{let e=0,r=(n,s,o="")=>{if(e>Ole||s.has(n))return"";e++;let a=Array.from(n.dependencies.values()).sort((c,u)=>c.name.localeCompare(u.name)),l="";s.add(n);for(let c=0;c":"")+(f!==u.name?`a:${u.name}:`:"")+wi(u.locator)+(g?` ${g}`:"")+(u!==n&&h.length>0?`, hoisted from: ${h.join(", ")}`:"")} -`,l+=r(u,s,`${o}${cOle?` -Tree is too large, part of the tree has been dunped -`:"")};var Js;(function(r){r.HARD="HARD",r.SOFT="SOFT"})(Js||(Js={}));var Sn;(function(i){i.WORKSPACES="workspaces",i.DEPENDENCIES="dependencies",i.NONE="none"})(Sn||(Sn={}));var Kle="node_modules",Hc="$wsroot$";var VC=(t,e)=>{let{packageTree:r,hoistingLimits:i,errors:n,preserveSymlinksRequired:s}=z5e(t,e),o=null;if(n.length===0){let a=Tle(r,{hoistingLimits:i});o=V5e(t,a,e)}return{tree:o,errors:n,preserveSymlinksRequired:s}},ms=t=>`${t.name}@${t.reference}`,WL=t=>{let e=new Map;for(let[r,i]of t.entries())if(!i.dirList){let n=e.get(i.locator);n||(n={target:i.target,linkType:i.linkType,locations:[],aliases:i.aliases},e.set(i.locator,n)),n.locations.push(r)}for(let r of e.values())r.locations=r.locations.sort((i,n)=>{let s=i.split(v.delimiter).length,o=n.split(v.delimiter).length;return s!==o?o-s:n.localeCompare(i)});return e},Ule=(t,e)=>{let r=S.isVirtualLocator(t)?S.devirtualizeLocator(t):t,i=S.isVirtualLocator(e)?S.devirtualizeLocator(e):e;return S.areLocatorsEqual(r,i)},zL=(t,e,r,i)=>{if(t.linkType!==Js.SOFT)return!1;let n=M.toPortablePath(r.resolveVirtual&&e.reference&&e.reference.startsWith("virtual:")?r.resolveVirtual(t.packageLocation):t.packageLocation);return v.contains(i,n)===null},_5e=t=>{let e=t.getPackageInformation(t.topLevel);if(e===null)throw new Error("Assertion failed: Expected the top-level package to have been registered");if(t.findPackageLocator(e.packageLocation)===null)throw new Error("Assertion failed: Expected the top-level package to have a physical locator");let i=M.toPortablePath(e.packageLocation.slice(0,-1)),n=new Map,s={children:new Map},o=t.getDependencyTreeRoots(),a=new Map,l=new Set,c=(f,h)=>{let p=ms(f);if(l.has(p))return;l.add(p);let d=t.getPackageInformation(f);if(d){let m=h?ms(h):"";if(ms(f)!==m&&d.linkType===Js.SOFT&&!zL(d,f,t,i)){let I=Hle(d,f,t);(!a.get(I)||f.reference.startsWith("workspace:"))&&a.set(I,f)}for(let[I,B]of d.packageDependencies)B!==null&&(d.packagePeers.has(I)||c(t.getLocator(I,B),f))}};for(let f of o)c(f,null);let u=i.split(v.sep);for(let f of a.values()){let h=t.getPackageInformation(f),d=M.toPortablePath(h.packageLocation.slice(0,-1)).split(v.sep).slice(u.length),m=s;for(let I of d){let B=m.children.get(I);B||(B={children:new Map},m.children.set(I,B)),m=B}m.workspaceLocator=f}let g=(f,h)=>{if(f.workspaceLocator){let p=ms(h),d=n.get(p);d||(d=new Set,n.set(p,d)),d.add(f.workspaceLocator)}for(let p of f.children.values())g(p,f.workspaceLocator||h)};for(let f of s.children.values())g(f,s.workspaceLocator);return n},z5e=(t,e)=>{let r=[],i=!1,n=new Map,s=_5e(t),o=t.getPackageInformation(t.topLevel);if(o===null)throw new Error("Assertion failed: Expected the top-level package to have been registered");let a=t.findPackageLocator(o.packageLocation);if(a===null)throw new Error("Assertion failed: Expected the top-level package to have a physical locator");let l=M.toPortablePath(o.packageLocation.slice(0,-1)),c={name:a.name,identName:a.name,reference:a.reference,peerNames:o.packagePeers,dependencies:new Set,isWorkspace:!0},u=new Map,g=(h,p)=>`${ms(p)}:${h}`,f=(h,p,d,m,I,B,b,R)=>{var X,F;let H=g(h,d),L=u.get(H),K=!!L;!K&&d.name===a.name&&d.reference===a.reference&&(L=c,u.set(H,c));let J=zL(p,d,t,l);if(!L){let D=p.linkType===Js.SOFT&&d.name.endsWith(Hc);L={name:h,identName:d.name,reference:d.reference,dependencies:new Set,peerNames:D?new Set:p.packagePeers,isWorkspace:D},u.set(H,L)}let ne;if(J?ne=2:I.linkType===Js.SOFT?ne=1:ne=0,L.hoistPriority=Math.max(L.hoistPriority||0,ne),R&&!J){let D=ms({name:m.identName,reference:m.reference}),he=n.get(D)||new Set;n.set(D,he),he.add(L.name)}let q=new Map(p.packageDependencies);if(e.project){let D=e.project.workspacesByCwd.get(M.toPortablePath(p.packageLocation.slice(0,-1)));if(D){let he=new Set([...Array.from(D.manifest.peerDependencies.values(),pe=>S.stringifyIdent(pe)),...Array.from(D.manifest.peerDependenciesMeta.keys())]);for(let pe of he)q.has(pe)||(q.set(pe,B.get(pe)||null),L.peerNames.add(pe))}}let A=ms({name:d.name.replace(Hc,""),reference:d.reference}),V=s.get(A);if(V)for(let D of V)q.set(`${D.name}${Hc}`,D.reference);(p!==I||p.linkType!==Js.SOFT||!e.selfReferencesByCwd||e.selfReferencesByCwd.get(b))&&m.dependencies.add(L);let W=d!==a&&p.linkType===Js.SOFT&&!d.name.endsWith(Hc)&&!J;if(!K&&!W){let D=new Map;for(let[he,pe]of q)if(pe!==null){let Ne=t.getLocator(he,pe),Pe=t.getLocator(he.replace(Hc,""),pe),qe=t.getPackageInformation(Pe);if(qe===null)throw new Error("Assertion failed: Expected the package to have been registered");let re=zL(qe,Ne,t,l);if(e.validateExternalSoftLinks&&e.project&&re){qe.packageDependencies.size>0&&(i=!0);for(let[De,$]of qe.packageDependencies)if($!==null){let G=S.parseLocator(Array.isArray($)?`${$[0]}@${$[1]}`:`${De}@${$}`);if(ms(G)!==ms(Ne)){let Ce=q.get(De);if(Ce){let ee=S.parseLocator(Array.isArray(Ce)?`${Ce[0]}@${Ce[1]}`:`${De}@${Ce}`);Ule(ee,G)||r.push({messageName:z.NM_CANT_INSTALL_EXTERNAL_SOFT_LINK,text:`Cannot link ${S.prettyIdent(e.project.configuration,S.parseIdent(Ne.name))} into ${S.prettyLocator(e.project.configuration,S.parseLocator(`${d.name}@${d.reference}`))} dependency ${S.prettyLocator(e.project.configuration,G)} conflicts with parent dependency ${S.prettyLocator(e.project.configuration,ee)}`})}else{let ee=D.get(De);if(ee){let Ue=ee.target,Oe=S.parseLocator(Array.isArray(Ue)?`${Ue[0]}@${Ue[1]}`:`${De}@${Ue}`);Ule(Oe,G)||r.push({messageName:z.NM_CANT_INSTALL_EXTERNAL_SOFT_LINK,text:`Cannot link ${S.prettyIdent(e.project.configuration,S.parseIdent(Ne.name))} into ${S.prettyLocator(e.project.configuration,S.parseLocator(`${d.name}@${d.reference}`))} dependency ${S.prettyLocator(e.project.configuration,G)} conflicts with dependency ${S.prettyLocator(e.project.configuration,Oe)} from sibling portal ${S.prettyIdent(e.project.configuration,S.parseIdent(ee.portal.name))}`})}else D.set(De,{target:G.reference,portal:Ne})}}}}let se=(X=e.hoistingLimitsByCwd)==null?void 0:X.get(b),be=re?b:v.relative(l,M.toPortablePath(qe.packageLocation))||Se.dot,ae=(F=e.hoistingLimitsByCwd)==null?void 0:F.get(be),Ae=se===Sn.DEPENDENCIES||ae===Sn.DEPENDENCIES||ae===Sn.WORKSPACES;f(ms(Ne)===ms(d)?h:he,qe,Ne,L,p,q,be,Ae)}}};return f(a.name,o,a,c,o,o.packageDependencies,Se.dot,!1),{packageTree:c,hoistingLimits:n,errors:r,preserveSymlinksRequired:i}};function Hle(t,e,r){let i=r.resolveVirtual&&e.reference&&e.reference.startsWith("virtual:")?r.resolveVirtual(t.packageLocation):t.packageLocation;return M.toPortablePath(i||t.packageLocation)}function X5e(t,e,r){let i=e.getLocator(t.name.replace(Hc,""),t.reference),n=e.getPackageInformation(i);if(n===null)throw new Error("Assertion failed: Expected the package to be registered");let s,o;return r.pnpifyFs?(o=M.toPortablePath(n.packageLocation),s=Js.SOFT):(o=Hle(n,t,e),s=n.linkType),{linkType:s,target:o}}var V5e=(t,e,r)=>{let i=new Map,n=(u,g,f)=>{let{linkType:h,target:p}=X5e(u,t,r);return{locator:ms(u),nodePath:g,target:p,linkType:h,aliases:f}},s=u=>{let[g,f]=u.split("/");return f?{scope:kr(g),name:kr(f)}:{scope:null,name:kr(g)}},o=new Set,a=(u,g,f)=>{if(!o.has(u)){o.add(u);for(let h of u.dependencies){if(h===u)continue;let p=Array.from(h.references).sort(),d={name:h.identName,reference:p[0]},{name:m,scope:I}=s(h.name),B=I?[I,m]:[m],b=v.join(g,Kle),R=v.join(b,...B),H=`${f}/${d.name}`,L=n(d,f,p.slice(1)),K=!1;if(L.linkType===Js.SOFT&&r.project){let J=r.project.workspacesByCwd.get(L.target.slice(0,-1));K=!!(J&&!J.manifest.name)}if(!h.name.endsWith(Hc)&&!K){let J=i.get(R);if(J){if(J.dirList)throw new Error(`Assertion failed: ${R} cannot merge dir node with leaf node`);{let V=S.parseLocator(J.locator),W=S.parseLocator(L.locator);if(J.linkType!==L.linkType)throw new Error(`Assertion failed: ${R} cannot merge nodes with different link types ${J.nodePath}/${S.stringifyLocator(V)} and ${f}/${S.stringifyLocator(W)}`);if(V.identHash!==W.identHash)throw new Error(`Assertion failed: ${R} cannot merge nodes with different idents ${J.nodePath}/${S.stringifyLocator(V)} and ${f}/s${S.stringifyLocator(W)}`);L.aliases=[...L.aliases,...J.aliases,S.parseLocator(J.locator).reference]}}i.set(R,L);let ne=R.split("/"),q=ne.indexOf(Kle),A=ne.length-1;for(;q>=0&&A>q;){let V=M.toPortablePath(ne.slice(0,A).join(v.sep)),W=kr(ne[A]),X=i.get(V);if(!X)i.set(V,{dirList:new Set([W])});else if(X.dirList){if(X.dirList.has(W))break;X.dirList.add(W)}A--}}a(h,L.linkType===Js.SOFT?L.target:R,H)}}},l=n({name:e.name,reference:Array.from(e.references)[0]},"",[]),c=l.target;return i.set(c,l),a(e,c,""),i};var oT={};it(oT,{PnpInstaller:()=>Cf,PnpLinker:()=>jc,default:()=>m6e,getPnpPath:()=>qA,jsInstallUtils:()=>Ws,pnpUtils:()=>nT,quotePathIfNeeded:()=>uce});var lce=ie(Or()),cce=ie(require("url"));var Gle;(function(r){r.HARD="HARD",r.SOFT="SOFT"})(Gle||(Gle={}));var Ht;(function(f){f.DEFAULT="DEFAULT",f.TOP_LEVEL="TOP_LEVEL",f.FALLBACK_EXCLUSION_LIST="FALLBACK_EXCLUSION_LIST",f.FALLBACK_EXCLUSION_ENTRIES="FALLBACK_EXCLUSION_ENTRIES",f.FALLBACK_EXCLUSION_DATA="FALLBACK_EXCLUSION_DATA",f.PACKAGE_REGISTRY_DATA="PACKAGE_REGISTRY_DATA",f.PACKAGE_REGISTRY_ENTRIES="PACKAGE_REGISTRY_ENTRIES",f.PACKAGE_STORE_DATA="PACKAGE_STORE_DATA",f.PACKAGE_STORE_ENTRIES="PACKAGE_STORE_ENTRIES",f.PACKAGE_INFORMATION_DATA="PACKAGE_INFORMATION_DATA",f.PACKAGE_DEPENDENCIES="PACKAGE_DEPENDENCIES",f.PACKAGE_DEPENDENCY="PACKAGE_DEPENDENCY"})(Ht||(Ht={}));var jle={[Ht.DEFAULT]:{collapsed:!1,next:{["*"]:Ht.DEFAULT}},[Ht.TOP_LEVEL]:{collapsed:!1,next:{fallbackExclusionList:Ht.FALLBACK_EXCLUSION_LIST,packageRegistryData:Ht.PACKAGE_REGISTRY_DATA,["*"]:Ht.DEFAULT}},[Ht.FALLBACK_EXCLUSION_LIST]:{collapsed:!1,next:{["*"]:Ht.FALLBACK_EXCLUSION_ENTRIES}},[Ht.FALLBACK_EXCLUSION_ENTRIES]:{collapsed:!0,next:{["*"]:Ht.FALLBACK_EXCLUSION_DATA}},[Ht.FALLBACK_EXCLUSION_DATA]:{collapsed:!0,next:{["*"]:Ht.DEFAULT}},[Ht.PACKAGE_REGISTRY_DATA]:{collapsed:!1,next:{["*"]:Ht.PACKAGE_REGISTRY_ENTRIES}},[Ht.PACKAGE_REGISTRY_ENTRIES]:{collapsed:!0,next:{["*"]:Ht.PACKAGE_STORE_DATA}},[Ht.PACKAGE_STORE_DATA]:{collapsed:!1,next:{["*"]:Ht.PACKAGE_STORE_ENTRIES}},[Ht.PACKAGE_STORE_ENTRIES]:{collapsed:!0,next:{["*"]:Ht.PACKAGE_INFORMATION_DATA}},[Ht.PACKAGE_INFORMATION_DATA]:{collapsed:!1,next:{packageDependencies:Ht.PACKAGE_DEPENDENCIES,["*"]:Ht.DEFAULT}},[Ht.PACKAGE_DEPENDENCIES]:{collapsed:!1,next:{["*"]:Ht.PACKAGE_DEPENDENCY}},[Ht.PACKAGE_DEPENDENCY]:{collapsed:!0,next:{["*"]:Ht.DEFAULT}}};function Z5e(t,e,r){let i="";i+="[";for(let n=0,s=t.length;ns(o)));let n=r.map((s,o)=>o);return n.sort((s,o)=>{for(let a of i){let l=a[s]a[o]?1:0;if(l!==0)return l}return 0}),n.map(s=>r[s])}function r6e(t){let e=new Map,r=_C(t.fallbackExclusionList||[],[({name:i,reference:n})=>i,({name:i,reference:n})=>n]);for(let{name:i,reference:n}of r){let s=e.get(i);typeof s=="undefined"&&e.set(i,s=new Set),s.add(n)}return Array.from(e).map(([i,n])=>[i,Array.from(n)])}function i6e(t){return _C(t.fallbackPool||[],([e])=>e)}function n6e(t){let e=[];for(let[r,i]of _C(t.packageRegistry,([n])=>n===null?"0":`1${n}`)){let n=[];e.push([r,n]);for(let[s,{packageLocation:o,packageDependencies:a,packagePeers:l,linkType:c,discardFromLookup:u}]of _C(i,([g])=>g===null?"0":`1${g}`)){let g=[];r!==null&&s!==null&&!a.has(r)&&g.push([r,s]);for(let[p,d]of _C(a.entries(),([m])=>m))g.push([p,d]);let f=l&&l.size>0?Array.from(l):void 0,h=u||void 0;n.push([s,{packageLocation:o,packageDependencies:g,packagePeers:f,linkType:c,discardFromLookup:h}])}}return e}function XC(t){return{__info:["This file is automatically generated. Do not touch it, or risk","your modifications being lost. We also recommend you not to read","it either without using the @yarnpkg/pnp package, as the data layout","is entirely unspecified and WILL change from a version to another."],dependencyTreeRoots:t.dependencyTreeRoots,enableTopLevelFallback:t.enableTopLevelFallback||!1,ignorePatternData:t.ignorePattern||null,fallbackExclusionList:r6e(t),fallbackPool:i6e(t),packageRegistryData:n6e(t)}}var zle=ie(Wle());function Vle(t,e){return[t?`${t} -`:"",`/* eslint-disable */ - -`,`try { -`,` Object.freeze({}).detectStrictMode = true; -`,`} catch (error) { -`," throw new Error(`The whole PnP file got strict-mode-ified, which is known to break (Emscripten libraries aren't strict mode). This usually happens when the file goes through Babel.`);\n",`} -`,` -`,`var __non_webpack_module__ = module; -`,` -`,`function $$SETUP_STATE(hydrateRuntimeState, basePath) { -`,e.replace(/^/gm," "),`} -`,` -`,(0,zle.default)()].join("")}function s6e(t){return JSON.stringify(t,null,2)}function o6e(t){return[`return hydrateRuntimeState(${qle(t)}, {basePath: basePath || __dirname}); -`].join("")}function a6e(t){return[`var path = require('path'); -`,`var dataLocation = path.resolve(__dirname, ${JSON.stringify(t)}); -`,`return hydrateRuntimeState(require(dataLocation), {basePath: basePath || path.dirname(dataLocation)}); -`].join("")}function _le(t){let e=XC(t),r=o6e(e);return Vle(t.shebang,r)}function Xle(t){let e=XC(t),r=a6e(t.dataLocation),i=Vle(t.shebang,r);return{dataFile:s6e(e),loaderFile:i}}var tce=ie(require("fs")),u6e=ie(require("path")),rce=ie(require("util"));function _L(t,{basePath:e}){let r=M.toPortablePath(e),i=v.resolve(r),n=t.ignorePatternData!==null?new RegExp(t.ignorePatternData):null,s=new Map,o=new Map(t.packageRegistryData.map(([g,f])=>[g,new Map(f.map(([h,p])=>{var b;if(g===null!=(h===null))throw new Error("Assertion failed: The name and reference should be null, or neither should");let d=(b=p.discardFromLookup)!=null?b:!1,m={name:g,reference:h},I=s.get(p.packageLocation);I?(I.discardFromLookup=I.discardFromLookup&&d,d||(I.locator=m)):s.set(p.packageLocation,{locator:m,discardFromLookup:d});let B=null;return[h,{packageDependencies:new Map(p.packageDependencies),packagePeers:new Set(p.packagePeers),linkType:p.linkType,discardFromLookup:d,get packageLocation(){return B||(B=v.join(i,p.packageLocation))}}]}))])),a=new Map(t.fallbackExclusionList.map(([g,f])=>[g,new Set(f)])),l=new Map(t.fallbackPool),c=t.dependencyTreeRoots,u=t.enableTopLevelFallback;return{basePath:r,dependencyTreeRoots:c,enableTopLevelFallback:u,fallbackExclusionList:a,fallbackPool:l,ignorePattern:n,packageLocatorsByLocations:s,packageRegistry:o}}var df=ie(require("module")),ece=ie($le()),ZL=ie(require("util"));var ur;(function(l){l.API_ERROR="API_ERROR",l.BUILTIN_NODE_RESOLUTION_FAILED="BUILTIN_NODE_RESOLUTION_FAILED",l.MISSING_DEPENDENCY="MISSING_DEPENDENCY",l.MISSING_PEER_DEPENDENCY="MISSING_PEER_DEPENDENCY",l.QUALIFIED_PATH_RESOLUTION_FAILED="QUALIFIED_PATH_RESOLUTION_FAILED",l.INTERNAL="INTERNAL",l.UNDECLARED_DEPENDENCY="UNDECLARED_DEPENDENCY",l.UNSUPPORTED="UNSUPPORTED"})(ur||(ur={}));var c6e=new Set([ur.BUILTIN_NODE_RESOLUTION_FAILED,ur.MISSING_DEPENDENCY,ur.MISSING_PEER_DEPENDENCY,ur.QUALIFIED_PATH_RESOLUTION_FAILED,ur.UNDECLARED_DEPENDENCY]);function ui(t,e,r={}){let i=c6e.has(t)?"MODULE_NOT_FOUND":t,n={configurable:!0,writable:!0,enumerable:!1};return Object.defineProperties(new Error(e),{code:_(P({},n),{value:i}),pnpCode:_(P({},n),{value:t}),data:_(P({},n),{value:r})})}function YA(t){return M.normalize(M.fromPortablePath(t))}function $L(t,e){let r=Number(process.env.PNP_ALWAYS_WARN_ON_FALLBACK)>0,i=Number(process.env.PNP_DEBUG_LEVEL),n=new Set(df.Module.builtinModules||Object.keys(process.binding("natives"))),s=re=>n.has(re)||re.startsWith("node:"),o=/^(?![a-zA-Z]:[\\/]|\\\\|\.{0,2}(?:\/|$))((?:node:)?(?:@[^/]+\/)?[^/]+)\/*(.*|)$/,a=/^(\/|\.{1,2}(\/|$))/,l=/\/$/,c=/^\.{0,2}\//,u={name:null,reference:null},g=[],f=new Set;if(t.enableTopLevelFallback===!0&&g.push(u),e.compatibilityMode!==!1)for(let re of["react-scripts","gatsby"]){let se=t.packageRegistry.get(re);if(se)for(let be of se.keys()){if(be===null)throw new Error("Assertion failed: This reference shouldn't be null");g.push({name:re,reference:be})}}let{ignorePattern:h,packageRegistry:p,packageLocatorsByLocations:d}=t;function m(re,se){return{fn:re,args:se,error:null,result:null}}function I(re){var De,$,G,Ce,ee,Ue;let se=(G=($=(De=process.stderr)==null?void 0:De.hasColors)==null?void 0:$.call(De))!=null?G:process.stdout.isTTY,be=(Oe,vt)=>`[${Oe}m${vt}`,ae=re.error;console.error(ae?be("31;1",`\u2716 ${(Ce=re.error)==null?void 0:Ce.message.replace(/\n.*/s,"")}`):be("33;1","\u203C Resolution")),re.args.length>0&&console.error();for(let Oe of re.args)console.error(` ${be("37;1","In \u2190")} ${(0,ZL.inspect)(Oe,{colors:se,compact:!0})}`);re.result&&(console.error(),console.error(` ${be("37;1","Out \u2192")} ${(0,ZL.inspect)(re.result,{colors:se,compact:!0})}`));let Ae=(Ue=(ee=new Error().stack.match(/(?<=^ +)at.*/gm))==null?void 0:ee.slice(2))!=null?Ue:[];if(Ae.length>0){console.error();for(let Oe of Ae)console.error(` ${be("38;5;244",Oe)}`)}console.error()}function B(re,se){if(e.allowDebug===!1)return se;if(Number.isFinite(i)){if(i>=2)return(...be)=>{let ae=m(re,be);try{return ae.result=se(...be)}catch(Ae){throw ae.error=Ae}finally{I(ae)}};if(i>=1)return(...be)=>{try{return se(...be)}catch(ae){let Ae=m(re,be);throw Ae.error=ae,I(Ae),ae}}}return se}function b(re){let se=W(re);if(!se)throw ui(ur.INTERNAL,"Couldn't find a matching entry in the dependency tree for the specified parent (this is probably an internal error)");return se}function R(re){if(re.name===null)return!0;for(let se of t.dependencyTreeRoots)if(se.name===re.name&&se.reference===re.reference)return!0;return!1}let H=new Set(["default","node","require"]);function L(re,se=H){let be=D(v.join(re,"internal.js"),{resolveIgnored:!0,includeDiscardFromLookup:!0});if(be===null)throw ui(ur.INTERNAL,`The locator that owns the "${re}" path can't be found inside the dependency tree (this is probably an internal error)`);let{packageLocation:ae}=b(be),Ae=v.join(ae,wt.manifest);if(!e.fakeFs.existsSync(Ae))return null;let De=JSON.parse(e.fakeFs.readFileSync(Ae,"utf8")),$=v.contains(ae,re);if($===null)throw ui(ur.INTERNAL,"unqualifiedPath doesn't contain the packageLocation (this is probably an internal error)");c.test($)||($=`./${$}`);let G=(0,ece.resolve)(De,v.normalize($),{conditions:se,unsafe:!0});return typeof G=="string"?v.join(ae,G):null}function K(re,se,{extensions:be}){let ae;try{se.push(re),ae=e.fakeFs.statSync(re)}catch(Ae){}if(ae&&!ae.isDirectory())return e.fakeFs.realpathSync(re);if(ae&&ae.isDirectory()){let Ae;try{Ae=JSON.parse(e.fakeFs.readFileSync(v.join(re,wt.manifest),"utf8"))}catch($){}let De;if(Ae&&Ae.main&&(De=v.resolve(re,Ae.main)),De&&De!==re){let $=K(De,se,{extensions:be});if($!==null)return $}}for(let Ae=0,De=be.length;Ae{let G=JSON.stringify($.name);if(ae.has(G))return;ae.add(G);let Ce=X($);for(let ee of Ce)if(b(ee).packagePeers.has(re))Ae(ee);else{let Oe=be.get(ee.name);typeof Oe=="undefined"&&be.set(ee.name,Oe=new Set),Oe.add(ee.reference)}};Ae(se);let De=[];for(let $ of[...be.keys()].sort())for(let G of[...be.get($)].sort())De.push({name:$,reference:G});return De}function D(re,{resolveIgnored:se=!1,includeDiscardFromLookup:be=!1}={}){if(q(re)&&!se)return null;let ae=v.relative(t.basePath,re);ae.match(a)||(ae=`./${ae}`),ae.endsWith("/")||(ae=`${ae}/`);do{let Ae=d.get(ae);if(typeof Ae=="undefined"||Ae.discardFromLookup&&!be){ae=ae.substring(0,ae.lastIndexOf("/",ae.length-2)+1);continue}return Ae.locator}while(ae!=="");return null}function he(re,se,{considerBuiltins:be=!0}={}){if(re==="pnpapi")return M.toPortablePath(e.pnpapiResolution);if(be&&s(re))return null;let ae=YA(re),Ae=se&&YA(se);if(se&&q(se)&&(!v.isAbsolute(re)||D(re)===null)){let G=ne(re,se);if(G===!1)throw ui(ur.BUILTIN_NODE_RESOLUTION_FAILED,`The builtin node resolution algorithm was unable to resolve the requested module (it didn't go through the pnp resolver because the issuer was explicitely ignored by the regexp) - -Require request: "${ae}" -Required by: ${Ae} -`,{request:ae,issuer:Ae});return M.toPortablePath(G)}let De,$=re.match(o);if($){if(!se)throw ui(ur.API_ERROR,"The resolveToUnqualified function must be called with a valid issuer when the path isn't a builtin nor absolute",{request:ae,issuer:Ae});let[,G,Ce]=$,ee=D(se);if(!ee){let yr=ne(re,se);if(yr===!1)throw ui(ur.BUILTIN_NODE_RESOLUTION_FAILED,`The builtin node resolution algorithm was unable to resolve the requested module (it didn't go through the pnp resolver because the issuer doesn't seem to be part of the Yarn-managed dependency tree). - -Require path: "${ae}" -Required by: ${Ae} -`,{request:ae,issuer:Ae});return M.toPortablePath(yr)}let Oe=b(ee).packageDependencies.get(G),vt=null;if(Oe==null&&ee.name!==null){let yr=t.fallbackExclusionList.get(ee.name);if(!yr||!yr.has(ee.reference)){for(let Qi=0,Go=g.length;QiR(Ki))?dt=ui(ur.MISSING_PEER_DEPENDENCY,`${ee.name} tried to access ${G} (a peer dependency) but it isn't provided by your application; this makes the require call ambiguous and unsound. - -Required package: ${G}${G!==ae?` (via "${ae}")`:""} -Required by: ${ee.name}@${ee.reference} (via ${Ae}) -${yr.map(Ki=>`Ancestor breaking the chain: ${Ki.name}@${Ki.reference} -`).join("")} -`,{request:ae,issuer:Ae,issuerLocator:Object.assign({},ee),dependencyName:G,brokenAncestors:yr}):dt=ui(ur.MISSING_PEER_DEPENDENCY,`${ee.name} tried to access ${G} (a peer dependency) but it isn't provided by its ancestors; this makes the require call ambiguous and unsound. - -Required package: ${G}${G!==ae?` (via "${ae}")`:""} -Required by: ${ee.name}@${ee.reference} (via ${Ae}) - -${yr.map(Ki=>`Ancestor breaking the chain: ${Ki.name}@${Ki.reference} -`).join("")} -`,{request:ae,issuer:Ae,issuerLocator:Object.assign({},ee),dependencyName:G,brokenAncestors:yr})}else Oe===void 0&&(!be&&s(re)?R(ee)?dt=ui(ur.UNDECLARED_DEPENDENCY,`Your application tried to access ${G}. While this module is usually interpreted as a Node builtin, your resolver is running inside a non-Node resolution context where such builtins are ignored. Since ${G} isn't otherwise declared in your dependencies, this makes the require call ambiguous and unsound. - -Required package: ${G}${G!==ae?` (via "${ae}")`:""} -Required by: ${Ae} -`,{request:ae,issuer:Ae,dependencyName:G}):dt=ui(ur.UNDECLARED_DEPENDENCY,`${ee.name} tried to access ${G}. While this module is usually interpreted as a Node builtin, your resolver is running inside a non-Node resolution context where such builtins are ignored. Since ${G} isn't otherwise declared in ${ee.name}'s dependencies, this makes the require call ambiguous and unsound. - -Required package: ${G}${G!==ae?` (via "${ae}")`:""} -Required by: ${Ae} -`,{request:ae,issuer:Ae,issuerLocator:Object.assign({},ee),dependencyName:G}):R(ee)?dt=ui(ur.UNDECLARED_DEPENDENCY,`Your application tried to access ${G}, but it isn't declared in your dependencies; this makes the require call ambiguous and unsound. - -Required package: ${G}${G!==ae?` (via "${ae}")`:""} -Required by: ${Ae} -`,{request:ae,issuer:Ae,dependencyName:G}):dt=ui(ur.UNDECLARED_DEPENDENCY,`${ee.name} tried to access ${G}, but it isn't declared in its dependencies; this makes the require call ambiguous and unsound. - -Required package: ${G}${G!==ae?` (via "${ae}")`:""} -Required by: ${ee.name}@${ee.reference} (via ${Ae}) -`,{request:ae,issuer:Ae,issuerLocator:Object.assign({},ee),dependencyName:G}));if(Oe==null){if(vt===null||dt===null)throw dt||new Error("Assertion failed: Expected an error to have been set");Oe=vt;let yr=dt.message.replace(/\n.*/g,"");dt.message=yr,!f.has(yr)&&i!==0&&(f.add(yr),process.emitWarning(dt))}let ri=Array.isArray(Oe)?{name:Oe[0],reference:Oe[1]}:{name:G,reference:Oe},ii=b(ri);if(!ii.packageLocation)throw ui(ur.MISSING_DEPENDENCY,`A dependency seems valid but didn't get installed for some reason. This might be caused by a partial install, such as dev vs prod. - -Required package: ${ri.name}@${ri.reference}${ri.name!==ae?` (via "${ae}")`:""} -Required by: ${ee.name}@${ee.reference} (via ${Ae}) -`,{request:ae,issuer:Ae,dependencyLocator:Object.assign({},ri)});let an=ii.packageLocation;Ce?De=v.join(an,Ce):De=an}else if(v.isAbsolute(re))De=v.normalize(re);else{if(!se)throw ui(ur.API_ERROR,"The resolveToUnqualified function must be called with a valid issuer when the path isn't a builtin nor absolute",{request:ae,issuer:Ae});let G=v.resolve(se);se.match(l)?De=v.normalize(v.join(G,re)):De=v.normalize(v.join(v.dirname(G),re))}return v.normalize(De)}function pe(re,se,be=H){if(a.test(re))return se;let ae=L(se,be);return ae?v.normalize(ae):se}function Ne(re,{extensions:se=Object.keys(df.Module._extensions)}={}){let be=[],ae=K(re,be,{extensions:se});if(ae)return v.normalize(ae);{let Ae=YA(re),De=D(re);if(De){let{packageLocation:$}=b(De);if(!e.fakeFs.existsSync($)){let G=$.includes("/unplugged/")?"Required unplugged package missing from disk. This may happen when switching branches without running installs (unplugged packages must be fully materialized on disk to work).":"Required package missing from disk. If you keep your packages inside your repository then restarting the Node process may be enough. Otherwise, try to run an install first.";throw ui(ur.QUALIFIED_PATH_RESOLUTION_FAILED,`${G} - -Missing package: ${De.name}@${De.reference} -Expected package location: ${YA($)} -`,{unqualifiedPath:Ae})}}throw ui(ur.QUALIFIED_PATH_RESOLUTION_FAILED,`Qualified path resolution failed - none of those files can be found on the disk. - -Source path: ${Ae} -${be.map($=>`Not found: ${YA($)} -`).join("")}`,{unqualifiedPath:Ae})}}function Pe(re,se,{considerBuiltins:be,extensions:ae,conditions:Ae}={}){let De=he(re,se,{considerBuiltins:be});if(re==="pnpapi")return De;if(De===null)return null;let $=()=>se!==null?q(se):!1,G=(!be||!s(re))&&!$()?pe(re,De,Ae):De;try{return Ne(G,{extensions:ae})}catch(Ce){throw Ce.pnpCode==="QUALIFIED_PATH_RESOLUTION_FAILED"&&Object.assign(Ce.data,{request:YA(re),issuer:se&&YA(se)}),Ce}}function qe(re){let se=v.normalize(re),be=Pr.resolveVirtual(se);return be!==se?be:null}return{VERSIONS:A,topLevel:V,getLocator:(re,se)=>Array.isArray(se)?{name:se[0],reference:se[1]}:{name:re,reference:se},getDependencyTreeRoots:()=>[...t.dependencyTreeRoots],getAllLocators(){let re=[];for(let[se,be]of p)for(let ae of be.keys())se!==null&&ae!==null&&re.push({name:se,reference:ae});return re},getPackageInformation:re=>{let se=W(re);if(se===null)return null;let be=M.fromPortablePath(se.packageLocation);return _(P({},se),{packageLocation:be})},findPackageLocator:re=>D(M.toPortablePath(re)),resolveToUnqualified:B("resolveToUnqualified",(re,se,be)=>{let ae=se!==null?M.toPortablePath(se):null,Ae=he(M.toPortablePath(re),ae,be);return Ae===null?null:M.fromPortablePath(Ae)}),resolveUnqualified:B("resolveUnqualified",(re,se)=>M.fromPortablePath(Ne(M.toPortablePath(re),se))),resolveRequest:B("resolveRequest",(re,se,be)=>{let ae=se!==null?M.toPortablePath(se):null,Ae=Pe(M.toPortablePath(re),ae,be);return Ae===null?null:M.fromPortablePath(Ae)}),resolveVirtual:B("resolveVirtual",re=>{let se=qe(M.toPortablePath(re));return se!==null?M.fromPortablePath(se):null})}}var ISt=(0,rce.promisify)(tce.readFile);var ice=(t,e,r)=>{let i=XC(t),n=_L(i,{basePath:e}),s=M.join(e,wt.pnpCjs);return $L(n,{fakeFs:r,pnpapiResolution:s})};var tT=ie(sce());var Ws={};it(Ws,{checkAndReportManifestCompatibility:()=>oce,extractBuildScripts:()=>Z0,getExtractHint:()=>rT,hasBindingGyp:()=>iT});function oce(t,e,{configuration:r,report:i}){return S.isPackageCompatible(t,{os:[process.platform],cpu:[process.arch]})?!0:(i==null||i.reportWarningOnce(z.INCOMPATIBLE_ARCHITECTURE,`${S.prettyLocator(r,t)} The ${process.platform}-${process.arch} architecture is incompatible with this module, ${e} skipped.`),!1)}function Z0(t,e,r,{configuration:i,report:n}){let s=[];for(let a of["preinstall","install","postinstall"])e.manifest.scripts.has(a)&&s.push([Gn.SCRIPT,a]);return!e.manifest.scripts.has("install")&&e.misc.hasBindingGyp&&s.push([Gn.SHELLCODE,"node-gyp rebuild"]),s.length===0?[]:t.linkType!==gt.HARD?(n==null||n.reportWarningOnce(z.SOFT_LINK_BUILD,`${S.prettyLocator(i,t)} lists build scripts, but is referenced through a soft link. Soft links don't support build scripts, so they'll be ignored.`),[]):r&&r.built===!1?(n==null||n.reportInfoOnce(z.BUILD_DISABLED,`${S.prettyLocator(i,t)} lists build scripts, but its build has been explicitly disabled through configuration.`),[]):!i.get("enableScripts")&&!r.built?(n==null||n.reportWarningOnce(z.DISABLED_BUILD_SCRIPTS,`${S.prettyLocator(i,t)} lists build scripts, but all build scripts have been disabled.`),[]):oce(t,"build",{configuration:i,report:n})?s:[]}var g6e=new Set([".exe",".h",".hh",".hpp",".c",".cc",".cpp",".java",".jar",".node"]);function rT(t){return t.packageFs.getExtractHint({relevantExtensions:g6e})}function iT(t){let e=v.join(t.prefixPath,"binding.gyp");return t.packageFs.existsSync(e)}var nT={};it(nT,{getUnpluggedPath:()=>ZC});function ZC(t,{configuration:e}){return v.resolve(e.get("pnpUnpluggedFolder"),S.slugifyLocator(t))}var f6e=new Set([S.makeIdent(null,"nan").identHash,S.makeIdent(null,"node-gyp").identHash,S.makeIdent(null,"node-pre-gyp").identHash,S.makeIdent(null,"node-addon-api").identHash,S.makeIdent(null,"fsevents").identHash]),jc=class{constructor(){this.mode="strict";this.pnpCache=new Map}supportsPackage(e,r){return!(r.project.configuration.get("nodeLinker")!=="pnp"||r.project.configuration.get("pnpMode")!==this.mode)}async findPackageLocation(e,r){let i=qA(r.project).cjs;if(!T.existsSync(i))throw new me(`The project in ${ue.pretty(r.project.configuration,`${r.project.cwd}/package.json`,ue.Type.PATH)} doesn't seem to have been installed - running an install there might help`);let n=de.getFactoryWithDefault(this.pnpCache,i,()=>de.dynamicRequire(i,{cachingStrategy:de.CachingStrategy.FsTime})),s={name:S.stringifyIdent(e),reference:e.reference},o=n.getPackageInformation(s);if(!o)throw new me(`Couldn't find ${S.prettyLocator(r.project.configuration,e)} in the currently installed PnP map - running an install might help`);return M.toPortablePath(o.packageLocation)}async findPackageLocator(e,r){let i=qA(r.project).cjs;if(!T.existsSync(i))return null;let s=de.getFactoryWithDefault(this.pnpCache,i,()=>de.dynamicRequire(i,{cachingStrategy:de.CachingStrategy.FsTime})).findPackageLocator(M.fromPortablePath(e));return s?S.makeLocator(S.parseIdent(s.name),s.reference):null}makeInstaller(e){return new Cf(e)}},Cf=class{constructor(e){this.opts=e;this.mode="strict";this.packageRegistry=new Map;this.virtualTemplates=new Map;this.isESMLoaderRequired=!1;this.customData={store:new Map};this.unpluggedPaths=new Set;this.opts=e}getCustomDataKey(){return JSON.stringify({name:"PnpInstaller",version:2})}attachCustomData(e){this.customData=e}async installPackage(e,r){let i=S.stringifyIdent(e),n=e.reference,s=!!this.opts.project.tryWorkspaceByLocator(e),o=S.isVirtualLocator(e),a=e.peerDependencies.size>0&&!o,l=!a&&!s,c=!a&&e.linkType!==gt.SOFT,u,g;if(l||c){let B=o?S.devirtualizeLocator(e):e;u=this.customData.store.get(B.locatorHash),typeof u=="undefined"&&(u=await h6e(r),e.linkType===gt.HARD&&this.customData.store.set(B.locatorHash,u)),u.manifest.type==="module"&&(this.isESMLoaderRequired=!0),g=this.opts.project.getDependencyMeta(B,e.version)}let f=l?Z0(e,u,g,{configuration:this.opts.project.configuration,report:this.opts.report}):[],h=c?await this.unplugPackageIfNeeded(e,u,r,g):r.packageFs;if(v.isAbsolute(r.prefixPath))throw new Error(`Assertion failed: Expected the prefix path (${r.prefixPath}) to be relative to the parent`);let p=v.resolve(h.getRealPath(),r.prefixPath),d=sT(this.opts.project.cwd,p),m=new Map,I=new Set;if(o){for(let B of e.peerDependencies.values())m.set(S.stringifyIdent(B),null),I.add(S.stringifyIdent(B));if(!s){let B=S.devirtualizeLocator(e);this.virtualTemplates.set(B.locatorHash,{location:sT(this.opts.project.cwd,Pr.resolveVirtual(p)),locator:B})}}return de.getMapWithDefault(this.packageRegistry,i).set(n,{packageLocation:d,packageDependencies:m,packagePeers:I,linkType:e.linkType,discardFromLookup:r.discardFromLookup||!1}),{packageLocation:p,buildDirective:f.length>0?f:null}}async attachInternalDependencies(e,r){let i=this.getPackageInformation(e);for(let[n,s]of r){let o=S.areIdentsEqual(n,s)?s.reference:[S.stringifyIdent(s),s.reference];i.packageDependencies.set(S.stringifyIdent(n),o)}}async attachExternalDependents(e,r){for(let i of r)this.getDiskInformation(i).packageDependencies.set(S.stringifyIdent(e),e.reference)}async finalizeInstall(){if(this.opts.project.configuration.get("pnpMode")!==this.mode)return;let e=qA(this.opts.project);if(T.existsSync(e.cjsLegacy)&&(this.opts.report.reportWarning(z.UNNAMED,`Removing the old ${ue.pretty(this.opts.project.configuration,wt.pnpJs,ue.Type.PATH)} file. You might need to manually update existing references to reference the new ${ue.pretty(this.opts.project.configuration,wt.pnpCjs,ue.Type.PATH)} file. If you use Editor SDKs, you'll have to rerun ${ue.pretty(this.opts.project.configuration,"yarn sdks",ue.Type.CODE)}.`),await T.removePromise(e.cjsLegacy)),this.isEsmEnabled()||await T.removePromise(e.esmLoader),this.opts.project.configuration.get("nodeLinker")!=="pnp"){await T.removePromise(e.cjs),await T.removePromise(this.opts.project.configuration.get("pnpDataPath")),await T.removePromise(e.esmLoader);return}for(let{locator:u,location:g}of this.virtualTemplates.values())de.getMapWithDefault(this.packageRegistry,S.stringifyIdent(u)).set(u.reference,{packageLocation:g,packageDependencies:new Map,packagePeers:new Set,linkType:gt.SOFT,discardFromLookup:!1});this.packageRegistry.set(null,new Map([[null,this.getPackageInformation(this.opts.project.topLevelWorkspace.anchoredLocator)]]));let r=this.opts.project.configuration.get("pnpFallbackMode"),i=this.opts.project.workspaces.map(({anchoredLocator:u})=>({name:S.stringifyIdent(u),reference:u.reference})),n=r!=="none",s=[],o=new Map,a=de.buildIgnorePattern([".yarn/sdks/**",...this.opts.project.configuration.get("pnpIgnorePatterns")]),l=this.packageRegistry,c=this.opts.project.configuration.get("pnpShebang");if(r==="dependencies-only")for(let u of this.opts.project.storedPackages.values())this.opts.project.tryWorkspaceByLocator(u)&&s.push({name:S.stringifyIdent(u),reference:u.reference});return await this.finalizeInstallWithPnp({dependencyTreeRoots:i,enableTopLevelFallback:n,fallbackExclusionList:s,fallbackPool:o,ignorePattern:a,packageRegistry:l,shebang:c}),{customData:this.customData}}async transformPnpSettings(e){}isEsmEnabled(){if(this.opts.project.configuration.sources.has("pnpEnableEsmLoader"))return this.opts.project.configuration.get("pnpEnableEsmLoader");if(this.isESMLoaderRequired)return!0;for(let e of this.opts.project.workspaces)if(e.manifest.type==="module")return!0;return!1}async finalizeInstallWithPnp(e){let r=qA(this.opts.project),i=this.opts.project.configuration.get("pnpDataPath"),n=await this.locateNodeModules(e.ignorePattern);if(n.length>0){this.opts.report.reportWarning(z.DANGEROUS_NODE_MODULES,"One or more node_modules have been detected and will be removed. This operation may take some time.");for(let o of n)await T.removePromise(o)}if(await this.transformPnpSettings(e),this.opts.project.configuration.get("pnpEnableInlining")){let o=_le(e);await T.changeFilePromise(r.cjs,o,{automaticNewlines:!0,mode:493}),await T.removePromise(i)}else{let o=v.relative(v.dirname(r.cjs),i),{dataFile:a,loaderFile:l}=Xle(_(P({},e),{dataLocation:o}));await T.changeFilePromise(r.cjs,l,{automaticNewlines:!0,mode:493}),await T.changeFilePromise(i,a,{automaticNewlines:!0,mode:420})}this.isEsmEnabled()&&(this.opts.report.reportWarning(z.UNNAMED,"ESM support for PnP uses the experimental loader API and is therefore experimental"),await T.changeFilePromise(r.esmLoader,(0,tT.default)(),{automaticNewlines:!0,mode:420}));let s=this.opts.project.configuration.get("pnpUnpluggedFolder");if(this.unpluggedPaths.size===0)await T.removePromise(s);else for(let o of await T.readdirPromise(s)){let a=v.resolve(s,o);this.unpluggedPaths.has(a)||await T.removePromise(a)}}async locateNodeModules(e){let r=[],i=e?new RegExp(e):null;for(let n of this.opts.project.workspaces){let s=v.join(n.cwd,"node_modules");if(i&&i.test(v.relative(this.opts.project.cwd,n.cwd))||!T.existsSync(s))continue;let o=await T.readdirPromise(s,{withFileTypes:!0}),a=o.filter(l=>!l.isDirectory()||l.name===".bin"||!l.name.startsWith("."));if(a.length===o.length)r.push(s);else for(let l of a)r.push(v.join(s,l.name))}return r}async unplugPackageIfNeeded(e,r,i,n){return this.shouldBeUnplugged(e,r,n)?this.unplugPackage(e,i):i.packageFs}shouldBeUnplugged(e,r,i){return typeof i.unplugged!="undefined"?i.unplugged:f6e.has(e.identHash)||e.conditions!=null?!0:r.manifest.preferUnplugged!==null?r.manifest.preferUnplugged:!!(Z0(e,r,i,{configuration:this.opts.project.configuration}).length>0||r.misc.extractHint)}async unplugPackage(e,r){let i=ZC(e,{configuration:this.opts.project.configuration});if(this.opts.project.disabledLocators.has(e.locatorHash))return new Xo(i,{baseFs:r.packageFs,pathUtils:v});this.unpluggedPaths.add(i);let n=v.join(i,r.prefixPath,".ready");return await T.existsPromise(n)?new Ft(i):(this.opts.project.storedBuildState.delete(e.locatorHash),await T.mkdirPromise(i,{recursive:!0}),await T.copyPromise(i,Se.dot,{baseFs:r.packageFs,overwrite:!1}),await T.writeFilePromise(n,""),new Ft(i))}getPackageInformation(e){let r=S.stringifyIdent(e),i=e.reference,n=this.packageRegistry.get(r);if(!n)throw new Error(`Assertion failed: The package information store should have been available (for ${S.prettyIdent(this.opts.project.configuration,e)})`);let s=n.get(i);if(!s)throw new Error(`Assertion failed: The package information should have been available (for ${S.prettyLocator(this.opts.project.configuration,e)})`);return s}getDiskInformation(e){let r=de.getMapWithDefault(this.packageRegistry,"@@disk"),i=sT(this.opts.project.cwd,e);return de.getFactoryWithDefault(r,i,()=>({packageLocation:i,packageDependencies:new Map,packagePeers:new Set,linkType:gt.SOFT,discardFromLookup:!1}))}};function sT(t,e){let r=v.relative(t,e);return r.match(/^\.{0,2}\//)||(r=`./${r}`),r.replace(/\/?$/,"/")}async function h6e(t){var i;let e=(i=await Ze.tryFind(t.prefixPath,{baseFs:t.packageFs}))!=null?i:new Ze,r=new Set(["preinstall","install","postinstall"]);for(let n of e.scripts.keys())r.has(n)||e.scripts.delete(n);return{manifest:{scripts:e.scripts,preferUnplugged:e.preferUnplugged,type:e.type},misc:{extractHint:rT(t),hasBindingGyp:iT(t)}}}var ace=ie(Nn());var $C=class extends Be{constructor(){super(...arguments);this.all=Y.Boolean("-A,--all",!1,{description:"Unplug direct dependencies from the entire project"});this.recursive=Y.Boolean("-R,--recursive",!1,{description:"Unplug both direct and transitive dependencies"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.patterns=Y.Rest()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);if(e.get("nodeLinker")!=="pnp")throw new me("This command can only be used if the `nodeLinker` option is set to `pnp`");await r.restoreInstallState();let s=new Set(this.patterns),o=this.patterns.map(f=>{let h=S.parseDescriptor(f),p=h.range!=="unknown"?h:S.makeDescriptor(h,"*");if(!qt.validRange(p.range))throw new me(`The range of the descriptor patterns must be a valid semver range (${S.prettyDescriptor(e,p)})`);return d=>{let m=S.stringifyIdent(d);return!ace.default.isMatch(m,S.stringifyIdent(p))||d.version&&!qt.satisfiesWithPrereleases(d.version,p.range)?!1:(s.delete(f),!0)}}),a=()=>{let f=[];for(let h of r.storedPackages.values())!r.tryWorkspaceByLocator(h)&&!S.isVirtualLocator(h)&&o.some(p=>p(h))&&f.push(h);return f},l=f=>{let h=new Set,p=[],d=(m,I)=>{if(!h.has(m.locatorHash)&&(h.add(m.locatorHash),!r.tryWorkspaceByLocator(m)&&o.some(B=>B(m))&&p.push(m),!(I>0&&!this.recursive)))for(let B of m.dependencies.values()){let b=r.storedResolutions.get(B.descriptorHash);if(!b)throw new Error("Assertion failed: The resolution should have been registered");let R=r.storedPackages.get(b);if(!R)throw new Error("Assertion failed: The package should have been registered");d(R,I+1)}};for(let m of f){let I=r.storedPackages.get(m.anchoredLocator.locatorHash);if(!I)throw new Error("Assertion failed: The package should have been registered");d(I,0)}return p},c,u;if(this.all&&this.recursive?(c=a(),u="the project"):this.all?(c=l(r.workspaces),u="any workspace"):(c=l([i]),u="this workspace"),s.size>1)throw new me(`Patterns ${ue.prettyList(e,s,ue.Type.CODE)} don't match any packages referenced by ${u}`);if(s.size>0)throw new me(`Pattern ${ue.prettyList(e,s,ue.Type.CODE)} doesn't match any packages referenced by ${u}`);return c=de.sortMap(c,f=>S.stringifyLocator(f)),(await Fe.start({configuration:e,stdout:this.context.stdout,json:this.json},async f=>{var h;for(let p of c){let d=(h=p.version)!=null?h:"unknown",m=r.topLevelWorkspace.manifest.ensureDependencyMeta(S.makeDescriptor(p,d));m.unplugged=!0,f.reportInfo(z.UNNAMED,`Will unpack ${S.prettyLocator(e,p)} to ${ue.pretty(e,ZC(p,{configuration:e}),ue.Type.PATH)}`),f.reportJson({locator:S.stringifyLocator(p),version:d})}await r.topLevelWorkspace.persistManifest(),f.reportSeparator(),await r.install({cache:n,report:f})})).exitCode()}};$C.paths=[["unplug"]],$C.usage=ye.Usage({description:"force the unpacking of a list of packages",details:"\n This command will add the selectors matching the specified patterns to the list of packages that must be unplugged when installed.\n\n A package being unplugged means that instead of being referenced directly through its archive, it will be unpacked at install time in the directory configured via `pnpUnpluggedFolder`. Note that unpacking packages this way is generally not recommended because it'll make it harder to store your packages within the repository. However, it's a good approach to quickly and safely debug some packages, and can even sometimes be required depending on the context (for example when the package contains shellscripts).\n\n Running the command will set a persistent flag inside your top-level `package.json`, in the `dependenciesMeta` field. As such, to undo its effects, you'll need to revert the changes made to the manifest and run `yarn install` to apply the modification.\n\n By default, only direct dependencies from the current workspace are affected. If `-A,--all` is set, direct dependencies from the entire project are affected. Using the `-R,--recursive` flag will affect transitive dependencies as well as direct ones.\n\n This command accepts glob patterns inside the scope and name components (not the range). Make sure to escape the patterns to prevent your own shell from trying to expand them.\n ",examples:[["Unplug the lodash dependency from the active workspace","yarn unplug lodash"],["Unplug all instances of lodash referenced by any workspace","yarn unplug lodash -A"],["Unplug all instances of lodash referenced by the active workspace and its dependencies","yarn unplug lodash -R"],["Unplug all instances of lodash, anywhere","yarn unplug lodash -AR"],["Unplug one specific version of lodash","yarn unplug lodash@1.2.3"],["Unplug all packages with the `@babel` scope","yarn unplug '@babel/*'"],["Unplug all packages (only for testing, not recommended)","yarn unplug -R '*'"]]});var Ace=$C;var qA=t=>({cjs:v.join(t.cwd,wt.pnpCjs),cjsLegacy:v.join(t.cwd,wt.pnpJs),esmLoader:v.join(t.cwd,".pnp.loader.mjs")}),uce=t=>/\s/.test(t)?JSON.stringify(t):t;async function p6e(t,e,r){let i=qA(t),n=`--require ${uce(M.fromPortablePath(i.cjs))}`;if(T.existsSync(i.esmLoader)&&(n=`${n} --experimental-loader ${(0,cce.pathToFileURL)(M.fromPortablePath(i.esmLoader)).href}`),i.cjs.includes(" ")&&lce.default.lt(process.versions.node,"12.0.0"))throw new Error(`Expected the build location to not include spaces when using Node < 12.0.0 (${process.versions.node})`);if(T.existsSync(i.cjs)){let s=e.NODE_OPTIONS||"",o=/\s*--require\s+\S*\.pnp\.c?js\s*/g,a=/\s*--experimental-loader\s+\S*\.pnp\.loader\.mjs\s*/;s=s.replace(o," ").replace(a," ").trim(),s=s?`${n} ${s}`:n,e.NODE_OPTIONS=s}}async function d6e(t,e){let r=qA(t);e(r.cjs),e(r.esmLoader),e(t.configuration.get("pnpDataPath")),e(t.configuration.get("pnpUnpluggedFolder"))}var C6e={hooks:{populateYarnPaths:d6e,setupScriptEnvironment:p6e},configuration:{nodeLinker:{description:'The linker used for installing Node packages, one of: "pnp", "node-modules"',type:ge.STRING,default:"pnp"},pnpMode:{description:"If 'strict', generates standard PnP maps. If 'loose', merges them with the n_m resolution.",type:ge.STRING,default:"strict"},pnpShebang:{description:"String to prepend to the generated PnP script",type:ge.STRING,default:"#!/usr/bin/env node"},pnpIgnorePatterns:{description:"Array of glob patterns; files matching them will use the classic resolution",type:ge.STRING,default:[],isArray:!0},pnpEnableEsmLoader:{description:"If true, Yarn will generate an ESM loader (`.pnp.loader.mjs`). If this is not explicitly set Yarn tries to automatically detect whether ESM support is required.",type:ge.BOOLEAN,default:!1},pnpEnableInlining:{description:"If true, the PnP data will be inlined along with the generated loader",type:ge.BOOLEAN,default:!0},pnpFallbackMode:{description:"If true, the generated PnP loader will follow the top-level fallback rule",type:ge.STRING,default:"dependencies-only"},pnpUnpluggedFolder:{description:"Folder where the unplugged packages must be stored",type:ge.ABSOLUTE_PATH,default:"./.yarn/unplugged"},pnpDataPath:{description:"Path of the file where the PnP data (used by the loader) must be written",type:ge.ABSOLUTE_PATH,default:"./.pnp.data.json"}},linkers:[jc],commands:[Ace]},m6e=C6e;var Cce=ie(dce());var uT=ie(require("crypto")),mce=ie(require("fs")),Ece=1,gi="node_modules",gT=".bin",Ice=".yarn-state.yml",Bi;(function(i){i.CLASSIC="classic",i.HARDLINKS_LOCAL="hardlinks-local",i.HARDLINKS_GLOBAL="hardlinks-global"})(Bi||(Bi={}));var fT=class{constructor(){this.installStateCache=new Map}supportsPackage(e,r){return r.project.configuration.get("nodeLinker")==="node-modules"}async findPackageLocation(e,r){let i=r.project.tryWorkspaceByLocator(e);if(i)return i.cwd;let n=await de.getFactoryWithDefault(this.installStateCache,r.project.cwd,async()=>await hT(r.project,{unrollAliases:!0}));if(n===null)throw new me("Couldn't find the node_modules state file - running an install might help (findPackageLocation)");let s=n.locatorMap.get(S.stringifyLocator(e));if(!s){let a=new me(`Couldn't find ${S.prettyLocator(r.project.configuration,e)} in the currently installed node_modules map - running an install might help`);throw a.code="LOCATOR_NOT_INSTALLED",a}let o=r.project.configuration.startingCwd;return s.locations.find(a=>v.contains(o,a))||s.locations[0]}async findPackageLocator(e,r){let i=await de.getFactoryWithDefault(this.installStateCache,r.project.cwd,async()=>await hT(r.project,{unrollAliases:!0}));if(i===null)return null;let{locationRoot:n,segments:s}=$0(v.resolve(e),{skipPrefix:r.project.cwd}),o=i.locationTree.get(n);if(!o)return null;let a=o.locator;for(let l of s){if(o=o.children.get(l),!o)break;a=o.locator||a}return S.parseLocator(a)}makeInstaller(e){return new yce(e)}},yce=class{constructor(e){this.opts=e;this.localStore=new Map;this.realLocatorChecksums=new Map;this.customData={store:new Map}}getCustomDataKey(){return JSON.stringify({name:"NodeModulesInstaller",version:1})}attachCustomData(e){this.customData=e}async installPackage(e,r){var u;let i=v.resolve(r.packageFs.getRealPath(),r.prefixPath),n=this.customData.store.get(e.locatorHash);if(typeof n=="undefined"&&(n=await L6e(e,r),e.linkType===gt.HARD&&this.customData.store.set(e.locatorHash,n)),!Ws.checkAndReportManifestCompatibility(e,"link",{configuration:this.opts.project.configuration,report:this.opts.report}))return{packageLocation:null,buildDirective:null};let s=new Map,o=new Set;s.has(S.stringifyIdent(e))||s.set(S.stringifyIdent(e),e.reference);let a=e;if(S.isVirtualLocator(e)){a=S.devirtualizeLocator(e);for(let g of e.peerDependencies.values())s.set(S.stringifyIdent(g),null),o.add(S.stringifyIdent(g))}let l={packageLocation:`${M.fromPortablePath(i)}/`,packageDependencies:s,packagePeers:o,linkType:e.linkType,discardFromLookup:(u=r.discardFromLookup)!=null?u:!1};this.localStore.set(e.locatorHash,{pkg:e,customPackageData:n,dependencyMeta:this.opts.project.getDependencyMeta(e,e.version),pnpNode:l});let c=r.checksum?r.checksum.substring(r.checksum.indexOf("/")+1):null;return this.realLocatorChecksums.set(a.locatorHash,c),{packageLocation:i,buildDirective:null}}async attachInternalDependencies(e,r){let i=this.localStore.get(e.locatorHash);if(typeof i=="undefined")throw new Error("Assertion failed: Expected information object to have been registered");for(let[n,s]of r){let o=S.areIdentsEqual(n,s)?s.reference:[S.stringifyIdent(s),s.reference];i.pnpNode.packageDependencies.set(S.stringifyIdent(n),o)}}async attachExternalDependents(e,r){throw new Error("External dependencies haven't been implemented for the node-modules linker")}async finalizeInstall(){if(this.opts.project.configuration.get("nodeLinker")!=="node-modules")return;let e=new Pr({baseFs:new Jn({libzip:await $i(),maxOpenFiles:80,readOnlyArchives:!0})}),r=await hT(this.opts.project),i=this.opts.project.configuration.get("nmMode");(r===null||i!==r.nmMode)&&(this.opts.project.storedBuildState.clear(),r={locatorMap:new Map,binSymlinks:new Map,locationTree:new Map,nmMode:i});let n=new Map(this.opts.project.workspaces.map(f=>{var p,d;let h=this.opts.project.configuration.get("nmHoistingLimits");try{h=de.validateEnum(Sn,(d=(p=f.manifest.installConfig)==null?void 0:p.hoistingLimits)!=null?d:h)}catch(m){let I=S.prettyWorkspace(this.opts.project.configuration,f);this.opts.report.reportWarning(z.INVALID_MANIFEST,`${I}: Invalid 'installConfig.hoistingLimits' value. Expected one of ${Object.values(Sn).join(", ")}, using default: "${h}"`)}return[f.relativeCwd,h]})),s=new Map(this.opts.project.workspaces.map(f=>{var p,d;let h=this.opts.project.configuration.get("nmSelfReferences");return h=(d=(p=f.manifest.installConfig)==null?void 0:p.selfReferences)!=null?d:h,[f.relativeCwd,h]})),o={VERSIONS:{std:1},topLevel:{name:null,reference:null},getLocator:(f,h)=>Array.isArray(h)?{name:h[0],reference:h[1]}:{name:f,reference:h},getDependencyTreeRoots:()=>this.opts.project.workspaces.map(f=>{let h=f.anchoredLocator;return{name:S.stringifyIdent(f.locator),reference:h.reference}}),getPackageInformation:f=>{let h=f.reference===null?this.opts.project.topLevelWorkspace.anchoredLocator:S.makeLocator(S.parseIdent(f.name),f.reference),p=this.localStore.get(h.locatorHash);if(typeof p=="undefined")throw new Error("Assertion failed: Expected the package reference to have been registered");return p.pnpNode},findPackageLocator:f=>{let h=this.opts.project.tryWorkspaceByCwd(M.toPortablePath(f));if(h!==null){let p=h.anchoredLocator;return{name:S.stringifyIdent(p),reference:p.reference}}throw new Error("Assertion failed: Unimplemented")},resolveToUnqualified:()=>{throw new Error("Assertion failed: Unimplemented")},resolveUnqualified:()=>{throw new Error("Assertion failed: Unimplemented")},resolveRequest:()=>{throw new Error("Assertion failed: Unimplemented")},resolveVirtual:f=>M.fromPortablePath(Pr.resolveVirtual(M.toPortablePath(f)))},{tree:a,errors:l,preserveSymlinksRequired:c}=VC(o,{pnpifyFs:!1,validateExternalSoftLinks:!0,hoistingLimitsByCwd:n,project:this.opts.project,selfReferencesByCwd:s});if(!a){for(let{messageName:f,text:h}of l)this.opts.report.reportError(f,h);return}let u=WL(a);await T6e(r,u,{baseFs:e,project:this.opts.project,report:this.opts.report,realLocatorChecksums:this.realLocatorChecksums,loadManifest:async f=>{let h=S.parseLocator(f),p=this.localStore.get(h.locatorHash);if(typeof p=="undefined")throw new Error("Assertion failed: Expected the slot to exist");return p.customPackageData.manifest}});let g=[];for(let[f,h]of u.entries()){if(wce(f))continue;let p=S.parseLocator(f),d=this.localStore.get(p.locatorHash);if(typeof d=="undefined")throw new Error("Assertion failed: Expected the slot to exist");if(this.opts.project.tryWorkspaceByLocator(d.pkg))continue;let m=Ws.extractBuildScripts(d.pkg,d.customPackageData,d.dependencyMeta,{configuration:this.opts.project.configuration,report:this.opts.report});m.length!==0&&g.push({buildLocations:h.locations,locatorHash:p.locatorHash,buildDirective:m})}return c&&this.opts.report.reportWarning(z.NM_PRESERVE_SYMLINKS_REQUIRED,`The application uses portals and that's why ${ue.pretty(this.opts.project.configuration,"--preserve-symlinks",ue.Type.CODE)} Node option is required for launching it`),{customData:this.customData,records:g}}};async function L6e(t,e){var n;let r=(n=await Ze.tryFind(e.prefixPath,{baseFs:e.packageFs}))!=null?n:new Ze,i=new Set(["preinstall","install","postinstall"]);for(let s of r.scripts.keys())i.has(s)||r.scripts.delete(s);return{manifest:{bin:r.bin,scripts:r.scripts},misc:{extractHint:Ws.getExtractHint(e),hasBindingGyp:Ws.hasBindingGyp(e)}}}async function M6e(t,e,r,i){let n="";n+=`# Warning: This file is automatically generated. Removing it is fine, but will -`,n+=`# cause your node_modules installation to become invalidated. -`,n+=` -`,n+=`__metadata: -`,n+=` version: ${Ece} -`,n+=` nmMode: ${i.value} -`;let s=Array.from(e.keys()).sort(),o=S.stringifyLocator(t.topLevelWorkspace.anchoredLocator);for(let c of s){let u=e.get(c);n+=` -`,n+=`${JSON.stringify(c)}: -`,n+=` locations: -`;for(let g of u.locations){let f=v.contains(t.cwd,g);if(f===null)throw new Error(`Assertion failed: Expected the path to be within the project (${g})`);n+=` - ${JSON.stringify(f)} -`}if(u.aliases.length>0){n+=` aliases: -`;for(let g of u.aliases)n+=` - ${JSON.stringify(g)} -`}if(c===o&&r.size>0){n+=` bin: -`;for(let[g,f]of r){let h=v.contains(t.cwd,g);if(h===null)throw new Error(`Assertion failed: Expected the path to be within the project (${g})`);n+=` ${JSON.stringify(h)}: -`;for(let[p,d]of f){let m=v.relative(v.join(g,gi),d);n+=` ${JSON.stringify(p)}: ${JSON.stringify(m)} -`}}}}let a=t.cwd,l=v.join(a,gi,Ice);await T.changeFilePromise(l,n,{automaticNewlines:!0})}async function hT(t,{unrollAliases:e=!1}={}){let r=t.cwd,i=v.join(r,gi,Ice);if(!T.existsSync(i))return null;let n=Ii(await T.readFilePromise(i,"utf8"));if(n.__metadata.version>Ece)return null;let s=n.__metadata.nmMode||Bi.CLASSIC,o=new Map,a=new Map;delete n.__metadata;for(let[l,c]of Object.entries(n)){let u=c.locations.map(f=>v.join(r,f)),g=c.bin;if(g)for(let[f,h]of Object.entries(g)){let p=v.join(r,M.toPortablePath(f)),d=de.getMapWithDefault(a,p);for(let[m,I]of Object.entries(h))d.set(kr(m),M.toPortablePath([p,gi,I].join(v.delimiter)))}if(o.set(l,{target:Se.dot,linkType:gt.HARD,locations:u,aliases:c.aliases||[]}),e&&c.aliases)for(let f of c.aliases){let{scope:h,name:p}=S.parseLocator(l),d=S.makeLocator(S.makeIdent(h,p),f),m=S.stringifyLocator(d);o.set(m,{target:Se.dot,linkType:gt.HARD,locations:u,aliases:[]})}}return{locatorMap:o,binSymlinks:a,locationTree:Bce(o,{skipPrefix:t.cwd}),nmMode:s}}var Ef=async(t,e)=>{if(t.split(v.sep).indexOf(gi)<0)throw new Error(`Assertion failed: trying to remove dir that doesn't contain node_modules: ${t}`);try{if(!e.innerLoop&&(await T.lstatPromise(t)).isSymbolicLink()){await T.unlinkPromise(t);return}let r=await T.readdirPromise(t,{withFileTypes:!0});for(let i of r){let n=v.join(t,kr(i.name));i.isDirectory()?(i.name!==gi||e&&e.innerLoop)&&await Ef(n,{innerLoop:!0,contentsOnly:!1}):await T.unlinkPromise(n)}e.contentsOnly||await T.rmdirPromise(t)}catch(r){if(r.code!=="ENOENT"&&r.code!=="ENOTEMPTY")throw r}},Qce=4,$0=(t,{skipPrefix:e})=>{let r=v.contains(e,t);if(r===null)throw new Error(`Assertion failed: Writing attempt prevented to ${t} which is outside project root: ${e}`);let i=r.split(v.sep).filter(l=>l!==""),n=i.indexOf(gi),s=i.slice(0,n).join(v.sep),o=v.join(e,s),a=i.slice(n);return{locationRoot:o,segments:a}},Bce=(t,{skipPrefix:e})=>{let r=new Map;if(t===null)return r;let i=()=>({children:new Map,linkType:gt.HARD});for(let[n,s]of t.entries()){if(s.linkType===gt.SOFT&&v.contains(e,s.target)!==null){let a=de.getFactoryWithDefault(r,s.target,i);a.locator=n,a.linkType=s.linkType}for(let o of s.locations){let{locationRoot:a,segments:l}=$0(o,{skipPrefix:e}),c=de.getFactoryWithDefault(r,a,i);for(let u=0;u{let r;try{process.platform==="win32"&&(r=await T.lstatPromise(t))}catch(i){}process.platform=="win32"&&(!r||r.isDirectory())?await T.symlinkPromise(t,e,"junction"):await T.symlinkPromise(v.relative(v.dirname(e),t),e)};async function bce(t,e,r){let i=v.join(t,kr(`${uT.default.randomBytes(16).toString("hex")}.tmp`));try{await T.writeFilePromise(i,r);try{await T.linkPromise(i,e)}catch(n){}}finally{await T.unlinkPromise(i)}}async function O6e({srcPath:t,dstPath:e,srcMode:r,globalHardlinksStore:i,baseFs:n,nmMode:s,digest:o}){if(s.value===Bi.HARDLINKS_GLOBAL&&i&&o){let l=v.join(i,o.substring(0,2),`${o.substring(2)}.dat`),c;try{if(await mn.checksumFile(l,{baseFs:T,algorithm:"sha1"})!==o){let g=v.join(i,kr(`${uT.default.randomBytes(16).toString("hex")}.tmp`));await T.renamePromise(l,g);let f=await n.readFilePromise(t);await T.writeFilePromise(g,f);try{await T.linkPromise(g,l),await T.unlinkPromise(g)}catch(h){}}await T.linkPromise(l,e),c=!0}catch(u){c=!1}if(!c){let u=await n.readFilePromise(t);await bce(i,l,u);try{await T.linkPromise(l,e)}catch(g){g&&g.code&&g.code=="EXDEV"&&(s.value=Bi.HARDLINKS_LOCAL,await n.copyFilePromise(t,e))}}}else await n.copyFilePromise(t,e);let a=r&511;a!==420&&await T.chmodPromise(e,a)}var JA;(function(i){i.FILE="file",i.DIRECTORY="directory",i.SYMLINK="symlink"})(JA||(JA={}));var K6e=async(t,e,{baseFs:r,globalHardlinksStore:i,nmMode:n,packageChecksum:s})=>{await T.mkdirPromise(t,{recursive:!0});let o=async(l=Se.dot)=>{let c=v.join(e,l),u=await r.readdirPromise(c,{withFileTypes:!0}),g=new Map;for(let f of u){let h=v.join(l,f.name),p,d=v.join(c,f.name);if(f.isFile()){if(p={kind:JA.FILE,mode:(await r.lstatPromise(d)).mode},n.value===Bi.HARDLINKS_GLOBAL){let m=await mn.checksumFile(d,{baseFs:r,algorithm:"sha1"});p.digest=m}}else if(f.isDirectory())p={kind:JA.DIRECTORY};else if(f.isSymbolicLink())p={kind:JA.SYMLINK,symlinkTo:await r.readlinkPromise(d)};else throw new Error(`Unsupported file type (file: ${d}, mode: 0o${await r.statSync(d).mode.toString(8).padStart(6,"0")})`);if(g.set(h,p),f.isDirectory()&&h!==gi){let m=await o(h);for(let[I,B]of m)g.set(I,B)}}return g},a;if(n.value===Bi.HARDLINKS_GLOBAL&&i&&s){let l=v.join(i,s.substring(0,2),`${s.substring(2)}.json`);try{a=new Map(Object.entries(JSON.parse(await T.readFilePromise(l,"utf8"))))}catch(c){a=await o(),await bce(i,l,Buffer.from(JSON.stringify(Object.fromEntries(a))))}}else a=await o();for(let[l,c]of a){let u=v.join(e,l),g=v.join(t,l);c.kind===JA.DIRECTORY?await T.mkdirPromise(g,{recursive:!0}):c.kind===JA.FILE?await O6e({srcPath:u,dstPath:g,srcMode:c.mode,digest:c.digest,nmMode:n,baseFs:r,globalHardlinksStore:i}):c.kind===JA.SYMLINK&&await pT(v.resolve(v.dirname(g),c.symlinkTo),g)}};function U6e(t,e){let r=new Map([...t]),i=new Map([...e]);for(let[n,s]of t){let o=v.join(n,gi);if(!T.existsSync(o)){s.children.delete(gi);for(let a of i.keys())v.contains(o,a)!==null&&i.delete(a)}}return{locationTree:r,binSymlinks:i}}function wce(t){let e=S.parseDescriptor(t);return S.isVirtualDescriptor(e)&&(e=S.devirtualizeDescriptor(e)),e.range.startsWith("link:")}async function H6e(t,e,r,{loadManifest:i}){let n=new Map;for(let[a,{locations:l}]of t){let c=wce(a)?null:await i(a,l[0]),u=new Map;if(c)for(let[g,f]of c.bin){let h=v.join(l[0],f);f!==""&&T.existsSync(h)&&u.set(g,f)}n.set(a,u)}let s=new Map,o=(a,l,c)=>{let u=new Map,g=v.contains(r,a);if(c.locator&&g!==null){let f=n.get(c.locator);for(let[h,p]of f){let d=v.join(a,M.toPortablePath(p));u.set(kr(h),d)}for(let[h,p]of c.children){let d=v.join(a,h),m=o(d,d,p);m.size>0&&s.set(a,new Map([...s.get(a)||new Map,...m]))}}else for(let[f,h]of c.children){let p=o(v.join(a,f),l,h);for(let[d,m]of p)u.set(d,m)}return u};for(let[a,l]of e){let c=o(a,a,l);c.size>0&&s.set(a,new Map([...s.get(a)||new Map,...c]))}return s}var vce=(t,e)=>{if(!t||!e)return t===e;let r=S.parseLocator(t);S.isVirtualLocator(r)&&(r=S.devirtualizeLocator(r));let i=S.parseLocator(e);return S.isVirtualLocator(i)&&(i=S.devirtualizeLocator(i)),S.areLocatorsEqual(r,i)};function dT(t){return v.join(t.get("globalFolder"),"store")}async function T6e(t,e,{baseFs:r,project:i,report:n,loadManifest:s,realLocatorChecksums:o}){let a=v.join(i.cwd,gi),{locationTree:l,binSymlinks:c}=U6e(t.locationTree,t.binSymlinks),u=Bce(e,{skipPrefix:i.cwd}),g=[],f=async({srcDir:L,dstDir:K,linkType:J,globalHardlinksStore:ne,nmMode:q,packageChecksum:A})=>{let V=(async()=>{try{J===gt.SOFT?(await T.mkdirPromise(v.dirname(K),{recursive:!0}),await pT(v.resolve(L),K)):await K6e(K,L,{baseFs:r,globalHardlinksStore:ne,nmMode:q,packageChecksum:A})}catch(W){throw W.message=`While persisting ${L} -> ${K} ${W.message}`,W}finally{B.tick()}})().then(()=>g.splice(g.indexOf(V),1));g.push(V),g.length>Qce&&await Promise.race(g)},h=async(L,K,J)=>{let ne=(async()=>{let q=async(A,V,W)=>{try{W.innerLoop||await T.mkdirPromise(V,{recursive:!0});let X=await T.readdirPromise(A,{withFileTypes:!0});for(let F of X){if(!W.innerLoop&&F.name===gT)continue;let D=v.join(A,F.name),he=v.join(V,F.name);F.isDirectory()?(F.name!==gi||W&&W.innerLoop)&&(await T.mkdirPromise(he,{recursive:!0}),await q(D,he,_(P({},W),{innerLoop:!0}))):H.value===Bi.HARDLINKS_LOCAL||H.value===Bi.HARDLINKS_GLOBAL?await T.linkPromise(D,he):await T.copyFilePromise(D,he,mce.default.constants.COPYFILE_FICLONE)}}catch(X){throw W.innerLoop||(X.message=`While cloning ${A} -> ${V} ${X.message}`),X}finally{W.innerLoop||B.tick()}};await q(L,K,J)})().then(()=>g.splice(g.indexOf(ne),1));g.push(ne),g.length>Qce&&await Promise.race(g)},p=async(L,K,J)=>{if(!J)K.children.has(gi)&&await Ef(v.join(L,gi),{contentsOnly:!1}),await Ef(L,{contentsOnly:L===a});else for(let[ne,q]of K.children){let A=J.children.get(ne);await p(v.join(L,ne),q,A)}};for(let[L,K]of l){let J=u.get(L);for(let[ne,q]of K.children){if(ne===".")continue;let A=J&&J.children.get(ne);await p(v.join(L,ne),q,A)}}let d=async(L,K,J)=>{if(!J)K.children.has(gi)&&await Ef(v.join(L,gi),{contentsOnly:!0}),await Ef(L,{contentsOnly:K.linkType===gt.HARD});else{vce(K.locator,J.locator)||await Ef(L,{contentsOnly:K.linkType===gt.HARD});for(let[ne,q]of K.children){let A=J.children.get(ne);await d(v.join(L,ne),q,A)}}};for(let[L,K]of u){let J=l.get(L);for(let[ne,q]of K.children){if(ne===".")continue;let A=J&&J.children.get(ne);await d(v.join(L,ne),q,A)}}let m=new Map,I=[];for(let[L,{locations:K}]of t.locatorMap.entries())for(let J of K){let{locationRoot:ne,segments:q}=$0(J,{skipPrefix:i.cwd}),A=u.get(ne),V=ne;if(A){for(let W of q)if(V=v.join(V,W),A=A.children.get(W),!A)break;if(A){let W=vce(A.locator,L),X=e.get(A.locator),F=X.target,D=V,he=X.linkType;if(W)m.has(F)||m.set(F,D);else if(F!==D){let pe=S.parseLocator(A.locator);S.isVirtualLocator(pe)&&(pe=S.devirtualizeLocator(pe)),I.push({srcDir:F,dstDir:D,linkType:he,realLocatorHash:pe.locatorHash})}}}}for(let[L,{locations:K}]of e.entries())for(let J of K){let{locationRoot:ne,segments:q}=$0(J,{skipPrefix:i.cwd}),A=l.get(ne),V=u.get(ne),W=ne,X=e.get(L),F=S.parseLocator(L);S.isVirtualLocator(F)&&(F=S.devirtualizeLocator(F));let D=F.locatorHash,he=X.target,pe=J;if(he===pe)continue;let Ne=X.linkType;for(let Pe of q)V=V.children.get(Pe);if(!A)I.push({srcDir:he,dstDir:pe,linkType:Ne,realLocatorHash:D});else for(let Pe of q)if(W=v.join(W,Pe),A=A.children.get(Pe),!A){I.push({srcDir:he,dstDir:pe,linkType:Ne,realLocatorHash:D});break}}let B=Xi.progressViaCounter(I.length),b=n.reportProgress(B),R=i.configuration.get("nmMode"),H={value:R};try{let L=H.value===Bi.HARDLINKS_GLOBAL?`${dT(i.configuration)}/v1`:null;if(L&&!await T.existsPromise(L)){await T.mkdirpPromise(L);for(let J=0;J<256;J++)await T.mkdirPromise(v.join(L,J.toString(16).padStart(2,"0")))}for(let J of I)(J.linkType===gt.SOFT||!m.has(J.srcDir))&&(m.set(J.srcDir,J.dstDir),await f(_(P({},J),{globalHardlinksStore:L,nmMode:H,packageChecksum:o.get(J.realLocatorHash)||null})));await Promise.all(g),g.length=0;for(let J of I){let ne=m.get(J.srcDir);J.linkType!==gt.SOFT&&J.dstDir!==ne&&await h(ne,J.dstDir,{nmMode:H})}await Promise.all(g),await T.mkdirPromise(a,{recursive:!0});let K=await H6e(e,u,i.cwd,{loadManifest:s});await G6e(c,K,i.cwd),await M6e(i,e,K,H),R==Bi.HARDLINKS_GLOBAL&&H.value==Bi.HARDLINKS_LOCAL&&n.reportWarningOnce(z.NM_HARDLINKS_MODE_DOWNGRADED,"'nmMode' has been downgraded to 'hardlinks-local' due to global cache and install folder being on different devices")}finally{b.stop()}}async function G6e(t,e,r){for(let i of t.keys()){if(v.contains(r,i)===null)throw new Error(`Assertion failed. Excepted bin symlink location to be inside project dir, instead it was at ${i}`);if(!e.has(i)){let n=v.join(i,gi,gT);await T.removePromise(n)}}for(let[i,n]of e){if(v.contains(r,i)===null)throw new Error(`Assertion failed. Excepted bin symlink location to be inside project dir, instead it was at ${i}`);let s=v.join(i,gi,gT),o=t.get(i)||new Map;await T.mkdirPromise(s,{recursive:!0});for(let a of o.keys())n.has(a)||(await T.removePromise(v.join(s,a)),process.platform==="win32"&&await T.removePromise(v.join(s,kr(`${a}.cmd`))));for(let[a,l]of n){let c=o.get(a),u=v.join(s,a);c!==l&&(process.platform==="win32"?await(0,Cce.default)(M.fromPortablePath(l),M.fromPortablePath(u),{createPwshFile:!1}):(await T.removePromise(u),await pT(l,u),v.contains(r,await T.realpathPromise(l))!==null&&await T.chmodPromise(l,493)))}}}var CT=class extends jc{constructor(){super(...arguments);this.mode="loose"}makeInstaller(e){return new Sce(e)}},Sce=class extends Cf{constructor(){super(...arguments);this.mode="loose"}async transformPnpSettings(e){let r=new Pr({baseFs:new Jn({libzip:await $i(),maxOpenFiles:80,readOnlyArchives:!0})}),i=ice(e,this.opts.project.cwd,r),{tree:n,errors:s}=VC(i,{pnpifyFs:!1,project:this.opts.project});if(!n){for(let{messageName:u,text:g}of s)this.opts.report.reportError(u,g);return}let o=new Map;e.fallbackPool=o;let a=(u,g)=>{let f=S.parseLocator(g.locator),h=S.stringifyIdent(f);h===u?o.set(u,f.reference):o.set(u,[h,f.reference])},l=v.join(this.opts.project.cwd,wt.nodeModules),c=n.get(l);if(typeof c!="undefined"){if("target"in c)throw new Error("Assertion failed: Expected the root junction point to be a directory");for(let u of c.dirList){let g=v.join(l,u),f=n.get(g);if(typeof f=="undefined")throw new Error("Assertion failed: Expected the child to have been registered");if("target"in f)a(u,f);else for(let h of f.dirList){let p=v.join(g,h),d=n.get(p);if(typeof d=="undefined")throw new Error("Assertion failed: Expected the subchild to have been registered");if("target"in d)a(`${u}/${h}`,d);else throw new Error("Assertion failed: Expected the leaf junction to be a package")}}}}};var j6e={hooks:{cleanGlobalArtifacts:async t=>{let e=dT(t);await T.removePromise(e)}},configuration:{nmHoistingLimits:{description:"Prevent packages to be hoisted past specific levels",type:ge.STRING,values:[Sn.WORKSPACES,Sn.DEPENDENCIES,Sn.NONE],default:Sn.NONE},nmMode:{description:'If set to "hardlinks-local" Yarn will utilize hardlinks to reduce disk space consumption inside "node_modules" directories. With "hardlinks-global" Yarn will use global content addressable storage to reduce "node_modules" size across all the projects using this option.',type:ge.STRING,values:[Bi.CLASSIC,Bi.HARDLINKS_LOCAL,Bi.HARDLINKS_GLOBAL],default:Bi.CLASSIC},nmSelfReferences:{description:"If set to 'false' the workspace will not be allowed to require itself and corresponding self-referencing symlink will not be created",type:ge.BOOLEAN,default:!0}},linkers:[fT,CT]},Y6e=j6e;var yM={};it(yM,{default:()=>Z7e,npmConfigUtils:()=>gr,npmHttpUtils:()=>Lt,npmPublishUtils:()=>Rf});var Rce=ie(Or());var ir="npm:";var Lt={};it(Lt,{AuthType:()=>jn,customPackageError:()=>W6e,del:()=>_6e,get:()=>zs,getIdentUrl:()=>zA,handleInvalidAuthenticationError:()=>WA,post:()=>z6e,put:()=>V6e});var Pce=ie(aC()),Dce=ie(require("url"));var gr={};it(gr,{RegistryType:()=>ja,getAuditRegistry:()=>q6e,getAuthConfiguration:()=>IT,getDefaultRegistry:()=>eQ,getPublishRegistry:()=>xce,getRegistryConfiguration:()=>kce,getScopeConfiguration:()=>ET,getScopeRegistry:()=>Ya,normalizeRegistry:()=>To});var ja;(function(i){i.AUDIT_REGISTRY="npmAuditRegistry",i.FETCH_REGISTRY="npmRegistryServer",i.PUBLISH_REGISTRY="npmPublishRegistry"})(ja||(ja={}));function To(t){return t.replace(/\/$/,"")}function q6e(t,{configuration:e}){let r=e.get(ja.AUDIT_REGISTRY);return r!==null?To(r):xce(t,{configuration:e})}function xce(t,{configuration:e}){var r;return((r=t.publishConfig)==null?void 0:r.registry)?To(t.publishConfig.registry):t.name?Ya(t.name.scope,{configuration:e,type:ja.PUBLISH_REGISTRY}):eQ({configuration:e,type:ja.PUBLISH_REGISTRY})}function Ya(t,{configuration:e,type:r=ja.FETCH_REGISTRY}){let i=ET(t,{configuration:e});if(i===null)return eQ({configuration:e,type:r});let n=i.get(r);return n===null?eQ({configuration:e,type:r}):To(n)}function eQ({configuration:t,type:e=ja.FETCH_REGISTRY}){let r=t.get(e);return To(r!==null?r:t.get(ja.FETCH_REGISTRY))}function kce(t,{configuration:e}){let r=e.get("npmRegistries"),i=To(t),n=r.get(i);if(typeof n!="undefined")return n;let s=r.get(i.replace(/^[a-z]+:/,""));return typeof s!="undefined"?s:null}function ET(t,{configuration:e}){if(t===null)return null;let i=e.get("npmScopes").get(t);return i||null}function IT(t,{configuration:e,ident:r}){let i=r&&ET(r.scope,{configuration:e});return(i==null?void 0:i.get("npmAuthIdent"))||(i==null?void 0:i.get("npmAuthToken"))?i:kce(t,{configuration:e})||e}var jn;(function(n){n[n.NO_AUTH=0]="NO_AUTH",n[n.BEST_EFFORT=1]="BEST_EFFORT",n[n.CONFIGURATION=2]="CONFIGURATION",n[n.ALWAYS_AUTH=3]="ALWAYS_AUTH"})(jn||(jn={}));async function WA(t,{attemptedAs:e,registry:r,headers:i,configuration:n}){var s,o;if(((s=t.originalError)==null?void 0:s.name)==="HTTPError"&&((o=t.originalError)==null?void 0:o.response.statusCode)===401)throw new nt(z.AUTHENTICATION_INVALID,`Invalid authentication (${typeof e!="string"?`as ${await J6e(r,i,{configuration:n})}`:`attempted as ${e}`})`)}function W6e(t){var e;return((e=t.response)==null?void 0:e.statusCode)===404?"Package not found":null}function zA(t){return t.scope?`/@${t.scope}%2f${t.name}`:`/${t.name}`}async function zs(t,a){var l=a,{configuration:e,headers:r,ident:i,authType:n,registry:s}=l,o=qr(l,["configuration","headers","ident","authType","registry"]);if(i&&typeof s=="undefined"&&(s=Ya(i.scope,{configuration:e})),i&&i.scope&&typeof n=="undefined"&&(n=1),typeof s!="string")throw new Error("Assertion failed: The registry should be a string");let c=await tQ(s,{authType:n,configuration:e,ident:i});c&&(r=_(P({},r),{authorization:c}));try{return await Zt.get(t.charAt(0)==="/"?`${s}${t}`:t,P({configuration:e,headers:r},o))}catch(u){throw await WA(u,{registry:s,configuration:e,headers:r}),u}}async function z6e(t,e,c){var u=c,{attemptedAs:r,configuration:i,headers:n,ident:s,authType:o=3,registry:a}=u,l=qr(u,["attemptedAs","configuration","headers","ident","authType","registry"]);if(s&&typeof a=="undefined"&&(a=Ya(s.scope,{configuration:i})),typeof a!="string")throw new Error("Assertion failed: The registry should be a string");let g=await tQ(a,{authType:o,configuration:i,ident:s});g&&(n=_(P({},n),{authorization:g}));try{return await Zt.post(a+t,e,P({configuration:i,headers:n},l))}catch(f){if(!wT(f))throw await WA(f,{attemptedAs:r,registry:a,configuration:i,headers:n}),f;let h=await yT(),p=P(P({},n),BT(h));try{return await Zt.post(`${a}${t}`,e,P({configuration:i,headers:p},l))}catch(d){throw await WA(d,{attemptedAs:r,registry:a,configuration:i,headers:n}),d}}}async function V6e(t,e,c){var u=c,{attemptedAs:r,configuration:i,headers:n,ident:s,authType:o=3,registry:a}=u,l=qr(u,["attemptedAs","configuration","headers","ident","authType","registry"]);if(s&&typeof a=="undefined"&&(a=Ya(s.scope,{configuration:i})),typeof a!="string")throw new Error("Assertion failed: The registry should be a string");let g=await tQ(a,{authType:o,configuration:i,ident:s});g&&(n=_(P({},n),{authorization:g}));try{return await Zt.put(a+t,e,P({configuration:i,headers:n},l))}catch(f){if(!wT(f))throw await WA(f,{attemptedAs:r,registry:a,configuration:i,headers:n}),f;let h=await yT(),p=P(P({},n),BT(h));try{return await Zt.put(`${a}${t}`,e,P({configuration:i,headers:p},l))}catch(d){throw await WA(d,{attemptedAs:r,registry:a,configuration:i,headers:n}),d}}}async function _6e(t,l){var c=l,{attemptedAs:e,configuration:r,headers:i,ident:n,authType:s=3,registry:o}=c,a=qr(c,["attemptedAs","configuration","headers","ident","authType","registry"]);if(n&&typeof o=="undefined"&&(o=Ya(n.scope,{configuration:r})),typeof o!="string")throw new Error("Assertion failed: The registry should be a string");let u=await tQ(o,{authType:s,configuration:r,ident:n});u&&(i=_(P({},i),{authorization:u}));try{return await Zt.del(o+t,P({configuration:r,headers:i},a))}catch(g){if(!wT(g))throw await WA(g,{attemptedAs:e,registry:o,configuration:r,headers:i}),g;let f=await yT(),h=P(P({},i),BT(f));try{return await Zt.del(`${o}${t}`,P({configuration:r,headers:h},a))}catch(p){throw await WA(p,{attemptedAs:e,registry:o,configuration:r,headers:i}),p}}}async function tQ(t,{authType:e=2,configuration:r,ident:i}){let n=IT(t,{configuration:r,ident:i}),s=X6e(n,e);if(!s)return null;let o=await r.reduceHook(a=>a.getNpmAuthenticationHeader,void 0,t,{configuration:r,ident:i});if(o)return o;if(n.get("npmAuthToken"))return`Bearer ${n.get("npmAuthToken")}`;if(n.get("npmAuthIdent")){let a=n.get("npmAuthIdent");return a.includes(":")?`Basic ${Buffer.from(a).toString("base64")}`:`Basic ${a}`}if(s&&e!==1)throw new nt(z.AUTHENTICATION_NOT_FOUND,"No authentication configured for request");return null}function X6e(t,e){switch(e){case 2:return t.get("npmAlwaysAuth");case 1:case 3:return!0;case 0:return!1;default:throw new Error("Unreachable")}}async function J6e(t,e,{configuration:r}){var i;if(typeof e=="undefined"||typeof e.authorization=="undefined")return"an anonymous user";try{return(i=(await Zt.get(new Dce.URL(`${t}/-/whoami`).href,{configuration:r,headers:e,jsonResponse:!0})).username)!=null?i:"an unknown user"}catch{return"an unknown user"}}async function yT(){if(process.env.TEST_ENV)return process.env.TEST_NPM_2FA_TOKEN||"";let{otp:t}=await(0,Pce.prompt)({type:"password",name:"otp",message:"One-time password:",required:!0,onCancel:()=>process.exit(130)});return t}function wT(t){var e,r;if(((e=t.originalError)==null?void 0:e.name)!=="HTTPError")return!1;try{return((r=t.originalError)==null?void 0:r.response.headers["www-authenticate"].split(/,\s*/).map(n=>n.toLowerCase())).includes("otp")}catch(i){return!1}}function BT(t){return{["npm-otp"]:t}}var QT=class{supports(e,r){if(!e.reference.startsWith(ir))return!1;let{selector:i,params:n}=S.parseRange(e.reference);return!(!Rce.default.valid(i)||n===null||typeof n.__archiveUrl!="string")}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the remote server`),loader:()=>this.fetchFromNetwork(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:S.getIdentVendorPath(e),checksum:o}}async fetchFromNetwork(e,r){let{params:i}=S.parseRange(e.reference);if(i===null||typeof i.__archiveUrl!="string")throw new Error("Assertion failed: The archiveUrl querystring parameter should have been available");let n=await zs(i.__archiveUrl,{configuration:r.project.configuration,ident:e});return await Ai.convertToZip(n,{compressionLevel:r.project.configuration.get("compressionLevel"),prefixPath:S.getIdentVendorPath(e),stripComponents:1})}};var bT=class{supportsDescriptor(e,r){return!(!e.range.startsWith(ir)||!S.tryParseDescriptor(e.range.slice(ir.length),!0))}supportsLocator(e,r){return!1}shouldPersistResolution(e,r){throw new Error("Unreachable")}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){let i=S.parseDescriptor(e.range.slice(ir.length),!0);return r.resolver.getResolutionDependencies(i,r)}async getCandidates(e,r,i){let n=S.parseDescriptor(e.range.slice(ir.length),!0);return await i.resolver.getCandidates(n,r,i)}async getSatisfying(e,r,i){let n=S.parseDescriptor(e.range.slice(ir.length),!0);return i.resolver.getSatisfying(n,r,i)}resolve(e,r){throw new Error("Unreachable")}};var vT=ie(Or()),Fce=ie(require("url"));var Vs=class{supports(e,r){if(!e.reference.startsWith(ir))return!1;let i=new Fce.URL(e.reference);return!(!vT.default.valid(i.pathname)||i.searchParams.has("__archiveUrl"))}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the remote registry`),loader:()=>this.fetchFromNetwork(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:S.getIdentVendorPath(e),checksum:o}}async fetchFromNetwork(e,r){let i;try{i=await zs(Vs.getLocatorUrl(e),{configuration:r.project.configuration,ident:e})}catch(n){i=await zs(Vs.getLocatorUrl(e).replace(/%2f/g,"/"),{configuration:r.project.configuration,ident:e})}return await Ai.convertToZip(i,{compressionLevel:r.project.configuration.get("compressionLevel"),prefixPath:S.getIdentVendorPath(e),stripComponents:1})}static isConventionalTarballUrl(e,r,{configuration:i}){let n=Ya(e.scope,{configuration:i}),s=Vs.getLocatorUrl(e);return r=r.replace(/^https?:(\/\/(?:[^/]+\.)?npmjs.org(?:$|\/))/,"https:$1"),n=n.replace(/^https:\/\/registry\.npmjs\.org($|\/)/,"https://registry.yarnpkg.com$1"),r=r.replace(/^https:\/\/registry\.npmjs\.org($|\/)/,"https://registry.yarnpkg.com$1"),r===n+s||r===n+s.replace(/%2f/g,"/")}static getLocatorUrl(e){let r=vT.default.clean(e.reference.slice(ir.length));if(r===null)throw new nt(z.RESOLVER_NOT_FOUND,"The npm semver resolver got selected, but the version isn't semver");return`${zA(e)}/-/${e.name}-${r}.tgz`}};var ST=ie(Or());var rQ=S.makeIdent(null,"node-gyp"),Z6e=/\b(node-gyp|prebuild-install)\b/,xT=class{supportsDescriptor(e,r){return e.range.startsWith(ir)?!!qt.validRange(e.range.slice(ir.length)):!1}supportsLocator(e,r){if(!e.reference.startsWith(ir))return!1;let{selector:i}=S.parseRange(e.reference);return!!ST.default.valid(i)}shouldPersistResolution(e,r){return!0}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){let n=qt.validRange(e.range.slice(ir.length));if(n===null)throw new Error(`Expected a valid range, got ${e.range.slice(ir.length)}`);let s=await zs(zA(e),{configuration:i.project.configuration,ident:e,jsonResponse:!0}),o=de.mapAndFilter(Object.keys(s.versions),c=>{try{let u=new qt.SemVer(c);if(n.test(u))return u}catch{}return de.mapAndFilter.skip}),a=o.filter(c=>!s.versions[c.raw].deprecated),l=a.length>0?a:o;return l.sort((c,u)=>-c.compare(u)),l.map(c=>{let u=S.makeLocator(e,`${ir}${c.raw}`),g=s.versions[c.raw].dist.tarball;return Vs.isConventionalTarballUrl(u,g,{configuration:i.project.configuration})?u:S.bindLocator(u,{__archiveUrl:g})})}async getSatisfying(e,r,i){let n=qt.validRange(e.range.slice(ir.length));if(n===null)throw new Error(`Expected a valid range, got ${e.range.slice(ir.length)}`);return de.mapAndFilter(r,s=>{try{let{selector:o}=S.parseRange(s,{requireProtocol:ir}),a=new qt.SemVer(o);if(n.test(a))return{reference:s,version:a}}catch{}return de.mapAndFilter.skip}).sort((s,o)=>-s.version.compare(o.version)).map(({reference:s})=>S.makeLocator(e,s))}async resolve(e,r){let{selector:i}=S.parseRange(e.reference),n=ST.default.clean(i);if(n===null)throw new nt(z.RESOLVER_NOT_FOUND,"The npm semver resolver got selected, but the version isn't semver");let s=await zs(zA(e),{configuration:r.project.configuration,ident:e,jsonResponse:!0});if(!Object.prototype.hasOwnProperty.call(s,"versions"))throw new nt(z.REMOTE_INVALID,'Registry returned invalid data for - missing "versions" field');if(!Object.prototype.hasOwnProperty.call(s.versions,n))throw new nt(z.REMOTE_NOT_FOUND,`Registry failed to return reference "${n}"`);let o=new Ze;if(o.load(s.versions[n]),!o.dependencies.has(rQ.identHash)&&!o.peerDependencies.has(rQ.identHash)){for(let a of o.scripts.values())if(a.match(Z6e)){o.dependencies.set(rQ.identHash,S.makeDescriptor(rQ,"latest")),r.report.reportWarningOnce(z.NODE_GYP_INJECTED,`${S.prettyLocator(r.project.configuration,e)}: Implicit dependencies on node-gyp are discouraged`);break}}return typeof o.raw.deprecated=="string"&&r.report.reportWarningOnce(z.DEPRECATED_PACKAGE,`${S.prettyLocator(r.project.configuration,e)} is deprecated: ${o.raw.deprecated}`),_(P({},e),{version:n,languageName:"node",linkType:gt.HARD,conditions:o.getConditions(),dependencies:o.dependencies,peerDependencies:o.peerDependencies,dependenciesMeta:o.dependenciesMeta,peerDependenciesMeta:o.peerDependenciesMeta,bin:o.bin})}};var kT=class{supportsDescriptor(e,r){return!(!e.range.startsWith(ir)||!Rg.test(e.range.slice(ir.length)))}supportsLocator(e,r){return!1}shouldPersistResolution(e,r){throw new Error("Unreachable")}bindDescriptor(e,r,i){return e}getResolutionDependencies(e,r){return[]}async getCandidates(e,r,i){let n=e.range.slice(ir.length),s=await zs(zA(e),{configuration:i.project.configuration,ident:e,jsonResponse:!0});if(!Object.prototype.hasOwnProperty.call(s,"dist-tags"))throw new nt(z.REMOTE_INVALID,'Registry returned invalid data - missing "dist-tags" field');let o=s["dist-tags"];if(!Object.prototype.hasOwnProperty.call(o,n))throw new nt(z.REMOTE_NOT_FOUND,`Registry failed to return tag "${n}"`);let a=o[n],l=S.makeLocator(e,`${ir}${a}`),c=s.versions[a].dist.tarball;return Vs.isConventionalTarballUrl(l,c,{configuration:i.project.configuration})?[l]:[S.bindLocator(l,{__archiveUrl:c})]}async getSatisfying(e,r,i){return null}async resolve(e,r){throw new Error("Unreachable")}};var Rf={};it(Rf,{getGitHead:()=>_7e,makePublishBody:()=>V7e});var CM={};it(CM,{default:()=>D7e,packUtils:()=>za});var za={};it(za,{genPackList:()=>QQ,genPackStream:()=>dM,genPackageManifest:()=>age,hasPackScripts:()=>hM,prepareForPack:()=>pM});var fM=ie(Nn()),sge=ie(nge()),oge=ie(require("zlib")),I7e=["/package.json","/readme","/readme.*","/license","/license.*","/licence","/licence.*","/changelog","/changelog.*"],y7e=["/package.tgz",".github",".git",".hg","node_modules",".npmignore",".gitignore",".#*",".DS_Store"];async function hM(t){return!!(Kt.hasWorkspaceScript(t,"prepack")||Kt.hasWorkspaceScript(t,"postpack"))}async function pM(t,{report:e},r){await Kt.maybeExecuteWorkspaceLifecycleScript(t,"prepack",{report:e});try{let i=v.join(t.cwd,Ze.fileName);await T.existsPromise(i)&&await t.manifest.loadFile(i,{baseFs:T}),await r()}finally{await Kt.maybeExecuteWorkspaceLifecycleScript(t,"postpack",{report:e})}}async function dM(t,e){var s,o;typeof e=="undefined"&&(e=await QQ(t));let r=new Set;for(let a of(o=(s=t.manifest.publishConfig)==null?void 0:s.executableFiles)!=null?o:new Set)r.add(v.normalize(a));for(let a of t.manifest.bin.values())r.add(v.normalize(a));let i=sge.default.pack();process.nextTick(async()=>{for(let a of e){let l=v.normalize(a),c=v.resolve(t.cwd,l),u=v.join("package",l),g=await T.lstatPromise(c),f={name:u,mtime:new Date(mr.SAFE_TIME*1e3)},h=r.has(l)?493:420,p,d,m=new Promise((B,b)=>{p=B,d=b}),I=B=>{B?d(B):p()};if(g.isFile()){let B;l==="package.json"?B=Buffer.from(JSON.stringify(await age(t),null,2)):B=await T.readFilePromise(c),i.entry(_(P({},f),{mode:h,type:"file"}),B,I)}else g.isSymbolicLink()?i.entry(_(P({},f),{mode:h,type:"symlink",linkname:await T.readlinkPromise(c)}),I):I(new Error(`Unsupported file type ${g.mode} for ${M.fromPortablePath(l)}`));await m}i.finalize()});let n=(0,oge.createGzip)();return i.pipe(n),n}async function age(t){let e=JSON.parse(JSON.stringify(t.manifest.raw));return await t.project.configuration.triggerHook(r=>r.beforeWorkspacePacking,t,e),e}async function QQ(t){var g,f,h,p,d,m,I,B;let e=t.project,r=e.configuration,i={accept:[],reject:[]};for(let b of y7e)i.reject.push(b);for(let b of I7e)i.accept.push(b);i.reject.push(r.get("rcFilename"));let n=b=>{if(b===null||!b.startsWith(`${t.cwd}/`))return;let R=v.relative(t.cwd,b),H=v.resolve(Se.root,R);i.reject.push(H)};n(v.resolve(e.cwd,r.get("lockfileFilename"))),n(r.get("cacheFolder")),n(r.get("globalFolder")),n(r.get("installStatePath")),n(r.get("virtualFolder")),n(r.get("yarnPath")),await r.triggerHook(b=>b.populateYarnPaths,e,b=>{n(b)});for(let b of e.workspaces){let R=v.relative(t.cwd,b.cwd);R!==""&&!R.match(/^(\.\.)?\//)&&i.reject.push(`/${R}`)}let s={accept:[],reject:[]},o=(f=(g=t.manifest.publishConfig)==null?void 0:g.main)!=null?f:t.manifest.main,a=(p=(h=t.manifest.publishConfig)==null?void 0:h.module)!=null?p:t.manifest.module,l=(m=(d=t.manifest.publishConfig)==null?void 0:d.browser)!=null?m:t.manifest.browser,c=(B=(I=t.manifest.publishConfig)==null?void 0:I.bin)!=null?B:t.manifest.bin;o!=null&&s.accept.push(v.resolve(Se.root,o)),a!=null&&s.accept.push(v.resolve(Se.root,a)),typeof l=="string"&&s.accept.push(v.resolve(Se.root,l));for(let b of c.values())s.accept.push(v.resolve(Se.root,b));if(l instanceof Map)for(let[b,R]of l.entries())s.accept.push(v.resolve(Se.root,b)),typeof R=="string"&&s.accept.push(v.resolve(Se.root,R));let u=t.manifest.files!==null;if(u){s.reject.push("/*");for(let b of t.manifest.files)Age(s.accept,b,{cwd:Se.root})}return await w7e(t.cwd,{hasExplicitFileList:u,globalList:i,ignoreList:s})}async function w7e(t,{hasExplicitFileList:e,globalList:r,ignoreList:i}){let n=[],s=new Zo(t),o=[[Se.root,[i]]];for(;o.length>0;){let[a,l]=o.pop(),c=await s.lstatPromise(a);if(!cge(a,{globalList:r,ignoreLists:c.isDirectory()?null:l}))if(c.isDirectory()){let u=await s.readdirPromise(a),g=!1,f=!1;if(!e||a!==Se.root)for(let d of u)g=g||d===".gitignore",f=f||d===".npmignore";let h=f?await lge(s,a,".npmignore"):g?await lge(s,a,".gitignore"):null,p=h!==null?[h].concat(l):l;cge(a,{globalList:r,ignoreLists:l})&&(p=[...l,{accept:[],reject:["**/*"]}]);for(let d of u)o.push([v.resolve(a,d),p])}else(c.isFile()||c.isSymbolicLink())&&n.push(v.relative(Se.root,a))}return n.sort()}async function lge(t,e,r){let i={accept:[],reject:[]},n=await t.readFilePromise(v.join(e,r),"utf8");for(let s of n.split(/\n/g))Age(i.reject,s,{cwd:e});return i}function B7e(t,{cwd:e}){let r=t[0]==="!";return r&&(t=t.slice(1)),t.match(/\.{0,1}\//)&&(t=v.resolve(e,t)),r&&(t=`!${t}`),t}function Age(t,e,{cwd:r}){let i=e.trim();i===""||i[0]==="#"||t.push(B7e(i,{cwd:r}))}function cge(t,{globalList:e,ignoreLists:r}){if(bQ(t,e.accept))return!1;if(bQ(t,e.reject))return!0;if(r!==null)for(let i of r){if(bQ(t,i.accept))return!1;if(bQ(t,i.reject))return!0}return!1}function bQ(t,e){let r=e,i=[];for(let n=0;n{await pM(i,{report:l},async()=>{l.reportJson({base:M.fromPortablePath(i.cwd)});let c=await QQ(i);for(let u of c)l.reportInfo(null,M.fromPortablePath(u)),l.reportJson({location:M.fromPortablePath(u)});if(!this.dryRun){let u=await dM(i,c),g=T.createWriteStream(s);u.pipe(g),await new Promise(f=>{g.on("finish",f)})}}),this.dryRun||(l.reportInfo(z.UNNAMED,`Package archive generated in ${ue.pretty(e,s,ue.Type.PATH)}`),l.reportJson({output:M.fromPortablePath(s)}))})).exitCode()}};fm.paths=[["pack"]],fm.usage=ye.Usage({description:"generate a tarball from the active workspace",details:"\n This command will turn the active workspace into a compressed archive suitable for publishing. The archive will by default be stored at the root of the workspace (`package.tgz`).\n\n If the `-o,---out` is set the archive will be created at the specified path. The `%s` and `%v` variables can be used within the path and will be respectively replaced by the package name and version.\n ",examples:[["Create an archive from the active workspace","yarn pack"],["List the files that would be made part of the workspace's archive","yarn pack --dry-run"],["Name and output the archive in a dedicated folder","yarn pack --out /artifacts/%s-%v.tgz"]]});var gge=fm;function Q7e(t,{workspace:e}){let r=t.replace("%s",b7e(e)).replace("%v",v7e(e));return M.toPortablePath(r)}function b7e(t){return t.manifest.name!==null?S.slugifyIdent(t.manifest.name):"package"}function v7e(t){return t.manifest.version!==null?t.manifest.version:"unknown"}var S7e=["dependencies","devDependencies","peerDependencies"],x7e="workspace:",k7e=(t,e)=>{var i,n;e.publishConfig&&(e.publishConfig.main&&(e.main=e.publishConfig.main),e.publishConfig.browser&&(e.browser=e.publishConfig.browser),e.publishConfig.module&&(e.module=e.publishConfig.module),e.publishConfig.browser&&(e.browser=e.publishConfig.browser),e.publishConfig.exports&&(e.exports=e.publishConfig.exports),e.publishConfig.bin&&(e.bin=e.publishConfig.bin));let r=t.project;for(let s of S7e)for(let o of t.manifest.getForScope(s).values()){let a=r.tryWorkspaceByDescriptor(o),l=S.parseRange(o.range);if(l.protocol===x7e)if(a===null){if(r.tryWorkspaceByIdent(o)===null)throw new nt(z.WORKSPACE_NOT_FOUND,`${S.prettyDescriptor(r.configuration,o)}: No local workspace found for this range`)}else{let c;S.areDescriptorsEqual(o,a.anchoredDescriptor)||l.selector==="*"?c=(i=a.manifest.version)!=null?i:"0.0.0":l.selector==="~"||l.selector==="^"?c=`${l.selector}${(n=a.manifest.version)!=null?n:"0.0.0"}`:c=l.selector,e[s][S.stringifyIdent(o)]=c}}},P7e={hooks:{beforeWorkspacePacking:k7e},commands:[gge]},D7e=P7e;var yge=ie(require("crypto")),wge=ie(Ige()),Bge=ie(require("url"));async function V7e(t,e,{access:r,tag:i,registry:n,gitHead:s}){let o=t.project.configuration,a=t.manifest.name,l=t.manifest.version,c=S.stringifyIdent(a),u=(0,yge.createHash)("sha1").update(e).digest("hex"),g=wge.default.fromData(e).toString();typeof r=="undefined"&&(t.manifest.publishConfig&&typeof t.manifest.publishConfig.access=="string"?r=t.manifest.publishConfig.access:o.get("npmPublishAccess")!==null?r=o.get("npmPublishAccess"):a.scope?r="restricted":r="public");let f=await za.genPackageManifest(t),h=`${c}-${l}.tgz`,p=new Bge.URL(`${To(n)}/${c}/-/${h}`);return{_id:c,_attachments:{[h]:{content_type:"application/octet-stream",data:e.toString("base64"),length:e.length}},name:c,access:r,["dist-tags"]:{[i]:l},versions:{[l]:_(P({},f),{_id:`${c}@${l}`,name:c,version:l,gitHead:s,dist:{shasum:u,integrity:g,tarball:p.toString()}})}}}async function _7e(t){try{let{stdout:e}=await hr.execvp("git",["rev-parse","--revs-only","HEAD"],{cwd:t});return e.trim()===""?void 0:e.trim()}catch{return}}var wM={npmAlwaysAuth:{description:"URL of the selected npm registry (note: npm enterprise isn't supported)",type:ge.BOOLEAN,default:!1},npmAuthIdent:{description:"Authentication identity for the npm registry (_auth in npm and yarn v1)",type:ge.SECRET,default:null},npmAuthToken:{description:"Authentication token for the npm registry (_authToken in npm and yarn v1)",type:ge.SECRET,default:null}},Qge={npmAuditRegistry:{description:"Registry to query for audit reports",type:ge.STRING,default:null},npmPublishRegistry:{description:"Registry to push packages to",type:ge.STRING,default:null},npmRegistryServer:{description:"URL of the selected npm registry (note: npm enterprise isn't supported)",type:ge.STRING,default:"https://registry.yarnpkg.com"}},X7e={configuration:_(P(P({},wM),Qge),{npmScopes:{description:"Settings per package scope",type:ge.MAP,valueDefinition:{description:"",type:ge.SHAPE,properties:P(P({},wM),Qge)}},npmRegistries:{description:"Settings per registry",type:ge.MAP,normalizeKeys:To,valueDefinition:{description:"",type:ge.SHAPE,properties:P({},wM)}}}),fetchers:[QT,Vs],resolvers:[bT,xT,kT]},Z7e=X7e;var vM={};it(vM,{default:()=>a_e});Ss();var Ho;(function(i){i.All="all",i.Production="production",i.Development="development"})(Ho||(Ho={}));var Xs;(function(s){s.Info="info",s.Low="low",s.Moderate="moderate",s.High="high",s.Critical="critical"})(Xs||(Xs={}));var vQ=[Xs.Info,Xs.Low,Xs.Moderate,Xs.High,Xs.Critical];function bge(t,e){let r=[],i=new Set,n=o=>{i.has(o)||(i.add(o),r.push(o))};for(let o of e)n(o);let s=new Set;for(;r.length>0;){let o=r.shift(),a=t.storedResolutions.get(o);if(typeof a=="undefined")throw new Error("Assertion failed: Expected the resolution to have been registered");let l=t.storedPackages.get(a);if(!!l){s.add(o);for(let c of l.dependencies.values())n(c.descriptorHash)}}return s}function $7e(t,e){return new Set([...t].filter(r=>!e.has(r)))}function e_e(t,e,{all:r}){let i=r?t.workspaces:[e],n=i.map(f=>f.manifest),s=new Set(n.map(f=>[...f.dependencies].map(([h,p])=>h)).flat()),o=new Set(n.map(f=>[...f.devDependencies].map(([h,p])=>h)).flat()),a=i.map(f=>[...f.dependencies.values()]).flat(),l=a.filter(f=>s.has(f.identHash)).map(f=>f.descriptorHash),c=a.filter(f=>o.has(f.identHash)).map(f=>f.descriptorHash),u=bge(t,l),g=bge(t,c);return $7e(g,u)}function vge(t){let e={};for(let r of t)e[S.stringifyIdent(r)]=S.parseRange(r.range).selector;return e}function Sge(t){if(typeof t=="undefined")return new Set;let e=vQ.indexOf(t),r=vQ.slice(e);return new Set(r)}function t_e(t,e){let r=Sge(e),i={};for(let n of r)i[n]=t[n];return i}function xge(t,e){var i;let r=t_e(t,e);for(let n of Object.keys(r))if((i=r[n])!=null?i:0>0)return!0;return!1}function kge(t,e){var s;let r={},i={children:r},n=Object.values(t.advisories);if(e!=null){let o=Sge(e);n=n.filter(a=>o.has(a.severity))}for(let o of de.sortMap(n,a=>a.module_name))r[o.module_name]={label:o.module_name,value:ue.tuple(ue.Type.RANGE,o.findings.map(a=>a.version).join(", ")),children:{Issue:{label:"Issue",value:ue.tuple(ue.Type.NO_HINT,o.title)},URL:{label:"URL",value:ue.tuple(ue.Type.URL,o.url)},Severity:{label:"Severity",value:ue.tuple(ue.Type.NO_HINT,o.severity)},["Vulnerable Versions"]:{label:"Vulnerable Versions",value:ue.tuple(ue.Type.RANGE,o.vulnerable_versions)},["Patched Versions"]:{label:"Patched Versions",value:ue.tuple(ue.Type.RANGE,o.patched_versions)},Via:{label:"Via",value:ue.tuple(ue.Type.NO_HINT,Array.from(new Set(o.findings.map(a=>a.paths).flat().map(a=>a.split(">")[0]))).join(", "))},Recommendation:{label:"Recommendation",value:ue.tuple(ue.Type.NO_HINT,(s=o.recommendation)==null?void 0:s.replace(/\n/g," "))}}};return i}function Pge(t,e,{all:r,environment:i}){let n=r?t.workspaces:[e],s=[Ho.All,Ho.Production].includes(i),o=[];if(s)for(let c of n)for(let u of c.manifest.dependencies.values())o.push(u);let a=[Ho.All,Ho.Development].includes(i),l=[];if(a)for(let c of n)for(let u of c.manifest.devDependencies.values())l.push(u);return vge([...o,...l].filter(c=>S.parseRange(c.range).protocol===null))}function Dge(t,e,{all:r}){var s;let i=e_e(t,e,{all:r}),n={};for(let o of t.storedPackages.values())n[S.stringifyIdent(o)]={version:(s=o.version)!=null?s:"0.0.0",integrity:o.identHash,requires:vge(o.dependencies.values()),dev:i.has(S.convertLocatorToDescriptor(o).descriptorHash)};return n}var dm=class extends Be{constructor(){super(...arguments);this.all=Y.Boolean("-A,--all",!1,{description:"Audit dependencies from all workspaces"});this.recursive=Y.Boolean("-R,--recursive",!1,{description:"Audit transitive dependencies as well"});this.environment=Y.String("--environment",Ho.All,{description:"Which environments to cover",validator:Yi(Ho)});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.severity=Y.String("--severity",Xs.Info,{description:"Minimal severity requested for packages to be displayed",validator:Yi(Xs)})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState();let n=Pge(r,i,{all:this.all,environment:this.environment}),s=Dge(r,i,{all:this.all});if(!this.recursive)for(let f of Object.keys(s))Object.prototype.hasOwnProperty.call(n,f)?s[f].requires={}:delete s[f];let o={requires:n,dependencies:s},a=gr.getAuditRegistry(i.manifest,{configuration:e}),l,c=await Fa.start({configuration:e,stdout:this.context.stdout},async()=>{l=await Lt.post("/-/npm/v1/security/audits/quick",o,{authType:Lt.AuthType.BEST_EFFORT,configuration:e,jsonResponse:!0,registry:a})});if(c.hasErrors())return c.exitCode();let u=xge(l.metadata.vulnerabilities,this.severity);return!this.json&&u?(Hs.emitTree(kge(l,this.severity),{configuration:e,json:this.json,stdout:this.context.stdout,separators:2}),1):(await Fe.start({configuration:e,includeFooter:!1,json:this.json,stdout:this.context.stdout},async f=>{f.reportJson(l),u||f.reportInfo(z.EXCEPTION,"No audit suggestions")})).exitCode()}};dm.paths=[["npm","audit"]],dm.usage=ye.Usage({description:"perform a vulnerability audit against the installed packages",details:` - This command checks for known security reports on the packages you use. The reports are by default extracted from the npm registry, and may or may not be relevant to your actual program (not all vulnerabilities affect all code paths). - - For consistency with our other commands the default is to only check the direct dependencies for the active workspace. To extend this search to all workspaces, use \`-A,--all\`. To extend this search to both direct and transitive dependencies, use \`-R,--recursive\`. - - Applying the \`--severity\` flag will limit the audit table to vulnerabilities of the corresponding severity and above. Valid values are ${vQ.map(e=>`\`${e}\``).join(", ")}. - - If the \`--json\` flag is set, Yarn will print the output exactly as received from the registry. Regardless of this flag, the process will exit with a non-zero exit code if a report is found for the selected packages. - - To understand the dependency tree requiring vulnerable packages, check the raw report with the \`--json\` flag or use \`yarn why \` to get more information as to who depends on them. - `,examples:[["Checks for known security issues with the installed packages. The output is a list of known issues.","yarn npm audit"],["Audit dependencies in all workspaces","yarn npm audit --all"],["Limit auditing to `dependencies` (excludes `devDependencies`)","yarn npm audit --environment production"],["Show audit report as valid JSON","yarn npm audit --json"],["Audit all direct and transitive dependencies","yarn npm audit --recursive"],["Output moderate (or more severe) vulnerabilities","yarn npm audit --severity moderate"]]});var Rge=dm;var BM=ie(Or()),QM=ie(require("util")),Cm=class extends Be{constructor(){super(...arguments);this.fields=Y.String("-f,--fields",{description:"A comma-separated list of manifest fields that should be displayed"});this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.packages=Y.Rest()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r}=await Ke.find(e,this.context.cwd),i=typeof this.fields!="undefined"?new Set(["name",...this.fields.split(/\s*,\s*/)]):null,n=[],s=!1,o=await Fe.start({configuration:e,includeFooter:!1,json:this.json,stdout:this.context.stdout},async a=>{for(let l of this.packages){let c;if(l==="."){let b=r.topLevelWorkspace;if(!b.manifest.name)throw new me(`Missing 'name' field in ${M.fromPortablePath(v.join(b.cwd,wt.manifest))}`);c=S.makeDescriptor(b.manifest.name,"unknown")}else c=S.parseDescriptor(l);let u=Lt.getIdentUrl(c),g=bM(await Lt.get(u,{configuration:e,ident:c,jsonResponse:!0,customErrorMessage:Lt.customPackageError})),f=Object.keys(g.versions).sort(BM.default.compareLoose),p=g["dist-tags"].latest||f[f.length-1],d=qt.validRange(c.range);if(d){let b=BM.default.maxSatisfying(f,d);b!==null?p=b:(a.reportWarning(z.UNNAMED,`Unmet range ${S.prettyRange(e,c.range)}; falling back to the latest version`),s=!0)}else c.range!=="unknown"&&(a.reportWarning(z.UNNAMED,`Invalid range ${S.prettyRange(e,c.range)}; falling back to the latest version`),s=!0);let m=g.versions[p],I=_(P(P({},g),m),{version:p,versions:f}),B;if(i!==null){B={};for(let b of i){let R=I[b];if(typeof R!="undefined")B[b]=R;else{a.reportWarning(z.EXCEPTION,`The '${b}' field doesn't exist inside ${S.prettyIdent(e,c)}'s informations`),s=!0;continue}}}else this.json||(delete I.dist,delete I.readme,delete I.users),B=I;a.reportJson(B),this.json||n.push(B)}});QM.inspect.styles.name="cyan";for(let a of n)(a!==n[0]||s)&&this.context.stdout.write(` -`),this.context.stdout.write(`${(0,QM.inspect)(a,{depth:Infinity,colors:!0,compact:!1})} -`);return o.exitCode()}};Cm.paths=[["npm","info"]],Cm.usage=ye.Usage({category:"Npm-related commands",description:"show information about a package",details:"\n This command will fetch information about a package from the npm registry, and prints it in a tree format.\n\n The package does not have to be installed locally, but needs to have been published (in particular, local changes will be ignored even for workspaces).\n\n Append `@` to the package argument to provide information specific to the latest version that satisfies the range. If the range is invalid or if there is no version satisfying the range, the command will print a warning and fall back to the latest version.\n\n If the `-f,--fields` option is set, it's a comma-separated list of fields which will be used to only display part of the package informations.\n\n By default, this command won't return the `dist`, `readme`, and `users` fields, since they are often very long. To explicitly request those fields, explicitly list them with the `--fields` flag or request the output in JSON mode.\n ",examples:[["Show all available information about react (except the `dist`, `readme`, and `users` fields)","yarn npm info react"],["Show all available information about react as valid JSON (including the `dist`, `readme`, and `users` fields)","yarn npm info react --json"],["Show all available information about react 16.12.0","yarn npm info react@16.12.0"],["Show the description of react","yarn npm info react --fields description"],["Show all available versions of react","yarn npm info react --fields versions"],["Show the readme of react","yarn npm info react --fields readme"],["Show a few fields of react","yarn npm info react --fields homepage,repository"]]});var Fge=Cm;function bM(t){if(Array.isArray(t)){let e=[];for(let r of t)r=bM(r),r&&e.push(r);return e}else if(typeof t=="object"&&t!==null){let e={};for(let r of Object.keys(t)){if(r.startsWith("_"))continue;let i=bM(t[r]);i&&(e[r]=i)}return e}else return t||null}var Nge=ie(aC()),mm=class extends Be{constructor(){super(...arguments);this.scope=Y.String("-s,--scope",{description:"Login to the registry configured for a given scope"});this.publish=Y.Boolean("--publish",!1,{description:"Login to the publish registry"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=await SQ({configuration:e,cwd:this.context.cwd,publish:this.publish,scope:this.scope});return(await Fe.start({configuration:e,stdout:this.context.stdout},async n=>{let s=await i_e({registry:r,report:n,stdin:this.context.stdin,stdout:this.context.stdout}),o=`/-/user/org.couchdb.user:${encodeURIComponent(s.name)}`,a=await Lt.put(o,s,{attemptedAs:s.name,configuration:e,registry:r,jsonResponse:!0,authType:Lt.AuthType.NO_AUTH});return await r_e(r,a.token,{configuration:e,scope:this.scope}),n.reportInfo(z.UNNAMED,"Successfully logged in")})).exitCode()}};mm.paths=[["npm","login"]],mm.usage=ye.Usage({category:"Npm-related commands",description:"store new login info to access the npm registry",details:"\n This command will ask you for your username, password, and 2FA One-Time-Password (when it applies). It will then modify your local configuration (in your home folder, never in the project itself) to reference the new tokens thus generated.\n\n Adding the `-s,--scope` flag will cause the authentication to be done against whatever registry is configured for the associated scope (see also `npmScopes`).\n\n Adding the `--publish` flag will cause the authentication to be done against the registry used when publishing the package (see also `publishConfig.registry` and `npmPublishRegistry`).\n ",examples:[["Login to the default registry","yarn npm login"],["Login to the registry linked to the @my-scope registry","yarn npm login --scope my-scope"],["Login to the publish registry for the current package","yarn npm login --publish"]]});var Lge=mm;async function SQ({scope:t,publish:e,configuration:r,cwd:i}){return t&&e?gr.getScopeRegistry(t,{configuration:r,type:gr.RegistryType.PUBLISH_REGISTRY}):t?gr.getScopeRegistry(t,{configuration:r}):e?gr.getPublishRegistry((await rf(r,i)).manifest,{configuration:r}):gr.getDefaultRegistry({configuration:r})}async function r_e(t,e,{configuration:r,scope:i}){let n=o=>a=>{let l=de.isIndexableObject(a)?a:{},c=l[o],u=de.isIndexableObject(c)?c:{};return _(P({},l),{[o]:_(P({},u),{npmAuthToken:e})})},s=i?{npmScopes:n(i)}:{npmRegistries:n(t)};return await fe.updateHomeConfiguration(s)}async function i_e({registry:t,report:e,stdin:r,stdout:i}){if(process.env.TEST_ENV)return{name:process.env.TEST_NPM_USER||"",password:process.env.TEST_NPM_PASSWORD||""};e.reportInfo(z.UNNAMED,`Logging in to ${t}`);let n=!1;t.match(/^https:\/\/npm\.pkg\.github\.com(\/|$)/)&&(e.reportInfo(z.UNNAMED,"You seem to be using the GitHub Package Registry. Tokens must be generated with the 'repo', 'write:packages', and 'read:packages' permissions."),n=!0),e.reportSeparator();let{username:s,password:o}=await(0,Nge.prompt)([{type:"input",name:"username",message:"Username:",required:!0,onCancel:()=>process.exit(130),stdin:r,stdout:i},{type:"password",name:"password",message:n?"Token:":"Password:",required:!0,onCancel:()=>process.exit(130),stdin:r,stdout:i}]);return e.reportSeparator(),{name:s,password:o}}var Ff=new Set(["npmAuthIdent","npmAuthToken"]),Em=class extends Be{constructor(){super(...arguments);this.scope=Y.String("-s,--scope",{description:"Logout of the registry configured for a given scope"});this.publish=Y.Boolean("--publish",!1,{description:"Logout of the publish registry"});this.all=Y.Boolean("-A,--all",!1,{description:"Logout of all registries"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r=async()=>{var l;let n=await SQ({configuration:e,cwd:this.context.cwd,publish:this.publish,scope:this.scope}),s=await fe.find(this.context.cwd,this.context.plugins),o=S.makeIdent((l=this.scope)!=null?l:null,"pkg");return!gr.getAuthConfiguration(n,{configuration:s,ident:o}).get("npmAuthToken")};return(await Fe.start({configuration:e,stdout:this.context.stdout},async n=>{if(this.all&&(await n_e(),n.reportInfo(z.UNNAMED,"Successfully logged out from everything")),this.scope){await Tge("npmScopes",this.scope),await r()?n.reportInfo(z.UNNAMED,`Successfully logged out from ${this.scope}`):n.reportWarning(z.UNNAMED,"Scope authentication settings removed, but some other ones settings still apply to it");return}let s=await SQ({configuration:e,cwd:this.context.cwd,publish:this.publish});await Tge("npmRegistries",s),await r()?n.reportInfo(z.UNNAMED,`Successfully logged out from ${s}`):n.reportWarning(z.UNNAMED,"Registry authentication settings removed, but some other ones settings still apply to it")})).exitCode()}};Em.paths=[["npm","logout"]],Em.usage=ye.Usage({category:"Npm-related commands",description:"logout of the npm registry",details:"\n This command will log you out by modifying your local configuration (in your home folder, never in the project itself) to delete all credentials linked to a registry.\n\n Adding the `-s,--scope` flag will cause the deletion to be done against whatever registry is configured for the associated scope (see also `npmScopes`).\n\n Adding the `--publish` flag will cause the deletion to be done against the registry used when publishing the package (see also `publishConfig.registry` and `npmPublishRegistry`).\n\n Adding the `-A,--all` flag will cause the deletion to be done against all registries and scopes.\n ",examples:[["Logout of the default registry","yarn npm logout"],["Logout of the @my-scope scope","yarn npm logout --scope my-scope"],["Logout of the publish registry for the current package","yarn npm logout --publish"],["Logout of all registries","yarn npm logout --all"]]});var Mge=Em;function s_e(t,e){let r=t[e];if(!de.isIndexableObject(r))return!1;let i=new Set(Object.keys(r));if([...Ff].every(s=>!i.has(s)))return!1;for(let s of Ff)i.delete(s);if(i.size===0)return t[e]=void 0,!0;let n=P({},r);for(let s of Ff)delete n[s];return t[e]=n,!0}async function n_e(){let t=e=>{let r=!1,i=de.isIndexableObject(e)?P({},e):{};i.npmAuthToken&&(delete i.npmAuthToken,r=!0);for(let n of Object.keys(i))s_e(i,n)&&(r=!0);if(Object.keys(i).length!==0)return r?i:e};return await fe.updateHomeConfiguration({npmRegistries:t,npmScopes:t})}async function Tge(t,e){return await fe.updateHomeConfiguration({[t]:r=>{let i=de.isIndexableObject(r)?r:{};if(!Object.prototype.hasOwnProperty.call(i,e))return r;let n=i[e],s=de.isIndexableObject(n)?n:{},o=new Set(Object.keys(s));if([...Ff].every(l=>!o.has(l)))return r;for(let l of Ff)o.delete(l);if(o.size===0)return Object.keys(i).length===1?void 0:_(P({},i),{[e]:void 0});let a={};for(let l of Ff)a[l]=void 0;return _(P({},i),{[e]:P(P({},s),a)})}})}var Im=class extends Be{constructor(){super(...arguments);this.access=Y.String("--access",{description:"The access for the published package (public or restricted)"});this.tag=Y.String("--tag","latest",{description:"The tag on the registry that the package should be attached to"});this.tolerateRepublish=Y.Boolean("--tolerate-republish",!1,{description:"Warn and exit when republishing an already existing version of a package"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);if(i.manifest.private)throw new me("Private workspaces cannot be published");if(i.manifest.name===null||i.manifest.version===null)throw new me("Workspaces must have valid names and versions to be published on an external registry");await r.restoreInstallState();let n=i.manifest.name,s=i.manifest.version,o=gr.getPublishRegistry(i.manifest,{configuration:e});return(await Fe.start({configuration:e,stdout:this.context.stdout},async l=>{var c,u;if(this.tolerateRepublish)try{let g=await Lt.get(Lt.getIdentUrl(n),{configuration:e,registry:o,ident:n,jsonResponse:!0});if(!Object.prototype.hasOwnProperty.call(g,"versions"))throw new nt(z.REMOTE_INVALID,'Registry returned invalid data for - missing "versions" field');if(Object.prototype.hasOwnProperty.call(g.versions,s)){l.reportWarning(z.UNNAMED,`Registry already knows about version ${s}; skipping.`);return}}catch(g){if(((u=(c=g.originalError)==null?void 0:c.response)==null?void 0:u.statusCode)!==404)throw g}await Kt.maybeExecuteWorkspaceLifecycleScript(i,"prepublish",{report:l}),await za.prepareForPack(i,{report:l},async()=>{let g=await za.genPackList(i);for(let m of g)l.reportInfo(null,m);let f=await za.genPackStream(i,g),h=await de.bufferStream(f),p=await Rf.getGitHead(i.cwd),d=await Rf.makePublishBody(i,h,{access:this.access,tag:this.tag,registry:o,gitHead:p});await Lt.put(Lt.getIdentUrl(n),d,{configuration:e,registry:o,ident:n,jsonResponse:!0})}),l.reportInfo(z.UNNAMED,"Package archive published")})).exitCode()}};Im.paths=[["npm","publish"]],Im.usage=ye.Usage({category:"Npm-related commands",description:"publish the active workspace to the npm registry",details:'\n This command will pack the active workspace into a fresh archive and upload it to the npm registry.\n\n The package will by default be attached to the `latest` tag on the registry, but this behavior can be overriden by using the `--tag` option.\n\n Note that for legacy reasons scoped packages are by default published with an access set to `restricted` (aka "private packages"). This requires you to register for a paid npm plan. In case you simply wish to publish a public scoped package to the registry (for free), just add the `--access public` flag. This behavior can be enabled by default through the `npmPublishAccess` settings.\n ',examples:[["Publish the active workspace","yarn npm publish"]]});var Oge=Im;var Uge=ie(Or());var ym=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.package=Y.String({required:!1})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n;if(typeof this.package!="undefined")n=S.parseIdent(this.package);else{if(!i)throw new rt(r.cwd,this.context.cwd);if(!i.manifest.name)throw new me(`Missing 'name' field in ${M.fromPortablePath(v.join(i.cwd,wt.manifest))}`);n=i.manifest.name}let s=await wm(n,e),a={children:de.sortMap(Object.entries(s),([l])=>l).map(([l,c])=>({value:ue.tuple(ue.Type.RESOLUTION,{descriptor:S.makeDescriptor(n,l),locator:S.makeLocator(n,c)})}))};return Hs.emitTree(a,{configuration:e,json:this.json,stdout:this.context.stdout})}};ym.paths=[["npm","tag","list"]],ym.usage=ye.Usage({category:"Npm-related commands",description:"list all dist-tags of a package",details:` - This command will list all tags of a package from the npm registry. - - If the package is not specified, Yarn will default to the current workspace. - `,examples:[["List all tags of package `my-pkg`","yarn npm tag list my-pkg"]]});var Kge=ym;async function wm(t,e){let r=`/-/package${Lt.getIdentUrl(t)}/dist-tags`;return Lt.get(r,{configuration:e,ident:t,jsonResponse:!0,customErrorMessage:Lt.customPackageError})}var Bm=class extends Be{constructor(){super(...arguments);this.package=Y.String();this.tag=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);let n=S.parseDescriptor(this.package,!0),s=n.range;if(!Uge.default.valid(s))throw new me(`The range ${ue.pretty(e,n.range,ue.Type.RANGE)} must be a valid semver version`);let o=gr.getPublishRegistry(i.manifest,{configuration:e}),a=ue.pretty(e,n,ue.Type.IDENT),l=ue.pretty(e,s,ue.Type.RANGE),c=ue.pretty(e,this.tag,ue.Type.CODE);return(await Fe.start({configuration:e,stdout:this.context.stdout},async g=>{let f=await wm(n,e);Object.prototype.hasOwnProperty.call(f,this.tag)&&f[this.tag]===s&&g.reportWarning(z.UNNAMED,`Tag ${c} is already set to version ${l}`);let h=`/-/package${Lt.getIdentUrl(n)}/dist-tags/${encodeURIComponent(this.tag)}`;await Lt.put(h,s,{configuration:e,registry:o,ident:n,jsonRequest:!0,jsonResponse:!0}),g.reportInfo(z.UNNAMED,`Tag ${c} added to version ${l} of package ${a}`)})).exitCode()}};Bm.paths=[["npm","tag","add"]],Bm.usage=ye.Usage({category:"Npm-related commands",description:"add a tag for a specific version of a package",details:` - This command will add a tag to the npm registry for a specific version of a package. If the tag already exists, it will be overwritten. - `,examples:[["Add a `beta` tag for version `2.3.4-beta.4` of package `my-pkg`","yarn npm tag add my-pkg@2.3.4-beta.4 beta"]]});var Hge=Bm;var Qm=class extends Be{constructor(){super(...arguments);this.package=Y.String();this.tag=Y.String()}async execute(){if(this.tag==="latest")throw new me("The 'latest' tag cannot be removed.");let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);let n=S.parseIdent(this.package),s=gr.getPublishRegistry(i.manifest,{configuration:e}),o=ue.pretty(e,this.tag,ue.Type.CODE),a=ue.pretty(e,n,ue.Type.IDENT),l=await wm(n,e);if(!Object.prototype.hasOwnProperty.call(l,this.tag))throw new me(`${o} is not a tag of package ${a}`);return(await Fe.start({configuration:e,stdout:this.context.stdout},async u=>{let g=`/-/package${Lt.getIdentUrl(n)}/dist-tags/${encodeURIComponent(this.tag)}`;await Lt.del(g,{configuration:e,registry:s,ident:n,jsonResponse:!0}),u.reportInfo(z.UNNAMED,`Tag ${o} removed from package ${a}`)})).exitCode()}};Qm.paths=[["npm","tag","remove"]],Qm.usage=ye.Usage({category:"Npm-related commands",description:"remove a tag from a package",details:` - This command will remove a tag from a package from the npm registry. - `,examples:[["Remove the `beta` tag from package `my-pkg`","yarn npm tag remove my-pkg beta"]]});var Gge=Qm;var bm=class extends Be{constructor(){super(...arguments);this.scope=Y.String("-s,--scope",{description:"Print username for the registry configured for a given scope"});this.publish=Y.Boolean("--publish",!1,{description:"Print username for the publish registry"})}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),r;return this.scope&&this.publish?r=gr.getScopeRegistry(this.scope,{configuration:e,type:gr.RegistryType.PUBLISH_REGISTRY}):this.scope?r=gr.getScopeRegistry(this.scope,{configuration:e}):this.publish?r=gr.getPublishRegistry((await rf(e,this.context.cwd)).manifest,{configuration:e}):r=gr.getDefaultRegistry({configuration:e}),(await Fe.start({configuration:e,stdout:this.context.stdout},async n=>{var o,a;let s;try{s=await Lt.get("/-/whoami",{configuration:e,registry:r,authType:Lt.AuthType.ALWAYS_AUTH,jsonResponse:!0,ident:this.scope?S.makeIdent(this.scope,""):void 0})}catch(l){if(((o=l.response)==null?void 0:o.statusCode)===401||((a=l.response)==null?void 0:a.statusCode)===403){n.reportError(z.AUTHENTICATION_INVALID,"Authentication failed - your credentials may have expired");return}else throw l}n.reportInfo(z.UNNAMED,s.username)})).exitCode()}};bm.paths=[["npm","whoami"]],bm.usage=ye.Usage({category:"Npm-related commands",description:"display the name of the authenticated user",details:"\n Print the username associated with the current authentication settings to the standard output.\n\n When using `-s,--scope`, the username printed will be the one that matches the authentication settings of the registry associated with the given scope (those settings can be overriden using the `npmRegistries` map, and the registry associated with the scope is configured via the `npmScopes` map).\n\n When using `--publish`, the registry we'll select will by default be the one used when publishing packages (`publishConfig.registry` or `npmPublishRegistry` if available, otherwise we'll fallback to the regular `npmRegistryServer`).\n ",examples:[["Print username for the default registry","yarn npm whoami"],["Print username for the registry on a given scope","yarn npm whoami --scope company"]]});var jge=bm;var o_e={configuration:{npmPublishAccess:{description:"Default access of the published packages",type:ge.STRING,default:null}},commands:[Rge,Fge,Lge,Mge,Oge,Hge,Kge,Gge,jge]},a_e=o_e;var NM={};it(NM,{default:()=>B_e,patchUtils:()=>SM});var SM={};it(SM,{applyPatchFile:()=>PQ,diffFolders:()=>DM,extractPackageToDisk:()=>PM,extractPatchFlags:()=>Xge,isParentRequired:()=>kM,loadPatchFiles:()=>km,makeDescriptor:()=>I_e,makeLocator:()=>xM,parseDescriptor:()=>Sm,parseLocator:()=>xm,parsePatchFile:()=>kQ});var vm=class extends Error{constructor(e,r){super(`Cannot apply hunk #${e+1}`);this.hunk=r}};var A_e=/^@@ -(\d+)(,(\d+))? \+(\d+)(,(\d+))? @@.*/;function Nf(t){return v.relative(Se.root,v.resolve(Se.root,M.toPortablePath(t)))}function l_e(t){let e=t.trim().match(A_e);if(!e)throw new Error(`Bad header line: '${t}'`);return{original:{start:Math.max(Number(e[1]),1),length:Number(e[3]||1)},patched:{start:Math.max(Number(e[4]),1),length:Number(e[6]||1)}}}var c_e=420,u_e=493,Lr;(function(i){i.Context="context",i.Insertion="insertion",i.Deletion="deletion"})(Lr||(Lr={}));var Yge=()=>({semverExclusivity:null,diffLineFromPath:null,diffLineToPath:null,oldMode:null,newMode:null,deletedFileMode:null,newFileMode:null,renameFrom:null,renameTo:null,beforeHash:null,afterHash:null,fromPath:null,toPath:null,hunks:null}),g_e=t=>({header:l_e(t),parts:[]}),f_e={["@"]:"header",["-"]:Lr.Deletion,["+"]:Lr.Insertion,[" "]:Lr.Context,["\\"]:"pragma",undefined:Lr.Context};function p_e(t){let e=[],r=Yge(),i="parsing header",n=null,s=null;function o(){n&&(s&&(n.parts.push(s),s=null),r.hunks.push(n),n=null)}function a(){o(),e.push(r),r=Yge()}for(let l=0;l0?"patch":"mode change",B=null;switch(I){case"rename":{if(!u||!g)throw new Error("Bad parser state: rename from & to not given");e.push({type:"rename",semverExclusivity:i,fromPath:Nf(u),toPath:Nf(g)}),B=g}break;case"file deletion":{let b=n||p;if(!b)throw new Error("Bad parse state: no path given for file deletion");e.push({type:"file deletion",semverExclusivity:i,hunk:m&&m[0]||null,path:Nf(b),mode:xQ(l),hash:f})}break;case"file creation":{let b=s||d;if(!b)throw new Error("Bad parse state: no path given for file creation");e.push({type:"file creation",semverExclusivity:i,hunk:m&&m[0]||null,path:Nf(b),mode:xQ(c),hash:h})}break;case"patch":case"mode change":B=d||s;break;default:de.assertNever(I);break}B&&o&&a&&o!==a&&e.push({type:"mode change",semverExclusivity:i,path:Nf(B),oldMode:xQ(o),newMode:xQ(a)}),B&&m&&m.length&&e.push({type:"patch",semverExclusivity:i,path:Nf(B),hunks:m,beforeHash:f,afterHash:h})}if(e.length===0)throw new Error("Unable to parse patch file: No changes found. Make sure the patch is a valid UTF8 encoded string");return e}function xQ(t){let e=parseInt(t,8)&511;if(e!==c_e&&e!==u_e)throw new Error(`Unexpected file mode string: ${t}`);return e}function kQ(t){let e=t.split(/\n/g);return e[e.length-1]===""&&e.pop(),d_e(p_e(e))}function h_e(t){let e=0,r=0;for(let{type:i,lines:n}of t.parts)switch(i){case Lr.Context:r+=n.length,e+=n.length;break;case Lr.Deletion:e+=n.length;break;case Lr.Insertion:r+=n.length;break;default:de.assertNever(i);break}if(e!==t.header.original.length||r!==t.header.patched.length){let i=n=>n<0?n:`+${n}`;throw new Error(`hunk header integrity check failed (expected @@ ${i(t.header.original.length)} ${i(t.header.patched.length)} @@, got @@ ${i(e)} ${i(r)} @@)`)}}async function Lf(t,e,r){let i=await t.lstatPromise(e),n=await r();if(typeof n!="undefined"&&(e=n),t.lutimesPromise)await t.lutimesPromise(e,i.atime,i.mtime);else if(!i.isSymbolicLink())await t.utimesPromise(e,i.atime,i.mtime);else throw new Error("Cannot preserve the time values of a symlink")}async function PQ(t,{baseFs:e=new Wt,dryRun:r=!1,version:i=null}={}){for(let n of t)if(!(n.semverExclusivity!==null&&i!==null&&!qt.satisfiesWithPrereleases(i,n.semverExclusivity)))switch(n.type){case"file deletion":if(r){if(!e.existsSync(n.path))throw new Error(`Trying to delete a file that doesn't exist: ${n.path}`)}else await Lf(e,v.dirname(n.path),async()=>{await e.unlinkPromise(n.path)});break;case"rename":if(r){if(!e.existsSync(n.fromPath))throw new Error(`Trying to move a file that doesn't exist: ${n.fromPath}`)}else await Lf(e,v.dirname(n.fromPath),async()=>{await Lf(e,v.dirname(n.toPath),async()=>{await Lf(e,n.fromPath,async()=>(await e.movePromise(n.fromPath,n.toPath),n.toPath))})});break;case"file creation":if(r){if(e.existsSync(n.path))throw new Error(`Trying to create a file that already exists: ${n.path}`)}else{let s=n.hunk?n.hunk.parts[0].lines.join(` -`)+(n.hunk.parts[0].noNewlineAtEndOfFile?"":` -`):"";await e.mkdirpPromise(v.dirname(n.path),{chmod:493,utimes:[mr.SAFE_TIME,mr.SAFE_TIME]}),await e.writeFilePromise(n.path,s,{mode:n.mode}),await e.utimesPromise(n.path,mr.SAFE_TIME,mr.SAFE_TIME)}break;case"patch":await Lf(e,n.path,async()=>{await C_e(n,{baseFs:e,dryRun:r})});break;case"mode change":{let o=(await e.statPromise(n.path)).mode;if(qge(n.newMode)!==qge(o))continue;await Lf(e,n.path,async()=>{await e.chmodPromise(n.path,n.newMode)})}break;default:de.assertNever(n);break}}function qge(t){return(t&64)>0}function Jge(t){return t.replace(/\s+$/,"")}function m_e(t,e){return Jge(t)===Jge(e)}async function C_e({hunks:t,path:e},{baseFs:r,dryRun:i=!1}){let n=await r.statSync(e).mode,o=(await r.readFileSync(e,"utf8")).split(/\n/),a=[],l=0,c=0;for(let g of t){let f=Math.max(c,g.header.patched.start+l),h=Math.max(0,f-c),p=Math.max(0,o.length-f-g.header.original.length),d=Math.max(h,p),m=0,I=0,B=null;for(;m<=d;){if(m<=h&&(I=f-m,B=Wge(g,o,I),B!==null)){m=-m;break}if(m<=p&&(I=f+m,B=Wge(g,o,I),B!==null))break;m+=1}if(B===null)throw new vm(t.indexOf(g),g);a.push(B),l+=m,c=I+g.header.original.length}if(i)return;let u=0;for(let g of a)for(let f of g)switch(f.type){case"splice":{let h=f.index+u;o.splice(h,f.numToDelete,...f.linesToInsert),u+=f.linesToInsert.length-f.numToDelete}break;case"pop":o.pop();break;case"push":o.push(f.line);break;default:de.assertNever(f);break}await r.writeFilePromise(e,o.join(` -`),{mode:n})}function Wge(t,e,r){let i=[];for(let n of t.parts)switch(n.type){case Lr.Context:case Lr.Deletion:{for(let s of n.lines){let o=e[r];if(o==null||!m_e(o,s))return null;r+=1}n.type===Lr.Deletion&&(i.push({type:"splice",index:r-n.lines.length,numToDelete:n.lines.length,linesToInsert:[]}),n.noNewlineAtEndOfFile&&i.push({type:"push",line:""}))}break;case Lr.Insertion:i.push({type:"splice",index:r,numToDelete:0,linesToInsert:n.lines}),n.noNewlineAtEndOfFile&&i.push({type:"pop"});break;default:de.assertNever(n.type);break}return i}var E_e=/^builtin<([^>]+)>$/;function zge(t,e){let{source:r,selector:i,params:n}=S.parseRange(t);if(r===null)throw new Error("Patch locators must explicitly define their source");let s=i?i.split(/&/).map(c=>M.toPortablePath(c)):[],o=n&&typeof n.locator=="string"?S.parseLocator(n.locator):null,a=n&&typeof n.version=="string"?n.version:null,l=e(r);return{parentLocator:o,sourceItem:l,patchPaths:s,sourceVersion:a}}function Sm(t){let i=zge(t.range,S.parseDescriptor),{sourceItem:e}=i,r=qr(i,["sourceItem"]);return _(P({},r),{sourceDescriptor:e})}function xm(t){let i=zge(t.reference,S.parseLocator),{sourceItem:e}=i,r=qr(i,["sourceItem"]);return _(P({},r),{sourceLocator:e})}function Vge({parentLocator:t,sourceItem:e,patchPaths:r,sourceVersion:i,patchHash:n},s){let o=t!==null?{locator:S.stringifyLocator(t)}:{},a=typeof i!="undefined"?{version:i}:{},l=typeof n!="undefined"?{hash:n}:{};return S.makeRange({protocol:"patch:",source:s(e),selector:r.join("&"),params:P(P(P({},a),l),o)})}function I_e(t,{parentLocator:e,sourceDescriptor:r,patchPaths:i}){return S.makeLocator(t,Vge({parentLocator:e,sourceItem:r,patchPaths:i},S.stringifyDescriptor))}function xM(t,{parentLocator:e,sourcePackage:r,patchPaths:i,patchHash:n}){return S.makeLocator(t,Vge({parentLocator:e,sourceItem:r,sourceVersion:r.version,patchPaths:i,patchHash:n},S.stringifyLocator))}function _ge({onAbsolute:t,onRelative:e,onBuiltin:r},i){i.startsWith("~")&&(i=i.slice(1));let s=i.match(E_e);return s!==null?r(s[1]):v.isAbsolute(i)?t(i):e(i)}function Xge(t){let e=t.startsWith("~");return e&&(t=t.slice(1)),{optional:e}}function kM(t){return _ge({onAbsolute:()=>!1,onRelative:()=>!0,onBuiltin:()=>!1},t)}async function km(t,e,r){let i=t!==null?await r.fetcher.fetch(t,r):null,n=i&&i.localPath?{packageFs:new Ft(Se.root),prefixPath:v.relative(Se.root,i.localPath)}:i;i&&i!==n&&i.releaseFs&&i.releaseFs();let s=await de.releaseAfterUseAsync(async()=>await Promise.all(e.map(async o=>{let a=Xge(o),l=await _ge({onAbsolute:async()=>await T.readFilePromise(o,"utf8"),onRelative:async()=>{if(n===null)throw new Error("Assertion failed: The parent locator should have been fetched");return await n.packageFs.readFilePromise(v.join(n.prefixPath,o),"utf8")},onBuiltin:async c=>await r.project.configuration.firstHook(u=>u.getBuiltinPatch,r.project,c)},o);return _(P({},a),{source:l})})));for(let o of s)typeof o.source=="string"&&(o.source=o.source.replace(/\r\n?/g,` -`));return s}async function PM(t,{cache:e,project:r}){let i=r.storedPackages.get(t.locatorHash);if(typeof i=="undefined")throw new Error("Assertion failed: Expected the package to be registered");let n=r.storedChecksums,s=new ei,o=r.configuration.makeFetcher(),a=await o.fetch(t,{cache:e,project:r,fetcher:o,checksums:n,report:s}),l=await T.mktempPromise(),c=v.join(l,"source"),u=v.join(l,"user"),g=v.join(l,".yarn-patch.json");return await Promise.all([T.copyPromise(c,a.prefixPath,{baseFs:a.packageFs}),T.copyPromise(u,a.prefixPath,{baseFs:a.packageFs}),T.writeJsonPromise(g,{locator:S.stringifyLocator(t),version:i.version})]),T.detachTemp(l),u}async function DM(t,e){let r=M.fromPortablePath(t).replace(/\\/g,"/"),i=M.fromPortablePath(e).replace(/\\/g,"/"),{stdout:n,stderr:s}=await hr.execvp("git",["-c","core.safecrlf=false","diff","--src-prefix=a/","--dst-prefix=b/","--ignore-cr-at-eol","--full-index","--no-index","--text",r,i],{cwd:M.toPortablePath(process.cwd()),env:_(P({},process.env),{GIT_CONFIG_NOSYSTEM:"1",HOME:"",XDG_CONFIG_HOME:"",USERPROFILE:""})});if(s.length>0)throw new Error(`Unable to diff directories. Make sure you have a recent version of 'git' available in PATH. -The following error was reported by 'git': -${s}`);let o=r.startsWith("/")?a=>a.slice(1):a=>a;return n.replace(new RegExp(`(a|b)(${de.escapeRegExp(`/${o(r)}/`)})`,"g"),"$1/").replace(new RegExp(`(a|b)${de.escapeRegExp(`/${o(i)}/`)}`,"g"),"$1/").replace(new RegExp(de.escapeRegExp(`${r}/`),"g"),"").replace(new RegExp(de.escapeRegExp(`${i}/`),"g"),"")}function Zge(t,{configuration:e,report:r}){for(let i of t.parts)for(let n of i.lines)switch(i.type){case Lr.Context:r.reportInfo(null,` ${ue.pretty(e,n,"grey")}`);break;case Lr.Deletion:r.reportError(z.FROZEN_LOCKFILE_EXCEPTION,`- ${ue.pretty(e,n,ue.Type.REMOVED)}`);break;case Lr.Insertion:r.reportError(z.FROZEN_LOCKFILE_EXCEPTION,`+ ${ue.pretty(e,n,ue.Type.ADDED)}`);break;default:de.assertNever(i.type)}}var RM=class{supports(e,r){return!!e.reference.startsWith("patch:")}getLocalPath(e,r){return null}async fetch(e,r){let i=r.checksums.get(e.locatorHash)||null,[n,s,o]=await r.cache.fetchPackageFromCache(e,i,P({onHit:()=>r.report.reportCacheHit(e),onMiss:()=>r.report.reportCacheMiss(e,`${S.prettyLocator(r.project.configuration,e)} can't be found in the cache and will be fetched from the disk`),loader:()=>this.patchPackage(e,r),skipIntegrityCheck:r.skipIntegrityCheck},r.cacheOptions));return{packageFs:n,releaseFs:s,prefixPath:S.getIdentVendorPath(e),localPath:this.getLocalPath(e,r),checksum:o}}async patchPackage(e,r){let{parentLocator:i,sourceLocator:n,sourceVersion:s,patchPaths:o}=xm(e),a=await km(i,o,r),l=await T.mktempPromise(),c=v.join(l,"current.zip"),u=await r.fetcher.fetch(n,r),g=S.getIdentVendorPath(e),f=await $i(),h=new Jr(c,{libzip:f,create:!0,level:r.project.configuration.get("compressionLevel")});await de.releaseAfterUseAsync(async()=>{await h.copyPromise(g,u.prefixPath,{baseFs:u.packageFs,stableSort:!0})},u.releaseFs),h.saveAndClose();for(let{source:p,optional:d}of a){if(p===null)continue;let m=new Jr(c,{libzip:f,level:r.project.configuration.get("compressionLevel")}),I=new Ft(v.resolve(Se.root,g),{baseFs:m});try{await PQ(kQ(p),{baseFs:I,version:s})}catch(B){if(!(B instanceof vm))throw B;let b=r.project.configuration.get("enableInlineHunks"),R=!b&&!d?" (set enableInlineHunks for details)":"",H=`${S.prettyLocator(r.project.configuration,e)}: ${B.message}${R}`,L=K=>{!b||Zge(B.hunk,{configuration:r.project.configuration,report:K})};if(m.discardAndClose(),d){r.report.reportWarningOnce(z.PATCH_HUNK_FAILED,H,{reportExtra:L});continue}else throw new nt(z.PATCH_HUNK_FAILED,H,L)}m.saveAndClose()}return new Jr(c,{libzip:f,level:r.project.configuration.get("compressionLevel")})}};var y_e=3,FM=class{supportsDescriptor(e,r){return!!e.range.startsWith("patch:")}supportsLocator(e,r){return!!e.reference.startsWith("patch:")}shouldPersistResolution(e,r){return!1}bindDescriptor(e,r,i){let{patchPaths:n}=Sm(e);return n.every(s=>!kM(s))?e:S.bindDescriptor(e,{locator:S.stringifyLocator(r)})}getResolutionDependencies(e,r){let{sourceDescriptor:i}=Sm(e);return[i]}async getCandidates(e,r,i){if(!i.fetchOptions)throw new Error("Assertion failed: This resolver cannot be used unless a fetcher is configured");let{parentLocator:n,sourceDescriptor:s,patchPaths:o}=Sm(e),a=await km(n,o,i.fetchOptions),l=r.get(s.descriptorHash);if(typeof l=="undefined")throw new Error("Assertion failed: The dependency should have been resolved");let c=mn.makeHash(`${y_e}`,...a.map(u=>JSON.stringify(u))).slice(0,6);return[xM(e,{parentLocator:n,sourcePackage:l,patchPaths:o,patchHash:c})]}async getSatisfying(e,r,i){return null}async resolve(e,r){let{sourceLocator:i}=xm(e),n=await r.resolver.resolve(i,r);return P(P({},n),e)}};var Pm=class extends Be{constructor(){super(...arguments);this.save=Y.Boolean("-s,--save",!1,{description:"Add the patch to your resolution entries"});this.patchFolder=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState();let n=v.resolve(this.context.cwd,M.toPortablePath(this.patchFolder)),s=v.join(n,"../source"),o=v.join(n,"../.yarn-patch.json");if(!T.existsSync(s))throw new me("The argument folder didn't get created by 'yarn patch'");let a=await DM(s,n),l=await T.readJsonPromise(o),c=S.parseLocator(l.locator,!0);if(!r.storedPackages.has(c.locatorHash))throw new me("No package found in the project for the given locator");if(!this.save){this.context.stdout.write(a);return}let u=e.get("patchFolder"),g=v.join(u,S.slugifyLocator(c));await T.mkdirPromise(u,{recursive:!0}),await T.writeFilePromise(g,a);let f=v.relative(r.cwd,g);r.topLevelWorkspace.manifest.resolutions.push({pattern:{descriptor:{fullName:S.stringifyIdent(c),description:l.version}},reference:`patch:${S.stringifyLocator(c)}#${f}`}),await r.persist()}};Pm.paths=[["patch-commit"]],Pm.usage=ye.Usage({description:"generate a patch out of a directory",details:"\n This will print a patchfile on stdout based on the diff between the folder passed in and the original version of the package. Such file is suitable for consumption with the `patch:` protocol.\n\n Only folders generated by `yarn patch` are accepted as valid input for `yarn patch-commit`.\n "});var $ge=Pm;var Dm=class extends Be{constructor(){super(...arguments);this.json=Y.Boolean("--json",!1,{description:"Format the output as an NDJSON stream"});this.package=Y.String()}async execute(){let e=await fe.find(this.context.cwd,this.context.plugins),{project:r,workspace:i}=await Ke.find(e,this.context.cwd),n=await Qt.find(e);if(!i)throw new rt(r.cwd,this.context.cwd);await r.restoreInstallState();let s=S.parseLocator(this.package);if(s.reference==="unknown"){let o=de.mapAndFilter([...r.storedPackages.values()],a=>a.identHash!==s.identHash?de.mapAndFilter.skip:S.isVirtualLocator(a)?de.mapAndFilter.skip:a);if(o.length===0)throw new me("No package found in the project for the given locator");if(o.length>1)throw new me(`Multiple candidate packages found; explicitly choose one of them (use \`yarn why \` to get more information as to who depends on them): -${o.map(a=>` -- ${S.prettyLocator(e,a)}`).join("")}`);s=o[0]}if(!r.storedPackages.has(s.locatorHash))throw new me("No package found in the project for the given locator");await Fe.start({configuration:e,json:this.json,stdout:this.context.stdout},async o=>{let a=await PM(s,{cache:n,project:r});o.reportJson({locator:S.stringifyLocator(s),path:M.fromPortablePath(a)}),o.reportInfo(z.UNNAMED,`Package ${S.prettyLocator(e,s)} got extracted with success!`),o.reportInfo(z.UNNAMED,`You can now edit the following folder: ${ue.pretty(e,M.fromPortablePath(a),"magenta")}`),o.reportInfo(z.UNNAMED,`Once you are done run ${ue.pretty(e,`yarn patch-commit ${process.platform==="win32"?'"':""}${M.fromPortablePath(a)}${process.platform==="win32"?'"':""}`,"cyan")} and Yarn will store a patchfile based on your changes.`)})}};Dm.paths=[["patch"]],Dm.usage=ye.Usage({description:"prepare a package for patching",details:'\n This command will cause a package to be extracted in a temporary directory (under a folder named "patch-workdir"). This folder will be editable at will; running `yarn patch` inside it will then cause Yarn to generate a patchfile and register it into your top-level manifest (cf the `patch:` protocol).\n '});var efe=Dm;var w_e={configuration:{enableInlineHunks:{description:"If true, the installs will print unmatched patch hunks",type:ge.BOOLEAN,default:!1},patchFolder:{description:"Folder where the patch files must be written",type:ge.ABSOLUTE_PATH,default:"./.yarn/patches"}},commands:[$ge,efe],fetchers:[RM],resolvers:[FM]},B_e=w_e;var TM={};it(TM,{default:()=>S_e});var tfe=ie(Wp()),LM=class{supportsPackage(e,r){return r.project.configuration.get("nodeLinker")==="pnpm"}async findPackageLocation(e,r){return nfe(e,{project:r.project})}async findPackageLocator(e,r){let i=ife(),n=r.project.installersCustomData.get(i);if(!n)throw new me(`The project in ${ue.pretty(r.project.configuration,`${r.project.cwd}/package.json`,ue.Type.PATH)} doesn't seem to have been installed - running an install there might help`);let s=e.match(/(^.*\/node_modules\/(@[^/]*\/)?[^/]+)(\/.*$)/);if(s){let l=n.locatorByPath.get(s[1]);if(l)return l}let o=e,a=e;do{a=o,o=v.dirname(a);let l=n.locatorByPath.get(a);if(l)return l}while(o!==a);return null}makeInstaller(e){return new rfe(e)}},rfe=class{constructor(e){this.opts=e;this.asyncActions=new afe;this.packageLocations=new Map;this.customData={locatorByPath:new Map}}getCustomDataKey(){return ife()}attachCustomData(e){this.customData=e}async installPackage(e,r,i){switch(e.linkType){case gt.SOFT:return this.installPackageSoft(e,r,i);case gt.HARD:return this.installPackageHard(e,r,i)}throw new Error("Assertion failed: Unsupported package link type")}async installPackageSoft(e,r,i){let n=v.resolve(r.packageFs.getRealPath(),r.prefixPath);return this.packageLocations.set(e.locatorHash,n),{packageLocation:n,buildDirective:null}}async installPackageHard(e,r,i){var u;let n=nfe(e,{project:this.opts.project});this.customData.locatorByPath.set(n,S.stringifyLocator(e)),this.packageLocations.set(e.locatorHash,n),i.holdFetchResult(this.asyncActions.set(e.locatorHash,async()=>{await T.mkdirPromise(n,{recursive:!0}),await T.copyPromise(n,r.prefixPath,{baseFs:r.packageFs,overwrite:!1})}));let o=S.isVirtualLocator(e)?S.devirtualizeLocator(e):e,a={manifest:(u=await Ze.tryFind(r.prefixPath,{baseFs:r.packageFs}))!=null?u:new Ze,misc:{hasBindingGyp:Ws.hasBindingGyp(r)}},l=this.opts.project.getDependencyMeta(o,e.version),c=Ws.extractBuildScripts(e,a,l,{configuration:this.opts.project.configuration,report:this.opts.report});return{packageLocation:n,buildDirective:c}}async attachInternalDependencies(e,r){this.opts.project.configuration.get("nodeLinker")==="pnpm"&&(!ofe(e,{project:this.opts.project})||this.asyncActions.reduce(e.locatorHash,async i=>{await i;let n=this.packageLocations.get(e.locatorHash);if(typeof n=="undefined")throw new Error(`Assertion failed: Expected the package to have been registered (${S.stringifyLocator(e)})`);let s=v.join(n,wt.nodeModules);r.length>0&&await T.mkdirpPromise(s);let o=await Q_e(s),a=[];for(let[l,c]of r){let u=c;ofe(c,{project:this.opts.project})||(this.opts.report.reportWarning(z.UNNAMED,"The pnpm linker doesn't support providing different versions to workspaces' peer dependencies"),u=S.devirtualizeLocator(c));let g=this.packageLocations.get(u.locatorHash);if(typeof g=="undefined")throw new Error(`Assertion failed: Expected the package to have been registered (${S.stringifyLocator(c)})`);let f=S.stringifyIdent(l),h=v.join(s,f),p=v.relative(v.dirname(h),g),d=o.get(f);o.delete(f),a.push(Promise.resolve().then(async()=>{if(d){if(d.isSymbolicLink()&&await T.readlinkPromise(h)===p)return;await T.removePromise(h)}await T.mkdirpPromise(v.dirname(h)),process.platform=="win32"?await T.symlinkPromise(g,h,"junction"):await T.symlinkPromise(p,h)}))}for(let l of o.keys())a.push(T.removePromise(v.join(s,l)));await Promise.all(a)}))}async attachExternalDependents(e,r){throw new Error("External dependencies haven't been implemented for the pnpm linker")}async finalizeInstall(){let e=sfe(this.opts.project),r=new Set;for(let s of this.packageLocations.values())r.add(v.basename(s));let i;try{i=await T.readdirPromise(e)}catch{i=[]}let n=[];for(let s of i)r.has(s)||n.push(T.removePromise(v.join(e,s)));await Promise.all(n),await this.asyncActions.wait()}};function ife(){return JSON.stringify({name:"PnpmInstaller",version:1})}function sfe(t){return v.join(t.cwd,wt.nodeModules,".store")}function nfe(t,{project:e}){let r=S.slugifyLocator(t);return v.join(sfe(e),r)}function ofe(t,{project:e}){return!S.isVirtualLocator(t)||!e.tryWorkspaceByLocator(t)}async function Q_e(t){let e=new Map,r=[];try{r=await T.readdirPromise(t,{withFileTypes:!0})}catch(i){if(i.code!=="ENOENT")throw i}try{for(let i of r)if(!i.name.startsWith("."))if(i.name.startsWith("@"))for(let n of await T.readdirPromise(v.join(t,i.name),{withFileTypes:!0}))e.set(`${i.name}/${n.name}`,n);else e.set(i.name,i)}catch(i){if(i.code!=="ENOENT")throw i}return e}function b_e(){let t,e;return{promise:new Promise((i,n)=>{t=i,e=n}),resolve:t,reject:e}}var afe=class{constructor(){this.deferred=new Map;this.promises=new Map;this.limit=(0,tfe.default)(10)}set(e,r){let i=this.deferred.get(e);typeof i=="undefined"&&this.deferred.set(e,i=b_e());let n=this.limit(()=>r());return this.promises.set(e,n),n.then(()=>{this.promises.get(e)===n&&i.resolve()},s=>{this.promises.get(e)===n&&i.reject(s)}),i.promise}reduce(e,r){var n;let i=(n=this.promises.get(e))!=null?n:Promise.resolve();this.set(e,()=>r(i))}async wait(){await Promise.all(this.promises.values())}};var v_e={linkers:[LM]},S_e=v_e;var F0=()=>({modules:new Map([["@yarnpkg/cli",iC],["@yarnpkg/core",Fd],["@yarnpkg/fslib",ch],["@yarnpkg/libzip",Fp],["@yarnpkg/parsers",Hp],["@yarnpkg/shell",jp],["clipanion",F$(vh)],["semver",x_e],["typanion",lu],["yup",k_e],["@yarnpkg/plugin-essentials",hL],["@yarnpkg/plugin-compat",mL],["@yarnpkg/plugin-dlx",EL],["@yarnpkg/plugin-file",xL],["@yarnpkg/plugin-git",fL],["@yarnpkg/plugin-github",PL],["@yarnpkg/plugin-http",FL],["@yarnpkg/plugin-init",ML],["@yarnpkg/plugin-link",GL],["@yarnpkg/plugin-nm",mT],["@yarnpkg/plugin-npm",yM],["@yarnpkg/plugin-npm-cli",vM],["@yarnpkg/plugin-pack",CM],["@yarnpkg/plugin-patch",NM],["@yarnpkg/plugin-pnp",oT],["@yarnpkg/plugin-pnpm",TM]]),plugins:new Set(["@yarnpkg/plugin-essentials","@yarnpkg/plugin-compat","@yarnpkg/plugin-dlx","@yarnpkg/plugin-file","@yarnpkg/plugin-git","@yarnpkg/plugin-github","@yarnpkg/plugin-http","@yarnpkg/plugin-init","@yarnpkg/plugin-link","@yarnpkg/plugin-nm","@yarnpkg/plugin-npm","@yarnpkg/plugin-npm-cli","@yarnpkg/plugin-pack","@yarnpkg/plugin-patch","@yarnpkg/plugin-pnp","@yarnpkg/plugin-pnpm"])});i0({binaryVersion:Zr||"",pluginConfiguration:F0()});})(); -/*! - * buildToken - * Builds OAuth token prefix (helper function) - * - * @name buildToken - * @function - * @param {GitUrl} obj The parsed Git url object. - * @return {String} token prefix - */ -/*! - * fill-range - * - * Copyright (c) 2014-present, Jon Schlinkert. - * Licensed under the MIT License. - */ -/*! - * is-extglob - * - * Copyright (c) 2014-2016, Jon Schlinkert. - * Licensed under the MIT License. - */ -/*! - * is-glob - * - * Copyright (c) 2014-2017, Jon Schlinkert. - * Released under the MIT License. - */ -/*! - * is-number - * - * Copyright (c) 2014-present, Jon Schlinkert. - * Released under the MIT License. - */ -/*! - * is-windows - * - * Copyright © 2015-2018, Jon Schlinkert. - * Released under the MIT License. - */ -/*! - * to-regex-range - * - * Copyright (c) 2015-present, Jon Schlinkert. - * Released under the MIT License. - */ diff --git a/.yarnrc.yml b/.yarnrc.yml deleted file mode 100644 index 3b477710..00000000 --- a/.yarnrc.yml +++ /dev/null @@ -1,3 +0,0 @@ -nodeLinker: node-modules - -yarnPath: .yarn/releases/yarn-3.1.1.cjs diff --git a/README.md b/README.md index b8118cd0..0b1ad88a 100644 --- a/README.md +++ b/README.md @@ -1,1303 +1,207 @@ -# intercom-node +# Intercom TypeScript Library (intercom-client) -## Maintenance mode +[![fern shield](https://img.shields.io/badge/%F0%9F%8C%BF-Built%20with%20Fern-brightgreen)](https://buildwithfern.com?utm_source=github&utm_medium=github&utm_campaign=readme&utm_source=https%3A%2F%2Fgithub.com%2Fintercom%2Fintercom-node) +[![npm shield](https://img.shields.io/npm/v/intercom-client)](https://www.npmjs.com/package/intercom-client) -The Intercom Node SDK is currently in maintenance mode whilst we consider the best way to support it. We are not currently accepting new feature requests or actively working on the SDK. +The Intercom TypeScript library provides convenient access to the Intercom API from TypeScript. -[![Circle CI](https://circleci.com/gh/intercom/intercom-node.png?style=shield)](https://circleci.com/gh/intercom/intercom-node) [![npm](https://img.shields.io/npm/v/intercom-client)](https://www.npmjs.com/package/intercom-client) -![Intercom API Version](https://img.shields.io/badge/Intercom%20API%20Version-2.6-blue) +![Intercom API Version](https://img.shields.io/badge/Intercom%20API%20Version-2.11-blue) ![Typescript Supported](https://img.shields.io/badge/Typescript-Supported-lightgrey) -> Official Node bindings to the [Intercom API](https://api.intercom.io/docs) - ## Project Updates -## Breaking changes - -The Node SDK has been updated to support latest API version (2.6). The update also contains requested features, such like Typescript support. You can find more information on how-to migrate and what has changed in the [migration guide](https://github.com/intercom/intercom-node/wiki/Migration-guide). +The TypeScript SDK has been updated to support latest API version (2.11). ## Installation -```bash -yarn add intercom-client -``` - -**This client is intended for server side use only. Please use the [Intercom Javascript SDK](https://developers.intercom.com/installing-intercom/docs/intercom-for-web) for client-side operations.** - -## Usage - -Import Intercom: - -```typescript -import { Client } from 'intercom-client'; -``` - -Create a client using access tokens: - -```typescript -const client = new Client({ tokenAuth: { token: 'my_token' } }); -``` - -## Request Options - -This client library also supports passing in [`request` options](https://github.com/axios/axios#request-config): - -```typescript -const client = new Client({ tokenAuth: { token: 'my_token' } }); -client.useRequestOpts({ - baseURL: 'http://local.test-server.com', -}); -``` - -Note that certain request options (such as `json`, and certain `headers` names cannot be overriden). - -### Setting the API version - -We version our API (see the "Choose Version" section of the [API & Webhooks Reference](https://developers.intercom.com/intercom-api-reference/reference) for details). You can specify which version of the API to use when performing API requests using request options: - -```typescript -const client = new Client({ tokenAuth: { token: 'my_token' } }); -client.useRequestOpts({ - headers: { - 'Intercom-Version': 2.6, - }, -}); -``` - -### Setting the API base url - -If you are using the european instance of intercom and would like to call it directly and not be redirected through our US instance, you can set the `baseUrl` as follows: - -```typescript -const client = new Client({ tokenAuth: { token: 'my_token' } }); -client.useRequestOpts({ - baseURL: 'https://api.eu.intercom.io', -}); -``` - -## Examples - -### Admins - -#### [Retrieve admin](https://developers.intercom.com/intercom-api-reference/reference/view-an-admin) - -```typescript -const admin = await client.admins.find({ id: '123' }); -``` - -#### [Set Admin away](https://developers.intercom.com/intercom-api-reference/reference/set-admin-away-mode) - -```typescript -await client.admins.away({ - adminId: '123', - enableAwayMode: true, - enableReassignMode: false, -}); -``` - -#### [List all activity logs](https://developers.intercom.com/intercom-api-reference/reference/view-admin-activity-logs) - -```typescript -await client.admins.listAllActivityLogs({ - before: new Date('Fri, 17 Dec 2021 18:02:18 GMT');, - after: new Date('Fri, 17 Dec 2021 18:02:18 GMT');, -}); -``` - -#### [List all admins](https://developers.intercom.com/intercom-api-reference/reference/list-admins) - -```typescript -const admins = await client.admins.list(); -``` - -### Articles - -#### [Create an article](https://developers.intercom.com/intercom-api-reference/reference/create-an-article) - -```typescript -const article = await client.articles.create({ - title: 'Thanks for everything', - description: 'English description', - body: '

This is the body in html

', - authorId: 1, - state: 'published', - parentId: 1, - parentType: 'collection', - translatedContent: { - fr: { - title: 'Allez les verts', - description: 'French description', - body: '

French body in html

', - author_id: 1, - state: 'published', - }, - }, -}); -``` - -#### [Retrieve an article](https://developers.intercom.com/intercom-api-reference/reference/retrieve-an-article) - -```typescript -const response = await client.articles.find({ id: '123' }); -``` - -#### [Update an article](https://developers.intercom.com/intercom-api-reference/reference/update-an-article) - -```typescript -const article = await client.articles.update({ - id: '123', - title: 'Thanks for everything', - description: 'English description', - body: '

This is the body in html

', - authorId: 1, - state: 'published', - parentId: 1, - parentType: 'collection', - translatedContent: { - fr: { - title: 'Allez les verts', - description: 'French description', - body: '

French body in html

', - author_id: 1, - state: 'published', - }, - }, -}); -``` - -#### [Delete an article](https://developers.intercom.com/intercom-api-reference/reference/delete-an-article) - -```typescript -await client.articles.delete({ id: '123' }); -``` - -#### [List all articles](https://developers.intercom.com/intercom-api-reference/reference/list-all-articles) - -```typescript -const response = await client.articles.list({ - page: 3, - perPage: 12, -}); -``` - -### Companies - -#### [Create a company](https://developers.intercom.com/intercom-api-reference/reference/create-or-update-company) - -```typescript -const company = await client.companies.create({ - createdAt: dateToUnixTimestamp(new Date()), - companyId: '46029', - name: 'BestCompanyInc.', - monthlySpend: 9001, - plan: '1. Get pizzaid', - size: 62049, - website: 'http://the-best.one', - industry: 'The Best One', - customAttributes: {}, -}); -``` - -#### [Update a company](https://developers.intercom.com/intercom-api-reference/reference/update-a-company) - -```typescript -const company = await client.companies.update({ - createdAt: dateToUnixTimestamp(new Date()), - companyId: '46029', - name: 'BestCompanyInc.', - monthlySpend: 9001, - plan: '1. Get pizzaid', - size: 62049, - website: 'http://the-best.one', - industry: 'The Best One', - customAttributes: {}, -}); -``` - -#### [Retrieve a company](https://developers.intercom.com/intercom-api-reference/reference/view-a-company) - -##### By id - -```typescript -const company = await client.companies.find({ - companyId: 123, -}); -``` - -##### By name - -```typescript -const company = await client.companies.find({ - name: 'bruh moment inc.', -}); -``` - -#### [Delete a company](https://developers.intercom.com/intercom-api-reference/reference/delete-a-company) - -```typescript -const company = await client.companies.delete({ - id: 62049, -}); -``` - -#### [List all companies](https://developers.intercom.com/intercom-api-reference/reference/list-companies) - -##### With pagination - -```typescript -const companies = await client.companies.list({ - page: 1, - perPage: 35, - order: Order.DESC, -}); -``` - -##### With TagId and SegmentId - -```typescript -const companies = await client.companies.list({ - tagId: '1234', - segmentId: '4567', -}); -``` - -#### [Scroll over companies](https://developers.intercom.com/intercom-api-reference/reference/iterating-over-all-companies) - -##### Using infinite scroll - -```typescript -const companies = await client.companies.scroll.each({}); -``` - -##### Using manual scroll - -```typescript -const companies = await client.companies.scroll.next({ - scrollParam: '123_soleil', -}); -``` - -#### [Attach a contact](https://developers.intercom.com/intercom-api-reference/reference/attach-contact-to-company) - -```typescript -const response = await client.companies.attachContact({ - contactId: '123', - companyId: '234', -}); -``` - -#### [Detach a contact](https://developers.intercom.com/intercom-api-reference/reference/detach-contact-from-company) - -```typescript -const response = await client.companies.detachContact({ - contactId: '123', - companyId: '234', -}); -``` - -#### [List attached contacts](https://developers.intercom.com/intercom-api-reference/reference/list-company-contacts) - -```typescript -const response = await client.companies.listAttachedContacts({ - companyId: '123', - page: 1, - perPage: 15, -}); -``` - -#### [List attached segments](https://developers.intercom.com/intercom-api-reference/reference/list-attached-segments-1) - -```typescript -const response = await client.companies.listAttachedSegments({ - companyId: '123', -}); -``` - -### Contacts - -#### [Create Contact](https://developers.intercom.com/intercom-api-reference/reference/create-contact) - -##### With User Role - -```typescript -const user = await client.contacts.createUser({ - externalId: '536e564f316c83104c000020', - phone: '+48370044567', - name: 'Niko Bellic', - avatar: 'https://nico-from-gta-iv.com/lets_go_bowling.jpg', - signedUpAt: 1638203719, - lastSeenAt: 1638203720, - ownerId: '536e564f316c83104c000021', - isUnsubscribedFromEmails: true, -}); -``` - -##### With Lead Role - -```typescript -const lead = await client.contacts.createLead({ - phone: '+48370044567', - name: 'Roman Bellic', - avatar: 'https://nico-from-gta-iv.com/lets_go_bowling_yey.jpg', - signedUpAt: 1638203719, - lastSeenAt: 1638203720, - ownerId: '536e564f316c83104c000021', - isUnsubscribedFromEmails: true, -}); -``` - -#### [Retrieve a Contact](https://developers.intercom.com/intercom-api-reference/reference/get-contact) - -```typescript -const response = await client.contacts.find({ id: '123' }); -``` - -#### [Update a Contact](https://developers.intercom.com/intercom-api-reference/reference/update-contact) - -```typescript -const response = await client.contacts.update({ - id: '123', - role: Role.USER, - name: 'Roman The Bowling Fan', - customAttributes: { - callBrother: "Hey Niko, it's me – Roman. Let's go bowling!", - }, -}); -``` - -#### [Delete a Contact](https://developers.intercom.com/intercom-api-reference/reference/delete-contact) - -```typescript -const response = await client.contacts.delete({ id: '123' }); -``` - -#### [Archive a Contact](https://developers.intercom.com/intercom-api-reference/reference/archive-a-contact) - -```typescript -const response = await client.contacts.archive({ id: '123' }); +```sh +npm i -s intercom-client ``` -#### [Unarchive a Contact](https://developers.intercom.com/intercom-api-reference/reference/unarchive-a-contact) - -```typescript -const response = await client.contacts.unarchive({ id: '123' }); -``` +## Reference -#### [Merge two Contacts](https://developers.intercom.com/intercom-api-reference/reference/merge-contact) +A full reference for this library is available [here](./reference.md). -```typescript -const response = await client.contacts.mergeLeadInUser({ - leadId: '123', - userId: '234', -}); -``` +## Usage -#### [Search for contacts](https://developers.intercom.com/intercom-api-reference/reference/search-for-contacts) +Instantiate and use the client with the following: ```typescript -const response = await client.contacts.search({ - data: { - query: { - operator: Operators.AND, - value: [ - { - operator: Operators.AND, - value: [ - { - field: 'updated_at', - operator: Operators.GREATER_THAN, - value: 1560436650, - }, - { - field: 'conversation_rating.rating', - operator: Operators.EQUALS, - value: 1, - }, - ], - }, - { - operator: Operators.OR, - value: [ - { - field: 'updated_at', - operator: Operators.GREATER_THAN, - value: 1560436650, - }, - { - field: 'conversation_rating.rating', - operator: Operators.EQUALS, - value: 2, - }, - ], - }, - ], - }, - pagination: { - per_page: 5, - starting_after: - 'WzE2MzU4NjA2NDgwMDAsIjYxODJiNjJlNDM4YjdhM2EwMWE4YWYxNSIsMl0=', - }, - sort: { field: 'name', order: SearchContactOrderBy.ASC }, - }, -}); -``` - -#### [List all Contacts](https://developers.intercom.com/intercom-api-reference/reference/list-contacts) +import { IntercomClient } from "intercom-client"; -##### With cursor - -```typescript -const response = await client.contacts.list({ - perPage: 5, - startingAfter: - 'WzE2MzU3NzU4NjkwMDAsIjYxODJiNjJhMDMwZTk4OTBkZWU4NGM5YiIsMl0=', +const client = new IntercomClient({ token: "YOUR_TOKEN" }); +await client.articles.create({ + title: "How to create an account", + description: "Example article about creating an account.", + body: "Here are the steps to create an account.", + author_id: 1295, + state: "published", }); ``` -##### Without a cursor - -```typescript -const response = await client.contacts.list(); -``` +## Request And Response Types -#### [List attached companies](https://developers.intercom.com/intercom-api-reference/reference/list-companies-of-contact) +The SDK exports all request and response types as TypeScript interfaces. Simply import them with the +following namespace: ```typescript -const response = await client.contacts.listAttachedCompanies({ - id: '123', - perPage: 5, - page: 1, -}); -``` - -#### [List attached tags](https://developers.intercom.com/intercom-api-reference/reference/list-tags-of-contact) +import { Intercom } from "intercom-client"; -```typescript -const response = await client.contacts.listAttachedTags({ id: '123' }); +const request: Intercom.ConfigureAwayAdminRequest = { + ... +}; ``` -#### [List attached segments](https://developers.intercom.com/intercom-api-reference/reference/list-attached-segments) - -```typescript -const response = await client.contacts.listAttachedSegments({ id: '123' }); -``` +## Exception Handling -#### [List attached email subscriptions](https://developers.intercom.com/intercom-api-reference/reference/list-attached-email-subscriptions) +When the API returns a non-success status code (4xx or 5xx response), a subclass of the following error +will be thrown. ```typescript -const response = await client.contacts.listAttachedEmailSubscriptions({ - id: '123', -}); -``` - -### Conversations - -#### [Create a conversation](https://developers.intercom.com/intercom-api-reference/reference/create-a-conversation) +import { IntercomError } from "intercom-client"; -```typescript -const response = await client.conversations.create({ - userId: '123', - body: 'Hello darkness my old friend', -}); +try { + await client.articles.create(...); +} catch (err) { + if (err instanceof IntercomError) { + console.log(err.statusCode); + console.log(err.message); + console.log(err.body); + } +} ``` -#### [Retrieve a conversation](https://developers.intercom.com/intercom-api-reference/reference/retrieve-a-conversation) +## Request Options -##### Formatted text +This client library also supports passing in [`request` options](https://github.com/axios/axios#request-config): ```typescript -const response = await client.conversations.find({ - id: '123', +client.useRequestOpts({ + baseURL: "http://local.test-server.com", }); ``` -##### As plain text +Note that certain request options (such as `json`, and certain `headers` names cannot be overriden). -```typescript -const response = await client.conversations.find({ - id: '123', - inPlainText: true, -}); -``` +### Setting the API base url -#### [Update a conversation](https://developers.intercom.com/intercom-api-reference/reference/update-a-conversation) +If you are using the european instance of intercom and would like to call it directly and not be redirected through our US instance, you can set the `baseUrl` as follows: ```typescript -const response = await client.conversations.update({ - id, - markRead: true, - customAttributes: { - anything: 'you want', - }, +client.useRequestOpts({ + baseURL: "https://api.eu.intercom.io", }); ``` -#### [Reply to a conversation](https://developers.intercom.com/intercom-api-reference/reference/reply-to-a-conversation) +## Pagination -##### By id - -###### As user +List endpoints are paginated. The SDK provides an iterator so that you can simply loop over the items: ```typescript -const response = await client.conversations.replyByIdAsUser({ - id: '098', - body: 'blablbalba', - intercomUserId: '123', - attachmentUrls: '345', -}); -``` +import { IntercomClient } from "intercom-client"; -###### As admin +const client = new IntercomClient({ token: "YOUR_TOKEN" }); +const response = await client.articles.list(); +for await (const item of response) { + console.log(item); +} -```typescript -const response = await client.conversations.replyByIdAsAdmin({ - id: '098', - adminId: '458', - messageType: ReplyToConversationMessageType.NOTE, - body: 'Bee C', - attachmentUrls: ['https://site.org/bebra.jpg'], -}); +// Or you can manually iterate page-by-page +const page = await client.articles.list(); +while (page.hasNextPage()) { + page = page.getNextPage(); +} ``` -##### By last conversation - -###### As user +## Advanced -```typescript -const response = await client.conversations.replyByLastAsUser({ - body: 'blablbalba', - intercomUserId: '123', - attachmentUrls: '345', -}); -``` +### Additional Headers -###### As admin +If you would like to send additional headers as part of the request, use the `headers` request option. ```typescript -const response = await client.conversations.replyByLastAsAdmin({ - adminId: '458', - messageType: ReplyToConversationMessageType.NOTE, - body: 'Bee C', - attachmentUrls: ['https://site.org/bebra.jpg'], +const response = await client.articles.create(..., { + headers: { + 'X-Custom-Header': 'custom value' + } }); ``` -#### [Assign a conversation](https://developers.intercom.com/intercom-api-reference/reference/assign-a-conversation) +### Retries -##### As team without assignment rules - -```typescript -const response = await client.conversations.assign({ - id: '123', - type: AssignToConversationUserType.TEAM, - adminId: '456', - assigneeId: '789', - body: 'blablbalba', -}); -``` +The SDK is instrumented with automatic retries with exponential backoff. A request will be retried as long +as the request is deemed retriable and the number of retry attempts has not grown larger than the configured +retry limit (default: 2). -##### As team with assignment rules +A request is deemed retriable when any of the following HTTP status codes is returned: -```typescript -const response = await client.conversations.assign({ - id: '123', - withRunningAssignmentRules: true, -}); -``` +- [408](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/408) (Timeout) +- [429](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/429) (Too Many Requests) +- [5XX](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/500) (Internal Server Errors) -#### [Snooze a conversation](https://developers.intercom.com/intercom-api-reference/reference/snooze-a-conversation) +Use the `maxRetries` request option to configure this behavior. ```typescript -const response = await client.conversations.snooze({ - id: '123', - adminId: '234', - snoozedUntil: '1501512795', +const response = await client.articles.create(..., { + maxRetries: 0 // override maxRetries at the request level }); ``` -#### [Close a conversation](https://developers.intercom.com/intercom-api-reference/reference/close-a-conversation) - -```typescript -const response = await client.conversations.close({ - id: '123', - adminId: '456', - body: "That's it...", -}); -``` +### Timeouts -#### [Open a conversation](https://developers.intercom.com/intercom-api-reference/reference/open-a-conversation) +The SDK defaults to a 60 second timeout. Use the `timeoutInSeconds` option to configure this behavior. ```typescript -const response = await client.conversations.open({ - id: '123', - adminId: '234', +const response = await client.articles.create(..., { + timeoutInSeconds: 30 // override timeout to 30s }); ``` -#### [Attach a contact to group conversation](https://developers.intercom.com/intercom-api-reference/reference/adding-to-group-conversations-as-admin) - -##### As admin, using intercomUserid - -```typescript -const response = await client.conversations.attachContactAsAdmin({ - id: '123', - adminId: '234', - customer: { - intercomUserId: '456', - }, -}); -``` +### Aborting Requests -##### As contact, using intercomUserid +The SDK allows users to abort requests at any point by passing in an abort signal. ```typescript -const response = await client.conversations.attachContactAsAdmin({ - id: '123', - userId: '234', - customer: { - intercomUserId: '456', - }, +const controller = new AbortController(); +const response = await client.articles.create(..., { + abortSignal: controller.signal }); +controller.abort(); // aborts the request ``` -#### [Delete a contact from group conversation as admin](https://developers.intercom.com/intercom-api-reference/reference/deleting-from-group-conversations) +### Runtime Compatibility -```typescript -const response = await client.conversations.detachContactAsAdmin({ - conversationId: '123', - contactId: '456', - adminId: '789', -}); -``` +The SDK defaults to `node-fetch` but will use the global fetch client if present. The SDK works in the following +runtimes: -#### [Search for conversations](https://developers.intercom.com/intercom-api-reference/reference/search-for-conversations) +- Node.js 18+ +- Vercel +- Cloudflare Workers +- Deno v1.25+ +- Bun 1.0+ +- React Native -```typescript -const response = await client.conversations.search({ - data: { - query: { - operator: Operators.AND, - value: [ - { - operator: Operators.AND, - value: [ - { - field: 'updated_at', - operator: Operators.GREATER_THAN, - value: 1560436650, - }, - { - field: 'conversation_rating.rating', - operator: Operators.EQUALS, - value: 1, - }, - ], - }, - { - operator: Operators.OR, - value: [ - { - field: 'updated_at', - operator: Operators.GREATER_THAN, - value: 1560436650, - }, - { - field: 'conversation_rating.rating', - operator: Operators.EQUALS, - value: 2, - }, - ], - }, - ], - }, - pagination: { - per_page: 5, - starting_after: - 'WzE2MzU4NjA2NDgwMDAsIjYxODJiNjJlNDM4YjdhM2EwMWE4YWYxNSIsMl0=', - }, - sort: { - field: 'name', - order: SearchConversationOrderBy.DESC, - }, - }, -}); -``` +### Customizing Fetch Client -#### [List all conversations](https://developers.intercom.com/intercom-api-reference/reference/list-conversations) +The SDK provides a way for your to customize the underlying HTTP client / Fetch function. If you're running in an +unsupported environment, this provides a way for you to break glass and ensure the SDK works. ```typescript -const response = await client.conversations.list({ - startingAfter: 'WzE2NzA0MjI1MjkwMDAsMjQzMTY3NzA2ODcsMl0=', - perPage: 10, -}); -``` +import { IntercomClient } from "intercom-client"; -#### [Redact a conversation](https://developers.intercom.com/intercom-api-reference/reference/redact-a-conversation-part) - -```typescript -const response = await client.conversations.redactConversationPart({ - type: RedactConversationPartType.CONVERSATION_PART, - conversationId: '123', - conversationPartId: '456', +const client = new IntercomClient({ + ... + fetcher: // provide your implementation here }); ``` -### Counts - -#### [App Total Count](https://developers.intercom.com/intercom-api-reference/reference/company-user-counts) - -```typescript -const response = await client.counts.forApp(); -``` - -#### [Conversation Count Model](https://developers.intercom.com/intercom-api-reference/reference/conversation-counts) - -```typescript -const response = await client.counts.countConversation(); -``` - -#### [Admin Conversation Count Model](https://developers.intercom.com/intercom-api-reference/reference/admin-conversations) - -```typescript -const response = await client.counts.countAdminConversation(); -``` - -#### [User Segment/Tag Count Model](https://developers.intercom.com/intercom-api-reference/reference/user-tag-counts) - -##### Count User Segment - -```typescript -const response = await client.counts.countUserSegment(); -``` - -##### Count User Tag - -```typescript -const response = await client.counts.countUserTag(); -``` - -#### [Company User/Segment/Tag Count Model](https://developers.intercom.com/intercom-api-reference/reference/company-tag-counts) - -##### Count Company Segment - -```typescript -const response = await client.counts.countCompanySegment(); -const response = await client.counts.countCompanyTag(); -const response = await client.counts.countCompanyUser(); -``` - -##### Count Company Tag - -```typescript -const response = await client.counts.countCompanyTag(); -``` - -##### Count Company User - -```typescript -const response = await client.counts.countCompanyUser(); -``` - -### Data Attributes - -#### [Create Data Attribute](https://developers.intercom.com/intercom-api-reference/reference/create-data-attributes) - -```typescript -const response = await client.dataAttributes.create({ - name: 'list_cda', - model: ModelType.CONTACT, - dataType: DataType.STRING, - description: 'You are either alive or dead', - options: [{ value: 'alive' }, { value: 'dead' }], -}); -``` - -#### [Update Data Attribute](https://developers.intercom.com/intercom-api-reference/reference/update-data-attributes) - -```typescript -const response = await client.dataAttributes.update({ - id: '123', - description: 'You are either alive or dead', - options: [{ value: 'alive' }, { value: 'dead' }], - archived: true, -}); -``` - -#### [List all Data Attributes](https://developers.intercom.com/intercom-api-reference/reference/list-data-attributes) - -```typescript -const response = await client.dataAttributes.list({ - model: ModelType.CONTACT, - includeArchived: true, -}); -``` - -### Data Exports - -#### [Create a export job](https://developers.intercom.com/intercom-api-reference/reference/creating-an-export-job) - -```typescript -const response = await client.dataExport.create({ - createdAtAfter: 1527811200, - createdAtBefore: 1530316800, -}); -``` - -#### [Retrieve a job status](https://developers.intercom.com/intercom-api-reference/reference/retrieve-a-job-status) - -```typescript -const response = await client.dataExport.find({id: export.id}) -``` - -#### [Cancel a job](https://developers.intercom.com/intercom-api-reference/reference/the-export-job-model) - -```typescript -const response = await client.dataExport.cancel({id: export.id}) -``` - -### Events - -#### [Submit a data event](https://developers.intercom.com/intercom-api-reference/reference/list-data-attributes) - -```typescript -const response = await client.events.create({ - eventName: 'placed-order', - createdAt: 1389913941, - userId: 'f4ca124298', - metadata: { - order_date: 1392036272, - stripe_invoice: 'inv_3434343434', - order_number: { - value: '3434-3434', - url: 'https://example.org/orders/3434-3434', - }, - price: { - currency: 'usd', - amount: 2999, - }, - }, -}); -``` - -#### [List all data events](https://developers.intercom.com/intercom-api-reference/reference/list-user-events) - -```typescript -const response = await client.events.listBy({ - userId: '1234', - perPage: 2, - summary: true, - email: 'i_love_memes@gmail.com', -}); -``` - -### Help Center - Collections - -#### [Create a collection](https://developers.intercom.com/intercom-api-reference/reference/create-a-collection) - -```typescript -const collection = await client.helpCenter.collections.create({ - name: 'Thanks for everything', - description: 'English description', - translatedContent: { - fr: { - name: 'Allez les verts', - description: 'French description', - }, - }, -}); -``` - -#### [Retrieve a collection](https://developers.intercom.com/intercom-api-reference/reference/retrieve-a-collection) - -```typescript -const response = await client.helpCenter.collections.find({ id: '123' }); -``` - -#### [Update a collection](https://developers.intercom.com/intercom-api-reference/reference/update-a-collection) - -```typescript -const article = await client.helpCenter.collections.update({ - id: '123', - name: 'Thanks for everything', - description: 'English description', - translatedContent: { - fr: { - name: 'Allez les verts', - description: 'French description', - }, - }, -}); -``` - -#### [Delete a collection](https://developers.intercom.com/intercom-api-reference/reference/delete-a-collection) - -```typescript -await client.helpCenter.collections.delete({ - id: '123', -}); -``` - -#### [List all collections](https://developers.intercom.com/intercom-api-reference/reference/list-all-collections) - -```typescript -const response = client.helpCenter.collections.list({ - page: 3, - perPage: 12, -}); -``` - -## Help Center - Sections - -#### [Create a section](https://developers.intercom.com/intercom-api-reference/reference/create-a-section) - -```typescript -const collection = await client.helpCenter.sections.create({ - name: 'Thanks for everything', - parentId: '1234', - translatedContent: { - fr: { - name: 'Allez les verts', - description: 'French description', - }, - }, -}); -``` - -#### [Retrieve a section](https://developers.intercom.com/intercom-api-reference/reference/retrieve-a-section) - -```typescript -const response = await client.helpCenter.sections.find({ id: '123' }); -``` - -#### [Update a section](https://developers.intercom.com/intercom-api-reference/reference/update-a-section) - -```typescript -const article = await client.helpCenter.sections.update({ - id: '123', - name: 'Thanks for everything', - parentId: '456', - translatedContent: { - fr: { - name: 'Allez les verts', - description: 'French description', - }, - }, -}); -``` - -#### [Delete a section](https://developers.intercom.com/intercom-api-reference/reference/delete-a-section) - -```typescript -await client.helpCenter.sections.delete({ - id: '123', -}); -``` - -#### [List all sections](https://developers.intercom.com/intercom-api-reference/reference/list-all-sections) - -```typescript -const response = client.helpCenter.sections.list({ - page: 3, - perPage: 12, -}); -``` - -### Messages - -#### [Create a message](https://developers.intercom.com/intercom-api-reference/reference/admin-initiated-conversation) - -```typescript -const response = await client.messages.create({ - messageType: 'email', - subject: 'This is our demand now', - body: 'Destroy ponies', - template: 'plain', - from: { - type: 'admin', - id: '394051', - }, - to: { - type: 'user', - id: '536e564f316c83104c000020', - }, -}); -``` - -#### [Create conversation without contact reply](https://developers.intercom.com/intercom-api-reference/reference/admin-initiated-conversation) - -```typescript -const response = await client.messages.create({ - messageType: 'inapp', - body: 'Look at me, I am a conversation now', - from: { - type: 'admin', - id: '394051', - }, - to: { - type: 'user', - id: '536e564f316c83104c000020', - }, - createConversationWithoutContactReply: true, -}); -``` - -### Notes - -#### [Create a note](https://developers.intercom.com/intercom-api-reference/reference/create-note-for-contact) - -```typescript -const response = await client.notes.create({ - adminId: '12345', - body: 'Shiny', - contactId: '5678', -}); -``` - -#### [Retrieve a note](https://developers.intercom.com/intercom-api-reference/reference/view-a-note) - -```typescript -const response = await client.notes.find({ id: '123' }); -``` - -#### [List all notes](https://developers.intercom.com/intercom-api-reference/reference/list-notes-of-contact) - -```typescript -const response = await client.notes.list({ - contactId: '123', - page: 2, - perPage: 3, -}); -``` - -### Segments - -#### [Retrieve a segment](https://developers.intercom.com/intercom-api-reference/reference/view-a-segment) - -```typescript -const response = await client.segments.find({ - id: '123', - includeCount: true, -}); -``` - -#### [List all segments](https://developers.intercom.com/intercom-api-reference/reference/list-segments) - -```typescript -const response = await client.segments.list({ - includeCount: true, -}); -``` - -### Subscriptions - -#### [List all subscription types](https://developers.intercom.com/intercom-api-reference/reference/list-all-subscription-types) - -```typescript -const response = await client.subscriptions.listTypes(); -``` - -### PhoneCallRedirects - -#### [Create a phone call redirect](https://developers.intercom.com/intercom-api-reference/reference/create-a-phone-switch) - -```typescript -const response = await client.phoneCallRedirect.create({ - phone: '+353871234567', -}); -``` - -### Tags - -#### [Create or update a tag](https://developers.intercom.com/intercom-api-reference/reference/create-and-update-tags) - -##### Create - -```typescript -const response = await client.tags.create({ name: 'haven' }); -``` - -##### Update - -```typescript -const response = await client.tags.update({ id: '123', name: 'haven' }); -``` - -#### [Delete a tag](https://developers.intercom.com/intercom-api-reference/reference/delete-a-tag) - -```typescript -const response = await client.tags.delete({ id: 'baz' }); -``` - -#### [Attach a contact](https://developers.intercom.com/intercom-api-reference/reference/tag-contact) - -```typescript -const response = await client.tags.tagContact({ - contactId: '123', - tagId: '234', -}); -``` - -#### [Attach a conversation](https://developers.intercom.com/intercom-api-reference/reference/attach-a-tag-to-a-conversation) - -```typescript -const response = await client.tags.tagConversation({ - conversationId: '123', - tagId: '456', - adminId: '789', -}); -``` - -#### [Tag companies](https://developers.intercom.com/intercom-api-reference/reference/tag-companies) - -```typescript -const response = await client.tags.tagCompanies({ - tagName: 'gutenTag', - companiesIds: ['123', '234', '456'], -}); -``` - -#### [Untag companies](https://developers.intercom.com/intercom-api-reference/reference/untag-companies) - -```typescript -const response = await client.tags.untagCompanies({ - tagName: 'gutenTag', - companiesIds: ['123', '234', '456'], -}); -``` - -#### [Untag conversation](https://developers.intercom.com/intercom-api-reference/reference/detach-a-tag-from-a-conversation) - -```typescript -const response = await client.tags.untagConversation({ - conversationId: '123', - tagId: '345', - adminId: '678', -}); -``` - -#### [Untag contact](https://developers.intercom.com/intercom-api-reference/reference/untag-contact) - -```typescript -const response = await client.tags.untagContact({ - contactId: '123', - tagId: '345', -}); -``` - -#### [List all tags](https://developers.intercom.com/intercom-api-reference/reference/list-tags-for-an-app) - -```typescript -const response = await client.tags.list(); -``` - -### Teams - -#### [Retrieve a team](https://developers.intercom.com/intercom-api-reference/reference/view-a-team) - -```typescript -const response = await client.teams.find({ - id: '123', -}); -``` - -#### [List all teams](https://developers.intercom.com/intercom-api-reference/reference/list-teams) - -```typescript -const response = await client.teams.list(); -``` - -### Visitors - -#### [Retrieve a Visitor](https://developers.intercom.com/intercom-api-reference/reference/view-a-visitor) - -```typescript -const response = await client.visitors.find({ id: '123' }); -``` - -OR - -```typescript -const response = await client.visitors.find({ userId: '123' }); -``` - -#### [Update a Visitor](https://developers.intercom.com/intercom-api-reference/reference/update-a-visitor) - -```typescript -const response = await client.visitors.update({ - userId: '123', - name: 'anonymous bruh', - customAttributes: { - paid_subscriber: true, - }, -}); -``` - -#### [Delete a Visitor](https://developers.intercom.com/intercom-api-reference/reference/delete-a-visitor) - -```typescript -const response = await client.visitors.delete({ - id, -}); -``` - -#### [Convert a Visitor](https://developers.intercom.com/intercom-api-reference/reference/convert-a-visitor-to-a-user) - -```typescript -const response = await client.visitors.mergeToContact({ - visitor: { - id: '123', - }, - user: { - userId: '123', - }, - type: Role.USER, -}); -``` - -### Identity verification - -`intercom-node` provides a helper for using [identity verification](https://docs.intercom.com/configure-intercom-for-your-product-or-site/staying-secure/enable-identity-verification-on-your-web-product): - -```node -import { IdentityVerification } from 'intercom-client'; - -IdentityVerification.userHash({ - secretKey: 's3cre7', - identifier: 'jayne@serenity.io', -}); -``` - -## License - -Apache-2.0 - -## Testing - -```bash -yarn test -``` - -## Running the code locally - -Compile using babel: - -```bash -yarn prepublish -``` - -## Pull Requests - -- **Add tests!** Your patch won't be accepted if it doesn't have tests. - -- **Document any change in behaviour**. Make sure the README and any other - relevant documentation are kept up-to-date. - -- **Create topic branches**. Don't ask us to pull from your master branch. +## Contributing -- **One pull request per feature**. If you want to do more than one thing, send - multiple pull requests. +While we value open-source contributions to this SDK, this library is generated programmatically. +Additions made directly to this library would have to be moved over to our generation code, +otherwise they would be overwritten upon the next generated release. Feel free to open a PR as +a proof of concept, but know that we will not be able to merge it as-is. We suggest opening +an issue first to discuss with us! -- **Send coherent history**. Make sure each individual commit in your pull - request is meaningful. If you had to make multiple intermediate commits while - developing, please squash them before sending them to us. +On the other hand, contributions to the README are always very welcome! diff --git a/jest.config.js b/jest.config.js new file mode 100644 index 00000000..35d6e65b --- /dev/null +++ b/jest.config.js @@ -0,0 +1,5 @@ +/** @type {import('jest').Config} */ +module.exports = { + preset: "ts-jest", + testEnvironment: "node", +}; diff --git a/lib/admin.ts b/lib/admin.ts deleted file mode 100644 index bf5c7b09..00000000 --- a/lib/admin.ts +++ /dev/null @@ -1,82 +0,0 @@ -import { Client } from '.'; -import { AdminObject } from './admin/admin.types'; -import { dateToUnixTimestamp } from './util/time'; - -export default class Admin { - public readonly baseUrl = 'admins'; - - constructor(private readonly client: Client) { - this.client = client; - } - - find({ id }: AdminGetByIdData) { - return this.client.get({ url: `/${this.baseUrl}/${id}` }); - } - away({ adminId, enableAwayMode, enableReassignMode }: SetAdminAwayData) { - const data = { - away_mode_enabled: enableAwayMode, - away_mode_reassign: enableReassignMode, - }; - - return this.client.put({ - url: `/${this.baseUrl}/${adminId}/away`, - data, - }); - } - listAllActivityLogs({ before, after }: ListAllActivityLogsData) { - const params = { - created_at_after: dateToUnixTimestamp(after), - created_at_before: before ? dateToUnixTimestamp(before) : undefined, - }; - - return this.client.get({ - url: `/${this.baseUrl}/activity_logs`, - params, - }); - } - list() { - return this.client.get({ url: `/${this.baseUrl}` }); - } -} - -interface AdminGetByIdData { - id: string; -} - -interface SetAdminAwayData { - adminId: string; - enableAwayMode: boolean; - enableReassignMode: boolean; -} - -interface ListAllActivityLogsData { - after: Date; - before?: Date; -} - -interface ListAllActivityLogsResponse { - type: 'activity_log.list'; - activityLogs: Array; - pages?: Pages; -} - -interface ActivityObject { - id: string; - activity_type: string; - activity_description: string; - metadata: Record; - performed_by: AdminObject; -} - -interface Pages { - type: 'pages'; - next: unknown | null; - page: number; - per_page: number; - total_pages: number; -} - -interface ListAllResponse { - type: 'admin.list'; - admins: AdminObject[]; -} diff --git a/lib/admin/admin.types.ts b/lib/admin/admin.types.ts deleted file mode 100644 index 421a69a7..00000000 --- a/lib/admin/admin.types.ts +++ /dev/null @@ -1,12 +0,0 @@ -export interface AdminObject { - type: 'admin'; - id: string; - name: string; - email: string; - job_title: string; - away_mode_enabled: boolean; - away_mode_reassign: boolean; - has_inbox_seat: boolean; - team_ids: Array; - avatar: string | { image_url: string }; -} diff --git a/lib/article.ts b/lib/article.ts deleted file mode 100644 index 82436abd..00000000 --- a/lib/article.ts +++ /dev/null @@ -1,119 +0,0 @@ -import { Client } from '.'; -import { - ArticleObject, - TranslatedContentObject, -} from './article/article.types'; -import { - GenericDeletedResponse, - OperationById, - Paginated, -} from './common/common.types'; - -export default class Article { - public readonly baseUrl = 'articles'; - - constructor(private readonly client: Client) { - this.client = client; - } - - create({ - title, - description, - body, - authorId, - state, - parentId, - parentType, - translatedContent, - }: CreateArticleData) { - const data = { - title, - description, - body, - author_id: authorId, - state, - parent_id: parentId, - parent_type: parentType, - translated_content: translatedContent, - }; - - return this.client.post({ - url: `/${this.baseUrl}`, - data, - }); - } - find({ id }: ArticleFindByIdData) { - return this.client.get({ - url: `/${this.baseUrl}/${id}`, - }); - } - update({ - id, - title, - description, - body, - authorId, - state, - parentId, - parentType, - translatedContent, - }: UpdateArticleData) { - const data = { - title, - description, - body, - author_id: authorId, - state, - parent_id: parentId, - parent_type: parentType, - translated_content: translatedContent, - }; - - return this.client.put({ - url: `/${this.baseUrl}/${id}`, - data, - }); - } - delete({ id }: ArticleDeleteByIdData) { - return this.client.delete({ - url: `/${this.baseUrl}/${id}`, - }); - } - list({ page, perPage: per_page }: ArticleListData) { - const params = { - page, - per_page, - }; - - return this.client.get({ - url: `/${this.baseUrl}`, - params, - }); - } -} - -interface CreateArticleData { - title: string; - authorId: number; - description?: string; - body?: string; - state?: string; - parentId?: number; - parentType?: string; - translatedContent?: Omit; -} - -type ArticleFindByIdData = OperationById; - -type UpdateArticleData = Partial & OperationById; - -type ArticleDeleteByIdData = OperationById; - -type ArticleDeleteByIdResponse = GenericDeletedResponse<'article'>; - -type ArticleListData = { - page?: number; - perPage?: number; -}; - -type ArticleListResponse = Paginated; diff --git a/lib/article/article.types.ts b/lib/article/article.types.ts deleted file mode 100644 index 76d86410..00000000 --- a/lib/article/article.types.ts +++ /dev/null @@ -1,92 +0,0 @@ -import { Timestamp } from '../common/common.types'; - -export type ArticleObject = { - type: 'article'; - id: string; - workspace_id: string; - title: string; - description: string; - body: string; - author_id: string; - state: string; - created_at: Timestamp; - updated_at: Timestamp; - url: string; - parent_id: string; - parent_type: string; - default_locale: string; - translated_content: TranslatedContentObject; - statistics: StatisticsObject; -}; - -export enum Locales { - ARABIC = 'ar', - BULGARIAN = 'bg', - BOSNIAN = 'bs', - CATALAN = 'ca', - CZECH = 'cs', - DANISH = 'da', - GERMAN = 'de', - DE_FORM = 'de-form', - GREEK = 'el', - ENGLISH = 'en', - SPANISH = 'es', - ESTONIAN = 'et', - FINNISH = 'fi', - FRENCH = 'fr', - HEBREW = 'he', - CROATIAN = 'hr', - HUNGARIAN = 'hu', - INDONESIAN = 'id', - ITALIAN = 'it', - JAPANESE = 'ja', - KOREAN = 'ko', - LITHUANIAN = 'lt', - LATVIAN = 'lv', - MONGOLIAN = 'mn', - NORWEGIAN = 'nb', - DUTCH = 'nl', - POLISH = 'pl', - PORTUGUESE_BRAZIL = 'pt-BR', - PORTUGUESE = 'pt', - ROMANIAN = 'ro', - RUSSIAN = 'ru', - SLOVENIAN = 'sl', - SERBIAN = 'sr', - SWEDISH = 'sv', - TURKISH = 'tr', - VIETNAMESE = 'vi', - CHINESE_S = 'zh-CN', - CHINESE_T = 'zh-TW', -} - -export interface ContentObject { - type?: 'article_content'; - title: string; - description: string; - body: string; - author?: string; - author_id?: number; - state: string; - created_at?: Timestamp; - updated_at?: Timestamp; - url?: string; -} - -export type ArticleLocalesMapping = { - [key in Locales]: ContentObject; -}; - -export type TranslatedContentObject = { - type: 'article_translated_content'; -} & Partial; - -export type StatisticsObject = { - type: 'article_statistics'; - views: number; - conversations: number; - reactions: number; - happy_reaction_percentage: number; - neutral_reaction_percentage: number; - sad_reaction_percentage: number; -}; diff --git a/lib/client.ts b/lib/client.ts deleted file mode 100644 index 830b0b21..00000000 --- a/lib/client.ts +++ /dev/null @@ -1,290 +0,0 @@ -import axios, { Axios, AxiosDefaults, AxiosResponse } from 'axios'; -import { merge, omit } from 'lodash'; - -import Article from './article'; -import Admin from './admin'; -import Company from './company'; -import Contact from './contact'; -import Conversation from './conversation'; -import Count from './count'; -import DataAttribute from './dataAttribute'; -import DataExport from './dataExport'; -import Event from './event'; -import HelpCenter from './helpCenter'; -import Message from './message'; -import Note from './note'; -import Segment from './segment'; -import Subscription from './subscription'; -import Team from './team'; -import Tag from './tag'; -import Visitor from './visitor'; -import PhoneCallRedirect from './phoneCallRedirect'; - -import * as packageJson from '../package.json'; - -import { BadResponseError } from './errors/badResponse.error'; - -interface RequestOptions { - url: string; - // eslint-disable-next-line @typescript-eslint/no-explicit-any - data?: any; - // eslint-disable-next-line @typescript-eslint/no-explicit-any - params?: any; -} - -type Constructor = { - usernameAuth?: UsernameAuth; - tokenAuth?: TokenAuth; - apiKeyAuth?: ApiKeyAuth; -}; - -type UsernameAuth = { - username: string; - password: string; -}; - -type TokenAuth = { - token: string; -}; - -type ApiKeyAuth = { - appId: string; - appApiKey: string; -}; - -export default class Client { - articles: Article; - admins: Admin; - axiosInstance: Axios; - companies: Company; - contacts: Contact; - conversations: Conversation; - counts: Count; - dataAttributes: DataAttribute; - dataExport: DataExport; - events: Event; - helpCenter: HelpCenter; - messages: Message; - notes: Note; - segments: Segment; - subscriptions: Subscription; - passwordPart?: string; - propertiesToOmitInRequestOpts: string[]; - requestOpts: Partial; - tags: Tag; - teams: Team; - usernamePart?: string; - visitors: Visitor; - phoneCallRedirect: PhoneCallRedirect; - - constructor(args: Constructor) { - const [usernamePart, passwordPart] = Client.getAuthDetails(args); - - this.usernamePart = usernamePart; - this.passwordPart = passwordPart; - - if (!this.usernamePart || this.passwordPart === undefined) { - throw new Error( - 'Could not construct a client with those parameters' - ); - } - - this.admins = new Admin(this); - this.articles = new Article(this); - this.companies = new Company(this); - this.contacts = new Contact(this); - this.conversations = new Conversation(this); - this.counts = new Count(this); - this.dataAttributes = new DataAttribute(this); - this.dataExport = new DataExport(this); - this.events = new Event(this); - this.helpCenter = new HelpCenter(this); - this.messages = new Message(this); - this.notes = new Note(this); - this.segments = new Segment(this); - this.subscriptions = new Subscription(this); - this.tags = new Tag(this); - this.teams = new Team(this); - this.visitors = new Visitor(this); - this.phoneCallRedirect = new PhoneCallRedirect(this); - this.requestOpts = { - baseURL: 'https://api.intercom.io', - }; - this.propertiesToOmitInRequestOpts = ['headers.common.Accept']; - - this.axiosInstance = this.initiateAxiosInstance(); - } - initiateAxiosInstance(): Axios { - const defaultHeaders = { - 'User-Agent': `intercom-node-client/${packageJson.version}`, - Accept: 'application/json', - }; - - const axiosInstance = axios.create({ - auth: { - username: this.usernamePart as string, - password: this.passwordPart as string, - }, - baseURL: this.requestOpts.baseURL, - }); - - axiosInstance.defaults.headers.common = merge( - axiosInstance.defaults.headers.common, - defaultHeaders - ); - - return axiosInstance; - } - - useRequestOpts(opts: Partial) { - const filteredOpts = this.filterUnwantedProperties(opts); - - this.requestOpts = merge(this.requestOpts, filteredOpts); - this.updateAxiosInstanceDefaults(); - - return this; - } - - updateAxiosInstanceDefaults(): void { - this.axiosInstance.defaults = merge( - this.axiosInstance.defaults, - this.requestOpts - ); - } - - filterUnwantedProperties( - opts: Partial - ): Partial { - return omit(opts, this.propertiesToOmitInRequestOpts); - } - - async ping(): Promise { - try { - const response = await this.axiosInstance.get('/admins'); - - return response.data; - } catch (err) { - const error = err.response - ? this.checkOnErrorInResponse(err.response) - : err; - - throw error; - } - } - - async put({ url, data }: RequestOptions): Promise { - try { - const response = await this.axiosInstance.put(url, data); - - return response.data; - } catch (err) { - const error = err.response - ? this.checkOnErrorInResponse(err.response) - : err; - - throw error; - } - } - - async post({ url, data }: RequestOptions): Promise { - try { - const response = await this.axiosInstance.post(url, data); - - return response.data; - } catch (err) { - const error = err.response - ? this.checkOnErrorInResponse(err.response) - : err; - - throw error; - } - } - - async get({ url, data, params }: RequestOptions): Promise { - try { - const response = await this.axiosInstance.get(url, { - params, - data, - }); - - return response.data; - } catch (err) { - const error = err.response - ? this.checkOnErrorInResponse(err.response) - : err; - - throw error; - } - } - - async nextPage(paginationObject: { next: string }): Promise { - try { - const response = await this.axiosInstance.get( - paginationObject.next, - { baseURL: undefined } - ); - - return response.data; - } catch (err) { - const error = err.response - ? this.checkOnErrorInResponse(err.response) - : err; - - throw error; - } - } - - async delete({ url, data, params }: RequestOptions): Promise { - try { - const response = await this.axiosInstance.delete(url, { - data, - params, - }); - - return response.data; - } catch (err) { - const error = err.response - ? this.checkOnErrorInResponse(err.response) - : err; - - throw error; - } - } - - private checkOnErrorInResponse({ - data, - headers, - status, - }: AxiosResponse): Error | undefined { - if (data.type !== 'error.list') { - return undefined; - } - - const message = - Array.isArray(data.errors) && data.errors[0].message - ? data.errors[0].message - : null; - return new BadResponseError( - message || 'Response error', - data, - headers, - status - ); - } - - private static getAuthDetails( - args: Constructor - ): [username: string | undefined, password: string | undefined] { - if (args.apiKeyAuth) { - return [args.apiKeyAuth.appId, args.apiKeyAuth.appApiKey]; - } - if (args.tokenAuth) { - return [args.tokenAuth.token, '']; - } - if (args.usernameAuth) { - return [args.usernameAuth.username, args.usernameAuth.password]; - } - - return [undefined, undefined]; - } -} diff --git a/lib/common/common.types.ts b/lib/common/common.types.ts deleted file mode 100644 index c4bec953..00000000 --- a/lib/common/common.types.ts +++ /dev/null @@ -1,84 +0,0 @@ -export type StringifiedTimestamp = string; -export type Timestamp = number; -export type Seconds = number; -export type JavascriptObject = Record; - -export enum Role { - USER = 'user', - LEAD = 'lead', -} - -export type PaginatedBase = { - type: string; - pages: { - type: 'pages'; - next?: { - page: number; - starting_after?: string; - }; - page: number; - per_page: number; - total_pages: number; - }; - total_count: number; -}; - -export type Paginated = PaginatedBase & { - data: T[]; -}; - -export enum Operators { - AND = 'AND', - OR = 'OR', - EQUALS = '=', - NOT_EQUALS = '!=', - IN = 'IN', - NIN = 'NIN', - GREATER_THAN = '>', - LESS_THAN = '<', - CONTAINS = '~', - NOT_CONTAINS = '!~', - STARTS_WITH = '^', - ENDS_WITH = '$', -} - -interface FlatQuery { - field: string; - operator: Operators; - value: string | number | string[] | number[] | null; -} - -interface NestedQueries { - operator: Operators; - value: - | Array - | string - | number - | string[] - | number[] - | null; -} - -export interface GenericSearchFilters { - query: FlatQuery | NestedQueries; -} - -export enum Order { - DESC = 'desc', - ASC = 'asc', -} - -export interface PaginationParams { - page?: number; - perPage?: number; -} - -export interface GenericDeletedResponse { - id: string; - object: ObjectType; - deleted: boolean; -} - -export interface OperationById { - id: string; -} diff --git a/lib/company.ts b/lib/company.ts deleted file mode 100644 index e1d3b98f..00000000 --- a/lib/company.ts +++ /dev/null @@ -1,198 +0,0 @@ -import { Client } from '.'; -import { - PaginationParams, - JavascriptObject, - Order, - Paginated, - Timestamp, - GenericDeletedResponse, -} from './common/common.types'; -import { CompanyObject, ListCompaniesResponse } from './company/company.types'; -import { ContactObject } from './contact/contact.types'; -import Scroll from './scroll'; -import { SegmentObject } from './segment/segment.types'; -import { encodeParamsForURL } from './util/url'; - -export default class Company { - public readonly baseUrl = 'companies'; - public readonly scroll: Scroll; - - constructor(private readonly client: Client) { - this.client = client; - this.scroll = new Scroll(this.client, this.baseUrl); - } - create({ - createdAt, - companyId, - name, - monthlySpend, - plan, - size, - website, - industry, - customAttributes, - }: CreateCompanyData) { - const data = { - remote_created_at: createdAt, - company_id: companyId, - name, - monthly_spend: monthlySpend, - plan, - size, - website, - industry, - custom_attributes: customAttributes, - }; - - return this.client.post({ - url: `/${this.baseUrl}`, - data, - }); - } - update({ - createdAt, - companyId, - name, - monthlySpend, - plan, - size, - website, - industry, - customAttributes, - }: UpdateCompanyData) { - const data = { - remote_created_at: createdAt, - name, - monthly_spend: monthlySpend, - plan, - size, - website, - industry, - custom_attributes: customAttributes, - }; - - return this.client.put({ - url: `/${this.baseUrl}/${companyId}`, - data, - }); - } - find({ companyId, name }: FindCompanyData) { - const query = { - company_id: companyId, - name, - }; - - return this.client.get({ - url: `/${this.baseUrl}`, - params: encodeParamsForURL( - query as Record> - ), - }); - } - delete({ id }: DeleteCompanyData) { - return this.client.delete({ - url: `/${this.baseUrl}/${id}`, - }); - } - list({ - page, - perPage: per_page, - order, - tagId: tag_id, - segmentId: segment_id, - }: ListCompaniesData) { - const params = { - page, - per_page, - order, - tag_id, - segment_id, - }; - - return this.client.get({ - url: `/${this.baseUrl}`, - params, - }); - } - attachContact({ contactId, companyId }: AttachContactData) { - const data = { - id: companyId, - }; - - return this.client.post({ - url: `/${this.client.contacts.baseUrl}/${contactId}/${this.baseUrl}`, - data, - }); - } - detachContact({ contactId, companyId }: DetachContactData) { - return this.client.delete({ - url: `/${this.client.contacts.baseUrl}/${contactId}/${this.baseUrl}/${companyId}`, - }); - } - listAttachedContacts({ - companyId, - page, - perPage, - }: ListAttachedContactsData) { - const params = { page, perPage }; - - return this.client.get>({ - url: `/${this.baseUrl}/${companyId}/${this.client.contacts.baseUrl}`, - params, - }); - } - listAttachedSegments({ companyId }: ListAttachedSegmentsData) { - return this.client.get({ - url: `/${this.baseUrl}/${companyId}/${this.client.segments.baseUrl}`, - }); - } -} - -interface CreateCompanyData { - createdAt?: Timestamp; - companyId: string; - name?: string; - monthlySpend?: number; - plan?: string; - size?: number; - website?: string; - industry?: string; - customAttributes?: JavascriptObject; -} -// -type UpdateCompanyData = CreateCompanyData; -// -interface FindCompanyData { - companyId?: string; - name?: string; -} -// -interface DeleteCompanyData { - id: string; -} -type DeleteCompanyResponse = GenericDeletedResponse<'company'>; -// -interface ListCompaniesData extends PaginationParams { - order?: Order; - tagId?: string; - segmentId?: string; -} -// -interface AttachContactData { - contactId: string; - companyId: string; -} -// -type DetachContactData = AttachContactData; -// -interface ListAttachedContactsData extends PaginationParams { - companyId: string; -} -// -interface ListAttachedSegmentsData { - companyId: string; -} -interface ListAttachedSegmentsResponse { - type: 'list'; - data: SegmentObject[]; -} diff --git a/lib/company/company.types.ts b/lib/company/company.types.ts deleted file mode 100644 index f5f22b99..00000000 --- a/lib/company/company.types.ts +++ /dev/null @@ -1,39 +0,0 @@ -import { JavascriptObject, Paginated, Timestamp } from '../common/common.types'; -import { SegmentObject } from '../segment/segment.types'; -import { TagObject } from '../tag/tag.types'; - -export interface CompanyObject { - type: 'company'; - company_id: string; - id: string; - app_id: string; - name: string; - remote_created_at: Timestamp; - created_at: Timestamp; - updated_at: Timestamp; - last_request_at: Timestamp; - monthly_spend: number; - session_count: number; - user_count: number; - size: number; - website: string; - industry: string; - tags: { - type: 'tag.list'; - tags: TagObject; - }; - segments: { - type: 'segment.list'; - segments: SegmentObject; - }; - plan: PlanObject; - custom_attributes: JavascriptObject; -} - -export interface PlanObject { - type: 'plan'; - id: string; - name: string; -} - -export type ListCompaniesResponse = Paginated; diff --git a/lib/contact.ts b/lib/contact.ts deleted file mode 100644 index e4bf16b4..00000000 --- a/lib/contact.ts +++ /dev/null @@ -1,335 +0,0 @@ -import { Client } from '.'; -import { ContactObject } from './contact/contact.types'; -import { - GenericDeletedResponse, - GenericSearchFilters, - Paginated, - Role, -} from './common/common.types'; -import { ListCompaniesResponse } from './company/company.types'; -import { SegmentObject } from './segment/segment.types'; -import { TagObject } from './tag/tag.types'; -import { SubscriptionObject } from './subscription/subscription.types'; - -export default class Contact { - public readonly baseUrl = 'contacts'; - - constructor(private readonly client: Client) { - this.client = client; - } - createUser({ - externalId, - email, - phone, - name, - avatar, - signedUpAt, - lastSeenAt, - ownerId, - isUnsubscribedFromEmails, - customAttributes, - }: CreateUserData) { - const requestData: CreateContactRequest = { - role: Role.USER, - external_id: externalId, - email, - phone, - name, - avatar, - signed_up_at: signedUpAt, - last_seen_at: lastSeenAt, - owner_id: ownerId, - unsubscribed_from_emails: isUnsubscribedFromEmails, - custom_attributes: customAttributes, - }; - - return this.client.post({ - url: `/${this.baseUrl}`, - data: requestData, - }); - } - createLead(data?: CreateLeadData) { - const requestData: CreateContactRequest = { - role: Role.LEAD, - phone: data?.phone, - email: data?.email, - name: data?.name, - avatar: data?.avatar, - signed_up_at: data?.signedUpAt, - last_seen_at: data?.lastSeenAt, - owner_id: data?.ownerId, - unsubscribed_from_emails: data?.isUnsubscribedFromEmails, - custom_attributes: data?.customAttributes, - }; - return this.client.post({ - url: `/${this.baseUrl}`, - data: requestData, - }); - } - find({ id }: RetrieveContactData) { - return this.client.get({ - url: `/${this.baseUrl}/${id}`, - }); - } - update({ - id, - role, - externalId, - email, - phone, - name, - avatar, - signedUpAt, - lastSeenAt, - ownerId, - isUnsubscribedFromMails, - customAttributes, - }: UpdateContactData) { - const data: UpdateContactRequest = { - role, - external_id: externalId, - email, - phone, - name, - avatar, - signed_up_at: signedUpAt, - last_seen_at: lastSeenAt, - owner_id: ownerId, - unsubscribed_from_emails: isUnsubscribedFromMails, - custom_attributes: customAttributes, - }; - - return this.client.put({ - url: `/${this.baseUrl}/${id}`, - data, - }); - } - mergeLeadInUser({ leadId, userId }: MergeLeadInUserContactData) { - const data: MergeLeadInUserContactRequest = { - from: leadId, - into: userId, - }; - - return this.client.post({ - url: `/${this.baseUrl}/merge`, - data, - }); - } - search({ data }: SearchContactRequest) { - return this.client.post({ - url: `/${this.baseUrl}/search`, - data, - }); - } - list({ perPage, startingAfter }: ListAllContactsData) { - const params: ListAllContactsRequest = { - per_page: perPage, - starting_after: startingAfter, - }; - return this.client.get({ - url: `/${this.baseUrl}`, - params, - }); - } - delete({ id }: DeleteContactData) { - return this.client.delete({ - url: `/${this.baseUrl}/${id}`, - }); - } - archive({ id }: ArchiveContactData) { - return this.client.post({ - url: `/${this.baseUrl}/${id}/archive`, - }); - } - unarchive({ id }: UnarchiveContactData) { - return this.client.post({ - url: `/${this.baseUrl}/${id}/unarchive`, - }); - } - listAttachedCompanies({ id, perPage, page }: ListAttachedCompaniesData) { - const params = { - per_page: perPage, - page, - }; - return this.client.get({ - url: `/${this.baseUrl}/${id}/companies`, - params, - }); - } - listAttachedTags({ id }: RetrieveContactData) { - return this.client.get({ - url: `/${this.baseUrl}/${id}/tags`, - }); - } - listAttachedSegments({ id }: RetrieveContactData) { - return this.client.get({ - url: `/${this.baseUrl}/${id}/segments`, - }); - } - listAttachedEmailSubscriptions({ id }: RetrieveContactData) { - return this.client.get({ - url: `/${this.baseUrl}/${id}/subscriptions`, - }); - } -} - -type CreateContactRequest = Pick & - Partial< - Pick< - ContactObject, - | 'external_id' - | 'email' - | 'phone' - | 'name' - | 'avatar' - | 'signed_up_at' - | 'last_seen_at' - | 'owner_id' - | 'unsubscribed_from_emails' - | 'custom_attributes' - > - >; - -interface CreateUserDataBase { - phone?: CreateContactRequest['phone']; - name?: CreateContactRequest['name']; - email?: CreateContactRequest['email']; - avatar?: CreateContactRequest['avatar']; - signedUpAt?: CreateContactRequest['signed_up_at']; - lastSeenAt?: CreateContactRequest['last_seen_at']; - ownerId?: CreateContactRequest['owner_id']; - isUnsubscribedFromEmails?: CreateContactRequest['unsubscribed_from_emails']; - customAttributes?: CreateContactRequest['custom_attributes']; -} - -interface CreateUserData extends CreateUserDataBase { - externalId?: string; -} - -type CreateLeadData = CreateUserDataBase; - -// -interface RetrieveContactData { - id: string; -} -// -type UpdateContactRequest = Partial< - Pick< - ContactObject, - | 'role' - | 'external_id' - | 'email' - | 'phone' - | 'name' - | 'avatar' - | 'signed_up_at' - | 'last_seen_at' - | 'owner_id' - | 'unsubscribed_from_emails' - | 'custom_attributes' - > ->; - -type UpdateContactData = { - id: string; - role?: UpdateContactRequest['role']; - externalId?: UpdateContactRequest['external_id']; - email?: UpdateContactRequest['email']; - phone?: UpdateContactRequest['phone']; - name?: UpdateContactRequest['name']; - avatar?: UpdateContactRequest['avatar']; - signedUpAt?: UpdateContactRequest['signed_up_at']; - lastSeenAt?: UpdateContactRequest['last_seen_at']; - ownerId?: UpdateContactRequest['owner_id']; - isUnsubscribedFromMails?: UpdateContactRequest['unsubscribed_from_emails']; - customAttributes?: UpdateContactRequest['custom_attributes']; -}; -// -interface DeleteContactData { - id: string; -} - -type DeleteContactResponse = GenericDeletedResponse<'contact'>; -// -interface ArchiveContactData { - id: string; -} - -interface ArchiveContactResponse { - id: string; - object: ContactObject; - archived: boolean; -} -// -type UnarchiveContactData = ArchiveContactData; - -type UnarchiveContactResponse = ArchiveContactResponse; -// -interface MergeLeadInUserContactRequest { - from: string; - into: string; -} - -interface MergeLeadInUserContactData { - leadId: string; - userId: string; -} -// -export enum SearchContactOrderBy { - ASC = 'ascending', - DESC = 'descending', -} -interface SearchContactPagination { - pagination: { - per_page: number; - starting_after?: string; - }; -} - -interface SearchContactOrder { - sort: { - field: string; - order: SearchContactOrderBy; - }; -} - -interface SearchContactRequest { - data: GenericSearchFilters & - Partial & - Partial; -} - -type SearchContactResponse = Paginated; -// -interface ListAllContactsRequest { - per_page?: number; - starting_after?: string; -} - -interface ListAllContactsData { - perPage?: number; - startingAfter?: string; -} - -type ListContactsResponse = Paginated; -// -type ListAttachedTagsResponse = { - type: string; - tags: Array; -}; -// -type ListAttachedSegmentsResponse = { - type: string; - data: Array; -}; -// -type ListAttachedEmailSubscriptionsResponse = { - type: string; - data: Array; -}; -// -type ListAttachedCompaniesData = { - id: string; - perPage?: number; - page?: number; -}; diff --git a/lib/contact/contact.types.ts b/lib/contact/contact.types.ts deleted file mode 100644 index 97560159..00000000 --- a/lib/contact/contact.types.ts +++ /dev/null @@ -1,85 +0,0 @@ -import { JavascriptObject, Role, Timestamp } from '../common/common.types'; - -export interface ContactObject { - type: 'contact'; - id: string; - workspace_id: string; - external_id: string; - role: Role; - email: string; - phone: string; - name: string; - avatar: string; - owner_id: number; - social_profiles: Array; - has_hard_bounced: boolean; - marked_email_as_spam: boolean; - unsubscribed_from_emails: boolean; - created_at: Timestamp; - updated_at: Timestamp; - signed_up_at: Timestamp; - last_seen_at: Timestamp; - last_replied_at: Timestamp; - last_contacted_at: Timestamp; - last_email_opened_at: Timestamp; - last_email_clicked_at: Timestamp; - language_override: string; - browser: string; - browser_version: string; - browser_language: string; - os: string; - location: LocationObject; - android_app_name: string | null; - android_app_version: string | null; - android_device: string | null; - android_os_version: string | null; - android_sdk_version: string | null; - android_last_seen_at: Timestamp | null; - ios_app_name: string | null; - ios_app_version: string | null; - ios_device: string | null; - ios_os_version: string | null; - ios_sdk_version: string | null; - ios_last_seen_at: Timestamp | null; - custom_attributes: JavascriptObject; - tags: AddressableList; - notes: AddressableList; - companies: AddressableList; - opted_in_subscription_types: AddressableList; - opted_out_subscription_types: AddressableList; - referrer: string; - utm_campaign: string | null; - utm_content: string | null; - utm_medium: string | null; - utm_source: string | null; - utm_term: string | null; -} - -interface LocationObject { - type: 'location'; - country: string; - region: string; - city: string; - country_code: string; - continent_code: string; -} - -interface SocialProfileObject { - type: 'social_profile'; - name: string; - url: string; -} - -interface AddressableList { - type: 'list'; - data: Array; - url: string; - total_count: number; - has_more: boolean; -} - -interface AddressableObject { - type: 'company' | 'note' | 'tag'; - id: string; - url: string; -} diff --git a/lib/conversation.ts b/lib/conversation.ts deleted file mode 100644 index 060e96e9..00000000 --- a/lib/conversation.ts +++ /dev/null @@ -1,549 +0,0 @@ -import Client from './client'; -import { - StringifiedTimestamp, - GenericSearchFilters, - PaginatedBase, -} from './common/common.types'; -import { - ContactType, - ConversationObject, - ConversationObjectWithoutParts, -} from './conversation/conversation.types'; -import { MessageObject } from './message/message.types'; - -export default class Conversation { - public readonly baseUrl = 'conversations'; - - constructor(private readonly client: Client) { - this.client = client; - } - create({ userId, type = ContactType.USER, body }: CreateConversationData) { - const requestData: CreateConversationRequest = { - from: { - id: userId, - type, - }, - body, - }; - return this.client.post({ - url: `/${this.baseUrl}`, - data: requestData, - }); - } - find({ id, inPlainText }: RetrieveConversationData) { - const params = inPlainText - ? { - display_as: 'plaintext', - } - : undefined; - - return this.client.get({ - url: `/${this.baseUrl}/${id}`, - params, - }); - } - update({ id, markRead, customAttributes }: UpdateConversationData) { - const data: UpdateConversationRequest = { - read: markRead, - custom_attributes: customAttributes, - }; - - return this.client.put({ - url: `/${this.baseUrl}/${id}`, - data, - }); - } - replyByIdAsUser({ - id, - body, - intercomUserId, - userId, - email, - attachmentUrls, - }: ReplyByIdAsUserData) { - const data: ReplyToConversationAsUser = { - message_type: ReplyToConversationMessageType.COMMENT, - type: ReplyToConversationUserType.USER, - body, - intercom_user_id: intercomUserId, - user_id: userId, - email: email, - attachment_urls: attachmentUrls, - }; - return this.client.post({ - url: `/${this.baseUrl}/${id}/reply`, - data, - }); - } - replyByIdAsAdmin({ - id, - adminId, - messageType, - body, - attachmentUrls, - }: ReplyByIdAsAdminData) { - const data: ReplyToConversationAsAdmin = { - admin_id: adminId, - message_type: messageType, - type: ReplyToConversationUserType.ADMIN, - body, - attachment_urls: attachmentUrls, - }; - return this.client.post({ - url: `/${this.baseUrl}/${id}/reply`, - data, - }); - } - replyByLastAsUser({ - body, - intercomUserId, - userId, - email, - attachmentUrls, - }: ReplyByLastAsUserData) { - const data: ReplyToConversationAsUser = { - message_type: ReplyToConversationMessageType.COMMENT, - type: ReplyToConversationUserType.USER, - body, - intercom_user_id: intercomUserId, - user_id: userId, - email: email, - attachment_urls: attachmentUrls, - }; - return this.client.post({ - url: `/${this.baseUrl}/last/reply`, - data, - }); - } - replyByLastAsAdmin({ - adminId, - messageType, - body, - attachmentUrls, - }: ReplyByLastAsAdminData) { - const data: ReplyToConversationAsAdmin = { - admin_id: adminId, - message_type: messageType, - type: ReplyToConversationUserType.ADMIN, - body, - attachment_urls: attachmentUrls, - }; - return this.client.post({ - url: `/${this.baseUrl}/last/reply`, - data, - }); - } - assign({ - id, - type, - adminId, - assigneeId, - body, - withRunningAssignmentRules = false, - }: AssignConversationData) { - const url = `/${this.baseUrl}/${id}${ - withRunningAssignmentRules ? '/run_assignment_rules' : '' - }/parts`; - const data: AssignConversationRequest | undefined = - withRunningAssignmentRules - ? undefined - : { - message_type: AssignToConversationMessageType.ASSIGNMENT, - type, - admin_id: adminId, - assignee_id: assigneeId, - body, - }; - - return this.client.post({ url, data }); - } - snooze({ id, adminId, snoozedUntil }: SnoozeConversationData) { - const data: SnoozeConversationRequest = { - message_type: SnoozeConversationMessageType.SNOOZED, - admin_id: adminId, - snoozed_until: snoozedUntil, - }; - - return this.client.post({ - url: `/${this.baseUrl}/${id}/reply`, - data, - }); - } - close({ id, adminId, body }: CloseConversationData) { - const data: CloseConversationRequest = { - message_type: CloseConversationMessageType.CLOSED, - type: CloseConversationType.ADMIN, - admin_id: adminId, - body, - }; - - return this.client.post({ - url: `/${this.baseUrl}/${id}/parts`, - data, - }); - } - open({ id, adminId }: OpenConversationData) { - const data: OpenConversationRequest = { - message_type: OpenConversationMessageType.OPEN, - admin_id: adminId, - }; - - return this.client.post({ - url: `/${this.baseUrl}/${id}/parts`, - data, - }); - } - attachContactAsAdmin({ - id, - adminId, - customer, - }: AttachContactToConversationAsAdminData) { - const data: AttachContactToConversationAdminRequest = { - admin_id: adminId, - customer: { - intercom_user_id: customer.intercomUserId, - user_id: customer.userId, - email: customer.email, - }, - }; - - return this.client.post({ - url: `/${this.baseUrl}/${id}/customers`, - data, - }); - } - attachContactAsContact({ - id, - userId, - intercomUserId, - email, - customer, - }: AttachContactToConversationAsContactData) { - const data: AttachContactToConversationContactRequest = { - intercom_user_id: intercomUserId, - user_id: userId, - email, - customer: { - intercom_user_id: customer.intercomUserId, - user_id: customer.userId, - email: customer.email, - }, - }; - - return this.client.post({ - url: `/${this.baseUrl}/${id}/customers`, - data, - }); - } - detachContactAsAdmin({ - conversationId, - contactId, - adminId, - }: DetachContactFromConversationData) { - const data: DetachContactFromConversationRequest = { - admin_id: adminId, - }; - - return this.client.delete({ - url: `/${this.baseUrl}/${conversationId}/customers/${contactId}`, - data, - }); - } - search({ data }: SearchConversationRequest) { - return this.client.post({ - url: `/${this.baseUrl}/search`, - data, - }); - } - list({ - startingAfter: starting_after, - perPage: per_page, - }: ListConversationData) { - const params = { starting_after, per_page }; - - return this.client.get({ - url: `/${this.baseUrl}`, - params, - }); - } - redactConversationPart({ - conversationId, - conversationPartId, - sourceId, - type, - }: RedactConversationPartData) { - const data: RedactConversationPartRequest = { - conversation_id: conversationId, - conversation_part_id: conversationPartId, - source_id: sourceId, - type, - }; - - return this.client.post({ - url: `/${this.baseUrl}/redact`, - data, - }); - } -} - -interface CreateConversationRequest { - from: { - type: ContactType; - id: string; - }; - body: string; -} - -interface CreateConversationData { - userId: string; - type?: ContactType; - body: string; -} -// -interface RetrieveConversationData { - id: string; - inPlainText?: boolean; -} -// -interface UpdateConversationRequest { - custom_attributes?: object; - read?: boolean; -} -interface UpdateConversationData { - id: string; - markRead?: boolean; - customAttributes?: object; -} -// -export enum ReplyToConversationMessageType { - COMMENT = 'comment', - NOTE = 'note', -} -export enum ReplyToConversationUserType { - ADMIN = 'admin', - USER = 'user', -} - -interface ReplyToConversationAsUser { - message_type: ReplyToConversationMessageType; - type: ReplyToConversationUserType; - body: string; - // refactor to CustomerObject - intercom_user_id?: string; - user_id?: string; - email?: string; - attachment_urls?: Array; -} - -interface ReplyToConversationAsAdmin { - admin_id: string; - message_type: ReplyToConversationMessageType; - type: ReplyToConversationUserType; - body: string; - attachment_urls?: Array; -} - -interface ReplyByIdAsUserData { - id: string; - body: string; - intercomUserId?: string; - userId?: string; - email?: string; - attachmentUrls?: Array; -} - -interface ReplyByIdAsAdminData { - id: string; - adminId: string; - messageType: ReplyToConversationMessageType; - body: string; - attachmentUrls?: Array; -} - -type ReplyByLastAsUserData = Omit; - -type ReplyByLastAsAdminData = Omit; -// -export enum AssignToConversationMessageType { - ASSIGNMENT = 'assignment', -} -export enum AssignToConversationUserType { - ADMIN = 'admin', - TEAM = 'team', -} - -interface AssignConversationRequest { - message_type: AssignToConversationMessageType; - type?: AssignToConversationUserType; - admin_id?: string; - assignee_id?: string | 0; - body?: string; -} - -interface AssignConversationData { - id: string; - type?: AssignToConversationUserType; - adminId?: string; - assigneeId?: string | 0; - body?: string; - withRunningAssignmentRules?: boolean; -} -// -export enum SnoozeConversationMessageType { - SNOOZED = 'snoozed', -} - -interface SnoozeConversationRequest { - message_type: SnoozeConversationMessageType; - admin_id: string; - snoozed_until: StringifiedTimestamp; -} - -interface SnoozeConversationData { - id: string; - adminId: string; - snoozedUntil: StringifiedTimestamp; -} -// -export enum CloseConversationMessageType { - CLOSED = 'close', -} -export enum CloseConversationType { - ADMIN = 'admin', -} - -interface CloseConversationRequest { - message_type: CloseConversationMessageType; - type: CloseConversationType; - admin_id: string; - body?: string; -} - -interface CloseConversationData { - id: string; - adminId: string; - body?: string; -} -// -export enum OpenConversationMessageType { - OPEN = 'open', -} - -interface OpenConversationRequest { - message_type: OpenConversationMessageType; - admin_id: string; -} - -interface OpenConversationData { - id: string; - adminId: string; -} -// -interface CustomerObject { - intercom_user_id?: string; - user_id?: string; - email?: string; -} - -interface NormalizedCustomerObject { - intercomUserId?: string; - userId?: string; - email?: string; -} - -interface AttachContactToConversationAdminRequest { - admin_id: string; - customer: CustomerObject; -} - -interface AttachContactToConversationContactRequest extends CustomerObject { - customer: CustomerObject; -} - -interface AttachContactToConversationAsAdminData { - id: string; - adminId: string; - customer: NormalizedCustomerObject; -} - -interface AttachContactToConversationAsContactData - extends NormalizedCustomerObject { - id: string; - customer: NormalizedCustomerObject; -} - -interface AttachContactToConversationResponse { - customers: Array<{ id: string; type: ContactType }>; -} -// -interface DetachContactFromConversationRequest { - admin_id: string; -} - -interface DetachContactFromConversationData { - conversationId: string; - contactId: string; - adminId: string; -} -// -export enum SearchConversationOrderBy { - ASC = 'ascending', - DESC = 'descending', -} -interface SearchConversationPagination { - pagination: { - per_page: number; - starting_after?: string; - }; -} - -interface SearchConversationOrder { - sort: { - field: string; - order: SearchConversationOrderBy; - }; -} - -interface SearchConversationRequest { - data: GenericSearchFilters & - Partial & - Partial; -} - -type SearchConversationResponse = PaginatedBase & { - conversations: ConversationObject[]; -}; -// -export enum SortBy { - CreatedAt = 'created_at', - UpdatedAt = 'updated_at', - WaitingSince = 'waiting_since', -} - -interface ListConversationData { - startingAfter?: string; - perPage?: number; -} - -type ListConversationResponse = PaginatedBase & { - conversations: ConversationObjectWithoutParts[]; -}; -// -export enum RedactConversationPartType { - CONVERSATION_PART = 'conversation_part', - SOURCE = 'source', -} - -interface RedactConversationPartRequest { - type: RedactConversationPartType; - conversation_id: string; - conversation_part_id?: string; - source_id?: string; -} - -interface RedactConversationPartData { - type: RedactConversationPartType; - conversationId: string; - conversationPartId?: string; - sourceId?: string; -} diff --git a/lib/conversation/conversation.types.ts b/lib/conversation/conversation.types.ts deleted file mode 100644 index c82f2975..00000000 --- a/lib/conversation/conversation.types.ts +++ /dev/null @@ -1,163 +0,0 @@ -import { AdminObject } from '../admin/admin.types'; -import { JavascriptObject, Seconds, Timestamp } from '../common/common.types'; - -export interface ConversationObject { - type: 'conversation'; - id: string; - created_at: Timestamp; - updated_at: Timestamp; - source: SourceObject; - contacts: Array; - teammates: Array; - title: string; - admin_assignee_id: number; - team_assignee_id: number; - custom_attributes: JavascriptObject; - topics: JavascriptObject; - open: boolean; - state: ConversationState; - read: boolean; - waiting_since: Timestamp; - snoozed_until: Timestamp; - tags: JavascriptObject[]; - first_contact_reply: FirstContactReplyObject; - priority: ConversationPriority; - sla_applied: SLAObject; - conversation_rating: ConversationRatingObject; - statistics: StatisticsObject; - conversation_parts: ConversationPartObject; -} - -export type ConversationObjectWithoutParts = Exclude< - ConversationObject, - 'conversation_parts' ->; - -interface SourceObject { - type: ConversationSourceType; - id: string; - delivered_as: string; - subject?: string; - body: string; - author: Author; - attachments: JavascriptObject[]; - url: string; - redacted: boolean; -} - -interface ContactObject { - type: ContactType; - id: string; -} - -interface TeammateObject { - type: 'admin'; - id: string; -} - -interface FirstContactReplyObject { - type: ConversationSourceType; - url: string; - created_at: Timestamp; -} - -interface ConversationRatingObject { - rating: FromOneToFiveRating; - remark?: string; - created_at: Timestamp; - contact: ContactObject; - teammate: TeammateObject; -} - -interface SLAObject { - sla_name: string; - sla_status: SLAStatus; -} - -interface StatisticsObject { - time_to_assignment: Seconds; - time_to_admin_reply: Seconds; - time_to_first_close: Seconds; - time_to_last_close: Seconds; - median_time_to_reply: Seconds; - first_contact_reply_at: Seconds; - first_assignment_at: Seconds; - first_admin_reply_at: Seconds; - first_close_at: Seconds; - last_assignment_at: Seconds; - last_assignment_admin_reply_at: Seconds; - last_contact_reply_at: Seconds; - last_admin_reply_at: Seconds; - last_close_at: Seconds; - last_closed_by: AdminObject; - count_reopens: number; - count_assignments: number; - count_conversations_parts: number; -} - -interface ConversationPartObject { - type: 'conversation_part.list'; - conversation_parts: { - id: string; - part_type: string; - body: string; - created_at: Timestamp; - updated_at: Timestamp; - notified_at: Timestamp; - assigned_to: string | null; - author: Author; - attachments: JavascriptObject[]; - redacted: boolean; - }[]; -} - -enum ConversationState { - OPEN = 'open', - CLOSED = 'closed', - SNOOZED = 'snoozed', -} - -enum ConversationPriority { - PRIORITY = 'priority', - NOT_PRIORITY = 'not_priority', -} - -enum ConversationSourceType { - CONVERSATION = 'conversation', - PUSH = 'push', - FACEBOOK = 'facebook', - TWITTER = 'twitter', - EMAIL = 'email', -} - -export enum ContactType { - USER = 'user', - LEAD = 'lead', -} - -enum FromOneToFiveRating { - ONE = 1, - TWO = 2, - THREE = 3, - FOUR = 4, - FIVE = 5, -} - -enum SLAStatus { - HIT = 'hit', - MISSED = 'missed', - CANCELLED = 'cancelled', - ACTIVE = 'active', -} - -interface Author { - id: string; - type: AuthorType; -} - -enum AuthorType { - USER = 'user', - ADMIN = 'admin', - BOT = 'bot', - TEAM = 'team', -} diff --git a/lib/count.ts b/lib/count.ts deleted file mode 100644 index 8220204d..00000000 --- a/lib/count.ts +++ /dev/null @@ -1,86 +0,0 @@ -import { - Client, - CompanySegmentCountResponse, - CompanyTagCountResponse, - CompanyUserCountResponse, - UserCountResponse, - UserSegmentCountResponse, - UserTagCountResponse, -} from '.'; -import { - AdminConversationCountResponse, - AppTotalCountResponse, - CompanyCountResponse, - ConversationCountResponse, - CountEntity, - CountType, -} from './count/count.types'; - -export default class Count { - public readonly baseUrl = 'counts'; - - constructor(private readonly client: Client) { - this.client = client; - } - - forApp() { - return this.client.get({ - url: `/${this.baseUrl}`, - }); - } - - countCompany() { - return this.client.get({ - url: `/${this.baseUrl}`, - params: { type: CountType.COMPANY }, - }); - } - countCompanySegment() { - return this.client.get({ - url: `/${this.baseUrl}`, - params: { type: CountType.COMPANY, count: CountEntity.SEGMENT }, - }); - } - countCompanyTag() { - return this.client.get({ - url: `/${this.baseUrl}`, - params: { type: CountType.COMPANY, count: CountEntity.TAG }, - }); - } - countCompanyUser() { - return this.client.get({ - url: `/${this.baseUrl}`, - params: { type: CountType.COMPANY, count: CountEntity.USER }, - }); - } - countConversation() { - return this.client.get({ - url: `/${this.baseUrl}`, - params: { type: CountType.CONVERSATION }, - }); - } - countAdminConversation() { - return this.client.get({ - url: `/${this.baseUrl}`, - params: { type: CountType.CONVERSATION, count: CountEntity.ADMIN }, - }); - } - countUser() { - return this.client.get({ - url: `/${this.baseUrl}`, - params: { type: CountType.USER }, - }); - } - countUserSegment() { - return this.client.get({ - url: `/${this.baseUrl}`, - params: { type: CountType.USER, count: CountEntity.SEGMENT }, - }); - } - countUserTag() { - return this.client.get({ - url: `/${this.baseUrl}`, - params: { type: CountType.USER, count: CountEntity.TAG }, - }); - } -} diff --git a/lib/count/count.types.ts b/lib/count/count.types.ts deleted file mode 100644 index ac2cd0fe..00000000 --- a/lib/count/count.types.ts +++ /dev/null @@ -1,90 +0,0 @@ -export type AppTotalCountResponse = { - type: 'count.hash'; - company: CountObject; - user: CountObject; - lead: CountObject; - tag: CountObject; - segment: CountObject; -}; - -export type ConversationCountResponse = { - type: 'count'; - conversation: { - assigned: number; - closed: number; - open: number; - unassigned: number; - }; -}; - -export type AdminConversationCountResponse = { - type: 'count'; - conversation: { - admin: { - id: string; - name: string; - open: number; - closed: number; - }[]; - }; -}; - -export type CompanyCountResponse = { - type: 'count'; - company: CountObject; -}; - -export type CompanySegmentCountResponse = { - type: 'count'; - company: { segment: GenericCountObject[] }; -}; - -export type CompanyTagCountResponse = { - type: 'count'; - company: { tag: GenericCountObject[] }; -}; - -export type CompanyUserCountResponse = { - type: 'count'; - company: { - user: GenericCountObject & { remote_company_id: string }[]; - }; -}; - -export type UserCountResponse = { - type: 'count'; - user: { - user: CountObject; - }; -}; - -export type UserSegmentCountResponse = { - type: 'count'; - company: { segment: GenericCountObject[] }; -}; - -export type UserTagCountResponse = { - type: 'count'; - company: { tag: GenericCountObject[] }; -}; - -export type CountObject = { - count: number; -}; - -export enum CountType { - CONVERSATION = 'conversation', - USER = 'user', - COMPANY = 'company', -} - -export enum CountEntity { - ADMIN = 'admin', - SEGMENT = 'segment', - TAG = 'tag', - USER = 'user', -} - -type GenericCountObject = { - [title: string]: number; -}; diff --git a/lib/dataAttribute.ts b/lib/dataAttribute.ts deleted file mode 100644 index 46952d05..00000000 --- a/lib/dataAttribute.ts +++ /dev/null @@ -1,82 +0,0 @@ -import { Client } from '.'; -import { - DataAttributeObject, - ModelType, -} from './dataAttribute/dataAttribute.types'; - -export default class DataAttribute { - public readonly baseUrl = 'data_attributes'; - - constructor(private readonly client: Client) { - this.client = client; - } - - create({ - name, - model, - dataType: data_type, - description, - options, - }: CreateDataAttributeData) { - const data = { - name, - model, - data_type, - description, - options, - }; - - return this.client.post({ - url: `/${this.baseUrl}`, - data, - }); - } - update({ archived, description, id, options }: UpdateDataAttributeData) { - const data = { - archived, - description, - options, - }; - - return this.client.put({ - url: `/${this.baseUrl}/${id}`, - data, - }); - } - list({ model, includeArchived: include_archived }: ListDataAttributeData) { - const queryParams = { - model, - include_archived, - }; - - return this.client.get({ - url: `/${this.baseUrl}`, - params: queryParams, - }); - } -} - -interface CreateDataAttributeData { - name: DataAttributeObject['name']; - model: DataAttributeObject['model']; - dataType: DataAttributeObject['data_type']; - description?: DataAttributeObject['description']; - options?: DataAttributeObject['options']; -} - -interface UpdateDataAttributeData { - id: string; - archived?: DataAttributeObject['archived']; - description?: DataAttributeObject['description']; - options?: DataAttributeObject['options']; -} - -interface ListDataAttributeData { - model?: ModelType; - includeArchived?: boolean; -} - -interface ListAllResponse { - type: 'list'; - data: DataAttributeObject[]; -} diff --git a/lib/dataAttribute/dataAttribute.types.ts b/lib/dataAttribute/dataAttribute.types.ts deleted file mode 100644 index 4256dd0e..00000000 --- a/lib/dataAttribute/dataAttribute.types.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { Timestamp } from '../common/common.types'; - -export interface DataAttributeObject { - id: string; - name: string; - full_name: string; - label: string; - description: string; - data_type: DataType; - api_writable: boolean; - ui_writable: boolean; - custom: boolean; - archived: boolean; - model: ModelType; - options: Record<'value', string>[]; - type?: 'data_attribute'; - created_at?: Timestamp; - updated_at?: Timestamp; - admin_id?: string; -} - -export enum ModelType { - CONTACT = 'contact', - COMPANY = 'company', - CONVERSATION = 'conversation', -} - -export enum DataType { - STRING = 'string', - INTEGER = 'integer', - FLOAT = 'float', - BOOLEAN = 'boolean', - DATE = 'date', -} diff --git a/lib/dataExport.ts b/lib/dataExport.ts deleted file mode 100644 index bd704d48..00000000 --- a/lib/dataExport.ts +++ /dev/null @@ -1,43 +0,0 @@ -import { Client } from '.'; -import { DataExportObject } from './dataExport/dataExport.types'; -import { OperationById } from './common/common.types'; - -export default class DataExport { - public readonly baseUrl = 'export'; - - constructor(private readonly client: Client) { - this.client = client; - } - - find({ id }: DataExportByIdData) { - return this.client.get({ - url: `/${this.baseUrl}/content/data/${id}`, - }); - } - - create({ createdAtBefore, createdAtAfter }: CreateDataExportData) { - const data = { - created_at_before: createdAtBefore, - created_at_after: createdAtAfter, - }; - - return this.client.post({ - url: `/${this.client.dataExport.baseUrl}/content/data/`, - data, - }); - } - - cancel({ id }: DataExportByIdData) { - return this.client.post({ - url: `/${this.baseUrl}/cancel/${id}`, - data: {}, - }); - } -} - -interface CreateDataExportData { - createdAtBefore: number; - createdAtAfter: number; -} - -type DataExportByIdData = OperationById; diff --git a/lib/dataExport/dataExport.types.ts b/lib/dataExport/dataExport.types.ts deleted file mode 100644 index 88a482cf..00000000 --- a/lib/dataExport/dataExport.types.ts +++ /dev/null @@ -1,6 +0,0 @@ -export type DataExportObject = { - job_identifier: string; - status: string; - download_url: string; - download_expires_at: string; -}; diff --git a/lib/errors/badResponse.error.ts b/lib/errors/badResponse.error.ts deleted file mode 100644 index 4688c26c..00000000 --- a/lib/errors/badResponse.error.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { AxiosResponse } from 'axios'; - -export class BadResponseError extends Error { - constructor( - readonly message: string, - readonly body: AxiosResponse['data'], - readonly headers: AxiosResponse['headers'], - readonly statusCode: AxiosResponse['status'] - ) { - super(message); - this.body = body; - this.headers = headers; - this.statusCode = statusCode; - } -} diff --git a/lib/event.ts b/lib/event.ts deleted file mode 100644 index 55aac37b..00000000 --- a/lib/event.ts +++ /dev/null @@ -1,87 +0,0 @@ -import { Client } from '.'; -import { EventObject, SummaryEventObject } from './event/event.types'; - -export default class Event { - public readonly baseUrl = 'events'; - - constructor(private readonly client: Client) { - this.client = client; - } - create({ - eventName: event_name, - createdAt: created_at, - userId: user_id, - id, - email, - metadata, - }: CreateEventData) { - const data: EventObject = { - event_name, - created_at, - user_id, - id, - email, - metadata, - }; - - return this.client.post({ url: `/${this.baseUrl}`, data }); - } - listBy({ - userId: user_id, - email, - intercomUserId: intercom_user_id, - perPage: per_page, - summary, - }: ListParams) { - const params = { - type: 'user', - user_id, - email, - intercom_user_id, - per_page, - summary, - }; - - return summary - ? this.client.get({ - url: `/${this.baseUrl}`, - params, - }) - : this.client.get({ - url: `/${this.baseUrl}`, - params, - }); - } -} - -interface CreateEventData { - eventName: EventObject['event_name']; - createdAt: EventObject['created_at']; - userId?: EventObject['user_id']; - id?: EventObject['id']; - email?: EventObject['email']; - metadata?: EventObject['metadata']; -} -// -interface ListParams { - userId?: EventObject['user_id']; - email?: EventObject['email']; - intercomUserId?: string; - perPage?: number; - summary?: boolean; -} -interface ListParamsResponse { - type: 'event.list'; - events: EventObject[]; - pages: { - next?: string; - since?: string; - }; -} -interface ListParamsWithSummaryResponse { - type: 'event.summary'; - email: string; - intercom_user_id: string; - user_id: string; - events: SummaryEventObject[]; -} diff --git a/lib/event/event.types.ts b/lib/event/event.types.ts deleted file mode 100644 index f10b2e0b..00000000 --- a/lib/event/event.types.ts +++ /dev/null @@ -1,29 +0,0 @@ -import { Timestamp } from '../common/common.types'; - -export interface SummaryEventObject { - name: string; - first: Date | string; - last: Date | string; - count: number; - description: string | null; -} - -export interface EventObject { - event_name: string; - created_at: Timestamp; - user_id?: string; - id?: string; - email?: string; - metadata?: Metadata; -} - -export interface Metadata { - [x: string]: string | number | RichLink | MonetaryAmount; -} - -type RichLink = { - url: string; - value: string; -}; - -type MonetaryAmount = { amount: number; currency: string }; diff --git a/lib/helpCenter.ts b/lib/helpCenter.ts deleted file mode 100644 index b15351e5..00000000 --- a/lib/helpCenter.ts +++ /dev/null @@ -1,171 +0,0 @@ -import { Client } from '.'; -import { - GenericDeletedResponse, - OperationById, - Paginated, -} from './common/common.types'; -import { - CollectionObject, - GroupTranslatedContentObject, - SectionObject, -} from './helpCenter/helpCenter.types'; - -export default class HelpCenter { - public readonly collections: Collection; - public readonly sections: Section; - - constructor(client: Client) { - this.collections = new Collection(client); - this.sections = new Section(client); - } -} - -class Collection { - public readonly baseUrl = 'help_center/collections'; - - constructor(private readonly client: Client) { - this.client = client; - } - - create({ name, description, translatedContent }: CreateCollectionData) { - const data = { - name, - description, - translated_content: translatedContent, - }; - - return this.client.post({ - url: `/${this.baseUrl}`, - data, - }); - } - find({ id }: CollectionFindByIdData) { - return this.client.get({ - url: `/${this.baseUrl}/${id}`, - }); - } - update({ id, name, description, translatedContent }: UpdateCollectionData) { - const data = { - name, - description, - translated_content: translatedContent, - }; - - return this.client.put({ - url: `/${this.baseUrl}/${id}`, - data, - }); - } - delete({ id }: CollectionDeleteByIdData) { - return this.client.delete({ - url: `/${this.baseUrl}/${id}`, - }); - } - list({ page, perPage: per_page }: CollectionListData) { - const params = { - page, - per_page, - }; - - return this.client.get({ - url: `/${this.baseUrl}`, - params, - }); - } -} - -interface CreateCollectionData { - name: string; - description?: string; - translatedContent?: Omit; -} - -type CollectionFindByIdData = OperationById; - -type UpdateCollectionData = Partial & OperationById; - -type CollectionDeleteByIdData = OperationById; - -type CollectionDeleteByIdResponse = GenericDeletedResponse<'collection'>; - -type CollectionListData = { - page?: number; - perPage?: number; -}; - -type CollectionListResponse = Paginated; - -class Section { - public readonly baseUrl = 'help_center/sections'; - - constructor(private readonly client: Client) { - this.client = client; - } - - create({ name, parentId, translatedContent }: CreateSectionData) { - const data = { - name, - parent_id: parentId, - translated_content: translatedContent, - }; - - return this.client.post({ - url: `/${this.baseUrl}`, - data, - }); - } - find({ id }: SectionFindByIdData) { - return this.client.get({ - url: `/${this.baseUrl}/${id}`, - }); - } - update({ id, name, parentId, translatedContent }: UpdateSectionData) { - const data = { - name, - parent_id: parentId, - translated_content: translatedContent, - }; - - return this.client.put({ - url: `/${this.baseUrl}/${id}`, - data, - }); - } - delete({ id }: SectionDeleteByIdData) { - return this.client.delete({ - url: `/${this.baseUrl}/${id}`, - }); - } - list({ page, perPage: per_page }: SectionListData) { - const params = { - page, - per_page, - }; - - return this.client.get({ - url: `/${this.baseUrl}`, - params, - }); - } -} - -interface CreateSectionData { - name: string; - parentId: string; - translatedContent?: Omit; -} - -type SectionFindByIdData = OperationById; - -type UpdateSectionData = Partial & OperationById; - -type SectionDeleteByIdData = OperationById; - -type SectionDeleteByIdResponse = GenericDeletedResponse<'section'>; - -type SectionListData = { - page?: number; - perPage?: number; -}; - -type SectionListResponse = Paginated; diff --git a/lib/helpCenter/helpCenter.types.ts b/lib/helpCenter/helpCenter.types.ts deleted file mode 100644 index 737ca930..00000000 --- a/lib/helpCenter/helpCenter.types.ts +++ /dev/null @@ -1,37 +0,0 @@ -import { ArticleObject, Locales } from '../index'; - -export type CollectionObject = { - type: 'collection'; - name: string; - icon: string; - order: number; -} & Pick< - ArticleObject, - | 'id' - | 'workspace_id' - | 'description' - | 'created_at' - | 'updated_at' - | 'url' - | 'default_locale' - | 'translated_content' ->; - -export type SectionObject = { - type: 'section'; - parent_id: number; -} & Omit; - -export type GroupTranslatedContentObject = { - type: 'group_translated_content'; -} & Partial; - -export type HelpCenterLocalesMapping = { - [key in Locales]: GroupContentObject; -}; - -export type GroupContentObject = { - name: string; - description: string; - type?: 'group_content'; -}; diff --git a/lib/index.ts b/lib/index.ts deleted file mode 100644 index fe4bbc3b..00000000 --- a/lib/index.ts +++ /dev/null @@ -1,66 +0,0 @@ -import crypto from 'crypto'; - -export class IdentityVerification { - static userHash({ - secretKey, - identifier, - }: { - secretKey?: string; - identifier?: string; - }) { - if (!secretKey) { - throw new Error('secretKey must be provided'); - } - if (!identifier) { - throw new Error('identifier must be provided'); - } - return crypto - .createHmac('sha256', secretKey) - .update(identifier) - .digest('hex'); - } -} - -export { default as Client } from './client'; - -// Export model types -export * from './admin/admin.types'; -export * from './article/article.types'; -export * from './common/common.types'; -export * from './company/company.types'; -export * from './contact/contact.types'; -export * from './conversation/conversation.types'; -export * from './count/count.types'; -export * from './dataAttribute/dataAttribute.types'; -export * from './event/event.types'; -export * from './helpCenter/helpCenter.types'; -export * from './message/message.types'; -export * from './note/note.types'; -export * from './segment/segment.types'; -export * from './subscription/subscription.types'; -export * from './tag/tag.types'; -export * from './team/team.types'; -export * from './visitor/visitor.types'; - -// Export enums needed for requests -export { SearchContactOrderBy } from './contact'; -export { - ReplyToConversationMessageType, - ReplyToConversationUserType, - AssignToConversationMessageType, - AssignToConversationUserType, - SnoozeConversationMessageType, - CloseConversationMessageType, - CloseConversationType, - OpenConversationMessageType, - SearchConversationOrderBy, - SortBy, - RedactConversationPartType, -} from './conversation'; -export { RecipientType } from './message'; -export { - ContactObjectForMerge, - MergeVisitorToContactData, - VisitorObjectForMerge, - IdentificationForVisitor, -} from './visitor'; diff --git a/lib/message.ts b/lib/message.ts deleted file mode 100644 index e941ae65..00000000 --- a/lib/message.ts +++ /dev/null @@ -1,66 +0,0 @@ -import { Client } from '.'; -import { MessageObject, MessageType } from './message/message.types'; - -export default class Message { - private messagesBaseUrl = 'messages'; - - constructor(private readonly client: Client) { - this.client = client; - } - - create({ - messageType: message_type, - subject, - body, - template, - from, - to, - createConversationWithoutContactReply: - create_conversation_without_contact_reply, - }: CreateMessageBody) { - const data: CreateMessageRequest = { - message_type, - subject, - body, - template, - from, - to, - create_conversation_without_contact_reply, - }; - - return this.client.post({ - url: `/${this.messagesBaseUrl}`, - data, - }); - } -} - -interface CreateMessageRequest { - message_type: MessageType; - body: string; - from: Recipient; - to: Recipient; - subject?: string; - template?: string; - create_conversation_without_contact_reply?: boolean; -} - -interface CreateMessageBody - extends Omit< - CreateMessageRequest, - 'message_type' | 'create_conversation_without_contact_reply' - > { - messageType: MessageType; - createConversationWithoutContactReply?: boolean; -} - -type Recipient = { - id: string; - type: RecipientType; -}; - -export enum RecipientType { - ADMIN = 'admin', - USER = 'user', - LEAD = 'lead', -} diff --git a/lib/message/message.types.ts b/lib/message/message.types.ts deleted file mode 100644 index fe84adb0..00000000 --- a/lib/message/message.types.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { Timestamp } from '../common/common.types'; - -export interface MessageObject { - type: string; - id: string; - created_at: Timestamp; - subject?: string; - body: string; - message_type: MessageType; - conversation_id?: string; -} - -export enum MessageType { - EMAIL = 'email', - INAPP = 'inapp', - FACEBOOK = 'facebook', - TWITTER = 'twitter', -} diff --git a/lib/note.ts b/lib/note.ts deleted file mode 100644 index a8dae2f9..00000000 --- a/lib/note.ts +++ /dev/null @@ -1,54 +0,0 @@ -import { Client, NoteObject } from '.'; -import { OperationById, Paginated } from './common/common.types'; - -export default class Note { - public readonly baseUrl = 'notes'; - - constructor(private readonly client: Client) { - this.client = client; - } - - create({ adminId, body, contactId }: CreateNoteData) { - const data = { - admin_id: adminId, - body, - }; - - return this.client.post({ - url: `/${this.client.contacts.baseUrl}/${contactId}/${this.baseUrl}`, - data, - }); - } - find({ id }: FindNoteByIdData) { - return this.client.get({ - url: `/${this.baseUrl}/${id}`, - }); - } - list({ contactId, page, perPage: per_page }: ListNotesData) { - const params = { - page, - per_page, - }; - - return this.client.get({ - url: `/${this.client.contacts.baseUrl}/${contactId}/${this.baseUrl}`, - params, - }); - } -} - -interface CreateNoteData { - adminId: string; - body: string; - contactId: string; -} - -type FindNoteByIdData = OperationById; - -type ListNotesData = { - contactId: string; - page?: number; - perPage?: number; -}; - -type ListNotesResponse = Paginated; diff --git a/lib/note/note.types.ts b/lib/note/note.types.ts deleted file mode 100644 index 818c627c..00000000 --- a/lib/note/note.types.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { AdminObject, Timestamp } from '..'; - -export type NoteObject = { - type: 'note'; - id: string; - created_at: Timestamp; - contact: { - type: 'contact'; - id: string; - }; - author?: Pick< - AdminObject, - | 'type' - | 'id' - | 'name' - | 'email' - | 'away_mode_enabled' - | 'away_mode_reassign' - | 'avatar' - >; - body: string; -}; diff --git a/lib/phoneCallRedirect.ts b/lib/phoneCallRedirect.ts deleted file mode 100644 index 44073d6a..00000000 --- a/lib/phoneCallRedirect.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { Client } from '.'; -import { PhoneCallRedirectObject } from './phoneCallRedirect/phoneCallRedirect.types'; -import { JavascriptObject } from './common/common.types'; - -export default class PhoneCallRedirect { - public readonly baseUrl = 'phone_call_redirects'; - - constructor(private readonly client: Client) { - this.client = client; - } - - create({ phone, customAttributes }: CreatePhoneRedirectData) { - const data = { - phone, - customAttributes, - }; - return this.client.post({ - url: `/${this.client.phoneCallRedirect.baseUrl}/`, - data, - }); - } -} - -interface CreatePhoneRedirectData { - phone: string; - customAttributes?: JavascriptObject; -} diff --git a/lib/phoneCallRedirect/phoneCallRedirect.types.ts b/lib/phoneCallRedirect/phoneCallRedirect.types.ts deleted file mode 100644 index 45359aeb..00000000 --- a/lib/phoneCallRedirect/phoneCallRedirect.types.ts +++ /dev/null @@ -1,4 +0,0 @@ -export type PhoneCallRedirectObject = { - type: 'phone_call_redirect'; - url: string; -}; diff --git a/lib/scroll.ts b/lib/scroll.ts deleted file mode 100644 index 8aff02b5..00000000 --- a/lib/scroll.ts +++ /dev/null @@ -1,68 +0,0 @@ -import { Client } from '.'; - -export default class Scroll { - constructor( - private readonly client: Client, - private readonly scrollUrlDataType: string, - private scrollParam?: string - ) { - this.client = client; - this.scrollParam = scrollParam; - } - - // eslint-disable-next-line require-await - async each(params: EachData): Promise { - this.scrollParam = params.scrollParam ?? undefined; - - return this.eachInternal(); - } - - async eachInternal(storedData: EntityType[] = []): Promise { - const response = await this.client.get>({ - url: this.scrollUrl(), - }); - const dataFromResponse = response.data; - const combinedData = [...dataFromResponse, ...storedData]; - - if (dataFromResponse.length > 0) { - this.scrollParam = response.scroll_param; - return this.eachInternal(combinedData); - } - - return combinedData; - } - - async next({ - scrollParam, - }: NextData): Promise> { - this.scrollParam = scrollParam; - - const response = await this.client.get>({ - url: this.scrollUrl(), - }); - - return response; - } - - scrollUrl() { - const baseScrollUrl = `/${this.scrollUrlDataType}/scroll`; - - return this.scrollParam && this.scrollParam.length > 0 - ? `${baseScrollUrl}?scroll_param=${this.scrollParam}` - : baseScrollUrl; - } -} - -interface ScrollableResponse { - type: 'list'; - data: EntityType[]; - pages: number | null; - total_count: number | null; - scroll_param?: string; -} - -interface EachData { - scrollParam?: string; -} - -type NextData = EachData; diff --git a/lib/segment.ts b/lib/segment.ts deleted file mode 100644 index c0a1f775..00000000 --- a/lib/segment.ts +++ /dev/null @@ -1,39 +0,0 @@ -import { Client } from '.'; -import { SegmentObject } from './segment/segment.types'; - -export default class Segment { - public readonly baseUrl = 'segments'; - - constructor(private readonly client: Client) { - this.client = client; - } - list({ includeCount: include_count }: ListData) { - const params = { include_count }; - - return this.client.get({ - url: `/${this.baseUrl}`, - params, - }); - } - find({ id, includeCount: include_count }: FindSegmentData) { - const params = { include_count }; - - return this.client.get({ - url: `/${this.baseUrl}/${id}`, - params, - }); - } -} - -interface ListData { - includeCount?: boolean; -} -interface ListResponse { - type: 'segment.list'; - segments: SegmentObject[]; -} -// -interface FindSegmentData { - id: string; - includeCount?: boolean; -} diff --git a/lib/segment/segment.types.ts b/lib/segment/segment.types.ts deleted file mode 100644 index 7e5bca61..00000000 --- a/lib/segment/segment.types.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { Role, Timestamp } from '../common/common.types'; - -export type SegmentObject = { - type: 'segment'; - id: string; - name: string; - created_at: Timestamp; - updated_at: Timestamp; - person_type: Role; - count?: number; -}; diff --git a/lib/subscription.ts b/lib/subscription.ts deleted file mode 100644 index 012e8071..00000000 --- a/lib/subscription.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { Client } from '.'; -import { SubscriptionObject } from './subscription/subscription.types'; - -export default class Subscription { - public readonly baseUrl = 'subscription_types'; - - constructor(private readonly client: Client) { - this.client = client; - } - listTypes() { - return this.client.get({ - url: `/${this.baseUrl}`, - }); - } -} - -interface ListResponse { - type: 'list'; - data: SubscriptionObject[]; -} diff --git a/lib/subscription/subscription.types.ts b/lib/subscription/subscription.types.ts deleted file mode 100644 index f39f687b..00000000 --- a/lib/subscription/subscription.types.ts +++ /dev/null @@ -1,20 +0,0 @@ -export type SubscriptionObject = { - type: 'subscription'; - id: string; - state: SubscriptionState; - default_translation: TranslationObject; - translations: TranslationObject[]; - consent_type: 'opt_out'; -}; - -export enum SubscriptionState { - ARCHIVED = 'archived', - DRAFT = 'draft', - LIVE = 'live', -} - -export type TranslationObject = { - name: string; - description: string; - locale: string; -}; diff --git a/lib/tag.ts b/lib/tag.ts deleted file mode 100644 index a72cc598..00000000 --- a/lib/tag.ts +++ /dev/null @@ -1,142 +0,0 @@ -import { Client } from '.'; -import { TagObject } from './tag/tag.types'; - -export default class Tag { - private tagsBaseUrl = 'tags'; - - constructor(private readonly client: Client) { - this.client = client; - } - - create(data: CreateTagData) { - return this.client.post({ - url: `/${this.tagsBaseUrl}`, - data, - }); - } - update(data: UpdateTagData) { - return this.client.post({ - url: `/${this.tagsBaseUrl}`, - data, - }); - } - delete({ id }: DeleteTagData) { - return this.client.delete({ - url: `/${this.tagsBaseUrl}/${id}`, - }); - } - tagContact({ contactId, tagId }: TagContactData) { - const data = { - id: tagId, - }; - return this.client.post({ - url: `/${this.client.contacts.baseUrl}/${contactId}/${this.tagsBaseUrl}`, - data, - }); - } - tagConversation({ - conversationId, - tagId, - adminId: admin_id, - }: TagConversationData) { - const data = { - id: tagId, - admin_id, - }; - - return this.client.post({ - url: `/${this.client.conversations.baseUrl}/${conversationId}/${this.tagsBaseUrl}`, - data, - }); - } - tagCompanies({ tagName: name, companiesIds }: TagCompaniesData) { - const data = { - name, - companies: companiesIds.map((id) => ({ id })), - }; - - return this.client.post({ - url: `/${this.tagsBaseUrl}`, - data, - }); - } - untagContact({ contactId, tagId }: UntagContactData) { - return this.client.delete({ - url: `/${this.client.contacts.baseUrl}/${contactId}/${this.tagsBaseUrl}/${tagId}`, - }); - } - untagConversation({ - conversationId, - tagId, - adminId: admin_id, - }: UntagConversationData) { - const data = { - id: tagId, - admin_id, - }; - - return this.client.delete({ - url: `/${this.client.conversations.baseUrl}/${conversationId}/${this.tagsBaseUrl}/${tagId}`, - data, - }); - } - untagCompanies({ tagName: name, companiesIds }: UntagCompaniesData) { - const data = { - name, - companies: companiesIds.map((id) => ({ id, untag: true })), - }; - - return this.client.post({ - url: `/${this.tagsBaseUrl}`, - data, - }); - } - list() { - return this.client.get({ - url: `/${this.tagsBaseUrl}`, - }); - } -} - -interface CreateTagData { - name: string; -} -// -interface UpdateTagData extends CreateTagData { - id: string; -} -// -interface DeleteTagData { - id: string; -} -// -interface TagContactData { - contactId: string; - tagId: string; -} -// -interface TagConversationData { - conversationId: string; - tagId: string; - adminId: string; -} -// -interface TagCompaniesData { - tagName: string; - companiesIds: string[]; -} -// -type UntagContactData = TagContactData; -// -interface UntagConversationData { - tagId: string; - conversationId: string; - adminId: string; -} -// -type UntagCompaniesData = TagCompaniesData; -// -interface ListAllTagsResponse { - type: 'list'; - data: Array; -} diff --git a/lib/tag/tag.types.ts b/lib/tag/tag.types.ts deleted file mode 100644 index b55c8923..00000000 --- a/lib/tag/tag.types.ts +++ /dev/null @@ -1,5 +0,0 @@ -export interface TagObject { - id: string; - name: string; - type: 'tag'; -} diff --git a/lib/team.ts b/lib/team.ts deleted file mode 100644 index 5170acda..00000000 --- a/lib/team.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { Client } from '.'; -import { TeamObject } from './team/team.types'; - -export default class Team { - private readonly baseUrl = 'teams'; - - constructor(private readonly client: Client) { - this.client = client; - } - - find({ id }: FindTeamData) { - return this.client.get({ - url: `/${this.baseUrl}/${id}`, - }); - } - - list() { - return this.client.get({ - url: `/${this.baseUrl}`, - }); - } -} - -interface FindTeamData { - id: string; -} - -interface ListTeamsResponse { - type: 'team.list'; - teams: TeamObject[]; -} diff --git a/lib/team/team.types.ts b/lib/team/team.types.ts deleted file mode 100644 index 6ff6b700..00000000 --- a/lib/team/team.types.ts +++ /dev/null @@ -1,6 +0,0 @@ -export interface TeamObject { - type: 'team'; - id: string; - name: string; - admin_ids: string[]; -} diff --git a/lib/util/time.ts b/lib/util/time.ts deleted file mode 100644 index 5c93eb13..00000000 --- a/lib/util/time.ts +++ /dev/null @@ -1,3 +0,0 @@ -import { Timestamp } from "../common/common.types"; - -export const dateToUnixTimestamp = (date: Date): Timestamp => Math.floor(date.getTime() / 1000); diff --git a/lib/util/url.ts b/lib/util/url.ts deleted file mode 100644 index b5b049e1..00000000 --- a/lib/util/url.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { URLSearchParams } from 'url'; -import { omitBy, isEmpty } from 'lodash'; - -export const encodeParamsForURL = ( - params: Record> -): URLSearchParams => new URLSearchParams(purifyFromEmptiness(params)); - -const purifyFromEmptiness = ( - object: Record> -): Record> => omitBy(object, isEmpty); diff --git a/lib/visitor.ts b/lib/visitor.ts deleted file mode 100644 index fe6eb3f4..00000000 --- a/lib/visitor.ts +++ /dev/null @@ -1,87 +0,0 @@ -import { Client, ContactObject } from '.'; -import { Role } from './common/common.types'; -import { VisitorObject } from './visitor/visitor.types'; - -export default class Visitor { - public readonly baseUrl = 'visitors'; - - constructor(private readonly client: Client) { - this.client = client; - } - - find({ id, userId }: FindVisitorByIdData) { - const query = userId ? { user_id: userId } : {}; - const url = `/${this.baseUrl}${id ? `/${id}` : ''}`; - - return this.client.get({ - url, - params: query, - }); - } - update({ id, userId, name, customAttributes }: UpdateVisitorData) { - const data = { - id, - user_id: userId, - name, - custom_attributes: customAttributes, - }; - - return this.client.put({ - url: `/${this.baseUrl}`, - data, - }); - } - delete({ id }: DeleteVisitorByIdData) { - return this.client.delete({ - url: `/${this.baseUrl}/${id}`, - }); - } - mergeToContact({ visitor, user, type }: MergeVisitorToContactData) { - const data = { - visitor: { - id: visitor.id, - user_id: visitor.userId, - email: visitor.email, - }, - user: { - id: user.id, - user_id: user.userId, - email: user.email, - }, - type, - }; - - return this.client.post({ - url: `/${this.baseUrl}/convert`, - data, - }); - } -} - -export type IdentificationForVisitor = - | { id: string; userId?: never } - | { id?: never; userId: string }; - -type FindVisitorByIdData = IdentificationForVisitor; - -type UpdateVisitorData = IdentificationForVisitor & { - name?: string; - customAttributes?: VisitorObject['custom_attributes']; -}; - -type DeleteVisitorByIdData = { id: string }; - -export type MergeVisitorToContactData = { - visitor: VisitorObjectForMerge; - user: ContactObjectForMerge; - type: Role; -}; - -export type VisitorObjectForMerge = - | { id: string; userId?: never; email?: never } - | { id?: never; userId: string; email?: never } - | { id?: never; userId?: never; email: string }; - -export type ContactObjectForMerge = IdentificationForVisitor & { - email?: string; -}; diff --git a/lib/visitor/visitor.types.ts b/lib/visitor/visitor.types.ts deleted file mode 100644 index e9f92b53..00000000 --- a/lib/visitor/visitor.types.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { JavascriptObject, SegmentObject, TagObject, Timestamp } from '..'; - -export type VisitorObject = { - type: 'visitor'; - id: string; - created_at: Timestamp; - updated_at: Timestamp; - user_id: string; - name: string; - custom_attributes: JavascriptObject; - last_request_at: Timestamp; - avatar: string | { url: string }; - unsubscribed_from_emails: boolean; - location_data: JavascriptObject; - social_profiles: JavascriptObject[]; - segments: SegmentObject[]; - tags: TagObject[]; -}; diff --git a/package.json b/package.json index 028941d4..3692ca63 100644 --- a/package.json +++ b/package.json @@ -1,61 +1,43 @@ { "name": "intercom-client", - "version": "5.0.0", - "description": "Official Node bindings to the Intercom API", - "homepage": "https://github.com/intercom/intercom-node", - "bugs:": "https://github.com/intercom/intercom-node/issues", - "repository": "intercom/intercom-node", - "author": { - "name": "Bob Long", - "email": "bob@intercom.io" + "version": "6.0.0", + "private": false, + "repository": "https://github.com/intercom/intercom-node", + "main": "./index.js", + "types": "./index.d.ts", + "scripts": { + "format": "prettier . --write --ignore-unknown", + "build": "tsc", + "prepack": "cp -rv dist/. .", + "test": "jest" }, - "files": [ - "dist" - ], - "main": "dist/index.js", - "keywords": [ - "intercom", - "api" - ], "dependencies": { - "axios": "^1.6.0", - "htmlencode": "^0.0.4", - "lodash": "^4.17.21" + "url-join": "4.0.1", + "form-data": "^4.0.0", + "formdata-node": "^6.0.3", + "node-fetch": "2.7.0", + "qs": "6.11.2", + "readable-stream": "^4.5.2", + "js-base64": "3.7.2" }, "devDependencies": { - "@istanbuljs/nyc-config-typescript": "^1.0.2", - "@types/lodash": "^4.14.195", - "@types/mocha": "^9.1.1", - "@types/node": "^16.18.38", - "@types/sinon": "^10.0.15", - "@typescript-eslint/eslint-plugin": "^5.61.0", - "@typescript-eslint/parser": "^5.61.0", - "eslint": "^8.44.0", - "eslint-config-prettier": "^8.8.0", - "eslint-plugin-no-only-tests": "^2.6.0", - "merge2": "^1.4.1", - "mocha": "^9.2.2", - "nock": "^13.3.1", - "nyc": "^15.1.0", - "prettier": "^2.8.8", - "sinon": "^7.5.0", - "ts-node": "^10.9.1", - "tslib": "^2.6.0", - "typescript": "^4.9.5" - }, - "scripts": { - "clean": "rm -r -f dist", - "static": "eslint .", - "compile_ts": "tsc", - "move_compiled_to_dist": "mv dist/lib/* dist && rmdir dist/lib", - "prepublish": "yarn clean && yarn static && yarn compile_ts && yarn move_compiled_to_dist", - "test:unit": "yarn compile_ts && mocha -r ts-node/register test/unit/*.test.ts --reporter=nyan", - "test:integration": "yarn compile_ts && mocha -r ts-node/register test/integration/**/*.test.ts --timeout=30000", - "coverage": "nyc yarn test" - }, - "engines": { - "node": ">= v8.0.0" + "@types/url-join": "4.0.1", + "@types/qs": "6.9.8", + "@types/node-fetch": "2.6.9", + "@types/readable-stream": "^4.0.15", + "webpack": "^5.94.0", + "ts-loader": "^9.3.1", + "jest": "29.7.0", + "@types/jest": "29.5.5", + "ts-jest": "29.1.1", + "jest-environment-jsdom": "29.7.0", + "@types/node": "17.0.33", + "prettier": "2.7.1", + "typescript": "4.6.4" }, - "license": "Apache-2.0", - "packageManager": "yarn@3.1.1" + "browser": { + "fs": false, + "os": false, + "path": false + } } diff --git a/reference.md b/reference.md new file mode 100644 index 00000000..09ab857e --- /dev/null +++ b/reference.md @@ -0,0 +1,7819 @@ +# Reference + +## Admins + +
client.admins.identify() -> Intercom.AdminWithApp +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can view the currently authorised admin along with the embedded app object (a "workspace" in legacy terminology). + +> 🚧 Single Sign On +> +> If you are building a custom "Log in with Intercom" flow for your site, and you call the `/me` endpoint to identify the logged-in user, you should not accept any sign-ins from users with unverified email addresses as it poses a potential impersonation security risk. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.admins.identify(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Admins.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.admins.away({ ...params }) -> Intercom.Admin +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can set an Admin as away for the Inbox. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.admins.away({ + admin_id: "admin_id", + away_mode_enabled: true, + away_mode_reassign: true, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ConfigureAwayAdminRequest` + +
+
+ +
+
+ +**requestOptions:** `Admins.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.admins.listAllActivityLogs({ ...params }) -> Intercom.ActivityLogList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can get a log of activities by all admins in an app. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.admins.listAllActivityLogs({ + created_at_after: "1677253093", + created_at_before: "1677861493", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListAllActivityLogsRequest` + +
+
+ +
+
+ +**requestOptions:** `Admins.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.admins.list() -> Intercom.AdminList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of admins for a given workspace. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.admins.list(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Admins.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.admins.find({ ...params }) -> Intercom.Admin +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can retrieve the details of a single admin. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.admins.find({ + admin_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindAdminRequest` + +
+
+ +
+
+ +**requestOptions:** `Admins.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Articles + +
client.articles.list({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all articles by making a GET request to `https://api.intercom.io/articles`. + +> 📘 How are the articles sorted and ordered? +> +> Articles will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated articles first. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const response = await client.articles.list(); +for await (const item of response) { + console.log(item); +} + +// Or you can manually iterate page-by-page +const page = await client.articles.list(); +while (page.hasNextPage()) { + page = page.getNextPage(); +} +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListArticlesRequest` + +
+
+ +
+
+ +**requestOptions:** `Articles.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.articles.create({ ...params }) -> Intercom.Article +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a new article by making a POST request to `https://api.intercom.io/articles`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.articles.create({ + title: "Thanks for everything", + description: "Description of the Article", + body: "Body of the Article", + author_id: 991267407, + state: "published", + parent_id: 145, + parent_type: "collection", + translated_content: { + fr: { + type: "article_content", + title: "Merci pour tout", + description: "Description de l'article", + body: "Corps de l'article", + author_id: 991267407, + state: "published", + }, + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateArticleRequest` + +
+
+ +
+
+ +**requestOptions:** `Articles.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.articles.find({ ...params }) -> Intercom.Article +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single article by making a GET request to `https://api.intercom.io/articles/`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.articles.find({ + article_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindArticleRequest` + +
+
+ +
+
+ +**requestOptions:** `Articles.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.articles.update({ ...params }) -> Intercom.Article +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update the details of a single article by making a PUT request to `https://api.intercom.io/articles/`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.articles.update({ + article_id: "123", + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UpdateArticleRequest` + +
+
+ +
+
+ +**requestOptions:** `Articles.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.articles.delete({ ...params }) -> Intercom.DeletedArticleObject +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete a single article by making a DELETE request to `https://api.intercom.io/articles/`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.articles.delete({ + article_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.DeleteArticleRequest` + +
+
+ +
+
+ +**requestOptions:** `Articles.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.articles.search({ ...params }) -> Intercom.SearchArticlesResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can search for articles by making a GET request to `https://api.intercom.io/articles/search`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.articles.search({ + phrase: "Getting started", + state: "published", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.SearchArticlesRequest` + +
+
+ +
+
+ +**requestOptions:** `Articles.RequestOptions` + +
+
+
+
+ +
+
+
+ +## HelpCenters + +
client.helpCenters.find({ ...params }) -> Intercom.HelpCenter +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single Help Center by making a GET request to `https://api.intercom.io/help_center/help_center/`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.helpCenters.find({ + help_center_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindHelpCenterRequest` + +
+
+ +
+
+ +**requestOptions:** `HelpCenters.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.helpCenters.list({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can list all Help Centers by making a GET request to `https://api.intercom.io/help_center/help_centers`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const response = await client.helpCenters.list(); +for await (const item of response) { + console.log(item); +} + +// Or you can manually iterate page-by-page +const page = await client.helpCenters.list(); +while (page.hasNextPage()) { + page = page.getNextPage(); +} +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListHelpCentersRequest` + +
+
+ +
+
+ +**requestOptions:** `HelpCenters.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Companies + +
client.companies.retrieve({ ...params }) -> Intercom.CompanyList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a single company by passing in `company_id` or `name`. + +`https://api.intercom.io/companies?name={name}` + +`https://api.intercom.io/companies?company_id={company_id}` + +You can fetch all companies and filter by `segment_id` or `tag_id` as a query parameter. + +`https://api.intercom.io/companies?tag_id={tag_id}` + +`https://api.intercom.io/companies?segment_id={segment_id}` + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.companies.retrieve({ + name: "my company", + company_id: "12345", + tag_id: "678910", + segment_id: "98765", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.RetrieveCompanyRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.companies.createOrUpdate({ ...params }) -> Intercom.Company +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create or update a company. + +Companies will be only visible in Intercom when there is at least one associated user. + +Companies are looked up via `company_id` in a `POST` request, if not found via `company_id`, the new company will be created, if found, that company will be updated. + +{% admonition type="attention" name="Using `company_id`" %} +You can set a unique `company_id` value when creating a company. However, it is not possible to update `company_id`. Be sure to set a unique value once upon creation of the company. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.companies.createOrUpdate({ + name: "my company", + company_id: "company_remote_id", + remote_created_at: 1374138000, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateOrUpdateCompanyRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.companies.find({ ...params }) -> Intercom.Company +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a single company. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.companies.find({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindCompanyRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.companies.update({ ...params }) -> Intercom.Company +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update a single company using the Intercom provisioned `id`. + +{% admonition type="attention" name="Using `company_id`" %} +When updating a company it is not possible to update `company_id`. This can only be set once upon creation of the company. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.companies.update({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UpdateCompanyRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.companies.delete({ ...params }) -> Intercom.DeletedCompanyObject +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete a single company. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.companies.delete({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.DeleteCompanyRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.companies.listAttachedContacts({ ...params }) -> Intercom.CompanyAttachedContacts +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all contacts that belong to a company. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.companies.listAttachedContacts({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListAttachedContactsRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.companies.listAttachedSegments({ ...params }) -> Intercom.CompanyAttachedSegments +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all segments that belong to a company. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.companies.listAttachedSegments({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListSegmentsAttachedToCompanyRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.companies.list({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can list companies. The company list is sorted by the `last_request_at` field and by default is ordered descending, most recently requested first. + +Note that the API does not include companies who have no associated users in list responses. + +When using the Companies endpoint and the pages object to iterate through the returned companies, there is a limit of 10,000 Companies that can be returned. If you need to list or iterate on more than 10,000 Companies, please use the [Scroll API](https://developers.intercom.com/reference#iterating-over-all-companies). +{% admonition type="warning" name="Pagination" %} +You can use pagination to limit the number of results returned. The default is `20` results per page. +See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const response = await client.companies.list({ + order: "desc", +}); +for await (const item of response) { + console.log(item); +} + +// Or you can manually iterate page-by-page +const page = await client.companies.list({ + order: "desc", +}); +while (page.hasNextPage()) { + page = page.getNextPage(); +} +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListCompaniesRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.companies.scroll({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ + The `list all companies` functionality does not work well for huge datasets, and can result in errors and performance problems when paging deeply. The Scroll API provides an efficient mechanism for iterating over all companies in a dataset. + +- Each app can only have 1 scroll open at a time. You'll get an error message if you try to have more than one open per app. +- If the scroll isn't used for 1 minute, it expires and calls with that scroll param will fail +- If the end of the scroll is reached, "companies" will be empty and the scroll parameter will expire + +{% admonition type="info" name="Scroll Parameter" %} +You can get the first page of companies by simply sending a GET request to the scroll endpoint. +For subsequent requests you will need to use the scroll parameter from the response. +{% /admonition %} +{% admonition type="danger" name="Scroll network timeouts" %} +Since scroll is often used on large datasets network errors such as timeouts can be encountered. When this occurs you will see a HTTP 500 error with the following message: +"Request failed due to an internal network error. Please restart the scroll operation." +If this happens, you will need to restart your scroll query: It is not possible to continue from a specific point when using scroll. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const response = await client.companies.scroll(); +for await (const item of response) { + console.log(item); +} + +// Or you can manually iterate page-by-page +const page = await client.companies.scroll(); +while (page.hasNextPage()) { + page = page.getNextPage(); +} +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ScrollCompaniesRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.companies.attachContact({ ...params }) -> Intercom.Company +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can attach a company to a single contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.companies.attachContact({ + contact_id: "contact_id", + id: "667d608d8a68186f43bafd70", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.AttachContactToCompanyRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.companies.detachContact({ ...params }) -> Intercom.Company +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can detach a company from a single contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.companies.detachContact({ + contact_id: "58a430d35458202d41b1e65b", + company_id: "58a430d35458202d41b1e65b", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.DetachContactFromCompanyRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Contacts + +
client.contacts.listAttachedCompanies({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of companies that are associated to a contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const response = await client.contacts.listAttachedCompanies({ + contact_id: "63a07ddf05a32042dffac965", +}); +for await (const item of response) { + console.log(item); +} + +// Or you can manually iterate page-by-page +const page = await client.contacts.listAttachedCompanies({ + contact_id: "63a07ddf05a32042dffac965", +}); +while (page.hasNextPage()) { + page = page.getNextPage(); +} +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListAttachedCompaniesRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.contacts.listAttachedSegments({ ...params }) -> Intercom.ContactSegments +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of segments that are associated to a contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.listAttachedSegments({ + contact_id: "63a07ddf05a32042dffac965", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListSegmentsAttachedToContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.contacts.listAttachedSubscriptions({ ...params }) -> Intercom.SubscriptionTypeList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of subscription types that are attached to a contact. These can be subscriptions that a user has 'opted-in' to or has 'opted-out' from, depending on the subscription type. +This will return a list of Subscription Type objects that the contact is associated with. + +The data property will show a combined list of: + +1.Opt-out subscription types that the user has opted-out from. +2.Opt-in subscription types that the user has opted-in to receiving. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.listAttachedSubscriptions({ + contact_id: "63a07ddf05a32042dffac965", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListAttachedSubscriptionsRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.contacts.attachSubscription({ ...params }) -> Intercom.SubscriptionType +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can add a specific subscription to a contact. In Intercom, we have two different subscription types based on user consent - opt-out and opt-in: + +1.Attaching a contact to an opt-out subscription type will opt that user out from receiving messages related to that subscription type. + +2.Attaching a contact to an opt-in subscription type will opt that user in to receiving messages related to that subscription type. + +This will return a subscription type model for the subscription type that was added to the contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.attachSubscription({ + contact_id: "63a07ddf05a32042dffac965", + id: "37846", + consent_type: "opt_in", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.AttachSubscriptionToContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.contacts.detachSubscription({ ...params }) -> Intercom.SubscriptionType +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can remove a specific subscription from a contact. This will return a subscription type model for the subscription type that was removed from the contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.detachSubscription({ + contact_id: "63a07ddf05a32042dffac965", + subscription_id: "37846", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.DetachSubscriptionFromContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.contacts.listAttachedTags({ ...params }) -> Intercom.TagList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all tags that are attached to a specific contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.listAttachedTags({ + contact_id: "63a07ddf05a32042dffac965", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListTagsAttachedToContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.contacts.find({ ...params }) -> Intercom.Contact +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.find({ + contact_id: "63a07ddf05a32042dffac965", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.contacts.update({ ...params }) -> Intercom.Contact +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update an existing contact (ie. user or lead). + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.update({ + contact_id: "63a07ddf05a32042dffac965", + email: "joebloggs@intercom.io", + name: "joe bloggs", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UpdateContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.contacts.delete({ ...params }) -> Intercom.ContactDeleted +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete a single contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.delete({ + contact_id: "contact_id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.DeleteContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.contacts.mergeLeadInUser({ ...params }) -> Intercom.Contact +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can merge a contact with a `role` of `lead` into a contact with a `role` of `user`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.mergeLeadInUser({ + from: "667d60ac8a68186f43bafdbb", + into: "667d60ac8a68186f43bafdbc", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.MergeContactsRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.contacts.search({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can search for multiple contacts by the value of their attributes in order to fetch exactly who you want. + +To search for contacts, you need to send a `POST` request to `https://api.intercom.io/contacts/search`. + +This will accept a query object in the body which will define your filters in order to search for contacts. + +{% admonition type="warning" name="Optimizing search queries" %} +Search queries can be complex, so optimizing them can help the performance of your search. +Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize +pagination to limit the number of results returned. The default is `50` results per page. +See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. +{% /admonition %} + +### Contact Creation Delay + +If a contact has recently been created, there is a possibility that it will not yet be available when searching. This means that it may not appear in the response. This delay can take a few minutes. If you need to be instantly notified it is recommended to use webhooks and iterate to see if they match your search filters. + +### Nesting & Limitations + +You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). +There are some limitations to the amount of multiple's there can be: + +- There's a limit of max 2 nested filters +- There's a limit of max 15 filters for each AND or OR group + +### Searching for Timestamp Fields + +All timestamp fields (created_at, updated_at etc.) are indexed as Dates for Contact Search queries; Datetime queries are not currently supported. This means you can only query for timestamp fields by day - not hour, minute or second. +For example, if you search for all Contacts with a created_at value greater (>) than 1577869200 (the UNIX timestamp for January 1st, 2020 9:00 AM), that will be interpreted as 1577836800 (January 1st, 2020 12:00 AM). The search results will then include Contacts created from January 2nd, 2020 12:00 AM onwards. +If you'd like to get contacts created on January 1st, 2020 you should search with a created_at value equal (=) to 1577836800 (January 1st, 2020 12:00 AM). +This behaviour applies only to timestamps used in search queries. The search results will still contain the full UNIX timestamp and be sorted accordingly. + +### Accepted Fields + +Most key listed as part of the Contacts Model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). + +| Field | Type | +| ---------------------------------- | ------------------------------ | +| id | String | +| role | String
Accepts user or lead | +| name | String | +| avatar | String | +| owner_id | Integer | +| email | String | +| email_domain | String | +| phone | String | +| formatted_phone | String | +| external_id | String | +| created_at | Date (UNIX Timestamp) | +| signed_up_at | Date (UNIX Timestamp) | +| updated_at | Date (UNIX Timestamp) | +| last_seen_at | Date (UNIX Timestamp) | +| last_contacted_at | Date (UNIX Timestamp) | +| last_replied_at | Date (UNIX Timestamp) | +| last_email_opened_at | Date (UNIX Timestamp) | +| last_email_clicked_at | Date (UNIX Timestamp) | +| language_override | String | +| browser | String | +| browser_language | String | +| os | String | +| location.country | String | +| location.region | String | +| location.city | String | +| unsubscribed_from_emails | Boolean | +| marked_email_as_spam | Boolean | +| has_hard_bounced | Boolean | +| ios_last_seen_at | Date (UNIX Timestamp) | +| ios_app_version | String | +| ios_device | String | +| ios_app_device | String | +| ios_os_version | String | +| ios_app_name | String | +| ios_sdk_version | String | +| android_last_seen_at | Date (UNIX Timestamp) | +| android_app_version | String | +| android_device | String | +| android_app_name | String | +| andoid_sdk_version | String | +| segment_id | String | +| tag_id | String | +| custom_attributes.{attribute_name} | String | + +### Accepted Operators + +{% admonition type="attention" name="Searching based on `created_at`" %} +You cannot use the `<=` or `>=` operators to search by `created_at`. +{% /admonition %} + +The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + +| Operator | Valid Types | Description | +| :------- | :------------------------------- | :--------------------------------------------------------------- | +| = | All | Equals | +| != | All | Doesn't Equal | +| IN | All | In
Shortcut for `OR` queries
Values must be in Array | +| NIN | All | Not In
Shortcut for `OR !` queries
Values must be in Array | +| > | Integer
Date (UNIX Timestamp) | Greater than | +| < | Integer
Date (UNIX Timestamp) | Lower than | +| ~ | String | Contains | +| !~ | String | Doesn't Contain | +| ^ | String | Starts With | +| $ | String | Ends With | + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const response = await client.contacts.search({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, +}); +for await (const item of response) { + console.log(item); +} + +// Or you can manually iterate page-by-page +const page = await client.contacts.search({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, +}); +while (page.hasNextPage()) { + page = page.getNextPage(); +} +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.SearchRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.contacts.list({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all contacts (ie. users or leads) in your workspace. +{% admonition type="warning" name="Pagination" %} +You can use pagination to limit the number of results returned. The default is `50` results per page. +See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const response = await client.contacts.list(); +for await (const item of response) { + console.log(item); +} + +// Or you can manually iterate page-by-page +const page = await client.contacts.list(); +while (page.hasNextPage()) { + page = page.getNextPage(); +} +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListContactsRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.contacts.create({ ...params }) -> Intercom.Contact +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a new contact (ie. user or lead). + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.create({ + email: "joebloggs@intercom.io", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.contacts.archive({ ...params }) -> Intercom.ContactArchived +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can archive a single contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.archive({ + contact_id: "63a07ddf05a32042dffac965", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ArchiveContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.contacts.unarchive({ ...params }) -> Intercom.ContactUnarchived +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can unarchive a single contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.unarchive({ + contact_id: "63a07ddf05a32042dffac965", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UnarchiveContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Notes + +
client.notes.list({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of notes that are associated to a contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const response = await client.notes.list({ + contact_id: "contact_id", +}); +for await (const item of response) { + console.log(item); +} + +// Or you can manually iterate page-by-page +const page = await client.notes.list({ + contact_id: "contact_id", +}); +while (page.hasNextPage()) { + page = page.getNextPage(); +} +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListContactNotesRequest` + +
+
+ +
+
+ +**requestOptions:** `Notes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.notes.create({ ...params }) -> Intercom.Note +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can add a note to a single contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.notes.create({ + contact_id: "123", + body: "Hello", + admin_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateContactNoteRequest` + +
+
+ +
+
+ +**requestOptions:** `Notes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.notes.find({ ...params }) -> Intercom.Note +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single note. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.notes.find({ + note_id: "1", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindNoteRequest` + +
+
+ +
+
+ +**requestOptions:** `Notes.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Tags + +
client.tags.tagContact({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can tag a specific contact. This will return a tag object for the tag that was added to the contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.tagContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "7522907", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.TagContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.tags.untagContact({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can remove tag from a specific contact. This will return a tag object for the tag that was removed from the contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.untagContact({ + contact_id: "63a07ddf05a32042dffac965", + tag_id: "7522907", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UntagContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.tags.tagConversation({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can tag a specific conversation. This will return a tag object for the tag that was added to the conversation. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.tagConversation({ + conversation_id: "64619700005694", + id: "7522907", + admin_id: "780", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.TagConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.tags.untagConversation({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can remove tag from a specific conversation. This will return a tag object for the tag that was removed from the conversation. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.untagConversation({ + conversation_id: "64619700005694", + tag_id: "7522907", + admin_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UntagConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.tags.list() -> Intercom.TagList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all tags for a given workspace. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.list(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.tags.create({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can use this endpoint to perform the following operations: + +**1. Create a new tag:** You can create a new tag by passing in the tag name as specified in "Create or Update Tag Request Payload" described below. + +**2. Update an existing tag:** You can update an existing tag by passing the id of the tag as specified in "Create or Update Tag Request Payload" described below. + +**3. Tag Companies:** You can tag single company or a list of companies. You can tag a company by passing in the tag name and the company details as specified in "Tag Company Request Payload" described below. Also, if the tag doesn't exist then a new one will be created automatically. + +**4. Untag Companies:** You can untag a single company or a list of companies. You can untag a company by passing in the tag id and the company details as specified in "Untag Company Request Payload" described below. + +**5. Tag Multiple Users:** You can tag a list of users. You can tag the users by passing in the tag name and the user details as specified in "Tag Users Request Payload" described below. + +Each operation will return a tag object. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.create({ + name: "test", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.TagsCreateRequestBody` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.tags.find({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of tags that are on the workspace by their id. +This will return a tag object. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.find({ + tag_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindTagRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.tags.delete({ ...params }) -> void +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete the details of tags that are on the workspace by passing in the id. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.delete({ + tag_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.DeleteTagRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.tags.tagTicket({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can tag a specific ticket. This will return a tag object for the tag that was added to the ticket. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.tagTicket({ + ticket_id: "64619700005694", + id: "7522907", + admin_id: "780", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.TagTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.tags.untagTicket({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can remove tag from a specific ticket. This will return a tag object for the tag that was removed from the ticket. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.untagTicket({ + ticket_id: "64619700005694", + tag_id: "7522907", + admin_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UntagTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Conversations + +
client.conversations.list({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all conversations. + +You can optionally request the result page size and the cursor to start after to fetch the result. +{% admonition type="warning" name="Pagination" %} +You can use pagination to limit the number of results returned. The default is `20` results per page. +See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const response = await client.conversations.list(); +for await (const item of response) { + console.log(item); +} + +// Or you can manually iterate page-by-page +const page = await client.conversations.list(); +while (page.hasNextPage()) { + page = page.getNextPage(); +} +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListConversationsRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.conversations.create({ ...params }) -> Intercom.Message +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a conversation that has been initiated by a contact (ie. user or lead). +The conversation can be an in-app message only. + +{% admonition type="info" name="Sending for visitors" %} +You can also send a message from a visitor by specifying their `user_id` or `id` value in the `from` field, along with a `type` field value of `contact`. +This visitor will be automatically converted to a contact with a lead role once the conversation is created. +{% /admonition %} + +This will return the Message model that has been created. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.create({ + from: { + type: "user", + id: "667d60d18a68186f43bafddd", + }, + body: "Hello there", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.conversations.find({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single conversation. + +This will return a single Conversation model with all its conversation parts. + +{% admonition type="warning" name="Hard limit of 500 parts" %} +The maximum number of conversation parts that can be returned via the API is 500. If you have more than that we will return the 500 most recent conversation parts. +{% /admonition %} + +For AI agent conversation metadata, please note that you need to have the agent enabled in your workspace, which is a [paid feature](https://www.intercom.com/help/en/articles/8205718-fin-resolutions#h_97f8c2e671). + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.find({ + conversation_id: "123", + display_as: "plaintext", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.conversations.update({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update an existing conversation. + +{% admonition type="info" name="Replying and other actions" %} +If you want to reply to a coveration or take an action such as assign, unassign, open, close or snooze, take a look at the reply and manage endpoints. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.update({ + conversation_id: "123", + display_as: "plaintext", + read: true, + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UpdateConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.conversations.search({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can search for multiple conversations by the value of their attributes in order to fetch exactly which ones you want. + +To search for conversations, you need to send a `POST` request to `https://api.intercom.io/conversations/search`. + +This will accept a query object in the body which will define your filters in order to search for conversations. +{% admonition type="warning" name="Optimizing search queries" %} +Search queries can be complex, so optimizing them can help the performance of your search. +Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize +pagination to limit the number of results returned. The default is `20` results per page and maximum is `150`. +See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. +{% /admonition %} + +### Nesting & Limitations + +You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). +There are some limitations to the amount of multiple's there can be: + +- There's a limit of max 2 nested filters +- There's a limit of max 15 filters for each AND or OR group + +### Accepted Fields + +Most keys listed as part of the The conversation model is searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). +The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. + +| Field | Type | +| :---------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------- | +| id | String | +| created_at | Date (UNIX timestamp) | +| updated_at | Date (UNIX timestamp) | +| source.type | String
Accepted fields are `conversation`, `email`, `facebook`, `instagram`, `phone_call`, `phone_switch`, `push`, `sms`, `twitter` and `whatsapp`. | +| source.id | String | +| source.delivered_as | String | +| source.subject | String | +| source.body | String | +| source.author.id | String | +| source.author.type | String | +| source.author.name | String | +| source.author.email | String | +| source.url | String | +| contact_ids | String | +| teammate_ids | String | +| admin_assignee_id | String | +| team_assignee_id | String | +| channel_initiated | String | +| open | Boolean | +| read | Boolean | +| state | String | +| waiting_since | Date (UNIX timestamp) | +| snoozed_until | Date (UNIX timestamp) | +| tag_ids | String | +| priority | String | +| statistics.time_to_assignment | Integer | +| statistics.time_to_admin_reply | Integer | +| statistics.time_to_first_close | Integer | +| statistics.time_to_last_close | Integer | +| statistics.median_time_to_reply | Integer | +| statistics.first_contact_reply_at | Date (UNIX timestamp) | +| statistics.first_assignment_at | Date (UNIX timestamp) | +| statistics.first_admin_reply_at | Date (UNIX timestamp) | +| statistics.first_close_at | Date (UNIX timestamp) | +| statistics.last_assignment_at | Date (UNIX timestamp) | +| statistics.last_assignment_admin_reply_at | Date (UNIX timestamp) | +| statistics.last_contact_reply_at | Date (UNIX timestamp) | +| statistics.last_admin_reply_at | Date (UNIX timestamp) | +| statistics.last_close_at | Date (UNIX timestamp) | +| statistics.last_closed_by_id | String | +| statistics.count_reopens | Integer | +| statistics.count_assignments | Integer | +| statistics.count_conversation_parts | Integer | +| conversation_rating.requested_at | Date (UNIX timestamp) | +| conversation_rating.replied_at | Date (UNIX timestamp) | +| conversation_rating.score | Integer | +| conversation_rating.remark | String | +| conversation_rating.contact_id | String | +| conversation_rating.admin_d | String | +| ai_agent_participated | Boolean | +| ai_agent.resolution_state | String | +| ai_agent.last_answer_type | String | +| ai_agent.rating | Integer | +| ai_agent.rating_remark | String | +| ai_agent.source_type | String | +| ai_agent.source_title | String | + +### Accepted Operators + +The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + +| Operator | Valid Types | Description | +| :------- | :---------------------------- | :--------------------------------------------------------- | +| = | All | Equals | +| != | All | Doesn't Equal | +| IN | All | In Shortcut for `OR` queries Values most be in Array | +| NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | +| > | Integer Date (UNIX Timestamp) | Greater (or equal) than | +| < | Integer Date (UNIX Timestamp) | Lower (or equal) than | +| ~ | String | Contains | +| !~ | String | Doesn't Contain | +| ^ | String | Starts With | +| $ | String | Ends With | + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const response = await client.conversations.search({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, +}); +for await (const item of response) { + console.log(item); +} + +// Or you can manually iterate page-by-page +const page = await client.conversations.search({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, +}); +while (page.hasNextPage()) { + page = page.getNextPage(); +} +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.SearchRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.conversations.reply({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can reply to a conversation with a message from an admin or on behalf of a contact, or with a note for admins. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.reply({ + conversation_id: '123 or "last"', + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "667d60f18a68186f43bafdf4", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ReplyToConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.conversations.manage({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +For managing conversations you can: + +- Close a conversation +- Snooze a conversation to reopen on a future date +- Open a conversation which is `snoozed` or `closed` +- Assign a conversation to an admin and/or team. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.manage({ + conversation_id: "123", + body: { + message_type: "assignment", + type: "admin", + admin_id: "12345", + assignee_id: "4324241", + body: "Goodbye :)", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ManageConversationPartsRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.conversations.runAssignmentRules({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can let a conversation be automatically assigned following assignment rules. +{% admonition type="attention" name="When using workflows" %} +It is not possible to use this endpoint with Workflows. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.runAssignmentRules({ + conversation_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.AutoAssignConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.conversations.attachContactAsAdmin({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. + +{% admonition type="attention" name="Contacts without an email" %} +If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.attachContactAsAdmin({ + conversation_id: "123", + admin_id: "12345", + customer: { + intercom_user_id: "667d61168a68186f43bafe0d", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.AttachContactToConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.conversations.detachContactAsAdmin({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. + +{% admonition type="attention" name="Contacts without an email" %} +If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.detachContactAsAdmin({ + conversation_id: "123", + contact_id: "123", + admin_id: "5017690", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.DetachContactFromConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.conversations.redactConversationPart({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can redact a conversation part or the source message of a conversation (as seen in the source object). + +{% admonition type="info" name="Redacting parts and messages" %} +If you are redacting a conversation part, it must have a `body`. If you are redacting a source message, it must have been created by a contact. We will return a `conversation_part_not_redactable` error if these criteria are not met. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.redactConversationPart({ + type: "conversation_part", + conversation_id: "19894788788", + conversation_part_id: "19381789428", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.RedactConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.conversations.convertToTicket({ ...params }) -> Intercom.Ticket +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can convert a conversation to a ticket. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.convertToTicket({ + conversation_id: "123", + ticket_type_id: "79", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ConvertConversationToTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Data Attributes + +
client.dataAttributes.list({ ...params }) -> Intercom.DataAttributeList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all data attributes belonging to a workspace for contacts, companies or conversations. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.dataAttributes.list(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListDataAttributesRequest` + +
+
+ +
+
+ +**requestOptions:** `DataAttributes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.dataAttributes.create({ ...params }) -> Intercom.DataAttribute +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a data attributes for a `contact` or a `company`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.dataAttributes.create({ + name: "Mithril Shirt", + model: "company", + data_type: "string", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateDataAttributeRequest` + +
+
+ +
+
+ +**requestOptions:** `DataAttributes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.dataAttributes.update({ ...params }) -> Intercom.DataAttribute +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update a data attribute. + +> 🚧 Updating the data type is not possible +> +> It is currently a dangerous action to execute changing a data attribute's type via the API. You will need to update the type via the UI instead. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.dataAttributes.update({ + data_attribute_id: "1", + archived: false, + description: "Just a plain old ring", + options: [ + { + value: "1-10", + }, + { + value: "11-20", + }, + ], +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UpdateDataAttributeRequest` + +
+
+ +
+
+ +**requestOptions:** `DataAttributes.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Events + +
client.events.list({ ...params }) -> Intercom.DataEventSummary +
+
+ +#### 📝 Description + +
+
+ +
+
+ +> 🚧 +> +> Please note that you can only 'list' events that are less than 90 days old. Event counts and summaries will still include your events older than 90 days but you cannot 'list' these events individually if they are older than 90 days + +The events belonging to a customer can be listed by sending a GET request to `https://api.intercom.io/events` with a user or lead identifier along with a `type` parameter. The identifier parameter can be one of `user_id`, `email` or `intercom_user_id`. The `type` parameter value must be `user`. + +- `https://api.intercom.io/events?type=user&user_id={user_id}` +- `https://api.intercom.io/events?type=user&email={email}` +- `https://api.intercom.io/events?type=user&intercom_user_id={id}` (this call can be used to list leads) + +The `email` parameter value should be [url encoded](http://en.wikipedia.org/wiki/Percent-encoding) when sending. + +You can optionally define the result page size as well with the `per_page` parameter. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.events.list({ + type: "type", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListEventsRequest` + +
+
+ +
+
+ +**requestOptions:** `Events.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.events.create({ ...params }) -> void +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You will need an Access Token that has write permissions to send Events. Once you have a key you can submit events via POST to the Events resource, which is located at https://api.intercom.io/events, or you can send events using one of the client libraries. When working with the HTTP API directly a client should send the event with a `Content-Type` of `application/json`. + +When using the JavaScript API, [adding the code to your app](http://docs.intercom.io/configuring-Intercom/tracking-user-events-in-your-app) makes the Events API available. Once added, you can submit an event using the `trackEvent` method. This will associate the event with the Lead or currently logged-in user or logged-out visitor/lead and send it to Intercom. The final parameter is a map that can be used to send optional metadata about the event. + +With the Ruby client you pass a hash describing the event to `Intercom::Event.create`, or call the `track_user` method directly on the current user object (e.g. `user.track_event`). + +**NB: For the JSON object types, please note that we do not currently support nested JSON structure.** + +| Type | Description | Example | +| :-------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------- | +| String | The value is a JSON String | `"source":"desktop"` | +| Number | The value is a JSON Number | `"load": 3.67` | +| Date | The key ends with the String `_date` and the value is a [Unix timestamp](http://en.wikipedia.org/wiki/Unix_time), assumed to be in the [UTC](http://en.wikipedia.org/wiki/Coordinated_Universal_Time) timezone. | `"contact_date": 1392036272` | +| Link | The value is a HTTP or HTTPS URI. | `"article": "https://example.org/ab1de.html"` | +| Rich Link | The value is a JSON object that contains `url` and `value` keys. | `"article": {"url": "https://example.org/ab1de.html", "value":"the dude abides"}` | +| Monetary Amount | The value is a JSON object that contains `amount` and `currency` keys. The `amount` key is a positive integer representing the amount in cents. The price in the example to the right denotes €349.99. | `"price": {"amount": 34999, "currency": "eur"}` | + +**Lead Events** + +When submitting events for Leads, you will need to specify the Lead's `id`. + +**Metadata behaviour** + +- We currently limit the number of tracked metadata keys to 10 per event. Once the quota is reached, we ignore any further keys we receive. The first 10 metadata keys are determined by the order in which they are sent in with the event. +- It is not possible to change the metadata keys once the event has been sent. A new event will need to be created with the new keys and you can archive the old one. +- There might be up to 24 hrs delay when you send a new metadata for an existing event. + +**Event de-duplication** + +The API may detect and ignore duplicate events. Each event is uniquely identified as a combination of the following data - the Workspace identifier, the Contact external identifier, the Data Event name and the Data Event created time. As a result, it is **strongly recommended** to send a second granularity Unix timestamp in the `created_at` field. + +Duplicated events are responded to using the normal `202 Accepted` code - an error is not thrown, however repeat requests will be counted against any rate limit that is in place. + +### HTTP API Responses + +- Successful responses to submitted events return `202 Accepted` with an empty body. +- Unauthorised access will be rejected with a `401 Unauthorized` or `403 Forbidden` response code. +- Events sent about users that cannot be found will return a `404 Not Found`. +- Event lists containing duplicate events will have those duplicates ignored. +- Server errors will return a `500` response code and may contain an error message in the body. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.events.create({ + id: "8a88a590-e1c3-41e2-a502-e0649dbf721c", + event_name: "invited-friend", + created_at: 1671028894, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateDataEventRequest` + +
+
+ +
+
+ +**requestOptions:** `Events.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.events.summaries({ ...params }) -> void +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Create event summaries for a user. Event summaries are used to track the number of times an event has occurred, the first time it occurred and the last time it occurred. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.events.summaries(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListEventSummariesRequest` + +
+
+ +
+
+ +**requestOptions:** `Events.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Data Export + +
client.dataExport.create({ ...params }) -> Intercom.DataExport +
+
+ +#### 📝 Description + +
+
+ +
+
+ +To create your export job, you need to send a `POST` request to the export endpoint `https://api.intercom.io/export/content/data`. + +The only parameters you need to provide are the range of dates that you want exported. + +> 🚧 Limit of one active job +> +> You can only have one active job per workspace. You will receive a HTTP status code of 429 with the message Exceeded rate limit of 1 pending message data export jobs if you attempt to create a second concurrent job. + +> ❗️ Updated_at not included +> +> It should be noted that the timeframe only includes messages sent during the time period and not messages that were only updated during this period. For example, if a message was updated yesterday but sent two days ago, you would need to set the created_at_after date before the message was sent to include that in your retrieval job. + +> 📘 Date ranges are inclusive +> +> Requesting data for 2018-06-01 until 2018-06-30 will get all data for those days including those specified - e.g. 2018-06-01 00:00:00 until 2018-06-30 23:59:99. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.dataExport.create({ + created_at_after: 1719474967, + created_at_before: 1719492967, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateDataExportRequest` + +
+
+ +
+
+ +**requestOptions:** `DataExport.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.dataExport.find({ ...params }) -> Intercom.DataExport +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can view the status of your job by sending a `GET` request to the URL +`https://api.intercom.io/export/content/data/{job_identifier}` - the `{job_identifier}` is the value returned in the response when you first created the export job. More on it can be seen in the Export Job Model. + +> 🚧 Jobs expire after two days +> All jobs that have completed processing (and are thus available to download from the provided URL) will have an expiry limit of two days from when the export ob completed. After this, the data will no longer be available. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.dataExport.find({ + job_identifier: "job_identifier", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindDataExportRequest` + +
+
+ +
+
+ +**requestOptions:** `DataExport.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.dataExport.cancel({ ...params }) -> Intercom.DataExport +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can cancel your job + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.dataExport.cancel({ + job_identifier: "job_identifier", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CancelDataExportRequest` + +
+
+ +
+
+ +**requestOptions:** `DataExport.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.dataExport.download({ ...params }) -> void +
+
+ +#### 📝 Description + +
+
+ +
+
+ +When a job has a status of complete, and thus a filled download_url, you can download your data by hitting that provided URL, formatted like so: https://api.intercom.io/download/content/data/xyz1234. + +Your exported message data will be streamed continuously back down to you in a gzipped CSV format. + +> 📘 Octet header required +> +> You will have to specify the header Accept: `application/octet-stream` when hitting this endpoint. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.dataExport.download({ + job_identifier: "job_identifier", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.DownloadDataExportRequest` + +
+
+ +
+
+ +**requestOptions:** `DataExport.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Messages + +
client.messages.create({ ...params }) -> Intercom.Message +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a message that has been initiated by an admin. The conversation can be either an in-app message or an email. + +> 🚧 Sending for visitors +> +> There can be a short delay between when a contact is created and when a contact becomes available to be messaged through the API. A 404 Not Found error will be returned in this case. + +This will return the Message model that has been created. + +> 🚧 Retrieving Associated Conversations +> +> As this is a message, there will be no conversation present until the contact responds. Once they do, you will have to search for a contact's conversations with the id of the message. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.messages.create({ + message_type: "inapp", + subject: "Thanks for everything", + body: "heyy", + template: "plain", + from: { + type: "admin", + id: 394051, + }, + to: { + type: "user", + id: "536e564f316c83104c000020", + }, + created_at: 1590000000, + create_conversation_without_contact_reply: true, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateMessageRequest` + +
+
+ +
+
+ +**requestOptions:** `Messages.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Segments + +
client.segments.list({ ...params }) -> Intercom.SegmentList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all segments. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.segments.list(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListSegmentsRequest` + +
+
+ +
+
+ +**requestOptions:** `Segments.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.segments.find({ ...params }) -> Intercom.Segment +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single segment. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.segments.find({ + segment_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindSegmentRequest` + +
+
+ +
+
+ +**requestOptions:** `Segments.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Subscription Types + +
client.subscriptionTypes.list() -> Intercom.SubscriptionTypeList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can list all subscription types. A list of subscription type objects will be returned. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.subscriptionTypes.list(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `SubscriptionTypes.RequestOptions` + +
+
+
+
+ +
+
+
+ +## PhoneCallRedirects + +
client.phoneCallRedirects.create({ ...params }) -> Intercom.PhoneSwitch +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can use the API to deflect phone calls to the Intercom Messenger. +Calling this endpoint will send an SMS with a link to the Messenger to the phone number specified. + +If custom attributes are specified, they will be added to the user or lead's custom data attributes. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.phoneCallRedirects.create({ + phone: "+353832345678", + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreatePhoneCallRedirectRequest` + +
+
+ +
+
+ +**requestOptions:** `PhoneCallRedirects.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Teams + +
client.teams.list() -> Intercom.TeamList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +This will return a list of team objects for the App. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.teams.list(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Teams.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.teams.find({ ...params }) -> Intercom.Team +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single team, containing an array of admins that belong to this team. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.teams.find({ + team_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindTeamRequest` + +
+
+ +
+
+ +**requestOptions:** `Teams.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Ticket Types + +
client.ticketTypes.list() -> Intercom.TicketTypeList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can get a list of all ticket types for a workspace. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ticketTypes.list(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `TicketTypes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.ticketTypes.create({ ...params }) -> Intercom.TicketType +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a new ticket type. + +> 📘 Creating ticket types. +> +> Every ticket type will be created with two default attributes: _default_title_ and _default_description_. +> For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ticketTypes.create({ + name: "Customer Issue", + description: "Customer Report Template", + category: "Customer", + icon: "\uD83C\uDF9F\uFE0F", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateTicketTypeRequest` + +
+
+ +
+
+ +**requestOptions:** `TicketTypes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.ticketTypes.get({ ...params }) -> Intercom.TicketType +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single ticket type. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ticketTypes.get({ + ticket_type_id: "ticket_type_id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindTicketTypeRequest` + +
+
+ +
+
+ +**requestOptions:** `TicketTypes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.ticketTypes.update({ ...params }) -> Intercom.TicketType +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update a ticket type. + +> 📘 Updating a ticket type. +> +> For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ticketTypes.update({ + ticket_type_id: "ticket_type_id", + name: "Bug Report 2", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UpdateTicketTypeRequest` + +
+
+ +
+
+ +**requestOptions:** `TicketTypes.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Tickets + +
client.tickets.reply({ ...params }) -> Intercom.TicketReply +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can reply to a ticket with a message from an admin or on behalf of a contact, or with a note for admins. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tickets.reply({ + ticket_id: "123", + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "667d619d8a68186f43bafe82", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ReplyToTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Tickets.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.tickets.create({ ...params }) -> Intercom.Ticket +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a new ticket. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tickets.create({ + ticket_type_id: "1234", + contacts: [ + { + id: "667d61b78a68186f43bafe8d", + }, + ], + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Tickets.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.tickets.get({ ...params }) -> Intercom.Ticket +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single ticket. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tickets.get({ + ticket_id: "ticket_id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Tickets.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.tickets.update({ ...params }) -> Intercom.Ticket +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update a ticket. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tickets.update({ + ticket_id: "ticket_id", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + state: "in_progress", + open: true, + snoozed_until: 1673609604, + assignment: { + admin_id: "991267883", + assignee_id: "991267885", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UpdateTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Tickets.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.tickets.search({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can search for multiple tickets by the value of their attributes in order to fetch exactly which ones you want. + +To search for tickets, you send a `POST` request to `https://api.intercom.io/tickets/search`. + +This will accept a query object in the body which will define your filters. +{% admonition type="warning" name="Optimizing search queries" %} +Search queries can be complex, so optimizing them can help the performance of your search. +Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize +pagination to limit the number of results returned. The default is `20` results per page. +See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. +{% /admonition %} + +### Nesting & Limitations + +You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). +There are some limitations to the amount of multiples there can be: + +- There's a limit of max 2 nested filters +- There's a limit of max 15 filters for each AND or OR group + +### Accepted Fields + +Most keys listed as part of the Ticket model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foobar"`). + +| Field | Type | +| :-------------------- | :------------------------------------------------------------- | +| id | String | +| created_at | Date (UNIX timestamp) | +| updated_at | Date (UNIX timestamp) | +| _default_title_ | String | +| _default_description_ | String | +| category | String | +| ticket_type_id | String | +| contact_ids | String | +| teammate_ids | String | +| admin_assignee_id | String | +| team_assignee_id | String | +| open | Boolean | +| state | String | +| snoozed_until | Date (UNIX timestamp) | +| ticket_attribute.{id} | String or Boolean or Date (UNIX timestamp) or Float or Integer | + +### Accepted Operators + +{% admonition type="info" name="Searching based on `created_at`" %} +You may use the `<=` or `>=` operators to search by `created_at`. +{% /admonition %} + +The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + +| Operator | Valid Types | Description | +| :------- | :---------------------------- | :--------------------------------------------------------- | +| = | All | Equals | +| != | All | Doesn't Equal | +| IN | All | In Shortcut for `OR` queries Values most be in Array | +| NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | +| > | Integer Date (UNIX Timestamp) | Greater (or equal) than | +| < | Integer Date (UNIX Timestamp) | Lower (or equal) than | +| ~ | String | Contains | +| !~ | String | Doesn't Contain | +| ^ | String | Starts With | +| $ | String | Ends With | + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const response = await client.tickets.search({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, +}); +for await (const item of response) { + console.log(item); +} + +// Or you can manually iterate page-by-page +const page = await client.tickets.search({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, +}); +while (page.hasNextPage()) { + page = page.getNextPage(); +} +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.SearchRequest` + +
+
+ +
+
+ +**requestOptions:** `Tickets.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Visitors + +
client.visitors.find({ ...params }) -> Intercom.Visitor +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single visitor. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.visitors.find({ + user_id: "user_id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindVisitorRequest` + +
+
+ +
+
+ +**requestOptions:** `Visitors.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.visitors.update({ ...params }) -> Intercom.Visitor +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Sending a PUT request to `/visitors` will result in an update of an existing Visitor. + +**Option 1.** You can update a visitor by passing in the `user_id` of the visitor in the Request body. + +**Option 2.** You can update a visitor by passing in the `id` of the visitor in the Request body. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.visitors.update({ + id: "667d61cc8a68186f43bafe95", + name: "Gareth Bale", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UpdateVisitorRequest` + +
+
+ +
+
+ +**requestOptions:** `Visitors.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.visitors.mergeToContact({ ...params }) -> Intercom.Contact +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can merge a Visitor to a Contact of role type `lead` or `user`. + +> 📘 What happens upon a visitor being converted? +> +> If the User exists, then the Visitor will be merged into it, the Visitor deleted and the User returned. If the User does not exist, the Visitor will be converted to a User, with the User identifiers replacing it's Visitor identifiers. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.visitors.mergeToContact({ + type: "user", + user: { + id: "8a88a590-e1c3-41e2-a502-e0649dbf721c", + email: "foo@bar.com", + }, + visitor: { + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.MergeVisitorToContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Visitors.RequestOptions` + +
+
+
+
+ +
+
+
+ +## HelpCenters Collections + +
client.helpCenters.collections.list({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all collections by making a GET request to `https://api.intercom.io/help_center/collections`. + +Collections will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated collections first. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const response = await client.helpCenters.collections.list(); +for await (const item of response) { + console.log(item); +} + +// Or you can manually iterate page-by-page +const page = await client.helpCenters.collections.list(); +while (page.hasNextPage()) { + page = page.getNextPage(); +} +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.helpCenters.ListCollectionsRequest` + +
+
+ +
+
+ +**requestOptions:** `Collections.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.helpCenters.collections.create({ ...params }) -> Intercom.Collection +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a new collection by making a POST request to `https://api.intercom.io/help_center/collections.` + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.helpCenters.collections.create({ + name: "Thanks for everything", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.helpCenters.CreateCollectionRequest` + +
+
+ +
+
+ +**requestOptions:** `Collections.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.helpCenters.collections.find({ ...params }) -> Intercom.Collection +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single collection by making a GET request to `https://api.intercom.io/help_center/collections/`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.helpCenters.collections.find({ + collection_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.helpCenters.FindCollectionRequest` + +
+
+ +
+
+ +**requestOptions:** `Collections.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.helpCenters.collections.update({ ...params }) -> Intercom.Collection +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update the details of a single collection by making a PUT request to `https://api.intercom.io/collections/`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.helpCenters.collections.update({ + collection_id: "123", + name: "Update collection name", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.helpCenters.UpdateCollectionRequest` + +
+
+ +
+
+ +**requestOptions:** `Collections.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.helpCenters.collections.delete({ ...params }) -> Intercom.DeletedCollectionObject +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete a single collection by making a DELETE request to `https://api.intercom.io/collections/`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.helpCenters.collections.delete({ + collection_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.helpCenters.DeleteCollectionRequest` + +
+
+ +
+
+ +**requestOptions:** `Collections.RequestOptions` + +
+
+
+
+ +
+
+
+ +## News Items + +
client.news.items.list() -> Intercom.PaginatedNewsItemResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all news items + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.news.items.list(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Items.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.news.items.create({ ...params }) -> Intercom.NewsItem +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a news item + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.news.items.create({ + title: "Halloween is here!", + body: "

New costumes in store for this spooky season

", + sender_id: 991267734, + state: "live", + deliver_silently: true, + labels: ["Product", "Update", "New"], + reactions: ["\uD83D\uDE06", "\uD83D\uDE05"], + newsfeed_assignments: [ + { + newsfeed_id: 53, + published_at: 1664638214, + }, + ], +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.NewsItemRequest` + +
+
+ +
+
+ +**requestOptions:** `Items.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.news.items.find({ ...params }) -> Intercom.NewsItem +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single news item. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.news.items.find({ + news_item_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.news.FindNewsItemRequest` + +
+
+ +
+
+ +**requestOptions:** `Items.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.news.items.update({ ...params }) -> Intercom.NewsItem +
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.news.items.update({ + news_item_id: "123", + body: { + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267745, + reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"], + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.news.UpdateNewsItemRequest` + +
+
+ +
+
+ +**requestOptions:** `Items.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.news.items.delete({ ...params }) -> Intercom.DeletedObject +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete a single news item. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.news.items.delete({ + news_item_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.news.DeleteNewsItemRequest` + +
+
+ +
+
+ +**requestOptions:** `Items.RequestOptions` + +
+
+
+
+ +
+
+
+ +## News Feeds + +
client.news.feeds.listItems({ ...params }) -> Intercom.PaginatedNewsItemResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all news items that are live on a given newsfeed + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.news.feeds.listItems({ + newsfeed_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.news.ListNewsFeedItemsRequest` + +
+
+ +
+
+ +**requestOptions:** `Feeds.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.news.feeds.list() -> Intercom.PaginatedNewsfeedResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all newsfeeds + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.news.feeds.list(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Feeds.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.news.feeds.find({ ...params }) -> Intercom.Newsfeed +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single newsfeed + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.news.feeds.find({ + newsfeed_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.news.FindNewsFeedRequest` + +
+
+ +
+
+ +**requestOptions:** `Feeds.RequestOptions` + +
+
+
+
+ +
+
+
+ +## TicketTypes Attributes + +
client.ticketTypes.attributes.create({ ...params }) -> Intercom.TicketTypeAttribute +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a new attribute for a ticket type. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ticketTypes.attributes.create({ + ticket_type_id: "ticket_type_id", + name: "Attribute Title", + description: "Attribute Description", + data_type: "string", + required_to_create: false, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ticketTypes.CreateTicketTypeAttributeRequest` + +
+
+ +
+
+ +**requestOptions:** `Attributes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.ticketTypes.attributes.update({ ...params }) -> Intercom.TicketTypeAttribute +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update an existing attribute for a ticket type. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ticketTypes.attributes.update({ + ticket_type_id: "ticket_type_id", + attribute_id: "attribute_id", + description: "New Attribute Description", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ticketTypes.UpdateTicketTypeAttributeRequest` + +
+
+ +
+
+ +**requestOptions:** `Attributes.RequestOptions` + +
+
+
+
+ +
+
+
diff --git a/src/Client.ts b/src/Client.ts new file mode 100644 index 00000000..3559a154 --- /dev/null +++ b/src/Client.ts @@ -0,0 +1,190 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "./environments"; +import * as core from "./core"; +import { Admins } from "./api/resources/admins/client/Client"; +import { Articles } from "./api/resources/articles/client/Client"; +import { HelpCenters } from "./api/resources/helpCenters/client/Client"; +import { Companies } from "./api/resources/companies/client/Client"; +import { Contacts } from "./api/resources/contacts/client/Client"; +import { Notes } from "./api/resources/notes/client/Client"; +import { Tags } from "./api/resources/tags/client/Client"; +import { Conversations } from "./api/resources/conversations/client/Client"; +import { DataAttributes } from "./api/resources/dataAttributes/client/Client"; +import { Events } from "./api/resources/events/client/Client"; +import { DataExport } from "./api/resources/dataExport/client/Client"; +import { Messages } from "./api/resources/messages/client/Client"; +import { Segments } from "./api/resources/segments/client/Client"; +import { SubscriptionTypes } from "./api/resources/subscriptionTypes/client/Client"; +import { PhoneCallRedirects } from "./api/resources/phoneCallRedirects/client/Client"; +import { Teams } from "./api/resources/teams/client/Client"; +import { TicketTypes } from "./api/resources/ticketTypes/client/Client"; +import { Tickets } from "./api/resources/tickets/client/Client"; +import { Visitors } from "./api/resources/visitors/client/Client"; +import { News } from "./api/resources/news/client/Client"; + +export declare namespace IntercomClient { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +export class IntercomClient { + protected _admins: Admins | undefined; + protected _articles: Articles | undefined; + protected _helpCenters: HelpCenters | undefined; + protected _companies: Companies | undefined; + protected _contacts: Contacts | undefined; + protected _notes: Notes | undefined; + protected _tags: Tags | undefined; + protected _conversations: Conversations | undefined; + protected _dataAttributes: DataAttributes | undefined; + protected _events: Events | undefined; + protected _dataExport: DataExport | undefined; + protected _messages: Messages | undefined; + protected _segments: Segments | undefined; + protected _subscriptionTypes: SubscriptionTypes | undefined; + protected _phoneCallRedirects: PhoneCallRedirects | undefined; + protected _teams: Teams | undefined; + protected _ticketTypes: TicketTypes | undefined; + protected _tickets: Tickets | undefined; + protected _visitors: Visitors | undefined; + protected _news: News | undefined; + + constructor(protected readonly _options: IntercomClient.Options = {}) {} + + public get admins(): Admins { + return (this._admins ??= new Admins(this._options)); + } + + public get articles(): Articles { + return (this._articles ??= new Articles(this._options)); + } + + public get helpCenters(): HelpCenters { + return (this._helpCenters ??= new HelpCenters(this._options)); + } + + public get companies(): Companies { + return (this._companies ??= new Companies(this._options)); + } + + public get contacts(): Contacts { + return (this._contacts ??= new Contacts(this._options)); + } + + public get notes(): Notes { + return (this._notes ??= new Notes(this._options)); + } + + public get tags(): Tags { + return (this._tags ??= new Tags(this._options)); + } + + public get conversations(): Conversations { + return (this._conversations ??= new Conversations(this._options)); + } + + public get dataAttributes(): DataAttributes { + return (this._dataAttributes ??= new DataAttributes(this._options)); + } + + public get events(): Events { + return (this._events ??= new Events(this._options)); + } + + public get dataExport(): DataExport { + return (this._dataExport ??= new DataExport(this._options)); + } + + public get messages(): Messages { + return (this._messages ??= new Messages(this._options)); + } + + public get segments(): Segments { + return (this._segments ??= new Segments(this._options)); + } + + public get subscriptionTypes(): SubscriptionTypes { + return (this._subscriptionTypes ??= new SubscriptionTypes(this._options)); + } + + public get phoneCallRedirects(): PhoneCallRedirects { + return (this._phoneCallRedirects ??= new PhoneCallRedirects(this._options)); + } + + public get teams(): Teams { + return (this._teams ??= new Teams(this._options)); + } + + public get ticketTypes(): TicketTypes { + return (this._ticketTypes ??= new TicketTypes(this._options)); + } + + public get tickets(): Tickets { + return (this._tickets ??= new Tickets(this._options)); + } + + public get visitors(): Visitors { + return (this._visitors ??= new Visitors(this._options)); + } + + public get news(): News { + return (this._news ??= new News(this._options)); + } +} diff --git a/src/api/errors/BadRequestError.ts b/src/api/errors/BadRequestError.ts new file mode 100644 index 00000000..34319f60 --- /dev/null +++ b/src/api/errors/BadRequestError.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as errors from "../../errors/index"; + +export class BadRequestError extends errors.IntercomError { + constructor(body?: unknown) { + super({ + message: "BadRequestError", + statusCode: 400, + body: body, + }); + Object.setPrototypeOf(this, BadRequestError.prototype); + } +} diff --git a/src/api/errors/ForbiddenError.ts b/src/api/errors/ForbiddenError.ts new file mode 100644 index 00000000..733bdc33 --- /dev/null +++ b/src/api/errors/ForbiddenError.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as errors from "../../errors/index"; +import * as Intercom from "../index"; + +export class ForbiddenError extends errors.IntercomError { + constructor(body: Intercom.Error_) { + super({ + message: "ForbiddenError", + statusCode: 403, + body: body, + }); + Object.setPrototypeOf(this, ForbiddenError.prototype); + } +} diff --git a/src/api/errors/NotFoundError.ts b/src/api/errors/NotFoundError.ts new file mode 100644 index 00000000..27ed057b --- /dev/null +++ b/src/api/errors/NotFoundError.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as errors from "../../errors/index"; + +export class NotFoundError extends errors.IntercomError { + constructor(body?: unknown) { + super({ + message: "NotFoundError", + statusCode: 404, + body: body, + }); + Object.setPrototypeOf(this, NotFoundError.prototype); + } +} diff --git a/src/api/errors/UnauthorizedError.ts b/src/api/errors/UnauthorizedError.ts new file mode 100644 index 00000000..dcbab95b --- /dev/null +++ b/src/api/errors/UnauthorizedError.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as errors from "../../errors/index"; +import * as Intercom from "../index"; + +export class UnauthorizedError extends errors.IntercomError { + constructor(body: Intercom.Error_) { + super({ + message: "UnauthorizedError", + statusCode: 401, + body: body, + }); + Object.setPrototypeOf(this, UnauthorizedError.prototype); + } +} diff --git a/src/api/errors/UnprocessableEntityError.ts b/src/api/errors/UnprocessableEntityError.ts new file mode 100644 index 00000000..ac84eaf2 --- /dev/null +++ b/src/api/errors/UnprocessableEntityError.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as errors from "../../errors/index"; + +export class UnprocessableEntityError extends errors.IntercomError { + constructor(body?: unknown) { + super({ + message: "UnprocessableEntityError", + statusCode: 422, + body: body, + }); + Object.setPrototypeOf(this, UnprocessableEntityError.prototype); + } +} diff --git a/src/api/errors/index.ts b/src/api/errors/index.ts new file mode 100644 index 00000000..f81dc80f --- /dev/null +++ b/src/api/errors/index.ts @@ -0,0 +1,5 @@ +export * from "./UnauthorizedError"; +export * from "./NotFoundError"; +export * from "./BadRequestError"; +export * from "./ForbiddenError"; +export * from "./UnprocessableEntityError"; diff --git a/src/api/index.ts b/src/api/index.ts new file mode 100644 index 00000000..fefdd8f9 --- /dev/null +++ b/src/api/index.ts @@ -0,0 +1,4 @@ +export * from "./resources"; +export * from "./types"; +export * from "./errors"; +export { IntercomVersion } from "./version"; diff --git a/src/api/resources/admins/client/Client.ts b/src/api/resources/admins/client/Client.ts new file mode 100644 index 00000000..05d639d7 --- /dev/null +++ b/src/api/resources/admins/client/Client.ts @@ -0,0 +1,447 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace Admins { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Admins + */ +export class Admins { + constructor(protected readonly _options: Admins.Options = {}) {} + + /** + * + * You can view the currently authorised admin along with the embedded app object (a "workspace" in legacy terminology). + * + * > 🚧 Single Sign On + * > + * > If you are building a custom "Log in with Intercom" flow for your site, and you call the `/me` endpoint to identify the logged-in user, you should not accept any sign-ins from users with unverified email addresses as it poses a potential impersonation security risk. + * + * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.admins.identify() + */ + public async identify(requestOptions?: Admins.RequestOptions): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "me" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.AdminWithApp; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /me."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can set an Admin as away for the Inbox. + * + * @param {Intercom.ConfigureAwayAdminRequest} request + * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.admins.away({ + * admin_id: "admin_id", + * away_mode_enabled: true, + * away_mode_reassign: true + * }) + */ + public async away( + request: Intercom.ConfigureAwayAdminRequest, + requestOptions?: Admins.RequestOptions + ): Promise { + const { admin_id: adminId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `admins/${encodeURIComponent(adminId)}/away` + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Admin; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /admins/{admin_id}/away."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can get a log of activities by all admins in an app. + * + * @param {Intercom.ListAllActivityLogsRequest} request + * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.admins.listAllActivityLogs({ + * created_at_after: "1677253093", + * created_at_before: "1677861493" + * }) + */ + public async listAllActivityLogs( + request: Intercom.ListAllActivityLogsRequest, + requestOptions?: Admins.RequestOptions + ): Promise { + const { created_at_after: createdAtAfter, created_at_before: createdAtBefore } = request; + const _queryParams: Record = {}; + _queryParams["created_at_after"] = createdAtAfter; + if (createdAtBefore != null) { + _queryParams["created_at_before"] = createdAtBefore; + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "admins/activity_logs" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.ActivityLogList; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins/activity_logs."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch a list of admins for a given workspace. + * + * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.admins.list() + */ + public async list(requestOptions?: Admins.RequestOptions): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "admins" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.AdminList; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can retrieve the details of a single admin. + * + * @param {Intercom.FindAdminRequest} request + * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.admins.find({ + * admin_id: "123" + * }) + */ + public async find( + request: Intercom.FindAdminRequest, + requestOptions?: Admins.RequestOptions + ): Promise { + const { admin_id: adminId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `admins/${encodeURIComponent(adminId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Admin; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins/{admin_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/admins/client/index.ts b/src/api/resources/admins/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/admins/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/admins/client/requests/ConfigureAwayAdminRequest.ts b/src/api/resources/admins/client/requests/ConfigureAwayAdminRequest.ts new file mode 100644 index 00000000..524d1a23 --- /dev/null +++ b/src/api/resources/admins/client/requests/ConfigureAwayAdminRequest.ts @@ -0,0 +1,36 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * admin_id: "admin_id", + * away_mode_enabled: true, + * away_mode_reassign: true + * } + * + * @example + * { + * admin_id: "admin_id", + * away_mode_enabled: true, + * away_mode_reassign: true + * } + * + * @example + * { + * admin_id: "admin_id", + * away_mode_enabled: true, + * away_mode_reassign: true + * } + */ +export interface ConfigureAwayAdminRequest { + /** + * The unique identifier of a given admin + */ + admin_id: string; + /** Set to "true" to change the status of the admin to away. */ + away_mode_enabled: boolean; + /** Set to "true" to assign any new conversation replies to your default inbox. */ + away_mode_reassign: boolean; +} diff --git a/src/api/resources/admins/client/requests/FindAdminRequest.ts b/src/api/resources/admins/client/requests/FindAdminRequest.ts new file mode 100644 index 00000000..85d66282 --- /dev/null +++ b/src/api/resources/admins/client/requests/FindAdminRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * admin_id: "123" + * } + */ +export interface FindAdminRequest { + /** + * The unique identifier of a given admin + */ + admin_id: string; +} diff --git a/src/api/resources/admins/client/requests/ListAllActivityLogsRequest.ts b/src/api/resources/admins/client/requests/ListAllActivityLogsRequest.ts new file mode 100644 index 00000000..1379e86e --- /dev/null +++ b/src/api/resources/admins/client/requests/ListAllActivityLogsRequest.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * created_at_after: "1677253093", + * created_at_before: "1677861493" + * } + */ +export interface ListAllActivityLogsRequest { + /** + * The start date that you request data for. It must be formatted as a UNIX timestamp. + */ + created_at_after: string; + /** + * The end date that you request data for. It must be formatted as a UNIX timestamp. + */ + created_at_before?: string; +} diff --git a/src/api/resources/admins/client/requests/index.ts b/src/api/resources/admins/client/requests/index.ts new file mode 100644 index 00000000..bf3a8602 --- /dev/null +++ b/src/api/resources/admins/client/requests/index.ts @@ -0,0 +1,3 @@ +export { type ConfigureAwayAdminRequest } from "./ConfigureAwayAdminRequest"; +export { type ListAllActivityLogsRequest } from "./ListAllActivityLogsRequest"; +export { type FindAdminRequest } from "./FindAdminRequest"; diff --git a/src/api/resources/admins/index.ts b/src/api/resources/admins/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/admins/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/admins/types/Admin.ts b/src/api/resources/admins/types/Admin.ts new file mode 100644 index 00000000..0551b7d5 --- /dev/null +++ b/src/api/resources/admins/types/Admin.ts @@ -0,0 +1,32 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Admins are teammate accounts that have access to a workspace. + */ +export interface Admin { + /** String representing the object's type. Always has the value `admin`. */ + type?: "admin"; + /** The id representing the admin. */ + id: string; + /** The name of the admin. */ + name: string; + /** The email of the admin. */ + email: string; + /** The job title of the admin. */ + job_title: string; + /** Identifies if this admin is currently set in away mode. */ + away_mode_enabled: boolean; + /** Identifies if this admin is set to automatically reassign new conversations to the apps default inbox. */ + away_mode_reassign: boolean; + /** Identifies if this admin has a paid inbox seat to restrict/allow features that require them. */ + has_inbox_seat: boolean; + /** This object represents the avatar associated with the admin. */ + team_ids: number[]; + /** Image for the associated team or teammate */ + avatar?: string; + team_priority_level?: Intercom.TeamPriorityLevel; +} diff --git a/src/api/resources/admins/types/index.ts b/src/api/resources/admins/types/index.ts new file mode 100644 index 00000000..c950b2eb --- /dev/null +++ b/src/api/resources/admins/types/index.ts @@ -0,0 +1 @@ +export * from "./Admin"; diff --git a/src/api/resources/aiAgent/index.ts b/src/api/resources/aiAgent/index.ts new file mode 100644 index 00000000..eea524d6 --- /dev/null +++ b/src/api/resources/aiAgent/index.ts @@ -0,0 +1 @@ +export * from "./types"; diff --git a/src/api/resources/aiAgent/types/AiAgent.ts b/src/api/resources/aiAgent/types/AiAgent.ts new file mode 100644 index 00000000..af7c7974 --- /dev/null +++ b/src/api/resources/aiAgent/types/AiAgent.ts @@ -0,0 +1,38 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Data related to AI Agent involvement in the conversation. + */ +export interface AiAgent { + /** The type of the source that triggered AI Agent involvement in the conversation. */ + source_type: AiAgent.SourceType; + /** The title of the source that triggered AI Agent involvement in the conversation. If this is `essentials_plan_setup` then it will return `null`. */ + source_title?: string; + /** The type of the last answer delivered by AI Agent. If no answer was delivered then this will return `null` */ + last_answer_type?: string; + /** The resolution state of AI Agent. If no AI or custom answer has been delivered then this will return `null`. */ + resolution_state?: string; + /** The customer satisfaction rating given to AI Agent, from 1-5. */ + rating?: number; + /** The customer satisfaction rating remark given to AI Agent. */ + rating_remark?: string; + content_sources?: Intercom.ContentSourcesList; +} + +export namespace AiAgent { + /** + * The type of the source that triggered AI Agent involvement in the conversation. + */ + export type SourceType = "essentials_plan_setup" | "profile" | "workflow" | "workflow_preview" | "fin_preview"; + export const SourceType = { + EssentialsPlanSetup: "essentials_plan_setup", + Profile: "profile", + Workflow: "workflow", + WorkflowPreview: "workflow_preview", + FinPreview: "fin_preview", + } as const; +} diff --git a/src/api/resources/aiAgent/types/index.ts b/src/api/resources/aiAgent/types/index.ts new file mode 100644 index 00000000..05de312f --- /dev/null +++ b/src/api/resources/aiAgent/types/index.ts @@ -0,0 +1 @@ +export * from "./AiAgent"; diff --git a/src/api/resources/aiContentSource/index.ts b/src/api/resources/aiContentSource/index.ts new file mode 100644 index 00000000..eea524d6 --- /dev/null +++ b/src/api/resources/aiContentSource/index.ts @@ -0,0 +1 @@ +export * from "./types"; diff --git a/src/api/resources/aiContentSource/types/ContentSource.ts b/src/api/resources/aiContentSource/types/ContentSource.ts new file mode 100644 index 00000000..e8345f1b --- /dev/null +++ b/src/api/resources/aiContentSource/types/ContentSource.ts @@ -0,0 +1,31 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The content source used by AI Agent in the conversation. + */ +export interface ContentSource { + /** The type of the content source. */ + content_type: ContentSource.ContentType; + /** The internal URL linking to the content source for teammates. */ + url: string; + /** The title of the content source. */ + title: string; + /** The ISO 639 language code of the content source. */ + locale: string; +} + +export namespace ContentSource { + /** + * The type of the content source. + */ + export type ContentType = "file" | "article" | "external_content" | "content_snippet" | "workflow_connector_action"; + export const ContentType = { + File: "file", + Article: "article", + ExternalContent: "external_content", + ContentSnippet: "content_snippet", + WorkflowConnectorAction: "workflow_connector_action", + } as const; +} diff --git a/src/api/resources/aiContentSource/types/index.ts b/src/api/resources/aiContentSource/types/index.ts new file mode 100644 index 00000000..68047f7e --- /dev/null +++ b/src/api/resources/aiContentSource/types/index.ts @@ -0,0 +1 @@ +export * from "./ContentSource"; diff --git a/src/api/resources/articles/client/Client.ts b/src/api/resources/articles/client/Client.ts new file mode 100644 index 00000000..c902cb40 --- /dev/null +++ b/src/api/resources/articles/client/Client.ts @@ -0,0 +1,598 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace Articles { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Articles + */ +export class Articles { + constructor(protected readonly _options: Articles.Options = {}) {} + + /** + * You can fetch a list of all articles by making a GET request to `https://api.intercom.io/articles`. + * + * > 📘 How are the articles sorted and ordered? + * > + * > Articles will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated articles first. + * + * @param {Intercom.ListArticlesRequest} request + * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.articles.list() + */ + public async list( + request: Intercom.ListArticlesRequest = {}, + requestOptions?: Articles.RequestOptions + ): Promise> { + const list = async (request: Intercom.ListArticlesRequest): Promise => { + const { page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "articles" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.ArticleList; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + }; + let _offset = request?.page != null ? request?.page : 1; + return new core.Pageable({ + response: await list(request), + hasNextPage: (response) => (response?.data ?? []).length > 0, + getItems: (response) => response?.data ?? [], + loadPage: (_response) => { + _offset += 1; + return list(core.setObjectProperty(request, "page", _offset)); + }, + }); + } + + /** + * You can create a new article by making a POST request to `https://api.intercom.io/articles`. + * + * @param {Intercom.CreateArticleRequest} request + * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.articles.create({ + * title: "Thanks for everything", + * description: "Description of the Article", + * body: "Body of the Article", + * author_id: 991267407, + * state: "published", + * parent_id: 145, + * parent_type: "collection", + * translated_content: { + * fr: { + * type: "article_content", + * title: "Merci pour tout", + * description: "Description de l'article", + * body: "Corps de l'article", + * author_id: 991267407, + * state: "published" + * } + * } + * }) + * + * @example + * await client.articles.create({ + * title: "Thanks for everything", + * description: "Description of the Article", + * body: "Body of the Article", + * author_id: 1295, + * state: "published" + * }) + */ + public async create( + request: Intercom.CreateArticleRequest, + requestOptions?: Articles.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "articles" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Article; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown); + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /articles."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch the details of a single article by making a GET request to `https://api.intercom.io/articles/`. + * + * @param {Intercom.FindArticleRequest} request + * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.articles.find({ + * article_id: "123" + * }) + */ + public async find( + request: Intercom.FindArticleRequest, + requestOptions?: Articles.RequestOptions + ): Promise { + const { article_id: articleId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `articles/${encodeURIComponent(articleId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Article; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles/{article_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can update the details of a single article by making a PUT request to `https://api.intercom.io/articles/`. + * + * @param {Intercom.UpdateArticleRequest} request + * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.articles.update({ + * article_id: "123", + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

" + * }) + */ + public async update( + request: Intercom.UpdateArticleRequest, + requestOptions?: Articles.RequestOptions + ): Promise { + const { article_id: articleId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `articles/${encodeURIComponent(articleId)}` + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Article; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /articles/{article_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can delete a single article by making a DELETE request to `https://api.intercom.io/articles/`. + * + * @param {Intercom.DeleteArticleRequest} request + * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.articles.delete({ + * article_id: "123" + * }) + */ + public async delete( + request: Intercom.DeleteArticleRequest, + requestOptions?: Articles.RequestOptions + ): Promise { + const { article_id: articleId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `articles/${encodeURIComponent(articleId)}` + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.DeletedArticleObject; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /articles/{article_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can search for articles by making a GET request to `https://api.intercom.io/articles/search`. + * + * @param {Intercom.SearchArticlesRequest} request + * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.articles.search({ + * phrase: "Getting started", + * state: "published" + * }) + */ + public async search( + request: Intercom.SearchArticlesRequest = {}, + requestOptions?: Articles.RequestOptions + ): Promise { + const { phrase, state, help_center_id: helpCenterId, highlight } = request; + const _queryParams: Record = {}; + if (phrase != null) { + _queryParams["phrase"] = phrase; + } + + if (state != null) { + _queryParams["state"] = state; + } + + if (helpCenterId != null) { + _queryParams["help_center_id"] = helpCenterId.toString(); + } + + if (highlight != null) { + _queryParams["highlight"] = highlight.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "articles/search" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.SearchArticlesResponse; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles/search."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/articles/client/index.ts b/src/api/resources/articles/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/articles/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/articles/client/requests/CreateArticleRequest.ts b/src/api/resources/articles/client/requests/CreateArticleRequest.ts new file mode 100644 index 00000000..b75b8a3d --- /dev/null +++ b/src/api/resources/articles/client/requests/CreateArticleRequest.ts @@ -0,0 +1,65 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../index"; + +/** + * @example + * { + * title: "Thanks for everything", + * description: "Description of the Article", + * body: "Body of the Article", + * author_id: 991267407, + * state: "published", + * parent_id: 145, + * parent_type: "collection", + * translated_content: { + * fr: { + * type: "article_content", + * title: "Merci pour tout", + * description: "Description de l'article", + * body: "Corps de l'article", + * author_id: 991267407, + * state: "published" + * } + * } + * } + * + * @example + * { + * title: "Thanks for everything", + * description: "Description of the Article", + * body: "Body of the Article", + * author_id: 1295, + * state: "published" + * } + */ +export interface CreateArticleRequest { + /** The title of the article.For multilingual articles, this will be the title of the default language's content. */ + title: string; + /** The description of the article. For multilingual articles, this will be the description of the default language's content. */ + description?: string; + /** The content of the article. For multilingual articles, this will be the body of the default language's content. */ + body?: string; + /** The id of the author of the article. For multilingual articles, this will be the id of the author of the default language's content. Must be a teammate on the help center's workspace. */ + author_id: number; + /** Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. */ + state?: CreateArticleRequest.State; + /** The id of the article's parent collection or section. An article without this field stands alone. */ + parent_id?: number; + /** The type of parent, which can either be a `collection` or `section`. */ + parent_type?: string; + translated_content?: Intercom.ArticleTranslatedContent; +} + +export namespace CreateArticleRequest { + /** + * Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. + */ + export type State = "published" | "draft"; + export const State = { + Published: "published", + Draft: "draft", + } as const; +} diff --git a/src/api/resources/articles/client/requests/DeleteArticleRequest.ts b/src/api/resources/articles/client/requests/DeleteArticleRequest.ts new file mode 100644 index 00000000..cfc44703 --- /dev/null +++ b/src/api/resources/articles/client/requests/DeleteArticleRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * article_id: "123" + * } + */ +export interface DeleteArticleRequest { + /** + * The unique identifier for the article which is given by Intercom. + */ + article_id: string; +} diff --git a/src/api/resources/articles/client/requests/FindArticleRequest.ts b/src/api/resources/articles/client/requests/FindArticleRequest.ts new file mode 100644 index 00000000..29e6bc18 --- /dev/null +++ b/src/api/resources/articles/client/requests/FindArticleRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * article_id: "123" + * } + */ +export interface FindArticleRequest { + /** + * The unique identifier for the article which is given by Intercom. + */ + article_id: string; +} diff --git a/src/api/resources/articles/client/requests/ListArticlesRequest.ts b/src/api/resources/articles/client/requests/ListArticlesRequest.ts new file mode 100644 index 00000000..03a1e4d4 --- /dev/null +++ b/src/api/resources/articles/client/requests/ListArticlesRequest.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * {} + */ +export interface ListArticlesRequest { + /** + * The page of results to fetch. Defaults to first page + */ + page?: number; + /** + * How many results to display per page. Defaults to 15 + */ + per_page?: number; +} diff --git a/src/api/resources/articles/client/requests/SearchArticlesRequest.ts b/src/api/resources/articles/client/requests/SearchArticlesRequest.ts new file mode 100644 index 00000000..7c07777d --- /dev/null +++ b/src/api/resources/articles/client/requests/SearchArticlesRequest.ts @@ -0,0 +1,29 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * phrase: "Getting started", + * state: "published" + * } + */ +export interface SearchArticlesRequest { + /** + * The phrase within your articles to search for. + */ + phrase?: string; + /** + * The state of the Articles returned. One of `published`, `draft` or `all`. + */ + state?: string; + /** + * The ID of the Help Center to search in. + */ + help_center_id?: number; + /** + * Return a highlighted version of the matching content within your articles. Refer to the response schema for more details. + */ + highlight?: boolean; +} diff --git a/src/api/resources/articles/client/requests/UpdateArticleRequest.ts b/src/api/resources/articles/client/requests/UpdateArticleRequest.ts new file mode 100644 index 00000000..4714b224 --- /dev/null +++ b/src/api/resources/articles/client/requests/UpdateArticleRequest.ts @@ -0,0 +1,53 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../index"; + +/** + * @example + * { + * article_id: "123", + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

" + * } + * + * @example + * { + * article_id: "123", + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

" + * } + */ +export interface UpdateArticleRequest { + /** + * The unique identifier for the article which is given by Intercom. + */ + article_id: string; + /** The title of the article.For multilingual articles, this will be the title of the default language's content. */ + title?: string; + /** The description of the article. For multilingual articles, this will be the description of the default language's content. */ + description?: string; + /** The content of the article. For multilingual articles, this will be the body of the default language's content. */ + body?: string; + /** The id of the author of the article. For multilingual articles, this will be the id of the author of the default language's content. Must be a teammate on the help center's workspace. */ + author_id?: number; + /** Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. */ + state?: UpdateArticleRequest.State; + /** The id of the article's parent collection or section. An article without this field stands alone. */ + parent_id?: string; + /** The type of parent, which can either be a `collection` or `section`. */ + parent_type?: string; + translated_content?: Intercom.ArticleTranslatedContent; +} + +export namespace UpdateArticleRequest { + /** + * Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. + */ + export type State = "published" | "draft"; + export const State = { + Published: "published", + Draft: "draft", + } as const; +} diff --git a/src/api/resources/articles/client/requests/index.ts b/src/api/resources/articles/client/requests/index.ts new file mode 100644 index 00000000..48ca8171 --- /dev/null +++ b/src/api/resources/articles/client/requests/index.ts @@ -0,0 +1,6 @@ +export { type ListArticlesRequest } from "./ListArticlesRequest"; +export { type CreateArticleRequest } from "./CreateArticleRequest"; +export { type FindArticleRequest } from "./FindArticleRequest"; +export { type UpdateArticleRequest } from "./UpdateArticleRequest"; +export { type DeleteArticleRequest } from "./DeleteArticleRequest"; +export { type SearchArticlesRequest } from "./SearchArticlesRequest"; diff --git a/src/api/resources/articles/index.ts b/src/api/resources/articles/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/articles/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/articles/types/Article.ts b/src/api/resources/articles/types/Article.ts new file mode 100644 index 00000000..4328ff6c --- /dev/null +++ b/src/api/resources/articles/types/Article.ts @@ -0,0 +1,12 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * The Articles API is a central place to gather all information and take actions on your articles. Articles can live within collections and sections, or alternatively they can stand alone. + */ +export interface Article extends Intercom.ArticleListItem { + statistics?: Intercom.ArticleStatistics; +} diff --git a/src/api/resources/articles/types/ArticleListItem.ts b/src/api/resources/articles/types/ArticleListItem.ts new file mode 100644 index 00000000..1c180206 --- /dev/null +++ b/src/api/resources/articles/types/ArticleListItem.ts @@ -0,0 +1,53 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * The data returned about your articles when you list them. + */ +export interface ArticleListItem { + /** The type of object - `article`. */ + type?: "article"; + /** The unique identifier for the article which is given by Intercom. */ + id: string; + /** The id of the workspace which the article belongs to. */ + workspace_id: string; + /** The title of the article. For multilingual articles, this will be the title of the default language's content. */ + title: string; + /** The description of the article. For multilingual articles, this will be the description of the default language's content. */ + description?: string; + /** The body of the article in HTML. For multilingual articles, this will be the body of the default language's content. */ + body?: string; + /** The id of the author of the article. For multilingual articles, this will be the id of the author of the default language's content. Must be a teammate on the help center's workspace. */ + author_id: number; + /** Whether the article is `published` or is a `draft`. For multilingual articles, this will be the state of the default language's content. */ + state: ArticleListItem.State; + /** The time when the article was created. For multilingual articles, this will be the timestamp of creation of the default language's content in seconds. */ + created_at: number; + /** The time when the article was last updated. For multilingual articles, this will be the timestamp of last update of the default language's content in seconds. */ + updated_at: number; + /** The URL of the article. For multilingual articles, this will be the URL of the default language's content. */ + url?: string; + /** The id of the article's parent collection or section. An article without this field stands alone. */ + parent_id?: number; + /** The ids of the article's parent collections or sections. An article without this field stands alone. */ + parent_ids?: number[]; + /** The type of parent, which can either be a `collection` or `section`. */ + parent_type?: string; + /** The default locale of the help center. This field is only returned for multilingual help centers. */ + default_locale: string; + translated_content: Intercom.ArticleTranslatedContent; +} + +export namespace ArticleListItem { + /** + * Whether the article is `published` or is a `draft`. For multilingual articles, this will be the state of the default language's content. + */ + export type State = "published" | "draft"; + export const State = { + Published: "published", + Draft: "draft", + } as const; +} diff --git a/src/api/resources/articles/types/ArticleSearchHighlights.ts b/src/api/resources/articles/types/ArticleSearchHighlights.ts new file mode 100644 index 00000000..0dd36d50 --- /dev/null +++ b/src/api/resources/articles/types/ArticleSearchHighlights.ts @@ -0,0 +1,67 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The highlighted results of an Article search. In the examples provided my search query is always "my query". + */ +export interface ArticleSearchHighlights { + /** The ID of the corresponding article. */ + article_id: string; + /** An Article title highlighted. */ + highlighted_title: ArticleSearchHighlights.HighlightedTitle.Item[]; + /** An Article description and body text highlighted. */ + highlighted_summary: ArticleSearchHighlights.HighlightedSummary.Item[][]; +} + +export namespace ArticleSearchHighlights { + export type HighlightedTitle = HighlightedTitle.Item[]; + + export namespace HighlightedTitle { + /** + * A highlighted article title. + */ + export interface Item { + /** The type of text - `highlight` or `plain`. */ + type?: Item.Type; + /** The text of the title. */ + text?: string; + } + + export namespace Item { + /** + * The type of text - `highlight` or `plain`. + */ + export type Type = "highlight" | "plain"; + export const Type = { + Highlight: "highlight", + Plain: "plain", + } as const; + } + } + + export type HighlightedSummary = HighlightedSummary.Item[]; + + export namespace HighlightedSummary { + /** + * An instance of highlighted summary text. + */ + export interface Item { + /** The type of text - `highlight` or `plain`. */ + type?: Item.Type; + /** The text of the title. */ + text?: string; + } + + export namespace Item { + /** + * The type of text - `highlight` or `plain`. + */ + export type Type = "highlight" | "plain"; + export const Type = { + Highlight: "highlight", + Plain: "plain", + } as const; + } + } +} diff --git a/src/api/resources/articles/types/SearchArticlesResponse.ts b/src/api/resources/articles/types/SearchArticlesResponse.ts new file mode 100644 index 00000000..dbf3330a --- /dev/null +++ b/src/api/resources/articles/types/SearchArticlesResponse.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * The results of an Article search + */ +export interface SearchArticlesResponse { + /** The type of the object - `list`. */ + type: "list"; + /** The total number of Articles matching the search query */ + total_count: number; + /** An object containing the results of the search. */ + data: SearchArticlesResponse.Data; + pages?: Intercom.CursorPages; +} + +export namespace SearchArticlesResponse { + /** + * An object containing the results of the search. + */ + export interface Data { + /** An array of Article objects */ + articles?: Intercom.Article[]; + /** A corresponding array of highlighted Article content */ + highlights?: Intercom.ArticleSearchHighlights[]; + } +} diff --git a/src/api/resources/articles/types/index.ts b/src/api/resources/articles/types/index.ts new file mode 100644 index 00000000..a9b4ea42 --- /dev/null +++ b/src/api/resources/articles/types/index.ts @@ -0,0 +1,4 @@ +export * from "./Article"; +export * from "./ArticleListItem"; +export * from "./ArticleSearchHighlights"; +export * from "./SearchArticlesResponse"; diff --git a/src/api/resources/companies/client/Client.ts b/src/api/resources/companies/client/Client.ts new file mode 100644 index 00000000..e16b780d --- /dev/null +++ b/src/api/resources/companies/client/Client.ts @@ -0,0 +1,1053 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace Companies { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Companies + */ +export class Companies { + constructor(protected readonly _options: Companies.Options = {}) {} + + /** + * You can fetch a single company by passing in `company_id` or `name`. + * + * `https://api.intercom.io/companies?name={name}` + * + * `https://api.intercom.io/companies?company_id={company_id}` + * + * You can fetch all companies and filter by `segment_id` or `tag_id` as a query parameter. + * + * `https://api.intercom.io/companies?tag_id={tag_id}` + * + * `https://api.intercom.io/companies?segment_id={segment_id}` + * + * @param {Intercom.RetrieveCompanyRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.companies.retrieve({ + * name: "my company", + * company_id: "12345", + * tag_id: "678910", + * segment_id: "98765" + * }) + */ + public async retrieve( + request: Intercom.RetrieveCompanyRequest = {}, + requestOptions?: Companies.RequestOptions + ): Promise { + const { name, company_id: companyId, tag_id: tagId, segment_id: segmentId, page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (name != null) { + _queryParams["name"] = name; + } + + if (companyId != null) { + _queryParams["company_id"] = companyId; + } + + if (tagId != null) { + _queryParams["tag_id"] = tagId; + } + + if (segmentId != null) { + _queryParams["segment_id"] = segmentId; + } + + if (page != null) { + _queryParams["page"] = page.toString(); + } + + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "companies" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.CompanyList; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can create or update a company. + * + * Companies will be only visible in Intercom when there is at least one associated user. + * + * Companies are looked up via `company_id` in a `POST` request, if not found via `company_id`, the new company will be created, if found, that company will be updated. + * + * {% admonition type="attention" name="Using `company_id`" %} + * You can set a unique `company_id` value when creating a company. However, it is not possible to update `company_id`. Be sure to set a unique value once upon creation of the company. + * {% /admonition %} + * + * @param {Intercom.CreateOrUpdateCompanyRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.companies.createOrUpdate({ + * name: "my company", + * company_id: "company_remote_id", + * remote_created_at: 1374138000 + * }) + * + * @example + * await client.companies.createOrUpdate() + */ + public async createOrUpdate( + request: Intercom.CreateOrUpdateCompanyRequest = {}, + requestOptions?: Companies.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "companies" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Company; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown); + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /companies."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch a single company. + * + * @param {Intercom.FindCompanyRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.companies.find({ + * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * }) + */ + public async find( + request: Intercom.FindCompanyRequest, + requestOptions?: Companies.RequestOptions + ): Promise { + const { company_id: companyId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(companyId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Company; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/{company_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can update a single company using the Intercom provisioned `id`. + * + * {% admonition type="attention" name="Using `company_id`" %} + * When updating a company it is not possible to update `company_id`. This can only be set once upon creation of the company. + * {% /admonition %} + * + * @param {Intercom.UpdateCompanyRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.companies.update({ + * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * }) + */ + public async update( + request: Intercom.UpdateCompanyRequest, + requestOptions?: Companies.RequestOptions + ): Promise { + const { company_id: companyId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(companyId)}` + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Company; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /companies/{company_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can delete a single company. + * + * @param {Intercom.DeleteCompanyRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.companies.delete({ + * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * }) + */ + public async delete( + request: Intercom.DeleteCompanyRequest, + requestOptions?: Companies.RequestOptions + ): Promise { + const { company_id: companyId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(companyId)}` + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.DeletedCompanyObject; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /companies/{company_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch a list of all contacts that belong to a company. + * + * @param {Intercom.ListAttachedContactsRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.companies.listAttachedContacts({ + * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * }) + */ + public async listAttachedContacts( + request: Intercom.ListAttachedContactsRequest, + requestOptions?: Companies.RequestOptions + ): Promise { + const { company_id: companyId, page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(companyId)}/contacts` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.CompanyAttachedContacts; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /companies/{company_id}/contacts." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch a list of all segments that belong to a company. + * + * @param {Intercom.ListSegmentsAttachedToCompanyRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.companies.listAttachedSegments({ + * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * }) + */ + public async listAttachedSegments( + request: Intercom.ListSegmentsAttachedToCompanyRequest, + requestOptions?: Companies.RequestOptions + ): Promise { + const { company_id: companyId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(companyId)}/segments` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.CompanyAttachedSegments; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /companies/{company_id}/segments." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can list companies. The company list is sorted by the `last_request_at` field and by default is ordered descending, most recently requested first. + * + * Note that the API does not include companies who have no associated users in list responses. + * + * When using the Companies endpoint and the pages object to iterate through the returned companies, there is a limit of 10,000 Companies that can be returned. If you need to list or iterate on more than 10,000 Companies, please use the [Scroll API](https://developers.intercom.com/reference#iterating-over-all-companies). + * {% admonition type="warning" name="Pagination" %} + * You can use pagination to limit the number of results returned. The default is `20` results per page. + * See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. + * {% /admonition %} + * + * @param {Intercom.ListCompaniesRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.companies.list({ + * order: "desc" + * }) + */ + public async list( + request: Intercom.ListCompaniesRequest = {}, + requestOptions?: Companies.RequestOptions + ): Promise> { + const list = async (request: Intercom.ListCompaniesRequest): Promise => { + const { page, per_page: perPage, order } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + if (order != null) { + _queryParams["order"] = order; + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "companies/list" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.CompanyList; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /companies/list."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + }; + let _offset = request?.page != null ? request?.page : 1; + return new core.Pageable({ + response: await list(request), + hasNextPage: (response) => (response?.data ?? []).length > 0, + getItems: (response) => response?.data ?? [], + loadPage: (_response) => { + _offset += 1; + return list(core.setObjectProperty(request, "page", _offset)); + }, + }); + } + + /** + * The `list all companies` functionality does not work well for huge datasets, and can result in errors and performance problems when paging deeply. The Scroll API provides an efficient mechanism for iterating over all companies in a dataset. + * + * - Each app can only have 1 scroll open at a time. You'll get an error message if you try to have more than one open per app. + * - If the scroll isn't used for 1 minute, it expires and calls with that scroll param will fail + * - If the end of the scroll is reached, "companies" will be empty and the scroll parameter will expire + * + * {% admonition type="info" name="Scroll Parameter" %} + * You can get the first page of companies by simply sending a GET request to the scroll endpoint. + * For subsequent requests you will need to use the scroll parameter from the response. + * {% /admonition %} + * {% admonition type="danger" name="Scroll network timeouts" %} + * Since scroll is often used on large datasets network errors such as timeouts can be encountered. When this occurs you will see a HTTP 500 error with the following message: + * "Request failed due to an internal network error. Please restart the scroll operation." + * If this happens, you will need to restart your scroll query: It is not possible to continue from a specific point when using scroll. + * {% /admonition %} + * + * @param {Intercom.ScrollCompaniesRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.companies.scroll() + */ + public async scroll( + request: Intercom.ScrollCompaniesRequest = {}, + requestOptions?: Companies.RequestOptions + ): Promise> { + const list = async (request: Intercom.ScrollCompaniesRequest): Promise => { + const { scroll_param: scrollParam } = request; + const _queryParams: Record = {}; + if (scrollParam != null) { + _queryParams["scroll_param"] = scrollParam; + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "companies/scroll" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.CompanyScroll; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/scroll."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + }; + return new core.Pageable({ + response: await list(request), + hasNextPage: (response) => response?.scroll_param != null, + getItems: (response) => response?.data ?? [], + loadPage: (response) => { + return list(core.setObjectProperty(request, "scroll_param", response?.scroll_param)); + }, + }); + } + + /** + * You can attach a company to a single contact. + * + * @param {Intercom.AttachContactToCompanyRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.companies.attachContact({ + * contact_id: "contact_id", + * id: "667d608d8a68186f43bafd70" + * }) + * + * @example + * await client.companies.attachContact({ + * contact_id: "contact_id", + * id: "58a430d35458202d41b1e65b" + * }) + * + * @example + * await client.companies.attachContact({ + * contact_id: "contact_id", + * id: "123" + * }) + */ + public async attachContact( + request: Intercom.AttachContactToCompanyRequest, + requestOptions?: Companies.RequestOptions + ): Promise { + const { contact_id: contactId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/companies` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Company; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown); + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /contacts/{contact_id}/companies." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can detach a company from a single contact. + * + * @param {Intercom.DetachContactFromCompanyRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.companies.detachContact({ + * contact_id: "58a430d35458202d41b1e65b", + * company_id: "58a430d35458202d41b1e65b" + * }) + */ + public async detachContact( + request: Intercom.DetachContactFromCompanyRequest, + requestOptions?: Companies.RequestOptions + ): Promise { + const { contact_id: contactId, company_id: companyId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/companies/${encodeURIComponent(companyId)}` + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Company; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /contacts/{contact_id}/companies/{company_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/companies/client/index.ts b/src/api/resources/companies/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/companies/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/companies/client/requests/AttachContactToCompanyRequest.ts b/src/api/resources/companies/client/requests/AttachContactToCompanyRequest.ts new file mode 100644 index 00000000..17a7d4b3 --- /dev/null +++ b/src/api/resources/companies/client/requests/AttachContactToCompanyRequest.ts @@ -0,0 +1,31 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "contact_id", + * id: "667d608d8a68186f43bafd70" + * } + * + * @example + * { + * contact_id: "contact_id", + * id: "58a430d35458202d41b1e65b" + * } + * + * @example + * { + * contact_id: "contact_id", + * id: "123" + * } + */ +export interface AttachContactToCompanyRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; + /** The unique identifier for the company which is given by Intercom */ + id: string; +} diff --git a/src/api/resources/companies/client/requests/CreateOrUpdateCompanyRequest.ts b/src/api/resources/companies/client/requests/CreateOrUpdateCompanyRequest.ts new file mode 100644 index 00000000..207120b3 --- /dev/null +++ b/src/api/resources/companies/client/requests/CreateOrUpdateCompanyRequest.ts @@ -0,0 +1,35 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * name: "my company", + * company_id: "company_remote_id", + * remote_created_at: 1374138000 + * } + * + * @example + * {} + */ +export interface CreateOrUpdateCompanyRequest { + /** The name of the Company */ + name?: string; + /** The company id you have defined for the company. Can't be updated */ + company_id?: string; + /** The name of the plan you have associated with the company. */ + plan?: string; + /** The number of employees in this company. */ + size?: number; + /** The URL for this company's website. Please note that the value specified here is not validated. Accepts any string. */ + website?: string; + /** The industry that this company operates in. */ + industry?: string; + /** A hash of key/value pairs containing any other data about the company you want Intercom to store. */ + custom_attributes?: Record; + /** The time the company was created by you. */ + remote_created_at?: number; + /** How much revenue the company generates for your business. Note that this will truncate floats. i.e. it only allow for whole integers, 155.98 will be truncated to 155. Note that this has an upper limit of 2**31-1 or 2147483647.. */ + monthly_spend?: number; +} diff --git a/src/api/resources/companies/client/requests/DeleteCompanyRequest.ts b/src/api/resources/companies/client/requests/DeleteCompanyRequest.ts new file mode 100644 index 00000000..907c4032 --- /dev/null +++ b/src/api/resources/companies/client/requests/DeleteCompanyRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * } + */ +export interface DeleteCompanyRequest { + /** + * The unique identifier for the company which is given by Intercom + */ + company_id: string; +} diff --git a/src/api/resources/companies/client/requests/DetachContactFromCompanyRequest.ts b/src/api/resources/companies/client/requests/DetachContactFromCompanyRequest.ts new file mode 100644 index 00000000..9264bac5 --- /dev/null +++ b/src/api/resources/companies/client/requests/DetachContactFromCompanyRequest.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "58a430d35458202d41b1e65b", + * company_id: "58a430d35458202d41b1e65b" + * } + */ +export interface DetachContactFromCompanyRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; + /** + * The unique identifier for the company which is given by Intercom + */ + company_id: string; +} diff --git a/src/api/resources/companies/client/requests/FindCompanyRequest.ts b/src/api/resources/companies/client/requests/FindCompanyRequest.ts new file mode 100644 index 00000000..ca707798 --- /dev/null +++ b/src/api/resources/companies/client/requests/FindCompanyRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * } + */ +export interface FindCompanyRequest { + /** + * The unique identifier for the company which is given by Intercom + */ + company_id: string; +} diff --git a/src/api/resources/companies/client/requests/ListAttachedContactsRequest.ts b/src/api/resources/companies/client/requests/ListAttachedContactsRequest.ts new file mode 100644 index 00000000..af7ff8a7 --- /dev/null +++ b/src/api/resources/companies/client/requests/ListAttachedContactsRequest.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * } + */ +export interface ListAttachedContactsRequest { + /** + * The unique identifier for the company which is given by Intercom + */ + company_id: string; + /** + * The page of results to fetch. Defaults to first page + */ + page?: number; + /** + * How many results to return per page. Defaults to 15 + */ + per_page?: number; +} diff --git a/src/api/resources/companies/client/requests/ListCompaniesRequest.ts b/src/api/resources/companies/client/requests/ListCompaniesRequest.ts new file mode 100644 index 00000000..3d097dd4 --- /dev/null +++ b/src/api/resources/companies/client/requests/ListCompaniesRequest.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * order: "desc" + * } + */ +export interface ListCompaniesRequest { + /** + * The page of results to fetch. Defaults to first page + */ + page?: number; + /** + * How many results to return per page. Defaults to 15 + */ + per_page?: number; + /** + * `asc` or `desc`. Return the companies in ascending or descending order. Defaults to desc + */ + order?: string; +} diff --git a/src/api/resources/companies/client/requests/ListSegmentsAttachedToCompanyRequest.ts b/src/api/resources/companies/client/requests/ListSegmentsAttachedToCompanyRequest.ts new file mode 100644 index 00000000..6c640aea --- /dev/null +++ b/src/api/resources/companies/client/requests/ListSegmentsAttachedToCompanyRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * } + */ +export interface ListSegmentsAttachedToCompanyRequest { + /** + * The unique identifier for the company which is given by Intercom + */ + company_id: string; +} diff --git a/src/api/resources/companies/client/requests/RetrieveCompanyRequest.ts b/src/api/resources/companies/client/requests/RetrieveCompanyRequest.ts new file mode 100644 index 00000000..557a2e00 --- /dev/null +++ b/src/api/resources/companies/client/requests/RetrieveCompanyRequest.ts @@ -0,0 +1,39 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * name: "my company", + * company_id: "12345", + * tag_id: "678910", + * segment_id: "98765" + * } + */ +export interface RetrieveCompanyRequest { + /** + * The `name` of the company to filter by. + */ + name?: string; + /** + * The `company_id` of the company to filter by. + */ + company_id?: string; + /** + * The `tag_id` of the company to filter by. + */ + tag_id?: string; + /** + * The `segment_id` of the company to filter by. + */ + segment_id?: string; + /** + * The page of results to fetch. Defaults to first page + */ + page?: number; + /** + * How many results to display per page. Defaults to 15 + */ + per_page?: number; +} diff --git a/src/api/resources/companies/client/requests/ScrollCompaniesRequest.ts b/src/api/resources/companies/client/requests/ScrollCompaniesRequest.ts new file mode 100644 index 00000000..f5233617 --- /dev/null +++ b/src/api/resources/companies/client/requests/ScrollCompaniesRequest.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * {} + */ +export interface ScrollCompaniesRequest { + /** + * + */ + scroll_param?: string; +} diff --git a/src/api/resources/companies/client/requests/UpdateCompanyRequest.ts b/src/api/resources/companies/client/requests/UpdateCompanyRequest.ts new file mode 100644 index 00000000..bcd76db2 --- /dev/null +++ b/src/api/resources/companies/client/requests/UpdateCompanyRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * } + */ +export interface UpdateCompanyRequest { + /** + * The unique identifier for the company which is given by Intercom + */ + company_id: string; +} diff --git a/src/api/resources/companies/client/requests/index.ts b/src/api/resources/companies/client/requests/index.ts new file mode 100644 index 00000000..6e45efe4 --- /dev/null +++ b/src/api/resources/companies/client/requests/index.ts @@ -0,0 +1,11 @@ +export { type RetrieveCompanyRequest } from "./RetrieveCompanyRequest"; +export { type CreateOrUpdateCompanyRequest } from "./CreateOrUpdateCompanyRequest"; +export { type FindCompanyRequest } from "./FindCompanyRequest"; +export { type UpdateCompanyRequest } from "./UpdateCompanyRequest"; +export { type DeleteCompanyRequest } from "./DeleteCompanyRequest"; +export { type ListAttachedContactsRequest } from "./ListAttachedContactsRequest"; +export { type ListSegmentsAttachedToCompanyRequest } from "./ListSegmentsAttachedToCompanyRequest"; +export { type ListCompaniesRequest } from "./ListCompaniesRequest"; +export { type ScrollCompaniesRequest } from "./ScrollCompaniesRequest"; +export { type AttachContactToCompanyRequest } from "./AttachContactToCompanyRequest"; +export { type DetachContactFromCompanyRequest } from "./DetachContactFromCompanyRequest"; diff --git a/src/api/resources/companies/index.ts b/src/api/resources/companies/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/companies/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/companies/types/Company.ts b/src/api/resources/companies/types/Company.ts new file mode 100644 index 00000000..ef8faa7c --- /dev/null +++ b/src/api/resources/companies/types/Company.ts @@ -0,0 +1,77 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Companies allow you to represent organizations using your product. Each company will have its own description and be associated with contacts. You can fetch, create, update and list companies. + */ +export interface Company { + /** Value is `company` */ + type?: "company"; + /** The Intercom defined id representing the company. */ + id: string; + /** The name of the company. */ + name: string; + /** The Intercom defined code of the workspace the company is associated to. */ + app_id: string; + plan?: Company.Plan; + /** The company id you have defined for the company. */ + company_id: string; + /** The time the company was created by you. */ + remote_created_at: number; + /** The time the company was added in Intercom. */ + created_at: number; + /** The last time the company was updated. */ + updated_at: number; + /** The time the company last recorded making a request. */ + last_request_at: number; + /** The number of employees in the company. */ + size: number; + /** The URL for the company website. */ + website: string; + /** The industry that the company operates in. */ + industry: string; + /** How much revenue the company generates for your business. */ + monthly_spend: number; + /** How many sessions the company has recorded. */ + session_count: number; + /** The number of users in the company. */ + user_count: number; + /** The custom attributes you have set on the company. */ + custom_attributes?: Record; + /** The list of tags associated with the company */ + tags?: Company.Tags; + /** The list of segments associated with the company */ + segments?: Company.Segments; +} + +export namespace Company { + export interface Plan { + /** Value is always "plan" */ + type?: "plan"; + /** The id of the plan */ + id?: string; + /** The name of the plan */ + name?: string; + } + + /** + * The list of tags associated with the company + */ + export interface Tags { + /** The type of the object */ + type?: "tag.list"; + tags?: unknown[]; + } + + /** + * The list of segments associated with the company + */ + export interface Segments { + /** The type of the object */ + type?: "segment.list"; + segments?: Intercom.Segment[]; + } +} diff --git a/src/api/resources/companies/types/index.ts b/src/api/resources/companies/types/index.ts new file mode 100644 index 00000000..d15bbd39 --- /dev/null +++ b/src/api/resources/companies/types/index.ts @@ -0,0 +1 @@ +export * from "./Company"; diff --git a/src/api/resources/contacts/client/Client.ts b/src/api/resources/contacts/client/Client.ts new file mode 100644 index 00000000..61b69bf1 --- /dev/null +++ b/src/api/resources/contacts/client/Client.ts @@ -0,0 +1,1374 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace Contacts { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your contacts + */ +export class Contacts { + constructor(protected readonly _options: Contacts.Options = {}) {} + + /** + * You can fetch a list of companies that are associated to a contact. + * + * @param {Intercom.ListAttachedCompaniesRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.contacts.listAttachedCompanies({ + * contact_id: "63a07ddf05a32042dffac965" + * }) + */ + public async listAttachedCompanies( + request: Intercom.ListAttachedCompaniesRequest, + requestOptions?: Contacts.RequestOptions + ): Promise> { + const list = async ( + request: Intercom.ListAttachedCompaniesRequest + ): Promise => { + const { contact_id: contactId, page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/companies` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.ContactAttachedCompanies; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /contacts/{contact_id}/companies." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + }; + let _offset = request?.page != null ? request?.page : 1; + return new core.Pageable({ + response: await list(request), + hasNextPage: (response) => (response?.companies ?? []).length > 0, + getItems: (response) => response?.companies ?? [], + loadPage: (_response) => { + _offset += 1; + return list(core.setObjectProperty(request, "page", _offset)); + }, + }); + } + + /** + * You can fetch a list of segments that are associated to a contact. + * + * @param {Intercom.ListSegmentsAttachedToContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.contacts.listAttachedSegments({ + * contact_id: "63a07ddf05a32042dffac965" + * }) + */ + public async listAttachedSegments( + request: Intercom.ListSegmentsAttachedToContactRequest, + requestOptions?: Contacts.RequestOptions + ): Promise { + const { contact_id: contactId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/segments` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.ContactSegments; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /contacts/{contact_id}/segments." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch a list of subscription types that are attached to a contact. These can be subscriptions that a user has 'opted-in' to or has 'opted-out' from, depending on the subscription type. + * This will return a list of Subscription Type objects that the contact is associated with. + * + * The data property will show a combined list of: + * + * 1.Opt-out subscription types that the user has opted-out from. + * 2.Opt-in subscription types that the user has opted-in to receiving. + * + * @param {Intercom.ListAttachedSubscriptionsRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.contacts.listAttachedSubscriptions({ + * contact_id: "63a07ddf05a32042dffac965" + * }) + */ + public async listAttachedSubscriptions( + request: Intercom.ListAttachedSubscriptionsRequest, + requestOptions?: Contacts.RequestOptions + ): Promise { + const { contact_id: contactId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/subscriptions` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.SubscriptionTypeList; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /contacts/{contact_id}/subscriptions." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can add a specific subscription to a contact. In Intercom, we have two different subscription types based on user consent - opt-out and opt-in: + * + * 1.Attaching a contact to an opt-out subscription type will opt that user out from receiving messages related to that subscription type. + * + * 2.Attaching a contact to an opt-in subscription type will opt that user in to receiving messages related to that subscription type. + * + * This will return a subscription type model for the subscription type that was added to the contact. + * + * @param {Intercom.AttachSubscriptionToContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.contacts.attachSubscription({ + * contact_id: "63a07ddf05a32042dffac965", + * id: "37846", + * consent_type: "opt_in" + * }) + * + * @example + * await client.contacts.attachSubscription({ + * contact_id: "63a07ddf05a32042dffac965", + * id: "invalid_id", + * consent_type: "opt_in" + * }) + */ + public async attachSubscription( + request: Intercom.AttachSubscriptionToContactRequest, + requestOptions?: Contacts.RequestOptions + ): Promise { + const { contact_id: contactId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/subscriptions` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.SubscriptionType; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /contacts/{contact_id}/subscriptions." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can remove a specific subscription from a contact. This will return a subscription type model for the subscription type that was removed from the contact. + * + * @param {Intercom.DetachSubscriptionFromContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.contacts.detachSubscription({ + * contact_id: "63a07ddf05a32042dffac965", + * subscription_id: "37846" + * }) + */ + public async detachSubscription( + request: Intercom.DetachSubscriptionFromContactRequest, + requestOptions?: Contacts.RequestOptions + ): Promise { + const { contact_id: contactId, subscription_id: subscriptionId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/subscriptions/${encodeURIComponent(subscriptionId)}` + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.SubscriptionType; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /contacts/{contact_id}/subscriptions/{subscription_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch a list of all tags that are attached to a specific contact. + * + * @param {Intercom.ListTagsAttachedToContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.contacts.listAttachedTags({ + * contact_id: "63a07ddf05a32042dffac965" + * }) + */ + public async listAttachedTags( + request: Intercom.ListTagsAttachedToContactRequest, + requestOptions?: Contacts.RequestOptions + ): Promise { + const { contact_id: contactId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/tags` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.TagList; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts/{contact_id}/tags."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch the details of a single contact. + * + * @param {Intercom.FindContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.contacts.find({ + * contact_id: "63a07ddf05a32042dffac965" + * }) + */ + public async find( + request: Intercom.FindContactRequest, + requestOptions?: Contacts.RequestOptions + ): Promise { + const { contact_id: contactId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Contact; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts/{contact_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can update an existing contact (ie. user or lead). + * + * @param {Intercom.UpdateContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.contacts.update({ + * contact_id: "63a07ddf05a32042dffac965", + * email: "joebloggs@intercom.io", + * name: "joe bloggs" + * }) + */ + public async update( + request: Intercom.UpdateContactRequest, + requestOptions?: Contacts.RequestOptions + ): Promise { + const { contact_id: contactId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}` + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Contact; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /contacts/{contact_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can delete a single contact. + * + * @param {Intercom.DeleteContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.contacts.delete({ + * contact_id: "contact_id" + * }) + */ + public async delete( + request: Intercom.DeleteContactRequest, + requestOptions?: Contacts.RequestOptions + ): Promise { + const { contact_id: contactId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}` + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.ContactDeleted; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /contacts/{contact_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can merge a contact with a `role` of `lead` into a contact with a `role` of `user`. + * + * @param {Intercom.MergeContactsRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.contacts.mergeLeadInUser({ + * from: "667d60ac8a68186f43bafdbb", + * into: "667d60ac8a68186f43bafdbc" + * }) + */ + public async mergeLeadInUser( + request: Intercom.MergeContactsRequest, + requestOptions?: Contacts.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "contacts/merge" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Contact; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/merge."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can search for multiple contacts by the value of their attributes in order to fetch exactly who you want. + * + * To search for contacts, you need to send a `POST` request to `https://api.intercom.io/contacts/search`. + * + * This will accept a query object in the body which will define your filters in order to search for contacts. + * + * {% admonition type="warning" name="Optimizing search queries" %} + * Search queries can be complex, so optimizing them can help the performance of your search. + * Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize + * pagination to limit the number of results returned. The default is `50` results per page. + * See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. + * {% /admonition %} + * ### Contact Creation Delay + * + * If a contact has recently been created, there is a possibility that it will not yet be available when searching. This means that it may not appear in the response. This delay can take a few minutes. If you need to be instantly notified it is recommended to use webhooks and iterate to see if they match your search filters. + * + * ### Nesting & Limitations + * + * You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). + * There are some limitations to the amount of multiple's there can be: + * * There's a limit of max 2 nested filters + * * There's a limit of max 15 filters for each AND or OR group + * + * ### Searching for Timestamp Fields + * + * All timestamp fields (created_at, updated_at etc.) are indexed as Dates for Contact Search queries; Datetime queries are not currently supported. This means you can only query for timestamp fields by day - not hour, minute or second. + * For example, if you search for all Contacts with a created_at value greater (>) than 1577869200 (the UNIX timestamp for January 1st, 2020 9:00 AM), that will be interpreted as 1577836800 (January 1st, 2020 12:00 AM). The search results will then include Contacts created from January 2nd, 2020 12:00 AM onwards. + * If you'd like to get contacts created on January 1st, 2020 you should search with a created_at value equal (=) to 1577836800 (January 1st, 2020 12:00 AM). + * This behaviour applies only to timestamps used in search queries. The search results will still contain the full UNIX timestamp and be sorted accordingly. + * + * ### Accepted Fields + * + * Most key listed as part of the Contacts Model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). + * + * | Field | Type | + * | ---------------------------------- | ------------------------------ | + * | id | String | + * | role | String
Accepts user or lead | + * | name | String | + * | avatar | String | + * | owner_id | Integer | + * | email | String | + * | email_domain | String | + * | phone | String | + * | formatted_phone | String | + * | external_id | String | + * | created_at | Date (UNIX Timestamp) | + * | signed_up_at | Date (UNIX Timestamp) | + * | updated_at | Date (UNIX Timestamp) | + * | last_seen_at | Date (UNIX Timestamp) | + * | last_contacted_at | Date (UNIX Timestamp) | + * | last_replied_at | Date (UNIX Timestamp) | + * | last_email_opened_at | Date (UNIX Timestamp) | + * | last_email_clicked_at | Date (UNIX Timestamp) | + * | language_override | String | + * | browser | String | + * | browser_language | String | + * | os | String | + * | location.country | String | + * | location.region | String | + * | location.city | String | + * | unsubscribed_from_emails | Boolean | + * | marked_email_as_spam | Boolean | + * | has_hard_bounced | Boolean | + * | ios_last_seen_at | Date (UNIX Timestamp) | + * | ios_app_version | String | + * | ios_device | String | + * | ios_app_device | String | + * | ios_os_version | String | + * | ios_app_name | String | + * | ios_sdk_version | String | + * | android_last_seen_at | Date (UNIX Timestamp) | + * | android_app_version | String | + * | android_device | String | + * | android_app_name | String | + * | andoid_sdk_version | String | + * | segment_id | String | + * | tag_id | String | + * | custom_attributes.{attribute_name} | String | + * + * ### Accepted Operators + * + * {% admonition type="attention" name="Searching based on `created_at`" %} + * You cannot use the `<=` or `>=` operators to search by `created_at`. + * {% /admonition %} + * + * The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + * + * | Operator | Valid Types | Description | + * | :------- | :------------------------------- | :--------------------------------------------------------------- | + * | = | All | Equals | + * | != | All | Doesn't Equal | + * | IN | All | In
Shortcut for `OR` queries
Values must be in Array | + * | NIN | All | Not In
Shortcut for `OR !` queries
Values must be in Array | + * | > | Integer
Date (UNIX Timestamp) | Greater than | + * | < | Integer
Date (UNIX Timestamp) | Lower than | + * | ~ | String | Contains | + * | !~ | String | Doesn't Contain | + * | ^ | String | Starts With | + * | $ | String | Ends With | + * + * @param {Intercom.SearchRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.contacts.search({ + * query: { + * operator: "AND", + * value: [{ + * field: "created_at", + * operator: ">", + * value: "1306054154" + * }] + * }, + * pagination: { + * per_page: 5 + * } + * }) + */ + public async search( + request: Intercom.SearchRequest, + requestOptions?: Contacts.RequestOptions + ): Promise> { + const list = async (request: Intercom.SearchRequest): Promise => { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "contacts/search" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.ContactList; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/search."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + }; + return new core.Pageable({ + response: await list(request), + hasNextPage: (response) => response?.pages?.next?.starting_after != null, + getItems: (response) => response?.data ?? [], + loadPage: (response) => { + return list( + core.setObjectProperty(request, "pagination.starting_after", response?.pages?.next?.starting_after) + ); + }, + }); + } + + /** + * You can fetch a list of all contacts (ie. users or leads) in your workspace. + * {% admonition type="warning" name="Pagination" %} + * You can use pagination to limit the number of results returned. The default is `50` results per page. + * See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. + * {% /admonition %} + * + * @param {Intercom.ListContactsRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.contacts.list() + */ + public async list( + request: Intercom.ListContactsRequest = {}, + requestOptions?: Contacts.RequestOptions + ): Promise> { + const list = async (request: Intercom.ListContactsRequest): Promise => { + const { page, per_page: perPage, starting_after: startingAfter } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + if (startingAfter != null) { + _queryParams["starting_after"] = startingAfter; + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "contacts" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.ContactList; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + }; + return new core.Pageable({ + response: await list(request), + hasNextPage: (response) => response?.pages?.next?.starting_after != null, + getItems: (response) => response?.data ?? [], + loadPage: (response) => { + return list(core.setObjectProperty(request, "starting_after", response?.pages?.next?.starting_after)); + }, + }); + } + + /** + * You can create a new contact (ie. user or lead). + * + * @param {Intercom.CreateContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.contacts.create({ + * email: "joebloggs@intercom.io" + * }) + */ + public async create( + request: Intercom.CreateContactRequest, + requestOptions?: Contacts.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "contacts" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Contact; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can archive a single contact. + * + * @param {Intercom.ArchiveContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.contacts.archive({ + * contact_id: "63a07ddf05a32042dffac965" + * }) + */ + public async archive( + request: Intercom.ArchiveContactRequest, + requestOptions?: Contacts.RequestOptions + ): Promise { + const { contact_id: contactId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/archive` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.ContactArchived; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /contacts/{contact_id}/archive." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can unarchive a single contact. + * + * @param {Intercom.UnarchiveContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.contacts.unarchive({ + * contact_id: "63a07ddf05a32042dffac965" + * }) + */ + public async unarchive( + request: Intercom.UnarchiveContactRequest, + requestOptions?: Contacts.RequestOptions + ): Promise { + const { contact_id: contactId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/unarchive` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.ContactUnarchived; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /contacts/{contact_id}/unarchive." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/contacts/client/index.ts b/src/api/resources/contacts/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/contacts/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/contacts/client/requests/ArchiveContactRequest.ts b/src/api/resources/contacts/client/requests/ArchiveContactRequest.ts new file mode 100644 index 00000000..1e5452c4 --- /dev/null +++ b/src/api/resources/contacts/client/requests/ArchiveContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965" + * } + */ +export interface ArchiveContactRequest { + /** + * id + */ + contact_id: string; +} diff --git a/src/api/resources/contacts/client/requests/AttachSubscriptionToContactRequest.ts b/src/api/resources/contacts/client/requests/AttachSubscriptionToContactRequest.ts new file mode 100644 index 00000000..6433e324 --- /dev/null +++ b/src/api/resources/contacts/client/requests/AttachSubscriptionToContactRequest.ts @@ -0,0 +1,36 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * id: "37846", + * consent_type: "opt_in" + * } + * + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * id: "37846", + * consent_type: "opt_in" + * } + * + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * id: "invalid_id", + * consent_type: "opt_in" + * } + */ +export interface AttachSubscriptionToContactRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; + /** The unique identifier for the subscription which is given by Intercom */ + id: string; + /** The consent_type of a subscription, opt_out or opt_in. */ + consent_type: string; +} diff --git a/src/api/resources/contacts/client/requests/DeleteContactRequest.ts b/src/api/resources/contacts/client/requests/DeleteContactRequest.ts new file mode 100644 index 00000000..559cfeb9 --- /dev/null +++ b/src/api/resources/contacts/client/requests/DeleteContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "contact_id" + * } + */ +export interface DeleteContactRequest { + /** + * id + */ + contact_id: string; +} diff --git a/src/api/resources/contacts/client/requests/DetachSubscriptionFromContactRequest.ts b/src/api/resources/contacts/client/requests/DetachSubscriptionFromContactRequest.ts new file mode 100644 index 00000000..081c1459 --- /dev/null +++ b/src/api/resources/contacts/client/requests/DetachSubscriptionFromContactRequest.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * subscription_id: "37846" + * } + */ +export interface DetachSubscriptionFromContactRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; + /** + * The unique identifier for the subscription type which is given by Intercom + */ + subscription_id: string; +} diff --git a/src/api/resources/contacts/client/requests/FindContactRequest.ts b/src/api/resources/contacts/client/requests/FindContactRequest.ts new file mode 100644 index 00000000..3eed3e85 --- /dev/null +++ b/src/api/resources/contacts/client/requests/FindContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965" + * } + */ +export interface FindContactRequest { + /** + * id + */ + contact_id: string; +} diff --git a/src/api/resources/contacts/client/requests/ListAttachedCompaniesRequest.ts b/src/api/resources/contacts/client/requests/ListAttachedCompaniesRequest.ts new file mode 100644 index 00000000..5c1f5caa --- /dev/null +++ b/src/api/resources/contacts/client/requests/ListAttachedCompaniesRequest.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965" + * } + */ +export interface ListAttachedCompaniesRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; + /** + * The page of results to fetch. Defaults to first page + */ + page?: number; + /** + * How many results to display per page. Defaults to 15 + */ + per_page?: number; +} diff --git a/src/api/resources/contacts/client/requests/ListAttachedSubscriptionsRequest.ts b/src/api/resources/contacts/client/requests/ListAttachedSubscriptionsRequest.ts new file mode 100644 index 00000000..3ab3f449 --- /dev/null +++ b/src/api/resources/contacts/client/requests/ListAttachedSubscriptionsRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965" + * } + */ +export interface ListAttachedSubscriptionsRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; +} diff --git a/src/api/resources/contacts/client/requests/ListContactsRequest.ts b/src/api/resources/contacts/client/requests/ListContactsRequest.ts new file mode 100644 index 00000000..b67a189f --- /dev/null +++ b/src/api/resources/contacts/client/requests/ListContactsRequest.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * {} + */ +export interface ListContactsRequest { + /** + * The page of results to fetch. Defaults to first page + */ + page?: number; + /** + * How many results to display per page. Defaults to 15 + */ + per_page?: number; + /** + * String used to get the next page of conversations. + */ + starting_after?: string; +} diff --git a/src/api/resources/contacts/client/requests/ListSegmentsAttachedToContactRequest.ts b/src/api/resources/contacts/client/requests/ListSegmentsAttachedToContactRequest.ts new file mode 100644 index 00000000..b120b483 --- /dev/null +++ b/src/api/resources/contacts/client/requests/ListSegmentsAttachedToContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965" + * } + */ +export interface ListSegmentsAttachedToContactRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; +} diff --git a/src/api/resources/contacts/client/requests/ListTagsAttachedToContactRequest.ts b/src/api/resources/contacts/client/requests/ListTagsAttachedToContactRequest.ts new file mode 100644 index 00000000..632002f6 --- /dev/null +++ b/src/api/resources/contacts/client/requests/ListTagsAttachedToContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965" + * } + */ +export interface ListTagsAttachedToContactRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; +} diff --git a/src/api/resources/contacts/client/requests/MergeContactsRequest.ts b/src/api/resources/contacts/client/requests/MergeContactsRequest.ts new file mode 100644 index 00000000..704efeb1 --- /dev/null +++ b/src/api/resources/contacts/client/requests/MergeContactsRequest.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * from: "667d60ac8a68186f43bafdbb", + * into: "667d60ac8a68186f43bafdbc" + * } + */ +export interface MergeContactsRequest { + /** The unique identifier for the contact to merge away from. Must be a lead. */ + from: string; + /** The unique identifier for the contact to merge into. Must be a user. */ + into: string; +} diff --git a/src/api/resources/contacts/client/requests/UnarchiveContactRequest.ts b/src/api/resources/contacts/client/requests/UnarchiveContactRequest.ts new file mode 100644 index 00000000..f014d7d2 --- /dev/null +++ b/src/api/resources/contacts/client/requests/UnarchiveContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965" + * } + */ +export interface UnarchiveContactRequest { + /** + * id + */ + contact_id: string; +} diff --git a/src/api/resources/contacts/client/requests/UpdateContactRequest.ts b/src/api/resources/contacts/client/requests/UpdateContactRequest.ts new file mode 100644 index 00000000..109178e2 --- /dev/null +++ b/src/api/resources/contacts/client/requests/UpdateContactRequest.ts @@ -0,0 +1,40 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * email: "joebloggs@intercom.io", + * name: "joe bloggs" + * } + */ +export interface UpdateContactRequest { + /** + * id + */ + contact_id: string; + /** The role of the contact. */ + role?: string; + /** A unique identifier for the contact which is given to Intercom */ + external_id?: string; + /** The contacts email */ + email?: string; + /** The contacts phone */ + phone?: string; + /** The contacts name */ + name?: string; + /** An image URL containing the avatar of a contact */ + avatar?: string; + /** The time specified for when a contact signed up */ + signed_up_at?: number; + /** The time when the contact was last seen (either where the Intercom Messenger was installed or when specified manually) */ + last_seen_at?: number; + /** The id of an admin that has been assigned account ownership of the contact */ + owner_id?: number; + /** Whether the contact is unsubscribed from emails */ + unsubscribed_from_emails?: boolean; + /** The custom attributes which are set for the contact */ + custom_attributes?: Record; +} diff --git a/src/api/resources/contacts/client/requests/index.ts b/src/api/resources/contacts/client/requests/index.ts new file mode 100644 index 00000000..1e895632 --- /dev/null +++ b/src/api/resources/contacts/client/requests/index.ts @@ -0,0 +1,13 @@ +export { type ListAttachedCompaniesRequest } from "./ListAttachedCompaniesRequest"; +export { type ListSegmentsAttachedToContactRequest } from "./ListSegmentsAttachedToContactRequest"; +export { type ListAttachedSubscriptionsRequest } from "./ListAttachedSubscriptionsRequest"; +export { type AttachSubscriptionToContactRequest } from "./AttachSubscriptionToContactRequest"; +export { type DetachSubscriptionFromContactRequest } from "./DetachSubscriptionFromContactRequest"; +export { type ListTagsAttachedToContactRequest } from "./ListTagsAttachedToContactRequest"; +export { type FindContactRequest } from "./FindContactRequest"; +export { type UpdateContactRequest } from "./UpdateContactRequest"; +export { type DeleteContactRequest } from "./DeleteContactRequest"; +export { type MergeContactsRequest } from "./MergeContactsRequest"; +export { type ListContactsRequest } from "./ListContactsRequest"; +export { type ArchiveContactRequest } from "./ArchiveContactRequest"; +export { type UnarchiveContactRequest } from "./UnarchiveContactRequest"; diff --git a/src/api/resources/contacts/index.ts b/src/api/resources/contacts/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/contacts/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/contacts/types/Contact.ts b/src/api/resources/contacts/types/Contact.ts new file mode 100644 index 00000000..c4b7c47a --- /dev/null +++ b/src/api/resources/contacts/types/Contact.ts @@ -0,0 +1,106 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Contact are the objects that represent your leads and users in Intercom. + */ +export interface Contact { + /** The type of object. */ + type?: string; + /** The unique identifier for the contact which is given by Intercom. */ + id: string; + /** The unique identifier for the contact which is provided by the Client. */ + external_id?: string; + /** The id of the workspace which the contact belongs to. */ + workspace_id: string; + /** The role of the contact. */ + role: string; + /** The contact's email. */ + email: string; + /** The contact's email domain. */ + email_domain?: string; + /** The contacts phone. */ + phone?: string; + /** The contacts phone number normalized to the E164 format */ + formatted_phone?: string; + /** The contacts name. */ + name?: string; + /** The id of an admin that has been assigned account ownership of the contact. */ + owner_id?: number; + /** Whether the contact has had an email sent to them hard bounce. */ + has_hard_bounced: boolean; + /** Whether the contact has marked an email sent to them as spam. */ + marked_email_as_spam: boolean; + /** Whether the contact is unsubscribed from emails. */ + unsubscribed_from_emails: boolean; + /** (UNIX timestamp) The time when the contact was created. */ + created_at: number; + /** (UNIX timestamp) The time when the contact was last updated. */ + updated_at: number; + /** (UNIX timestamp) The time specified for when a contact signed up. */ + signed_up_at?: number; + /** (UNIX timestamp) The time when the contact was last seen (either where the Intercom Messenger was installed or when specified manually). */ + last_seen_at?: number; + /** (UNIX timestamp) The time when the contact last messaged in. */ + last_replied_at?: number; + /** (UNIX timestamp) The time when the contact was last messaged. */ + last_contacted_at?: number; + /** (UNIX timestamp) The time when the contact last opened an email. */ + last_email_opened_at?: number; + /** (UNIX timestamp) The time when the contact last clicked a link in an email. */ + last_email_clicked_at?: number; + /** A preferred language setting for the contact, used by the Intercom Messenger even if their browser settings change. */ + language_override?: string; + /** The name of the browser which the contact is using. */ + browser?: string; + /** The version of the browser which the contact is using. */ + browser_version?: string; + /** The language set by the browser which the contact is using. */ + browser_language?: string; + /** The operating system which the contact is using. */ + os?: string; + /** The name of the Android app which the contact is using. */ + android_app_name?: string; + /** The version of the Android app which the contact is using. */ + android_app_version?: string; + /** The Android device which the contact is using. */ + android_device?: string; + /** The version of the Android OS which the contact is using. */ + android_os_version?: string; + /** The version of the Android SDK which the contact is using. */ + android_sdk_version?: string; + /** (UNIX timestamp) The time when the contact was last seen on an Android device. */ + android_last_seen_at?: number; + /** The name of the iOS app which the contact is using. */ + ios_app_name?: string; + /** The version of the iOS app which the contact is using. */ + ios_app_version?: string; + /** The iOS device which the contact is using. */ + ios_device?: string; + /** The version of iOS which the contact is using. */ + ios_os_version?: string; + /** The version of the iOS SDK which the contact is using. */ + ios_sdk_version?: string; + /** (UNIX timestamp) The last time the contact used the iOS app. */ + ios_last_seen_at?: number; + /** The custom attributes which are set for the contact. */ + custom_attributes?: Record; + avatar?: Contact.Avatar; + tags?: Intercom.ContactTags; + notes?: Intercom.ContactNotes; + companies?: Intercom.ContactCompanies; + location: Intercom.ContactLocation; + social_profiles: Intercom.ContactSocialProfiles; +} + +export namespace Contact { + export interface Avatar { + /** The type of object */ + type?: string; + /** An image URL containing the avatar of a contact. */ + image_url?: string; + } +} diff --git a/src/api/resources/contacts/types/index.ts b/src/api/resources/contacts/types/index.ts new file mode 100644 index 00000000..b538eafc --- /dev/null +++ b/src/api/resources/contacts/types/index.ts @@ -0,0 +1 @@ +export * from "./Contact"; diff --git a/src/api/resources/conversations/client/Client.ts b/src/api/resources/conversations/client/Client.ts new file mode 100644 index 00000000..a6bffd8a --- /dev/null +++ b/src/api/resources/conversations/client/Client.ts @@ -0,0 +1,1331 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace Conversations { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Conversations + */ +export class Conversations { + constructor(protected readonly _options: Conversations.Options = {}) {} + + /** + * You can fetch a list of all conversations. + * + * You can optionally request the result page size and the cursor to start after to fetch the result. + * {% admonition type="warning" name="Pagination" %} + * You can use pagination to limit the number of results returned. The default is `20` results per page. + * See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. + * {% /admonition %} + * + * @param {Intercom.ListConversationsRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.ForbiddenError} + * + * @example + * await client.conversations.list() + */ + public async list( + request: Intercom.ListConversationsRequest = {}, + requestOptions?: Conversations.RequestOptions + ): Promise> { + const list = async ( + request: Intercom.ListConversationsRequest + ): Promise => { + const { per_page: perPage, starting_after: startingAfter } = request; + const _queryParams: Record = {}; + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + if (startingAfter != null) { + _queryParams["starting_after"] = startingAfter; + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "conversations" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.PaginatedConversationResponse; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 403: + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /conversations."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + }; + return new core.Pageable({ + response: await list(request), + hasNextPage: (response) => response?.pages?.next?.starting_after != null, + getItems: (response) => response?.conversations ?? [], + loadPage: (response) => { + return list(core.setObjectProperty(request, "starting_after", response?.pages?.next?.starting_after)); + }, + }); + } + + /** + * You can create a conversation that has been initiated by a contact (ie. user or lead). + * The conversation can be an in-app message only. + * + * {% admonition type="info" name="Sending for visitors" %} + * You can also send a message from a visitor by specifying their `user_id` or `id` value in the `from` field, along with a `type` field value of `contact`. + * This visitor will be automatically converted to a contact with a lead role once the conversation is created. + * {% /admonition %} + * + * This will return the Message model that has been created. + * + * + * @param {Intercom.CreateConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.ForbiddenError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.conversations.create({ + * from: { + * type: "user", + * id: "667d60d18a68186f43bafddd" + * }, + * body: "Hello there" + * }) + * + * @example + * await client.conversations.create({ + * from: { + * type: "user", + * id: "123_doesnt_exist" + * }, + * body: "Hello there" + * }) + */ + public async create( + request: Intercom.CreateConversationRequest, + requestOptions?: Conversations.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "conversations" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Message; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 403: + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * + * You can fetch the details of a single conversation. + * + * This will return a single Conversation model with all its conversation parts. + * + * {% admonition type="warning" name="Hard limit of 500 parts" %} + * The maximum number of conversation parts that can be returned via the API is 500. If you have more than that we will return the 500 most recent conversation parts. + * {% /admonition %} + * + * For AI agent conversation metadata, please note that you need to have the agent enabled in your workspace, which is a [paid feature](https://www.intercom.com/help/en/articles/8205718-fin-resolutions#h_97f8c2e671). + * + * @param {Intercom.FindConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.ForbiddenError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.conversations.find({ + * conversation_id: "123", + * display_as: "plaintext" + * }) + */ + public async find( + request: Intercom.FindConversationRequest, + requestOptions?: Conversations.RequestOptions + ): Promise { + const { conversation_id: conversationId, display_as: displayAs } = request; + const _queryParams: Record = {}; + if (displayAs != null) { + _queryParams["display_as"] = displayAs; + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Conversation; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 403: + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /conversations/{conversation_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * + * You can update an existing conversation. + * + * {% admonition type="info" name="Replying and other actions" %} + * If you want to reply to a coveration or take an action such as assign, unassign, open, close or snooze, take a look at the reply and manage endpoints. + * {% /admonition %} + * + * + * @param {Intercom.UpdateConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.ForbiddenError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.conversations.update({ + * conversation_id: "123", + * display_as: "plaintext", + * read: true, + * custom_attributes: { + * "issue_type": "Billing", + * "priority": "High" + * } + * }) + */ + public async update( + request: Intercom.UpdateConversationRequest, + requestOptions?: Conversations.RequestOptions + ): Promise { + const { conversation_id: conversationId, display_as: displayAs, ..._body } = request; + const _queryParams: Record = {}; + if (displayAs != null) { + _queryParams["display_as"] = displayAs; + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}` + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Conversation; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 403: + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling PUT /conversations/{conversation_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can search for multiple conversations by the value of their attributes in order to fetch exactly which ones you want. + * + * To search for conversations, you need to send a `POST` request to `https://api.intercom.io/conversations/search`. + * + * This will accept a query object in the body which will define your filters in order to search for conversations. + * {% admonition type="warning" name="Optimizing search queries" %} + * Search queries can be complex, so optimizing them can help the performance of your search. + * Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize + * pagination to limit the number of results returned. The default is `20` results per page and maximum is `150`. + * See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. + * {% /admonition %} + * + * ### Nesting & Limitations + * + * You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). + * There are some limitations to the amount of multiple's there can be: + * - There's a limit of max 2 nested filters + * - There's a limit of max 15 filters for each AND or OR group + * + * ### Accepted Fields + * + * Most keys listed as part of the The conversation model is searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). + * The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. + * + * | Field | Type | + * | :---------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------- | + * | id | String | + * | created_at | Date (UNIX timestamp) | + * | updated_at | Date (UNIX timestamp) | + * | source.type | String
Accepted fields are `conversation`, `email`, `facebook`, `instagram`, `phone_call`, `phone_switch`, `push`, `sms`, `twitter` and `whatsapp`. | + * | source.id | String | + * | source.delivered_as | String | + * | source.subject | String | + * | source.body | String | + * | source.author.id | String | + * | source.author.type | String | + * | source.author.name | String | + * | source.author.email | String | + * | source.url | String | + * | contact_ids | String | + * | teammate_ids | String | + * | admin_assignee_id | String | + * | team_assignee_id | String | + * | channel_initiated | String | + * | open | Boolean | + * | read | Boolean | + * | state | String | + * | waiting_since | Date (UNIX timestamp) | + * | snoozed_until | Date (UNIX timestamp) | + * | tag_ids | String | + * | priority | String | + * | statistics.time_to_assignment | Integer | + * | statistics.time_to_admin_reply | Integer | + * | statistics.time_to_first_close | Integer | + * | statistics.time_to_last_close | Integer | + * | statistics.median_time_to_reply | Integer | + * | statistics.first_contact_reply_at | Date (UNIX timestamp) | + * | statistics.first_assignment_at | Date (UNIX timestamp) | + * | statistics.first_admin_reply_at | Date (UNIX timestamp) | + * | statistics.first_close_at | Date (UNIX timestamp) | + * | statistics.last_assignment_at | Date (UNIX timestamp) | + * | statistics.last_assignment_admin_reply_at | Date (UNIX timestamp) | + * | statistics.last_contact_reply_at | Date (UNIX timestamp) | + * | statistics.last_admin_reply_at | Date (UNIX timestamp) | + * | statistics.last_close_at | Date (UNIX timestamp) | + * | statistics.last_closed_by_id | String | + * | statistics.count_reopens | Integer | + * | statistics.count_assignments | Integer | + * | statistics.count_conversation_parts | Integer | + * | conversation_rating.requested_at | Date (UNIX timestamp) | + * | conversation_rating.replied_at | Date (UNIX timestamp) | + * | conversation_rating.score | Integer | + * | conversation_rating.remark | String | + * | conversation_rating.contact_id | String | + * | conversation_rating.admin_d | String | + * | ai_agent_participated | Boolean | + * | ai_agent.resolution_state | String | + * | ai_agent.last_answer_type | String | + * | ai_agent.rating | Integer | + * | ai_agent.rating_remark | String | + * | ai_agent.source_type | String | + * | ai_agent.source_title | String | + * + * ### Accepted Operators + * + * The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + * + * | Operator | Valid Types | Description | + * | :------- | :----------------------------- | :----------------------------------------------------------- | + * | = | All | Equals | + * | != | All | Doesn't Equal | + * | IN | All | In Shortcut for `OR` queries Values most be in Array | + * | NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | + * | > | Integer Date (UNIX Timestamp) | Greater (or equal) than | + * | < | Integer Date (UNIX Timestamp) | Lower (or equal) than | + * | ~ | String | Contains | + * | !~ | String | Doesn't Contain | + * | ^ | String | Starts With | + * | $ | String | Ends With | + * + * @param {Intercom.SearchRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.conversations.search({ + * query: { + * operator: "AND", + * value: [{ + * field: "created_at", + * operator: ">", + * value: "1306054154" + * }] + * }, + * pagination: { + * per_page: 5 + * } + * }) + */ + public async search( + request: Intercom.SearchRequest, + requestOptions?: Conversations.RequestOptions + ): Promise> { + const list = async (request: Intercom.SearchRequest): Promise => { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "conversations/search" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.PaginatedConversationResponse; + } + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations/search."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + }; + return new core.Pageable({ + response: await list(request), + hasNextPage: (response) => response?.pages?.next?.starting_after != null, + getItems: (response) => response?.conversations ?? [], + loadPage: (response) => { + return list( + core.setObjectProperty(request, "pagination.starting_after", response?.pages?.next?.starting_after) + ); + }, + }); + } + + /** + * You can reply to a conversation with a message from an admin or on behalf of a contact, or with a note for admins. + * + * @param {Intercom.ReplyToConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.ForbiddenError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.conversations.reply({ + * conversation_id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d60f18a68186f43bafdf4" + * } + * }) + * + * @example + * await client.conversations.reply({ + * conversation_id: "123 or \"last\"", + * body: { + * message_type: "note", + * type: "admin", + * body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + * admin_id: "3156780" + * } + * }) + * + * @example + * await client.conversations.reply({ + * conversation_id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d60f78a68186f43bafdf7" + * } + * }) + * + * @example + * await client.conversations.reply({ + * conversation_id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d60f98a68186f43bafdf8" + * } + * }) + */ + public async reply( + request: Intercom.ReplyToConversationRequest, + requestOptions?: Conversations.RequestOptions + ): Promise { + const { conversation_id: conversationId, body: _body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/reply` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Conversation; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 403: + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /conversations/{conversation_id}/reply." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * For managing conversations you can: + * - Close a conversation + * - Snooze a conversation to reopen on a future date + * - Open a conversation which is `snoozed` or `closed` + * - Assign a conversation to an admin and/or team. + * + * @param {Intercom.ManageConversationPartsRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.ForbiddenError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.conversations.manage({ + * conversation_id: "123", + * body: { + * message_type: "assignment", + * type: "admin", + * admin_id: "12345", + * assignee_id: "4324241", + * body: "Goodbye :)" + * } + * }) + * + * @example + * await client.conversations.manage({ + * conversation_id: "123", + * body: { + * message_type: "assignment", + * type: "admin", + * admin_id: "12345", + * assignee_id: "4324241", + * body: "Let me pass you over to one of my colleagues." + * } + * }) + */ + public async manage( + request: Intercom.ManageConversationPartsRequest, + requestOptions?: Conversations.RequestOptions + ): Promise { + const { conversation_id: conversationId, body: _body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/parts` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Conversation; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 403: + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /conversations/{conversation_id}/parts." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can let a conversation be automatically assigned following assignment rules. + * {% admonition type="attention" name="When using workflows" %} + * It is not possible to use this endpoint with Workflows. + * {% /admonition %} + * + * @param {Intercom.AutoAssignConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.ForbiddenError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.conversations.runAssignmentRules({ + * conversation_id: "123" + * }) + */ + public async runAssignmentRules( + request: Intercom.AutoAssignConversationRequest, + requestOptions?: Conversations.RequestOptions + ): Promise { + const { conversation_id: conversationId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/run_assignment_rules` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Conversation; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 403: + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /conversations/{conversation_id}/run_assignment_rules." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. + * + * {% admonition type="attention" name="Contacts without an email" %} + * If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. + * {% /admonition %} + * + * + * @param {Intercom.AttachContactToConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.ForbiddenError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.conversations.attachContactAsAdmin({ + * conversation_id: "123", + * admin_id: "12345", + * customer: { + * intercom_user_id: "667d61168a68186f43bafe0d" + * } + * }) + * + * @example + * await client.conversations.attachContactAsAdmin({ + * conversation_id: "123", + * admin_id: "12345", + * customer: { + * intercom_user_id: "667d61188a68186f43bafe0e" + * } + * }) + */ + public async attachContactAsAdmin( + request: Intercom.AttachContactToConversationRequest, + requestOptions?: Conversations.RequestOptions + ): Promise { + const { conversation_id: conversationId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/customers` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Conversation; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 403: + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /conversations/{conversation_id}/customers." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. + * + * {% admonition type="attention" name="Contacts without an email" %} + * If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. + * {% /admonition %} + * + * + * @param {Intercom.DetachContactFromConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.ForbiddenError} + * @throws {@link Intercom.NotFoundError} + * @throws {@link Intercom.UnprocessableEntityError} + * + * @example + * await client.conversations.detachContactAsAdmin({ + * conversation_id: "123", + * contact_id: "123", + * admin_id: "5017690" + * }) + */ + public async detachContactAsAdmin( + request: Intercom.DetachContactFromConversationRequest, + requestOptions?: Conversations.RequestOptions + ): Promise { + const { conversation_id: conversationId, contact_id: contactId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/customers/${encodeURIComponent(contactId)}` + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Conversation; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 403: + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + case 422: + throw new Intercom.UnprocessableEntityError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /conversations/{conversation_id}/customers/{contact_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can redact a conversation part or the source message of a conversation (as seen in the source object). + * + * {% admonition type="info" name="Redacting parts and messages" %} + * If you are redacting a conversation part, it must have a `body`. If you are redacting a source message, it must have been created by a contact. We will return a `conversation_part_not_redactable` error if these criteria are not met. + * {% /admonition %} + * + * + * @param {Intercom.RedactConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.conversations.redactConversationPart({ + * type: "conversation_part", + * conversation_id: "19894788788", + * conversation_part_id: "19381789428" + * }) + * + * @example + * await client.conversations.redactConversationPart({ + * type: "conversation_part", + * conversation_id: "really_123_doesnt_exist", + * conversation_part_id: "really_123_doesnt_exist" + * }) + */ + public async redactConversationPart( + request: Intercom.RedactConversationRequest, + requestOptions?: Conversations.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "conversations/redact" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Conversation; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations/redact."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can convert a conversation to a ticket. + * + * @param {Intercom.ConvertConversationToTicketRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * + * @example + * await client.conversations.convertToTicket({ + * conversation_id: "123", + * ticket_type_id: "79" + * }) + * + * @example + * await client.conversations.convertToTicket({ + * conversation_id: "123", + * ticket_type_id: "80" + * }) + */ + public async convertToTicket( + request: Intercom.ConvertConversationToTicketRequest, + requestOptions?: Conversations.RequestOptions + ): Promise { + const { conversation_id: conversationId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/convert` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Ticket; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /conversations/{conversation_id}/convert." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/conversations/client/index.ts b/src/api/resources/conversations/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/conversations/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/conversations/client/requests/AttachContactToConversationRequest.ts b/src/api/resources/conversations/client/requests/AttachContactToConversationRequest.ts new file mode 100644 index 00000000..852c6c2f --- /dev/null +++ b/src/api/resources/conversations/client/requests/AttachContactToConversationRequest.ts @@ -0,0 +1,50 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../index"; + +/** + * @example + * { + * conversation_id: "123", + * admin_id: "12345", + * customer: { + * intercom_user_id: "667d61168a68186f43bafe0d" + * } + * } + * + * @example + * { + * conversation_id: "123", + * admin_id: "12345", + * customer: { + * intercom_user_id: "667d61188a68186f43bafe0e" + * } + * } + */ +export interface AttachContactToConversationRequest { + /** + * The identifier for the conversation as given by Intercom. + */ + conversation_id: string; + /** The `id` of the admin who is adding the new participant. */ + admin_id?: string; + customer?: AttachContactToConversationRequest.Customer; +} + +export namespace AttachContactToConversationRequest { + export type Customer = + | { + intercom_user_id: string; + customer?: Intercom.CustomerRequest | undefined; + } + | { + user_id: string; + customer?: Intercom.CustomerRequest | undefined; + } + | { + email: string; + customer?: Intercom.CustomerRequest | undefined; + }; +} diff --git a/src/api/resources/conversations/client/requests/AutoAssignConversationRequest.ts b/src/api/resources/conversations/client/requests/AutoAssignConversationRequest.ts new file mode 100644 index 00000000..b5f6e0c6 --- /dev/null +++ b/src/api/resources/conversations/client/requests/AutoAssignConversationRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * conversation_id: "123" + * } + */ +export interface AutoAssignConversationRequest { + /** + * The identifier for the conversation as given by Intercom. + */ + conversation_id: string; +} diff --git a/src/api/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts b/src/api/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts new file mode 100644 index 00000000..ce9e3abc --- /dev/null +++ b/src/api/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts @@ -0,0 +1,28 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../index"; + +/** + * @example + * { + * conversation_id: "123", + * ticket_type_id: "79" + * } + * + * @example + * { + * conversation_id: "123", + * ticket_type_id: "80" + * } + */ +export interface ConvertConversationToTicketRequest { + /** + * The id of the conversation to target + */ + conversation_id: string; + /** The ID of the type of ticket you want to convert the conversation to */ + ticket_type_id: string; + attributes?: Intercom.TicketRequestCustomAttributes; +} diff --git a/src/api/resources/conversations/client/requests/CreateConversationRequest.ts b/src/api/resources/conversations/client/requests/CreateConversationRequest.ts new file mode 100644 index 00000000..24e5403f --- /dev/null +++ b/src/api/resources/conversations/client/requests/CreateConversationRequest.ts @@ -0,0 +1,49 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * from: { + * type: "user", + * id: "667d60d18a68186f43bafddd" + * }, + * body: "Hello there" + * } + * + * @example + * { + * from: { + * type: "user", + * id: "123_doesnt_exist" + * }, + * body: "Hello there" + * } + */ +export interface CreateConversationRequest { + from: CreateConversationRequest.From; + /** The content of the message. HTML is not supported. */ + body: string; +} + +export namespace CreateConversationRequest { + export interface From { + /** The role associated to the contact - user or lead. */ + type: From.Type; + /** The identifier for the contact which is given by Intercom. */ + id: string; + } + + export namespace From { + /** + * The role associated to the contact - user or lead. + */ + export type Type = "lead" | "user" | "contact"; + export const Type = { + Lead: "lead", + User: "user", + Contact: "contact", + } as const; + } +} diff --git a/src/api/resources/conversations/client/requests/DetachContactFromConversationRequest.ts b/src/api/resources/conversations/client/requests/DetachContactFromConversationRequest.ts new file mode 100644 index 00000000..e245b23d --- /dev/null +++ b/src/api/resources/conversations/client/requests/DetachContactFromConversationRequest.ts @@ -0,0 +1,45 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * conversation_id: "123", + * contact_id: "123", + * admin_id: "5017690" + * } + * + * @example + * { + * conversation_id: "123", + * contact_id: "123", + * admin_id: "5017690" + * } + * + * @example + * { + * conversation_id: "123", + * contact_id: "123", + * admin_id: "5017690" + * } + * + * @example + * { + * conversation_id: "123", + * contact_id: "123", + * admin_id: "5017690" + * } + */ +export interface DetachContactFromConversationRequest { + /** + * The identifier for the conversation as given by Intercom. + */ + conversation_id: string; + /** + * The identifier for the contact as given by Intercom. + */ + contact_id: string; + /** The `id` of the admin who is performing the action. */ + admin_id: string; +} diff --git a/src/api/resources/conversations/client/requests/FindConversationRequest.ts b/src/api/resources/conversations/client/requests/FindConversationRequest.ts new file mode 100644 index 00000000..094cfa53 --- /dev/null +++ b/src/api/resources/conversations/client/requests/FindConversationRequest.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * conversation_id: "123", + * display_as: "plaintext" + * } + */ +export interface FindConversationRequest { + /** + * The id of the conversation to target + */ + conversation_id: string; + /** + * Set to plaintext to retrieve conversation messages in plain text. + */ + display_as?: string; +} diff --git a/src/api/resources/conversations/client/requests/ListConversationsRequest.ts b/src/api/resources/conversations/client/requests/ListConversationsRequest.ts new file mode 100644 index 00000000..f3c7f741 --- /dev/null +++ b/src/api/resources/conversations/client/requests/ListConversationsRequest.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * {} + */ +export interface ListConversationsRequest { + /** + * How many results per page + */ + per_page?: number; + /** + * String used to get the next page of conversations. + */ + starting_after?: string; +} diff --git a/src/api/resources/conversations/client/requests/ManageConversationPartsRequest.ts b/src/api/resources/conversations/client/requests/ManageConversationPartsRequest.ts new file mode 100644 index 00000000..1ad1d15b --- /dev/null +++ b/src/api/resources/conversations/client/requests/ManageConversationPartsRequest.ts @@ -0,0 +1,74 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../index"; + +/** + * @example + * { + * conversation_id: "123", + * body: { + * message_type: "assignment", + * type: "admin", + * admin_id: "12345", + * assignee_id: "4324241", + * body: "Goodbye :)" + * } + * } + * + * @example + * { + * conversation_id: "123", + * body: { + * message_type: "assignment", + * type: "admin", + * admin_id: "12345", + * assignee_id: "4324241", + * body: "Let me pass you over to one of my colleagues." + * } + * } + * + * @example + * { + * conversation_id: "123", + * body: { + * message_type: "assignment", + * type: "admin", + * admin_id: "12345", + * assignee_id: "4324241", + * body: "Let me pass you over to one of my colleagues." + * } + * } + * + * @example + * { + * conversation_id: "123", + * body: { + * message_type: "assignment", + * type: "admin", + * admin_id: "12345", + * assignee_id: "4324241", + * body: "Let me pass you over to one of my colleagues." + * } + * } + * + * @example + * { + * conversation_id: "123", + * body: { + * message_type: "assignment", + * type: "admin", + * admin_id: "12345", + * assignee_id: "4324241", + * body: "Goodbye :)" + * } + * } + */ +export interface ManageConversationPartsRequest { + /** + * The identifier for the conversation as given by Intercom. + */ + conversation_id: string; + body: Intercom.ConversationsManageRequestBody; +} diff --git a/src/api/resources/conversations/client/requests/ReplyToConversationRequest.ts b/src/api/resources/conversations/client/requests/ReplyToConversationRequest.ts new file mode 100644 index 00000000..e9ae5970 --- /dev/null +++ b/src/api/resources/conversations/client/requests/ReplyToConversationRequest.ts @@ -0,0 +1,91 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../index"; + +/** + * @example + * { + * conversation_id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d60f18a68186f43bafdf4" + * } + * } + * + * @example + * { + * conversation_id: "123 or \"last\"", + * body: { + * message_type: "note", + * type: "admin", + * body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + * admin_id: "3156780" + * } + * } + * + * @example + * { + * conversation_id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d60f78a68186f43bafdf7" + * } + * } + * + * @example + * { + * conversation_id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d60f98a68186f43bafdf8" + * } + * } + * + * @example + * { + * conversation_id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d60f18a68186f43bafdf4" + * } + * } + * + * @example + * { + * conversation_id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d60f18a68186f43bafdf4" + * } + * } + * + * @example + * { + * conversation_id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d60f18a68186f43bafdf4" + * } + * } + */ +export interface ReplyToConversationRequest { + /** + * The Intercom provisioned identifier for the conversation or the string "last" to reply to the last part of the conversation + */ + conversation_id: string; + body: Intercom.ReplyConversationRequest; +} diff --git a/src/api/resources/conversations/client/requests/UpdateConversationRequest.ts b/src/api/resources/conversations/client/requests/UpdateConversationRequest.ts new file mode 100644 index 00000000..0590a00c --- /dev/null +++ b/src/api/resources/conversations/client/requests/UpdateConversationRequest.ts @@ -0,0 +1,42 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../index"; + +/** + * @example + * { + * conversation_id: "123", + * display_as: "plaintext", + * read: true, + * custom_attributes: { + * "issue_type": "Billing", + * "priority": "High" + * } + * } + * + * @example + * { + * conversation_id: "123", + * display_as: "plaintext", + * read: true, + * custom_attributes: { + * "issue_type": "Billing", + * "priority": "High" + * } + * } + */ +export interface UpdateConversationRequest { + /** + * The id of the conversation to target + */ + conversation_id: string; + /** + * Set to plaintext to retrieve conversation messages in plain text. + */ + display_as?: string; + /** Mark a conversation as read within Intercom. */ + read?: boolean; + custom_attributes?: Intercom.CustomAttributes; +} diff --git a/src/api/resources/conversations/client/requests/index.ts b/src/api/resources/conversations/client/requests/index.ts new file mode 100644 index 00000000..fa317731 --- /dev/null +++ b/src/api/resources/conversations/client/requests/index.ts @@ -0,0 +1,10 @@ +export { type ListConversationsRequest } from "./ListConversationsRequest"; +export { type CreateConversationRequest } from "./CreateConversationRequest"; +export { type FindConversationRequest } from "./FindConversationRequest"; +export { type UpdateConversationRequest } from "./UpdateConversationRequest"; +export { type ReplyToConversationRequest } from "./ReplyToConversationRequest"; +export { type ManageConversationPartsRequest } from "./ManageConversationPartsRequest"; +export { type AutoAssignConversationRequest } from "./AutoAssignConversationRequest"; +export { type AttachContactToConversationRequest } from "./AttachContactToConversationRequest"; +export { type DetachContactFromConversationRequest } from "./DetachContactFromConversationRequest"; +export { type ConvertConversationToTicketRequest } from "./ConvertConversationToTicketRequest"; diff --git a/src/api/resources/conversations/index.ts b/src/api/resources/conversations/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/conversations/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/conversations/types/Conversation.ts b/src/api/resources/conversations/types/Conversation.ts new file mode 100644 index 00000000..3e08c1b6 --- /dev/null +++ b/src/api/resources/conversations/types/Conversation.ts @@ -0,0 +1,71 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Conversations are how you can communicate with users in Intercom. They are created when a contact replies to an outbound message, or when one admin directly sends a message to a single contact. + */ +export interface Conversation { + /** Always conversation. */ + type?: "conversation"; + /** The id representing the conversation. */ + id: string; + /** The title given to the conversation. */ + title?: string; + /** The time the conversation was created. */ + created_at: number; + /** The last time the conversation was updated. */ + updated_at: number; + /** The last time a Contact responded to an Admin. In other words, the time a customer started waiting for a response. Set to null if last reply is from an Admin. */ + waiting_since?: number; + /** If set this is the time in the future when this conversation will be marked as open. i.e. it will be in a snoozed state until this time. i.e. it will be in a snoozed state until this time. */ + snoozed_until?: number; + /** Indicates whether a conversation is open (true) or closed (false). */ + open: boolean; + /** Can be set to "open", "closed" or "snoozed". */ + state: Conversation.State; + /** Indicates whether a conversation has been read. */ + read: boolean; + /** If marked as priority, it will return priority or else not_priority. */ + priority?: Conversation.Priority; + /** The id of the admin assigned to the conversation. If it's not assigned to an admin it will return null. */ + admin_assignee_id?: number; + /** The id of the team assigned to the conversation. If it's not assigned to a team it will return null. */ + team_assignee_id?: string; + tags?: Intercom.Tags; + conversation_rating?: Intercom.ConversationRating; + source: Intercom.ConversationSource; + contacts: Intercom.ConversationContacts; + teammates: Intercom.ConversationTeammates; + custom_attributes: Intercom.CustomAttributes; + first_contact_reply?: Intercom.ConversationFirstContactReply; + sla_applied?: Intercom.SlaApplied; + statistics?: Intercom.ConversationStatistics; + conversation_parts?: Intercom.ConversationParts; + linked_objects?: Intercom.LinkedObjectList; + /** Indicates whether the AI Agent participated in the conversation. */ + ai_agent_participated?: boolean; + ai_agent?: Intercom.AiAgent; +} + +export namespace Conversation { + /** + * Can be set to "open", "closed" or "snoozed". + */ + export type State = "open" | "closed" | "snoozed"; + export const State = { + Open: "open", + Closed: "closed", + Snoozed: "snoozed", + } as const; + /** + * If marked as priority, it will return priority or else not_priority. + */ + export type Priority = "priority" | "not_priority"; + export const Priority = { + Priority: "priority", + NotPriority: "not_priority", + } as const; +} diff --git a/src/api/resources/conversations/types/ConversationsManageRequestBody.ts b/src/api/resources/conversations/types/ConversationsManageRequestBody.ts new file mode 100644 index 00000000..232eb1e2 --- /dev/null +++ b/src/api/resources/conversations/types/ConversationsManageRequestBody.ts @@ -0,0 +1,29 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +export type ConversationsManageRequestBody = + | Intercom.ConversationsManageRequestBody.Close + | Intercom.ConversationsManageRequestBody.Snoozed + | Intercom.ConversationsManageRequestBody.Open + | Intercom.ConversationsManageRequestBody.Assignment; + +export namespace ConversationsManageRequestBody { + export interface Close extends Intercom.CloseConversationRequest { + message_type: "close"; + } + + export interface Snoozed extends Intercom.SnoozeConversationRequest { + message_type: "snoozed"; + } + + export interface Open extends Intercom.OpenConversationRequest { + message_type: "open"; + } + + export interface Assignment extends Intercom.AssignConversationRequest { + message_type: "assignment"; + } +} diff --git a/src/api/resources/conversations/types/index.ts b/src/api/resources/conversations/types/index.ts new file mode 100644 index 00000000..7ff13377 --- /dev/null +++ b/src/api/resources/conversations/types/index.ts @@ -0,0 +1,2 @@ +export * from "./ConversationsManageRequestBody"; +export * from "./Conversation"; diff --git a/src/api/resources/customObjectInstances/index.ts b/src/api/resources/customObjectInstances/index.ts new file mode 100644 index 00000000..eea524d6 --- /dev/null +++ b/src/api/resources/customObjectInstances/index.ts @@ -0,0 +1 @@ +export * from "./types"; diff --git a/src/api/resources/customObjectInstances/types/CustomObjectInstance.ts b/src/api/resources/customObjectInstances/types/CustomObjectInstance.ts new file mode 100644 index 00000000..4f43cee0 --- /dev/null +++ b/src/api/resources/customObjectInstances/types/CustomObjectInstance.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A Custom Object Instance represents an instance of a custom object type. This allows you to create and set custom attributes to store data about your customers that is not already captured by Intercom. The parent object includes recommended default attributes and you can add your own custom attributes. + */ +export interface CustomObjectInstance { + /** The Intercom defined id representing the custom object instance. */ + id: string; + /** The id you have defined for the custom object instance. */ + external_id?: string; + /** The identifier of the custom object type that defines the structure of the custom object instance. */ + type: string; + /** The custom attributes you have set on the custom object instance. */ + custom_attributes?: Record; +} diff --git a/src/api/resources/customObjectInstances/types/index.ts b/src/api/resources/customObjectInstances/types/index.ts new file mode 100644 index 00000000..d5c782f8 --- /dev/null +++ b/src/api/resources/customObjectInstances/types/index.ts @@ -0,0 +1 @@ +export * from "./CustomObjectInstance"; diff --git a/src/api/resources/dataAttributes/client/Client.ts b/src/api/resources/dataAttributes/client/Client.ts new file mode 100644 index 00000000..d3ca59dc --- /dev/null +++ b/src/api/resources/dataAttributes/client/Client.ts @@ -0,0 +1,395 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace DataAttributes { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Data Attributes + */ +export class DataAttributes { + constructor(protected readonly _options: DataAttributes.Options = {}) {} + + /** + * You can fetch a list of all data attributes belonging to a workspace for contacts, companies or conversations. + * + * @param {Intercom.ListDataAttributesRequest} request + * @param {DataAttributes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.dataAttributes.list() + */ + public async list( + request: Intercom.ListDataAttributesRequest = {}, + requestOptions?: DataAttributes.RequestOptions + ): Promise { + const { model, include_archived: includeArchived } = request; + const _queryParams: Record = {}; + if (model != null) { + _queryParams["model"] = model; + } + + if (includeArchived != null) { + _queryParams["include_archived"] = includeArchived.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "data_attributes" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.DataAttributeList; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /data_attributes."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can create a data attributes for a `contact` or a `company`. + * + * @param {Intercom.CreateDataAttributeRequest} request + * @param {DataAttributes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.dataAttributes.create({ + * name: "Mithril Shirt", + * model: "company", + * data_type: "string" + * }) + * + * @example + * await client.dataAttributes.create({ + * name: "The One Ring", + * model: "contact", + * data_type: "integer" + * }) + * + * @example + * await client.dataAttributes.create({ + * name: "!nv@l!d n@me", + * model: "company", + * data_type: "string" + * }) + * + * @example + * await client.dataAttributes.create({ + * name: "The One Ring", + * model: "company", + * data_type: "string" + * }) + * + * @example + * await client.dataAttributes.create({ + * name: "The Second Ring", + * model: "company", + * data_type: "string" + * }) + * + * @example + * await client.dataAttributes.create({ + * name: "My Data Attribute", + * model: "contact", + * data_type: "string", + * description: "Just a plain old ring", + * options: ["options"] + * }) + */ + public async create( + request: Intercom.CreateDataAttributeRequest, + requestOptions?: DataAttributes.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "data_attributes" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.DataAttribute; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown); + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /data_attributes."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * + * You can update a data attribute. + * + * > 🚧 Updating the data type is not possible + * > + * > It is currently a dangerous action to execute changing a data attribute's type via the API. You will need to update the type via the UI instead. + * + * @param {Intercom.UpdateDataAttributeRequest} request + * @param {DataAttributes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * @throws {@link Intercom.UnprocessableEntityError} + * + * @example + * await client.dataAttributes.update({ + * data_attribute_id: "1", + * archived: false, + * description: "Just a plain old ring", + * options: [{ + * value: "1-10" + * }, { + * value: "11-20" + * }] + * }) + * + * @example + * await client.dataAttributes.update({ + * data_attribute_id: "1", + * archived: false, + * description: "Too few options", + * options: [{ + * value: "value" + * }, { + * value: "value" + * }] + * }) + * + * @example + * await client.dataAttributes.update({ + * data_attribute_id: "1", + * archived: true, + * description: "Trying to archieve" + * }) + */ + public async update( + request: Intercom.UpdateDataAttributeRequest, + requestOptions?: DataAttributes.RequestOptions + ): Promise { + const { data_attribute_id: dataAttributeId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `data_attributes/${encodeURIComponent(dataAttributeId)}` + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.DataAttribute; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown); + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + case 422: + throw new Intercom.UnprocessableEntityError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling PUT /data_attributes/{data_attribute_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/dataAttributes/client/index.ts b/src/api/resources/dataAttributes/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/dataAttributes/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts b/src/api/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts new file mode 100644 index 00000000..d0856471 --- /dev/null +++ b/src/api/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts @@ -0,0 +1,86 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * name: "Mithril Shirt", + * model: "company", + * data_type: "string" + * } + * + * @example + * { + * name: "The One Ring", + * model: "contact", + * data_type: "integer" + * } + * + * @example + * { + * name: "!nv@l!d n@me", + * model: "company", + * data_type: "string" + * } + * + * @example + * { + * name: "The One Ring", + * model: "company", + * data_type: "string" + * } + * + * @example + * { + * name: "The Second Ring", + * model: "company", + * data_type: "string" + * } + * + * @example + * { + * name: "My Data Attribute", + * model: "contact", + * data_type: "string", + * description: "Just a plain old ring", + * options: ["options"] + * } + */ +export interface CreateDataAttributeRequest { + /** The name of the data attribute. */ + name: string; + /** The model that the data attribute belongs to. */ + model: CreateDataAttributeRequest.Model; + /** The type of data stored for this attribute. */ + data_type: CreateDataAttributeRequest.DataType; + /** The readable description you see in the UI for the attribute. */ + description?: string; + /** To create list attributes. Provide a set of hashes with `value` as the key of the options you want to make. `data_type` must be `string`. */ + options?: string[]; + /** Can this attribute be updated by the Messenger */ + messenger_writable?: boolean; +} + +export namespace CreateDataAttributeRequest { + /** + * The model that the data attribute belongs to. + */ + export type Model = "contact" | "company"; + export const Model = { + Contact: "contact", + Company: "company", + } as const; + /** + * The type of data stored for this attribute. + */ + export type DataType = "string" | "integer" | "float" | "boolean" | "datetime" | "date"; + export const DataType = { + String: "string", + Integer: "integer", + Float: "float", + Boolean: "boolean", + Datetime: "datetime", + Date: "date", + } as const; +} diff --git a/src/api/resources/dataAttributes/client/requests/ListDataAttributesRequest.ts b/src/api/resources/dataAttributes/client/requests/ListDataAttributesRequest.ts new file mode 100644 index 00000000..5d9ee979 --- /dev/null +++ b/src/api/resources/dataAttributes/client/requests/ListDataAttributesRequest.ts @@ -0,0 +1,20 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../index"; + +/** + * @example + * {} + */ +export interface ListDataAttributesRequest { + /** + * Specify the data attribute model to return. + */ + model?: Intercom.DataAttributesListRequestModel; + /** + * Include archived attributes in the list. By default we return only non archived data attributes. + */ + include_archived?: boolean; +} diff --git a/src/api/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts b/src/api/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts new file mode 100644 index 00000000..5ea8b95d --- /dev/null +++ b/src/api/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts @@ -0,0 +1,72 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * data_attribute_id: "1", + * archived: false, + * description: "Just a plain old ring", + * options: [{ + * value: "1-10" + * }, { + * value: "11-20" + * }] + * } + * + * @example + * { + * data_attribute_id: "1", + * archived: false, + * description: "Too few options", + * options: [{ + * value: "value" + * }, { + * value: "value" + * }] + * } + * + * @example + * { + * data_attribute_id: "1", + * archived: false, + * description: "Just a plain old ring", + * options: [{ + * value: "1-10" + * }, { + * value: "11-20" + * }] + * } + * + * @example + * { + * data_attribute_id: "1", + * archived: true, + * description: "Trying to archieve" + * } + */ +export interface UpdateDataAttributeRequest { + /** + * The data attribute id + */ + data_attribute_id: string; + /** Whether the attribute is to be archived or not. */ + archived?: boolean; + /** The readable description you see in the UI for the attribute. */ + description?: string; + /** To create list attributes. Provide a set of hashes with `value` as the key of the options you want to make. `data_type` must be `string`. */ + options?: UpdateDataAttributeRequest.Options.Item[]; + /** Can this attribute be updated by the Messenger */ + messenger_writable?: boolean; +} + +export namespace UpdateDataAttributeRequest { + export type Options = Options.Item[]; + + export namespace Options { + export interface Item { + value: string; + } + } +} diff --git a/src/api/resources/dataAttributes/client/requests/index.ts b/src/api/resources/dataAttributes/client/requests/index.ts new file mode 100644 index 00000000..6a7a0de5 --- /dev/null +++ b/src/api/resources/dataAttributes/client/requests/index.ts @@ -0,0 +1,3 @@ +export { type ListDataAttributesRequest } from "./ListDataAttributesRequest"; +export { type CreateDataAttributeRequest } from "./CreateDataAttributeRequest"; +export { type UpdateDataAttributeRequest } from "./UpdateDataAttributeRequest"; diff --git a/src/api/resources/dataAttributes/index.ts b/src/api/resources/dataAttributes/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/dataAttributes/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/dataAttributes/types/DataAttribute.ts b/src/api/resources/dataAttributes/types/DataAttribute.ts new file mode 100644 index 00000000..1ce04881 --- /dev/null +++ b/src/api/resources/dataAttributes/types/DataAttribute.ts @@ -0,0 +1,65 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Data Attributes are metadata used to describe your contact, company and conversation models. These include standard and custom attributes. By using the data attributes endpoint, you can get the global list of attributes for your workspace, as well as create and archive custom attributes. + */ +export interface DataAttribute { + /** Value is `data_attribute`. */ + type: "data_attribute"; + /** The unique identifier for the data attribute which is given by Intercom. Only available for custom attributes. */ + id?: number; + /** Value is `contact` for user/lead attributes and `company` for company attributes. */ + model?: DataAttribute.Model; + /** Name of the attribute. */ + name: string; + /** Full name of the attribute. Should match the name unless it's a nested attribute. We can split full_name on `.` to access nested user object values. */ + full_name: string; + /** Readable name of the attribute (i.e. name you see in the UI) */ + label: string; + /** Readable description of the attribute. */ + description: string; + /** The data type of the attribute. */ + data_type: DataAttribute.DataType; + /** List of predefined options for attribute value. */ + options?: string[]; + /** Can this attribute be updated through API */ + api_writable?: boolean; + /** Can this attribute be updated by the Messenger */ + messenger_writable?: boolean; + /** Can this attribute be updated in the UI */ + ui_writable?: boolean; + /** Set to true if this is a CDA */ + custom?: boolean; + /** Is this attribute archived. (Only applicable to CDAs) */ + archived?: boolean; + /** The time the attribute was created as a UTC Unix timestamp */ + created_at?: number; + /** The time the attribute was last updated as a UTC Unix timestamp */ + updated_at?: number; + /** Teammate who created the attribute. Only applicable to CDAs */ + admin_id?: string; +} + +export namespace DataAttribute { + /** + * Value is `contact` for user/lead attributes and `company` for company attributes. + */ + export type Model = "contact" | "company"; + export const Model = { + Contact: "contact", + Company: "company", + } as const; + /** + * The data type of the attribute. + */ + export type DataType = "string" | "integer" | "float" | "boolean" | "date"; + export const DataType = { + String: "string", + Integer: "integer", + Float: "float", + Boolean: "boolean", + Date: "date", + } as const; +} diff --git a/src/api/resources/dataAttributes/types/DataAttributesListRequestModel.ts b/src/api/resources/dataAttributes/types/DataAttributesListRequestModel.ts new file mode 100644 index 00000000..4c163f30 --- /dev/null +++ b/src/api/resources/dataAttributes/types/DataAttributesListRequestModel.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type DataAttributesListRequestModel = "contact" | "company" | "conversation"; +export const DataAttributesListRequestModel = { + Contact: "contact", + Company: "company", + Conversation: "conversation", +} as const; diff --git a/src/api/resources/dataAttributes/types/index.ts b/src/api/resources/dataAttributes/types/index.ts new file mode 100644 index 00000000..70dcfefc --- /dev/null +++ b/src/api/resources/dataAttributes/types/index.ts @@ -0,0 +1,2 @@ +export * from "./DataAttributesListRequestModel"; +export * from "./DataAttribute"; diff --git a/src/api/resources/dataEvents/index.ts b/src/api/resources/dataEvents/index.ts new file mode 100644 index 00000000..eea524d6 --- /dev/null +++ b/src/api/resources/dataEvents/index.ts @@ -0,0 +1 @@ +export * from "./types"; diff --git a/src/api/resources/dataEvents/types/DataEvent.ts b/src/api/resources/dataEvents/types/DataEvent.ts new file mode 100644 index 00000000..124221eb --- /dev/null +++ b/src/api/resources/dataEvents/types/DataEvent.ts @@ -0,0 +1,25 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Data events are used to notify Intercom of changes to your data. + */ +export interface DataEvent { + /** The type of the object */ + type?: "event"; + /** The name of the event that occurred. This is presented to your App's admins when filtering and creating segments - a good event name is typically a past tense 'verb-noun' combination, to improve readability, for example `updated-plan`. */ + event_name: string; + /** The time the event occurred as a UTC Unix timestamp */ + created_at: number; + /** Your identifier for the user. */ + user_id?: string; + /** Your identifier for a lead or a user. */ + id?: string; + /** The Intercom identifier for the user. */ + intercom_user_id?: string; + /** An email address for your user. An email should only be used where your application uses email to uniquely identify users. */ + email?: string; + /** Optional metadata about the event. */ + metadata?: Record; +} diff --git a/src/api/resources/dataEvents/types/index.ts b/src/api/resources/dataEvents/types/index.ts new file mode 100644 index 00000000..9b28ca3c --- /dev/null +++ b/src/api/resources/dataEvents/types/index.ts @@ -0,0 +1 @@ +export * from "./DataEvent"; diff --git a/src/api/resources/dataExport/client/Client.ts b/src/api/resources/dataExport/client/Client.ts new file mode 100644 index 00000000..47032822 --- /dev/null +++ b/src/api/resources/dataExport/client/Client.ts @@ -0,0 +1,377 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace DataExport { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Data Exports + */ +export class DataExport { + constructor(protected readonly _options: DataExport.Options = {}) {} + + /** + * To create your export job, you need to send a `POST` request to the export endpoint `https://api.intercom.io/export/content/data`. + * + * The only parameters you need to provide are the range of dates that you want exported. + * + * >🚧 Limit of one active job + * > + * > You can only have one active job per workspace. You will receive a HTTP status code of 429 with the message Exceeded rate limit of 1 pending message data export jobs if you attempt to create a second concurrent job. + * + * >❗️ Updated_at not included + * > + * > It should be noted that the timeframe only includes messages sent during the time period and not messages that were only updated during this period. For example, if a message was updated yesterday but sent two days ago, you would need to set the created_at_after date before the message was sent to include that in your retrieval job. + * + * >📘 Date ranges are inclusive + * > + * > Requesting data for 2018-06-01 until 2018-06-30 will get all data for those days including those specified - e.g. 2018-06-01 00:00:00 until 2018-06-30 23:59:99. + * + * @param {Intercom.CreateDataExportRequest} request + * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.dataExport.create({ + * created_at_after: 1719474967, + * created_at_before: 1719492967 + * }) + */ + public async create( + request: Intercom.CreateDataExportRequest, + requestOptions?: DataExport.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "export/content/data" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.DataExport; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /export/content/data."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can view the status of your job by sending a `GET` request to the URL + * `https://api.intercom.io/export/content/data/{job_identifier}` - the `{job_identifier}` is the value returned in the response when you first created the export job. More on it can be seen in the Export Job Model. + * + * > 🚧 Jobs expire after two days + * > All jobs that have completed processing (and are thus available to download from the provided URL) will have an expiry limit of two days from when the export ob completed. After this, the data will no longer be available. + * + * @param {Intercom.FindDataExportRequest} request + * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.dataExport.find({ + * job_identifier: "job_identifier" + * }) + */ + public async find( + request: Intercom.FindDataExportRequest, + requestOptions?: DataExport.RequestOptions + ): Promise { + const { job_identifier: jobIdentifier } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `export/content/data/${encodeURIComponent(jobIdentifier)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.DataExport; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /export/content/data/{job_identifier}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can cancel your job + * + * @param {Intercom.CancelDataExportRequest} request + * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.dataExport.cancel({ + * job_identifier: "job_identifier" + * }) + */ + public async cancel( + request: Intercom.CancelDataExportRequest, + requestOptions?: DataExport.RequestOptions + ): Promise { + const { job_identifier: jobIdentifier } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `export/cancel/${encodeURIComponent(jobIdentifier)}` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.DataExport; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /export/cancel/{job_identifier}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * When a job has a status of complete, and thus a filled download_url, you can download your data by hitting that provided URL, formatted like so: https://api.intercom.io/download/content/data/xyz1234. + * + * Your exported message data will be streamed continuously back down to you in a gzipped CSV format. + * + * > 📘 Octet header required + * > + * > You will have to specify the header Accept: `application/octet-stream` when hitting this endpoint. + * + * @param {Intercom.DownloadDataExportRequest} request + * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.dataExport.download({ + * job_identifier: "job_identifier" + * }) + */ + public async download( + request: Intercom.DownloadDataExportRequest, + requestOptions?: DataExport.RequestOptions + ): Promise { + const { job_identifier: jobIdentifier } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `download/content/data/${encodeURIComponent(jobIdentifier)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /download/content/data/{job_identifier}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/dataExport/client/index.ts b/src/api/resources/dataExport/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/dataExport/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/dataExport/client/requests/CancelDataExportRequest.ts b/src/api/resources/dataExport/client/requests/CancelDataExportRequest.ts new file mode 100644 index 00000000..39ed6925 --- /dev/null +++ b/src/api/resources/dataExport/client/requests/CancelDataExportRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * job_identifier: "job_identifier" + * } + */ +export interface CancelDataExportRequest { + /** + * job_identifier + */ + job_identifier: string; +} diff --git a/src/api/resources/dataExport/client/requests/CreateDataExportRequest.ts b/src/api/resources/dataExport/client/requests/CreateDataExportRequest.ts new file mode 100644 index 00000000..d8b4e380 --- /dev/null +++ b/src/api/resources/dataExport/client/requests/CreateDataExportRequest.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * created_at_after: 1719474967, + * created_at_before: 1719492967 + * } + */ +export interface CreateDataExportRequest { + /** The start date that you request data for. It must be formatted as a unix timestamp. */ + created_at_after: number; + /** The end date that you request data for. It must be formatted as a unix timestamp. */ + created_at_before: number; +} diff --git a/src/api/resources/dataExport/client/requests/DownloadDataExportRequest.ts b/src/api/resources/dataExport/client/requests/DownloadDataExportRequest.ts new file mode 100644 index 00000000..4a7ee828 --- /dev/null +++ b/src/api/resources/dataExport/client/requests/DownloadDataExportRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * job_identifier: "job_identifier" + * } + */ +export interface DownloadDataExportRequest { + /** + * job_identifier + */ + job_identifier: string; +} diff --git a/src/api/resources/dataExport/client/requests/FindDataExportRequest.ts b/src/api/resources/dataExport/client/requests/FindDataExportRequest.ts new file mode 100644 index 00000000..fc5c67b4 --- /dev/null +++ b/src/api/resources/dataExport/client/requests/FindDataExportRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * job_identifier: "job_identifier" + * } + */ +export interface FindDataExportRequest { + /** + * job_identifier + */ + job_identifier: string; +} diff --git a/src/api/resources/dataExport/client/requests/index.ts b/src/api/resources/dataExport/client/requests/index.ts new file mode 100644 index 00000000..fa7821f6 --- /dev/null +++ b/src/api/resources/dataExport/client/requests/index.ts @@ -0,0 +1,4 @@ +export { type CreateDataExportRequest } from "./CreateDataExportRequest"; +export { type FindDataExportRequest } from "./FindDataExportRequest"; +export { type CancelDataExportRequest } from "./CancelDataExportRequest"; +export { type DownloadDataExportRequest } from "./DownloadDataExportRequest"; diff --git a/src/api/resources/dataExport/index.ts b/src/api/resources/dataExport/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/dataExport/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/dataExport/types/DataExport.ts b/src/api/resources/dataExport/types/DataExport.ts new file mode 100644 index 00000000..fbb48fc4 --- /dev/null +++ b/src/api/resources/dataExport/types/DataExport.ts @@ -0,0 +1,32 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The data export api is used to view all message sent & viewed in a given timeframe. + */ +export interface DataExport { + /** The identifier for your job. */ + job_identifier: string; + /** The current state of your job. */ + status: DataExport.Status; + /** The time after which you will not be able to access the data. */ + download_expires_at: string; + /** The location where you can download your data. */ + download_url: string; +} + +export namespace DataExport { + /** + * The current state of your job. + */ + export type Status = "pending" | "in_progress" | "failed" | "completed" | "no_data" | "canceled"; + export const Status = { + Pending: "pending", + InProgress: "in_progress", + Failed: "failed", + Completed: "completed", + NoData: "no_data", + Canceled: "canceled", + } as const; +} diff --git a/src/api/resources/dataExport/types/index.ts b/src/api/resources/dataExport/types/index.ts new file mode 100644 index 00000000..7cea751a --- /dev/null +++ b/src/api/resources/dataExport/types/index.ts @@ -0,0 +1 @@ +export * from "./DataExport"; diff --git a/src/api/resources/events/client/Client.ts b/src/api/resources/events/client/Client.ts new file mode 100644 index 00000000..6862abba --- /dev/null +++ b/src/api/resources/events/client/Client.ts @@ -0,0 +1,384 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace Events { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +export class Events { + constructor(protected readonly _options: Events.Options = {}) {} + + /** + * + * > 🚧 + * > + * > Please note that you can only 'list' events that are less than 90 days old. Event counts and summaries will still include your events older than 90 days but you cannot 'list' these events individually if they are older than 90 days + * + * The events belonging to a customer can be listed by sending a GET request to `https://api.intercom.io/events` with a user or lead identifier along with a `type` parameter. The identifier parameter can be one of `user_id`, `email` or `intercom_user_id`. The `type` parameter value must be `user`. + * + * - `https://api.intercom.io/events?type=user&user_id={user_id}` + * - `https://api.intercom.io/events?type=user&email={email}` + * - `https://api.intercom.io/events?type=user&intercom_user_id={id}` (this call can be used to list leads) + * + * The `email` parameter value should be [url encoded](http://en.wikipedia.org/wiki/Percent-encoding) when sending. + * + * You can optionally define the result page size as well with the `per_page` parameter. + * + * @param {Intercom.ListEventsRequest} request + * @param {Events.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.events.list({ + * type: "type" + * }) + */ + public async list( + request: Intercom.ListEventsRequest, + requestOptions?: Events.RequestOptions + ): Promise { + const { + user_id: userId, + intercom_user_id: intercomUserId, + email, + type: type_, + summary, + per_page: perPage, + } = request; + const _queryParams: Record = {}; + if (userId != null) { + _queryParams["user_id"] = userId; + } + + if (intercomUserId != null) { + _queryParams["intercom_user_id"] = intercomUserId; + } + + if (email != null) { + _queryParams["email"] = email; + } + + _queryParams["type"] = type_; + if (summary != null) { + _queryParams["summary"] = summary.toString(); + } + + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "events" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.DataEventSummary; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /events."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * + * You will need an Access Token that has write permissions to send Events. Once you have a key you can submit events via POST to the Events resource, which is located at https://api.intercom.io/events, or you can send events using one of the client libraries. When working with the HTTP API directly a client should send the event with a `Content-Type` of `application/json`. + * + * When using the JavaScript API, [adding the code to your app](http://docs.intercom.io/configuring-Intercom/tracking-user-events-in-your-app) makes the Events API available. Once added, you can submit an event using the `trackEvent` method. This will associate the event with the Lead or currently logged-in user or logged-out visitor/lead and send it to Intercom. The final parameter is a map that can be used to send optional metadata about the event. + * + * With the Ruby client you pass a hash describing the event to `Intercom::Event.create`, or call the `track_user` method directly on the current user object (e.g. `user.track_event`). + * + * **NB: For the JSON object types, please note that we do not currently support nested JSON structure.** + * + * | Type | Description | Example | + * | :-------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------- | + * | String | The value is a JSON String | `"source":"desktop"` | + * | Number | The value is a JSON Number | `"load": 3.67` | + * | Date | The key ends with the String `_date` and the value is a [Unix timestamp](http://en.wikipedia.org/wiki/Unix_time), assumed to be in the [UTC](http://en.wikipedia.org/wiki/Coordinated_Universal_Time) timezone. | `"contact_date": 1392036272` | + * | Link | The value is a HTTP or HTTPS URI. | `"article": "https://example.org/ab1de.html"` | + * | Rich Link | The value is a JSON object that contains `url` and `value` keys. | `"article": {"url": "https://example.org/ab1de.html", "value":"the dude abides"}` | + * | Monetary Amount | The value is a JSON object that contains `amount` and `currency` keys. The `amount` key is a positive integer representing the amount in cents. The price in the example to the right denotes €349.99. | `"price": {"amount": 34999, "currency": "eur"}` | + * + * **Lead Events** + * + * When submitting events for Leads, you will need to specify the Lead's `id`. + * + * **Metadata behaviour** + * + * - We currently limit the number of tracked metadata keys to 10 per event. Once the quota is reached, we ignore any further keys we receive. The first 10 metadata keys are determined by the order in which they are sent in with the event. + * - It is not possible to change the metadata keys once the event has been sent. A new event will need to be created with the new keys and you can archive the old one. + * - There might be up to 24 hrs delay when you send a new metadata for an existing event. + * + * **Event de-duplication** + * + * The API may detect and ignore duplicate events. Each event is uniquely identified as a combination of the following data - the Workspace identifier, the Contact external identifier, the Data Event name and the Data Event created time. As a result, it is **strongly recommended** to send a second granularity Unix timestamp in the `created_at` field. + * + * Duplicated events are responded to using the normal `202 Accepted` code - an error is not thrown, however repeat requests will be counted against any rate limit that is in place. + * + * ### HTTP API Responses + * + * - Successful responses to submitted events return `202 Accepted` with an empty body. + * - Unauthorised access will be rejected with a `401 Unauthorized` or `403 Forbidden` response code. + * - Events sent about users that cannot be found will return a `404 Not Found`. + * - Event lists containing duplicate events will have those duplicates ignored. + * - Server errors will return a `500` response code and may contain an error message in the body. + * + * + * @param {Intercom.CreateDataEventRequest} request + * @param {Events.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.events.create({ + * id: "8a88a590-e1c3-41e2-a502-e0649dbf721c", + * event_name: "invited-friend", + * created_at: 1671028894 + * }) + */ + public async create( + request: Intercom.CreateDataEventRequest, + requestOptions?: Events.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "events" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /events."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * Create event summaries for a user. Event summaries are used to track the number of times an event has occurred, the first time it occurred and the last time it occurred. + * + * + * @param {Intercom.ListEventSummariesRequest} request + * @param {Events.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.events.summaries() + */ + public async summaries( + request: Intercom.ListEventSummariesRequest = {}, + requestOptions?: Events.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "events/summaries" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /events/summaries."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/events/client/index.ts b/src/api/resources/events/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/events/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/events/client/requests/ListEventSummariesRequest.ts b/src/api/resources/events/client/requests/ListEventSummariesRequest.ts new file mode 100644 index 00000000..b1f4c485 --- /dev/null +++ b/src/api/resources/events/client/requests/ListEventSummariesRequest.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * {} + */ +export interface ListEventSummariesRequest { + /** Your identifier for the user. */ + user_id?: string; + /** A list of event summaries for the user. Each event summary should contain the event name, the time the event occurred, and the number of times the event occurred. The event name should be a past tense 'verb-noun' combination, to improve readability, for example `updated-plan`. */ + event_summaries?: ListEventSummariesRequest.EventSummaries; +} + +export namespace ListEventSummariesRequest { + /** + * A list of event summaries for the user. Each event summary should contain the event name, the time the event occurred, and the number of times the event occurred. The event name should be a past tense 'verb-noun' combination, to improve readability, for example `updated-plan`. + */ + export interface EventSummaries { + /** The name of the event that occurred. A good event name is typically a past tense 'verb-noun' combination, to improve readability, for example `updated-plan`. */ + event_name?: string; + /** The number of times the event occurred. */ + count?: number; + /** The first time the event was sent */ + first?: number; + /** The last time the event was sent */ + last?: number; + } +} diff --git a/src/api/resources/events/client/requests/ListEventsRequest.ts b/src/api/resources/events/client/requests/ListEventsRequest.ts new file mode 100644 index 00000000..c77ac53b --- /dev/null +++ b/src/api/resources/events/client/requests/ListEventsRequest.ts @@ -0,0 +1,36 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * type: "type" + * } + */ +export interface ListEventsRequest { + /** + * user_id query parameter + */ + user_id?: string; + /** + * intercom_user_id query parameter + */ + intercom_user_id?: string; + /** + * email query parameter + */ + email?: string; + /** + * The value must be user + */ + type: string; + /** + * summary flag + */ + summary?: boolean; + /** + * How many results to display per page. Defaults to 15 + */ + per_page?: number; +} diff --git a/src/api/resources/events/client/requests/index.ts b/src/api/resources/events/client/requests/index.ts new file mode 100644 index 00000000..25f04352 --- /dev/null +++ b/src/api/resources/events/client/requests/index.ts @@ -0,0 +1,2 @@ +export { type ListEventsRequest } from "./ListEventsRequest"; +export { type ListEventSummariesRequest } from "./ListEventSummariesRequest"; diff --git a/src/api/resources/events/index.ts b/src/api/resources/events/index.ts new file mode 100644 index 00000000..5ec76921 --- /dev/null +++ b/src/api/resources/events/index.ts @@ -0,0 +1 @@ +export * from "./client"; diff --git a/src/api/resources/helpCenter/index.ts b/src/api/resources/helpCenter/index.ts new file mode 100644 index 00000000..eea524d6 --- /dev/null +++ b/src/api/resources/helpCenter/index.ts @@ -0,0 +1 @@ +export * from "./types"; diff --git a/src/api/resources/helpCenter/types/Collection.ts b/src/api/resources/helpCenter/types/Collection.ts new file mode 100644 index 00000000..5394f881 --- /dev/null +++ b/src/api/resources/helpCenter/types/Collection.ts @@ -0,0 +1,36 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Collections are top level containers for Articles within the Help Center. + */ +export interface Collection { + /** The unique identifier for the collection which is given by Intercom. */ + id: string; + /** The id of the workspace which the collection belongs to. */ + workspace_id: string; + /** The name of the collection. For multilingual collections, this will be the name of the default language's content. */ + name: string; + /** The description of the collection. For multilingual help centers, this will be the description of the collection for the default language. */ + description?: string; + /** The time when the article was created (seconds). For multilingual articles, this will be the timestamp of creation of the default language's content. */ + created_at: number; + /** The time when the article was last updated (seconds). For multilingual articles, this will be the timestamp of last update of the default language's content. */ + updated_at?: number; + /** The URL of the collection. For multilingual help centers, this will be the URL of the collection for the default language. */ + url?: string; + /** The icon of the collection. */ + icon?: string; + /** The order of the section in relation to others sections within a collection. Values go from `0` upwards. `0` is the default if there's no order. */ + order: number; + /** The default locale of the help center. This field is only returned for multilingual help centers. */ + default_locale: string; + translated_content?: Intercom.GroupTranslatedContent; + /** The id of the parent collection. If `null` then it is the first level collection. */ + parent_id?: string; + /** The id of the help center the collection is in. */ + help_center_id?: number; +} diff --git a/src/api/resources/helpCenter/types/HelpCenter.ts b/src/api/resources/helpCenter/types/HelpCenter.ts new file mode 100644 index 00000000..acf3993d --- /dev/null +++ b/src/api/resources/helpCenter/types/HelpCenter.ts @@ -0,0 +1,23 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Help Centers contain collections + */ +export interface HelpCenter { + /** The unique identifier for the Help Center which is given by Intercom. */ + id: string; + /** The id of the workspace which the Help Center belongs to. */ + workspace_id: string; + /** The time when the Help Center was created. */ + created_at: number; + /** The time when the Help Center was last updated. */ + updated_at?: number; + /** The identifier of the Help Center. This is used in the URL of the Help Center. */ + identifier: string; + /** Whether the Help Center is turned on or not. This is controlled in your Help Center settings. */ + website_turned_on: boolean; + /** The display name of the Help Center only seen by teammates. */ + display_name: string; +} diff --git a/src/api/resources/helpCenter/types/HelpCenterList.ts b/src/api/resources/helpCenter/types/HelpCenterList.ts new file mode 100644 index 00000000..f2d362f7 --- /dev/null +++ b/src/api/resources/helpCenter/types/HelpCenterList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of Help Centers belonging to the App + */ +export interface HelpCenterList { + /** The type of the object - `list`. */ + type: "list"; + /** An array of Help Center objects */ + data: Intercom.HelpCenter[]; +} diff --git a/src/api/resources/helpCenter/types/index.ts b/src/api/resources/helpCenter/types/index.ts new file mode 100644 index 00000000..65d348a7 --- /dev/null +++ b/src/api/resources/helpCenter/types/index.ts @@ -0,0 +1,3 @@ +export * from "./Collection"; +export * from "./HelpCenter"; +export * from "./HelpCenterList"; diff --git a/src/api/resources/helpCenters/client/Client.ts b/src/api/resources/helpCenters/client/Client.ts new file mode 100644 index 00000000..dc51ba65 --- /dev/null +++ b/src/api/resources/helpCenters/client/Client.ts @@ -0,0 +1,258 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; +import { Collections } from "../resources/collections/client/Client"; + +export declare namespace HelpCenters { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +export class HelpCenters { + protected _collections: Collections | undefined; + + constructor(protected readonly _options: HelpCenters.Options = {}) {} + + public get collections(): Collections { + return (this._collections ??= new Collections(this._options)); + } + + /** + * You can fetch the details of a single Help Center by making a GET request to `https://api.intercom.io/help_center/help_center/`. + * + * @param {Intercom.FindHelpCenterRequest} request + * @param {HelpCenters.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.helpCenters.find({ + * help_center_id: "123" + * }) + */ + public async find( + request: Intercom.FindHelpCenterRequest, + requestOptions?: HelpCenters.RequestOptions + ): Promise { + const { help_center_id: helpCenterId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `help_center/help_centers/${encodeURIComponent(helpCenterId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.HelpCenter; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /help_center/help_centers/{help_center_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can list all Help Centers by making a GET request to `https://api.intercom.io/help_center/help_centers`. + * + * @param {Intercom.ListHelpCentersRequest} request + * @param {HelpCenters.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.helpCenters.list() + */ + public async list( + request: Intercom.ListHelpCentersRequest = {}, + requestOptions?: HelpCenters.RequestOptions + ): Promise> { + const list = async (request: Intercom.ListHelpCentersRequest): Promise => { + const { page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "help_center/help_centers" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.HelpCenterList; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /help_center/help_centers." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + }; + let _offset = request?.page != null ? request?.page : 1; + return new core.Pageable({ + response: await list(request), + hasNextPage: (response) => (response?.data ?? []).length > 0, + getItems: (response) => response?.data ?? [], + loadPage: (_response) => { + _offset += 1; + return list(core.setObjectProperty(request, "page", _offset)); + }, + }); + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/helpCenters/client/index.ts b/src/api/resources/helpCenters/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/helpCenters/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/helpCenters/client/requests/FindHelpCenterRequest.ts b/src/api/resources/helpCenters/client/requests/FindHelpCenterRequest.ts new file mode 100644 index 00000000..2be74aba --- /dev/null +++ b/src/api/resources/helpCenters/client/requests/FindHelpCenterRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * help_center_id: "123" + * } + */ +export interface FindHelpCenterRequest { + /** + * The unique identifier for the Help Center which is given by Intercom. + */ + help_center_id: string; +} diff --git a/src/api/resources/helpCenters/client/requests/ListHelpCentersRequest.ts b/src/api/resources/helpCenters/client/requests/ListHelpCentersRequest.ts new file mode 100644 index 00000000..952e8e50 --- /dev/null +++ b/src/api/resources/helpCenters/client/requests/ListHelpCentersRequest.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * {} + */ +export interface ListHelpCentersRequest { + /** + * The page of results to fetch. Defaults to first page + */ + page?: number; + /** + * How many results to display per page. Defaults to 15 + */ + per_page?: number; +} diff --git a/src/api/resources/helpCenters/client/requests/index.ts b/src/api/resources/helpCenters/client/requests/index.ts new file mode 100644 index 00000000..8cc9bf08 --- /dev/null +++ b/src/api/resources/helpCenters/client/requests/index.ts @@ -0,0 +1,2 @@ +export { type FindHelpCenterRequest } from "./FindHelpCenterRequest"; +export { type ListHelpCentersRequest } from "./ListHelpCentersRequest"; diff --git a/src/api/resources/helpCenters/index.ts b/src/api/resources/helpCenters/index.ts new file mode 100644 index 00000000..33a87f10 --- /dev/null +++ b/src/api/resources/helpCenters/index.ts @@ -0,0 +1,2 @@ +export * from "./client"; +export * from "./resources"; diff --git a/src/api/resources/helpCenters/resources/collections/client/Client.ts b/src/api/resources/helpCenters/resources/collections/client/Client.ts new file mode 100644 index 00000000..cd6fe1d3 --- /dev/null +++ b/src/api/resources/helpCenters/resources/collections/client/Client.ts @@ -0,0 +1,490 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Collections { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +export class Collections { + constructor(protected readonly _options: Collections.Options = {}) {} + + /** + * You can fetch a list of all collections by making a GET request to `https://api.intercom.io/help_center/collections`. + * + * Collections will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated collections first. + * + * @param {Intercom.helpCenters.ListCollectionsRequest} request + * @param {Collections.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.helpCenters.collections.list() + */ + public async list( + request: Intercom.helpCenters.ListCollectionsRequest = {}, + requestOptions?: Collections.RequestOptions + ): Promise> { + const list = async (request: Intercom.helpCenters.ListCollectionsRequest): Promise => { + const { page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "help_center/collections" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.CollectionList; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /help_center/collections." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + }; + let _offset = request?.page != null ? request?.page : 1; + return new core.Pageable({ + response: await list(request), + hasNextPage: (response) => (response?.data ?? []).length > 0, + getItems: (response) => response?.data ?? [], + loadPage: (_response) => { + _offset += 1; + return list(core.setObjectProperty(request, "page", _offset)); + }, + }); + } + + /** + * You can create a new collection by making a POST request to `https://api.intercom.io/help_center/collections.` + * + * @param {Intercom.helpCenters.CreateCollectionRequest} request + * @param {Collections.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.helpCenters.collections.create({ + * name: "Thanks for everything" + * }) + * + * @example + * await client.helpCenters.collections.create({ + * name: "collection 51", + * description: "Missing required parameter" + * }) + */ + public async create( + request: Intercom.helpCenters.CreateCollectionRequest, + requestOptions?: Collections.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "help_center/collections" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Collection; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown); + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /help_center/collections."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch the details of a single collection by making a GET request to `https://api.intercom.io/help_center/collections/`. + * + * @param {Intercom.helpCenters.FindCollectionRequest} request + * @param {Collections.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.helpCenters.collections.find({ + * collection_id: "123" + * }) + */ + public async find( + request: Intercom.helpCenters.FindCollectionRequest, + requestOptions?: Collections.RequestOptions + ): Promise { + const { collection_id: collectionId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `help_center/collections/${encodeURIComponent(collectionId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Collection; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /help_center/collections/{collection_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can update the details of a single collection by making a PUT request to `https://api.intercom.io/collections/`. + * + * @param {Intercom.helpCenters.UpdateCollectionRequest} request + * @param {Collections.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.helpCenters.collections.update({ + * collection_id: "123", + * name: "Update collection name" + * }) + */ + public async update( + request: Intercom.helpCenters.UpdateCollectionRequest, + requestOptions?: Collections.RequestOptions + ): Promise { + const { collection_id: collectionId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `help_center/collections/${encodeURIComponent(collectionId)}` + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Collection; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling PUT /help_center/collections/{collection_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can delete a single collection by making a DELETE request to `https://api.intercom.io/collections/`. + * + * @param {Intercom.helpCenters.DeleteCollectionRequest} request + * @param {Collections.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.helpCenters.collections.delete({ + * collection_id: "123" + * }) + */ + public async delete( + request: Intercom.helpCenters.DeleteCollectionRequest, + requestOptions?: Collections.RequestOptions + ): Promise { + const { collection_id: collectionId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `help_center/collections/${encodeURIComponent(collectionId)}` + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.DeletedCollectionObject; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /help_center/collections/{collection_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/helpCenters/resources/collections/client/index.ts b/src/api/resources/helpCenters/resources/collections/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/helpCenters/resources/collections/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/helpCenters/resources/collections/client/requests/CreateCollectionRequest.ts b/src/api/resources/helpCenters/resources/collections/client/requests/CreateCollectionRequest.ts new file mode 100644 index 00000000..3fe27292 --- /dev/null +++ b/src/api/resources/helpCenters/resources/collections/client/requests/CreateCollectionRequest.ts @@ -0,0 +1,29 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * name: "Thanks for everything" + * } + * + * @example + * { + * name: "collection 51", + * description: "Missing required parameter" + * } + */ +export interface CreateCollectionRequest { + /** The name of the collection. For multilingual collections, this will be the name of the default language's content. */ + name: string; + /** The description of the collection. For multilingual collections, this will be the description of the default language's content. */ + description?: string; + translated_content?: Intercom.GroupTranslatedContent; + /** The id of the parent collection. If `null` then it will be created as the first level collection. */ + parent_id?: string; + /** The id of the help center where the collection will be created. If `null` then it will be created in the default help center. */ + help_center_id?: number; +} diff --git a/src/api/resources/helpCenters/resources/collections/client/requests/DeleteCollectionRequest.ts b/src/api/resources/helpCenters/resources/collections/client/requests/DeleteCollectionRequest.ts new file mode 100644 index 00000000..8dbdb625 --- /dev/null +++ b/src/api/resources/helpCenters/resources/collections/client/requests/DeleteCollectionRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * collection_id: "123" + * } + */ +export interface DeleteCollectionRequest { + /** + * The unique identifier for the collection which is given by Intercom. + */ + collection_id: string; +} diff --git a/src/api/resources/helpCenters/resources/collections/client/requests/FindCollectionRequest.ts b/src/api/resources/helpCenters/resources/collections/client/requests/FindCollectionRequest.ts new file mode 100644 index 00000000..6c44a759 --- /dev/null +++ b/src/api/resources/helpCenters/resources/collections/client/requests/FindCollectionRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * collection_id: "123" + * } + */ +export interface FindCollectionRequest { + /** + * The unique identifier for the collection which is given by Intercom. + */ + collection_id: string; +} diff --git a/src/api/resources/helpCenters/resources/collections/client/requests/ListCollectionsRequest.ts b/src/api/resources/helpCenters/resources/collections/client/requests/ListCollectionsRequest.ts new file mode 100644 index 00000000..c8d346bd --- /dev/null +++ b/src/api/resources/helpCenters/resources/collections/client/requests/ListCollectionsRequest.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * {} + */ +export interface ListCollectionsRequest { + /** + * The page of results to fetch. Defaults to first page + */ + page?: number; + /** + * How many results to display per page. Defaults to 15 + */ + per_page?: number; +} diff --git a/src/api/resources/helpCenters/resources/collections/client/requests/UpdateCollectionRequest.ts b/src/api/resources/helpCenters/resources/collections/client/requests/UpdateCollectionRequest.ts new file mode 100644 index 00000000..69bf333a --- /dev/null +++ b/src/api/resources/helpCenters/resources/collections/client/requests/UpdateCollectionRequest.ts @@ -0,0 +1,32 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * collection_id: "123", + * name: "Update collection name" + * } + * + * @example + * { + * collection_id: "123", + * name: "Update collection name" + * } + */ +export interface UpdateCollectionRequest { + /** + * The unique identifier for the collection which is given by Intercom. + */ + collection_id: string; + /** The name of the collection. For multilingual collections, this will be the name of the default language's content. */ + name?: string; + /** The description of the collection. For multilingual collections, this will be the description of the default language's content. */ + description?: string; + translated_content?: Intercom.GroupTranslatedContent; + /** The id of the parent collection. If `null` then it will be updated as the first level collection. */ + parent_id?: string; +} diff --git a/src/api/resources/helpCenters/resources/collections/client/requests/index.ts b/src/api/resources/helpCenters/resources/collections/client/requests/index.ts new file mode 100644 index 00000000..ed57ba6d --- /dev/null +++ b/src/api/resources/helpCenters/resources/collections/client/requests/index.ts @@ -0,0 +1,5 @@ +export { type ListCollectionsRequest } from "./ListCollectionsRequest"; +export { type CreateCollectionRequest } from "./CreateCollectionRequest"; +export { type FindCollectionRequest } from "./FindCollectionRequest"; +export { type UpdateCollectionRequest } from "./UpdateCollectionRequest"; +export { type DeleteCollectionRequest } from "./DeleteCollectionRequest"; diff --git a/src/api/resources/helpCenters/resources/collections/index.ts b/src/api/resources/helpCenters/resources/collections/index.ts new file mode 100644 index 00000000..5ec76921 --- /dev/null +++ b/src/api/resources/helpCenters/resources/collections/index.ts @@ -0,0 +1 @@ +export * from "./client"; diff --git a/src/api/resources/helpCenters/resources/index.ts b/src/api/resources/helpCenters/resources/index.ts new file mode 100644 index 00000000..d52abdea --- /dev/null +++ b/src/api/resources/helpCenters/resources/index.ts @@ -0,0 +1,2 @@ +export * as collections from "./collections"; +export * from "./collections/client/requests"; diff --git a/src/api/resources/index.ts b/src/api/resources/index.ts new file mode 100644 index 00000000..2f3cb340 --- /dev/null +++ b/src/api/resources/index.ts @@ -0,0 +1,62 @@ +export * as admins from "./admins"; +export * from "./admins/types"; +export * as articles from "./articles"; +export * from "./articles/types"; +export * as companies from "./companies"; +export * from "./companies/types"; +export * as contacts from "./contacts"; +export * from "./contacts/types"; +export * as notes from "./notes"; +export * from "./notes/types"; +export * as tags from "./tags"; +export * from "./tags/types"; +export * as conversations from "./conversations"; +export * from "./conversations/types"; +export * as dataAttributes from "./dataAttributes"; +export * from "./dataAttributes/types"; +export * as dataExport from "./dataExport"; +export * from "./dataExport/types"; +export * as messages from "./messages"; +export * from "./messages/types"; +export * as segments from "./segments"; +export * from "./segments/types"; +export * as subscriptionTypes from "./subscriptionTypes"; +export * from "./subscriptionTypes/types"; +export * as teams from "./teams"; +export * from "./teams/types"; +export * as tickets from "./tickets"; +export * from "./tickets/types"; +export * as aiAgent from "./aiAgent"; +export * from "./aiAgent/types"; +export * as helpCenter from "./helpCenter"; +export * from "./helpCenter/types"; +export * as aiContentSource from "./aiContentSource"; +export * from "./aiContentSource/types"; +export * as customObjectInstances from "./customObjectInstances"; +export * from "./customObjectInstances/types"; +export * as dataEvents from "./dataEvents"; +export * from "./dataEvents/types"; +export * as news from "./news"; +export * from "./news/types"; +export * as helpCenters from "./helpCenters"; +export * as events from "./events"; +export * as phoneCallRedirects from "./phoneCallRedirects"; +export * as ticketTypes from "./ticketTypes"; +export * as visitors from "./visitors"; +export * from "./admins/client/requests"; +export * from "./articles/client/requests"; +export * from "./helpCenters/client/requests"; +export * from "./companies/client/requests"; +export * from "./contacts/client/requests"; +export * from "./notes/client/requests"; +export * from "./tags/client/requests"; +export * from "./conversations/client/requests"; +export * from "./dataAttributes/client/requests"; +export * from "./events/client/requests"; +export * from "./dataExport/client/requests"; +export * from "./segments/client/requests"; +export * from "./phoneCallRedirects/client/requests"; +export * from "./teams/client/requests"; +export * from "./ticketTypes/client/requests"; +export * from "./tickets/client/requests"; +export * from "./visitors/client/requests"; diff --git a/src/api/resources/messages/client/Client.ts b/src/api/resources/messages/client/Client.ts new file mode 100644 index 00000000..c69a0fad --- /dev/null +++ b/src/api/resources/messages/client/Client.ts @@ -0,0 +1,262 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace Messages { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your messages + */ +export class Messages { + constructor(protected readonly _options: Messages.Options = {}) {} + + /** + * You can create a message that has been initiated by an admin. The conversation can be either an in-app message or an email. + * + * > 🚧 Sending for visitors + * > + * > There can be a short delay between when a contact is created and when a contact becomes available to be messaged through the API. A 404 Not Found error will be returned in this case. + * + * This will return the Message model that has been created. + * + * > 🚧 Retrieving Associated Conversations + * > + * > As this is a message, there will be no conversation present until the contact responds. Once they do, you will have to search for a contact's conversations with the id of the message. + * + * @param {Intercom.CreateMessageRequest} request + * @param {Messages.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.ForbiddenError} + * @throws {@link Intercom.UnprocessableEntityError} + * + * @example + * await client.messages.create({ + * message_type: "inapp", + * subject: "Thanks for everything", + * body: "heyy", + * template: "plain", + * from: { + * type: "admin", + * id: 394051 + * }, + * to: { + * type: "user", + * id: "536e564f316c83104c000020" + * }, + * created_at: 1590000000, + * create_conversation_without_contact_reply: true + * }) + * + * @example + * await client.messages.create({ + * message_type: "inapp", + * subject: "Thanks for everything", + * body: "heyy", + * template: "plain", + * from: { + * type: "admin", + * id: 394051 + * }, + * to: { + * type: "user", + * id: "667d616c8a68186f43bafe52" + * }, + * created_at: 1590000000, + * create_conversation_without_contact_reply: true + * }) + * + * @example + * await client.messages.create({ + * message_type: "inapp", + * subject: "heyy", + * body: "Hello there", + * template: "plain", + * from: { + * type: "admin", + * id: 394051 + * }, + * to: { + * type: "user", + * id: "667d616d8a68186f43bafe53" + * }, + * created_at: 1590000000, + * create_conversation_without_contact_reply: true + * }) + * + * @example + * await client.messages.create({ + * message_type: "email", + * subject: "Thanks for everything", + * body: "hey there", + * template: "plain", + * from: { + * type: "admin", + * id: 394051 + * }, + * to: { + * type: "user", + * id: "536e564f316c83104c000020" + * }, + * created_at: 1590000000, + * create_conversation_without_contact_reply: true + * }) + * + * @example + * await client.messages.create({ + * message_type: "email", + * subject: "heyy", + * body: "Hello there", + * template: "plain", + * from: { + * type: "admin", + * id: 394051 + * }, + * to: { + * type: "user", + * id: "667d616e8a68186f43bafe55" + * }, + * created_at: 1590000000, + * create_conversation_without_contact_reply: true + * }) + */ + public async create( + request: Intercom.CreateMessageRequest, + requestOptions?: Messages.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "messages" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Message; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown); + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 403: + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + case 422: + throw new Intercom.UnprocessableEntityError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /messages."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/messages/client/index.ts b/src/api/resources/messages/client/index.ts new file mode 100644 index 00000000..cb0ff5c3 --- /dev/null +++ b/src/api/resources/messages/client/index.ts @@ -0,0 +1 @@ +export {}; diff --git a/src/api/resources/messages/index.ts b/src/api/resources/messages/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/messages/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/messages/types/Message.ts b/src/api/resources/messages/types/Message.ts new file mode 100644 index 00000000..d8bd0388 --- /dev/null +++ b/src/api/resources/messages/types/Message.ts @@ -0,0 +1,36 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Message are how you reach out to contacts in Intercom. They are created when an admin sends an outbound message to a contact. + */ +export interface Message { + /** The type of the message */ + type: string; + /** The id representing the message. */ + id: string; + /** The time the conversation was created. */ + created_at: number; + /** The subject of the message. Only present if message_type: email. */ + subject: string; + /** The message body, which may contain HTML. */ + body: string; + /** The type of message that was sent. Can be email, inapp, facebook or twitter. */ + message_type: Message.MessageType; + /** The associated conversation_id */ + conversation_id: string; +} + +export namespace Message { + /** + * The type of message that was sent. Can be email, inapp, facebook or twitter. + */ + export type MessageType = "email" | "inapp" | "facebook" | "twitter"; + export const MessageType = { + Email: "email", + Inapp: "inapp", + Facebook: "facebook", + Twitter: "twitter", + } as const; +} diff --git a/src/api/resources/messages/types/index.ts b/src/api/resources/messages/types/index.ts new file mode 100644 index 00000000..6596816a --- /dev/null +++ b/src/api/resources/messages/types/index.ts @@ -0,0 +1 @@ +export * from "./Message"; diff --git a/src/api/resources/news/client/Client.ts b/src/api/resources/news/client/Client.ts new file mode 100644 index 00000000..22771259 --- /dev/null +++ b/src/api/resources/news/client/Client.ts @@ -0,0 +1,82 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import { Items } from "../resources/items/client/Client"; +import { Feeds } from "../resources/feeds/client/Client"; + +export declare namespace News { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +export class News { + protected _items: Items | undefined; + protected _feeds: Feeds | undefined; + + constructor(protected readonly _options: News.Options = {}) {} + + public get items(): Items { + return (this._items ??= new Items(this._options)); + } + + public get feeds(): Feeds { + return (this._feeds ??= new Feeds(this._options)); + } +} diff --git a/src/api/resources/news/client/index.ts b/src/api/resources/news/client/index.ts new file mode 100644 index 00000000..cb0ff5c3 --- /dev/null +++ b/src/api/resources/news/client/index.ts @@ -0,0 +1 @@ +export {}; diff --git a/src/api/resources/news/index.ts b/src/api/resources/news/index.ts new file mode 100644 index 00000000..848e75ab --- /dev/null +++ b/src/api/resources/news/index.ts @@ -0,0 +1,3 @@ +export * from "./types"; +export * from "./client"; +export * from "./resources"; diff --git a/src/api/resources/news/resources/feeds/client/Client.ts b/src/api/resources/news/resources/feeds/client/Client.ts new file mode 100644 index 00000000..277de3c0 --- /dev/null +++ b/src/api/resources/news/resources/feeds/client/Client.ts @@ -0,0 +1,296 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Feeds { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +export class Feeds { + constructor(protected readonly _options: Feeds.Options = {}) {} + + /** + * You can fetch a list of all news items that are live on a given newsfeed + * + * @param {Intercom.news.ListNewsFeedItemsRequest} request + * @param {Feeds.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.news.feeds.listItems({ + * newsfeed_id: "123" + * }) + */ + public async listItems( + request: Intercom.news.ListNewsFeedItemsRequest, + requestOptions?: Feeds.RequestOptions + ): Promise { + const { newsfeed_id: newsfeedId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `news/newsfeeds/${encodeURIComponent(newsfeedId)}/items` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.PaginatedNewsItemResponse; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /news/newsfeeds/{newsfeed_id}/items." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch a list of all newsfeeds + * + * @param {Feeds.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.news.feeds.list() + */ + public async list(requestOptions?: Feeds.RequestOptions): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "news/newsfeeds" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.PaginatedNewsfeedResponse; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/newsfeeds."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch the details of a single newsfeed + * + * @param {Intercom.news.FindNewsFeedRequest} request + * @param {Feeds.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.news.feeds.find({ + * newsfeed_id: "123" + * }) + */ + public async find( + request: Intercom.news.FindNewsFeedRequest, + requestOptions?: Feeds.RequestOptions + ): Promise { + const { newsfeed_id: newsfeedId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `news/newsfeeds/${encodeURIComponent(newsfeedId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Newsfeed; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /news/newsfeeds/{newsfeed_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/news/resources/feeds/client/index.ts b/src/api/resources/news/resources/feeds/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/news/resources/feeds/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/news/resources/feeds/client/requests/FindNewsFeedRequest.ts b/src/api/resources/news/resources/feeds/client/requests/FindNewsFeedRequest.ts new file mode 100644 index 00000000..4882b9d2 --- /dev/null +++ b/src/api/resources/news/resources/feeds/client/requests/FindNewsFeedRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * newsfeed_id: "123" + * } + */ +export interface FindNewsFeedRequest { + /** + * The unique identifier for the news feed item which is given by Intercom. + */ + newsfeed_id: string; +} diff --git a/src/api/resources/news/resources/feeds/client/requests/ListNewsFeedItemsRequest.ts b/src/api/resources/news/resources/feeds/client/requests/ListNewsFeedItemsRequest.ts new file mode 100644 index 00000000..209d86cc --- /dev/null +++ b/src/api/resources/news/resources/feeds/client/requests/ListNewsFeedItemsRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * newsfeed_id: "123" + * } + */ +export interface ListNewsFeedItemsRequest { + /** + * The unique identifier for the news feed item which is given by Intercom. + */ + newsfeed_id: string; +} diff --git a/src/api/resources/news/resources/feeds/client/requests/index.ts b/src/api/resources/news/resources/feeds/client/requests/index.ts new file mode 100644 index 00000000..0d025c4f --- /dev/null +++ b/src/api/resources/news/resources/feeds/client/requests/index.ts @@ -0,0 +1,2 @@ +export { type ListNewsFeedItemsRequest } from "./ListNewsFeedItemsRequest"; +export { type FindNewsFeedRequest } from "./FindNewsFeedRequest"; diff --git a/src/api/resources/news/resources/feeds/index.ts b/src/api/resources/news/resources/feeds/index.ts new file mode 100644 index 00000000..5ec76921 --- /dev/null +++ b/src/api/resources/news/resources/feeds/index.ts @@ -0,0 +1 @@ +export * from "./client"; diff --git a/src/api/resources/news/resources/index.ts b/src/api/resources/news/resources/index.ts new file mode 100644 index 00000000..bab08c4a --- /dev/null +++ b/src/api/resources/news/resources/index.ts @@ -0,0 +1,4 @@ +export * as items from "./items"; +export * as feeds from "./feeds"; +export * from "./items/client/requests"; +export * from "./feeds/client/requests"; diff --git a/src/api/resources/news/resources/items/client/Client.ts b/src/api/resources/news/resources/items/client/Client.ts new file mode 100644 index 00000000..472e49fb --- /dev/null +++ b/src/api/resources/news/resources/items/client/Client.ts @@ -0,0 +1,477 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Items { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +export class Items { + constructor(protected readonly _options: Items.Options = {}) {} + + /** + * You can fetch a list of all news items + * + * @param {Items.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.news.items.list() + */ + public async list(requestOptions?: Items.RequestOptions): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "news/news_items" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.PaginatedNewsItemResponse; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/news_items."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can create a news item + * + * @param {Intercom.NewsItemRequest} request + * @param {Items.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.news.items.create({ + * title: "Halloween is here!", + * body: "

New costumes in store for this spooky season

", + * sender_id: 991267734, + * state: "live", + * deliver_silently: true, + * labels: ["Product", "Update", "New"], + * reactions: ["\uD83D\uDE06", "\uD83D\uDE05"], + * newsfeed_assignments: [{ + * newsfeed_id: 53, + * published_at: 1664638214 + * }] + * }) + */ + public async create( + request: Intercom.NewsItemRequest, + requestOptions?: Items.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "news/news_items" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.NewsItem; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /news/news_items."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch the details of a single news item. + * + * @param {Intercom.news.FindNewsItemRequest} request + * @param {Items.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.news.items.find({ + * news_item_id: "123" + * }) + */ + public async find( + request: Intercom.news.FindNewsItemRequest, + requestOptions?: Items.RequestOptions + ): Promise { + const { news_item_id: newsItemId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `news/news_items/${encodeURIComponent(newsItemId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.NewsItem; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /news/news_items/{news_item_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * @param {Intercom.news.UpdateNewsItemRequest} request + * @param {Items.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.news.items.update({ + * news_item_id: "123", + * body: { + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

", + * sender_id: 991267745, + * reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"] + * } + * }) + * + * @example + * await client.news.items.update({ + * news_item_id: "123", + * body: { + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

", + * sender_id: 991267748, + * reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"] + * } + * }) + */ + public async update( + request: Intercom.news.UpdateNewsItemRequest, + requestOptions?: Items.RequestOptions + ): Promise { + const { news_item_id: newsItemId, body: _body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `news/news_items/${encodeURIComponent(newsItemId)}` + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.NewsItem; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling PUT /news/news_items/{news_item_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can delete a single news item. + * + * @param {Intercom.news.DeleteNewsItemRequest} request + * @param {Items.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.news.items.delete({ + * news_item_id: "123" + * }) + */ + public async delete( + request: Intercom.news.DeleteNewsItemRequest, + requestOptions?: Items.RequestOptions + ): Promise { + const { news_item_id: newsItemId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `news/news_items/${encodeURIComponent(newsItemId)}` + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.DeletedObject; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /news/news_items/{news_item_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/news/resources/items/client/index.ts b/src/api/resources/news/resources/items/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/news/resources/items/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/news/resources/items/client/requests/DeleteNewsItemRequest.ts b/src/api/resources/news/resources/items/client/requests/DeleteNewsItemRequest.ts new file mode 100644 index 00000000..9fc8094b --- /dev/null +++ b/src/api/resources/news/resources/items/client/requests/DeleteNewsItemRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * news_item_id: "123" + * } + */ +export interface DeleteNewsItemRequest { + /** + * The unique identifier for the news item which is given by Intercom. + */ + news_item_id: string; +} diff --git a/src/api/resources/news/resources/items/client/requests/FindNewsItemRequest.ts b/src/api/resources/news/resources/items/client/requests/FindNewsItemRequest.ts new file mode 100644 index 00000000..d727fbdb --- /dev/null +++ b/src/api/resources/news/resources/items/client/requests/FindNewsItemRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * news_item_id: "123" + * } + */ +export interface FindNewsItemRequest { + /** + * The unique identifier for the news item which is given by Intercom. + */ + news_item_id: string; +} diff --git a/src/api/resources/news/resources/items/client/requests/UpdateNewsItemRequest.ts b/src/api/resources/news/resources/items/client/requests/UpdateNewsItemRequest.ts new file mode 100644 index 00000000..ec976bc2 --- /dev/null +++ b/src/api/resources/news/resources/items/client/requests/UpdateNewsItemRequest.ts @@ -0,0 +1,36 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * news_item_id: "123", + * body: { + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

", + * sender_id: 991267745, + * reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"] + * } + * } + * + * @example + * { + * news_item_id: "123", + * body: { + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

", + * sender_id: 991267748, + * reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"] + * } + * } + */ +export interface UpdateNewsItemRequest { + /** + * The unique identifier for the news item which is given by Intercom. + */ + news_item_id: string; + body: Intercom.NewsItemRequest; +} diff --git a/src/api/resources/news/resources/items/client/requests/index.ts b/src/api/resources/news/resources/items/client/requests/index.ts new file mode 100644 index 00000000..0ae128c3 --- /dev/null +++ b/src/api/resources/news/resources/items/client/requests/index.ts @@ -0,0 +1,3 @@ +export { type FindNewsItemRequest } from "./FindNewsItemRequest"; +export { type UpdateNewsItemRequest } from "./UpdateNewsItemRequest"; +export { type DeleteNewsItemRequest } from "./DeleteNewsItemRequest"; diff --git a/src/api/resources/news/resources/items/index.ts b/src/api/resources/news/resources/items/index.ts new file mode 100644 index 00000000..5ec76921 --- /dev/null +++ b/src/api/resources/news/resources/items/index.ts @@ -0,0 +1 @@ +export * from "./client"; diff --git a/src/api/resources/news/types/NewsItem.ts b/src/api/resources/news/types/NewsItem.ts new file mode 100644 index 00000000..2addce53 --- /dev/null +++ b/src/api/resources/news/types/NewsItem.ts @@ -0,0 +1,50 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A News Item is a content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers. + */ +export interface NewsItem { + /** The type of object. */ + type: "news-item"; + /** The unique identifier for the news item which is given by Intercom. */ + id: string; + /** The id of the workspace which the news item belongs to. */ + workspace_id: string; + /** The title of the news item. */ + title: string; + /** The news item body, which may contain HTML. */ + body: string; + /** The id of the sender of the news item. Must be a teammate on the workspace. */ + sender_id: number; + /** News items will not be visible to your users in the assigned newsfeeds until they are set live. */ + state: NewsItem.State; + /** A list of newsfeed_assignments to assign to the specified newsfeed. */ + newsfeed_assignments?: Intercom.NewsfeedAssignment[]; + /** Label names displayed to users to categorize the news item. */ + labels?: (string | undefined)[]; + /** URL of the image used as cover. Must have .jpg or .png extension. */ + cover_image_url?: string; + /** Ordered list of emoji reactions to the news item. When empty, reactions are disabled. */ + reactions?: (string | undefined)[]; + /** When set to true, the news item will appear in the messenger newsfeed without showing a notification badge. */ + deliver_silently?: boolean; + /** Timestamp for when the news item was created. */ + created_at: number; + /** Timestamp for when the news item was last updated. */ + updated_at?: number; +} + +export namespace NewsItem { + /** + * News items will not be visible to your users in the assigned newsfeeds until they are set live. + */ + export type State = "draft" | "live"; + export const State = { + Draft: "draft", + Live: "live", + } as const; +} diff --git a/src/api/resources/news/types/Newsfeed.ts b/src/api/resources/news/types/Newsfeed.ts new file mode 100644 index 00000000..a20a9016 --- /dev/null +++ b/src/api/resources/news/types/Newsfeed.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A newsfeed is a collection of news items, targeted to a specific audience. + * + * Newsfeeds currently cannot be edited through the API, please refer to [this article](https://www.intercom.com/help/en/articles/6362267-getting-started-with-news) to set up your newsfeeds in Intercom. + */ +export interface Newsfeed { + /** The unique identifier for the newsfeed which is given by Intercom. */ + id: string; + /** The type of object. */ + type: "newsfeed"; + /** The name of the newsfeed. This name will never be visible to your users. */ + name: string; + /** Timestamp for when the newsfeed was created. */ + created_at: number; + /** Timestamp for when the newsfeed was last updated. */ + updated_at?: number; +} diff --git a/src/api/resources/news/types/NewsfeedAssignment.ts b/src/api/resources/news/types/NewsfeedAssignment.ts new file mode 100644 index 00000000..80447b20 --- /dev/null +++ b/src/api/resources/news/types/NewsfeedAssignment.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Assigns a news item to a newsfeed. + */ +export interface NewsfeedAssignment { + /** The unique identifier for the newsfeed which is given by Intercom. Publish dates cannot be in the future, to schedule news items use the dedicated feature in app (see this article). */ + newsfeed_id: number; + /** Publish date of the news item on the newsfeed, use this field if you want to set a publish date in the past (e.g. when importing existing news items). On write, this field will be ignored if the news item state is "draft". */ + published_at: number; +} diff --git a/src/api/resources/news/types/index.ts b/src/api/resources/news/types/index.ts new file mode 100644 index 00000000..b8c22f3c --- /dev/null +++ b/src/api/resources/news/types/index.ts @@ -0,0 +1,3 @@ +export * from "./NewsItem"; +export * from "./Newsfeed"; +export * from "./NewsfeedAssignment"; diff --git a/src/api/resources/notes/client/Client.ts b/src/api/resources/notes/client/Client.ts new file mode 100644 index 00000000..f01df098 --- /dev/null +++ b/src/api/resources/notes/client/Client.ts @@ -0,0 +1,331 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace Notes { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Notes + */ +export class Notes { + constructor(protected readonly _options: Notes.Options = {}) {} + + /** + * You can fetch a list of notes that are associated to a contact. + * + * @param {Intercom.ListContactNotesRequest} request + * @param {Notes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.notes.list({ + * contact_id: "contact_id" + * }) + */ + public async list( + request: Intercom.ListContactNotesRequest, + requestOptions?: Notes.RequestOptions + ): Promise> { + const list = async (request: Intercom.ListContactNotesRequest): Promise => { + const { contact_id: contactId, page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/notes` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.NoteList; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /contacts/{contact_id}/notes." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + }; + let _offset = request?.page != null ? request?.page : 1; + return new core.Pageable({ + response: await list(request), + hasNextPage: (response) => (response?.data ?? []).length > 0, + getItems: (response) => response?.data ?? [], + loadPage: (_response) => { + _offset += 1; + return list(core.setObjectProperty(request, "page", _offset)); + }, + }); + } + + /** + * You can add a note to a single contact. + * + * @param {Intercom.CreateContactNoteRequest} request + * @param {Notes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.notes.create({ + * contact_id: "123", + * body: "Hello", + * admin_id: "123" + * }) + */ + public async create( + request: Intercom.CreateContactNoteRequest, + requestOptions?: Notes.RequestOptions + ): Promise { + const { contact_id: contactId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/notes` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Note; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /contacts/{contact_id}/notes." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch the details of a single note. + * + * @param {Intercom.FindNoteRequest} request + * @param {Notes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.notes.find({ + * note_id: "1" + * }) + */ + public async find( + request: Intercom.FindNoteRequest, + requestOptions?: Notes.RequestOptions + ): Promise { + const { note_id: noteId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `notes/${encodeURIComponent(noteId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Note; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /notes/{note_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/notes/client/index.ts b/src/api/resources/notes/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/notes/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/notes/client/requests/CreateContactNoteRequest.ts b/src/api/resources/notes/client/requests/CreateContactNoteRequest.ts new file mode 100644 index 00000000..1cadbe4a --- /dev/null +++ b/src/api/resources/notes/client/requests/CreateContactNoteRequest.ts @@ -0,0 +1,36 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "123", + * body: "Hello", + * admin_id: "123" + * } + * + * @example + * { + * contact_id: "123", + * body: "Hello", + * admin_id: "123" + * } + * + * @example + * { + * contact_id: "123", + * body: "Hello", + * admin_id: "123" + * } + */ +export interface CreateContactNoteRequest { + /** + * The unique identifier of a given contact. + */ + contact_id: string; + /** The text of the note. */ + body: string; + /** The unique identifier of a given admin. */ + admin_id?: string; +} diff --git a/src/api/resources/notes/client/requests/FindNoteRequest.ts b/src/api/resources/notes/client/requests/FindNoteRequest.ts new file mode 100644 index 00000000..35bff5e2 --- /dev/null +++ b/src/api/resources/notes/client/requests/FindNoteRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * note_id: "1" + * } + */ +export interface FindNoteRequest { + /** + * The unique identifier of a given note + */ + note_id: string; +} diff --git a/src/api/resources/notes/client/requests/ListContactNotesRequest.ts b/src/api/resources/notes/client/requests/ListContactNotesRequest.ts new file mode 100644 index 00000000..1c8b5763 --- /dev/null +++ b/src/api/resources/notes/client/requests/ListContactNotesRequest.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "contact_id" + * } + */ +export interface ListContactNotesRequest { + /** + * The unique identifier of a contact. + */ + contact_id: string; + /** + * The page of results to fetch. Defaults to first page + */ + page?: number; + /** + * How many results to display per page. Defaults to 15 + */ + per_page?: number; +} diff --git a/src/api/resources/notes/client/requests/index.ts b/src/api/resources/notes/client/requests/index.ts new file mode 100644 index 00000000..6271b2a9 --- /dev/null +++ b/src/api/resources/notes/client/requests/index.ts @@ -0,0 +1,3 @@ +export { type ListContactNotesRequest } from "./ListContactNotesRequest"; +export { type CreateContactNoteRequest } from "./CreateContactNoteRequest"; +export { type FindNoteRequest } from "./FindNoteRequest"; diff --git a/src/api/resources/notes/index.ts b/src/api/resources/notes/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/notes/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/notes/types/Note.ts b/src/api/resources/notes/types/Note.ts new file mode 100644 index 00000000..a2b2345d --- /dev/null +++ b/src/api/resources/notes/types/Note.ts @@ -0,0 +1,35 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Notes allow you to annotate and comment on your contacts. + */ +export interface Note { + /** String representing the object's type. Always has the value `note`. */ + type: "note"; + /** The id of the note. */ + id: string; + /** The time the note was created. */ + created_at: number; + /** Represents the contact that the note was created about. */ + contact?: Note.Contact; + /** Optional. Represents the Admin that created the note. */ + author: Intercom.Admin; + /** The body text of the note. */ + body: string; +} + +export namespace Note { + /** + * Represents the contact that the note was created about. + */ + export interface Contact { + /** String representing the object's type. Always has the value `contact`. */ + type?: "contact"; + /** The id of the contact. */ + id?: string; + } +} diff --git a/src/api/resources/notes/types/index.ts b/src/api/resources/notes/types/index.ts new file mode 100644 index 00000000..cf881fa5 --- /dev/null +++ b/src/api/resources/notes/types/index.ts @@ -0,0 +1 @@ +export * from "./Note"; diff --git a/src/api/resources/phoneCallRedirects/client/Client.ts b/src/api/resources/phoneCallRedirects/client/Client.ts new file mode 100644 index 00000000..7e3d3829 --- /dev/null +++ b/src/api/resources/phoneCallRedirects/client/Client.ts @@ -0,0 +1,177 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace PhoneCallRedirects { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +export class PhoneCallRedirects { + constructor(protected readonly _options: PhoneCallRedirects.Options = {}) {} + + /** + * You can use the API to deflect phone calls to the Intercom Messenger. + * Calling this endpoint will send an SMS with a link to the Messenger to the phone number specified. + * + * If custom attributes are specified, they will be added to the user or lead's custom data attributes. + * + * @param {Intercom.CreatePhoneCallRedirectRequest} request + * @param {PhoneCallRedirects.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.UnprocessableEntityError} + * + * @example + * await client.phoneCallRedirects.create({ + * phone: "+353832345678", + * custom_attributes: { + * "issue_type": "Billing", + * "priority": "High" + * } + * }) + * + * @example + * await client.phoneCallRedirects.create({ + * phone: "+40241100100", + * custom_attributes: { + * "issue_type": "Billing", + * "priority": "High" + * } + * }) + */ + public async create( + request: Intercom.CreatePhoneCallRedirectRequest, + requestOptions?: PhoneCallRedirects.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "phone_call_redirects" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.PhoneSwitch; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown); + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 422: + throw new Intercom.UnprocessableEntityError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /phone_call_redirects."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/phoneCallRedirects/client/index.ts b/src/api/resources/phoneCallRedirects/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/phoneCallRedirects/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/phoneCallRedirects/client/requests/CreatePhoneCallRedirectRequest.ts b/src/api/resources/phoneCallRedirects/client/requests/CreatePhoneCallRedirectRequest.ts new file mode 100644 index 00000000..3b19efc3 --- /dev/null +++ b/src/api/resources/phoneCallRedirects/client/requests/CreatePhoneCallRedirectRequest.ts @@ -0,0 +1,48 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../index"; + +/** + * @example + * { + * phone: "+353832345678", + * custom_attributes: { + * "issue_type": "Billing", + * "priority": "High" + * } + * } + * + * @example + * { + * phone: "+353832345678", + * custom_attributes: { + * "issue_type": "Billing", + * "priority": "High" + * } + * } + * + * @example + * { + * phone: "+353832345678", + * custom_attributes: { + * "issue_type": "Billing", + * "priority": "High" + * } + * } + * + * @example + * { + * phone: "+40241100100", + * custom_attributes: { + * "issue_type": "Billing", + * "priority": "High" + * } + * } + */ +export interface CreatePhoneCallRedirectRequest { + /** Phone number in E.164 format, that will receive the SMS to continue the conversation in the Messenger. */ + phone: string; + custom_attributes?: Intercom.CustomAttributes; +} diff --git a/src/api/resources/phoneCallRedirects/client/requests/index.ts b/src/api/resources/phoneCallRedirects/client/requests/index.ts new file mode 100644 index 00000000..7038d703 --- /dev/null +++ b/src/api/resources/phoneCallRedirects/client/requests/index.ts @@ -0,0 +1 @@ +export { type CreatePhoneCallRedirectRequest } from "./CreatePhoneCallRedirectRequest"; diff --git a/src/api/resources/phoneCallRedirects/index.ts b/src/api/resources/phoneCallRedirects/index.ts new file mode 100644 index 00000000..5ec76921 --- /dev/null +++ b/src/api/resources/phoneCallRedirects/index.ts @@ -0,0 +1 @@ +export * from "./client"; diff --git a/src/api/resources/segments/client/Client.ts b/src/api/resources/segments/client/Client.ts new file mode 100644 index 00000000..6af0a5bd --- /dev/null +++ b/src/api/resources/segments/client/Client.ts @@ -0,0 +1,237 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace Segments { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Segments + */ +export class Segments { + constructor(protected readonly _options: Segments.Options = {}) {} + + /** + * You can fetch a list of all segments. + * + * @param {Intercom.ListSegmentsRequest} request + * @param {Segments.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.segments.list() + */ + public async list( + request: Intercom.ListSegmentsRequest = {}, + requestOptions?: Segments.RequestOptions + ): Promise { + const { include_count: includeCount } = request; + const _queryParams: Record = {}; + if (includeCount != null) { + _queryParams["include_count"] = includeCount.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "segments" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.SegmentList; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /segments."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch the details of a single segment. + * + * @param {Intercom.FindSegmentRequest} request + * @param {Segments.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.segments.find({ + * segment_id: "123" + * }) + */ + public async find( + request: Intercom.FindSegmentRequest, + requestOptions?: Segments.RequestOptions + ): Promise { + const { segment_id: segmentId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `segments/${encodeURIComponent(segmentId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Segment; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /segments/{segment_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/segments/client/index.ts b/src/api/resources/segments/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/segments/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/segments/client/requests/FindSegmentRequest.ts b/src/api/resources/segments/client/requests/FindSegmentRequest.ts new file mode 100644 index 00000000..0e0dff0b --- /dev/null +++ b/src/api/resources/segments/client/requests/FindSegmentRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * segment_id: "123" + * } + */ +export interface FindSegmentRequest { + /** + * The unique identified of a given segment. + */ + segment_id: string; +} diff --git a/src/api/resources/segments/client/requests/ListSegmentsRequest.ts b/src/api/resources/segments/client/requests/ListSegmentsRequest.ts new file mode 100644 index 00000000..116acd5e --- /dev/null +++ b/src/api/resources/segments/client/requests/ListSegmentsRequest.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * {} + */ +export interface ListSegmentsRequest { + /** + * It includes the count of contacts that belong to each segment. + */ + include_count?: boolean; +} diff --git a/src/api/resources/segments/client/requests/index.ts b/src/api/resources/segments/client/requests/index.ts new file mode 100644 index 00000000..a7d400d9 --- /dev/null +++ b/src/api/resources/segments/client/requests/index.ts @@ -0,0 +1,2 @@ +export { type ListSegmentsRequest } from "./ListSegmentsRequest"; +export { type FindSegmentRequest } from "./FindSegmentRequest"; diff --git a/src/api/resources/segments/index.ts b/src/api/resources/segments/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/segments/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/segments/types/Segment.ts b/src/api/resources/segments/types/Segment.ts new file mode 100644 index 00000000..6612edb7 --- /dev/null +++ b/src/api/resources/segments/types/Segment.ts @@ -0,0 +1,34 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A segment is a group of your contacts defined by the rules that you set. + */ +export interface Segment { + /** The type of object. */ + type: "segment"; + /** The unique identifier representing the segment. */ + id: string; + /** The name of the segment. */ + name: string; + /** The time the segment was created. */ + created_at: number; + /** The time the segment was updated. */ + updated_at?: number; + /** Type of the contact: contact (lead) or user. */ + person_type: Segment.PersonType; + /** The number of items in the user segment. It's returned when `include_count=true` is included in the request. */ + count?: number; +} + +export namespace Segment { + /** + * Type of the contact: contact (lead) or user. + */ + export type PersonType = "contact" | "user"; + export const PersonType = { + Contact: "contact", + User: "user", + } as const; +} diff --git a/src/api/resources/segments/types/index.ts b/src/api/resources/segments/types/index.ts new file mode 100644 index 00000000..957aab14 --- /dev/null +++ b/src/api/resources/segments/types/index.ts @@ -0,0 +1 @@ +export * from "./Segment"; diff --git a/src/api/resources/subscriptionTypes/client/Client.ts b/src/api/resources/subscriptionTypes/client/Client.ts new file mode 100644 index 00000000..c2914911 --- /dev/null +++ b/src/api/resources/subscriptionTypes/client/Client.ts @@ -0,0 +1,151 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace SubscriptionTypes { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about subscription types + */ +export class SubscriptionTypes { + constructor(protected readonly _options: SubscriptionTypes.Options = {}) {} + + /** + * You can list all subscription types. A list of subscription type objects will be returned. + * + * @param {SubscriptionTypes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.subscriptionTypes.list() + */ + public async list(requestOptions?: SubscriptionTypes.RequestOptions): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "subscription_types" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.SubscriptionTypeList; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /subscription_types."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/subscriptionTypes/client/index.ts b/src/api/resources/subscriptionTypes/client/index.ts new file mode 100644 index 00000000..cb0ff5c3 --- /dev/null +++ b/src/api/resources/subscriptionTypes/client/index.ts @@ -0,0 +1 @@ +export {}; diff --git a/src/api/resources/subscriptionTypes/index.ts b/src/api/resources/subscriptionTypes/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/subscriptionTypes/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/subscriptionTypes/types/SubscriptionType.ts b/src/api/resources/subscriptionTypes/types/SubscriptionType.ts new file mode 100644 index 00000000..e27d1d7d --- /dev/null +++ b/src/api/resources/subscriptionTypes/types/SubscriptionType.ts @@ -0,0 +1,53 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A subscription type lets customers easily opt out of non-essential communications without missing what's important to them. + */ +export interface SubscriptionType { + /** The type of the object - subscription */ + type: string; + /** The unique identifier representing the subscription type. */ + id: string; + /** The state of the subscription type. */ + state: SubscriptionType.State; + default_translation: Intercom.Translation; + /** An array of translations objects with the localised version of the subscription type in each available locale within your translation settings. */ + translations: Intercom.Translation[]; + /** Describes the type of consent. */ + consent_type: SubscriptionType.ConsentType; + /** The message types that this subscription supports - can contain `email` or `sms_message`. */ + content_types: SubscriptionType.ContentTypes.Item[]; +} + +export namespace SubscriptionType { + /** + * The state of the subscription type. + */ + export type State = "live" | "draft" | "archived"; + export const State = { + Live: "live", + Draft: "draft", + Archived: "archived", + } as const; + /** + * Describes the type of consent. + */ + export type ConsentType = "opt_out" | "opt_in"; + export const ConsentType = { + OptOut: "opt_out", + OptIn: "opt_in", + } as const; + export type ContentTypes = ContentTypes.Item[]; + + export namespace ContentTypes { + export type Item = "email" | "sms_message"; + export const Item = { + Email: "email", + SmsMessage: "sms_message", + } as const; + } +} diff --git a/src/api/resources/subscriptionTypes/types/index.ts b/src/api/resources/subscriptionTypes/types/index.ts new file mode 100644 index 00000000..fe95bab5 --- /dev/null +++ b/src/api/resources/subscriptionTypes/types/index.ts @@ -0,0 +1 @@ +export * from "./SubscriptionType"; diff --git a/src/api/resources/tags/client/Client.ts b/src/api/resources/tags/client/Client.ts new file mode 100644 index 00000000..7e4729c9 --- /dev/null +++ b/src/api/resources/tags/client/Client.ts @@ -0,0 +1,892 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace Tags { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about tags + */ +export class Tags { + constructor(protected readonly _options: Tags.Options = {}) {} + + /** + * You can tag a specific contact. This will return a tag object for the tag that was added to the contact. + * + * @param {Intercom.TagContactRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.tags.tagContact({ + * contact_id: "63a07ddf05a32042dffac965", + * id: "7522907" + * }) + * + * @example + * await client.tags.tagContact({ + * contact_id: "63a07ddf05a32042dffac965", + * id: "123" + * }) + */ + public async tagContact( + request: Intercom.TagContactRequest, + requestOptions?: Tags.RequestOptions + ): Promise { + const { contact_id: contactId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/tags` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Tag; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /contacts/{contact_id}/tags." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can remove tag from a specific contact. This will return a tag object for the tag that was removed from the contact. + * + * @param {Intercom.UntagContactRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.tags.untagContact({ + * contact_id: "63a07ddf05a32042dffac965", + * tag_id: "7522907" + * }) + */ + public async untagContact( + request: Intercom.UntagContactRequest, + requestOptions?: Tags.RequestOptions + ): Promise { + const { contact_id: contactId, tag_id: tagId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/tags/${encodeURIComponent(tagId)}` + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Tag; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /contacts/{contact_id}/tags/{tag_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can tag a specific conversation. This will return a tag object for the tag that was added to the conversation. + * + * @param {Intercom.TagConversationRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.tags.tagConversation({ + * conversation_id: "64619700005694", + * id: "7522907", + * admin_id: "780" + * }) + */ + public async tagConversation( + request: Intercom.TagConversationRequest, + requestOptions?: Tags.RequestOptions + ): Promise { + const { conversation_id: conversationId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/tags` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Tag; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /conversations/{conversation_id}/tags." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can remove tag from a specific conversation. This will return a tag object for the tag that was removed from the conversation. + * + * @param {Intercom.UntagConversationRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.tags.untagConversation({ + * conversation_id: "64619700005694", + * tag_id: "7522907", + * admin_id: "123" + * }) + */ + public async untagConversation( + request: Intercom.UntagConversationRequest, + requestOptions?: Tags.RequestOptions + ): Promise { + const { conversation_id: conversationId, tag_id: tagId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/tags/${encodeURIComponent(tagId)}` + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Tag; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /conversations/{conversation_id}/tags/{tag_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch a list of all tags for a given workspace. + * + * + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.tags.list() + */ + public async list(requestOptions?: Tags.RequestOptions): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "tags" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.TagList; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tags."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can use this endpoint to perform the following operations: + * + * **1. Create a new tag:** You can create a new tag by passing in the tag name as specified in "Create or Update Tag Request Payload" described below. + * + * **2. Update an existing tag:** You can update an existing tag by passing the id of the tag as specified in "Create or Update Tag Request Payload" described below. + * + * **3. Tag Companies:** You can tag single company or a list of companies. You can tag a company by passing in the tag name and the company details as specified in "Tag Company Request Payload" described below. Also, if the tag doesn't exist then a new one will be created automatically. + * + * **4. Untag Companies:** You can untag a single company or a list of companies. You can untag a company by passing in the tag id and the company details as specified in "Untag Company Request Payload" described below. + * + * **5. Tag Multiple Users:** You can tag a list of users. You can tag the users by passing in the tag name and the user details as specified in "Tag Users Request Payload" described below. + * + * Each operation will return a tag object. + * + * @param {Intercom.TagsCreateRequestBody} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.tags.create({ + * name: "test" + * }) + * + * @example + * await client.tags.create({ + * name: "Independent" + * }) + * + * @example + * await client.tags.create({ + * name: "test", + * companies: [{ + * company_id: "123" + * }] + * }) + * + * @example + * await client.tags.create({ + * name: "test", + * users: [{ + * id: "123" + * }] + * }) + */ + public async create( + request: Intercom.TagsCreateRequestBody, + requestOptions?: Tags.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "tags" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Tag; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown); + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tags."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch the details of tags that are on the workspace by their id. + * This will return a tag object. + * + * @param {Intercom.FindTagRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.tags.find({ + * tag_id: "123" + * }) + */ + public async find(request: Intercom.FindTagRequest, requestOptions?: Tags.RequestOptions): Promise { + const { tag_id: tagId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `tags/${encodeURIComponent(tagId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Tag; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tags/{tag_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can delete the details of tags that are on the workspace by passing in the id. + * + * @param {Intercom.DeleteTagRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.tags.delete({ + * tag_id: "123" + * }) + */ + public async delete(request: Intercom.DeleteTagRequest, requestOptions?: Tags.RequestOptions): Promise { + const { tag_id: tagId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `tags/${encodeURIComponent(tagId)}` + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown); + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /tags/{tag_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can tag a specific ticket. This will return a tag object for the tag that was added to the ticket. + * + * @param {Intercom.TagTicketRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.tags.tagTicket({ + * ticket_id: "64619700005694", + * id: "7522907", + * admin_id: "780" + * }) + */ + public async tagTicket( + request: Intercom.TagTicketRequest, + requestOptions?: Tags.RequestOptions + ): Promise { + const { ticket_id: ticketId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(ticketId)}/tags` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Tag; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/{ticket_id}/tags."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can remove tag from a specific ticket. This will return a tag object for the tag that was removed from the ticket. + * + * @param {Intercom.UntagTicketRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.tags.untagTicket({ + * ticket_id: "64619700005694", + * tag_id: "7522907", + * admin_id: "123" + * }) + */ + public async untagTicket( + request: Intercom.UntagTicketRequest, + requestOptions?: Tags.RequestOptions + ): Promise { + const { ticket_id: ticketId, tag_id: tagId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(ticketId)}/tags/${encodeURIComponent(tagId)}` + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Tag; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /tickets/{ticket_id}/tags/{tag_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/tags/client/index.ts b/src/api/resources/tags/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/tags/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/tags/client/requests/DeleteTagRequest.ts b/src/api/resources/tags/client/requests/DeleteTagRequest.ts new file mode 100644 index 00000000..c6f44174 --- /dev/null +++ b/src/api/resources/tags/client/requests/DeleteTagRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * tag_id: "123" + * } + */ +export interface DeleteTagRequest { + /** + * The unique identifier of a given tag + */ + tag_id: string; +} diff --git a/src/api/resources/tags/client/requests/FindTagRequest.ts b/src/api/resources/tags/client/requests/FindTagRequest.ts new file mode 100644 index 00000000..b708ed6a --- /dev/null +++ b/src/api/resources/tags/client/requests/FindTagRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * tag_id: "123" + * } + */ +export interface FindTagRequest { + /** + * The unique identifier of a given tag + */ + tag_id: string; +} diff --git a/src/api/resources/tags/client/requests/TagContactRequest.ts b/src/api/resources/tags/client/requests/TagContactRequest.ts new file mode 100644 index 00000000..fe463e94 --- /dev/null +++ b/src/api/resources/tags/client/requests/TagContactRequest.ts @@ -0,0 +1,31 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * id: "7522907" + * } + * + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * id: "7522907" + * } + * + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * id: "123" + * } + */ +export interface TagContactRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; + /** The unique identifier for the tag which is given by Intercom */ + id: string; +} diff --git a/src/api/resources/tags/client/requests/TagConversationRequest.ts b/src/api/resources/tags/client/requests/TagConversationRequest.ts new file mode 100644 index 00000000..2fd2282f --- /dev/null +++ b/src/api/resources/tags/client/requests/TagConversationRequest.ts @@ -0,0 +1,29 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * conversation_id: "64619700005694", + * id: "7522907", + * admin_id: "780" + * } + * + * @example + * { + * conversation_id: "64619700005694", + * id: "7522907", + * admin_id: "780" + * } + */ +export interface TagConversationRequest { + /** + * conversation_id + */ + conversation_id: string; + /** The unique identifier for the tag which is given by Intercom */ + id: string; + /** The unique identifier for the admin which is given by Intercom. */ + admin_id: string; +} diff --git a/src/api/resources/tags/client/requests/TagTicketRequest.ts b/src/api/resources/tags/client/requests/TagTicketRequest.ts new file mode 100644 index 00000000..3be7d004 --- /dev/null +++ b/src/api/resources/tags/client/requests/TagTicketRequest.ts @@ -0,0 +1,29 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * ticket_id: "64619700005694", + * id: "7522907", + * admin_id: "780" + * } + * + * @example + * { + * ticket_id: "64619700005694", + * id: "7522907", + * admin_id: "780" + * } + */ +export interface TagTicketRequest { + /** + * ticket_id + */ + ticket_id: string; + /** The unique identifier for the tag which is given by Intercom */ + id: string; + /** The unique identifier for the admin which is given by Intercom. */ + admin_id: string; +} diff --git a/src/api/resources/tags/client/requests/UntagContactRequest.ts b/src/api/resources/tags/client/requests/UntagContactRequest.ts new file mode 100644 index 00000000..81a2c945 --- /dev/null +++ b/src/api/resources/tags/client/requests/UntagContactRequest.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * tag_id: "7522907" + * } + */ +export interface UntagContactRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; + /** + * The unique identifier for the tag which is given by Intercom + */ + tag_id: string; +} diff --git a/src/api/resources/tags/client/requests/UntagConversationRequest.ts b/src/api/resources/tags/client/requests/UntagConversationRequest.ts new file mode 100644 index 00000000..1d730070 --- /dev/null +++ b/src/api/resources/tags/client/requests/UntagConversationRequest.ts @@ -0,0 +1,38 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * conversation_id: "64619700005694", + * tag_id: "7522907", + * admin_id: "123" + * } + * + * @example + * { + * conversation_id: "64619700005694", + * tag_id: "7522907", + * admin_id: "123" + * } + * + * @example + * { + * conversation_id: "64619700005694", + * tag_id: "7522907", + * admin_id: "123" + * } + */ +export interface UntagConversationRequest { + /** + * conversation_id + */ + conversation_id: string; + /** + * id + */ + tag_id: string; + /** The unique identifier for the admin which is given by Intercom. */ + admin_id: string; +} diff --git a/src/api/resources/tags/client/requests/UntagTicketRequest.ts b/src/api/resources/tags/client/requests/UntagTicketRequest.ts new file mode 100644 index 00000000..2115f12e --- /dev/null +++ b/src/api/resources/tags/client/requests/UntagTicketRequest.ts @@ -0,0 +1,38 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * ticket_id: "64619700005694", + * tag_id: "7522907", + * admin_id: "123" + * } + * + * @example + * { + * ticket_id: "64619700005694", + * tag_id: "7522907", + * admin_id: "123" + * } + * + * @example + * { + * ticket_id: "64619700005694", + * tag_id: "7522907", + * admin_id: "123" + * } + */ +export interface UntagTicketRequest { + /** + * ticket_id + */ + ticket_id: string; + /** + * The unique identifier for the tag which is given by Intercom + */ + tag_id: string; + /** The unique identifier for the admin which is given by Intercom. */ + admin_id: string; +} diff --git a/src/api/resources/tags/client/requests/index.ts b/src/api/resources/tags/client/requests/index.ts new file mode 100644 index 00000000..0d5e855b --- /dev/null +++ b/src/api/resources/tags/client/requests/index.ts @@ -0,0 +1,8 @@ +export { type TagContactRequest } from "./TagContactRequest"; +export { type UntagContactRequest } from "./UntagContactRequest"; +export { type TagConversationRequest } from "./TagConversationRequest"; +export { type UntagConversationRequest } from "./UntagConversationRequest"; +export { type FindTagRequest } from "./FindTagRequest"; +export { type DeleteTagRequest } from "./DeleteTagRequest"; +export { type TagTicketRequest } from "./TagTicketRequest"; +export { type UntagTicketRequest } from "./UntagTicketRequest"; diff --git a/src/api/resources/tags/index.ts b/src/api/resources/tags/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/tags/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/tags/types/Tag.ts b/src/api/resources/tags/types/Tag.ts new file mode 100644 index 00000000..89b6ce54 --- /dev/null +++ b/src/api/resources/tags/types/Tag.ts @@ -0,0 +1,20 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A tag allows you to label your contacts, companies, and conversations and list them using that tag. + */ +export interface Tag { + /** value is "tag" */ + type: string; + /** The id of the tag */ + id: string; + /** The name of the tag */ + name: string; + /** The time when the tag was applied to the object */ + applied_at: number; + applied_by: Intercom.Reference; +} diff --git a/src/api/resources/tags/types/TagsCreateRequestBody.ts b/src/api/resources/tags/types/TagsCreateRequestBody.ts new file mode 100644 index 00000000..aaf7c9e9 --- /dev/null +++ b/src/api/resources/tags/types/TagsCreateRequestBody.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +export type TagsCreateRequestBody = + | Intercom.CreateOrUpdateTagRequest + | Intercom.TagCompanyRequest + | Intercom.UntagCompanyRequest + | Intercom.TagMultipleUsersRequest; diff --git a/src/api/resources/tags/types/index.ts b/src/api/resources/tags/types/index.ts new file mode 100644 index 00000000..9f251c2a --- /dev/null +++ b/src/api/resources/tags/types/index.ts @@ -0,0 +1,2 @@ +export * from "./TagsCreateRequestBody"; +export * from "./Tag"; diff --git a/src/api/resources/teams/client/Client.ts b/src/api/resources/teams/client/Client.ts new file mode 100644 index 00000000..5cffe77d --- /dev/null +++ b/src/api/resources/teams/client/Client.ts @@ -0,0 +1,226 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace Teams { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Teams + */ +export class Teams { + constructor(protected readonly _options: Teams.Options = {}) {} + + /** + * This will return a list of team objects for the App. + * + * @param {Teams.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.teams.list() + */ + public async list(requestOptions?: Teams.RequestOptions): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "teams" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.TeamList; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /teams."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch the details of a single team, containing an array of admins that belong to this team. + * + * @param {Intercom.FindTeamRequest} request + * @param {Teams.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.teams.find({ + * team_id: "123" + * }) + */ + public async find( + request: Intercom.FindTeamRequest, + requestOptions?: Teams.RequestOptions + ): Promise { + const { team_id: teamId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `teams/${encodeURIComponent(teamId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Team; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /teams/{team_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/teams/client/index.ts b/src/api/resources/teams/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/teams/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/teams/client/requests/FindTeamRequest.ts b/src/api/resources/teams/client/requests/FindTeamRequest.ts new file mode 100644 index 00000000..c2a2151a --- /dev/null +++ b/src/api/resources/teams/client/requests/FindTeamRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * team_id: "123" + * } + */ +export interface FindTeamRequest { + /** + * The unique identifier of a given team. + */ + team_id: string; +} diff --git a/src/api/resources/teams/client/requests/index.ts b/src/api/resources/teams/client/requests/index.ts new file mode 100644 index 00000000..38be3714 --- /dev/null +++ b/src/api/resources/teams/client/requests/index.ts @@ -0,0 +1 @@ +export { type FindTeamRequest } from "./FindTeamRequest"; diff --git a/src/api/resources/teams/index.ts b/src/api/resources/teams/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/teams/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/teams/types/Team.ts b/src/api/resources/teams/types/Team.ts new file mode 100644 index 00000000..698c89c9 --- /dev/null +++ b/src/api/resources/teams/types/Team.ts @@ -0,0 +1,20 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Teams are groups of admins in Intercom. + */ +export interface Team { + /** Value is always "team" */ + type: "team"; + /** The id of the team */ + id: string; + /** The name of the team */ + name: string; + /** The list of admin IDs that are a part of the team. */ + admin_ids: number[]; + admin_priority_level?: Intercom.AdminPriorityLevel; +} diff --git a/src/api/resources/teams/types/index.ts b/src/api/resources/teams/types/index.ts new file mode 100644 index 00000000..e3645596 --- /dev/null +++ b/src/api/resources/teams/types/index.ts @@ -0,0 +1 @@ +export * from "./Team"; diff --git a/src/api/resources/ticketTypes/client/Client.ts b/src/api/resources/ticketTypes/client/Client.ts new file mode 100644 index 00000000..4d37e791 --- /dev/null +++ b/src/api/resources/ticketTypes/client/Client.ts @@ -0,0 +1,392 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; +import { Attributes } from "../resources/attributes/client/Client"; + +export declare namespace TicketTypes { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your ticket types + */ +export class TicketTypes { + protected _attributes: Attributes | undefined; + + constructor(protected readonly _options: TicketTypes.Options = {}) {} + + public get attributes(): Attributes { + return (this._attributes ??= new Attributes(this._options)); + } + + /** + * You can get a list of all ticket types for a workspace. + * + * @param {TicketTypes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.ticketTypes.list() + */ + public async list(requestOptions?: TicketTypes.RequestOptions): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "ticket_types" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.TicketTypeList; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ticket_types."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can create a new ticket type. + * > 📘 Creating ticket types. + * > + * > Every ticket type will be created with two default attributes: _default_title_ and _default_description_. + * > For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) + * + * @param {Intercom.CreateTicketTypeRequest} request + * @param {TicketTypes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.ticketTypes.create({ + * name: "Customer Issue", + * description: "Customer Report Template", + * category: "Customer", + * icon: "\uD83C\uDF9F\uFE0F" + * }) + */ + public async create( + request: Intercom.CreateTicketTypeRequest, + requestOptions?: TicketTypes.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "ticket_types" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.TicketType; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /ticket_types."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch the details of a single ticket type. + * + * @param {Intercom.FindTicketTypeRequest} request + * @param {TicketTypes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.ticketTypes.get({ + * ticket_type_id: "ticket_type_id" + * }) + */ + public async get( + request: Intercom.FindTicketTypeRequest, + requestOptions?: TicketTypes.RequestOptions + ): Promise { + const { ticket_type_id: ticketTypeId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `ticket_types/${encodeURIComponent(ticketTypeId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.TicketType; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /ticket_types/{ticket_type_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * + * You can update a ticket type. + * + * > 📘 Updating a ticket type. + * > + * > For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) + * + * @param {Intercom.UpdateTicketTypeRequest} request + * @param {TicketTypes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.ticketTypes.update({ + * ticket_type_id: "ticket_type_id", + * name: "Bug Report 2" + * }) + */ + public async update( + request: Intercom.UpdateTicketTypeRequest, + requestOptions?: TicketTypes.RequestOptions + ): Promise { + const { ticket_type_id: ticketTypeId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `ticket_types/${encodeURIComponent(ticketTypeId)}` + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.TicketType; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling PUT /ticket_types/{ticket_type_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/ticketTypes/client/index.ts b/src/api/resources/ticketTypes/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/ticketTypes/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/ticketTypes/client/requests/CreateTicketTypeRequest.ts b/src/api/resources/ticketTypes/client/requests/CreateTicketTypeRequest.ts new file mode 100644 index 00000000..0282e169 --- /dev/null +++ b/src/api/resources/ticketTypes/client/requests/CreateTicketTypeRequest.ts @@ -0,0 +1,37 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * name: "Customer Issue", + * description: "Customer Report Template", + * category: "Customer", + * icon: "\uD83C\uDF9F\uFE0F" + * } + */ +export interface CreateTicketTypeRequest { + /** The name of the ticket type. */ + name: string; + /** The description of the ticket type. */ + description?: string; + /** Category of the Ticket Type. */ + category?: CreateTicketTypeRequest.Category; + /** The icon of the ticket type. */ + icon?: string; + /** Whether the tickets associated with this ticket type are intended for internal use only or will be shared with customers. This is currently a limited attribute. */ + is_internal?: boolean; +} + +export namespace CreateTicketTypeRequest { + /** + * Category of the Ticket Type. + */ + export type Category = "Customer" | "Back-office" | "Tracker"; + export const Category = { + Customer: "Customer", + BackOffice: "Back-office", + Tracker: "Tracker", + } as const; +} diff --git a/src/api/resources/ticketTypes/client/requests/FindTicketTypeRequest.ts b/src/api/resources/ticketTypes/client/requests/FindTicketTypeRequest.ts new file mode 100644 index 00000000..968dd46d --- /dev/null +++ b/src/api/resources/ticketTypes/client/requests/FindTicketTypeRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * ticket_type_id: "ticket_type_id" + * } + */ +export interface FindTicketTypeRequest { + /** + * The unique identifier for the ticket type which is given by Intercom. + */ + ticket_type_id: string; +} diff --git a/src/api/resources/ticketTypes/client/requests/UpdateTicketTypeRequest.ts b/src/api/resources/ticketTypes/client/requests/UpdateTicketTypeRequest.ts new file mode 100644 index 00000000..55572ebe --- /dev/null +++ b/src/api/resources/ticketTypes/client/requests/UpdateTicketTypeRequest.ts @@ -0,0 +1,41 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * ticket_type_id: "ticket_type_id", + * name: "Bug Report 2" + * } + */ +export interface UpdateTicketTypeRequest { + /** + * The unique identifier for the ticket type which is given by Intercom. + */ + ticket_type_id: string; + /** The name of the ticket type. */ + name?: string; + /** The description of the ticket type. */ + description?: string; + /** Category of the Ticket Type. */ + category?: UpdateTicketTypeRequest.Category; + /** The icon of the ticket type. */ + icon?: string; + /** The archived status of the ticket type. */ + archived?: boolean; + /** Whether the tickets associated with this ticket type are intended for internal use only or will be shared with customers. This is currently a limited attribute. */ + is_internal?: boolean; +} + +export namespace UpdateTicketTypeRequest { + /** + * Category of the Ticket Type. + */ + export type Category = "Customer" | "Back-office" | "Tracker"; + export const Category = { + Customer: "Customer", + BackOffice: "Back-office", + Tracker: "Tracker", + } as const; +} diff --git a/src/api/resources/ticketTypes/client/requests/index.ts b/src/api/resources/ticketTypes/client/requests/index.ts new file mode 100644 index 00000000..7b66e378 --- /dev/null +++ b/src/api/resources/ticketTypes/client/requests/index.ts @@ -0,0 +1,3 @@ +export { type CreateTicketTypeRequest } from "./CreateTicketTypeRequest"; +export { type FindTicketTypeRequest } from "./FindTicketTypeRequest"; +export { type UpdateTicketTypeRequest } from "./UpdateTicketTypeRequest"; diff --git a/src/api/resources/ticketTypes/index.ts b/src/api/resources/ticketTypes/index.ts new file mode 100644 index 00000000..33a87f10 --- /dev/null +++ b/src/api/resources/ticketTypes/index.ts @@ -0,0 +1,2 @@ +export * from "./client"; +export * from "./resources"; diff --git a/src/api/resources/ticketTypes/resources/attributes/client/Client.ts b/src/api/resources/ticketTypes/resources/attributes/client/Client.ts new file mode 100644 index 00000000..f2a677b5 --- /dev/null +++ b/src/api/resources/ticketTypes/resources/attributes/client/Client.ts @@ -0,0 +1,239 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Attributes { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +export class Attributes { + constructor(protected readonly _options: Attributes.Options = {}) {} + + /** + * You can create a new attribute for a ticket type. + * + * @param {Intercom.ticketTypes.CreateTicketTypeAttributeRequest} request + * @param {Attributes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.ticketTypes.attributes.create({ + * ticket_type_id: "ticket_type_id", + * name: "Attribute Title", + * description: "Attribute Description", + * data_type: "string", + * required_to_create: false + * }) + */ + public async create( + request: Intercom.ticketTypes.CreateTicketTypeAttributeRequest, + requestOptions?: Attributes.RequestOptions + ): Promise { + const { ticket_type_id: ticketTypeId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `ticket_types/${encodeURIComponent(ticketTypeId)}/attributes` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.TicketTypeAttribute; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /ticket_types/{ticket_type_id}/attributes." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can update an existing attribute for a ticket type. + * + * @param {Intercom.ticketTypes.UpdateTicketTypeAttributeRequest} request + * @param {Attributes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.ticketTypes.attributes.update({ + * ticket_type_id: "ticket_type_id", + * attribute_id: "attribute_id", + * description: "New Attribute Description" + * }) + */ + public async update( + request: Intercom.ticketTypes.UpdateTicketTypeAttributeRequest, + requestOptions?: Attributes.RequestOptions + ): Promise { + const { ticket_type_id: ticketTypeId, attribute_id: attributeId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `ticket_types/${encodeURIComponent(ticketTypeId)}/attributes/${encodeURIComponent(attributeId)}` + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.TicketTypeAttribute; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling PUT /ticket_types/{ticket_type_id}/attributes/{attribute_id}." + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/ticketTypes/resources/attributes/client/index.ts b/src/api/resources/ticketTypes/resources/attributes/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/ticketTypes/resources/attributes/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/ticketTypes/resources/attributes/client/requests/CreateTicketTypeAttributeRequest.ts b/src/api/resources/ticketTypes/resources/attributes/client/requests/CreateTicketTypeAttributeRequest.ts new file mode 100644 index 00000000..0a9604c1 --- /dev/null +++ b/src/api/resources/ticketTypes/resources/attributes/client/requests/CreateTicketTypeAttributeRequest.ts @@ -0,0 +1,56 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * ticket_type_id: "ticket_type_id", + * name: "Attribute Title", + * description: "Attribute Description", + * data_type: "string", + * required_to_create: false + * } + */ +export interface CreateTicketTypeAttributeRequest { + /** + * The unique identifier for the ticket type which is given by Intercom. + */ + ticket_type_id: string; + /** The name of the ticket type attribute */ + name: string; + /** The description of the attribute presented to the teammate or contact */ + description: string; + /** The data type of the attribute */ + data_type: CreateTicketTypeAttributeRequest.DataType; + /** Whether the attribute is required to be filled in when teammates are creating the ticket in Inbox. */ + required_to_create?: boolean; + /** Whether the attribute is required to be filled in when contacts are creating the ticket in Messenger. */ + required_to_create_for_contacts?: boolean; + /** Whether the attribute is visible to teammates when creating a ticket in Inbox. */ + visible_on_create?: boolean; + /** Whether the attribute is visible to contacts when creating a ticket in Messenger. */ + visible_to_contacts?: boolean; + /** Whether the attribute allows multiple lines of text (only applicable to string attributes) */ + multiline?: boolean; + /** A comma delimited list of items for the attribute value (only applicable to list attributes) */ + list_items?: string; + /** Whether the attribute allows multiple files to be attached to it (only applicable to file attributes) */ + allow_multiple_values?: boolean; +} + +export namespace CreateTicketTypeAttributeRequest { + /** + * The data type of the attribute + */ + export type DataType = "string" | "list" | "integer" | "decimal" | "boolean" | "datetime" | "files"; + export const DataType = { + String: "string", + List: "list", + Integer: "integer", + Decimal: "decimal", + Boolean: "boolean", + Datetime: "datetime", + Files: "files", + } as const; +} diff --git a/src/api/resources/ticketTypes/resources/attributes/client/requests/UpdateTicketTypeAttributeRequest.ts b/src/api/resources/ticketTypes/resources/attributes/client/requests/UpdateTicketTypeAttributeRequest.ts new file mode 100644 index 00000000..a7324b1e --- /dev/null +++ b/src/api/resources/ticketTypes/resources/attributes/client/requests/UpdateTicketTypeAttributeRequest.ts @@ -0,0 +1,42 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * ticket_type_id: "ticket_type_id", + * attribute_id: "attribute_id", + * description: "New Attribute Description" + * } + */ +export interface UpdateTicketTypeAttributeRequest { + /** + * The unique identifier for the ticket type which is given by Intercom. + */ + ticket_type_id: string; + /** + * The unique identifier for the ticket type attribute which is given by Intercom. + */ + attribute_id: string; + /** The name of the ticket type attribute */ + name?: string; + /** The description of the attribute presented to the teammate or contact */ + description?: string; + /** Whether the attribute is required to be filled in when teammates are creating the ticket in Inbox. */ + required_to_create?: boolean; + /** Whether the attribute is required to be filled in when contacts are creating the ticket in Messenger. */ + required_to_create_for_contacts?: boolean; + /** Whether the attribute is visible to teammates when creating a ticket in Inbox. */ + visible_on_create?: boolean; + /** Whether the attribute is visible to contacts when creating a ticket in Messenger. */ + visible_to_contacts?: boolean; + /** Whether the attribute allows multiple lines of text (only applicable to string attributes) */ + multiline?: boolean; + /** A comma delimited list of items for the attribute value (only applicable to list attributes) */ + list_items?: string; + /** Whether the attribute allows multiple files to be attached to it (only applicable to file attributes) */ + allow_multiple_values?: boolean; + /** Whether the attribute should be archived and not shown during creation of the ticket (it will still be present on previously created tickets) */ + archived?: boolean; +} diff --git a/src/api/resources/ticketTypes/resources/attributes/client/requests/index.ts b/src/api/resources/ticketTypes/resources/attributes/client/requests/index.ts new file mode 100644 index 00000000..b2d37564 --- /dev/null +++ b/src/api/resources/ticketTypes/resources/attributes/client/requests/index.ts @@ -0,0 +1,2 @@ +export { type CreateTicketTypeAttributeRequest } from "./CreateTicketTypeAttributeRequest"; +export { type UpdateTicketTypeAttributeRequest } from "./UpdateTicketTypeAttributeRequest"; diff --git a/src/api/resources/ticketTypes/resources/attributes/index.ts b/src/api/resources/ticketTypes/resources/attributes/index.ts new file mode 100644 index 00000000..5ec76921 --- /dev/null +++ b/src/api/resources/ticketTypes/resources/attributes/index.ts @@ -0,0 +1 @@ +export * from "./client"; diff --git a/src/api/resources/ticketTypes/resources/index.ts b/src/api/resources/ticketTypes/resources/index.ts new file mode 100644 index 00000000..85faeec8 --- /dev/null +++ b/src/api/resources/ticketTypes/resources/index.ts @@ -0,0 +1,2 @@ +export * as attributes from "./attributes"; +export * from "./attributes/client/requests"; diff --git a/src/api/resources/tickets/client/Client.ts b/src/api/resources/tickets/client/Client.ts new file mode 100644 index 00000000..1f86b3b8 --- /dev/null +++ b/src/api/resources/tickets/client/Client.ts @@ -0,0 +1,622 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace Tickets { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your tickets + */ +export class Tickets { + constructor(protected readonly _options: Tickets.Options = {}) {} + + /** + * You can reply to a ticket with a message from an admin or on behalf of a contact, or with a note for admins. + * + * @param {Intercom.ReplyToTicketRequest} request + * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.tickets.reply({ + * ticket_id: "123", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d619d8a68186f43bafe82" + * } + * }) + * + * @example + * await client.tickets.reply({ + * ticket_id: "123", + * body: { + * message_type: "note", + * type: "admin", + * body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + * admin_id: "3156780" + * } + * }) + * + * @example + * await client.tickets.reply({ + * ticket_id: "123", + * body: { + * message_type: "quick_reply", + * type: "admin", + * admin_id: "3156780", + * reply_options: [{ + * text: "Yes", + * uuid: "22d6d1f4-1a19-41d0-94c2-e54031f78aca" + * }, { + * text: "No", + * uuid: "fbc3dbe0-ec0c-4fb6-826d-e19127191906" + * }] + * } + * }) + * + * @example + * await client.tickets.reply({ + * ticket_id: "123", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d61a68a68186f43bafe85" + * } + * }) + */ + public async reply( + request: Intercom.ReplyToTicketRequest, + requestOptions?: Tickets.RequestOptions + ): Promise { + const { ticket_id: ticketId, body: _body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(ticketId)}/reply` + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.TicketReply; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown); + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/{ticket_id}/reply."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can create a new ticket. + * + * @param {Intercom.CreateTicketRequest} request + * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.tickets.create({ + * ticket_type_id: "1234", + * contacts: [{ + * id: "667d61b78a68186f43bafe8d" + * }], + * ticket_attributes: { + * "_default_title_": "example", + * "_default_description_": "there is a problem" + * } + * }) + */ + public async create( + request: Intercom.CreateTicketRequest, + requestOptions?: Tickets.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "tickets" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Ticket; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can fetch the details of a single ticket. + * + * @param {Intercom.FindTicketRequest} request + * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.tickets.get({ + * ticket_id: "ticket_id" + * }) + */ + public async get( + request: Intercom.FindTicketRequest, + requestOptions?: Tickets.RequestOptions + ): Promise { + const { ticket_id: ticketId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(ticketId)}` + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Ticket; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tickets/{ticket_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can update a ticket. + * + * @param {Intercom.UpdateTicketRequest} request + * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.tickets.update({ + * ticket_id: "ticket_id", + * ticket_attributes: { + * "_default_title_": "example", + * "_default_description_": "there is a problem" + * }, + * state: "in_progress", + * open: true, + * snoozed_until: 1673609604, + * assignment: { + * admin_id: "991267883", + * assignee_id: "991267885" + * } + * }) + * + * @example + * await client.tickets.update({ + * ticket_id: "ticket_id", + * ticket_attributes: { + * "_default_title_": "example", + * "_default_description_": "there is a problem" + * }, + * state: "in_progress", + * assignment: { + * admin_id: "123", + * assignee_id: "991267893" + * } + * }) + * + * @example + * await client.tickets.update({ + * ticket_id: "ticket_id", + * ticket_attributes: { + * "_default_title_": "example", + * "_default_description_": "there is a problem" + * }, + * state: "in_progress", + * assignment: { + * admin_id: "991267899", + * assignee_id: "456" + * } + * }) + */ + public async update( + request: Intercom.UpdateTicketRequest, + requestOptions?: Tickets.RequestOptions + ): Promise { + const { ticket_id: ticketId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(ticketId)}` + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Ticket; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /tickets/{ticket_id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can search for multiple tickets by the value of their attributes in order to fetch exactly which ones you want. + * + * To search for tickets, you send a `POST` request to `https://api.intercom.io/tickets/search`. + * + * This will accept a query object in the body which will define your filters. + * {% admonition type="warning" name="Optimizing search queries" %} + * Search queries can be complex, so optimizing them can help the performance of your search. + * Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize + * pagination to limit the number of results returned. The default is `20` results per page. + * See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. + * {% /admonition %} + * + * ### Nesting & Limitations + * + * You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). + * There are some limitations to the amount of multiples there can be: + * - There's a limit of max 2 nested filters + * - There's a limit of max 15 filters for each AND or OR group + * + * ### Accepted Fields + * + * Most keys listed as part of the Ticket model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foobar"`). + * + * | Field | Type | + * | :---------------------------------------- | :--------------------------------------------------------------------------------------- | + * | id | String | + * | created_at | Date (UNIX timestamp) | + * | updated_at | Date (UNIX timestamp) | + * | _default_title_ | String | + * | _default_description_ | String | + * | category | String | + * | ticket_type_id | String | + * | contact_ids | String | + * | teammate_ids | String | + * | admin_assignee_id | String | + * | team_assignee_id | String | + * | open | Boolean | + * | state | String | + * | snoozed_until | Date (UNIX timestamp) | + * | ticket_attribute.{id} | String or Boolean or Date (UNIX timestamp) or Float or Integer | + * + * ### Accepted Operators + * + * {% admonition type="info" name="Searching based on `created_at`" %} + * You may use the `<=` or `>=` operators to search by `created_at`. + * {% /admonition %} + * + * The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + * + * | Operator | Valid Types | Description | + * | :------- | :----------------------------- | :----------------------------------------------------------- | + * | = | All | Equals | + * | != | All | Doesn't Equal | + * | IN | All | In Shortcut for `OR` queries Values most be in Array | + * | NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | + * | > | Integer Date (UNIX Timestamp) | Greater (or equal) than | + * | < | Integer Date (UNIX Timestamp) | Lower (or equal) than | + * | ~ | String | Contains | + * | !~ | String | Doesn't Contain | + * | ^ | String | Starts With | + * | $ | String | Ends With | + * + * @param {Intercom.SearchRequest} request + * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.tickets.search({ + * query: { + * operator: "AND", + * value: [{ + * field: "created_at", + * operator: ">", + * value: "1306054154" + * }] + * }, + * pagination: { + * per_page: 5 + * } + * }) + */ + public async search( + request: Intercom.SearchRequest, + requestOptions?: Tickets.RequestOptions + ): Promise> { + const list = async (request: Intercom.SearchRequest): Promise => { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "tickets/search" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.TicketList; + } + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/search."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + }; + return new core.Pageable({ + response: await list(request), + hasNextPage: (response) => response?.pages?.next?.starting_after != null, + getItems: (response) => response?.tickets ?? [], + loadPage: (response) => { + return list( + core.setObjectProperty(request, "pagination.starting_after", response?.pages?.next?.starting_after) + ); + }, + }); + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/tickets/client/index.ts b/src/api/resources/tickets/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/tickets/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/tickets/client/requests/CreateTicketRequest.ts b/src/api/resources/tickets/client/requests/CreateTicketRequest.ts new file mode 100644 index 00000000..db4974e5 --- /dev/null +++ b/src/api/resources/tickets/client/requests/CreateTicketRequest.ts @@ -0,0 +1,47 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../index"; + +/** + * @example + * { + * ticket_type_id: "1234", + * contacts: [{ + * id: "667d61b78a68186f43bafe8d" + * }], + * ticket_attributes: { + * "_default_title_": "example", + * "_default_description_": "there is a problem" + * } + * } + */ +export interface CreateTicketRequest { + /** The ID of the type of ticket you want to create */ + ticket_type_id: string; + /** The list of contacts (users or leads) affected by this ticket. Currently only one is allowed */ + contacts: CreateTicketRequest.Contacts.Item[]; + /** The ID of the company that the ticket is associated with. The ID that you set upon company creation. */ + company_id?: string; + /** The time the ticket was created. If not provided, the current time will be used. */ + created_at?: number; + ticket_attributes?: Intercom.TicketRequestCustomAttributes; +} + +export namespace CreateTicketRequest { + export type Contacts = Contacts.Item[]; + + export namespace Contacts { + export type Item = + | { + id: string; + } + | { + external_id: string; + } + | { + email: string; + }; + } +} diff --git a/src/api/resources/tickets/client/requests/FindTicketRequest.ts b/src/api/resources/tickets/client/requests/FindTicketRequest.ts new file mode 100644 index 00000000..450d0725 --- /dev/null +++ b/src/api/resources/tickets/client/requests/FindTicketRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * ticket_id: "ticket_id" + * } + */ +export interface FindTicketRequest { + /** + * The unique identifier for the ticket which is given by Intercom. + */ + ticket_id: string; +} diff --git a/src/api/resources/tickets/client/requests/ReplyToTicketRequest.ts b/src/api/resources/tickets/client/requests/ReplyToTicketRequest.ts new file mode 100644 index 00000000..c00dcfdd --- /dev/null +++ b/src/api/resources/tickets/client/requests/ReplyToTicketRequest.ts @@ -0,0 +1,83 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../index"; + +/** + * @example + * { + * ticket_id: "123", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d619d8a68186f43bafe82" + * } + * } + * + * @example + * { + * ticket_id: "123", + * body: { + * message_type: "note", + * type: "admin", + * body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + * admin_id: "3156780" + * } + * } + * + * @example + * { + * ticket_id: "123", + * body: { + * message_type: "quick_reply", + * type: "admin", + * admin_id: "3156780", + * reply_options: [{ + * text: "Yes", + * uuid: "22d6d1f4-1a19-41d0-94c2-e54031f78aca" + * }, { + * text: "No", + * uuid: "fbc3dbe0-ec0c-4fb6-826d-e19127191906" + * }] + * } + * } + * + * @example + * { + * ticket_id: "123", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d61a68a68186f43bafe85" + * } + * } + * + * @example + * { + * ticket_id: "123", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d619d8a68186f43bafe82" + * } + * } + * + * @example + * { + * ticket_id: "123", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "667d619d8a68186f43bafe82" + * } + * } + */ +export interface ReplyToTicketRequest { + ticket_id: string; + body: Intercom.TicketsReplyRequestBody; +} diff --git a/src/api/resources/tickets/client/requests/UpdateTicketRequest.ts b/src/api/resources/tickets/client/requests/UpdateTicketRequest.ts new file mode 100644 index 00000000..99555fa9 --- /dev/null +++ b/src/api/resources/tickets/client/requests/UpdateTicketRequest.ts @@ -0,0 +1,85 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * ticket_id: "ticket_id", + * ticket_attributes: { + * "_default_title_": "example", + * "_default_description_": "there is a problem" + * }, + * state: "in_progress", + * open: true, + * snoozed_until: 1673609604, + * assignment: { + * admin_id: "991267883", + * assignee_id: "991267885" + * } + * } + * + * @example + * { + * ticket_id: "ticket_id", + * ticket_attributes: { + * "_default_title_": "example", + * "_default_description_": "there is a problem" + * }, + * state: "in_progress", + * assignment: { + * admin_id: "123", + * assignee_id: "991267893" + * } + * } + * + * @example + * { + * ticket_id: "ticket_id", + * ticket_attributes: { + * "_default_title_": "example", + * "_default_description_": "there is a problem" + * }, + * state: "in_progress", + * assignment: { + * admin_id: "991267899", + * assignee_id: "456" + * } + * } + */ +export interface UpdateTicketRequest { + /** + * The unique identifier for the ticket which is given by Intercom + */ + ticket_id: string; + /** The attributes set on the ticket. */ + ticket_attributes?: Record; + /** The state of the ticket. */ + state?: UpdateTicketRequest.State; + /** Specify if a ticket is open. Set to false to close a ticket. Closing a ticket will also unsnooze it. */ + open?: boolean; + /** Specify whether the ticket is visible to users. */ + is_shared?: boolean; + /** The time you want the ticket to reopen. */ + snoozed_until?: number; + assignment?: UpdateTicketRequest.Assignment; +} + +export namespace UpdateTicketRequest { + /** + * The state of the ticket. + */ + export type State = "in_progress" | "waiting_on_customer" | "resolved"; + export const State = { + InProgress: "in_progress", + WaitingOnCustomer: "waiting_on_customer", + Resolved: "resolved", + } as const; + + export interface Assignment { + /** The ID of the admin performing the action. */ + admin_id?: string; + /** The ID of the admin or team to which the ticket is assigned. Set this 0 to unassign it. */ + assignee_id?: string; + } +} diff --git a/src/api/resources/tickets/client/requests/index.ts b/src/api/resources/tickets/client/requests/index.ts new file mode 100644 index 00000000..083c02e9 --- /dev/null +++ b/src/api/resources/tickets/client/requests/index.ts @@ -0,0 +1,4 @@ +export { type ReplyToTicketRequest } from "./ReplyToTicketRequest"; +export { type CreateTicketRequest } from "./CreateTicketRequest"; +export { type FindTicketRequest } from "./FindTicketRequest"; +export { type UpdateTicketRequest } from "./UpdateTicketRequest"; diff --git a/src/api/resources/tickets/index.ts b/src/api/resources/tickets/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/tickets/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/tickets/types/Ticket.ts b/src/api/resources/tickets/types/Ticket.ts new file mode 100644 index 00000000..4962e861 --- /dev/null +++ b/src/api/resources/tickets/types/Ticket.ts @@ -0,0 +1,66 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Tickets are how you track requests from your users. + */ +export interface Ticket { + /** Always ticket */ + type: "ticket"; + /** The unique identifier for the ticket which is given by Intercom. */ + id: string; + /** The ID of the Ticket used in the Intercom Inbox and Messenger. Do not use ticket_id for API queries. */ + ticket_id: string; + /** Category of the Ticket. */ + category: Ticket.Category; + ticket_attributes: Intercom.TicketCustomAttributes; + /** The state the ticket is currently in */ + ticket_state: Ticket.TicketState; + ticket_type: Intercom.TicketType; + contacts: Intercom.TicketContacts; + /** The id representing the admin assigned to the ticket. */ + admin_assignee_id?: string; + /** The id representing the team assigned to the ticket. */ + team_assignee_id?: string; + /** The time the ticket was created as a UTC Unix timestamp. */ + created_at?: number; + /** The last time the ticket was updated as a UTC Unix timestamp. */ + updated_at?: number; + /** Whether or not the ticket is open. If false, the ticket is closed. */ + open?: boolean; + /** The time the ticket will be snoozed until as a UTC Unix timestamp. If null, the ticket is not currently snoozed. */ + snoozed_until?: number; + linked_objects?: Intercom.LinkedObjectList; + ticket_parts?: Intercom.TicketParts; + /** Whether or not the ticket is shared with the customer. */ + is_shared?: boolean; + /** The state the ticket is currently in, in a human readable form - visible in Intercom */ + ticket_state_internal_label?: string; + /** The state the ticket is currently in, in a human readable form - visible to customers, in the messenger, email and tickets portal. */ + ticket_state_external_label?: string; +} + +export namespace Ticket { + /** + * Category of the Ticket. + */ + export type Category = "Customer" | "Back-office" | "Tracker"; + export const Category = { + Customer: "Customer", + BackOffice: "Back-office", + Tracker: "Tracker", + } as const; + /** + * The state the ticket is currently in + */ + export type TicketState = "submitted" | "in_progress" | "waiting_on_customer" | "resolved"; + export const TicketState = { + Submitted: "submitted", + InProgress: "in_progress", + WaitingOnCustomer: "waiting_on_customer", + Resolved: "resolved", + } as const; +} diff --git a/src/api/resources/tickets/types/TicketContacts.ts b/src/api/resources/tickets/types/TicketContacts.ts new file mode 100644 index 00000000..cc70ccbb --- /dev/null +++ b/src/api/resources/tickets/types/TicketContacts.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * The list of contacts affected by a ticket. + */ +export interface TicketContacts { + /** always contact.list */ + type: "contact.list"; + /** The list of contacts affected by this ticket. */ + contacts: Intercom.ContactReference[]; +} diff --git a/src/api/resources/tickets/types/TicketPart.ts b/src/api/resources/tickets/types/TicketPart.ts new file mode 100644 index 00000000..ecfb0528 --- /dev/null +++ b/src/api/resources/tickets/types/TicketPart.ts @@ -0,0 +1,59 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A Ticket Part represents a message in the ticket. + */ +export interface TicketPart { + /** Always ticket_part */ + type: "ticket_part"; + /** The id representing the ticket part. */ + id: string; + /** The type of ticket part. */ + part_type: string; + /** The message body, which may contain HTML. */ + body?: string; + /** The previous state of the ticket. */ + previous_ticket_state?: TicketPart.PreviousTicketState; + /** The state of the ticket. */ + ticket_state: TicketPart.TicketState; + /** The time the ticket part was created. */ + created_at: number; + /** The last time the ticket part was updated. */ + updated_at?: number; + /** The id of the admin that was assigned the ticket by this ticket_part (null if there has been no change in assignment.) */ + assigned_to?: Intercom.Reference; + author?: Intercom.TicketPartAuthor; + /** A list of attachments for the part. */ + attachments?: Intercom.PartAttachment[]; + /** The external id of the ticket part */ + external_id?: string; + /** Whether or not the ticket part has been redacted. */ + redacted?: boolean; +} + +export namespace TicketPart { + /** + * The previous state of the ticket. + */ + export type PreviousTicketState = "submitted" | "in_progress" | "waiting_on_customer" | "resolved"; + export const PreviousTicketState = { + Submitted: "submitted", + InProgress: "in_progress", + WaitingOnCustomer: "waiting_on_customer", + Resolved: "resolved", + } as const; + /** + * The state of the ticket. + */ + export type TicketState = "submitted" | "in_progress" | "waiting_on_customer" | "resolved"; + export const TicketState = { + Submitted: "submitted", + InProgress: "in_progress", + WaitingOnCustomer: "waiting_on_customer", + Resolved: "resolved", + } as const; +} diff --git a/src/api/resources/tickets/types/TicketType.ts b/src/api/resources/tickets/types/TicketType.ts new file mode 100644 index 00000000..ae240f82 --- /dev/null +++ b/src/api/resources/tickets/types/TicketType.ts @@ -0,0 +1,44 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A ticket type, used to define the data fields to be captured in a ticket. + */ +export interface TicketType { + /** String representing the object's type. Always has the value `ticket_type`. */ + type: "ticket_type"; + /** The id representing the ticket type. */ + id: string; + /** Category of the Ticket Type. */ + category: TicketType.Category; + /** The name of the ticket type */ + name: string; + /** The description of the ticket type */ + description: string; + /** The icon of the ticket type */ + icon: string; + /** The id of the workspace that the ticket type belongs to. */ + workspace_id: string; + ticket_type_attributes: Intercom.TicketTypeAttributeList; + /** Whether the ticket type is archived or not. */ + archived: boolean; + /** The date and time the ticket type was created. */ + created_at: number; + /** The date and time the ticket type was last updated. */ + updated_at?: number; +} + +export namespace TicketType { + /** + * Category of the Ticket Type. + */ + export type Category = "Customer" | "Back-office" | "Tracker"; + export const Category = { + Customer: "Customer", + BackOffice: "Back-office", + Tracker: "Tracker", + } as const; +} diff --git a/src/api/resources/tickets/types/TicketsReplyRequestBody.ts b/src/api/resources/tickets/types/TicketsReplyRequestBody.ts new file mode 100644 index 00000000..e6c57710 --- /dev/null +++ b/src/api/resources/tickets/types/TicketsReplyRequestBody.ts @@ -0,0 +1,7 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +export type TicketsReplyRequestBody = Intercom.ContactReplyTicketRequest | Intercom.AdminReplyTicketRequest; diff --git a/src/api/resources/tickets/types/index.ts b/src/api/resources/tickets/types/index.ts new file mode 100644 index 00000000..2bba4510 --- /dev/null +++ b/src/api/resources/tickets/types/index.ts @@ -0,0 +1,5 @@ +export * from "./TicketsReplyRequestBody"; +export * from "./Ticket"; +export * from "./TicketContacts"; +export * from "./TicketPart"; +export * from "./TicketType"; diff --git a/src/api/resources/visitors/client/Client.ts b/src/api/resources/visitors/client/Client.ts new file mode 100644 index 00000000..284b58b3 --- /dev/null +++ b/src/api/resources/visitors/client/Client.ts @@ -0,0 +1,333 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import * as Intercom from "../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace Visitors { + interface Options { + environment?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Visitors + */ +export class Visitors { + constructor(protected readonly _options: Visitors.Options = {}) {} + + /** + * You can fetch the details of a single visitor. + * + * @param {Intercom.FindVisitorRequest} request + * @param {Visitors.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.visitors.find({ + * user_id: "user_id" + * }) + */ + public async find( + request: Intercom.FindVisitorRequest, + requestOptions?: Visitors.RequestOptions + ): Promise { + const { user_id: userId } = request; + const _queryParams: Record = {}; + _queryParams["user_id"] = userId; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "visitors" + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Visitor; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /visitors."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * Sending a PUT request to `/visitors` will result in an update of an existing Visitor. + * + * **Option 1.** You can update a visitor by passing in the `user_id` of the visitor in the Request body. + * + * **Option 2.** You can update a visitor by passing in the `id` of the visitor in the Request body. + * + * @param {Intercom.UpdateVisitorRequest} request + * @param {Visitors.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.visitors.update({ + * id: "667d61cc8a68186f43bafe95", + * name: "Gareth Bale" + * }) + * + * @example + * await client.visitors.update({ + * user_id: "fail", + * name: "Christian Fail" + * }) + */ + public async update( + request: Intercom.UpdateVisitorRequest, + requestOptions?: Visitors.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "visitors" + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Visitor; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /visitors."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * You can merge a Visitor to a Contact of role type `lead` or `user`. + * + * > 📘 What happens upon a visitor being converted? + * > + * > If the User exists, then the Visitor will be merged into it, the Visitor deleted and the User returned. If the User does not exist, the Visitor will be converted to a User, with the User identifiers replacing it's Visitor identifiers. + * + * @param {Intercom.MergeVisitorToContactRequest} request + * @param {Visitors.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.visitors.mergeToContact({ + * type: "user", + * user: { + * id: "8a88a590-e1c3-41e2-a502-e0649dbf721c", + * email: "foo@bar.com" + * }, + * visitor: { + * user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3" + * } + * }) + */ + public async mergeToContact( + request: Intercom.MergeVisitorToContactRequest, + requestOptions?: Visitors.RequestOptions + ): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, + "visitors/convert" + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.0.0", + "User-Agent": "intercom-client/6.0.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as Intercom.Contact; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /visitors/convert."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: "Please specify INTERCOM_API_KEY when instantiating the client.", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/visitors/client/index.ts b/src/api/resources/visitors/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/visitors/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/visitors/client/requests/FindVisitorRequest.ts b/src/api/resources/visitors/client/requests/FindVisitorRequest.ts new file mode 100644 index 00000000..24bdf1b9 --- /dev/null +++ b/src/api/resources/visitors/client/requests/FindVisitorRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * user_id: "user_id" + * } + */ +export interface FindVisitorRequest { + /** + * The user_id of the Visitor you want to retrieve. + */ + user_id: string; +} diff --git a/src/api/resources/visitors/client/requests/MergeVisitorToContactRequest.ts b/src/api/resources/visitors/client/requests/MergeVisitorToContactRequest.ts new file mode 100644 index 00000000..85a59941 --- /dev/null +++ b/src/api/resources/visitors/client/requests/MergeVisitorToContactRequest.ts @@ -0,0 +1,53 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * type: "user", + * user: { + * id: "8a88a590-e1c3-41e2-a502-e0649dbf721c", + * email: "foo@bar.com" + * }, + * visitor: { + * user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3" + * } + * } + */ +export interface MergeVisitorToContactRequest { + /** Represents the role of the Contact model. Accepts `lead` or `user`. */ + type: string; + /** The unique identifiers retained after converting or merging. */ + user: MergeVisitorToContactRequest.User; + /** The unique identifiers to convert a single Visitor. */ + visitor: MergeVisitorToContactRequest.Visitor; +} + +export namespace MergeVisitorToContactRequest { + /** + * The unique identifiers retained after converting or merging. + */ + export type User = + | { + id: string; + email?: string | undefined; + } + | { + user_id: string; + email?: string | undefined; + }; + /** + * The unique identifiers to convert a single Visitor. + */ + export type Visitor = + | { + id: string; + } + | { + user_id: string; + } + | { + email: string; + }; +} diff --git a/src/api/resources/visitors/client/requests/index.ts b/src/api/resources/visitors/client/requests/index.ts new file mode 100644 index 00000000..c03d0f15 --- /dev/null +++ b/src/api/resources/visitors/client/requests/index.ts @@ -0,0 +1,2 @@ +export { type FindVisitorRequest } from "./FindVisitorRequest"; +export { type MergeVisitorToContactRequest } from "./MergeVisitorToContactRequest"; diff --git a/src/api/resources/visitors/index.ts b/src/api/resources/visitors/index.ts new file mode 100644 index 00000000..5ec76921 --- /dev/null +++ b/src/api/resources/visitors/index.ts @@ -0,0 +1 @@ +export * from "./client"; diff --git a/src/api/types/ActivityLog.ts b/src/api/types/ActivityLog.ts new file mode 100644 index 00000000..80328f6f --- /dev/null +++ b/src/api/types/ActivityLog.ts @@ -0,0 +1,175 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Activities performed by Admins. + */ +export interface ActivityLog { + /** The id representing the activity. */ + id: string; + /** Details about the Admin involved in the activity. */ + performed_by: ActivityLog.PerformedBy; + metadata?: Intercom.ActivityLogMetadata; + /** The time the activity was created. */ + created_at?: number; + activity_type: ActivityLog.ActivityType; + /** A sentence or two describing the activity. */ + activity_description?: string; +} + +export namespace ActivityLog { + /** + * Details about the Admin involved in the activity. + */ + export interface PerformedBy { + /** String representing the object's type. Always has the value `admin`. */ + type?: "admin"; + /** The id representing the admin. */ + id?: string; + /** The email of the admin. */ + email?: string; + /** The IP address of the admin. */ + ip?: string; + } + + export type ActivityType = + | "admin_assignment_limit_change" + | "admin_away_mode_change" + | "admin_deletion" + | "admin_deprovisioned" + | "admin_impersonation_end" + | "admin_impersonation_start" + | "admin_invite_change" + | "admin_invite_creation" + | "admin_invite_deletion" + | "admin_login_failure" + | "admin_login_success" + | "admin_logout" + | "admin_password_reset_request" + | "admin_password_reset_success" + | "admin_permission_change" + | "admin_provisioned" + | "admin_two_factor_auth_change" + | "admin_unauthorized_sign_in_method" + | "app_admin_join" + | "app_authentication_method_change" + | "app_data_deletion" + | "app_data_export" + | "app_google_sso_domain_change" + | "app_identity_verification_change" + | "app_name_change" + | "app_outbound_address_change" + | "app_package_installation" + | "app_package_token_regeneration" + | "app_package_uninstallation" + | "app_team_creation" + | "app_team_deletion" + | "app_team_membership_modification" + | "app_timezone_change" + | "app_webhook_creation" + | "app_webhook_deletion" + | "articles_in_messenger_enabled_change" + | "bulk_delete" + | "bulk_export" + | "campaign_deletion" + | "campaign_state_change" + | "conversation_part_deletion" + | "conversation_topic_change" + | "conversation_topic_creation" + | "conversation_topic_deletion" + | "help_center_settings_change" + | "inbound_conversations_change" + | "inbox_access_change" + | "message_deletion" + | "message_state_change" + | "messenger_look_and_feel_change" + | "messenger_search_required_change" + | "messenger_spaces_change" + | "office_hours_change" + | "role_change" + | "role_creation" + | "role_deletion" + | "ruleset_activation_title_preview" + | "ruleset_creation" + | "ruleset_deletion" + | "search_browse_enabled_change" + | "search_browse_required_change" + | "seat_change" + | "seat_revoke" + | "security_settings_change" + | "temporary_expectation_change" + | "upfront_email_collection_change" + | "welcome_message_change"; + export const ActivityType = { + AdminAssignmentLimitChange: "admin_assignment_limit_change", + AdminAwayModeChange: "admin_away_mode_change", + AdminDeletion: "admin_deletion", + AdminDeprovisioned: "admin_deprovisioned", + AdminImpersonationEnd: "admin_impersonation_end", + AdminImpersonationStart: "admin_impersonation_start", + AdminInviteChange: "admin_invite_change", + AdminInviteCreation: "admin_invite_creation", + AdminInviteDeletion: "admin_invite_deletion", + AdminLoginFailure: "admin_login_failure", + AdminLoginSuccess: "admin_login_success", + AdminLogout: "admin_logout", + AdminPasswordResetRequest: "admin_password_reset_request", + AdminPasswordResetSuccess: "admin_password_reset_success", + AdminPermissionChange: "admin_permission_change", + AdminProvisioned: "admin_provisioned", + AdminTwoFactorAuthChange: "admin_two_factor_auth_change", + AdminUnauthorizedSignInMethod: "admin_unauthorized_sign_in_method", + AppAdminJoin: "app_admin_join", + AppAuthenticationMethodChange: "app_authentication_method_change", + AppDataDeletion: "app_data_deletion", + AppDataExport: "app_data_export", + AppGoogleSsoDomainChange: "app_google_sso_domain_change", + AppIdentityVerificationChange: "app_identity_verification_change", + AppNameChange: "app_name_change", + AppOutboundAddressChange: "app_outbound_address_change", + AppPackageInstallation: "app_package_installation", + AppPackageTokenRegeneration: "app_package_token_regeneration", + AppPackageUninstallation: "app_package_uninstallation", + AppTeamCreation: "app_team_creation", + AppTeamDeletion: "app_team_deletion", + AppTeamMembershipModification: "app_team_membership_modification", + AppTimezoneChange: "app_timezone_change", + AppWebhookCreation: "app_webhook_creation", + AppWebhookDeletion: "app_webhook_deletion", + ArticlesInMessengerEnabledChange: "articles_in_messenger_enabled_change", + BulkDelete: "bulk_delete", + BulkExport: "bulk_export", + CampaignDeletion: "campaign_deletion", + CampaignStateChange: "campaign_state_change", + ConversationPartDeletion: "conversation_part_deletion", + ConversationTopicChange: "conversation_topic_change", + ConversationTopicCreation: "conversation_topic_creation", + ConversationTopicDeletion: "conversation_topic_deletion", + HelpCenterSettingsChange: "help_center_settings_change", + InboundConversationsChange: "inbound_conversations_change", + InboxAccessChange: "inbox_access_change", + MessageDeletion: "message_deletion", + MessageStateChange: "message_state_change", + MessengerLookAndFeelChange: "messenger_look_and_feel_change", + MessengerSearchRequiredChange: "messenger_search_required_change", + MessengerSpacesChange: "messenger_spaces_change", + OfficeHoursChange: "office_hours_change", + RoleChange: "role_change", + RoleCreation: "role_creation", + RoleDeletion: "role_deletion", + RulesetActivationTitlePreview: "ruleset_activation_title_preview", + RulesetCreation: "ruleset_creation", + RulesetDeletion: "ruleset_deletion", + SearchBrowseEnabledChange: "search_browse_enabled_change", + SearchBrowseRequiredChange: "search_browse_required_change", + SeatChange: "seat_change", + SeatRevoke: "seat_revoke", + SecuritySettingsChange: "security_settings_change", + TemporaryExpectationChange: "temporary_expectation_change", + UpfrontEmailCollectionChange: "upfront_email_collection_change", + WelcomeMessageChange: "welcome_message_change", + } as const; +} diff --git a/src/api/types/ActivityLogList.ts b/src/api/types/ActivityLogList.ts new file mode 100644 index 00000000..ff4d942a --- /dev/null +++ b/src/api/types/ActivityLogList.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A paginated list of activity logs. + */ +export interface ActivityLogList { + /** String representing the object's type. Always has the value `activity_log.list`. */ + type: "activity_log.list"; + pages?: Intercom.CursorPages; + /** An array of activity logs */ + activity_logs: Intercom.ActivityLog[]; +} diff --git a/src/api/types/ActivityLogMetadata.ts b/src/api/types/ActivityLogMetadata.ts new file mode 100644 index 00000000..4814d8e5 --- /dev/null +++ b/src/api/types/ActivityLogMetadata.ts @@ -0,0 +1,27 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Additional data provided about Admin activity. + */ +export interface ActivityLogMetadata { + /** The way the admin signed in. */ + sign_in_method?: string; + /** The unique identifier for the contact which is provided by the Client. */ + external_id?: string; + /** The away mode status which is set to true when away and false when returned. */ + away_mode?: boolean; + /** The reason the Admin is away. */ + away_status_reason?: string; + /** Indicates if conversations should be reassigned while an Admin is away. */ + reassign_conversations?: boolean; + /** The action that initiated the status change. */ + source?: string; + /** Indicates if the status was changed automatically or manually. */ + auto_changed?: string; + /** The ID of the Admin who initiated the activity. */ + update_by?: number; + /** The name of the Admin who initiated the activity. */ + update_by_name?: string; +} diff --git a/src/api/types/AddressableList.ts b/src/api/types/AddressableList.ts new file mode 100644 index 00000000..9fbf43ad --- /dev/null +++ b/src/api/types/AddressableList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A list used to access other resources from a parent model. + */ +export interface AddressableList { + /** The addressable object type */ + type: string; + /** The id of the addressable object */ + id: string; + /** Url to get more company resources for this contact */ + url: string; +} diff --git a/src/api/types/AdminList.ts b/src/api/types/AdminList.ts new file mode 100644 index 00000000..6c802a88 --- /dev/null +++ b/src/api/types/AdminList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list of admins associated with a given workspace. + */ +export interface AdminList { + /** String representing the object's type. Always has the value `admin.list`. */ + type: "admin.list"; + /** A list of admins associated with a given workspace. */ + admins: Intercom.Admin[]; +} diff --git a/src/api/types/AdminPriorityLevel.ts b/src/api/types/AdminPriorityLevel.ts new file mode 100644 index 00000000..659f95f2 --- /dev/null +++ b/src/api/types/AdminPriorityLevel.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Admin priority levels for the team + */ +export interface AdminPriorityLevel { + /** The primary admin ids for the team */ + primary_admin_ids?: number[]; + /** The secondary admin ids for the team */ + secondary_admin_ids?: number[]; +} diff --git a/src/api/types/AdminReplyConversationRequest.ts b/src/api/types/AdminReplyConversationRequest.ts new file mode 100644 index 00000000..be2e3a21 --- /dev/null +++ b/src/api/types/AdminReplyConversationRequest.ts @@ -0,0 +1,31 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Payload of the request to reply on behalf of an admin + */ +export interface AdminReplyConversationRequest { + message_type: AdminReplyConversationRequest.MessageType; + type: "admin"; + /** The text body of the reply. Notes accept some HTML formatting. Must be present for comment and note message types. */ + body?: string; + /** The id of the admin who is authoring the comment. */ + admin_id: string; + /** The time the reply was created. If not provided, the current time will be used. */ + created_at?: number; + /** A list of image URLs that will be added as attachments. You can include up to 10 URLs. */ + attachment_urls?: string[]; + /** A list of files that will be added as attachments. You can include up to 10 files */ + attachment_files?: Intercom.ConversationAttachmentFiles[]; +} + +export namespace AdminReplyConversationRequest { + export type MessageType = "comment" | "note"; + export const MessageType = { + Comment: "comment", + Note: "note", + } as const; +} diff --git a/src/api/types/AdminReplyTicketRequest.ts b/src/api/types/AdminReplyTicketRequest.ts new file mode 100644 index 00000000..dfc2ae57 --- /dev/null +++ b/src/api/types/AdminReplyTicketRequest.ts @@ -0,0 +1,40 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Payload of the request to reply on behalf of an admin + */ +export interface AdminReplyTicketRequest { + message_type: AdminReplyTicketRequest.MessageType; + type: "admin"; + /** The text body of the reply. Notes accept some HTML formatting. Must be present for comment and note message types. */ + body?: string; + /** The id of the admin who is authoring the comment. */ + admin_id: string; + /** The time the reply was created. If not provided, the current time will be used. */ + created_at?: number; + /** The quick reply options to display. Must be present for quick_reply message types. */ + reply_options?: AdminReplyTicketRequest.ReplyOptions.Item[]; + /** A list of image URLs that will be added as attachments. You can include up to 10 URLs. */ + attachment_urls?: string[]; +} + +export namespace AdminReplyTicketRequest { + export type MessageType = "comment" | "note" | "quick_reply"; + export const MessageType = { + Comment: "comment", + Note: "note", + QuickReply: "quick_reply", + } as const; + export type ReplyOptions = ReplyOptions.Item[]; + + export namespace ReplyOptions { + export interface Item { + /** The text to display in this quick reply option. */ + text: string; + /** A unique identifier for this quick reply option. This value will be available within the metadata of the comment ticket part that is created when a user clicks on this reply option. */ + uuid: string; + } + } +} diff --git a/src/api/types/AdminWithApp.ts b/src/api/types/AdminWithApp.ts new file mode 100644 index 00000000..5f262869 --- /dev/null +++ b/src/api/types/AdminWithApp.ts @@ -0,0 +1,47 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Admins are the teammate accounts that have access to a workspace + */ +export interface AdminWithApp { + /** String representing the object's type. Always has the value `admin`. */ + type: "admin"; + /** The id representing the admin. */ + id: string; + /** The name of the admin. */ + name: string; + /** The email of the admin. */ + email: string; + /** The job title of the admin. */ + job_title: string; + /** Identifies if this admin is currently set in away mode. */ + away_mode_enabled: boolean; + /** Identifies if this admin is set to automatically reassign new conversations to the apps default inbox. */ + away_mode_reassign: boolean; + /** Identifies if this admin has a paid inbox seat to restrict/allow features that require them. */ + has_inbox_seat: boolean; + /** This is a list of ids of the teams that this admin is part of. */ + team_ids: number[]; + /** This object represents the avatar associated with the admin. */ + avatar?: AdminWithApp.Avatar; + /** Identifies if this admin's email is verified. */ + email_verified?: boolean; + /** App that the admin belongs to. */ + app?: Intercom.App; +} + +export namespace AdminWithApp { + /** + * This object represents the avatar associated with the admin. + */ + export interface Avatar { + /** This is a string that identifies the type of the object. It will always have the value `avatar`. */ + type?: "avatar"; + /** This object represents the avatar associated with the admin. */ + image_url?: string; + } +} diff --git a/src/api/types/App.ts b/src/api/types/App.ts new file mode 100644 index 00000000..6506491c --- /dev/null +++ b/src/api/types/App.ts @@ -0,0 +1,23 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * App is a workspace on Intercom + */ +export interface App { + /** */ + type: string; + /** The id of the app. */ + id_code: string; + /** The name of the app. */ + name: string; + /** The Intercom region the app is located in. */ + region: string; + /** The timezone of the region where the app is located. */ + timezone: string; + /** When the app was created. */ + created_at: number; + /** Whether or not the app uses identity verification. */ + identity_verification: boolean; +} diff --git a/src/api/types/ArticleContent.ts b/src/api/types/ArticleContent.ts new file mode 100644 index 00000000..dd73e27e --- /dev/null +++ b/src/api/types/ArticleContent.ts @@ -0,0 +1,38 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The Content of an Article. + */ +export interface ArticleContent { + /** The type of object - `article_content` . */ + type: "article_content"; + /** The title of the article. */ + title: string; + /** The description of the article. */ + description: string; + /** The body of the article. */ + body: string; + /** The ID of the author of the article. */ + author_id: number; + /** Whether the article is `published` or is a `draft` . */ + state: ArticleContent.State; + /** The time when the article was created (seconds). */ + created_at?: number; + /** The time when the article was last updated (seconds). */ + updated_at?: number; + /** The URL of the article. */ + url?: string; +} + +export namespace ArticleContent { + /** + * Whether the article is `published` or is a `draft` . + */ + export type State = "published" | "draft"; + export const State = { + Published: "published", + Draft: "draft", + } as const; +} diff --git a/src/api/types/ArticleList.ts b/src/api/types/ArticleList.ts new file mode 100644 index 00000000..9bb7744b --- /dev/null +++ b/src/api/types/ArticleList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * This will return a list of articles for the App. + */ +export interface ArticleList { + /** The type of the object - `list`. */ + type: "list"; + pages?: Intercom.CursorPages; + /** A count of the total number of articles. */ + total_count: number; + /** An array of Article objects */ + data: Intercom.ArticleListItem[]; +} diff --git a/src/api/types/ArticleStatistics.ts b/src/api/types/ArticleStatistics.ts new file mode 100644 index 00000000..00301798 --- /dev/null +++ b/src/api/types/ArticleStatistics.ts @@ -0,0 +1,23 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The statistics of an article. + */ +export interface ArticleStatistics { + /** The type of object - `article_statistics`. */ + type: "article_statistics"; + /** The number of total views the article has received. */ + views: number; + /** The number of conversations started from the article. */ + conversions: number; + /** The number of total reactions the article has received. */ + reactions: number; + /** The percentage of happy reactions the article has received against other types of reaction. */ + happy_reaction_percentage: number; + /** The percentage of neutral reactions the article has received against other types of reaction. */ + neutral_reaction_percentage: number; + /** The percentage of sad reactions the article has received against other types of reaction. */ + sad_reaction_percentage: number; +} diff --git a/src/api/types/ArticleTranslatedContent.ts b/src/api/types/ArticleTranslatedContent.ts new file mode 100644 index 00000000..48f103b3 --- /dev/null +++ b/src/api/types/ArticleTranslatedContent.ts @@ -0,0 +1,87 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The Translated Content of an Article. The keys are the locale codes and the values are the translated content of the article. + */ +export interface ArticleTranslatedContent { + /** The type of object - article_translated_content. */ + type?: "article_translated_content"; + /** The content of the article in Arabic */ + ar?: Intercom.ArticleContent; + /** The content of the article in Bulgarian */ + bg?: Intercom.ArticleContent; + /** The content of the article in Bosnian */ + bs?: Intercom.ArticleContent; + /** The content of the article in Catalan */ + ca?: Intercom.ArticleContent; + /** The content of the article in Czech */ + cs?: Intercom.ArticleContent; + /** The content of the article in Danish */ + da?: Intercom.ArticleContent; + /** The content of the article in German */ + de?: Intercom.ArticleContent; + /** The content of the article in Greek */ + el?: Intercom.ArticleContent; + /** The content of the article in English */ + en?: Intercom.ArticleContent; + /** The content of the article in Spanish */ + es?: Intercom.ArticleContent; + /** The content of the article in Estonian */ + et?: Intercom.ArticleContent; + /** The content of the article in Finnish */ + fi?: Intercom.ArticleContent; + /** The content of the article in French */ + fr?: Intercom.ArticleContent; + /** The content of the article in Hebrew */ + he?: Intercom.ArticleContent; + /** The content of the article in Croatian */ + hr?: Intercom.ArticleContent; + /** The content of the article in Hungarian */ + hu?: Intercom.ArticleContent; + /** The content of the article in Indonesian */ + id?: Intercom.ArticleContent; + /** The content of the article in Italian */ + it?: Intercom.ArticleContent; + /** The content of the article in Japanese */ + ja?: Intercom.ArticleContent; + /** The content of the article in Korean */ + ko?: Intercom.ArticleContent; + /** The content of the article in Lithuanian */ + lt?: Intercom.ArticleContent; + /** The content of the article in Latvian */ + lv?: Intercom.ArticleContent; + /** The content of the article in Mongolian */ + mn?: Intercom.ArticleContent; + /** The content of the article in Norwegian */ + nb?: Intercom.ArticleContent; + /** The content of the article in Dutch */ + nl?: Intercom.ArticleContent; + /** The content of the article in Polish */ + pl?: Intercom.ArticleContent; + /** The content of the article in Portuguese (Portugal) */ + pt?: Intercom.ArticleContent; + /** The content of the article in Romanian */ + ro?: Intercom.ArticleContent; + /** The content of the article in Russian */ + ru?: Intercom.ArticleContent; + /** The content of the article in Slovenian */ + sl?: Intercom.ArticleContent; + /** The content of the article in Serbian */ + sr?: Intercom.ArticleContent; + /** The content of the article in Swedish */ + sv?: Intercom.ArticleContent; + /** The content of the article in Turkish */ + tr?: Intercom.ArticleContent; + /** The content of the article in Vietnamese */ + vi?: Intercom.ArticleContent; + /** The content of the article in Portuguese (Brazil) */ + "pt-BR"?: Intercom.ArticleContent; + /** The content of the article in Chinese (China) */ + "zh-CN"?: Intercom.ArticleContent; + /** The content of the article in Chinese (Taiwan) */ + "zh-TW"?: Intercom.ArticleContent; +} diff --git a/src/api/types/AssignConversationRequest.ts b/src/api/types/AssignConversationRequest.ts new file mode 100644 index 00000000..e3eef208 --- /dev/null +++ b/src/api/types/AssignConversationRequest.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Payload of the request to assign a conversation + */ +export interface AssignConversationRequest { + type: AssignConversationRequest.Type; + /** The id of the admin who is performing the action. */ + admin_id: string; + /** The `id` of the `admin` or `team` which will be assigned the conversation. A conversation can be assigned both an admin and a team.\nSet `0` if you want this assign to no admin or team (ie. Unassigned). */ + assignee_id: string; + /** Optionally you can send a response in the conversation when it is assigned. */ + body?: string; +} + +export namespace AssignConversationRequest { + export type Type = "admin" | "team"; + export const Type = { + Admin: "admin", + Team: "team", + } as const; +} diff --git a/src/api/types/CloseConversationRequest.ts b/src/api/types/CloseConversationRequest.ts new file mode 100644 index 00000000..56f0755e --- /dev/null +++ b/src/api/types/CloseConversationRequest.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Payload of the request to close a conversation + */ +export interface CloseConversationRequest { + type: "admin"; + /** The id of the admin who is performing the action. */ + admin_id: string; + /** Optionally you can leave a message in the conversation to provide additional context to the user and other teammates. */ + body?: string; +} diff --git a/src/api/types/CollectionList.ts b/src/api/types/CollectionList.ts new file mode 100644 index 00000000..240ee1e5 --- /dev/null +++ b/src/api/types/CollectionList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * This will return a list of Collections for the App. + */ +export interface CollectionList { + /** The type of the object - `list`. */ + type: "list"; + pages?: Intercom.CursorPages; + /** A count of the total number of collections. */ + total_count: number; + /** An array of collection objects */ + data: Intercom.Collection[]; +} diff --git a/src/api/types/CompanyAttachedContacts.ts b/src/api/types/CompanyAttachedContacts.ts new file mode 100644 index 00000000..a07697e9 --- /dev/null +++ b/src/api/types/CompanyAttachedContacts.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list of Contact Objects + */ +export interface CompanyAttachedContacts { + /** The type of object - `list` */ + type: "list"; + /** An array containing Contact Objects */ + data: Intercom.Contact[]; + /** The total number of contacts */ + total_count: number; + pages?: Intercom.CursorPages; +} diff --git a/src/api/types/CompanyAttachedSegments.ts b/src/api/types/CompanyAttachedSegments.ts new file mode 100644 index 00000000..12c36438 --- /dev/null +++ b/src/api/types/CompanyAttachedSegments.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list of Segment Objects + */ +export interface CompanyAttachedSegments { + /** The type of object - `list` */ + type: "list"; + /** An array containing Segment Objects */ + data: Intercom.Segment[]; +} diff --git a/src/api/types/CompanyList.ts b/src/api/types/CompanyList.ts new file mode 100644 index 00000000..90a0ff32 --- /dev/null +++ b/src/api/types/CompanyList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * This will return a list of companies for the App. + */ +export interface CompanyList { + /** The type of object - `list`. */ + type: "list"; + pages?: Intercom.CursorPages; + /** The total number of companies. */ + total_count: number; + /** An array containing Company Objects. */ + data: Intercom.Company[]; +} diff --git a/src/api/types/CompanyScroll.ts b/src/api/types/CompanyScroll.ts new file mode 100644 index 00000000..dd606955 --- /dev/null +++ b/src/api/types/CompanyScroll.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Companies allow you to represent organizations using your product. Each company will have its own description and be associated with contacts. You can fetch, create, update and list companies. + */ +export interface CompanyScroll { + /** The type of object - `list` */ + type: "list"; + data: Intercom.Company[]; + pages?: Intercom.CursorPages; + /** The total number of companies */ + total_count?: number; + /** The scroll parameter to use in the next request to fetch the next page of results. */ + scroll_param?: string; +} diff --git a/src/api/types/ContactArchived.ts b/src/api/types/ContactArchived.ts new file mode 100644 index 00000000..882c4bec --- /dev/null +++ b/src/api/types/ContactArchived.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * archived contact object + */ +export interface ContactArchived { + /** always contact */ + type: "contact"; + /** The unique identifier for the contact which is given by Intercom. */ + id: string; + /** The unique identifier for the contact which is provided by the Client. */ + external_id?: string; + /** Whether the contact is archived or not. */ + archived: boolean; +} diff --git a/src/api/types/ContactAttachedCompanies.ts b/src/api/types/ContactAttachedCompanies.ts new file mode 100644 index 00000000..3c73d361 --- /dev/null +++ b/src/api/types/ContactAttachedCompanies.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list of Company Objects + */ +export interface ContactAttachedCompanies { + /** The type of object */ + type: "list"; + /** An array containing Company Objects */ + companies: Intercom.Company[]; + /** The total number of companies associated to this contact */ + total_count: number; + pages?: Intercom.PagesLink; +} diff --git a/src/api/types/ContactCompanies.ts b/src/api/types/ContactCompanies.ts new file mode 100644 index 00000000..c452e42e --- /dev/null +++ b/src/api/types/ContactCompanies.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * An object containing companies meta data about the companies that a contact has. Up to 10 will be displayed here. Use the url to get more. + */ +export interface ContactCompanies { + /** Url to get more company resources for this contact */ + url: string; + /** Int representing the total number of companyies attached to this contact */ + total_count: number; + /** Whether there's more Addressable Objects to be viewed. If true, use the url to view all */ + has_more: boolean; +} diff --git a/src/api/types/ContactDeleted.ts b/src/api/types/ContactDeleted.ts new file mode 100644 index 00000000..12d7b0c6 --- /dev/null +++ b/src/api/types/ContactDeleted.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * deleted contact object + */ +export interface ContactDeleted { + /** always contact */ + type: "contact"; + /** The unique identifier for the contact which is given by Intercom. */ + id: string; + /** The unique identifier for the contact which is provided by the Client. */ + external_id?: string; + /** Whether the contact is deleted or not. */ + deleted: boolean; +} diff --git a/src/api/types/ContactList.ts b/src/api/types/ContactList.ts new file mode 100644 index 00000000..fd188c1a --- /dev/null +++ b/src/api/types/ContactList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Contacts are your users in Intercom. + */ +export interface ContactList { + /** Always list */ + type: "list"; + /** The list of contact objects */ + data: Intercom.Contact[]; + /** A count of the total number of objects. */ + total_count: number; + pages?: Intercom.CursorPages; +} diff --git a/src/api/types/ContactLocation.ts b/src/api/types/ContactLocation.ts new file mode 100644 index 00000000..2e079a7c --- /dev/null +++ b/src/api/types/ContactLocation.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * An object containing location meta data about a Intercom contact. + */ +export interface ContactLocation { + /** Always location */ + type: "location"; + /** The country that the contact is located in */ + country?: string; + /** The overal region that the contact is located in */ + region?: string; + /** The city that the contact is located in */ + city?: string; +} diff --git a/src/api/types/ContactNotes.ts b/src/api/types/ContactNotes.ts new file mode 100644 index 00000000..56f4b090 --- /dev/null +++ b/src/api/types/ContactNotes.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * An object containing notes meta data about the notes that a contact has. Up to 10 will be displayed here. Use the url to get more. + */ +export interface ContactNotes { + /** This object represents the notes attached to a contact. */ + data: Intercom.AddressableList[]; + /** Url to get more company resources for this contact */ + url: string; + /** Int representing the total number of companyies attached to this contact */ + total_count: number; + /** Whether there's more Addressable Objects to be viewed. If true, use the url to view all */ + has_more: boolean; +} diff --git a/src/api/types/ContactReference.ts b/src/api/types/ContactReference.ts new file mode 100644 index 00000000..06dcf74e --- /dev/null +++ b/src/api/types/ContactReference.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * reference to contact object + */ +export interface ContactReference { + /** always contact */ + type: "contact"; + /** The unique identifier for the contact which is given by Intercom. */ + id: string; + /** The unique identifier for the contact which is provided by the Client. */ + external_id?: string; +} diff --git a/src/api/types/ContactReplyBaseRequest.ts b/src/api/types/ContactReplyBaseRequest.ts new file mode 100644 index 00000000..74f679c9 --- /dev/null +++ b/src/api/types/ContactReplyBaseRequest.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface ContactReplyBaseRequest { + message_type: "comment"; + type: "user"; + /** The text body of the comment. */ + body: string; + /** The time the reply was created. If not provided, the current time will be used. */ + created_at?: number; + /** A list of image URLs that will be added as attachments. You can include up to 10 URLs. */ + attachment_urls?: string[]; +} diff --git a/src/api/types/ContactReplyConversationRequest.ts b/src/api/types/ContactReplyConversationRequest.ts new file mode 100644 index 00000000..90c1aa5b --- /dev/null +++ b/src/api/types/ContactReplyConversationRequest.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +export type ContactReplyConversationRequest = + | Intercom.ContactReplyIntercomUserIdRequest + | Intercom.ContactReplyEmailRequest + | Intercom.ContactReplyUserIdRequest; diff --git a/src/api/types/ContactReplyEmailRequest.ts b/src/api/types/ContactReplyEmailRequest.ts new file mode 100644 index 00000000..3f6b266b --- /dev/null +++ b/src/api/types/ContactReplyEmailRequest.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Payload of the request to reply on behalf of a contact using their `email` + */ +export interface ContactReplyEmailRequest extends Intercom.ContactReplyBaseRequest { + /** The email you have defined for the user. */ + email: string; + /** A list of files that will be added as attachments. */ + attachment_files?: Intercom.ConversationAttachmentFiles[]; +} diff --git a/src/api/types/ContactReplyIntercomUserIdRequest.ts b/src/api/types/ContactReplyIntercomUserIdRequest.ts new file mode 100644 index 00000000..7de99551 --- /dev/null +++ b/src/api/types/ContactReplyIntercomUserIdRequest.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Payload of the request to reply on behalf of a contact using their `intercom_user_id` + */ +export interface ContactReplyIntercomUserIdRequest extends Intercom.ContactReplyBaseRequest { + /** The identifier for the contact as given by Intercom. */ + intercom_user_id: string; + /** A list of files that will be added as attachments. */ + attachment_files?: Intercom.ConversationAttachmentFiles[]; +} diff --git a/src/api/types/ContactReplyTicketEmailRequest.ts b/src/api/types/ContactReplyTicketEmailRequest.ts new file mode 100644 index 00000000..f1c5da4d --- /dev/null +++ b/src/api/types/ContactReplyTicketEmailRequest.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Payload of the request to reply on behalf of a contact using their `email` + */ +export interface ContactReplyTicketEmailRequest extends Intercom.ContactReplyBaseRequest { + /** The email you have defined for the user. */ + email: string; +} diff --git a/src/api/types/ContactReplyTicketIntercomUserIdRequest.ts b/src/api/types/ContactReplyTicketIntercomUserIdRequest.ts new file mode 100644 index 00000000..fb39fc05 --- /dev/null +++ b/src/api/types/ContactReplyTicketIntercomUserIdRequest.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Payload of the request to reply on behalf of a contact using their `intercom_user_id` + */ +export interface ContactReplyTicketIntercomUserIdRequest extends Intercom.ContactReplyBaseRequest { + /** The identifier for the contact as given by Intercom. */ + intercom_user_id: string; +} diff --git a/src/api/types/ContactReplyTicketRequest.ts b/src/api/types/ContactReplyTicketRequest.ts new file mode 100644 index 00000000..a285ecec --- /dev/null +++ b/src/api/types/ContactReplyTicketRequest.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +export type ContactReplyTicketRequest = + | Intercom.ContactReplyTicketIntercomUserIdRequest + | Intercom.ContactReplyTicketUserIdRequest + | Intercom.ContactReplyTicketEmailRequest; diff --git a/src/api/types/ContactReplyTicketUserIdRequest.ts b/src/api/types/ContactReplyTicketUserIdRequest.ts new file mode 100644 index 00000000..475a259d --- /dev/null +++ b/src/api/types/ContactReplyTicketUserIdRequest.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Payload of the request to reply on behalf of a contact using their `user_id` + */ +export interface ContactReplyTicketUserIdRequest extends Intercom.ContactReplyBaseRequest { + /** The external_id you have defined for the contact. */ + user_id: string; +} diff --git a/src/api/types/ContactReplyUserIdRequest.ts b/src/api/types/ContactReplyUserIdRequest.ts new file mode 100644 index 00000000..919a6e28 --- /dev/null +++ b/src/api/types/ContactReplyUserIdRequest.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Payload of the request to reply on behalf of a contact using their `user_id` + */ +export interface ContactReplyUserIdRequest extends Intercom.ContactReplyBaseRequest { + /** The external_id you have defined for the contact. */ + user_id: string; + /** A list of files that will be added as attachments. You can include up to 10 files. */ + attachment_files?: Intercom.ConversationAttachmentFiles[]; +} diff --git a/src/api/types/ContactSegments.ts b/src/api/types/ContactSegments.ts new file mode 100644 index 00000000..cb9bc850 --- /dev/null +++ b/src/api/types/ContactSegments.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list of segments objects attached to a specific contact. + */ +export interface ContactSegments { + /** The type of the object */ + type: "list"; + /** Segment objects associated with the contact. */ + data: Intercom.Segment[]; +} diff --git a/src/api/types/ContactSocialProfiles.ts b/src/api/types/ContactSocialProfiles.ts new file mode 100644 index 00000000..baf40a04 --- /dev/null +++ b/src/api/types/ContactSocialProfiles.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * An object containing social profiles that a contact has. + */ +export interface ContactSocialProfiles { + /** A list of social profiles objects associated with the contact. */ + data: Intercom.SocialProfile[]; +} diff --git a/src/api/types/ContactSubscriptionTypes.ts b/src/api/types/ContactSubscriptionTypes.ts new file mode 100644 index 00000000..ff8cd650 --- /dev/null +++ b/src/api/types/ContactSubscriptionTypes.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * An object containing Subscription Types meta data about the SubscriptionTypes that a contact has. + */ +export interface ContactSubscriptionTypes { + /** This object represents the subscriptions attached to a contact. */ + data: Intercom.AddressableList[]; + /** Url to get more subscription type resources for this contact */ + url: string; + /** Int representing the total number of subscription types attached to this contact */ + total_count: number; + /** Whether there's more Addressable Objects to be viewed. If true, use the url to view all */ + has_more: boolean; +} diff --git a/src/api/types/ContactTags.ts b/src/api/types/ContactTags.ts new file mode 100644 index 00000000..6ed9fd6d --- /dev/null +++ b/src/api/types/ContactTags.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * An object containing tags meta data about the tags that a contact has. Up to 10 will be displayed here. Use the url to get more. + */ +export interface ContactTags { + /** This object represents the tags attached to a contact. */ + data: Intercom.AddressableList[]; + /** url to get more tag resources for this contact */ + url: string; + /** Int representing the total number of tags attached to this contact */ + total_count: number; + /** Whether there's more Addressable Objects to be viewed. If true, use the url to view all */ + has_more: boolean; +} diff --git a/src/api/types/ContactUnarchived.ts b/src/api/types/ContactUnarchived.ts new file mode 100644 index 00000000..7940f0f1 --- /dev/null +++ b/src/api/types/ContactUnarchived.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * unarchived contact object + */ +export interface ContactUnarchived { + /** always contact */ + type: "contact"; + /** The unique identifier for the contact which is given by Intercom. */ + id: string; + /** The unique identifier for the contact which is provided by the Client. */ + external_id?: string; + /** Whether the contact is archived or not. */ + archived: boolean; +} diff --git a/src/api/types/ContentSourcesList.ts b/src/api/types/ContentSourcesList.ts new file mode 100644 index 00000000..28044b85 --- /dev/null +++ b/src/api/types/ContentSourcesList.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +export interface ContentSourcesList { + type: "content_source.list"; + /** The total number of content sources used by AI Agent in the conversation. */ + total_count: number; + /** The content sources used by AI Agent in the conversation. */ + content_sources: Intercom.ContentSource[]; +} diff --git a/src/api/types/ConversationAttachmentFiles.ts b/src/api/types/ConversationAttachmentFiles.ts new file mode 100644 index 00000000..df8323f1 --- /dev/null +++ b/src/api/types/ConversationAttachmentFiles.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Properties of the attachment files in a conversation part + */ +export interface ConversationAttachmentFiles { + /** The content type of the file */ + content_type: string; + /** The base64 encoded file data. */ + data: string; + /** The name of the file. */ + name: string; +} diff --git a/src/api/types/ConversationContacts.ts b/src/api/types/ConversationContacts.ts new file mode 100644 index 00000000..c76e082d --- /dev/null +++ b/src/api/types/ConversationContacts.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The list of contacts (users or leads) involved in this conversation. This will only contain one customer unless more were added via the group conversation feature. + */ +export interface ConversationContacts { + type: "contact.list"; + /** The list of contacts (users or leads) involved in this conversation. This will only contain one customer unless more were added via the group conversation feature. */ + contacts: Intercom.ContactReference[]; +} diff --git a/src/api/types/ConversationFirstContactReply.ts b/src/api/types/ConversationFirstContactReply.ts new file mode 100644 index 00000000..efef9c6a --- /dev/null +++ b/src/api/types/ConversationFirstContactReply.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * An object containing information on the first users message. For a contact initiated message this will represent the users original message. + */ +export interface ConversationFirstContactReply { + /** */ + created_at: number; + /** */ + type: string; + /** */ + url?: string; +} diff --git a/src/api/types/ConversationPart.ts b/src/api/types/ConversationPart.ts new file mode 100644 index 00000000..51fcf06a --- /dev/null +++ b/src/api/types/ConversationPart.ts @@ -0,0 +1,34 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A Conversation Part represents a message in the conversation. + */ +export interface ConversationPart { + /** Always conversation_part */ + type: "conversation_part"; + /** The id representing the conversation part. */ + id: string; + /** The type of conversation part. */ + part_type: string; + /** The message body, which may contain HTML. For Twitter, this will show a generic message regarding why the body is obscured. */ + body?: string; + /** The time the conversation part was created. */ + created_at: number; + /** The last time the conversation part was updated. */ + updated_at?: number; + /** The time the user was notified with the conversation part. */ + notified_at: number; + /** The id of the admin that was assigned the conversation by this conversation_part (null if there has been no change in assignment.) */ + assigned_to?: Intercom.Reference; + author: Intercom.ConversationPartAuthor; + /** A list of attachments for the part. */ + attachments?: Intercom.PartAttachment[]; + /** The external id of the conversation part */ + external_id?: string; + /** Whether or not the conversation part has been redacted. */ + redacted: boolean; +} diff --git a/src/api/types/ConversationPartAuthor.ts b/src/api/types/ConversationPartAuthor.ts new file mode 100644 index 00000000..36495f34 --- /dev/null +++ b/src/api/types/ConversationPartAuthor.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The object who initiated the conversation, which can be a Contact, Admin or Team. Bots and campaigns send messages on behalf of Admins or Teams. For Twitter, this will be blank. + */ +export interface ConversationPartAuthor { + /** The type of the author */ + type: string; + /** The id of the author */ + id: string; + /** The name of the author */ + name: string; + /** The email of the author */ + email: string; +} diff --git a/src/api/types/ConversationParts.ts b/src/api/types/ConversationParts.ts new file mode 100644 index 00000000..2d0114df --- /dev/null +++ b/src/api/types/ConversationParts.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list of Conversation Part objects for each part message in the conversation. This is only returned when Retrieving a Conversation, and ignored when Listing all Conversations. There is a limit of 500 parts. + */ +export interface ConversationParts { + /** */ + type: "conversation_part.list"; + /** A list of Conversation Part objects for each part message in the conversation. This is only returned when Retrieving a Conversation, and ignored when Listing all Conversations. There is a limit of 500 parts. */ + conversation_parts: Intercom.ConversationPart[]; + /** */ + total_count: number; +} diff --git a/src/api/types/ConversationRating.ts b/src/api/types/ConversationRating.ts new file mode 100644 index 00000000..96209e62 --- /dev/null +++ b/src/api/types/ConversationRating.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The Conversation Rating object which contains information on the rating and/or remark added by a Contact and the Admin assigned to the conversation. + */ +export interface ConversationRating { + /** The rating, between 1 and 5, for the conversation. */ + rating: number; + /** An optional field to add a remark to correspond to the number rating */ + remark: string; + /** The time the rating was requested in the conversation being rated. */ + created_at: number; + contact: Intercom.ContactReference; + teammate: Intercom.Reference; +} diff --git a/src/api/types/ConversationSource.ts b/src/api/types/ConversationSource.ts new file mode 100644 index 00000000..1b1e352d --- /dev/null +++ b/src/api/types/ConversationSource.ts @@ -0,0 +1,28 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The Conversation Part that originated this conversation, which can be Contact, Admin, Campaign, Automated or Operator initiated. + */ +export interface ConversationSource { + /** This includes conversation, email, facebook, instagram, phone_call, phone_switch, push, sms, twitter and whatsapp. */ + type: string; + /** The id representing the message. */ + id: string; + /** The conversation's initiation type. Possible values are customer_initiated, campaigns_initiated (legacy campaigns), operator_initiated (Custom bot), automated (Series and other outbounds with dynamic audience message) and admin_initiated (fixed audience message, ticket initiated by an admin, group email). */ + delivered_as: string; + /** Optional. The message subject. For Twitter, this will show a generic message regarding why the subject is obscured. */ + subject: string; + /** The message body, which may contain HTML. For Twitter, this will show a generic message regarding why the body is obscured. */ + body?: string; + author: Intercom.ConversationPartAuthor; + /** A list of attachments for the part. */ + attachments?: Intercom.PartAttachment[]; + /** The URL where the conversation was started. For Twitter, Email, and Bots, this will be blank. */ + url?: string; + /** Whether or not the source message has been redacted. Only applicable for contact initiated messages. */ + redacted: boolean; +} diff --git a/src/api/types/ConversationStatistics.ts b/src/api/types/ConversationStatistics.ts new file mode 100644 index 00000000..18444e0d --- /dev/null +++ b/src/api/types/ConversationStatistics.ts @@ -0,0 +1,47 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A Statistics object containing all information required for reporting, with timestamps and calculated metrics. + */ +export interface ConversationStatistics { + /** */ + type: "conversation_statistics"; + /** Duration until last assignment before first admin reply. In seconds. */ + time_to_assignment?: number; + /** Duration until first admin reply. Subtracts out of business hours. In seconds. */ + time_to_admin_reply?: number; + /** Duration until conversation was closed first time. Subtracts out of business hours. In seconds. */ + time_to_first_close?: number; + /** Duration until conversation was closed last time. Subtracts out of business hours. In seconds. */ + time_to_last_close?: number; + /** Median based on all admin replies after a contact reply. Subtracts out of business hours. In seconds. */ + median_time_to_reply?: number; + /** Time of first text conversation part from a contact. */ + first_contact_reply_at?: number; + /** Time of first assignment after first_contact_reply_at. */ + first_assignment_at?: number; + /** Time of first admin reply after first_contact_reply_at. */ + first_admin_reply_at?: number; + /** Time of first close after first_contact_reply_at. */ + first_close_at?: number; + /** Time of last assignment after first_contact_reply_at. */ + last_assignment_at?: number; + /** Time of first admin reply since most recent assignment. */ + last_assignment_admin_reply_at?: number; + /** Time of the last conversation part from a contact. */ + last_contact_reply_at?: number; + /** Time of the last conversation part from an admin. */ + last_admin_reply_at?: number; + /** Time of the last conversation close. */ + last_close_at?: number; + /** The last admin who closed the conversation. Returns a reference to an Admin object. */ + last_closed_by_id?: string; + /** Number of reopens after first_contact_reply_at. */ + count_reopens?: number; + /** Number of assignments after first_contact_reply_at. */ + count_assignments?: number; + /** Total number of conversation parts. */ + count_conversation_parts?: number; +} diff --git a/src/api/types/ConversationTeammates.ts b/src/api/types/ConversationTeammates.ts new file mode 100644 index 00000000..6094d5c5 --- /dev/null +++ b/src/api/types/ConversationTeammates.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The list of teammates who participated in the conversation (wrote at least one conversation part). + */ +export interface ConversationTeammates { + /** The type of the object - `admin.list`. */ + type: string; + /** The list of teammates who participated in the conversation (wrote at least one conversation part). */ + teammates: Intercom.Reference[]; +} diff --git a/src/api/types/CreateContactRequest.ts b/src/api/types/CreateContactRequest.ts new file mode 100644 index 00000000..9af417df --- /dev/null +++ b/src/api/types/CreateContactRequest.ts @@ -0,0 +1,41 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Payload to create a contact + */ +export type CreateContactRequest = + | { + email: string; + phone?: string | undefined; + name?: string | undefined; + avatar?: string | undefined; + signed_up_at?: number | undefined; + last_seen_at?: number | undefined; + owner_id?: number | undefined; + unsubscribed_from_emails?: boolean | undefined; + custom_attributes?: Record | undefined; + } + | { + external_id: string; + phone?: string | undefined; + name?: string | undefined; + avatar?: string | undefined; + signed_up_at?: number | undefined; + last_seen_at?: number | undefined; + owner_id?: number | undefined; + unsubscribed_from_emails?: boolean | undefined; + custom_attributes?: Record | undefined; + } + | { + role: string; + phone?: string | undefined; + name?: string | undefined; + avatar?: string | undefined; + signed_up_at?: number | undefined; + last_seen_at?: number | undefined; + owner_id?: number | undefined; + unsubscribed_from_emails?: boolean | undefined; + custom_attributes?: Record | undefined; + }; diff --git a/src/api/types/CreateDataEventRequest.ts b/src/api/types/CreateDataEventRequest.ts new file mode 100644 index 00000000..85a0c1c5 --- /dev/null +++ b/src/api/types/CreateDataEventRequest.ts @@ -0,0 +1,26 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * + */ +export type CreateDataEventRequest = + | { + id: string; + event_name: string; + created_at: number; + metadata?: Record | undefined; + } + | { + user_id: string; + event_name: string; + created_at: number; + metadata?: Record | undefined; + } + | { + email: string; + event_name: string; + created_at: number; + metadata?: Record | undefined; + }; diff --git a/src/api/types/CreateMessageRequest.ts b/src/api/types/CreateMessageRequest.ts new file mode 100644 index 00000000..9434ec98 --- /dev/null +++ b/src/api/types/CreateMessageRequest.ts @@ -0,0 +1,114 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * You can create a message + */ +export type CreateMessageRequest = Intercom.CreateMessageRequest.Email | Intercom.CreateMessageRequest.Inapp; + +export namespace CreateMessageRequest { + export interface Email { + message_type: "email"; + /** The title of the email. */ + subject: string; + /** The content of the message. HTML and plaintext are supported. */ + body: string; + /** The style of the outgoing message. Possible values `plain` or `personal`. */ + template: string; + /** The sender of the message. If not provided, the default sender will be used. */ + from: CreateMessageRequestWithEmail.From; + /** The sender of the message. If not provided, the default sender will be used. */ + to: CreateMessageRequestWithEmail.To; + /** The time the message was created. If not provided, the current time will be used. */ + created_at?: number; + /** Whether a conversation should be opened in the inbox for the message without the contact replying. Defaults to false if not provided. */ + create_conversation_without_contact_reply?: boolean; + } + + export namespace CreateMessageRequestWithEmail { + /** + * The sender of the message. If not provided, the default sender will be used. + */ + export interface From { + /** Always `admin`. */ + type: "admin"; + /** The identifier for the admin which is given by Intercom. */ + id: number; + } + + /** + * The sender of the message. If not provided, the default sender will be used. + */ + export interface To { + /** The role associated to the contact - `user` or `lead`. */ + type: To.Type; + /** The identifier for the contact which is given by Intercom. */ + id: string; + } + + export namespace To { + /** + * The role associated to the contact - `user` or `lead`. + */ + export type Type = "user" | "lead"; + export const Type = { + User: "user", + Lead: "lead", + } as const; + } + } + + export interface Inapp { + message_type: "inapp"; + /** The title of the email. */ + subject?: string; + /** The content of the message. HTML and plaintext are supported. */ + body: string; + /** The style of the outgoing message. Possible values `plain` or `personal`. */ + template?: string; + /** The sender of the message. If not provided, the default sender will be used. */ + from: CreateMessageRequestWithInapp.From; + /** The sender of the message. If not provided, the default sender will be used. */ + to: CreateMessageRequestWithInapp.To; + /** The time the message was created. If not provided, the current time will be used. */ + created_at?: number; + /** Whether a conversation should be opened in the inbox for the message without the contact replying. Defaults to false if not provided. */ + create_conversation_without_contact_reply?: boolean; + } + + export namespace CreateMessageRequestWithInapp { + /** + * The sender of the message. If not provided, the default sender will be used. + */ + export interface From { + /** Always `admin`. */ + type: "admin"; + /** The identifier for the admin which is given by Intercom. */ + id: number; + } + + /** + * The sender of the message. If not provided, the default sender will be used. + */ + export interface To { + /** The role associated to the contact - `user` or `lead`. */ + type: To.Type; + /** The identifier for the contact which is given by Intercom. */ + id: string; + } + + export namespace To { + /** + * The role associated to the contact - `user` or `lead`. + */ + export type Type = "user" | "lead"; + export const Type = { + User: "user", + Lead: "lead", + } as const; + } + } +} diff --git a/src/api/types/CreateOrUpdateTagRequest.ts b/src/api/types/CreateOrUpdateTagRequest.ts new file mode 100644 index 00000000..a79ff2e0 --- /dev/null +++ b/src/api/types/CreateOrUpdateTagRequest.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * You can create or update an existing tag. + */ +export interface CreateOrUpdateTagRequest { + /** The name of the tag, which will be created if not found, or the new name for the tag if this is an update request. Names are case insensitive. */ + name: string; + /** The id of tag to updates. */ + id?: string; +} diff --git a/src/api/types/CreateTicketReplyWithCommentRequest.ts b/src/api/types/CreateTicketReplyWithCommentRequest.ts new file mode 100644 index 00000000..ad63ed81 --- /dev/null +++ b/src/api/types/CreateTicketReplyWithCommentRequest.ts @@ -0,0 +1,7 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +export type CreateTicketReplyWithCommentRequest = Intercom.ContactReplyTicketRequest | Intercom.AdminReplyTicketRequest; diff --git a/src/api/types/CursorPages.ts b/src/api/types/CursorPages.ts new file mode 100644 index 00000000..db27af6a --- /dev/null +++ b/src/api/types/CursorPages.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Cursor-based pagination is a technique used in the Intercom API to navigate through large amounts of data. + * A "cursor" or pointer is used to keep track of the current position in the result set, allowing the API to return the data in small chunks or "pages" as needed. + */ +export interface CursorPages { + /** the type of object `pages`. */ + type: "pages"; + /** The current page */ + page?: number; + next?: Intercom.StartingAfterPaging; + /** Number of results per page */ + per_page?: number; + /** Total number of pages */ + total_pages?: number; +} diff --git a/src/api/types/CustomAttributes.ts b/src/api/types/CustomAttributes.ts new file mode 100644 index 00000000..39701626 --- /dev/null +++ b/src/api/types/CustomAttributes.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * An object containing the different custom attributes associated to the conversation as key-value pairs. For relationship attributes the value will be a list of custom object instance models. + */ +export type CustomAttributes = Record; + +export namespace CustomAttributes { + export type Value = string | Intercom.CustomObjectInstance; +} diff --git a/src/api/types/CustomerRequest.ts b/src/api/types/CustomerRequest.ts new file mode 100644 index 00000000..6ede7a3d --- /dev/null +++ b/src/api/types/CustomerRequest.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type CustomerRequest = + | { + intercom_user_id: string; + } + | { + user_id: string; + } + | { + email: string; + }; diff --git a/src/api/types/DataAttributeList.ts b/src/api/types/DataAttributeList.ts new file mode 100644 index 00000000..860b9192 --- /dev/null +++ b/src/api/types/DataAttributeList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list of all data attributes belonging to a workspace for contacts, companies or conversations. + */ +export interface DataAttributeList { + /** The type of the object */ + type: "list"; + /** A list of data attributes */ + data: Intercom.DataAttribute[]; +} diff --git a/src/api/types/DataEventList.ts b/src/api/types/DataEventList.ts new file mode 100644 index 00000000..90c73811 --- /dev/null +++ b/src/api/types/DataEventList.ts @@ -0,0 +1,27 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * This will return a list of data events for the App. + */ +export interface DataEventList { + /** The type of the object */ + type: "event.list"; + /** A list of data events */ + events: Intercom.DataEvent[]; + /** Pagination */ + pages?: DataEventList.Pages; +} + +export namespace DataEventList { + /** + * Pagination + */ + export interface Pages { + next?: string; + since?: string; + } +} diff --git a/src/api/types/DataEventSummary.ts b/src/api/types/DataEventSummary.ts new file mode 100644 index 00000000..df7d10fd --- /dev/null +++ b/src/api/types/DataEventSummary.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * This will return a summary of data events for the App. + */ +export interface DataEventSummary { + /** The type of the object */ + type: "event.summary"; + /** The email address of the user */ + email: string; + /** The Intercom user ID of the user */ + intercom_user_id: string; + /** The user ID of the user */ + user_id: string; + /** A summary of data events */ + events: Intercom.DataEventSummaryItem[]; +} diff --git a/src/api/types/DataEventSummaryItem.ts b/src/api/types/DataEventSummaryItem.ts new file mode 100644 index 00000000..ec12ab27 --- /dev/null +++ b/src/api/types/DataEventSummaryItem.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * This will return a summary of a data event for the App. + */ +export interface DataEventSummaryItem { + /** The name of the event */ + name: string; + /** The first time the event was sent */ + first: string; + /** The last time the event was sent */ + last: string; + /** The number of times the event was sent */ + count: number; + /** The description of the event */ + description: string; +} diff --git a/src/api/types/DataExportCsv.ts b/src/api/types/DataExportCsv.ts new file mode 100644 index 00000000..22f1bf3c --- /dev/null +++ b/src/api/types/DataExportCsv.ts @@ -0,0 +1,61 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A CSV output file + */ +export interface DataExportCsv { + /** The user_id of the user who was sent the message. */ + user_id: string; + /** The external_user_id of the user who was sent the message */ + user_external_id?: string; + /** The company ID of the user in relation to the message that was sent. Will return -1 if no company is present. */ + company_id: string; + /** The users email who was sent the message. */ + email: string; + /** The full name of the user receiving the message */ + name: string; + /** The id of the message. */ + ruleset_id: string; + /** The specific content that was received. In an A/B test each version has its own Content ID. */ + content_id: string; + /** Email, Chat, Post etc. */ + content_type: string; + /** The title of the content you see in your Intercom workspace. */ + content_title: string; + /** As you edit content we record new versions. This ID can help you determine which version of a piece of content that was received. */ + ruleset_version_id?: string; + /** ID for this receipt. Will be included with any related stats in other files to identify this specific delivery of a message. */ + receipt_id?: string; + /** Timestamp for when the receipt was recorded. */ + received_at?: number; + /** The id of the series that this content is part of. Will return -1 if not part of a series. */ + series_id?: string; + /** The title of the series that this content is part of. */ + series_title?: string; + /** The id of the series node that this ruleset is associated with. Each block in a series has a corresponding node_id. */ + node_id?: string; + /** The first time a user replied to this message if the content was able to receive replies. */ + first_reply?: number; + /** The first time a user completed this message if the content was able to be completed e.g. Tours, Surveys. */ + first_completion?: number; + /** The first time the series this message was a part of was completed by the user. */ + first_series_completion?: number; + /** The first time the series this message was a part of was disengaged by the user. */ + first_series_disengagement?: number; + /** The first time the series this message was a part of was exited by the user. */ + first_series_exit?: number; + /** The first time the user met this messages associated goal if one exists. */ + first_goal_success?: number; + /** The first time the user opened this message. */ + first_open?: number; + /** The first time the series the user clicked on a link within this message. */ + first_click?: number; + /** The first time the series the user dismissed this message. */ + first_dismisall?: number; + /** The first time the user unsubscribed from this message. */ + first_unsubscribe?: number; + /** The first time this message hard bounced for this user */ + first_hard_bounce?: number; +} diff --git a/src/api/types/DeletedArticleObject.ts b/src/api/types/DeletedArticleObject.ts new file mode 100644 index 00000000..b792af78 --- /dev/null +++ b/src/api/types/DeletedArticleObject.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Response returned when an object is deleted + */ +export interface DeletedArticleObject { + /** The unique identifier for the article which you provided in the URL. */ + id: string; + /** The type of object which was deleted. - article */ + object: "article"; + /** Whether the article was deleted successfully or not. */ + deleted: boolean; +} diff --git a/src/api/types/DeletedCollectionObject.ts b/src/api/types/DeletedCollectionObject.ts new file mode 100644 index 00000000..f01ce8e6 --- /dev/null +++ b/src/api/types/DeletedCollectionObject.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Response returned when an object is deleted + */ +export interface DeletedCollectionObject { + /** The unique identifier for the collection which you provided in the URL. */ + id: string; + /** The type of object which was deleted. - `collection` */ + object: "collection"; + /** Whether the collection was deleted successfully or not. */ + deleted: boolean; +} diff --git a/src/api/types/DeletedCompanyObject.ts b/src/api/types/DeletedCompanyObject.ts new file mode 100644 index 00000000..e3252c3c --- /dev/null +++ b/src/api/types/DeletedCompanyObject.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Response returned when an object is deleted + */ +export interface DeletedCompanyObject { + /** The unique identifier for the company which is given by Intercom. */ + id: string; + /** The type of object which was deleted. - `company` */ + object: "company"; + /** Whether the company was deleted successfully or not. */ + deleted: boolean; +} diff --git a/src/api/types/DeletedObject.ts b/src/api/types/DeletedObject.ts new file mode 100644 index 00000000..f0bcc357 --- /dev/null +++ b/src/api/types/DeletedObject.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Response returned when an object is deleted + */ +export interface DeletedObject { + /** The unique identifier for the news item which you provided in the URL. */ + id: string; + /** The type of object which was deleted - news-item. */ + object: "news-item"; + /** Whether the news item was deleted successfully or not. */ + deleted: boolean; +} diff --git a/src/api/types/Error_.ts b/src/api/types/Error_.ts new file mode 100644 index 00000000..1526174a --- /dev/null +++ b/src/api/types/Error_.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The API will return an Error List for a failed request, which will contain one or more Error objects. + */ +export interface Error_ { + /** The type is error.list */ + type: string; + /** */ + request_id?: string; + /** An array of one or more error objects */ + errors: Error_.Errors.Item[]; +} + +export namespace Error_ { + export type Errors = Errors.Item[]; + + export namespace Errors { + export interface Item { + /** A string indicating the kind of error, used to further qualify the HTTP response code */ + code: string; + /** Optional. Human readable description of the error. */ + message?: string; + /** Optional. Used to identify a particular field or query parameter that was in error. */ + field?: string; + } + } +} diff --git a/src/api/types/FileAttribute.ts b/src/api/types/FileAttribute.ts new file mode 100644 index 00000000..e33ed602 --- /dev/null +++ b/src/api/types/FileAttribute.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The value describing a file upload set for a custom attribute + */ +export interface FileAttribute { + type: string; + /** The name of the file */ + name: string; + /** The url of the file. This is a temporary URL and will expire after 30 minutes. */ + url: string; + /** The type of file */ + content_type: string; + /** The size of the file in bytes */ + filesize: number; + /** The width of the file in pixels, if applicable */ + width: number; + /** The height of the file in pixels, if applicable */ + height: number; +} diff --git a/src/api/types/GroupContent.ts b/src/api/types/GroupContent.ts new file mode 100644 index 00000000..92c493c6 --- /dev/null +++ b/src/api/types/GroupContent.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The Content of a Group. + */ +export interface GroupContent { + /** The type of object - `group_content` . */ + type: "group_content"; + /** The name of the collection or section. */ + name: string; + /** The description of the collection. Only available for collections. */ + description: string; +} diff --git a/src/api/types/GroupTranslatedContent.ts b/src/api/types/GroupTranslatedContent.ts new file mode 100644 index 00000000..8f89cab2 --- /dev/null +++ b/src/api/types/GroupTranslatedContent.ts @@ -0,0 +1,87 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The Translated Content of an Group. The keys are the locale codes and the values are the translated content of the Group. + */ +export interface GroupTranslatedContent { + /** The type of object - group_translated_content. */ + type: "group_translated_content"; + /** The content of the group in Arabic */ + ar?: Intercom.GroupContent; + /** The content of the group in Bulgarian */ + bg?: Intercom.GroupContent; + /** The content of the group in Bosnian */ + bs?: Intercom.GroupContent; + /** The content of the group in Catalan */ + ca?: Intercom.GroupContent; + /** The content of the group in Czech */ + cs?: Intercom.GroupContent; + /** The content of the group in Danish */ + da?: Intercom.GroupContent; + /** The content of the group in German */ + de?: Intercom.GroupContent; + /** The content of the group in Greek */ + el?: Intercom.GroupContent; + /** The content of the group in English */ + en?: Intercom.GroupContent; + /** The content of the group in Spanish */ + es?: Intercom.GroupContent; + /** The content of the group in Estonian */ + et?: Intercom.GroupContent; + /** The content of the group in Finnish */ + fi?: Intercom.GroupContent; + /** The content of the group in French */ + fr?: Intercom.GroupContent; + /** The content of the group in Hebrew */ + he?: Intercom.GroupContent; + /** The content of the group in Croatian */ + hr?: Intercom.GroupContent; + /** The content of the group in Hungarian */ + hu?: Intercom.GroupContent; + /** The content of the group in Indonesian */ + id?: Intercom.GroupContent; + /** The content of the group in Italian */ + it?: Intercom.GroupContent; + /** The content of the group in Japanese */ + ja?: Intercom.GroupContent; + /** The content of the group in Korean */ + ko?: Intercom.GroupContent; + /** The content of the group in Lithuanian */ + lt?: Intercom.GroupContent; + /** The content of the group in Latvian */ + lv?: Intercom.GroupContent; + /** The content of the group in Mongolian */ + mn?: Intercom.GroupContent; + /** The content of the group in Norwegian */ + nb?: Intercom.GroupContent; + /** The content of the group in Dutch */ + nl?: Intercom.GroupContent; + /** The content of the group in Polish */ + pl?: Intercom.GroupContent; + /** The content of the group in Portuguese (Portugal) */ + pt?: Intercom.GroupContent; + /** The content of the group in Romanian */ + ro?: Intercom.GroupContent; + /** The content of the group in Russian */ + ru?: Intercom.GroupContent; + /** The content of the group in Slovenian */ + sl?: Intercom.GroupContent; + /** The content of the group in Serbian */ + sr?: Intercom.GroupContent; + /** The content of the group in Swedish */ + sv?: Intercom.GroupContent; + /** The content of the group in Turkish */ + tr?: Intercom.GroupContent; + /** The content of the group in Vietnamese */ + vi?: Intercom.GroupContent; + /** The content of the group in Portuguese (Brazil) */ + "pt-BR"?: Intercom.GroupContent; + /** The content of the group in Chinese (China) */ + "zh-CN"?: Intercom.GroupContent; + /** The content of the group in Chinese (Taiwan) */ + "zh-TW"?: Intercom.GroupContent; +} diff --git a/src/api/types/LinkedObject.ts b/src/api/types/LinkedObject.ts new file mode 100644 index 00000000..262dd306 --- /dev/null +++ b/src/api/types/LinkedObject.ts @@ -0,0 +1,26 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A linked conversation or ticket. + */ +export interface LinkedObject { + /** ticket or conversation */ + type: LinkedObject.Type; + /** The ID of the linked object */ + id: string; + /** Category of the Linked Ticket Object. */ + category?: string; +} + +export namespace LinkedObject { + /** + * ticket or conversation + */ + export type Type = "ticket" | "conversation"; + export const Type = { + Ticket: "ticket", + Conversation: "conversation", + } as const; +} diff --git a/src/api/types/LinkedObjectList.ts b/src/api/types/LinkedObjectList.ts new file mode 100644 index 00000000..043bfe1c --- /dev/null +++ b/src/api/types/LinkedObjectList.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * An object containing metadata about linked conversations and linked tickets. Up to 1000 can be returned. + */ +export interface LinkedObjectList { + /** Always list. */ + type: "list"; + /** The total number of linked objects. */ + total_count: number; + /** Whether or not there are more linked objects than returned. */ + has_more: boolean; + /** An array containing the linked conversations and linked tickets. */ + data: Intercom.LinkedObject[]; +} diff --git a/src/api/types/MultipleFilterSearchRequest.ts b/src/api/types/MultipleFilterSearchRequest.ts new file mode 100644 index 00000000..cdaf21d8 --- /dev/null +++ b/src/api/types/MultipleFilterSearchRequest.ts @@ -0,0 +1,32 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Search using Intercoms Search APIs with more than one filter. + */ +export interface MultipleFilterSearchRequest { + /** An operator to allow boolean inspection between multiple fields. */ + operator?: MultipleFilterSearchRequest.Operator; + value?: MultipleFilterSearchRequest.Value; +} + +export namespace MultipleFilterSearchRequest { + /** + * An operator to allow boolean inspection between multiple fields. + */ + export type Operator = "AND" | "OR"; + export const Operator = { + And: "AND", + Or: "OR", + } as const; + export type Value = + /** + * Add mutiple filters. */ + | Intercom.MultipleFilterSearchRequest[] + /** + * Add a single filter field. */ + | Intercom.SingleFilterSearchRequest[]; +} diff --git a/src/api/types/NewsItemRequest.ts b/src/api/types/NewsItemRequest.ts new file mode 100644 index 00000000..a7aaf7e4 --- /dev/null +++ b/src/api/types/NewsItemRequest.ts @@ -0,0 +1,38 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A News Item is a content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers. + */ +export interface NewsItemRequest { + /** The title of the news item. */ + title: string; + /** The news item body, which may contain HTML. */ + body?: string; + /** The id of the sender of the news item. Must be a teammate on the workspace. */ + sender_id: number; + /** News items will not be visible to your users in the assigned newsfeeds until they are set live. */ + state?: NewsItemRequest.State; + /** When set to `true`, the news item will appear in the messenger newsfeed without showing a notification badge. */ + deliver_silently?: boolean; + /** Label names displayed to users to categorize the news item. */ + labels?: string[]; + /** Ordered list of emoji reactions to the news item. When empty, reactions are disabled. */ + reactions?: (string | undefined)[]; + /** A list of newsfeed_assignments to assign to the specified newsfeed. */ + newsfeed_assignments?: Intercom.NewsfeedAssignment[]; +} + +export namespace NewsItemRequest { + /** + * News items will not be visible to your users in the assigned newsfeeds until they are set live. + */ + export type State = "draft" | "live"; + export const State = { + Draft: "draft", + Live: "live", + } as const; +} diff --git a/src/api/types/NoteList.ts b/src/api/types/NoteList.ts new file mode 100644 index 00000000..a9af4e69 --- /dev/null +++ b/src/api/types/NoteList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A paginated list of notes associated with a contact. + */ +export interface NoteList { + /** String representing the object's type. Always has the value `list`. */ + type: "list"; + /** An array of notes. */ + data: Intercom.Note[]; + /** A count of the total number of notes. */ + total_count: number; + pages?: Intercom.CursorPages; +} diff --git a/src/api/types/OpenConversationRequest.ts b/src/api/types/OpenConversationRequest.ts new file mode 100644 index 00000000..682699e3 --- /dev/null +++ b/src/api/types/OpenConversationRequest.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Payload of the request to open a conversation + */ +export interface OpenConversationRequest { + /** The id of the admin who is performing the action. */ + admin_id: string; +} diff --git a/src/api/types/PagesLink.ts b/src/api/types/PagesLink.ts new file mode 100644 index 00000000..9f298e78 --- /dev/null +++ b/src/api/types/PagesLink.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The majority of list resources in the API are paginated to allow clients to traverse data over multiple requests. + * + * Their responses are likely to contain a pages object that hosts pagination links which a client can use to paginate through the data without having to construct a query. The link relations for the pages field are as follows. + */ +export interface PagesLink { + type: "pages"; + page: number; + /** A link to the next page of results. A response that does not contain a next link does not have further data to fetch. */ + next?: string; + per_page: number; + total_pages: number; +} diff --git a/src/api/types/PaginatedConversationResponse.ts b/src/api/types/PaginatedConversationResponse.ts new file mode 100644 index 00000000..4a319f84 --- /dev/null +++ b/src/api/types/PaginatedConversationResponse.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Conversations are how you can communicate with users in Intercom. They are created when a contact replies to an outbound message, or when one admin directly sends a message to a single contact. + */ +export interface PaginatedConversationResponse { + /** Always conversation.list */ + type: "conversation.list"; + /** The list of conversation objects */ + conversations: Intercom.Conversation[]; + /** A count of the total number of objects. */ + total_count: number; + pages?: Intercom.CursorPages; +} diff --git a/src/api/types/PaginatedNewsItemResponse.ts b/src/api/types/PaginatedNewsItemResponse.ts new file mode 100644 index 00000000..dcabdedc --- /dev/null +++ b/src/api/types/PaginatedNewsItemResponse.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Paginated News Item Response + */ +export interface PaginatedNewsItemResponse { + /** The type of object */ + type: "list"; + pages?: Intercom.CursorPages; + /** A count of the total number of News Items. */ + total_count: number; + /** An array of News Items */ + data: Intercom.NewsItem[]; +} diff --git a/src/api/types/PaginatedNewsfeedResponse.ts b/src/api/types/PaginatedNewsfeedResponse.ts new file mode 100644 index 00000000..92ded308 --- /dev/null +++ b/src/api/types/PaginatedNewsfeedResponse.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Paginated Newsfeed Response + */ +export interface PaginatedNewsfeedResponse { + /** The type of object */ + type: "list"; + pages?: Intercom.CursorPages; + /** A count of the total number of Newsfeeds. */ + total_count: number; + /** An array of Newsfeeds */ + data: Intercom.Newsfeed[]; +} diff --git a/src/api/types/PartAttachment.ts b/src/api/types/PartAttachment.ts new file mode 100644 index 00000000..e87f566e --- /dev/null +++ b/src/api/types/PartAttachment.ts @@ -0,0 +1,23 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The file attached to a part + */ +export interface PartAttachment { + /** The type of attachment */ + type: string; + /** The name of the attachment */ + name: string; + /** The URL of the attachment */ + url: string; + /** The content type of the attachment */ + content_type: string; + /** The size of the attachment */ + filesize: number; + /** The width of the attachment */ + width: number; + /** The height of the attachment */ + height: number; +} diff --git a/src/api/types/PhoneSwitch.ts b/src/api/types/PhoneSwitch.ts new file mode 100644 index 00000000..200aa121 --- /dev/null +++ b/src/api/types/PhoneSwitch.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Phone Switch Response + */ +export interface PhoneSwitch { + /** */ + type: "phone_call_redirect"; + /** Phone number in E.164 format, that has received the SMS to continue the conversation in the Messenger. */ + phone: string; +} diff --git a/src/api/types/RedactConversationRequest.ts b/src/api/types/RedactConversationRequest.ts new file mode 100644 index 00000000..521b8ca3 --- /dev/null +++ b/src/api/types/RedactConversationRequest.ts @@ -0,0 +1,31 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +export type RedactConversationRequest = + /** + * Payload of the request to redact a conversation part */ + | Intercom.RedactConversationRequest.ConversationPart + /** + * Payload of the request to redact a conversation source */ + | Intercom.RedactConversationRequest.Source; + +export namespace RedactConversationRequest { + export interface ConversationPart { + type: "conversation_part"; + /** The id of the conversation. */ + conversation_id: string; + /** The id of the conversation_part. */ + conversation_part_id: string; + } + + export interface Source { + type: "source"; + /** The id of the conversation. */ + conversation_id: string; + /** The id of the source. */ + source_id: string; + } +} diff --git a/src/api/types/Reference.ts b/src/api/types/Reference.ts new file mode 100644 index 00000000..708375f6 --- /dev/null +++ b/src/api/types/Reference.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * reference to another object + */ +export interface Reference { + /** */ + type: string; + /** */ + id?: string; +} diff --git a/src/api/types/ReplyConversationRequest.ts b/src/api/types/ReplyConversationRequest.ts new file mode 100644 index 00000000..47e84c5d --- /dev/null +++ b/src/api/types/ReplyConversationRequest.ts @@ -0,0 +1,9 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +export type ReplyConversationRequest = + | Intercom.ContactReplyConversationRequest + | Intercom.AdminReplyConversationRequest; diff --git a/src/api/types/SearchRequest.ts b/src/api/types/SearchRequest.ts new file mode 100644 index 00000000..75ca8744 --- /dev/null +++ b/src/api/types/SearchRequest.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Search using Intercoms Search APIs. + */ +export interface SearchRequest { + query: SearchRequest.Query; + pagination?: Intercom.StartingAfterPaging; +} + +export namespace SearchRequest { + export type Query = Intercom.SingleFilterSearchRequest | Intercom.MultipleFilterSearchRequest; +} diff --git a/src/api/types/SegmentList.ts b/src/api/types/SegmentList.ts new file mode 100644 index 00000000..3c5636cf --- /dev/null +++ b/src/api/types/SegmentList.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * This will return a list of Segment Objects. The result may also have a pages object if the response is paginated. + */ +export interface SegmentList { + /** The type of the object */ + type: "segment.list"; + /** A list of Segment objects */ + segments: Intercom.Segment[]; + /** A pagination object, which may be empty, indicating no further pages to fetch. */ + pages?: Record; +} diff --git a/src/api/types/SingleFilterSearchRequest.ts b/src/api/types/SingleFilterSearchRequest.ts new file mode 100644 index 00000000..95f869cf --- /dev/null +++ b/src/api/types/SingleFilterSearchRequest.ts @@ -0,0 +1,34 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Search using Intercoms Search APIs with a single filter. + */ +export interface SingleFilterSearchRequest { + /** The accepted field that you want to search on. */ + field?: string; + /** The accepted operators you can use to define how you want to search for the value. */ + operator?: SingleFilterSearchRequest.Operator; + /** The value that you want to search on. */ + value?: string; +} + +export namespace SingleFilterSearchRequest { + /** + * The accepted operators you can use to define how you want to search for the value. + */ + export type Operator = "=" | "!=" | "IN" | "NIN" | "<" | ">" | "~" | "!~" | "^" | "$"; + export const Operator = { + Equals: "=", + NotEquals: "!=", + In: "IN", + NotIn: "NIN", + LessThan: "<", + GreaterThan: ">", + Contains: "~", + DoesNotContain: "!~", + StartsWith: "^", + EndsWith: "$", + } as const; +} diff --git a/src/api/types/SlaApplied.ts b/src/api/types/SlaApplied.ts new file mode 100644 index 00000000..086c6c17 --- /dev/null +++ b/src/api/types/SlaApplied.ts @@ -0,0 +1,37 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The SLA Applied object contains the details for which SLA has been applied to this conversation. + * Important: if there are any canceled sla_events for the conversation - meaning an SLA has been manually removed from a conversation, the sla_status will always be returned as null. + */ +export interface SlaApplied { + /** object type */ + type: string; + /** The name of the SLA as given by the teammate when it was created. */ + sla_name: string; + /** + * SLA statuses: + * - `hit`: If there’s at least one hit event in the underlying sla_events table, and no “missed” or “canceled” events for the conversation. + * - `missed`: If there are any missed sla_events for the conversation and no canceled events. If there’s even a single missed sla event, the status will always be missed. A missed status is not applied when the SLA expires, only the next time a teammate replies. + * - `active`: An SLA has been applied to a conversation, but has not yet been fulfilled. SLA status is active only if there are no “hit, “missed”, or “canceled” events. + */ + sla_status: SlaApplied.SlaStatus; +} + +export namespace SlaApplied { + /** + * SLA statuses: + * - `hit`: If there’s at least one hit event in the underlying sla_events table, and no “missed” or “canceled” events for the conversation. + * - `missed`: If there are any missed sla_events for the conversation and no canceled events. If there’s even a single missed sla event, the status will always be missed. A missed status is not applied when the SLA expires, only the next time a teammate replies. + * - `active`: An SLA has been applied to a conversation, but has not yet been fulfilled. SLA status is active only if there are no “hit, “missed”, or “canceled” events. + */ + export type SlaStatus = "hit" | "missed" | "cancelled" | "active"; + export const SlaStatus = { + Hit: "hit", + Missed: "missed", + Cancelled: "cancelled", + Active: "active", + } as const; +} diff --git a/src/api/types/SnoozeConversationRequest.ts b/src/api/types/SnoozeConversationRequest.ts new file mode 100644 index 00000000..25429753 --- /dev/null +++ b/src/api/types/SnoozeConversationRequest.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Payload of the request to snooze a conversation + */ +export interface SnoozeConversationRequest { + /** The id of the admin who is performing the action. */ + admin_id: string; + /** The time you want the conversation to reopen. */ + snoozed_until: number; +} diff --git a/src/api/types/SocialProfile.ts b/src/api/types/SocialProfile.ts new file mode 100644 index 00000000..be480217 --- /dev/null +++ b/src/api/types/SocialProfile.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A Social Profile allows you to label your contacts, companies, and conversations and list them using that Social Profile. + */ +export interface SocialProfile { + /** value is "social_profile" */ + type: string; + /** The name of the Social media profile */ + name: string; + /** The name of the Social media profile */ + url: string; +} diff --git a/src/api/types/StartingAfterPaging.ts b/src/api/types/StartingAfterPaging.ts new file mode 100644 index 00000000..df4feb10 --- /dev/null +++ b/src/api/types/StartingAfterPaging.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface StartingAfterPaging { + /** The number of results to fetch per page. */ + per_page: number; + /** The cursor to use in the next request to get the next page of results. */ + starting_after?: string; +} diff --git a/src/api/types/SubscriptionTypeList.ts b/src/api/types/SubscriptionTypeList.ts new file mode 100644 index 00000000..39b5ec38 --- /dev/null +++ b/src/api/types/SubscriptionTypeList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list of subscription type objects. + */ +export interface SubscriptionTypeList { + /** The type of the object */ + type: "list"; + /** A list of subscription type objects associated with the workspace . */ + data: Intercom.SubscriptionType[]; +} diff --git a/src/api/types/TagCompanyRequest.ts b/src/api/types/TagCompanyRequest.ts new file mode 100644 index 00000000..23231949 --- /dev/null +++ b/src/api/types/TagCompanyRequest.ts @@ -0,0 +1,26 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * You can tag a single company or a list of companies. + */ +export interface TagCompanyRequest { + /** The name of the tag, which will be created if not found. */ + name: string; + /** The id or company_id of the company can be passed as input parameters. */ + companies: TagCompanyRequest.Companies.Item[]; +} + +export namespace TagCompanyRequest { + export type Companies = Companies.Item[]; + + export namespace Companies { + export interface Item { + /** The Intercom defined id representing the company. */ + id?: string; + /** The company id you have defined for the company. */ + company_id?: string; + } + } +} diff --git a/src/api/types/TagList.ts b/src/api/types/TagList.ts new file mode 100644 index 00000000..4e658c56 --- /dev/null +++ b/src/api/types/TagList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list of tags objects in the workspace. + */ +export interface TagList { + /** The type of the object */ + type: "list"; + /** A list of tags objects associated with the workspace . */ + data: Intercom.Tag[]; +} diff --git a/src/api/types/TagMultipleUsersRequest.ts b/src/api/types/TagMultipleUsersRequest.ts new file mode 100644 index 00000000..df2f72b2 --- /dev/null +++ b/src/api/types/TagMultipleUsersRequest.ts @@ -0,0 +1,23 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * You can tag a list of users. + */ +export interface TagMultipleUsersRequest { + /** The name of the tag, which will be created if not found. */ + name: string; + users: TagMultipleUsersRequest.Users.Item[]; +} + +export namespace TagMultipleUsersRequest { + export type Users = Users.Item[]; + + export namespace Users { + export interface Item { + /** The Intercom defined id representing the user. */ + id?: string; + } + } +} diff --git a/src/api/types/Tags.ts b/src/api/types/Tags.ts new file mode 100644 index 00000000..b1257d7d --- /dev/null +++ b/src/api/types/Tags.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list of tags objects associated with a conversation + */ +export interface Tags { + /** The type of the object */ + type: "tag.list"; + /** A list of tags objects associated with the conversation. */ + tags: Intercom.Tag[]; +} diff --git a/src/api/types/TeamList.ts b/src/api/types/TeamList.ts new file mode 100644 index 00000000..b7833bf3 --- /dev/null +++ b/src/api/types/TeamList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * This will return a list of team objects for the App. + */ +export interface TeamList { + /** The type of the object */ + type: "team.list"; + /** A list of team objects */ + teams: Intercom.Team[]; +} diff --git a/src/api/types/TeamPriorityLevel.ts b/src/api/types/TeamPriorityLevel.ts new file mode 100644 index 00000000..b979fa1d --- /dev/null +++ b/src/api/types/TeamPriorityLevel.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Admin priority levels for teams + */ +export interface TeamPriorityLevel { + /** The primary team ids for the team */ + primary_team_ids?: number[]; + /** The secondary team ids for the team */ + secondary_team_ids?: number[]; +} diff --git a/src/api/types/TicketCustomAttributes.ts b/src/api/types/TicketCustomAttributes.ts new file mode 100644 index 00000000..08242e66 --- /dev/null +++ b/src/api/types/TicketCustomAttributes.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * An object containing the different attributes associated to the ticket as key-value pairs. For the default title and description attributes, the keys are `_default_title_` and `_default_description_`. + */ +export type TicketCustomAttributes = Record; + +export namespace TicketCustomAttributes { + export type Value = string | undefined | number | boolean | unknown[] | Intercom.FileAttribute; +} diff --git a/src/api/types/TicketList.ts b/src/api/types/TicketList.ts new file mode 100644 index 00000000..5cfdf4fe --- /dev/null +++ b/src/api/types/TicketList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Tickets are how you track requests from your users. + */ +export interface TicketList { + /** Always ticket.list */ + type: "ticket.list"; + /** The list of ticket objects */ + tickets: Intercom.Ticket[]; + /** A count of the total number of objects. */ + total_count: number; + pages?: Intercom.CursorPages; +} diff --git a/src/api/types/TicketPartAuthor.ts b/src/api/types/TicketPartAuthor.ts new file mode 100644 index 00000000..c09f0739 --- /dev/null +++ b/src/api/types/TicketPartAuthor.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The author that wrote or triggered the part. Can be a bot, admin, team or user. + */ +export interface TicketPartAuthor { + /** The type of the author */ + type: TicketPartAuthor.Type; + /** The id of the author */ + id: string; + /** The name of the author */ + name?: string; + /** The email of the author */ + email: string; +} + +export namespace TicketPartAuthor { + /** + * The type of the author + */ + export type Type = "admin" | "bot" | "team" | "user"; + export const Type = { + Admin: "admin", + Bot: "bot", + Team: "team", + User: "user", + } as const; +} diff --git a/src/api/types/TicketParts.ts b/src/api/types/TicketParts.ts new file mode 100644 index 00000000..f6d4ee25 --- /dev/null +++ b/src/api/types/TicketParts.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list of Ticket Part objects for each note and event in the ticket. There is a limit of 500 parts. + */ +export interface TicketParts { + /** */ + type: "ticket_part.list"; + /** A list of Ticket Part objects for each ticket. There is a limit of 500 parts. */ + ticket_parts: Intercom.TicketPart[]; + /** */ + total_count: number; +} diff --git a/src/api/types/TicketReply.ts b/src/api/types/TicketReply.ts new file mode 100644 index 00000000..7c3b7f11 --- /dev/null +++ b/src/api/types/TicketReply.ts @@ -0,0 +1,40 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A Ticket Part representing a note, comment, or quick_reply on a ticket + */ +export interface TicketReply { + /** Always ticket_part */ + type: "ticket_part"; + /** The id representing the part. */ + id: string; + /** Type of the part */ + part_type: TicketReply.PartType; + /** The message body, which may contain HTML. */ + body?: string; + /** The time the note was created. */ + created_at: number; + /** The last time the note was updated. */ + updated_at?: number; + author?: Intercom.TicketPartAuthor; + /** A list of attachments for the part. */ + attachments?: Intercom.PartAttachment[]; + /** Whether or not the ticket part has been redacted. */ + redacted?: boolean; +} + +export namespace TicketReply { + /** + * Type of the part + */ + export type PartType = "note" | "comment" | "quick_reply"; + export const PartType = { + Note: "note", + Comment: "comment", + QuickReply: "quick_reply", + } as const; +} diff --git a/src/api/types/TicketRequestCustomAttributes.ts b/src/api/types/TicketRequestCustomAttributes.ts new file mode 100644 index 00000000..6a3af042 --- /dev/null +++ b/src/api/types/TicketRequestCustomAttributes.ts @@ -0,0 +1,12 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The attributes set on the ticket. When setting the default title and description attributes, the attribute keys that should be used are `_default_title_` and `_default_description_`. When setting ticket type attributes of the list attribute type, the key should be the attribute name and the value of the attribute should be the list item id, obtainable by [listing the ticket type](ref:get_ticket-types). For example, if the ticket type has an attribute called `priority` of type `list`, the key should be `priority` and the value of the attribute should be the guid of the list item (e.g. `de1825a0-0164-4070-8ca6-13e22462fa7e`). + */ +export type TicketRequestCustomAttributes = Record; + +export namespace TicketRequestCustomAttributes { + export type Value = string | undefined | number | boolean | unknown[]; +} diff --git a/src/api/types/TicketTypeAttribute.ts b/src/api/types/TicketTypeAttribute.ts new file mode 100644 index 00000000..d86c1807 --- /dev/null +++ b/src/api/types/TicketTypeAttribute.ts @@ -0,0 +1,43 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Ticket type attribute, used to define each data field to be captured in a ticket. + */ +export interface TicketTypeAttribute { + /** String representing the object's type. Always has the value `ticket_type_attribute`. */ + type: "ticket_type_attribute"; + /** The id representing the ticket type attribute. */ + id: string; + /** The id of the workspace that the ticket type attribute belongs to. */ + workspace_id: string; + /** The name of the ticket type attribute */ + name: string; + /** The description of the ticket type attribute */ + description: string; + /** The type of the data attribute (allowed values: "string list integer decimal boolean datetime files") */ + data_type: string; + /** Input options for the attribute */ + input_options: Record; + /** The order of the attribute against other attributes */ + order: number; + /** Whether the attribute is required or not for teammates. */ + required_to_create: boolean; + /** Whether the attribute is required or not for contacts. */ + required_to_create_for_contacts: boolean; + /** Whether the attribute is visible or not to teammates. */ + visible_on_create: boolean; + /** Whether the attribute is visible or not to contacts. */ + visible_to_contacts: boolean; + /** Whether the attribute is built in or not. */ + default: boolean; + /** The id of the ticket type that the attribute belongs to. */ + ticket_type_id: number; + /** Whether the ticket type attribute is archived or not. */ + archived: boolean; + /** The date and time the ticket type attribute was created. */ + created_at: number; + /** The date and time the ticket type attribute was last updated. */ + updated_at?: number; +} diff --git a/src/api/types/TicketTypeAttributeList.ts b/src/api/types/TicketTypeAttributeList.ts new file mode 100644 index 00000000..011e3cc2 --- /dev/null +++ b/src/api/types/TicketTypeAttributeList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list of attributes associated with a given ticket type. + */ +export interface TicketTypeAttributeList { + /** String representing the object's type. Always has the value `ticket_type_attributes.list`. */ + type: "ticket_type_attributes.list"; + /** A list of ticket type attributes associated with a given ticket type. */ + ticket_type_attributes: Intercom.TicketTypeAttribute[]; +} diff --git a/src/api/types/TicketTypeList.ts b/src/api/types/TicketTypeList.ts new file mode 100644 index 00000000..3a4d2b86 --- /dev/null +++ b/src/api/types/TicketTypeList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list of ticket types associated with a given workspace. + */ +export interface TicketTypeList { + /** String representing the object's type. Always has the value `ticket_type.list`. */ + type: "ticket_type_attributes.list"; + /** A list of ticket_types associated with a given workspace. */ + ticket_types: Intercom.TicketType[]; +} diff --git a/src/api/types/Translation.ts b/src/api/types/Translation.ts new file mode 100644 index 00000000..19b73881 --- /dev/null +++ b/src/api/types/Translation.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A translation object contains the localised details of a subscription type. + */ +export interface Translation { + /** The localised name of the subscription type. */ + name: string; + /** The localised description of the subscription type. */ + description: string; + /** The two character identifier for the language of the translation object. */ + locale: string; +} diff --git a/src/api/types/UntagCompanyRequest.ts b/src/api/types/UntagCompanyRequest.ts new file mode 100644 index 00000000..dd179dde --- /dev/null +++ b/src/api/types/UntagCompanyRequest.ts @@ -0,0 +1,28 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * You can tag a single company or a list of companies. + */ +export interface UntagCompanyRequest { + /** The name of the tag which will be untagged from the company */ + name: string; + /** The id or company_id of the company can be passed as input parameters. */ + companies: UntagCompanyRequest.Companies.Item[]; +} + +export namespace UntagCompanyRequest { + export type Companies = Companies.Item[]; + + export namespace Companies { + export interface Item { + /** The Intercom defined id representing the company. */ + id: string; + /** The company id you have defined for the company. */ + company_id: string; + /** Always set to true */ + untag: true; + } + } +} diff --git a/src/api/types/UpdateVisitorRequest.ts b/src/api/types/UpdateVisitorRequest.ts new file mode 100644 index 00000000..a81aa7d3 --- /dev/null +++ b/src/api/types/UpdateVisitorRequest.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Update an existing visitor. + */ +export type UpdateVisitorRequest = + | { + id: string; + name?: string | undefined; + custom_attributes?: Record | undefined; + } + | { + user_id: string; + name?: string | undefined; + custom_attributes?: Record | undefined; + }; diff --git a/src/api/types/Visitor.ts b/src/api/types/Visitor.ts new file mode 100644 index 00000000..d70f2bec --- /dev/null +++ b/src/api/types/Visitor.ts @@ -0,0 +1,138 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Visitors are useful for representing anonymous people that have not yet been identified. They usually represent website visitors. Visitors are not visible in Intercom platform. The Visitors resource provides methods to fetch, update, convert and delete. + */ +export interface Visitor { + /** Value is 'visitor' */ + type: string; + /** The Intercom defined id representing the Visitor. */ + id: string; + /** Automatically generated identifier for the Visitor. */ + user_id: string; + /** Identifies if this visitor is anonymous. */ + anonymous: boolean; + /** The email of the visitor. */ + email: string; + /** The phone number of the visitor. */ + phone?: string; + /** The name of the visitor. */ + name?: string; + /** The pseudonym of the visitor. */ + pseudonym?: string; + avatar?: Visitor.Avatar; + /** The id of the app the visitor is associated with. */ + app_id: string; + companies?: Visitor.Companies; + location_data?: Visitor.LocationData; + /** The time the Lead last recorded making a request. */ + las_request_at?: number; + /** The time the Visitor was added to Intercom. */ + created_at: number; + /** The time the Visitor was added to Intercom. */ + remote_created_at?: number; + /** The time the Visitor signed up for your product. */ + signed_up_at: number; + /** The last time the Visitor was updated. */ + updated_at?: number; + /** The number of sessions the Visitor has had. */ + session_count?: number; + social_profiles?: Visitor.SocialProfiles; + /** The id of the admin that owns the Visitor. */ + owner_id?: string; + /** Whether the Visitor is unsubscribed from emails. */ + unsubscribed_from_emails?: boolean; + /** Identifies if this visitor has marked an email as spam. */ + marked_email_as_spam?: boolean; + /** Identifies if this visitor has had a hard bounce. */ + has_hard_bounced?: boolean; + tags?: Visitor.Tags; + segments?: Visitor.Segments; + /** The custom attributes you have set on the Visitor. */ + custom_attributes?: Record; + /** The referer of the visitor. */ + referrer?: string; + /** The utm_campaign of the visitor. */ + utm_campaign?: string; + /** The utm_content of the visitor. */ + utm_content?: string; + /** The utm_medium of the visitor. */ + utm_medium?: string; + /** The utm_source of the visitor. */ + utm_source?: string; + /** The utm_term of the visitor. */ + utm_term?: string; + /** Identifies if this visitor has do not track enabled. */ + do_not_track?: boolean; +} + +export namespace Visitor { + export interface Avatar { + /** */ + type?: string; + /** This object represents the avatar associated with the visitor. */ + image_url?: string; + } + + export interface Companies { + /** The type of the object */ + type?: "company.list"; + companies?: Intercom.Company[]; + } + + export interface LocationData { + /** */ + type?: string; + /** The city name of the visitor. */ + city_name?: string; + /** The continent code of the visitor. */ + continent_code?: string; + /** The country code of the visitor. */ + country_code?: string; + /** The country name of the visitor. */ + country_name?: string; + /** The postal code of the visitor. */ + postal_code?: string; + /** The region name of the visitor. */ + region_name?: string; + /** The timezone of the visitor. */ + timezone?: string; + } + + export interface SocialProfiles { + /** The type of the object */ + type?: "social_profile.list"; + social_profiles?: string[]; + } + + export interface Tags { + /** The type of the object */ + type?: "tag.list"; + tags?: Tags.Tags.Item[]; + } + + export namespace Tags { + export type Tags = Tags.Item[]; + + export namespace Tags { + export interface Item { + /** The type of the object */ + type?: "tag"; + /** The id of the tag. */ + id?: string; + /** The name of the tag. */ + name?: string; + } + } + } + + export interface Segments { + /** The type of the object */ + type?: "segment.list"; + segments?: string[]; + } +} diff --git a/src/api/types/VisitorDeletedObject.ts b/src/api/types/VisitorDeletedObject.ts new file mode 100644 index 00000000..3195b30d --- /dev/null +++ b/src/api/types/VisitorDeletedObject.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Response returned when an object is deleted + */ +export interface VisitorDeletedObject { + /** The unique identifier for the visitor which is given by Intercom. */ + id: string; + /** The type of object which was deleted */ + type: "visitor"; + /** Automatically generated identifier for the Visitor. */ + user_id: string; +} diff --git a/src/api/types/index.ts b/src/api/types/index.ts new file mode 100644 index 00000000..589b9a06 --- /dev/null +++ b/src/api/types/index.ts @@ -0,0 +1,118 @@ +export * from "./ActivityLog"; +export * from "./ActivityLogList"; +export * from "./ActivityLogMetadata"; +export * from "./AddressableList"; +export * from "./AdminList"; +export * from "./AdminPriorityLevel"; +export * from "./AdminReplyConversationRequest"; +export * from "./AdminReplyTicketRequest"; +export * from "./AdminWithApp"; +export * from "./App"; +export * from "./ArticleContent"; +export * from "./ArticleList"; +export * from "./ArticleStatistics"; +export * from "./ArticleTranslatedContent"; +export * from "./AssignConversationRequest"; +export * from "./CloseConversationRequest"; +export * from "./CollectionList"; +export * from "./CompanyAttachedContacts"; +export * from "./CompanyAttachedSegments"; +export * from "./CompanyList"; +export * from "./CompanyScroll"; +export * from "./ContactArchived"; +export * from "./ContactAttachedCompanies"; +export * from "./ContactCompanies"; +export * from "./ContactDeleted"; +export * from "./ContactList"; +export * from "./ContactLocation"; +export * from "./ContactNotes"; +export * from "./ContactReference"; +export * from "./ContactReplyBaseRequest"; +export * from "./ContactReplyConversationRequest"; +export * from "./ContactReplyEmailRequest"; +export * from "./ContactReplyIntercomUserIdRequest"; +export * from "./ContactReplyTicketEmailRequest"; +export * from "./ContactReplyTicketIntercomUserIdRequest"; +export * from "./ContactReplyTicketRequest"; +export * from "./ContactReplyTicketUserIdRequest"; +export * from "./ContactReplyUserIdRequest"; +export * from "./ContactSegments"; +export * from "./ContactSocialProfiles"; +export * from "./ContactSubscriptionTypes"; +export * from "./ContactTags"; +export * from "./ContactUnarchived"; +export * from "./ContentSourcesList"; +export * from "./ConversationAttachmentFiles"; +export * from "./ConversationContacts"; +export * from "./ConversationFirstContactReply"; +export * from "./PaginatedConversationResponse"; +export * from "./ConversationPart"; +export * from "./ConversationPartAuthor"; +export * from "./ConversationParts"; +export * from "./ConversationRating"; +export * from "./ConversationSource"; +export * from "./ConversationStatistics"; +export * from "./ConversationTeammates"; +export * from "./CreateContactRequest"; +export * from "./CreateDataEventRequest"; +export * from "./CreateMessageRequest"; +export * from "./CreateOrUpdateTagRequest"; +export * from "./CreateTicketReplyWithCommentRequest"; +export * from "./CursorPages"; +export * from "./CustomAttributes"; +export * from "./CustomerRequest"; +export * from "./DataAttributeList"; +export * from "./DataEventList"; +export * from "./DataEventSummary"; +export * from "./DataEventSummaryItem"; +export * from "./DataExportCsv"; +export * from "./DeletedArticleObject"; +export * from "./DeletedCollectionObject"; +export * from "./DeletedCompanyObject"; +export * from "./DeletedObject"; +export * from "./Error_"; +export * from "./FileAttribute"; +export * from "./GroupContent"; +export * from "./GroupTranslatedContent"; +export * from "./LinkedObject"; +export * from "./LinkedObjectList"; +export * from "./MultipleFilterSearchRequest"; +export * from "./NewsItemRequest"; +export * from "./NoteList"; +export * from "./OpenConversationRequest"; +export * from "./PagesLink"; +export * from "./PaginatedNewsItemResponse"; +export * from "./PaginatedNewsfeedResponse"; +export * from "./PartAttachment"; +export * from "./PhoneSwitch"; +export * from "./RedactConversationRequest"; +export * from "./Reference"; +export * from "./ReplyConversationRequest"; +export * from "./SearchRequest"; +export * from "./SegmentList"; +export * from "./SingleFilterSearchRequest"; +export * from "./SlaApplied"; +export * from "./SnoozeConversationRequest"; +export * from "./SocialProfile"; +export * from "./StartingAfterPaging"; +export * from "./SubscriptionTypeList"; +export * from "./TagCompanyRequest"; +export * from "./TagList"; +export * from "./TagMultipleUsersRequest"; +export * from "./Tags"; +export * from "./TeamList"; +export * from "./TeamPriorityLevel"; +export * from "./TicketCustomAttributes"; +export * from "./TicketList"; +export * from "./TicketPartAuthor"; +export * from "./TicketParts"; +export * from "./TicketReply"; +export * from "./TicketRequestCustomAttributes"; +export * from "./TicketTypeAttribute"; +export * from "./TicketTypeAttributeList"; +export * from "./TicketTypeList"; +export * from "./Translation"; +export * from "./UntagCompanyRequest"; +export * from "./UpdateVisitorRequest"; +export * from "./Visitor"; +export * from "./VisitorDeletedObject"; diff --git a/src/api/version.ts b/src/api/version.ts new file mode 100644 index 00000000..834369d5 --- /dev/null +++ b/src/api/version.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** The version of the API, sent as the Intercom-Version header. */ +export type IntercomVersion = + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; diff --git a/src/core/auth/BasicAuth.ts b/src/core/auth/BasicAuth.ts new file mode 100644 index 00000000..146df215 --- /dev/null +++ b/src/core/auth/BasicAuth.ts @@ -0,0 +1,31 @@ +import { Base64 } from "js-base64"; + +export interface BasicAuth { + username: string; + password: string; +} + +const BASIC_AUTH_HEADER_PREFIX = /^Basic /i; + +export const BasicAuth = { + toAuthorizationHeader: (basicAuth: BasicAuth | undefined): string | undefined => { + if (basicAuth == null) { + return undefined; + } + const token = Base64.encode(`${basicAuth.username}:${basicAuth.password}`); + return `Basic ${token}`; + }, + fromAuthorizationHeader: (header: string): BasicAuth => { + const credentials = header.replace(BASIC_AUTH_HEADER_PREFIX, ""); + const decoded = Base64.decode(credentials); + const [username, password] = decoded.split(":", 2); + + if (username == null || password == null) { + throw new Error("Invalid basic auth"); + } + return { + username, + password, + }; + }, +}; diff --git a/src/core/auth/BearerToken.ts b/src/core/auth/BearerToken.ts new file mode 100644 index 00000000..fe987fc9 --- /dev/null +++ b/src/core/auth/BearerToken.ts @@ -0,0 +1,15 @@ +export type BearerToken = string; + +const BEARER_AUTH_HEADER_PREFIX = /^Bearer /i; + +export const BearerToken = { + toAuthorizationHeader: (token: BearerToken | undefined): string | undefined => { + if (token == null) { + return undefined; + } + return `Bearer ${token}`; + }, + fromAuthorizationHeader: (header: string): BearerToken => { + return header.replace(BEARER_AUTH_HEADER_PREFIX, "").trim() as BearerToken; + }, +}; diff --git a/src/core/auth/index.ts b/src/core/auth/index.ts new file mode 100644 index 00000000..ee293b34 --- /dev/null +++ b/src/core/auth/index.ts @@ -0,0 +1,2 @@ +export { BasicAuth } from "./BasicAuth"; +export { BearerToken } from "./BearerToken"; diff --git a/src/core/fetcher/APIResponse.ts b/src/core/fetcher/APIResponse.ts new file mode 100644 index 00000000..3664d09e --- /dev/null +++ b/src/core/fetcher/APIResponse.ts @@ -0,0 +1,12 @@ +export type APIResponse = SuccessfulResponse | FailedResponse; + +export interface SuccessfulResponse { + ok: true; + body: T; + headers?: Record; +} + +export interface FailedResponse { + ok: false; + error: T; +} diff --git a/src/core/fetcher/Fetcher.ts b/src/core/fetcher/Fetcher.ts new file mode 100644 index 00000000..b8f23717 --- /dev/null +++ b/src/core/fetcher/Fetcher.ts @@ -0,0 +1,143 @@ +import { APIResponse } from "./APIResponse"; +import { createRequestUrl } from "./createRequestUrl"; +import { getFetchFn } from "./getFetchFn"; +import { getRequestBody } from "./getRequestBody"; +import { getResponseBody } from "./getResponseBody"; +import { makeRequest } from "./makeRequest"; +import { requestWithRetries } from "./requestWithRetries"; + +export type FetchFunction = (args: Fetcher.Args) => Promise>; + +export declare namespace Fetcher { + export interface Args { + url: string; + method: string; + contentType?: string; + headers?: Record; + queryParameters?: Record; + body?: unknown; + timeoutMs?: number; + maxRetries?: number; + withCredentials?: boolean; + abortSignal?: AbortSignal; + requestType?: "json" | "file" | "bytes"; + responseType?: "json" | "blob" | "sse" | "streaming" | "text" | "arrayBuffer"; + duplex?: "half"; + } + + export type Error = FailedStatusCodeError | NonJsonError | TimeoutError | UnknownError; + + export interface FailedStatusCodeError { + reason: "status-code"; + statusCode: number; + body: unknown; + } + + export interface NonJsonError { + reason: "non-json"; + statusCode: number; + rawBody: string; + } + + export interface TimeoutError { + reason: "timeout"; + } + + export interface UnknownError { + reason: "unknown"; + errorMessage: string; + } +} + +export async function fetcherImpl(args: Fetcher.Args): Promise> { + const headers: Record = {}; + if (args.body !== undefined && args.contentType != null) { + headers["Content-Type"] = args.contentType; + } + + if (args.headers != null) { + for (const [key, value] of Object.entries(args.headers)) { + if (value != null) { + headers[key] = value; + } + } + } + + const url = createRequestUrl(args.url, args.queryParameters); + let requestBody: BodyInit | undefined = await getRequestBody({ + body: args.body, + type: args.requestType === "json" ? "json" : "other", + }); + const fetchFn = await getFetchFn(); + + try { + const response = await requestWithRetries( + async () => + makeRequest( + fetchFn, + url, + args.method, + headers, + requestBody, + args.timeoutMs, + args.abortSignal, + args.withCredentials, + args.duplex + ), + args.maxRetries + ); + let responseBody = await getResponseBody(response, args.responseType); + + if (response.status >= 200 && response.status < 400) { + return { + ok: true, + body: responseBody as R, + headers: response.headers, + }; + } else { + return { + ok: false, + error: { + reason: "status-code", + statusCode: response.status, + body: responseBody, + }, + }; + } + } catch (error) { + if (args.abortSignal != null && args.abortSignal.aborted) { + return { + ok: false, + error: { + reason: "unknown", + errorMessage: "The user aborted a request", + }, + }; + } else if (error instanceof Error && error.name === "AbortError") { + return { + ok: false, + error: { + reason: "timeout", + }, + }; + } else if (error instanceof Error) { + return { + ok: false, + error: { + reason: "unknown", + errorMessage: error.message, + }, + }; + } + + return { + ok: false, + error: { + reason: "unknown", + errorMessage: JSON.stringify(error), + }, + }; + } +} + +export const fetcher: FetchFunction = fetcherImpl; diff --git a/src/core/fetcher/Supplier.ts b/src/core/fetcher/Supplier.ts new file mode 100644 index 00000000..867c931c --- /dev/null +++ b/src/core/fetcher/Supplier.ts @@ -0,0 +1,11 @@ +export type Supplier = T | Promise | (() => T | Promise); + +export const Supplier = { + get: async (supplier: Supplier): Promise => { + if (typeof supplier === "function") { + return (supplier as () => T)(); + } else { + return supplier; + } + }, +}; diff --git a/src/core/fetcher/createRequestUrl.ts b/src/core/fetcher/createRequestUrl.ts new file mode 100644 index 00000000..9288a99b --- /dev/null +++ b/src/core/fetcher/createRequestUrl.ts @@ -0,0 +1,10 @@ +import qs from "qs"; + +export function createRequestUrl( + baseUrl: string, + queryParameters?: Record +): string { + return Object.keys(queryParameters ?? {}).length > 0 + ? `${baseUrl}?${qs.stringify(queryParameters, { arrayFormat: "repeat" })}` + : baseUrl; +} diff --git a/src/core/fetcher/getFetchFn.ts b/src/core/fetcher/getFetchFn.ts new file mode 100644 index 00000000..9fd9bfc4 --- /dev/null +++ b/src/core/fetcher/getFetchFn.ts @@ -0,0 +1,25 @@ +import { RUNTIME } from "../runtime"; + +/** + * Returns a fetch function based on the runtime + */ +export async function getFetchFn(): Promise { + // In Node.js 18+ environments, use native fetch + if (RUNTIME.type === "node" && RUNTIME.parsedVersion != null && RUNTIME.parsedVersion >= 18) { + return fetch; + } + + // In Node.js 18 or lower environments, the SDK always uses`node-fetch`. + if (RUNTIME.type === "node") { + return (await import("node-fetch")).default as any; + } + + // Otherwise the SDK uses global fetch if available, + // and falls back to node-fetch. + if (typeof fetch == "function") { + return fetch; + } + + // Defaults to node `node-fetch` if global fetch isn't available + return (await import("node-fetch")).default as any; +} diff --git a/src/core/fetcher/getHeader.ts b/src/core/fetcher/getHeader.ts new file mode 100644 index 00000000..50f922b0 --- /dev/null +++ b/src/core/fetcher/getHeader.ts @@ -0,0 +1,8 @@ +export function getHeader(headers: Record, header: string): string | undefined { + for (const [headerKey, headerValue] of Object.entries(headers)) { + if (headerKey.toLowerCase() === header.toLowerCase()) { + return headerValue; + } + } + return undefined; +} diff --git a/src/core/fetcher/getRequestBody.ts b/src/core/fetcher/getRequestBody.ts new file mode 100644 index 00000000..1138414b --- /dev/null +++ b/src/core/fetcher/getRequestBody.ts @@ -0,0 +1,14 @@ +export declare namespace GetRequestBody { + interface Args { + body: unknown; + type: "json" | "file" | "bytes" | "other"; + } +} + +export async function getRequestBody({ body, type }: GetRequestBody.Args): Promise { + if (type.includes("json")) { + return JSON.stringify(body); + } else { + return body as BodyInit; + } +} diff --git a/src/core/fetcher/getResponseBody.ts b/src/core/fetcher/getResponseBody.ts new file mode 100644 index 00000000..d046e6ea --- /dev/null +++ b/src/core/fetcher/getResponseBody.ts @@ -0,0 +1,34 @@ +import { chooseStreamWrapper } from "./stream-wrappers/chooseStreamWrapper"; + +export async function getResponseBody(response: Response, responseType?: string): Promise { + if (response.body != null && responseType === "blob") { + return await response.blob(); + } else if (response.body != null && responseType === "arrayBuffer") { + return await response.arrayBuffer(); + } else if (response.body != null && responseType === "sse") { + return response.body; + } else if (response.body != null && responseType === "streaming") { + return chooseStreamWrapper(response.body); + } else if (response.body != null && responseType === "text") { + return await response.text(); + } else { + const text = await response.text(); + if (text.length > 0) { + try { + let responseBody = JSON.parse(text); + return responseBody; + } catch (err) { + return { + ok: false, + error: { + reason: "non-json", + statusCode: response.status, + rawBody: text, + }, + }; + } + } else { + return undefined; + } + } +} diff --git a/src/core/fetcher/index.ts b/src/core/fetcher/index.ts new file mode 100644 index 00000000..2d658ca4 --- /dev/null +++ b/src/core/fetcher/index.ts @@ -0,0 +1,5 @@ +export type { APIResponse } from "./APIResponse"; +export { fetcher } from "./Fetcher"; +export type { Fetcher, FetchFunction } from "./Fetcher"; +export { getHeader } from "./getHeader"; +export { Supplier } from "./Supplier"; diff --git a/src/core/fetcher/makeRequest.ts b/src/core/fetcher/makeRequest.ts new file mode 100644 index 00000000..8fb4bace --- /dev/null +++ b/src/core/fetcher/makeRequest.ts @@ -0,0 +1,44 @@ +import { anySignal, getTimeoutSignal } from "./signals"; + +export const makeRequest = async ( + fetchFn: (url: string, init: RequestInit) => Promise, + url: string, + method: string, + headers: Record, + requestBody: BodyInit | undefined, + timeoutMs?: number, + abortSignal?: AbortSignal, + withCredentials?: boolean, + duplex?: "half" +): Promise => { + const signals: AbortSignal[] = []; + + // Add timeout signal + let timeoutAbortId: NodeJS.Timeout | undefined = undefined; + if (timeoutMs != null) { + const { signal, abortId } = getTimeoutSignal(timeoutMs); + timeoutAbortId = abortId; + signals.push(signal); + } + + // Add arbitrary signal + if (abortSignal != null) { + signals.push(abortSignal); + } + let newSignals = anySignal(signals); + const response = await fetchFn(url, { + method: method, + headers, + body: requestBody, + signal: newSignals, + credentials: withCredentials ? "include" : undefined, + // @ts-ignore + duplex, + }); + + if (timeoutAbortId != null) { + clearTimeout(timeoutAbortId); + } + + return response; +}; diff --git a/src/core/fetcher/requestWithRetries.ts b/src/core/fetcher/requestWithRetries.ts new file mode 100644 index 00000000..8d5af9d5 --- /dev/null +++ b/src/core/fetcher/requestWithRetries.ts @@ -0,0 +1,33 @@ +const INITIAL_RETRY_DELAY = 1000; // in milliseconds +const MAX_RETRY_DELAY = 60000; // in milliseconds +const DEFAULT_MAX_RETRIES = 2; +const JITTER_FACTOR = 0.2; // 20% random jitter + +function addJitter(delay: number): number { + // Generate a random value between -JITTER_FACTOR and +JITTER_FACTOR + const jitterMultiplier = 1 + (Math.random() * 2 - 1) * JITTER_FACTOR; + return delay * jitterMultiplier; +} + +export async function requestWithRetries( + requestFn: () => Promise, + maxRetries: number = DEFAULT_MAX_RETRIES +): Promise { + let response: Response = await requestFn(); + + for (let i = 0; i < maxRetries; ++i) { + if ([408, 409, 429].includes(response.status) || response.status >= 500) { + // Calculate base delay using exponential backoff (in milliseconds) + const baseDelay = Math.min(INITIAL_RETRY_DELAY * Math.pow(2, i), MAX_RETRY_DELAY); + + // Add jitter to the delay + const delayWithJitter = addJitter(baseDelay); + + await new Promise((resolve) => setTimeout(resolve, delayWithJitter)); + response = await requestFn(); + } else { + break; + } + } + return response!; +} diff --git a/src/core/fetcher/signals.ts b/src/core/fetcher/signals.ts new file mode 100644 index 00000000..6c124ff7 --- /dev/null +++ b/src/core/fetcher/signals.ts @@ -0,0 +1,38 @@ +const TIMEOUT = "timeout"; + +export function getTimeoutSignal(timeoutMs: number): { signal: AbortSignal; abortId: NodeJS.Timeout } { + const controller = new AbortController(); + const abortId = setTimeout(() => controller.abort(TIMEOUT), timeoutMs); + return { signal: controller.signal, abortId }; +} + +/** + * Returns an abort signal that is getting aborted when + * at least one of the specified abort signals is aborted. + * + * Requires at least node.js 18. + */ +export function anySignal(...args: AbortSignal[] | [AbortSignal[]]): AbortSignal { + // Allowing signals to be passed either as array + // of signals or as multiple arguments. + const signals = (args.length === 1 && Array.isArray(args[0]) ? args[0] : args); + + const controller = new AbortController(); + + for (const signal of signals) { + if (signal.aborted) { + // Exiting early if one of the signals + // is already aborted. + controller.abort((signal as any)?.reason); + break; + } + + // Listening for signals and removing the listeners + // when at least one symbol is aborted. + signal.addEventListener("abort", () => controller.abort((signal as any)?.reason), { + signal: controller.signal, + }); + } + + return controller.signal; +} diff --git a/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts b/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts new file mode 100644 index 00000000..4d7b7d52 --- /dev/null +++ b/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts @@ -0,0 +1,256 @@ +import type { Writable } from "readable-stream"; +import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; + +export class Node18UniversalStreamWrapper + implements + StreamWrapper | Writable | WritableStream, ReadFormat> +{ + private readableStream: ReadableStream; + private reader: ReadableStreamDefaultReader; + private events: Record; + private paused: boolean; + private resumeCallback: ((value?: unknown) => void) | null; + private encoding: string | null; + + constructor(readableStream: ReadableStream) { + this.readableStream = readableStream; + this.reader = this.readableStream.getReader(); + this.events = { + data: [], + end: [], + error: [], + readable: [], + close: [], + pause: [], + resume: [], + }; + this.paused = false; + this.resumeCallback = null; + this.encoding = null; + } + + public on(event: string, callback: EventCallback): void { + this.events[event]?.push(callback); + } + + public off(event: string, callback: EventCallback): void { + this.events[event] = this.events[event]?.filter((cb) => cb !== callback); + } + + public pipe( + dest: Node18UniversalStreamWrapper | Writable | WritableStream + ): Node18UniversalStreamWrapper | Writable | WritableStream { + this.on("data", async (chunk) => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._write(chunk); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.write(chunk).then(() => writer.releaseLock()); + } else { + dest.write(chunk); + } + }); + + this.on("end", async () => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._end(); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.close(); + } else { + dest.end(); + } + }); + + this.on("error", async (error) => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._error(error); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.abort(error); + } else { + dest.destroy(error); + } + }); + + this._startReading(); + + return dest; + } + + public pipeTo( + dest: Node18UniversalStreamWrapper | Writable | WritableStream + ): Node18UniversalStreamWrapper | Writable | WritableStream { + return this.pipe(dest); + } + + public unpipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): void { + this.off("data", async (chunk) => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._write(chunk); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.write(chunk).then(() => writer.releaseLock()); + } else { + dest.write(chunk); + } + }); + + this.off("end", async () => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._end(); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.close(); + } else { + dest.end(); + } + }); + + this.off("error", async (error) => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._error(error); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.abort(error); + } else { + dest.destroy(error); + } + }); + } + + public destroy(error?: Error): void { + this.reader + .cancel(error) + .then(() => { + this._emit("close"); + }) + .catch((err) => { + this._emit("error", err); + }); + } + + public pause(): void { + this.paused = true; + this._emit("pause"); + } + + public resume(): void { + if (this.paused) { + this.paused = false; + this._emit("resume"); + if (this.resumeCallback) { + this.resumeCallback(); + this.resumeCallback = null; + } + } + } + + public get isPaused(): boolean { + return this.paused; + } + + public async read(): Promise { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + + if (done) { + return undefined; + } + return value; + } + + public setEncoding(encoding: string): void { + this.encoding = encoding; + } + + public async text(): Promise { + const chunks: ReadFormat[] = []; + + while (true) { + const { done, value } = await this.reader.read(); + if (done) { + break; + } + if (value) { + chunks.push(value); + } + } + + const decoder = new TextDecoder(this.encoding || "utf-8"); + return decoder.decode(await new Blob(chunks).arrayBuffer()); + } + + public async json(): Promise { + const text = await this.text(); + return JSON.parse(text); + } + + private _write(chunk: ReadFormat): void { + this._emit("data", chunk); + } + + private _end(): void { + this._emit("end"); + } + + private _error(error: any): void { + this._emit("error", error); + } + + private _emit(event: string, data?: any): void { + if (this.events[event]) { + for (const callback of this.events[event] || []) { + callback(data); + } + } + } + + private async _startReading(): Promise { + try { + this._emit("readable"); + while (true) { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + this._emit("end"); + this._emit("close"); + break; + } + if (value) { + this._emit("data", value); + } + } + } catch (error) { + this._emit("error", error); + } + } + + [Symbol.asyncIterator](): AsyncIterableIterator { + return { + next: async () => { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + return { done: true, value: undefined }; + } + return { done: false, value }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } +} diff --git a/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts b/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts new file mode 100644 index 00000000..ba5f7276 --- /dev/null +++ b/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts @@ -0,0 +1,106 @@ +import type { Readable, Writable } from "readable-stream"; +import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; + +export class NodePre18StreamWrapper implements StreamWrapper { + private readableStream: Readable; + private encoding: string | undefined; + + constructor(readableStream: Readable) { + this.readableStream = readableStream; + } + + public on(event: string, callback: EventCallback): void { + this.readableStream.on(event, callback); + } + + public off(event: string, callback: EventCallback): void { + this.readableStream.off(event, callback); + } + + public pipe(dest: Writable): Writable { + this.readableStream.pipe(dest); + return dest; + } + + public pipeTo(dest: Writable): Writable { + return this.pipe(dest); + } + + public unpipe(dest?: Writable): void { + if (dest) { + this.readableStream.unpipe(dest); + } else { + this.readableStream.unpipe(); + } + } + + public destroy(error?: Error): void { + this.readableStream.destroy(error); + } + + public pause(): void { + this.readableStream.pause(); + } + + public resume(): void { + this.readableStream.resume(); + } + + public get isPaused(): boolean { + return this.readableStream.isPaused(); + } + + public async read(): Promise { + return new Promise((resolve, reject) => { + const chunk = this.readableStream.read(); + if (chunk) { + resolve(chunk); + } else { + this.readableStream.once("readable", () => { + const chunk = this.readableStream.read(); + resolve(chunk); + }); + this.readableStream.once("error", reject); + } + }); + } + + public setEncoding(encoding?: string): void { + this.readableStream.setEncoding(encoding as BufferEncoding); + this.encoding = encoding; + } + + public async text(): Promise { + const chunks: Uint8Array[] = []; + const encoder = new TextEncoder(); + this.readableStream.setEncoding((this.encoding || "utf-8") as BufferEncoding); + + for await (const chunk of this.readableStream) { + chunks.push(encoder.encode(chunk)); + } + + const decoder = new TextDecoder(this.encoding || "utf-8"); + return decoder.decode(Buffer.concat(chunks)); + } + + public async json(): Promise { + const text = await this.text(); + return JSON.parse(text); + } + + public [Symbol.asyncIterator](): AsyncIterableIterator { + const readableStream = this.readableStream; + const iterator = readableStream[Symbol.asyncIterator](); + + // Create and return an async iterator that yields buffers + return { + async next(): Promise> { + const { value, done } = await iterator.next(); + return { value: value as Buffer, done }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } +} diff --git a/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts b/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts new file mode 100644 index 00000000..263af009 --- /dev/null +++ b/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts @@ -0,0 +1,243 @@ +import { StreamWrapper } from "./chooseStreamWrapper"; + +type EventCallback = (data?: any) => void; + +export class UndiciStreamWrapper + implements StreamWrapper | WritableStream, ReadFormat> +{ + private readableStream: ReadableStream; + private reader: ReadableStreamDefaultReader; + private events: Record; + private paused: boolean; + private resumeCallback: ((value?: unknown) => void) | null; + private encoding: string | null; + + constructor(readableStream: ReadableStream) { + this.readableStream = readableStream; + this.reader = this.readableStream.getReader(); + this.events = { + data: [], + end: [], + error: [], + readable: [], + close: [], + pause: [], + resume: [], + }; + this.paused = false; + this.resumeCallback = null; + this.encoding = null; + } + + public on(event: string, callback: EventCallback): void { + this.events[event]?.push(callback); + } + + public off(event: string, callback: EventCallback): void { + this.events[event] = this.events[event]?.filter((cb) => cb !== callback); + } + + public pipe( + dest: UndiciStreamWrapper | WritableStream + ): UndiciStreamWrapper | WritableStream { + this.on("data", (chunk) => { + if (dest instanceof UndiciStreamWrapper) { + dest._write(chunk); + } else { + const writer = dest.getWriter(); + writer.write(chunk).then(() => writer.releaseLock()); + } + }); + + this.on("end", () => { + if (dest instanceof UndiciStreamWrapper) { + dest._end(); + } else { + const writer = dest.getWriter(); + writer.close(); + } + }); + + this.on("error", (error) => { + if (dest instanceof UndiciStreamWrapper) { + dest._error(error); + } else { + const writer = dest.getWriter(); + writer.abort(error); + } + }); + + this._startReading(); + + return dest; + } + + public pipeTo( + dest: UndiciStreamWrapper | WritableStream + ): UndiciStreamWrapper | WritableStream { + return this.pipe(dest); + } + + public unpipe(dest: UndiciStreamWrapper | WritableStream): void { + this.off("data", (chunk) => { + if (dest instanceof UndiciStreamWrapper) { + dest._write(chunk); + } else { + const writer = dest.getWriter(); + writer.write(chunk).then(() => writer.releaseLock()); + } + }); + + this.off("end", () => { + if (dest instanceof UndiciStreamWrapper) { + dest._end(); + } else { + const writer = dest.getWriter(); + writer.close(); + } + }); + + this.off("error", (error) => { + if (dest instanceof UndiciStreamWrapper) { + dest._error(error); + } else { + const writer = dest.getWriter(); + writer.abort(error); + } + }); + } + + public destroy(error?: Error): void { + this.reader + .cancel(error) + .then(() => { + this._emit("close"); + }) + .catch((err) => { + this._emit("error", err); + }); + } + + public pause(): void { + this.paused = true; + this._emit("pause"); + } + + public resume(): void { + if (this.paused) { + this.paused = false; + this._emit("resume"); + if (this.resumeCallback) { + this.resumeCallback(); + this.resumeCallback = null; + } + } + } + + public get isPaused(): boolean { + return this.paused; + } + + public async read(): Promise { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + return undefined; + } + return value; + } + + public setEncoding(encoding: string): void { + this.encoding = encoding; + } + + public async text(): Promise { + const chunks: BlobPart[] = []; + + while (true) { + const { done, value } = await this.reader.read(); + if (done) { + break; + } + if (value) { + chunks.push(value); + } + } + + const decoder = new TextDecoder(this.encoding || "utf-8"); + return decoder.decode(await new Blob(chunks).arrayBuffer()); + } + + public async json(): Promise { + const text = await this.text(); + return JSON.parse(text); + } + + private _write(chunk: ReadFormat): void { + this._emit("data", chunk); + } + + private _end(): void { + this._emit("end"); + } + + private _error(error: any): void { + this._emit("error", error); + } + + private _emit(event: string, data?: any): void { + if (this.events[event]) { + for (const callback of this.events[event] || []) { + callback(data); + } + } + } + + private async _startReading(): Promise { + try { + this._emit("readable"); + while (true) { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + this._emit("end"); + this._emit("close"); + break; + } + if (value) { + this._emit("data", value); + } + } + } catch (error) { + this._emit("error", error); + } + } + + [Symbol.asyncIterator](): AsyncIterableIterator { + return { + next: async () => { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + return { done: true, value: undefined }; + } + return { done: false, value }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } +} diff --git a/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts b/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts new file mode 100644 index 00000000..2abd6b2b --- /dev/null +++ b/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts @@ -0,0 +1,33 @@ +import type { Readable } from "readable-stream"; +import { RUNTIME } from "../../runtime"; + +export type EventCallback = (data?: any) => void; + +export interface StreamWrapper { + setEncoding(encoding?: string): void; + on(event: string, callback: EventCallback): void; + off(event: string, callback: EventCallback): void; + pipe(dest: WritableStream): WritableStream; + pipeTo(dest: WritableStream): WritableStream; + unpipe(dest?: WritableStream): void; + destroy(error?: Error): void; + pause(): void; + resume(): void; + get isPaused(): boolean; + read(): Promise; + text(): Promise; + json(): Promise; + [Symbol.asyncIterator](): AsyncIterableIterator; +} + +export async function chooseStreamWrapper(responseBody: any): Promise>> { + if (RUNTIME.type === "node" && RUNTIME.parsedVersion != null && RUNTIME.parsedVersion >= 18) { + return new (await import("./Node18UniversalStreamWrapper")).Node18UniversalStreamWrapper( + responseBody as ReadableStream + ); + } else if (RUNTIME.type !== "node" && typeof fetch === "function") { + return new (await import("./UndiciStreamWrapper")).UndiciStreamWrapper(responseBody as ReadableStream); + } else { + return new (await import("./NodePre18StreamWrapper")).NodePre18StreamWrapper(responseBody as Readable); + } +} diff --git a/src/core/index.ts b/src/core/index.ts new file mode 100644 index 00000000..eaa51053 --- /dev/null +++ b/src/core/index.ts @@ -0,0 +1,5 @@ +export * from "./fetcher"; +export * from "./auth"; +export * from "./runtime"; +export * from "./utils"; +export * from "./pagination"; diff --git a/src/core/pagination/Page.ts b/src/core/pagination/Page.ts new file mode 100644 index 00000000..07c6796e --- /dev/null +++ b/src/core/pagination/Page.ts @@ -0,0 +1,67 @@ +/** + * A page of results from a paginated API. + * + * @template T The type of the items in the page. + */ +export class Page implements AsyncIterable { + public data: T[]; + + private response: unknown; + private _hasNextPage: (response: unknown) => boolean; + private getItems: (response: unknown) => T[]; + private loadNextPage: (response: unknown) => Promise; + + constructor({ + response, + hasNextPage, + getItems, + loadPage, + }: { + response: unknown; + hasNextPage: (response: unknown) => boolean; + getItems: (response: unknown) => T[]; + loadPage: (response: unknown) => Promise; + }) { + this.response = response; + this.data = getItems(response); + this._hasNextPage = hasNextPage; + this.getItems = getItems; + this.loadNextPage = loadPage; + } + + /** + * Retrieves the next page + * @returns this + */ + public async getNextPage(): Promise { + this.response = await this.loadNextPage(this.response); + this.data = this.getItems(this.response); + return this; + } + + /** + * @returns whether there is a next page to load + */ + public hasNextPage(): boolean { + return this._hasNextPage(this.response); + } + + private async *iterMessages(): AsyncGenerator { + for (const item of this.data) { + yield item; + } + + while (this.hasNextPage()) { + await this.getNextPage(); + for (const item of this.data) { + yield item; + } + } + } + + async *[Symbol.asyncIterator](): AsyncIterator { + for await (const message of this.iterMessages()) { + yield message; + } + } +} diff --git a/src/core/pagination/Pageable.ts b/src/core/pagination/Pageable.ts new file mode 100644 index 00000000..befce635 --- /dev/null +++ b/src/core/pagination/Pageable.ts @@ -0,0 +1,16 @@ +import { Page } from "./Page"; + +export declare namespace Pageable { + interface Args { + response: Response; + hasNextPage: (response: Response) => boolean; + getItems: (response: Response) => Item[]; + loadPage: (response: Response) => Promise; + } +} + +export class Pageable extends Page { + constructor(args: Pageable.Args) { + super(args as any); + } +} diff --git a/src/core/pagination/index.ts b/src/core/pagination/index.ts new file mode 100644 index 00000000..2ceb2684 --- /dev/null +++ b/src/core/pagination/index.ts @@ -0,0 +1,2 @@ +export { Page } from "./Page"; +export { Pageable } from "./Pageable"; diff --git a/src/core/runtime/index.ts b/src/core/runtime/index.ts new file mode 100644 index 00000000..5c76dbb1 --- /dev/null +++ b/src/core/runtime/index.ts @@ -0,0 +1 @@ +export { RUNTIME } from "./runtime"; diff --git a/src/core/runtime/runtime.ts b/src/core/runtime/runtime.ts new file mode 100644 index 00000000..4d0687e8 --- /dev/null +++ b/src/core/runtime/runtime.ts @@ -0,0 +1,126 @@ +interface DenoGlobal { + version: { + deno: string; + }; +} + +interface BunGlobal { + version: string; +} + +declare const Deno: DenoGlobal; +declare const Bun: BunGlobal; + +/** + * A constant that indicates whether the environment the code is running is a Web Browser. + */ +const isBrowser = typeof window !== "undefined" && typeof window.document !== "undefined"; + +/** + * A constant that indicates whether the environment the code is running is a Web Worker. + */ +const isWebWorker = + typeof self === "object" && + // @ts-ignore + typeof self?.importScripts === "function" && + (self.constructor?.name === "DedicatedWorkerGlobalScope" || + self.constructor?.name === "ServiceWorkerGlobalScope" || + self.constructor?.name === "SharedWorkerGlobalScope"); + +/** + * A constant that indicates whether the environment the code is running is Deno. + */ +const isDeno = + typeof Deno !== "undefined" && typeof Deno.version !== "undefined" && typeof Deno.version.deno !== "undefined"; + +/** + * A constant that indicates whether the environment the code is running is Bun.sh. + */ +const isBun = typeof Bun !== "undefined" && typeof Bun.version !== "undefined"; + +/** + * A constant that indicates whether the environment the code is running is Node.JS. + */ +const isNode = + typeof process !== "undefined" && + Boolean(process.version) && + Boolean(process.versions?.node) && + // Deno spoofs process.versions.node, see https://deno.land/std@0.177.0/node/process.ts?s=versions + !isDeno && + !isBun; + +/** + * A constant that indicates whether the environment the code is running is in React-Native. + * https://github.com/facebook/react-native/blob/main/packages/react-native/Libraries/Core/setUpNavigator.js + */ +const isReactNative = typeof navigator !== "undefined" && navigator?.product === "ReactNative"; + +/** + * A constant that indicates whether the environment the code is running is Cloudflare. + * https://developers.cloudflare.com/workers/runtime-apis/web-standards/#navigatoruseragent + */ +const isCloudflare = typeof globalThis !== "undefined" && globalThis?.navigator?.userAgent === "Cloudflare-Workers"; + +/** + * A constant that indicates which environment and version the SDK is running in. + */ +export const RUNTIME: Runtime = evaluateRuntime(); + +export interface Runtime { + type: "browser" | "web-worker" | "deno" | "bun" | "node" | "react-native" | "unknown" | "workerd"; + version?: string; + parsedVersion?: number; +} + +function evaluateRuntime(): Runtime { + if (isBrowser) { + return { + type: "browser", + version: window.navigator.userAgent, + }; + } + + if (isCloudflare) { + return { + type: "workerd", + }; + } + + if (isWebWorker) { + return { + type: "web-worker", + }; + } + + if (isDeno) { + return { + type: "deno", + version: Deno.version.deno, + }; + } + + if (isBun) { + return { + type: "bun", + version: Bun.version, + }; + } + + if (isNode) { + return { + type: "node", + version: process.versions.node, + parsedVersion: Number(process.versions.node.split(".")[0]), + }; + } + + if (isReactNative) { + return { + type: "react-native", + }; + } + + return { + type: "unknown", + }; +} diff --git a/src/core/utils/index.ts b/src/core/utils/index.ts new file mode 100644 index 00000000..b168f599 --- /dev/null +++ b/src/core/utils/index.ts @@ -0,0 +1 @@ +export { setObjectProperty } from "./setObjectProperty"; diff --git a/src/core/utils/setObjectProperty.ts b/src/core/utils/setObjectProperty.ts new file mode 100644 index 00000000..5528af24 --- /dev/null +++ b/src/core/utils/setObjectProperty.ts @@ -0,0 +1,43 @@ +/** + * Sets the value at path of object. If a portion of path doesn’t exist it’s created. This is + * inspired by Lodash's set function, but is simplified to accommodate our use case. + * For more details, see https://lodash.com/docs/4.17.15#set. + * + * @param object The object to modify. + * @param path The path of the property to set. + * @param value The value to set. + * @return Returns object. + */ +export function setObjectProperty(object: T, path: string, value: any): T { + if (object == null) { + return object; + } + + const keys: string[] = path.split("."); + if (keys.length === 0) { + // Invalid path; do nothing. + return object; + } + + let current: Record = object; + for (let i = 0; i < keys.length - 1; i++) { + const key = keys[i]; + if (key == null) { + // Unreachable. + continue; + } + if (!current[key] || typeof current[key] !== "object") { + current[key] = {}; + } + current = current[key] as Record; + } + + const lastKey = keys[keys.length - 1]; + if (lastKey == null) { + // Unreachable. + return object; + } + + current[lastKey] = value; + return object; +} diff --git a/src/environments.ts b/src/environments.ts new file mode 100644 index 00000000..d2816275 --- /dev/null +++ b/src/environments.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export const IntercomEnvironment = { + UsProduction: "https://api.intercom.io", + EuProduction: "https://api.eu.intercom.io", + AuProduction: "https://api.au.intercom.io", +} as const; + +export type IntercomEnvironment = + | typeof IntercomEnvironment.UsProduction + | typeof IntercomEnvironment.EuProduction + | typeof IntercomEnvironment.AuProduction; diff --git a/src/errors/IntercomError.ts b/src/errors/IntercomError.ts new file mode 100644 index 00000000..898a54a6 --- /dev/null +++ b/src/errors/IntercomError.ts @@ -0,0 +1,45 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export class IntercomError extends Error { + readonly statusCode?: number; + readonly body?: unknown; + + constructor({ message, statusCode, body }: { message?: string; statusCode?: number; body?: unknown }) { + super(buildMessage({ message, statusCode, body })); + Object.setPrototypeOf(this, IntercomError.prototype); + if (statusCode != null) { + this.statusCode = statusCode; + } + + if (body !== undefined) { + this.body = body; + } + } +} + +function buildMessage({ + message, + statusCode, + body, +}: { + message: string | undefined; + statusCode: number | undefined; + body: unknown | undefined; +}): string { + let lines: string[] = []; + if (message != null) { + lines.push(message); + } + + if (statusCode != null) { + lines.push(`Status code: ${statusCode.toString()}`); + } + + if (body != null) { + lines.push(`Body: ${JSON.stringify(body, undefined, 2)}`); + } + + return lines.join("\n"); +} diff --git a/src/errors/IntercomTimeoutError.ts b/src/errors/IntercomTimeoutError.ts new file mode 100644 index 00000000..52bd429f --- /dev/null +++ b/src/errors/IntercomTimeoutError.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export class IntercomTimeoutError extends Error { + constructor(message: string) { + super(message); + Object.setPrototypeOf(this, IntercomTimeoutError.prototype); + } +} diff --git a/src/errors/index.ts b/src/errors/index.ts new file mode 100644 index 00000000..25abf2ea --- /dev/null +++ b/src/errors/index.ts @@ -0,0 +1,2 @@ +export { IntercomError } from "./IntercomError"; +export { IntercomTimeoutError } from "./IntercomTimeoutError"; diff --git a/src/index.ts b/src/index.ts new file mode 100644 index 00000000..5394f30c --- /dev/null +++ b/src/index.ts @@ -0,0 +1,4 @@ +export * as Intercom from "./api"; +export { IntercomClient } from "./Client"; +export { IntercomEnvironment } from "./environments"; +export { IntercomError, IntercomTimeoutError } from "./errors"; diff --git a/src/version.ts b/src/version.ts new file mode 100644 index 00000000..7ba3a938 --- /dev/null +++ b/src/version.ts @@ -0,0 +1 @@ +export const SDK_VERSION = "6.0.0"; diff --git a/test/integration/admins.test.ts b/test/integration/admins.test.ts deleted file mode 100644 index 6e258b60..00000000 --- a/test/integration/admins.test.ts +++ /dev/null @@ -1,49 +0,0 @@ -import { token } from './utils/config'; -import { Client } from '../../lib'; -import assert from 'assert'; - -describe('Admins', () => { - let adminId: string; - const client = new Client({ - tokenAuth: { token }, - }); - - it('list', async () => { - const response = await client.admins.list(); - - adminId = response.admins[0].id; - - assert.notEqual(response, undefined); - }); - it('find', async () => { - const response = await client.admins.find({ id: adminId }); - - assert.notEqual(response, undefined); - }); - it('listAllActivityLogs', async () => { - const response = await client.admins.listAllActivityLogs({ - after: new Date('2021-12-12'), - before: new Date('2022-01-01'), - }); - - assert.notEqual(response, undefined); - }); - it('away - ON', async () => { - const response = await client.admins.away({ - adminId, - enableAwayMode: true, - enableReassignMode: true, - }); - - assert.notEqual(response, undefined); - }); - it('away - OFF', async () => { - const response = await client.admins.away({ - adminId, - enableAwayMode: false, - enableReassignMode: false, - }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/articles.test.ts b/test/integration/articles.test.ts deleted file mode 100644 index 9839a5bb..00000000 --- a/test/integration/articles.test.ts +++ /dev/null @@ -1,69 +0,0 @@ -import { Client } from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; -import { randomString } from './utils/random'; - -describe('Articles', () => { - let newArticleId: string; - let parentId: number; - let adminId: number; - - before(async () => { - const randomCollections = await client.helpCenter.collections.list({ - perPage: 1, - }); - const randomAdmins = await client.admins.list(); - - parentId = parseInt(randomCollections.data[0].id, 10); - adminId = parseInt(randomAdmins.admins[0].id, 10); - }); - - const client = new Client({ tokenAuth: { token } }); - - it('create', async () => { - const response = await client.articles.create({ - title: randomString(), - description: randomString(), - body: 'Eins Zwei', - authorId: adminId, - state: 'draft', - parentId, - parentType: 'collection', - translatedContent: { - fr: { - title: 'Allez les verts', - description: 'French description', - body: '

French body in html

', - author_id: adminId, - state: 'draft', - }, - }, - }); - - newArticleId = response.id; - assert.notEqual(response, undefined); - }); - it('find', async () => { - const response = await client.articles.find({ id: newArticleId }); - - assert.notEqual(response, undefined); - }); - it('update', async () => { - const response = await client.articles.update({ - id: newArticleId, - title: 'Biba & Boba', - }); - - assert.notEqual(response, undefined); - }); - it('delete', async () => { - const response = await client.articles.delete({ id: newArticleId }); - - assert.notEqual(response, undefined); - }); - it('list', async () => { - const response = await client.articles.list({ page: 1, perPage: 12 }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/companies.test.ts b/test/integration/companies.test.ts deleted file mode 100644 index 0be07f80..00000000 --- a/test/integration/companies.test.ts +++ /dev/null @@ -1,120 +0,0 @@ -import { Client, CompanyObject, Order } from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; -import { dateToUnixTimestamp } from '../../lib/util/time'; - -describe('Companies', () => { - let createdCompany: CompanyObject; - let contactId: string; - - before(async () => { - const randomContacts = await client.contacts.list({ - perPage: 1, - }); - - contactId = randomContacts.data[0].id; - }); - - const client = new Client({ tokenAuth: { token } }); - - it('create', async () => { - const response = await client.companies.create({ - createdAt: dateToUnixTimestamp(new Date()), - companyId: '46029', - name: 'BestCompanyInc.', - monthlySpend: 9001, - plan: '1. Get pizzaid', - size: 62049, - website: 'http://the-best.one', - industry: 'The Best One', - customAttributes: {}, - }); - - createdCompany = response; - - assert.notEqual(response, undefined); - }); - it('update', async () => { - const response = await client.companies.update({ - createdAt: dateToUnixTimestamp(new Date()), - companyId: createdCompany.id, - name: 'BestCompanyInc', - monthlySpend: 9001, - plan: '1. Get pizzaid', - size: 62049, - website: 'http://the-best.one', - industry: 'The Best One', - customAttributes: {}, - }); - - assert.notEqual(response, undefined); - }); - it('find - by id', async () => { - const response = await client.companies.find({ - companyId: createdCompany.company_id, - }); - - assert.notEqual(response, undefined); - }); - // TO-DO: Create issue on API. Doesn't work on API.. - it.skip('find - by name', async () => { - const response = await client.companies.find({ - name: 'BestCompanyInc', - }); - - assert.notEqual(response, undefined); - }); - it('list', async () => { - const response = await client.companies.list({ - page: 1, - perPage: 35, - order: Order.DESC, - }); - - assert.notEqual(response, undefined); - }); - it('scroll - infinite one', async () => { - const response = await client.companies.scroll.each({}); - - assert.notEqual(response, undefined); - }); - it('attachContact', async () => { - const response = await client.companies.attachContact({ - contactId, - companyId: createdCompany.id, - }); - - assert.notEqual(response, undefined); - }); - it('detachContact', async () => { - const response = await client.companies.detachContact({ - contactId, - companyId: createdCompany.id, - }); - - assert.notEqual(response, undefined); - }); - it('listAttachedContacts', async () => { - const response = await client.companies.listAttachedContacts({ - companyId: createdCompany.id, - page: 1, - perPage: 25, - }); - - assert.notEqual(response, undefined); - }); - it('listAttachedSegments', async () => { - const response = await client.companies.listAttachedSegments({ - companyId: createdCompany.id, - }); - - assert.notEqual(response, undefined); - }); - it('delete', async () => { - const response = await client.companies.delete({ - id: createdCompany.id, - }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/contacts.test.ts b/test/integration/contacts.test.ts deleted file mode 100644 index 938811b7..00000000 --- a/test/integration/contacts.test.ts +++ /dev/null @@ -1,113 +0,0 @@ -import { Client, ContactObject } from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; -import { randomString } from './utils/random'; - -describe('Contacts', () => { - let randomContact: ContactObject; - let createdUser: ContactObject; - let createdLead: ContactObject; - let mergedLeadAndUser: ContactObject; - - const client = new Client({ tokenAuth: { token } }); - - it('list', async () => { - const response = await client.contacts.list({ perPage: 5 }); - - randomContact = response && response.data[2]; - - assert.notEqual(response, undefined); - }); - it('createUser', async () => { - const response = await client.contacts.createUser({ - externalId: randomString(), - phone: randomContact.phone, - }); - - createdUser = response; - - assert.notEqual(response, undefined); - }); - it('createLead', async () => { - const response = await client.contacts.createLead({ - name: 'Roman Bowling', - }); - - createdLead = response; - - assert.notEqual(response, undefined); - }); - it('find - by id', async () => { - const response = await client.contacts.find({ - id: randomContact.id, - }); - - assert.notEqual(response, undefined); - }); - it('update', async () => { - const response = await client.contacts.update({ - id: randomContact.id, - name: 'Nico Bellic', - }); - - assert.notEqual(response, undefined); - }); - it('archive', async () => { - const response = await client.contacts.archive({ - id: randomContact.id, - }); - assert.notEqual(response, undefined); - }); - it('unarchive', async () => { - const response = await client.contacts.unarchive({ - id: randomContact.id, - }); - - assert.notEqual(response, undefined); - }); - it('mergeLeadInUser', async () => { - const response = await client.contacts.mergeLeadInUser({ - leadId: createdLead && createdLead.id, - userId: createdUser && createdUser.id, - }); - - mergedLeadAndUser = response; - - assert.notEqual(response, undefined); - }); - it('delete', async () => { - const response = await client.contacts.delete({ - id: mergedLeadAndUser.id, - }); - - assert.notEqual(response, undefined); - }); - it('listAttachedCompanies', async () => { - const response = await client.contacts.listAttachedCompanies({ - id: randomContact.id, - }); - - assert.notEqual(response, undefined); - }); - it('listAttachedEmailSubscriptions', async () => { - const response = await client.contacts.listAttachedEmailSubscriptions({ - id: randomContact.id, - }); - - assert.notEqual(response, undefined); - }); - it('listAttachedSegments', async () => { - const response = await client.contacts.listAttachedSegments({ - id: randomContact.id, - }); - - assert.notEqual(response, undefined); - }); - it('listAttachedTags', async () => { - const response = await client.contacts.listAttachedTags({ - id: randomContact.id, - }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/conversations.test.ts b/test/integration/conversations.test.ts deleted file mode 100644 index 7954e926..00000000 --- a/test/integration/conversations.test.ts +++ /dev/null @@ -1,211 +0,0 @@ -import { - Client, - AssignToConversationUserType, - RedactConversationPartType, - ReplyToConversationMessageType, - Operators, - ContactObject, - ConversationObject, - MessageObject, - ContactType, -} from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; -import { randomString } from './utils/random'; - -describe('Conversations', () => { - let user: ContactObject; - let secondUser: ContactObject; - let leadUser: ContactObject; - let createdConversation: MessageObject; - let foundConversation: ConversationObject; - - let adminId: string; - let anotherAdminId: string; - - const client = new Client({ tokenAuth: { token } }); - - before(async () => { - const admins = await client.admins.list(); - - const adminList = admins.admins.filter((admin) => admin.has_inbox_seat); - // Only admins with inbox seat can interact with conversations. - adminId = adminList[0].id; - anotherAdminId = adminList[1].id; - user = await client.contacts.createUser({ - externalId: randomString(), - name: 'Baba Booey', - }); - secondUser = await client.contacts.createUser({ - externalId: randomString(), - name: 'Babushka Boy', - email: 'babushka_boy@bababooey.com', - }); - leadUser = await client.contacts.createLead({ - name: 'Babushka Lead', - email: 'babushka_lead@bababooey.com', - }); - }); - - it('create conversation with user as default', async () => { - const response = await client.conversations.create({ - userId: user.id, - body: 'Raz-dwa-try kalyna, czorniawaja diwczyna', - }); - - createdConversation = response; - - assert.notEqual(response, undefined); - }); - - it('create conversation with user', async () => { - const response = await client.conversations.create({ - userId: user.id, - body: 'Raz-dwa-try kalyna, czorniawaja diwczyna', - type: ContactType.USER, - }); - - createdConversation = response; - - assert.notEqual(response, undefined); - }); - - it('create conversation with lead', async () => { - const response = await client.conversations.create({ - userId: leadUser.id, - body: 'Raz-dwa-try kalyna, czorniawaja diwczyna', - type: ContactType.LEAD, - }); - - assert.notEqual(response, undefined); - }); - - it('find - by id', async () => { - const response = await client.conversations.find({ - id: createdConversation.conversation_id as string, - }); - - foundConversation = response; - - assert.notEqual(response, undefined); - }); - it('update', async () => { - const response = await client.conversations.update({ - id: foundConversation.id, - markRead: false, - }); - - assert.notEqual(response, undefined); - }); - // TO-DO: Fix on API side. - it.skip('replyToLastConversationAsAdmin', async () => { - const response = await client.conversations.replyByLastAsAdmin({ - adminId, - messageType: ReplyToConversationMessageType.COMMENT, - body: 'test', - }); - assert.notEqual(response, undefined); - }); - it('replyByIdAsAdmin', async () => { - const response = await client.conversations.replyByIdAsAdmin({ - id: foundConversation.id, - adminId, - body: 'test', - messageType: ReplyToConversationMessageType.COMMENT, - }); - - assert.notEqual(response, undefined); - }); - it('replyByIdAsUser', async () => { - const response = await client.conversations.replyByIdAsUser({ - id: foundConversation.id, - intercomUserId: user.id, - body: '*click* Nice!', - }); - - foundConversation = response; - - assert.notEqual(response, undefined); - }); - it('assign', async () => { - const response = await client.conversations.assign({ - id: foundConversation.id, - assigneeId: anotherAdminId, - adminId, - type: AssignToConversationUserType.ADMIN, - }); - assert.notEqual(response, undefined); - }); - it('snooze', async () => { - const response = await client.conversations.snooze({ - id: foundConversation.id, - adminId, - snoozedUntil: `${new Date('2040.06.19').getTime() / 1000}`, - }); - - assert.notEqual(response, undefined); - }); - it('open', async () => { - const response = await client.conversations.open({ - id: foundConversation.id, - adminId, - }); - - assert.notEqual(response, undefined); - }); - it('attachContactAsAdmin', async () => { - const response = await client.conversations.attachContactAsAdmin({ - id: foundConversation.id, - adminId, - customer: { intercomUserId: secondUser.id }, - }); - - assert.notEqual(response, undefined); - }); - it('detachContactAsAdmin', async () => { - const response = await client.conversations.detachContactAsAdmin({ - conversationId: foundConversation.id, - adminId, - contactId: user.id, - }); - - assert.notEqual(response, undefined); - }); - it('redactConversationPart', async () => { - const response = await client.conversations.redactConversationPart({ - conversationId: foundConversation.id, - conversationPartId: - foundConversation.conversation_parts.conversation_parts[2].id, - type: RedactConversationPartType.CONVERSATION_PART, - }); - - assert.notEqual(response, undefined); - }); - it('close', async () => { - const response = await client.conversations.close({ - id: foundConversation.id, - adminId, - body: 'Hasta la vista, baby', - }); - - assert.notEqual(response, undefined); - }); - it('search', async () => { - const response = await client.conversations.search({ - data: { - query: { - operator: Operators.AND, - value: [ - { - field: 'id', - operator: Operators.NOT_EQUALS, - value: '123', - }, - ], - }, - }, - }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/counts.test.ts b/test/integration/counts.test.ts deleted file mode 100644 index a7da50d4..00000000 --- a/test/integration/counts.test.ts +++ /dev/null @@ -1,48 +0,0 @@ -import { Client } from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; - -describe('Counts', () => { - const client = new Client({ tokenAuth: { token } }); - - it('forApp', async () => { - const response = await client.counts.forApp(); - - assert.notEqual(response, undefined); - }); - it('countConversation', async () => { - const response = await client.counts.countConversation(); - - assert.notEqual(response, undefined); - }); - it('countAdminConversation', async () => { - const response = await client.counts.countAdminConversation(); - - assert.notEqual(response, undefined); - }); - it('countUserSegment', async () => { - const response = await client.counts.countUserSegment(); - - assert.notEqual(response, undefined); - }); - it('countUserTag', async () => { - const response = await client.counts.countUserTag(); - - assert.notEqual(response, undefined); - }); - it('countCompanySegment', async () => { - const response = await client.counts.countCompanySegment(); - - assert.notEqual(response, undefined); - }); - it('countCompanyTag', async () => { - const response = await client.counts.countCompanyTag(); - - assert.notEqual(response, undefined); - }); - it('countCompanyUser', async () => { - const response = await client.counts.countCompanyUser(); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/dataAttributes.test.ts b/test/integration/dataAttributes.test.ts deleted file mode 100644 index d0b055df..00000000 --- a/test/integration/dataAttributes.test.ts +++ /dev/null @@ -1,46 +0,0 @@ -import { Client, DataAttributeObject, DataType, ModelType } from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; -import { randomInt } from './utils/random'; - -describe('Data Attributes', () => { - let createdDataAttribute: DataAttributeObject; - - const client = new Client({ tokenAuth: { token } }); - - xit('create', async () => { - // The workspace we test on has hit the CDA limit, so we can't create any more - // for now. We should reenable this test once we have a new workspace. - const response = await client.dataAttributes.create({ - name: `Bebech${randomInt(0, 999)},${randomInt( - randomInt(0, 999) - )},${randomInt(0, 999)},${randomInt(randomInt(0, 999))}`, - model: ModelType.CONTACT, - dataType: DataType.STRING, - description: 'Dummy description', - options: [{ value: 'yey' }, { value: 'yoy' }], - }); - - createdDataAttribute = response; - - assert.notEqual(response, undefined); - }); - xit('update', async () => { - const response = await client.dataAttributes.update({ - id: createdDataAttribute.id, - archived: false, - description: 'Woo-aaa', - options: [{ value: 'yey' }, { value: 'yoy' }], - }); - - assert.notEqual(response, undefined); - }); - it('list', async () => { - const response = await client.dataAttributes.list({ - includeArchived: true, - model: ModelType.CONVERSATION, - }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/dataExport.test.ts b/test/integration/dataExport.test.ts deleted file mode 100644 index 475a5fa0..00000000 --- a/test/integration/dataExport.test.ts +++ /dev/null @@ -1,30 +0,0 @@ -import { Client } from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; - -describe('dataExport', () => { - const client = new Client({ tokenAuth: { token } }); - let dataExport: string; - - it('create', async () => { - const response = await client.dataExport.create({ - createdAtAfter: 1670000000, - createdAtBefore: 1670940528, - }); - dataExport = response.job_identifier; - - assert.notEqual(response, undefined); - }); - - it('find', async () => { - const response = await client.dataExport.find({ id: dataExport }); - - assert.notEqual(response, undefined); - }); - - it('delete', async () => { - const response = await client.dataExport.cancel({ id: dataExport }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/events.test.ts b/test/integration/events.test.ts deleted file mode 100644 index 1157fbc5..00000000 --- a/test/integration/events.test.ts +++ /dev/null @@ -1,61 +0,0 @@ -import { Client, Operators, Role } from '../../lib'; -import { dateToUnixTimestamp } from '../../lib/util/time'; -import assert from 'assert'; -import { token } from './utils/config'; - -describe('Events', () => { - let userId: string; - - before(async () => { - const randomUsers = await client.contacts.search({ - data: { - query: { - operator: Operators.AND, - value: [ - { - field: 'role', - operator: Operators.EQUALS, - value: Role.USER, - }, - { - field: 'external_id', - operator: Operators.NOT_EQUALS, - value: null, - }, - ], - }, - pagination: { - per_page: 1, - }, - }, - }); - - userId = randomUsers.data[0].external_id; - }); - - const client = new Client({ tokenAuth: { token } }); - - it('create', async () => { - const response = await client.events.create({ - userId, - eventName: 'opinion-rejected', - createdAt: dateToUnixTimestamp(new Date()), - metadata: { - guidance: 'provided', - wereall: 'gonna make it', - price: { amount: 9001, currency: 'eur' }, - }, - }); - - assert.notEqual(response, undefined); - }); - it('listBy', async () => { - const response = await client.events.listBy({ - userId, - perPage: 2, - summary: true, - }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/helpCenter/collections.test.ts b/test/integration/helpCenter/collections.test.ts deleted file mode 100644 index 3f309bc6..00000000 --- a/test/integration/helpCenter/collections.test.ts +++ /dev/null @@ -1,56 +0,0 @@ -import { Client, CollectionObject } from '../../../lib'; -import assert from 'assert'; -import { token } from '../utils/config'; - -describe('Collections', () => { - let collection: CollectionObject; - - const client = new Client({ tokenAuth: { token } }); - - it('create', async () => { - const response = await client.helpCenter.collections.create({ - name: 'The Bruh Moment', - description: 'Bruuuuuh', - translatedContent: { - fr: { - name: 'Le Moment Frère', - description: 'Frèèèèère', - }, - }, - }); - - collection = response; - - assert.notEqual(response, undefined); - }); - it('find', async () => { - const response = await client.helpCenter.collections.find({ - id: collection.id, - }); - - assert.notEqual(response, undefined); - }); - it('update', async () => { - const response = await client.helpCenter.collections.update({ - id: collection.id, - name: 'People of future, tell us if NFTs make sense in 2026', - }); - - assert.notEqual(response, undefined); - }); - it('delete', async () => { - const response = await client.helpCenter.collections.delete({ - id: collection.id, - }); - - assert.notEqual(response, undefined); - }); - it('list', async () => { - const response = await client.helpCenter.collections.list({ - perPage: 25, - page: 1, - }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/helpCenter/sections.test.ts b/test/integration/helpCenter/sections.test.ts deleted file mode 100644 index f9a58476..00000000 --- a/test/integration/helpCenter/sections.test.ts +++ /dev/null @@ -1,66 +0,0 @@ -import { Client, SectionObject } from '../../../lib'; -import assert from 'assert'; -import { token } from '../utils/config'; -import { randomString } from '../utils/random'; - -describe('Sections', () => { - let section: SectionObject; - let parentId: string; - - before(async () => { - const randomCollections = await client.helpCenter.collections.list({ - perPage: 1, - }); - - parentId = randomCollections.data[0].id; - }); - - const client = new Client({ tokenAuth: { token } }); - - it('create', async () => { - const response = await client.helpCenter.sections.create({ - name: randomString(), - parentId, - translatedContent: { - fr: { - name: randomString(), - description: randomString(), - }, - }, - }); - - section = response; - - assert.notEqual(response, undefined); - }); - it('find', async () => { - const response = await client.helpCenter.sections.find({ - id: section.id, - }); - - assert.notEqual(response, undefined); - }); - it('update', async () => { - const response = await client.helpCenter.sections.update({ - id: section.id, - name: 'People of future, tell us if blockchain makes sense in 2026', - }); - - assert.notEqual(response, undefined); - }); - it('delete', async () => { - const response = await client.helpCenter.sections.delete({ - id: section.id, - }); - - assert.notEqual(response, undefined); - }); - it('list', async () => { - const response = await client.helpCenter.sections.list({ - perPage: 25, - page: 1, - }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/integration.test.ts b/test/integration/integration.test.ts deleted file mode 100644 index d576355a..00000000 --- a/test/integration/integration.test.ts +++ /dev/null @@ -1,86 +0,0 @@ -import { Client, ContactObject, ContactType, MessageObject } from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; -import { randomInt } from 'crypto'; - -describe('Integration between Contact, Conversation, Company and Tag APIs', () => { - let adminId: string; - let contact: ContactObject; - let conversation: MessageObject; - let companyId: string; - let lead: ContactObject; - let user: ContactObject; - - before(async () => { - const randomCompanies = await client.companies.list({ - perPage: 1, - }); - const admins = await client.admins.list(); - - adminId = admins.admins[0].id; - companyId = randomCompanies.data[0].id; - }); - - const client = new Client({ tokenAuth: { token } }); - - it('Create User', async () => { - const response = await client.contacts.createUser({ - externalId: `${randomInt(9999)}-${randomInt(9999)}-${randomInt( - 9999 - )}`, - }); - - user = response; - - assert.notEqual(response, undefined); - }); - - it('Create Lead', async () => { - const response = await client.contacts.createLead({ - name: 'Marek Barek', - }); - - lead = response; - - assert.notEqual(response, undefined); - }); - it('Convert Lead to Contact', async () => { - const response = await client.contacts.mergeLeadInUser({ - leadId: lead.id, - userId: user.id, - }); - - contact = response; - - assert.notEqual(response, undefined); - }); - it('Add Contact to Company', async () => { - const response = await client.companies.attachContact({ - contactId: contact.id, - companyId, - }); - - assert.notEqual(response, undefined); - }); - it('Create Conversation with Contact', async () => { - const response = await client.conversations.create({ - userId: contact.id, - body: 'Welcome to the club, buddy!', - type: ContactType.USER, - }); - - conversation = response; - - assert.notEqual(response, undefined); - }); - it('Tag the Conversation', async () => { - const tags = await client.tags.list(); - const response = await client.tags.tagConversation({ - conversationId: conversation.conversation_id as string, - tagId: tags.data[0].id, - adminId, - }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/messages.test.ts b/test/integration/messages.test.ts deleted file mode 100644 index 73dc71a2..00000000 --- a/test/integration/messages.test.ts +++ /dev/null @@ -1,87 +0,0 @@ -import { token } from './utils/config'; -import { Client, Operators } from '../../lib'; -import { randomString } from './utils/random'; -import { MessageType } from '../../lib/message/message.types'; -import { RecipientType } from '../../lib/message'; -import assert from 'assert'; - -describe('Messages', () => { - let adminId: string; - let userIntercomId: string; - const client = new Client({ - tokenAuth: { token }, - }); - - before(async () => { - const admins = await client.admins.list(); - const adminList = admins.admins.filter((admin) => admin.has_inbox_seat); - - adminId = adminList[0].id; - - const createdUser = await client.contacts.createUser({ - externalId: randomString(), - name: 'Message Test User', - }); - userIntercomId = createdUser.id; - }); - - it('Message that creates a converation', async () => { - const requestBody = { - message_type: MessageType.INAPP, - body: 'Hey, look at me! I am the conversations creator now!', - from: { - type: RecipientType.ADMIN, - id: adminId, - }, - to: { - type: RecipientType.USER, - id: userIntercomId, - }, - }; - const response = await client.messages.create({ - messageType: requestBody.message_type, - body: requestBody.body, - from: requestBody.from, - to: requestBody.to, - createConversationWithoutContactReply: true, - }); - - const messageId = response.id; - - // Give Intercom a few seconds to index conversation - await new Promise((resolve) => setTimeout(resolve, 5000)); - - const searchResults = await client.conversations.search({ - data: { - query: { - field: 'source.id', - operator: Operators.EQUALS, - value: messageId, - }, - }, - }); - assert.equal(searchResults.total_count > 0, true); - }); - - it('Create message, no conversation', async () => { - const requestBody = { - message_type: MessageType.INAPP, - body: 'Message without creating conversation', - from: { - type: RecipientType.ADMIN, - id: adminId, - }, - to: { - type: RecipientType.USER, - id: userIntercomId, - }, - }; - const response = await client.messages.create({ - messageType: requestBody.message_type, - body: requestBody.body, - from: requestBody.from, - to: requestBody.to, - }); - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/notes.test.ts b/test/integration/notes.test.ts deleted file mode 100644 index 7ee0d04e..00000000 --- a/test/integration/notes.test.ts +++ /dev/null @@ -1,48 +0,0 @@ -import { Client, NoteObject } from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; -import { randomString } from './utils/random'; - -describe('Notes', () => { - let adminId: string; - let contactId: string; - let note: NoteObject; - - before(async () => { - const randomContacts = await client.contacts.list({ - perPage: 1, - }); - const admins = await client.admins.list(); - - adminId = admins.admins[0].id; - contactId = randomContacts.data[0].id; - }); - - const client = new Client({ tokenAuth: { token } }); - - it('create', async () => { - const response = await client.notes.create({ - adminId, - body: randomString(), - contactId, - }); - - note = response; - - assert.notEqual(response, undefined); - }); - it('find', async () => { - const response = await client.notes.find({ id: note.id }); - - assert.notEqual(response, undefined); - }); - it('list', async () => { - const response = await client.notes.list({ - contactId, - perPage: 25, - page: 1, - }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/phoneCallRedirect.test.ts b/test/integration/phoneCallRedirect.test.ts deleted file mode 100644 index faf4148e..00000000 --- a/test/integration/phoneCallRedirect.test.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { Client } from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; - -describe('phoneCallRedirect', () => { - const client = new Client({ tokenAuth: { token } }); - - it('create', () => { - const response = client.phoneCallRedirect.create({ - phone: '+353871234567', - }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/segments.test.ts b/test/integration/segments.test.ts deleted file mode 100644 index 44e6239c..00000000 --- a/test/integration/segments.test.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { Client } from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; - -describe('Segments', () => { - let segmentId: string; - - const client = new Client({ tokenAuth: { token } }); - - it('list', async () => { - const response = await client.segments.list({ includeCount: true }); - - segmentId = response.segments[0].id; - - assert.notEqual(response, undefined); - }); - it('find', async () => { - const response = await client.segments.find({ id: segmentId }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/subscriptions.test.ts b/test/integration/subscriptions.test.ts deleted file mode 100644 index 2dde2816..00000000 --- a/test/integration/subscriptions.test.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { Client } from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; - -describe('Subscriptions', () => { - const client = new Client({ tokenAuth: { token } }); - - it('listTypes', async () => { - const response = await client.subscriptions.listTypes(); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/tags.test.ts b/test/integration/tags.test.ts deleted file mode 100644 index dfa61456..00000000 --- a/test/integration/tags.test.ts +++ /dev/null @@ -1,106 +0,0 @@ -import { Client, TagObject } from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; - -describe('Tags', () => { - let adminId: string; - let conversationId: string; - let companyId: string; - let contactId: string; - let tag: TagObject; - - before(async () => { - const randomAdmins = await client.admins.list(); - const randomConversations = await client.conversations.list({ - perPage: 1, - }); - const randomCompanies = await client.companies.list({ - perPage: 1, - }); - const randomContacts = await client.contacts.list({ - perPage: 1, - }); - - adminId = randomAdmins.admins[0].id; - conversationId = randomConversations.conversations[0].id; - companyId = randomCompanies.data[0].id; - contactId = randomContacts.data[0].id; - }); - - const client = new Client({ tokenAuth: { token } }); - - it('create', async () => { - const response = await client.tags.create({ - name: 'Bellic and Partners', - }); - - tag = response; - - assert.notEqual(response, undefined); - }); - it('update', async () => { - const response = await client.tags.update({ id: tag.id, name: 'Poor' }); - - assert.notEqual(response, undefined); - }); - it('tagContact', async () => { - const response = await client.tags.tagContact({ - contactId, - tagId: tag.id, - }); - - assert.notEqual(response, undefined); - }); - it('tagConversation', async () => { - const response = await client.tags.tagConversation({ - conversationId, - tagId: tag.id, - adminId, - }); - - assert.notEqual(response, undefined); - }); - it('tagCompanies', async () => { - const response = await client.tags.tagCompanies({ - tagName: 'Poor', - companiesIds: [companyId], - }); - - assert.notEqual(response, undefined); - }); - it('untagContact', async () => { - const response = await client.tags.untagContact({ - contactId, - tagId: tag.id, - }); - - assert.notEqual(response, undefined); - }); - it('untagConversation', async () => { - const response = await client.tags.untagConversation({ - conversationId, - tagId: tag.id, - adminId, - }); - - assert.notEqual(response, undefined); - }); - it('untagCompanies', async () => { - const response = await client.tags.untagCompanies({ - tagName: 'Poor', - companiesIds: [companyId], - }); - - assert.notEqual(response, undefined); - }); - it('list', async () => { - const response = await client.tags.list(); - - assert.notEqual(response, undefined); - }); - it('delete', async () => { - const response = await client.tags.delete({ id: tag.id }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/teams.test.ts b/test/integration/teams.test.ts deleted file mode 100644 index e276f4cb..00000000 --- a/test/integration/teams.test.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { Client } from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; - -describe('Teams', () => { - let teamId: string; - - const client = new Client({ tokenAuth: { token } }); - - it('list', async () => { - const response = await client.teams.list(); - - teamId = response.teams[0].id; - - assert.notEqual(response, undefined); - }); - it('find', async () => { - const response = await client.teams.find({ id: teamId }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/integration/utils/config.ts b/test/integration/utils/config.ts deleted file mode 100644 index ecd6093b..00000000 --- a/test/integration/utils/config.ts +++ /dev/null @@ -1 +0,0 @@ -export const token = process.env.API_TOKEN as string; diff --git a/test/integration/utils/date.ts b/test/integration/utils/date.ts deleted file mode 100644 index 0c9f7406..00000000 --- a/test/integration/utils/date.ts +++ /dev/null @@ -1,2 +0,0 @@ -export const dateToUnixTimestamp = (date: Date): number => - Math.floor(date.getTime() / 1000); diff --git a/test/integration/utils/random.ts b/test/integration/utils/random.ts deleted file mode 100644 index f74fe680..00000000 --- a/test/integration/utils/random.ts +++ /dev/null @@ -1,6 +0,0 @@ -export const randomString = () => - Buffer.from(Math.random().toString()).toString('base64').substring(10, 5); - -export const randomInt = (min = 0, max = 999): number => - Math.floor(Math.random() * (Math.floor(max) - Math.ceil(min) + 1)) + - Math.ceil(min); diff --git a/test/integration/visitors.test.ts b/test/integration/visitors.test.ts deleted file mode 100644 index 9f4829d3..00000000 --- a/test/integration/visitors.test.ts +++ /dev/null @@ -1,52 +0,0 @@ -import { Client, Role } from '../../lib'; -import assert from 'assert'; -import { token } from './utils/config'; - -// Skip by default, because there is no automation yet -describe.skip('Visitors', () => { - // Info: should be set manually. Find a way to automate it. - // Tip: headless browser to visit test application and get visitorId from ping request. - const visitorId = '0'; - const userId = '0'; - - const client = new Client({ tokenAuth: { token } }); - - it('find by id', async () => { - const response = await client.visitors.find({ id: visitorId }); - - assert.notEqual(response, undefined); - }); - it('find by user id', async () => { - const response = await client.visitors.find({ userId }); - - assert.notEqual(response, undefined); - }); - it('update', async () => { - const response = await client.visitors.update({ - userId, - name: 'Winston Smith', - }); - - assert.notEqual(response, undefined); - }); - it('delete', async () => { - const response = await client.visitors.delete({ - id: visitorId, - }); - - assert.notEqual(response, undefined); - }); - it('mergeToContact', async () => { - const response = await client.visitors.mergeToContact({ - visitor: { - id: visitorId, - }, - user: { - email: 'mcboxford@intercom-test.com', - } as any, - type: Role.USER, - }); - - assert.notEqual(response, undefined); - }); -}); diff --git a/test/unit/admin.test.ts b/test/unit/admin.test.ts deleted file mode 100644 index c0ae2c91..00000000 --- a/test/unit/admin.test.ts +++ /dev/null @@ -1,64 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import nock from 'nock'; - -describe('admins', () => { - it('should find admins by id', async () => { - nock('https://api.intercom.io').get('/admins/baz').reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.admins.find({ id: 'baz' }); - - assert.deepStrictEqual({}, response); - }); - it('should set an admin away', async () => { - const id = 'baz'; - const requestData = { - away_mode_enabled: true, - away_mode_reassign: false, - }; - - nock('https://api.intercom.io') - .put(`/admins/${id}/away`, requestData) - .reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.admins.away({ - adminId: id, - enableAwayMode: true, - enableReassignMode: false, - }); - - assert.deepStrictEqual({}, response); - }); - it('should list all activites logs', async () => { - const date = new Date('Fri, 17 Dec 2021 18:02:18 GMT'); - const dateInUnix = '1639764138'; - - nock('https://api.intercom.io') - .get( - `/admins/activity_logs?created_at_after=${dateInUnix}&created_at_before=${dateInUnix}` - ) - .reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.admins.listAllActivityLogs({ - before: date, - after: date, - }); - - assert.deepStrictEqual({}, response); - }); - it('should list all', async () => { - nock('https://api.intercom.io').get('/admins').reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.admins.list(); - - assert.deepStrictEqual({}, response); - }); -}); diff --git a/test/unit/article.test.ts b/test/unit/article.test.ts deleted file mode 100644 index a52a873c..00000000 --- a/test/unit/article.test.ts +++ /dev/null @@ -1,113 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import nock from 'nock'; - -describe('articles', () => { - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - it('creates article', async () => { - const requestData = { - title: 'Thanks for everything', - description: 'English description', - body: '

This is the body in html

', - author_id: 1, - state: 'published', - parent_id: 1, - parent_type: 'collection', - translated_content: { - fr: { - title: 'Allez les verts', - description: 'French description', - body: '

French body in html

', - author_id: 1, - state: 'published', - }, - }, - }; - nock('https://api.intercom.io').post('/articles').reply(200, {}); - const response = await client.articles.create({ - title: requestData.title, - description: requestData.description, - body: requestData.body, - authorId: requestData.author_id, - state: requestData.state, - parentId: requestData.parent_id, - parentType: requestData.parent_type, - translatedContent: requestData.translated_content, - }); - - assert.deepStrictEqual({}, response); - }); - it('retrieves an article', async () => { - const id = 'baz'; - - nock('https://api.intercom.io').get(`/articles/${id}`).reply(200, {}); - - const response = await client.articles.find({ id }); - - assert.deepStrictEqual({}, response); - }); - it('updates an article', async () => { - const id = 'baz'; - const requestData = { - title: 'Thanks for everything', - description: 'English description', - body: '

This is the body in html

', - author_id: 1, - state: 'published', - parent_id: 1, - parent_type: 'collection', - translated_content: { - fr: { - title: 'Allez les verts', - description: 'French description', - body: '

French body in html

', - author_id: 1, - state: 'published', - }, - }, - }; - nock('https://api.intercom.io').put(`/articles/${id}`).reply(200, {}); - const response = await client.articles.update({ - id, - title: requestData.title, - description: requestData.description, - body: requestData.body, - authorId: requestData.author_id, - state: requestData.state, - parentId: requestData.parent_id, - parentType: requestData.parent_type, - translatedContent: requestData.translated_content, - }); - - assert.deepStrictEqual({}, response); - }); - it('deletes an article', async () => { - const id = 'baz'; - nock('https://api.intercom.io') - .delete(`/articles/${id}`) - .reply(200, {}); - - const response = await client.articles.delete({ - id, - }); - - assert.deepStrictEqual({}, response); - }); - it('lists all', async () => { - const requestQuery = { page: 3, per_page: 12 }; - - nock('https://api.intercom.io') - .get('/articles') - .query(requestQuery) - .reply(200, {}); - - const response = await client.articles.list({ - page: requestQuery.page, - perPage: requestQuery.per_page, - }); - - assert.deepStrictEqual({}, response); - }); -}); diff --git a/test/unit/client.test.ts b/test/unit/client.test.ts deleted file mode 100644 index 7dda2498..00000000 --- a/test/unit/client.test.ts +++ /dev/null @@ -1,69 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import nock from 'nock'; - -describe('clients', () => { - it('should resolve promises', async () => { - nock('https://api.intercom.io').get('/admins').reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.admins.list(); - - assert.deepStrictEqual({}, response); - }); - it('should reject promises', async () => { - nock('https://api.intercom.io') - .get('/admins') - .reply(200, { type: 'error.list' }); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - try { - await client.admins.list(); - } catch (err) { - assert.deepStrictEqual({ type: 'error.list' }, err.body); - } - }); - it('should reject promises with error objects', async () => { - nock('https://api.intercom.io') - .get('/admins') - .reply(200, { type: 'error.list' }); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - try { - await client.admins.list(); - } catch (err) { - assert.equal(true, err instanceof Error); - } - }); - it('should construct with two fields', () => { - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - assert.equal('foo', client.usernamePart); - assert.equal('bar', client.passwordPart); - }); - it('should construct with an object', () => { - const client = new Client({ - apiKeyAuth: { appId: 'foo', appApiKey: 'bar' }, - }); - assert.equal('foo', client.usernamePart); - assert.equal('bar', client.passwordPart); - }); - it('should construct with an object containing an OAuth token', () => { - const client = new Client({ tokenAuth: { token: 'foo' } }); - assert.equal('foo', client.usernamePart); - assert.equal('', client.passwordPart); - }); - it('should throw if no credentials found', () => { - assert.throws(() => { - const client = new Client({}); - console.log(client.usernamePart); - }, /Could not construct a client with those parameters/); - }); -}); diff --git a/test/unit/company.test.ts b/test/unit/company.test.ts deleted file mode 100644 index 48e3e4b2..00000000 --- a/test/unit/company.test.ts +++ /dev/null @@ -1,260 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import nock from 'nock'; -import { dateToUnixTimestamp } from '../../lib/util/time'; -import { Order } from '../../lib/common/common.types'; - -const dummyCompany = { - type: 'company', - company_id: 'dummy-company', - id: '59yo', - app_id: 'einszweidrei', - name: 'Bitconeeeeeeect', - created_at: 1509716268, - updated_at: 1509977818, - last_request_at: 1506274700, - monthly_spend: 0, - session_count: 0, - user_count: 1, - tags: { - type: 'tag.list', - tags: [], - }, - segments: { - type: 'segment.list', - segments: [], - }, - plan: {}, - custom_attributes: {}, -}; -describe('companies', () => { - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - it('should be created', async () => { - const requestBody = { - remote_created_at: dateToUnixTimestamp(new Date()), - company_id: '46029', - name: 'BestCompanyInc.', - monthly_spend: 9001, - plan: '1. Get pizzaid', - size: 62049, - website: 'http://the-best.one', - industry: 'The Best One', - custom_attributes: {}, - }; - - nock('https://api.intercom.io') - .post('/companies', requestBody) - .reply(200, {}); - - const response = await client.companies.create({ - createdAt: requestBody.remote_created_at, - companyId: requestBody.company_id, - name: requestBody.name, - monthlySpend: requestBody.monthly_spend, - plan: requestBody.plan, - size: requestBody.size, - website: requestBody.website, - industry: requestBody.industry, - customAttributes: requestBody.custom_attributes, - }); - - assert.deepStrictEqual({}, response); - }); - it('should be updated', async () => { - const company_id = '46029'; - const requestBody = { - remote_created_at: dateToUnixTimestamp(new Date()), - name: 'BestCompanyInc.', - monthly_spend: 9001, - plan: '1. Get pizzaid', - size: 62049, - website: 'http://the-best.one', - industry: 'The Best One', - custom_attributes: {}, - }; - - nock('https://api.intercom.io') - .put(`/companies/${company_id}`, requestBody) - .reply(200, {}); - - const response = await client.companies.update({ - createdAt: requestBody.remote_created_at, - companyId: company_id, - name: requestBody.name, - monthlySpend: requestBody.monthly_spend, - plan: requestBody.plan, - size: requestBody.size, - website: requestBody.website, - industry: requestBody.industry, - customAttributes: requestBody.custom_attributes, - }); - - assert.deepStrictEqual({}, response); - }); - it('should find companies by company_id', async () => { - const queryData = { - company_id: 'baz', - }; - nock('https://api.intercom.io') - .get('/companies') - .query(queryData) - .reply(200, {}); - const response = await client.companies.find({ - companyId: queryData.company_id, - }); - - assert.deepStrictEqual({}, response); - }); - it('should find companies by name', async () => { - const queryData = { - name: 'bruh moment inc.', - }; - nock('https://api.intercom.io') - .get('/companies') - .query(queryData) - .reply(200, {}); - const response = await client.companies.find({ name: queryData.name }); - - assert.deepStrictEqual({}, response); - }); - it('should delete company by id', async () => { - const id = 'baz'; - - nock('https://api.intercom.io') - .delete(`/companies/${id}`) - .reply(200, {}); - - const response = await client.companies.delete({ - id, - }); - - assert.deepStrictEqual({}, response); - }); - it('should list with pagination', async () => { - nock('https://api.intercom.io') - .get('/companies') - .query({ page: 1, per_page: 35, order: Order.DESC }) - .reply(200, {}); - const response = await client.companies.list({ - page: 1, - perPage: 35, - order: Order.DESC, - }); - - assert.deepStrictEqual({}, response); - }); - it('should list by params', async () => { - nock('https://api.intercom.io') - .get('/companies') - .query({ tag_id: '1234', segment_id: '4567' }) - .reply(200, {}); - const response = await client.companies.list({ - tagId: '1234', - segmentId: '4567', - }); - - assert.deepStrictEqual({}, response); - }); - it('should get all infinite companies with scroll', async () => { - nock('https://api.intercom.io') - .get('/companies/scroll') - .reply(200, { - type: 'list', - scroll_param: '123_soleil', - data: [dummyCompany], - }); - - nock('https://api.intercom.io') - .get('/companies/scroll?scroll_param=123_soleil') - .reply(200, { - type: 'list', - scroll_param: '123_soleil_345', - data: [], - }); - - const response = await client.companies.scroll.each({}); - - assert.equal(1, response.length); - assert.deepStrictEqual(dummyCompany, response[0]); - }); - it('should get companies with manual scroll', async () => { - nock('https://api.intercom.io') - .get('/companies/scroll?scroll_param=123_soleil') - .reply(200, { - type: 'list', - scroll_param: '123_soleil_345', - data: [dummyCompany], - }); - - const response = await client.companies.scroll.next({ - scrollParam: '123_soleil', - }); - - assert.deepStrictEqual(dummyCompany, response.data[0]); - assert.deepStrictEqual('123_soleil_345', response.scroll_param); - }); - it('should attach contact to company', async () => { - const contactId = '123'; - const companyId = '234'; - - nock('https://api.intercom.io') - .post(`/contacts/${contactId}/companies`, { id: companyId }) - .reply(200, {}); - - const response = await client.companies.attachContact({ - contactId, - companyId, - }); - - assert.deepStrictEqual({}, response); - }); - it('should detach contact from company', async () => { - const contactId = '123'; - const companyId = '234'; - - nock('https://api.intercom.io') - .delete(`/contacts/${contactId}/companies/${companyId}`) - .reply(200, {}); - - const response = await client.companies.detachContact({ - contactId, - companyId, - }); - - assert.deepStrictEqual({}, response); - }); - it('should list all attached contacts to company', async () => { - const companyId = '234'; - const page = 1; - const perPage = 15; - - nock('https://api.intercom.io') - .get(`/companies/${companyId}/contacts`) - .query({ page, perPage }) - .reply(200, {}); - - const response = await client.companies.listAttachedContacts({ - companyId, - page, - perPage, - }); - - assert.deepStrictEqual({}, response); - }); - it('should list all attached segments to company', async () => { - const companyId = '234'; - - nock('https://api.intercom.io') - .get(`/companies/${companyId}/segments`) - .reply(200, {}); - - const response = await client.companies.listAttachedSegments({ - companyId, - }); - - assert.deepStrictEqual({}, response); - }); -}); diff --git a/test/unit/contact.test.ts b/test/unit/contact.test.ts deleted file mode 100644 index 6abe4543..00000000 --- a/test/unit/contact.test.ts +++ /dev/null @@ -1,421 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import nock from 'nock'; -import { Operators, Role } from '../../lib/common/common.types'; -import { SearchContactOrderBy } from '../../lib/contact'; - -describe('contacts', () => { - it('should create a contact with user role with external id', async () => { - const id = '536e564f316c83104c000020'; - - const contact = { - role: 'user', - external_id: id, - phone: '+48370044567', - name: 'Niko Bellic', - avatar: 'https://nico-from-gta-iv.com/lets_go_bowling.jpg', - signed_up_at: 1638203719, - last_seen_at: 1638203719, - owner_id: 1, - unsubscribed_from_emails: true, - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post('/contacts', contact) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.createUser({ - externalId: contact.external_id, - phone: contact.phone, - name: contact.name, - avatar: contact.avatar, - signedUpAt: contact.signed_up_at, - lastSeenAt: contact.last_seen_at, - ownerId: contact.owner_id, - isUnsubscribedFromEmails: contact.unsubscribed_from_emails, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should create a contact with user role with email', async () => { - const contact = { - role: 'user', - email: 'niko_bellic@mail.com', - phone: '+48370044567', - name: 'Niko Bellic', - avatar: 'https://nico-from-gta-iv.com/lets_go_bowling.jpg', - signed_up_at: 1638203719, - last_seen_at: 1638203719, - owner_id: 1, - unsubscribed_from_emails: true, - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post('/contacts', contact) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.createUser({ - email: contact.email, - phone: contact.phone, - name: contact.name, - avatar: contact.avatar, - signedUpAt: contact.signed_up_at, - lastSeenAt: contact.last_seen_at, - ownerId: contact.owner_id, - isUnsubscribedFromEmails: contact.unsubscribed_from_emails, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should create a contact with lead role', async () => { - const contact = { - role: 'lead', - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post('/contacts', contact) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.createLead(); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should create a contact with lead role with email', async () => { - const contact = { - role: 'lead', - email: 'niko_bellic@mail.com', - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post('/contacts', contact) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.createLead({ - email: contact.email, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should retrieve a contact by id', async () => { - const id = '536e564f316c83104c000020'; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .get(`/contacts/${id}`) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.find({ id }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should update a contact', async () => { - const id = '536e564f316c83104c000020'; - - const requestBody = { - role: Role.USER, - name: 'Roman The Bowling Fan', - custom_attributes: { - callBrother: "Hey Niko, it's me – Roman. Let's go bowling!", - }, - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .put(`/contacts/${id}`, requestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.update({ - id, - role: requestBody.role, - name: requestBody.name, - customAttributes: requestBody.custom_attributes, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should delete a contact by id', async () => { - const id = '536e564f316c83104c000020'; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .delete(`/contacts/${id}`) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.delete({ id }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should archive a contact by id', async () => { - const id = '536e564f316c83104c000020'; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/contacts/${id}/archive`) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.archive({ id }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should unarchive a contact by id', async () => { - const id = '536e564f316c83104c000020'; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/contacts/${id}/unarchive`) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.unarchive({ id }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should merge two contacts', async () => { - const leadId = '536e564f316c83104c000020'; - const userId = '536e564f316c83104c000021'; - - const requestBody = { - from: leadId, - into: userId, - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/contacts/merge`, requestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.mergeLeadInUser({ - leadId, - userId, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should search for contacts using filters, sorts ascending by name, paginates 5 pages per page on page 2', async () => { - const requestBody = { - query: { - operator: Operators.AND, - value: [ - { - operator: Operators.AND, - value: [ - { - field: 'updated_at', - operator: Operators.GREATER_THAN, - value: 1560436650, - }, - { - field: 'conversation_rating.rating', - operator: Operators.EQUALS, - value: 1, - }, - ], - }, - { - operator: Operators.OR, - value: [ - { - field: 'updated_at', - operator: Operators.GREATER_THAN, - value: 1560436650, - }, - { - field: 'conversation_rating.rating', - operator: Operators.EQUALS, - value: 2, - }, - ], - }, - ], - }, - pagination: { - per_page: 5, - starting_after: - 'WzE2MzU4NjA2NDgwMDAsIjYxODJiNjJlNDM4YjdhM2EwMWE4YWYxNSIsMl0=', - }, - sort: { - field: 'name', - order: 'ascending', - }, - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/contacts/search`, requestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.search({ - data: { - query: requestBody.query, - pagination: requestBody.pagination, - sort: { field: 'name', order: SearchContactOrderBy.ASC }, - }, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should list all contacts, with per page = 5 and cursor set to next page', async () => { - nock('https://api.intercom.io') - .get( - '/contacts?per_page=5&starting_after=WzE2MzU3NzU4NjkwMDAsIjYxODJiNjJhMDMwZTk4OTBkZWU4NGM5YiIsMl0=' - ) - .reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.contacts.list({ - perPage: 5, - startingAfter: - 'WzE2MzU3NzU4NjkwMDAsIjYxODJiNjJhMDMwZTk4OTBkZWU4NGM5YiIsMl0=', - }); - - assert.deepStrictEqual({}, response); - }); - - it('should list attached companies of contact by id', async () => { - const id = '536e564f316c83104c000020'; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .get(`/contacts/${id}/companies?per_page=5&page=1`) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.listAttachedCompanies({ - id, - perPage: 5, - page: 1, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should list attached tags of contact by id', async () => { - const id = '536e564f316c83104c000020'; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .get(`/contacts/${id}/tags`) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.listAttachedTags({ id }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should list attached segments of contact by id', async () => { - const id = '536e564f316c83104c000020'; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .get(`/contacts/${id}/segments`) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.listAttachedSegments({ id }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should list attached email subscriptions of contact by id', async () => { - const id = '536e564f316c83104c000020'; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .get(`/contacts/${id}/subscriptions`) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.contacts.listAttachedEmailSubscriptions({ - id, - }); - - assert.deepStrictEqual(expectedReply, response); - }); -}); diff --git a/test/unit/conversation.test.ts b/test/unit/conversation.test.ts deleted file mode 100644 index 3a3c628d..00000000 --- a/test/unit/conversation.test.ts +++ /dev/null @@ -1,665 +0,0 @@ -import assert from 'assert'; -import { Client, ContactType } from '../../lib'; -import nock from 'nock'; -import { - AssignToConversationMessageType, - AssignToConversationUserType, - CloseConversationMessageType, - CloseConversationType, - OpenConversationMessageType, - RedactConversationPartType, - ReplyToConversationMessageType, - ReplyToConversationUserType, - SearchConversationOrderBy, - SnoozeConversationMessageType, -} from '../../lib/conversation'; -import { Operators } from '../../lib/common/common.types'; - -describe('conversations', () => { - it('should create a conversation from a user', async () => { - const id = '536e564f316c83104c000020'; - - const message = { - from: { - type: 'user', - id, - }, - body: 'Hello darkness my old friend', - }; - - const expectedReply = { - type: 'user_message', - id: '2001', - created_at: 1401917202, - body: 'Hello darkness my old friend', - message_type: 'inapp', - conversation_id: '36000324324', - }; - - nock('https://api.intercom.io') - .post('/conversations', message) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.create({ - userId: id, - type: ContactType.USER, - body: message.body, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should create a conversation from a lead', async () => { - const id = '536e564f316c83104c000020'; - - const message = { - from: { - type: 'lead', - id, - }, - body: 'Hello darkness my old friend', - }; - - const expectedReply = { - type: 'user_message', - id: '2001', - created_at: 1401917202, - body: 'Hello darkness my old friend', - message_type: 'inapp', - conversation_id: '36000324324', - }; - - nock('https://api.intercom.io') - .post('/conversations', message) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.create({ - userId: id, - type: ContactType.LEAD, - body: message.body, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should retrieve a conversation as is', async () => { - const id = '536e564f316c83104c000020'; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .get(`/conversations/${id}`) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.find({ id }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should retrieve a conversation as plain text', async () => { - const id = '536e564f316c83104c000020'; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .get(`/conversations/${id}`) - .query({ display_as: 'plaintext' }) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.find({ - id, - inPlainText: true, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should update a conversation', async () => { - const id = '536e564f316c83104c000020'; - - const requestBody = { - read: false, - custom_attributes: { - yey: 'in the bay', - }, - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .put(`/conversations/${id}`, requestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.update({ - id, - markRead: requestBody.read, - customAttributes: requestBody.custom_attributes, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should reply as user to a conversation by id', async () => { - const id = '536e564f316c83104c000020'; - - const userRequestBody = { - message_type: ReplyToConversationMessageType.COMMENT, - type: ReplyToConversationUserType.USER, - body: 'blablbalba', - intercom_user_id: id, - attachment_urls: ['https://definitely-sfw-site.org/bebra.jpg'], - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/conversations/${id}/reply`, userRequestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.replyByIdAsUser({ - id, - body: userRequestBody.body, - intercomUserId: userRequestBody.intercom_user_id, - attachmentUrls: userRequestBody.attachment_urls, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should reply as admin to a conversation by id', async () => { - const id = '536e564f316c83104c000020'; - - const adminRequestBody = { - admin_id: '536e564f316c83104c000020', - message_type: ReplyToConversationMessageType.NOTE, - type: ReplyToConversationUserType.ADMIN, - body: 'blablbalba', - attachment_urls: ['https://definitely-sfw-site.org/bebra.jpg'], - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/conversations/${id}/reply`, adminRequestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.replyByIdAsAdmin({ - id, - adminId: adminRequestBody.admin_id, - messageType: adminRequestBody.message_type, - body: adminRequestBody.body, - attachmentUrls: adminRequestBody.attachment_urls, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should reply as user to last conversation', async () => { - const id = '536e564f316c83104c000020'; - - const userRequestBody = { - message_type: ReplyToConversationMessageType.COMMENT, - type: ReplyToConversationUserType.USER, - body: 'blablbalba', - intercom_user_id: id, - attachment_urls: ['https://definitely-sfw-site.org/bebra.jpg'], - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/conversations/last/reply`, userRequestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.replyByLastAsUser({ - body: userRequestBody.body, - intercomUserId: userRequestBody.intercom_user_id, - attachmentUrls: userRequestBody.attachment_urls, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should reply as admin to last conversation', async () => { - const adminId = '536e564f316c83104c000021'; - - const adminRequestBody = { - admin_id: adminId, - message_type: ReplyToConversationMessageType.NOTE, - type: ReplyToConversationUserType.ADMIN, - body: 'blablbalba', - attachment_urls: ['https://definitely-sfw-site.org/bebra.jpg'], - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/conversations/last/reply`, adminRequestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.replyByLastAsAdmin({ - adminId, - messageType: adminRequestBody.message_type, - body: adminRequestBody.body, - attachmentUrls: adminRequestBody.attachment_urls, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should assign a conversation as team without assignment_rules', async () => { - const id = '536e564f316c83104c000020'; - - const userRequestBody = { - message_type: AssignToConversationMessageType.ASSIGNMENT, - type: AssignToConversationUserType.TEAM, - assignee_id: id, - admin_id: id, - body: 'blablbalba', - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/conversations/${id}/parts`, userRequestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.assign({ - id, - type: userRequestBody.type, - adminId: userRequestBody.admin_id, - assigneeId: userRequestBody.assignee_id, - body: userRequestBody.body, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should assign a conversation as team with assignment_rules', async () => { - const id = '536e564f316c83104c000020'; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/conversations/${id}/run_assignment_rules/parts`) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.assign({ - id, - withRunningAssignmentRules: true, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should snooze a conversation', async () => { - const id = '536e564f316c83104c000020'; - - const adminRequestBody = { - message_type: SnoozeConversationMessageType.SNOOZED, - admin_id: id, - snoozed_until: '1501512795', - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/conversations/${id}/reply`, adminRequestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.snooze({ - id, - adminId: adminRequestBody.admin_id, - snoozedUntil: adminRequestBody.snoozed_until, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should close a conversation', async () => { - const id = '536e564f316c83104c000020'; - - const adminRequestBody = { - message_type: CloseConversationMessageType.CLOSED, - type: CloseConversationType.ADMIN, - admin_id: id, - body: 'Closed conversation because of X.', - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/conversations/${id}/parts`, adminRequestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.close({ - id, - adminId: adminRequestBody.admin_id, - body: adminRequestBody.body, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should open a conversation', async () => { - const id = '536e564f316c83104c000020'; - - const adminRequestBody = { - message_type: OpenConversationMessageType.OPEN, - admin_id: id, - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/conversations/${id}/parts`, adminRequestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.open({ - id, - adminId: adminRequestBody.admin_id, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should attach a contact to the conversation as admin', async () => { - const id = '536e564f316c83104c000020'; - - const adminRequestBody = { - admin_id: id, - customer: { - intercom_user_id: id, - }, - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/conversations/${id}/customers`, adminRequestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.attachContactAsAdmin({ - id, - adminId: adminRequestBody.admin_id, - customer: { - intercomUserId: adminRequestBody.customer.intercom_user_id, - }, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should attach a contact to the conversation as contact', async () => { - const id = '536e564f316c83104c000020'; - - const contactRequestBody = { - user_id: id, - customer: { - intercom_user_id: id, - }, - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/conversations/${id}/customers`, contactRequestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.attachContactAsContact({ - id, - userId: contactRequestBody.user_id, - customer: { - intercomUserId: contactRequestBody.customer.intercom_user_id, - }, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should detach a contact from the conversation as admin', async () => { - const id = '536e564f316c83104c000020'; - const contactId = '536e564f316c83104c000021'; - const conversationId = '536e564f316c83104c000022'; - - const adminRequestBody = { - admin_id: id, - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .delete( - `/conversations/${conversationId}/customers/${contactId}`, - adminRequestBody - ) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.detachContactAsAdmin({ - conversationId, - contactId, - adminId: adminRequestBody.admin_id, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should search for conversations using filters', async () => { - const requestBody = { - query: { - operator: Operators.AND, - value: [ - { - operator: Operators.AND, - value: [ - { - field: 'updated_at', - operator: Operators.GREATER_THAN, - value: 1560436650, - }, - { - field: 'conversation_rating.rating', - operator: Operators.EQUALS, - value: 1, - }, - ], - }, - { - operator: Operators.OR, - value: [ - { - field: 'updated_at', - operator: Operators.GREATER_THAN, - value: 1560436650, - }, - { - field: 'conversation_rating.rating', - operator: Operators.EQUALS, - value: 2, - }, - ], - }, - ], - }, - pagination: { - per_page: 5, - starting_after: - 'WzE2MzU4NjA2NDgwMDAsIjYxODJiNjJlNDM4YjdhM2EwMWE4YWYxNSIsMl0=', - }, - sort: { - field: 'name', - order: SearchConversationOrderBy.DESC, - }, - }; - - const expectedReply = {}; - - nock('https://api.intercom.io') - .post(`/conversations/search`, requestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.search({ - data: { - query: requestBody.query, - pagination: requestBody.pagination, - // eslint-disable-next-line @typescript-eslint/no-explicit-any - sort: requestBody.sort as any, - }, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should list all conversations with', async () => { - const expectedReply = {}; - - nock('https://api.intercom.io') - .get(`/conversations`) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.list({}); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should list all conversations with per_page param', async () => { - const expectedReply = {}; - - nock('https://api.intercom.io') - .get(`/conversations?per_page=10`) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.list({ - perPage: 10, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should list all conversations with starting_after', async () => { - const expectedReply = {}; - - nock('https://api.intercom.io') - .get(`/conversations?starting_after=asdf123&per_page=10`) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.list({ - startingAfter: 'asdf123', - perPage: 10, - }); - - assert.deepStrictEqual(expectedReply, response); - }); - - it('should redact a conversation part', async () => { - const conversation_id = '536e564f316c83104c000020'; - const conversation_part_id = '536e564f316c83104c000021'; - - const requestBody = { - type: RedactConversationPartType.CONVERSATION_PART, - conversation_id, - conversation_part_id, - }; - const expectedReply = {}; - - nock('https://api.intercom.io') - .post('/conversations/redact', requestBody) - .reply(200, expectedReply); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - const response = await client.conversations.redactConversationPart({ - type: requestBody.type, - conversationId: requestBody.conversation_id, - conversationPartId: requestBody.conversation_part_id, - }); - - assert.deepStrictEqual(expectedReply, response); - }); -}); diff --git a/test/unit/counts.test.ts b/test/unit/counts.test.ts deleted file mode 100644 index 47bb3c26..00000000 --- a/test/unit/counts.test.ts +++ /dev/null @@ -1,85 +0,0 @@ -import assert from 'assert'; -import { Client, CountEntity, CountType } from '../../lib'; -import nock from 'nock'; - -describe('counts', () => { - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - it('gets total app count', async () => { - nock('https://api.intercom.io').get('/counts').reply(200, {}); - const response = await client.counts.forApp(); - - assert.deepStrictEqual({}, response); - }); - it('gets conversations count', async () => { - nock('https://api.intercom.io') - .get('/counts') - .query({ type: CountType.CONVERSATION }) - .reply(200, {}); - const response = await client.counts.countConversation(); - - assert.deepStrictEqual({}, response); - }); - it('gets admin conversations count', async () => { - nock('https://api.intercom.io') - .get('/counts') - .query({ type: CountType.CONVERSATION, count: CountEntity.ADMIN }) - .reply(200, {}); - const response = await client.counts.countAdminConversation(); - - assert.deepStrictEqual({}, response); - }); - describe('for user', () => { - it('gets segment count', async () => { - nock('https://api.intercom.io') - .get('/counts') - .query({ type: CountType.USER, count: CountEntity.SEGMENT }) - .reply(200, {}); - const response = await client.counts.countUserSegment(); - - assert.deepStrictEqual({}, response); - }); - - it('gets tags count', async () => { - nock('https://api.intercom.io') - .get('/counts') - .query({ type: CountType.USER, count: CountEntity.TAG }) - .reply(200, {}); - const response = await client.counts.countUserTag(); - - assert.deepStrictEqual({}, response); - }); - }); - describe('for company', () => { - it('gets segment count', async () => { - nock('https://api.intercom.io') - .get('/counts') - .query({ type: CountType.COMPANY, count: CountEntity.SEGMENT }) - .reply(200, {}); - const response = await client.counts.countCompanySegment(); - - assert.deepStrictEqual({}, response); - }); - - it('gets tags count', async () => { - nock('https://api.intercom.io') - .get('/counts') - .query({ type: CountType.COMPANY, count: CountEntity.TAG }) - .reply(200, {}); - const response = await client.counts.countCompanyTag(); - - assert.deepStrictEqual({}, response); - }); - - it('gets users count', async () => { - nock('https://api.intercom.io') - .get('/counts') - .query({ type: CountType.COMPANY, count: CountEntity.USER }) - .reply(200, {}); - const response = await client.counts.countCompanyUser(); - - assert.deepStrictEqual({}, response); - }); - }); -}); diff --git a/test/unit/dataAttribute.test.ts b/test/unit/dataAttribute.test.ts deleted file mode 100644 index b130f3c8..00000000 --- a/test/unit/dataAttribute.test.ts +++ /dev/null @@ -1,73 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import { - DataType, - ModelType, -} from '../../lib/dataAttribute/dataAttribute.types'; -import nock from 'nock'; - -describe('data attributes', () => { - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - it('should create', async () => { - const requestBody = { - name: 'list_cda', - model: ModelType.CONTACT, - data_type: DataType.STRING, - description: 'You are either alive or dead', - options: [{ value: 'alive' }, { value: 'dead' }], - }; - - nock('https://api.intercom.io') - .post('/data_attributes', requestBody) - .reply(200, {}); - const response = await client.dataAttributes.create({ - name: requestBody.name, - model: ModelType.CONTACT, - dataType: DataType.STRING, - description: requestBody.description, - options: requestBody.options, - }); - - assert.deepStrictEqual({}, response); - }); - it('should update', async () => { - const id = '123'; - const requestBody = { - description: 'You are either alive or dead', - options: [{ value: 'alive' }, { value: 'dead' }], - archived: true, - }; - - nock('https://api.intercom.io') - .put(`/data_attributes/${id}`) - .reply(200, {}); - const response = await client.dataAttributes.update({ - id, - description: requestBody.description, - options: requestBody.options, - archived: requestBody.archived, - }); - - assert.deepStrictEqual({}, response); - }); - it('should list all', async () => { - const queryParams = { - model: ModelType.CONTACT, - include_archived: true, - }; - - nock('https://api.intercom.io') - .get('/data_attributes') - .query(queryParams) - .reply(200, {}); - const response = await client.dataAttributes.list({ - model: queryParams.model, - includeArchived: queryParams.include_archived, - }); - - assert.deepStrictEqual({}, response); - }); -}); diff --git a/test/unit/errors.test.ts b/test/unit/errors.test.ts deleted file mode 100644 index 533d0f73..00000000 --- a/test/unit/errors.test.ts +++ /dev/null @@ -1,109 +0,0 @@ -import assert from 'assert'; -import nock from 'nock'; -import { Client } from '../../lib'; - -describe('errors', () => { - it('should fail with unauthorized (401) error', async () => { - nock('https://api.intercom.io') - .replyContentLength() - .get('/admins') - .reply( - 401, - { - type: 'error.list', - request_id: 'b2i3ri5909msvfqskol0', - errors: [ - { - code: 'token_unauthorized', - message: 'Not authorized to access resource', - }, - ], - }, - { - 'X-Intercom-Version': - '3736ab533ad11d88d93cdef3fcef9a98a5724229', - 'X-RateLimit-Limit': '83', - 'X-RateLimit-Remaining': '27', - 'X-RateLimit-Reset': '1522850540', - 'X-Request-Id': 'b2i3ri5909msvfqskol0', - 'X-Runtime': '0.037708', - } - ); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - try { - const response = await client.admins.list(); - assert.strictEqual(response, null, 'Valid response'); - } catch (err) { - assert.strictEqual(err.statusCode, 401); - assert.strictEqual(err.body.request_id, 'b2i3ri5909msvfqskol0'); - assert.deepStrictEqual(err.body.errors, [ - { - code: 'token_unauthorized', - message: 'Not authorized to access resource', - }, - ]); - assert.deepStrictEqual( - err.message, - 'Not authorized to access resource' - ); - assert.strictEqual( - err.headers['x-request-id'], - 'b2i3ri5909msvfqskol0' - ); - } - }); - it('should fail with too many requests (429) error', async () => { - nock('https://api.intercom.io') - .replyContentLength() - .get('/admins') - .reply( - 429, - { - type: 'error.list', - request_id: 'b2i3mhcboc6pcbe33q80', - errors: [ - { - code: 'rate_limit_exceeded', - message: 'Exceeded rate limit of 83 in 10_seconds', - }, - ], - }, - { - 'X-Intercom-Version': - '3736ab533ad11d88d93cdef3fcef9a98a5724229', - 'X-RateLimit-Limit': '83', - 'X-RateLimit-Remaining': '0', - 'X-RateLimit-Reset': '1522849880', - 'X-Request-Id': 'b2i3mhcboc6pcbe33q80', - 'X-Runtime': '0.037708', - } - ); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - try { - const response = await client.admins.list(); - assert.strictEqual(response, null, 'Valid response'); - } catch (err) { - assert.strictEqual(err.statusCode, 429); - assert.strictEqual(err.body.request_id, 'b2i3mhcboc6pcbe33q80'); - assert.deepStrictEqual(err.body.errors, [ - { - code: 'rate_limit_exceeded', - message: 'Exceeded rate limit of 83 in 10_seconds', - }, - ]); - assert.deepStrictEqual( - err.message, - 'Exceeded rate limit of 83 in 10_seconds' - ); - assert.strictEqual( - err.headers['x-request-id'], - 'b2i3mhcboc6pcbe33q80' - ); - assert.strictEqual(err.headers['x-ratelimit-reset'], '1522849880'); - } - }); -}); diff --git a/test/unit/event.test.ts b/test/unit/event.test.ts deleted file mode 100644 index 2e40158f..00000000 --- a/test/unit/event.test.ts +++ /dev/null @@ -1,65 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import nock from 'nock'; - -describe('events', () => { - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - it('should be submitted (created)', async () => { - const requestBody = { - event_name: 'placed-order', - created_at: 1389913941, - user_id: 'f4ca124298', - metadata: { - order_date: 1392036272, - stripe_invoice: 'inv_3434343434', - order_number: { - value: '3434-3434', - url: 'https://example.org/orders/3434-3434', - }, - price: { - currency: 'usd', - amount: 2999, - }, - }, - }; - - nock('https://api.intercom.io') - .post('/events', requestBody) - .reply(200, {}); - - const response = await client.events.create({ - eventName: requestBody.event_name, - createdAt: requestBody.created_at, - userId: requestBody.user_id, - metadata: requestBody.metadata, - }); - - assert.deepStrictEqual({}, response); - }); - it('should list by params', async () => { - const requestParams = { - type: 'user', - user_id: '1234', - per_page: 2, - summary: true, - email: 'i_love_memes@gmail.com', - }; - - nock('https://api.intercom.io') - .get('/events') - .query(requestParams) - .reply(200, {}); - - const response = await client.events.listBy({ - userId: requestParams.user_id, - perPage: requestParams.per_page, - summary: requestParams.summary, - email: requestParams.email, - }); - - assert.deepStrictEqual({}, response); - }); -}); diff --git a/test/unit/helpCenter.test.ts b/test/unit/helpCenter.test.ts deleted file mode 100644 index 668b1be0..00000000 --- a/test/unit/helpCenter.test.ts +++ /dev/null @@ -1,181 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import nock from 'nock'; - -describe('help center', () => { - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - describe('collections', () => { - it('creates a collection', async () => { - const requestData = { - name: 'Thanks for everything', - description: 'English description', - translated_content: { - fr: { - name: 'Allez les verts', - description: 'French description', - }, - }, - }; - nock('https://api.intercom.io') - .post('/help_center/collections') - .reply(200, {}); - const response = await client.helpCenter.collections.create({ - name: requestData.name, - description: requestData.description, - translatedContent: requestData.translated_content, - }); - - assert.deepStrictEqual({}, response); - }); - it('retrieves a collection', async () => { - const id = 'baz'; - - nock('https://api.intercom.io') - .get(`/help_center/collections/${id}`) - .reply(200, {}); - - const response = await client.helpCenter.collections.find({ id }); - - assert.deepStrictEqual({}, response); - }); - it('updates a collection', async () => { - const id = 'baz'; - const requestData = { - name: 'Thanks for everything', - description: 'English description', - translated_content: { - fr: { - name: 'Allez les verts', - description: 'French description', - }, - }, - }; - nock('https://api.intercom.io') - .put(`/help_center/collections/${id}`) - .reply(200, {}); - const response = await client.helpCenter.collections.update({ - id, - name: requestData.name, - description: requestData.description, - translatedContent: requestData.translated_content, - }); - - assert.deepStrictEqual({}, response); - }); - it('deletes a collection', async () => { - const id = 'baz'; - nock('https://api.intercom.io') - .delete(`/help_center/collections/${id}`) - .reply(200, {}); - - const response = await client.helpCenter.collections.delete({ - id, - }); - - assert.deepStrictEqual({}, response); - }); - it('lists all', async () => { - const requestQuery = { page: 3, per_page: 12 }; - - nock('https://api.intercom.io') - .get('/help_center/collections') - .query(requestQuery) - .reply(200, {}); - - const response = await client.helpCenter.collections.list({ - page: requestQuery.page, - perPage: requestQuery.per_page, - }); - - assert.deepStrictEqual({}, response); - }); - }); - describe('sections', () => { - it('creates a section', async () => { - const requestData = { - name: 'Thanks for everything', - parent_id: '123', - translated_content: { - fr: { - name: 'Allez les verts', - description: 'French description', - }, - }, - }; - nock('https://api.intercom.io') - .post('/help_center/sections') - .reply(200, {}); - const response = await client.helpCenter.sections.create({ - name: requestData.name, - parentId: requestData.parent_id, - translatedContent: requestData.translated_content, - }); - - assert.deepStrictEqual({}, response); - }); - it('retrieves a section', async () => { - const id = 'baz'; - - nock('https://api.intercom.io') - .get(`/help_center/sections/${id}`) - .reply(200, {}); - - const response = await client.helpCenter.sections.find({ id }); - - assert.deepStrictEqual({}, response); - }); - it('updates a section', async () => { - const id = 'baz'; - const requestData = { - name: 'Thanks for everything', - parent_id: '123', - translated_content: { - fr: { - name: 'Allez les verts', - description: 'French description', - }, - }, - }; - nock('https://api.intercom.io') - .put(`/help_center/sections/${id}`) - .reply(200, {}); - const response = await client.helpCenter.sections.update({ - id, - name: requestData.name, - parentId: requestData.parent_id, - translatedContent: requestData.translated_content, - }); - - assert.deepStrictEqual({}, response); - }); - it('deletes a section', async () => { - const id = 'baz'; - nock('https://api.intercom.io') - .delete(`/help_center/sections/${id}`) - .reply(200, {}); - - const response = await client.helpCenter.sections.delete({ - id, - }); - - assert.deepStrictEqual({}, response); - }); - it('lists all', async () => { - const requestQuery = { page: 3, per_page: 12 }; - - nock('https://api.intercom.io') - .get('/help_center/sections') - .query(requestQuery) - .reply(200, {}); - - const response = await client.helpCenter.sections.list({ - page: requestQuery.page, - perPage: requestQuery.per_page, - }); - - assert.deepStrictEqual({}, response); - }); - }); -}); diff --git a/test/unit/index.test.ts b/test/unit/index.test.ts deleted file mode 100644 index fe6e82c9..00000000 --- a/test/unit/index.test.ts +++ /dev/null @@ -1,39 +0,0 @@ -import assert from 'assert'; -import { Client, IdentityVerification } from '../../lib'; -import nock from 'nock'; - -describe('clients', () => { - it('ping', async () => { - nock('https://api.intercom.io').get('/admins').reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.ping(); - - assert.deepStrictEqual({}, response); - }); - it('paginate', async () => { - nock('https://api.intercom.io') - .get('/foo/bar/baz') - .query({ blue: 'red' }) - .reply(200, { foo: 'bar' }); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const paginationObject = { - next: 'https://api.intercom.io/foo/bar/baz?blue=red', - }; - const response = await client.nextPage(paginationObject); - - assert.deepStrictEqual({ foo: 'bar' }, response); - }); - it('should compute user hashes', () => { - assert.equal( - 'c8acc43edc084edb8207a50320ba4ec5d113686cf8050274a305480c98512e45', - IdentityVerification.userHash({ - secretKey: 'bar', - identifier: 'baz', - }) - ); - }); -}); diff --git a/test/unit/message.test.ts b/test/unit/message.test.ts deleted file mode 100644 index a10dda8d..00000000 --- a/test/unit/message.test.ts +++ /dev/null @@ -1,42 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import nock from 'nock'; -import { MessageType } from '../../lib/message/message.types'; -import { RecipientType } from '../../lib/message'; - -describe('messages', () => { - it('should be created', async () => { - const requestBody = { - message_type: MessageType.EMAIL, - subject: 'This is our demand now', - body: 'Destroy ponies', - template: 'plain', - from: { - type: RecipientType.ADMIN, - id: '394051', - }, - to: { - type: RecipientType.USER, - id: '536e564f316c83104c000020', - }, - }; - - nock('https://api.intercom.io') - .post('/messages', requestBody) - .reply(200, {}); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.messages.create({ - messageType: requestBody.message_type, - subject: requestBody.subject, - body: requestBody.body, - template: requestBody.template, - from: requestBody.from, - to: requestBody.to, - }); - - assert.deepStrictEqual({}, response); - }); -}); diff --git a/test/unit/notes.test.ts b/test/unit/notes.test.ts deleted file mode 100644 index 52ee81d8..00000000 --- a/test/unit/notes.test.ts +++ /dev/null @@ -1,51 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import nock from 'nock'; - -describe('notes', () => { - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - it('creates new', async () => { - const contactId = 'baz'; - const requestBody = { - body: 'Shiny', - admin_id: '12345', - }; - - nock('https://api.intercom.io') - .post(`/contacts/${contactId}/notes`, requestBody) - .reply(200, {}); - const response = await client.notes.create({ - adminId: requestBody.admin_id, - body: requestBody.body, - contactId, - }); - - assert.deepStrictEqual({}, response); - }); - it('finds by id', async () => { - const id = 'beb'; - - nock('https://api.intercom.io').get(`/notes/${id}`).reply(200, {}); - const response = await client.notes.find({ id }); - - assert.deepStrictEqual({}, response); - }); - it('lists all for specific contact by id', async () => { - const contactId = 'yoopi'; - - nock('https://api.intercom.io') - .get(`/contacts/${contactId}/notes`) - .query({ page: 2, per_page: 3 }) - .reply(200, {}); - const response = await client.notes.list({ - contactId, - page: 2, - perPage: 3, - }); - - assert.deepStrictEqual({}, response); - }); -}); diff --git a/test/unit/request-opts.test.ts b/test/unit/request-opts.test.ts deleted file mode 100644 index c66b4e39..00000000 --- a/test/unit/request-opts.test.ts +++ /dev/null @@ -1,74 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import nock from 'nock'; -import sinon from 'sinon'; -import { HeadersDefaults } from 'axios'; - -describe('request-opts', function () { - it('should be able to change request options', async () => { - nock('https://api.intercom.io').get('/admins/baz').reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }).useRequestOpts({ - proxy: false, - }); - - const response = await client.admins.find({ id: 'baz' }); - - assert.deepStrictEqual({}, response); - assert.deepStrictEqual(client.requestOpts, { - baseURL: 'https://api.intercom.io', - proxy: false, - }); - }); - it('should be able to change request baseURL option', async () => { - nock('http://local.test-server.com').get('/admins/baz').reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }).useRequestOpts({ - baseURL: 'http://local.test-server.com', - }); - - const response = await client.admins.find({ id: 'baz' }); - - assert.deepStrictEqual({}, response); - }); - it('should be able to change request options merging in headers', async () => { - const customHeaderCheck = sinon.stub().returns(true); - const userAgentHeaderCheck = sinon.stub().returns(true); - const acceptHeaderCheck = sinon.stub().returns(true); - - nock('https://api.intercom.io', { - reqheaders: { - 'x-intercom-header': customHeaderCheck, - 'User-Agent': userAgentHeaderCheck, - Accept: acceptHeaderCheck, - }, - }) - .get('/admins/baz') - .reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }).useRequestOpts({ - headers: { - common: { - Accept: 'text/plain', - 'x-intercom-header': 'bar', - }, - } as unknown as HeadersDefaults, - }); - - const response = await client.admins.find({ id: 'baz' }); - - assert.deepStrictEqual({}, response); - // Should always have a user-agent - sinon.assert.calledOnce(userAgentHeaderCheck); - sinon.assert.calledWithMatch(userAgentHeaderCheck, sinon.match.string); - // Shouldn't allow accept header to be overriden - sinon.assert.calledOnce(acceptHeaderCheck); - sinon.assert.calledWithExactly(acceptHeaderCheck, 'application/json'); - // Should include custom header - sinon.assert.calledOnce(customHeaderCheck); - sinon.assert.calledWithExactly(customHeaderCheck, 'bar'); - }); -}); diff --git a/test/unit/segment.test.ts b/test/unit/segment.test.ts deleted file mode 100644 index 85ceae8d..00000000 --- a/test/unit/segment.test.ts +++ /dev/null @@ -1,43 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import nock from 'nock'; - -describe('segments', () => { - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - it('should be listed', async () => { - const queryParams = { - include_count: true, - }; - - nock('https://api.intercom.io') - .get('/segments') - .query(queryParams) - .reply(200, {}); - const response = await client.segments.list({ - includeCount: queryParams.include_count, - }); - - assert.deepStrictEqual({}, response); - }); - it('find by id', async () => { - const id = 'baz'; - const queryParams = { - include_count: true, - }; - - nock('https://api.intercom.io') - .get(`/segments/${id}`) - .query(queryParams) - .reply(200, {}); - - const response = await client.segments.find({ - id, - includeCount: queryParams.include_count, - }); - - assert.deepStrictEqual({}, response); - }); -}); diff --git a/test/unit/subscription.test.ts b/test/unit/subscription.test.ts deleted file mode 100644 index 5cc5ecc3..00000000 --- a/test/unit/subscription.test.ts +++ /dev/null @@ -1,18 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import nock from 'nock'; - -describe('subscriptions', () => { - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - - it('should be listed', async () => { - nock('https://api.intercom.io') - .get('/subscription_types') - .reply(200, { type: 'list', data: [] }); - const response = await client.subscriptions.listTypes(); - - assert.deepStrictEqual({ type: 'list', data: [] }, response); - }); -}); diff --git a/test/unit/tag.test.ts b/test/unit/tag.test.ts deleted file mode 100644 index 396fca74..00000000 --- a/test/unit/tag.test.ts +++ /dev/null @@ -1,175 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import nock from 'nock'; - -describe('tags', () => { - it('should be created', async () => { - const requestBody = { - name: 'haven', - }; - - nock('https://api.intercom.io') - .post('/tags', requestBody) - .reply(200, {}); - - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.tags.create({ name: 'haven' }); - - assert.deepStrictEqual({}, response); - }); - it('should be updated', async () => { - const requestBody = { - id: '123', - name: 'haven', - }; - - nock('https://api.intercom.io') - .post('/tags', requestBody) - .reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.tags.update({ id: '123', name: 'haven' }); - - assert.deepStrictEqual({}, response); - }); - it('should delete tags', async () => { - nock('https://api.intercom.io').delete('/tags/baz').reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.tags.delete({ id: 'baz' }); - - assert.deepStrictEqual({}, response); - }); - it('should tag contacts', async () => { - const contactId = 'contactid123'; - const requestBody = { - id: 'tagid123', - }; - - nock('https://api.intercom.io') - .post(`/contacts/${contactId}/tags`, requestBody) - .reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.tags.tagContact({ - contactId, - tagId: requestBody.id, - }); - - assert.deepStrictEqual({}, response); - }); - it('should tag conversations', async () => { - const conversationId = 'contactid123'; - const requestBody = { - id: 'tagid123', - admin_id: 'adminid123', - }; - - nock('https://api.intercom.io') - .post(`/conversations/${conversationId}/tags`, requestBody) - .reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.tags.tagConversation({ - conversationId, - tagId: requestBody.id, - adminId: requestBody.admin_id, - }); - - assert.deepStrictEqual({}, response); - }); - it('should tag companies', async () => { - const requestBody = { - name: 'tagname_69', - companies: [{ id: '123' }, { id: '234' }, { id: '456' }], - }; - - nock('https://api.intercom.io') - .post(`/tags`, requestBody) - .reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.tags.tagCompanies({ - tagName: requestBody.name, - companiesIds: ['123', '234', '456'], - }); - - assert.deepStrictEqual({}, response); - }); - it('should untag contacts', async () => { - const { contactId, tagId } = { - contactId: 'contactId123', - tagId: 'tagId123', - }; - - nock('https://api.intercom.io') - .delete(`/contacts/${contactId}/tags/${tagId}`) - .reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.tags.untagContact({ contactId, tagId }); - - assert.deepStrictEqual({}, response); - }); - it('should untag conversations', async () => { - const conversationId = 'contactid123'; - const requestBody = { - id: 'tagid123', - admin_id: 'adminid123', - }; - - nock('https://api.intercom.io') - .delete(`/conversations/${conversationId}/tags/${requestBody.id}`) - .reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.tags.untagConversation({ - conversationId, - tagId: requestBody.id, - adminId: requestBody.admin_id, - }); - - assert.deepStrictEqual({}, response); - }); - it('should untag companies', async () => { - const requestBody = { - name: 'tagname_69', - companies: [ - { id: '123', untag: true }, - { id: '234', untag: true }, - { id: '456', untag: true }, - ], - }; - - nock('https://api.intercom.io') - .post(`/tags`, requestBody) - .reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.tags.untagCompanies({ - tagName: requestBody.name, - companiesIds: ['123', '234', '456'], - }); - - assert.deepStrictEqual({}, response); - }); - it('should list', async () => { - nock('https://api.intercom.io').get('/tags').reply(200, {}); - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - const response = await client.tags.list(); - - assert.deepStrictEqual({}, response); - }); -}); diff --git a/test/unit/team.test.ts b/test/unit/team.test.ts deleted file mode 100644 index 53c9b721..00000000 --- a/test/unit/team.test.ts +++ /dev/null @@ -1,33 +0,0 @@ -import assert from 'assert'; -import { Client } from '../../lib'; -import nock from 'nock'; - -describe('teams', () => { - let client: Client; - - before(() => { - client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - }); - - it('should be retrieved by id', async () => { - const teamId = '123'; - - nock('https://api.intercom.io').get(`/teams/${teamId}`).reply(200, {}); - - const response = await client.teams.find({ - id: teamId, - }); - - assert.deepStrictEqual({}, response); - }); - - it('should list all teams', async () => { - nock('https://api.intercom.io').get('/teams').reply(200, {}); - - const response = await client.teams.list(); - - assert.deepStrictEqual({}, response); - }); -}); diff --git a/test/unit/visitor.test.ts b/test/unit/visitor.test.ts deleted file mode 100644 index 3b2745f5..00000000 --- a/test/unit/visitor.test.ts +++ /dev/null @@ -1,85 +0,0 @@ -import assert from 'assert'; -import { Client, Role } from '../../lib'; -import nock from 'nock'; - -describe('visitors', () => { - const client = new Client({ - usernameAuth: { username: 'foo', password: 'bar' }, - }); - it('retrieves a visitor by id', async () => { - const id = 'baz'; - - nock('https://api.intercom.io').get(`/visitors/${id}`).reply(200, {}); - - const response = await client.visitors.find({ id }); - - assert.deepStrictEqual({}, response); - }); - it('retrieves a visitor by user id', async () => { - const userId = 'baz'; - - nock('https://api.intercom.io') - .get('/visitors') - .query({ user_id: userId }) - .reply(200, {}); - - const response = await client.visitors.find({ userId }); - - assert.deepStrictEqual({}, response); - }); - it('updates a visitor by id', async () => { - const requestData = { - user_id: '124', - name: 'Winston Smith', - custom_attributes: { - paid_subscriber: true, - monthly_spend: 155.5, - team_mates: 9, - }, - }; - nock('https://api.intercom.io').put('/visitors').reply(200, {}); - const response = await client.visitors.update({ - userId: requestData.user_id, - name: requestData.name, - customAttributes: requestData.custom_attributes, - }); - - assert.deepStrictEqual({}, response); - }); - it('deletes a visitor', async () => { - const id = 'baz'; - - nock('https://api.intercom.io') - .delete(`/visitors/${id}`) - .reply(200, {}); - - const response = await client.visitors.delete({ - id, - }); - - assert.deepStrictEqual({}, response); - }); - it('converts a visitor into contact', async () => { - const requestData = { - visitor: { id: 'baz' }, - user: { user_id: 'bez' }, - type: Role.USER, - }; - - nock('https://api.intercom.io') - .post('/visitors/convert', requestData) - .reply(200, {}); - - const response = await client.visitors.mergeToContact({ - visitor: { - id: requestData.visitor.id, - }, - user: { - userId: requestData.user.user_id, - }, - type: requestData.type, - }); - - assert.deepStrictEqual({}, response); - }); -}); diff --git a/tests/custom.test.ts b/tests/custom.test.ts new file mode 100644 index 00000000..7f5e031c --- /dev/null +++ b/tests/custom.test.ts @@ -0,0 +1,13 @@ +/** + * This is a custom test file, if you wish to add more tests + * to your SDK. + * Be sure to mark this file in `.fernignore`. + * + * If you include example requests/responses in your fern definition, + * you will have tests automatically generated for you. + */ +describe("test", () => { + it("default", () => { + expect(true).toBe(true); + }); +}); diff --git a/tests/integration/admins.test.ts b/tests/integration/admins.test.ts new file mode 100644 index 00000000..8302bf1b --- /dev/null +++ b/tests/integration/admins.test.ts @@ -0,0 +1,61 @@ +import { createClient } from "./utils/createClient"; + +describe("Admins", () => { + let adminId: string; + const client = createClient(); + + beforeAll(async () => { + // arrange + const adminList = await client.admins.list(); + adminId = adminList.admins[0].id; + }); + + it("list", async () => { + // act + const response = await client.admins.list(); + + // assert + expect(response).toBeDefined(); + }); + it("find", async () => { + // act + const response = await client.admins.find({ admin_id: adminId }); + + // assert + expect(response).toBeDefined(); + }); + + it("listAllActivityLogs", async () => { + // act + const response = await client.admins.listAllActivityLogs({ + created_at_after: new Date("2021-12-12").toISOString(), + created_at_before: new Date("2022-01-01").toISOString(), + }); + + // assert + expect(response).toBeDefined(); + }); + + it("away - ON", async () => { + // act + const response = await client.admins.away({ + admin_id: adminId, + away_mode_enabled: true, + away_mode_reassign: true, + }); + + // assert + expect(response).toBeDefined(); + }); + it("away - OFF", async () => { + // act + const response = await client.admins.away({ + admin_id: adminId, + away_mode_enabled: false, + away_mode_reassign: false, + }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/articles.test.ts b/tests/integration/articles.test.ts new file mode 100644 index 00000000..d7e0dc2d --- /dev/null +++ b/tests/integration/articles.test.ts @@ -0,0 +1,114 @@ +import { IntercomClient as Client } from "../../src"; +import { randomString } from "./utils/random"; +import { createClient } from "./utils/createClient"; + +async function createArticle(client: Client, parentId: number, adminId: number) { + return await client.articles.create({ + title: randomString(), + description: randomString(), + body: "Eins Zwei", + author_id: adminId, + state: "draft", + parent_id: parentId, + parent_type: "collection", + translated_content: { + fr: { + type: "article_content", + title: "Allez les verts", + description: "French description", + body: "

French body in html

", + author_id: adminId, + state: "draft", + }, + }, + }); +} + +async function tryDeleteArticle(client: Client, articleId: string) { + try { + await client.articles.delete({ article_id: articleId }); + } catch (error) { + console.error("Failed to delete article:", error); + } +} + +describe("Articles", () => { + let articleId: string; + let parentId: number; + let adminId: number; + const client = createClient(); + + beforeAll(async () => { + // arrange + const randomCollections = await client.helpCenters.collections.list({ + per_page: 1, + }); + const randomAdmins = await client.admins.list(); + + parentId = parseInt(randomCollections.data[0].id, 10); + adminId = parseInt(randomAdmins.admins[0].id, 10); + + const article = await createArticle(client, parentId, adminId); + articleId = article.id; + }); + + afterAll(async () => { + // cleanup + await tryDeleteArticle(client, articleId); + }); + + it("create", async () => { + // act + const article = await createArticle(client, parentId, adminId); + + // assert + expect(article).toBeDefined(); + + // cleanup + await tryDeleteArticle(client, article.id); + }); + + it("find", async () => { + // act + const response = await client.articles.find({ article_id: articleId }); + + // assert + expect(response).toBeDefined(); + }); + + it("update", async () => { + // arrange + const article = await createArticle(client, parentId, adminId); + + // act + const response = await client.articles.update({ + article_id: article.id, + title: "Biba & Boba", + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryDeleteArticle(client, article.id); + }); + + it("list", async () => { + // act + const response = await client.articles.list({ page: 1, per_page: 12 }); + + // assert + expect(response).toBeDefined(); + }); + + it("delete", async () => { + // arrange + const article = await createArticle(client, parentId, adminId); + + // act + const response = await client.articles.delete({ article_id: article.id }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/companies.test.ts b/tests/integration/companies.test.ts new file mode 100644 index 00000000..078d81ee --- /dev/null +++ b/tests/integration/companies.test.ts @@ -0,0 +1,148 @@ +import { Intercom } from "../../src"; +import { dateToUnixTimestamp } from "./utils/date"; +import { createCompany, tryDeleteCompany } from "./helpers"; +import { createClient } from "./utils/createClient"; + +describe("Companies", () => { + let contactId: string; + let company: Intercom.Company; + + const client = createClient(); + + beforeAll(async () => { + // arrange + const randomContacts = await client.contacts.list({ + per_page: 1, + }); + + contactId = randomContacts.data[0].id; + company = await createCompany(client); + }); + + afterAll(async () => { + // cleanup + await tryDeleteCompany(client, company.id); + }); + + it("create", async () => { + // act + const company = await createCompany(client); + + // assert + expect(company).toBeDefined(); + + // cleanup + await tryDeleteCompany(client, company.id); + }); + + it("update", async () => { + // arrange + const company = await createCompany(client); + + // act + const response = await client.companies.createOrUpdate({ + company_id: company.company_id, + remote_created_at: dateToUnixTimestamp(new Date()), + name: "BestCompanyInc", + monthly_spend: 9001, + plan: "1. Get pizzaid", + size: 62049, + website: "http://the-best.one", + industry: "The Best One", + custom_attributes: {}, + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryDeleteCompany(client, company.id); + }); + + it("find - by id", async () => { + // act + const response = await client.companies.find({ + company_id: company.id, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("list", async () => { + // act + const response = await client.companies.list({ + page: 1, + per_page: 35, + order: "desc", + }); + + // assert + expect(response).toBeDefined(); + }); + + it("delete", async () => { + // arrange + const company = await createCompany(client); + + // act + const response = await client.companies.delete({ + company_id: company.id, + }); + + // assert + expect(response).toBeDefined(); + }); + + it.skip("scroll - infinite one", async () => { + // act + const response = await client.companies.scroll(); + + // assert + expect(response.data).toBeDefined(); + }); + + it("attachContact", async () => { + // act + const response = await client.companies.attachContact({ + contact_id: contactId, + id: company.id, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("detachContact", async () => { + // act + const response = await client.companies.detachContact({ + contact_id: contactId, + company_id: company.id, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("listAttachedContacts", async () => { + // act + const response = await client.companies.listAttachedContacts({ + company_id: company.id, + page: 1, + per_page: 25, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("listAttachedSegments", async () => { + // act + const response = await client.companies.listAttachedSegments({ + company_id: company.id, + }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/contacts.test.ts b/tests/integration/contacts.test.ts new file mode 100644 index 00000000..633714dc --- /dev/null +++ b/tests/integration/contacts.test.ts @@ -0,0 +1,243 @@ +import { Intercom } from "../../src"; +import { dateToUnixTimestamp } from "./utils/date"; +import { randomString } from "./utils/random"; +import { createContact, tryDeleteCompany, tryDeleteContact, tryUntagContact } from "./helpers"; +import { createClient } from "./utils/createClient"; + +describe("Contacts", () => { + let subscriptionId: string; + let tag: Intercom.Tag; + let contact: Intercom.Contact; + let company: Intercom.Company; + + const client = createClient(); + + beforeAll(async () => { + // arrange + contact = await createContact(client); + + company = await client.companies.createOrUpdate({ + remote_created_at: dateToUnixTimestamp(new Date()), + company_id: randomString(), + name: randomString(), + monthly_spend: 9001, + plan: "1. Get pizzaid", + size: 62049, + website: "http://the-best.one", + industry: "The Best One", + custom_attributes: {}, + }); + + await client.companies.attachContact({ + id: company.id, + contact_id: contact.id, + }); + + const subscriptionTypes = await client.subscriptionTypes.list(); + subscriptionId = subscriptionTypes.data[0].id; + await client.contacts.attachSubscription({ + contact_id: contact.id, + id: subscriptionId, + consent_type: "opt_in", + }); + + tag = await client.tags.create({ + name: randomString(), + }); + await client.tags.tagContact({ + contact_id: contact.id, + id: tag.id, + }); + }); + + afterAll(async () => { + // cleanup + try { + await client.contacts.detachSubscription({ + contact_id: contact.id, + subscription_id: subscriptionId, + }); + } catch (error) { + console.error("Failed to detach subscription:", error); + } + await tryUntagContact(client, contact.id, tag.id); + await tryDeleteCompany(client, company.id); + await tryDeleteContact(client, contact.id); + }); + + it("list", async () => { + // act + const response = await client.contacts.list({ + per_page: 5, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("createUser", async () => { + // act + const response = await client.contacts.create({ + external_id: randomString(), + phone: "+353871234567", + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryDeleteContact(client, response.id); + }); + + it("createLead", async () => { + // act + const response = await client.contacts.create({ + name: "Roman Bowling", + role: "lead", + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryDeleteContact(client, response.id); + }); + + it("find - by id", async () => { + // act + const response = await client.contacts.find({ + contact_id: contact.id, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("update", async () => { + // arrange + const contact = await createContact(client); + + // act + const response = await client.contacts.update({ + contact_id: contact.id, + name: "Nico Bellic", + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryDeleteContact(client, contact.id); + }); + + it("archive", async () => { + // arrange + const contact = await createContact(client); + + // act + const response = await client.contacts.archive({ + contact_id: contact.id, + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryDeleteContact(client, contact.id); + }); + + it("unarchive", async () => { + // arrange + const contact = await createContact(client); + + // act + const response = await client.contacts.unarchive({ + contact_id: contact.id, + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryDeleteContact(client, contact.id); + }); + + it("delete", async () => { + // arrange + const contact = await client.contacts.create({ + external_id: randomString(), + phone: "+353871234567", + }); + + // act + const response = await client.contacts.delete({ + contact_id: contact.id, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("mergeLeadInUser", async () => { + // arrange + const createdUser = await client.contacts.create({ + external_id: randomString(), + phone: "+353871234567", + }); + const createdLead = await client.contacts.create({ + name: "Roman Bowling", + role: "lead", + }); + const response = await client.contacts.mergeLeadInUser({ + from: createdLead.id, + into: createdUser.id, + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryDeleteContact(client, createdUser.id); + await tryDeleteContact(client, createdLead.id); + }); + + it("listAttachedCompanies", async () => { + // act + const response = await client.contacts.listAttachedCompanies({ + contact_id: contact.id, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("listAttachedEmailSubscriptions", async () => { + // act + const response = await client.contacts.listAttachedSubscriptions({ + contact_id: contact.id, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("listAttachedSegments", async () => { + // act + const response = await client.contacts.listAttachedSegments({ + contact_id: contact.id, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("listAttachedTags", async () => { + // act + const response = await client.contacts.listAttachedTags({ + contact_id: contact.id, + }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/conversations.test.ts b/tests/integration/conversations.test.ts new file mode 100644 index 00000000..c204cd8e --- /dev/null +++ b/tests/integration/conversations.test.ts @@ -0,0 +1,286 @@ +import { Intercom } from "../../src"; +import { randomString } from "./utils/random"; +import { createConversation, tryDeleteContact } from "./helpers"; +import { wait } from "./utils/wait"; +import { createClient } from "./utils/createClient"; + +describe("Conversations", () => { + let user: Intercom.Contact; + let secondUser: Intercom.Contact; + let lead: Intercom.Contact; + + let adminId: string; + let secondAdminId: string; + let conversationId: string; + let conversation: Intercom.Conversation; + + const client = createClient(); + + beforeAll(async () => { + // arrange + const admins = await client.admins.list(); + + const adminList = admins.admins.filter((admin) => admin.has_inbox_seat); + // Only admins with inbox seat can interact with conversations. + adminId = adminList[0].id; + secondAdminId = adminList[1].id; + user = await client.contacts.create({ + external_id: randomString(), + name: "Baba Booey", + }); + secondUser = await client.contacts.create({ + external_id: randomString(), + name: "Babushka Boy", + email: "babushka_boy@bababooey.com", + }); + lead = await client.contacts.create({ + name: "Babushka Lead", + email: "babushka_lead@bababooey.com", + role: "lead", + }); + + const conversationMessage = await client.conversations.create({ + from: { id: user.id, type: "user" }, + body: "Raz-dwa-try kalyna, czorniawaja diwczyna", + }); + conversationId = conversationMessage.conversation_id; + + // Give Intercom a few seconds to index conversation + await wait(5000); + + conversation = await client.conversations.find({ + conversation_id: conversationId, + }); + }, 20_000); + + afterAll(async () => { + // cleanup + await tryDeleteContact(client, user.id); + await tryDeleteContact(client, secondUser.id); + await tryDeleteContact(client, lead.id); + }); + + it("create conversation with user as default", async () => { + // act + const response = await client.conversations.create({ + from: { id: user.id, type: "user" }, + body: "Raz-dwa-try kalyna, czorniawaja diwczyna", + }); + + // assert + expect(response).toBeDefined(); + }); + + it("create conversation with user", async () => { + // act + const response = await client.conversations.create({ + from: { id: user.id, type: "user" }, + body: "Raz-dwa-try kalyna, czorniawaja diwczyna", + }); + + // assert + expect(response).toBeDefined(); + }); + + it("create conversation with lead", async () => { + // act + const response = await client.conversations.create({ + from: { id: lead.id, type: "lead" }, + body: "Raz-dwa-try kalyna, czorniawaja diwczyna", + }); + + // assert + expect(response).toBeDefined(); + }); + + it("find - by id", async () => { + // act + const response = await client.conversations.find({ + conversation_id: conversationId, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("update", async () => { + // act + const response = await client.conversations.update({ + conversation_id: conversationId, + read: false, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("replyByIdAsAdmin", async () => { + // act + const response = await client.conversations.reply({ + conversation_id: conversationId, + body: { + message_type: "comment", + type: "admin", + body: "test", + admin_id: adminId, + } + }); + + // assert + expect(response).toBeDefined(); + }); + + it("replyByIdAsUser", async () => { + // act + const response = await client.conversations.reply({ + conversation_id: conversationId, + body: { + message_type: "comment", + type: "user", + body: "*click* Nice!", + intercom_user_id: user.id, + } + }); + + // assert + expect(response).toBeDefined(); + }); + + it("assign", async () => { + // arrange + const message = await createConversation(client, user.id); + + // act + const response = await client.conversations.manage({ + conversation_id: message.conversation_id, + body: { + message_type: "assignment", + type: "admin", + admin_id: adminId, + assignee_id: secondAdminId, + body: "Goodbye :)", + } + }); + + // assert + expect(response).toBeDefined(); + }); + + it("run assignment rules", async () => { + // arrange + const message = await createConversation(client, user.id); + + // act + const response = await client.conversations.runAssignmentRules({ + conversation_id: message.conversation_id, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("snooze", async () => { + // act + const response = await client.conversations.manage({ + conversation_id: conversationId, + body: { + message_type: "snoozed", + admin_id: adminId, + snoozed_until: new Date("2040.06.19").getTime() / 1000, + } + }); + + // assert + expect(response).toBeDefined(); + }); + + it("open", async () => { + // act + const response = await client.conversations.manage({ + conversation_id: conversationId, + body: { + message_type: "open", + admin_id: adminId, + } + }); + + // assert + expect(response).toBeDefined(); + }); + + it("attachContactAsAdmin", async () => { + // act + const response = await client.conversations.attachContactAsAdmin({ + conversation_id: conversationId, + customer: { intercom_user_id: secondUser.id }, + admin_id: adminId, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("detachContactAsAdmin", async () => { + // act + const response = await client.conversations.detachContactAsAdmin({ + admin_id: adminId, + contact_id: secondUser.id, + conversation_id: conversationId, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("redactConversationPart", async () => { + // arrange + const conversation = await client.conversations.find({ + conversation_id: conversationId, + }); + + // act + const response = await client.conversations.redactConversationPart({ + type: "conversation_part", + conversation_id: conversationId, + conversation_part_id: conversation.conversation_parts?.conversation_parts[2].id ?? "", + }); + + // assert + expect(response).toBeDefined(); + }); + + it("close", async () => { + // act + const response = await client.conversations.manage({ + conversation_id: conversationId, + body: { + type: "admin", + message_type: "close", + admin_id: adminId, + body: "Hasta la vista, baby", + } + }); + + // assert + expect(response).toBeDefined(); + }); + + it("search", async () => { + // act + const response = await client.conversations.search({ + query: { + operator: "AND", + value: [ + { + field: "id", + operator: "!=", + value: "123", + }, + ], + }, + }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/dataAttributes.test.ts b/tests/integration/dataAttributes.test.ts new file mode 100644 index 00000000..22c3ca10 --- /dev/null +++ b/tests/integration/dataAttributes.test.ts @@ -0,0 +1,67 @@ +import { Intercom } from "../../src"; +import { randomString } from "./utils/random"; +import { createClient } from "./utils/createClient"; + +describe("Data Attributes", () => { + let randomDataAttribute: Intercom.DataAttribute | undefined; + + const client = createClient(); + + beforeAll(async () => { + // arrange + const attributes = await client.dataAttributes.list(); + randomDataAttribute = attributes.data.find((attribute) => attribute.id !== undefined); + }); + + xit("create", async () => { + //act + + // The workspace we test on has hit the CDA limit, so we can't create any more + // for now. We should reenable this test once we have a new workspace. + const response = await client.dataAttributes.create({ + name: `Bebech${randomString()}`, + model: "contact", + data_type: "string", + description: "Dummy description", + options: ["yey", "yoy"], + }); + + // assert + expect(response).toBeDefined(); + }); + it("update", async () => { + // arrange + if (!randomDataAttribute?.id) { + console.log("randomDataAttribute", randomDataAttribute); + throw new Error("random_data_attribute.id is required to update"); + } + + // act + const response = await client.dataAttributes.update({ + data_attribute_id: randomDataAttribute.id.toString(), + archived: false, + description: "Woo-aaa", + options: [ + { + value: "1-10", + }, + { + value: "11-20", + }, + ], + }); + + // assert + expect(response).toBeDefined(); + }); + it("list", async () => { + // act + const response = await client.dataAttributes.list({ + include_archived: true, + model: "conversation", + }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/dataExport.test.ts b/tests/integration/dataExport.test.ts new file mode 100644 index 00000000..a26d014a --- /dev/null +++ b/tests/integration/dataExport.test.ts @@ -0,0 +1,57 @@ +import { Intercom, IntercomClient } from "../../src"; +import { createClient } from "./utils/createClient"; + +async function createDataExport(client: IntercomClient): Promise { + const dataExport = await client.dataExport.create({ + created_at_after: 1670000000, + created_at_before: 1670940528, + }); + return dataExport; +} + +async function tryCancelDataExport(client: IntercomClient, jobIdentifier: string): Promise { + try { + await client.dataExport.cancel({ job_identifier: jobIdentifier }); + } catch (error: unknown) { + console.log(error); + } +} + +describe("dataExport", () => { + const client = createClient(); + it("create", async () => { + // act + const response = await createDataExport(client); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryCancelDataExport(client, response.job_identifier); + }); + + it("find", async () => { + // arrange + const dataExport = await createDataExport(client); + + // act + const response = await client.dataExport.find({ job_identifier: dataExport.job_identifier }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryCancelDataExport(client, dataExport.job_identifier); + }); + + it("cancel", async () => { + // arrange + const dataExport = await createDataExport(client); + + // act + const response = await client.dataExport.cancel({ job_identifier: dataExport.job_identifier }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/events.test.ts b/tests/integration/events.test.ts new file mode 100644 index 00000000..d86c25c9 --- /dev/null +++ b/tests/integration/events.test.ts @@ -0,0 +1,69 @@ +import { IntercomClient as Client } from "../../src"; +import { dateToUnixTimestamp } from "./utils/date"; +import { randomString } from "./utils/random"; +import { createClient } from "./utils/createClient"; + +describe("Events", () => { + let userId: string; + let eventId = randomString(); + + const client = createClient(); + + beforeAll(async () => { + // arrange + const randomUsers = await client.contacts.search({ + query: { + operator: "AND", + value: [ + { + field: "role", + operator: "=", + value: "user", + }, + { + field: "external_id", + operator: "!=", + value: undefined, + }, + ], + }, + pagination: { + per_page: 1, + }, + }); + userId = randomUsers.data[0].external_id || ""; + if (!userId) { + console.warn("user_id is required to run tests"); + } + }); + + it("create", async () => { + // act + expect( + async () => + await client.events.create({ + id: eventId, + user_id: userId, + event_name: "opinion-rejected", + created_at: dateToUnixTimestamp(new Date()), + metadata: { + guidance: "provided", + wereall: "gonna make it", + price: "9001", + }, + }) + ).not.toThrowError(); + }); + + // expected to fail for now + it("listBy", async () => { + const response = await client.events.list({ + type: "user", + user_id: userId, + per_page: 2, + summary: true, + }); + + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/helpCenter/collections.test.ts b/tests/integration/helpCenter/collections.test.ts new file mode 100644 index 00000000..6dcfd781 --- /dev/null +++ b/tests/integration/helpCenter/collections.test.ts @@ -0,0 +1,105 @@ +import { IntercomClient as Client } from "../../../src"; +import { Collection } from "../../../src/api/resources/helpCenter/types"; +import { createClient } from "../utils/createClient"; + +async function createCollection(client: Client): Promise { + return await client.helpCenters.collections.create({ + name: "The Bruh Moment", + description: "Bruuuuuh", + translated_content: { + type: "group_translated_content", + fr: { + type: "group_content", + name: "Le Moment Frère", + description: "Frèèèèère", + }, + }, + }); +} + +async function tryDeleteCollection(client: Client, collectionId: string) { + try { + await client.helpCenters.collections.delete({ collection_id: collectionId }); + } catch (error) { + console.log(error); + } +} + +describe("Collections", () => { + let collectionId: string; + + const client = createClient(); + + beforeAll(async () => { + // arrange + const collection = await createCollection(client); + collectionId = collection.id; + }); + + afterAll(async () => { + // cleanup + await tryDeleteCollection(client, collectionId); + }); + + it("create", async () => { + // act + const collection = await createCollection(client); + + // assert + expect(collection).toBeDefined(); + + // cleanup + await tryDeleteCollection(client, collection.id); + }); + + it("find", async () => { + // act + const response = await client.helpCenters.collections.find({ + collection_id: collectionId, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("update", async () => { + // arrange + const collection = await createCollection(client); + + // act + const response = await client.helpCenters.collections.update({ + collection_id: collection.id, + name: "People of future, tell us if NFTs make sense in 2026", + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryDeleteCollection(client, collection.id); + }); + + it("list", async () => { + // act + const response = await client.helpCenters.collections.list({ + per_page: 25, + page: 1, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("delete", async () => { + // arrange + const collection = await createCollection(client); + + // act + const response = await client.helpCenters.collections.delete({ + collection_id: collection.id, + }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/helpers.ts b/tests/integration/helpers.ts new file mode 100644 index 00000000..0d358442 --- /dev/null +++ b/tests/integration/helpers.ts @@ -0,0 +1,87 @@ +import { Intercom, IntercomClient } from "../../src"; +import { dateToUnixTimestamp } from "./utils/date"; +import { randomString } from "./utils/random"; + +export async function createCompany(client: IntercomClient) { + return await client.companies.createOrUpdate({ + remote_created_at: dateToUnixTimestamp(new Date()), + company_id: randomString(), + name: randomString(), + monthly_spend: 9001, + plan: "1. Get pizzaid", + size: 62049, + website: "http://the-best.one", + industry: "The Best One", + custom_attributes: {}, + }); +} + +export async function tryDeleteCompany(client: IntercomClient, companyId: string) { + try { + await client.companies.delete({ company_id: companyId }); + } catch (error) { + console.error("Failed to delete company:", error); + } +} + +export async function createContact(client: IntercomClient) { + return await client.contacts.create({ + external_id: randomString(), + phone: "+353871234567", + }); +} + +export async function tryDeleteContact(client: IntercomClient, contactId: string) { + try { + await client.contacts.delete({ contact_id: contactId }); + } catch (error) { + console.error("Failed to delete contact:", error); + } +} + +export async function tryDeleteTag(client: IntercomClient, tagId: string) { + try { + await client.tags.delete({ tag_id: tagId }); + } catch (error) { + console.error(error); + } +} + +export async function createConversation(client: IntercomClient, contactId: string) { + return await client.conversations.create({ + from: { id: contactId, type: "user" }, + body: randomString(), + }); +} + +export async function tryUntagContact(client: IntercomClient, contactId: string, tagId: string) { + try { + await client.tags.untagContact({ contact_id: contactId, tag_id: tagId }); + } catch (error) { + console.error(error); + } +} + +export async function tryUntagConversation( + client: IntercomClient, + conversationId: string, + tagId: string, + adminId: string +) { + try { + await client.tags.untagConversation({ conversation_id: conversationId, tag_id: tagId, admin_id: adminId }); + } catch (error) { + console.error(error); + } +} + +export async function tryUntagCompany(client: IntercomClient, tagName: string, company: Intercom.Company) { + try { + await client.tags.create({ + name: tagName, + companies: [{ id: company.id, company_id: company.company_id, untag: true }], + }); + } catch (error) { + console.error(error); + } +} diff --git a/tests/integration/integration.test.ts b/tests/integration/integration.test.ts new file mode 100644 index 00000000..321552f6 --- /dev/null +++ b/tests/integration/integration.test.ts @@ -0,0 +1,86 @@ +import { Intercom } from "../../src"; +import { randomString } from "./utils/random"; +import { createCompany, tryDeleteCompany, tryDeleteContact, tryDeleteTag } from "./helpers"; +import { createClient } from "./utils/createClient"; + +describe("Integration between Contact, Conversation, Company and Tag APIs", () => { + let adminId: string; + let company: Intercom.Company; + let user: Intercom.Contact; + let lead: Intercom.Contact; + let tag: Intercom.Tag; + + const client = createClient(); + + beforeAll(async () => { + // arrange + const admins = await client.admins.list(); + adminId = admins.admins[0].id; + + company = await createCompany(client); + user = await client.contacts.create({ + external_id: randomString(), + }); + lead = await client.contacts.create({ + name: "Marek Barek", + role: "lead", + }); + tag = await client.tags.create({ + name: randomString(), + }); + }); + + afterAll(async () => { + // cleanup + await tryDeleteContact(client, lead.id); + await tryDeleteContact(client, user.id); + await tryDeleteCompany(client, company.id); + await tryDeleteTag(client, tag.id); + }); + + it("Add Contact to Company", async () => { + // act + const response = await client.companies.attachContact({ + contact_id: user.id, + id: company.id, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("Create Conversation with Contact", async () => { + // act + const response = await client.conversations.create({ + from: { + type: "user", + id: user.id, + }, + body: "Welcome to the club, buddy!", + }); + + // assert + expect(response).toBeDefined(); + }); + + it("Tag the Conversation", async () => { + // arrange + const conversation = await client.conversations.create({ + from: { + type: "user", + id: user.id, + }, + body: "Welcome to the club, buddy!", + }); + + // act + const response = await client.tags.tagConversation({ + conversation_id: conversation.conversation_id, + id: tag.id, + admin_id: adminId, + }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/messages.test.ts b/tests/integration/messages.test.ts new file mode 100644 index 00000000..e1bd716b --- /dev/null +++ b/tests/integration/messages.test.ts @@ -0,0 +1,81 @@ +import { Intercom } from "../../src"; +import { tryDeleteContact } from "./helpers"; +import { randomString } from "./utils/random"; +import { wait } from "./utils/wait"; +import { createClient } from "./utils/createClient"; + +describe("Messages", () => { + let adminId: string; + let user: Intercom.Contact; + + const client = createClient(); + + beforeAll(async () => { + // arrange + const admins = await client.admins.list(); + const adminList = admins.admins.filter((admin) => admin.has_inbox_seat); + + adminId = adminList[0].id; + user = await client.contacts.create({ + external_id: randomString(), + name: "Message Test User", + }); + }); + + afterAll(async () => { + // cleanup + await tryDeleteContact(client, user.id); + }); + + it("Message that creates a converation", async () => { + // act + const response = await client.messages.create({ + message_type: "inapp", + body: "Hey, look at me! I am the conversations creator now!", + from: { + type: "admin", + id: Number(adminId), + }, + to: { + type: "user", + id: user.id, + }, + create_conversation_without_contact_reply: true, + }); + + const messageId = response.id; + + // Give Intercom a few seconds to index conversation + await wait(10_000); + + const searchResults = await client.conversations.search({ + query: { + field: "source.id", + operator: "=", + value: messageId, + }, + }); + + // assert + expect(searchResults.data.length).toBeGreaterThan(0); + }, 20_000); + + it("Create message, no conversation", async () => { + // act + const response = await client.messages.create({ + message_type: "inapp", + body: "Message without creating conversation", + from: { + type: "admin", + id: Number(adminId), + }, + to: { + type: "user", + id: user.id, + }, + }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/notes.test.ts b/tests/integration/notes.test.ts new file mode 100644 index 00000000..b38c17ff --- /dev/null +++ b/tests/integration/notes.test.ts @@ -0,0 +1,65 @@ +import { Intercom } from "../../src"; +import { tryDeleteContact } from "./helpers"; +import { randomString } from "./utils/random"; +import { createClient } from "./utils/createClient"; + +describe("Notes", () => { + let adminId: string; + let contact: Intercom.Contact; + let note: Intercom.Note; + + const client = createClient(); + + beforeAll(async () => { + // arrange + const admins = await client.admins.list(); + adminId = admins.admins[0].id; + + contact = await client.contacts.create({ + external_id: randomString(), + }); + + note = await client.notes.create({ + admin_id: adminId, + body: randomString(), + contact_id: contact.id, + }); + }); + + afterAll(async () => { + // cleanup + await tryDeleteContact(client, contact.id); + }); + + it("create", async () => { + // act + const response = await client.notes.create({ + admin_id: adminId, + body: randomString(), + contact_id: contact.id, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("find", async () => { + // act + const response = await client.notes.find({ note_id: note.id }); + + // assert + expect(response).toBeDefined(); + }); + + it("list", async () => { + // act + const response = await client.notes.list({ + contact_id: contact.id, + per_page: 25, + page: 1, + }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/pagination.test.ts b/tests/integration/pagination.test.ts new file mode 100644 index 00000000..bfe4b2bd --- /dev/null +++ b/tests/integration/pagination.test.ts @@ -0,0 +1,148 @@ +import { Companies } from "../../src/api/resources/companies/client/Client"; +import { Contacts } from "../../src/api/resources/contacts/client/Client"; +import { Conversations } from "../../src/api/resources/conversations/client/Client"; +import { Collections } from "../../src/api/resources/helpCenters/resources/collections/client/Client"; +import { Notes } from "../../src/api/resources/notes/client/Client"; +import { createClient } from "./utils/createClient"; +import { randomString } from "./utils/random"; + +type TestClient = Collections | Companies | Contacts | Conversations | Notes; + +describe("Pagination", () => { + const client = createClient(); + + interface TestCase { + name: string; + client: TestClient; + limit: number; + perPage: number; + greaterThan: number; + setup?: () => Promise; + additionalParams?: Record; + } + + const testCases: TestCase[] = [ + { + name: "helpCenters collections", + client: client.helpCenters.collections, + limit: 2, + perPage: 1, + greaterThan: 1, + }, + { + name: "companies", + client: client.companies, + limit: 10, + perPage: 1, + greaterThan: 0, + }, + { + name: "contacts", + client: client.contacts, + limit: 100, + perPage: 50, + greaterThan: 0, + }, + { + name: "conversations", + client: client.conversations, + limit: 2, + perPage: 1, + greaterThan: 1, + }, + { + name: "notes", + client: client.notes, + limit: 2, + perPage: 1, + greaterThan: 1, + async setup() { + const contact = await client.contacts.create({ + email: `${randomString()}@test.com`, + }); + + await client.notes.create({ + contact_id: contact.id, + body: "one", + }); + + await client.notes.create({ + contact_id: contact.id, + body: "two", + }); + + return { contact_id: contact.id }; + }, + }, + ]; + + async function testIterator({ + client, + limit, + params, + }: { + client: TestClient; + limit: number; + params: Record; + }) { + const iterator = await client.list(params as any); + expect(iterator).toBeDefined(); + + let count = 0; + for await (const item of iterator) { + expect(item).toBeDefined(); + expect(item.id).toBeDefined(); + count++; + + if (count >= limit) { + break; + } + } + return count; + } + + async function testPager({ + client, + limit, + params, + }: { + client: TestClient; + limit: number; + params: Record; + }) { + const pager = await client.list(params as any); + expect(pager).toBeDefined(); + + let count = pager.data.length; + while (pager.hasNextPage()) { + await pager.getNextPage(); + count += pager.data.length; + + if (count >= limit) { + break; + } + } + return count; + } + + testCases.forEach(({ name, client, limit, perPage, greaterThan, setup, additionalParams }) => { + it(name, async () => { + let params: Record = { per_page: perPage }; + if (setup) { + const setupParams = await setup(); + params = { ...params, ...setupParams }; + } + if (additionalParams) { + params = { ...params, ...additionalParams }; + } + + const iteratorCount = await testIterator({ client, limit, params: { ...params } }); + const pagerCount = await testPager({ client, limit, params: { ...params } }); + expect(iteratorCount).toBeGreaterThan(greaterThan); + expect(pagerCount).toBeGreaterThan(greaterThan); + + // Confirm iterator and pager return same count. + expect(pagerCount).toEqual(iteratorCount); + }); + }); +}); diff --git a/tests/integration/phoneCallRedirect.test.ts b/tests/integration/phoneCallRedirect.test.ts new file mode 100644 index 00000000..3fc363d2 --- /dev/null +++ b/tests/integration/phoneCallRedirect.test.ts @@ -0,0 +1,20 @@ +import { createClient } from "./utils/createClient"; + +describe("phoneCallRedirect", () => { + const client = createClient(); + + // TODO: Configure Twilio to enable phone call redirect tests. + it.skip("create", async () => { + // act + const response = await client.phoneCallRedirects.create({ + phone: "+353832345678", + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, + }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/segments.test.ts b/tests/integration/segments.test.ts new file mode 100644 index 00000000..902c4c75 --- /dev/null +++ b/tests/integration/segments.test.ts @@ -0,0 +1,31 @@ +import { createClient } from "./utils/createClient"; + +describe("Segments", () => { + let segmentId: string; + + const client = createClient(); + + beforeAll(async () => { + // arrange + const response = await client.segments.list(); + segmentId = response.segments[0].id; + }); + + it("list", async () => { + // act + const response = await client.segments.list({ + include_count: true, + }); + + // assert + expect(response).toBeDefined(); + }); + + it("find", async () => { + // act + const response = await client.segments.find({ segment_id: segmentId }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/subscriptions.test.ts b/tests/integration/subscriptions.test.ts new file mode 100644 index 00000000..73b9dcb6 --- /dev/null +++ b/tests/integration/subscriptions.test.ts @@ -0,0 +1,13 @@ +import { createClient } from "./utils/createClient"; + +describe("Subscriptions", () => { + const client = createClient(); + + it("listTypes", async () => { + // act + const response = await client.subscriptionTypes.list(); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/tags.test.ts b/tests/integration/tags.test.ts new file mode 100644 index 00000000..f4fa85c5 --- /dev/null +++ b/tests/integration/tags.test.ts @@ -0,0 +1,217 @@ +import { Intercom } from "../../src"; +import { + tryDeleteTag, + createContact, + tryDeleteContact, + createConversation, + tryDeleteCompany, + createCompany, + tryUntagContact, + tryUntagConversation, + tryUntagCompany, +} from "./helpers"; +import { createClient } from "./utils/createClient"; +import { randomString } from "./utils/random"; +import { wait } from "./utils/wait"; + +describe("Tags", () => { + let adminId: string; + let tag: Intercom.Tag; + + const client = createClient(); + + beforeAll(async () => { + // arrange + const randomAdmins = await client.admins.list(); + adminId = randomAdmins.admins[0].id; + tag = await client.tags.create({ + name: randomString(), + }); + }); + + afterAll(async () => { + // cleanup + await tryDeleteTag(client, tag.id); + }); + + it("create", async () => { + // act + const response = await client.tags.create({ + name: "Bellic and Partners", + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryDeleteTag(client, response.id); + }); + + it("update", async () => { + // arrange + const tag = await client.tags.create({ + name: randomString(), + }); + + // act + const response = await client.tags.create({ id: tag.id, name: "Poor" }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryDeleteTag(client, response.id); + }); + + it("find", async () => { + // act + const response = await client.tags.find({ tag_id: tag.id }); + + // assert + expect(response).toBeDefined(); + }); + + it("list", async () => { + // act + const response = await client.tags.list(); + + // assert + expect(response).toBeDefined(); + }); + + it("delete", async () => { + // arrange + const tag = await client.tags.create({ + name: randomString(), + }); + + // act & assert + expect(async () => await client.tags.delete({ tag_id: tag.id })).not.toThrow(); + + // cleanup + await tryDeleteTag(client, tag.id); + }); + + it("tagContact", async () => { + // arrange + const contact = await createContact(client); + + // act + const response = await client.tags.tagContact({ + contact_id: contact.id, + id: tag.id, + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryUntagContact(client, contact.id, tag.id); + await tryDeleteContact(client, contact.id); + }); + + it("tagConversation", async () => { + // arrange + const contact = await createContact(client); + const message = await createConversation(client, contact.id); + + // act + const response = await client.tags.tagConversation({ + conversation_id: message.conversation_id, + id: tag.id, + admin_id: adminId, + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryUntagConversation(client, message.conversation_id, tag.id, adminId); + await tryDeleteContact(client, contact.id); + }, 10_000); + + it("tagCompany", async () => { + // arrange + const company = await createCompany(client); + + // act + const response = await client.tags.create({ + name: "Poor", + companies: [{ company_id: company.company_id }], + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryUntagCompany(client, "Poor", company); + await tryDeleteCompany(client, company.id); + }); + + it("untagContact", async () => { + // arrange + const contact = await createContact(client); + await client.tags.tagContact({ + contact_id: contact.id, + id: tag.id, + }); + + // act + const response = await client.tags.untagContact({ + contact_id: contact.id, + tag_id: tag.id, + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryDeleteContact(client, contact.id); + }); + + it("untagConversation", async () => { + // arrange + const contact = await createContact(client); + const message = await createConversation(client, contact.id); + + await client.tags.tagConversation({ + conversation_id: message.conversation_id, + id: tag.id, + admin_id: adminId, + }); + + // act + const response = await client.tags.untagConversation({ + conversation_id: message.conversation_id, + tag_id: tag.id, + admin_id: adminId, + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryDeleteContact(client, contact.id); + }, 10_000); + + it("untagCompany", async () => { + // arrange + const company = await createCompany(client); + await client.tags.create({ + name: "Poor", + companies: [{ id: company.id, company_id: company.company_id }], + }); + + // act + const response = await client.tags.create({ + name: "Poor", + companies: [{ id: company.id, company_id: company.company_id, untag: true }], + }); + + // assert + expect(response).toBeDefined(); + + // cleanup + await tryDeleteCompany(client, company.id); + }); +}); diff --git a/tests/integration/teams.test.ts b/tests/integration/teams.test.ts new file mode 100644 index 00000000..59165464 --- /dev/null +++ b/tests/integration/teams.test.ts @@ -0,0 +1,29 @@ +import { createClient } from "./utils/createClient"; + +describe("Teams", () => { + let teamId: string; + + const client = createClient(); + + beforeAll(async () => { + // arrange + const response = await client.teams.list(); + teamId = response.teams[0].id; + }); + + it("list", async () => { + // act + const response = await client.teams.list(); + + // assert + expect(response).toBeDefined(); + }); + + it("find", async () => { + // act + const response = await client.teams.find({ team_id: teamId }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/integration/utils/createClient.ts b/tests/integration/utils/createClient.ts new file mode 100644 index 00000000..4b2c5475 --- /dev/null +++ b/tests/integration/utils/createClient.ts @@ -0,0 +1,5 @@ +import { IntercomClient } from "../../../src"; + +export function createClient(): IntercomClient { + return new IntercomClient({ token: process.env.API_TOKEN as string }); +} diff --git a/tests/integration/utils/date.ts b/tests/integration/utils/date.ts new file mode 100644 index 00000000..4ec8b32f --- /dev/null +++ b/tests/integration/utils/date.ts @@ -0,0 +1 @@ +export const dateToUnixTimestamp = (date: Date): number => Math.floor(date.getTime() / 1000); diff --git a/tests/integration/utils/random.ts b/tests/integration/utils/random.ts new file mode 100644 index 00000000..496df284 --- /dev/null +++ b/tests/integration/utils/random.ts @@ -0,0 +1,6 @@ +import crypto from "crypto"; + +export const randomString = (): string => crypto.randomBytes(16).toString("hex"); + +export const randomInt = (min = 0, max = 999): number => + Math.floor(Math.random() * (Math.floor(max) - Math.ceil(min) + 1)) + Math.ceil(min); diff --git a/tests/integration/utils/wait.ts b/tests/integration/utils/wait.ts new file mode 100644 index 00000000..685944a5 --- /dev/null +++ b/tests/integration/utils/wait.ts @@ -0,0 +1,3 @@ +export async function wait(ms: number) { + return new Promise((resolve) => setTimeout(resolve, ms)); +} diff --git a/tests/integration/visitors.test.ts b/tests/integration/visitors.test.ts new file mode 100644 index 00000000..10e2a469 --- /dev/null +++ b/tests/integration/visitors.test.ts @@ -0,0 +1,53 @@ +import { createClient } from "./utils/createClient"; + +// Skip by default, because there is no automation yet +describe.skip("Visitors", () => { + // Info: should be set manually. Find a way to automate it. + // Tip: headless browser to visit test application and get visitorId from ping request. + const visitorId = "0"; + const userId = "0"; + + const client = createClient(); + + it("find by id", async () => { + // act + const response = await client.visitors.find({ user_id: visitorId }); + + // assert + expect(response).toBeDefined(); + }); + it("find by user id", async () => { + // act + const response = await client.visitors.find({ user_id: userId }); + + // assert + expect(response).toBeDefined(); + }); + it("update", async () => { + // act + const response = await client.visitors.update({ + user_id: userId, + name: "Winston Smith", + }); + + // assert + + expect(response).toBeDefined(); + }); + + it("mergeToContact", async () => { + // act + const response = await client.visitors.mergeToContact({ + visitor: { + id: visitorId, + }, + user: { + email: "mcboxford@intercom-test.com", + } as any, + type: "user", + }); + + // assert + expect(response).toBeDefined(); + }); +}); diff --git a/tests/unit/auth/BasicAuth.test.ts b/tests/unit/auth/BasicAuth.test.ts new file mode 100644 index 00000000..fc35704e --- /dev/null +++ b/tests/unit/auth/BasicAuth.test.ts @@ -0,0 +1,22 @@ +import { BasicAuth } from "../../../src/core/auth/BasicAuth"; + +describe("BasicAuth", () => { + describe("toAuthorizationHeader", () => { + it("correctly converts to header", () => { + expect( + BasicAuth.toAuthorizationHeader({ + username: "username", + password: "password", + }) + ).toBe("Basic dXNlcm5hbWU6cGFzc3dvcmQ="); + }); + }); + describe("fromAuthorizationHeader", () => { + it("correctly parses header", () => { + expect(BasicAuth.fromAuthorizationHeader("Basic dXNlcm5hbWU6cGFzc3dvcmQ=")).toEqual({ + username: "username", + password: "password", + }); + }); + }); +}); diff --git a/tests/unit/auth/BearerToken.test.ts b/tests/unit/auth/BearerToken.test.ts new file mode 100644 index 00000000..7757b87c --- /dev/null +++ b/tests/unit/auth/BearerToken.test.ts @@ -0,0 +1,14 @@ +import { BearerToken } from "../../../src/core/auth/BearerToken"; + +describe("BearerToken", () => { + describe("toAuthorizationHeader", () => { + it("correctly converts to header", () => { + expect(BearerToken.toAuthorizationHeader("my-token")).toBe("Bearer my-token"); + }); + }); + describe("fromAuthorizationHeader", () => { + it("correctly parses header", () => { + expect(BearerToken.fromAuthorizationHeader("Bearer my-token")).toBe("my-token"); + }); + }); +}); diff --git a/tests/unit/fetcher/Fetcher.test.ts b/tests/unit/fetcher/Fetcher.test.ts new file mode 100644 index 00000000..ff804217 --- /dev/null +++ b/tests/unit/fetcher/Fetcher.test.ts @@ -0,0 +1,73 @@ +import fs from "fs"; +import { Fetcher, fetcherImpl } from "../../../src/core/fetcher/Fetcher"; +import { join } from "path"; + +describe("Test fetcherImpl", () => { + it("should handle successful request", async () => { + const mockArgs: Fetcher.Args = { + url: "https://httpbin.org/post", + method: "POST", + headers: { "X-Test": "x-test-header" }, + body: { data: "test" }, + contentType: "application/json", + requestType: "json", + }; + + global.fetch = jest.fn().mockResolvedValue({ + ok: true, + status: 200, + text: () => Promise.resolve(JSON.stringify({ data: "test" })), + json: () => ({ data: "test" }), + }); + + const result = await fetcherImpl(mockArgs); + expect(result.ok).toBe(true); + if (result.ok) { + expect(result.body).toEqual({ data: "test" }); + } + + expect(global.fetch).toHaveBeenCalledWith( + "https://httpbin.org/post", + expect.objectContaining({ + method: "POST", + headers: expect.objectContaining({ "X-Test": "x-test-header" }), + body: JSON.stringify({ data: "test" }), + }) + ); + }); + + it("should send octet stream", async () => { + const url = "https://httpbin.org/post/file"; + const mockArgs: Fetcher.Args = { + url, + method: "POST", + headers: { "X-Test": "x-test-header" }, + contentType: "application/octet-stream", + requestType: "bytes", + duplex: "half", + body: fs.createReadStream(join(__dirname, "test-file.txt")), + }; + + global.fetch = jest.fn().mockResolvedValue({ + ok: true, + status: 200, + text: () => Promise.resolve(JSON.stringify({ data: "test" })), + json: () => Promise.resolve({ data: "test" }), + }); + + const result = await fetcherImpl(mockArgs); + + expect(global.fetch).toHaveBeenCalledWith( + url, + expect.objectContaining({ + method: "POST", + headers: expect.objectContaining({ "X-Test": "x-test-header" }), + body: expect.any(fs.ReadStream), + }) + ); + expect(result.ok).toBe(true); + if (result.ok) { + expect(result.body).toEqual({ data: "test" }); + } + }); +}); diff --git a/tests/unit/fetcher/createRequestUrl.test.ts b/tests/unit/fetcher/createRequestUrl.test.ts new file mode 100644 index 00000000..f2cd24b6 --- /dev/null +++ b/tests/unit/fetcher/createRequestUrl.test.ts @@ -0,0 +1,51 @@ +import { createRequestUrl } from "../../../src/core/fetcher/createRequestUrl"; + +describe("Test createRequestUrl", () => { + it("should return the base URL when no query parameters are provided", () => { + const baseUrl = "https://api.example.com"; + expect(createRequestUrl(baseUrl)).toBe(baseUrl); + }); + + it("should append simple query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { key: "value", another: "param" }; + expect(createRequestUrl(baseUrl, queryParams)).toBe("https://api.example.com?key=value&another=param"); + }); + + it("should handle array query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { items: ["a", "b", "c"] }; + expect(createRequestUrl(baseUrl, queryParams)).toBe("https://api.example.com?items=a&items=b&items=c"); + }); + + it("should handle object query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { filter: { name: "John", age: 30 } }; + expect(createRequestUrl(baseUrl, queryParams)).toBe( + "https://api.example.com?filter%5Bname%5D=John&filter%5Bage%5D=30" + ); + }); + + it("should handle mixed types of query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { + simple: "value", + array: ["x", "y"], + object: { key: "value" }, + }; + expect(createRequestUrl(baseUrl, queryParams)).toBe( + "https://api.example.com?simple=value&array=x&array=y&object%5Bkey%5D=value" + ); + }); + + it("should handle empty query parameters object", () => { + const baseUrl = "https://api.example.com"; + expect(createRequestUrl(baseUrl, {})).toBe(baseUrl); + }); + + it("should encode special characters in query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { special: "a&b=c d" }; + expect(createRequestUrl(baseUrl, queryParams)).toBe("https://api.example.com?special=a%26b%3Dc%20d"); + }); +}); diff --git a/tests/unit/fetcher/getFetchFn.test.ts b/tests/unit/fetcher/getFetchFn.test.ts new file mode 100644 index 00000000..9b315ad0 --- /dev/null +++ b/tests/unit/fetcher/getFetchFn.test.ts @@ -0,0 +1,22 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { getFetchFn } from "../../../src/core/fetcher/getFetchFn"; + +describe("Test for getFetchFn", () => { + it("should get node-fetch function", async () => { + if (RUNTIME.type == "node") { + if (RUNTIME.parsedVersion != null && RUNTIME.parsedVersion >= 18) { + expect(await getFetchFn()).toBe(fetch); + } else { + expect(await getFetchFn()).toEqual((await import("node-fetch")).default as any); + } + } + }); + + it("should get fetch function", async () => { + if (RUNTIME.type == "browser") { + const fetchFn = await getFetchFn(); + expect(typeof fetchFn).toBe("function"); + expect(fetchFn.name).toBe("fetch"); + } + }); +}); diff --git a/tests/unit/fetcher/getRequestBody.test.ts b/tests/unit/fetcher/getRequestBody.test.ts new file mode 100644 index 00000000..919604c2 --- /dev/null +++ b/tests/unit/fetcher/getRequestBody.test.ts @@ -0,0 +1,77 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { getRequestBody } from "../../../src/core/fetcher/getRequestBody"; + +describe("Test getRequestBody", () => { + it("should return FormData as is in Node environment", async () => { + if (RUNTIME.type === "node") { + const formData = new (await import("formdata-node")).FormData(); + formData.append("key", "value"); + const result = await getRequestBody({ + body: formData, + type: "file", + }); + expect(result).toBe(formData); + } + }); + + it("should stringify body if not FormData in Node environment", async () => { + if (RUNTIME.type === "node") { + const body = { key: "value" }; + const result = await getRequestBody({ + body, + type: "json", + }); + expect(result).toBe('{"key":"value"}'); + } + }); + + it("should return FormData in browser environment", async () => { + if (RUNTIME.type === "browser") { + const formData = new (await import("form-data")).default(); + formData.append("key", "value"); + const result = await getRequestBody({ + body: formData, + type: "file", + }); + expect(result).toBe(formData); + } + }); + + it("should stringify body if not FormData in browser environment", async () => { + if (RUNTIME.type === "browser") { + const body = { key: "value" }; + const result = await getRequestBody({ + body, + type: "json", + }); + expect(result).toBe('{"key":"value"}'); + } + }); + + it("should return the Uint8Array", async () => { + const input = new Uint8Array([1, 2, 3]); + const result = await getRequestBody({ + body: input, + type: "bytes", + }); + expect(result).toBe(input); + }); + + it("should return the input for content-type 'application/x-www-form-urlencoded'", async () => { + const input = "key=value&another=param"; + const result = await getRequestBody({ + body: input, + type: "other", + }); + expect(result).toBe(input); + }); + + it("should JSON stringify objects", async () => { + const input = { key: "value" }; + const result = await getRequestBody({ + body: input, + type: "json", + }); + expect(result).toBe('{"key":"value"}'); + }); +}); diff --git a/tests/unit/fetcher/getResponseBody.test.ts b/tests/unit/fetcher/getResponseBody.test.ts new file mode 100644 index 00000000..1030c517 --- /dev/null +++ b/tests/unit/fetcher/getResponseBody.test.ts @@ -0,0 +1,64 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { getResponseBody } from "../../../src/core/fetcher/getResponseBody"; +import { chooseStreamWrapper } from "../../../src/core/fetcher/stream-wrappers/chooseStreamWrapper"; + +describe("Test getResponseBody", () => { + it("should handle blob response type", async () => { + const mockBlob = new Blob(["test"], { type: "text/plain" }); + const mockResponse = new Response(mockBlob); + const result = await getResponseBody(mockResponse, "blob"); + // @ts-expect-error + expect(result.constructor.name).toBe("Blob"); + }); + + it("should handle sse response type", async () => { + if (RUNTIME.type === "node") { + const mockStream = new ReadableStream(); + const mockResponse = new Response(mockStream); + const result = await getResponseBody(mockResponse, "sse"); + expect(result).toBe(mockStream); + } + }); + + it("should handle streaming response type", async () => { + if (RUNTIME.type === "node") { + const mockStream = new ReadableStream(); + const mockResponse = new Response(mockStream); + const result = await getResponseBody(mockResponse, "streaming"); + // need to reinstantiate string as a result of locked state in Readable Stream after registration with Response + expect(JSON.stringify(result)).toBe(JSON.stringify(await chooseStreamWrapper(new ReadableStream()))); + } + }); + + it("should handle text response type", async () => { + const mockResponse = new Response("test text"); + const result = await getResponseBody(mockResponse, "text"); + expect(result).toBe("test text"); + }); + + it("should handle JSON response", async () => { + const mockJson = { key: "value" }; + const mockResponse = new Response(JSON.stringify(mockJson)); + const result = await getResponseBody(mockResponse); + expect(result).toEqual(mockJson); + }); + + it("should handle empty response", async () => { + const mockResponse = new Response(""); + const result = await getResponseBody(mockResponse); + expect(result).toBeUndefined(); + }); + + it("should handle non-JSON response", async () => { + const mockResponse = new Response("invalid json"); + const result = await getResponseBody(mockResponse); + expect(result).toEqual({ + ok: false, + error: { + reason: "non-json", + statusCode: 200, + rawBody: "invalid json", + }, + }); + }); +}); diff --git a/tests/unit/fetcher/makeRequest.test.ts b/tests/unit/fetcher/makeRequest.test.ts new file mode 100644 index 00000000..be94ab45 --- /dev/null +++ b/tests/unit/fetcher/makeRequest.test.ts @@ -0,0 +1,54 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { makeRequest } from "../../../src/core/fetcher/makeRequest"; + +describe("Test makeRequest", () => { + const mockPostUrl = "https://httpbin.org/post"; + const mockGetUrl = "https://httpbin.org/get"; + const mockHeaders = { "Content-Type": "application/json" }; + const mockBody = JSON.stringify({ key: "value" }); + + let mockFetch: jest.Mock; + + beforeEach(() => { + mockFetch = jest.fn(); + mockFetch.mockResolvedValue(new Response(JSON.stringify({ test: "successful" }), { status: 200 })); + }); + + it("should handle POST request correctly", async () => { + const response = await makeRequest(mockFetch, mockPostUrl, "POST", mockHeaders, mockBody); + const responseBody = await response.json(); + expect(responseBody).toEqual({ test: "successful" }); + expect(mockFetch).toHaveBeenCalledTimes(1); + const [calledUrl, calledOptions] = mockFetch.mock.calls[0]; + expect(calledUrl).toBe(mockPostUrl); + expect(calledOptions).toEqual( + expect.objectContaining({ + method: "POST", + headers: mockHeaders, + body: mockBody, + credentials: undefined, + }) + ); + expect(calledOptions.signal).toBeDefined(); + expect(calledOptions.signal).toBeInstanceOf(AbortSignal); + }); + + it("should handle GET request correctly", async () => { + const response = await makeRequest(mockFetch, mockGetUrl, "GET", mockHeaders, undefined); + const responseBody = await response.json(); + expect(responseBody).toEqual({ test: "successful" }); + expect(mockFetch).toHaveBeenCalledTimes(1); + const [calledUrl, calledOptions] = mockFetch.mock.calls[0]; + expect(calledUrl).toBe(mockGetUrl); + expect(calledOptions).toEqual( + expect.objectContaining({ + method: "GET", + headers: mockHeaders, + body: undefined, + credentials: undefined, + }) + ); + expect(calledOptions.signal).toBeDefined(); + expect(calledOptions.signal).toBeInstanceOf(AbortSignal); + }); +}); diff --git a/tests/unit/fetcher/requestWithRetries.test.ts b/tests/unit/fetcher/requestWithRetries.test.ts new file mode 100644 index 00000000..6f77f093 --- /dev/null +++ b/tests/unit/fetcher/requestWithRetries.test.ts @@ -0,0 +1,133 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { requestWithRetries } from "../../../src/core/fetcher/requestWithRetries"; + +describe("requestWithRetries", () => { + let mockFetch: jest.Mock; + let originalMathRandom: typeof Math.random; + let setTimeoutSpy: jest.SpyInstance; + + beforeEach(() => { + mockFetch = jest.fn(); + originalMathRandom = Math.random; + + // Mock Math.random for consistent jitter + Math.random = jest.fn(() => 0.5); + + jest.useFakeTimers({ doNotFake: ["nextTick"] }); + }); + + afterEach(() => { + Math.random = originalMathRandom; + jest.clearAllMocks(); + jest.clearAllTimers(); + }); + + it("should retry on retryable status codes", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + const retryableStatuses = [408, 409, 429, 500, 502]; + let callCount = 0; + + mockFetch.mockImplementation(async () => { + if (callCount < retryableStatuses.length) { + return new Response("", { status: retryableStatuses[callCount++] }); + } + return new Response("", { status: 200 }); + }); + + const responsePromise = requestWithRetries(() => mockFetch(), retryableStatuses.length); + await jest.runAllTimersAsync(); + const response = await responsePromise; + + expect(mockFetch).toHaveBeenCalledTimes(retryableStatuses.length + 1); + expect(response.status).toBe(200); + }); + + it("should respect maxRetries limit", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + const maxRetries = 2; + mockFetch.mockResolvedValue(new Response("", { status: 500 })); + + const responsePromise = requestWithRetries(() => mockFetch(), maxRetries); + await jest.runAllTimersAsync(); + const response = await responsePromise; + + expect(mockFetch).toHaveBeenCalledTimes(maxRetries + 1); + expect(response.status).toBe(500); + }); + + it("should not retry on success status codes", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + const successStatuses = [200, 201, 202]; + + for (const status of successStatuses) { + mockFetch.mockReset(); + setTimeoutSpy.mockClear(); + mockFetch.mockResolvedValueOnce(new Response("", { status })); + + const responsePromise = requestWithRetries(() => mockFetch(), 3); + await jest.runAllTimersAsync(); + await responsePromise; + + expect(mockFetch).toHaveBeenCalledTimes(1); + expect(setTimeoutSpy).not.toHaveBeenCalled(); + } + }); + + it("should apply correct exponential backoff with jitter", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + mockFetch.mockResolvedValue(new Response("", { status: 500 })); + const maxRetries = 3; + const expectedDelays = [1000, 2000, 4000]; + + const responsePromise = requestWithRetries(() => mockFetch(), maxRetries); + await jest.runAllTimersAsync(); + await responsePromise; + + // Verify setTimeout calls + expect(setTimeoutSpy).toHaveBeenCalledTimes(expectedDelays.length); + + expectedDelays.forEach((delay, index) => { + expect(setTimeoutSpy).toHaveBeenNthCalledWith(index + 1, expect.any(Function), delay); + }); + + expect(mockFetch).toHaveBeenCalledTimes(maxRetries + 1); + }); + + it("should handle concurrent retries independently", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + mockFetch + .mockResolvedValueOnce(new Response("", { status: 500 })) + .mockResolvedValueOnce(new Response("", { status: 500 })) + .mockResolvedValueOnce(new Response("", { status: 200 })) + .mockResolvedValueOnce(new Response("", { status: 200 })); + + const promise1 = requestWithRetries(() => mockFetch(), 1); + const promise2 = requestWithRetries(() => mockFetch(), 1); + + await jest.runAllTimersAsync(); + const [response1, response2] = await Promise.all([promise1, promise2]); + + expect(response1.status).toBe(200); + expect(response2.status).toBe(200); + }); +}); diff --git a/tests/unit/fetcher/signals.test.ts b/tests/unit/fetcher/signals.test.ts new file mode 100644 index 00000000..9cabfa07 --- /dev/null +++ b/tests/unit/fetcher/signals.test.ts @@ -0,0 +1,69 @@ +import { anySignal, getTimeoutSignal } from "../../../src/core/fetcher/signals"; + +describe("Test getTimeoutSignal", () => { + beforeEach(() => { + jest.useFakeTimers(); + }); + + afterEach(() => { + jest.useRealTimers(); + }); + + it("should return an object with signal and abortId", () => { + const { signal, abortId } = getTimeoutSignal(1000); + + expect(signal).toBeDefined(); + expect(abortId).toBeDefined(); + expect(signal).toBeInstanceOf(AbortSignal); + expect(signal.aborted).toBe(false); + }); + + it("should create a signal that aborts after the specified timeout", () => { + const timeoutMs = 5000; + const { signal } = getTimeoutSignal(timeoutMs); + + expect(signal.aborted).toBe(false); + + jest.advanceTimersByTime(timeoutMs - 1); + expect(signal.aborted).toBe(false); + + jest.advanceTimersByTime(1); + expect(signal.aborted).toBe(true); + }); +}); + +describe("Test anySignal", () => { + it("should return an AbortSignal", () => { + const signal = anySignal(new AbortController().signal); + expect(signal).toBeInstanceOf(AbortSignal); + }); + + it("should abort when any of the input signals is aborted", () => { + const controller1 = new AbortController(); + const controller2 = new AbortController(); + const signal = anySignal(controller1.signal, controller2.signal); + + expect(signal.aborted).toBe(false); + controller1.abort(); + expect(signal.aborted).toBe(true); + }); + + it("should handle an array of signals", () => { + const controller1 = new AbortController(); + const controller2 = new AbortController(); + const signal = anySignal([controller1.signal, controller2.signal]); + + expect(signal.aborted).toBe(false); + controller2.abort(); + expect(signal.aborted).toBe(true); + }); + + it("should abort immediately if one of the input signals is already aborted", () => { + const controller1 = new AbortController(); + const controller2 = new AbortController(); + controller1.abort(); + + const signal = anySignal(controller1.signal, controller2.signal); + expect(signal.aborted).toBe(true); + }); +}); diff --git a/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts b/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts new file mode 100644 index 00000000..1dc9be0c --- /dev/null +++ b/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts @@ -0,0 +1,178 @@ +import { Node18UniversalStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper"; + +describe("Node18UniversalStreamWrapper", () => { + it("should set encoding to utf-8", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const setEncodingSpy = jest.spyOn(stream, "setEncoding"); + + stream.setEncoding("utf-8"); + + expect(setEncodingSpy).toHaveBeenCalledWith("utf-8"); + }); + + it("should register an event listener for readable", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const onSpy = jest.spyOn(stream, "on"); + + stream.on("readable", () => {}); + + expect(onSpy).toHaveBeenCalledWith("readable", expect.any(Function)); + }); + + it("should remove an event listener for data", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const offSpy = jest.spyOn(stream, "off"); + + const fn = () => {}; + stream.on("data", fn); + stream.off("data", fn); + + expect(offSpy).toHaveBeenCalledWith("data", expect.any(Function)); + }); + + it("should write to dest when calling pipe to writable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + const dest = new WritableStream({ + write(chunk) { + expect(chunk).toEqual(new TextEncoder().encode("test")); + }, + }); + + stream.pipe(dest); + }); + + it("should write to dest when calling pipe to node writable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + const dest = new (await import("readable-stream")).Writable({ + write(chunk, encoding, callback) { + expect(chunk.toString()).toEqual("test"); + callback(); + }, + }); + + stream.pipe(dest); + }); + + it("should write nothing when calling pipe and unpipe", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + const buffer: Uint8Array[] = []; + const dest = new WritableStream({ + write(chunk) { + buffer.push(chunk); + }, + }); + + stream.pipe(dest); + stream.unpipe(dest); + expect(buffer).toEqual([]); + }); + + it("should destroy the stream", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const destroySpy = jest.spyOn(stream, "destroy"); + + stream.destroy(); + + expect(destroySpy).toHaveBeenCalled(); + }); + + it("should pause and resume the stream", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const pauseSpy = jest.spyOn(stream, "pause"); + const resumeSpy = jest.spyOn(stream, "resume"); + + expect(stream.isPaused).toBe(false); + stream.pause(); + expect(stream.isPaused).toBe(true); + stream.resume(); + + expect(pauseSpy).toHaveBeenCalled(); + expect(resumeSpy).toHaveBeenCalled(); + }); + + it("should read the stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + + expect(await stream.read()).toEqual(new TextEncoder().encode("test")); + expect(await stream.read()).toEqual(new TextEncoder().encode("test")); + }); + + it("should read the stream as text", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + + const data = await stream.text(); + + expect(data).toEqual("testtest"); + }); + + it("should read the stream as json", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode(JSON.stringify({ test: "test" }))); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + + const data = await stream.json(); + + expect(data).toEqual({ test: "test" }); + }); + + it("should allow use with async iteratable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + let data = ""; + const stream = new Node18UniversalStreamWrapper(rawStream); + for await (const chunk of stream) { + data += new TextDecoder().decode(chunk); + } + + expect(data).toEqual("testtest"); + }); +}); diff --git a/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts b/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts new file mode 100644 index 00000000..0c99d3b2 --- /dev/null +++ b/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts @@ -0,0 +1,124 @@ +import { NodePre18StreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/NodePre18StreamWrapper"; + +describe("NodePre18StreamWrapper", () => { + it("should set encoding to utf-8", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const setEncodingSpy = jest.spyOn(stream, "setEncoding"); + + stream.setEncoding("utf-8"); + + expect(setEncodingSpy).toHaveBeenCalledWith("utf-8"); + }); + + it("should register an event listener for readable", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const onSpy = jest.spyOn(stream, "on"); + + stream.on("readable", () => {}); + + expect(onSpy).toHaveBeenCalledWith("readable", expect.any(Function)); + }); + + it("should remove an event listener for data", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const offSpy = jest.spyOn(stream, "off"); + + const fn = () => {}; + stream.on("data", fn); + stream.off("data", fn); + + expect(offSpy).toHaveBeenCalledWith("data", expect.any(Function)); + }); + + it("should write to dest when calling pipe to node writable stream", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const dest = new (await import("readable-stream")).Writable({ + write(chunk, encoding, callback) { + expect(chunk.toString()).toEqual("test"); + callback(); + }, + }); + + stream.pipe(dest); + }); + + it("should write nothing when calling pipe and unpipe", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const buffer: Uint8Array[] = []; + const dest = new (await import("readable-stream")).Writable({ + write(chunk, encoding, callback) { + buffer.push(chunk); + callback(); + }, + }); + stream.pipe(dest); + stream.unpipe(); + + expect(buffer).toEqual([]); + }); + + it("should destroy the stream", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const destroySpy = jest.spyOn(stream, "destroy"); + + stream.destroy(); + + expect(destroySpy).toHaveBeenCalledWith(); + }); + + it("should pause the stream and resume", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const pauseSpy = jest.spyOn(stream, "pause"); + + stream.pause(); + expect(stream.isPaused).toBe(true); + stream.resume(); + expect(stream.isPaused).toBe(false); + + expect(pauseSpy).toHaveBeenCalledWith(); + }); + + it("should read the stream", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + + expect(await stream.read()).toEqual("test"); + expect(await stream.read()).toEqual("test"); + }); + + it("should read the stream as text", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + + const data = await stream.text(); + + expect(data).toEqual("testtest"); + }); + + it("should read the stream as json", async () => { + const rawStream = (await import("readable-stream")).Readable.from([JSON.stringify({ test: "test" })]); + const stream = new NodePre18StreamWrapper(rawStream); + + const data = await stream.json(); + + expect(data).toEqual({ test: "test" }); + }); + + it("should allow use with async iteratable stream", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + let data = ""; + const stream = new NodePre18StreamWrapper(rawStream); + for await (const chunk of stream) { + data += chunk; + } + + expect(data).toEqual("testtest"); + }); +}); diff --git a/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts b/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts new file mode 100644 index 00000000..1d171ce6 --- /dev/null +++ b/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts @@ -0,0 +1,153 @@ +import { UndiciStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/UndiciStreamWrapper"; + +describe("UndiciStreamWrapper", () => { + it("should set encoding to utf-8", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const setEncodingSpy = jest.spyOn(stream, "setEncoding"); + + stream.setEncoding("utf-8"); + + expect(setEncodingSpy).toHaveBeenCalledWith("utf-8"); + }); + + it("should register an event listener for readable", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const onSpy = jest.spyOn(stream, "on"); + + stream.on("readable", () => {}); + + expect(onSpy).toHaveBeenCalledWith("readable", expect.any(Function)); + }); + + it("should remove an event listener for data", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const offSpy = jest.spyOn(stream, "off"); + + const fn = () => {}; + stream.on("data", fn); + stream.off("data", fn); + + expect(offSpy).toHaveBeenCalledWith("data", expect.any(Function)); + }); + + it("should write to dest when calling pipe to writable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new UndiciStreamWrapper(rawStream); + const dest = new WritableStream({ + write(chunk) { + expect(chunk).toEqual(new TextEncoder().encode("test")); + }, + }); + + stream.pipe(dest); + }); + + it("should write nothing when calling pipe and unpipe", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const buffer: Uint8Array[] = []; + const dest = new WritableStream({ + write(chunk) { + buffer.push(chunk); + }, + }); + stream.pipe(dest); + stream.unpipe(dest); + + expect(buffer).toEqual([]); + }); + + it("should destroy the stream", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const destroySpy = jest.spyOn(stream, "destroy"); + + stream.destroy(); + + expect(destroySpy).toHaveBeenCalled(); + }); + + it("should pause and resume the stream", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const pauseSpy = jest.spyOn(stream, "pause"); + const resumeSpy = jest.spyOn(stream, "resume"); + + expect(stream.isPaused).toBe(false); + stream.pause(); + expect(stream.isPaused).toBe(true); + stream.resume(); + + expect(pauseSpy).toHaveBeenCalled(); + expect(resumeSpy).toHaveBeenCalled(); + }); + + it("should read the stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new UndiciStreamWrapper(rawStream); + + expect(await stream.read()).toEqual(new TextEncoder().encode("test")); + expect(await stream.read()).toEqual(new TextEncoder().encode("test")); + }); + + it("should read the stream as text", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new UndiciStreamWrapper(rawStream); + + const data = await stream.text(); + + expect(data).toEqual("testtest"); + }); + + it("should read the stream as json", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode(JSON.stringify({ test: "test" }))); + controller.close(); + }, + }); + const stream = new UndiciStreamWrapper(rawStream); + + const data = await stream.json(); + + expect(data).toEqual({ test: "test" }); + }); + + it("should allow use with async iteratable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + let data = ""; + const stream = new UndiciStreamWrapper(rawStream); + for await (const chunk of stream) { + data += new TextDecoder().decode(chunk); + } + + expect(data).toEqual("testtest"); + }); +}); diff --git a/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts b/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts new file mode 100644 index 00000000..17cf37a2 --- /dev/null +++ b/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts @@ -0,0 +1,43 @@ +import { RUNTIME } from "../../../../src/core/runtime"; +import { chooseStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/chooseStreamWrapper"; +import { Node18UniversalStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper"; +import { NodePre18StreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/NodePre18StreamWrapper"; +import { UndiciStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/UndiciStreamWrapper"; + +describe("chooseStreamWrapper", () => { + beforeEach(() => { + RUNTIME.type = "unknown"; + RUNTIME.parsedVersion = 0; + }); + + it('should return a Node18UniversalStreamWrapper when RUNTIME.type is "node" and RUNTIME.parsedVersion is not null and RUNTIME.parsedVersion is greater than or equal to 18', async () => { + const expected = new Node18UniversalStreamWrapper(new ReadableStream()); + RUNTIME.type = "node"; + RUNTIME.parsedVersion = 18; + + const result = await chooseStreamWrapper(new ReadableStream()); + + expect(JSON.stringify(result)).toBe(JSON.stringify(expected)); + }); + + it('should return a NodePre18StreamWrapper when RUNTIME.type is "node" and RUNTIME.parsedVersion is not null and RUNTIME.parsedVersion is less than 18', async () => { + const stream = await import("readable-stream"); + const expected = new NodePre18StreamWrapper(new stream.Readable()); + + RUNTIME.type = "node"; + RUNTIME.parsedVersion = 16; + + const result = await chooseStreamWrapper(new stream.Readable()); + + expect(JSON.stringify(result)).toEqual(JSON.stringify(expected)); + }); + + it('should return a Undici when RUNTIME.type is not "node"', async () => { + const expected = new UndiciStreamWrapper(new ReadableStream()); + RUNTIME.type = "browser"; + + const result = await chooseStreamWrapper(new ReadableStream()); + + expect(JSON.stringify(result)).toEqual(JSON.stringify(expected)); + }); +}); diff --git a/tests/unit/fetcher/stream-wrappers/webpack.test.ts b/tests/unit/fetcher/stream-wrappers/webpack.test.ts new file mode 100644 index 00000000..557db6dc --- /dev/null +++ b/tests/unit/fetcher/stream-wrappers/webpack.test.ts @@ -0,0 +1,38 @@ +import webpack from "webpack"; + +describe("test env compatibility", () => { + test("webpack", () => { + return new Promise((resolve, reject) => { + webpack( + { + mode: "production", + entry: "./src/index.ts", + module: { + rules: [ + { + test: /\.tsx?$/, + use: "ts-loader", + exclude: /node_modules/, + }, + ], + }, + resolve: { + extensions: [".tsx", ".ts", ".js"], + }, + }, + (err, stats) => { + try { + expect(err).toBe(null); + if (stats?.hasErrors()) { + console.log(stats?.toString()); + } + expect(stats?.hasErrors()).toBe(false); + resolve(); + } catch (error) { + reject(error); + } + } + ); + }); + }, 60_000); +}); diff --git a/tests/unit/fetcher/test-file.txt b/tests/unit/fetcher/test-file.txt new file mode 100644 index 00000000..c66d471e --- /dev/null +++ b/tests/unit/fetcher/test-file.txt @@ -0,0 +1 @@ +This is a test file! diff --git a/tsconfig.json b/tsconfig.json index aa3a2e02..538c94fe 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,29 +1,17 @@ { "compilerOptions": { - "lib": ["es5", "es6"], - "outDir": "./dist", - "allowSyntheticDefaultImports": true, - "esModuleInterop": true, - "target": "es5", - "module": "commonjs", + "extendedDiagnostics": true, + "strict": true, + "target": "ES6", + "module": "CommonJS", "moduleResolution": "node", - "emitDecoratorMetadata": true, - "experimentalDecorators": true, - "sourceMap": true, - "noImplicitAny": true, - "noFallthroughCasesInSwitch": true, - "noImplicitReturns": true, - "stripInternal": true, - "pretty": true, - "strictNullChecks": true, - "noUnusedLocals": true, - "downlevelIteration": true, - "rootDir": ".", - // Ensure that .d.ts files are created by tsc, but not .js files + "esModuleInterop": true, + "skipLibCheck": true, "declaration": true, - "declarationMap": true, - "resolveJsonModule": true + "outDir": "dist", + "rootDir": "src", + "baseUrl": "src" }, - "include": ["lib/**/*"], - "exclude": ["node_modules"] + "include": ["src"], + "exclude": [] } diff --git a/yarn.lock b/yarn.lock index ccf47422..281e9091 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1,4027 +1,3165 @@ -# This file is generated by running "yarn install" inside your project. -# Manual changes might be lost - proceed with caution! - -__metadata: - version: 5 - cacheKey: 8 - -"@aashutoshrathi/word-wrap@npm:^1.2.3": - version: 1.2.6 - resolution: "@aashutoshrathi/word-wrap@npm:1.2.6" - checksum: ada901b9e7c680d190f1d012c84217ce0063d8f5c5a7725bb91ec3c5ed99bb7572680eb2d2938a531ccbaec39a95422fcd8a6b4a13110c7d98dd75402f66a0cd - languageName: node - linkType: hard - -"@ampproject/remapping@npm:^2.2.0": - version: 2.2.1 - resolution: "@ampproject/remapping@npm:2.2.1" - dependencies: - "@jridgewell/gen-mapping": ^0.3.0 - "@jridgewell/trace-mapping": ^0.3.9 - checksum: 03c04fd526acc64a1f4df22651186f3e5ef0a9d6d6530ce4482ec9841269cf7a11dbb8af79237c282d721c5312024ff17529cd72cc4768c11e999b58e2302079 - languageName: node - linkType: hard - -"@babel/code-frame@npm:^7.22.13": - version: 7.22.13 - resolution: "@babel/code-frame@npm:7.22.13" - dependencies: - "@babel/highlight": ^7.22.13 - chalk: ^2.4.2 - checksum: 22e342c8077c8b77eeb11f554ecca2ba14153f707b85294fcf6070b6f6150aae88a7b7436dd88d8c9289970585f3fe5b9b941c5aa3aa26a6d5a8ef3f292da058 - languageName: node - linkType: hard - -"@babel/code-frame@npm:^7.22.5": - version: 7.22.5 - resolution: "@babel/code-frame@npm:7.22.5" - dependencies: - "@babel/highlight": ^7.22.5 - checksum: cfe804f518f53faaf9a1d3e0f9f74127ab9a004912c3a16fda07fb6a633393ecb9918a053cb71804204c1b7ec3d49e1699604715e2cfb0c9f7bc4933d324ebb6 - languageName: node - linkType: hard - -"@babel/compat-data@npm:^7.22.6": - version: 7.22.6 - resolution: "@babel/compat-data@npm:7.22.6" - checksum: b88631143a2ebdb75e5bac47984e950983294f1739c2133f32569c6f2fcee85f83634bb6cf4378afb44fa8eb7877d11e48811d1e6a52afa161f82276ffdc3fb4 - languageName: node - linkType: hard - -"@babel/core@npm:^7.7.5": - version: 7.22.8 - resolution: "@babel/core@npm:7.22.8" - dependencies: - "@ampproject/remapping": ^2.2.0 - "@babel/code-frame": ^7.22.5 - "@babel/generator": ^7.22.7 - "@babel/helper-compilation-targets": ^7.22.6 - "@babel/helper-module-transforms": ^7.22.5 - "@babel/helpers": ^7.22.6 - "@babel/parser": ^7.22.7 - "@babel/template": ^7.22.5 - "@babel/traverse": ^7.22.8 - "@babel/types": ^7.22.5 - "@nicolo-ribaudo/semver-v6": ^6.3.3 - convert-source-map: ^1.7.0 - debug: ^4.1.0 - gensync: ^1.0.0-beta.2 - json5: ^2.2.2 - checksum: 75ed701c14ad17070382ae1dd166f7534b31f2c71e00995a5f261ee2398ee96335b0736573b8ff24ab6e3e6f5814ee2a48fa11ab90fabcd3dfc70ea87c5f30a6 - languageName: node - linkType: hard - -"@babel/generator@npm:^7.22.7": - version: 7.22.7 - resolution: "@babel/generator@npm:7.22.7" - dependencies: - "@babel/types": ^7.22.5 - "@jridgewell/gen-mapping": ^0.3.2 - "@jridgewell/trace-mapping": ^0.3.17 - jsesc: ^2.5.1 - checksum: cee15558888bdf5564e19cfaf95101b2910fa425f30cc1a25ac9b8621bd62b63544eb1b36ad89c80b5e41915699219f78712cab128d1f7e3da6a21fbf4143927 - languageName: node - linkType: hard - -"@babel/generator@npm:^7.23.0": - version: 7.23.0 - resolution: "@babel/generator@npm:7.23.0" - dependencies: - "@babel/types": ^7.23.0 - "@jridgewell/gen-mapping": ^0.3.2 - "@jridgewell/trace-mapping": ^0.3.17 - jsesc: ^2.5.1 - checksum: 8efe24adad34300f1f8ea2add420b28171a646edc70f2a1b3e1683842f23b8b7ffa7e35ef0119294e1901f45bfea5b3dc70abe1f10a1917ccdfb41bed69be5f1 - languageName: node - linkType: hard - -"@babel/helper-compilation-targets@npm:^7.22.6": - version: 7.22.6 - resolution: "@babel/helper-compilation-targets@npm:7.22.6" - dependencies: - "@babel/compat-data": ^7.22.6 - "@babel/helper-validator-option": ^7.22.5 - "@nicolo-ribaudo/semver-v6": ^6.3.3 - browserslist: ^4.21.9 - lru-cache: ^5.1.1 - peerDependencies: - "@babel/core": ^7.0.0 - checksum: c7788c48099c4f0edf2adeb367a941a930d39ed7453140ceb10d7114c4091922adf56d3cdd832050fd4501f25e872886390629042ddd365d3bce2ecad69ed394 - languageName: node - linkType: hard - -"@babel/helper-environment-visitor@npm:^7.22.20": - version: 7.22.20 - resolution: "@babel/helper-environment-visitor@npm:7.22.20" - checksum: d80ee98ff66f41e233f36ca1921774c37e88a803b2f7dca3db7c057a5fea0473804db9fb6729e5dbfd07f4bed722d60f7852035c2c739382e84c335661590b69 - languageName: node - linkType: hard - -"@babel/helper-environment-visitor@npm:^7.22.5": - version: 7.22.5 - resolution: "@babel/helper-environment-visitor@npm:7.22.5" - checksum: 248532077d732a34cd0844eb7b078ff917c3a8ec81a7f133593f71a860a582f05b60f818dc5049c2212e5baa12289c27889a4b81d56ef409b4863db49646c4b1 - languageName: node - linkType: hard - -"@babel/helper-function-name@npm:^7.23.0": - version: 7.23.0 - resolution: "@babel/helper-function-name@npm:7.23.0" - dependencies: - "@babel/template": ^7.22.15 - "@babel/types": ^7.23.0 - checksum: e44542257b2d4634a1f979244eb2a4ad8e6d75eb6761b4cfceb56b562f7db150d134bc538c8e6adca3783e3bc31be949071527aa8e3aab7867d1ad2d84a26e10 - languageName: node - linkType: hard - -"@babel/helper-hoist-variables@npm:^7.22.5": - version: 7.22.5 - resolution: "@babel/helper-hoist-variables@npm:7.22.5" - dependencies: - "@babel/types": ^7.22.5 - checksum: 394ca191b4ac908a76e7c50ab52102669efe3a1c277033e49467913c7ed6f7c64d7eacbeabf3bed39ea1f41731e22993f763b1edce0f74ff8563fd1f380d92cc - languageName: node - linkType: hard - -"@babel/helper-module-imports@npm:^7.22.5": - version: 7.22.5 - resolution: "@babel/helper-module-imports@npm:7.22.5" - dependencies: - "@babel/types": ^7.22.5 - checksum: 9ac2b0404fa38b80bdf2653fbeaf8e8a43ccb41bd505f9741d820ed95d3c4e037c62a1bcdcb6c9527d7798d2e595924c4d025daed73283badc180ada2c9c49ad - languageName: node - linkType: hard - -"@babel/helper-module-transforms@npm:^7.22.5": - version: 7.22.5 - resolution: "@babel/helper-module-transforms@npm:7.22.5" - dependencies: - "@babel/helper-environment-visitor": ^7.22.5 - "@babel/helper-module-imports": ^7.22.5 - "@babel/helper-simple-access": ^7.22.5 - "@babel/helper-split-export-declaration": ^7.22.5 - "@babel/helper-validator-identifier": ^7.22.5 - "@babel/template": ^7.22.5 - "@babel/traverse": ^7.22.5 - "@babel/types": ^7.22.5 - checksum: 8985dc0d971fd17c467e8b84fe0f50f3dd8610e33b6c86e5b3ca8e8859f9448bcc5c84e08a2a14285ef388351c0484797081c8f05a03770bf44fc27bf4900e68 - languageName: node - linkType: hard - -"@babel/helper-simple-access@npm:^7.22.5": - version: 7.22.5 - resolution: "@babel/helper-simple-access@npm:7.22.5" - dependencies: - "@babel/types": ^7.22.5 - checksum: fe9686714caf7d70aedb46c3cce090f8b915b206e09225f1e4dbc416786c2fdbbee40b38b23c268b7ccef749dd2db35f255338fb4f2444429874d900dede5ad2 - languageName: node - linkType: hard - -"@babel/helper-split-export-declaration@npm:^7.22.5, @babel/helper-split-export-declaration@npm:^7.22.6": - version: 7.22.6 - resolution: "@babel/helper-split-export-declaration@npm:7.22.6" - dependencies: - "@babel/types": ^7.22.5 - checksum: e141cace583b19d9195f9c2b8e17a3ae913b7ee9b8120246d0f9ca349ca6f03cb2c001fd5ec57488c544347c0bb584afec66c936511e447fd20a360e591ac921 - languageName: node - linkType: hard - -"@babel/helper-string-parser@npm:^7.22.5": - version: 7.22.5 - resolution: "@babel/helper-string-parser@npm:7.22.5" - checksum: 836851ca5ec813077bbb303acc992d75a360267aa3b5de7134d220411c852a6f17de7c0d0b8c8dcc0f567f67874c00f4528672b2a4f1bc978a3ada64c8c78467 - languageName: node - linkType: hard - -"@babel/helper-validator-identifier@npm:^7.22.20": - version: 7.22.20 - resolution: "@babel/helper-validator-identifier@npm:7.22.20" - checksum: 136412784d9428266bcdd4d91c32bcf9ff0e8d25534a9d94b044f77fe76bc50f941a90319b05aafd1ec04f7d127cd57a179a3716009ff7f3412ef835ada95bdc - languageName: node - linkType: hard - -"@babel/helper-validator-identifier@npm:^7.22.5": - version: 7.22.5 - resolution: "@babel/helper-validator-identifier@npm:7.22.5" - checksum: 7f0f30113474a28298c12161763b49de5018732290ca4de13cdaefd4fd0d635a6fe3f6686c37a02905fb1e64f21a5ee2b55140cf7b070e729f1bd66866506aea - languageName: node - linkType: hard - -"@babel/helper-validator-option@npm:^7.22.5": - version: 7.22.5 - resolution: "@babel/helper-validator-option@npm:7.22.5" - checksum: bbeca8a85ee86990215c0424997438b388b8d642d69b9f86c375a174d3cdeb270efafd1ff128bc7a1d370923d13b6e45829ba8581c027620e83e3a80c5c414b3 - languageName: node - linkType: hard - -"@babel/helpers@npm:^7.22.6": - version: 7.22.6 - resolution: "@babel/helpers@npm:7.22.6" - dependencies: - "@babel/template": ^7.22.5 - "@babel/traverse": ^7.22.6 - "@babel/types": ^7.22.5 - checksum: 5c1f33241fe7bf7709868c2105134a0a86dca26a0fbd508af10a89312b1f77ca38ebae43e50be3b208613c5eacca1559618af4ca236f0abc55d294800faeff30 - languageName: node - linkType: hard - -"@babel/highlight@npm:^7.22.13": - version: 7.22.20 - resolution: "@babel/highlight@npm:7.22.20" - dependencies: - "@babel/helper-validator-identifier": ^7.22.20 - chalk: ^2.4.2 - js-tokens: ^4.0.0 - checksum: 84bd034dca309a5e680083cd827a766780ca63cef37308404f17653d32366ea76262bd2364b2d38776232f2d01b649f26721417d507e8b4b6da3e4e739f6d134 - languageName: node - linkType: hard - -"@babel/highlight@npm:^7.22.5": - version: 7.22.5 - resolution: "@babel/highlight@npm:7.22.5" - dependencies: - "@babel/helper-validator-identifier": ^7.22.5 - chalk: ^2.0.0 - js-tokens: ^4.0.0 - checksum: f61ae6de6ee0ea8d9b5bcf2a532faec5ab0a1dc0f7c640e5047fc61630a0edb88b18d8c92eb06566d30da7a27db841aca11820ecd3ebe9ce514c9350fbed39c4 - languageName: node - linkType: hard - -"@babel/parser@npm:^7.22.15, @babel/parser@npm:^7.23.0": - version: 7.23.0 - resolution: "@babel/parser@npm:7.23.0" - bin: - parser: ./bin/babel-parser.js - checksum: 453fdf8b9e2c2b7d7b02139e0ce003d1af21947bbc03eb350fb248ee335c9b85e4ab41697ddbdd97079698de825a265e45a0846bb2ed47a2c7c1df833f42a354 - languageName: node - linkType: hard - -"@babel/parser@npm:^7.22.5, @babel/parser@npm:^7.22.7": - version: 7.22.7 - resolution: "@babel/parser@npm:7.22.7" - bin: - parser: ./bin/babel-parser.js - checksum: 02209ddbd445831ee8bf966fdf7c29d189ed4b14343a68eb2479d940e7e3846340d7cc6bd654a5f3d87d19dc84f49f50a58cf9363bee249dc5409ff3ba3dab54 - languageName: node - linkType: hard - -"@babel/template@npm:^7.22.15": - version: 7.22.15 - resolution: "@babel/template@npm:7.22.15" - dependencies: - "@babel/code-frame": ^7.22.13 - "@babel/parser": ^7.22.15 - "@babel/types": ^7.22.15 - checksum: 1f3e7dcd6c44f5904c184b3f7fe280394b191f2fed819919ffa1e529c259d5b197da8981b6ca491c235aee8dbad4a50b7e31304aa531271cb823a4a24a0dd8fd - languageName: node - linkType: hard - -"@babel/template@npm:^7.22.5": - version: 7.22.5 - resolution: "@babel/template@npm:7.22.5" - dependencies: - "@babel/code-frame": ^7.22.5 - "@babel/parser": ^7.22.5 - "@babel/types": ^7.22.5 - checksum: c5746410164039aca61829cdb42e9a55410f43cace6f51ca443313f3d0bdfa9a5a330d0b0df73dc17ef885c72104234ae05efede37c1cc8a72dc9f93425977a3 - languageName: node - linkType: hard - -"@babel/traverse@npm:^7.22.5, @babel/traverse@npm:^7.22.6, @babel/traverse@npm:^7.22.8": - version: 7.23.2 - resolution: "@babel/traverse@npm:7.23.2" - dependencies: - "@babel/code-frame": ^7.22.13 - "@babel/generator": ^7.23.0 - "@babel/helper-environment-visitor": ^7.22.20 - "@babel/helper-function-name": ^7.23.0 - "@babel/helper-hoist-variables": ^7.22.5 - "@babel/helper-split-export-declaration": ^7.22.6 - "@babel/parser": ^7.23.0 - "@babel/types": ^7.23.0 - debug: ^4.1.0 - globals: ^11.1.0 - checksum: 26a1eea0dde41ab99dde8b9773a013a0dc50324e5110a049f5d634e721ff08afffd54940b3974a20308d7952085ac769689369e9127dea655f868c0f6e1ab35d - languageName: node - linkType: hard - -"@babel/types@npm:^7.22.15, @babel/types@npm:^7.23.0": - version: 7.23.0 - resolution: "@babel/types@npm:7.23.0" - dependencies: - "@babel/helper-string-parser": ^7.22.5 - "@babel/helper-validator-identifier": ^7.22.20 - to-fast-properties: ^2.0.0 - checksum: 215fe04bd7feef79eeb4d33374b39909ce9cad1611c4135a4f7fdf41fe3280594105af6d7094354751514625ea92d0875aba355f53e86a92600f290e77b0e604 - languageName: node - linkType: hard - -"@babel/types@npm:^7.22.5, @babel/types@npm:^7.8.3": - version: 7.22.5 - resolution: "@babel/types@npm:7.22.5" - dependencies: - "@babel/helper-string-parser": ^7.22.5 - "@babel/helper-validator-identifier": ^7.22.5 - to-fast-properties: ^2.0.0 - checksum: c13a9c1dc7d2d1a241a2f8363540cb9af1d66e978e8984b400a20c4f38ba38ca29f06e26a0f2d49a70bad9e57615dac09c35accfddf1bb90d23cd3e0a0bab892 - languageName: node - linkType: hard - -"@cspotcode/source-map-support@npm:^0.8.0": - version: 0.8.1 - resolution: "@cspotcode/source-map-support@npm:0.8.1" - dependencies: - "@jridgewell/trace-mapping": 0.3.9 - checksum: 5718f267085ed8edb3e7ef210137241775e607ee18b77d95aa5bd7514f47f5019aa2d82d96b3bf342ef7aa890a346fa1044532ff7cc3009e7d24fce3ce6200fa - languageName: node - linkType: hard - -"@eslint-community/eslint-utils@npm:^4.2.0": - version: 4.4.0 - resolution: "@eslint-community/eslint-utils@npm:4.4.0" - dependencies: - eslint-visitor-keys: ^3.3.0 - peerDependencies: - eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 - checksum: cdfe3ae42b4f572cbfb46d20edafe6f36fc5fb52bf2d90875c58aefe226892b9677fef60820e2832caf864a326fe4fc225714c46e8389ccca04d5f9288aabd22 - languageName: node - linkType: hard - -"@eslint-community/regexpp@npm:^4.4.0": - version: 4.5.1 - resolution: "@eslint-community/regexpp@npm:4.5.1" - checksum: 6d901166d64998d591fab4db1c2f872981ccd5f6fe066a1ad0a93d4e11855ecae6bfb76660869a469563e8882d4307228cebd41142adb409d182f2966771e57e - languageName: node - linkType: hard - -"@eslint/eslintrc@npm:^2.1.0": - version: 2.1.0 - resolution: "@eslint/eslintrc@npm:2.1.0" - dependencies: - ajv: ^6.12.4 - debug: ^4.3.2 - espree: ^9.6.0 - globals: ^13.19.0 - ignore: ^5.2.0 - import-fresh: ^3.2.1 - js-yaml: ^4.1.0 - minimatch: ^3.1.2 - strip-json-comments: ^3.1.1 - checksum: d5ed0adbe23f6571d8c9bb0ca6edf7618dc6aed4046aa56df7139f65ae7b578874e0d9c796df784c25bda648ceb754b6320277d828c8b004876d7443b8dc018c - languageName: node - linkType: hard - -"@eslint/js@npm:8.44.0": - version: 8.44.0 - resolution: "@eslint/js@npm:8.44.0" - checksum: fc539583226a28f5677356e9f00d2789c34253f076643d2e32888250e509a4e13aafe0880cb2425139051de0f3a48d25bfc5afa96b7304f203b706c17340e3cf - languageName: node - linkType: hard - -"@humanwhocodes/config-array@npm:^0.11.10": - version: 0.11.10 - resolution: "@humanwhocodes/config-array@npm:0.11.10" - dependencies: - "@humanwhocodes/object-schema": ^1.2.1 - debug: ^4.1.1 - minimatch: ^3.0.5 - checksum: 1b1302e2403d0e35bc43e66d67a2b36b0ad1119efc704b5faff68c41f791a052355b010fb2d27ef022670f550de24cd6d08d5ecf0821c16326b7dcd0ee5d5d8a - languageName: node - linkType: hard - -"@humanwhocodes/module-importer@npm:^1.0.1": - version: 1.0.1 - resolution: "@humanwhocodes/module-importer@npm:1.0.1" - checksum: 0fd22007db8034a2cdf2c764b140d37d9020bbfce8a49d3ec5c05290e77d4b0263b1b972b752df8c89e5eaa94073408f2b7d977aed131faf6cf396ebb5d7fb61 - languageName: node - linkType: hard - -"@humanwhocodes/object-schema@npm:^1.2.1": - version: 1.2.1 - resolution: "@humanwhocodes/object-schema@npm:1.2.1" - checksum: a824a1ec31591231e4bad5787641f59e9633827d0a2eaae131a288d33c9ef0290bd16fda8da6f7c0fcb014147865d12118df10db57f27f41e20da92369fcb3f1 - languageName: node - linkType: hard - -"@isaacs/cliui@npm:^8.0.2": - version: 8.0.2 - resolution: "@isaacs/cliui@npm:8.0.2" - dependencies: - string-width: ^5.1.2 - string-width-cjs: "npm:string-width@^4.2.0" - strip-ansi: ^7.0.1 - strip-ansi-cjs: "npm:strip-ansi@^6.0.1" - wrap-ansi: ^8.1.0 - wrap-ansi-cjs: "npm:wrap-ansi@^7.0.0" - checksum: 4a473b9b32a7d4d3cfb7a614226e555091ff0c5a29a1734c28c72a182c2f6699b26fc6b5c2131dfd841e86b185aea714c72201d7c98c2fba5f17709333a67aeb - languageName: node - linkType: hard - -"@istanbuljs/load-nyc-config@npm:^1.0.0": - version: 1.1.0 - resolution: "@istanbuljs/load-nyc-config@npm:1.1.0" - dependencies: - camelcase: ^5.3.1 - find-up: ^4.1.0 - get-package-type: ^0.1.0 - js-yaml: ^3.13.1 - resolve-from: ^5.0.0 - checksum: d578da5e2e804d5c93228450a1380e1a3c691de4953acc162f387b717258512a3e07b83510a936d9fab03eac90817473917e24f5d16297af3867f59328d58568 - languageName: node - linkType: hard - -"@istanbuljs/nyc-config-typescript@npm:^1.0.2": - version: 1.0.2 - resolution: "@istanbuljs/nyc-config-typescript@npm:1.0.2" - dependencies: - "@istanbuljs/schema": ^0.1.2 - peerDependencies: - nyc: ">=15" - checksum: df6f9c9b17df8f1d8813f768c11ca31ec125d60bcd82d8273a467022e414d2d686ee80abb7b0f0e3c512b7ed686771fadb7fb5be8881619b9f6cb1f31b86e9f3 - languageName: node - linkType: hard - -"@istanbuljs/schema@npm:^0.1.2": - version: 0.1.3 - resolution: "@istanbuljs/schema@npm:0.1.3" - checksum: 5282759d961d61350f33d9118d16bcaed914ebf8061a52f4fa474b2cb08720c9c81d165e13b82f2e5a8a212cc5af482f0c6fc1ac27b9e067e5394c9a6ed186c9 - languageName: node - linkType: hard - -"@jridgewell/gen-mapping@npm:^0.3.0, @jridgewell/gen-mapping@npm:^0.3.2": - version: 0.3.3 - resolution: "@jridgewell/gen-mapping@npm:0.3.3" - dependencies: - "@jridgewell/set-array": ^1.0.1 - "@jridgewell/sourcemap-codec": ^1.4.10 - "@jridgewell/trace-mapping": ^0.3.9 - checksum: 4a74944bd31f22354fc01c3da32e83c19e519e3bbadafa114f6da4522ea77dd0c2842607e923a591d60a76699d819a2fbb6f3552e277efdb9b58b081390b60ab - languageName: node - linkType: hard - -"@jridgewell/resolve-uri@npm:3.1.0": - version: 3.1.0 - resolution: "@jridgewell/resolve-uri@npm:3.1.0" - checksum: b5ceaaf9a110fcb2780d1d8f8d4a0bfd216702f31c988d8042e5f8fbe353c55d9b0f55a1733afdc64806f8e79c485d2464680ac48a0d9fcadb9548ee6b81d267 - languageName: node - linkType: hard - -"@jridgewell/resolve-uri@npm:^3.0.3": - version: 3.1.1 - resolution: "@jridgewell/resolve-uri@npm:3.1.1" - checksum: f5b441fe7900eab4f9155b3b93f9800a916257f4e8563afbcd3b5a5337b55e52bd8ae6735453b1b745457d9f6cdb16d74cd6220bbdd98cf153239e13f6cbb653 - languageName: node - linkType: hard - -"@jridgewell/set-array@npm:^1.0.1": - version: 1.1.2 - resolution: "@jridgewell/set-array@npm:1.1.2" - checksum: 69a84d5980385f396ff60a175f7177af0b8da4ddb81824cb7016a9ef914eee9806c72b6b65942003c63f7983d4f39a5c6c27185bbca88eb4690b62075602e28e - languageName: node - linkType: hard - -"@jridgewell/sourcemap-codec@npm:1.4.14": - version: 1.4.14 - resolution: "@jridgewell/sourcemap-codec@npm:1.4.14" - checksum: 61100637b6d173d3ba786a5dff019e1a74b1f394f323c1fee337ff390239f053b87266c7a948777f4b1ee68c01a8ad0ab61e5ff4abb5a012a0b091bec391ab97 - languageName: node - linkType: hard - -"@jridgewell/sourcemap-codec@npm:^1.4.10": - version: 1.4.15 - resolution: "@jridgewell/sourcemap-codec@npm:1.4.15" - checksum: b881c7e503db3fc7f3c1f35a1dd2655a188cc51a3612d76efc8a6eb74728bef5606e6758ee77423e564092b4a518aba569bbb21c9bac5ab7a35b0c6ae7e344c8 - languageName: node - linkType: hard - -"@jridgewell/trace-mapping@npm:0.3.9": - version: 0.3.9 - resolution: "@jridgewell/trace-mapping@npm:0.3.9" - dependencies: - "@jridgewell/resolve-uri": ^3.0.3 - "@jridgewell/sourcemap-codec": ^1.4.10 - checksum: d89597752fd88d3f3480845691a05a44bd21faac18e2185b6f436c3b0fd0c5a859fbbd9aaa92050c4052caf325ad3e10e2e1d1b64327517471b7d51babc0ddef - languageName: node - linkType: hard - -"@jridgewell/trace-mapping@npm:^0.3.17, @jridgewell/trace-mapping@npm:^0.3.9": - version: 0.3.18 - resolution: "@jridgewell/trace-mapping@npm:0.3.18" - dependencies: - "@jridgewell/resolve-uri": 3.1.0 - "@jridgewell/sourcemap-codec": 1.4.14 - checksum: 0572669f855260808c16fe8f78f5f1b4356463b11d3f2c7c0b5580c8ba1cbf4ae53efe9f627595830856e57dbac2325ac17eb0c3dd0ec42102e6f227cc289c02 - languageName: node - linkType: hard - -"@nicolo-ribaudo/semver-v6@npm:^6.3.3": - version: 6.3.3 - resolution: "@nicolo-ribaudo/semver-v6@npm:6.3.3" - bin: - semver: bin/semver.js - checksum: 8290855b1591477d2298364541fda64fafd4acc110b387067a71c9b05f4105c0a4ac079857ae9cd107c42ee884e8724a406b5116f069575e02d7ab87a35a5272 - languageName: node - linkType: hard - -"@nodelib/fs.scandir@npm:2.1.5": - version: 2.1.5 - resolution: "@nodelib/fs.scandir@npm:2.1.5" - dependencies: - "@nodelib/fs.stat": 2.0.5 - run-parallel: ^1.1.9 - checksum: a970d595bd23c66c880e0ef1817791432dbb7acbb8d44b7e7d0e7a22f4521260d4a83f7f9fd61d44fda4610105577f8f58a60718105fb38352baed612fd79e59 - languageName: node - linkType: hard - -"@nodelib/fs.stat@npm:2.0.5, @nodelib/fs.stat@npm:^2.0.2": - version: 2.0.5 - resolution: "@nodelib/fs.stat@npm:2.0.5" - checksum: 012480b5ca9d97bff9261571dbbec7bbc6033f69cc92908bc1ecfad0792361a5a1994bc48674b9ef76419d056a03efadfce5a6cf6dbc0a36559571a7a483f6f0 - languageName: node - linkType: hard - -"@nodelib/fs.walk@npm:^1.2.3, @nodelib/fs.walk@npm:^1.2.8": - version: 1.2.8 - resolution: "@nodelib/fs.walk@npm:1.2.8" - dependencies: - "@nodelib/fs.scandir": 2.1.5 - fastq: ^1.6.0 - checksum: 190c643f156d8f8f277bf2a6078af1ffde1fd43f498f187c2db24d35b4b4b5785c02c7dc52e356497b9a1b65b13edc996de08de0b961c32844364da02986dc53 - languageName: node - linkType: hard - -"@npmcli/fs@npm:^3.1.0": - version: 3.1.0 - resolution: "@npmcli/fs@npm:3.1.0" - dependencies: - semver: ^7.3.5 - checksum: a50a6818de5fc557d0b0e6f50ec780a7a02ab8ad07e5ac8b16bf519e0ad60a144ac64f97d05c443c3367235d337182e1d012bbac0eb8dbae8dc7b40b193efd0e - languageName: node - linkType: hard - -"@pkgjs/parseargs@npm:^0.11.0": - version: 0.11.0 - resolution: "@pkgjs/parseargs@npm:0.11.0" - checksum: 6ad6a00fc4f2f2cfc6bff76fb1d88b8ee20bc0601e18ebb01b6d4be583733a860239a521a7fbca73b612e66705078809483549d2b18f370eb346c5155c8e4a0f - languageName: node - linkType: hard - -"@sinonjs/commons@npm:^1, @sinonjs/commons@npm:^1.3.0, @sinonjs/commons@npm:^1.4.0, @sinonjs/commons@npm:^1.7.0": - version: 1.8.6 - resolution: "@sinonjs/commons@npm:1.8.6" - dependencies: - type-detect: 4.0.8 - checksum: 7d3f8c1e85f30cd4e83594fc19b7a657f14d49eb8d95a30095631ce15e906c869e0eff96c5b93dffea7490c00418b07f54582ba49c6560feb2a8c34c0b16832d - languageName: node - linkType: hard - -"@sinonjs/formatio@npm:^3.2.1": - version: 3.2.2 - resolution: "@sinonjs/formatio@npm:3.2.2" - dependencies: - "@sinonjs/commons": ^1 - "@sinonjs/samsam": ^3.1.0 - checksum: ddc30698df9b0aa59204da93ca94fd04bc5672ac03c798c0a487c35d514d7d8e0ce0e4c72386fc80e29f59cb1cc54eeea3b7f804281b3c4e3dd2394de56c6e4a - languageName: node - linkType: hard - -"@sinonjs/samsam@npm:^3.1.0, @sinonjs/samsam@npm:^3.3.3": - version: 3.3.3 - resolution: "@sinonjs/samsam@npm:3.3.3" - dependencies: - "@sinonjs/commons": ^1.3.0 - array-from: ^2.1.1 - lodash: ^4.17.15 - checksum: 340f2f62dec3fa1e5e9300a75996bd12ab9d2da4f6b453fa5d1ee101cc5e58eb218af2e2584b496d41ba31c3c0854d47a691fd9a0d8b9092f3cb6a5c7a080856 - languageName: node - linkType: hard - -"@sinonjs/text-encoding@npm:^0.7.1": - version: 0.7.2 - resolution: "@sinonjs/text-encoding@npm:0.7.2" - checksum: fe690002a32ba06906cf87e2e8fe84d1590294586f2a7fd180a65355b53660c155c3273d8011a5f2b77209b819aa7306678ae6e4aea0df014bd7ffd4bbbcf1ab - languageName: node - linkType: hard - -"@tootallnate/once@npm:2": - version: 2.0.0 - resolution: "@tootallnate/once@npm:2.0.0" - checksum: ad87447820dd3f24825d2d947ebc03072b20a42bfc96cbafec16bff8bbda6c1a81fcb0be56d5b21968560c5359a0af4038a68ba150c3e1694fe4c109a063bed8 - languageName: node - linkType: hard - -"@tsconfig/node10@npm:^1.0.7": - version: 1.0.9 - resolution: "@tsconfig/node10@npm:1.0.9" - checksum: a33ae4dc2a621c0678ac8ac4bceb8e512ae75dac65417a2ad9b022d9b5411e863c4c198b6ba9ef659e14b9fb609bbec680841a2e84c1172df7a5ffcf076539df - languageName: node - linkType: hard - -"@tsconfig/node12@npm:^1.0.7": - version: 1.0.11 - resolution: "@tsconfig/node12@npm:1.0.11" - checksum: 5ce29a41b13e7897a58b8e2df11269c5395999e588b9a467386f99d1d26f6c77d1af2719e407621412520ea30517d718d5192a32403b8dfcc163bf33e40a338a - languageName: node - linkType: hard - -"@tsconfig/node14@npm:^1.0.0": - version: 1.0.3 - resolution: "@tsconfig/node14@npm:1.0.3" - checksum: 19275fe80c4c8d0ad0abed6a96dbf00642e88b220b090418609c4376e1cef81bf16237bf170ad1b341452feddb8115d8dd2e5acdfdea1b27422071163dc9ba9d - languageName: node - linkType: hard - -"@tsconfig/node16@npm:^1.0.2": - version: 1.0.4 - resolution: "@tsconfig/node16@npm:1.0.4" - checksum: 202319785901f942a6e1e476b872d421baec20cf09f4b266a1854060efbf78cde16a4d256e8bc949d31e6cd9a90f1e8ef8fb06af96a65e98338a2b6b0de0a0ff - languageName: node - linkType: hard - -"@types/json-schema@npm:^7.0.9": - version: 7.0.12 - resolution: "@types/json-schema@npm:7.0.12" - checksum: 00239e97234eeb5ceefb0c1875d98ade6e922bfec39dd365ec6bd360b5c2f825e612ac4f6e5f1d13601b8b30f378f15e6faa805a3a732f4a1bbe61915163d293 - languageName: node - linkType: hard - -"@types/lodash@npm:^4.14.195": - version: 4.14.195 - resolution: "@types/lodash@npm:4.14.195" - checksum: 39b75ca635b3fa943d17d3d3aabc750babe4c8212485a4df166fe0516e39288e14b0c60afc6e21913cc0e5a84734633c71e617e2bd14eaa1cf51b8d7799c432e - languageName: node - linkType: hard - -"@types/mocha@npm:^9.1.1": - version: 9.1.1 - resolution: "@types/mocha@npm:9.1.1" - checksum: 516077c0acd9806dc78317f88aaac0df5aaf0bdc2f63dfdadeabdf0b0137953b6ca65472e6ff7c30bc93ce4e0ae76eae70e8d46764b9a8eae4877a928b6ef49a - languageName: node - linkType: hard - -"@types/node@npm:^16.18.38": - version: 16.18.38 - resolution: "@types/node@npm:16.18.38" - checksum: a3baa141e49ce94486f083eea1240cf38479a73ba663e1bf3f52f85b466125821b6e3ea85ded38fde3901530aca4601291395a50eefcea533a4f3b45171bda28 - languageName: node - linkType: hard - -"@types/semver@npm:^7.3.12": - version: 7.5.0 - resolution: "@types/semver@npm:7.5.0" - checksum: 0a64b9b9c7424d9a467658b18dd70d1d781c2d6f033096a6e05762d20ebbad23c1b69b0083b0484722aabf35640b78ccc3de26368bcae1129c87e9df028a22e2 - languageName: node - linkType: hard - -"@types/sinon@npm:^10.0.15": - version: 10.0.15 - resolution: "@types/sinon@npm:10.0.15" - dependencies: - "@types/sinonjs__fake-timers": "*" - checksum: cec6d7d9d5582ca3ac851b029d5d90451bfe6d376164253792a6eb6ddcd609a0411a7fac9ed92e1879e7d3ec091d2ea2e8dbb4f6140a1065439b81dc20cafa7c - languageName: node - linkType: hard - -"@types/sinonjs__fake-timers@npm:*": - version: 8.1.2 - resolution: "@types/sinonjs__fake-timers@npm:8.1.2" - checksum: bbc73a5ab6c0ec974929392f3d6e1e8db4ebad97ec506d785301e1c3d8a4f98a35b1aa95b97035daef02886fd8efd7788a2fa3ced2ec7105988bfd8dce61eedd - languageName: node - linkType: hard - -"@typescript-eslint/eslint-plugin@npm:^5.61.0": - version: 5.61.0 - resolution: "@typescript-eslint/eslint-plugin@npm:5.61.0" - dependencies: - "@eslint-community/regexpp": ^4.4.0 - "@typescript-eslint/scope-manager": 5.61.0 - "@typescript-eslint/type-utils": 5.61.0 - "@typescript-eslint/utils": 5.61.0 - debug: ^4.3.4 - graphemer: ^1.4.0 - ignore: ^5.2.0 - natural-compare-lite: ^1.4.0 - semver: ^7.3.7 - tsutils: ^3.21.0 - peerDependencies: - "@typescript-eslint/parser": ^5.0.0 - eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 - peerDependenciesMeta: - typescript: - optional: true - checksum: d9e891fb43ccb75322fc40d58d02479f98bd3c962db71075438868b13f579643d714a24b5477a827be7ca2e7e9f6058c406241b6696a6395c6fcbd6de76e015c - languageName: node - linkType: hard - -"@typescript-eslint/parser@npm:^5.61.0": - version: 5.61.0 - resolution: "@typescript-eslint/parser@npm:5.61.0" - dependencies: - "@typescript-eslint/scope-manager": 5.61.0 - "@typescript-eslint/types": 5.61.0 - "@typescript-eslint/typescript-estree": 5.61.0 - debug: ^4.3.4 - peerDependencies: - eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 - peerDependenciesMeta: - typescript: - optional: true - checksum: 2422bca03ecc6830700aaa739ec46b8e9ab6c0a47a67f140dc6b62a42a8b98997e73bce52c6a010b8a9b461211c46ba865d5b7f680a7823cf5c245d3b61f7fd5 - languageName: node - linkType: hard - -"@typescript-eslint/scope-manager@npm:5.61.0": - version: 5.61.0 - resolution: "@typescript-eslint/scope-manager@npm:5.61.0" - dependencies: - "@typescript-eslint/types": 5.61.0 - "@typescript-eslint/visitor-keys": 5.61.0 - checksum: 6dfbb42c4b7d796ae3c395398bdfd2e5a4ae8aaf1448381278ecc39a1d1045af2cb452da5a00519d265bc1a5997523de22d5021acb4dbe1648502fe61512d3c6 - languageName: node - linkType: hard - -"@typescript-eslint/type-utils@npm:5.61.0": - version: 5.61.0 - resolution: "@typescript-eslint/type-utils@npm:5.61.0" - dependencies: - "@typescript-eslint/typescript-estree": 5.61.0 - "@typescript-eslint/utils": 5.61.0 - debug: ^4.3.4 - tsutils: ^3.21.0 - peerDependencies: - eslint: "*" - peerDependenciesMeta: - typescript: - optional: true - checksum: f0203fd48c6218f004dd73a9a71ba4cf97f015d0f13a7b3c821a3ba7ec814839bae270a1db589184ca7091fe54815a3171d1993e8a25200bf33e131bd6e855d4 - languageName: node - linkType: hard - -"@typescript-eslint/types@npm:5.61.0": - version: 5.61.0 - resolution: "@typescript-eslint/types@npm:5.61.0" - checksum: d311ca2141f6bcb5f0f8f97ddbc218c9911e0735aaa30f0f2e64d518fb33568410754e1b04bf157175f8783504f8ec62a7ab53a66a18507f43edb1e21fe69e90 - languageName: node - linkType: hard - -"@typescript-eslint/typescript-estree@npm:5.61.0": - version: 5.61.0 - resolution: "@typescript-eslint/typescript-estree@npm:5.61.0" - dependencies: - "@typescript-eslint/types": 5.61.0 - "@typescript-eslint/visitor-keys": 5.61.0 - debug: ^4.3.4 - globby: ^11.1.0 - is-glob: ^4.0.3 - semver: ^7.3.7 - tsutils: ^3.21.0 - peerDependenciesMeta: - typescript: - optional: true - checksum: efe25a1b2774939c02cb9b388cf72efa672811f1c39a87ddd617937f63c2320551ce459ba69c6d022e33322594d40b9f2d2c6bc9937387718adc40dc5e57ea8e - languageName: node - linkType: hard - -"@typescript-eslint/utils@npm:5.61.0": - version: 5.61.0 - resolution: "@typescript-eslint/utils@npm:5.61.0" - dependencies: - "@eslint-community/eslint-utils": ^4.2.0 - "@types/json-schema": ^7.0.9 - "@types/semver": ^7.3.12 - "@typescript-eslint/scope-manager": 5.61.0 - "@typescript-eslint/types": 5.61.0 - "@typescript-eslint/typescript-estree": 5.61.0 - eslint-scope: ^5.1.1 - semver: ^7.3.7 - peerDependencies: - eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 - checksum: 24efc1964e6c92db96fe0d9a390550e4f27e8f353e51a9b46bda03e6692ea5d40f398d539235a4ff0894e9e45dfcfb51df953ade2ae9d17a1421449625ce6f5a - languageName: node - linkType: hard - -"@typescript-eslint/visitor-keys@npm:5.61.0": - version: 5.61.0 - resolution: "@typescript-eslint/visitor-keys@npm:5.61.0" - dependencies: - "@typescript-eslint/types": 5.61.0 - eslint-visitor-keys: ^3.3.0 - checksum: a8d589f61ddfc380787218da4d347e8f9aef0f82f4a93f1daee46786bda889a90961c7ec1b470db5e3261438a728fdfd956f5bda6ee2de22c4be2d2152d6e270 - languageName: node - linkType: hard - -"@ungap/promise-all-settled@npm:1.1.2": - version: 1.1.2 - resolution: "@ungap/promise-all-settled@npm:1.1.2" - checksum: 08d37fdfa23a6fe8139f1305313562ebad973f3fac01bcce2773b2bda5bcb0146dfdcf3cb6a722cf0a5f2ca0bc56a827eac8f1e7b3beddc548f654addf1fc34c - languageName: node - linkType: hard - -"abbrev@npm:^1.0.0": - version: 1.1.1 - resolution: "abbrev@npm:1.1.1" - checksum: a4a97ec07d7ea112c517036882b2ac22f3109b7b19077dc656316d07d308438aac28e4d9746dc4d84bf6b1e75b4a7b0a5f3cb30592419f128ca9a8cee3bcfa17 - languageName: node - linkType: hard - -"acorn-jsx@npm:^5.3.2": - version: 5.3.2 - resolution: "acorn-jsx@npm:5.3.2" - peerDependencies: - acorn: ^6.0.0 || ^7.0.0 || ^8.0.0 - checksum: c3d3b2a89c9a056b205b69530a37b972b404ee46ec8e5b341666f9513d3163e2a4f214a71f4dfc7370f5a9c07472d2fd1c11c91c3f03d093e37637d95da98950 - languageName: node - linkType: hard - -"acorn-walk@npm:^8.1.1": - version: 8.2.0 - resolution: "acorn-walk@npm:8.2.0" - checksum: 1715e76c01dd7b2d4ca472f9c58968516a4899378a63ad5b6c2d668bba8da21a71976c14ec5f5b75f887b6317c4ae0b897ab141c831d741dc76024d8745f1ad1 - languageName: node - linkType: hard - -"acorn@npm:^8.4.1, acorn@npm:^8.9.0": - version: 8.10.0 - resolution: "acorn@npm:8.10.0" - bin: - acorn: bin/acorn - checksum: 538ba38af0cc9e5ef983aee196c4b8b4d87c0c94532334fa7e065b2c8a1f85863467bb774231aae91613fcda5e68740c15d97b1967ae3394d20faddddd8af61d - languageName: node - linkType: hard - -"agent-base@npm:6, agent-base@npm:^6.0.2": - version: 6.0.2 - resolution: "agent-base@npm:6.0.2" - dependencies: - debug: 4 - checksum: f52b6872cc96fd5f622071b71ef200e01c7c4c454ee68bc9accca90c98cfb39f2810e3e9aa330435835eedc8c23f4f8a15267f67c6e245d2b33757575bdac49d - languageName: node - linkType: hard - -"agentkeepalive@npm:^4.2.1": - version: 4.3.0 - resolution: "agentkeepalive@npm:4.3.0" - dependencies: - debug: ^4.1.0 - depd: ^2.0.0 - humanize-ms: ^1.2.1 - checksum: 982453aa44c11a06826c836025e5162c846e1200adb56f2d075400da7d32d87021b3b0a58768d949d824811f5654223d5a8a3dad120921a2439625eb847c6260 - languageName: node - linkType: hard - -"aggregate-error@npm:^3.0.0": - version: 3.1.0 - resolution: "aggregate-error@npm:3.1.0" - dependencies: - clean-stack: ^2.0.0 - indent-string: ^4.0.0 - checksum: 1101a33f21baa27a2fa8e04b698271e64616b886795fd43c31068c07533c7b3facfcaf4e9e0cab3624bd88f729a592f1c901a1a229c9e490eafce411a8644b79 - languageName: node - linkType: hard - -"ajv@npm:^6.10.0, ajv@npm:^6.12.4": - version: 6.12.6 - resolution: "ajv@npm:6.12.6" - dependencies: - fast-deep-equal: ^3.1.1 - fast-json-stable-stringify: ^2.0.0 - json-schema-traverse: ^0.4.1 - uri-js: ^4.2.2 - checksum: 874972efe5c4202ab0a68379481fbd3d1b5d0a7bd6d3cc21d40d3536ebff3352a2a1fabb632d4fd2cc7fe4cbdcd5ed6782084c9bbf7f32a1536d18f9da5007d4 - languageName: node - linkType: hard - -"ansi-colors@npm:4.1.1": - version: 4.1.1 - resolution: "ansi-colors@npm:4.1.1" - checksum: 138d04a51076cb085da0a7e2d000c5c0bb09f6e772ed5c65c53cb118d37f6c5f1637506d7155fb5f330f0abcf6f12fa2e489ac3f8cdab9da393bf1bb4f9a32b0 - languageName: node - linkType: hard - -"ansi-regex@npm:^5.0.1": - version: 5.0.1 - resolution: "ansi-regex@npm:5.0.1" - checksum: 2aa4bb54caf2d622f1afdad09441695af2a83aa3fe8b8afa581d205e57ed4261c183c4d3877cee25794443fde5876417d859c108078ab788d6af7e4fe52eb66b - languageName: node - linkType: hard - -"ansi-regex@npm:^6.0.1": - version: 6.0.1 - resolution: "ansi-regex@npm:6.0.1" - checksum: 1ff8b7667cded1de4fa2c9ae283e979fc87036864317da86a2e546725f96406746411d0d85e87a2d12fa5abd715d90006de7fa4fa0477c92321ad3b4c7d4e169 - languageName: node - linkType: hard - -"ansi-styles@npm:^3.2.1": - version: 3.2.1 - resolution: "ansi-styles@npm:3.2.1" - dependencies: - color-convert: ^1.9.0 - checksum: d85ade01c10e5dd77b6c89f34ed7531da5830d2cb5882c645f330079975b716438cd7ebb81d0d6e6b4f9c577f19ae41ab55f07f19786b02f9dfd9e0377395665 - languageName: node - linkType: hard - -"ansi-styles@npm:^4.0.0, ansi-styles@npm:^4.1.0": - version: 4.3.0 - resolution: "ansi-styles@npm:4.3.0" - dependencies: - color-convert: ^2.0.1 - checksum: 513b44c3b2105dd14cc42a19271e80f386466c4be574bccf60b627432f9198571ebf4ab1e4c3ba17347658f4ee1711c163d574248c0c1cdc2d5917a0ad582ec4 - languageName: node - linkType: hard - -"ansi-styles@npm:^6.1.0": - version: 6.2.1 - resolution: "ansi-styles@npm:6.2.1" - checksum: ef940f2f0ced1a6347398da88a91da7930c33ecac3c77b72c5905f8b8fe402c52e6fde304ff5347f616e27a742da3f1dc76de98f6866c69251ad0b07a66776d9 - languageName: node - linkType: hard - -"anymatch@npm:~3.1.2": - version: 3.1.3 - resolution: "anymatch@npm:3.1.3" - dependencies: - normalize-path: ^3.0.0 - picomatch: ^2.0.4 - checksum: 3e044fd6d1d26545f235a9fe4d7a534e2029d8e59fa7fd9f2a6eb21230f6b5380ea1eaf55136e60cbf8e613544b3b766e7a6fa2102e2a3a117505466e3025dc2 - languageName: node - linkType: hard - -"append-transform@npm:^2.0.0": - version: 2.0.0 - resolution: "append-transform@npm:2.0.0" - dependencies: - default-require-extensions: ^3.0.0 - checksum: f26f393bf7a428fd1bb18f2758a819830a582243310c5170edb3f98fdc5a535333d02b952f7c2d9b14522bd8ead5b132a0b15000eca18fa9f49172963ebbc231 - languageName: node - linkType: hard - -"aproba@npm:^1.0.3 || ^2.0.0": - version: 2.0.0 - resolution: "aproba@npm:2.0.0" - checksum: 5615cadcfb45289eea63f8afd064ab656006361020e1735112e346593856f87435e02d8dcc7ff0d11928bc7d425f27bc7c2a84f6c0b35ab0ff659c814c138a24 - languageName: node - linkType: hard - -"archy@npm:^1.0.0": - version: 1.0.0 - resolution: "archy@npm:1.0.0" - checksum: 504ae7af655130bab9f471343cfdb054feaec7d8e300e13348bc9fe9e660f83d422e473069584f73233c701ae37d1c8452ff2522f2a20c38849e0f406f1732ac - languageName: node - linkType: hard - -"are-we-there-yet@npm:^3.0.0": - version: 3.0.1 - resolution: "are-we-there-yet@npm:3.0.1" - dependencies: - delegates: ^1.0.0 - readable-stream: ^3.6.0 - checksum: 52590c24860fa7173bedeb69a4c05fb573473e860197f618b9a28432ee4379049336727ae3a1f9c4cb083114601c1140cee578376164d0e651217a9843f9fe83 - languageName: node - linkType: hard - -"arg@npm:^4.1.0": - version: 4.1.3 - resolution: "arg@npm:4.1.3" - checksum: 544af8dd3f60546d3e4aff084d451b96961d2267d668670199692f8d054f0415d86fc5497d0e641e91546f0aa920e7c29e5250e99fc89f5552a34b5d93b77f43 - languageName: node - linkType: hard - -"argparse@npm:^1.0.7": - version: 1.0.10 - resolution: "argparse@npm:1.0.10" - dependencies: - sprintf-js: ~1.0.2 - checksum: 7ca6e45583a28de7258e39e13d81e925cfa25d7d4aacbf806a382d3c02fcb13403a07fb8aeef949f10a7cfe4a62da0e2e807b348a5980554cc28ee573ef95945 - languageName: node - linkType: hard - -"argparse@npm:^2.0.1": - version: 2.0.1 - resolution: "argparse@npm:2.0.1" - checksum: 83644b56493e89a254bae05702abf3a1101b4fa4d0ca31df1c9985275a5a5bd47b3c27b7fa0b71098d41114d8ca000e6ed90cad764b306f8a503665e4d517ced - languageName: node - linkType: hard - -"array-from@npm:^2.1.1": - version: 2.1.1 - resolution: "array-from@npm:2.1.1" - checksum: 4cd5fa27aa6133b99a57c2881d2a8a66ec59b8e17a0c900f7e8ac9a0a2fae450ed682b67435467bfa71ac9328d025a760c5c46a95586a352180c5a79fc13015d - languageName: node - linkType: hard - -"array-union@npm:^2.1.0": - version: 2.1.0 - resolution: "array-union@npm:2.1.0" - checksum: 5bee12395cba82da674931df6d0fea23c4aa4660cb3b338ced9f828782a65caa232573e6bf3968f23e0c5eb301764a382cef2f128b170a9dc59de0e36c39f98d - languageName: node - linkType: hard - -"asynckit@npm:^0.4.0": - version: 0.4.0 - resolution: "asynckit@npm:0.4.0" - checksum: 7b78c451df768adba04e2d02e63e2d0bf3b07adcd6e42b4cf665cb7ce899bedd344c69a1dcbce355b5f972d597b25aaa1c1742b52cffd9caccb22f348114f6be - languageName: node - linkType: hard - -"axios@npm:^1.6.0": - version: 1.6.1 - resolution: "axios@npm:1.6.1" - dependencies: - follow-redirects: ^1.15.0 - form-data: ^4.0.0 - proxy-from-env: ^1.1.0 - checksum: 573f03f59b7487d54551b16f5e155d1d130ad4864ed32d1da93d522b78a57123b34e3bde37f822a65ee297e79f1db840f9ad6514addff50d3cbf5caeed39e8dc - languageName: node - linkType: hard - -"balanced-match@npm:^1.0.0": - version: 1.0.2 - resolution: "balanced-match@npm:1.0.2" - checksum: 9706c088a283058a8a99e0bf91b0a2f75497f185980d9ffa8b304de1d9e58ebda7c72c07ebf01dadedaac5b2907b2c6f566f660d62bd336c3468e960403b9d65 - languageName: node - linkType: hard - -"binary-extensions@npm:^2.0.0": - version: 2.2.0 - resolution: "binary-extensions@npm:2.2.0" - checksum: ccd267956c58d2315f5d3ea6757cf09863c5fc703e50fbeb13a7dc849b812ef76e3cf9ca8f35a0c48498776a7478d7b4a0418e1e2b8cb9cb9731f2922aaad7f8 - languageName: node - linkType: hard - -"brace-expansion@npm:^1.1.7": - version: 1.1.11 - resolution: "brace-expansion@npm:1.1.11" - dependencies: - balanced-match: ^1.0.0 - concat-map: 0.0.1 - checksum: faf34a7bb0c3fcf4b59c7808bc5d2a96a40988addf2e7e09dfbb67a2251800e0d14cd2bfc1aa79174f2f5095c54ff27f46fb1289fe2d77dac755b5eb3434cc07 - languageName: node - linkType: hard - -"brace-expansion@npm:^2.0.1": - version: 2.0.1 - resolution: "brace-expansion@npm:2.0.1" - dependencies: - balanced-match: ^1.0.0 - checksum: a61e7cd2e8a8505e9f0036b3b6108ba5e926b4b55089eeb5550cd04a471fe216c96d4fe7e4c7f995c728c554ae20ddfc4244cad10aef255e72b62930afd233d1 - languageName: node - linkType: hard - -"braces@npm:^3.0.2, braces@npm:~3.0.2": - version: 3.0.2 - resolution: "braces@npm:3.0.2" - dependencies: - fill-range: ^7.0.1 - checksum: e2a8e769a863f3d4ee887b5fe21f63193a891c68b612ddb4b68d82d1b5f3ff9073af066c343e9867a393fe4c2555dcb33e89b937195feb9c1613d259edfcd459 - languageName: node - linkType: hard - -"browser-stdout@npm:1.3.1": - version: 1.3.1 - resolution: "browser-stdout@npm:1.3.1" - checksum: b717b19b25952dd6af483e368f9bcd6b14b87740c3d226c2977a65e84666ffd67000bddea7d911f111a9b6ddc822b234de42d52ab6507bce4119a4cc003ef7b3 - languageName: node - linkType: hard - -"browserslist@npm:^4.21.9": - version: 4.21.9 - resolution: "browserslist@npm:4.21.9" - dependencies: - caniuse-lite: ^1.0.30001503 - electron-to-chromium: ^1.4.431 - node-releases: ^2.0.12 - update-browserslist-db: ^1.0.11 - bin: - browserslist: cli.js - checksum: 80d3820584e211484ad1b1a5cfdeca1dd00442f47be87e117e1dda34b628c87e18b81ae7986fa5977b3e6a03154f6d13cd763baa6b8bf5dd9dd19f4926603698 - languageName: node - linkType: hard - -"cacache@npm:^17.0.0": - version: 17.1.3 - resolution: "cacache@npm:17.1.3" - dependencies: - "@npmcli/fs": ^3.1.0 - fs-minipass: ^3.0.0 - glob: ^10.2.2 - lru-cache: ^7.7.1 - minipass: ^5.0.0 - minipass-collect: ^1.0.2 - minipass-flush: ^1.0.5 - minipass-pipeline: ^1.2.4 - p-map: ^4.0.0 - ssri: ^10.0.0 - tar: ^6.1.11 - unique-filename: ^3.0.0 - checksum: 385756781e1e21af089160d89d7462b7ed9883c978e848c7075b90b73cb823680e66092d61513050164588387d2ca87dd6d910e28d64bc13a9ac82cd8580c796 - languageName: node - linkType: hard - -"caching-transform@npm:^4.0.0": - version: 4.0.0 - resolution: "caching-transform@npm:4.0.0" - dependencies: - hasha: ^5.0.0 - make-dir: ^3.0.0 - package-hash: ^4.0.0 - write-file-atomic: ^3.0.0 - checksum: c4db6939533b677866808de67c32f0aaf8bf4fd3e3b8dc957e5d630c007c06b7f11512d44c38a38287fb068e931067e8da9019c34d787259a44121c9a6b87a1f - languageName: node - linkType: hard - -"callsites@npm:^3.0.0": - version: 3.1.0 - resolution: "callsites@npm:3.1.0" - checksum: 072d17b6abb459c2ba96598918b55868af677154bec7e73d222ef95a8fdb9bbf7dae96a8421085cdad8cd190d86653b5b6dc55a4484f2e5b2e27d5e0c3fc15b3 - languageName: node - linkType: hard - -"camelcase@npm:^5.0.0, camelcase@npm:^5.3.1": - version: 5.3.1 - resolution: "camelcase@npm:5.3.1" - checksum: e6effce26b9404e3c0f301498184f243811c30dfe6d0b9051863bd8e4034d09c8c2923794f280d6827e5aa055f6c434115ff97864a16a963366fb35fd673024b - languageName: node - linkType: hard - -"camelcase@npm:^6.0.0": - version: 6.3.0 - resolution: "camelcase@npm:6.3.0" - checksum: 8c96818a9076434998511251dcb2761a94817ea17dbdc37f47ac080bd088fc62c7369429a19e2178b993497132c8cbcf5cc1f44ba963e76782ba469c0474938d - languageName: node - linkType: hard - -"caniuse-lite@npm:^1.0.30001503": - version: 1.0.30001514 - resolution: "caniuse-lite@npm:1.0.30001514" - checksum: ee2e90fe63cb59fb4a1515eb6b157f1c26d3ccba496b994b0f03088c39c282ee2fb8c160ad7b677ee196b5bb078b23f2f9474c32e4e47724f4d782de92bb8bbe - languageName: node - linkType: hard - -"chalk@npm:^2.0.0, chalk@npm:^2.4.2": - version: 2.4.2 - resolution: "chalk@npm:2.4.2" - dependencies: - ansi-styles: ^3.2.1 - escape-string-regexp: ^1.0.5 - supports-color: ^5.3.0 - checksum: ec3661d38fe77f681200f878edbd9448821924e0f93a9cefc0e26a33b145f1027a2084bf19967160d11e1f03bfe4eaffcabf5493b89098b2782c3fe0b03d80c2 - languageName: node - linkType: hard - -"chalk@npm:^4.0.0, chalk@npm:^4.1.0": - version: 4.1.2 - resolution: "chalk@npm:4.1.2" - dependencies: - ansi-styles: ^4.1.0 - supports-color: ^7.1.0 - checksum: fe75c9d5c76a7a98d45495b91b2172fa3b7a09e0cc9370e5c8feb1c567b85c4288e2b3fded7cfdd7359ac28d6b3844feb8b82b8686842e93d23c827c417e83fc - languageName: node - linkType: hard - -"chokidar@npm:3.5.3": - version: 3.5.3 - resolution: "chokidar@npm:3.5.3" - dependencies: - anymatch: ~3.1.2 - braces: ~3.0.2 - fsevents: ~2.3.2 - glob-parent: ~5.1.2 - is-binary-path: ~2.1.0 - is-glob: ~4.0.1 - normalize-path: ~3.0.0 - readdirp: ~3.6.0 - dependenciesMeta: - fsevents: - optional: true - checksum: b49fcde40176ba007ff361b198a2d35df60d9bb2a5aab228279eb810feae9294a6b4649ab15981304447afe1e6ffbf4788ad5db77235dc770ab777c6e771980c - languageName: node - linkType: hard - -"chownr@npm:^2.0.0": - version: 2.0.0 - resolution: "chownr@npm:2.0.0" - checksum: c57cf9dd0791e2f18a5ee9c1a299ae6e801ff58fee96dc8bfd0dcb4738a6ce58dd252a3605b1c93c6418fe4f9d5093b28ffbf4d66648cb2a9c67eaef9679be2f - languageName: node - linkType: hard - -"clean-stack@npm:^2.0.0": - version: 2.2.0 - resolution: "clean-stack@npm:2.2.0" - checksum: 2ac8cd2b2f5ec986a3c743935ec85b07bc174d5421a5efc8017e1f146a1cf5f781ae962618f416352103b32c9cd7e203276e8c28241bbe946160cab16149fb68 - languageName: node - linkType: hard - -"cliui@npm:^6.0.0": - version: 6.0.0 - resolution: "cliui@npm:6.0.0" - dependencies: - string-width: ^4.2.0 - strip-ansi: ^6.0.0 - wrap-ansi: ^6.2.0 - checksum: 4fcfd26d292c9f00238117f39fc797608292ae36bac2168cfee4c85923817d0607fe21b3329a8621e01aedf512c99b7eaa60e363a671ffd378df6649fb48ae42 - languageName: node - linkType: hard - -"cliui@npm:^7.0.2": - version: 7.0.4 - resolution: "cliui@npm:7.0.4" - dependencies: - string-width: ^4.2.0 - strip-ansi: ^6.0.0 - wrap-ansi: ^7.0.0 - checksum: ce2e8f578a4813806788ac399b9e866297740eecd4ad1823c27fd344d78b22c5f8597d548adbcc46f0573e43e21e751f39446c5a5e804a12aace402b7a315d7f - languageName: node - linkType: hard - -"color-convert@npm:^1.9.0": - version: 1.9.3 - resolution: "color-convert@npm:1.9.3" - dependencies: - color-name: 1.1.3 - checksum: fd7a64a17cde98fb923b1dd05c5f2e6f7aefda1b60d67e8d449f9328b4e53b228a428fd38bfeaeb2db2ff6b6503a776a996150b80cdf224062af08a5c8a3a203 - languageName: node - linkType: hard - -"color-convert@npm:^2.0.1": - version: 2.0.1 - resolution: "color-convert@npm:2.0.1" - dependencies: - color-name: ~1.1.4 - checksum: 79e6bdb9fd479a205c71d89574fccfb22bd9053bd98c6c4d870d65c132e5e904e6034978e55b43d69fcaa7433af2016ee203ce76eeba9cfa554b373e7f7db336 - languageName: node - linkType: hard - -"color-name@npm:1.1.3": - version: 1.1.3 - resolution: "color-name@npm:1.1.3" - checksum: 09c5d3e33d2105850153b14466501f2bfb30324a2f76568a408763a3b7433b0e50e5b4ab1947868e65cb101bb7cb75029553f2c333b6d4b8138a73fcc133d69d - languageName: node - linkType: hard - -"color-name@npm:~1.1.4": - version: 1.1.4 - resolution: "color-name@npm:1.1.4" - checksum: b0445859521eb4021cd0fb0cc1a75cecf67fceecae89b63f62b201cca8d345baf8b952c966862a9d9a2632987d4f6581f0ec8d957dfacece86f0a7919316f610 - languageName: node - linkType: hard - -"color-support@npm:^1.1.3": - version: 1.1.3 - resolution: "color-support@npm:1.1.3" - bin: - color-support: bin.js - checksum: 9b7356817670b9a13a26ca5af1c21615463b500783b739b7634a0c2047c16cef4b2865d7576875c31c3cddf9dd621fa19285e628f20198b233a5cfdda6d0793b - languageName: node - linkType: hard - -"combined-stream@npm:^1.0.8": - version: 1.0.8 - resolution: "combined-stream@npm:1.0.8" - dependencies: - delayed-stream: ~1.0.0 - checksum: 49fa4aeb4916567e33ea81d088f6584749fc90c7abec76fd516bf1c5aa5c79f3584b5ba3de6b86d26ddd64bae5329c4c7479343250cfe71c75bb366eae53bb7c - languageName: node - linkType: hard - -"commondir@npm:^1.0.1": - version: 1.0.1 - resolution: "commondir@npm:1.0.1" - checksum: 59715f2fc456a73f68826285718503340b9f0dd89bfffc42749906c5cf3d4277ef11ef1cca0350d0e79204f00f1f6d83851ececc9095dc88512a697ac0b9bdcb - languageName: node - linkType: hard - -"concat-map@npm:0.0.1": - version: 0.0.1 - resolution: "concat-map@npm:0.0.1" - checksum: 902a9f5d8967a3e2faf138d5cb784b9979bad2e6db5357c5b21c568df4ebe62bcb15108af1b2253744844eb964fc023fbd9afbbbb6ddd0bcc204c6fb5b7bf3af - languageName: node - linkType: hard - -"console-control-strings@npm:^1.1.0": - version: 1.1.0 - resolution: "console-control-strings@npm:1.1.0" - checksum: 8755d76787f94e6cf79ce4666f0c5519906d7f5b02d4b884cf41e11dcd759ed69c57da0670afd9236d229a46e0f9cf519db0cd829c6dca820bb5a5c3def584ed - languageName: node - linkType: hard - -"convert-source-map@npm:^1.7.0": - version: 1.9.0 - resolution: "convert-source-map@npm:1.9.0" - checksum: dc55a1f28ddd0e9485ef13565f8f756b342f9a46c4ae18b843fe3c30c675d058d6a4823eff86d472f187b176f0adf51ea7b69ea38be34be4a63cbbf91b0593c8 - languageName: node - linkType: hard - -"create-require@npm:^1.1.0": - version: 1.1.1 - resolution: "create-require@npm:1.1.1" - checksum: a9a1503d4390d8b59ad86f4607de7870b39cad43d929813599a23714831e81c520bddf61bcdd1f8e30f05fd3a2b71ae8538e946eb2786dc65c2bbc520f692eff - languageName: node - linkType: hard - -"cross-spawn@npm:^7.0.0, cross-spawn@npm:^7.0.2, cross-spawn@npm:^7.0.3": - version: 7.0.3 - resolution: "cross-spawn@npm:7.0.3" - dependencies: - path-key: ^3.1.0 - shebang-command: ^2.0.0 - which: ^2.0.1 - checksum: 671cc7c7288c3a8406f3c69a3ae2fc85555c04169e9d611def9a675635472614f1c0ed0ef80955d5b6d4e724f6ced67f0ad1bb006c2ea643488fcfef994d7f52 - languageName: node - linkType: hard - -"debug@npm:4, debug@npm:^4.1.0, debug@npm:^4.1.1, debug@npm:^4.3.2, debug@npm:^4.3.3, debug@npm:^4.3.4": - version: 4.3.4 - resolution: "debug@npm:4.3.4" - dependencies: - ms: 2.1.2 - peerDependenciesMeta: - supports-color: - optional: true - checksum: 3dbad3f94ea64f34431a9cbf0bafb61853eda57bff2880036153438f50fb5a84f27683ba0d8e5426bf41a8c6ff03879488120cf5b3a761e77953169c0600a708 - languageName: node - linkType: hard - -"debug@npm:4.3.3": - version: 4.3.3 - resolution: "debug@npm:4.3.3" - dependencies: - ms: 2.1.2 - peerDependenciesMeta: - supports-color: - optional: true - checksum: 14472d56fe4a94dbcfaa6dbed2dd3849f1d72ba78104a1a328047bb564643ca49df0224c3a17fa63533fd11dd3d4c8636cd861191232a2c6735af00cc2d4de16 - languageName: node - linkType: hard - -"decamelize@npm:^1.2.0": - version: 1.2.0 - resolution: "decamelize@npm:1.2.0" - checksum: ad8c51a7e7e0720c70ec2eeb1163b66da03e7616d7b98c9ef43cce2416395e84c1e9548dd94f5f6ffecfee9f8b94251fc57121a8b021f2ff2469b2bae247b8aa - languageName: node - linkType: hard - -"decamelize@npm:^4.0.0": - version: 4.0.0 - resolution: "decamelize@npm:4.0.0" - checksum: b7d09b82652c39eead4d6678bb578e3bebd848add894b76d0f6b395bc45b2d692fb88d977e7cfb93c4ed6c119b05a1347cef261174916c2e75c0a8ca57da1809 - languageName: node - linkType: hard - -"deep-is@npm:^0.1.3": - version: 0.1.4 - resolution: "deep-is@npm:0.1.4" - checksum: edb65dd0d7d1b9c40b2f50219aef30e116cedd6fc79290e740972c132c09106d2e80aa0bc8826673dd5a00222d4179c84b36a790eef63a4c4bca75a37ef90804 - languageName: node - linkType: hard - -"default-require-extensions@npm:^3.0.0": - version: 3.0.1 - resolution: "default-require-extensions@npm:3.0.1" - dependencies: - strip-bom: ^4.0.0 - checksum: 45882fc971dd157faf6716ced04c15cf252c0a2d6f5c5844b66ca49f46ed03396a26cd940771aa569927aee22923a961bab789e74b25aabc94d90742c9dd1217 - languageName: node - linkType: hard - -"delayed-stream@npm:~1.0.0": - version: 1.0.0 - resolution: "delayed-stream@npm:1.0.0" - checksum: 46fe6e83e2cb1d85ba50bd52803c68be9bd953282fa7096f51fc29edd5d67ff84ff753c51966061e5ba7cb5e47ef6d36a91924eddb7f3f3483b1c560f77a0020 - languageName: node - linkType: hard - -"delegates@npm:^1.0.0": - version: 1.0.0 - resolution: "delegates@npm:1.0.0" - checksum: a51744d9b53c164ba9c0492471a1a2ffa0b6727451bdc89e31627fdf4adda9d51277cfcbfb20f0a6f08ccb3c436f341df3e92631a3440226d93a8971724771fd - languageName: node - linkType: hard - -"depd@npm:^2.0.0": - version: 2.0.0 - resolution: "depd@npm:2.0.0" - checksum: abbe19c768c97ee2eed6282d8ce3031126662252c58d711f646921c9623f9052e3e1906443066beec1095832f534e57c523b7333f8e7e0d93051ab6baef5ab3a - languageName: node - linkType: hard - -"diff@npm:5.0.0": - version: 5.0.0 - resolution: "diff@npm:5.0.0" - checksum: f19fe29284b633afdb2725c2a8bb7d25761ea54d321d8e67987ac851c5294be4afeab532bd84531e02583a3fe7f4014aa314a3eda84f5590e7a9e6b371ef3b46 - languageName: node - linkType: hard - -"diff@npm:^3.5.0": - version: 3.5.0 - resolution: "diff@npm:3.5.0" - checksum: 00842950a6551e26ce495bdbce11047e31667deea546527902661f25cc2e73358967ebc78cf86b1a9736ec3e14286433225f9970678155753a6291c3bca5227b - languageName: node - linkType: hard - -"diff@npm:^4.0.1": - version: 4.0.2 - resolution: "diff@npm:4.0.2" - checksum: f2c09b0ce4e6b301c221addd83bf3f454c0bc00caa3dd837cf6c127d6edf7223aa2bbe3b688feea110b7f262adbfc845b757c44c8a9f8c0c5b15d8fa9ce9d20d - languageName: node - linkType: hard - -"dir-glob@npm:^3.0.1": - version: 3.0.1 - resolution: "dir-glob@npm:3.0.1" - dependencies: - path-type: ^4.0.0 - checksum: fa05e18324510d7283f55862f3161c6759a3f2f8dbce491a2fc14c8324c498286c54282c1f0e933cb930da8419b30679389499b919122952a4f8592362ef4615 - languageName: node - linkType: hard - -"doctrine@npm:^3.0.0": - version: 3.0.0 - resolution: "doctrine@npm:3.0.0" - dependencies: - esutils: ^2.0.2 - checksum: fd7673ca77fe26cd5cba38d816bc72d641f500f1f9b25b83e8ce28827fe2da7ad583a8da26ab6af85f834138cf8dae9f69b0cd6ab925f52ddab1754db44d99ce - languageName: node - linkType: hard - -"eastasianwidth@npm:^0.2.0": - version: 0.2.0 - resolution: "eastasianwidth@npm:0.2.0" - checksum: 7d00d7cd8e49b9afa762a813faac332dee781932d6f2c848dc348939c4253f1d4564341b7af1d041853bc3f32c2ef141b58e0a4d9862c17a7f08f68df1e0f1ed - languageName: node - linkType: hard - -"electron-to-chromium@npm:^1.4.431": - version: 1.4.454 - resolution: "electron-to-chromium@npm:1.4.454" - checksum: 26a756485b442be04a640b8733c3e0d1ad9630541e56906332b1a5f25ec0027647561ec98d0d2a5069a1aae3875c9751c6d1c6cb9ef400b2beabedc36da14ba1 - languageName: node - linkType: hard - -"emoji-regex@npm:^8.0.0": - version: 8.0.0 - resolution: "emoji-regex@npm:8.0.0" - checksum: d4c5c39d5a9868b5fa152f00cada8a936868fd3367f33f71be515ecee4c803132d11b31a6222b2571b1e5f7e13890156a94880345594d0ce7e3c9895f560f192 - languageName: node - linkType: hard - -"emoji-regex@npm:^9.2.2": - version: 9.2.2 - resolution: "emoji-regex@npm:9.2.2" - checksum: 8487182da74aabd810ac6d6f1994111dfc0e331b01271ae01ec1eb0ad7b5ecc2bbbbd2f053c05cb55a1ac30449527d819bbfbf0e3de1023db308cbcb47f86601 - languageName: node - linkType: hard - -"encoding@npm:^0.1.13": - version: 0.1.13 - resolution: "encoding@npm:0.1.13" - dependencies: - iconv-lite: ^0.6.2 - checksum: bb98632f8ffa823996e508ce6a58ffcf5856330fde839ae42c9e1f436cc3b5cc651d4aeae72222916545428e54fd0f6aa8862fd8d25bdbcc4589f1e3f3715e7f - languageName: node - linkType: hard - -"env-paths@npm:^2.2.0": - version: 2.2.1 - resolution: "env-paths@npm:2.2.1" - checksum: 65b5df55a8bab92229ab2b40dad3b387fad24613263d103a97f91c9fe43ceb21965cd3392b1ccb5d77088021e525c4e0481adb309625d0cb94ade1d1fb8dc17e - languageName: node - linkType: hard - -"err-code@npm:^2.0.2": - version: 2.0.3 - resolution: "err-code@npm:2.0.3" - checksum: 8b7b1be20d2de12d2255c0bc2ca638b7af5171142693299416e6a9339bd7d88fc8d7707d913d78e0993176005405a236b066b45666b27b797252c771156ace54 - languageName: node - linkType: hard - -"es6-error@npm:^4.0.1": - version: 4.1.1 - resolution: "es6-error@npm:4.1.1" - checksum: ae41332a51ec1323da6bbc5d75b7803ccdeddfae17c41b6166ebbafc8e8beb7a7b80b884b7fab1cc80df485860ac3c59d78605e860bb4f8cd816b3d6ade0d010 - languageName: node - linkType: hard - -"escalade@npm:^3.1.1": - version: 3.1.1 - resolution: "escalade@npm:3.1.1" - checksum: a3e2a99f07acb74b3ad4989c48ca0c3140f69f923e56d0cba0526240ee470b91010f9d39001f2a4a313841d237ede70a729e92125191ba5d21e74b106800b133 - languageName: node - linkType: hard - -"escape-string-regexp@npm:4.0.0, escape-string-regexp@npm:^4.0.0": - version: 4.0.0 - resolution: "escape-string-regexp@npm:4.0.0" - checksum: 98b48897d93060f2322108bf29db0feba7dd774be96cd069458d1453347b25ce8682ecc39859d4bca2203cc0ab19c237bcc71755eff49a0f8d90beadeeba5cc5 - languageName: node - linkType: hard - -"escape-string-regexp@npm:^1.0.5": - version: 1.0.5 - resolution: "escape-string-regexp@npm:1.0.5" - checksum: 6092fda75c63b110c706b6a9bfde8a612ad595b628f0bd2147eea1d3406723020810e591effc7db1da91d80a71a737a313567c5abb3813e8d9c71f4aa595b410 - languageName: node - linkType: hard - -"eslint-config-prettier@npm:^8.8.0": - version: 8.8.0 - resolution: "eslint-config-prettier@npm:8.8.0" - peerDependencies: - eslint: ">=7.0.0" - bin: - eslint-config-prettier: bin/cli.js - checksum: 1e94c3882c4d5e41e1dcfa2c368dbccbfe3134f6ac7d40101644d3bfbe3eb2f2ffac757f3145910b5eacf20c0e85e02b91293d3126d770cbf3dc390b3564681c - languageName: node - linkType: hard - -"eslint-plugin-no-only-tests@npm:^2.6.0": - version: 2.6.0 - resolution: "eslint-plugin-no-only-tests@npm:2.6.0" - checksum: 4e3c9cc7e09c13e855fd7af4a8969128f766dcf32a0680715ebcaa903c7fe44db8e45e994c8b908443a6019cbd9ea1b51f413bf968a0c58214aded930a863df9 - languageName: node - linkType: hard - -"eslint-scope@npm:^5.1.1": - version: 5.1.1 - resolution: "eslint-scope@npm:5.1.1" - dependencies: - esrecurse: ^4.3.0 - estraverse: ^4.1.1 - checksum: 47e4b6a3f0cc29c7feedee6c67b225a2da7e155802c6ea13bbef4ac6b9e10c66cd2dcb987867ef176292bf4e64eccc680a49e35e9e9c669f4a02bac17e86abdb - languageName: node - linkType: hard - -"eslint-scope@npm:^7.2.0": - version: 7.2.0 - resolution: "eslint-scope@npm:7.2.0" - dependencies: - esrecurse: ^4.3.0 - estraverse: ^5.2.0 - checksum: 64591a2d8b244ade9c690b59ef238a11d5c721a98bcee9e9f445454f442d03d3e04eda88e95a4daec558220a99fa384309d9faae3d459bd40e7a81b4063980ae - languageName: node - linkType: hard - -"eslint-visitor-keys@npm:^3.3.0, eslint-visitor-keys@npm:^3.4.1": - version: 3.4.1 - resolution: "eslint-visitor-keys@npm:3.4.1" - checksum: f05121d868202736b97de7d750847a328fcfa8593b031c95ea89425333db59676ac087fa905eba438d0a3c5769632f828187e0c1a0d271832a2153c1d3661c2c - languageName: node - linkType: hard - -"eslint@npm:^8.44.0": - version: 8.44.0 - resolution: "eslint@npm:8.44.0" - dependencies: - "@eslint-community/eslint-utils": ^4.2.0 - "@eslint-community/regexpp": ^4.4.0 - "@eslint/eslintrc": ^2.1.0 - "@eslint/js": 8.44.0 - "@humanwhocodes/config-array": ^0.11.10 - "@humanwhocodes/module-importer": ^1.0.1 - "@nodelib/fs.walk": ^1.2.8 - ajv: ^6.10.0 - chalk: ^4.0.0 - cross-spawn: ^7.0.2 - debug: ^4.3.2 - doctrine: ^3.0.0 - escape-string-regexp: ^4.0.0 - eslint-scope: ^7.2.0 - eslint-visitor-keys: ^3.4.1 - espree: ^9.6.0 - esquery: ^1.4.2 - esutils: ^2.0.2 - fast-deep-equal: ^3.1.3 - file-entry-cache: ^6.0.1 - find-up: ^5.0.0 - glob-parent: ^6.0.2 - globals: ^13.19.0 - graphemer: ^1.4.0 - ignore: ^5.2.0 - import-fresh: ^3.0.0 - imurmurhash: ^0.1.4 - is-glob: ^4.0.0 - is-path-inside: ^3.0.3 - js-yaml: ^4.1.0 - json-stable-stringify-without-jsonify: ^1.0.1 - levn: ^0.4.1 - lodash.merge: ^4.6.2 - minimatch: ^3.1.2 - natural-compare: ^1.4.0 - optionator: ^0.9.3 - strip-ansi: ^6.0.1 - strip-json-comments: ^3.1.0 - text-table: ^0.2.0 - bin: - eslint: bin/eslint.js - checksum: d06309ce4aafb9d27d558c8e5e5aa5cba3bbec3ce8ceccbc7d4b7a35f2b67fd40189159155553270e2e6febeb69bd8a3b60d6241c8f5ddc2ef1702ccbd328501 - languageName: node - linkType: hard - -"espree@npm:^9.6.0": - version: 9.6.0 - resolution: "espree@npm:9.6.0" - dependencies: - acorn: ^8.9.0 - acorn-jsx: ^5.3.2 - eslint-visitor-keys: ^3.4.1 - checksum: 1287979510efb052a6a97c73067ea5d0a40701b29adde87bbe2d3eb1667e39ca55e8129e20e2517fed3da570150e7ef470585228459a8f3e3755f45007a1c662 - languageName: node - linkType: hard - -"esprima@npm:^4.0.0": - version: 4.0.1 - resolution: "esprima@npm:4.0.1" - bin: - esparse: ./bin/esparse.js - esvalidate: ./bin/esvalidate.js - checksum: b45bc805a613dbea2835278c306b91aff6173c8d034223fa81498c77dcbce3b2931bf6006db816f62eacd9fd4ea975dfd85a5b7f3c6402cfd050d4ca3c13a628 - languageName: node - linkType: hard - -"esquery@npm:^1.4.2": - version: 1.5.0 - resolution: "esquery@npm:1.5.0" - dependencies: - estraverse: ^5.1.0 - checksum: aefb0d2596c230118656cd4ec7532d447333a410a48834d80ea648b1e7b5c9bc9ed8b5e33a89cb04e487b60d622f44cf5713bf4abed7c97343edefdc84a35900 - languageName: node - linkType: hard - -"esrecurse@npm:^4.3.0": - version: 4.3.0 - resolution: "esrecurse@npm:4.3.0" - dependencies: - estraverse: ^5.2.0 - checksum: ebc17b1a33c51cef46fdc28b958994b1dc43cd2e86237515cbc3b4e5d2be6a811b2315d0a1a4d9d340b6d2308b15322f5c8291059521cc5f4802f65e7ec32837 - languageName: node - linkType: hard - -"estraverse@npm:^4.1.1": - version: 4.3.0 - resolution: "estraverse@npm:4.3.0" - checksum: a6299491f9940bb246124a8d44b7b7a413a8336f5436f9837aaa9330209bd9ee8af7e91a654a3545aee9c54b3308e78ee360cef1d777d37cfef77d2fa33b5827 - languageName: node - linkType: hard - -"estraverse@npm:^5.1.0, estraverse@npm:^5.2.0": - version: 5.3.0 - resolution: "estraverse@npm:5.3.0" - checksum: 072780882dc8416ad144f8fe199628d2b3e7bbc9989d9ed43795d2c90309a2047e6bc5979d7e2322a341163d22cfad9e21f4110597fe487519697389497e4e2b - languageName: node - linkType: hard - -"esutils@npm:^2.0.2": - version: 2.0.3 - resolution: "esutils@npm:2.0.3" - checksum: 22b5b08f74737379a840b8ed2036a5fb35826c709ab000683b092d9054e5c2a82c27818f12604bfc2a9a76b90b6834ef081edbc1c7ae30d1627012e067c6ec87 - languageName: node - linkType: hard - -"exponential-backoff@npm:^3.1.1": - version: 3.1.1 - resolution: "exponential-backoff@npm:3.1.1" - checksum: 3d21519a4f8207c99f7457287291316306255a328770d320b401114ec8481986e4e467e854cb9914dd965e0a1ca810a23ccb559c642c88f4c7f55c55778a9b48 - languageName: node - linkType: hard - -"fast-deep-equal@npm:^3.1.1, fast-deep-equal@npm:^3.1.3": - version: 3.1.3 - resolution: "fast-deep-equal@npm:3.1.3" - checksum: e21a9d8d84f53493b6aa15efc9cfd53dd5b714a1f23f67fb5dc8f574af80df889b3bce25dc081887c6d25457cce704e636395333abad896ccdec03abaf1f3f9d - languageName: node - linkType: hard - -"fast-glob@npm:^3.2.9": - version: 3.3.0 - resolution: "fast-glob@npm:3.3.0" - dependencies: - "@nodelib/fs.stat": ^2.0.2 - "@nodelib/fs.walk": ^1.2.3 - glob-parent: ^5.1.2 - merge2: ^1.3.0 - micromatch: ^4.0.4 - checksum: 20df62be28eb5426fe8e40e0d05601a63b1daceb7c3d87534afcad91bdcf1e4b1743cf2d5247d6e225b120b46df0b9053a032b2691ba34ee121e033acd81f547 - languageName: node - linkType: hard - -"fast-json-stable-stringify@npm:^2.0.0": - version: 2.1.0 - resolution: "fast-json-stable-stringify@npm:2.1.0" - checksum: b191531e36c607977e5b1c47811158733c34ccb3bfde92c44798929e9b4154884378536d26ad90dfecd32e1ffc09c545d23535ad91b3161a27ddbb8ebe0cbecb - languageName: node - linkType: hard - -"fast-levenshtein@npm:^2.0.6": - version: 2.0.6 - resolution: "fast-levenshtein@npm:2.0.6" - checksum: 92cfec0a8dfafd9c7a15fba8f2cc29cd0b62b85f056d99ce448bbcd9f708e18ab2764bda4dd5158364f4145a7c72788538994f0d1787b956ef0d1062b0f7c24c - languageName: node - linkType: hard - -"fastq@npm:^1.6.0": - version: 1.15.0 - resolution: "fastq@npm:1.15.0" - dependencies: - reusify: ^1.0.4 - checksum: 0170e6bfcd5d57a70412440b8ef600da6de3b2a6c5966aeaf0a852d542daff506a0ee92d6de7679d1de82e644bce69d7a574a6c93f0b03964b5337eed75ada1a - languageName: node - linkType: hard - -"file-entry-cache@npm:^6.0.1": - version: 6.0.1 - resolution: "file-entry-cache@npm:6.0.1" - dependencies: - flat-cache: ^3.0.4 - checksum: f49701feaa6314c8127c3c2f6173cfefff17612f5ed2daaafc6da13b5c91fd43e3b2a58fd0d63f9f94478a501b167615931e7200e31485e320f74a33885a9c74 - languageName: node - linkType: hard - -"fill-range@npm:^7.0.1": - version: 7.0.1 - resolution: "fill-range@npm:7.0.1" - dependencies: - to-regex-range: ^5.0.1 - checksum: cc283f4e65b504259e64fd969bcf4def4eb08d85565e906b7d36516e87819db52029a76b6363d0f02d0d532f0033c9603b9e2d943d56ee3b0d4f7ad3328ff917 - languageName: node - linkType: hard - -"find-cache-dir@npm:^3.2.0": - version: 3.3.2 - resolution: "find-cache-dir@npm:3.3.2" - dependencies: - commondir: ^1.0.1 - make-dir: ^3.0.2 - pkg-dir: ^4.1.0 - checksum: 1e61c2e64f5c0b1c535bd85939ae73b0e5773142713273818cc0b393ee3555fb0fd44e1a5b161b8b6c3e03e98c2fcc9c227d784850a13a90a8ab576869576817 - languageName: node - linkType: hard - -"find-up@npm:5.0.0, find-up@npm:^5.0.0": - version: 5.0.0 - resolution: "find-up@npm:5.0.0" - dependencies: - locate-path: ^6.0.0 - path-exists: ^4.0.0 - checksum: 07955e357348f34660bde7920783204ff5a26ac2cafcaa28bace494027158a97b9f56faaf2d89a6106211a8174db650dd9f503f9c0d526b1202d5554a00b9095 - languageName: node - linkType: hard - -"find-up@npm:^4.0.0, find-up@npm:^4.1.0": - version: 4.1.0 - resolution: "find-up@npm:4.1.0" - dependencies: - locate-path: ^5.0.0 - path-exists: ^4.0.0 - checksum: 4c172680e8f8c1f78839486e14a43ef82e9decd0e74145f40707cc42e7420506d5ec92d9a11c22bd2c48fb0c384ea05dd30e10dd152fefeec6f2f75282a8b844 - languageName: node - linkType: hard - -"flat-cache@npm:^3.0.4": - version: 3.0.4 - resolution: "flat-cache@npm:3.0.4" - dependencies: - flatted: ^3.1.0 - rimraf: ^3.0.2 - checksum: 4fdd10ecbcbf7d520f9040dd1340eb5dfe951e6f0ecf2252edeec03ee68d989ec8b9a20f4434270e71bcfd57800dc09b3344fca3966b2eb8f613072c7d9a2365 - languageName: node - linkType: hard - -"flat@npm:^5.0.2": - version: 5.0.2 - resolution: "flat@npm:5.0.2" - bin: - flat: cli.js - checksum: 12a1536ac746db74881316a181499a78ef953632ddd28050b7a3a43c62ef5462e3357c8c29d76072bb635f147f7a9a1f0c02efef6b4be28f8db62ceb3d5c7f5d - languageName: node - linkType: hard - -"flatted@npm:^3.1.0": - version: 3.2.7 - resolution: "flatted@npm:3.2.7" - checksum: 427633049d55bdb80201c68f7eb1cbd533e03eac541f97d3aecab8c5526f12a20ccecaeede08b57503e772c769e7f8680b37e8d482d1e5f8d7e2194687f9ea35 - languageName: node - linkType: hard - -"follow-redirects@npm:^1.15.0": - version: 1.15.3 - resolution: "follow-redirects@npm:1.15.3" - peerDependenciesMeta: - debug: - optional: true - checksum: 584da22ec5420c837bd096559ebfb8fe69d82512d5585004e36a3b4a6ef6d5905780e0c74508c7b72f907d1fa2b7bd339e613859e9c304d0dc96af2027fd0231 - languageName: node - linkType: hard - -"foreground-child@npm:^2.0.0": - version: 2.0.0 - resolution: "foreground-child@npm:2.0.0" - dependencies: - cross-spawn: ^7.0.0 - signal-exit: ^3.0.2 - checksum: f77ec9aff621abd6b754cb59e690743e7639328301fbea6ff09df27d2befaf7dd5b77cec51c32323d73a81a7d91caaf9413990d305cbe3d873eec4fe58960956 - languageName: node - linkType: hard - -"foreground-child@npm:^3.1.0": - version: 3.1.1 - resolution: "foreground-child@npm:3.1.1" - dependencies: - cross-spawn: ^7.0.0 - signal-exit: ^4.0.1 - checksum: 139d270bc82dc9e6f8bc045fe2aae4001dc2472157044fdfad376d0a3457f77857fa883c1c8b21b491c6caade9a926a4bed3d3d2e8d3c9202b151a4cbbd0bcd5 - languageName: node - linkType: hard - -"form-data@npm:^4.0.0": - version: 4.0.0 - resolution: "form-data@npm:4.0.0" - dependencies: - asynckit: ^0.4.0 - combined-stream: ^1.0.8 - mime-types: ^2.1.12 - checksum: 01135bf8675f9d5c61ff18e2e2932f719ca4de964e3be90ef4c36aacfc7b9cb2fceb5eca0b7e0190e3383fe51c5b37f4cb80b62ca06a99aaabfcfd6ac7c9328c - languageName: node - linkType: hard - -"fromentries@npm:^1.2.0": - version: 1.3.2 - resolution: "fromentries@npm:1.3.2" - checksum: 33729c529ce19f5494f846f0dd4945078f4e37f4e8955f4ae8cc7385c218f600e9d93a7d225d17636c20d1889106fd87061f911550861b7072f53bf891e6b341 - languageName: node - linkType: hard - -"fs-minipass@npm:^2.0.0": - version: 2.1.0 - resolution: "fs-minipass@npm:2.1.0" - dependencies: - minipass: ^3.0.0 - checksum: 1b8d128dae2ac6cc94230cc5ead341ba3e0efaef82dab46a33d171c044caaa6ca001364178d42069b2809c35a1c3c35079a32107c770e9ffab3901b59af8c8b1 - languageName: node - linkType: hard - -"fs-minipass@npm:^3.0.0": - version: 3.0.2 - resolution: "fs-minipass@npm:3.0.2" - dependencies: - minipass: ^5.0.0 - checksum: e9cc0e1f2d01c6f6f62f567aee59530aba65c6c7b2ae88c5027bc34c711ebcfcfaefd0caf254afa6adfe7d1fba16bc2537508a6235196bac7276747d078aef0a - languageName: node - linkType: hard - -"fs.realpath@npm:^1.0.0": - version: 1.0.0 - resolution: "fs.realpath@npm:1.0.0" - checksum: 99ddea01a7e75aa276c250a04eedeffe5662bce66c65c07164ad6264f9de18fb21be9433ead460e54cff20e31721c811f4fb5d70591799df5f85dce6d6746fd0 - languageName: node - linkType: hard - -"fsevents@npm:~2.3.2": - version: 2.3.2 - resolution: "fsevents@npm:2.3.2" - dependencies: - node-gyp: latest - checksum: 97ade64e75091afee5265e6956cb72ba34db7819b4c3e94c431d4be2b19b8bb7a2d4116da417950c3425f17c8fe693d25e20212cac583ac1521ad066b77ae31f - conditions: os=darwin - languageName: node - linkType: hard - -"fsevents@patch:fsevents@~2.3.2#~builtin": - version: 2.3.2 - resolution: "fsevents@patch:fsevents@npm%3A2.3.2#~builtin::version=2.3.2&hash=18f3a7" - dependencies: - node-gyp: latest - conditions: os=darwin - languageName: node - linkType: hard - -"gauge@npm:^4.0.3": - version: 4.0.4 - resolution: "gauge@npm:4.0.4" - dependencies: - aproba: ^1.0.3 || ^2.0.0 - color-support: ^1.1.3 - console-control-strings: ^1.1.0 - has-unicode: ^2.0.1 - signal-exit: ^3.0.7 - string-width: ^4.2.3 - strip-ansi: ^6.0.1 - wide-align: ^1.1.5 - checksum: 788b6bfe52f1dd8e263cda800c26ac0ca2ff6de0b6eee2fe0d9e3abf15e149b651bd27bf5226be10e6e3edb5c4e5d5985a5a1a98137e7a892f75eff76467ad2d - languageName: node - linkType: hard - -"gensync@npm:^1.0.0-beta.2": - version: 1.0.0-beta.2 - resolution: "gensync@npm:1.0.0-beta.2" - checksum: a7437e58c6be12aa6c90f7730eac7fa9833dc78872b4ad2963d2031b00a3367a93f98aec75f9aaac7220848e4026d67a8655e870b24f20a543d103c0d65952ec - languageName: node - linkType: hard - -"get-caller-file@npm:^2.0.1, get-caller-file@npm:^2.0.5": - version: 2.0.5 - resolution: "get-caller-file@npm:2.0.5" - checksum: b9769a836d2a98c3ee734a88ba712e62703f1df31b94b784762c433c27a386dd6029ff55c2a920c392e33657d80191edbf18c61487e198844844516f843496b9 - languageName: node - linkType: hard - -"get-package-type@npm:^0.1.0": - version: 0.1.0 - resolution: "get-package-type@npm:0.1.0" - checksum: bba0811116d11e56d702682ddef7c73ba3481f114590e705fc549f4d868972263896af313c57a25c076e3c0d567e11d919a64ba1b30c879be985fc9d44f96148 - languageName: node - linkType: hard - -"glob-parent@npm:^5.1.2, glob-parent@npm:~5.1.2": - version: 5.1.2 - resolution: "glob-parent@npm:5.1.2" - dependencies: - is-glob: ^4.0.1 - checksum: f4f2bfe2425296e8a47e36864e4f42be38a996db40420fe434565e4480e3322f18eb37589617a98640c5dc8fdec1a387007ee18dbb1f3f5553409c34d17f425e - languageName: node - linkType: hard - -"glob-parent@npm:^6.0.2": - version: 6.0.2 - resolution: "glob-parent@npm:6.0.2" - dependencies: - is-glob: ^4.0.3 - checksum: c13ee97978bef4f55106b71e66428eb1512e71a7466ba49025fc2aec59a5bfb0954d5abd58fc5ee6c9b076eef4e1f6d3375c2e964b88466ca390da4419a786a8 - languageName: node - linkType: hard - -"glob@npm:7.2.0": - version: 7.2.0 - resolution: "glob@npm:7.2.0" - dependencies: - fs.realpath: ^1.0.0 - inflight: ^1.0.4 - inherits: 2 - minimatch: ^3.0.4 - once: ^1.3.0 - path-is-absolute: ^1.0.0 - checksum: 78a8ea942331f08ed2e055cb5b9e40fe6f46f579d7fd3d694f3412fe5db23223d29b7fee1575440202e9a7ff9a72ab106a39fee39934c7bedafe5e5f8ae20134 - languageName: node - linkType: hard - -"glob@npm:^10.2.2": - version: 10.3.3 - resolution: "glob@npm:10.3.3" - dependencies: - foreground-child: ^3.1.0 - jackspeak: ^2.0.3 - minimatch: ^9.0.1 - minipass: ^5.0.0 || ^6.0.2 || ^7.0.0 - path-scurry: ^1.10.1 - bin: - glob: dist/cjs/src/bin.js - checksum: 29190d3291f422da0cb40b77a72fc8d2c51a36524e99b8bf412548b7676a6627489528b57250429612b6eec2e6fe7826d328451d3e694a9d15e575389308ec53 - languageName: node - linkType: hard - -"glob@npm:^7.1.3, glob@npm:^7.1.4, glob@npm:^7.1.6": - version: 7.2.3 - resolution: "glob@npm:7.2.3" - dependencies: - fs.realpath: ^1.0.0 - inflight: ^1.0.4 - inherits: 2 - minimatch: ^3.1.1 - once: ^1.3.0 - path-is-absolute: ^1.0.0 - checksum: 29452e97b38fa704dabb1d1045350fb2467cf0277e155aa9ff7077e90ad81d1ea9d53d3ee63bd37c05b09a065e90f16aec4a65f5b8de401d1dac40bc5605d133 - languageName: node - linkType: hard - -"globals@npm:^11.1.0": - version: 11.12.0 - resolution: "globals@npm:11.12.0" - checksum: 67051a45eca3db904aee189dfc7cd53c20c7d881679c93f6146ddd4c9f4ab2268e68a919df740d39c71f4445d2b38ee360fc234428baea1dbdfe68bbcb46979e - languageName: node - linkType: hard - -"globals@npm:^13.19.0": - version: 13.20.0 - resolution: "globals@npm:13.20.0" - dependencies: - type-fest: ^0.20.2 - checksum: ad1ecf914bd051325faad281d02ea2c0b1df5d01bd94d368dcc5513340eac41d14b3c61af325768e3c7f8d44576e72780ec0b6f2d366121f8eec6e03c3a3b97a - languageName: node - linkType: hard - -"globby@npm:^11.1.0": - version: 11.1.0 - resolution: "globby@npm:11.1.0" - dependencies: - array-union: ^2.1.0 - dir-glob: ^3.0.1 - fast-glob: ^3.2.9 - ignore: ^5.2.0 - merge2: ^1.4.1 - slash: ^3.0.0 - checksum: b4be8885e0cfa018fc783792942d53926c35c50b3aefd3fdcfb9d22c627639dc26bd2327a40a0b74b074100ce95bb7187bfeae2f236856aa3de183af7a02aea6 - languageName: node - linkType: hard - -"graceful-fs@npm:^4.1.15, graceful-fs@npm:^4.2.6": - version: 4.2.11 - resolution: "graceful-fs@npm:4.2.11" - checksum: ac85f94da92d8eb6b7f5a8b20ce65e43d66761c55ce85ac96df6865308390da45a8d3f0296dd3a663de65d30ba497bd46c696cc1e248c72b13d6d567138a4fc7 - languageName: node - linkType: hard - -"graphemer@npm:^1.4.0": - version: 1.4.0 - resolution: "graphemer@npm:1.4.0" - checksum: bab8f0be9b568857c7bec9fda95a89f87b783546d02951c40c33f84d05bb7da3fd10f863a9beb901463669b6583173a8c8cc6d6b306ea2b9b9d5d3d943c3a673 - languageName: node - linkType: hard - -"growl@npm:1.10.5": - version: 1.10.5 - resolution: "growl@npm:1.10.5" - checksum: 4b86685de6831cebcbb19f93870bea624afee61124b0a20c49017013987cd129e73a8c4baeca295728f41d21265e1f859d25ef36731b142ca59c655fea94bb1a - languageName: node - linkType: hard - -"has-flag@npm:^3.0.0": - version: 3.0.0 - resolution: "has-flag@npm:3.0.0" - checksum: 4a15638b454bf086c8148979aae044dd6e39d63904cd452d970374fa6a87623423da485dfb814e7be882e05c096a7ccf1ebd48e7e7501d0208d8384ff4dea73b - languageName: node - linkType: hard - -"has-flag@npm:^4.0.0": - version: 4.0.0 - resolution: "has-flag@npm:4.0.0" - checksum: 261a1357037ead75e338156b1f9452c016a37dcd3283a972a30d9e4a87441ba372c8b81f818cd0fbcd9c0354b4ae7e18b9e1afa1971164aef6d18c2b6095a8ad - languageName: node - linkType: hard - -"has-unicode@npm:^2.0.1": - version: 2.0.1 - resolution: "has-unicode@npm:2.0.1" - checksum: 1eab07a7436512db0be40a710b29b5dc21fa04880b7f63c9980b706683127e3c1b57cb80ea96d47991bdae2dfe479604f6a1ba410106ee1046a41d1bd0814400 - languageName: node - linkType: hard - -"hasha@npm:^5.0.0": - version: 5.2.2 - resolution: "hasha@npm:5.2.2" - dependencies: - is-stream: ^2.0.0 - type-fest: ^0.8.0 - checksum: 06cc474bed246761ff61c19d629977eb5f53fa817be4313a255a64ae0f433e831a29e83acb6555e3f4592b348497596f1d1653751008dda4f21c9c21ca60ac5a - languageName: node - linkType: hard - -"he@npm:1.2.0": - version: 1.2.0 - resolution: "he@npm:1.2.0" - bin: - he: bin/he - checksum: 3d4d6babccccd79c5c5a3f929a68af33360d6445587d628087f39a965079d84f18ce9c3d3f917ee1e3978916fc833bb8b29377c3b403f919426f91bc6965e7a7 - languageName: node - linkType: hard - -"html-escaper@npm:^2.0.0": - version: 2.0.2 - resolution: "html-escaper@npm:2.0.2" - checksum: d2df2da3ad40ca9ee3a39c5cc6475ef67c8f83c234475f24d8e9ce0dc80a2c82df8e1d6fa78ddd1e9022a586ea1bd247a615e80a5cd9273d90111ddda7d9e974 - languageName: node - linkType: hard - -"htmlencode@npm:^0.0.4": - version: 0.0.4 - resolution: "htmlencode@npm:0.0.4" - checksum: b5c5a280213569f59807d22ae2d68c77360f6337b6936cdfa4e2aeaa12e3a69bb36b426ad18ed9333a7fb3f7d55c14ea3b46040d3271af7a586f262aaf4092ad - languageName: node - linkType: hard - -"http-cache-semantics@npm:^4.1.1": - version: 4.1.1 - resolution: "http-cache-semantics@npm:4.1.1" - checksum: 83ac0bc60b17a3a36f9953e7be55e5c8f41acc61b22583060e8dedc9dd5e3607c823a88d0926f9150e571f90946835c7fe150732801010845c72cd8bbff1a236 - languageName: node - linkType: hard - -"http-proxy-agent@npm:^5.0.0": - version: 5.0.0 - resolution: "http-proxy-agent@npm:5.0.0" - dependencies: - "@tootallnate/once": 2 - agent-base: 6 - debug: 4 - checksum: e2ee1ff1656a131953839b2a19cd1f3a52d97c25ba87bd2559af6ae87114abf60971e498021f9b73f9fd78aea8876d1fb0d4656aac8a03c6caa9fc175f22b786 - languageName: node - linkType: hard - -"https-proxy-agent@npm:^5.0.0": - version: 5.0.1 - resolution: "https-proxy-agent@npm:5.0.1" - dependencies: - agent-base: 6 - debug: 4 - checksum: 571fccdf38184f05943e12d37d6ce38197becdd69e58d03f43637f7fa1269cf303a7d228aa27e5b27bbd3af8f09fd938e1c91dcfefff2df7ba77c20ed8dfc765 - languageName: node - linkType: hard - -"humanize-ms@npm:^1.2.1": - version: 1.2.1 - resolution: "humanize-ms@npm:1.2.1" - dependencies: - ms: ^2.0.0 - checksum: 9c7a74a2827f9294c009266c82031030eae811ca87b0da3dceb8d6071b9bde22c9f3daef0469c3c533cc67a97d8a167cd9fc0389350e5f415f61a79b171ded16 - languageName: node - linkType: hard - -"iconv-lite@npm:^0.6.2": - version: 0.6.3 - resolution: "iconv-lite@npm:0.6.3" - dependencies: - safer-buffer: ">= 2.1.2 < 3.0.0" - checksum: 3f60d47a5c8fc3313317edfd29a00a692cc87a19cac0159e2ce711d0ebc9019064108323b5e493625e25594f11c6236647d8e256fbe7a58f4a3b33b89e6d30bf - languageName: node - linkType: hard - -"ignore@npm:^5.2.0": - version: 5.2.4 - resolution: "ignore@npm:5.2.4" - checksum: 3d4c309c6006e2621659311783eaea7ebcd41fe4ca1d78c91c473157ad6666a57a2df790fe0d07a12300d9aac2888204d7be8d59f9aaf665b1c7fcdb432517ef - languageName: node - linkType: hard - -"import-fresh@npm:^3.0.0, import-fresh@npm:^3.2.1": - version: 3.3.0 - resolution: "import-fresh@npm:3.3.0" - dependencies: - parent-module: ^1.0.0 - resolve-from: ^4.0.0 - checksum: 2cacfad06e652b1edc50be650f7ec3be08c5e5a6f6d12d035c440a42a8cc028e60a5b99ca08a77ab4d6b1346da7d971915828f33cdab730d3d42f08242d09baa - languageName: node - linkType: hard - -"imurmurhash@npm:^0.1.4": - version: 0.1.4 - resolution: "imurmurhash@npm:0.1.4" - checksum: 7cae75c8cd9a50f57dadd77482359f659eaebac0319dd9368bcd1714f55e65badd6929ca58569da2b6494ef13fdd5598cd700b1eba23f8b79c5f19d195a3ecf7 - languageName: node - linkType: hard - -"indent-string@npm:^4.0.0": - version: 4.0.0 - resolution: "indent-string@npm:4.0.0" - checksum: 824cfb9929d031dabf059bebfe08cf3137365e112019086ed3dcff6a0a7b698cb80cf67ccccde0e25b9e2d7527aa6cc1fed1ac490c752162496caba3e6699612 - languageName: node - linkType: hard - -"inflight@npm:^1.0.4": - version: 1.0.6 - resolution: "inflight@npm:1.0.6" - dependencies: - once: ^1.3.0 - wrappy: 1 - checksum: f4f76aa072ce19fae87ce1ef7d221e709afb59d445e05d47fba710e85470923a75de35bfae47da6de1b18afc3ce83d70facf44cfb0aff89f0a3f45c0a0244dfd - languageName: node - linkType: hard - -"inherits@npm:2, inherits@npm:^2.0.3": - version: 2.0.4 - resolution: "inherits@npm:2.0.4" - checksum: 4a48a733847879d6cf6691860a6b1e3f0f4754176e4d71494c41f3475553768b10f84b5ce1d40fbd0e34e6bfbb864ee35858ad4dd2cf31e02fc4a154b724d7f1 - languageName: node - linkType: hard - -"intercom-client@workspace:.": - version: 0.0.0-use.local - resolution: "intercom-client@workspace:." - dependencies: - "@istanbuljs/nyc-config-typescript": ^1.0.2 - "@types/lodash": ^4.14.195 - "@types/mocha": ^9.1.1 - "@types/node": ^16.18.38 - "@types/sinon": ^10.0.15 - "@typescript-eslint/eslint-plugin": ^5.61.0 - "@typescript-eslint/parser": ^5.61.0 - axios: ^1.6.0 - eslint: ^8.44.0 - eslint-config-prettier: ^8.8.0 - eslint-plugin-no-only-tests: ^2.6.0 - htmlencode: ^0.0.4 - lodash: ^4.17.21 - merge2: ^1.4.1 - mocha: ^9.2.2 - nock: ^13.3.1 - nyc: ^15.1.0 - prettier: ^2.8.8 - sinon: ^7.5.0 - ts-node: ^10.9.1 - tslib: ^2.6.0 - typescript: ^4.9.5 - languageName: unknown - linkType: soft - -"ip@npm:^2.0.0": - version: 2.0.0 - resolution: "ip@npm:2.0.0" - checksum: cfcfac6b873b701996d71ec82a7dd27ba92450afdb421e356f44044ed688df04567344c36cbacea7d01b1c39a4c732dc012570ebe9bebfb06f27314bca625349 - languageName: node - linkType: hard - -"is-binary-path@npm:~2.1.0": - version: 2.1.0 - resolution: "is-binary-path@npm:2.1.0" - dependencies: - binary-extensions: ^2.0.0 - checksum: 84192eb88cff70d320426f35ecd63c3d6d495da9d805b19bc65b518984b7c0760280e57dbf119b7e9be6b161784a5a673ab2c6abe83abb5198a432232ad5b35c - languageName: node - linkType: hard - -"is-extglob@npm:^2.1.1": - version: 2.1.1 - resolution: "is-extglob@npm:2.1.1" - checksum: df033653d06d0eb567461e58a7a8c9f940bd8c22274b94bf7671ab36df5719791aae15eef6d83bbb5e23283967f2f984b8914559d4449efda578c775c4be6f85 - languageName: node - linkType: hard - -"is-fullwidth-code-point@npm:^3.0.0": - version: 3.0.0 - resolution: "is-fullwidth-code-point@npm:3.0.0" - checksum: 44a30c29457c7fb8f00297bce733f0a64cd22eca270f83e58c105e0d015e45c019491a4ab2faef91ab51d4738c670daff901c799f6a700e27f7314029e99e348 - languageName: node - linkType: hard - -"is-glob@npm:^4.0.0, is-glob@npm:^4.0.1, is-glob@npm:^4.0.3, is-glob@npm:~4.0.1": - version: 4.0.3 - resolution: "is-glob@npm:4.0.3" - dependencies: - is-extglob: ^2.1.1 - checksum: d381c1319fcb69d341cc6e6c7cd588e17cd94722d9a32dbd60660b993c4fb7d0f19438674e68dfec686d09b7c73139c9166b47597f846af387450224a8101ab4 - languageName: node - linkType: hard - -"is-lambda@npm:^1.0.1": - version: 1.0.1 - resolution: "is-lambda@npm:1.0.1" - checksum: 93a32f01940220532e5948538699ad610d5924ac86093fcee83022252b363eb0cc99ba53ab084a04e4fb62bf7b5731f55496257a4c38adf87af9c4d352c71c35 - languageName: node - linkType: hard - -"is-number@npm:^7.0.0": - version: 7.0.0 - resolution: "is-number@npm:7.0.0" - checksum: 456ac6f8e0f3111ed34668a624e45315201dff921e5ac181f8ec24923b99e9f32ca1a194912dc79d539c97d33dba17dc635202ff0b2cf98326f608323276d27a - languageName: node - linkType: hard - -"is-path-inside@npm:^3.0.3": - version: 3.0.3 - resolution: "is-path-inside@npm:3.0.3" - checksum: abd50f06186a052b349c15e55b182326f1936c89a78bf6c8f2b707412517c097ce04bc49a0ca221787bc44e1049f51f09a2ffb63d22899051988d3a618ba13e9 - languageName: node - linkType: hard - -"is-plain-obj@npm:^2.1.0": - version: 2.1.0 - resolution: "is-plain-obj@npm:2.1.0" - checksum: cec9100678b0a9fe0248a81743041ed990c2d4c99f893d935545cfbc42876cbe86d207f3b895700c690ad2fa520e568c44afc1605044b535a7820c1d40e38daa - languageName: node - linkType: hard - -"is-stream@npm:^2.0.0": - version: 2.0.1 - resolution: "is-stream@npm:2.0.1" - checksum: b8e05ccdf96ac330ea83c12450304d4a591f9958c11fd17bed240af8d5ffe08aedafa4c0f4cfccd4d28dc9d4d129daca1023633d5c11601a6cbc77521f6fae66 - languageName: node - linkType: hard - -"is-typedarray@npm:^1.0.0": - version: 1.0.0 - resolution: "is-typedarray@npm:1.0.0" - checksum: 3508c6cd0a9ee2e0df2fa2e9baabcdc89e911c7bd5cf64604586697212feec525aa21050e48affb5ffc3df20f0f5d2e2cf79b08caa64e1ccc9578e251763aef7 - languageName: node - linkType: hard - -"is-unicode-supported@npm:^0.1.0": - version: 0.1.0 - resolution: "is-unicode-supported@npm:0.1.0" - checksum: a2aab86ee7712f5c2f999180daaba5f361bdad1efadc9610ff5b8ab5495b86e4f627839d085c6530363c6d6d4ecbde340fb8e54bdb83da4ba8e0865ed5513c52 - languageName: node - linkType: hard - -"is-windows@npm:^1.0.2": - version: 1.0.2 - resolution: "is-windows@npm:1.0.2" - checksum: 438b7e52656fe3b9b293b180defb4e448088e7023a523ec21a91a80b9ff8cdb3377ddb5b6e60f7c7de4fa8b63ab56e121b6705fe081b3cf1b828b0a380009ad7 - languageName: node - linkType: hard - -"isarray@npm:0.0.1": - version: 0.0.1 - resolution: "isarray@npm:0.0.1" - checksum: 49191f1425681df4a18c2f0f93db3adb85573bcdd6a4482539d98eac9e705d8961317b01175627e860516a2fc45f8f9302db26e5a380a97a520e272e2a40a8d4 - languageName: node - linkType: hard - -"isexe@npm:^2.0.0": - version: 2.0.0 - resolution: "isexe@npm:2.0.0" - checksum: 26bf6c5480dda5161c820c5b5c751ae1e766c587b1f951ea3fcfc973bafb7831ae5b54a31a69bd670220e42e99ec154475025a468eae58ea262f813fdc8d1c62 - languageName: node - linkType: hard - -"istanbul-lib-coverage@npm:^3.0.0, istanbul-lib-coverage@npm:^3.2.0": - version: 3.2.0 - resolution: "istanbul-lib-coverage@npm:3.2.0" - checksum: a2a545033b9d56da04a8571ed05c8120bf10e9bce01cf8633a3a2b0d1d83dff4ac4fe78d6d5673c27fc29b7f21a41d75f83a36be09f82a61c367b56aa73c1ff9 - languageName: node - linkType: hard - -"istanbul-lib-hook@npm:^3.0.0": - version: 3.0.0 - resolution: "istanbul-lib-hook@npm:3.0.0" - dependencies: - append-transform: ^2.0.0 - checksum: ac4d0a0751e959cfe4c95d817df5f1f573f9b0cf892552e60d81785654291391fac1ceb667f13bb17fcc2ef23b74c89ed8cf1c6148c833c8596a2b920b079101 - languageName: node - linkType: hard - -"istanbul-lib-instrument@npm:^4.0.0": - version: 4.0.3 - resolution: "istanbul-lib-instrument@npm:4.0.3" - dependencies: - "@babel/core": ^7.7.5 - "@istanbuljs/schema": ^0.1.2 - istanbul-lib-coverage: ^3.0.0 - semver: ^6.3.0 - checksum: fa1171d3022b1bb8f6a734042620ac5d9ee7dc80f3065a0bb12863e9f0494d0eefa3d86608fcc0254ab2765d29d7dad8bdc42e5f8df2f9a1fbe85ccc59d76cb9 - languageName: node - linkType: hard - -"istanbul-lib-processinfo@npm:^2.0.2": - version: 2.0.3 - resolution: "istanbul-lib-processinfo@npm:2.0.3" - dependencies: - archy: ^1.0.0 - cross-spawn: ^7.0.3 - istanbul-lib-coverage: ^3.2.0 - p-map: ^3.0.0 - rimraf: ^3.0.0 - uuid: ^8.3.2 - checksum: 501729e809a4e98bbb9f62f89cae924be81655a7ff8118661f8834a10bb89ed5d3a5099ea0b6555e1a8ee15a0099cb64f7170b89aae155ab2afacfe8dd94421a - languageName: node - linkType: hard - -"istanbul-lib-report@npm:^3.0.0": - version: 3.0.0 - resolution: "istanbul-lib-report@npm:3.0.0" - dependencies: - istanbul-lib-coverage: ^3.0.0 - make-dir: ^3.0.0 - supports-color: ^7.1.0 - checksum: 3f29eb3f53c59b987386e07fe772d24c7f58c6897f34c9d7a296f4000de7ae3de9eb95c3de3df91dc65b134c84dee35c54eee572a56243e8907c48064e34ff1b - languageName: node - linkType: hard - -"istanbul-lib-source-maps@npm:^4.0.0": - version: 4.0.1 - resolution: "istanbul-lib-source-maps@npm:4.0.1" - dependencies: - debug: ^4.1.1 - istanbul-lib-coverage: ^3.0.0 - source-map: ^0.6.1 - checksum: 21ad3df45db4b81852b662b8d4161f6446cd250c1ddc70ef96a585e2e85c26ed7cd9c2a396a71533cfb981d1a645508bc9618cae431e55d01a0628e7dec62ef2 - languageName: node - linkType: hard - -"istanbul-reports@npm:^3.0.2": - version: 3.1.5 - resolution: "istanbul-reports@npm:3.1.5" - dependencies: - html-escaper: ^2.0.0 - istanbul-lib-report: ^3.0.0 - checksum: 7867228f83ed39477b188ea07e7ccb9b4f5320b6f73d1db93a0981b7414fa4ef72d3f80c4692c442f90fc250d9406e71d8d7ab65bb615cb334e6292b73192b89 - languageName: node - linkType: hard - -"jackspeak@npm:^2.0.3": - version: 2.2.1 - resolution: "jackspeak@npm:2.2.1" - dependencies: - "@isaacs/cliui": ^8.0.2 - "@pkgjs/parseargs": ^0.11.0 - dependenciesMeta: - "@pkgjs/parseargs": - optional: true - checksum: e29291c0d0f280a063fa18fbd1e891ab8c2d7519fd34052c0ebde38538a15c603140d60c2c7f432375ff7ee4c5f1c10daa8b2ae19a97c3d4affe308c8360c1df - languageName: node - linkType: hard - -"js-tokens@npm:^4.0.0": - version: 4.0.0 - resolution: "js-tokens@npm:4.0.0" - checksum: 8a95213a5a77deb6cbe94d86340e8d9ace2b93bc367790b260101d2f36a2eaf4e4e22d9fa9cf459b38af3a32fb4190e638024cf82ec95ef708680e405ea7cc78 - languageName: node - linkType: hard - -"js-yaml@npm:4.1.0, js-yaml@npm:^4.1.0": - version: 4.1.0 - resolution: "js-yaml@npm:4.1.0" - dependencies: - argparse: ^2.0.1 - bin: - js-yaml: bin/js-yaml.js - checksum: c7830dfd456c3ef2c6e355cc5a92e6700ceafa1d14bba54497b34a99f0376cecbb3e9ac14d3e5849b426d5a5140709a66237a8c991c675431271c4ce5504151a - languageName: node - linkType: hard - -"js-yaml@npm:^3.13.1": - version: 3.14.1 - resolution: "js-yaml@npm:3.14.1" - dependencies: - argparse: ^1.0.7 - esprima: ^4.0.0 - bin: - js-yaml: bin/js-yaml.js - checksum: bef146085f472d44dee30ec34e5cf36bf89164f5d585435a3d3da89e52622dff0b188a580e4ad091c3341889e14cb88cac6e4deb16dc5b1e9623bb0601fc255c - languageName: node - linkType: hard - -"jsesc@npm:^2.5.1": - version: 2.5.2 - resolution: "jsesc@npm:2.5.2" - bin: - jsesc: bin/jsesc - checksum: 4dc190771129e12023f729ce20e1e0bfceac84d73a85bc3119f7f938843fe25a4aeccb54b6494dce26fcf263d815f5f31acdefac7cc9329efb8422a4f4d9fa9d - languageName: node - linkType: hard - -"json-schema-traverse@npm:^0.4.1": - version: 0.4.1 - resolution: "json-schema-traverse@npm:0.4.1" - checksum: 7486074d3ba247769fda17d5181b345c9fb7d12e0da98b22d1d71a5db9698d8b4bd900a3ec1a4ffdd60846fc2556274a5c894d0c48795f14cb03aeae7b55260b - languageName: node - linkType: hard - -"json-stable-stringify-without-jsonify@npm:^1.0.1": - version: 1.0.1 - resolution: "json-stable-stringify-without-jsonify@npm:1.0.1" - checksum: cff44156ddce9c67c44386ad5cddf91925fe06b1d217f2da9c4910d01f358c6e3989c4d5a02683c7a5667f9727ff05831f7aa8ae66c8ff691c556f0884d49215 - languageName: node - linkType: hard - -"json-stringify-safe@npm:^5.0.1": - version: 5.0.1 - resolution: "json-stringify-safe@npm:5.0.1" - checksum: 48ec0adad5280b8a96bb93f4563aa1667fd7a36334f79149abd42446d0989f2ddc58274b479f4819f1f00617957e6344c886c55d05a4e15ebb4ab931e4a6a8ee - languageName: node - linkType: hard - -"json5@npm:^2.2.2": - version: 2.2.3 - resolution: "json5@npm:2.2.3" - bin: - json5: lib/cli.js - checksum: 2a7436a93393830bce797d4626275152e37e877b265e94ca69c99e3d20c2b9dab021279146a39cdb700e71b2dd32a4cebd1514cd57cee102b1af906ce5040349 - languageName: node - linkType: hard - -"just-extend@npm:^4.0.2": - version: 4.2.1 - resolution: "just-extend@npm:4.2.1" - checksum: ff9fdede240fad313efeeeb68a660b942e5586d99c0058064c78884894a2690dc09bba44c994ad4e077e45d913fef01a9240c14a72c657b53687ac58de53b39c - languageName: node - linkType: hard - -"levn@npm:^0.4.1": - version: 0.4.1 - resolution: "levn@npm:0.4.1" - dependencies: - prelude-ls: ^1.2.1 - type-check: ~0.4.0 - checksum: 12c5021c859bd0f5248561bf139121f0358285ec545ebf48bb3d346820d5c61a4309535c7f387ed7d84361cf821e124ce346c6b7cef8ee09a67c1473b46d0fc4 - languageName: node - linkType: hard - -"locate-path@npm:^5.0.0": - version: 5.0.0 - resolution: "locate-path@npm:5.0.0" - dependencies: - p-locate: ^4.1.0 - checksum: 83e51725e67517287d73e1ded92b28602e3ae5580b301fe54bfb76c0c723e3f285b19252e375712316774cf52006cb236aed5704692c32db0d5d089b69696e30 - languageName: node - linkType: hard - -"locate-path@npm:^6.0.0": - version: 6.0.0 - resolution: "locate-path@npm:6.0.0" - dependencies: - p-locate: ^5.0.0 - checksum: 72eb661788a0368c099a184c59d2fee760b3831c9c1c33955e8a19ae4a21b4116e53fa736dc086cdeb9fce9f7cc508f2f92d2d3aae516f133e16a2bb59a39f5a - languageName: node - linkType: hard - -"lodash.flattendeep@npm:^4.4.0": - version: 4.4.0 - resolution: "lodash.flattendeep@npm:4.4.0" - checksum: 8521c919acac3d4bcf0aaf040c1ca9cb35d6c617e2d72e9b4d51c9a58b4366622cd6077441a18be626c3f7b28227502b3bf042903d447b056ee7e0b11d45c722 - languageName: node - linkType: hard - -"lodash.merge@npm:^4.6.2": - version: 4.6.2 - resolution: "lodash.merge@npm:4.6.2" - checksum: ad580b4bdbb7ca1f7abf7e1bce63a9a0b98e370cf40194b03380a46b4ed799c9573029599caebc1b14e3f24b111aef72b96674a56cfa105e0f5ac70546cdc005 - languageName: node - linkType: hard - -"lodash@npm:^4.17.15, lodash@npm:^4.17.21": - version: 4.17.21 - resolution: "lodash@npm:4.17.21" - checksum: eb835a2e51d381e561e508ce932ea50a8e5a68f4ebdd771ea240d3048244a8d13658acbd502cd4829768c56f2e16bdd4340b9ea141297d472517b83868e677f7 - languageName: node - linkType: hard - -"log-symbols@npm:4.1.0": - version: 4.1.0 - resolution: "log-symbols@npm:4.1.0" - dependencies: - chalk: ^4.1.0 - is-unicode-supported: ^0.1.0 - checksum: fce1497b3135a0198803f9f07464165e9eb83ed02ceb2273930a6f8a508951178d8cf4f0378e9d28300a2ed2bc49050995d2bd5f53ab716bb15ac84d58c6ef74 - languageName: node - linkType: hard - -"lolex@npm:^4.2.0": - version: 4.2.0 - resolution: "lolex@npm:4.2.0" - checksum: 0a83bfe1748fc745515dff9b3f722422918f5f6975104d7e576fc32c06b5398ee0c58525684068d4de49cdd49874e00b5e2b2d72ce8c5d829dab86c8c08ca31f - languageName: node - linkType: hard - -"lolex@npm:^5.0.1": - version: 5.1.2 - resolution: "lolex@npm:5.1.2" - dependencies: - "@sinonjs/commons": ^1.7.0 - checksum: 7eb468d4ef4746c024d23cb2b75f679f79449a9d5cbe11abadf2f3b147c1d7ffe28816438bedfb8a75c58357a625c2f9ba197b050c226d2b3f0c4a956cf556fb - languageName: node - linkType: hard - -"lru-cache@npm:^5.1.1": - version: 5.1.1 - resolution: "lru-cache@npm:5.1.1" - dependencies: - yallist: ^3.0.2 - checksum: c154ae1cbb0c2206d1501a0e94df349653c92c8cbb25236d7e85190bcaf4567a03ac6eb43166fabfa36fd35623694da7233e88d9601fbf411a9a481d85dbd2cb - languageName: node - linkType: hard - -"lru-cache@npm:^6.0.0": - version: 6.0.0 - resolution: "lru-cache@npm:6.0.0" - dependencies: - yallist: ^4.0.0 - checksum: f97f499f898f23e4585742138a22f22526254fdba6d75d41a1c2526b3b6cc5747ef59c5612ba7375f42aca4f8461950e925ba08c991ead0651b4918b7c978297 - languageName: node - linkType: hard - -"lru-cache@npm:^7.7.1": - version: 7.18.3 - resolution: "lru-cache@npm:7.18.3" - checksum: e550d772384709deea3f141af34b6d4fa392e2e418c1498c078de0ee63670f1f46f5eee746e8ef7e69e1c895af0d4224e62ee33e66a543a14763b0f2e74c1356 - languageName: node - linkType: hard - -"lru-cache@npm:^9.1.1 || ^10.0.0": - version: 10.0.0 - resolution: "lru-cache@npm:10.0.0" - checksum: 18f101675fe283bc09cda0ef1e3cc83781aeb8373b439f086f758d1d91b28730950db785999cd060d3c825a8571c03073e8c14512b6655af2188d623031baf50 - languageName: node - linkType: hard - -"make-dir@npm:^3.0.0, make-dir@npm:^3.0.2": - version: 3.1.0 - resolution: "make-dir@npm:3.1.0" - dependencies: - semver: ^6.0.0 - checksum: 484200020ab5a1fdf12f393fe5f385fc8e4378824c940fba1729dcd198ae4ff24867bc7a5646331e50cead8abff5d9270c456314386e629acec6dff4b8016b78 - languageName: node - linkType: hard - -"make-error@npm:^1.1.1": - version: 1.3.6 - resolution: "make-error@npm:1.3.6" - checksum: b86e5e0e25f7f777b77fabd8e2cbf15737972869d852a22b7e73c17623928fccb826d8e46b9951501d3f20e51ad74ba8c59ed584f610526a48f8ccf88aaec402 - languageName: node - linkType: hard - -"make-fetch-happen@npm:^11.0.3": - version: 11.1.1 - resolution: "make-fetch-happen@npm:11.1.1" - dependencies: - agentkeepalive: ^4.2.1 - cacache: ^17.0.0 - http-cache-semantics: ^4.1.1 - http-proxy-agent: ^5.0.0 - https-proxy-agent: ^5.0.0 - is-lambda: ^1.0.1 - lru-cache: ^7.7.1 - minipass: ^5.0.0 - minipass-fetch: ^3.0.0 - minipass-flush: ^1.0.5 - minipass-pipeline: ^1.2.4 - negotiator: ^0.6.3 - promise-retry: ^2.0.1 - socks-proxy-agent: ^7.0.0 - ssri: ^10.0.0 - checksum: 7268bf274a0f6dcf0343829489a4506603ff34bd0649c12058753900b0eb29191dce5dba12680719a5d0a983d3e57810f594a12f3c18494e93a1fbc6348a4540 - languageName: node - linkType: hard - -"merge2@npm:^1.3.0, merge2@npm:^1.4.1": - version: 1.4.1 - resolution: "merge2@npm:1.4.1" - checksum: 7268db63ed5169466540b6fb947aec313200bcf6d40c5ab722c22e242f651994619bcd85601602972d3c85bd2cc45a358a4c61937e9f11a061919a1da569b0c2 - languageName: node - linkType: hard - -"micromatch@npm:^4.0.4": - version: 4.0.5 - resolution: "micromatch@npm:4.0.5" - dependencies: - braces: ^3.0.2 - picomatch: ^2.3.1 - checksum: 02a17b671c06e8fefeeb6ef996119c1e597c942e632a21ef589154f23898c9c6a9858526246abb14f8bca6e77734aa9dcf65476fca47cedfb80d9577d52843fc - languageName: node - linkType: hard - -"mime-db@npm:1.52.0": - version: 1.52.0 - resolution: "mime-db@npm:1.52.0" - checksum: 0d99a03585f8b39d68182803b12ac601d9c01abfa28ec56204fa330bc9f3d1c5e14beb049bafadb3dbdf646dfb94b87e24d4ec7b31b7279ef906a8ea9b6a513f - languageName: node - linkType: hard - -"mime-types@npm:^2.1.12": - version: 2.1.35 - resolution: "mime-types@npm:2.1.35" - dependencies: - mime-db: 1.52.0 - checksum: 89a5b7f1def9f3af5dad6496c5ed50191ae4331cc5389d7c521c8ad28d5fdad2d06fd81baf38fed813dc4e46bb55c8145bb0ff406330818c9cf712fb2e9b3836 - languageName: node - linkType: hard - -"minimatch@npm:4.2.1": - version: 4.2.1 - resolution: "minimatch@npm:4.2.1" - dependencies: - brace-expansion: ^1.1.7 - checksum: 2b1514e3d0f29a549912f0db7ae7b82c5cab4a8f2dd0369f1c6451a325b3f12b2cf473c95873b6157bb8df183d6cf6db82ff03614b6adaaf1d7e055beccdfd01 - languageName: node - linkType: hard - -"minimatch@npm:^3.0.4, minimatch@npm:^3.0.5, minimatch@npm:^3.1.1, minimatch@npm:^3.1.2": - version: 3.1.2 - resolution: "minimatch@npm:3.1.2" - dependencies: - brace-expansion: ^1.1.7 - checksum: c154e566406683e7bcb746e000b84d74465b3a832c45d59912b9b55cd50dee66e5c4b1e5566dba26154040e51672f9aa450a9aef0c97cfc7336b78b7afb9540a - languageName: node - linkType: hard - -"minimatch@npm:^9.0.1": - version: 9.0.3 - resolution: "minimatch@npm:9.0.3" - dependencies: - brace-expansion: ^2.0.1 - checksum: 253487976bf485b612f16bf57463520a14f512662e592e95c571afdab1442a6a6864b6c88f248ce6fc4ff0b6de04ac7aa6c8bb51e868e99d1d65eb0658a708b5 - languageName: node - linkType: hard - -"minipass-collect@npm:^1.0.2": - version: 1.0.2 - resolution: "minipass-collect@npm:1.0.2" - dependencies: - minipass: ^3.0.0 - checksum: 14df761028f3e47293aee72888f2657695ec66bd7d09cae7ad558da30415fdc4752bbfee66287dcc6fd5e6a2fa3466d6c484dc1cbd986525d9393b9523d97f10 - languageName: node - linkType: hard - -"minipass-fetch@npm:^3.0.0": - version: 3.0.3 - resolution: "minipass-fetch@npm:3.0.3" - dependencies: - encoding: ^0.1.13 - minipass: ^5.0.0 - minipass-sized: ^1.0.3 - minizlib: ^2.1.2 - dependenciesMeta: - encoding: - optional: true - checksum: af5ab2552a16fcf505d35fd7ffb84b57f4a0eeb269e6e1d9a2a75824dda48b36e527083250b7cca4a4def21d9544e2ade441e4730e233c0bc2133f6abda31e18 - languageName: node - linkType: hard - -"minipass-flush@npm:^1.0.5": - version: 1.0.5 - resolution: "minipass-flush@npm:1.0.5" - dependencies: - minipass: ^3.0.0 - checksum: 56269a0b22bad756a08a94b1ffc36b7c9c5de0735a4dd1ab2b06c066d795cfd1f0ac44a0fcae13eece5589b908ecddc867f04c745c7009be0b566421ea0944cf - languageName: node - linkType: hard - -"minipass-pipeline@npm:^1.2.4": - version: 1.2.4 - resolution: "minipass-pipeline@npm:1.2.4" - dependencies: - minipass: ^3.0.0 - checksum: b14240dac0d29823c3d5911c286069e36d0b81173d7bdf07a7e4a91ecdef92cdff4baaf31ea3746f1c61e0957f652e641223970870e2353593f382112257971b - languageName: node - linkType: hard - -"minipass-sized@npm:^1.0.3": - version: 1.0.3 - resolution: "minipass-sized@npm:1.0.3" - dependencies: - minipass: ^3.0.0 - checksum: 79076749fcacf21b5d16dd596d32c3b6bf4d6e62abb43868fac21674078505c8b15eaca4e47ed844985a4514854f917d78f588fcd029693709417d8f98b2bd60 - languageName: node - linkType: hard - -"minipass@npm:^3.0.0": - version: 3.3.6 - resolution: "minipass@npm:3.3.6" - dependencies: - yallist: ^4.0.0 - checksum: a30d083c8054cee83cdcdc97f97e4641a3f58ae743970457b1489ce38ee1167b3aaf7d815cd39ec7a99b9c40397fd4f686e83750e73e652b21cb516f6d845e48 - languageName: node - linkType: hard - -"minipass@npm:^5.0.0": - version: 5.0.0 - resolution: "minipass@npm:5.0.0" - checksum: 425dab288738853fded43da3314a0b5c035844d6f3097a8e3b5b29b328da8f3c1af6fc70618b32c29ff906284cf6406b6841376f21caaadd0793c1d5a6a620ea - languageName: node - linkType: hard - -"minipass@npm:^5.0.0 || ^6.0.2 || ^7.0.0": - version: 7.0.1 - resolution: "minipass@npm:7.0.1" - checksum: fedd1293f6a1b4e406c242a1cecfb75d0a81422bb2c365d999e33a88642fb68d70a89d95b550e08c640b3c0d9162829310e0c58b9b846b9218de25779818c709 - languageName: node - linkType: hard - -"minizlib@npm:^2.1.1, minizlib@npm:^2.1.2": - version: 2.1.2 - resolution: "minizlib@npm:2.1.2" - dependencies: - minipass: ^3.0.0 - yallist: ^4.0.0 - checksum: f1fdeac0b07cf8f30fcf12f4b586795b97be856edea22b5e9072707be51fc95d41487faec3f265b42973a304fe3a64acd91a44a3826a963e37b37bafde0212c3 - languageName: node - linkType: hard - -"mkdirp@npm:^1.0.3": - version: 1.0.4 - resolution: "mkdirp@npm:1.0.4" - bin: - mkdirp: bin/cmd.js - checksum: a96865108c6c3b1b8e1d5e9f11843de1e077e57737602de1b82030815f311be11f96f09cce59bd5b903d0b29834733e5313f9301e3ed6d6f6fba2eae0df4298f - languageName: node - linkType: hard - -"mocha@npm:^9.2.2": - version: 9.2.2 - resolution: "mocha@npm:9.2.2" - dependencies: - "@ungap/promise-all-settled": 1.1.2 - ansi-colors: 4.1.1 - browser-stdout: 1.3.1 - chokidar: 3.5.3 - debug: 4.3.3 - diff: 5.0.0 - escape-string-regexp: 4.0.0 - find-up: 5.0.0 - glob: 7.2.0 - growl: 1.10.5 - he: 1.2.0 - js-yaml: 4.1.0 - log-symbols: 4.1.0 - minimatch: 4.2.1 - ms: 2.1.3 - nanoid: 3.3.1 - serialize-javascript: 6.0.0 - strip-json-comments: 3.1.1 - supports-color: 8.1.1 - which: 2.0.2 - workerpool: 6.2.0 - yargs: 16.2.0 - yargs-parser: 20.2.4 - yargs-unparser: 2.0.0 - bin: - _mocha: bin/_mocha - mocha: bin/mocha - checksum: 4d5ca4ce33fc66627e63acdf09a634e2358c9a00f61de7788b1091b6aad430da04f97f9ecb82d56dc034b623cb833b65576136fd010d77679c03fcea5bc1e12d - languageName: node - linkType: hard - -"ms@npm:2.1.2": - version: 2.1.2 - resolution: "ms@npm:2.1.2" - checksum: 673cdb2c3133eb050c745908d8ce632ed2c02d85640e2edb3ace856a2266a813b30c613569bf3354fdf4ea7d1a1494add3bfa95e2713baa27d0c2c71fc44f58f - languageName: node - linkType: hard - -"ms@npm:2.1.3, ms@npm:^2.0.0": - version: 2.1.3 - resolution: "ms@npm:2.1.3" - checksum: aa92de608021b242401676e35cfa5aa42dd70cbdc082b916da7fb925c542173e36bce97ea3e804923fe92c0ad991434e4a38327e15a1b5b5f945d66df615ae6d - languageName: node - linkType: hard - -"nanoid@npm:3.3.1": - version: 3.3.1 - resolution: "nanoid@npm:3.3.1" - bin: - nanoid: bin/nanoid.cjs - checksum: 4ef0969e1bbe866fc223eb32276cbccb0961900bfe79104fa5abe34361979dead8d0e061410a5c03bc3d47455685adf32c09d6f27790f4a6898fb51f7df7ec86 - languageName: node - linkType: hard - -"natural-compare-lite@npm:^1.4.0": - version: 1.4.0 - resolution: "natural-compare-lite@npm:1.4.0" - checksum: 5222ac3986a2b78dd6069ac62cbb52a7bf8ffc90d972ab76dfe7b01892485d229530ed20d0c62e79a6b363a663b273db3bde195a1358ce9e5f779d4453887225 - languageName: node - linkType: hard - -"natural-compare@npm:^1.4.0": - version: 1.4.0 - resolution: "natural-compare@npm:1.4.0" - checksum: 23ad088b08f898fc9b53011d7bb78ec48e79de7627e01ab5518e806033861bef68d5b0cd0e2205c2f36690ac9571ff6bcb05eb777ced2eeda8d4ac5b44592c3d - languageName: node - linkType: hard - -"negotiator@npm:^0.6.3": - version: 0.6.3 - resolution: "negotiator@npm:0.6.3" - checksum: b8ffeb1e262eff7968fc90a2b6767b04cfd9842582a9d0ece0af7049537266e7b2506dfb1d107a32f06dd849ab2aea834d5830f7f4d0e5cb7d36e1ae55d021d9 - languageName: node - linkType: hard - -"nise@npm:^1.5.2": - version: 1.5.3 - resolution: "nise@npm:1.5.3" - dependencies: - "@sinonjs/formatio": ^3.2.1 - "@sinonjs/text-encoding": ^0.7.1 - just-extend: ^4.0.2 - lolex: ^5.0.1 - path-to-regexp: ^1.7.0 - checksum: ec3af21345dcaf34650a6f5420a11e0fd21a836ac5960f5e8523c301ee98465abf88b958f7b3084ecc6e0a7133e5cf7963f4df176b90b423c4da4984f1ebd75e - languageName: node - linkType: hard - -"nock@npm:^13.3.1": - version: 13.3.1 - resolution: "nock@npm:13.3.1" - dependencies: - debug: ^4.1.0 - json-stringify-safe: ^5.0.1 - lodash: ^4.17.21 - propagate: ^2.0.0 - checksum: 0f2a73e8432f6b5650656c53eef99f9e5bbde3df538dc2f07057edc4438cfc61a394c9d06dd82e60f6e86d42433f20f3c04364a1f088beee7bf03a24e3f0fdd0 - languageName: node - linkType: hard - -"node-gyp@npm:latest": - version: 9.4.0 - resolution: "node-gyp@npm:9.4.0" - dependencies: - env-paths: ^2.2.0 - exponential-backoff: ^3.1.1 - glob: ^7.1.4 - graceful-fs: ^4.2.6 - make-fetch-happen: ^11.0.3 - nopt: ^6.0.0 - npmlog: ^6.0.0 - rimraf: ^3.0.2 - semver: ^7.3.5 - tar: ^6.1.2 - which: ^2.0.2 - bin: - node-gyp: bin/node-gyp.js - checksum: 78b404e2e0639d64e145845f7f5a3cb20c0520cdaf6dda2f6e025e9b644077202ea7de1232396ba5bde3fee84cdc79604feebe6ba3ec84d464c85d407bb5da99 - languageName: node - linkType: hard - -"node-preload@npm:^0.2.1": - version: 0.2.1 - resolution: "node-preload@npm:0.2.1" - dependencies: - process-on-spawn: ^1.0.0 - checksum: 4586f91ac7417b33accce0ac629fb60f642d0c8d212b3c536dc3dda37fe54f8a3b858273380e1036e41a65d85470332c358315d2288e6584260d620fb4b00fb3 - languageName: node - linkType: hard - -"node-releases@npm:^2.0.12": - version: 2.0.13 - resolution: "node-releases@npm:2.0.13" - checksum: 17ec8f315dba62710cae71a8dad3cd0288ba943d2ece43504b3b1aa8625bf138637798ab470b1d9035b0545996f63000a8a926e0f6d35d0996424f8b6d36dda3 - languageName: node - linkType: hard - -"nopt@npm:^6.0.0": - version: 6.0.0 - resolution: "nopt@npm:6.0.0" - dependencies: - abbrev: ^1.0.0 - bin: - nopt: bin/nopt.js - checksum: 82149371f8be0c4b9ec2f863cc6509a7fd0fa729929c009f3a58e4eb0c9e4cae9920e8f1f8eb46e7d032fec8fb01bede7f0f41a67eb3553b7b8e14fa53de1dac - languageName: node - linkType: hard - -"normalize-path@npm:^3.0.0, normalize-path@npm:~3.0.0": - version: 3.0.0 - resolution: "normalize-path@npm:3.0.0" - checksum: 88eeb4da891e10b1318c4b2476b6e2ecbeb5ff97d946815ffea7794c31a89017c70d7f34b3c2ebf23ef4e9fc9fb99f7dffe36da22011b5b5c6ffa34f4873ec20 - languageName: node - linkType: hard - -"npmlog@npm:^6.0.0": - version: 6.0.2 - resolution: "npmlog@npm:6.0.2" - dependencies: - are-we-there-yet: ^3.0.0 - console-control-strings: ^1.1.0 - gauge: ^4.0.3 - set-blocking: ^2.0.0 - checksum: ae238cd264a1c3f22091cdd9e2b106f684297d3c184f1146984ecbe18aaa86343953f26b9520dedd1b1372bc0316905b736c1932d778dbeb1fcf5a1001390e2a - languageName: node - linkType: hard - -"nyc@npm:^15.1.0": - version: 15.1.0 - resolution: "nyc@npm:15.1.0" - dependencies: - "@istanbuljs/load-nyc-config": ^1.0.0 - "@istanbuljs/schema": ^0.1.2 - caching-transform: ^4.0.0 - convert-source-map: ^1.7.0 - decamelize: ^1.2.0 - find-cache-dir: ^3.2.0 - find-up: ^4.1.0 - foreground-child: ^2.0.0 - get-package-type: ^0.1.0 - glob: ^7.1.6 - istanbul-lib-coverage: ^3.0.0 - istanbul-lib-hook: ^3.0.0 - istanbul-lib-instrument: ^4.0.0 - istanbul-lib-processinfo: ^2.0.2 - istanbul-lib-report: ^3.0.0 - istanbul-lib-source-maps: ^4.0.0 - istanbul-reports: ^3.0.2 - make-dir: ^3.0.0 - node-preload: ^0.2.1 - p-map: ^3.0.0 - process-on-spawn: ^1.0.0 - resolve-from: ^5.0.0 - rimraf: ^3.0.0 - signal-exit: ^3.0.2 - spawn-wrap: ^2.0.0 - test-exclude: ^6.0.0 - yargs: ^15.0.2 - bin: - nyc: bin/nyc.js - checksum: 82a7031982df2fd6ab185c9f1b5d032b6221846268007b45b5773c6582e776ab33e96cd22b4231520345942fcef69b4339bd967675b8483f3fa255b56326faef - languageName: node - linkType: hard - -"once@npm:^1.3.0": - version: 1.4.0 - resolution: "once@npm:1.4.0" - dependencies: - wrappy: 1 - checksum: cd0a88501333edd640d95f0d2700fbde6bff20b3d4d9bdc521bdd31af0656b5706570d6c6afe532045a20bb8dc0849f8332d6f2a416e0ba6d3d3b98806c7db68 - languageName: node - linkType: hard - -"optionator@npm:^0.9.3": - version: 0.9.3 - resolution: "optionator@npm:0.9.3" - dependencies: - "@aashutoshrathi/word-wrap": ^1.2.3 - deep-is: ^0.1.3 - fast-levenshtein: ^2.0.6 - levn: ^0.4.1 - prelude-ls: ^1.2.1 - type-check: ^0.4.0 - checksum: 09281999441f2fe9c33a5eeab76700795365a061563d66b098923eb719251a42bdbe432790d35064d0816ead9296dbeb1ad51a733edf4167c96bd5d0882e428a - languageName: node - linkType: hard - -"p-limit@npm:^2.2.0": - version: 2.3.0 - resolution: "p-limit@npm:2.3.0" - dependencies: - p-try: ^2.0.0 - checksum: 84ff17f1a38126c3314e91ecfe56aecbf36430940e2873dadaa773ffe072dc23b7af8e46d4b6485d302a11673fe94c6b67ca2cfbb60c989848b02100d0594ac1 - languageName: node - linkType: hard - -"p-limit@npm:^3.0.2": - version: 3.1.0 - resolution: "p-limit@npm:3.1.0" - dependencies: - yocto-queue: ^0.1.0 - checksum: 7c3690c4dbf62ef625671e20b7bdf1cbc9534e83352a2780f165b0d3ceba21907e77ad63401708145ca4e25bfc51636588d89a8c0aeb715e6c37d1c066430360 - languageName: node - linkType: hard - -"p-locate@npm:^4.1.0": - version: 4.1.0 - resolution: "p-locate@npm:4.1.0" - dependencies: - p-limit: ^2.2.0 - checksum: 513bd14a455f5da4ebfcb819ef706c54adb09097703de6aeaa5d26fe5ea16df92b48d1ac45e01e3944ce1e6aa2a66f7f8894742b8c9d6e276e16cd2049a2b870 - languageName: node - linkType: hard - -"p-locate@npm:^5.0.0": - version: 5.0.0 - resolution: "p-locate@npm:5.0.0" - dependencies: - p-limit: ^3.0.2 - checksum: 1623088f36cf1cbca58e9b61c4e62bf0c60a07af5ae1ca99a720837356b5b6c5ba3eb1b2127e47a06865fee59dd0453cad7cc844cda9d5a62ac1a5a51b7c86d3 - languageName: node - linkType: hard - -"p-map@npm:^3.0.0": - version: 3.0.0 - resolution: "p-map@npm:3.0.0" - dependencies: - aggregate-error: ^3.0.0 - checksum: 49b0fcbc66b1ef9cd379de1b4da07fa7a9f84b41509ea3f461c31903623aaba8a529d22f835e0d77c7cb9fcc16e4fae71e308fd40179aea514ba68f27032b5d5 - languageName: node - linkType: hard - -"p-map@npm:^4.0.0": - version: 4.0.0 - resolution: "p-map@npm:4.0.0" - dependencies: - aggregate-error: ^3.0.0 - checksum: cb0ab21ec0f32ddffd31dfc250e3afa61e103ef43d957cc45497afe37513634589316de4eb88abdfd969fe6410c22c0b93ab24328833b8eb1ccc087fc0442a1c - languageName: node - linkType: hard - -"p-try@npm:^2.0.0": - version: 2.2.0 - resolution: "p-try@npm:2.2.0" - checksum: f8a8e9a7693659383f06aec604ad5ead237c7a261c18048a6e1b5b85a5f8a067e469aa24f5bc009b991ea3b058a87f5065ef4176793a200d4917349881216cae - languageName: node - linkType: hard - -"package-hash@npm:^4.0.0": - version: 4.0.0 - resolution: "package-hash@npm:4.0.0" - dependencies: - graceful-fs: ^4.1.15 - hasha: ^5.0.0 - lodash.flattendeep: ^4.4.0 - release-zalgo: ^1.0.0 - checksum: 32c49e3a0e1c4a33b086a04cdd6d6e570aee019cb8402ec16476d9b3564a40e38f91ce1a1f9bc88b08f8ef2917a11e0b786c08140373bdf609ea90749031e6fc - languageName: node - linkType: hard - -"parent-module@npm:^1.0.0": - version: 1.0.1 - resolution: "parent-module@npm:1.0.1" - dependencies: - callsites: ^3.0.0 - checksum: 6ba8b255145cae9470cf5551eb74be2d22281587af787a2626683a6c20fbb464978784661478dd2a3f1dad74d1e802d403e1b03c1a31fab310259eec8ac560ff - languageName: node - linkType: hard - -"path-exists@npm:^4.0.0": - version: 4.0.0 - resolution: "path-exists@npm:4.0.0" - checksum: 505807199dfb7c50737b057dd8d351b82c033029ab94cb10a657609e00c1bc53b951cfdbccab8de04c5584d5eff31128ce6afd3db79281874a5ef2adbba55ed1 - languageName: node - linkType: hard - -"path-is-absolute@npm:^1.0.0": - version: 1.0.1 - resolution: "path-is-absolute@npm:1.0.1" - checksum: 060840f92cf8effa293bcc1bea81281bd7d363731d214cbe5c227df207c34cd727430f70c6037b5159c8a870b9157cba65e775446b0ab06fd5ecc7e54615a3b8 - languageName: node - linkType: hard - -"path-key@npm:^3.1.0": - version: 3.1.1 - resolution: "path-key@npm:3.1.1" - checksum: 55cd7a9dd4b343412a8386a743f9c746ef196e57c823d90ca3ab917f90ab9f13dd0ded27252ba49dbdfcab2b091d998bc446f6220cd3cea65db407502a740020 - languageName: node - linkType: hard - -"path-scurry@npm:^1.10.1": - version: 1.10.1 - resolution: "path-scurry@npm:1.10.1" - dependencies: - lru-cache: ^9.1.1 || ^10.0.0 - minipass: ^5.0.0 || ^6.0.2 || ^7.0.0 - checksum: e2557cff3a8fb8bc07afdd6ab163a92587884f9969b05bbbaf6fe7379348bfb09af9ed292af12ed32398b15fb443e81692047b786d1eeb6d898a51eb17ed7d90 - languageName: node - linkType: hard - -"path-to-regexp@npm:^1.7.0": - version: 1.9.0 - resolution: "path-to-regexp@npm:1.9.0" - dependencies: - isarray: 0.0.1 - checksum: 5b2ac9cab2a9f82effd30a35164b20998b18d99d96608281dd2cab6e66c0e4536187970369b185ab21d3815da1ecb7dcb2d5f97a4bf0ee6e31a9612299fca147 - languageName: node - linkType: hard - -"path-type@npm:^4.0.0": - version: 4.0.0 - resolution: "path-type@npm:4.0.0" - checksum: 5b1e2daa247062061325b8fdbfd1fb56dde0a448fb1455453276ea18c60685bdad23a445dc148cf87bc216be1573357509b7d4060494a6fd768c7efad833ee45 - languageName: node - linkType: hard - -"picocolors@npm:^1.0.0": - version: 1.0.0 - resolution: "picocolors@npm:1.0.0" - checksum: a2e8092dd86c8396bdba9f2b5481032848525b3dc295ce9b57896f931e63fc16f79805144321f72976383fc249584672a75cc18d6777c6b757603f372f745981 - languageName: node - linkType: hard - -"picomatch@npm:^2.0.4, picomatch@npm:^2.2.1, picomatch@npm:^2.3.1": - version: 2.3.1 - resolution: "picomatch@npm:2.3.1" - checksum: 050c865ce81119c4822c45d3c84f1ced46f93a0126febae20737bd05ca20589c564d6e9226977df859ed5e03dc73f02584a2b0faad36e896936238238b0446cf - languageName: node - linkType: hard - -"pkg-dir@npm:^4.1.0": - version: 4.2.0 - resolution: "pkg-dir@npm:4.2.0" - dependencies: - find-up: ^4.0.0 - checksum: 9863e3f35132bf99ae1636d31ff1e1e3501251d480336edb1c211133c8d58906bed80f154a1d723652df1fda91e01c7442c2eeaf9dc83157c7ae89087e43c8d6 - languageName: node - linkType: hard - -"prelude-ls@npm:^1.2.1": - version: 1.2.1 - resolution: "prelude-ls@npm:1.2.1" - checksum: cd192ec0d0a8e4c6da3bb80e4f62afe336df3f76271ac6deb0e6a36187133b6073a19e9727a1ff108cd8b9982e4768850d413baa71214dd80c7979617dca827a - languageName: node - linkType: hard - -"prettier@npm:^2.8.8": - version: 2.8.8 - resolution: "prettier@npm:2.8.8" - bin: - prettier: bin-prettier.js - checksum: b49e409431bf129dd89238d64299ba80717b57ff5a6d1c1a8b1a28b590d998a34e083fa13573bc732bb8d2305becb4c9a4407f8486c81fa7d55100eb08263cf8 - languageName: node - linkType: hard - -"process-on-spawn@npm:^1.0.0": - version: 1.0.0 - resolution: "process-on-spawn@npm:1.0.0" - dependencies: - fromentries: ^1.2.0 - checksum: 597769e3db6a8e2cb1cd64a952bbc150220588debac31c7cf1a9f620ce981e25583d8d70848d8a14953577608512984a8808c3be77e09af8ebdcdc14ec23a295 - languageName: node - linkType: hard - -"promise-retry@npm:^2.0.1": - version: 2.0.1 - resolution: "promise-retry@npm:2.0.1" - dependencies: - err-code: ^2.0.2 - retry: ^0.12.0 - checksum: f96a3f6d90b92b568a26f71e966cbbc0f63ab85ea6ff6c81284dc869b41510e6cdef99b6b65f9030f0db422bf7c96652a3fff9f2e8fb4a0f069d8f4430359429 - languageName: node - linkType: hard - -"propagate@npm:^2.0.0": - version: 2.0.1 - resolution: "propagate@npm:2.0.1" - checksum: c4febaee2be0979e82fb6b3727878fd122a98d64a7fa3c9d09b0576751b88514a9e9275b1b92e76b364d488f508e223bd7e1dcdc616be4cdda876072fbc2a96c - languageName: node - linkType: hard - -"proxy-from-env@npm:^1.1.0": - version: 1.1.0 - resolution: "proxy-from-env@npm:1.1.0" - checksum: ed7fcc2ba0a33404958e34d95d18638249a68c430e30fcb6c478497d72739ba64ce9810a24f53a7d921d0c065e5b78e3822759800698167256b04659366ca4d4 - languageName: node - linkType: hard - -"punycode@npm:^2.1.0": - version: 2.3.0 - resolution: "punycode@npm:2.3.0" - checksum: 39f760e09a2a3bbfe8f5287cf733ecdad69d6af2fe6f97ca95f24b8921858b91e9ea3c9eeec6e08cede96181b3bb33f95c6ffd8c77e63986508aa2e8159fa200 - languageName: node - linkType: hard - -"queue-microtask@npm:^1.2.2": - version: 1.2.3 - resolution: "queue-microtask@npm:1.2.3" - checksum: b676f8c040cdc5b12723ad2f91414d267605b26419d5c821ff03befa817ddd10e238d22b25d604920340fd73efd8ba795465a0377c4adf45a4a41e4234e42dc4 - languageName: node - linkType: hard - -"randombytes@npm:^2.1.0": - version: 2.1.0 - resolution: "randombytes@npm:2.1.0" - dependencies: - safe-buffer: ^5.1.0 - checksum: d779499376bd4cbb435ef3ab9a957006c8682f343f14089ed5f27764e4645114196e75b7f6abf1cbd84fd247c0cb0651698444df8c9bf30e62120fbbc52269d6 - languageName: node - linkType: hard - -"readable-stream@npm:^3.6.0": - version: 3.6.2 - resolution: "readable-stream@npm:3.6.2" - dependencies: - inherits: ^2.0.3 - string_decoder: ^1.1.1 - util-deprecate: ^1.0.1 - checksum: bdcbe6c22e846b6af075e32cf8f4751c2576238c5043169a1c221c92ee2878458a816a4ea33f4c67623c0b6827c8a400409bfb3cf0bf3381392d0b1dfb52ac8d - languageName: node - linkType: hard - -"readdirp@npm:~3.6.0": - version: 3.6.0 - resolution: "readdirp@npm:3.6.0" - dependencies: - picomatch: ^2.2.1 - checksum: 1ced032e6e45670b6d7352d71d21ce7edf7b9b928494dcaba6f11fba63180d9da6cd7061ebc34175ffda6ff529f481818c962952004d273178acd70f7059b320 - languageName: node - linkType: hard - -"release-zalgo@npm:^1.0.0": - version: 1.0.0 - resolution: "release-zalgo@npm:1.0.0" - dependencies: - es6-error: ^4.0.1 - checksum: b59849dc310f6c426f34e308c48ba83df3d034ddef75189951723bb2aac99d29d15f5e127edad951c4095fc9025aa582053907154d68fe0c5380cd6a75365e53 - languageName: node - linkType: hard - -"require-directory@npm:^2.1.1": - version: 2.1.1 - resolution: "require-directory@npm:2.1.1" - checksum: fb47e70bf0001fdeabdc0429d431863e9475e7e43ea5f94ad86503d918423c1543361cc5166d713eaa7029dd7a3d34775af04764bebff99ef413111a5af18c80 - languageName: node - linkType: hard - -"require-main-filename@npm:^2.0.0": - version: 2.0.0 - resolution: "require-main-filename@npm:2.0.0" - checksum: e9e294695fea08b076457e9ddff854e81bffbe248ed34c1eec348b7abbd22a0d02e8d75506559e2265e96978f3c4720bd77a6dad84755de8162b357eb6c778c7 - languageName: node - linkType: hard - -"resolve-from@npm:^4.0.0": - version: 4.0.0 - resolution: "resolve-from@npm:4.0.0" - checksum: f4ba0b8494846a5066328ad33ef8ac173801a51739eb4d63408c847da9a2e1c1de1e6cbbf72699211f3d13f8fc1325648b169bd15eb7da35688e30a5fb0e4a7f - languageName: node - linkType: hard - -"resolve-from@npm:^5.0.0": - version: 5.0.0 - resolution: "resolve-from@npm:5.0.0" - checksum: 4ceeb9113e1b1372d0cd969f3468fa042daa1dd9527b1b6bb88acb6ab55d8b9cd65dbf18819f9f9ddf0db804990901dcdaade80a215e7b2c23daae38e64f5bdf - languageName: node - linkType: hard - -"retry@npm:^0.12.0": - version: 0.12.0 - resolution: "retry@npm:0.12.0" - checksum: 623bd7d2e5119467ba66202d733ec3c2e2e26568074923bc0585b6b99db14f357e79bdedb63cab56cec47491c4a0da7e6021a7465ca6dc4f481d3898fdd3158c - languageName: node - linkType: hard - -"reusify@npm:^1.0.4": - version: 1.0.4 - resolution: "reusify@npm:1.0.4" - checksum: c3076ebcc22a6bc252cb0b9c77561795256c22b757f40c0d8110b1300723f15ec0fc8685e8d4ea6d7666f36c79ccc793b1939c748bf36f18f542744a4e379fcc - languageName: node - linkType: hard - -"rimraf@npm:^3.0.0, rimraf@npm:^3.0.2": - version: 3.0.2 - resolution: "rimraf@npm:3.0.2" - dependencies: - glob: ^7.1.3 - bin: - rimraf: bin.js - checksum: 87f4164e396f0171b0a3386cc1877a817f572148ee13a7e113b238e48e8a9f2f31d009a92ec38a591ff1567d9662c6b67fd8818a2dbbaed74bc26a87a2a4a9a0 - languageName: node - linkType: hard - -"run-parallel@npm:^1.1.9": - version: 1.2.0 - resolution: "run-parallel@npm:1.2.0" - dependencies: - queue-microtask: ^1.2.2 - checksum: cb4f97ad25a75ebc11a8ef4e33bb962f8af8516bb2001082ceabd8902e15b98f4b84b4f8a9b222e5d57fc3bd1379c483886ed4619367a7680dad65316993021d - languageName: node - linkType: hard - -"safe-buffer@npm:^5.1.0, safe-buffer@npm:~5.2.0": - version: 5.2.1 - resolution: "safe-buffer@npm:5.2.1" - checksum: b99c4b41fdd67a6aaf280fcd05e9ffb0813654894223afb78a31f14a19ad220bba8aba1cb14eddce1fcfb037155fe6de4e861784eb434f7d11ed58d1e70dd491 - languageName: node - linkType: hard - -"safer-buffer@npm:>= 2.1.2 < 3.0.0": - version: 2.1.2 - resolution: "safer-buffer@npm:2.1.2" - checksum: cab8f25ae6f1434abee8d80023d7e72b598cf1327164ddab31003c51215526801e40b66c5e65d658a0af1e9d6478cadcb4c745f4bd6751f97d8644786c0978b0 - languageName: node - linkType: hard - -"semver@npm:^6.0.0, semver@npm:^6.3.0": - version: 6.3.1 - resolution: "semver@npm:6.3.1" - bin: - semver: bin/semver.js - checksum: ae47d06de28836adb9d3e25f22a92943477371292d9b665fb023fae278d345d508ca1958232af086d85e0155aee22e313e100971898bbb8d5d89b8b1d4054ca2 - languageName: node - linkType: hard - -"semver@npm:^7.3.5, semver@npm:^7.3.7": - version: 7.5.4 - resolution: "semver@npm:7.5.4" - dependencies: - lru-cache: ^6.0.0 - bin: - semver: bin/semver.js - checksum: 12d8ad952fa353b0995bf180cdac205a4068b759a140e5d3c608317098b3575ac2f1e09182206bf2eb26120e1c0ed8fb92c48c592f6099680de56bb071423ca3 - languageName: node - linkType: hard - -"serialize-javascript@npm:6.0.0": - version: 6.0.0 - resolution: "serialize-javascript@npm:6.0.0" - dependencies: - randombytes: ^2.1.0 - checksum: 56f90b562a1bdc92e55afb3e657c6397c01a902c588c0fe3d4c490efdcc97dcd2a3074ba12df9e94630f33a5ce5b76a74784a7041294628a6f4306e0ec84bf93 - languageName: node - linkType: hard - -"set-blocking@npm:^2.0.0": - version: 2.0.0 - resolution: "set-blocking@npm:2.0.0" - checksum: 6e65a05f7cf7ebdf8b7c75b101e18c0b7e3dff4940d480efed8aad3a36a4005140b660fa1d804cb8bce911cac290441dc728084a30504d3516ac2ff7ad607b02 - languageName: node - linkType: hard - -"shebang-command@npm:^2.0.0": - version: 2.0.0 - resolution: "shebang-command@npm:2.0.0" - dependencies: - shebang-regex: ^3.0.0 - checksum: 6b52fe87271c12968f6a054e60f6bde5f0f3d2db483a1e5c3e12d657c488a15474121a1d55cd958f6df026a54374ec38a4a963988c213b7570e1d51575cea7fa - languageName: node - linkType: hard - -"shebang-regex@npm:^3.0.0": - version: 3.0.0 - resolution: "shebang-regex@npm:3.0.0" - checksum: 1a2bcae50de99034fcd92ad4212d8e01eedf52c7ec7830eedcf886622804fe36884278f2be8be0ea5fde3fd1c23911643a4e0f726c8685b61871c8908af01222 - languageName: node - linkType: hard - -"signal-exit@npm:^3.0.2, signal-exit@npm:^3.0.7": - version: 3.0.7 - resolution: "signal-exit@npm:3.0.7" - checksum: a2f098f247adc367dffc27845853e9959b9e88b01cb301658cfe4194352d8d2bb32e18467c786a7fe15f1d44b233ea35633d076d5e737870b7139949d1ab6318 - languageName: node - linkType: hard - -"signal-exit@npm:^4.0.1": - version: 4.0.2 - resolution: "signal-exit@npm:4.0.2" - checksum: 41f5928431cc6e91087bf0343db786a6313dd7c6fd7e551dbc141c95bb5fb26663444fd9df8ea47c5d7fc202f60aa7468c3162a9365cbb0615fc5e1b1328fe31 - languageName: node - linkType: hard - -"sinon@npm:^7.5.0": - version: 7.5.0 - resolution: "sinon@npm:7.5.0" - dependencies: - "@sinonjs/commons": ^1.4.0 - "@sinonjs/formatio": ^3.2.1 - "@sinonjs/samsam": ^3.3.3 - diff: ^3.5.0 - lolex: ^4.2.0 - nise: ^1.5.2 - supports-color: ^5.5.0 - checksum: e8cf6b3dd16e9c1ed1a2b9560c396a2d6205a4f32293b1762cb6ebb8f88cfa47db6aba45b0c1709ec396efb41d171d88c9b1ab8f32f35512eb9e5d0d0d15d307 - languageName: node - linkType: hard - -"slash@npm:^3.0.0": - version: 3.0.0 - resolution: "slash@npm:3.0.0" - checksum: 94a93fff615f25a999ad4b83c9d5e257a7280c90a32a7cb8b4a87996e4babf322e469c42b7f649fd5796edd8687652f3fb452a86dc97a816f01113183393f11c - languageName: node - linkType: hard - -"smart-buffer@npm:^4.2.0": - version: 4.2.0 - resolution: "smart-buffer@npm:4.2.0" - checksum: b5167a7142c1da704c0e3af85c402002b597081dd9575031a90b4f229ca5678e9a36e8a374f1814c8156a725d17008ae3bde63b92f9cfd132526379e580bec8b - languageName: node - linkType: hard - -"socks-proxy-agent@npm:^7.0.0": - version: 7.0.0 - resolution: "socks-proxy-agent@npm:7.0.0" - dependencies: - agent-base: ^6.0.2 - debug: ^4.3.3 - socks: ^2.6.2 - checksum: 720554370154cbc979e2e9ce6a6ec6ced205d02757d8f5d93fe95adae454fc187a5cbfc6b022afab850a5ce9b4c7d73e0f98e381879cf45f66317a4895953846 - languageName: node - linkType: hard - -"socks@npm:^2.6.2": - version: 2.7.1 - resolution: "socks@npm:2.7.1" - dependencies: - ip: ^2.0.0 - smart-buffer: ^4.2.0 - checksum: 259d9e3e8e1c9809a7f5c32238c3d4d2a36b39b83851d0f573bfde5f21c4b1288417ce1af06af1452569cd1eb0841169afd4998f0e04ba04656f6b7f0e46d748 - languageName: node - linkType: hard - -"source-map@npm:^0.6.1": - version: 0.6.1 - resolution: "source-map@npm:0.6.1" - checksum: 59ce8640cf3f3124f64ac289012c2b8bd377c238e316fb323ea22fbfe83da07d81e000071d7242cad7a23cd91c7de98e4df8830ec3f133cb6133a5f6e9f67bc2 - languageName: node - linkType: hard - -"spawn-wrap@npm:^2.0.0": - version: 2.0.0 - resolution: "spawn-wrap@npm:2.0.0" - dependencies: - foreground-child: ^2.0.0 - is-windows: ^1.0.2 - make-dir: ^3.0.0 - rimraf: ^3.0.0 - signal-exit: ^3.0.2 - which: ^2.0.1 - checksum: 5a518e37620def6d516b86207482a4f76bcf3c37c57d8d886d9fa399b04e5668d11fd12817b178029b02002a5ebbd09010374307effa821ba39594042f0a2d96 - languageName: node - linkType: hard - -"sprintf-js@npm:~1.0.2": - version: 1.0.3 - resolution: "sprintf-js@npm:1.0.3" - checksum: 19d79aec211f09b99ec3099b5b2ae2f6e9cdefe50bc91ac4c69144b6d3928a640bb6ae5b3def70c2e85a2c3d9f5ec2719921e3a59d3ca3ef4b2fd1a4656a0df3 - languageName: node - linkType: hard - -"ssri@npm:^10.0.0": - version: 10.0.4 - resolution: "ssri@npm:10.0.4" - dependencies: - minipass: ^5.0.0 - checksum: fb14da9f8a72b04eab163eb13a9dda11d5962cd2317f85457c4e0b575e9a6e0e3a6a87b5bf122c75cb36565830cd5f263fb457571bf6f1587eb5f95d095d6165 - languageName: node - linkType: hard - -"string-width-cjs@npm:string-width@^4.2.0, string-width@npm:^1.0.2 || 2 || 3 || 4, string-width@npm:^4.1.0, string-width@npm:^4.2.0, string-width@npm:^4.2.3": - version: 4.2.3 - resolution: "string-width@npm:4.2.3" - dependencies: - emoji-regex: ^8.0.0 - is-fullwidth-code-point: ^3.0.0 - strip-ansi: ^6.0.1 - checksum: e52c10dc3fbfcd6c3a15f159f54a90024241d0f149cf8aed2982a2d801d2e64df0bf1dc351cf8e95c3319323f9f220c16e740b06faecd53e2462df1d2b5443fb - languageName: node - linkType: hard - -"string-width@npm:^5.0.1, string-width@npm:^5.1.2": - version: 5.1.2 - resolution: "string-width@npm:5.1.2" - dependencies: - eastasianwidth: ^0.2.0 - emoji-regex: ^9.2.2 - strip-ansi: ^7.0.1 - checksum: 7369deaa29f21dda9a438686154b62c2c5f661f8dda60449088f9f980196f7908fc39fdd1803e3e01541970287cf5deae336798337e9319a7055af89dafa7193 - languageName: node - linkType: hard - -"string_decoder@npm:^1.1.1": - version: 1.3.0 - resolution: "string_decoder@npm:1.3.0" - dependencies: - safe-buffer: ~5.2.0 - checksum: 8417646695a66e73aefc4420eb3b84cc9ffd89572861fe004e6aeb13c7bc00e2f616247505d2dbbef24247c372f70268f594af7126f43548565c68c117bdeb56 - languageName: node - linkType: hard - -"strip-ansi-cjs@npm:strip-ansi@^6.0.1, strip-ansi@npm:^6.0.0, strip-ansi@npm:^6.0.1": - version: 6.0.1 - resolution: "strip-ansi@npm:6.0.1" - dependencies: - ansi-regex: ^5.0.1 - checksum: f3cd25890aef3ba6e1a74e20896c21a46f482e93df4a06567cebf2b57edabb15133f1f94e57434e0a958d61186087b1008e89c94875d019910a213181a14fc8c - languageName: node - linkType: hard - -"strip-ansi@npm:^7.0.1": - version: 7.1.0 - resolution: "strip-ansi@npm:7.1.0" - dependencies: - ansi-regex: ^6.0.1 - checksum: 859c73fcf27869c22a4e4d8c6acfe690064659e84bef9458aa6d13719d09ca88dcfd40cbf31fd0be63518ea1a643fe070b4827d353e09533a5b0b9fd4553d64d - languageName: node - linkType: hard - -"strip-bom@npm:^4.0.0": - version: 4.0.0 - resolution: "strip-bom@npm:4.0.0" - checksum: 9dbcfbaf503c57c06af15fe2c8176fb1bf3af5ff65003851a102749f875a6dbe0ab3b30115eccf6e805e9d756830d3e40ec508b62b3f1ddf3761a20ebe29d3f3 - languageName: node - linkType: hard - -"strip-json-comments@npm:3.1.1, strip-json-comments@npm:^3.1.0, strip-json-comments@npm:^3.1.1": - version: 3.1.1 - resolution: "strip-json-comments@npm:3.1.1" - checksum: 492f73e27268f9b1c122733f28ecb0e7e8d8a531a6662efbd08e22cccb3f9475e90a1b82cab06a392f6afae6d2de636f977e231296400d0ec5304ba70f166443 - languageName: node - linkType: hard - -"supports-color@npm:8.1.1": - version: 8.1.1 - resolution: "supports-color@npm:8.1.1" - dependencies: - has-flag: ^4.0.0 - checksum: c052193a7e43c6cdc741eb7f378df605636e01ad434badf7324f17fb60c69a880d8d8fcdcb562cf94c2350e57b937d7425ab5b8326c67c2adc48f7c87c1db406 - languageName: node - linkType: hard - -"supports-color@npm:^5.3.0, supports-color@npm:^5.5.0": - version: 5.5.0 - resolution: "supports-color@npm:5.5.0" - dependencies: - has-flag: ^3.0.0 - checksum: 95f6f4ba5afdf92f495b5a912d4abee8dcba766ae719b975c56c084f5004845f6f5a5f7769f52d53f40e21952a6d87411bafe34af4a01e65f9926002e38e1dac - languageName: node - linkType: hard - -"supports-color@npm:^7.1.0": - version: 7.2.0 - resolution: "supports-color@npm:7.2.0" - dependencies: - has-flag: ^4.0.0 - checksum: 3dda818de06ebbe5b9653e07842d9479f3555ebc77e9a0280caf5a14fb877ffee9ed57007c3b78f5a6324b8dbeec648d9e97a24e2ed9fdb81ddc69ea07100f4a - languageName: node - linkType: hard - -"tar@npm:^6.1.11, tar@npm:^6.1.2": - version: 6.1.15 - resolution: "tar@npm:6.1.15" - dependencies: - chownr: ^2.0.0 - fs-minipass: ^2.0.0 - minipass: ^5.0.0 - minizlib: ^2.1.1 - mkdirp: ^1.0.3 - yallist: ^4.0.0 - checksum: f23832fceeba7578bf31907aac744ae21e74a66f4a17a9e94507acf460e48f6db598c7023882db33bab75b80e027c21f276d405e4a0322d58f51c7088d428268 - languageName: node - linkType: hard - -"test-exclude@npm:^6.0.0": - version: 6.0.0 - resolution: "test-exclude@npm:6.0.0" - dependencies: - "@istanbuljs/schema": ^0.1.2 - glob: ^7.1.4 - minimatch: ^3.0.4 - checksum: 3b34a3d77165a2cb82b34014b3aba93b1c4637a5011807557dc2f3da826c59975a5ccad765721c4648b39817e3472789f9b0fa98fc854c5c1c7a1e632aacdc28 - languageName: node - linkType: hard - -"text-table@npm:^0.2.0": - version: 0.2.0 - resolution: "text-table@npm:0.2.0" - checksum: b6937a38c80c7f84d9c11dd75e49d5c44f71d95e810a3250bd1f1797fc7117c57698204adf676b71497acc205d769d65c16ae8fa10afad832ae1322630aef10a - languageName: node - linkType: hard - -"to-fast-properties@npm:^2.0.0": - version: 2.0.0 - resolution: "to-fast-properties@npm:2.0.0" - checksum: be2de62fe58ead94e3e592680052683b1ec986c72d589e7b21e5697f8744cdbf48c266fa72f6c15932894c10187b5f54573a3bcf7da0bfd964d5caf23d436168 - languageName: node - linkType: hard - -"to-regex-range@npm:^5.0.1": - version: 5.0.1 - resolution: "to-regex-range@npm:5.0.1" - dependencies: - is-number: ^7.0.0 - checksum: f76fa01b3d5be85db6a2a143e24df9f60dd047d151062d0ba3df62953f2f697b16fe5dad9b0ac6191c7efc7b1d9dcaa4b768174b7b29da89d4428e64bc0a20ed - languageName: node - linkType: hard - -"ts-node@npm:^10.9.1": - version: 10.9.1 - resolution: "ts-node@npm:10.9.1" - dependencies: - "@cspotcode/source-map-support": ^0.8.0 - "@tsconfig/node10": ^1.0.7 - "@tsconfig/node12": ^1.0.7 - "@tsconfig/node14": ^1.0.0 - "@tsconfig/node16": ^1.0.2 - acorn: ^8.4.1 - acorn-walk: ^8.1.1 - arg: ^4.1.0 - create-require: ^1.1.0 - diff: ^4.0.1 - make-error: ^1.1.1 - v8-compile-cache-lib: ^3.0.1 - yn: 3.1.1 - peerDependencies: - "@swc/core": ">=1.2.50" - "@swc/wasm": ">=1.2.50" - "@types/node": "*" - typescript: ">=2.7" - peerDependenciesMeta: - "@swc/core": - optional: true - "@swc/wasm": - optional: true - bin: - ts-node: dist/bin.js - ts-node-cwd: dist/bin-cwd.js - ts-node-esm: dist/bin-esm.js - ts-node-script: dist/bin-script.js - ts-node-transpile-only: dist/bin-transpile.js - ts-script: dist/bin-script-deprecated.js - checksum: 090adff1302ab20bd3486e6b4799e90f97726ed39e02b39e566f8ab674fd5bd5f727f43615debbfc580d33c6d9d1c6b1b3ce7d8e3cca3e20530a145ffa232c35 - languageName: node - linkType: hard - -"tslib@npm:^1.8.1": - version: 1.14.1 - resolution: "tslib@npm:1.14.1" - checksum: dbe628ef87f66691d5d2959b3e41b9ca0045c3ee3c7c7b906cc1e328b39f199bb1ad9e671c39025bd56122ac57dfbf7385a94843b1cc07c60a4db74795829acd - languageName: node - linkType: hard - -"tslib@npm:^2.6.0": - version: 2.6.0 - resolution: "tslib@npm:2.6.0" - checksum: c01066038f950016a18106ddeca4649b4d76caa76ec5a31e2a26e10586a59fceb4ee45e96719bf6c715648e7c14085a81fee5c62f7e9ebee68e77a5396e5538f - languageName: node - linkType: hard - -"tsutils@npm:^3.21.0": - version: 3.21.0 - resolution: "tsutils@npm:3.21.0" - dependencies: - tslib: ^1.8.1 - peerDependencies: - typescript: ">=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta" - checksum: 1843f4c1b2e0f975e08c4c21caa4af4f7f65a12ac1b81b3b8489366826259323feb3fc7a243123453d2d1a02314205a7634e048d4a8009921da19f99755cdc48 - languageName: node - linkType: hard - -"type-check@npm:^0.4.0, type-check@npm:~0.4.0": - version: 0.4.0 - resolution: "type-check@npm:0.4.0" - dependencies: - prelude-ls: ^1.2.1 - checksum: ec688ebfc9c45d0c30412e41ca9c0cdbd704580eb3a9ccf07b9b576094d7b86a012baebc95681999dd38f4f444afd28504cb3a89f2ef16b31d4ab61a0739025a - languageName: node - linkType: hard - -"type-detect@npm:4.0.8": - version: 4.0.8 - resolution: "type-detect@npm:4.0.8" - checksum: 62b5628bff67c0eb0b66afa371bd73e230399a8d2ad30d852716efcc4656a7516904570cd8631a49a3ce57c10225adf5d0cbdcb47f6b0255fe6557c453925a15 - languageName: node - linkType: hard - -"type-fest@npm:^0.20.2": - version: 0.20.2 - resolution: "type-fest@npm:0.20.2" - checksum: 4fb3272df21ad1c552486f8a2f8e115c09a521ad7a8db3d56d53718d0c907b62c6e9141ba5f584af3f6830d0872c521357e512381f24f7c44acae583ad517d73 - languageName: node - linkType: hard - -"type-fest@npm:^0.8.0": - version: 0.8.1 - resolution: "type-fest@npm:0.8.1" - checksum: d61c4b2eba24009033ae4500d7d818a94fd6d1b481a8111612ee141400d5f1db46f199c014766b9fa9b31a6a7374d96fc748c6d688a78a3ce5a33123839becb7 - languageName: node - linkType: hard - -"typedarray-to-buffer@npm:^3.1.5": - version: 3.1.5 - resolution: "typedarray-to-buffer@npm:3.1.5" - dependencies: - is-typedarray: ^1.0.0 - checksum: 99c11aaa8f45189fcfba6b8a4825fd684a321caa9bd7a76a27cf0c7732c174d198b99f449c52c3818107430b5f41c0ccbbfb75cb2ee3ca4a9451710986d61a60 - languageName: node - linkType: hard - -"typescript@npm:^4.9.5": - version: 4.9.5 - resolution: "typescript@npm:4.9.5" - bin: - tsc: bin/tsc - tsserver: bin/tsserver - checksum: ee000bc26848147ad423b581bd250075662a354d84f0e06eb76d3b892328d8d4440b7487b5a83e851b12b255f55d71835b008a66cbf8f255a11e4400159237db - languageName: node - linkType: hard - -"typescript@patch:typescript@^4.9.5#~builtin": - version: 4.9.5 - resolution: "typescript@patch:typescript@npm%3A4.9.5#~builtin::version=4.9.5&hash=493e53" - bin: - tsc: bin/tsc - tsserver: bin/tsserver - checksum: 2eee5c37cad4390385db5db5a8e81470e42e8f1401b0358d7390095d6f681b410f2c4a0c496c6ff9ebd775423c7785cdace7bcdad76c7bee283df3d9718c0f20 - languageName: node - linkType: hard - -"unique-filename@npm:^3.0.0": - version: 3.0.0 - resolution: "unique-filename@npm:3.0.0" - dependencies: - unique-slug: ^4.0.0 - checksum: 8e2f59b356cb2e54aab14ff98a51ac6c45781d15ceaab6d4f1c2228b780193dc70fae4463ce9e1df4479cb9d3304d7c2043a3fb905bdeca71cc7e8ce27e063df - languageName: node - linkType: hard - -"unique-slug@npm:^4.0.0": - version: 4.0.0 - resolution: "unique-slug@npm:4.0.0" - dependencies: - imurmurhash: ^0.1.4 - checksum: 0884b58365af59f89739e6f71e3feacb5b1b41f2df2d842d0757933620e6de08eff347d27e9d499b43c40476cbaf7988638d3acb2ffbcb9d35fd035591adfd15 - languageName: node - linkType: hard - -"update-browserslist-db@npm:^1.0.11": - version: 1.0.11 - resolution: "update-browserslist-db@npm:1.0.11" - dependencies: - escalade: ^3.1.1 - picocolors: ^1.0.0 - peerDependencies: - browserslist: ">= 4.21.0" - bin: - update-browserslist-db: cli.js - checksum: b98327518f9a345c7cad5437afae4d2ae7d865f9779554baf2a200fdf4bac4969076b679b1115434bd6557376bdd37ca7583d0f9b8f8e302d7d4cc1e91b5f231 - languageName: node - linkType: hard - -"uri-js@npm:^4.2.2": - version: 4.4.1 - resolution: "uri-js@npm:4.4.1" - dependencies: - punycode: ^2.1.0 - checksum: 7167432de6817fe8e9e0c9684f1d2de2bb688c94388f7569f7dbdb1587c9f4ca2a77962f134ec90be0cc4d004c939ff0d05acc9f34a0db39a3c797dada262633 - languageName: node - linkType: hard - -"util-deprecate@npm:^1.0.1": - version: 1.0.2 - resolution: "util-deprecate@npm:1.0.2" - checksum: 474acf1146cb2701fe3b074892217553dfcf9a031280919ba1b8d651a068c9b15d863b7303cb15bd00a862b498e6cf4ad7b4a08fb134edd5a6f7641681cb54a2 - languageName: node - linkType: hard - -"uuid@npm:^8.3.2": - version: 8.3.2 - resolution: "uuid@npm:8.3.2" - bin: - uuid: dist/bin/uuid - checksum: 5575a8a75c13120e2f10e6ddc801b2c7ed7d8f3c8ac22c7ed0c7b2ba6383ec0abda88c905085d630e251719e0777045ae3236f04c812184b7c765f63a70e58df - languageName: node - linkType: hard - -"v8-compile-cache-lib@npm:^3.0.1": - version: 3.0.1 - resolution: "v8-compile-cache-lib@npm:3.0.1" - checksum: 78089ad549e21bcdbfca10c08850022b22024cdcc2da9b168bcf5a73a6ed7bf01a9cebb9eac28e03cd23a684d81e0502797e88f3ccd27a32aeab1cfc44c39da0 - languageName: node - linkType: hard - -"which-module@npm:^2.0.0": - version: 2.0.1 - resolution: "which-module@npm:2.0.1" - checksum: 1967b7ce17a2485544a4fdd9063599f0f773959cca24176dbe8f405e55472d748b7c549cd7920ff6abb8f1ab7db0b0f1b36de1a21c57a8ff741f4f1e792c52be - languageName: node - linkType: hard - -"which@npm:2.0.2, which@npm:^2.0.1, which@npm:^2.0.2": - version: 2.0.2 - resolution: "which@npm:2.0.2" - dependencies: - isexe: ^2.0.0 - bin: - node-which: ./bin/node-which - checksum: 1a5c563d3c1b52d5f893c8b61afe11abc3bab4afac492e8da5bde69d550de701cf9806235f20a47b5c8fa8a1d6a9135841de2596535e998027a54589000e66d1 - languageName: node - linkType: hard - -"wide-align@npm:^1.1.5": - version: 1.1.5 - resolution: "wide-align@npm:1.1.5" - dependencies: - string-width: ^1.0.2 || 2 || 3 || 4 - checksum: d5fc37cd561f9daee3c80e03b92ed3e84d80dde3365a8767263d03dacfc8fa06b065ffe1df00d8c2a09f731482fcacae745abfbb478d4af36d0a891fad4834d3 - languageName: node - linkType: hard - -"workerpool@npm:6.2.0": - version: 6.2.0 - resolution: "workerpool@npm:6.2.0" - checksum: 3493b4f0ef979a23d2c1583d7ef85f62fc9463cc02f82829d3e7e663b517f8ae9707da0249b382e46ac58986deb0ca2232ee1081713741211bda9254b429c9bb - languageName: node - linkType: hard - -"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0, wrap-ansi@npm:^7.0.0": - version: 7.0.0 - resolution: "wrap-ansi@npm:7.0.0" - dependencies: - ansi-styles: ^4.0.0 - string-width: ^4.1.0 - strip-ansi: ^6.0.0 - checksum: a790b846fd4505de962ba728a21aaeda189b8ee1c7568ca5e817d85930e06ef8d1689d49dbf0e881e8ef84436af3a88bc49115c2e2788d841ff1b8b5b51a608b - languageName: node - linkType: hard - -"wrap-ansi@npm:^6.2.0": - version: 6.2.0 - resolution: "wrap-ansi@npm:6.2.0" - dependencies: - ansi-styles: ^4.0.0 - string-width: ^4.1.0 - strip-ansi: ^6.0.0 - checksum: 6cd96a410161ff617b63581a08376f0cb9162375adeb7956e10c8cd397821f7eb2a6de24eb22a0b28401300bf228c86e50617cd568209b5f6775b93c97d2fe3a - languageName: node - linkType: hard - -"wrap-ansi@npm:^8.1.0": - version: 8.1.0 - resolution: "wrap-ansi@npm:8.1.0" - dependencies: - ansi-styles: ^6.1.0 - string-width: ^5.0.1 - strip-ansi: ^7.0.1 - checksum: 371733296dc2d616900ce15a0049dca0ef67597d6394c57347ba334393599e800bab03c41d4d45221b6bc967b8c453ec3ae4749eff3894202d16800fdfe0e238 - languageName: node - linkType: hard - -"wrappy@npm:1": - version: 1.0.2 - resolution: "wrappy@npm:1.0.2" - checksum: 159da4805f7e84a3d003d8841557196034155008f817172d4e986bd591f74aa82aa7db55929a54222309e01079a65a92a9e6414da5a6aa4b01ee44a511ac3ee5 - languageName: node - linkType: hard - -"write-file-atomic@npm:^3.0.0": - version: 3.0.3 - resolution: "write-file-atomic@npm:3.0.3" - dependencies: - imurmurhash: ^0.1.4 - is-typedarray: ^1.0.0 - signal-exit: ^3.0.2 - typedarray-to-buffer: ^3.1.5 - checksum: c55b24617cc61c3a4379f425fc62a386cc51916a9b9d993f39734d005a09d5a4bb748bc251f1304e7abd71d0a26d339996c275955f527a131b1dcded67878280 - languageName: node - linkType: hard - -"y18n@npm:^4.0.0": - version: 4.0.3 - resolution: "y18n@npm:4.0.3" - checksum: 014dfcd9b5f4105c3bb397c1c8c6429a9df004aa560964fb36732bfb999bfe83d45ae40aeda5b55d21b1ee53d8291580a32a756a443e064317953f08025b1aa4 - languageName: node - linkType: hard - -"y18n@npm:^5.0.5": - version: 5.0.8 - resolution: "y18n@npm:5.0.8" - checksum: 54f0fb95621ee60898a38c572c515659e51cc9d9f787fb109cef6fde4befbe1c4602dc999d30110feee37456ad0f1660fa2edcfde6a9a740f86a290999550d30 - languageName: node - linkType: hard - -"yallist@npm:^3.0.2": - version: 3.1.1 - resolution: "yallist@npm:3.1.1" - checksum: 48f7bb00dc19fc635a13a39fe547f527b10c9290e7b3e836b9a8f1ca04d4d342e85714416b3c2ab74949c9c66f9cebb0473e6bc353b79035356103b47641285d - languageName: node - linkType: hard - -"yallist@npm:^4.0.0": - version: 4.0.0 - resolution: "yallist@npm:4.0.0" - checksum: 343617202af32df2a15a3be36a5a8c0c8545208f3d3dfbc6bb7c3e3b7e8c6f8e7485432e4f3b88da3031a6e20afa7c711eded32ddfb122896ac5d914e75848d5 - languageName: node - linkType: hard - -"yargs-parser@npm:20.2.4": - version: 20.2.4 - resolution: "yargs-parser@npm:20.2.4" - checksum: d251998a374b2743a20271c2fd752b9fbef24eb881d53a3b99a7caa5e8227fcafd9abf1f345ac5de46435821be25ec12189a11030c12ee6481fef6863ed8b924 - languageName: node - linkType: hard - -"yargs-parser@npm:^18.1.2": - version: 18.1.3 - resolution: "yargs-parser@npm:18.1.3" - dependencies: - camelcase: ^5.0.0 - decamelize: ^1.2.0 - checksum: 60e8c7d1b85814594d3719300ecad4e6ae3796748b0926137bfec1f3042581b8646d67e83c6fc80a692ef08b8390f21ddcacb9464476c39bbdf52e34961dd4d9 - languageName: node - linkType: hard - -"yargs-parser@npm:^20.2.2": - version: 20.2.9 - resolution: "yargs-parser@npm:20.2.9" - checksum: 8bb69015f2b0ff9e17b2c8e6bfe224ab463dd00ca211eece72a4cd8a906224d2703fb8a326d36fdd0e68701e201b2a60ed7cf81ce0fd9b3799f9fe7745977ae3 - languageName: node - linkType: hard - -"yargs-unparser@npm:2.0.0": - version: 2.0.0 - resolution: "yargs-unparser@npm:2.0.0" - dependencies: - camelcase: ^6.0.0 - decamelize: ^4.0.0 - flat: ^5.0.2 - is-plain-obj: ^2.1.0 - checksum: 68f9a542c6927c3768c2f16c28f71b19008710abd6b8f8efbac6dcce26bbb68ab6503bed1d5994bdbc2df9a5c87c161110c1dfe04c6a3fe5c6ad1b0e15d9a8a3 - languageName: node - linkType: hard - -"yargs@npm:16.2.0": - version: 16.2.0 - resolution: "yargs@npm:16.2.0" - dependencies: - cliui: ^7.0.2 - escalade: ^3.1.1 - get-caller-file: ^2.0.5 - require-directory: ^2.1.1 - string-width: ^4.2.0 - y18n: ^5.0.5 - yargs-parser: ^20.2.2 - checksum: b14afbb51e3251a204d81937c86a7e9d4bdbf9a2bcee38226c900d00f522969ab675703bee2a6f99f8e20103f608382936034e64d921b74df82b63c07c5e8f59 - languageName: node - linkType: hard - -"yargs@npm:^15.0.2": - version: 15.4.1 - resolution: "yargs@npm:15.4.1" - dependencies: - cliui: ^6.0.0 - decamelize: ^1.2.0 - find-up: ^4.1.0 - get-caller-file: ^2.0.1 - require-directory: ^2.1.1 - require-main-filename: ^2.0.0 - set-blocking: ^2.0.0 - string-width: ^4.2.0 - which-module: ^2.0.0 - y18n: ^4.0.0 - yargs-parser: ^18.1.2 - checksum: 40b974f508d8aed28598087720e086ecd32a5fd3e945e95ea4457da04ee9bdb8bdd17fd91acff36dc5b7f0595a735929c514c40c402416bbb87c03f6fb782373 - languageName: node - linkType: hard - -"yn@npm:3.1.1": - version: 3.1.1 - resolution: "yn@npm:3.1.1" - checksum: 2c487b0e149e746ef48cda9f8bad10fc83693cd69d7f9dcd8be4214e985de33a29c9e24f3c0d6bcf2288427040a8947406ab27f7af67ee9456e6b84854f02dd6 - languageName: node - linkType: hard - -"yocto-queue@npm:^0.1.0": - version: 0.1.0 - resolution: "yocto-queue@npm:0.1.0" - checksum: f77b3d8d00310def622123df93d4ee654fc6a0096182af8bd60679ddcdfb3474c56c6c7190817c84a2785648cdee9d721c0154eb45698c62176c322fb46fc700 - languageName: node - linkType: hard +# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. +# yarn lockfile v1 + + +"@ampproject/remapping@^2.2.0": + version "2.3.0" + resolved "https://registry.yarnpkg.com/@ampproject/remapping/-/remapping-2.3.0.tgz#ed441b6fa600072520ce18b43d2c8cc8caecc7f4" + integrity sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw== + dependencies: + "@jridgewell/gen-mapping" "^0.3.5" + "@jridgewell/trace-mapping" "^0.3.24" + +"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.12.13", "@babel/code-frame@^7.25.9", "@babel/code-frame@^7.26.0", "@babel/code-frame@^7.26.2": + version "7.26.2" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.26.2.tgz#4b5fab97d33338eff916235055f0ebc21e573a85" + integrity sha512-RJlIHRueQgwWitWgF8OdFYGZX328Ax5BCemNGlqHfplnRT9ESi8JkFlvaVYbS+UubVY6dpv87Fs2u5M29iNFVQ== + dependencies: + "@babel/helper-validator-identifier" "^7.25.9" + js-tokens "^4.0.0" + picocolors "^1.0.0" + +"@babel/compat-data@^7.25.9": + version "7.26.3" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.26.3.tgz#99488264a56b2aded63983abd6a417f03b92ed02" + integrity sha512-nHIxvKPniQXpmQLb0vhY3VaFb3S0YrTAwpOWJZh1wn3oJPjJk9Asva204PsBdmAE8vpzfHudT8DB0scYvy9q0g== + +"@babel/core@^7.11.6", "@babel/core@^7.12.3", "@babel/core@^7.23.9": + version "7.26.0" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.26.0.tgz#d78b6023cc8f3114ccf049eb219613f74a747b40" + integrity sha512-i1SLeK+DzNnQ3LL/CswPCa/E5u4lh1k6IAEphON8F+cXt0t9euTshDru0q7/IqMa1PMPz5RnHuHscF8/ZJsStg== + dependencies: + "@ampproject/remapping" "^2.2.0" + "@babel/code-frame" "^7.26.0" + "@babel/generator" "^7.26.0" + "@babel/helper-compilation-targets" "^7.25.9" + "@babel/helper-module-transforms" "^7.26.0" + "@babel/helpers" "^7.26.0" + "@babel/parser" "^7.26.0" + "@babel/template" "^7.25.9" + "@babel/traverse" "^7.25.9" + "@babel/types" "^7.26.0" + convert-source-map "^2.0.0" + debug "^4.1.0" + gensync "^1.0.0-beta.2" + json5 "^2.2.3" + semver "^6.3.1" + +"@babel/generator@^7.26.0", "@babel/generator@^7.26.3", "@babel/generator@^7.7.2": + version "7.26.3" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.26.3.tgz#ab8d4360544a425c90c248df7059881f4b2ce019" + integrity sha512-6FF/urZvD0sTeO7k6/B15pMLC4CHUv1426lzr3N01aHJTl046uCAh9LXW/fzeXXjPNCJ6iABW5XaWOsIZB93aQ== + dependencies: + "@babel/parser" "^7.26.3" + "@babel/types" "^7.26.3" + "@jridgewell/gen-mapping" "^0.3.5" + "@jridgewell/trace-mapping" "^0.3.25" + jsesc "^3.0.2" + +"@babel/helper-compilation-targets@^7.25.9": + version "7.25.9" + resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.25.9.tgz#55af025ce365be3cdc0c1c1e56c6af617ce88875" + integrity sha512-j9Db8Suy6yV/VHa4qzrj9yZfZxhLWQdVnRlXxmKLYlhWUVB1sB2G5sxuWYXk/whHD9iW76PmNzxZ4UCnTQTVEQ== + dependencies: + "@babel/compat-data" "^7.25.9" + "@babel/helper-validator-option" "^7.25.9" + browserslist "^4.24.0" + lru-cache "^5.1.1" + semver "^6.3.1" + +"@babel/helper-module-imports@^7.25.9": + version "7.25.9" + resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.25.9.tgz#e7f8d20602ebdbf9ebbea0a0751fb0f2a4141715" + integrity sha512-tnUA4RsrmflIM6W6RFTLFSXITtl0wKjgpnLgXyowocVPrbYrLUXSBXDgTs8BlbmIzIdlBySRQjINYs2BAkiLtw== + dependencies: + "@babel/traverse" "^7.25.9" + "@babel/types" "^7.25.9" + +"@babel/helper-module-transforms@^7.26.0": + version "7.26.0" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.26.0.tgz#8ce54ec9d592695e58d84cd884b7b5c6a2fdeeae" + integrity sha512-xO+xu6B5K2czEnQye6BHA7DolFFmS3LB7stHZFaOLb1pAwO1HWLS8fXA+eh0A2yIvltPVmx3eNNDBJA2SLHXFw== + dependencies: + "@babel/helper-module-imports" "^7.25.9" + "@babel/helper-validator-identifier" "^7.25.9" + "@babel/traverse" "^7.25.9" + +"@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.14.5", "@babel/helper-plugin-utils@^7.25.9", "@babel/helper-plugin-utils@^7.8.0": + version "7.25.9" + resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.25.9.tgz#9cbdd63a9443a2c92a725cca7ebca12cc8dd9f46" + integrity sha512-kSMlyUVdWe25rEsRGviIgOWnoT/nfABVWlqt9N19/dIPWViAOW2s9wznP5tURbs/IDuNk4gPy3YdYRgH3uxhBw== + +"@babel/helper-string-parser@^7.25.9": + version "7.25.9" + resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.25.9.tgz#1aabb72ee72ed35789b4bbcad3ca2862ce614e8c" + integrity sha512-4A/SCr/2KLd5jrtOMFzaKjVtAei3+2r/NChoBNoZ3EyP/+GlhoaEGoWOZUmFmoITP7zOJyHIMm+DYRd8o3PvHA== + +"@babel/helper-validator-identifier@^7.25.9": + version "7.25.9" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.25.9.tgz#24b64e2c3ec7cd3b3c547729b8d16871f22cbdc7" + integrity sha512-Ed61U6XJc3CVRfkERJWDz4dJwKe7iLmmJsbOGu9wSloNSFttHV0I8g6UAgb7qnK5ly5bGLPd4oXZlxCdANBOWQ== + +"@babel/helper-validator-option@^7.25.9": + version "7.25.9" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.25.9.tgz#86e45bd8a49ab7e03f276577f96179653d41da72" + integrity sha512-e/zv1co8pp55dNdEcCynfj9X7nyUKUXoUEwfXqaZt0omVOmDe9oOTdKStH4GmAw6zxMFs50ZayuMfHDKlO7Tfw== + +"@babel/helpers@^7.26.0": + version "7.26.0" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.26.0.tgz#30e621f1eba5aa45fe6f4868d2e9154d884119a4" + integrity sha512-tbhNuIxNcVb21pInl3ZSjksLCvgdZy9KwJ8brv993QtIVKJBBkYXz4q4ZbAv31GdnC+R90np23L5FbEBlthAEw== + dependencies: + "@babel/template" "^7.25.9" + "@babel/types" "^7.26.0" + +"@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.20.7", "@babel/parser@^7.23.9", "@babel/parser@^7.25.9", "@babel/parser@^7.26.0", "@babel/parser@^7.26.3": + version "7.26.3" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.26.3.tgz#8c51c5db6ddf08134af1ddbacf16aaab48bac234" + integrity sha512-WJ/CvmY8Mea8iDXo6a7RK2wbmJITT5fN3BEkRuFlxVyNx8jOKIIhmC4fSkTcPcf8JyavbBwIe6OpiCOBXt/IcA== + dependencies: + "@babel/types" "^7.26.3" + +"@babel/plugin-syntax-async-generators@^7.8.4": + version "7.8.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz#a983fb1aeb2ec3f6ed042a210f640e90e786fe0d" + integrity sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw== + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-bigint@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-bigint/-/plugin-syntax-bigint-7.8.3.tgz#4c9a6f669f5d0cdf1b90a1671e9a146be5300cea" + integrity sha512-wnTnFlG+YxQm3vDxpGE57Pj0srRU4sHE/mDkt1qv2YJJSeUAec2ma4WLUnUPeKjyrfntVwe/N6dCXpU+zL3Npg== + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-class-properties@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz#b5c987274c4a3a82b89714796931a6b53544ae10" + integrity sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA== + dependencies: + "@babel/helper-plugin-utils" "^7.12.13" + +"@babel/plugin-syntax-class-static-block@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-class-static-block/-/plugin-syntax-class-static-block-7.14.5.tgz#195df89b146b4b78b3bf897fd7a257c84659d406" + integrity sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-syntax-import-attributes@^7.24.7": + version "7.26.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-import-attributes/-/plugin-syntax-import-attributes-7.26.0.tgz#3b1412847699eea739b4f2602c74ce36f6b0b0f7" + integrity sha512-e2dttdsJ1ZTpi3B9UYGLw41hifAubg19AtCu/2I/F1QNVclOBr1dYpTdmdyZ84Xiz43BS/tCUkMAZNLv12Pi+A== + dependencies: + "@babel/helper-plugin-utils" "^7.25.9" + +"@babel/plugin-syntax-import-meta@^7.10.4": + version "7.10.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-import-meta/-/plugin-syntax-import-meta-7.10.4.tgz#ee601348c370fa334d2207be158777496521fd51" + integrity sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g== + dependencies: + "@babel/helper-plugin-utils" "^7.10.4" + +"@babel/plugin-syntax-json-strings@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz#01ca21b668cd8218c9e640cb6dd88c5412b2c96a" + integrity sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA== + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-jsx@^7.7.2": + version "7.25.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.25.9.tgz#a34313a178ea56f1951599b929c1ceacee719290" + integrity sha512-ld6oezHQMZsZfp6pWtbjaNDF2tiiCYYDqQszHt5VV437lewP9aSi2Of99CK0D0XB21k7FLgnLcmQKyKzynfeAA== + dependencies: + "@babel/helper-plugin-utils" "^7.25.9" + +"@babel/plugin-syntax-logical-assignment-operators@^7.10.4": + version "7.10.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz#ca91ef46303530448b906652bac2e9fe9941f699" + integrity sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig== + dependencies: + "@babel/helper-plugin-utils" "^7.10.4" + +"@babel/plugin-syntax-nullish-coalescing-operator@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz#167ed70368886081f74b5c36c65a88c03b66d1a9" + integrity sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ== + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-numeric-separator@^7.10.4": + version "7.10.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz#b9b070b3e33570cd9fd07ba7fa91c0dd37b9af97" + integrity sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug== + dependencies: + "@babel/helper-plugin-utils" "^7.10.4" + +"@babel/plugin-syntax-object-rest-spread@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz#60e225edcbd98a640332a2e72dd3e66f1af55871" + integrity sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA== + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-optional-catch-binding@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz#6111a265bcfb020eb9efd0fdfd7d26402b9ed6c1" + integrity sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q== + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-optional-chaining@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz#4f69c2ab95167e0180cd5336613f8c5788f7d48a" + integrity sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg== + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-private-property-in-object@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-private-property-in-object/-/plugin-syntax-private-property-in-object-7.14.5.tgz#0dc6671ec0ea22b6e94a1114f857970cd39de1ad" + integrity sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-syntax-top-level-await@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz#c1cfdadc35a646240001f06138247b741c34d94c" + integrity sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-syntax-typescript@^7.7.2": + version "7.25.9" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.25.9.tgz#67dda2b74da43727cf21d46cf9afef23f4365399" + integrity sha512-hjMgRy5hb8uJJjUcdWunWVcoi9bGpJp8p5Ol1229PoN6aytsLwNMgmdftO23wnCLMfVmTwZDWMPNq/D1SY60JQ== + dependencies: + "@babel/helper-plugin-utils" "^7.25.9" + +"@babel/template@^7.25.9", "@babel/template@^7.3.3": + version "7.25.9" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.25.9.tgz#ecb62d81a8a6f5dc5fe8abfc3901fc52ddf15016" + integrity sha512-9DGttpmPvIxBb/2uwpVo3dqJ+O6RooAFOS+lB+xDqoE2PVCE8nfoHMdZLpfCQRLwvohzXISPZcgxt80xLfsuwg== + dependencies: + "@babel/code-frame" "^7.25.9" + "@babel/parser" "^7.25.9" + "@babel/types" "^7.25.9" + +"@babel/traverse@^7.25.9": + version "7.26.4" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.26.4.tgz#ac3a2a84b908dde6d463c3bfa2c5fdc1653574bd" + integrity sha512-fH+b7Y4p3yqvApJALCPJcwb0/XaOSgtK4pzV6WVjPR5GLFQBRI7pfoX2V2iM48NXvX07NUxxm1Vw98YjqTcU5w== + dependencies: + "@babel/code-frame" "^7.26.2" + "@babel/generator" "^7.26.3" + "@babel/parser" "^7.26.3" + "@babel/template" "^7.25.9" + "@babel/types" "^7.26.3" + debug "^4.3.1" + globals "^11.1.0" + +"@babel/types@^7.0.0", "@babel/types@^7.20.7", "@babel/types@^7.25.9", "@babel/types@^7.26.0", "@babel/types@^7.26.3", "@babel/types@^7.3.3": + version "7.26.3" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.26.3.tgz#37e79830f04c2b5687acc77db97fbc75fb81f3c0" + integrity sha512-vN5p+1kl59GVKMvTHt55NzzmYVxprfJD+ql7U9NFIfKCBkYE55LYtS+WtPlaYOyzydrKI8Nezd+aZextrd+FMA== + dependencies: + "@babel/helper-string-parser" "^7.25.9" + "@babel/helper-validator-identifier" "^7.25.9" + +"@bcoe/v8-coverage@^0.2.3": + version "0.2.3" + resolved "https://registry.yarnpkg.com/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" + integrity sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw== + +"@istanbuljs/load-nyc-config@^1.0.0": + version "1.1.0" + resolved "https://registry.yarnpkg.com/@istanbuljs/load-nyc-config/-/load-nyc-config-1.1.0.tgz#fd3db1d59ecf7cf121e80650bb86712f9b55eced" + integrity sha512-VjeHSlIzpv/NyD3N0YuHfXOPDIixcA1q2ZV98wsMqcYlPmv2n3Yb2lYP9XMElnaFVXg5A7YLTeLu6V84uQDjmQ== + dependencies: + camelcase "^5.3.1" + find-up "^4.1.0" + get-package-type "^0.1.0" + js-yaml "^3.13.1" + resolve-from "^5.0.0" + +"@istanbuljs/schema@^0.1.2", "@istanbuljs/schema@^0.1.3": + version "0.1.3" + resolved "https://registry.yarnpkg.com/@istanbuljs/schema/-/schema-0.1.3.tgz#e45e384e4b8ec16bce2fd903af78450f6bf7ec98" + integrity sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA== + +"@jest/console@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/console/-/console-29.7.0.tgz#cd4822dbdb84529265c5a2bdb529a3c9cc950ffc" + integrity sha512-5Ni4CU7XHQi32IJ398EEP4RrB8eV09sXP2ROqD4bksHrnTree52PsxvX8tpL8LvTZ3pFzXyPbNQReSN41CAhOg== + dependencies: + "@jest/types" "^29.6.3" + "@types/node" "*" + chalk "^4.0.0" + jest-message-util "^29.7.0" + jest-util "^29.7.0" + slash "^3.0.0" + +"@jest/core@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/core/-/core-29.7.0.tgz#b6cccc239f30ff36609658c5a5e2291757ce448f" + integrity sha512-n7aeXWKMnGtDA48y8TLWJPJmLmmZ642Ceo78cYWEpiD7FzDgmNDV/GCVRorPABdXLJZ/9wzzgZAlHjXjxDHGsg== + dependencies: + "@jest/console" "^29.7.0" + "@jest/reporters" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/node" "*" + ansi-escapes "^4.2.1" + chalk "^4.0.0" + ci-info "^3.2.0" + exit "^0.1.2" + graceful-fs "^4.2.9" + jest-changed-files "^29.7.0" + jest-config "^29.7.0" + jest-haste-map "^29.7.0" + jest-message-util "^29.7.0" + jest-regex-util "^29.6.3" + jest-resolve "^29.7.0" + jest-resolve-dependencies "^29.7.0" + jest-runner "^29.7.0" + jest-runtime "^29.7.0" + jest-snapshot "^29.7.0" + jest-util "^29.7.0" + jest-validate "^29.7.0" + jest-watcher "^29.7.0" + micromatch "^4.0.4" + pretty-format "^29.7.0" + slash "^3.0.0" + strip-ansi "^6.0.0" + +"@jest/environment@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-29.7.0.tgz#24d61f54ff1f786f3cd4073b4b94416383baf2a7" + integrity sha512-aQIfHDq33ExsN4jP1NWGXhxgQ/wixs60gDiKO+XVMd8Mn0NWPWgc34ZQDTb2jKaUWQ7MuwoitXAsN2XVXNMpAw== + dependencies: + "@jest/fake-timers" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/node" "*" + jest-mock "^29.7.0" + +"@jest/expect-utils@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/expect-utils/-/expect-utils-29.7.0.tgz#023efe5d26a8a70f21677d0a1afc0f0a44e3a1c6" + integrity sha512-GlsNBWiFQFCVi9QVSx7f5AgMeLxe9YCCs5PuP2O2LdjDAA8Jh9eX7lA1Jq/xdXw3Wb3hyvlFNfZIfcRetSzYcA== + dependencies: + jest-get-type "^29.6.3" + +"@jest/expect@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/expect/-/expect-29.7.0.tgz#76a3edb0cb753b70dfbfe23283510d3d45432bf2" + integrity sha512-8uMeAMycttpva3P1lBHB8VciS9V0XAr3GymPpipdyQXbBcuhkLQOSe8E/p92RyAdToS6ZD1tFkX+CkhoECE0dQ== + dependencies: + expect "^29.7.0" + jest-snapshot "^29.7.0" + +"@jest/fake-timers@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-29.7.0.tgz#fd91bf1fffb16d7d0d24a426ab1a47a49881a565" + integrity sha512-q4DH1Ha4TTFPdxLsqDXK1d3+ioSL7yL5oCMJZgDYm6i+6CygW5E5xVr/D1HdsGxjt1ZWSfUAs9OxSB/BNelWrQ== + dependencies: + "@jest/types" "^29.6.3" + "@sinonjs/fake-timers" "^10.0.2" + "@types/node" "*" + jest-message-util "^29.7.0" + jest-mock "^29.7.0" + jest-util "^29.7.0" + +"@jest/globals@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/globals/-/globals-29.7.0.tgz#8d9290f9ec47ff772607fa864ca1d5a2efae1d4d" + integrity sha512-mpiz3dutLbkW2MNFubUGUEVLkTGiqW6yLVTA+JbP6fI6J5iL9Y0Nlg8k95pcF8ctKwCS7WVxteBs29hhfAotzQ== + dependencies: + "@jest/environment" "^29.7.0" + "@jest/expect" "^29.7.0" + "@jest/types" "^29.6.3" + jest-mock "^29.7.0" + +"@jest/reporters@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/reporters/-/reporters-29.7.0.tgz#04b262ecb3b8faa83b0b3d321623972393e8f4c7" + integrity sha512-DApq0KJbJOEzAFYjHADNNxAE3KbhxQB1y5Kplb5Waqw6zVbuWatSnMjE5gs8FUgEPmNsnZA3NCWl9NG0ia04Pg== + dependencies: + "@bcoe/v8-coverage" "^0.2.3" + "@jest/console" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" + "@jridgewell/trace-mapping" "^0.3.18" + "@types/node" "*" + chalk "^4.0.0" + collect-v8-coverage "^1.0.0" + exit "^0.1.2" + glob "^7.1.3" + graceful-fs "^4.2.9" + istanbul-lib-coverage "^3.0.0" + istanbul-lib-instrument "^6.0.0" + istanbul-lib-report "^3.0.0" + istanbul-lib-source-maps "^4.0.0" + istanbul-reports "^3.1.3" + jest-message-util "^29.7.0" + jest-util "^29.7.0" + jest-worker "^29.7.0" + slash "^3.0.0" + string-length "^4.0.1" + strip-ansi "^6.0.0" + v8-to-istanbul "^9.0.1" + +"@jest/schemas@^29.6.3": + version "29.6.3" + resolved "https://registry.yarnpkg.com/@jest/schemas/-/schemas-29.6.3.tgz#430b5ce8a4e0044a7e3819663305a7b3091c8e03" + integrity sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA== + dependencies: + "@sinclair/typebox" "^0.27.8" + +"@jest/source-map@^29.6.3": + version "29.6.3" + resolved "https://registry.yarnpkg.com/@jest/source-map/-/source-map-29.6.3.tgz#d90ba772095cf37a34a5eb9413f1b562a08554c4" + integrity sha512-MHjT95QuipcPrpLM+8JMSzFx6eHp5Bm+4XeFDJlwsvVBjmKNiIAvasGK2fxz2WbGRlnvqehFbh07MMa7n3YJnw== + dependencies: + "@jridgewell/trace-mapping" "^0.3.18" + callsites "^3.0.0" + graceful-fs "^4.2.9" + +"@jest/test-result@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-29.7.0.tgz#8db9a80aa1a097bb2262572686734baed9b1657c" + integrity sha512-Fdx+tv6x1zlkJPcWXmMDAG2HBnaR9XPSd5aDWQVsfrZmLVT3lU1cwyxLgRmXR9yrq4NBoEm9BMsfgFzTQAbJYA== + dependencies: + "@jest/console" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/istanbul-lib-coverage" "^2.0.0" + collect-v8-coverage "^1.0.0" + +"@jest/test-sequencer@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-29.7.0.tgz#6cef977ce1d39834a3aea887a1726628a6f072ce" + integrity sha512-GQwJ5WZVrKnOJuiYiAF52UNUJXgTZx1NHjFSEB0qEMmSZKAkdMoIzw/Cj6x6NF4AvV23AUqDpFzQkN/eYCYTxw== + dependencies: + "@jest/test-result" "^29.7.0" + graceful-fs "^4.2.9" + jest-haste-map "^29.7.0" + slash "^3.0.0" + +"@jest/transform@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-29.7.0.tgz#df2dd9c346c7d7768b8a06639994640c642e284c" + integrity sha512-ok/BTPFzFKVMwO5eOHRrvnBVHdRy9IrsrW1GpMaQ9MCnilNLXQKmAX8s1YXDFaai9xJpac2ySzV0YeRRECr2Vw== + dependencies: + "@babel/core" "^7.11.6" + "@jest/types" "^29.6.3" + "@jridgewell/trace-mapping" "^0.3.18" + babel-plugin-istanbul "^6.1.1" + chalk "^4.0.0" + convert-source-map "^2.0.0" + fast-json-stable-stringify "^2.1.0" + graceful-fs "^4.2.9" + jest-haste-map "^29.7.0" + jest-regex-util "^29.6.3" + jest-util "^29.7.0" + micromatch "^4.0.4" + pirates "^4.0.4" + slash "^3.0.0" + write-file-atomic "^4.0.2" + +"@jest/types@^29.6.3": + version "29.6.3" + resolved "https://registry.yarnpkg.com/@jest/types/-/types-29.6.3.tgz#1131f8cf634e7e84c5e77bab12f052af585fba59" + integrity sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw== + dependencies: + "@jest/schemas" "^29.6.3" + "@types/istanbul-lib-coverage" "^2.0.0" + "@types/istanbul-reports" "^3.0.0" + "@types/node" "*" + "@types/yargs" "^17.0.8" + chalk "^4.0.0" + +"@jridgewell/gen-mapping@^0.3.5": + version "0.3.8" + resolved "https://registry.yarnpkg.com/@jridgewell/gen-mapping/-/gen-mapping-0.3.8.tgz#4f0e06362e01362f823d348f1872b08f666d8142" + integrity sha512-imAbBGkb+ebQyxKgzv5Hu2nmROxoDOXHh80evxdoXNOrvAnVx7zimzc1Oo5h9RlfV4vPXaE2iM5pOFbvOCClWA== + dependencies: + "@jridgewell/set-array" "^1.2.1" + "@jridgewell/sourcemap-codec" "^1.4.10" + "@jridgewell/trace-mapping" "^0.3.24" + +"@jridgewell/resolve-uri@^3.1.0": + version "3.1.2" + resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz#7a0ee601f60f99a20c7c7c5ff0c80388c1189bd6" + integrity sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw== + +"@jridgewell/set-array@^1.2.1": + version "1.2.1" + resolved "https://registry.yarnpkg.com/@jridgewell/set-array/-/set-array-1.2.1.tgz#558fb6472ed16a4c850b889530e6b36438c49280" + integrity sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A== + +"@jridgewell/source-map@^0.3.3": + version "0.3.6" + resolved "https://registry.yarnpkg.com/@jridgewell/source-map/-/source-map-0.3.6.tgz#9d71ca886e32502eb9362c9a74a46787c36df81a" + integrity sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ== + dependencies: + "@jridgewell/gen-mapping" "^0.3.5" + "@jridgewell/trace-mapping" "^0.3.25" + +"@jridgewell/sourcemap-codec@^1.4.10", "@jridgewell/sourcemap-codec@^1.4.14": + version "1.5.0" + resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.0.tgz#3188bcb273a414b0d215fd22a58540b989b9409a" + integrity sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ== + +"@jridgewell/trace-mapping@^0.3.12", "@jridgewell/trace-mapping@^0.3.18", "@jridgewell/trace-mapping@^0.3.24", "@jridgewell/trace-mapping@^0.3.25": + version "0.3.25" + resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz#15f190e98895f3fc23276ee14bc76b675c2e50f0" + integrity sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ== + dependencies: + "@jridgewell/resolve-uri" "^3.1.0" + "@jridgewell/sourcemap-codec" "^1.4.14" + +"@sinclair/typebox@^0.27.8": + version "0.27.8" + resolved "https://registry.yarnpkg.com/@sinclair/typebox/-/typebox-0.27.8.tgz#6667fac16c436b5434a387a34dedb013198f6e6e" + integrity sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA== + +"@sinonjs/commons@^3.0.0": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-3.0.1.tgz#1029357e44ca901a615585f6d27738dbc89084cd" + integrity sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ== + dependencies: + type-detect "4.0.8" + +"@sinonjs/fake-timers@^10.0.2": + version "10.3.0" + resolved "https://registry.yarnpkg.com/@sinonjs/fake-timers/-/fake-timers-10.3.0.tgz#55fdff1ecab9f354019129daf4df0dd4d923ea66" + integrity sha512-V4BG07kuYSUkTCSBHG8G8TNhM+F19jXFWnQtzj+we8DrkpSBCee9Z3Ms8yiGer/dlmhe35/Xdgyo3/0rQKg7YA== + dependencies: + "@sinonjs/commons" "^3.0.0" + +"@tootallnate/once@2": + version "2.0.0" + resolved "https://registry.yarnpkg.com/@tootallnate/once/-/once-2.0.0.tgz#f544a148d3ab35801c1f633a7441fd87c2e484bf" + integrity sha512-XCuKFP5PS55gnMVu3dty8KPatLqUoy/ZYzDzAGCQ8JNFCkLXzmI7vNHCR+XpbZaMWQK/vQubr7PkYq8g470J/A== + +"@types/babel__core@^7.1.14": + version "7.20.5" + resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.20.5.tgz#3df15f27ba85319caa07ba08d0721889bb39c017" + integrity sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA== + dependencies: + "@babel/parser" "^7.20.7" + "@babel/types" "^7.20.7" + "@types/babel__generator" "*" + "@types/babel__template" "*" + "@types/babel__traverse" "*" + +"@types/babel__generator@*": + version "7.6.8" + resolved "https://registry.yarnpkg.com/@types/babel__generator/-/babel__generator-7.6.8.tgz#f836c61f48b1346e7d2b0d93c6dacc5b9535d3ab" + integrity sha512-ASsj+tpEDsEiFr1arWrlN6V3mdfjRMZt6LtK/Vp/kreFLnr5QH5+DhvD5nINYZXzwJvXeGq+05iUXcAzVrqWtw== + dependencies: + "@babel/types" "^7.0.0" + +"@types/babel__template@*": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@types/babel__template/-/babel__template-7.4.4.tgz#5672513701c1b2199bc6dad636a9d7491586766f" + integrity sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A== + dependencies: + "@babel/parser" "^7.1.0" + "@babel/types" "^7.0.0" + +"@types/babel__traverse@*", "@types/babel__traverse@^7.0.6": + version "7.20.6" + resolved "https://registry.yarnpkg.com/@types/babel__traverse/-/babel__traverse-7.20.6.tgz#8dc9f0ae0f202c08d8d4dab648912c8d6038e3f7" + integrity sha512-r1bzfrm0tomOI8g1SzvCaQHo6Lcv6zu0EA+W2kHrt8dyrHQxGzBBL4kdkzIS+jBMV+EYcMAEAqXqYaLJq5rOZg== + dependencies: + "@babel/types" "^7.20.7" + +"@types/eslint-scope@^3.7.7": + version "3.7.7" + resolved "https://registry.yarnpkg.com/@types/eslint-scope/-/eslint-scope-3.7.7.tgz#3108bd5f18b0cdb277c867b3dd449c9ed7079ac5" + integrity sha512-MzMFlSLBqNF2gcHWO0G1vP/YQyfvrxZ0bF+u7mzUdZ1/xK4A4sru+nraZz5i3iEIk1l1uyicaDVTB4QbbEkAYg== + dependencies: + "@types/eslint" "*" + "@types/estree" "*" + +"@types/eslint@*": + version "9.6.1" + resolved "https://registry.yarnpkg.com/@types/eslint/-/eslint-9.6.1.tgz#d5795ad732ce81715f27f75da913004a56751584" + integrity sha512-FXx2pKgId/WyYo2jXw63kk7/+TY7u7AziEJxJAnSFzHlqTAS3Ync6SvgYAN/k4/PQpnnVuzoMuVnByKK2qp0ag== + dependencies: + "@types/estree" "*" + "@types/json-schema" "*" + +"@types/estree@*", "@types/estree@^1.0.6": + version "1.0.6" + resolved "https://registry.yarnpkg.com/@types/estree/-/estree-1.0.6.tgz#628effeeae2064a1b4e79f78e81d87b7e5fc7b50" + integrity sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw== + +"@types/graceful-fs@^4.1.3": + version "4.1.9" + resolved "https://registry.yarnpkg.com/@types/graceful-fs/-/graceful-fs-4.1.9.tgz#2a06bc0f68a20ab37b3e36aa238be6abdf49e8b4" + integrity sha512-olP3sd1qOEe5dXTSaFvQG+02VdRXcdytWLAZsAq1PecU8uqQAhkrnbli7DagjtXKW/Bl7YJbUsa8MPcuc8LHEQ== + dependencies: + "@types/node" "*" + +"@types/istanbul-lib-coverage@*", "@types/istanbul-lib-coverage@^2.0.0", "@types/istanbul-lib-coverage@^2.0.1": + version "2.0.6" + resolved "https://registry.yarnpkg.com/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz#7739c232a1fee9b4d3ce8985f314c0c6d33549d7" + integrity sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w== + +"@types/istanbul-lib-report@*": + version "3.0.3" + resolved "https://registry.yarnpkg.com/@types/istanbul-lib-report/-/istanbul-lib-report-3.0.3.tgz#53047614ae72e19fc0401d872de3ae2b4ce350bf" + integrity sha512-NQn7AHQnk/RSLOxrBbGyJM/aVQ+pjj5HCgasFxc0K/KhoATfQ/47AyUl15I2yBUpihjmas+a+VJBOqecrFH+uA== + dependencies: + "@types/istanbul-lib-coverage" "*" + +"@types/istanbul-reports@^3.0.0": + version "3.0.4" + resolved "https://registry.yarnpkg.com/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz#0f03e3d2f670fbdac586e34b433783070cc16f54" + integrity sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ== + dependencies: + "@types/istanbul-lib-report" "*" + +"@types/jest@29.5.5": + version "29.5.5" + resolved "https://registry.yarnpkg.com/@types/jest/-/jest-29.5.5.tgz#727204e06228fe24373df9bae76b90f3e8236a2a" + integrity sha512-ebylz2hnsWR9mYvmBFbXJXr+33UPc4+ZdxyDXh5w0FlPBTfCVN3wPL+kuOiQt3xvrK419v7XWeAs+AeOksafXg== + dependencies: + expect "^29.0.0" + pretty-format "^29.0.0" + +"@types/jsdom@^20.0.0": + version "20.0.1" + resolved "https://registry.yarnpkg.com/@types/jsdom/-/jsdom-20.0.1.tgz#07c14bc19bd2f918c1929541cdaacae894744808" + integrity sha512-d0r18sZPmMQr1eG35u12FZfhIXNrnsPU/g5wvRKCUf/tOGilKKwYMYGqh33BNR6ba+2gkHw1EUiHoN3mn7E5IQ== + dependencies: + "@types/node" "*" + "@types/tough-cookie" "*" + parse5 "^7.0.0" + +"@types/json-schema@*", "@types/json-schema@^7.0.8", "@types/json-schema@^7.0.9": + version "7.0.15" + resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.15.tgz#596a1747233694d50f6ad8a7869fcb6f56cf5841" + integrity sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA== + +"@types/node-fetch@2.6.9": + version "2.6.9" + resolved "https://registry.yarnpkg.com/@types/node-fetch/-/node-fetch-2.6.9.tgz#15f529d247f1ede1824f7e7acdaa192d5f28071e" + integrity sha512-bQVlnMLFJ2d35DkPNjEPmd9ueO/rh5EiaZt2bhqiSarPjZIuIV6bPQVqcrEyvNo+AfTrRGVazle1tl597w3gfA== + dependencies: + "@types/node" "*" + form-data "^4.0.0" + +"@types/node@*": + version "22.10.2" + resolved "https://registry.yarnpkg.com/@types/node/-/node-22.10.2.tgz#a485426e6d1fdafc7b0d4c7b24e2c78182ddabb9" + integrity sha512-Xxr6BBRCAOQixvonOye19wnzyDiUtTeqldOOmj3CkeblonbccA12PFwlufvRdrpjXxqnmUaeiU5EOA+7s5diUQ== + dependencies: + undici-types "~6.20.0" + +"@types/node@17.0.33": + version "17.0.33" + resolved "https://registry.yarnpkg.com/@types/node/-/node-17.0.33.tgz#3c1879b276dc63e73030bb91165e62a4509cd506" + integrity sha512-miWq2m2FiQZmaHfdZNcbpp9PuXg34W5JZ5CrJ/BaS70VuhoJENBEQybeiYSaPBRNq6KQGnjfEnc/F3PN++D+XQ== + +"@types/qs@6.9.8": + version "6.9.8" + resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.9.8.tgz#f2a7de3c107b89b441e071d5472e6b726b4adf45" + integrity sha512-u95svzDlTysU5xecFNTgfFG5RUWu1A9P0VzgpcIiGZA9iraHOdSzcxMxQ55DyeRaGCSxQi7LxXDI4rzq/MYfdg== + +"@types/readable-stream@^4.0.15": + version "4.0.18" + resolved "https://registry.yarnpkg.com/@types/readable-stream/-/readable-stream-4.0.18.tgz#5d8d15d26c776500ce573cae580787d149823bfc" + integrity sha512-21jK/1j+Wg+7jVw1xnSwy/2Q1VgVjWuFssbYGTREPUBeZ+rqVFl2udq0IkxzPC0ZhOzVceUbyIACFZKLqKEBlA== + dependencies: + "@types/node" "*" + safe-buffer "~5.1.1" + +"@types/stack-utils@^2.0.0": + version "2.0.3" + resolved "https://registry.yarnpkg.com/@types/stack-utils/-/stack-utils-2.0.3.tgz#6209321eb2c1712a7e7466422b8cb1fc0d9dd5d8" + integrity sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw== + +"@types/tough-cookie@*": + version "4.0.5" + resolved "https://registry.yarnpkg.com/@types/tough-cookie/-/tough-cookie-4.0.5.tgz#cb6e2a691b70cb177c6e3ae9c1d2e8b2ea8cd304" + integrity sha512-/Ad8+nIOV7Rl++6f1BdKxFSMgmoqEoYbHRpPcx3JEfv8VRsQe9Z4mCXeJBzxs7mbHY/XOZZuXlRNfhpVPbs6ZA== + +"@types/url-join@4.0.1": + version "4.0.1" + resolved "https://registry.yarnpkg.com/@types/url-join/-/url-join-4.0.1.tgz#4989c97f969464647a8586c7252d97b449cdc045" + integrity sha512-wDXw9LEEUHyV+7UWy7U315nrJGJ7p1BzaCxDpEoLr789Dk1WDVMMlf3iBfbG2F8NdWnYyFbtTxUn2ZNbm1Q4LQ== + +"@types/yargs-parser@*": + version "21.0.3" + resolved "https://registry.yarnpkg.com/@types/yargs-parser/-/yargs-parser-21.0.3.tgz#815e30b786d2e8f0dcd85fd5bcf5e1a04d008f15" + integrity sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ== + +"@types/yargs@^17.0.8": + version "17.0.33" + resolved "https://registry.yarnpkg.com/@types/yargs/-/yargs-17.0.33.tgz#8c32303da83eec050a84b3c7ae7b9f922d13e32d" + integrity sha512-WpxBCKWPLr4xSsHgz511rFJAM+wS28w2zEO1QDNY5zM/S8ok70NNfztH0xwhqKyaK0OHCbN98LDAZuy1ctxDkA== + dependencies: + "@types/yargs-parser" "*" + +"@webassemblyjs/ast@1.14.1", "@webassemblyjs/ast@^1.14.1": + version "1.14.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/ast/-/ast-1.14.1.tgz#a9f6a07f2b03c95c8d38c4536a1fdfb521ff55b6" + integrity sha512-nuBEDgQfm1ccRp/8bCQrx1frohyufl4JlbMMZ4P1wpeOfDhF6FQkxZJ1b/e+PLwr6X1Nhw6OLme5usuBWYBvuQ== + dependencies: + "@webassemblyjs/helper-numbers" "1.13.2" + "@webassemblyjs/helper-wasm-bytecode" "1.13.2" + +"@webassemblyjs/floating-point-hex-parser@1.13.2": + version "1.13.2" + resolved "https://registry.yarnpkg.com/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.13.2.tgz#fcca1eeddb1cc4e7b6eed4fc7956d6813b21b9fb" + integrity sha512-6oXyTOzbKxGH4steLbLNOu71Oj+C8Lg34n6CqRvqfS2O71BxY6ByfMDRhBytzknj9yGUPVJ1qIKhRlAwO1AovA== + +"@webassemblyjs/helper-api-error@1.13.2": + version "1.13.2" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-api-error/-/helper-api-error-1.13.2.tgz#e0a16152248bc38daee76dd7e21f15c5ef3ab1e7" + integrity sha512-U56GMYxy4ZQCbDZd6JuvvNV/WFildOjsaWD3Tzzvmw/mas3cXzRJPMjP83JqEsgSbyrmaGjBfDtV7KDXV9UzFQ== + +"@webassemblyjs/helper-buffer@1.14.1": + version "1.14.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-buffer/-/helper-buffer-1.14.1.tgz#822a9bc603166531f7d5df84e67b5bf99b72b96b" + integrity sha512-jyH7wtcHiKssDtFPRB+iQdxlDf96m0E39yb0k5uJVhFGleZFoNw1c4aeIcVUPPbXUVJ94wwnMOAqUHyzoEPVMA== + +"@webassemblyjs/helper-numbers@1.13.2": + version "1.13.2" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-numbers/-/helper-numbers-1.13.2.tgz#dbd932548e7119f4b8a7877fd5a8d20e63490b2d" + integrity sha512-FE8aCmS5Q6eQYcV3gI35O4J789wlQA+7JrqTTpJqn5emA4U2hvwJmvFRC0HODS+3Ye6WioDklgd6scJ3+PLnEA== + dependencies: + "@webassemblyjs/floating-point-hex-parser" "1.13.2" + "@webassemblyjs/helper-api-error" "1.13.2" + "@xtuc/long" "4.2.2" + +"@webassemblyjs/helper-wasm-bytecode@1.13.2": + version "1.13.2" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.13.2.tgz#e556108758f448aae84c850e593ce18a0eb31e0b" + integrity sha512-3QbLKy93F0EAIXLh0ogEVR6rOubA9AoZ+WRYhNbFyuB70j3dRdwH9g+qXhLAO0kiYGlg3TxDV+I4rQTr/YNXkA== + +"@webassemblyjs/helper-wasm-section@1.14.1": + version "1.14.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.14.1.tgz#9629dda9c4430eab54b591053d6dc6f3ba050348" + integrity sha512-ds5mXEqTJ6oxRoqjhWDU83OgzAYjwsCV8Lo/N+oRsNDmx/ZDpqalmrtgOMkHwxsG0iI//3BwWAErYRHtgn0dZw== + dependencies: + "@webassemblyjs/ast" "1.14.1" + "@webassemblyjs/helper-buffer" "1.14.1" + "@webassemblyjs/helper-wasm-bytecode" "1.13.2" + "@webassemblyjs/wasm-gen" "1.14.1" + +"@webassemblyjs/ieee754@1.13.2": + version "1.13.2" + resolved "https://registry.yarnpkg.com/@webassemblyjs/ieee754/-/ieee754-1.13.2.tgz#1c5eaace1d606ada2c7fd7045ea9356c59ee0dba" + integrity sha512-4LtOzh58S/5lX4ITKxnAK2USuNEvpdVV9AlgGQb8rJDHaLeHciwG4zlGr0j/SNWlr7x3vO1lDEsuePvtcDNCkw== + dependencies: + "@xtuc/ieee754" "^1.2.0" + +"@webassemblyjs/leb128@1.13.2": + version "1.13.2" + resolved "https://registry.yarnpkg.com/@webassemblyjs/leb128/-/leb128-1.13.2.tgz#57c5c3deb0105d02ce25fa3fd74f4ebc9fd0bbb0" + integrity sha512-Lde1oNoIdzVzdkNEAWZ1dZ5orIbff80YPdHx20mrHwHrVNNTjNr8E3xz9BdpcGqRQbAEa+fkrCb+fRFTl/6sQw== + dependencies: + "@xtuc/long" "4.2.2" + +"@webassemblyjs/utf8@1.13.2": + version "1.13.2" + resolved "https://registry.yarnpkg.com/@webassemblyjs/utf8/-/utf8-1.13.2.tgz#917a20e93f71ad5602966c2d685ae0c6c21f60f1" + integrity sha512-3NQWGjKTASY1xV5m7Hr0iPeXD9+RDobLll3T9d2AO+g3my8xy5peVyjSag4I50mR1bBSN/Ct12lo+R9tJk0NZQ== + +"@webassemblyjs/wasm-edit@^1.14.1": + version "1.14.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-edit/-/wasm-edit-1.14.1.tgz#ac6689f502219b59198ddec42dcd496b1004d597" + integrity sha512-RNJUIQH/J8iA/1NzlE4N7KtyZNHi3w7at7hDjvRNm5rcUXa00z1vRz3glZoULfJ5mpvYhLybmVcwcjGrC1pRrQ== + dependencies: + "@webassemblyjs/ast" "1.14.1" + "@webassemblyjs/helper-buffer" "1.14.1" + "@webassemblyjs/helper-wasm-bytecode" "1.13.2" + "@webassemblyjs/helper-wasm-section" "1.14.1" + "@webassemblyjs/wasm-gen" "1.14.1" + "@webassemblyjs/wasm-opt" "1.14.1" + "@webassemblyjs/wasm-parser" "1.14.1" + "@webassemblyjs/wast-printer" "1.14.1" + +"@webassemblyjs/wasm-gen@1.14.1": + version "1.14.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-gen/-/wasm-gen-1.14.1.tgz#991e7f0c090cb0bb62bbac882076e3d219da9570" + integrity sha512-AmomSIjP8ZbfGQhumkNvgC33AY7qtMCXnN6bL2u2Js4gVCg8fp735aEiMSBbDR7UQIj90n4wKAFUSEd0QN2Ukg== + dependencies: + "@webassemblyjs/ast" "1.14.1" + "@webassemblyjs/helper-wasm-bytecode" "1.13.2" + "@webassemblyjs/ieee754" "1.13.2" + "@webassemblyjs/leb128" "1.13.2" + "@webassemblyjs/utf8" "1.13.2" + +"@webassemblyjs/wasm-opt@1.14.1": + version "1.14.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-opt/-/wasm-opt-1.14.1.tgz#e6f71ed7ccae46781c206017d3c14c50efa8106b" + integrity sha512-PTcKLUNvBqnY2U6E5bdOQcSM+oVP/PmrDY9NzowJjislEjwP/C4an2303MCVS2Mg9d3AJpIGdUFIQQWbPds0Sw== + dependencies: + "@webassemblyjs/ast" "1.14.1" + "@webassemblyjs/helper-buffer" "1.14.1" + "@webassemblyjs/wasm-gen" "1.14.1" + "@webassemblyjs/wasm-parser" "1.14.1" + +"@webassemblyjs/wasm-parser@1.14.1", "@webassemblyjs/wasm-parser@^1.14.1": + version "1.14.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-parser/-/wasm-parser-1.14.1.tgz#b3e13f1893605ca78b52c68e54cf6a865f90b9fb" + integrity sha512-JLBl+KZ0R5qB7mCnud/yyX08jWFw5MsoalJ1pQ4EdFlgj9VdXKGuENGsiCIjegI1W7p91rUlcB/LB5yRJKNTcQ== + dependencies: + "@webassemblyjs/ast" "1.14.1" + "@webassemblyjs/helper-api-error" "1.13.2" + "@webassemblyjs/helper-wasm-bytecode" "1.13.2" + "@webassemblyjs/ieee754" "1.13.2" + "@webassemblyjs/leb128" "1.13.2" + "@webassemblyjs/utf8" "1.13.2" + +"@webassemblyjs/wast-printer@1.14.1": + version "1.14.1" + resolved "https://registry.yarnpkg.com/@webassemblyjs/wast-printer/-/wast-printer-1.14.1.tgz#3bb3e9638a8ae5fdaf9610e7a06b4d9f9aa6fe07" + integrity sha512-kPSSXE6De1XOR820C90RIo2ogvZG+c3KiHzqUoO/F34Y2shGzesfqv7o57xrxovZJH/MetF5UjroJ/R/3isoiw== + dependencies: + "@webassemblyjs/ast" "1.14.1" + "@xtuc/long" "4.2.2" + +"@xtuc/ieee754@^1.2.0": + version "1.2.0" + resolved "https://registry.yarnpkg.com/@xtuc/ieee754/-/ieee754-1.2.0.tgz#eef014a3145ae477a1cbc00cd1e552336dceb790" + integrity sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA== + +"@xtuc/long@4.2.2": + version "4.2.2" + resolved "https://registry.yarnpkg.com/@xtuc/long/-/long-4.2.2.tgz#d291c6a4e97989b5c61d9acf396ae4fe133a718d" + integrity sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ== + +abab@^2.0.6: + version "2.0.6" + resolved "https://registry.yarnpkg.com/abab/-/abab-2.0.6.tgz#41b80f2c871d19686216b82309231cfd3cb3d291" + integrity sha512-j2afSsaIENvHZN2B8GOpF566vZ5WVk5opAiMTvWgaQT8DkbOqsTfvNAvHoRGU2zzP8cPoqys+xHTRDWW8L+/BA== + +abort-controller@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/abort-controller/-/abort-controller-3.0.0.tgz#eaf54d53b62bae4138e809ca225c8439a6efb392" + integrity sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg== + dependencies: + event-target-shim "^5.0.0" + +acorn-globals@^7.0.0: + version "7.0.1" + resolved "https://registry.yarnpkg.com/acorn-globals/-/acorn-globals-7.0.1.tgz#0dbf05c44fa7c94332914c02066d5beff62c40c3" + integrity sha512-umOSDSDrfHbTNPuNpC2NSnnA3LUrqpevPb4T9jRx4MagXNS0rs+gwiTcAvqCRmsD6utzsrzNt+ebm00SNWiC3Q== + dependencies: + acorn "^8.1.0" + acorn-walk "^8.0.2" + +acorn-walk@^8.0.2: + version "8.3.4" + resolved "https://registry.yarnpkg.com/acorn-walk/-/acorn-walk-8.3.4.tgz#794dd169c3977edf4ba4ea47583587c5866236b7" + integrity sha512-ueEepnujpqee2o5aIYnvHU6C0A42MNdsIDeqy5BydrkuC5R1ZuUFnm27EeFJGoEHJQgn3uleRvmTXaJgfXbt4g== + dependencies: + acorn "^8.11.0" + +acorn@^8.1.0, acorn@^8.11.0, acorn@^8.14.0, acorn@^8.8.1, acorn@^8.8.2: + version "8.14.0" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.14.0.tgz#063e2c70cac5fb4f6467f0b11152e04c682795b0" + integrity sha512-cl669nCJTZBsL97OF4kUQm5g5hC2uihk0NxY3WENAC0TYdILVkAyHymAntgxGkl7K+t0cXIrH5siy5S4XkFycA== + +agent-base@6: + version "6.0.2" + resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-6.0.2.tgz#49fff58577cfee3f37176feab4c22e00f86d7f77" + integrity sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ== + dependencies: + debug "4" + +ajv-formats@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/ajv-formats/-/ajv-formats-2.1.1.tgz#6e669400659eb74973bbf2e33327180a0996b520" + integrity sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA== + dependencies: + ajv "^8.0.0" + +ajv-keywords@^3.5.2: + version "3.5.2" + resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-3.5.2.tgz#31f29da5ab6e00d1c2d329acf7b5929614d5014d" + integrity sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ== + +ajv-keywords@^5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-5.1.0.tgz#69d4d385a4733cdbeab44964a1170a88f87f0e16" + integrity sha512-YCS/JNFAUyr5vAuhk1DWm1CBxRHW9LbJ2ozWeemrIqpbsqKjHVxYPyi5GC0rjZIT5JxJ3virVTS8wk4i/Z+krw== + dependencies: + fast-deep-equal "^3.1.3" + +ajv@^6.12.5: + version "6.12.6" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" + integrity sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g== + dependencies: + fast-deep-equal "^3.1.1" + fast-json-stable-stringify "^2.0.0" + json-schema-traverse "^0.4.1" + uri-js "^4.2.2" + +ajv@^8.0.0, ajv@^8.9.0: + version "8.17.1" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-8.17.1.tgz#37d9a5c776af6bc92d7f4f9510eba4c0a60d11a6" + integrity sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g== + dependencies: + fast-deep-equal "^3.1.3" + fast-uri "^3.0.1" + json-schema-traverse "^1.0.0" + require-from-string "^2.0.2" + +ansi-escapes@^4.2.1: + version "4.3.2" + resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-4.3.2.tgz#6b2291d1db7d98b6521d5f1efa42d0f3a9feb65e" + integrity sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ== + dependencies: + type-fest "^0.21.3" + +ansi-regex@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.1.tgz#082cb2c89c9fe8659a311a53bd6a4dc5301db304" + integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== + +ansi-styles@^4.0.0, ansi-styles@^4.1.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" + integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== + dependencies: + color-convert "^2.0.1" + +ansi-styles@^5.0.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-5.2.0.tgz#07449690ad45777d1924ac2abb2fc8895dba836b" + integrity sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA== + +anymatch@^3.0.3: + version "3.1.3" + resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-3.1.3.tgz#790c58b19ba1720a84205b57c618d5ad8524973e" + integrity sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw== + dependencies: + normalize-path "^3.0.0" + picomatch "^2.0.4" + +argparse@^1.0.7: + version "1.0.10" + resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.10.tgz#bcd6791ea5ae09725e17e5ad988134cd40b3d911" + integrity sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg== + dependencies: + sprintf-js "~1.0.2" + +asynckit@^0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" + integrity sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q== + +babel-jest@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-29.7.0.tgz#f4369919225b684c56085998ac63dbd05be020d5" + integrity sha512-BrvGY3xZSwEcCzKvKsCi2GgHqDqsYkOP4/by5xCgIwGXQxIEh+8ew3gmrE1y7XRR6LHZIj6yLYnUi/mm2KXKBg== + dependencies: + "@jest/transform" "^29.7.0" + "@types/babel__core" "^7.1.14" + babel-plugin-istanbul "^6.1.1" + babel-preset-jest "^29.6.3" + chalk "^4.0.0" + graceful-fs "^4.2.9" + slash "^3.0.0" + +babel-plugin-istanbul@^6.1.1: + version "6.1.1" + resolved "https://registry.yarnpkg.com/babel-plugin-istanbul/-/babel-plugin-istanbul-6.1.1.tgz#fa88ec59232fd9b4e36dbbc540a8ec9a9b47da73" + integrity sha512-Y1IQok9821cC9onCx5otgFfRm7Lm+I+wwxOx738M/WLPZ9Q42m4IG5W0FNX8WLL2gYMZo3JkuXIH2DOpWM+qwA== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + "@istanbuljs/load-nyc-config" "^1.0.0" + "@istanbuljs/schema" "^0.1.2" + istanbul-lib-instrument "^5.0.4" + test-exclude "^6.0.0" + +babel-plugin-jest-hoist@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-29.6.3.tgz#aadbe943464182a8922c3c927c3067ff40d24626" + integrity sha512-ESAc/RJvGTFEzRwOTT4+lNDk/GNHMkKbNzsvT0qKRfDyyYTskxB5rnU2njIDYVxXCBHHEI1c0YwHob3WaYujOg== + dependencies: + "@babel/template" "^7.3.3" + "@babel/types" "^7.3.3" + "@types/babel__core" "^7.1.14" + "@types/babel__traverse" "^7.0.6" + +babel-preset-current-node-syntax@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/babel-preset-current-node-syntax/-/babel-preset-current-node-syntax-1.1.0.tgz#9a929eafece419612ef4ae4f60b1862ebad8ef30" + integrity sha512-ldYss8SbBlWva1bs28q78Ju5Zq1F+8BrqBZZ0VFhLBvhh6lCpC2o3gDJi/5DRLs9FgYZCnmPYIVFU4lRXCkyUw== + dependencies: + "@babel/plugin-syntax-async-generators" "^7.8.4" + "@babel/plugin-syntax-bigint" "^7.8.3" + "@babel/plugin-syntax-class-properties" "^7.12.13" + "@babel/plugin-syntax-class-static-block" "^7.14.5" + "@babel/plugin-syntax-import-attributes" "^7.24.7" + "@babel/plugin-syntax-import-meta" "^7.10.4" + "@babel/plugin-syntax-json-strings" "^7.8.3" + "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" + "@babel/plugin-syntax-numeric-separator" "^7.10.4" + "@babel/plugin-syntax-object-rest-spread" "^7.8.3" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" + "@babel/plugin-syntax-optional-chaining" "^7.8.3" + "@babel/plugin-syntax-private-property-in-object" "^7.14.5" + "@babel/plugin-syntax-top-level-await" "^7.14.5" + +babel-preset-jest@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/babel-preset-jest/-/babel-preset-jest-29.6.3.tgz#fa05fa510e7d493896d7b0dd2033601c840f171c" + integrity sha512-0B3bhxR6snWXJZtR/RliHTDPRgn1sNHOR0yVtq/IiQFyuOVjFS+wuio/R4gSNkyYmKmJB4wGZv2NZanmKmTnNA== + dependencies: + babel-plugin-jest-hoist "^29.6.3" + babel-preset-current-node-syntax "^1.0.0" + +balanced-match@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" + integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== + +base64-js@^1.3.1: + version "1.5.1" + resolved "https://registry.yarnpkg.com/base64-js/-/base64-js-1.5.1.tgz#1b1b440160a5bf7ad40b650f095963481903930a" + integrity sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA== + +brace-expansion@^1.1.7: + version "1.1.11" + resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd" + integrity sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA== + dependencies: + balanced-match "^1.0.0" + concat-map "0.0.1" + +braces@^3.0.3: + version "3.0.3" + resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.3.tgz#490332f40919452272d55a8480adc0c441358789" + integrity sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA== + dependencies: + fill-range "^7.1.1" + +browserslist@^4.24.0: + version "4.24.3" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.24.3.tgz#5fc2725ca8fb3c1432e13dac278c7cc103e026d2" + integrity sha512-1CPmv8iobE2fyRMV97dAcMVegvvWKxmq94hkLiAkUGwKVTyDLw33K+ZxiFrREKmmps4rIw6grcCFCnTMSZ/YiA== + dependencies: + caniuse-lite "^1.0.30001688" + electron-to-chromium "^1.5.73" + node-releases "^2.0.19" + update-browserslist-db "^1.1.1" + +bs-logger@0.x: + version "0.2.6" + resolved "https://registry.yarnpkg.com/bs-logger/-/bs-logger-0.2.6.tgz#eb7d365307a72cf974cc6cda76b68354ad336bd8" + integrity sha512-pd8DCoxmbgc7hyPKOvxtqNcjYoOsABPQdcCUjGp3d42VR2CX1ORhk2A87oqqu5R1kk+76nsxZupkmyd+MVtCog== + dependencies: + fast-json-stable-stringify "2.x" + +bser@2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/bser/-/bser-2.1.1.tgz#e6787da20ece9d07998533cfd9de6f5c38f4bc05" + integrity sha512-gQxTNE/GAfIIrmHLUE3oJyp5FO6HRBfhjnw4/wMmA63ZGDJnWBmgY/lyQBpnDUkGmAhbSe39tx2d/iTOAfglwQ== + dependencies: + node-int64 "^0.4.0" + +buffer-from@^1.0.0: + version "1.1.2" + resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.2.tgz#2b146a6fd72e80b4f55d255f35ed59a3a9a41bd5" + integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== + +buffer@^6.0.3: + version "6.0.3" + resolved "https://registry.yarnpkg.com/buffer/-/buffer-6.0.3.tgz#2ace578459cc8fbe2a70aaa8f52ee63b6a74c6c6" + integrity sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA== + dependencies: + base64-js "^1.3.1" + ieee754 "^1.2.1" + +call-bind-apply-helpers@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.1.tgz#32e5892e6361b29b0b545ba6f7763378daca2840" + integrity sha512-BhYE+WDaywFg2TBWYNXAE+8B1ATnThNBqXHP5nQu0jWJdVvY2hvkpyB3qOmtmDePiS5/BDQ8wASEWGMWRG148g== + dependencies: + es-errors "^1.3.0" + function-bind "^1.1.2" + +call-bound@^1.0.2: + version "1.0.3" + resolved "https://registry.yarnpkg.com/call-bound/-/call-bound-1.0.3.tgz#41cfd032b593e39176a71533ab4f384aa04fd681" + integrity sha512-YTd+6wGlNlPxSuri7Y6X8tY2dmm12UMH66RpKMhiX6rsk5wXXnYgbUcOt8kiS31/AjfoTOvCsE+w8nZQLQnzHA== + dependencies: + call-bind-apply-helpers "^1.0.1" + get-intrinsic "^1.2.6" + +callsites@^3.0.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" + integrity sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ== + +camelcase@^5.3.1: + version "5.3.1" + resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.3.1.tgz#e3c9b31569e106811df242f715725a1f4c494320" + integrity sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg== + +camelcase@^6.2.0: + version "6.3.0" + resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-6.3.0.tgz#5685b95eb209ac9c0c177467778c9c84df58ba9a" + integrity sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA== + +caniuse-lite@^1.0.30001688: + version "1.0.30001690" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001690.tgz#f2d15e3aaf8e18f76b2b8c1481abde063b8104c8" + integrity sha512-5ExiE3qQN6oF8Clf8ifIDcMRCRE/dMGcETG/XGMD8/XiXm6HXQgQTh1yZYLXXpSOsEUlJm1Xr7kGULZTuGtP/w== + +chalk@^4.0.0, chalk@^4.1.0: + version "4.1.2" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" + integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== + dependencies: + ansi-styles "^4.1.0" + supports-color "^7.1.0" + +char-regex@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/char-regex/-/char-regex-1.0.2.tgz#d744358226217f981ed58f479b1d6bcc29545dcf" + integrity sha512-kWWXztvZ5SBQV+eRgKFeh8q5sLuZY2+8WUIzlxWVTg+oGwY14qylx1KbKzHd8P6ZYkAg0xyIDU9JMHhyJMZ1jw== + +chrome-trace-event@^1.0.2: + version "1.0.4" + resolved "https://registry.yarnpkg.com/chrome-trace-event/-/chrome-trace-event-1.0.4.tgz#05bffd7ff928465093314708c93bdfa9bd1f0f5b" + integrity sha512-rNjApaLzuwaOTjCiT8lSDdGN1APCiqkChLMJxJPWLunPAt5fy8xgU9/jNOchV84wfIxrA0lRQB7oCT8jrn/wrQ== + +ci-info@^3.2.0: + version "3.9.0" + resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-3.9.0.tgz#4279a62028a7b1f262f3473fc9605f5e218c59b4" + integrity sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ== + +cjs-module-lexer@^1.0.0: + version "1.4.1" + resolved "https://registry.yarnpkg.com/cjs-module-lexer/-/cjs-module-lexer-1.4.1.tgz#707413784dbb3a72aa11c2f2b042a0bef4004170" + integrity sha512-cuSVIHi9/9E/+821Qjdvngor+xpnlwnuwIyZOaLmHBVdXL+gP+I6QQB9VkO7RI77YIcTV+S1W9AreJ5eN63JBA== + +cliui@^8.0.1: + version "8.0.1" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-8.0.1.tgz#0c04b075db02cbfe60dc8e6cf2f5486b1a3608aa" + integrity sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ== + dependencies: + string-width "^4.2.0" + strip-ansi "^6.0.1" + wrap-ansi "^7.0.0" + +co@^4.6.0: + version "4.6.0" + resolved "https://registry.yarnpkg.com/co/-/co-4.6.0.tgz#6ea6bdf3d853ae54ccb8e47bfa0bf3f9031fb184" + integrity sha512-QVb0dM5HvG+uaxitm8wONl7jltx8dqhfU33DcqtOZcLSVIKSDDLDi7+0LbAKiyI8hD9u42m2YxXSkMGWThaecQ== + +collect-v8-coverage@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/collect-v8-coverage/-/collect-v8-coverage-1.0.2.tgz#c0b29bcd33bcd0779a1344c2136051e6afd3d9e9" + integrity sha512-lHl4d5/ONEbLlJvaJNtsF/Lz+WvB07u2ycqTYbdrq7UypDXailES4valYb2eWiJFxZlVmpGekfqoxQhzyFdT4Q== + +color-convert@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" + integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== + dependencies: + color-name "~1.1.4" + +color-name@~1.1.4: + version "1.1.4" + resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" + integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== + +combined-stream@^1.0.8: + version "1.0.8" + resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.8.tgz#c3d45a8b34fd730631a110a8a2520682b31d5a7f" + integrity sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg== + dependencies: + delayed-stream "~1.0.0" + +commander@^2.20.0: + version "2.20.3" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" + integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ== + +concat-map@0.0.1: + version "0.0.1" + resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" + integrity sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg== + +convert-source-map@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-2.0.0.tgz#4b560f649fc4e918dd0ab75cf4961e8bc882d82a" + integrity sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg== + +create-jest@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/create-jest/-/create-jest-29.7.0.tgz#a355c5b3cb1e1af02ba177fe7afd7feee49a5320" + integrity sha512-Adz2bdH0Vq3F53KEMJOoftQFutWCukm6J24wbPWRO4k1kMY7gS7ds/uoJkNuV8wDCtWWnuwGcJwpWcih+zEW1Q== + dependencies: + "@jest/types" "^29.6.3" + chalk "^4.0.0" + exit "^0.1.2" + graceful-fs "^4.2.9" + jest-config "^29.7.0" + jest-util "^29.7.0" + prompts "^2.0.1" + +cross-spawn@^7.0.3: + version "7.0.6" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.6.tgz#8a58fe78f00dcd70c370451759dfbfaf03e8ee9f" + integrity sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA== + dependencies: + path-key "^3.1.0" + shebang-command "^2.0.0" + which "^2.0.1" + +cssom@^0.5.0: + version "0.5.0" + resolved "https://registry.yarnpkg.com/cssom/-/cssom-0.5.0.tgz#d254fa92cd8b6fbd83811b9fbaed34663cc17c36" + integrity sha512-iKuQcq+NdHqlAcwUY0o/HL69XQrUaQdMjmStJ8JFmUaiiQErlhrmuigkg/CU4E2J0IyUKUrMAgl36TvN67MqTw== + +cssom@~0.3.6: + version "0.3.8" + resolved "https://registry.yarnpkg.com/cssom/-/cssom-0.3.8.tgz#9f1276f5b2b463f2114d3f2c75250af8c1a36f4a" + integrity sha512-b0tGHbfegbhPJpxpiBPU2sCkigAqtM9O121le6bbOlgyV+NyGyCmVfJ6QW9eRjz8CpNfWEOYBIMIGRYkLwsIYg== + +cssstyle@^2.3.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/cssstyle/-/cssstyle-2.3.0.tgz#ff665a0ddbdc31864b09647f34163443d90b0852" + integrity sha512-AZL67abkUzIuvcHqk7c09cezpGNcxUxU4Ioi/05xHk4DQeTkWmGYftIE6ctU6AEt+Gn4n1lDStOtj7FKycP71A== + dependencies: + cssom "~0.3.6" + +data-urls@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/data-urls/-/data-urls-3.0.2.tgz#9cf24a477ae22bcef5cd5f6f0bfbc1d2d3be9143" + integrity sha512-Jy/tj3ldjZJo63sVAvg6LHt2mHvl4V6AgRAmNDtLdm7faqtsx+aJG42rsyCo9JCoRVKwPFzKlIPx3DIibwSIaQ== + dependencies: + abab "^2.0.6" + whatwg-mimetype "^3.0.0" + whatwg-url "^11.0.0" + +debug@4, debug@^4.1.0, debug@^4.1.1, debug@^4.3.1: + version "4.4.0" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.4.0.tgz#2b3f2aea2ffeb776477460267377dc8710faba8a" + integrity sha512-6WTZ/IxCY/T6BALoZHaE4ctp9xm+Z5kY/pzYaCHRFeyVhojxlrm+46y68HA6hr0TcwEssoxNiDEUJQjfPZ/RYA== + dependencies: + ms "^2.1.3" + +decimal.js@^10.4.2: + version "10.4.3" + resolved "https://registry.yarnpkg.com/decimal.js/-/decimal.js-10.4.3.tgz#1044092884d245d1b7f65725fa4ad4c6f781cc23" + integrity sha512-VBBaLc1MgL5XpzgIP7ny5Z6Nx3UrRkIViUkPUdtl9aya5amy3De1gsUUSB1g3+3sExYNjCAsAznmukyxCb1GRA== + +dedent@^1.0.0: + version "1.5.3" + resolved "https://registry.yarnpkg.com/dedent/-/dedent-1.5.3.tgz#99aee19eb9bae55a67327717b6e848d0bf777e5a" + integrity sha512-NHQtfOOW68WD8lgypbLA5oT+Bt0xXJhiYvoR6SmmNXZfpzOGXwdKWmcwG8N7PwVVWV3eF/68nmD9BaJSsTBhyQ== + +deepmerge@^4.2.2: + version "4.3.1" + resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-4.3.1.tgz#44b5f2147cd3b00d4b56137685966f26fd25dd4a" + integrity sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A== + +delayed-stream@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" + integrity sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ== + +detect-newline@^3.0.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/detect-newline/-/detect-newline-3.1.0.tgz#576f5dfc63ae1a192ff192d8ad3af6308991b651" + integrity sha512-TLz+x/vEXm/Y7P7wn1EJFNLxYpUD4TgMosxY6fAVJUnJMbupHBOncxyWUG9OpTaH9EBD7uFI5LfEgmMOc54DsA== + +diff-sequences@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-29.6.3.tgz#4deaf894d11407c51efc8418012f9e70b84ea921" + integrity sha512-EjePK1srD3P08o2j4f0ExnylqRs5B9tJjcp9t1krH2qRi8CCdsYfwe9JgSLurFBWwq4uOlipzfk5fHNvwFKr8Q== + +domexception@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/domexception/-/domexception-4.0.0.tgz#4ad1be56ccadc86fc76d033353999a8037d03673" + integrity sha512-A2is4PLG+eeSfoTMA95/s4pvAoSo2mKtiM5jlHkAVewmiO8ISFTFKZjH7UAM1Atli/OT/7JHOrJRJiMKUZKYBw== + dependencies: + webidl-conversions "^7.0.0" + +dunder-proto@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/dunder-proto/-/dunder-proto-1.0.1.tgz#d7ae667e1dc83482f8b70fd0f6eefc50da30f58a" + integrity sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A== + dependencies: + call-bind-apply-helpers "^1.0.1" + es-errors "^1.3.0" + gopd "^1.2.0" + +electron-to-chromium@^1.5.73: + version "1.5.75" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.75.tgz#bba96eabf0e8ca36324679caa38b982800acc87d" + integrity sha512-Lf3++DumRE/QmweGjU+ZcKqQ+3bKkU/qjaKYhIJKEOhgIO9Xs6IiAQFkfFoj+RhgDk4LUeNsLo6plExHqSyu6Q== + +emittery@^0.13.1: + version "0.13.1" + resolved "https://registry.yarnpkg.com/emittery/-/emittery-0.13.1.tgz#c04b8c3457490e0847ae51fced3af52d338e3dad" + integrity sha512-DeWwawk6r5yR9jFgnDKYt4sLS0LmHJJi3ZOnb5/JdbYwj3nW+FxQnHIjhBKz8YLC7oRNPVM9NQ47I3CVx34eqQ== + +emoji-regex@^8.0.0: + version "8.0.0" + resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" + integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== + +enhanced-resolve@^5.0.0, enhanced-resolve@^5.17.1: + version "5.18.0" + resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-5.18.0.tgz#91eb1db193896b9801251eeff1c6980278b1e404" + integrity sha512-0/r0MySGYG8YqlayBZ6MuCfECmHFdJ5qyPh8s8wa5Hnm6SaFLSK1VYCbj+NKp090Nm1caZhD+QTnmxO7esYGyQ== + dependencies: + graceful-fs "^4.2.4" + tapable "^2.2.0" + +entities@^4.5.0: + version "4.5.0" + resolved "https://registry.yarnpkg.com/entities/-/entities-4.5.0.tgz#5d268ea5e7113ec74c4d033b79ea5a35a488fb48" + integrity sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw== + +error-ex@^1.3.1: + version "1.3.2" + resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" + integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== + dependencies: + is-arrayish "^0.2.1" + +es-define-property@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/es-define-property/-/es-define-property-1.0.1.tgz#983eb2f9a6724e9303f61addf011c72e09e0b0fa" + integrity sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g== + +es-errors@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/es-errors/-/es-errors-1.3.0.tgz#05f75a25dab98e4fb1dcd5e1472c0546d5057c8f" + integrity sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw== + +es-module-lexer@^1.2.1: + version "1.5.4" + resolved "https://registry.yarnpkg.com/es-module-lexer/-/es-module-lexer-1.5.4.tgz#a8efec3a3da991e60efa6b633a7cad6ab8d26b78" + integrity sha512-MVNK56NiMrOwitFB7cqDwq0CQutbw+0BvLshJSse0MUNU+y1FC3bUS/AQg7oUng+/wKrrki7JfmwtVHkVfPLlw== + +es-object-atoms@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/es-object-atoms/-/es-object-atoms-1.0.0.tgz#ddb55cd47ac2e240701260bc2a8e31ecb643d941" + integrity sha512-MZ4iQ6JwHOBQjahnjwaC1ZtIBH+2ohjamzAO3oaHcXYup7qxjF2fixyH+Q71voWHeOkI2q/TnJao/KfXYIZWbw== + dependencies: + es-errors "^1.3.0" + +escalade@^3.1.1, escalade@^3.2.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.2.0.tgz#011a3f69856ba189dffa7dc8fcce99d2a87903e5" + integrity sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA== + +escape-string-regexp@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz#a30304e99daa32e23b2fd20f51babd07cffca344" + integrity sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w== + +escodegen@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-2.1.0.tgz#ba93bbb7a43986d29d6041f99f5262da773e2e17" + integrity sha512-2NlIDTwUWJN0mRPQOdtQBzbUHvdGY2P1VXSyU83Q3xKxM7WHX2Ql8dKq782Q9TgQUNOLEzEYu9bzLNj1q88I5w== + dependencies: + esprima "^4.0.1" + estraverse "^5.2.0" + esutils "^2.0.2" + optionalDependencies: + source-map "~0.6.1" + +eslint-scope@5.1.1: + version "5.1.1" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-5.1.1.tgz#e786e59a66cb92b3f6c1fb0d508aab174848f48c" + integrity sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw== + dependencies: + esrecurse "^4.3.0" + estraverse "^4.1.1" + +esprima@^4.0.0, esprima@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" + integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== + +esrecurse@^4.3.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.3.0.tgz#7ad7964d679abb28bee72cec63758b1c5d2c9921" + integrity sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag== + dependencies: + estraverse "^5.2.0" + +estraverse@^4.1.1: + version "4.3.0" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.3.0.tgz#398ad3f3c5a24948be7725e83d11a7de28cdbd1d" + integrity sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw== + +estraverse@^5.2.0: + version "5.3.0" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-5.3.0.tgz#2eea5290702f26ab8fe5370370ff86c965d21123" + integrity sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA== + +esutils@^2.0.2: + version "2.0.3" + resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.3.tgz#74d2eb4de0b8da1293711910d50775b9b710ef64" + integrity sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g== + +event-target-shim@^5.0.0: + version "5.0.1" + resolved "https://registry.yarnpkg.com/event-target-shim/-/event-target-shim-5.0.1.tgz#5d4d3ebdf9583d63a5333ce2deb7480ab2b05789" + integrity sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ== + +events@^3.2.0, events@^3.3.0: + version "3.3.0" + resolved "https://registry.yarnpkg.com/events/-/events-3.3.0.tgz#31a95ad0a924e2d2c419a813aeb2c4e878ea7400" + integrity sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q== + +execa@^5.0.0: + version "5.1.1" + resolved "https://registry.yarnpkg.com/execa/-/execa-5.1.1.tgz#f80ad9cbf4298f7bd1d4c9555c21e93741c411dd" + integrity sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg== + dependencies: + cross-spawn "^7.0.3" + get-stream "^6.0.0" + human-signals "^2.1.0" + is-stream "^2.0.0" + merge-stream "^2.0.0" + npm-run-path "^4.0.1" + onetime "^5.1.2" + signal-exit "^3.0.3" + strip-final-newline "^2.0.0" + +exit@^0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/exit/-/exit-0.1.2.tgz#0632638f8d877cc82107d30a0fff1a17cba1cd0c" + integrity sha512-Zk/eNKV2zbjpKzrsQ+n1G6poVbErQxJ0LBOJXaKZ1EViLzH+hrLu9cdXI4zw9dBQJslwBEpbQ2P1oS7nDxs6jQ== + +expect@^29.0.0, expect@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/expect/-/expect-29.7.0.tgz#578874590dcb3214514084c08115d8aee61e11bc" + integrity sha512-2Zks0hf1VLFYI1kbh0I5jP3KHHyCHpkfyHBzsSXRFgl/Bg9mWYfMW8oD+PdMPlEwy5HNsR9JutYy6pMeOh61nw== + dependencies: + "@jest/expect-utils" "^29.7.0" + jest-get-type "^29.6.3" + jest-matcher-utils "^29.7.0" + jest-message-util "^29.7.0" + jest-util "^29.7.0" + +fast-deep-equal@^3.1.1, fast-deep-equal@^3.1.3: + version "3.1.3" + resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" + integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== + +fast-json-stable-stringify@2.x, fast-json-stable-stringify@^2.0.0, fast-json-stable-stringify@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz#874bf69c6f404c2b5d99c481341399fd55892633" + integrity sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw== + +fast-uri@^3.0.1: + version "3.0.3" + resolved "https://registry.yarnpkg.com/fast-uri/-/fast-uri-3.0.3.tgz#892a1c91802d5d7860de728f18608a0573142241" + integrity sha512-aLrHthzCjH5He4Z2H9YZ+v6Ujb9ocRuW6ZzkJQOrTxleEijANq4v1TsaPaVG1PZcuurEzrLcWRyYBYXD5cEiaw== + +fb-watchman@^2.0.0: + version "2.0.2" + resolved "https://registry.yarnpkg.com/fb-watchman/-/fb-watchman-2.0.2.tgz#e9524ee6b5c77e9e5001af0f85f3adbb8623255c" + integrity sha512-p5161BqbuCaSnB8jIbzQHOlpgsPmK5rJVDfDKO91Axs5NC1uu3HRQm6wt9cd9/+GtQQIO53JdGXXoyDpTAsgYA== + dependencies: + bser "2.1.1" + +fill-range@^7.1.1: + version "7.1.1" + resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-7.1.1.tgz#44265d3cac07e3ea7dc247516380643754a05292" + integrity sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg== + dependencies: + to-regex-range "^5.0.1" + +find-up@^4.0.0, find-up@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/find-up/-/find-up-4.1.0.tgz#97afe7d6cdc0bc5928584b7c8d7b16e8a9aa5d19" + integrity sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw== + dependencies: + locate-path "^5.0.0" + path-exists "^4.0.0" + +form-data@^4.0.0: + version "4.0.1" + resolved "https://registry.yarnpkg.com/form-data/-/form-data-4.0.1.tgz#ba1076daaaa5bfd7e99c1a6cb02aa0a5cff90d48" + integrity sha512-tzN8e4TX8+kkxGPK8D5u0FNmjPUjw3lwC9lSLxxoB/+GtsJG91CO8bSWy73APlgAZzZbXEYZJuxjkHH2w+Ezhw== + dependencies: + asynckit "^0.4.0" + combined-stream "^1.0.8" + mime-types "^2.1.12" + +formdata-node@^6.0.3: + version "6.0.3" + resolved "https://registry.yarnpkg.com/formdata-node/-/formdata-node-6.0.3.tgz#48f8e2206ae2befded82af621ef015f08168dc6d" + integrity sha512-8e1++BCiTzUno9v5IZ2J6bv4RU+3UKDmqWUQD0MIMVCd9AdhWkO1gw57oo1mNEX1dMq2EGI+FbWz4B92pscSQg== + +fs.realpath@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" + integrity sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw== + +fsevents@^2.3.2: + version "2.3.3" + resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.3.tgz#cac6407785d03675a2a5e1a5305c697b347d90d6" + integrity sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw== + +function-bind@^1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.2.tgz#2c02d864d97f3ea6c8830c464cbd11ab6eab7a1c" + integrity sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA== + +gensync@^1.0.0-beta.2: + version "1.0.0-beta.2" + resolved "https://registry.yarnpkg.com/gensync/-/gensync-1.0.0-beta.2.tgz#32a6ee76c3d7f52d46b2b1ae5d93fea8580a25e0" + integrity sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg== + +get-caller-file@^2.0.5: + version "2.0.5" + resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" + integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== + +get-intrinsic@^1.2.5, get-intrinsic@^1.2.6: + version "1.2.6" + resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.2.6.tgz#43dd3dd0e7b49b82b2dfcad10dc824bf7fc265d5" + integrity sha512-qxsEs+9A+u85HhllWJJFicJfPDhRmjzoYdl64aMWW9yRIJmSyxdn8IEkuIM530/7T+lv0TIHd8L6Q/ra0tEoeA== + dependencies: + call-bind-apply-helpers "^1.0.1" + dunder-proto "^1.0.0" + es-define-property "^1.0.1" + es-errors "^1.3.0" + es-object-atoms "^1.0.0" + function-bind "^1.1.2" + gopd "^1.2.0" + has-symbols "^1.1.0" + hasown "^2.0.2" + math-intrinsics "^1.0.0" + +get-package-type@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/get-package-type/-/get-package-type-0.1.0.tgz#8de2d803cff44df3bc6c456e6668b36c3926e11a" + integrity sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q== + +get-stream@^6.0.0: + version "6.0.1" + resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-6.0.1.tgz#a262d8eef67aced57c2852ad6167526a43cbf7b7" + integrity sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg== + +glob-to-regexp@^0.4.1: + version "0.4.1" + resolved "https://registry.yarnpkg.com/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz#c75297087c851b9a578bd217dd59a92f59fe546e" + integrity sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw== + +glob@^7.1.3, glob@^7.1.4: + version "7.2.3" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.3.tgz#b8df0fb802bbfa8e89bd1d938b4e16578ed44f2b" + integrity sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q== + dependencies: + fs.realpath "^1.0.0" + inflight "^1.0.4" + inherits "2" + minimatch "^3.1.1" + once "^1.3.0" + path-is-absolute "^1.0.0" + +globals@^11.1.0: + version "11.12.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" + integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== + +gopd@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/gopd/-/gopd-1.2.0.tgz#89f56b8217bdbc8802bd299df6d7f1081d7e51a1" + integrity sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg== + +graceful-fs@^4.1.2, graceful-fs@^4.2.11, graceful-fs@^4.2.4, graceful-fs@^4.2.9: + version "4.2.11" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3" + integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== + +has-flag@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" + integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== + +has-symbols@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.1.0.tgz#fc9c6a783a084951d0b971fe1018de813707a338" + integrity sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ== + +hasown@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/hasown/-/hasown-2.0.2.tgz#003eaf91be7adc372e84ec59dc37252cedb80003" + integrity sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ== + dependencies: + function-bind "^1.1.2" + +html-encoding-sniffer@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/html-encoding-sniffer/-/html-encoding-sniffer-3.0.0.tgz#2cb1a8cf0db52414776e5b2a7a04d5dd98158de9" + integrity sha512-oWv4T4yJ52iKrufjnyZPkrN0CH3QnrUqdB6In1g5Fe1mia8GmF36gnfNySxoZtxD5+NmYw1EElVXiBk93UeskA== + dependencies: + whatwg-encoding "^2.0.0" + +html-escaper@^2.0.0: + version "2.0.2" + resolved "https://registry.yarnpkg.com/html-escaper/-/html-escaper-2.0.2.tgz#dfd60027da36a36dfcbe236262c00a5822681453" + integrity sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg== + +http-proxy-agent@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/http-proxy-agent/-/http-proxy-agent-5.0.0.tgz#5129800203520d434f142bc78ff3c170800f2b43" + integrity sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w== + dependencies: + "@tootallnate/once" "2" + agent-base "6" + debug "4" + +https-proxy-agent@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz#c59ef224a04fe8b754f3db0063a25ea30d0005d6" + integrity sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA== + dependencies: + agent-base "6" + debug "4" + +human-signals@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-2.1.0.tgz#dc91fcba42e4d06e4abaed33b3e7a3c02f514ea0" + integrity sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw== + +iconv-lite@0.6.3: + version "0.6.3" + resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.6.3.tgz#a52f80bf38da1952eb5c681790719871a1a72501" + integrity sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw== + dependencies: + safer-buffer ">= 2.1.2 < 3.0.0" + +ieee754@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.2.1.tgz#8eb7a10a63fff25d15a57b001586d177d1b0d352" + integrity sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA== + +import-local@^3.0.2: + version "3.2.0" + resolved "https://registry.yarnpkg.com/import-local/-/import-local-3.2.0.tgz#c3d5c745798c02a6f8b897726aba5100186ee260" + integrity sha512-2SPlun1JUPWoM6t3F0dw0FkCF/jWY8kttcY4f599GLTSjh2OCuuhdTkJQsEcZzBqbXZGKMK2OqW1oZsjtf/gQA== + dependencies: + pkg-dir "^4.2.0" + resolve-cwd "^3.0.0" + +imurmurhash@^0.1.4: + version "0.1.4" + resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" + integrity sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA== + +inflight@^1.0.4: + version "1.0.6" + resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" + integrity sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA== + dependencies: + once "^1.3.0" + wrappy "1" + +inherits@2: + version "2.0.4" + resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" + integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== + +is-arrayish@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" + integrity sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg== + +is-core-module@^2.16.0: + version "2.16.0" + resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.16.0.tgz#6c01ffdd5e33c49c1d2abfa93334a85cb56bd81c" + integrity sha512-urTSINYfAYgcbLb0yDQ6egFm6h3Mo1DcF9EkyXSRjjzdHbsulg01qhwWuXdOoUBuTkbQ80KDboXa0vFJ+BDH+g== + dependencies: + hasown "^2.0.2" + +is-fullwidth-code-point@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz#f116f8064fe90b3f7844a38997c0b75051269f1d" + integrity sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg== + +is-generator-fn@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/is-generator-fn/-/is-generator-fn-2.1.0.tgz#7d140adc389aaf3011a8f2a2a4cfa6faadffb118" + integrity sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ== + +is-number@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/is-number/-/is-number-7.0.0.tgz#7535345b896734d5f80c4d06c50955527a14f12b" + integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== + +is-potential-custom-element-name@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz#171ed6f19e3ac554394edf78caa05784a45bebb5" + integrity sha512-bCYeRA2rVibKZd+s2625gGnGF/t7DSqDs4dP7CrLA1m7jKWz6pps0LpYLJN8Q64HtmPKJ1hrN3nzPNKFEKOUiQ== + +is-stream@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.1.tgz#fac1e3d53b97ad5a9d0ae9cef2389f5810a5c077" + integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== + +isexe@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" + integrity sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw== + +istanbul-lib-coverage@^3.0.0, istanbul-lib-coverage@^3.2.0: + version "3.2.2" + resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.2.tgz#2d166c4b0644d43a39f04bf6c2edd1e585f31756" + integrity sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg== + +istanbul-lib-instrument@^5.0.4: + version "5.2.1" + resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-5.2.1.tgz#d10c8885c2125574e1c231cacadf955675e1ce3d" + integrity sha512-pzqtp31nLv/XFOzXGuvhCb8qhjmTVo5vjVk19XE4CRlSWz0KoeJ3bw9XsA7nOp9YBf4qHjwBxkDzKcME/J29Yg== + dependencies: + "@babel/core" "^7.12.3" + "@babel/parser" "^7.14.7" + "@istanbuljs/schema" "^0.1.2" + istanbul-lib-coverage "^3.2.0" + semver "^6.3.0" + +istanbul-lib-instrument@^6.0.0: + version "6.0.3" + resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-6.0.3.tgz#fa15401df6c15874bcb2105f773325d78c666765" + integrity sha512-Vtgk7L/R2JHyyGW07spoFlB8/lpjiOLTjMdms6AFMraYt3BaJauod/NGrfnVG/y4Ix1JEuMRPDPEj2ua+zz1/Q== + dependencies: + "@babel/core" "^7.23.9" + "@babel/parser" "^7.23.9" + "@istanbuljs/schema" "^0.1.3" + istanbul-lib-coverage "^3.2.0" + semver "^7.5.4" + +istanbul-lib-report@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/istanbul-lib-report/-/istanbul-lib-report-3.0.1.tgz#908305bac9a5bd175ac6a74489eafd0fc2445a7d" + integrity sha512-GCfE1mtsHGOELCU8e/Z7YWzpmybrx/+dSTfLrvY8qRmaY6zXTKWn6WQIjaAFw069icm6GVMNkgu0NzI4iPZUNw== + dependencies: + istanbul-lib-coverage "^3.0.0" + make-dir "^4.0.0" + supports-color "^7.1.0" + +istanbul-lib-source-maps@^4.0.0: + version "4.0.1" + resolved "https://registry.yarnpkg.com/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.1.tgz#895f3a709fcfba34c6de5a42939022f3e4358551" + integrity sha512-n3s8EwkdFIJCG3BPKBYvskgXGoy88ARzvegkitk60NxRdwltLOTaH7CUiMRXvwYorl0Q712iEjcWB+fK/MrWVw== + dependencies: + debug "^4.1.1" + istanbul-lib-coverage "^3.0.0" + source-map "^0.6.1" + +istanbul-reports@^3.1.3: + version "3.1.7" + resolved "https://registry.yarnpkg.com/istanbul-reports/-/istanbul-reports-3.1.7.tgz#daed12b9e1dca518e15c056e1e537e741280fa0b" + integrity sha512-BewmUXImeuRk2YY0PVbxgKAysvhRPUQE0h5QRM++nVWyubKGV0l8qQ5op8+B2DOmwSe63Jivj0BjkPQVf8fP5g== + dependencies: + html-escaper "^2.0.0" + istanbul-lib-report "^3.0.0" + +jest-changed-files@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-29.7.0.tgz#1c06d07e77c78e1585d020424dedc10d6e17ac3a" + integrity sha512-fEArFiwf1BpQ+4bXSprcDc3/x4HSzL4al2tozwVpDFpsxALjLYdyiIK4e5Vz66GQJIbXJ82+35PtysofptNX2w== + dependencies: + execa "^5.0.0" + jest-util "^29.7.0" + p-limit "^3.1.0" + +jest-circus@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-circus/-/jest-circus-29.7.0.tgz#b6817a45fcc835d8b16d5962d0c026473ee3668a" + integrity sha512-3E1nCMgipcTkCocFwM90XXQab9bS+GMsjdpmPrlelaxwD93Ad8iVEjX/vvHPdLPnFf+L40u+5+iutRdA1N9myw== + dependencies: + "@jest/environment" "^29.7.0" + "@jest/expect" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/node" "*" + chalk "^4.0.0" + co "^4.6.0" + dedent "^1.0.0" + is-generator-fn "^2.0.0" + jest-each "^29.7.0" + jest-matcher-utils "^29.7.0" + jest-message-util "^29.7.0" + jest-runtime "^29.7.0" + jest-snapshot "^29.7.0" + jest-util "^29.7.0" + p-limit "^3.1.0" + pretty-format "^29.7.0" + pure-rand "^6.0.0" + slash "^3.0.0" + stack-utils "^2.0.3" + +jest-cli@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-29.7.0.tgz#5592c940798e0cae677eec169264f2d839a37995" + integrity sha512-OVVobw2IubN/GSYsxETi+gOe7Ka59EFMR/twOU3Jb2GnKKeMGJB5SGUUrEz3SFVmJASUdZUzy83sLNNQ2gZslg== + dependencies: + "@jest/core" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/types" "^29.6.3" + chalk "^4.0.0" + create-jest "^29.7.0" + exit "^0.1.2" + import-local "^3.0.2" + jest-config "^29.7.0" + jest-util "^29.7.0" + jest-validate "^29.7.0" + yargs "^17.3.1" + +jest-config@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-29.7.0.tgz#bcbda8806dbcc01b1e316a46bb74085a84b0245f" + integrity sha512-uXbpfeQ7R6TZBqI3/TxCU4q4ttk3u0PJeC+E0zbfSoSjq6bJ7buBPxzQPL0ifrkY4DNu4JUdk0ImlBUYi840eQ== + dependencies: + "@babel/core" "^7.11.6" + "@jest/test-sequencer" "^29.7.0" + "@jest/types" "^29.6.3" + babel-jest "^29.7.0" + chalk "^4.0.0" + ci-info "^3.2.0" + deepmerge "^4.2.2" + glob "^7.1.3" + graceful-fs "^4.2.9" + jest-circus "^29.7.0" + jest-environment-node "^29.7.0" + jest-get-type "^29.6.3" + jest-regex-util "^29.6.3" + jest-resolve "^29.7.0" + jest-runner "^29.7.0" + jest-util "^29.7.0" + jest-validate "^29.7.0" + micromatch "^4.0.4" + parse-json "^5.2.0" + pretty-format "^29.7.0" + slash "^3.0.0" + strip-json-comments "^3.1.1" + +jest-diff@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-29.7.0.tgz#017934a66ebb7ecf6f205e84699be10afd70458a" + integrity sha512-LMIgiIrhigmPrs03JHpxUh2yISK3vLFPkAodPeo0+BuF7wA2FoQbkEg1u8gBYBThncu7e1oEDUfIXVuTqLRUjw== + dependencies: + chalk "^4.0.0" + diff-sequences "^29.6.3" + jest-get-type "^29.6.3" + pretty-format "^29.7.0" + +jest-docblock@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-29.7.0.tgz#8fddb6adc3cdc955c93e2a87f61cfd350d5d119a" + integrity sha512-q617Auw3A612guyaFgsbFeYpNP5t2aoUNLwBUbc/0kD1R4t9ixDbyFTHd1nok4epoVFpr7PmeWHrhvuV3XaJ4g== + dependencies: + detect-newline "^3.0.0" + +jest-each@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-29.7.0.tgz#162a9b3f2328bdd991beaabffbb74745e56577d1" + integrity sha512-gns+Er14+ZrEoC5fhOfYCY1LOHHr0TI+rQUHZS8Ttw2l7gl+80eHc/gFf2Ktkw0+SIACDTeWvpFcv3B04VembQ== + dependencies: + "@jest/types" "^29.6.3" + chalk "^4.0.0" + jest-get-type "^29.6.3" + jest-util "^29.7.0" + pretty-format "^29.7.0" + +jest-environment-jsdom@29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-29.7.0.tgz#d206fa3551933c3fd519e5dfdb58a0f5139a837f" + integrity sha512-k9iQbsf9OyOfdzWH8HDmrRT0gSIcX+FLNW7IQq94tFX0gynPwqDTW0Ho6iMVNjGz/nb+l/vW3dWM2bbLLpkbXA== + dependencies: + "@jest/environment" "^29.7.0" + "@jest/fake-timers" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/jsdom" "^20.0.0" + "@types/node" "*" + jest-mock "^29.7.0" + jest-util "^29.7.0" + jsdom "^20.0.0" + +jest-environment-node@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-29.7.0.tgz#0b93e111dda8ec120bc8300e6d1fb9576e164376" + integrity sha512-DOSwCRqXirTOyheM+4d5YZOrWcdu0LNZ87ewUoywbcb2XR4wKgqiG8vNeYwhjFMbEkfju7wx2GYH0P2gevGvFw== + dependencies: + "@jest/environment" "^29.7.0" + "@jest/fake-timers" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/node" "*" + jest-mock "^29.7.0" + jest-util "^29.7.0" + +jest-get-type@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-29.6.3.tgz#36f499fdcea197c1045a127319c0481723908fd1" + integrity sha512-zrteXnqYxfQh7l5FHyL38jL39di8H8rHoecLH3JNxH3BwOrBsNeabdap5e0I23lD4HHI8W5VFBZqG4Eaq5LNcw== + +jest-haste-map@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-29.7.0.tgz#3c2396524482f5a0506376e6c858c3bbcc17b104" + integrity sha512-fP8u2pyfqx0K1rGn1R9pyE0/KTn+G7PxktWidOBTqFPLYX0b9ksaMFkhK5vrS3DVun09pckLdlx90QthlW7AmA== + dependencies: + "@jest/types" "^29.6.3" + "@types/graceful-fs" "^4.1.3" + "@types/node" "*" + anymatch "^3.0.3" + fb-watchman "^2.0.0" + graceful-fs "^4.2.9" + jest-regex-util "^29.6.3" + jest-util "^29.7.0" + jest-worker "^29.7.0" + micromatch "^4.0.4" + walker "^1.0.8" + optionalDependencies: + fsevents "^2.3.2" + +jest-leak-detector@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-29.7.0.tgz#5b7ec0dadfdfec0ca383dc9aa016d36b5ea4c728" + integrity sha512-kYA8IJcSYtST2BY9I+SMC32nDpBT3J2NvWJx8+JCuCdl/CR1I4EKUJROiP8XtCcxqgTTBGJNdbB1A8XRKbTetw== + dependencies: + jest-get-type "^29.6.3" + pretty-format "^29.7.0" + +jest-matcher-utils@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-29.7.0.tgz#ae8fec79ff249fd592ce80e3ee474e83a6c44f12" + integrity sha512-sBkD+Xi9DtcChsI3L3u0+N0opgPYnCRPtGcQYrgXmR+hmt/fYfWAL0xRXYU8eWOdfuLgBe0YCW3AFtnRLagq/g== + dependencies: + chalk "^4.0.0" + jest-diff "^29.7.0" + jest-get-type "^29.6.3" + pretty-format "^29.7.0" + +jest-message-util@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-29.7.0.tgz#8bc392e204e95dfe7564abbe72a404e28e51f7f3" + integrity sha512-GBEV4GRADeP+qtB2+6u61stea8mGcOT4mCtrYISZwfu9/ISHFJ/5zOMXYbpBE9RsS5+Gb63DW4FgmnKJ79Kf6w== + dependencies: + "@babel/code-frame" "^7.12.13" + "@jest/types" "^29.6.3" + "@types/stack-utils" "^2.0.0" + chalk "^4.0.0" + graceful-fs "^4.2.9" + micromatch "^4.0.4" + pretty-format "^29.7.0" + slash "^3.0.0" + stack-utils "^2.0.3" + +jest-mock@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-29.7.0.tgz#4e836cf60e99c6fcfabe9f99d017f3fdd50a6347" + integrity sha512-ITOMZn+UkYS4ZFh83xYAOzWStloNzJFO2s8DWrE4lhtGD+AorgnbkiKERe4wQVBydIGPx059g6riW5Btp6Llnw== + dependencies: + "@jest/types" "^29.6.3" + "@types/node" "*" + jest-util "^29.7.0" + +jest-pnp-resolver@^1.2.2: + version "1.2.3" + resolved "https://registry.yarnpkg.com/jest-pnp-resolver/-/jest-pnp-resolver-1.2.3.tgz#930b1546164d4ad5937d5540e711d4d38d4cad2e" + integrity sha512-+3NpwQEnRoIBtx4fyhblQDPgJI0H1IEIkX7ShLUjPGA7TtUTvI1oiKi3SR4oBR0hQhQR80l4WAe5RrXBwWMA8w== + +jest-regex-util@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-29.6.3.tgz#4a556d9c776af68e1c5f48194f4d0327d24e8a52" + integrity sha512-KJJBsRCyyLNWCNBOvZyRDnAIfUiRJ8v+hOBQYGn8gDyF3UegwiP4gwRR3/SDa42g1YbVycTidUF3rKjyLFDWbg== + +jest-resolve-dependencies@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-29.7.0.tgz#1b04f2c095f37fc776ff40803dc92921b1e88428" + integrity sha512-un0zD/6qxJ+S0et7WxeI3H5XSe9lTBBR7bOHCHXkKR6luG5mwDDlIzVQ0V5cZCuoTgEdcdwzTghYkTWfubi+nA== + dependencies: + jest-regex-util "^29.6.3" + jest-snapshot "^29.7.0" + +jest-resolve@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-29.7.0.tgz#64d6a8992dd26f635ab0c01e5eef4399c6bcbc30" + integrity sha512-IOVhZSrg+UvVAshDSDtHyFCCBUl/Q3AAJv8iZ6ZjnZ74xzvwuzLXid9IIIPgTnY62SJjfuupMKZsZQRsCvxEgA== + dependencies: + chalk "^4.0.0" + graceful-fs "^4.2.9" + jest-haste-map "^29.7.0" + jest-pnp-resolver "^1.2.2" + jest-util "^29.7.0" + jest-validate "^29.7.0" + resolve "^1.20.0" + resolve.exports "^2.0.0" + slash "^3.0.0" + +jest-runner@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-29.7.0.tgz#809af072d408a53dcfd2e849a4c976d3132f718e" + integrity sha512-fsc4N6cPCAahybGBfTRcq5wFR6fpLznMg47sY5aDpsoejOcVYFb07AHuSnR0liMcPTgBsA3ZJL6kFOjPdoNipQ== + dependencies: + "@jest/console" "^29.7.0" + "@jest/environment" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/node" "*" + chalk "^4.0.0" + emittery "^0.13.1" + graceful-fs "^4.2.9" + jest-docblock "^29.7.0" + jest-environment-node "^29.7.0" + jest-haste-map "^29.7.0" + jest-leak-detector "^29.7.0" + jest-message-util "^29.7.0" + jest-resolve "^29.7.0" + jest-runtime "^29.7.0" + jest-util "^29.7.0" + jest-watcher "^29.7.0" + jest-worker "^29.7.0" + p-limit "^3.1.0" + source-map-support "0.5.13" + +jest-runtime@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-29.7.0.tgz#efecb3141cf7d3767a3a0cc8f7c9990587d3d817" + integrity sha512-gUnLjgwdGqW7B4LvOIkbKs9WGbn+QLqRQQ9juC6HndeDiezIwhDP+mhMwHWCEcfQ5RUXa6OPnFF8BJh5xegwwQ== + dependencies: + "@jest/environment" "^29.7.0" + "@jest/fake-timers" "^29.7.0" + "@jest/globals" "^29.7.0" + "@jest/source-map" "^29.6.3" + "@jest/test-result" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/node" "*" + chalk "^4.0.0" + cjs-module-lexer "^1.0.0" + collect-v8-coverage "^1.0.0" + glob "^7.1.3" + graceful-fs "^4.2.9" + jest-haste-map "^29.7.0" + jest-message-util "^29.7.0" + jest-mock "^29.7.0" + jest-regex-util "^29.6.3" + jest-resolve "^29.7.0" + jest-snapshot "^29.7.0" + jest-util "^29.7.0" + slash "^3.0.0" + strip-bom "^4.0.0" + +jest-snapshot@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-29.7.0.tgz#c2c574c3f51865da1bb329036778a69bf88a6be5" + integrity sha512-Rm0BMWtxBcioHr1/OX5YCP8Uov4riHvKPknOGs804Zg9JGZgmIBkbtlxJC/7Z4msKYVbIJtfU+tKb8xlYNfdkw== + dependencies: + "@babel/core" "^7.11.6" + "@babel/generator" "^7.7.2" + "@babel/plugin-syntax-jsx" "^7.7.2" + "@babel/plugin-syntax-typescript" "^7.7.2" + "@babel/types" "^7.3.3" + "@jest/expect-utils" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" + babel-preset-current-node-syntax "^1.0.0" + chalk "^4.0.0" + expect "^29.7.0" + graceful-fs "^4.2.9" + jest-diff "^29.7.0" + jest-get-type "^29.6.3" + jest-matcher-utils "^29.7.0" + jest-message-util "^29.7.0" + jest-util "^29.7.0" + natural-compare "^1.4.0" + pretty-format "^29.7.0" + semver "^7.5.3" + +jest-util@^29.0.0, jest-util@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-29.7.0.tgz#23c2b62bfb22be82b44de98055802ff3710fc0bc" + integrity sha512-z6EbKajIpqGKU56y5KBUgy1dt1ihhQJgWzUlZHArA/+X2ad7Cb5iF+AK1EWVL/Bo7Rz9uurpqw6SiBCefUbCGA== + dependencies: + "@jest/types" "^29.6.3" + "@types/node" "*" + chalk "^4.0.0" + ci-info "^3.2.0" + graceful-fs "^4.2.9" + picomatch "^2.2.3" + +jest-validate@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-29.7.0.tgz#7bf705511c64da591d46b15fce41400d52147d9c" + integrity sha512-ZB7wHqaRGVw/9hST/OuFUReG7M8vKeq0/J2egIGLdvjHCmYqGARhzXmtgi+gVeZ5uXFF219aOc3Ls2yLg27tkw== + dependencies: + "@jest/types" "^29.6.3" + camelcase "^6.2.0" + chalk "^4.0.0" + jest-get-type "^29.6.3" + leven "^3.1.0" + pretty-format "^29.7.0" + +jest-watcher@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-watcher/-/jest-watcher-29.7.0.tgz#7810d30d619c3a62093223ce6bb359ca1b28a2f2" + integrity sha512-49Fg7WXkU3Vl2h6LbLtMQ/HyB6rXSIX7SqvBLQmssRBGN9I0PNvPmAmCWSOY6SOvrjhI/F7/bGAv9RtnsPA03g== + dependencies: + "@jest/test-result" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/node" "*" + ansi-escapes "^4.2.1" + chalk "^4.0.0" + emittery "^0.13.1" + jest-util "^29.7.0" + string-length "^4.0.1" + +jest-worker@^27.4.5: + version "27.5.1" + resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-27.5.1.tgz#8d146f0900e8973b106b6f73cc1e9a8cb86f8db0" + integrity sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg== + dependencies: + "@types/node" "*" + merge-stream "^2.0.0" + supports-color "^8.0.0" + +jest-worker@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-29.7.0.tgz#acad073acbbaeb7262bd5389e1bcf43e10058d4a" + integrity sha512-eIz2msL/EzL9UFTFFx7jBTkeZfku0yUAyZZZmJ93H2TYEiroIx2PQjEXcwYtYl8zXCxb+PAmA2hLIt/6ZEkPHw== + dependencies: + "@types/node" "*" + jest-util "^29.7.0" + merge-stream "^2.0.0" + supports-color "^8.0.0" + +jest@29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest/-/jest-29.7.0.tgz#994676fc24177f088f1c5e3737f5697204ff2613" + integrity sha512-NIy3oAFp9shda19hy4HK0HRTWKtPJmGdnvywu01nOqNC2vZg+Z+fvJDxpMQA88eb2I9EcafcdjYgsDthnYTvGw== + dependencies: + "@jest/core" "^29.7.0" + "@jest/types" "^29.6.3" + import-local "^3.0.2" + jest-cli "^29.7.0" + +js-base64@3.7.2: + version "3.7.2" + resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-3.7.2.tgz#816d11d81a8aff241603d19ce5761e13e41d7745" + integrity sha512-NnRs6dsyqUXejqk/yv2aiXlAvOs56sLkX6nUdeaNezI5LFFLlsZjOThmwnrcwh5ZZRwZlCMnVAY3CvhIhoVEKQ== + +js-tokens@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" + integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== + +js-yaml@^3.13.1: + version "3.14.1" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.14.1.tgz#dae812fdb3825fa306609a8717383c50c36a0537" + integrity sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g== + dependencies: + argparse "^1.0.7" + esprima "^4.0.0" + +jsdom@^20.0.0: + version "20.0.3" + resolved "https://registry.yarnpkg.com/jsdom/-/jsdom-20.0.3.tgz#886a41ba1d4726f67a8858028c99489fed6ad4db" + integrity sha512-SYhBvTh89tTfCD/CRdSOm13mOBa42iTaTyfyEWBdKcGdPxPtLFBXuHR8XHb33YNYaP+lLbmSvBTsnoesCNJEsQ== + dependencies: + abab "^2.0.6" + acorn "^8.8.1" + acorn-globals "^7.0.0" + cssom "^0.5.0" + cssstyle "^2.3.0" + data-urls "^3.0.2" + decimal.js "^10.4.2" + domexception "^4.0.0" + escodegen "^2.0.0" + form-data "^4.0.0" + html-encoding-sniffer "^3.0.0" + http-proxy-agent "^5.0.0" + https-proxy-agent "^5.0.1" + is-potential-custom-element-name "^1.0.1" + nwsapi "^2.2.2" + parse5 "^7.1.1" + saxes "^6.0.0" + symbol-tree "^3.2.4" + tough-cookie "^4.1.2" + w3c-xmlserializer "^4.0.0" + webidl-conversions "^7.0.0" + whatwg-encoding "^2.0.0" + whatwg-mimetype "^3.0.0" + whatwg-url "^11.0.0" + ws "^8.11.0" + xml-name-validator "^4.0.0" + +jsesc@^3.0.2: + version "3.1.0" + resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-3.1.0.tgz#74d335a234f67ed19907fdadfac7ccf9d409825d" + integrity sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA== + +json-parse-even-better-errors@^2.3.0, json-parse-even-better-errors@^2.3.1: + version "2.3.1" + resolved "https://registry.yarnpkg.com/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz#7c47805a94319928e05777405dc12e1f7a4ee02d" + integrity sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w== + +json-schema-traverse@^0.4.1: + version "0.4.1" + resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" + integrity sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg== + +json-schema-traverse@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz#ae7bcb3656ab77a73ba5c49bf654f38e6b6860e2" + integrity sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug== + +json5@^2.2.3: + version "2.2.3" + resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.3.tgz#78cd6f1a19bdc12b73db5ad0c61efd66c1e29283" + integrity sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg== + +kleur@^3.0.3: + version "3.0.3" + resolved "https://registry.yarnpkg.com/kleur/-/kleur-3.0.3.tgz#a79c9ecc86ee1ce3fa6206d1216c501f147fc07e" + integrity sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w== + +leven@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/leven/-/leven-3.1.0.tgz#77891de834064cccba82ae7842bb6b14a13ed7f2" + integrity sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A== + +lines-and-columns@^1.1.6: + version "1.2.4" + resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.2.4.tgz#eca284f75d2965079309dc0ad9255abb2ebc1632" + integrity sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg== + +loader-runner@^4.2.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/loader-runner/-/loader-runner-4.3.0.tgz#c1b4a163b99f614830353b16755e7149ac2314e1" + integrity sha512-3R/1M+yS3j5ou80Me59j7F9IMs4PXs3VqRrm0TU3AbKPxlmpoY1TNscJV/oGJXo8qCatFGTfDbY6W6ipGOYXfg== + +locate-path@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-5.0.0.tgz#1afba396afd676a6d42504d0a67a3a7eb9f62aa0" + integrity sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g== + dependencies: + p-locate "^4.1.0" + +lodash.memoize@4.x: + version "4.1.2" + resolved "https://registry.yarnpkg.com/lodash.memoize/-/lodash.memoize-4.1.2.tgz#bcc6c49a42a2840ed997f323eada5ecd182e0bfe" + integrity sha512-t7j+NzmgnQzTAYXcsHYLgimltOV1MXHtlOWf6GjL9Kj8GK5FInw5JotxvbOs+IvV1/Dzo04/fCGfLVs7aXb4Ag== + +lru-cache@^5.1.1: + version "5.1.1" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-5.1.1.tgz#1da27e6710271947695daf6848e847f01d84b920" + integrity sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w== + dependencies: + yallist "^3.0.2" + +make-dir@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-4.0.0.tgz#c3c2307a771277cd9638305f915c29ae741b614e" + integrity sha512-hXdUTZYIVOt1Ex//jAQi+wTZZpUpwBj/0QsOzqegb3rGMMeJiSEu5xLHnYfBrRV4RH2+OCSOO95Is/7x1WJ4bw== + dependencies: + semver "^7.5.3" + +make-error@1.x: + version "1.3.6" + resolved "https://registry.yarnpkg.com/make-error/-/make-error-1.3.6.tgz#2eb2e37ea9b67c4891f684a1394799af484cf7a2" + integrity sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw== + +makeerror@1.0.12: + version "1.0.12" + resolved "https://registry.yarnpkg.com/makeerror/-/makeerror-1.0.12.tgz#3e5dd2079a82e812e983cc6610c4a2cb0eaa801a" + integrity sha512-JmqCvUhmt43madlpFzG4BQzG2Z3m6tvQDNKdClZnO3VbIudJYmxsT0FNJMeiB2+JTSlTQTSbU8QdesVmwJcmLg== + dependencies: + tmpl "1.0.5" + +math-intrinsics@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/math-intrinsics/-/math-intrinsics-1.1.0.tgz#a0dd74be81e2aa5c2f27e65ce283605ee4e2b7f9" + integrity sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g== + +merge-stream@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-2.0.0.tgz#52823629a14dd00c9770fb6ad47dc6310f2c1f60" + integrity sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w== + +micromatch@^4.0.0, micromatch@^4.0.4: + version "4.0.8" + resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.8.tgz#d66fa18f3a47076789320b9b1af32bd86d9fa202" + integrity sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA== + dependencies: + braces "^3.0.3" + picomatch "^2.3.1" + +mime-db@1.52.0: + version "1.52.0" + resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.52.0.tgz#bbabcdc02859f4987301c856e3387ce5ec43bf70" + integrity sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg== + +mime-types@^2.1.12, mime-types@^2.1.27: + version "2.1.35" + resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.35.tgz#381a871b62a734450660ae3deee44813f70d959a" + integrity sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw== + dependencies: + mime-db "1.52.0" + +mimic-fn@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-2.1.0.tgz#7ed2c2ccccaf84d3ffcb7a69b57711fc2083401b" + integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== + +minimatch@^3.0.4, minimatch@^3.1.1: + version "3.1.2" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b" + integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== + dependencies: + brace-expansion "^1.1.7" + +ms@^2.1.3: + version "2.1.3" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" + integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== + +natural-compare@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" + integrity sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw== + +neo-async@^2.6.2: + version "2.6.2" + resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.2.tgz#b4aafb93e3aeb2d8174ca53cf163ab7d7308305f" + integrity sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw== + +node-fetch@2.7.0: + version "2.7.0" + resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.7.0.tgz#d0f0fa6e3e2dc1d27efcd8ad99d550bda94d187d" + integrity sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A== + dependencies: + whatwg-url "^5.0.0" + +node-int64@^0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/node-int64/-/node-int64-0.4.0.tgz#87a9065cdb355d3182d8f94ce11188b825c68a3b" + integrity sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw== + +node-releases@^2.0.19: + version "2.0.19" + resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-2.0.19.tgz#9e445a52950951ec4d177d843af370b411caf314" + integrity sha512-xxOWJsBKtzAq7DY0J+DTzuz58K8e7sJbdgwkbMWQe8UYB6ekmsQ45q0M/tJDsGaZmbC+l7n57UV8Hl5tHxO9uw== + +normalize-path@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" + integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== + +npm-run-path@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-4.0.1.tgz#b7ecd1e5ed53da8e37a55e1c2269e0b97ed748ea" + integrity sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw== + dependencies: + path-key "^3.0.0" + +nwsapi@^2.2.2: + version "2.2.16" + resolved "https://registry.yarnpkg.com/nwsapi/-/nwsapi-2.2.16.tgz#177760bba02c351df1d2644e220c31dfec8cdb43" + integrity sha512-F1I/bimDpj3ncaNDhfyMWuFqmQDBwDB0Fogc2qpL3BWvkQteFD/8BzWuIRl83rq0DXfm8SGt/HFhLXZyljTXcQ== + +object-inspect@^1.13.3: + version "1.13.3" + resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.13.3.tgz#f14c183de51130243d6d18ae149375ff50ea488a" + integrity sha512-kDCGIbxkDSXE3euJZZXzc6to7fCrKHNI/hSRQnRuQ+BWjFNzZwiFF8fj/6o2t2G9/jTj8PSIYTfCLelLZEeRpA== + +once@^1.3.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" + integrity sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w== + dependencies: + wrappy "1" + +onetime@^5.1.2: + version "5.1.2" + resolved "https://registry.yarnpkg.com/onetime/-/onetime-5.1.2.tgz#d0e96ebb56b07476df1dd9c4806e5237985ca45e" + integrity sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg== + dependencies: + mimic-fn "^2.1.0" + +p-limit@^2.2.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-2.3.0.tgz#3dd33c647a214fdfffd835933eb086da0dc21db1" + integrity sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w== + dependencies: + p-try "^2.0.0" + +p-limit@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-3.1.0.tgz#e1daccbe78d0d1388ca18c64fea38e3e57e3706b" + integrity sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ== + dependencies: + yocto-queue "^0.1.0" + +p-locate@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-4.1.0.tgz#a3428bb7088b3a60292f66919278b7c297ad4f07" + integrity sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A== + dependencies: + p-limit "^2.2.0" + +p-try@^2.0.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/p-try/-/p-try-2.2.0.tgz#cb2868540e313d61de58fafbe35ce9004d5540e6" + integrity sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ== + +parse-json@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-5.2.0.tgz#c76fc66dee54231c962b22bcc8a72cf2f99753cd" + integrity sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg== + dependencies: + "@babel/code-frame" "^7.0.0" + error-ex "^1.3.1" + json-parse-even-better-errors "^2.3.0" + lines-and-columns "^1.1.6" + +parse5@^7.0.0, parse5@^7.1.1: + version "7.2.1" + resolved "https://registry.yarnpkg.com/parse5/-/parse5-7.2.1.tgz#8928f55915e6125f430cc44309765bf17556a33a" + integrity sha512-BuBYQYlv1ckiPdQi/ohiivi9Sagc9JG+Ozs0r7b/0iK3sKmrb0b9FdWdBbOdx6hBCM/F9Ir82ofnBhtZOjCRPQ== + dependencies: + entities "^4.5.0" + +path-exists@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-4.0.0.tgz#513bdbe2d3b95d7762e8c1137efa195c6c61b5b3" + integrity sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w== + +path-is-absolute@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" + integrity sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg== + +path-key@^3.0.0, path-key@^3.1.0: + version "3.1.1" + resolved "https://registry.yarnpkg.com/path-key/-/path-key-3.1.1.tgz#581f6ade658cbba65a0d3380de7753295054f375" + integrity sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q== + +path-parse@^1.0.7: + version "1.0.7" + resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" + integrity sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw== + +picocolors@^1.0.0, picocolors@^1.1.0: + version "1.1.1" + resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.1.1.tgz#3d321af3eab939b083c8f929a1d12cda81c26b6b" + integrity sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA== + +picomatch@^2.0.4, picomatch@^2.2.3, picomatch@^2.3.1: + version "2.3.1" + resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" + integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== + +pirates@^4.0.4: + version "4.0.6" + resolved "https://registry.yarnpkg.com/pirates/-/pirates-4.0.6.tgz#3018ae32ecfcff6c29ba2267cbf21166ac1f36b9" + integrity sha512-saLsH7WeYYPiD25LDuLRRY/i+6HaPYr6G1OUlN39otzkSTxKnubR9RTxS3/Kk50s1g2JTgFwWQDQyplC5/SHZg== + +pkg-dir@^4.2.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-4.2.0.tgz#f099133df7ede422e81d1d8448270eeb3e4261f3" + integrity sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ== + dependencies: + find-up "^4.0.0" + +prettier@2.7.1: + version "2.7.1" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.7.1.tgz#e235806850d057f97bb08368a4f7d899f7760c64" + integrity sha512-ujppO+MkdPqoVINuDFDRLClm7D78qbDt0/NR+wp5FqEZOoTNAjPHWj17QRhu7geIHJfcNhRk1XVQmF8Bp3ye+g== + +pretty-format@^29.0.0, pretty-format@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-29.7.0.tgz#ca42c758310f365bfa71a0bda0a807160b776812" + integrity sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ== + dependencies: + "@jest/schemas" "^29.6.3" + ansi-styles "^5.0.0" + react-is "^18.0.0" + +process@^0.11.10: + version "0.11.10" + resolved "https://registry.yarnpkg.com/process/-/process-0.11.10.tgz#7332300e840161bda3e69a1d1d91a7d4bc16f182" + integrity sha512-cdGef/drWFoydD1JsMzuFf8100nZl+GT+yacc2bEced5f9Rjk4z+WtFUTBu9PhOi9j/jfmBPu0mMEY4wIdAF8A== + +prompts@^2.0.1: + version "2.4.2" + resolved "https://registry.yarnpkg.com/prompts/-/prompts-2.4.2.tgz#7b57e73b3a48029ad10ebd44f74b01722a4cb069" + integrity sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q== + dependencies: + kleur "^3.0.3" + sisteransi "^1.0.5" + +psl@^1.1.33: + version "1.15.0" + resolved "https://registry.yarnpkg.com/psl/-/psl-1.15.0.tgz#bdace31896f1d97cec6a79e8224898ce93d974c6" + integrity sha512-JZd3gMVBAVQkSs6HdNZo9Sdo0LNcQeMNP3CozBJb3JYC/QUYZTnKxP+f8oWRX4rHP5EurWxqAHTSwUCjlNKa1w== + dependencies: + punycode "^2.3.1" + +punycode@^2.1.0, punycode@^2.1.1, punycode@^2.3.1: + version "2.3.1" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.3.1.tgz#027422e2faec0b25e1549c3e1bd8309b9133b6e5" + integrity sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg== + +pure-rand@^6.0.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/pure-rand/-/pure-rand-6.1.0.tgz#d173cf23258231976ccbdb05247c9787957604f2" + integrity sha512-bVWawvoZoBYpp6yIoQtQXHZjmz35RSVHnUOTefl8Vcjr8snTPY1wnpSPMWekcFwbxI6gtmT7rSYPFvz71ldiOA== + +qs@6.11.2: + version "6.11.2" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.2.tgz#64bea51f12c1f5da1bc01496f48ffcff7c69d7d9" + integrity sha512-tDNIz22aBzCDxLtVH++VnTfzxlfeK5CbqohpSqpJgj1Wg/cQbStNAz3NuqCs5vV+pjBsK4x4pN9HlVh7rcYRiA== + dependencies: + side-channel "^1.0.4" + +querystringify@^2.1.1: + version "2.2.0" + resolved "https://registry.yarnpkg.com/querystringify/-/querystringify-2.2.0.tgz#3345941b4153cb9d082d8eee4cda2016a9aef7f6" + integrity sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ== + +randombytes@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/randombytes/-/randombytes-2.1.0.tgz#df6f84372f0270dc65cdf6291349ab7a473d4f2a" + integrity sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ== + dependencies: + safe-buffer "^5.1.0" + +react-is@^18.0.0: + version "18.3.1" + resolved "https://registry.yarnpkg.com/react-is/-/react-is-18.3.1.tgz#e83557dc12eae63a99e003a46388b1dcbb44db7e" + integrity sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg== + +readable-stream@^4.5.2: + version "4.6.0" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-4.6.0.tgz#ce412dfb19c04efde1c5936d99c27f37a1ff94c9" + integrity sha512-cbAdYt0VcnpN2Bekq7PU+k363ZRsPwJoEEJOEtSJQlJXzwaxt3FIo/uL+KeDSGIjJqtkwyge4KQgD2S2kd+CQw== + dependencies: + abort-controller "^3.0.0" + buffer "^6.0.3" + events "^3.3.0" + process "^0.11.10" + string_decoder "^1.3.0" + +require-directory@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" + integrity sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q== + +require-from-string@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/require-from-string/-/require-from-string-2.0.2.tgz#89a7fdd938261267318eafe14f9c32e598c36909" + integrity sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw== + +requires-port@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff" + integrity sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ== + +resolve-cwd@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/resolve-cwd/-/resolve-cwd-3.0.0.tgz#0f0075f1bb2544766cf73ba6a6e2adfebcb13f2d" + integrity sha512-OrZaX2Mb+rJCpH/6CpSqt9xFVpN++x01XnN2ie9g6P5/3xelLAkXWVADpdz1IHD/KFfEXyE6V0U01OQ3UO2rEg== + dependencies: + resolve-from "^5.0.0" + +resolve-from@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-5.0.0.tgz#c35225843df8f776df21c57557bc087e9dfdfc69" + integrity sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw== + +resolve.exports@^2.0.0: + version "2.0.3" + resolved "https://registry.yarnpkg.com/resolve.exports/-/resolve.exports-2.0.3.tgz#41955e6f1b4013b7586f873749a635dea07ebe3f" + integrity sha512-OcXjMsGdhL4XnbShKpAcSqPMzQoYkYyhbEaeSko47MjRP9NfEQMhZkXL1DoFlt9LWQn4YttrdnV6X2OiyzBi+A== + +resolve@^1.20.0: + version "1.22.10" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.10.tgz#b663e83ffb09bbf2386944736baae803029b8b39" + integrity sha512-NPRy+/ncIMeDlTAsuqwKIiferiawhefFJtkNSW0qZJEqMEb+qBt/77B/jGeeek+F0uOeN05CDa6HXbbIgtVX4w== + dependencies: + is-core-module "^2.16.0" + path-parse "^1.0.7" + supports-preserve-symlinks-flag "^1.0.0" + +safe-buffer@^5.1.0, safe-buffer@~5.2.0: + version "5.2.1" + resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" + integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== + +safe-buffer@~5.1.1: + version "5.1.2" + resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" + integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== + +"safer-buffer@>= 2.1.2 < 3.0.0": + version "2.1.2" + resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" + integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== + +saxes@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/saxes/-/saxes-6.0.0.tgz#fe5b4a4768df4f14a201b1ba6a65c1f3d9988cc5" + integrity sha512-xAg7SOnEhrm5zI3puOOKyy1OMcMlIJZYNJY7xLBwSze0UjhPLnWfj2GF2EpT0jmzaJKIWKHLsaSSajf35bcYnA== + dependencies: + xmlchars "^2.2.0" + +schema-utils@^3.2.0: + version "3.3.0" + resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-3.3.0.tgz#f50a88877c3c01652a15b622ae9e9795df7a60fe" + integrity sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg== + dependencies: + "@types/json-schema" "^7.0.8" + ajv "^6.12.5" + ajv-keywords "^3.5.2" + +schema-utils@^4.3.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-4.3.0.tgz#3b669f04f71ff2dfb5aba7ce2d5a9d79b35622c0" + integrity sha512-Gf9qqc58SpCA/xdziiHz35F4GNIWYWZrEshUc/G/r5BnLph6xpKuLeoJoQuj5WfBIx/eQLf+hmVPYHaxJu7V2g== + dependencies: + "@types/json-schema" "^7.0.9" + ajv "^8.9.0" + ajv-formats "^2.1.1" + ajv-keywords "^5.1.0" + +semver@^6.3.0, semver@^6.3.1: + version "6.3.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" + integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== + +semver@^7.3.4, semver@^7.5.3, semver@^7.5.4: + version "7.6.3" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.6.3.tgz#980f7b5550bc175fb4dc09403085627f9eb33143" + integrity sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A== + +serialize-javascript@^6.0.2: + version "6.0.2" + resolved "https://registry.yarnpkg.com/serialize-javascript/-/serialize-javascript-6.0.2.tgz#defa1e055c83bf6d59ea805d8da862254eb6a6c2" + integrity sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g== + dependencies: + randombytes "^2.1.0" + +shebang-command@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-2.0.0.tgz#ccd0af4f8835fbdc265b82461aaf0c36663f34ea" + integrity sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA== + dependencies: + shebang-regex "^3.0.0" + +shebang-regex@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172" + integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A== + +side-channel-list@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/side-channel-list/-/side-channel-list-1.0.0.tgz#10cb5984263115d3b7a0e336591e290a830af8ad" + integrity sha512-FCLHtRD/gnpCiCHEiJLOwdmFP+wzCmDEkc9y7NsYxeF4u7Btsn1ZuwgwJGxImImHicJArLP4R0yX4c2KCrMrTA== + dependencies: + es-errors "^1.3.0" + object-inspect "^1.13.3" + +side-channel-map@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/side-channel-map/-/side-channel-map-1.0.1.tgz#d6bb6b37902c6fef5174e5f533fab4c732a26f42" + integrity sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA== + dependencies: + call-bound "^1.0.2" + es-errors "^1.3.0" + get-intrinsic "^1.2.5" + object-inspect "^1.13.3" + +side-channel-weakmap@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/side-channel-weakmap/-/side-channel-weakmap-1.0.2.tgz#11dda19d5368e40ce9ec2bdc1fb0ecbc0790ecea" + integrity sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A== + dependencies: + call-bound "^1.0.2" + es-errors "^1.3.0" + get-intrinsic "^1.2.5" + object-inspect "^1.13.3" + side-channel-map "^1.0.1" + +side-channel@^1.0.4: + version "1.1.0" + resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.1.0.tgz#c3fcff9c4da932784873335ec9765fa94ff66bc9" + integrity sha512-ZX99e6tRweoUXqR+VBrslhda51Nh5MTQwou5tnUDgbtyM0dBgmhEDtWGP/xbKn6hqfPRHujUNwz5fy/wbbhnpw== + dependencies: + es-errors "^1.3.0" + object-inspect "^1.13.3" + side-channel-list "^1.0.0" + side-channel-map "^1.0.1" + side-channel-weakmap "^1.0.2" + +signal-exit@^3.0.3, signal-exit@^3.0.7: + version "3.0.7" + resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.7.tgz#a9a1767f8af84155114eaabd73f99273c8f59ad9" + integrity sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ== + +sisteransi@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/sisteransi/-/sisteransi-1.0.5.tgz#134d681297756437cc05ca01370d3a7a571075ed" + integrity sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg== + +slash@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/slash/-/slash-3.0.0.tgz#6539be870c165adbd5240220dbe361f1bc4d4634" + integrity sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q== + +source-map-support@0.5.13: + version "0.5.13" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.13.tgz#31b24a9c2e73c2de85066c0feb7d44767ed52932" + integrity sha512-SHSKFHadjVA5oR4PPqhtAVdcBWwRYVd6g6cAXnIbRiIwc2EhPrTuKUBdSLvlEKyIP3GCf89fltvcZiP9MMFA1w== + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + +source-map-support@~0.5.20: + version "0.5.21" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.21.tgz#04fe7c7f9e1ed2d662233c28cb2b35b9f63f6e4f" + integrity sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w== + dependencies: + buffer-from "^1.0.0" + source-map "^0.6.0" + +source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.1: + version "0.6.1" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" + integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== + +source-map@^0.7.4: + version "0.7.4" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.7.4.tgz#a9bbe705c9d8846f4e08ff6765acf0f1b0898656" + integrity sha512-l3BikUxvPOcn5E74dZiq5BGsTb5yEwhaTSzccU6t4sDOH8NWJCstKO5QT2CvtFoK6F0saL7p9xHAqHOlCPJygA== + +sprintf-js@~1.0.2: + version "1.0.3" + resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" + integrity sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g== + +stack-utils@^2.0.3: + version "2.0.6" + resolved "https://registry.yarnpkg.com/stack-utils/-/stack-utils-2.0.6.tgz#aaf0748169c02fc33c8232abccf933f54a1cc34f" + integrity sha512-XlkWvfIm6RmsWtNJx+uqtKLS8eqFbxUg0ZzLXqY0caEy9l7hruX8IpiDnjsLavoBgqCCR71TqWO8MaXYheJ3RQ== + dependencies: + escape-string-regexp "^2.0.0" + +string-length@^4.0.1: + version "4.0.2" + resolved "https://registry.yarnpkg.com/string-length/-/string-length-4.0.2.tgz#a8a8dc7bd5c1a82b9b3c8b87e125f66871b6e57a" + integrity sha512-+l6rNN5fYHNhZZy41RXsYptCjA2Igmq4EG7kZAYFQI1E1VTXarr6ZPXBg6eq7Y6eK4FEhY6AJlyuFIb/v/S0VQ== + dependencies: + char-regex "^1.0.2" + strip-ansi "^6.0.0" + +string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: + version "4.2.3" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" + integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== + dependencies: + emoji-regex "^8.0.0" + is-fullwidth-code-point "^3.0.0" + strip-ansi "^6.0.1" + +string_decoder@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.3.0.tgz#42f114594a46cf1a8e30b0a84f56c78c3edac21e" + integrity sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA== + dependencies: + safe-buffer "~5.2.0" + +strip-ansi@^6.0.0, strip-ansi@^6.0.1: + version "6.0.1" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" + integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== + dependencies: + ansi-regex "^5.0.1" + +strip-bom@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-4.0.0.tgz#9c3505c1db45bcedca3d9cf7a16f5c5aa3901878" + integrity sha512-3xurFv5tEgii33Zi8Jtp55wEIILR9eh34FAW00PZf+JnSsTmV/ioewSgQl97JHvgjoRGwPShsWm+IdrxB35d0w== + +strip-final-newline@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/strip-final-newline/-/strip-final-newline-2.0.0.tgz#89b852fb2fcbe936f6f4b3187afb0a12c1ab58ad" + integrity sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA== + +strip-json-comments@^3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" + integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== + +supports-color@^7.1.0: + version "7.2.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" + integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== + dependencies: + has-flag "^4.0.0" + +supports-color@^8.0.0: + version "8.1.1" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-8.1.1.tgz#cd6fc17e28500cff56c1b86c0a7fd4a54a73005c" + integrity sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q== + dependencies: + has-flag "^4.0.0" + +supports-preserve-symlinks-flag@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09" + integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w== + +symbol-tree@^3.2.4: + version "3.2.4" + resolved "https://registry.yarnpkg.com/symbol-tree/-/symbol-tree-3.2.4.tgz#430637d248ba77e078883951fb9aa0eed7c63fa2" + integrity sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw== + +tapable@^2.1.1, tapable@^2.2.0: + version "2.2.1" + resolved "https://registry.yarnpkg.com/tapable/-/tapable-2.2.1.tgz#1967a73ef4060a82f12ab96af86d52fdb76eeca0" + integrity sha512-GNzQvQTOIP6RyTfE2Qxb8ZVlNmw0n88vp1szwWRimP02mnTsx3Wtn5qRdqY9w2XduFNUgvOwhNnQsjwCp+kqaQ== + +terser-webpack-plugin@^5.3.10: + version "5.3.11" + resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-5.3.11.tgz#93c21f44ca86634257cac176f884f942b7ba3832" + integrity sha512-RVCsMfuD0+cTt3EwX8hSl2Ks56EbFHWmhluwcqoPKtBnfjiT6olaq7PRIRfhyU8nnC2MrnDrBLfrD/RGE+cVXQ== + dependencies: + "@jridgewell/trace-mapping" "^0.3.25" + jest-worker "^27.4.5" + schema-utils "^4.3.0" + serialize-javascript "^6.0.2" + terser "^5.31.1" + +terser@^5.31.1: + version "5.37.0" + resolved "https://registry.yarnpkg.com/terser/-/terser-5.37.0.tgz#38aa66d1cfc43d0638fab54e43ff8a4f72a21ba3" + integrity sha512-B8wRRkmre4ERucLM/uXx4MOV5cbnOlVAqUst+1+iLKPI0dOgFO28f84ptoQt9HEI537PMzfYa/d+GEPKTRXmYA== + dependencies: + "@jridgewell/source-map" "^0.3.3" + acorn "^8.8.2" + commander "^2.20.0" + source-map-support "~0.5.20" + +test-exclude@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/test-exclude/-/test-exclude-6.0.0.tgz#04a8698661d805ea6fa293b6cb9e63ac044ef15e" + integrity sha512-cAGWPIyOHU6zlmg88jwm7VRyXnMN7iV68OGAbYDk/Mh/xC/pzVPlQtY6ngoIH/5/tciuhGfvESU8GrHrcxD56w== + dependencies: + "@istanbuljs/schema" "^0.1.2" + glob "^7.1.4" + minimatch "^3.0.4" + +tmpl@1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/tmpl/-/tmpl-1.0.5.tgz#8683e0b902bb9c20c4f726e3c0b69f36518c07cc" + integrity sha512-3f0uOEAQwIqGuWW2MVzYg8fV/QNnc/IpuJNG837rLuczAaLVHslWHZQj4IGiEl5Hs3kkbhwL9Ab7Hrsmuj+Smw== + +to-regex-range@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-5.0.1.tgz#1648c44aae7c8d988a326018ed72f5b4dd0392e4" + integrity sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ== + dependencies: + is-number "^7.0.0" + +tough-cookie@^4.1.2: + version "4.1.4" + resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-4.1.4.tgz#945f1461b45b5a8c76821c33ea49c3ac192c1b36" + integrity sha512-Loo5UUvLD9ScZ6jh8beX1T6sO1w2/MpCRpEP7V280GKMVUQ0Jzar2U3UJPsrdbziLEMMhu3Ujnq//rhiFuIeag== + dependencies: + psl "^1.1.33" + punycode "^2.1.1" + universalify "^0.2.0" + url-parse "^1.5.3" + +tr46@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/tr46/-/tr46-3.0.0.tgz#555c4e297a950617e8eeddef633c87d4d9d6cbf9" + integrity sha512-l7FvfAHlcmulp8kr+flpQZmVwtu7nfRV7NZujtN0OqES8EL4O4e0qqzL0DC5gAvx/ZC/9lk6rhcUwYvkBnBnYA== + dependencies: + punycode "^2.1.1" + +tr46@~0.0.3: + version "0.0.3" + resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" + integrity sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw== + +ts-jest@29.1.1: + version "29.1.1" + resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-29.1.1.tgz#f58fe62c63caf7bfcc5cc6472082f79180f0815b" + integrity sha512-D6xjnnbP17cC85nliwGiL+tpoKN0StpgE0TeOjXQTU6MVCfsB4v7aW05CgQ/1OywGb0x/oy9hHFnN+sczTiRaA== + dependencies: + bs-logger "0.x" + fast-json-stable-stringify "2.x" + jest-util "^29.0.0" + json5 "^2.2.3" + lodash.memoize "4.x" + make-error "1.x" + semver "^7.5.3" + yargs-parser "^21.0.1" + +ts-loader@^9.3.1: + version "9.5.1" + resolved "https://registry.yarnpkg.com/ts-loader/-/ts-loader-9.5.1.tgz#63d5912a86312f1fbe32cef0859fb8b2193d9b89" + integrity sha512-rNH3sK9kGZcH9dYzC7CewQm4NtxJTjSEVRJ2DyBZR7f8/wcta+iV44UPCXc5+nzDzivKtlzV6c9P4e+oFhDLYg== + dependencies: + chalk "^4.1.0" + enhanced-resolve "^5.0.0" + micromatch "^4.0.0" + semver "^7.3.4" + source-map "^0.7.4" + +type-detect@4.0.8: + version "4.0.8" + resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c" + integrity sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g== + +type-fest@^0.21.3: + version "0.21.3" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.21.3.tgz#d260a24b0198436e133fa26a524a6d65fa3b2e37" + integrity sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w== + +typescript@4.6.4: + version "4.6.4" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.6.4.tgz#caa78bbc3a59e6a5c510d35703f6a09877ce45e9" + integrity sha512-9ia/jWHIEbo49HfjrLGfKbZSuWo9iTMwXO+Ca3pRsSpbsMbc7/IU8NKdCZVRRBafVPGnoJeFL76ZOAA84I9fEg== + +undici-types@~6.20.0: + version "6.20.0" + resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-6.20.0.tgz#8171bf22c1f588d1554d55bf204bc624af388433" + integrity sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg== + +universalify@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.2.0.tgz#6451760566fa857534745ab1dde952d1b1761be0" + integrity sha512-CJ1QgKmNg3CwvAv/kOFmtnEN05f0D/cn9QntgNOQlQF9dgvVTHj3t+8JPdjqawCHk7V/KA+fbUqzZ9XWhcqPUg== + +update-browserslist-db@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/update-browserslist-db/-/update-browserslist-db-1.1.1.tgz#80846fba1d79e82547fb661f8d141e0945755fe5" + integrity sha512-R8UzCaa9Az+38REPiJ1tXlImTJXlVfgHZsglwBD/k6nj76ctsH1E3q4doGrukiLQd3sGQYu56r5+lo5r94l29A== + dependencies: + escalade "^3.2.0" + picocolors "^1.1.0" + +uri-js@^4.2.2: + version "4.4.1" + resolved "https://registry.yarnpkg.com/uri-js/-/uri-js-4.4.1.tgz#9b1a52595225859e55f669d928f88c6c57f2a77e" + integrity sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg== + dependencies: + punycode "^2.1.0" + +url-join@4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/url-join/-/url-join-4.0.1.tgz#b642e21a2646808ffa178c4c5fda39844e12cde7" + integrity sha512-jk1+QP6ZJqyOiuEI9AEWQfju/nB2Pw466kbA0LEZljHwKeMgd9WrAEgEGxjPDD2+TNbbb37rTyhEfrCXfuKXnA== + +url-parse@^1.5.3: + version "1.5.10" + resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.10.tgz#9d3c2f736c1d75dd3bd2be507dcc111f1e2ea9c1" + integrity sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ== + dependencies: + querystringify "^2.1.1" + requires-port "^1.0.0" + +v8-to-istanbul@^9.0.1: + version "9.3.0" + resolved "https://registry.yarnpkg.com/v8-to-istanbul/-/v8-to-istanbul-9.3.0.tgz#b9572abfa62bd556c16d75fdebc1a411d5ff3175" + integrity sha512-kiGUalWN+rgBJ/1OHZsBtU4rXZOfj/7rKQxULKlIzwzQSvMJUUNgPwJEEh7gU6xEVxC0ahoOBvN2YI8GH6FNgA== + dependencies: + "@jridgewell/trace-mapping" "^0.3.12" + "@types/istanbul-lib-coverage" "^2.0.1" + convert-source-map "^2.0.0" + +w3c-xmlserializer@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/w3c-xmlserializer/-/w3c-xmlserializer-4.0.0.tgz#aebdc84920d806222936e3cdce408e32488a3073" + integrity sha512-d+BFHzbiCx6zGfz0HyQ6Rg69w9k19nviJspaj4yNscGjrHu94sVP+aRm75yEbCh+r2/yR+7q6hux9LVtbuTGBw== + dependencies: + xml-name-validator "^4.0.0" + +walker@^1.0.8: + version "1.0.8" + resolved "https://registry.yarnpkg.com/walker/-/walker-1.0.8.tgz#bd498db477afe573dc04185f011d3ab8a8d7653f" + integrity sha512-ts/8E8l5b7kY0vlWLewOkDXMmPdLcVV4GmOQLyxuSswIJsweeFZtAsMF7k1Nszz+TYBQrlYRmzOnr398y1JemQ== + dependencies: + makeerror "1.0.12" + +watchpack@^2.4.1: + version "2.4.2" + resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-2.4.2.tgz#2feeaed67412e7c33184e5a79ca738fbd38564da" + integrity sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw== + dependencies: + glob-to-regexp "^0.4.1" + graceful-fs "^4.1.2" + +webidl-conversions@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-3.0.1.tgz#24534275e2a7bc6be7bc86611cc16ae0a5654871" + integrity sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ== + +webidl-conversions@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-7.0.0.tgz#256b4e1882be7debbf01d05f0aa2039778ea080a" + integrity sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g== + +webpack-sources@^3.2.3: + version "3.2.3" + resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-3.2.3.tgz#2d4daab8451fd4b240cc27055ff6a0c2ccea0cde" + integrity sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w== + +webpack@^5.94.0: + version "5.97.1" + resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.97.1.tgz#972a8320a438b56ff0f1d94ade9e82eac155fa58" + integrity sha512-EksG6gFY3L1eFMROS/7Wzgrii5mBAFe4rIr3r2BTfo7bcc+DWwFZ4OJ/miOuHJO/A85HwyI4eQ0F6IKXesO7Fg== + dependencies: + "@types/eslint-scope" "^3.7.7" + "@types/estree" "^1.0.6" + "@webassemblyjs/ast" "^1.14.1" + "@webassemblyjs/wasm-edit" "^1.14.1" + "@webassemblyjs/wasm-parser" "^1.14.1" + acorn "^8.14.0" + browserslist "^4.24.0" + chrome-trace-event "^1.0.2" + enhanced-resolve "^5.17.1" + es-module-lexer "^1.2.1" + eslint-scope "5.1.1" + events "^3.2.0" + glob-to-regexp "^0.4.1" + graceful-fs "^4.2.11" + json-parse-even-better-errors "^2.3.1" + loader-runner "^4.2.0" + mime-types "^2.1.27" + neo-async "^2.6.2" + schema-utils "^3.2.0" + tapable "^2.1.1" + terser-webpack-plugin "^5.3.10" + watchpack "^2.4.1" + webpack-sources "^3.2.3" + +whatwg-encoding@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/whatwg-encoding/-/whatwg-encoding-2.0.0.tgz#e7635f597fd87020858626805a2729fa7698ac53" + integrity sha512-p41ogyeMUrw3jWclHWTQg1k05DSVXPLcVxRTYsXUk+ZooOCZLcoYgPZ/HL/D/N+uQPOtcp1me1WhBEaX02mhWg== + dependencies: + iconv-lite "0.6.3" + +whatwg-mimetype@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/whatwg-mimetype/-/whatwg-mimetype-3.0.0.tgz#5fa1a7623867ff1af6ca3dc72ad6b8a4208beba7" + integrity sha512-nt+N2dzIutVRxARx1nghPKGv1xHikU7HKdfafKkLNLindmPU/ch3U31NOCGGA/dmPcmb1VlofO0vnKAcsm0o/Q== + +whatwg-url@^11.0.0: + version "11.0.0" + resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-11.0.0.tgz#0a849eebb5faf2119b901bb76fd795c2848d4018" + integrity sha512-RKT8HExMpoYx4igMiVMY83lN6UeITKJlBQ+vR/8ZJ8OCdSiN3RwCq+9gH0+Xzj0+5IrM6i4j/6LuvzbZIQgEcQ== + dependencies: + tr46 "^3.0.0" + webidl-conversions "^7.0.0" + +whatwg-url@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-5.0.0.tgz#966454e8765462e37644d3626f6742ce8b70965d" + integrity sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw== + dependencies: + tr46 "~0.0.3" + webidl-conversions "^3.0.0" + +which@^2.0.1: + version "2.0.2" + resolved "https://registry.yarnpkg.com/which/-/which-2.0.2.tgz#7c6a8dd0a636a0327e10b59c9286eee93f3f51b1" + integrity sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA== + dependencies: + isexe "^2.0.0" + +wrap-ansi@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" + integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== + dependencies: + ansi-styles "^4.0.0" + string-width "^4.1.0" + strip-ansi "^6.0.0" + +wrappy@1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" + integrity sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ== + +write-file-atomic@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-4.0.2.tgz#a9df01ae5b77858a027fd2e80768ee433555fcfd" + integrity sha512-7KxauUdBmSdWnmpaGFg+ppNjKF8uNLry8LyzjauQDOVONfFLNKrKvQOxZ/VuTIcS/gge/YNahf5RIIQWTSarlg== + dependencies: + imurmurhash "^0.1.4" + signal-exit "^3.0.7" + +ws@^8.11.0: + version "8.18.0" + resolved "https://registry.yarnpkg.com/ws/-/ws-8.18.0.tgz#0d7505a6eafe2b0e712d232b42279f53bc289bbc" + integrity sha512-8VbfWfHLbbwu3+N6OKsOMpBdT4kXPDDB9cJk2bJ6mh9ucxdlnNvH1e+roYkKmN9Nxw2yjz7VzeO9oOz2zJ04Pw== + +xml-name-validator@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/xml-name-validator/-/xml-name-validator-4.0.0.tgz#79a006e2e63149a8600f15430f0a4725d1524835" + integrity sha512-ICP2e+jsHvAj2E2lIHxa5tjXRlKDJo4IdvPvCXbXQGdzSfmSpNVyIKMvoZHjDY9DP0zV17iI85o90vRFXNccRw== + +xmlchars@^2.2.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/xmlchars/-/xmlchars-2.2.0.tgz#060fe1bcb7f9c76fe2a17db86a9bc3ab894210cb" + integrity sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw== + +y18n@^5.0.5: + version "5.0.8" + resolved "https://registry.yarnpkg.com/y18n/-/y18n-5.0.8.tgz#7f4934d0f7ca8c56f95314939ddcd2dd91ce1d55" + integrity sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA== + +yallist@^3.0.2: + version "3.1.1" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.1.1.tgz#dbb7daf9bfd8bac9ab45ebf602b8cbad0d5d08fd" + integrity sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g== + +yargs-parser@^21.0.1, yargs-parser@^21.1.1: + version "21.1.1" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-21.1.1.tgz#9096bceebf990d21bb31fa9516e0ede294a77d35" + integrity sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw== + +yargs@^17.3.1: + version "17.7.2" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-17.7.2.tgz#991df39aca675a192b816e1e0363f9d75d2aa269" + integrity sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w== + dependencies: + cliui "^8.0.1" + escalade "^3.1.1" + get-caller-file "^2.0.5" + require-directory "^2.1.1" + string-width "^4.2.3" + y18n "^5.0.5" + yargs-parser "^21.1.1" + +yocto-queue@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-0.1.0.tgz#0294eb3dee05028d31ee1a5fa2c556a6aaf10a1b" + integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q== From 50a5ec0b621e6c03e4231a6cb41c905d3fa35b6c Mon Sep 17 00:00:00 2001 From: Matt Donnelly Date: Wed, 22 Jan 2025 11:00:03 +0000 Subject: [PATCH 127/146] Bump setup-node action (#464) --- .github/workflows/ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 58483329..4b1950e5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,7 +11,7 @@ jobs: uses: actions/checkout@v3 - name: Set up node - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 - name: Compile run: yarn && yarn build @@ -24,7 +24,7 @@ jobs: uses: actions/checkout@v3 - name: Set up node - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 - name: Compile run: yarn @@ -42,7 +42,7 @@ jobs: - name: Checkout repo uses: actions/checkout@v3 - name: Set up node - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 - name: Install dependencies run: yarn install - name: Build From 36bd5bad510ab5e2e886e1b42edb46799b1674ef Mon Sep 17 00:00:00 2001 From: Fern Support <126544928+fern-support@users.noreply.github.com> Date: Fri, 7 Feb 2025 13:46:08 -0500 Subject: [PATCH 128/146] Update `converstaions` integration test. (#468) Co-authored-by: eden --- tests/integration/conversations.test.ts | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/tests/integration/conversations.test.ts b/tests/integration/conversations.test.ts index c204cd8e..474b318b 100644 --- a/tests/integration/conversations.test.ts +++ b/tests/integration/conversations.test.ts @@ -1,8 +1,8 @@ import { Intercom } from "../../src"; -import { randomString } from "./utils/random"; import { createConversation, tryDeleteContact } from "./helpers"; -import { wait } from "./utils/wait"; import { createClient } from "./utils/createClient"; +import { randomString } from "./utils/random"; +import { wait } from "./utils/wait"; describe("Conversations", () => { let user: Intercom.Contact; @@ -31,11 +31,12 @@ describe("Conversations", () => { secondUser = await client.contacts.create({ external_id: randomString(), name: "Babushka Boy", - email: "babushka_boy@bababooey.com", + email: `${randomString()}@bababooey.com`, }); lead = await client.contacts.create({ + external_id: randomString(), name: "Babushka Lead", - email: "babushka_lead@bababooey.com", + email: `${randomString()}@bababooey.com`, role: "lead", }); From 217f6d3cf8deaed1657678642ecb80a040121ef8 Mon Sep 17 00:00:00 2001 From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com> Date: Thu, 13 Mar 2025 11:47:22 -0400 Subject: [PATCH 129/146] SDK regeneration (#479) --- README.md | 52 ++- package.json | 12 +- reference.md | 26 +- src/api/resources/admins/client/Client.ts | 30 +- src/api/resources/admins/types/Admin.ts | 14 +- src/api/resources/articles/client/Client.ts | 36 +- .../client/requests/CreateArticleRequest.ts | 10 +- .../client/requests/UpdateArticleRequest.ts | 10 +- src/api/resources/companies/client/Client.ts | 70 ++-- .../requests/CreateOrUpdateCompanyRequest.ts | 2 +- src/api/resources/companies/types/Company.ts | 2 +- src/api/resources/contacts/client/Client.ts | 93 +++-- src/api/resources/contacts/types/Contact.ts | 6 +- .../resources/conversations/client/Client.ts | 109 ++--- .../requests/CreateConversationRequest.ts | 2 + .../ManageConversationPartsRequest.ts | 30 +- .../resources/customObjectInstances/index.ts | 1 - .../types/CustomObjectInstance.ts | 17 - .../customObjectInstances/types/index.ts | 1 - .../resources/dataAttributes/client/Client.ts | 18 +- src/api/resources/dataExport/client/Client.ts | 24 +- src/api/resources/events/client/Client.ts | 18 +- .../resources/helpCenters/client/Client.ts | 12 +- .../resources/collections/client/Client.ts | 30 +- src/api/resources/index.ts | 2 - src/api/resources/messages/client/Client.ts | 32 +- .../news/resources/feeds/client/Client.ts | 18 +- .../news/resources/items/client/Client.ts | 30 +- src/api/resources/notes/client/Client.ts | 18 +- .../phoneCallRedirects/client/Client.ts | 6 +- src/api/resources/segments/client/Client.ts | 12 +- .../subscriptionTypes/client/Client.ts | 6 +- .../types/SubscriptionType.ts | 2 +- src/api/resources/tags/client/Client.ts | 60 +-- src/api/resources/tags/types/Tag.ts | 2 +- src/api/resources/teams/client/Client.ts | 12 +- .../resources/ticketTypes/client/Client.ts | 24 +- .../resources/attributes/client/Client.ts | 12 +- src/api/resources/tickets/client/Client.ts | 30 +- src/api/resources/visitors/client/Client.ts | 18 +- src/api/types/ActionComponent.ts | 24 ++ src/api/types/ButtonComponent.ts | 36 ++ src/api/types/CanvasObject.ts | 22 + src/api/types/CheckboxComponent.ts | 39 ++ src/api/types/CheckboxOption.ts | 17 + src/api/types/Component.ts | 69 ++++ src/api/types/ConfigureRequest.ts | 26 ++ src/api/types/ConfigureResponse.ts | 16 + src/api/types/ContactCompanies.ts | 6 + src/api/types/ContactCompany.ts | 15 + src/api/types/ContentObject.ts | 15 + src/api/types/Context.ts | 36 ++ src/api/types/ConversationSource.ts | 31 +- src/api/types/ConversationTeammates.ts | 4 +- src/api/types/CurrentCanvas.ts | 13 + src/api/types/CustomAttributes.ts | 10 +- src/api/types/DataEventSummaryItem.ts | 2 +- src/api/types/DataTableComponent.ts | 13 + src/api/types/DataTableItem.ts | 15 + src/api/types/DividerComponent.ts | 13 + src/api/types/DropdownComponent.ts | 37 ++ src/api/types/DropdownOption.ts | 17 + src/api/types/Error_.ts | 2 +- src/api/types/Event.ts | 11 + src/api/types/ImageComponent.ts | 43 ++ src/api/types/InitializeRequest.ts | 25 ++ src/api/types/InitializeResponse.ts | 13 + src/api/types/InputComponent.ts | 40 ++ src/api/types/ListComponent.ts | 27 ++ src/api/types/ListItem.ts | 27 ++ src/api/types/ListItemWithImage.ts | 14 + src/api/types/ListItemWithoutImage.ts | 14 + src/api/types/LiveCanvasRequest.ts | 23 ++ src/api/types/LiveCanvasResponse.ts | 13 + src/api/types/MultipleFilterSearchRequest.ts | 9 +- .../MultipleOrSingleFilterSearchRequest.ts | 9 + src/api/types/ResultsResponse.ts | 11 + src/api/types/SheetActionComponent.ts | 13 + src/api/types/SingleFilterSearchRequest.ts | 6 +- src/api/types/SingleSelectComponent.ts | 42 ++ src/api/types/SingleSelectOption.ts | 17 + src/api/types/SocialProfile.ts | 2 +- src/api/types/SpacerComponent.ts | 27 ++ src/api/types/SubmitActionComponent.ts | 8 + src/api/types/SubmitRequest.ts | 31 ++ src/api/types/SubmitResponse.ts | 25 ++ src/api/types/TextAreaComponent.ts | 23 ++ src/api/types/TextComponent.ts | 41 ++ src/api/types/TicketTypeAttribute.ts | 18 +- src/api/types/UrlActionComponent.ts | 11 + src/api/types/Visitor.ts | 4 +- src/api/types/index.ts | 42 +- src/version.ts | 2 +- yarn.lock | 380 +++++++++--------- 94 files changed, 1679 insertions(+), 679 deletions(-) delete mode 100644 src/api/resources/customObjectInstances/index.ts delete mode 100644 src/api/resources/customObjectInstances/types/CustomObjectInstance.ts delete mode 100644 src/api/resources/customObjectInstances/types/index.ts create mode 100644 src/api/types/ActionComponent.ts create mode 100644 src/api/types/ButtonComponent.ts create mode 100644 src/api/types/CanvasObject.ts create mode 100644 src/api/types/CheckboxComponent.ts create mode 100644 src/api/types/CheckboxOption.ts create mode 100644 src/api/types/Component.ts create mode 100644 src/api/types/ConfigureRequest.ts create mode 100644 src/api/types/ConfigureResponse.ts create mode 100644 src/api/types/ContactCompany.ts create mode 100644 src/api/types/ContentObject.ts create mode 100644 src/api/types/Context.ts create mode 100644 src/api/types/CurrentCanvas.ts create mode 100644 src/api/types/DataTableComponent.ts create mode 100644 src/api/types/DataTableItem.ts create mode 100644 src/api/types/DividerComponent.ts create mode 100644 src/api/types/DropdownComponent.ts create mode 100644 src/api/types/DropdownOption.ts create mode 100644 src/api/types/Event.ts create mode 100644 src/api/types/ImageComponent.ts create mode 100644 src/api/types/InitializeRequest.ts create mode 100644 src/api/types/InitializeResponse.ts create mode 100644 src/api/types/InputComponent.ts create mode 100644 src/api/types/ListComponent.ts create mode 100644 src/api/types/ListItem.ts create mode 100644 src/api/types/ListItemWithImage.ts create mode 100644 src/api/types/ListItemWithoutImage.ts create mode 100644 src/api/types/LiveCanvasRequest.ts create mode 100644 src/api/types/LiveCanvasResponse.ts create mode 100644 src/api/types/MultipleOrSingleFilterSearchRequest.ts create mode 100644 src/api/types/ResultsResponse.ts create mode 100644 src/api/types/SheetActionComponent.ts create mode 100644 src/api/types/SingleSelectComponent.ts create mode 100644 src/api/types/SingleSelectOption.ts create mode 100644 src/api/types/SpacerComponent.ts create mode 100644 src/api/types/SubmitActionComponent.ts create mode 100644 src/api/types/SubmitRequest.ts create mode 100644 src/api/types/SubmitResponse.ts create mode 100644 src/api/types/TextAreaComponent.ts create mode 100644 src/api/types/TextComponent.ts create mode 100644 src/api/types/UrlActionComponent.ts diff --git a/README.md b/README.md index 0b1ad88a..a9441d7c 100644 --- a/README.md +++ b/README.md @@ -1,14 +1,10 @@ -# Intercom TypeScript Library (intercom-client) +# Intercom TypeScript Library [![fern shield](https://img.shields.io/badge/%F0%9F%8C%BF-Built%20with%20Fern-brightgreen)](https://buildwithfern.com?utm_source=github&utm_medium=github&utm_campaign=readme&utm_source=https%3A%2F%2Fgithub.com%2Fintercom%2Fintercom-node) [![npm shield](https://img.shields.io/npm/v/intercom-client)](https://www.npmjs.com/package/intercom-client) The Intercom TypeScript library provides convenient access to the Intercom API from TypeScript. -[![npm](https://img.shields.io/npm/v/intercom-client)](https://www.npmjs.com/package/intercom-client) -![Intercom API Version](https://img.shields.io/badge/Intercom%20API%20Version-2.11-blue) -![Typescript Supported](https://img.shields.io/badge/Typescript-Supported-lightgrey) - ## Project Updates The TypeScript SDK has been updated to support latest API version (2.11). @@ -32,9 +28,9 @@ import { IntercomClient } from "intercom-client"; const client = new IntercomClient({ token: "YOUR_TOKEN" }); await client.articles.create({ - title: "How to create an account", - description: "Example article about creating an account.", - body: "Here are the steps to create an account.", + title: "Thanks for everything", + description: "Description of the Article", + body: "Body of the Article", author_id: 1295, state: "published", }); @@ -72,6 +68,26 @@ try { } ``` +## Pagination + +List endpoints are paginated. The SDK provides an iterator so that you can simply loop over the items: + +```typescript +import { IntercomClient } from "intercom-client"; + +const client = new IntercomClient({ token: "YOUR_TOKEN" }); +const response = await client.articles.list(); +for await (const item of response) { + console.log(item); +} + +// Or you can manually iterate page-by-page +const page = await client.articles.list(); +while (page.hasNextPage()) { + page = page.getNextPage(); +} +``` + ## Request Options This client library also supports passing in [`request` options](https://github.com/axios/axios#request-config): @@ -94,26 +110,6 @@ client.useRequestOpts({ }); ``` -## Pagination - -List endpoints are paginated. The SDK provides an iterator so that you can simply loop over the items: - -```typescript -import { IntercomClient } from "intercom-client"; - -const client = new IntercomClient({ token: "YOUR_TOKEN" }); -const response = await client.articles.list(); -for await (const item of response) { - console.log(item); -} - -// Or you can manually iterate page-by-page -const page = await client.articles.list(); -while (page.hasNextPage()) { - page = page.getNextPage(); -} -``` - ## Advanced ### Additional Headers diff --git a/package.json b/package.json index 3692ca63..faac874b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "6.0.0", + "version": "6.1.0", "private": false, "repository": "https://github.com/intercom/intercom-node", "main": "./index.js", @@ -39,5 +39,13 @@ "fs": false, "os": false, "path": false - } + }, + "license": "Apache-2.0", + "description": "Official Node bindings to the Intercom API", + "homepage": "https://github.com/intercom/intercom-node", + "bugs": "https://github.com/intercom/intercom-node/issues", + "keywords": [ + "intercom", + "api" + ] } diff --git a/reference.md b/reference.md index 09ab857e..e07b5d97 100644 --- a/reference.md +++ b/reference.md @@ -973,7 +973,7 @@ Companies will be only visible in Intercom when there is at least one associated Companies are looked up via `company_id` in a `POST` request, if not found via `company_id`, the new company will be created, if found, that company will be updated. -{% admonition type="attention" name="Using `company_id`" %} +{% admonition type="warning" name="Using `company_id`" %} You can set a unique `company_id` value when creating a company. However, it is not possible to update `company_id`. Be sure to set a unique value once upon creation of the company. {% /admonition %} @@ -1109,7 +1109,7 @@ await client.companies.find({ You can update a single company using the Intercom provisioned `id`. -{% admonition type="attention" name="Using `company_id`" %} +{% admonition type="warning" name="Using `company_id`" %} When updating a company it is not possible to update `company_id`. This can only be set once upon creation of the company. {% /admonition %} @@ -2400,7 +2400,6 @@ Most key listed as part of the Contacts Model are searchable, whether writeable | email | String | | email_domain | String | | phone | String | -| formatted_phone | String | | external_id | String | | created_at | Date (UNIX Timestamp) | | signed_up_at | Date (UNIX Timestamp) | @@ -2438,7 +2437,7 @@ Most key listed as part of the Contacts Model are searchable, whether writeable ### Accepted Operators -{% admonition type="attention" name="Searching based on `created_at`" %} +{% admonition type="warning" name="Searching based on `created_at`" %} You cannot use the `<=` or `>=` operators to search by `created_at`. {% /admonition %} @@ -4300,11 +4299,9 @@ For managing conversations you can: await client.conversations.manage({ conversation_id: "123", body: { - message_type: "assignment", + message_type: "close", type: "admin", admin_id: "12345", - assignee_id: "4324241", - body: "Goodbye :)", }, }); ``` @@ -4353,8 +4350,11 @@ await client.conversations.manage({
+{% admonition type="danger" name="Deprecation of Run Assignment Rules" %} +Run assignment rules is now deprecated in version 2.12 and future versions and will be permanently removed on December 31, 2026. After this date, any requests made to this endpoint will fail. +{% /admonition %} You can let a conversation be automatically assigned following assignment rules. -{% admonition type="attention" name="When using workflows" %} +{% admonition type="warning" name="When using workflows" %} It is not possible to use this endpoint with Workflows. {% /admonition %} @@ -4423,7 +4423,7 @@ await client.conversations.runAssignmentRules({ You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. -{% admonition type="attention" name="Contacts without an email" %} +{% admonition type="warning" name="Contacts without an email" %} If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. {% /admonition %} @@ -4496,7 +4496,7 @@ await client.conversations.attachContactAsAdmin({ You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. -{% admonition type="attention" name="Contacts without an email" %} +{% admonition type="warning" name="Contacts without an email" %} If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. {% /admonition %} @@ -5477,9 +5477,9 @@ This will return the Message model that has been created. ```typescript await client.messages.create({ - message_type: "inapp", + message_type: "email", subject: "Thanks for everything", - body: "heyy", + body: "Hello there", template: "plain", from: { type: "admin", @@ -5489,8 +5489,6 @@ await client.messages.create({ type: "user", id: "536e564f316c83104c000020", }, - created_at: 1590000000, - create_conversation_without_contact_reply: true, }); ``` diff --git a/src/api/resources/admins/client/Client.ts b/src/api/resources/admins/client/Client.ts index 05d639d7..25141fbf 100644 --- a/src/api/resources/admins/client/Client.ts +++ b/src/api/resources/admins/client/Client.ts @@ -97,8 +97,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -106,7 +106,7 @@ export class Admins { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -167,8 +167,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -177,7 +177,7 @@ export class Admins { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -249,8 +249,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -259,7 +259,7 @@ export class Admins { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -315,8 +315,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -324,7 +324,7 @@ export class Admins { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -388,8 +388,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -397,7 +397,7 @@ export class Admins { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/admins/types/Admin.ts b/src/api/resources/admins/types/Admin.ts index 0551b7d5..33266da0 100644 --- a/src/api/resources/admins/types/Admin.ts +++ b/src/api/resources/admins/types/Admin.ts @@ -26,7 +26,17 @@ export interface Admin { has_inbox_seat: boolean; /** This object represents the avatar associated with the admin. */ team_ids: number[]; - /** Image for the associated team or teammate */ - avatar?: string; + /** The avatar object associated with the admin */ + avatar?: Admin.Avatar; team_priority_level?: Intercom.TeamPriorityLevel; } + +export namespace Admin { + /** + * The avatar object associated with the admin + */ + export interface Avatar { + /** URL of the admin's avatar image */ + image_url: string; + } +} diff --git a/src/api/resources/articles/client/Client.ts b/src/api/resources/articles/client/Client.ts index c902cb40..a37c5569 100644 --- a/src/api/resources/articles/client/Client.ts +++ b/src/api/resources/articles/client/Client.ts @@ -112,8 +112,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -122,7 +122,7 @@ export class Articles { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -219,8 +219,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -229,7 +229,7 @@ export class Articles { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -295,8 +295,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -304,7 +304,7 @@ export class Articles { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -372,8 +372,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -382,7 +382,7 @@ export class Articles { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -448,8 +448,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -457,7 +457,7 @@ export class Articles { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -540,8 +540,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -550,7 +550,7 @@ export class Articles { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/articles/client/requests/CreateArticleRequest.ts b/src/api/resources/articles/client/requests/CreateArticleRequest.ts index b75b8a3d..ef3fdc01 100644 --- a/src/api/resources/articles/client/requests/CreateArticleRequest.ts +++ b/src/api/resources/articles/client/requests/CreateArticleRequest.ts @@ -49,7 +49,7 @@ export interface CreateArticleRequest { /** The id of the article's parent collection or section. An article without this field stands alone. */ parent_id?: number; /** The type of parent, which can either be a `collection` or `section`. */ - parent_type?: string; + parent_type?: CreateArticleRequest.ParentType; translated_content?: Intercom.ArticleTranslatedContent; } @@ -62,4 +62,12 @@ export namespace CreateArticleRequest { Published: "published", Draft: "draft", } as const; + /** + * The type of parent, which can either be a `collection` or `section`. + */ + export type ParentType = "collection" | "section"; + export const ParentType = { + Collection: "collection", + Section: "section", + } as const; } diff --git a/src/api/resources/articles/client/requests/UpdateArticleRequest.ts b/src/api/resources/articles/client/requests/UpdateArticleRequest.ts index 4714b224..cb814947 100644 --- a/src/api/resources/articles/client/requests/UpdateArticleRequest.ts +++ b/src/api/resources/articles/client/requests/UpdateArticleRequest.ts @@ -37,7 +37,7 @@ export interface UpdateArticleRequest { /** The id of the article's parent collection or section. An article without this field stands alone. */ parent_id?: string; /** The type of parent, which can either be a `collection` or `section`. */ - parent_type?: string; + parent_type?: UpdateArticleRequest.ParentType; translated_content?: Intercom.ArticleTranslatedContent; } @@ -50,4 +50,12 @@ export namespace UpdateArticleRequest { Published: "published", Draft: "draft", } as const; + /** + * The type of parent, which can either be a `collection` or `section`. + */ + export type ParentType = "collection" | "section"; + export const ParentType = { + Collection: "collection", + Section: "section", + } as const; } diff --git a/src/api/resources/companies/client/Client.ts b/src/api/resources/companies/client/Client.ts index e16b780d..75bb59c4 100644 --- a/src/api/resources/companies/client/Client.ts +++ b/src/api/resources/companies/client/Client.ts @@ -140,8 +140,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -150,7 +150,7 @@ export class Companies { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -194,7 +194,7 @@ export class Companies { * * Companies are looked up via `company_id` in a `POST` request, if not found via `company_id`, the new company will be created, if found, that company will be updated. * - * {% admonition type="attention" name="Using `company_id`" %} + * {% admonition type="warning" name="Using `company_id`" %} * You can set a unique `company_id` value when creating a company. However, it is not possible to update `company_id`. Be sure to set a unique value once upon creation of the company. * {% /admonition %} * @@ -228,8 +228,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -238,7 +238,7 @@ export class Companies { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -304,8 +304,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -313,7 +313,7 @@ export class Companies { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -353,7 +353,7 @@ export class Companies { /** * You can update a single company using the Intercom provisioned `id`. * - * {% admonition type="attention" name="Using `company_id`" %} + * {% admonition type="warning" name="Using `company_id`" %} * When updating a company it is not possible to update `company_id`. This can only be set once upon creation of the company. * {% /admonition %} * @@ -383,8 +383,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -392,7 +392,7 @@ export class Companies { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -458,8 +458,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -467,7 +467,7 @@ export class Companies { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -542,8 +542,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -552,7 +552,7 @@ export class Companies { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -620,8 +620,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -629,7 +629,7 @@ export class Companies { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -716,8 +716,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -726,7 +726,7 @@ export class Companies { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -816,8 +816,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -826,7 +826,7 @@ export class Companies { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -911,8 +911,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -921,7 +921,7 @@ export class Companies { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -992,8 +992,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1001,7 +1001,7 @@ export class Companies { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/companies/client/requests/CreateOrUpdateCompanyRequest.ts b/src/api/resources/companies/client/requests/CreateOrUpdateCompanyRequest.ts index 207120b3..7024d304 100644 --- a/src/api/resources/companies/client/requests/CreateOrUpdateCompanyRequest.ts +++ b/src/api/resources/companies/client/requests/CreateOrUpdateCompanyRequest.ts @@ -27,7 +27,7 @@ export interface CreateOrUpdateCompanyRequest { /** The industry that this company operates in. */ industry?: string; /** A hash of key/value pairs containing any other data about the company you want Intercom to store. */ - custom_attributes?: Record; + custom_attributes?: Record; /** The time the company was created by you. */ remote_created_at?: number; /** How much revenue the company generates for your business. Note that this will truncate floats. i.e. it only allow for whole integers, 155.98 will be truncated to 155. Note that this has an upper limit of 2**31-1 or 2147483647.. */ diff --git a/src/api/resources/companies/types/Company.ts b/src/api/resources/companies/types/Company.ts index ef8faa7c..2534d3fc 100644 --- a/src/api/resources/companies/types/Company.ts +++ b/src/api/resources/companies/types/Company.ts @@ -40,7 +40,7 @@ export interface Company { /** The number of users in the company. */ user_count: number; /** The custom attributes you have set on the company. */ - custom_attributes?: Record; + custom_attributes?: Record; /** The list of tags associated with the company */ tags?: Company.Tags; /** The list of segments associated with the company */ diff --git a/src/api/resources/contacts/client/Client.ts b/src/api/resources/contacts/client/Client.ts index 61b69bf1..6d654f3a 100644 --- a/src/api/resources/contacts/client/Client.ts +++ b/src/api/resources/contacts/client/Client.ts @@ -113,8 +113,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -123,7 +123,7 @@ export class Contacts { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -200,8 +200,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -209,7 +209,7 @@ export class Contacts { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -283,8 +283,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -292,7 +292,7 @@ export class Contacts { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -375,8 +375,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -385,7 +385,7 @@ export class Contacts { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -454,8 +454,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -463,7 +463,7 @@ export class Contacts { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -531,8 +531,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -540,7 +540,7 @@ export class Contacts { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -605,8 +605,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -614,7 +614,7 @@ export class Contacts { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -679,8 +679,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -689,7 +689,7 @@ export class Contacts { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -752,8 +752,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -761,7 +761,7 @@ export class Contacts { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -824,8 +824,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -834,7 +834,7 @@ export class Contacts { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -914,7 +914,6 @@ export class Contacts { * | email | String | * | email_domain | String | * | phone | String | - * | formatted_phone | String | * | external_id | String | * | created_at | Date (UNIX Timestamp) | * | signed_up_at | Date (UNIX Timestamp) | @@ -952,7 +951,7 @@ export class Contacts { * * ### Accepted Operators * - * {% admonition type="attention" name="Searching based on `created_at`" %} + * {% admonition type="warning" name="Searching based on `created_at`" %} * You cannot use the `<=` or `>=` operators to search by `created_at`. * {% /admonition %} * @@ -1007,8 +1006,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1017,7 +1016,7 @@ export class Contacts { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -1103,8 +1102,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1113,7 +1112,7 @@ export class Contacts { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -1182,8 +1181,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1192,7 +1191,7 @@ export class Contacts { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -1253,8 +1252,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1262,7 +1261,7 @@ export class Contacts { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -1320,8 +1319,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1329,7 +1328,7 @@ export class Contacts { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/contacts/types/Contact.ts b/src/api/resources/contacts/types/Contact.ts index c4b7c47a..2b1c744e 100644 --- a/src/api/resources/contacts/types/Contact.ts +++ b/src/api/resources/contacts/types/Contact.ts @@ -9,7 +9,7 @@ import * as Intercom from "../../../index"; */ export interface Contact { /** The type of object. */ - type?: string; + type?: "contact"; /** The unique identifier for the contact which is given by Intercom. */ id: string; /** The unique identifier for the contact which is provided by the Client. */ @@ -19,7 +19,7 @@ export interface Contact { /** The role of the contact. */ role: string; /** The contact's email. */ - email: string; + email?: string; /** The contact's email domain. */ email_domain?: string; /** The contacts phone. */ @@ -99,7 +99,7 @@ export interface Contact { export namespace Contact { export interface Avatar { /** The type of object */ - type?: string; + type?: "avatar"; /** An image URL containing the avatar of a contact. */ image_url?: string; } diff --git a/src/api/resources/conversations/client/Client.ts b/src/api/resources/conversations/client/Client.ts index a6bffd8a..feedc547 100644 --- a/src/api/resources/conversations/client/Client.ts +++ b/src/api/resources/conversations/client/Client.ts @@ -117,8 +117,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -127,7 +127,7 @@ export class Conversations { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -222,8 +222,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -232,7 +232,7 @@ export class Conversations { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -316,8 +316,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -326,7 +326,7 @@ export class Conversations { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -414,8 +414,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -425,7 +425,7 @@ export class Conversations { queryParameters: _queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -601,8 +601,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -611,7 +611,7 @@ export class Conversations { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -719,8 +719,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -729,7 +729,7 @@ export class Conversations { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -788,11 +788,28 @@ export class Conversations { * await client.conversations.manage({ * conversation_id: "123", * body: { - * message_type: "assignment", + * message_type: "close", * type: "admin", - * admin_id: "12345", - * assignee_id: "4324241", - * body: "Goodbye :)" + * admin_id: "12345" + * } + * }) + * + * @example + * await client.conversations.manage({ + * conversation_id: "123", + * body: { + * message_type: "snoozed", + * admin_id: "5017691", + * snoozed_until: 1673609604 + * } + * }) + * + * @example + * await client.conversations.manage({ + * conversation_id: "123", + * body: { + * message_type: "open", + * admin_id: "5017690" * } * }) * @@ -803,8 +820,7 @@ export class Conversations { * message_type: "assignment", * type: "admin", * admin_id: "12345", - * assignee_id: "4324241", - * body: "Let me pass you over to one of my colleagues." + * assignee_id: "4324241" * } * }) */ @@ -823,8 +839,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -833,7 +849,7 @@ export class Conversations { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -875,8 +891,11 @@ export class Conversations { } /** + * {% admonition type="danger" name="Deprecation of Run Assignment Rules" %} + * Run assignment rules is now deprecated in version 2.12 and future versions and will be permanently removed on December 31, 2026. After this date, any requests made to this endpoint will fail. + * {% /admonition %} * You can let a conversation be automatically assigned following assignment rules. - * {% admonition type="attention" name="When using workflows" %} + * {% admonition type="warning" name="When using workflows" %} * It is not possible to use this endpoint with Workflows. * {% /admonition %} * @@ -907,8 +926,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -916,7 +935,7 @@ export class Conversations { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -960,7 +979,7 @@ export class Conversations { /** * You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. * - * {% admonition type="attention" name="Contacts without an email" %} + * {% admonition type="warning" name="Contacts without an email" %} * If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. * {% /admonition %} * @@ -1005,8 +1024,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1015,7 +1034,7 @@ export class Conversations { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -1059,7 +1078,7 @@ export class Conversations { /** * You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. * - * {% admonition type="attention" name="Contacts without an email" %} + * {% admonition type="warning" name="Contacts without an email" %} * If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. * {% /admonition %} * @@ -1094,8 +1113,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1104,7 +1123,7 @@ export class Conversations { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -1189,8 +1208,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1199,7 +1218,7 @@ export class Conversations { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -1271,8 +1290,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1281,7 +1300,7 @@ export class Conversations { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/conversations/client/requests/CreateConversationRequest.ts b/src/api/resources/conversations/client/requests/CreateConversationRequest.ts index 24e5403f..4c82a814 100644 --- a/src/api/resources/conversations/client/requests/CreateConversationRequest.ts +++ b/src/api/resources/conversations/client/requests/CreateConversationRequest.ts @@ -25,6 +25,8 @@ export interface CreateConversationRequest { from: CreateConversationRequest.From; /** The content of the message. HTML is not supported. */ body: string; + /** The time the conversation was created as a UTC Unix timestamp. If not provided, the current time will be used. This field is only recommneded for migrating past conversations from another source into Intercom. */ + created_at?: number; } export namespace CreateConversationRequest { diff --git a/src/api/resources/conversations/client/requests/ManageConversationPartsRequest.ts b/src/api/resources/conversations/client/requests/ManageConversationPartsRequest.ts index 1ad1d15b..48c245e7 100644 --- a/src/api/resources/conversations/client/requests/ManageConversationPartsRequest.ts +++ b/src/api/resources/conversations/client/requests/ManageConversationPartsRequest.ts @@ -9,11 +9,9 @@ import * as Intercom from "../../../../index"; * { * conversation_id: "123", * body: { - * message_type: "assignment", + * message_type: "close", * type: "admin", - * admin_id: "12345", - * assignee_id: "4324241", - * body: "Goodbye :)" + * admin_id: "12345" * } * } * @@ -21,11 +19,9 @@ import * as Intercom from "../../../../index"; * { * conversation_id: "123", * body: { - * message_type: "assignment", - * type: "admin", - * admin_id: "12345", - * assignee_id: "4324241", - * body: "Let me pass you over to one of my colleagues." + * message_type: "snoozed", + * admin_id: "5017691", + * snoozed_until: 1673609604 * } * } * @@ -33,11 +29,8 @@ import * as Intercom from "../../../../index"; * { * conversation_id: "123", * body: { - * message_type: "assignment", - * type: "admin", - * admin_id: "12345", - * assignee_id: "4324241", - * body: "Let me pass you over to one of my colleagues." + * message_type: "open", + * admin_id: "5017690" * } * } * @@ -48,8 +41,7 @@ import * as Intercom from "../../../../index"; * message_type: "assignment", * type: "admin", * admin_id: "12345", - * assignee_id: "4324241", - * body: "Let me pass you over to one of my colleagues." + * assignee_id: "4324241" * } * } * @@ -57,11 +49,9 @@ import * as Intercom from "../../../../index"; * { * conversation_id: "123", * body: { - * message_type: "assignment", + * message_type: "close", * type: "admin", - * admin_id: "12345", - * assignee_id: "4324241", - * body: "Goodbye :)" + * admin_id: "12345" * } * } */ diff --git a/src/api/resources/customObjectInstances/index.ts b/src/api/resources/customObjectInstances/index.ts deleted file mode 100644 index eea524d6..00000000 --- a/src/api/resources/customObjectInstances/index.ts +++ /dev/null @@ -1 +0,0 @@ -export * from "./types"; diff --git a/src/api/resources/customObjectInstances/types/CustomObjectInstance.ts b/src/api/resources/customObjectInstances/types/CustomObjectInstance.ts deleted file mode 100644 index 4f43cee0..00000000 --- a/src/api/resources/customObjectInstances/types/CustomObjectInstance.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A Custom Object Instance represents an instance of a custom object type. This allows you to create and set custom attributes to store data about your customers that is not already captured by Intercom. The parent object includes recommended default attributes and you can add your own custom attributes. - */ -export interface CustomObjectInstance { - /** The Intercom defined id representing the custom object instance. */ - id: string; - /** The id you have defined for the custom object instance. */ - external_id?: string; - /** The identifier of the custom object type that defines the structure of the custom object instance. */ - type: string; - /** The custom attributes you have set on the custom object instance. */ - custom_attributes?: Record; -} diff --git a/src/api/resources/customObjectInstances/types/index.ts b/src/api/resources/customObjectInstances/types/index.ts deleted file mode 100644 index d5c782f8..00000000 --- a/src/api/resources/customObjectInstances/types/index.ts +++ /dev/null @@ -1 +0,0 @@ -export * from "./CustomObjectInstance"; diff --git a/src/api/resources/dataAttributes/client/Client.ts b/src/api/resources/dataAttributes/client/Client.ts index d3ca59dc..f24256a1 100644 --- a/src/api/resources/dataAttributes/client/Client.ts +++ b/src/api/resources/dataAttributes/client/Client.ts @@ -108,8 +108,8 @@ export class DataAttributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -118,7 +118,7 @@ export class DataAttributes { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -220,8 +220,8 @@ export class DataAttributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -230,7 +230,7 @@ export class DataAttributes { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -329,8 +329,8 @@ export class DataAttributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -339,7 +339,7 @@ export class DataAttributes { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/dataExport/client/Client.ts b/src/api/resources/dataExport/client/Client.ts index 47032822..8a9064d8 100644 --- a/src/api/resources/dataExport/client/Client.ts +++ b/src/api/resources/dataExport/client/Client.ts @@ -113,8 +113,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -123,7 +123,7 @@ export class DataExport { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -183,8 +183,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -192,7 +192,7 @@ export class DataExport { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -250,8 +250,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -259,7 +259,7 @@ export class DataExport { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -323,8 +323,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -332,7 +332,7 @@ export class DataExport { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/events/client/Client.ts b/src/api/resources/events/client/Client.ts index 6862abba..67de1e49 100644 --- a/src/api/resources/events/client/Client.ts +++ b/src/api/resources/events/client/Client.ts @@ -140,8 +140,8 @@ export class Events { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -150,7 +150,7 @@ export class Events { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -255,8 +255,8 @@ export class Events { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -265,7 +265,7 @@ export class Events { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -326,8 +326,8 @@ export class Events { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -336,7 +336,7 @@ export class Events { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/helpCenters/client/Client.ts b/src/api/resources/helpCenters/client/Client.ts index dc51ba65..82e0cb17 100644 --- a/src/api/resources/helpCenters/client/Client.ts +++ b/src/api/resources/helpCenters/client/Client.ts @@ -106,8 +106,8 @@ export class HelpCenters { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -115,7 +115,7 @@ export class HelpCenters { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -189,8 +189,8 @@ export class HelpCenters { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -199,7 +199,7 @@ export class HelpCenters { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/helpCenters/resources/collections/client/Client.ts b/src/api/resources/helpCenters/resources/collections/client/Client.ts index cd6fe1d3..bcba68d6 100644 --- a/src/api/resources/helpCenters/resources/collections/client/Client.ts +++ b/src/api/resources/helpCenters/resources/collections/client/Client.ts @@ -107,8 +107,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -117,7 +117,7 @@ export class Collections { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -197,8 +197,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -207,7 +207,7 @@ export class Collections { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -273,8 +273,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -282,7 +282,7 @@ export class Collections { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -351,8 +351,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -361,7 +361,7 @@ export class Collections { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -429,8 +429,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -438,7 +438,7 @@ export class Collections { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/index.ts b/src/api/resources/index.ts index 2f3cb340..b97ae198 100644 --- a/src/api/resources/index.ts +++ b/src/api/resources/index.ts @@ -32,8 +32,6 @@ export * as helpCenter from "./helpCenter"; export * from "./helpCenter/types"; export * as aiContentSource from "./aiContentSource"; export * from "./aiContentSource/types"; -export * as customObjectInstances from "./customObjectInstances"; -export * from "./customObjectInstances/types"; export * as dataEvents from "./dataEvents"; export * from "./dataEvents/types"; export * as news from "./news"; diff --git a/src/api/resources/messages/client/Client.ts b/src/api/resources/messages/client/Client.ts index c69a0fad..9656e54f 100644 --- a/src/api/resources/messages/client/Client.ts +++ b/src/api/resources/messages/client/Client.ts @@ -96,9 +96,9 @@ export class Messages { * * @example * await client.messages.create({ - * message_type: "inapp", + * message_type: "email", * subject: "Thanks for everything", - * body: "heyy", + * body: "Hello there", * template: "plain", * from: { * type: "admin", @@ -107,27 +107,7 @@ export class Messages { * to: { * type: "user", * id: "536e564f316c83104c000020" - * }, - * created_at: 1590000000, - * create_conversation_without_contact_reply: true - * }) - * - * @example - * await client.messages.create({ - * message_type: "inapp", - * subject: "Thanks for everything", - * body: "heyy", - * template: "plain", - * from: { - * type: "admin", - * id: 394051 - * }, - * to: { - * type: "user", - * id: "667d616c8a68186f43bafe52" - * }, - * created_at: 1590000000, - * create_conversation_without_contact_reply: true + * } * }) * * @example @@ -198,8 +178,8 @@ export class Messages { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -208,7 +188,7 @@ export class Messages { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/news/resources/feeds/client/Client.ts b/src/api/resources/news/resources/feeds/client/Client.ts index 277de3c0..755013e9 100644 --- a/src/api/resources/news/resources/feeds/client/Client.ts +++ b/src/api/resources/news/resources/feeds/client/Client.ts @@ -98,8 +98,8 @@ export class Feeds { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -107,7 +107,7 @@ export class Feeds { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -165,8 +165,8 @@ export class Feeds { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -174,7 +174,7 @@ export class Feeds { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -237,8 +237,8 @@ export class Feeds { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -246,7 +246,7 @@ export class Feeds { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/news/resources/items/client/Client.ts b/src/api/resources/news/resources/items/client/Client.ts index 472e49fb..ce135ffe 100644 --- a/src/api/resources/news/resources/items/client/Client.ts +++ b/src/api/resources/news/resources/items/client/Client.ts @@ -91,8 +91,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -100,7 +100,7 @@ export class Items { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -172,8 +172,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -182,7 +182,7 @@ export class Items { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -246,8 +246,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -255,7 +255,7 @@ export class Items { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -338,8 +338,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -348,7 +348,7 @@ export class Items { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -416,8 +416,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -425,7 +425,7 @@ export class Items { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/notes/client/Client.ts b/src/api/resources/notes/client/Client.ts index f01df098..668debcb 100644 --- a/src/api/resources/notes/client/Client.ts +++ b/src/api/resources/notes/client/Client.ts @@ -110,8 +110,8 @@ export class Notes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -120,7 +120,7 @@ export class Notes { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -196,8 +196,8 @@ export class Notes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -206,7 +206,7 @@ export class Notes { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -272,8 +272,8 @@ export class Notes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -281,7 +281,7 @@ export class Notes { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/phoneCallRedirects/client/Client.ts b/src/api/resources/phoneCallRedirects/client/Client.ts index 7e3d3829..0216809a 100644 --- a/src/api/resources/phoneCallRedirects/client/Client.ts +++ b/src/api/resources/phoneCallRedirects/client/Client.ts @@ -115,8 +115,8 @@ export class PhoneCallRedirects { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -125,7 +125,7 @@ export class PhoneCallRedirects { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/segments/client/Client.ts b/src/api/resources/segments/client/Client.ts index 6af0a5bd..4b044c01 100644 --- a/src/api/resources/segments/client/Client.ts +++ b/src/api/resources/segments/client/Client.ts @@ -104,8 +104,8 @@ export class Segments { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -114,7 +114,7 @@ export class Segments { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -178,8 +178,8 @@ export class Segments { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -187,7 +187,7 @@ export class Segments { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/subscriptionTypes/client/Client.ts b/src/api/resources/subscriptionTypes/client/Client.ts index c2914911..e8bdfb4b 100644 --- a/src/api/resources/subscriptionTypes/client/Client.ts +++ b/src/api/resources/subscriptionTypes/client/Client.ts @@ -94,8 +94,8 @@ export class SubscriptionTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -103,7 +103,7 @@ export class SubscriptionTypes { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/subscriptionTypes/types/SubscriptionType.ts b/src/api/resources/subscriptionTypes/types/SubscriptionType.ts index e27d1d7d..fe1c68ff 100644 --- a/src/api/resources/subscriptionTypes/types/SubscriptionType.ts +++ b/src/api/resources/subscriptionTypes/types/SubscriptionType.ts @@ -9,7 +9,7 @@ import * as Intercom from "../../../index"; */ export interface SubscriptionType { /** The type of the object - subscription */ - type: string; + type: "subscription"; /** The unique identifier representing the subscription type. */ id: string; /** The state of the subscription type. */ diff --git a/src/api/resources/tags/client/Client.ts b/src/api/resources/tags/client/Client.ts index 7e4729c9..5d47d7fd 100644 --- a/src/api/resources/tags/client/Client.ts +++ b/src/api/resources/tags/client/Client.ts @@ -109,8 +109,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -119,7 +119,7 @@ export class Tags { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -188,8 +188,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -197,7 +197,7 @@ export class Tags { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -267,8 +267,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -277,7 +277,7 @@ export class Tags { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -347,8 +347,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -357,7 +357,7 @@ export class Tags { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -418,8 +418,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -427,7 +427,7 @@ export class Tags { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -524,8 +524,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -534,7 +534,7 @@ export class Tags { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -600,8 +600,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -609,7 +609,7 @@ export class Tags { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -673,8 +673,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -682,7 +682,7 @@ export class Tags { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -752,8 +752,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -762,7 +762,7 @@ export class Tags { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -830,8 +830,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -840,7 +840,7 @@ export class Tags { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/tags/types/Tag.ts b/src/api/resources/tags/types/Tag.ts index 89b6ce54..7002dfdb 100644 --- a/src/api/resources/tags/types/Tag.ts +++ b/src/api/resources/tags/types/Tag.ts @@ -9,7 +9,7 @@ import * as Intercom from "../../../index"; */ export interface Tag { /** value is "tag" */ - type: string; + type: "tag"; /** The id of the tag */ id: string; /** The name of the tag */ diff --git a/src/api/resources/teams/client/Client.ts b/src/api/resources/teams/client/Client.ts index 5cffe77d..8d996de9 100644 --- a/src/api/resources/teams/client/Client.ts +++ b/src/api/resources/teams/client/Client.ts @@ -94,8 +94,8 @@ export class Teams { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -103,7 +103,7 @@ export class Teams { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -167,8 +167,8 @@ export class Teams { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -176,7 +176,7 @@ export class Teams { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/ticketTypes/client/Client.ts b/src/api/resources/ticketTypes/client/Client.ts index 4d37e791..ad8aa653 100644 --- a/src/api/resources/ticketTypes/client/Client.ts +++ b/src/api/resources/ticketTypes/client/Client.ts @@ -101,8 +101,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -110,7 +110,7 @@ export class TicketTypes { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -179,8 +179,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -189,7 +189,7 @@ export class TicketTypes { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -252,8 +252,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -261,7 +261,7 @@ export class TicketTypes { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -332,8 +332,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -342,7 +342,7 @@ export class TicketTypes { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/ticketTypes/resources/attributes/client/Client.ts b/src/api/resources/ticketTypes/resources/attributes/client/Client.ts index f2a677b5..d11b193b 100644 --- a/src/api/resources/ticketTypes/resources/attributes/client/Client.ts +++ b/src/api/resources/ticketTypes/resources/attributes/client/Client.ts @@ -102,8 +102,8 @@ export class Attributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -112,7 +112,7 @@ export class Attributes { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -179,8 +179,8 @@ export class Attributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -189,7 +189,7 @@ export class Attributes { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/tickets/client/Client.ts b/src/api/resources/tickets/client/Client.ts index 1f86b3b8..20106a19 100644 --- a/src/api/resources/tickets/client/Client.ts +++ b/src/api/resources/tickets/client/Client.ts @@ -148,8 +148,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -158,7 +158,7 @@ export class Tickets { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -231,8 +231,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -241,7 +241,7 @@ export class Tickets { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -304,8 +304,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -313,7 +313,7 @@ export class Tickets { }, contentType: "application/json", requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -416,8 +416,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -426,7 +426,7 @@ export class Tickets { contentType: "application/json", requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -560,8 +560,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -570,7 +570,7 @@ export class Tickets { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/resources/visitors/client/Client.ts b/src/api/resources/visitors/client/Client.ts index 284b58b3..ec8654a2 100644 --- a/src/api/resources/visitors/client/Client.ts +++ b/src/api/resources/visitors/client/Client.ts @@ -104,8 +104,8 @@ export class Visitors { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -114,7 +114,7 @@ export class Visitors { contentType: "application/json", queryParameters: _queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -190,8 +190,8 @@ export class Visitors { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -200,7 +200,7 @@ export class Visitors { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); @@ -275,8 +275,8 @@ export class Visitors { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.0.0", - "User-Agent": "intercom-client/6.0.0", + "X-Fern-SDK-Version": "6.1.0", + "User-Agent": "intercom-client/6.1.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -285,7 +285,7 @@ export class Visitors { contentType: "application/json", requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); diff --git a/src/api/types/ActionComponent.ts b/src/api/types/ActionComponent.ts new file mode 100644 index 00000000..c97feba7 --- /dev/null +++ b/src/api/types/ActionComponent.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +export type ActionComponent = + | Intercom.ActionComponent.Sheet + | Intercom.ActionComponent.Url + | Intercom.ActionComponent.Submit; + +export namespace ActionComponent { + export interface Sheet extends Intercom.SheetActionComponent { + type: "sheet"; + } + + export interface Url extends Intercom.UrlActionComponent { + type: "url"; + } + + export interface Submit extends Intercom.SubmitActionComponent { + type: "submit"; + } +} diff --git a/src/api/types/ButtonComponent.ts b/src/api/types/ButtonComponent.ts new file mode 100644 index 00000000..fa419ed8 --- /dev/null +++ b/src/api/types/ButtonComponent.ts @@ -0,0 +1,36 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A button component is used to take an action by clicking a button. This can either: + * - [Trigger a submit request to be sent](https://developers.intercom.com/docs/references/canvas-kit/actioncomponents/submit-action) Inbox Messenger + * - [Open a link in a new page](https://developers.intercom.com/docs/references/canvas-kit/actioncomponents/url-action) Inbox Messenger + * - [Open a sheet](https://developers.intercom.com/docs/references/canvas-kit/actioncomponents/sheets-action) Messenger + */ +export interface ButtonComponent { + /** A unique identifier for the component. */ + id: string; + /** The text that will be rendered inside the button. */ + label: string; + /** This can be a Submit Action, URL Action, or Sheets Action. */ + action: Intercom.ActionComponent; + /** Styles the button. Default is 'primary'. */ + style?: ButtonComponent.Style; + /** Styles the button and prevents the action. Default is false. */ + disabled?: boolean; +} + +export namespace ButtonComponent { + /** + * Styles the button. Default is 'primary'. + */ + export type Style = "primary" | "secondary" | "link"; + export const Style = { + Primary: "primary", + Secondary: "secondary", + Link: "link", + } as const; +} diff --git a/src/api/types/CanvasObject.ts b/src/api/types/CanvasObject.ts new file mode 100644 index 00000000..bb6161d3 --- /dev/null +++ b/src/api/types/CanvasObject.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * You have to respond to the majority of requests with a canvas object. This will tell us what UI to show for your app. + * + * A canvas can either be static (meaning we send you the next request only when an action takes place) or live (meaning we send you the next request when someone views the app). + * + * - A static canvas needs a ContentObject which will contain the components to show. + * - A live canvas needs a `content_url` which we we will make the Live Canvas requests to when the app is viewed. This is only possible for apps viewed or used in the Messenger. + */ +export interface CanvasObject { + /** The content object that will be shown as the UI of the app. Max Size is 64KB. */ + content: Intercom.ContentObject; + /** The URL which we make Live Canvas requests to. You must respond to these with a content object. Max size is 64KB. */ + content_url?: string; + /** Optional Stored Data that you want to be returned in the next sent request. Max Size is 64KB. */ + stored_data?: Record; +} diff --git a/src/api/types/CheckboxComponent.ts b/src/api/types/CheckboxComponent.ts new file mode 100644 index 00000000..ddd79298 --- /dev/null +++ b/src/api/types/CheckboxComponent.ts @@ -0,0 +1,39 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A checkbox component is used to capture multiple choices from as many options as you want to provide. You can submit the options by: + * + * - Using a ButtonComponent (which will submit all interactive components in the canvas) + * + * When a submit action takes place, the results are given in a hash with the `id` from the checkbox component used as the key and an array containing the `id` of each chosen option as the value. + */ +export interface CheckboxComponent { + /** A unique identifier for the component. */ + id: string; + /** The list of options. Minimum of 1. */ + option: Intercom.CheckboxOption[]; + /** The text shown above the options. */ + label: string; + /** The option's that are selected by default. */ + value?: string[]; + /** Styles the input. Default is `unsaved`. Prevent action with `saved`. */ + save_state?: CheckboxComponent.SaveState; + /** Styles all options and prevents the action. Default is false. Will be overridden if save_state is saved. */ + disabled?: boolean; +} + +export namespace CheckboxComponent { + /** + * Styles the input. Default is `unsaved`. Prevent action with `saved`. + */ + export type SaveState = "unsaved" | "saved" | "failed"; + export const SaveState = { + Unsaved: "unsaved", + Saved: "saved", + Failed: "failed", + } as const; +} diff --git a/src/api/types/CheckboxOption.ts b/src/api/types/CheckboxOption.ts new file mode 100644 index 00000000..d33bb8fe --- /dev/null +++ b/src/api/types/CheckboxOption.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A checkbox option component that can be selected. + */ +export interface CheckboxOption { + /** The type of component you are rendering. */ + type: "option"; + /** A unique identifier for the option. */ + id: string; + /** The text shown next to the checkbox. */ + text: string; + /** Styles the option and prevents the action. Default is false. */ + disabled?: boolean; +} diff --git a/src/api/types/Component.ts b/src/api/types/Component.ts new file mode 100644 index 00000000..d2de298c --- /dev/null +++ b/src/api/types/Component.ts @@ -0,0 +1,69 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +export type Component = + | Intercom.Component.Button + | Intercom.Component.Checkbox + | Intercom.Component.Dropdown + | Intercom.Component.Input + | Intercom.Component.List + | Intercom.Component.SingleSelect + | Intercom.Component.Textarea + | Intercom.Component.DataTable + | Intercom.Component.Divider + | Intercom.Component.Image + | Intercom.Component.Spacer + | Intercom.Component.Text; + +export namespace Component { + export interface Button extends Intercom.ButtonComponent { + type: "button"; + } + + export interface Checkbox extends Intercom.CheckboxComponent { + type: "checkbox"; + } + + export interface Dropdown extends Intercom.DropdownComponent { + type: "dropdown"; + } + + export interface Input extends Intercom.InputComponent { + type: "input"; + } + + export interface List extends Intercom.ListComponent { + type: "list"; + } + + export interface SingleSelect extends Intercom.SingleSelectComponent { + type: "single-select"; + } + + export interface Textarea extends Intercom.TextAreaComponent { + type: "textarea"; + } + + export interface DataTable extends Intercom.DataTableComponent { + type: "data-table"; + } + + export interface Divider extends Intercom.DividerComponent { + type: "divider"; + } + + export interface Image extends Intercom.ImageComponent { + type: "image"; + } + + export interface Spacer extends Intercom.SpacerComponent { + type: "spacer"; + } + + export interface Text extends Intercom.TextComponent { + type: "text"; + } +} diff --git a/src/api/types/ConfigureRequest.ts b/src/api/types/ConfigureRequest.ts new file mode 100644 index 00000000..b565bb2b --- /dev/null +++ b/src/api/types/ConfigureRequest.ts @@ -0,0 +1,26 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The first request we send will allow you to know the workspace where this is happening, the admin who will be configuring the app, and additional context such as where this will be added once complete. + * + * For subsequent requests whereby an admin has interacted with a component with a submit action, the request payload will contain the same details with `current_canvas`, `input_values` and the `component_id` also present. This allows you to understand what component the request came from, see what the value of any input was, action anything in your codebase, and then respond knowing what canvas was previously shown beforehand. + */ +export type ConfigureRequest = + | { + workspace_id: string; + admin: Intercom.Admin; + context: Intercom.Context; + } + | { + workspace_id: string; + workspace_region: string; + component_id: string; + admin: Intercom.Admin; + context: Intercom.Context; + current_canvas: Intercom.CanvasObject; + input_values: Record; + }; diff --git a/src/api/types/ConfigureResponse.ts b/src/api/types/ConfigureResponse.ts new file mode 100644 index 00000000..08ad2508 --- /dev/null +++ b/src/api/types/ConfigureResponse.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The response object returned when configuring an app. This will either: + * - A canvas object which will replace the previous canvas that was visible until the teammate interacted with your app + * - A results object which will end the configuration and trigger the initialize request to be sent. There will be a card_creation_options object in the payload showing your key-value pairs from the results object. + */ +export type ConfigureResponse = + | Intercom.ResultsResponse + | { + canvas: Intercom.CanvasObject; + }; diff --git a/src/api/types/ContactCompanies.ts b/src/api/types/ContactCompanies.ts index c452e42e..88980a31 100644 --- a/src/api/types/ContactCompanies.ts +++ b/src/api/types/ContactCompanies.ts @@ -2,10 +2,16 @@ * This file was auto-generated by Fern from our API Definition. */ +import * as Intercom from "../index"; + /** * An object containing companies meta data about the companies that a contact has. Up to 10 will be displayed here. Use the url to get more. */ export interface ContactCompanies { + /** The type of object */ + type?: "list"; + /** An array containing Company Objects */ + data?: Intercom.ContactCompany[]; /** Url to get more company resources for this contact */ url: string; /** Int representing the total number of companyies attached to this contact */ diff --git a/src/api/types/ContactCompany.ts b/src/api/types/ContactCompany.ts new file mode 100644 index 00000000..cfe15a56 --- /dev/null +++ b/src/api/types/ContactCompany.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A reference to a company associated with a contact + */ +export interface ContactCompany { + /** The unique identifier for the company */ + id: string; + /** The type of the object */ + type: "company"; + /** URL to get the full company resource */ + url: string; +} diff --git a/src/api/types/ContentObject.ts b/src/api/types/ContentObject.ts new file mode 100644 index 00000000..127b8d88 --- /dev/null +++ b/src/api/types/ContentObject.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The content object is where you specify the UI of your app. You provide us with a set of `components` in a components array that we then render. + * + * The content object should usually be returned within the [canvas object](https://developers.intercom.com/docs/references/canvas-kit/responseobjects/canvas). If you're responding to a Live Canvas request however, then you should only respond with the content object. + */ +export interface ContentObject { + /** The list of components to be rendered. */ + components: Intercom.Component[]; +} diff --git a/src/api/types/Context.ts b/src/api/types/Context.ts new file mode 100644 index 00000000..c86d4597 --- /dev/null +++ b/src/api/types/Context.ts @@ -0,0 +1,36 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The context object provides additional details on where the app has been added (or is currently being used), what page the app is being used on, and information on the Messenger settings. This is in order for you give a fully customised experience based on the customers use case. + * + * If the `location` is `conversation` then you will also be given a `conversation_id`. If you need to use details about the conversation, then you have to use the `conversation_id` to [make a call to our Conversations API and retrieve the conversation object](https://developers.intercom.com/intercom-api-reference/reference#get-a-single-conversation). + */ +export interface Context { + /** The id of the conversation where the app is added or being used. */ + conversation_id?: number; + /** Where the app is added or the action took place. Can be either 'conversation', 'home', 'message', or 'operator'. */ + location?: Context.Location; + /** The default end-user language of the Messenger. Use to localise Messenger App content. */ + locale?: string; + /** The messengers action colour. Use in Sheets and Icons to make a Messenger App experience feel part of the host Messenger. */ + messenger_action_colour?: string; + /** The messengers background colour. Use in Sheets and Icons to make a Messenger App experience feel part of the host Messenger. */ + messenger_background_colour?: string; + /** The current page URL where the app is being used. */ + referrer?: string; +} + +export namespace Context { + /** + * Where the app is added or the action took place. Can be either 'conversation', 'home', 'message', or 'operator'. + */ + export type Location = "conversation" | "home" | "message" | "operator"; + export const Location = { + Conversation: "conversation", + Home: "home", + Message: "message", + Operator: "operator", + } as const; +} diff --git a/src/api/types/ConversationSource.ts b/src/api/types/ConversationSource.ts index 1b1e352d..7dcaf810 100644 --- a/src/api/types/ConversationSource.ts +++ b/src/api/types/ConversationSource.ts @@ -9,7 +9,7 @@ import * as Intercom from "../index"; */ export interface ConversationSource { /** This includes conversation, email, facebook, instagram, phone_call, phone_switch, push, sms, twitter and whatsapp. */ - type: string; + type: ConversationSource.Type; /** The id representing the message. */ id: string; /** The conversation's initiation type. Possible values are customer_initiated, campaigns_initiated (legacy campaigns), operator_initiated (Custom bot), automated (Series and other outbounds with dynamic audience message) and admin_initiated (fixed audience message, ticket initiated by an admin, group email). */ @@ -26,3 +26,32 @@ export interface ConversationSource { /** Whether or not the source message has been redacted. Only applicable for contact initiated messages. */ redacted: boolean; } + +export namespace ConversationSource { + /** + * This includes conversation, email, facebook, instagram, phone_call, phone_switch, push, sms, twitter and whatsapp. + */ + export type Type = + | "conversation" + | "email" + | "facebook" + | "instagram" + | "phone_call" + | "phone_switch" + | "push" + | "sms" + | "twitter" + | "whatsapp"; + export const Type = { + Conversation: "conversation", + Email: "email", + Facebook: "facebook", + Instagram: "instagram", + PhoneCall: "phone_call", + PhoneSwitch: "phone_switch", + Push: "push", + Sms: "sms", + Twitter: "twitter", + Whatsapp: "whatsapp", + } as const; +} diff --git a/src/api/types/ConversationTeammates.ts b/src/api/types/ConversationTeammates.ts index 6094d5c5..c619dcb5 100644 --- a/src/api/types/ConversationTeammates.ts +++ b/src/api/types/ConversationTeammates.ts @@ -9,7 +9,7 @@ import * as Intercom from "../index"; */ export interface ConversationTeammates { /** The type of the object - `admin.list`. */ - type: string; + type: "admin.list"; /** The list of teammates who participated in the conversation (wrote at least one conversation part). */ - teammates: Intercom.Reference[]; + admins: Intercom.Reference[]; } diff --git a/src/api/types/CurrentCanvas.ts b/src/api/types/CurrentCanvas.ts new file mode 100644 index 00000000..d985ac0f --- /dev/null +++ b/src/api/types/CurrentCanvas.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The current canvas that was most recently showing before the request was sent. This object mirrors the same format as the Canvas Object. + */ +export interface CurrentCanvas { + /** The canvas object representing the current canvas state. */ + current_canvas: Intercom.CanvasObject; +} diff --git a/src/api/types/CustomAttributes.ts b/src/api/types/CustomAttributes.ts index 39701626..ebc3d771 100644 --- a/src/api/types/CustomAttributes.ts +++ b/src/api/types/CustomAttributes.ts @@ -2,13 +2,7 @@ * This file was auto-generated by Fern from our API Definition. */ -import * as Intercom from "../index"; - /** - * An object containing the different custom attributes associated to the conversation as key-value pairs. For relationship attributes the value will be a list of custom object instance models. + * Custom data set for this data. */ -export type CustomAttributes = Record; - -export namespace CustomAttributes { - export type Value = string | Intercom.CustomObjectInstance; -} +export type CustomAttributes = Record; diff --git a/src/api/types/DataEventSummaryItem.ts b/src/api/types/DataEventSummaryItem.ts index ec12ab27..581a8e54 100644 --- a/src/api/types/DataEventSummaryItem.ts +++ b/src/api/types/DataEventSummaryItem.ts @@ -15,5 +15,5 @@ export interface DataEventSummaryItem { /** The number of times the event was sent */ count: number; /** The description of the event */ - description: string; + description?: string; } diff --git a/src/api/types/DataTableComponent.ts b/src/api/types/DataTableComponent.ts new file mode 100644 index 00000000..64e38560 --- /dev/null +++ b/src/api/types/DataTableComponent.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A data-table component is used for rendering a table of key-value pairs. For Messenger, text will wrap around on multiple lines. For Inbox and Frame (ie. Configure) views, we will truncate and use tooltips on hover if the text overflows. + */ +export interface DataTableComponent { + /** The items that will be rendered in the data-table. */ + items: Intercom.DataTableItem[]; +} diff --git a/src/api/types/DataTableItem.ts b/src/api/types/DataTableItem.ts new file mode 100644 index 00000000..f0b9e04f --- /dev/null +++ b/src/api/types/DataTableItem.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A field-value pair component for use in a data table. + */ +export interface DataTableItem { + /** The type of component you are rendering. */ + type: "field-value"; + /** The text of the key in your key-value pair. */ + field: string; + /** The text of the value in your key-value pair. */ + value: string; +} diff --git a/src/api/types/DividerComponent.ts b/src/api/types/DividerComponent.ts new file mode 100644 index 00000000..7b37b3c8 --- /dev/null +++ b/src/api/types/DividerComponent.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A divider component is used to separate components with a line. + */ +export interface DividerComponent { + /** A unique identifier for the component. */ + id?: string; + /** Disables a component's margin-bottom of 10px. */ + bottom_margin?: "none"; +} diff --git a/src/api/types/DropdownComponent.ts b/src/api/types/DropdownComponent.ts new file mode 100644 index 00000000..f0d36aaa --- /dev/null +++ b/src/api/types/DropdownComponent.ts @@ -0,0 +1,37 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A dropdown component is used to capture a choice from the options that you provide. + * + * When submitted, the dropdown choices are returned in a hash with the id from the dropdown component used as the key and the id from the chosen option as the value. + */ +export interface DropdownComponent { + /** A unique identifier for the component. */ + id: string; + /** The list of options. Can provide 2 to 10. */ + options: Intercom.DropdownOption[]; + /** The text shown above the dropdown. */ + label?: string; + /** The option that is selected by default. */ + value?: string; + /** Styles all options and prevents the action. Default is `unsaved`. Will be overridden if `save_state` is `saved`. */ + save_state?: DropdownComponent.SaveState; + /** Styles all options and prevents the action. Default is false. Will be overridden if save_state is saved. */ + disabled?: boolean; +} + +export namespace DropdownComponent { + /** + * Styles all options and prevents the action. Default is `unsaved`. Will be overridden if `save_state` is `saved`. + */ + export type SaveState = "unsaved" | "saved" | "failed"; + export const SaveState = { + Unsaved: "unsaved", + Saved: "saved", + Failed: "failed", + } as const; +} diff --git a/src/api/types/DropdownOption.ts b/src/api/types/DropdownOption.ts new file mode 100644 index 00000000..17bd18e5 --- /dev/null +++ b/src/api/types/DropdownOption.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A dropdown option component that can be selected. + */ +export interface DropdownOption { + /** The type of component you are rendering. */ + type: "option"; + /** A unique identifier for the option. */ + id: string; + /** The text shown within this option. */ + text: string; + /** Styles the option and prevents the action. Default is false. */ + disabled?: boolean; +} diff --git a/src/api/types/Error_.ts b/src/api/types/Error_.ts index 1526174a..a9df7613 100644 --- a/src/api/types/Error_.ts +++ b/src/api/types/Error_.ts @@ -7,7 +7,7 @@ */ export interface Error_ { /** The type is error.list */ - type: string; + type: "error.list"; /** */ request_id?: string; /** An array of one or more error objects */ diff --git a/src/api/types/Event.ts b/src/api/types/Event.ts new file mode 100644 index 00000000..b6bbe375 --- /dev/null +++ b/src/api/types/Event.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The event object enables Intercom to know more about the actions that took place in your app. Currently, you can only tell us when an app's flow has been completed. + */ +export interface Event { + /** What action took place. The only value currently accepted is `completed`. */ + type: "completed"; +} diff --git a/src/api/types/ImageComponent.ts b/src/api/types/ImageComponent.ts new file mode 100644 index 00000000..52e8d603 --- /dev/null +++ b/src/api/types/ImageComponent.ts @@ -0,0 +1,43 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * An image component is used to display an image. + * + * HTTPS Images: + * If your request URLs (or website URLs) are over HTTPS, you will need to ensure that images are loaded over HTTPS likewise. Otherwise, they will not work. + */ +export interface ImageComponent { + /** A unique identifier for the component. */ + id?: string; + /** The URL where the image is located. */ + url: string; + /** Aligns the image inside the component. Default is `left`. */ + align?: ImageComponent.Align; + /** The exact width of the image in pixels. */ + width: number; + /** The exact height of the image in pixels. */ + height: number; + /** Rounds the corners of the image. Default is `false`. */ + rounded?: boolean; + /** Disables a component's margin-bottom of 10px. */ + bottom_margin?: "none"; + /** This can be a URL Action only. */ + action?: Intercom.UrlActionComponent; +} + +export namespace ImageComponent { + /** + * Aligns the image inside the component. Default is `left`. + */ + export type Align = "left" | "center" | "right" | "full_width"; + export const Align = { + Left: "left", + Center: "center", + Right: "right", + FullWidth: "full_width", + } as const; +} diff --git a/src/api/types/InitializeRequest.ts b/src/api/types/InitializeRequest.ts new file mode 100644 index 00000000..e3d617b9 --- /dev/null +++ b/src/api/types/InitializeRequest.ts @@ -0,0 +1,25 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The request payload will have all the data needed for you to understand who is using your app, where they are using it, and how you should respond. There are different request payloads for Messenger capabilities and Inbox capabilities. + */ +export interface InitializeRequest { + /** The workspace ID of the teammate. Attribute is `app_id` for V1.2 and below. */ + workspace_id: string; + /** The Intercom hosted region that this app is located in. */ + workspace_region: string; + /** The Intercom teammate viewing the conversation. */ + admin: Intercom.Admin; + /** Key-value pairs which were given as results in response to the Configure request. */ + card_creation_options: Record; + /** The context of where the app is added, where the user last visited, and information on the Messenger settings. */ + context: Intercom.Context; + /** The conversation your app is being shown for. */ + conversation: Intercom.Conversation; + /** The contact which is currently being viewed by the teammate in the conversation details panel. We send an individual initialize request for each customer when it's a group conversation. */ + contact: Intercom.Contact; +} diff --git a/src/api/types/InitializeResponse.ts b/src/api/types/InitializeResponse.ts new file mode 100644 index 00000000..a675eeaa --- /dev/null +++ b/src/api/types/InitializeResponse.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The response object returned when initializing an app, specifying the UI for the first screen using components. + */ +export interface InitializeResponse { + /** The canvas object that defines the UI to be shown for the app. */ + canvas: Intercom.CanvasObject; +} diff --git a/src/api/types/InputComponent.ts b/src/api/types/InputComponent.ts new file mode 100644 index 00000000..cd7f86fb --- /dev/null +++ b/src/api/types/InputComponent.ts @@ -0,0 +1,40 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * An input component is used to capture text input from the end user. You can submit the value of the input by: + * + * - Adding an `action` to the input component (which will render an inline button) + * - Using a ButtonComponent (which will submit all interactive components in the canvas) + */ +export interface InputComponent { + /** A unique identifier for the component. */ + id: string; + /** The text shown above the input. */ + label?: string; + /** An example value shown inside the component when it's empty. */ + placeholder?: string; + /** An entered value which is already inside the component. */ + value?: string; + /** This can be a Submit Action, URL Action, or Sheets Action. */ + action?: Intercom.ActionComponent; + /** Styles the input. Default is `unsaved`. Prevent action with `saved`. */ + save_state?: InputComponent.SaveState; + /** Styles the input and prevents the action. Default is false. Will be overridden if save_state is saved. */ + disabled?: boolean; +} + +export namespace InputComponent { + /** + * Styles the input. Default is `unsaved`. Prevent action with `saved`. + */ + export type SaveState = "unsaved" | "saved" | "failed"; + export const SaveState = { + Unsaved: "unsaved", + Saved: "saved", + Failed: "failed", + } as const; +} diff --git a/src/api/types/ListComponent.ts b/src/api/types/ListComponent.ts new file mode 100644 index 00000000..b80e900d --- /dev/null +++ b/src/api/types/ListComponent.ts @@ -0,0 +1,27 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list component renders a list of items which you provide in an array. You can make each list item take an action by adding the relevant action object to the item: + * + * - [Trigger a submit request to be sent](https://developers.intercom.com/docs/references/canvas-kit/actioncomponents/submit-action) Inbox Messenger + * - [Open a link in a new page](https://developers.intercom.com/docs/references/canvas-kit/actioncomponents/url-action) Inbox Messenger + * - [Open a sheet](https://developers.intercom.com/docs/references/canvas-kit/actioncomponents/sheets-action) Messenger + */ +export interface ListComponent { + /** The items that will be rendered in the list. */ + items: ListComponent.Items.Item[]; + /** Styles all list items and prevents the action. Default is `false`. */ + disabled?: boolean; +} + +export namespace ListComponent { + export type Items = Items.Item[]; + + export namespace Items { + export type Item = Intercom.ListItemWithImage | Intercom.ListItemWithoutImage; + } +} diff --git a/src/api/types/ListItem.ts b/src/api/types/ListItem.ts new file mode 100644 index 00000000..d85d821c --- /dev/null +++ b/src/api/types/ListItem.ts @@ -0,0 +1,27 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A list item component that can be rendered in a list. + */ +export interface ListItem { + /** The type of component you are rendering. */ + type: "item"; + /** A unique identifier for the item. */ + id: string; + /** The text shown as the title for the item. */ + title: string; + /** The text shown underneath the item's title. */ + subtitle?: string; + /** The text shown next to the subtitle, separates by a bullet. */ + tertiary_text?: string; + /** Rounds the corners of the image. Default is `false`. */ + rounded_image?: boolean; + /** Styles all list items and prevents the action. Default is `false`. */ + disabled?: boolean; + /** This can be a Submit Action, URL Action, or Sheets Action. */ + action?: Intercom.ActionComponent; +} diff --git a/src/api/types/ListItemWithImage.ts b/src/api/types/ListItemWithImage.ts new file mode 100644 index 00000000..4d62f441 --- /dev/null +++ b/src/api/types/ListItemWithImage.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +export interface ListItemWithImage extends Intercom.ListItem { + /** An image that will be displayed to the left of the item. */ + image: string; + /** The exact width of the image in pixels. */ + image_width: number; + /** The exact height of the image in pixels. */ + image_height: number; +} diff --git a/src/api/types/ListItemWithoutImage.ts b/src/api/types/ListItemWithoutImage.ts new file mode 100644 index 00000000..d5f911ec --- /dev/null +++ b/src/api/types/ListItemWithoutImage.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +export interface ListItemWithoutImage extends Intercom.ListItem { + /** An image that will be displayed to the left of the item. */ + image?: string; + /** The exact width of the image in pixels. */ + image_width?: number; + /** The exact height of the image in pixels. */ + image_height?: number; +} diff --git a/src/api/types/LiveCanvasRequest.ts b/src/api/types/LiveCanvasRequest.ts new file mode 100644 index 00000000..4c90a1d5 --- /dev/null +++ b/src/api/types/LiveCanvasRequest.ts @@ -0,0 +1,23 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * Canvases are static by default and require a new request to come through in order to update them. Live canvases however will make requests every time the card is viewed without any interaction needed, meaning the canvas can be kept up-to-date with no action from the user. + * + * This works for every Messenger request that you can respond with a canvas object to. Instead of returning the content object within the canvas object, you should provide a `content_url` attribute instead with the value being the URL you want us to send a POST request to when someone views the app. + */ +export interface LiveCanvasRequest { + /** The workspace ID of the teammate. Attribute is `app_id` for V1.2 and below. */ + workspace_id: string; + /** The Intercom hosted region that this app is located in. */ + workspace_region: string; + /** The current_canvas the teammate can see. */ + canvas: Intercom.CanvasObject; + /** The context of where the app is added, where the user last visited, and information on the Messenger settings. */ + context: Intercom.Context; + /** The contact who viewed the card. */ + contact: Intercom.Contact; +} diff --git a/src/api/types/LiveCanvasResponse.ts b/src/api/types/LiveCanvasResponse.ts new file mode 100644 index 00000000..fca96ef7 --- /dev/null +++ b/src/api/types/LiveCanvasResponse.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The response object returned when responding to a Live Canvas request. This contains the components you want to show. + */ +export interface LiveCanvasResponse { + /** The content object that defines the components to be shown. */ + content: Intercom.ContentObject; +} diff --git a/src/api/types/MultipleFilterSearchRequest.ts b/src/api/types/MultipleFilterSearchRequest.ts index cdaf21d8..8554380e 100644 --- a/src/api/types/MultipleFilterSearchRequest.ts +++ b/src/api/types/MultipleFilterSearchRequest.ts @@ -10,7 +10,7 @@ import * as Intercom from "../index"; export interface MultipleFilterSearchRequest { /** An operator to allow boolean inspection between multiple fields. */ operator?: MultipleFilterSearchRequest.Operator; - value?: MultipleFilterSearchRequest.Value; + value?: Intercom.MultipleOrSingleFilterSearchRequest[]; } export namespace MultipleFilterSearchRequest { @@ -22,11 +22,4 @@ export namespace MultipleFilterSearchRequest { And: "AND", Or: "OR", } as const; - export type Value = - /** - * Add mutiple filters. */ - | Intercom.MultipleFilterSearchRequest[] - /** - * Add a single filter field. */ - | Intercom.SingleFilterSearchRequest[]; } diff --git a/src/api/types/MultipleOrSingleFilterSearchRequest.ts b/src/api/types/MultipleOrSingleFilterSearchRequest.ts new file mode 100644 index 00000000..05b7916a --- /dev/null +++ b/src/api/types/MultipleOrSingleFilterSearchRequest.ts @@ -0,0 +1,9 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +export type MultipleOrSingleFilterSearchRequest = + | Intercom.MultipleFilterSearchRequest + | Intercom.SingleFilterSearchRequest; diff --git a/src/api/types/ResultsResponse.ts b/src/api/types/ResultsResponse.ts new file mode 100644 index 00000000..118b3e37 --- /dev/null +++ b/src/api/types/ResultsResponse.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The results object should be sent when you want to end configuration of the app and trigger the [Initialize request](https://developers.intercom.com/docs/canvas-kit/#initialize) to be sent. You provide the key-value pairs of data you want access to and we will send these in the Initialize request within a [card_creation_options object](https://developers.intercom.com/docs/references/canvas-kit/requestobjects/card-creation-options/#card-creation-options). + */ +export interface ResultsResponse { + /** Key-value pairs of data you want access to in the Initialize request */ + results: Record; +} diff --git a/src/api/types/SheetActionComponent.ts b/src/api/types/SheetActionComponent.ts new file mode 100644 index 00000000..655b7039 --- /dev/null +++ b/src/api/types/SheetActionComponent.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A sheet action opens the link you give within the Messenger as an embedded iframe. + * + * [More on how Sheets work is in our Canvas Kit documentation.](https://developers.intercom.com/docs/canvas-kit#sheets-optional) + */ +export interface SheetActionComponent { + /** The link which hosts your sheet. */ + url: string; +} diff --git a/src/api/types/SingleFilterSearchRequest.ts b/src/api/types/SingleFilterSearchRequest.ts index 95f869cf..94aa9dfc 100644 --- a/src/api/types/SingleFilterSearchRequest.ts +++ b/src/api/types/SingleFilterSearchRequest.ts @@ -11,7 +11,7 @@ export interface SingleFilterSearchRequest { /** The accepted operators you can use to define how you want to search for the value. */ operator?: SingleFilterSearchRequest.Operator; /** The value that you want to search on. */ - value?: string; + value?: SingleFilterSearchRequest.Value; } export namespace SingleFilterSearchRequest { @@ -31,4 +31,8 @@ export namespace SingleFilterSearchRequest { StartsWith: "^", EndsWith: "$", } as const; + /** + * The value that you want to search on. + */ + export type Value = string | number | string[] | number[]; } diff --git a/src/api/types/SingleSelectComponent.ts b/src/api/types/SingleSelectComponent.ts new file mode 100644 index 00000000..04f9cf85 --- /dev/null +++ b/src/api/types/SingleSelectComponent.ts @@ -0,0 +1,42 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * A single-select component is used to capture a choice from up to 10 options that you provide. You can submit the value of the select option by: + * + * - Adding an `action` to the single-select component + * - Using a ButtonComponent (which will submit all interactive components in the canvas) + * + * When a submit action takes place, the results are given in a hash with the `id` from the single-select component used as the key and the `id` from the chosen option as the value. + */ +export interface SingleSelectComponent { + /** A unique identifier for the component. */ + id: string; + /** The list of options. Can provide 2 to 10. */ + options: Intercom.SingleSelectOption[]; + /** The text shown above the options. */ + label?: string; + /** The option that is selected by default. */ + value?: string; + /** Styles the input. Default is `unsaved`. Prevent action with `saved`. */ + save_state?: SingleSelectComponent.SaveState; + /** Styles all options and prevents the action. Default is false. Will be overridden if save_state is saved. */ + disabled?: boolean; + /** This can be a Submit Action, URL Action, or Sheets Action. */ + action?: Intercom.ActionComponent; +} + +export namespace SingleSelectComponent { + /** + * Styles the input. Default is `unsaved`. Prevent action with `saved`. + */ + export type SaveState = "unsaved" | "saved" | "failed"; + export const SaveState = { + Unsaved: "unsaved", + Saved: "saved", + Failed: "failed", + } as const; +} diff --git a/src/api/types/SingleSelectOption.ts b/src/api/types/SingleSelectOption.ts new file mode 100644 index 00000000..4fc06e87 --- /dev/null +++ b/src/api/types/SingleSelectOption.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A single select option component that can be selected. + */ +export interface SingleSelectOption { + /** The type of component you are rendering. */ + type: "option"; + /** A unique identifier for the option. */ + id: string; + /** The text shown within this option. */ + text: string; + /** Styles the option and prevents the action. Default is false. */ + disabled?: boolean; +} diff --git a/src/api/types/SocialProfile.ts b/src/api/types/SocialProfile.ts index be480217..90befe00 100644 --- a/src/api/types/SocialProfile.ts +++ b/src/api/types/SocialProfile.ts @@ -7,7 +7,7 @@ */ export interface SocialProfile { /** value is "social_profile" */ - type: string; + type: "social_profile"; /** The name of the Social media profile */ name: string; /** The name of the Social media profile */ diff --git a/src/api/types/SpacerComponent.ts b/src/api/types/SpacerComponent.ts new file mode 100644 index 00000000..d8215aa3 --- /dev/null +++ b/src/api/types/SpacerComponent.ts @@ -0,0 +1,27 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A spacer component is used to create empty space between components. + */ +export interface SpacerComponent { + /** A unique identifier for the component. */ + id?: string; + /** The amount of space between components. Default is `s`. */ + size?: SpacerComponent.Size; +} + +export namespace SpacerComponent { + /** + * The amount of space between components. Default is `s`. + */ + export type Size = "xs" | "s" | "m" | "l" | "xl"; + export const Size = { + Xs: "xs", + S: "s", + M: "m", + L: "l", + Xl: "xl", + } as const; +} diff --git a/src/api/types/SubmitActionComponent.ts b/src/api/types/SubmitActionComponent.ts new file mode 100644 index 00000000..c1eec8c9 --- /dev/null +++ b/src/api/types/SubmitActionComponent.ts @@ -0,0 +1,8 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A submit action triggers a [Submit Request](https://developers.intercom.com/docs/canvas-kit#submit-request) to be sent. This request will include all values which have been entered into all the interactive components on the current canvas. + */ +export interface SubmitActionComponent {} diff --git a/src/api/types/SubmitRequest.ts b/src/api/types/SubmitRequest.ts new file mode 100644 index 00000000..38aa3f2c --- /dev/null +++ b/src/api/types/SubmitRequest.ts @@ -0,0 +1,31 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The Submit request is triggered when a component with a submit action is interacted with in Messenger Inbox. + */ +export interface SubmitRequest { + /** The workspace ID of the teammate. Attribute is `app_id` for V1.2 and below. */ + workspace_id: string; + /** The Intercom hosted region that this app is located in. */ + workspace_region: string; + /** The Intercom teammate viewing the conversation. */ + admin: Intercom.Admin; + /** The id of the component clicked by the teammate to trigger the request. */ + component_id: string; + /** The context of where the app is added, where the user last visited, and information on the Messenger settings. */ + context: Intercom.Context; + /** The conversation where your app is being shown. */ + conversation: Intercom.Conversation; + /** The current canvas the teammate can see. */ + current_canvas: Intercom.CurrentCanvas; + /** The contact which is currently being viewed by the teammate in the conversation details panel. */ + contact: Intercom.Contact; + /** A list of key/value pairs of data, inputted by the teammate on the current canvas. */ + input_values: Record; + /** The user who took the action. */ + user: Intercom.Contact; +} diff --git a/src/api/types/SubmitResponse.ts b/src/api/types/SubmitResponse.ts new file mode 100644 index 00000000..9e2ff974 --- /dev/null +++ b/src/api/types/SubmitResponse.ts @@ -0,0 +1,25 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +/** + * The response object returned when submitting an app interaction. This will replace the previous canvas that was visible until the app was interacted with. + * + * You can optionally provide an event object with the attribute `type` given as `completed` to tell us if the app has completed its purpose. For example, an email collector app would be complete when the end-user submits their email address. + * + * Apps in conversation details can also optionally insert an app into the conversation reply: + * + * 1. You respond with a card_creation_options object (https://developers.intercom.com/canvas-kit-reference/reference/card-creation-options) + * 2. We send a request to the initialize URL for Messenger capabilities (https://developers.intercom.com/docs/build-an-integration/getting-started/build-an-app-for-your-messenger/request-flows) with the card_creation_options object present + * 3. You respond with a canvas object with the components you want to insert into the conversation reply + */ +export interface SubmitResponse { + /** The canvas object that defines the new UI to be shown. */ + canvas: Intercom.CanvasObject; + /** Optional. Key-value pairs that will be sent in the initialize request to insert an app into the conversation reply. */ + card_creation_options?: Record; + /** Optional. Indicates if the app has completed its purpose. */ + event?: Intercom.Event; +} diff --git a/src/api/types/TextAreaComponent.ts b/src/api/types/TextAreaComponent.ts new file mode 100644 index 00000000..1a2d215c --- /dev/null +++ b/src/api/types/TextAreaComponent.ts @@ -0,0 +1,23 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A text area component is used to capture a large amount of text as input with a multi-line text box. You can submit the value of the text area by: + * + * - Using a ButtonComponent (which will submit all interactive components in the canvas) + */ +export interface TextAreaComponent { + /** A unique identifier for the component. */ + id: string; + /** The text shown above the text area. */ + label?: string; + /** An example value shown inside the component when it's empty. */ + placeholder?: string; + /** An entered value which is already inside the component. */ + value?: string; + /** Styles the input as failed. Default is false. */ + error?: boolean; + /** Styles the input and prevents the action. Default is false. */ + disabled?: boolean; +} diff --git a/src/api/types/TextComponent.ts b/src/api/types/TextComponent.ts new file mode 100644 index 00000000..1fe6bce2 --- /dev/null +++ b/src/api/types/TextComponent.ts @@ -0,0 +1,41 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A text component is used for rendering blocks of text. Links and bold font can be rendered through Markdown. There are different styles provided which edit the color, weight, and font size. These cannot be edited through Markdown. + */ +export interface TextComponent { + /** A unique identifier for the component. */ + id?: string; + /** The text that will be rendered. */ + text: string; + /** Aligns the text. Default is `left`. */ + align?: TextComponent.Align; + /** Styles the text. Default is `paragraph`. */ + style?: TextComponent.Style; + /** Disables a component's margin-bottom of 10px. */ + bottom_margin?: "none"; +} + +export namespace TextComponent { + /** + * Aligns the text. Default is `left`. + */ + export type Align = "left" | "center" | "right"; + export const Align = { + Left: "left", + Center: "center", + Right: "right", + } as const; + /** + * Styles the text. Default is `paragraph`. + */ + export type Style = "header" | "paragraph" | "muted" | "error"; + export const Style = { + Header: "header", + Paragraph: "paragraph", + Muted: "muted", + Error: "error", + } as const; +} diff --git a/src/api/types/TicketTypeAttribute.ts b/src/api/types/TicketTypeAttribute.ts index d86c1807..a0267806 100644 --- a/src/api/types/TicketTypeAttribute.ts +++ b/src/api/types/TicketTypeAttribute.ts @@ -17,7 +17,7 @@ export interface TicketTypeAttribute { /** The description of the ticket type attribute */ description: string; /** The type of the data attribute (allowed values: "string list integer decimal boolean datetime files") */ - data_type: string; + data_type: TicketTypeAttribute.DataType; /** Input options for the attribute */ input_options: Record; /** The order of the attribute against other attributes */ @@ -41,3 +41,19 @@ export interface TicketTypeAttribute { /** The date and time the ticket type attribute was last updated. */ updated_at?: number; } + +export namespace TicketTypeAttribute { + /** + * The type of the data attribute (allowed values: "string list integer decimal boolean datetime files") + */ + export type DataType = "string" | "list" | "integer" | "decimal" | "boolean" | "datetime" | "files"; + export const DataType = { + String: "string", + List: "list", + Integer: "integer", + Decimal: "decimal", + Boolean: "boolean", + Datetime: "datetime", + Files: "files", + } as const; +} diff --git a/src/api/types/UrlActionComponent.ts b/src/api/types/UrlActionComponent.ts new file mode 100644 index 00000000..34d44dcf --- /dev/null +++ b/src/api/types/UrlActionComponent.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A URL action opens a given link in a new browser tab. + */ +export interface UrlActionComponent { + /** The link you want to open. */ + url: string; +} diff --git a/src/api/types/Visitor.ts b/src/api/types/Visitor.ts index d70f2bec..6865b074 100644 --- a/src/api/types/Visitor.ts +++ b/src/api/types/Visitor.ts @@ -9,7 +9,7 @@ import * as Intercom from "../index"; */ export interface Visitor { /** Value is 'visitor' */ - type: string; + type: "visitor"; /** The Intercom defined id representing the Visitor. */ id: string; /** Automatically generated identifier for the Visitor. */ @@ -53,7 +53,7 @@ export interface Visitor { tags?: Visitor.Tags; segments?: Visitor.Segments; /** The custom attributes you have set on the Visitor. */ - custom_attributes?: Record; + custom_attributes?: Record; /** The referer of the visitor. */ referrer?: string; /** The utm_campaign of the visitor. */ diff --git a/src/api/types/index.ts b/src/api/types/index.ts index 589b9a06..03b2def2 100644 --- a/src/api/types/index.ts +++ b/src/api/types/index.ts @@ -1,3 +1,4 @@ +export * from "./ActionComponent"; export * from "./ActivityLog"; export * from "./ActivityLogList"; export * from "./ActivityLogMetadata"; @@ -13,15 +14,23 @@ export * from "./ArticleList"; export * from "./ArticleStatistics"; export * from "./ArticleTranslatedContent"; export * from "./AssignConversationRequest"; +export * from "./ButtonComponent"; +export * from "./CanvasObject"; +export * from "./CheckboxOption"; +export * from "./CheckboxComponent"; export * from "./CloseConversationRequest"; export * from "./CollectionList"; export * from "./CompanyAttachedContacts"; export * from "./CompanyAttachedSegments"; export * from "./CompanyList"; export * from "./CompanyScroll"; +export * from "./Component"; +export * from "./ConfigureRequest"; +export * from "./ConfigureResponse"; export * from "./ContactArchived"; export * from "./ContactAttachedCompanies"; export * from "./ContactCompanies"; +export * from "./ContactCompany"; export * from "./ContactDeleted"; export * from "./ContactList"; export * from "./ContactLocation"; @@ -41,7 +50,9 @@ export * from "./ContactSocialProfiles"; export * from "./ContactSubscriptionTypes"; export * from "./ContactTags"; export * from "./ContactUnarchived"; +export * from "./ContentObject"; export * from "./ContentSourcesList"; +export * from "./Context"; export * from "./ConversationAttachmentFiles"; export * from "./ConversationContacts"; export * from "./ConversationFirstContactReply"; @@ -58,24 +69,41 @@ export * from "./CreateDataEventRequest"; export * from "./CreateMessageRequest"; export * from "./CreateOrUpdateTagRequest"; export * from "./CreateTicketReplyWithCommentRequest"; +export * from "./CurrentCanvas"; export * from "./CursorPages"; -export * from "./CustomAttributes"; export * from "./CustomerRequest"; export * from "./DataAttributeList"; export * from "./DataEventList"; export * from "./DataEventSummary"; export * from "./DataEventSummaryItem"; export * from "./DataExportCsv"; +export * from "./DataTableItem"; +export * from "./DataTableComponent"; export * from "./DeletedArticleObject"; export * from "./DeletedCollectionObject"; export * from "./DeletedCompanyObject"; export * from "./DeletedObject"; +export * from "./DividerComponent"; +export * from "./DropdownOption"; +export * from "./DropdownComponent"; export * from "./Error_"; +export * from "./Event"; export * from "./FileAttribute"; export * from "./GroupContent"; export * from "./GroupTranslatedContent"; +export * from "./ImageComponent"; +export * from "./InitializeRequest"; +export * from "./InitializeResponse"; +export * from "./InputComponent"; export * from "./LinkedObject"; export * from "./LinkedObjectList"; +export * from "./ListItem"; +export * from "./ListItemWithImage"; +export * from "./ListItemWithoutImage"; +export * from "./ListComponent"; +export * from "./LiveCanvasRequest"; +export * from "./LiveCanvasResponse"; +export * from "./MultipleOrSingleFilterSearchRequest"; export * from "./MultipleFilterSearchRequest"; export * from "./NewsItemRequest"; export * from "./NoteList"; @@ -88,13 +116,21 @@ export * from "./PhoneSwitch"; export * from "./RedactConversationRequest"; export * from "./Reference"; export * from "./ReplyConversationRequest"; +export * from "./ResultsResponse"; export * from "./SearchRequest"; export * from "./SegmentList"; +export * from "./SheetActionComponent"; export * from "./SingleFilterSearchRequest"; +export * from "./SingleSelectOption"; +export * from "./SingleSelectComponent"; export * from "./SlaApplied"; export * from "./SnoozeConversationRequest"; export * from "./SocialProfile"; +export * from "./SpacerComponent"; export * from "./StartingAfterPaging"; +export * from "./SubmitActionComponent"; +export * from "./SubmitRequest"; +export * from "./SubmitResponse"; export * from "./SubscriptionTypeList"; export * from "./TagCompanyRequest"; export * from "./TagList"; @@ -102,6 +138,8 @@ export * from "./TagMultipleUsersRequest"; export * from "./Tags"; export * from "./TeamList"; export * from "./TeamPriorityLevel"; +export * from "./TextComponent"; +export * from "./TextAreaComponent"; export * from "./TicketCustomAttributes"; export * from "./TicketList"; export * from "./TicketPartAuthor"; @@ -114,5 +152,7 @@ export * from "./TicketTypeList"; export * from "./Translation"; export * from "./UntagCompanyRequest"; export * from "./UpdateVisitorRequest"; +export * from "./UrlActionComponent"; export * from "./Visitor"; export * from "./VisitorDeletedObject"; +export * from "./CustomAttributes"; diff --git a/src/version.ts b/src/version.ts index 7ba3a938..0105d13d 100644 --- a/src/version.ts +++ b/src/version.ts @@ -1 +1 @@ -export const SDK_VERSION = "6.0.0"; +export const SDK_VERSION = "6.1.0"; diff --git a/yarn.lock b/yarn.lock index 281e9091..a53e591d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -10,7 +10,7 @@ "@jridgewell/gen-mapping" "^0.3.5" "@jridgewell/trace-mapping" "^0.3.24" -"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.12.13", "@babel/code-frame@^7.25.9", "@babel/code-frame@^7.26.0", "@babel/code-frame@^7.26.2": +"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.12.13", "@babel/code-frame@^7.26.2": version "7.26.2" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.26.2.tgz#4b5fab97d33338eff916235055f0ebc21e573a85" integrity sha512-RJlIHRueQgwWitWgF8OdFYGZX328Ax5BCemNGlqHfplnRT9ESi8JkFlvaVYbS+UubVY6dpv87Fs2u5M29iNFVQ== @@ -19,49 +19,49 @@ js-tokens "^4.0.0" picocolors "^1.0.0" -"@babel/compat-data@^7.25.9": - version "7.26.3" - resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.26.3.tgz#99488264a56b2aded63983abd6a417f03b92ed02" - integrity sha512-nHIxvKPniQXpmQLb0vhY3VaFb3S0YrTAwpOWJZh1wn3oJPjJk9Asva204PsBdmAE8vpzfHudT8DB0scYvy9q0g== +"@babel/compat-data@^7.26.5": + version "7.26.8" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.26.8.tgz#821c1d35641c355284d4a870b8a4a7b0c141e367" + integrity sha512-oH5UPLMWR3L2wEFLnFJ1TZXqHufiTKAiLfqw5zkhS4dKXLJ10yVztfil/twG8EDTA4F/tvVNw9nOl4ZMslB8rQ== "@babel/core@^7.11.6", "@babel/core@^7.12.3", "@babel/core@^7.23.9": - version "7.26.0" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.26.0.tgz#d78b6023cc8f3114ccf049eb219613f74a747b40" - integrity sha512-i1SLeK+DzNnQ3LL/CswPCa/E5u4lh1k6IAEphON8F+cXt0t9euTshDru0q7/IqMa1PMPz5RnHuHscF8/ZJsStg== + version "7.26.10" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.26.10.tgz#5c876f83c8c4dcb233ee4b670c0606f2ac3000f9" + integrity sha512-vMqyb7XCDMPvJFFOaT9kxtiRh42GwlZEg1/uIgtZshS5a/8OaduUfCi7kynKgc3Tw/6Uo2D+db9qBttghhmxwQ== dependencies: "@ampproject/remapping" "^2.2.0" - "@babel/code-frame" "^7.26.0" - "@babel/generator" "^7.26.0" - "@babel/helper-compilation-targets" "^7.25.9" + "@babel/code-frame" "^7.26.2" + "@babel/generator" "^7.26.10" + "@babel/helper-compilation-targets" "^7.26.5" "@babel/helper-module-transforms" "^7.26.0" - "@babel/helpers" "^7.26.0" - "@babel/parser" "^7.26.0" - "@babel/template" "^7.25.9" - "@babel/traverse" "^7.25.9" - "@babel/types" "^7.26.0" + "@babel/helpers" "^7.26.10" + "@babel/parser" "^7.26.10" + "@babel/template" "^7.26.9" + "@babel/traverse" "^7.26.10" + "@babel/types" "^7.26.10" convert-source-map "^2.0.0" debug "^4.1.0" gensync "^1.0.0-beta.2" json5 "^2.2.3" semver "^6.3.1" -"@babel/generator@^7.26.0", "@babel/generator@^7.26.3", "@babel/generator@^7.7.2": - version "7.26.3" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.26.3.tgz#ab8d4360544a425c90c248df7059881f4b2ce019" - integrity sha512-6FF/urZvD0sTeO7k6/B15pMLC4CHUv1426lzr3N01aHJTl046uCAh9LXW/fzeXXjPNCJ6iABW5XaWOsIZB93aQ== +"@babel/generator@^7.26.10", "@babel/generator@^7.7.2": + version "7.26.10" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.26.10.tgz#a60d9de49caca16744e6340c3658dfef6138c3f7" + integrity sha512-rRHT8siFIXQrAYOYqZQVsAr8vJ+cBNqcVAY6m5V8/4QqzaPl+zDBe6cLEPRDuNOUf3ww8RfJVlOyQMoSI+5Ang== dependencies: - "@babel/parser" "^7.26.3" - "@babel/types" "^7.26.3" + "@babel/parser" "^7.26.10" + "@babel/types" "^7.26.10" "@jridgewell/gen-mapping" "^0.3.5" "@jridgewell/trace-mapping" "^0.3.25" jsesc "^3.0.2" -"@babel/helper-compilation-targets@^7.25.9": - version "7.25.9" - resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.25.9.tgz#55af025ce365be3cdc0c1c1e56c6af617ce88875" - integrity sha512-j9Db8Suy6yV/VHa4qzrj9yZfZxhLWQdVnRlXxmKLYlhWUVB1sB2G5sxuWYXk/whHD9iW76PmNzxZ4UCnTQTVEQ== +"@babel/helper-compilation-targets@^7.26.5": + version "7.26.5" + resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.26.5.tgz#75d92bb8d8d51301c0d49e52a65c9a7fe94514d8" + integrity sha512-IXuyn5EkouFJscIDuFF5EsiSolseme1s0CZB+QxVugqJLYmKdxI1VfIBOst0SUu4rnk2Z7kqTwmoO1lp3HIfnA== dependencies: - "@babel/compat-data" "^7.25.9" + "@babel/compat-data" "^7.26.5" "@babel/helper-validator-option" "^7.25.9" browserslist "^4.24.0" lru-cache "^5.1.1" @@ -85,9 +85,9 @@ "@babel/traverse" "^7.25.9" "@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.14.5", "@babel/helper-plugin-utils@^7.25.9", "@babel/helper-plugin-utils@^7.8.0": - version "7.25.9" - resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.25.9.tgz#9cbdd63a9443a2c92a725cca7ebca12cc8dd9f46" - integrity sha512-kSMlyUVdWe25rEsRGviIgOWnoT/nfABVWlqt9N19/dIPWViAOW2s9wznP5tURbs/IDuNk4gPy3YdYRgH3uxhBw== + version "7.26.5" + resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.26.5.tgz#18580d00c9934117ad719392c4f6585c9333cc35" + integrity sha512-RS+jZcRdZdRFzMyr+wcsaqOmld1/EqTghfaBGQQd/WnRdzdlvSZ//kF7U8VQTxf1ynZ4cjUcYgjVGx13ewNPMg== "@babel/helper-string-parser@^7.25.9": version "7.25.9" @@ -104,20 +104,20 @@ resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.25.9.tgz#86e45bd8a49ab7e03f276577f96179653d41da72" integrity sha512-e/zv1co8pp55dNdEcCynfj9X7nyUKUXoUEwfXqaZt0omVOmDe9oOTdKStH4GmAw6zxMFs50ZayuMfHDKlO7Tfw== -"@babel/helpers@^7.26.0": - version "7.26.0" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.26.0.tgz#30e621f1eba5aa45fe6f4868d2e9154d884119a4" - integrity sha512-tbhNuIxNcVb21pInl3ZSjksLCvgdZy9KwJ8brv993QtIVKJBBkYXz4q4ZbAv31GdnC+R90np23L5FbEBlthAEw== +"@babel/helpers@^7.26.10": + version "7.26.10" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.26.10.tgz#6baea3cd62ec2d0c1068778d63cb1314f6637384" + integrity sha512-UPYc3SauzZ3JGgj87GgZ89JVdC5dj0AoetR5Bw6wj4niittNyFh6+eOGonYvJ1ao6B8lEa3Q3klS7ADZ53bc5g== dependencies: - "@babel/template" "^7.25.9" - "@babel/types" "^7.26.0" + "@babel/template" "^7.26.9" + "@babel/types" "^7.26.10" -"@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.20.7", "@babel/parser@^7.23.9", "@babel/parser@^7.25.9", "@babel/parser@^7.26.0", "@babel/parser@^7.26.3": - version "7.26.3" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.26.3.tgz#8c51c5db6ddf08134af1ddbacf16aaab48bac234" - integrity sha512-WJ/CvmY8Mea8iDXo6a7RK2wbmJITT5fN3BEkRuFlxVyNx8jOKIIhmC4fSkTcPcf8JyavbBwIe6OpiCOBXt/IcA== +"@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.20.7", "@babel/parser@^7.23.9", "@babel/parser@^7.26.10", "@babel/parser@^7.26.9": + version "7.26.10" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.26.10.tgz#e9bdb82f14b97df6569b0b038edd436839c57749" + integrity sha512-6aQR2zGE/QFi8JpDLjUZEPYOs7+mhKXm86VaKFiLP35JQwQb6bwUE+XbvkH0EptsYhbNBSUGaUBLKqxH1xSgsA== dependencies: - "@babel/types" "^7.26.3" + "@babel/types" "^7.26.10" "@babel/plugin-syntax-async-generators@^7.8.4": version "7.8.4" @@ -238,32 +238,32 @@ dependencies: "@babel/helper-plugin-utils" "^7.25.9" -"@babel/template@^7.25.9", "@babel/template@^7.3.3": - version "7.25.9" - resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.25.9.tgz#ecb62d81a8a6f5dc5fe8abfc3901fc52ddf15016" - integrity sha512-9DGttpmPvIxBb/2uwpVo3dqJ+O6RooAFOS+lB+xDqoE2PVCE8nfoHMdZLpfCQRLwvohzXISPZcgxt80xLfsuwg== +"@babel/template@^7.26.9", "@babel/template@^7.3.3": + version "7.26.9" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.26.9.tgz#4577ad3ddf43d194528cff4e1fa6b232fa609bb2" + integrity sha512-qyRplbeIpNZhmzOysF/wFMuP9sctmh2cFzRAZOn1YapxBsE1i9bJIY586R/WBLfLcmcBlM8ROBiQURnnNy+zfA== dependencies: - "@babel/code-frame" "^7.25.9" - "@babel/parser" "^7.25.9" - "@babel/types" "^7.25.9" + "@babel/code-frame" "^7.26.2" + "@babel/parser" "^7.26.9" + "@babel/types" "^7.26.9" -"@babel/traverse@^7.25.9": - version "7.26.4" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.26.4.tgz#ac3a2a84b908dde6d463c3bfa2c5fdc1653574bd" - integrity sha512-fH+b7Y4p3yqvApJALCPJcwb0/XaOSgtK4pzV6WVjPR5GLFQBRI7pfoX2V2iM48NXvX07NUxxm1Vw98YjqTcU5w== +"@babel/traverse@^7.25.9", "@babel/traverse@^7.26.10": + version "7.26.10" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.26.10.tgz#43cca33d76005dbaa93024fae536cc1946a4c380" + integrity sha512-k8NuDrxr0WrPH5Aupqb2LCVURP/S0vBEn5mK6iH+GIYob66U5EtoZvcdudR2jQ4cmTwhEwW1DLB+Yyas9zjF6A== dependencies: "@babel/code-frame" "^7.26.2" - "@babel/generator" "^7.26.3" - "@babel/parser" "^7.26.3" - "@babel/template" "^7.25.9" - "@babel/types" "^7.26.3" + "@babel/generator" "^7.26.10" + "@babel/parser" "^7.26.10" + "@babel/template" "^7.26.9" + "@babel/types" "^7.26.10" debug "^4.3.1" globals "^11.1.0" -"@babel/types@^7.0.0", "@babel/types@^7.20.7", "@babel/types@^7.25.9", "@babel/types@^7.26.0", "@babel/types@^7.26.3", "@babel/types@^7.3.3": - version "7.26.3" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.26.3.tgz#37e79830f04c2b5687acc77db97fbc75fb81f3c0" - integrity sha512-vN5p+1kl59GVKMvTHt55NzzmYVxprfJD+ql7U9NFIfKCBkYE55LYtS+WtPlaYOyzydrKI8Nezd+aZextrd+FMA== +"@babel/types@^7.0.0", "@babel/types@^7.20.7", "@babel/types@^7.25.9", "@babel/types@^7.26.10", "@babel/types@^7.26.9", "@babel/types@^7.3.3": + version "7.26.10" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.26.10.tgz#396382f6335bd4feb65741eacfc808218f859259" + integrity sha512-emqcG3vHrpxUKTrxcblR36dcrcoRDvKmnL/dCL6ZsHaShW80qxCAcNhzQZrpeM765VzEos+xOi4s+r4IXzTwdQ== dependencies: "@babel/helper-string-parser" "^7.25.9" "@babel/helper-validator-identifier" "^7.25.9" @@ -642,7 +642,7 @@ "@types/tough-cookie" "*" parse5 "^7.0.0" -"@types/json-schema@*", "@types/json-schema@^7.0.8", "@types/json-schema@^7.0.9": +"@types/json-schema@*", "@types/json-schema@^7.0.9": version "7.0.15" resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.15.tgz#596a1747233694d50f6ad8a7869fcb6f56cf5841" integrity sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA== @@ -656,9 +656,9 @@ form-data "^4.0.0" "@types/node@*": - version "22.10.2" - resolved "https://registry.yarnpkg.com/@types/node/-/node-22.10.2.tgz#a485426e6d1fdafc7b0d4c7b24e2c78182ddabb9" - integrity sha512-Xxr6BBRCAOQixvonOye19wnzyDiUtTeqldOOmj3CkeblonbccA12PFwlufvRdrpjXxqnmUaeiU5EOA+7s5diUQ== + version "22.13.10" + resolved "https://registry.yarnpkg.com/@types/node/-/node-22.13.10.tgz#df9ea358c5ed991266becc3109dc2dc9125d77e4" + integrity sha512-I6LPUvlRH+O6VRUqYOcMudhaIdUVWfsjnZavnsraHvpBwaEyMN29ry+0UVJhImYL16xsscu0aske3yA+uPOWfw== dependencies: undici-types "~6.20.0" @@ -866,9 +866,9 @@ acorn-walk@^8.0.2: acorn "^8.11.0" acorn@^8.1.0, acorn@^8.11.0, acorn@^8.14.0, acorn@^8.8.1, acorn@^8.8.2: - version "8.14.0" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.14.0.tgz#063e2c70cac5fb4f6467f0b11152e04c682795b0" - integrity sha512-cl669nCJTZBsL97OF4kUQm5g5hC2uihk0NxY3WENAC0TYdILVkAyHymAntgxGkl7K+t0cXIrH5siy5S4XkFycA== + version "8.14.1" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.14.1.tgz#721d5dc10f7d5b5609a891773d47731796935dfb" + integrity sha512-OvQ/2pUDKmgfCg++xsTX1wGxfTaszcHVcTctW4UJB4hibJx2HXxxO5UmVgyjMa+ZDsiaf5wWLXYpRWMmBI0QHg== agent-base@6: version "6.0.2" @@ -884,11 +884,6 @@ ajv-formats@^2.1.1: dependencies: ajv "^8.0.0" -ajv-keywords@^3.5.2: - version "3.5.2" - resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-3.5.2.tgz#31f29da5ab6e00d1c2d329acf7b5929614d5014d" - integrity sha512-5p6WTN0DdTGVQk6VjcEju19IgaHudalcfabD7yhDGeA6bcQnmL+CpveLJq/3hvfwd1aof6L386Ougkx6RfyMIQ== - ajv-keywords@^5.1.0: version "5.1.0" resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-5.1.0.tgz#69d4d385a4733cdbeab44964a1170a88f87f0e16" @@ -896,16 +891,6 @@ ajv-keywords@^5.1.0: dependencies: fast-deep-equal "^3.1.3" -ajv@^6.12.5: - version "6.12.6" - resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" - integrity sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g== - dependencies: - fast-deep-equal "^3.1.1" - fast-json-stable-stringify "^2.0.0" - json-schema-traverse "^0.4.1" - uri-js "^4.2.2" - ajv@^8.0.0, ajv@^8.9.0: version "8.17.1" resolved "https://registry.yarnpkg.com/ajv/-/ajv-8.17.1.tgz#37d9a5c776af6bc92d7f4f9510eba4c0a60d11a6" @@ -1049,9 +1034,9 @@ braces@^3.0.3: fill-range "^7.1.1" browserslist@^4.24.0: - version "4.24.3" - resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.24.3.tgz#5fc2725ca8fb3c1432e13dac278c7cc103e026d2" - integrity sha512-1CPmv8iobE2fyRMV97dAcMVegvvWKxmq94hkLiAkUGwKVTyDLw33K+ZxiFrREKmmps4rIw6grcCFCnTMSZ/YiA== + version "4.24.4" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.24.4.tgz#c6b2865a3f08bcb860a0e827389003b9fe686e4b" + integrity sha512-KDi1Ny1gSePi1vm0q4oxSF8b4DR44GF4BbmS2YdhPLOEqd8pDviZOGH/GsmRwoWJ2+5Lr085X7naowMwKHDG1A== dependencies: caniuse-lite "^1.0.30001688" electron-to-chromium "^1.5.73" @@ -1085,21 +1070,21 @@ buffer@^6.0.3: base64-js "^1.3.1" ieee754 "^1.2.1" -call-bind-apply-helpers@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.1.tgz#32e5892e6361b29b0b545ba6f7763378daca2840" - integrity sha512-BhYE+WDaywFg2TBWYNXAE+8B1ATnThNBqXHP5nQu0jWJdVvY2hvkpyB3qOmtmDePiS5/BDQ8wASEWGMWRG148g== +call-bind-apply-helpers@^1.0.1, call-bind-apply-helpers@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz#4b5428c222be985d79c3d82657479dbe0b59b2d6" + integrity sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ== dependencies: es-errors "^1.3.0" function-bind "^1.1.2" call-bound@^1.0.2: - version "1.0.3" - resolved "https://registry.yarnpkg.com/call-bound/-/call-bound-1.0.3.tgz#41cfd032b593e39176a71533ab4f384aa04fd681" - integrity sha512-YTd+6wGlNlPxSuri7Y6X8tY2dmm12UMH66RpKMhiX6rsk5wXXnYgbUcOt8kiS31/AjfoTOvCsE+w8nZQLQnzHA== + version "1.0.4" + resolved "https://registry.yarnpkg.com/call-bound/-/call-bound-1.0.4.tgz#238de935d2a2a692928c538c7ccfa91067fd062a" + integrity sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg== dependencies: - call-bind-apply-helpers "^1.0.1" - get-intrinsic "^1.2.6" + call-bind-apply-helpers "^1.0.2" + get-intrinsic "^1.3.0" callsites@^3.0.0: version "3.1.0" @@ -1117,9 +1102,9 @@ camelcase@^6.2.0: integrity sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA== caniuse-lite@^1.0.30001688: - version "1.0.30001690" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001690.tgz#f2d15e3aaf8e18f76b2b8c1481abde063b8104c8" - integrity sha512-5ExiE3qQN6oF8Clf8ifIDcMRCRE/dMGcETG/XGMD8/XiXm6HXQgQTh1yZYLXXpSOsEUlJm1Xr7kGULZTuGtP/w== + version "1.0.30001704" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001704.tgz#6644fe909d924ac3a7125e8a0ab6af95b1f32990" + integrity sha512-+L2IgBbV6gXB4ETf0keSvLr7JUrRVbIaB/lrQ1+z8mRcQiisG5k+lG6O4n6Y5q6f5EuNfaYXKgymucphlEXQew== chalk@^4.0.0, chalk@^4.1.0: version "4.1.2" @@ -1145,9 +1130,9 @@ ci-info@^3.2.0: integrity sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ== cjs-module-lexer@^1.0.0: - version "1.4.1" - resolved "https://registry.yarnpkg.com/cjs-module-lexer/-/cjs-module-lexer-1.4.1.tgz#707413784dbb3a72aa11c2f2b042a0bef4004170" - integrity sha512-cuSVIHi9/9E/+821Qjdvngor+xpnlwnuwIyZOaLmHBVdXL+gP+I6QQB9VkO7RI77YIcTV+S1W9AreJ5eN63JBA== + version "1.4.3" + resolved "https://registry.yarnpkg.com/cjs-module-lexer/-/cjs-module-lexer-1.4.3.tgz#0f79731eb8cfe1ec72acd4066efac9d61991b00d" + integrity sha512-9z8TZaGM1pfswYeXrUpzPrkx8UnWYdhJclsiYMm6x/w5+nN+8Tf/LnAgfLGQCm59qAOxU8WwHEq2vNwF6i4j+Q== cliui@^8.0.1: version "8.0.1" @@ -1258,9 +1243,9 @@ debug@4, debug@^4.1.0, debug@^4.1.1, debug@^4.3.1: ms "^2.1.3" decimal.js@^10.4.2: - version "10.4.3" - resolved "https://registry.yarnpkg.com/decimal.js/-/decimal.js-10.4.3.tgz#1044092884d245d1b7f65725fa4ad4c6f781cc23" - integrity sha512-VBBaLc1MgL5XpzgIP7ny5Z6Nx3UrRkIViUkPUdtl9aya5amy3De1gsUUSB1g3+3sExYNjCAsAznmukyxCb1GRA== + version "10.5.0" + resolved "https://registry.yarnpkg.com/decimal.js/-/decimal.js-10.5.0.tgz#0f371c7cf6c4898ce0afb09836db73cd82010f22" + integrity sha512-8vDa8Qxvr/+d94hSh5P3IJwI5t8/c0KsMp+g8bNw9cY2icONa5aPfvKeieW1WlG0WQYwwhJ7mjui2xtiePQSXw== dedent@^1.0.0: version "1.5.3" @@ -1294,7 +1279,7 @@ domexception@^4.0.0: dependencies: webidl-conversions "^7.0.0" -dunder-proto@^1.0.0: +dunder-proto@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/dunder-proto/-/dunder-proto-1.0.1.tgz#d7ae667e1dc83482f8b70fd0f6eefc50da30f58a" integrity sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A== @@ -1304,9 +1289,9 @@ dunder-proto@^1.0.0: gopd "^1.2.0" electron-to-chromium@^1.5.73: - version "1.5.75" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.75.tgz#bba96eabf0e8ca36324679caa38b982800acc87d" - integrity sha512-Lf3++DumRE/QmweGjU+ZcKqQ+3bKkU/qjaKYhIJKEOhgIO9Xs6IiAQFkfFoj+RhgDk4LUeNsLo6plExHqSyu6Q== + version "1.5.116" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.116.tgz#b779d73cd0cc75305d12ae4f061d7f7bcee4c761" + integrity sha512-mufxTCJzLBQVvSdZzX1s5YAuXsN1M4tTyYxOOL1TcSKtIzQ9rjIrm7yFK80rN5dwGTePgdoABDSHpuVtRQh0Zw== emittery@^0.13.1: version "0.13.1" @@ -1319,9 +1304,9 @@ emoji-regex@^8.0.0: integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== enhanced-resolve@^5.0.0, enhanced-resolve@^5.17.1: - version "5.18.0" - resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-5.18.0.tgz#91eb1db193896b9801251eeff1c6980278b1e404" - integrity sha512-0/r0MySGYG8YqlayBZ6MuCfECmHFdJ5qyPh8s8wa5Hnm6SaFLSK1VYCbj+NKp090Nm1caZhD+QTnmxO7esYGyQ== + version "5.18.1" + resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-5.18.1.tgz#728ab082f8b7b6836de51f1637aab5d3b9568faf" + integrity sha512-ZSW3ma5GkcQBIpwZTSRAI8N71Uuwgs93IezB7mf7R60tC8ZbJideoDNKjHn2O9KIlx6rkGTTEk1xUCK2E1Y2Yg== dependencies: graceful-fs "^4.2.4" tapable "^2.2.0" @@ -1349,17 +1334,27 @@ es-errors@^1.3.0: integrity sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw== es-module-lexer@^1.2.1: - version "1.5.4" - resolved "https://registry.yarnpkg.com/es-module-lexer/-/es-module-lexer-1.5.4.tgz#a8efec3a3da991e60efa6b633a7cad6ab8d26b78" - integrity sha512-MVNK56NiMrOwitFB7cqDwq0CQutbw+0BvLshJSse0MUNU+y1FC3bUS/AQg7oUng+/wKrrki7JfmwtVHkVfPLlw== + version "1.6.0" + resolved "https://registry.yarnpkg.com/es-module-lexer/-/es-module-lexer-1.6.0.tgz#da49f587fd9e68ee2404fe4e256c0c7d3a81be21" + integrity sha512-qqnD1yMU6tk/jnaMosogGySTZP8YtUgAffA9nMN+E/rjxcfRQ6IEk7IiozUjgxKoFHBGjTLnrHB/YC45r/59EQ== -es-object-atoms@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/es-object-atoms/-/es-object-atoms-1.0.0.tgz#ddb55cd47ac2e240701260bc2a8e31ecb643d941" - integrity sha512-MZ4iQ6JwHOBQjahnjwaC1ZtIBH+2ohjamzAO3oaHcXYup7qxjF2fixyH+Q71voWHeOkI2q/TnJao/KfXYIZWbw== +es-object-atoms@^1.0.0, es-object-atoms@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/es-object-atoms/-/es-object-atoms-1.1.1.tgz#1c4f2c4837327597ce69d2ca190a7fdd172338c1" + integrity sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA== dependencies: es-errors "^1.3.0" +es-set-tostringtag@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/es-set-tostringtag/-/es-set-tostringtag-2.1.0.tgz#f31dbbe0c183b00a6d26eb6325c810c0fd18bd4d" + integrity sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA== + dependencies: + es-errors "^1.3.0" + get-intrinsic "^1.2.6" + has-tostringtag "^1.0.2" + hasown "^2.0.2" + escalade@^3.1.1, escalade@^3.2.0: version "3.2.0" resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.2.0.tgz#011a3f69856ba189dffa7dc8fcce99d2a87903e5" @@ -1457,20 +1452,20 @@ expect@^29.0.0, expect@^29.7.0: jest-message-util "^29.7.0" jest-util "^29.7.0" -fast-deep-equal@^3.1.1, fast-deep-equal@^3.1.3: +fast-deep-equal@^3.1.3: version "3.1.3" resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== -fast-json-stable-stringify@2.x, fast-json-stable-stringify@^2.0.0, fast-json-stable-stringify@^2.1.0: +fast-json-stable-stringify@2.x, fast-json-stable-stringify@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz#874bf69c6f404c2b5d99c481341399fd55892633" integrity sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw== fast-uri@^3.0.1: - version "3.0.3" - resolved "https://registry.yarnpkg.com/fast-uri/-/fast-uri-3.0.3.tgz#892a1c91802d5d7860de728f18608a0573142241" - integrity sha512-aLrHthzCjH5He4Z2H9YZ+v6Ujb9ocRuW6ZzkJQOrTxleEijANq4v1TsaPaVG1PZcuurEzrLcWRyYBYXD5cEiaw== + version "3.0.6" + resolved "https://registry.yarnpkg.com/fast-uri/-/fast-uri-3.0.6.tgz#88f130b77cfaea2378d56bf970dea21257a68748" + integrity sha512-Atfo14OibSv5wAp4VWNsFYE1AchQRTv9cBGWET4pZWHzYshFSS9NQI6I57rdKn9croWVMbYFbLhJ+yJvmZIIHw== fb-watchman@^2.0.0: version "2.0.2" @@ -1495,12 +1490,13 @@ find-up@^4.0.0, find-up@^4.1.0: path-exists "^4.0.0" form-data@^4.0.0: - version "4.0.1" - resolved "https://registry.yarnpkg.com/form-data/-/form-data-4.0.1.tgz#ba1076daaaa5bfd7e99c1a6cb02aa0a5cff90d48" - integrity sha512-tzN8e4TX8+kkxGPK8D5u0FNmjPUjw3lwC9lSLxxoB/+GtsJG91CO8bSWy73APlgAZzZbXEYZJuxjkHH2w+Ezhw== + version "4.0.2" + resolved "https://registry.yarnpkg.com/form-data/-/form-data-4.0.2.tgz#35cabbdd30c3ce73deb2c42d3c8d3ed9ca51794c" + integrity sha512-hGfm/slu0ZabnNt4oaRZ6uREyfCj6P4fT/n6A1rGV+Z0VdGXjfOhVUpkn6qVQONHGIFwmveGXyDs75+nr6FM8w== dependencies: asynckit "^0.4.0" combined-stream "^1.0.8" + es-set-tostringtag "^2.1.0" mime-types "^2.1.12" formdata-node@^6.0.3: @@ -1533,27 +1529,35 @@ get-caller-file@^2.0.5: resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== -get-intrinsic@^1.2.5, get-intrinsic@^1.2.6: - version "1.2.6" - resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.2.6.tgz#43dd3dd0e7b49b82b2dfcad10dc824bf7fc265d5" - integrity sha512-qxsEs+9A+u85HhllWJJFicJfPDhRmjzoYdl64aMWW9yRIJmSyxdn8IEkuIM530/7T+lv0TIHd8L6Q/ra0tEoeA== +get-intrinsic@^1.2.5, get-intrinsic@^1.2.6, get-intrinsic@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.3.0.tgz#743f0e3b6964a93a5491ed1bffaae054d7f98d01" + integrity sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ== dependencies: - call-bind-apply-helpers "^1.0.1" - dunder-proto "^1.0.0" + call-bind-apply-helpers "^1.0.2" es-define-property "^1.0.1" es-errors "^1.3.0" - es-object-atoms "^1.0.0" + es-object-atoms "^1.1.1" function-bind "^1.1.2" + get-proto "^1.0.1" gopd "^1.2.0" has-symbols "^1.1.0" hasown "^2.0.2" - math-intrinsics "^1.0.0" + math-intrinsics "^1.1.0" get-package-type@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/get-package-type/-/get-package-type-0.1.0.tgz#8de2d803cff44df3bc6c456e6668b36c3926e11a" integrity sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q== +get-proto@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/get-proto/-/get-proto-1.0.1.tgz#150b3f2743869ef3e851ec0c49d15b1d14d00ee1" + integrity sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g== + dependencies: + dunder-proto "^1.0.1" + es-object-atoms "^1.0.0" + get-stream@^6.0.0: version "6.0.1" resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-6.0.1.tgz#a262d8eef67aced57c2852ad6167526a43cbf7b7" @@ -1596,11 +1600,18 @@ has-flag@^4.0.0: resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== -has-symbols@^1.1.0: +has-symbols@^1.0.3, has-symbols@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.1.0.tgz#fc9c6a783a084951d0b971fe1018de813707a338" integrity sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ== +has-tostringtag@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/has-tostringtag/-/has-tostringtag-1.0.2.tgz#2cdc42d40bef2e5b4eeab7c01a73c54ce7ab5abc" + integrity sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw== + dependencies: + has-symbols "^1.0.3" + hasown@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/hasown/-/hasown-2.0.2.tgz#003eaf91be7adc372e84ec59dc37252cedb80003" @@ -1686,9 +1697,9 @@ is-arrayish@^0.2.1: integrity sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg== is-core-module@^2.16.0: - version "2.16.0" - resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.16.0.tgz#6c01ffdd5e33c49c1d2abfa93334a85cb56bd81c" - integrity sha512-urTSINYfAYgcbLb0yDQ6egFm6h3Mo1DcF9EkyXSRjjzdHbsulg01qhwWuXdOoUBuTkbQ80KDboXa0vFJ+BDH+g== + version "2.16.1" + resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.16.1.tgz#2a98801a849f43e2add644fbb6bc6229b19a4ef4" + integrity sha512-UfoeMA6fIJ8wTYFEUjelnaGI67v6+N7qXJEvQuIGa99l4xsCruSYOVSQ0uPANn4dAzm8lkYPaKLrrijLq7x23w== dependencies: hasown "^2.0.2" @@ -2216,11 +2227,6 @@ json-parse-even-better-errors@^2.3.0, json-parse-even-better-errors@^2.3.1: resolved "https://registry.yarnpkg.com/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz#7c47805a94319928e05777405dc12e1f7a4ee02d" integrity sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w== -json-schema-traverse@^0.4.1: - version "0.4.1" - resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" - integrity sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg== - json-schema-traverse@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz#ae7bcb3656ab77a73ba5c49bf654f38e6b6860e2" @@ -2289,7 +2295,7 @@ makeerror@1.0.12: dependencies: tmpl "1.0.5" -math-intrinsics@^1.0.0: +math-intrinsics@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/math-intrinsics/-/math-intrinsics-1.1.0.tgz#a0dd74be81e2aa5c2f27e65ce283605ee4e2b7f9" integrity sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g== @@ -2376,14 +2382,14 @@ npm-run-path@^4.0.1: path-key "^3.0.0" nwsapi@^2.2.2: - version "2.2.16" - resolved "https://registry.yarnpkg.com/nwsapi/-/nwsapi-2.2.16.tgz#177760bba02c351df1d2644e220c31dfec8cdb43" - integrity sha512-F1I/bimDpj3ncaNDhfyMWuFqmQDBwDB0Fogc2qpL3BWvkQteFD/8BzWuIRl83rq0DXfm8SGt/HFhLXZyljTXcQ== + version "2.2.18" + resolved "https://registry.yarnpkg.com/nwsapi/-/nwsapi-2.2.18.tgz#3c4d7927e1ef4d042d319438ecfda6cd81b7ee41" + integrity sha512-p1TRH/edngVEHVbwqWnxUViEmq5znDvyB+Sik5cmuLpGOIfDf/39zLiq3swPF8Vakqn+gvNiOQAZu8djYlQILA== object-inspect@^1.13.3: - version "1.13.3" - resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.13.3.tgz#f14c183de51130243d6d18ae149375ff50ea488a" - integrity sha512-kDCGIbxkDSXE3euJZZXzc6to7fCrKHNI/hSRQnRuQ+BWjFNzZwiFF8fj/6o2t2G9/jTj8PSIYTfCLelLZEeRpA== + version "1.13.4" + resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.13.4.tgz#8375265e21bc20d0fa582c22e1b13485d6e00213" + integrity sha512-W67iLl4J2EXEGTbfeHCffrjDfitvLANg0UlX3wFUUSTx92KXRFegMHUVgSqE+wvhAbi4WqjGg9czysTV2Epbew== once@^1.3.0: version "1.4.0" @@ -2462,7 +2468,7 @@ path-parse@^1.0.7: resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" integrity sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw== -picocolors@^1.0.0, picocolors@^1.1.0: +picocolors@^1.0.0, picocolors@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.1.1.tgz#3d321af3eab939b083c8f929a1d12cda81c26b6b" integrity sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA== @@ -2518,7 +2524,7 @@ psl@^1.1.33: dependencies: punycode "^2.3.1" -punycode@^2.1.0, punycode@^2.1.1, punycode@^2.3.1: +punycode@^2.1.1, punycode@^2.3.1: version "2.3.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.3.1.tgz#027422e2faec0b25e1549c3e1bd8309b9133b6e5" integrity sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg== @@ -2553,9 +2559,9 @@ react-is@^18.0.0: integrity sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg== readable-stream@^4.5.2: - version "4.6.0" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-4.6.0.tgz#ce412dfb19c04efde1c5936d99c27f37a1ff94c9" - integrity sha512-cbAdYt0VcnpN2Bekq7PU+k363ZRsPwJoEEJOEtSJQlJXzwaxt3FIo/uL+KeDSGIjJqtkwyge4KQgD2S2kd+CQw== + version "4.7.0" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-4.7.0.tgz#cedbd8a1146c13dfff8dab14068028d58c15ac91" + integrity sha512-oIGGmcpTLwPga8Bn6/Z75SVaH1z5dUut2ibSyAMVhmUggWpmDn2dapB0n7f8nwaSiRtepAsfJyfXIO5DCVAODg== dependencies: abort-controller "^3.0.0" buffer "^6.0.3" @@ -2626,15 +2632,6 @@ saxes@^6.0.0: dependencies: xmlchars "^2.2.0" -schema-utils@^3.2.0: - version "3.3.0" - resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-3.3.0.tgz#f50a88877c3c01652a15b622ae9e9795df7a60fe" - integrity sha512-pN/yOAvcC+5rQ5nERGuwrjLlYvLTbCibnZ1I7B1LaiAz9BRBlE9GMgE/eqV30P7aJQUf7Ddimy/RsbYO/GrVGg== - dependencies: - "@types/json-schema" "^7.0.8" - ajv "^6.12.5" - ajv-keywords "^3.5.2" - schema-utils@^4.3.0: version "4.3.0" resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-4.3.0.tgz#3b669f04f71ff2dfb5aba7ce2d5a9d79b35622c0" @@ -2651,9 +2648,9 @@ semver@^6.3.0, semver@^6.3.1: integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== semver@^7.3.4, semver@^7.5.3, semver@^7.5.4: - version "7.6.3" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.6.3.tgz#980f7b5550bc175fb4dc09403085627f9eb33143" - integrity sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A== + version "7.7.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.7.1.tgz#abd5098d82b18c6c81f6074ff2647fd3e7220c9f" + integrity sha512-hlq8tAfn0m/61p4BVRcPzIGr6LKiMwo4VM6dGi6pt4qcRkmNzTcWq6eCEjEh+qXjkMDvPlOFFSGwQjoEa6gyMA== serialize-javascript@^6.0.2: version "6.0.2" @@ -2842,10 +2839,10 @@ tapable@^2.1.1, tapable@^2.2.0: resolved "https://registry.yarnpkg.com/tapable/-/tapable-2.2.1.tgz#1967a73ef4060a82f12ab96af86d52fdb76eeca0" integrity sha512-GNzQvQTOIP6RyTfE2Qxb8ZVlNmw0n88vp1szwWRimP02mnTsx3Wtn5qRdqY9w2XduFNUgvOwhNnQsjwCp+kqaQ== -terser-webpack-plugin@^5.3.10: - version "5.3.11" - resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-5.3.11.tgz#93c21f44ca86634257cac176f884f942b7ba3832" - integrity sha512-RVCsMfuD0+cTt3EwX8hSl2Ks56EbFHWmhluwcqoPKtBnfjiT6olaq7PRIRfhyU8nnC2MrnDrBLfrD/RGE+cVXQ== +terser-webpack-plugin@^5.3.11: + version "5.3.14" + resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-5.3.14.tgz#9031d48e57ab27567f02ace85c7d690db66c3e06" + integrity sha512-vkZjpUjb6OMS7dhV+tILUW6BhpDR7P2L/aQSAv+Uwk+m8KATX9EccViHTJR2qDtACKPIYndLGCyl3FMo+r2LMw== dependencies: "@jridgewell/trace-mapping" "^0.3.25" jest-worker "^27.4.5" @@ -2854,9 +2851,9 @@ terser-webpack-plugin@^5.3.10: terser "^5.31.1" terser@^5.31.1: - version "5.37.0" - resolved "https://registry.yarnpkg.com/terser/-/terser-5.37.0.tgz#38aa66d1cfc43d0638fab54e43ff8a4f72a21ba3" - integrity sha512-B8wRRkmre4ERucLM/uXx4MOV5cbnOlVAqUst+1+iLKPI0dOgFO28f84ptoQt9HEI537PMzfYa/d+GEPKTRXmYA== + version "5.39.0" + resolved "https://registry.yarnpkg.com/terser/-/terser-5.39.0.tgz#0e82033ed57b3ddf1f96708d123cca717d86ca3a" + integrity sha512-LBAhFyLho16harJoWMg/nZsQYgTrg5jXOn2nCYjRUcZZEdE3qa2zb8QEDRUGVZBW4rlazf2fxkg8tztybTaqWw== dependencies: "@jridgewell/source-map" "^0.3.3" acorn "^8.8.2" @@ -2921,9 +2918,9 @@ ts-jest@29.1.1: yargs-parser "^21.0.1" ts-loader@^9.3.1: - version "9.5.1" - resolved "https://registry.yarnpkg.com/ts-loader/-/ts-loader-9.5.1.tgz#63d5912a86312f1fbe32cef0859fb8b2193d9b89" - integrity sha512-rNH3sK9kGZcH9dYzC7CewQm4NtxJTjSEVRJ2DyBZR7f8/wcta+iV44UPCXc5+nzDzivKtlzV6c9P4e+oFhDLYg== + version "9.5.2" + resolved "https://registry.yarnpkg.com/ts-loader/-/ts-loader-9.5.2.tgz#1f3d7f4bb709b487aaa260e8f19b301635d08020" + integrity sha512-Qo4piXvOTWcMGIgRiuFa6nHNm+54HbYaZCKqc9eeZCLRy3XqafQgwX2F7mofrbJG3g7EEb+lkiR+z2Lic2s3Zw== dependencies: chalk "^4.1.0" enhanced-resolve "^5.0.0" @@ -2957,19 +2954,12 @@ universalify@^0.2.0: integrity sha512-CJ1QgKmNg3CwvAv/kOFmtnEN05f0D/cn9QntgNOQlQF9dgvVTHj3t+8JPdjqawCHk7V/KA+fbUqzZ9XWhcqPUg== update-browserslist-db@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/update-browserslist-db/-/update-browserslist-db-1.1.1.tgz#80846fba1d79e82547fb661f8d141e0945755fe5" - integrity sha512-R8UzCaa9Az+38REPiJ1tXlImTJXlVfgHZsglwBD/k6nj76ctsH1E3q4doGrukiLQd3sGQYu56r5+lo5r94l29A== + version "1.1.3" + resolved "https://registry.yarnpkg.com/update-browserslist-db/-/update-browserslist-db-1.1.3.tgz#348377dd245216f9e7060ff50b15a1b740b75420" + integrity sha512-UxhIZQ+QInVdunkDAaiazvvT/+fXL5Osr0JZlJulepYu6Jd7qJtDZjlur0emRlT71EN3ScPoE7gvsuIKKNavKw== dependencies: escalade "^3.2.0" - picocolors "^1.1.0" - -uri-js@^4.2.2: - version "4.4.1" - resolved "https://registry.yarnpkg.com/uri-js/-/uri-js-4.4.1.tgz#9b1a52595225859e55f669d928f88c6c57f2a77e" - integrity sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg== - dependencies: - punycode "^2.1.0" + picocolors "^1.1.1" url-join@4.0.1: version "4.0.1" @@ -3031,9 +3021,9 @@ webpack-sources@^3.2.3: integrity sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w== webpack@^5.94.0: - version "5.97.1" - resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.97.1.tgz#972a8320a438b56ff0f1d94ade9e82eac155fa58" - integrity sha512-EksG6gFY3L1eFMROS/7Wzgrii5mBAFe4rIr3r2BTfo7bcc+DWwFZ4OJ/miOuHJO/A85HwyI4eQ0F6IKXesO7Fg== + version "5.98.0" + resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.98.0.tgz#44ae19a8f2ba97537978246072fb89d10d1fbd17" + integrity sha512-UFynvx+gM44Gv9qFgj0acCQK2VE1CtdfwFdimkapco3hlPCJ/zeq73n2yVKimVbtm+TnApIugGhLJnkU6gjYXA== dependencies: "@types/eslint-scope" "^3.7.7" "@types/estree" "^1.0.6" @@ -3053,9 +3043,9 @@ webpack@^5.94.0: loader-runner "^4.2.0" mime-types "^2.1.27" neo-async "^2.6.2" - schema-utils "^3.2.0" + schema-utils "^4.3.0" tapable "^2.1.1" - terser-webpack-plugin "^5.3.10" + terser-webpack-plugin "^5.3.11" watchpack "^2.4.1" webpack-sources "^3.2.3" @@ -3117,9 +3107,9 @@ write-file-atomic@^4.0.2: signal-exit "^3.0.7" ws@^8.11.0: - version "8.18.0" - resolved "https://registry.yarnpkg.com/ws/-/ws-8.18.0.tgz#0d7505a6eafe2b0e712d232b42279f53bc289bbc" - integrity sha512-8VbfWfHLbbwu3+N6OKsOMpBdT4kXPDDB9cJk2bJ6mh9ucxdlnNvH1e+roYkKmN9Nxw2yjz7VzeO9oOz2zJ04Pw== + version "8.18.1" + resolved "https://registry.yarnpkg.com/ws/-/ws-8.18.1.tgz#ea131d3784e1dfdff91adb0a4a116b127515e3cb" + integrity sha512-RKW2aJZMXeMxVpnZ6bck+RswznaxmzdULiBr6KY7XkTnW8uvt0iT9H5DkHUChXrc+uurzwa0rVI16n/Xzjdz1w== xml-name-validator@^4.0.0: version "4.0.0" From c484b930cc5de084fdb9f535344adb344db442a1 Mon Sep 17 00:00:00 2001 From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com> Date: Thu, 20 Mar 2025 08:18:45 -0400 Subject: [PATCH 130/146] SDK regeneration (#481) --- README.md | 44 +++++++------- package.json | 2 +- reference.md | 1 - src/api/resources/admins/client/Client.ts | 20 +++---- src/api/resources/articles/client/Client.ts | 24 ++++---- src/api/resources/companies/client/Client.ts | 44 +++++++------- src/api/resources/contacts/client/Client.ts | 60 +++++++++---------- src/api/resources/contacts/types/Contact.ts | 12 +--- .../resources/conversations/client/Client.ts | 53 ++++++++-------- .../resources/dataAttributes/client/Client.ts | 12 ++-- src/api/resources/dataExport/client/Client.ts | 16 ++--- src/api/resources/events/client/Client.ts | 14 ++--- .../resources/helpCenters/client/Client.ts | 8 +-- .../resources/collections/client/Client.ts | 20 +++---- src/api/resources/messages/client/Client.ts | 4 +- .../news/resources/feeds/client/Client.ts | 12 ++-- .../news/resources/items/client/Client.ts | 20 +++---- src/api/resources/notes/client/Client.ts | 12 ++-- .../phoneCallRedirects/client/Client.ts | 4 +- src/api/resources/segments/client/Client.ts | 8 +-- .../subscriptionTypes/client/Client.ts | 4 +- src/api/resources/tags/client/Client.ts | 41 +++++++------ src/api/resources/teams/client/Client.ts | 8 +-- .../resources/ticketTypes/client/Client.ts | 16 ++--- .../resources/attributes/client/Client.ts | 8 +-- src/api/resources/tickets/client/Client.ts | 20 +++---- src/api/resources/visitors/client/Client.ts | 12 ++-- src/api/types/ArticleList.ts | 2 +- src/api/types/CollectionList.ts | 2 +- src/api/types/CompanyList.ts | 2 +- src/api/types/NoteList.ts | 2 +- src/api/types/OffsetPages.ts | 15 +++++ src/api/types/index.ts | 1 + src/version.ts | 2 +- yarn.lock | 18 +++--- 35 files changed, 271 insertions(+), 272 deletions(-) create mode 100644 src/api/types/OffsetPages.ts diff --git a/README.md b/README.md index a9441d7c..b55707b6 100644 --- a/README.md +++ b/README.md @@ -88,28 +88,6 @@ while (page.hasNextPage()) { } ``` -## Request Options - -This client library also supports passing in [`request` options](https://github.com/axios/axios#request-config): - -```typescript -client.useRequestOpts({ - baseURL: "http://local.test-server.com", -}); -``` - -Note that certain request options (such as `json`, and certain `headers` names cannot be overriden). - -### Setting the API base url - -If you are using the european instance of intercom and would like to call it directly and not be redirected through our US instance, you can set the `baseUrl` as follows: - -```typescript -client.useRequestOpts({ - baseURL: "https://api.eu.intercom.io", -}); -``` - ## Advanced ### Additional Headers @@ -192,6 +170,28 @@ const client = new IntercomClient({ }); ``` +## Request Options + +This client library also supports passing in [`request` options](https://github.com/axios/axios#request-config): + +```typescript +client.useRequestOpts({ + baseURL: "http://local.test-server.com", +}); +``` + +Note that certain request options (such as `json`, and certain `headers` names cannot be overriden). + +### Setting the API base url + +If you are using the european instance of intercom and would like to call it directly and not be redirected through our US instance, you can set the `baseUrl` as follows: + +```typescript +client.useRequestOpts({ + baseURL: "https://api.eu.intercom.io", +}); +``` + ## Contributing While we value open-source contributions to this SDK, this library is generated programmatically. diff --git a/package.json b/package.json index faac874b..0a5a6102 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "6.1.0", + "version": "v6.1.1", "private": false, "repository": "https://github.com/intercom/intercom-node", "main": "./index.js", diff --git a/reference.md b/reference.md index e07b5d97..65fd0e3b 100644 --- a/reference.md +++ b/reference.md @@ -5032,7 +5032,6 @@ Duplicated events are responded to using the normal `202 Accepted` code - an err - Events sent about users that cannot be found will return a `404 Not Found`. - Event lists containing duplicate events will have those duplicates ignored. - Server errors will return a `500` response code and may contain an error message in the body. -
diff --git a/src/api/resources/admins/client/Client.ts b/src/api/resources/admins/client/Client.ts index 25141fbf..88778352 100644 --- a/src/api/resources/admins/client/Client.ts +++ b/src/api/resources/admins/client/Client.ts @@ -97,8 +97,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -167,8 +167,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -249,8 +249,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -315,8 +315,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -388,8 +388,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/articles/client/Client.ts b/src/api/resources/articles/client/Client.ts index a37c5569..660e6d8c 100644 --- a/src/api/resources/articles/client/Client.ts +++ b/src/api/resources/articles/client/Client.ts @@ -112,8 +112,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -219,8 +219,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -295,8 +295,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -372,8 +372,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -448,8 +448,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -540,8 +540,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/companies/client/Client.ts b/src/api/resources/companies/client/Client.ts index 75bb59c4..9ff6fdb5 100644 --- a/src/api/resources/companies/client/Client.ts +++ b/src/api/resources/companies/client/Client.ts @@ -140,8 +140,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -228,8 +228,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -304,8 +304,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -383,8 +383,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -458,8 +458,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -542,8 +542,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -620,8 +620,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -716,8 +716,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -816,8 +816,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -911,8 +911,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -992,8 +992,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/contacts/client/Client.ts b/src/api/resources/contacts/client/Client.ts index 6d654f3a..28fae748 100644 --- a/src/api/resources/contacts/client/Client.ts +++ b/src/api/resources/contacts/client/Client.ts @@ -113,8 +113,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -200,8 +200,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -283,8 +283,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -375,8 +375,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -454,8 +454,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -531,8 +531,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -605,8 +605,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -679,8 +679,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -752,8 +752,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -824,8 +824,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1006,8 +1006,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1102,8 +1102,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1181,8 +1181,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1252,8 +1252,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1319,8 +1319,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/contacts/types/Contact.ts b/src/api/resources/contacts/types/Contact.ts index 2b1c744e..a9bed2d3 100644 --- a/src/api/resources/contacts/types/Contact.ts +++ b/src/api/resources/contacts/types/Contact.ts @@ -88,19 +88,11 @@ export interface Contact { ios_last_seen_at?: number; /** The custom attributes which are set for the contact. */ custom_attributes?: Record; - avatar?: Contact.Avatar; + /** An image URL containing the avatar of a contact. */ + avatar?: string; tags?: Intercom.ContactTags; notes?: Intercom.ContactNotes; companies?: Intercom.ContactCompanies; location: Intercom.ContactLocation; social_profiles: Intercom.ContactSocialProfiles; } - -export namespace Contact { - export interface Avatar { - /** The type of object */ - type?: "avatar"; - /** An image URL containing the avatar of a contact. */ - image_url?: string; - } -} diff --git a/src/api/resources/conversations/client/Client.ts b/src/api/resources/conversations/client/Client.ts index feedc547..df170958 100644 --- a/src/api/resources/conversations/client/Client.ts +++ b/src/api/resources/conversations/client/Client.ts @@ -117,8 +117,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -182,7 +182,6 @@ export class Conversations { * * This will return the Message model that has been created. * - * * @param {Intercom.CreateConversationRequest} request * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. * @@ -222,8 +221,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -316,8 +315,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -375,7 +374,6 @@ export class Conversations { * If you want to reply to a coveration or take an action such as assign, unassign, open, close or snooze, take a look at the reply and manage endpoints. * {% /admonition %} * - * * @param {Intercom.UpdateConversationRequest} request * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. * @@ -414,8 +412,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -601,8 +599,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -719,8 +717,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -839,8 +837,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -926,8 +924,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -983,7 +981,6 @@ export class Conversations { * If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. * {% /admonition %} * - * * @param {Intercom.AttachContactToConversationRequest} request * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. * @@ -1024,8 +1021,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1082,7 +1079,6 @@ export class Conversations { * If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. * {% /admonition %} * - * * @param {Intercom.DetachContactFromConversationRequest} request * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. * @@ -1113,8 +1109,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1173,7 +1169,6 @@ export class Conversations { * If you are redacting a conversation part, it must have a `body`. If you are redacting a source message, it must have been created by a contact. We will return a `conversation_part_not_redactable` error if these criteria are not met. * {% /admonition %} * - * * @param {Intercom.RedactConversationRequest} request * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. * @@ -1208,8 +1203,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1290,8 +1285,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/dataAttributes/client/Client.ts b/src/api/resources/dataAttributes/client/Client.ts index f24256a1..303e547a 100644 --- a/src/api/resources/dataAttributes/client/Client.ts +++ b/src/api/resources/dataAttributes/client/Client.ts @@ -108,8 +108,8 @@ export class DataAttributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -220,8 +220,8 @@ export class DataAttributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -329,8 +329,8 @@ export class DataAttributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/dataExport/client/Client.ts b/src/api/resources/dataExport/client/Client.ts index 8a9064d8..1696efc0 100644 --- a/src/api/resources/dataExport/client/Client.ts +++ b/src/api/resources/dataExport/client/Client.ts @@ -113,8 +113,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -183,8 +183,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -250,8 +250,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -323,8 +323,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/events/client/Client.ts b/src/api/resources/events/client/Client.ts index 67de1e49..d4fcbd97 100644 --- a/src/api/resources/events/client/Client.ts +++ b/src/api/resources/events/client/Client.ts @@ -140,8 +140,8 @@ export class Events { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -228,7 +228,6 @@ export class Events { * - Event lists containing duplicate events will have those duplicates ignored. * - Server errors will return a `500` response code and may contain an error message in the body. * - * * @param {Intercom.CreateDataEventRequest} request * @param {Events.RequestOptions} requestOptions - Request-specific configuration. * @@ -255,8 +254,8 @@ export class Events { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -303,7 +302,6 @@ export class Events { /** * Create event summaries for a user. Event summaries are used to track the number of times an event has occurred, the first time it occurred and the last time it occurred. * - * * @param {Intercom.ListEventSummariesRequest} request * @param {Events.RequestOptions} requestOptions - Request-specific configuration. * @@ -326,8 +324,8 @@ export class Events { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/helpCenters/client/Client.ts b/src/api/resources/helpCenters/client/Client.ts index 82e0cb17..a0e94871 100644 --- a/src/api/resources/helpCenters/client/Client.ts +++ b/src/api/resources/helpCenters/client/Client.ts @@ -106,8 +106,8 @@ export class HelpCenters { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -189,8 +189,8 @@ export class HelpCenters { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/helpCenters/resources/collections/client/Client.ts b/src/api/resources/helpCenters/resources/collections/client/Client.ts index bcba68d6..1daef23b 100644 --- a/src/api/resources/helpCenters/resources/collections/client/Client.ts +++ b/src/api/resources/helpCenters/resources/collections/client/Client.ts @@ -107,8 +107,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -197,8 +197,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -273,8 +273,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -351,8 +351,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -429,8 +429,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/messages/client/Client.ts b/src/api/resources/messages/client/Client.ts index 9656e54f..e5ed8541 100644 --- a/src/api/resources/messages/client/Client.ts +++ b/src/api/resources/messages/client/Client.ts @@ -178,8 +178,8 @@ export class Messages { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/news/resources/feeds/client/Client.ts b/src/api/resources/news/resources/feeds/client/Client.ts index 755013e9..010b3fe8 100644 --- a/src/api/resources/news/resources/feeds/client/Client.ts +++ b/src/api/resources/news/resources/feeds/client/Client.ts @@ -98,8 +98,8 @@ export class Feeds { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -165,8 +165,8 @@ export class Feeds { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -237,8 +237,8 @@ export class Feeds { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/news/resources/items/client/Client.ts b/src/api/resources/news/resources/items/client/Client.ts index ce135ffe..feaf5a90 100644 --- a/src/api/resources/news/resources/items/client/Client.ts +++ b/src/api/resources/news/resources/items/client/Client.ts @@ -91,8 +91,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -172,8 +172,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -246,8 +246,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -338,8 +338,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -416,8 +416,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/notes/client/Client.ts b/src/api/resources/notes/client/Client.ts index 668debcb..b023e823 100644 --- a/src/api/resources/notes/client/Client.ts +++ b/src/api/resources/notes/client/Client.ts @@ -110,8 +110,8 @@ export class Notes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -196,8 +196,8 @@ export class Notes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -272,8 +272,8 @@ export class Notes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/phoneCallRedirects/client/Client.ts b/src/api/resources/phoneCallRedirects/client/Client.ts index 0216809a..8ab07914 100644 --- a/src/api/resources/phoneCallRedirects/client/Client.ts +++ b/src/api/resources/phoneCallRedirects/client/Client.ts @@ -115,8 +115,8 @@ export class PhoneCallRedirects { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/segments/client/Client.ts b/src/api/resources/segments/client/Client.ts index 4b044c01..9a980a78 100644 --- a/src/api/resources/segments/client/Client.ts +++ b/src/api/resources/segments/client/Client.ts @@ -104,8 +104,8 @@ export class Segments { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -178,8 +178,8 @@ export class Segments { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/subscriptionTypes/client/Client.ts b/src/api/resources/subscriptionTypes/client/Client.ts index e8bdfb4b..249ba181 100644 --- a/src/api/resources/subscriptionTypes/client/Client.ts +++ b/src/api/resources/subscriptionTypes/client/Client.ts @@ -94,8 +94,8 @@ export class SubscriptionTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/tags/client/Client.ts b/src/api/resources/tags/client/Client.ts index 5d47d7fd..68729f8a 100644 --- a/src/api/resources/tags/client/Client.ts +++ b/src/api/resources/tags/client/Client.ts @@ -109,8 +109,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -188,8 +188,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -267,8 +267,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -347,8 +347,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -399,7 +399,6 @@ export class Tags { /** * You can fetch a list of all tags for a given workspace. * - * * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} @@ -418,8 +417,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -524,8 +523,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -600,8 +599,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -673,8 +672,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -752,8 +751,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -830,8 +829,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/teams/client/Client.ts b/src/api/resources/teams/client/Client.ts index 8d996de9..3aa7071c 100644 --- a/src/api/resources/teams/client/Client.ts +++ b/src/api/resources/teams/client/Client.ts @@ -94,8 +94,8 @@ export class Teams { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -167,8 +167,8 @@ export class Teams { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/ticketTypes/client/Client.ts b/src/api/resources/ticketTypes/client/Client.ts index ad8aa653..53ca5a78 100644 --- a/src/api/resources/ticketTypes/client/Client.ts +++ b/src/api/resources/ticketTypes/client/Client.ts @@ -101,8 +101,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -179,8 +179,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -252,8 +252,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -332,8 +332,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/ticketTypes/resources/attributes/client/Client.ts b/src/api/resources/ticketTypes/resources/attributes/client/Client.ts index d11b193b..86190542 100644 --- a/src/api/resources/ticketTypes/resources/attributes/client/Client.ts +++ b/src/api/resources/ticketTypes/resources/attributes/client/Client.ts @@ -102,8 +102,8 @@ export class Attributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -179,8 +179,8 @@ export class Attributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/tickets/client/Client.ts b/src/api/resources/tickets/client/Client.ts index 20106a19..b4720b29 100644 --- a/src/api/resources/tickets/client/Client.ts +++ b/src/api/resources/tickets/client/Client.ts @@ -148,8 +148,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -231,8 +231,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -304,8 +304,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -416,8 +416,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -560,8 +560,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/visitors/client/Client.ts b/src/api/resources/visitors/client/Client.ts index ec8654a2..dc9e4d33 100644 --- a/src/api/resources/visitors/client/Client.ts +++ b/src/api/resources/visitors/client/Client.ts @@ -104,8 +104,8 @@ export class Visitors { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -190,8 +190,8 @@ export class Visitors { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -275,8 +275,8 @@ export class Visitors { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.1.0", - "User-Agent": "intercom-client/6.1.0", + "X-Fern-SDK-Version": "v6.1.1", + "User-Agent": "intercom-client/v6.1.1", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/types/ArticleList.ts b/src/api/types/ArticleList.ts index 9bb7744b..faf9ef31 100644 --- a/src/api/types/ArticleList.ts +++ b/src/api/types/ArticleList.ts @@ -10,7 +10,7 @@ import * as Intercom from "../index"; export interface ArticleList { /** The type of the object - `list`. */ type: "list"; - pages?: Intercom.CursorPages; + pages?: unknown; /** A count of the total number of articles. */ total_count: number; /** An array of Article objects */ diff --git a/src/api/types/CollectionList.ts b/src/api/types/CollectionList.ts index 240ee1e5..3260e2c6 100644 --- a/src/api/types/CollectionList.ts +++ b/src/api/types/CollectionList.ts @@ -10,7 +10,7 @@ import * as Intercom from "../index"; export interface CollectionList { /** The type of the object - `list`. */ type: "list"; - pages?: Intercom.CursorPages; + pages?: Intercom.OffsetPages; /** A count of the total number of collections. */ total_count: number; /** An array of collection objects */ diff --git a/src/api/types/CompanyList.ts b/src/api/types/CompanyList.ts index 90a0ff32..4bd8a082 100644 --- a/src/api/types/CompanyList.ts +++ b/src/api/types/CompanyList.ts @@ -10,7 +10,7 @@ import * as Intercom from "../index"; export interface CompanyList { /** The type of object - `list`. */ type: "list"; - pages?: Intercom.CursorPages; + pages?: Intercom.OffsetPages; /** The total number of companies. */ total_count: number; /** An array containing Company Objects. */ diff --git a/src/api/types/NoteList.ts b/src/api/types/NoteList.ts index a9af4e69..e9bf93ee 100644 --- a/src/api/types/NoteList.ts +++ b/src/api/types/NoteList.ts @@ -14,5 +14,5 @@ export interface NoteList { data: Intercom.Note[]; /** A count of the total number of notes. */ total_count: number; - pages?: Intercom.CursorPages; + pages?: Intercom.OffsetPages; } diff --git a/src/api/types/OffsetPages.ts b/src/api/types/OffsetPages.ts new file mode 100644 index 00000000..618d4b85 --- /dev/null +++ b/src/api/types/OffsetPages.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface OffsetPages { + /** the type of object `offset_pages` */ + type: "offset_pages"; + /** The current offset */ + page?: number; + next?: string; + /** Number of results per page */ + per_page?: number; + /** Total number of pages */ + total_pages?: number; +} diff --git a/src/api/types/index.ts b/src/api/types/index.ts index 03b2def2..ded80781 100644 --- a/src/api/types/index.ts +++ b/src/api/types/index.ts @@ -156,3 +156,4 @@ export * from "./UrlActionComponent"; export * from "./Visitor"; export * from "./VisitorDeletedObject"; export * from "./CustomAttributes"; +export * from "./OffsetPages"; diff --git a/src/version.ts b/src/version.ts index 0105d13d..9e9f5ed5 100644 --- a/src/version.ts +++ b/src/version.ts @@ -1 +1 @@ -export const SDK_VERSION = "6.1.0"; +export const SDK_VERSION = "v6.1.1"; diff --git a/yarn.lock b/yarn.lock index a53e591d..970f6bab 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1102,9 +1102,9 @@ camelcase@^6.2.0: integrity sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA== caniuse-lite@^1.0.30001688: - version "1.0.30001704" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001704.tgz#6644fe909d924ac3a7125e8a0ab6af95b1f32990" - integrity sha512-+L2IgBbV6gXB4ETf0keSvLr7JUrRVbIaB/lrQ1+z8mRcQiisG5k+lG6O4n6Y5q6f5EuNfaYXKgymucphlEXQew== + version "1.0.30001706" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001706.tgz#902c3f896f4b2968031c3a546ab2ef8b465a2c8f" + integrity sha512-3ZczoTApMAZwPKYWmwVbQMFpXBDds3/0VciVoUwPUbldlYyVLmRVuRs/PcUZtHpbLRpzzDvrvnFuREsGt6lUug== chalk@^4.0.0, chalk@^4.1.0: version "4.1.2" @@ -1289,9 +1289,9 @@ dunder-proto@^1.0.1: gopd "^1.2.0" electron-to-chromium@^1.5.73: - version "1.5.116" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.116.tgz#b779d73cd0cc75305d12ae4f061d7f7bcee4c761" - integrity sha512-mufxTCJzLBQVvSdZzX1s5YAuXsN1M4tTyYxOOL1TcSKtIzQ9rjIrm7yFK80rN5dwGTePgdoABDSHpuVtRQh0Zw== + version "1.5.122" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.122.tgz#4fabd37b30b71dc041f6c6c4bab309b3f8348fcb" + integrity sha512-EML1wnwkY5MFh/xUnCvY8FrhUuKzdYhowuZExZOfwJo+Zu9OsNCI23Cgl5y7awy7HrUHSwB1Z8pZX5TI34lsUg== emittery@^0.13.1: version "0.13.1" @@ -2382,9 +2382,9 @@ npm-run-path@^4.0.1: path-key "^3.0.0" nwsapi@^2.2.2: - version "2.2.18" - resolved "https://registry.yarnpkg.com/nwsapi/-/nwsapi-2.2.18.tgz#3c4d7927e1ef4d042d319438ecfda6cd81b7ee41" - integrity sha512-p1TRH/edngVEHVbwqWnxUViEmq5znDvyB+Sik5cmuLpGOIfDf/39zLiq3swPF8Vakqn+gvNiOQAZu8djYlQILA== + version "2.2.19" + resolved "https://registry.yarnpkg.com/nwsapi/-/nwsapi-2.2.19.tgz#586660f7c24c34691907002309a8dc28064c9c0b" + integrity sha512-94bcyI3RsqiZufXjkr3ltkI86iEl+I7uiHVDtcq9wJUTwYQJ5odHDeSzkkrRzi80jJ8MaeZgqKjH1bAWAFw9bA== object-inspect@^1.13.3: version "1.13.4" From fc2ac6c3f1d2844042af18fdba509d2c35b8e9d0 Mon Sep 17 00:00:00 2001 From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com> Date: Thu, 20 Mar 2025 08:36:22 -0400 Subject: [PATCH 131/146] SDK regeneration (#482) --- README.md | 42 ++-- jest.config.js => jest.config.mjs | 5 +- package.json | 32 +-- reference.md | 64 +++--- scripts/rename-to-esm-files.js | 115 ++++++++++ src/Client.ts | 6 +- src/api/resources/admins/client/Client.ts | 67 +++--- src/api/resources/articles/client/Client.ts | 84 ++++--- src/api/resources/companies/client/Client.ts | 155 +++++++------ src/api/resources/contacts/client/Client.ts | 208 ++++++++++-------- .../resources/conversations/client/Client.ts | 177 ++++++++------- .../resources/dataAttributes/client/Client.ts | 49 +++-- src/api/resources/dataExport/client/Client.ts | 63 +++--- src/api/resources/events/client/Client.ts | 47 ++-- .../resources/helpCenters/client/Client.ts | 38 ++-- .../resources/collections/client/Client.ts | 78 ++++--- src/api/resources/messages/client/Client.ts | 21 +- src/api/resources/news/client/Client.ts | 35 +-- .../news/resources/feeds/client/Client.ts | 47 ++-- .../news/resources/items/client/Client.ts | 73 +++--- src/api/resources/notes/client/Client.ts | 50 +++-- .../phoneCallRedirects/client/Client.ts | 21 +- src/api/resources/segments/client/Client.ts | 35 +-- .../subscriptionTypes/client/Client.ts | 19 +- src/api/resources/tags/client/Client.ts | 133 ++++++----- src/api/resources/teams/client/Client.ts | 31 ++- .../resources/ticketTypes/client/Client.ts | 59 +++-- .../resources/attributes/client/Client.ts | 37 ++-- src/api/resources/tickets/client/Client.ts | 70 +++--- src/api/resources/visitors/client/Client.ts | 47 ++-- src/core/fetcher/Fetcher.ts | 13 +- src/core/fetcher/createRequestUrl.ts | 2 +- src/core/fetcher/getRequestBody.ts | 4 +- src/core/fetcher/makeRequest.ts | 2 +- src/core/fetcher/requestWithRetries.ts | 4 +- src/core/fetcher/signals.ts | 2 +- .../Node18UniversalStreamWrapper.ts | 5 +- .../stream-wrappers/NodePre18StreamWrapper.ts | 1 + .../stream-wrappers/UndiciStreamWrapper.ts | 4 +- .../stream-wrappers/chooseStreamWrapper.ts | 3 +- src/core/json.ts | 27 +++ src/core/runtime/runtime.ts | 111 +++++----- src/errors/IntercomError.ts | 4 +- src/version.ts | 2 +- tests/unit/auth/BasicAuth.test.ts | 2 +- tests/unit/fetcher/Fetcher.test.ts | 7 +- tests/unit/fetcher/createRequestUrl.test.ts | 4 +- tests/unit/fetcher/makeRequest.test.ts | 5 +- tests/unit/fetcher/requestWithRetries.test.ts | 13 +- .../Node18UniversalStreamWrapper.test.ts | 2 +- .../NodePre18StreamWrapper.test.ts | 2 +- .../UndiciStreamWrapper.test.ts | 2 +- .../chooseStreamWrapper.test.ts | 2 +- .../fetcher/stream-wrappers/webpack.test.ts | 10 +- tsconfig.json | 4 +- yarn.lock | 165 +++++++++----- 56 files changed, 1384 insertions(+), 926 deletions(-) rename jest.config.js => jest.config.mjs (55%) create mode 100644 scripts/rename-to-esm-files.js create mode 100644 src/core/json.ts diff --git a/README.md b/README.md index b55707b6..a2e2c58a 100644 --- a/README.md +++ b/README.md @@ -105,14 +105,14 @@ const response = await client.articles.create(..., { ### Retries The SDK is instrumented with automatic retries with exponential backoff. A request will be retried as long -as the request is deemed retriable and the number of retry attempts has not grown larger than the configured +as the request is deemed retryable and the number of retry attempts has not grown larger than the configured retry limit (default: 2). -A request is deemed retriable when any of the following HTTP status codes is returned: +A request is deemed retryable when any of the following HTTP status codes is returned: -- [408](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/408) (Timeout) -- [429](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/429) (Too Many Requests) -- [5XX](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/500) (Internal Server Errors) +- [408](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/408) (Timeout) +- [429](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/429) (Too Many Requests) +- [5XX](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/500) (Internal Server Errors) Use the `maxRetries` request option to configure this behavior. @@ -149,12 +149,12 @@ controller.abort(); // aborts the request The SDK defaults to `node-fetch` but will use the global fetch client if present. The SDK works in the following runtimes: -- Node.js 18+ -- Vercel -- Cloudflare Workers -- Deno v1.25+ -- Bun 1.0+ -- React Native +- Node.js 18+ +- Vercel +- Cloudflare Workers +- Deno v1.25+ +- Bun 1.0+ +- React Native ### Customizing Fetch Client @@ -170,6 +170,16 @@ const client = new IntercomClient({ }); ``` +## Contributing + +While we value open-source contributions to this SDK, this library is generated programmatically. +Additions made directly to this library would have to be moved over to our generation code, +otherwise they would be overwritten upon the next generated release. Feel free to open a PR as +a proof of concept, but know that we will not be able to merge it as-is. We suggest opening +an issue first to discuss with us! + +On the other hand, contributions to the README are always very welcome! + ## Request Options This client library also supports passing in [`request` options](https://github.com/axios/axios#request-config): @@ -191,13 +201,3 @@ client.useRequestOpts({ baseURL: "https://api.eu.intercom.io", }); ``` - -## Contributing - -While we value open-source contributions to this SDK, this library is generated programmatically. -Additions made directly to this library would have to be moved over to our generation code, -otherwise they would be overwritten upon the next generated release. Feel free to open a PR as -a proof of concept, but know that we will not be able to merge it as-is. We suggest opening -an issue first to discuss with us! - -On the other hand, contributions to the README are always very welcome! diff --git a/jest.config.js b/jest.config.mjs similarity index 55% rename from jest.config.js rename to jest.config.mjs index 35d6e65b..c7248211 100644 --- a/jest.config.js +++ b/jest.config.mjs @@ -1,5 +1,8 @@ /** @type {import('jest').Config} */ -module.exports = { +export default { preset: "ts-jest", testEnvironment: "node", + moduleNameMapper: { + "(.+)\.js$": "$1", + }, }; diff --git a/package.json b/package.json index 0a5a6102..8679953d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "v6.1.1", + "version": "6.2.0", "private": false, "repository": "https://github.com/intercom/intercom-node", "main": "./index.js", @@ -15,25 +15,25 @@ "url-join": "4.0.1", "form-data": "^4.0.0", "formdata-node": "^6.0.3", - "node-fetch": "2.7.0", - "qs": "6.11.2", + "node-fetch": "^2.7.0", + "qs": "^6.13.1", "readable-stream": "^4.5.2", - "js-base64": "3.7.2" + "js-base64": "3.7.7" }, "devDependencies": { "@types/url-join": "4.0.1", - "@types/qs": "6.9.8", - "@types/node-fetch": "2.6.9", - "@types/readable-stream": "^4.0.15", - "webpack": "^5.94.0", - "ts-loader": "^9.3.1", - "jest": "29.7.0", - "@types/jest": "29.5.5", - "ts-jest": "29.1.1", - "jest-environment-jsdom": "29.7.0", - "@types/node": "17.0.33", - "prettier": "2.7.1", - "typescript": "4.6.4" + "@types/qs": "^6.9.17", + "@types/node-fetch": "^2.6.12", + "@types/readable-stream": "^4.0.18", + "webpack": "^5.97.1", + "ts-loader": "^9.5.1", + "jest": "^29.7.0", + "@types/jest": "^29.5.14", + "ts-jest": "^29.1.1", + "jest-environment-jsdom": "^29.7.0", + "@types/node": "^18.19.70", + "prettier": "^3.4.2", + "typescript": "~5.7.2" }, "browser": { "fs": false, diff --git a/reference.md b/reference.md index 65fd0e3b..fd0ceaf4 100644 --- a/reference.md +++ b/reference.md @@ -1457,9 +1457,9 @@ while (page.hasNextPage()) { The `list all companies` functionality does not work well for huge datasets, and can result in errors and performance problems when paging deeply. The Scroll API provides an efficient mechanism for iterating over all companies in a dataset. -- Each app can only have 1 scroll open at a time. You'll get an error message if you try to have more than one open per app. -- If the scroll isn't used for 1 minute, it expires and calls with that scroll param will fail -- If the end of the scroll is reached, "companies" will be empty and the scroll parameter will expire +- Each app can only have 1 scroll open at a time. You'll get an error message if you try to have more than one open per app. +- If the scroll isn't used for 1 minute, it expires and calls with that scroll param will fail +- If the end of the scroll is reached, "companies" will be empty and the scroll parameter will expire {% admonition type="info" name="Scroll Parameter" %} You can get the first page of companies by simply sending a GET request to the scroll endpoint. @@ -2376,8 +2376,8 @@ If a contact has recently been created, there is a possibility that it will not You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). There are some limitations to the amount of multiple's there can be: -- There's a limit of max 2 nested filters -- There's a limit of max 15 filters for each AND or OR group +- There's a limit of max 2 nested filters +- There's a limit of max 15 filters for each AND or OR group ### Searching for Timestamp Fields @@ -4023,8 +4023,8 @@ See the [pagination section](https://developers.intercom.com/docs/build-an-integ You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). There are some limitations to the amount of multiple's there can be: -- There's a limit of max 2 nested filters -- There's a limit of max 15 filters for each AND or OR group +- There's a limit of max 2 nested filters +- There's a limit of max 15 filters for each AND or OR group ### Accepted Fields @@ -4278,14 +4278,14 @@ await client.conversations.reply({ For managing conversations you can: -- Close a conversation -- Snooze a conversation to reopen on a future date -- Open a conversation which is `snoozed` or `closed` -- Assign a conversation to an admin and/or team. - - - - +- Close a conversation +- Snooze a conversation to reopen on a future date +- Open a conversation which is `snoozed` or `closed` +- Assign a conversation to an admin and/or team. + + + + #### 🔌 Usage @@ -4921,9 +4921,9 @@ await client.dataAttributes.update({ The events belonging to a customer can be listed by sending a GET request to `https://api.intercom.io/events` with a user or lead identifier along with a `type` parameter. The identifier parameter can be one of `user_id`, `email` or `intercom_user_id`. The `type` parameter value must be `user`. -- `https://api.intercom.io/events?type=user&user_id={user_id}` -- `https://api.intercom.io/events?type=user&email={email}` -- `https://api.intercom.io/events?type=user&intercom_user_id={id}` (this call can be used to list leads) +- `https://api.intercom.io/events?type=user&user_id={user_id}` +- `https://api.intercom.io/events?type=user&email={email}` +- `https://api.intercom.io/events?type=user&intercom_user_id={id}` (this call can be used to list leads) The `email` parameter value should be [url encoded](http://en.wikipedia.org/wiki/Percent-encoding) when sending. @@ -5015,9 +5015,9 @@ When submitting events for Leads, you will need to specify the Lead's `id`. **Metadata behaviour** -- We currently limit the number of tracked metadata keys to 10 per event. Once the quota is reached, we ignore any further keys we receive. The first 10 metadata keys are determined by the order in which they are sent in with the event. -- It is not possible to change the metadata keys once the event has been sent. A new event will need to be created with the new keys and you can archive the old one. -- There might be up to 24 hrs delay when you send a new metadata for an existing event. +- We currently limit the number of tracked metadata keys to 10 per event. Once the quota is reached, we ignore any further keys we receive. The first 10 metadata keys are determined by the order in which they are sent in with the event. +- It is not possible to change the metadata keys once the event has been sent. A new event will need to be created with the new keys and you can archive the old one. +- There might be up to 24 hrs delay when you send a new metadata for an existing event. **Event de-duplication** @@ -5027,15 +5027,15 @@ Duplicated events are responded to using the normal `202 Accepted` code - an err ### HTTP API Responses -- Successful responses to submitted events return `202 Accepted` with an empty body. -- Unauthorised access will be rejected with a `401 Unauthorized` or `403 Forbidden` response code. -- Events sent about users that cannot be found will return a `404 Not Found`. -- Event lists containing duplicate events will have those duplicates ignored. -- Server errors will return a `500` response code and may contain an error message in the body. - - - - +- Successful responses to submitted events return `202 Accepted` with an empty body. +- Unauthorised access will be rejected with a `401 Unauthorized` or `403 Forbidden` response code. +- Events sent about users that cannot be found will return a `404 Not Found`. +- Event lists containing duplicate events will have those duplicates ignored. +- Server errors will return a `500` response code and may contain an error message in the body. + + + + #### 🔌 Usage @@ -6488,8 +6488,8 @@ See the [pagination section](https://developers.intercom.com/docs/build-an-integ You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). There are some limitations to the amount of multiples there can be: -- There's a limit of max 2 nested filters -- There's a limit of max 15 filters for each AND or OR group +- There's a limit of max 2 nested filters +- There's a limit of max 15 filters for each AND or OR group ### Accepted Fields diff --git a/scripts/rename-to-esm-files.js b/scripts/rename-to-esm-files.js new file mode 100644 index 00000000..81dac6a7 --- /dev/null +++ b/scripts/rename-to-esm-files.js @@ -0,0 +1,115 @@ +#!/usr/bin/env node + +const fs = require("fs").promises; +const path = require("path"); + +const extensionMap = { + ".js": ".mjs", + ".d.ts": ".d.mts", +}; +const oldExtensions = Object.keys(extensionMap); + +async function findFiles(rootPath) { + const files = []; + + async function scan(directory) { + const entries = await fs.readdir(directory, { withFileTypes: true }); + + for (const entry of entries) { + const fullPath = path.join(directory, entry.name); + + if (entry.isDirectory()) { + if (entry.name !== "node_modules" && !entry.name.startsWith(".")) { + await scan(fullPath); + } + } else if (entry.isFile()) { + if (oldExtensions.some((ext) => entry.name.endsWith(ext))) { + files.push(fullPath); + } + } + } + } + + await scan(rootPath); + return files; +} + +async function updateFiles(files) { + const updatedFiles = []; + for (const file of files) { + const updated = await updateFileContents(file); + updatedFiles.push(updated); + } + + console.log(`Updated imports in ${updatedFiles.length} files.`); +} + +async function updateFileContents(file) { + const content = await fs.readFile(file, "utf8"); + + let newContent = content; + // Update each extension type defined in the map + for (const [oldExt, newExt] of Object.entries(extensionMap)) { + const regex = new RegExp(`(import|export)(.+from\\s+['"])(\\.\\.?\\/[^'"]+)(\\${oldExt})(['"])`, "g"); + newContent = newContent.replace(regex, `$1$2$3${newExt}$5`); + } + + if (content !== newContent) { + await fs.writeFile(file, newContent, "utf8"); + return true; + } + return false; +} + +async function renameFiles(files) { + let counter = 0; + for (const file of files) { + const ext = oldExtensions.find((ext) => file.endsWith(ext)); + const newExt = extensionMap[ext]; + + if (newExt) { + const newPath = file.slice(0, -ext.length) + newExt; + await fs.rename(file, newPath); + counter++; + } + } + + console.log(`Renamed ${counter} files.`); +} + +async function main() { + try { + const targetDir = process.argv[2]; + if (!targetDir) { + console.error("Please provide a target directory"); + process.exit(1); + } + + const targetPath = path.resolve(targetDir); + const targetStats = await fs.stat(targetPath); + + if (!targetStats.isDirectory()) { + console.error("The provided path is not a directory"); + process.exit(1); + } + + console.log(`Scanning directory: ${targetDir}`); + + const files = await findFiles(targetDir); + + if (files.length === 0) { + console.log("No matching files found."); + process.exit(0); + } + + console.log(`Found ${files.length} files.`); + await updateFiles(files); + await renameFiles(files); + console.log("\nDone!"); + } catch (error) { + console.error("An error occurred:", error.message); + process.exit(1); + } +} + +main(); diff --git a/src/Client.ts b/src/Client.ts index 3559a154..3e4a074b 100644 --- a/src/Client.ts +++ b/src/Client.ts @@ -26,8 +26,10 @@ import { Visitors } from "./api/resources/visitors/client/Client"; import { News } from "./api/resources/news/client/Client"; export declare namespace IntercomClient { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -52,7 +54,7 @@ export declare namespace IntercomClient { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ diff --git a/src/api/resources/admins/client/Client.ts b/src/api/resources/admins/client/Client.ts index 88778352..4a45597e 100644 --- a/src/api/resources/admins/client/Client.ts +++ b/src/api/resources/admins/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace Admins { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Admins { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -89,16 +91,18 @@ export class Admins { public async identify(requestOptions?: Admins.RequestOptions): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "me" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "me", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -154,21 +158,23 @@ export class Admins { */ public async away( request: Intercom.ConfigureAwayAdminRequest, - requestOptions?: Admins.RequestOptions + requestOptions?: Admins.RequestOptions, ): Promise { const { admin_id: adminId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `admins/${encodeURIComponent(adminId)}/away` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `admins/${encodeURIComponent(adminId)}/away`, ), method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -230,10 +236,10 @@ export class Admins { */ public async listAllActivityLogs( request: Intercom.ListAllActivityLogsRequest, - requestOptions?: Admins.RequestOptions + requestOptions?: Admins.RequestOptions, ): Promise { const { created_at_after: createdAtAfter, created_at_before: createdAtBefore } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; _queryParams["created_at_after"] = createdAtAfter; if (createdAtBefore != null) { _queryParams["created_at_before"] = createdAtBefore; @@ -241,16 +247,18 @@ export class Admins { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "admins/activity_logs" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "admins/activity_logs", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -307,16 +315,18 @@ export class Admins { public async list(requestOptions?: Admins.RequestOptions): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "admins" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "admins", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -375,21 +385,23 @@ export class Admins { */ public async find( request: Intercom.FindAdminRequest, - requestOptions?: Admins.RequestOptions + requestOptions?: Admins.RequestOptions, ): Promise { const { admin_id: adminId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `admins/${encodeURIComponent(adminId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `admins/${encodeURIComponent(adminId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -438,7 +450,8 @@ export class Admins { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/articles/client/Client.ts b/src/api/resources/articles/client/Client.ts index 660e6d8c..f9b802c6 100644 --- a/src/api/resources/articles/client/Client.ts +++ b/src/api/resources/articles/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace Articles { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Articles { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -90,11 +92,11 @@ export class Articles { */ public async list( request: Intercom.ListArticlesRequest = {}, - requestOptions?: Articles.RequestOptions + requestOptions?: Articles.RequestOptions, ): Promise> { const list = async (request: Intercom.ListArticlesRequest): Promise => { const { page, per_page: perPage } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (page != null) { _queryParams["page"] = page.toString(); } @@ -103,17 +105,18 @@ export class Articles { } const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "articles" + "articles", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -207,20 +210,22 @@ export class Articles { */ public async create( request: Intercom.CreateArticleRequest, - requestOptions?: Articles.RequestOptions + requestOptions?: Articles.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "articles" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "articles", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -282,21 +287,23 @@ export class Articles { */ public async find( request: Intercom.FindArticleRequest, - requestOptions?: Articles.RequestOptions + requestOptions?: Articles.RequestOptions, ): Promise { const { article_id: articleId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `articles/${encodeURIComponent(articleId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `articles/${encodeURIComponent(articleId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -359,21 +366,23 @@ export class Articles { */ public async update( request: Intercom.UpdateArticleRequest, - requestOptions?: Articles.RequestOptions + requestOptions?: Articles.RequestOptions, ): Promise { const { article_id: articleId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `articles/${encodeURIComponent(articleId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `articles/${encodeURIComponent(articleId)}`, ), method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -435,21 +444,23 @@ export class Articles { */ public async delete( request: Intercom.DeleteArticleRequest, - requestOptions?: Articles.RequestOptions + requestOptions?: Articles.RequestOptions, ): Promise { const { article_id: articleId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `articles/${encodeURIComponent(articleId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `articles/${encodeURIComponent(articleId)}`, ), method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -510,10 +521,10 @@ export class Articles { */ public async search( request: Intercom.SearchArticlesRequest = {}, - requestOptions?: Articles.RequestOptions + requestOptions?: Articles.RequestOptions, ): Promise { const { phrase, state, help_center_id: helpCenterId, highlight } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (phrase != null) { _queryParams["phrase"] = phrase; } @@ -532,16 +543,18 @@ export class Articles { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "articles/search" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "articles/search", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -589,7 +602,8 @@ export class Articles { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/companies/client/Client.ts b/src/api/resources/companies/client/Client.ts index 9ff6fdb5..73e1367a 100644 --- a/src/api/resources/companies/client/Client.ts +++ b/src/api/resources/companies/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace Companies { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Companies { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -102,10 +104,10 @@ export class Companies { */ public async retrieve( request: Intercom.RetrieveCompanyRequest = {}, - requestOptions?: Companies.RequestOptions + requestOptions?: Companies.RequestOptions, ): Promise { const { name, company_id: companyId, tag_id: tagId, segment_id: segmentId, page, per_page: perPage } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (name != null) { _queryParams["name"] = name; } @@ -132,16 +134,18 @@ export class Companies { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "companies" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "companies", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -216,20 +220,22 @@ export class Companies { */ public async createOrUpdate( request: Intercom.CreateOrUpdateCompanyRequest = {}, - requestOptions?: Companies.RequestOptions + requestOptions?: Companies.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "companies" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "companies", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -291,21 +297,23 @@ export class Companies { */ public async find( request: Intercom.FindCompanyRequest, - requestOptions?: Companies.RequestOptions + requestOptions?: Companies.RequestOptions, ): Promise { const { company_id: companyId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(companyId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(companyId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -370,21 +378,23 @@ export class Companies { */ public async update( request: Intercom.UpdateCompanyRequest, - requestOptions?: Companies.RequestOptions + requestOptions?: Companies.RequestOptions, ): Promise { const { company_id: companyId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(companyId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(companyId)}`, ), method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -445,21 +455,23 @@ export class Companies { */ public async delete( request: Intercom.DeleteCompanyRequest, - requestOptions?: Companies.RequestOptions + requestOptions?: Companies.RequestOptions, ): Promise { const { company_id: companyId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(companyId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(companyId)}`, ), method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -520,10 +532,10 @@ export class Companies { */ public async listAttachedContacts( request: Intercom.ListAttachedContactsRequest, - requestOptions?: Companies.RequestOptions + requestOptions?: Companies.RequestOptions, ): Promise { const { company_id: companyId, page, per_page: perPage } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (page != null) { _queryParams["page"] = page.toString(); } @@ -534,16 +546,18 @@ export class Companies { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(companyId)}/contacts` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(companyId)}/contacts`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -582,7 +596,7 @@ export class Companies { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /companies/{company_id}/contacts." + "Timeout exceeded when calling GET /companies/{company_id}/contacts.", ); case "unknown": throw new errors.IntercomError({ @@ -607,21 +621,23 @@ export class Companies { */ public async listAttachedSegments( request: Intercom.ListSegmentsAttachedToCompanyRequest, - requestOptions?: Companies.RequestOptions + requestOptions?: Companies.RequestOptions, ): Promise { const { company_id: companyId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(companyId)}/segments` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(companyId)}/segments`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -659,7 +675,7 @@ export class Companies { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /companies/{company_id}/segments." + "Timeout exceeded when calling GET /companies/{company_id}/segments.", ); case "unknown": throw new errors.IntercomError({ @@ -691,11 +707,11 @@ export class Companies { */ public async list( request: Intercom.ListCompaniesRequest = {}, - requestOptions?: Companies.RequestOptions + requestOptions?: Companies.RequestOptions, ): Promise> { const list = async (request: Intercom.ListCompaniesRequest): Promise => { const { page, per_page: perPage, order } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (page != null) { _queryParams["page"] = page.toString(); } @@ -707,17 +723,18 @@ export class Companies { } const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "companies/list" + "companies/list", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -797,27 +814,28 @@ export class Companies { */ public async scroll( request: Intercom.ScrollCompaniesRequest = {}, - requestOptions?: Companies.RequestOptions + requestOptions?: Companies.RequestOptions, ): Promise> { const list = async (request: Intercom.ScrollCompaniesRequest): Promise => { const { scroll_param: scrollParam } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (scrollParam != null) { _queryParams["scroll_param"] = scrollParam; } const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "companies/scroll" + "companies/scroll", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -898,21 +916,23 @@ export class Companies { */ public async attachContact( request: Intercom.AttachContactToCompanyRequest, - requestOptions?: Companies.RequestOptions + requestOptions?: Companies.RequestOptions, ): Promise { const { contact_id: contactId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/companies` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/companies`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -953,7 +973,7 @@ export class Companies { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /contacts/{contact_id}/companies." + "Timeout exceeded when calling POST /contacts/{contact_id}/companies.", ); case "unknown": throw new errors.IntercomError({ @@ -979,21 +999,23 @@ export class Companies { */ public async detachContact( request: Intercom.DetachContactFromCompanyRequest, - requestOptions?: Companies.RequestOptions + requestOptions?: Companies.RequestOptions, ): Promise { const { contact_id: contactId, company_id: companyId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/companies/${encodeURIComponent(companyId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/companies/${encodeURIComponent(companyId)}`, ), method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1031,7 +1053,7 @@ export class Companies { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /contacts/{contact_id}/companies/{company_id}." + "Timeout exceeded when calling DELETE /contacts/{contact_id}/companies/{company_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -1044,7 +1066,8 @@ export class Companies { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/contacts/client/Client.ts b/src/api/resources/contacts/client/Client.ts index 28fae748..2f4b253e 100644 --- a/src/api/resources/contacts/client/Client.ts +++ b/src/api/resources/contacts/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace Contacts { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Contacts { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -89,13 +91,13 @@ export class Contacts { */ public async listAttachedCompanies( request: Intercom.ListAttachedCompaniesRequest, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise> { const list = async ( - request: Intercom.ListAttachedCompaniesRequest + request: Intercom.ListAttachedCompaniesRequest, ): Promise => { const { contact_id: contactId, page, per_page: perPage } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (page != null) { _queryParams["page"] = page.toString(); } @@ -104,17 +106,18 @@ export class Contacts { } const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/companies` + `contacts/${encodeURIComponent(contactId)}/companies`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -151,7 +154,7 @@ export class Contacts { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /contacts/{contact_id}/companies." + "Timeout exceeded when calling GET /contacts/{contact_id}/companies.", ); case "unknown": throw new errors.IntercomError({ @@ -187,21 +190,23 @@ export class Contacts { */ public async listAttachedSegments( request: Intercom.ListSegmentsAttachedToContactRequest, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise { const { contact_id: contactId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/segments` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/segments`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -239,7 +244,7 @@ export class Contacts { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /contacts/{contact_id}/segments." + "Timeout exceeded when calling GET /contacts/{contact_id}/segments.", ); case "unknown": throw new errors.IntercomError({ @@ -270,21 +275,23 @@ export class Contacts { */ public async listAttachedSubscriptions( request: Intercom.ListAttachedSubscriptionsRequest, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise { const { contact_id: contactId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/subscriptions` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/subscriptions`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -322,7 +329,7 @@ export class Contacts { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /contacts/{contact_id}/subscriptions." + "Timeout exceeded when calling GET /contacts/{contact_id}/subscriptions.", ); case "unknown": throw new errors.IntercomError({ @@ -362,21 +369,23 @@ export class Contacts { */ public async attachSubscription( request: Intercom.AttachSubscriptionToContactRequest, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise { const { contact_id: contactId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/subscriptions` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/subscriptions`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -415,7 +424,7 @@ export class Contacts { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /contacts/{contact_id}/subscriptions." + "Timeout exceeded when calling POST /contacts/{contact_id}/subscriptions.", ); case "unknown": throw new errors.IntercomError({ @@ -441,21 +450,23 @@ export class Contacts { */ public async detachSubscription( request: Intercom.DetachSubscriptionFromContactRequest, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise { const { contact_id: contactId, subscription_id: subscriptionId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/subscriptions/${encodeURIComponent(subscriptionId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/subscriptions/${encodeURIComponent(subscriptionId)}`, ), method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -493,7 +504,7 @@ export class Contacts { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /contacts/{contact_id}/subscriptions/{subscription_id}." + "Timeout exceeded when calling DELETE /contacts/{contact_id}/subscriptions/{subscription_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -518,21 +529,23 @@ export class Contacts { */ public async listAttachedTags( request: Intercom.ListTagsAttachedToContactRequest, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise { const { contact_id: contactId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/tags` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/tags`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -592,21 +605,23 @@ export class Contacts { */ public async find( request: Intercom.FindContactRequest, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise { const { contact_id: contactId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -666,21 +681,23 @@ export class Contacts { */ public async update( request: Intercom.UpdateContactRequest, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise { const { contact_id: contactId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}`, ), method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -739,21 +756,23 @@ export class Contacts { */ public async delete( request: Intercom.DeleteContactRequest, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise { const { contact_id: contactId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}`, ), method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -812,20 +831,22 @@ export class Contacts { */ public async mergeLeadInUser( request: Intercom.MergeContactsRequest, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "contacts/merge" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "contacts/merge", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -992,22 +1013,23 @@ export class Contacts { */ public async search( request: Intercom.SearchRequest, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise> { const list = async (request: Intercom.SearchRequest): Promise => { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "contacts/search" + "contacts/search", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1054,7 +1076,7 @@ export class Contacts { getItems: (response) => response?.data ?? [], loadPage: (response) => { return list( - core.setObjectProperty(request, "pagination.starting_after", response?.pages?.next?.starting_after) + core.setObjectProperty(request, "pagination.starting_after", response?.pages?.next?.starting_after), ); }, }); @@ -1077,11 +1099,11 @@ export class Contacts { */ public async list( request: Intercom.ListContactsRequest = {}, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise> { const list = async (request: Intercom.ListContactsRequest): Promise => { const { page, per_page: perPage, starting_after: startingAfter } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (page != null) { _queryParams["page"] = page.toString(); } @@ -1093,17 +1115,18 @@ export class Contacts { } const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "contacts" + "contacts", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1169,20 +1192,22 @@ export class Contacts { */ public async create( request: Intercom.CreateContactRequest, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "contacts" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "contacts", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1239,21 +1264,23 @@ export class Contacts { */ public async archive( request: Intercom.ArchiveContactRequest, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise { const { contact_id: contactId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/archive` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/archive`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1284,7 +1311,7 @@ export class Contacts { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /contacts/{contact_id}/archive." + "Timeout exceeded when calling POST /contacts/{contact_id}/archive.", ); case "unknown": throw new errors.IntercomError({ @@ -1306,21 +1333,23 @@ export class Contacts { */ public async unarchive( request: Intercom.UnarchiveContactRequest, - requestOptions?: Contacts.RequestOptions + requestOptions?: Contacts.RequestOptions, ): Promise { const { contact_id: contactId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/unarchive` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/unarchive`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1351,7 +1380,7 @@ export class Contacts { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /contacts/{contact_id}/unarchive." + "Timeout exceeded when calling POST /contacts/{contact_id}/unarchive.", ); case "unknown": throw new errors.IntercomError({ @@ -1364,7 +1393,8 @@ export class Contacts { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/conversations/client/Client.ts b/src/api/resources/conversations/client/Client.ts index df170958..5e35fcec 100644 --- a/src/api/resources/conversations/client/Client.ts +++ b/src/api/resources/conversations/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace Conversations { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Conversations { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -93,13 +95,13 @@ export class Conversations { */ public async list( request: Intercom.ListConversationsRequest = {}, - requestOptions?: Conversations.RequestOptions + requestOptions?: Conversations.RequestOptions, ): Promise> { const list = async ( - request: Intercom.ListConversationsRequest + request: Intercom.ListConversationsRequest, ): Promise => { const { per_page: perPage, starting_after: startingAfter } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (perPage != null) { _queryParams["per_page"] = perPage.toString(); } @@ -108,17 +110,18 @@ export class Conversations { } const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "conversations" + "conversations", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -209,20 +212,22 @@ export class Conversations { */ public async create( request: Intercom.CreateConversationRequest, - requestOptions?: Conversations.RequestOptions + requestOptions?: Conversations.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "conversations" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "conversations", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -297,26 +302,28 @@ export class Conversations { */ public async find( request: Intercom.FindConversationRequest, - requestOptions?: Conversations.RequestOptions + requestOptions?: Conversations.RequestOptions, ): Promise { const { conversation_id: conversationId, display_as: displayAs } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (displayAs != null) { _queryParams["display_as"] = displayAs; } const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -357,7 +364,7 @@ export class Conversations { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /conversations/{conversation_id}." + "Timeout exceeded when calling GET /conversations/{conversation_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -394,26 +401,28 @@ export class Conversations { */ public async update( request: Intercom.UpdateConversationRequest, - requestOptions?: Conversations.RequestOptions + requestOptions?: Conversations.RequestOptions, ): Promise { const { conversation_id: conversationId, display_as: displayAs, ..._body } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (displayAs != null) { _queryParams["display_as"] = displayAs; } const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}`, ), method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -455,7 +464,7 @@ export class Conversations { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /conversations/{conversation_id}." + "Timeout exceeded when calling PUT /conversations/{conversation_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -585,22 +594,23 @@ export class Conversations { */ public async search( request: Intercom.SearchRequest, - requestOptions?: Conversations.RequestOptions + requestOptions?: Conversations.RequestOptions, ): Promise> { const list = async (request: Intercom.SearchRequest): Promise => { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "conversations/search" + "conversations/search", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -642,7 +652,7 @@ export class Conversations { getItems: (response) => response?.conversations ?? [], loadPage: (response) => { return list( - core.setObjectProperty(request, "pagination.starting_after", response?.pages?.next?.starting_after) + core.setObjectProperty(request, "pagination.starting_after", response?.pages?.next?.starting_after), ); }, }); @@ -704,21 +714,23 @@ export class Conversations { */ public async reply( request: Intercom.ReplyToConversationRequest, - requestOptions?: Conversations.RequestOptions + requestOptions?: Conversations.RequestOptions, ): Promise { const { conversation_id: conversationId, body: _body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/reply` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/reply`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -759,7 +771,7 @@ export class Conversations { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{conversation_id}/reply." + "Timeout exceeded when calling POST /conversations/{conversation_id}/reply.", ); case "unknown": throw new errors.IntercomError({ @@ -824,21 +836,23 @@ export class Conversations { */ public async manage( request: Intercom.ManageConversationPartsRequest, - requestOptions?: Conversations.RequestOptions + requestOptions?: Conversations.RequestOptions, ): Promise { const { conversation_id: conversationId, body: _body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/parts` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/parts`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -879,7 +893,7 @@ export class Conversations { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{conversation_id}/parts." + "Timeout exceeded when calling POST /conversations/{conversation_id}/parts.", ); case "unknown": throw new errors.IntercomError({ @@ -911,21 +925,23 @@ export class Conversations { */ public async runAssignmentRules( request: Intercom.AutoAssignConversationRequest, - requestOptions?: Conversations.RequestOptions + requestOptions?: Conversations.RequestOptions, ): Promise { const { conversation_id: conversationId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/run_assignment_rules` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/run_assignment_rules`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -965,7 +981,7 @@ export class Conversations { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{conversation_id}/run_assignment_rules." + "Timeout exceeded when calling POST /conversations/{conversation_id}/run_assignment_rules.", ); case "unknown": throw new errors.IntercomError({ @@ -1008,21 +1024,23 @@ export class Conversations { */ public async attachContactAsAdmin( request: Intercom.AttachContactToConversationRequest, - requestOptions?: Conversations.RequestOptions + requestOptions?: Conversations.RequestOptions, ): Promise { const { conversation_id: conversationId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/customers` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/customers`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1063,7 +1081,7 @@ export class Conversations { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{conversation_id}/customers." + "Timeout exceeded when calling POST /conversations/{conversation_id}/customers.", ); case "unknown": throw new errors.IntercomError({ @@ -1096,21 +1114,23 @@ export class Conversations { */ public async detachContactAsAdmin( request: Intercom.DetachContactFromConversationRequest, - requestOptions?: Conversations.RequestOptions + requestOptions?: Conversations.RequestOptions, ): Promise { const { conversation_id: conversationId, contact_id: contactId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/customers/${encodeURIComponent(contactId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/customers/${encodeURIComponent(contactId)}`, ), method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1153,7 +1173,7 @@ export class Conversations { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /conversations/{conversation_id}/customers/{contact_id}." + "Timeout exceeded when calling DELETE /conversations/{conversation_id}/customers/{contact_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -1191,20 +1211,22 @@ export class Conversations { */ public async redactConversationPart( request: Intercom.RedactConversationRequest, - requestOptions?: Conversations.RequestOptions + requestOptions?: Conversations.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "conversations/redact" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "conversations/redact", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1272,21 +1294,23 @@ export class Conversations { */ public async convertToTicket( request: Intercom.ConvertConversationToTicketRequest, - requestOptions?: Conversations.RequestOptions + requestOptions?: Conversations.RequestOptions, ): Promise { const { conversation_id: conversationId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/convert` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/convert`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1323,7 +1347,7 @@ export class Conversations { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{conversation_id}/convert." + "Timeout exceeded when calling POST /conversations/{conversation_id}/convert.", ); case "unknown": throw new errors.IntercomError({ @@ -1336,7 +1360,8 @@ export class Conversations { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/dataAttributes/client/Client.ts b/src/api/resources/dataAttributes/client/Client.ts index 303e547a..614d3359 100644 --- a/src/api/resources/dataAttributes/client/Client.ts +++ b/src/api/resources/dataAttributes/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace DataAttributes { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace DataAttributes { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -86,10 +88,10 @@ export class DataAttributes { */ public async list( request: Intercom.ListDataAttributesRequest = {}, - requestOptions?: DataAttributes.RequestOptions + requestOptions?: DataAttributes.RequestOptions, ): Promise { const { model, include_archived: includeArchived } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (model != null) { _queryParams["model"] = model; } @@ -100,16 +102,18 @@ export class DataAttributes { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "data_attributes" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "data_attributes", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -208,20 +212,22 @@ export class DataAttributes { */ public async create( request: Intercom.CreateDataAttributeRequest, - requestOptions?: DataAttributes.RequestOptions + requestOptions?: DataAttributes.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "data_attributes" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "data_attributes", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -316,21 +322,23 @@ export class DataAttributes { */ public async update( request: Intercom.UpdateDataAttributeRequest, - requestOptions?: DataAttributes.RequestOptions + requestOptions?: DataAttributes.RequestOptions, ): Promise { const { data_attribute_id: dataAttributeId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `data_attributes/${encodeURIComponent(dataAttributeId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `data_attributes/${encodeURIComponent(dataAttributeId)}`, ), method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -373,7 +381,7 @@ export class DataAttributes { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /data_attributes/{data_attribute_id}." + "Timeout exceeded when calling PUT /data_attributes/{data_attribute_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -386,7 +394,8 @@ export class DataAttributes { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/dataExport/client/Client.ts b/src/api/resources/dataExport/client/Client.ts index 1696efc0..548a7df9 100644 --- a/src/api/resources/dataExport/client/Client.ts +++ b/src/api/resources/dataExport/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace DataExport { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace DataExport { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -101,20 +103,22 @@ export class DataExport { */ public async create( request: Intercom.CreateDataExportRequest, - requestOptions?: DataExport.RequestOptions + requestOptions?: DataExport.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "export/content/data" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "export/content/data", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -170,21 +174,23 @@ export class DataExport { */ public async find( request: Intercom.FindDataExportRequest, - requestOptions?: DataExport.RequestOptions + requestOptions?: DataExport.RequestOptions, ): Promise { const { job_identifier: jobIdentifier } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `export/content/data/${encodeURIComponent(jobIdentifier)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `export/content/data/${encodeURIComponent(jobIdentifier)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -215,7 +221,7 @@ export class DataExport { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /export/content/data/{job_identifier}." + "Timeout exceeded when calling GET /export/content/data/{job_identifier}.", ); case "unknown": throw new errors.IntercomError({ @@ -237,21 +243,23 @@ export class DataExport { */ public async cancel( request: Intercom.CancelDataExportRequest, - requestOptions?: DataExport.RequestOptions + requestOptions?: DataExport.RequestOptions, ): Promise { const { job_identifier: jobIdentifier } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `export/cancel/${encodeURIComponent(jobIdentifier)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `export/cancel/${encodeURIComponent(jobIdentifier)}`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -282,7 +290,7 @@ export class DataExport { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /export/cancel/{job_identifier}." + "Timeout exceeded when calling POST /export/cancel/{job_identifier}.", ); case "unknown": throw new errors.IntercomError({ @@ -310,21 +318,23 @@ export class DataExport { */ public async download( request: Intercom.DownloadDataExportRequest, - requestOptions?: DataExport.RequestOptions + requestOptions?: DataExport.RequestOptions, ): Promise { const { job_identifier: jobIdentifier } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `download/content/data/${encodeURIComponent(jobIdentifier)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `download/content/data/${encodeURIComponent(jobIdentifier)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -355,7 +365,7 @@ export class DataExport { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /download/content/data/{job_identifier}." + "Timeout exceeded when calling GET /download/content/data/{job_identifier}.", ); case "unknown": throw new errors.IntercomError({ @@ -368,7 +378,8 @@ export class DataExport { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/events/client/Client.ts b/src/api/resources/events/client/Client.ts index d4fcbd97..8afe9b6a 100644 --- a/src/api/resources/events/client/Client.ts +++ b/src/api/resources/events/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace Events { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Events { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -98,7 +100,7 @@ export class Events { */ public async list( request: Intercom.ListEventsRequest, - requestOptions?: Events.RequestOptions + requestOptions?: Events.RequestOptions, ): Promise { const { user_id: userId, @@ -108,7 +110,7 @@ export class Events { summary, per_page: perPage, } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (userId != null) { _queryParams["user_id"] = userId; } @@ -132,16 +134,18 @@ export class Events { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "events" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "events", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -242,20 +246,22 @@ export class Events { */ public async create( request: Intercom.CreateDataEventRequest, - requestOptions?: Events.RequestOptions + requestOptions?: Events.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "events" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "events", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -312,20 +318,22 @@ export class Events { */ public async summaries( request: Intercom.ListEventSummariesRequest = {}, - requestOptions?: Events.RequestOptions + requestOptions?: Events.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "events/summaries" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "events/summaries", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -373,7 +381,8 @@ export class Events { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/helpCenters/client/Client.ts b/src/api/resources/helpCenters/client/Client.ts index a0e94871..a6e12499 100644 --- a/src/api/resources/helpCenters/client/Client.ts +++ b/src/api/resources/helpCenters/client/Client.ts @@ -10,8 +10,10 @@ import * as errors from "../../../../errors/index"; import { Collections } from "../resources/collections/client/Client"; export declare namespace HelpCenters { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -36,7 +38,7 @@ export declare namespace HelpCenters { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -93,21 +95,23 @@ export class HelpCenters { */ public async find( request: Intercom.FindHelpCenterRequest, - requestOptions?: HelpCenters.RequestOptions + requestOptions?: HelpCenters.RequestOptions, ): Promise { const { help_center_id: helpCenterId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `help_center/help_centers/${encodeURIComponent(helpCenterId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `help_center/help_centers/${encodeURIComponent(helpCenterId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -145,7 +149,7 @@ export class HelpCenters { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /help_center/help_centers/{help_center_id}." + "Timeout exceeded when calling GET /help_center/help_centers/{help_center_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -167,11 +171,11 @@ export class HelpCenters { */ public async list( request: Intercom.ListHelpCentersRequest = {}, - requestOptions?: HelpCenters.RequestOptions + requestOptions?: HelpCenters.RequestOptions, ): Promise> { const list = async (request: Intercom.ListHelpCentersRequest): Promise => { const { page, per_page: perPage } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (page != null) { _queryParams["page"] = page.toString(); } @@ -180,17 +184,18 @@ export class HelpCenters { } const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "help_center/help_centers" + "help_center/help_centers", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -225,7 +230,7 @@ export class HelpCenters { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /help_center/help_centers." + "Timeout exceeded when calling GET /help_center/help_centers.", ); case "unknown": throw new errors.IntercomError({ @@ -249,7 +254,8 @@ export class HelpCenters { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/helpCenters/resources/collections/client/Client.ts b/src/api/resources/helpCenters/resources/collections/client/Client.ts index 1daef23b..a7f5a013 100644 --- a/src/api/resources/helpCenters/resources/collections/client/Client.ts +++ b/src/api/resources/helpCenters/resources/collections/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../../../errors/index"; export declare namespace Collections { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Collections { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -85,11 +87,11 @@ export class Collections { */ public async list( request: Intercom.helpCenters.ListCollectionsRequest = {}, - requestOptions?: Collections.RequestOptions + requestOptions?: Collections.RequestOptions, ): Promise> { const list = async (request: Intercom.helpCenters.ListCollectionsRequest): Promise => { const { page, per_page: perPage } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (page != null) { _queryParams["page"] = page.toString(); } @@ -98,17 +100,18 @@ export class Collections { } const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "help_center/collections" + "help_center/collections", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -143,7 +146,7 @@ export class Collections { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /help_center/collections." + "Timeout exceeded when calling GET /help_center/collections.", ); case "unknown": throw new errors.IntercomError({ @@ -185,20 +188,22 @@ export class Collections { */ public async create( request: Intercom.helpCenters.CreateCollectionRequest, - requestOptions?: Collections.RequestOptions + requestOptions?: Collections.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "help_center/collections" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "help_center/collections", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -260,21 +265,23 @@ export class Collections { */ public async find( request: Intercom.helpCenters.FindCollectionRequest, - requestOptions?: Collections.RequestOptions + requestOptions?: Collections.RequestOptions, ): Promise { const { collection_id: collectionId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `help_center/collections/${encodeURIComponent(collectionId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `help_center/collections/${encodeURIComponent(collectionId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -312,7 +319,7 @@ export class Collections { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /help_center/collections/{collection_id}." + "Timeout exceeded when calling GET /help_center/collections/{collection_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -338,21 +345,23 @@ export class Collections { */ public async update( request: Intercom.helpCenters.UpdateCollectionRequest, - requestOptions?: Collections.RequestOptions + requestOptions?: Collections.RequestOptions, ): Promise { const { collection_id: collectionId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `help_center/collections/${encodeURIComponent(collectionId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `help_center/collections/${encodeURIComponent(collectionId)}`, ), method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -391,7 +400,7 @@ export class Collections { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /help_center/collections/{collection_id}." + "Timeout exceeded when calling PUT /help_center/collections/{collection_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -416,21 +425,23 @@ export class Collections { */ public async delete( request: Intercom.helpCenters.DeleteCollectionRequest, - requestOptions?: Collections.RequestOptions + requestOptions?: Collections.RequestOptions, ): Promise { const { collection_id: collectionId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `help_center/collections/${encodeURIComponent(collectionId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `help_center/collections/${encodeURIComponent(collectionId)}`, ), method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -468,7 +479,7 @@ export class Collections { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /help_center/collections/{collection_id}." + "Timeout exceeded when calling DELETE /help_center/collections/{collection_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -481,7 +492,8 @@ export class Collections { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/messages/client/Client.ts b/src/api/resources/messages/client/Client.ts index e5ed8541..28f5c2f2 100644 --- a/src/api/resources/messages/client/Client.ts +++ b/src/api/resources/messages/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace Messages { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Messages { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -166,20 +168,22 @@ export class Messages { */ public async create( request: Intercom.CreateMessageRequest, - requestOptions?: Messages.RequestOptions + requestOptions?: Messages.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "messages" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "messages", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -233,7 +237,8 @@ export class Messages { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/news/client/Client.ts b/src/api/resources/news/client/Client.ts index 22771259..2b6dd6ab 100644 --- a/src/api/resources/news/client/Client.ts +++ b/src/api/resources/news/client/Client.ts @@ -8,8 +8,10 @@ import { Items } from "../resources/items/client/Client"; import { Feeds } from "../resources/feeds/client/Client"; export declare namespace News { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -33,37 +35,6 @@ export declare namespace News { | "Unstable"; fetcher?: core.FetchFunction; } - - interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } } export class News { diff --git a/src/api/resources/news/resources/feeds/client/Client.ts b/src/api/resources/news/resources/feeds/client/Client.ts index 010b3fe8..f9135b81 100644 --- a/src/api/resources/news/resources/feeds/client/Client.ts +++ b/src/api/resources/news/resources/feeds/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../../../errors/index"; export declare namespace Feeds { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Feeds { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -85,21 +87,23 @@ export class Feeds { */ public async listItems( request: Intercom.news.ListNewsFeedItemsRequest, - requestOptions?: Feeds.RequestOptions + requestOptions?: Feeds.RequestOptions, ): Promise { const { newsfeed_id: newsfeedId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/newsfeeds/${encodeURIComponent(newsfeedId)}/items` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `news/newsfeeds/${encodeURIComponent(newsfeedId)}/items`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -135,7 +139,7 @@ export class Feeds { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /news/newsfeeds/{newsfeed_id}/items." + "Timeout exceeded when calling GET /news/newsfeeds/{newsfeed_id}/items.", ); case "unknown": throw new errors.IntercomError({ @@ -157,16 +161,18 @@ export class Feeds { public async list(requestOptions?: Feeds.RequestOptions): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "news/newsfeeds" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "news/newsfeeds", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -224,21 +230,23 @@ export class Feeds { */ public async find( request: Intercom.news.FindNewsFeedRequest, - requestOptions?: Feeds.RequestOptions + requestOptions?: Feeds.RequestOptions, ): Promise { const { newsfeed_id: newsfeedId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/newsfeeds/${encodeURIComponent(newsfeedId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `news/newsfeeds/${encodeURIComponent(newsfeedId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -274,7 +282,7 @@ export class Feeds { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /news/newsfeeds/{newsfeed_id}." + "Timeout exceeded when calling GET /news/newsfeeds/{newsfeed_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -287,7 +295,8 @@ export class Feeds { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/news/resources/items/client/Client.ts b/src/api/resources/news/resources/items/client/Client.ts index feaf5a90..56023030 100644 --- a/src/api/resources/news/resources/items/client/Client.ts +++ b/src/api/resources/news/resources/items/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../../../errors/index"; export declare namespace Items { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Items { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -83,16 +85,18 @@ export class Items { public async list(requestOptions?: Items.RequestOptions): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "news/news_items" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "news/news_items", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -160,20 +164,22 @@ export class Items { */ public async create( request: Intercom.NewsItemRequest, - requestOptions?: Items.RequestOptions + requestOptions?: Items.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "news/news_items" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "news/news_items", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -233,21 +239,23 @@ export class Items { */ public async find( request: Intercom.news.FindNewsItemRequest, - requestOptions?: Items.RequestOptions + requestOptions?: Items.RequestOptions, ): Promise { const { news_item_id: newsItemId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/news_items/${encodeURIComponent(newsItemId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `news/news_items/${encodeURIComponent(newsItemId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -285,7 +293,7 @@ export class Items { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /news/news_items/{news_item_id}." + "Timeout exceeded when calling GET /news/news_items/{news_item_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -325,21 +333,23 @@ export class Items { */ public async update( request: Intercom.news.UpdateNewsItemRequest, - requestOptions?: Items.RequestOptions + requestOptions?: Items.RequestOptions, ): Promise { const { news_item_id: newsItemId, body: _body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/news_items/${encodeURIComponent(newsItemId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `news/news_items/${encodeURIComponent(newsItemId)}`, ), method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -378,7 +388,7 @@ export class Items { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /news/news_items/{news_item_id}." + "Timeout exceeded when calling PUT /news/news_items/{news_item_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -403,21 +413,23 @@ export class Items { */ public async delete( request: Intercom.news.DeleteNewsItemRequest, - requestOptions?: Items.RequestOptions + requestOptions?: Items.RequestOptions, ): Promise { const { news_item_id: newsItemId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/news_items/${encodeURIComponent(newsItemId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `news/news_items/${encodeURIComponent(newsItemId)}`, ), method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -455,7 +467,7 @@ export class Items { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /news/news_items/{news_item_id}." + "Timeout exceeded when calling DELETE /news/news_items/{news_item_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -468,7 +480,8 @@ export class Items { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/notes/client/Client.ts b/src/api/resources/notes/client/Client.ts index b023e823..8271ea3f 100644 --- a/src/api/resources/notes/client/Client.ts +++ b/src/api/resources/notes/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace Notes { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Notes { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -88,11 +90,11 @@ export class Notes { */ public async list( request: Intercom.ListContactNotesRequest, - requestOptions?: Notes.RequestOptions + requestOptions?: Notes.RequestOptions, ): Promise> { const list = async (request: Intercom.ListContactNotesRequest): Promise => { const { contact_id: contactId, page, per_page: perPage } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (page != null) { _queryParams["page"] = page.toString(); } @@ -101,17 +103,18 @@ export class Notes { } const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/notes` + `contacts/${encodeURIComponent(contactId)}/notes`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -146,7 +149,7 @@ export class Notes { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /contacts/{contact_id}/notes." + "Timeout exceeded when calling GET /contacts/{contact_id}/notes.", ); case "unknown": throw new errors.IntercomError({ @@ -183,21 +186,23 @@ export class Notes { */ public async create( request: Intercom.CreateContactNoteRequest, - requestOptions?: Notes.RequestOptions + requestOptions?: Notes.RequestOptions, ): Promise { const { contact_id: contactId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/notes` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/notes`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -234,7 +239,7 @@ export class Notes { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /contacts/{contact_id}/notes." + "Timeout exceeded when calling POST /contacts/{contact_id}/notes.", ); case "unknown": throw new errors.IntercomError({ @@ -259,21 +264,23 @@ export class Notes { */ public async find( request: Intercom.FindNoteRequest, - requestOptions?: Notes.RequestOptions + requestOptions?: Notes.RequestOptions, ): Promise { const { note_id: noteId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `notes/${encodeURIComponent(noteId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `notes/${encodeURIComponent(noteId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -322,7 +329,8 @@ export class Notes { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/phoneCallRedirects/client/Client.ts b/src/api/resources/phoneCallRedirects/client/Client.ts index 8ab07914..f8cc8e05 100644 --- a/src/api/resources/phoneCallRedirects/client/Client.ts +++ b/src/api/resources/phoneCallRedirects/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace PhoneCallRedirects { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace PhoneCallRedirects { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -103,20 +105,22 @@ export class PhoneCallRedirects { */ public async create( request: Intercom.CreatePhoneCallRedirectRequest, - requestOptions?: PhoneCallRedirects.RequestOptions + requestOptions?: PhoneCallRedirects.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "phone_call_redirects" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "phone_call_redirects", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -168,7 +172,8 @@ export class PhoneCallRedirects { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/segments/client/Client.ts b/src/api/resources/segments/client/Client.ts index 9a980a78..b83e7b81 100644 --- a/src/api/resources/segments/client/Client.ts +++ b/src/api/resources/segments/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace Segments { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Segments { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -86,26 +88,28 @@ export class Segments { */ public async list( request: Intercom.ListSegmentsRequest = {}, - requestOptions?: Segments.RequestOptions + requestOptions?: Segments.RequestOptions, ): Promise { const { include_count: includeCount } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; if (includeCount != null) { _queryParams["include_count"] = includeCount.toString(); } const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "segments" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "segments", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -165,21 +169,23 @@ export class Segments { */ public async find( request: Intercom.FindSegmentRequest, - requestOptions?: Segments.RequestOptions + requestOptions?: Segments.RequestOptions, ): Promise { const { segment_id: segmentId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `segments/${encodeURIComponent(segmentId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `segments/${encodeURIComponent(segmentId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -228,7 +234,8 @@ export class Segments { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/subscriptionTypes/client/Client.ts b/src/api/resources/subscriptionTypes/client/Client.ts index 249ba181..28ed27ea 100644 --- a/src/api/resources/subscriptionTypes/client/Client.ts +++ b/src/api/resources/subscriptionTypes/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace SubscriptionTypes { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace SubscriptionTypes { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -86,16 +88,18 @@ export class SubscriptionTypes { public async list(requestOptions?: SubscriptionTypes.RequestOptions): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "subscription_types" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "subscription_types", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -142,7 +146,8 @@ export class SubscriptionTypes { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/tags/client/Client.ts b/src/api/resources/tags/client/Client.ts index 68729f8a..4cb3a183 100644 --- a/src/api/resources/tags/client/Client.ts +++ b/src/api/resources/tags/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace Tags { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Tags { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -96,21 +98,23 @@ export class Tags { */ public async tagContact( request: Intercom.TagContactRequest, - requestOptions?: Tags.RequestOptions + requestOptions?: Tags.RequestOptions, ): Promise { const { contact_id: contactId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/tags` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/tags`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -149,7 +153,7 @@ export class Tags { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /contacts/{contact_id}/tags." + "Timeout exceeded when calling POST /contacts/{contact_id}/tags.", ); case "unknown": throw new errors.IntercomError({ @@ -175,21 +179,23 @@ export class Tags { */ public async untagContact( request: Intercom.UntagContactRequest, - requestOptions?: Tags.RequestOptions + requestOptions?: Tags.RequestOptions, ): Promise { const { contact_id: contactId, tag_id: tagId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/tags/${encodeURIComponent(tagId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/tags/${encodeURIComponent(tagId)}`, ), method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -227,7 +233,7 @@ export class Tags { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /contacts/{contact_id}/tags/{tag_id}." + "Timeout exceeded when calling DELETE /contacts/{contact_id}/tags/{tag_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -254,21 +260,23 @@ export class Tags { */ public async tagConversation( request: Intercom.TagConversationRequest, - requestOptions?: Tags.RequestOptions + requestOptions?: Tags.RequestOptions, ): Promise { const { conversation_id: conversationId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/tags` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/tags`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -307,7 +315,7 @@ export class Tags { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{conversation_id}/tags." + "Timeout exceeded when calling POST /conversations/{conversation_id}/tags.", ); case "unknown": throw new errors.IntercomError({ @@ -334,21 +342,23 @@ export class Tags { */ public async untagConversation( request: Intercom.UntagConversationRequest, - requestOptions?: Tags.RequestOptions + requestOptions?: Tags.RequestOptions, ): Promise { const { conversation_id: conversationId, tag_id: tagId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/tags/${encodeURIComponent(tagId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/tags/${encodeURIComponent(tagId)}`, ), method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -387,7 +397,7 @@ export class Tags { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /conversations/{conversation_id}/tags/{tag_id}." + "Timeout exceeded when calling DELETE /conversations/{conversation_id}/tags/{tag_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -409,16 +419,18 @@ export class Tags { public async list(requestOptions?: Tags.RequestOptions): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "tags" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "tags", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -511,20 +523,22 @@ export class Tags { */ public async create( request: Intercom.TagsCreateRequestBody, - requestOptions?: Tags.RequestOptions + requestOptions?: Tags.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "tags" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "tags", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -591,16 +605,18 @@ export class Tags { const { tag_id: tagId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tags/${encodeURIComponent(tagId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tags/${encodeURIComponent(tagId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -664,16 +680,18 @@ export class Tags { const { tag_id: tagId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tags/${encodeURIComponent(tagId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tags/${encodeURIComponent(tagId)}`, ), method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -738,21 +756,23 @@ export class Tags { */ public async tagTicket( request: Intercom.TagTicketRequest, - requestOptions?: Tags.RequestOptions + requestOptions?: Tags.RequestOptions, ): Promise { const { ticket_id: ticketId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(ticketId)}/tags` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(ticketId)}/tags`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -816,21 +836,23 @@ export class Tags { */ public async untagTicket( request: Intercom.UntagTicketRequest, - requestOptions?: Tags.RequestOptions + requestOptions?: Tags.RequestOptions, ): Promise { const { ticket_id: ticketId, tag_id: tagId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(ticketId)}/tags/${encodeURIComponent(tagId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(ticketId)}/tags/${encodeURIComponent(tagId)}`, ), method: "DELETE", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -869,7 +891,7 @@ export class Tags { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /tickets/{ticket_id}/tags/{tag_id}." + "Timeout exceeded when calling DELETE /tickets/{ticket_id}/tags/{tag_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -882,7 +904,8 @@ export class Tags { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/teams/client/Client.ts b/src/api/resources/teams/client/Client.ts index 3aa7071c..468b8b04 100644 --- a/src/api/resources/teams/client/Client.ts +++ b/src/api/resources/teams/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace Teams { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Teams { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -86,16 +88,18 @@ export class Teams { public async list(requestOptions?: Teams.RequestOptions): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "teams" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "teams", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -154,21 +158,23 @@ export class Teams { */ public async find( request: Intercom.FindTeamRequest, - requestOptions?: Teams.RequestOptions + requestOptions?: Teams.RequestOptions, ): Promise { const { team_id: teamId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `teams/${encodeURIComponent(teamId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `teams/${encodeURIComponent(teamId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -217,7 +223,8 @@ export class Teams { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/ticketTypes/client/Client.ts b/src/api/resources/ticketTypes/client/Client.ts index 53ca5a78..db370a8b 100644 --- a/src/api/resources/ticketTypes/client/Client.ts +++ b/src/api/resources/ticketTypes/client/Client.ts @@ -10,8 +10,10 @@ import * as errors from "../../../../errors/index"; import { Attributes } from "../resources/attributes/client/Client"; export declare namespace TicketTypes { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -36,7 +38,7 @@ export declare namespace TicketTypes { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -93,16 +95,18 @@ export class TicketTypes { public async list(requestOptions?: TicketTypes.RequestOptions): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "ticket_types" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ticket_types", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -167,20 +171,22 @@ export class TicketTypes { */ public async create( request: Intercom.CreateTicketTypeRequest, - requestOptions?: TicketTypes.RequestOptions + requestOptions?: TicketTypes.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "ticket_types" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ticket_types", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -239,21 +245,23 @@ export class TicketTypes { */ public async get( request: Intercom.FindTicketTypeRequest, - requestOptions?: TicketTypes.RequestOptions + requestOptions?: TicketTypes.RequestOptions, ): Promise { const { ticket_type_id: ticketTypeId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ticket_types/${encodeURIComponent(ticketTypeId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ticket_types/${encodeURIComponent(ticketTypeId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -289,7 +297,7 @@ export class TicketTypes { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /ticket_types/{ticket_type_id}." + "Timeout exceeded when calling GET /ticket_types/{ticket_type_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -319,21 +327,23 @@ export class TicketTypes { */ public async update( request: Intercom.UpdateTicketTypeRequest, - requestOptions?: TicketTypes.RequestOptions + requestOptions?: TicketTypes.RequestOptions, ): Promise { const { ticket_type_id: ticketTypeId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ticket_types/${encodeURIComponent(ticketTypeId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ticket_types/${encodeURIComponent(ticketTypeId)}`, ), method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -370,7 +380,7 @@ export class TicketTypes { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /ticket_types/{ticket_type_id}." + "Timeout exceeded when calling PUT /ticket_types/{ticket_type_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -383,7 +393,8 @@ export class TicketTypes { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/ticketTypes/resources/attributes/client/Client.ts b/src/api/resources/ticketTypes/resources/attributes/client/Client.ts index 86190542..0b206966 100644 --- a/src/api/resources/ticketTypes/resources/attributes/client/Client.ts +++ b/src/api/resources/ticketTypes/resources/attributes/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../../../errors/index"; export declare namespace Attributes { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Attributes { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -89,21 +91,23 @@ export class Attributes { */ public async create( request: Intercom.ticketTypes.CreateTicketTypeAttributeRequest, - requestOptions?: Attributes.RequestOptions + requestOptions?: Attributes.RequestOptions, ): Promise { const { ticket_type_id: ticketTypeId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ticket_types/${encodeURIComponent(ticketTypeId)}/attributes` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ticket_types/${encodeURIComponent(ticketTypeId)}/attributes`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -140,7 +144,7 @@ export class Attributes { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /ticket_types/{ticket_type_id}/attributes." + "Timeout exceeded when calling POST /ticket_types/{ticket_type_id}/attributes.", ); case "unknown": throw new errors.IntercomError({ @@ -166,21 +170,23 @@ export class Attributes { */ public async update( request: Intercom.ticketTypes.UpdateTicketTypeAttributeRequest, - requestOptions?: Attributes.RequestOptions + requestOptions?: Attributes.RequestOptions, ): Promise { const { ticket_type_id: ticketTypeId, attribute_id: attributeId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ticket_types/${encodeURIComponent(ticketTypeId)}/attributes/${encodeURIComponent(attributeId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ticket_types/${encodeURIComponent(ticketTypeId)}/attributes/${encodeURIComponent(attributeId)}`, ), method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -217,7 +223,7 @@ export class Attributes { }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /ticket_types/{ticket_type_id}/attributes/{attribute_id}." + "Timeout exceeded when calling PUT /ticket_types/{ticket_type_id}/attributes/{attribute_id}.", ); case "unknown": throw new errors.IntercomError({ @@ -230,7 +236,8 @@ export class Attributes { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/tickets/client/Client.ts b/src/api/resources/tickets/client/Client.ts index b4720b29..6942cd19 100644 --- a/src/api/resources/tickets/client/Client.ts +++ b/src/api/resources/tickets/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace Tickets { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Tickets { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -135,21 +137,23 @@ export class Tickets { */ public async reply( request: Intercom.ReplyToTicketRequest, - requestOptions?: Tickets.RequestOptions + requestOptions?: Tickets.RequestOptions, ): Promise { const { ticket_id: ticketId, body: _body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(ticketId)}/reply` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(ticketId)}/reply`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -219,20 +223,22 @@ export class Tickets { */ public async create( request: Intercom.CreateTicketRequest, - requestOptions?: Tickets.RequestOptions + requestOptions?: Tickets.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "tickets" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "tickets", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -291,21 +297,23 @@ export class Tickets { */ public async get( request: Intercom.FindTicketRequest, - requestOptions?: Tickets.RequestOptions + requestOptions?: Tickets.RequestOptions, ): Promise { const { ticket_id: ticketId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(ticketId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(ticketId)}`, ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -403,21 +411,23 @@ export class Tickets { */ public async update( request: Intercom.UpdateTicketRequest, - requestOptions?: Tickets.RequestOptions + requestOptions?: Tickets.RequestOptions, ): Promise { const { ticket_id: ticketId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(ticketId)}` + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(ticketId)}`, ), method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -546,22 +556,23 @@ export class Tickets { */ public async search( request: Intercom.SearchRequest, - requestOptions?: Tickets.RequestOptions + requestOptions?: Tickets.RequestOptions, ): Promise> { const list = async (request: Intercom.SearchRequest): Promise => { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "tickets/search" + "tickets/search", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -603,7 +614,7 @@ export class Tickets { getItems: (response) => response?.tickets ?? [], loadPage: (response) => { return list( - core.setObjectProperty(request, "pagination.starting_after", response?.pages?.next?.starting_after) + core.setObjectProperty(request, "pagination.starting_after", response?.pages?.next?.starting_after), ); }, }); @@ -613,7 +624,8 @@ export class Tickets { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/api/resources/visitors/client/Client.ts b/src/api/resources/visitors/client/Client.ts index dc9e4d33..29d31f04 100644 --- a/src/api/resources/visitors/client/Client.ts +++ b/src/api/resources/visitors/client/Client.ts @@ -9,8 +9,10 @@ import urlJoin from "url-join"; import * as errors from "../../../../errors/index"; export declare namespace Visitors { - interface Options { + export interface Options { environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; token?: core.Supplier; /** Override the Intercom-Version header */ version?: @@ -35,7 +37,7 @@ export declare namespace Visitors { fetcher?: core.FetchFunction; } - interface RequestOptions { + export interface RequestOptions { /** The maximum time to wait for a response in seconds. */ timeoutInSeconds?: number; /** The number of times to retry the request. Defaults to 2. */ @@ -89,23 +91,25 @@ export class Visitors { */ public async find( request: Intercom.FindVisitorRequest, - requestOptions?: Visitors.RequestOptions + requestOptions?: Visitors.RequestOptions, ): Promise { const { user_id: userId } = request; - const _queryParams: Record = {}; + const _queryParams: Record = {}; _queryParams["user_id"] = userId; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "visitors" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "visitors", ), method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -178,20 +182,22 @@ export class Visitors { */ public async update( request: Intercom.UpdateVisitorRequest, - requestOptions?: Visitors.RequestOptions + requestOptions?: Visitors.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "visitors" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "visitors", ), method: "PUT", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -263,20 +269,22 @@ export class Visitors { */ public async mergeToContact( request: Intercom.MergeVisitorToContactRequest, - requestOptions?: Visitors.RequestOptions + requestOptions?: Visitors.RequestOptions, ): Promise { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( - (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "visitors/convert" + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "visitors/convert", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "v6.1.1", - "User-Agent": "intercom-client/v6.1.1", + "X-Fern-SDK-Version": "6.2.0", + "User-Agent": "intercom-client/6.2.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -324,7 +332,8 @@ export class Visitors { const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; if (bearer == null) { throw new errors.IntercomError({ - message: "Please specify INTERCOM_API_KEY when instantiating the client.", + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", }); } diff --git a/src/core/fetcher/Fetcher.ts b/src/core/fetcher/Fetcher.ts index b8f23717..f3ee18ee 100644 --- a/src/core/fetcher/Fetcher.ts +++ b/src/core/fetcher/Fetcher.ts @@ -1,3 +1,4 @@ +import { toJson } from "../json"; import { APIResponse } from "./APIResponse"; import { createRequestUrl } from "./createRequestUrl"; import { getFetchFn } from "./getFetchFn"; @@ -14,7 +15,7 @@ export declare namespace Fetcher { method: string; contentType?: string; headers?: Record; - queryParameters?: Record; + queryParameters?: Record; body?: unknown; timeoutMs?: number; maxRetries?: number; @@ -64,7 +65,7 @@ export async function fetcherImpl(args: Fetcher.Args): Promise(args: Fetcher.Args): Promise= 200 && response.status < 400) { return { @@ -134,7 +135,7 @@ export async function fetcherImpl(args: Fetcher.Args): Promise + queryParameters?: Record, ): string { return Object.keys(queryParameters ?? {}).length > 0 ? `${baseUrl}?${qs.stringify(queryParameters, { arrayFormat: "repeat" })}` diff --git a/src/core/fetcher/getRequestBody.ts b/src/core/fetcher/getRequestBody.ts index 1138414b..fce5589c 100644 --- a/src/core/fetcher/getRequestBody.ts +++ b/src/core/fetcher/getRequestBody.ts @@ -1,3 +1,5 @@ +import { toJson } from "../json"; + export declare namespace GetRequestBody { interface Args { body: unknown; @@ -7,7 +9,7 @@ export declare namespace GetRequestBody { export async function getRequestBody({ body, type }: GetRequestBody.Args): Promise { if (type.includes("json")) { - return JSON.stringify(body); + return toJson(body); } else { return body as BodyInit; } diff --git a/src/core/fetcher/makeRequest.ts b/src/core/fetcher/makeRequest.ts index 8fb4bace..1af42bb9 100644 --- a/src/core/fetcher/makeRequest.ts +++ b/src/core/fetcher/makeRequest.ts @@ -9,7 +9,7 @@ export const makeRequest = async ( timeoutMs?: number, abortSignal?: AbortSignal, withCredentials?: boolean, - duplex?: "half" + duplex?: "half", ): Promise => { const signals: AbortSignal[] = []; diff --git a/src/core/fetcher/requestWithRetries.ts b/src/core/fetcher/requestWithRetries.ts index 8d5af9d5..add3cce0 100644 --- a/src/core/fetcher/requestWithRetries.ts +++ b/src/core/fetcher/requestWithRetries.ts @@ -11,12 +11,12 @@ function addJitter(delay: number): number { export async function requestWithRetries( requestFn: () => Promise, - maxRetries: number = DEFAULT_MAX_RETRIES + maxRetries: number = DEFAULT_MAX_RETRIES, ): Promise { let response: Response = await requestFn(); for (let i = 0; i < maxRetries; ++i) { - if ([408, 409, 429].includes(response.status) || response.status >= 500) { + if ([408, 429].includes(response.status) || response.status >= 500) { // Calculate base delay using exponential backoff (in milliseconds) const baseDelay = Math.min(INITIAL_RETRY_DELAY * Math.pow(2, i), MAX_RETRY_DELAY); diff --git a/src/core/fetcher/signals.ts b/src/core/fetcher/signals.ts index 6c124ff7..a8d32a2e 100644 --- a/src/core/fetcher/signals.ts +++ b/src/core/fetcher/signals.ts @@ -15,7 +15,7 @@ export function getTimeoutSignal(timeoutMs: number): { signal: AbortSignal; abor export function anySignal(...args: AbortSignal[] | [AbortSignal[]]): AbortSignal { // Allowing signals to be passed either as array // of signals or as multiple arguments. - const signals = (args.length === 1 && Array.isArray(args[0]) ? args[0] : args); + const signals = (args.length === 1 && Array.isArray(args[0]) ? args[0] : args) as AbortSignal[]; const controller = new AbortController(); diff --git a/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts b/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts index 4d7b7d52..6f1a82e9 100644 --- a/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts +++ b/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts @@ -1,4 +1,5 @@ import type { Writable } from "readable-stream"; + import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; export class Node18UniversalStreamWrapper @@ -38,7 +39,7 @@ export class Node18UniversalStreamWrapper | Writable | WritableStream + dest: Node18UniversalStreamWrapper | Writable | WritableStream, ): Node18UniversalStreamWrapper | Writable | WritableStream { this.on("data", async (chunk) => { if (dest instanceof Node18UniversalStreamWrapper) { @@ -79,7 +80,7 @@ export class Node18UniversalStreamWrapper | Writable | WritableStream + dest: Node18UniversalStreamWrapper | Writable | WritableStream, ): Node18UniversalStreamWrapper | Writable | WritableStream { return this.pipe(dest); } diff --git a/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts b/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts index ba5f7276..23c01a1a 100644 --- a/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts +++ b/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts @@ -1,4 +1,5 @@ import type { Readable, Writable } from "readable-stream"; + import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; export class NodePre18StreamWrapper implements StreamWrapper { diff --git a/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts b/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts index 263af009..091e2a7f 100644 --- a/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts +++ b/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts @@ -38,7 +38,7 @@ export class UndiciStreamWrapper | WritableStream + dest: UndiciStreamWrapper | WritableStream, ): UndiciStreamWrapper | WritableStream { this.on("data", (chunk) => { if (dest instanceof UndiciStreamWrapper) { @@ -73,7 +73,7 @@ export class UndiciStreamWrapper | WritableStream + dest: UndiciStreamWrapper | WritableStream, ): UndiciStreamWrapper | WritableStream { return this.pipe(dest); } diff --git a/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts b/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts index 2abd6b2b..8c7492fc 100644 --- a/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts +++ b/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts @@ -1,4 +1,5 @@ import type { Readable } from "readable-stream"; + import { RUNTIME } from "../../runtime"; export type EventCallback = (data?: any) => void; @@ -23,7 +24,7 @@ export interface StreamWrapper { export async function chooseStreamWrapper(responseBody: any): Promise>> { if (RUNTIME.type === "node" && RUNTIME.parsedVersion != null && RUNTIME.parsedVersion >= 18) { return new (await import("./Node18UniversalStreamWrapper")).Node18UniversalStreamWrapper( - responseBody as ReadableStream + responseBody as ReadableStream, ); } else if (RUNTIME.type !== "node" && typeof fetch === "function") { return new (await import("./UndiciStreamWrapper")).UndiciStreamWrapper(responseBody as ReadableStream); diff --git a/src/core/json.ts b/src/core/json.ts new file mode 100644 index 00000000..c052f324 --- /dev/null +++ b/src/core/json.ts @@ -0,0 +1,27 @@ +/** + * Serialize a value to JSON + * @param value A JavaScript value, usually an object or array, to be converted. + * @param replacer A function that transforms the results. + * @param space Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read. + * @returns JSON string + */ +export const toJson = ( + value: unknown, + replacer?: (this: unknown, key: string, value: unknown) => unknown, + space?: string | number, +): string => { + return JSON.stringify(value, replacer, space); +}; + +/** + * Parse JSON string to object, array, or other type + * @param text A valid JSON string. + * @param reviver A function that transforms the results. This function is called for each member of the object. If a member contains nested objects, the nested objects are transformed before the parent object is. + * @returns Parsed object, array, or other type + */ +export function fromJson( + text: string, + reviver?: (this: unknown, key: string, value: unknown) => unknown, +): T { + return JSON.parse(text, reviver); +} diff --git a/src/core/runtime/runtime.ts b/src/core/runtime/runtime.ts index 4d0687e8..a9750175 100644 --- a/src/core/runtime/runtime.ts +++ b/src/core/runtime/runtime.ts @@ -8,58 +8,9 @@ interface BunGlobal { version: string; } -declare const Deno: DenoGlobal; -declare const Bun: BunGlobal; - -/** - * A constant that indicates whether the environment the code is running is a Web Browser. - */ -const isBrowser = typeof window !== "undefined" && typeof window.document !== "undefined"; - -/** - * A constant that indicates whether the environment the code is running is a Web Worker. - */ -const isWebWorker = - typeof self === "object" && - // @ts-ignore - typeof self?.importScripts === "function" && - (self.constructor?.name === "DedicatedWorkerGlobalScope" || - self.constructor?.name === "ServiceWorkerGlobalScope" || - self.constructor?.name === "SharedWorkerGlobalScope"); - -/** - * A constant that indicates whether the environment the code is running is Deno. - */ -const isDeno = - typeof Deno !== "undefined" && typeof Deno.version !== "undefined" && typeof Deno.version.deno !== "undefined"; - -/** - * A constant that indicates whether the environment the code is running is Bun.sh. - */ -const isBun = typeof Bun !== "undefined" && typeof Bun.version !== "undefined"; - -/** - * A constant that indicates whether the environment the code is running is Node.JS. - */ -const isNode = - typeof process !== "undefined" && - Boolean(process.version) && - Boolean(process.versions?.node) && - // Deno spoofs process.versions.node, see https://deno.land/std@0.177.0/node/process.ts?s=versions - !isDeno && - !isBun; - -/** - * A constant that indicates whether the environment the code is running is in React-Native. - * https://github.com/facebook/react-native/blob/main/packages/react-native/Libraries/Core/setUpNavigator.js - */ -const isReactNative = typeof navigator !== "undefined" && navigator?.product === "ReactNative"; - -/** - * A constant that indicates whether the environment the code is running is Cloudflare. - * https://developers.cloudflare.com/workers/runtime-apis/web-standards/#navigatoruseragent - */ -const isCloudflare = typeof globalThis !== "undefined" && globalThis?.navigator?.userAgent === "Cloudflare-Workers"; +declare const Deno: DenoGlobal | undefined; +declare const Bun: BunGlobal | undefined; +declare const EdgeRuntime: string | undefined; /** * A constant that indicates which environment and version the SDK is running in. @@ -67,12 +18,16 @@ const isCloudflare = typeof globalThis !== "undefined" && globalThis?.navigator? export const RUNTIME: Runtime = evaluateRuntime(); export interface Runtime { - type: "browser" | "web-worker" | "deno" | "bun" | "node" | "react-native" | "unknown" | "workerd"; + type: "browser" | "web-worker" | "deno" | "bun" | "node" | "react-native" | "unknown" | "workerd" | "edge-runtime"; version?: string; parsedVersion?: number; } function evaluateRuntime(): Runtime { + /** + * A constant that indicates whether the environment the code is running is a Web Browser. + */ + const isBrowser = typeof window !== "undefined" && typeof window.document !== "undefined"; if (isBrowser) { return { type: "browser", @@ -80,18 +35,50 @@ function evaluateRuntime(): Runtime { }; } + /** + * A constant that indicates whether the environment the code is running is Cloudflare. + * https://developers.cloudflare.com/workers/runtime-apis/web-standards/#navigatoruseragent + */ + const isCloudflare = typeof globalThis !== "undefined" && globalThis?.navigator?.userAgent === "Cloudflare-Workers"; if (isCloudflare) { return { type: "workerd", }; } + /** + * A constant that indicates whether the environment the code is running is Edge Runtime. + * https://vercel.com/docs/functions/runtimes/edge-runtime#check-if-you're-running-on-the-edge-runtime + */ + const isEdgeRuntime = typeof EdgeRuntime === "string"; + if (isEdgeRuntime) { + return { + type: "edge-runtime", + }; + } + + /** + * A constant that indicates whether the environment the code is running is a Web Worker. + */ + const isWebWorker = + typeof self === "object" && + // @ts-ignore + typeof self?.importScripts === "function" && + (self.constructor?.name === "DedicatedWorkerGlobalScope" || + self.constructor?.name === "ServiceWorkerGlobalScope" || + self.constructor?.name === "SharedWorkerGlobalScope"); if (isWebWorker) { return { type: "web-worker", }; } + /** + * A constant that indicates whether the environment the code is running is Deno. + * FYI Deno spoofs process.versions.node, see https://deno.land/std@0.177.0/node/process.ts?s=versions + */ + const isDeno = + typeof Deno !== "undefined" && typeof Deno.version !== "undefined" && typeof Deno.version.deno !== "undefined"; if (isDeno) { return { type: "deno", @@ -99,6 +86,10 @@ function evaluateRuntime(): Runtime { }; } + /** + * A constant that indicates whether the environment the code is running is Bun.sh. + */ + const isBun = typeof Bun !== "undefined" && typeof Bun.version !== "undefined"; if (isBun) { return { type: "bun", @@ -106,6 +97,15 @@ function evaluateRuntime(): Runtime { }; } + /** + * A constant that indicates whether the environment the code is running is Node.JS. + */ + const isNode = + typeof process !== "undefined" && + "version" in process && + !!process.version && + "versions" in process && + !!process.versions?.node; if (isNode) { return { type: "node", @@ -114,6 +114,11 @@ function evaluateRuntime(): Runtime { }; } + /** + * A constant that indicates whether the environment the code is running is in React-Native. + * https://github.com/facebook/react-native/blob/main/packages/react-native/Libraries/Core/setUpNavigator.js + */ + const isReactNative = typeof navigator !== "undefined" && navigator?.product === "ReactNative"; if (isReactNative) { return { type: "react-native", diff --git a/src/errors/IntercomError.ts b/src/errors/IntercomError.ts index 898a54a6..add6ed73 100644 --- a/src/errors/IntercomError.ts +++ b/src/errors/IntercomError.ts @@ -2,6 +2,8 @@ * This file was auto-generated by Fern from our API Definition. */ +import { toJson } from "../core/json"; + export class IntercomError extends Error { readonly statusCode?: number; readonly body?: unknown; @@ -38,7 +40,7 @@ function buildMessage({ } if (body != null) { - lines.push(`Body: ${JSON.stringify(body, undefined, 2)}`); + lines.push(`Body: ${toJson(body, undefined, 2)}`); } return lines.join("\n"); diff --git a/src/version.ts b/src/version.ts index 9e9f5ed5..35d67468 100644 --- a/src/version.ts +++ b/src/version.ts @@ -1 +1 @@ -export const SDK_VERSION = "v6.1.1"; +export const SDK_VERSION = "6.2.0"; diff --git a/tests/unit/auth/BasicAuth.test.ts b/tests/unit/auth/BasicAuth.test.ts index fc35704e..79ef9799 100644 --- a/tests/unit/auth/BasicAuth.test.ts +++ b/tests/unit/auth/BasicAuth.test.ts @@ -7,7 +7,7 @@ describe("BasicAuth", () => { BasicAuth.toAuthorizationHeader({ username: "username", password: "password", - }) + }), ).toBe("Basic dXNlcm5hbWU6cGFzc3dvcmQ="); }); }); diff --git a/tests/unit/fetcher/Fetcher.test.ts b/tests/unit/fetcher/Fetcher.test.ts index ff804217..a32945e9 100644 --- a/tests/unit/fetcher/Fetcher.test.ts +++ b/tests/unit/fetcher/Fetcher.test.ts @@ -1,7 +1,8 @@ import fs from "fs"; -import { Fetcher, fetcherImpl } from "../../../src/core/fetcher/Fetcher"; import { join } from "path"; +import { Fetcher, fetcherImpl } from "../../../src/core/fetcher/Fetcher"; + describe("Test fetcherImpl", () => { it("should handle successful request", async () => { const mockArgs: Fetcher.Args = { @@ -32,7 +33,7 @@ describe("Test fetcherImpl", () => { method: "POST", headers: expect.objectContaining({ "X-Test": "x-test-header" }), body: JSON.stringify({ data: "test" }), - }) + }), ); }); @@ -63,7 +64,7 @@ describe("Test fetcherImpl", () => { method: "POST", headers: expect.objectContaining({ "X-Test": "x-test-header" }), body: expect.any(fs.ReadStream), - }) + }), ); expect(result.ok).toBe(true); if (result.ok) { diff --git a/tests/unit/fetcher/createRequestUrl.test.ts b/tests/unit/fetcher/createRequestUrl.test.ts index f2cd24b6..486e1e61 100644 --- a/tests/unit/fetcher/createRequestUrl.test.ts +++ b/tests/unit/fetcher/createRequestUrl.test.ts @@ -22,7 +22,7 @@ describe("Test createRequestUrl", () => { const baseUrl = "https://api.example.com"; const queryParams = { filter: { name: "John", age: 30 } }; expect(createRequestUrl(baseUrl, queryParams)).toBe( - "https://api.example.com?filter%5Bname%5D=John&filter%5Bage%5D=30" + "https://api.example.com?filter%5Bname%5D=John&filter%5Bage%5D=30", ); }); @@ -34,7 +34,7 @@ describe("Test createRequestUrl", () => { object: { key: "value" }, }; expect(createRequestUrl(baseUrl, queryParams)).toBe( - "https://api.example.com?simple=value&array=x&array=y&object%5Bkey%5D=value" + "https://api.example.com?simple=value&array=x&array=y&object%5Bkey%5D=value", ); }); diff --git a/tests/unit/fetcher/makeRequest.test.ts b/tests/unit/fetcher/makeRequest.test.ts index be94ab45..43ed9d11 100644 --- a/tests/unit/fetcher/makeRequest.test.ts +++ b/tests/unit/fetcher/makeRequest.test.ts @@ -1,4 +1,3 @@ -import { RUNTIME } from "../../../src/core/runtime"; import { makeRequest } from "../../../src/core/fetcher/makeRequest"; describe("Test makeRequest", () => { @@ -27,7 +26,7 @@ describe("Test makeRequest", () => { headers: mockHeaders, body: mockBody, credentials: undefined, - }) + }), ); expect(calledOptions.signal).toBeDefined(); expect(calledOptions.signal).toBeInstanceOf(AbortSignal); @@ -46,7 +45,7 @@ describe("Test makeRequest", () => { headers: mockHeaders, body: undefined, credentials: undefined, - }) + }), ); expect(calledOptions.signal).toBeDefined(); expect(calledOptions.signal).toBeInstanceOf(AbortSignal); diff --git a/tests/unit/fetcher/requestWithRetries.test.ts b/tests/unit/fetcher/requestWithRetries.test.ts index 6f77f093..3cdaa40a 100644 --- a/tests/unit/fetcher/requestWithRetries.test.ts +++ b/tests/unit/fetcher/requestWithRetries.test.ts @@ -1,4 +1,3 @@ -import { RUNTIME } from "../../../src/core/runtime"; import { requestWithRetries } from "../../../src/core/fetcher/requestWithRetries"; describe("requestWithRetries", () => { @@ -23,12 +22,12 @@ describe("requestWithRetries", () => { }); it("should retry on retryable status codes", async () => { - setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { process.nextTick(callback); return null as any; }); - const retryableStatuses = [408, 409, 429, 500, 502]; + const retryableStatuses = [408, 429, 500, 502]; let callCount = 0; mockFetch.mockImplementation(async () => { @@ -47,7 +46,7 @@ describe("requestWithRetries", () => { }); it("should respect maxRetries limit", async () => { - setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { process.nextTick(callback); return null as any; }); @@ -64,7 +63,7 @@ describe("requestWithRetries", () => { }); it("should not retry on success status codes", async () => { - setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { process.nextTick(callback); return null as any; }); @@ -86,7 +85,7 @@ describe("requestWithRetries", () => { }); it("should apply correct exponential backoff with jitter", async () => { - setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { process.nextTick(callback); return null as any; }); @@ -110,7 +109,7 @@ describe("requestWithRetries", () => { }); it("should handle concurrent retries independently", async () => { - setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { process.nextTick(callback); return null as any; }); diff --git a/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts b/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts index 1dc9be0c..172c1c26 100644 --- a/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts +++ b/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts @@ -159,7 +159,7 @@ describe("Node18UniversalStreamWrapper", () => { expect(data).toEqual({ test: "test" }); }); - it("should allow use with async iteratable stream", async () => { + it("should allow use with async iterable stream", async () => { const rawStream = new ReadableStream({ start(controller) { controller.enqueue(new TextEncoder().encode("test")); diff --git a/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts b/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts index 0c99d3b2..19c26668 100644 --- a/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts +++ b/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts @@ -111,7 +111,7 @@ describe("NodePre18StreamWrapper", () => { expect(data).toEqual({ test: "test" }); }); - it("should allow use with async iteratable stream", async () => { + it("should allow use with async iterable stream", async () => { const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); let data = ""; const stream = new NodePre18StreamWrapper(rawStream); diff --git a/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts b/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts index 1d171ce6..0ea14835 100644 --- a/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts +++ b/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts @@ -134,7 +134,7 @@ describe("UndiciStreamWrapper", () => { expect(data).toEqual({ test: "test" }); }); - it("should allow use with async iteratable stream", async () => { + it("should allow use with async iterable stream", async () => { const rawStream = new ReadableStream({ start(controller) { controller.enqueue(new TextEncoder().encode("test")); diff --git a/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts b/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts index 17cf37a2..8004e9ab 100644 --- a/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts +++ b/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts @@ -1,8 +1,8 @@ import { RUNTIME } from "../../../../src/core/runtime"; -import { chooseStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/chooseStreamWrapper"; import { Node18UniversalStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper"; import { NodePre18StreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/NodePre18StreamWrapper"; import { UndiciStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/UndiciStreamWrapper"; +import { chooseStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/chooseStreamWrapper"; describe("chooseStreamWrapper", () => { beforeEach(() => { diff --git a/tests/unit/fetcher/stream-wrappers/webpack.test.ts b/tests/unit/fetcher/stream-wrappers/webpack.test.ts index 557db6dc..63fa0a78 100644 --- a/tests/unit/fetcher/stream-wrappers/webpack.test.ts +++ b/tests/unit/fetcher/stream-wrappers/webpack.test.ts @@ -17,7 +17,11 @@ describe("test env compatibility", () => { ], }, resolve: { - extensions: [".tsx", ".ts", ".js"], + extensions: [".tsx", ".ts", ".jsx", ".js"], + extensionAlias: { + ".js": [".ts", ".js"], + ".jsx": [".tsx", ".jsx"], + }, }, }, (err, stats) => { @@ -31,8 +35,8 @@ describe("test env compatibility", () => { } catch (error) { reject(error); } - } + }, ); }); - }, 60_000); + }, 90_000); }); diff --git a/tsconfig.json b/tsconfig.json index 538c94fe..1ec87dd7 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -3,14 +3,14 @@ "extendedDiagnostics": true, "strict": true, "target": "ES6", - "module": "CommonJS", "moduleResolution": "node", "esModuleInterop": true, "skipLibCheck": true, "declaration": true, "outDir": "dist", "rootDir": "src", - "baseUrl": "src" + "baseUrl": "src", + "module": "CommonJS" }, "include": ["src"], "exclude": [] diff --git a/yarn.lock b/yarn.lock index 970f6bab..eb8d8c8d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -625,10 +625,10 @@ dependencies: "@types/istanbul-lib-report" "*" -"@types/jest@29.5.5": - version "29.5.5" - resolved "https://registry.yarnpkg.com/@types/jest/-/jest-29.5.5.tgz#727204e06228fe24373df9bae76b90f3e8236a2a" - integrity sha512-ebylz2hnsWR9mYvmBFbXJXr+33UPc4+ZdxyDXh5w0FlPBTfCVN3wPL+kuOiQt3xvrK419v7XWeAs+AeOksafXg== +"@types/jest@^29.5.14": + version "29.5.14" + resolved "https://registry.yarnpkg.com/@types/jest/-/jest-29.5.14.tgz#2b910912fa1d6856cadcd0c1f95af7df1d6049e5" + integrity sha512-ZN+4sdnLUbo8EVvVc2ao0GFW6oVrQRPn4K2lglySj7APvSrgzxHiNNK99us4WDMi57xxA2yggblIAMNhXOotLQ== dependencies: expect "^29.0.0" pretty-format "^29.0.0" @@ -647,10 +647,10 @@ resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.15.tgz#596a1747233694d50f6ad8a7869fcb6f56cf5841" integrity sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA== -"@types/node-fetch@2.6.9": - version "2.6.9" - resolved "https://registry.yarnpkg.com/@types/node-fetch/-/node-fetch-2.6.9.tgz#15f529d247f1ede1824f7e7acdaa192d5f28071e" - integrity sha512-bQVlnMLFJ2d35DkPNjEPmd9ueO/rh5EiaZt2bhqiSarPjZIuIV6bPQVqcrEyvNo+AfTrRGVazle1tl597w3gfA== +"@types/node-fetch@^2.6.12": + version "2.6.12" + resolved "https://registry.yarnpkg.com/@types/node-fetch/-/node-fetch-2.6.12.tgz#8ab5c3ef8330f13100a7479e2cd56d3386830a03" + integrity sha512-8nneRWKCg3rMtF69nLQJnOYUcbafYeFSjqkw3jCRLsqkWFlHaoQrr5mXmofFGOx3DKn7UfmBMyov8ySvLRVldA== dependencies: "@types/node" "*" form-data "^4.0.0" @@ -662,17 +662,19 @@ dependencies: undici-types "~6.20.0" -"@types/node@17.0.33": - version "17.0.33" - resolved "https://registry.yarnpkg.com/@types/node/-/node-17.0.33.tgz#3c1879b276dc63e73030bb91165e62a4509cd506" - integrity sha512-miWq2m2FiQZmaHfdZNcbpp9PuXg34W5JZ5CrJ/BaS70VuhoJENBEQybeiYSaPBRNq6KQGnjfEnc/F3PN++D+XQ== +"@types/node@^18.19.70": + version "18.19.80" + resolved "https://registry.yarnpkg.com/@types/node/-/node-18.19.80.tgz#6d6008e8920dddcd23f9dd33da24684ef57d487c" + integrity sha512-kEWeMwMeIvxYkeg1gTc01awpwLbfMRZXdIhwRcakd/KlK53jmRC26LqcbIt7fnAQTu5GzlnWmzA3H6+l1u6xxQ== + dependencies: + undici-types "~5.26.4" -"@types/qs@6.9.8": - version "6.9.8" - resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.9.8.tgz#f2a7de3c107b89b441e071d5472e6b726b4adf45" - integrity sha512-u95svzDlTysU5xecFNTgfFG5RUWu1A9P0VzgpcIiGZA9iraHOdSzcxMxQ55DyeRaGCSxQi7LxXDI4rzq/MYfdg== +"@types/qs@^6.9.17": + version "6.9.18" + resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.9.18.tgz#877292caa91f7c1b213032b34626505b746624c2" + integrity sha512-kK7dgTYDyGqS+e2Q4aK9X3D7q234CIZ1Bv0q/7Z5IwRDoADNU81xXJK/YVyLbLTZCoIwUoDoffFeF+p/eIklAA== -"@types/readable-stream@^4.0.15": +"@types/readable-stream@^4.0.18": version "4.0.18" resolved "https://registry.yarnpkg.com/@types/readable-stream/-/readable-stream-4.0.18.tgz#5d8d15d26c776500ce573cae580787d149823bfc" integrity sha512-21jK/1j+Wg+7jVw1xnSwy/2Q1VgVjWuFssbYGTREPUBeZ+rqVFl2udq0IkxzPC0ZhOzVceUbyIACFZKLqKEBlA== @@ -940,6 +942,11 @@ argparse@^1.0.7: dependencies: sprintf-js "~1.0.2" +async@^3.2.3: + version "3.2.6" + resolved "https://registry.yarnpkg.com/async/-/async-3.2.6.tgz#1b0728e14929d51b85b449b7f06e27c1145e38ce" + integrity sha512-htCUDlxyyCLMgaM3xXg0C0LW2xqfuQ6p05pCEIsXuyQ+a1koYKTuBMzRNwmybfLgvJDMd0r1LTn4+E0Ti6C2AA== + asynckit@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" @@ -1026,6 +1033,13 @@ brace-expansion@^1.1.7: balanced-match "^1.0.0" concat-map "0.0.1" +brace-expansion@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-2.0.1.tgz#1edc459e0f0c548486ecf9fc99f2221364b9a0ae" + integrity sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA== + dependencies: + balanced-match "^1.0.0" + braces@^3.0.3: version "3.0.3" resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.3.tgz#490332f40919452272d55a8480adc0c441358789" @@ -1043,7 +1057,7 @@ browserslist@^4.24.0: node-releases "^2.0.19" update-browserslist-db "^1.1.1" -bs-logger@0.x: +bs-logger@^0.2.6: version "0.2.6" resolved "https://registry.yarnpkg.com/bs-logger/-/bs-logger-0.2.6.tgz#eb7d365307a72cf974cc6cda76b68354ad336bd8" integrity sha512-pd8DCoxmbgc7hyPKOvxtqNcjYoOsABPQdcCUjGp3d42VR2CX1ORhk2A87oqqu5R1kk+76nsxZupkmyd+MVtCog== @@ -1106,7 +1120,7 @@ caniuse-lite@^1.0.30001688: resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001706.tgz#902c3f896f4b2968031c3a546ab2ef8b465a2c8f" integrity sha512-3ZczoTApMAZwPKYWmwVbQMFpXBDds3/0VciVoUwPUbldlYyVLmRVuRs/PcUZtHpbLRpzzDvrvnFuREsGt6lUug== -chalk@^4.0.0, chalk@^4.1.0: +chalk@^4.0.0, chalk@^4.0.2, chalk@^4.1.0: version "4.1.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== @@ -1288,6 +1302,13 @@ dunder-proto@^1.0.1: es-errors "^1.3.0" gopd "^1.2.0" +ejs@^3.1.10: + version "3.1.10" + resolved "https://registry.yarnpkg.com/ejs/-/ejs-3.1.10.tgz#69ab8358b14e896f80cc39e62087b88500c3ac3b" + integrity sha512-UeJmFfOrAQS8OJWPZ4qtgHyWExa088/MtK5UEyoJGFH67cDEXkZSviOiKRCZ4Xij0zxI3JECgYs3oKx+AizQBA== + dependencies: + jake "^10.8.5" + electron-to-chromium@^1.5.73: version "1.5.122" resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.122.tgz#4fabd37b30b71dc041f6c6c4bab309b3f8348fcb" @@ -1474,6 +1495,13 @@ fb-watchman@^2.0.0: dependencies: bser "2.1.1" +filelist@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/filelist/-/filelist-1.0.4.tgz#f78978a1e944775ff9e62e744424f215e58352b5" + integrity sha512-w1cEuf3S+DrLCQL7ET6kz+gmlJdbq9J7yXCSjK/OZCPA+qEN1WyF4ZAf0YYJa4/shHJra2t/d/r8SV4Ji+x+8Q== + dependencies: + minimatch "^5.0.1" + fill-range@^7.1.1: version "7.1.1" resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-7.1.1.tgz#44265d3cac07e3ea7dc247516380643754a05292" @@ -1786,6 +1814,16 @@ istanbul-reports@^3.1.3: html-escaper "^2.0.0" istanbul-lib-report "^3.0.0" +jake@^10.8.5: + version "10.9.2" + resolved "https://registry.yarnpkg.com/jake/-/jake-10.9.2.tgz#6ae487e6a69afec3a5e167628996b59f35ae2b7f" + integrity sha512-2P4SQ0HrLQ+fw6llpLnOaGAvN2Zu6778SJMrCUwns4fOoG9ayrTiZk3VV8sCPkVZF8ab0zksVpS8FDY5pRCNBA== + dependencies: + async "^3.2.3" + chalk "^4.0.2" + filelist "^1.0.4" + minimatch "^3.1.2" + jest-changed-files@^29.7.0: version "29.7.0" resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-29.7.0.tgz#1c06d07e77c78e1585d020424dedc10d6e17ac3a" @@ -1894,7 +1932,7 @@ jest-each@^29.7.0: jest-util "^29.7.0" pretty-format "^29.7.0" -jest-environment-jsdom@29.7.0: +jest-environment-jsdom@^29.7.0: version "29.7.0" resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-29.7.0.tgz#d206fa3551933c3fd519e5dfdb58a0f5139a837f" integrity sha512-k9iQbsf9OyOfdzWH8HDmrRT0gSIcX+FLNW7IQq94tFX0gynPwqDTW0Ho6iMVNjGz/nb+l/vW3dWM2bbLLpkbXA== @@ -2157,7 +2195,7 @@ jest-worker@^29.7.0: merge-stream "^2.0.0" supports-color "^8.0.0" -jest@29.7.0: +jest@^29.7.0: version "29.7.0" resolved "https://registry.yarnpkg.com/jest/-/jest-29.7.0.tgz#994676fc24177f088f1c5e3737f5697204ff2613" integrity sha512-NIy3oAFp9shda19hy4HK0HRTWKtPJmGdnvywu01nOqNC2vZg+Z+fvJDxpMQA88eb2I9EcafcdjYgsDthnYTvGw== @@ -2167,10 +2205,10 @@ jest@29.7.0: import-local "^3.0.2" jest-cli "^29.7.0" -js-base64@3.7.2: - version "3.7.2" - resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-3.7.2.tgz#816d11d81a8aff241603d19ce5761e13e41d7745" - integrity sha512-NnRs6dsyqUXejqk/yv2aiXlAvOs56sLkX6nUdeaNezI5LFFLlsZjOThmwnrcwh5ZZRwZlCMnVAY3CvhIhoVEKQ== +js-base64@3.7.7: + version "3.7.7" + resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-3.7.7.tgz#e51b84bf78fbf5702b9541e2cb7bfcb893b43e79" + integrity sha512-7rCnleh0z2CkXhH67J8K1Ytz0b2Y+yxTPL+/KOJoa20hfnVQ/3/T6W/KflYI4bRHRagNeXeU2bkNGI3v1oS/lw== js-tokens@^4.0.0: version "4.0.0" @@ -2264,7 +2302,7 @@ locate-path@^5.0.0: dependencies: p-locate "^4.1.0" -lodash.memoize@4.x: +lodash.memoize@^4.1.2: version "4.1.2" resolved "https://registry.yarnpkg.com/lodash.memoize/-/lodash.memoize-4.1.2.tgz#bcc6c49a42a2840ed997f323eada5ecd182e0bfe" integrity sha512-t7j+NzmgnQzTAYXcsHYLgimltOV1MXHtlOWf6GjL9Kj8GK5FInw5JotxvbOs+IvV1/Dzo04/fCGfLVs7aXb4Ag== @@ -2283,7 +2321,7 @@ make-dir@^4.0.0: dependencies: semver "^7.5.3" -make-error@1.x: +make-error@^1.3.6: version "1.3.6" resolved "https://registry.yarnpkg.com/make-error/-/make-error-1.3.6.tgz#2eb2e37ea9b67c4891f684a1394799af484cf7a2" integrity sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw== @@ -2330,13 +2368,20 @@ mimic-fn@^2.1.0: resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-2.1.0.tgz#7ed2c2ccccaf84d3ffcb7a69b57711fc2083401b" integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== -minimatch@^3.0.4, minimatch@^3.1.1: +minimatch@^3.0.4, minimatch@^3.1.1, minimatch@^3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b" integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== dependencies: brace-expansion "^1.1.7" +minimatch@^5.0.1: + version "5.1.6" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-5.1.6.tgz#1cfcb8cf5522ea69952cd2af95ae09477f122a96" + integrity sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g== + dependencies: + brace-expansion "^2.0.1" + ms@^2.1.3: version "2.1.3" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" @@ -2352,7 +2397,7 @@ neo-async@^2.6.2: resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.2.tgz#b4aafb93e3aeb2d8174ca53cf163ab7d7308305f" integrity sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw== -node-fetch@2.7.0: +node-fetch@^2.7.0: version "2.7.0" resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.7.0.tgz#d0f0fa6e3e2dc1d27efcd8ad99d550bda94d187d" integrity sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A== @@ -2490,10 +2535,10 @@ pkg-dir@^4.2.0: dependencies: find-up "^4.0.0" -prettier@2.7.1: - version "2.7.1" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.7.1.tgz#e235806850d057f97bb08368a4f7d899f7760c64" - integrity sha512-ujppO+MkdPqoVINuDFDRLClm7D78qbDt0/NR+wp5FqEZOoTNAjPHWj17QRhu7geIHJfcNhRk1XVQmF8Bp3ye+g== +prettier@^3.4.2: + version "3.5.3" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-3.5.3.tgz#4fc2ce0d657e7a02e602549f053b239cb7dfe1b5" + integrity sha512-QQtaxnoDJeAkDvDKWCLiwIXkTgRhwYDEQCghU9Z6q03iyek/rxRh/2lC3HB7P8sWT2xC/y5JDctPLBIGzHKbhw== pretty-format@^29.0.0, pretty-format@^29.7.0: version "29.7.0" @@ -2534,12 +2579,12 @@ pure-rand@^6.0.0: resolved "https://registry.yarnpkg.com/pure-rand/-/pure-rand-6.1.0.tgz#d173cf23258231976ccbdb05247c9787957604f2" integrity sha512-bVWawvoZoBYpp6yIoQtQXHZjmz35RSVHnUOTefl8Vcjr8snTPY1wnpSPMWekcFwbxI6gtmT7rSYPFvz71ldiOA== -qs@6.11.2: - version "6.11.2" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.2.tgz#64bea51f12c1f5da1bc01496f48ffcff7c69d7d9" - integrity sha512-tDNIz22aBzCDxLtVH++VnTfzxlfeK5CbqohpSqpJgj1Wg/cQbStNAz3NuqCs5vV+pjBsK4x4pN9HlVh7rcYRiA== +qs@^6.13.1: + version "6.14.0" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.14.0.tgz#c63fa40680d2c5c941412a0e899c89af60c0a930" + integrity sha512-YWWTjgABSKcvs/nWBi9PycY/JiPJqOD4JA6o9Sej2AtvSGarXxKC3OQSk4pAarbdQlKAh5D4FCQkJNkW+GAn3w== dependencies: - side-channel "^1.0.4" + side-channel "^1.1.0" querystringify@^2.1.1: version "2.2.0" @@ -2647,7 +2692,7 @@ semver@^6.3.0, semver@^6.3.1: resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== -semver@^7.3.4, semver@^7.5.3, semver@^7.5.4: +semver@^7.3.4, semver@^7.5.3, semver@^7.5.4, semver@^7.7.1: version "7.7.1" resolved "https://registry.yarnpkg.com/semver/-/semver-7.7.1.tgz#abd5098d82b18c6c81f6074ff2647fd3e7220c9f" integrity sha512-hlq8tAfn0m/61p4BVRcPzIGr6LKiMwo4VM6dGi6pt4qcRkmNzTcWq6eCEjEh+qXjkMDvPlOFFSGwQjoEa6gyMA== @@ -2700,7 +2745,7 @@ side-channel-weakmap@^1.0.2: object-inspect "^1.13.3" side-channel-map "^1.0.1" -side-channel@^1.0.4: +side-channel@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.1.0.tgz#c3fcff9c4da932784873335ec9765fa94ff66bc9" integrity sha512-ZX99e6tRweoUXqR+VBrslhda51Nh5MTQwou5tnUDgbtyM0dBgmhEDtWGP/xbKn6hqfPRHujUNwz5fy/wbbhnpw== @@ -2903,21 +2948,22 @@ tr46@~0.0.3: resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" integrity sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw== -ts-jest@29.1.1: - version "29.1.1" - resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-29.1.1.tgz#f58fe62c63caf7bfcc5cc6472082f79180f0815b" - integrity sha512-D6xjnnbP17cC85nliwGiL+tpoKN0StpgE0TeOjXQTU6MVCfsB4v7aW05CgQ/1OywGb0x/oy9hHFnN+sczTiRaA== +ts-jest@^29.1.1: + version "29.2.6" + resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-29.2.6.tgz#df53edf8b72fb89de032cfa310abf37582851d9a" + integrity sha512-yTNZVZqc8lSixm+QGVFcPe6+yj7+TWZwIesuOWvfcn4B9bz5x4NDzVCQQjOs7Hfouu36aEqfEbo9Qpo+gq8dDg== dependencies: - bs-logger "0.x" - fast-json-stable-stringify "2.x" + bs-logger "^0.2.6" + ejs "^3.1.10" + fast-json-stable-stringify "^2.1.0" jest-util "^29.0.0" json5 "^2.2.3" - lodash.memoize "4.x" - make-error "1.x" - semver "^7.5.3" - yargs-parser "^21.0.1" + lodash.memoize "^4.1.2" + make-error "^1.3.6" + semver "^7.7.1" + yargs-parser "^21.1.1" -ts-loader@^9.3.1: +ts-loader@^9.5.1: version "9.5.2" resolved "https://registry.yarnpkg.com/ts-loader/-/ts-loader-9.5.2.tgz#1f3d7f4bb709b487aaa260e8f19b301635d08020" integrity sha512-Qo4piXvOTWcMGIgRiuFa6nHNm+54HbYaZCKqc9eeZCLRy3XqafQgwX2F7mofrbJG3g7EEb+lkiR+z2Lic2s3Zw== @@ -2938,10 +2984,15 @@ type-fest@^0.21.3: resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.21.3.tgz#d260a24b0198436e133fa26a524a6d65fa3b2e37" integrity sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w== -typescript@4.6.4: - version "4.6.4" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.6.4.tgz#caa78bbc3a59e6a5c510d35703f6a09877ce45e9" - integrity sha512-9ia/jWHIEbo49HfjrLGfKbZSuWo9iTMwXO+Ca3pRsSpbsMbc7/IU8NKdCZVRRBafVPGnoJeFL76ZOAA84I9fEg== +typescript@~5.7.2: + version "5.7.3" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.7.3.tgz#919b44a7dbb8583a9b856d162be24a54bf80073e" + integrity sha512-84MVSjMEHP+FQRPy3pX9sTVV/INIex71s9TL2Gm5FG/WG1SqXeKyZ0k7/blY/4FdOzI12CBy1vGc4og/eus0fw== + +undici-types@~5.26.4: + version "5.26.5" + resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-5.26.5.tgz#bcd539893d00b56e964fd2657a4866b221a65617" + integrity sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA== undici-types@~6.20.0: version "6.20.0" @@ -3020,7 +3071,7 @@ webpack-sources@^3.2.3: resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-3.2.3.tgz#2d4daab8451fd4b240cc27055ff6a0c2ccea0cde" integrity sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w== -webpack@^5.94.0: +webpack@^5.97.1: version "5.98.0" resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.98.0.tgz#44ae19a8f2ba97537978246072fb89d10d1fbd17" integrity sha512-UFynvx+gM44Gv9qFgj0acCQK2VE1CtdfwFdimkapco3hlPCJ/zeq73n2yVKimVbtm+TnApIugGhLJnkU6gjYXA== @@ -3131,7 +3182,7 @@ yallist@^3.0.2: resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.1.1.tgz#dbb7daf9bfd8bac9ab45ebf602b8cbad0d5d08fd" integrity sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g== -yargs-parser@^21.0.1, yargs-parser@^21.1.1: +yargs-parser@^21.1.1: version "21.1.1" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-21.1.1.tgz#9096bceebf990d21bb31fa9516e0ede294a77d35" integrity sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw== From d82d2a5f02eda535fff3d864a300b33fda24d355 Mon Sep 17 00:00:00 2001 From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com> Date: Thu, 22 May 2025 10:29:06 +0100 Subject: [PATCH 132/146] SDK regeneration (#488) Co-authored-by: fern-api <115122769+fern-api[bot]@users.noreply.github.com> --- README.md | 26 +- package.json | 2 +- reference.md | 164 ++++++- src/Client.ts | 6 + src/api/resources/admins/client/Client.ts | 20 +- .../aiContentSource/types/ContentSource.ts | 16 +- src/api/resources/articles/client/Client.ts | 24 +- src/api/resources/companies/client/Client.ts | 48 +- .../types/CompaniesRetrieveResponse.ts | 19 + src/api/resources/companies/types/Company.ts | 2 - src/api/resources/companies/types/index.ts | 1 + src/api/resources/contacts/client/Client.ts | 60 +-- .../resources/conversations/client/Client.ts | 48 +- .../customChannelEvents/client/Client.ts | 325 +++++++++++++ .../customChannelEvents/client/index.ts | 1 + .../resources/customChannelEvents/index.ts | 1 + .../resources/dataAttributes/client/Client.ts | 12 +- src/api/resources/dataExport/client/Client.ts | 16 +- src/api/resources/events/client/Client.ts | 12 +- .../resources/helpCenters/client/Client.ts | 8 +- .../resources/collections/client/Client.ts | 20 +- src/api/resources/index.ts | 1 + src/api/resources/messages/client/Client.ts | 4 +- .../news/resources/feeds/client/Client.ts | 12 +- .../news/resources/items/client/Client.ts | 20 +- src/api/resources/notes/client/Client.ts | 12 +- .../phoneCallRedirects/client/Client.ts | 4 +- src/api/resources/segments/client/Client.ts | 8 +- .../subscriptionTypes/client/Client.ts | 4 +- src/api/resources/tags/client/Client.ts | 40 +- src/api/resources/teams/client/Client.ts | 8 +- .../resources/ticketTypes/client/Client.ts | 16 +- .../resources/attributes/client/Client.ts | 8 +- src/api/resources/tickets/client/Client.ts | 20 +- src/api/resources/visitors/client/Client.ts | 12 +- src/api/types/CompanyList.ts | 2 - src/api/types/TicketCustomAttributes.ts | 8 +- .../types/TicketRequestCustomAttributes.ts | 6 +- src/version.ts | 2 +- yarn.lock | 431 +++++++++--------- 40 files changed, 963 insertions(+), 486 deletions(-) create mode 100644 src/api/resources/companies/types/CompaniesRetrieveResponse.ts create mode 100644 src/api/resources/customChannelEvents/client/Client.ts create mode 100644 src/api/resources/customChannelEvents/client/index.ts create mode 100644 src/api/resources/customChannelEvents/index.ts diff --git a/README.md b/README.md index a2e2c58a..dce13154 100644 --- a/README.md +++ b/README.md @@ -180,24 +180,12 @@ an issue first to discuss with us! On the other hand, contributions to the README are always very welcome! -## Request Options - -This client library also supports passing in [`request` options](https://github.com/axios/axios#request-config): - -```typescript -client.useRequestOpts({ - baseURL: "http://local.test-server.com", -}); -``` - -Note that certain request options (such as `json`, and certain `headers` names cannot be overriden). - -### Setting the API base url +## Contributing -If you are using the european instance of intercom and would like to call it directly and not be redirected through our US instance, you can set the `baseUrl` as follows: +While we value open-source contributions to this SDK, this library is generated programmatically. +Additions made directly to this library would have to be moved over to our generation code, +otherwise they would be overwritten upon the next generated release. Feel free to open a PR as +a proof of concept, but know that we will not be able to merge it as-is. We suggest opening +an issue first to discuss with us! -```typescript -client.useRequestOpts({ - baseURL: "https://api.eu.intercom.io", -}); -``` +On the other hand, contributions to the README are always very welcome! diff --git a/package.json b/package.json index 8679953d..e3b19250 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "6.2.0", + "version": "6.3.0", "private": false, "repository": "https://github.com/intercom/intercom-node", "main": "./index.js", diff --git a/reference.md b/reference.md index fd0ceaf4..a73a1fe3 100644 --- a/reference.md +++ b/reference.md @@ -877,7 +877,7 @@ while (page.hasNextPage()) { ## Companies -
client.companies.retrieve({ ...params }) -> Intercom.CompanyList +
client.companies.retrieve({ ...params }) -> Intercom.CompaniesRetrieveResponse
@@ -6833,6 +6833,168 @@ await client.visitors.mergeToContact({
+## CustomChannelEvents + +
client.customChannelEvents.notifyAttributeCollected() -> void +
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.customChannelEvents.notifyAttributeCollected(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `CustomChannelEvents.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.customChannelEvents.notifyNewMessage() -> void +
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.customChannelEvents.notifyNewMessage(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `CustomChannelEvents.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.customChannelEvents.notifyNewConversation() -> void +
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.customChannelEvents.notifyNewConversation(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `CustomChannelEvents.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.customChannelEvents.notifyQuickReplySelected() -> void +
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.customChannelEvents.notifyQuickReplySelected(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `CustomChannelEvents.RequestOptions` + +
+
+
+
+ +
+
+
+ ## HelpCenters Collections
client.helpCenters.collections.list({ ...params }) -> core.Page diff --git a/src/Client.ts b/src/Client.ts index 3e4a074b..b240ddcb 100644 --- a/src/Client.ts +++ b/src/Client.ts @@ -23,6 +23,7 @@ import { Teams } from "./api/resources/teams/client/Client"; import { TicketTypes } from "./api/resources/ticketTypes/client/Client"; import { Tickets } from "./api/resources/tickets/client/Client"; import { Visitors } from "./api/resources/visitors/client/Client"; +import { CustomChannelEvents } from "./api/resources/customChannelEvents/client/Client"; import { News } from "./api/resources/news/client/Client"; export declare namespace IntercomClient { @@ -106,6 +107,7 @@ export class IntercomClient { protected _ticketTypes: TicketTypes | undefined; protected _tickets: Tickets | undefined; protected _visitors: Visitors | undefined; + protected _customChannelEvents: CustomChannelEvents | undefined; protected _news: News | undefined; constructor(protected readonly _options: IntercomClient.Options = {}) {} @@ -186,6 +188,10 @@ export class IntercomClient { return (this._visitors ??= new Visitors(this._options)); } + public get customChannelEvents(): CustomChannelEvents { + return (this._customChannelEvents ??= new CustomChannelEvents(this._options)); + } + public get news(): News { return (this._news ??= new News(this._options)); } diff --git a/src/api/resources/admins/client/Client.ts b/src/api/resources/admins/client/Client.ts index 4a45597e..58adcd11 100644 --- a/src/api/resources/admins/client/Client.ts +++ b/src/api/resources/admins/client/Client.ts @@ -101,8 +101,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -173,8 +173,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -257,8 +257,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -325,8 +325,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -400,8 +400,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/aiContentSource/types/ContentSource.ts b/src/api/resources/aiContentSource/types/ContentSource.ts index e8345f1b..15fd382f 100644 --- a/src/api/resources/aiContentSource/types/ContentSource.ts +++ b/src/api/resources/aiContentSource/types/ContentSource.ts @@ -7,7 +7,7 @@ */ export interface ContentSource { /** The type of the content source. */ - content_type: ContentSource.ContentType; + content_type: "custom_answer"; /** The internal URL linking to the content source for teammates. */ url: string; /** The title of the content source. */ @@ -15,17 +15,3 @@ export interface ContentSource { /** The ISO 639 language code of the content source. */ locale: string; } - -export namespace ContentSource { - /** - * The type of the content source. - */ - export type ContentType = "file" | "article" | "external_content" | "content_snippet" | "workflow_connector_action"; - export const ContentType = { - File: "file", - Article: "article", - ExternalContent: "external_content", - ContentSnippet: "content_snippet", - WorkflowConnectorAction: "workflow_connector_action", - } as const; -} diff --git a/src/api/resources/articles/client/Client.ts b/src/api/resources/articles/client/Client.ts index f9b802c6..f39c3695 100644 --- a/src/api/resources/articles/client/Client.ts +++ b/src/api/resources/articles/client/Client.ts @@ -115,8 +115,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -224,8 +224,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -302,8 +302,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -381,8 +381,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -459,8 +459,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -553,8 +553,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/companies/client/Client.ts b/src/api/resources/companies/client/Client.ts index 73e1367a..de1baaf2 100644 --- a/src/api/resources/companies/client/Client.ts +++ b/src/api/resources/companies/client/Client.ts @@ -105,7 +105,7 @@ export class Companies { public async retrieve( request: Intercom.RetrieveCompanyRequest = {}, requestOptions?: Companies.RequestOptions, - ): Promise { + ): Promise { const { name, company_id: companyId, tag_id: tagId, segment_id: segmentId, page, per_page: perPage } = request; const _queryParams: Record = {}; if (name != null) { @@ -144,8 +144,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -159,7 +159,7 @@ export class Companies { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.CompanyList; + return _response.body as Intercom.CompaniesRetrieveResponse; } if (_response.error.reason === "status-code") { @@ -234,8 +234,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -312,8 +312,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -393,8 +393,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -470,8 +470,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -556,8 +556,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -636,8 +636,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -733,8 +733,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -834,8 +834,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -931,8 +931,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1014,8 +1014,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/companies/types/CompaniesRetrieveResponse.ts b/src/api/resources/companies/types/CompaniesRetrieveResponse.ts new file mode 100644 index 00000000..fbe90f3f --- /dev/null +++ b/src/api/resources/companies/types/CompaniesRetrieveResponse.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +export type CompaniesRetrieveResponse = + | Intercom.CompaniesRetrieveResponse.Company + | Intercom.CompaniesRetrieveResponse.List; + +export namespace CompaniesRetrieveResponse { + export interface Company extends Intercom.Company { + type: "company"; + } + + export interface List extends Intercom.CompanyList { + type: "list"; + } +} diff --git a/src/api/resources/companies/types/Company.ts b/src/api/resources/companies/types/Company.ts index 2534d3fc..2de7fd36 100644 --- a/src/api/resources/companies/types/Company.ts +++ b/src/api/resources/companies/types/Company.ts @@ -8,8 +8,6 @@ import * as Intercom from "../../../index"; * Companies allow you to represent organizations using your product. Each company will have its own description and be associated with contacts. You can fetch, create, update and list companies. */ export interface Company { - /** Value is `company` */ - type?: "company"; /** The Intercom defined id representing the company. */ id: string; /** The name of the company. */ diff --git a/src/api/resources/companies/types/index.ts b/src/api/resources/companies/types/index.ts index d15bbd39..66af316a 100644 --- a/src/api/resources/companies/types/index.ts +++ b/src/api/resources/companies/types/index.ts @@ -1 +1,2 @@ +export * from "./CompaniesRetrieveResponse"; export * from "./Company"; diff --git a/src/api/resources/contacts/client/Client.ts b/src/api/resources/contacts/client/Client.ts index 2f4b253e..a932e14b 100644 --- a/src/api/resources/contacts/client/Client.ts +++ b/src/api/resources/contacts/client/Client.ts @@ -116,8 +116,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -205,8 +205,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -290,8 +290,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -384,8 +384,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -465,8 +465,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -544,8 +544,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -620,8 +620,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -696,8 +696,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -771,8 +771,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -845,8 +845,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1028,8 +1028,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1125,8 +1125,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1206,8 +1206,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1279,8 +1279,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1348,8 +1348,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/conversations/client/Client.ts b/src/api/resources/conversations/client/Client.ts index 5e35fcec..b678ff40 100644 --- a/src/api/resources/conversations/client/Client.ts +++ b/src/api/resources/conversations/client/Client.ts @@ -120,8 +120,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -226,8 +226,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -322,8 +322,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -421,8 +421,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -609,8 +609,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -729,8 +729,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -851,8 +851,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -940,8 +940,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1039,8 +1039,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1129,8 +1129,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1225,8 +1225,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1309,8 +1309,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/customChannelEvents/client/Client.ts b/src/api/resources/customChannelEvents/client/Client.ts new file mode 100644 index 00000000..fa662231 --- /dev/null +++ b/src/api/resources/customChannelEvents/client/Client.ts @@ -0,0 +1,325 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import urlJoin from "url-join"; +import * as errors from "../../../../errors/index"; + +export declare namespace CustomChannelEvents { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +export class CustomChannelEvents { + constructor(protected readonly _options: CustomChannelEvents.Options = {}) {} + + /** + * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.customChannelEvents.notifyAttributeCollected() + */ + public async notifyAttributeCollected(requestOptions?: CustomChannelEvents.RequestOptions): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "custom_channel_events/notify_attribute_collected", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /custom_channel_events/notify_attribute_collected.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.customChannelEvents.notifyNewMessage() + */ + public async notifyNewMessage(requestOptions?: CustomChannelEvents.RequestOptions): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "custom_channel_events/notify_new_message", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /custom_channel_events/notify_new_message.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.customChannelEvents.notifyNewConversation() + */ + public async notifyNewConversation(requestOptions?: CustomChannelEvents.RequestOptions): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "custom_channel_events/notify_new_conversation", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /custom_channel_events/notify_new_conversation.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.customChannelEvents.notifyQuickReplySelected() + */ + public async notifyQuickReplySelected(requestOptions?: CustomChannelEvents.RequestOptions): Promise { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "custom_channel_events/notify_quick_reply_selected", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /custom_channel_events/notify_quick_reply_selected.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/customChannelEvents/client/index.ts b/src/api/resources/customChannelEvents/client/index.ts new file mode 100644 index 00000000..cb0ff5c3 --- /dev/null +++ b/src/api/resources/customChannelEvents/client/index.ts @@ -0,0 +1 @@ +export {}; diff --git a/src/api/resources/customChannelEvents/index.ts b/src/api/resources/customChannelEvents/index.ts new file mode 100644 index 00000000..5ec76921 --- /dev/null +++ b/src/api/resources/customChannelEvents/index.ts @@ -0,0 +1 @@ +export * from "./client"; diff --git a/src/api/resources/dataAttributes/client/Client.ts b/src/api/resources/dataAttributes/client/Client.ts index 614d3359..fe06c4fe 100644 --- a/src/api/resources/dataAttributes/client/Client.ts +++ b/src/api/resources/dataAttributes/client/Client.ts @@ -112,8 +112,8 @@ export class DataAttributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -226,8 +226,8 @@ export class DataAttributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -337,8 +337,8 @@ export class DataAttributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/dataExport/client/Client.ts b/src/api/resources/dataExport/client/Client.ts index 548a7df9..f4c041aa 100644 --- a/src/api/resources/dataExport/client/Client.ts +++ b/src/api/resources/dataExport/client/Client.ts @@ -117,8 +117,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -189,8 +189,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -258,8 +258,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -333,8 +333,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/events/client/Client.ts b/src/api/resources/events/client/Client.ts index 8afe9b6a..3b8c96f7 100644 --- a/src/api/resources/events/client/Client.ts +++ b/src/api/resources/events/client/Client.ts @@ -144,8 +144,8 @@ export class Events { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -260,8 +260,8 @@ export class Events { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -332,8 +332,8 @@ export class Events { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/helpCenters/client/Client.ts b/src/api/resources/helpCenters/client/Client.ts index a6e12499..523ddf97 100644 --- a/src/api/resources/helpCenters/client/Client.ts +++ b/src/api/resources/helpCenters/client/Client.ts @@ -110,8 +110,8 @@ export class HelpCenters { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -194,8 +194,8 @@ export class HelpCenters { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/helpCenters/resources/collections/client/Client.ts b/src/api/resources/helpCenters/resources/collections/client/Client.ts index a7f5a013..e5b4fb85 100644 --- a/src/api/resources/helpCenters/resources/collections/client/Client.ts +++ b/src/api/resources/helpCenters/resources/collections/client/Client.ts @@ -110,8 +110,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -202,8 +202,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -280,8 +280,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -360,8 +360,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -440,8 +440,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/index.ts b/src/api/resources/index.ts index b97ae198..3e1d913c 100644 --- a/src/api/resources/index.ts +++ b/src/api/resources/index.ts @@ -41,6 +41,7 @@ export * as events from "./events"; export * as phoneCallRedirects from "./phoneCallRedirects"; export * as ticketTypes from "./ticketTypes"; export * as visitors from "./visitors"; +export * as customChannelEvents from "./customChannelEvents"; export * from "./admins/client/requests"; export * from "./articles/client/requests"; export * from "./helpCenters/client/requests"; diff --git a/src/api/resources/messages/client/Client.ts b/src/api/resources/messages/client/Client.ts index 28f5c2f2..97ff5961 100644 --- a/src/api/resources/messages/client/Client.ts +++ b/src/api/resources/messages/client/Client.ts @@ -182,8 +182,8 @@ export class Messages { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/news/resources/feeds/client/Client.ts b/src/api/resources/news/resources/feeds/client/Client.ts index f9135b81..35a6e147 100644 --- a/src/api/resources/news/resources/feeds/client/Client.ts +++ b/src/api/resources/news/resources/feeds/client/Client.ts @@ -102,8 +102,8 @@ export class Feeds { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -171,8 +171,8 @@ export class Feeds { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -245,8 +245,8 @@ export class Feeds { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/news/resources/items/client/Client.ts b/src/api/resources/news/resources/items/client/Client.ts index 56023030..7321ae29 100644 --- a/src/api/resources/news/resources/items/client/Client.ts +++ b/src/api/resources/news/resources/items/client/Client.ts @@ -95,8 +95,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -178,8 +178,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -254,8 +254,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -348,8 +348,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -428,8 +428,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/notes/client/Client.ts b/src/api/resources/notes/client/Client.ts index 8271ea3f..a7307111 100644 --- a/src/api/resources/notes/client/Client.ts +++ b/src/api/resources/notes/client/Client.ts @@ -113,8 +113,8 @@ export class Notes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -201,8 +201,8 @@ export class Notes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -279,8 +279,8 @@ export class Notes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/phoneCallRedirects/client/Client.ts b/src/api/resources/phoneCallRedirects/client/Client.ts index f8cc8e05..c9b53a74 100644 --- a/src/api/resources/phoneCallRedirects/client/Client.ts +++ b/src/api/resources/phoneCallRedirects/client/Client.ts @@ -119,8 +119,8 @@ export class PhoneCallRedirects { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/segments/client/Client.ts b/src/api/resources/segments/client/Client.ts index b83e7b81..cc2d5ea6 100644 --- a/src/api/resources/segments/client/Client.ts +++ b/src/api/resources/segments/client/Client.ts @@ -108,8 +108,8 @@ export class Segments { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -184,8 +184,8 @@ export class Segments { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/subscriptionTypes/client/Client.ts b/src/api/resources/subscriptionTypes/client/Client.ts index 28ed27ea..b07d4e1e 100644 --- a/src/api/resources/subscriptionTypes/client/Client.ts +++ b/src/api/resources/subscriptionTypes/client/Client.ts @@ -98,8 +98,8 @@ export class SubscriptionTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/tags/client/Client.ts b/src/api/resources/tags/client/Client.ts index 4cb3a183..8aee0957 100644 --- a/src/api/resources/tags/client/Client.ts +++ b/src/api/resources/tags/client/Client.ts @@ -113,8 +113,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -194,8 +194,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -275,8 +275,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -357,8 +357,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -429,8 +429,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -537,8 +537,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -615,8 +615,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -690,8 +690,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -771,8 +771,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -851,8 +851,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/teams/client/Client.ts b/src/api/resources/teams/client/Client.ts index 468b8b04..33d2fe91 100644 --- a/src/api/resources/teams/client/Client.ts +++ b/src/api/resources/teams/client/Client.ts @@ -98,8 +98,8 @@ export class Teams { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -173,8 +173,8 @@ export class Teams { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/ticketTypes/client/Client.ts b/src/api/resources/ticketTypes/client/Client.ts index db370a8b..102a5367 100644 --- a/src/api/resources/ticketTypes/client/Client.ts +++ b/src/api/resources/ticketTypes/client/Client.ts @@ -105,8 +105,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -185,8 +185,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -260,8 +260,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -342,8 +342,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/ticketTypes/resources/attributes/client/Client.ts b/src/api/resources/ticketTypes/resources/attributes/client/Client.ts index 0b206966..d95d26c5 100644 --- a/src/api/resources/ticketTypes/resources/attributes/client/Client.ts +++ b/src/api/resources/ticketTypes/resources/attributes/client/Client.ts @@ -106,8 +106,8 @@ export class Attributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -185,8 +185,8 @@ export class Attributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/tickets/client/Client.ts b/src/api/resources/tickets/client/Client.ts index 6942cd19..2fc45671 100644 --- a/src/api/resources/tickets/client/Client.ts +++ b/src/api/resources/tickets/client/Client.ts @@ -152,8 +152,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -237,8 +237,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -312,8 +312,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -426,8 +426,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -571,8 +571,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/resources/visitors/client/Client.ts b/src/api/resources/visitors/client/Client.ts index 29d31f04..531cd2a7 100644 --- a/src/api/resources/visitors/client/Client.ts +++ b/src/api/resources/visitors/client/Client.ts @@ -108,8 +108,8 @@ export class Visitors { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -196,8 +196,8 @@ export class Visitors { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -283,8 +283,8 @@ export class Visitors { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.2.0", - "User-Agent": "intercom-client/6.2.0", + "X-Fern-SDK-Version": "6.3.0", + "User-Agent": "intercom-client/6.3.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, diff --git a/src/api/types/CompanyList.ts b/src/api/types/CompanyList.ts index 4bd8a082..8d4eb5de 100644 --- a/src/api/types/CompanyList.ts +++ b/src/api/types/CompanyList.ts @@ -8,8 +8,6 @@ import * as Intercom from "../index"; * This will return a list of companies for the App. */ export interface CompanyList { - /** The type of object - `list`. */ - type: "list"; pages?: Intercom.OffsetPages; /** The total number of companies. */ total_count: number; diff --git a/src/api/types/TicketCustomAttributes.ts b/src/api/types/TicketCustomAttributes.ts index 08242e66..fe9181ea 100644 --- a/src/api/types/TicketCustomAttributes.ts +++ b/src/api/types/TicketCustomAttributes.ts @@ -2,13 +2,7 @@ * This file was auto-generated by Fern from our API Definition. */ -import * as Intercom from "../index"; - /** * An object containing the different attributes associated to the ticket as key-value pairs. For the default title and description attributes, the keys are `_default_title_` and `_default_description_`. */ -export type TicketCustomAttributes = Record; - -export namespace TicketCustomAttributes { - export type Value = string | undefined | number | boolean | unknown[] | Intercom.FileAttribute; -} +export type TicketCustomAttributes = Record; diff --git a/src/api/types/TicketRequestCustomAttributes.ts b/src/api/types/TicketRequestCustomAttributes.ts index 6a3af042..ce59bc75 100644 --- a/src/api/types/TicketRequestCustomAttributes.ts +++ b/src/api/types/TicketRequestCustomAttributes.ts @@ -5,8 +5,4 @@ /** * The attributes set on the ticket. When setting the default title and description attributes, the attribute keys that should be used are `_default_title_` and `_default_description_`. When setting ticket type attributes of the list attribute type, the key should be the attribute name and the value of the attribute should be the list item id, obtainable by [listing the ticket type](ref:get_ticket-types). For example, if the ticket type has an attribute called `priority` of type `list`, the key should be `priority` and the value of the attribute should be the guid of the list item (e.g. `de1825a0-0164-4070-8ca6-13e22462fa7e`). */ -export type TicketRequestCustomAttributes = Record; - -export namespace TicketRequestCustomAttributes { - export type Value = string | undefined | number | boolean | unknown[]; -} +export type TicketRequestCustomAttributes = Record; diff --git a/src/version.ts b/src/version.ts index 35d67468..0ea5cbcb 100644 --- a/src/version.ts +++ b/src/version.ts @@ -1 +1 @@ -export const SDK_VERSION = "6.2.0"; +export const SDK_VERSION = "6.3.0"; diff --git a/yarn.lock b/yarn.lock index eb8d8c8d..33ecf06c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -10,114 +10,114 @@ "@jridgewell/gen-mapping" "^0.3.5" "@jridgewell/trace-mapping" "^0.3.24" -"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.12.13", "@babel/code-frame@^7.26.2": - version "7.26.2" - resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.26.2.tgz#4b5fab97d33338eff916235055f0ebc21e573a85" - integrity sha512-RJlIHRueQgwWitWgF8OdFYGZX328Ax5BCemNGlqHfplnRT9ESi8JkFlvaVYbS+UubVY6dpv87Fs2u5M29iNFVQ== +"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.12.13", "@babel/code-frame@^7.27.1": + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.27.1.tgz#200f715e66d52a23b221a9435534a91cc13ad5be" + integrity sha512-cjQ7ZlQ0Mv3b47hABuTevyTuYN4i+loJKGeV9flcCgIK37cCXRh+L1bd3iBHlynerhQ7BhCkn2BPbQUL+rGqFg== dependencies: - "@babel/helper-validator-identifier" "^7.25.9" + "@babel/helper-validator-identifier" "^7.27.1" js-tokens "^4.0.0" - picocolors "^1.0.0" + picocolors "^1.1.1" -"@babel/compat-data@^7.26.5": - version "7.26.8" - resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.26.8.tgz#821c1d35641c355284d4a870b8a4a7b0c141e367" - integrity sha512-oH5UPLMWR3L2wEFLnFJ1TZXqHufiTKAiLfqw5zkhS4dKXLJ10yVztfil/twG8EDTA4F/tvVNw9nOl4ZMslB8rQ== +"@babel/compat-data@^7.27.2": + version "7.27.2" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.27.2.tgz#4183f9e642fd84e74e3eea7ffa93a412e3b102c9" + integrity sha512-TUtMJYRPyUb/9aU8f3K0mjmjf6M9N5Woshn2CS6nqJSeJtTtQcpLUXjGt9vbF8ZGff0El99sWkLgzwW3VXnxZQ== "@babel/core@^7.11.6", "@babel/core@^7.12.3", "@babel/core@^7.23.9": - version "7.26.10" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.26.10.tgz#5c876f83c8c4dcb233ee4b670c0606f2ac3000f9" - integrity sha512-vMqyb7XCDMPvJFFOaT9kxtiRh42GwlZEg1/uIgtZshS5a/8OaduUfCi7kynKgc3Tw/6Uo2D+db9qBttghhmxwQ== + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.27.1.tgz#89de51e86bd12246003e3524704c49541b16c3e6" + integrity sha512-IaaGWsQqfsQWVLqMn9OB92MNN7zukfVA4s7KKAI0KfrrDsZ0yhi5uV4baBuLuN7n3vsZpwP8asPPcVwApxvjBQ== dependencies: "@ampproject/remapping" "^2.2.0" - "@babel/code-frame" "^7.26.2" - "@babel/generator" "^7.26.10" - "@babel/helper-compilation-targets" "^7.26.5" - "@babel/helper-module-transforms" "^7.26.0" - "@babel/helpers" "^7.26.10" - "@babel/parser" "^7.26.10" - "@babel/template" "^7.26.9" - "@babel/traverse" "^7.26.10" - "@babel/types" "^7.26.10" + "@babel/code-frame" "^7.27.1" + "@babel/generator" "^7.27.1" + "@babel/helper-compilation-targets" "^7.27.1" + "@babel/helper-module-transforms" "^7.27.1" + "@babel/helpers" "^7.27.1" + "@babel/parser" "^7.27.1" + "@babel/template" "^7.27.1" + "@babel/traverse" "^7.27.1" + "@babel/types" "^7.27.1" convert-source-map "^2.0.0" debug "^4.1.0" gensync "^1.0.0-beta.2" json5 "^2.2.3" semver "^6.3.1" -"@babel/generator@^7.26.10", "@babel/generator@^7.7.2": - version "7.26.10" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.26.10.tgz#a60d9de49caca16744e6340c3658dfef6138c3f7" - integrity sha512-rRHT8siFIXQrAYOYqZQVsAr8vJ+cBNqcVAY6m5V8/4QqzaPl+zDBe6cLEPRDuNOUf3ww8RfJVlOyQMoSI+5Ang== +"@babel/generator@^7.27.1", "@babel/generator@^7.7.2": + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.27.1.tgz#862d4fad858f7208edd487c28b58144036b76230" + integrity sha512-UnJfnIpc/+JO0/+KRVQNGU+y5taA5vCbwN8+azkX6beii/ZF+enZJSOKo11ZSzGJjlNfJHfQtmQT8H+9TXPG2w== dependencies: - "@babel/parser" "^7.26.10" - "@babel/types" "^7.26.10" + "@babel/parser" "^7.27.1" + "@babel/types" "^7.27.1" "@jridgewell/gen-mapping" "^0.3.5" "@jridgewell/trace-mapping" "^0.3.25" jsesc "^3.0.2" -"@babel/helper-compilation-targets@^7.26.5": - version "7.26.5" - resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.26.5.tgz#75d92bb8d8d51301c0d49e52a65c9a7fe94514d8" - integrity sha512-IXuyn5EkouFJscIDuFF5EsiSolseme1s0CZB+QxVugqJLYmKdxI1VfIBOst0SUu4rnk2Z7kqTwmoO1lp3HIfnA== +"@babel/helper-compilation-targets@^7.27.1": + version "7.27.2" + resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.27.2.tgz#46a0f6efab808d51d29ce96858dd10ce8732733d" + integrity sha512-2+1thGUUWWjLTYTHZWK1n8Yga0ijBz1XAhUXcKy81rd5g6yh7hGqMp45v7cadSbEHc9G3OTv45SyneRN3ps4DQ== dependencies: - "@babel/compat-data" "^7.26.5" - "@babel/helper-validator-option" "^7.25.9" + "@babel/compat-data" "^7.27.2" + "@babel/helper-validator-option" "^7.27.1" browserslist "^4.24.0" lru-cache "^5.1.1" semver "^6.3.1" -"@babel/helper-module-imports@^7.25.9": - version "7.25.9" - resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.25.9.tgz#e7f8d20602ebdbf9ebbea0a0751fb0f2a4141715" - integrity sha512-tnUA4RsrmflIM6W6RFTLFSXITtl0wKjgpnLgXyowocVPrbYrLUXSBXDgTs8BlbmIzIdlBySRQjINYs2BAkiLtw== +"@babel/helper-module-imports@^7.27.1": + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.27.1.tgz#7ef769a323e2655e126673bb6d2d6913bbead204" + integrity sha512-0gSFWUPNXNopqtIPQvlD5WgXYI5GY2kP2cCvoT8kczjbfcfuIljTbcWrulD1CIPIX2gt1wghbDy08yE1p+/r3w== dependencies: - "@babel/traverse" "^7.25.9" - "@babel/types" "^7.25.9" + "@babel/traverse" "^7.27.1" + "@babel/types" "^7.27.1" -"@babel/helper-module-transforms@^7.26.0": - version "7.26.0" - resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.26.0.tgz#8ce54ec9d592695e58d84cd884b7b5c6a2fdeeae" - integrity sha512-xO+xu6B5K2czEnQye6BHA7DolFFmS3LB7stHZFaOLb1pAwO1HWLS8fXA+eh0A2yIvltPVmx3eNNDBJA2SLHXFw== +"@babel/helper-module-transforms@^7.27.1": + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.27.1.tgz#e1663b8b71d2de948da5c4fb2a20ca4f3ec27a6f" + integrity sha512-9yHn519/8KvTU5BjTVEEeIM3w9/2yXNKoD82JifINImhpKkARMJKPP59kLo+BafpdN5zgNeIcS4jsGDmd3l58g== dependencies: - "@babel/helper-module-imports" "^7.25.9" - "@babel/helper-validator-identifier" "^7.25.9" - "@babel/traverse" "^7.25.9" + "@babel/helper-module-imports" "^7.27.1" + "@babel/helper-validator-identifier" "^7.27.1" + "@babel/traverse" "^7.27.1" -"@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.14.5", "@babel/helper-plugin-utils@^7.25.9", "@babel/helper-plugin-utils@^7.8.0": - version "7.26.5" - resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.26.5.tgz#18580d00c9934117ad719392c4f6585c9333cc35" - integrity sha512-RS+jZcRdZdRFzMyr+wcsaqOmld1/EqTghfaBGQQd/WnRdzdlvSZ//kF7U8VQTxf1ynZ4cjUcYgjVGx13ewNPMg== +"@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.14.5", "@babel/helper-plugin-utils@^7.27.1", "@babel/helper-plugin-utils@^7.8.0": + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.27.1.tgz#ddb2f876534ff8013e6c2b299bf4d39b3c51d44c" + integrity sha512-1gn1Up5YXka3YYAHGKpbideQ5Yjf1tDa9qYcgysz+cNCXukyLl6DjPXhD3VRwSb8c0J9tA4b2+rHEZtc6R0tlw== -"@babel/helper-string-parser@^7.25.9": - version "7.25.9" - resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.25.9.tgz#1aabb72ee72ed35789b4bbcad3ca2862ce614e8c" - integrity sha512-4A/SCr/2KLd5jrtOMFzaKjVtAei3+2r/NChoBNoZ3EyP/+GlhoaEGoWOZUmFmoITP7zOJyHIMm+DYRd8o3PvHA== +"@babel/helper-string-parser@^7.27.1": + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.27.1.tgz#54da796097ab19ce67ed9f88b47bb2ec49367687" + integrity sha512-qMlSxKbpRlAridDExk92nSobyDdpPijUq2DW6oDnUqd0iOGxmQjyqhMIihI9+zv4LPyZdRje2cavWPbCbWm3eA== -"@babel/helper-validator-identifier@^7.25.9": - version "7.25.9" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.25.9.tgz#24b64e2c3ec7cd3b3c547729b8d16871f22cbdc7" - integrity sha512-Ed61U6XJc3CVRfkERJWDz4dJwKe7iLmmJsbOGu9wSloNSFttHV0I8g6UAgb7qnK5ly5bGLPd4oXZlxCdANBOWQ== +"@babel/helper-validator-identifier@^7.27.1": + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.27.1.tgz#a7054dcc145a967dd4dc8fee845a57c1316c9df8" + integrity sha512-D2hP9eA+Sqx1kBZgzxZh0y1trbuU+JoDkiEwqhQ36nodYqJwyEIhPSdMNd7lOm/4io72luTPWH20Yda0xOuUow== -"@babel/helper-validator-option@^7.25.9": - version "7.25.9" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.25.9.tgz#86e45bd8a49ab7e03f276577f96179653d41da72" - integrity sha512-e/zv1co8pp55dNdEcCynfj9X7nyUKUXoUEwfXqaZt0omVOmDe9oOTdKStH4GmAw6zxMFs50ZayuMfHDKlO7Tfw== +"@babel/helper-validator-option@^7.27.1": + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.27.1.tgz#fa52f5b1e7db1ab049445b421c4471303897702f" + integrity sha512-YvjJow9FxbhFFKDSuFnVCe2WxXk1zWc22fFePVNEaWJEu8IrZVlda6N0uHwzZrUM1il7NC9Mlp4MaJYbYd9JSg== -"@babel/helpers@^7.26.10": - version "7.26.10" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.26.10.tgz#6baea3cd62ec2d0c1068778d63cb1314f6637384" - integrity sha512-UPYc3SauzZ3JGgj87GgZ89JVdC5dj0AoetR5Bw6wj4niittNyFh6+eOGonYvJ1ao6B8lEa3Q3klS7ADZ53bc5g== +"@babel/helpers@^7.27.1": + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.27.1.tgz#ffc27013038607cdba3288e692c3611c06a18aa4" + integrity sha512-FCvFTm0sWV8Fxhpp2McP5/W53GPllQ9QeQ7SiqGWjMf/LVG07lFa5+pgK05IRhVwtvafT22KF+ZSnM9I545CvQ== dependencies: - "@babel/template" "^7.26.9" - "@babel/types" "^7.26.10" + "@babel/template" "^7.27.1" + "@babel/types" "^7.27.1" -"@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.20.7", "@babel/parser@^7.23.9", "@babel/parser@^7.26.10", "@babel/parser@^7.26.9": - version "7.26.10" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.26.10.tgz#e9bdb82f14b97df6569b0b038edd436839c57749" - integrity sha512-6aQR2zGE/QFi8JpDLjUZEPYOs7+mhKXm86VaKFiLP35JQwQb6bwUE+XbvkH0EptsYhbNBSUGaUBLKqxH1xSgsA== +"@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.20.7", "@babel/parser@^7.23.9", "@babel/parser@^7.27.1", "@babel/parser@^7.27.2": + version "7.27.2" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.27.2.tgz#577518bedb17a2ce4212afd052e01f7df0941127" + integrity sha512-QYLs8299NA7WM/bZAdp+CviYYkVoYXlDW2rzliy3chxd1PQjej7JORuMJDJXJUb9g0TT+B99EwaVLKmX+sPXWw== dependencies: - "@babel/types" "^7.26.10" + "@babel/types" "^7.27.1" "@babel/plugin-syntax-async-generators@^7.8.4": version "7.8.4" @@ -148,11 +148,11 @@ "@babel/helper-plugin-utils" "^7.14.5" "@babel/plugin-syntax-import-attributes@^7.24.7": - version "7.26.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-import-attributes/-/plugin-syntax-import-attributes-7.26.0.tgz#3b1412847699eea739b4f2602c74ce36f6b0b0f7" - integrity sha512-e2dttdsJ1ZTpi3B9UYGLw41hifAubg19AtCu/2I/F1QNVclOBr1dYpTdmdyZ84Xiz43BS/tCUkMAZNLv12Pi+A== + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-import-attributes/-/plugin-syntax-import-attributes-7.27.1.tgz#34c017d54496f9b11b61474e7ea3dfd5563ffe07" + integrity sha512-oFT0FrKHgF53f4vOsZGi2Hh3I35PfSmVs4IBFLFj4dnafP+hIWDLg3VyKmUHfLoLHlyxY4C7DGtmHuJgn+IGww== dependencies: - "@babel/helper-plugin-utils" "^7.25.9" + "@babel/helper-plugin-utils" "^7.27.1" "@babel/plugin-syntax-import-meta@^7.10.4": version "7.10.4" @@ -169,11 +169,11 @@ "@babel/helper-plugin-utils" "^7.8.0" "@babel/plugin-syntax-jsx@^7.7.2": - version "7.25.9" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.25.9.tgz#a34313a178ea56f1951599b929c1ceacee719290" - integrity sha512-ld6oezHQMZsZfp6pWtbjaNDF2tiiCYYDqQszHt5VV437lewP9aSi2Of99CK0D0XB21k7FLgnLcmQKyKzynfeAA== + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.27.1.tgz#2f9beb5eff30fa507c5532d107daac7b888fa34c" + integrity sha512-y8YTNIeKoyhGd9O0Jiyzyyqk8gdjnumGTQPsz0xOZOQ2RmkVJeZ1vmmfIvFEKqucBG6axJGBZDE/7iI5suUI/w== dependencies: - "@babel/helper-plugin-utils" "^7.25.9" + "@babel/helper-plugin-utils" "^7.27.1" "@babel/plugin-syntax-logical-assignment-operators@^7.10.4": version "7.10.4" @@ -232,41 +232,41 @@ "@babel/helper-plugin-utils" "^7.14.5" "@babel/plugin-syntax-typescript@^7.7.2": - version "7.25.9" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.25.9.tgz#67dda2b74da43727cf21d46cf9afef23f4365399" - integrity sha512-hjMgRy5hb8uJJjUcdWunWVcoi9bGpJp8p5Ol1229PoN6aytsLwNMgmdftO23wnCLMfVmTwZDWMPNq/D1SY60JQ== - dependencies: - "@babel/helper-plugin-utils" "^7.25.9" - -"@babel/template@^7.26.9", "@babel/template@^7.3.3": - version "7.26.9" - resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.26.9.tgz#4577ad3ddf43d194528cff4e1fa6b232fa609bb2" - integrity sha512-qyRplbeIpNZhmzOysF/wFMuP9sctmh2cFzRAZOn1YapxBsE1i9bJIY586R/WBLfLcmcBlM8ROBiQURnnNy+zfA== - dependencies: - "@babel/code-frame" "^7.26.2" - "@babel/parser" "^7.26.9" - "@babel/types" "^7.26.9" - -"@babel/traverse@^7.25.9", "@babel/traverse@^7.26.10": - version "7.26.10" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.26.10.tgz#43cca33d76005dbaa93024fae536cc1946a4c380" - integrity sha512-k8NuDrxr0WrPH5Aupqb2LCVURP/S0vBEn5mK6iH+GIYob66U5EtoZvcdudR2jQ4cmTwhEwW1DLB+Yyas9zjF6A== - dependencies: - "@babel/code-frame" "^7.26.2" - "@babel/generator" "^7.26.10" - "@babel/parser" "^7.26.10" - "@babel/template" "^7.26.9" - "@babel/types" "^7.26.10" + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.27.1.tgz#5147d29066a793450f220c63fa3a9431b7e6dd18" + integrity sha512-xfYCBMxveHrRMnAWl1ZlPXOZjzkN82THFvLhQhFXFt81Z5HnN+EtUkZhv/zcKpmT3fzmWZB0ywiBrbC3vogbwQ== + dependencies: + "@babel/helper-plugin-utils" "^7.27.1" + +"@babel/template@^7.27.1", "@babel/template@^7.3.3": + version "7.27.2" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.27.2.tgz#fa78ceed3c4e7b63ebf6cb39e5852fca45f6809d" + integrity sha512-LPDZ85aEJyYSd18/DkjNh4/y1ntkE5KwUHWTiqgRxruuZL2F1yuHligVHLvcHY2vMHXttKFpJn6LwfI7cw7ODw== + dependencies: + "@babel/code-frame" "^7.27.1" + "@babel/parser" "^7.27.2" + "@babel/types" "^7.27.1" + +"@babel/traverse@^7.27.1": + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.27.1.tgz#4db772902b133bbddd1c4f7a7ee47761c1b9f291" + integrity sha512-ZCYtZciz1IWJB4U61UPu4KEaqyfj+r5T1Q5mqPo+IBpcG9kHv30Z0aD8LXPgC1trYa6rK0orRyAhqUgk4MjmEg== + dependencies: + "@babel/code-frame" "^7.27.1" + "@babel/generator" "^7.27.1" + "@babel/parser" "^7.27.1" + "@babel/template" "^7.27.1" + "@babel/types" "^7.27.1" debug "^4.3.1" globals "^11.1.0" -"@babel/types@^7.0.0", "@babel/types@^7.20.7", "@babel/types@^7.25.9", "@babel/types@^7.26.10", "@babel/types@^7.26.9", "@babel/types@^7.3.3": - version "7.26.10" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.26.10.tgz#396382f6335bd4feb65741eacfc808218f859259" - integrity sha512-emqcG3vHrpxUKTrxcblR36dcrcoRDvKmnL/dCL6ZsHaShW80qxCAcNhzQZrpeM765VzEos+xOi4s+r4IXzTwdQ== +"@babel/types@^7.0.0", "@babel/types@^7.20.7", "@babel/types@^7.27.1", "@babel/types@^7.3.3": + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.27.1.tgz#9defc53c16fc899e46941fc6901a9eea1c9d8560" + integrity sha512-+EzkxvLNfiUeKMgy/3luqfsCWFRXLb7U6wNQTk60tovuckwB15B191tJWvpp4HjiQWdJkCxO3Wbvc6jlk3Xb2Q== dependencies: - "@babel/helper-string-parser" "^7.25.9" - "@babel/helper-validator-identifier" "^7.25.9" + "@babel/helper-string-parser" "^7.27.1" + "@babel/helper-validator-identifier" "^7.27.1" "@bcoe/v8-coverage@^0.2.3": version "0.2.3" @@ -557,9 +557,9 @@ "@types/babel__traverse" "*" "@types/babel__generator@*": - version "7.6.8" - resolved "https://registry.yarnpkg.com/@types/babel__generator/-/babel__generator-7.6.8.tgz#f836c61f48b1346e7d2b0d93c6dacc5b9535d3ab" - integrity sha512-ASsj+tpEDsEiFr1arWrlN6V3mdfjRMZt6LtK/Vp/kreFLnr5QH5+DhvD5nINYZXzwJvXeGq+05iUXcAzVrqWtw== + version "7.27.0" + resolved "https://registry.yarnpkg.com/@types/babel__generator/-/babel__generator-7.27.0.tgz#b5819294c51179957afaec341442f9341e4108a9" + integrity sha512-ufFd2Xi92OAVPYsy+P4n7/U7e68fex0+Ee8gSG9KX7eo084CWiQ4sdxktvdl0bOPupXtVJPY19zk6EwWqUQ8lg== dependencies: "@babel/types" "^7.0.0" @@ -572,9 +572,9 @@ "@babel/types" "^7.0.0" "@types/babel__traverse@*", "@types/babel__traverse@^7.0.6": - version "7.20.6" - resolved "https://registry.yarnpkg.com/@types/babel__traverse/-/babel__traverse-7.20.6.tgz#8dc9f0ae0f202c08d8d4dab648912c8d6038e3f7" - integrity sha512-r1bzfrm0tomOI8g1SzvCaQHo6Lcv6zu0EA+W2kHrt8dyrHQxGzBBL4kdkzIS+jBMV+EYcMAEAqXqYaLJq5rOZg== + version "7.20.7" + resolved "https://registry.yarnpkg.com/@types/babel__traverse/-/babel__traverse-7.20.7.tgz#968cdc2366ec3da159f61166428ee40f370e56c2" + integrity sha512-dkO5fhS7+/oos4ciWxyEyjWe48zmG6wbCheo/G2ZnHx4fs3EU6YC6UM8rk56gAjNJ9P3MTH2jo5jb92/K6wbng== dependencies: "@babel/types" "^7.20.7" @@ -595,9 +595,9 @@ "@types/json-schema" "*" "@types/estree@*", "@types/estree@^1.0.6": - version "1.0.6" - resolved "https://registry.yarnpkg.com/@types/estree/-/estree-1.0.6.tgz#628effeeae2064a1b4e79f78e81d87b7e5fc7b50" - integrity sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw== + version "1.0.7" + resolved "https://registry.yarnpkg.com/@types/estree/-/estree-1.0.7.tgz#4158d3105276773d5b7695cd4834b1722e4f37a8" + integrity sha512-w28IoSUCJpidD/TGviZwwMJckNESJZXFu7NBZ5YJ4mEUnNraUn9Pm8HSZm/jDF1pDWYKspWE7oVphigUPRakIQ== "@types/graceful-fs@^4.1.3": version "4.1.9" @@ -642,7 +642,7 @@ "@types/tough-cookie" "*" parse5 "^7.0.0" -"@types/json-schema@*", "@types/json-schema@^7.0.9": +"@types/json-schema@*", "@types/json-schema@^7.0.15", "@types/json-schema@^7.0.9": version "7.0.15" resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.15.tgz#596a1747233694d50f6ad8a7869fcb6f56cf5841" integrity sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA== @@ -656,31 +656,30 @@ form-data "^4.0.0" "@types/node@*": - version "22.13.10" - resolved "https://registry.yarnpkg.com/@types/node/-/node-22.13.10.tgz#df9ea358c5ed991266becc3109dc2dc9125d77e4" - integrity sha512-I6LPUvlRH+O6VRUqYOcMudhaIdUVWfsjnZavnsraHvpBwaEyMN29ry+0UVJhImYL16xsscu0aske3yA+uPOWfw== + version "22.15.21" + resolved "https://registry.yarnpkg.com/@types/node/-/node-22.15.21.tgz#196ef14fe20d87f7caf1e7b39832767f9a995b77" + integrity sha512-EV/37Td6c+MgKAbkcLG6vqZ2zEYHD7bvSrzqqs2RIhbA6w3x+Dqz8MZM3sP6kGTeLrdoOgKZe+Xja7tUB2DNkQ== dependencies: - undici-types "~6.20.0" + undici-types "~6.21.0" "@types/node@^18.19.70": - version "18.19.80" - resolved "https://registry.yarnpkg.com/@types/node/-/node-18.19.80.tgz#6d6008e8920dddcd23f9dd33da24684ef57d487c" - integrity sha512-kEWeMwMeIvxYkeg1gTc01awpwLbfMRZXdIhwRcakd/KlK53jmRC26LqcbIt7fnAQTu5GzlnWmzA3H6+l1u6xxQ== + version "18.19.103" + resolved "https://registry.yarnpkg.com/@types/node/-/node-18.19.103.tgz#9bbd31a54e240fc469cca409d7507ebc77536458" + integrity sha512-hHTHp+sEz6SxFsp+SA+Tqrua3AbmlAw+Y//aEwdHrdZkYVRWdvWD3y5uPZ0flYOkgskaFWqZ/YGFm3FaFQ0pRw== dependencies: undici-types "~5.26.4" "@types/qs@^6.9.17": - version "6.9.18" - resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.9.18.tgz#877292caa91f7c1b213032b34626505b746624c2" - integrity sha512-kK7dgTYDyGqS+e2Q4aK9X3D7q234CIZ1Bv0q/7Z5IwRDoADNU81xXJK/YVyLbLTZCoIwUoDoffFeF+p/eIklAA== + version "6.14.0" + resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.14.0.tgz#d8b60cecf62f2db0fb68e5e006077b9178b85de5" + integrity sha512-eOunJqu0K1923aExK6y8p6fsihYEn/BYuQ4g0CxAAgFc4b/ZLN4CrsRZ55srTdqoiLzU2B2evC+apEIxprEzkQ== "@types/readable-stream@^4.0.18": - version "4.0.18" - resolved "https://registry.yarnpkg.com/@types/readable-stream/-/readable-stream-4.0.18.tgz#5d8d15d26c776500ce573cae580787d149823bfc" - integrity sha512-21jK/1j+Wg+7jVw1xnSwy/2Q1VgVjWuFssbYGTREPUBeZ+rqVFl2udq0IkxzPC0ZhOzVceUbyIACFZKLqKEBlA== + version "4.0.19" + resolved "https://registry.yarnpkg.com/@types/readable-stream/-/readable-stream-4.0.19.tgz#e2392f17a9e11aca6e6b21b537aa13bc96a57e46" + integrity sha512-6Tgd3lMocKwOul/kwAAgSebkhdMCLhRvcJ6CKHA6wdql2qNIwK6hw3Y4PZQxn9HcJogoC/1ZOmkFM7OZKH/VrA== dependencies: "@types/node" "*" - safe-buffer "~5.1.1" "@types/stack-utils@^2.0.0": version "2.0.3" @@ -867,7 +866,7 @@ acorn-walk@^8.0.2: dependencies: acorn "^8.11.0" -acorn@^8.1.0, acorn@^8.11.0, acorn@^8.14.0, acorn@^8.8.1, acorn@^8.8.2: +acorn@^8.1.0, acorn@^8.11.0, acorn@^8.14.0, acorn@^8.8.1: version "8.14.1" resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.14.1.tgz#721d5dc10f7d5b5609a891773d47731796935dfb" integrity sha512-OvQ/2pUDKmgfCg++xsTX1wGxfTaszcHVcTctW4UJB4hibJx2HXxxO5UmVgyjMa+ZDsiaf5wWLXYpRWMmBI0QHg== @@ -1048,14 +1047,14 @@ braces@^3.0.3: fill-range "^7.1.1" browserslist@^4.24.0: - version "4.24.4" - resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.24.4.tgz#c6b2865a3f08bcb860a0e827389003b9fe686e4b" - integrity sha512-KDi1Ny1gSePi1vm0q4oxSF8b4DR44GF4BbmS2YdhPLOEqd8pDviZOGH/GsmRwoWJ2+5Lr085X7naowMwKHDG1A== + version "4.24.5" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.24.5.tgz#aa0f5b8560fe81fde84c6dcb38f759bafba0e11b" + integrity sha512-FDToo4Wo82hIdgc1CQ+NQD0hEhmpPjrZ3hiUgwgOG6IuTdlpr8jdjyG24P6cNP1yJpTLzS5OcGgSw0xmDU1/Tw== dependencies: - caniuse-lite "^1.0.30001688" - electron-to-chromium "^1.5.73" + caniuse-lite "^1.0.30001716" + electron-to-chromium "^1.5.149" node-releases "^2.0.19" - update-browserslist-db "^1.1.1" + update-browserslist-db "^1.1.3" bs-logger@^0.2.6: version "0.2.6" @@ -1115,10 +1114,10 @@ camelcase@^6.2.0: resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-6.3.0.tgz#5685b95eb209ac9c0c177467778c9c84df58ba9a" integrity sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA== -caniuse-lite@^1.0.30001688: - version "1.0.30001706" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001706.tgz#902c3f896f4b2968031c3a546ab2ef8b465a2c8f" - integrity sha512-3ZczoTApMAZwPKYWmwVbQMFpXBDds3/0VciVoUwPUbldlYyVLmRVuRs/PcUZtHpbLRpzzDvrvnFuREsGt6lUug== +caniuse-lite@^1.0.30001716: + version "1.0.30001718" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001718.tgz#dae13a9c80d517c30c6197515a96131c194d8f82" + integrity sha512-AflseV1ahcSunK53NfEs9gFWgOEmzr0f+kaMFA4xiLZlr9Hzt7HxcSpIFcnNCUkz6R6dWKa54rUz3HUmI3nVcw== chalk@^4.0.0, chalk@^4.0.2, chalk@^4.1.0: version "4.1.2" @@ -1250,9 +1249,9 @@ data-urls@^3.0.2: whatwg-url "^11.0.0" debug@4, debug@^4.1.0, debug@^4.1.1, debug@^4.3.1: - version "4.4.0" - resolved "https://registry.yarnpkg.com/debug/-/debug-4.4.0.tgz#2b3f2aea2ffeb776477460267377dc8710faba8a" - integrity sha512-6WTZ/IxCY/T6BALoZHaE4ctp9xm+Z5kY/pzYaCHRFeyVhojxlrm+46y68HA6hr0TcwEssoxNiDEUJQjfPZ/RYA== + version "4.4.1" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.4.1.tgz#e5a8bc6cbc4c6cd3e64308b0693a3d4fa550189b" + integrity sha512-KcKCqiftBJcZr++7ykoDIEwSa3XWowTfNPo92BYxjXiyYEVrUQh2aLyhxBCwww+heortUFxEJYcRzosstTEBYQ== dependencies: ms "^2.1.3" @@ -1262,9 +1261,9 @@ decimal.js@^10.4.2: integrity sha512-8vDa8Qxvr/+d94hSh5P3IJwI5t8/c0KsMp+g8bNw9cY2icONa5aPfvKeieW1WlG0WQYwwhJ7mjui2xtiePQSXw== dedent@^1.0.0: - version "1.5.3" - resolved "https://registry.yarnpkg.com/dedent/-/dedent-1.5.3.tgz#99aee19eb9bae55a67327717b6e848d0bf777e5a" - integrity sha512-NHQtfOOW68WD8lgypbLA5oT+Bt0xXJhiYvoR6SmmNXZfpzOGXwdKWmcwG8N7PwVVWV3eF/68nmD9BaJSsTBhyQ== + version "1.6.0" + resolved "https://registry.yarnpkg.com/dedent/-/dedent-1.6.0.tgz#79d52d6389b1ffa67d2bcef59ba51847a9d503b2" + integrity sha512-F1Z+5UCFpmQUzJa11agbyPVMbpgT/qA3/SKyJ1jyBgm7dUcUEa8v9JwDkerSQXfakBwFljIxhOJqGkjUwZ9FSA== deepmerge@^4.2.2: version "4.3.1" @@ -1309,10 +1308,10 @@ ejs@^3.1.10: dependencies: jake "^10.8.5" -electron-to-chromium@^1.5.73: - version "1.5.122" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.122.tgz#4fabd37b30b71dc041f6c6c4bab309b3f8348fcb" - integrity sha512-EML1wnwkY5MFh/xUnCvY8FrhUuKzdYhowuZExZOfwJo+Zu9OsNCI23Cgl5y7awy7HrUHSwB1Z8pZX5TI34lsUg== +electron-to-chromium@^1.5.149: + version "1.5.155" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.155.tgz#809dd0ae9ae1db87c358e0c0c17c09a2ffc432d1" + integrity sha512-ps5KcGGmwL8VaeJlvlDlu4fORQpv3+GIcF5I3f9tUKUlJ/wsysh6HU8P5L1XWRYeXfA0oJd4PyM8ds8zTFf6Ng== emittery@^0.13.1: version "0.13.1" @@ -1332,10 +1331,10 @@ enhanced-resolve@^5.0.0, enhanced-resolve@^5.17.1: graceful-fs "^4.2.4" tapable "^2.2.0" -entities@^4.5.0: - version "4.5.0" - resolved "https://registry.yarnpkg.com/entities/-/entities-4.5.0.tgz#5d268ea5e7113ec74c4d033b79ea5a35a488fb48" - integrity sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw== +entities@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/entities/-/entities-6.0.0.tgz#09c9e29cb79b0a6459a9b9db9efb418ac5bb8e51" + integrity sha512-aKstq2TDOndCn4diEyp9Uq/Flu2i1GlLkc6XIDQSDMuaFE3OPW5OphLCyQ5SpSJZTb4reN+kTcYru5yIfXoRPw== error-ex@^1.3.1: version "1.3.2" @@ -1355,9 +1354,9 @@ es-errors@^1.3.0: integrity sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw== es-module-lexer@^1.2.1: - version "1.6.0" - resolved "https://registry.yarnpkg.com/es-module-lexer/-/es-module-lexer-1.6.0.tgz#da49f587fd9e68ee2404fe4e256c0c7d3a81be21" - integrity sha512-qqnD1yMU6tk/jnaMosogGySTZP8YtUgAffA9nMN+E/rjxcfRQ6IEk7IiozUjgxKoFHBGjTLnrHB/YC45r/59EQ== + version "1.7.0" + resolved "https://registry.yarnpkg.com/es-module-lexer/-/es-module-lexer-1.7.0.tgz#9159601561880a85f2734560a9099b2c31e5372a" + integrity sha512-jEQoCwk8hyb2AZziIOLhDqpm5+2ww5uIE6lkO/6jcOCusfk6LhMHpXXfBLXTZ7Ydyt0j4VoUQv6uGNYbdW+kBA== es-object-atoms@^1.0.0, es-object-atoms@^1.1.1: version "1.1.1" @@ -2427,9 +2426,9 @@ npm-run-path@^4.0.1: path-key "^3.0.0" nwsapi@^2.2.2: - version "2.2.19" - resolved "https://registry.yarnpkg.com/nwsapi/-/nwsapi-2.2.19.tgz#586660f7c24c34691907002309a8dc28064c9c0b" - integrity sha512-94bcyI3RsqiZufXjkr3ltkI86iEl+I7uiHVDtcq9wJUTwYQJ5odHDeSzkkrRzi80jJ8MaeZgqKjH1bAWAFw9bA== + version "2.2.20" + resolved "https://registry.yarnpkg.com/nwsapi/-/nwsapi-2.2.20.tgz#22e53253c61e7b0e7e93cef42c891154bcca11ef" + integrity sha512-/ieB+mDe4MrrKMT8z+mQL8klXydZWGR5Dowt4RAGKbJ3kIGEx3X4ljUo+6V73IXtUPWgfOlU5B9MlGxFO5T+cA== object-inspect@^1.13.3: version "1.13.4" @@ -2487,11 +2486,11 @@ parse-json@^5.2.0: lines-and-columns "^1.1.6" parse5@^7.0.0, parse5@^7.1.1: - version "7.2.1" - resolved "https://registry.yarnpkg.com/parse5/-/parse5-7.2.1.tgz#8928f55915e6125f430cc44309765bf17556a33a" - integrity sha512-BuBYQYlv1ckiPdQi/ohiivi9Sagc9JG+Ozs0r7b/0iK3sKmrb0b9FdWdBbOdx6hBCM/F9Ir82ofnBhtZOjCRPQ== + version "7.3.0" + resolved "https://registry.yarnpkg.com/parse5/-/parse5-7.3.0.tgz#d7e224fa72399c7a175099f45fc2ad024b05ec05" + integrity sha512-IInvU7fabl34qmi9gY8XOVxhYyMyuH2xUNpb2q8/Y+7552KlejkRvqvD19nMoUW/uQGGbqNpA6Tufu5FL5BZgw== dependencies: - entities "^4.5.0" + entities "^6.0.0" path-exists@^4.0.0: version "4.0.0" @@ -2513,7 +2512,7 @@ path-parse@^1.0.7: resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" integrity sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw== -picocolors@^1.0.0, picocolors@^1.1.1: +picocolors@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.1.1.tgz#3d321af3eab939b083c8f929a1d12cda81c26b6b" integrity sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA== @@ -2524,9 +2523,9 @@ picomatch@^2.0.4, picomatch@^2.2.3, picomatch@^2.3.1: integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== pirates@^4.0.4: - version "4.0.6" - resolved "https://registry.yarnpkg.com/pirates/-/pirates-4.0.6.tgz#3018ae32ecfcff6c29ba2267cbf21166ac1f36b9" - integrity sha512-saLsH7WeYYPiD25LDuLRRY/i+6HaPYr6G1OUlN39otzkSTxKnubR9RTxS3/Kk50s1g2JTgFwWQDQyplC5/SHZg== + version "4.0.7" + resolved "https://registry.yarnpkg.com/pirates/-/pirates-4.0.7.tgz#643b4a18c4257c8a65104b73f3049ce9a0a15e22" + integrity sha512-TfySrs/5nm8fQJDcBDuUng3VOUKsd7S+zqvbOTiGXHfxX4wK31ard+hoNuvkicM/2YFzlpDgABOevKSsB4G/FA== pkg-dir@^4.2.0: version "4.2.0" @@ -2660,11 +2659,6 @@ safe-buffer@^5.1.0, safe-buffer@~5.2.0: resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== -safe-buffer@~5.1.1: - version "5.1.2" - resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" - integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== - "safer-buffer@>= 2.1.2 < 3.0.0": version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" @@ -2677,10 +2671,10 @@ saxes@^6.0.0: dependencies: xmlchars "^2.2.0" -schema-utils@^4.3.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-4.3.0.tgz#3b669f04f71ff2dfb5aba7ce2d5a9d79b35622c0" - integrity sha512-Gf9qqc58SpCA/xdziiHz35F4GNIWYWZrEshUc/G/r5BnLph6xpKuLeoJoQuj5WfBIx/eQLf+hmVPYHaxJu7V2g== +schema-utils@^4.3.0, schema-utils@^4.3.2: + version "4.3.2" + resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-4.3.2.tgz#0c10878bf4a73fd2b1dfd14b9462b26788c806ae" + integrity sha512-Gn/JaSk/Mt9gYubxTtSn/QCV4em9mpAPiR1rqy/Ocu19u/G9J5WWdNoUT4SiV6mFC3y6cxyFcFwdzPM3FgxGAQ== dependencies: "@types/json-schema" "^7.0.9" ajv "^8.9.0" @@ -2692,10 +2686,10 @@ semver@^6.3.0, semver@^6.3.1: resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== -semver@^7.3.4, semver@^7.5.3, semver@^7.5.4, semver@^7.7.1: - version "7.7.1" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.7.1.tgz#abd5098d82b18c6c81f6074ff2647fd3e7220c9f" - integrity sha512-hlq8tAfn0m/61p4BVRcPzIGr6LKiMwo4VM6dGi6pt4qcRkmNzTcWq6eCEjEh+qXjkMDvPlOFFSGwQjoEa6gyMA== +semver@^7.3.4, semver@^7.5.3, semver@^7.5.4, semver@^7.7.2: + version "7.7.2" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.7.2.tgz#67d99fdcd35cec21e6f8b87a7fd515a33f982b58" + integrity sha512-RF0Fw+rO5AMf9MAyaRXI4AV0Ulj5lMHqVxxdSgiVbixSCXoEmmX/jk0CuJw4+3SqroYO9VoUh+HcuJivvtJemA== serialize-javascript@^6.0.2: version "6.0.2" @@ -2880,9 +2874,9 @@ symbol-tree@^3.2.4: integrity sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw== tapable@^2.1.1, tapable@^2.2.0: - version "2.2.1" - resolved "https://registry.yarnpkg.com/tapable/-/tapable-2.2.1.tgz#1967a73ef4060a82f12ab96af86d52fdb76eeca0" - integrity sha512-GNzQvQTOIP6RyTfE2Qxb8ZVlNmw0n88vp1szwWRimP02mnTsx3Wtn5qRdqY9w2XduFNUgvOwhNnQsjwCp+kqaQ== + version "2.2.2" + resolved "https://registry.yarnpkg.com/tapable/-/tapable-2.2.2.tgz#ab4984340d30cb9989a490032f086dbb8b56d872" + integrity sha512-Re10+NauLTMCudc7T5WLFLAwDhQ0JWdrMK+9B2M8zR5hRExKmsRDCBA7/aV/pNJFltmBFO5BAMlQFi/vq3nKOg== terser-webpack-plugin@^5.3.11: version "5.3.14" @@ -2896,12 +2890,12 @@ terser-webpack-plugin@^5.3.11: terser "^5.31.1" terser@^5.31.1: - version "5.39.0" - resolved "https://registry.yarnpkg.com/terser/-/terser-5.39.0.tgz#0e82033ed57b3ddf1f96708d123cca717d86ca3a" - integrity sha512-LBAhFyLho16harJoWMg/nZsQYgTrg5jXOn2nCYjRUcZZEdE3qa2zb8QEDRUGVZBW4rlazf2fxkg8tztybTaqWw== + version "5.39.2" + resolved "https://registry.yarnpkg.com/terser/-/terser-5.39.2.tgz#5a1626030724a672e2e5b5c9cd9070308c20e8f9" + integrity sha512-yEPUmWve+VA78bI71BW70Dh0TuV4HHd+I5SHOAfS1+QBOmvmCiiffgjR8ryyEd3KIfvPGFqoADt8LdQ6XpXIvg== dependencies: "@jridgewell/source-map" "^0.3.3" - acorn "^8.8.2" + acorn "^8.14.0" commander "^2.20.0" source-map-support "~0.5.20" @@ -2949,9 +2943,9 @@ tr46@~0.0.3: integrity sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw== ts-jest@^29.1.1: - version "29.2.6" - resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-29.2.6.tgz#df53edf8b72fb89de032cfa310abf37582851d9a" - integrity sha512-yTNZVZqc8lSixm+QGVFcPe6+yj7+TWZwIesuOWvfcn4B9bz5x4NDzVCQQjOs7Hfouu36aEqfEbo9Qpo+gq8dDg== + version "29.3.4" + resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-29.3.4.tgz#9354472aceae1d3867a80e8e02014ea5901aee41" + integrity sha512-Iqbrm8IXOmV+ggWHOTEbjwyCf2xZlUMv5npExksXohL+tk8va4Fjhb+X2+Rt9NBmgO7bJ8WpnMLOwih/DnMlFA== dependencies: bs-logger "^0.2.6" ejs "^3.1.10" @@ -2960,7 +2954,8 @@ ts-jest@^29.1.1: json5 "^2.2.3" lodash.memoize "^4.1.2" make-error "^1.3.6" - semver "^7.7.1" + semver "^7.7.2" + type-fest "^4.41.0" yargs-parser "^21.1.1" ts-loader@^9.5.1: @@ -2984,6 +2979,11 @@ type-fest@^0.21.3: resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.21.3.tgz#d260a24b0198436e133fa26a524a6d65fa3b2e37" integrity sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w== +type-fest@^4.41.0: + version "4.41.0" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-4.41.0.tgz#6ae1c8e5731273c2bf1f58ad39cbae2c91a46c58" + integrity sha512-TeTSQ6H5YHvpqVwBRcnLDCBnDOHWYu7IvGbHT6N8AOymcr9PJGjc1GTtiWZTYg0NCgYwvnYWEkVChQAr9bjfwA== + typescript@~5.7.2: version "5.7.3" resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.7.3.tgz#919b44a7dbb8583a9b856d162be24a54bf80073e" @@ -2994,17 +2994,17 @@ undici-types@~5.26.4: resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-5.26.5.tgz#bcd539893d00b56e964fd2657a4866b221a65617" integrity sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA== -undici-types@~6.20.0: - version "6.20.0" - resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-6.20.0.tgz#8171bf22c1f588d1554d55bf204bc624af388433" - integrity sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg== +undici-types@~6.21.0: + version "6.21.0" + resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-6.21.0.tgz#691d00af3909be93a7faa13be61b3a5b50ef12cb" + integrity sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ== universalify@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.2.0.tgz#6451760566fa857534745ab1dde952d1b1761be0" integrity sha512-CJ1QgKmNg3CwvAv/kOFmtnEN05f0D/cn9QntgNOQlQF9dgvVTHj3t+8JPdjqawCHk7V/KA+fbUqzZ9XWhcqPUg== -update-browserslist-db@^1.1.1: +update-browserslist-db@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/update-browserslist-db/-/update-browserslist-db-1.1.3.tgz#348377dd245216f9e7060ff50b15a1b740b75420" integrity sha512-UxhIZQ+QInVdunkDAaiazvvT/+fXL5Osr0JZlJulepYu6Jd7qJtDZjlur0emRlT71EN3ScPoE7gvsuIKKNavKw== @@ -3049,9 +3049,9 @@ walker@^1.0.8: makeerror "1.0.12" watchpack@^2.4.1: - version "2.4.2" - resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-2.4.2.tgz#2feeaed67412e7c33184e5a79ca738fbd38564da" - integrity sha512-TnbFSbcOCcDgjZ4piURLCbJ3nJhznVh9kw6F6iokjiFPl8ONxe9A6nMDVXDiNbrSfLILs6vB07F7wLBrwPYzJw== + version "2.4.4" + resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-2.4.4.tgz#473bda72f0850453da6425081ea46fc0d7602947" + integrity sha512-c5EGNOiyxxV5qmTtAB7rbiXxi1ooX1pQKMLX/MIabJjRA0SJBQOjKF+KSVfHkr9U1cADPon0mRiVe/riyaiDUA== dependencies: glob-to-regexp "^0.4.1" graceful-fs "^4.1.2" @@ -3072,12 +3072,13 @@ webpack-sources@^3.2.3: integrity sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w== webpack@^5.97.1: - version "5.98.0" - resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.98.0.tgz#44ae19a8f2ba97537978246072fb89d10d1fbd17" - integrity sha512-UFynvx+gM44Gv9qFgj0acCQK2VE1CtdfwFdimkapco3hlPCJ/zeq73n2yVKimVbtm+TnApIugGhLJnkU6gjYXA== + version "5.99.9" + resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.99.9.tgz#d7de799ec17d0cce3c83b70744b4aedb537d8247" + integrity sha512-brOPwM3JnmOa+7kd3NsmOUOwbDAj8FT9xDsG3IW0MgbN9yZV7Oi/s/+MNQ/EcSMqw7qfoRyXPoeEWT8zLVdVGg== dependencies: "@types/eslint-scope" "^3.7.7" "@types/estree" "^1.0.6" + "@types/json-schema" "^7.0.15" "@webassemblyjs/ast" "^1.14.1" "@webassemblyjs/wasm-edit" "^1.14.1" "@webassemblyjs/wasm-parser" "^1.14.1" @@ -3094,7 +3095,7 @@ webpack@^5.97.1: loader-runner "^4.2.0" mime-types "^2.1.27" neo-async "^2.6.2" - schema-utils "^4.3.0" + schema-utils "^4.3.2" tapable "^2.1.1" terser-webpack-plugin "^5.3.11" watchpack "^2.4.1" @@ -3158,9 +3159,9 @@ write-file-atomic@^4.0.2: signal-exit "^3.0.7" ws@^8.11.0: - version "8.18.1" - resolved "https://registry.yarnpkg.com/ws/-/ws-8.18.1.tgz#ea131d3784e1dfdff91adb0a4a116b127515e3cb" - integrity sha512-RKW2aJZMXeMxVpnZ6bck+RswznaxmzdULiBr6KY7XkTnW8uvt0iT9H5DkHUChXrc+uurzwa0rVI16n/Xzjdz1w== + version "8.18.2" + resolved "https://registry.yarnpkg.com/ws/-/ws-8.18.2.tgz#42738b2be57ced85f46154320aabb51ab003705a" + integrity sha512-DMricUmwGZUVr++AEAe2uiVM7UoO9MAVZMDu05UQOaUII0lp+zOzLLU4Xqh/JvTqklB1T4uELaaPBKyjE1r4fQ== xml-name-validator@^4.0.0: version "4.0.0" From 2d61924d3dee9ccf4804740d0a78bc786e864e6d Mon Sep 17 00:00:00 2001 From: Iain Breen <4470039+iainbreen@users.noreply.github.com> Date: Mon, 16 Jun 2025 14:37:59 +0100 Subject: [PATCH 133/146] Add AI-generated PR labeling workflow (#491) --- .github/workflows/label-ai-generated-prs.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 .github/workflows/label-ai-generated-prs.yml diff --git a/.github/workflows/label-ai-generated-prs.yml b/.github/workflows/label-ai-generated-prs.yml new file mode 100644 index 00000000..547cbfec --- /dev/null +++ b/.github/workflows/label-ai-generated-prs.yml @@ -0,0 +1,11 @@ +# .github/workflows/label-ai-generated-prs.yml +name: Label AI-generated PRs + +on: + pull_request: + types: [opened, edited, synchronize] # run when the body changes too + +jobs: + call-label-ai-prs: + uses: intercom/github-action-workflows/.github/workflows/label-ai-prs.yml@main + secrets: inherit \ No newline at end of file From 0dabc5d7b0cd4c8d585447392db598d7a0d65c5f Mon Sep 17 00:00:00 2001 From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com> Date: Wed, 25 Jun 2025 17:55:26 -0400 Subject: [PATCH 134/146] SDK regeneration (#493) Co-authored-by: fern-api <115122769+fern-api[bot]@users.noreply.github.com> --- .github/workflows/label-ai-generated-prs.yml | 11 - README.md | 17 +- package.json | 3 +- reference.md | 9424 ++++++++++++++++- src/Client.ts | 12 +- src/api/errors/BadRequestError.ts | 4 +- src/api/errors/ForbiddenError.ts | 4 +- src/api/errors/NotFoundError.ts | 4 +- src/api/errors/UnauthorizedError.ts | 4 +- src/api/errors/UnprocessableEntityError.ts | 4 +- src/api/resources/admins/client/Client.ts | 116 +- src/api/resources/articles/client/Client.ts | 264 +- src/api/resources/companies/client/Client.ts | 507 +- src/api/resources/contacts/client/Client.ts | 698 +- .../resources/conversations/client/Client.ts | 537 +- .../resources/dataAttributes/client/Client.ts | 83 +- src/api/resources/dataExport/client/Client.ts | 80 +- src/api/resources/events/client/Client.ts | 75 +- .../resources/helpCenters/client/Client.ts | 164 +- .../resources/collections/client/Client.ts | 245 +- src/api/resources/index.ts | 2 +- src/api/resources/messages/client/Client.ts | 31 +- .../news/resources/feeds/client/Client.ts | 72 +- .../news/resources/items/client/Client.ts | 128 +- src/api/resources/notes/client/Client.ts | 181 +- .../phoneCallRedirects/client/Client.ts | 29 +- src/api/resources/segments/client/Client.ts | 52 +- .../subscriptionTypes/client/Client.ts | 24 +- src/api/resources/tags/client/Client.ts | 269 +- src/api/resources/teams/client/Client.ts | 47 +- .../resources/ticketTypes/client/Client.ts | 97 +- .../resources/attributes/client/Client.ts | 50 +- src/api/resources/tickets/client/Client.ts | 208 +- .../tickets/client/requests/index.ts | 1 - src/api/resources/unstable/client/Client.ts | 209 + .../client/index.ts | 0 .../unstable/errors/BadRequestError.ts | 18 + .../unstable/errors/ForbiddenError.ts | 19 + .../unstable/errors/InternalServerError.ts | 19 + .../unstable/errors/NotFoundError.ts | 18 + .../unstable/errors/TooManyRequestsError.ts | 19 + .../unstable/errors/UnauthorizedError.ts | 19 + .../errors/UnprocessableEntityError.ts | 18 + src/api/resources/unstable/errors/index.ts | 7 + src/api/resources/unstable/index.ts | 4 + .../resources/admins/client/Client.ts | 536 + .../unstable/resources/admins/client/index.ts | 1 + .../requests/ListActivityLogsRequest.ts | 21 + .../client/requests/RetrieveAdminRequest.ts | 16 + .../client/requests/SetAwayAdminRequest.ts | 39 + .../resources/admins/client/requests/index.ts | 3 + .../unstable/resources/admins/index.ts | 2 + .../unstable/resources/admins/types/Admin.ts | 34 + .../unstable/resources/admins/types/index.ts | 1 + .../unstable/resources/aiAgent/index.ts | 1 + .../resources/aiAgent/types/AiAgent.ts | 38 + .../unstable/resources/aiAgent/types/index.ts | 1 + .../resources/aiContent/client/Client.ts | 988 ++ .../resources/aiContent/client/index.ts | 1 + .../CreateContentImportSourceRequest.ts | 27 + .../requests/CreateExternalPageRequest.ts | 30 + .../DeleteContentImportSourceRequest.ts | 16 + .../requests/DeleteExternalPageRequest.ts | 16 + .../requests/GetContentImportSourceRequest.ts | 16 + .../client/requests/GetExternalPageRequest.ts | 16 + .../UpdateContentImportSourceRequest.ts | 44 + .../requests/UpdateExternalPageRequest.ts | 33 + .../aiContent/client/requests/index.ts | 8 + .../unstable/resources/aiContent/index.ts | 2 + .../aiContent/types/ContentImportSource.ts | 45 + .../types/ContentImportSourcesList.ts | 18 + .../resources/aiContent/types/ExternalPage.ts | 37 + .../aiContent/types/ExternalPagesList.ts | 18 + .../resources/aiContent/types/index.ts | 4 + .../resources/aiContentSource/index.ts | 1 + .../aiContentSource/types/ContentSource.ts | 31 + .../resources/aiContentSource/types/index.ts | 1 + .../resources/articles/client/Client.ts | 556 + .../resources/articles/client/index.ts | 1 + .../client/requests/DeleteArticleRequest.ts | 16 + .../client/requests/RetrieveArticleRequest.ts | 16 + .../client/requests/SearchArticlesRequest.ts | 29 + .../articles/client/requests/index.ts | 3 + .../unstable/resources/articles/index.ts | 2 + .../resources/articles/types/Article.ts | 12 + .../articles/types/ArticleListItem.ts | 53 + .../articles/types/ArticleSearchHighlights.ts | 67 + .../articles/types/ArticleSearchResponse.ts | 30 + .../resources/articles/types/index.ts | 4 + .../awayStatusReasons/client/Client.ts | 170 + .../awayStatusReasons/client/index.ts | 1 + .../resources/awayStatusReasons}/index.ts | 0 .../resources/companies/client/Client.ts | 1196 +++ .../resources/companies/client/index.ts | 1 + .../AttachContactToACompanyRequest.ts | 31 + .../client/requests/DeleteCompanyRequest.ts | 16 + .../DetachContactFromACompanyRequest.ts | 21 + .../requests/ListAllCompaniesRequest.ts | 24 + .../requests/ListAttachedContactsRequest.ts | 16 + ...ListAttachedSegmentsForCompaniesRequest.ts | 16 + .../requests/RetrieveACompanyByIdRequest.ts | 16 + .../client/requests/RetrieveCompanyRequest.ts | 39 + .../requests/ScrollOverAllCompaniesRequest.ts | 14 + .../client/requests/UpdateCompanyRequest.ts | 16 + .../companies/client/requests/index.ts | 10 + .../unstable/resources/companies/index.ts | 2 + .../resources/companies/types/Company.ts | 77 + .../resources/companies/types/index.ts | 1 + .../resources/contacts/client/Client.ts | 1536 +++ .../resources/contacts/client/index.ts | 1 + .../client/requests/ArchiveContactRequest.ts | 16 + .../client/requests/BlockContactRequest.ts | 16 + .../client/requests/DeleteContactRequest.ts | 16 + .../ListCompaniesForAContactRequest.ts | 16 + .../ListSegmentsForAContactRequest.ts | 16 + .../ListSubscriptionsForAContactRequest.ts | 16 + .../requests/ListTagsForAContactRequest.ts | 16 + .../client/requests/MergeContactsRequest.ts | 17 + .../ShowContactByExternalIdRequest.ts | 16 + .../client/requests/ShowContactRequest.ts | 16 + .../requests/UnarchiveContactRequest.ts | 16 + .../client/requests/UpdateContactRequest.ts | 50 + .../contacts/client/requests/index.ts | 12 + .../unstable/resources/contacts/index.ts | 2 + .../resources/contacts/types/Contact.ts | 106 + .../contacts/types/CreateContactResponse.ts | 10 + .../contacts/types/MergeContactResponse.ts | 10 + .../types/ShowContactByExternalIdResponse.ts | 10 + .../contacts/types/ShowContactResponse.ts | 10 + .../contacts/types/UpdateContactResponse.ts | 10 + .../resources/contacts/types/index.ts | 6 + .../resources/conversations/client/Client.ts | 1553 +++ .../resources/conversations/client/index.ts | 1 + .../AttachContactToConversationRequest.ts | 50 + .../ConvertConversationToTicketRequest.ts | 28 + .../requests/CreateConversationRequest.ts | 51 + .../requests/DeleteConversationRequest.ts | 16 + .../DetachContactFromConversationRequest.ts | 45 + .../requests/ListConversationsRequest.ts | 18 + .../requests/ManageConversationRequest.ts | 64 + .../requests/ReplyConversationRequest.ts | 79 + .../requests/RetrieveConversationRequest.ts | 21 + .../requests/UpdateConversationRequest.ts | 55 + .../conversations/client/requests/index.ts | 10 + .../unstable/resources/conversations/index.ts | 2 + .../conversations/types/Conversation.ts | 71 + .../types/ManageConversationRequestBody.ts | 29 + .../resources/conversations/types/index.ts | 2 + .../customChannelEvents/client/Client.ts | 540 + .../customChannelEvents/client/index.ts | 1 + .../NotifyAttributeCollectedRequest.ts | 26 + .../requests/NotifyNewMessageRequest.ts | 24 + .../NotifyQuickReplySelectedRequest.ts | 24 + .../client/requests/index.ts | 3 + .../resources/customChannelEvents/index.ts | 1 + .../customObjectInstances/client/Client.ts | 589 ++ .../customObjectInstances/client/index.ts | 1 + ...eateOrUpdateCustomObjectInstanceRequest.ts | 31 + ...ustomObjectInstancesByExternalIdRequest.ts | 21 + .../DeleteCustomObjectInstancesByIdRequest.ts | 18 + ...ustomObjectInstancesByExternalIdRequest.ts | 18 + .../GetCustomObjectInstancesByIdRequest.ts | 21 + .../client/requests/index.ts | 5 + .../resources/customObjectInstances/index.ts | 2 + .../types/CustomObjectInstance.ts | 25 + .../customObjectInstances/types/index.ts | 1 + .../resources/dataAttributes/client/Client.ts | 436 + .../resources/dataAttributes/client/index.ts | 1 + .../requests/CreateDataAttributeRequest.ts | 86 + .../requests/LisDataAttributesRequest.ts | 20 + .../requests/UpdateDataAttributeRequest.ts | 50 + .../dataAttributes/client/requests/index.ts | 3 + .../resources/dataAttributes/index.ts | 2 + .../dataAttributes/types/DataAttribute.ts | 65 + .../types/LisDataAttributesRequestModel.ts | 10 + .../resources/dataAttributes/types/index.ts | 2 + .../resources/dataEvents/client/Client.ts | 413 + .../resources/dataEvents/client/index.ts | 1 + .../CreateDataEventSummariesRequest.ts | 30 + .../client/requests/LisDataEventsRequest.ts | 26 + .../dataEvents/client/requests/index.ts | 2 + .../unstable/resources/dataEvents/index.ts | 2 + .../resources/dataEvents/types/DataEvent.ts | 25 + .../types/LisDataEventsRequestFilter.ts | 14 + .../resources/dataEvents/types/index.ts | 2 + .../resources/dataExport}/client/Client.ts | 187 +- .../resources/dataExport/client/index.ts | 1 + .../requests/CancelDataExportRequest.ts | 16 + .../requests/CreateDataExportsRequest.ts | 17 + .../requests/DownloadDataExportRequest.ts | 16 + .../client/requests/GetDataExportRequest.ts | 16 + .../dataExport/client/requests/index.ts | 4 + .../unstable/resources/dataExport/index.ts | 2 + .../resources/dataExport/types/DataExport.ts | 32 + .../resources/dataExport/types/index.ts | 1 + .../resources/export/client/Client.ts | 262 + .../unstable/resources/export/client/index.ts | 1 + .../PostExportReportingDataEnqueueRequest.ts | 19 + .../resources/export/client/requests/index.ts | 1 + .../unstable/resources/export/index.ts | 2 + ...tExportReportingDataGetDatasetsResponse.ts | 33 + .../PostExportReportingDataEnqueueResponse.ts | 10 + .../unstable/resources/export/types/index.ts | 2 + .../resources/helpCenter/client/Client.ts | 722 ++ .../resources/helpCenter/client/index.ts | 1 + .../requests/CreateCollectionRequest.ts | 29 + .../requests/DeleteCollectionRequest.ts | 16 + .../requests/RetrieveCollectionRequest.ts | 16 + .../requests/RetrieveHelpCenterRequest.ts | 16 + .../requests/UpdateCollectionRequest.ts | 32 + .../helpCenter/client/requests/index.ts | 5 + .../unstable/resources/helpCenter/index.ts | 2 + .../resources/helpCenter/types/Collection.ts | 36 + .../resources/helpCenter/types/HelpCenter.ts | 23 + .../helpCenter/types/HelpCenterList.ts | 15 + .../resources/helpCenter/types/index.ts | 3 + src/api/resources/unstable/resources/index.ts | 78 + .../unstable/resources/jobs/client/Client.ts | 179 + .../unstable/resources/jobs/client/index.ts | 1 + .../jobs/client/requests/JobsStatusRequest.ts | 16 + .../resources/jobs/client/requests/index.ts | 1 + .../unstable/resources/jobs/index.ts | 2 + .../unstable/resources/jobs/types/Jobs.ts | 35 + .../unstable/resources/jobs/types/index.ts | 1 + .../resources/messages/client/Client.ts | 446 + .../resources/messages/client/index.ts | 1 + .../GetWhatsAppMessageStatusRequest.ts | 24 + .../messages/client/requests/index.ts | 1 + .../unstable/resources/messages/index.ts | 2 + .../resources/messages/types/Message.ts | 37 + .../resources/messages/types/index.ts | 1 + .../unstable/resources/news/client/Client.ts | 808 ++ .../unstable/resources/news/client/index.ts | 1 + .../client/requests/DeleteNewsItemRequest.ts | 16 + .../requests/ListLiveNewsfeedItemsRequest.ts | 16 + .../requests/RetrieveNewsItemRequest.ts | 16 + .../requests/RetrieveNewsfeedRequest.ts | 16 + .../client/requests/UpdateNewsItemRequest.ts | 36 + .../resources/news/client/requests/index.ts | 5 + .../unstable/resources/news/index.ts | 2 + .../unstable/resources/news/types/NewsItem.ts | 48 + .../unstable/resources/news/types/Newsfeed.ts | 19 + .../news/types/NewsfeedAssignment.ts | 13 + .../unstable/resources/news/types/index.ts | 3 + .../unstable/resources/notes/client/Client.ts | 367 + .../unstable/resources/notes/client/index.ts | 1 + .../client/requests/CreateNoteRequest.ts | 41 + .../notes/client/requests/ListNotesRequest.ts | 16 + .../client/requests/RetrieveNoteRequest.ts | 16 + .../resources/notes/client/requests/index.ts | 3 + .../unstable/resources/notes/index.ts | 2 + .../unstable/resources/notes/types/Note.ts | 35 + .../unstable/resources/notes/types/index.ts | 1 + .../resources/segments/client/Client.ts | 270 + .../resources/segments/client/index.ts | 1 + .../client/requests/ListSegmentsRequest.ts | 14 + .../client/requests/RetrieveSegmentRequest.ts | 16 + .../segments/client/requests/index.ts | 2 + .../unstable/resources/segments/index.ts | 2 + .../resources/segments/types/Segment.ts | 34 + .../resources/segments/types/index.ts | 1 + .../subscriptionTypes/client/Client.ts | 374 + .../subscriptionTypes/client/index.ts | 1 + .../AttachSubscriptionTypeToContactRequest.ts | 36 + .../DetachSubscriptionTypeToContactRequest.ts | 21 + .../client/requests/index.ts | 2 + .../resources/subscriptionTypes/index.ts | 2 + .../types/SubscriptionType.ts | 53 + .../subscriptionTypes/types/index.ts | 1 + .../resources/switch/client/Client.ts | 191 + .../unstable/resources/switch/client/index.ts | 1 + .../unstable/resources/switch/index.ts | 1 + .../unstable/resources/tags/client/Client.ts | 1049 ++ .../unstable/resources/tags/client/index.ts | 1 + .../requests/AttachTagToContactRequest.ts | 31 + .../AttachTagToConversationRequest.ts | 29 + .../requests/AttachTagToTicketRequest.ts | 29 + .../tags/client/requests/DeleteTagRequest.ts | 16 + .../requests/DetachTagFromContactRequest.ts | 21 + .../DetachTagFromConversationRequest.ts | 38 + .../requests/DetachTagFromTicketRequest.ts | 38 + .../tags/client/requests/FindTagRequest.ts | 16 + .../resources/tags/client/requests/index.ts | 8 + .../unstable/resources/tags/index.ts | 2 + .../tags/types/CreateTagRequestBody.ts | 11 + .../unstable/resources/tags/types/Tag.ts | 20 + .../unstable/resources/tags/types/TagBasic.ts | 15 + .../unstable/resources/tags/types/index.ts | 3 + .../unstable/resources/teams/client/Client.ts | 258 + .../unstable/resources/teams/client/index.ts | 1 + .../client/requests/RetrieveTeamRequest.ts | 16 + .../resources/teams/client/requests/index.ts | 1 + .../unstable/resources/teams/index.ts | 2 + .../unstable/resources/teams/types/Team.ts | 20 + .../unstable/resources/teams/types/index.ts | 1 + .../resources/ticketStates/client/Client.ts | 170 + .../resources/ticketStates/client/index.ts | 1 + .../unstable/resources/ticketStates/index.ts | 1 + .../ticketTypeAttributes/client/Client.ts | 281 + .../ticketTypeAttributes/client/index.ts | 1 + .../CreateTicketTypeAttributeRequest.ts | 56 + .../UpdateTicketTypeAttributeRequest.ts | 42 + .../client/requests/index.ts | 2 + .../resources/ticketTypeAttributes/index.ts | 1 + .../resources/ticketTypes/client/Client.ts | 354 + .../resources/ticketTypes/client/index.ts | 1 + .../client/requests/GetTicketTypeRequest.ts | 16 + .../ticketTypes/client/requests/index.ts | 1 + .../unstable/resources/ticketTypes/index.ts | 1 + .../resources/tickets/client/Client.ts | 770 ++ .../resources/tickets/client/index.ts | 1 + .../client/requests/DeleteTicketRequest.ts | 16 + .../requests/EnqueueCreateTicketRequest.ts | 19 + .../client/requests/GetTicketRequest.ts | 16 + .../client/requests/ReplyTicketRequest.ts | 61 + .../client/requests/UpdateTicketRequest.ts | 71 + .../tickets/client/requests/index.ts | 5 + .../unstable/resources/tickets/index.ts | 2 + .../tickets/types/DeleteTicketResponse.ts | 15 + .../tickets/types/ReplyTicketRequestBody.ts | 9 + .../resources/tickets/types/Ticket.ts | 51 + .../resources/tickets/types/TicketContacts.ts | 15 + .../resources/tickets/types/TicketPart.ts | 115 + .../resources/tickets/types/TicketState.ts | 32 + .../tickets/types/TicketStateDetailed.ts | 48 + .../resources/tickets/types/TicketType.ts | 56 + .../unstable/resources/tickets/types/index.ts | 8 + .../resources/visitors/client/Client.ts | 386 + .../resources/visitors/client/index.ts | 1 + .../client/requests/ConvertVisitorRequest.ts | 22 + .../RetrieveVisitorWithUserIdRequest.ts | 16 + .../visitors/client/requests/index.ts | 2 + .../unstable/resources/visitors/index.ts | 1 + .../resources/unstable/types/ActivityLog.ts | 175 + .../unstable/types/ActivityLogList.ts | 16 + .../unstable/types/ActivityLogMetadata.ts | 27 + .../unstable/types/AddressableList.ts | 15 + src/api/resources/unstable/types/AdminList.ts | 15 + .../unstable/types/AdminPriorityLevel.ts | 13 + .../types/AdminReplyConversationRequest.ts | 34 + .../unstable/types/AdminReplyTicketRequest.ts | 40 + .../resources/unstable/types/AdminWithApp.ts | 47 + src/api/resources/unstable/types/App.ts | 23 + .../unstable/types/ArticleContent.ts | 38 + .../resources/unstable/types/ArticleList.ts | 18 + .../unstable/types/ArticleStatistics.ts | 23 + .../types/ArticleTranslatedContent.ts | 87 + .../types/AssignConversationRequest.ts | 24 + .../unstable/types/AwayStatusReason.ts | 21 + .../types/CloseConversationRequest.ts | 14 + .../unstable/types/CollectionList.ts | 18 + .../unstable/types/CompanyAttachedContacts.ts | 18 + .../unstable/types/CompanyAttachedSegments.ts | 15 + .../resources/unstable/types/CompanyData.ts | 15 + .../resources/unstable/types/CompanyList.ts | 18 + .../resources/unstable/types/CompanyScroll.ts | 19 + .../unstable/types/ContactArchived.ts | 13 + .../types/ContactAttachedCompanies.ts | 18 + .../unstable/types/ContactBlocked.ts | 13 + .../unstable/types/ContactCompanies.ts | 19 + .../unstable/types/ContactDeleted.ts | 13 + .../resources/unstable/types/ContactList.ts | 18 + .../unstable/types/ContactLocation.ts | 17 + .../resources/unstable/types/ContactNotes.ts | 19 + .../unstable/types/ContactReference.ts | 15 + .../unstable/types/ContactReplyBaseRequest.ts | 29 + .../types/ContactReplyConversationRequest.ts | 10 + .../types/ContactReplyEmailRequest.ts | 15 + .../ContactReplyIntercomUserIdRequest.ts | 15 + .../types/ContactReplyTicketEmailRequest.ts | 13 + ...ContactReplyTicketIntercomUserIdRequest.ts | 13 + .../types/ContactReplyTicketRequest.ts | 10 + .../types/ContactReplyTicketUserIdRequest.ts | 13 + .../types/ContactReplyUserIdRequest.ts | 15 + .../unstable/types/ContactSegments.ts | 15 + .../unstable/types/ContactSocialProfiles.ts | 13 + .../types/ContactSubscriptionTypes.ts | 19 + .../resources/unstable/types/ContactTags.ts | 19 + .../unstable/types/ContactUnarchived.ts | 13 + .../unstable/types/ContentSourcesList.ts | 13 + .../types/ConversationAttachmentFiles.ts | 15 + .../ConversationAttributeUpdatedByAdmin.ts | 23 + .../ConversationAttributeUpdatedByWorkflow.ts | 29 + .../unstable/types/ConversationContacts.ts | 15 + .../unstable/types/ConversationDeleted.ts | 15 + .../types/ConversationFirstContactReply.ts | 15 + .../unstable/types/ConversationList.ts | 18 + .../unstable/types/ConversationPart.ts | 55 + .../unstable/types/ConversationPartAuthor.ts | 21 + .../types/ConversationPartMetadata.ts | 26 + .../unstable/types/ConversationParts.ts | 17 + .../unstable/types/ConversationRating.ts | 19 + .../types/ConversationResponseTime.ts | 15 + .../unstable/types/ConversationSource.ts | 57 + .../unstable/types/ConversationStatistics.ts | 55 + .../unstable/types/ConversationTeammates.ts | 15 + .../types/CreateOrUpdateTagRequest.ts | 13 + .../CreateTicketReplyWithCommentRequest.ts | 9 + .../unstable/types/CreateTicketRequestBody.ts | 50 + .../resources/unstable/types/CursorPages.ts | 21 + .../unstable/types/CustomActionFinished.ts | 30 + .../unstable/types/CustomActionStarted.ts | 17 + .../unstable/types/CustomAttributes.ts | 14 + .../unstable/types/CustomChannelAttribute.ts | 10 + .../unstable/types/CustomChannelBaseEvent.ts | 13 + .../unstable/types/CustomChannelContact.ts | 25 + .../CustomChannelNotificationResponse.ts | 14 + .../types/CustomObjectInstanceDeleted.ts | 15 + .../types/CustomObjectInstanceList.ts | 14 + .../unstable/types/CustomerRequest.ts | 14 + .../unstable/types/DataAttributeList.ts | 15 + .../resources/unstable/types/DataEventList.ts | 27 + .../unstable/types/DataEventSummary.ts | 21 + .../unstable/types/DataEventSummaryItem.ts | 19 + .../resources/unstable/types/DataExportCsv.ts | 61 + src/api/resources/unstable/types/Datetime.ts | 11 + .../unstable/types/DeletedArticleObject.ts | 15 + .../unstable/types/DeletedCollectionObject.ts | 15 + .../unstable/types/DeletedCompanyObject.ts | 15 + .../resources/unstable/types/DeletedObject.ts | 15 + .../unstable/types/EmailAddressHeader.ts | 15 + .../unstable/types/EmailMessageMetadata.ts | 15 + src/api/resources/unstable/types/Error_.ts | 30 + .../resources/unstable/types/EventDetails.ts | 12 + .../resources/unstable/types/FileAttribute.ts | 22 + .../resources/unstable/types/GroupContent.ts | 15 + .../unstable/types/GroupTranslatedContent.ts | 87 + .../unstable/types/IntercomVersion.ts | 46 + .../unstable/types/IntercomVersionUnstable.ts | 8 + .../resources/unstable/types/LinkedObject.ts | 26 + .../unstable/types/LinkedObjectList.ts | 19 + .../types/MultipleFilterSearchRequest.ts | 32 + .../unstable/types/NewsItemRequest.ts | 38 + .../unstable/types/NotFoundErrorBody.ts | 25 + src/api/resources/unstable/types/NoteList.ts | 18 + .../unstable/types/OpenConversationRequest.ts | 11 + .../unstable/types/OperatorWorkflowEvent.ts | 25 + src/api/resources/unstable/types/PagesLink.ts | 17 + .../unstable/types/PaginatedResponse.ts | 29 + .../types/PaginatedResponseDataItem.ts | 19 + .../unstable/types/PartAttachment.ts | 23 + .../resources/unstable/types/PhoneSwitch.ts | 13 + .../unstable/types/QuickReplyOption.ts | 10 + src/api/resources/unstable/types/Recipient.ts | 24 + .../types/RedactConversationRequest.ts | 31 + src/api/resources/unstable/types/Reference.ts | 13 + .../types/ReplyConversationRequestBody.ts | 9 + .../resources/unstable/types/SearchRequest.ts | 17 + .../resources/unstable/types/SegmentList.ts | 17 + .../types/SingleFilterSearchRequest.ts | 34 + .../resources/unstable/types/SlaApplied.ts | 37 + .../types/SnoozeConversationRequest.ts | 13 + .../resources/unstable/types/SocialProfile.ts | 15 + .../unstable/types/StartingAfterPaging.ts | 10 + .../unstable/types/SubscriptionTypeList.ts | 15 + .../unstable/types/TagCompanyRequest.ts | 26 + src/api/resources/unstable/types/TagList.ts | 15 + .../unstable/types/TagMultipleUsersRequest.ts | 23 + src/api/resources/unstable/types/Tags.ts | 15 + src/api/resources/unstable/types/TeamList.ts | 15 + .../unstable/types/TeamPriorityLevel.ts | 13 + .../unstable/types/TicketCustomAttributes.ts | 14 + .../resources/unstable/types/TicketList.ts | 18 + .../unstable/types/TicketPartAuthor.ts | 30 + .../resources/unstable/types/TicketParts.ts | 17 + .../resources/unstable/types/TicketReply.ts | 40 + .../types/TicketRequestCustomAttributes.ts | 12 + .../unstable/types/TicketStateList.ts | 15 + .../unstable/types/TicketTypeAttribute.ts | 43 + .../unstable/types/TicketTypeAttributeList.ts | 15 + .../unstable/types/TicketTypeList.ts | 15 + .../resources/unstable/types/Translation.ts | 15 + .../unstable/types/UntagCompanyRequest.ts | 28 + .../types/UpdateArticleRequestBody.ts | 37 + .../types/UpdateTicketTypeRequestBody.ts | 34 + src/api/resources/unstable/types/Visitor.ts | 138 + .../unstable/types/VisitorDeletedObject.ts | 15 + .../types/WhatsappMessageStatusList.ts | 71 + src/api/resources/unstable/types/index.ts | 145 + src/api/resources/visitors/client/Client.ts | 79 +- src/api/types/CreateContactRequestTwo.ts | 5 + src/api/types/CreateDataEventRequestTwo.ts | 5 + src/api/types/CreateMessageRequestTwo.ts | 5 + .../requests => types}/CreateTicketRequest.ts | 14 +- src/api/types/Metadata.ts | 7 + src/api/types/UpdateVisitorRequestOne.ts | 5 + src/api/types/index.ts | 6 + src/core/fetcher/APIResponse.ts | 11 + src/core/fetcher/Fetcher.ts | 7 + src/core/fetcher/Headers.ts | 93 + src/core/fetcher/HttpResponsePromise.ts | 116 + src/core/fetcher/RawResponse.ts | 61 + src/core/fetcher/index.ts | 3 + src/core/index.ts | 2 +- src/core/pagination/Page.ts | 14 +- src/core/pagination/Pageable.ts | 2 + src/errors/IntercomError.ts | 30 +- src/version.ts | 2 +- .../unit/fetcher/HttpResponsePromise.test.ts | 143 + tests/unit/fetcher/RawResponse.test.ts | 34 + .../fetcher/stream-wrappers/webpack.test.ts | 2 +- yarn.lock | 224 +- 502 files changed, 36777 insertions(+), 1711 deletions(-) delete mode 100644 .github/workflows/label-ai-generated-prs.yml create mode 100644 src/api/resources/unstable/client/Client.ts rename src/api/resources/{customChannelEvents => unstable}/client/index.ts (100%) create mode 100644 src/api/resources/unstable/errors/BadRequestError.ts create mode 100644 src/api/resources/unstable/errors/ForbiddenError.ts create mode 100644 src/api/resources/unstable/errors/InternalServerError.ts create mode 100644 src/api/resources/unstable/errors/NotFoundError.ts create mode 100644 src/api/resources/unstable/errors/TooManyRequestsError.ts create mode 100644 src/api/resources/unstable/errors/UnauthorizedError.ts create mode 100644 src/api/resources/unstable/errors/UnprocessableEntityError.ts create mode 100644 src/api/resources/unstable/errors/index.ts create mode 100644 src/api/resources/unstable/index.ts create mode 100644 src/api/resources/unstable/resources/admins/client/Client.ts create mode 100644 src/api/resources/unstable/resources/admins/client/index.ts create mode 100644 src/api/resources/unstable/resources/admins/client/requests/ListActivityLogsRequest.ts create mode 100644 src/api/resources/unstable/resources/admins/client/requests/RetrieveAdminRequest.ts create mode 100644 src/api/resources/unstable/resources/admins/client/requests/SetAwayAdminRequest.ts create mode 100644 src/api/resources/unstable/resources/admins/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/admins/index.ts create mode 100644 src/api/resources/unstable/resources/admins/types/Admin.ts create mode 100644 src/api/resources/unstable/resources/admins/types/index.ts create mode 100644 src/api/resources/unstable/resources/aiAgent/index.ts create mode 100644 src/api/resources/unstable/resources/aiAgent/types/AiAgent.ts create mode 100644 src/api/resources/unstable/resources/aiAgent/types/index.ts create mode 100644 src/api/resources/unstable/resources/aiContent/client/Client.ts create mode 100644 src/api/resources/unstable/resources/aiContent/client/index.ts create mode 100644 src/api/resources/unstable/resources/aiContent/client/requests/CreateContentImportSourceRequest.ts create mode 100644 src/api/resources/unstable/resources/aiContent/client/requests/CreateExternalPageRequest.ts create mode 100644 src/api/resources/unstable/resources/aiContent/client/requests/DeleteContentImportSourceRequest.ts create mode 100644 src/api/resources/unstable/resources/aiContent/client/requests/DeleteExternalPageRequest.ts create mode 100644 src/api/resources/unstable/resources/aiContent/client/requests/GetContentImportSourceRequest.ts create mode 100644 src/api/resources/unstable/resources/aiContent/client/requests/GetExternalPageRequest.ts create mode 100644 src/api/resources/unstable/resources/aiContent/client/requests/UpdateContentImportSourceRequest.ts create mode 100644 src/api/resources/unstable/resources/aiContent/client/requests/UpdateExternalPageRequest.ts create mode 100644 src/api/resources/unstable/resources/aiContent/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/aiContent/index.ts create mode 100644 src/api/resources/unstable/resources/aiContent/types/ContentImportSource.ts create mode 100644 src/api/resources/unstable/resources/aiContent/types/ContentImportSourcesList.ts create mode 100644 src/api/resources/unstable/resources/aiContent/types/ExternalPage.ts create mode 100644 src/api/resources/unstable/resources/aiContent/types/ExternalPagesList.ts create mode 100644 src/api/resources/unstable/resources/aiContent/types/index.ts create mode 100644 src/api/resources/unstable/resources/aiContentSource/index.ts create mode 100644 src/api/resources/unstable/resources/aiContentSource/types/ContentSource.ts create mode 100644 src/api/resources/unstable/resources/aiContentSource/types/index.ts create mode 100644 src/api/resources/unstable/resources/articles/client/Client.ts create mode 100644 src/api/resources/unstable/resources/articles/client/index.ts create mode 100644 src/api/resources/unstable/resources/articles/client/requests/DeleteArticleRequest.ts create mode 100644 src/api/resources/unstable/resources/articles/client/requests/RetrieveArticleRequest.ts create mode 100644 src/api/resources/unstable/resources/articles/client/requests/SearchArticlesRequest.ts create mode 100644 src/api/resources/unstable/resources/articles/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/articles/index.ts create mode 100644 src/api/resources/unstable/resources/articles/types/Article.ts create mode 100644 src/api/resources/unstable/resources/articles/types/ArticleListItem.ts create mode 100644 src/api/resources/unstable/resources/articles/types/ArticleSearchHighlights.ts create mode 100644 src/api/resources/unstable/resources/articles/types/ArticleSearchResponse.ts create mode 100644 src/api/resources/unstable/resources/articles/types/index.ts create mode 100644 src/api/resources/unstable/resources/awayStatusReasons/client/Client.ts create mode 100644 src/api/resources/unstable/resources/awayStatusReasons/client/index.ts rename src/api/resources/{customChannelEvents => unstable/resources/awayStatusReasons}/index.ts (100%) create mode 100644 src/api/resources/unstable/resources/companies/client/Client.ts create mode 100644 src/api/resources/unstable/resources/companies/client/index.ts create mode 100644 src/api/resources/unstable/resources/companies/client/requests/AttachContactToACompanyRequest.ts create mode 100644 src/api/resources/unstable/resources/companies/client/requests/DeleteCompanyRequest.ts create mode 100644 src/api/resources/unstable/resources/companies/client/requests/DetachContactFromACompanyRequest.ts create mode 100644 src/api/resources/unstable/resources/companies/client/requests/ListAllCompaniesRequest.ts create mode 100644 src/api/resources/unstable/resources/companies/client/requests/ListAttachedContactsRequest.ts create mode 100644 src/api/resources/unstable/resources/companies/client/requests/ListAttachedSegmentsForCompaniesRequest.ts create mode 100644 src/api/resources/unstable/resources/companies/client/requests/RetrieveACompanyByIdRequest.ts create mode 100644 src/api/resources/unstable/resources/companies/client/requests/RetrieveCompanyRequest.ts create mode 100644 src/api/resources/unstable/resources/companies/client/requests/ScrollOverAllCompaniesRequest.ts create mode 100644 src/api/resources/unstable/resources/companies/client/requests/UpdateCompanyRequest.ts create mode 100644 src/api/resources/unstable/resources/companies/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/companies/index.ts create mode 100644 src/api/resources/unstable/resources/companies/types/Company.ts create mode 100644 src/api/resources/unstable/resources/companies/types/index.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/Client.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/index.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/requests/ArchiveContactRequest.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/requests/BlockContactRequest.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/requests/DeleteContactRequest.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/requests/ListCompaniesForAContactRequest.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/requests/ListSegmentsForAContactRequest.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/requests/ListSubscriptionsForAContactRequest.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/requests/ListTagsForAContactRequest.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/requests/MergeContactsRequest.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/requests/ShowContactByExternalIdRequest.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/requests/ShowContactRequest.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/requests/UnarchiveContactRequest.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/requests/UpdateContactRequest.ts create mode 100644 src/api/resources/unstable/resources/contacts/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/contacts/index.ts create mode 100644 src/api/resources/unstable/resources/contacts/types/Contact.ts create mode 100644 src/api/resources/unstable/resources/contacts/types/CreateContactResponse.ts create mode 100644 src/api/resources/unstable/resources/contacts/types/MergeContactResponse.ts create mode 100644 src/api/resources/unstable/resources/contacts/types/ShowContactByExternalIdResponse.ts create mode 100644 src/api/resources/unstable/resources/contacts/types/ShowContactResponse.ts create mode 100644 src/api/resources/unstable/resources/contacts/types/UpdateContactResponse.ts create mode 100644 src/api/resources/unstable/resources/contacts/types/index.ts create mode 100644 src/api/resources/unstable/resources/conversations/client/Client.ts create mode 100644 src/api/resources/unstable/resources/conversations/client/index.ts create mode 100644 src/api/resources/unstable/resources/conversations/client/requests/AttachContactToConversationRequest.ts create mode 100644 src/api/resources/unstable/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts create mode 100644 src/api/resources/unstable/resources/conversations/client/requests/CreateConversationRequest.ts create mode 100644 src/api/resources/unstable/resources/conversations/client/requests/DeleteConversationRequest.ts create mode 100644 src/api/resources/unstable/resources/conversations/client/requests/DetachContactFromConversationRequest.ts create mode 100644 src/api/resources/unstable/resources/conversations/client/requests/ListConversationsRequest.ts create mode 100644 src/api/resources/unstable/resources/conversations/client/requests/ManageConversationRequest.ts create mode 100644 src/api/resources/unstable/resources/conversations/client/requests/ReplyConversationRequest.ts create mode 100644 src/api/resources/unstable/resources/conversations/client/requests/RetrieveConversationRequest.ts create mode 100644 src/api/resources/unstable/resources/conversations/client/requests/UpdateConversationRequest.ts create mode 100644 src/api/resources/unstable/resources/conversations/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/conversations/index.ts create mode 100644 src/api/resources/unstable/resources/conversations/types/Conversation.ts create mode 100644 src/api/resources/unstable/resources/conversations/types/ManageConversationRequestBody.ts create mode 100644 src/api/resources/unstable/resources/conversations/types/index.ts create mode 100644 src/api/resources/unstable/resources/customChannelEvents/client/Client.ts create mode 100644 src/api/resources/unstable/resources/customChannelEvents/client/index.ts create mode 100644 src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyAttributeCollectedRequest.ts create mode 100644 src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyNewMessageRequest.ts create mode 100644 src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyQuickReplySelectedRequest.ts create mode 100644 src/api/resources/unstable/resources/customChannelEvents/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/customChannelEvents/index.ts create mode 100644 src/api/resources/unstable/resources/customObjectInstances/client/Client.ts create mode 100644 src/api/resources/unstable/resources/customObjectInstances/client/index.ts create mode 100644 src/api/resources/unstable/resources/customObjectInstances/client/requests/CreateOrUpdateCustomObjectInstanceRequest.ts create mode 100644 src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByExternalIdRequest.ts create mode 100644 src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByIdRequest.ts create mode 100644 src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByExternalIdRequest.ts create mode 100644 src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByIdRequest.ts create mode 100644 src/api/resources/unstable/resources/customObjectInstances/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/customObjectInstances/index.ts create mode 100644 src/api/resources/unstable/resources/customObjectInstances/types/CustomObjectInstance.ts create mode 100644 src/api/resources/unstable/resources/customObjectInstances/types/index.ts create mode 100644 src/api/resources/unstable/resources/dataAttributes/client/Client.ts create mode 100644 src/api/resources/unstable/resources/dataAttributes/client/index.ts create mode 100644 src/api/resources/unstable/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts create mode 100644 src/api/resources/unstable/resources/dataAttributes/client/requests/LisDataAttributesRequest.ts create mode 100644 src/api/resources/unstable/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts create mode 100644 src/api/resources/unstable/resources/dataAttributes/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/dataAttributes/index.ts create mode 100644 src/api/resources/unstable/resources/dataAttributes/types/DataAttribute.ts create mode 100644 src/api/resources/unstable/resources/dataAttributes/types/LisDataAttributesRequestModel.ts create mode 100644 src/api/resources/unstable/resources/dataAttributes/types/index.ts create mode 100644 src/api/resources/unstable/resources/dataEvents/client/Client.ts create mode 100644 src/api/resources/unstable/resources/dataEvents/client/index.ts create mode 100644 src/api/resources/unstable/resources/dataEvents/client/requests/CreateDataEventSummariesRequest.ts create mode 100644 src/api/resources/unstable/resources/dataEvents/client/requests/LisDataEventsRequest.ts create mode 100644 src/api/resources/unstable/resources/dataEvents/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/dataEvents/index.ts create mode 100644 src/api/resources/unstable/resources/dataEvents/types/DataEvent.ts create mode 100644 src/api/resources/unstable/resources/dataEvents/types/LisDataEventsRequestFilter.ts create mode 100644 src/api/resources/unstable/resources/dataEvents/types/index.ts rename src/api/resources/{customChannelEvents => unstable/resources/dataExport}/client/Client.ts (54%) create mode 100644 src/api/resources/unstable/resources/dataExport/client/index.ts create mode 100644 src/api/resources/unstable/resources/dataExport/client/requests/CancelDataExportRequest.ts create mode 100644 src/api/resources/unstable/resources/dataExport/client/requests/CreateDataExportsRequest.ts create mode 100644 src/api/resources/unstable/resources/dataExport/client/requests/DownloadDataExportRequest.ts create mode 100644 src/api/resources/unstable/resources/dataExport/client/requests/GetDataExportRequest.ts create mode 100644 src/api/resources/unstable/resources/dataExport/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/dataExport/index.ts create mode 100644 src/api/resources/unstable/resources/dataExport/types/DataExport.ts create mode 100644 src/api/resources/unstable/resources/dataExport/types/index.ts create mode 100644 src/api/resources/unstable/resources/export/client/Client.ts create mode 100644 src/api/resources/unstable/resources/export/client/index.ts create mode 100644 src/api/resources/unstable/resources/export/client/requests/PostExportReportingDataEnqueueRequest.ts create mode 100644 src/api/resources/unstable/resources/export/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/export/index.ts create mode 100644 src/api/resources/unstable/resources/export/types/GetExportReportingDataGetDatasetsResponse.ts create mode 100644 src/api/resources/unstable/resources/export/types/PostExportReportingDataEnqueueResponse.ts create mode 100644 src/api/resources/unstable/resources/export/types/index.ts create mode 100644 src/api/resources/unstable/resources/helpCenter/client/Client.ts create mode 100644 src/api/resources/unstable/resources/helpCenter/client/index.ts create mode 100644 src/api/resources/unstable/resources/helpCenter/client/requests/CreateCollectionRequest.ts create mode 100644 src/api/resources/unstable/resources/helpCenter/client/requests/DeleteCollectionRequest.ts create mode 100644 src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveCollectionRequest.ts create mode 100644 src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveHelpCenterRequest.ts create mode 100644 src/api/resources/unstable/resources/helpCenter/client/requests/UpdateCollectionRequest.ts create mode 100644 src/api/resources/unstable/resources/helpCenter/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/helpCenter/index.ts create mode 100644 src/api/resources/unstable/resources/helpCenter/types/Collection.ts create mode 100644 src/api/resources/unstable/resources/helpCenter/types/HelpCenter.ts create mode 100644 src/api/resources/unstable/resources/helpCenter/types/HelpCenterList.ts create mode 100644 src/api/resources/unstable/resources/helpCenter/types/index.ts create mode 100644 src/api/resources/unstable/resources/index.ts create mode 100644 src/api/resources/unstable/resources/jobs/client/Client.ts create mode 100644 src/api/resources/unstable/resources/jobs/client/index.ts create mode 100644 src/api/resources/unstable/resources/jobs/client/requests/JobsStatusRequest.ts create mode 100644 src/api/resources/unstable/resources/jobs/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/jobs/index.ts create mode 100644 src/api/resources/unstable/resources/jobs/types/Jobs.ts create mode 100644 src/api/resources/unstable/resources/jobs/types/index.ts create mode 100644 src/api/resources/unstable/resources/messages/client/Client.ts create mode 100644 src/api/resources/unstable/resources/messages/client/index.ts create mode 100644 src/api/resources/unstable/resources/messages/client/requests/GetWhatsAppMessageStatusRequest.ts create mode 100644 src/api/resources/unstable/resources/messages/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/messages/index.ts create mode 100644 src/api/resources/unstable/resources/messages/types/Message.ts create mode 100644 src/api/resources/unstable/resources/messages/types/index.ts create mode 100644 src/api/resources/unstable/resources/news/client/Client.ts create mode 100644 src/api/resources/unstable/resources/news/client/index.ts create mode 100644 src/api/resources/unstable/resources/news/client/requests/DeleteNewsItemRequest.ts create mode 100644 src/api/resources/unstable/resources/news/client/requests/ListLiveNewsfeedItemsRequest.ts create mode 100644 src/api/resources/unstable/resources/news/client/requests/RetrieveNewsItemRequest.ts create mode 100644 src/api/resources/unstable/resources/news/client/requests/RetrieveNewsfeedRequest.ts create mode 100644 src/api/resources/unstable/resources/news/client/requests/UpdateNewsItemRequest.ts create mode 100644 src/api/resources/unstable/resources/news/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/news/index.ts create mode 100644 src/api/resources/unstable/resources/news/types/NewsItem.ts create mode 100644 src/api/resources/unstable/resources/news/types/Newsfeed.ts create mode 100644 src/api/resources/unstable/resources/news/types/NewsfeedAssignment.ts create mode 100644 src/api/resources/unstable/resources/news/types/index.ts create mode 100644 src/api/resources/unstable/resources/notes/client/Client.ts create mode 100644 src/api/resources/unstable/resources/notes/client/index.ts create mode 100644 src/api/resources/unstable/resources/notes/client/requests/CreateNoteRequest.ts create mode 100644 src/api/resources/unstable/resources/notes/client/requests/ListNotesRequest.ts create mode 100644 src/api/resources/unstable/resources/notes/client/requests/RetrieveNoteRequest.ts create mode 100644 src/api/resources/unstable/resources/notes/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/notes/index.ts create mode 100644 src/api/resources/unstable/resources/notes/types/Note.ts create mode 100644 src/api/resources/unstable/resources/notes/types/index.ts create mode 100644 src/api/resources/unstable/resources/segments/client/Client.ts create mode 100644 src/api/resources/unstable/resources/segments/client/index.ts create mode 100644 src/api/resources/unstable/resources/segments/client/requests/ListSegmentsRequest.ts create mode 100644 src/api/resources/unstable/resources/segments/client/requests/RetrieveSegmentRequest.ts create mode 100644 src/api/resources/unstable/resources/segments/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/segments/index.ts create mode 100644 src/api/resources/unstable/resources/segments/types/Segment.ts create mode 100644 src/api/resources/unstable/resources/segments/types/index.ts create mode 100644 src/api/resources/unstable/resources/subscriptionTypes/client/Client.ts create mode 100644 src/api/resources/unstable/resources/subscriptionTypes/client/index.ts create mode 100644 src/api/resources/unstable/resources/subscriptionTypes/client/requests/AttachSubscriptionTypeToContactRequest.ts create mode 100644 src/api/resources/unstable/resources/subscriptionTypes/client/requests/DetachSubscriptionTypeToContactRequest.ts create mode 100644 src/api/resources/unstable/resources/subscriptionTypes/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/subscriptionTypes/index.ts create mode 100644 src/api/resources/unstable/resources/subscriptionTypes/types/SubscriptionType.ts create mode 100644 src/api/resources/unstable/resources/subscriptionTypes/types/index.ts create mode 100644 src/api/resources/unstable/resources/switch/client/Client.ts create mode 100644 src/api/resources/unstable/resources/switch/client/index.ts create mode 100644 src/api/resources/unstable/resources/switch/index.ts create mode 100644 src/api/resources/unstable/resources/tags/client/Client.ts create mode 100644 src/api/resources/unstable/resources/tags/client/index.ts create mode 100644 src/api/resources/unstable/resources/tags/client/requests/AttachTagToContactRequest.ts create mode 100644 src/api/resources/unstable/resources/tags/client/requests/AttachTagToConversationRequest.ts create mode 100644 src/api/resources/unstable/resources/tags/client/requests/AttachTagToTicketRequest.ts create mode 100644 src/api/resources/unstable/resources/tags/client/requests/DeleteTagRequest.ts create mode 100644 src/api/resources/unstable/resources/tags/client/requests/DetachTagFromContactRequest.ts create mode 100644 src/api/resources/unstable/resources/tags/client/requests/DetachTagFromConversationRequest.ts create mode 100644 src/api/resources/unstable/resources/tags/client/requests/DetachTagFromTicketRequest.ts create mode 100644 src/api/resources/unstable/resources/tags/client/requests/FindTagRequest.ts create mode 100644 src/api/resources/unstable/resources/tags/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/tags/index.ts create mode 100644 src/api/resources/unstable/resources/tags/types/CreateTagRequestBody.ts create mode 100644 src/api/resources/unstable/resources/tags/types/Tag.ts create mode 100644 src/api/resources/unstable/resources/tags/types/TagBasic.ts create mode 100644 src/api/resources/unstable/resources/tags/types/index.ts create mode 100644 src/api/resources/unstable/resources/teams/client/Client.ts create mode 100644 src/api/resources/unstable/resources/teams/client/index.ts create mode 100644 src/api/resources/unstable/resources/teams/client/requests/RetrieveTeamRequest.ts create mode 100644 src/api/resources/unstable/resources/teams/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/teams/index.ts create mode 100644 src/api/resources/unstable/resources/teams/types/Team.ts create mode 100644 src/api/resources/unstable/resources/teams/types/index.ts create mode 100644 src/api/resources/unstable/resources/ticketStates/client/Client.ts create mode 100644 src/api/resources/unstable/resources/ticketStates/client/index.ts create mode 100644 src/api/resources/unstable/resources/ticketStates/index.ts create mode 100644 src/api/resources/unstable/resources/ticketTypeAttributes/client/Client.ts create mode 100644 src/api/resources/unstable/resources/ticketTypeAttributes/client/index.ts create mode 100644 src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/CreateTicketTypeAttributeRequest.ts create mode 100644 src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/UpdateTicketTypeAttributeRequest.ts create mode 100644 src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/ticketTypeAttributes/index.ts create mode 100644 src/api/resources/unstable/resources/ticketTypes/client/Client.ts create mode 100644 src/api/resources/unstable/resources/ticketTypes/client/index.ts create mode 100644 src/api/resources/unstable/resources/ticketTypes/client/requests/GetTicketTypeRequest.ts create mode 100644 src/api/resources/unstable/resources/ticketTypes/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/ticketTypes/index.ts create mode 100644 src/api/resources/unstable/resources/tickets/client/Client.ts create mode 100644 src/api/resources/unstable/resources/tickets/client/index.ts create mode 100644 src/api/resources/unstable/resources/tickets/client/requests/DeleteTicketRequest.ts create mode 100644 src/api/resources/unstable/resources/tickets/client/requests/EnqueueCreateTicketRequest.ts create mode 100644 src/api/resources/unstable/resources/tickets/client/requests/GetTicketRequest.ts create mode 100644 src/api/resources/unstable/resources/tickets/client/requests/ReplyTicketRequest.ts create mode 100644 src/api/resources/unstable/resources/tickets/client/requests/UpdateTicketRequest.ts create mode 100644 src/api/resources/unstable/resources/tickets/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/tickets/index.ts create mode 100644 src/api/resources/unstable/resources/tickets/types/DeleteTicketResponse.ts create mode 100644 src/api/resources/unstable/resources/tickets/types/ReplyTicketRequestBody.ts create mode 100644 src/api/resources/unstable/resources/tickets/types/Ticket.ts create mode 100644 src/api/resources/unstable/resources/tickets/types/TicketContacts.ts create mode 100644 src/api/resources/unstable/resources/tickets/types/TicketPart.ts create mode 100644 src/api/resources/unstable/resources/tickets/types/TicketState.ts create mode 100644 src/api/resources/unstable/resources/tickets/types/TicketStateDetailed.ts create mode 100644 src/api/resources/unstable/resources/tickets/types/TicketType.ts create mode 100644 src/api/resources/unstable/resources/tickets/types/index.ts create mode 100644 src/api/resources/unstable/resources/visitors/client/Client.ts create mode 100644 src/api/resources/unstable/resources/visitors/client/index.ts create mode 100644 src/api/resources/unstable/resources/visitors/client/requests/ConvertVisitorRequest.ts create mode 100644 src/api/resources/unstable/resources/visitors/client/requests/RetrieveVisitorWithUserIdRequest.ts create mode 100644 src/api/resources/unstable/resources/visitors/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/visitors/index.ts create mode 100644 src/api/resources/unstable/types/ActivityLog.ts create mode 100644 src/api/resources/unstable/types/ActivityLogList.ts create mode 100644 src/api/resources/unstable/types/ActivityLogMetadata.ts create mode 100644 src/api/resources/unstable/types/AddressableList.ts create mode 100644 src/api/resources/unstable/types/AdminList.ts create mode 100644 src/api/resources/unstable/types/AdminPriorityLevel.ts create mode 100644 src/api/resources/unstable/types/AdminReplyConversationRequest.ts create mode 100644 src/api/resources/unstable/types/AdminReplyTicketRequest.ts create mode 100644 src/api/resources/unstable/types/AdminWithApp.ts create mode 100644 src/api/resources/unstable/types/App.ts create mode 100644 src/api/resources/unstable/types/ArticleContent.ts create mode 100644 src/api/resources/unstable/types/ArticleList.ts create mode 100644 src/api/resources/unstable/types/ArticleStatistics.ts create mode 100644 src/api/resources/unstable/types/ArticleTranslatedContent.ts create mode 100644 src/api/resources/unstable/types/AssignConversationRequest.ts create mode 100644 src/api/resources/unstable/types/AwayStatusReason.ts create mode 100644 src/api/resources/unstable/types/CloseConversationRequest.ts create mode 100644 src/api/resources/unstable/types/CollectionList.ts create mode 100644 src/api/resources/unstable/types/CompanyAttachedContacts.ts create mode 100644 src/api/resources/unstable/types/CompanyAttachedSegments.ts create mode 100644 src/api/resources/unstable/types/CompanyData.ts create mode 100644 src/api/resources/unstable/types/CompanyList.ts create mode 100644 src/api/resources/unstable/types/CompanyScroll.ts create mode 100644 src/api/resources/unstable/types/ContactArchived.ts create mode 100644 src/api/resources/unstable/types/ContactAttachedCompanies.ts create mode 100644 src/api/resources/unstable/types/ContactBlocked.ts create mode 100644 src/api/resources/unstable/types/ContactCompanies.ts create mode 100644 src/api/resources/unstable/types/ContactDeleted.ts create mode 100644 src/api/resources/unstable/types/ContactList.ts create mode 100644 src/api/resources/unstable/types/ContactLocation.ts create mode 100644 src/api/resources/unstable/types/ContactNotes.ts create mode 100644 src/api/resources/unstable/types/ContactReference.ts create mode 100644 src/api/resources/unstable/types/ContactReplyBaseRequest.ts create mode 100644 src/api/resources/unstable/types/ContactReplyConversationRequest.ts create mode 100644 src/api/resources/unstable/types/ContactReplyEmailRequest.ts create mode 100644 src/api/resources/unstable/types/ContactReplyIntercomUserIdRequest.ts create mode 100644 src/api/resources/unstable/types/ContactReplyTicketEmailRequest.ts create mode 100644 src/api/resources/unstable/types/ContactReplyTicketIntercomUserIdRequest.ts create mode 100644 src/api/resources/unstable/types/ContactReplyTicketRequest.ts create mode 100644 src/api/resources/unstable/types/ContactReplyTicketUserIdRequest.ts create mode 100644 src/api/resources/unstable/types/ContactReplyUserIdRequest.ts create mode 100644 src/api/resources/unstable/types/ContactSegments.ts create mode 100644 src/api/resources/unstable/types/ContactSocialProfiles.ts create mode 100644 src/api/resources/unstable/types/ContactSubscriptionTypes.ts create mode 100644 src/api/resources/unstable/types/ContactTags.ts create mode 100644 src/api/resources/unstable/types/ContactUnarchived.ts create mode 100644 src/api/resources/unstable/types/ContentSourcesList.ts create mode 100644 src/api/resources/unstable/types/ConversationAttachmentFiles.ts create mode 100644 src/api/resources/unstable/types/ConversationAttributeUpdatedByAdmin.ts create mode 100644 src/api/resources/unstable/types/ConversationAttributeUpdatedByWorkflow.ts create mode 100644 src/api/resources/unstable/types/ConversationContacts.ts create mode 100644 src/api/resources/unstable/types/ConversationDeleted.ts create mode 100644 src/api/resources/unstable/types/ConversationFirstContactReply.ts create mode 100644 src/api/resources/unstable/types/ConversationList.ts create mode 100644 src/api/resources/unstable/types/ConversationPart.ts create mode 100644 src/api/resources/unstable/types/ConversationPartAuthor.ts create mode 100644 src/api/resources/unstable/types/ConversationPartMetadata.ts create mode 100644 src/api/resources/unstable/types/ConversationParts.ts create mode 100644 src/api/resources/unstable/types/ConversationRating.ts create mode 100644 src/api/resources/unstable/types/ConversationResponseTime.ts create mode 100644 src/api/resources/unstable/types/ConversationSource.ts create mode 100644 src/api/resources/unstable/types/ConversationStatistics.ts create mode 100644 src/api/resources/unstable/types/ConversationTeammates.ts create mode 100644 src/api/resources/unstable/types/CreateOrUpdateTagRequest.ts create mode 100644 src/api/resources/unstable/types/CreateTicketReplyWithCommentRequest.ts create mode 100644 src/api/resources/unstable/types/CreateTicketRequestBody.ts create mode 100644 src/api/resources/unstable/types/CursorPages.ts create mode 100644 src/api/resources/unstable/types/CustomActionFinished.ts create mode 100644 src/api/resources/unstable/types/CustomActionStarted.ts create mode 100644 src/api/resources/unstable/types/CustomAttributes.ts create mode 100644 src/api/resources/unstable/types/CustomChannelAttribute.ts create mode 100644 src/api/resources/unstable/types/CustomChannelBaseEvent.ts create mode 100644 src/api/resources/unstable/types/CustomChannelContact.ts create mode 100644 src/api/resources/unstable/types/CustomChannelNotificationResponse.ts create mode 100644 src/api/resources/unstable/types/CustomObjectInstanceDeleted.ts create mode 100644 src/api/resources/unstable/types/CustomObjectInstanceList.ts create mode 100644 src/api/resources/unstable/types/CustomerRequest.ts create mode 100644 src/api/resources/unstable/types/DataAttributeList.ts create mode 100644 src/api/resources/unstable/types/DataEventList.ts create mode 100644 src/api/resources/unstable/types/DataEventSummary.ts create mode 100644 src/api/resources/unstable/types/DataEventSummaryItem.ts create mode 100644 src/api/resources/unstable/types/DataExportCsv.ts create mode 100644 src/api/resources/unstable/types/Datetime.ts create mode 100644 src/api/resources/unstable/types/DeletedArticleObject.ts create mode 100644 src/api/resources/unstable/types/DeletedCollectionObject.ts create mode 100644 src/api/resources/unstable/types/DeletedCompanyObject.ts create mode 100644 src/api/resources/unstable/types/DeletedObject.ts create mode 100644 src/api/resources/unstable/types/EmailAddressHeader.ts create mode 100644 src/api/resources/unstable/types/EmailMessageMetadata.ts create mode 100644 src/api/resources/unstable/types/Error_.ts create mode 100644 src/api/resources/unstable/types/EventDetails.ts create mode 100644 src/api/resources/unstable/types/FileAttribute.ts create mode 100644 src/api/resources/unstable/types/GroupContent.ts create mode 100644 src/api/resources/unstable/types/GroupTranslatedContent.ts create mode 100644 src/api/resources/unstable/types/IntercomVersion.ts create mode 100644 src/api/resources/unstable/types/IntercomVersionUnstable.ts create mode 100644 src/api/resources/unstable/types/LinkedObject.ts create mode 100644 src/api/resources/unstable/types/LinkedObjectList.ts create mode 100644 src/api/resources/unstable/types/MultipleFilterSearchRequest.ts create mode 100644 src/api/resources/unstable/types/NewsItemRequest.ts create mode 100644 src/api/resources/unstable/types/NotFoundErrorBody.ts create mode 100644 src/api/resources/unstable/types/NoteList.ts create mode 100644 src/api/resources/unstable/types/OpenConversationRequest.ts create mode 100644 src/api/resources/unstable/types/OperatorWorkflowEvent.ts create mode 100644 src/api/resources/unstable/types/PagesLink.ts create mode 100644 src/api/resources/unstable/types/PaginatedResponse.ts create mode 100644 src/api/resources/unstable/types/PaginatedResponseDataItem.ts create mode 100644 src/api/resources/unstable/types/PartAttachment.ts create mode 100644 src/api/resources/unstable/types/PhoneSwitch.ts create mode 100644 src/api/resources/unstable/types/QuickReplyOption.ts create mode 100644 src/api/resources/unstable/types/Recipient.ts create mode 100644 src/api/resources/unstable/types/RedactConversationRequest.ts create mode 100644 src/api/resources/unstable/types/Reference.ts create mode 100644 src/api/resources/unstable/types/ReplyConversationRequestBody.ts create mode 100644 src/api/resources/unstable/types/SearchRequest.ts create mode 100644 src/api/resources/unstable/types/SegmentList.ts create mode 100644 src/api/resources/unstable/types/SingleFilterSearchRequest.ts create mode 100644 src/api/resources/unstable/types/SlaApplied.ts create mode 100644 src/api/resources/unstable/types/SnoozeConversationRequest.ts create mode 100644 src/api/resources/unstable/types/SocialProfile.ts create mode 100644 src/api/resources/unstable/types/StartingAfterPaging.ts create mode 100644 src/api/resources/unstable/types/SubscriptionTypeList.ts create mode 100644 src/api/resources/unstable/types/TagCompanyRequest.ts create mode 100644 src/api/resources/unstable/types/TagList.ts create mode 100644 src/api/resources/unstable/types/TagMultipleUsersRequest.ts create mode 100644 src/api/resources/unstable/types/Tags.ts create mode 100644 src/api/resources/unstable/types/TeamList.ts create mode 100644 src/api/resources/unstable/types/TeamPriorityLevel.ts create mode 100644 src/api/resources/unstable/types/TicketCustomAttributes.ts create mode 100644 src/api/resources/unstable/types/TicketList.ts create mode 100644 src/api/resources/unstable/types/TicketPartAuthor.ts create mode 100644 src/api/resources/unstable/types/TicketParts.ts create mode 100644 src/api/resources/unstable/types/TicketReply.ts create mode 100644 src/api/resources/unstable/types/TicketRequestCustomAttributes.ts create mode 100644 src/api/resources/unstable/types/TicketStateList.ts create mode 100644 src/api/resources/unstable/types/TicketTypeAttribute.ts create mode 100644 src/api/resources/unstable/types/TicketTypeAttributeList.ts create mode 100644 src/api/resources/unstable/types/TicketTypeList.ts create mode 100644 src/api/resources/unstable/types/Translation.ts create mode 100644 src/api/resources/unstable/types/UntagCompanyRequest.ts create mode 100644 src/api/resources/unstable/types/UpdateArticleRequestBody.ts create mode 100644 src/api/resources/unstable/types/UpdateTicketTypeRequestBody.ts create mode 100644 src/api/resources/unstable/types/Visitor.ts create mode 100644 src/api/resources/unstable/types/VisitorDeletedObject.ts create mode 100644 src/api/resources/unstable/types/WhatsappMessageStatusList.ts create mode 100644 src/api/resources/unstable/types/index.ts create mode 100644 src/api/types/CreateContactRequestTwo.ts create mode 100644 src/api/types/CreateDataEventRequestTwo.ts create mode 100644 src/api/types/CreateMessageRequestTwo.ts rename src/api/{resources/tickets/client/requests => types}/CreateTicketRequest.ts (74%) create mode 100644 src/api/types/Metadata.ts create mode 100644 src/api/types/UpdateVisitorRequestOne.ts create mode 100644 src/core/fetcher/Headers.ts create mode 100644 src/core/fetcher/HttpResponsePromise.ts create mode 100644 src/core/fetcher/RawResponse.ts create mode 100644 tests/unit/fetcher/HttpResponsePromise.test.ts create mode 100644 tests/unit/fetcher/RawResponse.test.ts diff --git a/.github/workflows/label-ai-generated-prs.yml b/.github/workflows/label-ai-generated-prs.yml deleted file mode 100644 index 547cbfec..00000000 --- a/.github/workflows/label-ai-generated-prs.yml +++ /dev/null @@ -1,11 +0,0 @@ -# .github/workflows/label-ai-generated-prs.yml -name: Label AI-generated PRs - -on: - pull_request: - types: [opened, edited, synchronize] # run when the body changes too - -jobs: - call-label-ai-prs: - uses: intercom/github-action-workflows/.github/workflows/label-ai-prs.yml@main - secrets: inherit \ No newline at end of file diff --git a/README.md b/README.md index dce13154..08d01dae 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,7 @@ npm i -s intercom-client ## Reference -A full reference for this library is available [here](./reference.md). +A full reference for this library is available [here](https://github.com/intercom/intercom-node/blob/HEAD/./reference.md). ## Usage @@ -64,6 +64,7 @@ try { console.log(err.statusCode); console.log(err.message); console.log(err.body); + console.log(err.rawResponse); } } ``` @@ -144,6 +145,18 @@ const response = await client.articles.create(..., { controller.abort(); // aborts the request ``` +### Access Raw Response Data + +The SDK provides access to raw response data, including headers, through the `.withRawResponse()` method. +The `.withRawResponse()` method returns a promise that results to an object with a `data` and a `rawResponse` property. + +```typescript +const { data, rawResponse } = await client.articles.create(...).withRawResponse(); + +console.log(data); +console.log(rawResponse.headers['X-My-Header']); +``` + ### Runtime Compatibility The SDK defaults to `node-fetch` but will use the global fetch client if present. The SDK works in the following @@ -158,7 +171,7 @@ runtimes: ### Customizing Fetch Client -The SDK provides a way for your to customize the underlying HTTP client / Fetch function. If you're running in an +The SDK provides a way for you to customize the underlying HTTP client / Fetch function. If you're running in an unsupported environment, this provides a way for you to break glass and ensure the SDK works. ```typescript diff --git a/package.json b/package.json index e3b19250..00b818fa 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "6.3.0", + "version": "6.4.0", "private": false, "repository": "https://github.com/intercom/intercom-node", "main": "./index.js", @@ -40,6 +40,7 @@ "os": false, "path": false }, + "packageManager": "yarn@1.22.22", "license": "Apache-2.0", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", diff --git a/reference.md b/reference.md index a73a1fe3..df65e9f7 100644 --- a/reference.md +++ b/reference.md @@ -6833,168 +6833,6 @@ await client.visitors.mergeToContact({
-## CustomChannelEvents - -
client.customChannelEvents.notifyAttributeCollected() -> void -
-
- -#### 🔌 Usage - -
-
- -
-
- -```typescript -await client.customChannelEvents.notifyAttributeCollected(); -``` - -
-
-
-
- -#### ⚙️ Parameters - -
-
- -
-
- -**requestOptions:** `CustomChannelEvents.RequestOptions` - -
-
-
-
- -
-
-
- -
client.customChannelEvents.notifyNewMessage() -> void -
-
- -#### 🔌 Usage - -
-
- -
-
- -```typescript -await client.customChannelEvents.notifyNewMessage(); -``` - -
-
-
-
- -#### ⚙️ Parameters - -
-
- -
-
- -**requestOptions:** `CustomChannelEvents.RequestOptions` - -
-
-
-
- -
-
-
- -
client.customChannelEvents.notifyNewConversation() -> void -
-
- -#### 🔌 Usage - -
-
- -
-
- -```typescript -await client.customChannelEvents.notifyNewConversation(); -``` - -
-
-
-
- -#### ⚙️ Parameters - -
-
- -
-
- -**requestOptions:** `CustomChannelEvents.RequestOptions` - -
-
-
-
- -
-
-
- -
client.customChannelEvents.notifyQuickReplySelected() -> void -
-
- -#### 🔌 Usage - -
-
- -
-
- -```typescript -await client.customChannelEvents.notifyQuickReplySelected(); -``` - -
-
-
-
- -#### ⚙️ Parameters - -
-
- -
-
- -**requestOptions:** `CustomChannelEvents.RequestOptions` - -
-
-
-
- -
-
-
- ## HelpCenters Collections
client.helpCenters.collections.list({ ...params }) -> core.Page @@ -7976,3 +7814,9265 @@ await client.ticketTypes.attributes.update({
+ +## Admins + +
client.unstable.admins.identifyAdmin() -> Intercom.AdminWithApp | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can view the currently authorised admin along with the embedded app object (a "workspace" in legacy terminology). + +> 🚧 Single Sign On +> +> If you are building a custom "Log in with Intercom" flow for your site, and you call the `/me` endpoint to identify the logged-in user, you should not accept any sign-ins from users with unverified email addresses as it poses a potential impersonation security risk. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.admins.identifyAdmin(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Admins.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.admins.setAwayAdmin({ ...params }) -> Intercom.Admin | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can set an Admin as away for the Inbox. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.admins.setAwayAdmin({ + id: 1, + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.SetAwayAdminRequest` + +
+
+ +
+
+ +**requestOptions:** `Admins.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.admins.listActivityLogs({ ...params }) -> Intercom.ActivityLogList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can get a log of activities by all admins in an app. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.admins.listActivityLogs({ + created_at_after: "1677253093", + created_at_before: "1677861493", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ListActivityLogsRequest` + +
+
+ +
+
+ +**requestOptions:** `Admins.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.admins.listAdmins() -> Intercom.AdminList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of admins for a given workspace. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.admins.listAdmins(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Admins.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.admins.retrieveAdmin({ ...params }) -> Intercom.Admin | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can retrieve the details of a single admin. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.admins.retrieveAdmin({ + id: 1, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.RetrieveAdminRequest` + +
+
+ +
+
+ +**requestOptions:** `Admins.RequestOptions` + +
+
+
+
+ +
+
+
+ +## AI Content + +
client.unstable.aiContent.listContentImportSources() -> Intercom.ContentImportSourcesList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can retrieve a list of all content import sources for a workspace. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.aiContent.listContentImportSources(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `AiContent.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.aiContent.createContentImportSource({ ...params }) -> Intercom.ContentImportSource +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a new content import source by sending a POST request to this endpoint. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.aiContent.createContentImportSource({ + url: "https://www.example.com", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.CreateContentImportSourceRequest` + +
+
+ +
+
+ +**requestOptions:** `AiContent.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.aiContent.getContentImportSource({ ...params }) -> Intercom.ContentImportSource +
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.aiContent.getContentImportSource({ + id: "id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.GetContentImportSourceRequest` + +
+
+ +
+
+ +**requestOptions:** `AiContent.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.aiContent.updateContentImportSource({ ...params }) -> Intercom.ContentImportSource +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update an existing content import source. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.aiContent.updateContentImportSource({ + id: "id", + sync_behavior: "api", + url: "https://www.example.com", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.UpdateContentImportSourceRequest` + +
+
+ +
+
+ +**requestOptions:** `AiContent.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.aiContent.deleteContentImportSource({ ...params }) -> void +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete a content import source by making a DELETE request this endpoint. This will also delete all external pages that were imported from this source. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.aiContent.deleteContentImportSource({ + id: "id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DeleteContentImportSourceRequest` + +
+
+ +
+
+ +**requestOptions:** `AiContent.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.aiContent.listExternalPages() -> Intercom.ExternalPagesList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can retrieve a list of all external pages for a workspace. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.aiContent.listExternalPages(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `AiContent.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.aiContent.createExternalPage({ ...params }) -> Intercom.ExternalPage +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a new external page by sending a POST request to this endpoint. If an external page already exists with the specified source_id and external_id, it will be updated instead. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.aiContent.createExternalPage({ + title: "Test", + html: "

Test

", + url: "https://www.example.com", + source_id: 44, + external_id: "abc1234", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.CreateExternalPageRequest` + +
+
+ +
+
+ +**requestOptions:** `AiContent.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.aiContent.getExternalPage({ ...params }) -> Intercom.ExternalPage +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can retrieve an external page. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.aiContent.getExternalPage({ + id: "id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.GetExternalPageRequest` + +
+
+ +
+
+ +**requestOptions:** `AiContent.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.aiContent.updateExternalPage({ ...params }) -> Intercom.ExternalPage +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update an existing external page (if it was created via the API). + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.aiContent.updateExternalPage({ + id: "id", + title: "Test", + html: "

Test

", + url: "https://www.example.com", + source_id: 47, + external_id: "5678", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.UpdateExternalPageRequest` + +
+
+ +
+
+ +**requestOptions:** `AiContent.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.aiContent.deleteExternalPage({ ...params }) -> Intercom.ExternalPage +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Sending a DELETE request for an external page will remove it from the content library UI and from being used for AI answers. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.aiContent.deleteExternalPage({ + id: "id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DeleteExternalPageRequest` + +
+
+ +
+
+ +**requestOptions:** `AiContent.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Articles + +
client.unstable.articles.listArticles() -> Intercom.ArticleList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all articles by making a GET request to `https://api.intercom.io/articles`. + +> 📘 How are the articles sorted and ordered? +> +> Articles will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated articles first. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.articles.listArticles(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Articles.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.articles.createArticle({ ...params }) -> Intercom.Article +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a new article by making a POST request to `https://api.intercom.io/articles`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.articles.createArticle({ + key: "value", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `unknown` + +
+
+ +
+
+ +**requestOptions:** `Articles.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.articles.retrieveArticle({ ...params }) -> Intercom.Article +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single article by making a GET request to `https://api.intercom.io/articles/`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.articles.retrieveArticle({ + id: 1, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.RetrieveArticleRequest` + +
+
+ +
+
+ +**requestOptions:** `Articles.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.articles.deleteArticle({ ...params }) -> Intercom.DeletedArticleObject +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete a single article by making a DELETE request to `https://api.intercom.io/articles/`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.articles.deleteArticle({ + id: 1, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DeleteArticleRequest` + +
+
+ +
+
+ +**requestOptions:** `Articles.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.articles.searchArticles({ ...params }) -> Intercom.ArticleSearchResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can search for articles by making a GET request to `https://api.intercom.io/articles/search`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.articles.searchArticles({ + phrase: "Getting started", + state: "published", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.SearchArticlesRequest` + +
+
+ +
+
+ +**requestOptions:** `Articles.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Away Status Reasons + +
client.unstable.awayStatusReasons.listAwayStatusReasons() -> Intercom.AwayStatusReason[] +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Returns a list of all away status reasons configured for the workspace, including deleted ones. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.awayStatusReasons.listAwayStatusReasons(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `AwayStatusReasons.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Unstable Export + +
client.unstable.export.enqueueANewReportingDataExportJob({ ...params }) -> Intercom.PostExportReportingDataEnqueueResponse +
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.export.enqueueANewReportingDataExportJob({ + dataset_id: "conversation", + attribute_ids: ["conversation.id", "conversation.first_user_conversation_part_created_at"], + start_time: 1717490000, + end_time: 1717510000, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.PostExportReportingDataEnqueueRequest` + +
+
+ +
+
+ +**requestOptions:** `Export.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.export.listAvailableDatasetsAndAttributes() -> Intercom.GetExportReportingDataGetDatasetsResponse +
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.export.listAvailableDatasetsAndAttributes(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Export.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Help Center + +
client.unstable.helpCenter.listAllCollections() -> Intercom.CollectionList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all collections by making a GET request to `https://api.intercom.io/help_center/collections`. + +Collections will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated collections first. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.helpCenter.listAllCollections(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `HelpCenter.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.helpCenter.createCollection({ ...params }) -> Intercom.Collection +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a new collection by making a POST request to `https://api.intercom.io/help_center/collections.` + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.helpCenter.createCollection({ + name: "Thanks for everything", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.CreateCollectionRequest` + +
+
+ +
+
+ +**requestOptions:** `HelpCenter.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.helpCenter.retrieveCollection({ ...params }) -> Intercom.Collection +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single collection by making a GET request to `https://api.intercom.io/help_center/collections/`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.helpCenter.retrieveCollection({ + id: 1, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.RetrieveCollectionRequest` + +
+
+ +
+
+ +**requestOptions:** `HelpCenter.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.helpCenter.updateCollection({ ...params }) -> Intercom.Collection +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update the details of a single collection by making a PUT request to `https://api.intercom.io/collections/`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.helpCenter.updateCollection({ + id: 1, + name: "Update collection name", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.UpdateCollectionRequest` + +
+
+ +
+
+ +**requestOptions:** `HelpCenter.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.helpCenter.deleteCollection({ ...params }) -> Intercom.DeletedCollectionObject +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete a single collection by making a DELETE request to `https://api.intercom.io/collections/`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.helpCenter.deleteCollection({ + id: 1, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DeleteCollectionRequest` + +
+
+ +
+
+ +**requestOptions:** `HelpCenter.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.helpCenter.retrieveHelpCenter({ ...params }) -> Intercom.HelpCenter +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single Help Center by making a GET request to `https://api.intercom.io/help_center/help_center/`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.helpCenter.retrieveHelpCenter({ + id: 1, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.RetrieveHelpCenterRequest` + +
+
+ +
+
+ +**requestOptions:** `HelpCenter.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.helpCenter.listHelpCenters() -> Intercom.HelpCenterList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can list all Help Centers by making a GET request to `https://api.intercom.io/help_center/help_centers`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.helpCenter.listHelpCenters(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `HelpCenter.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Companies + +
client.unstable.companies.retrieveCompany({ ...params }) -> Intercom.CompanyList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a single company by passing in `company_id` or `name`. + +`https://api.intercom.io/companies?name={name}` + +`https://api.intercom.io/companies?company_id={company_id}` + +You can fetch all companies and filter by `segment_id` or `tag_id` as a query parameter. + +`https://api.intercom.io/companies?tag_id={tag_id}` + +`https://api.intercom.io/companies?segment_id={segment_id}` + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.companies.retrieveCompany({ + name: "my company", + company_id: "12345", + tag_id: "678910", + segment_id: "98765", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.RetrieveCompanyRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.companies.createOrUpdateCompany({ ...params }) -> Intercom.Company +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create or update a company. + +Companies will be only visible in Intercom when there is at least one associated user. + +Companies are looked up via `company_id` in a `POST` request, if not found via `company_id`, the new company will be created, if found, that company will be updated. + +{% admonition type="warning" name="Using `company_id`" %} +You can set a unique `company_id` value when creating a company. However, it is not possible to update `company_id`. Be sure to set a unique value once upon creation of the company. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.companies.createOrUpdateCompany({ + key: "value", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `unknown` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.companies.retrieveACompanyById({ ...params }) -> Intercom.Company +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a single company. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.companies.retrieveACompanyById({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.RetrieveACompanyByIdRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.companies.updateCompany({ ...params }) -> Intercom.Company +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update a single company using the Intercom provisioned `id`. + +{% admonition type="warning" name="Using `company_id`" %} +When updating a company it is not possible to update `company_id`. This can only be set once upon creation of the company. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.companies.updateCompany({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.UpdateCompanyRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.companies.deleteCompany({ ...params }) -> Intercom.DeletedCompanyObject +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete a single company. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.companies.deleteCompany({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DeleteCompanyRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.companies.listAttachedContacts({ ...params }) -> Intercom.CompanyAttachedContacts +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all contacts that belong to a company. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.companies.listAttachedContacts({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ListAttachedContactsRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.companies.listAttachedSegmentsForCompanies({ ...params }) -> Intercom.CompanyAttachedSegments +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all segments that belong to a company. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.companies.listAttachedSegmentsForCompanies({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ListAttachedSegmentsForCompaniesRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.companies.listAllCompanies({ ...params }) -> Intercom.CompanyList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can list companies. The company list is sorted by the `last_request_at` field and by default is ordered descending, most recently requested first. + +Note that the API does not include companies who have no associated users in list responses. + +When using the Companies endpoint and the pages object to iterate through the returned companies, there is a limit of 10,000 Companies that can be returned. If you need to list or iterate on more than 10,000 Companies, please use the [Scroll API](https://developers.intercom.com/reference#iterating-over-all-companies). +{% admonition type="warning" name="Pagination" %} +You can use pagination to limit the number of results returned. The default is `20` results per page. +See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.companies.listAllCompanies({ + order: "desc", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ListAllCompaniesRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.companies.scrollOverAllCompanies({ ...params }) -> Intercom.CompanyScroll | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ + The `list all companies` functionality does not work well for huge datasets, and can result in errors and performance problems when paging deeply. The Scroll API provides an efficient mechanism for iterating over all companies in a dataset. + +- Each app can only have 1 scroll open at a time. You'll get an error message if you try to have more than one open per app. +- If the scroll isn't used for 1 minute, it expires and calls with that scroll param will fail +- If the end of the scroll is reached, "companies" will be empty and the scroll parameter will expire + +{% admonition type="info" name="Scroll Parameter" %} +You can get the first page of companies by simply sending a GET request to the scroll endpoint. +For subsequent requests you will need to use the scroll parameter from the response. +{% /admonition %} +{% admonition type="danger" name="Scroll network timeouts" %} +Since scroll is often used on large datasets network errors such as timeouts can be encountered. When this occurs you will see a HTTP 500 error with the following message: +"Request failed due to an internal network error. Please restart the scroll operation." +If this happens, you will need to restart your scroll query: It is not possible to continue from a specific point when using scroll. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.companies.scrollOverAllCompanies(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ScrollOverAllCompaniesRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.companies.attachContactToACompany({ ...params }) -> Intercom.Company +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can attach a company to a single contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.companies.attachContactToACompany({ + id: "id", + company_id: "6762f09a1bb69f9f2193bb34", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.AttachContactToACompanyRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.companies.detachContactFromACompany({ ...params }) -> Intercom.Company +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can detach a company from a single contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.companies.detachContactFromACompany({ + contact_id: "58a430d35458202d41b1e65b", + id: "58a430d35458202d41b1e65b", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DetachContactFromACompanyRequest` + +
+
+ +
+
+ +**requestOptions:** `Companies.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Contacts + +
client.unstable.contacts.listCompaniesForAContact({ ...params }) -> Intercom.ContactAttachedCompanies +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of companies that are associated to a contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.listCompaniesForAContact({ + id: "63a07ddf05a32042dffac965", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ListCompaniesForAContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.contacts.listSegmentsForAContact({ ...params }) -> Intercom.ContactSegments +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of segments that are associated to a contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.listSegmentsForAContact({ + contact_id: "63a07ddf05a32042dffac965", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ListSegmentsForAContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.contacts.listSubscriptionsForAContact({ ...params }) -> Intercom.SubscriptionTypeList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of subscription types that are attached to a contact. These can be subscriptions that a user has 'opted-in' to or has 'opted-out' from, depending on the subscription type. +This will return a list of Subscription Type objects that the contact is associated with. + +The data property will show a combined list of: + +1.Opt-out subscription types that the user has opted-out from. +2.Opt-in subscription types that the user has opted-in to receiving. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.listSubscriptionsForAContact({ + contact_id: "63a07ddf05a32042dffac965", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ListSubscriptionsForAContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.contacts.listTagsForAContact({ ...params }) -> Intercom.TagList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all tags that are attached to a specific contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.listTagsForAContact({ + contact_id: "63a07ddf05a32042dffac965", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ListTagsForAContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.contacts.showContact({ ...params }) -> Intercom.ShowContactResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.showContact({ + id: "63a07ddf05a32042dffac965", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ShowContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.contacts.updateContact({ ...params }) -> Intercom.UpdateContactResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update an existing contact (ie. user or lead). + +{% admonition type="info" %} +This endpoint handles both **contact updates** and **custom object associations**. + +See _`update a contact with an association to a custom object instance`_ in the request/response examples to see the custom object association format. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.updateContact({ + id: "63a07ddf05a32042dffac965", + email: "joebloggs@intercom.io", + name: "joe bloggs", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.UpdateContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.contacts.deleteContact({ ...params }) -> Intercom.ContactDeleted +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete a single contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.deleteContact({ + id: "id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DeleteContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.contacts.mergeContact({ ...params }) -> Intercom.MergeContactResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can merge a contact with a `role` of `lead` into a contact with a `role` of `user`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.mergeContact({ + from: "6762f0d51bb69f9f2193bb7f", + into: "6762f0d51bb69f9f2193bb80", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.MergeContactsRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.contacts.searchContacts({ ...params }) -> Intercom.ContactList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can search for multiple contacts by the value of their attributes in order to fetch exactly who you want. + +To search for contacts, you need to send a `POST` request to `https://api.intercom.io/contacts/search`. + +This will accept a query object in the body which will define your filters in order to search for contacts. + +{% admonition type="warning" name="Optimizing search queries" %} +Search queries can be complex, so optimizing them can help the performance of your search. +Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize +pagination to limit the number of results returned. The default is `50` results per page. +See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. +{% /admonition %} + +### Contact Creation Delay + +If a contact has recently been created, there is a possibility that it will not yet be available when searching. This means that it may not appear in the response. This delay can take a few minutes. If you need to be instantly notified it is recommended to use webhooks and iterate to see if they match your search filters. + +### Nesting & Limitations + +You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). +There are some limitations to the amount of multiple's there can be: + +- There's a limit of max 2 nested filters +- There's a limit of max 15 filters for each AND or OR group + +### Searching for Timestamp Fields + +All timestamp fields (created_at, updated_at etc.) are indexed as Dates for Contact Search queries; Datetime queries are not currently supported. This means you can only query for timestamp fields by day - not hour, minute or second. +For example, if you search for all Contacts with a created_at value greater (>) than 1577869200 (the UNIX timestamp for January 1st, 2020 9:00 AM), that will be interpreted as 1577836800 (January 1st, 2020 12:00 AM). The search results will then include Contacts created from January 2nd, 2020 12:00 AM onwards. +If you'd like to get contacts created on January 1st, 2020 you should search with a created_at value equal (=) to 1577836800 (January 1st, 2020 12:00 AM). +This behaviour applies only to timestamps used in search queries. The search results will still contain the full UNIX timestamp and be sorted accordingly. + +### Accepted Fields + +Most key listed as part of the Contacts Model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). + +| Field | Type | +| ---------------------------------- | ------------------------------ | +| id | String | +| role | String
Accepts user or lead | +| name | String | +| avatar | String | +| owner_id | Integer | +| email | String | +| email_domain | String | +| phone | String | +| formatted_phone | String | +| external_id | String | +| created_at | Date (UNIX Timestamp) | +| signed_up_at | Date (UNIX Timestamp) | +| updated_at | Date (UNIX Timestamp) | +| last_seen_at | Date (UNIX Timestamp) | +| last_contacted_at | Date (UNIX Timestamp) | +| last_replied_at | Date (UNIX Timestamp) | +| last_email_opened_at | Date (UNIX Timestamp) | +| last_email_clicked_at | Date (UNIX Timestamp) | +| language_override | String | +| browser | String | +| browser_language | String | +| os | String | +| location.country | String | +| location.region | String | +| location.city | String | +| unsubscribed_from_emails | Boolean | +| marked_email_as_spam | Boolean | +| has_hard_bounced | Boolean | +| ios_last_seen_at | Date (UNIX Timestamp) | +| ios_app_version | String | +| ios_device | String | +| ios_app_device | String | +| ios_os_version | String | +| ios_app_name | String | +| ios_sdk_version | String | +| android_last_seen_at | Date (UNIX Timestamp) | +| android_app_version | String | +| android_device | String | +| android_app_name | String | +| andoid_sdk_version | String | +| segment_id | String | +| tag_id | String | +| custom_attributes.{attribute_name} | String | + +### Accepted Operators + +{% admonition type="warning" name="Searching based on `created_at`" %} +You cannot use the `<=` or `>=` operators to search by `created_at`. +{% /admonition %} + +The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + +| Operator | Valid Types | Description | +| :------- | :------------------------------- | :--------------------------------------------------------------- | +| = | All | Equals | +| != | All | Doesn't Equal | +| IN | All | In
Shortcut for `OR` queries
Values must be in Array | +| NIN | All | Not In
Shortcut for `OR !` queries
Values must be in Array | +| > | Integer
Date (UNIX Timestamp) | Greater than | +| < | Integer
Date (UNIX Timestamp) | Lower than | +| ~ | String | Contains | +| !~ | String | Doesn't Contain | +| ^ | String | Starts With | +| $ | String | Ends With | + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.searchContacts({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.SearchRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.contacts.listContacts() -> Intercom.ContactList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all contacts (ie. users or leads) in your workspace. +{% admonition type="warning" name="Pagination" %} +You can use pagination to limit the number of results returned. The default is `50` results per page. +See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.listContacts(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.contacts.createContact({ ...params }) -> Intercom.CreateContactResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a new contact (ie. user or lead). + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.createContact({ + email: "joebloggs@intercom.io", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateContactRequestTwo` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.contacts.showContactByExternalId({ ...params }) -> Intercom.ShowContactByExternalIdResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single contact by external ID. Note that this endpoint only supports users and not leads. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.showContactByExternalId({ + external_id: "cdd29344-5e0c-4ef0-ac56-f9ba2979bc27", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ShowContactByExternalIdRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.contacts.archiveContact({ ...params }) -> Intercom.ContactArchived +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can archive a single contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.archiveContact({ + id: "63a07ddf05a32042dffac965", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ArchiveContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.contacts.unarchiveContact({ ...params }) -> Intercom.ContactUnarchived +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can unarchive a single contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.unarchiveContact({ + id: "63a07ddf05a32042dffac965", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.UnarchiveContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.contacts.blockContact({ ...params }) -> Intercom.ContactBlocked +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Block a single contact.
**Note:** conversations of the contact will also be archived during the process.
More details in [FAQ How do I block Inbox spam?](https://www.intercom.com/help/en/articles/8838656-inbox-faqs) + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.contacts.blockContact({ + id: "63a07ddf05a32042dffac965", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.BlockContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Contacts.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Notes + +
client.unstable.notes.listNotes({ ...params }) -> Intercom.NoteList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of notes that are associated to a contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.notes.listNotes({ + id: 1, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ListNotesRequest` + +
+
+ +
+
+ +**requestOptions:** `Notes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.notes.createNote({ ...params }) -> Intercom.Note +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can add a note to a single contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.notes.createNote({ + id: 1, + body: "Hello", + contact_id: "6762f0ad1bb69f9f2193bb62", + admin_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.CreateNoteRequest` + +
+
+ +
+
+ +**requestOptions:** `Notes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.notes.retrieveNote({ ...params }) -> Intercom.Note +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single note. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.notes.retrieveNote({ + id: 1, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.RetrieveNoteRequest` + +
+
+ +
+
+ +**requestOptions:** `Notes.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Subscription Types + +
client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({ ...params }) -> Intercom.SubscriptionType +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can add a specific subscription to a contact. In Intercom, we have two different subscription types based on user consent - opt-out and opt-in: + +1.Attaching a contact to an opt-out subscription type will opt that user out from receiving messages related to that subscription type. + +2.Attaching a contact to an opt-in subscription type will opt that user in to receiving messages related to that subscription type. + +This will return a subscription type model for the subscription type that was added to the contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "37846", + consent_type: "opt_in", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.AttachSubscriptionTypeToContactRequest` + +
+
+ +
+
+ +**requestOptions:** `SubscriptionTypes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.subscriptionTypes.detachSubscriptionTypeToContact({ ...params }) -> Intercom.SubscriptionType +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can remove a specific subscription from a contact. This will return a subscription type model for the subscription type that was removed from the contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.subscriptionTypes.detachSubscriptionTypeToContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "37846", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DetachSubscriptionTypeToContactRequest` + +
+
+ +
+
+ +**requestOptions:** `SubscriptionTypes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.subscriptionTypes.listSubscriptionTypes() -> Intercom.SubscriptionTypeList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can list all subscription types. A list of subscription type objects will be returned. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.subscriptionTypes.listSubscriptionTypes(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `SubscriptionTypes.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Tags + +
client.unstable.tags.attachTagToContact({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can tag a specific contact. This will return a tag object for the tag that was added to the contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tags.attachTagToContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "7522907", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.AttachTagToContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.tags.detachTagFromContact({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can remove tag from a specific contact. This will return a tag object for the tag that was removed from the contact. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tags.detachTagFromContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "7522907", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DetachTagFromContactRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.tags.attachTagToConversation({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can tag a specific conversation. This will return a tag object for the tag that was added to the conversation. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tags.attachTagToConversation({ + conversation_id: "64619700005694", + id: "7522907", + admin_id: "780", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.AttachTagToConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.tags.detachTagFromConversation({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can remove tag from a specific conversation. This will return a tag object for the tag that was removed from the conversation. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tags.detachTagFromConversation({ + conversation_id: "64619700005694", + id: "7522907", + admin_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DetachTagFromConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.tags.listTags() -> Intercom.TagList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all tags for a given workspace. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tags.listTags(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.tags.createTag({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can use this endpoint to perform the following operations: + +**1. Create a new tag:** You can create a new tag by passing in the tag name as specified in "Create or Update Tag Request Payload" described below. + +**2. Update an existing tag:** You can update an existing tag by passing the id of the tag as specified in "Create or Update Tag Request Payload" described below. + +**3. Tag Companies:** You can tag single company or a list of companies. You can tag a company by passing in the tag name and the company details as specified in "Tag Company Request Payload" described below. Also, if the tag doesn't exist then a new one will be created automatically. + +**4. Untag Companies:** You can untag a single company or a list of companies. You can untag a company by passing in the tag id and the company details as specified in "Untag Company Request Payload" described below. + +**5. Tag Multiple Users:** You can tag a list of users. You can tag the users by passing in the tag name and the user details as specified in "Tag Users Request Payload" described below. + +Each operation will return a tag object. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tags.createTag({ + name: "test", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateTagRequestBody` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.tags.findTag({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of tags that are on the workspace by their id. +This will return a tag object. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tags.findTag({ + id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.FindTagRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.tags.deleteTag({ ...params }) -> void +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete the details of tags that are on the workspace by passing in the id. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tags.deleteTag({ + id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DeleteTagRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.tags.attachTagToTicket({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can tag a specific ticket. This will return a tag object for the tag that was added to the ticket. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tags.attachTagToTicket({ + ticket_id: "64619700005694", + id: "7522907", + admin_id: "780", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.AttachTagToTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.tags.detachTagFromTicket({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can remove tag from a specific ticket. This will return a tag object for the tag that was removed from the ticket. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tags.detachTagFromTicket({ + ticket_id: "64619700005694", + id: "7522907", + admin_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DetachTagFromTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Tags.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Conversations + +
client.unstable.conversations.listConversations({ ...params }) -> Intercom.ConversationList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all conversations. + +You can optionally request the result page size and the cursor to start after to fetch the result. +{% admonition type="warning" name="Pagination" %} +You can use pagination to limit the number of results returned. The default is `20` results per page. +See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.conversations.listConversations(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ListConversationsRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.conversations.createConversation({ ...params }) -> Intercom.Message +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a conversation that has been initiated by a contact (ie. user or lead). +The conversation can be an in-app message only. + +{% admonition type="info" name="Sending for visitors" %} +You can also send a message from a visitor by specifying their `user_id` or `id` value in the `from` field, along with a `type` field value of `contact`. +This visitor will be automatically converted to a contact with a lead role once the conversation is created. +{% /admonition %} + +This will return the Message model that has been created. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.conversations.createConversation({ + from: { + type: "user", + id: "6762f11b1bb69f9f2193bba3", + }, + body: "Hello there", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.CreateConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.conversations.retrieveConversation({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single conversation. + +This will return a single Conversation model with all its conversation parts. + +{% admonition type="warning" name="Hard limit of 500 parts" %} +The maximum number of conversation parts that can be returned via the API is 500. If you have more than that we will return the 500 most recent conversation parts. +{% /admonition %} + +For AI agent conversation metadata, please note that you need to have the agent enabled in your workspace, which is a [paid feature](https://www.intercom.com/help/en/articles/8205718-fin-resolutions#h_97f8c2e671). + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.conversations.retrieveConversation({ + id: 1, + display_as: "plaintext", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.RetrieveConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.conversations.updateConversation({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update an existing conversation. + +{% admonition type="info" name="Replying and other actions" %} +If you want to reply to a coveration or take an action such as assign, unassign, open, close or snooze, take a look at the reply and manage endpoints. +{% /admonition %} + +{% admonition type="info" %} +This endpoint handles both **conversation updates** and **custom object associations**. + +See _`update a conversation with an association to a custom object instance`_ in the request/response examples to see the custom object association format. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.conversations.updateConversation({ + id: 1, + display_as: "plaintext", + read: true, + title: "new conversation title", + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.UpdateConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.conversations.deleteConversation({ ...params }) -> Intercom.ConversationDeleted +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete a single conversation. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.conversations.deleteConversation({ + id: 1, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DeleteConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.conversations.searchConversations({ ...params }) -> Intercom.ConversationList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can search for multiple conversations by the value of their attributes in order to fetch exactly which ones you want. + +To search for conversations, you need to send a `POST` request to `https://api.intercom.io/conversations/search`. + +This will accept a query object in the body which will define your filters in order to search for conversations. +{% admonition type="warning" name="Optimizing search queries" %} +Search queries can be complex, so optimizing them can help the performance of your search. +Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize +pagination to limit the number of results returned. The default is `20` results per page and maximum is `150`. +See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. +{% /admonition %} + +### Nesting & Limitations + +You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). +There are some limitations to the amount of multiple's there can be: + +- There's a limit of max 2 nested filters +- There's a limit of max 15 filters for each AND or OR group + +### Accepted Fields + +Most keys listed in the conversation model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). +The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. + +| Field | Type | +| :---------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------- | +| id | String | +| created_at | Date (UNIX timestamp) | +| updated_at | Date (UNIX timestamp) | +| source.type | String
Accepted fields are `conversation`, `email`, `facebook`, `instagram`, `phone_call`, `phone_switch`, `push`, `sms`, `twitter` and `whatsapp`. | +| source.id | String | +| source.delivered_as | String | +| source.subject | String | +| source.body | String | +| source.author.id | String | +| source.author.type | String | +| source.author.name | String | +| source.author.email | String | +| source.url | String | +| contact_ids | String | +| teammate_ids | String | +| admin_assignee_id | String | +| team_assignee_id | String | +| channel_initiated | String | +| open | Boolean | +| read | Boolean | +| state | String | +| waiting_since | Date (UNIX timestamp) | +| snoozed_until | Date (UNIX timestamp) | +| tag_ids | String | +| priority | String | +| statistics.time_to_assignment | Integer | +| statistics.time_to_admin_reply | Integer | +| statistics.time_to_first_close | Integer | +| statistics.time_to_last_close | Integer | +| statistics.median_time_to_reply | Integer | +| statistics.first_contact_reply_at | Date (UNIX timestamp) | +| statistics.first_assignment_at | Date (UNIX timestamp) | +| statistics.first_admin_reply_at | Date (UNIX timestamp) | +| statistics.first_close_at | Date (UNIX timestamp) | +| statistics.last_assignment_at | Date (UNIX timestamp) | +| statistics.last_assignment_admin_reply_at | Date (UNIX timestamp) | +| statistics.last_contact_reply_at | Date (UNIX timestamp) | +| statistics.last_admin_reply_at | Date (UNIX timestamp) | +| statistics.last_close_at | Date (UNIX timestamp) | +| statistics.last_closed_by_id | String | +| statistics.count_reopens | Integer | +| statistics.count_assignments | Integer | +| statistics.count_conversation_parts | Integer | +| conversation_rating.requested_at | Date (UNIX timestamp) | +| conversation_rating.replied_at | Date (UNIX timestamp) | +| conversation_rating.score | Integer | +| conversation_rating.remark | String | +| conversation_rating.contact_id | String | +| conversation_rating.admin_d | String | +| ai_agent_participated | Boolean | +| ai_agent.resolution_state | String | +| ai_agent.last_answer_type | String | +| ai_agent.rating | Integer | +| ai_agent.rating_remark | String | +| ai_agent.source_type | String | +| ai_agent.source_title | String | + +### Accepted Operators + +The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + +| Operator | Valid Types | Description | +| :------- | :---------------------------- | :--------------------------------------------------------- | +| = | All | Equals | +| != | All | Doesn't Equal | +| IN | All | In Shortcut for `OR` queries Values most be in Array | +| NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | +| > | Integer Date (UNIX Timestamp) | Greater (or equal) than | +| < | Integer Date (UNIX Timestamp) | Lower (or equal) than | +| ~ | String | Contains | +| !~ | String | Doesn't Contain | +| ^ | String | Starts With | +| $ | String | Ends With | + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.conversations.searchConversations({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.SearchRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.conversations.replyConversation({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can reply to a conversation with a message from an admin or on behalf of a contact, or with a note for admins. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.conversations.replyConversation({ + id: '123 or "last"', + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1571bb69f9f2193bbbb", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ReplyConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.conversations.manageConversation({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +For managing conversations you can: + +- Close a conversation +- Snooze a conversation to reopen on a future date +- Open a conversation which is `snoozed` or `closed` +- Assign a conversation to an admin and/or team. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.conversations.manageConversation({ + id: "123", + body: { + message_type: "close", + type: "admin", + admin_id: "12345", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ManageConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.conversations.attachContactToConversation({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. + +{% admonition type="warning" name="Contacts without an email" %} +If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.conversations.attachContactToConversation({ + id: "123", + admin_id: "12345", + customer: { + intercom_user_id: "6762f19b1bb69f9f2193bbd4", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.AttachContactToConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.conversations.detachContactFromConversation({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. + +{% admonition type="warning" name="Contacts without an email" %} +If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.conversations.detachContactFromConversation({ + conversation_id: "123", + contact_id: "123", + admin_id: "5017690", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DetachContactFromConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.conversations.redactConversation({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can redact a conversation part or the source message of a conversation (as seen in the source object). + +{% admonition type="info" name="Redacting parts and messages" %} +If you are redacting a conversation part, it must have a `body`. If you are redacting a source message, it must have been created by a contact. We will return a `conversation_part_not_redactable` error if these criteria are not met. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.conversations.redactConversation({ + type: "conversation_part", + conversation_id: "19894788788", + conversation_part_id: "19381789428", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.RedactConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.conversations.convertConversationToTicket({ ...params }) -> Intercom.Ticket | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can convert a conversation to a ticket. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.conversations.convertConversationToTicket({ + id: 1, + ticket_type_id: "53", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ConvertConversationToTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Conversations.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Unstable CustomChannelEvents + +
client.unstable.customChannelEvents.notifyNewConversation({ ...params }) -> Intercom.CustomChannelNotificationResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Notifies Intercom that a new conversation was created in your custom channel/platform. This triggers conversation creation and workflow automations within Intercom for your custom channel integration. + +> **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.customChannelEvents.notifyNewConversation({ + event_id: "evt_12345", + external_conversation_id: "conv_67890", + contact: { + type: "user", + external_id: "user_001", + name: "Jane Doe", + email: "jane.doe@example.com", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CustomChannelBaseEvent` + +
+
+ +
+
+ +**requestOptions:** `CustomChannelEvents.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.customChannelEvents.notifyNewMessage({ ...params }) -> Intercom.CustomChannelNotificationResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Notifies Intercom that a new message was sent in a conversation on your custom channel/platform. This allows Intercom to process the message and trigger any relevant workflow automations. + +> **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.customChannelEvents.notifyNewMessage({ + event_id: "evt_54321", + external_conversation_id: "conv_98765", + contact: { + type: "user", + external_id: "user_002", + name: "John Smith", + email: "john.smith@example.com", + }, + body: "Hello, I need help with my order.", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.NotifyNewMessageRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomChannelEvents.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.customChannelEvents.notifyQuickReplySelected({ ...params }) -> Intercom.CustomChannelNotificationResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Notifies Intercom that a user selected a quick reply option in your custom channel/platform. This allows Intercom to process the response and trigger any relevant workflow automations. + +> **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.customChannelEvents.notifyQuickReplySelected({ + event_id: "evt_67890", + external_conversation_id: "conv_13579", + contact: { + type: "user", + external_id: "user_003", + name: "Alice Example", + email: "alice@example.com", + }, + quick_reply_option_id: "1234", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.NotifyQuickReplySelectedRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomChannelEvents.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.customChannelEvents.notifyAttributeCollected({ ...params }) -> Intercom.CustomChannelNotificationResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Notifies Intercom that a user provided a response to an attribute collector in your custom channel/platform. This allows Intercom to process the attribute and trigger any relevant workflow automations. + +> **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.customChannelEvents.notifyAttributeCollected({ + event_id: "evt_24680", + external_conversation_id: "conv_11223", + contact: { + type: "user", + external_id: "user_004", + name: "Bob Example", + email: "bob@example.com", + }, + attribute: { + id: "shipping_address", + value: "123 Main St, Springfield", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.NotifyAttributeCollectedRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomChannelEvents.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Custom Object Instances + +
client.unstable.customObjectInstances.getCustomObjectInstancesByExternalId({ ...params }) -> Intercom.CustomObjectInstance | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Fetch a Custom Object Instance by external_id. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.customObjectInstances.getCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "Order", + external_id: "external_id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.GetCustomObjectInstancesByExternalIdRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomObjectInstances.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.customObjectInstances.createCustomObjectInstances({ ...params }) -> Intercom.CustomObjectInstance | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Create or update a custom object instance + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.customObjectInstances.createCustomObjectInstances({ + custom_object_type_identifier: "Order", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + custom_attributes: { + order_number: "ORDER-12345", + total_amount: "custom_attributes", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.CreateOrUpdateCustomObjectInstanceRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomObjectInstances.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.customObjectInstances.deleteCustomObjectInstancesById({ ...params }) -> Intercom.CustomObjectInstanceDeleted +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Delete a single Custom Object instance by external_id. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.customObjectInstances.deleteCustomObjectInstancesById({ + custom_object_type_identifier: "Order", + external_id: "external_id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DeleteCustomObjectInstancesByIdRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomObjectInstances.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.customObjectInstances.getCustomObjectInstancesById({ ...params }) -> Intercom.CustomObjectInstance | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Fetch a Custom Object Instance by id. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.customObjectInstances.getCustomObjectInstancesById({ + custom_object_type_identifier: "Order", + id: "id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.GetCustomObjectInstancesByIdRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomObjectInstances.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.customObjectInstances.deleteCustomObjectInstancesByExternalId({ ...params }) -> Intercom.CustomObjectInstanceDeleted +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Delete a single Custom Object instance using the Intercom defined id. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.customObjectInstances.deleteCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "Order", + id: "id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DeleteCustomObjectInstancesByExternalIdRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomObjectInstances.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Data Attributes + +
client.unstable.dataAttributes.lisDataAttributes({ ...params }) -> Intercom.DataAttributeList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all data attributes belonging to a workspace for contacts, companies or conversations. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.dataAttributes.lisDataAttributes(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.LisDataAttributesRequest` + +
+
+ +
+
+ +**requestOptions:** `DataAttributes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.dataAttributes.createDataAttribute({ ...params }) -> Intercom.DataAttribute +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a data attributes for a `contact` or a `company`. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.dataAttributes.createDataAttribute({ + name: "Mithril Shirt", + model: "company", + data_type: "string", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.CreateDataAttributeRequest` + +
+
+ +
+
+ +**requestOptions:** `DataAttributes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.dataAttributes.updateDataAttribute({ ...params }) -> Intercom.DataAttribute +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update a data attribute. + +> 🚧 Updating the data type is not possible +> +> It is currently a dangerous action to execute changing a data attribute's type via the API. You will need to update the type via the UI instead. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.dataAttributes.updateDataAttribute({ + id: 1, + archived: false, + description: "Just a plain old ring", + options: ["options", "options"], +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.UpdateDataAttributeRequest` + +
+
+ +
+
+ +**requestOptions:** `DataAttributes.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Data Events + +
client.unstable.dataEvents.lisDataEvents({ ...params }) -> Intercom.DataEventSummary +
+
+ +#### 📝 Description + +
+
+ +
+
+ +> 🚧 +> +> Please note that you can only 'list' events that are less than 90 days old. Event counts and summaries will still include your events older than 90 days but you cannot 'list' these events individually if they are older than 90 days + +The events belonging to a customer can be listed by sending a GET request to `https://api.intercom.io/events` with a user or lead identifier along with a `type` parameter. The identifier parameter can be one of `user_id`, `email` or `intercom_user_id`. The `type` parameter value must be `user`. + +- `https://api.intercom.io/events?type=user&user_id={user_id}` +- `https://api.intercom.io/events?type=user&email={email}` +- `https://api.intercom.io/events?type=user&intercom_user_id={id}` (this call can be used to list leads) + +The `email` parameter value should be [url encoded](http://en.wikipedia.org/wiki/Percent-encoding) when sending. + +You can optionally define the result page size as well with the `per_page` parameter. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.dataEvents.lisDataEvents({ + filter: { + user_id: "user_id", + }, + type: "type", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.LisDataEventsRequest` + +
+
+ +
+
+ +**requestOptions:** `DataEvents.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.dataEvents.createDataEvent({ ...params }) -> void +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You will need an Access Token that has write permissions to send Events. Once you have a key you can submit events via POST to the Events resource, which is located at https://api.intercom.io/events, or you can send events using one of the client libraries. When working with the HTTP API directly a client should send the event with a `Content-Type` of `application/json`. + +When using the JavaScript API, [adding the code to your app](http://docs.intercom.io/configuring-Intercom/tracking-user-events-in-your-app) makes the Events API available. Once added, you can submit an event using the `trackEvent` method. This will associate the event with the Lead or currently logged-in user or logged-out visitor/lead and send it to Intercom. The final parameter is a map that can be used to send optional metadata about the event. + +With the Ruby client you pass a hash describing the event to `Intercom::Event.create`, or call the `track_user` method directly on the current user object (e.g. `user.track_event`). + +**NB: For the JSON object types, please note that we do not currently support nested JSON structure.** + +| Type | Description | Example | +| :-------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------- | +| String | The value is a JSON String | `"source":"desktop"` | +| Number | The value is a JSON Number | `"load": 3.67` | +| Date | The key ends with the String `_date` and the value is a [Unix timestamp](http://en.wikipedia.org/wiki/Unix_time), assumed to be in the [UTC](http://en.wikipedia.org/wiki/Coordinated_Universal_Time) timezone. | `"contact_date": 1392036272` | +| Link | The value is a HTTP or HTTPS URI. | `"article": "https://example.org/ab1de.html"` | +| Rich Link | The value is a JSON object that contains `url` and `value` keys. | `"article": {"url": "https://example.org/ab1de.html", "value":"the dude abides"}` | +| Monetary Amount | The value is a JSON object that contains `amount` and `currency` keys. The `amount` key is a positive integer representing the amount in cents. The price in the example to the right denotes €349.99. | `"price": {"amount": 34999, "currency": "eur"}` | + +**Lead Events** + +When submitting events for Leads, you will need to specify the Lead's `id`. + +**Metadata behaviour** + +- We currently limit the number of tracked metadata keys to 10 per event. Once the quota is reached, we ignore any further keys we receive. The first 10 metadata keys are determined by the order in which they are sent in with the event. +- It is not possible to change the metadata keys once the event has been sent. A new event will need to be created with the new keys and you can archive the old one. +- There might be up to 24 hrs delay when you send a new metadata for an existing event. + +**Event de-duplication** + +The API may detect and ignore duplicate events. Each event is uniquely identified as a combination of the following data - the Workspace identifier, the Contact external identifier, the Data Event name and the Data Event created time. As a result, it is **strongly recommended** to send a second granularity Unix timestamp in the `created_at` field. + +Duplicated events are responded to using the normal `202 Accepted` code - an error is not thrown, however repeat requests will be counted against any rate limit that is in place. + +### HTTP API Responses + +- Successful responses to submitted events return `202 Accepted` with an empty body. +- Unauthorised access will be rejected with a `401 Unauthorized` or `403 Forbidden` response code. +- Events sent about users that cannot be found will return a `404 Not Found`. +- Event lists containing duplicate events will have those duplicates ignored. +- Server errors will return a `500` response code and may contain an error message in the body. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.dataEvents.createDataEvent({ + key: "value", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateDataEventRequestTwo` + +
+
+ +
+
+ +**requestOptions:** `DataEvents.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.dataEvents.dataEventSummaries({ ...params }) -> void +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Create event summaries for a user. Event summaries are used to track the number of times an event has occurred, the first time it occurred and the last time it occurred. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.dataEvents.dataEventSummaries(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.CreateDataEventSummariesRequest` + +
+
+ +
+
+ +**requestOptions:** `DataEvents.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Data Export + +
client.unstable.dataExport.createDataExport({ ...params }) -> Intercom.DataExport +
+
+ +#### 📝 Description + +
+
+ +
+
+ +To create your export job, you need to send a `POST` request to the export endpoint `https://api.intercom.io/export/content/data`. + +The only parameters you need to provide are the range of dates that you want exported. + +> 🚧 Limit of one active job +> +> You can only have one active job per workspace. You will receive a HTTP status code of 429 with the message Exceeded rate limit of 1 pending message data export jobs if you attempt to create a second concurrent job. + +> ❗️ Updated_at not included +> +> It should be noted that the timeframe only includes messages sent during the time period and not messages that were only updated during this period. For example, if a message was updated yesterday but sent two days ago, you would need to set the created_at_after date before the message was sent to include that in your retrieval job. + +> 📘 Date ranges are inclusive +> +> Requesting data for 2018-06-01 until 2018-06-30 will get all data for those days including those specified - e.g. 2018-06-01 00:00:00 until 2018-06-30 23:59:99. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.dataExport.createDataExport({ + created_at_after: 1734519776, + created_at_before: 1734537776, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.CreateDataExportsRequest` + +
+
+ +
+
+ +**requestOptions:** `DataExport.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.dataExport.getDataExport({ ...params }) -> Intercom.DataExport +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can view the status of your job by sending a `GET` request to the URL +`https://api.intercom.io/export/content/data/{job_identifier}` - the `{job_identifier}` is the value returned in the response when you first created the export job. More on it can be seen in the Export Job Model. + +> 🚧 Jobs expire after two days +> All jobs that have completed processing (and are thus available to download from the provided URL) will have an expiry limit of two days from when the export ob completed. After this, the data will no longer be available. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.dataExport.getDataExport({ + job_identifier: "job_identifier", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.GetDataExportRequest` + +
+
+ +
+
+ +**requestOptions:** `DataExport.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.dataExport.cancelDataExport({ ...params }) -> Intercom.DataExport +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can cancel your job + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.dataExport.cancelDataExport({ + job_identifier: "job_identifier", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.CancelDataExportRequest` + +
+
+ +
+
+ +**requestOptions:** `DataExport.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.dataExport.downloadDataExport({ ...params }) -> void +
+
+ +#### 📝 Description + +
+
+ +
+
+ +When a job has a status of complete, and thus a filled download_url, you can download your data by hitting that provided URL, formatted like so: https://api.intercom.io/download/content/data/xyz1234. + +Your exported message data will be streamed continuously back down to you in a gzipped CSV format. + +> 📘 Octet header required +> +> You will have to specify the header Accept: `application/octet-stream` when hitting this endpoint. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.dataExport.downloadDataExport({ + job_identifier: "job_identifier", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DownloadDataExportRequest` + +
+
+ +
+
+ +**requestOptions:** `DataExport.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Jobs + +
client.unstable.jobs.status({ ...params }) -> Intercom.Jobs +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve the status of job execution. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.jobs.status({ + id: "id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.JobsStatusRequest` + +
+
+ +
+
+ +**requestOptions:** `Jobs.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Messages + +
client.unstable.messages.createMessage({ ...params }) -> Intercom.Message +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a message that has been initiated by an admin. The conversation can be either an in-app message, an email or sms. + +> 🚧 Sending for visitors +> +> There can be a short delay between when a contact is created and when a contact becomes available to be messaged through the API. A 404 Not Found error will be returned in this case. + +This will return the Message model that has been created. + +> 🚧 Retrieving Associated Conversations +> +> As this is a message, there will be no conversation present until the contact responds. Once they do, you will have to search for a contact's conversations with the id of the message. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.messages.createMessage({ + from: { + type: "user", + id: "6762f2341bb69f9f2193bc17", + }, + body: "heyy", + referer: "https://twitter.com/bob", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateMessageRequestTwo` + +
+
+ +
+
+ +**requestOptions:** `Messages.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.messages.getWhatsAppMessageStatus({ ...params }) -> Intercom.WhatsappMessageStatusList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieves statuses of messages sent from the Outbound module. Currently, this API only supports WhatsApp messages. + +This endpoint returns paginated status events for WhatsApp messages sent via the Outbound module, providing +information about delivery state and related message details. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.messages.getWhatsAppMessageStatus({ + ruleset_id: "ruleset_id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.GetWhatsAppMessageStatusRequest` + +
+
+ +
+
+ +**requestOptions:** `Messages.RequestOptions` + +
+
+
+
+ +
+
+
+ +## News + +
client.unstable.news.listNewsItems() -> Intercom.PaginatedResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all news items + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.news.listNewsItems(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `News.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.news.createNewsItem({ ...params }) -> Intercom.NewsItem +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a news item + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.news.createNewsItem({ + title: "Halloween is here!", + body: "

New costumes in store for this spooky season

", + sender_id: 991267834, + state: "live", + deliver_silently: true, + labels: ["Product", "Update", "New"], + reactions: ["\uD83D\uDE06", "\uD83D\uDE05"], + newsfeed_assignments: [ + { + newsfeed_id: 53, + published_at: 1664638214, + }, + ], +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.NewsItemRequest` + +
+
+ +
+
+ +**requestOptions:** `News.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.news.retrieveNewsItem({ ...params }) -> Intercom.NewsItem +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single news item. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.news.retrieveNewsItem({ + id: 1, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.RetrieveNewsItemRequest` + +
+
+ +
+
+ +**requestOptions:** `News.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.news.updateNewsItem({ ...params }) -> Intercom.NewsItem +
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.news.updateNewsItem({ + id: 1, + body: { + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"], + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.UpdateNewsItemRequest` + +
+
+ +
+
+ +**requestOptions:** `News.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.news.deleteNewsItem({ ...params }) -> Intercom.DeletedObject +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete a single news item. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.news.deleteNewsItem({ + id: 1, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DeleteNewsItemRequest` + +
+
+ +
+
+ +**requestOptions:** `News.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.news.listLiveNewsfeedItems({ ...params }) -> Intercom.PaginatedResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all news items that are live on a given newsfeed + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.news.listLiveNewsfeedItems({ + id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ListLiveNewsfeedItemsRequest` + +
+
+ +
+
+ +**requestOptions:** `News.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.news.listNewsfeeds() -> Intercom.PaginatedResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all newsfeeds + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.news.listNewsfeeds(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `News.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.news.retrieveNewsfeed({ ...params }) -> Intercom.Newsfeed +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single newsfeed + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.news.retrieveNewsfeed({ + id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.RetrieveNewsfeedRequest` + +
+
+ +
+
+ +**requestOptions:** `News.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Segments + +
client.unstable.segments.listSegments({ ...params }) -> Intercom.SegmentList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all segments. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.segments.listSegments(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ListSegmentsRequest` + +
+
+ +
+
+ +**requestOptions:** `Segments.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.segments.retrieveSegment({ ...params }) -> Intercom.Segment +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single segment. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.segments.retrieveSegment({ + id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.RetrieveSegmentRequest` + +
+
+ +
+
+ +**requestOptions:** `Segments.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Switch + +
client.unstable.switch.createPhoneSwitch({ ...params }) -> Intercom.PhoneSwitch | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can use the API to deflect phone calls to the Intercom Messenger. +Calling this endpoint will send an SMS with a link to the Messenger to the phone number specified. + +If custom attributes are specified, they will be added to the user or lead's custom data attributes. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.switch.createPhoneSwitch({ + key: "value", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `unknown` + +
+
+ +
+
+ +**requestOptions:** `Switch.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Teams + +
client.unstable.teams.listTeams() -> Intercom.TeamList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +This will return a list of team objects for the App. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.teams.listTeams(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `Teams.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.teams.retrieveTeam({ ...params }) -> Intercom.Team +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single team, containing an array of admins that belong to this team. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.teams.retrieveTeam({ + id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.RetrieveTeamRequest` + +
+
+ +
+
+ +**requestOptions:** `Teams.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Ticket States + +
client.unstable.ticketStates.listTicketStates() -> Intercom.TicketStateList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can get a list of all ticket states for a workspace. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.ticketStates.listTicketStates(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `TicketStates.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Ticket Type Attributes + +
client.unstable.ticketTypeAttributes.createTicketTypeAttribute({ ...params }) -> Intercom.TicketTypeAttribute | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a new attribute for a ticket type. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.ticketTypeAttributes.createTicketTypeAttribute({ + ticket_type_id: "ticket_type_id", + name: "Attribute Title", + description: "Attribute Description", + data_type: "string", + required_to_create: false, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.CreateTicketTypeAttributeRequest` + +
+
+ +
+
+ +**requestOptions:** `TicketTypeAttributes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.ticketTypeAttributes.updateTicketTypeAttribute({ ...params }) -> Intercom.TicketTypeAttribute | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update an existing attribute for a ticket type. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.ticketTypeAttributes.updateTicketTypeAttribute({ + ticket_type_id: "ticket_type_id", + id: "id", + description: "New Attribute Description", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.UpdateTicketTypeAttributeRequest` + +
+
+ +
+
+ +**requestOptions:** `TicketTypeAttributes.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Ticket Types + +
client.unstable.ticketTypes.listTicketTypes() -> Intercom.TicketTypeList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can get a list of all ticket types for a workspace. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.ticketTypes.listTicketTypes(); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `TicketTypes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.ticketTypes.createTicketType({ ...params }) -> Intercom.TicketType | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a new ticket type. + +> 📘 Creating ticket types. +> +> Every ticket type will be created with two default attributes: _default_title_ and _default_description_. +> For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.ticketTypes.createTicketType({ + key: "value", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `unknown` + +
+
+ +
+
+ +**requestOptions:** `TicketTypes.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.ticketTypes.getTicketType({ ...params }) -> Intercom.TicketType | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single ticket type. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.ticketTypes.getTicketType({ + id: "id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.GetTicketTypeRequest` + +
+
+ +
+
+ +**requestOptions:** `TicketTypes.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Tickets + +
client.unstable.tickets.replyTicket({ ...params }) -> Intercom.TicketReply +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can reply to a ticket with a message from an admin or on behalf of a contact, or with a note for admins. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tickets.replyTicket({ + id: "123", + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2971bb69f9f2193bc49", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ReplyTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Tickets.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.tickets.enqueueCreateTicket({ ...params }) -> Intercom.Jobs +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Enqueues ticket creation for asynchronous processing, returning if the job was enqueued successfully to be processed. We attempt to perform a best-effort validation on inputs before tasks are enqueued. If the given parameters are incorrect, we won't enqueue the job. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tickets.enqueueCreateTicket({ + ticket_type_id: "1234", + contacts: [ + { + id: "6762f2d81bb69f9f2193bc54", + }, + ], +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.EnqueueCreateTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Tickets.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.tickets.getTicket({ ...params }) -> Intercom.Ticket | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single ticket. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tickets.getTicket({ + id: "id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.GetTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Tickets.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.tickets.updateTicket({ ...params }) -> Intercom.Ticket | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can update a ticket. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tickets.updateTicket({ + id: "id", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state_id: "123", + open: true, + snoozed_until: 1673609604, + admin_id: 991268011, + assignee_id: "123", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.UpdateTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Tickets.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.tickets.deleteTicket({ ...params }) -> Intercom.DeleteTicketResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete a ticket using the Intercom provided ID. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tickets.deleteTicket({ + id: "id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.DeleteTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `Tickets.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.tickets.searchTickets({ ...params }) -> Intercom.TicketList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can search for multiple tickets by the value of their attributes in order to fetch exactly which ones you want. + +To search for tickets, you send a `POST` request to `https://api.intercom.io/tickets/search`. + +This will accept a query object in the body which will define your filters. +{% admonition type="warning" name="Optimizing search queries" %} +Search queries can be complex, so optimizing them can help the performance of your search. +Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize +pagination to limit the number of results returned. The default is `20` results per page. +See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. +{% /admonition %} + +### Nesting & Limitations + +You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). +There are some limitations to the amount of multiples there can be: + +- There's a limit of max 2 nested filters +- There's a limit of max 15 filters for each AND or OR group + +### Accepted Fields + +Most keys listed as part of the Ticket model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foobar"`). +The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. + +| Field | Type | +| :-------------------- | :------------------------------------------------------------- | +| id | String | +| created_at | Date (UNIX timestamp) | +| updated_at | Date (UNIX timestamp) | +| _default_title_ | String | +| _default_description_ | String | +| category | String | +| ticket_type_id | String | +| contact_ids | String | +| teammate_ids | String | +| admin_assignee_id | String | +| team_assignee_id | String | +| open | Boolean | +| state | String | +| snoozed_until | Date (UNIX timestamp) | +| ticket_attribute.{id} | String or Boolean or Date (UNIX timestamp) or Float or Integer | + +### Accepted Operators + +{% admonition type="info" name="Searching based on `created_at`" %} +You may use the `<=` or `>=` operators to search by `created_at`. +{% /admonition %} + +The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + +| Operator | Valid Types | Description | +| :------- | :---------------------------- | :--------------------------------------------------------- | +| = | All | Equals | +| != | All | Doesn't Equal | +| IN | All | In Shortcut for `OR` queries Values most be in Array | +| NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | +| > | Integer Date (UNIX Timestamp) | Greater (or equal) than | +| < | Integer Date (UNIX Timestamp) | Lower (or equal) than | +| ~ | String | Contains | +| !~ | String | Doesn't Contain | +| ^ | String | Starts With | +| $ | String | Ends With | + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.tickets.searchTickets({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.SearchRequest` + +
+
+ +
+
+ +**requestOptions:** `Tickets.RequestOptions` + +
+
+
+
+ +
+
+
+ +## Visitors + +
client.unstable.visitors.retrieveVisitorWithUserId({ ...params }) -> Intercom.Visitor | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single visitor. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.visitors.retrieveVisitorWithUserId({ + user_id: "user_id", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.RetrieveVisitorWithUserIdRequest` + +
+
+ +
+
+ +**requestOptions:** `Visitors.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.visitors.updateVisitor({ ...params }) -> Intercom.Visitor | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Sending a PUT request to `/visitors` will result in an update of an existing Visitor. + +**Option 1.** You can update a visitor by passing in the `user_id` of the visitor in the Request body. + +**Option 2.** You can update a visitor by passing in the `id` of the visitor in the Request body. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.visitors.updateVisitor({ + id: "6762f30c1bb69f9f2193bc5e", + name: "Gareth Bale", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UpdateVisitorRequestOne` + +
+
+ +
+
+ +**requestOptions:** `Visitors.RequestOptions` + +
+
+
+
+ +
+
+
+ +
client.unstable.visitors.convertVisitor({ ...params }) -> Intercom.Contact +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can merge a Visitor to a Contact of role type `lead` or `user`. + +> 📘 What happens upon a visitor being converted? +> +> If the User exists, then the Visitor will be merged into it, the Visitor deleted and the User returned. If the User does not exist, the Visitor will be converted to a User, with the User identifiers replacing it's Visitor identifiers. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.visitors.convertVisitor({ + type: "user", + user: { + email: "foo@bar.com", + }, + visitor: { + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + }, +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ConvertVisitorRequest` + +
+
+ +
+
+ +**requestOptions:** `Visitors.RequestOptions` + +
+
+
+
+ +
+
+
diff --git a/src/Client.ts b/src/Client.ts index b240ddcb..bdbba22c 100644 --- a/src/Client.ts +++ b/src/Client.ts @@ -23,8 +23,8 @@ import { Teams } from "./api/resources/teams/client/Client"; import { TicketTypes } from "./api/resources/ticketTypes/client/Client"; import { Tickets } from "./api/resources/tickets/client/Client"; import { Visitors } from "./api/resources/visitors/client/Client"; -import { CustomChannelEvents } from "./api/resources/customChannelEvents/client/Client"; import { News } from "./api/resources/news/client/Client"; +import { Unstable } from "./api/resources/unstable/client/Client"; export declare namespace IntercomClient { export interface Options { @@ -107,8 +107,8 @@ export class IntercomClient { protected _ticketTypes: TicketTypes | undefined; protected _tickets: Tickets | undefined; protected _visitors: Visitors | undefined; - protected _customChannelEvents: CustomChannelEvents | undefined; protected _news: News | undefined; + protected _unstable: Unstable | undefined; constructor(protected readonly _options: IntercomClient.Options = {}) {} @@ -188,11 +188,11 @@ export class IntercomClient { return (this._visitors ??= new Visitors(this._options)); } - public get customChannelEvents(): CustomChannelEvents { - return (this._customChannelEvents ??= new CustomChannelEvents(this._options)); - } - public get news(): News { return (this._news ??= new News(this._options)); } + + public get unstable(): Unstable { + return (this._unstable ??= new Unstable(this._options)); + } } diff --git a/src/api/errors/BadRequestError.ts b/src/api/errors/BadRequestError.ts index 34319f60..6d3e423f 100644 --- a/src/api/errors/BadRequestError.ts +++ b/src/api/errors/BadRequestError.ts @@ -3,13 +3,15 @@ */ import * as errors from "../../errors/index"; +import * as core from "../../core"; export class BadRequestError extends errors.IntercomError { - constructor(body?: unknown) { + constructor(body?: unknown, rawResponse?: core.RawResponse) { super({ message: "BadRequestError", statusCode: 400, body: body, + rawResponse: rawResponse, }); Object.setPrototypeOf(this, BadRequestError.prototype); } diff --git a/src/api/errors/ForbiddenError.ts b/src/api/errors/ForbiddenError.ts index 733bdc33..45a3327c 100644 --- a/src/api/errors/ForbiddenError.ts +++ b/src/api/errors/ForbiddenError.ts @@ -4,13 +4,15 @@ import * as errors from "../../errors/index"; import * as Intercom from "../index"; +import * as core from "../../core"; export class ForbiddenError extends errors.IntercomError { - constructor(body: Intercom.Error_) { + constructor(body: Intercom.Error_, rawResponse?: core.RawResponse) { super({ message: "ForbiddenError", statusCode: 403, body: body, + rawResponse: rawResponse, }); Object.setPrototypeOf(this, ForbiddenError.prototype); } diff --git a/src/api/errors/NotFoundError.ts b/src/api/errors/NotFoundError.ts index 27ed057b..e99cdf65 100644 --- a/src/api/errors/NotFoundError.ts +++ b/src/api/errors/NotFoundError.ts @@ -3,13 +3,15 @@ */ import * as errors from "../../errors/index"; +import * as core from "../../core"; export class NotFoundError extends errors.IntercomError { - constructor(body?: unknown) { + constructor(body?: unknown, rawResponse?: core.RawResponse) { super({ message: "NotFoundError", statusCode: 404, body: body, + rawResponse: rawResponse, }); Object.setPrototypeOf(this, NotFoundError.prototype); } diff --git a/src/api/errors/UnauthorizedError.ts b/src/api/errors/UnauthorizedError.ts index dcbab95b..0cafa7ae 100644 --- a/src/api/errors/UnauthorizedError.ts +++ b/src/api/errors/UnauthorizedError.ts @@ -4,13 +4,15 @@ import * as errors from "../../errors/index"; import * as Intercom from "../index"; +import * as core from "../../core"; export class UnauthorizedError extends errors.IntercomError { - constructor(body: Intercom.Error_) { + constructor(body: Intercom.Error_, rawResponse?: core.RawResponse) { super({ message: "UnauthorizedError", statusCode: 401, body: body, + rawResponse: rawResponse, }); Object.setPrototypeOf(this, UnauthorizedError.prototype); } diff --git a/src/api/errors/UnprocessableEntityError.ts b/src/api/errors/UnprocessableEntityError.ts index ac84eaf2..7bb55289 100644 --- a/src/api/errors/UnprocessableEntityError.ts +++ b/src/api/errors/UnprocessableEntityError.ts @@ -3,13 +3,15 @@ */ import * as errors from "../../errors/index"; +import * as core from "../../core"; export class UnprocessableEntityError extends errors.IntercomError { - constructor(body?: unknown) { + constructor(body?: unknown, rawResponse?: core.RawResponse) { super({ message: "UnprocessableEntityError", statusCode: 422, body: body, + rawResponse: rawResponse, }); Object.setPrototypeOf(this, UnprocessableEntityError.prototype); } diff --git a/src/api/resources/admins/client/Client.ts b/src/api/resources/admins/client/Client.ts index 58adcd11..007cc89c 100644 --- a/src/api/resources/admins/client/Client.ts +++ b/src/api/resources/admins/client/Client.ts @@ -88,7 +88,13 @@ export class Admins { * @example * await client.admins.identify() */ - public async identify(requestOptions?: Admins.RequestOptions): Promise { + public identify(requestOptions?: Admins.RequestOptions): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__identify(requestOptions)); + } + + private async __identify( + requestOptions?: Admins.RequestOptions, + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -101,8 +107,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -115,13 +121,14 @@ export class Admins { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.AdminWithApp; + return { data: _response.body as Intercom.AdminWithApp, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } @@ -130,12 +137,14 @@ export class Admins { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /me."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -156,10 +165,17 @@ export class Admins { * away_mode_reassign: true * }) */ - public async away( + public away( request: Intercom.ConfigureAwayAdminRequest, requestOptions?: Admins.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__away(request, requestOptions)); + } + + private async __away( + request: Intercom.ConfigureAwayAdminRequest, + requestOptions?: Admins.RequestOptions, + ): Promise> { const { admin_id: adminId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -173,8 +189,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -188,19 +204,23 @@ export class Admins { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Admin; + return { data: _response.body as Intercom.Admin, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -210,12 +230,14 @@ export class Admins { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /admins/{admin_id}/away."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -234,10 +256,17 @@ export class Admins { * created_at_before: "1677861493" * }) */ - public async listAllActivityLogs( + public listAllActivityLogs( request: Intercom.ListAllActivityLogsRequest, requestOptions?: Admins.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAllActivityLogs(request, requestOptions)); + } + + private async __listAllActivityLogs( + request: Intercom.ListAllActivityLogsRequest, + requestOptions?: Admins.RequestOptions, + ): Promise> { const { created_at_after: createdAtAfter, created_at_before: createdAtBefore } = request; const _queryParams: Record = {}; _queryParams["created_at_after"] = createdAtAfter; @@ -257,8 +286,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -272,17 +301,21 @@ export class Admins { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.ActivityLogList; + return { data: _response.body as Intercom.ActivityLogList, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -292,12 +325,14 @@ export class Admins { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins/activity_logs."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -312,7 +347,11 @@ export class Admins { * @example * await client.admins.list() */ - public async list(requestOptions?: Admins.RequestOptions): Promise { + public list(requestOptions?: Admins.RequestOptions): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__list(requestOptions)); + } + + private async __list(requestOptions?: Admins.RequestOptions): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -325,8 +364,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -339,17 +378,21 @@ export class Admins { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.AdminList; + return { data: _response.body as Intercom.AdminList, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -359,12 +402,14 @@ export class Admins { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -383,10 +428,17 @@ export class Admins { * admin_id: "123" * }) */ - public async find( + public find( + request: Intercom.FindAdminRequest, + requestOptions?: Admins.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( request: Intercom.FindAdminRequest, requestOptions?: Admins.RequestOptions, - ): Promise { + ): Promise> { const { admin_id: adminId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -400,8 +452,8 @@ export class Admins { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -414,19 +466,23 @@ export class Admins { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Admin; + return { data: _response.body as Intercom.Admin, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -436,12 +492,14 @@ export class Admins { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins/{admin_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/articles/client/Client.ts b/src/api/resources/articles/client/Client.ts index f39c3695..78948f01 100644 --- a/src/api/resources/articles/client/Client.ts +++ b/src/api/resources/articles/client/Client.ts @@ -94,72 +94,83 @@ export class Articles { request: Intercom.ListArticlesRequest = {}, requestOptions?: Articles.RequestOptions, ): Promise> { - const list = async (request: Intercom.ListArticlesRequest): Promise => { - const { page, per_page: perPage } = request; - const _queryParams: Record = {}; - if (page != null) { - _queryParams["page"] = page.toString(); - } - if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); - } - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.baseUrl)) ?? - (await core.Supplier.get(this._options.environment)) ?? - environments.IntercomEnvironment.UsProduction, - "articles", - ), - method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return _response.body as Intercom.ArticleList; - } - if (_response.error.reason === "status-code") { - switch (_response.error.statusCode) { - case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); - default: + const list = core.HttpResponsePromise.interceptFunction( + async (request: Intercom.ListArticlesRequest): Promise> => { + const { page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "articles", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: + requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.ArticleList, rawResponse: _response.rawResponse }; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + switch (_response.error.reason) { + case "non-json": throw new errors.IntercomError({ statusCode: _response.error.statusCode, - body: _response.error.body, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } - } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - }); - } - }; + }, + ); let _offset = request?.page != null ? request?.page : 1; + const dataWithRawResponse = await list(request).withRawResponse(); return new core.Pageable({ - response: await list(request), + response: dataWithRawResponse.data, + rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => (response?.data ?? []).length > 0, getItems: (response) => response?.data ?? [], loadPage: (_response) => { @@ -208,10 +219,17 @@ export class Articles { * state: "published" * }) */ - public async create( + public create( request: Intercom.CreateArticleRequest, requestOptions?: Articles.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( + request: Intercom.CreateArticleRequest, + requestOptions?: Articles.RequestOptions, + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -224,8 +242,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -239,19 +257,23 @@ export class Articles { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Article; + return { data: _response.body as Intercom.Article, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 400: - throw new Intercom.BadRequestError(_response.error.body as unknown); + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -261,12 +283,14 @@ export class Articles { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /articles."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -285,10 +309,17 @@ export class Articles { * article_id: "123" * }) */ - public async find( + public find( + request: Intercom.FindArticleRequest, + requestOptions?: Articles.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( request: Intercom.FindArticleRequest, requestOptions?: Articles.RequestOptions, - ): Promise { + ): Promise> { const { article_id: articleId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -302,8 +333,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -316,19 +347,23 @@ export class Articles { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Article; + return { data: _response.body as Intercom.Article, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -338,12 +373,14 @@ export class Articles { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles/{article_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -364,10 +401,17 @@ export class Articles { * body: "

New gifts in store for the jolly season

" * }) */ - public async update( + public update( request: Intercom.UpdateArticleRequest, requestOptions?: Articles.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); + } + + private async __update( + request: Intercom.UpdateArticleRequest, + requestOptions?: Articles.RequestOptions, + ): Promise> { const { article_id: articleId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -381,8 +425,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -396,19 +440,23 @@ export class Articles { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Article; + return { data: _response.body as Intercom.Article, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -418,12 +466,14 @@ export class Articles { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /articles/{article_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -442,10 +492,17 @@ export class Articles { * article_id: "123" * }) */ - public async delete( + public delete( + request: Intercom.DeleteArticleRequest, + requestOptions?: Articles.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__delete(request, requestOptions)); + } + + private async __delete( request: Intercom.DeleteArticleRequest, requestOptions?: Articles.RequestOptions, - ): Promise { + ): Promise> { const { article_id: articleId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -459,8 +516,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -473,19 +530,23 @@ export class Articles { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.DeletedArticleObject; + return { data: _response.body as Intercom.DeletedArticleObject, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -495,12 +556,14 @@ export class Articles { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /articles/{article_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -519,10 +582,17 @@ export class Articles { * state: "published" * }) */ - public async search( + public search( + request: Intercom.SearchArticlesRequest = {}, + requestOptions?: Articles.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__search(request, requestOptions)); + } + + private async __search( request: Intercom.SearchArticlesRequest = {}, requestOptions?: Articles.RequestOptions, - ): Promise { + ): Promise> { const { phrase, state, help_center_id: helpCenterId, highlight } = request; const _queryParams: Record = {}; if (phrase != null) { @@ -553,8 +623,8 @@ export class Articles { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -568,17 +638,21 @@ export class Articles { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.SearchArticlesResponse; + return { data: _response.body as Intercom.SearchArticlesResponse, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -588,12 +662,14 @@ export class Articles { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles/search."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/companies/client/Client.ts b/src/api/resources/companies/client/Client.ts index de1baaf2..5ac7d49b 100644 --- a/src/api/resources/companies/client/Client.ts +++ b/src/api/resources/companies/client/Client.ts @@ -102,10 +102,17 @@ export class Companies { * segment_id: "98765" * }) */ - public async retrieve( + public retrieve( request: Intercom.RetrieveCompanyRequest = {}, requestOptions?: Companies.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieve(request, requestOptions)); + } + + private async __retrieve( + request: Intercom.RetrieveCompanyRequest = {}, + requestOptions?: Companies.RequestOptions, + ): Promise> { const { name, company_id: companyId, tag_id: tagId, segment_id: segmentId, page, per_page: perPage } = request; const _queryParams: Record = {}; if (name != null) { @@ -144,8 +151,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -159,19 +166,23 @@ export class Companies { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.CompaniesRetrieveResponse; + return { data: _response.body as Intercom.CompaniesRetrieveResponse, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -181,12 +192,14 @@ export class Companies { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -218,10 +231,17 @@ export class Companies { * @example * await client.companies.createOrUpdate() */ - public async createOrUpdate( + public createOrUpdate( + request: Intercom.CreateOrUpdateCompanyRequest = {}, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createOrUpdate(request, requestOptions)); + } + + private async __createOrUpdate( request: Intercom.CreateOrUpdateCompanyRequest = {}, requestOptions?: Companies.RequestOptions, - ): Promise { + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -234,8 +254,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -249,19 +269,23 @@ export class Companies { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Company; + return { data: _response.body as Intercom.Company, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 400: - throw new Intercom.BadRequestError(_response.error.body as unknown); + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -271,12 +295,14 @@ export class Companies { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /companies."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -295,10 +321,17 @@ export class Companies { * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" * }) */ - public async find( + public find( request: Intercom.FindCompanyRequest, requestOptions?: Companies.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( + request: Intercom.FindCompanyRequest, + requestOptions?: Companies.RequestOptions, + ): Promise> { const { company_id: companyId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -312,8 +345,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -326,19 +359,23 @@ export class Companies { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Company; + return { data: _response.body as Intercom.Company, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -348,12 +385,14 @@ export class Companies { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/{company_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -376,10 +415,17 @@ export class Companies { * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" * }) */ - public async update( + public update( request: Intercom.UpdateCompanyRequest, requestOptions?: Companies.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); + } + + private async __update( + request: Intercom.UpdateCompanyRequest, + requestOptions?: Companies.RequestOptions, + ): Promise> { const { company_id: companyId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -393,8 +439,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -407,19 +453,23 @@ export class Companies { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Company; + return { data: _response.body as Intercom.Company, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -429,12 +479,14 @@ export class Companies { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /companies/{company_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -453,10 +505,17 @@ export class Companies { * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" * }) */ - public async delete( + public delete( request: Intercom.DeleteCompanyRequest, requestOptions?: Companies.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__delete(request, requestOptions)); + } + + private async __delete( + request: Intercom.DeleteCompanyRequest, + requestOptions?: Companies.RequestOptions, + ): Promise> { const { company_id: companyId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -470,8 +529,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -484,19 +543,23 @@ export class Companies { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.DeletedCompanyObject; + return { data: _response.body as Intercom.DeletedCompanyObject, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -506,12 +569,14 @@ export class Companies { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /companies/{company_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -530,10 +595,17 @@ export class Companies { * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" * }) */ - public async listAttachedContacts( + public listAttachedContacts( + request: Intercom.ListAttachedContactsRequest, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAttachedContacts(request, requestOptions)); + } + + private async __listAttachedContacts( request: Intercom.ListAttachedContactsRequest, requestOptions?: Companies.RequestOptions, - ): Promise { + ): Promise> { const { company_id: companyId, page, per_page: perPage } = request; const _queryParams: Record = {}; if (page != null) { @@ -556,8 +628,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -571,19 +643,23 @@ export class Companies { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.CompanyAttachedContacts; + return { data: _response.body as Intercom.CompanyAttachedContacts, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -593,6 +669,7 @@ export class Companies { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -601,6 +678,7 @@ export class Companies { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -619,10 +697,17 @@ export class Companies { * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" * }) */ - public async listAttachedSegments( + public listAttachedSegments( + request: Intercom.ListSegmentsAttachedToCompanyRequest, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAttachedSegments(request, requestOptions)); + } + + private async __listAttachedSegments( request: Intercom.ListSegmentsAttachedToCompanyRequest, requestOptions?: Companies.RequestOptions, - ): Promise { + ): Promise> { const { company_id: companyId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -636,8 +721,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -650,19 +735,23 @@ export class Companies { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.CompanyAttachedSegments; + return { data: _response.body as Intercom.CompanyAttachedSegments, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -672,6 +761,7 @@ export class Companies { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -680,6 +770,7 @@ export class Companies { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -709,75 +800,86 @@ export class Companies { request: Intercom.ListCompaniesRequest = {}, requestOptions?: Companies.RequestOptions, ): Promise> { - const list = async (request: Intercom.ListCompaniesRequest): Promise => { - const { page, per_page: perPage, order } = request; - const _queryParams: Record = {}; - if (page != null) { - _queryParams["page"] = page.toString(); - } - if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); - } - if (order != null) { - _queryParams["order"] = order; - } - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.baseUrl)) ?? - (await core.Supplier.get(this._options.environment)) ?? - environments.IntercomEnvironment.UsProduction, - "companies/list", - ), - method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return _response.body as Intercom.CompanyList; - } - if (_response.error.reason === "status-code") { - switch (_response.error.statusCode) { - case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); - default: + const list = core.HttpResponsePromise.interceptFunction( + async (request: Intercom.ListCompaniesRequest): Promise> => { + const { page, per_page: perPage, order } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + if (order != null) { + _queryParams["order"] = order; + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "companies/list", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: + requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.CompanyList, rawResponse: _response.rawResponse }; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + switch (_response.error.reason) { + case "non-json": throw new errors.IntercomError({ statusCode: _response.error.statusCode, - body: _response.error.body, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /companies/list."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } - } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /companies/list."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - }); - } - }; + }, + ); let _offset = request?.page != null ? request?.page : 1; + const dataWithRawResponse = await list(request).withRawResponse(); return new core.Pageable({ - response: await list(request), + response: dataWithRawResponse.data, + rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => (response?.data ?? []).length > 0, getItems: (response) => response?.data ?? [], loadPage: (_response) => { @@ -816,68 +918,79 @@ export class Companies { request: Intercom.ScrollCompaniesRequest = {}, requestOptions?: Companies.RequestOptions, ): Promise> { - const list = async (request: Intercom.ScrollCompaniesRequest): Promise => { - const { scroll_param: scrollParam } = request; - const _queryParams: Record = {}; - if (scrollParam != null) { - _queryParams["scroll_param"] = scrollParam; - } - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.baseUrl)) ?? - (await core.Supplier.get(this._options.environment)) ?? - environments.IntercomEnvironment.UsProduction, - "companies/scroll", - ), - method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return _response.body as Intercom.CompanyScroll; - } - if (_response.error.reason === "status-code") { - switch (_response.error.statusCode) { - case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); - default: + const list = core.HttpResponsePromise.interceptFunction( + async (request: Intercom.ScrollCompaniesRequest): Promise> => { + const { scroll_param: scrollParam } = request; + const _queryParams: Record = {}; + if (scrollParam != null) { + _queryParams["scroll_param"] = scrollParam; + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "companies/scroll", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: + requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.CompanyScroll, rawResponse: _response.rawResponse }; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + switch (_response.error.reason) { + case "non-json": throw new errors.IntercomError({ statusCode: _response.error.statusCode, - body: _response.error.body, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/scroll."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } - } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/scroll."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - }); - } - }; + }, + ); + const dataWithRawResponse = await list(request).withRawResponse(); return new core.Pageable({ - response: await list(request), + response: dataWithRawResponse.data, + rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => response?.scroll_param != null, getItems: (response) => response?.data ?? [], loadPage: (response) => { @@ -914,10 +1027,17 @@ export class Companies { * id: "123" * }) */ - public async attachContact( + public attachContact( + request: Intercom.AttachContactToCompanyRequest, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__attachContact(request, requestOptions)); + } + + private async __attachContact( request: Intercom.AttachContactToCompanyRequest, requestOptions?: Companies.RequestOptions, - ): Promise { + ): Promise> { const { contact_id: contactId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -931,8 +1051,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -946,21 +1066,25 @@ export class Companies { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Company; + return { data: _response.body as Intercom.Company, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 400: - throw new Intercom.BadRequestError(_response.error.body as unknown); + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -970,6 +1094,7 @@ export class Companies { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -978,6 +1103,7 @@ export class Companies { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -997,10 +1123,17 @@ export class Companies { * company_id: "58a430d35458202d41b1e65b" * }) */ - public async detachContact( + public detachContact( + request: Intercom.DetachContactFromCompanyRequest, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__detachContact(request, requestOptions)); + } + + private async __detachContact( request: Intercom.DetachContactFromCompanyRequest, requestOptions?: Companies.RequestOptions, - ): Promise { + ): Promise> { const { contact_id: contactId, company_id: companyId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -1014,8 +1147,8 @@ export class Companies { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1028,19 +1161,23 @@ export class Companies { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Company; + return { data: _response.body as Intercom.Company, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -1050,6 +1187,7 @@ export class Companies { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -1058,6 +1196,7 @@ export class Companies { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/contacts/client/Client.ts b/src/api/resources/contacts/client/Client.ts index a932e14b..894de6c9 100644 --- a/src/api/resources/contacts/client/Client.ts +++ b/src/api/resources/contacts/client/Client.ts @@ -93,78 +93,92 @@ export class Contacts { request: Intercom.ListAttachedCompaniesRequest, requestOptions?: Contacts.RequestOptions, ): Promise> { - const list = async ( - request: Intercom.ListAttachedCompaniesRequest, - ): Promise => { - const { contact_id: contactId, page, per_page: perPage } = request; - const _queryParams: Record = {}; - if (page != null) { - _queryParams["page"] = page.toString(); - } - if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); - } - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.baseUrl)) ?? - (await core.Supplier.get(this._options.environment)) ?? - environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/companies`, - ), - method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return _response.body as Intercom.ContactAttachedCompanies; - } - if (_response.error.reason === "status-code") { - switch (_response.error.statusCode) { - case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); - case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); - default: + const list = core.HttpResponsePromise.interceptFunction( + async ( + request: Intercom.ListAttachedCompaniesRequest, + ): Promise> => { + const { contact_id: contactId, page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/companies`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: + requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.ContactAttachedCompanies, + rawResponse: _response.rawResponse, + }; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + switch (_response.error.reason) { + case "non-json": throw new errors.IntercomError({ statusCode: _response.error.statusCode, - body: _response.error.body, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /contacts/{contact_id}/companies.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } - } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /contacts/{contact_id}/companies.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - }); - } - }; + }, + ); let _offset = request?.page != null ? request?.page : 1; + const dataWithRawResponse = await list(request).withRawResponse(); return new core.Pageable({ - response: await list(request), + response: dataWithRawResponse.data, + rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => (response?.companies ?? []).length > 0, getItems: (response) => response?.companies ?? [], loadPage: (_response) => { @@ -188,10 +202,17 @@ export class Contacts { * contact_id: "63a07ddf05a32042dffac965" * }) */ - public async listAttachedSegments( + public listAttachedSegments( + request: Intercom.ListSegmentsAttachedToContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAttachedSegments(request, requestOptions)); + } + + private async __listAttachedSegments( request: Intercom.ListSegmentsAttachedToContactRequest, requestOptions?: Contacts.RequestOptions, - ): Promise { + ): Promise> { const { contact_id: contactId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -205,8 +226,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -219,19 +240,23 @@ export class Contacts { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.ContactSegments; + return { data: _response.body as Intercom.ContactSegments, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -241,6 +266,7 @@ export class Contacts { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -249,6 +275,7 @@ export class Contacts { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -273,10 +300,17 @@ export class Contacts { * contact_id: "63a07ddf05a32042dffac965" * }) */ - public async listAttachedSubscriptions( + public listAttachedSubscriptions( + request: Intercom.ListAttachedSubscriptionsRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAttachedSubscriptions(request, requestOptions)); + } + + private async __listAttachedSubscriptions( request: Intercom.ListAttachedSubscriptionsRequest, requestOptions?: Contacts.RequestOptions, - ): Promise { + ): Promise> { const { contact_id: contactId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -290,8 +324,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -304,19 +338,23 @@ export class Contacts { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.SubscriptionTypeList; + return { data: _response.body as Intercom.SubscriptionTypeList, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -326,6 +364,7 @@ export class Contacts { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -334,6 +373,7 @@ export class Contacts { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -367,10 +407,17 @@ export class Contacts { * consent_type: "opt_in" * }) */ - public async attachSubscription( + public attachSubscription( request: Intercom.AttachSubscriptionToContactRequest, requestOptions?: Contacts.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__attachSubscription(request, requestOptions)); + } + + private async __attachSubscription( + request: Intercom.AttachSubscriptionToContactRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { const { contact_id: contactId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -384,8 +431,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -399,19 +446,23 @@ export class Contacts { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.SubscriptionType; + return { data: _response.body as Intercom.SubscriptionType, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -421,6 +472,7 @@ export class Contacts { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -429,6 +481,7 @@ export class Contacts { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -448,10 +501,17 @@ export class Contacts { * subscription_id: "37846" * }) */ - public async detachSubscription( + public detachSubscription( + request: Intercom.DetachSubscriptionFromContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__detachSubscription(request, requestOptions)); + } + + private async __detachSubscription( request: Intercom.DetachSubscriptionFromContactRequest, requestOptions?: Contacts.RequestOptions, - ): Promise { + ): Promise> { const { contact_id: contactId, subscription_id: subscriptionId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -465,8 +525,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -479,19 +539,23 @@ export class Contacts { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.SubscriptionType; + return { data: _response.body as Intercom.SubscriptionType, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -501,6 +565,7 @@ export class Contacts { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -509,6 +574,7 @@ export class Contacts { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -527,10 +593,17 @@ export class Contacts { * contact_id: "63a07ddf05a32042dffac965" * }) */ - public async listAttachedTags( + public listAttachedTags( + request: Intercom.ListTagsAttachedToContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAttachedTags(request, requestOptions)); + } + + private async __listAttachedTags( request: Intercom.ListTagsAttachedToContactRequest, requestOptions?: Contacts.RequestOptions, - ): Promise { + ): Promise> { const { contact_id: contactId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -544,8 +617,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -558,19 +631,23 @@ export class Contacts { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.TagList; + return { data: _response.body as Intercom.TagList, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -580,12 +657,14 @@ export class Contacts { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts/{contact_id}/tags."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -603,10 +682,17 @@ export class Contacts { * contact_id: "63a07ddf05a32042dffac965" * }) */ - public async find( + public find( request: Intercom.FindContactRequest, requestOptions?: Contacts.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( + request: Intercom.FindContactRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { const { contact_id: contactId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -620,8 +706,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -634,17 +720,21 @@ export class Contacts { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Contact; + return { data: _response.body as Intercom.Contact, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -654,12 +744,14 @@ export class Contacts { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts/{contact_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -679,10 +771,17 @@ export class Contacts { * name: "joe bloggs" * }) */ - public async update( + public update( request: Intercom.UpdateContactRequest, requestOptions?: Contacts.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); + } + + private async __update( + request: Intercom.UpdateContactRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { const { contact_id: contactId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -696,8 +795,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -711,17 +810,21 @@ export class Contacts { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Contact; + return { data: _response.body as Intercom.Contact, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -731,12 +834,14 @@ export class Contacts { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /contacts/{contact_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -754,10 +859,17 @@ export class Contacts { * contact_id: "contact_id" * }) */ - public async delete( + public delete( + request: Intercom.DeleteContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__delete(request, requestOptions)); + } + + private async __delete( request: Intercom.DeleteContactRequest, requestOptions?: Contacts.RequestOptions, - ): Promise { + ): Promise> { const { contact_id: contactId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -771,8 +883,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -785,17 +897,21 @@ export class Contacts { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.ContactDeleted; + return { data: _response.body as Intercom.ContactDeleted, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -805,12 +921,14 @@ export class Contacts { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /contacts/{contact_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -829,10 +947,17 @@ export class Contacts { * into: "667d60ac8a68186f43bafdbc" * }) */ - public async mergeLeadInUser( + public mergeLeadInUser( + request: Intercom.MergeContactsRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__mergeLeadInUser(request, requestOptions)); + } + + private async __mergeLeadInUser( request: Intercom.MergeContactsRequest, requestOptions?: Contacts.RequestOptions, - ): Promise { + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -845,8 +970,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -860,17 +985,21 @@ export class Contacts { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Contact; + return { data: _response.body as Intercom.Contact, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -880,12 +1009,14 @@ export class Contacts { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/merge."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -1015,63 +1146,74 @@ export class Contacts { request: Intercom.SearchRequest, requestOptions?: Contacts.RequestOptions, ): Promise> { - const list = async (request: Intercom.SearchRequest): Promise => { - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.baseUrl)) ?? - (await core.Supplier.get(this._options.environment)) ?? - environments.IntercomEnvironment.UsProduction, - "contacts/search", - ), - method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return _response.body as Intercom.ContactList; - } - if (_response.error.reason === "status-code") { - switch (_response.error.statusCode) { - case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); - default: + const list = core.HttpResponsePromise.interceptFunction( + async (request: Intercom.SearchRequest): Promise> => { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "contacts/search", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: + requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.ContactList, rawResponse: _response.rawResponse }; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + switch (_response.error.reason) { + case "non-json": throw new errors.IntercomError({ statusCode: _response.error.statusCode, - body: _response.error.body, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/search."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } - } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/search."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - }); - } - }; + }, + ); + const dataWithRawResponse = await list(request).withRawResponse(); return new core.Pageable({ - response: await list(request), + response: dataWithRawResponse.data, + rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => response?.pages?.next?.starting_after != null, getItems: (response) => response?.data ?? [], loadPage: (response) => { @@ -1101,74 +1243,85 @@ export class Contacts { request: Intercom.ListContactsRequest = {}, requestOptions?: Contacts.RequestOptions, ): Promise> { - const list = async (request: Intercom.ListContactsRequest): Promise => { - const { page, per_page: perPage, starting_after: startingAfter } = request; - const _queryParams: Record = {}; - if (page != null) { - _queryParams["page"] = page.toString(); - } - if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); - } - if (startingAfter != null) { - _queryParams["starting_after"] = startingAfter; - } - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.baseUrl)) ?? - (await core.Supplier.get(this._options.environment)) ?? - environments.IntercomEnvironment.UsProduction, - "contacts", - ), - method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return _response.body as Intercom.ContactList; - } - if (_response.error.reason === "status-code") { - switch (_response.error.statusCode) { - case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); - default: + const list = core.HttpResponsePromise.interceptFunction( + async (request: Intercom.ListContactsRequest): Promise> => { + const { page, per_page: perPage, starting_after: startingAfter } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + if (startingAfter != null) { + _queryParams["starting_after"] = startingAfter; + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "contacts", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: + requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.ContactList, rawResponse: _response.rawResponse }; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + switch (_response.error.reason) { + case "non-json": throw new errors.IntercomError({ statusCode: _response.error.statusCode, - body: _response.error.body, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } - } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - }); - } - }; + }, + ); + const dataWithRawResponse = await list(request).withRawResponse(); return new core.Pageable({ - response: await list(request), + response: dataWithRawResponse.data, + rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => response?.pages?.next?.starting_after != null, getItems: (response) => response?.data ?? [], loadPage: (response) => { @@ -1190,10 +1343,17 @@ export class Contacts { * email: "joebloggs@intercom.io" * }) */ - public async create( + public create( request: Intercom.CreateContactRequest, requestOptions?: Contacts.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( + request: Intercom.CreateContactRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -1206,8 +1366,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1221,17 +1381,21 @@ export class Contacts { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Contact; + return { data: _response.body as Intercom.Contact, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -1241,12 +1405,14 @@ export class Contacts { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -1262,10 +1428,17 @@ export class Contacts { * contact_id: "63a07ddf05a32042dffac965" * }) */ - public async archive( + public archive( + request: Intercom.ArchiveContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__archive(request, requestOptions)); + } + + private async __archive( request: Intercom.ArchiveContactRequest, requestOptions?: Contacts.RequestOptions, - ): Promise { + ): Promise> { const { contact_id: contactId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -1279,8 +1452,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1293,13 +1466,14 @@ export class Contacts { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.ContactArchived; + return { data: _response.body as Intercom.ContactArchived, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } @@ -1308,6 +1482,7 @@ export class Contacts { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -1316,6 +1491,7 @@ export class Contacts { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -1331,10 +1507,17 @@ export class Contacts { * contact_id: "63a07ddf05a32042dffac965" * }) */ - public async unarchive( + public unarchive( + request: Intercom.UnarchiveContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__unarchive(request, requestOptions)); + } + + private async __unarchive( request: Intercom.UnarchiveContactRequest, requestOptions?: Contacts.RequestOptions, - ): Promise { + ): Promise> { const { contact_id: contactId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -1348,8 +1531,8 @@ export class Contacts { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1362,13 +1545,14 @@ export class Contacts { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.ContactUnarchived; + return { data: _response.body as Intercom.ContactUnarchived, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } @@ -1377,6 +1561,7 @@ export class Contacts { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -1385,6 +1570,7 @@ export class Contacts { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/conversations/client/Client.ts b/src/api/resources/conversations/client/Client.ts index b678ff40..d24ccbfd 100644 --- a/src/api/resources/conversations/client/Client.ts +++ b/src/api/resources/conversations/client/Client.ts @@ -97,75 +97,92 @@ export class Conversations { request: Intercom.ListConversationsRequest = {}, requestOptions?: Conversations.RequestOptions, ): Promise> { - const list = async ( - request: Intercom.ListConversationsRequest, - ): Promise => { - const { per_page: perPage, starting_after: startingAfter } = request; - const _queryParams: Record = {}; - if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); - } - if (startingAfter != null) { - _queryParams["starting_after"] = startingAfter; - } - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.baseUrl)) ?? - (await core.Supplier.get(this._options.environment)) ?? - environments.IntercomEnvironment.UsProduction, - "conversations", - ), - method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return _response.body as Intercom.PaginatedConversationResponse; - } - if (_response.error.reason === "status-code") { - switch (_response.error.statusCode) { - case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); - case 403: - throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); - default: + const list = core.HttpResponsePromise.interceptFunction( + async ( + request: Intercom.ListConversationsRequest, + ): Promise> => { + const { per_page: perPage, starting_after: startingAfter } = request; + const _queryParams: Record = {}; + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + if (startingAfter != null) { + _queryParams["starting_after"] = startingAfter; + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "conversations", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: + requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.PaginatedConversationResponse, + rawResponse: _response.rawResponse, + }; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.ForbiddenError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + switch (_response.error.reason) { + case "non-json": throw new errors.IntercomError({ statusCode: _response.error.statusCode, - body: _response.error.body, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /conversations."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } - } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /conversations."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - }); - } - }; + }, + ); + const dataWithRawResponse = await list(request).withRawResponse(); return new core.Pageable({ - response: await list(request), + response: dataWithRawResponse.data, + rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => response?.pages?.next?.starting_after != null, getItems: (response) => response?.conversations ?? [], loadPage: (response) => { @@ -210,10 +227,17 @@ export class Conversations { * body: "Hello there" * }) */ - public async create( + public create( request: Intercom.CreateConversationRequest, requestOptions?: Conversations.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( + request: Intercom.CreateConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -226,8 +250,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -241,21 +265,25 @@ export class Conversations { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Message; + return { data: _response.body as Intercom.Message, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 403: - throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_, _response.rawResponse); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -265,12 +293,14 @@ export class Conversations { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -300,10 +330,17 @@ export class Conversations { * display_as: "plaintext" * }) */ - public async find( + public find( + request: Intercom.FindConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( request: Intercom.FindConversationRequest, requestOptions?: Conversations.RequestOptions, - ): Promise { + ): Promise> { const { conversation_id: conversationId, display_as: displayAs } = request; const _queryParams: Record = {}; if (displayAs != null) { @@ -322,8 +359,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -337,21 +374,25 @@ export class Conversations { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Conversation; + return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 403: - throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_, _response.rawResponse); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -361,6 +402,7 @@ export class Conversations { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -369,6 +411,7 @@ export class Conversations { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -399,10 +442,17 @@ export class Conversations { * } * }) */ - public async update( + public update( request: Intercom.UpdateConversationRequest, requestOptions?: Conversations.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); + } + + private async __update( + request: Intercom.UpdateConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { const { conversation_id: conversationId, display_as: displayAs, ..._body } = request; const _queryParams: Record = {}; if (displayAs != null) { @@ -421,8 +471,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -437,21 +487,25 @@ export class Conversations { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Conversation; + return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 403: - throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_, _response.rawResponse); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -461,6 +515,7 @@ export class Conversations { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -469,6 +524,7 @@ export class Conversations { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -596,58 +652,73 @@ export class Conversations { request: Intercom.SearchRequest, requestOptions?: Conversations.RequestOptions, ): Promise> { - const list = async (request: Intercom.SearchRequest): Promise => { - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.baseUrl)) ?? - (await core.Supplier.get(this._options.environment)) ?? - environments.IntercomEnvironment.UsProduction, - "conversations/search", - ), - method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return _response.body as Intercom.PaginatedConversationResponse; - } - if (_response.error.reason === "status-code") { - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.body, + const list = core.HttpResponsePromise.interceptFunction( + async ( + request: Intercom.SearchRequest, + ): Promise> => { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "conversations/search", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: + requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, }); - } - switch (_response.error.reason) { - case "non-json": + if (_response.ok) { + return { + data: _response.body as Intercom.PaginatedConversationResponse, + rawResponse: _response.rawResponse, + }; + } + if (_response.error.reason === "status-code") { throw new errors.IntercomError({ statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations/search."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, + body: _response.error.body, + rawResponse: _response.rawResponse, }); - } - }; + } + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /conversations/search.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + }, + ); + const dataWithRawResponse = await list(request).withRawResponse(); return new core.Pageable({ - response: await list(request), + response: dataWithRawResponse.data, + rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => response?.pages?.next?.starting_after != null, getItems: (response) => response?.conversations ?? [], loadPage: (response) => { @@ -712,10 +783,17 @@ export class Conversations { * } * }) */ - public async reply( + public reply( request: Intercom.ReplyToConversationRequest, requestOptions?: Conversations.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__reply(request, requestOptions)); + } + + private async __reply( + request: Intercom.ReplyToConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { const { conversation_id: conversationId, body: _body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -729,8 +807,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -744,21 +822,25 @@ export class Conversations { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Conversation; + return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 403: - throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_, _response.rawResponse); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -768,6 +850,7 @@ export class Conversations { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -776,6 +859,7 @@ export class Conversations { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -834,10 +918,17 @@ export class Conversations { * } * }) */ - public async manage( + public manage( request: Intercom.ManageConversationPartsRequest, requestOptions?: Conversations.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__manage(request, requestOptions)); + } + + private async __manage( + request: Intercom.ManageConversationPartsRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { const { conversation_id: conversationId, body: _body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -851,8 +942,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -866,21 +957,25 @@ export class Conversations { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Conversation; + return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 403: - throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_, _response.rawResponse); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -890,6 +985,7 @@ export class Conversations { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -898,6 +994,7 @@ export class Conversations { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -923,10 +1020,17 @@ export class Conversations { * conversation_id: "123" * }) */ - public async runAssignmentRules( + public runAssignmentRules( + request: Intercom.AutoAssignConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__runAssignmentRules(request, requestOptions)); + } + + private async __runAssignmentRules( request: Intercom.AutoAssignConversationRequest, requestOptions?: Conversations.RequestOptions, - ): Promise { + ): Promise> { const { conversation_id: conversationId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -940,8 +1044,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -954,21 +1058,25 @@ export class Conversations { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Conversation; + return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 403: - throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_, _response.rawResponse); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -978,6 +1086,7 @@ export class Conversations { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -986,6 +1095,7 @@ export class Conversations { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -1022,10 +1132,17 @@ export class Conversations { * } * }) */ - public async attachContactAsAdmin( + public attachContactAsAdmin( + request: Intercom.AttachContactToConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__attachContactAsAdmin(request, requestOptions)); + } + + private async __attachContactAsAdmin( request: Intercom.AttachContactToConversationRequest, requestOptions?: Conversations.RequestOptions, - ): Promise { + ): Promise> { const { conversation_id: conversationId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -1039,8 +1156,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1054,21 +1171,25 @@ export class Conversations { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Conversation; + return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 403: - throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_, _response.rawResponse); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -1078,6 +1199,7 @@ export class Conversations { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -1086,6 +1208,7 @@ export class Conversations { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -1112,10 +1235,17 @@ export class Conversations { * admin_id: "5017690" * }) */ - public async detachContactAsAdmin( + public detachContactAsAdmin( request: Intercom.DetachContactFromConversationRequest, requestOptions?: Conversations.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__detachContactAsAdmin(request, requestOptions)); + } + + private async __detachContactAsAdmin( + request: Intercom.DetachContactFromConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { const { conversation_id: conversationId, contact_id: contactId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -1129,8 +1259,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1144,23 +1274,27 @@ export class Conversations { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Conversation; + return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 403: - throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_, _response.rawResponse); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); case 422: - throw new Intercom.UnprocessableEntityError(_response.error.body as unknown); + throw new Intercom.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -1170,6 +1304,7 @@ export class Conversations { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -1178,6 +1313,7 @@ export class Conversations { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -1209,10 +1345,17 @@ export class Conversations { * conversation_part_id: "really_123_doesnt_exist" * }) */ - public async redactConversationPart( + public redactConversationPart( + request: Intercom.RedactConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__redactConversationPart(request, requestOptions)); + } + + private async __redactConversationPart( request: Intercom.RedactConversationRequest, requestOptions?: Conversations.RequestOptions, - ): Promise { + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -1225,8 +1368,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1240,19 +1383,23 @@ export class Conversations { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Conversation; + return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -1262,12 +1409,14 @@ export class Conversations { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations/redact."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -1292,10 +1441,17 @@ export class Conversations { * ticket_type_id: "80" * }) */ - public async convertToTicket( + public convertToTicket( + request: Intercom.ConvertConversationToTicketRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__convertToTicket(request, requestOptions)); + } + + private async __convertToTicket( request: Intercom.ConvertConversationToTicketRequest, requestOptions?: Conversations.RequestOptions, - ): Promise { + ): Promise> { const { conversation_id: conversationId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -1309,8 +1465,8 @@ export class Conversations { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -1324,17 +1480,18 @@ export class Conversations { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Ticket; + return { data: _response.body as Intercom.Ticket, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 400: - throw new Intercom.BadRequestError(_response.error.body as unknown); + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -1344,6 +1501,7 @@ export class Conversations { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -1352,6 +1510,7 @@ export class Conversations { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/dataAttributes/client/Client.ts b/src/api/resources/dataAttributes/client/Client.ts index fe06c4fe..cd6b4d7e 100644 --- a/src/api/resources/dataAttributes/client/Client.ts +++ b/src/api/resources/dataAttributes/client/Client.ts @@ -86,10 +86,17 @@ export class DataAttributes { * @example * await client.dataAttributes.list() */ - public async list( + public list( request: Intercom.ListDataAttributesRequest = {}, requestOptions?: DataAttributes.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__list(request, requestOptions)); + } + + private async __list( + request: Intercom.ListDataAttributesRequest = {}, + requestOptions?: DataAttributes.RequestOptions, + ): Promise> { const { model, include_archived: includeArchived } = request; const _queryParams: Record = {}; if (model != null) { @@ -112,8 +119,8 @@ export class DataAttributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -127,17 +134,21 @@ export class DataAttributes { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.DataAttributeList; + return { data: _response.body as Intercom.DataAttributeList, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -147,12 +158,14 @@ export class DataAttributes { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /data_attributes."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -210,10 +223,17 @@ export class DataAttributes { * options: ["options"] * }) */ - public async create( + public create( + request: Intercom.CreateDataAttributeRequest, + requestOptions?: DataAttributes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( request: Intercom.CreateDataAttributeRequest, requestOptions?: DataAttributes.RequestOptions, - ): Promise { + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -226,8 +246,8 @@ export class DataAttributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -241,19 +261,23 @@ export class DataAttributes { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.DataAttribute; + return { data: _response.body as Intercom.DataAttribute, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 400: - throw new Intercom.BadRequestError(_response.error.body as unknown); + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -263,12 +287,14 @@ export class DataAttributes { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /data_attributes."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -320,10 +346,17 @@ export class DataAttributes { * description: "Trying to archieve" * }) */ - public async update( + public update( + request: Intercom.UpdateDataAttributeRequest, + requestOptions?: DataAttributes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); + } + + private async __update( request: Intercom.UpdateDataAttributeRequest, requestOptions?: DataAttributes.RequestOptions, - ): Promise { + ): Promise> { const { data_attribute_id: dataAttributeId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -337,8 +370,8 @@ export class DataAttributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -352,23 +385,27 @@ export class DataAttributes { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.DataAttribute; + return { data: _response.body as Intercom.DataAttribute, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 400: - throw new Intercom.BadRequestError(_response.error.body as unknown); + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); case 422: - throw new Intercom.UnprocessableEntityError(_response.error.body as unknown); + throw new Intercom.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -378,6 +415,7 @@ export class DataAttributes { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -386,6 +424,7 @@ export class DataAttributes { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/dataExport/client/Client.ts b/src/api/resources/dataExport/client/Client.ts index f4c041aa..72d82c09 100644 --- a/src/api/resources/dataExport/client/Client.ts +++ b/src/api/resources/dataExport/client/Client.ts @@ -101,10 +101,17 @@ export class DataExport { * created_at_before: 1719492967 * }) */ - public async create( + public create( request: Intercom.CreateDataExportRequest, requestOptions?: DataExport.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( + request: Intercom.CreateDataExportRequest, + requestOptions?: DataExport.RequestOptions, + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -117,8 +124,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -132,13 +139,14 @@ export class DataExport { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.DataExport; + return { data: _response.body as Intercom.DataExport, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } @@ -147,12 +155,14 @@ export class DataExport { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /export/content/data."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -172,10 +182,17 @@ export class DataExport { * job_identifier: "job_identifier" * }) */ - public async find( + public find( + request: Intercom.FindDataExportRequest, + requestOptions?: DataExport.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( request: Intercom.FindDataExportRequest, requestOptions?: DataExport.RequestOptions, - ): Promise { + ): Promise> { const { job_identifier: jobIdentifier } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -189,8 +206,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -203,13 +220,14 @@ export class DataExport { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.DataExport; + return { data: _response.body as Intercom.DataExport, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } @@ -218,6 +236,7 @@ export class DataExport { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -226,6 +245,7 @@ export class DataExport { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -241,10 +261,17 @@ export class DataExport { * job_identifier: "job_identifier" * }) */ - public async cancel( + public cancel( request: Intercom.CancelDataExportRequest, requestOptions?: DataExport.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__cancel(request, requestOptions)); + } + + private async __cancel( + request: Intercom.CancelDataExportRequest, + requestOptions?: DataExport.RequestOptions, + ): Promise> { const { job_identifier: jobIdentifier } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -258,8 +285,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -272,13 +299,14 @@ export class DataExport { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.DataExport; + return { data: _response.body as Intercom.DataExport, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } @@ -287,6 +315,7 @@ export class DataExport { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -295,6 +324,7 @@ export class DataExport { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -316,10 +346,17 @@ export class DataExport { * job_identifier: "job_identifier" * }) */ - public async download( + public download( + request: Intercom.DownloadDataExportRequest, + requestOptions?: DataExport.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__download(request, requestOptions)); + } + + private async __download( request: Intercom.DownloadDataExportRequest, requestOptions?: DataExport.RequestOptions, - ): Promise { + ): Promise> { const { job_identifier: jobIdentifier } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -333,8 +370,8 @@ export class DataExport { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -347,13 +384,14 @@ export class DataExport { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return; + return { data: undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } @@ -362,6 +400,7 @@ export class DataExport { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -370,6 +409,7 @@ export class DataExport { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/events/client/Client.ts b/src/api/resources/events/client/Client.ts index 3b8c96f7..a51cd863 100644 --- a/src/api/resources/events/client/Client.ts +++ b/src/api/resources/events/client/Client.ts @@ -98,10 +98,17 @@ export class Events { * type: "type" * }) */ - public async list( + public list( request: Intercom.ListEventsRequest, requestOptions?: Events.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__list(request, requestOptions)); + } + + private async __list( + request: Intercom.ListEventsRequest, + requestOptions?: Events.RequestOptions, + ): Promise> { const { user_id: userId, intercom_user_id: intercomUserId, @@ -144,8 +151,8 @@ export class Events { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -159,17 +166,21 @@ export class Events { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.DataEventSummary; + return { data: _response.body as Intercom.DataEventSummary, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -179,12 +190,14 @@ export class Events { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /events."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -244,10 +257,17 @@ export class Events { * created_at: 1671028894 * }) */ - public async create( + public create( + request: Intercom.CreateDataEventRequest, + requestOptions?: Events.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( request: Intercom.CreateDataEventRequest, requestOptions?: Events.RequestOptions, - ): Promise { + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -260,8 +280,8 @@ export class Events { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -275,17 +295,21 @@ export class Events { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return; + return { data: undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -295,12 +319,14 @@ export class Events { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /events."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -316,10 +342,17 @@ export class Events { * @example * await client.events.summaries() */ - public async summaries( + public summaries( + request: Intercom.ListEventSummariesRequest = {}, + requestOptions?: Events.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__summaries(request, requestOptions)); + } + + private async __summaries( request: Intercom.ListEventSummariesRequest = {}, requestOptions?: Events.RequestOptions, - ): Promise { + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -332,8 +365,8 @@ export class Events { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -347,17 +380,21 @@ export class Events { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return; + return { data: undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -367,12 +404,14 @@ export class Events { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /events/summaries."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/helpCenters/client/Client.ts b/src/api/resources/helpCenters/client/Client.ts index 523ddf97..f8a1cf28 100644 --- a/src/api/resources/helpCenters/client/Client.ts +++ b/src/api/resources/helpCenters/client/Client.ts @@ -93,10 +93,17 @@ export class HelpCenters { * help_center_id: "123" * }) */ - public async find( + public find( request: Intercom.FindHelpCenterRequest, requestOptions?: HelpCenters.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( + request: Intercom.FindHelpCenterRequest, + requestOptions?: HelpCenters.RequestOptions, + ): Promise> { const { help_center_id: helpCenterId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -110,8 +117,8 @@ export class HelpCenters { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -124,19 +131,23 @@ export class HelpCenters { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.HelpCenter; + return { data: _response.body as Intercom.HelpCenter, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -146,6 +157,7 @@ export class HelpCenters { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -154,6 +166,7 @@ export class HelpCenters { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -173,74 +186,87 @@ export class HelpCenters { request: Intercom.ListHelpCentersRequest = {}, requestOptions?: HelpCenters.RequestOptions, ): Promise> { - const list = async (request: Intercom.ListHelpCentersRequest): Promise => { - const { page, per_page: perPage } = request; - const _queryParams: Record = {}; - if (page != null) { - _queryParams["page"] = page.toString(); - } - if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); - } - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.baseUrl)) ?? - (await core.Supplier.get(this._options.environment)) ?? - environments.IntercomEnvironment.UsProduction, - "help_center/help_centers", - ), - method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return _response.body as Intercom.HelpCenterList; - } - if (_response.error.reason === "status-code") { - switch (_response.error.statusCode) { - case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); - default: + const list = core.HttpResponsePromise.interceptFunction( + async ( + request: Intercom.ListHelpCentersRequest, + ): Promise> => { + const { page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "help_center/help_centers", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: + requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.HelpCenterList, rawResponse: _response.rawResponse }; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + switch (_response.error.reason) { + case "non-json": throw new errors.IntercomError({ statusCode: _response.error.statusCode, - body: _response.error.body, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /help_center/help_centers.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } - } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /help_center/help_centers.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - }); - } - }; + }, + ); let _offset = request?.page != null ? request?.page : 1; + const dataWithRawResponse = await list(request).withRawResponse(); return new core.Pageable({ - response: await list(request), + response: dataWithRawResponse.data, + rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => (response?.data ?? []).length > 0, getItems: (response) => response?.data ?? [], loadPage: (_response) => { diff --git a/src/api/resources/helpCenters/resources/collections/client/Client.ts b/src/api/resources/helpCenters/resources/collections/client/Client.ts index e5b4fb85..b123a0c1 100644 --- a/src/api/resources/helpCenters/resources/collections/client/Client.ts +++ b/src/api/resources/helpCenters/resources/collections/client/Client.ts @@ -89,74 +89,87 @@ export class Collections { request: Intercom.helpCenters.ListCollectionsRequest = {}, requestOptions?: Collections.RequestOptions, ): Promise> { - const list = async (request: Intercom.helpCenters.ListCollectionsRequest): Promise => { - const { page, per_page: perPage } = request; - const _queryParams: Record = {}; - if (page != null) { - _queryParams["page"] = page.toString(); - } - if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); - } - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.baseUrl)) ?? - (await core.Supplier.get(this._options.environment)) ?? - environments.IntercomEnvironment.UsProduction, - "help_center/collections", - ), - method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return _response.body as Intercom.CollectionList; - } - if (_response.error.reason === "status-code") { - switch (_response.error.statusCode) { - case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); - default: + const list = core.HttpResponsePromise.interceptFunction( + async ( + request: Intercom.helpCenters.ListCollectionsRequest, + ): Promise> => { + const { page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "help_center/collections", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: + requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.CollectionList, rawResponse: _response.rawResponse }; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + switch (_response.error.reason) { + case "non-json": throw new errors.IntercomError({ statusCode: _response.error.statusCode, - body: _response.error.body, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /help_center/collections.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } - } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /help_center/collections.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - }); - } - }; + }, + ); let _offset = request?.page != null ? request?.page : 1; + const dataWithRawResponse = await list(request).withRawResponse(); return new core.Pageable({ - response: await list(request), + response: dataWithRawResponse.data, + rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => (response?.data ?? []).length > 0, getItems: (response) => response?.data ?? [], loadPage: (_response) => { @@ -186,10 +199,17 @@ export class Collections { * description: "Missing required parameter" * }) */ - public async create( + public create( request: Intercom.helpCenters.CreateCollectionRequest, requestOptions?: Collections.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( + request: Intercom.helpCenters.CreateCollectionRequest, + requestOptions?: Collections.RequestOptions, + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -202,8 +222,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -217,19 +237,23 @@ export class Collections { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Collection; + return { data: _response.body as Intercom.Collection, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 400: - throw new Intercom.BadRequestError(_response.error.body as unknown); + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -239,12 +263,14 @@ export class Collections { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /help_center/collections."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -263,10 +289,17 @@ export class Collections { * collection_id: "123" * }) */ - public async find( + public find( request: Intercom.helpCenters.FindCollectionRequest, requestOptions?: Collections.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( + request: Intercom.helpCenters.FindCollectionRequest, + requestOptions?: Collections.RequestOptions, + ): Promise> { const { collection_id: collectionId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -280,8 +313,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -294,19 +327,23 @@ export class Collections { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Collection; + return { data: _response.body as Intercom.Collection, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -316,6 +353,7 @@ export class Collections { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -324,6 +362,7 @@ export class Collections { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -343,10 +382,17 @@ export class Collections { * name: "Update collection name" * }) */ - public async update( + public update( request: Intercom.helpCenters.UpdateCollectionRequest, requestOptions?: Collections.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); + } + + private async __update( + request: Intercom.helpCenters.UpdateCollectionRequest, + requestOptions?: Collections.RequestOptions, + ): Promise> { const { collection_id: collectionId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -360,8 +406,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -375,19 +421,23 @@ export class Collections { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Collection; + return { data: _response.body as Intercom.Collection, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -397,6 +447,7 @@ export class Collections { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -405,6 +456,7 @@ export class Collections { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -423,10 +475,17 @@ export class Collections { * collection_id: "123" * }) */ - public async delete( + public delete( request: Intercom.helpCenters.DeleteCollectionRequest, requestOptions?: Collections.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__delete(request, requestOptions)); + } + + private async __delete( + request: Intercom.helpCenters.DeleteCollectionRequest, + requestOptions?: Collections.RequestOptions, + ): Promise> { const { collection_id: collectionId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -440,8 +499,8 @@ export class Collections { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -454,19 +513,23 @@ export class Collections { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.DeletedCollectionObject; + return { data: _response.body as Intercom.DeletedCollectionObject, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -476,6 +539,7 @@ export class Collections { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -484,6 +548,7 @@ export class Collections { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/index.ts b/src/api/resources/index.ts index 3e1d913c..7761ecb9 100644 --- a/src/api/resources/index.ts +++ b/src/api/resources/index.ts @@ -36,12 +36,12 @@ export * as dataEvents from "./dataEvents"; export * from "./dataEvents/types"; export * as news from "./news"; export * from "./news/types"; +export * as unstable from "./unstable"; export * as helpCenters from "./helpCenters"; export * as events from "./events"; export * as phoneCallRedirects from "./phoneCallRedirects"; export * as ticketTypes from "./ticketTypes"; export * as visitors from "./visitors"; -export * as customChannelEvents from "./customChannelEvents"; export * from "./admins/client/requests"; export * from "./articles/client/requests"; export * from "./helpCenters/client/requests"; diff --git a/src/api/resources/messages/client/Client.ts b/src/api/resources/messages/client/Client.ts index 97ff5961..9fd4d027 100644 --- a/src/api/resources/messages/client/Client.ts +++ b/src/api/resources/messages/client/Client.ts @@ -166,10 +166,17 @@ export class Messages { * create_conversation_without_contact_reply: true * }) */ - public async create( + public create( request: Intercom.CreateMessageRequest, requestOptions?: Messages.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( + request: Intercom.CreateMessageRequest, + requestOptions?: Messages.RequestOptions, + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -182,8 +189,8 @@ export class Messages { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -197,23 +204,27 @@ export class Messages { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Message; + return { data: _response.body as Intercom.Message, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 400: - throw new Intercom.BadRequestError(_response.error.body as unknown); + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 403: - throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_); + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_, _response.rawResponse); case 422: - throw new Intercom.UnprocessableEntityError(_response.error.body as unknown); + throw new Intercom.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -223,12 +234,14 @@ export class Messages { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /messages."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/news/resources/feeds/client/Client.ts b/src/api/resources/news/resources/feeds/client/Client.ts index 35a6e147..7af908b2 100644 --- a/src/api/resources/news/resources/feeds/client/Client.ts +++ b/src/api/resources/news/resources/feeds/client/Client.ts @@ -85,10 +85,17 @@ export class Feeds { * newsfeed_id: "123" * }) */ - public async listItems( + public listItems( request: Intercom.news.ListNewsFeedItemsRequest, requestOptions?: Feeds.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listItems(request, requestOptions)); + } + + private async __listItems( + request: Intercom.news.ListNewsFeedItemsRequest, + requestOptions?: Feeds.RequestOptions, + ): Promise> { const { newsfeed_id: newsfeedId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -102,8 +109,8 @@ export class Feeds { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -116,17 +123,21 @@ export class Feeds { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.PaginatedNewsItemResponse; + return { data: _response.body as Intercom.PaginatedNewsItemResponse, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -136,6 +147,7 @@ export class Feeds { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -144,6 +156,7 @@ export class Feeds { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -158,7 +171,13 @@ export class Feeds { * @example * await client.news.feeds.list() */ - public async list(requestOptions?: Feeds.RequestOptions): Promise { + public list(requestOptions?: Feeds.RequestOptions): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__list(requestOptions)); + } + + private async __list( + requestOptions?: Feeds.RequestOptions, + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -171,8 +190,8 @@ export class Feeds { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -185,17 +204,21 @@ export class Feeds { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.PaginatedNewsfeedResponse; + return { data: _response.body as Intercom.PaginatedNewsfeedResponse, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -205,12 +228,14 @@ export class Feeds { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/newsfeeds."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -228,10 +253,17 @@ export class Feeds { * newsfeed_id: "123" * }) */ - public async find( + public find( + request: Intercom.news.FindNewsFeedRequest, + requestOptions?: Feeds.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( request: Intercom.news.FindNewsFeedRequest, requestOptions?: Feeds.RequestOptions, - ): Promise { + ): Promise> { const { newsfeed_id: newsfeedId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -245,8 +277,8 @@ export class Feeds { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -259,17 +291,21 @@ export class Feeds { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Newsfeed; + return { data: _response.body as Intercom.Newsfeed, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -279,6 +315,7 @@ export class Feeds { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -287,6 +324,7 @@ export class Feeds { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/news/resources/items/client/Client.ts b/src/api/resources/news/resources/items/client/Client.ts index 7321ae29..2dc9fa97 100644 --- a/src/api/resources/news/resources/items/client/Client.ts +++ b/src/api/resources/news/resources/items/client/Client.ts @@ -82,7 +82,13 @@ export class Items { * @example * await client.news.items.list() */ - public async list(requestOptions?: Items.RequestOptions): Promise { + public list(requestOptions?: Items.RequestOptions): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__list(requestOptions)); + } + + private async __list( + requestOptions?: Items.RequestOptions, + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -95,8 +101,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -109,17 +115,21 @@ export class Items { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.PaginatedNewsItemResponse; + return { data: _response.body as Intercom.PaginatedNewsItemResponse, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -129,12 +139,14 @@ export class Items { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/news_items."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -162,10 +174,17 @@ export class Items { * }] * }) */ - public async create( + public create( + request: Intercom.NewsItemRequest, + requestOptions?: Items.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( request: Intercom.NewsItemRequest, requestOptions?: Items.RequestOptions, - ): Promise { + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -178,8 +197,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -193,17 +212,21 @@ export class Items { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.NewsItem; + return { data: _response.body as Intercom.NewsItem, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -213,12 +236,14 @@ export class Items { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /news/news_items."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -237,10 +262,17 @@ export class Items { * news_item_id: "123" * }) */ - public async find( + public find( request: Intercom.news.FindNewsItemRequest, requestOptions?: Items.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( + request: Intercom.news.FindNewsItemRequest, + requestOptions?: Items.RequestOptions, + ): Promise> { const { news_item_id: newsItemId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -254,8 +286,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -268,19 +300,23 @@ export class Items { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.NewsItem; + return { data: _response.body as Intercom.NewsItem, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -290,6 +326,7 @@ export class Items { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -298,6 +335,7 @@ export class Items { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -331,10 +369,17 @@ export class Items { * } * }) */ - public async update( + public update( + request: Intercom.news.UpdateNewsItemRequest, + requestOptions?: Items.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); + } + + private async __update( request: Intercom.news.UpdateNewsItemRequest, requestOptions?: Items.RequestOptions, - ): Promise { + ): Promise> { const { news_item_id: newsItemId, body: _body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -348,8 +393,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -363,19 +408,23 @@ export class Items { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.NewsItem; + return { data: _response.body as Intercom.NewsItem, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -385,6 +434,7 @@ export class Items { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -393,6 +443,7 @@ export class Items { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -411,10 +462,17 @@ export class Items { * news_item_id: "123" * }) */ - public async delete( + public delete( + request: Intercom.news.DeleteNewsItemRequest, + requestOptions?: Items.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__delete(request, requestOptions)); + } + + private async __delete( request: Intercom.news.DeleteNewsItemRequest, requestOptions?: Items.RequestOptions, - ): Promise { + ): Promise> { const { news_item_id: newsItemId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -428,8 +486,8 @@ export class Items { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -442,19 +500,23 @@ export class Items { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.DeletedObject; + return { data: _response.body as Intercom.DeletedObject, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -464,6 +526,7 @@ export class Items { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -472,6 +535,7 @@ export class Items { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/notes/client/Client.ts b/src/api/resources/notes/client/Client.ts index a7307111..44866b02 100644 --- a/src/api/resources/notes/client/Client.ts +++ b/src/api/resources/notes/client/Client.ts @@ -92,74 +92,82 @@ export class Notes { request: Intercom.ListContactNotesRequest, requestOptions?: Notes.RequestOptions, ): Promise> { - const list = async (request: Intercom.ListContactNotesRequest): Promise => { - const { contact_id: contactId, page, per_page: perPage } = request; - const _queryParams: Record = {}; - if (page != null) { - _queryParams["page"] = page.toString(); - } - if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); - } - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.baseUrl)) ?? - (await core.Supplier.get(this._options.environment)) ?? - environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/notes`, - ), - method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return _response.body as Intercom.NoteList; - } - if (_response.error.reason === "status-code") { - switch (_response.error.statusCode) { - case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); - default: + const list = core.HttpResponsePromise.interceptFunction( + async (request: Intercom.ListContactNotesRequest): Promise> => { + const { contact_id: contactId, page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/notes`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: + requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.NoteList, rawResponse: _response.rawResponse }; + } + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + switch (_response.error.reason) { + case "non-json": throw new errors.IntercomError({ statusCode: _response.error.statusCode, - body: _response.error.body, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /contacts/{contact_id}/notes.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } - } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /contacts/{contact_id}/notes.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - }); - } - }; + }, + ); let _offset = request?.page != null ? request?.page : 1; + const dataWithRawResponse = await list(request).withRawResponse(); return new core.Pageable({ - response: await list(request), + response: dataWithRawResponse.data, + rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => (response?.data ?? []).length > 0, getItems: (response) => response?.data ?? [], loadPage: (_response) => { @@ -184,10 +192,17 @@ export class Notes { * admin_id: "123" * }) */ - public async create( + public create( + request: Intercom.CreateContactNoteRequest, + requestOptions?: Notes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( request: Intercom.CreateContactNoteRequest, requestOptions?: Notes.RequestOptions, - ): Promise { + ): Promise> { const { contact_id: contactId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -201,8 +216,8 @@ export class Notes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -216,17 +231,18 @@ export class Notes { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Note; + return { data: _response.body as Intercom.Note, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -236,6 +252,7 @@ export class Notes { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -244,6 +261,7 @@ export class Notes { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -262,10 +280,17 @@ export class Notes { * note_id: "1" * }) */ - public async find( + public find( request: Intercom.FindNoteRequest, requestOptions?: Notes.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( + request: Intercom.FindNoteRequest, + requestOptions?: Notes.RequestOptions, + ): Promise> { const { note_id: noteId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -279,8 +304,8 @@ export class Notes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -293,19 +318,23 @@ export class Notes { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Note; + return { data: _response.body as Intercom.Note, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -315,12 +344,14 @@ export class Notes { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /notes/{note_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/phoneCallRedirects/client/Client.ts b/src/api/resources/phoneCallRedirects/client/Client.ts index c9b53a74..2c057d93 100644 --- a/src/api/resources/phoneCallRedirects/client/Client.ts +++ b/src/api/resources/phoneCallRedirects/client/Client.ts @@ -103,10 +103,17 @@ export class PhoneCallRedirects { * } * }) */ - public async create( + public create( request: Intercom.CreatePhoneCallRedirectRequest, requestOptions?: PhoneCallRedirects.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( + request: Intercom.CreatePhoneCallRedirectRequest, + requestOptions?: PhoneCallRedirects.RequestOptions, + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -119,8 +126,8 @@ export class PhoneCallRedirects { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -134,21 +141,25 @@ export class PhoneCallRedirects { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.PhoneSwitch; + return { data: _response.body as Intercom.PhoneSwitch, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 400: - throw new Intercom.BadRequestError(_response.error.body as unknown); + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 422: - throw new Intercom.UnprocessableEntityError(_response.error.body as unknown); + throw new Intercom.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -158,12 +169,14 @@ export class PhoneCallRedirects { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /phone_call_redirects."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/segments/client/Client.ts b/src/api/resources/segments/client/Client.ts index cc2d5ea6..738a10b7 100644 --- a/src/api/resources/segments/client/Client.ts +++ b/src/api/resources/segments/client/Client.ts @@ -86,10 +86,17 @@ export class Segments { * @example * await client.segments.list() */ - public async list( + public list( request: Intercom.ListSegmentsRequest = {}, requestOptions?: Segments.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__list(request, requestOptions)); + } + + private async __list( + request: Intercom.ListSegmentsRequest = {}, + requestOptions?: Segments.RequestOptions, + ): Promise> { const { include_count: includeCount } = request; const _queryParams: Record = {}; if (includeCount != null) { @@ -108,8 +115,8 @@ export class Segments { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -123,17 +130,21 @@ export class Segments { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.SegmentList; + return { data: _response.body as Intercom.SegmentList, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -143,12 +154,14 @@ export class Segments { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /segments."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -167,10 +180,17 @@ export class Segments { * segment_id: "123" * }) */ - public async find( + public find( + request: Intercom.FindSegmentRequest, + requestOptions?: Segments.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( request: Intercom.FindSegmentRequest, requestOptions?: Segments.RequestOptions, - ): Promise { + ): Promise> { const { segment_id: segmentId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -184,8 +204,8 @@ export class Segments { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -198,19 +218,23 @@ export class Segments { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Segment; + return { data: _response.body as Intercom.Segment, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -220,12 +244,14 @@ export class Segments { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /segments/{segment_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/subscriptionTypes/client/Client.ts b/src/api/resources/subscriptionTypes/client/Client.ts index b07d4e1e..abfe8aa7 100644 --- a/src/api/resources/subscriptionTypes/client/Client.ts +++ b/src/api/resources/subscriptionTypes/client/Client.ts @@ -85,7 +85,15 @@ export class SubscriptionTypes { * @example * await client.subscriptionTypes.list() */ - public async list(requestOptions?: SubscriptionTypes.RequestOptions): Promise { + public list( + requestOptions?: SubscriptionTypes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__list(requestOptions)); + } + + private async __list( + requestOptions?: SubscriptionTypes.RequestOptions, + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -98,8 +106,8 @@ export class SubscriptionTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -112,17 +120,21 @@ export class SubscriptionTypes { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.SubscriptionTypeList; + return { data: _response.body as Intercom.SubscriptionTypeList, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -132,12 +144,14 @@ export class SubscriptionTypes { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /subscription_types."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/tags/client/Client.ts b/src/api/resources/tags/client/Client.ts index 8aee0957..db51c738 100644 --- a/src/api/resources/tags/client/Client.ts +++ b/src/api/resources/tags/client/Client.ts @@ -96,10 +96,17 @@ export class Tags { * id: "123" * }) */ - public async tagContact( + public tagContact( request: Intercom.TagContactRequest, requestOptions?: Tags.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__tagContact(request, requestOptions)); + } + + private async __tagContact( + request: Intercom.TagContactRequest, + requestOptions?: Tags.RequestOptions, + ): Promise> { const { contact_id: contactId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -113,8 +120,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -128,19 +135,23 @@ export class Tags { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Tag; + return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -150,6 +161,7 @@ export class Tags { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -158,6 +170,7 @@ export class Tags { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -177,10 +190,17 @@ export class Tags { * tag_id: "7522907" * }) */ - public async untagContact( + public untagContact( + request: Intercom.UntagContactRequest, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__untagContact(request, requestOptions)); + } + + private async __untagContact( request: Intercom.UntagContactRequest, requestOptions?: Tags.RequestOptions, - ): Promise { + ): Promise> { const { contact_id: contactId, tag_id: tagId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -194,8 +214,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -208,19 +228,23 @@ export class Tags { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Tag; + return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -230,6 +254,7 @@ export class Tags { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -238,6 +263,7 @@ export class Tags { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -258,10 +284,17 @@ export class Tags { * admin_id: "780" * }) */ - public async tagConversation( + public tagConversation( request: Intercom.TagConversationRequest, requestOptions?: Tags.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__tagConversation(request, requestOptions)); + } + + private async __tagConversation( + request: Intercom.TagConversationRequest, + requestOptions?: Tags.RequestOptions, + ): Promise> { const { conversation_id: conversationId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -275,8 +308,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -290,19 +323,23 @@ export class Tags { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Tag; + return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -312,6 +349,7 @@ export class Tags { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -320,6 +358,7 @@ export class Tags { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -340,10 +379,17 @@ export class Tags { * admin_id: "123" * }) */ - public async untagConversation( + public untagConversation( request: Intercom.UntagConversationRequest, requestOptions?: Tags.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__untagConversation(request, requestOptions)); + } + + private async __untagConversation( + request: Intercom.UntagConversationRequest, + requestOptions?: Tags.RequestOptions, + ): Promise> { const { conversation_id: conversationId, tag_id: tagId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -357,8 +403,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -372,19 +418,23 @@ export class Tags { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Tag; + return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -394,6 +444,7 @@ export class Tags { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -402,6 +453,7 @@ export class Tags { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -416,7 +468,11 @@ export class Tags { * @example * await client.tags.list() */ - public async list(requestOptions?: Tags.RequestOptions): Promise { + public list(requestOptions?: Tags.RequestOptions): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__list(requestOptions)); + } + + private async __list(requestOptions?: Tags.RequestOptions): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -429,8 +485,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -443,17 +499,21 @@ export class Tags { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.TagList; + return { data: _response.body as Intercom.TagList, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -463,12 +523,14 @@ export class Tags { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tags."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -521,10 +583,17 @@ export class Tags { * }] * }) */ - public async create( + public create( + request: Intercom.TagsCreateRequestBody, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( request: Intercom.TagsCreateRequestBody, requestOptions?: Tags.RequestOptions, - ): Promise { + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -537,8 +606,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -552,21 +621,25 @@ export class Tags { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Tag; + return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 400: - throw new Intercom.BadRequestError(_response.error.body as unknown); + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -576,12 +649,14 @@ export class Tags { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tags."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -601,7 +676,17 @@ export class Tags { * tag_id: "123" * }) */ - public async find(request: Intercom.FindTagRequest, requestOptions?: Tags.RequestOptions): Promise { + public find( + request: Intercom.FindTagRequest, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( + request: Intercom.FindTagRequest, + requestOptions?: Tags.RequestOptions, + ): Promise> { const { tag_id: tagId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -615,8 +700,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -629,19 +714,23 @@ export class Tags { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Tag; + return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -651,12 +740,14 @@ export class Tags { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tags/{tag_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -676,7 +767,17 @@ export class Tags { * tag_id: "123" * }) */ - public async delete(request: Intercom.DeleteTagRequest, requestOptions?: Tags.RequestOptions): Promise { + public delete( + request: Intercom.DeleteTagRequest, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__delete(request, requestOptions)); + } + + private async __delete( + request: Intercom.DeleteTagRequest, + requestOptions?: Tags.RequestOptions, + ): Promise> { const { tag_id: tagId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -690,8 +791,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -704,21 +805,25 @@ export class Tags { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return; + return { data: undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 400: - throw new Intercom.BadRequestError(_response.error.body as unknown); + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -728,12 +833,14 @@ export class Tags { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /tags/{tag_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -754,10 +861,17 @@ export class Tags { * admin_id: "780" * }) */ - public async tagTicket( + public tagTicket( + request: Intercom.TagTicketRequest, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__tagTicket(request, requestOptions)); + } + + private async __tagTicket( request: Intercom.TagTicketRequest, requestOptions?: Tags.RequestOptions, - ): Promise { + ): Promise> { const { ticket_id: ticketId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -771,8 +885,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -786,19 +900,23 @@ export class Tags { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Tag; + return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -808,12 +926,14 @@ export class Tags { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/{ticket_id}/tags."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -834,10 +954,17 @@ export class Tags { * admin_id: "123" * }) */ - public async untagTicket( + public untagTicket( + request: Intercom.UntagTicketRequest, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__untagTicket(request, requestOptions)); + } + + private async __untagTicket( request: Intercom.UntagTicketRequest, requestOptions?: Tags.RequestOptions, - ): Promise { + ): Promise> { const { ticket_id: ticketId, tag_id: tagId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -851,8 +978,8 @@ export class Tags { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -866,19 +993,23 @@ export class Tags { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Tag; + return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -888,6 +1019,7 @@ export class Tags { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -896,6 +1028,7 @@ export class Tags { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/teams/client/Client.ts b/src/api/resources/teams/client/Client.ts index 33d2fe91..2d523ac4 100644 --- a/src/api/resources/teams/client/Client.ts +++ b/src/api/resources/teams/client/Client.ts @@ -85,7 +85,11 @@ export class Teams { * @example * await client.teams.list() */ - public async list(requestOptions?: Teams.RequestOptions): Promise { + public list(requestOptions?: Teams.RequestOptions): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__list(requestOptions)); + } + + private async __list(requestOptions?: Teams.RequestOptions): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -98,8 +102,8 @@ export class Teams { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -112,17 +116,21 @@ export class Teams { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.TeamList; + return { data: _response.body as Intercom.TeamList, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -132,12 +140,14 @@ export class Teams { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /teams."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -156,10 +166,17 @@ export class Teams { * team_id: "123" * }) */ - public async find( + public find( + request: Intercom.FindTeamRequest, + requestOptions?: Teams.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( request: Intercom.FindTeamRequest, requestOptions?: Teams.RequestOptions, - ): Promise { + ): Promise> { const { team_id: teamId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -173,8 +190,8 @@ export class Teams { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -187,19 +204,23 @@ export class Teams { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Team; + return { data: _response.body as Intercom.Team, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -209,12 +230,14 @@ export class Teams { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /teams/{team_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/ticketTypes/client/Client.ts b/src/api/resources/ticketTypes/client/Client.ts index 102a5367..f4909e81 100644 --- a/src/api/resources/ticketTypes/client/Client.ts +++ b/src/api/resources/ticketTypes/client/Client.ts @@ -92,7 +92,13 @@ export class TicketTypes { * @example * await client.ticketTypes.list() */ - public async list(requestOptions?: TicketTypes.RequestOptions): Promise { + public list(requestOptions?: TicketTypes.RequestOptions): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__list(requestOptions)); + } + + private async __list( + requestOptions?: TicketTypes.RequestOptions, + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -105,8 +111,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -119,17 +125,21 @@ export class TicketTypes { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.TicketTypeList; + return { data: _response.body as Intercom.TicketTypeList, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -139,12 +149,14 @@ export class TicketTypes { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ticket_types."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -169,10 +181,17 @@ export class TicketTypes { * icon: "\uD83C\uDF9F\uFE0F" * }) */ - public async create( + public create( + request: Intercom.CreateTicketTypeRequest, + requestOptions?: TicketTypes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( request: Intercom.CreateTicketTypeRequest, requestOptions?: TicketTypes.RequestOptions, - ): Promise { + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -185,8 +204,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -200,17 +219,21 @@ export class TicketTypes { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.TicketType; + return { data: _response.body as Intercom.TicketType, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -220,12 +243,14 @@ export class TicketTypes { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /ticket_types."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -243,10 +268,17 @@ export class TicketTypes { * ticket_type_id: "ticket_type_id" * }) */ - public async get( + public get( request: Intercom.FindTicketTypeRequest, requestOptions?: TicketTypes.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__get(request, requestOptions)); + } + + private async __get( + request: Intercom.FindTicketTypeRequest, + requestOptions?: TicketTypes.RequestOptions, + ): Promise> { const { ticket_type_id: ticketTypeId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -260,8 +292,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -274,17 +306,21 @@ export class TicketTypes { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.TicketType; + return { data: _response.body as Intercom.TicketType, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -294,6 +330,7 @@ export class TicketTypes { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -302,6 +339,7 @@ export class TicketTypes { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -325,10 +363,17 @@ export class TicketTypes { * name: "Bug Report 2" * }) */ - public async update( + public update( + request: Intercom.UpdateTicketTypeRequest, + requestOptions?: TicketTypes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); + } + + private async __update( request: Intercom.UpdateTicketTypeRequest, requestOptions?: TicketTypes.RequestOptions, - ): Promise { + ): Promise> { const { ticket_type_id: ticketTypeId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -342,8 +387,8 @@ export class TicketTypes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -357,17 +402,21 @@ export class TicketTypes { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.TicketType; + return { data: _response.body as Intercom.TicketType, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -377,6 +426,7 @@ export class TicketTypes { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -385,6 +435,7 @@ export class TicketTypes { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/ticketTypes/resources/attributes/client/Client.ts b/src/api/resources/ticketTypes/resources/attributes/client/Client.ts index d95d26c5..32ac1e89 100644 --- a/src/api/resources/ticketTypes/resources/attributes/client/Client.ts +++ b/src/api/resources/ticketTypes/resources/attributes/client/Client.ts @@ -89,10 +89,17 @@ export class Attributes { * required_to_create: false * }) */ - public async create( + public create( request: Intercom.ticketTypes.CreateTicketTypeAttributeRequest, requestOptions?: Attributes.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( + request: Intercom.ticketTypes.CreateTicketTypeAttributeRequest, + requestOptions?: Attributes.RequestOptions, + ): Promise> { const { ticket_type_id: ticketTypeId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -106,8 +113,8 @@ export class Attributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -121,17 +128,21 @@ export class Attributes { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.TicketTypeAttribute; + return { data: _response.body as Intercom.TicketTypeAttribute, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -141,6 +152,7 @@ export class Attributes { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -149,6 +161,7 @@ export class Attributes { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -168,10 +181,17 @@ export class Attributes { * description: "New Attribute Description" * }) */ - public async update( + public update( + request: Intercom.ticketTypes.UpdateTicketTypeAttributeRequest, + requestOptions?: Attributes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); + } + + private async __update( request: Intercom.ticketTypes.UpdateTicketTypeAttributeRequest, requestOptions?: Attributes.RequestOptions, - ): Promise { + ): Promise> { const { ticket_type_id: ticketTypeId, attribute_id: attributeId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -185,8 +205,8 @@ export class Attributes { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -200,17 +220,21 @@ export class Attributes { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.TicketTypeAttribute; + return { data: _response.body as Intercom.TicketTypeAttribute, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -220,6 +244,7 @@ export class Attributes { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( @@ -228,6 +253,7 @@ export class Attributes { case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/tickets/client/Client.ts b/src/api/resources/tickets/client/Client.ts index 2fc45671..a47554f7 100644 --- a/src/api/resources/tickets/client/Client.ts +++ b/src/api/resources/tickets/client/Client.ts @@ -135,10 +135,17 @@ export class Tickets { * } * }) */ - public async reply( + public reply( request: Intercom.ReplyToTicketRequest, requestOptions?: Tickets.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__reply(request, requestOptions)); + } + + private async __reply( + request: Intercom.ReplyToTicketRequest, + requestOptions?: Tickets.RequestOptions, + ): Promise> { const { ticket_id: ticketId, body: _body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -152,8 +159,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -167,21 +174,25 @@ export class Tickets { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.TicketReply; + return { data: _response.body as Intercom.TicketReply, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 400: - throw new Intercom.BadRequestError(_response.error.body as unknown); + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -191,12 +202,14 @@ export class Tickets { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/{ticket_id}/reply."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -221,10 +234,17 @@ export class Tickets { * } * }) */ - public async create( + public create( request: Intercom.CreateTicketRequest, requestOptions?: Tickets.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); + } + + private async __create( + request: Intercom.CreateTicketRequest, + requestOptions?: Tickets.RequestOptions, + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -237,8 +257,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -252,17 +272,21 @@ export class Tickets { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Ticket; + return { data: _response.body as Intercom.Ticket, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -272,12 +296,14 @@ export class Tickets { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -295,10 +321,17 @@ export class Tickets { * ticket_id: "ticket_id" * }) */ - public async get( + public get( + request: Intercom.FindTicketRequest, + requestOptions?: Tickets.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__get(request, requestOptions)); + } + + private async __get( request: Intercom.FindTicketRequest, requestOptions?: Tickets.RequestOptions, - ): Promise { + ): Promise> { const { ticket_id: ticketId } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -312,8 +345,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -326,17 +359,21 @@ export class Tickets { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Ticket; + return { data: _response.body as Intercom.Ticket, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -346,12 +383,14 @@ export class Tickets { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tickets/{ticket_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -409,10 +448,17 @@ export class Tickets { * } * }) */ - public async update( + public update( + request: Intercom.UpdateTicketRequest, + requestOptions?: Tickets.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); + } + + private async __update( request: Intercom.UpdateTicketRequest, requestOptions?: Tickets.RequestOptions, - ): Promise { + ): Promise> { const { ticket_id: ticketId, ..._body } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( @@ -426,8 +472,8 @@ export class Tickets { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -441,19 +487,23 @@ export class Tickets { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Ticket; + return { data: _response.body as Intercom.Ticket, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -463,12 +513,14 @@ export class Tickets { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /tickets/{ticket_id}."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -558,58 +610,66 @@ export class Tickets { request: Intercom.SearchRequest, requestOptions?: Tickets.RequestOptions, ): Promise> { - const list = async (request: Intercom.SearchRequest): Promise => { - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.baseUrl)) ?? - (await core.Supplier.get(this._options.environment)) ?? - environments.IntercomEnvironment.UsProduction, - "tickets/search", - ), - method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return _response.body as Intercom.TicketList; - } - if (_response.error.reason === "status-code") { - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.body, + const list = core.HttpResponsePromise.interceptFunction( + async (request: Intercom.SearchRequest): Promise> => { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "tickets/search", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: + requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, }); - } - switch (_response.error.reason) { - case "non-json": + if (_response.ok) { + return { data: _response.body as Intercom.TicketList, rawResponse: _response.rawResponse }; + } + if (_response.error.reason === "status-code") { throw new errors.IntercomError({ statusCode: _response.error.statusCode, - body: _response.error.rawBody, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/search."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, + body: _response.error.body, + rawResponse: _response.rawResponse, }); - } - }; + } + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/search."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + }, + ); + const dataWithRawResponse = await list(request).withRawResponse(); return new core.Pageable({ - response: await list(request), + response: dataWithRawResponse.data, + rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => response?.pages?.next?.starting_after != null, getItems: (response) => response?.tickets ?? [], loadPage: (response) => { diff --git a/src/api/resources/tickets/client/requests/index.ts b/src/api/resources/tickets/client/requests/index.ts index 083c02e9..23ce5a7f 100644 --- a/src/api/resources/tickets/client/requests/index.ts +++ b/src/api/resources/tickets/client/requests/index.ts @@ -1,4 +1,3 @@ export { type ReplyToTicketRequest } from "./ReplyToTicketRequest"; -export { type CreateTicketRequest } from "./CreateTicketRequest"; export { type FindTicketRequest } from "./FindTicketRequest"; export { type UpdateTicketRequest } from "./UpdateTicketRequest"; diff --git a/src/api/resources/unstable/client/Client.ts b/src/api/resources/unstable/client/Client.ts new file mode 100644 index 00000000..d05f4c7f --- /dev/null +++ b/src/api/resources/unstable/client/Client.ts @@ -0,0 +1,209 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../environments"; +import * as core from "../../../../core"; +import { Admins } from "../resources/admins/client/Client"; +import { AiContent } from "../resources/aiContent/client/Client"; +import { Articles } from "../resources/articles/client/Client"; +import { AwayStatusReasons } from "../resources/awayStatusReasons/client/Client"; +import { Export } from "../resources/export/client/Client"; +import { HelpCenter } from "../resources/helpCenter/client/Client"; +import { Companies } from "../resources/companies/client/Client"; +import { Contacts } from "../resources/contacts/client/Client"; +import { Notes } from "../resources/notes/client/Client"; +import { SubscriptionTypes } from "../resources/subscriptionTypes/client/Client"; +import { Tags } from "../resources/tags/client/Client"; +import { Conversations } from "../resources/conversations/client/Client"; +import { CustomChannelEvents } from "../resources/customChannelEvents/client/Client"; +import { CustomObjectInstances } from "../resources/customObjectInstances/client/Client"; +import { DataAttributes } from "../resources/dataAttributes/client/Client"; +import { DataEvents } from "../resources/dataEvents/client/Client"; +import { DataExport } from "../resources/dataExport/client/Client"; +import { Jobs } from "../resources/jobs/client/Client"; +import { Messages } from "../resources/messages/client/Client"; +import { News } from "../resources/news/client/Client"; +import { Segments } from "../resources/segments/client/Client"; +import { Switch } from "../resources/switch/client/Client"; +import { Teams } from "../resources/teams/client/Client"; +import { TicketStates } from "../resources/ticketStates/client/Client"; +import { TicketTypeAttributes } from "../resources/ticketTypeAttributes/client/Client"; +import { TicketTypes } from "../resources/ticketTypes/client/Client"; +import { Tickets } from "../resources/tickets/client/Client"; +import { Visitors } from "../resources/visitors/client/Client"; + +export declare namespace Unstable { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } +} + +export class Unstable { + protected _admins: Admins | undefined; + protected _aiContent: AiContent | undefined; + protected _articles: Articles | undefined; + protected _awayStatusReasons: AwayStatusReasons | undefined; + protected _export: Export | undefined; + protected _helpCenter: HelpCenter | undefined; + protected _companies: Companies | undefined; + protected _contacts: Contacts | undefined; + protected _notes: Notes | undefined; + protected _subscriptionTypes: SubscriptionTypes | undefined; + protected _tags: Tags | undefined; + protected _conversations: Conversations | undefined; + protected _customChannelEvents: CustomChannelEvents | undefined; + protected _customObjectInstances: CustomObjectInstances | undefined; + protected _dataAttributes: DataAttributes | undefined; + protected _dataEvents: DataEvents | undefined; + protected _dataExport: DataExport | undefined; + protected _jobs: Jobs | undefined; + protected _messages: Messages | undefined; + protected _news: News | undefined; + protected _segments: Segments | undefined; + protected _switch: Switch | undefined; + protected _teams: Teams | undefined; + protected _ticketStates: TicketStates | undefined; + protected _ticketTypeAttributes: TicketTypeAttributes | undefined; + protected _ticketTypes: TicketTypes | undefined; + protected _tickets: Tickets | undefined; + protected _visitors: Visitors | undefined; + + constructor(protected readonly _options: Unstable.Options = {}) {} + + public get admins(): Admins { + return (this._admins ??= new Admins(this._options)); + } + + public get aiContent(): AiContent { + return (this._aiContent ??= new AiContent(this._options)); + } + + public get articles(): Articles { + return (this._articles ??= new Articles(this._options)); + } + + public get awayStatusReasons(): AwayStatusReasons { + return (this._awayStatusReasons ??= new AwayStatusReasons(this._options)); + } + + public get export(): Export { + return (this._export ??= new Export(this._options)); + } + + public get helpCenter(): HelpCenter { + return (this._helpCenter ??= new HelpCenter(this._options)); + } + + public get companies(): Companies { + return (this._companies ??= new Companies(this._options)); + } + + public get contacts(): Contacts { + return (this._contacts ??= new Contacts(this._options)); + } + + public get notes(): Notes { + return (this._notes ??= new Notes(this._options)); + } + + public get subscriptionTypes(): SubscriptionTypes { + return (this._subscriptionTypes ??= new SubscriptionTypes(this._options)); + } + + public get tags(): Tags { + return (this._tags ??= new Tags(this._options)); + } + + public get conversations(): Conversations { + return (this._conversations ??= new Conversations(this._options)); + } + + public get customChannelEvents(): CustomChannelEvents { + return (this._customChannelEvents ??= new CustomChannelEvents(this._options)); + } + + public get customObjectInstances(): CustomObjectInstances { + return (this._customObjectInstances ??= new CustomObjectInstances(this._options)); + } + + public get dataAttributes(): DataAttributes { + return (this._dataAttributes ??= new DataAttributes(this._options)); + } + + public get dataEvents(): DataEvents { + return (this._dataEvents ??= new DataEvents(this._options)); + } + + public get dataExport(): DataExport { + return (this._dataExport ??= new DataExport(this._options)); + } + + public get jobs(): Jobs { + return (this._jobs ??= new Jobs(this._options)); + } + + public get messages(): Messages { + return (this._messages ??= new Messages(this._options)); + } + + public get news(): News { + return (this._news ??= new News(this._options)); + } + + public get segments(): Segments { + return (this._segments ??= new Segments(this._options)); + } + + public get switch(): Switch { + return (this._switch ??= new Switch(this._options)); + } + + public get teams(): Teams { + return (this._teams ??= new Teams(this._options)); + } + + public get ticketStates(): TicketStates { + return (this._ticketStates ??= new TicketStates(this._options)); + } + + public get ticketTypeAttributes(): TicketTypeAttributes { + return (this._ticketTypeAttributes ??= new TicketTypeAttributes(this._options)); + } + + public get ticketTypes(): TicketTypes { + return (this._ticketTypes ??= new TicketTypes(this._options)); + } + + public get tickets(): Tickets { + return (this._tickets ??= new Tickets(this._options)); + } + + public get visitors(): Visitors { + return (this._visitors ??= new Visitors(this._options)); + } +} diff --git a/src/api/resources/customChannelEvents/client/index.ts b/src/api/resources/unstable/client/index.ts similarity index 100% rename from src/api/resources/customChannelEvents/client/index.ts rename to src/api/resources/unstable/client/index.ts diff --git a/src/api/resources/unstable/errors/BadRequestError.ts b/src/api/resources/unstable/errors/BadRequestError.ts new file mode 100644 index 00000000..d7e71d09 --- /dev/null +++ b/src/api/resources/unstable/errors/BadRequestError.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as errors from "../../../../errors/index"; +import * as core from "../../../../core"; + +export class BadRequestError extends errors.IntercomError { + constructor(body?: unknown, rawResponse?: core.RawResponse) { + super({ + message: "BadRequestError", + statusCode: 400, + body: body, + rawResponse: rawResponse, + }); + Object.setPrototypeOf(this, BadRequestError.prototype); + } +} diff --git a/src/api/resources/unstable/errors/ForbiddenError.ts b/src/api/resources/unstable/errors/ForbiddenError.ts new file mode 100644 index 00000000..c98ade42 --- /dev/null +++ b/src/api/resources/unstable/errors/ForbiddenError.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as errors from "../../../../errors/index"; +import * as Intercom from "../../../index"; +import * as core from "../../../../core"; + +export class ForbiddenError extends errors.IntercomError { + constructor(body: Intercom.unstable.Error_, rawResponse?: core.RawResponse) { + super({ + message: "ForbiddenError", + statusCode: 403, + body: body, + rawResponse: rawResponse, + }); + Object.setPrototypeOf(this, ForbiddenError.prototype); + } +} diff --git a/src/api/resources/unstable/errors/InternalServerError.ts b/src/api/resources/unstable/errors/InternalServerError.ts new file mode 100644 index 00000000..6e6ad916 --- /dev/null +++ b/src/api/resources/unstable/errors/InternalServerError.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as errors from "../../../../errors/index"; +import * as Intercom from "../../../index"; +import * as core from "../../../../core"; + +export class InternalServerError extends errors.IntercomError { + constructor(body: Intercom.unstable.Error_, rawResponse?: core.RawResponse) { + super({ + message: "InternalServerError", + statusCode: 500, + body: body, + rawResponse: rawResponse, + }); + Object.setPrototypeOf(this, InternalServerError.prototype); + } +} diff --git a/src/api/resources/unstable/errors/NotFoundError.ts b/src/api/resources/unstable/errors/NotFoundError.ts new file mode 100644 index 00000000..323b5b44 --- /dev/null +++ b/src/api/resources/unstable/errors/NotFoundError.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as errors from "../../../../errors/index"; +import * as core from "../../../../core"; + +export class NotFoundError extends errors.IntercomError { + constructor(body?: unknown, rawResponse?: core.RawResponse) { + super({ + message: "NotFoundError", + statusCode: 404, + body: body, + rawResponse: rawResponse, + }); + Object.setPrototypeOf(this, NotFoundError.prototype); + } +} diff --git a/src/api/resources/unstable/errors/TooManyRequestsError.ts b/src/api/resources/unstable/errors/TooManyRequestsError.ts new file mode 100644 index 00000000..e9ff4d56 --- /dev/null +++ b/src/api/resources/unstable/errors/TooManyRequestsError.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as errors from "../../../../errors/index"; +import * as Intercom from "../../../index"; +import * as core from "../../../../core"; + +export class TooManyRequestsError extends errors.IntercomError { + constructor(body: Intercom.unstable.Error_, rawResponse?: core.RawResponse) { + super({ + message: "TooManyRequestsError", + statusCode: 429, + body: body, + rawResponse: rawResponse, + }); + Object.setPrototypeOf(this, TooManyRequestsError.prototype); + } +} diff --git a/src/api/resources/unstable/errors/UnauthorizedError.ts b/src/api/resources/unstable/errors/UnauthorizedError.ts new file mode 100644 index 00000000..33fb0bce --- /dev/null +++ b/src/api/resources/unstable/errors/UnauthorizedError.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as errors from "../../../../errors/index"; +import * as Intercom from "../../../index"; +import * as core from "../../../../core"; + +export class UnauthorizedError extends errors.IntercomError { + constructor(body: Intercom.unstable.Error_, rawResponse?: core.RawResponse) { + super({ + message: "UnauthorizedError", + statusCode: 401, + body: body, + rawResponse: rawResponse, + }); + Object.setPrototypeOf(this, UnauthorizedError.prototype); + } +} diff --git a/src/api/resources/unstable/errors/UnprocessableEntityError.ts b/src/api/resources/unstable/errors/UnprocessableEntityError.ts new file mode 100644 index 00000000..912441d7 --- /dev/null +++ b/src/api/resources/unstable/errors/UnprocessableEntityError.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as errors from "../../../../errors/index"; +import * as core from "../../../../core"; + +export class UnprocessableEntityError extends errors.IntercomError { + constructor(body?: unknown, rawResponse?: core.RawResponse) { + super({ + message: "UnprocessableEntityError", + statusCode: 422, + body: body, + rawResponse: rawResponse, + }); + Object.setPrototypeOf(this, UnprocessableEntityError.prototype); + } +} diff --git a/src/api/resources/unstable/errors/index.ts b/src/api/resources/unstable/errors/index.ts new file mode 100644 index 00000000..6190d905 --- /dev/null +++ b/src/api/resources/unstable/errors/index.ts @@ -0,0 +1,7 @@ +export * from "./BadRequestError"; +export * from "./UnauthorizedError"; +export * from "./NotFoundError"; +export * from "./TooManyRequestsError"; +export * from "./ForbiddenError"; +export * from "./UnprocessableEntityError"; +export * from "./InternalServerError"; diff --git a/src/api/resources/unstable/index.ts b/src/api/resources/unstable/index.ts new file mode 100644 index 00000000..d5c609c4 --- /dev/null +++ b/src/api/resources/unstable/index.ts @@ -0,0 +1,4 @@ +export * from "./resources"; +export * from "./types"; +export * from "./errors"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/admins/client/Client.ts b/src/api/resources/unstable/resources/admins/client/Client.ts new file mode 100644 index 00000000..fad5ac42 --- /dev/null +++ b/src/api/resources/unstable/resources/admins/client/Client.ts @@ -0,0 +1,536 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Admins { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Admins + */ +export class Admins { + constructor(protected readonly _options: Admins.Options = {}) {} + + /** + * + * You can view the currently authorised admin along with the embedded app object (a "workspace" in legacy terminology). + * + * > 🚧 Single Sign On + * > + * > If you are building a custom "Log in with Intercom" flow for your site, and you call the `/me` endpoint to identify the logged-in user, you should not accept any sign-ins from users with unverified email addresses as it poses a potential impersonation security risk. + * + * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.unstable.admins.identifyAdmin() + */ + public identifyAdmin( + requestOptions?: Admins.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__identifyAdmin(requestOptions)); + } + + private async __identifyAdmin( + requestOptions?: Admins.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "me", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.AdminWithApp | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /me."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can set an Admin as away for the Inbox. + * + * @param {Intercom.unstable.SetAwayAdminRequest} request + * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.admins.setAwayAdmin({ + * id: 1, + * away_mode_enabled: true, + * away_mode_reassign: true, + * away_status_reason_id: 12345 + * }) + * + * @example + * await client.unstable.admins.setAwayAdmin({ + * id: 1, + * away_mode_enabled: true, + * away_mode_reassign: true + * }) + */ + public setAwayAdmin( + request: Intercom.unstable.SetAwayAdminRequest, + requestOptions?: Admins.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__setAwayAdmin(request, requestOptions)); + } + + private async __setAwayAdmin( + request: Intercom.unstable.SetAwayAdminRequest, + requestOptions?: Admins.RequestOptions, + ): Promise> { + const { id, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `admins/${encodeURIComponent(id)}/away`, + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Admin | undefined, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /admins/{id}/away."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can get a log of activities by all admins in an app. + * + * @param {Intercom.unstable.ListActivityLogsRequest} request + * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.admins.listActivityLogs({ + * created_at_after: "1677253093", + * created_at_before: "1677861493" + * }) + */ + public listActivityLogs( + request: Intercom.unstable.ListActivityLogsRequest, + requestOptions?: Admins.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listActivityLogs(request, requestOptions)); + } + + private async __listActivityLogs( + request: Intercom.unstable.ListActivityLogsRequest, + requestOptions?: Admins.RequestOptions, + ): Promise> { + const { created_at_after: createdAtAfter, created_at_before: createdAtBefore } = request; + const _queryParams: Record = {}; + _queryParams["created_at_after"] = createdAtAfter; + if (createdAtBefore != null) { + _queryParams["created_at_before"] = createdAtBefore; + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "admins/activity_logs", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ActivityLogList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins/activity_logs."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch a list of admins for a given workspace. + * + * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.admins.listAdmins() + */ + public listAdmins(requestOptions?: Admins.RequestOptions): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAdmins(requestOptions)); + } + + private async __listAdmins( + requestOptions?: Admins.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "admins", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.AdminList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can retrieve the details of a single admin. + * + * @param {Intercom.unstable.RetrieveAdminRequest} request + * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.admins.retrieveAdmin({ + * id: 1 + * }) + */ + public retrieveAdmin( + request: Intercom.unstable.RetrieveAdminRequest, + requestOptions?: Admins.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveAdmin(request, requestOptions)); + } + + private async __retrieveAdmin( + request: Intercom.unstable.RetrieveAdminRequest, + requestOptions?: Admins.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `admins/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Admin | undefined, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/admins/client/index.ts b/src/api/resources/unstable/resources/admins/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/admins/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/admins/client/requests/ListActivityLogsRequest.ts b/src/api/resources/unstable/resources/admins/client/requests/ListActivityLogsRequest.ts new file mode 100644 index 00000000..88dbafc4 --- /dev/null +++ b/src/api/resources/unstable/resources/admins/client/requests/ListActivityLogsRequest.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * created_at_after: "1677253093", + * created_at_before: "1677861493" + * } + */ +export interface ListActivityLogsRequest { + /** + * The start date that you request data for. It must be formatted as a UNIX timestamp. + */ + created_at_after: string; + /** + * The end date that you request data for. It must be formatted as a UNIX timestamp. + */ + created_at_before?: string; +} diff --git a/src/api/resources/unstable/resources/admins/client/requests/RetrieveAdminRequest.ts b/src/api/resources/unstable/resources/admins/client/requests/RetrieveAdminRequest.ts new file mode 100644 index 00000000..49fb29b2 --- /dev/null +++ b/src/api/resources/unstable/resources/admins/client/requests/RetrieveAdminRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1 + * } + */ +export interface RetrieveAdminRequest { + /** + * The unique identifier of a given admin + */ + id: number; +} diff --git a/src/api/resources/unstable/resources/admins/client/requests/SetAwayAdminRequest.ts b/src/api/resources/unstable/resources/admins/client/requests/SetAwayAdminRequest.ts new file mode 100644 index 00000000..2b986684 --- /dev/null +++ b/src/api/resources/unstable/resources/admins/client/requests/SetAwayAdminRequest.ts @@ -0,0 +1,39 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1, + * away_mode_enabled: true, + * away_mode_reassign: true, + * away_status_reason_id: 12345 + * } + * + * @example + * { + * id: 1, + * away_mode_enabled: true, + * away_mode_reassign: true + * } + * + * @example + * { + * id: 1, + * away_mode_enabled: true, + * away_mode_reassign: true + * } + */ +export interface SetAwayAdminRequest { + /** + * The unique identifier of a given admin + */ + id: number; + /** Set to "true" to change the status of the admin to away. */ + away_mode_enabled: boolean; + /** Set to "true" to assign any new conversation replies to your default inbox. */ + away_mode_reassign: boolean; + /** The unique identifier of the away status reason */ + away_status_reason_id?: number; +} diff --git a/src/api/resources/unstable/resources/admins/client/requests/index.ts b/src/api/resources/unstable/resources/admins/client/requests/index.ts new file mode 100644 index 00000000..9ca82847 --- /dev/null +++ b/src/api/resources/unstable/resources/admins/client/requests/index.ts @@ -0,0 +1,3 @@ +export { type SetAwayAdminRequest } from "./SetAwayAdminRequest"; +export { type ListActivityLogsRequest } from "./ListActivityLogsRequest"; +export { type RetrieveAdminRequest } from "./RetrieveAdminRequest"; diff --git a/src/api/resources/unstable/resources/admins/index.ts b/src/api/resources/unstable/resources/admins/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/admins/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/admins/types/Admin.ts b/src/api/resources/unstable/resources/admins/types/Admin.ts new file mode 100644 index 00000000..8e1794d6 --- /dev/null +++ b/src/api/resources/unstable/resources/admins/types/Admin.ts @@ -0,0 +1,34 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * Admins are teammate accounts that have access to a workspace. + */ +export interface Admin { + /** String representing the object's type. Always has the value `admin`. */ + type?: string; + /** The id representing the admin. */ + id?: string; + /** The name of the admin. */ + name?: string; + /** The email of the admin. */ + email?: string; + /** The job title of the admin. */ + job_title?: string; + /** Identifies if this admin is currently set in away mode. */ + away_mode_enabled?: boolean; + /** Identifies if this admin is set to automatically reassign new conversations to the apps default inbox. */ + away_mode_reassign?: boolean; + /** The unique identifier of the away status reason */ + away_status_reason_id?: number; + /** Identifies if this admin has a paid inbox seat to restrict/allow features that require them. */ + has_inbox_seat?: boolean; + /** This object represents the avatar associated with the admin. */ + team_ids?: number[]; + /** Image for the associated team or teammate */ + avatar?: string; + team_priority_level?: Intercom.unstable.TeamPriorityLevel; +} diff --git a/src/api/resources/unstable/resources/admins/types/index.ts b/src/api/resources/unstable/resources/admins/types/index.ts new file mode 100644 index 00000000..c950b2eb --- /dev/null +++ b/src/api/resources/unstable/resources/admins/types/index.ts @@ -0,0 +1 @@ +export * from "./Admin"; diff --git a/src/api/resources/unstable/resources/aiAgent/index.ts b/src/api/resources/unstable/resources/aiAgent/index.ts new file mode 100644 index 00000000..eea524d6 --- /dev/null +++ b/src/api/resources/unstable/resources/aiAgent/index.ts @@ -0,0 +1 @@ +export * from "./types"; diff --git a/src/api/resources/unstable/resources/aiAgent/types/AiAgent.ts b/src/api/resources/unstable/resources/aiAgent/types/AiAgent.ts new file mode 100644 index 00000000..bc37ada3 --- /dev/null +++ b/src/api/resources/unstable/resources/aiAgent/types/AiAgent.ts @@ -0,0 +1,38 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * Data related to AI Agent involvement in the conversation. + */ +export interface AiAgent { + /** The type of the source that triggered AI Agent involvement in the conversation. */ + source_type?: AiAgent.SourceType; + /** The title of the source that triggered AI Agent involvement in the conversation. If this is `essentials_plan_setup` then it will return `null`. */ + source_title?: string; + /** The type of the last answer delivered by AI Agent. If no answer was delivered then this will return `null` */ + last_answer_type?: string; + /** The resolution state of AI Agent. If no AI or custom answer has been delivered then this will return `null`. */ + resolution_state?: string; + /** The customer satisfaction rating given to AI Agent, from 1-5. */ + rating?: number; + /** The customer satisfaction rating remark given to AI Agent. */ + rating_remark?: string; + content_sources?: Intercom.unstable.ContentSourcesList; +} + +export namespace AiAgent { + /** + * The type of the source that triggered AI Agent involvement in the conversation. + */ + export type SourceType = "essentials_plan_setup" | "profile" | "workflow" | "workflow_preview" | "fin_preview"; + export const SourceType = { + EssentialsPlanSetup: "essentials_plan_setup", + Profile: "profile", + Workflow: "workflow", + WorkflowPreview: "workflow_preview", + FinPreview: "fin_preview", + } as const; +} diff --git a/src/api/resources/unstable/resources/aiAgent/types/index.ts b/src/api/resources/unstable/resources/aiAgent/types/index.ts new file mode 100644 index 00000000..05de312f --- /dev/null +++ b/src/api/resources/unstable/resources/aiAgent/types/index.ts @@ -0,0 +1 @@ +export * from "./AiAgent"; diff --git a/src/api/resources/unstable/resources/aiContent/client/Client.ts b/src/api/resources/unstable/resources/aiContent/client/Client.ts new file mode 100644 index 00000000..55afcd8a --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/client/Client.ts @@ -0,0 +1,988 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace AiContent { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * With the AI Content APIs, you can create and manage External Pages and Content Import Sources for your Fin Content Library. + * + *   + * + * *External Pages* are pages that you want Fin to be able to answer questions about. The API for External Pages is a great way to ingest into your Fin Content Library pages that are not publicly accessible and hence can't be crawled by Intercom. + * + *   + * + * *Content Import Sources* are the sources of those pages, and they are used to determine the default audience for the pages (configured via the UI). You should create a Content Import Source for each source of External Pages that you want to ingest into your Fin Content Library. + * + *   + * + * You can then iterate through the content from that source via its API and POST it to the External Pages endpoint. That endpoint has an *external_id* parameter which allows you to specify the identifier from the source. The endpoint will then either create a new External Page or update an existing one as appropriate.", + */ +export class AiContent { + constructor(protected readonly _options: AiContent.Options = {}) {} + + /** + * You can retrieve a list of all content import sources for a workspace. + * + * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.aiContent.listContentImportSources() + */ + public listContentImportSources( + requestOptions?: AiContent.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listContentImportSources(requestOptions)); + } + + private async __listContentImportSources( + requestOptions?: AiContent.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ai/content_import_sources", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.ContentImportSourcesList, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ai/content_import_sources."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can create a new content import source by sending a POST request to this endpoint. + * + * @param {Intercom.unstable.CreateContentImportSourceRequest} request + * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.aiContent.createContentImportSource({ + * url: "https://www.example.com" + * }) + */ + public createContentImportSource( + request: Intercom.unstable.CreateContentImportSourceRequest, + requestOptions?: AiContent.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createContentImportSource(request, requestOptions)); + } + + private async __createContentImportSource( + request: Intercom.unstable.CreateContentImportSourceRequest, + requestOptions?: AiContent.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ai/content_import_sources", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: { ...request, sync_behavior: "api" }, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.ContentImportSource, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /ai/content_import_sources."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * @param {Intercom.unstable.GetContentImportSourceRequest} request + * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.aiContent.getContentImportSource({ + * id: "id" + * }) + */ + public getContentImportSource( + request: Intercom.unstable.GetContentImportSourceRequest, + requestOptions?: AiContent.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__getContentImportSource(request, requestOptions)); + } + + private async __getContentImportSource( + request: Intercom.unstable.GetContentImportSourceRequest, + requestOptions?: AiContent.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ai/content_import_sources/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.ContentImportSource, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /ai/content_import_sources/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can update an existing content import source. + * + * @param {Intercom.unstable.UpdateContentImportSourceRequest} request + * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.aiContent.updateContentImportSource({ + * id: "id", + * sync_behavior: "api", + * url: "https://www.example.com" + * }) + */ + public updateContentImportSource( + request: Intercom.unstable.UpdateContentImportSourceRequest, + requestOptions?: AiContent.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateContentImportSource(request, requestOptions)); + } + + private async __updateContentImportSource( + request: Intercom.unstable.UpdateContentImportSourceRequest, + requestOptions?: AiContent.RequestOptions, + ): Promise> { + const { id, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ai/content_import_sources/${encodeURIComponent(id)}`, + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.ContentImportSource, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling PUT /ai/content_import_sources/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can delete a content import source by making a DELETE request this endpoint. This will also delete all external pages that were imported from this source. + * + * @param {Intercom.unstable.DeleteContentImportSourceRequest} request + * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.aiContent.deleteContentImportSource({ + * id: "id" + * }) + */ + public deleteContentImportSource( + request: Intercom.unstable.DeleteContentImportSourceRequest, + requestOptions?: AiContent.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteContentImportSource(request, requestOptions)); + } + + private async __deleteContentImportSource( + request: Intercom.unstable.DeleteContentImportSourceRequest, + requestOptions?: AiContent.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ai/content_import_sources/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: undefined, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /ai/content_import_sources/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can retrieve a list of all external pages for a workspace. + * + * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.aiContent.listExternalPages() + */ + public listExternalPages( + requestOptions?: AiContent.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listExternalPages(requestOptions)); + } + + private async __listExternalPages( + requestOptions?: AiContent.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ai/external_pages", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ExternalPagesList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ai/external_pages."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can create a new external page by sending a POST request to this endpoint. If an external page already exists with the specified source_id and external_id, it will be updated instead. + * + * @param {Intercom.unstable.CreateExternalPageRequest} request + * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.aiContent.createExternalPage({ + * title: "Test", + * html: "

Test

", + * url: "https://www.example.com", + * source_id: 44, + * external_id: "abc1234" + * }) + */ + public createExternalPage( + request: Intercom.unstable.CreateExternalPageRequest, + requestOptions?: AiContent.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createExternalPage(request, requestOptions)); + } + + private async __createExternalPage( + request: Intercom.unstable.CreateExternalPageRequest, + requestOptions?: AiContent.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ai/external_pages", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: { ...request, locale: "en" }, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ExternalPage, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /ai/external_pages."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can retrieve an external page. + * + * @param {Intercom.unstable.GetExternalPageRequest} request + * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.aiContent.getExternalPage({ + * id: "id" + * }) + */ + public getExternalPage( + request: Intercom.unstable.GetExternalPageRequest, + requestOptions?: AiContent.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__getExternalPage(request, requestOptions)); + } + + private async __getExternalPage( + request: Intercom.unstable.GetExternalPageRequest, + requestOptions?: AiContent.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ai/external_pages/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ExternalPage, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ai/external_pages/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can update an existing external page (if it was created via the API). + * + * @param {Intercom.unstable.UpdateExternalPageRequest} request + * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.aiContent.updateExternalPage({ + * id: "id", + * title: "Test", + * html: "

Test

", + * url: "https://www.example.com", + * source_id: 47, + * external_id: "5678" + * }) + */ + public updateExternalPage( + request: Intercom.unstable.UpdateExternalPageRequest, + requestOptions?: AiContent.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateExternalPage(request, requestOptions)); + } + + private async __updateExternalPage( + request: Intercom.unstable.UpdateExternalPageRequest, + requestOptions?: AiContent.RequestOptions, + ): Promise> { + const { id, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ai/external_pages/${encodeURIComponent(id)}`, + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: { ..._body, locale: "en" }, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ExternalPage, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /ai/external_pages/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Sending a DELETE request for an external page will remove it from the content library UI and from being used for AI answers. + * + * @param {Intercom.unstable.DeleteExternalPageRequest} request + * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.aiContent.deleteExternalPage({ + * id: "id" + * }) + */ + public deleteExternalPage( + request: Intercom.unstable.DeleteExternalPageRequest, + requestOptions?: AiContent.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteExternalPage(request, requestOptions)); + } + + private async __deleteExternalPage( + request: Intercom.unstable.DeleteExternalPageRequest, + requestOptions?: AiContent.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ai/external_pages/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ExternalPage, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /ai/external_pages/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/aiContent/client/index.ts b/src/api/resources/unstable/resources/aiContent/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/CreateContentImportSourceRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/CreateContentImportSourceRequest.ts new file mode 100644 index 00000000..06da2b4a --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/client/requests/CreateContentImportSourceRequest.ts @@ -0,0 +1,27 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * url: "https://www.example.com" + * } + */ +export interface CreateContentImportSourceRequest { + /** The status of the content import source. */ + status?: CreateContentImportSourceRequest.Status; + /** The URL of the content import source. */ + url: string; +} + +export namespace CreateContentImportSourceRequest { + /** + * The status of the content import source. + */ + export type Status = "active" | "deactivated"; + export const Status = { + Active: "active", + Deactivated: "deactivated", + } as const; +} diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/CreateExternalPageRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/CreateExternalPageRequest.ts new file mode 100644 index 00000000..d0d37237 --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/client/requests/CreateExternalPageRequest.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * title: "Test", + * html: "

Test

", + * url: "https://www.example.com", + * source_id: 44, + * external_id: "abc1234" + * } + */ +export interface CreateExternalPageRequest { + /** The title of the external page. */ + title: string; + /** The body of the external page in HTML. */ + html: string; + /** The URL of the external page. This will be used by Fin to link end users to the page it based its answer on. When a URL is not present, Fin will not reference the source. */ + url?: string; + /** Whether the external page should be used to answer questions by AI Agent. Will not default when updating an existing external page. */ + ai_agent_availability?: boolean; + /** Whether the external page should be used to answer questions by AI Copilot. Will not default when updating an existing external page. */ + ai_copilot_availability?: boolean; + /** The unique identifier for the source of the external page which was given by Intercom. Every external page must be associated with a Content Import Source which represents the place it comes from and from which it inherits a default audience (configured in the UI). For a new source, make a POST request to the Content Import Source endpoint and an ID for the source will be returned in the response. */ + source_id: number; + /** The identifier for the external page which was given by the source. Must be unique for the source. */ + external_id: string; +} diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/DeleteContentImportSourceRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/DeleteContentImportSourceRequest.ts new file mode 100644 index 00000000..6d921146 --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/client/requests/DeleteContentImportSourceRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "id" + * } + */ +export interface DeleteContentImportSourceRequest { + /** + * The unique identifier for the content import source which is given by Intercom. + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/DeleteExternalPageRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/DeleteExternalPageRequest.ts new file mode 100644 index 00000000..cf5c01d3 --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/client/requests/DeleteExternalPageRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "id" + * } + */ +export interface DeleteExternalPageRequest { + /** + * The unique identifier for the external page which is given by Intercom. + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/GetContentImportSourceRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/GetContentImportSourceRequest.ts new file mode 100644 index 00000000..68b77b47 --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/client/requests/GetContentImportSourceRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "id" + * } + */ +export interface GetContentImportSourceRequest { + /** + * The unique identifier for the content import source which is given by Intercom. + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/GetExternalPageRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/GetExternalPageRequest.ts new file mode 100644 index 00000000..bb1c963e --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/client/requests/GetExternalPageRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "id" + * } + */ +export interface GetExternalPageRequest { + /** + * The unique identifier for the external page which is given by Intercom. + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/UpdateContentImportSourceRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/UpdateContentImportSourceRequest.ts new file mode 100644 index 00000000..bac30489 --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/client/requests/UpdateContentImportSourceRequest.ts @@ -0,0 +1,44 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "id", + * sync_behavior: "api", + * url: "https://www.example.com" + * } + */ +export interface UpdateContentImportSourceRequest { + /** + * The unique identifier for the content import source which is given by Intercom. + */ + id: string; + /** If you intend to create or update External Pages via the API, this should be set to `api`. You can not change the value to or from api. */ + sync_behavior: UpdateContentImportSourceRequest.SyncBehavior; + /** The status of the content import source. */ + status?: UpdateContentImportSourceRequest.Status; + /** The URL of the content import source. This may only be different from the existing value if the sync behavior is API. */ + url: string; +} + +export namespace UpdateContentImportSourceRequest { + /** + * If you intend to create or update External Pages via the API, this should be set to `api`. You can not change the value to or from api. + */ + export type SyncBehavior = "api" | "automated" | "manual"; + export const SyncBehavior = { + Api: "api", + Automated: "automated", + Manual: "manual", + } as const; + /** + * The status of the content import source. + */ + export type Status = "active" | "deactivated"; + export const Status = { + Active: "active", + Deactivated: "deactivated", + } as const; +} diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/UpdateExternalPageRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/UpdateExternalPageRequest.ts new file mode 100644 index 00000000..162b3c77 --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/client/requests/UpdateExternalPageRequest.ts @@ -0,0 +1,33 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "id", + * title: "Test", + * html: "

Test

", + * url: "https://www.example.com", + * source_id: 47, + * external_id: "5678" + * } + */ +export interface UpdateExternalPageRequest { + /** + * The unique identifier for the external page which is given by Intercom. + */ + id: string; + /** The title of the external page. */ + title: string; + /** The body of the external page in HTML. */ + html: string; + /** The URL of the external page. This will be used by Fin to link end users to the page it based its answer on. */ + url: string; + /** Whether the external page should be used to answer questions by Fin. */ + fin_availability?: boolean; + /** The unique identifier for the source of the external page which was given by Intercom. Every external page must be associated with a Content Import Source which represents the place it comes from and from which it inherits a default audience (configured in the UI). For a new source, make a POST request to the Content Import Source endpoint and an ID for the source will be returned in the response. */ + source_id: number; + /** The identifier for the external page which was given by the source. Must be unique for the source. */ + external_id?: string; +} diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/index.ts b/src/api/resources/unstable/resources/aiContent/client/requests/index.ts new file mode 100644 index 00000000..820c72ee --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/client/requests/index.ts @@ -0,0 +1,8 @@ +export { type CreateContentImportSourceRequest } from "./CreateContentImportSourceRequest"; +export { type GetContentImportSourceRequest } from "./GetContentImportSourceRequest"; +export { type UpdateContentImportSourceRequest } from "./UpdateContentImportSourceRequest"; +export { type DeleteContentImportSourceRequest } from "./DeleteContentImportSourceRequest"; +export { type CreateExternalPageRequest } from "./CreateExternalPageRequest"; +export { type GetExternalPageRequest } from "./GetExternalPageRequest"; +export { type UpdateExternalPageRequest } from "./UpdateExternalPageRequest"; +export { type DeleteExternalPageRequest } from "./DeleteExternalPageRequest"; diff --git a/src/api/resources/unstable/resources/aiContent/index.ts b/src/api/resources/unstable/resources/aiContent/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/aiContent/types/ContentImportSource.ts b/src/api/resources/unstable/resources/aiContent/types/ContentImportSource.ts new file mode 100644 index 00000000..ef5cd352 --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/types/ContentImportSource.ts @@ -0,0 +1,45 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * An external source for External Pages that you add to your Fin Content Library. + */ +export interface ContentImportSource { + /** Always external_page */ + type: "content_import_source"; + /** The unique identifier for the content import source which is given by Intercom. */ + id: number; + /** The time when the content import source was last synced. */ + last_synced_at: number; + /** If you intend to create or update External Pages via the API, this should be set to `api`. */ + sync_behavior: ContentImportSource.SyncBehavior; + /** The status of the content import source. */ + status: ContentImportSource.Status; + /** The URL of the root of the external source. */ + url: string; + /** The time when the content import source was created. */ + created_at: number; + /** The time when the content import source was last updated. */ + updated_at: number; +} + +export namespace ContentImportSource { + /** + * If you intend to create or update External Pages via the API, this should be set to `api`. + */ + export type SyncBehavior = "api" | "automatic" | "manual"; + export const SyncBehavior = { + Api: "api", + Automatic: "automatic", + Manual: "manual", + } as const; + /** + * The status of the content import source. + */ + export type Status = "active" | "deactivated"; + export const Status = { + Active: "active", + Deactivated: "deactivated", + } as const; +} diff --git a/src/api/resources/unstable/resources/aiContent/types/ContentImportSourcesList.ts b/src/api/resources/unstable/resources/aiContent/types/ContentImportSourcesList.ts new file mode 100644 index 00000000..ede951a5 --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/types/ContentImportSourcesList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * This will return a list of the content import sources for the App. + */ +export interface ContentImportSourcesList { + /** The type of the object - `list`. */ + type?: "list"; + pages?: Intercom.unstable.PagesLink; + /** A count of the total number of content import sources. */ + total_count?: number; + /** An array of Content Import Source objects */ + data?: Intercom.unstable.ContentImportSource[]; +} diff --git a/src/api/resources/unstable/resources/aiContent/types/ExternalPage.ts b/src/api/resources/unstable/resources/aiContent/types/ExternalPage.ts new file mode 100644 index 00000000..93a5eaf4 --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/types/ExternalPage.ts @@ -0,0 +1,37 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * External pages that you have added to your Fin Content Library. + */ +export interface ExternalPage { + /** Always external_page */ + type: "external_page"; + /** The unique identifier for the external page which is given by Intercom. */ + id: string; + /** The title of the external page. */ + title: string; + /** The body of the external page in HTML. */ + html: string; + /** The URL of the external page. This will be used by Fin to link end users to the page it based its answer on. */ + url?: string; + /** Whether the external page should be used to answer questions by AI Agent. */ + ai_agent_availability: boolean; + /** Whether the external page should be used to answer questions by AI Copilot. */ + ai_copilot_availability: boolean; + /** Deprecated. Use ai_agent_availability and ai_copilot_availability instead. */ + fin_availability?: boolean; + /** Always en */ + locale: "en"; + /** The unique identifier for the source of the external page which was given by Intercom. Every external page must be associated with a Content Import Source which represents the place it comes from and from which it inherits a default audience (configured in the UI). For a new source, make a POST request to the Content Import Source endpoint and an ID for the source will be returned in the response. */ + source_id: number; + /** The identifier for the external page which was given by the source. Must be unique for the source. */ + external_id: string; + /** The time when the external page was created. */ + created_at: number; + /** The time when the external page was last updated. */ + updated_at: number; + /** The time when the external page was last ingested. */ + last_ingested_at: number; +} diff --git a/src/api/resources/unstable/resources/aiContent/types/ExternalPagesList.ts b/src/api/resources/unstable/resources/aiContent/types/ExternalPagesList.ts new file mode 100644 index 00000000..d3c610c2 --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/types/ExternalPagesList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * This will return a list of external pages for the App. + */ +export interface ExternalPagesList { + /** The type of the object - `list`. */ + type?: "list"; + pages?: Intercom.unstable.PagesLink; + /** A count of the total number of external pages. */ + total_count?: number; + /** An array of External Page objects */ + data?: Intercom.unstable.ExternalPage[]; +} diff --git a/src/api/resources/unstable/resources/aiContent/types/index.ts b/src/api/resources/unstable/resources/aiContent/types/index.ts new file mode 100644 index 00000000..a1b39227 --- /dev/null +++ b/src/api/resources/unstable/resources/aiContent/types/index.ts @@ -0,0 +1,4 @@ +export * from "./ContentImportSource"; +export * from "./ContentImportSourcesList"; +export * from "./ExternalPage"; +export * from "./ExternalPagesList"; diff --git a/src/api/resources/unstable/resources/aiContentSource/index.ts b/src/api/resources/unstable/resources/aiContentSource/index.ts new file mode 100644 index 00000000..eea524d6 --- /dev/null +++ b/src/api/resources/unstable/resources/aiContentSource/index.ts @@ -0,0 +1 @@ +export * from "./types"; diff --git a/src/api/resources/unstable/resources/aiContentSource/types/ContentSource.ts b/src/api/resources/unstable/resources/aiContentSource/types/ContentSource.ts new file mode 100644 index 00000000..3baaae4a --- /dev/null +++ b/src/api/resources/unstable/resources/aiContentSource/types/ContentSource.ts @@ -0,0 +1,31 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The content source used by AI Agent in the conversation. + */ +export interface ContentSource { + /** The type of the content source. */ + content_type?: ContentSource.ContentType; + /** The internal URL linking to the content source for teammates. */ + url?: string; + /** The title of the content source. */ + title?: string; + /** The ISO 639 language code of the content source. */ + locale?: string; +} + +export namespace ContentSource { + /** + * The type of the content source. + */ + export type ContentType = "file" | "article" | "external_content" | "content_snippet" | "workflow_connector_action"; + export const ContentType = { + File: "file", + Article: "article", + ExternalContent: "external_content", + ContentSnippet: "content_snippet", + WorkflowConnectorAction: "workflow_connector_action", + } as const; +} diff --git a/src/api/resources/unstable/resources/aiContentSource/types/index.ts b/src/api/resources/unstable/resources/aiContentSource/types/index.ts new file mode 100644 index 00000000..68047f7e --- /dev/null +++ b/src/api/resources/unstable/resources/aiContentSource/types/index.ts @@ -0,0 +1 @@ +export * from "./ContentSource"; diff --git a/src/api/resources/unstable/resources/articles/client/Client.ts b/src/api/resources/unstable/resources/articles/client/Client.ts new file mode 100644 index 00000000..ec87cbce --- /dev/null +++ b/src/api/resources/unstable/resources/articles/client/Client.ts @@ -0,0 +1,556 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Articles { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Articles + */ +export class Articles { + constructor(protected readonly _options: Articles.Options = {}) {} + + /** + * You can fetch a list of all articles by making a GET request to `https://api.intercom.io/articles`. + * + * > 📘 How are the articles sorted and ordered? + * > + * > Articles will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated articles first. + * + * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.articles.listArticles() + */ + public listArticles( + requestOptions?: Articles.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listArticles(requestOptions)); + } + + private async __listArticles( + requestOptions?: Articles.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "articles", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ArticleList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can create a new article by making a POST request to `https://api.intercom.io/articles`. + * + * @param {unknown} request + * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.articles.createArticle({ + * "key": "value" + * }) + */ + public createArticle( + request?: unknown, + requestOptions?: Articles.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createArticle(request, requestOptions)); + } + + private async __createArticle( + request?: unknown, + requestOptions?: Articles.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "articles", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Article, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /articles."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch the details of a single article by making a GET request to `https://api.intercom.io/articles/`. + * + * @param {Intercom.unstable.RetrieveArticleRequest} request + * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.articles.retrieveArticle({ + * id: 1 + * }) + */ + public retrieveArticle( + request: Intercom.unstable.RetrieveArticleRequest, + requestOptions?: Articles.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveArticle(request, requestOptions)); + } + + private async __retrieveArticle( + request: Intercom.unstable.RetrieveArticleRequest, + requestOptions?: Articles.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `articles/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Article, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can delete a single article by making a DELETE request to `https://api.intercom.io/articles/`. + * + * @param {Intercom.unstable.DeleteArticleRequest} request + * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.articles.deleteArticle({ + * id: 1 + * }) + */ + public deleteArticle( + request: Intercom.unstable.DeleteArticleRequest, + requestOptions?: Articles.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteArticle(request, requestOptions)); + } + + private async __deleteArticle( + request: Intercom.unstable.DeleteArticleRequest, + requestOptions?: Articles.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `articles/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.DeletedArticleObject, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /articles/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can search for articles by making a GET request to `https://api.intercom.io/articles/search`. + * + * @param {Intercom.unstable.SearchArticlesRequest} request + * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.articles.searchArticles({ + * phrase: "Getting started", + * state: "published" + * }) + */ + public searchArticles( + request: Intercom.unstable.SearchArticlesRequest = {}, + requestOptions?: Articles.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__searchArticles(request, requestOptions)); + } + + private async __searchArticles( + request: Intercom.unstable.SearchArticlesRequest = {}, + requestOptions?: Articles.RequestOptions, + ): Promise> { + const { phrase, state, help_center_id: helpCenterId, highlight } = request; + const _queryParams: Record = {}; + if (phrase != null) { + _queryParams["phrase"] = phrase; + } + + if (state != null) { + _queryParams["state"] = state; + } + + if (helpCenterId != null) { + _queryParams["help_center_id"] = helpCenterId.toString(); + } + + if (highlight != null) { + _queryParams["highlight"] = highlight.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "articles/search", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.ArticleSearchResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles/search."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/articles/client/index.ts b/src/api/resources/unstable/resources/articles/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/articles/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/articles/client/requests/DeleteArticleRequest.ts b/src/api/resources/unstable/resources/articles/client/requests/DeleteArticleRequest.ts new file mode 100644 index 00000000..51b8ba6a --- /dev/null +++ b/src/api/resources/unstable/resources/articles/client/requests/DeleteArticleRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1 + * } + */ +export interface DeleteArticleRequest { + /** + * The unique identifier for the article which is given by Intercom. + */ + id: number; +} diff --git a/src/api/resources/unstable/resources/articles/client/requests/RetrieveArticleRequest.ts b/src/api/resources/unstable/resources/articles/client/requests/RetrieveArticleRequest.ts new file mode 100644 index 00000000..d9920ed0 --- /dev/null +++ b/src/api/resources/unstable/resources/articles/client/requests/RetrieveArticleRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1 + * } + */ +export interface RetrieveArticleRequest { + /** + * The unique identifier for the article which is given by Intercom. + */ + id: number; +} diff --git a/src/api/resources/unstable/resources/articles/client/requests/SearchArticlesRequest.ts b/src/api/resources/unstable/resources/articles/client/requests/SearchArticlesRequest.ts new file mode 100644 index 00000000..7c07777d --- /dev/null +++ b/src/api/resources/unstable/resources/articles/client/requests/SearchArticlesRequest.ts @@ -0,0 +1,29 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * phrase: "Getting started", + * state: "published" + * } + */ +export interface SearchArticlesRequest { + /** + * The phrase within your articles to search for. + */ + phrase?: string; + /** + * The state of the Articles returned. One of `published`, `draft` or `all`. + */ + state?: string; + /** + * The ID of the Help Center to search in. + */ + help_center_id?: number; + /** + * Return a highlighted version of the matching content within your articles. Refer to the response schema for more details. + */ + highlight?: boolean; +} diff --git a/src/api/resources/unstable/resources/articles/client/requests/index.ts b/src/api/resources/unstable/resources/articles/client/requests/index.ts new file mode 100644 index 00000000..a0beaf5f --- /dev/null +++ b/src/api/resources/unstable/resources/articles/client/requests/index.ts @@ -0,0 +1,3 @@ +export { type RetrieveArticleRequest } from "./RetrieveArticleRequest"; +export { type DeleteArticleRequest } from "./DeleteArticleRequest"; +export { type SearchArticlesRequest } from "./SearchArticlesRequest"; diff --git a/src/api/resources/unstable/resources/articles/index.ts b/src/api/resources/unstable/resources/articles/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/articles/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/articles/types/Article.ts b/src/api/resources/unstable/resources/articles/types/Article.ts new file mode 100644 index 00000000..adb8fda9 --- /dev/null +++ b/src/api/resources/unstable/resources/articles/types/Article.ts @@ -0,0 +1,12 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * The Articles API is a central place to gather all information and take actions on your articles. Articles can live within collections and sections, or alternatively they can stand alone. + */ +export interface Article extends Intercom.unstable.ArticleListItem { + statistics?: Intercom.unstable.ArticleStatistics; +} diff --git a/src/api/resources/unstable/resources/articles/types/ArticleListItem.ts b/src/api/resources/unstable/resources/articles/types/ArticleListItem.ts new file mode 100644 index 00000000..01c385fe --- /dev/null +++ b/src/api/resources/unstable/resources/articles/types/ArticleListItem.ts @@ -0,0 +1,53 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * The data returned about your articles when you list them. + */ +export interface ArticleListItem { + /** The type of object - `article`. */ + type?: "article"; + /** The unique identifier for the article which is given by Intercom. */ + id?: string; + /** The id of the workspace which the article belongs to. */ + workspace_id?: string; + /** The title of the article. For multilingual articles, this will be the title of the default language's content. */ + title?: string; + /** The description of the article. For multilingual articles, this will be the description of the default language's content. */ + description?: string; + /** The body of the article in HTML. For multilingual articles, this will be the body of the default language's content. */ + body?: string; + /** The id of the author of the article. For multilingual articles, this will be the id of the author of the default language's content. Must be a teammate on the help center's workspace. */ + author_id?: number; + /** Whether the article is `published` or is a `draft`. For multilingual articles, this will be the state of the default language's content. */ + state?: ArticleListItem.State; + /** The time when the article was created. For multilingual articles, this will be the timestamp of creation of the default language's content in seconds. */ + created_at?: number; + /** The time when the article was last updated. For multilingual articles, this will be the timestamp of last update of the default language's content in seconds. */ + updated_at?: number; + /** The URL of the article. For multilingual articles, this will be the URL of the default language's content. */ + url?: string; + /** The id of the article's parent collection or section. An article without this field stands alone. */ + parent_id?: number; + /** The ids of the article's parent collections or sections. An article without this field stands alone. */ + parent_ids?: number[]; + /** The type of parent, which can either be a `collection` or `section`. */ + parent_type?: string; + /** The default locale of the help center. This field is only returned for multilingual help centers. */ + default_locale?: string; + translated_content?: Intercom.unstable.ArticleTranslatedContent; +} + +export namespace ArticleListItem { + /** + * Whether the article is `published` or is a `draft`. For multilingual articles, this will be the state of the default language's content. + */ + export type State = "published" | "draft"; + export const State = { + Published: "published", + Draft: "draft", + } as const; +} diff --git a/src/api/resources/unstable/resources/articles/types/ArticleSearchHighlights.ts b/src/api/resources/unstable/resources/articles/types/ArticleSearchHighlights.ts new file mode 100644 index 00000000..5e1f607b --- /dev/null +++ b/src/api/resources/unstable/resources/articles/types/ArticleSearchHighlights.ts @@ -0,0 +1,67 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The highlighted results of an Article search. In the examples provided my search query is always "my query". + */ +export interface ArticleSearchHighlights { + /** The ID of the corresponding article. */ + article_id?: string; + /** An Article title highlighted. */ + highlighted_title?: ArticleSearchHighlights.HighlightedTitle.Item[]; + /** An Article description and body text highlighted. */ + highlighted_summary?: ArticleSearchHighlights.HighlightedSummary.Item[][]; +} + +export namespace ArticleSearchHighlights { + export type HighlightedTitle = HighlightedTitle.Item[]; + + export namespace HighlightedTitle { + /** + * A highlighted article title. + */ + export interface Item { + /** The type of text - `highlight` or `plain`. */ + type?: Item.Type; + /** The text of the title. */ + text?: string; + } + + export namespace Item { + /** + * The type of text - `highlight` or `plain`. + */ + export type Type = "highlight" | "plain"; + export const Type = { + Highlight: "highlight", + Plain: "plain", + } as const; + } + } + + export type HighlightedSummary = HighlightedSummary.Item[]; + + export namespace HighlightedSummary { + /** + * An instance of highlighted summary text. + */ + export interface Item { + /** The type of text - `highlight` or `plain`. */ + type?: Item.Type; + /** The text of the title. */ + text?: string; + } + + export namespace Item { + /** + * The type of text - `highlight` or `plain`. + */ + export type Type = "highlight" | "plain"; + export const Type = { + Highlight: "highlight", + Plain: "plain", + } as const; + } + } +} diff --git a/src/api/resources/unstable/resources/articles/types/ArticleSearchResponse.ts b/src/api/resources/unstable/resources/articles/types/ArticleSearchResponse.ts new file mode 100644 index 00000000..38cd179a --- /dev/null +++ b/src/api/resources/unstable/resources/articles/types/ArticleSearchResponse.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * The results of an Article search + */ +export interface ArticleSearchResponse { + /** The type of the object - `list`. */ + type?: "list"; + /** The total number of Articles matching the search query */ + total_count?: number; + /** An object containing the results of the search. */ + data?: ArticleSearchResponse.Data; + pages?: Intercom.unstable.CursorPages; +} + +export namespace ArticleSearchResponse { + /** + * An object containing the results of the search. + */ + export interface Data { + /** An array of Article objects */ + articles?: Intercom.unstable.Article[]; + /** A corresponding array of highlighted Article content */ + highlights?: Intercom.unstable.ArticleSearchHighlights[]; + } +} diff --git a/src/api/resources/unstable/resources/articles/types/index.ts b/src/api/resources/unstable/resources/articles/types/index.ts new file mode 100644 index 00000000..815412c7 --- /dev/null +++ b/src/api/resources/unstable/resources/articles/types/index.ts @@ -0,0 +1,4 @@ +export * from "./Article"; +export * from "./ArticleListItem"; +export * from "./ArticleSearchHighlights"; +export * from "./ArticleSearchResponse"; diff --git a/src/api/resources/unstable/resources/awayStatusReasons/client/Client.ts b/src/api/resources/unstable/resources/awayStatusReasons/client/Client.ts new file mode 100644 index 00000000..9ff1532d --- /dev/null +++ b/src/api/resources/unstable/resources/awayStatusReasons/client/Client.ts @@ -0,0 +1,170 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace AwayStatusReasons { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Away Status Reasons + */ +export class AwayStatusReasons { + constructor(protected readonly _options: AwayStatusReasons.Options = {}) {} + + /** + * Returns a list of all away status reasons configured for the workspace, including deleted ones. + * + * @param {AwayStatusReasons.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.awayStatusReasons.listAwayStatusReasons() + */ + public listAwayStatusReasons( + requestOptions?: AwayStatusReasons.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAwayStatusReasons(requestOptions)); + } + + private async __listAwayStatusReasons( + requestOptions?: AwayStatusReasons.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "away_status_reasons", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.AwayStatusReason[], rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /away_status_reasons."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/awayStatusReasons/client/index.ts b/src/api/resources/unstable/resources/awayStatusReasons/client/index.ts new file mode 100644 index 00000000..cb0ff5c3 --- /dev/null +++ b/src/api/resources/unstable/resources/awayStatusReasons/client/index.ts @@ -0,0 +1 @@ +export {}; diff --git a/src/api/resources/customChannelEvents/index.ts b/src/api/resources/unstable/resources/awayStatusReasons/index.ts similarity index 100% rename from src/api/resources/customChannelEvents/index.ts rename to src/api/resources/unstable/resources/awayStatusReasons/index.ts diff --git a/src/api/resources/unstable/resources/companies/client/Client.ts b/src/api/resources/unstable/resources/companies/client/Client.ts new file mode 100644 index 00000000..b5593293 --- /dev/null +++ b/src/api/resources/unstable/resources/companies/client/Client.ts @@ -0,0 +1,1196 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Companies { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Companies + */ +export class Companies { + constructor(protected readonly _options: Companies.Options = {}) {} + + /** + * You can fetch a single company by passing in `company_id` or `name`. + * + * `https://api.intercom.io/companies?name={name}` + * + * `https://api.intercom.io/companies?company_id={company_id}` + * + * You can fetch all companies and filter by `segment_id` or `tag_id` as a query parameter. + * + * `https://api.intercom.io/companies?tag_id={tag_id}` + * + * `https://api.intercom.io/companies?segment_id={segment_id}` + * + * @param {Intercom.unstable.RetrieveCompanyRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.companies.retrieveCompany({ + * name: "my company", + * company_id: "12345", + * tag_id: "678910", + * segment_id: "98765" + * }) + */ + public retrieveCompany( + request: Intercom.unstable.RetrieveCompanyRequest = {}, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveCompany(request, requestOptions)); + } + + private async __retrieveCompany( + request: Intercom.unstable.RetrieveCompanyRequest = {}, + requestOptions?: Companies.RequestOptions, + ): Promise> { + const { name, company_id: companyId, tag_id: tagId, segment_id: segmentId, page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (name != null) { + _queryParams["name"] = name; + } + + if (companyId != null) { + _queryParams["company_id"] = companyId; + } + + if (tagId != null) { + _queryParams["tag_id"] = tagId; + } + + if (segmentId != null) { + _queryParams["segment_id"] = segmentId; + } + + if (page != null) { + _queryParams["page"] = page.toString(); + } + + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "companies", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.CompanyList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can create or update a company. + * + * Companies will be only visible in Intercom when there is at least one associated user. + * + * Companies are looked up via `company_id` in a `POST` request, if not found via `company_id`, the new company will be created, if found, that company will be updated. + * + * {% admonition type="warning" name="Using `company_id`" %} + * You can set a unique `company_id` value when creating a company. However, it is not possible to update `company_id`. Be sure to set a unique value once upon creation of the company. + * {% /admonition %} + * + * @param {unknown} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.companies.createOrUpdateCompany({ + * "key": "value" + * }) + */ + public createOrUpdateCompany( + request?: unknown, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createOrUpdateCompany(request, requestOptions)); + } + + private async __createOrUpdateCompany( + request?: unknown, + requestOptions?: Companies.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "companies", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Company, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /companies."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch a single company. + * + * @param {Intercom.unstable.RetrieveACompanyByIdRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.companies.retrieveACompanyById({ + * id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * }) + */ + public retrieveACompanyById( + request: Intercom.unstable.RetrieveACompanyByIdRequest, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveACompanyById(request, requestOptions)); + } + + private async __retrieveACompanyById( + request: Intercom.unstable.RetrieveACompanyByIdRequest, + requestOptions?: Companies.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Company, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can update a single company using the Intercom provisioned `id`. + * + * {% admonition type="warning" name="Using `company_id`" %} + * When updating a company it is not possible to update `company_id`. This can only be set once upon creation of the company. + * {% /admonition %} + * + * @param {Intercom.unstable.UpdateCompanyRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.companies.updateCompany({ + * id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * }) + */ + public updateCompany( + request: Intercom.unstable.UpdateCompanyRequest, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateCompany(request, requestOptions)); + } + + private async __updateCompany( + request: Intercom.unstable.UpdateCompanyRequest, + requestOptions?: Companies.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(id)}`, + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Company, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /companies/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can delete a single company. + * + * @param {Intercom.unstable.DeleteCompanyRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.companies.deleteCompany({ + * id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * }) + */ + public deleteCompany( + request: Intercom.unstable.DeleteCompanyRequest, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteCompany(request, requestOptions)); + } + + private async __deleteCompany( + request: Intercom.unstable.DeleteCompanyRequest, + requestOptions?: Companies.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.DeletedCompanyObject, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /companies/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch a list of all contacts that belong to a company. + * + * @param {Intercom.unstable.ListAttachedContactsRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.companies.listAttachedContacts({ + * id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * }) + */ + public listAttachedContacts( + request: Intercom.unstable.ListAttachedContactsRequest, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAttachedContacts(request, requestOptions)); + } + + private async __listAttachedContacts( + request: Intercom.unstable.ListAttachedContactsRequest, + requestOptions?: Companies.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(id)}/contacts`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.CompanyAttachedContacts, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/{id}/contacts."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch a list of all segments that belong to a company. + * + * @param {Intercom.unstable.ListAttachedSegmentsForCompaniesRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.companies.listAttachedSegmentsForCompanies({ + * id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * }) + */ + public listAttachedSegmentsForCompanies( + request: Intercom.unstable.ListAttachedSegmentsForCompaniesRequest, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAttachedSegmentsForCompanies(request, requestOptions)); + } + + private async __listAttachedSegmentsForCompanies( + request: Intercom.unstable.ListAttachedSegmentsForCompaniesRequest, + requestOptions?: Companies.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `companies/${encodeURIComponent(id)}/segments`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.CompanyAttachedSegments, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/{id}/segments."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can list companies. The company list is sorted by the `last_request_at` field and by default is ordered descending, most recently requested first. + * + * Note that the API does not include companies who have no associated users in list responses. + * + * When using the Companies endpoint and the pages object to iterate through the returned companies, there is a limit of 10,000 Companies that can be returned. If you need to list or iterate on more than 10,000 Companies, please use the [Scroll API](https://developers.intercom.com/reference#iterating-over-all-companies). + * {% admonition type="warning" name="Pagination" %} + * You can use pagination to limit the number of results returned. The default is `20` results per page. + * See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. + * {% /admonition %} + * + * @param {Intercom.unstable.ListAllCompaniesRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.companies.listAllCompanies({ + * order: "desc" + * }) + */ + public listAllCompanies( + request: Intercom.unstable.ListAllCompaniesRequest = {}, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAllCompanies(request, requestOptions)); + } + + private async __listAllCompanies( + request: Intercom.unstable.ListAllCompaniesRequest = {}, + requestOptions?: Companies.RequestOptions, + ): Promise> { + const { page, per_page: perPage, order } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams["page"] = page.toString(); + } + + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + + if (order != null) { + _queryParams["order"] = order; + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "companies/list", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.CompanyList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /companies/list."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * The `list all companies` functionality does not work well for huge datasets, and can result in errors and performance problems when paging deeply. The Scroll API provides an efficient mechanism for iterating over all companies in a dataset. + * + * - Each app can only have 1 scroll open at a time. You'll get an error message if you try to have more than one open per app. + * - If the scroll isn't used for 1 minute, it expires and calls with that scroll param will fail + * - If the end of the scroll is reached, "companies" will be empty and the scroll parameter will expire + * + * {% admonition type="info" name="Scroll Parameter" %} + * You can get the first page of companies by simply sending a GET request to the scroll endpoint. + * For subsequent requests you will need to use the scroll parameter from the response. + * {% /admonition %} + * {% admonition type="danger" name="Scroll network timeouts" %} + * Since scroll is often used on large datasets network errors such as timeouts can be encountered. When this occurs you will see a HTTP 500 error with the following message: + * "Request failed due to an internal network error. Please restart the scroll operation." + * If this happens, you will need to restart your scroll query: It is not possible to continue from a specific point when using scroll. + * {% /admonition %} + * + * @param {Intercom.unstable.ScrollOverAllCompaniesRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.companies.scrollOverAllCompanies() + */ + public scrollOverAllCompanies( + request: Intercom.unstable.ScrollOverAllCompaniesRequest = {}, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__scrollOverAllCompanies(request, requestOptions)); + } + + private async __scrollOverAllCompanies( + request: Intercom.unstable.ScrollOverAllCompaniesRequest = {}, + requestOptions?: Companies.RequestOptions, + ): Promise> { + const { scroll_param: scrollParam } = request; + const _queryParams: Record = {}; + if (scrollParam != null) { + _queryParams["scroll_param"] = scrollParam; + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "companies/scroll", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.CompanyScroll | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/scroll."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can attach a company to a single contact. + * + * @param {Intercom.unstable.AttachContactToACompanyRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.companies.attachContactToACompany({ + * id: "id", + * company_id: "6762f09a1bb69f9f2193bb34" + * }) + * + * @example + * await client.unstable.companies.attachContactToACompany({ + * id: "id", + * company_id: "58a430d35458202d41b1e65b" + * }) + * + * @example + * await client.unstable.companies.attachContactToACompany({ + * id: "id", + * company_id: "123" + * }) + */ + public attachContactToACompany( + request: Intercom.unstable.AttachContactToACompanyRequest, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__attachContactToACompany(request, requestOptions)); + } + + private async __attachContactToACompany( + request: Intercom.unstable.AttachContactToACompanyRequest, + requestOptions?: Companies.RequestOptions, + ): Promise> { + const { id, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(id)}/companies`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Company, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/{id}/companies."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can detach a company from a single contact. + * + * @param {Intercom.unstable.DetachContactFromACompanyRequest} request + * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.companies.detachContactFromACompany({ + * contact_id: "58a430d35458202d41b1e65b", + * id: "58a430d35458202d41b1e65b" + * }) + */ + public detachContactFromACompany( + request: Intercom.unstable.DetachContactFromACompanyRequest, + requestOptions?: Companies.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__detachContactFromACompany(request, requestOptions)); + } + + private async __detachContactFromACompany( + request: Intercom.unstable.DetachContactFromACompanyRequest, + requestOptions?: Companies.RequestOptions, + ): Promise> { + const { contact_id: contactId, id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/companies/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Company, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /contacts/{contact_id}/companies/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/companies/client/index.ts b/src/api/resources/unstable/resources/companies/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/companies/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/companies/client/requests/AttachContactToACompanyRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/AttachContactToACompanyRequest.ts new file mode 100644 index 00000000..d82657ba --- /dev/null +++ b/src/api/resources/unstable/resources/companies/client/requests/AttachContactToACompanyRequest.ts @@ -0,0 +1,31 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "id", + * company_id: "6762f09a1bb69f9f2193bb34" + * } + * + * @example + * { + * id: "id", + * company_id: "58a430d35458202d41b1e65b" + * } + * + * @example + * { + * id: "id", + * company_id: "123" + * } + */ +export interface AttachContactToACompanyRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + id: string; + /** The unique identifier for the company which is given by Intercom */ + company_id: string; +} diff --git a/src/api/resources/unstable/resources/companies/client/requests/DeleteCompanyRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/DeleteCompanyRequest.ts new file mode 100644 index 00000000..abe9080b --- /dev/null +++ b/src/api/resources/unstable/resources/companies/client/requests/DeleteCompanyRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * } + */ +export interface DeleteCompanyRequest { + /** + * The unique identifier for the company which is given by Intercom + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/companies/client/requests/DetachContactFromACompanyRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/DetachContactFromACompanyRequest.ts new file mode 100644 index 00000000..3cbcb14d --- /dev/null +++ b/src/api/resources/unstable/resources/companies/client/requests/DetachContactFromACompanyRequest.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "58a430d35458202d41b1e65b", + * id: "58a430d35458202d41b1e65b" + * } + */ +export interface DetachContactFromACompanyRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; + /** + * The unique identifier for the company which is given by Intercom + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/companies/client/requests/ListAllCompaniesRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/ListAllCompaniesRequest.ts new file mode 100644 index 00000000..0829eab0 --- /dev/null +++ b/src/api/resources/unstable/resources/companies/client/requests/ListAllCompaniesRequest.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * order: "desc" + * } + */ +export interface ListAllCompaniesRequest { + /** + * The page of results to fetch. Defaults to first page + */ + page?: number; + /** + * How many results to return per page. Defaults to 15 + */ + per_page?: number; + /** + * `asc` or `desc`. Return the companies in ascending or descending order. Defaults to desc + */ + order?: string; +} diff --git a/src/api/resources/unstable/resources/companies/client/requests/ListAttachedContactsRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/ListAttachedContactsRequest.ts new file mode 100644 index 00000000..0dc176ea --- /dev/null +++ b/src/api/resources/unstable/resources/companies/client/requests/ListAttachedContactsRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * } + */ +export interface ListAttachedContactsRequest { + /** + * The unique identifier for the company which is given by Intercom + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/companies/client/requests/ListAttachedSegmentsForCompaniesRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/ListAttachedSegmentsForCompaniesRequest.ts new file mode 100644 index 00000000..3e2c05a4 --- /dev/null +++ b/src/api/resources/unstable/resources/companies/client/requests/ListAttachedSegmentsForCompaniesRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * } + */ +export interface ListAttachedSegmentsForCompaniesRequest { + /** + * The unique identifier for the company which is given by Intercom + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/companies/client/requests/RetrieveACompanyByIdRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/RetrieveACompanyByIdRequest.ts new file mode 100644 index 00000000..8b4afb24 --- /dev/null +++ b/src/api/resources/unstable/resources/companies/client/requests/RetrieveACompanyByIdRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * } + */ +export interface RetrieveACompanyByIdRequest { + /** + * The unique identifier for the company which is given by Intercom + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/companies/client/requests/RetrieveCompanyRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/RetrieveCompanyRequest.ts new file mode 100644 index 00000000..557a2e00 --- /dev/null +++ b/src/api/resources/unstable/resources/companies/client/requests/RetrieveCompanyRequest.ts @@ -0,0 +1,39 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * name: "my company", + * company_id: "12345", + * tag_id: "678910", + * segment_id: "98765" + * } + */ +export interface RetrieveCompanyRequest { + /** + * The `name` of the company to filter by. + */ + name?: string; + /** + * The `company_id` of the company to filter by. + */ + company_id?: string; + /** + * The `tag_id` of the company to filter by. + */ + tag_id?: string; + /** + * The `segment_id` of the company to filter by. + */ + segment_id?: string; + /** + * The page of results to fetch. Defaults to first page + */ + page?: number; + /** + * How many results to display per page. Defaults to 15 + */ + per_page?: number; +} diff --git a/src/api/resources/unstable/resources/companies/client/requests/ScrollOverAllCompaniesRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/ScrollOverAllCompaniesRequest.ts new file mode 100644 index 00000000..9d7a6877 --- /dev/null +++ b/src/api/resources/unstable/resources/companies/client/requests/ScrollOverAllCompaniesRequest.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * {} + */ +export interface ScrollOverAllCompaniesRequest { + /** + * + */ + scroll_param?: string; +} diff --git a/src/api/resources/unstable/resources/companies/client/requests/UpdateCompanyRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/UpdateCompanyRequest.ts new file mode 100644 index 00000000..1b2d26a4 --- /dev/null +++ b/src/api/resources/unstable/resources/companies/client/requests/UpdateCompanyRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * } + */ +export interface UpdateCompanyRequest { + /** + * The unique identifier for the company which is given by Intercom + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/companies/client/requests/index.ts b/src/api/resources/unstable/resources/companies/client/requests/index.ts new file mode 100644 index 00000000..2db00d94 --- /dev/null +++ b/src/api/resources/unstable/resources/companies/client/requests/index.ts @@ -0,0 +1,10 @@ +export { type RetrieveCompanyRequest } from "./RetrieveCompanyRequest"; +export { type RetrieveACompanyByIdRequest } from "./RetrieveACompanyByIdRequest"; +export { type UpdateCompanyRequest } from "./UpdateCompanyRequest"; +export { type DeleteCompanyRequest } from "./DeleteCompanyRequest"; +export { type ListAttachedContactsRequest } from "./ListAttachedContactsRequest"; +export { type ListAttachedSegmentsForCompaniesRequest } from "./ListAttachedSegmentsForCompaniesRequest"; +export { type ListAllCompaniesRequest } from "./ListAllCompaniesRequest"; +export { type ScrollOverAllCompaniesRequest } from "./ScrollOverAllCompaniesRequest"; +export { type AttachContactToACompanyRequest } from "./AttachContactToACompanyRequest"; +export { type DetachContactFromACompanyRequest } from "./DetachContactFromACompanyRequest"; diff --git a/src/api/resources/unstable/resources/companies/index.ts b/src/api/resources/unstable/resources/companies/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/companies/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/companies/types/Company.ts b/src/api/resources/unstable/resources/companies/types/Company.ts new file mode 100644 index 00000000..ebce2925 --- /dev/null +++ b/src/api/resources/unstable/resources/companies/types/Company.ts @@ -0,0 +1,77 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * Companies allow you to represent organizations using your product. Each company will have its own description and be associated with contacts. You can fetch, create, update and list companies. + */ +export interface Company { + /** Value is `company` */ + type?: "company"; + /** The Intercom defined id representing the company. */ + id?: string; + /** The name of the company. */ + name?: string; + /** The Intercom defined code of the workspace the company is associated to. */ + app_id?: string; + plan?: Company.Plan; + /** The company id you have defined for the company. */ + company_id?: string; + /** The time the company was created by you. */ + remote_created_at?: number; + /** The time the company was added in Intercom. */ + created_at?: number; + /** The last time the company was updated. */ + updated_at?: number; + /** The time the company last recorded making a request. */ + last_request_at?: number; + /** The number of employees in the company. */ + size?: number; + /** The URL for the company website. */ + website?: string; + /** The industry that the company operates in. */ + industry?: string; + /** How much revenue the company generates for your business. */ + monthly_spend?: number; + /** How many sessions the company has recorded. */ + session_count?: number; + /** The number of users in the company. */ + user_count?: number; + /** The custom attributes you have set on the company. */ + custom_attributes?: Record; + /** The list of tags associated with the company */ + tags?: Company.Tags; + /** The list of segments associated with the company */ + segments?: Company.Segments; +} + +export namespace Company { + export interface Plan { + /** Value is always "plan" */ + type?: string; + /** The id of the plan */ + id?: string; + /** The name of the plan */ + name?: string; + } + + /** + * The list of tags associated with the company + */ + export interface Tags { + /** The type of the object */ + type?: "tag.list"; + tags?: unknown[]; + } + + /** + * The list of segments associated with the company + */ + export interface Segments { + /** The type of the object */ + type?: "segment.list"; + segments?: Intercom.unstable.Segment[]; + } +} diff --git a/src/api/resources/unstable/resources/companies/types/index.ts b/src/api/resources/unstable/resources/companies/types/index.ts new file mode 100644 index 00000000..d15bbd39 --- /dev/null +++ b/src/api/resources/unstable/resources/companies/types/index.ts @@ -0,0 +1 @@ +export * from "./Company"; diff --git a/src/api/resources/unstable/resources/contacts/client/Client.ts b/src/api/resources/unstable/resources/contacts/client/Client.ts new file mode 100644 index 00000000..432c912e --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/Client.ts @@ -0,0 +1,1536 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Contacts { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your contacts + */ +export class Contacts { + constructor(protected readonly _options: Contacts.Options = {}) {} + + /** + * You can fetch a list of companies that are associated to a contact. + * + * @param {Intercom.unstable.ListCompaniesForAContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.contacts.listCompaniesForAContact({ + * id: "63a07ddf05a32042dffac965" + * }) + */ + public listCompaniesForAContact( + request: Intercom.unstable.ListCompaniesForAContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listCompaniesForAContact(request, requestOptions)); + } + + private async __listCompaniesForAContact( + request: Intercom.unstable.ListCompaniesForAContactRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(id)}/companies`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.ContactAttachedCompanies, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts/{id}/companies."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch a list of segments that are associated to a contact. + * + * @param {Intercom.unstable.ListSegmentsForAContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.contacts.listSegmentsForAContact({ + * contact_id: "63a07ddf05a32042dffac965" + * }) + */ + public listSegmentsForAContact( + request: Intercom.unstable.ListSegmentsForAContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listSegmentsForAContact(request, requestOptions)); + } + + private async __listSegmentsForAContact( + request: Intercom.unstable.ListSegmentsForAContactRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const { contact_id: contactId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/segments`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ContactSegments, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /contacts/{contact_id}/segments.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch a list of subscription types that are attached to a contact. These can be subscriptions that a user has 'opted-in' to or has 'opted-out' from, depending on the subscription type. + * This will return a list of Subscription Type objects that the contact is associated with. + * + * The data property will show a combined list of: + * + * 1.Opt-out subscription types that the user has opted-out from. + * 2.Opt-in subscription types that the user has opted-in to receiving. + * + * @param {Intercom.unstable.ListSubscriptionsForAContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.contacts.listSubscriptionsForAContact({ + * contact_id: "63a07ddf05a32042dffac965" + * }) + */ + public listSubscriptionsForAContact( + request: Intercom.unstable.ListSubscriptionsForAContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listSubscriptionsForAContact(request, requestOptions)); + } + + private async __listSubscriptionsForAContact( + request: Intercom.unstable.ListSubscriptionsForAContactRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const { contact_id: contactId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/subscriptions`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.SubscriptionTypeList, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /contacts/{contact_id}/subscriptions.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch a list of all tags that are attached to a specific contact. + * + * @param {Intercom.unstable.ListTagsForAContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.contacts.listTagsForAContact({ + * contact_id: "63a07ddf05a32042dffac965" + * }) + */ + public listTagsForAContact( + request: Intercom.unstable.ListTagsForAContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listTagsForAContact(request, requestOptions)); + } + + private async __listTagsForAContact( + request: Intercom.unstable.ListTagsForAContactRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const { contact_id: contactId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/tags`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.TagList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts/{contact_id}/tags."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch the details of a single contact. + * + * @param {Intercom.unstable.ShowContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.contacts.showContact({ + * id: "63a07ddf05a32042dffac965" + * }) + */ + public showContact( + request: Intercom.unstable.ShowContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__showContact(request, requestOptions)); + } + + private async __showContact( + request: Intercom.unstable.ShowContactRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.ShowContactResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can update an existing contact (ie. user or lead). + * + * {% admonition type="info" %} + * This endpoint handles both **contact updates** and **custom object associations**. + * + * See _`update a contact with an association to a custom object instance`_ in the request/response examples to see the custom object association format. + * {% /admonition %} + * + * @param {Intercom.unstable.UpdateContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.contacts.updateContact({ + * id: "63a07ddf05a32042dffac965", + * email: "joebloggs@intercom.io", + * name: "joe bloggs" + * }) + * + * @example + * await client.unstable.contacts.updateContact({ + * id: "63a07ddf05a32042dffac965", + * custom_attributes: { + * "order": [ + * "21" + * ] + * } + * }) + */ + public updateContact( + request: Intercom.unstable.UpdateContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateContact(request, requestOptions)); + } + + private async __updateContact( + request: Intercom.unstable.UpdateContactRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const { id, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(id)}`, + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.UpdateContactResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /contacts/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can delete a single contact. + * + * @param {Intercom.unstable.DeleteContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.contacts.deleteContact({ + * id: "id" + * }) + */ + public deleteContact( + request: Intercom.unstable.DeleteContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteContact(request, requestOptions)); + } + + private async __deleteContact( + request: Intercom.unstable.DeleteContactRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ContactDeleted, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /contacts/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can merge a contact with a `role` of `lead` into a contact with a `role` of `user`. + * + * @param {Intercom.unstable.MergeContactsRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.contacts.mergeContact({ + * from: "6762f0d51bb69f9f2193bb7f", + * into: "6762f0d51bb69f9f2193bb80" + * }) + */ + public mergeContact( + request: Intercom.unstable.MergeContactsRequest = {}, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__mergeContact(request, requestOptions)); + } + + private async __mergeContact( + request: Intercom.unstable.MergeContactsRequest = {}, + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "contacts/merge", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.MergeContactResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/merge."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can search for multiple contacts by the value of their attributes in order to fetch exactly who you want. + * + * To search for contacts, you need to send a `POST` request to `https://api.intercom.io/contacts/search`. + * + * This will accept a query object in the body which will define your filters in order to search for contacts. + * + * {% admonition type="warning" name="Optimizing search queries" %} + * Search queries can be complex, so optimizing them can help the performance of your search. + * Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize + * pagination to limit the number of results returned. The default is `50` results per page. + * See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. + * {% /admonition %} + * ### Contact Creation Delay + * + * If a contact has recently been created, there is a possibility that it will not yet be available when searching. This means that it may not appear in the response. This delay can take a few minutes. If you need to be instantly notified it is recommended to use webhooks and iterate to see if they match your search filters. + * + * ### Nesting & Limitations + * + * You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). + * There are some limitations to the amount of multiple's there can be: + * * There's a limit of max 2 nested filters + * * There's a limit of max 15 filters for each AND or OR group + * + * ### Searching for Timestamp Fields + * + * All timestamp fields (created_at, updated_at etc.) are indexed as Dates for Contact Search queries; Datetime queries are not currently supported. This means you can only query for timestamp fields by day - not hour, minute or second. + * For example, if you search for all Contacts with a created_at value greater (>) than 1577869200 (the UNIX timestamp for January 1st, 2020 9:00 AM), that will be interpreted as 1577836800 (January 1st, 2020 12:00 AM). The search results will then include Contacts created from January 2nd, 2020 12:00 AM onwards. + * If you'd like to get contacts created on January 1st, 2020 you should search with a created_at value equal (=) to 1577836800 (January 1st, 2020 12:00 AM). + * This behaviour applies only to timestamps used in search queries. The search results will still contain the full UNIX timestamp and be sorted accordingly. + * + * ### Accepted Fields + * + * Most key listed as part of the Contacts Model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). + * + * | Field | Type | + * | ---------------------------------- | ------------------------------ | + * | id | String | + * | role | String
Accepts user or lead | + * | name | String | + * | avatar | String | + * | owner_id | Integer | + * | email | String | + * | email_domain | String | + * | phone | String | + * | formatted_phone | String | + * | external_id | String | + * | created_at | Date (UNIX Timestamp) | + * | signed_up_at | Date (UNIX Timestamp) | + * | updated_at | Date (UNIX Timestamp) | + * | last_seen_at | Date (UNIX Timestamp) | + * | last_contacted_at | Date (UNIX Timestamp) | + * | last_replied_at | Date (UNIX Timestamp) | + * | last_email_opened_at | Date (UNIX Timestamp) | + * | last_email_clicked_at | Date (UNIX Timestamp) | + * | language_override | String | + * | browser | String | + * | browser_language | String | + * | os | String | + * | location.country | String | + * | location.region | String | + * | location.city | String | + * | unsubscribed_from_emails | Boolean | + * | marked_email_as_spam | Boolean | + * | has_hard_bounced | Boolean | + * | ios_last_seen_at | Date (UNIX Timestamp) | + * | ios_app_version | String | + * | ios_device | String | + * | ios_app_device | String | + * | ios_os_version | String | + * | ios_app_name | String | + * | ios_sdk_version | String | + * | android_last_seen_at | Date (UNIX Timestamp) | + * | android_app_version | String | + * | android_device | String | + * | android_app_name | String | + * | andoid_sdk_version | String | + * | segment_id | String | + * | tag_id | String | + * | custom_attributes.{attribute_name} | String | + * + * ### Accepted Operators + * + * {% admonition type="warning" name="Searching based on `created_at`" %} + * You cannot use the `<=` or `>=` operators to search by `created_at`. + * {% /admonition %} + * + * The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + * + * | Operator | Valid Types | Description | + * | :------- | :------------------------------- | :--------------------------------------------------------------- | + * | = | All | Equals | + * | != | All | Doesn't Equal | + * | IN | All | In
Shortcut for `OR` queries
Values must be in Array | + * | NIN | All | Not In
Shortcut for `OR !` queries
Values must be in Array | + * | > | Integer
Date (UNIX Timestamp) | Greater than | + * | < | Integer
Date (UNIX Timestamp) | Lower than | + * | ~ | String | Contains | + * | !~ | String | Doesn't Contain | + * | ^ | String | Starts With | + * | $ | String | Ends With | + * + * @param {Intercom.unstable.SearchRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.contacts.searchContacts({ + * query: { + * operator: "AND", + * value: [{ + * field: "created_at", + * operator: ">", + * value: "1306054154" + * }] + * }, + * pagination: { + * per_page: 5 + * } + * }) + */ + public searchContacts( + request: Intercom.unstable.SearchRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__searchContacts(request, requestOptions)); + } + + private async __searchContacts( + request: Intercom.unstable.SearchRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "contacts/search", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ContactList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/search."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch a list of all contacts (ie. users or leads) in your workspace. + * {% admonition type="warning" name="Pagination" %} + * You can use pagination to limit the number of results returned. The default is `50` results per page. + * See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. + * {% /admonition %} + * + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.contacts.listContacts() + */ + public listContacts( + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listContacts(requestOptions)); + } + + private async __listContacts( + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "contacts", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ContactList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can create a new contact (ie. user or lead). + * + * @param {Intercom.CreateContactRequestTwo} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.contacts.createContact({ + * "email": "joebloggs@intercom.io" + * }) + */ + public createContact( + request?: Intercom.CreateContactRequestTwo, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createContact(request, requestOptions)); + } + + private async __createContact( + request?: Intercom.CreateContactRequestTwo, + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "contacts", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.CreateContactResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch the details of a single contact by external ID. Note that this endpoint only supports users and not leads. + * + * @param {Intercom.unstable.ShowContactByExternalIdRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.contacts.showContactByExternalId({ + * external_id: "cdd29344-5e0c-4ef0-ac56-f9ba2979bc27" + * }) + */ + public showContactByExternalId( + request: Intercom.unstable.ShowContactByExternalIdRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__showContactByExternalId(request, requestOptions)); + } + + private async __showContactByExternalId( + request: Intercom.unstable.ShowContactByExternalIdRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const { external_id: externalId } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/find_by_external_id/${encodeURIComponent(externalId)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.ShowContactByExternalIdResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /contacts/find_by_external_id/{external_id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can archive a single contact. + * + * @param {Intercom.unstable.ArchiveContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.unstable.contacts.archiveContact({ + * id: "63a07ddf05a32042dffac965" + * }) + */ + public archiveContact( + request: Intercom.unstable.ArchiveContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__archiveContact(request, requestOptions)); + } + + private async __archiveContact( + request: Intercom.unstable.ArchiveContactRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(id)}/archive`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ContactArchived, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/{id}/archive."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can unarchive a single contact. + * + * @param {Intercom.unstable.UnarchiveContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.unstable.contacts.unarchiveContact({ + * id: "63a07ddf05a32042dffac965" + * }) + */ + public unarchiveContact( + request: Intercom.unstable.UnarchiveContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__unarchiveContact(request, requestOptions)); + } + + private async __unarchiveContact( + request: Intercom.unstable.UnarchiveContactRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(id)}/unarchive`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ContactUnarchived, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/{id}/unarchive."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Block a single contact.
**Note:** conversations of the contact will also be archived during the process.
More details in [FAQ How do I block Inbox spam?](https://www.intercom.com/help/en/articles/8838656-inbox-faqs) + * + * @param {Intercom.unstable.BlockContactRequest} request + * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.unstable.contacts.blockContact({ + * id: "63a07ddf05a32042dffac965" + * }) + */ + public blockContact( + request: Intercom.unstable.BlockContactRequest, + requestOptions?: Contacts.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__blockContact(request, requestOptions)); + } + + private async __blockContact( + request: Intercom.unstable.BlockContactRequest, + requestOptions?: Contacts.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(id)}/block`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ContactBlocked, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/{id}/block."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/contacts/client/index.ts b/src/api/resources/unstable/resources/contacts/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/contacts/client/requests/ArchiveContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/ArchiveContactRequest.ts new file mode 100644 index 00000000..f44c40c3 --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/requests/ArchiveContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "63a07ddf05a32042dffac965" + * } + */ +export interface ArchiveContactRequest { + /** + * id + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/contacts/client/requests/BlockContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/BlockContactRequest.ts new file mode 100644 index 00000000..497e928a --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/requests/BlockContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "63a07ddf05a32042dffac965" + * } + */ +export interface BlockContactRequest { + /** + * id + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/contacts/client/requests/DeleteContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/DeleteContactRequest.ts new file mode 100644 index 00000000..e70f0504 --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/requests/DeleteContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "id" + * } + */ +export interface DeleteContactRequest { + /** + * id + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/contacts/client/requests/ListCompaniesForAContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/ListCompaniesForAContactRequest.ts new file mode 100644 index 00000000..af4ebe19 --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/requests/ListCompaniesForAContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "63a07ddf05a32042dffac965" + * } + */ +export interface ListCompaniesForAContactRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/contacts/client/requests/ListSegmentsForAContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/ListSegmentsForAContactRequest.ts new file mode 100644 index 00000000..22e71773 --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/requests/ListSegmentsForAContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965" + * } + */ +export interface ListSegmentsForAContactRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; +} diff --git a/src/api/resources/unstable/resources/contacts/client/requests/ListSubscriptionsForAContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/ListSubscriptionsForAContactRequest.ts new file mode 100644 index 00000000..3e48e0c9 --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/requests/ListSubscriptionsForAContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965" + * } + */ +export interface ListSubscriptionsForAContactRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; +} diff --git a/src/api/resources/unstable/resources/contacts/client/requests/ListTagsForAContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/ListTagsForAContactRequest.ts new file mode 100644 index 00000000..f91dffdc --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/requests/ListTagsForAContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965" + * } + */ +export interface ListTagsForAContactRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; +} diff --git a/src/api/resources/unstable/resources/contacts/client/requests/MergeContactsRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/MergeContactsRequest.ts new file mode 100644 index 00000000..a9009e6a --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/requests/MergeContactsRequest.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * from: "6762f0d51bb69f9f2193bb7f", + * into: "6762f0d51bb69f9f2193bb80" + * } + */ +export interface MergeContactsRequest { + /** The unique identifier for the contact to merge away from. Must be a lead. */ + from?: string; + /** The unique identifier for the contact to merge into. Must be a user. */ + into?: string; +} diff --git a/src/api/resources/unstable/resources/contacts/client/requests/ShowContactByExternalIdRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/ShowContactByExternalIdRequest.ts new file mode 100644 index 00000000..af3dff76 --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/requests/ShowContactByExternalIdRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * external_id: "cdd29344-5e0c-4ef0-ac56-f9ba2979bc27" + * } + */ +export interface ShowContactByExternalIdRequest { + /** + * The external ID of the user that you want to retrieve + */ + external_id: string; +} diff --git a/src/api/resources/unstable/resources/contacts/client/requests/ShowContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/ShowContactRequest.ts new file mode 100644 index 00000000..6abbc7ab --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/requests/ShowContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "63a07ddf05a32042dffac965" + * } + */ +export interface ShowContactRequest { + /** + * id + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/contacts/client/requests/UnarchiveContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/UnarchiveContactRequest.ts new file mode 100644 index 00000000..e6a5af5e --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/requests/UnarchiveContactRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "63a07ddf05a32042dffac965" + * } + */ +export interface UnarchiveContactRequest { + /** + * id + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/contacts/client/requests/UpdateContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/UpdateContactRequest.ts new file mode 100644 index 00000000..b130cd58 --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/requests/UpdateContactRequest.ts @@ -0,0 +1,50 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "63a07ddf05a32042dffac965", + * email: "joebloggs@intercom.io", + * name: "joe bloggs" + * } + * + * @example + * { + * id: "63a07ddf05a32042dffac965", + * custom_attributes: { + * "order": [ + * "21" + * ] + * } + * } + */ +export interface UpdateContactRequest { + /** + * id + */ + id: string; + /** The role of the contact. */ + role?: string; + /** A unique identifier for the contact which is given to Intercom */ + external_id?: string; + /** The contacts email */ + email?: string; + /** The contacts phone */ + phone?: string; + /** The contacts name */ + name?: string; + /** An image URL containing the avatar of a contact */ + avatar?: string; + /** The time specified for when a contact signed up */ + signed_up_at?: number; + /** The time when the contact was last seen (either where the Intercom Messenger was installed or when specified manually) */ + last_seen_at?: number; + /** The id of an admin that has been assigned account ownership of the contact */ + owner_id?: number; + /** Whether the contact is unsubscribed from emails */ + unsubscribed_from_emails?: boolean; + /** The custom attributes which are set for the contact */ + custom_attributes?: Record; +} diff --git a/src/api/resources/unstable/resources/contacts/client/requests/index.ts b/src/api/resources/unstable/resources/contacts/client/requests/index.ts new file mode 100644 index 00000000..2c00f2f2 --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/client/requests/index.ts @@ -0,0 +1,12 @@ +export { type ListCompaniesForAContactRequest } from "./ListCompaniesForAContactRequest"; +export { type ListSegmentsForAContactRequest } from "./ListSegmentsForAContactRequest"; +export { type ListSubscriptionsForAContactRequest } from "./ListSubscriptionsForAContactRequest"; +export { type ListTagsForAContactRequest } from "./ListTagsForAContactRequest"; +export { type ShowContactRequest } from "./ShowContactRequest"; +export { type UpdateContactRequest } from "./UpdateContactRequest"; +export { type DeleteContactRequest } from "./DeleteContactRequest"; +export { type MergeContactsRequest } from "./MergeContactsRequest"; +export { type ShowContactByExternalIdRequest } from "./ShowContactByExternalIdRequest"; +export { type ArchiveContactRequest } from "./ArchiveContactRequest"; +export { type UnarchiveContactRequest } from "./UnarchiveContactRequest"; +export { type BlockContactRequest } from "./BlockContactRequest"; diff --git a/src/api/resources/unstable/resources/contacts/index.ts b/src/api/resources/unstable/resources/contacts/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/contacts/types/Contact.ts b/src/api/resources/unstable/resources/contacts/types/Contact.ts new file mode 100644 index 00000000..156e327d --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/types/Contact.ts @@ -0,0 +1,106 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * Contacts represent your leads and users in Intercom. + */ +export interface Contact { + /** The type of object. */ + type?: string; + /** The unique identifier for the contact which is given by Intercom. */ + id?: string; + /** The unique identifier for the contact which is provided by the Client. */ + external_id?: string; + /** The id of the workspace which the contact belongs to. */ + workspace_id?: string; + /** The role of the contact. */ + role?: string; + /** The contact's email. */ + email?: string; + /** The contact's email domain. */ + email_domain?: string; + /** The contacts phone. */ + phone?: string; + /** The contacts phone number normalized to the E164 format */ + formatted_phone?: string; + /** The contacts name. */ + name?: string; + /** The id of an admin that has been assigned account ownership of the contact. */ + owner_id?: number; + /** Whether the contact has had an email sent to them hard bounce. */ + has_hard_bounced?: boolean; + /** Whether the contact has marked an email sent to them as spam. */ + marked_email_as_spam?: boolean; + /** Whether the contact is unsubscribed from emails. */ + unsubscribed_from_emails?: boolean; + /** (UNIX timestamp) The time when the contact was created. */ + created_at?: number; + /** (UNIX timestamp) The time when the contact was last updated. */ + updated_at?: number; + /** (UNIX timestamp) The time specified for when a contact signed up. */ + signed_up_at?: number; + /** (UNIX timestamp) The time when the contact was last seen (either where the Intercom Messenger was installed or when specified manually). */ + last_seen_at?: number; + /** (UNIX timestamp) The time when the contact last messaged in. */ + last_replied_at?: number; + /** (UNIX timestamp) The time when the contact was last messaged. */ + last_contacted_at?: number; + /** (UNIX timestamp) The time when the contact last opened an email. */ + last_email_opened_at?: number; + /** (UNIX timestamp) The time when the contact last clicked a link in an email. */ + last_email_clicked_at?: number; + /** A preferred language setting for the contact, used by the Intercom Messenger even if their browser settings change. */ + language_override?: string; + /** The name of the browser which the contact is using. */ + browser?: string; + /** The version of the browser which the contact is using. */ + browser_version?: string; + /** The language set by the browser which the contact is using. */ + browser_language?: string; + /** The operating system which the contact is using. */ + os?: string; + /** The name of the Android app which the contact is using. */ + android_app_name?: string; + /** The version of the Android app which the contact is using. */ + android_app_version?: string; + /** The Android device which the contact is using. */ + android_device?: string; + /** The version of the Android OS which the contact is using. */ + android_os_version?: string; + /** The version of the Android SDK which the contact is using. */ + android_sdk_version?: string; + /** (UNIX timestamp) The time when the contact was last seen on an Android device. */ + android_last_seen_at?: number; + /** The name of the iOS app which the contact is using. */ + ios_app_name?: string; + /** The version of the iOS app which the contact is using. */ + ios_app_version?: string; + /** The iOS device which the contact is using. */ + ios_device?: string; + /** The version of iOS which the contact is using. */ + ios_os_version?: string; + /** The version of the iOS SDK which the contact is using. */ + ios_sdk_version?: string; + /** (UNIX timestamp) The last time the contact used the iOS app. */ + ios_last_seen_at?: number; + /** The custom attributes which are set for the contact. */ + custom_attributes?: Record; + avatar?: Contact.Avatar; + tags?: Intercom.unstable.ContactTags; + notes?: Intercom.unstable.ContactNotes; + companies?: Intercom.unstable.ContactCompanies; + location?: Intercom.unstable.ContactLocation; + social_profiles?: Intercom.unstable.ContactSocialProfiles; +} + +export namespace Contact { + export interface Avatar { + /** The type of object */ + type?: string; + /** An image URL containing the avatar of a contact. */ + image_url?: string; + } +} diff --git a/src/api/resources/unstable/resources/contacts/types/CreateContactResponse.ts b/src/api/resources/unstable/resources/contacts/types/CreateContactResponse.ts new file mode 100644 index 00000000..1455fa8f --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/types/CreateContactResponse.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +export interface CreateContactResponse extends Intercom.unstable.Contact { + /** If the user has enabled push messaging. */ + enabled_push_messaging?: boolean; +} diff --git a/src/api/resources/unstable/resources/contacts/types/MergeContactResponse.ts b/src/api/resources/unstable/resources/contacts/types/MergeContactResponse.ts new file mode 100644 index 00000000..b67e7baa --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/types/MergeContactResponse.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +export interface MergeContactResponse extends Intercom.unstable.Contact { + /** If the user has enabled push messaging. */ + enabled_push_messaging?: boolean; +} diff --git a/src/api/resources/unstable/resources/contacts/types/ShowContactByExternalIdResponse.ts b/src/api/resources/unstable/resources/contacts/types/ShowContactByExternalIdResponse.ts new file mode 100644 index 00000000..d11d1d83 --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/types/ShowContactByExternalIdResponse.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +export interface ShowContactByExternalIdResponse extends Intercom.unstable.Contact { + /** If the user has enabled push messaging. */ + enabled_push_messaging?: boolean; +} diff --git a/src/api/resources/unstable/resources/contacts/types/ShowContactResponse.ts b/src/api/resources/unstable/resources/contacts/types/ShowContactResponse.ts new file mode 100644 index 00000000..58bc07cc --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/types/ShowContactResponse.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +export interface ShowContactResponse extends Intercom.unstable.Contact { + /** If the user has enabled push messaging. */ + enabled_push_messaging?: boolean; +} diff --git a/src/api/resources/unstable/resources/contacts/types/UpdateContactResponse.ts b/src/api/resources/unstable/resources/contacts/types/UpdateContactResponse.ts new file mode 100644 index 00000000..8919485b --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/types/UpdateContactResponse.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +export interface UpdateContactResponse extends Intercom.unstable.Contact { + /** If the user has enabled push messaging. */ + enabled_push_messaging?: boolean; +} diff --git a/src/api/resources/unstable/resources/contacts/types/index.ts b/src/api/resources/unstable/resources/contacts/types/index.ts new file mode 100644 index 00000000..12ec2438 --- /dev/null +++ b/src/api/resources/unstable/resources/contacts/types/index.ts @@ -0,0 +1,6 @@ +export * from "./ShowContactResponse"; +export * from "./UpdateContactResponse"; +export * from "./MergeContactResponse"; +export * from "./CreateContactResponse"; +export * from "./ShowContactByExternalIdResponse"; +export * from "./Contact"; diff --git a/src/api/resources/unstable/resources/conversations/client/Client.ts b/src/api/resources/unstable/resources/conversations/client/Client.ts new file mode 100644 index 00000000..87442ffe --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/client/Client.ts @@ -0,0 +1,1553 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Conversations { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Conversations + */ +export class Conversations { + constructor(protected readonly _options: Conversations.Options = {}) {} + + /** + * You can fetch a list of all conversations. + * + * You can optionally request the result page size and the cursor to start after to fetch the result. + * {% admonition type="warning" name="Pagination" %} + * You can use pagination to limit the number of results returned. The default is `20` results per page. + * See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. + * {% /admonition %} + * + * @param {Intercom.unstable.ListConversationsRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.ForbiddenError} + * + * @example + * await client.unstable.conversations.listConversations() + */ + public listConversations( + request: Intercom.unstable.ListConversationsRequest = {}, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listConversations(request, requestOptions)); + } + + private async __listConversations( + request: Intercom.unstable.ListConversationsRequest = {}, + requestOptions?: Conversations.RequestOptions, + ): Promise> { + const { per_page: perPage, starting_after: startingAfter } = request; + const _queryParams: Record = {}; + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + + if (startingAfter != null) { + _queryParams["starting_after"] = startingAfter; + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "conversations", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ConversationList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.unstable.ForbiddenError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /conversations."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can create a conversation that has been initiated by a contact (ie. user or lead). + * The conversation can be an in-app message only. + * + * {% admonition type="info" name="Sending for visitors" %} + * You can also send a message from a visitor by specifying their `user_id` or `id` value in the `from` field, along with a `type` field value of `contact`. + * This visitor will be automatically converted to a contact with a lead role once the conversation is created. + * {% /admonition %} + * + * This will return the Message model that has been created. + * + * @param {Intercom.unstable.CreateConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.ForbiddenError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.conversations.createConversation({ + * from: { + * type: "user", + * id: "6762f11b1bb69f9f2193bba3" + * }, + * body: "Hello there" + * }) + * + * @example + * await client.unstable.conversations.createConversation({ + * from: { + * type: "user", + * id: "123_doesnt_exist" + * }, + * body: "Hello there" + * }) + */ + public createConversation( + request: Intercom.unstable.CreateConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createConversation(request, requestOptions)); + } + + private async __createConversation( + request: Intercom.unstable.CreateConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "conversations", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Message, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.unstable.ForbiddenError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * + * You can fetch the details of a single conversation. + * + * This will return a single Conversation model with all its conversation parts. + * + * {% admonition type="warning" name="Hard limit of 500 parts" %} + * The maximum number of conversation parts that can be returned via the API is 500. If you have more than that we will return the 500 most recent conversation parts. + * {% /admonition %} + * + * For AI agent conversation metadata, please note that you need to have the agent enabled in your workspace, which is a [paid feature](https://www.intercom.com/help/en/articles/8205718-fin-resolutions#h_97f8c2e671). + * + * @param {Intercom.unstable.RetrieveConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.ForbiddenError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.conversations.retrieveConversation({ + * id: 1, + * display_as: "plaintext" + * }) + */ + public retrieveConversation( + request: Intercom.unstable.RetrieveConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveConversation(request, requestOptions)); + } + + private async __retrieveConversation( + request: Intercom.unstable.RetrieveConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { + const { id, display_as: displayAs } = request; + const _queryParams: Record = {}; + if (displayAs != null) { + _queryParams["display_as"] = displayAs; + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Conversation, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.unstable.ForbiddenError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /conversations/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * + * You can update an existing conversation. + * + * {% admonition type="info" name="Replying and other actions" %} + * If you want to reply to a coveration or take an action such as assign, unassign, open, close or snooze, take a look at the reply and manage endpoints. + * {% /admonition %} + * + * {% admonition type="info" %} + * This endpoint handles both **conversation updates** and **custom object associations**. + * + * See _`update a conversation with an association to a custom object instance`_ in the request/response examples to see the custom object association format. + * {% /admonition %} + * + * @param {Intercom.unstable.UpdateConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.ForbiddenError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.conversations.updateConversation({ + * id: 1, + * display_as: "plaintext", + * read: true, + * title: "new conversation title", + * custom_attributes: { + * "issue_type": "Billing", + * "priority": "High" + * } + * }) + * + * @example + * await client.unstable.conversations.updateConversation({ + * id: 1, + * display_as: "plaintext", + * custom_attributes: { + * "order": {} + * } + * }) + */ + public updateConversation( + request: Intercom.unstable.UpdateConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateConversation(request, requestOptions)); + } + + private async __updateConversation( + request: Intercom.unstable.UpdateConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { + const { id, display_as: displayAs, ..._body } = request; + const _queryParams: Record = {}; + if (displayAs != null) { + _queryParams["display_as"] = displayAs; + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(id)}`, + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Conversation, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.unstable.ForbiddenError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /conversations/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can delete a single conversation. + * + * @param {Intercom.unstable.DeleteConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.ForbiddenError} + * + * @example + * await client.unstable.conversations.deleteConversation({ + * id: 1 + * }) + */ + public deleteConversation( + request: Intercom.unstable.DeleteConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteConversation(request, requestOptions)); + } + + private async __deleteConversation( + request: Intercom.unstable.DeleteConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.ConversationDeleted, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.unstable.ForbiddenError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /conversations/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can search for multiple conversations by the value of their attributes in order to fetch exactly which ones you want. + * + * To search for conversations, you need to send a `POST` request to `https://api.intercom.io/conversations/search`. + * + * This will accept a query object in the body which will define your filters in order to search for conversations. + * {% admonition type="warning" name="Optimizing search queries" %} + * Search queries can be complex, so optimizing them can help the performance of your search. + * Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize + * pagination to limit the number of results returned. The default is `20` results per page and maximum is `150`. + * See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. + * {% /admonition %} + * + * ### Nesting & Limitations + * + * You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). + * There are some limitations to the amount of multiple's there can be: + * - There's a limit of max 2 nested filters + * - There's a limit of max 15 filters for each AND or OR group + * + * ### Accepted Fields + * + * Most keys listed in the conversation model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). + * The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. + * + * | Field | Type | + * | :---------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------- | + * | id | String | + * | created_at | Date (UNIX timestamp) | + * | updated_at | Date (UNIX timestamp) | + * | source.type | String
Accepted fields are `conversation`, `email`, `facebook`, `instagram`, `phone_call`, `phone_switch`, `push`, `sms`, `twitter` and `whatsapp`. | + * | source.id | String | + * | source.delivered_as | String | + * | source.subject | String | + * | source.body | String | + * | source.author.id | String | + * | source.author.type | String | + * | source.author.name | String | + * | source.author.email | String | + * | source.url | String | + * | contact_ids | String | + * | teammate_ids | String | + * | admin_assignee_id | String | + * | team_assignee_id | String | + * | channel_initiated | String | + * | open | Boolean | + * | read | Boolean | + * | state | String | + * | waiting_since | Date (UNIX timestamp) | + * | snoozed_until | Date (UNIX timestamp) | + * | tag_ids | String | + * | priority | String | + * | statistics.time_to_assignment | Integer | + * | statistics.time_to_admin_reply | Integer | + * | statistics.time_to_first_close | Integer | + * | statistics.time_to_last_close | Integer | + * | statistics.median_time_to_reply | Integer | + * | statistics.first_contact_reply_at | Date (UNIX timestamp) | + * | statistics.first_assignment_at | Date (UNIX timestamp) | + * | statistics.first_admin_reply_at | Date (UNIX timestamp) | + * | statistics.first_close_at | Date (UNIX timestamp) | + * | statistics.last_assignment_at | Date (UNIX timestamp) | + * | statistics.last_assignment_admin_reply_at | Date (UNIX timestamp) | + * | statistics.last_contact_reply_at | Date (UNIX timestamp) | + * | statistics.last_admin_reply_at | Date (UNIX timestamp) | + * | statistics.last_close_at | Date (UNIX timestamp) | + * | statistics.last_closed_by_id | String | + * | statistics.count_reopens | Integer | + * | statistics.count_assignments | Integer | + * | statistics.count_conversation_parts | Integer | + * | conversation_rating.requested_at | Date (UNIX timestamp) | + * | conversation_rating.replied_at | Date (UNIX timestamp) | + * | conversation_rating.score | Integer | + * | conversation_rating.remark | String | + * | conversation_rating.contact_id | String | + * | conversation_rating.admin_d | String | + * | ai_agent_participated | Boolean | + * | ai_agent.resolution_state | String | + * | ai_agent.last_answer_type | String | + * | ai_agent.rating | Integer | + * | ai_agent.rating_remark | String | + * | ai_agent.source_type | String | + * | ai_agent.source_title | String | + * + * ### Accepted Operators + * + * The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + * + * | Operator | Valid Types | Description | + * | :------- | :----------------------------- | :----------------------------------------------------------- | + * | = | All | Equals | + * | != | All | Doesn't Equal | + * | IN | All | In Shortcut for `OR` queries Values most be in Array | + * | NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | + * | > | Integer Date (UNIX Timestamp) | Greater (or equal) than | + * | < | Integer Date (UNIX Timestamp) | Lower (or equal) than | + * | ~ | String | Contains | + * | !~ | String | Doesn't Contain | + * | ^ | String | Starts With | + * | $ | String | Ends With | + * + * @param {Intercom.unstable.SearchRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.unstable.conversations.searchConversations({ + * query: { + * operator: "AND", + * value: [{ + * field: "created_at", + * operator: ">", + * value: "1306054154" + * }] + * }, + * pagination: { + * per_page: 5 + * } + * }) + */ + public searchConversations( + request: Intercom.unstable.SearchRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__searchConversations(request, requestOptions)); + } + + private async __searchConversations( + request: Intercom.unstable.SearchRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "conversations/search", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.ConversationList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations/search."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can reply to a conversation with a message from an admin or on behalf of a contact, or with a note for admins. + * + * @param {Intercom.unstable.ReplyConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.ForbiddenError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.conversations.replyConversation({ + * id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "6762f1571bb69f9f2193bbbb" + * } + * }) + * + * @example + * await client.unstable.conversations.replyConversation({ + * id: "123 or \"last\"", + * body: { + * message_type: "note", + * type: "admin", + * body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + * admin_id: "3156780" + * } + * }) + * + * @example + * await client.unstable.conversations.replyConversation({ + * id: "123 or \"last\"", + * body: { + * message_type: "quick_reply", + * type: "admin", + * admin_id: "3156780", + * reply_options: [{ + * text: "Yes", + * uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb" + * }, { + * text: "No", + * uuid: "f4a98af1-be56-4948-a57e-e1a83f8484c6" + * }] + * } + * }) + * + * @example + * await client.unstable.conversations.replyConversation({ + * id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "body", + * reply_options: [{ + * text: "Yes", + * uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb" + * }], + * intercom_user_id: "6762f1621bb69f9f2193bbbe" + * } + * }) + * + * @example + * await client.unstable.conversations.replyConversation({ + * id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "6762f1661bb69f9f2193bbbf" + * } + * }) + */ + public replyConversation( + request: Intercom.unstable.ReplyConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__replyConversation(request, requestOptions)); + } + + private async __replyConversation( + request: Intercom.unstable.ReplyConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { + const { id, body: _body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(id)}/reply`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Conversation, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.unstable.ForbiddenError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations/{id}/reply."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * For managing conversations you can: + * - Close a conversation + * - Snooze a conversation to reopen on a future date + * - Open a conversation which is `snoozed` or `closed` + * - Assign a conversation to an admin and/or team. + * + * @param {Intercom.unstable.ManageConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.ForbiddenError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.conversations.manageConversation({ + * id: "123", + * body: { + * message_type: "close", + * type: "admin", + * admin_id: "12345" + * } + * }) + * + * @example + * await client.unstable.conversations.manageConversation({ + * id: "123", + * body: { + * message_type: "snoozed", + * admin_id: "5017691", + * snoozed_until: 1673609604 + * } + * }) + * + * @example + * await client.unstable.conversations.manageConversation({ + * id: "123", + * body: { + * message_type: "open", + * admin_id: "5017690" + * } + * }) + * + * @example + * await client.unstable.conversations.manageConversation({ + * id: "123", + * body: { + * message_type: "assignment", + * type: "admin", + * admin_id: "12345", + * assignee_id: "4324241" + * } + * }) + */ + public manageConversation( + request: Intercom.unstable.ManageConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__manageConversation(request, requestOptions)); + } + + private async __manageConversation( + request: Intercom.unstable.ManageConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { + const { id, body: _body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(id)}/parts`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Conversation, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.unstable.ForbiddenError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations/{id}/parts."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. + * + * {% admonition type="warning" name="Contacts without an email" %} + * If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. + * {% /admonition %} + * + * @param {Intercom.unstable.AttachContactToConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.ForbiddenError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.conversations.attachContactToConversation({ + * id: "123", + * admin_id: "12345", + * customer: { + * intercom_user_id: "6762f19b1bb69f9f2193bbd4" + * } + * }) + * + * @example + * await client.unstable.conversations.attachContactToConversation({ + * id: "123", + * admin_id: "12345", + * customer: { + * intercom_user_id: "6762f19e1bb69f9f2193bbd5" + * } + * }) + */ + public attachContactToConversation( + request: Intercom.unstable.AttachContactToConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__attachContactToConversation(request, requestOptions)); + } + + private async __attachContactToConversation( + request: Intercom.unstable.AttachContactToConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { + const { id, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(id)}/customers`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Conversation, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.unstable.ForbiddenError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /conversations/{id}/customers.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. + * + * {% admonition type="warning" name="Contacts without an email" %} + * If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. + * {% /admonition %} + * + * @param {Intercom.unstable.DetachContactFromConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.ForbiddenError} + * @throws {@link Intercom.unstable.NotFoundError} + * @throws {@link Intercom.unstable.UnprocessableEntityError} + * + * @example + * await client.unstable.conversations.detachContactFromConversation({ + * conversation_id: "123", + * contact_id: "123", + * admin_id: "5017690" + * }) + */ + public detachContactFromConversation( + request: Intercom.unstable.DetachContactFromConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__detachContactFromConversation(request, requestOptions)); + } + + private async __detachContactFromConversation( + request: Intercom.unstable.DetachContactFromConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { + const { conversation_id: conversationId, contact_id: contactId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/customers/${encodeURIComponent(contactId)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Conversation, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.unstable.ForbiddenError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + case 422: + throw new Intercom.unstable.UnprocessableEntityError( + _response.error.body as unknown, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /conversations/{conversation_id}/customers/{contact_id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can redact a conversation part or the source message of a conversation (as seen in the source object). + * + * {% admonition type="info" name="Redacting parts and messages" %} + * If you are redacting a conversation part, it must have a `body`. If you are redacting a source message, it must have been created by a contact. We will return a `conversation_part_not_redactable` error if these criteria are not met. + * {% /admonition %} + * + * @param {Intercom.unstable.RedactConversationRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.conversations.redactConversation({ + * type: "conversation_part", + * conversation_id: "19894788788", + * conversation_part_id: "19381789428" + * }) + * + * @example + * await client.unstable.conversations.redactConversation({ + * type: "conversation_part", + * conversation_id: "really_123_doesnt_exist", + * conversation_part_id: "really_123_doesnt_exist" + * }) + */ + public redactConversation( + request: Intercom.unstable.RedactConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__redactConversation(request, requestOptions)); + } + + private async __redactConversation( + request: Intercom.unstable.RedactConversationRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "conversations/redact", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Conversation, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations/redact."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can convert a conversation to a ticket. + * + * @param {Intercom.unstable.ConvertConversationToTicketRequest} request + * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * + * @example + * await client.unstable.conversations.convertConversationToTicket({ + * id: 1, + * ticket_type_id: "53" + * }) + * + * @example + * await client.unstable.conversations.convertConversationToTicket({ + * id: 1, + * ticket_type_id: "54" + * }) + */ + public convertConversationToTicket( + request: Intercom.unstable.ConvertConversationToTicketRequest, + requestOptions?: Conversations.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__convertConversationToTicket(request, requestOptions)); + } + + private async __convertConversationToTicket( + request: Intercom.unstable.ConvertConversationToTicketRequest, + requestOptions?: Conversations.RequestOptions, + ): Promise> { + const { id, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(id)}/convert`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Ticket | undefined, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /conversations/{id}/convert.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/conversations/client/index.ts b/src/api/resources/unstable/resources/conversations/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/conversations/client/requests/AttachContactToConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/AttachContactToConversationRequest.ts new file mode 100644 index 00000000..d887df62 --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/client/requests/AttachContactToConversationRequest.ts @@ -0,0 +1,50 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * id: "123", + * admin_id: "12345", + * customer: { + * intercom_user_id: "6762f19b1bb69f9f2193bbd4" + * } + * } + * + * @example + * { + * id: "123", + * admin_id: "12345", + * customer: { + * intercom_user_id: "6762f19e1bb69f9f2193bbd5" + * } + * } + */ +export interface AttachContactToConversationRequest { + /** + * The identifier for the conversation as given by Intercom. + */ + id: string; + /** The `id` of the admin who is adding the new participant. */ + admin_id?: string; + customer?: AttachContactToConversationRequest.Customer; +} + +export namespace AttachContactToConversationRequest { + export type Customer = + | { + intercom_user_id: string; + customer?: Intercom.unstable.CustomerRequest | undefined; + } + | { + user_id: string; + customer?: Intercom.unstable.CustomerRequest | undefined; + } + | { + email: string; + customer?: Intercom.unstable.CustomerRequest | undefined; + }; +} diff --git a/src/api/resources/unstable/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts new file mode 100644 index 00000000..2e317651 --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts @@ -0,0 +1,28 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * id: 1, + * ticket_type_id: "53" + * } + * + * @example + * { + * id: 1, + * ticket_type_id: "54" + * } + */ +export interface ConvertConversationToTicketRequest { + /** + * The id of the conversation to target + */ + id: number; + /** The ID of the type of ticket you want to convert the conversation to */ + ticket_type_id: string; + attributes?: Intercom.unstable.TicketRequestCustomAttributes; +} diff --git a/src/api/resources/unstable/resources/conversations/client/requests/CreateConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/CreateConversationRequest.ts new file mode 100644 index 00000000..93ec0636 --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/client/requests/CreateConversationRequest.ts @@ -0,0 +1,51 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * from: { + * type: "user", + * id: "6762f11b1bb69f9f2193bba3" + * }, + * body: "Hello there" + * } + * + * @example + * { + * from: { + * type: "user", + * id: "123_doesnt_exist" + * }, + * body: "Hello there" + * } + */ +export interface CreateConversationRequest { + from: CreateConversationRequest.From; + /** The content of the message. HTML is not supported. */ + body: string; + /** The time the conversation was created as a UTC Unix timestamp. If not provided, the current time will be used. This field is only recommneded for migrating past conversations from another source into Intercom. */ + created_at?: number; +} + +export namespace CreateConversationRequest { + export interface From { + /** The role associated to the contact - user or lead. */ + type: From.Type; + /** The identifier for the contact which is given by Intercom. */ + id: string; + } + + export namespace From { + /** + * The role associated to the contact - user or lead. + */ + export type Type = "lead" | "user" | "contact"; + export const Type = { + Lead: "lead", + User: "user", + Contact: "contact", + } as const; + } +} diff --git a/src/api/resources/unstable/resources/conversations/client/requests/DeleteConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/DeleteConversationRequest.ts new file mode 100644 index 00000000..9ef40c85 --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/client/requests/DeleteConversationRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1 + * } + */ +export interface DeleteConversationRequest { + /** + * id + */ + id: number; +} diff --git a/src/api/resources/unstable/resources/conversations/client/requests/DetachContactFromConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/DetachContactFromConversationRequest.ts new file mode 100644 index 00000000..e245b23d --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/client/requests/DetachContactFromConversationRequest.ts @@ -0,0 +1,45 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * conversation_id: "123", + * contact_id: "123", + * admin_id: "5017690" + * } + * + * @example + * { + * conversation_id: "123", + * contact_id: "123", + * admin_id: "5017690" + * } + * + * @example + * { + * conversation_id: "123", + * contact_id: "123", + * admin_id: "5017690" + * } + * + * @example + * { + * conversation_id: "123", + * contact_id: "123", + * admin_id: "5017690" + * } + */ +export interface DetachContactFromConversationRequest { + /** + * The identifier for the conversation as given by Intercom. + */ + conversation_id: string; + /** + * The identifier for the contact as given by Intercom. + */ + contact_id: string; + /** The `id` of the admin who is performing the action. */ + admin_id: string; +} diff --git a/src/api/resources/unstable/resources/conversations/client/requests/ListConversationsRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/ListConversationsRequest.ts new file mode 100644 index 00000000..f3c7f741 --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/client/requests/ListConversationsRequest.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * {} + */ +export interface ListConversationsRequest { + /** + * How many results per page + */ + per_page?: number; + /** + * String used to get the next page of conversations. + */ + starting_after?: string; +} diff --git a/src/api/resources/unstable/resources/conversations/client/requests/ManageConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/ManageConversationRequest.ts new file mode 100644 index 00000000..59c70d65 --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/client/requests/ManageConversationRequest.ts @@ -0,0 +1,64 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * id: "123", + * body: { + * message_type: "close", + * type: "admin", + * admin_id: "12345" + * } + * } + * + * @example + * { + * id: "123", + * body: { + * message_type: "snoozed", + * admin_id: "5017691", + * snoozed_until: 1673609604 + * } + * } + * + * @example + * { + * id: "123", + * body: { + * message_type: "open", + * admin_id: "5017690" + * } + * } + * + * @example + * { + * id: "123", + * body: { + * message_type: "assignment", + * type: "admin", + * admin_id: "12345", + * assignee_id: "4324241" + * } + * } + * + * @example + * { + * id: "123", + * body: { + * message_type: "close", + * type: "admin", + * admin_id: "12345" + * } + * } + */ +export interface ManageConversationRequest { + /** + * The identifier for the conversation as given by Intercom. + */ + id: string; + body: Intercom.unstable.ManageConversationRequestBody; +} diff --git a/src/api/resources/unstable/resources/conversations/client/requests/ReplyConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/ReplyConversationRequest.ts new file mode 100644 index 00000000..fb35a919 --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/client/requests/ReplyConversationRequest.ts @@ -0,0 +1,79 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "6762f1571bb69f9f2193bbbb" + * } + * } + * + * @example + * { + * id: "123 or \"last\"", + * body: { + * message_type: "note", + * type: "admin", + * body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + * admin_id: "3156780" + * } + * } + * + * @example + * { + * id: "123 or \"last\"", + * body: { + * message_type: "quick_reply", + * type: "admin", + * admin_id: "3156780", + * reply_options: [{ + * text: "Yes", + * uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb" + * }, { + * text: "No", + * uuid: "f4a98af1-be56-4948-a57e-e1a83f8484c6" + * }] + * } + * } + * + * @example + * { + * id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "body", + * reply_options: [{ + * text: "Yes", + * uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb" + * }], + * intercom_user_id: "6762f1621bb69f9f2193bbbe" + * } + * } + * + * @example + * { + * id: "123 or \"last\"", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "6762f1661bb69f9f2193bbbf" + * } + * } + */ +export interface ReplyConversationRequest { + /** + * The Intercom provisioned identifier for the conversation or the string "last" to reply to the last part of the conversation + */ + id: string; + body: Intercom.unstable.ReplyConversationRequestBody; +} diff --git a/src/api/resources/unstable/resources/conversations/client/requests/RetrieveConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/RetrieveConversationRequest.ts new file mode 100644 index 00000000..8849068d --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/client/requests/RetrieveConversationRequest.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1, + * display_as: "plaintext" + * } + */ +export interface RetrieveConversationRequest { + /** + * The id of the conversation to target + */ + id: number; + /** + * Set to plaintext to retrieve conversation messages in plain text. + */ + display_as?: string; +} diff --git a/src/api/resources/unstable/resources/conversations/client/requests/UpdateConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/UpdateConversationRequest.ts new file mode 100644 index 00000000..76276853 --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/client/requests/UpdateConversationRequest.ts @@ -0,0 +1,55 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * id: 1, + * display_as: "plaintext", + * read: true, + * title: "new conversation title", + * custom_attributes: { + * "issue_type": "Billing", + * "priority": "High" + * } + * } + * + * @example + * { + * id: 1, + * display_as: "plaintext", + * custom_attributes: { + * "order": {} + * } + * } + * + * @example + * { + * id: 1, + * display_as: "plaintext", + * read: true, + * title: "new conversation title", + * custom_attributes: { + * "issue_type": "Billing", + * "priority": "High" + * } + * } + */ +export interface UpdateConversationRequest { + /** + * The id of the conversation to target + */ + id: number; + /** + * Set to plaintext to retrieve conversation messages in plain text. + */ + display_as?: string; + /** Mark a conversation as read within Intercom. */ + read?: boolean; + /** The title given to the conversation */ + title?: string; + custom_attributes?: Intercom.unstable.CustomAttributes; +} diff --git a/src/api/resources/unstable/resources/conversations/client/requests/index.ts b/src/api/resources/unstable/resources/conversations/client/requests/index.ts new file mode 100644 index 00000000..b297425a --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/client/requests/index.ts @@ -0,0 +1,10 @@ +export { type ListConversationsRequest } from "./ListConversationsRequest"; +export { type CreateConversationRequest } from "./CreateConversationRequest"; +export { type RetrieveConversationRequest } from "./RetrieveConversationRequest"; +export { type UpdateConversationRequest } from "./UpdateConversationRequest"; +export { type DeleteConversationRequest } from "./DeleteConversationRequest"; +export { type ReplyConversationRequest } from "./ReplyConversationRequest"; +export { type ManageConversationRequest } from "./ManageConversationRequest"; +export { type AttachContactToConversationRequest } from "./AttachContactToConversationRequest"; +export { type DetachContactFromConversationRequest } from "./DetachContactFromConversationRequest"; +export { type ConvertConversationToTicketRequest } from "./ConvertConversationToTicketRequest"; diff --git a/src/api/resources/unstable/resources/conversations/index.ts b/src/api/resources/unstable/resources/conversations/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/conversations/types/Conversation.ts b/src/api/resources/unstable/resources/conversations/types/Conversation.ts new file mode 100644 index 00000000..2531c62d --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/types/Conversation.ts @@ -0,0 +1,71 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * Conversations are how you can communicate with users in Intercom. They are created when a contact replies to an outbound message, or when one admin directly sends a message to a single contact. + */ +export interface Conversation { + /** Always conversation. */ + type?: string; + /** The id representing the conversation. */ + id?: string; + /** The title given to the conversation. */ + title?: string; + /** The time the conversation was created. */ + created_at?: number; + /** The last time the conversation was updated. */ + updated_at?: number; + /** The last time a Contact responded to an Admin. In other words, the time a customer started waiting for a response. Set to null if last reply is from an Admin. */ + waiting_since?: number; + /** If set this is the time in the future when this conversation will be marked as open. i.e. it will be in a snoozed state until this time. i.e. it will be in a snoozed state until this time. */ + snoozed_until?: number; + /** Indicates whether a conversation is open (true) or closed (false). */ + open?: boolean; + /** Can be set to "open", "closed" or "snoozed". */ + state?: Conversation.State; + /** Indicates whether a conversation has been read. */ + read?: boolean; + /** If marked as priority, it will return priority or else not_priority. */ + priority?: Conversation.Priority; + /** The id of the admin assigned to the conversation. If it's not assigned to an admin it will return null. */ + admin_assignee_id?: number; + /** The id of the team assigned to the conversation. If it's not assigned to a team it will return null. */ + team_assignee_id?: string; + tags?: Intercom.unstable.Tags; + conversation_rating?: Intercom.unstable.ConversationRating; + source?: Intercom.unstable.ConversationSource; + contacts?: Intercom.unstable.ConversationContacts; + teammates?: Intercom.unstable.ConversationTeammates; + custom_attributes?: Intercom.unstable.CustomAttributes; + first_contact_reply?: Intercom.unstable.ConversationFirstContactReply; + sla_applied?: Intercom.unstable.SlaApplied; + statistics?: Intercom.unstable.ConversationStatistics; + conversation_parts?: Intercom.unstable.ConversationParts; + linked_objects?: Intercom.unstable.LinkedObjectList; + /** Indicates whether the AI Agent participated in the conversation. */ + ai_agent_participated?: boolean; + ai_agent?: Intercom.unstable.AiAgent; +} + +export namespace Conversation { + /** + * Can be set to "open", "closed" or "snoozed". + */ + export type State = "open" | "closed" | "snoozed"; + export const State = { + Open: "open", + Closed: "closed", + Snoozed: "snoozed", + } as const; + /** + * If marked as priority, it will return priority or else not_priority. + */ + export type Priority = "priority" | "not_priority"; + export const Priority = { + Priority: "priority", + NotPriority: "not_priority", + } as const; +} diff --git a/src/api/resources/unstable/resources/conversations/types/ManageConversationRequestBody.ts b/src/api/resources/unstable/resources/conversations/types/ManageConversationRequestBody.ts new file mode 100644 index 00000000..cceeedbb --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/types/ManageConversationRequestBody.ts @@ -0,0 +1,29 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +export type ManageConversationRequestBody = + | Intercom.unstable.ManageConversationRequestBody.Close + | Intercom.unstable.ManageConversationRequestBody.Snoozed + | Intercom.unstable.ManageConversationRequestBody.Open + | Intercom.unstable.ManageConversationRequestBody.Assignment; + +export namespace ManageConversationRequestBody { + export interface Close extends Intercom.unstable.CloseConversationRequest { + message_type: "close"; + } + + export interface Snoozed extends Intercom.unstable.SnoozeConversationRequest { + message_type: "snoozed"; + } + + export interface Open extends Intercom.unstable.OpenConversationRequest { + message_type: "open"; + } + + export interface Assignment extends Intercom.unstable.AssignConversationRequest { + message_type: "assignment"; + } +} diff --git a/src/api/resources/unstable/resources/conversations/types/index.ts b/src/api/resources/unstable/resources/conversations/types/index.ts new file mode 100644 index 00000000..b2325882 --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/types/index.ts @@ -0,0 +1,2 @@ +export * from "./ManageConversationRequestBody"; +export * from "./Conversation"; diff --git a/src/api/resources/unstable/resources/customChannelEvents/client/Client.ts b/src/api/resources/unstable/resources/customChannelEvents/client/Client.ts new file mode 100644 index 00000000..fab44a35 --- /dev/null +++ b/src/api/resources/unstable/resources/customChannelEvents/client/Client.ts @@ -0,0 +1,540 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace CustomChannelEvents { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +export class CustomChannelEvents { + constructor(protected readonly _options: CustomChannelEvents.Options = {}) {} + + /** + * Notifies Intercom that a new conversation was created in your custom channel/platform. This triggers conversation creation and workflow automations within Intercom for your custom channel integration. + * > **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". + * + * @param {Intercom.unstable.CustomChannelBaseEvent} request + * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * @throws {@link Intercom.unstable.UnprocessableEntityError} + * + * @example + * await client.unstable.customChannelEvents.notifyNewConversation({ + * event_id: "evt_12345", + * external_conversation_id: "conv_67890", + * contact: { + * type: "user", + * external_id: "user_001", + * name: "Jane Doe", + * email: "jane.doe@example.com" + * } + * }) + */ + public notifyNewConversation( + request: Intercom.unstable.CustomChannelBaseEvent, + requestOptions?: CustomChannelEvents.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__notifyNewConversation(request, requestOptions)); + } + + private async __notifyNewConversation( + request: Intercom.unstable.CustomChannelBaseEvent, + requestOptions?: CustomChannelEvents.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "custom_channel_events/notify_new_conversation", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.CustomChannelNotificationResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + case 422: + throw new Intercom.unstable.UnprocessableEntityError( + _response.error.body as unknown, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /custom_channel_events/notify_new_conversation.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Notifies Intercom that a new message was sent in a conversation on your custom channel/platform. This allows Intercom to process the message and trigger any relevant workflow automations. + * > **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". + * + * @param {Intercom.unstable.NotifyNewMessageRequest} request + * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * @throws {@link Intercom.unstable.UnprocessableEntityError} + * + * @example + * await client.unstable.customChannelEvents.notifyNewMessage({ + * event_id: "evt_54321", + * external_conversation_id: "conv_98765", + * contact: { + * type: "user", + * external_id: "user_002", + * name: "John Smith", + * email: "john.smith@example.com" + * }, + * body: "Hello, I need help with my order." + * }) + */ + public notifyNewMessage( + request: Intercom.unstable.NotifyNewMessageRequest, + requestOptions?: CustomChannelEvents.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__notifyNewMessage(request, requestOptions)); + } + + private async __notifyNewMessage( + request: Intercom.unstable.NotifyNewMessageRequest, + requestOptions?: CustomChannelEvents.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "custom_channel_events/notify_new_message", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.CustomChannelNotificationResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + case 422: + throw new Intercom.unstable.UnprocessableEntityError( + _response.error.body as unknown, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /custom_channel_events/notify_new_message.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Notifies Intercom that a user selected a quick reply option in your custom channel/platform. This allows Intercom to process the response and trigger any relevant workflow automations. + * > **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". + * + * @param {Intercom.unstable.NotifyQuickReplySelectedRequest} request + * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * @throws {@link Intercom.unstable.UnprocessableEntityError} + * + * @example + * await client.unstable.customChannelEvents.notifyQuickReplySelected({ + * event_id: "evt_67890", + * external_conversation_id: "conv_13579", + * contact: { + * type: "user", + * external_id: "user_003", + * name: "Alice Example", + * email: "alice@example.com" + * }, + * quick_reply_option_id: "1234" + * }) + */ + public notifyQuickReplySelected( + request: Intercom.unstable.NotifyQuickReplySelectedRequest, + requestOptions?: CustomChannelEvents.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__notifyQuickReplySelected(request, requestOptions)); + } + + private async __notifyQuickReplySelected( + request: Intercom.unstable.NotifyQuickReplySelectedRequest, + requestOptions?: CustomChannelEvents.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "custom_channel_events/notify_quick_reply_selected", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.CustomChannelNotificationResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + case 422: + throw new Intercom.unstable.UnprocessableEntityError( + _response.error.body as unknown, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /custom_channel_events/notify_quick_reply_selected.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Notifies Intercom that a user provided a response to an attribute collector in your custom channel/platform. This allows Intercom to process the attribute and trigger any relevant workflow automations. + * > **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". + * + * @param {Intercom.unstable.NotifyAttributeCollectedRequest} request + * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * @throws {@link Intercom.unstable.UnprocessableEntityError} + * + * @example + * await client.unstable.customChannelEvents.notifyAttributeCollected({ + * event_id: "evt_24680", + * external_conversation_id: "conv_11223", + * contact: { + * type: "user", + * external_id: "user_004", + * name: "Bob Example", + * email: "bob@example.com" + * }, + * attribute: { + * id: "shipping_address", + * value: "123 Main St, Springfield" + * } + * }) + */ + public notifyAttributeCollected( + request: Intercom.unstable.NotifyAttributeCollectedRequest, + requestOptions?: CustomChannelEvents.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__notifyAttributeCollected(request, requestOptions)); + } + + private async __notifyAttributeCollected( + request: Intercom.unstable.NotifyAttributeCollectedRequest, + requestOptions?: CustomChannelEvents.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "custom_channel_events/notify_attribute_collected", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.CustomChannelNotificationResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + case 422: + throw new Intercom.unstable.UnprocessableEntityError( + _response.error.body as unknown, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /custom_channel_events/notify_attribute_collected.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/customChannelEvents/client/index.ts b/src/api/resources/unstable/resources/customChannelEvents/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/customChannelEvents/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyAttributeCollectedRequest.ts b/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyAttributeCollectedRequest.ts new file mode 100644 index 00000000..f3a2660d --- /dev/null +++ b/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyAttributeCollectedRequest.ts @@ -0,0 +1,26 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * event_id: "evt_24680", + * external_conversation_id: "conv_11223", + * contact: { + * type: "user", + * external_id: "user_004", + * name: "Bob Example", + * email: "bob@example.com" + * }, + * attribute: { + * id: "shipping_address", + * value: "123 Main St, Springfield" + * } + * } + */ +export interface NotifyAttributeCollectedRequest extends Intercom.unstable.CustomChannelBaseEvent { + attribute: Intercom.unstable.CustomChannelAttribute; +} diff --git a/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyNewMessageRequest.ts b/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyNewMessageRequest.ts new file mode 100644 index 00000000..1ed15c6e --- /dev/null +++ b/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyNewMessageRequest.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * event_id: "evt_54321", + * external_conversation_id: "conv_98765", + * contact: { + * type: "user", + * external_id: "user_002", + * name: "John Smith", + * email: "john.smith@example.com" + * }, + * body: "Hello, I need help with my order." + * } + */ +export interface NotifyNewMessageRequest extends Intercom.unstable.CustomChannelBaseEvent { + /** The message content sent by the user. */ + body: string; +} diff --git a/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyQuickReplySelectedRequest.ts b/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyQuickReplySelectedRequest.ts new file mode 100644 index 00000000..499b11d6 --- /dev/null +++ b/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyQuickReplySelectedRequest.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * event_id: "evt_67890", + * external_conversation_id: "conv_13579", + * contact: { + * type: "user", + * external_id: "user_003", + * name: "Alice Example", + * email: "alice@example.com" + * }, + * quick_reply_option_id: "1234" + * } + */ +export interface NotifyQuickReplySelectedRequest extends Intercom.unstable.CustomChannelBaseEvent { + /** Id of the selected quick reply option. */ + quick_reply_option_id: string; +} diff --git a/src/api/resources/unstable/resources/customChannelEvents/client/requests/index.ts b/src/api/resources/unstable/resources/customChannelEvents/client/requests/index.ts new file mode 100644 index 00000000..007800f3 --- /dev/null +++ b/src/api/resources/unstable/resources/customChannelEvents/client/requests/index.ts @@ -0,0 +1,3 @@ +export { type NotifyNewMessageRequest } from "./NotifyNewMessageRequest"; +export { type NotifyQuickReplySelectedRequest } from "./NotifyQuickReplySelectedRequest"; +export { type NotifyAttributeCollectedRequest } from "./NotifyAttributeCollectedRequest"; diff --git a/src/api/resources/unstable/resources/customChannelEvents/index.ts b/src/api/resources/unstable/resources/customChannelEvents/index.ts new file mode 100644 index 00000000..5ec76921 --- /dev/null +++ b/src/api/resources/unstable/resources/customChannelEvents/index.ts @@ -0,0 +1 @@ +export * from "./client"; diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/Client.ts b/src/api/resources/unstable/resources/customObjectInstances/client/Client.ts new file mode 100644 index 00000000..8d8d1ca5 --- /dev/null +++ b/src/api/resources/unstable/resources/customObjectInstances/client/Client.ts @@ -0,0 +1,589 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace CustomObjectInstances { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Custom Object instances. + * {% admonition type="warning" name="Permission Requirements" %} + * From now on, to access this endpoint, you need additional permissions. Please head over to the [Developer Hub](https://app.intercom.com/a/apps/_/developer-hub) app package authentication settings to configure the required permissions. + * {% /admonition %} + */ +export class CustomObjectInstances { + constructor(protected readonly _options: CustomObjectInstances.Options = {}) {} + + /** + * Fetch a Custom Object Instance by external_id. + * + * @param {Intercom.unstable.GetCustomObjectInstancesByExternalIdRequest} request + * @param {CustomObjectInstances.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.customObjectInstances.getCustomObjectInstancesByExternalId({ + * custom_object_type_identifier: "Order", + * external_id: "external_id" + * }) + */ + public getCustomObjectInstancesByExternalId( + request: Intercom.unstable.GetCustomObjectInstancesByExternalIdRequest, + requestOptions?: CustomObjectInstances.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise( + this.__getCustomObjectInstancesByExternalId(request, requestOptions), + ); + } + + private async __getCustomObjectInstancesByExternalId( + request: Intercom.unstable.GetCustomObjectInstancesByExternalIdRequest, + requestOptions?: CustomObjectInstances.RequestOptions, + ): Promise> { + const { custom_object_type_identifier: customObjectTypeIdentifier, external_id: externalId } = request; + const _queryParams: Record = {}; + _queryParams["external_id"] = externalId; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `custom_object_instances/${encodeURIComponent(customObjectTypeIdentifier)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.CustomObjectInstance | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /custom_object_instances/{custom_object_type_identifier}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Create or update a custom object instance + * + * @param {Intercom.unstable.CreateOrUpdateCustomObjectInstanceRequest} request + * @param {CustomObjectInstances.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.customObjectInstances.createCustomObjectInstances({ + * custom_object_type_identifier: "Order", + * external_id: "123", + * external_created_at: 1392036272, + * external_updated_at: 1392036272, + * custom_attributes: { + * "order_number": "ORDER-12345", + * "total_amount": "custom_attributes" + * } + * }) + */ + public createCustomObjectInstances( + request: Intercom.unstable.CreateOrUpdateCustomObjectInstanceRequest, + requestOptions?: CustomObjectInstances.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createCustomObjectInstances(request, requestOptions)); + } + + private async __createCustomObjectInstances( + request: Intercom.unstable.CreateOrUpdateCustomObjectInstanceRequest, + requestOptions?: CustomObjectInstances.RequestOptions, + ): Promise> { + const { custom_object_type_identifier: customObjectTypeIdentifier, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `custom_object_instances/${encodeURIComponent(customObjectTypeIdentifier)}`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.CustomObjectInstance | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /custom_object_instances/{custom_object_type_identifier}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Delete a single Custom Object instance by external_id. + * + * @param {Intercom.unstable.DeleteCustomObjectInstancesByIdRequest} request + * @param {CustomObjectInstances.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.customObjectInstances.deleteCustomObjectInstancesById({ + * custom_object_type_identifier: "Order", + * external_id: "external_id" + * }) + */ + public deleteCustomObjectInstancesById( + request: Intercom.unstable.DeleteCustomObjectInstancesByIdRequest, + requestOptions?: CustomObjectInstances.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteCustomObjectInstancesById(request, requestOptions)); + } + + private async __deleteCustomObjectInstancesById( + request: Intercom.unstable.DeleteCustomObjectInstancesByIdRequest, + requestOptions?: CustomObjectInstances.RequestOptions, + ): Promise> { + const { custom_object_type_identifier: customObjectTypeIdentifier, external_id: externalId } = request; + const _queryParams: Record = {}; + _queryParams["external_id"] = externalId; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `custom_object_instances/${encodeURIComponent(customObjectTypeIdentifier)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.CustomObjectInstanceDeleted, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /custom_object_instances/{custom_object_type_identifier}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Fetch a Custom Object Instance by id. + * + * @param {Intercom.unstable.GetCustomObjectInstancesByIdRequest} request + * @param {CustomObjectInstances.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.customObjectInstances.getCustomObjectInstancesById({ + * custom_object_type_identifier: "Order", + * id: "id" + * }) + */ + public getCustomObjectInstancesById( + request: Intercom.unstable.GetCustomObjectInstancesByIdRequest, + requestOptions?: CustomObjectInstances.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__getCustomObjectInstancesById(request, requestOptions)); + } + + private async __getCustomObjectInstancesById( + request: Intercom.unstable.GetCustomObjectInstancesByIdRequest, + requestOptions?: CustomObjectInstances.RequestOptions, + ): Promise> { + const { custom_object_type_identifier: customObjectTypeIdentifier, id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `custom_object_instances/${encodeURIComponent(customObjectTypeIdentifier)}/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.CustomObjectInstance | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /custom_object_instances/{custom_object_type_identifier}/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Delete a single Custom Object instance using the Intercom defined id. + * + * @param {Intercom.unstable.DeleteCustomObjectInstancesByExternalIdRequest} request + * @param {CustomObjectInstances.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.customObjectInstances.deleteCustomObjectInstancesByExternalId({ + * custom_object_type_identifier: "Order", + * id: "id" + * }) + */ + public deleteCustomObjectInstancesByExternalId( + request: Intercom.unstable.DeleteCustomObjectInstancesByExternalIdRequest, + requestOptions?: CustomObjectInstances.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise( + this.__deleteCustomObjectInstancesByExternalId(request, requestOptions), + ); + } + + private async __deleteCustomObjectInstancesByExternalId( + request: Intercom.unstable.DeleteCustomObjectInstancesByExternalIdRequest, + requestOptions?: CustomObjectInstances.RequestOptions, + ): Promise> { + const { custom_object_type_identifier: customObjectTypeIdentifier, id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `custom_object_instances/${encodeURIComponent(customObjectTypeIdentifier)}/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.CustomObjectInstanceDeleted, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /custom_object_instances/{custom_object_type_identifier}/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/index.ts b/src/api/resources/unstable/resources/customObjectInstances/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/customObjectInstances/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/requests/CreateOrUpdateCustomObjectInstanceRequest.ts b/src/api/resources/unstable/resources/customObjectInstances/client/requests/CreateOrUpdateCustomObjectInstanceRequest.ts new file mode 100644 index 00000000..6366c551 --- /dev/null +++ b/src/api/resources/unstable/resources/customObjectInstances/client/requests/CreateOrUpdateCustomObjectInstanceRequest.ts @@ -0,0 +1,31 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * custom_object_type_identifier: "Order", + * external_id: "123", + * external_created_at: 1392036272, + * external_updated_at: 1392036272, + * custom_attributes: { + * "order_number": "ORDER-12345", + * "total_amount": "custom_attributes" + * } + * } + */ +export interface CreateOrUpdateCustomObjectInstanceRequest { + /** + * The unique identifier of the custom object type that defines the structure of the custom object instance. + */ + custom_object_type_identifier: string; + /** A unique identifier for the Custom Object instance in the external system it originated from. */ + external_id?: string; + /** The time when the Custom Object instance was created in the external system it originated from. */ + external_created_at?: number; + /** The time when the Custom Object instance was last updated in the external system it originated from. */ + external_updated_at?: number; + /** The custom attributes which are set for the Custom Object instance. */ + custom_attributes?: Record; +} diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByExternalIdRequest.ts b/src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByExternalIdRequest.ts new file mode 100644 index 00000000..4674b582 --- /dev/null +++ b/src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByExternalIdRequest.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * custom_object_type_identifier: "Order", + * id: "id" + * } + */ +export interface DeleteCustomObjectInstancesByExternalIdRequest { + /** + * The unique identifier of the custom object type that defines the structure of the custom object instance. + */ + custom_object_type_identifier: string; + /** + * The Intercom defined id of the custom object instance + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByIdRequest.ts b/src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByIdRequest.ts new file mode 100644 index 00000000..b14cf673 --- /dev/null +++ b/src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByIdRequest.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * custom_object_type_identifier: "Order", + * external_id: "external_id" + * } + */ +export interface DeleteCustomObjectInstancesByIdRequest { + /** + * The unique identifier of the custom object type that defines the structure of the custom object instance. + */ + custom_object_type_identifier: string; + external_id: string; +} diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByExternalIdRequest.ts b/src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByExternalIdRequest.ts new file mode 100644 index 00000000..5ca2f7d0 --- /dev/null +++ b/src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByExternalIdRequest.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * custom_object_type_identifier: "Order", + * external_id: "external_id" + * } + */ +export interface GetCustomObjectInstancesByExternalIdRequest { + /** + * The unique identifier of the custom object type that defines the structure of the custom object instance. + */ + custom_object_type_identifier: string; + external_id: string; +} diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByIdRequest.ts b/src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByIdRequest.ts new file mode 100644 index 00000000..9350898c --- /dev/null +++ b/src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByIdRequest.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * custom_object_type_identifier: "Order", + * id: "id" + * } + */ +export interface GetCustomObjectInstancesByIdRequest { + /** + * The unique identifier of the custom object type that defines the structure of the custom object instance. + */ + custom_object_type_identifier: string; + /** + * The id or external_id of the custom object instance + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/requests/index.ts b/src/api/resources/unstable/resources/customObjectInstances/client/requests/index.ts new file mode 100644 index 00000000..5382e3d2 --- /dev/null +++ b/src/api/resources/unstable/resources/customObjectInstances/client/requests/index.ts @@ -0,0 +1,5 @@ +export { type GetCustomObjectInstancesByExternalIdRequest } from "./GetCustomObjectInstancesByExternalIdRequest"; +export { type CreateOrUpdateCustomObjectInstanceRequest } from "./CreateOrUpdateCustomObjectInstanceRequest"; +export { type DeleteCustomObjectInstancesByIdRequest } from "./DeleteCustomObjectInstancesByIdRequest"; +export { type GetCustomObjectInstancesByIdRequest } from "./GetCustomObjectInstancesByIdRequest"; +export { type DeleteCustomObjectInstancesByExternalIdRequest } from "./DeleteCustomObjectInstancesByExternalIdRequest"; diff --git a/src/api/resources/unstable/resources/customObjectInstances/index.ts b/src/api/resources/unstable/resources/customObjectInstances/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/customObjectInstances/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/customObjectInstances/types/CustomObjectInstance.ts b/src/api/resources/unstable/resources/customObjectInstances/types/CustomObjectInstance.ts new file mode 100644 index 00000000..aab4a843 --- /dev/null +++ b/src/api/resources/unstable/resources/customObjectInstances/types/CustomObjectInstance.ts @@ -0,0 +1,25 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A Custom Object Instance represents an instance of a custom object type. This allows you to create and set custom attributes to store data about your customers that is not already captured by Intercom. The parent object includes recommended default attributes and you can add your own custom attributes. + */ +export interface CustomObjectInstance { + /** The Intercom defined id representing the custom object instance. */ + id?: string; + /** The id you have defined for the custom object instance. */ + external_id?: string; + /** The time when the Custom Object instance was created in the external system it originated from. */ + external_created_at?: number; + /** The time when the Custom Object instance was last updated in the external system it originated from. */ + external_updated_at?: number; + /** The time the attribute was created as a UTC Unix timestamp */ + created_at?: number; + /** The time the attribute was last updated as a UTC Unix timestamp */ + updated_at?: number; + /** The identifier of the custom object type that defines the structure of the custom object instance. */ + type?: string; + /** The custom attributes you have set on the custom object instance. */ + custom_attributes?: Record; +} diff --git a/src/api/resources/unstable/resources/customObjectInstances/types/index.ts b/src/api/resources/unstable/resources/customObjectInstances/types/index.ts new file mode 100644 index 00000000..d5c782f8 --- /dev/null +++ b/src/api/resources/unstable/resources/customObjectInstances/types/index.ts @@ -0,0 +1 @@ +export * from "./CustomObjectInstance"; diff --git a/src/api/resources/unstable/resources/dataAttributes/client/Client.ts b/src/api/resources/unstable/resources/dataAttributes/client/Client.ts new file mode 100644 index 00000000..03670ff6 --- /dev/null +++ b/src/api/resources/unstable/resources/dataAttributes/client/Client.ts @@ -0,0 +1,436 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace DataAttributes { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Data Attributes + */ +export class DataAttributes { + constructor(protected readonly _options: DataAttributes.Options = {}) {} + + /** + * You can fetch a list of all data attributes belonging to a workspace for contacts, companies or conversations. + * + * @param {Intercom.unstable.LisDataAttributesRequest} request + * @param {DataAttributes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.dataAttributes.lisDataAttributes() + */ + public lisDataAttributes( + request: Intercom.unstable.LisDataAttributesRequest = {}, + requestOptions?: DataAttributes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__lisDataAttributes(request, requestOptions)); + } + + private async __lisDataAttributes( + request: Intercom.unstable.LisDataAttributesRequest = {}, + requestOptions?: DataAttributes.RequestOptions, + ): Promise> { + const { model, include_archived: includeArchived } = request; + const _queryParams: Record = {}; + if (model != null) { + _queryParams["model"] = model; + } + + if (includeArchived != null) { + _queryParams["include_archived"] = includeArchived.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "data_attributes", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.DataAttributeList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /data_attributes."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can create a data attributes for a `contact` or a `company`. + * + * @param {Intercom.unstable.CreateDataAttributeRequest} request + * @param {DataAttributes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.dataAttributes.createDataAttribute({ + * name: "Mithril Shirt", + * model: "company", + * data_type: "string" + * }) + * + * @example + * await client.unstable.dataAttributes.createDataAttribute({ + * name: "The One Ring", + * model: "contact", + * data_type: "integer" + * }) + * + * @example + * await client.unstable.dataAttributes.createDataAttribute({ + * name: "!nv@l!d n@me", + * model: "company", + * data_type: "string" + * }) + * + * @example + * await client.unstable.dataAttributes.createDataAttribute({ + * name: "The One Ring", + * model: "company", + * data_type: "string" + * }) + * + * @example + * await client.unstable.dataAttributes.createDataAttribute({ + * name: "The Second Ring", + * model: "company", + * data_type: "string" + * }) + * + * @example + * await client.unstable.dataAttributes.createDataAttribute({ + * name: "My Data Attribute", + * model: "contact", + * data_type: "string", + * description: "Just a plain old ring", + * options: ["options"] + * }) + */ + public createDataAttribute( + request: Intercom.unstable.CreateDataAttributeRequest, + requestOptions?: DataAttributes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createDataAttribute(request, requestOptions)); + } + + private async __createDataAttribute( + request: Intercom.unstable.CreateDataAttributeRequest, + requestOptions?: DataAttributes.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "data_attributes", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.DataAttribute, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /data_attributes."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * + * You can update a data attribute. + * + * > 🚧 Updating the data type is not possible + * > + * > It is currently a dangerous action to execute changing a data attribute's type via the API. You will need to update the type via the UI instead. + * + * @param {Intercom.unstable.UpdateDataAttributeRequest} request + * @param {DataAttributes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * @throws {@link Intercom.unstable.UnprocessableEntityError} + * + * @example + * await client.unstable.dataAttributes.updateDataAttribute({ + * id: 1, + * archived: false, + * description: "Just a plain old ring", + * options: ["options", "options"] + * }) + * + * @example + * await client.unstable.dataAttributes.updateDataAttribute({ + * id: 1, + * archived: false, + * description: "Too few options", + * options: ["option1", "option2"] + * }) + * + * @example + * await client.unstable.dataAttributes.updateDataAttribute({ + * id: 1, + * archived: true, + * description: "Trying to archieve" + * }) + */ + public updateDataAttribute( + request: Intercom.unstable.UpdateDataAttributeRequest, + requestOptions?: DataAttributes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateDataAttribute(request, requestOptions)); + } + + private async __updateDataAttribute( + request: Intercom.unstable.UpdateDataAttributeRequest, + requestOptions?: DataAttributes.RequestOptions, + ): Promise> { + const { id, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `data_attributes/${encodeURIComponent(id)}`, + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.DataAttribute, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + case 422: + throw new Intercom.unstable.UnprocessableEntityError( + _response.error.body as unknown, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /data_attributes/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/dataAttributes/client/index.ts b/src/api/resources/unstable/resources/dataAttributes/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/dataAttributes/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts b/src/api/resources/unstable/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts new file mode 100644 index 00000000..d0856471 --- /dev/null +++ b/src/api/resources/unstable/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts @@ -0,0 +1,86 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * name: "Mithril Shirt", + * model: "company", + * data_type: "string" + * } + * + * @example + * { + * name: "The One Ring", + * model: "contact", + * data_type: "integer" + * } + * + * @example + * { + * name: "!nv@l!d n@me", + * model: "company", + * data_type: "string" + * } + * + * @example + * { + * name: "The One Ring", + * model: "company", + * data_type: "string" + * } + * + * @example + * { + * name: "The Second Ring", + * model: "company", + * data_type: "string" + * } + * + * @example + * { + * name: "My Data Attribute", + * model: "contact", + * data_type: "string", + * description: "Just a plain old ring", + * options: ["options"] + * } + */ +export interface CreateDataAttributeRequest { + /** The name of the data attribute. */ + name: string; + /** The model that the data attribute belongs to. */ + model: CreateDataAttributeRequest.Model; + /** The type of data stored for this attribute. */ + data_type: CreateDataAttributeRequest.DataType; + /** The readable description you see in the UI for the attribute. */ + description?: string; + /** To create list attributes. Provide a set of hashes with `value` as the key of the options you want to make. `data_type` must be `string`. */ + options?: string[]; + /** Can this attribute be updated by the Messenger */ + messenger_writable?: boolean; +} + +export namespace CreateDataAttributeRequest { + /** + * The model that the data attribute belongs to. + */ + export type Model = "contact" | "company"; + export const Model = { + Contact: "contact", + Company: "company", + } as const; + /** + * The type of data stored for this attribute. + */ + export type DataType = "string" | "integer" | "float" | "boolean" | "datetime" | "date"; + export const DataType = { + String: "string", + Integer: "integer", + Float: "float", + Boolean: "boolean", + Datetime: "datetime", + Date: "date", + } as const; +} diff --git a/src/api/resources/unstable/resources/dataAttributes/client/requests/LisDataAttributesRequest.ts b/src/api/resources/unstable/resources/dataAttributes/client/requests/LisDataAttributesRequest.ts new file mode 100644 index 00000000..4764c380 --- /dev/null +++ b/src/api/resources/unstable/resources/dataAttributes/client/requests/LisDataAttributesRequest.ts @@ -0,0 +1,20 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * {} + */ +export interface LisDataAttributesRequest { + /** + * Specify the data attribute model to return. + */ + model?: Intercom.unstable.LisDataAttributesRequestModel; + /** + * Include archived attributes in the list. By default we return only non archived data attributes. + */ + include_archived?: boolean; +} diff --git a/src/api/resources/unstable/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts b/src/api/resources/unstable/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts new file mode 100644 index 00000000..80ea0b29 --- /dev/null +++ b/src/api/resources/unstable/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts @@ -0,0 +1,50 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1, + * archived: false, + * description: "Just a plain old ring", + * options: ["options", "options"] + * } + * + * @example + * { + * id: 1, + * archived: false, + * description: "Too few options", + * options: ["option1", "option2"] + * } + * + * @example + * { + * id: 1, + * archived: false, + * description: "Just a plain old ring", + * options: ["options", "options"] + * } + * + * @example + * { + * id: 1, + * archived: true, + * description: "Trying to archieve" + * } + */ +export interface UpdateDataAttributeRequest { + /** + * The data attribute id + */ + id: number; + /** Whether the attribute is to be archived or not. */ + archived?: boolean; + /** The readable description you see in the UI for the attribute. */ + description?: string; + /** To create list attributes. Provide a set of hashes with `value` as the key of the options you want to make. `data_type` must be `string`. */ + options?: string[]; + /** Can this attribute be updated by the Messenger */ + messenger_writable?: boolean; +} diff --git a/src/api/resources/unstable/resources/dataAttributes/client/requests/index.ts b/src/api/resources/unstable/resources/dataAttributes/client/requests/index.ts new file mode 100644 index 00000000..5b0976fe --- /dev/null +++ b/src/api/resources/unstable/resources/dataAttributes/client/requests/index.ts @@ -0,0 +1,3 @@ +export { type LisDataAttributesRequest } from "./LisDataAttributesRequest"; +export { type CreateDataAttributeRequest } from "./CreateDataAttributeRequest"; +export { type UpdateDataAttributeRequest } from "./UpdateDataAttributeRequest"; diff --git a/src/api/resources/unstable/resources/dataAttributes/index.ts b/src/api/resources/unstable/resources/dataAttributes/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/dataAttributes/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/dataAttributes/types/DataAttribute.ts b/src/api/resources/unstable/resources/dataAttributes/types/DataAttribute.ts new file mode 100644 index 00000000..cacf2b7b --- /dev/null +++ b/src/api/resources/unstable/resources/dataAttributes/types/DataAttribute.ts @@ -0,0 +1,65 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Data Attributes are metadata used to describe your contact, company and conversation models. These include standard and custom attributes. By using the data attributes endpoint, you can get the global list of attributes for your workspace, as well as create and archive custom attributes. + */ +export interface DataAttribute { + /** Value is `data_attribute`. */ + type?: "data_attribute"; + /** The unique identifier for the data attribute which is given by Intercom. Only available for custom attributes. */ + id?: number; + /** Value is `contact` for user/lead attributes and `company` for company attributes. */ + model?: DataAttribute.Model; + /** Name of the attribute. */ + name?: string; + /** Full name of the attribute. Should match the name unless it's a nested attribute. We can split full_name on `.` to access nested user object values. */ + full_name?: string; + /** Readable name of the attribute (i.e. name you see in the UI) */ + label?: string; + /** Readable description of the attribute. */ + description?: string; + /** The data type of the attribute. */ + data_type?: DataAttribute.DataType; + /** List of predefined options for attribute value. */ + options?: string[]; + /** Can this attribute be updated through API */ + api_writable?: boolean; + /** Can this attribute be updated by the Messenger */ + messenger_writable?: boolean; + /** Can this attribute be updated in the UI */ + ui_writable?: boolean; + /** Set to true if this is a CDA */ + custom?: boolean; + /** Is this attribute archived. (Only applicable to CDAs) */ + archived?: boolean; + /** The time the attribute was created as a UTC Unix timestamp */ + created_at?: number; + /** The time the attribute was last updated as a UTC Unix timestamp */ + updated_at?: number; + /** Teammate who created the attribute. Only applicable to CDAs */ + admin_id?: string; +} + +export namespace DataAttribute { + /** + * Value is `contact` for user/lead attributes and `company` for company attributes. + */ + export type Model = "contact" | "company"; + export const Model = { + Contact: "contact", + Company: "company", + } as const; + /** + * The data type of the attribute. + */ + export type DataType = "string" | "integer" | "float" | "boolean" | "date"; + export const DataType = { + String: "string", + Integer: "integer", + Float: "float", + Boolean: "boolean", + Date: "date", + } as const; +} diff --git a/src/api/resources/unstable/resources/dataAttributes/types/LisDataAttributesRequestModel.ts b/src/api/resources/unstable/resources/dataAttributes/types/LisDataAttributesRequestModel.ts new file mode 100644 index 00000000..9ee462c6 --- /dev/null +++ b/src/api/resources/unstable/resources/dataAttributes/types/LisDataAttributesRequestModel.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type LisDataAttributesRequestModel = "contact" | "company" | "conversation"; +export const LisDataAttributesRequestModel = { + Contact: "contact", + Company: "company", + Conversation: "conversation", +} as const; diff --git a/src/api/resources/unstable/resources/dataAttributes/types/index.ts b/src/api/resources/unstable/resources/dataAttributes/types/index.ts new file mode 100644 index 00000000..f452bb6b --- /dev/null +++ b/src/api/resources/unstable/resources/dataAttributes/types/index.ts @@ -0,0 +1,2 @@ +export * from "./LisDataAttributesRequestModel"; +export * from "./DataAttribute"; diff --git a/src/api/resources/unstable/resources/dataEvents/client/Client.ts b/src/api/resources/unstable/resources/dataEvents/client/Client.ts new file mode 100644 index 00000000..7349e445 --- /dev/null +++ b/src/api/resources/unstable/resources/dataEvents/client/Client.ts @@ -0,0 +1,413 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import { toJson } from "../../../../../../core/json"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace DataEvents { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Data Events + */ +export class DataEvents { + constructor(protected readonly _options: DataEvents.Options = {}) {} + + /** + * + * > 🚧 + * > + * > Please note that you can only 'list' events that are less than 90 days old. Event counts and summaries will still include your events older than 90 days but you cannot 'list' these events individually if they are older than 90 days + * + * The events belonging to a customer can be listed by sending a GET request to `https://api.intercom.io/events` with a user or lead identifier along with a `type` parameter. The identifier parameter can be one of `user_id`, `email` or `intercom_user_id`. The `type` parameter value must be `user`. + * + * - `https://api.intercom.io/events?type=user&user_id={user_id}` + * - `https://api.intercom.io/events?type=user&email={email}` + * - `https://api.intercom.io/events?type=user&intercom_user_id={id}` (this call can be used to list leads) + * + * The `email` parameter value should be [url encoded](http://en.wikipedia.org/wiki/Percent-encoding) when sending. + * + * You can optionally define the result page size as well with the `per_page` parameter. + * + * @param {Intercom.unstable.LisDataEventsRequest} request + * @param {DataEvents.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.dataEvents.lisDataEvents({ + * filter: { + * user_id: "user_id" + * }, + * type: "type" + * }) + */ + public lisDataEvents( + request: Intercom.unstable.LisDataEventsRequest, + requestOptions?: DataEvents.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__lisDataEvents(request, requestOptions)); + } + + private async __lisDataEvents( + request: Intercom.unstable.LisDataEventsRequest, + requestOptions?: DataEvents.RequestOptions, + ): Promise> { + const { filter, type: type_, summary } = request; + const _queryParams: Record = {}; + _queryParams["filter"] = typeof filter === "string" ? filter : toJson(filter); + _queryParams["type"] = type_; + if (summary != null) { + _queryParams["summary"] = summary.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "events", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.DataEventSummary, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /events."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * + * You will need an Access Token that has write permissions to send Events. Once you have a key you can submit events via POST to the Events resource, which is located at https://api.intercom.io/events, or you can send events using one of the client libraries. When working with the HTTP API directly a client should send the event with a `Content-Type` of `application/json`. + * + * When using the JavaScript API, [adding the code to your app](http://docs.intercom.io/configuring-Intercom/tracking-user-events-in-your-app) makes the Events API available. Once added, you can submit an event using the `trackEvent` method. This will associate the event with the Lead or currently logged-in user or logged-out visitor/lead and send it to Intercom. The final parameter is a map that can be used to send optional metadata about the event. + * + * With the Ruby client you pass a hash describing the event to `Intercom::Event.create`, or call the `track_user` method directly on the current user object (e.g. `user.track_event`). + * + * **NB: For the JSON object types, please note that we do not currently support nested JSON structure.** + * + * | Type | Description | Example | + * | :-------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------- | + * | String | The value is a JSON String | `"source":"desktop"` | + * | Number | The value is a JSON Number | `"load": 3.67` | + * | Date | The key ends with the String `_date` and the value is a [Unix timestamp](http://en.wikipedia.org/wiki/Unix_time), assumed to be in the [UTC](http://en.wikipedia.org/wiki/Coordinated_Universal_Time) timezone. | `"contact_date": 1392036272` | + * | Link | The value is a HTTP or HTTPS URI. | `"article": "https://example.org/ab1de.html"` | + * | Rich Link | The value is a JSON object that contains `url` and `value` keys. | `"article": {"url": "https://example.org/ab1de.html", "value":"the dude abides"}` | + * | Monetary Amount | The value is a JSON object that contains `amount` and `currency` keys. The `amount` key is a positive integer representing the amount in cents. The price in the example to the right denotes €349.99. | `"price": {"amount": 34999, "currency": "eur"}` | + * + * **Lead Events** + * + * When submitting events for Leads, you will need to specify the Lead's `id`. + * + * **Metadata behaviour** + * + * - We currently limit the number of tracked metadata keys to 10 per event. Once the quota is reached, we ignore any further keys we receive. The first 10 metadata keys are determined by the order in which they are sent in with the event. + * - It is not possible to change the metadata keys once the event has been sent. A new event will need to be created with the new keys and you can archive the old one. + * - There might be up to 24 hrs delay when you send a new metadata for an existing event. + * + * **Event de-duplication** + * + * The API may detect and ignore duplicate events. Each event is uniquely identified as a combination of the following data - the Workspace identifier, the Contact external identifier, the Data Event name and the Data Event created time. As a result, it is **strongly recommended** to send a second granularity Unix timestamp in the `created_at` field. + * + * Duplicated events are responded to using the normal `202 Accepted` code - an error is not thrown, however repeat requests will be counted against any rate limit that is in place. + * + * ### HTTP API Responses + * + * - Successful responses to submitted events return `202 Accepted` with an empty body. + * - Unauthorised access will be rejected with a `401 Unauthorized` or `403 Forbidden` response code. + * - Events sent about users that cannot be found will return a `404 Not Found`. + * - Event lists containing duplicate events will have those duplicates ignored. + * - Server errors will return a `500` response code and may contain an error message in the body. + * + * @param {Intercom.CreateDataEventRequestTwo} request + * @param {DataEvents.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.dataEvents.createDataEvent({ + * "key": "value" + * }) + */ + public createDataEvent( + request?: Intercom.CreateDataEventRequestTwo, + requestOptions?: DataEvents.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createDataEvent(request, requestOptions)); + } + + private async __createDataEvent( + request?: Intercom.CreateDataEventRequestTwo, + requestOptions?: DataEvents.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "events", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: undefined, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /events."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Create event summaries for a user. Event summaries are used to track the number of times an event has occurred, the first time it occurred and the last time it occurred. + * + * @param {Intercom.unstable.CreateDataEventSummariesRequest} request + * @param {DataEvents.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.dataEvents.dataEventSummaries() + */ + public dataEventSummaries( + request: Intercom.unstable.CreateDataEventSummariesRequest = {}, + requestOptions?: DataEvents.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__dataEventSummaries(request, requestOptions)); + } + + private async __dataEventSummaries( + request: Intercom.unstable.CreateDataEventSummariesRequest = {}, + requestOptions?: DataEvents.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "events/summaries", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: undefined, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /events/summaries."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/dataEvents/client/index.ts b/src/api/resources/unstable/resources/dataEvents/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/dataEvents/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/dataEvents/client/requests/CreateDataEventSummariesRequest.ts b/src/api/resources/unstable/resources/dataEvents/client/requests/CreateDataEventSummariesRequest.ts new file mode 100644 index 00000000..9e731802 --- /dev/null +++ b/src/api/resources/unstable/resources/dataEvents/client/requests/CreateDataEventSummariesRequest.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * {} + */ +export interface CreateDataEventSummariesRequest { + /** Your identifier for the user. */ + user_id?: string; + /** A list of event summaries for the user. Each event summary should contain the event name, the time the event occurred, and the number of times the event occurred. The event name should be a past tense 'verb-noun' combination, to improve readability, for example `updated-plan`. */ + event_summaries?: CreateDataEventSummariesRequest.EventSummaries; +} + +export namespace CreateDataEventSummariesRequest { + /** + * A list of event summaries for the user. Each event summary should contain the event name, the time the event occurred, and the number of times the event occurred. The event name should be a past tense 'verb-noun' combination, to improve readability, for example `updated-plan`. + */ + export interface EventSummaries { + /** The name of the event that occurred. A good event name is typically a past tense 'verb-noun' combination, to improve readability, for example `updated-plan`. */ + event_name?: string; + /** The number of times the event occurred. */ + count?: number; + /** The first time the event was sent */ + first?: number; + /** The last time the event was sent */ + last?: number; + } +} diff --git a/src/api/resources/unstable/resources/dataEvents/client/requests/LisDataEventsRequest.ts b/src/api/resources/unstable/resources/dataEvents/client/requests/LisDataEventsRequest.ts new file mode 100644 index 00000000..713df5e3 --- /dev/null +++ b/src/api/resources/unstable/resources/dataEvents/client/requests/LisDataEventsRequest.ts @@ -0,0 +1,26 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * filter: { + * user_id: "user_id" + * }, + * type: "type" + * } + */ +export interface LisDataEventsRequest { + filter: Intercom.unstable.LisDataEventsRequestFilter; + /** + * The value must be user + */ + type: string; + /** + * summary flag + */ + summary?: boolean; +} diff --git a/src/api/resources/unstable/resources/dataEvents/client/requests/index.ts b/src/api/resources/unstable/resources/dataEvents/client/requests/index.ts new file mode 100644 index 00000000..59b33a62 --- /dev/null +++ b/src/api/resources/unstable/resources/dataEvents/client/requests/index.ts @@ -0,0 +1,2 @@ +export { type LisDataEventsRequest } from "./LisDataEventsRequest"; +export { type CreateDataEventSummariesRequest } from "./CreateDataEventSummariesRequest"; diff --git a/src/api/resources/unstable/resources/dataEvents/index.ts b/src/api/resources/unstable/resources/dataEvents/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/dataEvents/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/dataEvents/types/DataEvent.ts b/src/api/resources/unstable/resources/dataEvents/types/DataEvent.ts new file mode 100644 index 00000000..124221eb --- /dev/null +++ b/src/api/resources/unstable/resources/dataEvents/types/DataEvent.ts @@ -0,0 +1,25 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Data events are used to notify Intercom of changes to your data. + */ +export interface DataEvent { + /** The type of the object */ + type?: "event"; + /** The name of the event that occurred. This is presented to your App's admins when filtering and creating segments - a good event name is typically a past tense 'verb-noun' combination, to improve readability, for example `updated-plan`. */ + event_name: string; + /** The time the event occurred as a UTC Unix timestamp */ + created_at: number; + /** Your identifier for the user. */ + user_id?: string; + /** Your identifier for a lead or a user. */ + id?: string; + /** The Intercom identifier for the user. */ + intercom_user_id?: string; + /** An email address for your user. An email should only be used where your application uses email to uniquely identify users. */ + email?: string; + /** Optional metadata about the event. */ + metadata?: Record; +} diff --git a/src/api/resources/unstable/resources/dataEvents/types/LisDataEventsRequestFilter.ts b/src/api/resources/unstable/resources/dataEvents/types/LisDataEventsRequestFilter.ts new file mode 100644 index 00000000..a12948ea --- /dev/null +++ b/src/api/resources/unstable/resources/dataEvents/types/LisDataEventsRequestFilter.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type LisDataEventsRequestFilter = + | { + user_id: string; + } + | { + intercom_user_id: string; + } + | { + email: string; + }; diff --git a/src/api/resources/unstable/resources/dataEvents/types/index.ts b/src/api/resources/unstable/resources/dataEvents/types/index.ts new file mode 100644 index 00000000..57668594 --- /dev/null +++ b/src/api/resources/unstable/resources/dataEvents/types/index.ts @@ -0,0 +1,2 @@ +export * from "./LisDataEventsRequestFilter"; +export * from "./DataEvent"; diff --git a/src/api/resources/customChannelEvents/client/Client.ts b/src/api/resources/unstable/resources/dataExport/client/Client.ts similarity index 54% rename from src/api/resources/customChannelEvents/client/Client.ts rename to src/api/resources/unstable/resources/dataExport/client/Client.ts index fa662231..6f6a2ebe 100644 --- a/src/api/resources/customChannelEvents/client/Client.ts +++ b/src/api/resources/unstable/resources/dataExport/client/Client.ts @@ -2,12 +2,13 @@ * This file was auto-generated by Fern from our API Definition. */ -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import * as errors from "../../../../../../errors/index"; -export declare namespace CustomChannelEvents { +export declare namespace DataExport { export interface Options { environment?: core.Supplier; /** Specify a custom URL to connect the client to. */ @@ -68,30 +69,63 @@ export declare namespace CustomChannelEvents { } } -export class CustomChannelEvents { - constructor(protected readonly _options: CustomChannelEvents.Options = {}) {} +/** + * Everything about your Data Exports + */ +export class DataExport { + constructor(protected readonly _options: DataExport.Options = {}) {} /** - * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * To create your export job, you need to send a `POST` request to the export endpoint `https://api.intercom.io/export/content/data`. + * + * The only parameters you need to provide are the range of dates that you want exported. + * + * >🚧 Limit of one active job + * > + * > You can only have one active job per workspace. You will receive a HTTP status code of 429 with the message Exceeded rate limit of 1 pending message data export jobs if you attempt to create a second concurrent job. + * + * >❗️ Updated_at not included + * > + * > It should be noted that the timeframe only includes messages sent during the time period and not messages that were only updated during this period. For example, if a message was updated yesterday but sent two days ago, you would need to set the created_at_after date before the message was sent to include that in your retrieval job. + * + * >📘 Date ranges are inclusive + * > + * > Requesting data for 2018-06-01 until 2018-06-30 will get all data for those days including those specified - e.g. 2018-06-01 00:00:00 until 2018-06-30 23:59:99. + * + * @param {Intercom.unstable.CreateDataExportsRequest} request + * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. * * @example - * await client.customChannelEvents.notifyAttributeCollected() + * await client.unstable.dataExport.createDataExport({ + * created_at_after: 1734519776, + * created_at_before: 1734537776 + * }) */ - public async notifyAttributeCollected(requestOptions?: CustomChannelEvents.RequestOptions): Promise { + public createDataExport( + request: Intercom.unstable.CreateDataExportsRequest, + requestOptions?: DataExport.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createDataExport(request, requestOptions)); + } + + private async __createDataExport( + request: Intercom.unstable.CreateDataExportsRequest, + requestOptions?: DataExport.RequestOptions, + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "custom_channel_events/notify_attribute_collected", + "export/content/data", ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -99,18 +133,20 @@ export class CustomChannelEvents { }, contentType: "application/json", requestType: "json", + body: request, timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, maxRetries: requestOptions?.maxRetries, abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return; + return { data: _response.body as Intercom.unstable.DataExport, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } @@ -119,39 +155,59 @@ export class CustomChannelEvents { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /custom_channel_events/notify_attribute_collected.", - ); + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /export/content/data."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } /** - * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * You can view the status of your job by sending a `GET` request to the URL + * `https://api.intercom.io/export/content/data/{job_identifier}` - the `{job_identifier}` is the value returned in the response when you first created the export job. More on it can be seen in the Export Job Model. + * + * > 🚧 Jobs expire after two days + * > All jobs that have completed processing (and are thus available to download from the provided URL) will have an expiry limit of two days from when the export ob completed. After this, the data will no longer be available. + * + * @param {Intercom.unstable.GetDataExportRequest} request + * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. * * @example - * await client.customChannelEvents.notifyNewMessage() + * await client.unstable.dataExport.getDataExport({ + * job_identifier: "job_identifier" + * }) */ - public async notifyNewMessage(requestOptions?: CustomChannelEvents.RequestOptions): Promise { + public getDataExport( + request: Intercom.unstable.GetDataExportRequest, + requestOptions?: DataExport.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__getDataExport(request, requestOptions)); + } + + private async __getDataExport( + request: Intercom.unstable.GetDataExportRequest, + requestOptions?: DataExport.RequestOptions, + ): Promise> { + const { job_identifier: jobIdentifier } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "custom_channel_events/notify_new_message", + `export/content/data/${encodeURIComponent(jobIdentifier)}`, ), - method: "POST", + method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -164,13 +220,14 @@ export class CustomChannelEvents { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return; + return { data: _response.body as Intercom.unstable.DataExport, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } @@ -179,39 +236,57 @@ export class CustomChannelEvents { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /custom_channel_events/notify_new_message.", + "Timeout exceeded when calling GET /export/content/data/{job_identifier}.", ); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } /** - * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * You can cancel your job + * + * @param {Intercom.unstable.CancelDataExportRequest} request + * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. * * @example - * await client.customChannelEvents.notifyNewConversation() + * await client.unstable.dataExport.cancelDataExport({ + * job_identifier: "job_identifier" + * }) */ - public async notifyNewConversation(requestOptions?: CustomChannelEvents.RequestOptions): Promise { + public cancelDataExport( + request: Intercom.unstable.CancelDataExportRequest, + requestOptions?: DataExport.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__cancelDataExport(request, requestOptions)); + } + + private async __cancelDataExport( + request: Intercom.unstable.CancelDataExportRequest, + requestOptions?: DataExport.RequestOptions, + ): Promise> { + const { job_identifier: jobIdentifier } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "custom_channel_events/notify_new_conversation", + `export/cancel/${encodeURIComponent(jobIdentifier)}`, ), method: "POST", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -224,13 +299,14 @@ export class CustomChannelEvents { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return; + return { data: _response.body as Intercom.unstable.DataExport, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } @@ -239,39 +315,63 @@ export class CustomChannelEvents { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /custom_channel_events/notify_new_conversation.", + "Timeout exceeded when calling POST /export/cancel/{job_identifier}.", ); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } /** - * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * When a job has a status of complete, and thus a filled download_url, you can download your data by hitting that provided URL, formatted like so: https://api.intercom.io/download/content/data/xyz1234. + * + * Your exported message data will be streamed continuously back down to you in a gzipped CSV format. + * + * > 📘 Octet header required + * > + * > You will have to specify the header Accept: `application/octet-stream` when hitting this endpoint. + * + * @param {Intercom.unstable.DownloadDataExportRequest} request + * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. * * @example - * await client.customChannelEvents.notifyQuickReplySelected() + * await client.unstable.dataExport.downloadDataExport({ + * job_identifier: "job_identifier" + * }) */ - public async notifyQuickReplySelected(requestOptions?: CustomChannelEvents.RequestOptions): Promise { + public downloadDataExport( + request: Intercom.unstable.DownloadDataExportRequest, + requestOptions?: DataExport.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__downloadDataExport(request, requestOptions)); + } + + private async __downloadDataExport( + request: Intercom.unstable.DownloadDataExportRequest, + requestOptions?: DataExport.RequestOptions, + ): Promise> { + const { job_identifier: jobIdentifier } = request; const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - "custom_channel_events/notify_quick_reply_selected", + `download/content/data/${encodeURIComponent(jobIdentifier)}`, ), - method: "POST", + method: "GET", headers: { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -284,13 +384,14 @@ export class CustomChannelEvents { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return; + return { data: undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } @@ -299,14 +400,16 @@ export class CustomChannelEvents { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /custom_channel_events/notify_quick_reply_selected.", + "Timeout exceeded when calling GET /download/content/data/{job_identifier}.", ); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/resources/unstable/resources/dataExport/client/index.ts b/src/api/resources/unstable/resources/dataExport/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/dataExport/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/dataExport/client/requests/CancelDataExportRequest.ts b/src/api/resources/unstable/resources/dataExport/client/requests/CancelDataExportRequest.ts new file mode 100644 index 00000000..39ed6925 --- /dev/null +++ b/src/api/resources/unstable/resources/dataExport/client/requests/CancelDataExportRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * job_identifier: "job_identifier" + * } + */ +export interface CancelDataExportRequest { + /** + * job_identifier + */ + job_identifier: string; +} diff --git a/src/api/resources/unstable/resources/dataExport/client/requests/CreateDataExportsRequest.ts b/src/api/resources/unstable/resources/dataExport/client/requests/CreateDataExportsRequest.ts new file mode 100644 index 00000000..78a96196 --- /dev/null +++ b/src/api/resources/unstable/resources/dataExport/client/requests/CreateDataExportsRequest.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * created_at_after: 1734519776, + * created_at_before: 1734537776 + * } + */ +export interface CreateDataExportsRequest { + /** The start date that you request data for. It must be formatted as a unix timestamp. */ + created_at_after: number; + /** The end date that you request data for. It must be formatted as a unix timestamp. */ + created_at_before: number; +} diff --git a/src/api/resources/unstable/resources/dataExport/client/requests/DownloadDataExportRequest.ts b/src/api/resources/unstable/resources/dataExport/client/requests/DownloadDataExportRequest.ts new file mode 100644 index 00000000..4a7ee828 --- /dev/null +++ b/src/api/resources/unstable/resources/dataExport/client/requests/DownloadDataExportRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * job_identifier: "job_identifier" + * } + */ +export interface DownloadDataExportRequest { + /** + * job_identifier + */ + job_identifier: string; +} diff --git a/src/api/resources/unstable/resources/dataExport/client/requests/GetDataExportRequest.ts b/src/api/resources/unstable/resources/dataExport/client/requests/GetDataExportRequest.ts new file mode 100644 index 00000000..b03dfb16 --- /dev/null +++ b/src/api/resources/unstable/resources/dataExport/client/requests/GetDataExportRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * job_identifier: "job_identifier" + * } + */ +export interface GetDataExportRequest { + /** + * job_identifier + */ + job_identifier: string; +} diff --git a/src/api/resources/unstable/resources/dataExport/client/requests/index.ts b/src/api/resources/unstable/resources/dataExport/client/requests/index.ts new file mode 100644 index 00000000..4f6d12f0 --- /dev/null +++ b/src/api/resources/unstable/resources/dataExport/client/requests/index.ts @@ -0,0 +1,4 @@ +export { type CreateDataExportsRequest } from "./CreateDataExportsRequest"; +export { type GetDataExportRequest } from "./GetDataExportRequest"; +export { type CancelDataExportRequest } from "./CancelDataExportRequest"; +export { type DownloadDataExportRequest } from "./DownloadDataExportRequest"; diff --git a/src/api/resources/unstable/resources/dataExport/index.ts b/src/api/resources/unstable/resources/dataExport/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/dataExport/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/dataExport/types/DataExport.ts b/src/api/resources/unstable/resources/dataExport/types/DataExport.ts new file mode 100644 index 00000000..bd19f8c9 --- /dev/null +++ b/src/api/resources/unstable/resources/dataExport/types/DataExport.ts @@ -0,0 +1,32 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The data export api is used to view all message sent & viewed in a given timeframe. + */ +export interface DataExport { + /** The identifier for your job. */ + job_identfier?: string; + /** The current state of your job. */ + status?: DataExport.Status; + /** The time after which you will not be able to access the data. */ + download_expires_at?: string; + /** The location where you can download your data. */ + download_url?: string; +} + +export namespace DataExport { + /** + * The current state of your job. + */ + export type Status = "pending" | "in_progress" | "failed" | "completed" | "no_data" | "canceled"; + export const Status = { + Pending: "pending", + InProgress: "in_progress", + Failed: "failed", + Completed: "completed", + NoData: "no_data", + Canceled: "canceled", + } as const; +} diff --git a/src/api/resources/unstable/resources/dataExport/types/index.ts b/src/api/resources/unstable/resources/dataExport/types/index.ts new file mode 100644 index 00000000..7cea751a --- /dev/null +++ b/src/api/resources/unstable/resources/dataExport/types/index.ts @@ -0,0 +1 @@ +export * from "./DataExport"; diff --git a/src/api/resources/unstable/resources/export/client/Client.ts b/src/api/resources/unstable/resources/export/client/Client.ts new file mode 100644 index 00000000..b067f559 --- /dev/null +++ b/src/api/resources/unstable/resources/export/client/Client.ts @@ -0,0 +1,262 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Export { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +export class Export { + constructor(protected readonly _options: Export.Options = {}) {} + + /** + * @param {Intercom.unstable.PostExportReportingDataEnqueueRequest} request + * @param {Export.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.TooManyRequestsError} + * + * @example + * await client.unstable.export.enqueueANewReportingDataExportJob({ + * dataset_id: "conversation", + * attribute_ids: ["conversation.id", "conversation.first_user_conversation_part_created_at"], + * start_time: 1717490000, + * end_time: 1717510000 + * }) + */ + public enqueueANewReportingDataExportJob( + request: Intercom.unstable.PostExportReportingDataEnqueueRequest, + requestOptions?: Export.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__enqueueANewReportingDataExportJob(request, requestOptions)); + } + + private async __enqueueANewReportingDataExportJob( + request: Intercom.unstable.PostExportReportingDataEnqueueRequest, + requestOptions?: Export.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "export/reporting_data/enqueue", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.PostExportReportingDataEnqueueResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 429: + throw new Intercom.unstable.TooManyRequestsError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /export/reporting_data/enqueue.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * @param {Export.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.unstable.export.listAvailableDatasetsAndAttributes() + */ + public listAvailableDatasetsAndAttributes( + requestOptions?: Export.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAvailableDatasetsAndAttributes(requestOptions)); + } + + private async __listAvailableDatasetsAndAttributes( + requestOptions?: Export.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "export/reporting_data/get_datasets", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.GetExportReportingDataGetDatasetsResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /export/reporting_data/get_datasets.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/export/client/index.ts b/src/api/resources/unstable/resources/export/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/export/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/export/client/requests/PostExportReportingDataEnqueueRequest.ts b/src/api/resources/unstable/resources/export/client/requests/PostExportReportingDataEnqueueRequest.ts new file mode 100644 index 00000000..55c7d4f8 --- /dev/null +++ b/src/api/resources/unstable/resources/export/client/requests/PostExportReportingDataEnqueueRequest.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * dataset_id: "conversation", + * attribute_ids: ["conversation.id", "conversation.first_user_conversation_part_created_at"], + * start_time: 1717490000, + * end_time: 1717510000 + * } + */ +export interface PostExportReportingDataEnqueueRequest { + dataset_id: string; + attribute_ids: string[]; + start_time: number; + end_time: number; +} diff --git a/src/api/resources/unstable/resources/export/client/requests/index.ts b/src/api/resources/unstable/resources/export/client/requests/index.ts new file mode 100644 index 00000000..bcda81be --- /dev/null +++ b/src/api/resources/unstable/resources/export/client/requests/index.ts @@ -0,0 +1 @@ +export { type PostExportReportingDataEnqueueRequest } from "./PostExportReportingDataEnqueueRequest"; diff --git a/src/api/resources/unstable/resources/export/index.ts b/src/api/resources/unstable/resources/export/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/export/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/export/types/GetExportReportingDataGetDatasetsResponse.ts b/src/api/resources/unstable/resources/export/types/GetExportReportingDataGetDatasetsResponse.ts new file mode 100644 index 00000000..ab8c3ba6 --- /dev/null +++ b/src/api/resources/unstable/resources/export/types/GetExportReportingDataGetDatasetsResponse.ts @@ -0,0 +1,33 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface GetExportReportingDataGetDatasetsResponse { + type?: string; + data?: GetExportReportingDataGetDatasetsResponse.Data.Item[]; +} + +export namespace GetExportReportingDataGetDatasetsResponse { + export type Data = Data.Item[]; + + export namespace Data { + export interface Item { + id?: string; + name?: string; + description?: string; + default_time_attribute_id?: string; + attributes?: Item.Attributes.Item[]; + } + + export namespace Item { + export type Attributes = Attributes.Item[]; + + export namespace Attributes { + export interface Item { + id?: string; + name?: string; + } + } + } + } +} diff --git a/src/api/resources/unstable/resources/export/types/PostExportReportingDataEnqueueResponse.ts b/src/api/resources/unstable/resources/export/types/PostExportReportingDataEnqueueResponse.ts new file mode 100644 index 00000000..55a28e65 --- /dev/null +++ b/src/api/resources/unstable/resources/export/types/PostExportReportingDataEnqueueResponse.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface PostExportReportingDataEnqueueResponse { + job_identifier?: string; + status?: string; + download_url?: string; + download_expires_at?: string; +} diff --git a/src/api/resources/unstable/resources/export/types/index.ts b/src/api/resources/unstable/resources/export/types/index.ts new file mode 100644 index 00000000..cc8706ee --- /dev/null +++ b/src/api/resources/unstable/resources/export/types/index.ts @@ -0,0 +1,2 @@ +export * from "./PostExportReportingDataEnqueueResponse"; +export * from "./GetExportReportingDataGetDatasetsResponse"; diff --git a/src/api/resources/unstable/resources/helpCenter/client/Client.ts b/src/api/resources/unstable/resources/helpCenter/client/Client.ts new file mode 100644 index 00000000..776053b4 --- /dev/null +++ b/src/api/resources/unstable/resources/helpCenter/client/Client.ts @@ -0,0 +1,722 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace HelpCenter { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Help Center + */ +export class HelpCenter { + constructor(protected readonly _options: HelpCenter.Options = {}) {} + + /** + * You can fetch a list of all collections by making a GET request to `https://api.intercom.io/help_center/collections`. + * + * Collections will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated collections first. + * + * @param {HelpCenter.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.helpCenter.listAllCollections() + */ + public listAllCollections( + requestOptions?: HelpCenter.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAllCollections(requestOptions)); + } + + private async __listAllCollections( + requestOptions?: HelpCenter.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "help_center/collections", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.CollectionList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /help_center/collections."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can create a new collection by making a POST request to `https://api.intercom.io/help_center/collections.` + * + * @param {Intercom.unstable.CreateCollectionRequest} request + * @param {HelpCenter.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.helpCenter.createCollection({ + * name: "Thanks for everything" + * }) + * + * @example + * await client.unstable.helpCenter.createCollection({ + * name: "collection 51", + * description: "Missing required parameter" + * }) + */ + public createCollection( + request: Intercom.unstable.CreateCollectionRequest, + requestOptions?: HelpCenter.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createCollection(request, requestOptions)); + } + + private async __createCollection( + request: Intercom.unstable.CreateCollectionRequest, + requestOptions?: HelpCenter.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "help_center/collections", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Collection, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /help_center/collections."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch the details of a single collection by making a GET request to `https://api.intercom.io/help_center/collections/`. + * + * @param {Intercom.unstable.RetrieveCollectionRequest} request + * @param {HelpCenter.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.helpCenter.retrieveCollection({ + * id: 1 + * }) + */ + public retrieveCollection( + request: Intercom.unstable.RetrieveCollectionRequest, + requestOptions?: HelpCenter.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveCollection(request, requestOptions)); + } + + private async __retrieveCollection( + request: Intercom.unstable.RetrieveCollectionRequest, + requestOptions?: HelpCenter.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `help_center/collections/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Collection, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /help_center/collections/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can update the details of a single collection by making a PUT request to `https://api.intercom.io/collections/`. + * + * @param {Intercom.unstable.UpdateCollectionRequest} request + * @param {HelpCenter.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.helpCenter.updateCollection({ + * id: 1, + * name: "Update collection name" + * }) + */ + public updateCollection( + request: Intercom.unstable.UpdateCollectionRequest, + requestOptions?: HelpCenter.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateCollection(request, requestOptions)); + } + + private async __updateCollection( + request: Intercom.unstable.UpdateCollectionRequest, + requestOptions?: HelpCenter.RequestOptions, + ): Promise> { + const { id, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `help_center/collections/${encodeURIComponent(id)}`, + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Collection, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling PUT /help_center/collections/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can delete a single collection by making a DELETE request to `https://api.intercom.io/collections/`. + * + * @param {Intercom.unstable.DeleteCollectionRequest} request + * @param {HelpCenter.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.helpCenter.deleteCollection({ + * id: 1 + * }) + */ + public deleteCollection( + request: Intercom.unstable.DeleteCollectionRequest, + requestOptions?: HelpCenter.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteCollection(request, requestOptions)); + } + + private async __deleteCollection( + request: Intercom.unstable.DeleteCollectionRequest, + requestOptions?: HelpCenter.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `help_center/collections/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.DeletedCollectionObject, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /help_center/collections/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch the details of a single Help Center by making a GET request to `https://api.intercom.io/help_center/help_center/`. + * + * @param {Intercom.unstable.RetrieveHelpCenterRequest} request + * @param {HelpCenter.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.helpCenter.retrieveHelpCenter({ + * id: 1 + * }) + */ + public retrieveHelpCenter( + request: Intercom.unstable.RetrieveHelpCenterRequest, + requestOptions?: HelpCenter.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveHelpCenter(request, requestOptions)); + } + + private async __retrieveHelpCenter( + request: Intercom.unstable.RetrieveHelpCenterRequest, + requestOptions?: HelpCenter.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `help_center/help_centers/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.HelpCenter, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling GET /help_center/help_centers/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can list all Help Centers by making a GET request to `https://api.intercom.io/help_center/help_centers`. + * + * @param {HelpCenter.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.helpCenter.listHelpCenters() + */ + public listHelpCenters( + requestOptions?: HelpCenter.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listHelpCenters(requestOptions)); + } + + private async __listHelpCenters( + requestOptions?: HelpCenter.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "help_center/help_centers", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.HelpCenterList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /help_center/help_centers."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/helpCenter/client/index.ts b/src/api/resources/unstable/resources/helpCenter/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/helpCenter/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/helpCenter/client/requests/CreateCollectionRequest.ts b/src/api/resources/unstable/resources/helpCenter/client/requests/CreateCollectionRequest.ts new file mode 100644 index 00000000..7b50caa9 --- /dev/null +++ b/src/api/resources/unstable/resources/helpCenter/client/requests/CreateCollectionRequest.ts @@ -0,0 +1,29 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * name: "Thanks for everything" + * } + * + * @example + * { + * name: "collection 51", + * description: "Missing required parameter" + * } + */ +export interface CreateCollectionRequest { + /** The name of the collection. For multilingual collections, this will be the name of the default language's content. */ + name: string; + /** The description of the collection. For multilingual collections, this will be the description of the default language's content. */ + description?: string; + translated_content?: Intercom.unstable.GroupTranslatedContent; + /** The id of the parent collection. If `null` then it will be created as the first level collection. */ + parent_id?: string; + /** The id of the help center where the collection will be created. If `null` then it will be created in the default help center. */ + help_center_id?: number; +} diff --git a/src/api/resources/unstable/resources/helpCenter/client/requests/DeleteCollectionRequest.ts b/src/api/resources/unstable/resources/helpCenter/client/requests/DeleteCollectionRequest.ts new file mode 100644 index 00000000..eaf33993 --- /dev/null +++ b/src/api/resources/unstable/resources/helpCenter/client/requests/DeleteCollectionRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1 + * } + */ +export interface DeleteCollectionRequest { + /** + * The unique identifier for the collection which is given by Intercom. + */ + id: number; +} diff --git a/src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveCollectionRequest.ts b/src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveCollectionRequest.ts new file mode 100644 index 00000000..4737b56b --- /dev/null +++ b/src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveCollectionRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1 + * } + */ +export interface RetrieveCollectionRequest { + /** + * The unique identifier for the collection which is given by Intercom. + */ + id: number; +} diff --git a/src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveHelpCenterRequest.ts b/src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveHelpCenterRequest.ts new file mode 100644 index 00000000..42057096 --- /dev/null +++ b/src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveHelpCenterRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1 + * } + */ +export interface RetrieveHelpCenterRequest { + /** + * The unique identifier for the collection which is given by Intercom. + */ + id: number; +} diff --git a/src/api/resources/unstable/resources/helpCenter/client/requests/UpdateCollectionRequest.ts b/src/api/resources/unstable/resources/helpCenter/client/requests/UpdateCollectionRequest.ts new file mode 100644 index 00000000..58505b62 --- /dev/null +++ b/src/api/resources/unstable/resources/helpCenter/client/requests/UpdateCollectionRequest.ts @@ -0,0 +1,32 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * id: 1, + * name: "Update collection name" + * } + * + * @example + * { + * id: 1, + * name: "Update collection name" + * } + */ +export interface UpdateCollectionRequest { + /** + * The unique identifier for the collection which is given by Intercom. + */ + id: number; + /** The name of the collection. For multilingual collections, this will be the name of the default language's content. */ + name?: string; + /** The description of the collection. For multilingual collections, this will be the description of the default language's content. */ + description?: string; + translated_content?: Intercom.unstable.GroupTranslatedContent; + /** The id of the parent collection. If `null` then it will be updated as the first level collection. */ + parent_id?: string; +} diff --git a/src/api/resources/unstable/resources/helpCenter/client/requests/index.ts b/src/api/resources/unstable/resources/helpCenter/client/requests/index.ts new file mode 100644 index 00000000..b39271fa --- /dev/null +++ b/src/api/resources/unstable/resources/helpCenter/client/requests/index.ts @@ -0,0 +1,5 @@ +export { type CreateCollectionRequest } from "./CreateCollectionRequest"; +export { type RetrieveCollectionRequest } from "./RetrieveCollectionRequest"; +export { type UpdateCollectionRequest } from "./UpdateCollectionRequest"; +export { type DeleteCollectionRequest } from "./DeleteCollectionRequest"; +export { type RetrieveHelpCenterRequest } from "./RetrieveHelpCenterRequest"; diff --git a/src/api/resources/unstable/resources/helpCenter/index.ts b/src/api/resources/unstable/resources/helpCenter/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/helpCenter/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/helpCenter/types/Collection.ts b/src/api/resources/unstable/resources/helpCenter/types/Collection.ts new file mode 100644 index 00000000..ef0fa2ec --- /dev/null +++ b/src/api/resources/unstable/resources/helpCenter/types/Collection.ts @@ -0,0 +1,36 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * Collections are top level containers for Articles within the Help Center. + */ +export interface Collection { + /** The unique identifier for the collection which is given by Intercom. */ + id?: string; + /** The id of the workspace which the collection belongs to. */ + workspace_id?: string; + /** The name of the collection. For multilingual collections, this will be the name of the default language's content. */ + name?: string; + /** The description of the collection. For multilingual help centers, this will be the description of the collection for the default language. */ + description?: string; + /** The time when the article was created (seconds). For multilingual articles, this will be the timestamp of creation of the default language's content. */ + created_at?: number; + /** The time when the article was last updated (seconds). For multilingual articles, this will be the timestamp of last update of the default language's content. */ + updated_at?: number; + /** The URL of the collection. For multilingual help centers, this will be the URL of the collection for the default language. */ + url?: string; + /** The icon of the collection. */ + icon?: string; + /** The order of the section in relation to others sections within a collection. Values go from `0` upwards. `0` is the default if there's no order. */ + order?: number; + /** The default locale of the help center. This field is only returned for multilingual help centers. */ + default_locale?: string; + translated_content?: Intercom.unstable.GroupTranslatedContent; + /** The id of the parent collection. If `null` then it is the first level collection. */ + parent_id?: string; + /** The id of the help center the collection is in. */ + help_center_id?: number; +} diff --git a/src/api/resources/unstable/resources/helpCenter/types/HelpCenter.ts b/src/api/resources/unstable/resources/helpCenter/types/HelpCenter.ts new file mode 100644 index 00000000..30cba20e --- /dev/null +++ b/src/api/resources/unstable/resources/helpCenter/types/HelpCenter.ts @@ -0,0 +1,23 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Help Centers contain collections + */ +export interface HelpCenter { + /** The unique identifier for the Help Center which is given by Intercom. */ + id?: string; + /** The id of the workspace which the Help Center belongs to. */ + workspace_id?: string; + /** The time when the Help Center was created. */ + created_at?: number; + /** The time when the Help Center was last updated. */ + updated_at?: number; + /** The identifier of the Help Center. This is used in the URL of the Help Center. */ + identifier?: string; + /** Whether the Help Center is turned on or not. This is controlled in your Help Center settings. */ + website_turned_on?: boolean; + /** The display name of the Help Center only seen by teammates. */ + display_name?: string; +} diff --git a/src/api/resources/unstable/resources/helpCenter/types/HelpCenterList.ts b/src/api/resources/unstable/resources/helpCenter/types/HelpCenterList.ts new file mode 100644 index 00000000..ee6c2a05 --- /dev/null +++ b/src/api/resources/unstable/resources/helpCenter/types/HelpCenterList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * A list of Help Centers belonging to the App + */ +export interface HelpCenterList { + /** The type of the object - `list`. */ + type?: "list"; + /** An array of Help Center objects */ + data?: Intercom.unstable.HelpCenter[]; +} diff --git a/src/api/resources/unstable/resources/helpCenter/types/index.ts b/src/api/resources/unstable/resources/helpCenter/types/index.ts new file mode 100644 index 00000000..65d348a7 --- /dev/null +++ b/src/api/resources/unstable/resources/helpCenter/types/index.ts @@ -0,0 +1,3 @@ +export * from "./Collection"; +export * from "./HelpCenter"; +export * from "./HelpCenterList"; diff --git a/src/api/resources/unstable/resources/index.ts b/src/api/resources/unstable/resources/index.ts new file mode 100644 index 00000000..a7c8f375 --- /dev/null +++ b/src/api/resources/unstable/resources/index.ts @@ -0,0 +1,78 @@ +export * as admins from "./admins"; +export * from "./admins/types"; +export * as aiContent from "./aiContent"; +export * from "./aiContent/types"; +export * as articles from "./articles"; +export * from "./articles/types"; +export * as export_ from "./export"; +export * from "./export/types"; +export * as helpCenter from "./helpCenter"; +export * from "./helpCenter/types"; +export * as companies from "./companies"; +export * from "./companies/types"; +export * as contacts from "./contacts"; +export * from "./contacts/types"; +export * as notes from "./notes"; +export * from "./notes/types"; +export * as subscriptionTypes from "./subscriptionTypes"; +export * from "./subscriptionTypes/types"; +export * as tags from "./tags"; +export * from "./tags/types"; +export * as conversations from "./conversations"; +export * from "./conversations/types"; +export * as customObjectInstances from "./customObjectInstances"; +export * from "./customObjectInstances/types"; +export * as dataAttributes from "./dataAttributes"; +export * from "./dataAttributes/types"; +export * as dataEvents from "./dataEvents"; +export * from "./dataEvents/types"; +export * as dataExport from "./dataExport"; +export * from "./dataExport/types"; +export * as jobs from "./jobs"; +export * from "./jobs/types"; +export * as messages from "./messages"; +export * from "./messages/types"; +export * as news from "./news"; +export * from "./news/types"; +export * as segments from "./segments"; +export * from "./segments/types"; +export * as teams from "./teams"; +export * from "./teams/types"; +export * as tickets from "./tickets"; +export * from "./tickets/types"; +export * as aiAgent from "./aiAgent"; +export * from "./aiAgent/types"; +export * as aiContentSource from "./aiContentSource"; +export * from "./aiContentSource/types"; +export * as awayStatusReasons from "./awayStatusReasons"; +export * as customChannelEvents from "./customChannelEvents"; +export * as switch_ from "./switch"; +export * as ticketStates from "./ticketStates"; +export * as ticketTypeAttributes from "./ticketTypeAttributes"; +export * as ticketTypes from "./ticketTypes"; +export * as visitors from "./visitors"; +export * from "./admins/client/requests"; +export * from "./aiContent/client/requests"; +export * from "./articles/client/requests"; +export * from "./export/client/requests"; +export * from "./helpCenter/client/requests"; +export * from "./companies/client/requests"; +export * from "./contacts/client/requests"; +export * from "./notes/client/requests"; +export * from "./subscriptionTypes/client/requests"; +export * from "./tags/client/requests"; +export * from "./conversations/client/requests"; +export * from "./customChannelEvents/client/requests"; +export * from "./customObjectInstances/client/requests"; +export * from "./dataAttributes/client/requests"; +export * from "./dataEvents/client/requests"; +export * from "./dataExport/client/requests"; +export * from "./jobs/client/requests"; +export * from "./messages/client/requests"; +export * from "./news/client/requests"; +export * from "./segments/client/requests"; +export * from "./teams/client/requests"; +export * from "./ticketTypeAttributes/client/requests"; +export * from "./ticketTypes/client/requests"; +export * from "./tickets/client/requests"; +export * from "./visitors/client/requests"; diff --git a/src/api/resources/unstable/resources/jobs/client/Client.ts b/src/api/resources/unstable/resources/jobs/client/Client.ts new file mode 100644 index 00000000..3c114bdf --- /dev/null +++ b/src/api/resources/unstable/resources/jobs/client/Client.ts @@ -0,0 +1,179 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Jobs { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about jobs + */ +export class Jobs { + constructor(protected readonly _options: Jobs.Options = {}) {} + + /** + * Retrieve the status of job execution. + * + * @param {Intercom.unstable.JobsStatusRequest} request + * @param {Jobs.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.jobs.status({ + * id: "id" + * }) + */ + public status( + request: Intercom.unstable.JobsStatusRequest, + requestOptions?: Jobs.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__status(request, requestOptions)); + } + + private async __status( + request: Intercom.unstable.JobsStatusRequest, + requestOptions?: Jobs.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `jobs/status/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Jobs, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /jobs/status/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/jobs/client/index.ts b/src/api/resources/unstable/resources/jobs/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/jobs/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/jobs/client/requests/JobsStatusRequest.ts b/src/api/resources/unstable/resources/jobs/client/requests/JobsStatusRequest.ts new file mode 100644 index 00000000..861e1c7d --- /dev/null +++ b/src/api/resources/unstable/resources/jobs/client/requests/JobsStatusRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "id" + * } + */ +export interface JobsStatusRequest { + /** + * The unique identifier for the job which is given by Intercom + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/jobs/client/requests/index.ts b/src/api/resources/unstable/resources/jobs/client/requests/index.ts new file mode 100644 index 00000000..0d9f97d0 --- /dev/null +++ b/src/api/resources/unstable/resources/jobs/client/requests/index.ts @@ -0,0 +1 @@ +export { type JobsStatusRequest } from "./JobsStatusRequest"; diff --git a/src/api/resources/unstable/resources/jobs/index.ts b/src/api/resources/unstable/resources/jobs/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/jobs/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/jobs/types/Jobs.ts b/src/api/resources/unstable/resources/jobs/types/Jobs.ts new file mode 100644 index 00000000..e2192f11 --- /dev/null +++ b/src/api/resources/unstable/resources/jobs/types/Jobs.ts @@ -0,0 +1,35 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Jobs are tasks that are processed asynchronously by the Intercom system after being enqueued via the API. This allows for efficient handling of operations that may take time to complete, such as data imports or exports. You can check the status of your jobs to monitor their progress and ensure they are completed successfully. + */ +export interface Jobs { + /** The type of the object */ + type?: "job"; + /** The id of the job that's currently being processed or has completed. */ + id: string; + /** API endpoint URL to check the job status. */ + url?: string; + /** The status of the job execution. */ + status?: Jobs.Status; + /** The type of resource created during job execution. */ + resource_type?: string; + /** The id of the resource created during job execution (e.g. ticket id) */ + resource_id?: string; + /** The url of the resource created during job exeuction. Use this url to fetch the resource. */ + resource_url?: string; +} + +export namespace Jobs { + /** + * The status of the job execution. + */ + export type Status = "pending" | "success" | "failed"; + export const Status = { + Pending: "pending", + Success: "success", + Failed: "failed", + } as const; +} diff --git a/src/api/resources/unstable/resources/jobs/types/index.ts b/src/api/resources/unstable/resources/jobs/types/index.ts new file mode 100644 index 00000000..c46ba3db --- /dev/null +++ b/src/api/resources/unstable/resources/jobs/types/index.ts @@ -0,0 +1 @@ +export * from "./Jobs"; diff --git a/src/api/resources/unstable/resources/messages/client/Client.ts b/src/api/resources/unstable/resources/messages/client/Client.ts new file mode 100644 index 00000000..e49625bc --- /dev/null +++ b/src/api/resources/unstable/resources/messages/client/Client.ts @@ -0,0 +1,446 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Messages { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your messages + */ +export class Messages { + constructor(protected readonly _options: Messages.Options = {}) {} + + /** + * You can create a message that has been initiated by an admin. The conversation can be either an in-app message, an email or sms. + * + * > 🚧 Sending for visitors + * > + * > There can be a short delay between when a contact is created and when a contact becomes available to be messaged through the API. A 404 Not Found error will be returned in this case. + * + * This will return the Message model that has been created. + * + * > 🚧 Retrieving Associated Conversations + * > + * > As this is a message, there will be no conversation present until the contact responds. Once they do, you will have to search for a contact's conversations with the id of the message. + * + * @param {Intercom.CreateMessageRequestTwo} request + * @param {Messages.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.ForbiddenError} + * @throws {@link Intercom.unstable.UnprocessableEntityError} + * + * @example + * await client.unstable.messages.createMessage({ + * "from": { + * "type": "user", + * "id": "6762f2341bb69f9f2193bc17" + * }, + * "body": "heyy", + * "referer": "https://twitter.com/bob" + * }) + * + * @example + * await client.unstable.messages.createMessage({ + * "from": { + * "type": "lead", + * "id": "6762f2371bb69f9f2193bc18" + * }, + * "body": "heyy", + * "referer": "https://twitter.com/bob" + * }) + * + * @example + * await client.unstable.messages.createMessage({ + * "from": { + * "type": "admin", + * "id": "991267816" + * }, + * "to": [ + * { + * "type": "user", + * "id": "6762f2391bb69f9f2193bc19" + * }, + * { + * "type": "lead", + * "id": "6762f23c1bb69f9f2193bc1b" + * }, + * { + * "type": "user", + * "id": "6762f23d1bb69f9f2193bc1c" + * } + * ], + * "cc": [ + * { + * "type": "user", + * "id": "6762f23e1bb69f9f2193bc1d" + * }, + * { + * "type": "user", + * "id": "6762f23f1bb69f9f2193bc1e" + * } + * ], + * "bcc": [ + * { + * "type": "user", + * "id": "6762f23e1bb69f9f2193bc2f" + * } + * ], + * "message_type": "conversation", + * "body": "heyy" + * }) + * + * @example + * await client.unstable.messages.createMessage({ + * "from": { + * "type": "admin", + * "id": "991267817" + * }, + * "to": { + * "type": "user", + * "id": "6762f23a1bb69f9f2193bc1a" + * }, + * "message_type": "sms", + * "body": "heyy" + * }) + * + * @example + * await client.unstable.messages.createMessage({ + * "from": { + * "type": "admin", + * "id": "991267818" + * }, + * "to": { + * "type": "user", + * "id": "6762f23b1bb69f9f2193bc1a" + * }, + * "message_type": "inapp", + * "subject": "heyy" + * }) + * + * @example + * await client.unstable.messages.createMessage({ + * "from": { + * "type": "admin", + * "id": "991267819" + * }, + * "to": { + * "type": "user", + * "user_id": "70" + * }, + * "message_type": "email", + * "body": "hey there" + * }) + * + * @example + * await client.unstable.messages.createMessage({ + * "from": { + * "type": "admin", + * "id": "991267820" + * }, + * "to": { + * "type": "user", + * "id": "6762f23d1bb69f9f2193bc1c" + * }, + * "message_type": "email", + * "subject": "heyy" + * }) + * + * @example + * await client.unstable.messages.createMessage({ + * "from": { + * "type": "admin", + * "id": "991267821" + * }, + * "to": { + * "type": "user", + * "id": "6762f23b1bb69f9f2193bc1d" + * }, + * "message_type": "sms", + * "body": "heyy https://picsum.photos/200/300" + * }) + */ + public createMessage( + request?: Intercom.CreateMessageRequestTwo, + requestOptions?: Messages.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createMessage(request, requestOptions)); + } + + private async __createMessage( + request?: Intercom.CreateMessageRequestTwo, + requestOptions?: Messages.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "messages", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Message, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.unstable.ForbiddenError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 422: + throw new Intercom.unstable.UnprocessableEntityError( + _response.error.body as unknown, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /messages."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Retrieves statuses of messages sent from the Outbound module. Currently, this API only supports WhatsApp messages. + * + * + * This endpoint returns paginated status events for WhatsApp messages sent via the Outbound module, providing + * information about delivery state and related message details. + * + * @param {Intercom.unstable.GetWhatsAppMessageStatusRequest} request + * @param {Messages.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.ForbiddenError} + * @throws {@link Intercom.unstable.InternalServerError} + * + * @example + * await client.unstable.messages.getWhatsAppMessageStatus({ + * ruleset_id: "ruleset_id" + * }) + */ + public getWhatsAppMessageStatus( + request: Intercom.unstable.GetWhatsAppMessageStatusRequest, + requestOptions?: Messages.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__getWhatsAppMessageStatus(request, requestOptions)); + } + + private async __getWhatsAppMessageStatus( + request: Intercom.unstable.GetWhatsAppMessageStatusRequest, + requestOptions?: Messages.RequestOptions, + ): Promise> { + const { ruleset_id: rulesetId, per_page: perPage, starting_after: startingAfter } = request; + const _queryParams: Record = {}; + _queryParams["ruleset_id"] = rulesetId; + if (perPage != null) { + _queryParams["per_page"] = perPage.toString(); + } + + if (startingAfter != null) { + _queryParams["starting_after"] = startingAfter; + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "messages/status", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.WhatsappMessageStatusList, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.unstable.ForbiddenError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 500: + throw new Intercom.unstable.InternalServerError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /messages/status."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/messages/client/index.ts b/src/api/resources/unstable/resources/messages/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/messages/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/messages/client/requests/GetWhatsAppMessageStatusRequest.ts b/src/api/resources/unstable/resources/messages/client/requests/GetWhatsAppMessageStatusRequest.ts new file mode 100644 index 00000000..9f14d703 --- /dev/null +++ b/src/api/resources/unstable/resources/messages/client/requests/GetWhatsAppMessageStatusRequest.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * ruleset_id: "ruleset_id" + * } + */ +export interface GetWhatsAppMessageStatusRequest { + /** + * The unique identifier for the set of messages to check status for + */ + ruleset_id: string; + /** + * Number of results per page (default 50, max 100) + */ + per_page?: number; + /** + * Cursor for pagination, used to fetch the next page of results + */ + starting_after?: string; +} diff --git a/src/api/resources/unstable/resources/messages/client/requests/index.ts b/src/api/resources/unstable/resources/messages/client/requests/index.ts new file mode 100644 index 00000000..73c16159 --- /dev/null +++ b/src/api/resources/unstable/resources/messages/client/requests/index.ts @@ -0,0 +1 @@ +export { type GetWhatsAppMessageStatusRequest } from "./GetWhatsAppMessageStatusRequest"; diff --git a/src/api/resources/unstable/resources/messages/index.ts b/src/api/resources/unstable/resources/messages/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/messages/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/messages/types/Message.ts b/src/api/resources/unstable/resources/messages/types/Message.ts new file mode 100644 index 00000000..35585c59 --- /dev/null +++ b/src/api/resources/unstable/resources/messages/types/Message.ts @@ -0,0 +1,37 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Message are how you reach out to contacts in Intercom. They are created when an admin sends an outbound message to a contact. + */ +export interface Message { + /** The type of the message */ + type: string; + /** The id representing the message. */ + id: string; + /** The time the conversation was created. */ + created_at: number; + /** The subject of the message. Only present if message_type: email. */ + subject?: string; + /** The message body, which may contain HTML. */ + body: string; + /** The type of message that was sent. Can be email, inapp, facebook ,twitter or sms. */ + message_type: Message.MessageType; + /** The associated conversation_id */ + conversation_id?: string; +} + +export namespace Message { + /** + * The type of message that was sent. Can be email, inapp, facebook ,twitter or sms. + */ + export type MessageType = "email" | "inapp" | "facebook" | "twitter" | "sms"; + export const MessageType = { + Email: "email", + Inapp: "inapp", + Facebook: "facebook", + Twitter: "twitter", + Sms: "sms", + } as const; +} diff --git a/src/api/resources/unstable/resources/messages/types/index.ts b/src/api/resources/unstable/resources/messages/types/index.ts new file mode 100644 index 00000000..6596816a --- /dev/null +++ b/src/api/resources/unstable/resources/messages/types/index.ts @@ -0,0 +1 @@ +export * from "./Message"; diff --git a/src/api/resources/unstable/resources/news/client/Client.ts b/src/api/resources/unstable/resources/news/client/Client.ts new file mode 100644 index 00000000..f42e1729 --- /dev/null +++ b/src/api/resources/unstable/resources/news/client/Client.ts @@ -0,0 +1,808 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace News { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your News + */ +export class News { + constructor(protected readonly _options: News.Options = {}) {} + + /** + * You can fetch a list of all news items + * + * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.news.listNewsItems() + */ + public listNewsItems( + requestOptions?: News.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listNewsItems(requestOptions)); + } + + private async __listNewsItems( + requestOptions?: News.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "news/news_items", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.PaginatedResponse, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/news_items."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can create a news item + * + * @param {Intercom.unstable.NewsItemRequest} request + * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.news.createNewsItem({ + * title: "Halloween is here!", + * body: "

New costumes in store for this spooky season

", + * sender_id: 991267834, + * state: "live", + * deliver_silently: true, + * labels: ["Product", "Update", "New"], + * reactions: ["\uD83D\uDE06", "\uD83D\uDE05"], + * newsfeed_assignments: [{ + * newsfeed_id: 53, + * published_at: 1664638214 + * }] + * }) + */ + public createNewsItem( + request: Intercom.unstable.NewsItemRequest, + requestOptions?: News.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createNewsItem(request, requestOptions)); + } + + private async __createNewsItem( + request: Intercom.unstable.NewsItemRequest, + requestOptions?: News.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "news/news_items", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.NewsItem, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /news/news_items."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch the details of a single news item. + * + * @param {Intercom.unstable.RetrieveNewsItemRequest} request + * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.news.retrieveNewsItem({ + * id: 1 + * }) + */ + public retrieveNewsItem( + request: Intercom.unstable.RetrieveNewsItemRequest, + requestOptions?: News.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveNewsItem(request, requestOptions)); + } + + private async __retrieveNewsItem( + request: Intercom.unstable.RetrieveNewsItemRequest, + requestOptions?: News.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `news/news_items/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.NewsItem, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/news_items/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * @param {Intercom.unstable.UpdateNewsItemRequest} request + * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.news.updateNewsItem({ + * id: 1, + * body: { + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

", + * sender_id: 991267845, + * reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"] + * } + * }) + * + * @example + * await client.unstable.news.updateNewsItem({ + * id: 1, + * body: { + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

", + * sender_id: 991267848, + * reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"] + * } + * }) + */ + public updateNewsItem( + request: Intercom.unstable.UpdateNewsItemRequest, + requestOptions?: News.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateNewsItem(request, requestOptions)); + } + + private async __updateNewsItem( + request: Intercom.unstable.UpdateNewsItemRequest, + requestOptions?: News.RequestOptions, + ): Promise> { + const { id, body: _body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `news/news_items/${encodeURIComponent(id)}`, + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.NewsItem, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /news/news_items/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can delete a single news item. + * + * @param {Intercom.unstable.DeleteNewsItemRequest} request + * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.news.deleteNewsItem({ + * id: 1 + * }) + */ + public deleteNewsItem( + request: Intercom.unstable.DeleteNewsItemRequest, + requestOptions?: News.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteNewsItem(request, requestOptions)); + } + + private async __deleteNewsItem( + request: Intercom.unstable.DeleteNewsItemRequest, + requestOptions?: News.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `news/news_items/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.DeletedObject, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /news/news_items/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch a list of all news items that are live on a given newsfeed + * + * @param {Intercom.unstable.ListLiveNewsfeedItemsRequest} request + * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.news.listLiveNewsfeedItems({ + * id: "123" + * }) + */ + public listLiveNewsfeedItems( + request: Intercom.unstable.ListLiveNewsfeedItemsRequest, + requestOptions?: News.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listLiveNewsfeedItems(request, requestOptions)); + } + + private async __listLiveNewsfeedItems( + request: Intercom.unstable.ListLiveNewsfeedItemsRequest, + requestOptions?: News.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `news/newsfeeds/${encodeURIComponent(id)}/items`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.PaginatedResponse, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/newsfeeds/{id}/items."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch a list of all newsfeeds + * + * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.news.listNewsfeeds() + */ + public listNewsfeeds( + requestOptions?: News.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listNewsfeeds(requestOptions)); + } + + private async __listNewsfeeds( + requestOptions?: News.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "news/newsfeeds", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.PaginatedResponse, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/newsfeeds."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch the details of a single newsfeed + * + * @param {Intercom.unstable.RetrieveNewsfeedRequest} request + * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.news.retrieveNewsfeed({ + * id: "123" + * }) + */ + public retrieveNewsfeed( + request: Intercom.unstable.RetrieveNewsfeedRequest, + requestOptions?: News.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveNewsfeed(request, requestOptions)); + } + + private async __retrieveNewsfeed( + request: Intercom.unstable.RetrieveNewsfeedRequest, + requestOptions?: News.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `news/newsfeeds/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Newsfeed, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/newsfeeds/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/news/client/index.ts b/src/api/resources/unstable/resources/news/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/news/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/news/client/requests/DeleteNewsItemRequest.ts b/src/api/resources/unstable/resources/news/client/requests/DeleteNewsItemRequest.ts new file mode 100644 index 00000000..5edfca2a --- /dev/null +++ b/src/api/resources/unstable/resources/news/client/requests/DeleteNewsItemRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1 + * } + */ +export interface DeleteNewsItemRequest { + /** + * The unique identifier for the news item which is given by Intercom. + */ + id: number; +} diff --git a/src/api/resources/unstable/resources/news/client/requests/ListLiveNewsfeedItemsRequest.ts b/src/api/resources/unstable/resources/news/client/requests/ListLiveNewsfeedItemsRequest.ts new file mode 100644 index 00000000..4101909c --- /dev/null +++ b/src/api/resources/unstable/resources/news/client/requests/ListLiveNewsfeedItemsRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "123" + * } + */ +export interface ListLiveNewsfeedItemsRequest { + /** + * The unique identifier for the news feed item which is given by Intercom. + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/news/client/requests/RetrieveNewsItemRequest.ts b/src/api/resources/unstable/resources/news/client/requests/RetrieveNewsItemRequest.ts new file mode 100644 index 00000000..b2e33231 --- /dev/null +++ b/src/api/resources/unstable/resources/news/client/requests/RetrieveNewsItemRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1 + * } + */ +export interface RetrieveNewsItemRequest { + /** + * The unique identifier for the news item which is given by Intercom. + */ + id: number; +} diff --git a/src/api/resources/unstable/resources/news/client/requests/RetrieveNewsfeedRequest.ts b/src/api/resources/unstable/resources/news/client/requests/RetrieveNewsfeedRequest.ts new file mode 100644 index 00000000..a4d0663a --- /dev/null +++ b/src/api/resources/unstable/resources/news/client/requests/RetrieveNewsfeedRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "123" + * } + */ +export interface RetrieveNewsfeedRequest { + /** + * The unique identifier for the news feed item which is given by Intercom. + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/news/client/requests/UpdateNewsItemRequest.ts b/src/api/resources/unstable/resources/news/client/requests/UpdateNewsItemRequest.ts new file mode 100644 index 00000000..e0962588 --- /dev/null +++ b/src/api/resources/unstable/resources/news/client/requests/UpdateNewsItemRequest.ts @@ -0,0 +1,36 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * id: 1, + * body: { + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

", + * sender_id: 991267845, + * reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"] + * } + * } + * + * @example + * { + * id: 1, + * body: { + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

", + * sender_id: 991267848, + * reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"] + * } + * } + */ +export interface UpdateNewsItemRequest { + /** + * The unique identifier for the news item which is given by Intercom. + */ + id: number; + body: Intercom.unstable.NewsItemRequest; +} diff --git a/src/api/resources/unstable/resources/news/client/requests/index.ts b/src/api/resources/unstable/resources/news/client/requests/index.ts new file mode 100644 index 00000000..94944125 --- /dev/null +++ b/src/api/resources/unstable/resources/news/client/requests/index.ts @@ -0,0 +1,5 @@ +export { type RetrieveNewsItemRequest } from "./RetrieveNewsItemRequest"; +export { type UpdateNewsItemRequest } from "./UpdateNewsItemRequest"; +export { type DeleteNewsItemRequest } from "./DeleteNewsItemRequest"; +export { type ListLiveNewsfeedItemsRequest } from "./ListLiveNewsfeedItemsRequest"; +export { type RetrieveNewsfeedRequest } from "./RetrieveNewsfeedRequest"; diff --git a/src/api/resources/unstable/resources/news/index.ts b/src/api/resources/unstable/resources/news/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/news/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/news/types/NewsItem.ts b/src/api/resources/unstable/resources/news/types/NewsItem.ts new file mode 100644 index 00000000..6650f0c5 --- /dev/null +++ b/src/api/resources/unstable/resources/news/types/NewsItem.ts @@ -0,0 +1,48 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * A News Item is a content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers. + */ +export interface NewsItem { + /** The unique identifier for the news item which is given by Intercom. */ + id?: string; + /** The id of the workspace which the news item belongs to. */ + workspace_id?: string; + /** The title of the news item. */ + title?: string; + /** The news item body, which may contain HTML. */ + body?: string; + /** The id of the sender of the news item. Must be a teammate on the workspace. */ + sender_id?: number; + /** News items will not be visible to your users in the assigned newsfeeds until they are set live. */ + state?: NewsItem.State; + /** A list of newsfeed_assignments to assign to the specified newsfeed. */ + newsfeed_assignments?: Intercom.unstable.NewsfeedAssignment[]; + /** Label names displayed to users to categorize the news item. */ + labels?: (string | undefined)[]; + /** URL of the image used as cover. Must have .jpg or .png extension. */ + cover_image_url?: string; + /** Ordered list of emoji reactions to the news item. When empty, reactions are disabled. */ + reactions?: (string | undefined)[]; + /** When set to true, the news item will appear in the messenger newsfeed without showing a notification badge. */ + deliver_silently?: boolean; + /** Timestamp for when the news item was created. */ + created_at?: number; + /** Timestamp for when the news item was last updated. */ + updated_at?: number; +} + +export namespace NewsItem { + /** + * News items will not be visible to your users in the assigned newsfeeds until they are set live. + */ + export type State = "draft" | "live"; + export const State = { + Draft: "draft", + Live: "live", + } as const; +} diff --git a/src/api/resources/unstable/resources/news/types/Newsfeed.ts b/src/api/resources/unstable/resources/news/types/Newsfeed.ts new file mode 100644 index 00000000..10dc3a1f --- /dev/null +++ b/src/api/resources/unstable/resources/news/types/Newsfeed.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A newsfeed is a collection of news items, targeted to a specific audience. + * + * Newsfeeds currently cannot be edited through the API, please refer to [this article](https://www.intercom.com/help/en/articles/6362267-getting-started-with-news) to set up your newsfeeds in Intercom. + */ +export interface Newsfeed { + /** The unique identifier for the newsfeed which is given by Intercom. */ + id?: string; + /** The name of the newsfeed. This name will never be visible to your users. */ + name?: string; + /** Timestamp for when the newsfeed was created. */ + created_at?: number; + /** Timestamp for when the newsfeed was last updated. */ + updated_at?: number; +} diff --git a/src/api/resources/unstable/resources/news/types/NewsfeedAssignment.ts b/src/api/resources/unstable/resources/news/types/NewsfeedAssignment.ts new file mode 100644 index 00000000..2eb97d45 --- /dev/null +++ b/src/api/resources/unstable/resources/news/types/NewsfeedAssignment.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Assigns a news item to a newsfeed. + */ +export interface NewsfeedAssignment { + /** The unique identifier for the newsfeed which is given by Intercom. Publish dates cannot be in the future, to schedule news items use the dedicated feature in app (see this article). */ + newsfeed_id?: number; + /** Publish date of the news item on the newsfeed, use this field if you want to set a publish date in the past (e.g. when importing existing news items). On write, this field will be ignored if the news item state is "draft". */ + published_at?: number; +} diff --git a/src/api/resources/unstable/resources/news/types/index.ts b/src/api/resources/unstable/resources/news/types/index.ts new file mode 100644 index 00000000..b8c22f3c --- /dev/null +++ b/src/api/resources/unstable/resources/news/types/index.ts @@ -0,0 +1,3 @@ +export * from "./NewsItem"; +export * from "./Newsfeed"; +export * from "./NewsfeedAssignment"; diff --git a/src/api/resources/unstable/resources/notes/client/Client.ts b/src/api/resources/unstable/resources/notes/client/Client.ts new file mode 100644 index 00000000..b82d5191 --- /dev/null +++ b/src/api/resources/unstable/resources/notes/client/Client.ts @@ -0,0 +1,367 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Notes { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Notes + */ +export class Notes { + constructor(protected readonly _options: Notes.Options = {}) {} + + /** + * You can fetch a list of notes that are associated to a contact. + * + * @param {Intercom.unstable.ListNotesRequest} request + * @param {Notes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.notes.listNotes({ + * id: 1 + * }) + */ + public listNotes( + request: Intercom.unstable.ListNotesRequest, + requestOptions?: Notes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listNotes(request, requestOptions)); + } + + private async __listNotes( + request: Intercom.unstable.ListNotesRequest, + requestOptions?: Notes.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(id)}/notes`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.NoteList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts/{id}/notes."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can add a note to a single contact. + * + * @param {Intercom.unstable.CreateNoteRequest} request + * @param {Notes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.notes.createNote({ + * id: 1, + * body: "Hello", + * contact_id: "6762f0ad1bb69f9f2193bb62", + * admin_id: "123" + * }) + * + * @example + * await client.unstable.notes.createNote({ + * id: 1, + * body: "Hello", + * contact_id: "6762f0af1bb69f9f2193bb63", + * admin_id: "123" + * }) + * + * @example + * await client.unstable.notes.createNote({ + * id: 1, + * body: "Hello", + * contact_id: "123", + * admin_id: "123" + * }) + */ + public createNote( + request: Intercom.unstable.CreateNoteRequest, + requestOptions?: Notes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createNote(request, requestOptions)); + } + + private async __createNote( + request: Intercom.unstable.CreateNoteRequest, + requestOptions?: Notes.RequestOptions, + ): Promise> { + const { id, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(id)}/notes`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Note, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/{id}/notes."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch the details of a single note. + * + * @param {Intercom.unstable.RetrieveNoteRequest} request + * @param {Notes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.notes.retrieveNote({ + * id: 1 + * }) + */ + public retrieveNote( + request: Intercom.unstable.RetrieveNoteRequest, + requestOptions?: Notes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveNote(request, requestOptions)); + } + + private async __retrieveNote( + request: Intercom.unstable.RetrieveNoteRequest, + requestOptions?: Notes.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `notes/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Note, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /notes/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/notes/client/index.ts b/src/api/resources/unstable/resources/notes/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/notes/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/notes/client/requests/CreateNoteRequest.ts b/src/api/resources/unstable/resources/notes/client/requests/CreateNoteRequest.ts new file mode 100644 index 00000000..8fe9c7ae --- /dev/null +++ b/src/api/resources/unstable/resources/notes/client/requests/CreateNoteRequest.ts @@ -0,0 +1,41 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1, + * body: "Hello", + * contact_id: "6762f0ad1bb69f9f2193bb62", + * admin_id: "123" + * } + * + * @example + * { + * id: 1, + * body: "Hello", + * contact_id: "6762f0af1bb69f9f2193bb63", + * admin_id: "123" + * } + * + * @example + * { + * id: 1, + * body: "Hello", + * contact_id: "123", + * admin_id: "123" + * } + */ +export interface CreateNoteRequest { + /** + * The unique identifier of a given contact. + */ + id: number; + /** The text of the note. */ + body: string; + /** The unique identifier of a given contact. */ + contact_id?: string; + /** The unique identifier of a given admin. */ + admin_id?: string; +} diff --git a/src/api/resources/unstable/resources/notes/client/requests/ListNotesRequest.ts b/src/api/resources/unstable/resources/notes/client/requests/ListNotesRequest.ts new file mode 100644 index 00000000..7d8052df --- /dev/null +++ b/src/api/resources/unstable/resources/notes/client/requests/ListNotesRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1 + * } + */ +export interface ListNotesRequest { + /** + * The unique identifier of a contact. + */ + id: number; +} diff --git a/src/api/resources/unstable/resources/notes/client/requests/RetrieveNoteRequest.ts b/src/api/resources/unstable/resources/notes/client/requests/RetrieveNoteRequest.ts new file mode 100644 index 00000000..8fc83798 --- /dev/null +++ b/src/api/resources/unstable/resources/notes/client/requests/RetrieveNoteRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: 1 + * } + */ +export interface RetrieveNoteRequest { + /** + * The unique identifier of a given note + */ + id: number; +} diff --git a/src/api/resources/unstable/resources/notes/client/requests/index.ts b/src/api/resources/unstable/resources/notes/client/requests/index.ts new file mode 100644 index 00000000..4fa65001 --- /dev/null +++ b/src/api/resources/unstable/resources/notes/client/requests/index.ts @@ -0,0 +1,3 @@ +export { type ListNotesRequest } from "./ListNotesRequest"; +export { type CreateNoteRequest } from "./CreateNoteRequest"; +export { type RetrieveNoteRequest } from "./RetrieveNoteRequest"; diff --git a/src/api/resources/unstable/resources/notes/index.ts b/src/api/resources/unstable/resources/notes/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/notes/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/notes/types/Note.ts b/src/api/resources/unstable/resources/notes/types/Note.ts new file mode 100644 index 00000000..d4bc42b2 --- /dev/null +++ b/src/api/resources/unstable/resources/notes/types/Note.ts @@ -0,0 +1,35 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * Notes allow you to annotate and comment on your contacts. + */ +export interface Note { + /** String representing the object's type. Always has the value `note`. */ + type?: string; + /** The id of the note. */ + id?: string; + /** The time the note was created. */ + created_at?: number; + /** Represents the contact that the note was created about. */ + contact?: Note.Contact; + /** Optional. Represents the Admin that created the note. */ + author?: Intercom.unstable.Admin; + /** The body text of the note. */ + body?: string; +} + +export namespace Note { + /** + * Represents the contact that the note was created about. + */ + export interface Contact { + /** String representing the object's type. Always has the value `contact`. */ + type?: string; + /** The id of the contact. */ + id?: string; + } +} diff --git a/src/api/resources/unstable/resources/notes/types/index.ts b/src/api/resources/unstable/resources/notes/types/index.ts new file mode 100644 index 00000000..cf881fa5 --- /dev/null +++ b/src/api/resources/unstable/resources/notes/types/index.ts @@ -0,0 +1 @@ +export * from "./Note"; diff --git a/src/api/resources/unstable/resources/segments/client/Client.ts b/src/api/resources/unstable/resources/segments/client/Client.ts new file mode 100644 index 00000000..67d08f1f --- /dev/null +++ b/src/api/resources/unstable/resources/segments/client/Client.ts @@ -0,0 +1,270 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Segments { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Segments + */ +export class Segments { + constructor(protected readonly _options: Segments.Options = {}) {} + + /** + * You can fetch a list of all segments. + * + * @param {Intercom.unstable.ListSegmentsRequest} request + * @param {Segments.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.segments.listSegments() + */ + public listSegments( + request: Intercom.unstable.ListSegmentsRequest = {}, + requestOptions?: Segments.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listSegments(request, requestOptions)); + } + + private async __listSegments( + request: Intercom.unstable.ListSegmentsRequest = {}, + requestOptions?: Segments.RequestOptions, + ): Promise> { + const { include_count: includeCount } = request; + const _queryParams: Record = {}; + if (includeCount != null) { + _queryParams["include_count"] = includeCount.toString(); + } + + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "segments", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.SegmentList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /segments."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch the details of a single segment. + * + * @param {Intercom.unstable.RetrieveSegmentRequest} request + * @param {Segments.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.segments.retrieveSegment({ + * id: "123" + * }) + */ + public retrieveSegment( + request: Intercom.unstable.RetrieveSegmentRequest, + requestOptions?: Segments.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveSegment(request, requestOptions)); + } + + private async __retrieveSegment( + request: Intercom.unstable.RetrieveSegmentRequest, + requestOptions?: Segments.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `segments/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Segment, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /segments/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/segments/client/index.ts b/src/api/resources/unstable/resources/segments/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/segments/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/segments/client/requests/ListSegmentsRequest.ts b/src/api/resources/unstable/resources/segments/client/requests/ListSegmentsRequest.ts new file mode 100644 index 00000000..116acd5e --- /dev/null +++ b/src/api/resources/unstable/resources/segments/client/requests/ListSegmentsRequest.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * {} + */ +export interface ListSegmentsRequest { + /** + * It includes the count of contacts that belong to each segment. + */ + include_count?: boolean; +} diff --git a/src/api/resources/unstable/resources/segments/client/requests/RetrieveSegmentRequest.ts b/src/api/resources/unstable/resources/segments/client/requests/RetrieveSegmentRequest.ts new file mode 100644 index 00000000..0ba937bf --- /dev/null +++ b/src/api/resources/unstable/resources/segments/client/requests/RetrieveSegmentRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "123" + * } + */ +export interface RetrieveSegmentRequest { + /** + * The unique identified of a given segment. + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/segments/client/requests/index.ts b/src/api/resources/unstable/resources/segments/client/requests/index.ts new file mode 100644 index 00000000..d31998d0 --- /dev/null +++ b/src/api/resources/unstable/resources/segments/client/requests/index.ts @@ -0,0 +1,2 @@ +export { type ListSegmentsRequest } from "./ListSegmentsRequest"; +export { type RetrieveSegmentRequest } from "./RetrieveSegmentRequest"; diff --git a/src/api/resources/unstable/resources/segments/index.ts b/src/api/resources/unstable/resources/segments/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/segments/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/segments/types/Segment.ts b/src/api/resources/unstable/resources/segments/types/Segment.ts new file mode 100644 index 00000000..b297f427 --- /dev/null +++ b/src/api/resources/unstable/resources/segments/types/Segment.ts @@ -0,0 +1,34 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A segment is a group of your contacts defined by the rules that you set. + */ +export interface Segment { + /** The type of object. */ + type?: "segment"; + /** The unique identifier representing the segment. */ + id?: string; + /** The name of the segment. */ + name?: string; + /** The time the segment was created. */ + created_at?: number; + /** The time the segment was updated. */ + updated_at?: number; + /** Type of the contact: contact (lead) or user. */ + person_type?: Segment.PersonType; + /** The number of items in the user segment. It's returned when `include_count=true` is included in the request. */ + count?: number; +} + +export namespace Segment { + /** + * Type of the contact: contact (lead) or user. + */ + export type PersonType = "contact" | "user"; + export const PersonType = { + Contact: "contact", + User: "user", + } as const; +} diff --git a/src/api/resources/unstable/resources/segments/types/index.ts b/src/api/resources/unstable/resources/segments/types/index.ts new file mode 100644 index 00000000..957aab14 --- /dev/null +++ b/src/api/resources/unstable/resources/segments/types/index.ts @@ -0,0 +1 @@ +export * from "./Segment"; diff --git a/src/api/resources/unstable/resources/subscriptionTypes/client/Client.ts b/src/api/resources/unstable/resources/subscriptionTypes/client/Client.ts new file mode 100644 index 00000000..38e70154 --- /dev/null +++ b/src/api/resources/unstable/resources/subscriptionTypes/client/Client.ts @@ -0,0 +1,374 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace SubscriptionTypes { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about subscription types + */ +export class SubscriptionTypes { + constructor(protected readonly _options: SubscriptionTypes.Options = {}) {} + + /** + * You can add a specific subscription to a contact. In Intercom, we have two different subscription types based on user consent - opt-out and opt-in: + * + * 1.Attaching a contact to an opt-out subscription type will opt that user out from receiving messages related to that subscription type. + * + * 2.Attaching a contact to an opt-in subscription type will opt that user in to receiving messages related to that subscription type. + * + * This will return a subscription type model for the subscription type that was added to the contact. + * + * @param {Intercom.unstable.AttachSubscriptionTypeToContactRequest} request + * @param {SubscriptionTypes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({ + * contact_id: "63a07ddf05a32042dffac965", + * id: "37846", + * consent_type: "opt_in" + * }) + * + * @example + * await client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({ + * contact_id: "63a07ddf05a32042dffac965", + * id: "invalid_id", + * consent_type: "opt_in" + * }) + */ + public attachSubscriptionTypeToContact( + request: Intercom.unstable.AttachSubscriptionTypeToContactRequest, + requestOptions?: SubscriptionTypes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__attachSubscriptionTypeToContact(request, requestOptions)); + } + + private async __attachSubscriptionTypeToContact( + request: Intercom.unstable.AttachSubscriptionTypeToContactRequest, + requestOptions?: SubscriptionTypes.RequestOptions, + ): Promise> { + const { contact_id: contactId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/subscriptions`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.SubscriptionType, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /contacts/{contact_id}/subscriptions.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can remove a specific subscription from a contact. This will return a subscription type model for the subscription type that was removed from the contact. + * + * @param {Intercom.unstable.DetachSubscriptionTypeToContactRequest} request + * @param {SubscriptionTypes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.subscriptionTypes.detachSubscriptionTypeToContact({ + * contact_id: "63a07ddf05a32042dffac965", + * id: "37846" + * }) + */ + public detachSubscriptionTypeToContact( + request: Intercom.unstable.DetachSubscriptionTypeToContactRequest, + requestOptions?: SubscriptionTypes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__detachSubscriptionTypeToContact(request, requestOptions)); + } + + private async __detachSubscriptionTypeToContact( + request: Intercom.unstable.DetachSubscriptionTypeToContactRequest, + requestOptions?: SubscriptionTypes.RequestOptions, + ): Promise> { + const { contact_id: contactId, id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/subscriptions/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.SubscriptionType, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /contacts/{contact_id}/subscriptions/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can list all subscription types. A list of subscription type objects will be returned. + * + * @param {SubscriptionTypes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.subscriptionTypes.listSubscriptionTypes() + */ + public listSubscriptionTypes( + requestOptions?: SubscriptionTypes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listSubscriptionTypes(requestOptions)); + } + + private async __listSubscriptionTypes( + requestOptions?: SubscriptionTypes.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "subscription_types", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.SubscriptionTypeList, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /subscription_types."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/subscriptionTypes/client/index.ts b/src/api/resources/unstable/resources/subscriptionTypes/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/subscriptionTypes/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/subscriptionTypes/client/requests/AttachSubscriptionTypeToContactRequest.ts b/src/api/resources/unstable/resources/subscriptionTypes/client/requests/AttachSubscriptionTypeToContactRequest.ts new file mode 100644 index 00000000..742321c7 --- /dev/null +++ b/src/api/resources/unstable/resources/subscriptionTypes/client/requests/AttachSubscriptionTypeToContactRequest.ts @@ -0,0 +1,36 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * id: "37846", + * consent_type: "opt_in" + * } + * + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * id: "37846", + * consent_type: "opt_in" + * } + * + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * id: "invalid_id", + * consent_type: "opt_in" + * } + */ +export interface AttachSubscriptionTypeToContactRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; + /** The unique identifier for the subscription which is given by Intercom */ + id: string; + /** The consent_type of a subscription, opt_out or opt_in. */ + consent_type: string; +} diff --git a/src/api/resources/unstable/resources/subscriptionTypes/client/requests/DetachSubscriptionTypeToContactRequest.ts b/src/api/resources/unstable/resources/subscriptionTypes/client/requests/DetachSubscriptionTypeToContactRequest.ts new file mode 100644 index 00000000..8ad29dba --- /dev/null +++ b/src/api/resources/unstable/resources/subscriptionTypes/client/requests/DetachSubscriptionTypeToContactRequest.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * id: "37846" + * } + */ +export interface DetachSubscriptionTypeToContactRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; + /** + * The unique identifier for the subscription type which is given by Intercom + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/subscriptionTypes/client/requests/index.ts b/src/api/resources/unstable/resources/subscriptionTypes/client/requests/index.ts new file mode 100644 index 00000000..d5cc644c --- /dev/null +++ b/src/api/resources/unstable/resources/subscriptionTypes/client/requests/index.ts @@ -0,0 +1,2 @@ +export { type AttachSubscriptionTypeToContactRequest } from "./AttachSubscriptionTypeToContactRequest"; +export { type DetachSubscriptionTypeToContactRequest } from "./DetachSubscriptionTypeToContactRequest"; diff --git a/src/api/resources/unstable/resources/subscriptionTypes/index.ts b/src/api/resources/unstable/resources/subscriptionTypes/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/subscriptionTypes/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/subscriptionTypes/types/SubscriptionType.ts b/src/api/resources/unstable/resources/subscriptionTypes/types/SubscriptionType.ts new file mode 100644 index 00000000..bcb2bd27 --- /dev/null +++ b/src/api/resources/unstable/resources/subscriptionTypes/types/SubscriptionType.ts @@ -0,0 +1,53 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * A subscription type lets customers easily opt out of non-essential communications without missing what's important to them. + */ +export interface SubscriptionType { + /** The type of the object - subscription */ + type?: string; + /** The unique identifier representing the subscription type. */ + id?: string; + /** The state of the subscription type. */ + state?: SubscriptionType.State; + default_translation?: Intercom.unstable.Translation; + /** An array of translations objects with the localised version of the subscription type in each available locale within your translation settings. */ + translations?: Intercom.unstable.Translation[]; + /** Describes the type of consent. */ + consent_type?: SubscriptionType.ConsentType; + /** The message types that this subscription supports - can contain `email` or `sms_message`. */ + content_types?: SubscriptionType.ContentTypes.Item[]; +} + +export namespace SubscriptionType { + /** + * The state of the subscription type. + */ + export type State = "live" | "draft" | "archived"; + export const State = { + Live: "live", + Draft: "draft", + Archived: "archived", + } as const; + /** + * Describes the type of consent. + */ + export type ConsentType = "opt_out" | "opt_in"; + export const ConsentType = { + OptOut: "opt_out", + OptIn: "opt_in", + } as const; + export type ContentTypes = ContentTypes.Item[]; + + export namespace ContentTypes { + export type Item = "email" | "sms_message"; + export const Item = { + Email: "email", + SmsMessage: "sms_message", + } as const; + } +} diff --git a/src/api/resources/unstable/resources/subscriptionTypes/types/index.ts b/src/api/resources/unstable/resources/subscriptionTypes/types/index.ts new file mode 100644 index 00000000..fe95bab5 --- /dev/null +++ b/src/api/resources/unstable/resources/subscriptionTypes/types/index.ts @@ -0,0 +1 @@ +export * from "./SubscriptionType"; diff --git a/src/api/resources/unstable/resources/switch/client/Client.ts b/src/api/resources/unstable/resources/switch/client/Client.ts new file mode 100644 index 00000000..543d2759 --- /dev/null +++ b/src/api/resources/unstable/resources/switch/client/Client.ts @@ -0,0 +1,191 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Switch { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about Switch + */ +export class Switch { + constructor(protected readonly _options: Switch.Options = {}) {} + + /** + * You can use the API to deflect phone calls to the Intercom Messenger. + * Calling this endpoint will send an SMS with a link to the Messenger to the phone number specified. + * + * If custom attributes are specified, they will be added to the user or lead's custom data attributes. + * + * @param {unknown} request + * @param {Switch.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.UnprocessableEntityError} + * + * @example + * await client.unstable.switch.createPhoneSwitch({ + * "key": "value" + * }) + */ + public createPhoneSwitch( + request?: unknown, + requestOptions?: Switch.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createPhoneSwitch(request, requestOptions)); + } + + private async __createPhoneSwitch( + request?: unknown, + requestOptions?: Switch.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "phone_call_redirects", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.PhoneSwitch | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 422: + throw new Intercom.unstable.UnprocessableEntityError( + _response.error.body as unknown, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /phone_call_redirects."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/switch/client/index.ts b/src/api/resources/unstable/resources/switch/client/index.ts new file mode 100644 index 00000000..cb0ff5c3 --- /dev/null +++ b/src/api/resources/unstable/resources/switch/client/index.ts @@ -0,0 +1 @@ +export {}; diff --git a/src/api/resources/unstable/resources/switch/index.ts b/src/api/resources/unstable/resources/switch/index.ts new file mode 100644 index 00000000..5ec76921 --- /dev/null +++ b/src/api/resources/unstable/resources/switch/index.ts @@ -0,0 +1 @@ +export * from "./client"; diff --git a/src/api/resources/unstable/resources/tags/client/Client.ts b/src/api/resources/unstable/resources/tags/client/Client.ts new file mode 100644 index 00000000..279f075c --- /dev/null +++ b/src/api/resources/unstable/resources/tags/client/Client.ts @@ -0,0 +1,1049 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Tags { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about tags + */ +export class Tags { + constructor(protected readonly _options: Tags.Options = {}) {} + + /** + * You can tag a specific contact. This will return a tag object for the tag that was added to the contact. + * + * @param {Intercom.unstable.AttachTagToContactRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.tags.attachTagToContact({ + * contact_id: "63a07ddf05a32042dffac965", + * id: "7522907" + * }) + * + * @example + * await client.unstable.tags.attachTagToContact({ + * contact_id: "63a07ddf05a32042dffac965", + * id: "123" + * }) + */ + public attachTagToContact( + request: Intercom.unstable.AttachTagToContactRequest, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__attachTagToContact(request, requestOptions)); + } + + private async __attachTagToContact( + request: Intercom.unstable.AttachTagToContactRequest, + requestOptions?: Tags.RequestOptions, + ): Promise> { + const { contact_id: contactId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/tags`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /contacts/{contact_id}/tags.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can remove tag from a specific contact. This will return a tag object for the tag that was removed from the contact. + * + * @param {Intercom.unstable.DetachTagFromContactRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.tags.detachTagFromContact({ + * contact_id: "63a07ddf05a32042dffac965", + * id: "7522907" + * }) + */ + public detachTagFromContact( + request: Intercom.unstable.DetachTagFromContactRequest, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__detachTagFromContact(request, requestOptions)); + } + + private async __detachTagFromContact( + request: Intercom.unstable.DetachTagFromContactRequest, + requestOptions?: Tags.RequestOptions, + ): Promise> { + const { contact_id: contactId, id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${encodeURIComponent(contactId)}/tags/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /contacts/{contact_id}/tags/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can tag a specific conversation. This will return a tag object for the tag that was added to the conversation. + * + * @param {Intercom.unstable.AttachTagToConversationRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.tags.attachTagToConversation({ + * conversation_id: "64619700005694", + * id: "7522907", + * admin_id: "780" + * }) + */ + public attachTagToConversation( + request: Intercom.unstable.AttachTagToConversationRequest, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__attachTagToConversation(request, requestOptions)); + } + + private async __attachTagToConversation( + request: Intercom.unstable.AttachTagToConversationRequest, + requestOptions?: Tags.RequestOptions, + ): Promise> { + const { conversation_id: conversationId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/tags`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /conversations/{conversation_id}/tags.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can remove tag from a specific conversation. This will return a tag object for the tag that was removed from the conversation. + * + * @param {Intercom.unstable.DetachTagFromConversationRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.tags.detachTagFromConversation({ + * conversation_id: "64619700005694", + * id: "7522907", + * admin_id: "123" + * }) + */ + public detachTagFromConversation( + request: Intercom.unstable.DetachTagFromConversationRequest, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__detachTagFromConversation(request, requestOptions)); + } + + private async __detachTagFromConversation( + request: Intercom.unstable.DetachTagFromConversationRequest, + requestOptions?: Tags.RequestOptions, + ): Promise> { + const { conversation_id: conversationId, id, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${encodeURIComponent(conversationId)}/tags/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /conversations/{conversation_id}/tags/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch a list of all tags for a given workspace. + * + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.tags.listTags() + */ + public listTags(requestOptions?: Tags.RequestOptions): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listTags(requestOptions)); + } + + private async __listTags( + requestOptions?: Tags.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "tags", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.TagList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tags."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can use this endpoint to perform the following operations: + * + * **1. Create a new tag:** You can create a new tag by passing in the tag name as specified in "Create or Update Tag Request Payload" described below. + * + * **2. Update an existing tag:** You can update an existing tag by passing the id of the tag as specified in "Create or Update Tag Request Payload" described below. + * + * **3. Tag Companies:** You can tag single company or a list of companies. You can tag a company by passing in the tag name and the company details as specified in "Tag Company Request Payload" described below. Also, if the tag doesn't exist then a new one will be created automatically. + * + * **4. Untag Companies:** You can untag a single company or a list of companies. You can untag a company by passing in the tag id and the company details as specified in "Untag Company Request Payload" described below. + * + * **5. Tag Multiple Users:** You can tag a list of users. You can tag the users by passing in the tag name and the user details as specified in "Tag Users Request Payload" described below. + * + * Each operation will return a tag object. + * + * @param {Intercom.unstable.CreateTagRequestBody} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.tags.createTag({ + * name: "test" + * }) + * + * @example + * await client.unstable.tags.createTag({ + * name: "Independent" + * }) + * + * @example + * await client.unstable.tags.createTag({ + * name: "test", + * companies: [{ + * company_id: "123" + * }] + * }) + * + * @example + * await client.unstable.tags.createTag({ + * name: "test", + * users: [{ + * id: "123" + * }] + * }) + */ + public createTag( + request: Intercom.unstable.CreateTagRequestBody, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createTag(request, requestOptions)); + } + + private async __createTag( + request: Intercom.unstable.CreateTagRequestBody, + requestOptions?: Tags.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "tags", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tags."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch the details of tags that are on the workspace by their id. + * This will return a tag object. + * + * @param {Intercom.unstable.FindTagRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.tags.findTag({ + * id: "123" + * }) + */ + public findTag( + request: Intercom.unstable.FindTagRequest, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__findTag(request, requestOptions)); + } + + private async __findTag( + request: Intercom.unstable.FindTagRequest, + requestOptions?: Tags.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tags/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tags/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can delete the details of tags that are on the workspace by passing in the id. + * + * @param {Intercom.unstable.DeleteTagRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.tags.deleteTag({ + * id: "123" + * }) + */ + public deleteTag( + request: Intercom.unstable.DeleteTagRequest, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteTag(request, requestOptions)); + } + + private async __deleteTag( + request: Intercom.unstable.DeleteTagRequest, + requestOptions?: Tags.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tags/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: undefined, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /tags/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can tag a specific ticket. This will return a tag object for the tag that was added to the ticket. + * + * @param {Intercom.unstable.AttachTagToTicketRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.tags.attachTagToTicket({ + * ticket_id: "64619700005694", + * id: "7522907", + * admin_id: "780" + * }) + */ + public attachTagToTicket( + request: Intercom.unstable.AttachTagToTicketRequest, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__attachTagToTicket(request, requestOptions)); + } + + private async __attachTagToTicket( + request: Intercom.unstable.AttachTagToTicketRequest, + requestOptions?: Tags.RequestOptions, + ): Promise> { + const { ticket_id: ticketId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(ticketId)}/tags`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/{ticket_id}/tags."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can remove tag from a specific ticket. This will return a tag object for the tag that was removed from the ticket. + * + * @param {Intercom.unstable.DetachTagFromTicketRequest} request + * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.tags.detachTagFromTicket({ + * ticket_id: "64619700005694", + * id: "7522907", + * admin_id: "123" + * }) + */ + public detachTagFromTicket( + request: Intercom.unstable.DetachTagFromTicketRequest, + requestOptions?: Tags.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__detachTagFromTicket(request, requestOptions)); + } + + private async __detachTagFromTicket( + request: Intercom.unstable.DetachTagFromTicketRequest, + requestOptions?: Tags.RequestOptions, + ): Promise> { + const { ticket_id: ticketId, id, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(ticketId)}/tags/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling DELETE /tickets/{ticket_id}/tags/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/tags/client/index.ts b/src/api/resources/unstable/resources/tags/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/tags/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/tags/client/requests/AttachTagToContactRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/AttachTagToContactRequest.ts new file mode 100644 index 00000000..2d9e27cc --- /dev/null +++ b/src/api/resources/unstable/resources/tags/client/requests/AttachTagToContactRequest.ts @@ -0,0 +1,31 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * id: "7522907" + * } + * + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * id: "7522907" + * } + * + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * id: "123" + * } + */ +export interface AttachTagToContactRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; + /** The unique identifier for the tag which is given by Intercom */ + id: string; +} diff --git a/src/api/resources/unstable/resources/tags/client/requests/AttachTagToConversationRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/AttachTagToConversationRequest.ts new file mode 100644 index 00000000..f3533c92 --- /dev/null +++ b/src/api/resources/unstable/resources/tags/client/requests/AttachTagToConversationRequest.ts @@ -0,0 +1,29 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * conversation_id: "64619700005694", + * id: "7522907", + * admin_id: "780" + * } + * + * @example + * { + * conversation_id: "64619700005694", + * id: "7522907", + * admin_id: "780" + * } + */ +export interface AttachTagToConversationRequest { + /** + * conversation_id + */ + conversation_id: string; + /** The unique identifier for the tag which is given by Intercom */ + id: string; + /** The unique identifier for the admin which is given by Intercom. */ + admin_id: string; +} diff --git a/src/api/resources/unstable/resources/tags/client/requests/AttachTagToTicketRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/AttachTagToTicketRequest.ts new file mode 100644 index 00000000..55d90d6b --- /dev/null +++ b/src/api/resources/unstable/resources/tags/client/requests/AttachTagToTicketRequest.ts @@ -0,0 +1,29 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * ticket_id: "64619700005694", + * id: "7522907", + * admin_id: "780" + * } + * + * @example + * { + * ticket_id: "64619700005694", + * id: "7522907", + * admin_id: "780" + * } + */ +export interface AttachTagToTicketRequest { + /** + * ticket_id + */ + ticket_id: string; + /** The unique identifier for the tag which is given by Intercom */ + id: string; + /** The unique identifier for the admin which is given by Intercom. */ + admin_id: string; +} diff --git a/src/api/resources/unstable/resources/tags/client/requests/DeleteTagRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/DeleteTagRequest.ts new file mode 100644 index 00000000..95921be7 --- /dev/null +++ b/src/api/resources/unstable/resources/tags/client/requests/DeleteTagRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "123" + * } + */ +export interface DeleteTagRequest { + /** + * The unique identifier of a given tag + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromContactRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromContactRequest.ts new file mode 100644 index 00000000..a4d90398 --- /dev/null +++ b/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromContactRequest.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * id: "7522907" + * } + */ +export interface DetachTagFromContactRequest { + /** + * The unique identifier for the contact which is given by Intercom + */ + contact_id: string; + /** + * The unique identifier for the tag which is given by Intercom + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromConversationRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromConversationRequest.ts new file mode 100644 index 00000000..b41584c0 --- /dev/null +++ b/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromConversationRequest.ts @@ -0,0 +1,38 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * conversation_id: "64619700005694", + * id: "7522907", + * admin_id: "123" + * } + * + * @example + * { + * conversation_id: "64619700005694", + * id: "7522907", + * admin_id: "123" + * } + * + * @example + * { + * conversation_id: "64619700005694", + * id: "7522907", + * admin_id: "123" + * } + */ +export interface DetachTagFromConversationRequest { + /** + * conversation_id + */ + conversation_id: string; + /** + * id + */ + id: string; + /** The unique identifier for the admin which is given by Intercom. */ + admin_id: string; +} diff --git a/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromTicketRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromTicketRequest.ts new file mode 100644 index 00000000..ed321a9a --- /dev/null +++ b/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromTicketRequest.ts @@ -0,0 +1,38 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * ticket_id: "64619700005694", + * id: "7522907", + * admin_id: "123" + * } + * + * @example + * { + * ticket_id: "64619700005694", + * id: "7522907", + * admin_id: "123" + * } + * + * @example + * { + * ticket_id: "64619700005694", + * id: "7522907", + * admin_id: "123" + * } + */ +export interface DetachTagFromTicketRequest { + /** + * ticket_id + */ + ticket_id: string; + /** + * The unique identifier for the tag which is given by Intercom + */ + id: string; + /** The unique identifier for the admin which is given by Intercom. */ + admin_id: string; +} diff --git a/src/api/resources/unstable/resources/tags/client/requests/FindTagRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/FindTagRequest.ts new file mode 100644 index 00000000..7f23eca2 --- /dev/null +++ b/src/api/resources/unstable/resources/tags/client/requests/FindTagRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "123" + * } + */ +export interface FindTagRequest { + /** + * The unique identifier of a given tag + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/tags/client/requests/index.ts b/src/api/resources/unstable/resources/tags/client/requests/index.ts new file mode 100644 index 00000000..f529317a --- /dev/null +++ b/src/api/resources/unstable/resources/tags/client/requests/index.ts @@ -0,0 +1,8 @@ +export { type AttachTagToContactRequest } from "./AttachTagToContactRequest"; +export { type DetachTagFromContactRequest } from "./DetachTagFromContactRequest"; +export { type AttachTagToConversationRequest } from "./AttachTagToConversationRequest"; +export { type DetachTagFromConversationRequest } from "./DetachTagFromConversationRequest"; +export { type FindTagRequest } from "./FindTagRequest"; +export { type DeleteTagRequest } from "./DeleteTagRequest"; +export { type AttachTagToTicketRequest } from "./AttachTagToTicketRequest"; +export { type DetachTagFromTicketRequest } from "./DetachTagFromTicketRequest"; diff --git a/src/api/resources/unstable/resources/tags/index.ts b/src/api/resources/unstable/resources/tags/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/tags/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/tags/types/CreateTagRequestBody.ts b/src/api/resources/unstable/resources/tags/types/CreateTagRequestBody.ts new file mode 100644 index 00000000..cd52e610 --- /dev/null +++ b/src/api/resources/unstable/resources/tags/types/CreateTagRequestBody.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +export type CreateTagRequestBody = + | Intercom.unstable.CreateOrUpdateTagRequest + | Intercom.unstable.TagCompanyRequest + | Intercom.unstable.UntagCompanyRequest + | Intercom.unstable.TagMultipleUsersRequest; diff --git a/src/api/resources/unstable/resources/tags/types/Tag.ts b/src/api/resources/unstable/resources/tags/types/Tag.ts new file mode 100644 index 00000000..869f2171 --- /dev/null +++ b/src/api/resources/unstable/resources/tags/types/Tag.ts @@ -0,0 +1,20 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * A tag allows you to label your contacts, companies, and conversations and list them using that tag. + */ +export interface Tag { + /** value is "tag" */ + type?: string; + /** The id of the tag */ + id?: string; + /** The name of the tag */ + name?: string; + /** The time when the tag was applied to the object */ + applied_at?: number; + applied_by?: Intercom.unstable.Reference; +} diff --git a/src/api/resources/unstable/resources/tags/types/TagBasic.ts b/src/api/resources/unstable/resources/tags/types/TagBasic.ts new file mode 100644 index 00000000..7067f78b --- /dev/null +++ b/src/api/resources/unstable/resources/tags/types/TagBasic.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A tag allows you to label your contacts, companies, and conversations and list them using that tag. + */ +export interface TagBasic { + /** value is "tag" */ + type?: string; + /** The id of the tag */ + id?: string; + /** The name of the tag */ + name?: string; +} diff --git a/src/api/resources/unstable/resources/tags/types/index.ts b/src/api/resources/unstable/resources/tags/types/index.ts new file mode 100644 index 00000000..0188807b --- /dev/null +++ b/src/api/resources/unstable/resources/tags/types/index.ts @@ -0,0 +1,3 @@ +export * from "./CreateTagRequestBody"; +export * from "./Tag"; +export * from "./TagBasic"; diff --git a/src/api/resources/unstable/resources/teams/client/Client.ts b/src/api/resources/unstable/resources/teams/client/Client.ts new file mode 100644 index 00000000..1a849930 --- /dev/null +++ b/src/api/resources/unstable/resources/teams/client/Client.ts @@ -0,0 +1,258 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Teams { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Teams + */ +export class Teams { + constructor(protected readonly _options: Teams.Options = {}) {} + + /** + * This will return a list of team objects for the App. + * + * @param {Teams.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.teams.listTeams() + */ + public listTeams(requestOptions?: Teams.RequestOptions): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listTeams(requestOptions)); + } + + private async __listTeams( + requestOptions?: Teams.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "teams", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.TeamList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /teams."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch the details of a single team, containing an array of admins that belong to this team. + * + * @param {Intercom.unstable.RetrieveTeamRequest} request + * @param {Teams.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.teams.retrieveTeam({ + * id: "123" + * }) + */ + public retrieveTeam( + request: Intercom.unstable.RetrieveTeamRequest, + requestOptions?: Teams.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveTeam(request, requestOptions)); + } + + private async __retrieveTeam( + request: Intercom.unstable.RetrieveTeamRequest, + requestOptions?: Teams.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `teams/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Team, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /teams/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/teams/client/index.ts b/src/api/resources/unstable/resources/teams/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/teams/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/teams/client/requests/RetrieveTeamRequest.ts b/src/api/resources/unstable/resources/teams/client/requests/RetrieveTeamRequest.ts new file mode 100644 index 00000000..0b09296c --- /dev/null +++ b/src/api/resources/unstable/resources/teams/client/requests/RetrieveTeamRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "123" + * } + */ +export interface RetrieveTeamRequest { + /** + * The unique identifier of a given team. + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/teams/client/requests/index.ts b/src/api/resources/unstable/resources/teams/client/requests/index.ts new file mode 100644 index 00000000..b8dd50a7 --- /dev/null +++ b/src/api/resources/unstable/resources/teams/client/requests/index.ts @@ -0,0 +1 @@ +export { type RetrieveTeamRequest } from "./RetrieveTeamRequest"; diff --git a/src/api/resources/unstable/resources/teams/index.ts b/src/api/resources/unstable/resources/teams/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/teams/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/teams/types/Team.ts b/src/api/resources/unstable/resources/teams/types/Team.ts new file mode 100644 index 00000000..8ba1d68f --- /dev/null +++ b/src/api/resources/unstable/resources/teams/types/Team.ts @@ -0,0 +1,20 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * Teams are groups of admins in Intercom. + */ +export interface Team { + /** Value is always "team" */ + type?: string; + /** The id of the team */ + id?: string; + /** The name of the team */ + name?: string; + /** The list of admin IDs that are a part of the team. */ + admin_ids?: number[]; + admin_priority_level?: Intercom.unstable.AdminPriorityLevel; +} diff --git a/src/api/resources/unstable/resources/teams/types/index.ts b/src/api/resources/unstable/resources/teams/types/index.ts new file mode 100644 index 00000000..e3645596 --- /dev/null +++ b/src/api/resources/unstable/resources/teams/types/index.ts @@ -0,0 +1 @@ +export * from "./Team"; diff --git a/src/api/resources/unstable/resources/ticketStates/client/Client.ts b/src/api/resources/unstable/resources/ticketStates/client/Client.ts new file mode 100644 index 00000000..9df86fd0 --- /dev/null +++ b/src/api/resources/unstable/resources/ticketStates/client/Client.ts @@ -0,0 +1,170 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace TicketStates { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your ticket states + */ +export class TicketStates { + constructor(protected readonly _options: TicketStates.Options = {}) {} + + /** + * You can get a list of all ticket states for a workspace. + * + * @param {TicketStates.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.ticketStates.listTicketStates() + */ + public listTicketStates( + requestOptions?: TicketStates.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listTicketStates(requestOptions)); + } + + private async __listTicketStates( + requestOptions?: TicketStates.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ticket_states", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.TicketStateList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ticket_states."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/ticketStates/client/index.ts b/src/api/resources/unstable/resources/ticketStates/client/index.ts new file mode 100644 index 00000000..cb0ff5c3 --- /dev/null +++ b/src/api/resources/unstable/resources/ticketStates/client/index.ts @@ -0,0 +1 @@ +export {}; diff --git a/src/api/resources/unstable/resources/ticketStates/index.ts b/src/api/resources/unstable/resources/ticketStates/index.ts new file mode 100644 index 00000000..5ec76921 --- /dev/null +++ b/src/api/resources/unstable/resources/ticketStates/index.ts @@ -0,0 +1 @@ +export * from "./client"; diff --git a/src/api/resources/unstable/resources/ticketTypeAttributes/client/Client.ts b/src/api/resources/unstable/resources/ticketTypeAttributes/client/Client.ts new file mode 100644 index 00000000..4db689cf --- /dev/null +++ b/src/api/resources/unstable/resources/ticketTypeAttributes/client/Client.ts @@ -0,0 +1,281 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace TicketTypeAttributes { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your ticket type attributes + */ +export class TicketTypeAttributes { + constructor(protected readonly _options: TicketTypeAttributes.Options = {}) {} + + /** + * You can create a new attribute for a ticket type. + * + * @param {Intercom.unstable.CreateTicketTypeAttributeRequest} request + * @param {TicketTypeAttributes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.ticketTypeAttributes.createTicketTypeAttribute({ + * ticket_type_id: "ticket_type_id", + * name: "Attribute Title", + * description: "Attribute Description", + * data_type: "string", + * required_to_create: false + * }) + */ + public createTicketTypeAttribute( + request: Intercom.unstable.CreateTicketTypeAttributeRequest, + requestOptions?: TicketTypeAttributes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createTicketTypeAttribute(request, requestOptions)); + } + + private async __createTicketTypeAttribute( + request: Intercom.unstable.CreateTicketTypeAttributeRequest, + requestOptions?: TicketTypeAttributes.RequestOptions, + ): Promise> { + const { ticket_type_id: ticketTypeId, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ticket_types/${encodeURIComponent(ticketTypeId)}/attributes`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.TicketTypeAttribute | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling POST /ticket_types/{ticket_type_id}/attributes.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can update an existing attribute for a ticket type. + * + * @param {Intercom.unstable.UpdateTicketTypeAttributeRequest} request + * @param {TicketTypeAttributes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.ticketTypeAttributes.updateTicketTypeAttribute({ + * ticket_type_id: "ticket_type_id", + * id: "id", + * description: "New Attribute Description" + * }) + */ + public updateTicketTypeAttribute( + request: Intercom.unstable.UpdateTicketTypeAttributeRequest, + requestOptions?: TicketTypeAttributes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateTicketTypeAttribute(request, requestOptions)); + } + + private async __updateTicketTypeAttribute( + request: Intercom.unstable.UpdateTicketTypeAttributeRequest, + requestOptions?: TicketTypeAttributes.RequestOptions, + ): Promise> { + const { ticket_type_id: ticketTypeId, id, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ticket_types/${encodeURIComponent(ticketTypeId)}/attributes/${encodeURIComponent(id)}`, + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.TicketTypeAttribute | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError( + "Timeout exceeded when calling PUT /ticket_types/{ticket_type_id}/attributes/{id}.", + ); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/ticketTypeAttributes/client/index.ts b/src/api/resources/unstable/resources/ticketTypeAttributes/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/ticketTypeAttributes/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/CreateTicketTypeAttributeRequest.ts b/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/CreateTicketTypeAttributeRequest.ts new file mode 100644 index 00000000..0a9604c1 --- /dev/null +++ b/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/CreateTicketTypeAttributeRequest.ts @@ -0,0 +1,56 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * ticket_type_id: "ticket_type_id", + * name: "Attribute Title", + * description: "Attribute Description", + * data_type: "string", + * required_to_create: false + * } + */ +export interface CreateTicketTypeAttributeRequest { + /** + * The unique identifier for the ticket type which is given by Intercom. + */ + ticket_type_id: string; + /** The name of the ticket type attribute */ + name: string; + /** The description of the attribute presented to the teammate or contact */ + description: string; + /** The data type of the attribute */ + data_type: CreateTicketTypeAttributeRequest.DataType; + /** Whether the attribute is required to be filled in when teammates are creating the ticket in Inbox. */ + required_to_create?: boolean; + /** Whether the attribute is required to be filled in when contacts are creating the ticket in Messenger. */ + required_to_create_for_contacts?: boolean; + /** Whether the attribute is visible to teammates when creating a ticket in Inbox. */ + visible_on_create?: boolean; + /** Whether the attribute is visible to contacts when creating a ticket in Messenger. */ + visible_to_contacts?: boolean; + /** Whether the attribute allows multiple lines of text (only applicable to string attributes) */ + multiline?: boolean; + /** A comma delimited list of items for the attribute value (only applicable to list attributes) */ + list_items?: string; + /** Whether the attribute allows multiple files to be attached to it (only applicable to file attributes) */ + allow_multiple_values?: boolean; +} + +export namespace CreateTicketTypeAttributeRequest { + /** + * The data type of the attribute + */ + export type DataType = "string" | "list" | "integer" | "decimal" | "boolean" | "datetime" | "files"; + export const DataType = { + String: "string", + List: "list", + Integer: "integer", + Decimal: "decimal", + Boolean: "boolean", + Datetime: "datetime", + Files: "files", + } as const; +} diff --git a/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/UpdateTicketTypeAttributeRequest.ts b/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/UpdateTicketTypeAttributeRequest.ts new file mode 100644 index 00000000..9575db2d --- /dev/null +++ b/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/UpdateTicketTypeAttributeRequest.ts @@ -0,0 +1,42 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * ticket_type_id: "ticket_type_id", + * id: "id", + * description: "New Attribute Description" + * } + */ +export interface UpdateTicketTypeAttributeRequest { + /** + * The unique identifier for the ticket type which is given by Intercom. + */ + ticket_type_id: string; + /** + * The unique identifier for the ticket type attribute which is given by Intercom. + */ + id: string; + /** The name of the ticket type attribute */ + name?: string; + /** The description of the attribute presented to the teammate or contact */ + description?: string; + /** Whether the attribute is required to be filled in when teammates are creating the ticket in Inbox. */ + required_to_create?: boolean; + /** Whether the attribute is required to be filled in when contacts are creating the ticket in Messenger. */ + required_to_create_for_contacts?: boolean; + /** Whether the attribute is visible to teammates when creating a ticket in Inbox. */ + visible_on_create?: boolean; + /** Whether the attribute is visible to contacts when creating a ticket in Messenger. */ + visible_to_contacts?: boolean; + /** Whether the attribute allows multiple lines of text (only applicable to string attributes) */ + multiline?: boolean; + /** A comma delimited list of items for the attribute value (only applicable to list attributes) */ + list_items?: string; + /** Whether the attribute allows multiple files to be attached to it (only applicable to file attributes) */ + allow_multiple_values?: boolean; + /** Whether the attribute should be archived and not shown during creation of the ticket (it will still be present on previously created tickets) */ + archived?: boolean; +} diff --git a/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/index.ts b/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/index.ts new file mode 100644 index 00000000..b2d37564 --- /dev/null +++ b/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/index.ts @@ -0,0 +1,2 @@ +export { type CreateTicketTypeAttributeRequest } from "./CreateTicketTypeAttributeRequest"; +export { type UpdateTicketTypeAttributeRequest } from "./UpdateTicketTypeAttributeRequest"; diff --git a/src/api/resources/unstable/resources/ticketTypeAttributes/index.ts b/src/api/resources/unstable/resources/ticketTypeAttributes/index.ts new file mode 100644 index 00000000..5ec76921 --- /dev/null +++ b/src/api/resources/unstable/resources/ticketTypeAttributes/index.ts @@ -0,0 +1 @@ +export * from "./client"; diff --git a/src/api/resources/unstable/resources/ticketTypes/client/Client.ts b/src/api/resources/unstable/resources/ticketTypes/client/Client.ts new file mode 100644 index 00000000..857fd1f7 --- /dev/null +++ b/src/api/resources/unstable/resources/ticketTypes/client/Client.ts @@ -0,0 +1,354 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace TicketTypes { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your ticket types + */ +export class TicketTypes { + constructor(protected readonly _options: TicketTypes.Options = {}) {} + + /** + * You can get a list of all ticket types for a workspace. + * + * @param {TicketTypes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.ticketTypes.listTicketTypes() + */ + public listTicketTypes( + requestOptions?: TicketTypes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listTicketTypes(requestOptions)); + } + + private async __listTicketTypes( + requestOptions?: TicketTypes.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ticket_types", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.TicketTypeList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ticket_types."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can create a new ticket type. + * > 📘 Creating ticket types. + * > + * > Every ticket type will be created with two default attributes: _default_title_ and _default_description_. + * > For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) + * + * @param {unknown} request + * @param {TicketTypes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.ticketTypes.createTicketType({ + * "key": "value" + * }) + */ + public createTicketType( + request?: unknown, + requestOptions?: TicketTypes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createTicketType(request, requestOptions)); + } + + private async __createTicketType( + request?: unknown, + requestOptions?: TicketTypes.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ticket_types", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.TicketType | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /ticket_types."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch the details of a single ticket type. + * + * @param {Intercom.unstable.GetTicketTypeRequest} request + * @param {TicketTypes.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.ticketTypes.getTicketType({ + * id: "id" + * }) + */ + public getTicketType( + request: Intercom.unstable.GetTicketTypeRequest, + requestOptions?: TicketTypes.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__getTicketType(request, requestOptions)); + } + + private async __getTicketType( + request: Intercom.unstable.GetTicketTypeRequest, + requestOptions?: TicketTypes.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ticket_types/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.TicketType | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ticket_types/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/ticketTypes/client/index.ts b/src/api/resources/unstable/resources/ticketTypes/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/ticketTypes/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/ticketTypes/client/requests/GetTicketTypeRequest.ts b/src/api/resources/unstable/resources/ticketTypes/client/requests/GetTicketTypeRequest.ts new file mode 100644 index 00000000..b9868adc --- /dev/null +++ b/src/api/resources/unstable/resources/ticketTypes/client/requests/GetTicketTypeRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "id" + * } + */ +export interface GetTicketTypeRequest { + /** + * The unique identifier for the ticket type which is given by Intercom. + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/ticketTypes/client/requests/index.ts b/src/api/resources/unstable/resources/ticketTypes/client/requests/index.ts new file mode 100644 index 00000000..c25063a7 --- /dev/null +++ b/src/api/resources/unstable/resources/ticketTypes/client/requests/index.ts @@ -0,0 +1 @@ +export { type GetTicketTypeRequest } from "./GetTicketTypeRequest"; diff --git a/src/api/resources/unstable/resources/ticketTypes/index.ts b/src/api/resources/unstable/resources/ticketTypes/index.ts new file mode 100644 index 00000000..5ec76921 --- /dev/null +++ b/src/api/resources/unstable/resources/ticketTypes/index.ts @@ -0,0 +1 @@ +export * from "./client"; diff --git a/src/api/resources/unstable/resources/tickets/client/Client.ts b/src/api/resources/unstable/resources/tickets/client/Client.ts new file mode 100644 index 00000000..116eed02 --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/client/Client.ts @@ -0,0 +1,770 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Tickets { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your tickets + */ +export class Tickets { + constructor(protected readonly _options: Tickets.Options = {}) {} + + /** + * You can reply to a ticket with a message from an admin or on behalf of a contact, or with a note for admins. + * + * @param {Intercom.unstable.ReplyTicketRequest} request + * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.tickets.replyTicket({ + * id: "123", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "6762f2971bb69f9f2193bc49" + * } + * }) + * + * @example + * await client.unstable.tickets.replyTicket({ + * id: "123", + * body: { + * message_type: "note", + * type: "admin", + * body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + * admin_id: "3156780" + * } + * }) + * + * @example + * await client.unstable.tickets.replyTicket({ + * id: "123", + * body: { + * message_type: "quick_reply", + * type: "admin", + * admin_id: "3156780", + * reply_options: [{ + * text: "Yes", + * uuid: "0df48b85-9a93-4c66-a167-753eff0baaec" + * }, { + * text: "No", + * uuid: "4f0b5145-4193-4b4f-8cad-ce19478a3938" + * }] + * } + * }) + * + * @example + * await client.unstable.tickets.replyTicket({ + * id: "123", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "6762f2a41bb69f9f2193bc4c" + * } + * }) + */ + public replyTicket( + request: Intercom.unstable.ReplyTicketRequest, + requestOptions?: Tickets.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__replyTicket(request, requestOptions)); + } + + private async __replyTicket( + request: Intercom.unstable.ReplyTicketRequest, + requestOptions?: Tickets.RequestOptions, + ): Promise> { + const { id, body: _body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(id)}/reply`, + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.TicketReply, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/{id}/reply."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Enqueues ticket creation for asynchronous processing, returning if the job was enqueued successfully to be processed. We attempt to perform a best-effort validation on inputs before tasks are enqueued. If the given parameters are incorrect, we won't enqueue the job. + * + * @param {Intercom.unstable.EnqueueCreateTicketRequest} request + * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.tickets.enqueueCreateTicket({ + * ticket_type_id: "1234", + * contacts: [{ + * id: "6762f2d81bb69f9f2193bc54" + * }] + * }) + */ + public enqueueCreateTicket( + request: Intercom.unstable.EnqueueCreateTicketRequest, + requestOptions?: Tickets.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__enqueueCreateTicket(request, requestOptions)); + } + + private async __enqueueCreateTicket( + request: Intercom.unstable.EnqueueCreateTicketRequest, + requestOptions?: Tickets.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "tickets/enqueue", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Jobs, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/enqueue."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can fetch the details of a single ticket. + * + * @param {Intercom.unstable.GetTicketRequest} request + * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.tickets.getTicket({ + * id: "id" + * }) + */ + public getTicket( + request: Intercom.unstable.GetTicketRequest, + requestOptions?: Tickets.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__getTicket(request, requestOptions)); + } + + private async __getTicket( + request: Intercom.unstable.GetTicketRequest, + requestOptions?: Tickets.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(id)}`, + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Ticket | undefined, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tickets/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can update a ticket. + * + * @param {Intercom.unstable.UpdateTicketRequest} request + * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.tickets.updateTicket({ + * id: "id", + * ticket_attributes: { + * "_default_title_": "example", + * "_default_description_": "there is a problem" + * }, + * ticket_state_id: "123", + * open: true, + * snoozed_until: 1673609604, + * admin_id: 991268011, + * assignee_id: "123" + * }) + * + * @example + * await client.unstable.tickets.updateTicket({ + * id: "id", + * ticket_attributes: { + * "_default_title_": "example", + * "_default_description_": "there is a problem" + * }, + * ticket_state_id: "123", + * admin_id: 991268011, + * assignee_id: "123" + * }) + * + * @example + * await client.unstable.tickets.updateTicket({ + * id: "id", + * ticket_state_id: "123" + * }) + */ + public updateTicket( + request: Intercom.unstable.UpdateTicketRequest, + requestOptions?: Tickets.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateTicket(request, requestOptions)); + } + + private async __updateTicket( + request: Intercom.unstable.UpdateTicketRequest, + requestOptions?: Tickets.RequestOptions, + ): Promise> { + const { id, ..._body } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(id)}`, + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: _body, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Ticket | undefined, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /tickets/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can delete a ticket using the Intercom provided ID. + * + * @param {Intercom.unstable.DeleteTicketRequest} request + * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.tickets.deleteTicket({ + * id: "id" + * }) + */ + public deleteTicket( + request: Intercom.unstable.DeleteTicketRequest, + requestOptions?: Tickets.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteTicket(request, requestOptions)); + } + + private async __deleteTicket( + request: Intercom.unstable.DeleteTicketRequest, + requestOptions?: Tickets.RequestOptions, + ): Promise> { + const { id } = request; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tickets/${encodeURIComponent(id)}`, + ), + method: "DELETE", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.DeleteTicketResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /tickets/{id}."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can search for multiple tickets by the value of their attributes in order to fetch exactly which ones you want. + * + * To search for tickets, you send a `POST` request to `https://api.intercom.io/tickets/search`. + * + * This will accept a query object in the body which will define your filters. + * {% admonition type="warning" name="Optimizing search queries" %} + * Search queries can be complex, so optimizing them can help the performance of your search. + * Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize + * pagination to limit the number of results returned. The default is `20` results per page. + * See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. + * {% /admonition %} + * + * ### Nesting & Limitations + * + * You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). + * There are some limitations to the amount of multiples there can be: + * - There's a limit of max 2 nested filters + * - There's a limit of max 15 filters for each AND or OR group + * + * ### Accepted Fields + * + * Most keys listed as part of the Ticket model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foobar"`). + * The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. + * + * | Field | Type | + * | :---------------------------------------- | :--------------------------------------------------------------------------------------- | + * | id | String | + * | created_at | Date (UNIX timestamp) | + * | updated_at | Date (UNIX timestamp) | + * | _default_title_ | String | + * | _default_description_ | String | + * | category | String | + * | ticket_type_id | String | + * | contact_ids | String | + * | teammate_ids | String | + * | admin_assignee_id | String | + * | team_assignee_id | String | + * | open | Boolean | + * | state | String | + * | snoozed_until | Date (UNIX timestamp) | + * | ticket_attribute.{id} | String or Boolean or Date (UNIX timestamp) or Float or Integer | + * + * ### Accepted Operators + * + * {% admonition type="info" name="Searching based on `created_at`" %} + * You may use the `<=` or `>=` operators to search by `created_at`. + * {% /admonition %} + * + * The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + * + * | Operator | Valid Types | Description | + * | :------- | :----------------------------- | :----------------------------------------------------------- | + * | = | All | Equals | + * | != | All | Doesn't Equal | + * | IN | All | In Shortcut for `OR` queries Values most be in Array | + * | NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | + * | > | Integer Date (UNIX Timestamp) | Greater (or equal) than | + * | < | Integer Date (UNIX Timestamp) | Lower (or equal) than | + * | ~ | String | Contains | + * | !~ | String | Doesn't Contain | + * | ^ | String | Starts With | + * | $ | String | Ends With | + * + * @param {Intercom.unstable.SearchRequest} request + * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.unstable.tickets.searchTickets({ + * query: { + * operator: "AND", + * value: [{ + * field: "created_at", + * operator: ">", + * value: "1306054154" + * }] + * }, + * pagination: { + * per_page: 5 + * } + * }) + */ + public searchTickets( + request: Intercom.unstable.SearchRequest, + requestOptions?: Tickets.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__searchTickets(request, requestOptions)); + } + + private async __searchTickets( + request: Intercom.unstable.SearchRequest, + requestOptions?: Tickets.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "tickets/search", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.TicketList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/search."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/tickets/client/index.ts b/src/api/resources/unstable/resources/tickets/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/tickets/client/requests/DeleteTicketRequest.ts b/src/api/resources/unstable/resources/tickets/client/requests/DeleteTicketRequest.ts new file mode 100644 index 00000000..3a9f96f8 --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/client/requests/DeleteTicketRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "id" + * } + */ +export interface DeleteTicketRequest { + /** + * The unique identifier for the ticket which is given by Intercom. + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/tickets/client/requests/EnqueueCreateTicketRequest.ts b/src/api/resources/unstable/resources/tickets/client/requests/EnqueueCreateTicketRequest.ts new file mode 100644 index 00000000..d1d3b5ee --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/client/requests/EnqueueCreateTicketRequest.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * ticket_type_id: "1234", + * contacts: [{ + * id: "6762f2d81bb69f9f2193bc54" + * }] + * } + */ +export interface EnqueueCreateTicketRequest extends Intercom.unstable.CreateTicketRequestBody { + /** Option to disable notifications when a Ticket is created. */ + skip_notifications?: boolean; +} diff --git a/src/api/resources/unstable/resources/tickets/client/requests/GetTicketRequest.ts b/src/api/resources/unstable/resources/tickets/client/requests/GetTicketRequest.ts new file mode 100644 index 00000000..ea0795f8 --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/client/requests/GetTicketRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "id" + * } + */ +export interface GetTicketRequest { + /** + * The unique identifier for the ticket which is given by Intercom. + */ + id: string; +} diff --git a/src/api/resources/unstable/resources/tickets/client/requests/ReplyTicketRequest.ts b/src/api/resources/unstable/resources/tickets/client/requests/ReplyTicketRequest.ts new file mode 100644 index 00000000..ae8e6378 --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/client/requests/ReplyTicketRequest.ts @@ -0,0 +1,61 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../../index"; + +/** + * @example + * { + * id: "123", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "6762f2971bb69f9f2193bc49" + * } + * } + * + * @example + * { + * id: "123", + * body: { + * message_type: "note", + * type: "admin", + * body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + * admin_id: "3156780" + * } + * } + * + * @example + * { + * id: "123", + * body: { + * message_type: "quick_reply", + * type: "admin", + * admin_id: "3156780", + * reply_options: [{ + * text: "Yes", + * uuid: "0df48b85-9a93-4c66-a167-753eff0baaec" + * }, { + * text: "No", + * uuid: "4f0b5145-4193-4b4f-8cad-ce19478a3938" + * }] + * } + * } + * + * @example + * { + * id: "123", + * body: { + * message_type: "comment", + * type: "user", + * body: "Thanks again :)", + * intercom_user_id: "6762f2a41bb69f9f2193bc4c" + * } + * } + */ +export interface ReplyTicketRequest { + id: string; + body: Intercom.unstable.ReplyTicketRequestBody; +} diff --git a/src/api/resources/unstable/resources/tickets/client/requests/UpdateTicketRequest.ts b/src/api/resources/unstable/resources/tickets/client/requests/UpdateTicketRequest.ts new file mode 100644 index 00000000..28c7e40f --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/client/requests/UpdateTicketRequest.ts @@ -0,0 +1,71 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * id: "id", + * ticket_attributes: { + * "_default_title_": "example", + * "_default_description_": "there is a problem" + * }, + * ticket_state_id: "123", + * open: true, + * snoozed_until: 1673609604, + * admin_id: 991268011, + * assignee_id: "123" + * } + * + * @example + * { + * id: "id", + * ticket_attributes: { + * "_default_title_": "example", + * "_default_description_": "there is a problem" + * }, + * ticket_state_id: "123", + * admin_id: 991268011, + * assignee_id: "123" + * } + * + * @example + * { + * id: "id", + * ticket_attributes: { + * "_default_title_": "example", + * "_default_description_": "there is a problem" + * }, + * ticket_state_id: "123", + * admin_id: 991268011, + * assignee_id: "123" + * } + * + * @example + * { + * id: "id", + * ticket_state_id: "123" + * } + */ +export interface UpdateTicketRequest { + /** + * The unique identifier for the ticket which is given by Intercom + */ + id: string; + /** The attributes set on the ticket. */ + ticket_attributes?: Record; + /** The ID of the ticket state associated with the ticket type. */ + ticket_state_id?: string; + /** The ID of the company that the ticket is associated with. The unique identifier for the company which is given by Intercom. Set to nil to remove company. */ + company_id?: string; + /** Specify if a ticket is open. Set to false to close a ticket. Closing a ticket will also unsnooze it. */ + open?: boolean; + /** Specify whether the ticket is visible to users. */ + is_shared?: boolean; + /** The time you want the ticket to reopen. */ + snoozed_until?: number; + /** The ID of the admin performing ticket update. Needed for workflows execution and attributing actions to specific admins. */ + admin_id?: number; + /** The ID of the admin or team to which the ticket is assigned. Set this 0 to unassign it. */ + assignee_id?: string; +} diff --git a/src/api/resources/unstable/resources/tickets/client/requests/index.ts b/src/api/resources/unstable/resources/tickets/client/requests/index.ts new file mode 100644 index 00000000..b6a892f9 --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/client/requests/index.ts @@ -0,0 +1,5 @@ +export { type ReplyTicketRequest } from "./ReplyTicketRequest"; +export { type EnqueueCreateTicketRequest } from "./EnqueueCreateTicketRequest"; +export { type GetTicketRequest } from "./GetTicketRequest"; +export { type UpdateTicketRequest } from "./UpdateTicketRequest"; +export { type DeleteTicketRequest } from "./DeleteTicketRequest"; diff --git a/src/api/resources/unstable/resources/tickets/index.ts b/src/api/resources/unstable/resources/tickets/index.ts new file mode 100644 index 00000000..c9240f83 --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/src/api/resources/unstable/resources/tickets/types/DeleteTicketResponse.ts b/src/api/resources/unstable/resources/tickets/types/DeleteTicketResponse.ts new file mode 100644 index 00000000..579725c6 --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/types/DeleteTicketResponse.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Response when a ticket is deleted. + */ +export interface DeleteTicketResponse { + /** The unique identifier for the ticket. */ + id?: string; + /** always ticket */ + object?: "ticket"; + /** Whether the ticket is deleted or not. */ + deleted?: boolean; +} diff --git a/src/api/resources/unstable/resources/tickets/types/ReplyTicketRequestBody.ts b/src/api/resources/unstable/resources/tickets/types/ReplyTicketRequestBody.ts new file mode 100644 index 00000000..3f2ede0c --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/types/ReplyTicketRequestBody.ts @@ -0,0 +1,9 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +export type ReplyTicketRequestBody = + | Intercom.unstable.ContactReplyTicketRequest + | Intercom.unstable.AdminReplyTicketRequest; diff --git a/src/api/resources/unstable/resources/tickets/types/Ticket.ts b/src/api/resources/unstable/resources/tickets/types/Ticket.ts new file mode 100644 index 00000000..45defe9b --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/types/Ticket.ts @@ -0,0 +1,51 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * Tickets are how you track requests from your users. + */ +export interface Ticket { + /** Always ticket */ + type?: "ticket"; + /** The unique identifier for the ticket which is given by Intercom. */ + id?: string; + /** The ID of the Ticket used in the Intercom Inbox and Messenger. Do not use ticket_id for API queries. */ + ticket_id?: string; + /** Category of the Ticket. */ + category?: Ticket.Category; + ticket_attributes?: Intercom.unstable.TicketCustomAttributes; + ticket_state?: Intercom.unstable.TicketState; + ticket_type?: Intercom.unstable.TicketType; + contacts?: Intercom.unstable.TicketContacts; + /** The id representing the admin assigned to the ticket. */ + admin_assignee_id?: string; + /** The id representing the team assigned to the ticket. */ + team_assignee_id?: string; + /** The time the ticket was created as a UTC Unix timestamp. */ + created_at?: number; + /** The last time the ticket was updated as a UTC Unix timestamp. */ + updated_at?: number; + /** Whether or not the ticket is open. If false, the ticket is closed. */ + open?: boolean; + /** The time the ticket will be snoozed until as a UTC Unix timestamp. If null, the ticket is not currently snoozed. */ + snoozed_until?: number; + linked_objects?: Intercom.unstable.LinkedObjectList; + ticket_parts?: Intercom.unstable.TicketParts; + /** Whether or not the ticket is shared with the customer. */ + is_shared?: boolean; +} + +export namespace Ticket { + /** + * Category of the Ticket. + */ + export type Category = "Customer" | "Back-office" | "Tracker"; + export const Category = { + Customer: "Customer", + BackOffice: "Back-office", + Tracker: "Tracker", + } as const; +} diff --git a/src/api/resources/unstable/resources/tickets/types/TicketContacts.ts b/src/api/resources/unstable/resources/tickets/types/TicketContacts.ts new file mode 100644 index 00000000..e025dd66 --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/types/TicketContacts.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * The list of contacts affected by a ticket. + */ +export interface TicketContacts { + /** always contact.list */ + type?: "contact.list"; + /** The list of contacts affected by this ticket. */ + contacts?: Intercom.unstable.ContactReference[]; +} diff --git a/src/api/resources/unstable/resources/tickets/types/TicketPart.ts b/src/api/resources/unstable/resources/tickets/types/TicketPart.ts new file mode 100644 index 00000000..9153bf31 --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/types/TicketPart.ts @@ -0,0 +1,115 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * A Ticket Part represents a message in the ticket. + */ +export interface TicketPart { + /** Always ticket_part */ + type?: string; + /** The id representing the ticket part. */ + id?: string; + /** The type of ticket part. */ + part_type?: string; + /** The message body, which may contain HTML. */ + body?: string; + /** The previous state of the ticket. */ + previous_ticket_state?: TicketPart.PreviousTicketState; + /** The state of the ticket. */ + ticket_state?: TicketPart.TicketState; + /** The time the ticket part was created. */ + created_at?: number; + /** The last time the ticket part was updated. */ + updated_at?: number; + /** The id of the admin that was assigned the ticket by this ticket_part (null if there has been no change in assignment.) */ + assigned_to?: Intercom.unstable.Reference; + author?: Intercom.unstable.TicketPartAuthor; + /** A list of attachments for the part. */ + attachments?: Intercom.unstable.PartAttachment[]; + /** The external id of the ticket part */ + external_id?: string; + /** Whether or not the ticket part has been redacted. */ + redacted?: boolean; + /** The app package code if this part was created via API. Note this field won't show if the part was not created via API. */ + app_package_code?: string; + /** The updated attribute data of the ticket part. Only present for attribute update parts. */ + updated_attribute_data?: TicketPart.UpdatedAttributeData; +} + +export namespace TicketPart { + /** + * The previous state of the ticket. + */ + export type PreviousTicketState = "submitted" | "in_progress" | "waiting_on_customer" | "resolved"; + export const PreviousTicketState = { + Submitted: "submitted", + InProgress: "in_progress", + WaitingOnCustomer: "waiting_on_customer", + Resolved: "resolved", + } as const; + /** + * The state of the ticket. + */ + export type TicketState = "submitted" | "in_progress" | "waiting_on_customer" | "resolved"; + export const TicketState = { + Submitted: "submitted", + InProgress: "in_progress", + WaitingOnCustomer: "waiting_on_customer", + Resolved: "resolved", + } as const; + + /** + * The updated attribute data of the ticket part. Only present for attribute update parts. + */ + export interface UpdatedAttributeData { + /** Information about the attribute that was updated. */ + attribute: UpdatedAttributeData.Attribute; + /** The new value of the attribute. */ + value: UpdatedAttributeData.Value; + } + + export namespace UpdatedAttributeData { + /** + * Information about the attribute that was updated. + */ + export interface Attribute { + /** The type of the object. Always 'attribute'. */ + type: "attribute"; + /** The unique identifier of the attribute. */ + id: string; + /** The human-readable name of the attribute. */ + label: string; + } + + /** + * The new value of the attribute. + */ + export interface Value { + /** The type of the object. Always 'value'. */ + type: "value"; + id: Value.Id; + label: Value.Label; + } + + export namespace Value { + export type Id = + /** + * The value for text/number/decimal/boolean/date attributes, or the ID of the list option for list attributes. */ + | string + | undefined + /** + * Array of file IDs for file attributes. */ + | number[]; + export type Label = + /** + * The display value for text/number/decimal/boolean/date/list attributes. */ + | string + /** + * Array of file names for file attributes. */ + | string[]; + } + } +} diff --git a/src/api/resources/unstable/resources/tickets/types/TicketState.ts b/src/api/resources/unstable/resources/tickets/types/TicketState.ts new file mode 100644 index 00000000..70427191 --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/types/TicketState.ts @@ -0,0 +1,32 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A ticket state, used to define the state of a ticket. + */ +export interface TicketState { + /** String representing the object's type. Always has the value `ticket_state`. */ + type?: string; + /** The id of the ticket state */ + id?: string; + /** The category of the ticket state */ + category?: TicketState.Category; + /** The state the ticket is currently in, in a human readable form - visible in Intercom */ + internal_label?: string; + /** The state the ticket is currently in, in a human readable form - visible to customers, in the messenger, email and tickets portal. */ + external_label?: string; +} + +export namespace TicketState { + /** + * The category of the ticket state + */ + export type Category = "submitted" | "in_progress" | "waiting_on_customer" | "resolved"; + export const Category = { + Submitted: "submitted", + InProgress: "in_progress", + WaitingOnCustomer: "waiting_on_customer", + Resolved: "resolved", + } as const; +} diff --git a/src/api/resources/unstable/resources/tickets/types/TicketStateDetailed.ts b/src/api/resources/unstable/resources/tickets/types/TicketStateDetailed.ts new file mode 100644 index 00000000..2502a84b --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/types/TicketStateDetailed.ts @@ -0,0 +1,48 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * A ticket state, used to define the state of a ticket. + */ +export interface TicketStateDetailed { + /** String representing the object's type. Always has the value `ticket_state`. */ + type?: string; + /** The id of the ticket state */ + id?: string; + /** The category of the ticket state */ + category?: TicketStateDetailed.Category; + /** The state the ticket is currently in, in a human readable form - visible in Intercom */ + internal_label?: string; + /** The state the ticket is currently in, in a human readable form - visible to customers, in the messenger, email and tickets portal. */ + external_label?: string; + /** Whether the ticket state is archived */ + archived?: boolean; + /** A list of ticket types associated with a given ticket state. */ + ticket_types?: TicketStateDetailed.TicketTypes; +} + +export namespace TicketStateDetailed { + /** + * The category of the ticket state + */ + export type Category = "submitted" | "in_progress" | "waiting_on_customer" | "resolved"; + export const Category = { + Submitted: "submitted", + InProgress: "in_progress", + WaitingOnCustomer: "waiting_on_customer", + Resolved: "resolved", + } as const; + + /** + * A list of ticket types associated with a given ticket state. + */ + export interface TicketTypes { + /** String representing the object's type. Always has the value `list`. */ + type?: string; + /** A list of ticket type attributes associated with a given ticket type. */ + data?: (Intercom.unstable.TicketType | undefined)[]; + } +} diff --git a/src/api/resources/unstable/resources/tickets/types/TicketType.ts b/src/api/resources/unstable/resources/tickets/types/TicketType.ts new file mode 100644 index 00000000..3af90517 --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/types/TicketType.ts @@ -0,0 +1,56 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../../../index"; + +/** + * A ticket type, used to define the data fields to be captured in a ticket. + */ +export interface TicketType { + /** String representing the object's type. Always has the value `ticket_type`. */ + type?: string; + /** The id representing the ticket type. */ + id?: string; + /** Category of the Ticket Type. */ + category?: TicketType.Category; + /** The name of the ticket type */ + name?: string; + /** The description of the ticket type */ + description?: string; + /** The icon of the ticket type */ + icon?: string; + /** The id of the workspace that the ticket type belongs to. */ + workspace_id?: string; + ticket_type_attributes?: Intercom.unstable.TicketTypeAttributeList; + /** A list of ticket states associated with a given ticket type. */ + ticket_states?: TicketType.TicketStates; + /** Whether the ticket type is archived or not. */ + archived?: boolean; + /** The date and time the ticket type was created. */ + created_at?: number; + /** The date and time the ticket type was last updated. */ + updated_at?: number; +} + +export namespace TicketType { + /** + * Category of the Ticket Type. + */ + export type Category = "Customer" | "Back-office" | "Tracker"; + export const Category = { + Customer: "Customer", + BackOffice: "Back-office", + Tracker: "Tracker", + } as const; + + /** + * A list of ticket states associated with a given ticket type. + */ + export interface TicketStates { + /** String representing the object's type. Always has the value `list`. */ + type?: string; + /** A list of ticket states associated with a given ticket type. */ + data?: (Intercom.unstable.TicketState | undefined)[]; + } +} diff --git a/src/api/resources/unstable/resources/tickets/types/index.ts b/src/api/resources/unstable/resources/tickets/types/index.ts new file mode 100644 index 00000000..5c6f7a46 --- /dev/null +++ b/src/api/resources/unstable/resources/tickets/types/index.ts @@ -0,0 +1,8 @@ +export * from "./ReplyTicketRequestBody"; +export * from "./DeleteTicketResponse"; +export * from "./Ticket"; +export * from "./TicketContacts"; +export * from "./TicketPart"; +export * from "./TicketState"; +export * from "./TicketStateDetailed"; +export * from "./TicketType"; diff --git a/src/api/resources/unstable/resources/visitors/client/Client.ts b/src/api/resources/unstable/resources/visitors/client/Client.ts new file mode 100644 index 00000000..ef6e2e8a --- /dev/null +++ b/src/api/resources/unstable/resources/visitors/client/Client.ts @@ -0,0 +1,386 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as environments from "../../../../../../environments"; +import * as core from "../../../../../../core"; +import * as Intercom from "../../../../../index"; +import urlJoin from "url-join"; +import * as errors from "../../../../../../errors/index"; + +export declare namespace Visitors { + export interface Options { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + fetcher?: core.FetchFunction; + } + + export interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; + } +} + +/** + * Everything about your Visitors + */ +export class Visitors { + constructor(protected readonly _options: Visitors.Options = {}) {} + + /** + * You can fetch the details of a single visitor. + * + * @param {Intercom.unstable.RetrieveVisitorWithUserIdRequest} request + * @param {Visitors.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.visitors.retrieveVisitorWithUserId({ + * user_id: "user_id" + * }) + */ + public retrieveVisitorWithUserId( + request: Intercom.unstable.RetrieveVisitorWithUserIdRequest, + requestOptions?: Visitors.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveVisitorWithUserId(request, requestOptions)); + } + + private async __retrieveVisitorWithUserId( + request: Intercom.unstable.RetrieveVisitorWithUserIdRequest, + requestOptions?: Visitors.RequestOptions, + ): Promise> { + const { user_id: userId } = request; + const _queryParams: Record = {}; + _queryParams["user_id"] = userId; + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "visitors", + ), + method: "GET", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + queryParameters: _queryParams, + requestType: "json", + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.Visitor | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /visitors."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * Sending a PUT request to `/visitors` will result in an update of an existing Visitor. + * + * **Option 1.** You can update a visitor by passing in the `user_id` of the visitor in the Request body. + * + * **Option 2.** You can update a visitor by passing in the `id` of the visitor in the Request body. + * + * @param {Intercom.UpdateVisitorRequestOne} request + * @param {Visitors.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.visitors.updateVisitor({ + * "id": "6762f30c1bb69f9f2193bc5e", + * "name": "Gareth Bale" + * }) + * + * @example + * await client.unstable.visitors.updateVisitor({ + * "user_id": "fail", + * "name": "Christian Fail" + * }) + */ + public updateVisitor( + request?: Intercom.UpdateVisitorRequestOne, + requestOptions?: Visitors.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateVisitor(request, requestOptions)); + } + + private async __updateVisitor( + request?: Intercom.UpdateVisitorRequestOne, + requestOptions?: Visitors.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "visitors", + ), + method: "PUT", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.Visitor | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /visitors."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + /** + * You can merge a Visitor to a Contact of role type `lead` or `user`. + * + * > 📘 What happens upon a visitor being converted? + * > + * > If the User exists, then the Visitor will be merged into it, the Visitor deleted and the User returned. If the User does not exist, the Visitor will be converted to a User, with the User identifiers replacing it's Visitor identifiers. + * + * @param {Intercom.unstable.ConvertVisitorRequest} request + * @param {Visitors.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.visitors.convertVisitor({ + * type: "user", + * user: { + * "email": "foo@bar.com" + * }, + * visitor: { + * "user_id": "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3" + * } + * }) + */ + public convertVisitor( + request: Intercom.unstable.ConvertVisitorRequest, + requestOptions?: Visitors.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__convertVisitor(request, requestOptions)); + } + + private async __convertVisitor( + request: Intercom.unstable.ConvertVisitorRequest, + requestOptions?: Visitors.RequestOptions, + ): Promise> { + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: urlJoin( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "visitors/convert", + ), + method: "POST", + headers: { + Authorization: await this._getAuthorizationHeader(), + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", + "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Contact, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + rawResponse: _response.rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /visitors/convert."); + case "unknown": + throw new errors.IntercomError({ + message: _response.error.errorMessage, + rawResponse: _response.rawResponse, + }); + } + } + + protected async _getAuthorizationHeader(): Promise { + const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; + if (bearer == null) { + throw new errors.IntercomError({ + message: + "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return `Bearer ${bearer}`; + } +} diff --git a/src/api/resources/unstable/resources/visitors/client/index.ts b/src/api/resources/unstable/resources/visitors/client/index.ts new file mode 100644 index 00000000..415726b7 --- /dev/null +++ b/src/api/resources/unstable/resources/visitors/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/src/api/resources/unstable/resources/visitors/client/requests/ConvertVisitorRequest.ts b/src/api/resources/unstable/resources/visitors/client/requests/ConvertVisitorRequest.ts new file mode 100644 index 00000000..275e76e7 --- /dev/null +++ b/src/api/resources/unstable/resources/visitors/client/requests/ConvertVisitorRequest.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * type: "user", + * user: { + * "email": "foo@bar.com" + * }, + * visitor: { + * "user_id": "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3" + * } + * } + */ +export interface ConvertVisitorRequest { + /** Represents the role of the Contact model. Accepts `lead` or `user`. */ + type: string; + user?: unknown; + visitor?: unknown; +} diff --git a/src/api/resources/unstable/resources/visitors/client/requests/RetrieveVisitorWithUserIdRequest.ts b/src/api/resources/unstable/resources/visitors/client/requests/RetrieveVisitorWithUserIdRequest.ts new file mode 100644 index 00000000..27554599 --- /dev/null +++ b/src/api/resources/unstable/resources/visitors/client/requests/RetrieveVisitorWithUserIdRequest.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * user_id: "user_id" + * } + */ +export interface RetrieveVisitorWithUserIdRequest { + /** + * The user_id of the Visitor you want to retrieve. + */ + user_id: string; +} diff --git a/src/api/resources/unstable/resources/visitors/client/requests/index.ts b/src/api/resources/unstable/resources/visitors/client/requests/index.ts new file mode 100644 index 00000000..8878667c --- /dev/null +++ b/src/api/resources/unstable/resources/visitors/client/requests/index.ts @@ -0,0 +1,2 @@ +export { type RetrieveVisitorWithUserIdRequest } from "./RetrieveVisitorWithUserIdRequest"; +export { type ConvertVisitorRequest } from "./ConvertVisitorRequest"; diff --git a/src/api/resources/unstable/resources/visitors/index.ts b/src/api/resources/unstable/resources/visitors/index.ts new file mode 100644 index 00000000..5ec76921 --- /dev/null +++ b/src/api/resources/unstable/resources/visitors/index.ts @@ -0,0 +1 @@ +export * from "./client"; diff --git a/src/api/resources/unstable/types/ActivityLog.ts b/src/api/resources/unstable/types/ActivityLog.ts new file mode 100644 index 00000000..1815ce24 --- /dev/null +++ b/src/api/resources/unstable/types/ActivityLog.ts @@ -0,0 +1,175 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Activities performed by Admins. + */ +export interface ActivityLog { + /** The id representing the activity. */ + id?: string; + /** Details about the Admin involved in the activity. */ + performed_by?: ActivityLog.PerformedBy; + metadata?: Intercom.unstable.ActivityLogMetadata; + /** The time the activity was created. */ + created_at?: number; + activity_type?: ActivityLog.ActivityType; + /** A sentence or two describing the activity. */ + activity_description?: string; +} + +export namespace ActivityLog { + /** + * Details about the Admin involved in the activity. + */ + export interface PerformedBy { + /** String representing the object's type. Always has the value `admin`. */ + type?: string; + /** The id representing the admin. */ + id?: string; + /** The email of the admin. */ + email?: string; + /** The IP address of the admin. */ + ip?: string; + } + + export type ActivityType = + | "admin_assignment_limit_change" + | "admin_away_mode_change" + | "admin_deletion" + | "admin_deprovisioned" + | "admin_impersonation_end" + | "admin_impersonation_start" + | "admin_invite_change" + | "admin_invite_creation" + | "admin_invite_deletion" + | "admin_login_failure" + | "admin_login_success" + | "admin_logout" + | "admin_password_reset_request" + | "admin_password_reset_success" + | "admin_permission_change" + | "admin_provisioned" + | "admin_two_factor_auth_change" + | "admin_unauthorized_sign_in_method" + | "app_admin_join" + | "app_authentication_method_change" + | "app_data_deletion" + | "app_data_export" + | "app_google_sso_domain_change" + | "app_identity_verification_change" + | "app_name_change" + | "app_outbound_address_change" + | "app_package_installation" + | "app_package_token_regeneration" + | "app_package_uninstallation" + | "app_team_creation" + | "app_team_deletion" + | "app_team_membership_modification" + | "app_timezone_change" + | "app_webhook_creation" + | "app_webhook_deletion" + | "articles_in_messenger_enabled_change" + | "bulk_delete" + | "bulk_export" + | "campaign_deletion" + | "campaign_state_change" + | "conversation_part_deletion" + | "conversation_topic_change" + | "conversation_topic_creation" + | "conversation_topic_deletion" + | "help_center_settings_change" + | "inbound_conversations_change" + | "inbox_access_change" + | "message_deletion" + | "message_state_change" + | "messenger_look_and_feel_change" + | "messenger_search_required_change" + | "messenger_spaces_change" + | "office_hours_change" + | "role_change" + | "role_creation" + | "role_deletion" + | "ruleset_activation_title_preview" + | "ruleset_creation" + | "ruleset_deletion" + | "search_browse_enabled_change" + | "search_browse_required_change" + | "seat_change" + | "seat_revoke" + | "security_settings_change" + | "temporary_expectation_change" + | "upfront_email_collection_change" + | "welcome_message_change"; + export const ActivityType = { + AdminAssignmentLimitChange: "admin_assignment_limit_change", + AdminAwayModeChange: "admin_away_mode_change", + AdminDeletion: "admin_deletion", + AdminDeprovisioned: "admin_deprovisioned", + AdminImpersonationEnd: "admin_impersonation_end", + AdminImpersonationStart: "admin_impersonation_start", + AdminInviteChange: "admin_invite_change", + AdminInviteCreation: "admin_invite_creation", + AdminInviteDeletion: "admin_invite_deletion", + AdminLoginFailure: "admin_login_failure", + AdminLoginSuccess: "admin_login_success", + AdminLogout: "admin_logout", + AdminPasswordResetRequest: "admin_password_reset_request", + AdminPasswordResetSuccess: "admin_password_reset_success", + AdminPermissionChange: "admin_permission_change", + AdminProvisioned: "admin_provisioned", + AdminTwoFactorAuthChange: "admin_two_factor_auth_change", + AdminUnauthorizedSignInMethod: "admin_unauthorized_sign_in_method", + AppAdminJoin: "app_admin_join", + AppAuthenticationMethodChange: "app_authentication_method_change", + AppDataDeletion: "app_data_deletion", + AppDataExport: "app_data_export", + AppGoogleSsoDomainChange: "app_google_sso_domain_change", + AppIdentityVerificationChange: "app_identity_verification_change", + AppNameChange: "app_name_change", + AppOutboundAddressChange: "app_outbound_address_change", + AppPackageInstallation: "app_package_installation", + AppPackageTokenRegeneration: "app_package_token_regeneration", + AppPackageUninstallation: "app_package_uninstallation", + AppTeamCreation: "app_team_creation", + AppTeamDeletion: "app_team_deletion", + AppTeamMembershipModification: "app_team_membership_modification", + AppTimezoneChange: "app_timezone_change", + AppWebhookCreation: "app_webhook_creation", + AppWebhookDeletion: "app_webhook_deletion", + ArticlesInMessengerEnabledChange: "articles_in_messenger_enabled_change", + BulkDelete: "bulk_delete", + BulkExport: "bulk_export", + CampaignDeletion: "campaign_deletion", + CampaignStateChange: "campaign_state_change", + ConversationPartDeletion: "conversation_part_deletion", + ConversationTopicChange: "conversation_topic_change", + ConversationTopicCreation: "conversation_topic_creation", + ConversationTopicDeletion: "conversation_topic_deletion", + HelpCenterSettingsChange: "help_center_settings_change", + InboundConversationsChange: "inbound_conversations_change", + InboxAccessChange: "inbox_access_change", + MessageDeletion: "message_deletion", + MessageStateChange: "message_state_change", + MessengerLookAndFeelChange: "messenger_look_and_feel_change", + MessengerSearchRequiredChange: "messenger_search_required_change", + MessengerSpacesChange: "messenger_spaces_change", + OfficeHoursChange: "office_hours_change", + RoleChange: "role_change", + RoleCreation: "role_creation", + RoleDeletion: "role_deletion", + RulesetActivationTitlePreview: "ruleset_activation_title_preview", + RulesetCreation: "ruleset_creation", + RulesetDeletion: "ruleset_deletion", + SearchBrowseEnabledChange: "search_browse_enabled_change", + SearchBrowseRequiredChange: "search_browse_required_change", + SeatChange: "seat_change", + SeatRevoke: "seat_revoke", + SecuritySettingsChange: "security_settings_change", + TemporaryExpectationChange: "temporary_expectation_change", + UpfrontEmailCollectionChange: "upfront_email_collection_change", + WelcomeMessageChange: "welcome_message_change", + } as const; +} diff --git a/src/api/resources/unstable/types/ActivityLogList.ts b/src/api/resources/unstable/types/ActivityLogList.ts new file mode 100644 index 00000000..7c9d4e57 --- /dev/null +++ b/src/api/resources/unstable/types/ActivityLogList.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A paginated list of activity logs. + */ +export interface ActivityLogList { + /** String representing the object's type. Always has the value `activity_log.list`. */ + type?: string; + pages?: Intercom.unstable.CursorPages; + /** An array of activity logs */ + activity_logs?: (Intercom.unstable.ActivityLog | undefined)[]; +} diff --git a/src/api/resources/unstable/types/ActivityLogMetadata.ts b/src/api/resources/unstable/types/ActivityLogMetadata.ts new file mode 100644 index 00000000..4814d8e5 --- /dev/null +++ b/src/api/resources/unstable/types/ActivityLogMetadata.ts @@ -0,0 +1,27 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Additional data provided about Admin activity. + */ +export interface ActivityLogMetadata { + /** The way the admin signed in. */ + sign_in_method?: string; + /** The unique identifier for the contact which is provided by the Client. */ + external_id?: string; + /** The away mode status which is set to true when away and false when returned. */ + away_mode?: boolean; + /** The reason the Admin is away. */ + away_status_reason?: string; + /** Indicates if conversations should be reassigned while an Admin is away. */ + reassign_conversations?: boolean; + /** The action that initiated the status change. */ + source?: string; + /** Indicates if the status was changed automatically or manually. */ + auto_changed?: string; + /** The ID of the Admin who initiated the activity. */ + update_by?: number; + /** The name of the Admin who initiated the activity. */ + update_by_name?: string; +} diff --git a/src/api/resources/unstable/types/AddressableList.ts b/src/api/resources/unstable/types/AddressableList.ts new file mode 100644 index 00000000..787be0f6 --- /dev/null +++ b/src/api/resources/unstable/types/AddressableList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A list used to access other resources from a parent model. + */ +export interface AddressableList { + /** The addressable object type */ + type?: string; + /** The id of the addressable object */ + id?: string; + /** Url to get more company resources for this contact */ + url?: string; +} diff --git a/src/api/resources/unstable/types/AdminList.ts b/src/api/resources/unstable/types/AdminList.ts new file mode 100644 index 00000000..b5fc73d2 --- /dev/null +++ b/src/api/resources/unstable/types/AdminList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of admins associated with a given workspace. + */ +export interface AdminList { + /** String representing the object's type. Always has the value `admin.list`. */ + type?: string; + /** A list of admins associated with a given workspace. */ + admins?: (Intercom.unstable.Admin | undefined)[]; +} diff --git a/src/api/resources/unstable/types/AdminPriorityLevel.ts b/src/api/resources/unstable/types/AdminPriorityLevel.ts new file mode 100644 index 00000000..659f95f2 --- /dev/null +++ b/src/api/resources/unstable/types/AdminPriorityLevel.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Admin priority levels for the team + */ +export interface AdminPriorityLevel { + /** The primary admin ids for the team */ + primary_admin_ids?: number[]; + /** The secondary admin ids for the team */ + secondary_admin_ids?: number[]; +} diff --git a/src/api/resources/unstable/types/AdminReplyConversationRequest.ts b/src/api/resources/unstable/types/AdminReplyConversationRequest.ts new file mode 100644 index 00000000..b0bcb16c --- /dev/null +++ b/src/api/resources/unstable/types/AdminReplyConversationRequest.ts @@ -0,0 +1,34 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Payload of the request to reply on behalf of an admin + */ +export interface AdminReplyConversationRequest { + message_type: AdminReplyConversationRequest.MessageType; + type: "admin"; + /** The text body of the reply. Notes accept some HTML formatting. Must be present for comment and note message types. */ + body?: string; + /** The id of the admin who is authoring the comment. */ + admin_id: string; + /** The time the reply was created. If not provided, the current time will be used. */ + created_at?: number; + /** The quick reply options to display to the end user. Must be present for quick_reply message types. */ + reply_options?: Intercom.unstable.QuickReplyOption[]; + /** A list of image URLs that will be added as attachments. You can include up to 10 URLs. */ + attachment_urls?: string[]; + /** A list of files that will be added as attachments. You can include up to 10 files */ + attachment_files?: Intercom.unstable.ConversationAttachmentFiles[]; +} + +export namespace AdminReplyConversationRequest { + export type MessageType = "comment" | "note" | "quick_reply"; + export const MessageType = { + Comment: "comment", + Note: "note", + QuickReply: "quick_reply", + } as const; +} diff --git a/src/api/resources/unstable/types/AdminReplyTicketRequest.ts b/src/api/resources/unstable/types/AdminReplyTicketRequest.ts new file mode 100644 index 00000000..dfc2ae57 --- /dev/null +++ b/src/api/resources/unstable/types/AdminReplyTicketRequest.ts @@ -0,0 +1,40 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Payload of the request to reply on behalf of an admin + */ +export interface AdminReplyTicketRequest { + message_type: AdminReplyTicketRequest.MessageType; + type: "admin"; + /** The text body of the reply. Notes accept some HTML formatting. Must be present for comment and note message types. */ + body?: string; + /** The id of the admin who is authoring the comment. */ + admin_id: string; + /** The time the reply was created. If not provided, the current time will be used. */ + created_at?: number; + /** The quick reply options to display. Must be present for quick_reply message types. */ + reply_options?: AdminReplyTicketRequest.ReplyOptions.Item[]; + /** A list of image URLs that will be added as attachments. You can include up to 10 URLs. */ + attachment_urls?: string[]; +} + +export namespace AdminReplyTicketRequest { + export type MessageType = "comment" | "note" | "quick_reply"; + export const MessageType = { + Comment: "comment", + Note: "note", + QuickReply: "quick_reply", + } as const; + export type ReplyOptions = ReplyOptions.Item[]; + + export namespace ReplyOptions { + export interface Item { + /** The text to display in this quick reply option. */ + text: string; + /** A unique identifier for this quick reply option. This value will be available within the metadata of the comment ticket part that is created when a user clicks on this reply option. */ + uuid: string; + } + } +} diff --git a/src/api/resources/unstable/types/AdminWithApp.ts b/src/api/resources/unstable/types/AdminWithApp.ts new file mode 100644 index 00000000..4d7f69ed --- /dev/null +++ b/src/api/resources/unstable/types/AdminWithApp.ts @@ -0,0 +1,47 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Admins are the teammate accounts that have access to a workspace + */ +export interface AdminWithApp { + /** String representing the object's type. Always has the value `admin`. */ + type?: string; + /** The id representing the admin. */ + id?: string; + /** The name of the admin. */ + name?: string; + /** The email of the admin. */ + email?: string; + /** The job title of the admin. */ + job_title?: string; + /** Identifies if this admin is currently set in away mode. */ + away_mode_enabled?: boolean; + /** Identifies if this admin is set to automatically reassign new conversations to the apps default inbox. */ + away_mode_reassign?: boolean; + /** Identifies if this admin has a paid inbox seat to restrict/allow features that require them. */ + has_inbox_seat?: boolean; + /** This is a list of ids of the teams that this admin is part of. */ + team_ids?: number[]; + /** This object represents the avatar associated with the admin. */ + avatar?: AdminWithApp.Avatar; + /** Identifies if this admin's email is verified. */ + email_verified?: boolean; + /** App that the admin belongs to. */ + app?: Intercom.unstable.App; +} + +export namespace AdminWithApp { + /** + * This object represents the avatar associated with the admin. + */ + export interface Avatar { + /** This is a string that identifies the type of the object. It will always have the value `avatar`. */ + type?: string; + /** This object represents the avatar associated with the admin. */ + image_url?: string; + } +} diff --git a/src/api/resources/unstable/types/App.ts b/src/api/resources/unstable/types/App.ts new file mode 100644 index 00000000..fd2d8319 --- /dev/null +++ b/src/api/resources/unstable/types/App.ts @@ -0,0 +1,23 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * App is a workspace on Intercom + */ +export interface App { + /** */ + type?: string; + /** The id of the app. */ + id_code?: string; + /** The name of the app. */ + name?: string; + /** The Intercom region the app is located in. */ + region?: string; + /** The timezone of the region where the app is located. */ + timezone?: string; + /** When the app was created. */ + created_at?: number; + /** Whether or not the app uses identity verification. */ + identity_verification?: boolean; +} diff --git a/src/api/resources/unstable/types/ArticleContent.ts b/src/api/resources/unstable/types/ArticleContent.ts new file mode 100644 index 00000000..31652500 --- /dev/null +++ b/src/api/resources/unstable/types/ArticleContent.ts @@ -0,0 +1,38 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The Content of an Article. + */ +export interface ArticleContent { + /** The type of object - `article_content` . */ + type?: string; + /** The title of the article. */ + title?: string; + /** The description of the article. */ + description?: string; + /** The body of the article. */ + body?: string; + /** The ID of the author of the article. */ + author_id?: number; + /** Whether the article is `published` or is a `draft` . */ + state?: ArticleContent.State; + /** The time when the article was created (seconds). */ + created_at?: number; + /** The time when the article was last updated (seconds). */ + updated_at?: number; + /** The URL of the article. */ + url?: string; +} + +export namespace ArticleContent { + /** + * Whether the article is `published` or is a `draft` . + */ + export type State = "published" | "draft"; + export const State = { + Published: "published", + Draft: "draft", + } as const; +} diff --git a/src/api/resources/unstable/types/ArticleList.ts b/src/api/resources/unstable/types/ArticleList.ts new file mode 100644 index 00000000..5dbc0a01 --- /dev/null +++ b/src/api/resources/unstable/types/ArticleList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * This will return a list of articles for the App. + */ +export interface ArticleList { + /** The type of the object - `list`. */ + type?: "list"; + pages?: Intercom.unstable.CursorPages; + /** A count of the total number of articles. */ + total_count?: number; + /** An array of Article objects */ + data?: Intercom.unstable.ArticleListItem[]; +} diff --git a/src/api/resources/unstable/types/ArticleStatistics.ts b/src/api/resources/unstable/types/ArticleStatistics.ts new file mode 100644 index 00000000..2e12b7b3 --- /dev/null +++ b/src/api/resources/unstable/types/ArticleStatistics.ts @@ -0,0 +1,23 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The statistics of an article. + */ +export interface ArticleStatistics { + /** The type of object - `article_statistics`. */ + type?: "article_statistics"; + /** The number of total views the article has received. */ + views?: number; + /** The number of conversations started from the article. */ + conversions?: number; + /** The number of total reactions the article has received. */ + reactions?: number; + /** The percentage of happy reactions the article has received against other types of reaction. */ + happy_reaction_percentage?: number; + /** The percentage of neutral reactions the article has received against other types of reaction. */ + neutral_reaction_percentage?: number; + /** The percentage of sad reactions the article has received against other types of reaction. */ + sad_reaction_percentage?: number; +} diff --git a/src/api/resources/unstable/types/ArticleTranslatedContent.ts b/src/api/resources/unstable/types/ArticleTranslatedContent.ts new file mode 100644 index 00000000..5e4e52bd --- /dev/null +++ b/src/api/resources/unstable/types/ArticleTranslatedContent.ts @@ -0,0 +1,87 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * The Translated Content of an Article. The keys are the locale codes and the values are the translated content of the article. + */ +export interface ArticleTranslatedContent { + /** The type of object - article_translated_content. */ + type?: string; + /** The content of the article in Arabic */ + ar?: Intercom.unstable.ArticleContent; + /** The content of the article in Bulgarian */ + bg?: Intercom.unstable.ArticleContent; + /** The content of the article in Bosnian */ + bs?: Intercom.unstable.ArticleContent; + /** The content of the article in Catalan */ + ca?: Intercom.unstable.ArticleContent; + /** The content of the article in Czech */ + cs?: Intercom.unstable.ArticleContent; + /** The content of the article in Danish */ + da?: Intercom.unstable.ArticleContent; + /** The content of the article in German */ + de?: Intercom.unstable.ArticleContent; + /** The content of the article in Greek */ + el?: Intercom.unstable.ArticleContent; + /** The content of the article in English */ + en?: Intercom.unstable.ArticleContent; + /** The content of the article in Spanish */ + es?: Intercom.unstable.ArticleContent; + /** The content of the article in Estonian */ + et?: Intercom.unstable.ArticleContent; + /** The content of the article in Finnish */ + fi?: Intercom.unstable.ArticleContent; + /** The content of the article in French */ + fr?: Intercom.unstable.ArticleContent; + /** The content of the article in Hebrew */ + he?: Intercom.unstable.ArticleContent; + /** The content of the article in Croatian */ + hr?: Intercom.unstable.ArticleContent; + /** The content of the article in Hungarian */ + hu?: Intercom.unstable.ArticleContent; + /** The content of the article in Indonesian */ + id?: Intercom.unstable.ArticleContent; + /** The content of the article in Italian */ + it?: Intercom.unstable.ArticleContent; + /** The content of the article in Japanese */ + ja?: Intercom.unstable.ArticleContent; + /** The content of the article in Korean */ + ko?: Intercom.unstable.ArticleContent; + /** The content of the article in Lithuanian */ + lt?: Intercom.unstable.ArticleContent; + /** The content of the article in Latvian */ + lv?: Intercom.unstable.ArticleContent; + /** The content of the article in Mongolian */ + mn?: Intercom.unstable.ArticleContent; + /** The content of the article in Norwegian */ + nb?: Intercom.unstable.ArticleContent; + /** The content of the article in Dutch */ + nl?: Intercom.unstable.ArticleContent; + /** The content of the article in Polish */ + pl?: Intercom.unstable.ArticleContent; + /** The content of the article in Portuguese (Portugal) */ + pt?: Intercom.unstable.ArticleContent; + /** The content of the article in Romanian */ + ro?: Intercom.unstable.ArticleContent; + /** The content of the article in Russian */ + ru?: Intercom.unstable.ArticleContent; + /** The content of the article in Slovenian */ + sl?: Intercom.unstable.ArticleContent; + /** The content of the article in Serbian */ + sr?: Intercom.unstable.ArticleContent; + /** The content of the article in Swedish */ + sv?: Intercom.unstable.ArticleContent; + /** The content of the article in Turkish */ + tr?: Intercom.unstable.ArticleContent; + /** The content of the article in Vietnamese */ + vi?: Intercom.unstable.ArticleContent; + /** The content of the article in Portuguese (Brazil) */ + "pt-BR"?: Intercom.unstable.ArticleContent; + /** The content of the article in Chinese (China) */ + "zh-CN"?: Intercom.unstable.ArticleContent; + /** The content of the article in Chinese (Taiwan) */ + "zh-TW"?: Intercom.unstable.ArticleContent; +} diff --git a/src/api/resources/unstable/types/AssignConversationRequest.ts b/src/api/resources/unstable/types/AssignConversationRequest.ts new file mode 100644 index 00000000..e3eef208 --- /dev/null +++ b/src/api/resources/unstable/types/AssignConversationRequest.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Payload of the request to assign a conversation + */ +export interface AssignConversationRequest { + type: AssignConversationRequest.Type; + /** The id of the admin who is performing the action. */ + admin_id: string; + /** The `id` of the `admin` or `team` which will be assigned the conversation. A conversation can be assigned both an admin and a team.\nSet `0` if you want this assign to no admin or team (ie. Unassigned). */ + assignee_id: string; + /** Optionally you can send a response in the conversation when it is assigned. */ + body?: string; +} + +export namespace AssignConversationRequest { + export type Type = "admin" | "team"; + export const Type = { + Admin: "admin", + Team: "team", + } as const; +} diff --git a/src/api/resources/unstable/types/AwayStatusReason.ts b/src/api/resources/unstable/types/AwayStatusReason.ts new file mode 100644 index 00000000..02f9e7a8 --- /dev/null +++ b/src/api/resources/unstable/types/AwayStatusReason.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface AwayStatusReason { + type?: string; + /** The unique identifier for the away status reason */ + id?: string; + /** The display text for the away status reason */ + label?: string; + /** The emoji associated with the status reason */ + emoji?: string; + /** The display order of the status reason */ + order?: number; + /** Whether the status reason has been soft deleted */ + deleted?: boolean; + /** The Unix timestamp when the status reason was created */ + created_at?: number; + /** The Unix timestamp when the status reason was last updated */ + updated_at?: number; +} diff --git a/src/api/resources/unstable/types/CloseConversationRequest.ts b/src/api/resources/unstable/types/CloseConversationRequest.ts new file mode 100644 index 00000000..56f0755e --- /dev/null +++ b/src/api/resources/unstable/types/CloseConversationRequest.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Payload of the request to close a conversation + */ +export interface CloseConversationRequest { + type: "admin"; + /** The id of the admin who is performing the action. */ + admin_id: string; + /** Optionally you can leave a message in the conversation to provide additional context to the user and other teammates. */ + body?: string; +} diff --git a/src/api/resources/unstable/types/CollectionList.ts b/src/api/resources/unstable/types/CollectionList.ts new file mode 100644 index 00000000..ee2bbe53 --- /dev/null +++ b/src/api/resources/unstable/types/CollectionList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * This will return a list of Collections for the App. + */ +export interface CollectionList { + /** The type of the object - `list`. */ + type?: "list"; + pages?: Intercom.unstable.CursorPages; + /** A count of the total number of collections. */ + total_count?: number; + /** An array of collection objects */ + data?: Intercom.unstable.Collection[]; +} diff --git a/src/api/resources/unstable/types/CompanyAttachedContacts.ts b/src/api/resources/unstable/types/CompanyAttachedContacts.ts new file mode 100644 index 00000000..c4490d96 --- /dev/null +++ b/src/api/resources/unstable/types/CompanyAttachedContacts.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of Contact Objects + */ +export interface CompanyAttachedContacts { + /** The type of object - `list` */ + type?: "list"; + /** An array containing Contact Objects */ + data?: Intercom.unstable.Contact[]; + /** The total number of contacts */ + total_count?: number; + pages?: Intercom.unstable.CursorPages; +} diff --git a/src/api/resources/unstable/types/CompanyAttachedSegments.ts b/src/api/resources/unstable/types/CompanyAttachedSegments.ts new file mode 100644 index 00000000..b7c72a13 --- /dev/null +++ b/src/api/resources/unstable/types/CompanyAttachedSegments.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of Segment Objects + */ +export interface CompanyAttachedSegments { + /** The type of object - `list` */ + type?: "list"; + /** An array containing Segment Objects */ + data?: Intercom.unstable.Segment[]; +} diff --git a/src/api/resources/unstable/types/CompanyData.ts b/src/api/resources/unstable/types/CompanyData.ts new file mode 100644 index 00000000..de38845a --- /dev/null +++ b/src/api/resources/unstable/types/CompanyData.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * An object containing data about the companies that a contact is associated with. + */ +export interface CompanyData { + /** The unique identifier for the company which is given by Intercom. */ + id?: string; + /** The type of the object. Always company. */ + type?: "company"; + /** The relative URL of the company. */ + url?: string; +} diff --git a/src/api/resources/unstable/types/CompanyList.ts b/src/api/resources/unstable/types/CompanyList.ts new file mode 100644 index 00000000..af078812 --- /dev/null +++ b/src/api/resources/unstable/types/CompanyList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * This will return a list of companies for the App. + */ +export interface CompanyList { + /** The type of object - `list`. */ + type?: "list"; + pages?: Intercom.unstable.CursorPages; + /** The total number of companies. */ + total_count?: number; + /** An array containing Company Objects. */ + data?: Intercom.unstable.Company[]; +} diff --git a/src/api/resources/unstable/types/CompanyScroll.ts b/src/api/resources/unstable/types/CompanyScroll.ts new file mode 100644 index 00000000..95030bb2 --- /dev/null +++ b/src/api/resources/unstable/types/CompanyScroll.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Companies allow you to represent organizations using your product. Each company will have its own description and be associated with contacts. You can fetch, create, update and list companies. + */ +export interface CompanyScroll { + /** The type of object - `list` */ + type?: "list"; + data?: Intercom.unstable.Company[]; + pages?: Intercom.unstable.CursorPages; + /** The total number of companies */ + total_count?: number; + /** The scroll parameter to use in the next request to fetch the next page of results. */ + scroll_param?: string; +} diff --git a/src/api/resources/unstable/types/ContactArchived.ts b/src/api/resources/unstable/types/ContactArchived.ts new file mode 100644 index 00000000..9a5527f7 --- /dev/null +++ b/src/api/resources/unstable/types/ContactArchived.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * archived contact object + */ +export interface ContactArchived extends Intercom.unstable.ContactReference { + /** Whether the contact is archived or not. */ + archived?: boolean; +} diff --git a/src/api/resources/unstable/types/ContactAttachedCompanies.ts b/src/api/resources/unstable/types/ContactAttachedCompanies.ts new file mode 100644 index 00000000..d4a80f8f --- /dev/null +++ b/src/api/resources/unstable/types/ContactAttachedCompanies.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of Company Objects + */ +export interface ContactAttachedCompanies { + /** The type of object */ + type?: "list"; + /** An array containing Company Objects */ + companies?: Intercom.unstable.Company[]; + /** The total number of companies associated to this contact */ + total_count?: number; + pages?: Intercom.unstable.PagesLink; +} diff --git a/src/api/resources/unstable/types/ContactBlocked.ts b/src/api/resources/unstable/types/ContactBlocked.ts new file mode 100644 index 00000000..203b8792 --- /dev/null +++ b/src/api/resources/unstable/types/ContactBlocked.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * blocked contact object + */ +export interface ContactBlocked extends Intercom.unstable.ContactReference { + /** Always true. */ + blocked?: boolean; +} diff --git a/src/api/resources/unstable/types/ContactCompanies.ts b/src/api/resources/unstable/types/ContactCompanies.ts new file mode 100644 index 00000000..a827865a --- /dev/null +++ b/src/api/resources/unstable/types/ContactCompanies.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * An object with metadata about companies attached to a contact . Up to 10 will be displayed here. Use the url to get more. + */ +export interface ContactCompanies { + /** An array of company data objects attached to the contact. */ + data?: Intercom.unstable.CompanyData[]; + /** Url to get more company resources for this contact */ + url?: string; + /** Integer representing the total number of companies attached to this contact */ + total_count?: number; + /** Whether there's more Addressable Objects to be viewed. If true, use the url to view all */ + has_more?: boolean; +} diff --git a/src/api/resources/unstable/types/ContactDeleted.ts b/src/api/resources/unstable/types/ContactDeleted.ts new file mode 100644 index 00000000..38fc4950 --- /dev/null +++ b/src/api/resources/unstable/types/ContactDeleted.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * deleted contact object + */ +export interface ContactDeleted extends Intercom.unstable.ContactReference { + /** Whether the contact is deleted or not. */ + deleted?: boolean; +} diff --git a/src/api/resources/unstable/types/ContactList.ts b/src/api/resources/unstable/types/ContactList.ts new file mode 100644 index 00000000..51a0df3c --- /dev/null +++ b/src/api/resources/unstable/types/ContactList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Contacts are your users in Intercom. + */ +export interface ContactList { + /** Always list */ + type?: "list"; + /** The list of contact objects */ + data?: Intercom.unstable.Contact[]; + /** A count of the total number of objects. */ + total_count?: number; + pages?: Intercom.unstable.CursorPages; +} diff --git a/src/api/resources/unstable/types/ContactLocation.ts b/src/api/resources/unstable/types/ContactLocation.ts new file mode 100644 index 00000000..6f3ca2ec --- /dev/null +++ b/src/api/resources/unstable/types/ContactLocation.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * An object containing location meta data about a Intercom contact. + */ +export interface ContactLocation { + /** Always location */ + type?: string; + /** The country that the contact is located in */ + country?: string; + /** The overal region that the contact is located in */ + region?: string; + /** The city that the contact is located in */ + city?: string; +} diff --git a/src/api/resources/unstable/types/ContactNotes.ts b/src/api/resources/unstable/types/ContactNotes.ts new file mode 100644 index 00000000..fe835d12 --- /dev/null +++ b/src/api/resources/unstable/types/ContactNotes.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * An object containing notes meta data about the notes that a contact has. Up to 10 will be displayed here. Use the url to get more. + */ +export interface ContactNotes { + /** This object represents the notes attached to a contact. */ + data?: Intercom.unstable.AddressableList[]; + /** Url to get more company resources for this contact */ + url?: string; + /** Int representing the total number of companyies attached to this contact */ + total_count?: number; + /** Whether there's more Addressable Objects to be viewed. If true, use the url to view all */ + has_more?: boolean; +} diff --git a/src/api/resources/unstable/types/ContactReference.ts b/src/api/resources/unstable/types/ContactReference.ts new file mode 100644 index 00000000..d202aadc --- /dev/null +++ b/src/api/resources/unstable/types/ContactReference.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * reference to contact object + */ +export interface ContactReference { + /** always contact */ + type?: "contact"; + /** The unique identifier for the contact which is given by Intercom. */ + id?: string; + /** The unique identifier for the contact which is provided by the Client. */ + external_id?: string; +} diff --git a/src/api/resources/unstable/types/ContactReplyBaseRequest.ts b/src/api/resources/unstable/types/ContactReplyBaseRequest.ts new file mode 100644 index 00000000..0559f83e --- /dev/null +++ b/src/api/resources/unstable/types/ContactReplyBaseRequest.ts @@ -0,0 +1,29 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface ContactReplyBaseRequest { + message_type: "comment"; + type: "user"; + /** The text body of the comment. */ + body: string; + /** The time the reply was created. If not provided, the current time will be used. */ + created_at?: number; + /** A list of image URLs that will be added as attachments. You can include up to 10 URLs. */ + attachment_urls?: string[]; + /** The quick reply selection the contact wishes to respond with. These map to buttons displayed in the Messenger UI if sent by a bot, or the reply options sent by an Admin via the API. */ + reply_options?: ContactReplyBaseRequest.ReplyOptions.Item[]; +} + +export namespace ContactReplyBaseRequest { + export type ReplyOptions = ReplyOptions.Item[]; + + export namespace ReplyOptions { + export interface Item { + /** The text of the chosen reply option. */ + text: string; + /** The unique identifier for the quick reply option selected. */ + uuid: string; + } + } +} diff --git a/src/api/resources/unstable/types/ContactReplyConversationRequest.ts b/src/api/resources/unstable/types/ContactReplyConversationRequest.ts new file mode 100644 index 00000000..74fe2c40 --- /dev/null +++ b/src/api/resources/unstable/types/ContactReplyConversationRequest.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +export type ContactReplyConversationRequest = + | Intercom.unstable.ContactReplyIntercomUserIdRequest + | Intercom.unstable.ContactReplyEmailRequest + | Intercom.unstable.ContactReplyUserIdRequest; diff --git a/src/api/resources/unstable/types/ContactReplyEmailRequest.ts b/src/api/resources/unstable/types/ContactReplyEmailRequest.ts new file mode 100644 index 00000000..f00aaaec --- /dev/null +++ b/src/api/resources/unstable/types/ContactReplyEmailRequest.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Payload of the request to reply on behalf of a contact using their `email` + */ +export interface ContactReplyEmailRequest extends Intercom.unstable.ContactReplyBaseRequest { + /** The email you have defined for the user. */ + email: string; + /** A list of files that will be added as attachments. */ + attachment_files?: Intercom.unstable.ConversationAttachmentFiles[]; +} diff --git a/src/api/resources/unstable/types/ContactReplyIntercomUserIdRequest.ts b/src/api/resources/unstable/types/ContactReplyIntercomUserIdRequest.ts new file mode 100644 index 00000000..0b6e3424 --- /dev/null +++ b/src/api/resources/unstable/types/ContactReplyIntercomUserIdRequest.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Payload of the request to reply on behalf of a contact using their `intercom_user_id` + */ +export interface ContactReplyIntercomUserIdRequest extends Intercom.unstable.ContactReplyBaseRequest { + /** The identifier for the contact as given by Intercom. */ + intercom_user_id: string; + /** A list of files that will be added as attachments. */ + attachment_files?: Intercom.unstable.ConversationAttachmentFiles[]; +} diff --git a/src/api/resources/unstable/types/ContactReplyTicketEmailRequest.ts b/src/api/resources/unstable/types/ContactReplyTicketEmailRequest.ts new file mode 100644 index 00000000..b66e60dd --- /dev/null +++ b/src/api/resources/unstable/types/ContactReplyTicketEmailRequest.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Payload of the request to reply on behalf of a contact using their `email` + */ +export interface ContactReplyTicketEmailRequest extends Intercom.unstable.ContactReplyBaseRequest { + /** The email you have defined for the user. */ + email: string; +} diff --git a/src/api/resources/unstable/types/ContactReplyTicketIntercomUserIdRequest.ts b/src/api/resources/unstable/types/ContactReplyTicketIntercomUserIdRequest.ts new file mode 100644 index 00000000..fd94eb7f --- /dev/null +++ b/src/api/resources/unstable/types/ContactReplyTicketIntercomUserIdRequest.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Payload of the request to reply on behalf of a contact using their `intercom_user_id` + */ +export interface ContactReplyTicketIntercomUserIdRequest extends Intercom.unstable.ContactReplyBaseRequest { + /** The identifier for the contact as given by Intercom. */ + intercom_user_id: string; +} diff --git a/src/api/resources/unstable/types/ContactReplyTicketRequest.ts b/src/api/resources/unstable/types/ContactReplyTicketRequest.ts new file mode 100644 index 00000000..c83977cc --- /dev/null +++ b/src/api/resources/unstable/types/ContactReplyTicketRequest.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +export type ContactReplyTicketRequest = + | Intercom.unstable.ContactReplyTicketIntercomUserIdRequest + | Intercom.unstable.ContactReplyTicketUserIdRequest + | Intercom.unstable.ContactReplyTicketEmailRequest; diff --git a/src/api/resources/unstable/types/ContactReplyTicketUserIdRequest.ts b/src/api/resources/unstable/types/ContactReplyTicketUserIdRequest.ts new file mode 100644 index 00000000..5a6d2796 --- /dev/null +++ b/src/api/resources/unstable/types/ContactReplyTicketUserIdRequest.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Payload of the request to reply on behalf of a contact using their `user_id` + */ +export interface ContactReplyTicketUserIdRequest extends Intercom.unstable.ContactReplyBaseRequest { + /** The external_id you have defined for the contact. */ + user_id: string; +} diff --git a/src/api/resources/unstable/types/ContactReplyUserIdRequest.ts b/src/api/resources/unstable/types/ContactReplyUserIdRequest.ts new file mode 100644 index 00000000..b7e32da0 --- /dev/null +++ b/src/api/resources/unstable/types/ContactReplyUserIdRequest.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Payload of the request to reply on behalf of a contact using their `user_id` + */ +export interface ContactReplyUserIdRequest extends Intercom.unstable.ContactReplyBaseRequest { + /** The external_id you have defined for the contact. */ + user_id: string; + /** A list of files that will be added as attachments. You can include up to 10 files. */ + attachment_files?: Intercom.unstable.ConversationAttachmentFiles[]; +} diff --git a/src/api/resources/unstable/types/ContactSegments.ts b/src/api/resources/unstable/types/ContactSegments.ts new file mode 100644 index 00000000..21a83fec --- /dev/null +++ b/src/api/resources/unstable/types/ContactSegments.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of segments objects attached to a specific contact. + */ +export interface ContactSegments { + /** The type of the object */ + type?: "list"; + /** Segment objects associated with the contact. */ + data?: Intercom.unstable.Segment[]; +} diff --git a/src/api/resources/unstable/types/ContactSocialProfiles.ts b/src/api/resources/unstable/types/ContactSocialProfiles.ts new file mode 100644 index 00000000..32b4dfde --- /dev/null +++ b/src/api/resources/unstable/types/ContactSocialProfiles.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * An object containing social profiles that a contact has. + */ +export interface ContactSocialProfiles { + /** A list of social profiles objects associated with the contact. */ + data?: Intercom.unstable.SocialProfile[]; +} diff --git a/src/api/resources/unstable/types/ContactSubscriptionTypes.ts b/src/api/resources/unstable/types/ContactSubscriptionTypes.ts new file mode 100644 index 00000000..fc133189 --- /dev/null +++ b/src/api/resources/unstable/types/ContactSubscriptionTypes.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * An object containing Subscription Types meta data about the SubscriptionTypes that a contact has. + */ +export interface ContactSubscriptionTypes { + /** This object represents the subscriptions attached to a contact. */ + data?: Intercom.unstable.AddressableList[]; + /** Url to get more subscription type resources for this contact */ + url?: string; + /** Int representing the total number of subscription types attached to this contact */ + total_count?: number; + /** Whether there's more Addressable Objects to be viewed. If true, use the url to view all */ + has_more?: boolean; +} diff --git a/src/api/resources/unstable/types/ContactTags.ts b/src/api/resources/unstable/types/ContactTags.ts new file mode 100644 index 00000000..c7bc0e62 --- /dev/null +++ b/src/api/resources/unstable/types/ContactTags.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * An object containing tags meta data about the tags that a contact has. Up to 10 will be displayed here. Use the url to get more. + */ +export interface ContactTags { + /** This object represents the tags attached to a contact. */ + data?: Intercom.unstable.AddressableList[]; + /** url to get more tag resources for this contact */ + url?: string; + /** Int representing the total number of tags attached to this contact */ + total_count?: number; + /** Whether there's more Addressable Objects to be viewed. If true, use the url to view all */ + has_more?: boolean; +} diff --git a/src/api/resources/unstable/types/ContactUnarchived.ts b/src/api/resources/unstable/types/ContactUnarchived.ts new file mode 100644 index 00000000..38322437 --- /dev/null +++ b/src/api/resources/unstable/types/ContactUnarchived.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * unarchived contact object + */ +export interface ContactUnarchived extends Intercom.unstable.ContactReference { + /** Whether the contact is archived or not. */ + archived?: boolean; +} diff --git a/src/api/resources/unstable/types/ContentSourcesList.ts b/src/api/resources/unstable/types/ContentSourcesList.ts new file mode 100644 index 00000000..9250df9d --- /dev/null +++ b/src/api/resources/unstable/types/ContentSourcesList.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +export interface ContentSourcesList { + type?: "content_source.list"; + /** The total number of content sources used by AI Agent in the conversation. */ + total_count?: number; + /** The content sources used by AI Agent in the conversation. */ + content_sources?: Intercom.unstable.ContentSource[]; +} diff --git a/src/api/resources/unstable/types/ConversationAttachmentFiles.ts b/src/api/resources/unstable/types/ConversationAttachmentFiles.ts new file mode 100644 index 00000000..98d751b4 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationAttachmentFiles.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Properties of the attachment files in a conversation part + */ +export interface ConversationAttachmentFiles { + /** The content type of the file */ + content_type?: string; + /** The base64 encoded file data. */ + data?: string; + /** The name of the file. */ + name?: string; +} diff --git a/src/api/resources/unstable/types/ConversationAttributeUpdatedByAdmin.ts b/src/api/resources/unstable/types/ConversationAttributeUpdatedByAdmin.ts new file mode 100644 index 00000000..1c49cecf --- /dev/null +++ b/src/api/resources/unstable/types/ConversationAttributeUpdatedByAdmin.ts @@ -0,0 +1,23 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Contains details about Custom Data Attributes (CDAs) that were modified by an admin (operator) for conversation part type conversation_attribute_updated_by_admin. + */ +export interface ConversationAttributeUpdatedByAdmin { + attribute?: ConversationAttributeUpdatedByAdmin.Attribute; + value?: ConversationAttributeUpdatedByAdmin.Value; +} + +export namespace ConversationAttributeUpdatedByAdmin { + export interface Attribute { + /** Name of the CDA updated */ + name?: string; + } + + export interface Value { + /** Value of the CDA updated */ + name?: string; + } +} diff --git a/src/api/resources/unstable/types/ConversationAttributeUpdatedByWorkflow.ts b/src/api/resources/unstable/types/ConversationAttributeUpdatedByWorkflow.ts new file mode 100644 index 00000000..65572650 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationAttributeUpdatedByWorkflow.ts @@ -0,0 +1,29 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Contains details about the workflow that was triggered and any Custom Data Attributes (CDAs) that were modified during the workflow execution for conversation part type conversation_attribute_updated_by_workflow. + */ +export interface ConversationAttributeUpdatedByWorkflow { + workflow?: ConversationAttributeUpdatedByWorkflow.Workflow; + attribute?: ConversationAttributeUpdatedByWorkflow.Attribute; + value?: ConversationAttributeUpdatedByWorkflow.Value; +} + +export namespace ConversationAttributeUpdatedByWorkflow { + export interface Workflow { + /** Name of the workflow */ + name?: string; + } + + export interface Attribute { + /** Name of the CDA updated */ + name?: string; + } + + export interface Value { + /** Value of the CDA updated */ + name?: string; + } +} diff --git a/src/api/resources/unstable/types/ConversationContacts.ts b/src/api/resources/unstable/types/ConversationContacts.ts new file mode 100644 index 00000000..c9818ad5 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationContacts.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * The list of contacts (users or leads) involved in this conversation. This will only contain one customer unless more were added via the group conversation feature. + */ +export interface ConversationContacts { + /** */ + type?: "contact.list"; + /** The list of contacts (users or leads) involved in this conversation. This will only contain one customer unless more were added via the group conversation feature. */ + contacts?: Intercom.unstable.ContactReference[]; +} diff --git a/src/api/resources/unstable/types/ConversationDeleted.ts b/src/api/resources/unstable/types/ConversationDeleted.ts new file mode 100644 index 00000000..c45bc58f --- /dev/null +++ b/src/api/resources/unstable/types/ConversationDeleted.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * deleted conversation object + */ +export interface ConversationDeleted { + /** The unique identifier for the conversation. */ + id?: string; + /** always conversation */ + object?: "conversation"; + /** Whether the conversation is deleted or not. */ + deleted?: boolean; +} diff --git a/src/api/resources/unstable/types/ConversationFirstContactReply.ts b/src/api/resources/unstable/types/ConversationFirstContactReply.ts new file mode 100644 index 00000000..7d859b74 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationFirstContactReply.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * An object containing information on the first users message. For a contact initiated message this will represent the users original message. + */ +export interface ConversationFirstContactReply { + /** */ + created_at?: number; + /** */ + type?: string; + /** */ + url?: string; +} diff --git a/src/api/resources/unstable/types/ConversationList.ts b/src/api/resources/unstable/types/ConversationList.ts new file mode 100644 index 00000000..402dae67 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Conversations are how you can communicate with users in Intercom. They are created when a contact replies to an outbound message, or when one admin directly sends a message to a single contact. + */ +export interface ConversationList { + /** Always conversation.list */ + type?: "conversation.list"; + /** The list of conversation objects */ + conversations?: Intercom.unstable.Conversation[]; + /** A count of the total number of objects. */ + total_count?: number; + pages?: Intercom.unstable.CursorPages; +} diff --git a/src/api/resources/unstable/types/ConversationPart.ts b/src/api/resources/unstable/types/ConversationPart.ts new file mode 100644 index 00000000..e724eb88 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationPart.ts @@ -0,0 +1,55 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A Conversation Part represents a message in the conversation. + */ +export interface ConversationPart { + /** Always conversation_part */ + type?: string; + /** The id representing the conversation part. */ + id?: string; + /** The type of conversation part. */ + part_type?: string; + /** The message body, which may contain HTML. For Twitter, this will show a generic message regarding why the body is obscured. */ + body?: string; + /** The time the conversation part was created. */ + created_at?: number; + /** The last time the conversation part was updated. */ + updated_at?: number; + /** The time the user was notified with the conversation part. */ + notified_at?: number; + /** The id of the admin that was assigned the conversation by this conversation_part (null if there has been no change in assignment.) */ + assigned_to?: Intercom.unstable.Reference; + author?: Intercom.unstable.ConversationPartAuthor; + /** A list of attachments for the part. */ + attachments?: Intercom.unstable.PartAttachment[]; + /** The external id of the conversation part */ + external_id?: string; + /** Whether or not the conversation part has been redacted. */ + redacted?: boolean; + email_message_metadata?: Intercom.unstable.EmailMessageMetadata; + metadata?: Intercom.unstable.ConversationPartMetadata; + /** Indicates the current state of conversation when the conversation part was created. */ + state?: ConversationPart.State; + /** A list of tags objects associated with the conversation part. */ + tags?: Intercom.unstable.TagBasic[]; + event_details?: Intercom.unstable.EventDetails; + /** The app package code if this part was created via API. null if the part was not created via API. */ + app_package_code?: string; +} + +export namespace ConversationPart { + /** + * Indicates the current state of conversation when the conversation part was created. + */ + export type State = "open" | "closed" | "snoozed"; + export const State = { + Open: "open", + Closed: "closed", + Snoozed: "snoozed", + } as const; +} diff --git a/src/api/resources/unstable/types/ConversationPartAuthor.ts b/src/api/resources/unstable/types/ConversationPartAuthor.ts new file mode 100644 index 00000000..01a62b9f --- /dev/null +++ b/src/api/resources/unstable/types/ConversationPartAuthor.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The object who initiated the conversation, which can be a Contact, Admin or Team. Bots and campaigns send messages on behalf of Admins or Teams. For Twitter, this will be blank. + */ +export interface ConversationPartAuthor { + /** The type of the author */ + type?: string; + /** The id of the author */ + id?: string; + /** The name of the author */ + name?: string; + /** The email of the author */ + email?: string; + /** If this conversation part was sent by the AI Agent */ + from_ai_agent?: boolean; + /** If this conversation part body was generated by the AI Agent */ + is_ai_answer?: boolean; +} diff --git a/src/api/resources/unstable/types/ConversationPartMetadata.ts b/src/api/resources/unstable/types/ConversationPartMetadata.ts new file mode 100644 index 00000000..1a71c4a2 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationPartMetadata.ts @@ -0,0 +1,26 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Metadata for a conversation part + */ +export interface ConversationPartMetadata { + /** The quick reply options sent by the Admin or bot, presented in this conversation part. */ + quick_reply_options?: ConversationPartMetadata.QuickReplyOptions.Item[]; + /** The unique identifier for the quick reply option that was clicked by the end user. */ + quick_reply_uuid?: string; +} + +export namespace ConversationPartMetadata { + export type QuickReplyOptions = QuickReplyOptions.Item[]; + + export namespace QuickReplyOptions { + export interface Item extends Intercom.unstable.QuickReplyOption { + /** The translations for the quick reply option. */ + translations?: Record; + } + } +} diff --git a/src/api/resources/unstable/types/ConversationParts.ts b/src/api/resources/unstable/types/ConversationParts.ts new file mode 100644 index 00000000..2c21bccd --- /dev/null +++ b/src/api/resources/unstable/types/ConversationParts.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of Conversation Part objects for each part message in the conversation. This is only returned when Retrieving a Conversation, and ignored when Listing all Conversations. There is a limit of 500 parts. + */ +export interface ConversationParts { + /** */ + type?: "conversation_part.list"; + /** A list of Conversation Part objects for each part message in the conversation. This is only returned when Retrieving a Conversation, and ignored when Listing all Conversations. There is a limit of 500 parts. */ + conversation_parts?: Intercom.unstable.ConversationPart[]; + /** */ + total_count?: number; +} diff --git a/src/api/resources/unstable/types/ConversationRating.ts b/src/api/resources/unstable/types/ConversationRating.ts new file mode 100644 index 00000000..5b5a7899 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationRating.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * The Conversation Rating object which contains information on the rating and/or remark added by a Contact and the Admin assigned to the conversation. + */ +export interface ConversationRating { + /** The rating, between 1 and 5, for the conversation. */ + rating?: number; + /** An optional field to add a remark to correspond to the number rating */ + remark?: string; + /** The time the rating was requested in the conversation being rated. */ + created_at?: number; + contact?: Intercom.unstable.ContactReference; + teammate?: Intercom.unstable.Reference; +} diff --git a/src/api/resources/unstable/types/ConversationResponseTime.ts b/src/api/resources/unstable/types/ConversationResponseTime.ts new file mode 100644 index 00000000..56d2b0ae --- /dev/null +++ b/src/api/resources/unstable/types/ConversationResponseTime.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Details of first response time of assigned team in seconds. + */ +export interface ConversationResponseTime { + /** Id of the assigned team. */ + team_id?: number; + /** Name of the assigned Team, null if team does not exist, Unassigned if no team is assigned. */ + team_name?: string; + /** First response time of assigned team in seconds. */ + response_time?: number; +} diff --git a/src/api/resources/unstable/types/ConversationSource.ts b/src/api/resources/unstable/types/ConversationSource.ts new file mode 100644 index 00000000..e9ade720 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationSource.ts @@ -0,0 +1,57 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * The type of the conversation part that started this conversation. Can be Contact, Admin, Campaign, Automated or Operator initiated. + */ +export interface ConversationSource { + /** This includes conversation, email, facebook, instagram, phone_call, phone_switch, push, sms, twitter and whatsapp. */ + type?: ConversationSource.Type; + /** The id representing the message. */ + id?: string; + /** The conversation's initiation type. Possible values are customer_initiated, campaigns_initiated (legacy campaigns), operator_initiated (Custom bot), automated (Series and other outbounds with dynamic audience message) and admin_initiated (fixed audience message, ticket initiated by an admin, group email). */ + delivered_as?: string; + /** Optional. The message subject. For Twitter, this will show a generic message regarding why the subject is obscured. */ + subject?: string; + /** The message body, which may contain HTML. For Twitter, this will show a generic message regarding why the body is obscured. */ + body?: string; + author?: Intercom.unstable.ConversationPartAuthor; + /** A list of attachments for the part. */ + attachments?: Intercom.unstable.PartAttachment[]; + /** The URL where the conversation was started. For Twitter, Email, and Bots, this will be blank. */ + url?: string; + /** Whether or not the source message has been redacted. Only applicable for contact initiated messages. */ + redacted?: boolean; +} + +export namespace ConversationSource { + /** + * This includes conversation, email, facebook, instagram, phone_call, phone_switch, push, sms, twitter and whatsapp. + */ + export type Type = + | "conversation" + | "email" + | "facebook" + | "instagram" + | "phone_call" + | "phone_switch" + | "push" + | "sms" + | "twitter" + | "whatsapp"; + export const Type = { + Conversation: "conversation", + Email: "email", + Facebook: "facebook", + Instagram: "instagram", + PhoneCall: "phone_call", + PhoneSwitch: "phone_switch", + Push: "push", + Sms: "sms", + Twitter: "twitter", + Whatsapp: "whatsapp", + } as const; +} diff --git a/src/api/resources/unstable/types/ConversationStatistics.ts b/src/api/resources/unstable/types/ConversationStatistics.ts new file mode 100644 index 00000000..03dc8b5c --- /dev/null +++ b/src/api/resources/unstable/types/ConversationStatistics.ts @@ -0,0 +1,55 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A Statistics object containing all information required for reporting, with timestamps and calculated metrics. + */ +export interface ConversationStatistics { + /** */ + type?: string; + /** Duration until last assignment before first admin reply. In seconds. */ + time_to_assignment?: number; + /** Duration until first admin reply. Subtracts out of business hours. In seconds. */ + time_to_admin_reply?: number; + /** Duration until conversation was closed first time. Subtracts out of business hours. In seconds. */ + time_to_first_close?: number; + /** Duration until conversation was closed last time. Subtracts out of business hours. In seconds. */ + time_to_last_close?: number; + /** Median based on all admin replies after a contact reply. Subtracts out of business hours. In seconds. */ + median_time_to_reply?: number; + /** Time of first text conversation part from a contact. */ + first_contact_reply_at?: number; + /** Time of first assignment after first_contact_reply_at. */ + first_assignment_at?: number; + /** Time of first admin reply after first_contact_reply_at. */ + first_admin_reply_at?: number; + /** Time of first close after first_contact_reply_at. */ + first_close_at?: number; + /** Time of last assignment after first_contact_reply_at. */ + last_assignment_at?: number; + /** Time of first admin reply since most recent assignment. */ + last_assignment_admin_reply_at?: number; + /** Time of the last conversation part from a contact. */ + last_contact_reply_at?: number; + /** Time of the last conversation part from an admin. */ + last_admin_reply_at?: number; + /** Time of the last conversation close. */ + last_close_at?: number; + /** The last admin who closed the conversation. Returns a reference to an Admin object. */ + last_closed_by_id?: string; + /** Number of reopens after first_contact_reply_at. */ + count_reopens?: number; + /** Number of assignments after first_contact_reply_at. */ + count_assignments?: number; + /** Total number of conversation parts. */ + count_conversation_parts?: number; + /** An array of conversation response time objects */ + assigned_team_first_response_time_by_team?: Intercom.unstable.ConversationResponseTime[]; + /** An array of conversation response time objects within office hours */ + assigned_team_first_response_time_in_office_hours?: Intercom.unstable.ConversationResponseTime[]; + /** Time from conversation assignment to conversation close in seconds. */ + handling_time?: number; +} diff --git a/src/api/resources/unstable/types/ConversationTeammates.ts b/src/api/resources/unstable/types/ConversationTeammates.ts new file mode 100644 index 00000000..b72a5928 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationTeammates.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * The list of teammates who participated in the conversation (wrote at least one conversation part). + */ +export interface ConversationTeammates { + /** The type of the object - `admin.list`. */ + type?: string; + /** The list of teammates who participated in the conversation (wrote at least one conversation part). */ + teammates?: Intercom.unstable.Reference[]; +} diff --git a/src/api/resources/unstable/types/CreateOrUpdateTagRequest.ts b/src/api/resources/unstable/types/CreateOrUpdateTagRequest.ts new file mode 100644 index 00000000..a79ff2e0 --- /dev/null +++ b/src/api/resources/unstable/types/CreateOrUpdateTagRequest.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * You can create or update an existing tag. + */ +export interface CreateOrUpdateTagRequest { + /** The name of the tag, which will be created if not found, or the new name for the tag if this is an update request. Names are case insensitive. */ + name: string; + /** The id of tag to updates. */ + id?: string; +} diff --git a/src/api/resources/unstable/types/CreateTicketReplyWithCommentRequest.ts b/src/api/resources/unstable/types/CreateTicketReplyWithCommentRequest.ts new file mode 100644 index 00000000..cbca0524 --- /dev/null +++ b/src/api/resources/unstable/types/CreateTicketReplyWithCommentRequest.ts @@ -0,0 +1,9 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +export type CreateTicketReplyWithCommentRequest = + | Intercom.unstable.ContactReplyTicketRequest + | Intercom.unstable.AdminReplyTicketRequest; diff --git a/src/api/resources/unstable/types/CreateTicketRequestBody.ts b/src/api/resources/unstable/types/CreateTicketRequestBody.ts new file mode 100644 index 00000000..b5af5ba1 --- /dev/null +++ b/src/api/resources/unstable/types/CreateTicketRequestBody.ts @@ -0,0 +1,50 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * You can create a Ticket + */ +export interface CreateTicketRequestBody { + /** The ID of the type of ticket you want to create */ + ticket_type_id: string; + /** The list of contacts (users or leads) affected by this ticket. Currently only one is allowed */ + contacts: CreateTicketRequestBody.Contacts.Item[]; + /** + * The ID of the conversation you want to link to the ticket. Here are the valid ways of linking two tickets: + * - conversation | back-office ticket + * - customer tickets | non-shared back-office ticket + * - conversation | tracker ticket + * - customer ticket | tracker ticket + */ + conversation_to_link_id?: string; + /** The ID of the company that the ticket is associated with. The unique identifier for the company which is given by Intercom */ + company_id?: string; + /** The time the ticket was created. If not provided, the current time will be used. */ + created_at?: number; + assignment?: CreateTicketRequestBody.Assignment; +} + +export namespace CreateTicketRequestBody { + export type Contacts = Contacts.Item[]; + + export namespace Contacts { + export type Item = + | { + id: string; + } + | { + external_id: string; + } + | { + email: string; + }; + } + + export interface Assignment { + /** The ID of the admin to which the ticket is assigned. If not provided, the ticket will be unassigned. */ + admin_assignee_id?: string; + /** The ID of the team to which the ticket is assigned. If not provided, the ticket will be unassigned. */ + team_assignee_id?: string; + } +} diff --git a/src/api/resources/unstable/types/CursorPages.ts b/src/api/resources/unstable/types/CursorPages.ts new file mode 100644 index 00000000..b289ca72 --- /dev/null +++ b/src/api/resources/unstable/types/CursorPages.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Cursor-based pagination is a technique used in the Intercom API to navigate through large amounts of data. + * A "cursor" or pointer is used to keep track of the current position in the result set, allowing the API to return the data in small chunks or "pages" as needed. + */ +export interface CursorPages { + /** the type of object `pages`. */ + type?: "pages"; + /** The current page */ + page?: number; + next?: Intercom.unstable.StartingAfterPaging; + /** Number of results per page */ + per_page?: number; + /** Total number of pages */ + total_pages?: number; +} diff --git a/src/api/resources/unstable/types/CustomActionFinished.ts b/src/api/resources/unstable/types/CustomActionFinished.ts new file mode 100644 index 00000000..95484be5 --- /dev/null +++ b/src/api/resources/unstable/types/CustomActionFinished.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Contains details about final status of the completed action for conversation part type custom_action_finished. + */ +export interface CustomActionFinished { + action?: CustomActionFinished.Action; +} + +export namespace CustomActionFinished { + export interface Action { + /** Name of the action */ + name?: string; + /** Status of the action */ + result?: Action.Result; + } + + export namespace Action { + /** + * Status of the action + */ + export type Result = "success" | "failed"; + export const Result = { + Success: "success", + Failed: "failed", + } as const; + } +} diff --git a/src/api/resources/unstable/types/CustomActionStarted.ts b/src/api/resources/unstable/types/CustomActionStarted.ts new file mode 100644 index 00000000..eb089da6 --- /dev/null +++ b/src/api/resources/unstable/types/CustomActionStarted.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Contains details about name of the action that was initiated for conversation part type custom_action_started. + */ +export interface CustomActionStarted { + action?: CustomActionStarted.Action; +} + +export namespace CustomActionStarted { + export interface Action { + /** Name of the action */ + name?: string; + } +} diff --git a/src/api/resources/unstable/types/CustomAttributes.ts b/src/api/resources/unstable/types/CustomAttributes.ts new file mode 100644 index 00000000..1a8f52e6 --- /dev/null +++ b/src/api/resources/unstable/types/CustomAttributes.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * An object containing the different custom attributes associated to the conversation as key-value pairs. For relationship attributes the value will be a list of custom object instance models. + */ +export type CustomAttributes = Record; + +export namespace CustomAttributes { + export type Value = string | number | Intercom.unstable.Datetime | Intercom.unstable.CustomObjectInstanceList; +} diff --git a/src/api/resources/unstable/types/CustomChannelAttribute.ts b/src/api/resources/unstable/types/CustomChannelAttribute.ts new file mode 100644 index 00000000..1f5ffeb6 --- /dev/null +++ b/src/api/resources/unstable/types/CustomChannelAttribute.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface CustomChannelAttribute { + /** Identifier for the attribute being collected. */ + id: string; + /** Value provided by the user for the attribute. */ + value: string; +} diff --git a/src/api/resources/unstable/types/CustomChannelBaseEvent.ts b/src/api/resources/unstable/types/CustomChannelBaseEvent.ts new file mode 100644 index 00000000..16b7996e --- /dev/null +++ b/src/api/resources/unstable/types/CustomChannelBaseEvent.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +export interface CustomChannelBaseEvent { + /** Unique identifier for the event. */ + event_id: string; + /** Identifier for the conversation in your application. */ + external_conversation_id: string; + contact: Intercom.unstable.CustomChannelContact; +} diff --git a/src/api/resources/unstable/types/CustomChannelContact.ts b/src/api/resources/unstable/types/CustomChannelContact.ts new file mode 100644 index 00000000..e1e7eabc --- /dev/null +++ b/src/api/resources/unstable/types/CustomChannelContact.ts @@ -0,0 +1,25 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface CustomChannelContact { + /** Type of contact, must be "user" or "lead". */ + type: CustomChannelContact.Type; + /** External identifier for the contact. Intercom will take care of the mapping of your external_id with our internal ones so you don't have to worry about it. */ + external_id: string; + /** Name of the contact. */ + name: string; + /** Email address of the contact. */ + email: string; +} + +export namespace CustomChannelContact { + /** + * Type of contact, must be "user" or "lead". + */ + export type Type = "user" | "lead"; + export const Type = { + User: "user", + Lead: "lead", + } as const; +} diff --git a/src/api/resources/unstable/types/CustomChannelNotificationResponse.ts b/src/api/resources/unstable/types/CustomChannelNotificationResponse.ts new file mode 100644 index 00000000..ae5a5611 --- /dev/null +++ b/src/api/resources/unstable/types/CustomChannelNotificationResponse.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface CustomChannelNotificationResponse { + /** The external conversation ID provided in the notification request */ + external_conversation_id: string; + /** The Intercom conversation ID mapped to the external conversation ID */ + conversation_id: string; + /** The external contact ID provided in the notification request */ + external_contact_id: string; + /** The Intercom contact ID mapped to the external contact ID */ + contact_id: string; +} diff --git a/src/api/resources/unstable/types/CustomObjectInstanceDeleted.ts b/src/api/resources/unstable/types/CustomObjectInstanceDeleted.ts new file mode 100644 index 00000000..091e1ec4 --- /dev/null +++ b/src/api/resources/unstable/types/CustomObjectInstanceDeleted.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * deleted custom object instance object + */ +export interface CustomObjectInstanceDeleted { + /** The unique identifier of the Custom Object type that defines the structure of the Custom Object instance. */ + object?: string; + /** The Intercom defined id representing the Custom Object instance. */ + id?: string; + /** Whether the Custom Object instance is deleted or not. */ + deleted?: boolean; +} diff --git a/src/api/resources/unstable/types/CustomObjectInstanceList.ts b/src/api/resources/unstable/types/CustomObjectInstanceList.ts new file mode 100644 index 00000000..8bfd0ef2 --- /dev/null +++ b/src/api/resources/unstable/types/CustomObjectInstanceList.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * The list of associated custom object instances for a given reference attribute on the parent object. + */ +export interface CustomObjectInstanceList { + type?: string; + /** The list of associated custom object instances for a given reference attribute on the parent object. */ + instances?: (Intercom.unstable.CustomObjectInstance | undefined)[]; +} diff --git a/src/api/resources/unstable/types/CustomerRequest.ts b/src/api/resources/unstable/types/CustomerRequest.ts new file mode 100644 index 00000000..6ede7a3d --- /dev/null +++ b/src/api/resources/unstable/types/CustomerRequest.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type CustomerRequest = + | { + intercom_user_id: string; + } + | { + user_id: string; + } + | { + email: string; + }; diff --git a/src/api/resources/unstable/types/DataAttributeList.ts b/src/api/resources/unstable/types/DataAttributeList.ts new file mode 100644 index 00000000..5242a0bf --- /dev/null +++ b/src/api/resources/unstable/types/DataAttributeList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of all data attributes belonging to a workspace for contacts, companies or conversations. + */ +export interface DataAttributeList { + /** The type of the object */ + type?: "list"; + /** A list of data attributes */ + data?: Intercom.unstable.DataAttribute[]; +} diff --git a/src/api/resources/unstable/types/DataEventList.ts b/src/api/resources/unstable/types/DataEventList.ts new file mode 100644 index 00000000..09ed47e2 --- /dev/null +++ b/src/api/resources/unstable/types/DataEventList.ts @@ -0,0 +1,27 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * This will return a list of data events for the App. + */ +export interface DataEventList { + /** The type of the object */ + type?: "event.list"; + /** A list of data events */ + events?: Intercom.unstable.DataEvent[]; + /** Pagination */ + pages?: DataEventList.Pages; +} + +export namespace DataEventList { + /** + * Pagination + */ + export interface Pages { + next?: string; + since?: string; + } +} diff --git a/src/api/resources/unstable/types/DataEventSummary.ts b/src/api/resources/unstable/types/DataEventSummary.ts new file mode 100644 index 00000000..87791da0 --- /dev/null +++ b/src/api/resources/unstable/types/DataEventSummary.ts @@ -0,0 +1,21 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * This will return a summary of data events for the App. + */ +export interface DataEventSummary { + /** The type of the object */ + type?: "event.summary"; + /** The email address of the user */ + email?: string; + /** The Intercom user ID of the user */ + intercom_user_id?: string; + /** The user ID of the user */ + user_id?: string; + /** A summary of data events */ + events?: (Intercom.unstable.DataEventSummaryItem | undefined)[]; +} diff --git a/src/api/resources/unstable/types/DataEventSummaryItem.ts b/src/api/resources/unstable/types/DataEventSummaryItem.ts new file mode 100644 index 00000000..26f9e3a5 --- /dev/null +++ b/src/api/resources/unstable/types/DataEventSummaryItem.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * This will return a summary of a data event for the App. + */ +export interface DataEventSummaryItem { + /** The name of the event */ + name?: string; + /** The first time the event was sent */ + first?: string; + /** The last time the event was sent */ + last?: string; + /** The number of times the event was sent */ + count?: number; + /** The description of the event */ + description?: string; +} diff --git a/src/api/resources/unstable/types/DataExportCsv.ts b/src/api/resources/unstable/types/DataExportCsv.ts new file mode 100644 index 00000000..5cc3bea0 --- /dev/null +++ b/src/api/resources/unstable/types/DataExportCsv.ts @@ -0,0 +1,61 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A CSV output file + */ +export interface DataExportCsv { + /** The user_id of the user who was sent the message. */ + user_id?: string; + /** The external_user_id of the user who was sent the message */ + user_external_id?: string; + /** The company ID of the user in relation to the message that was sent. Will return -1 if no company is present. */ + company_id?: string; + /** The users email who was sent the message. */ + email?: string; + /** The full name of the user receiving the message */ + name?: string; + /** The id of the message. */ + ruleset_id?: string; + /** The specific content that was received. In an A/B test each version has its own Content ID. */ + content_id?: string; + /** Email, Chat, Post etc. */ + content_type?: string; + /** The title of the content you see in your Intercom workspace. */ + content_title?: string; + /** As you edit content we record new versions. This ID can help you determine which version of a piece of content that was received. */ + ruleset_version_id?: string; + /** ID for this receipt. Will be included with any related stats in other files to identify this specific delivery of a message. */ + receipt_id?: string; + /** Timestamp for when the receipt was recorded. */ + received_at?: number; + /** The id of the series that this content is part of. Will return -1 if not part of a series. */ + series_id?: string; + /** The title of the series that this content is part of. */ + series_title?: string; + /** The id of the series node that this ruleset is associated with. Each block in a series has a corresponding node_id. */ + node_id?: string; + /** The first time a user replied to this message if the content was able to receive replies. */ + first_reply?: number; + /** The first time a user completed this message if the content was able to be completed e.g. Tours, Surveys. */ + first_completion?: number; + /** The first time the series this message was a part of was completed by the user. */ + first_series_completion?: number; + /** The first time the series this message was a part of was disengaged by the user. */ + first_series_disengagement?: number; + /** The first time the series this message was a part of was exited by the user. */ + first_series_exit?: number; + /** The first time the user met this messages associated goal if one exists. */ + first_goal_success?: number; + /** The first time the user opened this message. */ + first_open?: number; + /** The first time the series the user clicked on a link within this message. */ + first_click?: number; + /** The first time the series the user dismissed this message. */ + first_dismisall?: number; + /** The first time the user unsubscribed from this message. */ + first_unsubscribe?: number; + /** The first time this message hard bounced for this user */ + first_hard_bounce?: number; +} diff --git a/src/api/resources/unstable/types/Datetime.ts b/src/api/resources/unstable/types/Datetime.ts new file mode 100644 index 00000000..c291e607 --- /dev/null +++ b/src/api/resources/unstable/types/Datetime.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type Datetime = + /** + * A date and time following the ISO8601 notation. */ + | string + /** + * A date and time as UNIX timestamp notation. */ + | number; diff --git a/src/api/resources/unstable/types/DeletedArticleObject.ts b/src/api/resources/unstable/types/DeletedArticleObject.ts new file mode 100644 index 00000000..2fb626a8 --- /dev/null +++ b/src/api/resources/unstable/types/DeletedArticleObject.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Response returned when an object is deleted + */ +export interface DeletedArticleObject { + /** The unique identifier for the article which you provided in the URL. */ + id?: string; + /** The type of object which was deleted. - article */ + object?: "article"; + /** Whether the article was deleted successfully or not. */ + deleted?: boolean; +} diff --git a/src/api/resources/unstable/types/DeletedCollectionObject.ts b/src/api/resources/unstable/types/DeletedCollectionObject.ts new file mode 100644 index 00000000..9f09babd --- /dev/null +++ b/src/api/resources/unstable/types/DeletedCollectionObject.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Response returned when an object is deleted + */ +export interface DeletedCollectionObject { + /** The unique identifier for the collection which you provided in the URL. */ + id?: string; + /** The type of object which was deleted. - `collection` */ + object?: "collection"; + /** Whether the collection was deleted successfully or not. */ + deleted?: boolean; +} diff --git a/src/api/resources/unstable/types/DeletedCompanyObject.ts b/src/api/resources/unstable/types/DeletedCompanyObject.ts new file mode 100644 index 00000000..f93f0699 --- /dev/null +++ b/src/api/resources/unstable/types/DeletedCompanyObject.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Response returned when an object is deleted + */ +export interface DeletedCompanyObject { + /** The unique identifier for the company which is given by Intercom. */ + id?: string; + /** The type of object which was deleted. - `company` */ + object?: "company"; + /** Whether the company was deleted successfully or not. */ + deleted?: boolean; +} diff --git a/src/api/resources/unstable/types/DeletedObject.ts b/src/api/resources/unstable/types/DeletedObject.ts new file mode 100644 index 00000000..613a0f83 --- /dev/null +++ b/src/api/resources/unstable/types/DeletedObject.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Response returned when an object is deleted + */ +export interface DeletedObject { + /** The unique identifier for the news item which you provided in the URL. */ + id?: string; + /** The type of object which was deleted - news-item. */ + object?: "news-item"; + /** Whether the news item was deleted successfully or not. */ + deleted?: boolean; +} diff --git a/src/api/resources/unstable/types/EmailAddressHeader.ts b/src/api/resources/unstable/types/EmailAddressHeader.ts new file mode 100644 index 00000000..81f30d02 --- /dev/null +++ b/src/api/resources/unstable/types/EmailAddressHeader.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Contains data for an email address header for a conversation part that was sent as an email. + */ +export interface EmailAddressHeader { + /** The type of email address header */ + type?: string; + /** The email address */ + email_address?: string; + /** The name associated with the email address */ + name?: string; +} diff --git a/src/api/resources/unstable/types/EmailMessageMetadata.ts b/src/api/resources/unstable/types/EmailMessageMetadata.ts new file mode 100644 index 00000000..6a407392 --- /dev/null +++ b/src/api/resources/unstable/types/EmailMessageMetadata.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Contains metadata if the message was sent as an email + */ +export interface EmailMessageMetadata { + /** The subject of the email */ + subject?: string; + /** A list of an email address headers. */ + email_address_headers?: Intercom.unstable.EmailAddressHeader[]; +} diff --git a/src/api/resources/unstable/types/Error_.ts b/src/api/resources/unstable/types/Error_.ts new file mode 100644 index 00000000..1526174a --- /dev/null +++ b/src/api/resources/unstable/types/Error_.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The API will return an Error List for a failed request, which will contain one or more Error objects. + */ +export interface Error_ { + /** The type is error.list */ + type: string; + /** */ + request_id?: string; + /** An array of one or more error objects */ + errors: Error_.Errors.Item[]; +} + +export namespace Error_ { + export type Errors = Errors.Item[]; + + export namespace Errors { + export interface Item { + /** A string indicating the kind of error, used to further qualify the HTTP response code */ + code: string; + /** Optional. Human readable description of the error. */ + message?: string; + /** Optional. Used to identify a particular field or query parameter that was in error. */ + field?: string; + } + } +} diff --git a/src/api/resources/unstable/types/EventDetails.ts b/src/api/resources/unstable/types/EventDetails.ts new file mode 100644 index 00000000..a5bddd05 --- /dev/null +++ b/src/api/resources/unstable/types/EventDetails.ts @@ -0,0 +1,12 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +export type EventDetails = + | Intercom.unstable.ConversationAttributeUpdatedByWorkflow + | Intercom.unstable.ConversationAttributeUpdatedByAdmin + | Intercom.unstable.CustomActionStarted + | Intercom.unstable.CustomActionFinished + | Intercom.unstable.OperatorWorkflowEvent; diff --git a/src/api/resources/unstable/types/FileAttribute.ts b/src/api/resources/unstable/types/FileAttribute.ts new file mode 100644 index 00000000..e0c5f023 --- /dev/null +++ b/src/api/resources/unstable/types/FileAttribute.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The value describing a file upload set for a custom attribute + */ +export interface FileAttribute { + type?: string; + /** The name of the file */ + name?: string; + /** The url of the file. This is a temporary URL and will expire after 30 minutes. */ + url?: string; + /** The type of file */ + content_type?: string; + /** The size of the file in bytes */ + filesize?: number; + /** The width of the file in pixels, if applicable */ + width?: number; + /** The height of the file in pixels, if applicable */ + height?: number; +} diff --git a/src/api/resources/unstable/types/GroupContent.ts b/src/api/resources/unstable/types/GroupContent.ts new file mode 100644 index 00000000..a7fb4506 --- /dev/null +++ b/src/api/resources/unstable/types/GroupContent.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The Content of a Group. + */ +export interface GroupContent { + /** The type of object - `group_content` . */ + type?: string; + /** The name of the collection or section. */ + name?: string; + /** The description of the collection. Only available for collections. */ + description?: string; +} diff --git a/src/api/resources/unstable/types/GroupTranslatedContent.ts b/src/api/resources/unstable/types/GroupTranslatedContent.ts new file mode 100644 index 00000000..5df6fde7 --- /dev/null +++ b/src/api/resources/unstable/types/GroupTranslatedContent.ts @@ -0,0 +1,87 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * The Translated Content of an Group. The keys are the locale codes and the values are the translated content of the Group. + */ +export interface GroupTranslatedContent { + /** The type of object - group_translated_content. */ + type?: string; + /** The content of the group in Arabic */ + ar?: Intercom.unstable.GroupContent; + /** The content of the group in Bulgarian */ + bg?: Intercom.unstable.GroupContent; + /** The content of the group in Bosnian */ + bs?: Intercom.unstable.GroupContent; + /** The content of the group in Catalan */ + ca?: Intercom.unstable.GroupContent; + /** The content of the group in Czech */ + cs?: Intercom.unstable.GroupContent; + /** The content of the group in Danish */ + da?: Intercom.unstable.GroupContent; + /** The content of the group in German */ + de?: Intercom.unstable.GroupContent; + /** The content of the group in Greek */ + el?: Intercom.unstable.GroupContent; + /** The content of the group in English */ + en?: Intercom.unstable.GroupContent; + /** The content of the group in Spanish */ + es?: Intercom.unstable.GroupContent; + /** The content of the group in Estonian */ + et?: Intercom.unstable.GroupContent; + /** The content of the group in Finnish */ + fi?: Intercom.unstable.GroupContent; + /** The content of the group in French */ + fr?: Intercom.unstable.GroupContent; + /** The content of the group in Hebrew */ + he?: Intercom.unstable.GroupContent; + /** The content of the group in Croatian */ + hr?: Intercom.unstable.GroupContent; + /** The content of the group in Hungarian */ + hu?: Intercom.unstable.GroupContent; + /** The content of the group in Indonesian */ + id?: Intercom.unstable.GroupContent; + /** The content of the group in Italian */ + it?: Intercom.unstable.GroupContent; + /** The content of the group in Japanese */ + ja?: Intercom.unstable.GroupContent; + /** The content of the group in Korean */ + ko?: Intercom.unstable.GroupContent; + /** The content of the group in Lithuanian */ + lt?: Intercom.unstable.GroupContent; + /** The content of the group in Latvian */ + lv?: Intercom.unstable.GroupContent; + /** The content of the group in Mongolian */ + mn?: Intercom.unstable.GroupContent; + /** The content of the group in Norwegian */ + nb?: Intercom.unstable.GroupContent; + /** The content of the group in Dutch */ + nl?: Intercom.unstable.GroupContent; + /** The content of the group in Polish */ + pl?: Intercom.unstable.GroupContent; + /** The content of the group in Portuguese (Portugal) */ + pt?: Intercom.unstable.GroupContent; + /** The content of the group in Romanian */ + ro?: Intercom.unstable.GroupContent; + /** The content of the group in Russian */ + ru?: Intercom.unstable.GroupContent; + /** The content of the group in Slovenian */ + sl?: Intercom.unstable.GroupContent; + /** The content of the group in Serbian */ + sr?: Intercom.unstable.GroupContent; + /** The content of the group in Swedish */ + sv?: Intercom.unstable.GroupContent; + /** The content of the group in Turkish */ + tr?: Intercom.unstable.GroupContent; + /** The content of the group in Vietnamese */ + vi?: Intercom.unstable.GroupContent; + /** The content of the group in Portuguese (Brazil) */ + "pt-BR"?: Intercom.unstable.GroupContent; + /** The content of the group in Chinese (China) */ + "zh-CN"?: Intercom.unstable.GroupContent; + /** The content of the group in Chinese (Taiwan) */ + "zh-TW"?: Intercom.unstable.GroupContent; +} diff --git a/src/api/resources/unstable/types/IntercomVersion.ts b/src/api/resources/unstable/types/IntercomVersion.ts new file mode 100644 index 00000000..921f8ae6 --- /dev/null +++ b/src/api/resources/unstable/types/IntercomVersion.ts @@ -0,0 +1,46 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Intercom API version.
By default, it's equal to the version set in the app package. + */ +export type IntercomVersion = + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "Unstable"; +export const IntercomVersion = { + One0: "1.0", + One1: "1.1", + One2: "1.2", + One3: "1.3", + One4: "1.4", + Two0: "2.0", + Two1: "2.1", + Two2: "2.2", + Two3: "2.3", + Two4: "2.4", + Two5: "2.5", + Two6: "2.6", + Two7: "2.7", + Two8: "2.8", + Two9: "2.9", + Two10: "2.10", + Two11: "2.11", + Unstable: "Unstable", +} as const; diff --git a/src/api/resources/unstable/types/IntercomVersionUnstable.ts b/src/api/resources/unstable/types/IntercomVersionUnstable.ts new file mode 100644 index 00000000..1bbcf600 --- /dev/null +++ b/src/api/resources/unstable/types/IntercomVersionUnstable.ts @@ -0,0 +1,8 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Unstable Intercom API version. Used for closed beta endpoints. + */ +export type IntercomVersionUnstable = "unstable"; diff --git a/src/api/resources/unstable/types/LinkedObject.ts b/src/api/resources/unstable/types/LinkedObject.ts new file mode 100644 index 00000000..d7eaf21d --- /dev/null +++ b/src/api/resources/unstable/types/LinkedObject.ts @@ -0,0 +1,26 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A linked conversation or ticket. + */ +export interface LinkedObject { + /** ticket or conversation */ + type?: LinkedObject.Type; + /** The ID of the linked object */ + id?: string; + /** Category of the Linked Ticket Object. */ + category?: string; +} + +export namespace LinkedObject { + /** + * ticket or conversation + */ + export type Type = "ticket" | "conversation"; + export const Type = { + Ticket: "ticket", + Conversation: "conversation", + } as const; +} diff --git a/src/api/resources/unstable/types/LinkedObjectList.ts b/src/api/resources/unstable/types/LinkedObjectList.ts new file mode 100644 index 00000000..8a95b96a --- /dev/null +++ b/src/api/resources/unstable/types/LinkedObjectList.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * An object containing metadata about linked conversations and linked tickets. Up to 1000 can be returned. + */ +export interface LinkedObjectList { + /** Always list. */ + type?: "list"; + /** The total number of linked objects. */ + total_count?: number; + /** Whether or not there are more linked objects than returned. */ + has_more?: boolean; + /** An array containing the linked conversations and linked tickets. */ + data?: Intercom.unstable.LinkedObject[]; +} diff --git a/src/api/resources/unstable/types/MultipleFilterSearchRequest.ts b/src/api/resources/unstable/types/MultipleFilterSearchRequest.ts new file mode 100644 index 00000000..9f184175 --- /dev/null +++ b/src/api/resources/unstable/types/MultipleFilterSearchRequest.ts @@ -0,0 +1,32 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Search using Intercoms Search APIs with more than one filter. + */ +export interface MultipleFilterSearchRequest { + /** An operator to allow boolean inspection between multiple fields. */ + operator?: MultipleFilterSearchRequest.Operator; + value?: MultipleFilterSearchRequest.Value; +} + +export namespace MultipleFilterSearchRequest { + /** + * An operator to allow boolean inspection between multiple fields. + */ + export type Operator = "AND" | "OR"; + export const Operator = { + And: "AND", + Or: "OR", + } as const; + export type Value = + /** + * Add mutiple filters. */ + | Intercom.unstable.MultipleFilterSearchRequest[] + /** + * Add a single filter field. */ + | Intercom.unstable.SingleFilterSearchRequest[]; +} diff --git a/src/api/resources/unstable/types/NewsItemRequest.ts b/src/api/resources/unstable/types/NewsItemRequest.ts new file mode 100644 index 00000000..3e3791a2 --- /dev/null +++ b/src/api/resources/unstable/types/NewsItemRequest.ts @@ -0,0 +1,38 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A News Item is a content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers. + */ +export interface NewsItemRequest { + /** The title of the news item. */ + title: string; + /** The news item body, which may contain HTML. */ + body?: string; + /** The id of the sender of the news item. Must be a teammate on the workspace. */ + sender_id: number; + /** News items will not be visible to your users in the assigned newsfeeds until they are set live. */ + state?: NewsItemRequest.State; + /** When set to `true`, the news item will appear in the messenger newsfeed without showing a notification badge. */ + deliver_silently?: boolean; + /** Label names displayed to users to categorize the news item. */ + labels?: string[]; + /** Ordered list of emoji reactions to the news item. When empty, reactions are disabled. */ + reactions?: (string | undefined)[]; + /** A list of newsfeed_assignments to assign to the specified newsfeed. */ + newsfeed_assignments?: Intercom.unstable.NewsfeedAssignment[]; +} + +export namespace NewsItemRequest { + /** + * News items will not be visible to your users in the assigned newsfeeds until they are set live. + */ + export type State = "draft" | "live"; + export const State = { + Draft: "draft", + Live: "live", + } as const; +} diff --git a/src/api/resources/unstable/types/NotFoundErrorBody.ts b/src/api/resources/unstable/types/NotFoundErrorBody.ts new file mode 100644 index 00000000..0893b81e --- /dev/null +++ b/src/api/resources/unstable/types/NotFoundErrorBody.ts @@ -0,0 +1,25 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface NotFoundErrorBody { + /** The type is error.list */ + type: string; + /** */ + request_id?: string; + /** An array of one or more error objects */ + errors: NotFoundErrorBody.Errors.Item[]; +} + +export namespace NotFoundErrorBody { + export type Errors = Errors.Item[]; + + export namespace Errors { + export interface Item { + /** ticket_not_found */ + code: string; + /** Ticket not found */ + message?: string; + } + } +} diff --git a/src/api/resources/unstable/types/NoteList.ts b/src/api/resources/unstable/types/NoteList.ts new file mode 100644 index 00000000..162d648f --- /dev/null +++ b/src/api/resources/unstable/types/NoteList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A paginated list of notes associated with a contact. + */ +export interface NoteList { + /** String representing the object's type. Always has the value `list`. */ + type?: string; + /** An array of notes. */ + data?: Intercom.unstable.Note[]; + /** A count of the total number of notes. */ + total_count?: number; + pages?: Intercom.unstable.CursorPages; +} diff --git a/src/api/resources/unstable/types/OpenConversationRequest.ts b/src/api/resources/unstable/types/OpenConversationRequest.ts new file mode 100644 index 00000000..682699e3 --- /dev/null +++ b/src/api/resources/unstable/types/OpenConversationRequest.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Payload of the request to open a conversation + */ +export interface OpenConversationRequest { + /** The id of the admin who is performing the action. */ + admin_id: string; +} diff --git a/src/api/resources/unstable/types/OperatorWorkflowEvent.ts b/src/api/resources/unstable/types/OperatorWorkflowEvent.ts new file mode 100644 index 00000000..336b4885 --- /dev/null +++ b/src/api/resources/unstable/types/OperatorWorkflowEvent.ts @@ -0,0 +1,25 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Contains details about name of the workflow for conversation part type operator_workflow_event. + */ +export interface OperatorWorkflowEvent { + workflow?: OperatorWorkflowEvent.Workflow; + event?: OperatorWorkflowEvent.Event; +} + +export namespace OperatorWorkflowEvent { + export interface Workflow { + /** The name of the workflow */ + name?: string; + } + + export interface Event { + /** Type of the workflow event initiated */ + type?: string; + /** Result of the workflow event */ + result?: string; + } +} diff --git a/src/api/resources/unstable/types/PagesLink.ts b/src/api/resources/unstable/types/PagesLink.ts new file mode 100644 index 00000000..4dd36d75 --- /dev/null +++ b/src/api/resources/unstable/types/PagesLink.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The majority of list resources in the API are paginated to allow clients to traverse data over multiple requests. + * + * Their responses are likely to contain a pages object that hosts pagination links which a client can use to paginate through the data without having to construct a query. The link relations for the pages field are as follows. + */ +export interface PagesLink { + type?: "pages"; + page?: number; + /** A link to the next page of results. A response that does not contain a next link does not have further data to fetch. */ + next?: string; + per_page?: number; + total_pages?: number; +} diff --git a/src/api/resources/unstable/types/PaginatedResponse.ts b/src/api/resources/unstable/types/PaginatedResponse.ts new file mode 100644 index 00000000..af97a516 --- /dev/null +++ b/src/api/resources/unstable/types/PaginatedResponse.ts @@ -0,0 +1,29 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Paginated Response + */ +export interface PaginatedResponse { + /** The type of object */ + type?: PaginatedResponse.Type; + pages?: Intercom.unstable.CursorPages; + /** A count of the total number of objects. */ + total_count?: number; + /** An array of Objects */ + data?: Intercom.unstable.PaginatedResponseDataItem[]; +} + +export namespace PaginatedResponse { + /** + * The type of object + */ + export type Type = "list" | "conversation.list"; + export const Type = { + List: "list", + ConversationList: "conversation.list", + } as const; +} diff --git a/src/api/resources/unstable/types/PaginatedResponseDataItem.ts b/src/api/resources/unstable/types/PaginatedResponseDataItem.ts new file mode 100644 index 00000000..fc09f5f8 --- /dev/null +++ b/src/api/resources/unstable/types/PaginatedResponseDataItem.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +export type PaginatedResponseDataItem = + | Intercom.unstable.PaginatedResponseDataItem.NewsItem + | Intercom.unstable.PaginatedResponseDataItem.Newsfeed; + +export namespace PaginatedResponseDataItem { + export interface NewsItem extends Intercom.unstable.NewsItem { + type: "news-item"; + } + + export interface Newsfeed extends Intercom.unstable.Newsfeed { + type: "newsfeed"; + } +} diff --git a/src/api/resources/unstable/types/PartAttachment.ts b/src/api/resources/unstable/types/PartAttachment.ts new file mode 100644 index 00000000..690152f9 --- /dev/null +++ b/src/api/resources/unstable/types/PartAttachment.ts @@ -0,0 +1,23 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The file attached to a part + */ +export interface PartAttachment { + /** The type of attachment */ + type?: string; + /** The name of the attachment */ + name?: string; + /** The URL of the attachment */ + url?: string; + /** The content type of the attachment */ + content_type?: string; + /** The size of the attachment */ + filesize?: number; + /** The width of the attachment */ + width?: number; + /** The height of the attachment */ + height?: number; +} diff --git a/src/api/resources/unstable/types/PhoneSwitch.ts b/src/api/resources/unstable/types/PhoneSwitch.ts new file mode 100644 index 00000000..3e6aad44 --- /dev/null +++ b/src/api/resources/unstable/types/PhoneSwitch.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Phone Switch Response + */ +export interface PhoneSwitch { + /** */ + type?: "phone_call_redirect"; + /** Phone number in E.164 format, that has received the SMS to continue the conversation in the Messenger. */ + phone?: string; +} diff --git a/src/api/resources/unstable/types/QuickReplyOption.ts b/src/api/resources/unstable/types/QuickReplyOption.ts new file mode 100644 index 00000000..379777e5 --- /dev/null +++ b/src/api/resources/unstable/types/QuickReplyOption.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface QuickReplyOption { + /** The text to display in this quick reply option. */ + text: string; + /** A unique identifier for this quick reply option. This value will be available within the metadata of the comment conversation part that is created when a user clicks on this reply option. */ + uuid: string; +} diff --git a/src/api/resources/unstable/types/Recipient.ts b/src/api/resources/unstable/types/Recipient.ts new file mode 100644 index 00000000..25e28bb9 --- /dev/null +++ b/src/api/resources/unstable/types/Recipient.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A recipient of a message + */ +export interface Recipient { + /** The role associated to the contact - `user` or `lead`. */ + type: Recipient.Type; + /** The identifier for the contact which is given by Intercom. */ + id: string; +} + +export namespace Recipient { + /** + * The role associated to the contact - `user` or `lead`. + */ + export type Type = "user" | "lead"; + export const Type = { + User: "user", + Lead: "lead", + } as const; +} diff --git a/src/api/resources/unstable/types/RedactConversationRequest.ts b/src/api/resources/unstable/types/RedactConversationRequest.ts new file mode 100644 index 00000000..968bb6af --- /dev/null +++ b/src/api/resources/unstable/types/RedactConversationRequest.ts @@ -0,0 +1,31 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +export type RedactConversationRequest = + /** + * Payload of the request to redact a conversation part */ + | Intercom.unstable.RedactConversationRequest.ConversationPart + /** + * Payload of the request to redact a conversation source */ + | Intercom.unstable.RedactConversationRequest.Source; + +export namespace RedactConversationRequest { + export interface ConversationPart { + type: "conversation_part"; + /** The id of the conversation. */ + conversation_id: string; + /** The id of the conversation_part. */ + conversation_part_id: string; + } + + export interface Source { + type: "source"; + /** The id of the conversation. */ + conversation_id: string; + /** The id of the source. */ + source_id: string; + } +} diff --git a/src/api/resources/unstable/types/Reference.ts b/src/api/resources/unstable/types/Reference.ts new file mode 100644 index 00000000..b14f584f --- /dev/null +++ b/src/api/resources/unstable/types/Reference.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * reference to another object + */ +export interface Reference { + /** */ + type?: string; + /** */ + id?: string; +} diff --git a/src/api/resources/unstable/types/ReplyConversationRequestBody.ts b/src/api/resources/unstable/types/ReplyConversationRequestBody.ts new file mode 100644 index 00000000..261d4f73 --- /dev/null +++ b/src/api/resources/unstable/types/ReplyConversationRequestBody.ts @@ -0,0 +1,9 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +export type ReplyConversationRequestBody = + | Intercom.unstable.ContactReplyConversationRequest + | Intercom.unstable.AdminReplyConversationRequest; diff --git a/src/api/resources/unstable/types/SearchRequest.ts b/src/api/resources/unstable/types/SearchRequest.ts new file mode 100644 index 00000000..7dc82a61 --- /dev/null +++ b/src/api/resources/unstable/types/SearchRequest.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Search using Intercoms Search APIs. + */ +export interface SearchRequest { + query: SearchRequest.Query; + pagination?: Intercom.unstable.StartingAfterPaging; +} + +export namespace SearchRequest { + export type Query = Intercom.unstable.SingleFilterSearchRequest | Intercom.unstable.MultipleFilterSearchRequest; +} diff --git a/src/api/resources/unstable/types/SegmentList.ts b/src/api/resources/unstable/types/SegmentList.ts new file mode 100644 index 00000000..22f29cc3 --- /dev/null +++ b/src/api/resources/unstable/types/SegmentList.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * This will return a list of Segment Objects. The result may also have a pages object if the response is paginated. + */ +export interface SegmentList { + /** The type of the object */ + type?: "segment.list"; + /** A list of Segment objects */ + segments?: Intercom.unstable.Segment[]; + /** A pagination object, which may be empty, indicating no further pages to fetch. */ + pages?: Record; +} diff --git a/src/api/resources/unstable/types/SingleFilterSearchRequest.ts b/src/api/resources/unstable/types/SingleFilterSearchRequest.ts new file mode 100644 index 00000000..1d1e1613 --- /dev/null +++ b/src/api/resources/unstable/types/SingleFilterSearchRequest.ts @@ -0,0 +1,34 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Search using Intercoms Search APIs with a single filter. + */ +export interface SingleFilterSearchRequest { + /** The accepted field that you want to search on. */ + field?: string; + /** The accepted operators you can use to define how you want to search for the value. */ + operator?: SingleFilterSearchRequest.Operator; + /** The value that you want to search on. */ + value?: SingleFilterSearchRequest.Value; +} + +export namespace SingleFilterSearchRequest { + /** + * The accepted operators you can use to define how you want to search for the value. + */ + export type Operator = "=" | "!=" | "IN" | "NIN" | "<" | ">"; + export const Operator = { + EqualTo: "=", + NotEquals: "!=", + In: "IN", + Nin: "NIN", + LessThan: "<", + GreaterThan: ">", + } as const; + /** + * The value that you want to search on. + */ + export type Value = string | number | (string | number)[]; +} diff --git a/src/api/resources/unstable/types/SlaApplied.ts b/src/api/resources/unstable/types/SlaApplied.ts new file mode 100644 index 00000000..1a7049bb --- /dev/null +++ b/src/api/resources/unstable/types/SlaApplied.ts @@ -0,0 +1,37 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The SLA Applied object contains the details for which SLA has been applied to this conversation. + * Important: if there are any canceled sla_events for the conversation - meaning an SLA has been manually removed from a conversation, the sla_status will always be returned as null. + */ +export interface SlaApplied { + /** object type */ + type?: string; + /** The name of the SLA as given by the teammate when it was created. */ + sla_name?: string; + /** + * SLA statuses: + * - `hit`: If there’s at least one hit event in the underlying sla_events table, and no “missed” or “canceled” events for the conversation. + * - `missed`: If there are any missed sla_events for the conversation and no canceled events. If there’s even a single missed sla event, the status will always be missed. A missed status is not applied when the SLA expires, only the next time a teammate replies. + * - `active`: An SLA has been applied to a conversation, but has not yet been fulfilled. SLA status is active only if there are no “hit, “missed”, or “canceled” events. + */ + sla_status?: SlaApplied.SlaStatus; +} + +export namespace SlaApplied { + /** + * SLA statuses: + * - `hit`: If there’s at least one hit event in the underlying sla_events table, and no “missed” or “canceled” events for the conversation. + * - `missed`: If there are any missed sla_events for the conversation and no canceled events. If there’s even a single missed sla event, the status will always be missed. A missed status is not applied when the SLA expires, only the next time a teammate replies. + * - `active`: An SLA has been applied to a conversation, but has not yet been fulfilled. SLA status is active only if there are no “hit, “missed”, or “canceled” events. + */ + export type SlaStatus = "hit" | "missed" | "cancelled" | "active"; + export const SlaStatus = { + Hit: "hit", + Missed: "missed", + Cancelled: "cancelled", + Active: "active", + } as const; +} diff --git a/src/api/resources/unstable/types/SnoozeConversationRequest.ts b/src/api/resources/unstable/types/SnoozeConversationRequest.ts new file mode 100644 index 00000000..25429753 --- /dev/null +++ b/src/api/resources/unstable/types/SnoozeConversationRequest.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Payload of the request to snooze a conversation + */ +export interface SnoozeConversationRequest { + /** The id of the admin who is performing the action. */ + admin_id: string; + /** The time you want the conversation to reopen. */ + snoozed_until: number; +} diff --git a/src/api/resources/unstable/types/SocialProfile.ts b/src/api/resources/unstable/types/SocialProfile.ts new file mode 100644 index 00000000..3598c433 --- /dev/null +++ b/src/api/resources/unstable/types/SocialProfile.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A Social Profile allows you to label your contacts, companies, and conversations and list them using that Social Profile. + */ +export interface SocialProfile { + /** value is "social_profile" */ + type?: string; + /** The name of the Social media profile */ + name?: string; + /** The name of the Social media profile */ + url?: string; +} diff --git a/src/api/resources/unstable/types/StartingAfterPaging.ts b/src/api/resources/unstable/types/StartingAfterPaging.ts new file mode 100644 index 00000000..e2d31e3f --- /dev/null +++ b/src/api/resources/unstable/types/StartingAfterPaging.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface StartingAfterPaging { + /** The number of results to fetch per page. */ + per_page?: number; + /** The cursor to use in the next request to get the next page of results. */ + starting_after?: string; +} diff --git a/src/api/resources/unstable/types/SubscriptionTypeList.ts b/src/api/resources/unstable/types/SubscriptionTypeList.ts new file mode 100644 index 00000000..3aa55e5c --- /dev/null +++ b/src/api/resources/unstable/types/SubscriptionTypeList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of subscription type objects. + */ +export interface SubscriptionTypeList { + /** The type of the object */ + type?: "list"; + /** A list of subscription type objects associated with the workspace . */ + data?: Intercom.unstable.SubscriptionType[]; +} diff --git a/src/api/resources/unstable/types/TagCompanyRequest.ts b/src/api/resources/unstable/types/TagCompanyRequest.ts new file mode 100644 index 00000000..23231949 --- /dev/null +++ b/src/api/resources/unstable/types/TagCompanyRequest.ts @@ -0,0 +1,26 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * You can tag a single company or a list of companies. + */ +export interface TagCompanyRequest { + /** The name of the tag, which will be created if not found. */ + name: string; + /** The id or company_id of the company can be passed as input parameters. */ + companies: TagCompanyRequest.Companies.Item[]; +} + +export namespace TagCompanyRequest { + export type Companies = Companies.Item[]; + + export namespace Companies { + export interface Item { + /** The Intercom defined id representing the company. */ + id?: string; + /** The company id you have defined for the company. */ + company_id?: string; + } + } +} diff --git a/src/api/resources/unstable/types/TagList.ts b/src/api/resources/unstable/types/TagList.ts new file mode 100644 index 00000000..f42df4b4 --- /dev/null +++ b/src/api/resources/unstable/types/TagList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of tags objects in the workspace. + */ +export interface TagList { + /** The type of the object */ + type?: "list"; + /** A list of tags objects associated with the workspace . */ + data?: Intercom.unstable.Tag[]; +} diff --git a/src/api/resources/unstable/types/TagMultipleUsersRequest.ts b/src/api/resources/unstable/types/TagMultipleUsersRequest.ts new file mode 100644 index 00000000..df2f72b2 --- /dev/null +++ b/src/api/resources/unstable/types/TagMultipleUsersRequest.ts @@ -0,0 +1,23 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * You can tag a list of users. + */ +export interface TagMultipleUsersRequest { + /** The name of the tag, which will be created if not found. */ + name: string; + users: TagMultipleUsersRequest.Users.Item[]; +} + +export namespace TagMultipleUsersRequest { + export type Users = Users.Item[]; + + export namespace Users { + export interface Item { + /** The Intercom defined id representing the user. */ + id?: string; + } + } +} diff --git a/src/api/resources/unstable/types/Tags.ts b/src/api/resources/unstable/types/Tags.ts new file mode 100644 index 00000000..980aba63 --- /dev/null +++ b/src/api/resources/unstable/types/Tags.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of tags objects associated with a conversation + */ +export interface Tags { + /** The type of the object */ + type?: "tag.list"; + /** A list of tags objects associated with the conversation. */ + tags?: Intercom.unstable.Tag[]; +} diff --git a/src/api/resources/unstable/types/TeamList.ts b/src/api/resources/unstable/types/TeamList.ts new file mode 100644 index 00000000..6728f16f --- /dev/null +++ b/src/api/resources/unstable/types/TeamList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * This will return a list of team objects for the App. + */ +export interface TeamList { + /** The type of the object */ + type?: "team.list"; + /** A list of team objects */ + teams?: Intercom.unstable.Team[]; +} diff --git a/src/api/resources/unstable/types/TeamPriorityLevel.ts b/src/api/resources/unstable/types/TeamPriorityLevel.ts new file mode 100644 index 00000000..b979fa1d --- /dev/null +++ b/src/api/resources/unstable/types/TeamPriorityLevel.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Admin priority levels for teams + */ +export interface TeamPriorityLevel { + /** The primary team ids for the team */ + primary_team_ids?: number[]; + /** The secondary team ids for the team */ + secondary_team_ids?: number[]; +} diff --git a/src/api/resources/unstable/types/TicketCustomAttributes.ts b/src/api/resources/unstable/types/TicketCustomAttributes.ts new file mode 100644 index 00000000..50eb281d --- /dev/null +++ b/src/api/resources/unstable/types/TicketCustomAttributes.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * An object containing the different attributes associated to the ticket as key-value pairs. For the default title and description attributes, the keys are `_default_title_` and `_default_description_`. + */ +export type TicketCustomAttributes = Record; + +export namespace TicketCustomAttributes { + export type Value = string | undefined | number | boolean | unknown[] | Intercom.unstable.FileAttribute; +} diff --git a/src/api/resources/unstable/types/TicketList.ts b/src/api/resources/unstable/types/TicketList.ts new file mode 100644 index 00000000..0457d26e --- /dev/null +++ b/src/api/resources/unstable/types/TicketList.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Tickets are how you track requests from your users. + */ +export interface TicketList { + /** Always ticket.list */ + type?: "ticket.list"; + /** The list of ticket objects */ + tickets?: (Intercom.unstable.Ticket | undefined)[]; + /** A count of the total number of objects. */ + total_count?: number; + pages?: Intercom.unstable.CursorPages; +} diff --git a/src/api/resources/unstable/types/TicketPartAuthor.ts b/src/api/resources/unstable/types/TicketPartAuthor.ts new file mode 100644 index 00000000..6dc2eb3b --- /dev/null +++ b/src/api/resources/unstable/types/TicketPartAuthor.ts @@ -0,0 +1,30 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The author that wrote or triggered the part. Can be a bot, admin, team or user. + */ +export interface TicketPartAuthor { + /** The type of the author */ + type?: TicketPartAuthor.Type; + /** The id of the author */ + id?: string; + /** The name of the author */ + name?: string; + /** The email of the author */ + email?: string; +} + +export namespace TicketPartAuthor { + /** + * The type of the author + */ + export type Type = "admin" | "bot" | "team" | "user"; + export const Type = { + Admin: "admin", + Bot: "bot", + Team: "team", + User: "user", + } as const; +} diff --git a/src/api/resources/unstable/types/TicketParts.ts b/src/api/resources/unstable/types/TicketParts.ts new file mode 100644 index 00000000..f4847b22 --- /dev/null +++ b/src/api/resources/unstable/types/TicketParts.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of Ticket Part objects for each note and event in the ticket. There is a limit of 500 parts. + */ +export interface TicketParts { + /** */ + type?: "ticket_part.list"; + /** A list of Ticket Part objects for each ticket. There is a limit of 500 parts. */ + ticket_parts?: Intercom.unstable.TicketPart[]; + /** */ + total_count?: number; +} diff --git a/src/api/resources/unstable/types/TicketReply.ts b/src/api/resources/unstable/types/TicketReply.ts new file mode 100644 index 00000000..d1e66754 --- /dev/null +++ b/src/api/resources/unstable/types/TicketReply.ts @@ -0,0 +1,40 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A Ticket Part representing a note, comment, or quick_reply on a ticket + */ +export interface TicketReply { + /** Always ticket_part */ + type?: "ticket_part"; + /** The id representing the part. */ + id?: string; + /** Type of the part */ + part_type?: TicketReply.PartType; + /** The message body, which may contain HTML. */ + body?: string; + /** The time the note was created. */ + created_at?: number; + /** The last time the note was updated. */ + updated_at?: number; + author?: Intercom.unstable.TicketPartAuthor; + /** A list of attachments for the part. */ + attachments?: Intercom.unstable.PartAttachment[]; + /** Whether or not the ticket part has been redacted. */ + redacted?: boolean; +} + +export namespace TicketReply { + /** + * Type of the part + */ + export type PartType = "note" | "comment" | "quick_reply"; + export const PartType = { + Note: "note", + Comment: "comment", + QuickReply: "quick_reply", + } as const; +} diff --git a/src/api/resources/unstable/types/TicketRequestCustomAttributes.ts b/src/api/resources/unstable/types/TicketRequestCustomAttributes.ts new file mode 100644 index 00000000..6a3af042 --- /dev/null +++ b/src/api/resources/unstable/types/TicketRequestCustomAttributes.ts @@ -0,0 +1,12 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The attributes set on the ticket. When setting the default title and description attributes, the attribute keys that should be used are `_default_title_` and `_default_description_`. When setting ticket type attributes of the list attribute type, the key should be the attribute name and the value of the attribute should be the list item id, obtainable by [listing the ticket type](ref:get_ticket-types). For example, if the ticket type has an attribute called `priority` of type `list`, the key should be `priority` and the value of the attribute should be the guid of the list item (e.g. `de1825a0-0164-4070-8ca6-13e22462fa7e`). + */ +export type TicketRequestCustomAttributes = Record; + +export namespace TicketRequestCustomAttributes { + export type Value = string | undefined | number | boolean | unknown[]; +} diff --git a/src/api/resources/unstable/types/TicketStateList.ts b/src/api/resources/unstable/types/TicketStateList.ts new file mode 100644 index 00000000..7e3bfbe6 --- /dev/null +++ b/src/api/resources/unstable/types/TicketStateList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of ticket states associated with a given ticket type. + */ +export interface TicketStateList { + /** String representing the object's type. Always has the value `list`. */ + type?: string; + /** A list of ticket states associated with a given ticket type. */ + data?: (Intercom.unstable.TicketStateDetailed | undefined)[]; +} diff --git a/src/api/resources/unstable/types/TicketTypeAttribute.ts b/src/api/resources/unstable/types/TicketTypeAttribute.ts new file mode 100644 index 00000000..269e5f99 --- /dev/null +++ b/src/api/resources/unstable/types/TicketTypeAttribute.ts @@ -0,0 +1,43 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Ticket type attribute, used to define each data field to be captured in a ticket. + */ +export interface TicketTypeAttribute { + /** String representing the object's type. Always has the value `ticket_type_attribute`. */ + type?: string; + /** The id representing the ticket type attribute. */ + id?: string; + /** The id of the workspace that the ticket type attribute belongs to. */ + workspace_id?: string; + /** The name of the ticket type attribute */ + name?: string; + /** The description of the ticket type attribute */ + description?: string; + /** The type of the data attribute (allowed values: "string list integer decimal boolean datetime files") */ + data_type?: string; + /** Input options for the attribute */ + input_options?: Record; + /** The order of the attribute against other attributes */ + order?: number; + /** Whether the attribute is required or not for teammates. */ + required_to_create?: boolean; + /** Whether the attribute is required or not for contacts. */ + required_to_create_for_contacts?: boolean; + /** Whether the attribute is visible or not to teammates. */ + visible_on_create?: boolean; + /** Whether the attribute is visible or not to contacts. */ + visible_to_contacts?: boolean; + /** Whether the attribute is built in or not. */ + default?: boolean; + /** The id of the ticket type that the attribute belongs to. */ + ticket_type_id?: number; + /** Whether the ticket type attribute is archived or not. */ + archived?: boolean; + /** The date and time the ticket type attribute was created. */ + created_at?: number; + /** The date and time the ticket type attribute was last updated. */ + updated_at?: number; +} diff --git a/src/api/resources/unstable/types/TicketTypeAttributeList.ts b/src/api/resources/unstable/types/TicketTypeAttributeList.ts new file mode 100644 index 00000000..ed242103 --- /dev/null +++ b/src/api/resources/unstable/types/TicketTypeAttributeList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of attributes associated with a given ticket type. + */ +export interface TicketTypeAttributeList { + /** String representing the object's type. Always has the value `ticket_type_attributes.list`. */ + type?: string; + /** A list of ticket type attributes associated with a given ticket type. */ + ticket_type_attributes?: (Intercom.unstable.TicketTypeAttribute | undefined)[]; +} diff --git a/src/api/resources/unstable/types/TicketTypeList.ts b/src/api/resources/unstable/types/TicketTypeList.ts new file mode 100644 index 00000000..572085e6 --- /dev/null +++ b/src/api/resources/unstable/types/TicketTypeList.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * A list of ticket types associated with a given workspace. + */ +export interface TicketTypeList { + /** String representing the object's type. Always has the value `list`. */ + type?: string; + /** A list of ticket_types associated with a given workspace. */ + data?: (Intercom.unstable.TicketType | undefined)[]; +} diff --git a/src/api/resources/unstable/types/Translation.ts b/src/api/resources/unstable/types/Translation.ts new file mode 100644 index 00000000..9807efeb --- /dev/null +++ b/src/api/resources/unstable/types/Translation.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * A translation object contains the localised details of a subscription type. + */ +export interface Translation { + /** The localised name of the subscription type. */ + name?: string; + /** The localised description of the subscription type. */ + description?: string; + /** The two character identifier for the language of the translation object. */ + locale?: string; +} diff --git a/src/api/resources/unstable/types/UntagCompanyRequest.ts b/src/api/resources/unstable/types/UntagCompanyRequest.ts new file mode 100644 index 00000000..b970ebc4 --- /dev/null +++ b/src/api/resources/unstable/types/UntagCompanyRequest.ts @@ -0,0 +1,28 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * You can tag a single company or a list of companies. + */ +export interface UntagCompanyRequest { + /** The name of the tag which will be untagged from the company */ + name: string; + /** The id or company_id of the company can be passed as input parameters. */ + companies: UntagCompanyRequest.Companies.Item[]; +} + +export namespace UntagCompanyRequest { + export type Companies = Companies.Item[]; + + export namespace Companies { + export interface Item { + /** The Intercom defined id representing the company. */ + id?: string; + /** The company id you have defined for the company. */ + company_id?: string; + /** Always set to true */ + untag?: boolean; + } + } +} diff --git a/src/api/resources/unstable/types/UpdateArticleRequestBody.ts b/src/api/resources/unstable/types/UpdateArticleRequestBody.ts new file mode 100644 index 00000000..09be43a9 --- /dev/null +++ b/src/api/resources/unstable/types/UpdateArticleRequestBody.ts @@ -0,0 +1,37 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * You can Update an Article + */ +export interface UpdateArticleRequestBody { + /** The title of the article.For multilingual articles, this will be the title of the default language's content. */ + title?: string; + /** The description of the article. For multilingual articles, this will be the description of the default language's content. */ + description?: string; + /** The content of the article. For multilingual articles, this will be the body of the default language's content. */ + body?: string; + /** The id of the author of the article. For multilingual articles, this will be the id of the author of the default language's content. Must be a teammate on the help center's workspace. */ + author_id?: number; + /** Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. */ + state?: UpdateArticleRequestBody.State; + /** The id of the article's parent collection or section. An article without this field stands alone. */ + parent_id?: string; + /** The type of parent, which can either be a `collection` or `section`. */ + parent_type?: string; + translated_content?: Intercom.unstable.ArticleTranslatedContent; +} + +export namespace UpdateArticleRequestBody { + /** + * Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. + */ + export type State = "published" | "draft"; + export const State = { + Published: "published", + Draft: "draft", + } as const; +} diff --git a/src/api/resources/unstable/types/UpdateTicketTypeRequestBody.ts b/src/api/resources/unstable/types/UpdateTicketTypeRequestBody.ts new file mode 100644 index 00000000..2eca441d --- /dev/null +++ b/src/api/resources/unstable/types/UpdateTicketTypeRequestBody.ts @@ -0,0 +1,34 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * The request payload for updating a ticket type. + * You can copy the `icon` property for your ticket type from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) + */ +export interface UpdateTicketTypeRequestBody { + /** The name of the ticket type. */ + name?: string; + /** The description of the ticket type. */ + description?: string; + /** Category of the Ticket Type. */ + category?: UpdateTicketTypeRequestBody.Category; + /** The icon of the ticket type. */ + icon?: string; + /** The archived status of the ticket type. */ + archived?: boolean; + /** Whether the tickets associated with this ticket type are intended for internal use only or will be shared with customers. This is currently a limited attribute. */ + is_internal?: boolean; +} + +export namespace UpdateTicketTypeRequestBody { + /** + * Category of the Ticket Type. + */ + export type Category = "Customer" | "Back-office" | "Tracker"; + export const Category = { + Customer: "Customer", + BackOffice: "Back-office", + Tracker: "Tracker", + } as const; +} diff --git a/src/api/resources/unstable/types/Visitor.ts b/src/api/resources/unstable/types/Visitor.ts new file mode 100644 index 00000000..272de16a --- /dev/null +++ b/src/api/resources/unstable/types/Visitor.ts @@ -0,0 +1,138 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../../../index"; + +/** + * Visitors are useful for representing anonymous people that have not yet been identified. They usually represent website visitors. Visitors are not visible in Intercom platform. The Visitors resource provides methods to fetch, update, convert and delete. + */ +export interface Visitor { + /** Value is 'visitor' */ + type?: string; + /** The Intercom defined id representing the Visitor. */ + id?: string; + /** Automatically generated identifier for the Visitor. */ + user_id?: string; + /** Identifies if this visitor is anonymous. */ + anonymous?: boolean; + /** The email of the visitor. */ + email?: string; + /** The phone number of the visitor. */ + phone?: string; + /** The name of the visitor. */ + name?: string; + /** The pseudonym of the visitor. */ + pseudonym?: string; + avatar?: Visitor.Avatar; + /** The id of the app the visitor is associated with. */ + app_id?: string; + companies?: Visitor.Companies; + location_data?: Visitor.LocationData; + /** The time the Lead last recorded making a request. */ + las_request_at?: number; + /** The time the Visitor was added to Intercom. */ + created_at?: number; + /** The time the Visitor was added to Intercom. */ + remote_created_at?: number; + /** The time the Visitor signed up for your product. */ + signed_up_at?: number; + /** The last time the Visitor was updated. */ + updated_at?: number; + /** The number of sessions the Visitor has had. */ + session_count?: number; + social_profiles?: Visitor.SocialProfiles; + /** The id of the admin that owns the Visitor. */ + owner_id?: string; + /** Whether the Visitor is unsubscribed from emails. */ + unsubscribed_from_emails?: boolean; + /** Identifies if this visitor has marked an email as spam. */ + marked_email_as_spam?: boolean; + /** Identifies if this visitor has had a hard bounce. */ + has_hard_bounced?: boolean; + tags?: Visitor.Tags; + segments?: Visitor.Segments; + /** The custom attributes you have set on the Visitor. */ + custom_attributes?: Record; + /** The referer of the visitor. */ + referrer?: string; + /** The utm_campaign of the visitor. */ + utm_campaign?: string; + /** The utm_content of the visitor. */ + utm_content?: string; + /** The utm_medium of the visitor. */ + utm_medium?: string; + /** The utm_source of the visitor. */ + utm_source?: string; + /** The utm_term of the visitor. */ + utm_term?: string; + /** Identifies if this visitor has do not track enabled. */ + do_not_track?: boolean; +} + +export namespace Visitor { + export interface Avatar { + /** */ + type?: string; + /** This object represents the avatar associated with the visitor. */ + image_url?: string; + } + + export interface Companies { + /** The type of the object */ + type?: "company.list"; + companies?: Intercom.unstable.Company[]; + } + + export interface LocationData { + /** */ + type?: string; + /** The city name of the visitor. */ + city_name?: string; + /** The continent code of the visitor. */ + continent_code?: string; + /** The country code of the visitor. */ + country_code?: string; + /** The country name of the visitor. */ + country_name?: string; + /** The postal code of the visitor. */ + postal_code?: string; + /** The region name of the visitor. */ + region_name?: string; + /** The timezone of the visitor. */ + timezone?: string; + } + + export interface SocialProfiles { + /** The type of the object */ + type?: "social_profile.list"; + social_profiles?: string[]; + } + + export interface Tags { + /** The type of the object */ + type?: "tag.list"; + tags?: Tags.Tags.Item[]; + } + + export namespace Tags { + export type Tags = Tags.Item[]; + + export namespace Tags { + export interface Item { + /** The type of the object */ + type?: "tag"; + /** The id of the tag. */ + id?: string; + /** The name of the tag. */ + name?: string; + } + } + } + + export interface Segments { + /** The type of the object */ + type?: "segment.list"; + segments?: string[]; + } +} diff --git a/src/api/resources/unstable/types/VisitorDeletedObject.ts b/src/api/resources/unstable/types/VisitorDeletedObject.ts new file mode 100644 index 00000000..6d2dcfd3 --- /dev/null +++ b/src/api/resources/unstable/types/VisitorDeletedObject.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * Response returned when an object is deleted + */ +export interface VisitorDeletedObject { + /** The unique identifier for the visitor which is given by Intercom. */ + id?: string; + /** The type of object which was deleted */ + type?: "visitor"; + /** Automatically generated identifier for the Visitor. */ + user_id?: string; +} diff --git a/src/api/resources/unstable/types/WhatsappMessageStatusList.ts b/src/api/resources/unstable/types/WhatsappMessageStatusList.ts new file mode 100644 index 00000000..71377c21 --- /dev/null +++ b/src/api/resources/unstable/types/WhatsappMessageStatusList.ts @@ -0,0 +1,71 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface WhatsappMessageStatusList { + type: "list"; + /** The provided ruleset ID */ + ruleset_id: string; + pages: WhatsappMessageStatusList.Pages; + /** Total number of events */ + total_count: number; + events: WhatsappMessageStatusList.Events.Item[]; +} + +export namespace WhatsappMessageStatusList { + export interface Pages { + type: "pages"; + /** Number of results per page */ + per_page: number; + /** Total number of pages */ + total_pages: number; + /** Information for fetching next page (null if no more pages) */ + next?: Pages.Next; + } + + export namespace Pages { + /** + * Information for fetching next page (null if no more pages) + */ + export interface Next { + /** Cursor for the next page */ + starting_after?: string; + } + } + + export type Events = Events.Item[]; + + export namespace Events { + export interface Item { + /** Event ID */ + id: string; + /** ID of the conversation */ + conversation_id: string; + /** Current status of the message */ + status: Item.Status; + /** Event type */ + type: "broadcast_outbound"; + /** Creation timestamp */ + created_at: number; + /** Last update timestamp */ + updated_at: number; + /** WhatsApp's message identifier */ + whatsapp_message_id: string; + /** Name of the WhatsApp template used */ + template_name?: string; + } + + export namespace Item { + /** + * Current status of the message + */ + export type Status = "sent" | "delivered" | "read" | "failed"; + export const Status = { + Sent: "sent", + Delivered: "delivered", + Read: "read", + Failed: "failed", + } as const; + } + } +} diff --git a/src/api/resources/unstable/types/index.ts b/src/api/resources/unstable/types/index.ts new file mode 100644 index 00000000..129ed3c6 --- /dev/null +++ b/src/api/resources/unstable/types/index.ts @@ -0,0 +1,145 @@ +export * from "./NotFoundErrorBody"; +export * from "./Datetime"; +export * from "./ActivityLog"; +export * from "./ActivityLogList"; +export * from "./ActivityLogMetadata"; +export * from "./AddressableList"; +export * from "./AdminList"; +export * from "./AdminPriorityLevel"; +export * from "./AdminReplyConversationRequest"; +export * from "./AdminReplyTicketRequest"; +export * from "./AdminWithApp"; +export * from "./App"; +export * from "./ArticleContent"; +export * from "./ArticleList"; +export * from "./ArticleStatistics"; +export * from "./ArticleTranslatedContent"; +export * from "./AssignConversationRequest"; +export * from "./AwayStatusReason"; +export * from "./CloseConversationRequest"; +export * from "./CollectionList"; +export * from "./CompanyAttachedContacts"; +export * from "./CompanyAttachedSegments"; +export * from "./CompanyList"; +export * from "./CompanyScroll"; +export * from "./ContactAttachedCompanies"; +export * from "./ContactCompanies"; +export * from "./CompanyData"; +export * from "./ContactDeleted"; +export * from "./ContactList"; +export * from "./ContactLocation"; +export * from "./ContactNotes"; +export * from "./ContactReference"; +export * from "./ContactReplyBaseRequest"; +export * from "./ContactReplyConversationRequest"; +export * from "./ContactReplyEmailRequest"; +export * from "./ContactReplyIntercomUserIdRequest"; +export * from "./ContactReplyTicketEmailRequest"; +export * from "./ContactReplyTicketIntercomUserIdRequest"; +export * from "./ContactReplyTicketRequest"; +export * from "./ContactReplyTicketUserIdRequest"; +export * from "./ContactReplyUserIdRequest"; +export * from "./ContactSegments"; +export * from "./ContactSocialProfiles"; +export * from "./ContactSubscriptionTypes"; +export * from "./ContactTags"; +export * from "./ContactArchived"; +export * from "./ContactUnarchived"; +export * from "./ContactBlocked"; +export * from "./ContentSourcesList"; +export * from "./ConversationAttachmentFiles"; +export * from "./ConversationContacts"; +export * from "./ConversationDeleted"; +export * from "./ConversationFirstContactReply"; +export * from "./ConversationList"; +export * from "./ConversationPart"; +export * from "./ConversationPartAuthor"; +export * from "./ConversationParts"; +export * from "./ConversationPartMetadata"; +export * from "./ConversationRating"; +export * from "./ConversationResponseTime"; +export * from "./ConversationSource"; +export * from "./ConversationStatistics"; +export * from "./ConversationTeammates"; +export * from "./Recipient"; +export * from "./CreateOrUpdateTagRequest"; +export * from "./CreateTicketReplyWithCommentRequest"; +export * from "./CreateTicketRequestBody"; +export * from "./CursorPages"; +export * from "./CustomAttributes"; +export * from "./CustomObjectInstanceDeleted"; +export * from "./CustomObjectInstanceList"; +export * from "./CustomerRequest"; +export * from "./DataAttributeList"; +export * from "./DataEventList"; +export * from "./DataEventSummary"; +export * from "./DataEventSummaryItem"; +export * from "./DataExportCsv"; +export * from "./DeletedArticleObject"; +export * from "./DeletedCollectionObject"; +export * from "./DeletedCompanyObject"; +export * from "./DeletedObject"; +export * from "./EmailAddressHeader"; +export * from "./EmailMessageMetadata"; +export * from "./ConversationAttributeUpdatedByWorkflow"; +export * from "./ConversationAttributeUpdatedByAdmin"; +export * from "./CustomActionStarted"; +export * from "./CustomChannelAttribute"; +export * from "./CustomChannelBaseEvent"; +export * from "./CustomChannelContact"; +export * from "./CustomChannelNotificationResponse"; +export * from "./CustomActionFinished"; +export * from "./OperatorWorkflowEvent"; +export * from "./EventDetails"; +export * from "./Error_"; +export * from "./FileAttribute"; +export * from "./GroupContent"; +export * from "./GroupTranslatedContent"; +export * from "./IntercomVersion"; +export * from "./LinkedObject"; +export * from "./IntercomVersionUnstable"; +export * from "./LinkedObjectList"; +export * from "./WhatsappMessageStatusList"; +export * from "./MultipleFilterSearchRequest"; +export * from "./NewsItemRequest"; +export * from "./NoteList"; +export * from "./OpenConversationRequest"; +export * from "./PagesLink"; +export * from "./PaginatedResponseDataItem"; +export * from "./PaginatedResponse"; +export * from "./PartAttachment"; +export * from "./PhoneSwitch"; +export * from "./QuickReplyOption"; +export * from "./RedactConversationRequest"; +export * from "./Reference"; +export * from "./ReplyConversationRequestBody"; +export * from "./SearchRequest"; +export * from "./SegmentList"; +export * from "./SingleFilterSearchRequest"; +export * from "./SlaApplied"; +export * from "./SnoozeConversationRequest"; +export * from "./SocialProfile"; +export * from "./StartingAfterPaging"; +export * from "./SubscriptionTypeList"; +export * from "./TagCompanyRequest"; +export * from "./TagList"; +export * from "./TagMultipleUsersRequest"; +export * from "./Tags"; +export * from "./TeamList"; +export * from "./TeamPriorityLevel"; +export * from "./TicketCustomAttributes"; +export * from "./TicketList"; +export * from "./TicketPartAuthor"; +export * from "./TicketParts"; +export * from "./TicketReply"; +export * from "./TicketRequestCustomAttributes"; +export * from "./TicketStateList"; +export * from "./TicketTypeAttribute"; +export * from "./TicketTypeAttributeList"; +export * from "./TicketTypeList"; +export * from "./Translation"; +export * from "./UntagCompanyRequest"; +export * from "./UpdateArticleRequestBody"; +export * from "./UpdateTicketTypeRequestBody"; +export * from "./Visitor"; +export * from "./VisitorDeletedObject"; diff --git a/src/api/resources/visitors/client/Client.ts b/src/api/resources/visitors/client/Client.ts index 531cd2a7..e18896e6 100644 --- a/src/api/resources/visitors/client/Client.ts +++ b/src/api/resources/visitors/client/Client.ts @@ -89,10 +89,17 @@ export class Visitors { * user_id: "user_id" * }) */ - public async find( + public find( request: Intercom.FindVisitorRequest, requestOptions?: Visitors.RequestOptions, - ): Promise { + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); + } + + private async __find( + request: Intercom.FindVisitorRequest, + requestOptions?: Visitors.RequestOptions, + ): Promise> { const { user_id: userId } = request; const _queryParams: Record = {}; _queryParams["user_id"] = userId; @@ -108,8 +115,8 @@ export class Visitors { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -123,19 +130,23 @@ export class Visitors { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Visitor; + return { data: _response.body as Intercom.Visitor, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -145,12 +156,14 @@ export class Visitors { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /visitors."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -180,10 +193,17 @@ export class Visitors { * name: "Christian Fail" * }) */ - public async update( + public update( + request: Intercom.UpdateVisitorRequest, + requestOptions?: Visitors.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); + } + + private async __update( request: Intercom.UpdateVisitorRequest, requestOptions?: Visitors.RequestOptions, - ): Promise { + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -196,8 +216,8 @@ export class Visitors { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -211,19 +231,23 @@ export class Visitors { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Visitor; + return { data: _response.body as Intercom.Visitor, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown); + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -233,12 +257,14 @@ export class Visitors { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /visitors."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } @@ -267,10 +293,17 @@ export class Visitors { * } * }) */ - public async mergeToContact( + public mergeToContact( + request: Intercom.MergeVisitorToContactRequest, + requestOptions?: Visitors.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__mergeToContact(request, requestOptions)); + } + + private async __mergeToContact( request: Intercom.MergeVisitorToContactRequest, requestOptions?: Visitors.RequestOptions, - ): Promise { + ): Promise> { const _response = await (this._options.fetcher ?? core.fetcher)({ url: urlJoin( (await core.Supplier.get(this._options.baseUrl)) ?? @@ -283,8 +316,8 @@ export class Visitors { Authorization: await this._getAuthorizationHeader(), "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.3.0", - "User-Agent": "intercom-client/6.3.0", + "X-Fern-SDK-Version": "6.4.0", + "User-Agent": "intercom-client/6.4.0", "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, @@ -298,17 +331,21 @@ export class Visitors { abortSignal: requestOptions?.abortSignal, }); if (_response.ok) { - return _response.body as Intercom.Contact; + return { data: _response.body as Intercom.Contact, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { case 401: - throw new Intercom.UnauthorizedError(_response.error.body as Intercom.Error_); + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); default: throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.body, + rawResponse: _response.rawResponse, }); } } @@ -318,12 +355,14 @@ export class Visitors { throw new errors.IntercomError({ statusCode: _response.error.statusCode, body: _response.error.rawBody, + rawResponse: _response.rawResponse, }); case "timeout": throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /visitors/convert."); case "unknown": throw new errors.IntercomError({ message: _response.error.errorMessage, + rawResponse: _response.rawResponse, }); } } diff --git a/src/api/types/CreateContactRequestTwo.ts b/src/api/types/CreateContactRequestTwo.ts new file mode 100644 index 00000000..b3041530 --- /dev/null +++ b/src/api/types/CreateContactRequestTwo.ts @@ -0,0 +1,5 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type CreateContactRequestTwo = unknown; diff --git a/src/api/types/CreateDataEventRequestTwo.ts b/src/api/types/CreateDataEventRequestTwo.ts new file mode 100644 index 00000000..5eb4bbe5 --- /dev/null +++ b/src/api/types/CreateDataEventRequestTwo.ts @@ -0,0 +1,5 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type CreateDataEventRequestTwo = unknown; diff --git a/src/api/types/CreateMessageRequestTwo.ts b/src/api/types/CreateMessageRequestTwo.ts new file mode 100644 index 00000000..1c075b32 --- /dev/null +++ b/src/api/types/CreateMessageRequestTwo.ts @@ -0,0 +1,5 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type CreateMessageRequestTwo = unknown; diff --git a/src/api/resources/tickets/client/requests/CreateTicketRequest.ts b/src/api/types/CreateTicketRequest.ts similarity index 74% rename from src/api/resources/tickets/client/requests/CreateTicketRequest.ts rename to src/api/types/CreateTicketRequest.ts index db4974e5..272de2b7 100644 --- a/src/api/resources/tickets/client/requests/CreateTicketRequest.ts +++ b/src/api/types/CreateTicketRequest.ts @@ -2,20 +2,10 @@ * This file was auto-generated by Fern from our API Definition. */ -import * as Intercom from "../../../../index"; +import * as Intercom from "../index"; /** - * @example - * { - * ticket_type_id: "1234", - * contacts: [{ - * id: "667d61b78a68186f43bafe8d" - * }], - * ticket_attributes: { - * "_default_title_": "example", - * "_default_description_": "there is a problem" - * } - * } + * You can create a Ticket */ export interface CreateTicketRequest { /** The ID of the type of ticket you want to create */ diff --git a/src/api/types/Metadata.ts b/src/api/types/Metadata.ts new file mode 100644 index 00000000..1c29cca9 --- /dev/null +++ b/src/api/types/Metadata.ts @@ -0,0 +1,7 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as Intercom from "../index"; + +export type Metadata = Intercom.unstable.ConversationPartMetadata; diff --git a/src/api/types/UpdateVisitorRequestOne.ts b/src/api/types/UpdateVisitorRequestOne.ts new file mode 100644 index 00000000..67858b8e --- /dev/null +++ b/src/api/types/UpdateVisitorRequestOne.ts @@ -0,0 +1,5 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type UpdateVisitorRequestOne = unknown; diff --git a/src/api/types/index.ts b/src/api/types/index.ts index ded80781..2a4c1060 100644 --- a/src/api/types/index.ts +++ b/src/api/types/index.ts @@ -69,6 +69,7 @@ export * from "./CreateDataEventRequest"; export * from "./CreateMessageRequest"; export * from "./CreateOrUpdateTagRequest"; export * from "./CreateTicketReplyWithCommentRequest"; +export * from "./CreateTicketRequest"; export * from "./CurrentCanvas"; export * from "./CursorPages"; export * from "./CustomerRequest"; @@ -157,3 +158,8 @@ export * from "./Visitor"; export * from "./VisitorDeletedObject"; export * from "./CustomAttributes"; export * from "./OffsetPages"; +export * from "./CreateContactRequestTwo"; +export * from "./CreateDataEventRequestTwo"; +export * from "./CreateMessageRequestTwo"; +export * from "./Metadata"; +export * from "./UpdateVisitorRequestOne"; diff --git a/src/core/fetcher/APIResponse.ts b/src/core/fetcher/APIResponse.ts index 3664d09e..6335291b 100644 --- a/src/core/fetcher/APIResponse.ts +++ b/src/core/fetcher/APIResponse.ts @@ -1,12 +1,23 @@ +import { RawResponse } from "./RawResponse"; + +/** + * The response of an API call. + * It is a successful response or a failed response. + */ export type APIResponse = SuccessfulResponse | FailedResponse; export interface SuccessfulResponse { ok: true; body: T; + /** + * @deprecated Use `rawResponse` instead + */ headers?: Record; + rawResponse: RawResponse; } export interface FailedResponse { ok: false; error: T; + rawResponse: RawResponse; } diff --git a/src/core/fetcher/Fetcher.ts b/src/core/fetcher/Fetcher.ts index f3ee18ee..336ee10b 100644 --- a/src/core/fetcher/Fetcher.ts +++ b/src/core/fetcher/Fetcher.ts @@ -1,5 +1,6 @@ import { toJson } from "../json"; import { APIResponse } from "./APIResponse"; +import { abortRawResponse, toRawResponse, unknownRawResponse } from "./RawResponse"; import { createRequestUrl } from "./createRequestUrl"; import { getFetchFn } from "./getFetchFn"; import { getRequestBody } from "./getRequestBody"; @@ -94,6 +95,7 @@ export async function fetcherImpl(args: Fetcher.Args): Promise(args: Fetcher.Args): Promise(args: Fetcher.Args): Promise(args: Fetcher.Args): Promise(args: Fetcher.Args): Promise(args: Fetcher.Args): Promise; + + constructor(init?: HeadersInit) { + this.headers = new Map(); + + if (init) { + if (init instanceof Headers) { + init.forEach((value, key) => this.append(key, value)); + } else if (Array.isArray(init)) { + for (const [key, value] of init) { + if (typeof key === "string" && typeof value === "string") { + this.append(key, value); + } else { + throw new TypeError("Each header entry must be a [string, string] tuple"); + } + } + } else { + for (const [key, value] of Object.entries(init)) { + if (typeof value === "string") { + this.append(key, value); + } else { + throw new TypeError("Header values must be strings"); + } + } + } + } + } + + append(name: string, value: string): void { + const key = name.toLowerCase(); + const existing = this.headers.get(key) || []; + this.headers.set(key, [...existing, value]); + } + + delete(name: string): void { + const key = name.toLowerCase(); + this.headers.delete(key); + } + + get(name: string): string | null { + const key = name.toLowerCase(); + const values = this.headers.get(key); + return values ? values.join(", ") : null; + } + + has(name: string): boolean { + const key = name.toLowerCase(); + return this.headers.has(key); + } + + set(name: string, value: string): void { + const key = name.toLowerCase(); + this.headers.set(key, [value]); + } + + forEach(callbackfn: (value: string, key: string, parent: Headers) => void, thisArg?: unknown): void { + const boundCallback = thisArg ? callbackfn.bind(thisArg) : callbackfn; + this.headers.forEach((values, key) => boundCallback(values.join(", "), key, this)); + } + + getSetCookie(): string[] { + return this.headers.get("set-cookie") || []; + } + + *entries(): HeadersIterator<[string, string]> { + for (const [key, values] of this.headers.entries()) { + yield [key, values.join(", ")]; + } + } + + *keys(): HeadersIterator { + yield* this.headers.keys(); + } + + *values(): HeadersIterator { + for (const values of this.headers.values()) { + yield values.join(", "); + } + } + + [Symbol.iterator](): HeadersIterator<[string, string]> { + return this.entries(); + } + }; +} + +export { Headers }; diff --git a/src/core/fetcher/HttpResponsePromise.ts b/src/core/fetcher/HttpResponsePromise.ts new file mode 100644 index 00000000..6b0bc4fc --- /dev/null +++ b/src/core/fetcher/HttpResponsePromise.ts @@ -0,0 +1,116 @@ +import { WithRawResponse } from "./RawResponse"; + +/** + * A promise that returns the parsed response and lets you retrieve the raw response too. + */ +export class HttpResponsePromise extends Promise { + private innerPromise: Promise>; + private unwrappedPromise: Promise | undefined; + + private constructor(promise: Promise>) { + // Initialize with a no-op to avoid premature parsing + super((resolve) => { + resolve(undefined as unknown as T); + }); + this.innerPromise = promise; + } + + /** + * Creates an `HttpResponsePromise` from a function that returns a promise. + * + * @param fn - A function that returns a promise resolving to a `WithRawResponse` object. + * @param args - Arguments to pass to the function. + * @returns An `HttpResponsePromise` instance. + */ + public static fromFunction Promise>, T>( + fn: F, + ...args: Parameters + ): HttpResponsePromise { + return new HttpResponsePromise(fn(...args)); + } + + /** + * Creates a function that returns an `HttpResponsePromise` from a function that returns a promise. + * + * @param fn - A function that returns a promise resolving to a `WithRawResponse` object. + * @returns A function that returns an `HttpResponsePromise` instance. + */ + public static interceptFunction< + F extends (...args: never[]) => Promise>, + T = Awaited>["data"], + >(fn: F): (...args: Parameters) => HttpResponsePromise { + return (...args: Parameters): HttpResponsePromise => { + return HttpResponsePromise.fromPromise(fn(...args)); + }; + } + + /** + * Creates an `HttpResponsePromise` from an existing promise. + * + * @param promise - A promise resolving to a `WithRawResponse` object. + * @returns An `HttpResponsePromise` instance. + */ + public static fromPromise(promise: Promise>): HttpResponsePromise { + return new HttpResponsePromise(promise); + } + + /** + * Creates an `HttpResponsePromise` from an executor function. + * + * @param executor - A function that takes resolve and reject callbacks to create a promise. + * @returns An `HttpResponsePromise` instance. + */ + public static fromExecutor( + executor: (resolve: (value: WithRawResponse) => void, reject: (reason?: unknown) => void) => void, + ): HttpResponsePromise { + const promise = new Promise>(executor); + return new HttpResponsePromise(promise); + } + + /** + * Creates an `HttpResponsePromise` from a resolved result. + * + * @param result - A `WithRawResponse` object to resolve immediately. + * @returns An `HttpResponsePromise` instance. + */ + public static fromResult(result: WithRawResponse): HttpResponsePromise { + const promise = Promise.resolve(result); + return new HttpResponsePromise(promise); + } + + private unwrap(): Promise { + if (!this.unwrappedPromise) { + this.unwrappedPromise = this.innerPromise.then(({ data }) => data); + } + return this.unwrappedPromise; + } + + /** @inheritdoc */ + public override then( + onfulfilled?: ((value: T) => TResult1 | PromiseLike) | null, + onrejected?: ((reason: unknown) => TResult2 | PromiseLike) | null, + ): Promise { + return this.unwrap().then(onfulfilled, onrejected); + } + + /** @inheritdoc */ + public override catch( + onrejected?: ((reason: unknown) => TResult | PromiseLike) | null, + ): Promise { + return this.unwrap().catch(onrejected); + } + + /** @inheritdoc */ + public override finally(onfinally?: (() => void) | null): Promise { + return this.unwrap().finally(onfinally); + } + + /** + * Retrieves the data and raw response. + * + * @returns A promise resolving to a `WithRawResponse` object. + */ + public async withRawResponse(): Promise> { + return await this.innerPromise; + } +} diff --git a/src/core/fetcher/RawResponse.ts b/src/core/fetcher/RawResponse.ts new file mode 100644 index 00000000..bdaa614a --- /dev/null +++ b/src/core/fetcher/RawResponse.ts @@ -0,0 +1,61 @@ +import { Headers } from "./Headers"; + +/** + * The raw response from the fetch call excluding the body. + */ +export type RawResponse = Omit< + { + [K in keyof Response as Response[K] extends Function ? never : K]: Response[K]; // strips out functions + }, + "ok" | "body" | "bodyUsed" +>; // strips out body and bodyUsed + +/** + * A raw response indicating that the request was aborted. + */ +export const abortRawResponse: RawResponse = { + headers: new Headers(), + redirected: false, + status: 499, + statusText: "Client Closed Request", + type: "error", + url: "", +} as const; + +/** + * A raw response indicating an unknown error. + */ +export const unknownRawResponse: RawResponse = { + headers: new Headers(), + redirected: false, + status: 0, + statusText: "Unknown Error", + type: "error", + url: "", +} as const; + +/** + * Converts a `RawResponse` object into a `RawResponse` by extracting its properties, + * excluding the `body` and `bodyUsed` fields. + * + * @param response - The `RawResponse` object to convert. + * @returns A `RawResponse` object containing the extracted properties of the input response. + */ +export function toRawResponse(response: Response): RawResponse { + return { + headers: response.headers, + redirected: response.redirected, + status: response.status, + statusText: response.statusText, + type: response.type, + url: response.url, + }; +} + +/** + * Creates a `RawResponse` from a standard `Response` object. + */ +export interface WithRawResponse { + readonly data: T; + readonly rawResponse: RawResponse; +} diff --git a/src/core/fetcher/index.ts b/src/core/fetcher/index.ts index 2d658ca4..249f5176 100644 --- a/src/core/fetcher/index.ts +++ b/src/core/fetcher/index.ts @@ -3,3 +3,6 @@ export { fetcher } from "./Fetcher"; export type { Fetcher, FetchFunction } from "./Fetcher"; export { getHeader } from "./getHeader"; export { Supplier } from "./Supplier"; +export { abortRawResponse, toRawResponse, unknownRawResponse } from "./RawResponse"; +export type { RawResponse, WithRawResponse } from "./RawResponse"; +export { HttpResponsePromise } from "./HttpResponsePromise"; diff --git a/src/core/index.ts b/src/core/index.ts index eaa51053..466b3c3a 100644 --- a/src/core/index.ts +++ b/src/core/index.ts @@ -1,5 +1,5 @@ export * from "./fetcher"; -export * from "./auth"; export * from "./runtime"; +export * from "./auth"; export * from "./utils"; export * from "./pagination"; diff --git a/src/core/pagination/Page.ts b/src/core/pagination/Page.ts index 07c6796e..30df7280 100644 --- a/src/core/pagination/Page.ts +++ b/src/core/pagination/Page.ts @@ -1,3 +1,5 @@ +import { HttpResponsePromise, RawResponse } from "../fetcher"; + /** * A page of results from a paginated API. * @@ -5,24 +7,28 @@ */ export class Page implements AsyncIterable { public data: T[]; + public rawResponse: RawResponse; private response: unknown; private _hasNextPage: (response: unknown) => boolean; private getItems: (response: unknown) => T[]; - private loadNextPage: (response: unknown) => Promise; + private loadNextPage: (response: unknown) => HttpResponsePromise; constructor({ response, + rawResponse, hasNextPage, getItems, loadPage, }: { response: unknown; + rawResponse: RawResponse; hasNextPage: (response: unknown) => boolean; getItems: (response: unknown) => T[]; - loadPage: (response: unknown) => Promise; + loadPage: (response: unknown) => HttpResponsePromise; }) { this.response = response; + this.rawResponse = rawResponse; this.data = getItems(response); this._hasNextPage = hasNextPage; this.getItems = getItems; @@ -34,7 +40,9 @@ export class Page implements AsyncIterable { * @returns this */ public async getNextPage(): Promise { - this.response = await this.loadNextPage(this.response); + const { data, rawResponse } = await this.loadNextPage(this.response).withRawResponse(); + this.response = data; + this.rawResponse = rawResponse; this.data = this.getItems(this.response); return this; } diff --git a/src/core/pagination/Pageable.ts b/src/core/pagination/Pageable.ts index befce635..3a5220eb 100644 --- a/src/core/pagination/Pageable.ts +++ b/src/core/pagination/Pageable.ts @@ -1,8 +1,10 @@ +import { RawResponse } from "../fetcher"; import { Page } from "./Page"; export declare namespace Pageable { interface Args { response: Response; + rawResponse: RawResponse; hasNextPage: (response: Response) => boolean; getItems: (response: Response) => Item[]; loadPage: (response: Response) => Promise; diff --git a/src/errors/IntercomError.ts b/src/errors/IntercomError.ts index add6ed73..0f91cad3 100644 --- a/src/errors/IntercomError.ts +++ b/src/errors/IntercomError.ts @@ -2,22 +2,30 @@ * This file was auto-generated by Fern from our API Definition. */ +import * as core from "../core"; import { toJson } from "../core/json"; export class IntercomError extends Error { - readonly statusCode?: number; - readonly body?: unknown; - - constructor({ message, statusCode, body }: { message?: string; statusCode?: number; body?: unknown }) { + public readonly statusCode?: number; + public readonly body?: unknown; + public readonly rawResponse?: core.RawResponse; + + constructor({ + message, + statusCode, + body, + rawResponse, + }: { + message?: string; + statusCode?: number; + body?: unknown; + rawResponse?: core.RawResponse; + }) { super(buildMessage({ message, statusCode, body })); Object.setPrototypeOf(this, IntercomError.prototype); - if (statusCode != null) { - this.statusCode = statusCode; - } - - if (body !== undefined) { - this.body = body; - } + this.statusCode = statusCode; + this.body = body; + this.rawResponse = rawResponse; } } diff --git a/src/version.ts b/src/version.ts index 0ea5cbcb..1420c168 100644 --- a/src/version.ts +++ b/src/version.ts @@ -1 +1 @@ -export const SDK_VERSION = "6.3.0"; +export const SDK_VERSION = "6.4.0"; diff --git a/tests/unit/fetcher/HttpResponsePromise.test.ts b/tests/unit/fetcher/HttpResponsePromise.test.ts new file mode 100644 index 00000000..2216a33e --- /dev/null +++ b/tests/unit/fetcher/HttpResponsePromise.test.ts @@ -0,0 +1,143 @@ +import { beforeEach, describe, expect, it, jest } from "@jest/globals"; + +import { HttpResponsePromise } from "../../../src/core/fetcher/HttpResponsePromise"; +import { RawResponse, WithRawResponse } from "../../../src/core/fetcher/RawResponse"; + +describe("HttpResponsePromise", () => { + const mockRawResponse: RawResponse = { + headers: new Headers(), + redirected: false, + status: 200, + statusText: "OK", + type: "basic" as ResponseType, + url: "https://example.com", + }; + const mockData = { id: "123", name: "test" }; + const mockWithRawResponse: WithRawResponse = { + data: mockData, + rawResponse: mockRawResponse, + }; + + describe("fromFunction", () => { + it("should create an HttpResponsePromise from a function", async () => { + const mockFn = jest + .fn<(arg1: string, arg2: string) => Promise>>() + .mockResolvedValue(mockWithRawResponse); + + const responsePromise = HttpResponsePromise.fromFunction(mockFn, "arg1", "arg2"); + + const result = await responsePromise; + expect(result).toEqual(mockData); + expect(mockFn).toHaveBeenCalledWith("arg1", "arg2"); + + const resultWithRawResponse = await responsePromise.withRawResponse(); + expect(resultWithRawResponse).toEqual({ + data: mockData, + rawResponse: mockRawResponse, + }); + }); + }); + + describe("fromPromise", () => { + it("should create an HttpResponsePromise from a promise", async () => { + const promise = Promise.resolve(mockWithRawResponse); + + const responsePromise = HttpResponsePromise.fromPromise(promise); + + const result = await responsePromise; + expect(result).toEqual(mockData); + + const resultWithRawResponse = await responsePromise.withRawResponse(); + expect(resultWithRawResponse).toEqual({ + data: mockData, + rawResponse: mockRawResponse, + }); + }); + }); + + describe("fromExecutor", () => { + it("should create an HttpResponsePromise from an executor function", async () => { + const responsePromise = HttpResponsePromise.fromExecutor((resolve) => { + resolve(mockWithRawResponse); + }); + + const result = await responsePromise; + expect(result).toEqual(mockData); + + const resultWithRawResponse = await responsePromise.withRawResponse(); + expect(resultWithRawResponse).toEqual({ + data: mockData, + rawResponse: mockRawResponse, + }); + }); + }); + + describe("fromResult", () => { + it("should create an HttpResponsePromise from a result", async () => { + const responsePromise = HttpResponsePromise.fromResult(mockWithRawResponse); + + const result = await responsePromise; + expect(result).toEqual(mockData); + + const resultWithRawResponse = await responsePromise.withRawResponse(); + expect(resultWithRawResponse).toEqual({ + data: mockData, + rawResponse: mockRawResponse, + }); + }); + }); + + describe("Promise methods", () => { + let responsePromise: HttpResponsePromise; + + beforeEach(() => { + responsePromise = HttpResponsePromise.fromResult(mockWithRawResponse); + }); + + it("should support then() method", async () => { + const result = await responsePromise.then((data) => ({ + ...data, + modified: true, + })); + + expect(result).toEqual({ + ...mockData, + modified: true, + }); + }); + + it("should support catch() method", async () => { + const errorResponsePromise = HttpResponsePromise.fromExecutor((_, reject) => { + reject(new Error("Test error")); + }); + + const catchSpy = jest.fn(); + await errorResponsePromise.catch(catchSpy); + + expect(catchSpy).toHaveBeenCalled(); + const error = catchSpy.mock.calls[0]?.[0]; + expect(error).toBeInstanceOf(Error); + expect((error as Error).message).toBe("Test error"); + }); + + it("should support finally() method", async () => { + const finallySpy = jest.fn(); + await responsePromise.finally(finallySpy); + + expect(finallySpy).toHaveBeenCalled(); + }); + }); + + describe("withRawResponse", () => { + it("should return both data and raw response", async () => { + const responsePromise = HttpResponsePromise.fromResult(mockWithRawResponse); + + const result = await responsePromise.withRawResponse(); + + expect(result).toEqual({ + data: mockData, + rawResponse: mockRawResponse, + }); + }); + }); +}); diff --git a/tests/unit/fetcher/RawResponse.test.ts b/tests/unit/fetcher/RawResponse.test.ts new file mode 100644 index 00000000..9ccd5e1e --- /dev/null +++ b/tests/unit/fetcher/RawResponse.test.ts @@ -0,0 +1,34 @@ +import { describe, expect, it } from "@jest/globals"; + +import { toRawResponse } from "../../../src/core/fetcher/RawResponse"; + +describe("RawResponse", () => { + describe("toRawResponse", () => { + it("should convert Response to RawResponse by removing body, bodyUsed, and ok properties", () => { + const mockHeaders = new Headers({ "content-type": "application/json" }); + const mockResponse = { + body: "test body", + bodyUsed: false, + ok: true, + headers: mockHeaders, + redirected: false, + status: 200, + statusText: "OK", + type: "basic" as ResponseType, + url: "https://example.com", + }; + + const result = toRawResponse(mockResponse as unknown as Response); + + expect("body" in result).toBe(false); + expect("bodyUsed" in result).toBe(false); + expect("ok" in result).toBe(false); + expect(result.headers).toBe(mockHeaders); + expect(result.redirected).toBe(false); + expect(result.status).toBe(200); + expect(result.statusText).toBe("OK"); + expect(result.type).toBe("basic"); + expect(result.url).toBe("https://example.com"); + }); + }); +}); diff --git a/tests/unit/fetcher/stream-wrappers/webpack.test.ts b/tests/unit/fetcher/stream-wrappers/webpack.test.ts index 63fa0a78..f7537d3c 100644 --- a/tests/unit/fetcher/stream-wrappers/webpack.test.ts +++ b/tests/unit/fetcher/stream-wrappers/webpack.test.ts @@ -38,5 +38,5 @@ describe("test env compatibility", () => { }, ); }); - }, 90_000); + }, 180_000); }); diff --git a/yarn.lock b/yarn.lock index 33ecf06c..fb6d3874 100644 --- a/yarn.lock +++ b/yarn.lock @@ -20,43 +20,43 @@ picocolors "^1.1.1" "@babel/compat-data@^7.27.2": - version "7.27.2" - resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.27.2.tgz#4183f9e642fd84e74e3eea7ffa93a412e3b102c9" - integrity sha512-TUtMJYRPyUb/9aU8f3K0mjmjf6M9N5Woshn2CS6nqJSeJtTtQcpLUXjGt9vbF8ZGff0El99sWkLgzwW3VXnxZQ== + version "7.27.5" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.27.5.tgz#7d0658ec1a8420fc866d1df1b03bea0e79934c82" + integrity sha512-KiRAp/VoJaWkkte84TvUd9qjdbZAdiqyvMxrGl1N6vzFogKmaLgoM3L1kgtLicp2HP5fBJS8JrZKLVIZGVJAVg== "@babel/core@^7.11.6", "@babel/core@^7.12.3", "@babel/core@^7.23.9": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.27.1.tgz#89de51e86bd12246003e3524704c49541b16c3e6" - integrity sha512-IaaGWsQqfsQWVLqMn9OB92MNN7zukfVA4s7KKAI0KfrrDsZ0yhi5uV4baBuLuN7n3vsZpwP8asPPcVwApxvjBQ== + version "7.27.4" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.27.4.tgz#cc1fc55d0ce140a1828d1dd2a2eba285adbfb3ce" + integrity sha512-bXYxrXFubeYdvB0NhD/NBB3Qi6aZeV20GOWVI47t2dkecCEoneR4NPVcb7abpXDEvejgrUfFtG6vG/zxAKmg+g== dependencies: "@ampproject/remapping" "^2.2.0" "@babel/code-frame" "^7.27.1" - "@babel/generator" "^7.27.1" - "@babel/helper-compilation-targets" "^7.27.1" - "@babel/helper-module-transforms" "^7.27.1" - "@babel/helpers" "^7.27.1" - "@babel/parser" "^7.27.1" - "@babel/template" "^7.27.1" - "@babel/traverse" "^7.27.1" - "@babel/types" "^7.27.1" + "@babel/generator" "^7.27.3" + "@babel/helper-compilation-targets" "^7.27.2" + "@babel/helper-module-transforms" "^7.27.3" + "@babel/helpers" "^7.27.4" + "@babel/parser" "^7.27.4" + "@babel/template" "^7.27.2" + "@babel/traverse" "^7.27.4" + "@babel/types" "^7.27.3" convert-source-map "^2.0.0" debug "^4.1.0" gensync "^1.0.0-beta.2" json5 "^2.2.3" semver "^6.3.1" -"@babel/generator@^7.27.1", "@babel/generator@^7.7.2": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.27.1.tgz#862d4fad858f7208edd487c28b58144036b76230" - integrity sha512-UnJfnIpc/+JO0/+KRVQNGU+y5taA5vCbwN8+azkX6beii/ZF+enZJSOKo11ZSzGJjlNfJHfQtmQT8H+9TXPG2w== +"@babel/generator@^7.27.3", "@babel/generator@^7.7.2": + version "7.27.5" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.27.5.tgz#3eb01866b345ba261b04911020cbe22dd4be8c8c" + integrity sha512-ZGhA37l0e/g2s1Cnzdix0O3aLYm66eF8aufiVteOgnwxgnRP8GoyMj7VWsgWnQbVKXyge7hqrFh2K2TQM6t1Hw== dependencies: - "@babel/parser" "^7.27.1" - "@babel/types" "^7.27.1" + "@babel/parser" "^7.27.5" + "@babel/types" "^7.27.3" "@jridgewell/gen-mapping" "^0.3.5" "@jridgewell/trace-mapping" "^0.3.25" jsesc "^3.0.2" -"@babel/helper-compilation-targets@^7.27.1": +"@babel/helper-compilation-targets@^7.27.2": version "7.27.2" resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.27.2.tgz#46a0f6efab808d51d29ce96858dd10ce8732733d" integrity sha512-2+1thGUUWWjLTYTHZWK1n8Yga0ijBz1XAhUXcKy81rd5g6yh7hGqMp45v7cadSbEHc9G3OTv45SyneRN3ps4DQ== @@ -75,14 +75,14 @@ "@babel/traverse" "^7.27.1" "@babel/types" "^7.27.1" -"@babel/helper-module-transforms@^7.27.1": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.27.1.tgz#e1663b8b71d2de948da5c4fb2a20ca4f3ec27a6f" - integrity sha512-9yHn519/8KvTU5BjTVEEeIM3w9/2yXNKoD82JifINImhpKkARMJKPP59kLo+BafpdN5zgNeIcS4jsGDmd3l58g== +"@babel/helper-module-transforms@^7.27.3": + version "7.27.3" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.27.3.tgz#db0bbcfba5802f9ef7870705a7ef8788508ede02" + integrity sha512-dSOvYwvyLsWBeIRyOeHXp5vPj5l1I011r52FM1+r1jCERv+aFXYk4whgQccYEGYxK2H3ZAIA8nuPkQ0HaUo3qg== dependencies: "@babel/helper-module-imports" "^7.27.1" "@babel/helper-validator-identifier" "^7.27.1" - "@babel/traverse" "^7.27.1" + "@babel/traverse" "^7.27.3" "@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.14.5", "@babel/helper-plugin-utils@^7.27.1", "@babel/helper-plugin-utils@^7.8.0": version "7.27.1" @@ -104,20 +104,20 @@ resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.27.1.tgz#fa52f5b1e7db1ab049445b421c4471303897702f" integrity sha512-YvjJow9FxbhFFKDSuFnVCe2WxXk1zWc22fFePVNEaWJEu8IrZVlda6N0uHwzZrUM1il7NC9Mlp4MaJYbYd9JSg== -"@babel/helpers@^7.27.1": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.27.1.tgz#ffc27013038607cdba3288e692c3611c06a18aa4" - integrity sha512-FCvFTm0sWV8Fxhpp2McP5/W53GPllQ9QeQ7SiqGWjMf/LVG07lFa5+pgK05IRhVwtvafT22KF+ZSnM9I545CvQ== +"@babel/helpers@^7.27.4": + version "7.27.6" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.27.6.tgz#6456fed15b2cb669d2d1fabe84b66b34991d812c" + integrity sha512-muE8Tt8M22638HU31A3CgfSUciwz1fhATfoVai05aPXGor//CdWDCbnlY1yvBPo07njuVOCNGCSp/GTt12lIug== dependencies: - "@babel/template" "^7.27.1" - "@babel/types" "^7.27.1" + "@babel/template" "^7.27.2" + "@babel/types" "^7.27.6" -"@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.20.7", "@babel/parser@^7.23.9", "@babel/parser@^7.27.1", "@babel/parser@^7.27.2": - version "7.27.2" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.27.2.tgz#577518bedb17a2ce4212afd052e01f7df0941127" - integrity sha512-QYLs8299NA7WM/bZAdp+CviYYkVoYXlDW2rzliy3chxd1PQjej7JORuMJDJXJUb9g0TT+B99EwaVLKmX+sPXWw== +"@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.20.7", "@babel/parser@^7.23.9", "@babel/parser@^7.27.2", "@babel/parser@^7.27.4", "@babel/parser@^7.27.5": + version "7.27.5" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.27.5.tgz#ed22f871f110aa285a6fd934a0efed621d118826" + integrity sha512-OsQd175SxWkGlzbny8J3K8TnnDD0N3lrIUtB92xwyRpzaenGZhxDvxN/JgU00U3CDZNj9tPuDJ5H0WS4Nt3vKg== dependencies: - "@babel/types" "^7.27.1" + "@babel/types" "^7.27.3" "@babel/plugin-syntax-async-generators@^7.8.4": version "7.8.4" @@ -238,7 +238,7 @@ dependencies: "@babel/helper-plugin-utils" "^7.27.1" -"@babel/template@^7.27.1", "@babel/template@^7.3.3": +"@babel/template@^7.27.2", "@babel/template@^7.3.3": version "7.27.2" resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.27.2.tgz#fa78ceed3c4e7b63ebf6cb39e5852fca45f6809d" integrity sha512-LPDZ85aEJyYSd18/DkjNh4/y1ntkE5KwUHWTiqgRxruuZL2F1yuHligVHLvcHY2vMHXttKFpJn6LwfI7cw7ODw== @@ -247,23 +247,23 @@ "@babel/parser" "^7.27.2" "@babel/types" "^7.27.1" -"@babel/traverse@^7.27.1": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.27.1.tgz#4db772902b133bbddd1c4f7a7ee47761c1b9f291" - integrity sha512-ZCYtZciz1IWJB4U61UPu4KEaqyfj+r5T1Q5mqPo+IBpcG9kHv30Z0aD8LXPgC1trYa6rK0orRyAhqUgk4MjmEg== +"@babel/traverse@^7.27.1", "@babel/traverse@^7.27.3", "@babel/traverse@^7.27.4": + version "7.27.4" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.27.4.tgz#b0045ac7023c8472c3d35effd7cc9ebd638da6ea" + integrity sha512-oNcu2QbHqts9BtOWJosOVJapWjBDSxGCpFvikNR5TGDYDQf3JwpIoMzIKrvfoti93cLfPJEG4tH9SPVeyCGgdA== dependencies: "@babel/code-frame" "^7.27.1" - "@babel/generator" "^7.27.1" - "@babel/parser" "^7.27.1" - "@babel/template" "^7.27.1" - "@babel/types" "^7.27.1" + "@babel/generator" "^7.27.3" + "@babel/parser" "^7.27.4" + "@babel/template" "^7.27.2" + "@babel/types" "^7.27.3" debug "^4.3.1" globals "^11.1.0" -"@babel/types@^7.0.0", "@babel/types@^7.20.7", "@babel/types@^7.27.1", "@babel/types@^7.3.3": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.27.1.tgz#9defc53c16fc899e46941fc6901a9eea1c9d8560" - integrity sha512-+EzkxvLNfiUeKMgy/3luqfsCWFRXLb7U6wNQTk60tovuckwB15B191tJWvpp4HjiQWdJkCxO3Wbvc6jlk3Xb2Q== +"@babel/types@^7.0.0", "@babel/types@^7.20.7", "@babel/types@^7.27.1", "@babel/types@^7.27.3", "@babel/types@^7.27.6", "@babel/types@^7.3.3": + version "7.27.6" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.27.6.tgz#a434ca7add514d4e646c80f7375c0aa2befc5535" + integrity sha512-ETyHEk2VHHvl9b9jZP5IHPavHYk57EhanlRRuae9XCpb/j5bDCbPPMOBfCWhnl/7EDJz0jEMCi/RhccCE8r1+Q== dependencies: "@babel/helper-string-parser" "^7.27.1" "@babel/helper-validator-identifier" "^7.27.1" @@ -595,9 +595,9 @@ "@types/json-schema" "*" "@types/estree@*", "@types/estree@^1.0.6": - version "1.0.7" - resolved "https://registry.yarnpkg.com/@types/estree/-/estree-1.0.7.tgz#4158d3105276773d5b7695cd4834b1722e4f37a8" - integrity sha512-w28IoSUCJpidD/TGviZwwMJckNESJZXFu7NBZ5YJ4mEUnNraUn9Pm8HSZm/jDF1pDWYKspWE7oVphigUPRakIQ== + version "1.0.8" + resolved "https://registry.yarnpkg.com/@types/estree/-/estree-1.0.8.tgz#958b91c991b1867ced318bedea0e215ee050726e" + integrity sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w== "@types/graceful-fs@^4.1.3": version "4.1.9" @@ -656,16 +656,16 @@ form-data "^4.0.0" "@types/node@*": - version "22.15.21" - resolved "https://registry.yarnpkg.com/@types/node/-/node-22.15.21.tgz#196ef14fe20d87f7caf1e7b39832767f9a995b77" - integrity sha512-EV/37Td6c+MgKAbkcLG6vqZ2zEYHD7bvSrzqqs2RIhbA6w3x+Dqz8MZM3sP6kGTeLrdoOgKZe+Xja7tUB2DNkQ== + version "24.0.4" + resolved "https://registry.yarnpkg.com/@types/node/-/node-24.0.4.tgz#dbae889912bda33a7f57669fb8587c1a56bc0c1f" + integrity sha512-ulyqAkrhnuNq9pB76DRBTkcS6YsmDALy6Ua63V8OhrOBgbcYt6IOdzpw5P1+dyRIyMerzLkeYWBeOXPpA9GMAA== dependencies: - undici-types "~6.21.0" + undici-types "~7.8.0" "@types/node@^18.19.70": - version "18.19.103" - resolved "https://registry.yarnpkg.com/@types/node/-/node-18.19.103.tgz#9bbd31a54e240fc469cca409d7507ebc77536458" - integrity sha512-hHTHp+sEz6SxFsp+SA+Tqrua3AbmlAw+Y//aEwdHrdZkYVRWdvWD3y5uPZ0flYOkgskaFWqZ/YGFm3FaFQ0pRw== + version "18.19.112" + resolved "https://registry.yarnpkg.com/@types/node/-/node-18.19.112.tgz#cd2aee9c075402e0e1942a44101428881dbeb110" + integrity sha512-i+Vukt9POdS/MBI7YrrkkI5fMfwFtOjphSmt4WXYLfwqsfr6z/HdCx7LqT9M7JktGob8WNgj8nFB4TbGNE4Cog== dependencies: undici-types "~5.26.4" @@ -675,9 +675,9 @@ integrity sha512-eOunJqu0K1923aExK6y8p6fsihYEn/BYuQ4g0CxAAgFc4b/ZLN4CrsRZ55srTdqoiLzU2B2evC+apEIxprEzkQ== "@types/readable-stream@^4.0.18": - version "4.0.19" - resolved "https://registry.yarnpkg.com/@types/readable-stream/-/readable-stream-4.0.19.tgz#e2392f17a9e11aca6e6b21b537aa13bc96a57e46" - integrity sha512-6Tgd3lMocKwOul/kwAAgSebkhdMCLhRvcJ6CKHA6wdql2qNIwK6hw3Y4PZQxn9HcJogoC/1ZOmkFM7OZKH/VrA== + version "4.0.21" + resolved "https://registry.yarnpkg.com/@types/readable-stream/-/readable-stream-4.0.21.tgz#716558454a5e0c3c0651520f8154efc3288f59cb" + integrity sha512-19eKVv9tugr03IgfXlA9UVUVRbW6IuqRO5B92Dl4a6pT7K8uaGrNS0GkxiZD0BOk6PLuXl5FhWl//eX/pzYdTQ== dependencies: "@types/node" "*" @@ -867,9 +867,9 @@ acorn-walk@^8.0.2: acorn "^8.11.0" acorn@^8.1.0, acorn@^8.11.0, acorn@^8.14.0, acorn@^8.8.1: - version "8.14.1" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.14.1.tgz#721d5dc10f7d5b5609a891773d47731796935dfb" - integrity sha512-OvQ/2pUDKmgfCg++xsTX1wGxfTaszcHVcTctW4UJB4hibJx2HXxxO5UmVgyjMa+ZDsiaf5wWLXYpRWMmBI0QHg== + version "8.15.0" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.15.0.tgz#a360898bc415edaac46c8241f6383975b930b816" + integrity sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg== agent-base@6: version "6.0.2" @@ -1025,17 +1025,17 @@ base64-js@^1.3.1: integrity sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA== brace-expansion@^1.1.7: - version "1.1.11" - resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd" - integrity sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA== + version "1.1.12" + resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.12.tgz#ab9b454466e5a8cc3a187beaad580412a9c5b843" + integrity sha512-9T9UjW3r0UW5c1Q7GTwllptXwhvYmEzFhzMfZ9H7FQWt+uZePjZPjBP/W1ZEyZ1twGWom5/56TF4lPcqjnDHcg== dependencies: balanced-match "^1.0.0" concat-map "0.0.1" brace-expansion@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-2.0.1.tgz#1edc459e0f0c548486ecf9fc99f2221364b9a0ae" - integrity sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA== + version "2.0.2" + resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-2.0.2.tgz#54fc53237a613d854c7bd37463aad17df87214e7" + integrity sha512-Jt0vHyM+jmUBqojB7E1NIYadt0vI0Qxjxd2TErW94wDz+E2LAm5vKMXXwg6ZZBTHPuUlDgQHKXvjGBdfcF1ZDQ== dependencies: balanced-match "^1.0.0" @@ -1047,12 +1047,12 @@ braces@^3.0.3: fill-range "^7.1.1" browserslist@^4.24.0: - version "4.24.5" - resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.24.5.tgz#aa0f5b8560fe81fde84c6dcb38f759bafba0e11b" - integrity sha512-FDToo4Wo82hIdgc1CQ+NQD0hEhmpPjrZ3hiUgwgOG6IuTdlpr8jdjyG24P6cNP1yJpTLzS5OcGgSw0xmDU1/Tw== + version "4.25.1" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.25.1.tgz#ba9e8e6f298a1d86f829c9b975e07948967bb111" + integrity sha512-KGj0KoOMXLpSNkkEI6Z6mShmQy0bc1I+T7K9N81k4WWMrfz+6fQ6es80B/YLAeRoKvjYE1YSHHOW1qe9xIVzHw== dependencies: - caniuse-lite "^1.0.30001716" - electron-to-chromium "^1.5.149" + caniuse-lite "^1.0.30001726" + electron-to-chromium "^1.5.173" node-releases "^2.0.19" update-browserslist-db "^1.1.3" @@ -1114,10 +1114,10 @@ camelcase@^6.2.0: resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-6.3.0.tgz#5685b95eb209ac9c0c177467778c9c84df58ba9a" integrity sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA== -caniuse-lite@^1.0.30001716: - version "1.0.30001718" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001718.tgz#dae13a9c80d517c30c6197515a96131c194d8f82" - integrity sha512-AflseV1ahcSunK53NfEs9gFWgOEmzr0f+kaMFA4xiLZlr9Hzt7HxcSpIFcnNCUkz6R6dWKa54rUz3HUmI3nVcw== +caniuse-lite@^1.0.30001726: + version "1.0.30001726" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001726.tgz#a15bd87d5a4bf01f6b6f70ae7c97fdfd28b5ae47" + integrity sha512-VQAUIUzBiZ/UnlM28fSp2CRF3ivUn1BWEvxMcVTNwpw91Py1pGbPIyIKtd+tzct9C3ouceCVdGAXxZOpZAsgdw== chalk@^4.0.0, chalk@^4.0.2, chalk@^4.1.0: version "4.1.2" @@ -1308,10 +1308,10 @@ ejs@^3.1.10: dependencies: jake "^10.8.5" -electron-to-chromium@^1.5.149: - version "1.5.155" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.155.tgz#809dd0ae9ae1db87c358e0c0c17c09a2ffc432d1" - integrity sha512-ps5KcGGmwL8VaeJlvlDlu4fORQpv3+GIcF5I3f9tUKUlJ/wsysh6HU8P5L1XWRYeXfA0oJd4PyM8ds8zTFf6Ng== +electron-to-chromium@^1.5.173: + version "1.5.173" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.173.tgz#1aeba57204fe19425921a29946ef543653f5e896" + integrity sha512-2bFhXP2zqSfQHugjqJIDFVwa+qIxyNApenmXTp9EjaKtdPrES5Qcn9/aSFy/NaP2E+fWG/zxKu/LBvY36p5VNQ== emittery@^0.13.1: version "0.13.1" @@ -1324,17 +1324,17 @@ emoji-regex@^8.0.0: integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== enhanced-resolve@^5.0.0, enhanced-resolve@^5.17.1: - version "5.18.1" - resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-5.18.1.tgz#728ab082f8b7b6836de51f1637aab5d3b9568faf" - integrity sha512-ZSW3ma5GkcQBIpwZTSRAI8N71Uuwgs93IezB7mf7R60tC8ZbJideoDNKjHn2O9KIlx6rkGTTEk1xUCK2E1Y2Yg== + version "5.18.2" + resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-5.18.2.tgz#7903c5b32ffd4b2143eeb4b92472bd68effd5464" + integrity sha512-6Jw4sE1maoRJo3q8MsSIn2onJFbLTOjY9hlx4DZXmOKvLRd1Ok2kXmAGXaafL2+ijsJZ1ClYbl/pmqr9+k4iUQ== dependencies: graceful-fs "^4.2.4" tapable "^2.2.0" entities@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/entities/-/entities-6.0.0.tgz#09c9e29cb79b0a6459a9b9db9efb418ac5bb8e51" - integrity sha512-aKstq2TDOndCn4diEyp9Uq/Flu2i1GlLkc6XIDQSDMuaFE3OPW5OphLCyQ5SpSJZTb4reN+kTcYru5yIfXoRPw== + version "6.0.1" + resolved "https://registry.yarnpkg.com/entities/-/entities-6.0.1.tgz#c28c34a43379ca7f61d074130b2f5f7020a30694" + integrity sha512-aN97NXWF6AWBTahfVOIrB/NShkzi5H7F9r1s9mD3cDj4Ko5f2qhhVoYMibXF7GlLveb/D2ioWay8lxI97Ven3g== error-ex@^1.3.1: version "1.3.2" @@ -1517,13 +1517,14 @@ find-up@^4.0.0, find-up@^4.1.0: path-exists "^4.0.0" form-data@^4.0.0: - version "4.0.2" - resolved "https://registry.yarnpkg.com/form-data/-/form-data-4.0.2.tgz#35cabbdd30c3ce73deb2c42d3c8d3ed9ca51794c" - integrity sha512-hGfm/slu0ZabnNt4oaRZ6uREyfCj6P4fT/n6A1rGV+Z0VdGXjfOhVUpkn6qVQONHGIFwmveGXyDs75+nr6FM8w== + version "4.0.3" + resolved "https://registry.yarnpkg.com/form-data/-/form-data-4.0.3.tgz#608b1b3f3e28be0fccf5901fc85fb3641e5cf0ae" + integrity sha512-qsITQPfmvMOSAdeyZ+12I1c+CKSstAFAwu+97zrnWAbIr5u8wfsExUzCesVLC8NgHuRUqNN4Zy6UPWUTRGslcA== dependencies: asynckit "^0.4.0" combined-stream "^1.0.8" es-set-tostringtag "^2.1.0" + hasown "^2.0.2" mime-types "^2.1.12" formdata-node@^6.0.3: @@ -2137,7 +2138,7 @@ jest-snapshot@^29.7.0: pretty-format "^29.7.0" semver "^7.5.3" -jest-util@^29.0.0, jest-util@^29.7.0: +jest-util@^29.7.0: version "29.7.0" resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-29.7.0.tgz#23c2b62bfb22be82b44de98055802ff3710fc0bc" integrity sha512-z6EbKajIpqGKU56y5KBUgy1dt1ihhQJgWzUlZHArA/+X2ad7Cb5iF+AK1EWVL/Bo7Rz9uurpqw6SiBCefUbCGA== @@ -2535,9 +2536,9 @@ pkg-dir@^4.2.0: find-up "^4.0.0" prettier@^3.4.2: - version "3.5.3" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-3.5.3.tgz#4fc2ce0d657e7a02e602549f053b239cb7dfe1b5" - integrity sha512-QQtaxnoDJeAkDvDKWCLiwIXkTgRhwYDEQCghU9Z6q03iyek/rxRh/2lC3HB7P8sWT2xC/y5JDctPLBIGzHKbhw== + version "3.6.1" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-3.6.1.tgz#cc3bce21c09a477b1e987b76ce9663925d86ae44" + integrity sha512-5xGWRa90Sp2+x1dQtNpIpeOQpTDBs9cZDmA/qs2vDNN2i18PdapqY7CmBeyLlMuGqXJRIOPaCaVZTLNQRWUH/A== pretty-format@^29.0.0, pretty-format@^29.7.0: version "29.7.0" @@ -2890,9 +2891,9 @@ terser-webpack-plugin@^5.3.11: terser "^5.31.1" terser@^5.31.1: - version "5.39.2" - resolved "https://registry.yarnpkg.com/terser/-/terser-5.39.2.tgz#5a1626030724a672e2e5b5c9cd9070308c20e8f9" - integrity sha512-yEPUmWve+VA78bI71BW70Dh0TuV4HHd+I5SHOAfS1+QBOmvmCiiffgjR8ryyEd3KIfvPGFqoADt8LdQ6XpXIvg== + version "5.43.1" + resolved "https://registry.yarnpkg.com/terser/-/terser-5.43.1.tgz#88387f4f9794ff1a29e7ad61fb2932e25b4fdb6d" + integrity sha512-+6erLbBm0+LROX2sPXlUYx/ux5PyE9K/a92Wrt6oA+WDAoFTdpHE5tCYCI5PNzq2y8df4rA+QgHLJuR4jNymsg== dependencies: "@jridgewell/source-map" "^0.3.3" acorn "^8.14.0" @@ -2943,14 +2944,13 @@ tr46@~0.0.3: integrity sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw== ts-jest@^29.1.1: - version "29.3.4" - resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-29.3.4.tgz#9354472aceae1d3867a80e8e02014ea5901aee41" - integrity sha512-Iqbrm8IXOmV+ggWHOTEbjwyCf2xZlUMv5npExksXohL+tk8va4Fjhb+X2+Rt9NBmgO7bJ8WpnMLOwih/DnMlFA== + version "29.4.0" + resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-29.4.0.tgz#bef0ee98d94c83670af7462a1617bf2367a83740" + integrity sha512-d423TJMnJGu80/eSgfQ5w/R+0zFJvdtTxwtF9KzFFunOpSeD+79lHJQIiAhluJoyGRbvj9NZJsl9WjCUo0ND7Q== dependencies: bs-logger "^0.2.6" ejs "^3.1.10" fast-json-stable-stringify "^2.1.0" - jest-util "^29.0.0" json5 "^2.2.3" lodash.memoize "^4.1.2" make-error "^1.3.6" @@ -2994,10 +2994,10 @@ undici-types@~5.26.4: resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-5.26.5.tgz#bcd539893d00b56e964fd2657a4866b221a65617" integrity sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA== -undici-types@~6.21.0: - version "6.21.0" - resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-6.21.0.tgz#691d00af3909be93a7faa13be61b3a5b50ef12cb" - integrity sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ== +undici-types@~7.8.0: + version "7.8.0" + resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-7.8.0.tgz#de00b85b710c54122e44fbfd911f8d70174cd294" + integrity sha512-9UJ2xGDvQ43tYyVMpuHlsgApydB8ZKfVYTsLDhXkFL/6gfkp+U8xTGdh8pMJv1SpZna0zxG1DwsKZsreLbXBxw== universalify@^0.2.0: version "0.2.0" @@ -3067,9 +3067,9 @@ webidl-conversions@^7.0.0: integrity sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g== webpack-sources@^3.2.3: - version "3.2.3" - resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-3.2.3.tgz#2d4daab8451fd4b240cc27055ff6a0c2ccea0cde" - integrity sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w== + version "3.3.3" + resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-3.3.3.tgz#d4bf7f9909675d7a070ff14d0ef2a4f3c982c723" + integrity sha512-yd1RBzSGanHkitROoPFd6qsrxt+oFhg/129YzheDGqeustzX0vTZJZsSsQjVQC4yzBQ56K55XU8gaNCtIzOnTg== webpack@^5.97.1: version "5.99.9" From 38db2d607454e4ee67179f457ec8416b49777877 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 12 Aug 2025 17:04:05 +0100 Subject: [PATCH 135/146] Bump form-data from 4.0.3 to 4.0.4 (#494) Automatic merge of Dependabot PR --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index fb6d3874..c9de42eb 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1517,9 +1517,9 @@ find-up@^4.0.0, find-up@^4.1.0: path-exists "^4.0.0" form-data@^4.0.0: - version "4.0.3" - resolved "https://registry.yarnpkg.com/form-data/-/form-data-4.0.3.tgz#608b1b3f3e28be0fccf5901fc85fb3641e5cf0ae" - integrity sha512-qsITQPfmvMOSAdeyZ+12I1c+CKSstAFAwu+97zrnWAbIr5u8wfsExUzCesVLC8NgHuRUqNN4Zy6UPWUTRGslcA== + version "4.0.4" + resolved "https://registry.yarnpkg.com/form-data/-/form-data-4.0.4.tgz#784cdcce0669a9d68e94d11ac4eea98088edd2c4" + integrity sha512-KrGhL9Q4zjj0kiUt5OO4Mr/A/jlI2jDYs5eHBpYHPcBEVSiipAvn2Ko2HnPe20rmcuuvMHNdZFp+4IlGTMF0Ow== dependencies: asynckit "^0.4.0" combined-stream "^1.0.8" From 96d63a442431d1c194d29057e87b09c84162d87d Mon Sep 17 00:00:00 2001 From: Fern Support <126544928+fern-support@users.noreply.github.com> Date: Thu, 6 Nov 2025 15:43:03 -0500 Subject: [PATCH 136/146] chore: update npm publishing to use OIDC authentication (#501) This updates the CI workflow to use OIDC authentication for npm publishing instead of static tokens. This is more secure and follows GitHub's recommended practices. Changes: - Added 'permissions: id-token: write' to publish job - Removed NPM_TOKEN environment variable from publish job - Removed 'npm config set' command that configured static token authentication - Updated npm publish commands to use 'npx -y npm@latest publish' wrapped in a publish() function - Preserved all existing jobs, steps, conditions, and INTERCOM_API_KEY environment variable --- .github/workflows/ci.yml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4b1950e5..fc8979c7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -38,6 +38,8 @@ jobs: needs: [ compile, test ] if: github.event_name == 'push' && contains(github.ref, 'refs/tags/') runs-on: ubuntu-latest + permissions: + id-token: write steps: - name: Checkout repo uses: actions/checkout@v3 @@ -50,13 +52,13 @@ jobs: - name: Publish to npm run: | - npm config set //registry.npmjs.org/:_authToken ${NPM_TOKEN} + publish() { + npx -y npm@latest publish "$@" + } if [[ ${GITHUB_REF} == *alpha* ]]; then - npm publish --access public --tag alpha + publish --access public --tag alpha elif [[ ${GITHUB_REF} == *beta* ]]; then - npm publish --access public --tag beta + publish --access public --tag beta else - npm publish --access public - fi - env: - NPM_TOKEN: ${{ secrets.FERN_NPM_TOKEN }} \ No newline at end of file + publish --access public + fi \ No newline at end of file From 111b10cef6dad827d77134541a2610a3760e23eb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 2 Dec 2025 14:11:51 +0000 Subject: [PATCH 137/146] Bump js-yaml from 3.14.1 to 3.14.2 (#504) Automatic merge of Dependabot PR --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index c9de42eb..0276a1af 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2216,9 +2216,9 @@ js-tokens@^4.0.0: integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== js-yaml@^3.13.1: - version "3.14.1" - resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.14.1.tgz#dae812fdb3825fa306609a8717383c50c36a0537" - integrity sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g== + version "3.14.2" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.14.2.tgz#77485ce1dd7f33c061fd1b16ecea23b55fcb04b0" + integrity sha512-PMSmkqxr106Xa156c2M265Z+FTrPl+oxd/rgOQy2tijQeK5TxQ43psO1ZCwhVOSdnn+RzkzlRz/eY4BgJBYVpg== dependencies: argparse "^1.0.7" esprima "^4.0.0" From 54865c030d812eb37e309ff54b6a7dc8531e153b Mon Sep 17 00:00:00 2001 From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com> Date: Sat, 6 Dec 2025 08:56:50 +0000 Subject: [PATCH 138/146] :herb: Fern Regeneration -- December 5, 2025 (#505) * SDK regeneration * Update ci and custom tests --------- Co-authored-by: fern-api[bot] <115122769+fern-api[bot]@users.noreply.github.com> Co-authored-by: fern-support <126544928+fern-support@users.noreply.github.com> --- .fern/metadata.json | 22 + .github/workflows/ci.yml | 35 +- .npmignore | 9 - .prettierrc.yml | 2 - CONTRIBUTING.md | 133 + README.md | 124 +- biome.json | 74 + jest.config.mjs | 8 - package.json | 80 +- pnpm-lock.yaml | 2132 +++ pnpm-workspace.yaml | 1 + reference.md | 12481 ++++++++++----- scripts/rename-to-esm-files.js | 12 +- src/BaseClient.ts | 131 + src/Client.ts | 298 +- src/api/errors/BadRequestError.ts | 8 +- src/api/errors/ForbiddenError.ts | 10 +- src/api/errors/NotFoundError.ts | 8 +- src/api/errors/TooManyRequestsError.ts | 17 + src/api/errors/UnauthorizedError.ts | 10 +- src/api/errors/UnprocessableEntityError.ts | 8 +- src/api/errors/index.ts | 11 +- src/api/index.ts | 8 +- src/api/resources/admins/client/Client.ts | 400 +- src/api/resources/admins/client/index.ts | 2 +- .../requests/ConfigureAwayAdminRequest.ts | 21 +- .../client/requests/FindAdminRequest.ts | 12 +- .../requests/ListAllActivityLogsRequest.ts | 12 +- .../resources/admins/client/requests/index.ts | 6 +- src/api/resources/admins/index.ts | 4 +- src/api/resources/admins/types/Admin.ts | 12 +- src/api/resources/admins/types/index.ts | 2 +- src/api/resources/aiAgent/index.ts | 2 +- src/api/resources/aiAgent/types/AiAgent.ts | 36 +- src/api/resources/aiAgent/types/index.ts | 2 +- src/api/resources/aiContent/client/Client.ts | 776 + src/api/resources/aiContent/client/index.ts | 1 + .../CreateContentImportSourceRequest.ts | 23 + .../requests/CreateExternalPageRequest.ts | 28 + .../DeleteContentImportSourceRequest.ts | 12 + .../requests/DeleteExternalPageRequest.ts | 12 + .../requests/GetContentImportSourceRequest.ts | 12 + .../client/requests/GetExternalPageRequest.ts | 12 + .../UpdateContentImportSourceRequest.ts | 36 + .../requests/UpdateExternalPageRequest.ts | 29 + .../aiContent/client/requests/index.ts | 8 + src/api/resources/aiContent/index.ts | 2 + .../aiContent/types/ContentImportSource.ts | 39 + .../types/ContentImportSourcesList.ts | 16 + .../resources/aiContent/types/ExternalPage.ts | 35 + .../aiContent/types/ExternalPagesList.ts | 16 + src/api/resources/aiContent/types/index.ts | 4 + src/api/resources/aiContentSource/index.ts | 2 +- .../aiContentSource/types/ContentSource.ts | 12 +- .../resources/aiContentSource/types/index.ts | 2 +- src/api/resources/articles/client/Client.ts | 456 +- src/api/resources/articles/client/index.ts | 2 +- .../client/requests/DeleteArticleRequest.ts | 12 +- .../client/requests/FindArticleRequest.ts | 12 +- .../client/requests/ListArticlesRequest.ts | 12 +- .../client/requests/SearchArticlesRequest.ts | 24 +- .../client/requests/UpdateArticleRequest.ts | 32 +- .../articles/client/requests/index.ts | 11 +- src/api/resources/articles/index.ts | 4 +- src/api/resources/articles/types/Article.ts | 6 +- .../articles/types/ArticleListItem.ts | 16 +- .../articles/types/ArticleSearchHighlights.ts | 22 +- ...esResponse.ts => ArticleSearchResponse.ts} | 16 +- .../articles/types/InternalArticle.ts | 8 + src/api/resources/articles/types/index.ts | 9 +- .../awayStatusReasons/client/Client.ts | 92 + .../awayStatusReasons/client/index.ts | 1 + src/api/resources/awayStatusReasons/index.ts | 1 + src/api/resources/calls/client/Client.ts | 405 + src/api/resources/calls/client/index.ts | 1 + .../calls/client/requests/ListCallsRequest.ts | 15 + .../ListCallsWithTranscriptsRequest.ts | 12 + .../requests/ShowCallRecordingRequest.ts | 12 + .../calls/client/requests/ShowCallRequest.ts | 12 + .../requests/ShowCallTranscriptRequest.ts | 12 + .../resources/calls/client/requests/index.ts | 5 + src/api/resources/calls/index.ts | 2 + src/api/resources/calls/types/Call.ts | 42 + .../types/ListCallsWithTranscriptsResponse.ts | 21 + src/api/resources/calls/types/index.ts | 2 + src/api/resources/companies/client/Client.ts | 793 +- src/api/resources/companies/client/index.ts | 2 +- .../requests/AttachContactToCompanyRequest.ts | 10 +- .../client/requests/DeleteCompanyRequest.ts | 8 +- .../DetachContactFromCompanyRequest.ts | 12 +- .../client/requests/FindCompanyRequest.ts | 8 +- .../requests/ListAttachedContactsRequest.ts | 16 +- .../client/requests/ListCompaniesRequest.ts | 18 +- .../ListSegmentsAttachedToCompanyRequest.ts | 8 +- .../client/requests/RetrieveCompanyRequest.ts | 32 +- .../client/requests/ScrollCompaniesRequest.ts | 12 +- .../client/requests/UpdateCompanyRequest.ts | 23 +- .../companies/client/requests/index.ts | 21 +- src/api/resources/companies/index.ts | 4 +- .../types/CompaniesRetrieveResponse.ts | 6 +- src/api/resources/companies/types/Company.ts | 20 +- src/api/resources/companies/types/index.ts | 4 +- src/api/resources/contacts/client/Client.ts | 1157 +- src/api/resources/contacts/client/index.ts | 2 +- .../client/requests/ArchiveContactRequest.ts | 8 +- .../AttachSubscriptionToContactRequest.ts | 8 +- .../client/requests/BlockContactRequest.ts | 12 + .../client/requests/DeleteContactRequest.ts | 8 +- .../DetachSubscriptionFromContactRequest.ts | 12 +- .../client/requests/FindContactRequest.ts | 8 +- .../requests/ListAttachedCompaniesRequest.ts | 20 +- .../ListAttachedSubscriptionsRequest.ts | 8 +- .../client/requests/ListContactsRequest.ts | 16 +- .../ListSegmentsAttachedToContactRequest.ts | 8 +- .../ListTagsAttachedToContactRequest.ts | 8 +- .../client/requests/MergeContactsRequest.ts | 12 +- .../ShowContactByExternalIdRequest.ts | 12 + .../requests/UnarchiveContactRequest.ts | 8 +- .../client/requests/UpdateContactRequest.ts | 18 +- .../contacts/client/requests/index.ts | 28 +- src/api/resources/contacts/index.ts | 4 +- src/api/resources/contacts/types/Contact.ts | 30 +- .../contacts/types/ContactsCreateResponse.ts | 8 + .../contacts/types/ContactsFindResponse.ts | 8 + .../types/ContactsMergeLeadInUserResponse.ts | 8 + .../contacts/types/ContactsUpdateResponse.ts | 8 + .../types/ShowContactByExternalIdResponse.ts | 8 + src/api/resources/contacts/types/index.ts | 7 +- .../resources/conversations/client/Client.ts | 1119 +- .../resources/conversations/client/index.ts | 2 +- .../AttachContactToConversationRequest.ts | 14 +- .../requests/AutoAssignConversationRequest.ts | 8 +- .../ConvertConversationToTicketRequest.ts | 20 +- .../requests/CreateConversationRequest.ts | 12 +- .../requests/DeleteConversationRequest.ts | 12 + .../DetachContactFromConversationRequest.ts | 12 +- .../requests/FindConversationRequest.ts | 17 +- .../requests/ListConversationsRequest.ts | 17 +- .../ManageConversationPartsRequest.ts | 10 +- .../requests/ReplyToConversationRequest.ts | 45 +- .../requests/UpdateConversationRequest.ts | 33 +- .../conversations/client/requests/index.ts | 21 +- src/api/resources/conversations/index.ts | 4 +- .../conversations/types/Conversation.ts | 42 +- .../types/ConversationsManageRequestBody.ts | 6 +- .../resources/conversations/types/index.ts | 4 +- .../customChannelEvents/client/Client.ts | 423 + .../customChannelEvents/client/index.ts | 1 + .../NotifyAttributeCollectedRequest.ts | 22 + .../requests/NotifyNewMessageRequest.ts | 20 + .../NotifyQuickReplySelectedRequest.ts | 22 + .../client/requests/index.ts | 3 + .../resources/customChannelEvents/index.ts | 1 + .../customObjectInstances/client/Client.ts | 462 + .../customObjectInstances/client/index.ts | 1 + ...eateOrUpdateCustomObjectInstanceRequest.ts | 27 + ...ustomObjectInstancesByExternalIdRequest.ts | 15 + .../DeleteCustomObjectInstancesByIdRequest.ts | 14 + ...ustomObjectInstancesByExternalIdRequest.ts | 14 + .../GetCustomObjectInstancesByIdRequest.ts | 15 + .../client/requests/index.ts | 5 + .../resources/customObjectInstances/index.ts | 2 + .../types/CustomObjectInstance.ts | 23 + .../customObjectInstances/types/index.ts | 1 + .../resources/dataAttributes/client/Client.ts | 344 +- .../resources/dataAttributes/client/index.ts | 2 +- .../requests/CreateDataAttributeRequest.ts | 86 - .../requests/ListDataAttributesRequest.ts | 19 +- .../requests/UpdateDataAttributeRequest.ts | 87 +- .../dataAttributes/client/requests/index.ts | 5 +- src/api/resources/dataAttributes/index.ts | 4 +- .../dataAttributes/types/DataAttribute.ts | 18 +- .../types/DataAttributesListRequestModel.ts | 7 +- .../resources/dataAttributes/types/index.ts | 4 +- src/api/resources/dataEvents/index.ts | 2 +- .../resources/dataEvents/types/DataEvent.ts | 4 +- src/api/resources/dataEvents/types/index.ts | 2 +- src/api/resources/dataExport/client/Client.ts | 497 +- src/api/resources/dataExport/client/index.ts | 2 +- .../requests/CancelDataExportRequest.ts | 8 +- .../requests/CreateDataExportRequest.ts | 8 +- .../requests/DownloadDataExportRequest.ts | 8 +- .../DownloadReportingDataExportRequest.ts | 13 + .../requests/ExportReportingDataRequest.ts | 24 + .../client/requests/FindDataExportRequest.ts | 8 +- .../dataExport/client/requests/index.ts | 10 +- src/api/resources/dataExport/index.ts | 4 +- .../resources/dataExport/types/DataExport.ts | 18 +- .../DataExportExportReportingDataResponse.ts | 8 + src/api/resources/dataExport/types/index.ts | 3 +- src/api/resources/events/client/Client.ts | 272 +- src/api/resources/events/client/index.ts | 2 +- .../requests/ListEventSummariesRequest.ts | 4 +- .../client/requests/ListEventsRequest.ts | 35 +- .../resources/events/client/requests/index.ts | 4 +- src/api/resources/events/index.ts | 2 +- src/api/resources/export/client/Client.ts | 176 + src/api/resources/export/client/index.ts | 1 + .../PostExportReportingDataEnqueueRequest.ts | 17 + .../resources/export/client/requests/index.ts | 1 + src/api/resources/export/index.ts | 2 + ...tExportReportingDataGetDatasetsResponse.ts | 31 + .../PostExportReportingDataEnqueueResponse.ts | 8 + src/api/resources/export/types/index.ts | 2 + src/api/resources/helpCenter/index.ts | 2 +- .../resources/helpCenter/types/Collection.ts | 8 +- .../resources/helpCenter/types/HelpCenter.ts | 20 +- .../helpCenter/types/HelpCenterList.ts | 10 +- src/api/resources/helpCenter/types/index.ts | 6 +- .../resources/helpCenters/client/Client.ts | 235 +- src/api/resources/helpCenters/client/index.ts | 2 +- .../client/requests/FindHelpCenterRequest.ts | 12 +- .../client/requests/ListHelpCentersRequest.ts | 12 +- .../helpCenters/client/requests/index.ts | 4 +- src/api/resources/helpCenters/index.ts | 4 +- .../resources/collections/client/Client.ts | 402 +- .../resources/collections/client/index.ts | 2 +- .../requests/CreateCollectionRequest.ts | 6 +- .../requests/DeleteCollectionRequest.ts | 12 +- .../client/requests/FindCollectionRequest.ts | 12 +- .../client/requests/ListCollectionsRequest.ts | 12 +- .../requests/UpdateCollectionRequest.ts | 16 +- .../collections/client/requests/index.ts | 10 +- .../resources/collections/index.ts | 2 +- .../resources/helpCenters/resources/index.ts | 4 +- src/api/resources/index.ts | 143 +- .../internalArticles/client/Client.ts | 503 + .../internalArticles/client/index.ts | 1 + .../requests/DeleteInternalArticleRequest.ts | 12 + .../RetrieveInternalArticleRequest.ts | 12 + .../requests/SearchInternalArticlesRequest.ts | 12 + .../UpdateInternalArticleRequestBody.ts | 29 + .../internalArticles/client/requests/index.ts | 4 + src/api/resources/internalArticles/index.ts | 2 + .../types/InternalArticleListItem.ts | 25 + .../types/InternalArticleSearchResponse.ts | 26 + .../resources/internalArticles/types/index.ts | 2 + src/api/resources/jobs/client/Client.ts | 101 + src/api/resources/jobs/client/index.ts | 1 + .../jobs/client/requests/JobsStatusRequest.ts | 12 + .../resources/jobs/client/requests/index.ts | 1 + src/api/resources/jobs/index.ts | 2 + src/api/resources/jobs/types/Jobs.ts | 31 + src/api/resources/jobs/types/index.ts | 1 + src/api/resources/messages/client/Client.ts | 158 +- src/api/resources/messages/index.ts | 4 +- src/api/resources/messages/types/Message.ts | 14 +- src/api/resources/messages/types/index.ts | 2 +- src/api/resources/news/client/Client.ts | 61 +- src/api/resources/news/index.ts | 6 +- .../news/resources/feeds/client/Client.ts | 277 +- .../news/resources/feeds/client/index.ts | 2 +- .../client/requests/FindNewsFeedRequest.ts | 8 +- .../requests/ListNewsFeedItemsRequest.ts | 8 +- .../resources/feeds/client/requests/index.ts | 4 +- .../resources/news/resources/feeds/index.ts | 2 +- src/api/resources/news/resources/index.ts | 8 +- .../news/resources/items/client/Client.ts | 399 +- .../news/resources/items/client/index.ts | 2 +- .../client/requests/DeleteNewsItemRequest.ts | 12 +- .../client/requests/FindNewsItemRequest.ts | 12 +- .../client/requests/UpdateNewsItemRequest.ts | 20 +- .../resources/items/client/requests/index.ts | 6 +- .../resources/news/resources/items/index.ts | 2 +- src/api/resources/news/types/NewsItem.ts | 28 +- src/api/resources/news/types/Newsfeed.ts | 12 +- .../news/types/NewsfeedAssignment.ts | 8 +- src/api/resources/news/types/index.ts | 6 +- src/api/resources/notes/client/Client.ts | 277 +- src/api/resources/notes/client/index.ts | 2 +- .../requests/CreateContactNoteRequest.ts | 8 +- .../notes/client/requests/FindNoteRequest.ts | 12 +- .../requests/ListContactNotesRequest.ts | 16 +- .../resources/notes/client/requests/index.ts | 6 +- src/api/resources/notes/index.ts | 4 +- src/api/resources/notes/types/Note.ts | 18 +- src/api/resources/notes/types/index.ts | 2 +- .../phoneCallRedirects/client/Client.ts | 162 +- .../phoneCallRedirects/client/index.ts | 2 +- .../CreatePhoneCallRedirectRequest.ts | 48 - .../client/requests/index.ts | 1 - src/api/resources/phoneCallRedirects/index.ts | 2 +- src/api/resources/segments/client/Client.ts | 211 +- src/api/resources/segments/client/index.ts | 2 +- .../client/requests/FindSegmentRequest.ts | 8 +- .../client/requests/ListSegmentsRequest.ts | 12 +- .../segments/client/requests/index.ts | 4 +- src/api/resources/segments/index.ts | 4 +- src/api/resources/segments/types/Segment.ts | 20 +- src/api/resources/segments/types/index.ts | 2 +- .../subscriptionTypes/client/Client.ts | 150 +- src/api/resources/subscriptionTypes/index.ts | 4 +- .../types/SubscriptionType.ts | 34 +- .../subscriptionTypes/types/index.ts | 2 +- src/api/resources/tags/client/Client.ts | 653 +- src/api/resources/tags/client/index.ts | 2 +- .../tags/client/requests/DeleteTagRequest.ts | 8 +- .../tags/client/requests/FindTagRequest.ts | 8 +- .../tags/client/requests/TagContactRequest.ts | 8 +- .../client/requests/TagConversationRequest.ts | 8 +- .../tags/client/requests/TagTicketRequest.ts | 8 +- .../client/requests/UntagContactRequest.ts | 12 +- .../requests/UntagConversationRequest.ts | 12 +- .../client/requests/UntagTicketRequest.ts | 12 +- .../resources/tags/client/requests/index.ts | 16 +- src/api/resources/tags/index.ts | 4 +- src/api/resources/tags/types/Tag.ts | 10 +- src/api/resources/tags/types/TagBasic.ts | 13 + .../tags/types/TagsCreateRequestBody.ts | 6 +- src/api/resources/tags/types/index.ts | 5 +- src/api/resources/teams/client/Client.ts | 206 +- src/api/resources/teams/client/index.ts | 2 +- .../teams/client/requests/FindTeamRequest.ts | 8 +- .../resources/teams/client/requests/index.ts | 2 +- src/api/resources/teams/index.ts | 4 +- src/api/resources/teams/types/Team.ts | 18 +- src/api/resources/teams/types/index.ts | 2 +- .../resources/ticketStates/client/Client.ts | 92 + .../resources/ticketStates/client/index.ts | 1 + src/api/resources/ticketStates/index.ts | 1 + .../resources/ticketTypes/client/Client.ts | 351 +- src/api/resources/ticketTypes/client/index.ts | 2 +- .../client/requests/FindTicketTypeRequest.ts | 8 +- .../requests/UpdateTicketTypeRequest.ts | 14 +- .../ticketTypes/client/requests/index.ts | 5 +- src/api/resources/ticketTypes/index.ts | 4 +- .../resources/attributes/client/Client.ts | 234 +- .../resources/attributes/client/index.ts | 2 +- .../CreateTicketTypeAttributeRequest.ts | 14 +- .../UpdateTicketTypeAttributeRequest.ts | 12 +- .../attributes/client/requests/index.ts | 4 +- .../ticketTypes/resources/attributes/index.ts | 2 +- .../resources/ticketTypes/resources/index.ts | 4 +- src/api/resources/tickets/client/Client.ts | 590 +- src/api/resources/tickets/client/index.ts | 2 +- .../client/requests/CreateTicketRequest.ts | 17 + .../client/requests/DeleteTicketRequest.ts | 12 + .../requests/EnqueueCreateTicketRequest.ts | 17 + .../client/requests/FindTicketRequest.ts | 8 +- .../client/requests/ReplyToTicketRequest.ts | 18 +- .../client/requests/UpdateTicketRequest.ts | 68 +- .../tickets/client/requests/index.ts | 9 +- src/api/resources/tickets/index.ts | 4 +- .../tickets/types/DeleteTicketResponse.ts | 13 + src/api/resources/tickets/types/Ticket.ts | 43 +- .../resources/tickets/types/TicketContacts.ts | 10 +- src/api/resources/tickets/types/TicketPart.ts | 84 +- .../resources/tickets/types/TicketState.ts | 28 + .../tickets/types/TicketStateDetailed.ts | 44 + src/api/resources/tickets/types/TicketType.ts | 44 +- .../tickets/types/TicketsReplyRequestBody.ts | 6 +- src/api/resources/tickets/types/index.ts | 13 +- src/api/resources/unstable/client/Client.ts | 303 +- .../unstable/errors/BadRequestError.ts | 8 +- .../unstable/errors/ConflictError.ts | 17 + .../unstable/errors/ForbiddenError.ts | 10 +- .../unstable/errors/InternalServerError.ts | 10 +- .../unstable/errors/NotFoundError.ts | 8 +- .../unstable/errors/TooManyRequestsError.ts | 10 +- .../unstable/errors/UnauthorizedError.ts | 10 +- .../errors/UnprocessableEntityError.ts | 8 +- src/api/resources/unstable/errors/index.ts | 15 +- src/api/resources/unstable/index.ts | 8 +- .../resources/admins/client/Client.ts | 367 +- .../unstable/resources/admins/client/index.ts | 2 +- .../requests/ListActivityLogsRequest.ts | 12 +- .../client/requests/RetrieveAdminRequest.ts | 8 +- .../client/requests/SetAwayAdminRequest.ts | 8 +- .../resources/admins/client/requests/index.ts | 6 +- .../unstable/resources/admins/index.ts | 4 +- .../unstable/resources/admins/types/Admin.ts | 6 +- .../unstable/resources/admins/types/index.ts | 2 +- .../unstable/resources/aiAgent/index.ts | 2 +- .../resources/aiAgent/types/AiAgent.ts | 34 +- .../unstable/resources/aiAgent/types/index.ts | 2 +- .../resources/aiContent/client/Client.ts | 645 +- .../resources/aiContent/client/index.ts | 2 +- .../CreateContentImportSourceRequest.ts | 10 +- .../requests/CreateExternalPageRequest.ts | 4 +- .../DeleteContentImportSourceRequest.ts | 8 +- .../requests/DeleteExternalPageRequest.ts | 8 +- .../requests/GetContentImportSourceRequest.ts | 8 +- .../client/requests/GetExternalPageRequest.ts | 8 +- .../UpdateContentImportSourceRequest.ts | 20 +- .../requests/UpdateExternalPageRequest.ts | 8 +- .../aiContent/client/requests/index.ts | 16 +- .../unstable/resources/aiContent/index.ts | 4 +- .../aiContent/types/ContentImportSource.ts | 16 +- .../types/ContentImportSourcesList.ts | 6 +- .../resources/aiContent/types/ExternalPage.ts | 4 +- .../aiContent/types/ExternalPagesList.ts | 6 +- .../resources/aiContent/types/index.ts | 8 +- .../resources/aiContentSource/index.ts | 2 +- .../aiContentSource/types/ContentSource.ts | 10 +- .../resources/aiContentSource/types/index.ts | 2 +- .../resources/articles/client/Client.ts | 373 +- .../resources/articles/client/index.ts | 2 +- .../client/requests/DeleteArticleRequest.ts | 8 +- .../client/requests/RetrieveArticleRequest.ts | 8 +- .../client/requests/SearchArticlesRequest.ts | 24 +- .../articles/client/requests/index.ts | 6 +- .../unstable/resources/articles/index.ts | 4 +- .../resources/articles/types/Article.ts | 6 +- .../articles/types/ArticleListItem.ts | 12 +- .../articles/types/ArticleSearchHighlights.ts | 16 +- .../articles/types/ArticleSearchResponse.ts | 6 +- .../articles/types/InternalArticle.ts | 8 + .../resources/articles/types/index.ts | 9 +- .../awayStatusReasons/client/Client.ts | 150 +- .../resources/awayStatusReasons/index.ts | 2 +- .../resources/brands/client/Client.ts | 167 + .../unstable/resources/brands/client/index.ts | 1 + .../client/requests/RetrieveBrandRequest.ts | 12 + .../resources/brands/client/requests/index.ts | 1 + .../unstable/resources/brands/index.ts | 2 + .../unstable/resources/brands/types/Brand.ts | 23 + .../resources/brands/types/BrandList.ts | 12 + .../unstable/resources/brands/types/index.ts | 2 + .../unstable/resources/calls/client/Client.ts | 710 + .../unstable/resources/calls/client/index.ts | 1 + .../CollectFinVoiceCallByExternalIdRequest.ts | 12 + .../CollectFinVoiceCallByIdRequest.ts | 12 + ...CollectFinVoiceCallByPhoneNumberRequest.ts | 12 + .../calls/client/requests/ListCallsRequest.ts | 15 + .../ListCallsWithTranscriptsRequest.ts | 12 + .../requests/ShowCallRecordingRequest.ts | 12 + .../calls/client/requests/ShowCallRequest.ts | 12 + .../requests/ShowCallTranscriptRequest.ts | 12 + .../resources/calls/client/requests/index.ts | 8 + .../unstable/resources/calls/index.ts | 2 + .../unstable/resources/calls/types/Call.ts | 42 + .../types/ListCallsWithTranscriptsResponse.ts | 21 + .../unstable/resources/calls/types/index.ts | 2 + .../resources/companies/client/Client.ts | 720 +- .../resources/companies/client/index.ts | 2 +- .../AttachContactToACompanyRequest.ts | 8 +- .../client/requests/DeleteCompanyRequest.ts | 8 +- .../DetachContactFromACompanyRequest.ts | 12 +- .../requests/ListAllCompaniesRequest.ts | 18 +- .../requests/ListAttachedContactsRequest.ts | 8 +- ...ListAttachedSegmentsForCompaniesRequest.ts | 8 +- .../requests/RetrieveACompanyByIdRequest.ts | 8 +- .../client/requests/RetrieveCompanyRequest.ts | 32 +- .../requests/ScrollOverAllCompaniesRequest.ts | 12 +- .../client/requests/UpdateCompanyRequest.ts | 8 +- .../companies/client/requests/index.ts | 20 +- .../unstable/resources/companies/index.ts | 4 +- .../resources/companies/types/Company.ts | 17 +- .../resources/companies/types/index.ts | 2 +- .../resources/contacts/client/Client.ts | 915 +- .../resources/contacts/client/index.ts | 2 +- .../client/requests/ArchiveContactRequest.ts | 8 +- .../client/requests/BlockContactRequest.ts | 8 +- .../client/requests/DeleteContactRequest.ts | 8 +- .../ListCompaniesForAContactRequest.ts | 8 +- .../ListSegmentsForAContactRequest.ts | 8 +- .../ListSubscriptionsForAContactRequest.ts | 8 +- .../requests/ListTagsForAContactRequest.ts | 8 +- .../client/requests/MergeContactsRequest.ts | 4 +- .../ShowContactByExternalIdRequest.ts | 8 +- .../client/requests/ShowContactRequest.ts | 8 +- .../requests/UnarchiveContactRequest.ts | 8 +- .../client/requests/UpdateContactRequest.ts | 8 +- .../contacts/client/requests/index.ts | 24 +- .../unstable/resources/contacts/index.ts | 4 +- .../resources/contacts/types/Contact.ts | 6 +- .../contacts/types/CreateContactResponse.ts | 6 +- .../contacts/types/MergeContactResponse.ts | 6 +- .../types/ShowContactByExternalIdResponse.ts | 6 +- .../contacts/types/ShowContactResponse.ts | 6 +- .../contacts/types/UpdateContactResponse.ts | 6 +- .../resources/contacts/types/index.ts | 12 +- .../resources/conversations/client/Client.ts | 766 +- .../resources/conversations/client/index.ts | 2 +- .../AttachContactToConversationRequest.ts | 10 +- .../ConvertConversationToTicketRequest.ts | 10 +- .../requests/CreateConversationRequest.ts | 10 +- .../requests/DeleteConversationRequest.ts | 8 +- .../DetachContactFromConversationRequest.ts | 12 +- .../requests/ListConversationsRequest.ts | 17 +- .../requests/ManageConversationRequest.ts | 10 +- .../requests/ReplyConversationRequest.ts | 10 +- .../requests/RetrieveConversationRequest.ts | 17 +- .../requests/UpdateConversationRequest.ts | 16 +- .../conversations/client/requests/index.ts | 20 +- .../unstable/resources/conversations/index.ts | 4 +- .../conversations/types/Conversation.ts | 20 +- .../types/ManageConversationRequestBody.ts | 6 +- .../resources/conversations/types/index.ts | 4 +- .../customChannelEvents/client/Client.ts | 334 +- .../customChannelEvents/client/index.ts | 2 +- .../NotifyAttributeCollectedRequest.ts | 6 +- .../requests/NotifyNewMessageRequest.ts | 6 +- .../NotifyQuickReplySelectedRequest.ts | 6 +- .../client/requests/index.ts | 6 +- .../resources/customChannelEvents/index.ts | 2 +- .../customObjectInstances/client/Client.ts | 407 +- .../customObjectInstances/client/index.ts | 2 +- ...eateOrUpdateCustomObjectInstanceRequest.ts | 8 +- ...ustomObjectInstancesByExternalIdRequest.ts | 12 +- .../DeleteCustomObjectInstancesByIdRequest.ts | 8 +- ...ustomObjectInstancesByExternalIdRequest.ts | 8 +- .../GetCustomObjectInstancesByIdRequest.ts | 12 +- .../client/requests/index.ts | 10 +- .../resources/customObjectInstances/index.ts | 4 +- .../types/CustomObjectInstance.ts | 4 +- .../customObjectInstances/types/index.ts | 2 +- .../resources/dataAttributes/client/Client.ts | 332 +- .../resources/dataAttributes/client/index.ts | 2 +- .../requests/CreateDataAttributeRequest.ts | 86 - .../requests/LisDataAttributesRequest.ts | 19 +- .../requests/UpdateDataAttributeRequest.ts | 46 +- .../dataAttributes/client/requests/index.ts | 5 +- .../resources/dataAttributes/index.ts | 4 +- .../dataAttributes/types/DataAttribute.ts | 16 +- .../types/LisDataAttributesRequestModel.ts | 7 +- .../resources/dataAttributes/types/index.ts | 4 +- .../resources/dataEvents/client/Client.ts | 261 +- .../resources/dataEvents/client/index.ts | 2 +- .../CreateDataEventSummariesRequest.ts | 4 +- .../client/requests/LisDataEventsRequest.ts | 14 +- .../dataEvents/client/requests/index.ts | 4 +- .../unstable/resources/dataEvents/index.ts | 4 +- .../resources/dataEvents/types/DataEvent.ts | 4 +- .../types/LisDataEventsRequestFilter.ts | 4 +- .../resources/dataEvents/types/index.ts | 4 +- .../resources/dataExport/client/Client.ts | 331 +- .../resources/dataExport/client/index.ts | 2 +- .../requests/CancelDataExportRequest.ts | 8 +- .../requests/CreateDataExportsRequest.ts | 4 +- .../requests/DownloadDataExportRequest.ts | 8 +- .../client/requests/GetDataExportRequest.ts | 8 +- .../dataExport/client/requests/index.ts | 8 +- .../unstable/resources/dataExport/index.ts | 4 +- .../resources/dataExport/types/DataExport.ts | 10 +- .../resources/dataExport/types/index.ts | 2 +- .../resources/emails/client/Client.ts | 166 + .../unstable/resources/emails/client/index.ts | 1 + .../client/requests/RetrieveEmailRequest.ts | 12 + .../resources/emails/client/requests/index.ts | 1 + .../unstable/resources/emails/index.ts | 2 + .../resources/emails/types/EmailList.ts | 12 + .../resources/emails/types/EmailSetting.ts | 27 + .../unstable/resources/emails/types/index.ts | 2 + .../resources/export/client/Client.ts | 216 +- .../unstable/resources/export/client/index.ts | 2 +- .../PostExportReportingDataEnqueueRequest.ts | 6 +- .../resources/export/client/requests/index.ts | 2 +- .../unstable/resources/export/index.ts | 4 +- ...tExportReportingDataGetDatasetsResponse.ts | 4 +- .../PostExportReportingDataEnqueueResponse.ts | 4 +- .../unstable/resources/export/types/index.ts | 4 +- .../resources/helpCenter/client/Client.ts | 486 +- .../resources/helpCenter/client/index.ts | 2 +- .../requests/CreateCollectionRequest.ts | 6 +- .../requests/DeleteCollectionRequest.ts | 8 +- .../requests/RetrieveCollectionRequest.ts | 8 +- .../requests/RetrieveHelpCenterRequest.ts | 8 +- .../requests/UpdateCollectionRequest.ts | 10 +- .../helpCenter/client/requests/index.ts | 10 +- .../unstable/resources/helpCenter/index.ts | 4 +- .../resources/helpCenter/types/Collection.ts | 6 +- .../resources/helpCenter/types/HelpCenter.ts | 8 +- .../helpCenter/types/HelpCenterList.ts | 6 +- .../resources/helpCenter/types/index.ts | 6 +- src/api/resources/unstable/resources/index.ts | 171 +- .../internalArticles/client/Client.ts | 491 + .../internalArticles/client/index.ts | 1 + .../requests/DeleteInternalArticleRequest.ts | 12 + .../RetrieveInternalArticleRequest.ts | 12 + .../requests/SearchInternalArticlesRequest.ts | 12 + .../UpdateInternalArticleRequestBody.ts | 29 + .../internalArticles/client/requests/index.ts | 4 + .../resources/internalArticles/index.ts | 2 + .../types/InternalArticleListItem.ts | 25 + .../types/InternalArticleSearchResponse.ts | 26 + .../resources/internalArticles/types/index.ts | 2 + .../unstable/resources/jobs/client/Client.ts | 152 +- .../unstable/resources/jobs/client/index.ts | 2 +- .../jobs/client/requests/JobsStatusRequest.ts | 8 +- .../resources/jobs/client/requests/index.ts | 2 +- .../unstable/resources/jobs/index.ts | 4 +- .../unstable/resources/jobs/types/Jobs.ts | 10 +- .../unstable/resources/jobs/types/index.ts | 2 +- .../resources/macros/client/Client.ts | 230 + .../unstable/resources/macros/client/index.ts | 1 + .../macros/client/requests/GetMacroRequest.ts | 27 + .../client/requests/ListMacrosRequest.ts | 53 + .../resources/macros/client/requests/index.ts | 2 + .../unstable/resources/macros/index.ts | 2 + .../unstable/resources/macros/types/Macro.ts | 45 + .../resources/macros/types/MacroList.ts | 39 + .../unstable/resources/macros/types/index.ts | 2 + .../resources/messages/client/Client.ts | 247 +- .../resources/messages/client/index.ts | 2 +- .../GetWhatsAppMessageStatusRequest.ts | 20 +- .../messages/client/requests/index.ts | 2 +- .../unstable/resources/messages/index.ts | 4 +- .../resources/messages/types/Message.ts | 13 +- .../resources/messages/types/index.ts | 2 +- .../unstable/resources/news/client/Client.ts | 522 +- .../unstable/resources/news/client/index.ts | 2 +- .../client/requests/DeleteNewsItemRequest.ts | 8 +- .../requests/ListLiveNewsfeedItemsRequest.ts | 8 +- .../requests/RetrieveNewsItemRequest.ts | 8 +- .../requests/RetrieveNewsfeedRequest.ts | 8 +- .../client/requests/UpdateNewsItemRequest.ts | 10 +- .../resources/news/client/requests/index.ts | 10 +- .../unstable/resources/news/index.ts | 4 +- .../unstable/resources/news/types/NewsItem.ts | 14 +- .../unstable/resources/news/types/Newsfeed.ts | 6 +- .../news/types/NewsfeedAssignment.ts | 4 +- .../unstable/resources/news/types/index.ts | 6 +- .../unstable/resources/notes/client/Client.ts | 326 +- .../unstable/resources/notes/client/index.ts | 2 +- .../client/requests/CreateNoteRequest.ts | 8 +- .../requests/ListCompanyNotesRequest.ts | 12 + .../notes/client/requests/ListNotesRequest.ts | 8 +- .../client/requests/RetrieveNoteRequest.ts | 8 +- .../resources/notes/client/requests/index.ts | 7 +- .../unstable/resources/notes/index.ts | 4 +- .../resources/notes/types/CompanyNote.ts | 33 + .../unstable/resources/notes/types/Note.ts | 6 +- .../unstable/resources/notes/types/index.ts | 3 +- .../resources/segments/client/Client.ts | 211 +- .../resources/segments/client/index.ts | 2 +- .../client/requests/ListSegmentsRequest.ts | 12 +- .../client/requests/RetrieveSegmentRequest.ts | 8 +- .../segments/client/requests/index.ts | 4 +- .../unstable/resources/segments/index.ts | 4 +- .../resources/segments/types/Segment.ts | 10 +- .../resources/segments/types/index.ts | 2 +- .../subscriptionTypes/client/Client.ts | 270 +- .../subscriptionTypes/client/index.ts | 2 +- .../AttachSubscriptionTypeToContactRequest.ts | 8 +- .../DetachSubscriptionTypeToContactRequest.ts | 12 +- .../client/requests/index.ts | 4 +- .../resources/subscriptionTypes/index.ts | 4 +- .../types/SubscriptionType.ts | 20 +- .../subscriptionTypes/types/index.ts | 2 +- .../resources/switch/client/Client.ts | 148 +- .../unstable/resources/switch/index.ts | 2 +- .../unstable/resources/tags/client/Client.ts | 653 +- .../unstable/resources/tags/client/index.ts | 2 +- .../requests/AttachTagToContactRequest.ts | 8 +- .../AttachTagToConversationRequest.ts | 8 +- .../requests/AttachTagToTicketRequest.ts | 8 +- .../tags/client/requests/DeleteTagRequest.ts | 8 +- .../requests/DetachTagFromContactRequest.ts | 12 +- .../DetachTagFromConversationRequest.ts | 12 +- .../requests/DetachTagFromTicketRequest.ts | 12 +- .../tags/client/requests/FindTagRequest.ts | 8 +- .../resources/tags/client/requests/index.ts | 16 +- .../unstable/resources/tags/index.ts | 4 +- .../tags/types/CreateTagRequestBody.ts | 6 +- .../unstable/resources/tags/types/Tag.ts | 6 +- .../unstable/resources/tags/types/TagBasic.ts | 4 +- .../unstable/resources/tags/types/index.ts | 6 +- .../unstable/resources/teams/client/Client.ts | 206 +- .../unstable/resources/teams/client/index.ts | 2 +- .../client/requests/RetrieveTeamRequest.ts | 8 +- .../resources/teams/client/requests/index.ts | 2 +- .../unstable/resources/teams/index.ts | 4 +- .../unstable/resources/teams/types/Team.ts | 6 +- .../unstable/resources/teams/types/index.ts | 2 +- .../resources/ticketStates/client/Client.ts | 150 +- .../unstable/resources/ticketStates/index.ts | 2 +- .../ticketTypeAttributes/client/Client.ts | 216 +- .../ticketTypeAttributes/client/index.ts | 2 +- .../CreateTicketTypeAttributeRequest.ts | 14 +- .../UpdateTicketTypeAttributeRequest.ts | 12 +- .../client/requests/index.ts | 4 +- .../resources/ticketTypeAttributes/index.ts | 2 +- .../resources/ticketTypes/client/Client.ts | 254 +- .../resources/ticketTypes/client/index.ts | 2 +- .../client/requests/GetTicketTypeRequest.ts | 8 +- .../ticketTypes/client/requests/index.ts | 2 +- .../unstable/resources/ticketTypes/index.ts | 2 +- .../resources/tickets/client/Client.ts | 421 +- .../resources/tickets/client/index.ts | 2 +- .../client/requests/DeleteTicketRequest.ts | 8 +- .../requests/EnqueueCreateTicketRequest.ts | 6 +- .../client/requests/GetTicketRequest.ts | 8 +- .../client/requests/ReplyTicketRequest.ts | 6 +- .../client/requests/UpdateTicketRequest.ts | 8 +- .../tickets/client/requests/index.ts | 10 +- .../unstable/resources/tickets/index.ts | 4 +- .../tickets/types/DeleteTicketResponse.ts | 4 +- .../tickets/types/ReplyTicketRequestBody.ts | 6 +- .../resources/tickets/types/Ticket.ts | 12 +- .../resources/tickets/types/TicketContacts.ts | 6 +- .../resources/tickets/types/TicketPart.ts | 18 +- .../resources/tickets/types/TicketState.ts | 10 +- .../tickets/types/TicketStateDetailed.ts | 12 +- .../resources/tickets/types/TicketType.ts | 12 +- .../unstable/resources/tickets/types/index.ts | 16 +- .../resources/visitors/client/Client.ts | 253 +- .../resources/visitors/client/index.ts | 2 +- .../client/requests/ConvertVisitorRequest.ts | 4 +- .../RetrieveVisitorWithUserIdRequest.ts | 8 +- .../visitors/client/requests/index.ts | 4 +- .../unstable/resources/visitors/index.ts | 2 +- .../resources/unstable/types/ActivityLog.ts | 78 +- .../unstable/types/ActivityLogList.ts | 6 +- .../unstable/types/ActivityLogMetadata.ts | 8 +- .../unstable/types/AddressableList.ts | 4 +- src/api/resources/unstable/types/AdminList.ts | 6 +- .../unstable/types/AdminPriorityLevel.ts | 4 +- .../types/AdminReplyConversationRequest.ts | 8 +- .../unstable/types/AdminReplyTicketRequest.ts | 6 +- .../resources/unstable/types/AdminWithApp.ts | 6 +- .../unstable/types/AiCallResponse.ts | 27 + src/api/resources/unstable/types/App.ts | 4 +- .../unstable/types/ArticleContent.ts | 12 +- .../resources/unstable/types/ArticleList.ts | 6 +- .../unstable/types/ArticleStatistics.ts | 4 +- .../types/ArticleTranslatedContent.ts | 8 +- .../types/AssignConversationRequest.ts | 6 +- .../unstable/types/AwayStatusReason.ts | 4 +- src/api/resources/unstable/types/CallList.ts | 16 + .../types/CloseConversationRequest.ts | 4 +- .../unstable/types/CollectionList.ts | 6 +- .../unstable/types/CompanyAttachedContacts.ts | 6 +- .../unstable/types/CompanyAttachedSegments.ts | 6 +- .../resources/unstable/types/CompanyData.ts | 4 +- .../resources/unstable/types/CompanyList.ts | 6 +- .../resources/unstable/types/CompanyScroll.ts | 6 +- .../unstable/types/ContactArchived.ts | 6 +- .../types/ContactAttachedCompanies.ts | 6 +- .../unstable/types/ContactBlocked.ts | 6 +- .../unstable/types/ContactCompanies.ts | 6 +- .../unstable/types/ContactDeleted.ts | 6 +- .../resources/unstable/types/ContactList.ts | 6 +- .../unstable/types/ContactLocation.ts | 4 +- .../resources/unstable/types/ContactNotes.ts | 6 +- .../unstable/types/ContactReference.ts | 4 +- .../unstable/types/ContactReplyBaseRequest.ts | 4 +- .../types/ContactReplyConversationRequest.ts | 6 +- .../types/ContactReplyEmailRequest.ts | 6 +- .../ContactReplyIntercomUserIdRequest.ts | 6 +- .../types/ContactReplyTicketEmailRequest.ts | 6 +- ...ContactReplyTicketIntercomUserIdRequest.ts | 6 +- .../types/ContactReplyTicketRequest.ts | 6 +- .../types/ContactReplyTicketUserIdRequest.ts | 6 +- .../types/ContactReplyUserIdRequest.ts | 6 +- .../unstable/types/ContactSegments.ts | 6 +- .../unstable/types/ContactSocialProfiles.ts | 6 +- .../types/ContactSubscriptionTypes.ts | 6 +- .../resources/unstable/types/ContactTags.ts | 6 +- .../unstable/types/ContactUnarchived.ts | 6 +- .../unstable/types/ContentSourcesList.ts | 6 +- .../types/ConversationAttachmentFiles.ts | 4 +- .../ConversationAttributeUpdatedByAdmin.ts | 4 +- .../ConversationAttributeUpdatedByWorkflow.ts | 4 +- .../unstable/types/ConversationContacts.ts | 6 +- .../unstable/types/ConversationDeleted.ts | 4 +- .../types/ConversationFirstContactReply.ts | 4 +- .../unstable/types/ConversationList.ts | 6 +- .../unstable/types/ConversationPart.ts | 12 +- .../unstable/types/ConversationPartAuthor.ts | 4 +- .../types/ConversationPartMetadata.ts | 6 +- .../unstable/types/ConversationParts.ts | 6 +- .../unstable/types/ConversationRating.ts | 8 +- .../types/ConversationResponseTime.ts | 4 +- .../unstable/types/ConversationSource.ts | 22 +- .../unstable/types/ConversationStatistics.ts | 8 +- .../unstable/types/ConversationTeammates.ts | 6 +- ...RequestBody.ts => CreateArticleRequest.ts} | 26 +- .../types/CreateDataAttributeRequest.ts | 15 + .../types/CreateInternalArticleRequest.ts | 15 + .../unstable/types/CreateMessageRequest.ts | 6 + .../types/CreateOrUpdateCompanyRequest.ts | 25 + .../types/CreateOrUpdateTagRequest.ts | 4 +- .../types/CreatePhoneSwitchRequest.ts | 12 + .../CreateTicketReplyWithCommentRequest.ts | 6 +- .../unstable/types/CreateTicketRequestBody.ts | 4 +- .../types}/CreateTicketTypeRequest.ts | 19 +- .../resources/unstable/types/CursorPages.ts | 6 +- .../unstable/types/CustomActionFinished.ts | 10 +- .../unstable/types/CustomActionStarted.ts | 4 +- .../unstable/types/CustomAttributes.ts | 6 +- .../unstable/types/CustomChannelAttribute.ts | 4 +- .../unstable/types/CustomChannelBaseEvent.ts | 6 +- .../unstable/types/CustomChannelContact.ts | 18 +- .../CustomChannelNotificationResponse.ts | 4 +- .../types/CustomObjectInstanceDeleted.ts | 4 +- .../types/CustomObjectInstanceList.ts | 6 +- .../unstable/types/CustomerRequest.ts | 4 +- .../unstable/types/DataAttributeList.ts | 6 +- .../resources/unstable/types/DataEventList.ts | 6 +- .../unstable/types/DataEventSummary.ts | 6 +- .../unstable/types/DataEventSummaryItem.ts | 4 +- .../resources/unstable/types/DataExportCsv.ts | 4 +- src/api/resources/unstable/types/Datetime.ts | 4 +- .../unstable/types/DeletedArticleObject.ts | 4 +- .../unstable/types/DeletedCollectionObject.ts | 4 +- .../unstable/types/DeletedCompanyObject.ts | 4 +- .../types/DeletedInternalArticleObject.ts | 13 + .../resources/unstable/types/DeletedObject.ts | 4 +- .../unstable/types/EmailAddressHeader.ts | 4 +- .../unstable/types/EmailMessageMetadata.ts | 8 +- src/api/resources/unstable/types/Error_.ts | 4 +- .../resources/unstable/types/EventDetails.ts | 6 +- .../resources/unstable/types/FileAttribute.ts | 4 +- .../resources/unstable/types/GroupContent.ts | 6 +- .../unstable/types/GroupTranslatedContent.ts | 8 +- .../unstable/types/IntercomVersion.ts | 46 - .../unstable/types/IntercomVersionUnstable.ts | 8 - .../unstable/types/InternalArticleList.ts | 16 + .../resources/unstable/types/LinkedObject.ts | 19 +- .../unstable/types/LinkedObjectList.ts | 6 +- .../types/MultipleFilterSearchRequest.ts | 12 +- .../unstable/types/NewsItemRequest.ts | 12 +- .../unstable/types/NotFoundErrorBody.ts | 4 +- src/api/resources/unstable/types/NoteList.ts | 8 +- .../unstable/types/OpenConversationRequest.ts | 4 +- .../unstable/types/OperatorWorkflowEvent.ts | 4 +- src/api/resources/unstable/types/PagesLink.ts | 4 +- .../unstable/types/PaginatedResponse.ts | 12 +- .../types/PaginatedResponseDataItem.ts | 6 +- .../unstable/types/PartAttachment.ts | 4 +- .../resources/unstable/types/PhoneSwitch.ts | 4 +- .../unstable/types/QuickReplyOption.ts | 4 +- src/api/resources/unstable/types/Recipient.ts | 10 +- .../types/RedactConversationRequest.ts | 6 +- src/api/resources/unstable/types/Reference.ts | 4 +- .../types/RegisterFinVoiceCallRequest.ts | 25 + .../types/ReplyConversationRequestBody.ts | 6 +- .../resources/unstable/types/SearchRequest.ts | 6 +- .../resources/unstable/types/SegmentList.ts | 6 +- .../types/SingleFilterSearchRequest.ts | 10 +- .../resources/unstable/types/SlaApplied.ts | 6 +- .../types/SnoozeConversationRequest.ts | 4 +- .../resources/unstable/types/SocialProfile.ts | 4 +- .../unstable/types/StartingAfterPaging.ts | 4 +- .../unstable/types/SubscriptionTypeList.ts | 6 +- .../unstable/types/TagCompanyRequest.ts | 4 +- src/api/resources/unstable/types/TagList.ts | 6 +- .../unstable/types/TagMultipleUsersRequest.ts | 4 +- src/api/resources/unstable/types/Tags.ts | 6 +- src/api/resources/unstable/types/TeamList.ts | 6 +- .../unstable/types/TeamPriorityLevel.ts | 4 +- .../unstable/types/TicketCustomAttributes.ts | 6 +- .../resources/unstable/types/TicketList.ts | 6 +- .../unstable/types/TicketPartAuthor.ts | 10 +- .../resources/unstable/types/TicketParts.ts | 6 +- .../resources/unstable/types/TicketReply.ts | 12 +- .../types/TicketRequestCustomAttributes.ts | 4 +- .../unstable/types/TicketStateList.ts | 6 +- .../unstable/types/TicketTypeAttribute.ts | 4 +- .../unstable/types/TicketTypeAttributeList.ts | 6 +- .../unstable/types/TicketTypeList.ts | 6 +- .../resources/unstable/types/Translation.ts | 4 +- .../unstable/types/UntagCompanyRequest.ts | 4 +- .../types/UpdateDataAttributeRequestBody.ts | 12 + .../types/UpdateTicketTypeRequestBody.ts | 34 - src/api/resources/unstable/types/Visitor.ts | 6 +- .../unstable/types/VisitorDeletedObject.ts | 4 +- .../types/WhatsappMessageStatusList.ts | 10 +- src/api/resources/unstable/types/index.ts | 299 +- src/api/resources/visitors/client/Client.ts | 267 +- src/api/resources/visitors/client/index.ts | 2 +- .../client/requests/FindVisitorRequest.ts | 8 +- .../requests/MergeVisitorToContactRequest.ts | 4 +- .../visitors/client/requests/index.ts | 4 +- src/api/resources/visitors/index.ts | 2 +- src/api/types/ActionComponent.ts | 24 - src/api/types/ActivityLog.ts | 111 +- src/api/types/ActivityLogList.ts | 10 +- src/api/types/ActivityLogMetadata.ts | 34 +- src/api/types/AddressableList.ts | 10 +- src/api/types/AdminList.ts | 10 +- src/api/types/AdminPriorityLevel.ts | 4 +- .../types/AdminReplyConversationRequest.ts | 11 +- src/api/types/AdminReplyTicketRequest.ts | 6 +- src/api/types/AdminWithApp.ts | 26 +- src/api/types/App.ts | 18 +- src/api/types/ArticleContent.ts | 22 +- src/api/types/ArticleList.ts | 12 +- src/api/types/ArticleStatistics.ts | 6 +- src/api/types/ArticleTranslatedContent.ts | 6 +- src/api/types/AssignConversationRequest.ts | 6 +- src/api/types/AwayStatusReason.ts | 19 + src/api/types/ButtonComponent.ts | 36 - src/api/types/CallList.ts | 16 + src/api/types/CanvasObject.ts | 22 - src/api/types/CheckboxComponent.ts | 39 - src/api/types/CheckboxOption.ts | 17 - src/api/types/CloseConversationRequest.ts | 4 +- src/api/types/CollectionList.ts | 12 +- src/api/types/CompanyAttachedContacts.ts | 12 +- src/api/types/CompanyAttachedSegments.ts | 10 +- src/api/types/CompanyData.ts | 13 + src/api/types/CompanyList.ts | 12 +- src/api/types/CompanyScroll.ts | 10 +- src/api/types/Component.ts | 69 - src/api/types/ConfigureRequest.ts | 26 - src/api/types/ConfigureResponse.ts | 16 - src/api/types/ContactArchived.ts | 16 +- src/api/types/ContactAttachedCompanies.ts | 12 +- src/api/types/ContactBlocked.ts | 11 + src/api/types/ContactCompanies.ts | 22 +- src/api/types/ContactCompany.ts | 15 - src/api/types/ContactDeleted.ts | 16 +- src/api/types/ContactList.ts | 12 +- src/api/types/ContactLocation.ts | 6 +- src/api/types/ContactNotes.ts | 14 +- src/api/types/ContactReference.ts | 8 +- src/api/types/ContactReplyBaseRequest.ts | 19 +- .../types/ContactReplyConversationRequest.ts | 6 +- src/api/types/ContactReplyEmailRequest.ts | 6 +- .../ContactReplyIntercomUserIdRequest.ts | 6 +- .../types/ContactReplyTicketEmailRequest.ts | 6 +- ...ContactReplyTicketIntercomUserIdRequest.ts | 6 +- src/api/types/ContactReplyTicketRequest.ts | 6 +- .../types/ContactReplyTicketUserIdRequest.ts | 6 +- src/api/types/ContactReplyUserIdRequest.ts | 6 +- src/api/types/ContactSegments.ts | 10 +- src/api/types/ContactSocialProfiles.ts | 8 +- src/api/types/ContactSubscriptionTypes.ts | 14 +- src/api/types/ContactTags.ts | 14 +- src/api/types/ContactUnarchived.ts | 16 +- src/api/types/ContentObject.ts | 15 - src/api/types/ContentSourcesList.ts | 12 +- src/api/types/Context.ts | 36 - src/api/types/ConversationAttachmentFiles.ts | 10 +- .../ConversationAttributeUpdatedByAdmin.ts | 21 + .../ConversationAttributeUpdatedByWorkflow.ts | 27 + src/api/types/ConversationContacts.ts | 11 +- src/api/types/ConversationDeleted.ts | 13 + .../types/ConversationFirstContactReply.ts | 8 +- ...rsationResponse.ts => ConversationList.ts} | 14 +- src/api/types/ConversationPart.ts | 39 +- src/api/types/ConversationPartAuthor.ts | 16 +- src/api/types/ConversationPartMetadata.ts | 24 + src/api/types/ConversationParts.ts | 12 +- src/api/types/ConversationRating.ts | 18 +- src/api/types/ConversationResponseTime.ts | 13 + src/api/types/ConversationSource.ts | 36 +- src/api/types/ConversationStatistics.ts | 16 +- src/api/types/ConversationTeammates.ts | 6 +- .../CreateArticleRequest.ts | 48 +- src/api/types/CreateContactRequest.ts | 4 +- src/api/types/CreateContactRequestTwo.ts | 4 +- src/api/types/CreateDataAttributeRequest.ts | 15 + src/api/types/CreateDataEventRequest.ts | 4 +- src/api/types/CreateDataEventRequestTwo.ts | 4 +- src/api/types/CreateInternalArticleRequest.ts | 15 + src/api/types/CreateMessageRequest.ts | 18 +- src/api/types/CreateMessageRequestTwo.ts | 5 - .../CreateOrUpdateCompanyRequest.ts | 14 +- src/api/types/CreateOrUpdateTagRequest.ts | 4 +- src/api/types/CreatePhoneSwitchRequest.ts | 12 + .../CreateTicketReplyWithCommentRequest.ts | 6 +- src/api/types/CreateTicketRequest.ts | 37 - src/api/types/CreateTicketRequestBody.ts | 48 + src/api/types/CreateTicketTypeRequest.ts | 28 + src/api/types/CurrentCanvas.ts | 13 - src/api/types/CursorPages.ts | 8 +- src/api/types/CustomActionFinished.ts | 26 + src/api/types/CustomActionStarted.ts | 15 + src/api/types/CustomAttributes.ts | 12 +- src/api/types/CustomChannelAttribute.ts | 8 + src/api/types/CustomChannelBaseEvent.ts | 11 + src/api/types/CustomChannelContact.ts | 21 + .../CustomChannelNotificationResponse.ts | 12 + src/api/types/CustomObjectInstanceDeleted.ts | 13 + src/api/types/CustomObjectInstanceList.ts | 12 + src/api/types/CustomerRequest.ts | 4 +- src/api/types/DataAttributeList.ts | 10 +- src/api/types/DataEventList.ts | 10 +- src/api/types/DataEventSummary.ts | 16 +- src/api/types/DataEventSummaryItem.ts | 12 +- src/api/types/DataExportCsv.ts | 20 +- src/api/types/DataTableComponent.ts | 13 - src/api/types/DataTableItem.ts | 15 - src/api/types/Datetime.ts | 9 + src/api/types/DeletedArticleObject.ts | 10 +- src/api/types/DeletedCollectionObject.ts | 10 +- src/api/types/DeletedCompanyObject.ts | 10 +- src/api/types/DeletedInternalArticleObject.ts | 13 + src/api/types/DeletedObject.ts | 10 +- src/api/types/DividerComponent.ts | 13 - src/api/types/DropdownComponent.ts | 37 - src/api/types/DropdownOption.ts | 17 - src/api/types/EmailAddressHeader.ts | 13 + src/api/types/EmailMessageMetadata.ts | 13 + src/api/types/Error_.ts | 4 +- src/api/types/Event.ts | 11 - src/api/types/EventDetails.ts | 10 + src/api/types/FileAttribute.ts | 18 +- src/api/types/GroupContent.ts | 10 +- src/api/types/GroupTranslatedContent.ts | 8 +- src/api/types/ImageComponent.ts | 43 - src/api/types/InitializeRequest.ts | 25 - src/api/types/InitializeResponse.ts | 13 - src/api/types/InputComponent.ts | 40 - src/api/types/InternalArticleList.ts | 16 + src/api/types/LinkedObject.ts | 23 +- src/api/types/LinkedObjectList.ts | 14 +- src/api/types/ListComponent.ts | 27 - src/api/types/ListItem.ts | 27 - src/api/types/ListItemWithImage.ts | 14 - src/api/types/ListItemWithoutImage.ts | 14 - src/api/types/LiveCanvasRequest.ts | 23 - src/api/types/LiveCanvasResponse.ts | 13 - src/api/types/Metadata.ts | 6 +- src/api/types/MultipleFilterSearchRequest.ts | 21 +- .../MultipleOrSingleFilterSearchRequest.ts | 9 - src/api/types/NewsItemRequest.ts | 12 +- src/api/types/NotFoundErrorBody.ts | 23 + src/api/types/NoteList.ts | 13 +- src/api/types/OffsetPages.ts | 4 +- src/api/types/OpenConversationRequest.ts | 4 +- src/api/types/OperatorWorkflowEvent.ts | 23 + src/api/types/PagesLink.ts | 12 +- src/api/types/PaginatedNewsItemResponse.ts | 18 - src/api/types/PaginatedNewsfeedResponse.ts | 18 - src/api/types/PaginatedResponse.ts | 25 + src/api/types/PaginatedResponseDataItem.ts | 17 + src/api/types/PartAttachment.ts | 18 +- src/api/types/PhoneSwitch.ts | 8 +- src/api/types/QuickReplyOption.ts | 8 + src/api/types/Recipient.ts | 20 + src/api/types/RedactConversationRequest.ts | 6 +- src/api/types/Reference.ts | 6 +- src/api/types/ReplyConversationRequest.ts | 6 +- src/api/types/ResultsResponse.ts | 11 - src/api/types/SearchRequest.ts | 6 +- src/api/types/SegmentList.ts | 10 +- src/api/types/SheetActionComponent.ts | 13 - src/api/types/SingleFilterSearchRequest.ts | 12 +- src/api/types/SingleSelectComponent.ts | 42 - src/api/types/SingleSelectOption.ts | 17 - src/api/types/SlaApplied.ts | 12 +- src/api/types/SnoozeConversationRequest.ts | 4 +- src/api/types/SocialProfile.ts | 10 +- src/api/types/SpacerComponent.ts | 27 - src/api/types/StartingAfterPaging.ts | 6 +- src/api/types/SubmitActionComponent.ts | 8 - src/api/types/SubmitRequest.ts | 31 - src/api/types/SubmitResponse.ts | 25 - src/api/types/SubscriptionTypeList.ts | 10 +- src/api/types/TagCompanyRequest.ts | 4 +- src/api/types/TagList.ts | 10 +- src/api/types/TagMultipleUsersRequest.ts | 4 +- src/api/types/Tags.ts | 10 +- src/api/types/TeamList.ts | 10 +- src/api/types/TeamPriorityLevel.ts | 4 +- src/api/types/TextAreaComponent.ts | 23 - src/api/types/TextComponent.ts | 41 - src/api/types/TicketCustomAttributes.ts | 4 +- src/api/types/TicketList.ts | 12 +- src/api/types/TicketPartAuthor.ts | 16 +- src/api/types/TicketParts.ts | 12 +- src/api/types/TicketReply.ts | 20 +- .../types/TicketRequestCustomAttributes.ts | 4 +- src/api/types/TicketStateList.ts | 13 + src/api/types/TicketTypeAttribute.ts | 42 +- src/api/types/TicketTypeAttributeList.ts | 10 +- src/api/types/TicketTypeList.ts | 12 +- src/api/types/Translation.ts | 10 +- src/api/types/UntagCompanyRequest.ts | 10 +- src/api/types/UpdateArticleRequestBody.ts | 13 + src/api/types/UpdateCompanyRequestBody.ts | 21 + .../types/UpdateDataAttributeRequestBody.ts | 12 + src/api/types/UpdateVisitorRequest.ts | 4 +- src/api/types/UpdateVisitorRequestOne.ts | 4 +- src/api/types/UrlActionComponent.ts | 11 - src/api/types/Visitor.ts | 22 +- src/api/types/VisitorDeletedObject.ts | 10 +- src/api/types/WhatsappMessageStatusList.ts | 67 + src/api/types/index.ts | 327 +- src/api/version.ts | 7 +- src/auth/BearerAuthProvider.ts | 36 + src/auth/index.ts | 1 + src/core/auth/AuthProvider.ts | 6 + src/core/auth/AuthRequest.ts | 9 + src/core/auth/BasicAuth.ts | 9 +- src/core/auth/BearerToken.ts | 19 +- src/core/auth/NoOpAuthProvider.ts | 8 + src/core/auth/index.ts | 7 +- src/core/base64.ts | 27 + src/core/exports.ts | 2 + src/core/fetcher/APIResponse.ts | 2 +- src/core/fetcher/BinaryResponse.ts | 34 + src/core/fetcher/EndpointMetadata.ts | 13 + src/core/fetcher/EndpointSupplier.ts | 14 + src/core/fetcher/Fetcher.ts | 296 +- src/core/fetcher/HttpResponsePromise.ts | 2 +- src/core/fetcher/RawResponse.ts | 2 +- src/core/fetcher/createRequestUrl.ts | 12 +- src/core/fetcher/getErrorResponseBody.ts | 33 + src/core/fetcher/getFetchFn.ts | 26 +- src/core/fetcher/getRequestBody.ts | 8 +- src/core/fetcher/getResponseBody.ts | 68 +- src/core/fetcher/index.ts | 19 +- src/core/fetcher/makeRequest.ts | 10 +- src/core/fetcher/requestWithRetries.ts | 49 +- src/core/fetcher/signals.ts | 14 +- .../Node18UniversalStreamWrapper.ts | 257 - .../stream-wrappers/NodePre18StreamWrapper.ts | 107 - .../stream-wrappers/UndiciStreamWrapper.ts | 243 - .../stream-wrappers/chooseStreamWrapper.ts | 34 - src/core/headers.ts | 35 + src/core/index.ts | 13 +- src/core/logging/exports.ts | 19 + src/core/logging/index.ts | 1 + src/core/logging/logger.ts | 203 + src/core/pagination/Page.ts | 21 +- src/core/pagination/Pageable.ts | 18 - src/core/pagination/exports.ts | 1 + src/core/pagination/index.ts | 3 +- src/core/runtime/index.ts | 2 +- src/core/runtime/runtime.ts | 27 +- src/core/url/encodePathParam.ts | 18 + src/core/url/index.ts | 3 + src/core/url/join.ts | 79 + src/core/url/qs.ts | 74 + src/core/utils/index.ts | 2 +- src/environments.ts | 4 +- src/errors/IntercomError.ts | 10 +- src/errors/IntercomTimeoutError.ts | 4 +- src/errors/handleNonStatusCodeError.ts | 37 + src/errors/index.ts | 4 +- src/exports.ts | 1 + src/index.ts | 10 +- src/version.ts | 2 +- tests/integration/conversations.test.ts | 5 +- tests/integration/dataAttributes.test.ts | 2 +- tests/integration/utils/createClient.ts | 12 +- tests/mock-server/MockServer.ts | 29 + tests/mock-server/MockServerPool.ts | 106 + tests/mock-server/mockEndpointBuilder.ts | 227 + tests/mock-server/randomBaseUrl.ts | 4 + tests/mock-server/setup.ts | 10 + tests/mock-server/withFormUrlEncoded.ts | 80 + tests/mock-server/withHeaders.ts | 70 + tests/mock-server/withJson.ts | 158 + tests/setup.ts | 80 + tests/tsconfig.json | 11 + tests/unit/auth/BasicAuth.test.ts | 92 +- tests/unit/base64.test.ts | 53 + tests/unit/fetcher/Fetcher.test.ts | 221 +- .../unit/fetcher/HttpResponsePromise.test.ts | 10 +- tests/unit/fetcher/RawResponse.test.ts | 2 +- tests/unit/fetcher/createRequestUrl.test.ts | 198 +- tests/unit/fetcher/getFetchFn.test.ts | 22 - tests/unit/fetcher/getRequestBody.test.ts | 168 +- tests/unit/fetcher/getResponseBody.test.ts | 109 +- tests/unit/fetcher/logging.test.ts | 517 + tests/unit/fetcher/makeRequest.test.ts | 5 +- tests/unit/fetcher/redacting.test.ts | 1115 ++ tests/unit/fetcher/requestWithRetries.test.ts | 138 +- tests/unit/fetcher/signals.test.ts | 8 +- .../Node18UniversalStreamWrapper.test.ts | 178 - .../NodePre18StreamWrapper.test.ts | 124 - .../UndiciStreamWrapper.test.ts | 153 - .../chooseStreamWrapper.test.ts | 43 - .../fetcher/stream-wrappers/webpack.test.ts | 42 - tests/unit/logging/logger.test.ts | 454 + tests/unit/url/join.test.ts | 284 + tests/unit/url/qs.test.ts | 278 + tests/unit/utils/setObjectProperty.test.ts | 76 + tests/wire/.gitkeep | 0 tests/wire/admins.test.ts | 686 + tests/wire/aiContent.test.ts | 878 ++ tests/wire/articles.test.ts | 6584 ++++++++ tests/wire/awayStatusReasons.test.ts | 74 + tests/wire/calls.test.ts | 410 + tests/wire/companies.test.ts | 1987 +++ tests/wire/contacts.test.ts | 2871 ++++ tests/wire/conversations.test.ts | 12610 ++++++++++++++++ tests/wire/customChannelEvents.test.ts | 790 + tests/wire/customObjectInstances.test.ts | 475 + tests/wire/dataAttributes.test.ts | 1515 ++ tests/wire/dataExport.test.ts | 273 + tests/wire/events.test.ts | 169 + tests/wire/export.test.ts | 201 + tests/wire/helpCenters.test.ts | 203 + tests/wire/helpCenters/collections.test.ts | 2216 +++ tests/wire/internalArticles.test.ts | 655 + tests/wire/jobs.test.ts | 97 + tests/wire/messages.test.ts | 618 + tests/wire/news/feeds.test.ts | 257 + tests/wire/news/items.test.ts | 620 + tests/wire/notes.test.ts | 527 + tests/wire/phoneCallRedirects.test.ts | 216 + tests/wire/segments.test.ts | 174 + tests/wire/subscriptionTypes.test.ts | 92 + tests/wire/tags.test.ts | 1371 ++ tests/wire/teams.test.ts | 144 + tests/wire/ticketStates.test.ts | 504 + tests/wire/ticketTypes.test.ts | 689 + tests/wire/ticketTypes/attributes.test.ts | 200 + tests/wire/tickets.test.ts | 3690 +++++ tests/wire/unstable/admins.test.ts | 644 + tests/wire/unstable/aiContent.test.ts | 878 ++ tests/wire/unstable/articles.test.ts | 2141 +++ tests/wire/unstable/awayStatusReasons.test.ts | 74 + tests/wire/unstable/brands.test.ts | 162 + tests/wire/unstable/calls.test.ts | 758 + tests/wire/unstable/companies.test.ts | 2011 +++ tests/wire/unstable/contacts.test.ts | 2297 +++ tests/wire/unstable/conversations.test.ts | 10888 +++++++++++++ .../wire/unstable/customChannelEvents.test.ts | 796 + .../unstable/customObjectInstances.test.ts | 475 + tests/wire/unstable/dataAttributes.test.ts | 992 ++ tests/wire/unstable/dataEvents.test.ts | 164 + tests/wire/unstable/dataExport.test.ts | 127 + tests/wire/unstable/emails.test.ts | 174 + tests/wire/unstable/export.test.ts | 201 + tests/wire/unstable/helpCenter.test.ts | 1933 +++ tests/wire/unstable/internalArticles.test.ts | 655 + tests/wire/unstable/jobs.test.ts | 79 + tests/wire/unstable/macros.test.ts | 699 + tests/wire/unstable/messages.test.ts | 766 + tests/wire/unstable/news.test.ts | 864 ++ tests/wire/unstable/notes.test.ts | 763 + tests/wire/unstable/segments.test.ts | 162 + tests/wire/unstable/subscriptionTypes.test.ts | 410 + tests/wire/unstable/switch.test.ts | 113 + tests/wire/unstable/tags.test.ts | 1371 ++ tests/wire/unstable/teams.test.ts | 136 + tests/wire/unstable/ticketStates.test.ts | 504 + .../unstable/ticketTypeAttributes.test.ts | 200 + tests/wire/unstable/ticketTypes.test.ts | 518 + tests/wire/unstable/tickets.test.ts | 3265 ++++ tests/wire/unstable/visitors.test.ts | 866 ++ tests/wire/visitors.test.ts | 847 ++ tsconfig.base.json | 18 + tsconfig.cjs.json | 9 + tsconfig.esm.json | 10 + tsconfig.json | 16 +- vitest.config.mts | 28 + yarn.lock | 3207 ---- 1236 files changed, 113166 insertions(+), 28336 deletions(-) create mode 100644 .fern/metadata.json delete mode 100644 .npmignore delete mode 100644 .prettierrc.yml create mode 100644 CONTRIBUTING.md create mode 100644 biome.json delete mode 100644 jest.config.mjs create mode 100644 pnpm-lock.yaml create mode 100644 pnpm-workspace.yaml create mode 100644 src/BaseClient.ts create mode 100644 src/api/errors/TooManyRequestsError.ts create mode 100644 src/api/resources/aiContent/client/Client.ts create mode 100644 src/api/resources/aiContent/client/index.ts create mode 100644 src/api/resources/aiContent/client/requests/CreateContentImportSourceRequest.ts create mode 100644 src/api/resources/aiContent/client/requests/CreateExternalPageRequest.ts create mode 100644 src/api/resources/aiContent/client/requests/DeleteContentImportSourceRequest.ts create mode 100644 src/api/resources/aiContent/client/requests/DeleteExternalPageRequest.ts create mode 100644 src/api/resources/aiContent/client/requests/GetContentImportSourceRequest.ts create mode 100644 src/api/resources/aiContent/client/requests/GetExternalPageRequest.ts create mode 100644 src/api/resources/aiContent/client/requests/UpdateContentImportSourceRequest.ts create mode 100644 src/api/resources/aiContent/client/requests/UpdateExternalPageRequest.ts create mode 100644 src/api/resources/aiContent/client/requests/index.ts create mode 100644 src/api/resources/aiContent/index.ts create mode 100644 src/api/resources/aiContent/types/ContentImportSource.ts create mode 100644 src/api/resources/aiContent/types/ContentImportSourcesList.ts create mode 100644 src/api/resources/aiContent/types/ExternalPage.ts create mode 100644 src/api/resources/aiContent/types/ExternalPagesList.ts create mode 100644 src/api/resources/aiContent/types/index.ts rename src/api/resources/articles/types/{SearchArticlesResponse.ts => ArticleSearchResponse.ts} (66%) create mode 100644 src/api/resources/articles/types/InternalArticle.ts create mode 100644 src/api/resources/awayStatusReasons/client/Client.ts create mode 100644 src/api/resources/awayStatusReasons/client/index.ts create mode 100644 src/api/resources/awayStatusReasons/index.ts create mode 100644 src/api/resources/calls/client/Client.ts create mode 100644 src/api/resources/calls/client/index.ts create mode 100644 src/api/resources/calls/client/requests/ListCallsRequest.ts create mode 100644 src/api/resources/calls/client/requests/ListCallsWithTranscriptsRequest.ts create mode 100644 src/api/resources/calls/client/requests/ShowCallRecordingRequest.ts create mode 100644 src/api/resources/calls/client/requests/ShowCallRequest.ts create mode 100644 src/api/resources/calls/client/requests/ShowCallTranscriptRequest.ts create mode 100644 src/api/resources/calls/client/requests/index.ts create mode 100644 src/api/resources/calls/index.ts create mode 100644 src/api/resources/calls/types/Call.ts create mode 100644 src/api/resources/calls/types/ListCallsWithTranscriptsResponse.ts create mode 100644 src/api/resources/calls/types/index.ts create mode 100644 src/api/resources/contacts/client/requests/BlockContactRequest.ts create mode 100644 src/api/resources/contacts/client/requests/ShowContactByExternalIdRequest.ts create mode 100644 src/api/resources/contacts/types/ContactsCreateResponse.ts create mode 100644 src/api/resources/contacts/types/ContactsFindResponse.ts create mode 100644 src/api/resources/contacts/types/ContactsMergeLeadInUserResponse.ts create mode 100644 src/api/resources/contacts/types/ContactsUpdateResponse.ts create mode 100644 src/api/resources/contacts/types/ShowContactByExternalIdResponse.ts create mode 100644 src/api/resources/conversations/client/requests/DeleteConversationRequest.ts create mode 100644 src/api/resources/customChannelEvents/client/Client.ts create mode 100644 src/api/resources/customChannelEvents/client/index.ts create mode 100644 src/api/resources/customChannelEvents/client/requests/NotifyAttributeCollectedRequest.ts create mode 100644 src/api/resources/customChannelEvents/client/requests/NotifyNewMessageRequest.ts create mode 100644 src/api/resources/customChannelEvents/client/requests/NotifyQuickReplySelectedRequest.ts create mode 100644 src/api/resources/customChannelEvents/client/requests/index.ts create mode 100644 src/api/resources/customChannelEvents/index.ts create mode 100644 src/api/resources/customObjectInstances/client/Client.ts create mode 100644 src/api/resources/customObjectInstances/client/index.ts create mode 100644 src/api/resources/customObjectInstances/client/requests/CreateOrUpdateCustomObjectInstanceRequest.ts create mode 100644 src/api/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByExternalIdRequest.ts create mode 100644 src/api/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByIdRequest.ts create mode 100644 src/api/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByExternalIdRequest.ts create mode 100644 src/api/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByIdRequest.ts create mode 100644 src/api/resources/customObjectInstances/client/requests/index.ts create mode 100644 src/api/resources/customObjectInstances/index.ts create mode 100644 src/api/resources/customObjectInstances/types/CustomObjectInstance.ts create mode 100644 src/api/resources/customObjectInstances/types/index.ts delete mode 100644 src/api/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts create mode 100644 src/api/resources/dataExport/client/requests/DownloadReportingDataExportRequest.ts create mode 100644 src/api/resources/dataExport/client/requests/ExportReportingDataRequest.ts create mode 100644 src/api/resources/dataExport/types/DataExportExportReportingDataResponse.ts create mode 100644 src/api/resources/export/client/Client.ts create mode 100644 src/api/resources/export/client/index.ts create mode 100644 src/api/resources/export/client/requests/PostExportReportingDataEnqueueRequest.ts create mode 100644 src/api/resources/export/client/requests/index.ts create mode 100644 src/api/resources/export/index.ts create mode 100644 src/api/resources/export/types/GetExportReportingDataGetDatasetsResponse.ts create mode 100644 src/api/resources/export/types/PostExportReportingDataEnqueueResponse.ts create mode 100644 src/api/resources/export/types/index.ts create mode 100644 src/api/resources/internalArticles/client/Client.ts create mode 100644 src/api/resources/internalArticles/client/index.ts create mode 100644 src/api/resources/internalArticles/client/requests/DeleteInternalArticleRequest.ts create mode 100644 src/api/resources/internalArticles/client/requests/RetrieveInternalArticleRequest.ts create mode 100644 src/api/resources/internalArticles/client/requests/SearchInternalArticlesRequest.ts create mode 100644 src/api/resources/internalArticles/client/requests/UpdateInternalArticleRequestBody.ts create mode 100644 src/api/resources/internalArticles/client/requests/index.ts create mode 100644 src/api/resources/internalArticles/index.ts create mode 100644 src/api/resources/internalArticles/types/InternalArticleListItem.ts create mode 100644 src/api/resources/internalArticles/types/InternalArticleSearchResponse.ts create mode 100644 src/api/resources/internalArticles/types/index.ts create mode 100644 src/api/resources/jobs/client/Client.ts create mode 100644 src/api/resources/jobs/client/index.ts create mode 100644 src/api/resources/jobs/client/requests/JobsStatusRequest.ts create mode 100644 src/api/resources/jobs/client/requests/index.ts create mode 100644 src/api/resources/jobs/index.ts create mode 100644 src/api/resources/jobs/types/Jobs.ts create mode 100644 src/api/resources/jobs/types/index.ts delete mode 100644 src/api/resources/phoneCallRedirects/client/requests/CreatePhoneCallRedirectRequest.ts delete mode 100644 src/api/resources/phoneCallRedirects/client/requests/index.ts create mode 100644 src/api/resources/tags/types/TagBasic.ts create mode 100644 src/api/resources/ticketStates/client/Client.ts create mode 100644 src/api/resources/ticketStates/client/index.ts create mode 100644 src/api/resources/ticketStates/index.ts create mode 100644 src/api/resources/tickets/client/requests/CreateTicketRequest.ts create mode 100644 src/api/resources/tickets/client/requests/DeleteTicketRequest.ts create mode 100644 src/api/resources/tickets/client/requests/EnqueueCreateTicketRequest.ts create mode 100644 src/api/resources/tickets/types/DeleteTicketResponse.ts create mode 100644 src/api/resources/tickets/types/TicketState.ts create mode 100644 src/api/resources/tickets/types/TicketStateDetailed.ts create mode 100644 src/api/resources/unstable/errors/ConflictError.ts create mode 100644 src/api/resources/unstable/resources/articles/types/InternalArticle.ts create mode 100644 src/api/resources/unstable/resources/brands/client/Client.ts create mode 100644 src/api/resources/unstable/resources/brands/client/index.ts create mode 100644 src/api/resources/unstable/resources/brands/client/requests/RetrieveBrandRequest.ts create mode 100644 src/api/resources/unstable/resources/brands/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/brands/index.ts create mode 100644 src/api/resources/unstable/resources/brands/types/Brand.ts create mode 100644 src/api/resources/unstable/resources/brands/types/BrandList.ts create mode 100644 src/api/resources/unstable/resources/brands/types/index.ts create mode 100644 src/api/resources/unstable/resources/calls/client/Client.ts create mode 100644 src/api/resources/unstable/resources/calls/client/index.ts create mode 100644 src/api/resources/unstable/resources/calls/client/requests/CollectFinVoiceCallByExternalIdRequest.ts create mode 100644 src/api/resources/unstable/resources/calls/client/requests/CollectFinVoiceCallByIdRequest.ts create mode 100644 src/api/resources/unstable/resources/calls/client/requests/CollectFinVoiceCallByPhoneNumberRequest.ts create mode 100644 src/api/resources/unstable/resources/calls/client/requests/ListCallsRequest.ts create mode 100644 src/api/resources/unstable/resources/calls/client/requests/ListCallsWithTranscriptsRequest.ts create mode 100644 src/api/resources/unstable/resources/calls/client/requests/ShowCallRecordingRequest.ts create mode 100644 src/api/resources/unstable/resources/calls/client/requests/ShowCallRequest.ts create mode 100644 src/api/resources/unstable/resources/calls/client/requests/ShowCallTranscriptRequest.ts create mode 100644 src/api/resources/unstable/resources/calls/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/calls/index.ts create mode 100644 src/api/resources/unstable/resources/calls/types/Call.ts create mode 100644 src/api/resources/unstable/resources/calls/types/ListCallsWithTranscriptsResponse.ts create mode 100644 src/api/resources/unstable/resources/calls/types/index.ts delete mode 100644 src/api/resources/unstable/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts create mode 100644 src/api/resources/unstable/resources/emails/client/Client.ts create mode 100644 src/api/resources/unstable/resources/emails/client/index.ts create mode 100644 src/api/resources/unstable/resources/emails/client/requests/RetrieveEmailRequest.ts create mode 100644 src/api/resources/unstable/resources/emails/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/emails/index.ts create mode 100644 src/api/resources/unstable/resources/emails/types/EmailList.ts create mode 100644 src/api/resources/unstable/resources/emails/types/EmailSetting.ts create mode 100644 src/api/resources/unstable/resources/emails/types/index.ts create mode 100644 src/api/resources/unstable/resources/internalArticles/client/Client.ts create mode 100644 src/api/resources/unstable/resources/internalArticles/client/index.ts create mode 100644 src/api/resources/unstable/resources/internalArticles/client/requests/DeleteInternalArticleRequest.ts create mode 100644 src/api/resources/unstable/resources/internalArticles/client/requests/RetrieveInternalArticleRequest.ts create mode 100644 src/api/resources/unstable/resources/internalArticles/client/requests/SearchInternalArticlesRequest.ts create mode 100644 src/api/resources/unstable/resources/internalArticles/client/requests/UpdateInternalArticleRequestBody.ts create mode 100644 src/api/resources/unstable/resources/internalArticles/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/internalArticles/index.ts create mode 100644 src/api/resources/unstable/resources/internalArticles/types/InternalArticleListItem.ts create mode 100644 src/api/resources/unstable/resources/internalArticles/types/InternalArticleSearchResponse.ts create mode 100644 src/api/resources/unstable/resources/internalArticles/types/index.ts create mode 100644 src/api/resources/unstable/resources/macros/client/Client.ts create mode 100644 src/api/resources/unstable/resources/macros/client/index.ts create mode 100644 src/api/resources/unstable/resources/macros/client/requests/GetMacroRequest.ts create mode 100644 src/api/resources/unstable/resources/macros/client/requests/ListMacrosRequest.ts create mode 100644 src/api/resources/unstable/resources/macros/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/macros/index.ts create mode 100644 src/api/resources/unstable/resources/macros/types/Macro.ts create mode 100644 src/api/resources/unstable/resources/macros/types/MacroList.ts create mode 100644 src/api/resources/unstable/resources/macros/types/index.ts create mode 100644 src/api/resources/unstable/resources/notes/client/requests/ListCompanyNotesRequest.ts create mode 100644 src/api/resources/unstable/resources/notes/types/CompanyNote.ts create mode 100644 src/api/resources/unstable/types/AiCallResponse.ts create mode 100644 src/api/resources/unstable/types/CallList.ts rename src/api/resources/unstable/types/{UpdateArticleRequestBody.ts => CreateArticleRequest.ts} (67%) create mode 100644 src/api/resources/unstable/types/CreateDataAttributeRequest.ts create mode 100644 src/api/resources/unstable/types/CreateInternalArticleRequest.ts create mode 100644 src/api/resources/unstable/types/CreateMessageRequest.ts create mode 100644 src/api/resources/unstable/types/CreateOrUpdateCompanyRequest.ts create mode 100644 src/api/resources/unstable/types/CreatePhoneSwitchRequest.ts rename src/api/resources/{ticketTypes/client/requests => unstable/types}/CreateTicketTypeRequest.ts (65%) create mode 100644 src/api/resources/unstable/types/DeletedInternalArticleObject.ts delete mode 100644 src/api/resources/unstable/types/IntercomVersion.ts delete mode 100644 src/api/resources/unstable/types/IntercomVersionUnstable.ts create mode 100644 src/api/resources/unstable/types/InternalArticleList.ts create mode 100644 src/api/resources/unstable/types/RegisterFinVoiceCallRequest.ts create mode 100644 src/api/resources/unstable/types/UpdateDataAttributeRequestBody.ts delete mode 100644 src/api/resources/unstable/types/UpdateTicketTypeRequestBody.ts delete mode 100644 src/api/types/ActionComponent.ts create mode 100644 src/api/types/AwayStatusReason.ts delete mode 100644 src/api/types/ButtonComponent.ts create mode 100644 src/api/types/CallList.ts delete mode 100644 src/api/types/CanvasObject.ts delete mode 100644 src/api/types/CheckboxComponent.ts delete mode 100644 src/api/types/CheckboxOption.ts create mode 100644 src/api/types/CompanyData.ts delete mode 100644 src/api/types/Component.ts delete mode 100644 src/api/types/ConfigureRequest.ts delete mode 100644 src/api/types/ConfigureResponse.ts create mode 100644 src/api/types/ContactBlocked.ts delete mode 100644 src/api/types/ContactCompany.ts delete mode 100644 src/api/types/ContentObject.ts delete mode 100644 src/api/types/Context.ts create mode 100644 src/api/types/ConversationAttributeUpdatedByAdmin.ts create mode 100644 src/api/types/ConversationAttributeUpdatedByWorkflow.ts create mode 100644 src/api/types/ConversationDeleted.ts rename src/api/types/{PaginatedConversationResponse.ts => ConversationList.ts} (59%) create mode 100644 src/api/types/ConversationPartMetadata.ts create mode 100644 src/api/types/ConversationResponseTime.ts rename src/api/{resources/articles/client/requests => types}/CreateArticleRequest.ts (52%) create mode 100644 src/api/types/CreateDataAttributeRequest.ts create mode 100644 src/api/types/CreateInternalArticleRequest.ts delete mode 100644 src/api/types/CreateMessageRequestTwo.ts rename src/api/{resources/companies/client/requests => types}/CreateOrUpdateCompanyRequest.ts (82%) create mode 100644 src/api/types/CreatePhoneSwitchRequest.ts delete mode 100644 src/api/types/CreateTicketRequest.ts create mode 100644 src/api/types/CreateTicketRequestBody.ts create mode 100644 src/api/types/CreateTicketTypeRequest.ts delete mode 100644 src/api/types/CurrentCanvas.ts create mode 100644 src/api/types/CustomActionFinished.ts create mode 100644 src/api/types/CustomActionStarted.ts create mode 100644 src/api/types/CustomChannelAttribute.ts create mode 100644 src/api/types/CustomChannelBaseEvent.ts create mode 100644 src/api/types/CustomChannelContact.ts create mode 100644 src/api/types/CustomChannelNotificationResponse.ts create mode 100644 src/api/types/CustomObjectInstanceDeleted.ts create mode 100644 src/api/types/CustomObjectInstanceList.ts delete mode 100644 src/api/types/DataTableComponent.ts delete mode 100644 src/api/types/DataTableItem.ts create mode 100644 src/api/types/Datetime.ts create mode 100644 src/api/types/DeletedInternalArticleObject.ts delete mode 100644 src/api/types/DividerComponent.ts delete mode 100644 src/api/types/DropdownComponent.ts delete mode 100644 src/api/types/DropdownOption.ts create mode 100644 src/api/types/EmailAddressHeader.ts create mode 100644 src/api/types/EmailMessageMetadata.ts delete mode 100644 src/api/types/Event.ts create mode 100644 src/api/types/EventDetails.ts delete mode 100644 src/api/types/ImageComponent.ts delete mode 100644 src/api/types/InitializeRequest.ts delete mode 100644 src/api/types/InitializeResponse.ts delete mode 100644 src/api/types/InputComponent.ts create mode 100644 src/api/types/InternalArticleList.ts delete mode 100644 src/api/types/ListComponent.ts delete mode 100644 src/api/types/ListItem.ts delete mode 100644 src/api/types/ListItemWithImage.ts delete mode 100644 src/api/types/ListItemWithoutImage.ts delete mode 100644 src/api/types/LiveCanvasRequest.ts delete mode 100644 src/api/types/LiveCanvasResponse.ts delete mode 100644 src/api/types/MultipleOrSingleFilterSearchRequest.ts create mode 100644 src/api/types/NotFoundErrorBody.ts create mode 100644 src/api/types/OperatorWorkflowEvent.ts delete mode 100644 src/api/types/PaginatedNewsItemResponse.ts delete mode 100644 src/api/types/PaginatedNewsfeedResponse.ts create mode 100644 src/api/types/PaginatedResponse.ts create mode 100644 src/api/types/PaginatedResponseDataItem.ts create mode 100644 src/api/types/QuickReplyOption.ts create mode 100644 src/api/types/Recipient.ts delete mode 100644 src/api/types/ResultsResponse.ts delete mode 100644 src/api/types/SheetActionComponent.ts delete mode 100644 src/api/types/SingleSelectComponent.ts delete mode 100644 src/api/types/SingleSelectOption.ts delete mode 100644 src/api/types/SpacerComponent.ts delete mode 100644 src/api/types/SubmitActionComponent.ts delete mode 100644 src/api/types/SubmitRequest.ts delete mode 100644 src/api/types/SubmitResponse.ts delete mode 100644 src/api/types/TextAreaComponent.ts delete mode 100644 src/api/types/TextComponent.ts create mode 100644 src/api/types/TicketStateList.ts create mode 100644 src/api/types/UpdateArticleRequestBody.ts create mode 100644 src/api/types/UpdateCompanyRequestBody.ts create mode 100644 src/api/types/UpdateDataAttributeRequestBody.ts delete mode 100644 src/api/types/UrlActionComponent.ts create mode 100644 src/api/types/WhatsappMessageStatusList.ts create mode 100644 src/auth/BearerAuthProvider.ts create mode 100644 src/auth/index.ts create mode 100644 src/core/auth/AuthProvider.ts create mode 100644 src/core/auth/AuthRequest.ts create mode 100644 src/core/auth/NoOpAuthProvider.ts create mode 100644 src/core/base64.ts create mode 100644 src/core/exports.ts create mode 100644 src/core/fetcher/BinaryResponse.ts create mode 100644 src/core/fetcher/EndpointMetadata.ts create mode 100644 src/core/fetcher/EndpointSupplier.ts create mode 100644 src/core/fetcher/getErrorResponseBody.ts delete mode 100644 src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts delete mode 100644 src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts delete mode 100644 src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts delete mode 100644 src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts create mode 100644 src/core/headers.ts create mode 100644 src/core/logging/exports.ts create mode 100644 src/core/logging/index.ts create mode 100644 src/core/logging/logger.ts delete mode 100644 src/core/pagination/Pageable.ts create mode 100644 src/core/pagination/exports.ts create mode 100644 src/core/url/encodePathParam.ts create mode 100644 src/core/url/index.ts create mode 100644 src/core/url/join.ts create mode 100644 src/core/url/qs.ts create mode 100644 src/errors/handleNonStatusCodeError.ts create mode 100644 src/exports.ts create mode 100644 tests/mock-server/MockServer.ts create mode 100644 tests/mock-server/MockServerPool.ts create mode 100644 tests/mock-server/mockEndpointBuilder.ts create mode 100644 tests/mock-server/randomBaseUrl.ts create mode 100644 tests/mock-server/setup.ts create mode 100644 tests/mock-server/withFormUrlEncoded.ts create mode 100644 tests/mock-server/withHeaders.ts create mode 100644 tests/mock-server/withJson.ts create mode 100644 tests/setup.ts create mode 100644 tests/tsconfig.json create mode 100644 tests/unit/base64.test.ts delete mode 100644 tests/unit/fetcher/getFetchFn.test.ts create mode 100644 tests/unit/fetcher/logging.test.ts create mode 100644 tests/unit/fetcher/redacting.test.ts delete mode 100644 tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts delete mode 100644 tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts delete mode 100644 tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts delete mode 100644 tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts delete mode 100644 tests/unit/fetcher/stream-wrappers/webpack.test.ts create mode 100644 tests/unit/logging/logger.test.ts create mode 100644 tests/unit/url/join.test.ts create mode 100644 tests/unit/url/qs.test.ts create mode 100644 tests/unit/utils/setObjectProperty.test.ts create mode 100644 tests/wire/.gitkeep create mode 100644 tests/wire/admins.test.ts create mode 100644 tests/wire/aiContent.test.ts create mode 100644 tests/wire/articles.test.ts create mode 100644 tests/wire/awayStatusReasons.test.ts create mode 100644 tests/wire/calls.test.ts create mode 100644 tests/wire/companies.test.ts create mode 100644 tests/wire/contacts.test.ts create mode 100644 tests/wire/conversations.test.ts create mode 100644 tests/wire/customChannelEvents.test.ts create mode 100644 tests/wire/customObjectInstances.test.ts create mode 100644 tests/wire/dataAttributes.test.ts create mode 100644 tests/wire/dataExport.test.ts create mode 100644 tests/wire/events.test.ts create mode 100644 tests/wire/export.test.ts create mode 100644 tests/wire/helpCenters.test.ts create mode 100644 tests/wire/helpCenters/collections.test.ts create mode 100644 tests/wire/internalArticles.test.ts create mode 100644 tests/wire/jobs.test.ts create mode 100644 tests/wire/messages.test.ts create mode 100644 tests/wire/news/feeds.test.ts create mode 100644 tests/wire/news/items.test.ts create mode 100644 tests/wire/notes.test.ts create mode 100644 tests/wire/phoneCallRedirects.test.ts create mode 100644 tests/wire/segments.test.ts create mode 100644 tests/wire/subscriptionTypes.test.ts create mode 100644 tests/wire/tags.test.ts create mode 100644 tests/wire/teams.test.ts create mode 100644 tests/wire/ticketStates.test.ts create mode 100644 tests/wire/ticketTypes.test.ts create mode 100644 tests/wire/ticketTypes/attributes.test.ts create mode 100644 tests/wire/tickets.test.ts create mode 100644 tests/wire/unstable/admins.test.ts create mode 100644 tests/wire/unstable/aiContent.test.ts create mode 100644 tests/wire/unstable/articles.test.ts create mode 100644 tests/wire/unstable/awayStatusReasons.test.ts create mode 100644 tests/wire/unstable/brands.test.ts create mode 100644 tests/wire/unstable/calls.test.ts create mode 100644 tests/wire/unstable/companies.test.ts create mode 100644 tests/wire/unstable/contacts.test.ts create mode 100644 tests/wire/unstable/conversations.test.ts create mode 100644 tests/wire/unstable/customChannelEvents.test.ts create mode 100644 tests/wire/unstable/customObjectInstances.test.ts create mode 100644 tests/wire/unstable/dataAttributes.test.ts create mode 100644 tests/wire/unstable/dataEvents.test.ts create mode 100644 tests/wire/unstable/dataExport.test.ts create mode 100644 tests/wire/unstable/emails.test.ts create mode 100644 tests/wire/unstable/export.test.ts create mode 100644 tests/wire/unstable/helpCenter.test.ts create mode 100644 tests/wire/unstable/internalArticles.test.ts create mode 100644 tests/wire/unstable/jobs.test.ts create mode 100644 tests/wire/unstable/macros.test.ts create mode 100644 tests/wire/unstable/messages.test.ts create mode 100644 tests/wire/unstable/news.test.ts create mode 100644 tests/wire/unstable/notes.test.ts create mode 100644 tests/wire/unstable/segments.test.ts create mode 100644 tests/wire/unstable/subscriptionTypes.test.ts create mode 100644 tests/wire/unstable/switch.test.ts create mode 100644 tests/wire/unstable/tags.test.ts create mode 100644 tests/wire/unstable/teams.test.ts create mode 100644 tests/wire/unstable/ticketStates.test.ts create mode 100644 tests/wire/unstable/ticketTypeAttributes.test.ts create mode 100644 tests/wire/unstable/ticketTypes.test.ts create mode 100644 tests/wire/unstable/tickets.test.ts create mode 100644 tests/wire/unstable/visitors.test.ts create mode 100644 tests/wire/visitors.test.ts create mode 100644 tsconfig.base.json create mode 100644 tsconfig.cjs.json create mode 100644 tsconfig.esm.json create mode 100644 vitest.config.mts delete mode 100644 yarn.lock diff --git a/.fern/metadata.json b/.fern/metadata.json new file mode 100644 index 00000000..ef3f5299 --- /dev/null +++ b/.fern/metadata.json @@ -0,0 +1,22 @@ +{ + "cliVersion": "3.0.2", + "generatorName": "fernapi/fern-typescript-sdk", + "generatorVersion": "3.35.8", + "generatorConfig": { + "namespaceExport": "Intercom", + "allowCustomFetcher": true, + "skipResponseValidation": true, + "includeApiReference": true, + "noSerdeLayer": true, + "enableInlineTypes": true, + "inlinePathParameters": true, + "timeoutInSeconds": 20, + "packageJson": { + "license": "Apache-2.0", + "description": "Official Node bindings to the Intercom API", + "homepage": "https://github.com/intercom/intercom-node", + "bugs": "https://github.com/intercom/intercom-node/issues", + "keywords": ["intercom", "api"] + } + } +} diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fc8979c7..6d5b7754 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -8,29 +8,38 @@ jobs: steps: - name: Checkout repo - uses: actions/checkout@v3 + uses: actions/checkout@v6 - name: Set up node - uses: actions/setup-node@v4 + uses: actions/setup-node@v6 + + - name: Install pnpm + uses: pnpm/action-setup@v4 + + - name: Install dependencies + run: pnpm install --frozen-lockfile - name: Compile - run: yarn && yarn build + run: pnpm build test: runs-on: ubuntu-latest steps: - name: Checkout repo - uses: actions/checkout@v3 + uses: actions/checkout@v6 - name: Set up node - uses: actions/setup-node@v4 + uses: actions/setup-node@v6 + + - name: Install pnpm + uses: pnpm/action-setup@v4 - - name: Compile - run: yarn + - name: Install dependencies + run: pnpm install --frozen-lockfile - name: Test - run: yarn test + run: pnpm test env: INTERCOM_API_KEY: ${{ secrets.INTERCOM_API_KEY }} @@ -42,13 +51,15 @@ jobs: id-token: write steps: - name: Checkout repo - uses: actions/checkout@v3 + uses: actions/checkout@v6 - name: Set up node - uses: actions/setup-node@v4 + uses: actions/setup-node@v6 + - name: Install pnpm + uses: pnpm/action-setup@v4 - name: Install dependencies - run: yarn install + run: pnpm install - name: Build - run: yarn build + run: pnpm build - name: Publish to npm run: | diff --git a/.npmignore b/.npmignore deleted file mode 100644 index 6db0876c..00000000 --- a/.npmignore +++ /dev/null @@ -1,9 +0,0 @@ -node_modules -src -tests -.gitignore -.github -.fernignore -.prettierrc.yml -tsconfig.json -yarn.lock \ No newline at end of file diff --git a/.prettierrc.yml b/.prettierrc.yml deleted file mode 100644 index 0c06786b..00000000 --- a/.prettierrc.yml +++ /dev/null @@ -1,2 +0,0 @@ -tabWidth: 4 -printWidth: 120 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 00000000..fe5bc2f7 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,133 @@ +# Contributing + +Thanks for your interest in contributing to this SDK! This document provides guidelines for contributing to the project. + +## Getting Started + +### Prerequisites + +- Node.js 20 or higher +- pnpm package manager + +### Installation + +Install the project dependencies: + +```bash +pnpm install +``` + +### Building + +Build the project: + +```bash +pnpm build +``` + +### Testing + +Run the test suite: + +```bash +pnpm test +``` + +Run specific test types: +- `pnpm test:unit` - Run unit tests +- `pnpm test:wire` - Run wire/integration tests + +### Linting and Formatting + +Check code style: + +```bash +pnpm run lint +pnpm run format:check +``` + +Fix code style issues: + +```bash +pnpm run lint:fix +pnpm run format:fix +``` + +Or use the combined check command: + +```bash +pnpm run check:fix +``` + +## About Generated Code + +**Important**: Most files in this SDK are automatically generated by [Fern](https://buildwithfern.com) from the API definition. Direct modifications to generated files will be overwritten the next time the SDK is generated. + +### Generated Files + +The following directories contain generated code: +- `src/api/` - API client classes and types +- `src/serialization/` - Serialization/deserialization logic +- Most TypeScript files in `src/` + +### How to Customize + +If you need to customize the SDK, you have two options: + +#### Option 1: Use `.fernignore` + +For custom code that should persist across SDK regenerations: + +1. Create a `.fernignore` file in the project root +2. Add file patterns for files you want to preserve (similar to `.gitignore` syntax) +3. Add your custom code to those files + +Files listed in `.fernignore` will not be overwritten when the SDK is regenerated. + +For more information, see the [Fern documentation on custom code](https://buildwithfern.com/learn/sdks/overview/custom-code). + +#### Option 2: Contribute to the Generator + +If you want to change how code is generated for all users of this SDK: + +1. The TypeScript SDK generator lives in the [Fern repository](https://github.com/fern-api/fern) +2. Generator code is located at `generators/typescript/sdk/` +3. Follow the [Fern contributing guidelines](https://github.com/fern-api/fern/blob/main/CONTRIBUTING.md) +4. Submit a pull request with your changes to the generator + +This approach is best for: +- Bug fixes in generated code +- New features that would benefit all users +- Improvements to code generation patterns + +## Making Changes + +### Workflow + +1. Create a new branch for your changes +2. Make your modifications +3. Run tests to ensure nothing breaks: `pnpm test` +4. Run linting and formatting: `pnpm run check:fix` +5. Build the project: `pnpm build` +6. Commit your changes with a clear commit message +7. Push your branch and create a pull request + +### Commit Messages + +Write clear, descriptive commit messages that explain what changed and why. + +### Code Style + +This project uses automated code formatting and linting. Run `pnpm run check:fix` before committing to ensure your code meets the project's style guidelines. + +## Questions or Issues? + +If you have questions or run into issues: + +1. Check the [Fern documentation](https://buildwithfern.com) +2. Search existing [GitHub issues](https://github.com/fern-api/fern/issues) +3. Open a new issue if your question hasn't been addressed + +## License + +By contributing to this project, you agree that your contributions will be licensed under the same license as the project. diff --git a/README.md b/README.md index 08d01dae..753ab107 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ [![fern shield](https://img.shields.io/badge/%F0%9F%8C%BF-Built%20with%20Fern-brightgreen)](https://buildwithfern.com?utm_source=github&utm_medium=github&utm_campaign=readme&utm_source=https%3A%2F%2Fgithub.com%2Fintercom%2Fintercom-node) [![npm shield](https://img.shields.io/npm/v/intercom-client)](https://www.npmjs.com/package/intercom-client) -The Intercom TypeScript library provides convenient access to the Intercom API from TypeScript. +The Intercom TypeScript library provides convenient access to the Intercom APIs from TypeScript. ## Project Updates @@ -27,12 +27,8 @@ Instantiate and use the client with the following: import { IntercomClient } from "intercom-client"; const client = new IntercomClient({ token: "YOUR_TOKEN" }); -await client.articles.create({ - title: "Thanks for everything", - description: "Description of the Article", - body: "Body of the Article", - author_id: 1295, - state: "published", +await client.aiContent.createContentImportSource({ + url: "https://www.example.com" }); ``` @@ -58,7 +54,7 @@ will be thrown. import { IntercomError } from "intercom-client"; try { - await client.articles.create(...); + await client.aiContent.createContentImportSource(...); } catch (err) { if (err instanceof IntercomError) { console.log(err.statusCode); @@ -77,16 +73,19 @@ List endpoints are paginated. The SDK provides an iterator so that you can simpl import { IntercomClient } from "intercom-client"; const client = new IntercomClient({ token: "YOUR_TOKEN" }); -const response = await client.articles.list(); -for await (const item of response) { +const pageableResponse = await client.articles.list(); +for await (const item of pageableResponse) { console.log(item); } // Or you can manually iterate page-by-page -const page = await client.articles.list(); +let page = await client.articles.list(); while (page.hasNextPage()) { page = page.getNextPage(); } + +// You can also access the underlying response +const response = page.response; ``` ## Advanced @@ -96,13 +95,25 @@ while (page.hasNextPage()) { If you would like to send additional headers as part of the request, use the `headers` request option. ```typescript -const response = await client.articles.create(..., { +const response = await client.aiContent.createContentImportSource(..., { headers: { 'X-Custom-Header': 'custom value' } }); ``` +### Additional Query String Parameters + +If you would like to send additional query string parameters as part of the request, use the `queryParams` request option. + +```typescript +const response = await client.aiContent.createContentImportSource(..., { + queryParams: { + 'customQueryParamKey': 'custom query param value' + } +}); +``` + ### Retries The SDK is instrumented with automatic retries with exponential backoff. A request will be retried as long @@ -118,7 +129,7 @@ A request is deemed retryable when any of the following HTTP status codes is ret Use the `maxRetries` request option to configure this behavior. ```typescript -const response = await client.articles.create(..., { +const response = await client.aiContent.createContentImportSource(..., { maxRetries: 0 // override maxRetries at the request level }); ``` @@ -128,7 +139,7 @@ const response = await client.articles.create(..., { The SDK defaults to a 60 second timeout. Use the `timeoutInSeconds` option to configure this behavior. ```typescript -const response = await client.articles.create(..., { +const response = await client.aiContent.createContentImportSource(..., { timeoutInSeconds: 30 // override timeout to 30s }); ``` @@ -139,7 +150,7 @@ The SDK allows users to abort requests at any point by passing in an abort signa ```typescript const controller = new AbortController(); -const response = await client.articles.create(..., { +const response = await client.aiContent.createContentImportSource(..., { abortSignal: controller.signal }); controller.abort(); // aborts the request @@ -151,16 +162,81 @@ The SDK provides access to raw response data, including headers, through the `.w The `.withRawResponse()` method returns a promise that results to an object with a `data` and a `rawResponse` property. ```typescript -const { data, rawResponse } = await client.articles.create(...).withRawResponse(); +const { data, rawResponse } = await client.aiContent.createContentImportSource(...).withRawResponse(); console.log(data); console.log(rawResponse.headers['X-My-Header']); ``` +### Logging + +The SDK supports logging. You can configure the logger by passing in a `logging` object to the client options. + +```typescript +import { IntercomClient, logging } from "intercom-client"; + +const client = new IntercomClient({ + ... + logging: { + level: logging.LogLevel.Debug, // defaults to logging.LogLevel.Info + logger: new logging.ConsoleLogger(), // defaults to ConsoleLogger + silent: false, // defaults to true, set to false to enable logging + } +}); +``` +The `logging` object can have the following properties: +- `level`: The log level to use. Defaults to `logging.LogLevel.Info`. +- `logger`: The logger to use. Defaults to a `logging.ConsoleLogger`. +- `silent`: Whether to silence the logger. Defaults to `true`. + +The `level` property can be one of the following values: +- `logging.LogLevel.Debug` +- `logging.LogLevel.Info` +- `logging.LogLevel.Warn` +- `logging.LogLevel.Error` + +To provide a custom logger, you can pass in an object that implements the `logging.ILogger` interface. + +
+Custom logger examples + +Here's an example using the popular `winston` logging library. +```ts +import winston from 'winston'; + +const winstonLogger = winston.createLogger({...}); + +const logger: logging.ILogger = { + debug: (msg, ...args) => winstonLogger.debug(msg, ...args), + info: (msg, ...args) => winstonLogger.info(msg, ...args), + warn: (msg, ...args) => winstonLogger.warn(msg, ...args), + error: (msg, ...args) => winstonLogger.error(msg, ...args), +}; +``` + +Here's an example using the popular `pino` logging library. + +```ts +import pino from 'pino'; + +const pinoLogger = pino({...}); + +const logger: logging.ILogger = { + debug: (msg, ...args) => pinoLogger.debug(args, msg), + info: (msg, ...args) => pinoLogger.info(args, msg), + warn: (msg, ...args) => pinoLogger.warn(args, msg), + error: (msg, ...args) => pinoLogger.error(args, msg), +}; +``` +
+ + ### Runtime Compatibility -The SDK defaults to `node-fetch` but will use the global fetch client if present. The SDK works in the following -runtimes: + +The SDK works in the following runtimes: + + - Node.js 18+ - Vercel @@ -191,14 +267,4 @@ otherwise they would be overwritten upon the next generated release. Feel free t a proof of concept, but know that we will not be able to merge it as-is. We suggest opening an issue first to discuss with us! -On the other hand, contributions to the README are always very welcome! - -## Contributing - -While we value open-source contributions to this SDK, this library is generated programmatically. -Additions made directly to this library would have to be moved over to our generation code, -otherwise they would be overwritten upon the next generated release. Feel free to open a PR as -a proof of concept, but know that we will not be able to merge it as-is. We suggest opening -an issue first to discuss with us! - -On the other hand, contributions to the README are always very welcome! +On the other hand, contributions to the README are always very welcome! \ No newline at end of file diff --git a/biome.json b/biome.json new file mode 100644 index 00000000..a777468e --- /dev/null +++ b/biome.json @@ -0,0 +1,74 @@ +{ + "$schema": "https://biomejs.dev/schemas/2.3.1/schema.json", + "root": true, + "vcs": { + "enabled": false + }, + "files": { + "ignoreUnknown": true, + "includes": [ + "**", + "!!dist", + "!!**/dist", + "!!lib", + "!!**/lib", + "!!_tmp_*", + "!!**/_tmp_*", + "!!*.tmp", + "!!**/*.tmp", + "!!.tmp/", + "!!**/.tmp/", + "!!*.log", + "!!**/*.log", + "!!**/.DS_Store", + "!!**/Thumbs.db" + ] + }, + "formatter": { + "enabled": true, + "indentStyle": "space", + "indentWidth": 4, + "lineWidth": 120 + }, + "javascript": { + "formatter": { + "quoteStyle": "double" + } + }, + "assist": { + "enabled": true, + "actions": { + "source": { + "organizeImports": "on" + } + } + }, + "linter": { + "rules": { + "style": { + "useNodejsImportProtocol": "off" + }, + "suspicious": { + "noAssignInExpressions": "warn", + "noUselessEscapeInString": { + "level": "warn", + "fix": "none", + "options": {} + }, + "noThenProperty": "warn", + "useIterableCallbackReturn": "warn", + "noShadowRestrictedNames": "warn", + "noTsIgnore": { + "level": "warn", + "fix": "none", + "options": {} + }, + "noConfusingVoidType": { + "level": "warn", + "fix": "none", + "options": {} + } + } + } + } +} diff --git a/jest.config.mjs b/jest.config.mjs deleted file mode 100644 index c7248211..00000000 --- a/jest.config.mjs +++ /dev/null @@ -1,8 +0,0 @@ -/** @type {import('jest').Config} */ -export default { - preset: "ts-jest", - testEnvironment: "node", - moduleNameMapper: { - "(.+)\.js$": "$1", - }, -}; diff --git a/package.json b/package.json index 00b818fa..5d739ad4 100644 --- a/package.json +++ b/package.json @@ -1,46 +1,68 @@ { "name": "intercom-client", - "version": "6.4.0", + "version": "7.0.0", "private": false, - "repository": "https://github.com/intercom/intercom-node", - "main": "./index.js", - "types": "./index.d.ts", - "scripts": { - "format": "prettier . --write --ignore-unknown", - "build": "tsc", - "prepack": "cp -rv dist/. .", - "test": "jest" + "repository": "github:intercom/intercom-node", + "type": "commonjs", + "main": "./dist/cjs/index.js", + "module": "./dist/esm/index.mjs", + "types": "./dist/cjs/index.d.ts", + "exports": { + ".": { + "types": "./dist/cjs/index.d.ts", + "import": { + "types": "./dist/esm/index.d.mts", + "default": "./dist/esm/index.mjs" + }, + "require": { + "types": "./dist/cjs/index.d.ts", + "default": "./dist/cjs/index.js" + }, + "default": "./dist/cjs/index.js" + }, + "./package.json": "./package.json" }, - "dependencies": { - "url-join": "4.0.1", - "form-data": "^4.0.0", - "formdata-node": "^6.0.3", - "node-fetch": "^2.7.0", - "qs": "^6.13.1", - "readable-stream": "^4.5.2", - "js-base64": "3.7.7" + "files": [ + "dist", + "reference.md", + "README.md", + "LICENSE" + ], + "scripts": { + "format": "biome format --write --skip-parse-errors --no-errors-on-unmatched --max-diagnostics=none", + "format:check": "biome format --skip-parse-errors --no-errors-on-unmatched --max-diagnostics=none", + "lint": "biome lint --skip-parse-errors --no-errors-on-unmatched --max-diagnostics=none", + "lint:fix": "biome lint --fix --unsafe --skip-parse-errors --no-errors-on-unmatched --max-diagnostics=none", + "check": "biome check --skip-parse-errors --no-errors-on-unmatched --max-diagnostics=none", + "check:fix": "biome check --fix --unsafe --skip-parse-errors --no-errors-on-unmatched --max-diagnostics=none", + "build": "pnpm build:cjs && pnpm build:esm", + "build:cjs": "tsc --project ./tsconfig.cjs.json", + "build:esm": "tsc --project ./tsconfig.esm.json && node scripts/rename-to-esm-files.js dist/esm", + "test": "vitest", + "test:unit": "vitest --project unit", + "test:wire": "vitest --project wire" }, + "dependencies": {}, "devDependencies": { - "@types/url-join": "4.0.1", - "@types/qs": "^6.9.17", - "@types/node-fetch": "^2.6.12", - "@types/readable-stream": "^4.0.18", "webpack": "^5.97.1", "ts-loader": "^9.5.1", - "jest": "^29.7.0", - "@types/jest": "^29.5.14", - "ts-jest": "^29.1.1", - "jest-environment-jsdom": "^29.7.0", + "vitest": "^3.2.4", + "msw": "2.11.2", "@types/node": "^18.19.70", - "prettier": "^3.4.2", - "typescript": "~5.7.2" + "typescript": "~5.7.2", + "@biomejs/biome": "2.3.1" }, "browser": { "fs": false, "os": false, - "path": false + "path": false, + "stream": false + }, + "packageManager": "pnpm@10.20.0", + "engines": { + "node": ">=18.0.0" }, - "packageManager": "yarn@1.22.22", + "sideEffects": false, "license": "Apache-2.0", "description": "Official Node bindings to the Intercom API", "homepage": "https://github.com/intercom/intercom-node", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml new file mode 100644 index 00000000..7a489b0d --- /dev/null +++ b/pnpm-lock.yaml @@ -0,0 +1,2132 @@ +lockfileVersion: '9.0' + +settings: + autoInstallPeers: true + excludeLinksFromLockfile: false + +importers: + + .: + devDependencies: + '@biomejs/biome': + specifier: 2.3.1 + version: 2.3.1 + '@types/node': + specifier: ^18.19.70 + version: 18.19.130 + msw: + specifier: 2.11.2 + version: 2.11.2(@types/node@18.19.130)(typescript@5.7.3) + ts-loader: + specifier: ^9.5.1 + version: 9.5.4(typescript@5.7.3)(webpack@5.103.0) + typescript: + specifier: ~5.7.2 + version: 5.7.3 + vitest: + specifier: ^3.2.4 + version: 3.2.4(@types/node@18.19.130)(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(terser@5.44.1) + webpack: + specifier: ^5.97.1 + version: 5.103.0 + +packages: + + '@biomejs/biome@2.3.1': + resolution: {integrity: sha512-A29evf1R72V5bo4o2EPxYMm5mtyGvzp2g+biZvRFx29nWebGyyeOSsDWGx3tuNNMFRepGwxmA9ZQ15mzfabK2w==} + engines: {node: '>=14.21.3'} + hasBin: true + + '@biomejs/cli-darwin-arm64@2.3.1': + resolution: {integrity: sha512-ombSf3MnTUueiYGN1SeI9tBCsDUhpWzOwS63Dove42osNh0PfE1cUtHFx6eZ1+MYCCLwXzlFlYFdrJ+U7h6LcA==} + engines: {node: '>=14.21.3'} + cpu: [arm64] + os: [darwin] + + '@biomejs/cli-darwin-x64@2.3.1': + resolution: {integrity: sha512-pcOfwyoQkrkbGvXxRvZNe5qgD797IowpJPovPX5biPk2FwMEV+INZqfCaz4G5bVq9hYnjwhRMamg11U4QsRXrQ==} + engines: {node: '>=14.21.3'} + cpu: [x64] + os: [darwin] + + '@biomejs/cli-linux-arm64-musl@2.3.1': + resolution: {integrity: sha512-+DZYv8l7FlUtTrWs1Tdt1KcNCAmRO87PyOnxKGunbWm5HKg1oZBSbIIPkjrCtDZaeqSG1DiGx7qF+CPsquQRcg==} + engines: {node: '>=14.21.3'} + cpu: [arm64] + os: [linux] + + '@biomejs/cli-linux-arm64@2.3.1': + resolution: {integrity: sha512-td5O8pFIgLs8H1sAZsD6v+5quODihyEw4nv2R8z7swUfIK1FKk+15e4eiYVLcAE4jUqngvh4j3JCNgg0Y4o4IQ==} + engines: {node: '>=14.21.3'} + cpu: [arm64] + os: [linux] + + '@biomejs/cli-linux-x64-musl@2.3.1': + resolution: {integrity: sha512-Y3Ob4nqgv38Mh+6EGHltuN+Cq8aj/gyMTJYzkFZV2AEj+9XzoXB9VNljz9pjfFNHUxvLEV4b55VWyxozQTBaUQ==} + engines: {node: '>=14.21.3'} + cpu: [x64] + os: [linux] + + '@biomejs/cli-linux-x64@2.3.1': + resolution: {integrity: sha512-PYWgEO7up7XYwSAArOpzsVCiqxBCXy53gsReAb1kKYIyXaoAlhBaBMvxR/k2Rm9aTuZ662locXUmPk/Aj+Xu+Q==} + engines: {node: '>=14.21.3'} + cpu: [x64] + os: [linux] + + '@biomejs/cli-win32-arm64@2.3.1': + resolution: {integrity: sha512-RHIG/zgo+69idUqVvV3n8+j58dKYABRpMyDmfWu2TITC+jwGPiEaT0Q3RKD+kQHiS80mpBrST0iUGeEXT0bU9A==} + engines: {node: '>=14.21.3'} + cpu: [arm64] + os: [win32] + + '@biomejs/cli-win32-x64@2.3.1': + resolution: {integrity: sha512-izl30JJ5Dp10mi90Eko47zhxE6pYyWPcnX1NQxKpL/yMhXxf95oLTzfpu4q+MDBh/gemNqyJEwjBpe0MT5iWPA==} + engines: {node: '>=14.21.3'} + cpu: [x64] + os: [win32] + + '@bundled-es-modules/cookie@2.0.1': + resolution: {integrity: sha512-8o+5fRPLNbjbdGRRmJj3h6Hh1AQJf2dk3qQ/5ZFb+PXkRNiSoMGGUKlsgLfrxneb72axVJyIYji64E2+nNfYyw==} + + '@bundled-es-modules/statuses@1.0.1': + resolution: {integrity: sha512-yn7BklA5acgcBr+7w064fGV+SGIFySjCKpqjcWgBAIfrAkY+4GQTJJHQMeT3V/sgz23VTEVV8TtOmkvJAhFVfg==} + + '@esbuild/aix-ppc64@0.25.12': + resolution: {integrity: sha512-Hhmwd6CInZ3dwpuGTF8fJG6yoWmsToE+vYgD4nytZVxcu1ulHpUQRAB1UJ8+N1Am3Mz4+xOByoQoSZf4D+CpkA==} + engines: {node: '>=18'} + cpu: [ppc64] + os: [aix] + + '@esbuild/android-arm64@0.25.12': + resolution: {integrity: sha512-6AAmLG7zwD1Z159jCKPvAxZd4y/VTO0VkprYy+3N2FtJ8+BQWFXU+OxARIwA46c5tdD9SsKGZ/1ocqBS/gAKHg==} + engines: {node: '>=18'} + cpu: [arm64] + os: [android] + + '@esbuild/android-arm@0.25.12': + resolution: {integrity: sha512-VJ+sKvNA/GE7Ccacc9Cha7bpS8nyzVv0jdVgwNDaR4gDMC/2TTRc33Ip8qrNYUcpkOHUT5OZ0bUcNNVZQ9RLlg==} + engines: {node: '>=18'} + cpu: [arm] + os: [android] + + '@esbuild/android-x64@0.25.12': + resolution: {integrity: sha512-5jbb+2hhDHx5phYR2By8GTWEzn6I9UqR11Kwf22iKbNpYrsmRB18aX/9ivc5cabcUiAT/wM+YIZ6SG9QO6a8kg==} + engines: {node: '>=18'} + cpu: [x64] + os: [android] + + '@esbuild/darwin-arm64@0.25.12': + resolution: {integrity: sha512-N3zl+lxHCifgIlcMUP5016ESkeQjLj/959RxxNYIthIg+CQHInujFuXeWbWMgnTo4cp5XVHqFPmpyu9J65C1Yg==} + engines: {node: '>=18'} + cpu: [arm64] + os: [darwin] + + '@esbuild/darwin-x64@0.25.12': + resolution: {integrity: sha512-HQ9ka4Kx21qHXwtlTUVbKJOAnmG1ipXhdWTmNXiPzPfWKpXqASVcWdnf2bnL73wgjNrFXAa3yYvBSd9pzfEIpA==} + engines: {node: '>=18'} + cpu: [x64] + os: [darwin] + + '@esbuild/freebsd-arm64@0.25.12': + resolution: {integrity: sha512-gA0Bx759+7Jve03K1S0vkOu5Lg/85dou3EseOGUes8flVOGxbhDDh/iZaoek11Y8mtyKPGF3vP8XhnkDEAmzeg==} + engines: {node: '>=18'} + cpu: [arm64] + os: [freebsd] + + '@esbuild/freebsd-x64@0.25.12': + resolution: {integrity: sha512-TGbO26Yw2xsHzxtbVFGEXBFH0FRAP7gtcPE7P5yP7wGy7cXK2oO7RyOhL5NLiqTlBh47XhmIUXuGciXEqYFfBQ==} + engines: {node: '>=18'} + cpu: [x64] + os: [freebsd] + + '@esbuild/linux-arm64@0.25.12': + resolution: {integrity: sha512-8bwX7a8FghIgrupcxb4aUmYDLp8pX06rGh5HqDT7bB+8Rdells6mHvrFHHW2JAOPZUbnjUpKTLg6ECyzvas2AQ==} + engines: {node: '>=18'} + cpu: [arm64] + os: [linux] + + '@esbuild/linux-arm@0.25.12': + resolution: {integrity: sha512-lPDGyC1JPDou8kGcywY0YILzWlhhnRjdof3UlcoqYmS9El818LLfJJc3PXXgZHrHCAKs/Z2SeZtDJr5MrkxtOw==} + engines: {node: '>=18'} + cpu: [arm] + os: [linux] + + '@esbuild/linux-ia32@0.25.12': + resolution: {integrity: sha512-0y9KrdVnbMM2/vG8KfU0byhUN+EFCny9+8g202gYqSSVMonbsCfLjUO+rCci7pM0WBEtz+oK/PIwHkzxkyharA==} + engines: {node: '>=18'} + cpu: [ia32] + os: [linux] + + '@esbuild/linux-loong64@0.25.12': + resolution: {integrity: sha512-h///Lr5a9rib/v1GGqXVGzjL4TMvVTv+s1DPoxQdz7l/AYv6LDSxdIwzxkrPW438oUXiDtwM10o9PmwS/6Z0Ng==} + engines: {node: '>=18'} + cpu: [loong64] + os: [linux] + + '@esbuild/linux-mips64el@0.25.12': + resolution: {integrity: sha512-iyRrM1Pzy9GFMDLsXn1iHUm18nhKnNMWscjmp4+hpafcZjrr2WbT//d20xaGljXDBYHqRcl8HnxbX6uaA/eGVw==} + engines: {node: '>=18'} + cpu: [mips64el] + os: [linux] + + '@esbuild/linux-ppc64@0.25.12': + resolution: {integrity: sha512-9meM/lRXxMi5PSUqEXRCtVjEZBGwB7P/D4yT8UG/mwIdze2aV4Vo6U5gD3+RsoHXKkHCfSxZKzmDssVlRj1QQA==} + engines: {node: '>=18'} + cpu: [ppc64] + os: [linux] + + '@esbuild/linux-riscv64@0.25.12': + resolution: {integrity: sha512-Zr7KR4hgKUpWAwb1f3o5ygT04MzqVrGEGXGLnj15YQDJErYu/BGg+wmFlIDOdJp0PmB0lLvxFIOXZgFRrdjR0w==} + engines: {node: '>=18'} + cpu: [riscv64] + os: [linux] + + '@esbuild/linux-s390x@0.25.12': + resolution: {integrity: sha512-MsKncOcgTNvdtiISc/jZs/Zf8d0cl/t3gYWX8J9ubBnVOwlk65UIEEvgBORTiljloIWnBzLs4qhzPkJcitIzIg==} + engines: {node: '>=18'} + cpu: [s390x] + os: [linux] + + '@esbuild/linux-x64@0.25.12': + resolution: {integrity: sha512-uqZMTLr/zR/ed4jIGnwSLkaHmPjOjJvnm6TVVitAa08SLS9Z0VM8wIRx7gWbJB5/J54YuIMInDquWyYvQLZkgw==} + engines: {node: '>=18'} + cpu: [x64] + os: [linux] + + '@esbuild/netbsd-arm64@0.25.12': + resolution: {integrity: sha512-xXwcTq4GhRM7J9A8Gv5boanHhRa/Q9KLVmcyXHCTaM4wKfIpWkdXiMog/KsnxzJ0A1+nD+zoecuzqPmCRyBGjg==} + engines: {node: '>=18'} + cpu: [arm64] + os: [netbsd] + + '@esbuild/netbsd-x64@0.25.12': + resolution: {integrity: sha512-Ld5pTlzPy3YwGec4OuHh1aCVCRvOXdH8DgRjfDy/oumVovmuSzWfnSJg+VtakB9Cm0gxNO9BzWkj6mtO1FMXkQ==} + engines: {node: '>=18'} + cpu: [x64] + os: [netbsd] + + '@esbuild/openbsd-arm64@0.25.12': + resolution: {integrity: sha512-fF96T6KsBo/pkQI950FARU9apGNTSlZGsv1jZBAlcLL1MLjLNIWPBkj5NlSz8aAzYKg+eNqknrUJ24QBybeR5A==} + engines: {node: '>=18'} + cpu: [arm64] + os: [openbsd] + + '@esbuild/openbsd-x64@0.25.12': + resolution: {integrity: sha512-MZyXUkZHjQxUvzK7rN8DJ3SRmrVrke8ZyRusHlP+kuwqTcfWLyqMOE3sScPPyeIXN/mDJIfGXvcMqCgYKekoQw==} + engines: {node: '>=18'} + cpu: [x64] + os: [openbsd] + + '@esbuild/openharmony-arm64@0.25.12': + resolution: {integrity: sha512-rm0YWsqUSRrjncSXGA7Zv78Nbnw4XL6/dzr20cyrQf7ZmRcsovpcRBdhD43Nuk3y7XIoW2OxMVvwuRvk9XdASg==} + engines: {node: '>=18'} + cpu: [arm64] + os: [openharmony] + + '@esbuild/sunos-x64@0.25.12': + resolution: {integrity: sha512-3wGSCDyuTHQUzt0nV7bocDy72r2lI33QL3gkDNGkod22EsYl04sMf0qLb8luNKTOmgF/eDEDP5BFNwoBKH441w==} + engines: {node: '>=18'} + cpu: [x64] + os: [sunos] + + '@esbuild/win32-arm64@0.25.12': + resolution: {integrity: sha512-rMmLrur64A7+DKlnSuwqUdRKyd3UE7oPJZmnljqEptesKM8wx9J8gx5u0+9Pq0fQQW8vqeKebwNXdfOyP+8Bsg==} + engines: {node: '>=18'} + cpu: [arm64] + os: [win32] + + '@esbuild/win32-ia32@0.25.12': + resolution: {integrity: sha512-HkqnmmBoCbCwxUKKNPBixiWDGCpQGVsrQfJoVGYLPT41XWF8lHuE5N6WhVia2n4o5QK5M4tYr21827fNhi4byQ==} + engines: {node: '>=18'} + cpu: [ia32] + os: [win32] + + '@esbuild/win32-x64@0.25.12': + resolution: {integrity: sha512-alJC0uCZpTFrSL0CCDjcgleBXPnCrEAhTBILpeAp7M/OFgoqtAetfBzX0xM00MUsVVPpVjlPuMbREqnZCXaTnA==} + engines: {node: '>=18'} + cpu: [x64] + os: [win32] + + '@inquirer/ansi@1.0.2': + resolution: {integrity: sha512-S8qNSZiYzFd0wAcyG5AXCvUHC5Sr7xpZ9wZ2py9XR88jUz8wooStVx5M6dRzczbBWjic9NP7+rY0Xi7qqK/aMQ==} + engines: {node: '>=18'} + + '@inquirer/confirm@5.1.21': + resolution: {integrity: sha512-KR8edRkIsUayMXV+o3Gv+q4jlhENF9nMYUZs9PA2HzrXeHI8M5uDag70U7RJn9yyiMZSbtF5/UexBtAVtZGSbQ==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@inquirer/core@10.3.2': + resolution: {integrity: sha512-43RTuEbfP8MbKzedNqBrlhhNKVwoK//vUFNW3Q3vZ88BLcrs4kYpGg+B2mm5p2K/HfygoCxuKwJJiv8PbGmE0A==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@inquirer/figures@1.0.15': + resolution: {integrity: sha512-t2IEY+unGHOzAaVM5Xx6DEWKeXlDDcNPeDyUpsRc6CUhBfU3VQOEl+Vssh7VNp1dR8MdUJBWhuObjXCsVpjN5g==} + engines: {node: '>=18'} + + '@inquirer/type@3.0.10': + resolution: {integrity: sha512-BvziSRxfz5Ov8ch0z/n3oijRSEcEsHnhggm4xFZe93DHcUCTlutlq9Ox4SVENAfcRD22UQq7T/atg9Wr3k09eA==} + engines: {node: '>=18'} + peerDependencies: + '@types/node': '>=18' + peerDependenciesMeta: + '@types/node': + optional: true + + '@jridgewell/gen-mapping@0.3.13': + resolution: {integrity: sha512-2kkt/7niJ6MgEPxF0bYdQ6etZaA+fQvDcLKckhy1yIQOzaoKjBBjSj63/aLVjYE3qhRt5dvM+uUyfCg6UKCBbA==} + + '@jridgewell/resolve-uri@3.1.2': + resolution: {integrity: sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==} + engines: {node: '>=6.0.0'} + + '@jridgewell/source-map@0.3.11': + resolution: {integrity: sha512-ZMp1V8ZFcPG5dIWnQLr3NSI1MiCU7UETdS/A0G8V/XWHvJv3ZsFqutJn1Y5RPmAPX6F3BiE397OqveU/9NCuIA==} + + '@jridgewell/sourcemap-codec@1.5.5': + resolution: {integrity: sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==} + + '@jridgewell/trace-mapping@0.3.31': + resolution: {integrity: sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==} + + '@mswjs/interceptors@0.39.8': + resolution: {integrity: sha512-2+BzZbjRO7Ct61k8fMNHEtoKjeWI9pIlHFTqBwZ5icHpqszIgEZbjb1MW5Z0+bITTCTl3gk4PDBxs9tA/csXvA==} + engines: {node: '>=18'} + + '@open-draft/deferred-promise@2.2.0': + resolution: {integrity: sha512-CecwLWx3rhxVQF6V4bAgPS5t+So2sTbPgAzafKkVizyi7tlwpcFpdFqq+wqF2OwNBmqFuu6tOyouTuxgpMfzmA==} + + '@open-draft/logger@0.3.0': + resolution: {integrity: sha512-X2g45fzhxH238HKO4xbSr7+wBS8Fvw6ixhTDuvLd5mqh6bJJCFAPwU9mPDxbcrRtfxv4u5IHCEH77BmxvXmmxQ==} + + '@open-draft/until@2.1.0': + resolution: {integrity: sha512-U69T3ItWHvLwGg5eJ0n3I62nWuE6ilHlmz7zM0npLBRvPRd7e6NYmg54vvRtP5mZG7kZqZCFVdsTWo7BPtBujg==} + + '@rollup/rollup-android-arm-eabi@4.53.3': + resolution: {integrity: sha512-mRSi+4cBjrRLoaal2PnqH82Wqyb+d3HsPUN/W+WslCXsZsyHa9ZeQQX/pQsZaVIWDkPcpV6jJ+3KLbTbgnwv8w==} + cpu: [arm] + os: [android] + + '@rollup/rollup-android-arm64@4.53.3': + resolution: {integrity: sha512-CbDGaMpdE9sh7sCmTrTUyllhrg65t6SwhjlMJsLr+J8YjFuPmCEjbBSx4Z/e4SmDyH3aB5hGaJUP2ltV/vcs4w==} + cpu: [arm64] + os: [android] + + '@rollup/rollup-darwin-arm64@4.53.3': + resolution: {integrity: sha512-Nr7SlQeqIBpOV6BHHGZgYBuSdanCXuw09hon14MGOLGmXAFYjx1wNvquVPmpZnl0tLjg25dEdr4IQ6GgyToCUA==} + cpu: [arm64] + os: [darwin] + + '@rollup/rollup-darwin-x64@4.53.3': + resolution: {integrity: sha512-DZ8N4CSNfl965CmPktJ8oBnfYr3F8dTTNBQkRlffnUarJ2ohudQD17sZBa097J8xhQ26AwhHJ5mvUyQW8ddTsQ==} + cpu: [x64] + os: [darwin] + + '@rollup/rollup-freebsd-arm64@4.53.3': + resolution: {integrity: sha512-yMTrCrK92aGyi7GuDNtGn2sNW+Gdb4vErx4t3Gv/Tr+1zRb8ax4z8GWVRfr3Jw8zJWvpGHNpss3vVlbF58DZ4w==} + cpu: [arm64] + os: [freebsd] + + '@rollup/rollup-freebsd-x64@4.53.3': + resolution: {integrity: sha512-lMfF8X7QhdQzseM6XaX0vbno2m3hlyZFhwcndRMw8fbAGUGL3WFMBdK0hbUBIUYcEcMhVLr1SIamDeuLBnXS+Q==} + cpu: [x64] + os: [freebsd] + + '@rollup/rollup-linux-arm-gnueabihf@4.53.3': + resolution: {integrity: sha512-k9oD15soC/Ln6d2Wv/JOFPzZXIAIFLp6B+i14KhxAfnq76ajt0EhYc5YPeX6W1xJkAdItcVT+JhKl1QZh44/qw==} + cpu: [arm] + os: [linux] + + '@rollup/rollup-linux-arm-musleabihf@4.53.3': + resolution: {integrity: sha512-vTNlKq+N6CK/8UktsrFuc+/7NlEYVxgaEgRXVUVK258Z5ymho29skzW1sutgYjqNnquGwVUObAaxae8rZ6YMhg==} + cpu: [arm] + os: [linux] + + '@rollup/rollup-linux-arm64-gnu@4.53.3': + resolution: {integrity: sha512-RGrFLWgMhSxRs/EWJMIFM1O5Mzuz3Xy3/mnxJp/5cVhZ2XoCAxJnmNsEyeMJtpK+wu0FJFWz+QF4mjCA7AUQ3w==} + cpu: [arm64] + os: [linux] + + '@rollup/rollup-linux-arm64-musl@4.53.3': + resolution: {integrity: sha512-kASyvfBEWYPEwe0Qv4nfu6pNkITLTb32p4yTgzFCocHnJLAHs+9LjUu9ONIhvfT/5lv4YS5muBHyuV84epBo/A==} + cpu: [arm64] + os: [linux] + + '@rollup/rollup-linux-loong64-gnu@4.53.3': + resolution: {integrity: sha512-JiuKcp2teLJwQ7vkJ95EwESWkNRFJD7TQgYmCnrPtlu50b4XvT5MOmurWNrCj3IFdyjBQ5p9vnrX4JM6I8OE7g==} + cpu: [loong64] + os: [linux] + + '@rollup/rollup-linux-ppc64-gnu@4.53.3': + resolution: {integrity: sha512-EoGSa8nd6d3T7zLuqdojxC20oBfNT8nexBbB/rkxgKj5T5vhpAQKKnD+h3UkoMuTyXkP5jTjK/ccNRmQrPNDuw==} + cpu: [ppc64] + os: [linux] + + '@rollup/rollup-linux-riscv64-gnu@4.53.3': + resolution: {integrity: sha512-4s+Wped2IHXHPnAEbIB0YWBv7SDohqxobiiPA1FIWZpX+w9o2i4LezzH/NkFUl8LRci/8udci6cLq+jJQlh+0g==} + cpu: [riscv64] + os: [linux] + + '@rollup/rollup-linux-riscv64-musl@4.53.3': + resolution: {integrity: sha512-68k2g7+0vs2u9CxDt5ktXTngsxOQkSEV/xBbwlqYcUrAVh6P9EgMZvFsnHy4SEiUl46Xf0IObWVbMvPrr2gw8A==} + cpu: [riscv64] + os: [linux] + + '@rollup/rollup-linux-s390x-gnu@4.53.3': + resolution: {integrity: sha512-VYsFMpULAz87ZW6BVYw3I6sWesGpsP9OPcyKe8ofdg9LHxSbRMd7zrVrr5xi/3kMZtpWL/wC+UIJWJYVX5uTKg==} + cpu: [s390x] + os: [linux] + + '@rollup/rollup-linux-x64-gnu@4.53.3': + resolution: {integrity: sha512-3EhFi1FU6YL8HTUJZ51imGJWEX//ajQPfqWLI3BQq4TlvHy4X0MOr5q3D2Zof/ka0d5FNdPwZXm3Yyib/UEd+w==} + cpu: [x64] + os: [linux] + + '@rollup/rollup-linux-x64-musl@4.53.3': + resolution: {integrity: sha512-eoROhjcc6HbZCJr+tvVT8X4fW3/5g/WkGvvmwz/88sDtSJzO7r/blvoBDgISDiCjDRZmHpwud7h+6Q9JxFwq1Q==} + cpu: [x64] + os: [linux] + + '@rollup/rollup-openharmony-arm64@4.53.3': + resolution: {integrity: sha512-OueLAWgrNSPGAdUdIjSWXw+u/02BRTcnfw9PN41D2vq/JSEPnJnVuBgw18VkN8wcd4fjUs+jFHVM4t9+kBSNLw==} + cpu: [arm64] + os: [openharmony] + + '@rollup/rollup-win32-arm64-msvc@4.53.3': + resolution: {integrity: sha512-GOFuKpsxR/whszbF/bzydebLiXIHSgsEUp6M0JI8dWvi+fFa1TD6YQa4aSZHtpmh2/uAlj/Dy+nmby3TJ3pkTw==} + cpu: [arm64] + os: [win32] + + '@rollup/rollup-win32-ia32-msvc@4.53.3': + resolution: {integrity: sha512-iah+THLcBJdpfZ1TstDFbKNznlzoxa8fmnFYK4V67HvmuNYkVdAywJSoteUszvBQ9/HqN2+9AZghbajMsFT+oA==} + cpu: [ia32] + os: [win32] + + '@rollup/rollup-win32-x64-gnu@4.53.3': + resolution: {integrity: sha512-J9QDiOIZlZLdcot5NXEepDkstocktoVjkaKUtqzgzpt2yWjGlbYiKyp05rWwk4nypbYUNoFAztEgixoLaSETkg==} + cpu: [x64] + os: [win32] + + '@rollup/rollup-win32-x64-msvc@4.53.3': + resolution: {integrity: sha512-UhTd8u31dXadv0MopwGgNOBpUVROFKWVQgAg5N1ESyCz8AuBcMqm4AuTjrwgQKGDfoFuz02EuMRHQIw/frmYKQ==} + cpu: [x64] + os: [win32] + + '@types/chai@5.2.3': + resolution: {integrity: sha512-Mw558oeA9fFbv65/y4mHtXDs9bPnFMZAL/jxdPFUpOHHIXX91mcgEHbS5Lahr+pwZFR8A7GQleRWeI6cGFC2UA==} + + '@types/cookie@0.6.0': + resolution: {integrity: sha512-4Kh9a6B2bQciAhf7FSuMRRkUWecJgJu9nPnx3yzpsfXX/c50REIqpHY4C82bXP90qrLtXtkDxTZosYO3UpOwlA==} + + '@types/deep-eql@4.0.2': + resolution: {integrity: sha512-c9h9dVVMigMPc4bwTvC5dxqtqJZwQPePsWjPlpSOnojbor6pGqdk541lfA7AqFQr5pB1BRdq0juY9db81BwyFw==} + + '@types/eslint-scope@3.7.7': + resolution: {integrity: sha512-MzMFlSLBqNF2gcHWO0G1vP/YQyfvrxZ0bF+u7mzUdZ1/xK4A4sru+nraZz5i3iEIk1l1uyicaDVTB4QbbEkAYg==} + + '@types/eslint@9.6.1': + resolution: {integrity: sha512-FXx2pKgId/WyYo2jXw63kk7/+TY7u7AziEJxJAnSFzHlqTAS3Ync6SvgYAN/k4/PQpnnVuzoMuVnByKK2qp0ag==} + + '@types/estree@1.0.8': + resolution: {integrity: sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w==} + + '@types/json-schema@7.0.15': + resolution: {integrity: sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==} + + '@types/node@18.19.130': + resolution: {integrity: sha512-GRaXQx6jGfL8sKfaIDD6OupbIHBr9jv7Jnaml9tB7l4v068PAOXqfcujMMo5PhbIs6ggR1XODELqahT2R8v0fg==} + + '@types/statuses@2.0.6': + resolution: {integrity: sha512-xMAgYwceFhRA2zY+XbEA7mxYbA093wdiW8Vu6gZPGWy9cmOyU9XesH1tNcEWsKFd5Vzrqx5T3D38PWx1FIIXkA==} + + '@vitest/expect@3.2.4': + resolution: {integrity: sha512-Io0yyORnB6sikFlt8QW5K7slY4OjqNX9jmJQ02QDda8lyM6B5oNgVWoSoKPac8/kgnCUzuHQKrSLtu/uOqqrig==} + + '@vitest/mocker@3.2.4': + resolution: {integrity: sha512-46ryTE9RZO/rfDd7pEqFl7etuyzekzEhUbTW3BvmeO/BcCMEgq59BKhek3dXDWgAj4oMK6OZi+vRr1wPW6qjEQ==} + peerDependencies: + msw: ^2.4.9 + vite: ^5.0.0 || ^6.0.0 || ^7.0.0-0 + peerDependenciesMeta: + msw: + optional: true + vite: + optional: true + + '@vitest/pretty-format@3.2.4': + resolution: {integrity: sha512-IVNZik8IVRJRTr9fxlitMKeJeXFFFN0JaB9PHPGQ8NKQbGpfjlTx9zO4RefN8gp7eqjNy8nyK3NZmBzOPeIxtA==} + + '@vitest/runner@3.2.4': + resolution: {integrity: sha512-oukfKT9Mk41LreEW09vt45f8wx7DordoWUZMYdY/cyAk7w5TWkTRCNZYF7sX7n2wB7jyGAl74OxgwhPgKaqDMQ==} + + '@vitest/snapshot@3.2.4': + resolution: {integrity: sha512-dEYtS7qQP2CjU27QBC5oUOxLE/v5eLkGqPE0ZKEIDGMs4vKWe7IjgLOeauHsR0D5YuuycGRO5oSRXnwnmA78fQ==} + + '@vitest/spy@3.2.4': + resolution: {integrity: sha512-vAfasCOe6AIK70iP5UD11Ac4siNUNJ9i/9PZ3NKx07sG6sUxeag1LWdNrMWeKKYBLlzuK+Gn65Yd5nyL6ds+nw==} + + '@vitest/utils@3.2.4': + resolution: {integrity: sha512-fB2V0JFrQSMsCo9HiSq3Ezpdv4iYaXRG1Sx8edX3MwxfyNn83mKiGzOcH+Fkxt4MHxr3y42fQi1oeAInqgX2QA==} + + '@webassemblyjs/ast@1.14.1': + resolution: {integrity: sha512-nuBEDgQfm1ccRp/8bCQrx1frohyufl4JlbMMZ4P1wpeOfDhF6FQkxZJ1b/e+PLwr6X1Nhw6OLme5usuBWYBvuQ==} + + '@webassemblyjs/floating-point-hex-parser@1.13.2': + resolution: {integrity: sha512-6oXyTOzbKxGH4steLbLNOu71Oj+C8Lg34n6CqRvqfS2O71BxY6ByfMDRhBytzknj9yGUPVJ1qIKhRlAwO1AovA==} + + '@webassemblyjs/helper-api-error@1.13.2': + resolution: {integrity: sha512-U56GMYxy4ZQCbDZd6JuvvNV/WFildOjsaWD3Tzzvmw/mas3cXzRJPMjP83JqEsgSbyrmaGjBfDtV7KDXV9UzFQ==} + + '@webassemblyjs/helper-buffer@1.14.1': + resolution: {integrity: sha512-jyH7wtcHiKssDtFPRB+iQdxlDf96m0E39yb0k5uJVhFGleZFoNw1c4aeIcVUPPbXUVJ94wwnMOAqUHyzoEPVMA==} + + '@webassemblyjs/helper-numbers@1.13.2': + resolution: {integrity: sha512-FE8aCmS5Q6eQYcV3gI35O4J789wlQA+7JrqTTpJqn5emA4U2hvwJmvFRC0HODS+3Ye6WioDklgd6scJ3+PLnEA==} + + '@webassemblyjs/helper-wasm-bytecode@1.13.2': + resolution: {integrity: sha512-3QbLKy93F0EAIXLh0ogEVR6rOubA9AoZ+WRYhNbFyuB70j3dRdwH9g+qXhLAO0kiYGlg3TxDV+I4rQTr/YNXkA==} + + '@webassemblyjs/helper-wasm-section@1.14.1': + resolution: {integrity: sha512-ds5mXEqTJ6oxRoqjhWDU83OgzAYjwsCV8Lo/N+oRsNDmx/ZDpqalmrtgOMkHwxsG0iI//3BwWAErYRHtgn0dZw==} + + '@webassemblyjs/ieee754@1.13.2': + resolution: {integrity: sha512-4LtOzh58S/5lX4ITKxnAK2USuNEvpdVV9AlgGQb8rJDHaLeHciwG4zlGr0j/SNWlr7x3vO1lDEsuePvtcDNCkw==} + + '@webassemblyjs/leb128@1.13.2': + resolution: {integrity: sha512-Lde1oNoIdzVzdkNEAWZ1dZ5orIbff80YPdHx20mrHwHrVNNTjNr8E3xz9BdpcGqRQbAEa+fkrCb+fRFTl/6sQw==} + + '@webassemblyjs/utf8@1.13.2': + resolution: {integrity: sha512-3NQWGjKTASY1xV5m7Hr0iPeXD9+RDobLll3T9d2AO+g3my8xy5peVyjSag4I50mR1bBSN/Ct12lo+R9tJk0NZQ==} + + '@webassemblyjs/wasm-edit@1.14.1': + resolution: {integrity: sha512-RNJUIQH/J8iA/1NzlE4N7KtyZNHi3w7at7hDjvRNm5rcUXa00z1vRz3glZoULfJ5mpvYhLybmVcwcjGrC1pRrQ==} + + '@webassemblyjs/wasm-gen@1.14.1': + resolution: {integrity: sha512-AmomSIjP8ZbfGQhumkNvgC33AY7qtMCXnN6bL2u2Js4gVCg8fp735aEiMSBbDR7UQIj90n4wKAFUSEd0QN2Ukg==} + + '@webassemblyjs/wasm-opt@1.14.1': + resolution: {integrity: sha512-PTcKLUNvBqnY2U6E5bdOQcSM+oVP/PmrDY9NzowJjislEjwP/C4an2303MCVS2Mg9d3AJpIGdUFIQQWbPds0Sw==} + + '@webassemblyjs/wasm-parser@1.14.1': + resolution: {integrity: sha512-JLBl+KZ0R5qB7mCnud/yyX08jWFw5MsoalJ1pQ4EdFlgj9VdXKGuENGsiCIjegI1W7p91rUlcB/LB5yRJKNTcQ==} + + '@webassemblyjs/wast-printer@1.14.1': + resolution: {integrity: sha512-kPSSXE6De1XOR820C90RIo2ogvZG+c3KiHzqUoO/F34Y2shGzesfqv7o57xrxovZJH/MetF5UjroJ/R/3isoiw==} + + '@xtuc/ieee754@1.2.0': + resolution: {integrity: sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA==} + + '@xtuc/long@4.2.2': + resolution: {integrity: sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==} + + acorn-import-phases@1.0.4: + resolution: {integrity: sha512-wKmbr/DDiIXzEOiWrTTUcDm24kQ2vGfZQvM2fwg2vXqR5uW6aapr7ObPtj1th32b9u90/Pf4AItvdTh42fBmVQ==} + engines: {node: '>=10.13.0'} + peerDependencies: + acorn: ^8.14.0 + + acorn@8.15.0: + resolution: {integrity: sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg==} + engines: {node: '>=0.4.0'} + hasBin: true + + ajv-formats@2.1.1: + resolution: {integrity: sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA==} + peerDependencies: + ajv: ^8.0.0 + peerDependenciesMeta: + ajv: + optional: true + + ajv-keywords@5.1.0: + resolution: {integrity: sha512-YCS/JNFAUyr5vAuhk1DWm1CBxRHW9LbJ2ozWeemrIqpbsqKjHVxYPyi5GC0rjZIT5JxJ3virVTS8wk4i/Z+krw==} + peerDependencies: + ajv: ^8.8.2 + + ajv@8.17.1: + resolution: {integrity: sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==} + + ansi-regex@5.0.1: + resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} + engines: {node: '>=8'} + + ansi-styles@4.3.0: + resolution: {integrity: sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==} + engines: {node: '>=8'} + + assertion-error@2.0.1: + resolution: {integrity: sha512-Izi8RQcffqCeNVgFigKli1ssklIbpHnCYc6AknXGYoB6grJqyeby7jv12JUQgmTAnIDnbck1uxksT4dzN3PWBA==} + engines: {node: '>=12'} + + baseline-browser-mapping@2.8.32: + resolution: {integrity: sha512-OPz5aBThlyLFgxyhdwf/s2+8ab3OvT7AdTNvKHBwpXomIYeXqpUUuT8LrdtxZSsWJ4R4CU1un4XGh5Ez3nlTpw==} + hasBin: true + + braces@3.0.3: + resolution: {integrity: sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==} + engines: {node: '>=8'} + + browserslist@4.28.0: + resolution: {integrity: sha512-tbydkR/CxfMwelN0vwdP/pLkDwyAASZ+VfWm4EOwlB6SWhx1sYnWLqo8N5j0rAzPfzfRaxt0mM/4wPU/Su84RQ==} + engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} + hasBin: true + + buffer-from@1.1.2: + resolution: {integrity: sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==} + + cac@6.7.14: + resolution: {integrity: sha512-b6Ilus+c3RrdDk+JhLKUAQfzzgLEPy6wcXqS7f/xe1EETvsDP6GORG7SFuOs6cID5YkqchW/LXZbX5bc8j7ZcQ==} + engines: {node: '>=8'} + + caniuse-lite@1.0.30001757: + resolution: {integrity: sha512-r0nnL/I28Zi/yjk1el6ilj27tKcdjLsNqAOZr0yVjWPrSQyHgKI2INaEWw21bAQSv2LXRt1XuCS/GomNpWOxsQ==} + + chai@5.3.3: + resolution: {integrity: sha512-4zNhdJD/iOjSH0A05ea+Ke6MU5mmpQcbQsSOkgdaUMJ9zTlDTD/GYlwohmIE2u0gaxHYiVHEn1Fw9mZ/ktJWgw==} + engines: {node: '>=18'} + + chalk@4.1.2: + resolution: {integrity: sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==} + engines: {node: '>=10'} + + check-error@2.1.1: + resolution: {integrity: sha512-OAlb+T7V4Op9OwdkjmguYRqncdlx5JiofwOAUkmTF+jNdHwzTaTs4sRAGpzLF3oOz5xAyDGrPgeIDFQmDOTiJw==} + engines: {node: '>= 16'} + + chrome-trace-event@1.0.4: + resolution: {integrity: sha512-rNjApaLzuwaOTjCiT8lSDdGN1APCiqkChLMJxJPWLunPAt5fy8xgU9/jNOchV84wfIxrA0lRQB7oCT8jrn/wrQ==} + engines: {node: '>=6.0'} + + cli-width@4.1.0: + resolution: {integrity: sha512-ouuZd4/dm2Sw5Gmqy6bGyNNNe1qt9RpmxveLSO7KcgsTnU7RXfsw+/bukWGo1abgBiMAic068rclZsO4IWmmxQ==} + engines: {node: '>= 12'} + + cliui@8.0.1: + resolution: {integrity: sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==} + engines: {node: '>=12'} + + color-convert@2.0.1: + resolution: {integrity: sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==} + engines: {node: '>=7.0.0'} + + color-name@1.1.4: + resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==} + + commander@2.20.3: + resolution: {integrity: sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==} + + cookie@0.7.2: + resolution: {integrity: sha512-yki5XnKuf750l50uGTllt6kKILY4nQ1eNIQatoXEByZ5dWgnKqbnqmTrBE5B4N7lrMJKQ2ytWMiTO2o0v6Ew/w==} + engines: {node: '>= 0.6'} + + debug@4.4.3: + resolution: {integrity: sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==} + engines: {node: '>=6.0'} + peerDependencies: + supports-color: '*' + peerDependenciesMeta: + supports-color: + optional: true + + deep-eql@5.0.2: + resolution: {integrity: sha512-h5k/5U50IJJFpzfL6nO9jaaumfjO/f2NjK/oYB2Djzm4p9L+3T9qWpZqZ2hAbLPuuYq9wrU08WQyBTL5GbPk5Q==} + engines: {node: '>=6'} + + electron-to-chromium@1.5.263: + resolution: {integrity: sha512-DrqJ11Knd+lo+dv+lltvfMDLU27g14LMdH2b0O3Pio4uk0x+z7OR+JrmyacTPN2M8w3BrZ7/RTwG3R9B7irPlg==} + + emoji-regex@8.0.0: + resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} + + enhanced-resolve@5.18.3: + resolution: {integrity: sha512-d4lC8xfavMeBjzGr2vECC3fsGXziXZQyJxD868h2M/mBI3PwAuODxAkLkq5HYuvrPYcUtiLzsTo8U3PgX3Ocww==} + engines: {node: '>=10.13.0'} + + es-module-lexer@1.7.0: + resolution: {integrity: sha512-jEQoCwk8hyb2AZziIOLhDqpm5+2ww5uIE6lkO/6jcOCusfk6LhMHpXXfBLXTZ7Ydyt0j4VoUQv6uGNYbdW+kBA==} + + esbuild@0.25.12: + resolution: {integrity: sha512-bbPBYYrtZbkt6Os6FiTLCTFxvq4tt3JKall1vRwshA3fdVztsLAatFaZobhkBC8/BrPetoa0oksYoKXoG4ryJg==} + engines: {node: '>=18'} + hasBin: true + + escalade@3.2.0: + resolution: {integrity: sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==} + engines: {node: '>=6'} + + eslint-scope@5.1.1: + resolution: {integrity: sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==} + engines: {node: '>=8.0.0'} + + esrecurse@4.3.0: + resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==} + engines: {node: '>=4.0'} + + estraverse@4.3.0: + resolution: {integrity: sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==} + engines: {node: '>=4.0'} + + estraverse@5.3.0: + resolution: {integrity: sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==} + engines: {node: '>=4.0'} + + estree-walker@3.0.3: + resolution: {integrity: sha512-7RUKfXgSMMkzt6ZuXmqapOurLGPPfgj6l9uRZ7lRGolvk0y2yocc35LdcxKC5PQZdn2DMqioAQ2NoWcrTKmm6g==} + + events@3.3.0: + resolution: {integrity: sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==} + engines: {node: '>=0.8.x'} + + expect-type@1.2.2: + resolution: {integrity: sha512-JhFGDVJ7tmDJItKhYgJCGLOWjuK9vPxiXoUFLwLDc99NlmklilbiQJwoctZtt13+xMw91MCk/REan6MWHqDjyA==} + engines: {node: '>=12.0.0'} + + fast-deep-equal@3.1.3: + resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==} + + fast-uri@3.1.0: + resolution: {integrity: sha512-iPeeDKJSWf4IEOasVVrknXpaBV0IApz/gp7S2bb7Z4Lljbl2MGJRqInZiUrQwV16cpzw/D3S5j5Julj/gT52AA==} + + fdir@6.5.0: + resolution: {integrity: sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==} + engines: {node: '>=12.0.0'} + peerDependencies: + picomatch: ^3 || ^4 + peerDependenciesMeta: + picomatch: + optional: true + + fill-range@7.1.1: + resolution: {integrity: sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==} + engines: {node: '>=8'} + + fsevents@2.3.3: + resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==} + engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} + os: [darwin] + + get-caller-file@2.0.5: + resolution: {integrity: sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==} + engines: {node: 6.* || 8.* || >= 10.*} + + glob-to-regexp@0.4.1: + resolution: {integrity: sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==} + + graceful-fs@4.2.11: + resolution: {integrity: sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==} + + graphql@16.12.0: + resolution: {integrity: sha512-DKKrynuQRne0PNpEbzuEdHlYOMksHSUI8Zc9Unei5gTsMNA2/vMpoMz/yKba50pejK56qj98qM0SjYxAKi13gQ==} + engines: {node: ^12.22.0 || ^14.16.0 || ^16.0.0 || >=17.0.0} + + has-flag@4.0.0: + resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==} + engines: {node: '>=8'} + + headers-polyfill@4.0.3: + resolution: {integrity: sha512-IScLbePpkvO846sIwOtOTDjutRMWdXdJmXdMvk6gCBHxFO8d+QKOQedyZSxFTTFYRSmlgSTDtXqqq4pcenBXLQ==} + + is-fullwidth-code-point@3.0.0: + resolution: {integrity: sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==} + engines: {node: '>=8'} + + is-node-process@1.2.0: + resolution: {integrity: sha512-Vg4o6/fqPxIjtxgUH5QLJhwZ7gW5diGCVlXpuUfELC62CuxM1iHcRe51f2W1FDy04Ai4KJkagKjx3XaqyfRKXw==} + + is-number@7.0.0: + resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==} + engines: {node: '>=0.12.0'} + + jest-worker@27.5.1: + resolution: {integrity: sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg==} + engines: {node: '>= 10.13.0'} + + js-tokens@9.0.1: + resolution: {integrity: sha512-mxa9E9ITFOt0ban3j6L5MpjwegGz6lBQmM1IJkWeBZGcMxto50+eWdjC/52xDbS2vy0k7vIMK0Fe2wfL9OQSpQ==} + + json-parse-even-better-errors@2.3.1: + resolution: {integrity: sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==} + + json-schema-traverse@1.0.0: + resolution: {integrity: sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==} + + loader-runner@4.3.1: + resolution: {integrity: sha512-IWqP2SCPhyVFTBtRcgMHdzlf9ul25NwaFx4wCEH/KjAXuuHY4yNjvPXsBokp8jCB936PyWRaPKUNh8NvylLp2Q==} + engines: {node: '>=6.11.5'} + + loupe@3.2.1: + resolution: {integrity: sha512-CdzqowRJCeLU72bHvWqwRBBlLcMEtIvGrlvef74kMnV2AolS9Y8xUv1I0U/MNAWMhBlKIoyuEgoJ0t/bbwHbLQ==} + + magic-string@0.30.21: + resolution: {integrity: sha512-vd2F4YUyEXKGcLHoq+TEyCjxueSeHnFxyyjNp80yg0XV4vUhnDer/lvvlqM/arB5bXQN5K2/3oinyCRyx8T2CQ==} + + merge-stream@2.0.0: + resolution: {integrity: sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==} + + micromatch@4.0.8: + resolution: {integrity: sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==} + engines: {node: '>=8.6'} + + mime-db@1.52.0: + resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==} + engines: {node: '>= 0.6'} + + mime-types@2.1.35: + resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==} + engines: {node: '>= 0.6'} + + ms@2.1.3: + resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==} + + msw@2.11.2: + resolution: {integrity: sha512-MI54hLCsrMwiflkcqlgYYNJJddY5/+S0SnONvhv1owOplvqohKSQyGejpNdUGyCwgs4IH7PqaNbPw/sKOEze9Q==} + engines: {node: '>=18'} + hasBin: true + peerDependencies: + typescript: '>= 4.8.x' + peerDependenciesMeta: + typescript: + optional: true + + mute-stream@2.0.0: + resolution: {integrity: sha512-WWdIxpyjEn+FhQJQQv9aQAYlHoNVdzIzUySNV1gHUPDSdZJ3yZn7pAAbQcV7B56Mvu881q9FZV+0Vx2xC44VWA==} + engines: {node: ^18.17.0 || >=20.5.0} + + nanoid@3.3.11: + resolution: {integrity: sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==} + engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} + hasBin: true + + neo-async@2.6.2: + resolution: {integrity: sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==} + + node-releases@2.0.27: + resolution: {integrity: sha512-nmh3lCkYZ3grZvqcCH+fjmQ7X+H0OeZgP40OierEaAptX4XofMh5kwNbWh7lBduUzCcV/8kZ+NDLCwm2iorIlA==} + + outvariant@1.4.3: + resolution: {integrity: sha512-+Sl2UErvtsoajRDKCE5/dBz4DIvHXQQnAxtQTF04OJxY0+DyZXSo5P5Bb7XYWOh81syohlYL24hbDwxedPUJCA==} + + path-to-regexp@6.3.0: + resolution: {integrity: sha512-Yhpw4T9C6hPpgPeA28us07OJeqZ5EzQTkbfwuhsUg0c237RomFoETJgmp2sa3F/41gfLE6G5cqcYwznmeEeOlQ==} + + pathe@2.0.3: + resolution: {integrity: sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==} + + pathval@2.0.1: + resolution: {integrity: sha512-//nshmD55c46FuFw26xV/xFAaB5HF9Xdap7HJBBnrKdAd6/GxDBaNA1870O79+9ueg61cZLSVc+OaFlfmObYVQ==} + engines: {node: '>= 14.16'} + + picocolors@1.1.1: + resolution: {integrity: sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==} + + picomatch@2.3.1: + resolution: {integrity: sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==} + engines: {node: '>=8.6'} + + picomatch@4.0.3: + resolution: {integrity: sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==} + engines: {node: '>=12'} + + postcss@8.5.6: + resolution: {integrity: sha512-3Ybi1tAuwAP9s0r1UQ2J4n5Y0G05bJkpUIO0/bI9MhwmD70S5aTWbXGBwxHrelT+XM1k6dM0pk+SwNkpTRN7Pg==} + engines: {node: ^10 || ^12 || >=14} + + randombytes@2.1.0: + resolution: {integrity: sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==} + + require-directory@2.1.1: + resolution: {integrity: sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==} + engines: {node: '>=0.10.0'} + + require-from-string@2.0.2: + resolution: {integrity: sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==} + engines: {node: '>=0.10.0'} + + rettime@0.7.0: + resolution: {integrity: sha512-LPRKoHnLKd/r3dVxcwO7vhCW+orkOGj9ViueosEBK6ie89CijnfRlhaDhHq/3Hxu4CkWQtxwlBG0mzTQY6uQjw==} + + rollup@4.53.3: + resolution: {integrity: sha512-w8GmOxZfBmKknvdXU1sdM9NHcoQejwF/4mNgj2JuEEdRaHwwF12K7e9eXn1nLZ07ad+du76mkVsyeb2rKGllsA==} + engines: {node: '>=18.0.0', npm: '>=8.0.0'} + hasBin: true + + safe-buffer@5.2.1: + resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==} + + schema-utils@4.3.3: + resolution: {integrity: sha512-eflK8wEtyOE6+hsaRVPxvUKYCpRgzLqDTb8krvAsRIwOGlHoSgYLgBXoubGgLd2fT41/OUYdb48v4k4WWHQurA==} + engines: {node: '>= 10.13.0'} + + semver@7.7.3: + resolution: {integrity: sha512-SdsKMrI9TdgjdweUSR9MweHA4EJ8YxHn8DFaDisvhVlUOe4BF1tLD7GAj0lIqWVl+dPb/rExr0Btby5loQm20Q==} + engines: {node: '>=10'} + hasBin: true + + serialize-javascript@6.0.2: + resolution: {integrity: sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==} + + siginfo@2.0.0: + resolution: {integrity: sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g==} + + signal-exit@4.1.0: + resolution: {integrity: sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==} + engines: {node: '>=14'} + + source-map-js@1.2.1: + resolution: {integrity: sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==} + engines: {node: '>=0.10.0'} + + source-map-support@0.5.21: + resolution: {integrity: sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==} + + source-map@0.6.1: + resolution: {integrity: sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==} + engines: {node: '>=0.10.0'} + + source-map@0.7.6: + resolution: {integrity: sha512-i5uvt8C3ikiWeNZSVZNWcfZPItFQOsYTUAOkcUPGd8DqDy1uOUikjt5dG+uRlwyvR108Fb9DOd4GvXfT0N2/uQ==} + engines: {node: '>= 12'} + + stackback@0.0.2: + resolution: {integrity: sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==} + + statuses@2.0.2: + resolution: {integrity: sha512-DvEy55V3DB7uknRo+4iOGT5fP1slR8wQohVdknigZPMpMstaKJQWhwiYBACJE3Ul2pTnATihhBYnRhZQHGBiRw==} + engines: {node: '>= 0.8'} + + std-env@3.10.0: + resolution: {integrity: sha512-5GS12FdOZNliM5mAOxFRg7Ir0pWz8MdpYm6AY6VPkGpbA7ZzmbzNcBJQ0GPvvyWgcY7QAhCgf9Uy89I03faLkg==} + + strict-event-emitter@0.5.1: + resolution: {integrity: sha512-vMgjE/GGEPEFnhFub6pa4FmJBRBVOLpIII2hvCZ8Kzb7K0hlHo7mQv6xYrBvCL2LtAIBwFUK8wvuJgTVSQ5MFQ==} + + string-width@4.2.3: + resolution: {integrity: sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==} + engines: {node: '>=8'} + + strip-ansi@6.0.1: + resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==} + engines: {node: '>=8'} + + strip-literal@3.1.0: + resolution: {integrity: sha512-8r3mkIM/2+PpjHoOtiAW8Rg3jJLHaV7xPwG+YRGrv6FP0wwk/toTpATxWYOW0BKdWwl82VT2tFYi5DlROa0Mxg==} + + supports-color@7.2.0: + resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} + engines: {node: '>=8'} + + supports-color@8.1.1: + resolution: {integrity: sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==} + engines: {node: '>=10'} + + tapable@2.3.0: + resolution: {integrity: sha512-g9ljZiwki/LfxmQADO3dEY1CbpmXT5Hm2fJ+QaGKwSXUylMybePR7/67YW7jOrrvjEgL1Fmz5kzyAjWVWLlucg==} + engines: {node: '>=6'} + + terser-webpack-plugin@5.3.14: + resolution: {integrity: sha512-vkZjpUjb6OMS7dhV+tILUW6BhpDR7P2L/aQSAv+Uwk+m8KATX9EccViHTJR2qDtACKPIYndLGCyl3FMo+r2LMw==} + engines: {node: '>= 10.13.0'} + peerDependencies: + '@swc/core': '*' + esbuild: '*' + uglify-js: '*' + webpack: ^5.1.0 + peerDependenciesMeta: + '@swc/core': + optional: true + esbuild: + optional: true + uglify-js: + optional: true + + terser@5.44.1: + resolution: {integrity: sha512-t/R3R/n0MSwnnazuPpPNVO60LX0SKL45pyl9YlvxIdkH0Of7D5qM2EVe+yASRIlY5pZ73nclYJfNANGWPwFDZw==} + engines: {node: '>=10'} + hasBin: true + + tinybench@2.9.0: + resolution: {integrity: sha512-0+DUvqWMValLmha6lr4kD8iAMK1HzV0/aKnCtWb9v9641TnP/MFb7Pc2bxoxQjTXAErryXVgUOfv2YqNllqGeg==} + + tinyexec@0.3.2: + resolution: {integrity: sha512-KQQR9yN7R5+OSwaK0XQoj22pwHoTlgYqmUscPYoknOoWCWfj/5/ABTMRi69FrKU5ffPVh5QcFikpWJI/P1ocHA==} + + tinyglobby@0.2.15: + resolution: {integrity: sha512-j2Zq4NyQYG5XMST4cbs02Ak8iJUdxRM0XI5QyxXuZOzKOINmWurp3smXu3y5wDcJrptwpSjgXHzIQxR0omXljQ==} + engines: {node: '>=12.0.0'} + + tinypool@1.1.1: + resolution: {integrity: sha512-Zba82s87IFq9A9XmjiX5uZA/ARWDrB03OHlq+Vw1fSdt0I+4/Kutwy8BP4Y/y/aORMo61FQ0vIb5j44vSo5Pkg==} + engines: {node: ^18.0.0 || >=20.0.0} + + tinyrainbow@2.0.0: + resolution: {integrity: sha512-op4nsTR47R6p0vMUUoYl/a+ljLFVtlfaXkLQmqfLR1qHma1h/ysYk4hEXZ880bf2CYgTskvTa/e196Vd5dDQXw==} + engines: {node: '>=14.0.0'} + + tinyspy@4.0.4: + resolution: {integrity: sha512-azl+t0z7pw/z958Gy9svOTuzqIk6xq+NSheJzn5MMWtWTFywIacg2wUlzKFGtt3cthx0r2SxMK0yzJOR0IES7Q==} + engines: {node: '>=14.0.0'} + + tldts-core@7.0.19: + resolution: {integrity: sha512-lJX2dEWx0SGH4O6p+7FPwYmJ/bu1JbcGJ8RLaG9b7liIgZ85itUVEPbMtWRVrde/0fnDPEPHW10ZsKW3kVsE9A==} + + tldts@7.0.19: + resolution: {integrity: sha512-8PWx8tvC4jDB39BQw1m4x8y5MH1BcQ5xHeL2n7UVFulMPH/3Q0uiamahFJ3lXA0zO2SUyRXuVVbWSDmstlt9YA==} + hasBin: true + + to-regex-range@5.0.1: + resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} + engines: {node: '>=8.0'} + + tough-cookie@6.0.0: + resolution: {integrity: sha512-kXuRi1mtaKMrsLUxz3sQYvVl37B0Ns6MzfrtV5DvJceE9bPyspOqk9xxv7XbZWcfLWbFmm997vl83qUWVJA64w==} + engines: {node: '>=16'} + + ts-loader@9.5.4: + resolution: {integrity: sha512-nCz0rEwunlTZiy6rXFByQU1kVVpCIgUpc/psFiKVrUwrizdnIbRFu8w7bxhUF0X613DYwT4XzrZHpVyMe758hQ==} + engines: {node: '>=12.0.0'} + peerDependencies: + typescript: '*' + webpack: ^5.0.0 + + type-fest@4.41.0: + resolution: {integrity: sha512-TeTSQ6H5YHvpqVwBRcnLDCBnDOHWYu7IvGbHT6N8AOymcr9PJGjc1GTtiWZTYg0NCgYwvnYWEkVChQAr9bjfwA==} + engines: {node: '>=16'} + + typescript@5.7.3: + resolution: {integrity: sha512-84MVSjMEHP+FQRPy3pX9sTVV/INIex71s9TL2Gm5FG/WG1SqXeKyZ0k7/blY/4FdOzI12CBy1vGc4og/eus0fw==} + engines: {node: '>=14.17'} + hasBin: true + + undici-types@5.26.5: + resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==} + + update-browserslist-db@1.1.4: + resolution: {integrity: sha512-q0SPT4xyU84saUX+tomz1WLkxUbuaJnR1xWt17M7fJtEJigJeWUNGUqrauFXsHnqev9y9JTRGwk13tFBuKby4A==} + hasBin: true + peerDependencies: + browserslist: '>= 4.21.0' + + vite-node@3.2.4: + resolution: {integrity: sha512-EbKSKh+bh1E1IFxeO0pg1n4dvoOTt0UDiXMd/qn++r98+jPO1xtJilvXldeuQ8giIB5IkpjCgMleHMNEsGH6pg==} + engines: {node: ^18.0.0 || ^20.0.0 || >=22.0.0} + hasBin: true + + vite@7.2.6: + resolution: {integrity: sha512-tI2l/nFHC5rLh7+5+o7QjKjSR04ivXDF4jcgV0f/bTQ+OJiITy5S6gaynVsEM+7RqzufMnVbIon6Sr5x1SDYaQ==} + engines: {node: ^20.19.0 || >=22.12.0} + hasBin: true + peerDependencies: + '@types/node': ^20.19.0 || >=22.12.0 + jiti: '>=1.21.0' + less: ^4.0.0 + lightningcss: ^1.21.0 + sass: ^1.70.0 + sass-embedded: ^1.70.0 + stylus: '>=0.54.8' + sugarss: ^5.0.0 + terser: ^5.16.0 + tsx: ^4.8.1 + yaml: ^2.4.2 + peerDependenciesMeta: + '@types/node': + optional: true + jiti: + optional: true + less: + optional: true + lightningcss: + optional: true + sass: + optional: true + sass-embedded: + optional: true + stylus: + optional: true + sugarss: + optional: true + terser: + optional: true + tsx: + optional: true + yaml: + optional: true + + vitest@3.2.4: + resolution: {integrity: sha512-LUCP5ev3GURDysTWiP47wRRUpLKMOfPh+yKTx3kVIEiu5KOMeqzpnYNsKyOoVrULivR8tLcks4+lga33Whn90A==} + engines: {node: ^18.0.0 || ^20.0.0 || >=22.0.0} + hasBin: true + peerDependencies: + '@edge-runtime/vm': '*' + '@types/debug': ^4.1.12 + '@types/node': ^18.0.0 || ^20.0.0 || >=22.0.0 + '@vitest/browser': 3.2.4 + '@vitest/ui': 3.2.4 + happy-dom: '*' + jsdom: '*' + peerDependenciesMeta: + '@edge-runtime/vm': + optional: true + '@types/debug': + optional: true + '@types/node': + optional: true + '@vitest/browser': + optional: true + '@vitest/ui': + optional: true + happy-dom: + optional: true + jsdom: + optional: true + + watchpack@2.4.4: + resolution: {integrity: sha512-c5EGNOiyxxV5qmTtAB7rbiXxi1ooX1pQKMLX/MIabJjRA0SJBQOjKF+KSVfHkr9U1cADPon0mRiVe/riyaiDUA==} + engines: {node: '>=10.13.0'} + + webpack-sources@3.3.3: + resolution: {integrity: sha512-yd1RBzSGanHkitROoPFd6qsrxt+oFhg/129YzheDGqeustzX0vTZJZsSsQjVQC4yzBQ56K55XU8gaNCtIzOnTg==} + engines: {node: '>=10.13.0'} + + webpack@5.103.0: + resolution: {integrity: sha512-HU1JOuV1OavsZ+mfigY0j8d1TgQgbZ6M+J75zDkpEAwYeXjWSqrGJtgnPblJjd/mAyTNQ7ygw0MiKOn6etz8yw==} + engines: {node: '>=10.13.0'} + hasBin: true + peerDependencies: + webpack-cli: '*' + peerDependenciesMeta: + webpack-cli: + optional: true + + why-is-node-running@2.3.0: + resolution: {integrity: sha512-hUrmaWBdVDcxvYqnyh09zunKzROWjbZTiNy8dBEjkS7ehEDQibXJ7XvlmtbwuTclUiIyN+CyXQD4Vmko8fNm8w==} + engines: {node: '>=8'} + hasBin: true + + wrap-ansi@6.2.0: + resolution: {integrity: sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA==} + engines: {node: '>=8'} + + wrap-ansi@7.0.0: + resolution: {integrity: sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==} + engines: {node: '>=10'} + + y18n@5.0.8: + resolution: {integrity: sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==} + engines: {node: '>=10'} + + yargs-parser@21.1.1: + resolution: {integrity: sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==} + engines: {node: '>=12'} + + yargs@17.7.2: + resolution: {integrity: sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==} + engines: {node: '>=12'} + + yoctocolors-cjs@2.1.3: + resolution: {integrity: sha512-U/PBtDf35ff0D8X8D0jfdzHYEPFxAI7jJlxZXwCSez5M3190m+QobIfh+sWDWSHMCWWJN2AWamkegn6vr6YBTw==} + engines: {node: '>=18'} + +snapshots: + + '@biomejs/biome@2.3.1': + optionalDependencies: + '@biomejs/cli-darwin-arm64': 2.3.1 + '@biomejs/cli-darwin-x64': 2.3.1 + '@biomejs/cli-linux-arm64': 2.3.1 + '@biomejs/cli-linux-arm64-musl': 2.3.1 + '@biomejs/cli-linux-x64': 2.3.1 + '@biomejs/cli-linux-x64-musl': 2.3.1 + '@biomejs/cli-win32-arm64': 2.3.1 + '@biomejs/cli-win32-x64': 2.3.1 + + '@biomejs/cli-darwin-arm64@2.3.1': + optional: true + + '@biomejs/cli-darwin-x64@2.3.1': + optional: true + + '@biomejs/cli-linux-arm64-musl@2.3.1': + optional: true + + '@biomejs/cli-linux-arm64@2.3.1': + optional: true + + '@biomejs/cli-linux-x64-musl@2.3.1': + optional: true + + '@biomejs/cli-linux-x64@2.3.1': + optional: true + + '@biomejs/cli-win32-arm64@2.3.1': + optional: true + + '@biomejs/cli-win32-x64@2.3.1': + optional: true + + '@bundled-es-modules/cookie@2.0.1': + dependencies: + cookie: 0.7.2 + + '@bundled-es-modules/statuses@1.0.1': + dependencies: + statuses: 2.0.2 + + '@esbuild/aix-ppc64@0.25.12': + optional: true + + '@esbuild/android-arm64@0.25.12': + optional: true + + '@esbuild/android-arm@0.25.12': + optional: true + + '@esbuild/android-x64@0.25.12': + optional: true + + '@esbuild/darwin-arm64@0.25.12': + optional: true + + '@esbuild/darwin-x64@0.25.12': + optional: true + + '@esbuild/freebsd-arm64@0.25.12': + optional: true + + '@esbuild/freebsd-x64@0.25.12': + optional: true + + '@esbuild/linux-arm64@0.25.12': + optional: true + + '@esbuild/linux-arm@0.25.12': + optional: true + + '@esbuild/linux-ia32@0.25.12': + optional: true + + '@esbuild/linux-loong64@0.25.12': + optional: true + + '@esbuild/linux-mips64el@0.25.12': + optional: true + + '@esbuild/linux-ppc64@0.25.12': + optional: true + + '@esbuild/linux-riscv64@0.25.12': + optional: true + + '@esbuild/linux-s390x@0.25.12': + optional: true + + '@esbuild/linux-x64@0.25.12': + optional: true + + '@esbuild/netbsd-arm64@0.25.12': + optional: true + + '@esbuild/netbsd-x64@0.25.12': + optional: true + + '@esbuild/openbsd-arm64@0.25.12': + optional: true + + '@esbuild/openbsd-x64@0.25.12': + optional: true + + '@esbuild/openharmony-arm64@0.25.12': + optional: true + + '@esbuild/sunos-x64@0.25.12': + optional: true + + '@esbuild/win32-arm64@0.25.12': + optional: true + + '@esbuild/win32-ia32@0.25.12': + optional: true + + '@esbuild/win32-x64@0.25.12': + optional: true + + '@inquirer/ansi@1.0.2': {} + + '@inquirer/confirm@5.1.21(@types/node@18.19.130)': + dependencies: + '@inquirer/core': 10.3.2(@types/node@18.19.130) + '@inquirer/type': 3.0.10(@types/node@18.19.130) + optionalDependencies: + '@types/node': 18.19.130 + + '@inquirer/core@10.3.2(@types/node@18.19.130)': + dependencies: + '@inquirer/ansi': 1.0.2 + '@inquirer/figures': 1.0.15 + '@inquirer/type': 3.0.10(@types/node@18.19.130) + cli-width: 4.1.0 + mute-stream: 2.0.0 + signal-exit: 4.1.0 + wrap-ansi: 6.2.0 + yoctocolors-cjs: 2.1.3 + optionalDependencies: + '@types/node': 18.19.130 + + '@inquirer/figures@1.0.15': {} + + '@inquirer/type@3.0.10(@types/node@18.19.130)': + optionalDependencies: + '@types/node': 18.19.130 + + '@jridgewell/gen-mapping@0.3.13': + dependencies: + '@jridgewell/sourcemap-codec': 1.5.5 + '@jridgewell/trace-mapping': 0.3.31 + + '@jridgewell/resolve-uri@3.1.2': {} + + '@jridgewell/source-map@0.3.11': + dependencies: + '@jridgewell/gen-mapping': 0.3.13 + '@jridgewell/trace-mapping': 0.3.31 + + '@jridgewell/sourcemap-codec@1.5.5': {} + + '@jridgewell/trace-mapping@0.3.31': + dependencies: + '@jridgewell/resolve-uri': 3.1.2 + '@jridgewell/sourcemap-codec': 1.5.5 + + '@mswjs/interceptors@0.39.8': + dependencies: + '@open-draft/deferred-promise': 2.2.0 + '@open-draft/logger': 0.3.0 + '@open-draft/until': 2.1.0 + is-node-process: 1.2.0 + outvariant: 1.4.3 + strict-event-emitter: 0.5.1 + + '@open-draft/deferred-promise@2.2.0': {} + + '@open-draft/logger@0.3.0': + dependencies: + is-node-process: 1.2.0 + outvariant: 1.4.3 + + '@open-draft/until@2.1.0': {} + + '@rollup/rollup-android-arm-eabi@4.53.3': + optional: true + + '@rollup/rollup-android-arm64@4.53.3': + optional: true + + '@rollup/rollup-darwin-arm64@4.53.3': + optional: true + + '@rollup/rollup-darwin-x64@4.53.3': + optional: true + + '@rollup/rollup-freebsd-arm64@4.53.3': + optional: true + + '@rollup/rollup-freebsd-x64@4.53.3': + optional: true + + '@rollup/rollup-linux-arm-gnueabihf@4.53.3': + optional: true + + '@rollup/rollup-linux-arm-musleabihf@4.53.3': + optional: true + + '@rollup/rollup-linux-arm64-gnu@4.53.3': + optional: true + + '@rollup/rollup-linux-arm64-musl@4.53.3': + optional: true + + '@rollup/rollup-linux-loong64-gnu@4.53.3': + optional: true + + '@rollup/rollup-linux-ppc64-gnu@4.53.3': + optional: true + + '@rollup/rollup-linux-riscv64-gnu@4.53.3': + optional: true + + '@rollup/rollup-linux-riscv64-musl@4.53.3': + optional: true + + '@rollup/rollup-linux-s390x-gnu@4.53.3': + optional: true + + '@rollup/rollup-linux-x64-gnu@4.53.3': + optional: true + + '@rollup/rollup-linux-x64-musl@4.53.3': + optional: true + + '@rollup/rollup-openharmony-arm64@4.53.3': + optional: true + + '@rollup/rollup-win32-arm64-msvc@4.53.3': + optional: true + + '@rollup/rollup-win32-ia32-msvc@4.53.3': + optional: true + + '@rollup/rollup-win32-x64-gnu@4.53.3': + optional: true + + '@rollup/rollup-win32-x64-msvc@4.53.3': + optional: true + + '@types/chai@5.2.3': + dependencies: + '@types/deep-eql': 4.0.2 + assertion-error: 2.0.1 + + '@types/cookie@0.6.0': {} + + '@types/deep-eql@4.0.2': {} + + '@types/eslint-scope@3.7.7': + dependencies: + '@types/eslint': 9.6.1 + '@types/estree': 1.0.8 + + '@types/eslint@9.6.1': + dependencies: + '@types/estree': 1.0.8 + '@types/json-schema': 7.0.15 + + '@types/estree@1.0.8': {} + + '@types/json-schema@7.0.15': {} + + '@types/node@18.19.130': + dependencies: + undici-types: 5.26.5 + + '@types/statuses@2.0.6': {} + + '@vitest/expect@3.2.4': + dependencies: + '@types/chai': 5.2.3 + '@vitest/spy': 3.2.4 + '@vitest/utils': 3.2.4 + chai: 5.3.3 + tinyrainbow: 2.0.0 + + '@vitest/mocker@3.2.4(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(vite@7.2.6(@types/node@18.19.130)(terser@5.44.1))': + dependencies: + '@vitest/spy': 3.2.4 + estree-walker: 3.0.3 + magic-string: 0.30.21 + optionalDependencies: + msw: 2.11.2(@types/node@18.19.130)(typescript@5.7.3) + vite: 7.2.6(@types/node@18.19.130)(terser@5.44.1) + + '@vitest/pretty-format@3.2.4': + dependencies: + tinyrainbow: 2.0.0 + + '@vitest/runner@3.2.4': + dependencies: + '@vitest/utils': 3.2.4 + pathe: 2.0.3 + strip-literal: 3.1.0 + + '@vitest/snapshot@3.2.4': + dependencies: + '@vitest/pretty-format': 3.2.4 + magic-string: 0.30.21 + pathe: 2.0.3 + + '@vitest/spy@3.2.4': + dependencies: + tinyspy: 4.0.4 + + '@vitest/utils@3.2.4': + dependencies: + '@vitest/pretty-format': 3.2.4 + loupe: 3.2.1 + tinyrainbow: 2.0.0 + + '@webassemblyjs/ast@1.14.1': + dependencies: + '@webassemblyjs/helper-numbers': 1.13.2 + '@webassemblyjs/helper-wasm-bytecode': 1.13.2 + + '@webassemblyjs/floating-point-hex-parser@1.13.2': {} + + '@webassemblyjs/helper-api-error@1.13.2': {} + + '@webassemblyjs/helper-buffer@1.14.1': {} + + '@webassemblyjs/helper-numbers@1.13.2': + dependencies: + '@webassemblyjs/floating-point-hex-parser': 1.13.2 + '@webassemblyjs/helper-api-error': 1.13.2 + '@xtuc/long': 4.2.2 + + '@webassemblyjs/helper-wasm-bytecode@1.13.2': {} + + '@webassemblyjs/helper-wasm-section@1.14.1': + dependencies: + '@webassemblyjs/ast': 1.14.1 + '@webassemblyjs/helper-buffer': 1.14.1 + '@webassemblyjs/helper-wasm-bytecode': 1.13.2 + '@webassemblyjs/wasm-gen': 1.14.1 + + '@webassemblyjs/ieee754@1.13.2': + dependencies: + '@xtuc/ieee754': 1.2.0 + + '@webassemblyjs/leb128@1.13.2': + dependencies: + '@xtuc/long': 4.2.2 + + '@webassemblyjs/utf8@1.13.2': {} + + '@webassemblyjs/wasm-edit@1.14.1': + dependencies: + '@webassemblyjs/ast': 1.14.1 + '@webassemblyjs/helper-buffer': 1.14.1 + '@webassemblyjs/helper-wasm-bytecode': 1.13.2 + '@webassemblyjs/helper-wasm-section': 1.14.1 + '@webassemblyjs/wasm-gen': 1.14.1 + '@webassemblyjs/wasm-opt': 1.14.1 + '@webassemblyjs/wasm-parser': 1.14.1 + '@webassemblyjs/wast-printer': 1.14.1 + + '@webassemblyjs/wasm-gen@1.14.1': + dependencies: + '@webassemblyjs/ast': 1.14.1 + '@webassemblyjs/helper-wasm-bytecode': 1.13.2 + '@webassemblyjs/ieee754': 1.13.2 + '@webassemblyjs/leb128': 1.13.2 + '@webassemblyjs/utf8': 1.13.2 + + '@webassemblyjs/wasm-opt@1.14.1': + dependencies: + '@webassemblyjs/ast': 1.14.1 + '@webassemblyjs/helper-buffer': 1.14.1 + '@webassemblyjs/wasm-gen': 1.14.1 + '@webassemblyjs/wasm-parser': 1.14.1 + + '@webassemblyjs/wasm-parser@1.14.1': + dependencies: + '@webassemblyjs/ast': 1.14.1 + '@webassemblyjs/helper-api-error': 1.13.2 + '@webassemblyjs/helper-wasm-bytecode': 1.13.2 + '@webassemblyjs/ieee754': 1.13.2 + '@webassemblyjs/leb128': 1.13.2 + '@webassemblyjs/utf8': 1.13.2 + + '@webassemblyjs/wast-printer@1.14.1': + dependencies: + '@webassemblyjs/ast': 1.14.1 + '@xtuc/long': 4.2.2 + + '@xtuc/ieee754@1.2.0': {} + + '@xtuc/long@4.2.2': {} + + acorn-import-phases@1.0.4(acorn@8.15.0): + dependencies: + acorn: 8.15.0 + + acorn@8.15.0: {} + + ajv-formats@2.1.1(ajv@8.17.1): + optionalDependencies: + ajv: 8.17.1 + + ajv-keywords@5.1.0(ajv@8.17.1): + dependencies: + ajv: 8.17.1 + fast-deep-equal: 3.1.3 + + ajv@8.17.1: + dependencies: + fast-deep-equal: 3.1.3 + fast-uri: 3.1.0 + json-schema-traverse: 1.0.0 + require-from-string: 2.0.2 + + ansi-regex@5.0.1: {} + + ansi-styles@4.3.0: + dependencies: + color-convert: 2.0.1 + + assertion-error@2.0.1: {} + + baseline-browser-mapping@2.8.32: {} + + braces@3.0.3: + dependencies: + fill-range: 7.1.1 + + browserslist@4.28.0: + dependencies: + baseline-browser-mapping: 2.8.32 + caniuse-lite: 1.0.30001757 + electron-to-chromium: 1.5.263 + node-releases: 2.0.27 + update-browserslist-db: 1.1.4(browserslist@4.28.0) + + buffer-from@1.1.2: {} + + cac@6.7.14: {} + + caniuse-lite@1.0.30001757: {} + + chai@5.3.3: + dependencies: + assertion-error: 2.0.1 + check-error: 2.1.1 + deep-eql: 5.0.2 + loupe: 3.2.1 + pathval: 2.0.1 + + chalk@4.1.2: + dependencies: + ansi-styles: 4.3.0 + supports-color: 7.2.0 + + check-error@2.1.1: {} + + chrome-trace-event@1.0.4: {} + + cli-width@4.1.0: {} + + cliui@8.0.1: + dependencies: + string-width: 4.2.3 + strip-ansi: 6.0.1 + wrap-ansi: 7.0.0 + + color-convert@2.0.1: + dependencies: + color-name: 1.1.4 + + color-name@1.1.4: {} + + commander@2.20.3: {} + + cookie@0.7.2: {} + + debug@4.4.3: + dependencies: + ms: 2.1.3 + + deep-eql@5.0.2: {} + + electron-to-chromium@1.5.263: {} + + emoji-regex@8.0.0: {} + + enhanced-resolve@5.18.3: + dependencies: + graceful-fs: 4.2.11 + tapable: 2.3.0 + + es-module-lexer@1.7.0: {} + + esbuild@0.25.12: + optionalDependencies: + '@esbuild/aix-ppc64': 0.25.12 + '@esbuild/android-arm': 0.25.12 + '@esbuild/android-arm64': 0.25.12 + '@esbuild/android-x64': 0.25.12 + '@esbuild/darwin-arm64': 0.25.12 + '@esbuild/darwin-x64': 0.25.12 + '@esbuild/freebsd-arm64': 0.25.12 + '@esbuild/freebsd-x64': 0.25.12 + '@esbuild/linux-arm': 0.25.12 + '@esbuild/linux-arm64': 0.25.12 + '@esbuild/linux-ia32': 0.25.12 + '@esbuild/linux-loong64': 0.25.12 + '@esbuild/linux-mips64el': 0.25.12 + '@esbuild/linux-ppc64': 0.25.12 + '@esbuild/linux-riscv64': 0.25.12 + '@esbuild/linux-s390x': 0.25.12 + '@esbuild/linux-x64': 0.25.12 + '@esbuild/netbsd-arm64': 0.25.12 + '@esbuild/netbsd-x64': 0.25.12 + '@esbuild/openbsd-arm64': 0.25.12 + '@esbuild/openbsd-x64': 0.25.12 + '@esbuild/openharmony-arm64': 0.25.12 + '@esbuild/sunos-x64': 0.25.12 + '@esbuild/win32-arm64': 0.25.12 + '@esbuild/win32-ia32': 0.25.12 + '@esbuild/win32-x64': 0.25.12 + + escalade@3.2.0: {} + + eslint-scope@5.1.1: + dependencies: + esrecurse: 4.3.0 + estraverse: 4.3.0 + + esrecurse@4.3.0: + dependencies: + estraverse: 5.3.0 + + estraverse@4.3.0: {} + + estraverse@5.3.0: {} + + estree-walker@3.0.3: + dependencies: + '@types/estree': 1.0.8 + + events@3.3.0: {} + + expect-type@1.2.2: {} + + fast-deep-equal@3.1.3: {} + + fast-uri@3.1.0: {} + + fdir@6.5.0(picomatch@4.0.3): + optionalDependencies: + picomatch: 4.0.3 + + fill-range@7.1.1: + dependencies: + to-regex-range: 5.0.1 + + fsevents@2.3.3: + optional: true + + get-caller-file@2.0.5: {} + + glob-to-regexp@0.4.1: {} + + graceful-fs@4.2.11: {} + + graphql@16.12.0: {} + + has-flag@4.0.0: {} + + headers-polyfill@4.0.3: {} + + is-fullwidth-code-point@3.0.0: {} + + is-node-process@1.2.0: {} + + is-number@7.0.0: {} + + jest-worker@27.5.1: + dependencies: + '@types/node': 18.19.130 + merge-stream: 2.0.0 + supports-color: 8.1.1 + + js-tokens@9.0.1: {} + + json-parse-even-better-errors@2.3.1: {} + + json-schema-traverse@1.0.0: {} + + loader-runner@4.3.1: {} + + loupe@3.2.1: {} + + magic-string@0.30.21: + dependencies: + '@jridgewell/sourcemap-codec': 1.5.5 + + merge-stream@2.0.0: {} + + micromatch@4.0.8: + dependencies: + braces: 3.0.3 + picomatch: 2.3.1 + + mime-db@1.52.0: {} + + mime-types@2.1.35: + dependencies: + mime-db: 1.52.0 + + ms@2.1.3: {} + + msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3): + dependencies: + '@bundled-es-modules/cookie': 2.0.1 + '@bundled-es-modules/statuses': 1.0.1 + '@inquirer/confirm': 5.1.21(@types/node@18.19.130) + '@mswjs/interceptors': 0.39.8 + '@open-draft/deferred-promise': 2.2.0 + '@open-draft/until': 2.1.0 + '@types/cookie': 0.6.0 + '@types/statuses': 2.0.6 + graphql: 16.12.0 + headers-polyfill: 4.0.3 + is-node-process: 1.2.0 + outvariant: 1.4.3 + path-to-regexp: 6.3.0 + picocolors: 1.1.1 + rettime: 0.7.0 + strict-event-emitter: 0.5.1 + tough-cookie: 6.0.0 + type-fest: 4.41.0 + yargs: 17.7.2 + optionalDependencies: + typescript: 5.7.3 + transitivePeerDependencies: + - '@types/node' + + mute-stream@2.0.0: {} + + nanoid@3.3.11: {} + + neo-async@2.6.2: {} + + node-releases@2.0.27: {} + + outvariant@1.4.3: {} + + path-to-regexp@6.3.0: {} + + pathe@2.0.3: {} + + pathval@2.0.1: {} + + picocolors@1.1.1: {} + + picomatch@2.3.1: {} + + picomatch@4.0.3: {} + + postcss@8.5.6: + dependencies: + nanoid: 3.3.11 + picocolors: 1.1.1 + source-map-js: 1.2.1 + + randombytes@2.1.0: + dependencies: + safe-buffer: 5.2.1 + + require-directory@2.1.1: {} + + require-from-string@2.0.2: {} + + rettime@0.7.0: {} + + rollup@4.53.3: + dependencies: + '@types/estree': 1.0.8 + optionalDependencies: + '@rollup/rollup-android-arm-eabi': 4.53.3 + '@rollup/rollup-android-arm64': 4.53.3 + '@rollup/rollup-darwin-arm64': 4.53.3 + '@rollup/rollup-darwin-x64': 4.53.3 + '@rollup/rollup-freebsd-arm64': 4.53.3 + '@rollup/rollup-freebsd-x64': 4.53.3 + '@rollup/rollup-linux-arm-gnueabihf': 4.53.3 + '@rollup/rollup-linux-arm-musleabihf': 4.53.3 + '@rollup/rollup-linux-arm64-gnu': 4.53.3 + '@rollup/rollup-linux-arm64-musl': 4.53.3 + '@rollup/rollup-linux-loong64-gnu': 4.53.3 + '@rollup/rollup-linux-ppc64-gnu': 4.53.3 + '@rollup/rollup-linux-riscv64-gnu': 4.53.3 + '@rollup/rollup-linux-riscv64-musl': 4.53.3 + '@rollup/rollup-linux-s390x-gnu': 4.53.3 + '@rollup/rollup-linux-x64-gnu': 4.53.3 + '@rollup/rollup-linux-x64-musl': 4.53.3 + '@rollup/rollup-openharmony-arm64': 4.53.3 + '@rollup/rollup-win32-arm64-msvc': 4.53.3 + '@rollup/rollup-win32-ia32-msvc': 4.53.3 + '@rollup/rollup-win32-x64-gnu': 4.53.3 + '@rollup/rollup-win32-x64-msvc': 4.53.3 + fsevents: 2.3.3 + + safe-buffer@5.2.1: {} + + schema-utils@4.3.3: + dependencies: + '@types/json-schema': 7.0.15 + ajv: 8.17.1 + ajv-formats: 2.1.1(ajv@8.17.1) + ajv-keywords: 5.1.0(ajv@8.17.1) + + semver@7.7.3: {} + + serialize-javascript@6.0.2: + dependencies: + randombytes: 2.1.0 + + siginfo@2.0.0: {} + + signal-exit@4.1.0: {} + + source-map-js@1.2.1: {} + + source-map-support@0.5.21: + dependencies: + buffer-from: 1.1.2 + source-map: 0.6.1 + + source-map@0.6.1: {} + + source-map@0.7.6: {} + + stackback@0.0.2: {} + + statuses@2.0.2: {} + + std-env@3.10.0: {} + + strict-event-emitter@0.5.1: {} + + string-width@4.2.3: + dependencies: + emoji-regex: 8.0.0 + is-fullwidth-code-point: 3.0.0 + strip-ansi: 6.0.1 + + strip-ansi@6.0.1: + dependencies: + ansi-regex: 5.0.1 + + strip-literal@3.1.0: + dependencies: + js-tokens: 9.0.1 + + supports-color@7.2.0: + dependencies: + has-flag: 4.0.0 + + supports-color@8.1.1: + dependencies: + has-flag: 4.0.0 + + tapable@2.3.0: {} + + terser-webpack-plugin@5.3.14(webpack@5.103.0): + dependencies: + '@jridgewell/trace-mapping': 0.3.31 + jest-worker: 27.5.1 + schema-utils: 4.3.3 + serialize-javascript: 6.0.2 + terser: 5.44.1 + webpack: 5.103.0 + + terser@5.44.1: + dependencies: + '@jridgewell/source-map': 0.3.11 + acorn: 8.15.0 + commander: 2.20.3 + source-map-support: 0.5.21 + + tinybench@2.9.0: {} + + tinyexec@0.3.2: {} + + tinyglobby@0.2.15: + dependencies: + fdir: 6.5.0(picomatch@4.0.3) + picomatch: 4.0.3 + + tinypool@1.1.1: {} + + tinyrainbow@2.0.0: {} + + tinyspy@4.0.4: {} + + tldts-core@7.0.19: {} + + tldts@7.0.19: + dependencies: + tldts-core: 7.0.19 + + to-regex-range@5.0.1: + dependencies: + is-number: 7.0.0 + + tough-cookie@6.0.0: + dependencies: + tldts: 7.0.19 + + ts-loader@9.5.4(typescript@5.7.3)(webpack@5.103.0): + dependencies: + chalk: 4.1.2 + enhanced-resolve: 5.18.3 + micromatch: 4.0.8 + semver: 7.7.3 + source-map: 0.7.6 + typescript: 5.7.3 + webpack: 5.103.0 + + type-fest@4.41.0: {} + + typescript@5.7.3: {} + + undici-types@5.26.5: {} + + update-browserslist-db@1.1.4(browserslist@4.28.0): + dependencies: + browserslist: 4.28.0 + escalade: 3.2.0 + picocolors: 1.1.1 + + vite-node@3.2.4(@types/node@18.19.130)(terser@5.44.1): + dependencies: + cac: 6.7.14 + debug: 4.4.3 + es-module-lexer: 1.7.0 + pathe: 2.0.3 + vite: 7.2.6(@types/node@18.19.130)(terser@5.44.1) + transitivePeerDependencies: + - '@types/node' + - jiti + - less + - lightningcss + - sass + - sass-embedded + - stylus + - sugarss + - supports-color + - terser + - tsx + - yaml + + vite@7.2.6(@types/node@18.19.130)(terser@5.44.1): + dependencies: + esbuild: 0.25.12 + fdir: 6.5.0(picomatch@4.0.3) + picomatch: 4.0.3 + postcss: 8.5.6 + rollup: 4.53.3 + tinyglobby: 0.2.15 + optionalDependencies: + '@types/node': 18.19.130 + fsevents: 2.3.3 + terser: 5.44.1 + + vitest@3.2.4(@types/node@18.19.130)(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(terser@5.44.1): + dependencies: + '@types/chai': 5.2.3 + '@vitest/expect': 3.2.4 + '@vitest/mocker': 3.2.4(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(vite@7.2.6(@types/node@18.19.130)(terser@5.44.1)) + '@vitest/pretty-format': 3.2.4 + '@vitest/runner': 3.2.4 + '@vitest/snapshot': 3.2.4 + '@vitest/spy': 3.2.4 + '@vitest/utils': 3.2.4 + chai: 5.3.3 + debug: 4.4.3 + expect-type: 1.2.2 + magic-string: 0.30.21 + pathe: 2.0.3 + picomatch: 4.0.3 + std-env: 3.10.0 + tinybench: 2.9.0 + tinyexec: 0.3.2 + tinyglobby: 0.2.15 + tinypool: 1.1.1 + tinyrainbow: 2.0.0 + vite: 7.2.6(@types/node@18.19.130)(terser@5.44.1) + vite-node: 3.2.4(@types/node@18.19.130)(terser@5.44.1) + why-is-node-running: 2.3.0 + optionalDependencies: + '@types/node': 18.19.130 + transitivePeerDependencies: + - jiti + - less + - lightningcss + - msw + - sass + - sass-embedded + - stylus + - sugarss + - supports-color + - terser + - tsx + - yaml + + watchpack@2.4.4: + dependencies: + glob-to-regexp: 0.4.1 + graceful-fs: 4.2.11 + + webpack-sources@3.3.3: {} + + webpack@5.103.0: + dependencies: + '@types/eslint-scope': 3.7.7 + '@types/estree': 1.0.8 + '@types/json-schema': 7.0.15 + '@webassemblyjs/ast': 1.14.1 + '@webassemblyjs/wasm-edit': 1.14.1 + '@webassemblyjs/wasm-parser': 1.14.1 + acorn: 8.15.0 + acorn-import-phases: 1.0.4(acorn@8.15.0) + browserslist: 4.28.0 + chrome-trace-event: 1.0.4 + enhanced-resolve: 5.18.3 + es-module-lexer: 1.7.0 + eslint-scope: 5.1.1 + events: 3.3.0 + glob-to-regexp: 0.4.1 + graceful-fs: 4.2.11 + json-parse-even-better-errors: 2.3.1 + loader-runner: 4.3.1 + mime-types: 2.1.35 + neo-async: 2.6.2 + schema-utils: 4.3.3 + tapable: 2.3.0 + terser-webpack-plugin: 5.3.14(webpack@5.103.0) + watchpack: 2.4.4 + webpack-sources: 3.3.3 + transitivePeerDependencies: + - '@swc/core' + - esbuild + - uglify-js + + why-is-node-running@2.3.0: + dependencies: + siginfo: 2.0.0 + stackback: 0.0.2 + + wrap-ansi@6.2.0: + dependencies: + ansi-styles: 4.3.0 + string-width: 4.2.3 + strip-ansi: 6.0.1 + + wrap-ansi@7.0.0: + dependencies: + ansi-styles: 4.3.0 + string-width: 4.2.3 + strip-ansi: 6.0.1 + + y18n@5.0.8: {} + + yargs-parser@21.1.1: {} + + yargs@17.7.2: + dependencies: + cliui: 8.0.1 + escalade: 3.2.0 + get-caller-file: 2.0.5 + require-directory: 2.1.1 + string-width: 4.2.3 + y18n: 5.0.8 + yargs-parser: 21.1.1 + + yoctocolors-cjs@2.1.3: {} diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml new file mode 100644 index 00000000..6e4c3951 --- /dev/null +++ b/pnpm-workspace.yaml @@ -0,0 +1 @@ +packages: ['.'] \ No newline at end of file diff --git a/reference.md b/reference.md index df65e9f7..5b2306ab 100644 --- a/reference.md +++ b/reference.md @@ -1,8 +1,6 @@ # Reference - ## Admins - -
client.admins.identify() -> Intercom.AdminWithApp +
client.admins.identify() -> Intercom.AdminWithApp | undefined
@@ -14,12 +12,12 @@
+ You can view the currently authorised admin along with the embedded app object (a "workspace" in legacy terminology). > 🚧 Single Sign On > > If you are building a custom "Log in with Intercom" flow for your site, and you call the `/me` endpoint to identify the logged-in user, you should not accept any sign-ins from users with unverified email addresses as it poses a potential impersonation security risk. -
@@ -35,8 +33,8 @@ You can view the currently authorised admin along with the embedded app object ( ```typescript await client.admins.identify(); -``` +```
@@ -50,18 +48,19 @@ await client.admins.identify();
-**requestOptions:** `Admins.RequestOptions` - +**requestOptions:** `AdminsClient.RequestOptions` +
+
-
client.admins.away({ ...params }) -> Intercom.Admin +
client.admins.away({ ...params }) -> Intercom.Admin | undefined
@@ -74,7 +73,6 @@ await client.admins.identify();
You can set an Admin as away for the Inbox. -
@@ -90,12 +88,13 @@ You can set an Admin as away for the Inbox. ```typescript await client.admins.away({ - admin_id: "admin_id", + admin_id: 1, away_mode_enabled: true, away_mode_reassign: true, + away_status_reason_id: 12345 }); -``` +``` @@ -109,21 +108,22 @@ await client.admins.away({
-**request:** `Intercom.ConfigureAwayAdminRequest` - +**request:** `Intercom.ConfigureAwayAdminRequest` +
-**requestOptions:** `Admins.RequestOptions` - +**requestOptions:** `AdminsClient.RequestOptions` +
+
@@ -141,7 +141,6 @@ await client.admins.away({
You can get a log of activities by all admins in an app. -
@@ -158,10 +157,10 @@ You can get a log of activities by all admins in an app. ```typescript await client.admins.listAllActivityLogs({ created_at_after: "1677253093", - created_at_before: "1677861493", + created_at_before: "1677861493" }); -``` +``` @@ -175,21 +174,22 @@ await client.admins.listAllActivityLogs({
-**request:** `Intercom.ListAllActivityLogsRequest` - +**request:** `Intercom.ListAllActivityLogsRequest` +
-**requestOptions:** `Admins.RequestOptions` - +**requestOptions:** `AdminsClient.RequestOptions` +
+
@@ -207,7 +207,6 @@ await client.admins.listAllActivityLogs({
You can fetch a list of admins for a given workspace. -
@@ -223,8 +222,8 @@ You can fetch a list of admins for a given workspace. ```typescript await client.admins.list(); -``` +``` @@ -238,18 +237,19 @@ await client.admins.list();
-**requestOptions:** `Admins.RequestOptions` - +**requestOptions:** `AdminsClient.RequestOptions` +
+
-
client.admins.find({ ...params }) -> Intercom.Admin +
client.admins.find({ ...params }) -> Intercom.Admin | undefined
@@ -262,7 +262,6 @@ await client.admins.list();
You can retrieve the details of a single admin. -
@@ -278,10 +277,10 @@ You can retrieve the details of a single admin. ```typescript await client.admins.find({ - admin_id: "123", + admin_id: 1 }); -``` +``` @@ -295,28 +294,28 @@ await client.admins.find({
-**request:** `Intercom.FindAdminRequest` - +**request:** `Intercom.FindAdminRequest` +
-**requestOptions:** `Admins.RequestOptions` - +**requestOptions:** `AdminsClient.RequestOptions` +
+
-## Articles - -
client.articles.list({ ...params }) -> core.Page +## AI Content +
client.aiContent.listContentImportSources() -> Intercom.ContentImportSourcesList
@@ -328,12 +327,7 @@ await client.admins.find({
-You can fetch a list of all articles by making a GET request to `https://api.intercom.io/articles`. - -> 📘 How are the articles sorted and ordered? -> -> Articles will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated articles first. - +You can retrieve a list of all content import sources for a workspace.
@@ -348,18 +342,9 @@ You can fetch a list of all articles by making a GET request to `https://api.int
```typescript -const response = await client.articles.list(); -for await (const item of response) { - console.log(item); -} +await client.aiContent.listContentImportSources(); -// Or you can manually iterate page-by-page -const page = await client.articles.list(); -while (page.hasNextPage()) { - page = page.getNextPage(); -} ``` -
@@ -373,26 +358,19 @@ while (page.hasNextPage()) {
-**request:** `Intercom.ListArticlesRequest` - -
-
- -
-
- -**requestOptions:** `Articles.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.articles.create({ ...params }) -> Intercom.Article +
client.aiContent.createContentImportSource({ ...params }) -> Intercom.ContentImportSource
@@ -404,8 +382,7 @@ while (page.hasNextPage()) {
-You can create a new article by making a POST request to `https://api.intercom.io/articles`. - +You can create a new content import source by sending a POST request to this endpoint.
@@ -420,27 +397,11 @@ You can create a new article by making a POST request to `https://api.intercom.i
```typescript -await client.articles.create({ - title: "Thanks for everything", - description: "Description of the Article", - body: "Body of the Article", - author_id: 991267407, - state: "published", - parent_id: 145, - parent_type: "collection", - translated_content: { - fr: { - type: "article_content", - title: "Merci pour tout", - description: "Description de l'article", - body: "Corps de l'article", - author_id: 991267407, - state: "published", - }, - }, +await client.aiContent.createContentImportSource({ + url: "https://www.example.com" }); -``` +```
@@ -454,44 +415,30 @@ await client.articles.create({
-**request:** `Intercom.CreateArticleRequest` - +**request:** `Intercom.CreateContentImportSourceRequest` +
-**requestOptions:** `Articles.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.articles.find({ ...params }) -> Intercom.Article -
-
- -#### 📝 Description - -
-
- +
client.aiContent.getContentImportSource({ ...params }) -> Intercom.ContentImportSource
-You can fetch the details of a single article by making a GET request to `https://api.intercom.io/articles/`. - -
-
-
-
- #### 🔌 Usage
@@ -501,11 +448,11 @@ You can fetch the details of a single article by making a GET request to `https:
```typescript -await client.articles.find({ - article_id: "123", +await client.aiContent.getContentImportSource({ + source_id: "source_id" }); -``` +```
@@ -519,26 +466,27 @@ await client.articles.find({
-**request:** `Intercom.FindArticleRequest` - +**request:** `Intercom.GetContentImportSourceRequest` +
-**requestOptions:** `Articles.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.articles.update({ ...params }) -> Intercom.Article +
client.aiContent.updateContentImportSource({ ...params }) -> Intercom.ContentImportSource
@@ -550,8 +498,7 @@ await client.articles.find({
-You can update the details of a single article by making a PUT request to `https://api.intercom.io/articles/`. - +You can update an existing content import source.
@@ -566,13 +513,13 @@ You can update the details of a single article by making a PUT request to `https
```typescript -await client.articles.update({ - article_id: "123", - title: "Christmas is here!", - body: "

New gifts in store for the jolly season

", +await client.aiContent.updateContentImportSource({ + source_id: "source_id", + sync_behavior: "api", + url: "https://www.example.com" }); -``` +```
@@ -586,26 +533,27 @@ await client.articles.update({
-**request:** `Intercom.UpdateArticleRequest` - +**request:** `Intercom.UpdateContentImportSourceRequest` +
-**requestOptions:** `Articles.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.articles.delete({ ...params }) -> Intercom.DeletedArticleObject +
client.aiContent.deleteContentImportSource({ ...params }) -> void
@@ -617,8 +565,7 @@ await client.articles.update({
-You can delete a single article by making a DELETE request to `https://api.intercom.io/articles/`. - +You can delete a content import source by making a DELETE request this endpoint. This will also delete all external pages that were imported from this source.
@@ -633,11 +580,11 @@ You can delete a single article by making a DELETE request to `https://api.inter
```typescript -await client.articles.delete({ - article_id: "123", +await client.aiContent.deleteContentImportSource({ + source_id: "source_id" }); -``` +```
@@ -651,26 +598,27 @@ await client.articles.delete({
-**request:** `Intercom.DeleteArticleRequest` - +**request:** `Intercom.DeleteContentImportSourceRequest` +
-**requestOptions:** `Articles.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.articles.search({ ...params }) -> Intercom.SearchArticlesResponse +
client.aiContent.listExternalPages() -> Intercom.ExternalPagesList
@@ -682,8 +630,7 @@ await client.articles.delete({
-You can search for articles by making a GET request to `https://api.intercom.io/articles/search`. - +You can retrieve a list of all external pages for a workspace.
@@ -698,12 +645,9 @@ You can search for articles by making a GET request to `https://api.intercom.io/
```typescript -await client.articles.search({ - phrase: "Getting started", - state: "published", -}); -``` +await client.aiContent.listExternalPages(); +```
@@ -717,28 +661,19 @@ await client.articles.search({
-**request:** `Intercom.SearchArticlesRequest` - -
-
- -
-
- -**requestOptions:** `Articles.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-## HelpCenters - -
client.helpCenters.find({ ...params }) -> Intercom.HelpCenter +
client.aiContent.createExternalPage({ ...params }) -> Intercom.ExternalPage
@@ -750,8 +685,7 @@ await client.articles.search({
-You can fetch the details of a single Help Center by making a GET request to `https://api.intercom.io/help_center/help_center/`. - +You can create a new external page by sending a POST request to this endpoint. If an external page already exists with the specified source_id and external_id, it will be updated instead.
@@ -766,11 +700,15 @@ You can fetch the details of a single Help Center by making a GET request to `ht
```typescript -await client.helpCenters.find({ - help_center_id: "123", +await client.aiContent.createExternalPage({ + title: "Test", + html: "

Test

", + url: "https://www.example.com", + source_id: 44, + external_id: "abc1234" }); -``` +```
@@ -784,26 +722,27 @@ await client.helpCenters.find({
-**request:** `Intercom.FindHelpCenterRequest` - +**request:** `Intercom.CreateExternalPageRequest` +
-**requestOptions:** `HelpCenters.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.helpCenters.list({ ...params }) -> core.Page +
client.aiContent.getExternalPage({ ...params }) -> Intercom.ExternalPage
@@ -815,8 +754,7 @@ await client.helpCenters.find({
-You can list all Help Centers by making a GET request to `https://api.intercom.io/help_center/help_centers`. - +You can retrieve an external page.
@@ -831,18 +769,11 @@ You can list all Help Centers by making a GET request to `https://api.intercom.i
```typescript -const response = await client.helpCenters.list(); -for await (const item of response) { - console.log(item); -} +await client.aiContent.getExternalPage({ + page_id: "page_id" +}); -// Or you can manually iterate page-by-page -const page = await client.helpCenters.list(); -while (page.hasNextPage()) { - page = page.getNextPage(); -} ``` -
@@ -856,28 +787,27 @@ while (page.hasNextPage()) {
-**request:** `Intercom.ListHelpCentersRequest` - +**request:** `Intercom.GetExternalPageRequest` +
-**requestOptions:** `HelpCenters.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-## Companies - -
client.companies.retrieve({ ...params }) -> Intercom.CompaniesRetrieveResponse +
client.aiContent.updateExternalPage({ ...params }) -> Intercom.ExternalPage
@@ -889,18 +819,7 @@ while (page.hasNextPage()) {
-You can fetch a single company by passing in `company_id` or `name`. - -`https://api.intercom.io/companies?name={name}` - -`https://api.intercom.io/companies?company_id={company_id}` - -You can fetch all companies and filter by `segment_id` or `tag_id` as a query parameter. - -`https://api.intercom.io/companies?tag_id={tag_id}` - -`https://api.intercom.io/companies?segment_id={segment_id}` - +You can update an existing external page (if it was created via the API).
@@ -915,14 +834,16 @@ You can fetch all companies and filter by `segment_id` or `tag_id` as a query pa
```typescript -await client.companies.retrieve({ - name: "my company", - company_id: "12345", - tag_id: "678910", - segment_id: "98765", +await client.aiContent.updateExternalPage({ + page_id: "page_id", + title: "Test", + html: "

Test

", + url: "https://www.example.com", + source_id: 47, + external_id: "5678" }); -``` +```
@@ -936,26 +857,27 @@ await client.companies.retrieve({
-**request:** `Intercom.RetrieveCompanyRequest` - +**request:** `Intercom.UpdateExternalPageRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.companies.createOrUpdate({ ...params }) -> Intercom.Company +
client.aiContent.deleteExternalPage({ ...params }) -> Intercom.ExternalPage
@@ -967,16 +889,7 @@ await client.companies.retrieve({
-You can create or update a company. - -Companies will be only visible in Intercom when there is at least one associated user. - -Companies are looked up via `company_id` in a `POST` request, if not found via `company_id`, the new company will be created, if found, that company will be updated. - -{% admonition type="warning" name="Using `company_id`" %} -You can set a unique `company_id` value when creating a company. However, it is not possible to update `company_id`. Be sure to set a unique value once upon creation of the company. -{% /admonition %} - +Sending a DELETE request for an external page will remove it from the content library UI and from being used for AI answers.
@@ -991,13 +904,11 @@ You can set a unique `company_id` value when creating a company. However, it is
```typescript -await client.companies.createOrUpdate({ - name: "my company", - company_id: "company_remote_id", - remote_created_at: 1374138000, +await client.aiContent.deleteExternalPage({ + page_id: "page_id" }); -``` +```
@@ -1011,26 +922,28 @@ await client.companies.createOrUpdate({
-**request:** `Intercom.CreateOrUpdateCompanyRequest` - +**request:** `Intercom.DeleteExternalPageRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.companies.find({ ...params }) -> Intercom.Company +## Articles +
client.articles.list({ ...params }) -> core.Page
@@ -1042,8 +955,11 @@ await client.companies.createOrUpdate({
-You can fetch a single company. +You can fetch a list of all articles by making a GET request to `https://api.intercom.io/articles`. +> 📘 How are the articles sorted and ordered? +> +> Articles will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated articles first.
@@ -1058,11 +974,21 @@ You can fetch a single company.
```typescript -await client.companies.find({ - company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", -}); -``` +const pageableResponse = await client.articles.list(); +for await (const item of pageableResponse) { + console.log(item); +} + +// Or you can manually iterate page-by-page +let page = await client.articles.list(); +while (page.hasNextPage()) { + page = page.getNextPage(); +} +// You can also access the underlying response +const response = page.response; + +```
@@ -1076,26 +1002,27 @@ await client.companies.find({
-**request:** `Intercom.FindCompanyRequest` - +**request:** `Intercom.ListArticlesRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ArticlesClient.RequestOptions` +
+
-
client.companies.update({ ...params }) -> Intercom.Company +
client.articles.create({ ...params }) -> Intercom.Article
@@ -1107,12 +1034,7 @@ await client.companies.find({
-You can update a single company using the Intercom provisioned `id`. - -{% admonition type="warning" name="Using `company_id`" %} -When updating a company it is not possible to update `company_id`. This can only be set once upon creation of the company. -{% /admonition %} - +You can create a new article by making a POST request to `https://api.intercom.io/articles`.
@@ -1127,15 +1049,30 @@ When updating a company it is not possible to update `company_id`. This can only
```typescript -await client.companies.update({ - company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", -}); -``` - -
-
- - +await client.articles.create({ + title: "Thanks for everything", + description: "Description of the Article", + body: "Body of the Article", + author_id: 991267497, + state: "published", + parent_id: 145, + parent_type: "collection", + translated_content: { + fr: { + title: "Merci pour tout", + description: "Description de l'article", + body: "Corps de l'article", + author_id: 991267497, + state: "published" + } + } +}); + +``` + + + + #### ⚙️ Parameters @@ -1145,26 +1082,27 @@ await client.companies.update({
-**request:** `Intercom.UpdateCompanyRequest` - +**request:** `Intercom.CreateArticleRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ArticlesClient.RequestOptions` +
+
-
client.companies.delete({ ...params }) -> Intercom.DeletedCompanyObject +
client.articles.find({ ...params }) -> Intercom.Article
@@ -1176,8 +1114,7 @@ await client.companies.update({
-You can delete a single company. - +You can fetch the details of a single article by making a GET request to `https://api.intercom.io/articles/`.
@@ -1192,11 +1129,11 @@ You can delete a single company.
```typescript -await client.companies.delete({ - company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +await client.articles.find({ + article_id: 1 }); -``` +```
@@ -1210,26 +1147,27 @@ await client.companies.delete({
-**request:** `Intercom.DeleteCompanyRequest` - +**request:** `Intercom.FindArticleRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ArticlesClient.RequestOptions` +
+
-
client.companies.listAttachedContacts({ ...params }) -> Intercom.CompanyAttachedContacts +
client.articles.update({ ...params }) -> Intercom.Article
@@ -1241,8 +1179,7 @@ await client.companies.delete({
-You can fetch a list of all contacts that belong to a company. - +You can update the details of a single article by making a PUT request to `https://api.intercom.io/articles/`.
@@ -1257,11 +1194,13 @@ You can fetch a list of all contacts that belong to a company.
```typescript -await client.companies.listAttachedContacts({ - company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +await client.articles.update({ + article_id: 1, + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

" }); -``` +```
@@ -1275,26 +1214,27 @@ await client.companies.listAttachedContacts({
-**request:** `Intercom.ListAttachedContactsRequest` - +**request:** `Intercom.UpdateArticleRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ArticlesClient.RequestOptions` +
+
-
client.companies.listAttachedSegments({ ...params }) -> Intercom.CompanyAttachedSegments +
client.articles.delete({ ...params }) -> Intercom.DeletedArticleObject
@@ -1306,8 +1246,7 @@ await client.companies.listAttachedContacts({
-You can fetch a list of all segments that belong to a company. - +You can delete a single article by making a DELETE request to `https://api.intercom.io/articles/`.
@@ -1322,11 +1261,11 @@ You can fetch a list of all segments that belong to a company.
```typescript -await client.companies.listAttachedSegments({ - company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +await client.articles.delete({ + article_id: 1 }); -``` +```
@@ -1340,26 +1279,27 @@ await client.companies.listAttachedSegments({
-**request:** `Intercom.ListSegmentsAttachedToCompanyRequest` - +**request:** `Intercom.DeleteArticleRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ArticlesClient.RequestOptions` +
+
-
client.companies.list({ ...params }) -> core.Page +
client.articles.search({ ...params }) -> Intercom.ArticleSearchResponse
@@ -1371,16 +1311,7 @@ await client.companies.listAttachedSegments({
-You can list companies. The company list is sorted by the `last_request_at` field and by default is ordered descending, most recently requested first. - -Note that the API does not include companies who have no associated users in list responses. - -When using the Companies endpoint and the pages object to iterate through the returned companies, there is a limit of 10,000 Companies that can be returned. If you need to list or iterate on more than 10,000 Companies, please use the [Scroll API](https://developers.intercom.com/reference#iterating-over-all-companies). -{% admonition type="warning" name="Pagination" %} -You can use pagination to limit the number of results returned. The default is `20` results per page. -See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. -{% /admonition %} - +You can search for articles by making a GET request to `https://api.intercom.io/articles/search`.
@@ -1395,22 +1326,14 @@ See the [pagination section](https://developers.intercom.com/docs/build-an-integ
```typescript -const response = await client.companies.list({ - order: "desc", +await client.articles.search({ + phrase: "Getting started", + state: "published", + help_center_id: 1, + highlight: true }); -for await (const item of response) { - console.log(item); -} -// Or you can manually iterate page-by-page -const page = await client.companies.list({ - order: "desc", -}); -while (page.hasNextPage()) { - page = page.getNextPage(); -} ``` -
@@ -1424,26 +1347,28 @@ while (page.hasNextPage()) {
-**request:** `Intercom.ListCompaniesRequest` - +**request:** `Intercom.SearchArticlesRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ArticlesClient.RequestOptions` +
+
-
client.companies.scroll({ ...params }) -> core.Page +## Away Status Reasons +
client.awayStatusReasons.listAwayStatusReasons() -> Intercom.AwayStatusReason[]
@@ -1455,22 +1380,7 @@ while (page.hasNextPage()) {
- The `list all companies` functionality does not work well for huge datasets, and can result in errors and performance problems when paging deeply. The Scroll API provides an efficient mechanism for iterating over all companies in a dataset. - -- Each app can only have 1 scroll open at a time. You'll get an error message if you try to have more than one open per app. -- If the scroll isn't used for 1 minute, it expires and calls with that scroll param will fail -- If the end of the scroll is reached, "companies" will be empty and the scroll parameter will expire - -{% admonition type="info" name="Scroll Parameter" %} -You can get the first page of companies by simply sending a GET request to the scroll endpoint. -For subsequent requests you will need to use the scroll parameter from the response. -{% /admonition %} -{% admonition type="danger" name="Scroll network timeouts" %} -Since scroll is often used on large datasets network errors such as timeouts can be encountered. When this occurs you will see a HTTP 500 error with the following message: -"Request failed due to an internal network error. Please restart the scroll operation." -If this happens, you will need to restart your scroll query: It is not possible to continue from a specific point when using scroll. -{% /admonition %} - +Returns a list of all away status reasons configured for the workspace, including deleted ones.
@@ -1485,18 +1395,9 @@ If this happens, you will need to restart your scroll query: It is not possible
```typescript -const response = await client.companies.scroll(); -for await (const item of response) { - console.log(item); -} +await client.awayStatusReasons.listAwayStatusReasons(); -// Or you can manually iterate page-by-page -const page = await client.companies.scroll(); -while (page.hasNextPage()) { - page = page.getNextPage(); -} ``` -
@@ -1510,44 +1411,23 @@ while (page.hasNextPage()) {
-**request:** `Intercom.ScrollCompaniesRequest` - -
-
- -
-
- -**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `AwayStatusReasonsClient.RequestOptions` +
+
-
client.companies.attachContact({ ...params }) -> Intercom.Company -
-
- -#### 📝 Description - +## Export +
client.export.enqueueANewReportingDataExportJob({ ...params }) -> Intercom.PostExportReportingDataEnqueueResponse
-
-
- -You can attach a company to a single contact. - -
-
-
-
- #### 🔌 Usage
@@ -1557,12 +1437,14 @@ You can attach a company to a single contact.
```typescript -await client.companies.attachContact({ - contact_id: "contact_id", - id: "667d608d8a68186f43bafd70", +await client.export.enqueueANewReportingDataExportJob({ + dataset_id: "conversation", + attribute_ids: ["conversation_id", "conversation_started_at"], + start_time: 1717490000, + end_time: 1717510000 }); -``` +```
@@ -1576,30 +1458,31 @@ await client.companies.attachContact({
-**request:** `Intercom.AttachContactToCompanyRequest` - +**request:** `Intercom.PostExportReportingDataEnqueueRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ExportClient.RequestOptions` +
+
-
client.companies.detachContact({ ...params }) -> Intercom.Company +
client.export.listAvailableDatasetsAndAttributes() -> Intercom.GetExportReportingDataGetDatasetsResponse
-#### 📝 Description +#### 🔌 Usage
@@ -1607,12 +1490,39 @@ await client.companies.attachContact({
-You can detach a company from a single contact. +```typescript +await client.export.listAvailableDatasetsAndAttributes(); +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `ExportClient.RequestOptions` + +
+
+ +
+
+ +## Data Export +
client.dataExport.exportReportingData({ ...params }) -> Intercom.DataExportExportReportingDataResponse +
+
#### 🔌 Usage @@ -1623,12 +1533,13 @@ You can detach a company from a single contact.
```typescript -await client.companies.detachContact({ - contact_id: "58a430d35458202d41b1e65b", - company_id: "58a430d35458202d41b1e65b", +await client.dataExport.exportReportingData({ + job_identifier: "job_identifier", + app_id: "app_id", + client_id: "client_id" }); -``` +```
@@ -1642,28 +1553,27 @@ await client.companies.detachContact({
-**request:** `Intercom.DetachContactFromCompanyRequest` - +**request:** `Intercom.ExportReportingDataRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `DataExportClient.RequestOptions` +
+
-## Contacts - -
client.contacts.listAttachedCompanies({ ...params }) -> core.Page +
client.dataExport.downloadReportingDataExport({ ...params }) -> void
@@ -1675,8 +1585,11 @@ await client.companies.detachContact({
-You can fetch a list of companies that are associated to a contact. +Download the data from a completed reporting data export job. +> Octet header required +> +> You will have to specify the header Accept: `application/octet-stream` when hitting this endpoint.
@@ -1691,22 +1604,12 @@ You can fetch a list of companies that are associated to a contact.
```typescript -const response = await client.contacts.listAttachedCompanies({ - contact_id: "63a07ddf05a32042dffac965", +await client.dataExport.downloadReportingDataExport({ + job_identifier: "job_identifier", + app_id: "app_id" }); -for await (const item of response) { - console.log(item); -} -// Or you can manually iterate page-by-page -const page = await client.contacts.listAttachedCompanies({ - contact_id: "63a07ddf05a32042dffac965", -}); -while (page.hasNextPage()) { - page = page.getNextPage(); -} ``` -
@@ -1720,26 +1623,27 @@ while (page.hasNextPage()) {
-**request:** `Intercom.ListAttachedCompaniesRequest` - +**request:** `Intercom.DownloadReportingDataExportRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `DataExportClient.RequestOptions` +
+
-
client.contacts.listAttachedSegments({ ...params }) -> Intercom.ContactSegments +
client.dataExport.create({ ...params }) -> Intercom.DataExport
@@ -1751,8 +1655,21 @@ while (page.hasNextPage()) {
-You can fetch a list of segments that are associated to a contact. +To create your export job, you need to send a `POST` request to the export endpoint `https://api.intercom.io/export/content/data`. + +The only parameters you need to provide are the range of dates that you want exported. +>🚧 Limit of one active job +> +> You can only have one active job per workspace. You will receive a HTTP status code of 429 with the message Exceeded rate limit of 1 pending message data export jobs if you attempt to create a second concurrent job. + +>❗️ Updated_at not included +> +> It should be noted that the timeframe only includes messages sent during the time period and not messages that were only updated during this period. For example, if a message was updated yesterday but sent two days ago, you would need to set the created_at_after date before the message was sent to include that in your retrieval job. + +>📘 Date ranges are inclusive +> +> Requesting data for 2018-06-01 until 2018-06-30 will get all data for those days including those specified - e.g. 2018-06-01 00:00:00 until 2018-06-30 23:59:99.
@@ -1767,11 +1684,12 @@ You can fetch a list of segments that are associated to a contact.
```typescript -await client.contacts.listAttachedSegments({ - contact_id: "63a07ddf05a32042dffac965", +await client.dataExport.create({ + created_at_after: 1734519776, + created_at_before: 1734537776 }); -``` +```
@@ -1785,26 +1703,27 @@ await client.contacts.listAttachedSegments({
-**request:** `Intercom.ListSegmentsAttachedToContactRequest` - +**request:** `Intercom.CreateDataExportRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `DataExportClient.RequestOptions` +
+
-
client.contacts.listAttachedSubscriptions({ ...params }) -> Intercom.SubscriptionTypeList +
client.dataExport.find({ ...params }) -> Intercom.DataExport
@@ -1816,14 +1735,11 @@ await client.contacts.listAttachedSegments({
-You can fetch a list of subscription types that are attached to a contact. These can be subscriptions that a user has 'opted-in' to or has 'opted-out' from, depending on the subscription type. -This will return a list of Subscription Type objects that the contact is associated with. - -The data property will show a combined list of: - -1.Opt-out subscription types that the user has opted-out from. -2.Opt-in subscription types that the user has opted-in to receiving. +You can view the status of your job by sending a `GET` request to the URL +`https://api.intercom.io/export/content/data/{job_identifier}` - the `{job_identifier}` is the value returned in the response when you first created the export job. More on it can be seen in the Export Job Model. +> 🚧 Jobs expire after two days +> All jobs that have completed processing (and are thus available to download from the provided URL) will have an expiry limit of two days from when the export ob completed. After this, the data will no longer be available.
@@ -1838,11 +1754,11 @@ The data property will show a combined list of:
```typescript -await client.contacts.listAttachedSubscriptions({ - contact_id: "63a07ddf05a32042dffac965", +await client.dataExport.find({ + job_identifier: "job_identifier" }); -``` +```
@@ -1856,26 +1772,27 @@ await client.contacts.listAttachedSubscriptions({
-**request:** `Intercom.ListAttachedSubscriptionsRequest` - +**request:** `Intercom.FindDataExportRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `DataExportClient.RequestOptions` +
+
-
client.contacts.attachSubscription({ ...params }) -> Intercom.SubscriptionType +
client.dataExport.cancel({ ...params }) -> Intercom.DataExport
@@ -1887,14 +1804,7 @@ await client.contacts.listAttachedSubscriptions({
-You can add a specific subscription to a contact. In Intercom, we have two different subscription types based on user consent - opt-out and opt-in: - -1.Attaching a contact to an opt-out subscription type will opt that user out from receiving messages related to that subscription type. - -2.Attaching a contact to an opt-in subscription type will opt that user in to receiving messages related to that subscription type. - -This will return a subscription type model for the subscription type that was added to the contact. - +You can cancel your job
@@ -1909,13 +1819,11 @@ This will return a subscription type model for the subscription type that was ad
```typescript -await client.contacts.attachSubscription({ - contact_id: "63a07ddf05a32042dffac965", - id: "37846", - consent_type: "opt_in", +await client.dataExport.cancel({ + job_identifier: "job_identifier" }); -``` +```
@@ -1929,26 +1837,27 @@ await client.contacts.attachSubscription({
-**request:** `Intercom.AttachSubscriptionToContactRequest` - +**request:** `Intercom.CancelDataExportRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `DataExportClient.RequestOptions` +
+
-
client.contacts.detachSubscription({ ...params }) -> Intercom.SubscriptionType +
client.dataExport.download({ ...params }) -> void
@@ -1960,8 +1869,13 @@ await client.contacts.attachSubscription({
-You can remove a specific subscription from a contact. This will return a subscription type model for the subscription type that was removed from the contact. +When a job has a status of complete, and thus a filled download_url, you can download your data by hitting that provided URL, formatted like so: https://api.intercom.io/download/content/data/xyz1234. + +Your exported message data will be streamed continuously back down to you in a gzipped CSV format. +> 📘 Octet header required +> +> You will have to specify the header Accept: `application/octet-stream` when hitting this endpoint.
@@ -1976,12 +1890,11 @@ You can remove a specific subscription from a contact. This will return a subscr
```typescript -await client.contacts.detachSubscription({ - contact_id: "63a07ddf05a32042dffac965", - subscription_id: "37846", +await client.dataExport.download({ + job_identifier: "job_identifier" }); -``` +```
@@ -1995,26 +1908,28 @@ await client.contacts.detachSubscription({
-**request:** `Intercom.DetachSubscriptionFromContactRequest` - +**request:** `Intercom.DownloadDataExportRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `DataExportClient.RequestOptions` +
+
-
client.contacts.listAttachedTags({ ...params }) -> Intercom.TagList +## HelpCenters +
client.helpCenters.find({ ...params }) -> Intercom.HelpCenter
@@ -2026,8 +1941,7 @@ await client.contacts.detachSubscription({
-You can fetch a list of all tags that are attached to a specific contact. - +You can fetch the details of a single Help Center by making a GET request to `https://api.intercom.io/help_center/help_center/`.
@@ -2042,11 +1956,11 @@ You can fetch a list of all tags that are attached to a specific contact.
```typescript -await client.contacts.listAttachedTags({ - contact_id: "63a07ddf05a32042dffac965", +await client.helpCenters.find({ + help_center_id: 1 }); -``` +```
@@ -2060,26 +1974,27 @@ await client.contacts.listAttachedTags({
-**request:** `Intercom.ListTagsAttachedToContactRequest` - +**request:** `Intercom.FindHelpCenterRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `HelpCentersClient.RequestOptions` +
+
-
client.contacts.find({ ...params }) -> Intercom.Contact +
client.helpCenters.list({ ...params }) -> core.Page
@@ -2091,8 +2006,7 @@ await client.contacts.listAttachedTags({
-You can fetch the details of a single contact. - +You can list all Help Centers by making a GET request to `https://api.intercom.io/help_center/help_centers`.
@@ -2107,11 +2021,21 @@ You can fetch the details of a single contact.
```typescript -await client.contacts.find({ - contact_id: "63a07ddf05a32042dffac965", -}); -``` +const pageableResponse = await client.helpCenters.list(); +for await (const item of pageableResponse) { + console.log(item); +} + +// Or you can manually iterate page-by-page +let page = await client.helpCenters.list(); +while (page.hasNextPage()) { + page = page.getNextPage(); +} + +// You can also access the underlying response +const response = page.response; +```
@@ -2125,26 +2049,28 @@ await client.contacts.find({
-**request:** `Intercom.FindContactRequest` - +**request:** `Intercom.ListHelpCentersRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `HelpCentersClient.RequestOptions` +
+
-
client.contacts.update({ ...params }) -> Intercom.Contact +## Internal Articles +
client.internalArticles.listInternalArticles() -> Intercom.InternalArticleList
@@ -2156,8 +2082,7 @@ await client.contacts.find({
-You can update an existing contact (ie. user or lead). - +You can fetch a list of all internal articles by making a GET request to `https://api.intercom.io/internal_articles`.
@@ -2172,13 +2097,9 @@ You can update an existing contact (ie. user or lead).
```typescript -await client.contacts.update({ - contact_id: "63a07ddf05a32042dffac965", - email: "joebloggs@intercom.io", - name: "joe bloggs", -}); -``` +await client.internalArticles.listInternalArticles(); +```
@@ -2192,26 +2113,19 @@ await client.contacts.update({
-**request:** `Intercom.UpdateContactRequest` - -
-
- -
-
- -**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `InternalArticlesClient.RequestOptions` +
+
-
client.contacts.delete({ ...params }) -> Intercom.ContactDeleted +
client.internalArticles.createInternalArticle({ ...params }) -> Intercom.InternalArticle
@@ -2223,8 +2137,7 @@ await client.contacts.update({
-You can delete a single contact. - +You can create a new internal article by making a POST request to `https://api.intercom.io/internal_articles`.
@@ -2239,11 +2152,14 @@ You can delete a single contact.
```typescript -await client.contacts.delete({ - contact_id: "contact_id", +await client.internalArticles.createInternalArticle({ + title: "Thanks for everything", + body: "Body of the Article", + author_id: 991266252, + owner_id: 991266252 }); -``` +```
@@ -2257,26 +2173,27 @@ await client.contacts.delete({
-**request:** `Intercom.DeleteContactRequest` - +**request:** `Intercom.CreateInternalArticleRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `InternalArticlesClient.RequestOptions` +
+
-
client.contacts.mergeLeadInUser({ ...params }) -> Intercom.Contact +
client.internalArticles.retrieveInternalArticle({ ...params }) -> Intercom.InternalArticle
@@ -2288,8 +2205,7 @@ await client.contacts.delete({
-You can merge a contact with a `role` of `lead` into a contact with a `role` of `user`. - +You can fetch the details of a single internal article by making a GET request to `https://api.intercom.io/internal_articles/`.
@@ -2304,12 +2220,11 @@ You can merge a contact with a `role` of `lead` into a contact with a `role` of
```typescript -await client.contacts.mergeLeadInUser({ - from: "667d60ac8a68186f43bafdbb", - into: "667d60ac8a68186f43bafdbc", +await client.internalArticles.retrieveInternalArticle({ + internal_article_id: 1 }); -``` +```
@@ -2323,26 +2238,27 @@ await client.contacts.mergeLeadInUser({
-**request:** `Intercom.MergeContactsRequest` - +**request:** `Intercom.RetrieveInternalArticleRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `InternalArticlesClient.RequestOptions` +
+
-
client.contacts.search({ ...params }) -> core.Page +
client.internalArticles.updateInternalArticle({ ...params }) -> Intercom.InternalArticle
@@ -2354,108 +2270,7 @@ await client.contacts.mergeLeadInUser({
-You can search for multiple contacts by the value of their attributes in order to fetch exactly who you want. - -To search for contacts, you need to send a `POST` request to `https://api.intercom.io/contacts/search`. - -This will accept a query object in the body which will define your filters in order to search for contacts. - -{% admonition type="warning" name="Optimizing search queries" %} -Search queries can be complex, so optimizing them can help the performance of your search. -Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize -pagination to limit the number of results returned. The default is `50` results per page. -See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. -{% /admonition %} - -### Contact Creation Delay - -If a contact has recently been created, there is a possibility that it will not yet be available when searching. This means that it may not appear in the response. This delay can take a few minutes. If you need to be instantly notified it is recommended to use webhooks and iterate to see if they match your search filters. - -### Nesting & Limitations - -You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). -There are some limitations to the amount of multiple's there can be: - -- There's a limit of max 2 nested filters -- There's a limit of max 15 filters for each AND or OR group - -### Searching for Timestamp Fields - -All timestamp fields (created_at, updated_at etc.) are indexed as Dates for Contact Search queries; Datetime queries are not currently supported. This means you can only query for timestamp fields by day - not hour, minute or second. -For example, if you search for all Contacts with a created_at value greater (>) than 1577869200 (the UNIX timestamp for January 1st, 2020 9:00 AM), that will be interpreted as 1577836800 (January 1st, 2020 12:00 AM). The search results will then include Contacts created from January 2nd, 2020 12:00 AM onwards. -If you'd like to get contacts created on January 1st, 2020 you should search with a created_at value equal (=) to 1577836800 (January 1st, 2020 12:00 AM). -This behaviour applies only to timestamps used in search queries. The search results will still contain the full UNIX timestamp and be sorted accordingly. - -### Accepted Fields - -Most key listed as part of the Contacts Model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). - -| Field | Type | -| ---------------------------------- | ------------------------------ | -| id | String | -| role | String
Accepts user or lead | -| name | String | -| avatar | String | -| owner_id | Integer | -| email | String | -| email_domain | String | -| phone | String | -| external_id | String | -| created_at | Date (UNIX Timestamp) | -| signed_up_at | Date (UNIX Timestamp) | -| updated_at | Date (UNIX Timestamp) | -| last_seen_at | Date (UNIX Timestamp) | -| last_contacted_at | Date (UNIX Timestamp) | -| last_replied_at | Date (UNIX Timestamp) | -| last_email_opened_at | Date (UNIX Timestamp) | -| last_email_clicked_at | Date (UNIX Timestamp) | -| language_override | String | -| browser | String | -| browser_language | String | -| os | String | -| location.country | String | -| location.region | String | -| location.city | String | -| unsubscribed_from_emails | Boolean | -| marked_email_as_spam | Boolean | -| has_hard_bounced | Boolean | -| ios_last_seen_at | Date (UNIX Timestamp) | -| ios_app_version | String | -| ios_device | String | -| ios_app_device | String | -| ios_os_version | String | -| ios_app_name | String | -| ios_sdk_version | String | -| android_last_seen_at | Date (UNIX Timestamp) | -| android_app_version | String | -| android_device | String | -| android_app_name | String | -| andoid_sdk_version | String | -| segment_id | String | -| tag_id | String | -| custom_attributes.{attribute_name} | String | - -### Accepted Operators - -{% admonition type="warning" name="Searching based on `created_at`" %} -You cannot use the `<=` or `>=` operators to search by `created_at`. -{% /admonition %} - -The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). - -| Operator | Valid Types | Description | -| :------- | :------------------------------- | :--------------------------------------------------------------- | -| = | All | Equals | -| != | All | Doesn't Equal | -| IN | All | In
Shortcut for `OR` queries
Values must be in Array | -| NIN | All | Not In
Shortcut for `OR !` queries
Values must be in Array | -| > | Integer
Date (UNIX Timestamp) | Greater than | -| < | Integer
Date (UNIX Timestamp) | Lower than | -| ~ | String | Contains | -| !~ | String | Doesn't Contain | -| ^ | String | Starts With | -| $ | String | Ends With | - +You can update the details of a single internal article by making a PUT request to `https://api.intercom.io/internal_articles/`.
@@ -2470,46 +2285,13 @@ The table below shows the operators you can use to define how you want to search
```typescript -const response = await client.contacts.search({ - query: { - operator: "AND", - value: [ - { - field: "created_at", - operator: ">", - value: "1306054154", - }, - ], - }, - pagination: { - per_page: 5, - }, +await client.internalArticles.updateInternalArticle({ + internal_article_id: 1, + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

" }); -for await (const item of response) { - console.log(item); -} -// Or you can manually iterate page-by-page -const page = await client.contacts.search({ - query: { - operator: "AND", - value: [ - { - field: "created_at", - operator: ">", - value: "1306054154", - }, - ], - }, - pagination: { - per_page: 5, - }, -}); -while (page.hasNextPage()) { - page = page.getNextPage(); -} ``` -
@@ -2523,26 +2305,27 @@ while (page.hasNextPage()) {
-**request:** `Intercom.SearchRequest` - +**request:** `Intercom.UpdateInternalArticleRequestBody` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `InternalArticlesClient.RequestOptions` +
+
-
client.contacts.list({ ...params }) -> core.Page +
client.internalArticles.deleteInternalArticle({ ...params }) -> Intercom.DeletedInternalArticleObject
@@ -2554,12 +2337,7 @@ while (page.hasNextPage()) {
-You can fetch a list of all contacts (ie. users or leads) in your workspace. -{% admonition type="warning" name="Pagination" %} -You can use pagination to limit the number of results returned. The default is `50` results per page. -See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. -{% /admonition %} - +You can delete a single internal article by making a DELETE request to `https://api.intercom.io/internal_articles/`.
@@ -2574,18 +2352,11 @@ See the [pagination section](https://developers.intercom.com/docs/build-an-integ
```typescript -const response = await client.contacts.list(); -for await (const item of response) { - console.log(item); -} +await client.internalArticles.deleteInternalArticle({ + internal_article_id: 1 +}); -// Or you can manually iterate page-by-page -const page = await client.contacts.list(); -while (page.hasNextPage()) { - page = page.getNextPage(); -} ``` -
@@ -2599,26 +2370,27 @@ while (page.hasNextPage()) {
-**request:** `Intercom.ListContactsRequest` - +**request:** `Intercom.DeleteInternalArticleRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `InternalArticlesClient.RequestOptions` +
+
-
client.contacts.create({ ...params }) -> Intercom.Contact +
client.internalArticles.searchInternalArticles({ ...params }) -> Intercom.InternalArticleSearchResponse
@@ -2630,8 +2402,7 @@ while (page.hasNextPage()) {
-You can create a new contact (ie. user or lead). - +You can search for internal articles by making a GET request to `https://api.intercom.io/internal_articles/search`.
@@ -2646,11 +2417,11 @@ You can create a new contact (ie. user or lead).
```typescript -await client.contacts.create({ - email: "joebloggs@intercom.io", +await client.internalArticles.searchInternalArticles({ + folder_id: "folder_id" }); -``` +```
@@ -2664,26 +2435,28 @@ await client.contacts.create({
-**request:** `Intercom.CreateContactRequest` - +**request:** `Intercom.SearchInternalArticlesRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `InternalArticlesClient.RequestOptions` +
+
-
client.contacts.archive({ ...params }) -> Intercom.ContactArchived +## Companies +
client.companies.retrieve({ ...params }) -> Intercom.CompaniesRetrieveResponse
@@ -2695,8 +2468,17 @@ await client.contacts.create({
-You can archive a single contact. +You can fetch a single company by passing in `company_id` or `name`. + + `https://api.intercom.io/companies?name={name}` + + `https://api.intercom.io/companies?company_id={company_id}` + +You can fetch all companies and filter by `segment_id` or `tag_id` as a query parameter. + + `https://api.intercom.io/companies?tag_id={tag_id}` + `https://api.intercom.io/companies?segment_id={segment_id}`
@@ -2711,11 +2493,16 @@ You can archive a single contact.
```typescript -await client.contacts.archive({ - contact_id: "63a07ddf05a32042dffac965", +await client.companies.retrieve({ + name: "my company", + company_id: "12345", + tag_id: "678910", + segment_id: "98765", + page: 1, + per_page: 1 }); -``` +```
@@ -2729,26 +2516,27 @@ await client.contacts.archive({
-**request:** `Intercom.ArchiveContactRequest` - +**request:** `Intercom.RetrieveCompanyRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.contacts.unarchive({ ...params }) -> Intercom.ContactUnarchived +
client.companies.createOrUpdate({ ...params }) -> Intercom.Company
@@ -2760,8 +2548,15 @@ await client.contacts.archive({
-You can unarchive a single contact. +You can create or update a company. +Companies will be only visible in Intercom when there is at least one associated user. + +Companies are looked up via `company_id` in a `POST` request, if not found via `company_id`, the new company will be created, if found, that company will be updated. + +{% admonition type="warning" name="Using `company_id`" %} + You can set a unique `company_id` value when creating a company. However, it is not possible to update `company_id`. Be sure to set a unique value once upon creation of the company. +{% /admonition %}
@@ -2776,11 +2571,13 @@ You can unarchive a single contact.
```typescript -await client.contacts.unarchive({ - contact_id: "63a07ddf05a32042dffac965", +await client.companies.createOrUpdate({ + name: "my company", + company_id: "company_remote_id", + remote_created_at: 1374138000 }); -``` +```
@@ -2794,28 +2591,27 @@ await client.contacts.unarchive({
-**request:** `Intercom.UnarchiveContactRequest` - +**request:** `Intercom.CreateOrUpdateCompanyRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-## Notes - -
client.notes.list({ ...params }) -> core.Page +
client.companies.find({ ...params }) -> Intercom.Company
@@ -2827,8 +2623,7 @@ await client.contacts.unarchive({
-You can fetch a list of notes that are associated to a contact. - +You can fetch a single company.
@@ -2843,22 +2638,11 @@ You can fetch a list of notes that are associated to a contact.
```typescript -const response = await client.notes.list({ - contact_id: "contact_id", +await client.companies.find({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" }); -for await (const item of response) { - console.log(item); -} -// Or you can manually iterate page-by-page -const page = await client.notes.list({ - contact_id: "contact_id", -}); -while (page.hasNextPage()) { - page = page.getNextPage(); -} ``` -
@@ -2872,26 +2656,27 @@ while (page.hasNextPage()) {
-**request:** `Intercom.ListContactNotesRequest` - +**request:** `Intercom.FindCompanyRequest` +
-**requestOptions:** `Notes.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.notes.create({ ...params }) -> Intercom.Note +
client.companies.update({ ...params }) -> Intercom.Company
@@ -2903,8 +2688,11 @@ while (page.hasNextPage()) {
-You can add a note to a single contact. +You can update a single company using the Intercom provisioned `id`. +{% admonition type="warning" name="Using `company_id`" %} + When updating a company it is not possible to update `company_id`. This can only be set once upon creation of the company. +{% /admonition %}
@@ -2919,13 +2707,15 @@ You can add a note to a single contact.
```typescript -await client.notes.create({ - contact_id: "123", - body: "Hello", - admin_id: "123", +await client.companies.update({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + body: { + name: "my company", + website: "http://www.mycompany.com/" + } }); -``` +```
@@ -2939,26 +2729,27 @@ await client.notes.create({
-**request:** `Intercom.CreateContactNoteRequest` - +**request:** `Intercom.UpdateCompanyRequest` +
-**requestOptions:** `Notes.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.notes.find({ ...params }) -> Intercom.Note +
client.companies.delete({ ...params }) -> Intercom.DeletedCompanyObject
@@ -2970,8 +2761,7 @@ await client.notes.create({
-You can fetch the details of a single note. - +You can delete a single company.
@@ -2986,11 +2776,11 @@ You can fetch the details of a single note.
```typescript -await client.notes.find({ - note_id: "1", +await client.companies.delete({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" }); -``` +```
@@ -3004,28 +2794,27 @@ await client.notes.find({
-**request:** `Intercom.FindNoteRequest` - +**request:** `Intercom.DeleteCompanyRequest` +
-**requestOptions:** `Notes.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-## Tags - -
client.tags.tagContact({ ...params }) -> Intercom.Tag +
client.companies.listAttachedContacts({ ...params }) -> Intercom.CompanyAttachedContacts
@@ -3037,8 +2826,7 @@ await client.notes.find({
-You can tag a specific contact. This will return a tag object for the tag that was added to the contact. - +You can fetch a list of all contacts that belong to a company.
@@ -3053,12 +2841,11 @@ You can tag a specific contact. This will return a tag object for the tag that w
```typescript -await client.tags.tagContact({ - contact_id: "63a07ddf05a32042dffac965", - id: "7522907", +await client.companies.listAttachedContacts({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" }); -``` +```
@@ -3072,26 +2859,27 @@ await client.tags.tagContact({
-**request:** `Intercom.TagContactRequest` - +**request:** `Intercom.ListAttachedContactsRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.tags.untagContact({ ...params }) -> Intercom.Tag +
client.companies.listAttachedSegments({ ...params }) -> Intercom.CompanyAttachedSegments
@@ -3103,8 +2891,7 @@ await client.tags.tagContact({
-You can remove tag from a specific contact. This will return a tag object for the tag that was removed from the contact. - +You can fetch a list of all segments that belong to a company.
@@ -3119,12 +2906,11 @@ You can remove tag from a specific contact. This will return a tag object for th
```typescript -await client.tags.untagContact({ - contact_id: "63a07ddf05a32042dffac965", - tag_id: "7522907", +await client.companies.listAttachedSegments({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" }); -``` +```
@@ -3138,26 +2924,27 @@ await client.tags.untagContact({
-**request:** `Intercom.UntagContactRequest` - +**request:** `Intercom.ListSegmentsAttachedToCompanyRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.tags.tagConversation({ ...params }) -> Intercom.Tag +
client.companies.list({ ...params }) -> core.Page
@@ -3169,8 +2956,15 @@ await client.tags.untagContact({
-You can tag a specific conversation. This will return a tag object for the tag that was added to the conversation. +You can list companies. The company list is sorted by the `last_request_at` field and by default is ordered descending, most recently requested first. + +Note that the API does not include companies who have no associated users in list responses. +When using the Companies endpoint and the pages object to iterate through the returned companies, there is a limit of 10,000 Companies that can be returned. If you need to list or iterate on more than 10,000 Companies, please use the [Scroll API](https://developers.intercom.com/reference#iterating-over-all-companies). +{% admonition type="warning" name="Pagination" %} + You can use pagination to limit the number of results returned. The default is `20` results per page. + See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. +{% /admonition %}
@@ -3185,13 +2979,29 @@ You can tag a specific conversation. This will return a tag object for the tag t
```typescript -await client.tags.tagConversation({ - conversation_id: "64619700005694", - id: "7522907", - admin_id: "780", +const pageableResponse = await client.companies.list({ + page: 1, + per_page: 1, + order: "desc" }); -``` +for await (const item of pageableResponse) { + console.log(item); +} + +// Or you can manually iterate page-by-page +let page = await client.companies.list({ + page: 1, + per_page: 1, + order: "desc" +}); +while (page.hasNextPage()) { + page = page.getNextPage(); +} + +// You can also access the underlying response +const response = page.response; +```
@@ -3205,26 +3015,27 @@ await client.tags.tagConversation({
-**request:** `Intercom.TagConversationRequest` - +**request:** `Intercom.ListCompaniesRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.tags.untagConversation({ ...params }) -> Intercom.Tag +
client.companies.scroll({ ...params }) -> core.Page
@@ -3236,8 +3047,21 @@ await client.tags.tagConversation({
-You can remove tag from a specific conversation. This will return a tag object for the tag that was removed from the conversation. + The `list all companies` functionality does not work well for huge datasets, and can result in errors and performance problems when paging deeply. The Scroll API provides an efficient mechanism for iterating over all companies in a dataset. + +- Each app can only have 1 scroll open at a time. You'll get an error message if you try to have more than one open per app. +- If the scroll isn't used for 1 minute, it expires and calls with that scroll param will fail +- If the end of the scroll is reached, "companies" will be empty and the scroll parameter will expire +{% admonition type="info" name="Scroll Parameter" %} + You can get the first page of companies by simply sending a GET request to the scroll endpoint. + For subsequent requests you will need to use the scroll parameter from the response. +{% /admonition %} +{% admonition type="danger" name="Scroll network timeouts" %} + Since scroll is often used on large datasets network errors such as timeouts can be encountered. When this occurs you will see a HTTP 500 error with the following message: + "Request failed due to an internal network error. Please restart the scroll operation." + If this happens, you will need to restart your scroll query: It is not possible to continue from a specific point when using scroll. +{% /admonition %}
@@ -3252,13 +3076,25 @@ You can remove tag from a specific conversation. This will return a tag object f
```typescript -await client.tags.untagConversation({ - conversation_id: "64619700005694", - tag_id: "7522907", - admin_id: "123", +const pageableResponse = await client.companies.scroll({ + scroll_param: "scroll_param" }); -``` +for await (const item of pageableResponse) { + console.log(item); +} + +// Or you can manually iterate page-by-page +let page = await client.companies.scroll({ + scroll_param: "scroll_param" +}); +while (page.hasNextPage()) { + page = page.getNextPage(); +} + +// You can also access the underlying response +const response = page.response; +```
@@ -3272,26 +3108,27 @@ await client.tags.untagConversation({
-**request:** `Intercom.UntagConversationRequest` - +**request:** `Intercom.ScrollCompaniesRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.tags.list() -> Intercom.TagList +
client.companies.attachContact({ ...params }) -> Intercom.Company
@@ -3303,8 +3140,7 @@ await client.tags.untagConversation({
-You can fetch a list of all tags for a given workspace. - +You can attach a company to a single contact.
@@ -3319,9 +3155,12 @@ You can fetch a list of all tags for a given workspace.
```typescript -await client.tags.list(); -``` +await client.companies.attachContact({ + contact_id: "contact_id", + id: "6762f09a1bb69f9f2193bb34" +}); +```
@@ -3335,18 +3174,27 @@ await client.tags.list();
-**requestOptions:** `Tags.RequestOptions` +**request:** `Intercom.AttachContactToCompanyRequest` + +
+
+ +
+
+**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.tags.create({ ...params }) -> Intercom.Tag +
client.companies.detachContact({ ...params }) -> Intercom.Company
@@ -3358,20 +3206,7 @@ await client.tags.list();
-You can use this endpoint to perform the following operations: - -**1. Create a new tag:** You can create a new tag by passing in the tag name as specified in "Create or Update Tag Request Payload" described below. - -**2. Update an existing tag:** You can update an existing tag by passing the id of the tag as specified in "Create or Update Tag Request Payload" described below. - -**3. Tag Companies:** You can tag single company or a list of companies. You can tag a company by passing in the tag name and the company details as specified in "Tag Company Request Payload" described below. Also, if the tag doesn't exist then a new one will be created automatically. - -**4. Untag Companies:** You can untag a single company or a list of companies. You can untag a company by passing in the tag id and the company details as specified in "Untag Company Request Payload" described below. - -**5. Tag Multiple Users:** You can tag a list of users. You can tag the users by passing in the tag name and the user details as specified in "Tag Users Request Payload" described below. - -Each operation will return a tag object. - +You can detach a company from a single contact.
@@ -3386,11 +3221,12 @@ Each operation will return a tag object.
```typescript -await client.tags.create({ - name: "test", +await client.companies.detachContact({ + contact_id: "58a430d35458202d41b1e65b", + company_id: "58a430d35458202d41b1e65b" }); -``` +```
@@ -3404,26 +3240,28 @@ await client.tags.create({
-**request:** `Intercom.TagsCreateRequestBody` - +**request:** `Intercom.DetachContactFromCompanyRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.tags.find({ ...params }) -> Intercom.Tag +## Contacts +
client.contacts.listAttachedCompanies({ ...params }) -> core.Page
@@ -3435,9 +3273,7 @@ await client.tags.create({
-You can fetch the details of tags that are on the workspace by their id. -This will return a tag object. - +You can fetch a list of companies that are associated to a contact.
@@ -3452,11 +3288,29 @@ This will return a tag object.
```typescript -await client.tags.find({ - tag_id: "123", +const pageableResponse = await client.contacts.listAttachedCompanies({ + contact_id: "63a07ddf05a32042dffac965", + page: 1, + per_page: 1 }); -``` +for await (const item of pageableResponse) { + console.log(item); +} + +// Or you can manually iterate page-by-page +let page = await client.contacts.listAttachedCompanies({ + contact_id: "63a07ddf05a32042dffac965", + page: 1, + per_page: 1 +}); +while (page.hasNextPage()) { + page = page.getNextPage(); +} + +// You can also access the underlying response +const response = page.response; +```
@@ -3470,26 +3324,27 @@ await client.tags.find({
-**request:** `Intercom.FindTagRequest` - +**request:** `Intercom.ListAttachedCompaniesRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.tags.delete({ ...params }) -> void +
client.contacts.listAttachedSegments({ ...params }) -> Intercom.ContactSegments
@@ -3501,8 +3356,7 @@ await client.tags.find({
-You can delete the details of tags that are on the workspace by passing in the id. - +You can fetch a list of segments that are associated to a contact.
@@ -3517,11 +3371,11 @@ You can delete the details of tags that are on the workspace by passing in the i
```typescript -await client.tags.delete({ - tag_id: "123", +await client.contacts.listAttachedSegments({ + contact_id: "63a07ddf05a32042dffac965" }); -``` +```
@@ -3535,26 +3389,27 @@ await client.tags.delete({
-**request:** `Intercom.DeleteTagRequest` - +**request:** `Intercom.ListSegmentsAttachedToContactRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.tags.tagTicket({ ...params }) -> Intercom.Tag +
client.contacts.listAttachedSubscriptions({ ...params }) -> Intercom.SubscriptionTypeList
@@ -3566,8 +3421,13 @@ await client.tags.delete({
-You can tag a specific ticket. This will return a tag object for the tag that was added to the ticket. +You can fetch a list of subscription types that are attached to a contact. These can be subscriptions that a user has 'opted-in' to or has 'opted-out' from, depending on the subscription type. +This will return a list of Subscription Type objects that the contact is associated with. + +The data property will show a combined list of: + 1.Opt-out subscription types that the user has opted-out from. + 2.Opt-in subscription types that the user has opted-in to receiving.
@@ -3582,13 +3442,11 @@ You can tag a specific ticket. This will return a tag object for the tag that wa
```typescript -await client.tags.tagTicket({ - ticket_id: "64619700005694", - id: "7522907", - admin_id: "780", +await client.contacts.listAttachedSubscriptions({ + contact_id: "63a07ddf05a32042dffac965" }); -``` +```
@@ -3602,26 +3460,27 @@ await client.tags.tagTicket({
-**request:** `Intercom.TagTicketRequest` - +**request:** `Intercom.ListAttachedSubscriptionsRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.tags.untagTicket({ ...params }) -> Intercom.Tag +
client.contacts.attachSubscription({ ...params }) -> Intercom.SubscriptionType
@@ -3633,8 +3492,13 @@ await client.tags.tagTicket({
-You can remove tag from a specific ticket. This will return a tag object for the tag that was removed from the ticket. +You can add a specific subscription to a contact. In Intercom, we have two different subscription types based on user consent - opt-out and opt-in: + 1.Attaching a contact to an opt-out subscription type will opt that user out from receiving messages related to that subscription type. + + 2.Attaching a contact to an opt-in subscription type will opt that user in to receiving messages related to that subscription type. + +This will return a subscription type model for the subscription type that was added to the contact.
@@ -3649,13 +3513,13 @@ You can remove tag from a specific ticket. This will return a tag object for the
```typescript -await client.tags.untagTicket({ - ticket_id: "64619700005694", - tag_id: "7522907", - admin_id: "123", +await client.contacts.attachSubscription({ + contact_id: "63a07ddf05a32042dffac965", + id: "37846", + consent_type: "opt_in" }); -``` +```
@@ -3669,28 +3533,27 @@ await client.tags.untagTicket({
-**request:** `Intercom.UntagTicketRequest` - +**request:** `Intercom.AttachSubscriptionToContactRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-## Conversations - -
client.conversations.list({ ...params }) -> core.Page +
client.contacts.detachSubscription({ ...params }) -> Intercom.SubscriptionType
@@ -3702,14 +3565,73 @@ await client.tags.untagTicket({
-You can fetch a list of all conversations. +You can remove a specific subscription from a contact. This will return a subscription type model for the subscription type that was removed from the contact. +
+
+
+
-You can optionally request the result page size and the cursor to start after to fetch the result. -{% admonition type="warning" name="Pagination" %} -You can use pagination to limit the number of results returned. The default is `20` results per page. -See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. -{% /admonition %} +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.detachSubscription({ + contact_id: "63a07ddf05a32042dffac965", + subscription_id: "37846" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.DetachSubscriptionFromContactRequest` + +
+
+ +
+
+ +**requestOptions:** `ContactsClient.RequestOptions` + +
+
+
+
+ + + + +
+ +
client.contacts.listAttachedTags({ ...params }) -> Intercom.TagList +
+
+ +#### 📝 Description + +
+
+ +
+
+You can fetch a list of all tags that are attached to a specific contact.
@@ -3724,18 +3646,11 @@ See the [pagination section](https://developers.intercom.com/docs/build-an-integ
```typescript -const response = await client.conversations.list(); -for await (const item of response) { - console.log(item); -} +await client.contacts.listAttachedTags({ + contact_id: "63a07ddf05a32042dffac965" +}); -// Or you can manually iterate page-by-page -const page = await client.conversations.list(); -while (page.hasNextPage()) { - page = page.getNextPage(); -} ``` -
@@ -3749,26 +3664,92 @@ while (page.hasNextPage()) {
-**request:** `Intercom.ListConversationsRequest` +**request:** `Intercom.ListTagsAttachedToContactRequest` + +
+
+ +
+
+ +**requestOptions:** `ContactsClient.RequestOptions` + +
+
+ +
+ + + + +
+ +
client.contacts.find({ ...params }) -> Intercom.ContactsFindResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single contact. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.find({ + contact_id: "63a07ddf05a32042dffac965" +}); +``` +
+
+#### ⚙️ Parameters + +
+
+
-**requestOptions:** `Conversations.RequestOptions` +**request:** `Intercom.FindContactRequest` + +
+
+ +
+
+**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.conversations.create({ ...params }) -> Intercom.Message +
client.contacts.update({ ...params }) -> Intercom.ContactsUpdateResponse
@@ -3780,16 +3761,80 @@ while (page.hasNextPage()) {
-You can create a conversation that has been initiated by a contact (ie. user or lead). -The conversation can be an in-app message only. +You can update an existing contact (ie. user or lead). -{% admonition type="info" name="Sending for visitors" %} -You can also send a message from a visitor by specifying their `user_id` or `id` value in the `from` field, along with a `type` field value of `contact`. -This visitor will be automatically converted to a contact with a lead role once the conversation is created. +{% admonition type="info" %} + This endpoint handles both **contact updates** and **custom object associations**. + + See _`update a contact with an association to a custom object instance`_ in the request/response examples to see the custom object association format. {% /admonition %} +
+
+
+
-This will return the Message model that has been created. +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.update({ + contact_id: "63a07ddf05a32042dffac965", + email: "joebloggs@intercom.io", + name: "joe bloggs" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UpdateContactRequest` + +
+
+ +
+
+ +**requestOptions:** `ContactsClient.RequestOptions` + +
+
+
+
+ + + + +
+ +
client.contacts.delete({ ...params }) -> Intercom.ContactDeleted +
+
+ +#### 📝 Description + +
+
+ +
+
+You can delete a single contact.
@@ -3804,15 +3849,11 @@ This will return the Message model that has been created.
```typescript -await client.conversations.create({ - from: { - type: "user", - id: "667d60d18a68186f43bafddd", - }, - body: "Hello there", +await client.contacts.delete({ + contact_id: "contact_id" }); -``` +```
@@ -3826,26 +3867,4299 @@ await client.conversations.create({
-**request:** `Intercom.CreateConversationRequest` +**request:** `Intercom.DeleteContactRequest` + +
+
+ +
+
+ +**requestOptions:** `ContactsClient.RequestOptions` + +
+
+ +
+ + + + +
+ +
client.contacts.mergeLeadInUser({ ...params }) -> Intercom.ContactsMergeLeadInUserResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+You can merge a contact with a `role` of `lead` into a contact with a `role` of `user`. +
+
+#### 🔌 Usage + +
+
+
-**requestOptions:** `Conversations.RequestOptions` +```typescript +await client.contacts.mergeLeadInUser({ + from: "6762f0d51bb69f9f2193bb7f", + into: "6762f0d51bb69f9f2193bb80" +}); +```
+#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.MergeContactsRequest` + +
+
+ +
+
+ +**requestOptions:** `ContactsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.contacts.search({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can search for multiple contacts by the value of their attributes in order to fetch exactly who you want. + +To search for contacts, you need to send a `POST` request to `https://api.intercom.io/contacts/search`. + +This will accept a query object in the body which will define your filters in order to search for contacts. + +{% admonition type="warning" name="Optimizing search queries" %} + Search queries can be complex, so optimizing them can help the performance of your search. + Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize + pagination to limit the number of results returned. The default is `50` results per page. + See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. +{% /admonition %} +### Contact Creation Delay + +If a contact has recently been created, there is a possibility that it will not yet be available when searching. This means that it may not appear in the response. This delay can take a few minutes. If you need to be instantly notified it is recommended to use webhooks and iterate to see if they match your search filters. + +### Nesting & Limitations + +You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). +There are some limitations to the amount of multiple's there can be: +* There's a limit of max 2 nested filters +* There's a limit of max 15 filters for each AND or OR group + +### Searching for Timestamp Fields + +All timestamp fields (created_at, updated_at etc.) are indexed as Dates for Contact Search queries; Datetime queries are not currently supported. This means you can only query for timestamp fields by day - not hour, minute or second. +For example, if you search for all Contacts with a created_at value greater (>) than 1577869200 (the UNIX timestamp for January 1st, 2020 9:00 AM), that will be interpreted as 1577836800 (January 1st, 2020 12:00 AM). The search results will then include Contacts created from January 2nd, 2020 12:00 AM onwards. +If you'd like to get contacts created on January 1st, 2020 you should search with a created_at value equal (=) to 1577836800 (January 1st, 2020 12:00 AM). +This behaviour applies only to timestamps used in search queries. The search results will still contain the full UNIX timestamp and be sorted accordingly. + +### Accepted Fields + +Most key listed as part of the Contacts Model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). + +| Field | Type | +| ---------------------------------- | ------------------------------ | +| id | String | +| role | String
Accepts user or lead | +| name | String | +| avatar | String | +| owner_id | Integer | +| email | String | +| email_domain | String | +| phone | String | +| external_id | String | +| created_at | Date (UNIX Timestamp) | +| signed_up_at | Date (UNIX Timestamp) | +| updated_at | Date (UNIX Timestamp) | +| last_seen_at | Date (UNIX Timestamp) | +| last_contacted_at | Date (UNIX Timestamp) | +| last_replied_at | Date (UNIX Timestamp) | +| last_email_opened_at | Date (UNIX Timestamp) | +| last_email_clicked_at | Date (UNIX Timestamp) | +| language_override | String | +| browser | String | +| browser_language | String | +| os | String | +| location.country | String | +| location.region | String | +| location.city | String | +| unsubscribed_from_emails | Boolean | +| marked_email_as_spam | Boolean | +| has_hard_bounced | Boolean | +| ios_last_seen_at | Date (UNIX Timestamp) | +| ios_app_version | String | +| ios_device | String | +| ios_app_device | String | +| ios_os_version | String | +| ios_app_name | String | +| ios_sdk_version | String | +| android_last_seen_at | Date (UNIX Timestamp) | +| android_app_version | String | +| android_device | String | +| android_app_name | String | +| andoid_sdk_version | String | +| segment_id | String | +| tag_id | String | +| custom_attributes.{attribute_name} | String | + +### Accepted Operators + +{% admonition type="warning" name="Searching based on `created_at`" %} + You cannot use the `<=` or `>=` operators to search by `created_at`. +{% /admonition %} + +The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + +| Operator | Valid Types | Description | +| :------- | :------------------------------- | :--------------------------------------------------------------- | +| = | All | Equals | +| != | All | Doesn't Equal | +| IN | All | In
Shortcut for `OR` queries
Values must be in Array | +| NIN | All | Not In
Shortcut for `OR !` queries
Values must be in Array | +| > | Integer
Date (UNIX Timestamp) | Greater than | +| < | Integer
Date (UNIX Timestamp) | Lower than | +| ~ | String | Contains | +| !~ | String | Doesn't Contain | +| ^ | String | Starts With | +| $ | String | Ends With | +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const pageableResponse = await client.contacts.search({ + query: { + operator: "AND", + value: [{ + field: "created_at", + operator: ">", + value: "1306054154" + }] + }, + pagination: { + per_page: 5 + } +}); +for await (const item of pageableResponse) { + console.log(item); +} + +// Or you can manually iterate page-by-page +let page = await client.contacts.search({ + query: { + operator: "AND", + value: [{ + field: "created_at", + operator: ">", + value: "1306054154" + }] + }, + pagination: { + per_page: 5 + } +}); +while (page.hasNextPage()) { + page = page.getNextPage(); +} + +// You can also access the underlying response +const response = page.response; + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.SearchRequest` + +
+
+ +
+
+ +**requestOptions:** `ContactsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.contacts.list({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all contacts (ie. users or leads) in your workspace. +{% admonition type="warning" name="Pagination" %} + You can use pagination to limit the number of results returned. The default is `50` results per page. + See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. +{% /admonition %} +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const pageableResponse = await client.contacts.list(); +for await (const item of pageableResponse) { + console.log(item); +} + +// Or you can manually iterate page-by-page +let page = await client.contacts.list(); +while (page.hasNextPage()) { + page = page.getNextPage(); +} + +// You can also access the underlying response +const response = page.response; + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListContactsRequest` + +
+
+ +
+
+ +**requestOptions:** `ContactsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.contacts.create({ ...params }) -> Intercom.ContactsCreateResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a new contact (ie. user or lead). +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.create({ + email: "joebloggs@intercom.io" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateContactRequest` + +
+
+ +
+
+ +**requestOptions:** `ContactsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.contacts.showContactByExternalId({ ...params }) -> Intercom.ShowContactByExternalIdResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single contact by external ID. Note that this endpoint only supports users and not leads. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.showContactByExternalId({ + external_id: "cdd29344-5e0c-4ef0-ac56-f9ba2979bc27" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ShowContactByExternalIdRequest` + +
+
+ +
+
+ +**requestOptions:** `ContactsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.contacts.archive({ ...params }) -> Intercom.ContactArchived +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can archive a single contact. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.archive({ + contact_id: "63a07ddf05a32042dffac965" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ArchiveContactRequest` + +
+
+ +
+
+ +**requestOptions:** `ContactsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.contacts.unarchive({ ...params }) -> Intercom.ContactUnarchived +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can unarchive a single contact. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.unarchive({ + contact_id: "63a07ddf05a32042dffac965" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UnarchiveContactRequest` + +
+
+ +
+
+ +**requestOptions:** `ContactsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.contacts.blockContact({ ...params }) -> Intercom.ContactBlocked +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Block a single contact.
**Note:** conversations of the contact will also be archived during the process.
More details in [FAQ How do I block Inbox spam?](https://www.intercom.com/help/en/articles/8838656-inbox-faqs) +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.contacts.blockContact({ + contact_id: "63a07ddf05a32042dffac965" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.BlockContactRequest` + +
+
+ +
+
+ +**requestOptions:** `ContactsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +## Notes +
client.notes.list({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of notes that are associated to a contact. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const pageableResponse = await client.notes.list({ + contact_id: "contact_id" +}); +for await (const item of pageableResponse) { + console.log(item); +} + +// Or you can manually iterate page-by-page +let page = await client.notes.list({ + contact_id: "contact_id" +}); +while (page.hasNextPage()) { + page = page.getNextPage(); +} + +// You can also access the underlying response +const response = page.response; + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListContactNotesRequest` + +
+
+ +
+
+ +**requestOptions:** `NotesClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.notes.create({ ...params }) -> Intercom.Note +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can add a note to a single contact. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.notes.create({ + contact_id: "123", + body: "Hello", + admin_id: "123" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateContactNoteRequest` + +
+
+ +
+
+ +**requestOptions:** `NotesClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.notes.find({ ...params }) -> Intercom.Note +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single note. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.notes.find({ + note_id: 1 +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindNoteRequest` + +
+
+ +
+
+ +**requestOptions:** `NotesClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +## Tags +
client.tags.tagContact({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can tag a specific contact. This will return a tag object for the tag that was added to the contact. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.tagContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "7522907" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.TagContactRequest` + +
+
+ +
+
+ +**requestOptions:** `TagsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.tags.untagContact({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can remove tag from a specific contact. This will return a tag object for the tag that was removed from the contact. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.untagContact({ + contact_id: "63a07ddf05a32042dffac965", + tag_id: "7522907" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UntagContactRequest` + +
+
+ +
+
+ +**requestOptions:** `TagsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.tags.tagConversation({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can tag a specific conversation. This will return a tag object for the tag that was added to the conversation. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.tagConversation({ + conversation_id: "64619700005694", + id: "7522907", + admin_id: "780" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.TagConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `TagsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.tags.untagConversation({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can remove tag from a specific conversation. This will return a tag object for the tag that was removed from the conversation. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.untagConversation({ + conversation_id: "64619700005694", + tag_id: "7522907", + admin_id: "123" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UntagConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `TagsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.tags.list() -> Intercom.TagList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all tags for a given workspace. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.list(); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `TagsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.tags.create({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can use this endpoint to perform the following operations: + + **1. Create a new tag:** You can create a new tag by passing in the tag name as specified in "Create or Update Tag Request Payload" described below. + + **2. Update an existing tag:** You can update an existing tag by passing the id of the tag as specified in "Create or Update Tag Request Payload" described below. + + **3. Tag Companies:** You can tag single company or a list of companies. You can tag a company by passing in the tag name and the company details as specified in "Tag Company Request Payload" described below. Also, if the tag doesn't exist then a new one will be created automatically. + + **4. Untag Companies:** You can untag a single company or a list of companies. You can untag a company by passing in the tag id and the company details as specified in "Untag Company Request Payload" described below. + + **5. Tag Multiple Users:** You can tag a list of users. You can tag the users by passing in the tag name and the user details as specified in "Tag Users Request Payload" described below. + +Each operation will return a tag object. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.create({ + name: "test" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.TagsCreateRequestBody` + +
+
+ +
+
+ +**requestOptions:** `TagsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.tags.find({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of tags that are on the workspace by their id. +This will return a tag object. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.find({ + tag_id: "123" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindTagRequest` + +
+
+ +
+
+ +**requestOptions:** `TagsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.tags.delete({ ...params }) -> void +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete the details of tags that are on the workspace by passing in the id. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.delete({ + tag_id: "123" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.DeleteTagRequest` + +
+
+ +
+
+ +**requestOptions:** `TagsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.tags.tagTicket({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can tag a specific ticket. This will return a tag object for the tag that was added to the ticket. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.tagTicket({ + ticket_id: "64619700005694", + id: "7522907", + admin_id: "780" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.TagTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `TagsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.tags.untagTicket({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can remove tag from a specific ticket. This will return a tag object for the tag that was removed from the ticket. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.tags.untagTicket({ + ticket_id: "64619700005694", + tag_id: "7522907", + admin_id: "123" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UntagTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `TagsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +## Conversations +
client.conversations.list({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all conversations. + +You can optionally request the result page size and the cursor to start after to fetch the result. +{% admonition type="warning" name="Pagination" %} + You can use pagination to limit the number of results returned. The default is `20` results per page. + See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. +{% /admonition %} +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const pageableResponse = await client.conversations.list({ + per_page: 1, + starting_after: "starting_after" +}); +for await (const item of pageableResponse) { + console.log(item); +} + +// Or you can manually iterate page-by-page +let page = await client.conversations.list({ + per_page: 1, + starting_after: "starting_after" +}); +while (page.hasNextPage()) { + page = page.getNextPage(); +} + +// You can also access the underlying response +const response = page.response; + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListConversationsRequest` + +
+
+ +
+
+ +**requestOptions:** `ConversationsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.conversations.create({ ...params }) -> Intercom.Message +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a conversation that has been initiated by a contact (ie. user or lead). +The conversation can be an in-app message only. + +{% admonition type="info" name="Sending for visitors" %} +You can also send a message from a visitor by specifying their `user_id` or `id` value in the `from` field, along with a `type` field value of `contact`. +This visitor will be automatically converted to a contact with a lead role once the conversation is created. +{% /admonition %} + +This will return the Message model that has been created. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.create({ + from: { + type: "user", + id: "6762f11b1bb69f9f2193bba3" + }, + body: "Hello there" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `ConversationsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.conversations.find({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ + +You can fetch the details of a single conversation. + +This will return a single Conversation model with all its conversation parts. + +{% admonition type="warning" name="Hard limit of 500 parts" %} +The maximum number of conversation parts that can be returned via the API is 500. If you have more than that we will return the 500 most recent conversation parts. +{% /admonition %} + +For AI agent conversation metadata, please note that you need to have the agent enabled in your workspace, which is a [paid feature](https://www.intercom.com/help/en/articles/8205718-fin-resolutions#h_97f8c2e671). +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.find({ + conversation_id: "123", + display_as: "plaintext", + include_translations: true +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `ConversationsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.conversations.update({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ + +You can update an existing conversation. + +{% admonition type="info" name="Replying and other actions" %} +If you want to reply to a coveration or take an action such as assign, unassign, open, close or snooze, take a look at the reply and manage endpoints. +{% /admonition %} + +{% admonition type="info" %} + This endpoint handles both **conversation updates** and **custom object associations**. + + See _`update a conversation with an association to a custom object instance`_ in the request/response examples to see the custom object association format. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.update({ + conversation_id: "conversation_id", + display_as: "plaintext", + read: true, + title: "new conversation title", + custom_attributes: { + "issue_type": "Billing", + "priority": "High" + } +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UpdateConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `ConversationsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.conversations.deleteConversation({ ...params }) -> Intercom.ConversationDeleted +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can delete a single conversation. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.deleteConversation({ + conversation_id: 1 +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.DeleteConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `ConversationsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.conversations.search({ ...params }) -> core.Page +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can search for multiple conversations by the value of their attributes in order to fetch exactly which ones you want. + +To search for conversations, you need to send a `POST` request to `https://api.intercom.io/conversations/search`. + +This will accept a query object in the body which will define your filters in order to search for conversations. +{% admonition type="warning" name="Optimizing search queries" %} + Search queries can be complex, so optimizing them can help the performance of your search. + Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize + pagination to limit the number of results returned. The default is `20` results per page and maximum is `150`. + See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. +{% /admonition %} + +### Nesting & Limitations + +You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). +There are some limitations to the amount of multiple's there can be: +- There's a limit of max 2 nested filters +- There's a limit of max 15 filters for each AND or OR group + +### Accepted Fields + +Most keys listed in the conversation model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). +The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. + +| Field | Type | +| :---------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------- | +| id | String | +| created_at | Date (UNIX timestamp) | +| updated_at | Date (UNIX timestamp) | +| source.type | String
Accepted fields are `conversation`, `email`, `facebook`, `instagram`, `phone_call`, `phone_switch`, `push`, `sms`, `twitter` and `whatsapp`. | +| source.id | String | +| source.delivered_as | String | +| source.subject | String | +| source.body | String | +| source.author.id | String | +| source.author.type | String | +| source.author.name | String | +| source.author.email | String | +| source.url | String | +| contact_ids | String | +| teammate_ids | String | +| admin_assignee_id | String | +| team_assignee_id | String | +| channel_initiated | String | +| open | Boolean | +| read | Boolean | +| state | String | +| waiting_since | Date (UNIX timestamp) | +| snoozed_until | Date (UNIX timestamp) | +| tag_ids | String | +| priority | String | +| statistics.time_to_assignment | Integer | +| statistics.time_to_admin_reply | Integer | +| statistics.time_to_first_close | Integer | +| statistics.time_to_last_close | Integer | +| statistics.median_time_to_reply | Integer | +| statistics.first_contact_reply_at | Date (UNIX timestamp) | +| statistics.first_assignment_at | Date (UNIX timestamp) | +| statistics.first_admin_reply_at | Date (UNIX timestamp) | +| statistics.first_close_at | Date (UNIX timestamp) | +| statistics.last_assignment_at | Date (UNIX timestamp) | +| statistics.last_assignment_admin_reply_at | Date (UNIX timestamp) | +| statistics.last_contact_reply_at | Date (UNIX timestamp) | +| statistics.last_admin_reply_at | Date (UNIX timestamp) | +| statistics.last_close_at | Date (UNIX timestamp) | +| statistics.last_closed_by_id | String | +| statistics.count_reopens | Integer | +| statistics.count_assignments | Integer | +| statistics.count_conversation_parts | Integer | +| conversation_rating.requested_at | Date (UNIX timestamp) | +| conversation_rating.replied_at | Date (UNIX timestamp) | +| conversation_rating.score | Integer | +| conversation_rating.remark | String | +| conversation_rating.contact_id | String | +| conversation_rating.admin_d | String | +| ai_agent_participated | Boolean | +| ai_agent.resolution_state | String | +| ai_agent.last_answer_type | String | +| ai_agent.rating | Integer | +| ai_agent.rating_remark | String | +| ai_agent.source_type | String | +| ai_agent.source_title | String | + +### Accepted Operators + +The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + +| Operator | Valid Types | Description | +| :------- | :----------------------------- | :----------------------------------------------------------- | +| = | All | Equals | +| != | All | Doesn't Equal | +| IN | All | In Shortcut for `OR` queries Values most be in Array | +| NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | +| > | Integer Date (UNIX Timestamp) | Greater (or equal) than | +| < | Integer Date (UNIX Timestamp) | Lower (or equal) than | +| ~ | String | Contains | +| !~ | String | Doesn't Contain | +| ^ | String | Starts With | +| $ | String | Ends With | +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +const pageableResponse = await client.conversations.search({ + query: { + operator: "AND", + value: [{ + field: "created_at", + operator: ">", + value: "1306054154" + }] + }, + pagination: { + per_page: 5 + } +}); +for await (const item of pageableResponse) { + console.log(item); +} + +// Or you can manually iterate page-by-page +let page = await client.conversations.search({ + query: { + operator: "AND", + value: [{ + field: "created_at", + operator: ">", + value: "1306054154" + }] + }, + pagination: { + per_page: 5 + } +}); +while (page.hasNextPage()) { + page = page.getNextPage(); +} + +// You can also access the underlying response +const response = page.response; + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.SearchRequest` + +
+
+ +
+
+ +**requestOptions:** `ConversationsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.conversations.reply({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can reply to a conversation with a message from an admin or on behalf of a contact, or with a note for admins. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.reply({ + conversation_id: "123 or \"last\"", + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1571bb69f9f2193bbbb" + } +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ReplyToConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `ConversationsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.conversations.manage({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +For managing conversations you can: +- Close a conversation +- Snooze a conversation to reopen on a future date +- Open a conversation which is `snoozed` or `closed` +- Assign a conversation to an admin and/or team. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.manage({ + conversation_id: "123", + body: { + message_type: "close", + type: "admin", + admin_id: "12345" + } +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ManageConversationPartsRequest` + +
+
+ +
+
+ +**requestOptions:** `ConversationsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.conversations.attachContactAsAdmin({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. + +{% admonition type="warning" name="Contacts without an email" %} +If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.attachContactAsAdmin({ + conversation_id: "123", + admin_id: "12345", + customer: { + intercom_user_id: "6762f19b1bb69f9f2193bbd4" + } +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.AttachContactToConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `ConversationsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.conversations.detachContactAsAdmin({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. + +{% admonition type="warning" name="Contacts without an email" %} +If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.detachContactAsAdmin({ + conversation_id: "123", + contact_id: "123", + admin_id: "5017690" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.DetachContactFromConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `ConversationsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.conversations.redactConversationPart({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can redact a conversation part or the source message of a conversation (as seen in the source object). + +{% admonition type="info" name="Redacting parts and messages" %} +If you are redacting a conversation part, it must have a `body`. If you are redacting a source message, it must have been created by a contact. We will return a `conversation_part_not_redactable` error if these criteria are not met. +{% /admonition %} + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.redactConversationPart({ + type: "conversation_part", + conversation_id: "19894788788", + conversation_part_id: "19381789428" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.RedactConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `ConversationsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.conversations.convertToTicket({ ...params }) -> Intercom.Ticket | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can convert a conversation to a ticket. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.convertToTicket({ + conversation_id: 1, + ticket_type_id: "53" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ConvertConversationToTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `ConversationsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.conversations.runAssignmentRules({ ...params }) -> Intercom.Conversation +
+
+ +#### 📝 Description + +
+
+ +
+
+ +{% admonition type="danger" name="Deprecation of Run Assignment Rules" %} +Run assignment rules is now deprecated in version 2.12 and future versions and will be permanently removed on December 31, 2026. After this date, any requests made to this endpoint will fail. +{% /admonition %} +You can let a conversation be automatically assigned following assignment rules. +{% admonition type="warning" name="When using workflows" %} +It is not possible to use this endpoint with Workflows. +{% /admonition %} +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.conversations.runAssignmentRules({ + conversation_id: "123" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.AutoAssignConversationRequest` + +
+
+ +
+
+ +**requestOptions:** `ConversationsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +## Custom Channel Events +
client.customChannelEvents.notifyNewConversation({ ...params }) -> Intercom.CustomChannelNotificationResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Notifies Intercom that a new conversation was created in your custom channel/platform. This triggers conversation creation and workflow automations within Intercom for your custom channel integration. +> **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.customChannelEvents.notifyNewConversation({ + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id" + } +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CustomChannelBaseEvent` + +
+
+ +
+
+ +**requestOptions:** `CustomChannelEventsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.customChannelEvents.notifyNewMessage({ ...params }) -> Intercom.CustomChannelNotificationResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Notifies Intercom that a new message was sent in a conversation on your custom channel/platform. This allows Intercom to process the message and trigger any relevant workflow automations. +> **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.customChannelEvents.notifyNewMessage({ + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id" + } +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.NotifyNewMessageRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomChannelEventsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.customChannelEvents.notifyQuickReplySelected({ ...params }) -> Intercom.CustomChannelNotificationResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Notifies Intercom that a user selected a quick reply option in your custom channel/platform. This allows Intercom to process the response and trigger any relevant workflow automations. +> **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.customChannelEvents.notifyQuickReplySelected({ + event_id: "evt_67890", + external_conversation_id: "conv_13579", + contact: { + type: "user", + external_id: "user_003", + name: "Alice Example", + email: "alice@example.com" + }, + quick_reply_option_id: "1234" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.NotifyQuickReplySelectedRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomChannelEventsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.customChannelEvents.notifyAttributeCollected({ ...params }) -> Intercom.CustomChannelNotificationResponse +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Notifies Intercom that a user provided a response to an attribute collector in your custom channel/platform. This allows Intercom to process the attribute and trigger any relevant workflow automations. +> **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.customChannelEvents.notifyAttributeCollected({ + attribute: { + id: "id", + value: "value" + }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id" + } +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.NotifyAttributeCollectedRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomChannelEventsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +## Custom Object Instances +
client.customObjectInstances.getCustomObjectInstancesByExternalId({ ...params }) -> Intercom.CustomObjectInstance | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Fetch a Custom Object Instance by external_id. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.customObjectInstances.getCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "Order", + external_id: "external_id" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.GetCustomObjectInstancesByExternalIdRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomObjectInstancesClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.customObjectInstances.createCustomObjectInstances({ ...params }) -> Intercom.CustomObjectInstance | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Create or update a custom object instance +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.customObjectInstances.createCustomObjectInstances({ + custom_object_type_identifier: "Order", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + custom_attributes: { + "order_number": "ORDER-12345", + "total_amount": "custom_attributes" + } +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateOrUpdateCustomObjectInstanceRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomObjectInstancesClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.customObjectInstances.deleteCustomObjectInstancesById({ ...params }) -> Intercom.CustomObjectInstanceDeleted +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Delete a single Custom Object instance by external_id. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.customObjectInstances.deleteCustomObjectInstancesById({ + custom_object_type_identifier: "Order", + external_id: "external_id" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.DeleteCustomObjectInstancesByIdRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomObjectInstancesClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.customObjectInstances.getCustomObjectInstancesById({ ...params }) -> Intercom.CustomObjectInstance | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Fetch a Custom Object Instance by id. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.customObjectInstances.getCustomObjectInstancesById({ + custom_object_type_identifier: "Order", + custom_object_instance_id: "custom_object_instance_id" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.GetCustomObjectInstancesByIdRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomObjectInstancesClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.customObjectInstances.deleteCustomObjectInstancesByExternalId({ ...params }) -> Intercom.CustomObjectInstanceDeleted +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Delete a single Custom Object instance using the Intercom defined id. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.customObjectInstances.deleteCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "Order", + custom_object_instance_id: "custom_object_instance_id" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.DeleteCustomObjectInstancesByExternalIdRequest` + +
+
+ +
+
+ +**requestOptions:** `CustomObjectInstancesClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +## Data Attributes +
client.dataAttributes.list({ ...params }) -> Intercom.DataAttributeList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all data attributes belonging to a workspace for contacts, companies or conversations. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.dataAttributes.list({ + model: "contact", + include_archived: true +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListDataAttributesRequest` + +
+
+ +
+
+ +**requestOptions:** `DataAttributesClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.dataAttributes.create({ ...params }) -> Intercom.DataAttribute +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a data attributes for a `contact` or a `company`. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.dataAttributes.create({ + data_type: "string" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateDataAttributeRequest` + +
+
+ +
+
+ +**requestOptions:** `DataAttributesClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.dataAttributes.update({ ...params }) -> Intercom.DataAttribute +
+
+ +#### 📝 Description + +
+
+ +
+
+ + +You can update a data attribute. + +> 🚧 Updating the data type is not possible +> +> It is currently a dangerous action to execute changing a data attribute's type via the API. You will need to update the type via the UI instead. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.dataAttributes.update({ + data_attribute_id: 1, + body: { + options: [{ + value: "1-10" + }, { + value: "11-20" + }] + } +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.UpdateDataAttributeRequest` + +
+
+ +
+
+ +**requestOptions:** `DataAttributesClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +## Events +
client.events.list({ ...params }) -> Intercom.DataEventSummary +
+
+ +#### 📝 Description + +
+
+ +
+
+ + +> 🚧 +> +> Please note that you can only 'list' events that are less than 90 days old. Event counts and summaries will still include your events older than 90 days but you cannot 'list' these events individually if they are older than 90 days + +The events belonging to a customer can be listed by sending a GET request to `https://api.intercom.io/events` with a user or lead identifier along with a `type` parameter. The identifier parameter can be one of `user_id`, `email` or `intercom_user_id`. The `type` parameter value must be `user`. + +- `https://api.intercom.io/events?type=user&user_id={user_id}` +- `https://api.intercom.io/events?type=user&email={email}` +- `https://api.intercom.io/events?type=user&intercom_user_id={id}` (this call can be used to list leads) + +The `email` parameter value should be [url encoded](http://en.wikipedia.org/wiki/Percent-encoding) when sending. + +You can optionally define the result page size as well with the `per_page` parameter. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.events.list({ + user_id: "user_id", + intercom_user_id: "intercom_user_id", + email: "email", + type: "type", + summary: true, + per_page: 1 +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListEventsRequest` + +
+
+ +
+
+ +**requestOptions:** `EventsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.events.create({ ...params }) -> void +
+
+ +#### 📝 Description + +
+
+ +
+
+ + +You will need an Access Token that has write permissions to send Events. Once you have a key you can submit events via POST to the Events resource, which is located at https://api.intercom.io/events, or you can send events using one of the client libraries. When working with the HTTP API directly a client should send the event with a `Content-Type` of `application/json`. + +When using the JavaScript API, [adding the code to your app](http://docs.intercom.io/configuring-Intercom/tracking-user-events-in-your-app) makes the Events API available. Once added, you can submit an event using the `trackEvent` method. This will associate the event with the Lead or currently logged-in user or logged-out visitor/lead and send it to Intercom. The final parameter is a map that can be used to send optional metadata about the event. + +With the Ruby client you pass a hash describing the event to `Intercom::Event.create`, or call the `track_user` method directly on the current user object (e.g. `user.track_event`). + +**NB: For the JSON object types, please note that we do not currently support nested JSON structure.** + +| Type | Description | Example | +| :-------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------- | +| String | The value is a JSON String | `"source":"desktop"` | +| Number | The value is a JSON Number | `"load": 3.67` | +| Date | The key ends with the String `_date` and the value is a [Unix timestamp](http://en.wikipedia.org/wiki/Unix_time), assumed to be in the [UTC](http://en.wikipedia.org/wiki/Coordinated_Universal_Time) timezone. | `"contact_date": 1392036272` | +| Link | The value is a HTTP or HTTPS URI. | `"article": "https://example.org/ab1de.html"` | +| Rich Link | The value is a JSON object that contains `url` and `value` keys. | `"article": {"url": "https://example.org/ab1de.html", "value":"the dude abides"}` | +| Monetary Amount | The value is a JSON object that contains `amount` and `currency` keys. The `amount` key is a positive integer representing the amount in cents. The price in the example to the right denotes €349.99. | `"price": {"amount": 34999, "currency": "eur"}` | + +**Lead Events** + +When submitting events for Leads, you will need to specify the Lead's `id`. + +**Metadata behaviour** + +- We currently limit the number of tracked metadata keys to 10 per event. Once the quota is reached, we ignore any further keys we receive. The first 10 metadata keys are determined by the order in which they are sent in with the event. +- It is not possible to change the metadata keys once the event has been sent. A new event will need to be created with the new keys and you can archive the old one. +- There might be up to 24 hrs delay when you send a new metadata for an existing event. + +**Event de-duplication** + +The API may detect and ignore duplicate events. Each event is uniquely identified as a combination of the following data - the Workspace identifier, the Contact external identifier, the Data Event name and the Data Event created time. As a result, it is **strongly recommended** to send a second granularity Unix timestamp in the `created_at` field. + +Duplicated events are responded to using the normal `202 Accepted` code - an error is not thrown, however repeat requests will be counted against any rate limit that is in place. + +### HTTP API Responses + +- Successful responses to submitted events return `202 Accepted` with an empty body. +- Unauthorised access will be rejected with a `401 Unauthorized` or `403 Forbidden` response code. +- Events sent about users that cannot be found will return a `404 Not Found`. +- Event lists containing duplicate events will have those duplicates ignored. +- Server errors will return a `500` response code and may contain an error message in the body. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.events.create({ + id: "8a88a590-e1c3-41e2-a502-e0649dbf721c", + event_name: "invited-friend", + created_at: 1671028894 +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateDataEventRequest` + +
+
+ +
+
+ +**requestOptions:** `EventsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.events.summaries({ ...params }) -> void +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Create event summaries for a user. Event summaries are used to track the number of times an event has occurred, the first time it occurred and the last time it occurred. + +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.events.summaries(); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListEventSummariesRequest` + +
+
+ +
+
+ +**requestOptions:** `EventsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +## Jobs +
client.jobs.status({ ...params }) -> Intercom.Jobs +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve the status of job execution. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.jobs.status({ + job_id: "job_id" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.JobsStatusRequest` + +
+
+ +
+
+ +**requestOptions:** `JobsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +## Messages +
client.messages.create({ ...params }) -> Intercom.Message +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can create a message that has been initiated by an admin. The conversation can be either an in-app message or an email. + +> 🚧 Sending for visitors +> +> There can be a short delay between when a contact is created and when a contact becomes available to be messaged through the API. A 404 Not Found error will be returned in this case. + +This will return the Message model that has been created. + +> 🚧 Retrieving Associated Conversations +> +> As this is a message, there will be no conversation present until the contact responds. Once they do, you will have to search for a contact's conversations with the id of the message. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.messages.create({ + message_type: "email", + subject: "Thanks for everything", + body: "Hello there", + template: "plain", + from: { + type: "admin", + id: 394051 + }, + to: { + type: "user", + id: "536e564f316c83104c000020" + } +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreateMessageRequest` + +
+
+ +
+
+ +**requestOptions:** `MessagesClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +## Segments +
client.segments.list({ ...params }) -> Intercom.SegmentList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch a list of all segments. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.segments.list({ + include_count: true +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListSegmentsRequest` + +
+
+ +
+
+ +**requestOptions:** `SegmentsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.segments.find({ ...params }) -> Intercom.Segment +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can fetch the details of a single segment. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.segments.find({ + segment_id: "123" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.FindSegmentRequest` + +
+
+ +
+
+ +**requestOptions:** `SegmentsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +## Subscription Types +
client.subscriptionTypes.list() -> Intercom.SubscriptionTypeList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can list all subscription types. A list of subscription type objects will be returned. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.subscriptionTypes.list(); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `SubscriptionTypesClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +## PhoneCallRedirects +
client.phoneCallRedirects.create({ ...params }) -> Intercom.PhoneSwitch | undefined +
+
+ +#### 📝 Description + +
+
+ +
+
+ +You can use the API to deflect phone calls to the Intercom Messenger. +Calling this endpoint will send an SMS with a link to the Messenger to the phone number specified. + +If custom attributes are specified, they will be added to the user or lead's custom data attributes. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.phoneCallRedirects.create({ + phone: "+353832345678", + custom_attributes: { + "issue_type": "Billing", + "priority": "High" + } +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.CreatePhoneSwitchRequest` + +
+
+ +
+
+ +**requestOptions:** `PhoneCallRedirectsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +## Calls +
client.calls.listCalls({ ...params }) -> Intercom.CallList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve a paginated list of calls. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.calls.listCalls({ + page: 1, + per_page: 1 +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ListCallsRequest` + +
+
+ +
+
+ +**requestOptions:** `CallsClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.calls.showCall({ ...params }) -> Intercom.Call +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve a single call by id. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.calls.showCall({ + call_id: "call_id" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.ShowCallRequest` + +
+
+ +
+
+ +**requestOptions:** `CallsClient.RequestOptions` + +
+
+
+
+ +
-
client.conversations.find({ ...params }) -> Intercom.Conversation +
client.calls.showCallRecording({ ...params }) -> void
@@ -3857,16 +8171,7 @@ await client.conversations.create({
-You can fetch the details of a single conversation. - -This will return a single Conversation model with all its conversation parts. - -{% admonition type="warning" name="Hard limit of 500 parts" %} -The maximum number of conversation parts that can be returned via the API is 500. If you have more than that we will return the 500 most recent conversation parts. -{% /admonition %} - -For AI agent conversation metadata, please note that you need to have the agent enabled in your workspace, which is a [paid feature](https://www.intercom.com/help/en/articles/8205718-fin-resolutions#h_97f8c2e671). - +Redirects to a signed URL for the call's recording if it exists.
@@ -3881,12 +8186,11 @@ For AI agent conversation metadata, please note that you need to have the agent
```typescript -await client.conversations.find({ - conversation_id: "123", - display_as: "plaintext", +await client.calls.showCallRecording({ + call_id: "call_id" }); -``` +```
@@ -3900,26 +8204,27 @@ await client.conversations.find({
-**request:** `Intercom.FindConversationRequest` - +**request:** `Intercom.ShowCallRecordingRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `CallsClient.RequestOptions` +
+
-
client.conversations.update({ ...params }) -> Intercom.Conversation +
client.calls.showCallTranscript({ ...params }) -> string
@@ -3931,12 +8236,7 @@ await client.conversations.find({
-You can update an existing conversation. - -{% admonition type="info" name="Replying and other actions" %} -If you want to reply to a coveration or take an action such as assign, unassign, open, close or snooze, take a look at the reply and manage endpoints. -{% /admonition %} - +Returns the transcript for the specified call as a downloadable text file.
@@ -3951,17 +8251,11 @@ If you want to reply to a coveration or take an action such as assign, unassign,
```typescript -await client.conversations.update({ - conversation_id: "123", - display_as: "plaintext", - read: true, - custom_attributes: { - issue_type: "Billing", - priority: "High", - }, +await client.calls.showCallTranscript({ + call_id: "call_id" }); -``` +```
@@ -3975,26 +8269,27 @@ await client.conversations.update({
-**request:** `Intercom.UpdateConversationRequest` - +**request:** `Intercom.ShowCallTranscriptRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `CallsClient.RequestOptions` +
+
-
client.conversations.search({ ...params }) -> core.Page +
client.calls.listCallsWithTranscripts({ ...params }) -> Intercom.ListCallsWithTranscriptsResponse
@@ -4006,107 +8301,8 @@ await client.conversations.update({
-You can search for multiple conversations by the value of their attributes in order to fetch exactly which ones you want. - -To search for conversations, you need to send a `POST` request to `https://api.intercom.io/conversations/search`. - -This will accept a query object in the body which will define your filters in order to search for conversations. -{% admonition type="warning" name="Optimizing search queries" %} -Search queries can be complex, so optimizing them can help the performance of your search. -Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize -pagination to limit the number of results returned. The default is `20` results per page and maximum is `150`. -See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. -{% /admonition %} - -### Nesting & Limitations - -You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). -There are some limitations to the amount of multiple's there can be: - -- There's a limit of max 2 nested filters -- There's a limit of max 15 filters for each AND or OR group - -### Accepted Fields - -Most keys listed as part of the The conversation model is searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). -The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. - -| Field | Type | -| :---------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------- | -| id | String | -| created_at | Date (UNIX timestamp) | -| updated_at | Date (UNIX timestamp) | -| source.type | String
Accepted fields are `conversation`, `email`, `facebook`, `instagram`, `phone_call`, `phone_switch`, `push`, `sms`, `twitter` and `whatsapp`. | -| source.id | String | -| source.delivered_as | String | -| source.subject | String | -| source.body | String | -| source.author.id | String | -| source.author.type | String | -| source.author.name | String | -| source.author.email | String | -| source.url | String | -| contact_ids | String | -| teammate_ids | String | -| admin_assignee_id | String | -| team_assignee_id | String | -| channel_initiated | String | -| open | Boolean | -| read | Boolean | -| state | String | -| waiting_since | Date (UNIX timestamp) | -| snoozed_until | Date (UNIX timestamp) | -| tag_ids | String | -| priority | String | -| statistics.time_to_assignment | Integer | -| statistics.time_to_admin_reply | Integer | -| statistics.time_to_first_close | Integer | -| statistics.time_to_last_close | Integer | -| statistics.median_time_to_reply | Integer | -| statistics.first_contact_reply_at | Date (UNIX timestamp) | -| statistics.first_assignment_at | Date (UNIX timestamp) | -| statistics.first_admin_reply_at | Date (UNIX timestamp) | -| statistics.first_close_at | Date (UNIX timestamp) | -| statistics.last_assignment_at | Date (UNIX timestamp) | -| statistics.last_assignment_admin_reply_at | Date (UNIX timestamp) | -| statistics.last_contact_reply_at | Date (UNIX timestamp) | -| statistics.last_admin_reply_at | Date (UNIX timestamp) | -| statistics.last_close_at | Date (UNIX timestamp) | -| statistics.last_closed_by_id | String | -| statistics.count_reopens | Integer | -| statistics.count_assignments | Integer | -| statistics.count_conversation_parts | Integer | -| conversation_rating.requested_at | Date (UNIX timestamp) | -| conversation_rating.replied_at | Date (UNIX timestamp) | -| conversation_rating.score | Integer | -| conversation_rating.remark | String | -| conversation_rating.contact_id | String | -| conversation_rating.admin_d | String | -| ai_agent_participated | Boolean | -| ai_agent.resolution_state | String | -| ai_agent.last_answer_type | String | -| ai_agent.rating | Integer | -| ai_agent.rating_remark | String | -| ai_agent.source_type | String | -| ai_agent.source_title | String | - -### Accepted Operators - -The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). - -| Operator | Valid Types | Description | -| :------- | :---------------------------- | :--------------------------------------------------------- | -| = | All | Equals | -| != | All | Doesn't Equal | -| IN | All | In Shortcut for `OR` queries Values most be in Array | -| NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | -| > | Integer Date (UNIX Timestamp) | Greater (or equal) than | -| < | Integer Date (UNIX Timestamp) | Lower (or equal) than | -| ~ | String | Contains | -| !~ | String | Doesn't Contain | -| ^ | String | Starts With | -| $ | String | Ends With | - +Retrieve calls by a list of conversation ids and include transcripts when available. +A maximum of 20 `conversation_ids` can be provided. If none are provided or more than 20 are provided, a 400 error is returned.
@@ -4121,46 +8317,11 @@ The table below shows the operators you can use to define how you want to search
```typescript -const response = await client.conversations.search({ - query: { - operator: "AND", - value: [ - { - field: "created_at", - operator: ">", - value: "1306054154", - }, - ], - }, - pagination: { - per_page: 5, - }, +await client.calls.listCallsWithTranscripts({ + conversation_ids: ["64619700005694", "64619700005695"] }); -for await (const item of response) { - console.log(item); -} -// Or you can manually iterate page-by-page -const page = await client.conversations.search({ - query: { - operator: "AND", - value: [ - { - field: "created_at", - operator: ">", - value: "1306054154", - }, - ], - }, - pagination: { - per_page: 5, - }, -}); -while (page.hasNextPage()) { - page = page.getNextPage(); -} ``` -
@@ -4174,26 +8335,28 @@ while (page.hasNextPage()) {
-**request:** `Intercom.SearchRequest` - +**request:** `Intercom.ListCallsWithTranscriptsRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `CallsClient.RequestOptions` +
+
-
client.conversations.reply({ ...params }) -> Intercom.Conversation +## Teams +
client.teams.list() -> Intercom.TeamList
@@ -4205,8 +8368,7 @@ while (page.hasNextPage()) {
-You can reply to a conversation with a message from an admin or on behalf of a contact, or with a note for admins. - +This will return a list of team objects for the App.
@@ -4221,17 +8383,9 @@ You can reply to a conversation with a message from an admin or on behalf of a c
```typescript -await client.conversations.reply({ - conversation_id: '123 or "last"', - body: { - message_type: "comment", - type: "user", - body: "Thanks again :)", - intercom_user_id: "667d60f18a68186f43bafdf4", - }, -}); -``` +await client.teams.list(); +```
@@ -4245,26 +8399,19 @@ await client.conversations.reply({
-**request:** `Intercom.ReplyToConversationRequest` - -
-
- -
-
- -**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `TeamsClient.RequestOptions` +
+
-
client.conversations.manage({ ...params }) -> Intercom.Conversation +
client.teams.find({ ...params }) -> Intercom.Team
@@ -4276,16 +8423,11 @@ await client.conversations.reply({
-For managing conversations you can: - -- Close a conversation -- Snooze a conversation to reopen on a future date -- Open a conversation which is `snoozed` or `closed` -- Assign a conversation to an admin and/or team. -
-
-
-
+You can fetch the details of a single team, containing an array of admins that belong to this team. + + + + #### 🔌 Usage @@ -4296,16 +8438,11 @@ For managing conversations you can:
```typescript -await client.conversations.manage({ - conversation_id: "123", - body: { - message_type: "close", - type: "admin", - admin_id: "12345", - }, +await client.teams.find({ + team_id: "123" }); -``` +```
@@ -4319,26 +8456,28 @@ await client.conversations.manage({
-**request:** `Intercom.ManageConversationPartsRequest` - +**request:** `Intercom.FindTeamRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `TeamsClient.RequestOptions` +
+
-
client.conversations.runAssignmentRules({ ...params }) -> Intercom.Conversation +## Ticket States +
client.ticketStates.listTicketStates() -> Intercom.TicketStateList
@@ -4350,14 +8489,7 @@ await client.conversations.manage({
-{% admonition type="danger" name="Deprecation of Run Assignment Rules" %} -Run assignment rules is now deprecated in version 2.12 and future versions and will be permanently removed on December 31, 2026. After this date, any requests made to this endpoint will fail. -{% /admonition %} -You can let a conversation be automatically assigned following assignment rules. -{% admonition type="warning" name="When using workflows" %} -It is not possible to use this endpoint with Workflows. -{% /admonition %} - +You can get a list of all ticket states for a workspace.
@@ -4372,11 +8504,9 @@ It is not possible to use this endpoint with Workflows.
```typescript -await client.conversations.runAssignmentRules({ - conversation_id: "123", -}); -``` +await client.ticketStates.listTicketStates(); +```
@@ -4390,26 +8520,20 @@ await client.conversations.runAssignmentRules({
-**request:** `Intercom.AutoAssignConversationRequest` - -
-
- -
-
- -**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `TicketStatesClient.RequestOptions` +
+
-
client.conversations.attachContactAsAdmin({ ...params }) -> Intercom.Conversation +## Ticket Types +
client.ticketTypes.list() -> Intercom.TicketTypeList
@@ -4421,12 +8545,7 @@ await client.conversations.runAssignmentRules({
-You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. - -{% admonition type="warning" name="Contacts without an email" %} -If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. -{% /admonition %} - +You can get a list of all ticket types for a workspace.
@@ -4441,15 +8560,9 @@ If you add a contact via the email parameter and there is no user/lead found on
```typescript -await client.conversations.attachContactAsAdmin({ - conversation_id: "123", - admin_id: "12345", - customer: { - intercom_user_id: "667d61168a68186f43bafe0d", - }, -}); -``` +await client.ticketTypes.list(); +```
@@ -4463,26 +8576,19 @@ await client.conversations.attachContactAsAdmin({
-**request:** `Intercom.AttachContactToConversationRequest` - -
-
- -
-
- -**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `TicketTypesClient.RequestOptions` +
+
-
client.conversations.detachContactAsAdmin({ ...params }) -> Intercom.Conversation +
client.ticketTypes.create({ ...params }) -> Intercom.TicketType | undefined
@@ -4492,14 +8598,13 @@ await client.conversations.attachContactAsAdmin({
-
- -You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. - -{% admonition type="warning" name="Contacts without an email" %} -If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. -{% /admonition %} +
+You can create a new ticket type. +> 📘 Creating ticket types. +> +> Every ticket type will be created with two default attributes: _default_title_ and _default_description_. +> For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/)
@@ -4514,13 +8619,14 @@ If you add a contact via the email parameter and there is no user/lead found on
```typescript -await client.conversations.detachContactAsAdmin({ - conversation_id: "123", - contact_id: "123", - admin_id: "5017690", +await client.ticketTypes.create({ + name: "Customer Issue", + description: "Customer Report Template", + category: "Customer", + icon: "\uD83C\uDF9F\uFE0F" }); -``` +```
@@ -4534,26 +8640,27 @@ await client.conversations.detachContactAsAdmin({
-**request:** `Intercom.DetachContactFromConversationRequest` - +**request:** `Intercom.CreateTicketTypeRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `TicketTypesClient.RequestOptions` +
+
-
client.conversations.redactConversationPart({ ...params }) -> Intercom.Conversation +
client.ticketTypes.get({ ...params }) -> Intercom.TicketType | undefined
@@ -4565,12 +8672,7 @@ await client.conversations.detachContactAsAdmin({
-You can redact a conversation part or the source message of a conversation (as seen in the source object). - -{% admonition type="info" name="Redacting parts and messages" %} -If you are redacting a conversation part, it must have a `body`. If you are redacting a source message, it must have been created by a contact. We will return a `conversation_part_not_redactable` error if these criteria are not met. -{% /admonition %} - +You can fetch the details of a single ticket type.
@@ -4585,13 +8687,11 @@ If you are redacting a conversation part, it must have a `body`. If you are reda
```typescript -await client.conversations.redactConversationPart({ - type: "conversation_part", - conversation_id: "19894788788", - conversation_part_id: "19381789428", +await client.ticketTypes.get({ + ticket_type_id: "ticket_type_id" }); -``` +```
@@ -4605,26 +8705,27 @@ await client.conversations.redactConversationPart({
-**request:** `Intercom.RedactConversationRequest` - +**request:** `Intercom.FindTicketTypeRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `TicketTypesClient.RequestOptions` +
+
-
client.conversations.convertToTicket({ ...params }) -> Intercom.Ticket +
client.ticketTypes.update({ ...params }) -> Intercom.TicketType | undefined
@@ -4636,8 +8737,12 @@ await client.conversations.redactConversationPart({
-You can convert a conversation to a ticket. +You can update a ticket type. + +> 📘 Updating a ticket type. +> +> For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/)
@@ -4652,12 +8757,12 @@ You can convert a conversation to a ticket.
```typescript -await client.conversations.convertToTicket({ - conversation_id: "123", - ticket_type_id: "79", +await client.ticketTypes.update({ + ticket_type_id: "ticket_type_id", + name: "Bug Report 2" }); -``` +```
@@ -4671,28 +8776,28 @@ await client.conversations.convertToTicket({
-**request:** `Intercom.ConvertConversationToTicketRequest` - +**request:** `Intercom.UpdateTicketTypeRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `TicketTypesClient.RequestOptions` +
+
-## Data Attributes - -
client.dataAttributes.list({ ...params }) -> Intercom.DataAttributeList +## Tickets +
client.tickets.reply({ ...params }) -> Intercom.TicketReply
@@ -4704,8 +8809,7 @@ await client.conversations.convertToTicket({
-You can fetch a list of all data attributes belonging to a workspace for contacts, companies or conversations. - +You can reply to a ticket with a message from an admin or on behalf of a contact, or with a note for admins.
@@ -4720,9 +8824,17 @@ You can fetch a list of all data attributes belonging to a workspace for contact
```typescript -await client.dataAttributes.list(); -``` +await client.tickets.reply({ + ticket_id: "123", + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2971bb69f9f2193bc49" + } +}); +```
@@ -4736,26 +8848,27 @@ await client.dataAttributes.list();
-**request:** `Intercom.ListDataAttributesRequest` - +**request:** `Intercom.ReplyToTicketRequest` +
-**requestOptions:** `DataAttributes.RequestOptions` - +**requestOptions:** `TicketsClient.RequestOptions` +
+
-
client.dataAttributes.create({ ...params }) -> Intercom.DataAttribute +
client.tickets.create({ ...params }) -> Intercom.Ticket | undefined
@@ -4767,8 +8880,7 @@ await client.dataAttributes.list();
-You can create a data attributes for a `contact` or a `company`. - +You can create a new ticket.
@@ -4783,13 +8895,14 @@ You can create a data attributes for a `contact` or a `company`.
```typescript -await client.dataAttributes.create({ - name: "Mithril Shirt", - model: "company", - data_type: "string", +await client.tickets.create({ + ticket_type_id: "1234", + contacts: [{ + id: "6762f2d81bb69f9f2193bc54" + }] }); -``` +```
@@ -4803,26 +8916,27 @@ await client.dataAttributes.create({
-**request:** `Intercom.CreateDataAttributeRequest` - +**request:** `Intercom.CreateTicketRequest` +
-**requestOptions:** `DataAttributes.RequestOptions` - +**requestOptions:** `TicketsClient.RequestOptions` +
+
-
client.dataAttributes.update({ ...params }) -> Intercom.DataAttribute +
client.tickets.enqueueCreateTicket({ ...params }) -> Intercom.Jobs
@@ -4834,12 +8948,7 @@ await client.dataAttributes.create({
-You can update a data attribute. - -> 🚧 Updating the data type is not possible -> -> It is currently a dangerous action to execute changing a data attribute's type via the API. You will need to update the type via the UI instead. - +Enqueues ticket creation for asynchronous processing, returning if the job was enqueued successfully to be processed. We attempt to perform a best-effort validation on inputs before tasks are enqueued. If the given parameters are incorrect, we won't enqueue the job.
@@ -4854,21 +8963,14 @@ You can update a data attribute.
```typescript -await client.dataAttributes.update({ - data_attribute_id: "1", - archived: false, - description: "Just a plain old ring", - options: [ - { - value: "1-10", - }, - { - value: "11-20", - }, - ], +await client.tickets.enqueueCreateTicket({ + ticket_type_id: "1234", + contacts: [{ + id: "6762f2d81bb69f9f2193bc54" + }] }); -``` +```
@@ -4882,28 +8984,27 @@ await client.dataAttributes.update({
-**request:** `Intercom.UpdateDataAttributeRequest` - +**request:** `Intercom.EnqueueCreateTicketRequest` +
-**requestOptions:** `DataAttributes.RequestOptions` - +**requestOptions:** `TicketsClient.RequestOptions` +
+
-## Events - -
client.events.list({ ...params }) -> Intercom.DataEventSummary +
client.tickets.get({ ...params }) -> Intercom.Ticket | undefined
@@ -4915,20 +9016,7 @@ await client.dataAttributes.update({
-> 🚧 -> -> Please note that you can only 'list' events that are less than 90 days old. Event counts and summaries will still include your events older than 90 days but you cannot 'list' these events individually if they are older than 90 days - -The events belonging to a customer can be listed by sending a GET request to `https://api.intercom.io/events` with a user or lead identifier along with a `type` parameter. The identifier parameter can be one of `user_id`, `email` or `intercom_user_id`. The `type` parameter value must be `user`. - -- `https://api.intercom.io/events?type=user&user_id={user_id}` -- `https://api.intercom.io/events?type=user&email={email}` -- `https://api.intercom.io/events?type=user&intercom_user_id={id}` (this call can be used to list leads) - -The `email` parameter value should be [url encoded](http://en.wikipedia.org/wiki/Percent-encoding) when sending. - -You can optionally define the result page size as well with the `per_page` parameter. - +You can fetch the details of a single ticket.
@@ -4943,11 +9031,11 @@ You can optionally define the result page size as well with the `per_page` param
```typescript -await client.events.list({ - type: "type", +await client.tickets.get({ + ticket_id: "ticket_id" }); -``` +```
@@ -4961,26 +9049,27 @@ await client.events.list({
-**request:** `Intercom.ListEventsRequest` - +**request:** `Intercom.FindTicketRequest` +
-**requestOptions:** `Events.RequestOptions` - +**requestOptions:** `TicketsClient.RequestOptions` +
+
-
client.events.create({ ...params }) -> void +
client.tickets.update({ ...params }) -> Intercom.Ticket | undefined
@@ -4992,50 +9081,11 @@ await client.events.list({
-You will need an Access Token that has write permissions to send Events. Once you have a key you can submit events via POST to the Events resource, which is located at https://api.intercom.io/events, or you can send events using one of the client libraries. When working with the HTTP API directly a client should send the event with a `Content-Type` of `application/json`. - -When using the JavaScript API, [adding the code to your app](http://docs.intercom.io/configuring-Intercom/tracking-user-events-in-your-app) makes the Events API available. Once added, you can submit an event using the `trackEvent` method. This will associate the event with the Lead or currently logged-in user or logged-out visitor/lead and send it to Intercom. The final parameter is a map that can be used to send optional metadata about the event. - -With the Ruby client you pass a hash describing the event to `Intercom::Event.create`, or call the `track_user` method directly on the current user object (e.g. `user.track_event`). - -**NB: For the JSON object types, please note that we do not currently support nested JSON structure.** - -| Type | Description | Example | -| :-------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------- | -| String | The value is a JSON String | `"source":"desktop"` | -| Number | The value is a JSON Number | `"load": 3.67` | -| Date | The key ends with the String `_date` and the value is a [Unix timestamp](http://en.wikipedia.org/wiki/Unix_time), assumed to be in the [UTC](http://en.wikipedia.org/wiki/Coordinated_Universal_Time) timezone. | `"contact_date": 1392036272` | -| Link | The value is a HTTP or HTTPS URI. | `"article": "https://example.org/ab1de.html"` | -| Rich Link | The value is a JSON object that contains `url` and `value` keys. | `"article": {"url": "https://example.org/ab1de.html", "value":"the dude abides"}` | -| Monetary Amount | The value is a JSON object that contains `amount` and `currency` keys. The `amount` key is a positive integer representing the amount in cents. The price in the example to the right denotes €349.99. | `"price": {"amount": 34999, "currency": "eur"}` | - -**Lead Events** - -When submitting events for Leads, you will need to specify the Lead's `id`. - -**Metadata behaviour** - -- We currently limit the number of tracked metadata keys to 10 per event. Once the quota is reached, we ignore any further keys we receive. The first 10 metadata keys are determined by the order in which they are sent in with the event. -- It is not possible to change the metadata keys once the event has been sent. A new event will need to be created with the new keys and you can archive the old one. -- There might be up to 24 hrs delay when you send a new metadata for an existing event. - -**Event de-duplication** - -The API may detect and ignore duplicate events. Each event is uniquely identified as a combination of the following data - the Workspace identifier, the Contact external identifier, the Data Event name and the Data Event created time. As a result, it is **strongly recommended** to send a second granularity Unix timestamp in the `created_at` field. - -Duplicated events are responded to using the normal `202 Accepted` code - an error is not thrown, however repeat requests will be counted against any rate limit that is in place. - -### HTTP API Responses - -- Successful responses to submitted events return `202 Accepted` with an empty body. -- Unauthorised access will be rejected with a `401 Unauthorized` or `403 Forbidden` response code. -- Events sent about users that cannot be found will return a `404 Not Found`. -- Event lists containing duplicate events will have those duplicates ignored. -- Server errors will return a `500` response code and may contain an error message in the body. -
-
-
-
+You can update a ticket. + + + + #### 🔌 Usage @@ -5046,13 +9096,20 @@ Duplicated events are responded to using the normal `202 Accepted` code - an err
```typescript -await client.events.create({ - id: "8a88a590-e1c3-41e2-a502-e0649dbf721c", - event_name: "invited-friend", - created_at: 1671028894, +await client.tickets.update({ + ticket_id: "ticket_id", + ticket_attributes: { + "_default_title_": "example", + "_default_description_": "there is a problem" + }, + ticket_state_id: "123", + open: true, + snoozed_until: 1673609604, + admin_id: 991268011, + assignee_id: "123" }); -``` +```
@@ -5066,26 +9123,27 @@ await client.events.create({
-**request:** `Intercom.CreateDataEventRequest` - +**request:** `Intercom.UpdateTicketRequest` +
-**requestOptions:** `Events.RequestOptions` - +**requestOptions:** `TicketsClient.RequestOptions` +
+
-
client.events.summaries({ ...params }) -> void +
client.tickets.deleteTicket({ ...params }) -> Intercom.DeleteTicketResponse
@@ -5097,8 +9155,7 @@ await client.events.create({
-Create event summaries for a user. Event summaries are used to track the number of times an event has occurred, the first time it occurred and the last time it occurred. - +You can delete a ticket using the Intercom provided ID.
@@ -5113,9 +9170,11 @@ Create event summaries for a user. Event summaries are used to track the number
```typescript -await client.events.summaries(); -``` +await client.tickets.deleteTicket({ + ticket_id: "ticket_id" +}); +```
@@ -5129,28 +9188,27 @@ await client.events.summaries();
-**request:** `Intercom.ListEventSummariesRequest` - +**request:** `Intercom.DeleteTicketRequest` +
-**requestOptions:** `Events.RequestOptions` - +**requestOptions:** `TicketsClient.RequestOptions` +
+
-## Data Export - -
client.dataExport.create({ ...params }) -> Intercom.DataExport +
client.tickets.search({ ...params }) -> core.Page<(Intercom.Ticket | undefined), Intercom.TicketList>
@@ -5162,22 +9220,75 @@ await client.events.summaries();
-To create your export job, you need to send a `POST` request to the export endpoint `https://api.intercom.io/export/content/data`. +You can search for multiple tickets by the value of their attributes in order to fetch exactly which ones you want. -The only parameters you need to provide are the range of dates that you want exported. +To search for tickets, you send a `POST` request to `https://api.intercom.io/tickets/search`. -> 🚧 Limit of one active job -> -> You can only have one active job per workspace. You will receive a HTTP status code of 429 with the message Exceeded rate limit of 1 pending message data export jobs if you attempt to create a second concurrent job. +This will accept a query object in the body which will define your filters. +{% admonition type="warning" name="Optimizing search queries" %} + Search queries can be complex, so optimizing them can help the performance of your search. + Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize + pagination to limit the number of results returned. The default is `20` results per page. + See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. +{% /admonition %} -> ❗️ Updated_at not included -> -> It should be noted that the timeframe only includes messages sent during the time period and not messages that were only updated during this period. For example, if a message was updated yesterday but sent two days ago, you would need to set the created_at_after date before the message was sent to include that in your retrieval job. +### Nesting & Limitations -> 📘 Date ranges are inclusive -> -> Requesting data for 2018-06-01 until 2018-06-30 will get all data for those days including those specified - e.g. 2018-06-01 00:00:00 until 2018-06-30 23:59:99. +You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). +There are some limitations to the amount of multiples there can be: +- There's a limit of max 2 nested filters +- There's a limit of max 15 filters for each AND or OR group + +### Accepted Fields + +Most keys listed as part of the Ticket model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foobar"`). +The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. + +| Field | Type | +| :---------------------------------------- | :--------------------------------------------------------------------------------------- | +| id | String | +| created_at | Date (UNIX timestamp) | +| updated_at | Date (UNIX timestamp) | +| title | String | +| description | String | +| category | String | +| ticket_type_id | String | +| contact_ids | String | +| teammate_ids | String | +| admin_assignee_id | String | +| team_assignee_id | String | +| open | Boolean | +| state | String | +| snoozed_until | Date (UNIX timestamp) | +| ticket_attribute.{id} | String or Boolean or Date (UNIX timestamp) or Float or Integer | + +{% admonition type="info" name="Searching by Category" %} +When searching for tickets by the **`category`** field, specific terms must be used instead of the category names: +* For **Customer** category tickets, use the term `request`. +* For **Back-office** category tickets, use the term `task`. +* For **Tracker** category tickets, use the term `tracker`. +{% /admonition %} + +### Accepted Operators + +{% admonition type="info" name="Searching based on `created_at`" %} + You may use the `<=` or `>=` operators to search by `created_at`. +{% /admonition %} +The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + +| Operator | Valid Types | Description | +| :------- | :----------------------------- | :----------------------------------------------------------- | +| = | All | Equals | +| != | All | Doesn't Equal | +| IN | All | In Shortcut for `OR` queries Values most be in Array | +| NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | +| > | Integer Date (UNIX Timestamp) | Greater (or equal) than | +| < | Integer Date (UNIX Timestamp) | Lower (or equal) than | +| ~ | String | Contains | +| !~ | String | Doesn't Contain | +| ^ | String | Starts With | +| $ | String | Ends With |
@@ -5188,16 +9299,49 @@ The only parameters you need to provide are the range of dates that you want exp
-
-
+
+
+ +```typescript +const pageableResponse = await client.tickets.search({ + query: { + operator: "AND", + value: [{ + field: "created_at", + operator: ">", + value: "1306054154" + }] + }, + pagination: { + per_page: 5 + } +}); +for await (const item of pageableResponse) { + console.log(item); +} + +// Or you can manually iterate page-by-page +let page = await client.tickets.search({ + query: { + operator: "AND", + value: [{ + field: "created_at", + operator: ">", + value: "1306054154" + }] + }, + pagination: { + per_page: 5 + } +}); +while (page.hasNextPage()) { + page = page.getNextPage(); +} + +// You can also access the underlying response +const response = page.response; -```typescript -await client.dataExport.create({ - created_at_after: 1719474967, - created_at_before: 1719492967, -}); ``` -
@@ -5211,26 +9355,28 @@ await client.dataExport.create({
-**request:** `Intercom.CreateDataExportRequest` - +**request:** `Intercom.SearchRequest` +
-**requestOptions:** `DataExport.RequestOptions` - +**requestOptions:** `TicketsClient.RequestOptions` +
+
-
client.dataExport.find({ ...params }) -> Intercom.DataExport +## Visitors +
client.visitors.find({ ...params }) -> Intercom.Visitor | undefined
@@ -5242,12 +9388,7 @@ await client.dataExport.create({
-You can view the status of your job by sending a `GET` request to the URL -`https://api.intercom.io/export/content/data/{job_identifier}` - the `{job_identifier}` is the value returned in the response when you first created the export job. More on it can be seen in the Export Job Model. - -> 🚧 Jobs expire after two days -> All jobs that have completed processing (and are thus available to download from the provided URL) will have an expiry limit of two days from when the export ob completed. After this, the data will no longer be available. - +You can fetch the details of a single visitor.
@@ -5262,11 +9403,11 @@ You can view the status of your job by sending a `GET` request to the URL
```typescript -await client.dataExport.find({ - job_identifier: "job_identifier", +await client.visitors.find({ + user_id: "user_id" }); -``` +```
@@ -5280,26 +9421,27 @@ await client.dataExport.find({
-**request:** `Intercom.FindDataExportRequest` - +**request:** `Intercom.FindVisitorRequest` +
-**requestOptions:** `DataExport.RequestOptions` - +**requestOptions:** `VisitorsClient.RequestOptions` +
+
-
client.dataExport.cancel({ ...params }) -> Intercom.DataExport +
client.visitors.update({ ...params }) -> Intercom.Visitor | undefined
@@ -5311,8 +9453,11 @@ await client.dataExport.find({
-You can cancel your job +Sending a PUT request to `/visitors` will result in an update of an existing Visitor. + +**Option 1.** You can update a visitor by passing in the `user_id` of the visitor in the Request body. +**Option 2.** You can update a visitor by passing in the `id` of the visitor in the Request body.
@@ -5327,11 +9472,12 @@ You can cancel your job
```typescript -await client.dataExport.cancel({ - job_identifier: "job_identifier", +await client.visitors.update({ + id: "6762f30c1bb69f9f2193bc5e", + name: "Gareth Bale" }); -``` +```
@@ -5345,26 +9491,27 @@ await client.dataExport.cancel({
-**request:** `Intercom.CancelDataExportRequest` - +**request:** `Intercom.UpdateVisitorRequest` +
-**requestOptions:** `DataExport.RequestOptions` - +**requestOptions:** `VisitorsClient.RequestOptions` +
+
-
client.dataExport.download({ ...params }) -> void +
client.visitors.mergeToContact({ ...params }) -> Intercom.Contact
@@ -5376,14 +9523,11 @@ await client.dataExport.cancel({
-When a job has a status of complete, and thus a filled download_url, you can download your data by hitting that provided URL, formatted like so: https://api.intercom.io/download/content/data/xyz1234. - -Your exported message data will be streamed continuously back down to you in a gzipped CSV format. +You can merge a Visitor to a Contact of role type `lead` or `user`. -> 📘 Octet header required +> 📘 What happens upon a visitor being converted? > -> You will have to specify the header Accept: `application/octet-stream` when hitting this endpoint. - +> If the User exists, then the Visitor will be merged into it, the Visitor deleted and the User returned. If the User does not exist, the Visitor will be converted to a User, with the User identifiers replacing it's Visitor identifiers.
@@ -5398,11 +9542,18 @@ Your exported message data will be streamed continuously back down to you in a g
```typescript -await client.dataExport.download({ - job_identifier: "job_identifier", +await client.visitors.mergeToContact({ + type: "user", + user: { + id: "8a88a590-e1c3-41e2-a502-e0649dbf721c", + email: "foo@bar.com" + }, + visitor: { + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3" + } }); -``` +```
@@ -5416,28 +9567,28 @@ await client.dataExport.download({
-**request:** `Intercom.DownloadDataExportRequest` - +**request:** `Intercom.MergeVisitorToContactRequest` +
-**requestOptions:** `DataExport.RequestOptions` - +**requestOptions:** `VisitorsClient.RequestOptions` +
+
-## Messages - -
client.messages.create({ ...params }) -> Intercom.Message +## HelpCenters Collections +
client.helpCenters.collections.list({ ...params }) -> core.Page
@@ -5449,18 +9600,9 @@ await client.dataExport.download({
-You can create a message that has been initiated by an admin. The conversation can be either an in-app message or an email. - -> 🚧 Sending for visitors -> -> There can be a short delay between when a contact is created and when a contact becomes available to be messaged through the API. A 404 Not Found error will be returned in this case. - -This will return the Message model that has been created. - -> 🚧 Retrieving Associated Conversations -> -> As this is a message, there will be no conversation present until the contact responds. Once they do, you will have to search for a contact's conversations with the id of the message. +You can fetch a list of all collections by making a GET request to `https://api.intercom.io/help_center/collections`. +Collections will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated collections first.
@@ -5475,22 +9617,21 @@ This will return the Message model that has been created.
```typescript -await client.messages.create({ - message_type: "email", - subject: "Thanks for everything", - body: "Hello there", - template: "plain", - from: { - type: "admin", - id: 394051, - }, - to: { - type: "user", - id: "536e564f316c83104c000020", - }, -}); -``` +const pageableResponse = await client.helpCenters.collections.list(); +for await (const item of pageableResponse) { + console.log(item); +} + +// Or you can manually iterate page-by-page +let page = await client.helpCenters.collections.list(); +while (page.hasNextPage()) { + page = page.getNextPage(); +} + +// You can also access the underlying response +const response = page.response; +```
@@ -5504,28 +9645,27 @@ await client.messages.create({
-**request:** `Intercom.CreateMessageRequest` - +**request:** `Intercom.helpCenters.ListCollectionsRequest` +
-**requestOptions:** `Messages.RequestOptions` - +**requestOptions:** `CollectionsClient.RequestOptions` +
+
-## Segments - -
client.segments.list({ ...params }) -> Intercom.SegmentList +
client.helpCenters.collections.create({ ...params }) -> Intercom.Collection
@@ -5537,8 +9677,7 @@ await client.messages.create({
-You can fetch a list of all segments. - +You can create a new collection by making a POST request to `https://api.intercom.io/help_center/collections.`
@@ -5553,9 +9692,11 @@ You can fetch a list of all segments.
```typescript -await client.segments.list(); -``` +await client.helpCenters.collections.create({ + name: "Thanks for everything" +}); +```
@@ -5569,26 +9710,27 @@ await client.segments.list();
-**request:** `Intercom.ListSegmentsRequest` - +**request:** `Intercom.helpCenters.CreateCollectionRequest` +
-**requestOptions:** `Segments.RequestOptions` - +**requestOptions:** `CollectionsClient.RequestOptions` +
+
-
client.segments.find({ ...params }) -> Intercom.Segment +
client.helpCenters.collections.find({ ...params }) -> Intercom.Collection
@@ -5600,8 +9742,7 @@ await client.segments.list();
-You can fetch the details of a single segment. - +You can fetch the details of a single collection by making a GET request to `https://api.intercom.io/help_center/collections/`.
@@ -5616,11 +9757,11 @@ You can fetch the details of a single segment.
```typescript -await client.segments.find({ - segment_id: "123", +await client.helpCenters.collections.find({ + collection_id: 1 }); -``` +```
@@ -5634,28 +9775,27 @@ await client.segments.find({
-**request:** `Intercom.FindSegmentRequest` - +**request:** `Intercom.helpCenters.FindCollectionRequest` +
-**requestOptions:** `Segments.RequestOptions` - +**requestOptions:** `CollectionsClient.RequestOptions` +
+
-## Subscription Types - -
client.subscriptionTypes.list() -> Intercom.SubscriptionTypeList +
client.helpCenters.collections.update({ ...params }) -> Intercom.Collection
@@ -5667,8 +9807,7 @@ await client.segments.find({
-You can list all subscription types. A list of subscription type objects will be returned. - +You can update the details of a single collection by making a PUT request to `https://api.intercom.io/collections/`.
@@ -5683,9 +9822,12 @@ You can list all subscription types. A list of subscription type objects will be
```typescript -await client.subscriptionTypes.list(); -``` +await client.helpCenters.collections.update({ + collection_id: 1, + name: "Update collection name" +}); +```
@@ -5699,20 +9841,27 @@ await client.subscriptionTypes.list();
-**requestOptions:** `SubscriptionTypes.RequestOptions` +**request:** `Intercom.helpCenters.UpdateCollectionRequest` + +
+
+ +
+
+**requestOptions:** `CollectionsClient.RequestOptions` +
+
-## PhoneCallRedirects - -
client.phoneCallRedirects.create({ ...params }) -> Intercom.PhoneSwitch +
client.helpCenters.collections.delete({ ...params }) -> Intercom.DeletedCollectionObject
@@ -5724,11 +9873,7 @@ await client.subscriptionTypes.list();
-You can use the API to deflect phone calls to the Intercom Messenger. -Calling this endpoint will send an SMS with a link to the Messenger to the phone number specified. - -If custom attributes are specified, they will be added to the user or lead's custom data attributes. - +You can delete a single collection by making a DELETE request to `https://api.intercom.io/collections/`.
@@ -5743,15 +9888,11 @@ If custom attributes are specified, they will be added to the user or lead's cus
```typescript -await client.phoneCallRedirects.create({ - phone: "+353832345678", - custom_attributes: { - issue_type: "Billing", - priority: "High", - }, +await client.helpCenters.collections.delete({ + collection_id: 1 }); -``` +```
@@ -5765,28 +9906,28 @@ await client.phoneCallRedirects.create({
-**request:** `Intercom.CreatePhoneCallRedirectRequest` - +**request:** `Intercom.helpCenters.DeleteCollectionRequest` +
-**requestOptions:** `PhoneCallRedirects.RequestOptions` - +**requestOptions:** `CollectionsClient.RequestOptions` +
+
-## Teams - -
client.teams.list() -> Intercom.TeamList +## News Items +
client.news.items.list() -> Intercom.PaginatedResponse
@@ -5798,8 +9939,7 @@ await client.phoneCallRedirects.create({
-This will return a list of team objects for the App. - +You can fetch a list of all news items
@@ -5814,9 +9954,9 @@ This will return a list of team objects for the App.
```typescript -await client.teams.list(); -``` +await client.news.items.list(); +```
@@ -5830,18 +9970,19 @@ await client.teams.list();
-**requestOptions:** `Teams.RequestOptions` - +**requestOptions:** `ItemsClient.RequestOptions` +
+
-
client.teams.find({ ...params }) -> Intercom.Team +
client.news.items.create({ ...params }) -> Intercom.NewsItem
@@ -5853,8 +9994,7 @@ await client.teams.list();
-You can fetch the details of a single team, containing an array of admins that belong to this team. - +You can create a news item
@@ -5869,11 +10009,21 @@ You can fetch the details of a single team, containing an array of admins that b
```typescript -await client.teams.find({ - team_id: "123", +await client.news.items.create({ + title: "Halloween is here!", + body: "

New costumes in store for this spooky season

", + sender_id: 991267834, + state: "live", + deliver_silently: true, + labels: ["Product", "Update", "New"], + reactions: ["\uD83D\uDE06", "\uD83D\uDE05"], + newsfeed_assignments: [{ + newsfeed_id: 53, + published_at: 1664638214 + }] }); -``` +```
@@ -5887,28 +10037,27 @@ await client.teams.find({
-**request:** `Intercom.FindTeamRequest` - +**request:** `Intercom.NewsItemRequest` +
-**requestOptions:** `Teams.RequestOptions` - +**requestOptions:** `ItemsClient.RequestOptions` +
+
-## Ticket Types - -
client.ticketTypes.list() -> Intercom.TicketTypeList +
client.news.items.find({ ...params }) -> Intercom.NewsItem
@@ -5920,8 +10069,7 @@ await client.teams.find({
-You can get a list of all ticket types for a workspace. - +You can fetch the details of a single news item.
@@ -5936,9 +10084,11 @@ You can get a list of all ticket types for a workspace.
```typescript -await client.ticketTypes.list(); -``` +await client.news.items.find({ + news_item_id: 1 +}); +```
@@ -5952,41 +10102,30 @@ await client.ticketTypes.list();
-**requestOptions:** `TicketTypes.RequestOptions` +**request:** `Intercom.news.FindNewsItemRequest` + +
+
+ +
+
+**requestOptions:** `ItemsClient.RequestOptions` +
+
-
client.ticketTypes.create({ ...params }) -> Intercom.TicketType -
-
- -#### 📝 Description - -
-
- +
client.news.items.update({ ...params }) -> Intercom.NewsItem
-You can create a new ticket type. - -> 📘 Creating ticket types. -> -> Every ticket type will be created with two default attributes: _default_title_ and _default_description_. -> For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) - -
-
-
-
- #### 🔌 Usage
@@ -5996,14 +10135,17 @@ You can create a new ticket type.
```typescript -await client.ticketTypes.create({ - name: "Customer Issue", - description: "Customer Report Template", - category: "Customer", - icon: "\uD83C\uDF9F\uFE0F", +await client.news.items.update({ + news_item_id: 1, + body: { + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"] + } }); -``` +```
@@ -6017,26 +10159,27 @@ await client.ticketTypes.create({
-**request:** `Intercom.CreateTicketTypeRequest` - +**request:** `Intercom.news.UpdateNewsItemRequest` +
-**requestOptions:** `TicketTypes.RequestOptions` - +**requestOptions:** `ItemsClient.RequestOptions` +
+
-
client.ticketTypes.get({ ...params }) -> Intercom.TicketType +
client.news.items.delete({ ...params }) -> Intercom.DeletedObject
@@ -6048,8 +10191,7 @@ await client.ticketTypes.create({
-You can fetch the details of a single ticket type. - +You can delete a single news item.
@@ -6064,11 +10206,11 @@ You can fetch the details of a single ticket type.
```typescript -await client.ticketTypes.get({ - ticket_type_id: "ticket_type_id", +await client.news.items.delete({ + news_item_id: 1 }); -``` +```
@@ -6082,26 +10224,28 @@ await client.ticketTypes.get({
-**request:** `Intercom.FindTicketTypeRequest` - +**request:** `Intercom.news.DeleteNewsItemRequest` +
-**requestOptions:** `TicketTypes.RequestOptions` - +**requestOptions:** `ItemsClient.RequestOptions` +
+
-
client.ticketTypes.update({ ...params }) -> Intercom.TicketType +## News Feeds +
client.news.feeds.listItems({ ...params }) -> Intercom.PaginatedResponse
@@ -6113,12 +10257,7 @@ await client.ticketTypes.get({
-You can update a ticket type. - -> 📘 Updating a ticket type. -> -> For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) - +You can fetch a list of all news items that are live on a given newsfeed
@@ -6133,12 +10272,11 @@ You can update a ticket type.
```typescript -await client.ticketTypes.update({ - ticket_type_id: "ticket_type_id", - name: "Bug Report 2", +await client.news.feeds.listItems({ + newsfeed_id: "123" }); -``` +```
@@ -6152,28 +10290,27 @@ await client.ticketTypes.update({
-**request:** `Intercom.UpdateTicketTypeRequest` - +**request:** `Intercom.news.ListNewsFeedItemsRequest` +
-**requestOptions:** `TicketTypes.RequestOptions` - +**requestOptions:** `FeedsClient.RequestOptions` +
+
-## Tickets - -
client.tickets.reply({ ...params }) -> Intercom.TicketReply +
client.news.feeds.list() -> Intercom.PaginatedResponse
@@ -6185,8 +10322,7 @@ await client.ticketTypes.update({
-You can reply to a ticket with a message from an admin or on behalf of a contact, or with a note for admins. - +You can fetch a list of all newsfeeds
@@ -6201,17 +10337,9 @@ You can reply to a ticket with a message from an admin or on behalf of a contact
```typescript -await client.tickets.reply({ - ticket_id: "123", - body: { - message_type: "comment", - type: "user", - body: "Thanks again :)", - intercom_user_id: "667d619d8a68186f43bafe82", - }, -}); -``` +await client.news.feeds.list(); +```
@@ -6225,26 +10353,19 @@ await client.tickets.reply({
-**request:** `Intercom.ReplyToTicketRequest` - -
-
- -
-
- -**requestOptions:** `Tickets.RequestOptions` - +**requestOptions:** `FeedsClient.RequestOptions` +
+
-
client.tickets.create({ ...params }) -> Intercom.Ticket +
client.news.feeds.find({ ...params }) -> Intercom.Newsfeed
@@ -6256,8 +10377,7 @@ await client.tickets.reply({
-You can create a new ticket. - +You can fetch the details of a single newsfeed
@@ -6272,20 +10392,11 @@ You can create a new ticket.
```typescript -await client.tickets.create({ - ticket_type_id: "1234", - contacts: [ - { - id: "667d61b78a68186f43bafe8d", - }, - ], - ticket_attributes: { - _default_title_: "example", - _default_description_: "there is a problem", - }, +await client.news.feeds.find({ + newsfeed_id: "123" }); -``` +```
@@ -6299,26 +10410,28 @@ await client.tickets.create({
-**request:** `Intercom.CreateTicketRequest` - +**request:** `Intercom.news.FindNewsFeedRequest` +
-**requestOptions:** `Tickets.RequestOptions` - +**requestOptions:** `FeedsClient.RequestOptions` +
+
-
client.tickets.get({ ...params }) -> Intercom.Ticket +## TicketTypes Attributes +
client.ticketTypes.attributes.create({ ...params }) -> Intercom.TicketTypeAttribute | undefined
@@ -6330,8 +10443,7 @@ await client.tickets.create({
-You can fetch the details of a single ticket. - +You can create a new attribute for a ticket type.
@@ -6346,11 +10458,15 @@ You can fetch the details of a single ticket.
```typescript -await client.tickets.get({ - ticket_id: "ticket_id", +await client.ticketTypes.attributes.create({ + ticket_type_id: "ticket_type_id", + name: "Attribute Title", + description: "Attribute Description", + data_type: "string", + required_to_create: false }); -``` +```
@@ -6364,26 +10480,27 @@ await client.tickets.get({
-**request:** `Intercom.FindTicketRequest` - +**request:** `Intercom.ticketTypes.CreateTicketTypeAttributeRequest` +
-**requestOptions:** `Tickets.RequestOptions` - +**requestOptions:** `AttributesClient.RequestOptions` +
+
-
client.tickets.update({ ...params }) -> Intercom.Ticket +
client.ticketTypes.attributes.update({ ...params }) -> Intercom.TicketTypeAttribute | undefined
@@ -6395,8 +10512,7 @@ await client.tickets.get({
-You can update a ticket. - +You can update an existing attribute for a ticket type.
@@ -6411,22 +10527,13 @@ You can update a ticket.
```typescript -await client.tickets.update({ - ticket_id: "ticket_id", - ticket_attributes: { - _default_title_: "example", - _default_description_: "there is a problem", - }, - state: "in_progress", - open: true, - snoozed_until: 1673609604, - assignment: { - admin_id: "991267883", - assignee_id: "991267885", - }, +await client.ticketTypes.attributes.update({ + ticket_type_id: "ticket_type_id", + attribute_id: "attribute_id", + description: "New Attribute Description" }); -``` +```
@@ -6440,26 +10547,28 @@ await client.tickets.update({
-**request:** `Intercom.UpdateTicketRequest` - +**request:** `Intercom.ticketTypes.UpdateTicketTypeAttributeRequest` +
-**requestOptions:** `Tickets.RequestOptions` - +**requestOptions:** `AttributesClient.RequestOptions` +
+
-
client.tickets.search({ ...params }) -> core.Page +## Admins +
client.unstable.admins.identifyAdmin() -> Intercom.AdminWithApp | undefined
@@ -6471,69 +10580,12 @@ await client.tickets.update({
-You can search for multiple tickets by the value of their attributes in order to fetch exactly which ones you want. - -To search for tickets, you send a `POST` request to `https://api.intercom.io/tickets/search`. - -This will accept a query object in the body which will define your filters. -{% admonition type="warning" name="Optimizing search queries" %} -Search queries can be complex, so optimizing them can help the performance of your search. -Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize -pagination to limit the number of results returned. The default is `20` results per page. -See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. -{% /admonition %} - -### Nesting & Limitations - -You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). -There are some limitations to the amount of multiples there can be: - -- There's a limit of max 2 nested filters -- There's a limit of max 15 filters for each AND or OR group - -### Accepted Fields - -Most keys listed as part of the Ticket model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foobar"`). - -| Field | Type | -| :-------------------- | :------------------------------------------------------------- | -| id | String | -| created_at | Date (UNIX timestamp) | -| updated_at | Date (UNIX timestamp) | -| _default_title_ | String | -| _default_description_ | String | -| category | String | -| ticket_type_id | String | -| contact_ids | String | -| teammate_ids | String | -| admin_assignee_id | String | -| team_assignee_id | String | -| open | Boolean | -| state | String | -| snoozed_until | Date (UNIX timestamp) | -| ticket_attribute.{id} | String or Boolean or Date (UNIX timestamp) or Float or Integer | - -### Accepted Operators - -{% admonition type="info" name="Searching based on `created_at`" %} -You may use the `<=` or `>=` operators to search by `created_at`. -{% /admonition %} -The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). - -| Operator | Valid Types | Description | -| :------- | :---------------------------- | :--------------------------------------------------------- | -| = | All | Equals | -| != | All | Doesn't Equal | -| IN | All | In Shortcut for `OR` queries Values most be in Array | -| NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | -| > | Integer Date (UNIX Timestamp) | Greater (or equal) than | -| < | Integer Date (UNIX Timestamp) | Lower (or equal) than | -| ~ | String | Contains | -| !~ | String | Doesn't Contain | -| ^ | String | Starts With | -| $ | String | Ends With | +You can view the currently authorised admin along with the embedded app object (a "workspace" in legacy terminology). +> 🚧 Single Sign On +> +> If you are building a custom "Log in with Intercom" flow for your site, and you call the `/me` endpoint to identify the logged-in user, you should not accept any sign-ins from users with unverified email addresses as it poses a potential impersonation security risk.
@@ -6548,46 +10600,9 @@ The table below shows the operators you can use to define how you want to search
```typescript -const response = await client.tickets.search({ - query: { - operator: "AND", - value: [ - { - field: "created_at", - operator: ">", - value: "1306054154", - }, - ], - }, - pagination: { - per_page: 5, - }, -}); -for await (const item of response) { - console.log(item); -} +await client.unstable.admins.identifyAdmin(); -// Or you can manually iterate page-by-page -const page = await client.tickets.search({ - query: { - operator: "AND", - value: [ - { - field: "created_at", - operator: ">", - value: "1306054154", - }, - ], - }, - pagination: { - per_page: 5, - }, -}); -while (page.hasNextPage()) { - page = page.getNextPage(); -} ``` -
@@ -6601,28 +10616,19 @@ while (page.hasNextPage()) {
-**request:** `Intercom.SearchRequest` - -
-
- -
-
- -**requestOptions:** `Tickets.RequestOptions` - +**requestOptions:** `AdminsClient.RequestOptions` +
+
-## Visitors - -
client.visitors.find({ ...params }) -> Intercom.Visitor +
client.unstable.admins.setAwayAdmin({ ...params }) -> Intercom.Admin | undefined
@@ -6634,8 +10640,7 @@ while (page.hasNextPage()) {
-You can fetch the details of a single visitor. - +You can set an Admin as away for the Inbox.
@@ -6650,11 +10655,14 @@ You can fetch the details of a single visitor.
```typescript -await client.visitors.find({ - user_id: "user_id", +await client.unstable.admins.setAwayAdmin({ + id: 1, + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345 }); -``` +```
@@ -6668,26 +10676,27 @@ await client.visitors.find({
-**request:** `Intercom.FindVisitorRequest` - +**request:** `Intercom.unstable.SetAwayAdminRequest` +
-**requestOptions:** `Visitors.RequestOptions` - +**requestOptions:** `AdminsClient.RequestOptions` +
+
-
client.visitors.update({ ...params }) -> Intercom.Visitor +
client.unstable.admins.listActivityLogs({ ...params }) -> Intercom.ActivityLogList
@@ -6699,12 +10708,7 @@ await client.visitors.find({
-Sending a PUT request to `/visitors` will result in an update of an existing Visitor. - -**Option 1.** You can update a visitor by passing in the `user_id` of the visitor in the Request body. - -**Option 2.** You can update a visitor by passing in the `id` of the visitor in the Request body. - +You can get a log of activities by all admins in an app.
@@ -6719,12 +10723,12 @@ Sending a PUT request to `/visitors` will result in an update of an existing Vis
```typescript -await client.visitors.update({ - id: "667d61cc8a68186f43bafe95", - name: "Gareth Bale", +await client.unstable.admins.listActivityLogs({ + created_at_after: "1677253093", + created_at_before: "1677861493" }); -``` +```
@@ -6738,26 +10742,27 @@ await client.visitors.update({
-**request:** `Intercom.UpdateVisitorRequest` - +**request:** `Intercom.unstable.ListActivityLogsRequest` +
-**requestOptions:** `Visitors.RequestOptions` - +**requestOptions:** `AdminsClient.RequestOptions` +
+
-
client.visitors.mergeToContact({ ...params }) -> Intercom.Contact +
client.unstable.admins.listAdmins() -> Intercom.AdminList
@@ -6769,12 +10774,7 @@ await client.visitors.update({
-You can merge a Visitor to a Contact of role type `lead` or `user`. - -> 📘 What happens upon a visitor being converted? -> -> If the User exists, then the Visitor will be merged into it, the Visitor deleted and the User returned. If the User does not exist, the Visitor will be converted to a User, with the User identifiers replacing it's Visitor identifiers. - +You can fetch a list of admins for a given workspace.
@@ -6789,18 +10789,9 @@ You can merge a Visitor to a Contact of role type `lead` or `user`.
```typescript -await client.visitors.mergeToContact({ - type: "user", - user: { - id: "8a88a590-e1c3-41e2-a502-e0649dbf721c", - email: "foo@bar.com", - }, - visitor: { - user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", - }, -}); -``` +await client.unstable.admins.listAdmins(); +```
@@ -6814,28 +10805,19 @@ await client.visitors.mergeToContact({
-**request:** `Intercom.MergeVisitorToContactRequest` - -
-
- -
-
- -**requestOptions:** `Visitors.RequestOptions` - +**requestOptions:** `AdminsClient.RequestOptions` +
+
-## HelpCenters Collections - -
client.helpCenters.collections.list({ ...params }) -> core.Page +
client.unstable.admins.retrieveAdmin({ ...params }) -> Intercom.Admin | undefined
@@ -6847,10 +10829,7 @@ await client.visitors.mergeToContact({
-You can fetch a list of all collections by making a GET request to `https://api.intercom.io/help_center/collections`. - -Collections will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated collections first. - +You can retrieve the details of a single admin.
@@ -6865,18 +10844,11 @@ Collections will be returned in descending order on the `updated_at` attribute.
```typescript -const response = await client.helpCenters.collections.list(); -for await (const item of response) { - console.log(item); -} +await client.unstable.admins.retrieveAdmin({ + id: 1 +}); -// Or you can manually iterate page-by-page -const page = await client.helpCenters.collections.list(); -while (page.hasNextPage()) { - page = page.getNextPage(); -} ``` -
@@ -6890,26 +10862,28 @@ while (page.hasNextPage()) {
-**request:** `Intercom.helpCenters.ListCollectionsRequest` - +**request:** `Intercom.unstable.RetrieveAdminRequest` +
-**requestOptions:** `Collections.RequestOptions` - +**requestOptions:** `AdminsClient.RequestOptions` +
+
-
client.helpCenters.collections.create({ ...params }) -> Intercom.Collection +## AI Content +
client.unstable.aiContent.listContentImportSources() -> Intercom.ContentImportSourcesList
@@ -6921,8 +10895,7 @@ while (page.hasNextPage()) {
-You can create a new collection by making a POST request to `https://api.intercom.io/help_center/collections.` - +You can retrieve a list of all content import sources for a workspace.
@@ -6937,11 +10910,9 @@ You can create a new collection by making a POST request to `https://api.interco
```typescript -await client.helpCenters.collections.create({ - name: "Thanks for everything", -}); -``` +await client.unstable.aiContent.listContentImportSources(); +```
@@ -6955,26 +10926,19 @@ await client.helpCenters.collections.create({
-**request:** `Intercom.helpCenters.CreateCollectionRequest` - -
-
- -
-
- -**requestOptions:** `Collections.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.helpCenters.collections.find({ ...params }) -> Intercom.Collection +
client.unstable.aiContent.createContentImportSource({ ...params }) -> Intercom.ContentImportSource
@@ -6986,8 +10950,7 @@ await client.helpCenters.collections.create({
-You can fetch the details of a single collection by making a GET request to `https://api.intercom.io/help_center/collections/`. - +You can create a new content import source by sending a POST request to this endpoint.
@@ -7002,11 +10965,11 @@ You can fetch the details of a single collection by making a GET request to `htt
```typescript -await client.helpCenters.collections.find({ - collection_id: "123", +await client.unstable.aiContent.createContentImportSource({ + url: "https://www.example.com" }); -``` +```
@@ -7020,44 +10983,30 @@ await client.helpCenters.collections.find({
-**request:** `Intercom.helpCenters.FindCollectionRequest` - +**request:** `Intercom.unstable.CreateContentImportSourceRequest` +
-**requestOptions:** `Collections.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.helpCenters.collections.update({ ...params }) -> Intercom.Collection -
-
- -#### 📝 Description - -
-
- +
client.unstable.aiContent.getContentImportSource({ ...params }) -> Intercom.ContentImportSource
-You can update the details of a single collection by making a PUT request to `https://api.intercom.io/collections/`. - -
-
-
-
- #### 🔌 Usage
@@ -7067,12 +11016,11 @@ You can update the details of a single collection by making a PUT request to `ht
```typescript -await client.helpCenters.collections.update({ - collection_id: "123", - name: "Update collection name", +await client.unstable.aiContent.getContentImportSource({ + id: "id" }); -``` +```
@@ -7086,26 +11034,27 @@ await client.helpCenters.collections.update({
-**request:** `Intercom.helpCenters.UpdateCollectionRequest` - +**request:** `Intercom.unstable.GetContentImportSourceRequest` +
-**requestOptions:** `Collections.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.helpCenters.collections.delete({ ...params }) -> Intercom.DeletedCollectionObject +
client.unstable.aiContent.updateContentImportSource({ ...params }) -> Intercom.ContentImportSource
@@ -7117,8 +11066,7 @@ await client.helpCenters.collections.update({
-You can delete a single collection by making a DELETE request to `https://api.intercom.io/collections/`. - +You can update an existing content import source.
@@ -7133,11 +11081,13 @@ You can delete a single collection by making a DELETE request to `https://api.in
```typescript -await client.helpCenters.collections.delete({ - collection_id: "123", +await client.unstable.aiContent.updateContentImportSource({ + id: "id", + sync_behavior: "api", + url: "https://www.example.com" }); -``` +```
@@ -7151,28 +11101,27 @@ await client.helpCenters.collections.delete({
-**request:** `Intercom.helpCenters.DeleteCollectionRequest` - +**request:** `Intercom.unstable.UpdateContentImportSourceRequest` +
-**requestOptions:** `Collections.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-## News Items - -
client.news.items.list() -> Intercom.PaginatedNewsItemResponse +
client.unstable.aiContent.deleteContentImportSource({ ...params }) -> void
@@ -7184,8 +11133,7 @@ await client.helpCenters.collections.delete({
-You can fetch a list of all news items - +You can delete a content import source by making a DELETE request this endpoint. This will also delete all external pages that were imported from this source.
@@ -7200,9 +11148,11 @@ You can fetch a list of all news items
```typescript -await client.news.items.list(); -``` +await client.unstable.aiContent.deleteContentImportSource({ + id: "id" +}); +```
@@ -7216,18 +11166,27 @@ await client.news.items.list();
-**requestOptions:** `Items.RequestOptions` +**request:** `Intercom.unstable.DeleteContentImportSourceRequest` + +
+
+ +
+
+**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.news.items.create({ ...params }) -> Intercom.NewsItem +
client.unstable.aiContent.listExternalPages() -> Intercom.ExternalPagesList
@@ -7239,8 +11198,7 @@ await client.news.items.list();
-You can create a news item - +You can retrieve a list of all external pages for a workspace.
@@ -7255,23 +11213,9 @@ You can create a news item
```typescript -await client.news.items.create({ - title: "Halloween is here!", - body: "

New costumes in store for this spooky season

", - sender_id: 991267734, - state: "live", - deliver_silently: true, - labels: ["Product", "Update", "New"], - reactions: ["\uD83D\uDE06", "\uD83D\uDE05"], - newsfeed_assignments: [ - { - newsfeed_id: 53, - published_at: 1664638214, - }, - ], -}); -``` +await client.unstable.aiContent.listExternalPages(); +```
@@ -7285,26 +11229,19 @@ await client.news.items.create({
-**request:** `Intercom.NewsItemRequest` - -
-
- -
-
- -**requestOptions:** `Items.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.news.items.find({ ...params }) -> Intercom.NewsItem +
client.unstable.aiContent.createExternalPage({ ...params }) -> Intercom.ExternalPage
@@ -7316,8 +11253,7 @@ await client.news.items.create({
-You can fetch the details of a single news item. - +You can create a new external page by sending a POST request to this endpoint. If an external page already exists with the specified source_id and external_id, it will be updated instead.
@@ -7332,11 +11268,15 @@ You can fetch the details of a single news item.
```typescript -await client.news.items.find({ - news_item_id: "123", +await client.unstable.aiContent.createExternalPage({ + title: "Test", + html: "

Test

", + url: "https://www.example.com", + source_id: 44, + external_id: "abc1234" }); -``` +```
@@ -7350,29 +11290,44 @@ await client.news.items.find({
-**request:** `Intercom.news.FindNewsItemRequest` - +**request:** `Intercom.unstable.CreateExternalPageRequest` +
-**requestOptions:** `Items.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.news.items.update({ ...params }) -> Intercom.NewsItem +
client.unstable.aiContent.getExternalPage({ ...params }) -> Intercom.ExternalPage +
+
+ +#### 📝 Description + +
+
+
+You can retrieve an external page. +
+
+
+
+ #### 🔌 Usage
@@ -7382,17 +11337,11 @@ await client.news.items.find({
```typescript -await client.news.items.update({ - news_item_id: "123", - body: { - title: "Christmas is here!", - body: "

New gifts in store for the jolly season

", - sender_id: 991267745, - reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"], - }, +await client.unstable.aiContent.getExternalPage({ + id: "id" }); -``` +```
@@ -7406,26 +11355,27 @@ await client.news.items.update({
-**request:** `Intercom.news.UpdateNewsItemRequest` - +**request:** `Intercom.unstable.GetExternalPageRequest` +
-**requestOptions:** `Items.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.news.items.delete({ ...params }) -> Intercom.DeletedObject +
client.unstable.aiContent.updateExternalPage({ ...params }) -> Intercom.ExternalPage
@@ -7437,8 +11387,7 @@ await client.news.items.update({
-You can delete a single news item. - +You can update an existing external page (if it was created via the API).
@@ -7453,11 +11402,16 @@ You can delete a single news item.
```typescript -await client.news.items.delete({ - news_item_id: "123", +await client.unstable.aiContent.updateExternalPage({ + id: "id", + title: "Test", + html: "

Test

", + url: "https://www.example.com", + source_id: 47, + external_id: "5678" }); -``` +```
@@ -7471,28 +11425,27 @@ await client.news.items.delete({
-**request:** `Intercom.news.DeleteNewsItemRequest` - +**request:** `Intercom.unstable.UpdateExternalPageRequest` +
-**requestOptions:** `Items.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-## News Feeds - -
client.news.feeds.listItems({ ...params }) -> Intercom.PaginatedNewsItemResponse +
client.unstable.aiContent.deleteExternalPage({ ...params }) -> Intercom.ExternalPage
@@ -7504,8 +11457,7 @@ await client.news.items.delete({
-You can fetch a list of all news items that are live on a given newsfeed - +Sending a DELETE request for an external page will remove it from the content library UI and from being used for AI answers.
@@ -7520,11 +11472,11 @@ You can fetch a list of all news items that are live on a given newsfeed
```typescript -await client.news.feeds.listItems({ - newsfeed_id: "123", +await client.unstable.aiContent.deleteExternalPage({ + id: "id" }); -``` +```
@@ -7538,26 +11490,28 @@ await client.news.feeds.listItems({
-**request:** `Intercom.news.ListNewsFeedItemsRequest` - +**request:** `Intercom.unstable.DeleteExternalPageRequest` +
-**requestOptions:** `Feeds.RequestOptions` - +**requestOptions:** `AiContentClient.RequestOptions` +
+
-
client.news.feeds.list() -> Intercom.PaginatedNewsfeedResponse +## Articles +
client.unstable.articles.listArticles() -> Intercom.ArticleList
@@ -7569,8 +11523,11 @@ await client.news.feeds.listItems({
-You can fetch a list of all newsfeeds +You can fetch a list of all articles by making a GET request to `https://api.intercom.io/articles`. +> 📘 How are the articles sorted and ordered? +> +> Articles will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated articles first.
@@ -7585,9 +11542,9 @@ You can fetch a list of all newsfeeds
```typescript -await client.news.feeds.list(); -``` +await client.unstable.articles.listArticles(); +```
@@ -7601,18 +11558,19 @@ await client.news.feeds.list();
-**requestOptions:** `Feeds.RequestOptions` - +**requestOptions:** `ArticlesClient.RequestOptions` +
+
-
client.news.feeds.find({ ...params }) -> Intercom.Newsfeed +
client.unstable.articles.createArticle({ ...params }) -> Intercom.Article
@@ -7624,8 +11582,7 @@ await client.news.feeds.list();
-You can fetch the details of a single newsfeed - +You can create a new article by making a POST request to `https://api.intercom.io/articles`.
@@ -7640,11 +11597,11 @@ You can fetch the details of a single newsfeed
```typescript -await client.news.feeds.find({ - newsfeed_id: "123", +await client.unstable.articles.createArticle({ + "key": "value" }); -``` +```
@@ -7658,28 +11615,27 @@ await client.news.feeds.find({
-**request:** `Intercom.news.FindNewsFeedRequest` - +**request:** `unknown` +
-**requestOptions:** `Feeds.RequestOptions` - +**requestOptions:** `ArticlesClient.RequestOptions` +
+
-## TicketTypes Attributes - -
client.ticketTypes.attributes.create({ ...params }) -> Intercom.TicketTypeAttribute +
client.unstable.articles.retrieveArticle({ ...params }) -> Intercom.Article
@@ -7691,8 +11647,7 @@ await client.news.feeds.find({
-You can create a new attribute for a ticket type. - +You can fetch the details of a single article by making a GET request to `https://api.intercom.io/articles/`.
@@ -7707,15 +11662,11 @@ You can create a new attribute for a ticket type.
```typescript -await client.ticketTypes.attributes.create({ - ticket_type_id: "ticket_type_id", - name: "Attribute Title", - description: "Attribute Description", - data_type: "string", - required_to_create: false, +await client.unstable.articles.retrieveArticle({ + id: 1 }); -``` +```
@@ -7729,26 +11680,27 @@ await client.ticketTypes.attributes.create({
-**request:** `Intercom.ticketTypes.CreateTicketTypeAttributeRequest` - +**request:** `Intercom.unstable.RetrieveArticleRequest` +
-**requestOptions:** `Attributes.RequestOptions` - +**requestOptions:** `ArticlesClient.RequestOptions` +
+
-
client.ticketTypes.attributes.update({ ...params }) -> Intercom.TicketTypeAttribute +
client.unstable.articles.deleteArticle({ ...params }) -> Intercom.DeletedArticleObject
@@ -7760,8 +11712,7 @@ await client.ticketTypes.attributes.create({
-You can update an existing attribute for a ticket type. - +You can delete a single article by making a DELETE request to `https://api.intercom.io/articles/`.
@@ -7776,13 +11727,11 @@ You can update an existing attribute for a ticket type.
```typescript -await client.ticketTypes.attributes.update({ - ticket_type_id: "ticket_type_id", - attribute_id: "attribute_id", - description: "New Attribute Description", +await client.unstable.articles.deleteArticle({ + id: 1 }); -``` +```
@@ -7796,28 +11745,27 @@ await client.ticketTypes.attributes.update({
-**request:** `Intercom.ticketTypes.UpdateTicketTypeAttributeRequest` - +**request:** `Intercom.unstable.DeleteArticleRequest` +
-**requestOptions:** `Attributes.RequestOptions` - +**requestOptions:** `ArticlesClient.RequestOptions` +
+
-## Admins - -
client.unstable.admins.identifyAdmin() -> Intercom.AdminWithApp | undefined +
client.unstable.articles.searchArticles({ ...params }) -> Intercom.ArticleSearchResponse
@@ -7829,12 +11777,7 @@ await client.ticketTypes.attributes.update({
-You can view the currently authorised admin along with the embedded app object (a "workspace" in legacy terminology). - -> 🚧 Single Sign On -> -> If you are building a custom "Log in with Intercom" flow for your site, and you call the `/me` endpoint to identify the logged-in user, you should not accept any sign-ins from users with unverified email addresses as it poses a potential impersonation security risk. - +You can search for articles by making a GET request to `https://api.intercom.io/articles/search`.
@@ -7849,9 +11792,14 @@ You can view the currently authorised admin along with the embedded app object (
```typescript -await client.unstable.admins.identifyAdmin(); -``` +await client.unstable.articles.searchArticles({ + phrase: "Getting started", + state: "published", + help_center_id: 1, + highlight: true +}); +```
@@ -7865,18 +11813,28 @@ await client.unstable.admins.identifyAdmin();
-**requestOptions:** `Admins.RequestOptions` - +**request:** `Intercom.unstable.SearchArticlesRequest` + +
+
+ +
+
+ +**requestOptions:** `ArticlesClient.RequestOptions` +
+
-
client.unstable.admins.setAwayAdmin({ ...params }) -> Intercom.Admin | undefined +## Away Status Reasons +
client.unstable.awayStatusReasons.listAwayStatusReasons() -> Intercom.AwayStatusReason[]
@@ -7888,8 +11846,7 @@ await client.unstable.admins.identifyAdmin();
-You can set an Admin as away for the Inbox. - +Returns a list of all away status reasons configured for the workspace, including deleted ones.
@@ -7904,14 +11861,9 @@ You can set an Admin as away for the Inbox.
```typescript -await client.unstable.admins.setAwayAdmin({ - id: 1, - away_mode_enabled: true, - away_mode_reassign: true, - away_status_reason_id: 12345, -}); -``` +await client.unstable.awayStatusReasons.listAwayStatusReasons(); +```
@@ -7925,30 +11877,24 @@ await client.unstable.admins.setAwayAdmin({
-**request:** `Intercom.unstable.SetAwayAdminRequest` - -
-
- -
-
- -**requestOptions:** `Admins.RequestOptions` - +**requestOptions:** `AwayStatusReasonsClient.RequestOptions` +
+
-
client.unstable.admins.listActivityLogs({ ...params }) -> Intercom.ActivityLogList +## Unstable Export +
client.unstable.export.enqueueANewReportingDataExportJob({ ...params }) -> Intercom.PostExportReportingDataEnqueueResponse
-#### 📝 Description +#### 🔌 Usage
@@ -7956,14 +11902,21 @@ await client.unstable.admins.setAwayAdmin({
-You can get a log of activities by all admins in an app. +```typescript +await client.unstable.export.enqueueANewReportingDataExportJob({ + dataset_id: "conversation", + attribute_ids: ["conversation_id", "conversation_started_at"], + start_time: 1717490000, + end_time: 1717510000 +}); +```
-#### 🔌 Usage +#### ⚙️ Parameters
@@ -7971,19 +11924,31 @@ You can get a log of activities by all admins in an app.
-```typescript -await client.unstable.admins.listActivityLogs({ - created_at_after: "1677253093", - created_at_before: "1677861493", -}); -``` +**request:** `Intercom.unstable.PostExportReportingDataEnqueueRequest` + +
+
+ +
+
+**requestOptions:** `ExportClient.RequestOptions` +
-#### ⚙️ Parameters + +
+
+
+ +
client.unstable.export.listAvailableDatasetsAndAttributes() -> Intercom.GetExportReportingDataGetDatasetsResponse +
+
+ +#### 🔌 Usage
@@ -7991,26 +11956,37 @@ await client.unstable.admins.listActivityLogs({
-**request:** `Intercom.unstable.ListActivityLogsRequest` +```typescript +await client.unstable.export.listAvailableDatasetsAndAttributes(); +``` +
+
+#### ⚙️ Parameters +
-**requestOptions:** `Admins.RequestOptions` +
+
+**requestOptions:** `ExportClient.RequestOptions` +
+
-
client.unstable.admins.listAdmins() -> Intercom.AdminList +## Help Center +
client.unstable.helpCenter.listAllCollections() -> Intercom.CollectionList
@@ -8022,8 +11998,9 @@ await client.unstable.admins.listActivityLogs({
-You can fetch a list of admins for a given workspace. +You can fetch a list of all collections by making a GET request to `https://api.intercom.io/help_center/collections`. +Collections will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated collections first.
@@ -8038,9 +12015,9 @@ You can fetch a list of admins for a given workspace.
```typescript -await client.unstable.admins.listAdmins(); -``` +await client.unstable.helpCenter.listAllCollections(); +```
@@ -8054,18 +12031,19 @@ await client.unstable.admins.listAdmins();
-**requestOptions:** `Admins.RequestOptions` - +**requestOptions:** `HelpCenterClient.RequestOptions` +
+
-
client.unstable.admins.retrieveAdmin({ ...params }) -> Intercom.Admin | undefined +
client.unstable.helpCenter.createCollection({ ...params }) -> Intercom.Collection
@@ -8077,8 +12055,7 @@ await client.unstable.admins.listAdmins();
-You can retrieve the details of a single admin. - +You can create a new collection by making a POST request to `https://api.intercom.io/help_center/collections.`
@@ -8093,11 +12070,11 @@ You can retrieve the details of a single admin.
```typescript -await client.unstable.admins.retrieveAdmin({ - id: 1, +await client.unstable.helpCenter.createCollection({ + name: "Thanks for everything" }); -``` +```
@@ -8111,28 +12088,27 @@ await client.unstable.admins.retrieveAdmin({
-**request:** `Intercom.unstable.RetrieveAdminRequest` - +**request:** `Intercom.unstable.CreateCollectionRequest` +
-**requestOptions:** `Admins.RequestOptions` - +**requestOptions:** `HelpCenterClient.RequestOptions` +
+
-## AI Content - -
client.unstable.aiContent.listContentImportSources() -> Intercom.ContentImportSourcesList +
client.unstable.helpCenter.retrieveCollection({ ...params }) -> Intercom.Collection
@@ -8144,8 +12120,7 @@ await client.unstable.admins.retrieveAdmin({
-You can retrieve a list of all content import sources for a workspace. - +You can fetch the details of a single collection by making a GET request to `https://api.intercom.io/help_center/collections/`.
@@ -8160,9 +12135,11 @@ You can retrieve a list of all content import sources for a workspace.
```typescript -await client.unstable.aiContent.listContentImportSources(); -``` +await client.unstable.helpCenter.retrieveCollection({ + id: 1 +}); +```
@@ -8176,18 +12153,27 @@ await client.unstable.aiContent.listContentImportSources();
-**requestOptions:** `AiContent.RequestOptions` +**request:** `Intercom.unstable.RetrieveCollectionRequest` + +
+
+ +
+
+**requestOptions:** `HelpCenterClient.RequestOptions` +
+
-
client.unstable.aiContent.createContentImportSource({ ...params }) -> Intercom.ContentImportSource +
client.unstable.helpCenter.updateCollection({ ...params }) -> Intercom.Collection
@@ -8199,8 +12185,7 @@ await client.unstable.aiContent.listContentImportSources();
-You can create a new content import source by sending a POST request to this endpoint. - +You can update the details of a single collection by making a PUT request to `https://api.intercom.io/collections/`.
@@ -8215,11 +12200,12 @@ You can create a new content import source by sending a POST request to this end
```typescript -await client.unstable.aiContent.createContentImportSource({ - url: "https://www.example.com", +await client.unstable.helpCenter.updateCollection({ + id: 1, + name: "Update collection name" }); -``` +```
@@ -8233,29 +12219,44 @@ await client.unstable.aiContent.createContentImportSource({
-**request:** `Intercom.unstable.CreateContentImportSourceRequest` - +**request:** `Intercom.unstable.UpdateCollectionRequest` +
-**requestOptions:** `AiContent.RequestOptions` - +**requestOptions:** `HelpCenterClient.RequestOptions` +
+
-
client.unstable.aiContent.getContentImportSource({ ...params }) -> Intercom.ContentImportSource +
client.unstable.helpCenter.deleteCollection({ ...params }) -> Intercom.DeletedCollectionObject +
+
+ +#### 📝 Description + +
+
+
+You can delete a single collection by making a DELETE request to `https://api.intercom.io/collections/`. +
+
+
+
+ #### 🔌 Usage
@@ -8265,11 +12266,11 @@ await client.unstable.aiContent.createContentImportSource({
```typescript -await client.unstable.aiContent.getContentImportSource({ - id: "id", +await client.unstable.helpCenter.deleteCollection({ + id: 1 }); -``` +```
@@ -8283,26 +12284,27 @@ await client.unstable.aiContent.getContentImportSource({
-**request:** `Intercom.unstable.GetContentImportSourceRequest` - +**request:** `Intercom.unstable.DeleteCollectionRequest` +
-**requestOptions:** `AiContent.RequestOptions` - +**requestOptions:** `HelpCenterClient.RequestOptions` +
+
-
client.unstable.aiContent.updateContentImportSource({ ...params }) -> Intercom.ContentImportSource +
client.unstable.helpCenter.retrieveHelpCenter({ ...params }) -> Intercom.HelpCenter
@@ -8314,8 +12316,7 @@ await client.unstable.aiContent.getContentImportSource({
-You can update an existing content import source. - +You can fetch the details of a single Help Center by making a GET request to `https://api.intercom.io/help_center/help_center/`.
@@ -8330,13 +12331,11 @@ You can update an existing content import source.
```typescript -await client.unstable.aiContent.updateContentImportSource({ - id: "id", - sync_behavior: "api", - url: "https://www.example.com", +await client.unstable.helpCenter.retrieveHelpCenter({ + id: 1 }); -``` +```
@@ -8350,26 +12349,27 @@ await client.unstable.aiContent.updateContentImportSource({
-**request:** `Intercom.unstable.UpdateContentImportSourceRequest` - +**request:** `Intercom.unstable.RetrieveHelpCenterRequest` +
-**requestOptions:** `AiContent.RequestOptions` - +**requestOptions:** `HelpCenterClient.RequestOptions` +
+
-
client.unstable.aiContent.deleteContentImportSource({ ...params }) -> void +
client.unstable.helpCenter.listHelpCenters() -> Intercom.HelpCenterList
@@ -8381,8 +12381,7 @@ await client.unstable.aiContent.updateContentImportSource({
-You can delete a content import source by making a DELETE request this endpoint. This will also delete all external pages that were imported from this source. - +You can list all Help Centers by making a GET request to `https://api.intercom.io/help_center/help_centers`.
@@ -8397,11 +12396,9 @@ You can delete a content import source by making a DELETE request this endpoint.
```typescript -await client.unstable.aiContent.deleteContentImportSource({ - id: "id", -}); -``` +await client.unstable.helpCenter.listHelpCenters(); +```
@@ -8415,26 +12412,20 @@ await client.unstable.aiContent.deleteContentImportSource({
-**request:** `Intercom.unstable.DeleteContentImportSourceRequest` - -
-
- -
-
- -**requestOptions:** `AiContent.RequestOptions` - +**requestOptions:** `HelpCenterClient.RequestOptions` +
+
-
client.unstable.aiContent.listExternalPages() -> Intercom.ExternalPagesList +## Internal Articles +
client.unstable.internalArticles.listInternalArticles() -> Intercom.InternalArticleList
@@ -8446,8 +12437,7 @@ await client.unstable.aiContent.deleteContentImportSource({
-You can retrieve a list of all external pages for a workspace. - +You can fetch a list of all internal articles by making a GET request to `https://api.intercom.io/internal_articles`.
@@ -8462,9 +12452,9 @@ You can retrieve a list of all external pages for a workspace.
```typescript -await client.unstable.aiContent.listExternalPages(); -``` +await client.unstable.internalArticles.listInternalArticles(); +```
@@ -8478,18 +12468,19 @@ await client.unstable.aiContent.listExternalPages();
-**requestOptions:** `AiContent.RequestOptions` - +**requestOptions:** `InternalArticlesClient.RequestOptions` +
+
-
client.unstable.aiContent.createExternalPage({ ...params }) -> Intercom.ExternalPage +
client.unstable.internalArticles.createInternalArticle({ ...params }) -> Intercom.InternalArticle
@@ -8501,8 +12492,7 @@ await client.unstable.aiContent.listExternalPages();
-You can create a new external page by sending a POST request to this endpoint. If an external page already exists with the specified source_id and external_id, it will be updated instead. - +You can create a new internal article by making a POST request to `https://api.intercom.io/internal_articles`.
@@ -8517,15 +12507,14 @@ You can create a new external page by sending a POST request to this endpoint. I
```typescript -await client.unstable.aiContent.createExternalPage({ - title: "Test", - html: "

Test

", - url: "https://www.example.com", - source_id: 44, - external_id: "abc1234", +await client.unstable.internalArticles.createInternalArticle({ + title: "Thanks for everything", + body: "Body of the Article", + author_id: 991266252, + owner_id: 991266252 }); -``` +```
@@ -8539,26 +12528,27 @@ await client.unstable.aiContent.createExternalPage({
-**request:** `Intercom.unstable.CreateExternalPageRequest` - +**request:** `Intercom.CreateInternalArticleRequest` +
-**requestOptions:** `AiContent.RequestOptions` - +**requestOptions:** `InternalArticlesClient.RequestOptions` +
+
-
client.unstable.aiContent.getExternalPage({ ...params }) -> Intercom.ExternalPage +
client.unstable.internalArticles.retrieveInternalArticle({ ...params }) -> Intercom.InternalArticle
@@ -8570,8 +12560,7 @@ await client.unstable.aiContent.createExternalPage({
-You can retrieve an external page. - +You can fetch the details of a single internal article by making a GET request to `https://api.intercom.io/internal_articles/`.
@@ -8586,11 +12575,11 @@ You can retrieve an external page.
```typescript -await client.unstable.aiContent.getExternalPage({ - id: "id", +await client.unstable.internalArticles.retrieveInternalArticle({ + id: 1 }); -``` +```
@@ -8604,26 +12593,27 @@ await client.unstable.aiContent.getExternalPage({
-**request:** `Intercom.unstable.GetExternalPageRequest` - +**request:** `Intercom.unstable.RetrieveInternalArticleRequest` +
-**requestOptions:** `AiContent.RequestOptions` - +**requestOptions:** `InternalArticlesClient.RequestOptions` +
+
-
client.unstable.aiContent.updateExternalPage({ ...params }) -> Intercom.ExternalPage +
client.unstable.internalArticles.updateInternalArticle({ ...params }) -> Intercom.InternalArticle
@@ -8635,8 +12625,7 @@ await client.unstable.aiContent.getExternalPage({
-You can update an existing external page (if it was created via the API). - +You can update the details of a single internal article by making a PUT request to `https://api.intercom.io/internal_articles/`.
@@ -8651,16 +12640,13 @@ You can update an existing external page (if it was created via the API).
```typescript -await client.unstable.aiContent.updateExternalPage({ - id: "id", - title: "Test", - html: "

Test

", - url: "https://www.example.com", - source_id: 47, - external_id: "5678", +await client.unstable.internalArticles.updateInternalArticle({ + id: 1, + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

" }); -``` +```
@@ -8674,26 +12660,27 @@ await client.unstable.aiContent.updateExternalPage({
-**request:** `Intercom.unstable.UpdateExternalPageRequest` - +**request:** `Intercom.unstable.UpdateInternalArticleRequestBody` +
-**requestOptions:** `AiContent.RequestOptions` - +**requestOptions:** `InternalArticlesClient.RequestOptions` +
+
-
client.unstable.aiContent.deleteExternalPage({ ...params }) -> Intercom.ExternalPage +
client.unstable.internalArticles.deleteInternalArticle({ ...params }) -> Intercom.DeletedInternalArticleObject
@@ -8705,8 +12692,7 @@ await client.unstable.aiContent.updateExternalPage({
-Sending a DELETE request for an external page will remove it from the content library UI and from being used for AI answers. - +You can delete a single internal article by making a DELETE request to `https://api.intercom.io/internal_articles/`.
@@ -8721,11 +12707,11 @@ Sending a DELETE request for an external page will remove it from the content li
```typescript -await client.unstable.aiContent.deleteExternalPage({ - id: "id", +await client.unstable.internalArticles.deleteInternalArticle({ + id: 1 }); -``` +```
@@ -8739,28 +12725,27 @@ await client.unstable.aiContent.deleteExternalPage({
-**request:** `Intercom.unstable.DeleteExternalPageRequest` - +**request:** `Intercom.unstable.DeleteInternalArticleRequest` +
-**requestOptions:** `AiContent.RequestOptions` - +**requestOptions:** `InternalArticlesClient.RequestOptions` +
+
-## Articles - -
client.unstable.articles.listArticles() -> Intercom.ArticleList +
client.unstable.internalArticles.searchInternalArticles({ ...params }) -> Intercom.InternalArticleSearchResponse
@@ -8769,15 +12754,10 @@ await client.unstable.aiContent.deleteExternalPage({
-
-
- -You can fetch a list of all articles by making a GET request to `https://api.intercom.io/articles`. - -> 📘 How are the articles sorted and ordered? -> -> Articles will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated articles first. +
+
+You can search for internal articles by making a GET request to `https://api.intercom.io/internal_articles/search`.
@@ -8792,9 +12772,11 @@ You can fetch a list of all articles by making a GET request to `https://api.int
```typescript -await client.unstable.articles.listArticles(); -``` +await client.unstable.internalArticles.searchInternalArticles({ + folder_id: "folder_id" +}); +```
@@ -8808,18 +12790,28 @@ await client.unstable.articles.listArticles();
-**requestOptions:** `Articles.RequestOptions` +**request:** `Intercom.unstable.SearchInternalArticlesRequest` + +
+
+ +
+
+**requestOptions:** `InternalArticlesClient.RequestOptions` +
+
-
client.unstable.articles.createArticle({ ...params }) -> Intercom.Article +## Companies +
client.unstable.companies.retrieveCompany({ ...params }) -> Intercom.CompanyList
@@ -8831,8 +12823,17 @@ await client.unstable.articles.listArticles();
-You can create a new article by making a POST request to `https://api.intercom.io/articles`. +You can fetch a single company by passing in `company_id` or `name`. + + `https://api.intercom.io/companies?name={name}` + + `https://api.intercom.io/companies?company_id={company_id}` + +You can fetch all companies and filter by `segment_id` or `tag_id` as a query parameter. + `https://api.intercom.io/companies?tag_id={tag_id}` + + `https://api.intercom.io/companies?segment_id={segment_id}`
@@ -8847,11 +12848,16 @@ You can create a new article by making a POST request to `https://api.intercom.i
```typescript -await client.unstable.articles.createArticle({ - key: "value", +await client.unstable.companies.retrieveCompany({ + name: "my company", + company_id: "12345", + tag_id: "678910", + segment_id: "98765", + page: 1, + per_page: 1 }); -``` +```
@@ -8865,26 +12871,27 @@ await client.unstable.articles.createArticle({
-**request:** `unknown` - +**request:** `Intercom.unstable.RetrieveCompanyRequest` +
-**requestOptions:** `Articles.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.unstable.articles.retrieveArticle({ ...params }) -> Intercom.Article +
client.unstable.companies.createOrUpdateCompany({ ...params }) -> Intercom.Company
@@ -8896,8 +12903,15 @@ await client.unstable.articles.createArticle({
-You can fetch the details of a single article by making a GET request to `https://api.intercom.io/articles/`. +You can create or update a company. +Companies will be only visible in Intercom when there is at least one associated user. + +Companies are looked up via `company_id` in a `POST` request, if not found via `company_id`, the new company will be created, if found, that company will be updated. + +{% admonition type="warning" name="Using `company_id`" %} + You can set a unique `company_id` value when creating a company. However, it is not possible to update `company_id`. Be sure to set a unique value once upon creation of the company. +{% /admonition %}
@@ -8912,11 +12926,11 @@ You can fetch the details of a single article by making a GET request to `https:
```typescript -await client.unstable.articles.retrieveArticle({ - id: 1, +await client.unstable.companies.createOrUpdateCompany({ + "key": "value" }); -``` +```
@@ -8930,26 +12944,27 @@ await client.unstable.articles.retrieveArticle({
-**request:** `Intercom.unstable.RetrieveArticleRequest` - +**request:** `unknown` +
-**requestOptions:** `Articles.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.unstable.articles.deleteArticle({ ...params }) -> Intercom.DeletedArticleObject +
client.unstable.companies.retrieveACompanyById({ ...params }) -> Intercom.Company
@@ -8961,8 +12976,7 @@ await client.unstable.articles.retrieveArticle({
-You can delete a single article by making a DELETE request to `https://api.intercom.io/articles/`. - +You can fetch a single company.
@@ -8977,11 +12991,11 @@ You can delete a single article by making a DELETE request to `https://api.inter
```typescript -await client.unstable.articles.deleteArticle({ - id: 1, +await client.unstable.companies.retrieveACompanyById({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" }); -``` +```
@@ -8995,26 +13009,27 @@ await client.unstable.articles.deleteArticle({
-**request:** `Intercom.unstable.DeleteArticleRequest` - +**request:** `Intercom.unstable.RetrieveACompanyByIdRequest` +
-**requestOptions:** `Articles.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.unstable.articles.searchArticles({ ...params }) -> Intercom.ArticleSearchResponse +
client.unstable.companies.updateCompany({ ...params }) -> Intercom.Company
@@ -9026,8 +13041,11 @@ await client.unstable.articles.deleteArticle({
-You can search for articles by making a GET request to `https://api.intercom.io/articles/search`. +You can update a single company using the Intercom provisioned `id`. +{% admonition type="warning" name="Using `company_id`" %} + When updating a company it is not possible to update `company_id`. This can only be set once upon creation of the company. +{% /admonition %}
@@ -9042,12 +13060,11 @@ You can search for articles by making a GET request to `https://api.intercom.io/
```typescript -await client.unstable.articles.searchArticles({ - phrase: "Getting started", - state: "published", +await client.unstable.companies.updateCompany({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" }); -``` +```
@@ -9061,28 +13078,27 @@ await client.unstable.articles.searchArticles({
-**request:** `Intercom.unstable.SearchArticlesRequest` - +**request:** `Intercom.unstable.UpdateCompanyRequest` +
-**requestOptions:** `Articles.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-## Away Status Reasons - -
client.unstable.awayStatusReasons.listAwayStatusReasons() -> Intercom.AwayStatusReason[] +
client.unstable.companies.deleteCompany({ ...params }) -> Intercom.DeletedCompanyObject
@@ -9094,8 +13110,7 @@ await client.unstable.articles.searchArticles({
-Returns a list of all away status reasons configured for the workspace, including deleted ones. - +You can delete a single company.
@@ -9110,9 +13125,11 @@ Returns a list of all away status reasons configured for the workspace, includin
```typescript -await client.unstable.awayStatusReasons.listAwayStatusReasons(); -``` +await client.unstable.companies.deleteCompany({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" +}); +```
@@ -9126,23 +13143,44 @@ await client.unstable.awayStatusReasons.listAwayStatusReasons();
-**requestOptions:** `AwayStatusReasons.RequestOptions` +**request:** `Intercom.unstable.DeleteCompanyRequest` + +
+
+ +
+
+**requestOptions:** `CompaniesClient.RequestOptions` +
+
-## Unstable Export +
client.unstable.companies.listAttachedContacts({ ...params }) -> Intercom.CompanyAttachedContacts +
+
+ +#### 📝 Description + +
+
-
client.unstable.export.enqueueANewReportingDataExportJob({ ...params }) -> Intercom.PostExportReportingDataEnqueueResponse
+You can fetch a list of all contacts that belong to a company. +
+
+
+
+ #### 🔌 Usage
@@ -9152,14 +13190,11 @@ await client.unstable.awayStatusReasons.listAwayStatusReasons();
```typescript -await client.unstable.export.enqueueANewReportingDataExportJob({ - dataset_id: "conversation", - attribute_ids: ["conversation.id", "conversation.first_user_conversation_part_created_at"], - start_time: 1717490000, - end_time: 1717510000, +await client.unstable.companies.listAttachedContacts({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" }); -``` +```
@@ -9173,29 +13208,44 @@ await client.unstable.export.enqueueANewReportingDataExportJob({
-**request:** `Intercom.unstable.PostExportReportingDataEnqueueRequest` - +**request:** `Intercom.unstable.ListAttachedContactsRequest` +
-**requestOptions:** `Export.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.unstable.export.listAvailableDatasetsAndAttributes() -> Intercom.GetExportReportingDataGetDatasetsResponse +
client.unstable.companies.listAttachedSegmentsForCompanies({ ...params }) -> Intercom.CompanyAttachedSegments +
+
+ +#### 📝 Description +
+
+
+ +You can fetch a list of all segments that belong to a company. +
+
+
+
+ #### 🔌 Usage
@@ -9205,9 +13255,11 @@ await client.unstable.export.enqueueANewReportingDataExportJob({
```typescript -await client.unstable.export.listAvailableDatasetsAndAttributes(); -``` +await client.unstable.companies.listAttachedSegmentsForCompanies({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" +}); +```
@@ -9221,20 +13273,27 @@ await client.unstable.export.listAvailableDatasetsAndAttributes();
-**requestOptions:** `Export.RequestOptions` +**request:** `Intercom.unstable.ListAttachedSegmentsForCompaniesRequest` + +
+
+ +
+
+**requestOptions:** `CompaniesClient.RequestOptions` +
+
-## Help Center - -
client.unstable.helpCenter.listAllCollections() -> Intercom.CollectionList +
client.unstable.companies.listAllCompanies({ ...params }) -> Intercom.CompanyList
@@ -9246,10 +13305,15 @@ await client.unstable.export.listAvailableDatasetsAndAttributes();
-You can fetch a list of all collections by making a GET request to `https://api.intercom.io/help_center/collections`. +You can list companies. The company list is sorted by the `last_request_at` field and by default is ordered descending, most recently requested first. -Collections will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated collections first. +Note that the API does not include companies who have no associated users in list responses. +When using the Companies endpoint and the pages object to iterate through the returned companies, there is a limit of 10,000 Companies that can be returned. If you need to list or iterate on more than 10,000 Companies, please use the [Scroll API](https://developers.intercom.com/reference#iterating-over-all-companies). +{% admonition type="warning" name="Pagination" %} + You can use pagination to limit the number of results returned. The default is `20` results per page. + See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. +{% /admonition %}
@@ -9264,9 +13328,13 @@ Collections will be returned in descending order on the `updated_at` attribute.
```typescript -await client.unstable.helpCenter.listAllCollections(); -``` +await client.unstable.companies.listAllCompanies({ + page: 1, + per_page: 1, + order: "desc" +}); +```
@@ -9280,18 +13348,27 @@ await client.unstable.helpCenter.listAllCollections();
-**requestOptions:** `HelpCenter.RequestOptions` +**request:** `Intercom.unstable.ListAllCompaniesRequest` + +
+
+ +
+
+**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.unstable.helpCenter.createCollection({ ...params }) -> Intercom.Collection +
client.unstable.companies.scrollOverAllCompanies({ ...params }) -> Intercom.CompanyScroll | undefined
@@ -9303,8 +13380,21 @@ await client.unstable.helpCenter.listAllCollections();
-You can create a new collection by making a POST request to `https://api.intercom.io/help_center/collections.` + The `list all companies` functionality does not work well for huge datasets, and can result in errors and performance problems when paging deeply. The Scroll API provides an efficient mechanism for iterating over all companies in a dataset. + +- Each app can only have 1 scroll open at a time. You'll get an error message if you try to have more than one open per app. +- If the scroll isn't used for 1 minute, it expires and calls with that scroll param will fail +- If the end of the scroll is reached, "companies" will be empty and the scroll parameter will expire +{% admonition type="info" name="Scroll Parameter" %} + You can get the first page of companies by simply sending a GET request to the scroll endpoint. + For subsequent requests you will need to use the scroll parameter from the response. +{% /admonition %} +{% admonition type="danger" name="Scroll network timeouts" %} + Since scroll is often used on large datasets network errors such as timeouts can be encountered. When this occurs you will see a HTTP 500 error with the following message: + "Request failed due to an internal network error. Please restart the scroll operation." + If this happens, you will need to restart your scroll query: It is not possible to continue from a specific point when using scroll. +{% /admonition %}
@@ -9319,11 +13409,11 @@ You can create a new collection by making a POST request to `https://api.interco
```typescript -await client.unstable.helpCenter.createCollection({ - name: "Thanks for everything", +await client.unstable.companies.scrollOverAllCompanies({ + scroll_param: "scroll_param" }); -``` +```
@@ -9337,26 +13427,27 @@ await client.unstable.helpCenter.createCollection({
-**request:** `Intercom.unstable.CreateCollectionRequest` - +**request:** `Intercom.unstable.ScrollOverAllCompaniesRequest` +
-**requestOptions:** `HelpCenter.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.unstable.helpCenter.retrieveCollection({ ...params }) -> Intercom.Collection +
client.unstable.companies.attachContactToACompany({ ...params }) -> Intercom.Company
@@ -9368,8 +13459,7 @@ await client.unstable.helpCenter.createCollection({
-You can fetch the details of a single collection by making a GET request to `https://api.intercom.io/help_center/collections/`. - +You can attach a company to a single contact.
@@ -9384,11 +13474,12 @@ You can fetch the details of a single collection by making a GET request to `htt
```typescript -await client.unstable.helpCenter.retrieveCollection({ - id: 1, +await client.unstable.companies.attachContactToACompany({ + id: "id", + company_id: "6762f09a1bb69f9f2193bb34" }); -``` +```
@@ -9402,26 +13493,27 @@ await client.unstable.helpCenter.retrieveCollection({
-**request:** `Intercom.unstable.RetrieveCollectionRequest` - +**request:** `Intercom.unstable.AttachContactToACompanyRequest` +
-**requestOptions:** `HelpCenter.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.unstable.helpCenter.updateCollection({ ...params }) -> Intercom.Collection +
client.unstable.companies.detachContactFromACompany({ ...params }) -> Intercom.Company
@@ -9433,8 +13525,7 @@ await client.unstable.helpCenter.retrieveCollection({
-You can update the details of a single collection by making a PUT request to `https://api.intercom.io/collections/`. - +You can detach a company from a single contact.
@@ -9449,12 +13540,12 @@ You can update the details of a single collection by making a PUT request to `ht
```typescript -await client.unstable.helpCenter.updateCollection({ - id: 1, - name: "Update collection name", +await client.unstable.companies.detachContactFromACompany({ + contact_id: "58a430d35458202d41b1e65b", + id: "58a430d35458202d41b1e65b" }); -``` +```
@@ -9468,26 +13559,28 @@ await client.unstable.helpCenter.updateCollection({
-**request:** `Intercom.unstable.UpdateCollectionRequest` - +**request:** `Intercom.unstable.DetachContactFromACompanyRequest` +
-**requestOptions:** `HelpCenter.RequestOptions` - +**requestOptions:** `CompaniesClient.RequestOptions` +
+
-
client.unstable.helpCenter.deleteCollection({ ...params }) -> Intercom.DeletedCollectionObject +## Notes +
client.unstable.notes.listCompanyNotes({ ...params }) -> Intercom.NoteList
@@ -9499,8 +13592,7 @@ await client.unstable.helpCenter.updateCollection({
-You can delete a single collection by making a DELETE request to `https://api.intercom.io/collections/`. - +You can fetch a list of notes that are associated to a company.
@@ -9515,11 +13607,11 @@ You can delete a single collection by making a DELETE request to `https://api.in
```typescript -await client.unstable.helpCenter.deleteCollection({ - id: 1, +await client.unstable.notes.listCompanyNotes({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" }); -``` +```
@@ -9533,26 +13625,27 @@ await client.unstable.helpCenter.deleteCollection({
-**request:** `Intercom.unstable.DeleteCollectionRequest` - +**request:** `Intercom.unstable.ListCompanyNotesRequest` +
-**requestOptions:** `HelpCenter.RequestOptions` - +**requestOptions:** `NotesClient.RequestOptions` +
+
-
client.unstable.helpCenter.retrieveHelpCenter({ ...params }) -> Intercom.HelpCenter +
client.unstable.notes.listNotes({ ...params }) -> Intercom.NoteList
@@ -9564,8 +13657,7 @@ await client.unstable.helpCenter.deleteCollection({
-You can fetch the details of a single Help Center by making a GET request to `https://api.intercom.io/help_center/help_center/`. - +You can fetch a list of notes that are associated to a contact.
@@ -9580,11 +13672,11 @@ You can fetch the details of a single Help Center by making a GET request to `ht
```typescript -await client.unstable.helpCenter.retrieveHelpCenter({ - id: 1, +await client.unstable.notes.listNotes({ + id: 1 }); -``` +```
@@ -9598,26 +13690,27 @@ await client.unstable.helpCenter.retrieveHelpCenter({
-**request:** `Intercom.unstable.RetrieveHelpCenterRequest` - +**request:** `Intercom.unstable.ListNotesRequest` +
-**requestOptions:** `HelpCenter.RequestOptions` - +**requestOptions:** `NotesClient.RequestOptions` +
+
-
client.unstable.helpCenter.listHelpCenters() -> Intercom.HelpCenterList +
client.unstable.notes.createNote({ ...params }) -> Intercom.Note
@@ -9629,8 +13722,7 @@ await client.unstable.helpCenter.retrieveHelpCenter({
-You can list all Help Centers by making a GET request to `https://api.intercom.io/help_center/help_centers`. - +You can add a note to a single contact.
@@ -9644,10 +13736,15 @@ You can list all Help Centers by making a GET request to `https://api.intercom.i
-```typescript -await client.unstable.helpCenter.listHelpCenters(); +```typescript +await client.unstable.notes.createNote({ + id: 1, + body: "Hello", + contact_id: "6762f0ad1bb69f9f2193bb62", + admin_id: "123" +}); + ``` -
@@ -9661,20 +13758,27 @@ await client.unstable.helpCenter.listHelpCenters();
-**requestOptions:** `HelpCenter.RequestOptions` +**request:** `Intercom.unstable.CreateNoteRequest` + +
+
+ +
+
+**requestOptions:** `NotesClient.RequestOptions` +
+
-## Companies - -
client.unstable.companies.retrieveCompany({ ...params }) -> Intercom.CompanyList +
client.unstable.notes.retrieveNote({ ...params }) -> Intercom.Note
@@ -9686,18 +13790,7 @@ await client.unstable.helpCenter.listHelpCenters();
-You can fetch a single company by passing in `company_id` or `name`. - -`https://api.intercom.io/companies?name={name}` - -`https://api.intercom.io/companies?company_id={company_id}` - -You can fetch all companies and filter by `segment_id` or `tag_id` as a query parameter. - -`https://api.intercom.io/companies?tag_id={tag_id}` - -`https://api.intercom.io/companies?segment_id={segment_id}` - +You can fetch the details of a single note.
@@ -9712,14 +13805,11 @@ You can fetch all companies and filter by `segment_id` or `tag_id` as a query pa
```typescript -await client.unstable.companies.retrieveCompany({ - name: "my company", - company_id: "12345", - tag_id: "678910", - segment_id: "98765", +await client.unstable.notes.retrieveNote({ + id: 1 }); -``` +```
@@ -9733,26 +13823,28 @@ await client.unstable.companies.retrieveCompany({
-**request:** `Intercom.unstable.RetrieveCompanyRequest` - +**request:** `Intercom.unstable.RetrieveNoteRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `NotesClient.RequestOptions` +
+
-
client.unstable.companies.createOrUpdateCompany({ ...params }) -> Intercom.Company +## Contacts +
client.unstable.contacts.listCompaniesForAContact({ ...params }) -> Intercom.ContactAttachedCompanies
@@ -9764,16 +13856,7 @@ await client.unstable.companies.retrieveCompany({
-You can create or update a company. - -Companies will be only visible in Intercom when there is at least one associated user. - -Companies are looked up via `company_id` in a `POST` request, if not found via `company_id`, the new company will be created, if found, that company will be updated. - -{% admonition type="warning" name="Using `company_id`" %} -You can set a unique `company_id` value when creating a company. However, it is not possible to update `company_id`. Be sure to set a unique value once upon creation of the company. -{% /admonition %} - +You can fetch a list of companies that are associated to a contact.
@@ -9788,11 +13871,11 @@ You can set a unique `company_id` value when creating a company. However, it is
```typescript -await client.unstable.companies.createOrUpdateCompany({ - key: "value", +await client.unstable.contacts.listCompaniesForAContact({ + id: "63a07ddf05a32042dffac965" }); -``` +```
@@ -9806,26 +13889,27 @@ await client.unstable.companies.createOrUpdateCompany({
-**request:** `unknown` - +**request:** `Intercom.unstable.ListCompaniesForAContactRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.unstable.companies.retrieveACompanyById({ ...params }) -> Intercom.Company +
client.unstable.contacts.listSegmentsForAContact({ ...params }) -> Intercom.ContactSegments
@@ -9837,8 +13921,7 @@ await client.unstable.companies.createOrUpdateCompany({
-You can fetch a single company. - +You can fetch a list of segments that are associated to a contact.
@@ -9853,11 +13936,11 @@ You can fetch a single company.
```typescript -await client.unstable.companies.retrieveACompanyById({ - id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +await client.unstable.contacts.listSegmentsForAContact({ + contact_id: "63a07ddf05a32042dffac965" }); -``` +```
@@ -9871,26 +13954,27 @@ await client.unstable.companies.retrieveACompanyById({
-**request:** `Intercom.unstable.RetrieveACompanyByIdRequest` - +**request:** `Intercom.unstable.ListSegmentsForAContactRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.unstable.companies.updateCompany({ ...params }) -> Intercom.Company +
client.unstable.contacts.listSubscriptionsForAContact({ ...params }) -> Intercom.SubscriptionTypeList
@@ -9902,12 +13986,13 @@ await client.unstable.companies.retrieveACompanyById({
-You can update a single company using the Intercom provisioned `id`. +You can fetch a list of subscription types that are attached to a contact. These can be subscriptions that a user has 'opted-in' to or has 'opted-out' from, depending on the subscription type. +This will return a list of Subscription Type objects that the contact is associated with. -{% admonition type="warning" name="Using `company_id`" %} -When updating a company it is not possible to update `company_id`. This can only be set once upon creation of the company. -{% /admonition %} +The data property will show a combined list of: + 1.Opt-out subscription types that the user has opted-out from. + 2.Opt-in subscription types that the user has opted-in to receiving.
@@ -9922,11 +14007,11 @@ When updating a company it is not possible to update `company_id`. This can only
```typescript -await client.unstable.companies.updateCompany({ - id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +await client.unstable.contacts.listSubscriptionsForAContact({ + contact_id: "63a07ddf05a32042dffac965" }); -``` +```
@@ -9940,26 +14025,27 @@ await client.unstable.companies.updateCompany({
-**request:** `Intercom.unstable.UpdateCompanyRequest` - +**request:** `Intercom.unstable.ListSubscriptionsForAContactRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.unstable.companies.deleteCompany({ ...params }) -> Intercom.DeletedCompanyObject +
client.unstable.contacts.listTagsForAContact({ ...params }) -> Intercom.TagList
@@ -9971,8 +14057,7 @@ await client.unstable.companies.updateCompany({
-You can delete a single company. - +You can fetch a list of all tags that are attached to a specific contact.
@@ -9987,11 +14072,11 @@ You can delete a single company.
```typescript -await client.unstable.companies.deleteCompany({ - id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +await client.unstable.contacts.listTagsForAContact({ + contact_id: "63a07ddf05a32042dffac965" }); -``` +```
@@ -10005,26 +14090,27 @@ await client.unstable.companies.deleteCompany({
-**request:** `Intercom.unstable.DeleteCompanyRequest` - +**request:** `Intercom.unstable.ListTagsForAContactRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.unstable.companies.listAttachedContacts({ ...params }) -> Intercom.CompanyAttachedContacts +
client.unstable.contacts.showContact({ ...params }) -> Intercom.ShowContactResponse
@@ -10036,8 +14122,7 @@ await client.unstable.companies.deleteCompany({
-You can fetch a list of all contacts that belong to a company. - +You can fetch the details of a single contact.
@@ -10052,11 +14137,11 @@ You can fetch a list of all contacts that belong to a company.
```typescript -await client.unstable.companies.listAttachedContacts({ - id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +await client.unstable.contacts.showContact({ + id: "63a07ddf05a32042dffac965" }); -``` +```
@@ -10070,26 +14155,27 @@ await client.unstable.companies.listAttachedContacts({
-**request:** `Intercom.unstable.ListAttachedContactsRequest` - +**request:** `Intercom.unstable.ShowContactRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.unstable.companies.listAttachedSegmentsForCompanies({ ...params }) -> Intercom.CompanyAttachedSegments +
client.unstable.contacts.updateContact({ ...params }) -> Intercom.UpdateContactResponse
@@ -10101,8 +14187,13 @@ await client.unstable.companies.listAttachedContacts({
-You can fetch a list of all segments that belong to a company. +You can update an existing contact (ie. user or lead). +{% admonition type="info" %} + This endpoint handles both **contact updates** and **custom object associations**. + + See _`update a contact with an association to a custom object instance`_ in the request/response examples to see the custom object association format. +{% /admonition %}
@@ -10117,11 +14208,13 @@ You can fetch a list of all segments that belong to a company.
```typescript -await client.unstable.companies.listAttachedSegmentsForCompanies({ - id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", +await client.unstable.contacts.updateContact({ + id: "63a07ddf05a32042dffac965", + email: "joebloggs@intercom.io", + name: "joe bloggs" }); -``` +```
@@ -10135,26 +14228,27 @@ await client.unstable.companies.listAttachedSegmentsForCompanies({
-**request:** `Intercom.unstable.ListAttachedSegmentsForCompaniesRequest` - +**request:** `Intercom.unstable.UpdateContactRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.unstable.companies.listAllCompanies({ ...params }) -> Intercom.CompanyList +
client.unstable.contacts.deleteContact({ ...params }) -> Intercom.ContactDeleted
@@ -10166,16 +14260,7 @@ await client.unstable.companies.listAttachedSegmentsForCompanies({
-You can list companies. The company list is sorted by the `last_request_at` field and by default is ordered descending, most recently requested first. - -Note that the API does not include companies who have no associated users in list responses. - -When using the Companies endpoint and the pages object to iterate through the returned companies, there is a limit of 10,000 Companies that can be returned. If you need to list or iterate on more than 10,000 Companies, please use the [Scroll API](https://developers.intercom.com/reference#iterating-over-all-companies). -{% admonition type="warning" name="Pagination" %} -You can use pagination to limit the number of results returned. The default is `20` results per page. -See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. -{% /admonition %} - +You can delete a single contact.
@@ -10190,11 +14275,11 @@ See the [pagination section](https://developers.intercom.com/docs/build-an-integ
```typescript -await client.unstable.companies.listAllCompanies({ - order: "desc", +await client.unstable.contacts.deleteContact({ + id: "id" }); -``` +```
@@ -10208,26 +14293,27 @@ await client.unstable.companies.listAllCompanies({
-**request:** `Intercom.unstable.ListAllCompaniesRequest` - +**request:** `Intercom.unstable.DeleteContactRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.unstable.companies.scrollOverAllCompanies({ ...params }) -> Intercom.CompanyScroll | undefined +
client.unstable.contacts.mergeContact({ ...params }) -> Intercom.MergeContactResponse
@@ -10239,22 +14325,7 @@ await client.unstable.companies.listAllCompanies({
- The `list all companies` functionality does not work well for huge datasets, and can result in errors and performance problems when paging deeply. The Scroll API provides an efficient mechanism for iterating over all companies in a dataset. - -- Each app can only have 1 scroll open at a time. You'll get an error message if you try to have more than one open per app. -- If the scroll isn't used for 1 minute, it expires and calls with that scroll param will fail -- If the end of the scroll is reached, "companies" will be empty and the scroll parameter will expire - -{% admonition type="info" name="Scroll Parameter" %} -You can get the first page of companies by simply sending a GET request to the scroll endpoint. -For subsequent requests you will need to use the scroll parameter from the response. -{% /admonition %} -{% admonition type="danger" name="Scroll network timeouts" %} -Since scroll is often used on large datasets network errors such as timeouts can be encountered. When this occurs you will see a HTTP 500 error with the following message: -"Request failed due to an internal network error. Please restart the scroll operation." -If this happens, you will need to restart your scroll query: It is not possible to continue from a specific point when using scroll. -{% /admonition %} - +You can merge a contact with a `role` of `lead` into a contact with a `role` of `user`.
@@ -10269,9 +14340,12 @@ If this happens, you will need to restart your scroll query: It is not possible
```typescript -await client.unstable.companies.scrollOverAllCompanies(); -``` +await client.unstable.contacts.mergeContact({ + from: "6762f0d51bb69f9f2193bb7f", + into: "6762f0d51bb69f9f2193bb80" +}); +```
@@ -10285,26 +14359,27 @@ await client.unstable.companies.scrollOverAllCompanies();
-**request:** `Intercom.unstable.ScrollOverAllCompaniesRequest` - +**request:** `Intercom.unstable.MergeContactsRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.unstable.companies.attachContactToACompany({ ...params }) -> Intercom.Company +
client.unstable.contacts.searchContacts({ ...params }) -> Intercom.ContactList
@@ -10316,8 +14391,106 @@ await client.unstable.companies.scrollOverAllCompanies();
-You can attach a company to a single contact. +You can search for multiple contacts by the value of their attributes in order to fetch exactly who you want. + +To search for contacts, you need to send a `POST` request to `https://api.intercom.io/contacts/search`. + +This will accept a query object in the body which will define your filters in order to search for contacts. + +{% admonition type="warning" name="Optimizing search queries" %} + Search queries can be complex, so optimizing them can help the performance of your search. + Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize + pagination to limit the number of results returned. The default is `50` results per page. + See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. +{% /admonition %} +### Contact Creation Delay + +If a contact has recently been created, there is a possibility that it will not yet be available when searching. This means that it may not appear in the response. This delay can take a few minutes. If you need to be instantly notified it is recommended to use webhooks and iterate to see if they match your search filters. + +### Nesting & Limitations + +You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). +There are some limitations to the amount of multiple's there can be: +* There's a limit of max 2 nested filters +* There's a limit of max 15 filters for each AND or OR group + +### Searching for Timestamp Fields + +All timestamp fields (created_at, updated_at etc.) are indexed as Dates for Contact Search queries; Datetime queries are not currently supported. This means you can only query for timestamp fields by day - not hour, minute or second. +For example, if you search for all Contacts with a created_at value greater (>) than 1577869200 (the UNIX timestamp for January 1st, 2020 9:00 AM), that will be interpreted as 1577836800 (January 1st, 2020 12:00 AM). The search results will then include Contacts created from January 2nd, 2020 12:00 AM onwards. +If you'd like to get contacts created on January 1st, 2020 you should search with a created_at value equal (=) to 1577836800 (January 1st, 2020 12:00 AM). +This behaviour applies only to timestamps used in search queries. The search results will still contain the full UNIX timestamp and be sorted accordingly. + +### Accepted Fields + +Most key listed as part of the Contacts Model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). + +| Field | Type | +| ---------------------------------- | ------------------------------ | +| id | String | +| role | String
Accepts user or lead | +| name | String | +| avatar | String | +| owner_id | Integer | +| email | String | +| email_domain | String | +| phone | String | +| formatted_phone | String | +| external_id | String | +| created_at | Date (UNIX Timestamp) | +| signed_up_at | Date (UNIX Timestamp) | +| updated_at | Date (UNIX Timestamp) | +| last_seen_at | Date (UNIX Timestamp) | +| last_contacted_at | Date (UNIX Timestamp) | +| last_replied_at | Date (UNIX Timestamp) | +| last_email_opened_at | Date (UNIX Timestamp) | +| last_email_clicked_at | Date (UNIX Timestamp) | +| language_override | String | +| browser | String | +| browser_language | String | +| os | String | +| location.country | String | +| location.region | String | +| location.city | String | +| unsubscribed_from_emails | Boolean | +| marked_email_as_spam | Boolean | +| has_hard_bounced | Boolean | +| ios_last_seen_at | Date (UNIX Timestamp) | +| ios_app_version | String | +| ios_device | String | +| ios_app_device | String | +| ios_os_version | String | +| ios_app_name | String | +| ios_sdk_version | String | +| android_last_seen_at | Date (UNIX Timestamp) | +| android_app_version | String | +| android_device | String | +| android_app_name | String | +| andoid_sdk_version | String | +| segment_id | String | +| tag_id | String | +| custom_attributes.{attribute_name} | String | + +### Accepted Operators + +{% admonition type="warning" name="Searching based on `created_at`" %} + You cannot use the `<=` or `>=` operators to search by `created_at`. +{% /admonition %} + +The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). +| Operator | Valid Types | Description | +| :------- | :------------------------------- | :--------------------------------------------------------------- | +| = | All | Equals | +| != | All | Doesn't Equal | +| IN | All | In
Shortcut for `OR` queries
Values must be in Array | +| NIN | All | Not In
Shortcut for `OR !` queries
Values must be in Array | +| > | Integer
Date (UNIX Timestamp) | Greater than | +| < | Integer
Date (UNIX Timestamp) | Lower than | +| ~ | String | Contains | +| !~ | String | Doesn't Contain | +| ^ | String | Starts With | +| $ | String | Ends With |
@@ -10331,13 +14504,22 @@ You can attach a company to a single contact.
-```typescript -await client.unstable.companies.attachContactToACompany({ - id: "id", - company_id: "6762f09a1bb69f9f2193bb34", +```typescript +await client.unstable.contacts.searchContacts({ + query: { + operator: "AND", + value: [{ + field: "created_at", + operator: ">", + value: "1306054154" + }] + }, + pagination: { + per_page: 5 + } }); -``` +```
@@ -10351,26 +14533,27 @@ await client.unstable.companies.attachContactToACompany({
-**request:** `Intercom.unstable.AttachContactToACompanyRequest` - +**request:** `Intercom.SearchRequest` +
-**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.unstable.companies.detachContactFromACompany({ ...params }) -> Intercom.Company +
client.unstable.contacts.listContacts() -> Intercom.ContactList
@@ -10382,8 +14565,11 @@ await client.unstable.companies.attachContactToACompany({
-You can detach a company from a single contact. - +You can fetch a list of all contacts (ie. users or leads) in your workspace. +{% admonition type="warning" name="Pagination" %} + You can use pagination to limit the number of results returned. The default is `50` results per page. + See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. +{% /admonition %}
@@ -10398,12 +14584,9 @@ You can detach a company from a single contact.
```typescript -await client.unstable.companies.detachContactFromACompany({ - contact_id: "58a430d35458202d41b1e65b", - id: "58a430d35458202d41b1e65b", -}); -``` +await client.unstable.contacts.listContacts(); +```
@@ -10417,28 +14600,19 @@ await client.unstable.companies.detachContactFromACompany({
-**request:** `Intercom.unstable.DetachContactFromACompanyRequest` - -
-
- -
-
- -**requestOptions:** `Companies.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-## Contacts - -
client.unstable.contacts.listCompaniesForAContact({ ...params }) -> Intercom.ContactAttachedCompanies +
client.unstable.contacts.createContact({ ...params }) -> Intercom.CreateContactResponse
@@ -10450,8 +14624,7 @@ await client.unstable.companies.detachContactFromACompany({
-You can fetch a list of companies that are associated to a contact. - +You can create a new contact (ie. user or lead).
@@ -10466,11 +14639,11 @@ You can fetch a list of companies that are associated to a contact.
```typescript -await client.unstable.contacts.listCompaniesForAContact({ - id: "63a07ddf05a32042dffac965", +await client.unstable.contacts.createContact({ + "email": "joebloggs@intercom.io" }); -``` +```
@@ -10484,26 +14657,27 @@ await client.unstable.contacts.listCompaniesForAContact({
-**request:** `Intercom.unstable.ListCompaniesForAContactRequest` - +**request:** `Intercom.CreateContactRequestTwo` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.unstable.contacts.listSegmentsForAContact({ ...params }) -> Intercom.ContactSegments +
client.unstable.contacts.showContactByExternalId({ ...params }) -> Intercom.ShowContactByExternalIdResponse
@@ -10515,8 +14689,7 @@ await client.unstable.contacts.listCompaniesForAContact({
-You can fetch a list of segments that are associated to a contact. - +You can fetch the details of a single contact by external ID. Note that this endpoint only supports users and not leads.
@@ -10531,11 +14704,11 @@ You can fetch a list of segments that are associated to a contact.
```typescript -await client.unstable.contacts.listSegmentsForAContact({ - contact_id: "63a07ddf05a32042dffac965", +await client.unstable.contacts.showContactByExternalId({ + external_id: "cdd29344-5e0c-4ef0-ac56-f9ba2979bc27" }); -``` +```
@@ -10549,26 +14722,27 @@ await client.unstable.contacts.listSegmentsForAContact({
-**request:** `Intercom.unstable.ListSegmentsForAContactRequest` - +**request:** `Intercom.unstable.ShowContactByExternalIdRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.unstable.contacts.listSubscriptionsForAContact({ ...params }) -> Intercom.SubscriptionTypeList +
client.unstable.contacts.archiveContact({ ...params }) -> Intercom.ContactArchived
@@ -10580,14 +14754,7 @@ await client.unstable.contacts.listSegmentsForAContact({
-You can fetch a list of subscription types that are attached to a contact. These can be subscriptions that a user has 'opted-in' to or has 'opted-out' from, depending on the subscription type. -This will return a list of Subscription Type objects that the contact is associated with. - -The data property will show a combined list of: - -1.Opt-out subscription types that the user has opted-out from. -2.Opt-in subscription types that the user has opted-in to receiving. - +You can archive a single contact.
@@ -10602,11 +14769,11 @@ The data property will show a combined list of:
```typescript -await client.unstable.contacts.listSubscriptionsForAContact({ - contact_id: "63a07ddf05a32042dffac965", +await client.unstable.contacts.archiveContact({ + id: "63a07ddf05a32042dffac965" }); -``` +```
@@ -10620,26 +14787,27 @@ await client.unstable.contacts.listSubscriptionsForAContact({
-**request:** `Intercom.unstable.ListSubscriptionsForAContactRequest` - +**request:** `Intercom.unstable.ArchiveContactRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.unstable.contacts.listTagsForAContact({ ...params }) -> Intercom.TagList +
client.unstable.contacts.unarchiveContact({ ...params }) -> Intercom.ContactUnarchived
@@ -10651,8 +14819,7 @@ await client.unstable.contacts.listSubscriptionsForAContact({
-You can fetch a list of all tags that are attached to a specific contact. - +You can unarchive a single contact.
@@ -10667,11 +14834,11 @@ You can fetch a list of all tags that are attached to a specific contact.
```typescript -await client.unstable.contacts.listTagsForAContact({ - contact_id: "63a07ddf05a32042dffac965", +await client.unstable.contacts.unarchiveContact({ + id: "63a07ddf05a32042dffac965" }); -``` +```
@@ -10685,26 +14852,27 @@ await client.unstable.contacts.listTagsForAContact({
-**request:** `Intercom.unstable.ListTagsForAContactRequest` - +**request:** `Intercom.unstable.UnarchiveContactRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.unstable.contacts.showContact({ ...params }) -> Intercom.ShowContactResponse +
client.unstable.contacts.blockContact({ ...params }) -> Intercom.ContactBlocked
@@ -10716,8 +14884,7 @@ await client.unstable.contacts.listTagsForAContact({
-You can fetch the details of a single contact. - +Block a single contact.
**Note:** conversations of the contact will also be archived during the process.
More details in [FAQ How do I block Inbox spam?](https://www.intercom.com/help/en/articles/8838656-inbox-faqs)
@@ -10732,11 +14899,11 @@ You can fetch the details of a single contact.
```typescript -await client.unstable.contacts.showContact({ - id: "63a07ddf05a32042dffac965", +await client.unstable.contacts.blockContact({ + id: "63a07ddf05a32042dffac965" }); -``` +```
@@ -10750,26 +14917,28 @@ await client.unstable.contacts.showContact({
-**request:** `Intercom.unstable.ShowContactRequest` - +**request:** `Intercom.unstable.BlockContactRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `ContactsClient.RequestOptions` +
+
-
client.unstable.contacts.updateContact({ ...params }) -> Intercom.UpdateContactResponse +## Subscription Types +
client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({ ...params }) -> Intercom.SubscriptionType
@@ -10781,14 +14950,13 @@ await client.unstable.contacts.showContact({
-You can update an existing contact (ie. user or lead). +You can add a specific subscription to a contact. In Intercom, we have two different subscription types based on user consent - opt-out and opt-in: -{% admonition type="info" %} -This endpoint handles both **contact updates** and **custom object associations**. + 1.Attaching a contact to an opt-out subscription type will opt that user out from receiving messages related to that subscription type. -See _`update a contact with an association to a custom object instance`_ in the request/response examples to see the custom object association format. -{% /admonition %} + 2.Attaching a contact to an opt-in subscription type will opt that user in to receiving messages related to that subscription type. +This will return a subscription type model for the subscription type that was added to the contact.
@@ -10803,13 +14971,13 @@ See _`update a contact with an association to a custom object instance`_ in the
```typescript -await client.unstable.contacts.updateContact({ - id: "63a07ddf05a32042dffac965", - email: "joebloggs@intercom.io", - name: "joe bloggs", +await client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "37846", + consent_type: "opt_in" }); -``` +```
@@ -10823,26 +14991,27 @@ await client.unstable.contacts.updateContact({
-**request:** `Intercom.unstable.UpdateContactRequest` - +**request:** `Intercom.unstable.AttachSubscriptionTypeToContactRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `SubscriptionTypesClient.RequestOptions` +
+
-
client.unstable.contacts.deleteContact({ ...params }) -> Intercom.ContactDeleted +
client.unstable.subscriptionTypes.detachSubscriptionTypeToContact({ ...params }) -> Intercom.SubscriptionType
@@ -10854,8 +15023,7 @@ await client.unstable.contacts.updateContact({
-You can delete a single contact. - +You can remove a specific subscription from a contact. This will return a subscription type model for the subscription type that was removed from the contact.
@@ -10870,11 +15038,12 @@ You can delete a single contact.
```typescript -await client.unstable.contacts.deleteContact({ - id: "id", +await client.unstable.subscriptionTypes.detachSubscriptionTypeToContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "37846" }); -``` +```
@@ -10888,26 +15057,27 @@ await client.unstable.contacts.deleteContact({
-**request:** `Intercom.unstable.DeleteContactRequest` - +**request:** `Intercom.unstable.DetachSubscriptionTypeToContactRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `SubscriptionTypesClient.RequestOptions` +
+
-
client.unstable.contacts.mergeContact({ ...params }) -> Intercom.MergeContactResponse +
client.unstable.subscriptionTypes.listSubscriptionTypes() -> Intercom.SubscriptionTypeList
@@ -10919,8 +15089,7 @@ await client.unstable.contacts.deleteContact({
-You can merge a contact with a `role` of `lead` into a contact with a `role` of `user`. - +You can list all subscription types. A list of subscription type objects will be returned.
@@ -10935,12 +15104,9 @@ You can merge a contact with a `role` of `lead` into a contact with a `role` of
```typescript -await client.unstable.contacts.mergeContact({ - from: "6762f0d51bb69f9f2193bb7f", - into: "6762f0d51bb69f9f2193bb80", -}); -``` +await client.unstable.subscriptionTypes.listSubscriptionTypes(); +```
@@ -10954,26 +15120,20 @@ await client.unstable.contacts.mergeContact({
-**request:** `Intercom.unstable.MergeContactsRequest` - -
-
- -
-
- -**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `SubscriptionTypesClient.RequestOptions` +
+
-
client.unstable.contacts.searchContacts({ ...params }) -> Intercom.ContactList +## Tags +
client.unstable.tags.attachTagToContact({ ...params }) -> Intercom.Tag
@@ -10985,109 +15145,73 @@ await client.unstable.contacts.mergeContact({
-You can search for multiple contacts by the value of their attributes in order to fetch exactly who you want. - -To search for contacts, you need to send a `POST` request to `https://api.intercom.io/contacts/search`. - -This will accept a query object in the body which will define your filters in order to search for contacts. - -{% admonition type="warning" name="Optimizing search queries" %} -Search queries can be complex, so optimizing them can help the performance of your search. -Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize -pagination to limit the number of results returned. The default is `50` results per page. -See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. -{% /admonition %} +You can tag a specific contact. This will return a tag object for the tag that was added to the contact. +
+
+
+
-### Contact Creation Delay +#### 🔌 Usage -If a contact has recently been created, there is a possibility that it will not yet be available when searching. This means that it may not appear in the response. This delay can take a few minutes. If you need to be instantly notified it is recommended to use webhooks and iterate to see if they match your search filters. +
+
-### Nesting & Limitations +
+
-You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). -There are some limitations to the amount of multiple's there can be: +```typescript +await client.unstable.tags.attachTagToContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "7522907" +}); -- There's a limit of max 2 nested filters -- There's a limit of max 15 filters for each AND or OR group +``` +
+
+
+
-### Searching for Timestamp Fields +#### ⚙️ Parameters -All timestamp fields (created_at, updated_at etc.) are indexed as Dates for Contact Search queries; Datetime queries are not currently supported. This means you can only query for timestamp fields by day - not hour, minute or second. -For example, if you search for all Contacts with a created_at value greater (>) than 1577869200 (the UNIX timestamp for January 1st, 2020 9:00 AM), that will be interpreted as 1577836800 (January 1st, 2020 12:00 AM). The search results will then include Contacts created from January 2nd, 2020 12:00 AM onwards. -If you'd like to get contacts created on January 1st, 2020 you should search with a created_at value equal (=) to 1577836800 (January 1st, 2020 12:00 AM). -This behaviour applies only to timestamps used in search queries. The search results will still contain the full UNIX timestamp and be sorted accordingly. +
+
-### Accepted Fields +
+
-Most key listed as part of the Contacts Model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). +**request:** `Intercom.unstable.AttachTagToContactRequest` + +
+
-| Field | Type | -| ---------------------------------- | ------------------------------ | -| id | String | -| role | String
Accepts user or lead | -| name | String | -| avatar | String | -| owner_id | Integer | -| email | String | -| email_domain | String | -| phone | String | -| formatted_phone | String | -| external_id | String | -| created_at | Date (UNIX Timestamp) | -| signed_up_at | Date (UNIX Timestamp) | -| updated_at | Date (UNIX Timestamp) | -| last_seen_at | Date (UNIX Timestamp) | -| last_contacted_at | Date (UNIX Timestamp) | -| last_replied_at | Date (UNIX Timestamp) | -| last_email_opened_at | Date (UNIX Timestamp) | -| last_email_clicked_at | Date (UNIX Timestamp) | -| language_override | String | -| browser | String | -| browser_language | String | -| os | String | -| location.country | String | -| location.region | String | -| location.city | String | -| unsubscribed_from_emails | Boolean | -| marked_email_as_spam | Boolean | -| has_hard_bounced | Boolean | -| ios_last_seen_at | Date (UNIX Timestamp) | -| ios_app_version | String | -| ios_device | String | -| ios_app_device | String | -| ios_os_version | String | -| ios_app_name | String | -| ios_sdk_version | String | -| android_last_seen_at | Date (UNIX Timestamp) | -| android_app_version | String | -| android_device | String | -| android_app_name | String | -| andoid_sdk_version | String | -| segment_id | String | -| tag_id | String | -| custom_attributes.{attribute_name} | String | +
+
-### Accepted Operators +**requestOptions:** `TagsClient.RequestOptions` + +
+
+
+
-{% admonition type="warning" name="Searching based on `created_at`" %} -You cannot use the `<=` or `>=` operators to search by `created_at`. -{% /admonition %} -The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + + +
-| Operator | Valid Types | Description | -| :------- | :------------------------------- | :--------------------------------------------------------------- | -| = | All | Equals | -| != | All | Doesn't Equal | -| IN | All | In
Shortcut for `OR` queries
Values must be in Array | -| NIN | All | Not In
Shortcut for `OR !` queries
Values must be in Array | -| > | Integer
Date (UNIX Timestamp) | Greater than | -| < | Integer
Date (UNIX Timestamp) | Lower than | -| ~ | String | Contains | -| !~ | String | Doesn't Contain | -| ^ | String | Starts With | -| $ | String | Ends With | +
client.unstable.tags.detachTagFromContact({ ...params }) -> Intercom.Tag +
+
+ +#### 📝 Description + +
+
+ +
+
+You can remove tag from a specific contact. This will return a tag object for the tag that was removed from the contact.
@@ -11102,23 +15226,12 @@ The table below shows the operators you can use to define how you want to search
```typescript -await client.unstable.contacts.searchContacts({ - query: { - operator: "AND", - value: [ - { - field: "created_at", - operator: ">", - value: "1306054154", - }, - ], - }, - pagination: { - per_page: 5, - }, +await client.unstable.tags.detachTagFromContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "7522907" }); -``` +```
@@ -11132,26 +15245,27 @@ await client.unstable.contacts.searchContacts({
-**request:** `Intercom.SearchRequest` - +**request:** `Intercom.unstable.DetachTagFromContactRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `TagsClient.RequestOptions` +
+
-
client.unstable.contacts.listContacts() -> Intercom.ContactList +
client.unstable.tags.attachTagToConversation({ ...params }) -> Intercom.Tag
@@ -11163,12 +15277,7 @@ await client.unstable.contacts.searchContacts({
-You can fetch a list of all contacts (ie. users or leads) in your workspace. -{% admonition type="warning" name="Pagination" %} -You can use pagination to limit the number of results returned. The default is `50` results per page. -See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. -{% /admonition %} - +You can tag a specific conversation. This will return a tag object for the tag that was added to the conversation.
@@ -11183,9 +15292,13 @@ See the [pagination section](https://developers.intercom.com/docs/build-an-integ
```typescript -await client.unstable.contacts.listContacts(); -``` +await client.unstable.tags.attachTagToConversation({ + conversation_id: "64619700005694", + id: "7522907", + admin_id: "780" +}); +```
@@ -11199,18 +15312,27 @@ await client.unstable.contacts.listContacts();
-**requestOptions:** `Contacts.RequestOptions` +**request:** `Intercom.unstable.AttachTagToConversationRequest` + +
+
+ +
+
+**requestOptions:** `TagsClient.RequestOptions` +
+
-
client.unstable.contacts.createContact({ ...params }) -> Intercom.CreateContactResponse +
client.unstable.tags.detachTagFromConversation({ ...params }) -> Intercom.Tag
@@ -11222,8 +15344,7 @@ await client.unstable.contacts.listContacts();
-You can create a new contact (ie. user or lead). - +You can remove tag from a specific conversation. This will return a tag object for the tag that was removed from the conversation.
@@ -11238,11 +15359,13 @@ You can create a new contact (ie. user or lead).
```typescript -await client.unstable.contacts.createContact({ - email: "joebloggs@intercom.io", +await client.unstable.tags.detachTagFromConversation({ + conversation_id: "64619700005694", + id: "7522907", + admin_id: "123" }); -``` +```
@@ -11256,26 +15379,27 @@ await client.unstable.contacts.createContact({
-**request:** `Intercom.CreateContactRequestTwo` - +**request:** `Intercom.unstable.DetachTagFromConversationRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `TagsClient.RequestOptions` +
+
-
client.unstable.contacts.showContactByExternalId({ ...params }) -> Intercom.ShowContactByExternalIdResponse +
client.unstable.tags.listTags() -> Intercom.TagList
@@ -11287,7 +15411,7 @@ await client.unstable.contacts.createContact({
-You can fetch the details of a single contact by external ID. Note that this endpoint only supports users and not leads. +You can fetch a list of all tags for a given workspace.
@@ -11303,11 +15427,9 @@ You can fetch the details of a single contact by external ID. Note that this end
```typescript -await client.unstable.contacts.showContactByExternalId({ - external_id: "cdd29344-5e0c-4ef0-ac56-f9ba2979bc27", -}); -``` +await client.unstable.tags.listTags(); +```
@@ -11321,26 +15443,19 @@ await client.unstable.contacts.showContactByExternalId({
-**request:** `Intercom.unstable.ShowContactByExternalIdRequest` - -
-
- -
-
- -**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `TagsClient.RequestOptions` +
+
-
client.unstable.contacts.archiveContact({ ...params }) -> Intercom.ContactArchived +
client.unstable.tags.createTag({ ...params }) -> Intercom.Tag
@@ -11352,8 +15467,19 @@ await client.unstable.contacts.showContactByExternalId({
-You can archive a single contact. +You can use this endpoint to perform the following operations: + + **1. Create a new tag:** You can create a new tag by passing in the tag name as specified in "Create or Update Tag Request Payload" described below. + + **2. Update an existing tag:** You can update an existing tag by passing the id of the tag as specified in "Create or Update Tag Request Payload" described below. + **3. Tag Companies:** You can tag single company or a list of companies. You can tag a company by passing in the tag name and the company details as specified in "Tag Company Request Payload" described below. Also, if the tag doesn't exist then a new one will be created automatically. + + **4. Untag Companies:** You can untag a single company or a list of companies. You can untag a company by passing in the tag id and the company details as specified in "Untag Company Request Payload" described below. + + **5. Tag Multiple Users:** You can tag a list of users. You can tag the users by passing in the tag name and the user details as specified in "Tag Users Request Payload" described below. + +Each operation will return a tag object.
@@ -11368,11 +15494,11 @@ You can archive a single contact.
```typescript -await client.unstable.contacts.archiveContact({ - id: "63a07ddf05a32042dffac965", +await client.unstable.tags.createTag({ + name: "test" }); -``` +```
@@ -11386,26 +15512,27 @@ await client.unstable.contacts.archiveContact({
-**request:** `Intercom.unstable.ArchiveContactRequest` - +**request:** `Intercom.CreateTagRequestBody` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `TagsClient.RequestOptions` +
+
-
client.unstable.contacts.unarchiveContact({ ...params }) -> Intercom.ContactUnarchived +
client.unstable.tags.findTag({ ...params }) -> Intercom.Tag
@@ -11417,8 +15544,8 @@ await client.unstable.contacts.archiveContact({
-You can unarchive a single contact. - +You can fetch the details of tags that are on the workspace by their id. +This will return a tag object.
@@ -11433,11 +15560,11 @@ You can unarchive a single contact.
```typescript -await client.unstable.contacts.unarchiveContact({ - id: "63a07ddf05a32042dffac965", +await client.unstable.tags.findTag({ + id: "123" }); -``` +```
@@ -11451,26 +15578,27 @@ await client.unstable.contacts.unarchiveContact({
-**request:** `Intercom.unstable.UnarchiveContactRequest` - +**request:** `Intercom.unstable.FindTagRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `TagsClient.RequestOptions` +
+
-
client.unstable.contacts.blockContact({ ...params }) -> Intercom.ContactBlocked +
client.unstable.tags.deleteTag({ ...params }) -> void
@@ -11482,8 +15610,7 @@ await client.unstable.contacts.unarchiveContact({
-Block a single contact.
**Note:** conversations of the contact will also be archived during the process.
More details in [FAQ How do I block Inbox spam?](https://www.intercom.com/help/en/articles/8838656-inbox-faqs) - +You can delete the details of tags that are on the workspace by passing in the id.
@@ -11498,11 +15625,11 @@ Block a single contact.
**Note:** conversations of the contact will also be a
```typescript -await client.unstable.contacts.blockContact({ - id: "63a07ddf05a32042dffac965", +await client.unstable.tags.deleteTag({ + id: "123" }); -``` +```
@@ -11516,28 +15643,27 @@ await client.unstable.contacts.blockContact({
-**request:** `Intercom.unstable.BlockContactRequest` - +**request:** `Intercom.unstable.DeleteTagRequest` +
-**requestOptions:** `Contacts.RequestOptions` - +**requestOptions:** `TagsClient.RequestOptions` +
+
-## Notes - -
client.unstable.notes.listNotes({ ...params }) -> Intercom.NoteList +
client.unstable.tags.attachTagToTicket({ ...params }) -> Intercom.Tag
@@ -11549,8 +15675,7 @@ await client.unstable.contacts.blockContact({
-You can fetch a list of notes that are associated to a contact. - +You can tag a specific ticket. This will return a tag object for the tag that was added to the ticket.
@@ -11565,11 +15690,13 @@ You can fetch a list of notes that are associated to a contact.
```typescript -await client.unstable.notes.listNotes({ - id: 1, +await client.unstable.tags.attachTagToTicket({ + ticket_id: "64619700005694", + id: "7522907", + admin_id: "780" }); -``` +```
@@ -11583,26 +15710,27 @@ await client.unstable.notes.listNotes({
-**request:** `Intercom.unstable.ListNotesRequest` - +**request:** `Intercom.unstable.AttachTagToTicketRequest` +
-**requestOptions:** `Notes.RequestOptions` - +**requestOptions:** `TagsClient.RequestOptions` +
+
-
client.unstable.notes.createNote({ ...params }) -> Intercom.Note +
client.unstable.tags.detachTagFromTicket({ ...params }) -> Intercom.Tag
@@ -11614,8 +15742,7 @@ await client.unstable.notes.listNotes({
-You can add a note to a single contact. - +You can remove tag from a specific ticket. This will return a tag object for the tag that was removed from the ticket.
@@ -11630,14 +15757,13 @@ You can add a note to a single contact.
```typescript -await client.unstable.notes.createNote({ - id: 1, - body: "Hello", - contact_id: "6762f0ad1bb69f9f2193bb62", - admin_id: "123", +await client.unstable.tags.detachTagFromTicket({ + ticket_id: "64619700005694", + id: "7522907", + admin_id: "123" }); -``` +```
@@ -11651,26 +15777,28 @@ await client.unstable.notes.createNote({
-**request:** `Intercom.unstable.CreateNoteRequest` - +**request:** `Intercom.unstable.DetachTagFromTicketRequest` +
-**requestOptions:** `Notes.RequestOptions` - +**requestOptions:** `TagsClient.RequestOptions` +
+
-
client.unstable.notes.retrieveNote({ ...params }) -> Intercom.Note +## Conversations +
client.unstable.conversations.listConversations({ ...params }) -> Intercom.ConversationList
@@ -11682,8 +15810,13 @@ await client.unstable.notes.createNote({
-You can fetch the details of a single note. +You can fetch a list of all conversations. +You can optionally request the result page size and the cursor to start after to fetch the result. +{% admonition type="warning" name="Pagination" %} + You can use pagination to limit the number of results returned. The default is `20` results per page. + See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. +{% /admonition %}
@@ -11698,11 +15831,12 @@ You can fetch the details of a single note.
```typescript -await client.unstable.notes.retrieveNote({ - id: 1, +await client.unstable.conversations.listConversations({ + per_page: 1, + starting_after: "starting_after" }); -``` +```
@@ -11716,28 +15850,27 @@ await client.unstable.notes.retrieveNote({
-**request:** `Intercom.unstable.RetrieveNoteRequest` - +**request:** `Intercom.unstable.ListConversationsRequest` +
-**requestOptions:** `Notes.RequestOptions` - +**requestOptions:** `ConversationsClient.RequestOptions` +
+
-## Subscription Types - -
client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({ ...params }) -> Intercom.SubscriptionType +
client.unstable.conversations.createConversation({ ...params }) -> Intercom.Message
@@ -11749,13 +15882,15 @@ await client.unstable.notes.retrieveNote({
-You can add a specific subscription to a contact. In Intercom, we have two different subscription types based on user consent - opt-out and opt-in: - -1.Attaching a contact to an opt-out subscription type will opt that user out from receiving messages related to that subscription type. +You can create a conversation that has been initiated by a contact (ie. user or lead). +The conversation can be an in-app message only. -2.Attaching a contact to an opt-in subscription type will opt that user in to receiving messages related to that subscription type. +{% admonition type="info" name="Sending for visitors" %} +You can also send a message from a visitor by specifying their `user_id` or `id` value in the `from` field, along with a `type` field value of `contact`. +This visitor will be automatically converted to a contact with a lead role once the conversation is created. +{% /admonition %} -This will return a subscription type model for the subscription type that was added to the contact. +This will return the Message model that has been created.
@@ -11771,13 +15906,15 @@ This will return a subscription type model for the subscription type that was ad
```typescript -await client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({ - contact_id: "63a07ddf05a32042dffac965", - id: "37846", - consent_type: "opt_in", +await client.unstable.conversations.createConversation({ + from: { + type: "user", + id: "6762f11b1bb69f9f2193bba3" + }, + body: "Hello there" }); -``` +```
@@ -11791,26 +15928,27 @@ await client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({
-**request:** `Intercom.unstable.AttachSubscriptionTypeToContactRequest` - +**request:** `Intercom.unstable.CreateConversationRequest` +
-**requestOptions:** `SubscriptionTypes.RequestOptions` - +**requestOptions:** `ConversationsClient.RequestOptions` +
+
-
client.unstable.subscriptionTypes.detachSubscriptionTypeToContact({ ...params }) -> Intercom.SubscriptionType +
client.unstable.conversations.retrieveConversation({ ...params }) -> Intercom.Conversation
@@ -11822,8 +15960,16 @@ await client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({
-You can remove a specific subscription from a contact. This will return a subscription type model for the subscription type that was removed from the contact. +You can fetch the details of a single conversation. + +This will return a single Conversation model with all its conversation parts. + +{% admonition type="warning" name="Hard limit of 500 parts" %} +The maximum number of conversation parts that can be returned via the API is 500. If you have more than that we will return the 500 most recent conversation parts. +{% /admonition %} + +For AI agent conversation metadata, please note that you need to have the agent enabled in your workspace, which is a [paid feature](https://www.intercom.com/help/en/articles/8205718-fin-resolutions#h_97f8c2e671).
@@ -11838,12 +15984,13 @@ You can remove a specific subscription from a contact. This will return a subscr
```typescript -await client.unstable.subscriptionTypes.detachSubscriptionTypeToContact({ - contact_id: "63a07ddf05a32042dffac965", - id: "37846", +await client.unstable.conversations.retrieveConversation({ + id: 1, + display_as: "plaintext", + include_translations: true }); -``` +```
@@ -11857,26 +16004,27 @@ await client.unstable.subscriptionTypes.detachSubscriptionTypeToContact({
-**request:** `Intercom.unstable.DetachSubscriptionTypeToContactRequest` - +**request:** `Intercom.unstable.RetrieveConversationRequest` +
-**requestOptions:** `SubscriptionTypes.RequestOptions` - +**requestOptions:** `ConversationsClient.RequestOptions` +
+
-
client.unstable.subscriptionTypes.listSubscriptionTypes() -> Intercom.SubscriptionTypeList +
client.unstable.conversations.updateConversation({ ...params }) -> Intercom.Conversation
@@ -11888,7 +16036,18 @@ await client.unstable.subscriptionTypes.detachSubscriptionTypeToContact({
-You can list all subscription types. A list of subscription type objects will be returned. + +You can update an existing conversation. + +{% admonition type="info" name="Replying and other actions" %} +If you want to reply to a coveration or take an action such as assign, unassign, open, close or snooze, take a look at the reply and manage endpoints. +{% /admonition %} + +{% admonition type="info" %} + This endpoint handles both **conversation updates** and **custom object associations**. + + See _`update a conversation with an association to a custom object instance`_ in the request/response examples to see the custom object association format. +{% /admonition %}
@@ -11904,9 +16063,18 @@ You can list all subscription types. A list of subscription type objects will be
```typescript -await client.unstable.subscriptionTypes.listSubscriptionTypes(); -``` +await client.unstable.conversations.updateConversation({ + id: 1, + display_as: "plaintext", + read: true, + title: "new conversation title", + custom_attributes: { + "issue_type": "Billing", + "priority": "High" + } +}); +```
@@ -11920,20 +16088,27 @@ await client.unstable.subscriptionTypes.listSubscriptionTypes();
-**requestOptions:** `SubscriptionTypes.RequestOptions` +**request:** `Intercom.unstable.UpdateConversationRequest` + +
+
+ +
+
+**requestOptions:** `ConversationsClient.RequestOptions` +
+
-## Tags - -
client.unstable.tags.attachTagToContact({ ...params }) -> Intercom.Tag +
client.unstable.conversations.deleteConversation({ ...params }) -> Intercom.ConversationDeleted
@@ -11945,8 +16120,7 @@ await client.unstable.subscriptionTypes.listSubscriptionTypes();
-You can tag a specific contact. This will return a tag object for the tag that was added to the contact. - +You can delete a single conversation.
@@ -11961,12 +16135,11 @@ You can tag a specific contact. This will return a tag object for the tag that w
```typescript -await client.unstable.tags.attachTagToContact({ - contact_id: "63a07ddf05a32042dffac965", - id: "7522907", +await client.unstable.conversations.deleteConversation({ + id: 1 }); -``` +```
@@ -11980,26 +16153,27 @@ await client.unstable.tags.attachTagToContact({
-**request:** `Intercom.unstable.AttachTagToContactRequest` - +**request:** `Intercom.unstable.DeleteConversationRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `ConversationsClient.RequestOptions` +
+
-
client.unstable.tags.detachTagFromContact({ ...params }) -> Intercom.Tag +
client.unstable.conversations.searchConversations({ ...params }) -> Intercom.ConversationList
@@ -12011,8 +16185,105 @@ await client.unstable.tags.attachTagToContact({
-You can remove tag from a specific contact. This will return a tag object for the tag that was removed from the contact. +You can search for multiple conversations by the value of their attributes in order to fetch exactly which ones you want. + +To search for conversations, you need to send a `POST` request to `https://api.intercom.io/conversations/search`. + +This will accept a query object in the body which will define your filters in order to search for conversations. +{% admonition type="warning" name="Optimizing search queries" %} + Search queries can be complex, so optimizing them can help the performance of your search. + Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize + pagination to limit the number of results returned. The default is `20` results per page and maximum is `150`. + See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. +{% /admonition %} + +### Nesting & Limitations + +You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). +There are some limitations to the amount of multiple's there can be: +- There's a limit of max 2 nested filters +- There's a limit of max 15 filters for each AND or OR group + +### Accepted Fields + +Most keys listed in the conversation model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). +The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. + +| Field | Type | +| :---------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------- | +| id | String | +| created_at | Date (UNIX timestamp) | +| updated_at | Date (UNIX timestamp) | +| source.type | String
Accepted fields are `conversation`, `email`, `facebook`, `instagram`, `phone_call`, `phone_switch`, `push`, `sms`, `twitter` and `whatsapp`. | +| source.id | String | +| source.delivered_as | String | +| source.subject | String | +| source.body | String | +| source.author.id | String | +| source.author.type | String | +| source.author.name | String | +| source.author.email | String | +| source.url | String | +| contact_ids | String | +| teammate_ids | String | +| admin_assignee_id | String | +| team_assignee_id | String | +| channel_initiated | String | +| open | Boolean | +| read | Boolean | +| state | String | +| waiting_since | Date (UNIX timestamp) | +| snoozed_until | Date (UNIX timestamp) | +| tag_ids | String | +| priority | String | +| statistics.time_to_assignment | Integer | +| statistics.time_to_admin_reply | Integer | +| statistics.time_to_first_close | Integer | +| statistics.time_to_last_close | Integer | +| statistics.median_time_to_reply | Integer | +| statistics.first_contact_reply_at | Date (UNIX timestamp) | +| statistics.first_assignment_at | Date (UNIX timestamp) | +| statistics.first_admin_reply_at | Date (UNIX timestamp) | +| statistics.first_close_at | Date (UNIX timestamp) | +| statistics.last_assignment_at | Date (UNIX timestamp) | +| statistics.last_assignment_admin_reply_at | Date (UNIX timestamp) | +| statistics.last_contact_reply_at | Date (UNIX timestamp) | +| statistics.last_admin_reply_at | Date (UNIX timestamp) | +| statistics.last_close_at | Date (UNIX timestamp) | +| statistics.last_closed_by_id | String | +| statistics.count_reopens | Integer | +| statistics.count_assignments | Integer | +| statistics.count_conversation_parts | Integer | +| conversation_rating.requested_at | Date (UNIX timestamp) | +| conversation_rating.replied_at | Date (UNIX timestamp) | +| conversation_rating.score | Integer | +| conversation_rating.remark | String | +| conversation_rating.contact_id | String | +| conversation_rating.admin_d | String | +| ai_agent_participated | Boolean | +| ai_agent.resolution_state | String | +| ai_agent.last_answer_type | String | +| ai_agent.rating | Integer | +| ai_agent.rating_remark | String | +| ai_agent.source_type | String | +| ai_agent.source_title | String | + +### Accepted Operators + +The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). +| Operator | Valid Types | Description | +| :------- | :----------------------------- | :----------------------------------------------------------- | +| = | All | Equals | +| != | All | Doesn't Equal | +| IN | All | In Shortcut for `OR` queries Values most be in Array | +| NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | +| > | Integer Date (UNIX Timestamp) | Greater (or equal) than | +| < | Integer Date (UNIX Timestamp) | Lower (or equal) than | +| ~ | String | Contains | +| !~ | String | Doesn't Contain | +| ^ | String | Starts With | +| $ | String | Ends With |
@@ -12027,12 +16298,21 @@ You can remove tag from a specific contact. This will return a tag object for th
```typescript -await client.unstable.tags.detachTagFromContact({ - contact_id: "63a07ddf05a32042dffac965", - id: "7522907", +await client.unstable.conversations.searchConversations({ + query: { + operator: "AND", + value: [{ + field: "created_at", + operator: ">", + value: "1306054154" + }] + }, + pagination: { + per_page: 5 + } }); -``` +```
@@ -12046,26 +16326,27 @@ await client.unstable.tags.detachTagFromContact({
-**request:** `Intercom.unstable.DetachTagFromContactRequest` - +**request:** `Intercom.SearchRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `ConversationsClient.RequestOptions` +
+
-
client.unstable.tags.attachTagToConversation({ ...params }) -> Intercom.Tag +
client.unstable.conversations.replyConversation({ ...params }) -> Intercom.Conversation
@@ -12077,8 +16358,7 @@ await client.unstable.tags.detachTagFromContact({
-You can tag a specific conversation. This will return a tag object for the tag that was added to the conversation. - +You can reply to a conversation with a message from an admin or on behalf of a contact, or with a note for admins.
@@ -12093,13 +16373,17 @@ You can tag a specific conversation. This will return a tag object for the tag t
```typescript -await client.unstable.tags.attachTagToConversation({ - conversation_id: "64619700005694", - id: "7522907", - admin_id: "780", +await client.unstable.conversations.replyConversation({ + id: "123 or \"last\"", + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1571bb69f9f2193bbbb" + } }); -``` +```
@@ -12113,26 +16397,27 @@ await client.unstable.tags.attachTagToConversation({
-**request:** `Intercom.unstable.AttachTagToConversationRequest` - +**request:** `Intercom.unstable.ReplyConversationRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `ConversationsClient.RequestOptions` +
+
-
client.unstable.tags.detachTagFromConversation({ ...params }) -> Intercom.Tag +
client.unstable.conversations.manageConversation({ ...params }) -> Intercom.Conversation
@@ -12144,8 +16429,11 @@ await client.unstable.tags.attachTagToConversation({
-You can remove tag from a specific conversation. This will return a tag object for the tag that was removed from the conversation. - +For managing conversations you can: +- Close a conversation +- Snooze a conversation to reopen on a future date +- Open a conversation which is `snoozed` or `closed` +- Assign a conversation to an admin and/or team.
@@ -12160,13 +16448,16 @@ You can remove tag from a specific conversation. This will return a tag object f
```typescript -await client.unstable.tags.detachTagFromConversation({ - conversation_id: "64619700005694", - id: "7522907", - admin_id: "123", +await client.unstable.conversations.manageConversation({ + id: "123", + body: { + message_type: "close", + type: "admin", + admin_id: "12345" + } }); -``` +```
@@ -12180,26 +16471,27 @@ await client.unstable.tags.detachTagFromConversation({
-**request:** `Intercom.unstable.DetachTagFromConversationRequest` - +**request:** `Intercom.unstable.ManageConversationRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `ConversationsClient.RequestOptions` +
+
-
client.unstable.tags.listTags() -> Intercom.TagList +
client.unstable.conversations.attachContactToConversation({ ...params }) -> Intercom.Conversation
@@ -12211,7 +16503,11 @@ await client.unstable.tags.detachTagFromConversation({
-You can fetch a list of all tags for a given workspace. +You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. + +{% admonition type="warning" name="Contacts without an email" %} +If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. +{% /admonition %}
@@ -12227,9 +16523,15 @@ You can fetch a list of all tags for a given workspace.
```typescript -await client.unstable.tags.listTags(); -``` +await client.unstable.conversations.attachContactToConversation({ + id: "123", + admin_id: "12345", + customer: { + intercom_user_id: "6762f19b1bb69f9f2193bbd4" + } +}); +```
@@ -12243,18 +16545,27 @@ await client.unstable.tags.listTags();
-**requestOptions:** `Tags.RequestOptions` +**request:** `Intercom.unstable.AttachContactToConversationRequest` + +
+
+ +
+
+**requestOptions:** `ConversationsClient.RequestOptions` +
+
-
client.unstable.tags.createTag({ ...params }) -> Intercom.Tag +
client.unstable.conversations.detachContactFromConversation({ ...params }) -> Intercom.Conversation
@@ -12266,19 +16577,11 @@ await client.unstable.tags.listTags();
-You can use this endpoint to perform the following operations: - -**1. Create a new tag:** You can create a new tag by passing in the tag name as specified in "Create or Update Tag Request Payload" described below. - -**2. Update an existing tag:** You can update an existing tag by passing the id of the tag as specified in "Create or Update Tag Request Payload" described below. - -**3. Tag Companies:** You can tag single company or a list of companies. You can tag a company by passing in the tag name and the company details as specified in "Tag Company Request Payload" described below. Also, if the tag doesn't exist then a new one will be created automatically. - -**4. Untag Companies:** You can untag a single company or a list of companies. You can untag a company by passing in the tag id and the company details as specified in "Untag Company Request Payload" described below. - -**5. Tag Multiple Users:** You can tag a list of users. You can tag the users by passing in the tag name and the user details as specified in "Tag Users Request Payload" described below. +You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. -Each operation will return a tag object. +{% admonition type="warning" name="Contacts without an email" %} +If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. +{% /admonition %}
@@ -12294,11 +16597,13 @@ Each operation will return a tag object.
```typescript -await client.unstable.tags.createTag({ - name: "test", +await client.unstable.conversations.detachContactFromConversation({ + conversation_id: "123", + contact_id: "123", + admin_id: "5017690" }); -``` +```
@@ -12312,26 +16617,27 @@ await client.unstable.tags.createTag({
-**request:** `Intercom.CreateTagRequestBody` - +**request:** `Intercom.unstable.DetachContactFromConversationRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `ConversationsClient.RequestOptions` +
+
-
client.unstable.tags.findTag({ ...params }) -> Intercom.Tag +
client.unstable.conversations.redactConversation({ ...params }) -> Intercom.Conversation
@@ -12343,8 +16649,11 @@ await client.unstable.tags.createTag({
-You can fetch the details of tags that are on the workspace by their id. -This will return a tag object. +You can redact a conversation part or the source message of a conversation (as seen in the source object). + +{% admonition type="info" name="Redacting parts and messages" %} +If you are redacting a conversation part, it must have a `body`. If you are redacting a source message, it must have been created by a contact. We will return a `conversation_part_not_redactable` error if these criteria are not met. +{% /admonition %}
@@ -12360,11 +16669,13 @@ This will return a tag object.
```typescript -await client.unstable.tags.findTag({ - id: "123", +await client.unstable.conversations.redactConversation({ + type: "conversation_part", + conversation_id: "19894788788", + conversation_part_id: "19381789428" }); -``` +```
@@ -12378,26 +16689,27 @@ await client.unstable.tags.findTag({
-**request:** `Intercom.unstable.FindTagRequest` - +**request:** `Intercom.RedactConversationRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `ConversationsClient.RequestOptions` +
+
-
client.unstable.tags.deleteTag({ ...params }) -> void +
client.unstable.conversations.convertConversationToTicket({ ...params }) -> Intercom.Ticket | undefined
@@ -12409,8 +16721,7 @@ await client.unstable.tags.findTag({
-You can delete the details of tags that are on the workspace by passing in the id. - +You can convert a conversation to a ticket.
@@ -12425,11 +16736,12 @@ You can delete the details of tags that are on the workspace by passing in the i
```typescript -await client.unstable.tags.deleteTag({ - id: "123", +await client.unstable.conversations.convertConversationToTicket({ + id: 1, + ticket_type_id: "53" }); -``` +```
@@ -12443,26 +16755,28 @@ await client.unstable.tags.deleteTag({
-**request:** `Intercom.unstable.DeleteTagRequest` - +**request:** `Intercom.unstable.ConvertConversationToTicketRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `ConversationsClient.RequestOptions` +
+
-
client.unstable.tags.attachTagToTicket({ ...params }) -> Intercom.Tag +## Unstable CustomChannelEvents +
client.unstable.customChannelEvents.notifyNewConversation({ ...params }) -> Intercom.CustomChannelNotificationResponse
@@ -12474,8 +16788,8 @@ await client.unstable.tags.deleteTag({
-You can tag a specific ticket. This will return a tag object for the tag that was added to the ticket. - +Notifies Intercom that a new conversation was created in your custom channel/platform. This triggers conversation creation and workflow automations within Intercom for your custom channel integration. +> **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support.
@@ -12490,13 +16804,18 @@ You can tag a specific ticket. This will return a tag object for the tag that wa
```typescript -await client.unstable.tags.attachTagToTicket({ - ticket_id: "64619700005694", - id: "7522907", - admin_id: "780", +await client.unstable.customChannelEvents.notifyNewConversation({ + event_id: "evt_12345", + external_conversation_id: "conv_67890", + contact: { + type: "user", + external_id: "user_001", + name: "Jane Doe", + email: "jane.doe@example.com" + } }); -``` +```
@@ -12510,26 +16829,27 @@ await client.unstable.tags.attachTagToTicket({
-**request:** `Intercom.unstable.AttachTagToTicketRequest` - +**request:** `Intercom.CustomChannelBaseEvent` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `CustomChannelEventsClient.RequestOptions` +
+
-
client.unstable.tags.detachTagFromTicket({ ...params }) -> Intercom.Tag +
client.unstable.customChannelEvents.notifyNewMessage({ ...params }) -> Intercom.CustomChannelNotificationResponse
@@ -12541,8 +16861,8 @@ await client.unstable.tags.attachTagToTicket({
-You can remove tag from a specific ticket. This will return a tag object for the tag that was removed from the ticket. - +Notifies Intercom that a new message was sent in a conversation on your custom channel/platform. This allows Intercom to process the message and trigger any relevant workflow automations. +> **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support.
@@ -12557,13 +16877,19 @@ You can remove tag from a specific ticket. This will return a tag object for the
```typescript -await client.unstable.tags.detachTagFromTicket({ - ticket_id: "64619700005694", - id: "7522907", - admin_id: "123", +await client.unstable.customChannelEvents.notifyNewMessage({ + event_id: "evt_54321", + external_conversation_id: "conv_98765", + contact: { + type: "user", + external_id: "user_002", + name: "John Smith", + email: "john.smith@example.com" + }, + body: "Hello, I need help with my order." }); -``` +```
@@ -12577,28 +16903,27 @@ await client.unstable.tags.detachTagFromTicket({
-**request:** `Intercom.unstable.DetachTagFromTicketRequest` - +**request:** `Intercom.unstable.NotifyNewMessageRequest` +
-**requestOptions:** `Tags.RequestOptions` - +**requestOptions:** `CustomChannelEventsClient.RequestOptions` +
+
-## Conversations - -
client.unstable.conversations.listConversations({ ...params }) -> Intercom.ConversationList +
client.unstable.customChannelEvents.notifyQuickReplySelected({ ...params }) -> Intercom.CustomChannelNotificationResponse
@@ -12610,14 +16935,8 @@ await client.unstable.tags.detachTagFromTicket({
-You can fetch a list of all conversations. - -You can optionally request the result page size and the cursor to start after to fetch the result. -{% admonition type="warning" name="Pagination" %} -You can use pagination to limit the number of results returned. The default is `20` results per page. -See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. -{% /admonition %} - +Notifies Intercom that a user selected a quick reply option in your custom channel/platform. This allows Intercom to process the response and trigger any relevant workflow automations. +> **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support.
@@ -12632,9 +16951,19 @@ See the [pagination section](https://developers.intercom.com/docs/build-an-integ
```typescript -await client.unstable.conversations.listConversations(); -``` +await client.unstable.customChannelEvents.notifyQuickReplySelected({ + event_id: "evt_67890", + external_conversation_id: "conv_13579", + contact: { + type: "user", + external_id: "user_003", + name: "Alice Example", + email: "alice@example.com" + }, + quick_reply_option_id: "1234" +}); +```
@@ -12648,26 +16977,27 @@ await client.unstable.conversations.listConversations();
-**request:** `Intercom.unstable.ListConversationsRequest` - +**request:** `Intercom.unstable.NotifyQuickReplySelectedRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `CustomChannelEventsClient.RequestOptions` +
+
-
client.unstable.conversations.createConversation({ ...params }) -> Intercom.Message +
client.unstable.customChannelEvents.notifyAttributeCollected({ ...params }) -> Intercom.CustomChannelNotificationResponse
@@ -12679,16 +17009,8 @@ await client.unstable.conversations.listConversations();
-You can create a conversation that has been initiated by a contact (ie. user or lead). -The conversation can be an in-app message only. - -{% admonition type="info" name="Sending for visitors" %} -You can also send a message from a visitor by specifying their `user_id` or `id` value in the `from` field, along with a `type` field value of `contact`. -This visitor will be automatically converted to a contact with a lead role once the conversation is created. -{% /admonition %} - -This will return the Message model that has been created. - +Notifies Intercom that a user provided a response to an attribute collector in your custom channel/platform. This allows Intercom to process the attribute and trigger any relevant workflow automations. +> **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support.
@@ -12703,15 +17025,22 @@ This will return the Message model that has been created.
```typescript -await client.unstable.conversations.createConversation({ - from: { +await client.unstable.customChannelEvents.notifyAttributeCollected({ + event_id: "evt_24680", + external_conversation_id: "conv_11223", + contact: { type: "user", - id: "6762f11b1bb69f9f2193bba3", + external_id: "user_004", + name: "Bob Example", + email: "bob@example.com" }, - body: "Hello there", + attribute: { + id: "shipping_address", + value: "123 Main St, Springfield" + } }); -``` +```
@@ -12725,26 +17054,28 @@ await client.unstable.conversations.createConversation({
-**request:** `Intercom.unstable.CreateConversationRequest` - +**request:** `Intercom.unstable.NotifyAttributeCollectedRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `CustomChannelEventsClient.RequestOptions` +
+
-
client.unstable.conversations.retrieveConversation({ ...params }) -> Intercom.Conversation +## Custom Object Instances +
client.unstable.customObjectInstances.getCustomObjectInstancesByExternalId({ ...params }) -> Intercom.CustomObjectInstance | undefined
@@ -12756,16 +17087,7 @@ await client.unstable.conversations.createConversation({
-You can fetch the details of a single conversation. - -This will return a single Conversation model with all its conversation parts. - -{% admonition type="warning" name="Hard limit of 500 parts" %} -The maximum number of conversation parts that can be returned via the API is 500. If you have more than that we will return the 500 most recent conversation parts. -{% /admonition %} - -For AI agent conversation metadata, please note that you need to have the agent enabled in your workspace, which is a [paid feature](https://www.intercom.com/help/en/articles/8205718-fin-resolutions#h_97f8c2e671). - +Fetch a Custom Object Instance by external_id.
@@ -12780,12 +17102,12 @@ For AI agent conversation metadata, please note that you need to have the agent
```typescript -await client.unstable.conversations.retrieveConversation({ - id: 1, - display_as: "plaintext", +await client.unstable.customObjectInstances.getCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "Order", + external_id: "external_id" }); -``` +```
@@ -12799,26 +17121,27 @@ await client.unstable.conversations.retrieveConversation({
-**request:** `Intercom.unstable.RetrieveConversationRequest` - +**request:** `Intercom.unstable.GetCustomObjectInstancesByExternalIdRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `CustomObjectInstancesClient.RequestOptions` +
+
-
client.unstable.conversations.updateConversation({ ...params }) -> Intercom.Conversation +
client.unstable.customObjectInstances.createCustomObjectInstances({ ...params }) -> Intercom.CustomObjectInstance | undefined
@@ -12830,18 +17153,7 @@ await client.unstable.conversations.retrieveConversation({
-You can update an existing conversation. - -{% admonition type="info" name="Replying and other actions" %} -If you want to reply to a coveration or take an action such as assign, unassign, open, close or snooze, take a look at the reply and manage endpoints. -{% /admonition %} - -{% admonition type="info" %} -This endpoint handles both **conversation updates** and **custom object associations**. - -See _`update a conversation with an association to a custom object instance`_ in the request/response examples to see the custom object association format. -{% /admonition %} - +Create or update a custom object instance
@@ -12856,18 +17168,18 @@ See _`update a conversation with an association to a custom object instance`_ in
```typescript -await client.unstable.conversations.updateConversation({ - id: 1, - display_as: "plaintext", - read: true, - title: "new conversation title", +await client.unstable.customObjectInstances.createCustomObjectInstances({ + custom_object_type_identifier: "Order", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, custom_attributes: { - issue_type: "Billing", - priority: "High", - }, + "order_number": "ORDER-12345", + "total_amount": "custom_attributes" + } }); -``` +```
@@ -12881,26 +17193,27 @@ await client.unstable.conversations.updateConversation({
-**request:** `Intercom.unstable.UpdateConversationRequest` - +**request:** `Intercom.unstable.CreateOrUpdateCustomObjectInstanceRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `CustomObjectInstancesClient.RequestOptions` +
+
-
client.unstable.conversations.deleteConversation({ ...params }) -> Intercom.ConversationDeleted +
client.unstable.customObjectInstances.deleteCustomObjectInstancesById({ ...params }) -> Intercom.CustomObjectInstanceDeleted
@@ -12912,8 +17225,7 @@ await client.unstable.conversations.updateConversation({
-You can delete a single conversation. - +Delete a single Custom Object instance by external_id.
@@ -12928,11 +17240,12 @@ You can delete a single conversation.
```typescript -await client.unstable.conversations.deleteConversation({ - id: 1, +await client.unstable.customObjectInstances.deleteCustomObjectInstancesById({ + custom_object_type_identifier: "Order", + external_id: "external_id" }); -``` +```
@@ -12946,138 +17259,39 @@ await client.unstable.conversations.deleteConversation({
-**request:** `Intercom.unstable.DeleteConversationRequest` - -
-
- -
-
- -**requestOptions:** `Conversations.RequestOptions` - -
-
- - - +**request:** `Intercom.unstable.DeleteCustomObjectInstancesByIdRequest` + -
- -
client.unstable.conversations.searchConversations({ ...params }) -> Intercom.ConversationList -
-
- -#### 📝 Description - -
-
-You can search for multiple conversations by the value of their attributes in order to fetch exactly which ones you want. - -To search for conversations, you need to send a `POST` request to `https://api.intercom.io/conversations/search`. - -This will accept a query object in the body which will define your filters in order to search for conversations. -{% admonition type="warning" name="Optimizing search queries" %} -Search queries can be complex, so optimizing them can help the performance of your search. -Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize -pagination to limit the number of results returned. The default is `20` results per page and maximum is `150`. -See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. -{% /admonition %} - -### Nesting & Limitations - -You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). -There are some limitations to the amount of multiple's there can be: - -- There's a limit of max 2 nested filters -- There's a limit of max 15 filters for each AND or OR group - -### Accepted Fields - -Most keys listed in the conversation model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). -The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. - -| Field | Type | -| :---------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------- | -| id | String | -| created_at | Date (UNIX timestamp) | -| updated_at | Date (UNIX timestamp) | -| source.type | String
Accepted fields are `conversation`, `email`, `facebook`, `instagram`, `phone_call`, `phone_switch`, `push`, `sms`, `twitter` and `whatsapp`. | -| source.id | String | -| source.delivered_as | String | -| source.subject | String | -| source.body | String | -| source.author.id | String | -| source.author.type | String | -| source.author.name | String | -| source.author.email | String | -| source.url | String | -| contact_ids | String | -| teammate_ids | String | -| admin_assignee_id | String | -| team_assignee_id | String | -| channel_initiated | String | -| open | Boolean | -| read | Boolean | -| state | String | -| waiting_since | Date (UNIX timestamp) | -| snoozed_until | Date (UNIX timestamp) | -| tag_ids | String | -| priority | String | -| statistics.time_to_assignment | Integer | -| statistics.time_to_admin_reply | Integer | -| statistics.time_to_first_close | Integer | -| statistics.time_to_last_close | Integer | -| statistics.median_time_to_reply | Integer | -| statistics.first_contact_reply_at | Date (UNIX timestamp) | -| statistics.first_assignment_at | Date (UNIX timestamp) | -| statistics.first_admin_reply_at | Date (UNIX timestamp) | -| statistics.first_close_at | Date (UNIX timestamp) | -| statistics.last_assignment_at | Date (UNIX timestamp) | -| statistics.last_assignment_admin_reply_at | Date (UNIX timestamp) | -| statistics.last_contact_reply_at | Date (UNIX timestamp) | -| statistics.last_admin_reply_at | Date (UNIX timestamp) | -| statistics.last_close_at | Date (UNIX timestamp) | -| statistics.last_closed_by_id | String | -| statistics.count_reopens | Integer | -| statistics.count_assignments | Integer | -| statistics.count_conversation_parts | Integer | -| conversation_rating.requested_at | Date (UNIX timestamp) | -| conversation_rating.replied_at | Date (UNIX timestamp) | -| conversation_rating.score | Integer | -| conversation_rating.remark | String | -| conversation_rating.contact_id | String | -| conversation_rating.admin_d | String | -| ai_agent_participated | Boolean | -| ai_agent.resolution_state | String | -| ai_agent.last_answer_type | String | -| ai_agent.rating | Integer | -| ai_agent.rating_remark | String | -| ai_agent.source_type | String | -| ai_agent.source_title | String | +**requestOptions:** `CustomObjectInstancesClient.RequestOptions` + +
+
+
+
-### Accepted Operators -The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). +
+
+
+ +
client.unstable.customObjectInstances.getCustomObjectInstancesById({ ...params }) -> Intercom.CustomObjectInstance | undefined +
+
+ +#### 📝 Description + +
+
-| Operator | Valid Types | Description | -| :------- | :---------------------------- | :--------------------------------------------------------- | -| = | All | Equals | -| != | All | Doesn't Equal | -| IN | All | In Shortcut for `OR` queries Values most be in Array | -| NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | -| > | Integer Date (UNIX Timestamp) | Greater (or equal) than | -| < | Integer Date (UNIX Timestamp) | Lower (or equal) than | -| ~ | String | Contains | -| !~ | String | Doesn't Contain | -| ^ | String | Starts With | -| $ | String | Ends With | +
+
+Fetch a Custom Object Instance by id.
@@ -13092,23 +17306,12 @@ The table below shows the operators you can use to define how you want to search
```typescript -await client.unstable.conversations.searchConversations({ - query: { - operator: "AND", - value: [ - { - field: "created_at", - operator: ">", - value: "1306054154", - }, - ], - }, - pagination: { - per_page: 5, - }, +await client.unstable.customObjectInstances.getCustomObjectInstancesById({ + custom_object_type_identifier: "Order", + id: "id" }); -``` +```
@@ -13122,26 +17325,27 @@ await client.unstable.conversations.searchConversations({
-**request:** `Intercom.SearchRequest` - +**request:** `Intercom.unstable.GetCustomObjectInstancesByIdRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `CustomObjectInstancesClient.RequestOptions` +
+
-
client.unstable.conversations.replyConversation({ ...params }) -> Intercom.Conversation +
client.unstable.customObjectInstances.deleteCustomObjectInstancesByExternalId({ ...params }) -> Intercom.CustomObjectInstanceDeleted
@@ -13153,8 +17357,7 @@ await client.unstable.conversations.searchConversations({
-You can reply to a conversation with a message from an admin or on behalf of a contact, or with a note for admins. - +Delete a single Custom Object instance using the Intercom defined id.
@@ -13169,17 +17372,12 @@ You can reply to a conversation with a message from an admin or on behalf of a c
```typescript -await client.unstable.conversations.replyConversation({ - id: '123 or "last"', - body: { - message_type: "comment", - type: "user", - body: "Thanks again :)", - intercom_user_id: "6762f1571bb69f9f2193bbbb", - }, +await client.unstable.customObjectInstances.deleteCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "Order", + id: "id" }); -``` +```
@@ -13193,26 +17391,28 @@ await client.unstable.conversations.replyConversation({
-**request:** `Intercom.unstable.ReplyConversationRequest` - +**request:** `Intercom.unstable.DeleteCustomObjectInstancesByExternalIdRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `CustomObjectInstancesClient.RequestOptions` +
+
-
client.unstable.conversations.manageConversation({ ...params }) -> Intercom.Conversation +## Data Attributes +
client.unstable.dataAttributes.lisDataAttributes({ ...params }) -> Intercom.DataAttributeList
@@ -13224,16 +17424,11 @@ await client.unstable.conversations.replyConversation({
-For managing conversations you can: - -- Close a conversation -- Snooze a conversation to reopen on a future date -- Open a conversation which is `snoozed` or `closed` -- Assign a conversation to an admin and/or team. -
-
-
-
+You can fetch a list of all data attributes belonging to a workspace for contacts, companies or conversations. + + + + #### 🔌 Usage @@ -13244,16 +17439,12 @@ For managing conversations you can:
```typescript -await client.unstable.conversations.manageConversation({ - id: "123", - body: { - message_type: "close", - type: "admin", - admin_id: "12345", - }, +await client.unstable.dataAttributes.lisDataAttributes({ + model: "contact", + include_archived: true }); -``` +```
@@ -13267,26 +17458,27 @@ await client.unstable.conversations.manageConversation({
-**request:** `Intercom.unstable.ManageConversationRequest` - +**request:** `Intercom.unstable.LisDataAttributesRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `DataAttributesClient.RequestOptions` +
+
-
client.unstable.conversations.attachContactToConversation({ ...params }) -> Intercom.Conversation +
client.unstable.dataAttributes.createDataAttribute({ ...params }) -> Intercom.DataAttribute
@@ -13298,12 +17490,7 @@ await client.unstable.conversations.manageConversation({
-You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. - -{% admonition type="warning" name="Contacts without an email" %} -If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. -{% /admonition %} - +You can create a data attributes for a `contact` or a `company`.
@@ -13318,15 +17505,11 @@ If you add a contact via the email parameter and there is no user/lead found on
```typescript -await client.unstable.conversations.attachContactToConversation({ - id: "123", - admin_id: "12345", - customer: { - intercom_user_id: "6762f19b1bb69f9f2193bbd4", - }, +await client.unstable.dataAttributes.createDataAttribute({ + "key": "value" }); -``` +```
@@ -13340,26 +17523,27 @@ await client.unstable.conversations.attachContactToConversation({
-**request:** `Intercom.unstable.AttachContactToConversationRequest` - +**request:** `unknown` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `DataAttributesClient.RequestOptions` +
+
-
client.unstable.conversations.detachContactFromConversation({ ...params }) -> Intercom.Conversation +
client.unstable.dataAttributes.updateDataAttribute({ ...params }) -> Intercom.DataAttribute
@@ -13371,12 +17555,12 @@ await client.unstable.conversations.attachContactToConversation({
-You can add participants who are contacts to a conversation, on behalf of either another contact or an admin. -{% admonition type="warning" name="Contacts without an email" %} -If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. -{% /admonition %} +You can update a data attribute. +> 🚧 Updating the data type is not possible +> +> It is currently a dangerous action to execute changing a data attribute's type via the API. You will need to update the type via the UI instead.
@@ -13391,13 +17575,14 @@ If you add a contact via the email parameter and there is no user/lead found on
```typescript -await client.unstable.conversations.detachContactFromConversation({ - conversation_id: "123", - contact_id: "123", - admin_id: "5017690", +await client.unstable.dataAttributes.updateDataAttribute({ + id: 1, + body: { + "key": "value" + } }); -``` +```
@@ -13411,26 +17596,28 @@ await client.unstable.conversations.detachContactFromConversation({
-**request:** `Intercom.unstable.DetachContactFromConversationRequest` - +**request:** `Intercom.unstable.UpdateDataAttributeRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `DataAttributesClient.RequestOptions` +
+
-
client.unstable.conversations.redactConversation({ ...params }) -> Intercom.Conversation +## Data Events +
client.unstable.dataEvents.lisDataEvents({ ...params }) -> Intercom.DataEventSummary
@@ -13442,12 +17629,20 @@ await client.unstable.conversations.detachContactFromConversation({
-You can redact a conversation part or the source message of a conversation (as seen in the source object). -{% admonition type="info" name="Redacting parts and messages" %} -If you are redacting a conversation part, it must have a `body`. If you are redacting a source message, it must have been created by a contact. We will return a `conversation_part_not_redactable` error if these criteria are not met. -{% /admonition %} +> 🚧 +> +> Please note that you can only 'list' events that are less than 90 days old. Event counts and summaries will still include your events older than 90 days but you cannot 'list' these events individually if they are older than 90 days + +The events belonging to a customer can be listed by sending a GET request to `https://api.intercom.io/events` with a user or lead identifier along with a `type` parameter. The identifier parameter can be one of `user_id`, `email` or `intercom_user_id`. The `type` parameter value must be `user`. + +- `https://api.intercom.io/events?type=user&user_id={user_id}` +- `https://api.intercom.io/events?type=user&email={email}` +- `https://api.intercom.io/events?type=user&intercom_user_id={id}` (this call can be used to list leads) + +The `email` parameter value should be [url encoded](http://en.wikipedia.org/wiki/Percent-encoding) when sending. +You can optionally define the result page size as well with the `per_page` parameter.
@@ -13462,13 +17657,14 @@ If you are redacting a conversation part, it must have a `body`. If you are reda
```typescript -await client.unstable.conversations.redactConversation({ - type: "conversation_part", - conversation_id: "19894788788", - conversation_part_id: "19381789428", +await client.unstable.dataEvents.lisDataEvents({ + filter: { + user_id: "user_id" + }, + type: "type" }); -``` +```
@@ -13482,26 +17678,27 @@ await client.unstable.conversations.redactConversation({
-**request:** `Intercom.RedactConversationRequest` - +**request:** `Intercom.unstable.LisDataEventsRequest` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `DataEventsClient.RequestOptions` +
+
-
client.unstable.conversations.convertConversationToTicket({ ...params }) -> Intercom.Ticket | undefined +
client.unstable.dataEvents.createDataEvent({ ...params }) -> void
@@ -13513,7 +17710,47 @@ await client.unstable.conversations.redactConversation({
-You can convert a conversation to a ticket. + +You will need an Access Token that has write permissions to send Events. Once you have a key you can submit events via POST to the Events resource, which is located at https://api.intercom.io/events, or you can send events using one of the client libraries. When working with the HTTP API directly a client should send the event with a `Content-Type` of `application/json`. + +When using the JavaScript API, [adding the code to your app](http://docs.intercom.io/configuring-Intercom/tracking-user-events-in-your-app) makes the Events API available. Once added, you can submit an event using the `trackEvent` method. This will associate the event with the Lead or currently logged-in user or logged-out visitor/lead and send it to Intercom. The final parameter is a map that can be used to send optional metadata about the event. + +With the Ruby client you pass a hash describing the event to `Intercom::Event.create`, or call the `track_user` method directly on the current user object (e.g. `user.track_event`). + +**NB: For the JSON object types, please note that we do not currently support nested JSON structure.** + +| Type | Description | Example | +| :-------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------- | +| String | The value is a JSON String | `"source":"desktop"` | +| Number | The value is a JSON Number | `"load": 3.67` | +| Date | The key ends with the String `_date` and the value is a [Unix timestamp](http://en.wikipedia.org/wiki/Unix_time), assumed to be in the [UTC](http://en.wikipedia.org/wiki/Coordinated_Universal_Time) timezone. | `"contact_date": 1392036272` | +| Link | The value is a HTTP or HTTPS URI. | `"article": "https://example.org/ab1de.html"` | +| Rich Link | The value is a JSON object that contains `url` and `value` keys. | `"article": {"url": "https://example.org/ab1de.html", "value":"the dude abides"}` | +| Monetary Amount | The value is a JSON object that contains `amount` and `currency` keys. The `amount` key is a positive integer representing the amount in cents. The price in the example to the right denotes €349.99. | `"price": {"amount": 34999, "currency": "eur"}` | + +**Lead Events** + +When submitting events for Leads, you will need to specify the Lead's `id`. + +**Metadata behaviour** + +- We currently limit the number of tracked metadata keys to 10 per event. Once the quota is reached, we ignore any further keys we receive. The first 10 metadata keys are determined by the order in which they are sent in with the event. +- It is not possible to change the metadata keys once the event has been sent. A new event will need to be created with the new keys and you can archive the old one. +- There might be up to 24 hrs delay when you send a new metadata for an existing event. + +**Event de-duplication** + +The API may detect and ignore duplicate events. Each event is uniquely identified as a combination of the following data - the Workspace identifier, the Contact external identifier, the Data Event name and the Data Event created time. As a result, it is **strongly recommended** to send a second granularity Unix timestamp in the `created_at` field. + +Duplicated events are responded to using the normal `202 Accepted` code - an error is not thrown, however repeat requests will be counted against any rate limit that is in place. + +### HTTP API Responses + +- Successful responses to submitted events return `202 Accepted` with an empty body. +- Unauthorised access will be rejected with a `401 Unauthorized` or `403 Forbidden` response code. +- Events sent about users that cannot be found will return a `404 Not Found`. +- Event lists containing duplicate events will have those duplicates ignored. +- Server errors will return a `500` response code and may contain an error message in the body.
@@ -13529,12 +17766,11 @@ You can convert a conversation to a ticket.
```typescript -await client.unstable.conversations.convertConversationToTicket({ - id: 1, - ticket_type_id: "53", +await client.unstable.dataEvents.createDataEvent({ + "key": "value" }); -``` +```
@@ -13548,28 +17784,27 @@ await client.unstable.conversations.convertConversationToTicket({
-**request:** `Intercom.unstable.ConvertConversationToTicketRequest` - +**request:** `Intercom.CreateDataEventRequestTwo` +
-**requestOptions:** `Conversations.RequestOptions` - +**requestOptions:** `DataEventsClient.RequestOptions` +
+
-## Unstable CustomChannelEvents - -
client.unstable.customChannelEvents.notifyNewConversation({ ...params }) -> Intercom.CustomChannelNotificationResponse +
client.unstable.dataEvents.dataEventSummaries({ ...params }) -> void
@@ -13581,9 +17816,7 @@ await client.unstable.conversations.convertConversationToTicket({
-Notifies Intercom that a new conversation was created in your custom channel/platform. This triggers conversation creation and workflow automations within Intercom for your custom channel integration. - -> **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". +Create event summaries for a user. Event summaries are used to track the number of times an event has occurred, the first time it occurred and the last time it occurred.
@@ -13599,18 +17832,9 @@ Notifies Intercom that a new conversation was created in your custom channel/pla
```typescript -await client.unstable.customChannelEvents.notifyNewConversation({ - event_id: "evt_12345", - external_conversation_id: "conv_67890", - contact: { - type: "user", - external_id: "user_001", - name: "Jane Doe", - email: "jane.doe@example.com", - }, -}); -``` +await client.unstable.dataEvents.dataEventSummaries(); +```
@@ -13624,26 +17848,28 @@ await client.unstable.customChannelEvents.notifyNewConversation({
-**request:** `Intercom.CustomChannelBaseEvent` - +**request:** `Intercom.unstable.CreateDataEventSummariesRequest` +
-**requestOptions:** `CustomChannelEvents.RequestOptions` - +**requestOptions:** `DataEventsClient.RequestOptions` +
+
-
client.unstable.customChannelEvents.notifyNewMessage({ ...params }) -> Intercom.CustomChannelNotificationResponse +## Data Export +
client.unstable.dataExport.createDataExport({ ...params }) -> Intercom.DataExport
@@ -13655,10 +17881,21 @@ await client.unstable.customChannelEvents.notifyNewConversation({
-Notifies Intercom that a new message was sent in a conversation on your custom channel/platform. This allows Intercom to process the message and trigger any relevant workflow automations. +To create your export job, you need to send a `POST` request to the export endpoint `https://api.intercom.io/export/content/data`. + +The only parameters you need to provide are the range of dates that you want exported. + +>🚧 Limit of one active job +> +> You can only have one active job per workspace. You will receive a HTTP status code of 429 with the message Exceeded rate limit of 1 pending message data export jobs if you attempt to create a second concurrent job. -> **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". +>❗️ Updated_at not included +> +> It should be noted that the timeframe only includes messages sent during the time period and not messages that were only updated during this period. For example, if a message was updated yesterday but sent two days ago, you would need to set the created_at_after date before the message was sent to include that in your retrieval job. +>📘 Date ranges are inclusive +> +> Requesting data for 2018-06-01 until 2018-06-30 will get all data for those days including those specified - e.g. 2018-06-01 00:00:00 until 2018-06-30 23:59:99.
@@ -13673,19 +17910,12 @@ Notifies Intercom that a new message was sent in a conversation on your custom c
```typescript -await client.unstable.customChannelEvents.notifyNewMessage({ - event_id: "evt_54321", - external_conversation_id: "conv_98765", - contact: { - type: "user", - external_id: "user_002", - name: "John Smith", - email: "john.smith@example.com", - }, - body: "Hello, I need help with my order.", +await client.unstable.dataExport.createDataExport({ + created_at_after: 1734519776, + created_at_before: 1734537776 }); -``` +```
@@ -13699,26 +17929,27 @@ await client.unstable.customChannelEvents.notifyNewMessage({
-**request:** `Intercom.unstable.NotifyNewMessageRequest` - +**request:** `Intercom.unstable.CreateDataExportsRequest` +
-**requestOptions:** `CustomChannelEvents.RequestOptions` - +**requestOptions:** `DataExportClient.RequestOptions` +
+
-
client.unstable.customChannelEvents.notifyQuickReplySelected({ ...params }) -> Intercom.CustomChannelNotificationResponse +
client.unstable.dataExport.getDataExport({ ...params }) -> Intercom.DataExport
@@ -13730,10 +17961,11 @@ await client.unstable.customChannelEvents.notifyNewMessage({
-Notifies Intercom that a user selected a quick reply option in your custom channel/platform. This allows Intercom to process the response and trigger any relevant workflow automations. - -> **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". +You can view the status of your job by sending a `GET` request to the URL +`https://api.intercom.io/export/content/data/{job_identifier}` - the `{job_identifier}` is the value returned in the response when you first created the export job. More on it can be seen in the Export Job Model. +> 🚧 Jobs expire after two days +> All jobs that have completed processing (and are thus available to download from the provided URL) will have an expiry limit of two days from when the export ob completed. After this, the data will no longer be available.
@@ -13748,19 +17980,11 @@ Notifies Intercom that a user selected a quick reply option in your custom chann
```typescript -await client.unstable.customChannelEvents.notifyQuickReplySelected({ - event_id: "evt_67890", - external_conversation_id: "conv_13579", - contact: { - type: "user", - external_id: "user_003", - name: "Alice Example", - email: "alice@example.com", - }, - quick_reply_option_id: "1234", +await client.unstable.dataExport.getDataExport({ + job_identifier: "job_identifier" }); -``` +```
@@ -13774,26 +17998,27 @@ await client.unstable.customChannelEvents.notifyQuickReplySelected({
-**request:** `Intercom.unstable.NotifyQuickReplySelectedRequest` - +**request:** `Intercom.unstable.GetDataExportRequest` +
-**requestOptions:** `CustomChannelEvents.RequestOptions` - +**requestOptions:** `DataExportClient.RequestOptions` +
+
-
client.unstable.customChannelEvents.notifyAttributeCollected({ ...params }) -> Intercom.CustomChannelNotificationResponse +
client.unstable.dataExport.cancelDataExport({ ...params }) -> Intercom.DataExport
@@ -13805,10 +18030,7 @@ await client.unstable.customChannelEvents.notifyQuickReplySelected({
-Notifies Intercom that a user provided a response to an attribute collector in your custom channel/platform. This allows Intercom to process the attribute and trigger any relevant workflow automations. - -> **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". - +You can cancel your job
@@ -13823,22 +18045,11 @@ Notifies Intercom that a user provided a response to an attribute collector in y
```typescript -await client.unstable.customChannelEvents.notifyAttributeCollected({ - event_id: "evt_24680", - external_conversation_id: "conv_11223", - contact: { - type: "user", - external_id: "user_004", - name: "Bob Example", - email: "bob@example.com", - }, - attribute: { - id: "shipping_address", - value: "123 Main St, Springfield", - }, +await client.unstable.dataExport.cancelDataExport({ + job_identifier: "job_identifier" }); -``` +```
@@ -13852,28 +18063,27 @@ await client.unstable.customChannelEvents.notifyAttributeCollected({
-**request:** `Intercom.unstable.NotifyAttributeCollectedRequest` - +**request:** `Intercom.unstable.CancelDataExportRequest` +
-**requestOptions:** `CustomChannelEvents.RequestOptions` - +**requestOptions:** `DataExportClient.RequestOptions` +
+
-## Custom Object Instances - -
client.unstable.customObjectInstances.getCustomObjectInstancesByExternalId({ ...params }) -> Intercom.CustomObjectInstance | undefined +
client.unstable.dataExport.downloadDataExport({ ...params }) -> void
@@ -13885,8 +18095,13 @@ await client.unstable.customChannelEvents.notifyAttributeCollected({
-Fetch a Custom Object Instance by external_id. +When a job has a status of complete, and thus a filled download_url, you can download your data by hitting that provided URL, formatted like so: https://api.intercom.io/download/content/data/xyz1234. + +Your exported message data will be streamed continuously back down to you in a gzipped CSV format. +> 📘 Octet header required +> +> You will have to specify the header Accept: `application/octet-stream` when hitting this endpoint.
@@ -13901,12 +18116,11 @@ Fetch a Custom Object Instance by external_id.
```typescript -await client.unstable.customObjectInstances.getCustomObjectInstancesByExternalId({ - custom_object_type_identifier: "Order", - external_id: "external_id", +await client.unstable.dataExport.downloadDataExport({ + job_identifier: "job_identifier" }); -``` +```
@@ -13920,26 +18134,28 @@ await client.unstable.customObjectInstances.getCustomObjectInstancesByExternalId
-**request:** `Intercom.unstable.GetCustomObjectInstancesByExternalIdRequest` - +**request:** `Intercom.unstable.DownloadDataExportRequest` +
-**requestOptions:** `CustomObjectInstances.RequestOptions` - +**requestOptions:** `DataExportClient.RequestOptions` +
+
-
client.unstable.customObjectInstances.createCustomObjectInstances({ ...params }) -> Intercom.CustomObjectInstance | undefined +## Jobs +
client.unstable.jobs.status({ ...params }) -> Intercom.Jobs
@@ -13951,8 +18167,7 @@ await client.unstable.customObjectInstances.getCustomObjectInstancesByExternalId
-Create or update a custom object instance - +Retrieve the status of job execution.
@@ -13967,18 +18182,11 @@ Create or update a custom object instance
```typescript -await client.unstable.customObjectInstances.createCustomObjectInstances({ - custom_object_type_identifier: "Order", - external_id: "123", - external_created_at: 1392036272, - external_updated_at: 1392036272, - custom_attributes: { - order_number: "ORDER-12345", - total_amount: "custom_attributes", - }, +await client.unstable.jobs.status({ + id: "id" }); -``` +```
@@ -13992,26 +18200,28 @@ await client.unstable.customObjectInstances.createCustomObjectInstances({
-**request:** `Intercom.unstable.CreateOrUpdateCustomObjectInstanceRequest` - +**request:** `Intercom.unstable.JobsStatusRequest` +
-**requestOptions:** `CustomObjectInstances.RequestOptions` - +**requestOptions:** `JobsClient.RequestOptions` +
+
-
client.unstable.customObjectInstances.deleteCustomObjectInstancesById({ ...params }) -> Intercom.CustomObjectInstanceDeleted +## Macros +
client.unstable.macros.listMacros({ ...params }) -> Intercom.MacroList
@@ -14023,8 +18233,19 @@ await client.unstable.customObjectInstances.createCustomObjectInstances({
-Delete a single Custom Object instance by external_id. +You can fetch a list of all macros (saved replies) in your workspace for use in automating responses. + +The macros are returned in descending order by updated_at. + +**Pagination** + +This endpoint uses cursor-based pagination via the `starting_after` parameter. The cursor is a Base64-encoded JSON array containing `[updated_at, id]` of the last item from the previous page. +**Placeholder Transformation** + +The API transforms Intercom placeholders to a more standard XML-like format: +- From: `{{user.name | fallback: 'there'}}` +- To: ``
@@ -14039,12 +18260,13 @@ Delete a single Custom Object instance by external_id.
```typescript -await client.unstable.customObjectInstances.deleteCustomObjectInstancesById({ - custom_object_type_identifier: "Order", - external_id: "external_id", +await client.unstable.macros.listMacros({ + per_page: 1, + starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + updated_since: 1000000 }); -``` +```
@@ -14058,26 +18280,27 @@ await client.unstable.customObjectInstances.deleteCustomObjectInstancesById({
-**request:** `Intercom.unstable.DeleteCustomObjectInstancesByIdRequest` - +**request:** `Intercom.unstable.ListMacrosRequest` +
-**requestOptions:** `CustomObjectInstances.RequestOptions` - +**requestOptions:** `MacrosClient.RequestOptions` +
+
-
client.unstable.customObjectInstances.getCustomObjectInstancesById({ ...params }) -> Intercom.CustomObjectInstance | undefined +
client.unstable.macros.getMacro({ ...params }) -> Intercom.Macro | undefined
@@ -14089,8 +18312,23 @@ await client.unstable.customObjectInstances.deleteCustomObjectInstancesById({
-Fetch a Custom Object Instance by id. +You can fetch a single macro (saved reply) by its ID. The macro will only be returned if it is visible to the authenticated user based on its visibility settings. + +**Visibility Rules** + +A macro is returned based on its `visible_to` setting: +- `everyone`: Always visible to all team members +- `specific_teams`: Only visible if the authenticated user belongs to one of the teams specified in `visible_to_team_ids` +If a macro exists but is not visible to the authenticated user, a 404 error is returned. + +**Placeholder Transformation** + +The API transforms Intercom placeholders to a more standard XML-like format in the `body` field: +- From: `{{user.name | fallback: 'there'}}` +- To: `` + +Default values in placeholders are HTML-escaped for security.
@@ -14105,12 +18343,11 @@ Fetch a Custom Object Instance by id.
```typescript -await client.unstable.customObjectInstances.getCustomObjectInstancesById({ - custom_object_type_identifier: "Order", - id: "id", +await client.unstable.macros.getMacro({ + id: "123" }); -``` +```
@@ -14124,26 +18361,28 @@ await client.unstable.customObjectInstances.getCustomObjectInstancesById({
-**request:** `Intercom.unstable.GetCustomObjectInstancesByIdRequest` - +**request:** `Intercom.unstable.GetMacroRequest` +
-**requestOptions:** `CustomObjectInstances.RequestOptions` - +**requestOptions:** `MacrosClient.RequestOptions` +
+
-
client.unstable.customObjectInstances.deleteCustomObjectInstancesByExternalId({ ...params }) -> Intercom.CustomObjectInstanceDeleted +## Messages +
client.unstable.messages.createMessage({ ...params }) -> Intercom.Message
@@ -14155,8 +18394,17 @@ await client.unstable.customObjectInstances.getCustomObjectInstancesById({
-Delete a single Custom Object instance using the Intercom defined id. +You can create a message that has been initiated by an admin. The conversation can be either an in-app message, an email, sms or whatsapp. + +> 🚧 Sending for visitors +> +> There can be a short delay between when a contact is created and when a contact becomes available to be messaged through the API. A 404 Not Found error will be returned in this case. + +This will return the Message model that has been created. +> 🚧 Retrieving Associated Conversations +> +> As this is a message, there will be no conversation present until the contact responds. Once they do, you will have to search for a contact's conversations with the id of the message.
@@ -14171,12 +18419,16 @@ Delete a single Custom Object instance using the Intercom defined id.
```typescript -await client.unstable.customObjectInstances.deleteCustomObjectInstancesByExternalId({ - custom_object_type_identifier: "Order", - id: "id", +await client.unstable.messages.createMessage({ + "from": { + "type": "user", + "id": "6762f2341bb69f9f2193bc17" + }, + "body": "heyy", + "referer": "https://twitter.com/bob" }); -``` +```
@@ -14190,28 +18442,27 @@ await client.unstable.customObjectInstances.deleteCustomObjectInstancesByExterna
-**request:** `Intercom.unstable.DeleteCustomObjectInstancesByExternalIdRequest` - +**request:** `Intercom.CreateMessageRequest | undefined` +
-**requestOptions:** `CustomObjectInstances.RequestOptions` - +**requestOptions:** `MessagesClient.RequestOptions` +
+
-## Data Attributes - -
client.unstable.dataAttributes.lisDataAttributes({ ...params }) -> Intercom.DataAttributeList +
client.unstable.messages.getWhatsAppMessageStatus({ ...params }) -> Intercom.WhatsappMessageStatusList
@@ -14223,8 +18474,11 @@ await client.unstable.customObjectInstances.deleteCustomObjectInstancesByExterna
-You can fetch a list of all data attributes belonging to a workspace for contacts, companies or conversations. +Retrieves statuses of messages sent from the Outbound module. Currently, this API only supports WhatsApp messages. + +This endpoint returns paginated status events for WhatsApp messages sent via the Outbound module, providing +information about delivery state and related message details.
@@ -14239,9 +18493,13 @@ You can fetch a list of all data attributes belonging to a workspace for contact
```typescript -await client.unstable.dataAttributes.lisDataAttributes(); -``` +await client.unstable.messages.getWhatsAppMessageStatus({ + ruleset_id: "ruleset_id", + per_page: 1, + starting_after: "starting_after" +}); +```
@@ -14255,26 +18513,28 @@ await client.unstable.dataAttributes.lisDataAttributes();
-**request:** `Intercom.unstable.LisDataAttributesRequest` - +**request:** `Intercom.unstable.GetWhatsAppMessageStatusRequest` +
-**requestOptions:** `DataAttributes.RequestOptions` - +**requestOptions:** `MessagesClient.RequestOptions` +
+
-
client.unstable.dataAttributes.createDataAttribute({ ...params }) -> Intercom.DataAttribute +## News +
client.unstable.news.listNewsItems() -> Intercom.PaginatedResponse
@@ -14286,8 +18546,7 @@ await client.unstable.dataAttributes.lisDataAttributes();
-You can create a data attributes for a `contact` or a `company`. - +You can fetch a list of all news items
@@ -14302,13 +18561,9 @@ You can create a data attributes for a `contact` or a `company`.
```typescript -await client.unstable.dataAttributes.createDataAttribute({ - name: "Mithril Shirt", - model: "company", - data_type: "string", -}); -``` +await client.unstable.news.listNewsItems(); +```
@@ -14322,26 +18577,19 @@ await client.unstable.dataAttributes.createDataAttribute({
-**request:** `Intercom.unstable.CreateDataAttributeRequest` - -
-
- -
-
- -**requestOptions:** `DataAttributes.RequestOptions` - +**requestOptions:** `NewsClient.RequestOptions` +
+
-
client.unstable.dataAttributes.updateDataAttribute({ ...params }) -> Intercom.DataAttribute +
client.unstable.news.createNewsItem({ ...params }) -> Intercom.NewsItem
@@ -14353,12 +18601,7 @@ await client.unstable.dataAttributes.createDataAttribute({
-You can update a data attribute. - -> 🚧 Updating the data type is not possible -> -> It is currently a dangerous action to execute changing a data attribute's type via the API. You will need to update the type via the UI instead. - +You can create a news item
@@ -14373,14 +18616,21 @@ You can update a data attribute.
```typescript -await client.unstable.dataAttributes.updateDataAttribute({ - id: 1, - archived: false, - description: "Just a plain old ring", - options: ["options", "options"], +await client.unstable.news.createNewsItem({ + title: "Halloween is here!", + body: "

New costumes in store for this spooky season

", + sender_id: 991267834, + state: "live", + deliver_silently: true, + labels: ["Product", "Update", "New"], + reactions: ["\uD83D\uDE06", "\uD83D\uDE05"], + newsfeed_assignments: [{ + newsfeed_id: 53, + published_at: 1664638214 + }] }); -``` +```
@@ -14394,28 +18644,27 @@ await client.unstable.dataAttributes.updateDataAttribute({
-**request:** `Intercom.unstable.UpdateDataAttributeRequest` - +**request:** `Intercom.NewsItemRequest` +
-**requestOptions:** `DataAttributes.RequestOptions` - +**requestOptions:** `NewsClient.RequestOptions` +
+
-## Data Events - -
client.unstable.dataEvents.lisDataEvents({ ...params }) -> Intercom.DataEventSummary +
client.unstable.news.retrieveNewsItem({ ...params }) -> Intercom.NewsItem
@@ -14427,20 +18676,7 @@ await client.unstable.dataAttributes.updateDataAttribute({
-> 🚧 -> -> Please note that you can only 'list' events that are less than 90 days old. Event counts and summaries will still include your events older than 90 days but you cannot 'list' these events individually if they are older than 90 days - -The events belonging to a customer can be listed by sending a GET request to `https://api.intercom.io/events` with a user or lead identifier along with a `type` parameter. The identifier parameter can be one of `user_id`, `email` or `intercom_user_id`. The `type` parameter value must be `user`. - -- `https://api.intercom.io/events?type=user&user_id={user_id}` -- `https://api.intercom.io/events?type=user&email={email}` -- `https://api.intercom.io/events?type=user&intercom_user_id={id}` (this call can be used to list leads) - -The `email` parameter value should be [url encoded](http://en.wikipedia.org/wiki/Percent-encoding) when sending. - -You can optionally define the result page size as well with the `per_page` parameter. - +You can fetch the details of a single news item.
@@ -14455,14 +18691,11 @@ You can optionally define the result page size as well with the `per_page` param
```typescript -await client.unstable.dataEvents.lisDataEvents({ - filter: { - user_id: "user_id", - }, - type: "type", +await client.unstable.news.retrieveNewsItem({ + id: 1 }); -``` +```
@@ -14476,30 +18709,31 @@ await client.unstable.dataEvents.lisDataEvents({
-**request:** `Intercom.unstable.LisDataEventsRequest` - +**request:** `Intercom.unstable.RetrieveNewsItemRequest` +
-**requestOptions:** `DataEvents.RequestOptions` - +**requestOptions:** `NewsClient.RequestOptions` +
+
-
client.unstable.dataEvents.createDataEvent({ ...params }) -> void +
client.unstable.news.updateNewsItem({ ...params }) -> Intercom.NewsItem
-#### 📝 Description +#### 🔌 Usage
@@ -14507,50 +18741,68 @@ await client.unstable.dataEvents.lisDataEvents({
-You will need an Access Token that has write permissions to send Events. Once you have a key you can submit events via POST to the Events resource, which is located at https://api.intercom.io/events, or you can send events using one of the client libraries. When working with the HTTP API directly a client should send the event with a `Content-Type` of `application/json`. +```typescript +await client.unstable.news.updateNewsItem({ + id: 1, + body: { + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"] + } +}); -When using the JavaScript API, [adding the code to your app](http://docs.intercom.io/configuring-Intercom/tracking-user-events-in-your-app) makes the Events API available. Once added, you can submit an event using the `trackEvent` method. This will associate the event with the Lead or currently logged-in user or logged-out visitor/lead and send it to Intercom. The final parameter is a map that can be used to send optional metadata about the event. +``` +
+
+
+
-With the Ruby client you pass a hash describing the event to `Intercom::Event.create`, or call the `track_user` method directly on the current user object (e.g. `user.track_event`). +#### ⚙️ Parameters -**NB: For the JSON object types, please note that we do not currently support nested JSON structure.** +
+
-| Type | Description | Example | -| :-------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------- | -| String | The value is a JSON String | `"source":"desktop"` | -| Number | The value is a JSON Number | `"load": 3.67` | -| Date | The key ends with the String `_date` and the value is a [Unix timestamp](http://en.wikipedia.org/wiki/Unix_time), assumed to be in the [UTC](http://en.wikipedia.org/wiki/Coordinated_Universal_Time) timezone. | `"contact_date": 1392036272` | -| Link | The value is a HTTP or HTTPS URI. | `"article": "https://example.org/ab1de.html"` | -| Rich Link | The value is a JSON object that contains `url` and `value` keys. | `"article": {"url": "https://example.org/ab1de.html", "value":"the dude abides"}` | -| Monetary Amount | The value is a JSON object that contains `amount` and `currency` keys. The `amount` key is a positive integer representing the amount in cents. The price in the example to the right denotes €349.99. | `"price": {"amount": 34999, "currency": "eur"}` | +
+
-**Lead Events** +**request:** `Intercom.unstable.UpdateNewsItemRequest` + +
+
-When submitting events for Leads, you will need to specify the Lead's `id`. +
+
-**Metadata behaviour** +**requestOptions:** `NewsClient.RequestOptions` + +
+
+
+
-- We currently limit the number of tracked metadata keys to 10 per event. Once the quota is reached, we ignore any further keys we receive. The first 10 metadata keys are determined by the order in which they are sent in with the event. -- It is not possible to change the metadata keys once the event has been sent. A new event will need to be created with the new keys and you can archive the old one. -- There might be up to 24 hrs delay when you send a new metadata for an existing event. -**Event de-duplication** +
+
+
-The API may detect and ignore duplicate events. Each event is uniquely identified as a combination of the following data - the Workspace identifier, the Contact external identifier, the Data Event name and the Data Event created time. As a result, it is **strongly recommended** to send a second granularity Unix timestamp in the `created_at` field. +
client.unstable.news.deleteNewsItem({ ...params }) -> Intercom.DeletedObject +
+
-Duplicated events are responded to using the normal `202 Accepted` code - an error is not thrown, however repeat requests will be counted against any rate limit that is in place. +#### 📝 Description -### HTTP API Responses +
+
-- Successful responses to submitted events return `202 Accepted` with an empty body. -- Unauthorised access will be rejected with a `401 Unauthorized` or `403 Forbidden` response code. -- Events sent about users that cannot be found will return a `404 Not Found`. -- Event lists containing duplicate events will have those duplicates ignored. -- Server errors will return a `500` response code and may contain an error message in the body. -
-
-
-
+
+
+ +You can delete a single news item. +
+
+ + #### 🔌 Usage @@ -14561,11 +18813,11 @@ Duplicated events are responded to using the normal `202 Accepted` code - an err
```typescript -await client.unstable.dataEvents.createDataEvent({ - key: "value", +await client.unstable.news.deleteNewsItem({ + id: 1 }); -``` +```
@@ -14579,26 +18831,27 @@ await client.unstable.dataEvents.createDataEvent({
-**request:** `Intercom.CreateDataEventRequestTwo` - +**request:** `Intercom.unstable.DeleteNewsItemRequest` +
-**requestOptions:** `DataEvents.RequestOptions` - +**requestOptions:** `NewsClient.RequestOptions` +
+
-
client.unstable.dataEvents.dataEventSummaries({ ...params }) -> void +
client.unstable.news.listLiveNewsfeedItems({ ...params }) -> Intercom.PaginatedResponse
@@ -14610,8 +18863,7 @@ await client.unstable.dataEvents.createDataEvent({
-Create event summaries for a user. Event summaries are used to track the number of times an event has occurred, the first time it occurred and the last time it occurred. - +You can fetch a list of all news items that are live on a given newsfeed
@@ -14626,9 +18878,11 @@ Create event summaries for a user. Event summaries are used to track the number
```typescript -await client.unstable.dataEvents.dataEventSummaries(); -``` +await client.unstable.news.listLiveNewsfeedItems({ + id: "123" +}); +```
@@ -14642,28 +18896,27 @@ await client.unstable.dataEvents.dataEventSummaries();
-**request:** `Intercom.unstable.CreateDataEventSummariesRequest` - +**request:** `Intercom.unstable.ListLiveNewsfeedItemsRequest` +
-**requestOptions:** `DataEvents.RequestOptions` - +**requestOptions:** `NewsClient.RequestOptions` +
+
-## Data Export - -
client.unstable.dataExport.createDataExport({ ...params }) -> Intercom.DataExport +
client.unstable.news.listNewsfeeds() -> Intercom.PaginatedResponse
@@ -14675,22 +18928,7 @@ await client.unstable.dataEvents.dataEventSummaries();
-To create your export job, you need to send a `POST` request to the export endpoint `https://api.intercom.io/export/content/data`. - -The only parameters you need to provide are the range of dates that you want exported. - -> 🚧 Limit of one active job -> -> You can only have one active job per workspace. You will receive a HTTP status code of 429 with the message Exceeded rate limit of 1 pending message data export jobs if you attempt to create a second concurrent job. - -> ❗️ Updated_at not included -> -> It should be noted that the timeframe only includes messages sent during the time period and not messages that were only updated during this period. For example, if a message was updated yesterday but sent two days ago, you would need to set the created_at_after date before the message was sent to include that in your retrieval job. - -> 📘 Date ranges are inclusive -> -> Requesting data for 2018-06-01 until 2018-06-30 will get all data for those days including those specified - e.g. 2018-06-01 00:00:00 until 2018-06-30 23:59:99. - +You can fetch a list of all newsfeeds
@@ -14705,12 +18943,9 @@ The only parameters you need to provide are the range of dates that you want exp
```typescript -await client.unstable.dataExport.createDataExport({ - created_at_after: 1734519776, - created_at_before: 1734537776, -}); -``` +await client.unstable.news.listNewsfeeds(); +```
@@ -14724,26 +18959,19 @@ await client.unstable.dataExport.createDataExport({
-**request:** `Intercom.unstable.CreateDataExportsRequest` - -
-
- -
-
- -**requestOptions:** `DataExport.RequestOptions` - +**requestOptions:** `NewsClient.RequestOptions` +
+
-
client.unstable.dataExport.getDataExport({ ...params }) -> Intercom.DataExport +
client.unstable.news.retrieveNewsfeed({ ...params }) -> Intercom.Newsfeed
@@ -14755,12 +18983,7 @@ await client.unstable.dataExport.createDataExport({
-You can view the status of your job by sending a `GET` request to the URL -`https://api.intercom.io/export/content/data/{job_identifier}` - the `{job_identifier}` is the value returned in the response when you first created the export job. More on it can be seen in the Export Job Model. - -> 🚧 Jobs expire after two days -> All jobs that have completed processing (and are thus available to download from the provided URL) will have an expiry limit of two days from when the export ob completed. After this, the data will no longer be available. - +You can fetch the details of a single newsfeed
@@ -14775,11 +18998,11 @@ You can view the status of your job by sending a `GET` request to the URL
```typescript -await client.unstable.dataExport.getDataExport({ - job_identifier: "job_identifier", +await client.unstable.news.retrieveNewsfeed({ + id: "123" }); -``` +```
@@ -14793,26 +19016,28 @@ await client.unstable.dataExport.getDataExport({
-**request:** `Intercom.unstable.GetDataExportRequest` - +**request:** `Intercom.unstable.RetrieveNewsfeedRequest` +
-**requestOptions:** `DataExport.RequestOptions` - +**requestOptions:** `NewsClient.RequestOptions` +
+
-
client.unstable.dataExport.cancelDataExport({ ...params }) -> Intercom.DataExport +## Segments +
client.unstable.segments.listSegments({ ...params }) -> Intercom.SegmentList
@@ -14824,8 +19049,7 @@ await client.unstable.dataExport.getDataExport({
-You can cancel your job - +You can fetch a list of all segments.
@@ -14840,11 +19064,11 @@ You can cancel your job
```typescript -await client.unstable.dataExport.cancelDataExport({ - job_identifier: "job_identifier", +await client.unstable.segments.listSegments({ + include_count: true }); -``` +```
@@ -14858,26 +19082,27 @@ await client.unstable.dataExport.cancelDataExport({
-**request:** `Intercom.unstable.CancelDataExportRequest` - +**request:** `Intercom.unstable.ListSegmentsRequest` +
-**requestOptions:** `DataExport.RequestOptions` - +**requestOptions:** `SegmentsClient.RequestOptions` +
+
-
client.unstable.dataExport.downloadDataExport({ ...params }) -> void +
client.unstable.segments.retrieveSegment({ ...params }) -> Intercom.Segment
@@ -14889,14 +19114,7 @@ await client.unstable.dataExport.cancelDataExport({
-When a job has a status of complete, and thus a filled download_url, you can download your data by hitting that provided URL, formatted like so: https://api.intercom.io/download/content/data/xyz1234. - -Your exported message data will be streamed continuously back down to you in a gzipped CSV format. - -> 📘 Octet header required -> -> You will have to specify the header Accept: `application/octet-stream` when hitting this endpoint. - +You can fetch the details of a single segment.
@@ -14911,11 +19129,11 @@ Your exported message data will be streamed continuously back down to you in a g
```typescript -await client.unstable.dataExport.downloadDataExport({ - job_identifier: "job_identifier", +await client.unstable.segments.retrieveSegment({ + id: "123" }); -``` +```
@@ -14929,28 +19147,28 @@ await client.unstable.dataExport.downloadDataExport({
-**request:** `Intercom.unstable.DownloadDataExportRequest` - +**request:** `Intercom.unstable.RetrieveSegmentRequest` +
-**requestOptions:** `DataExport.RequestOptions` - +**requestOptions:** `SegmentsClient.RequestOptions` +
+
-## Jobs - -
client.unstable.jobs.status({ ...params }) -> Intercom.Jobs +## Switch +
client.unstable.switch.createPhoneSwitch({ ...params }) -> Intercom.PhoneSwitch | undefined
@@ -14962,8 +19180,10 @@ await client.unstable.dataExport.downloadDataExport({
-Retrieve the status of job execution. +You can use the API to deflect phone calls to the Intercom Messenger. +Calling this endpoint will send an SMS with a link to the Messenger to the phone number specified. +If custom attributes are specified, they will be added to the user or lead's custom data attributes.
@@ -14978,11 +19198,11 @@ Retrieve the status of job execution.
```typescript -await client.unstable.jobs.status({ - id: "id", +await client.unstable.switch.createPhoneSwitch({ + "key": "value" }); -``` +```
@@ -14996,28 +19216,28 @@ await client.unstable.jobs.status({
-**request:** `Intercom.unstable.JobsStatusRequest` - +**request:** `unknown` +
-**requestOptions:** `Jobs.RequestOptions` - +**requestOptions:** `SwitchClient.RequestOptions` +
+
-## Messages - -
client.unstable.messages.createMessage({ ...params }) -> Intercom.Message +## Calls +
client.unstable.calls.listCalls({ ...params }) -> Intercom.CallList
@@ -15029,18 +19249,7 @@ await client.unstable.jobs.status({
-You can create a message that has been initiated by an admin. The conversation can be either an in-app message, an email or sms. - -> 🚧 Sending for visitors -> -> There can be a short delay between when a contact is created and when a contact becomes available to be messaged through the API. A 404 Not Found error will be returned in this case. - -This will return the Message model that has been created. - -> 🚧 Retrieving Associated Conversations -> -> As this is a message, there will be no conversation present until the contact responds. Once they do, you will have to search for a contact's conversations with the id of the message. - +Retrieve a paginated list of calls.
@@ -15055,16 +19264,12 @@ This will return the Message model that has been created.
```typescript -await client.unstable.messages.createMessage({ - from: { - type: "user", - id: "6762f2341bb69f9f2193bc17", - }, - body: "heyy", - referer: "https://twitter.com/bob", +await client.unstable.calls.listCalls({ + page: 1, + per_page: 1 }); -``` +```
@@ -15078,26 +19283,27 @@ await client.unstable.messages.createMessage({
-**request:** `Intercom.CreateMessageRequestTwo` - +**request:** `Intercom.unstable.ListCallsRequest` +
-**requestOptions:** `Messages.RequestOptions` - +**requestOptions:** `CallsClient.RequestOptions` +
+
-
client.unstable.messages.getWhatsAppMessageStatus({ ...params }) -> Intercom.WhatsappMessageStatusList +
client.unstable.calls.showCall({ ...params }) -> Intercom.Call
@@ -15109,11 +19315,7 @@ await client.unstable.messages.createMessage({
-Retrieves statuses of messages sent from the Outbound module. Currently, this API only supports WhatsApp messages. - -This endpoint returns paginated status events for WhatsApp messages sent via the Outbound module, providing -information about delivery state and related message details. - +Retrieve a single call by id.
@@ -15128,11 +19330,11 @@ information about delivery state and related message details.
```typescript -await client.unstable.messages.getWhatsAppMessageStatus({ - ruleset_id: "ruleset_id", +await client.unstable.calls.showCall({ + id: "id" }); -``` +```
@@ -15146,28 +19348,27 @@ await client.unstable.messages.getWhatsAppMessageStatus({
-**request:** `Intercom.unstable.GetWhatsAppMessageStatusRequest` - +**request:** `Intercom.unstable.ShowCallRequest` +
-**requestOptions:** `Messages.RequestOptions` - +**requestOptions:** `CallsClient.RequestOptions` +
+
-## News - -
client.unstable.news.listNewsItems() -> Intercom.PaginatedResponse +
client.unstable.calls.showCallRecording({ ...params }) -> void
@@ -15179,8 +19380,7 @@ await client.unstable.messages.getWhatsAppMessageStatus({
-You can fetch a list of all news items - +Redirects to a signed URL for the call's recording if it exists.
@@ -15195,9 +19395,11 @@ You can fetch a list of all news items
```typescript -await client.unstable.news.listNewsItems(); -``` +await client.unstable.calls.showCallRecording({ + id: "id" +}); +```
@@ -15211,18 +19413,27 @@ await client.unstable.news.listNewsItems();
-**requestOptions:** `News.RequestOptions` +**request:** `Intercom.unstable.ShowCallRecordingRequest` + +
+
+ +
+
+**requestOptions:** `CallsClient.RequestOptions` +
+
-
client.unstable.news.createNewsItem({ ...params }) -> Intercom.NewsItem +
client.unstable.calls.showCallTranscript({ ...params }) -> string
@@ -15234,8 +19445,7 @@ await client.unstable.news.listNewsItems();
-You can create a news item - +Returns the transcript for the specified call as a downloadable text file.
@@ -15250,23 +19460,11 @@ You can create a news item
```typescript -await client.unstable.news.createNewsItem({ - title: "Halloween is here!", - body: "

New costumes in store for this spooky season

", - sender_id: 991267834, - state: "live", - deliver_silently: true, - labels: ["Product", "Update", "New"], - reactions: ["\uD83D\uDE06", "\uD83D\uDE05"], - newsfeed_assignments: [ - { - newsfeed_id: 53, - published_at: 1664638214, - }, - ], +await client.unstable.calls.showCallTranscript({ + id: "id" }); -``` +```
@@ -15280,26 +19478,27 @@ await client.unstable.news.createNewsItem({
-**request:** `Intercom.NewsItemRequest` - +**request:** `Intercom.unstable.ShowCallTranscriptRequest` +
-**requestOptions:** `News.RequestOptions` - +**requestOptions:** `CallsClient.RequestOptions` +
+
-
client.unstable.news.retrieveNewsItem({ ...params }) -> Intercom.NewsItem +
client.unstable.calls.listCallsWithTranscripts({ ...params }) -> Intercom.ListCallsWithTranscriptsResponse
@@ -15311,8 +19510,8 @@ await client.unstable.news.createNewsItem({
-You can fetch the details of a single news item. - +Retrieve calls by a list of conversation ids and include transcripts when available. +A maximum of 20 `conversation_ids` can be provided. If none are provided or more than 20 are provided, a 400 error is returned.
@@ -15327,11 +19526,11 @@ You can fetch the details of a single news item.
```typescript -await client.unstable.news.retrieveNewsItem({ - id: 1, +await client.unstable.calls.listCallsWithTranscripts({ + conversation_ids: ["64619700005694", "64619700005695"] }); -``` +```
@@ -15345,29 +19544,50 @@ await client.unstable.news.retrieveNewsItem({
-**request:** `Intercom.unstable.RetrieveNewsItemRequest` - -
-
- +**request:** `Intercom.unstable.ListCallsWithTranscriptsRequest` + + + + +
+
+ +**requestOptions:** `CallsClient.RequestOptions` + +
+
+ + + + + + +
+ +
client.unstable.calls.registerFinVoiceCall({ ...params }) -> Intercom.AiCallResponse +
+
+ +#### 📝 Description + +
+
+
-**requestOptions:** `News.RequestOptions` +Register a Fin Voice call with Intercom. This endpoint creates an external reference +that links an external call identifier to an Intercom call and conversation. +The call can be from different sources: +- AWS Connect (default) +- Five9 +- Zoom Phone
-
-
-
- -
client.unstable.news.updateNewsItem({ ...params }) -> Intercom.NewsItem -
-
- #### 🔌 Usage
@@ -15377,17 +19597,12 @@ await client.unstable.news.retrieveNewsItem({
```typescript -await client.unstable.news.updateNewsItem({ - id: 1, - body: { - title: "Christmas is here!", - body: "

New gifts in store for the jolly season

", - sender_id: 991267845, - reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"], - }, +await client.unstable.calls.registerFinVoiceCall({ + phone_number: "+1234567890", + call_id: "call-123-abc" }); -``` +```
@@ -15401,26 +19616,27 @@ await client.unstable.news.updateNewsItem({
-**request:** `Intercom.unstable.UpdateNewsItemRequest` - +**request:** `Intercom.RegisterFinVoiceCallRequest` +
-**requestOptions:** `News.RequestOptions` - +**requestOptions:** `CallsClient.RequestOptions` +
+
-
client.unstable.news.deleteNewsItem({ ...params }) -> Intercom.DeletedObject +
client.unstable.calls.collectFinVoiceCallById({ ...params }) -> Intercom.AiCallResponse
@@ -15432,8 +19648,7 @@ await client.unstable.news.updateNewsItem({
-You can delete a single news item. - +Retrieve information about a Fin Voice call using the external reference ID.
@@ -15448,11 +19663,11 @@ You can delete a single news item.
```typescript -await client.unstable.news.deleteNewsItem({ - id: 1, +await client.unstable.calls.collectFinVoiceCallById({ + id: 1 }); -``` +```
@@ -15466,26 +19681,27 @@ await client.unstable.news.deleteNewsItem({
-**request:** `Intercom.unstable.DeleteNewsItemRequest` - +**request:** `Intercom.unstable.CollectFinVoiceCallByIdRequest` +
-**requestOptions:** `News.RequestOptions` - +**requestOptions:** `CallsClient.RequestOptions` +
+
-
client.unstable.news.listLiveNewsfeedItems({ ...params }) -> Intercom.PaginatedResponse +
client.unstable.calls.collectFinVoiceCallByExternalId({ ...params }) -> Intercom.AiCallResponse
@@ -15497,8 +19713,7 @@ await client.unstable.news.deleteNewsItem({
-You can fetch a list of all news items that are live on a given newsfeed - +Retrieve information about a Fin Voice call using the external call identifier.
@@ -15513,11 +19728,11 @@ You can fetch a list of all news items that are live on a given newsfeed
```typescript -await client.unstable.news.listLiveNewsfeedItems({ - id: "123", +await client.unstable.calls.collectFinVoiceCallByExternalId({ + external_id: "external_id" }); -``` +```
@@ -15531,26 +19746,27 @@ await client.unstable.news.listLiveNewsfeedItems({
-**request:** `Intercom.unstable.ListLiveNewsfeedItemsRequest` - +**request:** `Intercom.unstable.CollectFinVoiceCallByExternalIdRequest` +
-**requestOptions:** `News.RequestOptions` - +**requestOptions:** `CallsClient.RequestOptions` +
+
-
client.unstable.news.listNewsfeeds() -> Intercom.PaginatedResponse +
client.unstable.calls.collectFinVoiceCallByPhoneNumber({ ...params }) -> Intercom.Error_
@@ -15562,8 +19778,9 @@ await client.unstable.news.listLiveNewsfeedItems({
-You can fetch a list of all newsfeeds +Retrieve information about a Fin Voice call using the phone number. +Returns the most recent matched call for the given phone number, ordered by creation date.
@@ -15578,9 +19795,11 @@ You can fetch a list of all newsfeeds
```typescript -await client.unstable.news.listNewsfeeds(); -``` +await client.unstable.calls.collectFinVoiceCallByPhoneNumber({ + phone_number: "phone_number" +}); +```
@@ -15594,18 +19813,28 @@ await client.unstable.news.listNewsfeeds();
-**requestOptions:** `News.RequestOptions` +**request:** `Intercom.unstable.CollectFinVoiceCallByPhoneNumberRequest` + +
+
+ +
+
+**requestOptions:** `CallsClient.RequestOptions` +
+
-
client.unstable.news.retrieveNewsfeed({ ...params }) -> Intercom.Newsfeed +## Teams +
client.unstable.teams.listTeams() -> Intercom.TeamList
@@ -15617,8 +19846,7 @@ await client.unstable.news.listNewsfeeds();
-You can fetch the details of a single newsfeed - +This will return a list of team objects for the App.
@@ -15633,11 +19861,9 @@ You can fetch the details of a single newsfeed
```typescript -await client.unstable.news.retrieveNewsfeed({ - id: "123", -}); -``` +await client.unstable.teams.listTeams(); +```
@@ -15651,28 +19877,19 @@ await client.unstable.news.retrieveNewsfeed({
-**request:** `Intercom.unstable.RetrieveNewsfeedRequest` - -
-
- -
-
- -**requestOptions:** `News.RequestOptions` - +**requestOptions:** `TeamsClient.RequestOptions` +
+
-## Segments - -
client.unstable.segments.listSegments({ ...params }) -> Intercom.SegmentList +
client.unstable.teams.retrieveTeam({ ...params }) -> Intercom.Team
@@ -15684,8 +19901,7 @@ await client.unstable.news.retrieveNewsfeed({
-You can fetch a list of all segments. - +You can fetch the details of a single team, containing an array of admins that belong to this team.
@@ -15700,9 +19916,11 @@ You can fetch a list of all segments.
```typescript -await client.unstable.segments.listSegments(); -``` +await client.unstable.teams.retrieveTeam({ + id: "123" +}); +```
@@ -15716,26 +19934,28 @@ await client.unstable.segments.listSegments();
-**request:** `Intercom.unstable.ListSegmentsRequest` - +**request:** `Intercom.unstable.RetrieveTeamRequest` +
-**requestOptions:** `Segments.RequestOptions` - +**requestOptions:** `TeamsClient.RequestOptions` +
+
-
client.unstable.segments.retrieveSegment({ ...params }) -> Intercom.Segment +## Ticket States +
client.unstable.ticketStates.listTicketStates() -> Intercom.TicketStateList
@@ -15747,8 +19967,7 @@ await client.unstable.segments.listSegments();
-You can fetch the details of a single segment. - +You can get a list of all ticket states for a workspace.
@@ -15763,11 +19982,9 @@ You can fetch the details of a single segment.
```typescript -await client.unstable.segments.retrieveSegment({ - id: "123", -}); -``` +await client.unstable.ticketStates.listTicketStates(); +```
@@ -15781,28 +19998,20 @@ await client.unstable.segments.retrieveSegment({
-**request:** `Intercom.unstable.RetrieveSegmentRequest` - -
-
- -
-
- -**requestOptions:** `Segments.RequestOptions` - +**requestOptions:** `TicketStatesClient.RequestOptions` +
+
-## Switch - -
client.unstable.switch.createPhoneSwitch({ ...params }) -> Intercom.PhoneSwitch | undefined +## Ticket Type Attributes +
client.unstable.ticketTypeAttributes.createTicketTypeAttribute({ ...params }) -> Intercom.TicketTypeAttribute | undefined
@@ -15814,11 +20023,7 @@ await client.unstable.segments.retrieveSegment({
-You can use the API to deflect phone calls to the Intercom Messenger. -Calling this endpoint will send an SMS with a link to the Messenger to the phone number specified. - -If custom attributes are specified, they will be added to the user or lead's custom data attributes. - +You can create a new attribute for a ticket type.
@@ -15833,11 +20038,15 @@ If custom attributes are specified, they will be added to the user or lead's cus
```typescript -await client.unstable.switch.createPhoneSwitch({ - key: "value", +await client.unstable.ticketTypeAttributes.createTicketTypeAttribute({ + ticket_type_id: "ticket_type_id", + name: "Attribute Title", + description: "Attribute Description", + data_type: "string", + required_to_create: false }); -``` +```
@@ -15851,28 +20060,27 @@ await client.unstable.switch.createPhoneSwitch({
-**request:** `unknown` - +**request:** `Intercom.unstable.CreateTicketTypeAttributeRequest` +
-**requestOptions:** `Switch.RequestOptions` - +**requestOptions:** `TicketTypeAttributesClient.RequestOptions` +
+
-## Teams - -
client.unstable.teams.listTeams() -> Intercom.TeamList +
client.unstable.ticketTypeAttributes.updateTicketTypeAttribute({ ...params }) -> Intercom.TicketTypeAttribute | undefined
@@ -15884,8 +20092,7 @@ await client.unstable.switch.createPhoneSwitch({
-This will return a list of team objects for the App. - +You can update an existing attribute for a ticket type.
@@ -15900,9 +20107,13 @@ This will return a list of team objects for the App.
```typescript -await client.unstable.teams.listTeams(); -``` +await client.unstable.ticketTypeAttributes.updateTicketTypeAttribute({ + ticket_type_id: "ticket_type_id", + id: "id", + description: "New Attribute Description" +}); +```
@@ -15916,18 +20127,28 @@ await client.unstable.teams.listTeams();
-**requestOptions:** `Teams.RequestOptions` +**request:** `Intercom.unstable.UpdateTicketTypeAttributeRequest` + +
+
+ +
+
+**requestOptions:** `TicketTypeAttributesClient.RequestOptions` +
+
-
client.unstable.teams.retrieveTeam({ ...params }) -> Intercom.Team +## Ticket Types +
client.unstable.ticketTypes.listTicketTypes() -> Intercom.TicketTypeList
@@ -15939,8 +20160,7 @@ await client.unstable.teams.listTeams();
-You can fetch the details of a single team, containing an array of admins that belong to this team. - +You can get a list of all ticket types for a workspace.
@@ -15955,11 +20175,9 @@ You can fetch the details of a single team, containing an array of admins that b
```typescript -await client.unstable.teams.retrieveTeam({ - id: "123", -}); -``` +await client.unstable.ticketTypes.listTicketTypes(); +```
@@ -15973,28 +20191,19 @@ await client.unstable.teams.retrieveTeam({
-**request:** `Intercom.unstable.RetrieveTeamRequest` - -
-
- -
-
- -**requestOptions:** `Teams.RequestOptions` - +**requestOptions:** `TicketTypesClient.RequestOptions` +
+
-## Ticket States - -
client.unstable.ticketStates.listTicketStates() -> Intercom.TicketStateList +
client.unstable.ticketTypes.createTicketType({ ...params }) -> Intercom.TicketType | undefined
@@ -16006,8 +20215,11 @@ await client.unstable.teams.retrieveTeam({
-You can get a list of all ticket states for a workspace. - +You can create a new ticket type. +> 📘 Creating ticket types. +> +> Every ticket type will be created with two default attributes: _default_title_ and _default_description_. +> For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/)
@@ -16022,9 +20234,11 @@ You can get a list of all ticket states for a workspace.
```typescript -await client.unstable.ticketStates.listTicketStates(); -``` +await client.unstable.ticketTypes.createTicketType({ + "key": "value" +}); +```
@@ -16038,20 +20252,27 @@ await client.unstable.ticketStates.listTicketStates();
-**requestOptions:** `TicketStates.RequestOptions` +**request:** `unknown` + +
+
+ +
+
+**requestOptions:** `TicketTypesClient.RequestOptions` +
+
-## Ticket Type Attributes - -
client.unstable.ticketTypeAttributes.createTicketTypeAttribute({ ...params }) -> Intercom.TicketTypeAttribute | undefined +
client.unstable.ticketTypes.getTicketType({ ...params }) -> Intercom.TicketType | undefined
@@ -16063,8 +20284,7 @@ await client.unstable.ticketStates.listTicketStates();
-You can create a new attribute for a ticket type. - +You can fetch the details of a single ticket type.
@@ -16079,15 +20299,11 @@ You can create a new attribute for a ticket type.
```typescript -await client.unstable.ticketTypeAttributes.createTicketTypeAttribute({ - ticket_type_id: "ticket_type_id", - name: "Attribute Title", - description: "Attribute Description", - data_type: "string", - required_to_create: false, +await client.unstable.ticketTypes.getTicketType({ + id: "id" }); -``` +```
@@ -16101,26 +20317,28 @@ await client.unstable.ticketTypeAttributes.createTicketTypeAttribute({
-**request:** `Intercom.unstable.CreateTicketTypeAttributeRequest` - +**request:** `Intercom.unstable.GetTicketTypeRequest` +
-**requestOptions:** `TicketTypeAttributes.RequestOptions` - +**requestOptions:** `TicketTypesClient.RequestOptions` +
+
-
client.unstable.ticketTypeAttributes.updateTicketTypeAttribute({ ...params }) -> Intercom.TicketTypeAttribute | undefined +## Tickets +
client.unstable.tickets.replyTicket({ ...params }) -> Intercom.TicketReply
@@ -16132,8 +20350,7 @@ await client.unstable.ticketTypeAttributes.createTicketTypeAttribute({
-You can update an existing attribute for a ticket type. - +You can reply to a ticket with a message from an admin or on behalf of a contact, or with a note for admins.
@@ -16148,13 +20365,17 @@ You can update an existing attribute for a ticket type.
```typescript -await client.unstable.ticketTypeAttributes.updateTicketTypeAttribute({ - ticket_type_id: "ticket_type_id", - id: "id", - description: "New Attribute Description", +await client.unstable.tickets.replyTicket({ + id: "123", + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2971bb69f9f2193bc49" + } }); -``` +```
@@ -16168,28 +20389,27 @@ await client.unstable.ticketTypeAttributes.updateTicketTypeAttribute({
-**request:** `Intercom.unstable.UpdateTicketTypeAttributeRequest` - +**request:** `Intercom.unstable.ReplyTicketRequest` +
-**requestOptions:** `TicketTypeAttributes.RequestOptions` - +**requestOptions:** `TicketsClient.RequestOptions` +
+
-## Ticket Types - -
client.unstable.ticketTypes.listTicketTypes() -> Intercom.TicketTypeList +
client.unstable.tickets.enqueueCreateTicket({ ...params }) -> Intercom.Jobs
@@ -16201,8 +20421,7 @@ await client.unstable.ticketTypeAttributes.updateTicketTypeAttribute({
-You can get a list of all ticket types for a workspace. - +Enqueues ticket creation for asynchronous processing, returning if the job was enqueued successfully to be processed. We attempt to perform a best-effort validation on inputs before tasks are enqueued. If the given parameters are incorrect, we won't enqueue the job.
@@ -16217,9 +20436,14 @@ You can get a list of all ticket types for a workspace.
```typescript -await client.unstable.ticketTypes.listTicketTypes(); -``` +await client.unstable.tickets.enqueueCreateTicket({ + ticket_type_id: "1234", + contacts: [{ + id: "6762f2d81bb69f9f2193bc54" + }] +}); +```
@@ -16233,18 +20457,27 @@ await client.unstable.ticketTypes.listTicketTypes();
-**requestOptions:** `TicketTypes.RequestOptions` - +**request:** `Intercom.unstable.EnqueueCreateTicketRequest` + +
+
+ +
+
+ +**requestOptions:** `TicketsClient.RequestOptions` +
+
-
client.unstable.ticketTypes.createTicketType({ ...params }) -> Intercom.TicketType | undefined +
client.unstable.tickets.getTicket({ ...params }) -> Intercom.Ticket | undefined
@@ -16256,13 +20489,7 @@ await client.unstable.ticketTypes.listTicketTypes();
-You can create a new ticket type. - -> 📘 Creating ticket types. -> -> Every ticket type will be created with two default attributes: _default_title_ and _default_description_. -> For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) - +You can fetch the details of a single ticket.
@@ -16277,11 +20504,11 @@ You can create a new ticket type.
```typescript -await client.unstable.ticketTypes.createTicketType({ - key: "value", +await client.unstable.tickets.getTicket({ + id: "id" }); -``` +```
@@ -16295,26 +20522,27 @@ await client.unstable.ticketTypes.createTicketType({
-**request:** `unknown` - +**request:** `Intercom.unstable.GetTicketRequest` +
-**requestOptions:** `TicketTypes.RequestOptions` - +**requestOptions:** `TicketsClient.RequestOptions` +
+
-
client.unstable.ticketTypes.getTicketType({ ...params }) -> Intercom.TicketType | undefined +
client.unstable.tickets.updateTicket({ ...params }) -> Intercom.Ticket | undefined
@@ -16326,8 +20554,7 @@ await client.unstable.ticketTypes.createTicketType({
-You can fetch the details of a single ticket type. - +You can update a ticket.
@@ -16342,11 +20569,20 @@ You can fetch the details of a single ticket type.
```typescript -await client.unstable.ticketTypes.getTicketType({ +await client.unstable.tickets.updateTicket({ id: "id", + ticket_attributes: { + "_default_title_": "example", + "_default_description_": "there is a problem" + }, + ticket_state_id: "123", + open: true, + snoozed_until: 1673609604, + admin_id: 991268011, + assignee_id: "123" }); -``` +```
@@ -16360,28 +20596,27 @@ await client.unstable.ticketTypes.getTicketType({
-**request:** `Intercom.unstable.GetTicketTypeRequest` - +**request:** `Intercom.unstable.UpdateTicketRequest` +
-**requestOptions:** `TicketTypes.RequestOptions` - +**requestOptions:** `TicketsClient.RequestOptions` +
+
-## Tickets - -
client.unstable.tickets.replyTicket({ ...params }) -> Intercom.TicketReply +
client.unstable.tickets.deleteTicket({ ...params }) -> Intercom.DeleteTicketResponse
@@ -16393,8 +20628,7 @@ await client.unstable.ticketTypes.getTicketType({
-You can reply to a ticket with a message from an admin or on behalf of a contact, or with a note for admins. - +You can delete a ticket using the Intercom provided ID.
@@ -16409,17 +20643,11 @@ You can reply to a ticket with a message from an admin or on behalf of a contact
```typescript -await client.unstable.tickets.replyTicket({ - id: "123", - body: { - message_type: "comment", - type: "user", - body: "Thanks again :)", - intercom_user_id: "6762f2971bb69f9f2193bc49", - }, +await client.unstable.tickets.deleteTicket({ + id: "id" }); -``` +```
@@ -16433,26 +20661,27 @@ await client.unstable.tickets.replyTicket({
-**request:** `Intercom.unstable.ReplyTicketRequest` - +**request:** `Intercom.unstable.DeleteTicketRequest` +
-**requestOptions:** `Tickets.RequestOptions` - +**requestOptions:** `TicketsClient.RequestOptions` +
+
-
client.unstable.tickets.enqueueCreateTicket({ ...params }) -> Intercom.Jobs +
client.unstable.tickets.searchTickets({ ...params }) -> Intercom.TicketList
@@ -16464,8 +20693,75 @@ await client.unstable.tickets.replyTicket({
-Enqueues ticket creation for asynchronous processing, returning if the job was enqueued successfully to be processed. We attempt to perform a best-effort validation on inputs before tasks are enqueued. If the given parameters are incorrect, we won't enqueue the job. +You can search for multiple tickets by the value of their attributes in order to fetch exactly which ones you want. + +To search for tickets, you send a `POST` request to `https://api.intercom.io/tickets/search`. + +This will accept a query object in the body which will define your filters. +{% admonition type="warning" name="Optimizing search queries" %} + Search queries can be complex, so optimizing them can help the performance of your search. + Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize + pagination to limit the number of results returned. The default is `20` results per page. + See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. +{% /admonition %} + +### Nesting & Limitations + +You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). +There are some limitations to the amount of multiples there can be: +- There's a limit of max 2 nested filters +- There's a limit of max 15 filters for each AND or OR group + +### Accepted Fields + +Most keys listed as part of the Ticket model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foobar"`). +The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. + +| Field | Type | +| :---------------------------------------- | :--------------------------------------------------------------------------------------- | +| id | String | +| created_at | Date (UNIX timestamp) | +| updated_at | Date (UNIX timestamp) | +| title | String | +| description | String | +| category | String | +| ticket_type_id | String | +| contact_ids | String | +| teammate_ids | String | +| admin_assignee_id | String | +| team_assignee_id | String | +| open | Boolean | +| state | String | +| snoozed_until | Date (UNIX timestamp) | +| ticket_attribute.{id} | String or Boolean or Date (UNIX timestamp) or Float or Integer | + +{% admonition type="info" name="Searching by Category" %} +When searching for tickets by the **`category`** field, specific terms must be used instead of the category names: +* For **Customer** category tickets, use the term `request`. +* For **Back-office** category tickets, use the term `task`. +* For **Tracker** category tickets, use the term `tracker`. +{% /admonition %} + +### Accepted Operators + +{% admonition type="info" name="Searching based on `created_at`" %} + You may use the `<=` or `>=` operators to search by `created_at`. +{% /admonition %} +The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). + +| Operator | Valid Types | Description | +| :------- | :----------------------------- | :----------------------------------------------------------- | +| = | All | Equals | +| != | All | Doesn't Equal | +| IN | All | In Shortcut for `OR` queries Values most be in Array | +| NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | +| > | Integer Date (UNIX Timestamp) | Greater (or equal) than | +| < | Integer Date (UNIX Timestamp) | Lower (or equal) than | +| ~ | String | Contains | +| !~ | String | Doesn't Contain | +| ^ | String | Starts With | +| $ | String | Ends With |
@@ -16480,16 +20776,21 @@ Enqueues ticket creation for asynchronous processing, returning if the job was e
```typescript -await client.unstable.tickets.enqueueCreateTicket({ - ticket_type_id: "1234", - contacts: [ - { - id: "6762f2d81bb69f9f2193bc54", - }, - ], +await client.unstable.tickets.searchTickets({ + query: { + operator: "AND", + value: [{ + field: "created_at", + operator: ">", + value: "1306054154" + }] + }, + pagination: { + per_page: 5 + } }); -``` +```
@@ -16503,26 +20804,28 @@ await client.unstable.tickets.enqueueCreateTicket({
-**request:** `Intercom.unstable.EnqueueCreateTicketRequest` - +**request:** `Intercom.SearchRequest` +
-**requestOptions:** `Tickets.RequestOptions` - +**requestOptions:** `TicketsClient.RequestOptions` +
+
-
client.unstable.tickets.getTicket({ ...params }) -> Intercom.Ticket | undefined +## Visitors +
client.unstable.visitors.retrieveVisitorWithUserId({ ...params }) -> Intercom.Visitor | undefined
@@ -16534,8 +20837,7 @@ await client.unstable.tickets.enqueueCreateTicket({
-You can fetch the details of a single ticket. - +You can fetch the details of a single visitor.
@@ -16550,11 +20852,11 @@ You can fetch the details of a single ticket.
```typescript -await client.unstable.tickets.getTicket({ - id: "id", +await client.unstable.visitors.retrieveVisitorWithUserId({ + user_id: "user_id" }); -``` +```
@@ -16568,26 +20870,27 @@ await client.unstable.tickets.getTicket({
-**request:** `Intercom.unstable.GetTicketRequest` - +**request:** `Intercom.unstable.RetrieveVisitorWithUserIdRequest` +
-**requestOptions:** `Tickets.RequestOptions` - +**requestOptions:** `VisitorsClient.RequestOptions` +
+
-
client.unstable.tickets.updateTicket({ ...params }) -> Intercom.Ticket | undefined +
client.unstable.visitors.updateVisitor({ ...params }) -> Intercom.Visitor | undefined
@@ -16599,8 +20902,11 @@ await client.unstable.tickets.getTicket({
-You can update a ticket. +Sending a PUT request to `/visitors` will result in an update of an existing Visitor. + +**Option 1.** You can update a visitor by passing in the `user_id` of the visitor in the Request body. +**Option 2.** You can update a visitor by passing in the `id` of the visitor in the Request body.
@@ -16615,20 +20921,12 @@ You can update a ticket.
```typescript -await client.unstable.tickets.updateTicket({ - id: "id", - ticket_attributes: { - _default_title_: "example", - _default_description_: "there is a problem", - }, - ticket_state_id: "123", - open: true, - snoozed_until: 1673609604, - admin_id: 991268011, - assignee_id: "123", +await client.unstable.visitors.updateVisitor({ + "id": "6762f30c1bb69f9f2193bc5e", + "name": "Gareth Bale" }); -``` +```
@@ -16642,26 +20940,27 @@ await client.unstable.tickets.updateTicket({
-**request:** `Intercom.unstable.UpdateTicketRequest` - +**request:** `Intercom.UpdateVisitorRequestOne` +
-**requestOptions:** `Tickets.RequestOptions` - +**requestOptions:** `VisitorsClient.RequestOptions` +
+
-
client.unstable.tickets.deleteTicket({ ...params }) -> Intercom.DeleteTicketResponse +
client.unstable.visitors.convertVisitor({ ...params }) -> Intercom.Contact
@@ -16673,8 +20972,11 @@ await client.unstable.tickets.updateTicket({
-You can delete a ticket using the Intercom provided ID. +You can merge a Visitor to a Contact of role type `lead` or `user`. +> 📘 What happens upon a visitor being converted? +> +> If the User exists, then the Visitor will be merged into it, the Visitor deleted and the User returned. If the User does not exist, the Visitor will be converted to a User, with the User identifiers replacing it's Visitor identifiers.
@@ -16689,11 +20991,17 @@ You can delete a ticket using the Intercom provided ID.
```typescript -await client.unstable.tickets.deleteTicket({ - id: "id", +await client.unstable.visitors.convertVisitor({ + type: "user", + user: { + "email": "foo@bar.com" + }, + visitor: { + "user_id": "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3" + } }); -``` +```
@@ -16707,26 +21015,28 @@ await client.unstable.tickets.deleteTicket({
-**request:** `Intercom.unstable.DeleteTicketRequest` - +**request:** `Intercom.unstable.ConvertVisitorRequest` +
-**requestOptions:** `Tickets.RequestOptions` - +**requestOptions:** `VisitorsClient.RequestOptions` +
+
-
client.unstable.tickets.searchTickets({ ...params }) -> Intercom.TicketList +## Brands +
client.unstable.brands.listBrands() -> Intercom.BrandList
@@ -16738,70 +21048,8 @@ await client.unstable.tickets.deleteTicket({
-You can search for multiple tickets by the value of their attributes in order to fetch exactly which ones you want. - -To search for tickets, you send a `POST` request to `https://api.intercom.io/tickets/search`. - -This will accept a query object in the body which will define your filters. -{% admonition type="warning" name="Optimizing search queries" %} -Search queries can be complex, so optimizing them can help the performance of your search. -Use the `AND` and `OR` operators to combine multiple filters to get the exact results you need and utilize -pagination to limit the number of results returned. The default is `20` results per page. -See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#example-search-conversations-request) for more details on how to use the `starting_after` param. -{% /admonition %} - -### Nesting & Limitations - -You can nest these filters in order to get even more granular insights that pinpoint exactly what you need. Example: (1 OR 2) AND (3 OR 4). -There are some limitations to the amount of multiples there can be: - -- There's a limit of max 2 nested filters -- There's a limit of max 15 filters for each AND or OR group - -### Accepted Fields - -Most keys listed as part of the Ticket model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foobar"`). -The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. - -| Field | Type | -| :-------------------- | :------------------------------------------------------------- | -| id | String | -| created_at | Date (UNIX timestamp) | -| updated_at | Date (UNIX timestamp) | -| _default_title_ | String | -| _default_description_ | String | -| category | String | -| ticket_type_id | String | -| contact_ids | String | -| teammate_ids | String | -| admin_assignee_id | String | -| team_assignee_id | String | -| open | Boolean | -| state | String | -| snoozed_until | Date (UNIX timestamp) | -| ticket_attribute.{id} | String or Boolean or Date (UNIX timestamp) or Float or Integer | - -### Accepted Operators - -{% admonition type="info" name="Searching based on `created_at`" %} -You may use the `<=` or `>=` operators to search by `created_at`. -{% /admonition %} - -The table below shows the operators you can use to define how you want to search for the value. The operator should be put in as a string (`"="`). The operator has to be compatible with the field's type (eg. you cannot search with `>` for a given string value as it's only compatible for integer's and dates). - -| Operator | Valid Types | Description | -| :------- | :---------------------------- | :--------------------------------------------------------- | -| = | All | Equals | -| != | All | Doesn't Equal | -| IN | All | In Shortcut for `OR` queries Values most be in Array | -| NIN | All | Not In Shortcut for `OR !` queries Values must be in Array | -| > | Integer Date (UNIX Timestamp) | Greater (or equal) than | -| < | Integer Date (UNIX Timestamp) | Lower (or equal) than | -| ~ | String | Contains | -| !~ | String | Doesn't Contain | -| ^ | String | Starts With | -| $ | String | Ends With | - +Retrieves all brands for the workspace, including the default brand. +The default brand id always matches the workspace
@@ -16816,23 +21064,9 @@ The table below shows the operators you can use to define how you want to search
```typescript -await client.unstable.tickets.searchTickets({ - query: { - operator: "AND", - value: [ - { - field: "created_at", - operator: ">", - value: "1306054154", - }, - ], - }, - pagination: { - per_page: 5, - }, -}); -``` +await client.unstable.brands.listBrands(); +```
@@ -16846,28 +21080,19 @@ await client.unstable.tickets.searchTickets({
-**request:** `Intercom.SearchRequest` - -
-
- -
-
- -**requestOptions:** `Tickets.RequestOptions` - +**requestOptions:** `BrandsClient.RequestOptions` +
+
-## Visitors - -
client.unstable.visitors.retrieveVisitorWithUserId({ ...params }) -> Intercom.Visitor | undefined +
client.unstable.brands.retrieveBrand({ ...params }) -> Intercom.Brand
@@ -16879,8 +21104,7 @@ await client.unstable.tickets.searchTickets({
-You can fetch the details of a single visitor. - +Fetches a specific brand by its unique identifier
@@ -16895,11 +21119,11 @@ You can fetch the details of a single visitor.
```typescript -await client.unstable.visitors.retrieveVisitorWithUserId({ - user_id: "user_id", +await client.unstable.brands.retrieveBrand({ + id: "id" }); -``` +```
@@ -16913,26 +21137,28 @@ await client.unstable.visitors.retrieveVisitorWithUserId({
-**request:** `Intercom.unstable.RetrieveVisitorWithUserIdRequest` - +**request:** `Intercom.unstable.RetrieveBrandRequest` +
-**requestOptions:** `Visitors.RequestOptions` - +**requestOptions:** `BrandsClient.RequestOptions` +
+
-
client.unstable.visitors.updateVisitor({ ...params }) -> Intercom.Visitor | undefined +## Emails +
client.unstable.emails.listEmails() -> Intercom.EmailList
@@ -16944,12 +21170,7 @@ await client.unstable.visitors.retrieveVisitorWithUserId({
-Sending a PUT request to `/visitors` will result in an update of an existing Visitor. - -**Option 1.** You can update a visitor by passing in the `user_id` of the visitor in the Request body. - -**Option 2.** You can update a visitor by passing in the `id` of the visitor in the Request body. - +Lists all sender email address settings for the workspace
@@ -16964,12 +21185,9 @@ Sending a PUT request to `/visitors` will result in an update of an existing Vis
```typescript -await client.unstable.visitors.updateVisitor({ - id: "6762f30c1bb69f9f2193bc5e", - name: "Gareth Bale", -}); -``` +await client.unstable.emails.listEmails(); +```
@@ -16983,26 +21201,19 @@ await client.unstable.visitors.updateVisitor({
-**request:** `Intercom.UpdateVisitorRequestOne` - -
-
- -
-
- -**requestOptions:** `Visitors.RequestOptions` - +**requestOptions:** `EmailsClient.RequestOptions` +
+
-
client.unstable.visitors.convertVisitor({ ...params }) -> Intercom.Contact +
client.unstable.emails.retrieveEmail({ ...params }) -> Intercom.EmailSetting
@@ -17014,12 +21225,7 @@ await client.unstable.visitors.updateVisitor({
-You can merge a Visitor to a Contact of role type `lead` or `user`. - -> 📘 What happens upon a visitor being converted? -> -> If the User exists, then the Visitor will be merged into it, the Visitor deleted and the User returned. If the User does not exist, the Visitor will be converted to a User, with the User identifiers replacing it's Visitor identifiers. - +Fetches a specific email setting by its unique identifier
@@ -17034,17 +21240,11 @@ You can merge a Visitor to a Contact of role type `lead` or `user`.
```typescript -await client.unstable.visitors.convertVisitor({ - type: "user", - user: { - email: "foo@bar.com", - }, - visitor: { - user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", - }, +await client.unstable.emails.retrieveEmail({ + id: "id" }); -``` +```
@@ -17058,21 +21258,22 @@ await client.unstable.visitors.convertVisitor({
-**request:** `Intercom.unstable.ConvertVisitorRequest` - +**request:** `Intercom.unstable.RetrieveEmailRequest` +
-**requestOptions:** `Visitors.RequestOptions` - +**requestOptions:** `EmailsClient.RequestOptions` +
+
diff --git a/scripts/rename-to-esm-files.js b/scripts/rename-to-esm-files.js index 81dac6a7..dc1df1cb 100644 --- a/scripts/rename-to-esm-files.js +++ b/scripts/rename-to-esm-files.js @@ -50,8 +50,16 @@ async function updateFileContents(file) { let newContent = content; // Update each extension type defined in the map for (const [oldExt, newExt] of Object.entries(extensionMap)) { - const regex = new RegExp(`(import|export)(.+from\\s+['"])(\\.\\.?\\/[^'"]+)(\\${oldExt})(['"])`, "g"); - newContent = newContent.replace(regex, `$1$2$3${newExt}$5`); + // Handle static imports/exports + const staticRegex = new RegExp(`(import|export)(.+from\\s+['"])(\\.\\.?\\/[^'"]+)(\\${oldExt})(['"])`, "g"); + newContent = newContent.replace(staticRegex, `$1$2$3${newExt}$5`); + + // Handle dynamic imports (yield import, await import, regular import()) + const dynamicRegex = new RegExp( + `(yield\\s+import|await\\s+import|import)\\s*\\(\\s*['"](\\.\\.\?\\/[^'"]+)(\\${oldExt})['"]\\s*\\)`, + "g", + ); + newContent = newContent.replace(dynamicRegex, `$1("$2${newExt}")`); } if (content !== newContent) { diff --git a/src/BaseClient.ts b/src/BaseClient.ts new file mode 100644 index 00000000..45d31870 --- /dev/null +++ b/src/BaseClient.ts @@ -0,0 +1,131 @@ +// This file was auto-generated by Fern from our API Definition. + +import { BearerAuthProvider } from "./auth/BearerAuthProvider.js"; +import { mergeHeaders } from "./core/headers.js"; +import * as core from "./core/index.js"; +import type * as environments from "./environments.js"; + +export interface BaseClientOptions { + environment?: core.Supplier; + /** Specify a custom URL to connect the client to. */ + baseUrl?: core.Supplier; + token?: core.Supplier; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "2.12" + | "2.13" + | "2.14" + | "Unstable"; + /** Additional headers to include in requests. */ + headers?: Record | null | undefined>; + /** The default maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The default number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** Provide a custom fetch implementation. Useful for platforms that don't have a built-in fetch or need a custom implementation. */ + fetch?: typeof fetch; + fetcher?: core.FetchFunction; + /** Configure logging for the client. */ + logging?: core.logging.LogConfig | core.logging.Logger; +} + +export interface BaseRequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional query string parameters to include in the request. */ + queryParams?: Record; + /** Additional headers to include in the request. */ + headers?: Record | null | undefined>; + /** Override the Intercom-Version header */ + version?: + | "1.0" + | "1.1" + | "1.2" + | "1.3" + | "1.4" + | "2.0" + | "2.1" + | "2.2" + | "2.3" + | "2.4" + | "2.5" + | "2.6" + | "2.7" + | "2.8" + | "2.9" + | "2.10" + | "2.11" + | "2.12" + | "2.13" + | "2.14" + | "Unstable"; +} + +export type NormalizedClientOptions = T & { + logging: core.logging.Logger; + authProvider?: core.AuthProvider; +}; + +export type NormalizedClientOptionsWithAuth = NormalizedClientOptions & { + authProvider: core.AuthProvider; +}; + +export function normalizeClientOptions(options: T): NormalizedClientOptions { + const headers = mergeHeaders( + { + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "intercom-client", + "X-Fern-SDK-Version": "7.0.0", + "User-Agent": "intercom-client/7.0.0", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + "Intercom-Version": options?.version ?? "2.14", + }, + options?.headers, + ); + + return { + ...options, + logging: core.logging.createLogger(options?.logging), + headers, + } as NormalizedClientOptions; +} + +export function normalizeClientOptionsWithAuth( + options: T, +): NormalizedClientOptionsWithAuth { + const normalized = normalizeClientOptions(options) as NormalizedClientOptionsWithAuth; + const normalizedWithNoOpAuthProvider = withNoOpAuthProvider(normalized); + normalized.authProvider ??= new BearerAuthProvider(normalizedWithNoOpAuthProvider); + return normalized; +} + +function withNoOpAuthProvider( + options: NormalizedClientOptions, +): NormalizedClientOptionsWithAuth { + return { + ...options, + authProvider: new core.NoOpAuthProvider(), + }; +} diff --git a/src/Client.ts b/src/Client.ts index bdbba22c..8db0d729 100644 --- a/src/Client.ts +++ b/src/Client.ts @@ -1,198 +1,198 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as environments from "./environments"; -import * as core from "./core"; -import { Admins } from "./api/resources/admins/client/Client"; -import { Articles } from "./api/resources/articles/client/Client"; -import { HelpCenters } from "./api/resources/helpCenters/client/Client"; -import { Companies } from "./api/resources/companies/client/Client"; -import { Contacts } from "./api/resources/contacts/client/Client"; -import { Notes } from "./api/resources/notes/client/Client"; -import { Tags } from "./api/resources/tags/client/Client"; -import { Conversations } from "./api/resources/conversations/client/Client"; -import { DataAttributes } from "./api/resources/dataAttributes/client/Client"; -import { Events } from "./api/resources/events/client/Client"; -import { DataExport } from "./api/resources/dataExport/client/Client"; -import { Messages } from "./api/resources/messages/client/Client"; -import { Segments } from "./api/resources/segments/client/Client"; -import { SubscriptionTypes } from "./api/resources/subscriptionTypes/client/Client"; -import { PhoneCallRedirects } from "./api/resources/phoneCallRedirects/client/Client"; -import { Teams } from "./api/resources/teams/client/Client"; -import { TicketTypes } from "./api/resources/ticketTypes/client/Client"; -import { Tickets } from "./api/resources/tickets/client/Client"; -import { Visitors } from "./api/resources/visitors/client/Client"; -import { News } from "./api/resources/news/client/Client"; -import { Unstable } from "./api/resources/unstable/client/Client"; +// This file was auto-generated by Fern from our API Definition. + +import { AdminsClient } from "./api/resources/admins/client/Client.js"; +import { AiContentClient } from "./api/resources/aiContent/client/Client.js"; +import { ArticlesClient } from "./api/resources/articles/client/Client.js"; +import { AwayStatusReasonsClient } from "./api/resources/awayStatusReasons/client/Client.js"; +import { CallsClient } from "./api/resources/calls/client/Client.js"; +import { CompaniesClient } from "./api/resources/companies/client/Client.js"; +import { ContactsClient } from "./api/resources/contacts/client/Client.js"; +import { ConversationsClient } from "./api/resources/conversations/client/Client.js"; +import { CustomChannelEventsClient } from "./api/resources/customChannelEvents/client/Client.js"; +import { CustomObjectInstancesClient } from "./api/resources/customObjectInstances/client/Client.js"; +import { DataAttributesClient } from "./api/resources/dataAttributes/client/Client.js"; +import { DataExportClient } from "./api/resources/dataExport/client/Client.js"; +import { EventsClient } from "./api/resources/events/client/Client.js"; +import { ExportClient } from "./api/resources/export/client/Client.js"; +import { HelpCentersClient } from "./api/resources/helpCenters/client/Client.js"; +import { InternalArticlesClient } from "./api/resources/internalArticles/client/Client.js"; +import { JobsClient } from "./api/resources/jobs/client/Client.js"; +import { MessagesClient } from "./api/resources/messages/client/Client.js"; +import { NewsClient } from "./api/resources/news/client/Client.js"; +import { NotesClient } from "./api/resources/notes/client/Client.js"; +import { PhoneCallRedirectsClient } from "./api/resources/phoneCallRedirects/client/Client.js"; +import { SegmentsClient } from "./api/resources/segments/client/Client.js"; +import { SubscriptionTypesClient } from "./api/resources/subscriptionTypes/client/Client.js"; +import { TagsClient } from "./api/resources/tags/client/Client.js"; +import { TeamsClient } from "./api/resources/teams/client/Client.js"; +import { TicketStatesClient } from "./api/resources/ticketStates/client/Client.js"; +import { TicketsClient } from "./api/resources/tickets/client/Client.js"; +import { TicketTypesClient } from "./api/resources/ticketTypes/client/Client.js"; +import { UnstableClient } from "./api/resources/unstable/client/Client.js"; +import { VisitorsClient } from "./api/resources/visitors/client/Client.js"; +import type { BaseClientOptions, BaseRequestOptions } from "./BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "./BaseClient.js"; export declare namespace IntercomClient { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } - - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} } export class IntercomClient { - protected _admins: Admins | undefined; - protected _articles: Articles | undefined; - protected _helpCenters: HelpCenters | undefined; - protected _companies: Companies | undefined; - protected _contacts: Contacts | undefined; - protected _notes: Notes | undefined; - protected _tags: Tags | undefined; - protected _conversations: Conversations | undefined; - protected _dataAttributes: DataAttributes | undefined; - protected _events: Events | undefined; - protected _dataExport: DataExport | undefined; - protected _messages: Messages | undefined; - protected _segments: Segments | undefined; - protected _subscriptionTypes: SubscriptionTypes | undefined; - protected _phoneCallRedirects: PhoneCallRedirects | undefined; - protected _teams: Teams | undefined; - protected _ticketTypes: TicketTypes | undefined; - protected _tickets: Tickets | undefined; - protected _visitors: Visitors | undefined; - protected _news: News | undefined; - protected _unstable: Unstable | undefined; + protected readonly _options: NormalizedClientOptionsWithAuth; + protected _admins: AdminsClient | undefined; + protected _aiContent: AiContentClient | undefined; + protected _articles: ArticlesClient | undefined; + protected _awayStatusReasons: AwayStatusReasonsClient | undefined; + protected _export: ExportClient | undefined; + protected _dataExport: DataExportClient | undefined; + protected _helpCenters: HelpCentersClient | undefined; + protected _internalArticles: InternalArticlesClient | undefined; + protected _companies: CompaniesClient | undefined; + protected _contacts: ContactsClient | undefined; + protected _notes: NotesClient | undefined; + protected _tags: TagsClient | undefined; + protected _conversations: ConversationsClient | undefined; + protected _customChannelEvents: CustomChannelEventsClient | undefined; + protected _customObjectInstances: CustomObjectInstancesClient | undefined; + protected _dataAttributes: DataAttributesClient | undefined; + protected _events: EventsClient | undefined; + protected _jobs: JobsClient | undefined; + protected _messages: MessagesClient | undefined; + protected _segments: SegmentsClient | undefined; + protected _subscriptionTypes: SubscriptionTypesClient | undefined; + protected _phoneCallRedirects: PhoneCallRedirectsClient | undefined; + protected _calls: CallsClient | undefined; + protected _teams: TeamsClient | undefined; + protected _ticketStates: TicketStatesClient | undefined; + protected _ticketTypes: TicketTypesClient | undefined; + protected _tickets: TicketsClient | undefined; + protected _visitors: VisitorsClient | undefined; + protected _news: NewsClient | undefined; + protected _unstable: UnstableClient | undefined; + + constructor(options: IntercomClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + public get admins(): AdminsClient { + return (this._admins ??= new AdminsClient(this._options)); + } - constructor(protected readonly _options: IntercomClient.Options = {}) {} + public get aiContent(): AiContentClient { + return (this._aiContent ??= new AiContentClient(this._options)); + } + + public get articles(): ArticlesClient { + return (this._articles ??= new ArticlesClient(this._options)); + } + + public get awayStatusReasons(): AwayStatusReasonsClient { + return (this._awayStatusReasons ??= new AwayStatusReasonsClient(this._options)); + } + + public get export(): ExportClient { + return (this._export ??= new ExportClient(this._options)); + } + + public get dataExport(): DataExportClient { + return (this._dataExport ??= new DataExportClient(this._options)); + } + + public get helpCenters(): HelpCentersClient { + return (this._helpCenters ??= new HelpCentersClient(this._options)); + } + + public get internalArticles(): InternalArticlesClient { + return (this._internalArticles ??= new InternalArticlesClient(this._options)); + } + + public get companies(): CompaniesClient { + return (this._companies ??= new CompaniesClient(this._options)); + } - public get admins(): Admins { - return (this._admins ??= new Admins(this._options)); + public get contacts(): ContactsClient { + return (this._contacts ??= new ContactsClient(this._options)); } - public get articles(): Articles { - return (this._articles ??= new Articles(this._options)); + public get notes(): NotesClient { + return (this._notes ??= new NotesClient(this._options)); } - public get helpCenters(): HelpCenters { - return (this._helpCenters ??= new HelpCenters(this._options)); + public get tags(): TagsClient { + return (this._tags ??= new TagsClient(this._options)); } - public get companies(): Companies { - return (this._companies ??= new Companies(this._options)); + public get conversations(): ConversationsClient { + return (this._conversations ??= new ConversationsClient(this._options)); } - public get contacts(): Contacts { - return (this._contacts ??= new Contacts(this._options)); + public get customChannelEvents(): CustomChannelEventsClient { + return (this._customChannelEvents ??= new CustomChannelEventsClient(this._options)); } - public get notes(): Notes { - return (this._notes ??= new Notes(this._options)); + public get customObjectInstances(): CustomObjectInstancesClient { + return (this._customObjectInstances ??= new CustomObjectInstancesClient(this._options)); } - public get tags(): Tags { - return (this._tags ??= new Tags(this._options)); + public get dataAttributes(): DataAttributesClient { + return (this._dataAttributes ??= new DataAttributesClient(this._options)); } - public get conversations(): Conversations { - return (this._conversations ??= new Conversations(this._options)); + public get events(): EventsClient { + return (this._events ??= new EventsClient(this._options)); } - public get dataAttributes(): DataAttributes { - return (this._dataAttributes ??= new DataAttributes(this._options)); + public get jobs(): JobsClient { + return (this._jobs ??= new JobsClient(this._options)); } - public get events(): Events { - return (this._events ??= new Events(this._options)); + public get messages(): MessagesClient { + return (this._messages ??= new MessagesClient(this._options)); } - public get dataExport(): DataExport { - return (this._dataExport ??= new DataExport(this._options)); + public get segments(): SegmentsClient { + return (this._segments ??= new SegmentsClient(this._options)); } - public get messages(): Messages { - return (this._messages ??= new Messages(this._options)); + public get subscriptionTypes(): SubscriptionTypesClient { + return (this._subscriptionTypes ??= new SubscriptionTypesClient(this._options)); } - public get segments(): Segments { - return (this._segments ??= new Segments(this._options)); + public get phoneCallRedirects(): PhoneCallRedirectsClient { + return (this._phoneCallRedirects ??= new PhoneCallRedirectsClient(this._options)); } - public get subscriptionTypes(): SubscriptionTypes { - return (this._subscriptionTypes ??= new SubscriptionTypes(this._options)); + public get calls(): CallsClient { + return (this._calls ??= new CallsClient(this._options)); } - public get phoneCallRedirects(): PhoneCallRedirects { - return (this._phoneCallRedirects ??= new PhoneCallRedirects(this._options)); + public get teams(): TeamsClient { + return (this._teams ??= new TeamsClient(this._options)); } - public get teams(): Teams { - return (this._teams ??= new Teams(this._options)); + public get ticketStates(): TicketStatesClient { + return (this._ticketStates ??= new TicketStatesClient(this._options)); } - public get ticketTypes(): TicketTypes { - return (this._ticketTypes ??= new TicketTypes(this._options)); + public get ticketTypes(): TicketTypesClient { + return (this._ticketTypes ??= new TicketTypesClient(this._options)); } - public get tickets(): Tickets { - return (this._tickets ??= new Tickets(this._options)); + public get tickets(): TicketsClient { + return (this._tickets ??= new TicketsClient(this._options)); } - public get visitors(): Visitors { - return (this._visitors ??= new Visitors(this._options)); + public get visitors(): VisitorsClient { + return (this._visitors ??= new VisitorsClient(this._options)); } - public get news(): News { - return (this._news ??= new News(this._options)); + public get news(): NewsClient { + return (this._news ??= new NewsClient(this._options)); } - public get unstable(): Unstable { - return (this._unstable ??= new Unstable(this._options)); + public get unstable(): UnstableClient { + return (this._unstable ??= new UnstableClient(this._options)); } } diff --git a/src/api/errors/BadRequestError.ts b/src/api/errors/BadRequestError.ts index 6d3e423f..90b9567c 100644 --- a/src/api/errors/BadRequestError.ts +++ b/src/api/errors/BadRequestError.ts @@ -1,9 +1,7 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as errors from "../../errors/index"; -import * as core from "../../core"; +import type * as core from "../../core/index.js"; +import * as errors from "../../errors/index.js"; export class BadRequestError extends errors.IntercomError { constructor(body?: unknown, rawResponse?: core.RawResponse) { diff --git a/src/api/errors/ForbiddenError.ts b/src/api/errors/ForbiddenError.ts index 45a3327c..3d3e38f8 100644 --- a/src/api/errors/ForbiddenError.ts +++ b/src/api/errors/ForbiddenError.ts @@ -1,10 +1,8 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as errors from "../../errors/index"; -import * as Intercom from "../index"; -import * as core from "../../core"; +import type * as core from "../../core/index.js"; +import * as errors from "../../errors/index.js"; +import type * as Intercom from "../index.js"; export class ForbiddenError extends errors.IntercomError { constructor(body: Intercom.Error_, rawResponse?: core.RawResponse) { diff --git a/src/api/errors/NotFoundError.ts b/src/api/errors/NotFoundError.ts index e99cdf65..e097f867 100644 --- a/src/api/errors/NotFoundError.ts +++ b/src/api/errors/NotFoundError.ts @@ -1,9 +1,7 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as errors from "../../errors/index"; -import * as core from "../../core"; +import type * as core from "../../core/index.js"; +import * as errors from "../../errors/index.js"; export class NotFoundError extends errors.IntercomError { constructor(body?: unknown, rawResponse?: core.RawResponse) { diff --git a/src/api/errors/TooManyRequestsError.ts b/src/api/errors/TooManyRequestsError.ts new file mode 100644 index 00000000..713f4ece --- /dev/null +++ b/src/api/errors/TooManyRequestsError.ts @@ -0,0 +1,17 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as core from "../../core/index.js"; +import * as errors from "../../errors/index.js"; +import type * as Intercom from "../index.js"; + +export class TooManyRequestsError extends errors.IntercomError { + constructor(body: Intercom.Error_, rawResponse?: core.RawResponse) { + super({ + message: "TooManyRequestsError", + statusCode: 429, + body: body, + rawResponse: rawResponse, + }); + Object.setPrototypeOf(this, TooManyRequestsError.prototype); + } +} diff --git a/src/api/errors/UnauthorizedError.ts b/src/api/errors/UnauthorizedError.ts index 0cafa7ae..16bbd3af 100644 --- a/src/api/errors/UnauthorizedError.ts +++ b/src/api/errors/UnauthorizedError.ts @@ -1,10 +1,8 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as errors from "../../errors/index"; -import * as Intercom from "../index"; -import * as core from "../../core"; +import type * as core from "../../core/index.js"; +import * as errors from "../../errors/index.js"; +import type * as Intercom from "../index.js"; export class UnauthorizedError extends errors.IntercomError { constructor(body: Intercom.Error_, rawResponse?: core.RawResponse) { diff --git a/src/api/errors/UnprocessableEntityError.ts b/src/api/errors/UnprocessableEntityError.ts index 7bb55289..ab175870 100644 --- a/src/api/errors/UnprocessableEntityError.ts +++ b/src/api/errors/UnprocessableEntityError.ts @@ -1,9 +1,7 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as errors from "../../errors/index"; -import * as core from "../../core"; +import type * as core from "../../core/index.js"; +import * as errors from "../../errors/index.js"; export class UnprocessableEntityError extends errors.IntercomError { constructor(body?: unknown, rawResponse?: core.RawResponse) { diff --git a/src/api/errors/index.ts b/src/api/errors/index.ts index f81dc80f..a8a67c9f 100644 --- a/src/api/errors/index.ts +++ b/src/api/errors/index.ts @@ -1,5 +1,6 @@ -export * from "./UnauthorizedError"; -export * from "./NotFoundError"; -export * from "./BadRequestError"; -export * from "./ForbiddenError"; -export * from "./UnprocessableEntityError"; +export * from "./BadRequestError.js"; +export * from "./ForbiddenError.js"; +export * from "./NotFoundError.js"; +export * from "./TooManyRequestsError.js"; +export * from "./UnauthorizedError.js"; +export * from "./UnprocessableEntityError.js"; diff --git a/src/api/index.ts b/src/api/index.ts index fefdd8f9..f847ea3d 100644 --- a/src/api/index.ts +++ b/src/api/index.ts @@ -1,4 +1,4 @@ -export * from "./resources"; -export * from "./types"; -export * from "./errors"; -export { IntercomVersion } from "./version"; +export * from "./errors/index.js"; +export * from "./resources/index.js"; +export * from "./types/index.js"; +export type { IntercomVersion } from "./version.js"; diff --git a/src/api/resources/admins/client/Client.ts b/src/api/resources/admins/client/Client.ts index 007cc89c..f836356f 100644 --- a/src/api/resources/admins/client/Client.ts +++ b/src/api/resources/admins/client/Client.ts @@ -1,79 +1,29 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace Admins { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace AdminsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Admins */ -export class Admins { - constructor(protected readonly _options: Admins.Options = {}) {} +export class AdminsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: AdminsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * @@ -83,45 +33,45 @@ export class Admins { * > * > If you are building a custom "Log in with Intercom" flow for your site, and you call the `/me` endpoint to identify the logged-in user, you should not accept any sign-ins from users with unverified email addresses as it poses a potential impersonation security risk. * - * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * @param {AdminsClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.admins.identify() */ - public identify(requestOptions?: Admins.RequestOptions): core.HttpResponsePromise { + public identify( + requestOptions?: AdminsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__identify(requestOptions)); } private async __identify( - requestOptions?: Admins.RequestOptions, - ): Promise> { + requestOptions?: AdminsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "me", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.AdminWithApp, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.AdminWithApp | undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -132,83 +82,80 @@ export class Admins { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /me."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/me"); } /** * You can set an Admin as away for the Inbox. * * @param {Intercom.ConfigureAwayAdminRequest} request - * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * @param {AdminsClient.RequestOptions} requestOptions - Request-specific configuration. * + * @throws {@link Intercom.BadRequestError} * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.admins.away({ - * admin_id: "admin_id", + * admin_id: 1, + * away_mode_enabled: true, + * away_mode_reassign: true, + * away_status_reason_id: 12345 + * }) + * + * @example + * await client.admins.away({ + * admin_id: 1, * away_mode_enabled: true, * away_mode_reassign: true * }) */ public away( request: Intercom.ConfigureAwayAdminRequest, - requestOptions?: Admins.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: AdminsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__away(request, requestOptions)); } private async __away( request: Intercom.ConfigureAwayAdminRequest, - requestOptions?: Admins.RequestOptions, - ): Promise> { + requestOptions?: AdminsClient.RequestOptions, + ): Promise> { const { admin_id: adminId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `admins/${encodeURIComponent(adminId)}/away`, + `admins/${core.url.encodePathParam(adminId)}/away`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.Admin, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.Admin | undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); case 401: throw new Intercom.UnauthorizedError( _response.error.body as Intercom.Error_, @@ -225,28 +172,14 @@ export class Admins { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /admins/{admin_id}/away."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/admins/{admin_id}/away"); } /** * You can get a log of activities by all admins in an app. * * @param {Intercom.ListAllActivityLogsRequest} request - * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * @param {AdminsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -258,47 +191,44 @@ export class Admins { */ public listAllActivityLogs( request: Intercom.ListAllActivityLogsRequest, - requestOptions?: Admins.RequestOptions, + requestOptions?: AdminsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listAllActivityLogs(request, requestOptions)); } private async __listAllActivityLogs( request: Intercom.ListAllActivityLogsRequest, - requestOptions?: Admins.RequestOptions, + requestOptions?: AdminsClient.RequestOptions, ): Promise> { const { created_at_after: createdAtAfter, created_at_before: createdAtBefore } = request; const _queryParams: Record = {}; - _queryParams["created_at_after"] = createdAtAfter; + _queryParams.created_at_after = createdAtAfter; if (createdAtBefore != null) { - _queryParams["created_at_before"] = createdAtBefore; + _queryParams.created_at_before = createdAtBefore; } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "admins/activity_logs", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.ActivityLogList, rawResponse: _response.rawResponse }; @@ -320,62 +250,48 @@ export class Admins { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins/activity_logs."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/admins/activity_logs"); } /** * You can fetch a list of admins for a given workspace. * - * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * @param {AdminsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * * @example * await client.admins.list() */ - public list(requestOptions?: Admins.RequestOptions): core.HttpResponsePromise { + public list(requestOptions?: AdminsClient.RequestOptions): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__list(requestOptions)); } - private async __list(requestOptions?: Admins.RequestOptions): Promise> { + private async __list( + requestOptions?: AdminsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "admins", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.AdminList, rawResponse: _response.rawResponse }; @@ -397,76 +313,60 @@ export class Admins { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/admins"); } /** * You can retrieve the details of a single admin. * * @param {Intercom.FindAdminRequest} request - * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * @param {AdminsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.admins.find({ - * admin_id: "123" + * admin_id: 1 * }) */ public find( request: Intercom.FindAdminRequest, - requestOptions?: Admins.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: AdminsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.FindAdminRequest, - requestOptions?: Admins.RequestOptions, - ): Promise> { + requestOptions?: AdminsClient.RequestOptions, + ): Promise> { const { admin_id: adminId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `admins/${encodeURIComponent(adminId)}`, + `admins/${core.url.encodePathParam(adminId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.Admin, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.Admin | undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -487,32 +387,6 @@ export class Admins { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins/{admin_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/admins/{admin_id}"); } } diff --git a/src/api/resources/admins/client/index.ts b/src/api/resources/admins/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/admins/client/index.ts +++ b/src/api/resources/admins/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/admins/client/requests/ConfigureAwayAdminRequest.ts b/src/api/resources/admins/client/requests/ConfigureAwayAdminRequest.ts index 524d1a23..0e21602b 100644 --- a/src/api/resources/admins/client/requests/ConfigureAwayAdminRequest.ts +++ b/src/api/resources/admins/client/requests/ConfigureAwayAdminRequest.ts @@ -1,36 +1,35 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * admin_id: "admin_id", + * admin_id: 1, * away_mode_enabled: true, - * away_mode_reassign: true + * away_mode_reassign: true, + * away_status_reason_id: 12345 * } * * @example * { - * admin_id: "admin_id", + * admin_id: 1, * away_mode_enabled: true, * away_mode_reassign: true * } * * @example * { - * admin_id: "admin_id", + * admin_id: 1, * away_mode_enabled: true, * away_mode_reassign: true * } */ export interface ConfigureAwayAdminRequest { - /** - * The unique identifier of a given admin - */ - admin_id: string; + /** The unique identifier of a given admin */ + admin_id: number; /** Set to "true" to change the status of the admin to away. */ away_mode_enabled: boolean; /** Set to "true" to assign any new conversation replies to your default inbox. */ away_mode_reassign: boolean; + /** The unique identifier of the away status reason */ + away_status_reason_id?: number; } diff --git a/src/api/resources/admins/client/requests/FindAdminRequest.ts b/src/api/resources/admins/client/requests/FindAdminRequest.ts index 85d66282..46f8a13f 100644 --- a/src/api/resources/admins/client/requests/FindAdminRequest.ts +++ b/src/api/resources/admins/client/requests/FindAdminRequest.ts @@ -1,16 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * admin_id: "123" + * admin_id: 1 * } */ export interface FindAdminRequest { - /** - * The unique identifier of a given admin - */ - admin_id: string; + /** The unique identifier of a given admin */ + admin_id: number; } diff --git a/src/api/resources/admins/client/requests/ListAllActivityLogsRequest.ts b/src/api/resources/admins/client/requests/ListAllActivityLogsRequest.ts index 1379e86e..b52e406b 100644 --- a/src/api/resources/admins/client/requests/ListAllActivityLogsRequest.ts +++ b/src/api/resources/admins/client/requests/ListAllActivityLogsRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -10,12 +8,8 @@ * } */ export interface ListAllActivityLogsRequest { - /** - * The start date that you request data for. It must be formatted as a UNIX timestamp. - */ + /** The start date that you request data for. It must be formatted as a UNIX timestamp. */ created_at_after: string; - /** - * The end date that you request data for. It must be formatted as a UNIX timestamp. - */ + /** The end date that you request data for. It must be formatted as a UNIX timestamp. */ created_at_before?: string; } diff --git a/src/api/resources/admins/client/requests/index.ts b/src/api/resources/admins/client/requests/index.ts index bf3a8602..9d853cb4 100644 --- a/src/api/resources/admins/client/requests/index.ts +++ b/src/api/resources/admins/client/requests/index.ts @@ -1,3 +1,3 @@ -export { type ConfigureAwayAdminRequest } from "./ConfigureAwayAdminRequest"; -export { type ListAllActivityLogsRequest } from "./ListAllActivityLogsRequest"; -export { type FindAdminRequest } from "./FindAdminRequest"; +export type { ConfigureAwayAdminRequest } from "./ConfigureAwayAdminRequest.js"; +export type { FindAdminRequest } from "./FindAdminRequest.js"; +export type { ListAllActivityLogsRequest } from "./ListAllActivityLogsRequest.js"; diff --git a/src/api/resources/admins/index.ts b/src/api/resources/admins/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/admins/index.ts +++ b/src/api/resources/admins/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/admins/types/Admin.ts b/src/api/resources/admins/types/Admin.ts index 33266da0..957fee42 100644 --- a/src/api/resources/admins/types/Admin.ts +++ b/src/api/resources/admins/types/Admin.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Admins are teammate accounts that have access to a workspace. */ export interface Admin { /** String representing the object's type. Always has the value `admin`. */ - type?: "admin"; + type?: string; /** The id representing the admin. */ id: string; /** The name of the admin. */ @@ -17,11 +15,13 @@ export interface Admin { /** The email of the admin. */ email: string; /** The job title of the admin. */ - job_title: string; + job_title?: string; /** Identifies if this admin is currently set in away mode. */ away_mode_enabled: boolean; /** Identifies if this admin is set to automatically reassign new conversations to the apps default inbox. */ away_mode_reassign: boolean; + /** The unique identifier of the away status reason */ + away_status_reason_id?: number; /** Identifies if this admin has a paid inbox seat to restrict/allow features that require them. */ has_inbox_seat: boolean; /** This object represents the avatar associated with the admin. */ diff --git a/src/api/resources/admins/types/index.ts b/src/api/resources/admins/types/index.ts index c950b2eb..838f94f4 100644 --- a/src/api/resources/admins/types/index.ts +++ b/src/api/resources/admins/types/index.ts @@ -1 +1 @@ -export * from "./Admin"; +export * from "./Admin.js"; diff --git a/src/api/resources/aiAgent/index.ts b/src/api/resources/aiAgent/index.ts index eea524d6..2f88e301 100644 --- a/src/api/resources/aiAgent/index.ts +++ b/src/api/resources/aiAgent/index.ts @@ -1 +1 @@ -export * from "./types"; +export * from "./types/index.js"; diff --git a/src/api/resources/aiAgent/types/AiAgent.ts b/src/api/resources/aiAgent/types/AiAgent.ts index af7c7974..19ae094e 100644 --- a/src/api/resources/aiAgent/types/AiAgent.ts +++ b/src/api/resources/aiAgent/types/AiAgent.ts @@ -1,33 +1,32 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Data related to AI Agent involvement in the conversation. */ export interface AiAgent { /** The type of the source that triggered AI Agent involvement in the conversation. */ - source_type: AiAgent.SourceType; + source_type?: AiAgent.SourceType; /** The title of the source that triggered AI Agent involvement in the conversation. If this is `essentials_plan_setup` then it will return `null`. */ source_title?: string; /** The type of the last answer delivered by AI Agent. If no answer was delivered then this will return `null` */ - last_answer_type?: string; + last_answer_type?: AiAgent.LastAnswerType; /** The resolution state of AI Agent. If no AI or custom answer has been delivered then this will return `null`. */ - resolution_state?: string; + resolution_state?: AiAgent.ResolutionState; /** The customer satisfaction rating given to AI Agent, from 1-5. */ rating?: number; /** The customer satisfaction rating remark given to AI Agent. */ rating_remark?: string; + /** The time when the AI agent rating was created. */ + created_at?: number; + /** The time when the AI agent rating was last updated. */ + updated_at?: number; content_sources?: Intercom.ContentSourcesList; } export namespace AiAgent { - /** - * The type of the source that triggered AI Agent involvement in the conversation. - */ - export type SourceType = "essentials_plan_setup" | "profile" | "workflow" | "workflow_preview" | "fin_preview"; + /** The type of the source that triggered AI Agent involvement in the conversation. */ export const SourceType = { EssentialsPlanSetup: "essentials_plan_setup", Profile: "profile", @@ -35,4 +34,19 @@ export namespace AiAgent { WorkflowPreview: "workflow_preview", FinPreview: "fin_preview", } as const; + export type SourceType = (typeof SourceType)[keyof typeof SourceType]; + /** The type of the last answer delivered by AI Agent. If no answer was delivered then this will return `null` */ + export const LastAnswerType = { + AiAnswer: "ai_answer", + CustomAnswer: "custom_answer", + } as const; + export type LastAnswerType = (typeof LastAnswerType)[keyof typeof LastAnswerType]; + /** The resolution state of AI Agent. If no AI or custom answer has been delivered then this will return `null`. */ + export const ResolutionState = { + AssumedResolution: "assumed_resolution", + ConfirmedResolution: "confirmed_resolution", + RoutedToTeam: "routed_to_team", + Abandoned: "abandoned", + } as const; + export type ResolutionState = (typeof ResolutionState)[keyof typeof ResolutionState]; } diff --git a/src/api/resources/aiAgent/types/index.ts b/src/api/resources/aiAgent/types/index.ts index 05de312f..27ef772f 100644 --- a/src/api/resources/aiAgent/types/index.ts +++ b/src/api/resources/aiAgent/types/index.ts @@ -1 +1 @@ -export * from "./AiAgent"; +export * from "./AiAgent.js"; diff --git a/src/api/resources/aiContent/client/Client.ts b/src/api/resources/aiContent/client/Client.ts new file mode 100644 index 00000000..2beabc07 --- /dev/null +++ b/src/api/resources/aiContent/client/Client.ts @@ -0,0 +1,776 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; + +export declare namespace AiContentClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * With the AI Content APIs, you can create and manage External Pages and Content Import Sources for your Fin Content Library. + * + *   + * + * *External Pages* are pages that you want Fin to be able to answer questions about. The API for External Pages is a great way to ingest into your Fin Content Library pages that are not publicly accessible and hence can't be crawled by Intercom. + * + *   + * + * *Content Import Sources* are the sources of those pages, and they are used to determine the default audience for the pages (configured via the UI). You should create a Content Import Source for each source of External Pages that you want to ingest into your Fin Content Library. + * + *   + * + * You can then iterate through the content from that source via its API and POST it to the External Pages endpoint. That endpoint has an *external_id* parameter which allows you to specify the identifier from the source. The endpoint will then either create a new External Page or update an existing one as appropriate.", + */ +export class AiContentClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: AiContentClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * You can retrieve a list of all content import sources for a workspace. + * + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.aiContent.listContentImportSources() + */ + public listContentImportSources( + requestOptions?: AiContentClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listContentImportSources(requestOptions)); + } + + private async __listContentImportSources( + requestOptions?: AiContentClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ai/content_import_sources", + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.ContentImportSourcesList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/ai/content_import_sources"); + } + + /** + * You can create a new content import source by sending a POST request to this endpoint. + * + * @param {Intercom.CreateContentImportSourceRequest} request + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.aiContent.createContentImportSource({ + * url: "https://www.example.com" + * }) + */ + public createContentImportSource( + request: Intercom.CreateContentImportSourceRequest, + requestOptions?: AiContentClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createContentImportSource(request, requestOptions)); + } + + private async __createContentImportSource( + request: Intercom.CreateContentImportSourceRequest, + requestOptions?: AiContentClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ai/content_import_sources", + ), + method: "POST", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: { ...request, sync_behavior: "api" }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.ContentImportSource, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/ai/content_import_sources"); + } + + /** + * @param {Intercom.GetContentImportSourceRequest} request + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.aiContent.getContentImportSource({ + * source_id: "source_id" + * }) + */ + public getContentImportSource( + request: Intercom.GetContentImportSourceRequest, + requestOptions?: AiContentClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__getContentImportSource(request, requestOptions)); + } + + private async __getContentImportSource( + request: Intercom.GetContentImportSourceRequest, + requestOptions?: AiContentClient.RequestOptions, + ): Promise> { + const { source_id: sourceId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ai/content_import_sources/${core.url.encodePathParam(sourceId)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.ContentImportSource, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/ai/content_import_sources/{source_id}", + ); + } + + /** + * You can update an existing content import source. + * + * @param {Intercom.UpdateContentImportSourceRequest} request + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.aiContent.updateContentImportSource({ + * source_id: "source_id", + * sync_behavior: "api", + * url: "https://www.example.com" + * }) + */ + public updateContentImportSource( + request: Intercom.UpdateContentImportSourceRequest, + requestOptions?: AiContentClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateContentImportSource(request, requestOptions)); + } + + private async __updateContentImportSource( + request: Intercom.UpdateContentImportSourceRequest, + requestOptions?: AiContentClient.RequestOptions, + ): Promise> { + const { source_id: sourceId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ai/content_import_sources/${core.url.encodePathParam(sourceId)}`, + ), + method: "PUT", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: _body, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.ContentImportSource, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "PUT", + "/ai/content_import_sources/{source_id}", + ); + } + + /** + * You can delete a content import source by making a DELETE request this endpoint. This will also delete all external pages that were imported from this source. + * + * @param {Intercom.DeleteContentImportSourceRequest} request + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.aiContent.deleteContentImportSource({ + * source_id: "source_id" + * }) + */ + public deleteContentImportSource( + request: Intercom.DeleteContentImportSourceRequest, + requestOptions?: AiContentClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteContentImportSource(request, requestOptions)); + } + + private async __deleteContentImportSource( + request: Intercom.DeleteContentImportSourceRequest, + requestOptions?: AiContentClient.RequestOptions, + ): Promise> { + const { source_id: sourceId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ai/content_import_sources/${core.url.encodePathParam(sourceId)}`, + ), + method: "DELETE", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: undefined, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/ai/content_import_sources/{source_id}", + ); + } + + /** + * You can retrieve a list of all external pages for a workspace. + * + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.aiContent.listExternalPages() + */ + public listExternalPages( + requestOptions?: AiContentClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listExternalPages(requestOptions)); + } + + private async __listExternalPages( + requestOptions?: AiContentClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ai/external_pages", + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.ExternalPagesList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/ai/external_pages"); + } + + /** + * You can create a new external page by sending a POST request to this endpoint. If an external page already exists with the specified source_id and external_id, it will be updated instead. + * + * @param {Intercom.CreateExternalPageRequest} request + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.aiContent.createExternalPage({ + * title: "Test", + * html: "

Test

", + * url: "https://www.example.com", + * source_id: 44, + * external_id: "abc1234" + * }) + */ + public createExternalPage( + request: Intercom.CreateExternalPageRequest, + requestOptions?: AiContentClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createExternalPage(request, requestOptions)); + } + + private async __createExternalPage( + request: Intercom.CreateExternalPageRequest, + requestOptions?: AiContentClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ai/external_pages", + ), + method: "POST", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: { ...request, locale: "en" }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.ExternalPage, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/ai/external_pages"); + } + + /** + * You can retrieve an external page. + * + * @param {Intercom.GetExternalPageRequest} request + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.aiContent.getExternalPage({ + * page_id: "page_id" + * }) + */ + public getExternalPage( + request: Intercom.GetExternalPageRequest, + requestOptions?: AiContentClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__getExternalPage(request, requestOptions)); + } + + private async __getExternalPage( + request: Intercom.GetExternalPageRequest, + requestOptions?: AiContentClient.RequestOptions, + ): Promise> { + const { page_id: pageId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ai/external_pages/${core.url.encodePathParam(pageId)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.ExternalPage, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/ai/external_pages/{page_id}"); + } + + /** + * You can update an existing external page (if it was created via the API). + * + * @param {Intercom.UpdateExternalPageRequest} request + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.aiContent.updateExternalPage({ + * page_id: "page_id", + * title: "Test", + * html: "

Test

", + * url: "https://www.example.com", + * source_id: 47, + * external_id: "5678" + * }) + */ + public updateExternalPage( + request: Intercom.UpdateExternalPageRequest, + requestOptions?: AiContentClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateExternalPage(request, requestOptions)); + } + + private async __updateExternalPage( + request: Intercom.UpdateExternalPageRequest, + requestOptions?: AiContentClient.RequestOptions, + ): Promise> { + const { page_id: pageId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ai/external_pages/${core.url.encodePathParam(pageId)}`, + ), + method: "PUT", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: { ..._body, locale: "en" }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.ExternalPage, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/ai/external_pages/{page_id}"); + } + + /** + * Sending a DELETE request for an external page will remove it from the content library UI and from being used for AI answers. + * + * @param {Intercom.DeleteExternalPageRequest} request + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.aiContent.deleteExternalPage({ + * page_id: "page_id" + * }) + */ + public deleteExternalPage( + request: Intercom.DeleteExternalPageRequest, + requestOptions?: AiContentClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteExternalPage(request, requestOptions)); + } + + private async __deleteExternalPage( + request: Intercom.DeleteExternalPageRequest, + requestOptions?: AiContentClient.RequestOptions, + ): Promise> { + const { page_id: pageId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `ai/external_pages/${core.url.encodePathParam(pageId)}`, + ), + method: "DELETE", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.ExternalPage, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/ai/external_pages/{page_id}", + ); + } +} diff --git a/src/api/resources/aiContent/client/index.ts b/src/api/resources/aiContent/client/index.ts new file mode 100644 index 00000000..195f9aa8 --- /dev/null +++ b/src/api/resources/aiContent/client/index.ts @@ -0,0 +1 @@ +export * from "./requests/index.js"; diff --git a/src/api/resources/aiContent/client/requests/CreateContentImportSourceRequest.ts b/src/api/resources/aiContent/client/requests/CreateContentImportSourceRequest.ts new file mode 100644 index 00000000..f487b162 --- /dev/null +++ b/src/api/resources/aiContent/client/requests/CreateContentImportSourceRequest.ts @@ -0,0 +1,23 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * url: "https://www.example.com" + * } + */ +export interface CreateContentImportSourceRequest { + /** The status of the content import source. */ + status?: CreateContentImportSourceRequest.Status; + /** The URL of the content import source. */ + url: string; +} + +export namespace CreateContentImportSourceRequest { + /** The status of the content import source. */ + export const Status = { + Active: "active", + Deactivated: "deactivated", + } as const; + export type Status = (typeof Status)[keyof typeof Status]; +} diff --git a/src/api/resources/aiContent/client/requests/CreateExternalPageRequest.ts b/src/api/resources/aiContent/client/requests/CreateExternalPageRequest.ts new file mode 100644 index 00000000..c4f5e914 --- /dev/null +++ b/src/api/resources/aiContent/client/requests/CreateExternalPageRequest.ts @@ -0,0 +1,28 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * title: "Test", + * html: "

Test

", + * url: "https://www.example.com", + * source_id: 44, + * external_id: "abc1234" + * } + */ +export interface CreateExternalPageRequest { + /** The title of the external page. */ + title: string; + /** The body of the external page in HTML. */ + html: string; + /** The URL of the external page. This will be used by Fin to link end users to the page it based its answer on. When a URL is not present, Fin will not reference the source. */ + url?: string; + /** Whether the external page should be used to answer questions by AI Agent. Will not default when updating an existing external page. */ + ai_agent_availability?: boolean; + /** Whether the external page should be used to answer questions by AI Copilot. Will not default when updating an existing external page. */ + ai_copilot_availability?: boolean; + /** The unique identifier for the source of the external page which was given by Intercom. Every external page must be associated with a Content Import Source which represents the place it comes from and from which it inherits a default audience (configured in the UI). For a new source, make a POST request to the Content Import Source endpoint and an ID for the source will be returned in the response. */ + source_id: number; + /** The identifier for the external page which was given by the source. Must be unique for the source. */ + external_id: string; +} diff --git a/src/api/resources/aiContent/client/requests/DeleteContentImportSourceRequest.ts b/src/api/resources/aiContent/client/requests/DeleteContentImportSourceRequest.ts new file mode 100644 index 00000000..4e3cd384 --- /dev/null +++ b/src/api/resources/aiContent/client/requests/DeleteContentImportSourceRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * source_id: "source_id" + * } + */ +export interface DeleteContentImportSourceRequest { + /** The unique identifier for the content import source which is given by Intercom. */ + source_id: string; +} diff --git a/src/api/resources/aiContent/client/requests/DeleteExternalPageRequest.ts b/src/api/resources/aiContent/client/requests/DeleteExternalPageRequest.ts new file mode 100644 index 00000000..600b878a --- /dev/null +++ b/src/api/resources/aiContent/client/requests/DeleteExternalPageRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * page_id: "page_id" + * } + */ +export interface DeleteExternalPageRequest { + /** The unique identifier for the external page which is given by Intercom. */ + page_id: string; +} diff --git a/src/api/resources/aiContent/client/requests/GetContentImportSourceRequest.ts b/src/api/resources/aiContent/client/requests/GetContentImportSourceRequest.ts new file mode 100644 index 00000000..9fc6e88a --- /dev/null +++ b/src/api/resources/aiContent/client/requests/GetContentImportSourceRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * source_id: "source_id" + * } + */ +export interface GetContentImportSourceRequest { + /** The unique identifier for the content import source which is given by Intercom. */ + source_id: string; +} diff --git a/src/api/resources/aiContent/client/requests/GetExternalPageRequest.ts b/src/api/resources/aiContent/client/requests/GetExternalPageRequest.ts new file mode 100644 index 00000000..3255d445 --- /dev/null +++ b/src/api/resources/aiContent/client/requests/GetExternalPageRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * page_id: "page_id" + * } + */ +export interface GetExternalPageRequest { + /** The unique identifier for the external page which is given by Intercom. */ + page_id: string; +} diff --git a/src/api/resources/aiContent/client/requests/UpdateContentImportSourceRequest.ts b/src/api/resources/aiContent/client/requests/UpdateContentImportSourceRequest.ts new file mode 100644 index 00000000..4debce37 --- /dev/null +++ b/src/api/resources/aiContent/client/requests/UpdateContentImportSourceRequest.ts @@ -0,0 +1,36 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * source_id: "source_id", + * sync_behavior: "api", + * url: "https://www.example.com" + * } + */ +export interface UpdateContentImportSourceRequest { + /** The unique identifier for the content import source which is given by Intercom. */ + source_id: string; + /** If you intend to create or update External Pages via the API, this should be set to `api`. You can not change the value to or from api. */ + sync_behavior: UpdateContentImportSourceRequest.SyncBehavior; + /** The status of the content import source. */ + status?: UpdateContentImportSourceRequest.Status; + /** The URL of the content import source. This may only be different from the existing value if the sync behavior is API. */ + url: string; +} + +export namespace UpdateContentImportSourceRequest { + /** If you intend to create or update External Pages via the API, this should be set to `api`. You can not change the value to or from api. */ + export const SyncBehavior = { + Api: "api", + Automated: "automated", + Manual: "manual", + } as const; + export type SyncBehavior = (typeof SyncBehavior)[keyof typeof SyncBehavior]; + /** The status of the content import source. */ + export const Status = { + Active: "active", + Deactivated: "deactivated", + } as const; + export type Status = (typeof Status)[keyof typeof Status]; +} diff --git a/src/api/resources/aiContent/client/requests/UpdateExternalPageRequest.ts b/src/api/resources/aiContent/client/requests/UpdateExternalPageRequest.ts new file mode 100644 index 00000000..75d703c3 --- /dev/null +++ b/src/api/resources/aiContent/client/requests/UpdateExternalPageRequest.ts @@ -0,0 +1,29 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * page_id: "page_id", + * title: "Test", + * html: "

Test

", + * url: "https://www.example.com", + * source_id: 47, + * external_id: "5678" + * } + */ +export interface UpdateExternalPageRequest { + /** The unique identifier for the external page which is given by Intercom. */ + page_id: string; + /** The title of the external page. */ + title: string; + /** The body of the external page in HTML. */ + html: string; + /** The URL of the external page. This will be used by Fin to link end users to the page it based its answer on. */ + url: string; + /** Whether the external page should be used to answer questions by Fin. */ + fin_availability?: boolean; + /** The unique identifier for the source of the external page which was given by Intercom. Every external page must be associated with a Content Import Source which represents the place it comes from and from which it inherits a default audience (configured in the UI). For a new source, make a POST request to the Content Import Source endpoint and an ID for the source will be returned in the response. */ + source_id: number; + /** The identifier for the external page which was given by the source. Must be unique for the source. */ + external_id?: string; +} diff --git a/src/api/resources/aiContent/client/requests/index.ts b/src/api/resources/aiContent/client/requests/index.ts new file mode 100644 index 00000000..2c010829 --- /dev/null +++ b/src/api/resources/aiContent/client/requests/index.ts @@ -0,0 +1,8 @@ +export type { CreateContentImportSourceRequest } from "./CreateContentImportSourceRequest.js"; +export type { CreateExternalPageRequest } from "./CreateExternalPageRequest.js"; +export type { DeleteContentImportSourceRequest } from "./DeleteContentImportSourceRequest.js"; +export type { DeleteExternalPageRequest } from "./DeleteExternalPageRequest.js"; +export type { GetContentImportSourceRequest } from "./GetContentImportSourceRequest.js"; +export type { GetExternalPageRequest } from "./GetExternalPageRequest.js"; +export type { UpdateContentImportSourceRequest } from "./UpdateContentImportSourceRequest.js"; +export type { UpdateExternalPageRequest } from "./UpdateExternalPageRequest.js"; diff --git a/src/api/resources/aiContent/index.ts b/src/api/resources/aiContent/index.ts new file mode 100644 index 00000000..d9adb1af --- /dev/null +++ b/src/api/resources/aiContent/index.ts @@ -0,0 +1,2 @@ +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/aiContent/types/ContentImportSource.ts b/src/api/resources/aiContent/types/ContentImportSource.ts new file mode 100644 index 00000000..e65d8d1a --- /dev/null +++ b/src/api/resources/aiContent/types/ContentImportSource.ts @@ -0,0 +1,39 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * An external source for External Pages that you add to your Fin Content Library. + */ +export interface ContentImportSource { + /** Always external_page */ + type: "content_import_source"; + /** The unique identifier for the content import source which is given by Intercom. */ + id: number; + /** The time when the content import source was last synced. */ + last_synced_at: number; + /** If you intend to create or update External Pages via the API, this should be set to `api`. */ + sync_behavior: ContentImportSource.SyncBehavior; + /** The status of the content import source. */ + status: ContentImportSource.Status; + /** The URL of the root of the external source. */ + url: string; + /** The time when the content import source was created. */ + created_at: number; + /** The time when the content import source was last updated. */ + updated_at: number; +} + +export namespace ContentImportSource { + /** If you intend to create or update External Pages via the API, this should be set to `api`. */ + export const SyncBehavior = { + Api: "api", + Automatic: "automatic", + Manual: "manual", + } as const; + export type SyncBehavior = (typeof SyncBehavior)[keyof typeof SyncBehavior]; + /** The status of the content import source. */ + export const Status = { + Active: "active", + Deactivated: "deactivated", + } as const; + export type Status = (typeof Status)[keyof typeof Status]; +} diff --git a/src/api/resources/aiContent/types/ContentImportSourcesList.ts b/src/api/resources/aiContent/types/ContentImportSourcesList.ts new file mode 100644 index 00000000..8e7018fe --- /dev/null +++ b/src/api/resources/aiContent/types/ContentImportSourcesList.ts @@ -0,0 +1,16 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +/** + * This will return a list of the content import sources for the App. + */ +export interface ContentImportSourcesList { + /** The type of the object - `list`. */ + type?: "list"; + pages?: Intercom.PagesLink; + /** A count of the total number of content import sources. */ + total_count?: number; + /** An array of Content Import Source objects */ + data?: Intercom.ContentImportSource[]; +} diff --git a/src/api/resources/aiContent/types/ExternalPage.ts b/src/api/resources/aiContent/types/ExternalPage.ts new file mode 100644 index 00000000..97afb31c --- /dev/null +++ b/src/api/resources/aiContent/types/ExternalPage.ts @@ -0,0 +1,35 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * External pages that you have added to your Fin Content Library. + */ +export interface ExternalPage { + /** Always external_page */ + type: "external_page"; + /** The unique identifier for the external page which is given by Intercom. */ + id: string; + /** The title of the external page. */ + title: string; + /** The body of the external page in HTML. */ + html: string; + /** The URL of the external page. This will be used by Fin to link end users to the page it based its answer on. */ + url?: string; + /** Whether the external page should be used to answer questions by AI Agent. */ + ai_agent_availability: boolean; + /** Whether the external page should be used to answer questions by AI Copilot. */ + ai_copilot_availability: boolean; + /** Deprecated. Use ai_agent_availability and ai_copilot_availability instead. */ + fin_availability?: boolean; + /** Always en */ + locale: "en"; + /** The unique identifier for the source of the external page which was given by Intercom. Every external page must be associated with a Content Import Source which represents the place it comes from and from which it inherits a default audience (configured in the UI). For a new source, make a POST request to the Content Import Source endpoint and an ID for the source will be returned in the response. */ + source_id: number; + /** The identifier for the external page which was given by the source. Must be unique for the source. */ + external_id: string; + /** The time when the external page was created. */ + created_at: number; + /** The time when the external page was last updated. */ + updated_at: number; + /** The time when the external page was last ingested. */ + last_ingested_at: number; +} diff --git a/src/api/resources/aiContent/types/ExternalPagesList.ts b/src/api/resources/aiContent/types/ExternalPagesList.ts new file mode 100644 index 00000000..ec5273ca --- /dev/null +++ b/src/api/resources/aiContent/types/ExternalPagesList.ts @@ -0,0 +1,16 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +/** + * This will return a list of external pages for the App. + */ +export interface ExternalPagesList { + /** The type of the object - `list`. */ + type?: "list"; + pages?: Intercom.PagesLink; + /** A count of the total number of external pages. */ + total_count?: number; + /** An array of External Page objects */ + data?: Intercom.ExternalPage[]; +} diff --git a/src/api/resources/aiContent/types/index.ts b/src/api/resources/aiContent/types/index.ts new file mode 100644 index 00000000..4a084844 --- /dev/null +++ b/src/api/resources/aiContent/types/index.ts @@ -0,0 +1,4 @@ +export * from "./ContentImportSource.js"; +export * from "./ContentImportSourcesList.js"; +export * from "./ExternalPage.js"; +export * from "./ExternalPagesList.js"; diff --git a/src/api/resources/aiContentSource/index.ts b/src/api/resources/aiContentSource/index.ts index eea524d6..2f88e301 100644 --- a/src/api/resources/aiContentSource/index.ts +++ b/src/api/resources/aiContentSource/index.ts @@ -1 +1 @@ -export * from "./types"; +export * from "./types/index.js"; diff --git a/src/api/resources/aiContentSource/types/ContentSource.ts b/src/api/resources/aiContentSource/types/ContentSource.ts index 15fd382f..7013e220 100644 --- a/src/api/resources/aiContentSource/types/ContentSource.ts +++ b/src/api/resources/aiContentSource/types/ContentSource.ts @@ -1,17 +1,15 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The content source used by AI Agent in the conversation. */ export interface ContentSource { /** The type of the content source. */ - content_type: "custom_answer"; + content_type?: "custom_answer"; /** The internal URL linking to the content source for teammates. */ - url: string; + url?: string; /** The title of the content source. */ - title: string; + title?: string; /** The ISO 639 language code of the content source. */ - locale: string; + locale?: string; } diff --git a/src/api/resources/aiContentSource/types/index.ts b/src/api/resources/aiContentSource/types/index.ts index 68047f7e..190780ca 100644 --- a/src/api/resources/aiContentSource/types/index.ts +++ b/src/api/resources/aiContentSource/types/index.ts @@ -1 +1 @@ -export * from "./ContentSource"; +export * from "./ContentSource.js"; diff --git a/src/api/resources/articles/client/Client.ts b/src/api/resources/articles/client/Client.ts index 78948f01..e101ba3d 100644 --- a/src/api/resources/articles/client/Client.ts +++ b/src/api/resources/articles/client/Client.ts @@ -1,79 +1,29 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace Articles { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace ArticlesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Articles */ -export class Articles { - constructor(protected readonly _options: Articles.Options = {}) {} +export class ArticlesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: ArticlesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of all articles by making a GET request to `https://api.intercom.io/articles`. @@ -83,7 +33,7 @@ export class Articles { * > Articles will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated articles first. * * @param {Intercom.ListArticlesRequest} request - * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * @param {ArticlesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -92,44 +42,40 @@ export class Articles { */ public async list( request: Intercom.ListArticlesRequest = {}, - requestOptions?: Articles.RequestOptions, - ): Promise> { + requestOptions?: ArticlesClient.RequestOptions, + ): Promise> { const list = core.HttpResponsePromise.interceptFunction( async (request: Intercom.ListArticlesRequest): Promise> => { const { page, per_page: perPage } = request; const _queryParams: Record = {}; if (page != null) { - _queryParams["page"] = page.toString(); + _queryParams.page = page.toString(); } if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); + _queryParams.per_page = perPage.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "articles", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: - requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.ArticleList, rawResponse: _response.rawResponse }; @@ -149,26 +95,12 @@ export class Articles { }); } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/articles"); }, ); let _offset = request?.page != null ? request?.page : 1; const dataWithRawResponse = await list(request).withRawResponse(); - return new core.Pageable({ + return new core.Page({ response: dataWithRawResponse.data, rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => (response?.data ?? []).length > 0, @@ -184,7 +116,7 @@ export class Articles { * You can create a new article by making a POST request to `https://api.intercom.io/articles`. * * @param {Intercom.CreateArticleRequest} request - * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * @param {ArticlesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.BadRequestError} * @throws {@link Intercom.UnauthorizedError} @@ -194,17 +126,16 @@ export class Articles { * title: "Thanks for everything", * description: "Description of the Article", * body: "Body of the Article", - * author_id: 991267407, + * author_id: 991267497, * state: "published", * parent_id: 145, * parent_type: "collection", * translated_content: { * fr: { - * type: "article_content", * title: "Merci pour tout", * description: "Description de l'article", * body: "Corps de l'article", - * author_id: 991267407, + * author_id: 991267497, * state: "published" * } * } @@ -220,41 +151,41 @@ export class Articles { * }) */ public create( - request: Intercom.CreateArticleRequest, - requestOptions?: Articles.RequestOptions, + request?: Intercom.CreateArticleRequest, + requestOptions?: ArticlesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( - request: Intercom.CreateArticleRequest, - requestOptions?: Articles.RequestOptions, + request?: Intercom.CreateArticleRequest, + requestOptions?: ArticlesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "articles", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", - body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + body: request != null ? request : undefined, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Article, rawResponse: _response.rawResponse }; @@ -278,73 +209,57 @@ export class Articles { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /articles."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/articles"); } /** * You can fetch the details of a single article by making a GET request to `https://api.intercom.io/articles/`. * * @param {Intercom.FindArticleRequest} request - * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * @param {ArticlesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.articles.find({ - * article_id: "123" + * article_id: 1 * }) */ public find( request: Intercom.FindArticleRequest, - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.FindArticleRequest, - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): Promise> { const { article_id: articleId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `articles/${encodeURIComponent(articleId)}`, + `articles/${core.url.encodePathParam(articleId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Article, rawResponse: _response.rawResponse }; @@ -368,76 +283,62 @@ export class Articles { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles/{article_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/articles/{article_id}"); } /** * You can update the details of a single article by making a PUT request to `https://api.intercom.io/articles/`. * * @param {Intercom.UpdateArticleRequest} request - * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * @param {ArticlesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.articles.update({ - * article_id: "123", + * article_id: 1, * title: "Christmas is here!", * body: "

New gifts in store for the jolly season

" * }) */ public update( request: Intercom.UpdateArticleRequest, - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); } private async __update( request: Intercom.UpdateArticleRequest, - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): Promise> { const { article_id: articleId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `articles/${encodeURIComponent(articleId)}`, + `articles/${core.url.encodePathParam(articleId)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Article, rawResponse: _response.rawResponse }; @@ -461,73 +362,57 @@ export class Articles { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /articles/{article_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/articles/{article_id}"); } /** * You can delete a single article by making a DELETE request to `https://api.intercom.io/articles/`. * * @param {Intercom.DeleteArticleRequest} request - * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * @param {ArticlesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.articles.delete({ - * article_id: "123" + * article_id: 1 * }) */ public delete( request: Intercom.DeleteArticleRequest, - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__delete(request, requestOptions)); } private async __delete( request: Intercom.DeleteArticleRequest, - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): Promise> { const { article_id: articleId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `articles/${encodeURIComponent(articleId)}`, + `articles/${core.url.encodePathParam(articleId)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.DeletedArticleObject, rawResponse: _response.rawResponse }; @@ -551,94 +436,79 @@ export class Articles { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /articles/{article_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/articles/{article_id}"); } /** * You can search for articles by making a GET request to `https://api.intercom.io/articles/search`. * * @param {Intercom.SearchArticlesRequest} request - * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * @param {ArticlesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * * @example * await client.articles.search({ * phrase: "Getting started", - * state: "published" + * state: "published", + * help_center_id: 1, + * highlight: true * }) */ public search( request: Intercom.SearchArticlesRequest = {}, - requestOptions?: Articles.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: ArticlesClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__search(request, requestOptions)); } private async __search( request: Intercom.SearchArticlesRequest = {}, - requestOptions?: Articles.RequestOptions, - ): Promise> { + requestOptions?: ArticlesClient.RequestOptions, + ): Promise> { const { phrase, state, help_center_id: helpCenterId, highlight } = request; const _queryParams: Record = {}; if (phrase != null) { - _queryParams["phrase"] = phrase; + _queryParams.phrase = phrase; } if (state != null) { - _queryParams["state"] = state; + _queryParams.state = state; } if (helpCenterId != null) { - _queryParams["help_center_id"] = helpCenterId.toString(); + _queryParams.help_center_id = helpCenterId.toString(); } if (highlight != null) { - _queryParams["highlight"] = highlight.toString(); + _queryParams.highlight = highlight.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "articles/search", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.SearchArticlesResponse, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.ArticleSearchResponse, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -657,32 +527,6 @@ export class Articles { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles/search."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/articles/search"); } } diff --git a/src/api/resources/articles/client/index.ts b/src/api/resources/articles/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/articles/client/index.ts +++ b/src/api/resources/articles/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/articles/client/requests/DeleteArticleRequest.ts b/src/api/resources/articles/client/requests/DeleteArticleRequest.ts index cfc44703..43cfd9e2 100644 --- a/src/api/resources/articles/client/requests/DeleteArticleRequest.ts +++ b/src/api/resources/articles/client/requests/DeleteArticleRequest.ts @@ -1,16 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * article_id: "123" + * article_id: 1 * } */ export interface DeleteArticleRequest { - /** - * The unique identifier for the article which is given by Intercom. - */ - article_id: string; + /** The unique identifier for the article which is given by Intercom. */ + article_id: number; } diff --git a/src/api/resources/articles/client/requests/FindArticleRequest.ts b/src/api/resources/articles/client/requests/FindArticleRequest.ts index 29e6bc18..b333b0d8 100644 --- a/src/api/resources/articles/client/requests/FindArticleRequest.ts +++ b/src/api/resources/articles/client/requests/FindArticleRequest.ts @@ -1,16 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * article_id: "123" + * article_id: 1 * } */ export interface FindArticleRequest { - /** - * The unique identifier for the article which is given by Intercom. - */ - article_id: string; + /** The unique identifier for the article which is given by Intercom. */ + article_id: number; } diff --git a/src/api/resources/articles/client/requests/ListArticlesRequest.ts b/src/api/resources/articles/client/requests/ListArticlesRequest.ts index 03a1e4d4..598bdacf 100644 --- a/src/api/resources/articles/client/requests/ListArticlesRequest.ts +++ b/src/api/resources/articles/client/requests/ListArticlesRequest.ts @@ -1,18 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * {} */ export interface ListArticlesRequest { - /** - * The page of results to fetch. Defaults to first page - */ + /** The page of results to fetch. Defaults to first page */ page?: number; - /** - * How many results to display per page. Defaults to 15 - */ + /** How many results to display per page. Defaults to 15 */ per_page?: number; } diff --git a/src/api/resources/articles/client/requests/SearchArticlesRequest.ts b/src/api/resources/articles/client/requests/SearchArticlesRequest.ts index 7c07777d..3416dd98 100644 --- a/src/api/resources/articles/client/requests/SearchArticlesRequest.ts +++ b/src/api/resources/articles/client/requests/SearchArticlesRequest.ts @@ -1,29 +1,21 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { * phrase: "Getting started", - * state: "published" + * state: "published", + * help_center_id: 1, + * highlight: true * } */ export interface SearchArticlesRequest { - /** - * The phrase within your articles to search for. - */ + /** The phrase within your articles to search for. */ phrase?: string; - /** - * The state of the Articles returned. One of `published`, `draft` or `all`. - */ + /** The state of the Articles returned. One of `published`, `draft` or `all`. */ state?: string; - /** - * The ID of the Help Center to search in. - */ + /** The ID of the Help Center to search in. */ help_center_id?: number; - /** - * Return a highlighted version of the matching content within your articles. Refer to the response schema for more details. - */ + /** Return a highlighted version of the matching content within your articles. Refer to the response schema for more details. */ highlight?: boolean; } diff --git a/src/api/resources/articles/client/requests/UpdateArticleRequest.ts b/src/api/resources/articles/client/requests/UpdateArticleRequest.ts index cb814947..36209811 100644 --- a/src/api/resources/articles/client/requests/UpdateArticleRequest.ts +++ b/src/api/resources/articles/client/requests/UpdateArticleRequest.ts @@ -1,29 +1,25 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../index"; +import type * as Intercom from "../../../../index.js"; /** * @example * { - * article_id: "123", + * article_id: 1, * title: "Christmas is here!", * body: "

New gifts in store for the jolly season

" * } * * @example * { - * article_id: "123", + * article_id: 1, * title: "Christmas is here!", * body: "

New gifts in store for the jolly season

" * } */ export interface UpdateArticleRequest { - /** - * The unique identifier for the article which is given by Intercom. - */ - article_id: string; + /** The unique identifier for the article which is given by Intercom. */ + article_id: number; /** The title of the article.For multilingual articles, this will be the title of the default language's content. */ title?: string; /** The description of the article. For multilingual articles, this will be the description of the default language's content. */ @@ -37,25 +33,15 @@ export interface UpdateArticleRequest { /** The id of the article's parent collection or section. An article without this field stands alone. */ parent_id?: string; /** The type of parent, which can either be a `collection` or `section`. */ - parent_type?: UpdateArticleRequest.ParentType; + parent_type?: string; translated_content?: Intercom.ArticleTranslatedContent; } export namespace UpdateArticleRequest { - /** - * Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. - */ - export type State = "published" | "draft"; + /** Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. */ export const State = { Published: "published", Draft: "draft", } as const; - /** - * The type of parent, which can either be a `collection` or `section`. - */ - export type ParentType = "collection" | "section"; - export const ParentType = { - Collection: "collection", - Section: "section", - } as const; + export type State = (typeof State)[keyof typeof State]; } diff --git a/src/api/resources/articles/client/requests/index.ts b/src/api/resources/articles/client/requests/index.ts index 48ca8171..9376442d 100644 --- a/src/api/resources/articles/client/requests/index.ts +++ b/src/api/resources/articles/client/requests/index.ts @@ -1,6 +1,5 @@ -export { type ListArticlesRequest } from "./ListArticlesRequest"; -export { type CreateArticleRequest } from "./CreateArticleRequest"; -export { type FindArticleRequest } from "./FindArticleRequest"; -export { type UpdateArticleRequest } from "./UpdateArticleRequest"; -export { type DeleteArticleRequest } from "./DeleteArticleRequest"; -export { type SearchArticlesRequest } from "./SearchArticlesRequest"; +export type { DeleteArticleRequest } from "./DeleteArticleRequest.js"; +export type { FindArticleRequest } from "./FindArticleRequest.js"; +export type { ListArticlesRequest } from "./ListArticlesRequest.js"; +export type { SearchArticlesRequest } from "./SearchArticlesRequest.js"; +export type { UpdateArticleRequest } from "./UpdateArticleRequest.js"; diff --git a/src/api/resources/articles/index.ts b/src/api/resources/articles/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/articles/index.ts +++ b/src/api/resources/articles/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/articles/types/Article.ts b/src/api/resources/articles/types/Article.ts index 4328ff6c..02667c69 100644 --- a/src/api/resources/articles/types/Article.ts +++ b/src/api/resources/articles/types/Article.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * The Articles API is a central place to gather all information and take actions on your articles. Articles can live within collections and sections, or alternatively they can stand alone. diff --git a/src/api/resources/articles/types/ArticleListItem.ts b/src/api/resources/articles/types/ArticleListItem.ts index 1c180206..426c862a 100644 --- a/src/api/resources/articles/types/ArticleListItem.ts +++ b/src/api/resources/articles/types/ArticleListItem.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * The data returned about your articles when you list them. @@ -37,17 +35,15 @@ export interface ArticleListItem { /** The type of parent, which can either be a `collection` or `section`. */ parent_type?: string; /** The default locale of the help center. This field is only returned for multilingual help centers. */ - default_locale: string; - translated_content: Intercom.ArticleTranslatedContent; + default_locale?: string; + translated_content?: Intercom.ArticleTranslatedContent; } export namespace ArticleListItem { - /** - * Whether the article is `published` or is a `draft`. For multilingual articles, this will be the state of the default language's content. - */ - export type State = "published" | "draft"; + /** Whether the article is `published` or is a `draft`. For multilingual articles, this will be the state of the default language's content. */ export const State = { Published: "published", Draft: "draft", } as const; + export type State = (typeof State)[keyof typeof State]; } diff --git a/src/api/resources/articles/types/ArticleSearchHighlights.ts b/src/api/resources/articles/types/ArticleSearchHighlights.ts index 0dd36d50..c80f22fa 100644 --- a/src/api/resources/articles/types/ArticleSearchHighlights.ts +++ b/src/api/resources/articles/types/ArticleSearchHighlights.ts @@ -1,17 +1,15 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The highlighted results of an Article search. In the examples provided my search query is always "my query". */ export interface ArticleSearchHighlights { /** The ID of the corresponding article. */ - article_id: string; + article_id?: string; /** An Article title highlighted. */ - highlighted_title: ArticleSearchHighlights.HighlightedTitle.Item[]; + highlighted_title?: ArticleSearchHighlights.HighlightedTitle.Item[]; /** An Article description and body text highlighted. */ - highlighted_summary: ArticleSearchHighlights.HighlightedSummary.Item[][]; + highlighted_summary?: ArticleSearchHighlights.HighlightedSummary.Item[][]; } export namespace ArticleSearchHighlights { @@ -29,14 +27,12 @@ export namespace ArticleSearchHighlights { } export namespace Item { - /** - * The type of text - `highlight` or `plain`. - */ - export type Type = "highlight" | "plain"; + /** The type of text - `highlight` or `plain`. */ export const Type = { Highlight: "highlight", Plain: "plain", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } } @@ -54,14 +50,12 @@ export namespace ArticleSearchHighlights { } export namespace Item { - /** - * The type of text - `highlight` or `plain`. - */ - export type Type = "highlight" | "plain"; + /** The type of text - `highlight` or `plain`. */ export const Type = { Highlight: "highlight", Plain: "plain", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } } } diff --git a/src/api/resources/articles/types/SearchArticlesResponse.ts b/src/api/resources/articles/types/ArticleSearchResponse.ts similarity index 66% rename from src/api/resources/articles/types/SearchArticlesResponse.ts rename to src/api/resources/articles/types/ArticleSearchResponse.ts index dbf3330a..349062a8 100644 --- a/src/api/resources/articles/types/SearchArticlesResponse.ts +++ b/src/api/resources/articles/types/ArticleSearchResponse.ts @@ -1,23 +1,21 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * The results of an Article search */ -export interface SearchArticlesResponse { +export interface ArticleSearchResponse { /** The type of the object - `list`. */ - type: "list"; + type?: "list"; /** The total number of Articles matching the search query */ - total_count: number; + total_count?: number; /** An object containing the results of the search. */ - data: SearchArticlesResponse.Data; + data?: ArticleSearchResponse.Data; pages?: Intercom.CursorPages; } -export namespace SearchArticlesResponse { +export namespace ArticleSearchResponse { /** * An object containing the results of the search. */ diff --git a/src/api/resources/articles/types/InternalArticle.ts b/src/api/resources/articles/types/InternalArticle.ts new file mode 100644 index 00000000..dec37b5f --- /dev/null +++ b/src/api/resources/articles/types/InternalArticle.ts @@ -0,0 +1,8 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +/** + * The Internal Articles API is a central place to gather all information and take actions on your internal articles. + */ +export type InternalArticle = Intercom.InternalArticleListItem; diff --git a/src/api/resources/articles/types/index.ts b/src/api/resources/articles/types/index.ts index a9b4ea42..ac1a15f9 100644 --- a/src/api/resources/articles/types/index.ts +++ b/src/api/resources/articles/types/index.ts @@ -1,4 +1,5 @@ -export * from "./Article"; -export * from "./ArticleListItem"; -export * from "./ArticleSearchHighlights"; -export * from "./SearchArticlesResponse"; +export * from "./Article.js"; +export * from "./ArticleListItem.js"; +export * from "./ArticleSearchHighlights.js"; +export * from "./ArticleSearchResponse.js"; +export * from "./InternalArticle.js"; diff --git a/src/api/resources/awayStatusReasons/client/Client.ts b/src/api/resources/awayStatusReasons/client/Client.ts new file mode 100644 index 00000000..22df5064 --- /dev/null +++ b/src/api/resources/awayStatusReasons/client/Client.ts @@ -0,0 +1,92 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; + +export declare namespace AwayStatusReasonsClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * Everything about your Away Status Reasons + */ +export class AwayStatusReasonsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: AwayStatusReasonsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * Returns a list of all away status reasons configured for the workspace, including deleted ones. + * + * @param {AwayStatusReasonsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.awayStatusReasons.listAwayStatusReasons() + */ + public listAwayStatusReasons( + requestOptions?: AwayStatusReasonsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAwayStatusReasons(requestOptions)); + } + + private async __listAwayStatusReasons( + requestOptions?: AwayStatusReasonsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "away_status_reasons", + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.AwayStatusReason[], rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/away_status_reasons"); + } +} diff --git a/src/api/resources/awayStatusReasons/client/index.ts b/src/api/resources/awayStatusReasons/client/index.ts new file mode 100644 index 00000000..cb0ff5c3 --- /dev/null +++ b/src/api/resources/awayStatusReasons/client/index.ts @@ -0,0 +1 @@ +export {}; diff --git a/src/api/resources/awayStatusReasons/index.ts b/src/api/resources/awayStatusReasons/index.ts new file mode 100644 index 00000000..914b8c3c --- /dev/null +++ b/src/api/resources/awayStatusReasons/index.ts @@ -0,0 +1 @@ +export * from "./client/index.js"; diff --git a/src/api/resources/calls/client/Client.ts b/src/api/resources/calls/client/Client.ts new file mode 100644 index 00000000..956fcfa5 --- /dev/null +++ b/src/api/resources/calls/client/Client.ts @@ -0,0 +1,405 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; + +export declare namespace CallsClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * Everything about your Calls + */ +export class CallsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: CallsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * Retrieve a paginated list of calls. + * + * @param {Intercom.ListCallsRequest} request + * @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.calls.listCalls({ + * page: 1, + * per_page: 1 + * }) + */ + public listCalls( + request: Intercom.ListCallsRequest = {}, + requestOptions?: CallsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listCalls(request, requestOptions)); + } + + private async __listCalls( + request: Intercom.ListCallsRequest = {}, + requestOptions?: CallsClient.RequestOptions, + ): Promise> { + const { page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams.page = page.toString(); + } + + if (perPage != null) { + _queryParams.per_page = perPage.toString(); + } + + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "calls", + ), + method: "GET", + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.CallList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/calls"); + } + + /** + * Retrieve a single call by id. + * + * @param {Intercom.ShowCallRequest} request + * @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.calls.showCall({ + * call_id: "call_id" + * }) + */ + public showCall( + request: Intercom.ShowCallRequest, + requestOptions?: CallsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__showCall(request, requestOptions)); + } + + private async __showCall( + request: Intercom.ShowCallRequest, + requestOptions?: CallsClient.RequestOptions, + ): Promise> { + const { call_id: callId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `calls/${core.url.encodePathParam(callId)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.Call, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/calls/{call_id}"); + } + + /** + * Redirects to a signed URL for the call's recording if it exists. + * + * @param {Intercom.ShowCallRecordingRequest} request + * @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.calls.showCallRecording({ + * call_id: "call_id" + * }) + */ + public showCallRecording( + request: Intercom.ShowCallRecordingRequest, + requestOptions?: CallsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__showCallRecording(request, requestOptions)); + } + + private async __showCallRecording( + request: Intercom.ShowCallRecordingRequest, + requestOptions?: CallsClient.RequestOptions, + ): Promise> { + const { call_id: callId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `calls/${core.url.encodePathParam(callId)}/recording`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: undefined, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/calls/{call_id}/recording"); + } + + /** + * Returns the transcript for the specified call as a downloadable text file. + * + * @param {Intercom.ShowCallTranscriptRequest} request + * @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.calls.showCallTranscript({ + * call_id: "call_id" + * }) + */ + public showCallTranscript( + request: Intercom.ShowCallTranscriptRequest, + requestOptions?: CallsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__showCallTranscript(request, requestOptions)); + } + + private async __showCallTranscript( + request: Intercom.ShowCallTranscriptRequest, + requestOptions?: CallsClient.RequestOptions, + ): Promise> { + const { call_id: callId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `calls/${core.url.encodePathParam(callId)}/transcript`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + responseType: "text", + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as string, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/calls/{call_id}/transcript"); + } + + /** + * Retrieve calls by a list of conversation ids and include transcripts when available. + * A maximum of 20 `conversation_ids` can be provided. If none are provided or more than 20 are provided, a 400 error is returned. + * + * @param {Intercom.ListCallsWithTranscriptsRequest} request + * @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.calls.listCallsWithTranscripts({ + * conversation_ids: ["64619700005694", "64619700005695"] + * }) + */ + public listCallsWithTranscripts( + request: Intercom.ListCallsWithTranscriptsRequest, + requestOptions?: CallsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listCallsWithTranscripts(request, requestOptions)); + } + + private async __listCallsWithTranscripts( + request: Intercom.ListCallsWithTranscriptsRequest, + requestOptions?: CallsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "calls/search", + ), + method: "POST", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: request, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.ListCallsWithTranscriptsResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/calls/search"); + } +} diff --git a/src/api/resources/calls/client/index.ts b/src/api/resources/calls/client/index.ts new file mode 100644 index 00000000..195f9aa8 --- /dev/null +++ b/src/api/resources/calls/client/index.ts @@ -0,0 +1 @@ +export * from "./requests/index.js"; diff --git a/src/api/resources/calls/client/requests/ListCallsRequest.ts b/src/api/resources/calls/client/requests/ListCallsRequest.ts new file mode 100644 index 00000000..74c29012 --- /dev/null +++ b/src/api/resources/calls/client/requests/ListCallsRequest.ts @@ -0,0 +1,15 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * page: 1, + * per_page: 1 + * } + */ +export interface ListCallsRequest { + /** The page of results to fetch. Defaults to first page */ + page?: number; + /** How many results to display per page. Defaults to 25. Max 25. */ + per_page?: number; +} diff --git a/src/api/resources/calls/client/requests/ListCallsWithTranscriptsRequest.ts b/src/api/resources/calls/client/requests/ListCallsWithTranscriptsRequest.ts new file mode 100644 index 00000000..92d644c1 --- /dev/null +++ b/src/api/resources/calls/client/requests/ListCallsWithTranscriptsRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * conversation_ids: ["64619700005694", "64619700005695"] + * } + */ +export interface ListCallsWithTranscriptsRequest { + /** A list of conversation ids to fetch calls for. Maximum 20. */ + conversation_ids: string[]; +} diff --git a/src/api/resources/calls/client/requests/ShowCallRecordingRequest.ts b/src/api/resources/calls/client/requests/ShowCallRecordingRequest.ts new file mode 100644 index 00000000..7b9543df --- /dev/null +++ b/src/api/resources/calls/client/requests/ShowCallRecordingRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * call_id: "call_id" + * } + */ +export interface ShowCallRecordingRequest { + /** The id of the call */ + call_id: string; +} diff --git a/src/api/resources/calls/client/requests/ShowCallRequest.ts b/src/api/resources/calls/client/requests/ShowCallRequest.ts new file mode 100644 index 00000000..52c4cd8c --- /dev/null +++ b/src/api/resources/calls/client/requests/ShowCallRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * call_id: "call_id" + * } + */ +export interface ShowCallRequest { + /** The id of the call to retrieve */ + call_id: string; +} diff --git a/src/api/resources/calls/client/requests/ShowCallTranscriptRequest.ts b/src/api/resources/calls/client/requests/ShowCallTranscriptRequest.ts new file mode 100644 index 00000000..9c2bbe4e --- /dev/null +++ b/src/api/resources/calls/client/requests/ShowCallTranscriptRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * call_id: "call_id" + * } + */ +export interface ShowCallTranscriptRequest { + /** The id of the call */ + call_id: string; +} diff --git a/src/api/resources/calls/client/requests/index.ts b/src/api/resources/calls/client/requests/index.ts new file mode 100644 index 00000000..08b2eb9c --- /dev/null +++ b/src/api/resources/calls/client/requests/index.ts @@ -0,0 +1,5 @@ +export type { ListCallsRequest } from "./ListCallsRequest.js"; +export type { ListCallsWithTranscriptsRequest } from "./ListCallsWithTranscriptsRequest.js"; +export type { ShowCallRecordingRequest } from "./ShowCallRecordingRequest.js"; +export type { ShowCallRequest } from "./ShowCallRequest.js"; +export type { ShowCallTranscriptRequest } from "./ShowCallTranscriptRequest.js"; diff --git a/src/api/resources/calls/index.ts b/src/api/resources/calls/index.ts new file mode 100644 index 00000000..d9adb1af --- /dev/null +++ b/src/api/resources/calls/index.ts @@ -0,0 +1,2 @@ +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/calls/types/Call.ts b/src/api/resources/calls/types/Call.ts new file mode 100644 index 00000000..33b20803 --- /dev/null +++ b/src/api/resources/calls/types/Call.ts @@ -0,0 +1,42 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +/** + * Represents a phone call in Intercom + */ +export interface Call { + /** String representing the object's type. Always has the value `call`. */ + type?: string; + /** The id of the call. */ + id?: string; + /** The id of the conversation associated with the call, if any. */ + conversation_id?: string; + /** The id of the admin associated with the call, if any. */ + admin_id?: string; + /** The id of the contact associated with the call, if any. */ + contact_id?: string; + /** The current state of the call. */ + state?: string; + initiated_at?: Intercom.Datetime; + answered_at?: Intercom.Datetime; + ended_at?: Intercom.Datetime; + created_at?: Intercom.Datetime; + updated_at?: Intercom.Datetime; + /** API URL to download or redirect to the call recording if available. */ + recording_url?: string; + /** API URL to download or redirect to the call transcript if available. */ + transcription_url?: string; + /** The type of call. */ + call_type?: string; + /** The direction of the call. */ + direction?: string; + /** The reason for the call end, if applicable. */ + ended_reason?: string; + /** The phone number involved in the call, in E.164 format. */ + phone?: string; + /** API URL to the AI Agent (Fin) call recording if available. */ + fin_recording_url?: string; + /** API URL to the AI Agent (Fin) call transcript if available. */ + fin_transcription_url?: string; +} diff --git a/src/api/resources/calls/types/ListCallsWithTranscriptsResponse.ts b/src/api/resources/calls/types/ListCallsWithTranscriptsResponse.ts new file mode 100644 index 00000000..f37c83bc --- /dev/null +++ b/src/api/resources/calls/types/ListCallsWithTranscriptsResponse.ts @@ -0,0 +1,21 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +export interface ListCallsWithTranscriptsResponse { + type?: string; + data?: ListCallsWithTranscriptsResponse.Data.Item[]; +} + +export namespace ListCallsWithTranscriptsResponse { + export type Data = Data.Item[]; + + export namespace Data { + export interface Item extends Intercom.Call { + /** The call transcript if available, otherwise an empty array. */ + transcript?: Record[]; + /** The status of the transcript if available. */ + transcript_status?: string; + } + } +} diff --git a/src/api/resources/calls/types/index.ts b/src/api/resources/calls/types/index.ts new file mode 100644 index 00000000..a7b7c7f7 --- /dev/null +++ b/src/api/resources/calls/types/index.ts @@ -0,0 +1,2 @@ +export * from "./Call.js"; +export * from "./ListCallsWithTranscriptsResponse.js"; diff --git a/src/api/resources/companies/client/Client.ts b/src/api/resources/companies/client/Client.ts index 5ac7d49b..db9cb03e 100644 --- a/src/api/resources/companies/client/Client.ts +++ b/src/api/resources/companies/client/Client.ts @@ -1,79 +1,29 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace Companies { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace CompaniesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Companies */ -export class Companies { - constructor(protected readonly _options: Companies.Options = {}) {} +export class CompaniesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: CompaniesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a single company by passing in `company_id` or `name`. @@ -89,7 +39,7 @@ export class Companies { * `https://api.intercom.io/companies?segment_id={segment_id}` * * @param {Intercom.RetrieveCompanyRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -99,71 +49,70 @@ export class Companies { * name: "my company", * company_id: "12345", * tag_id: "678910", - * segment_id: "98765" + * segment_id: "98765", + * page: 1, + * per_page: 1 * }) */ public retrieve( request: Intercom.RetrieveCompanyRequest = {}, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__retrieve(request, requestOptions)); } private async __retrieve( request: Intercom.RetrieveCompanyRequest = {}, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { name, company_id: companyId, tag_id: tagId, segment_id: segmentId, page, per_page: perPage } = request; const _queryParams: Record = {}; if (name != null) { - _queryParams["name"] = name; + _queryParams.name = name; } if (companyId != null) { - _queryParams["company_id"] = companyId; + _queryParams.company_id = companyId; } if (tagId != null) { - _queryParams["tag_id"] = tagId; + _queryParams.tag_id = tagId; } if (segmentId != null) { - _queryParams["segment_id"] = segmentId; + _queryParams.segment_id = segmentId; } if (page != null) { - _queryParams["page"] = page.toString(); + _queryParams.page = page.toString(); } if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); + _queryParams.per_page = perPage.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "companies", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.CompaniesRetrieveResponse, rawResponse: _response.rawResponse }; @@ -187,21 +136,7 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/companies"); } /** @@ -216,7 +151,7 @@ export class Companies { * {% /admonition %} * * @param {Intercom.CreateOrUpdateCompanyRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.BadRequestError} * @throws {@link Intercom.UnauthorizedError} @@ -232,41 +167,41 @@ export class Companies { * await client.companies.createOrUpdate() */ public createOrUpdate( - request: Intercom.CreateOrUpdateCompanyRequest = {}, - requestOptions?: Companies.RequestOptions, + request?: Intercom.CreateOrUpdateCompanyRequest, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createOrUpdate(request, requestOptions)); } private async __createOrUpdate( - request: Intercom.CreateOrUpdateCompanyRequest = {}, - requestOptions?: Companies.RequestOptions, + request?: Intercom.CreateOrUpdateCompanyRequest, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "companies", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", - body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + body: request != null ? request : undefined, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Company, rawResponse: _response.rawResponse }; @@ -290,28 +225,14 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /companies."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/companies"); } /** * You can fetch a single company. * * @param {Intercom.FindCompanyRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -323,40 +244,38 @@ export class Companies { */ public find( request: Intercom.FindCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.FindCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { company_id: companyId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(companyId)}`, + `companies/${core.url.encodePathParam(companyId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Company, rawResponse: _response.rawResponse }; @@ -380,21 +299,7 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/{company_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/companies/{company_id}"); } /** @@ -405,52 +310,63 @@ export class Companies { * {% /admonition %} * * @param {Intercom.UpdateCompanyRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.companies.update({ - * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + * body: { + * name: "my company", + * website: "http://www.mycompany.com/" + * } + * }) + * + * @example + * await client.companies.update({ + * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + * body: {} * }) */ public update( request: Intercom.UpdateCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); } private async __update( request: Intercom.UpdateCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { - const { company_id: companyId } = request; + const { company_id: companyId, body: _body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(companyId)}`, + `companies/${core.url.encodePathParam(companyId)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + body: _body != null ? _body : undefined, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Company, rawResponse: _response.rawResponse }; @@ -474,28 +390,14 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /companies/{company_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/companies/{company_id}"); } /** * You can delete a single company. * * @param {Intercom.DeleteCompanyRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -507,40 +409,38 @@ export class Companies { */ public delete( request: Intercom.DeleteCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__delete(request, requestOptions)); } private async __delete( request: Intercom.DeleteCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { company_id: companyId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(companyId)}`, + `companies/${core.url.encodePathParam(companyId)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.DeletedCompanyObject, rawResponse: _response.rawResponse }; @@ -564,28 +464,14 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /companies/{company_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/companies/{company_id}"); } /** * You can fetch a list of all contacts that belong to a company. * * @param {Intercom.ListAttachedContactsRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -597,50 +483,38 @@ export class Companies { */ public listAttachedContacts( request: Intercom.ListAttachedContactsRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listAttachedContacts(request, requestOptions)); } private async __listAttachedContacts( request: Intercom.ListAttachedContactsRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { - const { company_id: companyId, page, per_page: perPage } = request; - const _queryParams: Record = {}; - if (page != null) { - _queryParams["page"] = page.toString(); - } - - if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); - } - + const { company_id: companyId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(companyId)}/contacts`, + `companies/${core.url.encodePathParam(companyId)}/contacts`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.CompanyAttachedContacts, rawResponse: _response.rawResponse }; @@ -664,30 +538,19 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /companies/{company_id}/contacts.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/companies/{company_id}/contacts", + ); } /** * You can fetch a list of all segments that belong to a company. * * @param {Intercom.ListSegmentsAttachedToCompanyRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -699,40 +562,38 @@ export class Companies { */ public listAttachedSegments( request: Intercom.ListSegmentsAttachedToCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listAttachedSegments(request, requestOptions)); } private async __listAttachedSegments( request: Intercom.ListSegmentsAttachedToCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { company_id: companyId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(companyId)}/segments`, + `companies/${core.url.encodePathParam(companyId)}/segments`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.CompanyAttachedSegments, rawResponse: _response.rawResponse }; @@ -756,23 +617,12 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /companies/{company_id}/segments.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/companies/{company_id}/segments", + ); } /** @@ -787,58 +637,56 @@ export class Companies { * {% /admonition %} * * @param {Intercom.ListCompaniesRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * * @example * await client.companies.list({ + * page: 1, + * per_page: 1, * order: "desc" * }) */ public async list( request: Intercom.ListCompaniesRequest = {}, - requestOptions?: Companies.RequestOptions, - ): Promise> { + requestOptions?: CompaniesClient.RequestOptions, + ): Promise> { const list = core.HttpResponsePromise.interceptFunction( async (request: Intercom.ListCompaniesRequest): Promise> => { const { page, per_page: perPage, order } = request; const _queryParams: Record = {}; if (page != null) { - _queryParams["page"] = page.toString(); + _queryParams.page = page.toString(); } if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); + _queryParams.per_page = perPage.toString(); } if (order != null) { - _queryParams["order"] = order; + _queryParams.order = order; } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "companies/list", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: - requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.CompanyList, rawResponse: _response.rawResponse }; @@ -858,26 +706,12 @@ export class Companies { }); } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /companies/list."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/companies/list"); }, ); let _offset = request?.page != null ? request?.page : 1; const dataWithRawResponse = await list(request).withRawResponse(); - return new core.Pageable({ + return new core.Page({ response: dataWithRawResponse.data, rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => (response?.data ?? []).length > 0, @@ -907,53 +741,56 @@ export class Companies { * {% /admonition %} * * @param {Intercom.ScrollCompaniesRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * * @example - * await client.companies.scroll() + * await client.companies.scroll({ + * scroll_param: "scroll_param" + * }) */ public async scroll( request: Intercom.ScrollCompaniesRequest = {}, - requestOptions?: Companies.RequestOptions, - ): Promise> { + requestOptions?: CompaniesClient.RequestOptions, + ): Promise> { const list = core.HttpResponsePromise.interceptFunction( - async (request: Intercom.ScrollCompaniesRequest): Promise> => { + async ( + request: Intercom.ScrollCompaniesRequest, + ): Promise> => { const { scroll_param: scrollParam } = request; const _queryParams: Record = {}; if (scrollParam != null) { - _queryParams["scroll_param"] = scrollParam; + _queryParams.scroll_param = scrollParam; } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "companies/scroll", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: - requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.CompanyScroll, rawResponse: _response.rawResponse }; + return { + data: _response.body as Intercom.CompanyScroll | undefined, + rawResponse: _response.rawResponse, + }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { @@ -970,28 +807,16 @@ export class Companies { }); } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/scroll."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/companies/scroll"); }, ); const dataWithRawResponse = await list(request).withRawResponse(); - return new core.Pageable({ + return new core.Page({ response: dataWithRawResponse.data, rawResponse: dataWithRawResponse.rawResponse, - hasNextPage: (response) => response?.scroll_param != null, + hasNextPage: (response) => + response?.scroll_param != null && + !(typeof response?.scroll_param === "string" && response?.scroll_param === ""), getItems: (response) => response?.data ?? [], loadPage: (response) => { return list(core.setObjectProperty(request, "scroll_param", response?.scroll_param)); @@ -1003,7 +828,7 @@ export class Companies { * You can attach a company to a single contact. * * @param {Intercom.AttachContactToCompanyRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.BadRequestError} * @throws {@link Intercom.UnauthorizedError} @@ -1012,7 +837,7 @@ export class Companies { * @example * await client.companies.attachContact({ * contact_id: "contact_id", - * id: "667d608d8a68186f43bafd70" + * id: "6762f09a1bb69f9f2193bb34" * }) * * @example @@ -1029,41 +854,41 @@ export class Companies { */ public attachContact( request: Intercom.AttachContactToCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__attachContact(request, requestOptions)); } private async __attachContact( request: Intercom.AttachContactToCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { contact_id: contactId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/companies`, + `contacts/${core.url.encodePathParam(contactId)}/companies`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Company, rawResponse: _response.rawResponse }; @@ -1089,30 +914,19 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /contacts/{contact_id}/companies.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/contacts/{contact_id}/companies", + ); } /** * You can detach a company from a single contact. * * @param {Intercom.DetachContactFromCompanyRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -1125,40 +939,38 @@ export class Companies { */ public detachContact( request: Intercom.DetachContactFromCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__detachContact(request, requestOptions)); } private async __detachContact( request: Intercom.DetachContactFromCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { contact_id: contactId, company_id: companyId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/companies/${encodeURIComponent(companyId)}`, + `contacts/${core.url.encodePathParam(contactId)}/companies/${core.url.encodePathParam(companyId)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Company, rawResponse: _response.rawResponse }; @@ -1182,34 +994,11 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /contacts/{contact_id}/companies/{company_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/contacts/{contact_id}/companies/{company_id}", + ); } } diff --git a/src/api/resources/companies/client/index.ts b/src/api/resources/companies/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/companies/client/index.ts +++ b/src/api/resources/companies/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/companies/client/requests/AttachContactToCompanyRequest.ts b/src/api/resources/companies/client/requests/AttachContactToCompanyRequest.ts index 17a7d4b3..95995f1a 100644 --- a/src/api/resources/companies/client/requests/AttachContactToCompanyRequest.ts +++ b/src/api/resources/companies/client/requests/AttachContactToCompanyRequest.ts @@ -1,12 +1,10 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { * contact_id: "contact_id", - * id: "667d608d8a68186f43bafd70" + * id: "6762f09a1bb69f9f2193bb34" * } * * @example @@ -22,9 +20,7 @@ * } */ export interface AttachContactToCompanyRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; /** The unique identifier for the company which is given by Intercom */ id: string; diff --git a/src/api/resources/companies/client/requests/DeleteCompanyRequest.ts b/src/api/resources/companies/client/requests/DeleteCompanyRequest.ts index 907c4032..89d10288 100644 --- a/src/api/resources/companies/client/requests/DeleteCompanyRequest.ts +++ b/src/api/resources/companies/client/requests/DeleteCompanyRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DeleteCompanyRequest { - /** - * The unique identifier for the company which is given by Intercom - */ + /** The unique identifier for the company which is given by Intercom */ company_id: string; } diff --git a/src/api/resources/companies/client/requests/DetachContactFromCompanyRequest.ts b/src/api/resources/companies/client/requests/DetachContactFromCompanyRequest.ts index 9264bac5..6b35eccd 100644 --- a/src/api/resources/companies/client/requests/DetachContactFromCompanyRequest.ts +++ b/src/api/resources/companies/client/requests/DetachContactFromCompanyRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -10,12 +8,8 @@ * } */ export interface DetachContactFromCompanyRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; - /** - * The unique identifier for the company which is given by Intercom - */ + /** The unique identifier for the company which is given by Intercom */ company_id: string; } diff --git a/src/api/resources/companies/client/requests/FindCompanyRequest.ts b/src/api/resources/companies/client/requests/FindCompanyRequest.ts index ca707798..6be81172 100644 --- a/src/api/resources/companies/client/requests/FindCompanyRequest.ts +++ b/src/api/resources/companies/client/requests/FindCompanyRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface FindCompanyRequest { - /** - * The unique identifier for the company which is given by Intercom - */ + /** The unique identifier for the company which is given by Intercom */ company_id: string; } diff --git a/src/api/resources/companies/client/requests/ListAttachedContactsRequest.ts b/src/api/resources/companies/client/requests/ListAttachedContactsRequest.ts index af7ff8a7..544f392f 100644 --- a/src/api/resources/companies/client/requests/ListAttachedContactsRequest.ts +++ b/src/api/resources/companies/client/requests/ListAttachedContactsRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,16 +7,6 @@ * } */ export interface ListAttachedContactsRequest { - /** - * The unique identifier for the company which is given by Intercom - */ + /** The unique identifier for the company which is given by Intercom */ company_id: string; - /** - * The page of results to fetch. Defaults to first page - */ - page?: number; - /** - * How many results to return per page. Defaults to 15 - */ - per_page?: number; } diff --git a/src/api/resources/companies/client/requests/ListCompaniesRequest.ts b/src/api/resources/companies/client/requests/ListCompaniesRequest.ts index 3d097dd4..ff355c19 100644 --- a/src/api/resources/companies/client/requests/ListCompaniesRequest.ts +++ b/src/api/resources/companies/client/requests/ListCompaniesRequest.ts @@ -1,24 +1,18 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { + * page: 1, + * per_page: 1, * order: "desc" * } */ export interface ListCompaniesRequest { - /** - * The page of results to fetch. Defaults to first page - */ + /** The page of results to fetch. Defaults to first page */ page?: number; - /** - * How many results to return per page. Defaults to 15 - */ + /** How many results to return per page. Defaults to 15 */ per_page?: number; - /** - * `asc` or `desc`. Return the companies in ascending or descending order. Defaults to desc - */ + /** `asc` or `desc`. Return the companies in ascending or descending order. Defaults to desc */ order?: string; } diff --git a/src/api/resources/companies/client/requests/ListSegmentsAttachedToCompanyRequest.ts b/src/api/resources/companies/client/requests/ListSegmentsAttachedToCompanyRequest.ts index 6c640aea..36c2e57f 100644 --- a/src/api/resources/companies/client/requests/ListSegmentsAttachedToCompanyRequest.ts +++ b/src/api/resources/companies/client/requests/ListSegmentsAttachedToCompanyRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ListSegmentsAttachedToCompanyRequest { - /** - * The unique identifier for the company which is given by Intercom - */ + /** The unique identifier for the company which is given by Intercom */ company_id: string; } diff --git a/src/api/resources/companies/client/requests/RetrieveCompanyRequest.ts b/src/api/resources/companies/client/requests/RetrieveCompanyRequest.ts index 557a2e00..a3314297 100644 --- a/src/api/resources/companies/client/requests/RetrieveCompanyRequest.ts +++ b/src/api/resources/companies/client/requests/RetrieveCompanyRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -8,32 +6,22 @@ * name: "my company", * company_id: "12345", * tag_id: "678910", - * segment_id: "98765" + * segment_id: "98765", + * page: 1, + * per_page: 1 * } */ export interface RetrieveCompanyRequest { - /** - * The `name` of the company to filter by. - */ + /** The `name` of the company to filter by. */ name?: string; - /** - * The `company_id` of the company to filter by. - */ + /** The `company_id` of the company to filter by. */ company_id?: string; - /** - * The `tag_id` of the company to filter by. - */ + /** The `tag_id` of the company to filter by. */ tag_id?: string; - /** - * The `segment_id` of the company to filter by. - */ + /** The `segment_id` of the company to filter by. */ segment_id?: string; - /** - * The page of results to fetch. Defaults to first page - */ + /** The page of results to fetch. Defaults to first page */ page?: number; - /** - * How many results to display per page. Defaults to 15 - */ + /** How many results to display per page. Defaults to 15 */ per_page?: number; } diff --git a/src/api/resources/companies/client/requests/ScrollCompaniesRequest.ts b/src/api/resources/companies/client/requests/ScrollCompaniesRequest.ts index f5233617..56661c7f 100644 --- a/src/api/resources/companies/client/requests/ScrollCompaniesRequest.ts +++ b/src/api/resources/companies/client/requests/ScrollCompaniesRequest.ts @@ -1,14 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example - * {} + * { + * scroll_param: "scroll_param" + * } */ export interface ScrollCompaniesRequest { - /** - * - */ + /** */ scroll_param?: string; } diff --git a/src/api/resources/companies/client/requests/UpdateCompanyRequest.ts b/src/api/resources/companies/client/requests/UpdateCompanyRequest.ts index bcd76db2..6bb331ec 100644 --- a/src/api/resources/companies/client/requests/UpdateCompanyRequest.ts +++ b/src/api/resources/companies/client/requests/UpdateCompanyRequest.ts @@ -1,16 +1,25 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../index.js"; /** * @example * { - * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + * body: { + * name: "my company", + * website: "http://www.mycompany.com/" + * } + * } + * + * @example + * { + * company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + * body: {} * } */ export interface UpdateCompanyRequest { - /** - * The unique identifier for the company which is given by Intercom - */ + /** The unique identifier for the company which is given by Intercom */ company_id: string; + body?: Intercom.UpdateCompanyRequestBody; } diff --git a/src/api/resources/companies/client/requests/index.ts b/src/api/resources/companies/client/requests/index.ts index 6e45efe4..3c6204dc 100644 --- a/src/api/resources/companies/client/requests/index.ts +++ b/src/api/resources/companies/client/requests/index.ts @@ -1,11 +1,10 @@ -export { type RetrieveCompanyRequest } from "./RetrieveCompanyRequest"; -export { type CreateOrUpdateCompanyRequest } from "./CreateOrUpdateCompanyRequest"; -export { type FindCompanyRequest } from "./FindCompanyRequest"; -export { type UpdateCompanyRequest } from "./UpdateCompanyRequest"; -export { type DeleteCompanyRequest } from "./DeleteCompanyRequest"; -export { type ListAttachedContactsRequest } from "./ListAttachedContactsRequest"; -export { type ListSegmentsAttachedToCompanyRequest } from "./ListSegmentsAttachedToCompanyRequest"; -export { type ListCompaniesRequest } from "./ListCompaniesRequest"; -export { type ScrollCompaniesRequest } from "./ScrollCompaniesRequest"; -export { type AttachContactToCompanyRequest } from "./AttachContactToCompanyRequest"; -export { type DetachContactFromCompanyRequest } from "./DetachContactFromCompanyRequest"; +export type { AttachContactToCompanyRequest } from "./AttachContactToCompanyRequest.js"; +export type { DeleteCompanyRequest } from "./DeleteCompanyRequest.js"; +export type { DetachContactFromCompanyRequest } from "./DetachContactFromCompanyRequest.js"; +export type { FindCompanyRequest } from "./FindCompanyRequest.js"; +export type { ListAttachedContactsRequest } from "./ListAttachedContactsRequest.js"; +export type { ListCompaniesRequest } from "./ListCompaniesRequest.js"; +export type { ListSegmentsAttachedToCompanyRequest } from "./ListSegmentsAttachedToCompanyRequest.js"; +export type { RetrieveCompanyRequest } from "./RetrieveCompanyRequest.js"; +export type { ScrollCompaniesRequest } from "./ScrollCompaniesRequest.js"; +export type { UpdateCompanyRequest } from "./UpdateCompanyRequest.js"; diff --git a/src/api/resources/companies/index.ts b/src/api/resources/companies/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/companies/index.ts +++ b/src/api/resources/companies/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/companies/types/CompaniesRetrieveResponse.ts b/src/api/resources/companies/types/CompaniesRetrieveResponse.ts index fbe90f3f..97513a72 100644 --- a/src/api/resources/companies/types/CompaniesRetrieveResponse.ts +++ b/src/api/resources/companies/types/CompaniesRetrieveResponse.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; export type CompaniesRetrieveResponse = | Intercom.CompaniesRetrieveResponse.Company diff --git a/src/api/resources/companies/types/Company.ts b/src/api/resources/companies/types/Company.ts index 2de7fd36..cb26b686 100644 --- a/src/api/resources/companies/types/Company.ts +++ b/src/api/resources/companies/types/Company.ts @@ -1,13 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Companies allow you to represent organizations using your product. Each company will have its own description and be associated with contacts. You can fetch, create, update and list companies. */ export interface Company { + /** Value is `company` */ + type?: "company"; /** The Intercom defined id representing the company. */ id: string; /** The name of the company. */ @@ -18,19 +18,19 @@ export interface Company { /** The company id you have defined for the company. */ company_id: string; /** The time the company was created by you. */ - remote_created_at: number; + remote_created_at?: number; /** The time the company was added in Intercom. */ created_at: number; /** The last time the company was updated. */ updated_at: number; /** The time the company last recorded making a request. */ - last_request_at: number; + last_request_at?: number; /** The number of employees in the company. */ - size: number; + size?: number; /** The URL for the company website. */ - website: string; + website?: string; /** The industry that the company operates in. */ - industry: string; + industry?: string; /** How much revenue the company generates for your business. */ monthly_spend: number; /** How many sessions the company has recorded. */ @@ -48,7 +48,7 @@ export interface Company { export namespace Company { export interface Plan { /** Value is always "plan" */ - type?: "plan"; + type?: string; /** The id of the plan */ id?: string; /** The name of the plan */ diff --git a/src/api/resources/companies/types/index.ts b/src/api/resources/companies/types/index.ts index 66af316a..7e2092d3 100644 --- a/src/api/resources/companies/types/index.ts +++ b/src/api/resources/companies/types/index.ts @@ -1,2 +1,2 @@ -export * from "./CompaniesRetrieveResponse"; -export * from "./Company"; +export * from "./CompaniesRetrieveResponse.js"; +export * from "./Company.js"; diff --git a/src/api/resources/contacts/client/Client.ts b/src/api/resources/contacts/client/Client.ts index 894de6c9..f5ec64f4 100644 --- a/src/api/resources/contacts/client/Client.ts +++ b/src/api/resources/contacts/client/Client.ts @@ -1,98 +1,50 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; - -export declare namespace Contacts { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } +export declare namespace ContactsClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your contacts */ -export class Contacts { - constructor(protected readonly _options: Contacts.Options = {}) {} +export class ContactsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: ContactsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of companies that are associated to a contact. * * @param {Intercom.ListAttachedCompaniesRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.contacts.listAttachedCompanies({ - * contact_id: "63a07ddf05a32042dffac965" + * contact_id: "63a07ddf05a32042dffac965", + * page: 1, + * per_page: 1 * }) */ public async listAttachedCompanies( request: Intercom.ListAttachedCompaniesRequest, - requestOptions?: Contacts.RequestOptions, - ): Promise> { + requestOptions?: ContactsClient.RequestOptions, + ): Promise> { const list = core.HttpResponsePromise.interceptFunction( async ( request: Intercom.ListAttachedCompaniesRequest, @@ -100,37 +52,33 @@ export class Contacts { const { contact_id: contactId, page, per_page: perPage } = request; const _queryParams: Record = {}; if (page != null) { - _queryParams["page"] = page.toString(); + _queryParams.page = page.toString(); } if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); + _queryParams.per_page = perPage.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/companies`, + `contacts/${core.url.encodePathParam(contactId)}/companies`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: - requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -155,28 +103,17 @@ export class Contacts { }); } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /contacts/{contact_id}/companies.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/contacts/{contact_id}/companies", + ); }, ); let _offset = request?.page != null ? request?.page : 1; const dataWithRawResponse = await list(request).withRawResponse(); - return new core.Pageable({ + return new core.Page({ response: dataWithRawResponse.data, rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => (response?.companies ?? []).length > 0, @@ -192,7 +129,7 @@ export class Contacts { * You can fetch a list of segments that are associated to a contact. * * @param {Intercom.ListSegmentsAttachedToContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -204,40 +141,38 @@ export class Contacts { */ public listAttachedSegments( request: Intercom.ListSegmentsAttachedToContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listAttachedSegments(request, requestOptions)); } private async __listAttachedSegments( request: Intercom.ListSegmentsAttachedToContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { contact_id: contactId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/segments`, + `contacts/${core.url.encodePathParam(contactId)}/segments`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.ContactSegments, rawResponse: _response.rawResponse }; @@ -261,23 +196,12 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /contacts/{contact_id}/segments.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/contacts/{contact_id}/segments", + ); } /** @@ -290,7 +214,7 @@ export class Contacts { * 2.Opt-in subscription types that the user has opted-in to receiving. * * @param {Intercom.ListAttachedSubscriptionsRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -302,40 +226,38 @@ export class Contacts { */ public listAttachedSubscriptions( request: Intercom.ListAttachedSubscriptionsRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listAttachedSubscriptions(request, requestOptions)); } private async __listAttachedSubscriptions( request: Intercom.ListAttachedSubscriptionsRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { contact_id: contactId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/subscriptions`, + `contacts/${core.url.encodePathParam(contactId)}/subscriptions`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.SubscriptionTypeList, rawResponse: _response.rawResponse }; @@ -359,23 +281,12 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /contacts/{contact_id}/subscriptions.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/contacts/{contact_id}/subscriptions", + ); } /** @@ -388,7 +299,7 @@ export class Contacts { * This will return a subscription type model for the subscription type that was added to the contact. * * @param {Intercom.AttachSubscriptionToContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -409,41 +320,41 @@ export class Contacts { */ public attachSubscription( request: Intercom.AttachSubscriptionToContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__attachSubscription(request, requestOptions)); } private async __attachSubscription( request: Intercom.AttachSubscriptionToContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { contact_id: contactId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/subscriptions`, + `contacts/${core.url.encodePathParam(contactId)}/subscriptions`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.SubscriptionType, rawResponse: _response.rawResponse }; @@ -467,30 +378,19 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /contacts/{contact_id}/subscriptions.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/contacts/{contact_id}/subscriptions", + ); } /** * You can remove a specific subscription from a contact. This will return a subscription type model for the subscription type that was removed from the contact. * * @param {Intercom.DetachSubscriptionFromContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -503,40 +403,38 @@ export class Contacts { */ public detachSubscription( request: Intercom.DetachSubscriptionFromContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__detachSubscription(request, requestOptions)); } private async __detachSubscription( request: Intercom.DetachSubscriptionFromContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { contact_id: contactId, subscription_id: subscriptionId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/subscriptions/${encodeURIComponent(subscriptionId)}`, + `contacts/${core.url.encodePathParam(contactId)}/subscriptions/${core.url.encodePathParam(subscriptionId)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.SubscriptionType, rawResponse: _response.rawResponse }; @@ -560,30 +458,19 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /contacts/{contact_id}/subscriptions/{subscription_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/contacts/{contact_id}/subscriptions/{subscription_id}", + ); } /** * You can fetch a list of all tags that are attached to a specific contact. * * @param {Intercom.ListTagsAttachedToContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -595,40 +482,38 @@ export class Contacts { */ public listAttachedTags( request: Intercom.ListTagsAttachedToContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listAttachedTags(request, requestOptions)); } private async __listAttachedTags( request: Intercom.ListTagsAttachedToContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { contact_id: contactId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/tags`, + `contacts/${core.url.encodePathParam(contactId)}/tags`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.TagList, rawResponse: _response.rawResponse }; @@ -652,28 +537,14 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts/{contact_id}/tags."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/contacts/{contact_id}/tags"); } /** * You can fetch the details of a single contact. * * @param {Intercom.FindContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -684,43 +555,41 @@ export class Contacts { */ public find( request: Intercom.FindContactRequest, - requestOptions?: Contacts.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: ContactsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.FindContactRequest, - requestOptions?: Contacts.RequestOptions, - ): Promise> { + requestOptions?: ContactsClient.RequestOptions, + ): Promise> { const { contact_id: contactId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}`, + `contacts/${core.url.encodePathParam(contactId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.Contact, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.ContactsFindResponse, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -739,28 +608,20 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts/{contact_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/contacts/{contact_id}"); } /** * You can update an existing contact (ie. user or lead). * + * {% admonition type="info" %} + * This endpoint handles both **contact updates** and **custom object associations**. + * + * See _`update a contact with an association to a custom object instance`_ in the request/response examples to see the custom object association format. + * {% /admonition %} + * * @param {Intercom.UpdateContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -770,47 +631,57 @@ export class Contacts { * email: "joebloggs@intercom.io", * name: "joe bloggs" * }) + * + * @example + * await client.contacts.update({ + * contact_id: "63a07ddf05a32042dffac965", + * custom_attributes: { + * "order": [ + * "21" + * ] + * } + * }) */ public update( request: Intercom.UpdateContactRequest, - requestOptions?: Contacts.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: ContactsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); } private async __update( request: Intercom.UpdateContactRequest, - requestOptions?: Contacts.RequestOptions, - ): Promise> { + requestOptions?: ContactsClient.RequestOptions, + ): Promise> { const { contact_id: contactId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}`, + `contacts/${core.url.encodePathParam(contactId)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.Contact, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.ContactsUpdateResponse, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -829,28 +700,14 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /contacts/{contact_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/contacts/{contact_id}"); } /** * You can delete a single contact. * * @param {Intercom.DeleteContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -861,40 +718,38 @@ export class Contacts { */ public delete( request: Intercom.DeleteContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__delete(request, requestOptions)); } private async __delete( request: Intercom.DeleteContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { contact_id: contactId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}`, + `contacts/${core.url.encodePathParam(contactId)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.ContactDeleted, rawResponse: _response.rawResponse }; @@ -916,76 +771,65 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /contacts/{contact_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/contacts/{contact_id}"); } /** * You can merge a contact with a `role` of `lead` into a contact with a `role` of `user`. * * @param {Intercom.MergeContactsRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * * @example * await client.contacts.mergeLeadInUser({ - * from: "667d60ac8a68186f43bafdbb", - * into: "667d60ac8a68186f43bafdbc" + * from: "6762f0d51bb69f9f2193bb7f", + * into: "6762f0d51bb69f9f2193bb80" * }) */ public mergeLeadInUser( - request: Intercom.MergeContactsRequest, - requestOptions?: Contacts.RequestOptions, - ): core.HttpResponsePromise { + request: Intercom.MergeContactsRequest = {}, + requestOptions?: ContactsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__mergeLeadInUser(request, requestOptions)); } private async __mergeLeadInUser( - request: Intercom.MergeContactsRequest, - requestOptions?: Contacts.RequestOptions, - ): Promise> { + request: Intercom.MergeContactsRequest = {}, + requestOptions?: ContactsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "contacts/merge", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.Contact, rawResponse: _response.rawResponse }; + return { + data: _response.body as Intercom.ContactsMergeLeadInUserResponse, + rawResponse: _response.rawResponse, + }; } if (_response.error.reason === "status-code") { @@ -1004,21 +848,7 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/merge."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts/merge"); } /** @@ -1123,7 +953,7 @@ export class Contacts { * | $ | String | Ends With | * * @param {Intercom.SearchRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -1144,36 +974,35 @@ export class Contacts { */ public async search( request: Intercom.SearchRequest, - requestOptions?: Contacts.RequestOptions, - ): Promise> { + requestOptions?: ContactsClient.RequestOptions, + ): Promise> { const list = core.HttpResponsePromise.interceptFunction( async (request: Intercom.SearchRequest): Promise> => { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "contacts/search", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: - requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.ContactList, rawResponse: _response.rawResponse }; @@ -1193,28 +1022,19 @@ export class Contacts { }); } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/search."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts/search"); }, ); const dataWithRawResponse = await list(request).withRawResponse(); - return new core.Pageable({ + return new core.Page({ response: dataWithRawResponse.data, rawResponse: dataWithRawResponse.rawResponse, - hasNextPage: (response) => response?.pages?.next?.starting_after != null, + hasNextPage: (response) => + response?.pages?.next?.starting_after != null && + !( + typeof response?.pages?.next?.starting_after === "string" && + response?.pages?.next?.starting_after === "" + ), getItems: (response) => response?.data ?? [], loadPage: (response) => { return list( @@ -1232,7 +1052,7 @@ export class Contacts { * {% /admonition %} * * @param {Intercom.ListContactsRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -1241,47 +1061,43 @@ export class Contacts { */ public async list( request: Intercom.ListContactsRequest = {}, - requestOptions?: Contacts.RequestOptions, - ): Promise> { + requestOptions?: ContactsClient.RequestOptions, + ): Promise> { const list = core.HttpResponsePromise.interceptFunction( async (request: Intercom.ListContactsRequest): Promise> => { const { page, per_page: perPage, starting_after: startingAfter } = request; const _queryParams: Record = {}; if (page != null) { - _queryParams["page"] = page.toString(); + _queryParams.page = page.toString(); } if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); + _queryParams.per_page = perPage.toString(); } if (startingAfter != null) { - _queryParams["starting_after"] = startingAfter; + _queryParams.starting_after = startingAfter; } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "contacts", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: - requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.ContactList, rawResponse: _response.rawResponse }; @@ -1301,28 +1117,19 @@ export class Contacts { }); } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/contacts"); }, ); const dataWithRawResponse = await list(request).withRawResponse(); - return new core.Pageable({ + return new core.Page({ response: dataWithRawResponse.data, rawResponse: dataWithRawResponse.rawResponse, - hasNextPage: (response) => response?.pages?.next?.starting_after != null, + hasNextPage: (response) => + response?.pages?.next?.starting_after != null && + !( + typeof response?.pages?.next?.starting_after === "string" && + response?.pages?.next?.starting_after === "" + ), getItems: (response) => response?.data ?? [], loadPage: (response) => { return list(core.setObjectProperty(request, "starting_after", response?.pages?.next?.starting_after)); @@ -1334,7 +1141,7 @@ export class Contacts { * You can create a new contact (ie. user or lead). * * @param {Intercom.CreateContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -1345,43 +1152,43 @@ export class Contacts { */ public create( request: Intercom.CreateContactRequest, - requestOptions?: Contacts.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: ContactsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( request: Intercom.CreateContactRequest, - requestOptions?: Contacts.RequestOptions, - ): Promise> { + requestOptions?: ContactsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "contacts", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.Contact, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.ContactsCreateResponse, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -1400,28 +1207,93 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts"); + } + + /** + * You can fetch the details of a single contact by external ID. Note that this endpoint only supports users and not leads. + * + * @param {Intercom.ShowContactByExternalIdRequest} request + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.contacts.showContactByExternalId({ + * external_id: "cdd29344-5e0c-4ef0-ac56-f9ba2979bc27" + * }) + */ + public showContactByExternalId( + request: Intercom.ShowContactByExternalIdRequest, + requestOptions?: ContactsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__showContactByExternalId(request, requestOptions)); + } + + private async __showContactByExternalId( + request: Intercom.ShowContactByExternalIdRequest, + requestOptions?: ContactsClient.RequestOptions, + ): Promise> { + const { external_id: externalId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/find_by_external_id/${core.url.encodePathParam(externalId)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.ShowContactByExternalIdResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/contacts/find_by_external_id/{external_id}", + ); } /** * You can archive a single contact. * * @param {Intercom.ArchiveContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.contacts.archive({ @@ -1430,40 +1302,38 @@ export class Contacts { */ public archive( request: Intercom.ArchiveContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__archive(request, requestOptions)); } private async __archive( request: Intercom.ArchiveContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { contact_id: contactId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/archive`, + `contacts/${core.url.encodePathParam(contactId)}/archive`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.ContactArchived, rawResponse: _response.rawResponse }; @@ -1477,30 +1347,19 @@ export class Contacts { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /contacts/{contact_id}/archive.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/contacts/{contact_id}/archive", + ); } /** * You can unarchive a single contact. * * @param {Intercom.UnarchiveContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.contacts.unarchive({ @@ -1509,40 +1368,38 @@ export class Contacts { */ public unarchive( request: Intercom.UnarchiveContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__unarchive(request, requestOptions)); } private async __unarchive( request: Intercom.UnarchiveContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { contact_id: contactId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/unarchive`, + `contacts/${core.url.encodePathParam(contactId)}/unarchive`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.ContactUnarchived, rawResponse: _response.rawResponse }; @@ -1556,34 +1413,72 @@ export class Contacts { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /contacts/{contact_id}/unarchive.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/contacts/{contact_id}/unarchive", + ); + } + + /** + * Block a single contact.
**Note:** conversations of the contact will also be archived during the process.
More details in [FAQ How do I block Inbox spam?](https://www.intercom.com/help/en/articles/8838656-inbox-faqs) + * + * @param {Intercom.BlockContactRequest} request + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.contacts.blockContact({ + * contact_id: "63a07ddf05a32042dffac965" + * }) + */ + public blockContact( + request: Intercom.BlockContactRequest, + requestOptions?: ContactsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__blockContact(request, requestOptions)); } - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { + private async __blockContact( + request: Intercom.BlockContactRequest, + requestOptions?: ContactsClient.RequestOptions, + ): Promise> { + const { contact_id: contactId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `contacts/${core.url.encodePathParam(contactId)}/block`, + ), + method: "POST", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.ContactBlocked, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, }); } - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts/{contact_id}/block"); } } diff --git a/src/api/resources/contacts/client/index.ts b/src/api/resources/contacts/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/contacts/client/index.ts +++ b/src/api/resources/contacts/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/contacts/client/requests/ArchiveContactRequest.ts b/src/api/resources/contacts/client/requests/ArchiveContactRequest.ts index 1e5452c4..9a3380a0 100644 --- a/src/api/resources/contacts/client/requests/ArchiveContactRequest.ts +++ b/src/api/resources/contacts/client/requests/ArchiveContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ArchiveContactRequest { - /** - * id - */ + /** contact_id */ contact_id: string; } diff --git a/src/api/resources/contacts/client/requests/AttachSubscriptionToContactRequest.ts b/src/api/resources/contacts/client/requests/AttachSubscriptionToContactRequest.ts index 6433e324..8bd134af 100644 --- a/src/api/resources/contacts/client/requests/AttachSubscriptionToContactRequest.ts +++ b/src/api/resources/contacts/client/requests/AttachSubscriptionToContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -25,9 +23,7 @@ * } */ export interface AttachSubscriptionToContactRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; /** The unique identifier for the subscription which is given by Intercom */ id: string; diff --git a/src/api/resources/contacts/client/requests/BlockContactRequest.ts b/src/api/resources/contacts/client/requests/BlockContactRequest.ts new file mode 100644 index 00000000..538c9a21 --- /dev/null +++ b/src/api/resources/contacts/client/requests/BlockContactRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * contact_id: "63a07ddf05a32042dffac965" + * } + */ +export interface BlockContactRequest { + /** contact_id */ + contact_id: string; +} diff --git a/src/api/resources/contacts/client/requests/DeleteContactRequest.ts b/src/api/resources/contacts/client/requests/DeleteContactRequest.ts index 559cfeb9..42fb1445 100644 --- a/src/api/resources/contacts/client/requests/DeleteContactRequest.ts +++ b/src/api/resources/contacts/client/requests/DeleteContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DeleteContactRequest { - /** - * id - */ + /** contact_id */ contact_id: string; } diff --git a/src/api/resources/contacts/client/requests/DetachSubscriptionFromContactRequest.ts b/src/api/resources/contacts/client/requests/DetachSubscriptionFromContactRequest.ts index 081c1459..d5a9e4e3 100644 --- a/src/api/resources/contacts/client/requests/DetachSubscriptionFromContactRequest.ts +++ b/src/api/resources/contacts/client/requests/DetachSubscriptionFromContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -10,12 +8,8 @@ * } */ export interface DetachSubscriptionFromContactRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; - /** - * The unique identifier for the subscription type which is given by Intercom - */ + /** The unique identifier for the subscription type which is given by Intercom */ subscription_id: string; } diff --git a/src/api/resources/contacts/client/requests/FindContactRequest.ts b/src/api/resources/contacts/client/requests/FindContactRequest.ts index 3eed3e85..a73c27ad 100644 --- a/src/api/resources/contacts/client/requests/FindContactRequest.ts +++ b/src/api/resources/contacts/client/requests/FindContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface FindContactRequest { - /** - * id - */ + /** contact_id */ contact_id: string; } diff --git a/src/api/resources/contacts/client/requests/ListAttachedCompaniesRequest.ts b/src/api/resources/contacts/client/requests/ListAttachedCompaniesRequest.ts index 5c1f5caa..bf57a734 100644 --- a/src/api/resources/contacts/client/requests/ListAttachedCompaniesRequest.ts +++ b/src/api/resources/contacts/client/requests/ListAttachedCompaniesRequest.ts @@ -1,24 +1,18 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * contact_id: "63a07ddf05a32042dffac965" + * contact_id: "63a07ddf05a32042dffac965", + * page: 1, + * per_page: 1 * } */ export interface ListAttachedCompaniesRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; - /** - * The page of results to fetch. Defaults to first page - */ + /** The page of results to fetch. Defaults to first page */ page?: number; - /** - * How many results to display per page. Defaults to 15 - */ + /** How many results to display per page. Defaults to 15 */ per_page?: number; } diff --git a/src/api/resources/contacts/client/requests/ListAttachedSubscriptionsRequest.ts b/src/api/resources/contacts/client/requests/ListAttachedSubscriptionsRequest.ts index 3ab3f449..12dce4dd 100644 --- a/src/api/resources/contacts/client/requests/ListAttachedSubscriptionsRequest.ts +++ b/src/api/resources/contacts/client/requests/ListAttachedSubscriptionsRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ListAttachedSubscriptionsRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; } diff --git a/src/api/resources/contacts/client/requests/ListContactsRequest.ts b/src/api/resources/contacts/client/requests/ListContactsRequest.ts index b67a189f..779b4121 100644 --- a/src/api/resources/contacts/client/requests/ListContactsRequest.ts +++ b/src/api/resources/contacts/client/requests/ListContactsRequest.ts @@ -1,22 +1,14 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * {} */ export interface ListContactsRequest { - /** - * The page of results to fetch. Defaults to first page - */ + /** The page of results to fetch. Defaults to first page */ page?: number; - /** - * How many results to display per page. Defaults to 15 - */ + /** How many results to display per page. Defaults to 15 */ per_page?: number; - /** - * String used to get the next page of conversations. - */ + /** String used to get the next page of conversations. */ starting_after?: string; } diff --git a/src/api/resources/contacts/client/requests/ListSegmentsAttachedToContactRequest.ts b/src/api/resources/contacts/client/requests/ListSegmentsAttachedToContactRequest.ts index b120b483..f2fe1a11 100644 --- a/src/api/resources/contacts/client/requests/ListSegmentsAttachedToContactRequest.ts +++ b/src/api/resources/contacts/client/requests/ListSegmentsAttachedToContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ListSegmentsAttachedToContactRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; } diff --git a/src/api/resources/contacts/client/requests/ListTagsAttachedToContactRequest.ts b/src/api/resources/contacts/client/requests/ListTagsAttachedToContactRequest.ts index 632002f6..1d62aa60 100644 --- a/src/api/resources/contacts/client/requests/ListTagsAttachedToContactRequest.ts +++ b/src/api/resources/contacts/client/requests/ListTagsAttachedToContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ListTagsAttachedToContactRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; } diff --git a/src/api/resources/contacts/client/requests/MergeContactsRequest.ts b/src/api/resources/contacts/client/requests/MergeContactsRequest.ts index 704efeb1..520d7f83 100644 --- a/src/api/resources/contacts/client/requests/MergeContactsRequest.ts +++ b/src/api/resources/contacts/client/requests/MergeContactsRequest.ts @@ -1,17 +1,15 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * from: "667d60ac8a68186f43bafdbb", - * into: "667d60ac8a68186f43bafdbc" + * from: "6762f0d51bb69f9f2193bb7f", + * into: "6762f0d51bb69f9f2193bb80" * } */ export interface MergeContactsRequest { /** The unique identifier for the contact to merge away from. Must be a lead. */ - from: string; + from?: string; /** The unique identifier for the contact to merge into. Must be a user. */ - into: string; + into?: string; } diff --git a/src/api/resources/contacts/client/requests/ShowContactByExternalIdRequest.ts b/src/api/resources/contacts/client/requests/ShowContactByExternalIdRequest.ts new file mode 100644 index 00000000..d6f2b0d8 --- /dev/null +++ b/src/api/resources/contacts/client/requests/ShowContactByExternalIdRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * external_id: "cdd29344-5e0c-4ef0-ac56-f9ba2979bc27" + * } + */ +export interface ShowContactByExternalIdRequest { + /** The external ID of the user that you want to retrieve */ + external_id: string; +} diff --git a/src/api/resources/contacts/client/requests/UnarchiveContactRequest.ts b/src/api/resources/contacts/client/requests/UnarchiveContactRequest.ts index f014d7d2..76ecc8e1 100644 --- a/src/api/resources/contacts/client/requests/UnarchiveContactRequest.ts +++ b/src/api/resources/contacts/client/requests/UnarchiveContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface UnarchiveContactRequest { - /** - * id - */ + /** contact_id */ contact_id: string; } diff --git a/src/api/resources/contacts/client/requests/UpdateContactRequest.ts b/src/api/resources/contacts/client/requests/UpdateContactRequest.ts index 109178e2..3f048efd 100644 --- a/src/api/resources/contacts/client/requests/UpdateContactRequest.ts +++ b/src/api/resources/contacts/client/requests/UpdateContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,11 +7,19 @@ * email: "joebloggs@intercom.io", * name: "joe bloggs" * } + * + * @example + * { + * contact_id: "63a07ddf05a32042dffac965", + * custom_attributes: { + * "order": [ + * "21" + * ] + * } + * } */ export interface UpdateContactRequest { - /** - * id - */ + /** id */ contact_id: string; /** The role of the contact. */ role?: string; diff --git a/src/api/resources/contacts/client/requests/index.ts b/src/api/resources/contacts/client/requests/index.ts index 1e895632..60cacd37 100644 --- a/src/api/resources/contacts/client/requests/index.ts +++ b/src/api/resources/contacts/client/requests/index.ts @@ -1,13 +1,15 @@ -export { type ListAttachedCompaniesRequest } from "./ListAttachedCompaniesRequest"; -export { type ListSegmentsAttachedToContactRequest } from "./ListSegmentsAttachedToContactRequest"; -export { type ListAttachedSubscriptionsRequest } from "./ListAttachedSubscriptionsRequest"; -export { type AttachSubscriptionToContactRequest } from "./AttachSubscriptionToContactRequest"; -export { type DetachSubscriptionFromContactRequest } from "./DetachSubscriptionFromContactRequest"; -export { type ListTagsAttachedToContactRequest } from "./ListTagsAttachedToContactRequest"; -export { type FindContactRequest } from "./FindContactRequest"; -export { type UpdateContactRequest } from "./UpdateContactRequest"; -export { type DeleteContactRequest } from "./DeleteContactRequest"; -export { type MergeContactsRequest } from "./MergeContactsRequest"; -export { type ListContactsRequest } from "./ListContactsRequest"; -export { type ArchiveContactRequest } from "./ArchiveContactRequest"; -export { type UnarchiveContactRequest } from "./UnarchiveContactRequest"; +export type { ArchiveContactRequest } from "./ArchiveContactRequest.js"; +export type { AttachSubscriptionToContactRequest } from "./AttachSubscriptionToContactRequest.js"; +export type { BlockContactRequest } from "./BlockContactRequest.js"; +export type { DeleteContactRequest } from "./DeleteContactRequest.js"; +export type { DetachSubscriptionFromContactRequest } from "./DetachSubscriptionFromContactRequest.js"; +export type { FindContactRequest } from "./FindContactRequest.js"; +export type { ListAttachedCompaniesRequest } from "./ListAttachedCompaniesRequest.js"; +export type { ListAttachedSubscriptionsRequest } from "./ListAttachedSubscriptionsRequest.js"; +export type { ListContactsRequest } from "./ListContactsRequest.js"; +export type { ListSegmentsAttachedToContactRequest } from "./ListSegmentsAttachedToContactRequest.js"; +export type { ListTagsAttachedToContactRequest } from "./ListTagsAttachedToContactRequest.js"; +export type { MergeContactsRequest } from "./MergeContactsRequest.js"; +export type { ShowContactByExternalIdRequest } from "./ShowContactByExternalIdRequest.js"; +export type { UnarchiveContactRequest } from "./UnarchiveContactRequest.js"; +export type { UpdateContactRequest } from "./UpdateContactRequest.js"; diff --git a/src/api/resources/contacts/index.ts b/src/api/resources/contacts/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/contacts/index.ts +++ b/src/api/resources/contacts/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/contacts/types/Contact.ts b/src/api/resources/contacts/types/Contact.ts index a9bed2d3..7c6e6305 100644 --- a/src/api/resources/contacts/types/Contact.ts +++ b/src/api/resources/contacts/types/Contact.ts @@ -1,45 +1,41 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** - * Contact are the objects that represent your leads and users in Intercom. + * Contacts represent your leads and users in Intercom. */ export interface Contact { /** The type of object. */ type?: "contact"; /** The unique identifier for the contact which is given by Intercom. */ - id: string; + id?: string; /** The unique identifier for the contact which is provided by the Client. */ external_id?: string; /** The id of the workspace which the contact belongs to. */ - workspace_id: string; + workspace_id?: string; /** The role of the contact. */ - role: string; + role?: string; /** The contact's email. */ email?: string; /** The contact's email domain. */ email_domain?: string; /** The contacts phone. */ phone?: string; - /** The contacts phone number normalized to the E164 format */ - formatted_phone?: string; /** The contacts name. */ name?: string; /** The id of an admin that has been assigned account ownership of the contact. */ owner_id?: number; /** Whether the contact has had an email sent to them hard bounce. */ - has_hard_bounced: boolean; + has_hard_bounced?: boolean; /** Whether the contact has marked an email sent to them as spam. */ - marked_email_as_spam: boolean; + marked_email_as_spam?: boolean; /** Whether the contact is unsubscribed from emails. */ - unsubscribed_from_emails: boolean; + unsubscribed_from_emails?: boolean; /** (UNIX timestamp) The time when the contact was created. */ - created_at: number; + created_at?: number; /** (UNIX timestamp) The time when the contact was last updated. */ - updated_at: number; + updated_at?: number; /** (UNIX timestamp) The time specified for when a contact signed up. */ signed_up_at?: number; /** (UNIX timestamp) The time when the contact was last seen (either where the Intercom Messenger was installed or when specified manually). */ @@ -93,6 +89,6 @@ export interface Contact { tags?: Intercom.ContactTags; notes?: Intercom.ContactNotes; companies?: Intercom.ContactCompanies; - location: Intercom.ContactLocation; - social_profiles: Intercom.ContactSocialProfiles; + location?: Intercom.ContactLocation; + social_profiles?: Intercom.ContactSocialProfiles; } diff --git a/src/api/resources/contacts/types/ContactsCreateResponse.ts b/src/api/resources/contacts/types/ContactsCreateResponse.ts new file mode 100644 index 00000000..c124d661 --- /dev/null +++ b/src/api/resources/contacts/types/ContactsCreateResponse.ts @@ -0,0 +1,8 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +export interface ContactsCreateResponse extends Intercom.Contact { + /** If the user has enabled push messaging. */ + enabled_push_messaging?: boolean; +} diff --git a/src/api/resources/contacts/types/ContactsFindResponse.ts b/src/api/resources/contacts/types/ContactsFindResponse.ts new file mode 100644 index 00000000..96ff7ff5 --- /dev/null +++ b/src/api/resources/contacts/types/ContactsFindResponse.ts @@ -0,0 +1,8 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +export interface ContactsFindResponse extends Intercom.Contact { + /** If the user has enabled push messaging. */ + enabled_push_messaging?: boolean; +} diff --git a/src/api/resources/contacts/types/ContactsMergeLeadInUserResponse.ts b/src/api/resources/contacts/types/ContactsMergeLeadInUserResponse.ts new file mode 100644 index 00000000..95ca8cfb --- /dev/null +++ b/src/api/resources/contacts/types/ContactsMergeLeadInUserResponse.ts @@ -0,0 +1,8 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +export interface ContactsMergeLeadInUserResponse extends Intercom.Contact { + /** If the user has enabled push messaging. */ + enabled_push_messaging?: boolean; +} diff --git a/src/api/resources/contacts/types/ContactsUpdateResponse.ts b/src/api/resources/contacts/types/ContactsUpdateResponse.ts new file mode 100644 index 00000000..736895ee --- /dev/null +++ b/src/api/resources/contacts/types/ContactsUpdateResponse.ts @@ -0,0 +1,8 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +export interface ContactsUpdateResponse extends Intercom.Contact { + /** If the user has enabled push messaging. */ + enabled_push_messaging?: boolean; +} diff --git a/src/api/resources/contacts/types/ShowContactByExternalIdResponse.ts b/src/api/resources/contacts/types/ShowContactByExternalIdResponse.ts new file mode 100644 index 00000000..c6dbf5c1 --- /dev/null +++ b/src/api/resources/contacts/types/ShowContactByExternalIdResponse.ts @@ -0,0 +1,8 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +export interface ShowContactByExternalIdResponse extends Intercom.Contact { + /** If the user has enabled push messaging. */ + enabled_push_messaging?: boolean; +} diff --git a/src/api/resources/contacts/types/index.ts b/src/api/resources/contacts/types/index.ts index b538eafc..adc73bae 100644 --- a/src/api/resources/contacts/types/index.ts +++ b/src/api/resources/contacts/types/index.ts @@ -1 +1,6 @@ -export * from "./Contact"; +export * from "./Contact.js"; +export * from "./ContactsCreateResponse.js"; +export * from "./ContactsFindResponse.js"; +export * from "./ContactsMergeLeadInUserResponse.js"; +export * from "./ContactsUpdateResponse.js"; +export * from "./ShowContactByExternalIdResponse.js"; diff --git a/src/api/resources/conversations/client/Client.ts b/src/api/resources/conversations/client/Client.ts index d24ccbfd..af9f6fc0 100644 --- a/src/api/resources/conversations/client/Client.ts +++ b/src/api/resources/conversations/client/Client.ts @@ -1,79 +1,29 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace Conversations { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace ConversationsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Conversations */ -export class Conversations { - constructor(protected readonly _options: Conversations.Options = {}) {} +export class ConversationsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: ConversationsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of all conversations. @@ -85,62 +35,58 @@ export class Conversations { * {% /admonition %} * * @param {Intercom.ListConversationsRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.ForbiddenError} * * @example - * await client.conversations.list() + * await client.conversations.list({ + * per_page: 1, + * starting_after: "starting_after" + * }) */ public async list( request: Intercom.ListConversationsRequest = {}, - requestOptions?: Conversations.RequestOptions, - ): Promise> { + requestOptions?: ConversationsClient.RequestOptions, + ): Promise> { const list = core.HttpResponsePromise.interceptFunction( async ( request: Intercom.ListConversationsRequest, - ): Promise> => { + ): Promise> => { const { per_page: perPage, starting_after: startingAfter } = request; const _queryParams: Record = {}; if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); + _queryParams.per_page = perPage.toString(); } if (startingAfter != null) { - _queryParams["starting_after"] = startingAfter; + _queryParams.starting_after = startingAfter; } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "conversations", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: - requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { - data: _response.body as Intercom.PaginatedConversationResponse, - rawResponse: _response.rawResponse, - }; + return { data: _response.body as Intercom.ConversationList, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { @@ -162,28 +108,19 @@ export class Conversations { }); } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /conversations."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/conversations"); }, ); const dataWithRawResponse = await list(request).withRawResponse(); - return new core.Pageable({ + return new core.Page({ response: dataWithRawResponse.data, rawResponse: dataWithRawResponse.rawResponse, - hasNextPage: (response) => response?.pages?.next?.starting_after != null, + hasNextPage: (response) => + response?.pages?.next?.starting_after != null && + !( + typeof response?.pages?.next?.starting_after === "string" && + response?.pages?.next?.starting_after === "" + ), getItems: (response) => response?.conversations ?? [], loadPage: (response) => { return list(core.setObjectProperty(request, "starting_after", response?.pages?.next?.starting_after)); @@ -202,8 +139,9 @@ export class Conversations { * * This will return the Message model that has been created. * + * * @param {Intercom.CreateConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.ForbiddenError} @@ -213,7 +151,7 @@ export class Conversations { * await client.conversations.create({ * from: { * type: "user", - * id: "667d60d18a68186f43bafddd" + * id: "6762f11b1bb69f9f2193bba3" * }, * body: "Hello there" * }) @@ -229,40 +167,40 @@ export class Conversations { */ public create( request: Intercom.CreateConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( request: Intercom.CreateConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "conversations", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Message, rawResponse: _response.rawResponse }; @@ -288,21 +226,7 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/conversations"); } /** @@ -318,7 +242,7 @@ export class Conversations { * For AI agent conversation metadata, please note that you need to have the agent enabled in your workspace, which is a [paid feature](https://www.intercom.com/help/en/articles/8205718-fin-resolutions#h_97f8c2e671). * * @param {Intercom.FindConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.ForbiddenError} @@ -327,51 +251,57 @@ export class Conversations { * @example * await client.conversations.find({ * conversation_id: "123", - * display_as: "plaintext" + * display_as: "plaintext", + * include_translations: true * }) */ public find( request: Intercom.FindConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.FindConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { - const { conversation_id: conversationId, display_as: displayAs } = request; + const { + conversation_id: conversationId, + display_as: displayAs, + include_translations: includeTranslations, + } = request; const _queryParams: Record = {}; if (displayAs != null) { - _queryParams["display_as"] = displayAs; + _queryParams.display_as = displayAs; + } + + if (includeTranslations != null) { + _queryParams.include_translations = includeTranslations.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}`, + `conversations/${core.url.encodePathParam(conversationId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; @@ -397,23 +327,12 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /conversations/{conversation_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/conversations/{conversation_id}", + ); } /** @@ -424,8 +343,15 @@ export class Conversations { * If you want to reply to a coveration or take an action such as assign, unassign, open, close or snooze, take a look at the reply and manage endpoints. * {% /admonition %} * + * {% admonition type="info" %} + * This endpoint handles both **conversation updates** and **custom object associations**. + * + * See _`update a conversation with an association to a custom object instance`_ in the request/response examples to see the custom object association format. + * {% /admonition %} + * + * * @param {Intercom.UpdateConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.ForbiddenError} @@ -433,58 +359,67 @@ export class Conversations { * * @example * await client.conversations.update({ - * conversation_id: "123", + * conversation_id: "conversation_id", * display_as: "plaintext", * read: true, + * title: "new conversation title", * custom_attributes: { * "issue_type": "Billing", * "priority": "High" * } * }) + * + * @example + * await client.conversations.update({ + * conversation_id: "conversation_id", + * display_as: "plaintext", + * custom_attributes: { + * "order": {} + * } + * }) */ public update( request: Intercom.UpdateConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); } private async __update( request: Intercom.UpdateConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { const { conversation_id: conversationId, display_as: displayAs, ..._body } = request; const _queryParams: Record = {}; if (displayAs != null) { - _queryParams["display_as"] = displayAs; + _queryParams.display_as = displayAs; } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}`, + `conversations/${core.url.encodePathParam(conversationId)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", - queryParameters: _queryParams, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; @@ -510,23 +445,91 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /conversations/{conversation_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "PUT", + "/conversations/{conversation_id}", + ); + } + + /** + * You can delete a single conversation. + * + * @param {Intercom.DeleteConversationRequest} request + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.ForbiddenError} + * + * @example + * await client.conversations.deleteConversation({ + * conversation_id: 1 + * }) + */ + public deleteConversation( + request: Intercom.DeleteConversationRequest, + requestOptions?: ConversationsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteConversation(request, requestOptions)); + } + + private async __deleteConversation( + request: Intercom.DeleteConversationRequest, + requestOptions?: ConversationsClient.RequestOptions, + ): Promise> { + const { conversation_id: conversationId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${core.url.encodePathParam(conversationId)}`, + ), + method: "DELETE", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.ConversationDeleted, rawResponse: _response.rawResponse }; } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/conversations/{conversation_id}", + ); } /** @@ -551,7 +554,7 @@ export class Conversations { * * ### Accepted Fields * - * Most keys listed as part of the The conversation model is searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). + * Most keys listed in the conversation model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foorbar"`). * The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. * * | Field | Type | @@ -631,7 +634,7 @@ export class Conversations { * | $ | String | Ends With | * * @param {Intercom.SearchRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.conversations.search({ @@ -650,44 +653,38 @@ export class Conversations { */ public async search( request: Intercom.SearchRequest, - requestOptions?: Conversations.RequestOptions, - ): Promise> { + requestOptions?: ConversationsClient.RequestOptions, + ): Promise> { const list = core.HttpResponsePromise.interceptFunction( - async ( - request: Intercom.SearchRequest, - ): Promise> => { + async (request: Intercom.SearchRequest): Promise> => { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "conversations/search", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: - requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { - data: _response.body as Intercom.PaginatedConversationResponse, - rawResponse: _response.rawResponse, - }; + return { data: _response.body as Intercom.ConversationList, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { throw new errors.IntercomError({ @@ -696,30 +693,24 @@ export class Conversations { rawResponse: _response.rawResponse, }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/search.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/conversations/search", + ); }, ); const dataWithRawResponse = await list(request).withRawResponse(); - return new core.Pageable({ + return new core.Page({ response: dataWithRawResponse.data, rawResponse: dataWithRawResponse.rawResponse, - hasNextPage: (response) => response?.pages?.next?.starting_after != null, + hasNextPage: (response) => + response?.pages?.next?.starting_after != null && + !( + typeof response?.pages?.next?.starting_after === "string" && + response?.pages?.next?.starting_after === "" + ), getItems: (response) => response?.conversations ?? [], loadPage: (response) => { return list( @@ -733,7 +724,7 @@ export class Conversations { * You can reply to a conversation with a message from an admin or on behalf of a contact, or with a note for admins. * * @param {Intercom.ReplyToConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.ForbiddenError} @@ -746,7 +737,7 @@ export class Conversations { * message_type: "comment", * type: "user", * body: "Thanks again :)", - * intercom_user_id: "667d60f18a68186f43bafdf4" + * intercom_user_id: "6762f1571bb69f9f2193bbbb" * } * }) * @@ -765,10 +756,31 @@ export class Conversations { * await client.conversations.reply({ * conversation_id: "123 or \"last\"", * body: { + * message_type: "quick_reply", + * type: "admin", + * admin_id: "3156780", + * reply_options: [{ + * text: "Yes", + * uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb" + * }, { + * text: "No", + * uuid: "f4a98af1-be56-4948-a57e-e1a83f8484c6" + * }] + * } + * }) + * + * @example + * await client.conversations.reply({ + * conversation_id: "123 or \"last\"", + * body: { * message_type: "comment", * type: "user", - * body: "Thanks again :)", - * intercom_user_id: "667d60f78a68186f43bafdf7" + * body: "body", + * reply_options: [{ + * text: "Yes", + * uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb" + * }], + * intercom_user_id: "6762f1621bb69f9f2193bbbe" * } * }) * @@ -779,47 +791,47 @@ export class Conversations { * message_type: "comment", * type: "user", * body: "Thanks again :)", - * intercom_user_id: "667d60f98a68186f43bafdf8" + * intercom_user_id: "6762f1661bb69f9f2193bbbf" * } * }) */ public reply( request: Intercom.ReplyToConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__reply(request, requestOptions)); } private async __reply( request: Intercom.ReplyToConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { const { conversation_id: conversationId, body: _body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/reply`, + `conversations/${core.url.encodePathParam(conversationId)}/reply`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; @@ -845,23 +857,12 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{conversation_id}/reply.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/conversations/{conversation_id}/reply", + ); } /** @@ -872,7 +873,7 @@ export class Conversations { * - Assign a conversation to an admin and/or team. * * @param {Intercom.ManageConversationPartsRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.ForbiddenError} @@ -920,41 +921,41 @@ export class Conversations { */ public manage( request: Intercom.ManageConversationPartsRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__manage(request, requestOptions)); } private async __manage( request: Intercom.ManageConversationPartsRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { const { conversation_id: conversationId, body: _body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/parts`, + `conversations/${core.url.encodePathParam(conversationId)}/parts`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; @@ -980,124 +981,12 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{conversation_id}/parts.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - /** - * {% admonition type="danger" name="Deprecation of Run Assignment Rules" %} - * Run assignment rules is now deprecated in version 2.12 and future versions and will be permanently removed on December 31, 2026. After this date, any requests made to this endpoint will fail. - * {% /admonition %} - * You can let a conversation be automatically assigned following assignment rules. - * {% admonition type="warning" name="When using workflows" %} - * It is not possible to use this endpoint with Workflows. - * {% /admonition %} - * - * @param {Intercom.AutoAssignConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. - * - * @throws {@link Intercom.UnauthorizedError} - * @throws {@link Intercom.ForbiddenError} - * @throws {@link Intercom.NotFoundError} - * - * @example - * await client.conversations.runAssignmentRules({ - * conversation_id: "123" - * }) - */ - public runAssignmentRules( - request: Intercom.AutoAssignConversationRequest, - requestOptions?: Conversations.RequestOptions, - ): core.HttpResponsePromise { - return core.HttpResponsePromise.fromPromise(this.__runAssignmentRules(request, requestOptions)); - } - - private async __runAssignmentRules( - request: Intercom.AutoAssignConversationRequest, - requestOptions?: Conversations.RequestOptions, - ): Promise> { - const { conversation_id: conversationId } = request; - const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( - (await core.Supplier.get(this._options.baseUrl)) ?? - (await core.Supplier.get(this._options.environment)) ?? - environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/run_assignment_rules`, - ), - method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, - abortSignal: requestOptions?.abortSignal, - }); - if (_response.ok) { - return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; - } - - if (_response.error.reason === "status-code") { - switch (_response.error.statusCode) { - case 401: - throw new Intercom.UnauthorizedError( - _response.error.body as Intercom.Error_, - _response.rawResponse, - ); - case 403: - throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_, _response.rawResponse); - case 404: - throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); - default: - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.body, - rawResponse: _response.rawResponse, - }); - } - } - - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{conversation_id}/run_assignment_rules.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/conversations/{conversation_id}/parts", + ); } /** @@ -1107,8 +996,9 @@ export class Conversations { * If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. * {% /admonition %} * + * * @param {Intercom.AttachContactToConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.ForbiddenError} @@ -1119,7 +1009,7 @@ export class Conversations { * conversation_id: "123", * admin_id: "12345", * customer: { - * intercom_user_id: "667d61168a68186f43bafe0d" + * intercom_user_id: "6762f19b1bb69f9f2193bbd4" * } * }) * @@ -1128,47 +1018,47 @@ export class Conversations { * conversation_id: "123", * admin_id: "12345", * customer: { - * intercom_user_id: "667d61188a68186f43bafe0e" + * intercom_user_id: "6762f19e1bb69f9f2193bbd5" * } * }) */ public attachContactAsAdmin( request: Intercom.AttachContactToConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__attachContactAsAdmin(request, requestOptions)); } private async __attachContactAsAdmin( request: Intercom.AttachContactToConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { const { conversation_id: conversationId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/customers`, + `conversations/${core.url.encodePathParam(conversationId)}/customers`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; @@ -1194,23 +1084,12 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{conversation_id}/customers.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/conversations/{conversation_id}/customers", + ); } /** @@ -1220,8 +1099,9 @@ export class Conversations { * If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. * {% /admonition %} * + * * @param {Intercom.DetachContactFromConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.ForbiddenError} @@ -1237,41 +1117,41 @@ export class Conversations { */ public detachContactAsAdmin( request: Intercom.DetachContactFromConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__detachContactAsAdmin(request, requestOptions)); } private async __detachContactAsAdmin( request: Intercom.DetachContactFromConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { const { conversation_id: conversationId, contact_id: contactId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/customers/${encodeURIComponent(contactId)}`, + `conversations/${core.url.encodePathParam(conversationId)}/customers/${core.url.encodePathParam(contactId)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; @@ -1299,23 +1179,12 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /conversations/{conversation_id}/customers/{contact_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/conversations/{conversation_id}/customers/{contact_id}", + ); } /** @@ -1325,8 +1194,9 @@ export class Conversations { * If you are redacting a conversation part, it must have a `body`. If you are redacting a source message, it must have been created by a contact. We will return a `conversation_part_not_redactable` error if these criteria are not met. * {% /admonition %} * + * * @param {Intercom.RedactConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -1347,40 +1217,40 @@ export class Conversations { */ public redactConversationPart( request: Intercom.RedactConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__redactConversationPart(request, requestOptions)); } private async __redactConversationPart( request: Intercom.RedactConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "conversations/redact", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; @@ -1404,83 +1274,69 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations/redact."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/conversations/redact"); } /** * You can convert a conversation to a ticket. * * @param {Intercom.ConvertConversationToTicketRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.BadRequestError} * * @example * await client.conversations.convertToTicket({ - * conversation_id: "123", - * ticket_type_id: "79" + * conversation_id: 1, + * ticket_type_id: "53" * }) * * @example * await client.conversations.convertToTicket({ - * conversation_id: "123", - * ticket_type_id: "80" + * conversation_id: 1, + * ticket_type_id: "54" * }) */ public convertToTicket( request: Intercom.ConvertConversationToTicketRequest, - requestOptions?: Conversations.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: ConversationsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__convertToTicket(request, requestOptions)); } private async __convertToTicket( request: Intercom.ConvertConversationToTicketRequest, - requestOptions?: Conversations.RequestOptions, - ): Promise> { + requestOptions?: ConversationsClient.RequestOptions, + ): Promise> { const { conversation_id: conversationId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/convert`, + `conversations/${core.url.encodePathParam(conversationId)}/convert`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.Ticket, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.Ticket | undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -1496,34 +1352,99 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{conversation_id}/convert.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/conversations/{conversation_id}/convert", + ); + } + + /** + * {% admonition type="danger" name="Deprecation of Run Assignment Rules" %} + * Run assignment rules is now deprecated in version 2.12 and future versions and will be permanently removed on December 31, 2026. After this date, any requests made to this endpoint will fail. + * {% /admonition %} + * You can let a conversation be automatically assigned following assignment rules. + * {% admonition type="warning" name="When using workflows" %} + * It is not possible to use this endpoint with Workflows. + * {% /admonition %} + * + * @param {Intercom.AutoAssignConversationRequest} request + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.ForbiddenError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.conversations.runAssignmentRules({ + * conversation_id: "123" + * }) + */ + public runAssignmentRules( + request: Intercom.AutoAssignConversationRequest, + requestOptions?: ConversationsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__runAssignmentRules(request, requestOptions)); } - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); + private async __runAssignmentRules( + request: Intercom.AutoAssignConversationRequest, + requestOptions?: ConversationsClient.RequestOptions, + ): Promise> { + const { conversation_id: conversationId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${core.url.encodePathParam(conversationId)}/run_assignment_rules`, + ), + method: "POST", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.Conversation, rawResponse: _response.rawResponse }; } - return `Bearer ${bearer}`; + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.ForbiddenError(_response.error.body as Intercom.Error_, _response.rawResponse); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/conversations/{conversation_id}/run_assignment_rules", + ); } } diff --git a/src/api/resources/conversations/client/index.ts b/src/api/resources/conversations/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/conversations/client/index.ts +++ b/src/api/resources/conversations/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/conversations/client/requests/AttachContactToConversationRequest.ts b/src/api/resources/conversations/client/requests/AttachContactToConversationRequest.ts index 852c6c2f..26b7dd3a 100644 --- a/src/api/resources/conversations/client/requests/AttachContactToConversationRequest.ts +++ b/src/api/resources/conversations/client/requests/AttachContactToConversationRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../index"; +import type * as Intercom from "../../../../index.js"; /** * @example @@ -10,7 +8,7 @@ import * as Intercom from "../../../../index"; * conversation_id: "123", * admin_id: "12345", * customer: { - * intercom_user_id: "667d61168a68186f43bafe0d" + * intercom_user_id: "6762f19b1bb69f9f2193bbd4" * } * } * @@ -19,14 +17,12 @@ import * as Intercom from "../../../../index"; * conversation_id: "123", * admin_id: "12345", * customer: { - * intercom_user_id: "667d61188a68186f43bafe0e" + * intercom_user_id: "6762f19e1bb69f9f2193bbd5" * } * } */ export interface AttachContactToConversationRequest { - /** - * The identifier for the conversation as given by Intercom. - */ + /** The identifier for the conversation as given by Intercom. */ conversation_id: string; /** The `id` of the admin who is adding the new participant. */ admin_id?: string; diff --git a/src/api/resources/conversations/client/requests/AutoAssignConversationRequest.ts b/src/api/resources/conversations/client/requests/AutoAssignConversationRequest.ts index b5f6e0c6..a5a03bdc 100644 --- a/src/api/resources/conversations/client/requests/AutoAssignConversationRequest.ts +++ b/src/api/resources/conversations/client/requests/AutoAssignConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface AutoAssignConversationRequest { - /** - * The identifier for the conversation as given by Intercom. - */ + /** The identifier for the conversation as given by Intercom. */ conversation_id: string; } diff --git a/src/api/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts b/src/api/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts index ce9e3abc..c5593cee 100644 --- a/src/api/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts +++ b/src/api/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts @@ -1,27 +1,23 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../index"; +import type * as Intercom from "../../../../index.js"; /** * @example * { - * conversation_id: "123", - * ticket_type_id: "79" + * conversation_id: 1, + * ticket_type_id: "53" * } * * @example * { - * conversation_id: "123", - * ticket_type_id: "80" + * conversation_id: 1, + * ticket_type_id: "54" * } */ export interface ConvertConversationToTicketRequest { - /** - * The id of the conversation to target - */ - conversation_id: string; + /** The id of the conversation to target */ + conversation_id: number; /** The ID of the type of ticket you want to convert the conversation to */ ticket_type_id: string; attributes?: Intercom.TicketRequestCustomAttributes; diff --git a/src/api/resources/conversations/client/requests/CreateConversationRequest.ts b/src/api/resources/conversations/client/requests/CreateConversationRequest.ts index 4c82a814..0f8bcd9a 100644 --- a/src/api/resources/conversations/client/requests/CreateConversationRequest.ts +++ b/src/api/resources/conversations/client/requests/CreateConversationRequest.ts @@ -1,13 +1,11 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { * from: { * type: "user", - * id: "667d60d18a68186f43bafddd" + * id: "6762f11b1bb69f9f2193bba3" * }, * body: "Hello there" * } @@ -38,14 +36,12 @@ export namespace CreateConversationRequest { } export namespace From { - /** - * The role associated to the contact - user or lead. - */ - export type Type = "lead" | "user" | "contact"; + /** The role associated to the contact - user or lead. */ export const Type = { Lead: "lead", User: "user", Contact: "contact", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } } diff --git a/src/api/resources/conversations/client/requests/DeleteConversationRequest.ts b/src/api/resources/conversations/client/requests/DeleteConversationRequest.ts new file mode 100644 index 00000000..a5bf5e64 --- /dev/null +++ b/src/api/resources/conversations/client/requests/DeleteConversationRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * conversation_id: 1 + * } + */ +export interface DeleteConversationRequest { + /** id */ + conversation_id: number; +} diff --git a/src/api/resources/conversations/client/requests/DetachContactFromConversationRequest.ts b/src/api/resources/conversations/client/requests/DetachContactFromConversationRequest.ts index e245b23d..415bfae9 100644 --- a/src/api/resources/conversations/client/requests/DetachContactFromConversationRequest.ts +++ b/src/api/resources/conversations/client/requests/DetachContactFromConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -32,13 +30,9 @@ * } */ export interface DetachContactFromConversationRequest { - /** - * The identifier for the conversation as given by Intercom. - */ + /** The identifier for the conversation as given by Intercom. */ conversation_id: string; - /** - * The identifier for the contact as given by Intercom. - */ + /** The identifier for the contact as given by Intercom. */ contact_id: string; /** The `id` of the admin who is performing the action. */ admin_id: string; diff --git a/src/api/resources/conversations/client/requests/FindConversationRequest.ts b/src/api/resources/conversations/client/requests/FindConversationRequest.ts index 094cfa53..c80a7032 100644 --- a/src/api/resources/conversations/client/requests/FindConversationRequest.ts +++ b/src/api/resources/conversations/client/requests/FindConversationRequest.ts @@ -1,21 +1,18 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { * conversation_id: "123", - * display_as: "plaintext" + * display_as: "plaintext", + * include_translations: true * } */ export interface FindConversationRequest { - /** - * The id of the conversation to target - */ + /** The id of the conversation to target */ conversation_id: string; - /** - * Set to plaintext to retrieve conversation messages in plain text. - */ + /** Set to plaintext to retrieve conversation messages in plain text. */ display_as?: string; + /** If set to true, conversation parts will be translated to the detected language of the conversation. */ + include_translations?: boolean; } diff --git a/src/api/resources/conversations/client/requests/ListConversationsRequest.ts b/src/api/resources/conversations/client/requests/ListConversationsRequest.ts index f3c7f741..4908f563 100644 --- a/src/api/resources/conversations/client/requests/ListConversationsRequest.ts +++ b/src/api/resources/conversations/client/requests/ListConversationsRequest.ts @@ -1,18 +1,15 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example - * {} + * { + * per_page: 1, + * starting_after: "starting_after" + * } */ export interface ListConversationsRequest { - /** - * How many results per page - */ + /** How many results per page */ per_page?: number; - /** - * String used to get the next page of conversations. - */ + /** String used to get the next page of conversations. */ starting_after?: string; } diff --git a/src/api/resources/conversations/client/requests/ManageConversationPartsRequest.ts b/src/api/resources/conversations/client/requests/ManageConversationPartsRequest.ts index 48c245e7..a16fe3ec 100644 --- a/src/api/resources/conversations/client/requests/ManageConversationPartsRequest.ts +++ b/src/api/resources/conversations/client/requests/ManageConversationPartsRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../index"; +import type * as Intercom from "../../../../index.js"; /** * @example @@ -56,9 +54,7 @@ import * as Intercom from "../../../../index"; * } */ export interface ManageConversationPartsRequest { - /** - * The identifier for the conversation as given by Intercom. - */ + /** The identifier for the conversation as given by Intercom. */ conversation_id: string; body: Intercom.ConversationsManageRequestBody; } diff --git a/src/api/resources/conversations/client/requests/ReplyToConversationRequest.ts b/src/api/resources/conversations/client/requests/ReplyToConversationRequest.ts index e9ae5970..9ef917d8 100644 --- a/src/api/resources/conversations/client/requests/ReplyToConversationRequest.ts +++ b/src/api/resources/conversations/client/requests/ReplyToConversationRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../index"; +import type * as Intercom from "../../../../index.js"; /** * @example @@ -12,7 +10,7 @@ import * as Intercom from "../../../../index"; * message_type: "comment", * type: "user", * body: "Thanks again :)", - * intercom_user_id: "667d60f18a68186f43bafdf4" + * intercom_user_id: "6762f1571bb69f9f2193bbbb" * } * } * @@ -31,10 +29,31 @@ import * as Intercom from "../../../../index"; * { * conversation_id: "123 or \"last\"", * body: { + * message_type: "quick_reply", + * type: "admin", + * admin_id: "3156780", + * reply_options: [{ + * text: "Yes", + * uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb" + * }, { + * text: "No", + * uuid: "f4a98af1-be56-4948-a57e-e1a83f8484c6" + * }] + * } + * } + * + * @example + * { + * conversation_id: "123 or \"last\"", + * body: { * message_type: "comment", * type: "user", - * body: "Thanks again :)", - * intercom_user_id: "667d60f78a68186f43bafdf7" + * body: "body", + * reply_options: [{ + * text: "Yes", + * uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb" + * }], + * intercom_user_id: "6762f1621bb69f9f2193bbbe" * } * } * @@ -45,7 +64,7 @@ import * as Intercom from "../../../../index"; * message_type: "comment", * type: "user", * body: "Thanks again :)", - * intercom_user_id: "667d60f98a68186f43bafdf8" + * intercom_user_id: "6762f1661bb69f9f2193bbbf" * } * } * @@ -56,7 +75,7 @@ import * as Intercom from "../../../../index"; * message_type: "comment", * type: "user", * body: "Thanks again :)", - * intercom_user_id: "667d60f18a68186f43bafdf4" + * intercom_user_id: "6762f1571bb69f9f2193bbbb" * } * } * @@ -67,7 +86,7 @@ import * as Intercom from "../../../../index"; * message_type: "comment", * type: "user", * body: "Thanks again :)", - * intercom_user_id: "667d60f18a68186f43bafdf4" + * intercom_user_id: "6762f1571bb69f9f2193bbbb" * } * } * @@ -78,14 +97,12 @@ import * as Intercom from "../../../../index"; * message_type: "comment", * type: "user", * body: "Thanks again :)", - * intercom_user_id: "667d60f18a68186f43bafdf4" + * intercom_user_id: "6762f1571bb69f9f2193bbbb" * } * } */ export interface ReplyToConversationRequest { - /** - * The Intercom provisioned identifier for the conversation or the string "last" to reply to the last part of the conversation - */ + /** The Intercom provisioned identifier for the conversation or the string "last" to reply to the last part of the conversation */ conversation_id: string; body: Intercom.ReplyConversationRequest; } diff --git a/src/api/resources/conversations/client/requests/UpdateConversationRequest.ts b/src/api/resources/conversations/client/requests/UpdateConversationRequest.ts index 0590a00c..164ecefe 100644 --- a/src/api/resources/conversations/client/requests/UpdateConversationRequest.ts +++ b/src/api/resources/conversations/client/requests/UpdateConversationRequest.ts @@ -1,15 +1,14 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../index"; +import type * as Intercom from "../../../../index.js"; /** * @example * { - * conversation_id: "123", + * conversation_id: "conversation_id", * display_as: "plaintext", * read: true, + * title: "new conversation title", * custom_attributes: { * "issue_type": "Billing", * "priority": "High" @@ -18,9 +17,19 @@ import * as Intercom from "../../../../index"; * * @example * { - * conversation_id: "123", + * conversation_id: "conversation_id", + * display_as: "plaintext", + * custom_attributes: { + * "order": {} + * } + * } + * + * @example + * { + * conversation_id: "conversation_id", * display_as: "plaintext", * read: true, + * title: "new conversation title", * custom_attributes: { * "issue_type": "Billing", * "priority": "High" @@ -28,15 +37,15 @@ import * as Intercom from "../../../../index"; * } */ export interface UpdateConversationRequest { - /** - * The id of the conversation to target - */ + /** The id of the conversation to target */ conversation_id: string; - /** - * Set to plaintext to retrieve conversation messages in plain text. - */ + /** Set to plaintext to retrieve conversation messages in plain text. */ display_as?: string; /** Mark a conversation as read within Intercom. */ read?: boolean; + /** The title given to the conversation */ + title?: string; custom_attributes?: Intercom.CustomAttributes; + /** The ID of the company that the conversation is associated with. The unique identifier for the company which is given by Intercom. Set to nil to remove company. */ + company_id?: string; } diff --git a/src/api/resources/conversations/client/requests/index.ts b/src/api/resources/conversations/client/requests/index.ts index fa317731..dbe79ca7 100644 --- a/src/api/resources/conversations/client/requests/index.ts +++ b/src/api/resources/conversations/client/requests/index.ts @@ -1,10 +1,11 @@ -export { type ListConversationsRequest } from "./ListConversationsRequest"; -export { type CreateConversationRequest } from "./CreateConversationRequest"; -export { type FindConversationRequest } from "./FindConversationRequest"; -export { type UpdateConversationRequest } from "./UpdateConversationRequest"; -export { type ReplyToConversationRequest } from "./ReplyToConversationRequest"; -export { type ManageConversationPartsRequest } from "./ManageConversationPartsRequest"; -export { type AutoAssignConversationRequest } from "./AutoAssignConversationRequest"; -export { type AttachContactToConversationRequest } from "./AttachContactToConversationRequest"; -export { type DetachContactFromConversationRequest } from "./DetachContactFromConversationRequest"; -export { type ConvertConversationToTicketRequest } from "./ConvertConversationToTicketRequest"; +export type { AttachContactToConversationRequest } from "./AttachContactToConversationRequest.js"; +export type { AutoAssignConversationRequest } from "./AutoAssignConversationRequest.js"; +export type { ConvertConversationToTicketRequest } from "./ConvertConversationToTicketRequest.js"; +export type { CreateConversationRequest } from "./CreateConversationRequest.js"; +export type { DeleteConversationRequest } from "./DeleteConversationRequest.js"; +export type { DetachContactFromConversationRequest } from "./DetachContactFromConversationRequest.js"; +export type { FindConversationRequest } from "./FindConversationRequest.js"; +export type { ListConversationsRequest } from "./ListConversationsRequest.js"; +export type { ManageConversationPartsRequest } from "./ManageConversationPartsRequest.js"; +export type { ReplyToConversationRequest } from "./ReplyToConversationRequest.js"; +export type { UpdateConversationRequest } from "./UpdateConversationRequest.js"; diff --git a/src/api/resources/conversations/index.ts b/src/api/resources/conversations/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/conversations/index.ts +++ b/src/api/resources/conversations/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/conversations/types/Conversation.ts b/src/api/resources/conversations/types/Conversation.ts index 3e08c1b6..95606d03 100644 --- a/src/api/resources/conversations/types/Conversation.ts +++ b/src/api/resources/conversations/types/Conversation.ts @@ -1,45 +1,45 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Conversations are how you can communicate with users in Intercom. They are created when a contact replies to an outbound message, or when one admin directly sends a message to a single contact. */ export interface Conversation { /** Always conversation. */ - type?: "conversation"; + type?: string; /** The id representing the conversation. */ - id: string; + id?: string; /** The title given to the conversation. */ title?: string; /** The time the conversation was created. */ - created_at: number; + created_at?: number; /** The last time the conversation was updated. */ - updated_at: number; + updated_at?: number; /** The last time a Contact responded to an Admin. In other words, the time a customer started waiting for a response. Set to null if last reply is from an Admin. */ waiting_since?: number; /** If set this is the time in the future when this conversation will be marked as open. i.e. it will be in a snoozed state until this time. i.e. it will be in a snoozed state until this time. */ snoozed_until?: number; /** Indicates whether a conversation is open (true) or closed (false). */ - open: boolean; + open?: boolean; /** Can be set to "open", "closed" or "snoozed". */ - state: Conversation.State; + state?: Conversation.State; /** Indicates whether a conversation has been read. */ - read: boolean; + read?: boolean; /** If marked as priority, it will return priority or else not_priority. */ priority?: Conversation.Priority; /** The id of the admin assigned to the conversation. If it's not assigned to an admin it will return null. */ admin_assignee_id?: number; /** The id of the team assigned to the conversation. If it's not assigned to a team it will return null. */ team_assignee_id?: string; + /** The ID of the company that the conversation is associated with. The unique identifier for the company which is given by Intercom. */ + company_id?: string; tags?: Intercom.Tags; conversation_rating?: Intercom.ConversationRating; - source: Intercom.ConversationSource; - contacts: Intercom.ConversationContacts; - teammates: Intercom.ConversationTeammates; - custom_attributes: Intercom.CustomAttributes; + source?: Intercom.ConversationSource; + contacts?: Intercom.ConversationContacts; + teammates?: Intercom.ConversationTeammates; + custom_attributes?: Intercom.CustomAttributes; first_contact_reply?: Intercom.ConversationFirstContactReply; sla_applied?: Intercom.SlaApplied; statistics?: Intercom.ConversationStatistics; @@ -51,21 +51,17 @@ export interface Conversation { } export namespace Conversation { - /** - * Can be set to "open", "closed" or "snoozed". - */ - export type State = "open" | "closed" | "snoozed"; + /** Can be set to "open", "closed" or "snoozed". */ export const State = { Open: "open", Closed: "closed", Snoozed: "snoozed", } as const; - /** - * If marked as priority, it will return priority or else not_priority. - */ - export type Priority = "priority" | "not_priority"; + export type State = (typeof State)[keyof typeof State]; + /** If marked as priority, it will return priority or else not_priority. */ export const Priority = { Priority: "priority", NotPriority: "not_priority", } as const; + export type Priority = (typeof Priority)[keyof typeof Priority]; } diff --git a/src/api/resources/conversations/types/ConversationsManageRequestBody.ts b/src/api/resources/conversations/types/ConversationsManageRequestBody.ts index 232eb1e2..7a8ef883 100644 --- a/src/api/resources/conversations/types/ConversationsManageRequestBody.ts +++ b/src/api/resources/conversations/types/ConversationsManageRequestBody.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; export type ConversationsManageRequestBody = | Intercom.ConversationsManageRequestBody.Close diff --git a/src/api/resources/conversations/types/index.ts b/src/api/resources/conversations/types/index.ts index 7ff13377..062aeafd 100644 --- a/src/api/resources/conversations/types/index.ts +++ b/src/api/resources/conversations/types/index.ts @@ -1,2 +1,2 @@ -export * from "./ConversationsManageRequestBody"; -export * from "./Conversation"; +export * from "./Conversation.js"; +export * from "./ConversationsManageRequestBody.js"; diff --git a/src/api/resources/customChannelEvents/client/Client.ts b/src/api/resources/customChannelEvents/client/Client.ts new file mode 100644 index 00000000..4ba0127c --- /dev/null +++ b/src/api/resources/customChannelEvents/client/Client.ts @@ -0,0 +1,423 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; + +export declare namespace CustomChannelEventsClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * With the "Custom Channel" integration, you can bring Fin and Intercom capabilities to your own platform via API, enabling powerful custom integrations. + * + * Intercom treats your integration like any other Intercom channel, allowing your application and Intercom to exchange events seamlessly. This makes it possible, for example, for your users to interact with Fin directly within your own application’s UI. + * + * > **Note:** "Fin over API" is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support. + */ +export class CustomChannelEventsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: CustomChannelEventsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * Notifies Intercom that a new conversation was created in your custom channel/platform. This triggers conversation creation and workflow automations within Intercom for your custom channel integration. + * > **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support. + * + * @param {Intercom.CustomChannelBaseEvent} request + * @param {CustomChannelEventsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * @throws {@link Intercom.UnprocessableEntityError} + * + * @example + * await client.customChannelEvents.notifyNewConversation({ + * event_id: "event_id", + * external_conversation_id: "external_conversation_id", + * contact: { + * type: "user", + * external_id: "external_id" + * } + * }) + */ + public notifyNewConversation( + request: Intercom.CustomChannelBaseEvent, + requestOptions?: CustomChannelEventsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__notifyNewConversation(request, requestOptions)); + } + + private async __notifyNewConversation( + request: Intercom.CustomChannelBaseEvent, + requestOptions?: CustomChannelEventsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "custom_channel_events/notify_new_conversation", + ), + method: "POST", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: request, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.CustomChannelNotificationResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + case 422: + throw new Intercom.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/custom_channel_events/notify_new_conversation", + ); + } + + /** + * Notifies Intercom that a new message was sent in a conversation on your custom channel/platform. This allows Intercom to process the message and trigger any relevant workflow automations. + * > **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support. + * + * @param {Intercom.NotifyNewMessageRequest} request + * @param {CustomChannelEventsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * @throws {@link Intercom.UnprocessableEntityError} + * + * @example + * await client.customChannelEvents.notifyNewMessage({ + * body: "body", + * event_id: "event_id", + * external_conversation_id: "external_conversation_id", + * contact: { + * type: "user", + * external_id: "external_id" + * } + * }) + */ + public notifyNewMessage( + request: Intercom.NotifyNewMessageRequest, + requestOptions?: CustomChannelEventsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__notifyNewMessage(request, requestOptions)); + } + + private async __notifyNewMessage( + request: Intercom.NotifyNewMessageRequest, + requestOptions?: CustomChannelEventsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "custom_channel_events/notify_new_message", + ), + method: "POST", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: request, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.CustomChannelNotificationResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + case 422: + throw new Intercom.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/custom_channel_events/notify_new_message", + ); + } + + /** + * Notifies Intercom that a user selected a quick reply option in your custom channel/platform. This allows Intercom to process the response and trigger any relevant workflow automations. + * > **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support. + * + * @param {Intercom.NotifyQuickReplySelectedRequest} request + * @param {CustomChannelEventsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * @throws {@link Intercom.UnprocessableEntityError} + * + * @example + * await client.customChannelEvents.notifyQuickReplySelected({ + * event_id: "evt_67890", + * external_conversation_id: "conv_13579", + * contact: { + * type: "user", + * external_id: "user_003", + * name: "Alice Example", + * email: "alice@example.com" + * }, + * quick_reply_option_id: "1234" + * }) + */ + public notifyQuickReplySelected( + request: Intercom.NotifyQuickReplySelectedRequest, + requestOptions?: CustomChannelEventsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__notifyQuickReplySelected(request, requestOptions)); + } + + private async __notifyQuickReplySelected( + request: Intercom.NotifyQuickReplySelectedRequest, + requestOptions?: CustomChannelEventsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "custom_channel_events/notify_quick_reply_selected", + ), + method: "POST", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: request, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.CustomChannelNotificationResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + case 422: + throw new Intercom.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/custom_channel_events/notify_quick_reply_selected", + ); + } + + /** + * Notifies Intercom that a user provided a response to an attribute collector in your custom channel/platform. This allows Intercom to process the attribute and trigger any relevant workflow automations. + * > **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support. + * + * @param {Intercom.NotifyAttributeCollectedRequest} request + * @param {CustomChannelEventsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * @throws {@link Intercom.UnprocessableEntityError} + * + * @example + * await client.customChannelEvents.notifyAttributeCollected({ + * attribute: { + * id: "id", + * value: "value" + * }, + * event_id: "event_id", + * external_conversation_id: "external_conversation_id", + * contact: { + * type: "user", + * external_id: "external_id" + * } + * }) + */ + public notifyAttributeCollected( + request: Intercom.NotifyAttributeCollectedRequest, + requestOptions?: CustomChannelEventsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__notifyAttributeCollected(request, requestOptions)); + } + + private async __notifyAttributeCollected( + request: Intercom.NotifyAttributeCollectedRequest, + requestOptions?: CustomChannelEventsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "custom_channel_events/notify_attribute_collected", + ), + method: "POST", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: request, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.CustomChannelNotificationResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + case 422: + throw new Intercom.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/custom_channel_events/notify_attribute_collected", + ); + } +} diff --git a/src/api/resources/customChannelEvents/client/index.ts b/src/api/resources/customChannelEvents/client/index.ts new file mode 100644 index 00000000..195f9aa8 --- /dev/null +++ b/src/api/resources/customChannelEvents/client/index.ts @@ -0,0 +1 @@ +export * from "./requests/index.js"; diff --git a/src/api/resources/customChannelEvents/client/requests/NotifyAttributeCollectedRequest.ts b/src/api/resources/customChannelEvents/client/requests/NotifyAttributeCollectedRequest.ts new file mode 100644 index 00000000..a4a040d9 --- /dev/null +++ b/src/api/resources/customChannelEvents/client/requests/NotifyAttributeCollectedRequest.ts @@ -0,0 +1,22 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../index.js"; + +/** + * @example + * { + * attribute: { + * id: "id", + * value: "value" + * }, + * event_id: "event_id", + * external_conversation_id: "external_conversation_id", + * contact: { + * type: "user", + * external_id: "external_id" + * } + * } + */ +export interface NotifyAttributeCollectedRequest extends Intercom.CustomChannelBaseEvent { + attribute: Intercom.CustomChannelAttribute; +} diff --git a/src/api/resources/customChannelEvents/client/requests/NotifyNewMessageRequest.ts b/src/api/resources/customChannelEvents/client/requests/NotifyNewMessageRequest.ts new file mode 100644 index 00000000..7f6483df --- /dev/null +++ b/src/api/resources/customChannelEvents/client/requests/NotifyNewMessageRequest.ts @@ -0,0 +1,20 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../index.js"; + +/** + * @example + * { + * body: "body", + * event_id: "event_id", + * external_conversation_id: "external_conversation_id", + * contact: { + * type: "user", + * external_id: "external_id" + * } + * } + */ +export interface NotifyNewMessageRequest extends Intercom.CustomChannelBaseEvent { + /** The message content sent by the user. */ + body: string; +} diff --git a/src/api/resources/customChannelEvents/client/requests/NotifyQuickReplySelectedRequest.ts b/src/api/resources/customChannelEvents/client/requests/NotifyQuickReplySelectedRequest.ts new file mode 100644 index 00000000..e6cec3d9 --- /dev/null +++ b/src/api/resources/customChannelEvents/client/requests/NotifyQuickReplySelectedRequest.ts @@ -0,0 +1,22 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../index.js"; + +/** + * @example + * { + * event_id: "evt_67890", + * external_conversation_id: "conv_13579", + * contact: { + * type: "user", + * external_id: "user_003", + * name: "Alice Example", + * email: "alice@example.com" + * }, + * quick_reply_option_id: "1234" + * } + */ +export interface NotifyQuickReplySelectedRequest extends Intercom.CustomChannelBaseEvent { + /** Id of the selected quick reply option. */ + quick_reply_option_id: string; +} diff --git a/src/api/resources/customChannelEvents/client/requests/index.ts b/src/api/resources/customChannelEvents/client/requests/index.ts new file mode 100644 index 00000000..702922d9 --- /dev/null +++ b/src/api/resources/customChannelEvents/client/requests/index.ts @@ -0,0 +1,3 @@ +export type { NotifyAttributeCollectedRequest } from "./NotifyAttributeCollectedRequest.js"; +export type { NotifyNewMessageRequest } from "./NotifyNewMessageRequest.js"; +export type { NotifyQuickReplySelectedRequest } from "./NotifyQuickReplySelectedRequest.js"; diff --git a/src/api/resources/customChannelEvents/index.ts b/src/api/resources/customChannelEvents/index.ts new file mode 100644 index 00000000..914b8c3c --- /dev/null +++ b/src/api/resources/customChannelEvents/index.ts @@ -0,0 +1 @@ +export * from "./client/index.js"; diff --git a/src/api/resources/customObjectInstances/client/Client.ts b/src/api/resources/customObjectInstances/client/Client.ts new file mode 100644 index 00000000..0ae03367 --- /dev/null +++ b/src/api/resources/customObjectInstances/client/Client.ts @@ -0,0 +1,462 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; + +export declare namespace CustomObjectInstancesClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * Everything about your Custom Object instances. + * {% admonition type="warning" name="Permission Requirements" %} + * From now on, to access this endpoint, you need additional permissions. Please head over to the [Developer Hub](https://app.intercom.com/a/apps/_/developer-hub) app package authentication settings to configure the required permissions. + * {% /admonition %} + */ +export class CustomObjectInstancesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: CustomObjectInstancesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * Fetch a Custom Object Instance by external_id. + * + * @param {Intercom.GetCustomObjectInstancesByExternalIdRequest} request + * @param {CustomObjectInstancesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.customObjectInstances.getCustomObjectInstancesByExternalId({ + * custom_object_type_identifier: "Order", + * external_id: "external_id" + * }) + */ + public getCustomObjectInstancesByExternalId( + request: Intercom.GetCustomObjectInstancesByExternalIdRequest, + requestOptions?: CustomObjectInstancesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise( + this.__getCustomObjectInstancesByExternalId(request, requestOptions), + ); + } + + private async __getCustomObjectInstancesByExternalId( + request: Intercom.GetCustomObjectInstancesByExternalIdRequest, + requestOptions?: CustomObjectInstancesClient.RequestOptions, + ): Promise> { + const { custom_object_type_identifier: customObjectTypeIdentifier, external_id: externalId } = request; + const _queryParams: Record = {}; + _queryParams.external_id = externalId; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `custom_object_instances/${core.url.encodePathParam(customObjectTypeIdentifier)}`, + ), + method: "GET", + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.CustomObjectInstance | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/custom_object_instances/{custom_object_type_identifier}", + ); + } + + /** + * Create or update a custom object instance + * + * @param {Intercom.CreateOrUpdateCustomObjectInstanceRequest} request + * @param {CustomObjectInstancesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.customObjectInstances.createCustomObjectInstances({ + * custom_object_type_identifier: "Order", + * external_id: "123", + * external_created_at: 1392036272, + * external_updated_at: 1392036272, + * custom_attributes: { + * "order_number": "ORDER-12345", + * "total_amount": "custom_attributes" + * } + * }) + */ + public createCustomObjectInstances( + request: Intercom.CreateOrUpdateCustomObjectInstanceRequest, + requestOptions?: CustomObjectInstancesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createCustomObjectInstances(request, requestOptions)); + } + + private async __createCustomObjectInstances( + request: Intercom.CreateOrUpdateCustomObjectInstanceRequest, + requestOptions?: CustomObjectInstancesClient.RequestOptions, + ): Promise> { + const { custom_object_type_identifier: customObjectTypeIdentifier, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `custom_object_instances/${core.url.encodePathParam(customObjectTypeIdentifier)}`, + ), + method: "POST", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: _body, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.CustomObjectInstance | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/custom_object_instances/{custom_object_type_identifier}", + ); + } + + /** + * Delete a single Custom Object instance by external_id. + * + * @param {Intercom.DeleteCustomObjectInstancesByIdRequest} request + * @param {CustomObjectInstancesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.customObjectInstances.deleteCustomObjectInstancesById({ + * custom_object_type_identifier: "Order", + * external_id: "external_id" + * }) + */ + public deleteCustomObjectInstancesById( + request: Intercom.DeleteCustomObjectInstancesByIdRequest, + requestOptions?: CustomObjectInstancesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteCustomObjectInstancesById(request, requestOptions)); + } + + private async __deleteCustomObjectInstancesById( + request: Intercom.DeleteCustomObjectInstancesByIdRequest, + requestOptions?: CustomObjectInstancesClient.RequestOptions, + ): Promise> { + const { custom_object_type_identifier: customObjectTypeIdentifier, external_id: externalId } = request; + const _queryParams: Record = {}; + _queryParams.external_id = externalId; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `custom_object_instances/${core.url.encodePathParam(customObjectTypeIdentifier)}`, + ), + method: "DELETE", + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.CustomObjectInstanceDeleted, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/custom_object_instances/{custom_object_type_identifier}", + ); + } + + /** + * Fetch a Custom Object Instance by id. + * + * @param {Intercom.GetCustomObjectInstancesByIdRequest} request + * @param {CustomObjectInstancesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.customObjectInstances.getCustomObjectInstancesById({ + * custom_object_type_identifier: "Order", + * custom_object_instance_id: "custom_object_instance_id" + * }) + */ + public getCustomObjectInstancesById( + request: Intercom.GetCustomObjectInstancesByIdRequest, + requestOptions?: CustomObjectInstancesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__getCustomObjectInstancesById(request, requestOptions)); + } + + private async __getCustomObjectInstancesById( + request: Intercom.GetCustomObjectInstancesByIdRequest, + requestOptions?: CustomObjectInstancesClient.RequestOptions, + ): Promise> { + const { + custom_object_type_identifier: customObjectTypeIdentifier, + custom_object_instance_id: customObjectInstanceId, + } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `custom_object_instances/${core.url.encodePathParam(customObjectTypeIdentifier)}/${core.url.encodePathParam(customObjectInstanceId)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.CustomObjectInstance | undefined, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/custom_object_instances/{custom_object_type_identifier}/{custom_object_instance_id}", + ); + } + + /** + * Delete a single Custom Object instance using the Intercom defined id. + * + * @param {Intercom.DeleteCustomObjectInstancesByExternalIdRequest} request + * @param {CustomObjectInstancesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.customObjectInstances.deleteCustomObjectInstancesByExternalId({ + * custom_object_type_identifier: "Order", + * custom_object_instance_id: "custom_object_instance_id" + * }) + */ + public deleteCustomObjectInstancesByExternalId( + request: Intercom.DeleteCustomObjectInstancesByExternalIdRequest, + requestOptions?: CustomObjectInstancesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise( + this.__deleteCustomObjectInstancesByExternalId(request, requestOptions), + ); + } + + private async __deleteCustomObjectInstancesByExternalId( + request: Intercom.DeleteCustomObjectInstancesByExternalIdRequest, + requestOptions?: CustomObjectInstancesClient.RequestOptions, + ): Promise> { + const { + custom_object_type_identifier: customObjectTypeIdentifier, + custom_object_instance_id: customObjectInstanceId, + } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `custom_object_instances/${core.url.encodePathParam(customObjectTypeIdentifier)}/${core.url.encodePathParam(customObjectInstanceId)}`, + ), + method: "DELETE", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.CustomObjectInstanceDeleted, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/custom_object_instances/{custom_object_type_identifier}/{custom_object_instance_id}", + ); + } +} diff --git a/src/api/resources/customObjectInstances/client/index.ts b/src/api/resources/customObjectInstances/client/index.ts new file mode 100644 index 00000000..195f9aa8 --- /dev/null +++ b/src/api/resources/customObjectInstances/client/index.ts @@ -0,0 +1 @@ +export * from "./requests/index.js"; diff --git a/src/api/resources/customObjectInstances/client/requests/CreateOrUpdateCustomObjectInstanceRequest.ts b/src/api/resources/customObjectInstances/client/requests/CreateOrUpdateCustomObjectInstanceRequest.ts new file mode 100644 index 00000000..97fa7ad7 --- /dev/null +++ b/src/api/resources/customObjectInstances/client/requests/CreateOrUpdateCustomObjectInstanceRequest.ts @@ -0,0 +1,27 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * custom_object_type_identifier: "Order", + * external_id: "123", + * external_created_at: 1392036272, + * external_updated_at: 1392036272, + * custom_attributes: { + * "order_number": "ORDER-12345", + * "total_amount": "custom_attributes" + * } + * } + */ +export interface CreateOrUpdateCustomObjectInstanceRequest { + /** The unique identifier of the custom object type that defines the structure of the custom object instance. */ + custom_object_type_identifier: string; + /** A unique identifier for the Custom Object instance in the external system it originated from. */ + external_id?: string; + /** The time when the Custom Object instance was created in the external system it originated from. */ + external_created_at?: number; + /** The time when the Custom Object instance was last updated in the external system it originated from. */ + external_updated_at?: number; + /** The custom attributes which are set for the Custom Object instance. */ + custom_attributes?: Record; +} diff --git a/src/api/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByExternalIdRequest.ts b/src/api/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByExternalIdRequest.ts new file mode 100644 index 00000000..16385f5b --- /dev/null +++ b/src/api/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByExternalIdRequest.ts @@ -0,0 +1,15 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * custom_object_type_identifier: "Order", + * custom_object_instance_id: "custom_object_instance_id" + * } + */ +export interface DeleteCustomObjectInstancesByExternalIdRequest { + /** The unique identifier of the custom object type that defines the structure of the custom object instance. */ + custom_object_type_identifier: string; + /** The Intercom defined id of the custom object instance */ + custom_object_instance_id: string; +} diff --git a/src/api/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByIdRequest.ts b/src/api/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByIdRequest.ts new file mode 100644 index 00000000..d97bc1ce --- /dev/null +++ b/src/api/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByIdRequest.ts @@ -0,0 +1,14 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * custom_object_type_identifier: "Order", + * external_id: "external_id" + * } + */ +export interface DeleteCustomObjectInstancesByIdRequest { + /** The unique identifier of the custom object type that defines the structure of the custom object instance. */ + custom_object_type_identifier: string; + external_id: string; +} diff --git a/src/api/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByExternalIdRequest.ts b/src/api/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByExternalIdRequest.ts new file mode 100644 index 00000000..2d9d0fe3 --- /dev/null +++ b/src/api/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByExternalIdRequest.ts @@ -0,0 +1,14 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * custom_object_type_identifier: "Order", + * external_id: "external_id" + * } + */ +export interface GetCustomObjectInstancesByExternalIdRequest { + /** The unique identifier of the custom object type that defines the structure of the custom object instance. */ + custom_object_type_identifier: string; + external_id: string; +} diff --git a/src/api/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByIdRequest.ts b/src/api/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByIdRequest.ts new file mode 100644 index 00000000..962a1337 --- /dev/null +++ b/src/api/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByIdRequest.ts @@ -0,0 +1,15 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * custom_object_type_identifier: "Order", + * custom_object_instance_id: "custom_object_instance_id" + * } + */ +export interface GetCustomObjectInstancesByIdRequest { + /** The unique identifier of the custom object type that defines the structure of the custom object instance. */ + custom_object_type_identifier: string; + /** The id or external_id of the custom object instance */ + custom_object_instance_id: string; +} diff --git a/src/api/resources/customObjectInstances/client/requests/index.ts b/src/api/resources/customObjectInstances/client/requests/index.ts new file mode 100644 index 00000000..07816781 --- /dev/null +++ b/src/api/resources/customObjectInstances/client/requests/index.ts @@ -0,0 +1,5 @@ +export type { CreateOrUpdateCustomObjectInstanceRequest } from "./CreateOrUpdateCustomObjectInstanceRequest.js"; +export type { DeleteCustomObjectInstancesByExternalIdRequest } from "./DeleteCustomObjectInstancesByExternalIdRequest.js"; +export type { DeleteCustomObjectInstancesByIdRequest } from "./DeleteCustomObjectInstancesByIdRequest.js"; +export type { GetCustomObjectInstancesByExternalIdRequest } from "./GetCustomObjectInstancesByExternalIdRequest.js"; +export type { GetCustomObjectInstancesByIdRequest } from "./GetCustomObjectInstancesByIdRequest.js"; diff --git a/src/api/resources/customObjectInstances/index.ts b/src/api/resources/customObjectInstances/index.ts new file mode 100644 index 00000000..d9adb1af --- /dev/null +++ b/src/api/resources/customObjectInstances/index.ts @@ -0,0 +1,2 @@ +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/customObjectInstances/types/CustomObjectInstance.ts b/src/api/resources/customObjectInstances/types/CustomObjectInstance.ts new file mode 100644 index 00000000..a4363acf --- /dev/null +++ b/src/api/resources/customObjectInstances/types/CustomObjectInstance.ts @@ -0,0 +1,23 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * A Custom Object Instance represents an instance of a custom object type. This allows you to create and set custom attributes to store data about your customers that is not already captured by Intercom. The parent object includes recommended default attributes and you can add your own custom attributes. + */ +export interface CustomObjectInstance { + /** The Intercom defined id representing the custom object instance. */ + id?: string; + /** The id you have defined for the custom object instance. */ + external_id?: string; + /** The time when the Custom Object instance was created in the external system it originated from. */ + external_created_at?: number; + /** The time when the Custom Object instance was last updated in the external system it originated from. */ + external_updated_at?: number; + /** The time the attribute was created as a UTC Unix timestamp */ + created_at?: number; + /** The time the attribute was last updated as a UTC Unix timestamp */ + updated_at?: number; + /** The identifier of the custom object type that defines the structure of the custom object instance. */ + type?: string; + /** The custom attributes you have set on the custom object instance. */ + custom_attributes?: Record; +} diff --git a/src/api/resources/customObjectInstances/types/index.ts b/src/api/resources/customObjectInstances/types/index.ts new file mode 100644 index 00000000..861f9ce5 --- /dev/null +++ b/src/api/resources/customObjectInstances/types/index.ts @@ -0,0 +1 @@ +export * from "./CustomObjectInstance.js"; diff --git a/src/api/resources/dataAttributes/client/Client.ts b/src/api/resources/dataAttributes/client/Client.ts index cd6b4d7e..acff8f55 100644 --- a/src/api/resources/dataAttributes/client/Client.ts +++ b/src/api/resources/dataAttributes/client/Client.ts @@ -1,137 +1,87 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace DataAttributes { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace DataAttributesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Data Attributes */ -export class DataAttributes { - constructor(protected readonly _options: DataAttributes.Options = {}) {} +export class DataAttributesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: DataAttributesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of all data attributes belonging to a workspace for contacts, companies or conversations. * * @param {Intercom.ListDataAttributesRequest} request - * @param {DataAttributes.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataAttributesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * * @example - * await client.dataAttributes.list() + * await client.dataAttributes.list({ + * model: "contact", + * include_archived: true + * }) */ public list( request: Intercom.ListDataAttributesRequest = {}, - requestOptions?: DataAttributes.RequestOptions, + requestOptions?: DataAttributesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__list(request, requestOptions)); } private async __list( request: Intercom.ListDataAttributesRequest = {}, - requestOptions?: DataAttributes.RequestOptions, + requestOptions?: DataAttributesClient.RequestOptions, ): Promise> { const { model, include_archived: includeArchived } = request; const _queryParams: Record = {}; if (model != null) { - _queryParams["model"] = model; + _queryParams.model = model; } if (includeArchived != null) { - _queryParams["include_archived"] = includeArchived.toString(); + _queryParams.include_archived = includeArchived.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "data_attributes", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.DataAttributeList, rawResponse: _response.rawResponse }; @@ -153,112 +103,71 @@ export class DataAttributes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /data_attributes."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/data_attributes"); } /** * You can create a data attributes for a `contact` or a `company`. * * @param {Intercom.CreateDataAttributeRequest} request - * @param {DataAttributes.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataAttributesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.BadRequestError} * @throws {@link Intercom.UnauthorizedError} * * @example * await client.dataAttributes.create({ - * name: "Mithril Shirt", - * model: "company", * data_type: "string" * }) * * @example * await client.dataAttributes.create({ - * name: "The One Ring", - * model: "contact", * data_type: "integer" * }) * * @example * await client.dataAttributes.create({ - * name: "!nv@l!d n@me", - * model: "company", - * data_type: "string" - * }) - * - * @example - * await client.dataAttributes.create({ - * name: "The One Ring", - * model: "company", - * data_type: "string" - * }) - * - * @example - * await client.dataAttributes.create({ - * name: "The Second Ring", - * model: "company", - * data_type: "string" - * }) - * - * @example - * await client.dataAttributes.create({ - * name: "My Data Attribute", - * model: "contact", - * data_type: "string", - * description: "Just a plain old ring", - * options: ["options"] + * options: [{ + * value: "1-10" + * }] * }) */ public create( request: Intercom.CreateDataAttributeRequest, - requestOptions?: DataAttributes.RequestOptions, + requestOptions?: DataAttributesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( request: Intercom.CreateDataAttributeRequest, - requestOptions?: DataAttributes.RequestOptions, + requestOptions?: DataAttributesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "data_attributes", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.DataAttribute, rawResponse: _response.rawResponse }; @@ -282,21 +191,7 @@ export class DataAttributes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /data_attributes."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/data_attributes"); } /** @@ -308,7 +203,7 @@ export class DataAttributes { * > It is currently a dangerous action to execute changing a data attribute's type via the API. You will need to update the type via the UI instead. * * @param {Intercom.UpdateDataAttributeRequest} request - * @param {DataAttributes.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataAttributesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.BadRequestError} * @throws {@link Intercom.UnauthorizedError} @@ -317,72 +212,74 @@ export class DataAttributes { * * @example * await client.dataAttributes.update({ - * data_attribute_id: "1", - * archived: false, - * description: "Just a plain old ring", - * options: [{ - * value: "1-10" - * }, { - * value: "11-20" - * }] + * data_attribute_id: 1, + * body: { + * options: [{ + * value: "1-10" + * }, { + * value: "11-20" + * }] + * } * }) * * @example * await client.dataAttributes.update({ - * data_attribute_id: "1", - * archived: false, - * description: "Too few options", - * options: [{ - * value: "value" - * }, { - * value: "value" - * }] + * data_attribute_id: 1, + * body: { + * options: [{ + * value: "1-10" + * }, { + * value: "11-50" + * }] + * } * }) * * @example * await client.dataAttributes.update({ - * data_attribute_id: "1", - * archived: true, - * description: "Trying to archieve" + * data_attribute_id: 1, + * body: { + * "description": "Trying to archieve", + * "archived": true + * } * }) */ public update( request: Intercom.UpdateDataAttributeRequest, - requestOptions?: DataAttributes.RequestOptions, + requestOptions?: DataAttributesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); } private async __update( request: Intercom.UpdateDataAttributeRequest, - requestOptions?: DataAttributes.RequestOptions, + requestOptions?: DataAttributesClient.RequestOptions, ): Promise> { - const { data_attribute_id: dataAttributeId, ..._body } = request; + const { data_attribute_id: dataAttributeId, body: _body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `data_attributes/${encodeURIComponent(dataAttributeId)}`, + `data_attributes/${core.url.encodePathParam(dataAttributeId)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.DataAttribute, rawResponse: _response.rawResponse }; @@ -410,34 +307,11 @@ export class DataAttributes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /data_attributes/{data_attribute_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "PUT", + "/data_attributes/{data_attribute_id}", + ); } } diff --git a/src/api/resources/dataAttributes/client/index.ts b/src/api/resources/dataAttributes/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/dataAttributes/client/index.ts +++ b/src/api/resources/dataAttributes/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts b/src/api/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts deleted file mode 100644 index d0856471..00000000 --- a/src/api/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts +++ /dev/null @@ -1,86 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * @example - * { - * name: "Mithril Shirt", - * model: "company", - * data_type: "string" - * } - * - * @example - * { - * name: "The One Ring", - * model: "contact", - * data_type: "integer" - * } - * - * @example - * { - * name: "!nv@l!d n@me", - * model: "company", - * data_type: "string" - * } - * - * @example - * { - * name: "The One Ring", - * model: "company", - * data_type: "string" - * } - * - * @example - * { - * name: "The Second Ring", - * model: "company", - * data_type: "string" - * } - * - * @example - * { - * name: "My Data Attribute", - * model: "contact", - * data_type: "string", - * description: "Just a plain old ring", - * options: ["options"] - * } - */ -export interface CreateDataAttributeRequest { - /** The name of the data attribute. */ - name: string; - /** The model that the data attribute belongs to. */ - model: CreateDataAttributeRequest.Model; - /** The type of data stored for this attribute. */ - data_type: CreateDataAttributeRequest.DataType; - /** The readable description you see in the UI for the attribute. */ - description?: string; - /** To create list attributes. Provide a set of hashes with `value` as the key of the options you want to make. `data_type` must be `string`. */ - options?: string[]; - /** Can this attribute be updated by the Messenger */ - messenger_writable?: boolean; -} - -export namespace CreateDataAttributeRequest { - /** - * The model that the data attribute belongs to. - */ - export type Model = "contact" | "company"; - export const Model = { - Contact: "contact", - Company: "company", - } as const; - /** - * The type of data stored for this attribute. - */ - export type DataType = "string" | "integer" | "float" | "boolean" | "datetime" | "date"; - export const DataType = { - String: "string", - Integer: "integer", - Float: "float", - Boolean: "boolean", - Datetime: "datetime", - Date: "date", - } as const; -} diff --git a/src/api/resources/dataAttributes/client/requests/ListDataAttributesRequest.ts b/src/api/resources/dataAttributes/client/requests/ListDataAttributesRequest.ts index 5d9ee979..f90a07a7 100644 --- a/src/api/resources/dataAttributes/client/requests/ListDataAttributesRequest.ts +++ b/src/api/resources/dataAttributes/client/requests/ListDataAttributesRequest.ts @@ -1,20 +1,17 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../index"; +import type * as Intercom from "../../../../index.js"; /** * @example - * {} + * { + * model: "contact", + * include_archived: true + * } */ export interface ListDataAttributesRequest { - /** - * Specify the data attribute model to return. - */ + /** Specify the data attribute model to return. */ model?: Intercom.DataAttributesListRequestModel; - /** - * Include archived attributes in the list. By default we return only non archived data attributes. - */ + /** Include archived attributes in the list. By default we return only non archived data attributes. */ include_archived?: boolean; } diff --git a/src/api/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts b/src/api/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts index 5ea8b95d..4b29b995 100644 --- a/src/api/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts +++ b/src/api/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts @@ -1,72 +1,55 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../index.js"; /** * @example * { - * data_attribute_id: "1", - * archived: false, - * description: "Just a plain old ring", - * options: [{ - * value: "1-10" - * }, { - * value: "11-20" - * }] + * data_attribute_id: 1, + * body: { + * options: [{ + * value: "1-10" + * }, { + * value: "11-20" + * }] + * } * } * * @example * { - * data_attribute_id: "1", - * archived: false, - * description: "Too few options", - * options: [{ - * value: "value" - * }, { - * value: "value" - * }] + * data_attribute_id: 1, + * body: { + * options: [{ + * value: "1-10" + * }, { + * value: "11-50" + * }] + * } * } * * @example * { - * data_attribute_id: "1", - * archived: false, - * description: "Just a plain old ring", - * options: [{ - * value: "1-10" - * }, { - * value: "11-20" - * }] + * data_attribute_id: 1, + * body: { + * options: [{ + * value: "1-10" + * }, { + * value: "11-20" + * }] + * } * } * * @example * { - * data_attribute_id: "1", - * archived: true, - * description: "Trying to archieve" + * data_attribute_id: 1, + * body: { + * "description": "Trying to archieve", + * "archived": true + * } * } */ export interface UpdateDataAttributeRequest { - /** - * The data attribute id - */ - data_attribute_id: string; - /** Whether the attribute is to be archived or not. */ - archived?: boolean; - /** The readable description you see in the UI for the attribute. */ - description?: string; - /** To create list attributes. Provide a set of hashes with `value` as the key of the options you want to make. `data_type` must be `string`. */ - options?: UpdateDataAttributeRequest.Options.Item[]; - /** Can this attribute be updated by the Messenger */ - messenger_writable?: boolean; -} - -export namespace UpdateDataAttributeRequest { - export type Options = Options.Item[]; - - export namespace Options { - export interface Item { - value: string; - } - } + /** The data attribute id */ + data_attribute_id: number; + body: Intercom.UpdateDataAttributeRequestBody; } diff --git a/src/api/resources/dataAttributes/client/requests/index.ts b/src/api/resources/dataAttributes/client/requests/index.ts index 6a7a0de5..a1a5824f 100644 --- a/src/api/resources/dataAttributes/client/requests/index.ts +++ b/src/api/resources/dataAttributes/client/requests/index.ts @@ -1,3 +1,2 @@ -export { type ListDataAttributesRequest } from "./ListDataAttributesRequest"; -export { type CreateDataAttributeRequest } from "./CreateDataAttributeRequest"; -export { type UpdateDataAttributeRequest } from "./UpdateDataAttributeRequest"; +export type { ListDataAttributesRequest } from "./ListDataAttributesRequest.js"; +export type { UpdateDataAttributeRequest } from "./UpdateDataAttributeRequest.js"; diff --git a/src/api/resources/dataAttributes/index.ts b/src/api/resources/dataAttributes/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/dataAttributes/index.ts +++ b/src/api/resources/dataAttributes/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/dataAttributes/types/DataAttribute.ts b/src/api/resources/dataAttributes/types/DataAttribute.ts index 1ce04881..a2dbee88 100644 --- a/src/api/resources/dataAttributes/types/DataAttribute.ts +++ b/src/api/resources/dataAttributes/types/DataAttribute.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Data Attributes are metadata used to describe your contact, company and conversation models. These include standard and custom attributes. By using the data attributes endpoint, you can get the global list of attributes for your workspace, as well as create and archive custom attributes. @@ -19,7 +17,7 @@ export interface DataAttribute { /** Readable name of the attribute (i.e. name you see in the UI) */ label: string; /** Readable description of the attribute. */ - description: string; + description?: string; /** The data type of the attribute. */ data_type: DataAttribute.DataType; /** List of predefined options for attribute value. */ @@ -43,18 +41,13 @@ export interface DataAttribute { } export namespace DataAttribute { - /** - * Value is `contact` for user/lead attributes and `company` for company attributes. - */ - export type Model = "contact" | "company"; + /** Value is `contact` for user/lead attributes and `company` for company attributes. */ export const Model = { Contact: "contact", Company: "company", } as const; - /** - * The data type of the attribute. - */ - export type DataType = "string" | "integer" | "float" | "boolean" | "date"; + export type Model = (typeof Model)[keyof typeof Model]; + /** The data type of the attribute. */ export const DataType = { String: "string", Integer: "integer", @@ -62,4 +55,5 @@ export namespace DataAttribute { Boolean: "boolean", Date: "date", } as const; + export type DataType = (typeof DataType)[keyof typeof DataType]; } diff --git a/src/api/resources/dataAttributes/types/DataAttributesListRequestModel.ts b/src/api/resources/dataAttributes/types/DataAttributesListRequestModel.ts index 4c163f30..8c42df63 100644 --- a/src/api/resources/dataAttributes/types/DataAttributesListRequestModel.ts +++ b/src/api/resources/dataAttributes/types/DataAttributesListRequestModel.ts @@ -1,10 +1,9 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -export type DataAttributesListRequestModel = "contact" | "company" | "conversation"; export const DataAttributesListRequestModel = { Contact: "contact", Company: "company", Conversation: "conversation", } as const; +export type DataAttributesListRequestModel = + (typeof DataAttributesListRequestModel)[keyof typeof DataAttributesListRequestModel]; diff --git a/src/api/resources/dataAttributes/types/index.ts b/src/api/resources/dataAttributes/types/index.ts index 70dcfefc..cf0add2c 100644 --- a/src/api/resources/dataAttributes/types/index.ts +++ b/src/api/resources/dataAttributes/types/index.ts @@ -1,2 +1,2 @@ -export * from "./DataAttributesListRequestModel"; -export * from "./DataAttribute"; +export * from "./DataAttribute.js"; +export * from "./DataAttributesListRequestModel.js"; diff --git a/src/api/resources/dataEvents/index.ts b/src/api/resources/dataEvents/index.ts index eea524d6..2f88e301 100644 --- a/src/api/resources/dataEvents/index.ts +++ b/src/api/resources/dataEvents/index.ts @@ -1 +1 @@ -export * from "./types"; +export * from "./types/index.js"; diff --git a/src/api/resources/dataEvents/types/DataEvent.ts b/src/api/resources/dataEvents/types/DataEvent.ts index 124221eb..a88a24e6 100644 --- a/src/api/resources/dataEvents/types/DataEvent.ts +++ b/src/api/resources/dataEvents/types/DataEvent.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Data events are used to notify Intercom of changes to your data. diff --git a/src/api/resources/dataEvents/types/index.ts b/src/api/resources/dataEvents/types/index.ts index 9b28ca3c..0272b738 100644 --- a/src/api/resources/dataEvents/types/index.ts +++ b/src/api/resources/dataEvents/types/index.ts @@ -1 +1 @@ -export * from "./DataEvent"; +export * from "./DataEvent.js"; diff --git a/src/api/resources/dataExport/client/Client.ts b/src/api/resources/dataExport/client/Client.ts index 72d82c09..f9ea23e2 100644 --- a/src/api/resources/dataExport/client/Client.ts +++ b/src/api/resources/dataExport/client/Client.ts @@ -1,79 +1,191 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace DataExport { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace DataExportClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Data Exports */ -export class DataExport { - constructor(protected readonly _options: DataExport.Options = {}) {} +export class DataExportClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: DataExportClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * @param {Intercom.ExportReportingDataRequest} request + * @param {DataExportClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.dataExport.exportReportingData({ + * job_identifier: "job_identifier", + * app_id: "app_id", + * client_id: "client_id" + * }) + */ + public exportReportingData( + request: Intercom.ExportReportingDataRequest, + requestOptions?: DataExportClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__exportReportingData(request, requestOptions)); + } + + private async __exportReportingData( + request: Intercom.ExportReportingDataRequest, + requestOptions?: DataExportClient.RequestOptions, + ): Promise> { + const { job_identifier: jobIdentifier, app_id: appId, client_id: clientId } = request; + const _queryParams: Record = {}; + _queryParams.app_id = appId; + _queryParams.client_id = clientId; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `export/reporting_data/${core.url.encodePathParam(jobIdentifier)}`, + ), + method: "GET", + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.DataExportExportReportingDataResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/export/reporting_data/{job_identifier}", + ); + } + + /** + * Download the data from a completed reporting data export job. + * + * > Octet header required + * > + * > You will have to specify the header Accept: `application/octet-stream` when hitting this endpoint. + * + * @param {Intercom.DownloadReportingDataExportRequest} request + * @param {DataExportClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.dataExport.downloadReportingDataExport({ + * job_identifier: "job_identifier", + * app_id: "app_id" + * }) + */ + public downloadReportingDataExport( + request: Intercom.DownloadReportingDataExportRequest, + requestOptions?: DataExportClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__downloadReportingDataExport(request, requestOptions)); + } + + private async __downloadReportingDataExport( + request: Intercom.DownloadReportingDataExportRequest, + requestOptions?: DataExportClient.RequestOptions, + ): Promise> { + const { job_identifier: jobIdentifier, app_id: appId } = request; + const _queryParams: Record = {}; + _queryParams.app_id = appId; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ + Accept: "application/octet-stream", + "Intercom-Version": requestOptions?.version, + }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `download/reporting_data/${core.url.encodePathParam(jobIdentifier)}`, + ), + method: "GET", + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: undefined, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/download/reporting_data/{job_identifier}", + ); + } /** * To create your export job, you need to send a `POST` request to the export endpoint `https://api.intercom.io/export/content/data`. @@ -93,50 +205,50 @@ export class DataExport { * > Requesting data for 2018-06-01 until 2018-06-30 will get all data for those days including those specified - e.g. 2018-06-01 00:00:00 until 2018-06-30 23:59:99. * * @param {Intercom.CreateDataExportRequest} request - * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataExportClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.dataExport.create({ - * created_at_after: 1719474967, - * created_at_before: 1719492967 + * created_at_after: 1734519776, + * created_at_before: 1734537776 * }) */ public create( request: Intercom.CreateDataExportRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( request: Intercom.CreateDataExportRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "export/content/data", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.DataExport, rawResponse: _response.rawResponse }; @@ -150,21 +262,7 @@ export class DataExport { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /export/content/data."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/export/content/data"); } /** @@ -175,7 +273,7 @@ export class DataExport { * > All jobs that have completed processing (and are thus available to download from the provided URL) will have an expiry limit of two days from when the export ob completed. After this, the data will no longer be available. * * @param {Intercom.FindDataExportRequest} request - * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataExportClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.dataExport.find({ @@ -184,40 +282,38 @@ export class DataExport { */ public find( request: Intercom.FindDataExportRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.FindDataExportRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): Promise> { const { job_identifier: jobIdentifier } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `export/content/data/${encodeURIComponent(jobIdentifier)}`, + `export/content/data/${core.url.encodePathParam(jobIdentifier)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.DataExport, rawResponse: _response.rawResponse }; @@ -231,30 +327,19 @@ export class DataExport { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /export/content/data/{job_identifier}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/export/content/data/{job_identifier}", + ); } /** * You can cancel your job * * @param {Intercom.CancelDataExportRequest} request - * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataExportClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.dataExport.cancel({ @@ -263,40 +348,38 @@ export class DataExport { */ public cancel( request: Intercom.CancelDataExportRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__cancel(request, requestOptions)); } private async __cancel( request: Intercom.CancelDataExportRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): Promise> { const { job_identifier: jobIdentifier } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `export/cancel/${encodeURIComponent(jobIdentifier)}`, + `export/cancel/${core.url.encodePathParam(jobIdentifier)}`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.DataExport, rawResponse: _response.rawResponse }; @@ -310,23 +393,12 @@ export class DataExport { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /export/cancel/{job_identifier}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/export/cancel/{job_identifier}", + ); } /** @@ -339,7 +411,7 @@ export class DataExport { * > You will have to specify the header Accept: `application/octet-stream` when hitting this endpoint. * * @param {Intercom.DownloadDataExportRequest} request - * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataExportClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.dataExport.download({ @@ -348,40 +420,38 @@ export class DataExport { */ public download( request: Intercom.DownloadDataExportRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__download(request, requestOptions)); } private async __download( request: Intercom.DownloadDataExportRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): Promise> { const { job_identifier: jobIdentifier } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `download/content/data/${encodeURIComponent(jobIdentifier)}`, + `download/content/data/${core.url.encodePathParam(jobIdentifier)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: undefined, rawResponse: _response.rawResponse }; @@ -395,34 +465,11 @@ export class DataExport { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /download/content/data/{job_identifier}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/download/content/data/{job_identifier}", + ); } } diff --git a/src/api/resources/dataExport/client/index.ts b/src/api/resources/dataExport/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/dataExport/client/index.ts +++ b/src/api/resources/dataExport/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/dataExport/client/requests/CancelDataExportRequest.ts b/src/api/resources/dataExport/client/requests/CancelDataExportRequest.ts index 39ed6925..4e387ec1 100644 --- a/src/api/resources/dataExport/client/requests/CancelDataExportRequest.ts +++ b/src/api/resources/dataExport/client/requests/CancelDataExportRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface CancelDataExportRequest { - /** - * job_identifier - */ + /** job_identifier */ job_identifier: string; } diff --git a/src/api/resources/dataExport/client/requests/CreateDataExportRequest.ts b/src/api/resources/dataExport/client/requests/CreateDataExportRequest.ts index d8b4e380..b0bc000c 100644 --- a/src/api/resources/dataExport/client/requests/CreateDataExportRequest.ts +++ b/src/api/resources/dataExport/client/requests/CreateDataExportRequest.ts @@ -1,12 +1,10 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * created_at_after: 1719474967, - * created_at_before: 1719492967 + * created_at_after: 1734519776, + * created_at_before: 1734537776 * } */ export interface CreateDataExportRequest { diff --git a/src/api/resources/dataExport/client/requests/DownloadDataExportRequest.ts b/src/api/resources/dataExport/client/requests/DownloadDataExportRequest.ts index 4a7ee828..98aab0f3 100644 --- a/src/api/resources/dataExport/client/requests/DownloadDataExportRequest.ts +++ b/src/api/resources/dataExport/client/requests/DownloadDataExportRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DownloadDataExportRequest { - /** - * job_identifier - */ + /** job_identifier */ job_identifier: string; } diff --git a/src/api/resources/dataExport/client/requests/DownloadReportingDataExportRequest.ts b/src/api/resources/dataExport/client/requests/DownloadReportingDataExportRequest.ts new file mode 100644 index 00000000..92bec12f --- /dev/null +++ b/src/api/resources/dataExport/client/requests/DownloadReportingDataExportRequest.ts @@ -0,0 +1,13 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * job_identifier: "job_identifier", + * app_id: "app_id" + * } + */ +export interface DownloadReportingDataExportRequest { + job_identifier: string; + app_id: string; +} diff --git a/src/api/resources/dataExport/client/requests/ExportReportingDataRequest.ts b/src/api/resources/dataExport/client/requests/ExportReportingDataRequest.ts new file mode 100644 index 00000000..15b8c300 --- /dev/null +++ b/src/api/resources/dataExport/client/requests/ExportReportingDataRequest.ts @@ -0,0 +1,24 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * job_identifier: "job_identifier", + * app_id: "app_id", + * client_id: "client_id" + * } + * + * @example + * { + * job_identifier: "job_identifier", + * app_id: "app_id", + * client_id: "client_id" + * } + */ +export interface ExportReportingDataRequest { + /** Unique identifier of the job. */ + job_identifier: string; + /** The Intercom defined code of the workspace the company is associated to. */ + app_id: string; + client_id: string; +} diff --git a/src/api/resources/dataExport/client/requests/FindDataExportRequest.ts b/src/api/resources/dataExport/client/requests/FindDataExportRequest.ts index fc5c67b4..cc335ddb 100644 --- a/src/api/resources/dataExport/client/requests/FindDataExportRequest.ts +++ b/src/api/resources/dataExport/client/requests/FindDataExportRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface FindDataExportRequest { - /** - * job_identifier - */ + /** job_identifier */ job_identifier: string; } diff --git a/src/api/resources/dataExport/client/requests/index.ts b/src/api/resources/dataExport/client/requests/index.ts index fa7821f6..753260ad 100644 --- a/src/api/resources/dataExport/client/requests/index.ts +++ b/src/api/resources/dataExport/client/requests/index.ts @@ -1,4 +1,6 @@ -export { type CreateDataExportRequest } from "./CreateDataExportRequest"; -export { type FindDataExportRequest } from "./FindDataExportRequest"; -export { type CancelDataExportRequest } from "./CancelDataExportRequest"; -export { type DownloadDataExportRequest } from "./DownloadDataExportRequest"; +export type { CancelDataExportRequest } from "./CancelDataExportRequest.js"; +export type { CreateDataExportRequest } from "./CreateDataExportRequest.js"; +export type { DownloadDataExportRequest } from "./DownloadDataExportRequest.js"; +export type { DownloadReportingDataExportRequest } from "./DownloadReportingDataExportRequest.js"; +export type { ExportReportingDataRequest } from "./ExportReportingDataRequest.js"; +export type { FindDataExportRequest } from "./FindDataExportRequest.js"; diff --git a/src/api/resources/dataExport/index.ts b/src/api/resources/dataExport/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/dataExport/index.ts +++ b/src/api/resources/dataExport/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/dataExport/types/DataExport.ts b/src/api/resources/dataExport/types/DataExport.ts index fbb48fc4..002d8072 100644 --- a/src/api/resources/dataExport/types/DataExport.ts +++ b/src/api/resources/dataExport/types/DataExport.ts @@ -1,26 +1,21 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The data export api is used to view all message sent & viewed in a given timeframe. */ export interface DataExport { /** The identifier for your job. */ - job_identifier: string; + job_identifier?: string; /** The current state of your job. */ - status: DataExport.Status; + status?: DataExport.Status; /** The time after which you will not be able to access the data. */ - download_expires_at: string; + download_expires_at?: string; /** The location where you can download your data. */ - download_url: string; + download_url?: string; } export namespace DataExport { - /** - * The current state of your job. - */ - export type Status = "pending" | "in_progress" | "failed" | "completed" | "no_data" | "canceled"; + /** The current state of your job. */ export const Status = { Pending: "pending", InProgress: "in_progress", @@ -29,4 +24,5 @@ export namespace DataExport { NoData: "no_data", Canceled: "canceled", } as const; + export type Status = (typeof Status)[keyof typeof Status]; } diff --git a/src/api/resources/dataExport/types/DataExportExportReportingDataResponse.ts b/src/api/resources/dataExport/types/DataExportExportReportingDataResponse.ts new file mode 100644 index 00000000..1eda3ab4 --- /dev/null +++ b/src/api/resources/dataExport/types/DataExportExportReportingDataResponse.ts @@ -0,0 +1,8 @@ +// This file was auto-generated by Fern from our API Definition. + +export interface DataExportExportReportingDataResponse { + job_identifier?: string; + status?: string; + download_url?: string; + download_expires_at?: string; +} diff --git a/src/api/resources/dataExport/types/index.ts b/src/api/resources/dataExport/types/index.ts index 7cea751a..222f0cce 100644 --- a/src/api/resources/dataExport/types/index.ts +++ b/src/api/resources/dataExport/types/index.ts @@ -1 +1,2 @@ -export * from "./DataExport"; +export * from "./DataExport.js"; +export * from "./DataExportExportReportingDataResponse.js"; diff --git a/src/api/resources/events/client/Client.ts b/src/api/resources/events/client/Client.ts index a51cd863..2c645b76 100644 --- a/src/api/resources/events/client/Client.ts +++ b/src/api/resources/events/client/Client.ts @@ -1,76 +1,26 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace Events { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace EventsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } -export class Events { - constructor(protected readonly _options: Events.Options = {}) {} +export class EventsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: EventsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * @@ -89,25 +39,30 @@ export class Events { * You can optionally define the result page size as well with the `per_page` parameter. * * @param {Intercom.ListEventsRequest} request - * @param {Events.RequestOptions} requestOptions - Request-specific configuration. + * @param {EventsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * * @example * await client.events.list({ - * type: "type" + * user_id: "user_id", + * intercom_user_id: "intercom_user_id", + * email: "email", + * type: "type", + * summary: true, + * per_page: 1 * }) */ public list( request: Intercom.ListEventsRequest, - requestOptions?: Events.RequestOptions, + requestOptions?: EventsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__list(request, requestOptions)); } private async __list( request: Intercom.ListEventsRequest, - requestOptions?: Events.RequestOptions, + requestOptions?: EventsClient.RequestOptions, ): Promise> { const { user_id: userId, @@ -119,51 +74,48 @@ export class Events { } = request; const _queryParams: Record = {}; if (userId != null) { - _queryParams["user_id"] = userId; + _queryParams.user_id = userId; } if (intercomUserId != null) { - _queryParams["intercom_user_id"] = intercomUserId; + _queryParams.intercom_user_id = intercomUserId; } if (email != null) { - _queryParams["email"] = email; + _queryParams.email = email; } - _queryParams["type"] = type_; + _queryParams.type = type_; if (summary != null) { - _queryParams["summary"] = summary.toString(); + _queryParams.summary = summary.toString(); } if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); + _queryParams.per_page = perPage.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "events", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.DataEventSummary, rawResponse: _response.rawResponse }; @@ -185,21 +137,7 @@ export class Events { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /events."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/events"); } /** @@ -245,8 +183,9 @@ export class Events { * - Event lists containing duplicate events will have those duplicates ignored. * - Server errors will return a `500` response code and may contain an error message in the body. * + * * @param {Intercom.CreateDataEventRequest} request - * @param {Events.RequestOptions} requestOptions - Request-specific configuration. + * @param {EventsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -259,40 +198,40 @@ export class Events { */ public create( request: Intercom.CreateDataEventRequest, - requestOptions?: Events.RequestOptions, + requestOptions?: EventsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( request: Intercom.CreateDataEventRequest, - requestOptions?: Events.RequestOptions, + requestOptions?: EventsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "events", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: undefined, rawResponse: _response.rawResponse }; @@ -314,28 +253,15 @@ export class Events { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /events."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/events"); } /** * Create event summaries for a user. Event summaries are used to track the number of times an event has occurred, the first time it occurred and the last time it occurred. * + * * @param {Intercom.ListEventSummariesRequest} request - * @param {Events.RequestOptions} requestOptions - Request-specific configuration. + * @param {EventsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -344,40 +270,40 @@ export class Events { */ public summaries( request: Intercom.ListEventSummariesRequest = {}, - requestOptions?: Events.RequestOptions, + requestOptions?: EventsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__summaries(request, requestOptions)); } private async __summaries( request: Intercom.ListEventSummariesRequest = {}, - requestOptions?: Events.RequestOptions, + requestOptions?: EventsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "events/summaries", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: undefined, rawResponse: _response.rawResponse }; @@ -399,32 +325,6 @@ export class Events { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /events/summaries."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/events/summaries"); } } diff --git a/src/api/resources/events/client/index.ts b/src/api/resources/events/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/events/client/index.ts +++ b/src/api/resources/events/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/events/client/requests/ListEventSummariesRequest.ts b/src/api/resources/events/client/requests/ListEventSummariesRequest.ts index b1f4c485..6c0d7bca 100644 --- a/src/api/resources/events/client/requests/ListEventSummariesRequest.ts +++ b/src/api/resources/events/client/requests/ListEventSummariesRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example diff --git a/src/api/resources/events/client/requests/ListEventsRequest.ts b/src/api/resources/events/client/requests/ListEventsRequest.ts index c77ac53b..6617f912 100644 --- a/src/api/resources/events/client/requests/ListEventsRequest.ts +++ b/src/api/resources/events/client/requests/ListEventsRequest.ts @@ -1,36 +1,27 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * type: "type" + * user_id: "user_id", + * intercom_user_id: "intercom_user_id", + * email: "email", + * type: "type", + * summary: true, + * per_page: 1 * } */ export interface ListEventsRequest { - /** - * user_id query parameter - */ + /** user_id query parameter */ user_id?: string; - /** - * intercom_user_id query parameter - */ + /** intercom_user_id query parameter */ intercom_user_id?: string; - /** - * email query parameter - */ + /** email query parameter */ email?: string; - /** - * The value must be user - */ + /** The value must be user */ type: string; - /** - * summary flag - */ + /** summary flag */ summary?: boolean; - /** - * How many results to display per page. Defaults to 15 - */ + /** How many results to display per page. Defaults to 15 */ per_page?: number; } diff --git a/src/api/resources/events/client/requests/index.ts b/src/api/resources/events/client/requests/index.ts index 25f04352..584ea81e 100644 --- a/src/api/resources/events/client/requests/index.ts +++ b/src/api/resources/events/client/requests/index.ts @@ -1,2 +1,2 @@ -export { type ListEventsRequest } from "./ListEventsRequest"; -export { type ListEventSummariesRequest } from "./ListEventSummariesRequest"; +export type { ListEventSummariesRequest } from "./ListEventSummariesRequest.js"; +export type { ListEventsRequest } from "./ListEventsRequest.js"; diff --git a/src/api/resources/events/index.ts b/src/api/resources/events/index.ts index 5ec76921..914b8c3c 100644 --- a/src/api/resources/events/index.ts +++ b/src/api/resources/events/index.ts @@ -1 +1 @@ -export * from "./client"; +export * from "./client/index.js"; diff --git a/src/api/resources/export/client/Client.ts b/src/api/resources/export/client/Client.ts new file mode 100644 index 00000000..521fe210 --- /dev/null +++ b/src/api/resources/export/client/Client.ts @@ -0,0 +1,176 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; + +export declare namespace ExportClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +export class ExportClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: ExportClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * @param {Intercom.PostExportReportingDataEnqueueRequest} request + * @param {ExportClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.TooManyRequestsError} + * + * @example + * await client.export.enqueueANewReportingDataExportJob({ + * dataset_id: "conversation", + * attribute_ids: ["conversation_id", "conversation_started_at"], + * start_time: 1717490000, + * end_time: 1717510000 + * }) + */ + public enqueueANewReportingDataExportJob( + request: Intercom.PostExportReportingDataEnqueueRequest, + requestOptions?: ExportClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__enqueueANewReportingDataExportJob(request, requestOptions)); + } + + private async __enqueueANewReportingDataExportJob( + request: Intercom.PostExportReportingDataEnqueueRequest, + requestOptions?: ExportClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "export/reporting_data/enqueue", + ), + method: "POST", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: request, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.PostExportReportingDataEnqueueResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 429: + throw new Intercom.TooManyRequestsError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/export/reporting_data/enqueue", + ); + } + + /** + * @param {ExportClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.export.listAvailableDatasetsAndAttributes() + */ + public listAvailableDatasetsAndAttributes( + requestOptions?: ExportClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listAvailableDatasetsAndAttributes(requestOptions)); + } + + private async __listAvailableDatasetsAndAttributes( + requestOptions?: ExportClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "export/reporting_data/get_datasets", + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.GetExportReportingDataGetDatasetsResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/export/reporting_data/get_datasets", + ); + } +} diff --git a/src/api/resources/export/client/index.ts b/src/api/resources/export/client/index.ts new file mode 100644 index 00000000..195f9aa8 --- /dev/null +++ b/src/api/resources/export/client/index.ts @@ -0,0 +1 @@ +export * from "./requests/index.js"; diff --git a/src/api/resources/export/client/requests/PostExportReportingDataEnqueueRequest.ts b/src/api/resources/export/client/requests/PostExportReportingDataEnqueueRequest.ts new file mode 100644 index 00000000..57767a44 --- /dev/null +++ b/src/api/resources/export/client/requests/PostExportReportingDataEnqueueRequest.ts @@ -0,0 +1,17 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * dataset_id: "conversation", + * attribute_ids: ["conversation_id", "conversation_started_at"], + * start_time: 1717490000, + * end_time: 1717510000 + * } + */ +export interface PostExportReportingDataEnqueueRequest { + dataset_id: string; + attribute_ids: string[]; + start_time: number; + end_time: number; +} diff --git a/src/api/resources/export/client/requests/index.ts b/src/api/resources/export/client/requests/index.ts new file mode 100644 index 00000000..a18772b7 --- /dev/null +++ b/src/api/resources/export/client/requests/index.ts @@ -0,0 +1 @@ +export type { PostExportReportingDataEnqueueRequest } from "./PostExportReportingDataEnqueueRequest.js"; diff --git a/src/api/resources/export/index.ts b/src/api/resources/export/index.ts new file mode 100644 index 00000000..d9adb1af --- /dev/null +++ b/src/api/resources/export/index.ts @@ -0,0 +1,2 @@ +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/export/types/GetExportReportingDataGetDatasetsResponse.ts b/src/api/resources/export/types/GetExportReportingDataGetDatasetsResponse.ts new file mode 100644 index 00000000..725ac29a --- /dev/null +++ b/src/api/resources/export/types/GetExportReportingDataGetDatasetsResponse.ts @@ -0,0 +1,31 @@ +// This file was auto-generated by Fern from our API Definition. + +export interface GetExportReportingDataGetDatasetsResponse { + type?: string; + data?: GetExportReportingDataGetDatasetsResponse.Data.Item[]; +} + +export namespace GetExportReportingDataGetDatasetsResponse { + export type Data = Data.Item[]; + + export namespace Data { + export interface Item { + id?: string; + name?: string; + description?: string; + default_time_attribute_id?: string; + attributes?: Item.Attributes.Item[]; + } + + export namespace Item { + export type Attributes = Attributes.Item[]; + + export namespace Attributes { + export interface Item { + id?: string; + name?: string; + } + } + } + } +} diff --git a/src/api/resources/export/types/PostExportReportingDataEnqueueResponse.ts b/src/api/resources/export/types/PostExportReportingDataEnqueueResponse.ts new file mode 100644 index 00000000..c15d988e --- /dev/null +++ b/src/api/resources/export/types/PostExportReportingDataEnqueueResponse.ts @@ -0,0 +1,8 @@ +// This file was auto-generated by Fern from our API Definition. + +export interface PostExportReportingDataEnqueueResponse { + job_identifier?: string; + status?: string; + download_url?: string; + download_expires_at?: string; +} diff --git a/src/api/resources/export/types/index.ts b/src/api/resources/export/types/index.ts new file mode 100644 index 00000000..27e82ed3 --- /dev/null +++ b/src/api/resources/export/types/index.ts @@ -0,0 +1,2 @@ +export * from "./GetExportReportingDataGetDatasetsResponse.js"; +export * from "./PostExportReportingDataEnqueueResponse.js"; diff --git a/src/api/resources/helpCenter/index.ts b/src/api/resources/helpCenter/index.ts index eea524d6..2f88e301 100644 --- a/src/api/resources/helpCenter/index.ts +++ b/src/api/resources/helpCenter/index.ts @@ -1 +1 @@ -export * from "./types"; +export * from "./types/index.js"; diff --git a/src/api/resources/helpCenter/types/Collection.ts b/src/api/resources/helpCenter/types/Collection.ts index 5394f881..7c9a53b2 100644 --- a/src/api/resources/helpCenter/types/Collection.ts +++ b/src/api/resources/helpCenter/types/Collection.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Collections are top level containers for Articles within the Help Center. @@ -27,7 +25,7 @@ export interface Collection { /** The order of the section in relation to others sections within a collection. Values go from `0` upwards. `0` is the default if there's no order. */ order: number; /** The default locale of the help center. This field is only returned for multilingual help centers. */ - default_locale: string; + default_locale?: string; translated_content?: Intercom.GroupTranslatedContent; /** The id of the parent collection. If `null` then it is the first level collection. */ parent_id?: string; diff --git a/src/api/resources/helpCenter/types/HelpCenter.ts b/src/api/resources/helpCenter/types/HelpCenter.ts index acf3993d..3715e87f 100644 --- a/src/api/resources/helpCenter/types/HelpCenter.ts +++ b/src/api/resources/helpCenter/types/HelpCenter.ts @@ -1,23 +1,25 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Help Centers contain collections */ export interface HelpCenter { /** The unique identifier for the Help Center which is given by Intercom. */ - id: string; + id?: string; /** The id of the workspace which the Help Center belongs to. */ - workspace_id: string; + workspace_id?: string; /** The time when the Help Center was created. */ - created_at: number; + created_at?: number; /** The time when the Help Center was last updated. */ updated_at?: number; /** The identifier of the Help Center. This is used in the URL of the Help Center. */ - identifier: string; + identifier?: string; /** Whether the Help Center is turned on or not. This is controlled in your Help Center settings. */ - website_turned_on: boolean; + website_turned_on?: boolean; /** The display name of the Help Center only seen by teammates. */ - display_name: string; + display_name?: string; + /** The URL for the help center, if you have a custom domain then this will show the URL using the custom domain. */ + url?: string; + /** Custom domain configured for the help center */ + custom_domain?: string; } diff --git a/src/api/resources/helpCenter/types/HelpCenterList.ts b/src/api/resources/helpCenter/types/HelpCenterList.ts index f2d362f7..e034eaff 100644 --- a/src/api/resources/helpCenter/types/HelpCenterList.ts +++ b/src/api/resources/helpCenter/types/HelpCenterList.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of Help Centers belonging to the App */ export interface HelpCenterList { /** The type of the object - `list`. */ - type: "list"; + type?: "list"; /** An array of Help Center objects */ - data: Intercom.HelpCenter[]; + data?: Intercom.HelpCenter[]; } diff --git a/src/api/resources/helpCenter/types/index.ts b/src/api/resources/helpCenter/types/index.ts index 65d348a7..097e7b49 100644 --- a/src/api/resources/helpCenter/types/index.ts +++ b/src/api/resources/helpCenter/types/index.ts @@ -1,3 +1,3 @@ -export * from "./Collection"; -export * from "./HelpCenter"; -export * from "./HelpCenterList"; +export * from "./Collection.js"; +export * from "./HelpCenter.js"; +export * from "./HelpCenterList.js"; diff --git a/src/api/resources/helpCenters/client/Client.ts b/src/api/resources/helpCenters/client/Client.ts index f8a1cf28..5541fb5c 100644 --- a/src/api/resources/helpCenters/client/Client.ts +++ b/src/api/resources/helpCenters/client/Client.ts @@ -1,134 +1,81 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; -import { Collections } from "../resources/collections/client/Client"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; +import { CollectionsClient } from "../resources/collections/client/Client.js"; -export declare namespace HelpCenters { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace HelpCentersClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } -export class HelpCenters { - protected _collections: Collections | undefined; +export class HelpCentersClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + protected _collections: CollectionsClient | undefined; - constructor(protected readonly _options: HelpCenters.Options = {}) {} + constructor(options: HelpCentersClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } - public get collections(): Collections { - return (this._collections ??= new Collections(this._options)); + public get collections(): CollectionsClient { + return (this._collections ??= new CollectionsClient(this._options)); } /** * You can fetch the details of a single Help Center by making a GET request to `https://api.intercom.io/help_center/help_center/`. * * @param {Intercom.FindHelpCenterRequest} request - * @param {HelpCenters.RequestOptions} requestOptions - Request-specific configuration. + * @param {HelpCentersClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.helpCenters.find({ - * help_center_id: "123" + * help_center_id: 1 * }) */ public find( request: Intercom.FindHelpCenterRequest, - requestOptions?: HelpCenters.RequestOptions, + requestOptions?: HelpCentersClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.FindHelpCenterRequest, - requestOptions?: HelpCenters.RequestOptions, + requestOptions?: HelpCentersClient.RequestOptions, ): Promise> { const { help_center_id: helpCenterId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `help_center/help_centers/${encodeURIComponent(helpCenterId)}`, + `help_center/help_centers/${core.url.encodePathParam(helpCenterId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.HelpCenter, rawResponse: _response.rawResponse }; @@ -152,30 +99,19 @@ export class HelpCenters { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /help_center/help_centers/{help_center_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/help_center/help_centers/{help_center_id}", + ); } /** * You can list all Help Centers by making a GET request to `https://api.intercom.io/help_center/help_centers`. * * @param {Intercom.ListHelpCentersRequest} request - * @param {HelpCenters.RequestOptions} requestOptions - Request-specific configuration. + * @param {HelpCentersClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -184,8 +120,8 @@ export class HelpCenters { */ public async list( request: Intercom.ListHelpCentersRequest = {}, - requestOptions?: HelpCenters.RequestOptions, - ): Promise> { + requestOptions?: HelpCentersClient.RequestOptions, + ): Promise> { const list = core.HttpResponsePromise.interceptFunction( async ( request: Intercom.ListHelpCentersRequest, @@ -193,37 +129,33 @@ export class HelpCenters { const { page, per_page: perPage } = request; const _queryParams: Record = {}; if (page != null) { - _queryParams["page"] = page.toString(); + _queryParams.page = page.toString(); } if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); + _queryParams.per_page = perPage.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "help_center/help_centers", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: - requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.HelpCenterList, rawResponse: _response.rawResponse }; @@ -243,28 +175,17 @@ export class HelpCenters { }); } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /help_center/help_centers.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/help_center/help_centers", + ); }, ); let _offset = request?.page != null ? request?.page : 1; const dataWithRawResponse = await list(request).withRawResponse(); - return new core.Pageable({ + return new core.Page({ response: dataWithRawResponse.data, rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => (response?.data ?? []).length > 0, @@ -275,16 +196,4 @@ export class HelpCenters { }, }); } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; - } } diff --git a/src/api/resources/helpCenters/client/index.ts b/src/api/resources/helpCenters/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/helpCenters/client/index.ts +++ b/src/api/resources/helpCenters/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/helpCenters/client/requests/FindHelpCenterRequest.ts b/src/api/resources/helpCenters/client/requests/FindHelpCenterRequest.ts index 2be74aba..f3efe0e4 100644 --- a/src/api/resources/helpCenters/client/requests/FindHelpCenterRequest.ts +++ b/src/api/resources/helpCenters/client/requests/FindHelpCenterRequest.ts @@ -1,16 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * help_center_id: "123" + * help_center_id: 1 * } */ export interface FindHelpCenterRequest { - /** - * The unique identifier for the Help Center which is given by Intercom. - */ - help_center_id: string; + /** The unique identifier for the collection which is given by Intercom. */ + help_center_id: number; } diff --git a/src/api/resources/helpCenters/client/requests/ListHelpCentersRequest.ts b/src/api/resources/helpCenters/client/requests/ListHelpCentersRequest.ts index 952e8e50..88dbf4b2 100644 --- a/src/api/resources/helpCenters/client/requests/ListHelpCentersRequest.ts +++ b/src/api/resources/helpCenters/client/requests/ListHelpCentersRequest.ts @@ -1,18 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * {} */ export interface ListHelpCentersRequest { - /** - * The page of results to fetch. Defaults to first page - */ + /** The page of results to fetch. Defaults to first page */ page?: number; - /** - * How many results to display per page. Defaults to 15 - */ + /** How many results to display per page. Defaults to 15 */ per_page?: number; } diff --git a/src/api/resources/helpCenters/client/requests/index.ts b/src/api/resources/helpCenters/client/requests/index.ts index 8cc9bf08..ea47193d 100644 --- a/src/api/resources/helpCenters/client/requests/index.ts +++ b/src/api/resources/helpCenters/client/requests/index.ts @@ -1,2 +1,2 @@ -export { type FindHelpCenterRequest } from "./FindHelpCenterRequest"; -export { type ListHelpCentersRequest } from "./ListHelpCentersRequest"; +export type { FindHelpCenterRequest } from "./FindHelpCenterRequest.js"; +export type { ListHelpCentersRequest } from "./ListHelpCentersRequest.js"; diff --git a/src/api/resources/helpCenters/index.ts b/src/api/resources/helpCenters/index.ts index 33a87f10..9eb1192d 100644 --- a/src/api/resources/helpCenters/index.ts +++ b/src/api/resources/helpCenters/index.ts @@ -1,2 +1,2 @@ -export * from "./client"; -export * from "./resources"; +export * from "./client/index.js"; +export * from "./resources/index.js"; diff --git a/src/api/resources/helpCenters/resources/collections/client/Client.ts b/src/api/resources/helpCenters/resources/collections/client/Client.ts index b123a0c1..86958a90 100644 --- a/src/api/resources/helpCenters/resources/collections/client/Client.ts +++ b/src/api/resources/helpCenters/resources/collections/client/Client.ts @@ -1,76 +1,26 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Collections { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace CollectionsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } -export class Collections { - constructor(protected readonly _options: Collections.Options = {}) {} +export class CollectionsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: CollectionsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of all collections by making a GET request to `https://api.intercom.io/help_center/collections`. @@ -78,7 +28,7 @@ export class Collections { * Collections will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated collections first. * * @param {Intercom.helpCenters.ListCollectionsRequest} request - * @param {Collections.RequestOptions} requestOptions - Request-specific configuration. + * @param {CollectionsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -87,8 +37,8 @@ export class Collections { */ public async list( request: Intercom.helpCenters.ListCollectionsRequest = {}, - requestOptions?: Collections.RequestOptions, - ): Promise> { + requestOptions?: CollectionsClient.RequestOptions, + ): Promise> { const list = core.HttpResponsePromise.interceptFunction( async ( request: Intercom.helpCenters.ListCollectionsRequest, @@ -96,37 +46,33 @@ export class Collections { const { page, per_page: perPage } = request; const _queryParams: Record = {}; if (page != null) { - _queryParams["page"] = page.toString(); + _queryParams.page = page.toString(); } if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); + _queryParams.per_page = perPage.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "help_center/collections", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: - requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.CollectionList, rawResponse: _response.rawResponse }; @@ -146,28 +92,17 @@ export class Collections { }); } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /help_center/collections.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/help_center/collections", + ); }, ); let _offset = request?.page != null ? request?.page : 1; const dataWithRawResponse = await list(request).withRawResponse(); - return new core.Pageable({ + return new core.Page({ response: dataWithRawResponse.data, rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => (response?.data ?? []).length > 0, @@ -183,7 +118,7 @@ export class Collections { * You can create a new collection by making a POST request to `https://api.intercom.io/help_center/collections.` * * @param {Intercom.helpCenters.CreateCollectionRequest} request - * @param {Collections.RequestOptions} requestOptions - Request-specific configuration. + * @param {CollectionsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.BadRequestError} * @throws {@link Intercom.UnauthorizedError} @@ -201,40 +136,40 @@ export class Collections { */ public create( request: Intercom.helpCenters.CreateCollectionRequest, - requestOptions?: Collections.RequestOptions, + requestOptions?: CollectionsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( request: Intercom.helpCenters.CreateCollectionRequest, - requestOptions?: Collections.RequestOptions, + requestOptions?: CollectionsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "help_center/collections", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Collection, rawResponse: _response.rawResponse }; @@ -258,73 +193,57 @@ export class Collections { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /help_center/collections."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/help_center/collections"); } /** * You can fetch the details of a single collection by making a GET request to `https://api.intercom.io/help_center/collections/`. * * @param {Intercom.helpCenters.FindCollectionRequest} request - * @param {Collections.RequestOptions} requestOptions - Request-specific configuration. + * @param {CollectionsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.helpCenters.collections.find({ - * collection_id: "123" + * collection_id: 1 * }) */ public find( request: Intercom.helpCenters.FindCollectionRequest, - requestOptions?: Collections.RequestOptions, + requestOptions?: CollectionsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.helpCenters.FindCollectionRequest, - requestOptions?: Collections.RequestOptions, + requestOptions?: CollectionsClient.RequestOptions, ): Promise> { const { collection_id: collectionId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `help_center/collections/${encodeURIComponent(collectionId)}`, + `help_center/collections/${core.url.encodePathParam(collectionId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Collection, rawResponse: _response.rawResponse }; @@ -348,77 +267,66 @@ export class Collections { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /help_center/collections/{collection_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/help_center/collections/{collection_id}", + ); } /** * You can update the details of a single collection by making a PUT request to `https://api.intercom.io/collections/`. * * @param {Intercom.helpCenters.UpdateCollectionRequest} request - * @param {Collections.RequestOptions} requestOptions - Request-specific configuration. + * @param {CollectionsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.helpCenters.collections.update({ - * collection_id: "123", + * collection_id: 1, * name: "Update collection name" * }) */ public update( request: Intercom.helpCenters.UpdateCollectionRequest, - requestOptions?: Collections.RequestOptions, + requestOptions?: CollectionsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); } private async __update( request: Intercom.helpCenters.UpdateCollectionRequest, - requestOptions?: Collections.RequestOptions, + requestOptions?: CollectionsClient.RequestOptions, ): Promise> { const { collection_id: collectionId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `help_center/collections/${encodeURIComponent(collectionId)}`, + `help_center/collections/${core.url.encodePathParam(collectionId)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Collection, rawResponse: _response.rawResponse }; @@ -442,75 +350,62 @@ export class Collections { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /help_center/collections/{collection_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "PUT", + "/help_center/collections/{collection_id}", + ); } /** * You can delete a single collection by making a DELETE request to `https://api.intercom.io/collections/`. * * @param {Intercom.helpCenters.DeleteCollectionRequest} request - * @param {Collections.RequestOptions} requestOptions - Request-specific configuration. + * @param {CollectionsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.helpCenters.collections.delete({ - * collection_id: "123" + * collection_id: 1 * }) */ public delete( request: Intercom.helpCenters.DeleteCollectionRequest, - requestOptions?: Collections.RequestOptions, + requestOptions?: CollectionsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__delete(request, requestOptions)); } private async __delete( request: Intercom.helpCenters.DeleteCollectionRequest, - requestOptions?: Collections.RequestOptions, + requestOptions?: CollectionsClient.RequestOptions, ): Promise> { const { collection_id: collectionId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `help_center/collections/${encodeURIComponent(collectionId)}`, + `help_center/collections/${core.url.encodePathParam(collectionId)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.DeletedCollectionObject, rawResponse: _response.rawResponse }; @@ -534,34 +429,11 @@ export class Collections { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /help_center/collections/{collection_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/help_center/collections/{collection_id}", + ); } } diff --git a/src/api/resources/helpCenters/resources/collections/client/index.ts b/src/api/resources/helpCenters/resources/collections/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/helpCenters/resources/collections/client/index.ts +++ b/src/api/resources/helpCenters/resources/collections/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/helpCenters/resources/collections/client/requests/CreateCollectionRequest.ts b/src/api/resources/helpCenters/resources/collections/client/requests/CreateCollectionRequest.ts index 3fe27292..045965d9 100644 --- a/src/api/resources/helpCenters/resources/collections/client/requests/CreateCollectionRequest.ts +++ b/src/api/resources/helpCenters/resources/collections/client/requests/CreateCollectionRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example diff --git a/src/api/resources/helpCenters/resources/collections/client/requests/DeleteCollectionRequest.ts b/src/api/resources/helpCenters/resources/collections/client/requests/DeleteCollectionRequest.ts index 8dbdb625..f97cdf86 100644 --- a/src/api/resources/helpCenters/resources/collections/client/requests/DeleteCollectionRequest.ts +++ b/src/api/resources/helpCenters/resources/collections/client/requests/DeleteCollectionRequest.ts @@ -1,16 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * collection_id: "123" + * collection_id: 1 * } */ export interface DeleteCollectionRequest { - /** - * The unique identifier for the collection which is given by Intercom. - */ - collection_id: string; + /** The unique identifier for the collection which is given by Intercom. */ + collection_id: number; } diff --git a/src/api/resources/helpCenters/resources/collections/client/requests/FindCollectionRequest.ts b/src/api/resources/helpCenters/resources/collections/client/requests/FindCollectionRequest.ts index 6c44a759..ddf2e39b 100644 --- a/src/api/resources/helpCenters/resources/collections/client/requests/FindCollectionRequest.ts +++ b/src/api/resources/helpCenters/resources/collections/client/requests/FindCollectionRequest.ts @@ -1,16 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * collection_id: "123" + * collection_id: 1 * } */ export interface FindCollectionRequest { - /** - * The unique identifier for the collection which is given by Intercom. - */ - collection_id: string; + /** The unique identifier for the collection which is given by Intercom. */ + collection_id: number; } diff --git a/src/api/resources/helpCenters/resources/collections/client/requests/ListCollectionsRequest.ts b/src/api/resources/helpCenters/resources/collections/client/requests/ListCollectionsRequest.ts index c8d346bd..2ebe21cd 100644 --- a/src/api/resources/helpCenters/resources/collections/client/requests/ListCollectionsRequest.ts +++ b/src/api/resources/helpCenters/resources/collections/client/requests/ListCollectionsRequest.ts @@ -1,18 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * {} */ export interface ListCollectionsRequest { - /** - * The page of results to fetch. Defaults to first page - */ + /** The page of results to fetch. Defaults to first page */ page?: number; - /** - * How many results to display per page. Defaults to 15 - */ + /** How many results to display per page. Defaults to 15 */ per_page?: number; } diff --git a/src/api/resources/helpCenters/resources/collections/client/requests/UpdateCollectionRequest.ts b/src/api/resources/helpCenters/resources/collections/client/requests/UpdateCollectionRequest.ts index 69bf333a..63cae012 100644 --- a/src/api/resources/helpCenters/resources/collections/client/requests/UpdateCollectionRequest.ts +++ b/src/api/resources/helpCenters/resources/collections/client/requests/UpdateCollectionRequest.ts @@ -1,27 +1,23 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example * { - * collection_id: "123", + * collection_id: 1, * name: "Update collection name" * } * * @example * { - * collection_id: "123", + * collection_id: 1, * name: "Update collection name" * } */ export interface UpdateCollectionRequest { - /** - * The unique identifier for the collection which is given by Intercom. - */ - collection_id: string; + /** The unique identifier for the collection which is given by Intercom. */ + collection_id: number; /** The name of the collection. For multilingual collections, this will be the name of the default language's content. */ name?: string; /** The description of the collection. For multilingual collections, this will be the description of the default language's content. */ diff --git a/src/api/resources/helpCenters/resources/collections/client/requests/index.ts b/src/api/resources/helpCenters/resources/collections/client/requests/index.ts index ed57ba6d..83e00901 100644 --- a/src/api/resources/helpCenters/resources/collections/client/requests/index.ts +++ b/src/api/resources/helpCenters/resources/collections/client/requests/index.ts @@ -1,5 +1,5 @@ -export { type ListCollectionsRequest } from "./ListCollectionsRequest"; -export { type CreateCollectionRequest } from "./CreateCollectionRequest"; -export { type FindCollectionRequest } from "./FindCollectionRequest"; -export { type UpdateCollectionRequest } from "./UpdateCollectionRequest"; -export { type DeleteCollectionRequest } from "./DeleteCollectionRequest"; +export type { CreateCollectionRequest } from "./CreateCollectionRequest.js"; +export type { DeleteCollectionRequest } from "./DeleteCollectionRequest.js"; +export type { FindCollectionRequest } from "./FindCollectionRequest.js"; +export type { ListCollectionsRequest } from "./ListCollectionsRequest.js"; +export type { UpdateCollectionRequest } from "./UpdateCollectionRequest.js"; diff --git a/src/api/resources/helpCenters/resources/collections/index.ts b/src/api/resources/helpCenters/resources/collections/index.ts index 5ec76921..914b8c3c 100644 --- a/src/api/resources/helpCenters/resources/collections/index.ts +++ b/src/api/resources/helpCenters/resources/collections/index.ts @@ -1 +1 @@ -export * from "./client"; +export * from "./client/index.js"; diff --git a/src/api/resources/helpCenters/resources/index.ts b/src/api/resources/helpCenters/resources/index.ts index d52abdea..a661f9d8 100644 --- a/src/api/resources/helpCenters/resources/index.ts +++ b/src/api/resources/helpCenters/resources/index.ts @@ -1,2 +1,2 @@ -export * as collections from "./collections"; -export * from "./collections/client/requests"; +export * from "./collections/client/requests/index.js"; +export * as collections from "./collections/index.js"; diff --git a/src/api/resources/index.ts b/src/api/resources/index.ts index 7761ecb9..80be8483 100644 --- a/src/api/resources/index.ts +++ b/src/api/resources/index.ts @@ -1,61 +1,82 @@ -export * as admins from "./admins"; -export * from "./admins/types"; -export * as articles from "./articles"; -export * from "./articles/types"; -export * as companies from "./companies"; -export * from "./companies/types"; -export * as contacts from "./contacts"; -export * from "./contacts/types"; -export * as notes from "./notes"; -export * from "./notes/types"; -export * as tags from "./tags"; -export * from "./tags/types"; -export * as conversations from "./conversations"; -export * from "./conversations/types"; -export * as dataAttributes from "./dataAttributes"; -export * from "./dataAttributes/types"; -export * as dataExport from "./dataExport"; -export * from "./dataExport/types"; -export * as messages from "./messages"; -export * from "./messages/types"; -export * as segments from "./segments"; -export * from "./segments/types"; -export * as subscriptionTypes from "./subscriptionTypes"; -export * from "./subscriptionTypes/types"; -export * as teams from "./teams"; -export * from "./teams/types"; -export * as tickets from "./tickets"; -export * from "./tickets/types"; -export * as aiAgent from "./aiAgent"; -export * from "./aiAgent/types"; -export * as helpCenter from "./helpCenter"; -export * from "./helpCenter/types"; -export * as aiContentSource from "./aiContentSource"; -export * from "./aiContentSource/types"; -export * as dataEvents from "./dataEvents"; -export * from "./dataEvents/types"; -export * as news from "./news"; -export * from "./news/types"; -export * as unstable from "./unstable"; -export * as helpCenters from "./helpCenters"; -export * as events from "./events"; -export * as phoneCallRedirects from "./phoneCallRedirects"; -export * as ticketTypes from "./ticketTypes"; -export * as visitors from "./visitors"; -export * from "./admins/client/requests"; -export * from "./articles/client/requests"; -export * from "./helpCenters/client/requests"; -export * from "./companies/client/requests"; -export * from "./contacts/client/requests"; -export * from "./notes/client/requests"; -export * from "./tags/client/requests"; -export * from "./conversations/client/requests"; -export * from "./dataAttributes/client/requests"; -export * from "./events/client/requests"; -export * from "./dataExport/client/requests"; -export * from "./segments/client/requests"; -export * from "./phoneCallRedirects/client/requests"; -export * from "./teams/client/requests"; -export * from "./ticketTypes/client/requests"; -export * from "./tickets/client/requests"; -export * from "./visitors/client/requests"; +export * from "./admins/client/requests/index.js"; +export * as admins from "./admins/index.js"; +export * from "./admins/types/index.js"; +export * as aiAgent from "./aiAgent/index.js"; +export * from "./aiAgent/types/index.js"; +export * from "./aiContent/client/requests/index.js"; +export * as aiContent from "./aiContent/index.js"; +export * from "./aiContent/types/index.js"; +export * as aiContentSource from "./aiContentSource/index.js"; +export * from "./aiContentSource/types/index.js"; +export * from "./articles/client/requests/index.js"; +export * as articles from "./articles/index.js"; +export * from "./articles/types/index.js"; +export * as awayStatusReasons from "./awayStatusReasons/index.js"; +export * from "./calls/client/requests/index.js"; +export * as calls from "./calls/index.js"; +export * from "./calls/types/index.js"; +export * from "./companies/client/requests/index.js"; +export * as companies from "./companies/index.js"; +export * from "./companies/types/index.js"; +export * from "./contacts/client/requests/index.js"; +export * as contacts from "./contacts/index.js"; +export * from "./contacts/types/index.js"; +export * from "./conversations/client/requests/index.js"; +export * as conversations from "./conversations/index.js"; +export * from "./conversations/types/index.js"; +export * from "./customChannelEvents/client/requests/index.js"; +export * as customChannelEvents from "./customChannelEvents/index.js"; +export * from "./customObjectInstances/client/requests/index.js"; +export * as customObjectInstances from "./customObjectInstances/index.js"; +export * from "./customObjectInstances/types/index.js"; +export * from "./dataAttributes/client/requests/index.js"; +export * as dataAttributes from "./dataAttributes/index.js"; +export * from "./dataAttributes/types/index.js"; +export * as dataEvents from "./dataEvents/index.js"; +export * from "./dataEvents/types/index.js"; +export * from "./dataExport/client/requests/index.js"; +export * as dataExport from "./dataExport/index.js"; +export * from "./dataExport/types/index.js"; +export * from "./events/client/requests/index.js"; +export * as events from "./events/index.js"; +export * from "./export/client/requests/index.js"; +export * as export_ from "./export/index.js"; +export * from "./export/types/index.js"; +export * as helpCenter from "./helpCenter/index.js"; +export * from "./helpCenter/types/index.js"; +export * from "./helpCenters/client/requests/index.js"; +export * as helpCenters from "./helpCenters/index.js"; +export * from "./internalArticles/client/requests/index.js"; +export * as internalArticles from "./internalArticles/index.js"; +export * from "./internalArticles/types/index.js"; +export * from "./jobs/client/requests/index.js"; +export * as jobs from "./jobs/index.js"; +export * from "./jobs/types/index.js"; +export * as messages from "./messages/index.js"; +export * from "./messages/types/index.js"; +export * as news from "./news/index.js"; +export * from "./news/types/index.js"; +export * from "./notes/client/requests/index.js"; +export * as notes from "./notes/index.js"; +export * from "./notes/types/index.js"; +export * as phoneCallRedirects from "./phoneCallRedirects/index.js"; +export * from "./segments/client/requests/index.js"; +export * as segments from "./segments/index.js"; +export * from "./segments/types/index.js"; +export * as subscriptionTypes from "./subscriptionTypes/index.js"; +export * from "./subscriptionTypes/types/index.js"; +export * from "./tags/client/requests/index.js"; +export * as tags from "./tags/index.js"; +export * from "./tags/types/index.js"; +export * from "./teams/client/requests/index.js"; +export * as teams from "./teams/index.js"; +export * from "./teams/types/index.js"; +export * as ticketStates from "./ticketStates/index.js"; +export * from "./tickets/client/requests/index.js"; +export * as tickets from "./tickets/index.js"; +export * from "./tickets/types/index.js"; +export * from "./ticketTypes/client/requests/index.js"; +export * as ticketTypes from "./ticketTypes/index.js"; +export * as unstable from "./unstable/index.js"; +export * from "./visitors/client/requests/index.js"; +export * as visitors from "./visitors/index.js"; diff --git a/src/api/resources/internalArticles/client/Client.ts b/src/api/resources/internalArticles/client/Client.ts new file mode 100644 index 00000000..4640a818 --- /dev/null +++ b/src/api/resources/internalArticles/client/Client.ts @@ -0,0 +1,503 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; + +export declare namespace InternalArticlesClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * Everything about your Internal Articles + */ +export class InternalArticlesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: InternalArticlesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * You can fetch a list of all internal articles by making a GET request to `https://api.intercom.io/internal_articles`. + * + * @param {InternalArticlesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.internalArticles.listInternalArticles() + */ + public listInternalArticles( + requestOptions?: InternalArticlesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listInternalArticles(requestOptions)); + } + + private async __listInternalArticles( + requestOptions?: InternalArticlesClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "internal_articles", + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.InternalArticleList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/internal_articles"); + } + + /** + * You can create a new internal article by making a POST request to `https://api.intercom.io/internal_articles`. + * + * @param {Intercom.CreateInternalArticleRequest} request + * @param {InternalArticlesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.internalArticles.createInternalArticle({ + * title: "Thanks for everything", + * body: "Body of the Article", + * author_id: 991266252, + * owner_id: 991266252 + * }) + * + * @example + * await client.internalArticles.createInternalArticle({ + * title: "Thanks for everything", + * body: "Body of the Internal Article", + * author_id: 1295, + * owner_id: 1295 + * }) + */ + public createInternalArticle( + request?: Intercom.CreateInternalArticleRequest, + requestOptions?: InternalArticlesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createInternalArticle(request, requestOptions)); + } + + private async __createInternalArticle( + request?: Intercom.CreateInternalArticleRequest, + requestOptions?: InternalArticlesClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "internal_articles", + ), + method: "POST", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: request != null ? request : undefined, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.InternalArticle, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/internal_articles"); + } + + /** + * You can fetch the details of a single internal article by making a GET request to `https://api.intercom.io/internal_articles/`. + * + * @param {Intercom.RetrieveInternalArticleRequest} request + * @param {InternalArticlesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.internalArticles.retrieveInternalArticle({ + * internal_article_id: 1 + * }) + */ + public retrieveInternalArticle( + request: Intercom.RetrieveInternalArticleRequest, + requestOptions?: InternalArticlesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveInternalArticle(request, requestOptions)); + } + + private async __retrieveInternalArticle( + request: Intercom.RetrieveInternalArticleRequest, + requestOptions?: InternalArticlesClient.RequestOptions, + ): Promise> { + const { internal_article_id: internalArticleId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `internal_articles/${core.url.encodePathParam(internalArticleId)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.InternalArticle, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/internal_articles/{internal_article_id}", + ); + } + + /** + * You can update the details of a single internal article by making a PUT request to `https://api.intercom.io/internal_articles/`. + * + * @param {Intercom.UpdateInternalArticleRequestBody} request + * @param {InternalArticlesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.internalArticles.updateInternalArticle({ + * internal_article_id: 1, + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

" + * }) + */ + public updateInternalArticle( + request: Intercom.UpdateInternalArticleRequestBody, + requestOptions?: InternalArticlesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateInternalArticle(request, requestOptions)); + } + + private async __updateInternalArticle( + request: Intercom.UpdateInternalArticleRequestBody, + requestOptions?: InternalArticlesClient.RequestOptions, + ): Promise> { + const { internal_article_id: internalArticleId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `internal_articles/${core.url.encodePathParam(internalArticleId)}`, + ), + method: "PUT", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: _body, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.InternalArticle, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "PUT", + "/internal_articles/{internal_article_id}", + ); + } + + /** + * You can delete a single internal article by making a DELETE request to `https://api.intercom.io/internal_articles/`. + * + * @param {Intercom.DeleteInternalArticleRequest} request + * @param {InternalArticlesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.internalArticles.deleteInternalArticle({ + * internal_article_id: 1 + * }) + */ + public deleteInternalArticle( + request: Intercom.DeleteInternalArticleRequest, + requestOptions?: InternalArticlesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteInternalArticle(request, requestOptions)); + } + + private async __deleteInternalArticle( + request: Intercom.DeleteInternalArticleRequest, + requestOptions?: InternalArticlesClient.RequestOptions, + ): Promise> { + const { internal_article_id: internalArticleId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `internal_articles/${core.url.encodePathParam(internalArticleId)}`, + ), + method: "DELETE", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.DeletedInternalArticleObject, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/internal_articles/{internal_article_id}", + ); + } + + /** + * You can search for internal articles by making a GET request to `https://api.intercom.io/internal_articles/search`. + * + * @param {Intercom.SearchInternalArticlesRequest} request + * @param {InternalArticlesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.internalArticles.searchInternalArticles({ + * folder_id: "folder_id" + * }) + */ + public searchInternalArticles( + request: Intercom.SearchInternalArticlesRequest = {}, + requestOptions?: InternalArticlesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__searchInternalArticles(request, requestOptions)); + } + + private async __searchInternalArticles( + request: Intercom.SearchInternalArticlesRequest = {}, + requestOptions?: InternalArticlesClient.RequestOptions, + ): Promise> { + const { folder_id: folderId } = request; + const _queryParams: Record = {}; + if (folderId != null) { + _queryParams.folder_id = folderId; + } + + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "internal_articles/search", + ), + method: "GET", + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.InternalArticleSearchResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/internal_articles/search"); + } +} diff --git a/src/api/resources/internalArticles/client/index.ts b/src/api/resources/internalArticles/client/index.ts new file mode 100644 index 00000000..195f9aa8 --- /dev/null +++ b/src/api/resources/internalArticles/client/index.ts @@ -0,0 +1 @@ +export * from "./requests/index.js"; diff --git a/src/api/resources/internalArticles/client/requests/DeleteInternalArticleRequest.ts b/src/api/resources/internalArticles/client/requests/DeleteInternalArticleRequest.ts new file mode 100644 index 00000000..6cd2773b --- /dev/null +++ b/src/api/resources/internalArticles/client/requests/DeleteInternalArticleRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * internal_article_id: 1 + * } + */ +export interface DeleteInternalArticleRequest { + /** The unique identifier for the internal article which is given by Intercom. */ + internal_article_id: number; +} diff --git a/src/api/resources/internalArticles/client/requests/RetrieveInternalArticleRequest.ts b/src/api/resources/internalArticles/client/requests/RetrieveInternalArticleRequest.ts new file mode 100644 index 00000000..ca4bac12 --- /dev/null +++ b/src/api/resources/internalArticles/client/requests/RetrieveInternalArticleRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * internal_article_id: 1 + * } + */ +export interface RetrieveInternalArticleRequest { + /** The unique identifier for the article which is given by Intercom. */ + internal_article_id: number; +} diff --git a/src/api/resources/internalArticles/client/requests/SearchInternalArticlesRequest.ts b/src/api/resources/internalArticles/client/requests/SearchInternalArticlesRequest.ts new file mode 100644 index 00000000..6f80cf05 --- /dev/null +++ b/src/api/resources/internalArticles/client/requests/SearchInternalArticlesRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * folder_id: "folder_id" + * } + */ +export interface SearchInternalArticlesRequest { + /** The ID of the folder to search in. */ + folder_id?: string; +} diff --git a/src/api/resources/internalArticles/client/requests/UpdateInternalArticleRequestBody.ts b/src/api/resources/internalArticles/client/requests/UpdateInternalArticleRequestBody.ts new file mode 100644 index 00000000..55416491 --- /dev/null +++ b/src/api/resources/internalArticles/client/requests/UpdateInternalArticleRequestBody.ts @@ -0,0 +1,29 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * internal_article_id: 1, + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

" + * } + * + * @example + * { + * internal_article_id: 1, + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

" + * } + */ +export interface UpdateInternalArticleRequestBody { + /** The unique identifier for the internal article which is given by Intercom. */ + internal_article_id: number; + /** The title of the article. */ + title?: string; + /** The content of the article. */ + body?: string; + /** The id of the author of the article. */ + author_id?: number; + /** The id of the author of the article. */ + owner_id?: number; +} diff --git a/src/api/resources/internalArticles/client/requests/index.ts b/src/api/resources/internalArticles/client/requests/index.ts new file mode 100644 index 00000000..677bd9fa --- /dev/null +++ b/src/api/resources/internalArticles/client/requests/index.ts @@ -0,0 +1,4 @@ +export type { DeleteInternalArticleRequest } from "./DeleteInternalArticleRequest.js"; +export type { RetrieveInternalArticleRequest } from "./RetrieveInternalArticleRequest.js"; +export type { SearchInternalArticlesRequest } from "./SearchInternalArticlesRequest.js"; +export type { UpdateInternalArticleRequestBody } from "./UpdateInternalArticleRequestBody.js"; diff --git a/src/api/resources/internalArticles/index.ts b/src/api/resources/internalArticles/index.ts new file mode 100644 index 00000000..d9adb1af --- /dev/null +++ b/src/api/resources/internalArticles/index.ts @@ -0,0 +1,2 @@ +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/internalArticles/types/InternalArticleListItem.ts b/src/api/resources/internalArticles/types/InternalArticleListItem.ts new file mode 100644 index 00000000..b906ff6f --- /dev/null +++ b/src/api/resources/internalArticles/types/InternalArticleListItem.ts @@ -0,0 +1,25 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * The data returned about your internal articles when you list them. + */ +export interface InternalArticleListItem { + /** The type of object - `internal_article`. */ + type?: "internal_article"; + /** The unique identifier for the article which is given by Intercom. */ + id?: string; + /** The title of the article. */ + title?: string; + /** The body of the article in HTML. */ + body?: string; + /** The id of the owner of the article. */ + owner_id?: number; + /** The id of the author of the article. */ + author_id?: number; + /** The time when the article was created. */ + created_at?: number; + /** The time when the article was last updated. */ + updated_at?: number; + /** The default locale of the article. */ + locale?: string; +} diff --git a/src/api/resources/internalArticles/types/InternalArticleSearchResponse.ts b/src/api/resources/internalArticles/types/InternalArticleSearchResponse.ts new file mode 100644 index 00000000..9718b94b --- /dev/null +++ b/src/api/resources/internalArticles/types/InternalArticleSearchResponse.ts @@ -0,0 +1,26 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +/** + * The results of an Internal Article search + */ +export interface InternalArticleSearchResponse { + /** The type of the object - `list`. */ + type?: "list"; + /** The total number of Internal Articles matching the search query */ + total_count?: number; + /** An object containing the results of the search. */ + data?: InternalArticleSearchResponse.Data; + pages?: Intercom.CursorPages; +} + +export namespace InternalArticleSearchResponse { + /** + * An object containing the results of the search. + */ + export interface Data { + /** An array of Internal Article objects */ + internal_articles?: Intercom.InternalArticle[]; + } +} diff --git a/src/api/resources/internalArticles/types/index.ts b/src/api/resources/internalArticles/types/index.ts new file mode 100644 index 00000000..aedeb96e --- /dev/null +++ b/src/api/resources/internalArticles/types/index.ts @@ -0,0 +1,2 @@ +export * from "./InternalArticleListItem.js"; +export * from "./InternalArticleSearchResponse.js"; diff --git a/src/api/resources/jobs/client/Client.ts b/src/api/resources/jobs/client/Client.ts new file mode 100644 index 00000000..80585eeb --- /dev/null +++ b/src/api/resources/jobs/client/Client.ts @@ -0,0 +1,101 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; + +export declare namespace JobsClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * Everything about jobs + */ +export class JobsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: JobsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * Retrieve the status of job execution. + * + * @param {Intercom.JobsStatusRequest} request + * @param {JobsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.jobs.status({ + * job_id: "job_id" + * }) + */ + public status( + request: Intercom.JobsStatusRequest, + requestOptions?: JobsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__status(request, requestOptions)); + } + + private async __status( + request: Intercom.JobsStatusRequest, + requestOptions?: JobsClient.RequestOptions, + ): Promise> { + const { job_id: jobId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `jobs/status/${core.url.encodePathParam(jobId)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.Jobs, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/jobs/status/{job_id}"); + } +} diff --git a/src/api/resources/jobs/client/index.ts b/src/api/resources/jobs/client/index.ts new file mode 100644 index 00000000..195f9aa8 --- /dev/null +++ b/src/api/resources/jobs/client/index.ts @@ -0,0 +1 @@ +export * from "./requests/index.js"; diff --git a/src/api/resources/jobs/client/requests/JobsStatusRequest.ts b/src/api/resources/jobs/client/requests/JobsStatusRequest.ts new file mode 100644 index 00000000..d5971376 --- /dev/null +++ b/src/api/resources/jobs/client/requests/JobsStatusRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * job_id: "job_id" + * } + */ +export interface JobsStatusRequest { + /** The unique identifier for the job which is given by Intercom */ + job_id: string; +} diff --git a/src/api/resources/jobs/client/requests/index.ts b/src/api/resources/jobs/client/requests/index.ts new file mode 100644 index 00000000..bfed16f9 --- /dev/null +++ b/src/api/resources/jobs/client/requests/index.ts @@ -0,0 +1 @@ +export type { JobsStatusRequest } from "./JobsStatusRequest.js"; diff --git a/src/api/resources/jobs/index.ts b/src/api/resources/jobs/index.ts new file mode 100644 index 00000000..d9adb1af --- /dev/null +++ b/src/api/resources/jobs/index.ts @@ -0,0 +1,2 @@ +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/jobs/types/Jobs.ts b/src/api/resources/jobs/types/Jobs.ts new file mode 100644 index 00000000..c3e63585 --- /dev/null +++ b/src/api/resources/jobs/types/Jobs.ts @@ -0,0 +1,31 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Jobs are tasks that are processed asynchronously by the Intercom system after being enqueued via the API. This allows for efficient handling of operations that may take time to complete, such as data imports or exports. You can check the status of your jobs to monitor their progress and ensure they are completed successfully. + */ +export interface Jobs { + /** The type of the object */ + type?: "job"; + /** The id of the job that's currently being processed or has completed. */ + id: string; + /** API endpoint URL to check the job status. */ + url?: string; + /** The status of the job execution. */ + status?: Jobs.Status; + /** The type of resource created during job execution. */ + resource_type?: string; + /** The id of the resource created during job execution (e.g. ticket id) */ + resource_id?: string; + /** The url of the resource created during job exeuction. Use this url to fetch the resource. */ + resource_url?: string; +} + +export namespace Jobs { + /** The status of the job execution. */ + export const Status = { + Pending: "pending", + Success: "success", + Failed: "failed", + } as const; + export type Status = (typeof Status)[keyof typeof Status]; +} diff --git a/src/api/resources/jobs/types/index.ts b/src/api/resources/jobs/types/index.ts new file mode 100644 index 00000000..c4ca9992 --- /dev/null +++ b/src/api/resources/jobs/types/index.ts @@ -0,0 +1 @@ +export * from "./Jobs.js"; diff --git a/src/api/resources/messages/client/Client.ts b/src/api/resources/messages/client/Client.ts index 9fd4d027..f4b5d54c 100644 --- a/src/api/resources/messages/client/Client.ts +++ b/src/api/resources/messages/client/Client.ts @@ -1,79 +1,29 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace Messages { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace MessagesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your messages */ -export class Messages { - constructor(protected readonly _options: Messages.Options = {}) {} +export class MessagesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: MessagesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can create a message that has been initiated by an admin. The conversation can be either an in-app message or an email. @@ -89,7 +39,7 @@ export class Messages { * > As this is a message, there will be no conversation present until the contact responds. Once they do, you will have to search for a contact's conversations with the id of the message. * * @param {Intercom.CreateMessageRequest} request - * @param {Messages.RequestOptions} requestOptions - Request-specific configuration. + * @param {MessagesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.BadRequestError} * @throws {@link Intercom.UnauthorizedError} @@ -124,7 +74,7 @@ export class Messages { * }, * to: { * type: "user", - * id: "667d616d8a68186f43bafe53" + * id: "6762f23b1bb69f9f2193bc1a" * }, * created_at: 1590000000, * create_conversation_without_contact_reply: true @@ -160,48 +110,48 @@ export class Messages { * }, * to: { * type: "user", - * id: "667d616e8a68186f43bafe55" + * id: "6762f23d1bb69f9f2193bc1c" * }, * created_at: 1590000000, * create_conversation_without_contact_reply: true * }) */ public create( - request: Intercom.CreateMessageRequest, - requestOptions?: Messages.RequestOptions, + request?: Intercom.CreateMessageRequest, + requestOptions?: MessagesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( - request: Intercom.CreateMessageRequest, - requestOptions?: Messages.RequestOptions, + request?: Intercom.CreateMessageRequest, + requestOptions?: MessagesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "messages", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", - body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + body: request != null ? request : undefined, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Message, rawResponse: _response.rawResponse }; @@ -229,32 +179,6 @@ export class Messages { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /messages."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/messages"); } } diff --git a/src/api/resources/messages/index.ts b/src/api/resources/messages/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/messages/index.ts +++ b/src/api/resources/messages/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/messages/types/Message.ts b/src/api/resources/messages/types/Message.ts index d8bd0388..a2f8aa46 100644 --- a/src/api/resources/messages/types/Message.ts +++ b/src/api/resources/messages/types/Message.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Message are how you reach out to contacts in Intercom. They are created when an admin sends an outbound message to a contact. @@ -13,24 +11,22 @@ export interface Message { /** The time the conversation was created. */ created_at: number; /** The subject of the message. Only present if message_type: email. */ - subject: string; + subject?: string; /** The message body, which may contain HTML. */ body: string; /** The type of message that was sent. Can be email, inapp, facebook or twitter. */ message_type: Message.MessageType; /** The associated conversation_id */ - conversation_id: string; + conversation_id?: string; } export namespace Message { - /** - * The type of message that was sent. Can be email, inapp, facebook or twitter. - */ - export type MessageType = "email" | "inapp" | "facebook" | "twitter"; + /** The type of message that was sent. Can be email, inapp, facebook or twitter. */ export const MessageType = { Email: "email", Inapp: "inapp", Facebook: "facebook", Twitter: "twitter", } as const; + export type MessageType = (typeof MessageType)[keyof typeof MessageType]; } diff --git a/src/api/resources/messages/types/index.ts b/src/api/resources/messages/types/index.ts index 6596816a..e16d36b7 100644 --- a/src/api/resources/messages/types/index.ts +++ b/src/api/resources/messages/types/index.ts @@ -1 +1 @@ -export * from "./Message"; +export * from "./Message.js"; diff --git a/src/api/resources/news/client/Client.ts b/src/api/resources/news/client/Client.ts index 2b6dd6ab..65efc563 100644 --- a/src/api/resources/news/client/Client.ts +++ b/src/api/resources/news/client/Client.ts @@ -1,53 +1,28 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import { Items } from "../resources/items/client/Client"; -import { Feeds } from "../resources/feeds/client/Client"; +import type { BaseClientOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { FeedsClient } from "../resources/feeds/client/Client.js"; +import { ItemsClient } from "../resources/items/client/Client.js"; -export declare namespace News { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace NewsClient { + export interface Options extends BaseClientOptions {} } -export class News { - protected _items: Items | undefined; - protected _feeds: Feeds | undefined; +export class NewsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + protected _items: ItemsClient | undefined; + protected _feeds: FeedsClient | undefined; - constructor(protected readonly _options: News.Options = {}) {} + constructor(options: NewsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } - public get items(): Items { - return (this._items ??= new Items(this._options)); + public get items(): ItemsClient { + return (this._items ??= new ItemsClient(this._options)); } - public get feeds(): Feeds { - return (this._feeds ??= new Feeds(this._options)); + public get feeds(): FeedsClient { + return (this._feeds ??= new FeedsClient(this._options)); } } diff --git a/src/api/resources/news/index.ts b/src/api/resources/news/index.ts index 848e75ab..0ef16e76 100644 --- a/src/api/resources/news/index.ts +++ b/src/api/resources/news/index.ts @@ -1,3 +1,3 @@ -export * from "./types"; -export * from "./client"; -export * from "./resources"; +export * from "./client/index.js"; +export * from "./resources/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/news/resources/feeds/client/Client.ts b/src/api/resources/news/resources/feeds/client/Client.ts index 7af908b2..b3c72e7d 100644 --- a/src/api/resources/news/resources/feeds/client/Client.ts +++ b/src/api/resources/news/resources/feeds/client/Client.ts @@ -1,82 +1,32 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Feeds { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace FeedsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } -export class Feeds { - constructor(protected readonly _options: Feeds.Options = {}) {} +export class FeedsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: FeedsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of all news items that are live on a given newsfeed * * @param {Intercom.news.ListNewsFeedItemsRequest} request - * @param {Feeds.RequestOptions} requestOptions - Request-specific configuration. + * @param {FeedsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -87,43 +37,41 @@ export class Feeds { */ public listItems( request: Intercom.news.ListNewsFeedItemsRequest, - requestOptions?: Feeds.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: FeedsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listItems(request, requestOptions)); } private async __listItems( request: Intercom.news.ListNewsFeedItemsRequest, - requestOptions?: Feeds.RequestOptions, - ): Promise> { + requestOptions?: FeedsClient.RequestOptions, + ): Promise> { const { newsfeed_id: newsfeedId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/newsfeeds/${encodeURIComponent(newsfeedId)}/items`, + `news/newsfeeds/${core.url.encodePathParam(newsfeedId)}/items`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.PaginatedNewsItemResponse, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.PaginatedResponse, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -142,69 +90,56 @@ export class Feeds { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /news/newsfeeds/{newsfeed_id}/items.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/news/newsfeeds/{newsfeed_id}/items", + ); } /** * You can fetch a list of all newsfeeds * - * @param {Feeds.RequestOptions} requestOptions - Request-specific configuration. + * @param {FeedsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * * @example * await client.news.feeds.list() */ - public list(requestOptions?: Feeds.RequestOptions): core.HttpResponsePromise { + public list(requestOptions?: FeedsClient.RequestOptions): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__list(requestOptions)); } private async __list( - requestOptions?: Feeds.RequestOptions, - ): Promise> { + requestOptions?: FeedsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "news/newsfeeds", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.PaginatedNewsfeedResponse, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.PaginatedResponse, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -223,28 +158,14 @@ export class Feeds { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/newsfeeds."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/news/newsfeeds"); } /** * You can fetch the details of a single newsfeed * * @param {Intercom.news.FindNewsFeedRequest} request - * @param {Feeds.RequestOptions} requestOptions - Request-specific configuration. + * @param {FeedsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -255,40 +176,38 @@ export class Feeds { */ public find( request: Intercom.news.FindNewsFeedRequest, - requestOptions?: Feeds.RequestOptions, + requestOptions?: FeedsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.news.FindNewsFeedRequest, - requestOptions?: Feeds.RequestOptions, + requestOptions?: FeedsClient.RequestOptions, ): Promise> { const { newsfeed_id: newsfeedId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/newsfeeds/${encodeURIComponent(newsfeedId)}`, + `news/newsfeeds/${core.url.encodePathParam(newsfeedId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Newsfeed, rawResponse: _response.rawResponse }; @@ -310,34 +229,6 @@ export class Feeds { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /news/newsfeeds/{newsfeed_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/news/newsfeeds/{newsfeed_id}"); } } diff --git a/src/api/resources/news/resources/feeds/client/index.ts b/src/api/resources/news/resources/feeds/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/news/resources/feeds/client/index.ts +++ b/src/api/resources/news/resources/feeds/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/news/resources/feeds/client/requests/FindNewsFeedRequest.ts b/src/api/resources/news/resources/feeds/client/requests/FindNewsFeedRequest.ts index 4882b9d2..a462c8d7 100644 --- a/src/api/resources/news/resources/feeds/client/requests/FindNewsFeedRequest.ts +++ b/src/api/resources/news/resources/feeds/client/requests/FindNewsFeedRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface FindNewsFeedRequest { - /** - * The unique identifier for the news feed item which is given by Intercom. - */ + /** The unique identifier for the news feed item which is given by Intercom. */ newsfeed_id: string; } diff --git a/src/api/resources/news/resources/feeds/client/requests/ListNewsFeedItemsRequest.ts b/src/api/resources/news/resources/feeds/client/requests/ListNewsFeedItemsRequest.ts index 209d86cc..5847e03b 100644 --- a/src/api/resources/news/resources/feeds/client/requests/ListNewsFeedItemsRequest.ts +++ b/src/api/resources/news/resources/feeds/client/requests/ListNewsFeedItemsRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ListNewsFeedItemsRequest { - /** - * The unique identifier for the news feed item which is given by Intercom. - */ + /** The unique identifier for the news feed item which is given by Intercom. */ newsfeed_id: string; } diff --git a/src/api/resources/news/resources/feeds/client/requests/index.ts b/src/api/resources/news/resources/feeds/client/requests/index.ts index 0d025c4f..c32a3ad5 100644 --- a/src/api/resources/news/resources/feeds/client/requests/index.ts +++ b/src/api/resources/news/resources/feeds/client/requests/index.ts @@ -1,2 +1,2 @@ -export { type ListNewsFeedItemsRequest } from "./ListNewsFeedItemsRequest"; -export { type FindNewsFeedRequest } from "./FindNewsFeedRequest"; +export type { FindNewsFeedRequest } from "./FindNewsFeedRequest.js"; +export type { ListNewsFeedItemsRequest } from "./ListNewsFeedItemsRequest.js"; diff --git a/src/api/resources/news/resources/feeds/index.ts b/src/api/resources/news/resources/feeds/index.ts index 5ec76921..914b8c3c 100644 --- a/src/api/resources/news/resources/feeds/index.ts +++ b/src/api/resources/news/resources/feeds/index.ts @@ -1 +1 @@ -export * from "./client"; +export * from "./client/index.js"; diff --git a/src/api/resources/news/resources/index.ts b/src/api/resources/news/resources/index.ts index bab08c4a..631ce9c7 100644 --- a/src/api/resources/news/resources/index.ts +++ b/src/api/resources/news/resources/index.ts @@ -1,4 +1,4 @@ -export * as items from "./items"; -export * as feeds from "./feeds"; -export * from "./items/client/requests"; -export * from "./feeds/client/requests"; +export * from "./feeds/client/requests/index.js"; +export * as feeds from "./feeds/index.js"; +export * from "./items/client/requests/index.js"; +export * as items from "./items/index.js"; diff --git a/src/api/resources/news/resources/items/client/Client.ts b/src/api/resources/news/resources/items/client/Client.ts index 2dc9fa97..96910a6b 100644 --- a/src/api/resources/news/resources/items/client/Client.ts +++ b/src/api/resources/news/resources/items/client/Client.ts @@ -1,121 +1,69 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Items { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace ItemsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } -export class Items { - constructor(protected readonly _options: Items.Options = {}) {} +export class ItemsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: ItemsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of all news items * - * @param {Items.RequestOptions} requestOptions - Request-specific configuration. + * @param {ItemsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * * @example * await client.news.items.list() */ - public list(requestOptions?: Items.RequestOptions): core.HttpResponsePromise { + public list(requestOptions?: ItemsClient.RequestOptions): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__list(requestOptions)); } private async __list( - requestOptions?: Items.RequestOptions, - ): Promise> { + requestOptions?: ItemsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "news/news_items", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.PaginatedNewsItemResponse, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.PaginatedResponse, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -134,28 +82,14 @@ export class Items { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/news_items."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/news/news_items"); } /** * You can create a news item * * @param {Intercom.NewsItemRequest} request - * @param {Items.RequestOptions} requestOptions - Request-specific configuration. + * @param {ItemsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -163,7 +97,7 @@ export class Items { * await client.news.items.create({ * title: "Halloween is here!", * body: "

New costumes in store for this spooky season

", - * sender_id: 991267734, + * sender_id: 991267834, * state: "live", * deliver_silently: true, * labels: ["Product", "Update", "New"], @@ -176,40 +110,40 @@ export class Items { */ public create( request: Intercom.NewsItemRequest, - requestOptions?: Items.RequestOptions, + requestOptions?: ItemsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( request: Intercom.NewsItemRequest, - requestOptions?: Items.RequestOptions, + requestOptions?: ItemsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "news/news_items", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.NewsItem, rawResponse: _response.rawResponse }; @@ -231,73 +165,57 @@ export class Items { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /news/news_items."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/news/news_items"); } /** * You can fetch the details of a single news item. * * @param {Intercom.news.FindNewsItemRequest} request - * @param {Items.RequestOptions} requestOptions - Request-specific configuration. + * @param {ItemsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.news.items.find({ - * news_item_id: "123" + * news_item_id: 1 * }) */ public find( request: Intercom.news.FindNewsItemRequest, - requestOptions?: Items.RequestOptions, + requestOptions?: ItemsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.news.FindNewsItemRequest, - requestOptions?: Items.RequestOptions, + requestOptions?: ItemsClient.RequestOptions, ): Promise> { const { news_item_id: newsItemId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/news_items/${encodeURIComponent(newsItemId)}`, + `news/news_items/${core.url.encodePathParam(newsItemId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.NewsItem, rawResponse: _response.rawResponse }; @@ -321,91 +239,80 @@ export class Items { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /news/news_items/{news_item_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/news/news_items/{news_item_id}", + ); } /** * @param {Intercom.news.UpdateNewsItemRequest} request - * @param {Items.RequestOptions} requestOptions - Request-specific configuration. + * @param {ItemsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.news.items.update({ - * news_item_id: "123", + * news_item_id: 1, * body: { * title: "Christmas is here!", * body: "

New gifts in store for the jolly season

", - * sender_id: 991267745, + * sender_id: 991267845, * reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"] * } * }) * * @example * await client.news.items.update({ - * news_item_id: "123", + * news_item_id: 1, * body: { * title: "Christmas is here!", * body: "

New gifts in store for the jolly season

", - * sender_id: 991267748, + * sender_id: 991267848, * reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"] * } * }) */ public update( request: Intercom.news.UpdateNewsItemRequest, - requestOptions?: Items.RequestOptions, + requestOptions?: ItemsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); } private async __update( request: Intercom.news.UpdateNewsItemRequest, - requestOptions?: Items.RequestOptions, + requestOptions?: ItemsClient.RequestOptions, ): Promise> { const { news_item_id: newsItemId, body: _body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/news_items/${encodeURIComponent(newsItemId)}`, + `news/news_items/${core.url.encodePathParam(newsItemId)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.NewsItem, rawResponse: _response.rawResponse }; @@ -429,75 +336,62 @@ export class Items { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /news/news_items/{news_item_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "PUT", + "/news/news_items/{news_item_id}", + ); } /** * You can delete a single news item. * * @param {Intercom.news.DeleteNewsItemRequest} request - * @param {Items.RequestOptions} requestOptions - Request-specific configuration. + * @param {ItemsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.news.items.delete({ - * news_item_id: "123" + * news_item_id: 1 * }) */ public delete( request: Intercom.news.DeleteNewsItemRequest, - requestOptions?: Items.RequestOptions, + requestOptions?: ItemsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__delete(request, requestOptions)); } private async __delete( request: Intercom.news.DeleteNewsItemRequest, - requestOptions?: Items.RequestOptions, + requestOptions?: ItemsClient.RequestOptions, ): Promise> { const { news_item_id: newsItemId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/news_items/${encodeURIComponent(newsItemId)}`, + `news/news_items/${core.url.encodePathParam(newsItemId)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.DeletedObject, rawResponse: _response.rawResponse }; @@ -521,34 +415,11 @@ export class Items { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /news/news_items/{news_item_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/news/news_items/{news_item_id}", + ); } } diff --git a/src/api/resources/news/resources/items/client/index.ts b/src/api/resources/news/resources/items/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/news/resources/items/client/index.ts +++ b/src/api/resources/news/resources/items/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/news/resources/items/client/requests/DeleteNewsItemRequest.ts b/src/api/resources/news/resources/items/client/requests/DeleteNewsItemRequest.ts index 9fc8094b..87c64a80 100644 --- a/src/api/resources/news/resources/items/client/requests/DeleteNewsItemRequest.ts +++ b/src/api/resources/news/resources/items/client/requests/DeleteNewsItemRequest.ts @@ -1,16 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * news_item_id: "123" + * news_item_id: 1 * } */ export interface DeleteNewsItemRequest { - /** - * The unique identifier for the news item which is given by Intercom. - */ - news_item_id: string; + /** The unique identifier for the news item which is given by Intercom. */ + news_item_id: number; } diff --git a/src/api/resources/news/resources/items/client/requests/FindNewsItemRequest.ts b/src/api/resources/news/resources/items/client/requests/FindNewsItemRequest.ts index d727fbdb..6e8e5ac2 100644 --- a/src/api/resources/news/resources/items/client/requests/FindNewsItemRequest.ts +++ b/src/api/resources/news/resources/items/client/requests/FindNewsItemRequest.ts @@ -1,16 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * news_item_id: "123" + * news_item_id: 1 * } */ export interface FindNewsItemRequest { - /** - * The unique identifier for the news item which is given by Intercom. - */ - news_item_id: string; + /** The unique identifier for the news item which is given by Intercom. */ + news_item_id: number; } diff --git a/src/api/resources/news/resources/items/client/requests/UpdateNewsItemRequest.ts b/src/api/resources/news/resources/items/client/requests/UpdateNewsItemRequest.ts index ec976bc2..948351c3 100644 --- a/src/api/resources/news/resources/items/client/requests/UpdateNewsItemRequest.ts +++ b/src/api/resources/news/resources/items/client/requests/UpdateNewsItemRequest.ts @@ -1,36 +1,32 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example * { - * news_item_id: "123", + * news_item_id: 1, * body: { * title: "Christmas is here!", * body: "

New gifts in store for the jolly season

", - * sender_id: 991267745, + * sender_id: 991267845, * reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"] * } * } * * @example * { - * news_item_id: "123", + * news_item_id: 1, * body: { * title: "Christmas is here!", * body: "

New gifts in store for the jolly season

", - * sender_id: 991267748, + * sender_id: 991267848, * reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"] * } * } */ export interface UpdateNewsItemRequest { - /** - * The unique identifier for the news item which is given by Intercom. - */ - news_item_id: string; + /** The unique identifier for the news item which is given by Intercom. */ + news_item_id: number; body: Intercom.NewsItemRequest; } diff --git a/src/api/resources/news/resources/items/client/requests/index.ts b/src/api/resources/news/resources/items/client/requests/index.ts index 0ae128c3..3869d0b3 100644 --- a/src/api/resources/news/resources/items/client/requests/index.ts +++ b/src/api/resources/news/resources/items/client/requests/index.ts @@ -1,3 +1,3 @@ -export { type FindNewsItemRequest } from "./FindNewsItemRequest"; -export { type UpdateNewsItemRequest } from "./UpdateNewsItemRequest"; -export { type DeleteNewsItemRequest } from "./DeleteNewsItemRequest"; +export type { DeleteNewsItemRequest } from "./DeleteNewsItemRequest.js"; +export type { FindNewsItemRequest } from "./FindNewsItemRequest.js"; +export type { UpdateNewsItemRequest } from "./UpdateNewsItemRequest.js"; diff --git a/src/api/resources/news/resources/items/index.ts b/src/api/resources/news/resources/items/index.ts index 5ec76921..914b8c3c 100644 --- a/src/api/resources/news/resources/items/index.ts +++ b/src/api/resources/news/resources/items/index.ts @@ -1 +1 @@ -export * from "./client"; +export * from "./client/index.js"; diff --git a/src/api/resources/news/types/NewsItem.ts b/src/api/resources/news/types/NewsItem.ts index 2addce53..7ae7b3f9 100644 --- a/src/api/resources/news/types/NewsItem.ts +++ b/src/api/resources/news/types/NewsItem.ts @@ -1,27 +1,25 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A News Item is a content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers. */ export interface NewsItem { /** The type of object. */ - type: "news-item"; + type?: "news-item"; /** The unique identifier for the news item which is given by Intercom. */ - id: string; + id?: string; /** The id of the workspace which the news item belongs to. */ - workspace_id: string; + workspace_id?: string; /** The title of the news item. */ - title: string; + title?: string; /** The news item body, which may contain HTML. */ - body: string; + body?: string; /** The id of the sender of the news item. Must be a teammate on the workspace. */ - sender_id: number; + sender_id?: number; /** News items will not be visible to your users in the assigned newsfeeds until they are set live. */ - state: NewsItem.State; + state?: NewsItem.State; /** A list of newsfeed_assignments to assign to the specified newsfeed. */ newsfeed_assignments?: Intercom.NewsfeedAssignment[]; /** Label names displayed to users to categorize the news item. */ @@ -33,18 +31,16 @@ export interface NewsItem { /** When set to true, the news item will appear in the messenger newsfeed without showing a notification badge. */ deliver_silently?: boolean; /** Timestamp for when the news item was created. */ - created_at: number; + created_at?: number; /** Timestamp for when the news item was last updated. */ updated_at?: number; } export namespace NewsItem { - /** - * News items will not be visible to your users in the assigned newsfeeds until they are set live. - */ - export type State = "draft" | "live"; + /** News items will not be visible to your users in the assigned newsfeeds until they are set live. */ export const State = { Draft: "draft", Live: "live", } as const; + export type State = (typeof State)[keyof typeof State]; } diff --git a/src/api/resources/news/types/Newsfeed.ts b/src/api/resources/news/types/Newsfeed.ts index a20a9016..a42f6306 100644 --- a/src/api/resources/news/types/Newsfeed.ts +++ b/src/api/resources/news/types/Newsfeed.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A newsfeed is a collection of news items, targeted to a specific audience. @@ -9,13 +7,13 @@ */ export interface Newsfeed { /** The unique identifier for the newsfeed which is given by Intercom. */ - id: string; + id?: string; /** The type of object. */ - type: "newsfeed"; + type?: "newsfeed"; /** The name of the newsfeed. This name will never be visible to your users. */ - name: string; + name?: string; /** Timestamp for when the newsfeed was created. */ - created_at: number; + created_at?: number; /** Timestamp for when the newsfeed was last updated. */ updated_at?: number; } diff --git a/src/api/resources/news/types/NewsfeedAssignment.ts b/src/api/resources/news/types/NewsfeedAssignment.ts index 80447b20..064483c9 100644 --- a/src/api/resources/news/types/NewsfeedAssignment.ts +++ b/src/api/resources/news/types/NewsfeedAssignment.ts @@ -1,13 +1,11 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Assigns a news item to a newsfeed. */ export interface NewsfeedAssignment { /** The unique identifier for the newsfeed which is given by Intercom. Publish dates cannot be in the future, to schedule news items use the dedicated feature in app (see this article). */ - newsfeed_id: number; + newsfeed_id?: number; /** Publish date of the news item on the newsfeed, use this field if you want to set a publish date in the past (e.g. when importing existing news items). On write, this field will be ignored if the news item state is "draft". */ - published_at: number; + published_at?: number; } diff --git a/src/api/resources/news/types/index.ts b/src/api/resources/news/types/index.ts index b8c22f3c..fe7a29c8 100644 --- a/src/api/resources/news/types/index.ts +++ b/src/api/resources/news/types/index.ts @@ -1,3 +1,3 @@ -export * from "./NewsItem"; -export * from "./Newsfeed"; -export * from "./NewsfeedAssignment"; +export * from "./Newsfeed.js"; +export * from "./NewsfeedAssignment.js"; +export * from "./NewsItem.js"; diff --git a/src/api/resources/notes/client/Client.ts b/src/api/resources/notes/client/Client.ts index 44866b02..da58ae5d 100644 --- a/src/api/resources/notes/client/Client.ts +++ b/src/api/resources/notes/client/Client.ts @@ -1,85 +1,35 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace Notes { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace NotesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Notes */ -export class Notes { - constructor(protected readonly _options: Notes.Options = {}) {} +export class NotesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: NotesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of notes that are associated to a contact. * * @param {Intercom.ListContactNotesRequest} request - * @param {Notes.RequestOptions} requestOptions - Request-specific configuration. + * @param {NotesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.NotFoundError} * @@ -90,44 +40,40 @@ export class Notes { */ public async list( request: Intercom.ListContactNotesRequest, - requestOptions?: Notes.RequestOptions, - ): Promise> { + requestOptions?: NotesClient.RequestOptions, + ): Promise> { const list = core.HttpResponsePromise.interceptFunction( async (request: Intercom.ListContactNotesRequest): Promise> => { const { contact_id: contactId, page, per_page: perPage } = request; const _queryParams: Record = {}; if (page != null) { - _queryParams["page"] = page.toString(); + _queryParams.page = page.toString(); } if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); + _queryParams.per_page = perPage.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/notes`, + `contacts/${core.url.encodePathParam(contactId)}/notes`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: - requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.NoteList, rawResponse: _response.rawResponse }; @@ -144,28 +90,17 @@ export class Notes { }); } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /contacts/{contact_id}/notes.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/contacts/{contact_id}/notes", + ); }, ); let _offset = request?.page != null ? request?.page : 1; const dataWithRawResponse = await list(request).withRawResponse(); - return new core.Pageable({ + return new core.Page({ response: dataWithRawResponse.data, rawResponse: dataWithRawResponse.rawResponse, hasNextPage: (response) => (response?.data ?? []).length > 0, @@ -181,7 +116,7 @@ export class Notes { * You can add a note to a single contact. * * @param {Intercom.CreateContactNoteRequest} request - * @param {Notes.RequestOptions} requestOptions - Request-specific configuration. + * @param {NotesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.NotFoundError} * @@ -194,41 +129,41 @@ export class Notes { */ public create( request: Intercom.CreateContactNoteRequest, - requestOptions?: Notes.RequestOptions, + requestOptions?: NotesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( request: Intercom.CreateContactNoteRequest, - requestOptions?: Notes.RequestOptions, + requestOptions?: NotesClient.RequestOptions, ): Promise> { const { contact_id: contactId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/notes`, + `contacts/${core.url.encodePathParam(contactId)}/notes`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Note, rawResponse: _response.rawResponse }; @@ -247,75 +182,57 @@ export class Notes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /contacts/{contact_id}/notes.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts/{contact_id}/notes"); } /** * You can fetch the details of a single note. * * @param {Intercom.FindNoteRequest} request - * @param {Notes.RequestOptions} requestOptions - Request-specific configuration. + * @param {NotesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.notes.find({ - * note_id: "1" + * note_id: 1 * }) */ public find( request: Intercom.FindNoteRequest, - requestOptions?: Notes.RequestOptions, + requestOptions?: NotesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.FindNoteRequest, - requestOptions?: Notes.RequestOptions, + requestOptions?: NotesClient.RequestOptions, ): Promise> { const { note_id: noteId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `notes/${encodeURIComponent(noteId)}`, + `notes/${core.url.encodePathParam(noteId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Note, rawResponse: _response.rawResponse }; @@ -339,32 +256,6 @@ export class Notes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /notes/{note_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/notes/{note_id}"); } } diff --git a/src/api/resources/notes/client/index.ts b/src/api/resources/notes/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/notes/client/index.ts +++ b/src/api/resources/notes/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/notes/client/requests/CreateContactNoteRequest.ts b/src/api/resources/notes/client/requests/CreateContactNoteRequest.ts index 1cadbe4a..bff219f9 100644 --- a/src/api/resources/notes/client/requests/CreateContactNoteRequest.ts +++ b/src/api/resources/notes/client/requests/CreateContactNoteRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -25,9 +23,7 @@ * } */ export interface CreateContactNoteRequest { - /** - * The unique identifier of a given contact. - */ + /** The unique identifier of a given contact. */ contact_id: string; /** The text of the note. */ body: string; diff --git a/src/api/resources/notes/client/requests/FindNoteRequest.ts b/src/api/resources/notes/client/requests/FindNoteRequest.ts index 35bff5e2..c7efb6a9 100644 --- a/src/api/resources/notes/client/requests/FindNoteRequest.ts +++ b/src/api/resources/notes/client/requests/FindNoteRequest.ts @@ -1,16 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * note_id: "1" + * note_id: 1 * } */ export interface FindNoteRequest { - /** - * The unique identifier of a given note - */ - note_id: string; + /** The unique identifier of a given note */ + note_id: number; } diff --git a/src/api/resources/notes/client/requests/ListContactNotesRequest.ts b/src/api/resources/notes/client/requests/ListContactNotesRequest.ts index 1c8b5763..49b13673 100644 --- a/src/api/resources/notes/client/requests/ListContactNotesRequest.ts +++ b/src/api/resources/notes/client/requests/ListContactNotesRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,16 +7,10 @@ * } */ export interface ListContactNotesRequest { - /** - * The unique identifier of a contact. - */ + /** The unique identifier of a contact. */ contact_id: string; - /** - * The page of results to fetch. Defaults to first page - */ + /** The page of results to fetch. Defaults to first page */ page?: number; - /** - * How many results to display per page. Defaults to 15 - */ + /** How many results to display per page. Defaults to 15 */ per_page?: number; } diff --git a/src/api/resources/notes/client/requests/index.ts b/src/api/resources/notes/client/requests/index.ts index 6271b2a9..d6e2648b 100644 --- a/src/api/resources/notes/client/requests/index.ts +++ b/src/api/resources/notes/client/requests/index.ts @@ -1,3 +1,3 @@ -export { type ListContactNotesRequest } from "./ListContactNotesRequest"; -export { type CreateContactNoteRequest } from "./CreateContactNoteRequest"; -export { type FindNoteRequest } from "./FindNoteRequest"; +export type { CreateContactNoteRequest } from "./CreateContactNoteRequest.js"; +export type { FindNoteRequest } from "./FindNoteRequest.js"; +export type { ListContactNotesRequest } from "./ListContactNotesRequest.js"; diff --git a/src/api/resources/notes/index.ts b/src/api/resources/notes/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/notes/index.ts +++ b/src/api/resources/notes/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/notes/types/Note.ts b/src/api/resources/notes/types/Note.ts index a2b2345d..e22e0eb3 100644 --- a/src/api/resources/notes/types/Note.ts +++ b/src/api/resources/notes/types/Note.ts @@ -1,25 +1,23 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Notes allow you to annotate and comment on your contacts. */ export interface Note { /** String representing the object's type. Always has the value `note`. */ - type: "note"; + type?: string; /** The id of the note. */ - id: string; + id?: string; /** The time the note was created. */ - created_at: number; + created_at?: number; /** Represents the contact that the note was created about. */ contact?: Note.Contact; /** Optional. Represents the Admin that created the note. */ - author: Intercom.Admin; + author?: Intercom.Admin; /** The body text of the note. */ - body: string; + body?: string; } export namespace Note { @@ -28,7 +26,7 @@ export namespace Note { */ export interface Contact { /** String representing the object's type. Always has the value `contact`. */ - type?: "contact"; + type?: string; /** The id of the contact. */ id?: string; } diff --git a/src/api/resources/notes/types/index.ts b/src/api/resources/notes/types/index.ts index cf881fa5..e0e2f407 100644 --- a/src/api/resources/notes/types/index.ts +++ b/src/api/resources/notes/types/index.ts @@ -1 +1 @@ -export * from "./Note"; +export * from "./Note.js"; diff --git a/src/api/resources/phoneCallRedirects/client/Client.ts b/src/api/resources/phoneCallRedirects/client/Client.ts index 2c057d93..e2585a9f 100644 --- a/src/api/resources/phoneCallRedirects/client/Client.ts +++ b/src/api/resources/phoneCallRedirects/client/Client.ts @@ -1,76 +1,26 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace PhoneCallRedirects { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace PhoneCallRedirectsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } -export class PhoneCallRedirects { - constructor(protected readonly _options: PhoneCallRedirects.Options = {}) {} +export class PhoneCallRedirectsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: PhoneCallRedirectsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can use the API to deflect phone calls to the Intercom Messenger. @@ -78,8 +28,8 @@ export class PhoneCallRedirects { * * If custom attributes are specified, they will be added to the user or lead's custom data attributes. * - * @param {Intercom.CreatePhoneCallRedirectRequest} request - * @param {PhoneCallRedirects.RequestOptions} requestOptions - Request-specific configuration. + * @param {Intercom.CreatePhoneSwitchRequest} request + * @param {PhoneCallRedirectsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.BadRequestError} * @throws {@link Intercom.UnauthorizedError} @@ -104,44 +54,44 @@ export class PhoneCallRedirects { * }) */ public create( - request: Intercom.CreatePhoneCallRedirectRequest, - requestOptions?: PhoneCallRedirects.RequestOptions, - ): core.HttpResponsePromise { + request?: Intercom.CreatePhoneSwitchRequest, + requestOptions?: PhoneCallRedirectsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( - request: Intercom.CreatePhoneCallRedirectRequest, - requestOptions?: PhoneCallRedirects.RequestOptions, - ): Promise> { + request?: Intercom.CreatePhoneSwitchRequest, + requestOptions?: PhoneCallRedirectsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "phone_call_redirects", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", - body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + body: request != null ? request : undefined, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.PhoneSwitch, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.PhoneSwitch | undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -164,32 +114,6 @@ export class PhoneCallRedirects { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /phone_call_redirects."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/phone_call_redirects"); } } diff --git a/src/api/resources/phoneCallRedirects/client/index.ts b/src/api/resources/phoneCallRedirects/client/index.ts index 415726b7..cb0ff5c3 100644 --- a/src/api/resources/phoneCallRedirects/client/index.ts +++ b/src/api/resources/phoneCallRedirects/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export {}; diff --git a/src/api/resources/phoneCallRedirects/client/requests/CreatePhoneCallRedirectRequest.ts b/src/api/resources/phoneCallRedirects/client/requests/CreatePhoneCallRedirectRequest.ts deleted file mode 100644 index 3b19efc3..00000000 --- a/src/api/resources/phoneCallRedirects/client/requests/CreatePhoneCallRedirectRequest.ts +++ /dev/null @@ -1,48 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../../../../index"; - -/** - * @example - * { - * phone: "+353832345678", - * custom_attributes: { - * "issue_type": "Billing", - * "priority": "High" - * } - * } - * - * @example - * { - * phone: "+353832345678", - * custom_attributes: { - * "issue_type": "Billing", - * "priority": "High" - * } - * } - * - * @example - * { - * phone: "+353832345678", - * custom_attributes: { - * "issue_type": "Billing", - * "priority": "High" - * } - * } - * - * @example - * { - * phone: "+40241100100", - * custom_attributes: { - * "issue_type": "Billing", - * "priority": "High" - * } - * } - */ -export interface CreatePhoneCallRedirectRequest { - /** Phone number in E.164 format, that will receive the SMS to continue the conversation in the Messenger. */ - phone: string; - custom_attributes?: Intercom.CustomAttributes; -} diff --git a/src/api/resources/phoneCallRedirects/client/requests/index.ts b/src/api/resources/phoneCallRedirects/client/requests/index.ts deleted file mode 100644 index 7038d703..00000000 --- a/src/api/resources/phoneCallRedirects/client/requests/index.ts +++ /dev/null @@ -1 +0,0 @@ -export { type CreatePhoneCallRedirectRequest } from "./CreatePhoneCallRedirectRequest"; diff --git a/src/api/resources/phoneCallRedirects/index.ts b/src/api/resources/phoneCallRedirects/index.ts index 5ec76921..914b8c3c 100644 --- a/src/api/resources/phoneCallRedirects/index.ts +++ b/src/api/resources/phoneCallRedirects/index.ts @@ -1 +1 @@ -export * from "./client"; +export * from "./client/index.js"; diff --git a/src/api/resources/segments/client/Client.ts b/src/api/resources/segments/client/Client.ts index 738a10b7..d7073779 100644 --- a/src/api/resources/segments/client/Client.ts +++ b/src/api/resources/segments/client/Client.ts @@ -1,133 +1,82 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace Segments { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace SegmentsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Segments */ -export class Segments { - constructor(protected readonly _options: Segments.Options = {}) {} +export class SegmentsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: SegmentsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of all segments. * * @param {Intercom.ListSegmentsRequest} request - * @param {Segments.RequestOptions} requestOptions - Request-specific configuration. + * @param {SegmentsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * * @example - * await client.segments.list() + * await client.segments.list({ + * include_count: true + * }) */ public list( request: Intercom.ListSegmentsRequest = {}, - requestOptions?: Segments.RequestOptions, + requestOptions?: SegmentsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__list(request, requestOptions)); } private async __list( request: Intercom.ListSegmentsRequest = {}, - requestOptions?: Segments.RequestOptions, + requestOptions?: SegmentsClient.RequestOptions, ): Promise> { const { include_count: includeCount } = request; const _queryParams: Record = {}; if (includeCount != null) { - _queryParams["include_count"] = includeCount.toString(); + _queryParams.include_count = includeCount.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "segments", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.SegmentList, rawResponse: _response.rawResponse }; @@ -149,28 +98,14 @@ export class Segments { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /segments."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/segments"); } /** * You can fetch the details of a single segment. * * @param {Intercom.FindSegmentRequest} request - * @param {Segments.RequestOptions} requestOptions - Request-specific configuration. + * @param {SegmentsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -182,40 +117,38 @@ export class Segments { */ public find( request: Intercom.FindSegmentRequest, - requestOptions?: Segments.RequestOptions, + requestOptions?: SegmentsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.FindSegmentRequest, - requestOptions?: Segments.RequestOptions, + requestOptions?: SegmentsClient.RequestOptions, ): Promise> { const { segment_id: segmentId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `segments/${encodeURIComponent(segmentId)}`, + `segments/${core.url.encodePathParam(segmentId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Segment, rawResponse: _response.rawResponse }; @@ -239,32 +172,6 @@ export class Segments { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /segments/{segment_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/segments/{segment_id}"); } } diff --git a/src/api/resources/segments/client/index.ts b/src/api/resources/segments/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/segments/client/index.ts +++ b/src/api/resources/segments/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/segments/client/requests/FindSegmentRequest.ts b/src/api/resources/segments/client/requests/FindSegmentRequest.ts index 0e0dff0b..eb150f95 100644 --- a/src/api/resources/segments/client/requests/FindSegmentRequest.ts +++ b/src/api/resources/segments/client/requests/FindSegmentRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface FindSegmentRequest { - /** - * The unique identified of a given segment. - */ + /** The unique identified of a given segment. */ segment_id: string; } diff --git a/src/api/resources/segments/client/requests/ListSegmentsRequest.ts b/src/api/resources/segments/client/requests/ListSegmentsRequest.ts index 116acd5e..7554f000 100644 --- a/src/api/resources/segments/client/requests/ListSegmentsRequest.ts +++ b/src/api/resources/segments/client/requests/ListSegmentsRequest.ts @@ -1,14 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example - * {} + * { + * include_count: true + * } */ export interface ListSegmentsRequest { - /** - * It includes the count of contacts that belong to each segment. - */ + /** It includes the count of contacts that belong to each segment. */ include_count?: boolean; } diff --git a/src/api/resources/segments/client/requests/index.ts b/src/api/resources/segments/client/requests/index.ts index a7d400d9..851720dd 100644 --- a/src/api/resources/segments/client/requests/index.ts +++ b/src/api/resources/segments/client/requests/index.ts @@ -1,2 +1,2 @@ -export { type ListSegmentsRequest } from "./ListSegmentsRequest"; -export { type FindSegmentRequest } from "./FindSegmentRequest"; +export type { FindSegmentRequest } from "./FindSegmentRequest.js"; +export type { ListSegmentsRequest } from "./ListSegmentsRequest.js"; diff --git a/src/api/resources/segments/index.ts b/src/api/resources/segments/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/segments/index.ts +++ b/src/api/resources/segments/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/segments/types/Segment.ts b/src/api/resources/segments/types/Segment.ts index 6612edb7..5fbb6b53 100644 --- a/src/api/resources/segments/types/Segment.ts +++ b/src/api/resources/segments/types/Segment.ts @@ -1,34 +1,30 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A segment is a group of your contacts defined by the rules that you set. */ export interface Segment { /** The type of object. */ - type: "segment"; + type?: "segment"; /** The unique identifier representing the segment. */ - id: string; + id?: string; /** The name of the segment. */ - name: string; + name?: string; /** The time the segment was created. */ - created_at: number; + created_at?: number; /** The time the segment was updated. */ updated_at?: number; /** Type of the contact: contact (lead) or user. */ - person_type: Segment.PersonType; + person_type?: Segment.PersonType; /** The number of items in the user segment. It's returned when `include_count=true` is included in the request. */ count?: number; } export namespace Segment { - /** - * Type of the contact: contact (lead) or user. - */ - export type PersonType = "contact" | "user"; + /** Type of the contact: contact (lead) or user. */ export const PersonType = { Contact: "contact", User: "user", } as const; + export type PersonType = (typeof PersonType)[keyof typeof PersonType]; } diff --git a/src/api/resources/segments/types/index.ts b/src/api/resources/segments/types/index.ts index 957aab14..a934b01a 100644 --- a/src/api/resources/segments/types/index.ts +++ b/src/api/resources/segments/types/index.ts @@ -1 +1 @@ -export * from "./Segment"; +export * from "./Segment.js"; diff --git a/src/api/resources/subscriptionTypes/client/Client.ts b/src/api/resources/subscriptionTypes/client/Client.ts index abfe8aa7..3f0c2673 100644 --- a/src/api/resources/subscriptionTypes/client/Client.ts +++ b/src/api/resources/subscriptionTypes/client/Client.ts @@ -1,84 +1,34 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace SubscriptionTypes { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace SubscriptionTypesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about subscription types */ -export class SubscriptionTypes { - constructor(protected readonly _options: SubscriptionTypes.Options = {}) {} +export class SubscriptionTypesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: SubscriptionTypesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can list all subscription types. A list of subscription type objects will be returned. * - * @param {SubscriptionTypes.RequestOptions} requestOptions - Request-specific configuration. + * @param {SubscriptionTypesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -86,38 +36,36 @@ export class SubscriptionTypes { * await client.subscriptionTypes.list() */ public list( - requestOptions?: SubscriptionTypes.RequestOptions, + requestOptions?: SubscriptionTypesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__list(requestOptions)); } private async __list( - requestOptions?: SubscriptionTypes.RequestOptions, + requestOptions?: SubscriptionTypesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "subscription_types", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.SubscriptionTypeList, rawResponse: _response.rawResponse }; @@ -139,32 +87,6 @@ export class SubscriptionTypes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /subscription_types."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/subscription_types"); } } diff --git a/src/api/resources/subscriptionTypes/index.ts b/src/api/resources/subscriptionTypes/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/subscriptionTypes/index.ts +++ b/src/api/resources/subscriptionTypes/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/subscriptionTypes/types/SubscriptionType.ts b/src/api/resources/subscriptionTypes/types/SubscriptionType.ts index fe1c68ff..55372879 100644 --- a/src/api/resources/subscriptionTypes/types/SubscriptionType.ts +++ b/src/api/resources/subscriptionTypes/types/SubscriptionType.ts @@ -1,53 +1,47 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A subscription type lets customers easily opt out of non-essential communications without missing what's important to them. */ export interface SubscriptionType { /** The type of the object - subscription */ - type: "subscription"; + type?: "subscription"; /** The unique identifier representing the subscription type. */ - id: string; + id?: string; /** The state of the subscription type. */ - state: SubscriptionType.State; - default_translation: Intercom.Translation; + state?: SubscriptionType.State; + default_translation?: Intercom.Translation; /** An array of translations objects with the localised version of the subscription type in each available locale within your translation settings. */ - translations: Intercom.Translation[]; + translations?: Intercom.Translation[]; /** Describes the type of consent. */ - consent_type: SubscriptionType.ConsentType; + consent_type?: SubscriptionType.ConsentType; /** The message types that this subscription supports - can contain `email` or `sms_message`. */ - content_types: SubscriptionType.ContentTypes.Item[]; + content_types?: SubscriptionType.ContentTypes.Item[]; } export namespace SubscriptionType { - /** - * The state of the subscription type. - */ - export type State = "live" | "draft" | "archived"; + /** The state of the subscription type. */ export const State = { Live: "live", Draft: "draft", Archived: "archived", } as const; - /** - * Describes the type of consent. - */ - export type ConsentType = "opt_out" | "opt_in"; + export type State = (typeof State)[keyof typeof State]; + /** Describes the type of consent. */ export const ConsentType = { OptOut: "opt_out", OptIn: "opt_in", } as const; + export type ConsentType = (typeof ConsentType)[keyof typeof ConsentType]; export type ContentTypes = ContentTypes.Item[]; export namespace ContentTypes { - export type Item = "email" | "sms_message"; export const Item = { Email: "email", SmsMessage: "sms_message", } as const; + export type Item = (typeof Item)[keyof typeof Item]; } } diff --git a/src/api/resources/subscriptionTypes/types/index.ts b/src/api/resources/subscriptionTypes/types/index.ts index fe95bab5..b6a27359 100644 --- a/src/api/resources/subscriptionTypes/types/index.ts +++ b/src/api/resources/subscriptionTypes/types/index.ts @@ -1 +1 @@ -export * from "./SubscriptionType"; +export * from "./SubscriptionType.js"; diff --git a/src/api/resources/tags/client/Client.ts b/src/api/resources/tags/client/Client.ts index db51c738..33235bf3 100644 --- a/src/api/resources/tags/client/Client.ts +++ b/src/api/resources/tags/client/Client.ts @@ -1,85 +1,35 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace Tags { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace TagsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about tags */ -export class Tags { - constructor(protected readonly _options: Tags.Options = {}) {} +export class TagsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: TagsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can tag a specific contact. This will return a tag object for the tag that was added to the contact. * * @param {Intercom.TagContactRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -98,41 +48,41 @@ export class Tags { */ public tagContact( request: Intercom.TagContactRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__tagContact(request, requestOptions)); } private async __tagContact( request: Intercom.TagContactRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { contact_id: contactId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/tags`, + `contacts/${core.url.encodePathParam(contactId)}/tags`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; @@ -156,30 +106,14 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /contacts/{contact_id}/tags.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts/{contact_id}/tags"); } /** * You can remove tag from a specific contact. This will return a tag object for the tag that was removed from the contact. * * @param {Intercom.UntagContactRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -192,40 +126,38 @@ export class Tags { */ public untagContact( request: Intercom.UntagContactRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__untagContact(request, requestOptions)); } private async __untagContact( request: Intercom.UntagContactRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { contact_id: contactId, tag_id: tagId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/tags/${encodeURIComponent(tagId)}`, + `contacts/${core.url.encodePathParam(contactId)}/tags/${core.url.encodePathParam(tagId)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; @@ -249,30 +181,19 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /contacts/{contact_id}/tags/{tag_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/contacts/{contact_id}/tags/{tag_id}", + ); } /** * You can tag a specific conversation. This will return a tag object for the tag that was added to the conversation. * * @param {Intercom.TagConversationRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -286,41 +207,41 @@ export class Tags { */ public tagConversation( request: Intercom.TagConversationRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__tagConversation(request, requestOptions)); } private async __tagConversation( request: Intercom.TagConversationRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { conversation_id: conversationId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/tags`, + `conversations/${core.url.encodePathParam(conversationId)}/tags`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; @@ -344,30 +265,19 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{conversation_id}/tags.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/conversations/{conversation_id}/tags", + ); } /** * You can remove tag from a specific conversation. This will return a tag object for the tag that was removed from the conversation. * * @param {Intercom.UntagConversationRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -381,41 +291,41 @@ export class Tags { */ public untagConversation( request: Intercom.UntagConversationRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__untagConversation(request, requestOptions)); } private async __untagConversation( request: Intercom.UntagConversationRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { conversation_id: conversationId, tag_id: tagId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/tags/${encodeURIComponent(tagId)}`, + `conversations/${core.url.encodePathParam(conversationId)}/tags/${core.url.encodePathParam(tagId)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; @@ -439,64 +349,52 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /conversations/{conversation_id}/tags/{tag_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/conversations/{conversation_id}/tags/{tag_id}", + ); } /** * You can fetch a list of all tags for a given workspace. * - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * * @example * await client.tags.list() */ - public list(requestOptions?: Tags.RequestOptions): core.HttpResponsePromise { + public list(requestOptions?: TagsClient.RequestOptions): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__list(requestOptions)); } - private async __list(requestOptions?: Tags.RequestOptions): Promise> { + private async __list(requestOptions?: TagsClient.RequestOptions): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "tags", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.TagList, rawResponse: _response.rawResponse }; @@ -518,21 +416,7 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tags."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/tags"); } /** @@ -551,7 +435,7 @@ export class Tags { * Each operation will return a tag object. * * @param {Intercom.TagsCreateRequestBody} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.BadRequestError} * @throws {@link Intercom.UnauthorizedError} @@ -585,40 +469,40 @@ export class Tags { */ public create( request: Intercom.TagsCreateRequestBody, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( request: Intercom.TagsCreateRequestBody, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "tags", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; @@ -644,21 +528,7 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tags."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/tags"); } /** @@ -666,7 +536,7 @@ export class Tags { * This will return a tag object. * * @param {Intercom.FindTagRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -678,40 +548,38 @@ export class Tags { */ public find( request: Intercom.FindTagRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.FindTagRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { tag_id: tagId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tags/${encodeURIComponent(tagId)}`, + `tags/${core.url.encodePathParam(tagId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; @@ -735,28 +603,14 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tags/{tag_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/tags/{tag_id}"); } /** * You can delete the details of tags that are on the workspace by passing in the id. * * @param {Intercom.DeleteTagRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.BadRequestError} * @throws {@link Intercom.UnauthorizedError} @@ -769,40 +623,38 @@ export class Tags { */ public delete( request: Intercom.DeleteTagRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__delete(request, requestOptions)); } private async __delete( request: Intercom.DeleteTagRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { tag_id: tagId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tags/${encodeURIComponent(tagId)}`, + `tags/${core.url.encodePathParam(tagId)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: undefined, rawResponse: _response.rawResponse }; @@ -828,28 +680,14 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /tags/{tag_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/tags/{tag_id}"); } /** * You can tag a specific ticket. This will return a tag object for the tag that was added to the ticket. * * @param {Intercom.TagTicketRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -863,41 +701,41 @@ export class Tags { */ public tagTicket( request: Intercom.TagTicketRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__tagTicket(request, requestOptions)); } private async __tagTicket( request: Intercom.TagTicketRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { ticket_id: ticketId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(ticketId)}/tags`, + `tickets/${core.url.encodePathParam(ticketId)}/tags`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; @@ -921,28 +759,14 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/{ticket_id}/tags."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/tickets/{ticket_id}/tags"); } /** * You can remove tag from a specific ticket. This will return a tag object for the tag that was removed from the ticket. * * @param {Intercom.UntagTicketRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -956,41 +780,41 @@ export class Tags { */ public untagTicket( request: Intercom.UntagTicketRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__untagTicket(request, requestOptions)); } private async __untagTicket( request: Intercom.UntagTicketRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { ticket_id: ticketId, tag_id: tagId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(ticketId)}/tags/${encodeURIComponent(tagId)}`, + `tickets/${core.url.encodePathParam(ticketId)}/tags/${core.url.encodePathParam(tagId)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Tag, rawResponse: _response.rawResponse }; @@ -1014,34 +838,11 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /tickets/{ticket_id}/tags/{tag_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/tickets/{ticket_id}/tags/{tag_id}", + ); } } diff --git a/src/api/resources/tags/client/index.ts b/src/api/resources/tags/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/tags/client/index.ts +++ b/src/api/resources/tags/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/tags/client/requests/DeleteTagRequest.ts b/src/api/resources/tags/client/requests/DeleteTagRequest.ts index c6f44174..4e81f7e4 100644 --- a/src/api/resources/tags/client/requests/DeleteTagRequest.ts +++ b/src/api/resources/tags/client/requests/DeleteTagRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DeleteTagRequest { - /** - * The unique identifier of a given tag - */ + /** The unique identifier of a given tag */ tag_id: string; } diff --git a/src/api/resources/tags/client/requests/FindTagRequest.ts b/src/api/resources/tags/client/requests/FindTagRequest.ts index b708ed6a..89b19db8 100644 --- a/src/api/resources/tags/client/requests/FindTagRequest.ts +++ b/src/api/resources/tags/client/requests/FindTagRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface FindTagRequest { - /** - * The unique identifier of a given tag - */ + /** The unique identifier of a given tag */ tag_id: string; } diff --git a/src/api/resources/tags/client/requests/TagContactRequest.ts b/src/api/resources/tags/client/requests/TagContactRequest.ts index fe463e94..a9dd6aa2 100644 --- a/src/api/resources/tags/client/requests/TagContactRequest.ts +++ b/src/api/resources/tags/client/requests/TagContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -22,9 +20,7 @@ * } */ export interface TagContactRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; /** The unique identifier for the tag which is given by Intercom */ id: string; diff --git a/src/api/resources/tags/client/requests/TagConversationRequest.ts b/src/api/resources/tags/client/requests/TagConversationRequest.ts index 2fd2282f..1a744067 100644 --- a/src/api/resources/tags/client/requests/TagConversationRequest.ts +++ b/src/api/resources/tags/client/requests/TagConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -18,9 +16,7 @@ * } */ export interface TagConversationRequest { - /** - * conversation_id - */ + /** conversation_id */ conversation_id: string; /** The unique identifier for the tag which is given by Intercom */ id: string; diff --git a/src/api/resources/tags/client/requests/TagTicketRequest.ts b/src/api/resources/tags/client/requests/TagTicketRequest.ts index 3be7d004..6835d0db 100644 --- a/src/api/resources/tags/client/requests/TagTicketRequest.ts +++ b/src/api/resources/tags/client/requests/TagTicketRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -18,9 +16,7 @@ * } */ export interface TagTicketRequest { - /** - * ticket_id - */ + /** ticket_id */ ticket_id: string; /** The unique identifier for the tag which is given by Intercom */ id: string; diff --git a/src/api/resources/tags/client/requests/UntagContactRequest.ts b/src/api/resources/tags/client/requests/UntagContactRequest.ts index 81a2c945..27108640 100644 --- a/src/api/resources/tags/client/requests/UntagContactRequest.ts +++ b/src/api/resources/tags/client/requests/UntagContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -10,12 +8,8 @@ * } */ export interface UntagContactRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; - /** - * The unique identifier for the tag which is given by Intercom - */ + /** The unique identifier for the tag which is given by Intercom */ tag_id: string; } diff --git a/src/api/resources/tags/client/requests/UntagConversationRequest.ts b/src/api/resources/tags/client/requests/UntagConversationRequest.ts index 1d730070..bcf4e945 100644 --- a/src/api/resources/tags/client/requests/UntagConversationRequest.ts +++ b/src/api/resources/tags/client/requests/UntagConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -25,13 +23,9 @@ * } */ export interface UntagConversationRequest { - /** - * conversation_id - */ + /** conversation_id */ conversation_id: string; - /** - * id - */ + /** tag_id */ tag_id: string; /** The unique identifier for the admin which is given by Intercom. */ admin_id: string; diff --git a/src/api/resources/tags/client/requests/UntagTicketRequest.ts b/src/api/resources/tags/client/requests/UntagTicketRequest.ts index 2115f12e..d6063ea7 100644 --- a/src/api/resources/tags/client/requests/UntagTicketRequest.ts +++ b/src/api/resources/tags/client/requests/UntagTicketRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -25,13 +23,9 @@ * } */ export interface UntagTicketRequest { - /** - * ticket_id - */ + /** ticket_id */ ticket_id: string; - /** - * The unique identifier for the tag which is given by Intercom - */ + /** The unique identifier for the tag which is given by Intercom */ tag_id: string; /** The unique identifier for the admin which is given by Intercom. */ admin_id: string; diff --git a/src/api/resources/tags/client/requests/index.ts b/src/api/resources/tags/client/requests/index.ts index 0d5e855b..f924d8ba 100644 --- a/src/api/resources/tags/client/requests/index.ts +++ b/src/api/resources/tags/client/requests/index.ts @@ -1,8 +1,8 @@ -export { type TagContactRequest } from "./TagContactRequest"; -export { type UntagContactRequest } from "./UntagContactRequest"; -export { type TagConversationRequest } from "./TagConversationRequest"; -export { type UntagConversationRequest } from "./UntagConversationRequest"; -export { type FindTagRequest } from "./FindTagRequest"; -export { type DeleteTagRequest } from "./DeleteTagRequest"; -export { type TagTicketRequest } from "./TagTicketRequest"; -export { type UntagTicketRequest } from "./UntagTicketRequest"; +export type { DeleteTagRequest } from "./DeleteTagRequest.js"; +export type { FindTagRequest } from "./FindTagRequest.js"; +export type { TagContactRequest } from "./TagContactRequest.js"; +export type { TagConversationRequest } from "./TagConversationRequest.js"; +export type { TagTicketRequest } from "./TagTicketRequest.js"; +export type { UntagContactRequest } from "./UntagContactRequest.js"; +export type { UntagConversationRequest } from "./UntagConversationRequest.js"; +export type { UntagTicketRequest } from "./UntagTicketRequest.js"; diff --git a/src/api/resources/tags/index.ts b/src/api/resources/tags/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/tags/index.ts +++ b/src/api/resources/tags/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/tags/types/Tag.ts b/src/api/resources/tags/types/Tag.ts index 7002dfdb..3a2c7940 100644 --- a/src/api/resources/tags/types/Tag.ts +++ b/src/api/resources/tags/types/Tag.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A tag allows you to label your contacts, companies, and conversations and list them using that tag. @@ -15,6 +13,6 @@ export interface Tag { /** The name of the tag */ name: string; /** The time when the tag was applied to the object */ - applied_at: number; - applied_by: Intercom.Reference; + applied_at?: number; + applied_by?: Intercom.Reference; } diff --git a/src/api/resources/tags/types/TagBasic.ts b/src/api/resources/tags/types/TagBasic.ts new file mode 100644 index 00000000..8e8b815d --- /dev/null +++ b/src/api/resources/tags/types/TagBasic.ts @@ -0,0 +1,13 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * A tag allows you to label your contacts, companies, and conversations and list them using that tag. + */ +export interface TagBasic { + /** value is "tag" */ + type?: string; + /** The id of the tag */ + id?: string; + /** The name of the tag */ + name?: string; +} diff --git a/src/api/resources/tags/types/TagsCreateRequestBody.ts b/src/api/resources/tags/types/TagsCreateRequestBody.ts index aaf7c9e9..3858b435 100644 --- a/src/api/resources/tags/types/TagsCreateRequestBody.ts +++ b/src/api/resources/tags/types/TagsCreateRequestBody.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; export type TagsCreateRequestBody = | Intercom.CreateOrUpdateTagRequest diff --git a/src/api/resources/tags/types/index.ts b/src/api/resources/tags/types/index.ts index 9f251c2a..9a358541 100644 --- a/src/api/resources/tags/types/index.ts +++ b/src/api/resources/tags/types/index.ts @@ -1,2 +1,3 @@ -export * from "./TagsCreateRequestBody"; -export * from "./Tag"; +export * from "./Tag.js"; +export * from "./TagBasic.js"; +export * from "./TagsCreateRequestBody.js"; diff --git a/src/api/resources/teams/client/Client.ts b/src/api/resources/teams/client/Client.ts index 2d523ac4..13d8921e 100644 --- a/src/api/resources/teams/client/Client.ts +++ b/src/api/resources/teams/client/Client.ts @@ -1,119 +1,69 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace Teams { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace TeamsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Teams */ -export class Teams { - constructor(protected readonly _options: Teams.Options = {}) {} +export class TeamsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: TeamsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * This will return a list of team objects for the App. * - * @param {Teams.RequestOptions} requestOptions - Request-specific configuration. + * @param {TeamsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * * @example * await client.teams.list() */ - public list(requestOptions?: Teams.RequestOptions): core.HttpResponsePromise { + public list(requestOptions?: TeamsClient.RequestOptions): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__list(requestOptions)); } - private async __list(requestOptions?: Teams.RequestOptions): Promise> { + private async __list( + requestOptions?: TeamsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "teams", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.TeamList, rawResponse: _response.rawResponse }; @@ -135,28 +85,14 @@ export class Teams { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /teams."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/teams"); } /** * You can fetch the details of a single team, containing an array of admins that belong to this team. * * @param {Intercom.FindTeamRequest} request - * @param {Teams.RequestOptions} requestOptions - Request-specific configuration. + * @param {TeamsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -168,40 +104,38 @@ export class Teams { */ public find( request: Intercom.FindTeamRequest, - requestOptions?: Teams.RequestOptions, + requestOptions?: TeamsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.FindTeamRequest, - requestOptions?: Teams.RequestOptions, + requestOptions?: TeamsClient.RequestOptions, ): Promise> { const { team_id: teamId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `teams/${encodeURIComponent(teamId)}`, + `teams/${core.url.encodePathParam(teamId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Team, rawResponse: _response.rawResponse }; @@ -225,32 +159,6 @@ export class Teams { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /teams/{team_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/teams/{team_id}"); } } diff --git a/src/api/resources/teams/client/index.ts b/src/api/resources/teams/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/teams/client/index.ts +++ b/src/api/resources/teams/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/teams/client/requests/FindTeamRequest.ts b/src/api/resources/teams/client/requests/FindTeamRequest.ts index c2a2151a..8902bc93 100644 --- a/src/api/resources/teams/client/requests/FindTeamRequest.ts +++ b/src/api/resources/teams/client/requests/FindTeamRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface FindTeamRequest { - /** - * The unique identifier of a given team. - */ + /** The unique identifier of a given team. */ team_id: string; } diff --git a/src/api/resources/teams/client/requests/index.ts b/src/api/resources/teams/client/requests/index.ts index 38be3714..0cc78a95 100644 --- a/src/api/resources/teams/client/requests/index.ts +++ b/src/api/resources/teams/client/requests/index.ts @@ -1 +1 @@ -export { type FindTeamRequest } from "./FindTeamRequest"; +export type { FindTeamRequest } from "./FindTeamRequest.js"; diff --git a/src/api/resources/teams/index.ts b/src/api/resources/teams/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/teams/index.ts +++ b/src/api/resources/teams/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/teams/types/Team.ts b/src/api/resources/teams/types/Team.ts index 698c89c9..8b038649 100644 --- a/src/api/resources/teams/types/Team.ts +++ b/src/api/resources/teams/types/Team.ts @@ -1,20 +1,22 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Teams are groups of admins in Intercom. */ export interface Team { /** Value is always "team" */ - type: "team"; + type?: string; /** The id of the team */ - id: string; + id?: string; /** The name of the team */ - name: string; + name?: string; /** The list of admin IDs that are a part of the team. */ - admin_ids: number[]; + admin_ids?: number[]; admin_priority_level?: Intercom.AdminPriorityLevel; + /** The assignment limit for the team. This field is only present when the team's distribution type is load balanced. */ + assignment_limit?: number; + /** Describes how assignments are distributed among the team members */ + distribution_method?: string; } diff --git a/src/api/resources/teams/types/index.ts b/src/api/resources/teams/types/index.ts index e3645596..bc100e99 100644 --- a/src/api/resources/teams/types/index.ts +++ b/src/api/resources/teams/types/index.ts @@ -1 +1 @@ -export * from "./Team"; +export * from "./Team.js"; diff --git a/src/api/resources/ticketStates/client/Client.ts b/src/api/resources/ticketStates/client/Client.ts new file mode 100644 index 00000000..58ed8ebf --- /dev/null +++ b/src/api/resources/ticketStates/client/Client.ts @@ -0,0 +1,92 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; + +export declare namespace TicketStatesClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * Everything about your ticket states + */ +export class TicketStatesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: TicketStatesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * You can get a list of all ticket states for a workspace. + * + * @param {TicketStatesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.ticketStates.listTicketStates() + */ + public listTicketStates( + requestOptions?: TicketStatesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listTicketStates(requestOptions)); + } + + private async __listTicketStates( + requestOptions?: TicketStatesClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ticket_states", + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.TicketStateList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/ticket_states"); + } +} diff --git a/src/api/resources/ticketStates/client/index.ts b/src/api/resources/ticketStates/client/index.ts new file mode 100644 index 00000000..cb0ff5c3 --- /dev/null +++ b/src/api/resources/ticketStates/client/index.ts @@ -0,0 +1 @@ +export {}; diff --git a/src/api/resources/ticketStates/index.ts b/src/api/resources/ticketStates/index.ts new file mode 100644 index 00000000..914b8c3c --- /dev/null +++ b/src/api/resources/ticketStates/index.ts @@ -0,0 +1 @@ +export * from "./client/index.js"; diff --git a/src/api/resources/ticketTypes/client/Client.ts b/src/api/resources/ticketTypes/client/Client.ts index f4909e81..8649ba80 100644 --- a/src/api/resources/ticketTypes/client/Client.ts +++ b/src/api/resources/ticketTypes/client/Client.ts @@ -1,128 +1,75 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; -import { Attributes } from "../resources/attributes/client/Client"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; +import { AttributesClient } from "../resources/attributes/client/Client.js"; -export declare namespace TicketTypes { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace TicketTypesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your ticket types */ -export class TicketTypes { - protected _attributes: Attributes | undefined; +export class TicketTypesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + protected _attributes: AttributesClient | undefined; - constructor(protected readonly _options: TicketTypes.Options = {}) {} + constructor(options: TicketTypesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } - public get attributes(): Attributes { - return (this._attributes ??= new Attributes(this._options)); + public get attributes(): AttributesClient { + return (this._attributes ??= new AttributesClient(this._options)); } /** * You can get a list of all ticket types for a workspace. * - * @param {TicketTypes.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketTypesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * * @example * await client.ticketTypes.list() */ - public list(requestOptions?: TicketTypes.RequestOptions): core.HttpResponsePromise { + public list(requestOptions?: TicketTypesClient.RequestOptions): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__list(requestOptions)); } private async __list( - requestOptions?: TicketTypes.RequestOptions, + requestOptions?: TicketTypesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "ticket_types", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.TicketTypeList, rawResponse: _response.rawResponse }; @@ -144,21 +91,7 @@ export class TicketTypes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ticket_types."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/ticket_types"); } /** @@ -169,7 +102,7 @@ export class TicketTypes { * > For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) * * @param {Intercom.CreateTicketTypeRequest} request - * @param {TicketTypes.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketTypesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -182,44 +115,44 @@ export class TicketTypes { * }) */ public create( - request: Intercom.CreateTicketTypeRequest, - requestOptions?: TicketTypes.RequestOptions, - ): core.HttpResponsePromise { + request?: Intercom.CreateTicketTypeRequest, + requestOptions?: TicketTypesClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( - request: Intercom.CreateTicketTypeRequest, - requestOptions?: TicketTypes.RequestOptions, - ): Promise> { + request?: Intercom.CreateTicketTypeRequest, + requestOptions?: TicketTypesClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "ticket_types", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", - body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + body: request != null ? request : undefined, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.TicketType, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.TicketType | undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -238,28 +171,14 @@ export class TicketTypes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /ticket_types."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/ticket_types"); } /** * You can fetch the details of a single ticket type. * * @param {Intercom.FindTicketTypeRequest} request - * @param {TicketTypes.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketTypesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -270,43 +189,41 @@ export class TicketTypes { */ public get( request: Intercom.FindTicketTypeRequest, - requestOptions?: TicketTypes.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: TicketTypesClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__get(request, requestOptions)); } private async __get( request: Intercom.FindTicketTypeRequest, - requestOptions?: TicketTypes.RequestOptions, - ): Promise> { + requestOptions?: TicketTypesClient.RequestOptions, + ): Promise> { const { ticket_type_id: ticketTypeId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ticket_types/${encodeURIComponent(ticketTypeId)}`, + `ticket_types/${core.url.encodePathParam(ticketTypeId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.TicketType, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.TicketType | undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -325,23 +242,12 @@ export class TicketTypes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /ticket_types/{ticket_type_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/ticket_types/{ticket_type_id}", + ); } /** @@ -353,7 +259,7 @@ export class TicketTypes { * > For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) * * @param {Intercom.UpdateTicketTypeRequest} request - * @param {TicketTypes.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketTypesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -365,44 +271,44 @@ export class TicketTypes { */ public update( request: Intercom.UpdateTicketTypeRequest, - requestOptions?: TicketTypes.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: TicketTypesClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); } private async __update( request: Intercom.UpdateTicketTypeRequest, - requestOptions?: TicketTypes.RequestOptions, - ): Promise> { + requestOptions?: TicketTypesClient.RequestOptions, + ): Promise> { const { ticket_type_id: ticketTypeId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ticket_types/${encodeURIComponent(ticketTypeId)}`, + `ticket_types/${core.url.encodePathParam(ticketTypeId)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.TicketType, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.TicketType | undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -421,34 +327,11 @@ export class TicketTypes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /ticket_types/{ticket_type_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "PUT", + "/ticket_types/{ticket_type_id}", + ); } } diff --git a/src/api/resources/ticketTypes/client/index.ts b/src/api/resources/ticketTypes/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/ticketTypes/client/index.ts +++ b/src/api/resources/ticketTypes/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/ticketTypes/client/requests/FindTicketTypeRequest.ts b/src/api/resources/ticketTypes/client/requests/FindTicketTypeRequest.ts index 968dd46d..84a6e0ef 100644 --- a/src/api/resources/ticketTypes/client/requests/FindTicketTypeRequest.ts +++ b/src/api/resources/ticketTypes/client/requests/FindTicketTypeRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface FindTicketTypeRequest { - /** - * The unique identifier for the ticket type which is given by Intercom. - */ + /** The unique identifier for the ticket type which is given by Intercom. */ ticket_type_id: string; } diff --git a/src/api/resources/ticketTypes/client/requests/UpdateTicketTypeRequest.ts b/src/api/resources/ticketTypes/client/requests/UpdateTicketTypeRequest.ts index 55572ebe..1d2bd489 100644 --- a/src/api/resources/ticketTypes/client/requests/UpdateTicketTypeRequest.ts +++ b/src/api/resources/ticketTypes/client/requests/UpdateTicketTypeRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -10,9 +8,7 @@ * } */ export interface UpdateTicketTypeRequest { - /** - * The unique identifier for the ticket type which is given by Intercom. - */ + /** The unique identifier for the ticket type which is given by Intercom. */ ticket_type_id: string; /** The name of the ticket type. */ name?: string; @@ -29,13 +25,11 @@ export interface UpdateTicketTypeRequest { } export namespace UpdateTicketTypeRequest { - /** - * Category of the Ticket Type. - */ - export type Category = "Customer" | "Back-office" | "Tracker"; + /** Category of the Ticket Type. */ export const Category = { Customer: "Customer", BackOffice: "Back-office", Tracker: "Tracker", } as const; + export type Category = (typeof Category)[keyof typeof Category]; } diff --git a/src/api/resources/ticketTypes/client/requests/index.ts b/src/api/resources/ticketTypes/client/requests/index.ts index 7b66e378..8eee27c4 100644 --- a/src/api/resources/ticketTypes/client/requests/index.ts +++ b/src/api/resources/ticketTypes/client/requests/index.ts @@ -1,3 +1,2 @@ -export { type CreateTicketTypeRequest } from "./CreateTicketTypeRequest"; -export { type FindTicketTypeRequest } from "./FindTicketTypeRequest"; -export { type UpdateTicketTypeRequest } from "./UpdateTicketTypeRequest"; +export type { FindTicketTypeRequest } from "./FindTicketTypeRequest.js"; +export type { UpdateTicketTypeRequest } from "./UpdateTicketTypeRequest.js"; diff --git a/src/api/resources/ticketTypes/index.ts b/src/api/resources/ticketTypes/index.ts index 33a87f10..9eb1192d 100644 --- a/src/api/resources/ticketTypes/index.ts +++ b/src/api/resources/ticketTypes/index.ts @@ -1,2 +1,2 @@ -export * from "./client"; -export * from "./resources"; +export * from "./client/index.js"; +export * from "./resources/index.js"; diff --git a/src/api/resources/ticketTypes/resources/attributes/client/Client.ts b/src/api/resources/ticketTypes/resources/attributes/client/Client.ts index 32ac1e89..0f27dcd1 100644 --- a/src/api/resources/ticketTypes/resources/attributes/client/Client.ts +++ b/src/api/resources/ticketTypes/resources/attributes/client/Client.ts @@ -1,82 +1,32 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Attributes { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace AttributesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } -export class Attributes { - constructor(protected readonly _options: Attributes.Options = {}) {} +export class AttributesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: AttributesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can create a new attribute for a ticket type. * * @param {Intercom.ticketTypes.CreateTicketTypeAttributeRequest} request - * @param {Attributes.RequestOptions} requestOptions - Request-specific configuration. + * @param {AttributesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -91,44 +41,47 @@ export class Attributes { */ public create( request: Intercom.ticketTypes.CreateTicketTypeAttributeRequest, - requestOptions?: Attributes.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: AttributesClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( request: Intercom.ticketTypes.CreateTicketTypeAttributeRequest, - requestOptions?: Attributes.RequestOptions, - ): Promise> { + requestOptions?: AttributesClient.RequestOptions, + ): Promise> { const { ticket_type_id: ticketTypeId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ticket_types/${encodeURIComponent(ticketTypeId)}/attributes`, + `ticket_types/${core.url.encodePathParam(ticketTypeId)}/attributes`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.TicketTypeAttribute, rawResponse: _response.rawResponse }; + return { + data: _response.body as Intercom.TicketTypeAttribute | undefined, + rawResponse: _response.rawResponse, + }; } if (_response.error.reason === "status-code") { @@ -147,30 +100,19 @@ export class Attributes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /ticket_types/{ticket_type_id}/attributes.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/ticket_types/{ticket_type_id}/attributes", + ); } /** * You can update an existing attribute for a ticket type. * * @param {Intercom.ticketTypes.UpdateTicketTypeAttributeRequest} request - * @param {Attributes.RequestOptions} requestOptions - Request-specific configuration. + * @param {AttributesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -183,44 +125,47 @@ export class Attributes { */ public update( request: Intercom.ticketTypes.UpdateTicketTypeAttributeRequest, - requestOptions?: Attributes.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: AttributesClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); } private async __update( request: Intercom.ticketTypes.UpdateTicketTypeAttributeRequest, - requestOptions?: Attributes.RequestOptions, - ): Promise> { + requestOptions?: AttributesClient.RequestOptions, + ): Promise> { const { ticket_type_id: ticketTypeId, attribute_id: attributeId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ticket_types/${encodeURIComponent(ticketTypeId)}/attributes/${encodeURIComponent(attributeId)}`, + `ticket_types/${core.url.encodePathParam(ticketTypeId)}/attributes/${core.url.encodePathParam(attributeId)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.TicketTypeAttribute, rawResponse: _response.rawResponse }; + return { + data: _response.body as Intercom.TicketTypeAttribute | undefined, + rawResponse: _response.rawResponse, + }; } if (_response.error.reason === "status-code") { @@ -239,34 +184,11 @@ export class Attributes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /ticket_types/{ticket_type_id}/attributes/{attribute_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "PUT", + "/ticket_types/{ticket_type_id}/attributes/{attribute_id}", + ); } } diff --git a/src/api/resources/ticketTypes/resources/attributes/client/index.ts b/src/api/resources/ticketTypes/resources/attributes/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/ticketTypes/resources/attributes/client/index.ts +++ b/src/api/resources/ticketTypes/resources/attributes/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/ticketTypes/resources/attributes/client/requests/CreateTicketTypeAttributeRequest.ts b/src/api/resources/ticketTypes/resources/attributes/client/requests/CreateTicketTypeAttributeRequest.ts index 0a9604c1..6dbf0ac2 100644 --- a/src/api/resources/ticketTypes/resources/attributes/client/requests/CreateTicketTypeAttributeRequest.ts +++ b/src/api/resources/ticketTypes/resources/attributes/client/requests/CreateTicketTypeAttributeRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -13,9 +11,7 @@ * } */ export interface CreateTicketTypeAttributeRequest { - /** - * The unique identifier for the ticket type which is given by Intercom. - */ + /** The unique identifier for the ticket type which is given by Intercom. */ ticket_type_id: string; /** The name of the ticket type attribute */ name: string; @@ -40,10 +36,7 @@ export interface CreateTicketTypeAttributeRequest { } export namespace CreateTicketTypeAttributeRequest { - /** - * The data type of the attribute - */ - export type DataType = "string" | "list" | "integer" | "decimal" | "boolean" | "datetime" | "files"; + /** The data type of the attribute */ export const DataType = { String: "string", List: "list", @@ -53,4 +46,5 @@ export namespace CreateTicketTypeAttributeRequest { Datetime: "datetime", Files: "files", } as const; + export type DataType = (typeof DataType)[keyof typeof DataType]; } diff --git a/src/api/resources/ticketTypes/resources/attributes/client/requests/UpdateTicketTypeAttributeRequest.ts b/src/api/resources/ticketTypes/resources/attributes/client/requests/UpdateTicketTypeAttributeRequest.ts index a7324b1e..8fda5439 100644 --- a/src/api/resources/ticketTypes/resources/attributes/client/requests/UpdateTicketTypeAttributeRequest.ts +++ b/src/api/resources/ticketTypes/resources/attributes/client/requests/UpdateTicketTypeAttributeRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -11,13 +9,9 @@ * } */ export interface UpdateTicketTypeAttributeRequest { - /** - * The unique identifier for the ticket type which is given by Intercom. - */ + /** The unique identifier for the ticket type which is given by Intercom. */ ticket_type_id: string; - /** - * The unique identifier for the ticket type attribute which is given by Intercom. - */ + /** The unique identifier for the ticket type attribute which is given by Intercom. */ attribute_id: string; /** The name of the ticket type attribute */ name?: string; diff --git a/src/api/resources/ticketTypes/resources/attributes/client/requests/index.ts b/src/api/resources/ticketTypes/resources/attributes/client/requests/index.ts index b2d37564..2a2ffb63 100644 --- a/src/api/resources/ticketTypes/resources/attributes/client/requests/index.ts +++ b/src/api/resources/ticketTypes/resources/attributes/client/requests/index.ts @@ -1,2 +1,2 @@ -export { type CreateTicketTypeAttributeRequest } from "./CreateTicketTypeAttributeRequest"; -export { type UpdateTicketTypeAttributeRequest } from "./UpdateTicketTypeAttributeRequest"; +export type { CreateTicketTypeAttributeRequest } from "./CreateTicketTypeAttributeRequest.js"; +export type { UpdateTicketTypeAttributeRequest } from "./UpdateTicketTypeAttributeRequest.js"; diff --git a/src/api/resources/ticketTypes/resources/attributes/index.ts b/src/api/resources/ticketTypes/resources/attributes/index.ts index 5ec76921..914b8c3c 100644 --- a/src/api/resources/ticketTypes/resources/attributes/index.ts +++ b/src/api/resources/ticketTypes/resources/attributes/index.ts @@ -1 +1 @@ -export * from "./client"; +export * from "./client/index.js"; diff --git a/src/api/resources/ticketTypes/resources/index.ts b/src/api/resources/ticketTypes/resources/index.ts index 85faeec8..f11460cf 100644 --- a/src/api/resources/ticketTypes/resources/index.ts +++ b/src/api/resources/ticketTypes/resources/index.ts @@ -1,2 +1,2 @@ -export * as attributes from "./attributes"; -export * from "./attributes/client/requests"; +export * from "./attributes/client/requests/index.js"; +export * as attributes from "./attributes/index.js"; diff --git a/src/api/resources/tickets/client/Client.ts b/src/api/resources/tickets/client/Client.ts index a47554f7..d7456f7f 100644 --- a/src/api/resources/tickets/client/Client.ts +++ b/src/api/resources/tickets/client/Client.ts @@ -1,85 +1,35 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace Tickets { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace TicketsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your tickets */ -export class Tickets { - constructor(protected readonly _options: Tickets.Options = {}) {} +export class TicketsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: TicketsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can reply to a ticket with a message from an admin or on behalf of a contact, or with a note for admins. * * @param {Intercom.ReplyToTicketRequest} request - * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.BadRequestError} * @throws {@link Intercom.UnauthorizedError} @@ -92,7 +42,7 @@ export class Tickets { * message_type: "comment", * type: "user", * body: "Thanks again :)", - * intercom_user_id: "667d619d8a68186f43bafe82" + * intercom_user_id: "6762f2971bb69f9f2193bc49" * } * }) * @@ -116,10 +66,10 @@ export class Tickets { * admin_id: "3156780", * reply_options: [{ * text: "Yes", - * uuid: "22d6d1f4-1a19-41d0-94c2-e54031f78aca" + * uuid: "0df48b85-9a93-4c66-a167-753eff0baaec" * }, { * text: "No", - * uuid: "fbc3dbe0-ec0c-4fb6-826d-e19127191906" + * uuid: "4f0b5145-4193-4b4f-8cad-ce19478a3938" * }] * } * }) @@ -131,47 +81,47 @@ export class Tickets { * message_type: "comment", * type: "user", * body: "Thanks again :)", - * intercom_user_id: "667d61a68a68186f43bafe85" + * intercom_user_id: "6762f2a41bb69f9f2193bc4c" * } * }) */ public reply( request: Intercom.ReplyToTicketRequest, - requestOptions?: Tickets.RequestOptions, + requestOptions?: TicketsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__reply(request, requestOptions)); } private async __reply( request: Intercom.ReplyToTicketRequest, - requestOptions?: Tickets.RequestOptions, + requestOptions?: TicketsClient.RequestOptions, ): Promise> { const { ticket_id: ticketId, body: _body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(ticketId)}/reply`, + `tickets/${core.url.encodePathParam(ticketId)}/reply`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.TicketReply, rawResponse: _response.rawResponse }; @@ -197,28 +147,14 @@ export class Tickets { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/{ticket_id}/reply."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/tickets/{ticket_id}/reply"); } /** * You can create a new ticket. * * @param {Intercom.CreateTicketRequest} request - * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -226,53 +162,49 @@ export class Tickets { * await client.tickets.create({ * ticket_type_id: "1234", * contacts: [{ - * id: "667d61b78a68186f43bafe8d" - * }], - * ticket_attributes: { - * "_default_title_": "example", - * "_default_description_": "there is a problem" - * } + * id: "6762f2d81bb69f9f2193bc54" + * }] * }) */ public create( request: Intercom.CreateTicketRequest, - requestOptions?: Tickets.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: TicketsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__create(request, requestOptions)); } private async __create( request: Intercom.CreateTicketRequest, - requestOptions?: Tickets.RequestOptions, - ): Promise> { + requestOptions?: TicketsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "tickets", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.Ticket, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.Ticket | undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -291,28 +223,93 @@ export class Tickets { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/tickets"); + } + + /** + * Enqueues ticket creation for asynchronous processing, returning if the job was enqueued successfully to be processed. We attempt to perform a best-effort validation on inputs before tasks are enqueued. If the given parameters are incorrect, we won't enqueue the job. + * + * @param {Intercom.EnqueueCreateTicketRequest} request + * @param {TicketsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.BadRequestError} + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.tickets.enqueueCreateTicket({ + * ticket_type_id: "1234", + * contacts: [{ + * id: "6762f2d81bb69f9f2193bc54" + * }] + * }) + */ + public enqueueCreateTicket( + request: Intercom.EnqueueCreateTicketRequest, + requestOptions?: TicketsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__enqueueCreateTicket(request, requestOptions)); + } + + private async __enqueueCreateTicket( + request: Intercom.EnqueueCreateTicketRequest, + requestOptions?: TicketsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "tickets/enqueue", + ), + method: "POST", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: request, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.Jobs, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/tickets/enqueue"); } /** * You can fetch the details of a single ticket. * * @param {Intercom.FindTicketRequest} request - * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -323,43 +320,41 @@ export class Tickets { */ public get( request: Intercom.FindTicketRequest, - requestOptions?: Tickets.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: TicketsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__get(request, requestOptions)); } private async __get( request: Intercom.FindTicketRequest, - requestOptions?: Tickets.RequestOptions, - ): Promise> { + requestOptions?: TicketsClient.RequestOptions, + ): Promise> { const { ticket_id: ticketId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(ticketId)}`, + `tickets/${core.url.encodePathParam(ticketId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.Ticket, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.Ticket | undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -378,29 +373,16 @@ export class Tickets { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tickets/{ticket_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/tickets/{ticket_id}"); } /** * You can update a ticket. * * @param {Intercom.UpdateTicketRequest} request - * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketsClient.RequestOptions} requestOptions - Request-specific configuration. * + * @throws {@link Intercom.BadRequestError} * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * @@ -411,13 +393,11 @@ export class Tickets { * "_default_title_": "example", * "_default_description_": "there is a problem" * }, - * state: "in_progress", + * ticket_state_id: "123", * open: true, * snoozed_until: 1673609604, - * assignment: { - * admin_id: "991267883", - * assignee_id: "991267885" - * } + * admin_id: 991268011, + * assignee_id: "123" * }) * * @example @@ -427,71 +407,63 @@ export class Tickets { * "_default_title_": "example", * "_default_description_": "there is a problem" * }, - * state: "in_progress", - * assignment: { - * admin_id: "123", - * assignee_id: "991267893" - * } + * ticket_state_id: "123", + * admin_id: 991268011, + * assignee_id: "123" * }) * * @example * await client.tickets.update({ * ticket_id: "ticket_id", - * ticket_attributes: { - * "_default_title_": "example", - * "_default_description_": "there is a problem" - * }, - * state: "in_progress", - * assignment: { - * admin_id: "991267899", - * assignee_id: "456" - * } + * ticket_state_id: "123" * }) */ public update( request: Intercom.UpdateTicketRequest, - requestOptions?: Tickets.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: TicketsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); } private async __update( request: Intercom.UpdateTicketRequest, - requestOptions?: Tickets.RequestOptions, - ): Promise> { + requestOptions?: TicketsClient.RequestOptions, + ): Promise> { const { ticket_id: ticketId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(ticketId)}`, + `tickets/${core.url.encodePathParam(ticketId)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.Ticket, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.Ticket | undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { switch (_response.error.statusCode) { + case 400: + throw new Intercom.BadRequestError(_response.error.body as unknown, _response.rawResponse); case 401: throw new Intercom.UnauthorizedError( _response.error.body as Intercom.Error_, @@ -508,21 +480,81 @@ export class Tickets { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /tickets/{ticket_id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/tickets/{ticket_id}"); + } + + /** + * You can delete a ticket using the Intercom provided ID. + * + * @param {Intercom.DeleteTicketRequest} request + * @param {TicketsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.NotFoundError} + * + * @example + * await client.tickets.deleteTicket({ + * ticket_id: "ticket_id" + * }) + */ + public deleteTicket( + request: Intercom.DeleteTicketRequest, + requestOptions?: TicketsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteTicket(request, requestOptions)); + } + + private async __deleteTicket( + request: Intercom.DeleteTicketRequest, + requestOptions?: TicketsClient.RequestOptions, + ): Promise> { + const { ticket_id: ticketId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `tickets/${core.url.encodePathParam(ticketId)}`, + ), + method: "DELETE", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.DeleteTicketResponse, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/tickets/{ticket_id}"); } /** @@ -548,14 +580,15 @@ export class Tickets { * ### Accepted Fields * * Most keys listed as part of the Ticket model are searchable, whether writeable or not. The value you search for has to match the accepted type, otherwise the query will fail (ie. as `created_at` accepts a date, the `value` cannot be a string such as `"foobar"`). + * The `source.body` field is unique as the search will not be performed against the entire value, but instead against every element of the value separately. For example, when searching for a conversation with a `"I need support"` body - the query should contain a `=` operator with the value `"support"` for such conversation to be returned. A query with a `=` operator and a `"need support"` value will not yield a result. * * | Field | Type | * | :---------------------------------------- | :--------------------------------------------------------------------------------------- | * | id | String | * | created_at | Date (UNIX timestamp) | * | updated_at | Date (UNIX timestamp) | - * | _default_title_ | String | - * | _default_description_ | String | + * | title | String | + * | description | String | * | category | String | * | ticket_type_id | String | * | contact_ids | String | @@ -567,6 +600,13 @@ export class Tickets { * | snoozed_until | Date (UNIX timestamp) | * | ticket_attribute.{id} | String or Boolean or Date (UNIX timestamp) or Float or Integer | * + * {% admonition type="info" name="Searching by Category" %} + * When searching for tickets by the **`category`** field, specific terms must be used instead of the category names: + * * For **Customer** category tickets, use the term `request`. + * * For **Back-office** category tickets, use the term `task`. + * * For **Tracker** category tickets, use the term `tracker`. + * {% /admonition %} + * * ### Accepted Operators * * {% admonition type="info" name="Searching based on `created_at`" %} @@ -589,7 +629,7 @@ export class Tickets { * | $ | String | Ends With | * * @param {Intercom.SearchRequest} request - * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketsClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.tickets.search({ @@ -608,36 +648,35 @@ export class Tickets { */ public async search( request: Intercom.SearchRequest, - requestOptions?: Tickets.RequestOptions, - ): Promise> { + requestOptions?: TicketsClient.RequestOptions, + ): Promise> { const list = core.HttpResponsePromise.interceptFunction( async (request: Intercom.SearchRequest): Promise> => { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "tickets/search", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: - requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.TicketList, rawResponse: _response.rawResponse }; @@ -649,28 +688,19 @@ export class Tickets { rawResponse: _response.rawResponse, }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/search."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/tickets/search"); }, ); const dataWithRawResponse = await list(request).withRawResponse(); - return new core.Pageable({ + return new core.Page({ response: dataWithRawResponse.data, rawResponse: dataWithRawResponse.rawResponse, - hasNextPage: (response) => response?.pages?.next?.starting_after != null, + hasNextPage: (response) => + response?.pages?.next?.starting_after != null && + !( + typeof response?.pages?.next?.starting_after === "string" && + response?.pages?.next?.starting_after === "" + ), getItems: (response) => response?.tickets ?? [], loadPage: (response) => { return list( @@ -679,16 +709,4 @@ export class Tickets { }, }); } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; - } } diff --git a/src/api/resources/tickets/client/index.ts b/src/api/resources/tickets/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/tickets/client/index.ts +++ b/src/api/resources/tickets/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/tickets/client/requests/CreateTicketRequest.ts b/src/api/resources/tickets/client/requests/CreateTicketRequest.ts new file mode 100644 index 00000000..496df31d --- /dev/null +++ b/src/api/resources/tickets/client/requests/CreateTicketRequest.ts @@ -0,0 +1,17 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../index.js"; + +/** + * @example + * { + * ticket_type_id: "1234", + * contacts: [{ + * id: "6762f2d81bb69f9f2193bc54" + * }] + * } + */ +export interface CreateTicketRequest extends Intercom.CreateTicketRequestBody { + /** Option to disable notifications when a Ticket is created. */ + skip_notifications?: boolean; +} diff --git a/src/api/resources/tickets/client/requests/DeleteTicketRequest.ts b/src/api/resources/tickets/client/requests/DeleteTicketRequest.ts new file mode 100644 index 00000000..e5b5dee8 --- /dev/null +++ b/src/api/resources/tickets/client/requests/DeleteTicketRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * ticket_id: "ticket_id" + * } + */ +export interface DeleteTicketRequest { + /** The unique identifier for the ticket which is given by Intercom. */ + ticket_id: string; +} diff --git a/src/api/resources/tickets/client/requests/EnqueueCreateTicketRequest.ts b/src/api/resources/tickets/client/requests/EnqueueCreateTicketRequest.ts new file mode 100644 index 00000000..f7969901 --- /dev/null +++ b/src/api/resources/tickets/client/requests/EnqueueCreateTicketRequest.ts @@ -0,0 +1,17 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../index.js"; + +/** + * @example + * { + * ticket_type_id: "1234", + * contacts: [{ + * id: "6762f2d81bb69f9f2193bc54" + * }] + * } + */ +export interface EnqueueCreateTicketRequest extends Intercom.CreateTicketRequestBody { + /** Option to disable notifications when a Ticket is created. */ + skip_notifications?: boolean; +} diff --git a/src/api/resources/tickets/client/requests/FindTicketRequest.ts b/src/api/resources/tickets/client/requests/FindTicketRequest.ts index 450d0725..f3f1e814 100644 --- a/src/api/resources/tickets/client/requests/FindTicketRequest.ts +++ b/src/api/resources/tickets/client/requests/FindTicketRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface FindTicketRequest { - /** - * The unique identifier for the ticket which is given by Intercom. - */ + /** The unique identifier for the ticket which is given by Intercom. */ ticket_id: string; } diff --git a/src/api/resources/tickets/client/requests/ReplyToTicketRequest.ts b/src/api/resources/tickets/client/requests/ReplyToTicketRequest.ts index c00dcfdd..b67d7011 100644 --- a/src/api/resources/tickets/client/requests/ReplyToTicketRequest.ts +++ b/src/api/resources/tickets/client/requests/ReplyToTicketRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../index"; +import type * as Intercom from "../../../../index.js"; /** * @example @@ -12,7 +10,7 @@ import * as Intercom from "../../../../index"; * message_type: "comment", * type: "user", * body: "Thanks again :)", - * intercom_user_id: "667d619d8a68186f43bafe82" + * intercom_user_id: "6762f2971bb69f9f2193bc49" * } * } * @@ -36,10 +34,10 @@ import * as Intercom from "../../../../index"; * admin_id: "3156780", * reply_options: [{ * text: "Yes", - * uuid: "22d6d1f4-1a19-41d0-94c2-e54031f78aca" + * uuid: "0df48b85-9a93-4c66-a167-753eff0baaec" * }, { * text: "No", - * uuid: "fbc3dbe0-ec0c-4fb6-826d-e19127191906" + * uuid: "4f0b5145-4193-4b4f-8cad-ce19478a3938" * }] * } * } @@ -51,7 +49,7 @@ import * as Intercom from "../../../../index"; * message_type: "comment", * type: "user", * body: "Thanks again :)", - * intercom_user_id: "667d61a68a68186f43bafe85" + * intercom_user_id: "6762f2a41bb69f9f2193bc4c" * } * } * @@ -62,7 +60,7 @@ import * as Intercom from "../../../../index"; * message_type: "comment", * type: "user", * body: "Thanks again :)", - * intercom_user_id: "667d619d8a68186f43bafe82" + * intercom_user_id: "6762f2971bb69f9f2193bc49" * } * } * @@ -73,7 +71,7 @@ import * as Intercom from "../../../../index"; * message_type: "comment", * type: "user", * body: "Thanks again :)", - * intercom_user_id: "667d619d8a68186f43bafe82" + * intercom_user_id: "6762f2971bb69f9f2193bc49" * } * } */ diff --git a/src/api/resources/tickets/client/requests/UpdateTicketRequest.ts b/src/api/resources/tickets/client/requests/UpdateTicketRequest.ts index 99555fa9..7ba6219a 100644 --- a/src/api/resources/tickets/client/requests/UpdateTicketRequest.ts +++ b/src/api/resources/tickets/client/requests/UpdateTicketRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -10,13 +8,11 @@ * "_default_title_": "example", * "_default_description_": "there is a problem" * }, - * state: "in_progress", + * ticket_state_id: "123", * open: true, * snoozed_until: 1673609604, - * assignment: { - * admin_id: "991267883", - * assignee_id: "991267885" - * } + * admin_id: 991268011, + * assignee_id: "123" * } * * @example @@ -26,11 +22,9 @@ * "_default_title_": "example", * "_default_description_": "there is a problem" * }, - * state: "in_progress", - * assignment: { - * admin_id: "123", - * assignee_id: "991267893" - * } + * ticket_state_id: "123", + * admin_id: 991268011, + * assignee_id: "123" * } * * @example @@ -40,46 +34,34 @@ * "_default_title_": "example", * "_default_description_": "there is a problem" * }, - * state: "in_progress", - * assignment: { - * admin_id: "991267899", - * assignee_id: "456" - * } + * ticket_state_id: "123", + * admin_id: 991268011, + * assignee_id: "123" + * } + * + * @example + * { + * ticket_id: "ticket_id", + * ticket_state_id: "123" * } */ export interface UpdateTicketRequest { - /** - * The unique identifier for the ticket which is given by Intercom - */ + /** The unique identifier for the ticket which is given by Intercom */ ticket_id: string; /** The attributes set on the ticket. */ ticket_attributes?: Record; - /** The state of the ticket. */ - state?: UpdateTicketRequest.State; + /** The ID of the ticket state associated with the ticket type. */ + ticket_state_id?: string; + /** The ID of the company that the ticket is associated with. The unique identifier for the company which is given by Intercom. Set to nil to remove company. */ + company_id?: string; /** Specify if a ticket is open. Set to false to close a ticket. Closing a ticket will also unsnooze it. */ open?: boolean; /** Specify whether the ticket is visible to users. */ is_shared?: boolean; /** The time you want the ticket to reopen. */ snoozed_until?: number; - assignment?: UpdateTicketRequest.Assignment; -} - -export namespace UpdateTicketRequest { - /** - * The state of the ticket. - */ - export type State = "in_progress" | "waiting_on_customer" | "resolved"; - export const State = { - InProgress: "in_progress", - WaitingOnCustomer: "waiting_on_customer", - Resolved: "resolved", - } as const; - - export interface Assignment { - /** The ID of the admin performing the action. */ - admin_id?: string; - /** The ID of the admin or team to which the ticket is assigned. Set this 0 to unassign it. */ - assignee_id?: string; - } + /** The ID of the admin performing ticket update. Needed for workflows execution and attributing actions to specific admins. */ + admin_id?: number; + /** The ID of the admin or team to which the ticket is assigned. Set this 0 to unassign it. */ + assignee_id?: string; } diff --git a/src/api/resources/tickets/client/requests/index.ts b/src/api/resources/tickets/client/requests/index.ts index 23ce5a7f..2a2313d7 100644 --- a/src/api/resources/tickets/client/requests/index.ts +++ b/src/api/resources/tickets/client/requests/index.ts @@ -1,3 +1,6 @@ -export { type ReplyToTicketRequest } from "./ReplyToTicketRequest"; -export { type FindTicketRequest } from "./FindTicketRequest"; -export { type UpdateTicketRequest } from "./UpdateTicketRequest"; +export type { CreateTicketRequest } from "./CreateTicketRequest.js"; +export type { DeleteTicketRequest } from "./DeleteTicketRequest.js"; +export type { EnqueueCreateTicketRequest } from "./EnqueueCreateTicketRequest.js"; +export type { FindTicketRequest } from "./FindTicketRequest.js"; +export type { ReplyToTicketRequest } from "./ReplyToTicketRequest.js"; +export type { UpdateTicketRequest } from "./UpdateTicketRequest.js"; diff --git a/src/api/resources/tickets/index.ts b/src/api/resources/tickets/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/tickets/index.ts +++ b/src/api/resources/tickets/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/tickets/types/DeleteTicketResponse.ts b/src/api/resources/tickets/types/DeleteTicketResponse.ts new file mode 100644 index 00000000..cdad7f2d --- /dev/null +++ b/src/api/resources/tickets/types/DeleteTicketResponse.ts @@ -0,0 +1,13 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Response when a ticket is deleted. + */ +export interface DeleteTicketResponse { + /** The unique identifier for the ticket. */ + id?: string; + /** always ticket */ + object?: "ticket"; + /** Whether the ticket is deleted or not. */ + deleted?: boolean; +} diff --git a/src/api/resources/tickets/types/Ticket.ts b/src/api/resources/tickets/types/Ticket.ts index 4962e861..8582aca5 100644 --- a/src/api/resources/tickets/types/Ticket.ts +++ b/src/api/resources/tickets/types/Ticket.ts @@ -1,26 +1,23 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Tickets are how you track requests from your users. */ export interface Ticket { /** Always ticket */ - type: "ticket"; + type?: "ticket"; /** The unique identifier for the ticket which is given by Intercom. */ - id: string; + id?: string; /** The ID of the Ticket used in the Intercom Inbox and Messenger. Do not use ticket_id for API queries. */ - ticket_id: string; + ticket_id?: string; /** Category of the Ticket. */ - category: Ticket.Category; - ticket_attributes: Intercom.TicketCustomAttributes; - /** The state the ticket is currently in */ - ticket_state: Ticket.TicketState; - ticket_type: Intercom.TicketType; - contacts: Intercom.TicketContacts; + category?: Ticket.Category; + ticket_attributes?: Intercom.TicketCustomAttributes; + ticket_state?: Intercom.TicketState; + ticket_type?: Intercom.TicketType; + contacts?: Intercom.TicketContacts; /** The id representing the admin assigned to the ticket. */ admin_assignee_id?: string; /** The id representing the team assigned to the ticket. */ @@ -37,30 +34,14 @@ export interface Ticket { ticket_parts?: Intercom.TicketParts; /** Whether or not the ticket is shared with the customer. */ is_shared?: boolean; - /** The state the ticket is currently in, in a human readable form - visible in Intercom */ - ticket_state_internal_label?: string; - /** The state the ticket is currently in, in a human readable form - visible to customers, in the messenger, email and tickets portal. */ - ticket_state_external_label?: string; } export namespace Ticket { - /** - * Category of the Ticket. - */ - export type Category = "Customer" | "Back-office" | "Tracker"; + /** Category of the Ticket. */ export const Category = { Customer: "Customer", BackOffice: "Back-office", Tracker: "Tracker", } as const; - /** - * The state the ticket is currently in - */ - export type TicketState = "submitted" | "in_progress" | "waiting_on_customer" | "resolved"; - export const TicketState = { - Submitted: "submitted", - InProgress: "in_progress", - WaitingOnCustomer: "waiting_on_customer", - Resolved: "resolved", - } as const; + export type Category = (typeof Category)[keyof typeof Category]; } diff --git a/src/api/resources/tickets/types/TicketContacts.ts b/src/api/resources/tickets/types/TicketContacts.ts index cc70ccbb..1d775525 100644 --- a/src/api/resources/tickets/types/TicketContacts.ts +++ b/src/api/resources/tickets/types/TicketContacts.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * The list of contacts affected by a ticket. */ export interface TicketContacts { /** always contact.list */ - type: "contact.list"; + type?: "contact.list"; /** The list of contacts affected by this ticket. */ - contacts: Intercom.ContactReference[]; + contacts?: Intercom.ContactReference[]; } diff --git a/src/api/resources/tickets/types/TicketPart.ts b/src/api/resources/tickets/types/TicketPart.ts index ecfb0528..ffe19d95 100644 --- a/src/api/resources/tickets/types/TicketPart.ts +++ b/src/api/resources/tickets/types/TicketPart.ts @@ -1,27 +1,25 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A Ticket Part represents a message in the ticket. */ export interface TicketPart { /** Always ticket_part */ - type: "ticket_part"; + type?: string; /** The id representing the ticket part. */ - id: string; + id?: string; /** The type of ticket part. */ - part_type: string; + part_type?: string; /** The message body, which may contain HTML. */ body?: string; /** The previous state of the ticket. */ previous_ticket_state?: TicketPart.PreviousTicketState; /** The state of the ticket. */ - ticket_state: TicketPart.TicketState; + ticket_state?: TicketPart.TicketState; /** The time the ticket part was created. */ - created_at: number; + created_at?: number; /** The last time the ticket part was updated. */ updated_at?: number; /** The id of the admin that was assigned the ticket by this ticket_part (null if there has been no change in assignment.) */ @@ -33,27 +31,79 @@ export interface TicketPart { external_id?: string; /** Whether or not the ticket part has been redacted. */ redacted?: boolean; + /** The app package code if this part was created via API. Note this field won't show if the part was not created via API. */ + app_package_code?: string; + /** The updated attribute data of the ticket part. Only present for attribute update parts. */ + updated_attribute_data?: TicketPart.UpdatedAttributeData; } export namespace TicketPart { - /** - * The previous state of the ticket. - */ - export type PreviousTicketState = "submitted" | "in_progress" | "waiting_on_customer" | "resolved"; + /** The previous state of the ticket. */ export const PreviousTicketState = { Submitted: "submitted", InProgress: "in_progress", WaitingOnCustomer: "waiting_on_customer", Resolved: "resolved", } as const; - /** - * The state of the ticket. - */ - export type TicketState = "submitted" | "in_progress" | "waiting_on_customer" | "resolved"; + export type PreviousTicketState = (typeof PreviousTicketState)[keyof typeof PreviousTicketState]; + /** The state of the ticket. */ export const TicketState = { Submitted: "submitted", InProgress: "in_progress", WaitingOnCustomer: "waiting_on_customer", Resolved: "resolved", } as const; + export type TicketState = (typeof TicketState)[keyof typeof TicketState]; + + /** + * The updated attribute data of the ticket part. Only present for attribute update parts. + */ + export interface UpdatedAttributeData { + /** Information about the attribute that was updated. */ + attribute: UpdatedAttributeData.Attribute; + /** The new value of the attribute. */ + value: UpdatedAttributeData.Value; + } + + export namespace UpdatedAttributeData { + /** + * Information about the attribute that was updated. + */ + export interface Attribute { + /** The type of the object. Always 'attribute'. */ + type: "attribute"; + /** The unique identifier of the attribute. */ + id: string; + /** The human-readable name of the attribute. */ + label: string; + } + + /** + * The new value of the attribute. + */ + export interface Value { + /** The type of the object. Always 'value'. */ + type: "value"; + id: Value.Id; + label: Value.Label; + } + + export namespace Value { + export type Id = + /** + * The value for text/number/decimal/boolean/date attributes, or the ID of the list option for list attributes. */ + | string + | undefined + /** + * Array of file IDs for file attributes. */ + | number[]; + export type Label = + /** + * The display value for text/number/decimal/boolean/date/list attributes. */ + | string + /** + * Array of file names for file attributes. */ + | string[]; + } + } } diff --git a/src/api/resources/tickets/types/TicketState.ts b/src/api/resources/tickets/types/TicketState.ts new file mode 100644 index 00000000..beef89c7 --- /dev/null +++ b/src/api/resources/tickets/types/TicketState.ts @@ -0,0 +1,28 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * A ticket state, used to define the state of a ticket. + */ +export interface TicketState { + /** String representing the object's type. Always has the value `ticket_state`. */ + type?: string; + /** The id of the ticket state */ + id?: string; + /** The category of the ticket state */ + category?: TicketState.Category; + /** The state the ticket is currently in, in a human readable form - visible in Intercom */ + internal_label?: string; + /** The state the ticket is currently in, in a human readable form - visible to customers, in the messenger, email and tickets portal. */ + external_label?: string; +} + +export namespace TicketState { + /** The category of the ticket state */ + export const Category = { + Submitted: "submitted", + InProgress: "in_progress", + WaitingOnCustomer: "waiting_on_customer", + Resolved: "resolved", + } as const; + export type Category = (typeof Category)[keyof typeof Category]; +} diff --git a/src/api/resources/tickets/types/TicketStateDetailed.ts b/src/api/resources/tickets/types/TicketStateDetailed.ts new file mode 100644 index 00000000..df97b118 --- /dev/null +++ b/src/api/resources/tickets/types/TicketStateDetailed.ts @@ -0,0 +1,44 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +/** + * A ticket state, used to define the state of a ticket. + */ +export interface TicketStateDetailed { + /** String representing the object's type. Always has the value `ticket_state`. */ + type?: string; + /** The id of the ticket state */ + id?: string; + /** The category of the ticket state */ + category?: TicketStateDetailed.Category; + /** The state the ticket is currently in, in a human readable form - visible in Intercom */ + internal_label?: string; + /** The state the ticket is currently in, in a human readable form - visible to customers, in the messenger, email and tickets portal. */ + external_label?: string; + /** Whether the ticket state is archived */ + archived?: boolean; + /** A list of ticket types associated with a given ticket state. */ + ticket_types?: TicketStateDetailed.TicketTypes; +} + +export namespace TicketStateDetailed { + /** The category of the ticket state */ + export const Category = { + Submitted: "submitted", + InProgress: "in_progress", + WaitingOnCustomer: "waiting_on_customer", + Resolved: "resolved", + } as const; + export type Category = (typeof Category)[keyof typeof Category]; + + /** + * A list of ticket types associated with a given ticket state. + */ + export interface TicketTypes { + /** String representing the object's type. Always has the value `list`. */ + type?: string; + /** A list of ticket type attributes associated with a given ticket type. */ + data?: (Intercom.TicketType | undefined)[]; + } +} diff --git a/src/api/resources/tickets/types/TicketType.ts b/src/api/resources/tickets/types/TicketType.ts index ae240f82..5ad0cd5d 100644 --- a/src/api/resources/tickets/types/TicketType.ts +++ b/src/api/resources/tickets/types/TicketType.ts @@ -1,44 +1,52 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A ticket type, used to define the data fields to be captured in a ticket. */ export interface TicketType { /** String representing the object's type. Always has the value `ticket_type`. */ - type: "ticket_type"; + type?: string; /** The id representing the ticket type. */ - id: string; + id?: string; /** Category of the Ticket Type. */ - category: TicketType.Category; + category?: TicketType.Category; /** The name of the ticket type */ - name: string; + name?: string; /** The description of the ticket type */ - description: string; + description?: string; /** The icon of the ticket type */ - icon: string; + icon?: string; /** The id of the workspace that the ticket type belongs to. */ - workspace_id: string; - ticket_type_attributes: Intercom.TicketTypeAttributeList; + workspace_id?: string; + ticket_type_attributes?: Intercom.TicketTypeAttributeList; + /** A list of ticket states associated with a given ticket type. */ + ticket_states?: TicketType.TicketStates; /** Whether the ticket type is archived or not. */ - archived: boolean; + archived?: boolean; /** The date and time the ticket type was created. */ - created_at: number; + created_at?: number; /** The date and time the ticket type was last updated. */ updated_at?: number; } export namespace TicketType { - /** - * Category of the Ticket Type. - */ - export type Category = "Customer" | "Back-office" | "Tracker"; + /** Category of the Ticket Type. */ export const Category = { Customer: "Customer", BackOffice: "Back-office", Tracker: "Tracker", } as const; + export type Category = (typeof Category)[keyof typeof Category]; + + /** + * A list of ticket states associated with a given ticket type. + */ + export interface TicketStates { + /** String representing the object's type. Always has the value `list`. */ + type?: string; + /** A list of ticket states associated with a given ticket type. */ + data?: (Intercom.TicketState | undefined)[]; + } } diff --git a/src/api/resources/tickets/types/TicketsReplyRequestBody.ts b/src/api/resources/tickets/types/TicketsReplyRequestBody.ts index e6c57710..f56d4a42 100644 --- a/src/api/resources/tickets/types/TicketsReplyRequestBody.ts +++ b/src/api/resources/tickets/types/TicketsReplyRequestBody.ts @@ -1,7 +1,5 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; export type TicketsReplyRequestBody = Intercom.ContactReplyTicketRequest | Intercom.AdminReplyTicketRequest; diff --git a/src/api/resources/tickets/types/index.ts b/src/api/resources/tickets/types/index.ts index 2bba4510..0802fc77 100644 --- a/src/api/resources/tickets/types/index.ts +++ b/src/api/resources/tickets/types/index.ts @@ -1,5 +1,8 @@ -export * from "./TicketsReplyRequestBody"; -export * from "./Ticket"; -export * from "./TicketContacts"; -export * from "./TicketPart"; -export * from "./TicketType"; +export * from "./DeleteTicketResponse.js"; +export * from "./Ticket.js"; +export * from "./TicketContacts.js"; +export * from "./TicketPart.js"; +export * from "./TicketState.js"; +export * from "./TicketStateDetailed.js"; +export * from "./TicketsReplyRequestBody.js"; +export * from "./TicketType.js"; diff --git a/src/api/resources/unstable/client/Client.ts b/src/api/resources/unstable/client/Client.ts index d05f4c7f..3058c14f 100644 --- a/src/api/resources/unstable/client/Client.ts +++ b/src/api/resources/unstable/client/Client.ts @@ -1,209 +1,214 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import { Admins } from "../resources/admins/client/Client"; -import { AiContent } from "../resources/aiContent/client/Client"; -import { Articles } from "../resources/articles/client/Client"; -import { AwayStatusReasons } from "../resources/awayStatusReasons/client/Client"; -import { Export } from "../resources/export/client/Client"; -import { HelpCenter } from "../resources/helpCenter/client/Client"; -import { Companies } from "../resources/companies/client/Client"; -import { Contacts } from "../resources/contacts/client/Client"; -import { Notes } from "../resources/notes/client/Client"; -import { SubscriptionTypes } from "../resources/subscriptionTypes/client/Client"; -import { Tags } from "../resources/tags/client/Client"; -import { Conversations } from "../resources/conversations/client/Client"; -import { CustomChannelEvents } from "../resources/customChannelEvents/client/Client"; -import { CustomObjectInstances } from "../resources/customObjectInstances/client/Client"; -import { DataAttributes } from "../resources/dataAttributes/client/Client"; -import { DataEvents } from "../resources/dataEvents/client/Client"; -import { DataExport } from "../resources/dataExport/client/Client"; -import { Jobs } from "../resources/jobs/client/Client"; -import { Messages } from "../resources/messages/client/Client"; -import { News } from "../resources/news/client/Client"; -import { Segments } from "../resources/segments/client/Client"; -import { Switch } from "../resources/switch/client/Client"; -import { Teams } from "../resources/teams/client/Client"; -import { TicketStates } from "../resources/ticketStates/client/Client"; -import { TicketTypeAttributes } from "../resources/ticketTypeAttributes/client/Client"; -import { TicketTypes } from "../resources/ticketTypes/client/Client"; -import { Tickets } from "../resources/tickets/client/Client"; -import { Visitors } from "../resources/visitors/client/Client"; - -export declare namespace Unstable { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { AdminsClient } from "../resources/admins/client/Client.js"; +import { AiContentClient } from "../resources/aiContent/client/Client.js"; +import { ArticlesClient } from "../resources/articles/client/Client.js"; +import { AwayStatusReasonsClient } from "../resources/awayStatusReasons/client/Client.js"; +import { BrandsClient } from "../resources/brands/client/Client.js"; +import { CallsClient } from "../resources/calls/client/Client.js"; +import { CompaniesClient } from "../resources/companies/client/Client.js"; +import { ContactsClient } from "../resources/contacts/client/Client.js"; +import { ConversationsClient } from "../resources/conversations/client/Client.js"; +import { CustomChannelEventsClient } from "../resources/customChannelEvents/client/Client.js"; +import { CustomObjectInstancesClient } from "../resources/customObjectInstances/client/Client.js"; +import { DataAttributesClient } from "../resources/dataAttributes/client/Client.js"; +import { DataEventsClient } from "../resources/dataEvents/client/Client.js"; +import { DataExportClient } from "../resources/dataExport/client/Client.js"; +import { EmailsClient } from "../resources/emails/client/Client.js"; +import { ExportClient } from "../resources/export/client/Client.js"; +import { HelpCenterClient } from "../resources/helpCenter/client/Client.js"; +import { InternalArticlesClient } from "../resources/internalArticles/client/Client.js"; +import { JobsClient } from "../resources/jobs/client/Client.js"; +import { MacrosClient } from "../resources/macros/client/Client.js"; +import { MessagesClient } from "../resources/messages/client/Client.js"; +import { NewsClient } from "../resources/news/client/Client.js"; +import { NotesClient } from "../resources/notes/client/Client.js"; +import { SegmentsClient } from "../resources/segments/client/Client.js"; +import { SubscriptionTypesClient } from "../resources/subscriptionTypes/client/Client.js"; +import { SwitchClient } from "../resources/switch/client/Client.js"; +import { TagsClient } from "../resources/tags/client/Client.js"; +import { TeamsClient } from "../resources/teams/client/Client.js"; +import { TicketStatesClient } from "../resources/ticketStates/client/Client.js"; +import { TicketsClient } from "../resources/tickets/client/Client.js"; +import { TicketTypeAttributesClient } from "../resources/ticketTypeAttributes/client/Client.js"; +import { TicketTypesClient } from "../resources/ticketTypes/client/Client.js"; +import { VisitorsClient } from "../resources/visitors/client/Client.js"; + +export declare namespace UnstableClient { + export interface Options extends BaseClientOptions {} } -export class Unstable { - protected _admins: Admins | undefined; - protected _aiContent: AiContent | undefined; - protected _articles: Articles | undefined; - protected _awayStatusReasons: AwayStatusReasons | undefined; - protected _export: Export | undefined; - protected _helpCenter: HelpCenter | undefined; - protected _companies: Companies | undefined; - protected _contacts: Contacts | undefined; - protected _notes: Notes | undefined; - protected _subscriptionTypes: SubscriptionTypes | undefined; - protected _tags: Tags | undefined; - protected _conversations: Conversations | undefined; - protected _customChannelEvents: CustomChannelEvents | undefined; - protected _customObjectInstances: CustomObjectInstances | undefined; - protected _dataAttributes: DataAttributes | undefined; - protected _dataEvents: DataEvents | undefined; - protected _dataExport: DataExport | undefined; - protected _jobs: Jobs | undefined; - protected _messages: Messages | undefined; - protected _news: News | undefined; - protected _segments: Segments | undefined; - protected _switch: Switch | undefined; - protected _teams: Teams | undefined; - protected _ticketStates: TicketStates | undefined; - protected _ticketTypeAttributes: TicketTypeAttributes | undefined; - protected _ticketTypes: TicketTypes | undefined; - protected _tickets: Tickets | undefined; - protected _visitors: Visitors | undefined; +export class UnstableClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + protected _admins: AdminsClient | undefined; + protected _aiContent: AiContentClient | undefined; + protected _articles: ArticlesClient | undefined; + protected _awayStatusReasons: AwayStatusReasonsClient | undefined; + protected _export: ExportClient | undefined; + protected _helpCenter: HelpCenterClient | undefined; + protected _internalArticles: InternalArticlesClient | undefined; + protected _companies: CompaniesClient | undefined; + protected _notes: NotesClient | undefined; + protected _contacts: ContactsClient | undefined; + protected _subscriptionTypes: SubscriptionTypesClient | undefined; + protected _tags: TagsClient | undefined; + protected _conversations: ConversationsClient | undefined; + protected _customChannelEvents: CustomChannelEventsClient | undefined; + protected _customObjectInstances: CustomObjectInstancesClient | undefined; + protected _dataAttributes: DataAttributesClient | undefined; + protected _dataEvents: DataEventsClient | undefined; + protected _dataExport: DataExportClient | undefined; + protected _jobs: JobsClient | undefined; + protected _macros: MacrosClient | undefined; + protected _messages: MessagesClient | undefined; + protected _news: NewsClient | undefined; + protected _segments: SegmentsClient | undefined; + protected _switch: SwitchClient | undefined; + protected _calls: CallsClient | undefined; + protected _teams: TeamsClient | undefined; + protected _ticketStates: TicketStatesClient | undefined; + protected _ticketTypeAttributes: TicketTypeAttributesClient | undefined; + protected _ticketTypes: TicketTypesClient | undefined; + protected _tickets: TicketsClient | undefined; + protected _visitors: VisitorsClient | undefined; + protected _brands: BrandsClient | undefined; + protected _emails: EmailsClient | undefined; + + constructor(options: UnstableClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + public get admins(): AdminsClient { + return (this._admins ??= new AdminsClient(this._options)); + } + + public get aiContent(): AiContentClient { + return (this._aiContent ??= new AiContentClient(this._options)); + } + + public get articles(): ArticlesClient { + return (this._articles ??= new ArticlesClient(this._options)); + } - constructor(protected readonly _options: Unstable.Options = {}) {} + public get awayStatusReasons(): AwayStatusReasonsClient { + return (this._awayStatusReasons ??= new AwayStatusReasonsClient(this._options)); + } + + public get export(): ExportClient { + return (this._export ??= new ExportClient(this._options)); + } - public get admins(): Admins { - return (this._admins ??= new Admins(this._options)); + public get helpCenter(): HelpCenterClient { + return (this._helpCenter ??= new HelpCenterClient(this._options)); } - public get aiContent(): AiContent { - return (this._aiContent ??= new AiContent(this._options)); + public get internalArticles(): InternalArticlesClient { + return (this._internalArticles ??= new InternalArticlesClient(this._options)); } - public get articles(): Articles { - return (this._articles ??= new Articles(this._options)); + public get companies(): CompaniesClient { + return (this._companies ??= new CompaniesClient(this._options)); } - public get awayStatusReasons(): AwayStatusReasons { - return (this._awayStatusReasons ??= new AwayStatusReasons(this._options)); + public get notes(): NotesClient { + return (this._notes ??= new NotesClient(this._options)); } - public get export(): Export { - return (this._export ??= new Export(this._options)); + public get contacts(): ContactsClient { + return (this._contacts ??= new ContactsClient(this._options)); } - public get helpCenter(): HelpCenter { - return (this._helpCenter ??= new HelpCenter(this._options)); + public get subscriptionTypes(): SubscriptionTypesClient { + return (this._subscriptionTypes ??= new SubscriptionTypesClient(this._options)); } - public get companies(): Companies { - return (this._companies ??= new Companies(this._options)); + public get tags(): TagsClient { + return (this._tags ??= new TagsClient(this._options)); } - public get contacts(): Contacts { - return (this._contacts ??= new Contacts(this._options)); + public get conversations(): ConversationsClient { + return (this._conversations ??= new ConversationsClient(this._options)); } - public get notes(): Notes { - return (this._notes ??= new Notes(this._options)); + public get customChannelEvents(): CustomChannelEventsClient { + return (this._customChannelEvents ??= new CustomChannelEventsClient(this._options)); } - public get subscriptionTypes(): SubscriptionTypes { - return (this._subscriptionTypes ??= new SubscriptionTypes(this._options)); + public get customObjectInstances(): CustomObjectInstancesClient { + return (this._customObjectInstances ??= new CustomObjectInstancesClient(this._options)); } - public get tags(): Tags { - return (this._tags ??= new Tags(this._options)); + public get dataAttributes(): DataAttributesClient { + return (this._dataAttributes ??= new DataAttributesClient(this._options)); } - public get conversations(): Conversations { - return (this._conversations ??= new Conversations(this._options)); + public get dataEvents(): DataEventsClient { + return (this._dataEvents ??= new DataEventsClient(this._options)); } - public get customChannelEvents(): CustomChannelEvents { - return (this._customChannelEvents ??= new CustomChannelEvents(this._options)); + public get dataExport(): DataExportClient { + return (this._dataExport ??= new DataExportClient(this._options)); } - public get customObjectInstances(): CustomObjectInstances { - return (this._customObjectInstances ??= new CustomObjectInstances(this._options)); + public get jobs(): JobsClient { + return (this._jobs ??= new JobsClient(this._options)); } - public get dataAttributes(): DataAttributes { - return (this._dataAttributes ??= new DataAttributes(this._options)); + public get macros(): MacrosClient { + return (this._macros ??= new MacrosClient(this._options)); } - public get dataEvents(): DataEvents { - return (this._dataEvents ??= new DataEvents(this._options)); + public get messages(): MessagesClient { + return (this._messages ??= new MessagesClient(this._options)); } - public get dataExport(): DataExport { - return (this._dataExport ??= new DataExport(this._options)); + public get news(): NewsClient { + return (this._news ??= new NewsClient(this._options)); } - public get jobs(): Jobs { - return (this._jobs ??= new Jobs(this._options)); + public get segments(): SegmentsClient { + return (this._segments ??= new SegmentsClient(this._options)); } - public get messages(): Messages { - return (this._messages ??= new Messages(this._options)); + public get switch(): SwitchClient { + return (this._switch ??= new SwitchClient(this._options)); } - public get news(): News { - return (this._news ??= new News(this._options)); + public get calls(): CallsClient { + return (this._calls ??= new CallsClient(this._options)); } - public get segments(): Segments { - return (this._segments ??= new Segments(this._options)); + public get teams(): TeamsClient { + return (this._teams ??= new TeamsClient(this._options)); } - public get switch(): Switch { - return (this._switch ??= new Switch(this._options)); + public get ticketStates(): TicketStatesClient { + return (this._ticketStates ??= new TicketStatesClient(this._options)); } - public get teams(): Teams { - return (this._teams ??= new Teams(this._options)); + public get ticketTypeAttributes(): TicketTypeAttributesClient { + return (this._ticketTypeAttributes ??= new TicketTypeAttributesClient(this._options)); } - public get ticketStates(): TicketStates { - return (this._ticketStates ??= new TicketStates(this._options)); + public get ticketTypes(): TicketTypesClient { + return (this._ticketTypes ??= new TicketTypesClient(this._options)); } - public get ticketTypeAttributes(): TicketTypeAttributes { - return (this._ticketTypeAttributes ??= new TicketTypeAttributes(this._options)); + public get tickets(): TicketsClient { + return (this._tickets ??= new TicketsClient(this._options)); } - public get ticketTypes(): TicketTypes { - return (this._ticketTypes ??= new TicketTypes(this._options)); + public get visitors(): VisitorsClient { + return (this._visitors ??= new VisitorsClient(this._options)); } - public get tickets(): Tickets { - return (this._tickets ??= new Tickets(this._options)); + public get brands(): BrandsClient { + return (this._brands ??= new BrandsClient(this._options)); } - public get visitors(): Visitors { - return (this._visitors ??= new Visitors(this._options)); + public get emails(): EmailsClient { + return (this._emails ??= new EmailsClient(this._options)); } } diff --git a/src/api/resources/unstable/errors/BadRequestError.ts b/src/api/resources/unstable/errors/BadRequestError.ts index d7e71d09..351933dd 100644 --- a/src/api/resources/unstable/errors/BadRequestError.ts +++ b/src/api/resources/unstable/errors/BadRequestError.ts @@ -1,9 +1,7 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as errors from "../../../../errors/index"; -import * as core from "../../../../core"; +import type * as core from "../../../../core/index.js"; +import * as errors from "../../../../errors/index.js"; export class BadRequestError extends errors.IntercomError { constructor(body?: unknown, rawResponse?: core.RawResponse) { diff --git a/src/api/resources/unstable/errors/ConflictError.ts b/src/api/resources/unstable/errors/ConflictError.ts new file mode 100644 index 00000000..afd826b8 --- /dev/null +++ b/src/api/resources/unstable/errors/ConflictError.ts @@ -0,0 +1,17 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as core from "../../../../core/index.js"; +import * as errors from "../../../../errors/index.js"; +import type * as Intercom from "../../../index.js"; + +export class ConflictError extends errors.IntercomError { + constructor(body: Intercom.unstable.Error_, rawResponse?: core.RawResponse) { + super({ + message: "ConflictError", + statusCode: 409, + body: body, + rawResponse: rawResponse, + }); + Object.setPrototypeOf(this, ConflictError.prototype); + } +} diff --git a/src/api/resources/unstable/errors/ForbiddenError.ts b/src/api/resources/unstable/errors/ForbiddenError.ts index c98ade42..a5eefa5f 100644 --- a/src/api/resources/unstable/errors/ForbiddenError.ts +++ b/src/api/resources/unstable/errors/ForbiddenError.ts @@ -1,10 +1,8 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as errors from "../../../../errors/index"; -import * as Intercom from "../../../index"; -import * as core from "../../../../core"; +import type * as core from "../../../../core/index.js"; +import * as errors from "../../../../errors/index.js"; +import type * as Intercom from "../../../index.js"; export class ForbiddenError extends errors.IntercomError { constructor(body: Intercom.unstable.Error_, rawResponse?: core.RawResponse) { diff --git a/src/api/resources/unstable/errors/InternalServerError.ts b/src/api/resources/unstable/errors/InternalServerError.ts index 6e6ad916..05de1b39 100644 --- a/src/api/resources/unstable/errors/InternalServerError.ts +++ b/src/api/resources/unstable/errors/InternalServerError.ts @@ -1,10 +1,8 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as errors from "../../../../errors/index"; -import * as Intercom from "../../../index"; -import * as core from "../../../../core"; +import type * as core from "../../../../core/index.js"; +import * as errors from "../../../../errors/index.js"; +import type * as Intercom from "../../../index.js"; export class InternalServerError extends errors.IntercomError { constructor(body: Intercom.unstable.Error_, rawResponse?: core.RawResponse) { diff --git a/src/api/resources/unstable/errors/NotFoundError.ts b/src/api/resources/unstable/errors/NotFoundError.ts index 323b5b44..2b6a1c39 100644 --- a/src/api/resources/unstable/errors/NotFoundError.ts +++ b/src/api/resources/unstable/errors/NotFoundError.ts @@ -1,9 +1,7 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as errors from "../../../../errors/index"; -import * as core from "../../../../core"; +import type * as core from "../../../../core/index.js"; +import * as errors from "../../../../errors/index.js"; export class NotFoundError extends errors.IntercomError { constructor(body?: unknown, rawResponse?: core.RawResponse) { diff --git a/src/api/resources/unstable/errors/TooManyRequestsError.ts b/src/api/resources/unstable/errors/TooManyRequestsError.ts index e9ff4d56..8213e523 100644 --- a/src/api/resources/unstable/errors/TooManyRequestsError.ts +++ b/src/api/resources/unstable/errors/TooManyRequestsError.ts @@ -1,10 +1,8 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as errors from "../../../../errors/index"; -import * as Intercom from "../../../index"; -import * as core from "../../../../core"; +import type * as core from "../../../../core/index.js"; +import * as errors from "../../../../errors/index.js"; +import type * as Intercom from "../../../index.js"; export class TooManyRequestsError extends errors.IntercomError { constructor(body: Intercom.unstable.Error_, rawResponse?: core.RawResponse) { diff --git a/src/api/resources/unstable/errors/UnauthorizedError.ts b/src/api/resources/unstable/errors/UnauthorizedError.ts index 33fb0bce..15ea9d4f 100644 --- a/src/api/resources/unstable/errors/UnauthorizedError.ts +++ b/src/api/resources/unstable/errors/UnauthorizedError.ts @@ -1,10 +1,8 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as errors from "../../../../errors/index"; -import * as Intercom from "../../../index"; -import * as core from "../../../../core"; +import type * as core from "../../../../core/index.js"; +import * as errors from "../../../../errors/index.js"; +import type * as Intercom from "../../../index.js"; export class UnauthorizedError extends errors.IntercomError { constructor(body: Intercom.unstable.Error_, rawResponse?: core.RawResponse) { diff --git a/src/api/resources/unstable/errors/UnprocessableEntityError.ts b/src/api/resources/unstable/errors/UnprocessableEntityError.ts index 912441d7..a2021d64 100644 --- a/src/api/resources/unstable/errors/UnprocessableEntityError.ts +++ b/src/api/resources/unstable/errors/UnprocessableEntityError.ts @@ -1,9 +1,7 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as errors from "../../../../errors/index"; -import * as core from "../../../../core"; +import type * as core from "../../../../core/index.js"; +import * as errors from "../../../../errors/index.js"; export class UnprocessableEntityError extends errors.IntercomError { constructor(body?: unknown, rawResponse?: core.RawResponse) { diff --git a/src/api/resources/unstable/errors/index.ts b/src/api/resources/unstable/errors/index.ts index 6190d905..200c43d1 100644 --- a/src/api/resources/unstable/errors/index.ts +++ b/src/api/resources/unstable/errors/index.ts @@ -1,7 +1,8 @@ -export * from "./BadRequestError"; -export * from "./UnauthorizedError"; -export * from "./NotFoundError"; -export * from "./TooManyRequestsError"; -export * from "./ForbiddenError"; -export * from "./UnprocessableEntityError"; -export * from "./InternalServerError"; +export * from "./BadRequestError.js"; +export * from "./ConflictError.js"; +export * from "./ForbiddenError.js"; +export * from "./InternalServerError.js"; +export * from "./NotFoundError.js"; +export * from "./TooManyRequestsError.js"; +export * from "./UnauthorizedError.js"; +export * from "./UnprocessableEntityError.js"; diff --git a/src/api/resources/unstable/index.ts b/src/api/resources/unstable/index.ts index d5c609c4..d73889d8 100644 --- a/src/api/resources/unstable/index.ts +++ b/src/api/resources/unstable/index.ts @@ -1,4 +1,4 @@ -export * from "./resources"; -export * from "./types"; -export * from "./errors"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./errors/index.js"; +export * from "./resources/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/admins/client/Client.ts b/src/api/resources/unstable/resources/admins/client/Client.ts index fad5ac42..ece2566e 100644 --- a/src/api/resources/unstable/resources/admins/client/Client.ts +++ b/src/api/resources/unstable/resources/admins/client/Client.ts @@ -1,79 +1,29 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Admins { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace AdminsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Admins */ -export class Admins { - constructor(protected readonly _options: Admins.Options = {}) {} +export class AdminsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: AdminsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * @@ -83,44 +33,42 @@ export class Admins { * > * > If you are building a custom "Log in with Intercom" flow for your site, and you call the `/me` endpoint to identify the logged-in user, you should not accept any sign-ins from users with unverified email addresses as it poses a potential impersonation security risk. * - * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * @param {AdminsClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.unstable.admins.identifyAdmin() */ public identifyAdmin( - requestOptions?: Admins.RequestOptions, + requestOptions?: AdminsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__identifyAdmin(requestOptions)); } private async __identifyAdmin( - requestOptions?: Admins.RequestOptions, + requestOptions?: AdminsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "me", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -137,28 +85,14 @@ export class Admins { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /me."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/me"); } /** * You can set an Admin as away for the Inbox. * * @param {Intercom.unstable.SetAwayAdminRequest} request - * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * @param {AdminsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -181,41 +115,41 @@ export class Admins { */ public setAwayAdmin( request: Intercom.unstable.SetAwayAdminRequest, - requestOptions?: Admins.RequestOptions, + requestOptions?: AdminsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__setAwayAdmin(request, requestOptions)); } private async __setAwayAdmin( request: Intercom.unstable.SetAwayAdminRequest, - requestOptions?: Admins.RequestOptions, + requestOptions?: AdminsClient.RequestOptions, ): Promise> { const { id, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `admins/${encodeURIComponent(id)}/away`, + `admins/${core.url.encodePathParam(id)}/away`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Admin | undefined, rawResponse: _response.rawResponse }; @@ -241,28 +175,14 @@ export class Admins { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /admins/{id}/away."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/admins/{id}/away"); } /** * You can get a log of activities by all admins in an app. * * @param {Intercom.unstable.ListActivityLogsRequest} request - * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * @param {AdminsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -274,47 +194,44 @@ export class Admins { */ public listActivityLogs( request: Intercom.unstable.ListActivityLogsRequest, - requestOptions?: Admins.RequestOptions, + requestOptions?: AdminsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listActivityLogs(request, requestOptions)); } private async __listActivityLogs( request: Intercom.unstable.ListActivityLogsRequest, - requestOptions?: Admins.RequestOptions, + requestOptions?: AdminsClient.RequestOptions, ): Promise> { const { created_at_after: createdAtAfter, created_at_before: createdAtBefore } = request; const _queryParams: Record = {}; - _queryParams["created_at_after"] = createdAtAfter; + _queryParams.created_at_after = createdAtAfter; if (createdAtBefore != null) { - _queryParams["created_at_before"] = createdAtBefore; + _queryParams.created_at_before = createdAtBefore; } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "admins/activity_logs", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ActivityLogList, rawResponse: _response.rawResponse }; @@ -336,64 +253,50 @@ export class Admins { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins/activity_logs."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/admins/activity_logs"); } /** * You can fetch a list of admins for a given workspace. * - * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * @param {AdminsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * * @example * await client.unstable.admins.listAdmins() */ - public listAdmins(requestOptions?: Admins.RequestOptions): core.HttpResponsePromise { + public listAdmins( + requestOptions?: AdminsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listAdmins(requestOptions)); } private async __listAdmins( - requestOptions?: Admins.RequestOptions, + requestOptions?: AdminsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "admins", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.AdminList, rawResponse: _response.rawResponse }; @@ -415,28 +318,14 @@ export class Admins { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/admins"); } /** * You can retrieve the details of a single admin. * * @param {Intercom.unstable.RetrieveAdminRequest} request - * @param {Admins.RequestOptions} requestOptions - Request-specific configuration. + * @param {AdminsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -448,40 +337,38 @@ export class Admins { */ public retrieveAdmin( request: Intercom.unstable.RetrieveAdminRequest, - requestOptions?: Admins.RequestOptions, + requestOptions?: AdminsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__retrieveAdmin(request, requestOptions)); } private async __retrieveAdmin( request: Intercom.unstable.RetrieveAdminRequest, - requestOptions?: Admins.RequestOptions, + requestOptions?: AdminsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `admins/${encodeURIComponent(id)}`, + `admins/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Admin | undefined, rawResponse: _response.rawResponse }; @@ -505,32 +392,6 @@ export class Admins { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /admins/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/admins/{id}"); } } diff --git a/src/api/resources/unstable/resources/admins/client/index.ts b/src/api/resources/unstable/resources/admins/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/admins/client/index.ts +++ b/src/api/resources/unstable/resources/admins/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/admins/client/requests/ListActivityLogsRequest.ts b/src/api/resources/unstable/resources/admins/client/requests/ListActivityLogsRequest.ts index 88dbafc4..f5608b49 100644 --- a/src/api/resources/unstable/resources/admins/client/requests/ListActivityLogsRequest.ts +++ b/src/api/resources/unstable/resources/admins/client/requests/ListActivityLogsRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -10,12 +8,8 @@ * } */ export interface ListActivityLogsRequest { - /** - * The start date that you request data for. It must be formatted as a UNIX timestamp. - */ + /** The start date that you request data for. It must be formatted as a UNIX timestamp. */ created_at_after: string; - /** - * The end date that you request data for. It must be formatted as a UNIX timestamp. - */ + /** The end date that you request data for. It must be formatted as a UNIX timestamp. */ created_at_before?: string; } diff --git a/src/api/resources/unstable/resources/admins/client/requests/RetrieveAdminRequest.ts b/src/api/resources/unstable/resources/admins/client/requests/RetrieveAdminRequest.ts index 49fb29b2..a7ae3952 100644 --- a/src/api/resources/unstable/resources/admins/client/requests/RetrieveAdminRequest.ts +++ b/src/api/resources/unstable/resources/admins/client/requests/RetrieveAdminRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface RetrieveAdminRequest { - /** - * The unique identifier of a given admin - */ + /** The unique identifier of a given admin */ id: number; } diff --git a/src/api/resources/unstable/resources/admins/client/requests/SetAwayAdminRequest.ts b/src/api/resources/unstable/resources/admins/client/requests/SetAwayAdminRequest.ts index 2b986684..7c270dec 100644 --- a/src/api/resources/unstable/resources/admins/client/requests/SetAwayAdminRequest.ts +++ b/src/api/resources/unstable/resources/admins/client/requests/SetAwayAdminRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -26,9 +24,7 @@ * } */ export interface SetAwayAdminRequest { - /** - * The unique identifier of a given admin - */ + /** The unique identifier of a given admin */ id: number; /** Set to "true" to change the status of the admin to away. */ away_mode_enabled: boolean; diff --git a/src/api/resources/unstable/resources/admins/client/requests/index.ts b/src/api/resources/unstable/resources/admins/client/requests/index.ts index 9ca82847..48a61029 100644 --- a/src/api/resources/unstable/resources/admins/client/requests/index.ts +++ b/src/api/resources/unstable/resources/admins/client/requests/index.ts @@ -1,3 +1,3 @@ -export { type SetAwayAdminRequest } from "./SetAwayAdminRequest"; -export { type ListActivityLogsRequest } from "./ListActivityLogsRequest"; -export { type RetrieveAdminRequest } from "./RetrieveAdminRequest"; +export type { ListActivityLogsRequest } from "./ListActivityLogsRequest.js"; +export type { RetrieveAdminRequest } from "./RetrieveAdminRequest.js"; +export type { SetAwayAdminRequest } from "./SetAwayAdminRequest.js"; diff --git a/src/api/resources/unstable/resources/admins/index.ts b/src/api/resources/unstable/resources/admins/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/admins/index.ts +++ b/src/api/resources/unstable/resources/admins/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/admins/types/Admin.ts b/src/api/resources/unstable/resources/admins/types/Admin.ts index 8e1794d6..113cc504 100644 --- a/src/api/resources/unstable/resources/admins/types/Admin.ts +++ b/src/api/resources/unstable/resources/admins/types/Admin.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * Admins are teammate accounts that have access to a workspace. diff --git a/src/api/resources/unstable/resources/admins/types/index.ts b/src/api/resources/unstable/resources/admins/types/index.ts index c950b2eb..838f94f4 100644 --- a/src/api/resources/unstable/resources/admins/types/index.ts +++ b/src/api/resources/unstable/resources/admins/types/index.ts @@ -1 +1 @@ -export * from "./Admin"; +export * from "./Admin.js"; diff --git a/src/api/resources/unstable/resources/aiAgent/index.ts b/src/api/resources/unstable/resources/aiAgent/index.ts index eea524d6..2f88e301 100644 --- a/src/api/resources/unstable/resources/aiAgent/index.ts +++ b/src/api/resources/unstable/resources/aiAgent/index.ts @@ -1 +1 @@ -export * from "./types"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/aiAgent/types/AiAgent.ts b/src/api/resources/unstable/resources/aiAgent/types/AiAgent.ts index bc37ada3..fb043f41 100644 --- a/src/api/resources/unstable/resources/aiAgent/types/AiAgent.ts +++ b/src/api/resources/unstable/resources/aiAgent/types/AiAgent.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * Data related to AI Agent involvement in the conversation. @@ -13,21 +11,22 @@ export interface AiAgent { /** The title of the source that triggered AI Agent involvement in the conversation. If this is `essentials_plan_setup` then it will return `null`. */ source_title?: string; /** The type of the last answer delivered by AI Agent. If no answer was delivered then this will return `null` */ - last_answer_type?: string; + last_answer_type?: AiAgent.LastAnswerType; /** The resolution state of AI Agent. If no AI or custom answer has been delivered then this will return `null`. */ - resolution_state?: string; + resolution_state?: AiAgent.ResolutionState; /** The customer satisfaction rating given to AI Agent, from 1-5. */ rating?: number; /** The customer satisfaction rating remark given to AI Agent. */ rating_remark?: string; + /** The time when the AI agent rating was created. */ + created_at?: number; + /** The time when the AI agent rating was last updated. */ + updated_at?: number; content_sources?: Intercom.unstable.ContentSourcesList; } export namespace AiAgent { - /** - * The type of the source that triggered AI Agent involvement in the conversation. - */ - export type SourceType = "essentials_plan_setup" | "profile" | "workflow" | "workflow_preview" | "fin_preview"; + /** The type of the source that triggered AI Agent involvement in the conversation. */ export const SourceType = { EssentialsPlanSetup: "essentials_plan_setup", Profile: "profile", @@ -35,4 +34,19 @@ export namespace AiAgent { WorkflowPreview: "workflow_preview", FinPreview: "fin_preview", } as const; + export type SourceType = (typeof SourceType)[keyof typeof SourceType]; + /** The type of the last answer delivered by AI Agent. If no answer was delivered then this will return `null` */ + export const LastAnswerType = { + AiAnswer: "ai_answer", + CustomAnswer: "custom_answer", + } as const; + export type LastAnswerType = (typeof LastAnswerType)[keyof typeof LastAnswerType]; + /** The resolution state of AI Agent. If no AI or custom answer has been delivered then this will return `null`. */ + export const ResolutionState = { + AssumedResolution: "assumed_resolution", + ConfirmedResolution: "confirmed_resolution", + Escalated: "escalated", + NegativeFeedback: "negative_feedback", + } as const; + export type ResolutionState = (typeof ResolutionState)[keyof typeof ResolutionState]; } diff --git a/src/api/resources/unstable/resources/aiAgent/types/index.ts b/src/api/resources/unstable/resources/aiAgent/types/index.ts index 05de312f..27ef772f 100644 --- a/src/api/resources/unstable/resources/aiAgent/types/index.ts +++ b/src/api/resources/unstable/resources/aiAgent/types/index.ts @@ -1 +1 @@ -export * from "./AiAgent"; +export * from "./AiAgent.js"; diff --git a/src/api/resources/unstable/resources/aiContent/client/Client.ts b/src/api/resources/unstable/resources/aiContent/client/Client.ts index 55afcd8a..cdb6bcae 100644 --- a/src/api/resources/unstable/resources/aiContent/client/Client.ts +++ b/src/api/resources/unstable/resources/aiContent/client/Client.ts @@ -1,72 +1,18 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; - -export declare namespace AiContent { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } +export declare namespace AiContentClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} } /** @@ -84,13 +30,17 @@ export declare namespace AiContent { * * You can then iterate through the content from that source via its API and POST it to the External Pages endpoint. That endpoint has an *external_id* parameter which allows you to specify the identifier from the source. The endpoint will then either create a new External Page or update an existing one as appropriate.", */ -export class AiContent { - constructor(protected readonly _options: AiContent.Options = {}) {} +export class AiContentClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: AiContentClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can retrieve a list of all content import sources for a workspace. * - * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -98,38 +48,36 @@ export class AiContent { * await client.unstable.aiContent.listContentImportSources() */ public listContentImportSources( - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listContentImportSources(requestOptions)); } private async __listContentImportSources( - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "ai/content_import_sources", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -154,28 +102,14 @@ export class AiContent { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ai/content_import_sources."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/ai/content_import_sources"); } /** * You can create a new content import source by sending a POST request to this endpoint. * * @param {Intercom.unstable.CreateContentImportSourceRequest} request - * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -186,40 +120,40 @@ export class AiContent { */ public createContentImportSource( request: Intercom.unstable.CreateContentImportSourceRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createContentImportSource(request, requestOptions)); } private async __createContentImportSource( request: Intercom.unstable.CreateContentImportSourceRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "ai/content_import_sources", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: { ...request, sync_behavior: "api" }, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -244,26 +178,12 @@ export class AiContent { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /ai/content_import_sources."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/ai/content_import_sources"); } /** * @param {Intercom.unstable.GetContentImportSourceRequest} request - * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -274,40 +194,38 @@ export class AiContent { */ public getContentImportSource( request: Intercom.unstable.GetContentImportSourceRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__getContentImportSource(request, requestOptions)); } private async __getContentImportSource( request: Intercom.unstable.GetContentImportSourceRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ai/content_import_sources/${encodeURIComponent(id)}`, + `ai/content_import_sources/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -332,30 +250,19 @@ export class AiContent { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /ai/content_import_sources/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/ai/content_import_sources/{id}", + ); } /** * You can update an existing content import source. * * @param {Intercom.unstable.UpdateContentImportSourceRequest} request - * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -368,41 +275,41 @@ export class AiContent { */ public updateContentImportSource( request: Intercom.unstable.UpdateContentImportSourceRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__updateContentImportSource(request, requestOptions)); } private async __updateContentImportSource( request: Intercom.unstable.UpdateContentImportSourceRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): Promise> { const { id, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ai/content_import_sources/${encodeURIComponent(id)}`, + `ai/content_import_sources/${core.url.encodePathParam(id)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -427,30 +334,19 @@ export class AiContent { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /ai/content_import_sources/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "PUT", + "/ai/content_import_sources/{id}", + ); } /** * You can delete a content import source by making a DELETE request this endpoint. This will also delete all external pages that were imported from this source. * * @param {Intercom.unstable.DeleteContentImportSourceRequest} request - * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -461,40 +357,38 @@ export class AiContent { */ public deleteContentImportSource( request: Intercom.unstable.DeleteContentImportSourceRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__deleteContentImportSource(request, requestOptions)); } private async __deleteContentImportSource( request: Intercom.unstable.DeleteContentImportSourceRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ai/content_import_sources/${encodeURIComponent(id)}`, + `ai/content_import_sources/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: undefined, rawResponse: _response.rawResponse }; @@ -516,29 +410,18 @@ export class AiContent { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /ai/content_import_sources/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/ai/content_import_sources/{id}", + ); } /** * You can retrieve a list of all external pages for a workspace. * - * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -546,38 +429,36 @@ export class AiContent { * await client.unstable.aiContent.listExternalPages() */ public listExternalPages( - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listExternalPages(requestOptions)); } private async __listExternalPages( - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "ai/external_pages", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ExternalPagesList, rawResponse: _response.rawResponse }; @@ -599,28 +480,14 @@ export class AiContent { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ai/external_pages."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/ai/external_pages"); } /** * You can create a new external page by sending a POST request to this endpoint. If an external page already exists with the specified source_id and external_id, it will be updated instead. * * @param {Intercom.unstable.CreateExternalPageRequest} request - * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -635,40 +502,40 @@ export class AiContent { */ public createExternalPage( request: Intercom.unstable.CreateExternalPageRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createExternalPage(request, requestOptions)); } private async __createExternalPage( request: Intercom.unstable.CreateExternalPageRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "ai/external_pages", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: { ...request, locale: "en" }, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ExternalPage, rawResponse: _response.rawResponse }; @@ -690,28 +557,14 @@ export class AiContent { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /ai/external_pages."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/ai/external_pages"); } /** * You can retrieve an external page. * * @param {Intercom.unstable.GetExternalPageRequest} request - * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -722,40 +575,38 @@ export class AiContent { */ public getExternalPage( request: Intercom.unstable.GetExternalPageRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__getExternalPage(request, requestOptions)); } private async __getExternalPage( request: Intercom.unstable.GetExternalPageRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ai/external_pages/${encodeURIComponent(id)}`, + `ai/external_pages/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ExternalPage, rawResponse: _response.rawResponse }; @@ -777,28 +628,14 @@ export class AiContent { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ai/external_pages/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/ai/external_pages/{id}"); } /** * You can update an existing external page (if it was created via the API). * * @param {Intercom.unstable.UpdateExternalPageRequest} request - * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -814,41 +651,41 @@ export class AiContent { */ public updateExternalPage( request: Intercom.unstable.UpdateExternalPageRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__updateExternalPage(request, requestOptions)); } private async __updateExternalPage( request: Intercom.unstable.UpdateExternalPageRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): Promise> { const { id, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ai/external_pages/${encodeURIComponent(id)}`, + `ai/external_pages/${core.url.encodePathParam(id)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: { ..._body, locale: "en" }, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ExternalPage, rawResponse: _response.rawResponse }; @@ -870,28 +707,14 @@ export class AiContent { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /ai/external_pages/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/ai/external_pages/{id}"); } /** * Sending a DELETE request for an external page will remove it from the content library UI and from being used for AI answers. * * @param {Intercom.unstable.DeleteExternalPageRequest} request - * @param {AiContent.RequestOptions} requestOptions - Request-specific configuration. + * @param {AiContentClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -902,40 +725,38 @@ export class AiContent { */ public deleteExternalPage( request: Intercom.unstable.DeleteExternalPageRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__deleteExternalPage(request, requestOptions)); } private async __deleteExternalPage( request: Intercom.unstable.DeleteExternalPageRequest, - requestOptions?: AiContent.RequestOptions, + requestOptions?: AiContentClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ai/external_pages/${encodeURIComponent(id)}`, + `ai/external_pages/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ExternalPage, rawResponse: _response.rawResponse }; @@ -957,32 +778,6 @@ export class AiContent { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /ai/external_pages/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/ai/external_pages/{id}"); } } diff --git a/src/api/resources/unstable/resources/aiContent/client/index.ts b/src/api/resources/unstable/resources/aiContent/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/aiContent/client/index.ts +++ b/src/api/resources/unstable/resources/aiContent/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/CreateContentImportSourceRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/CreateContentImportSourceRequest.ts index 06da2b4a..f487b162 100644 --- a/src/api/resources/unstable/resources/aiContent/client/requests/CreateContentImportSourceRequest.ts +++ b/src/api/resources/unstable/resources/aiContent/client/requests/CreateContentImportSourceRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -16,12 +14,10 @@ export interface CreateContentImportSourceRequest { } export namespace CreateContentImportSourceRequest { - /** - * The status of the content import source. - */ - export type Status = "active" | "deactivated"; + /** The status of the content import source. */ export const Status = { Active: "active", Deactivated: "deactivated", } as const; + export type Status = (typeof Status)[keyof typeof Status]; } diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/CreateExternalPageRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/CreateExternalPageRequest.ts index d0d37237..c4f5e914 100644 --- a/src/api/resources/unstable/resources/aiContent/client/requests/CreateExternalPageRequest.ts +++ b/src/api/resources/unstable/resources/aiContent/client/requests/CreateExternalPageRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/DeleteContentImportSourceRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/DeleteContentImportSourceRequest.ts index 6d921146..255ebcd0 100644 --- a/src/api/resources/unstable/resources/aiContent/client/requests/DeleteContentImportSourceRequest.ts +++ b/src/api/resources/unstable/resources/aiContent/client/requests/DeleteContentImportSourceRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DeleteContentImportSourceRequest { - /** - * The unique identifier for the content import source which is given by Intercom. - */ + /** The unique identifier for the content import source which is given by Intercom. */ id: string; } diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/DeleteExternalPageRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/DeleteExternalPageRequest.ts index cf5c01d3..87532df3 100644 --- a/src/api/resources/unstable/resources/aiContent/client/requests/DeleteExternalPageRequest.ts +++ b/src/api/resources/unstable/resources/aiContent/client/requests/DeleteExternalPageRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DeleteExternalPageRequest { - /** - * The unique identifier for the external page which is given by Intercom. - */ + /** The unique identifier for the external page which is given by Intercom. */ id: string; } diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/GetContentImportSourceRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/GetContentImportSourceRequest.ts index 68b77b47..199749ac 100644 --- a/src/api/resources/unstable/resources/aiContent/client/requests/GetContentImportSourceRequest.ts +++ b/src/api/resources/unstable/resources/aiContent/client/requests/GetContentImportSourceRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface GetContentImportSourceRequest { - /** - * The unique identifier for the content import source which is given by Intercom. - */ + /** The unique identifier for the content import source which is given by Intercom. */ id: string; } diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/GetExternalPageRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/GetExternalPageRequest.ts index bb1c963e..c7d50ef1 100644 --- a/src/api/resources/unstable/resources/aiContent/client/requests/GetExternalPageRequest.ts +++ b/src/api/resources/unstable/resources/aiContent/client/requests/GetExternalPageRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface GetExternalPageRequest { - /** - * The unique identifier for the external page which is given by Intercom. - */ + /** The unique identifier for the external page which is given by Intercom. */ id: string; } diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/UpdateContentImportSourceRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/UpdateContentImportSourceRequest.ts index bac30489..48401914 100644 --- a/src/api/resources/unstable/resources/aiContent/client/requests/UpdateContentImportSourceRequest.ts +++ b/src/api/resources/unstable/resources/aiContent/client/requests/UpdateContentImportSourceRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -11,9 +9,7 @@ * } */ export interface UpdateContentImportSourceRequest { - /** - * The unique identifier for the content import source which is given by Intercom. - */ + /** The unique identifier for the content import source which is given by Intercom. */ id: string; /** If you intend to create or update External Pages via the API, this should be set to `api`. You can not change the value to or from api. */ sync_behavior: UpdateContentImportSourceRequest.SyncBehavior; @@ -24,21 +20,17 @@ export interface UpdateContentImportSourceRequest { } export namespace UpdateContentImportSourceRequest { - /** - * If you intend to create or update External Pages via the API, this should be set to `api`. You can not change the value to or from api. - */ - export type SyncBehavior = "api" | "automated" | "manual"; + /** If you intend to create or update External Pages via the API, this should be set to `api`. You can not change the value to or from api. */ export const SyncBehavior = { Api: "api", Automated: "automated", Manual: "manual", } as const; - /** - * The status of the content import source. - */ - export type Status = "active" | "deactivated"; + export type SyncBehavior = (typeof SyncBehavior)[keyof typeof SyncBehavior]; + /** The status of the content import source. */ export const Status = { Active: "active", Deactivated: "deactivated", } as const; + export type Status = (typeof Status)[keyof typeof Status]; } diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/UpdateExternalPageRequest.ts b/src/api/resources/unstable/resources/aiContent/client/requests/UpdateExternalPageRequest.ts index 162b3c77..ccfddc5e 100644 --- a/src/api/resources/unstable/resources/aiContent/client/requests/UpdateExternalPageRequest.ts +++ b/src/api/resources/unstable/resources/aiContent/client/requests/UpdateExternalPageRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -14,9 +12,7 @@ * } */ export interface UpdateExternalPageRequest { - /** - * The unique identifier for the external page which is given by Intercom. - */ + /** The unique identifier for the external page which is given by Intercom. */ id: string; /** The title of the external page. */ title: string; diff --git a/src/api/resources/unstable/resources/aiContent/client/requests/index.ts b/src/api/resources/unstable/resources/aiContent/client/requests/index.ts index 820c72ee..2c010829 100644 --- a/src/api/resources/unstable/resources/aiContent/client/requests/index.ts +++ b/src/api/resources/unstable/resources/aiContent/client/requests/index.ts @@ -1,8 +1,8 @@ -export { type CreateContentImportSourceRequest } from "./CreateContentImportSourceRequest"; -export { type GetContentImportSourceRequest } from "./GetContentImportSourceRequest"; -export { type UpdateContentImportSourceRequest } from "./UpdateContentImportSourceRequest"; -export { type DeleteContentImportSourceRequest } from "./DeleteContentImportSourceRequest"; -export { type CreateExternalPageRequest } from "./CreateExternalPageRequest"; -export { type GetExternalPageRequest } from "./GetExternalPageRequest"; -export { type UpdateExternalPageRequest } from "./UpdateExternalPageRequest"; -export { type DeleteExternalPageRequest } from "./DeleteExternalPageRequest"; +export type { CreateContentImportSourceRequest } from "./CreateContentImportSourceRequest.js"; +export type { CreateExternalPageRequest } from "./CreateExternalPageRequest.js"; +export type { DeleteContentImportSourceRequest } from "./DeleteContentImportSourceRequest.js"; +export type { DeleteExternalPageRequest } from "./DeleteExternalPageRequest.js"; +export type { GetContentImportSourceRequest } from "./GetContentImportSourceRequest.js"; +export type { GetExternalPageRequest } from "./GetExternalPageRequest.js"; +export type { UpdateContentImportSourceRequest } from "./UpdateContentImportSourceRequest.js"; +export type { UpdateExternalPageRequest } from "./UpdateExternalPageRequest.js"; diff --git a/src/api/resources/unstable/resources/aiContent/index.ts b/src/api/resources/unstable/resources/aiContent/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/aiContent/index.ts +++ b/src/api/resources/unstable/resources/aiContent/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/aiContent/types/ContentImportSource.ts b/src/api/resources/unstable/resources/aiContent/types/ContentImportSource.ts index ef5cd352..e65d8d1a 100644 --- a/src/api/resources/unstable/resources/aiContent/types/ContentImportSource.ts +++ b/src/api/resources/unstable/resources/aiContent/types/ContentImportSource.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * An external source for External Pages that you add to your Fin Content Library. @@ -25,21 +23,17 @@ export interface ContentImportSource { } export namespace ContentImportSource { - /** - * If you intend to create or update External Pages via the API, this should be set to `api`. - */ - export type SyncBehavior = "api" | "automatic" | "manual"; + /** If you intend to create or update External Pages via the API, this should be set to `api`. */ export const SyncBehavior = { Api: "api", Automatic: "automatic", Manual: "manual", } as const; - /** - * The status of the content import source. - */ - export type Status = "active" | "deactivated"; + export type SyncBehavior = (typeof SyncBehavior)[keyof typeof SyncBehavior]; + /** The status of the content import source. */ export const Status = { Active: "active", Deactivated: "deactivated", } as const; + export type Status = (typeof Status)[keyof typeof Status]; } diff --git a/src/api/resources/unstable/resources/aiContent/types/ContentImportSourcesList.ts b/src/api/resources/unstable/resources/aiContent/types/ContentImportSourcesList.ts index ede951a5..ca3dfb3a 100644 --- a/src/api/resources/unstable/resources/aiContent/types/ContentImportSourcesList.ts +++ b/src/api/resources/unstable/resources/aiContent/types/ContentImportSourcesList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * This will return a list of the content import sources for the App. diff --git a/src/api/resources/unstable/resources/aiContent/types/ExternalPage.ts b/src/api/resources/unstable/resources/aiContent/types/ExternalPage.ts index 93a5eaf4..97afb31c 100644 --- a/src/api/resources/unstable/resources/aiContent/types/ExternalPage.ts +++ b/src/api/resources/unstable/resources/aiContent/types/ExternalPage.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * External pages that you have added to your Fin Content Library. diff --git a/src/api/resources/unstable/resources/aiContent/types/ExternalPagesList.ts b/src/api/resources/unstable/resources/aiContent/types/ExternalPagesList.ts index d3c610c2..94172e4f 100644 --- a/src/api/resources/unstable/resources/aiContent/types/ExternalPagesList.ts +++ b/src/api/resources/unstable/resources/aiContent/types/ExternalPagesList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * This will return a list of external pages for the App. diff --git a/src/api/resources/unstable/resources/aiContent/types/index.ts b/src/api/resources/unstable/resources/aiContent/types/index.ts index a1b39227..4a084844 100644 --- a/src/api/resources/unstable/resources/aiContent/types/index.ts +++ b/src/api/resources/unstable/resources/aiContent/types/index.ts @@ -1,4 +1,4 @@ -export * from "./ContentImportSource"; -export * from "./ContentImportSourcesList"; -export * from "./ExternalPage"; -export * from "./ExternalPagesList"; +export * from "./ContentImportSource.js"; +export * from "./ContentImportSourcesList.js"; +export * from "./ExternalPage.js"; +export * from "./ExternalPagesList.js"; diff --git a/src/api/resources/unstable/resources/aiContentSource/index.ts b/src/api/resources/unstable/resources/aiContentSource/index.ts index eea524d6..2f88e301 100644 --- a/src/api/resources/unstable/resources/aiContentSource/index.ts +++ b/src/api/resources/unstable/resources/aiContentSource/index.ts @@ -1 +1 @@ -export * from "./types"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/aiContentSource/types/ContentSource.ts b/src/api/resources/unstable/resources/aiContentSource/types/ContentSource.ts index 3baaae4a..9b504015 100644 --- a/src/api/resources/unstable/resources/aiContentSource/types/ContentSource.ts +++ b/src/api/resources/unstable/resources/aiContentSource/types/ContentSource.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The content source used by AI Agent in the conversation. @@ -17,10 +15,7 @@ export interface ContentSource { } export namespace ContentSource { - /** - * The type of the content source. - */ - export type ContentType = "file" | "article" | "external_content" | "content_snippet" | "workflow_connector_action"; + /** The type of the content source. */ export const ContentType = { File: "file", Article: "article", @@ -28,4 +23,5 @@ export namespace ContentSource { ContentSnippet: "content_snippet", WorkflowConnectorAction: "workflow_connector_action", } as const; + export type ContentType = (typeof ContentType)[keyof typeof ContentType]; } diff --git a/src/api/resources/unstable/resources/aiContentSource/types/index.ts b/src/api/resources/unstable/resources/aiContentSource/types/index.ts index 68047f7e..190780ca 100644 --- a/src/api/resources/unstable/resources/aiContentSource/types/index.ts +++ b/src/api/resources/unstable/resources/aiContentSource/types/index.ts @@ -1 +1 @@ -export * from "./ContentSource"; +export * from "./ContentSource.js"; diff --git a/src/api/resources/unstable/resources/articles/client/Client.ts b/src/api/resources/unstable/resources/articles/client/Client.ts index ec87cbce..5ab11f3e 100644 --- a/src/api/resources/unstable/resources/articles/client/Client.ts +++ b/src/api/resources/unstable/resources/articles/client/Client.ts @@ -1,79 +1,29 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Articles { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace ArticlesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Articles */ -export class Articles { - constructor(protected readonly _options: Articles.Options = {}) {} +export class ArticlesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: ArticlesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of all articles by making a GET request to `https://api.intercom.io/articles`. @@ -82,7 +32,7 @@ export class Articles { * > * > Articles will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated articles first. * - * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * @param {ArticlesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -90,38 +40,36 @@ export class Articles { * await client.unstable.articles.listArticles() */ public listArticles( - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listArticles(requestOptions)); } private async __listArticles( - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "articles", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ArticleList, rawResponse: _response.rawResponse }; @@ -143,28 +91,14 @@ export class Articles { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/articles"); } /** * You can create a new article by making a POST request to `https://api.intercom.io/articles`. * * @param {unknown} request - * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * @param {ArticlesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -176,40 +110,40 @@ export class Articles { */ public createArticle( request?: unknown, - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createArticle(request, requestOptions)); } private async __createArticle( request?: unknown, - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "articles", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Article, rawResponse: _response.rawResponse }; @@ -233,28 +167,14 @@ export class Articles { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /articles."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/articles"); } /** * You can fetch the details of a single article by making a GET request to `https://api.intercom.io/articles/`. * * @param {Intercom.unstable.RetrieveArticleRequest} request - * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * @param {ArticlesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -266,40 +186,38 @@ export class Articles { */ public retrieveArticle( request: Intercom.unstable.RetrieveArticleRequest, - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__retrieveArticle(request, requestOptions)); } private async __retrieveArticle( request: Intercom.unstable.RetrieveArticleRequest, - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `articles/${encodeURIComponent(id)}`, + `articles/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Article, rawResponse: _response.rawResponse }; @@ -323,28 +241,14 @@ export class Articles { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/articles/{id}"); } /** * You can delete a single article by making a DELETE request to `https://api.intercom.io/articles/`. * * @param {Intercom.unstable.DeleteArticleRequest} request - * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * @param {ArticlesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -356,40 +260,38 @@ export class Articles { */ public deleteArticle( request: Intercom.unstable.DeleteArticleRequest, - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__deleteArticle(request, requestOptions)); } private async __deleteArticle( request: Intercom.unstable.DeleteArticleRequest, - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `articles/${encodeURIComponent(id)}`, + `articles/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -416,91 +318,76 @@ export class Articles { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /articles/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/articles/{id}"); } /** * You can search for articles by making a GET request to `https://api.intercom.io/articles/search`. * * @param {Intercom.unstable.SearchArticlesRequest} request - * @param {Articles.RequestOptions} requestOptions - Request-specific configuration. + * @param {ArticlesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * * @example * await client.unstable.articles.searchArticles({ * phrase: "Getting started", - * state: "published" + * state: "published", + * help_center_id: 1, + * highlight: true * }) */ public searchArticles( request: Intercom.unstable.SearchArticlesRequest = {}, - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__searchArticles(request, requestOptions)); } private async __searchArticles( request: Intercom.unstable.SearchArticlesRequest = {}, - requestOptions?: Articles.RequestOptions, + requestOptions?: ArticlesClient.RequestOptions, ): Promise> { const { phrase, state, help_center_id: helpCenterId, highlight } = request; const _queryParams: Record = {}; if (phrase != null) { - _queryParams["phrase"] = phrase; + _queryParams.phrase = phrase; } if (state != null) { - _queryParams["state"] = state; + _queryParams.state = state; } if (helpCenterId != null) { - _queryParams["help_center_id"] = helpCenterId.toString(); + _queryParams.help_center_id = helpCenterId.toString(); } if (highlight != null) { - _queryParams["highlight"] = highlight.toString(); + _queryParams.highlight = highlight.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "articles/search", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -525,32 +412,6 @@ export class Articles { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /articles/search."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/articles/search"); } } diff --git a/src/api/resources/unstable/resources/articles/client/index.ts b/src/api/resources/unstable/resources/articles/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/articles/client/index.ts +++ b/src/api/resources/unstable/resources/articles/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/articles/client/requests/DeleteArticleRequest.ts b/src/api/resources/unstable/resources/articles/client/requests/DeleteArticleRequest.ts index 51b8ba6a..3429b3ea 100644 --- a/src/api/resources/unstable/resources/articles/client/requests/DeleteArticleRequest.ts +++ b/src/api/resources/unstable/resources/articles/client/requests/DeleteArticleRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DeleteArticleRequest { - /** - * The unique identifier for the article which is given by Intercom. - */ + /** The unique identifier for the article which is given by Intercom. */ id: number; } diff --git a/src/api/resources/unstable/resources/articles/client/requests/RetrieveArticleRequest.ts b/src/api/resources/unstable/resources/articles/client/requests/RetrieveArticleRequest.ts index d9920ed0..b1b95775 100644 --- a/src/api/resources/unstable/resources/articles/client/requests/RetrieveArticleRequest.ts +++ b/src/api/resources/unstable/resources/articles/client/requests/RetrieveArticleRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface RetrieveArticleRequest { - /** - * The unique identifier for the article which is given by Intercom. - */ + /** The unique identifier for the article which is given by Intercom. */ id: number; } diff --git a/src/api/resources/unstable/resources/articles/client/requests/SearchArticlesRequest.ts b/src/api/resources/unstable/resources/articles/client/requests/SearchArticlesRequest.ts index 7c07777d..3416dd98 100644 --- a/src/api/resources/unstable/resources/articles/client/requests/SearchArticlesRequest.ts +++ b/src/api/resources/unstable/resources/articles/client/requests/SearchArticlesRequest.ts @@ -1,29 +1,21 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { * phrase: "Getting started", - * state: "published" + * state: "published", + * help_center_id: 1, + * highlight: true * } */ export interface SearchArticlesRequest { - /** - * The phrase within your articles to search for. - */ + /** The phrase within your articles to search for. */ phrase?: string; - /** - * The state of the Articles returned. One of `published`, `draft` or `all`. - */ + /** The state of the Articles returned. One of `published`, `draft` or `all`. */ state?: string; - /** - * The ID of the Help Center to search in. - */ + /** The ID of the Help Center to search in. */ help_center_id?: number; - /** - * Return a highlighted version of the matching content within your articles. Refer to the response schema for more details. - */ + /** Return a highlighted version of the matching content within your articles. Refer to the response schema for more details. */ highlight?: boolean; } diff --git a/src/api/resources/unstable/resources/articles/client/requests/index.ts b/src/api/resources/unstable/resources/articles/client/requests/index.ts index a0beaf5f..e0a15786 100644 --- a/src/api/resources/unstable/resources/articles/client/requests/index.ts +++ b/src/api/resources/unstable/resources/articles/client/requests/index.ts @@ -1,3 +1,3 @@ -export { type RetrieveArticleRequest } from "./RetrieveArticleRequest"; -export { type DeleteArticleRequest } from "./DeleteArticleRequest"; -export { type SearchArticlesRequest } from "./SearchArticlesRequest"; +export type { DeleteArticleRequest } from "./DeleteArticleRequest.js"; +export type { RetrieveArticleRequest } from "./RetrieveArticleRequest.js"; +export type { SearchArticlesRequest } from "./SearchArticlesRequest.js"; diff --git a/src/api/resources/unstable/resources/articles/index.ts b/src/api/resources/unstable/resources/articles/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/articles/index.ts +++ b/src/api/resources/unstable/resources/articles/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/articles/types/Article.ts b/src/api/resources/unstable/resources/articles/types/Article.ts index adb8fda9..cab08a5d 100644 --- a/src/api/resources/unstable/resources/articles/types/Article.ts +++ b/src/api/resources/unstable/resources/articles/types/Article.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * The Articles API is a central place to gather all information and take actions on your articles. Articles can live within collections and sections, or alternatively they can stand alone. diff --git a/src/api/resources/unstable/resources/articles/types/ArticleListItem.ts b/src/api/resources/unstable/resources/articles/types/ArticleListItem.ts index 01c385fe..9c33e430 100644 --- a/src/api/resources/unstable/resources/articles/types/ArticleListItem.ts +++ b/src/api/resources/unstable/resources/articles/types/ArticleListItem.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * The data returned about your articles when you list them. @@ -42,12 +40,10 @@ export interface ArticleListItem { } export namespace ArticleListItem { - /** - * Whether the article is `published` or is a `draft`. For multilingual articles, this will be the state of the default language's content. - */ - export type State = "published" | "draft"; + /** Whether the article is `published` or is a `draft`. For multilingual articles, this will be the state of the default language's content. */ export const State = { Published: "published", Draft: "draft", } as const; + export type State = (typeof State)[keyof typeof State]; } diff --git a/src/api/resources/unstable/resources/articles/types/ArticleSearchHighlights.ts b/src/api/resources/unstable/resources/articles/types/ArticleSearchHighlights.ts index 5e1f607b..c80f22fa 100644 --- a/src/api/resources/unstable/resources/articles/types/ArticleSearchHighlights.ts +++ b/src/api/resources/unstable/resources/articles/types/ArticleSearchHighlights.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The highlighted results of an Article search. In the examples provided my search query is always "my query". @@ -29,14 +27,12 @@ export namespace ArticleSearchHighlights { } export namespace Item { - /** - * The type of text - `highlight` or `plain`. - */ - export type Type = "highlight" | "plain"; + /** The type of text - `highlight` or `plain`. */ export const Type = { Highlight: "highlight", Plain: "plain", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } } @@ -54,14 +50,12 @@ export namespace ArticleSearchHighlights { } export namespace Item { - /** - * The type of text - `highlight` or `plain`. - */ - export type Type = "highlight" | "plain"; + /** The type of text - `highlight` or `plain`. */ export const Type = { Highlight: "highlight", Plain: "plain", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } } } diff --git a/src/api/resources/unstable/resources/articles/types/ArticleSearchResponse.ts b/src/api/resources/unstable/resources/articles/types/ArticleSearchResponse.ts index 38cd179a..71b72609 100644 --- a/src/api/resources/unstable/resources/articles/types/ArticleSearchResponse.ts +++ b/src/api/resources/unstable/resources/articles/types/ArticleSearchResponse.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * The results of an Article search diff --git a/src/api/resources/unstable/resources/articles/types/InternalArticle.ts b/src/api/resources/unstable/resources/articles/types/InternalArticle.ts new file mode 100644 index 00000000..9cea2830 --- /dev/null +++ b/src/api/resources/unstable/resources/articles/types/InternalArticle.ts @@ -0,0 +1,8 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../../index.js"; + +/** + * The Internal Articles API is a central place to gather all information and take actions on your internal articles. + */ +export type InternalArticle = Intercom.unstable.InternalArticleListItem; diff --git a/src/api/resources/unstable/resources/articles/types/index.ts b/src/api/resources/unstable/resources/articles/types/index.ts index 815412c7..ac1a15f9 100644 --- a/src/api/resources/unstable/resources/articles/types/index.ts +++ b/src/api/resources/unstable/resources/articles/types/index.ts @@ -1,4 +1,5 @@ -export * from "./Article"; -export * from "./ArticleListItem"; -export * from "./ArticleSearchHighlights"; -export * from "./ArticleSearchResponse"; +export * from "./Article.js"; +export * from "./ArticleListItem.js"; +export * from "./ArticleSearchHighlights.js"; +export * from "./ArticleSearchResponse.js"; +export * from "./InternalArticle.js"; diff --git a/src/api/resources/unstable/resources/awayStatusReasons/client/Client.ts b/src/api/resources/unstable/resources/awayStatusReasons/client/Client.ts index 9ff1532d..5be942d3 100644 --- a/src/api/resources/unstable/resources/awayStatusReasons/client/Client.ts +++ b/src/api/resources/unstable/resources/awayStatusReasons/client/Client.ts @@ -1,84 +1,34 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace AwayStatusReasons { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace AwayStatusReasonsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Away Status Reasons */ -export class AwayStatusReasons { - constructor(protected readonly _options: AwayStatusReasons.Options = {}) {} +export class AwayStatusReasonsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: AwayStatusReasonsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * Returns a list of all away status reasons configured for the workspace, including deleted ones. * - * @param {AwayStatusReasons.RequestOptions} requestOptions - Request-specific configuration. + * @param {AwayStatusReasonsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -86,38 +36,36 @@ export class AwayStatusReasons { * await client.unstable.awayStatusReasons.listAwayStatusReasons() */ public listAwayStatusReasons( - requestOptions?: AwayStatusReasons.RequestOptions, + requestOptions?: AwayStatusReasonsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listAwayStatusReasons(requestOptions)); } private async __listAwayStatusReasons( - requestOptions?: AwayStatusReasons.RequestOptions, + requestOptions?: AwayStatusReasonsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "away_status_reasons", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.AwayStatusReason[], rawResponse: _response.rawResponse }; @@ -139,32 +87,6 @@ export class AwayStatusReasons { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /away_status_reasons."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/away_status_reasons"); } } diff --git a/src/api/resources/unstable/resources/awayStatusReasons/index.ts b/src/api/resources/unstable/resources/awayStatusReasons/index.ts index 5ec76921..914b8c3c 100644 --- a/src/api/resources/unstable/resources/awayStatusReasons/index.ts +++ b/src/api/resources/unstable/resources/awayStatusReasons/index.ts @@ -1 +1 @@ -export * from "./client"; +export * from "./client/index.js"; diff --git a/src/api/resources/unstable/resources/brands/client/Client.ts b/src/api/resources/unstable/resources/brands/client/Client.ts new file mode 100644 index 00000000..29540dc4 --- /dev/null +++ b/src/api/resources/unstable/resources/brands/client/Client.ts @@ -0,0 +1,167 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; + +export declare namespace BrandsClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * Everything about your Brands + */ +export class BrandsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: BrandsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * Retrieves all brands for the workspace, including the default brand. + * The default brand id always matches the workspace + * + * @param {BrandsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.brands.listBrands() + */ + public listBrands( + requestOptions?: BrandsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listBrands(requestOptions)); + } + + private async __listBrands( + requestOptions?: BrandsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "brands", + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.BrandList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/brands"); + } + + /** + * Fetches a specific brand by its unique identifier + * + * @param {Intercom.unstable.RetrieveBrandRequest} request + * @param {BrandsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.brands.retrieveBrand({ + * id: "id" + * }) + */ + public retrieveBrand( + request: Intercom.unstable.RetrieveBrandRequest, + requestOptions?: BrandsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveBrand(request, requestOptions)); + } + + private async __retrieveBrand( + request: Intercom.unstable.RetrieveBrandRequest, + requestOptions?: BrandsClient.RequestOptions, + ): Promise> { + const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `brands/${core.url.encodePathParam(id)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Brand, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/brands/{id}"); + } +} diff --git a/src/api/resources/unstable/resources/brands/client/index.ts b/src/api/resources/unstable/resources/brands/client/index.ts new file mode 100644 index 00000000..195f9aa8 --- /dev/null +++ b/src/api/resources/unstable/resources/brands/client/index.ts @@ -0,0 +1 @@ +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/brands/client/requests/RetrieveBrandRequest.ts b/src/api/resources/unstable/resources/brands/client/requests/RetrieveBrandRequest.ts new file mode 100644 index 00000000..fc52ec4e --- /dev/null +++ b/src/api/resources/unstable/resources/brands/client/requests/RetrieveBrandRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * id: "id" + * } + */ +export interface RetrieveBrandRequest { + /** The unique identifier of the brand */ + id: string; +} diff --git a/src/api/resources/unstable/resources/brands/client/requests/index.ts b/src/api/resources/unstable/resources/brands/client/requests/index.ts new file mode 100644 index 00000000..813c2ce1 --- /dev/null +++ b/src/api/resources/unstable/resources/brands/client/requests/index.ts @@ -0,0 +1 @@ +export type { RetrieveBrandRequest } from "./RetrieveBrandRequest.js"; diff --git a/src/api/resources/unstable/resources/brands/index.ts b/src/api/resources/unstable/resources/brands/index.ts new file mode 100644 index 00000000..d9adb1af --- /dev/null +++ b/src/api/resources/unstable/resources/brands/index.ts @@ -0,0 +1,2 @@ +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/brands/types/Brand.ts b/src/api/resources/unstable/resources/brands/types/Brand.ts new file mode 100644 index 00000000..53a416af --- /dev/null +++ b/src/api/resources/unstable/resources/brands/types/Brand.ts @@ -0,0 +1,23 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Represents a branding configuration for the workspace + */ +export interface Brand { + /** The type of object */ + type?: string; + /** Unique brand identifier. For default brand, matches the workspace ID */ + id?: string; + /** Display name of the brand */ + name?: string; + /** Whether this is the workspace's default brand */ + is_default?: boolean; + /** Unix timestamp of brand creation */ + created_at?: number; + /** Unix timestamp of last modification */ + updated_at?: number; + /** Associated help center identifier */ + help_center_id?: string; + /** Default email settings ID for this brand */ + default_address_settings_id?: string; +} diff --git a/src/api/resources/unstable/resources/brands/types/BrandList.ts b/src/api/resources/unstable/resources/brands/types/BrandList.ts new file mode 100644 index 00000000..3d7330de --- /dev/null +++ b/src/api/resources/unstable/resources/brands/types/BrandList.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../../index.js"; + +/** + * A list of brands + */ +export interface BrandList { + /** The type of object */ + type?: string; + data?: Intercom.unstable.Brand[]; +} diff --git a/src/api/resources/unstable/resources/brands/types/index.ts b/src/api/resources/unstable/resources/brands/types/index.ts new file mode 100644 index 00000000..c0d308e0 --- /dev/null +++ b/src/api/resources/unstable/resources/brands/types/index.ts @@ -0,0 +1,2 @@ +export * from "./Brand.js"; +export * from "./BrandList.js"; diff --git a/src/api/resources/unstable/resources/calls/client/Client.ts b/src/api/resources/unstable/resources/calls/client/Client.ts new file mode 100644 index 00000000..24f1b6f6 --- /dev/null +++ b/src/api/resources/unstable/resources/calls/client/Client.ts @@ -0,0 +1,710 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; + +export declare namespace CallsClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * Everything about your Calls + */ +export class CallsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: CallsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * Retrieve a paginated list of calls. + * + * @param {Intercom.unstable.ListCallsRequest} request + * @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.calls.listCalls({ + * page: 1, + * per_page: 1 + * }) + */ + public listCalls( + request: Intercom.unstable.ListCallsRequest = {}, + requestOptions?: CallsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listCalls(request, requestOptions)); + } + + private async __listCalls( + request: Intercom.unstable.ListCallsRequest = {}, + requestOptions?: CallsClient.RequestOptions, + ): Promise> { + const { page, per_page: perPage } = request; + const _queryParams: Record = {}; + if (page != null) { + _queryParams.page = page.toString(); + } + + if (perPage != null) { + _queryParams.per_page = perPage.toString(); + } + + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "calls", + ), + method: "GET", + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.CallList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/calls"); + } + + /** + * Retrieve a single call by id. + * + * @param {Intercom.unstable.ShowCallRequest} request + * @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.calls.showCall({ + * id: "id" + * }) + */ + public showCall( + request: Intercom.unstable.ShowCallRequest, + requestOptions?: CallsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__showCall(request, requestOptions)); + } + + private async __showCall( + request: Intercom.unstable.ShowCallRequest, + requestOptions?: CallsClient.RequestOptions, + ): Promise> { + const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `calls/${core.url.encodePathParam(id)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Call, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/calls/{id}"); + } + + /** + * Redirects to a signed URL for the call's recording if it exists. + * + * @param {Intercom.unstable.ShowCallRecordingRequest} request + * @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.calls.showCallRecording({ + * id: "id" + * }) + */ + public showCallRecording( + request: Intercom.unstable.ShowCallRecordingRequest, + requestOptions?: CallsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__showCallRecording(request, requestOptions)); + } + + private async __showCallRecording( + request: Intercom.unstable.ShowCallRecordingRequest, + requestOptions?: CallsClient.RequestOptions, + ): Promise> { + const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `calls/${core.url.encodePathParam(id)}/recording`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: undefined, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/calls/{id}/recording"); + } + + /** + * Returns the transcript for the specified call as a downloadable text file. + * + * @param {Intercom.unstable.ShowCallTranscriptRequest} request + * @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.calls.showCallTranscript({ + * id: "id" + * }) + */ + public showCallTranscript( + request: Intercom.unstable.ShowCallTranscriptRequest, + requestOptions?: CallsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__showCallTranscript(request, requestOptions)); + } + + private async __showCallTranscript( + request: Intercom.unstable.ShowCallTranscriptRequest, + requestOptions?: CallsClient.RequestOptions, + ): Promise> { + const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `calls/${core.url.encodePathParam(id)}/transcript`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + responseType: "text", + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as string, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/calls/{id}/transcript"); + } + + /** + * Retrieve calls by a list of conversation ids and include transcripts when available. + * A maximum of 20 `conversation_ids` can be provided. If none are provided or more than 20 are provided, a 400 error is returned. + * + * @param {Intercom.unstable.ListCallsWithTranscriptsRequest} request + * @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.calls.listCallsWithTranscripts({ + * conversation_ids: ["64619700005694", "64619700005695"] + * }) + */ + public listCallsWithTranscripts( + request: Intercom.unstable.ListCallsWithTranscriptsRequest, + requestOptions?: CallsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listCallsWithTranscripts(request, requestOptions)); + } + + private async __listCallsWithTranscripts( + request: Intercom.unstable.ListCallsWithTranscriptsRequest, + requestOptions?: CallsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "calls/search", + ), + method: "POST", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: request, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.ListCallsWithTranscriptsResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/calls/search"); + } + + /** + * Register a Fin Voice call with Intercom. This endpoint creates an external reference + * that links an external call identifier to an Intercom call and conversation. + * + * The call can be from different sources: + * - AWS Connect (default) + * - Five9 + * - Zoom Phone + * + * @param {Intercom.unstable.RegisterFinVoiceCallRequest} request + * @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.ConflictError} + * + * @example + * await client.unstable.calls.registerFinVoiceCall({ + * phone_number: "+1234567890", + * call_id: "call-123-abc" + * }) + */ + public registerFinVoiceCall( + request?: Intercom.unstable.RegisterFinVoiceCallRequest, + requestOptions?: CallsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__registerFinVoiceCall(request, requestOptions)); + } + + private async __registerFinVoiceCall( + request?: Intercom.unstable.RegisterFinVoiceCallRequest, + requestOptions?: CallsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "fin_voice/register", + ), + method: "POST", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: request != null ? request : undefined, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.AiCallResponse, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 409: + throw new Intercom.unstable.ConflictError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/fin_voice/register"); + } + + /** + * Retrieve information about a Fin Voice call using the external reference ID. + * + * @param {Intercom.unstable.CollectFinVoiceCallByIdRequest} request + * @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.calls.collectFinVoiceCallById({ + * id: 1 + * }) + */ + public collectFinVoiceCallById( + request: Intercom.unstable.CollectFinVoiceCallByIdRequest, + requestOptions?: CallsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__collectFinVoiceCallById(request, requestOptions)); + } + + private async __collectFinVoiceCallById( + request: Intercom.unstable.CollectFinVoiceCallByIdRequest, + requestOptions?: CallsClient.RequestOptions, + ): Promise> { + const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `fin_voice/collect/${core.url.encodePathParam(id)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.AiCallResponse, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/fin_voice/collect/{id}"); + } + + /** + * Retrieve information about a Fin Voice call using the external call identifier. + * + * @param {Intercom.unstable.CollectFinVoiceCallByExternalIdRequest} request + * @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.calls.collectFinVoiceCallByExternalId({ + * external_id: "external_id" + * }) + */ + public collectFinVoiceCallByExternalId( + request: Intercom.unstable.CollectFinVoiceCallByExternalIdRequest, + requestOptions?: CallsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__collectFinVoiceCallByExternalId(request, requestOptions)); + } + + private async __collectFinVoiceCallByExternalId( + request: Intercom.unstable.CollectFinVoiceCallByExternalIdRequest, + requestOptions?: CallsClient.RequestOptions, + ): Promise> { + const { external_id: externalId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `fin_voice/external_id/${core.url.encodePathParam(externalId)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.AiCallResponse, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/fin_voice/external_id/{external_id}", + ); + } + + /** + * Retrieve information about a Fin Voice call using the phone number. + * + * Returns the most recent matched call for the given phone number, ordered by creation date. + * + * @param {Intercom.unstable.CollectFinVoiceCallByPhoneNumberRequest} request + * @param {CallsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.calls.collectFinVoiceCallByPhoneNumber({ + * phone_number: "phone_number" + * }) + */ + public collectFinVoiceCallByPhoneNumber( + request: Intercom.unstable.CollectFinVoiceCallByPhoneNumberRequest, + requestOptions?: CallsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__collectFinVoiceCallByPhoneNumber(request, requestOptions)); + } + + private async __collectFinVoiceCallByPhoneNumber( + request: Intercom.unstable.CollectFinVoiceCallByPhoneNumberRequest, + requestOptions?: CallsClient.RequestOptions, + ): Promise> { + const { phone_number: phoneNumber } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `fin_voice/phone_number/${core.url.encodePathParam(phoneNumber)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Error_, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/fin_voice/phone_number/{phone_number}", + ); + } +} diff --git a/src/api/resources/unstable/resources/calls/client/index.ts b/src/api/resources/unstable/resources/calls/client/index.ts new file mode 100644 index 00000000..195f9aa8 --- /dev/null +++ b/src/api/resources/unstable/resources/calls/client/index.ts @@ -0,0 +1 @@ +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/calls/client/requests/CollectFinVoiceCallByExternalIdRequest.ts b/src/api/resources/unstable/resources/calls/client/requests/CollectFinVoiceCallByExternalIdRequest.ts new file mode 100644 index 00000000..1cdf7af4 --- /dev/null +++ b/src/api/resources/unstable/resources/calls/client/requests/CollectFinVoiceCallByExternalIdRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * external_id: "external_id" + * } + */ +export interface CollectFinVoiceCallByExternalIdRequest { + /** The external call identifier from the call provider */ + external_id: string; +} diff --git a/src/api/resources/unstable/resources/calls/client/requests/CollectFinVoiceCallByIdRequest.ts b/src/api/resources/unstable/resources/calls/client/requests/CollectFinVoiceCallByIdRequest.ts new file mode 100644 index 00000000..f3587f16 --- /dev/null +++ b/src/api/resources/unstable/resources/calls/client/requests/CollectFinVoiceCallByIdRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * id: 1 + * } + */ +export interface CollectFinVoiceCallByIdRequest { + /** The external reference ID */ + id: number; +} diff --git a/src/api/resources/unstable/resources/calls/client/requests/CollectFinVoiceCallByPhoneNumberRequest.ts b/src/api/resources/unstable/resources/calls/client/requests/CollectFinVoiceCallByPhoneNumberRequest.ts new file mode 100644 index 00000000..145f26e3 --- /dev/null +++ b/src/api/resources/unstable/resources/calls/client/requests/CollectFinVoiceCallByPhoneNumberRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * phone_number: "phone_number" + * } + */ +export interface CollectFinVoiceCallByPhoneNumberRequest { + /** Phone number in E.164 format */ + phone_number: string; +} diff --git a/src/api/resources/unstable/resources/calls/client/requests/ListCallsRequest.ts b/src/api/resources/unstable/resources/calls/client/requests/ListCallsRequest.ts new file mode 100644 index 00000000..74c29012 --- /dev/null +++ b/src/api/resources/unstable/resources/calls/client/requests/ListCallsRequest.ts @@ -0,0 +1,15 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * page: 1, + * per_page: 1 + * } + */ +export interface ListCallsRequest { + /** The page of results to fetch. Defaults to first page */ + page?: number; + /** How many results to display per page. Defaults to 25. Max 25. */ + per_page?: number; +} diff --git a/src/api/resources/unstable/resources/calls/client/requests/ListCallsWithTranscriptsRequest.ts b/src/api/resources/unstable/resources/calls/client/requests/ListCallsWithTranscriptsRequest.ts new file mode 100644 index 00000000..92d644c1 --- /dev/null +++ b/src/api/resources/unstable/resources/calls/client/requests/ListCallsWithTranscriptsRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * conversation_ids: ["64619700005694", "64619700005695"] + * } + */ +export interface ListCallsWithTranscriptsRequest { + /** A list of conversation ids to fetch calls for. Maximum 20. */ + conversation_ids: string[]; +} diff --git a/src/api/resources/unstable/resources/calls/client/requests/ShowCallRecordingRequest.ts b/src/api/resources/unstable/resources/calls/client/requests/ShowCallRecordingRequest.ts new file mode 100644 index 00000000..e17a6c0f --- /dev/null +++ b/src/api/resources/unstable/resources/calls/client/requests/ShowCallRecordingRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * id: "id" + * } + */ +export interface ShowCallRecordingRequest { + /** The id of the call */ + id: string; +} diff --git a/src/api/resources/unstable/resources/calls/client/requests/ShowCallRequest.ts b/src/api/resources/unstable/resources/calls/client/requests/ShowCallRequest.ts new file mode 100644 index 00000000..ee5cddee --- /dev/null +++ b/src/api/resources/unstable/resources/calls/client/requests/ShowCallRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * id: "id" + * } + */ +export interface ShowCallRequest { + /** The id of the call to retrieve */ + id: string; +} diff --git a/src/api/resources/unstable/resources/calls/client/requests/ShowCallTranscriptRequest.ts b/src/api/resources/unstable/resources/calls/client/requests/ShowCallTranscriptRequest.ts new file mode 100644 index 00000000..a21f329d --- /dev/null +++ b/src/api/resources/unstable/resources/calls/client/requests/ShowCallTranscriptRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * id: "id" + * } + */ +export interface ShowCallTranscriptRequest { + /** The id of the call */ + id: string; +} diff --git a/src/api/resources/unstable/resources/calls/client/requests/index.ts b/src/api/resources/unstable/resources/calls/client/requests/index.ts new file mode 100644 index 00000000..d1c18782 --- /dev/null +++ b/src/api/resources/unstable/resources/calls/client/requests/index.ts @@ -0,0 +1,8 @@ +export type { CollectFinVoiceCallByExternalIdRequest } from "./CollectFinVoiceCallByExternalIdRequest.js"; +export type { CollectFinVoiceCallByIdRequest } from "./CollectFinVoiceCallByIdRequest.js"; +export type { CollectFinVoiceCallByPhoneNumberRequest } from "./CollectFinVoiceCallByPhoneNumberRequest.js"; +export type { ListCallsRequest } from "./ListCallsRequest.js"; +export type { ListCallsWithTranscriptsRequest } from "./ListCallsWithTranscriptsRequest.js"; +export type { ShowCallRecordingRequest } from "./ShowCallRecordingRequest.js"; +export type { ShowCallRequest } from "./ShowCallRequest.js"; +export type { ShowCallTranscriptRequest } from "./ShowCallTranscriptRequest.js"; diff --git a/src/api/resources/unstable/resources/calls/index.ts b/src/api/resources/unstable/resources/calls/index.ts new file mode 100644 index 00000000..d9adb1af --- /dev/null +++ b/src/api/resources/unstable/resources/calls/index.ts @@ -0,0 +1,2 @@ +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/calls/types/Call.ts b/src/api/resources/unstable/resources/calls/types/Call.ts new file mode 100644 index 00000000..18bb1be3 --- /dev/null +++ b/src/api/resources/unstable/resources/calls/types/Call.ts @@ -0,0 +1,42 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../../index.js"; + +/** + * Represents a phone call in Intercom + */ +export interface Call { + /** String representing the object's type. Always has the value `call`. */ + type?: string; + /** The id of the call. */ + id?: string; + /** The id of the conversation associated with the call, if any. */ + conversation_id?: string; + /** The id of the admin associated with the call, if any. */ + admin_id?: string; + /** The id of the contact associated with the call, if any. */ + contact_id?: string; + /** The current state of the call. */ + state?: string; + initiated_at?: Intercom.unstable.Datetime; + answered_at?: Intercom.unstable.Datetime; + ended_at?: Intercom.unstable.Datetime; + created_at?: Intercom.unstable.Datetime; + updated_at?: Intercom.unstable.Datetime; + /** API URL to download or redirect to the call recording if available. */ + recording_url?: string; + /** API URL to the call transcript if available. */ + transcription_url?: string; + /** The type of call. */ + call_type?: string; + /** The direction of the call. */ + direction?: string; + /** The reason for the call end, if applicable. */ + ended_reason?: string; + /** The phone number involved in the call, in E.164 format. */ + phone?: string; + /** API URL to the AI Agent (Fin) call recording if available. */ + fin_recording_url?: string; + /** API URL to the AI Agent (Fin) call transcript if available. */ + fin_transcription_url?: string; +} diff --git a/src/api/resources/unstable/resources/calls/types/ListCallsWithTranscriptsResponse.ts b/src/api/resources/unstable/resources/calls/types/ListCallsWithTranscriptsResponse.ts new file mode 100644 index 00000000..ec066741 --- /dev/null +++ b/src/api/resources/unstable/resources/calls/types/ListCallsWithTranscriptsResponse.ts @@ -0,0 +1,21 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../../index.js"; + +export interface ListCallsWithTranscriptsResponse { + type?: string; + data?: ListCallsWithTranscriptsResponse.Data.Item[]; +} + +export namespace ListCallsWithTranscriptsResponse { + export type Data = Data.Item[]; + + export namespace Data { + export interface Item extends Intercom.unstable.Call { + /** The call transcript if available, otherwise an empty array. */ + transcript?: Record[]; + /** The status of the transcript if available. */ + transcript_status?: string; + } + } +} diff --git a/src/api/resources/unstable/resources/calls/types/index.ts b/src/api/resources/unstable/resources/calls/types/index.ts new file mode 100644 index 00000000..a7b7c7f7 --- /dev/null +++ b/src/api/resources/unstable/resources/calls/types/index.ts @@ -0,0 +1,2 @@ +export * from "./Call.js"; +export * from "./ListCallsWithTranscriptsResponse.js"; diff --git a/src/api/resources/unstable/resources/companies/client/Client.ts b/src/api/resources/unstable/resources/companies/client/Client.ts index b5593293..575c345d 100644 --- a/src/api/resources/unstable/resources/companies/client/Client.ts +++ b/src/api/resources/unstable/resources/companies/client/Client.ts @@ -1,79 +1,29 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Companies { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace CompaniesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Companies */ -export class Companies { - constructor(protected readonly _options: Companies.Options = {}) {} +export class CompaniesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: CompaniesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a single company by passing in `company_id` or `name`. @@ -89,7 +39,7 @@ export class Companies { * `https://api.intercom.io/companies?segment_id={segment_id}` * * @param {Intercom.unstable.RetrieveCompanyRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -99,71 +49,70 @@ export class Companies { * name: "my company", * company_id: "12345", * tag_id: "678910", - * segment_id: "98765" + * segment_id: "98765", + * page: 1, + * per_page: 1 * }) */ public retrieveCompany( request: Intercom.unstable.RetrieveCompanyRequest = {}, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__retrieveCompany(request, requestOptions)); } private async __retrieveCompany( request: Intercom.unstable.RetrieveCompanyRequest = {}, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { name, company_id: companyId, tag_id: tagId, segment_id: segmentId, page, per_page: perPage } = request; const _queryParams: Record = {}; if (name != null) { - _queryParams["name"] = name; + _queryParams.name = name; } if (companyId != null) { - _queryParams["company_id"] = companyId; + _queryParams.company_id = companyId; } if (tagId != null) { - _queryParams["tag_id"] = tagId; + _queryParams.tag_id = tagId; } if (segmentId != null) { - _queryParams["segment_id"] = segmentId; + _queryParams.segment_id = segmentId; } if (page != null) { - _queryParams["page"] = page.toString(); + _queryParams.page = page.toString(); } if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); + _queryParams.per_page = perPage.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "companies", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.CompanyList, rawResponse: _response.rawResponse }; @@ -187,21 +136,7 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/companies"); } /** @@ -216,7 +151,7 @@ export class Companies { * {% /admonition %} * * @param {unknown} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -228,40 +163,40 @@ export class Companies { */ public createOrUpdateCompany( request?: unknown, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createOrUpdateCompany(request, requestOptions)); } private async __createOrUpdateCompany( request?: unknown, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "companies", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Company, rawResponse: _response.rawResponse }; @@ -285,28 +220,14 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /companies."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/companies"); } /** * You can fetch a single company. * * @param {Intercom.unstable.RetrieveACompanyByIdRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -318,40 +239,38 @@ export class Companies { */ public retrieveACompanyById( request: Intercom.unstable.RetrieveACompanyByIdRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__retrieveACompanyById(request, requestOptions)); } private async __retrieveACompanyById( request: Intercom.unstable.RetrieveACompanyByIdRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(id)}`, + `companies/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Company, rawResponse: _response.rawResponse }; @@ -375,21 +294,7 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/companies/{id}"); } /** @@ -400,7 +305,7 @@ export class Companies { * {% /admonition %} * * @param {Intercom.unstable.UpdateCompanyRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -412,40 +317,38 @@ export class Companies { */ public updateCompany( request: Intercom.unstable.UpdateCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__updateCompany(request, requestOptions)); } private async __updateCompany( request: Intercom.unstable.UpdateCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(id)}`, + `companies/${core.url.encodePathParam(id)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Company, rawResponse: _response.rawResponse }; @@ -469,28 +372,14 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /companies/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/companies/{id}"); } /** * You can delete a single company. * * @param {Intercom.unstable.DeleteCompanyRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -502,40 +391,38 @@ export class Companies { */ public deleteCompany( request: Intercom.unstable.DeleteCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__deleteCompany(request, requestOptions)); } private async __deleteCompany( request: Intercom.unstable.DeleteCompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(id)}`, + `companies/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -562,28 +449,14 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /companies/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/companies/{id}"); } /** * You can fetch a list of all contacts that belong to a company. * * @param {Intercom.unstable.ListAttachedContactsRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -595,40 +468,38 @@ export class Companies { */ public listAttachedContacts( request: Intercom.unstable.ListAttachedContactsRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listAttachedContacts(request, requestOptions)); } private async __listAttachedContacts( request: Intercom.unstable.ListAttachedContactsRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(id)}/contacts`, + `companies/${core.url.encodePathParam(id)}/contacts`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -655,28 +526,14 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/{id}/contacts."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/companies/{id}/contacts"); } /** * You can fetch a list of all segments that belong to a company. * * @param {Intercom.unstable.ListAttachedSegmentsForCompaniesRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -688,40 +545,38 @@ export class Companies { */ public listAttachedSegmentsForCompanies( request: Intercom.unstable.ListAttachedSegmentsForCompaniesRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listAttachedSegmentsForCompanies(request, requestOptions)); } private async __listAttachedSegmentsForCompanies( request: Intercom.unstable.ListAttachedSegmentsForCompaniesRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `companies/${encodeURIComponent(id)}/segments`, + `companies/${core.url.encodePathParam(id)}/segments`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -748,21 +603,7 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/{id}/segments."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/companies/{id}/segments"); } /** @@ -777,65 +618,64 @@ export class Companies { * {% /admonition %} * * @param {Intercom.unstable.ListAllCompaniesRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * * @example * await client.unstable.companies.listAllCompanies({ + * page: 1, + * per_page: 1, * order: "desc" * }) */ public listAllCompanies( request: Intercom.unstable.ListAllCompaniesRequest = {}, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listAllCompanies(request, requestOptions)); } private async __listAllCompanies( request: Intercom.unstable.ListAllCompaniesRequest = {}, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { page, per_page: perPage, order } = request; const _queryParams: Record = {}; if (page != null) { - _queryParams["page"] = page.toString(); + _queryParams.page = page.toString(); } if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); + _queryParams.per_page = perPage.toString(); } if (order != null) { - _queryParams["order"] = order; + _queryParams.order = order; } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "companies/list", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.CompanyList, rawResponse: _response.rawResponse }; @@ -857,21 +697,7 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /companies/list."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/companies/list"); } /** @@ -892,55 +718,54 @@ export class Companies { * {% /admonition %} * * @param {Intercom.unstable.ScrollOverAllCompaniesRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * * @example - * await client.unstable.companies.scrollOverAllCompanies() + * await client.unstable.companies.scrollOverAllCompanies({ + * scroll_param: "scroll_param" + * }) */ public scrollOverAllCompanies( request: Intercom.unstable.ScrollOverAllCompaniesRequest = {}, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__scrollOverAllCompanies(request, requestOptions)); } private async __scrollOverAllCompanies( request: Intercom.unstable.ScrollOverAllCompaniesRequest = {}, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { scroll_param: scrollParam } = request; const _queryParams: Record = {}; if (scrollParam != null) { - _queryParams["scroll_param"] = scrollParam; + _queryParams.scroll_param = scrollParam; } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "companies/scroll", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -965,28 +790,14 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /companies/scroll."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/companies/scroll"); } /** * You can attach a company to a single contact. * * @param {Intercom.unstable.AttachContactToACompanyRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -1012,41 +823,41 @@ export class Companies { */ public attachContactToACompany( request: Intercom.unstable.AttachContactToACompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__attachContactToACompany(request, requestOptions)); } private async __attachContactToACompany( request: Intercom.unstable.AttachContactToACompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { id, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(id)}/companies`, + `contacts/${core.url.encodePathParam(id)}/companies`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Company, rawResponse: _response.rawResponse }; @@ -1072,28 +883,14 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/{id}/companies."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts/{id}/companies"); } /** * You can detach a company from a single contact. * * @param {Intercom.unstable.DetachContactFromACompanyRequest} request - * @param {Companies.RequestOptions} requestOptions - Request-specific configuration. + * @param {CompaniesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -1106,40 +903,38 @@ export class Companies { */ public detachContactFromACompany( request: Intercom.unstable.DetachContactFromACompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__detachContactFromACompany(request, requestOptions)); } private async __detachContactFromACompany( request: Intercom.unstable.DetachContactFromACompanyRequest, - requestOptions?: Companies.RequestOptions, + requestOptions?: CompaniesClient.RequestOptions, ): Promise> { const { contact_id: contactId, id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/companies/${encodeURIComponent(id)}`, + `contacts/${core.url.encodePathParam(contactId)}/companies/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Company, rawResponse: _response.rawResponse }; @@ -1163,34 +958,11 @@ export class Companies { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /contacts/{contact_id}/companies/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/contacts/{contact_id}/companies/{id}", + ); } } diff --git a/src/api/resources/unstable/resources/companies/client/index.ts b/src/api/resources/unstable/resources/companies/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/companies/client/index.ts +++ b/src/api/resources/unstable/resources/companies/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/companies/client/requests/AttachContactToACompanyRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/AttachContactToACompanyRequest.ts index d82657ba..fbab4ca6 100644 --- a/src/api/resources/unstable/resources/companies/client/requests/AttachContactToACompanyRequest.ts +++ b/src/api/resources/unstable/resources/companies/client/requests/AttachContactToACompanyRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -22,9 +20,7 @@ * } */ export interface AttachContactToACompanyRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ id: string; /** The unique identifier for the company which is given by Intercom */ company_id: string; diff --git a/src/api/resources/unstable/resources/companies/client/requests/DeleteCompanyRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/DeleteCompanyRequest.ts index abe9080b..e1ad8abe 100644 --- a/src/api/resources/unstable/resources/companies/client/requests/DeleteCompanyRequest.ts +++ b/src/api/resources/unstable/resources/companies/client/requests/DeleteCompanyRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DeleteCompanyRequest { - /** - * The unique identifier for the company which is given by Intercom - */ + /** The unique identifier for the company which is given by Intercom */ id: string; } diff --git a/src/api/resources/unstable/resources/companies/client/requests/DetachContactFromACompanyRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/DetachContactFromACompanyRequest.ts index 3cbcb14d..b80801fa 100644 --- a/src/api/resources/unstable/resources/companies/client/requests/DetachContactFromACompanyRequest.ts +++ b/src/api/resources/unstable/resources/companies/client/requests/DetachContactFromACompanyRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -10,12 +8,8 @@ * } */ export interface DetachContactFromACompanyRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; - /** - * The unique identifier for the company which is given by Intercom - */ + /** The unique identifier for the company which is given by Intercom */ id: string; } diff --git a/src/api/resources/unstable/resources/companies/client/requests/ListAllCompaniesRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/ListAllCompaniesRequest.ts index 0829eab0..86b2ef07 100644 --- a/src/api/resources/unstable/resources/companies/client/requests/ListAllCompaniesRequest.ts +++ b/src/api/resources/unstable/resources/companies/client/requests/ListAllCompaniesRequest.ts @@ -1,24 +1,18 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { + * page: 1, + * per_page: 1, * order: "desc" * } */ export interface ListAllCompaniesRequest { - /** - * The page of results to fetch. Defaults to first page - */ + /** The page of results to fetch. Defaults to first page */ page?: number; - /** - * How many results to return per page. Defaults to 15 - */ + /** How many results to return per page. Defaults to 15 */ per_page?: number; - /** - * `asc` or `desc`. Return the companies in ascending or descending order. Defaults to desc - */ + /** `asc` or `desc`. Return the companies in ascending or descending order. Defaults to desc */ order?: string; } diff --git a/src/api/resources/unstable/resources/companies/client/requests/ListAttachedContactsRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/ListAttachedContactsRequest.ts index 0dc176ea..e49c7dca 100644 --- a/src/api/resources/unstable/resources/companies/client/requests/ListAttachedContactsRequest.ts +++ b/src/api/resources/unstable/resources/companies/client/requests/ListAttachedContactsRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ListAttachedContactsRequest { - /** - * The unique identifier for the company which is given by Intercom - */ + /** The unique identifier for the company which is given by Intercom */ id: string; } diff --git a/src/api/resources/unstable/resources/companies/client/requests/ListAttachedSegmentsForCompaniesRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/ListAttachedSegmentsForCompaniesRequest.ts index 3e2c05a4..31d3c9d9 100644 --- a/src/api/resources/unstable/resources/companies/client/requests/ListAttachedSegmentsForCompaniesRequest.ts +++ b/src/api/resources/unstable/resources/companies/client/requests/ListAttachedSegmentsForCompaniesRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ListAttachedSegmentsForCompaniesRequest { - /** - * The unique identifier for the company which is given by Intercom - */ + /** The unique identifier for the company which is given by Intercom */ id: string; } diff --git a/src/api/resources/unstable/resources/companies/client/requests/RetrieveACompanyByIdRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/RetrieveACompanyByIdRequest.ts index 8b4afb24..f53eaada 100644 --- a/src/api/resources/unstable/resources/companies/client/requests/RetrieveACompanyByIdRequest.ts +++ b/src/api/resources/unstable/resources/companies/client/requests/RetrieveACompanyByIdRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface RetrieveACompanyByIdRequest { - /** - * The unique identifier for the company which is given by Intercom - */ + /** The unique identifier for the company which is given by Intercom */ id: string; } diff --git a/src/api/resources/unstable/resources/companies/client/requests/RetrieveCompanyRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/RetrieveCompanyRequest.ts index 557a2e00..a3314297 100644 --- a/src/api/resources/unstable/resources/companies/client/requests/RetrieveCompanyRequest.ts +++ b/src/api/resources/unstable/resources/companies/client/requests/RetrieveCompanyRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -8,32 +6,22 @@ * name: "my company", * company_id: "12345", * tag_id: "678910", - * segment_id: "98765" + * segment_id: "98765", + * page: 1, + * per_page: 1 * } */ export interface RetrieveCompanyRequest { - /** - * The `name` of the company to filter by. - */ + /** The `name` of the company to filter by. */ name?: string; - /** - * The `company_id` of the company to filter by. - */ + /** The `company_id` of the company to filter by. */ company_id?: string; - /** - * The `tag_id` of the company to filter by. - */ + /** The `tag_id` of the company to filter by. */ tag_id?: string; - /** - * The `segment_id` of the company to filter by. - */ + /** The `segment_id` of the company to filter by. */ segment_id?: string; - /** - * The page of results to fetch. Defaults to first page - */ + /** The page of results to fetch. Defaults to first page */ page?: number; - /** - * How many results to display per page. Defaults to 15 - */ + /** How many results to display per page. Defaults to 15 */ per_page?: number; } diff --git a/src/api/resources/unstable/resources/companies/client/requests/ScrollOverAllCompaniesRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/ScrollOverAllCompaniesRequest.ts index 9d7a6877..68f2ed8b 100644 --- a/src/api/resources/unstable/resources/companies/client/requests/ScrollOverAllCompaniesRequest.ts +++ b/src/api/resources/unstable/resources/companies/client/requests/ScrollOverAllCompaniesRequest.ts @@ -1,14 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example - * {} + * { + * scroll_param: "scroll_param" + * } */ export interface ScrollOverAllCompaniesRequest { - /** - * - */ + /** */ scroll_param?: string; } diff --git a/src/api/resources/unstable/resources/companies/client/requests/UpdateCompanyRequest.ts b/src/api/resources/unstable/resources/companies/client/requests/UpdateCompanyRequest.ts index 1b2d26a4..b63f71c5 100644 --- a/src/api/resources/unstable/resources/companies/client/requests/UpdateCompanyRequest.ts +++ b/src/api/resources/unstable/resources/companies/client/requests/UpdateCompanyRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface UpdateCompanyRequest { - /** - * The unique identifier for the company which is given by Intercom - */ + /** The unique identifier for the company which is given by Intercom */ id: string; } diff --git a/src/api/resources/unstable/resources/companies/client/requests/index.ts b/src/api/resources/unstable/resources/companies/client/requests/index.ts index 2db00d94..7bdff9f7 100644 --- a/src/api/resources/unstable/resources/companies/client/requests/index.ts +++ b/src/api/resources/unstable/resources/companies/client/requests/index.ts @@ -1,10 +1,10 @@ -export { type RetrieveCompanyRequest } from "./RetrieveCompanyRequest"; -export { type RetrieveACompanyByIdRequest } from "./RetrieveACompanyByIdRequest"; -export { type UpdateCompanyRequest } from "./UpdateCompanyRequest"; -export { type DeleteCompanyRequest } from "./DeleteCompanyRequest"; -export { type ListAttachedContactsRequest } from "./ListAttachedContactsRequest"; -export { type ListAttachedSegmentsForCompaniesRequest } from "./ListAttachedSegmentsForCompaniesRequest"; -export { type ListAllCompaniesRequest } from "./ListAllCompaniesRequest"; -export { type ScrollOverAllCompaniesRequest } from "./ScrollOverAllCompaniesRequest"; -export { type AttachContactToACompanyRequest } from "./AttachContactToACompanyRequest"; -export { type DetachContactFromACompanyRequest } from "./DetachContactFromACompanyRequest"; +export type { AttachContactToACompanyRequest } from "./AttachContactToACompanyRequest.js"; +export type { DeleteCompanyRequest } from "./DeleteCompanyRequest.js"; +export type { DetachContactFromACompanyRequest } from "./DetachContactFromACompanyRequest.js"; +export type { ListAllCompaniesRequest } from "./ListAllCompaniesRequest.js"; +export type { ListAttachedContactsRequest } from "./ListAttachedContactsRequest.js"; +export type { ListAttachedSegmentsForCompaniesRequest } from "./ListAttachedSegmentsForCompaniesRequest.js"; +export type { RetrieveACompanyByIdRequest } from "./RetrieveACompanyByIdRequest.js"; +export type { RetrieveCompanyRequest } from "./RetrieveCompanyRequest.js"; +export type { ScrollOverAllCompaniesRequest } from "./ScrollOverAllCompaniesRequest.js"; +export type { UpdateCompanyRequest } from "./UpdateCompanyRequest.js"; diff --git a/src/api/resources/unstable/resources/companies/index.ts b/src/api/resources/unstable/resources/companies/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/companies/index.ts +++ b/src/api/resources/unstable/resources/companies/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/companies/types/Company.ts b/src/api/resources/unstable/resources/companies/types/Company.ts index ebce2925..d2569495 100644 --- a/src/api/resources/unstable/resources/companies/types/Company.ts +++ b/src/api/resources/unstable/resources/companies/types/Company.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * Companies allow you to represent organizations using your product. Each company will have its own description and be associated with contacts. You can fetch, create, update and list companies. @@ -45,6 +43,8 @@ export interface Company { tags?: Company.Tags; /** The list of segments associated with the company */ segments?: Company.Segments; + /** The list of notes associated with the company */ + notes?: Company.Notes; } export namespace Company { @@ -74,4 +74,13 @@ export namespace Company { type?: "segment.list"; segments?: Intercom.unstable.Segment[]; } + + /** + * The list of notes associated with the company + */ + export interface Notes { + /** The type of the object */ + type?: "note.list"; + notes?: Intercom.unstable.CompanyNote[]; + } } diff --git a/src/api/resources/unstable/resources/companies/types/index.ts b/src/api/resources/unstable/resources/companies/types/index.ts index d15bbd39..19a19f61 100644 --- a/src/api/resources/unstable/resources/companies/types/index.ts +++ b/src/api/resources/unstable/resources/companies/types/index.ts @@ -1 +1 @@ -export * from "./Company"; +export * from "./Company.js"; diff --git a/src/api/resources/unstable/resources/contacts/client/Client.ts b/src/api/resources/unstable/resources/contacts/client/Client.ts index 432c912e..531e8b52 100644 --- a/src/api/resources/unstable/resources/contacts/client/Client.ts +++ b/src/api/resources/unstable/resources/contacts/client/Client.ts @@ -1,85 +1,35 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; - -export declare namespace Contacts { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } +export declare namespace ContactsClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your contacts */ -export class Contacts { - constructor(protected readonly _options: Contacts.Options = {}) {} +export class ContactsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: ContactsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of companies that are associated to a contact. * * @param {Intercom.unstable.ListCompaniesForAContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -91,40 +41,38 @@ export class Contacts { */ public listCompaniesForAContact( request: Intercom.unstable.ListCompaniesForAContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listCompaniesForAContact(request, requestOptions)); } private async __listCompaniesForAContact( request: Intercom.unstable.ListCompaniesForAContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(id)}/companies`, + `contacts/${core.url.encodePathParam(id)}/companies`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -151,28 +99,14 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts/{id}/companies."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/contacts/{id}/companies"); } /** * You can fetch a list of segments that are associated to a contact. * * @param {Intercom.unstable.ListSegmentsForAContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -184,40 +118,38 @@ export class Contacts { */ public listSegmentsForAContact( request: Intercom.unstable.ListSegmentsForAContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listSegmentsForAContact(request, requestOptions)); } private async __listSegmentsForAContact( request: Intercom.unstable.ListSegmentsForAContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { contact_id: contactId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/segments`, + `contacts/${core.url.encodePathParam(contactId)}/segments`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ContactSegments, rawResponse: _response.rawResponse }; @@ -241,23 +173,12 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /contacts/{contact_id}/segments.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/contacts/{contact_id}/segments", + ); } /** @@ -270,7 +191,7 @@ export class Contacts { * 2.Opt-in subscription types that the user has opted-in to receiving. * * @param {Intercom.unstable.ListSubscriptionsForAContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -282,40 +203,38 @@ export class Contacts { */ public listSubscriptionsForAContact( request: Intercom.unstable.ListSubscriptionsForAContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listSubscriptionsForAContact(request, requestOptions)); } private async __listSubscriptionsForAContact( request: Intercom.unstable.ListSubscriptionsForAContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { contact_id: contactId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/subscriptions`, + `contacts/${core.url.encodePathParam(contactId)}/subscriptions`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -342,30 +261,19 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /contacts/{contact_id}/subscriptions.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/contacts/{contact_id}/subscriptions", + ); } /** * You can fetch a list of all tags that are attached to a specific contact. * * @param {Intercom.unstable.ListTagsForAContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -377,40 +285,38 @@ export class Contacts { */ public listTagsForAContact( request: Intercom.unstable.ListTagsForAContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listTagsForAContact(request, requestOptions)); } private async __listTagsForAContact( request: Intercom.unstable.ListTagsForAContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { contact_id: contactId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/tags`, + `contacts/${core.url.encodePathParam(contactId)}/tags`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.TagList, rawResponse: _response.rawResponse }; @@ -434,28 +340,14 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts/{contact_id}/tags."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/contacts/{contact_id}/tags"); } /** * You can fetch the details of a single contact. * * @param {Intercom.unstable.ShowContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -466,40 +358,38 @@ export class Contacts { */ public showContact( request: Intercom.unstable.ShowContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__showContact(request, requestOptions)); } private async __showContact( request: Intercom.unstable.ShowContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(id)}`, + `contacts/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -524,21 +414,7 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/contacts/{id}"); } /** @@ -551,7 +427,7 @@ export class Contacts { * {% /admonition %} * * @param {Intercom.unstable.UpdateContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -574,41 +450,41 @@ export class Contacts { */ public updateContact( request: Intercom.unstable.UpdateContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__updateContact(request, requestOptions)); } private async __updateContact( request: Intercom.unstable.UpdateContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { id, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(id)}`, + `contacts/${core.url.encodePathParam(id)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -633,28 +509,14 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /contacts/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/contacts/{id}"); } /** * You can delete a single contact. * * @param {Intercom.unstable.DeleteContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -665,40 +527,38 @@ export class Contacts { */ public deleteContact( request: Intercom.unstable.DeleteContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__deleteContact(request, requestOptions)); } private async __deleteContact( request: Intercom.unstable.DeleteContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(id)}`, + `contacts/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ContactDeleted, rawResponse: _response.rawResponse }; @@ -720,28 +580,14 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /contacts/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/contacts/{id}"); } /** * You can merge a contact with a `role` of `lead` into a contact with a `role` of `user`. * * @param {Intercom.unstable.MergeContactsRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -753,40 +599,40 @@ export class Contacts { */ public mergeContact( request: Intercom.unstable.MergeContactsRequest = {}, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__mergeContact(request, requestOptions)); } private async __mergeContact( request: Intercom.unstable.MergeContactsRequest = {}, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "contacts/merge", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -811,21 +657,7 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/merge."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts/merge"); } /** @@ -931,7 +763,7 @@ export class Contacts { * | $ | String | Ends With | * * @param {Intercom.unstable.SearchRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -952,40 +784,40 @@ export class Contacts { */ public searchContacts( request: Intercom.unstable.SearchRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__searchContacts(request, requestOptions)); } private async __searchContacts( request: Intercom.unstable.SearchRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "contacts/search", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ContactList, rawResponse: _response.rawResponse }; @@ -1007,21 +839,7 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/search."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts/search"); } /** @@ -1031,7 +849,7 @@ export class Contacts { * See the [pagination section](https://developers.intercom.com/docs/build-an-integration/learn-more/rest-apis/pagination/#pagination-for-list-apis) for more details on how to use the `starting_after` param. * {% /admonition %} * - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -1039,38 +857,36 @@ export class Contacts { * await client.unstable.contacts.listContacts() */ public listContacts( - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listContacts(requestOptions)); } private async __listContacts( - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "contacts", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ContactList, rawResponse: _response.rawResponse }; @@ -1092,28 +908,14 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/contacts"); } /** * You can create a new contact (ie. user or lead). * * @param {Intercom.CreateContactRequestTwo} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -1124,40 +926,40 @@ export class Contacts { */ public createContact( request?: Intercom.CreateContactRequestTwo, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createContact(request, requestOptions)); } private async __createContact( request?: Intercom.CreateContactRequestTwo, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "contacts", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -1182,28 +984,14 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts"); } /** * You can fetch the details of a single contact by external ID. Note that this endpoint only supports users and not leads. * * @param {Intercom.unstable.ShowContactByExternalIdRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -1214,40 +1002,38 @@ export class Contacts { */ public showContactByExternalId( request: Intercom.unstable.ShowContactByExternalIdRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__showContactByExternalId(request, requestOptions)); } private async __showContactByExternalId( request: Intercom.unstable.ShowContactByExternalIdRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { external_id: externalId } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/find_by_external_id/${encodeURIComponent(externalId)}`, + `contacts/find_by_external_id/${core.url.encodePathParam(externalId)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -1272,30 +1058,19 @@ export class Contacts { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /contacts/find_by_external_id/{external_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/contacts/find_by_external_id/{external_id}", + ); } /** * You can archive a single contact. * * @param {Intercom.unstable.ArchiveContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.unstable.contacts.archiveContact({ @@ -1304,40 +1079,38 @@ export class Contacts { */ public archiveContact( request: Intercom.unstable.ArchiveContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__archiveContact(request, requestOptions)); } private async __archiveContact( request: Intercom.unstable.ArchiveContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(id)}/archive`, + `contacts/${core.url.encodePathParam(id)}/archive`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ContactArchived, rawResponse: _response.rawResponse }; @@ -1351,28 +1124,14 @@ export class Contacts { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/{id}/archive."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts/{id}/archive"); } /** * You can unarchive a single contact. * * @param {Intercom.unstable.UnarchiveContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.unstable.contacts.unarchiveContact({ @@ -1381,40 +1140,38 @@ export class Contacts { */ public unarchiveContact( request: Intercom.unstable.UnarchiveContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__unarchiveContact(request, requestOptions)); } private async __unarchiveContact( request: Intercom.unstable.UnarchiveContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(id)}/unarchive`, + `contacts/${core.url.encodePathParam(id)}/unarchive`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ContactUnarchived, rawResponse: _response.rawResponse }; @@ -1428,28 +1185,14 @@ export class Contacts { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/{id}/unarchive."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts/{id}/unarchive"); } /** * Block a single contact.
**Note:** conversations of the contact will also be archived during the process.
More details in [FAQ How do I block Inbox spam?](https://www.intercom.com/help/en/articles/8838656-inbox-faqs) * * @param {Intercom.unstable.BlockContactRequest} request - * @param {Contacts.RequestOptions} requestOptions - Request-specific configuration. + * @param {ContactsClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.unstable.contacts.blockContact({ @@ -1458,40 +1201,38 @@ export class Contacts { */ public blockContact( request: Intercom.unstable.BlockContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__blockContact(request, requestOptions)); } private async __blockContact( request: Intercom.unstable.BlockContactRequest, - requestOptions?: Contacts.RequestOptions, + requestOptions?: ContactsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(id)}/block`, + `contacts/${core.url.encodePathParam(id)}/block`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ContactBlocked, rawResponse: _response.rawResponse }; @@ -1505,32 +1246,6 @@ export class Contacts { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/{id}/block."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts/{id}/block"); } } diff --git a/src/api/resources/unstable/resources/contacts/client/index.ts b/src/api/resources/unstable/resources/contacts/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/contacts/client/index.ts +++ b/src/api/resources/unstable/resources/contacts/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/contacts/client/requests/ArchiveContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/ArchiveContactRequest.ts index f44c40c3..15dad8b9 100644 --- a/src/api/resources/unstable/resources/contacts/client/requests/ArchiveContactRequest.ts +++ b/src/api/resources/unstable/resources/contacts/client/requests/ArchiveContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ArchiveContactRequest { - /** - * id - */ + /** id */ id: string; } diff --git a/src/api/resources/unstable/resources/contacts/client/requests/BlockContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/BlockContactRequest.ts index 497e928a..75e78626 100644 --- a/src/api/resources/unstable/resources/contacts/client/requests/BlockContactRequest.ts +++ b/src/api/resources/unstable/resources/contacts/client/requests/BlockContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface BlockContactRequest { - /** - * id - */ + /** id */ id: string; } diff --git a/src/api/resources/unstable/resources/contacts/client/requests/DeleteContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/DeleteContactRequest.ts index e70f0504..55b557be 100644 --- a/src/api/resources/unstable/resources/contacts/client/requests/DeleteContactRequest.ts +++ b/src/api/resources/unstable/resources/contacts/client/requests/DeleteContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DeleteContactRequest { - /** - * id - */ + /** id */ id: string; } diff --git a/src/api/resources/unstable/resources/contacts/client/requests/ListCompaniesForAContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/ListCompaniesForAContactRequest.ts index af4ebe19..1e96546f 100644 --- a/src/api/resources/unstable/resources/contacts/client/requests/ListCompaniesForAContactRequest.ts +++ b/src/api/resources/unstable/resources/contacts/client/requests/ListCompaniesForAContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ListCompaniesForAContactRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ id: string; } diff --git a/src/api/resources/unstable/resources/contacts/client/requests/ListSegmentsForAContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/ListSegmentsForAContactRequest.ts index 22e71773..2d363b13 100644 --- a/src/api/resources/unstable/resources/contacts/client/requests/ListSegmentsForAContactRequest.ts +++ b/src/api/resources/unstable/resources/contacts/client/requests/ListSegmentsForAContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ListSegmentsForAContactRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; } diff --git a/src/api/resources/unstable/resources/contacts/client/requests/ListSubscriptionsForAContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/ListSubscriptionsForAContactRequest.ts index 3e48e0c9..6413b23e 100644 --- a/src/api/resources/unstable/resources/contacts/client/requests/ListSubscriptionsForAContactRequest.ts +++ b/src/api/resources/unstable/resources/contacts/client/requests/ListSubscriptionsForAContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ListSubscriptionsForAContactRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; } diff --git a/src/api/resources/unstable/resources/contacts/client/requests/ListTagsForAContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/ListTagsForAContactRequest.ts index f91dffdc..719e4d06 100644 --- a/src/api/resources/unstable/resources/contacts/client/requests/ListTagsForAContactRequest.ts +++ b/src/api/resources/unstable/resources/contacts/client/requests/ListTagsForAContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ListTagsForAContactRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; } diff --git a/src/api/resources/unstable/resources/contacts/client/requests/MergeContactsRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/MergeContactsRequest.ts index a9009e6a..520d7f83 100644 --- a/src/api/resources/unstable/resources/contacts/client/requests/MergeContactsRequest.ts +++ b/src/api/resources/unstable/resources/contacts/client/requests/MergeContactsRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example diff --git a/src/api/resources/unstable/resources/contacts/client/requests/ShowContactByExternalIdRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/ShowContactByExternalIdRequest.ts index af3dff76..d6f2b0d8 100644 --- a/src/api/resources/unstable/resources/contacts/client/requests/ShowContactByExternalIdRequest.ts +++ b/src/api/resources/unstable/resources/contacts/client/requests/ShowContactByExternalIdRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ShowContactByExternalIdRequest { - /** - * The external ID of the user that you want to retrieve - */ + /** The external ID of the user that you want to retrieve */ external_id: string; } diff --git a/src/api/resources/unstable/resources/contacts/client/requests/ShowContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/ShowContactRequest.ts index 6abbc7ab..170a185f 100644 --- a/src/api/resources/unstable/resources/contacts/client/requests/ShowContactRequest.ts +++ b/src/api/resources/unstable/resources/contacts/client/requests/ShowContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ShowContactRequest { - /** - * id - */ + /** id */ id: string; } diff --git a/src/api/resources/unstable/resources/contacts/client/requests/UnarchiveContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/UnarchiveContactRequest.ts index e6a5af5e..28b61c31 100644 --- a/src/api/resources/unstable/resources/contacts/client/requests/UnarchiveContactRequest.ts +++ b/src/api/resources/unstable/resources/contacts/client/requests/UnarchiveContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface UnarchiveContactRequest { - /** - * id - */ + /** id */ id: string; } diff --git a/src/api/resources/unstable/resources/contacts/client/requests/UpdateContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/UpdateContactRequest.ts index b130cd58..e33aba66 100644 --- a/src/api/resources/unstable/resources/contacts/client/requests/UpdateContactRequest.ts +++ b/src/api/resources/unstable/resources/contacts/client/requests/UpdateContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -21,9 +19,7 @@ * } */ export interface UpdateContactRequest { - /** - * id - */ + /** id */ id: string; /** The role of the contact. */ role?: string; diff --git a/src/api/resources/unstable/resources/contacts/client/requests/index.ts b/src/api/resources/unstable/resources/contacts/client/requests/index.ts index 2c00f2f2..faea767c 100644 --- a/src/api/resources/unstable/resources/contacts/client/requests/index.ts +++ b/src/api/resources/unstable/resources/contacts/client/requests/index.ts @@ -1,12 +1,12 @@ -export { type ListCompaniesForAContactRequest } from "./ListCompaniesForAContactRequest"; -export { type ListSegmentsForAContactRequest } from "./ListSegmentsForAContactRequest"; -export { type ListSubscriptionsForAContactRequest } from "./ListSubscriptionsForAContactRequest"; -export { type ListTagsForAContactRequest } from "./ListTagsForAContactRequest"; -export { type ShowContactRequest } from "./ShowContactRequest"; -export { type UpdateContactRequest } from "./UpdateContactRequest"; -export { type DeleteContactRequest } from "./DeleteContactRequest"; -export { type MergeContactsRequest } from "./MergeContactsRequest"; -export { type ShowContactByExternalIdRequest } from "./ShowContactByExternalIdRequest"; -export { type ArchiveContactRequest } from "./ArchiveContactRequest"; -export { type UnarchiveContactRequest } from "./UnarchiveContactRequest"; -export { type BlockContactRequest } from "./BlockContactRequest"; +export type { ArchiveContactRequest } from "./ArchiveContactRequest.js"; +export type { BlockContactRequest } from "./BlockContactRequest.js"; +export type { DeleteContactRequest } from "./DeleteContactRequest.js"; +export type { ListCompaniesForAContactRequest } from "./ListCompaniesForAContactRequest.js"; +export type { ListSegmentsForAContactRequest } from "./ListSegmentsForAContactRequest.js"; +export type { ListSubscriptionsForAContactRequest } from "./ListSubscriptionsForAContactRequest.js"; +export type { ListTagsForAContactRequest } from "./ListTagsForAContactRequest.js"; +export type { MergeContactsRequest } from "./MergeContactsRequest.js"; +export type { ShowContactByExternalIdRequest } from "./ShowContactByExternalIdRequest.js"; +export type { ShowContactRequest } from "./ShowContactRequest.js"; +export type { UnarchiveContactRequest } from "./UnarchiveContactRequest.js"; +export type { UpdateContactRequest } from "./UpdateContactRequest.js"; diff --git a/src/api/resources/unstable/resources/contacts/index.ts b/src/api/resources/unstable/resources/contacts/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/contacts/index.ts +++ b/src/api/resources/unstable/resources/contacts/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/contacts/types/Contact.ts b/src/api/resources/unstable/resources/contacts/types/Contact.ts index 156e327d..0cf076af 100644 --- a/src/api/resources/unstable/resources/contacts/types/Contact.ts +++ b/src/api/resources/unstable/resources/contacts/types/Contact.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * Contacts represent your leads and users in Intercom. diff --git a/src/api/resources/unstable/resources/contacts/types/CreateContactResponse.ts b/src/api/resources/unstable/resources/contacts/types/CreateContactResponse.ts index 1455fa8f..e7bb8739 100644 --- a/src/api/resources/unstable/resources/contacts/types/CreateContactResponse.ts +++ b/src/api/resources/unstable/resources/contacts/types/CreateContactResponse.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; export interface CreateContactResponse extends Intercom.unstable.Contact { /** If the user has enabled push messaging. */ diff --git a/src/api/resources/unstable/resources/contacts/types/MergeContactResponse.ts b/src/api/resources/unstable/resources/contacts/types/MergeContactResponse.ts index b67e7baa..6a253944 100644 --- a/src/api/resources/unstable/resources/contacts/types/MergeContactResponse.ts +++ b/src/api/resources/unstable/resources/contacts/types/MergeContactResponse.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; export interface MergeContactResponse extends Intercom.unstable.Contact { /** If the user has enabled push messaging. */ diff --git a/src/api/resources/unstable/resources/contacts/types/ShowContactByExternalIdResponse.ts b/src/api/resources/unstable/resources/contacts/types/ShowContactByExternalIdResponse.ts index d11d1d83..2e8b3f12 100644 --- a/src/api/resources/unstable/resources/contacts/types/ShowContactByExternalIdResponse.ts +++ b/src/api/resources/unstable/resources/contacts/types/ShowContactByExternalIdResponse.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; export interface ShowContactByExternalIdResponse extends Intercom.unstable.Contact { /** If the user has enabled push messaging. */ diff --git a/src/api/resources/unstable/resources/contacts/types/ShowContactResponse.ts b/src/api/resources/unstable/resources/contacts/types/ShowContactResponse.ts index 58bc07cc..e8ffabcc 100644 --- a/src/api/resources/unstable/resources/contacts/types/ShowContactResponse.ts +++ b/src/api/resources/unstable/resources/contacts/types/ShowContactResponse.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; export interface ShowContactResponse extends Intercom.unstable.Contact { /** If the user has enabled push messaging. */ diff --git a/src/api/resources/unstable/resources/contacts/types/UpdateContactResponse.ts b/src/api/resources/unstable/resources/contacts/types/UpdateContactResponse.ts index 8919485b..c67687b2 100644 --- a/src/api/resources/unstable/resources/contacts/types/UpdateContactResponse.ts +++ b/src/api/resources/unstable/resources/contacts/types/UpdateContactResponse.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; export interface UpdateContactResponse extends Intercom.unstable.Contact { /** If the user has enabled push messaging. */ diff --git a/src/api/resources/unstable/resources/contacts/types/index.ts b/src/api/resources/unstable/resources/contacts/types/index.ts index 12ec2438..bf8c1f71 100644 --- a/src/api/resources/unstable/resources/contacts/types/index.ts +++ b/src/api/resources/unstable/resources/contacts/types/index.ts @@ -1,6 +1,6 @@ -export * from "./ShowContactResponse"; -export * from "./UpdateContactResponse"; -export * from "./MergeContactResponse"; -export * from "./CreateContactResponse"; -export * from "./ShowContactByExternalIdResponse"; -export * from "./Contact"; +export * from "./Contact.js"; +export * from "./CreateContactResponse.js"; +export * from "./MergeContactResponse.js"; +export * from "./ShowContactByExternalIdResponse.js"; +export * from "./ShowContactResponse.js"; +export * from "./UpdateContactResponse.js"; diff --git a/src/api/resources/unstable/resources/conversations/client/Client.ts b/src/api/resources/unstable/resources/conversations/client/Client.ts index 87442ffe..70ca206d 100644 --- a/src/api/resources/unstable/resources/conversations/client/Client.ts +++ b/src/api/resources/unstable/resources/conversations/client/Client.ts @@ -1,79 +1,29 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Conversations { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace ConversationsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Conversations */ -export class Conversations { - constructor(protected readonly _options: Conversations.Options = {}) {} +export class ConversationsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: ConversationsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of all conversations. @@ -85,60 +35,60 @@ export class Conversations { * {% /admonition %} * * @param {Intercom.unstable.ListConversationsRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.ForbiddenError} * * @example - * await client.unstable.conversations.listConversations() + * await client.unstable.conversations.listConversations({ + * per_page: 1, + * starting_after: "starting_after" + * }) */ public listConversations( request: Intercom.unstable.ListConversationsRequest = {}, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listConversations(request, requestOptions)); } private async __listConversations( request: Intercom.unstable.ListConversationsRequest = {}, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { const { per_page: perPage, starting_after: startingAfter } = request; const _queryParams: Record = {}; if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); + _queryParams.per_page = perPage.toString(); } if (startingAfter != null) { - _queryParams["starting_after"] = startingAfter; + _queryParams.starting_after = startingAfter; } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "conversations", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ConversationList, rawResponse: _response.rawResponse }; @@ -165,21 +115,7 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /conversations."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/conversations"); } /** @@ -193,8 +129,9 @@ export class Conversations { * * This will return the Message model that has been created. * + * * @param {Intercom.unstable.CreateConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.ForbiddenError} @@ -220,40 +157,40 @@ export class Conversations { */ public createConversation( request: Intercom.unstable.CreateConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createConversation(request, requestOptions)); } private async __createConversation( request: Intercom.unstable.CreateConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "conversations", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Message, rawResponse: _response.rawResponse }; @@ -282,21 +219,7 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/conversations"); } /** @@ -312,7 +235,7 @@ export class Conversations { * For AI agent conversation metadata, please note that you need to have the agent enabled in your workspace, which is a [paid feature](https://www.intercom.com/help/en/articles/8205718-fin-resolutions#h_97f8c2e671). * * @param {Intercom.unstable.RetrieveConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.ForbiddenError} @@ -321,51 +244,53 @@ export class Conversations { * @example * await client.unstable.conversations.retrieveConversation({ * id: 1, - * display_as: "plaintext" + * display_as: "plaintext", + * include_translations: true * }) */ public retrieveConversation( request: Intercom.unstable.RetrieveConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__retrieveConversation(request, requestOptions)); } private async __retrieveConversation( request: Intercom.unstable.RetrieveConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { - const { id, display_as: displayAs } = request; + const { id, display_as: displayAs, include_translations: includeTranslations } = request; const _queryParams: Record = {}; if (displayAs != null) { - _queryParams["display_as"] = displayAs; + _queryParams.display_as = displayAs; + } + + if (includeTranslations != null) { + _queryParams.include_translations = includeTranslations.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(id)}`, + `conversations/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Conversation, rawResponse: _response.rawResponse }; @@ -394,21 +319,7 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /conversations/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/conversations/{id}"); } /** @@ -425,8 +336,9 @@ export class Conversations { * See _`update a conversation with an association to a custom object instance`_ in the request/response examples to see the custom object association format. * {% /admonition %} * + * * @param {Intercom.unstable.UpdateConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.ForbiddenError} @@ -455,47 +367,46 @@ export class Conversations { */ public updateConversation( request: Intercom.unstable.UpdateConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__updateConversation(request, requestOptions)); } private async __updateConversation( request: Intercom.unstable.UpdateConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { const { id, display_as: displayAs, ..._body } = request; const _queryParams: Record = {}; if (displayAs != null) { - _queryParams["display_as"] = displayAs; + _queryParams.display_as = displayAs; } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(id)}`, + `conversations/${core.url.encodePathParam(id)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", - queryParameters: _queryParams, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Conversation, rawResponse: _response.rawResponse }; @@ -524,28 +435,14 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /conversations/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/conversations/{id}"); } /** * You can delete a single conversation. * * @param {Intercom.unstable.DeleteConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.ForbiddenError} @@ -557,40 +454,38 @@ export class Conversations { */ public deleteConversation( request: Intercom.unstable.DeleteConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__deleteConversation(request, requestOptions)); } private async __deleteConversation( request: Intercom.unstable.DeleteConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(id)}`, + `conversations/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -620,21 +515,7 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /conversations/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/conversations/{id}"); } /** @@ -739,7 +620,7 @@ export class Conversations { * | $ | String | Ends With | * * @param {Intercom.unstable.SearchRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.unstable.conversations.searchConversations({ @@ -758,40 +639,40 @@ export class Conversations { */ public searchConversations( request: Intercom.unstable.SearchRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__searchConversations(request, requestOptions)); } private async __searchConversations( request: Intercom.unstable.SearchRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "conversations/search", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.ConversationList, rawResponse: _response.rawResponse }; @@ -805,28 +686,14 @@ export class Conversations { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations/search."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/conversations/search"); } /** * You can reply to a conversation with a message from an admin or on behalf of a contact, or with a note for admins. * * @param {Intercom.unstable.ReplyConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.ForbiddenError} @@ -899,41 +766,41 @@ export class Conversations { */ public replyConversation( request: Intercom.unstable.ReplyConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__replyConversation(request, requestOptions)); } private async __replyConversation( request: Intercom.unstable.ReplyConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { const { id, body: _body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(id)}/reply`, + `conversations/${core.url.encodePathParam(id)}/reply`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Conversation, rawResponse: _response.rawResponse }; @@ -962,21 +829,7 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations/{id}/reply."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/conversations/{id}/reply"); } /** @@ -987,7 +840,7 @@ export class Conversations { * - Assign a conversation to an admin and/or team. * * @param {Intercom.unstable.ManageConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.ForbiddenError} @@ -1035,41 +888,41 @@ export class Conversations { */ public manageConversation( request: Intercom.unstable.ManageConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__manageConversation(request, requestOptions)); } private async __manageConversation( request: Intercom.unstable.ManageConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { const { id, body: _body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(id)}/parts`, + `conversations/${core.url.encodePathParam(id)}/parts`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Conversation, rawResponse: _response.rawResponse }; @@ -1098,21 +951,7 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations/{id}/parts."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/conversations/{id}/parts"); } /** @@ -1122,8 +961,9 @@ export class Conversations { * If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. * {% /admonition %} * + * * @param {Intercom.unstable.AttachContactToConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.ForbiddenError} @@ -1149,41 +989,41 @@ export class Conversations { */ public attachContactToConversation( request: Intercom.unstable.AttachContactToConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__attachContactToConversation(request, requestOptions)); } private async __attachContactToConversation( request: Intercom.unstable.AttachContactToConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { const { id, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(id)}/customers`, + `conversations/${core.url.encodePathParam(id)}/customers`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Conversation, rawResponse: _response.rawResponse }; @@ -1212,23 +1052,12 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{id}/customers.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/conversations/{id}/customers", + ); } /** @@ -1238,8 +1067,9 @@ export class Conversations { * If you add a contact via the email parameter and there is no user/lead found on that workspace with he given email, then we will create a new contact with `role` set to `lead`. * {% /admonition %} * + * * @param {Intercom.unstable.DetachContactFromConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.ForbiddenError} @@ -1255,41 +1085,41 @@ export class Conversations { */ public detachContactFromConversation( request: Intercom.unstable.DetachContactFromConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__detachContactFromConversation(request, requestOptions)); } private async __detachContactFromConversation( request: Intercom.unstable.DetachContactFromConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { const { conversation_id: conversationId, contact_id: contactId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/customers/${encodeURIComponent(contactId)}`, + `conversations/${core.url.encodePathParam(conversationId)}/customers/${core.url.encodePathParam(contactId)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Conversation, rawResponse: _response.rawResponse }; @@ -1323,23 +1153,12 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /conversations/{conversation_id}/customers/{contact_id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/conversations/{conversation_id}/customers/{contact_id}", + ); } /** @@ -1349,8 +1168,9 @@ export class Conversations { * If you are redacting a conversation part, it must have a `body`. If you are redacting a source message, it must have been created by a contact. We will return a `conversation_part_not_redactable` error if these criteria are not met. * {% /admonition %} * + * * @param {Intercom.unstable.RedactConversationRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -1371,40 +1191,40 @@ export class Conversations { */ public redactConversation( request: Intercom.unstable.RedactConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__redactConversation(request, requestOptions)); } private async __redactConversation( request: Intercom.unstable.RedactConversationRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "conversations/redact", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Conversation, rawResponse: _response.rawResponse }; @@ -1428,28 +1248,14 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /conversations/redact."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/conversations/redact"); } /** * You can convert a conversation to a ticket. * * @param {Intercom.unstable.ConvertConversationToTicketRequest} request - * @param {Conversations.RequestOptions} requestOptions - Request-specific configuration. + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @@ -1467,41 +1273,41 @@ export class Conversations { */ public convertConversationToTicket( request: Intercom.unstable.ConvertConversationToTicketRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__convertConversationToTicket(request, requestOptions)); } private async __convertConversationToTicket( request: Intercom.unstable.ConvertConversationToTicketRequest, - requestOptions?: Conversations.RequestOptions, + requestOptions?: ConversationsClient.RequestOptions, ): Promise> { const { id, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(id)}/convert`, + `conversations/${core.url.encodePathParam(id)}/convert`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Ticket | undefined, rawResponse: _response.rawResponse }; @@ -1520,34 +1326,6 @@ export class Conversations { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{id}/convert.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/conversations/{id}/convert"); } } diff --git a/src/api/resources/unstable/resources/conversations/client/index.ts b/src/api/resources/unstable/resources/conversations/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/conversations/client/index.ts +++ b/src/api/resources/unstable/resources/conversations/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/conversations/client/requests/AttachContactToConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/AttachContactToConversationRequest.ts index d887df62..e7d06d91 100644 --- a/src/api/resources/unstable/resources/conversations/client/requests/AttachContactToConversationRequest.ts +++ b/src/api/resources/unstable/resources/conversations/client/requests/AttachContactToConversationRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example @@ -24,9 +22,7 @@ import * as Intercom from "../../../../../../index"; * } */ export interface AttachContactToConversationRequest { - /** - * The identifier for the conversation as given by Intercom. - */ + /** The identifier for the conversation as given by Intercom. */ id: string; /** The `id` of the admin who is adding the new participant. */ admin_id?: string; diff --git a/src/api/resources/unstable/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts index 2e317651..5985d835 100644 --- a/src/api/resources/unstable/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts +++ b/src/api/resources/unstable/resources/conversations/client/requests/ConvertConversationToTicketRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example @@ -18,9 +16,7 @@ import * as Intercom from "../../../../../../index"; * } */ export interface ConvertConversationToTicketRequest { - /** - * The id of the conversation to target - */ + /** The id of the conversation to target */ id: number; /** The ID of the type of ticket you want to convert the conversation to */ ticket_type_id: string; diff --git a/src/api/resources/unstable/resources/conversations/client/requests/CreateConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/CreateConversationRequest.ts index 93ec0636..0f8bcd9a 100644 --- a/src/api/resources/unstable/resources/conversations/client/requests/CreateConversationRequest.ts +++ b/src/api/resources/unstable/resources/conversations/client/requests/CreateConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -38,14 +36,12 @@ export namespace CreateConversationRequest { } export namespace From { - /** - * The role associated to the contact - user or lead. - */ - export type Type = "lead" | "user" | "contact"; + /** The role associated to the contact - user or lead. */ export const Type = { Lead: "lead", User: "user", Contact: "contact", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } } diff --git a/src/api/resources/unstable/resources/conversations/client/requests/DeleteConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/DeleteConversationRequest.ts index 9ef40c85..1a07b952 100644 --- a/src/api/resources/unstable/resources/conversations/client/requests/DeleteConversationRequest.ts +++ b/src/api/resources/unstable/resources/conversations/client/requests/DeleteConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DeleteConversationRequest { - /** - * id - */ + /** id */ id: number; } diff --git a/src/api/resources/unstable/resources/conversations/client/requests/DetachContactFromConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/DetachContactFromConversationRequest.ts index e245b23d..415bfae9 100644 --- a/src/api/resources/unstable/resources/conversations/client/requests/DetachContactFromConversationRequest.ts +++ b/src/api/resources/unstable/resources/conversations/client/requests/DetachContactFromConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -32,13 +30,9 @@ * } */ export interface DetachContactFromConversationRequest { - /** - * The identifier for the conversation as given by Intercom. - */ + /** The identifier for the conversation as given by Intercom. */ conversation_id: string; - /** - * The identifier for the contact as given by Intercom. - */ + /** The identifier for the contact as given by Intercom. */ contact_id: string; /** The `id` of the admin who is performing the action. */ admin_id: string; diff --git a/src/api/resources/unstable/resources/conversations/client/requests/ListConversationsRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/ListConversationsRequest.ts index f3c7f741..4908f563 100644 --- a/src/api/resources/unstable/resources/conversations/client/requests/ListConversationsRequest.ts +++ b/src/api/resources/unstable/resources/conversations/client/requests/ListConversationsRequest.ts @@ -1,18 +1,15 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example - * {} + * { + * per_page: 1, + * starting_after: "starting_after" + * } */ export interface ListConversationsRequest { - /** - * How many results per page - */ + /** How many results per page */ per_page?: number; - /** - * String used to get the next page of conversations. - */ + /** String used to get the next page of conversations. */ starting_after?: string; } diff --git a/src/api/resources/unstable/resources/conversations/client/requests/ManageConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/ManageConversationRequest.ts index 59c70d65..54ff3cf5 100644 --- a/src/api/resources/unstable/resources/conversations/client/requests/ManageConversationRequest.ts +++ b/src/api/resources/unstable/resources/conversations/client/requests/ManageConversationRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example @@ -56,9 +54,7 @@ import * as Intercom from "../../../../../../index"; * } */ export interface ManageConversationRequest { - /** - * The identifier for the conversation as given by Intercom. - */ + /** The identifier for the conversation as given by Intercom. */ id: string; body: Intercom.unstable.ManageConversationRequestBody; } diff --git a/src/api/resources/unstable/resources/conversations/client/requests/ReplyConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/ReplyConversationRequest.ts index fb35a919..3653ec6d 100644 --- a/src/api/resources/unstable/resources/conversations/client/requests/ReplyConversationRequest.ts +++ b/src/api/resources/unstable/resources/conversations/client/requests/ReplyConversationRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example @@ -71,9 +69,7 @@ import * as Intercom from "../../../../../../index"; * } */ export interface ReplyConversationRequest { - /** - * The Intercom provisioned identifier for the conversation or the string "last" to reply to the last part of the conversation - */ + /** The Intercom provisioned identifier for the conversation or the string "last" to reply to the last part of the conversation */ id: string; body: Intercom.unstable.ReplyConversationRequestBody; } diff --git a/src/api/resources/unstable/resources/conversations/client/requests/RetrieveConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/RetrieveConversationRequest.ts index 8849068d..1d207c59 100644 --- a/src/api/resources/unstable/resources/conversations/client/requests/RetrieveConversationRequest.ts +++ b/src/api/resources/unstable/resources/conversations/client/requests/RetrieveConversationRequest.ts @@ -1,21 +1,18 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { * id: 1, - * display_as: "plaintext" + * display_as: "plaintext", + * include_translations: true * } */ export interface RetrieveConversationRequest { - /** - * The id of the conversation to target - */ + /** The id of the conversation to target */ id: number; - /** - * Set to plaintext to retrieve conversation messages in plain text. - */ + /** Set to plaintext to retrieve conversation messages in plain text. This affects both the body and subject fields. */ display_as?: string; + /** If set to true, conversation parts will be translated to the detected language of the conversation. */ + include_translations?: boolean; } diff --git a/src/api/resources/unstable/resources/conversations/client/requests/UpdateConversationRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/UpdateConversationRequest.ts index 76276853..9e2a3dea 100644 --- a/src/api/resources/unstable/resources/conversations/client/requests/UpdateConversationRequest.ts +++ b/src/api/resources/unstable/resources/conversations/client/requests/UpdateConversationRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example @@ -39,17 +37,15 @@ import * as Intercom from "../../../../../../index"; * } */ export interface UpdateConversationRequest { - /** - * The id of the conversation to target - */ + /** The id of the conversation to target */ id: number; - /** - * Set to plaintext to retrieve conversation messages in plain text. - */ + /** Set to plaintext to retrieve conversation messages in plain text. This affects both the body and subject fields. */ display_as?: string; /** Mark a conversation as read within Intercom. */ read?: boolean; /** The title given to the conversation */ title?: string; custom_attributes?: Intercom.unstable.CustomAttributes; + /** The ID of the company that the conversation is associated with. The unique identifier for the company which is given by Intercom. Set to nil to remove company. */ + company_id?: string; } diff --git a/src/api/resources/unstable/resources/conversations/client/requests/index.ts b/src/api/resources/unstable/resources/conversations/client/requests/index.ts index b297425a..0d6b5317 100644 --- a/src/api/resources/unstable/resources/conversations/client/requests/index.ts +++ b/src/api/resources/unstable/resources/conversations/client/requests/index.ts @@ -1,10 +1,10 @@ -export { type ListConversationsRequest } from "./ListConversationsRequest"; -export { type CreateConversationRequest } from "./CreateConversationRequest"; -export { type RetrieveConversationRequest } from "./RetrieveConversationRequest"; -export { type UpdateConversationRequest } from "./UpdateConversationRequest"; -export { type DeleteConversationRequest } from "./DeleteConversationRequest"; -export { type ReplyConversationRequest } from "./ReplyConversationRequest"; -export { type ManageConversationRequest } from "./ManageConversationRequest"; -export { type AttachContactToConversationRequest } from "./AttachContactToConversationRequest"; -export { type DetachContactFromConversationRequest } from "./DetachContactFromConversationRequest"; -export { type ConvertConversationToTicketRequest } from "./ConvertConversationToTicketRequest"; +export type { AttachContactToConversationRequest } from "./AttachContactToConversationRequest.js"; +export type { ConvertConversationToTicketRequest } from "./ConvertConversationToTicketRequest.js"; +export type { CreateConversationRequest } from "./CreateConversationRequest.js"; +export type { DeleteConversationRequest } from "./DeleteConversationRequest.js"; +export type { DetachContactFromConversationRequest } from "./DetachContactFromConversationRequest.js"; +export type { ListConversationsRequest } from "./ListConversationsRequest.js"; +export type { ManageConversationRequest } from "./ManageConversationRequest.js"; +export type { ReplyConversationRequest } from "./ReplyConversationRequest.js"; +export type { RetrieveConversationRequest } from "./RetrieveConversationRequest.js"; +export type { UpdateConversationRequest } from "./UpdateConversationRequest.js"; diff --git a/src/api/resources/unstable/resources/conversations/index.ts b/src/api/resources/unstable/resources/conversations/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/conversations/index.ts +++ b/src/api/resources/unstable/resources/conversations/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/conversations/types/Conversation.ts b/src/api/resources/unstable/resources/conversations/types/Conversation.ts index 2531c62d..8a79bcda 100644 --- a/src/api/resources/unstable/resources/conversations/types/Conversation.ts +++ b/src/api/resources/unstable/resources/conversations/types/Conversation.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * Conversations are how you can communicate with users in Intercom. They are created when a contact replies to an outbound message, or when one admin directly sends a message to a single contact. @@ -34,6 +32,8 @@ export interface Conversation { admin_assignee_id?: number; /** The id of the team assigned to the conversation. If it's not assigned to a team it will return null. */ team_assignee_id?: string; + /** The ID of the company that the conversation is associated with. The unique identifier for the company which is given by Intercom. */ + company_id?: string; tags?: Intercom.unstable.Tags; conversation_rating?: Intercom.unstable.ConversationRating; source?: Intercom.unstable.ConversationSource; @@ -51,21 +51,17 @@ export interface Conversation { } export namespace Conversation { - /** - * Can be set to "open", "closed" or "snoozed". - */ - export type State = "open" | "closed" | "snoozed"; + /** Can be set to "open", "closed" or "snoozed". */ export const State = { Open: "open", Closed: "closed", Snoozed: "snoozed", } as const; - /** - * If marked as priority, it will return priority or else not_priority. - */ - export type Priority = "priority" | "not_priority"; + export type State = (typeof State)[keyof typeof State]; + /** If marked as priority, it will return priority or else not_priority. */ export const Priority = { Priority: "priority", NotPriority: "not_priority", } as const; + export type Priority = (typeof Priority)[keyof typeof Priority]; } diff --git a/src/api/resources/unstable/resources/conversations/types/ManageConversationRequestBody.ts b/src/api/resources/unstable/resources/conversations/types/ManageConversationRequestBody.ts index cceeedbb..ec011db3 100644 --- a/src/api/resources/unstable/resources/conversations/types/ManageConversationRequestBody.ts +++ b/src/api/resources/unstable/resources/conversations/types/ManageConversationRequestBody.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; export type ManageConversationRequestBody = | Intercom.unstable.ManageConversationRequestBody.Close diff --git a/src/api/resources/unstable/resources/conversations/types/index.ts b/src/api/resources/unstable/resources/conversations/types/index.ts index b2325882..7f9a27b5 100644 --- a/src/api/resources/unstable/resources/conversations/types/index.ts +++ b/src/api/resources/unstable/resources/conversations/types/index.ts @@ -1,2 +1,2 @@ -export * from "./ManageConversationRequestBody"; -export * from "./Conversation"; +export * from "./Conversation.js"; +export * from "./ManageConversationRequestBody.js"; diff --git a/src/api/resources/unstable/resources/customChannelEvents/client/Client.ts b/src/api/resources/unstable/resources/customChannelEvents/client/Client.ts index fab44a35..fdb99c2e 100644 --- a/src/api/resources/unstable/resources/customChannelEvents/client/Client.ts +++ b/src/api/resources/unstable/resources/customChannelEvents/client/Client.ts @@ -1,83 +1,33 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace CustomChannelEvents { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace CustomChannelEventsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } -export class CustomChannelEvents { - constructor(protected readonly _options: CustomChannelEvents.Options = {}) {} +export class CustomChannelEventsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: CustomChannelEventsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * Notifies Intercom that a new conversation was created in your custom channel/platform. This triggers conversation creation and workflow automations within Intercom for your custom channel integration. - * > **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". + * > **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support. * * @param {Intercom.unstable.CustomChannelBaseEvent} request - * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * @param {CustomChannelEventsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -98,40 +48,40 @@ export class CustomChannelEvents { */ public notifyNewConversation( request: Intercom.unstable.CustomChannelBaseEvent, - requestOptions?: CustomChannelEvents.RequestOptions, + requestOptions?: CustomChannelEventsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__notifyNewConversation(request, requestOptions)); } private async __notifyNewConversation( request: Intercom.unstable.CustomChannelBaseEvent, - requestOptions?: CustomChannelEvents.RequestOptions, + requestOptions?: CustomChannelEventsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "custom_channel_events/notify_new_conversation", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -165,31 +115,20 @@ export class CustomChannelEvents { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /custom_channel_events/notify_new_conversation.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/custom_channel_events/notify_new_conversation", + ); } /** * Notifies Intercom that a new message was sent in a conversation on your custom channel/platform. This allows Intercom to process the message and trigger any relevant workflow automations. - * > **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". + * > **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support. * * @param {Intercom.unstable.NotifyNewMessageRequest} request - * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * @param {CustomChannelEventsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -211,40 +150,40 @@ export class CustomChannelEvents { */ public notifyNewMessage( request: Intercom.unstable.NotifyNewMessageRequest, - requestOptions?: CustomChannelEvents.RequestOptions, + requestOptions?: CustomChannelEventsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__notifyNewMessage(request, requestOptions)); } private async __notifyNewMessage( request: Intercom.unstable.NotifyNewMessageRequest, - requestOptions?: CustomChannelEvents.RequestOptions, + requestOptions?: CustomChannelEventsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "custom_channel_events/notify_new_message", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -278,31 +217,20 @@ export class CustomChannelEvents { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /custom_channel_events/notify_new_message.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/custom_channel_events/notify_new_message", + ); } /** * Notifies Intercom that a user selected a quick reply option in your custom channel/platform. This allows Intercom to process the response and trigger any relevant workflow automations. - * > **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". + * > **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support. * * @param {Intercom.unstable.NotifyQuickReplySelectedRequest} request - * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * @param {CustomChannelEventsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -324,40 +252,40 @@ export class CustomChannelEvents { */ public notifyQuickReplySelected( request: Intercom.unstable.NotifyQuickReplySelectedRequest, - requestOptions?: CustomChannelEvents.RequestOptions, + requestOptions?: CustomChannelEventsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__notifyQuickReplySelected(request, requestOptions)); } private async __notifyQuickReplySelected( request: Intercom.unstable.NotifyQuickReplySelectedRequest, - requestOptions?: CustomChannelEvents.RequestOptions, + requestOptions?: CustomChannelEventsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "custom_channel_events/notify_quick_reply_selected", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -391,31 +319,20 @@ export class CustomChannelEvents { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /custom_channel_events/notify_quick_reply_selected.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/custom_channel_events/notify_quick_reply_selected", + ); } /** * Notifies Intercom that a user provided a response to an attribute collector in your custom channel/platform. This allows Intercom to process the attribute and trigger any relevant workflow automations. - * > **Note:** This endpoint is restricted to customers with access to the closed beta for "Fin over API". + * > **Note:** This endpoint is currently under managed availability. Please reach out to your accounts team to discuss access and tailored, hands-on support. * * @param {Intercom.unstable.NotifyAttributeCollectedRequest} request - * @param {CustomChannelEvents.RequestOptions} requestOptions - Request-specific configuration. + * @param {CustomChannelEventsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -440,40 +357,40 @@ export class CustomChannelEvents { */ public notifyAttributeCollected( request: Intercom.unstable.NotifyAttributeCollectedRequest, - requestOptions?: CustomChannelEvents.RequestOptions, + requestOptions?: CustomChannelEventsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__notifyAttributeCollected(request, requestOptions)); } private async __notifyAttributeCollected( request: Intercom.unstable.NotifyAttributeCollectedRequest, - requestOptions?: CustomChannelEvents.RequestOptions, + requestOptions?: CustomChannelEventsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "custom_channel_events/notify_attribute_collected", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -507,34 +424,11 @@ export class CustomChannelEvents { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /custom_channel_events/notify_attribute_collected.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/custom_channel_events/notify_attribute_collected", + ); } } diff --git a/src/api/resources/unstable/resources/customChannelEvents/client/index.ts b/src/api/resources/unstable/resources/customChannelEvents/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/customChannelEvents/client/index.ts +++ b/src/api/resources/unstable/resources/customChannelEvents/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyAttributeCollectedRequest.ts b/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyAttributeCollectedRequest.ts index f3a2660d..f0ad7f82 100644 --- a/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyAttributeCollectedRequest.ts +++ b/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyAttributeCollectedRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example diff --git a/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyNewMessageRequest.ts b/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyNewMessageRequest.ts index 1ed15c6e..8a4f252a 100644 --- a/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyNewMessageRequest.ts +++ b/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyNewMessageRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example diff --git a/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyQuickReplySelectedRequest.ts b/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyQuickReplySelectedRequest.ts index 499b11d6..049df316 100644 --- a/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyQuickReplySelectedRequest.ts +++ b/src/api/resources/unstable/resources/customChannelEvents/client/requests/NotifyQuickReplySelectedRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example diff --git a/src/api/resources/unstable/resources/customChannelEvents/client/requests/index.ts b/src/api/resources/unstable/resources/customChannelEvents/client/requests/index.ts index 007800f3..702922d9 100644 --- a/src/api/resources/unstable/resources/customChannelEvents/client/requests/index.ts +++ b/src/api/resources/unstable/resources/customChannelEvents/client/requests/index.ts @@ -1,3 +1,3 @@ -export { type NotifyNewMessageRequest } from "./NotifyNewMessageRequest"; -export { type NotifyQuickReplySelectedRequest } from "./NotifyQuickReplySelectedRequest"; -export { type NotifyAttributeCollectedRequest } from "./NotifyAttributeCollectedRequest"; +export type { NotifyAttributeCollectedRequest } from "./NotifyAttributeCollectedRequest.js"; +export type { NotifyNewMessageRequest } from "./NotifyNewMessageRequest.js"; +export type { NotifyQuickReplySelectedRequest } from "./NotifyQuickReplySelectedRequest.js"; diff --git a/src/api/resources/unstable/resources/customChannelEvents/index.ts b/src/api/resources/unstable/resources/customChannelEvents/index.ts index 5ec76921..914b8c3c 100644 --- a/src/api/resources/unstable/resources/customChannelEvents/index.ts +++ b/src/api/resources/unstable/resources/customChannelEvents/index.ts @@ -1 +1 @@ -export * from "./client"; +export * from "./client/index.js"; diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/Client.ts b/src/api/resources/unstable/resources/customObjectInstances/client/Client.ts index 8d8d1ca5..a8ff8f05 100644 --- a/src/api/resources/unstable/resources/customObjectInstances/client/Client.ts +++ b/src/api/resources/unstable/resources/customObjectInstances/client/Client.ts @@ -1,72 +1,18 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace CustomObjectInstances { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace CustomObjectInstancesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** @@ -75,14 +21,18 @@ export declare namespace CustomObjectInstances { * From now on, to access this endpoint, you need additional permissions. Please head over to the [Developer Hub](https://app.intercom.com/a/apps/_/developer-hub) app package authentication settings to configure the required permissions. * {% /admonition %} */ -export class CustomObjectInstances { - constructor(protected readonly _options: CustomObjectInstances.Options = {}) {} +export class CustomObjectInstancesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: CustomObjectInstancesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * Fetch a Custom Object Instance by external_id. * * @param {Intercom.unstable.GetCustomObjectInstancesByExternalIdRequest} request - * @param {CustomObjectInstances.RequestOptions} requestOptions - Request-specific configuration. + * @param {CustomObjectInstancesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -95,7 +45,7 @@ export class CustomObjectInstances { */ public getCustomObjectInstancesByExternalId( request: Intercom.unstable.GetCustomObjectInstancesByExternalIdRequest, - requestOptions?: CustomObjectInstances.RequestOptions, + requestOptions?: CustomObjectInstancesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise( this.__getCustomObjectInstancesByExternalId(request, requestOptions), @@ -104,36 +54,33 @@ export class CustomObjectInstances { private async __getCustomObjectInstancesByExternalId( request: Intercom.unstable.GetCustomObjectInstancesByExternalIdRequest, - requestOptions?: CustomObjectInstances.RequestOptions, + requestOptions?: CustomObjectInstancesClient.RequestOptions, ): Promise> { const { custom_object_type_identifier: customObjectTypeIdentifier, external_id: externalId } = request; const _queryParams: Record = {}; - _queryParams["external_id"] = externalId; + _queryParams.external_id = externalId; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `custom_object_instances/${encodeURIComponent(customObjectTypeIdentifier)}`, + `custom_object_instances/${core.url.encodePathParam(customObjectTypeIdentifier)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -160,30 +107,19 @@ export class CustomObjectInstances { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /custom_object_instances/{custom_object_type_identifier}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/custom_object_instances/{custom_object_type_identifier}", + ); } /** * Create or update a custom object instance * * @param {Intercom.unstable.CreateOrUpdateCustomObjectInstanceRequest} request - * @param {CustomObjectInstances.RequestOptions} requestOptions - Request-specific configuration. + * @param {CustomObjectInstancesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -202,41 +138,41 @@ export class CustomObjectInstances { */ public createCustomObjectInstances( request: Intercom.unstable.CreateOrUpdateCustomObjectInstanceRequest, - requestOptions?: CustomObjectInstances.RequestOptions, + requestOptions?: CustomObjectInstancesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createCustomObjectInstances(request, requestOptions)); } private async __createCustomObjectInstances( request: Intercom.unstable.CreateOrUpdateCustomObjectInstanceRequest, - requestOptions?: CustomObjectInstances.RequestOptions, + requestOptions?: CustomObjectInstancesClient.RequestOptions, ): Promise> { const { custom_object_type_identifier: customObjectTypeIdentifier, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `custom_object_instances/${encodeURIComponent(customObjectTypeIdentifier)}`, + `custom_object_instances/${core.url.encodePathParam(customObjectTypeIdentifier)}`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -263,30 +199,19 @@ export class CustomObjectInstances { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /custom_object_instances/{custom_object_type_identifier}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/custom_object_instances/{custom_object_type_identifier}", + ); } /** * Delete a single Custom Object instance by external_id. * * @param {Intercom.unstable.DeleteCustomObjectInstancesByIdRequest} request - * @param {CustomObjectInstances.RequestOptions} requestOptions - Request-specific configuration. + * @param {CustomObjectInstancesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -299,43 +224,40 @@ export class CustomObjectInstances { */ public deleteCustomObjectInstancesById( request: Intercom.unstable.DeleteCustomObjectInstancesByIdRequest, - requestOptions?: CustomObjectInstances.RequestOptions, + requestOptions?: CustomObjectInstancesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__deleteCustomObjectInstancesById(request, requestOptions)); } private async __deleteCustomObjectInstancesById( request: Intercom.unstable.DeleteCustomObjectInstancesByIdRequest, - requestOptions?: CustomObjectInstances.RequestOptions, + requestOptions?: CustomObjectInstancesClient.RequestOptions, ): Promise> { const { custom_object_type_identifier: customObjectTypeIdentifier, external_id: externalId } = request; const _queryParams: Record = {}; - _queryParams["external_id"] = externalId; + _queryParams.external_id = externalId; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `custom_object_instances/${encodeURIComponent(customObjectTypeIdentifier)}`, + `custom_object_instances/${core.url.encodePathParam(customObjectTypeIdentifier)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -362,30 +284,19 @@ export class CustomObjectInstances { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /custom_object_instances/{custom_object_type_identifier}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/custom_object_instances/{custom_object_type_identifier}", + ); } /** * Fetch a Custom Object Instance by id. * * @param {Intercom.unstable.GetCustomObjectInstancesByIdRequest} request - * @param {CustomObjectInstances.RequestOptions} requestOptions - Request-specific configuration. + * @param {CustomObjectInstancesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -398,40 +309,38 @@ export class CustomObjectInstances { */ public getCustomObjectInstancesById( request: Intercom.unstable.GetCustomObjectInstancesByIdRequest, - requestOptions?: CustomObjectInstances.RequestOptions, + requestOptions?: CustomObjectInstancesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__getCustomObjectInstancesById(request, requestOptions)); } private async __getCustomObjectInstancesById( request: Intercom.unstable.GetCustomObjectInstancesByIdRequest, - requestOptions?: CustomObjectInstances.RequestOptions, + requestOptions?: CustomObjectInstancesClient.RequestOptions, ): Promise> { const { custom_object_type_identifier: customObjectTypeIdentifier, id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `custom_object_instances/${encodeURIComponent(customObjectTypeIdentifier)}/${encodeURIComponent(id)}`, + `custom_object_instances/${core.url.encodePathParam(customObjectTypeIdentifier)}/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -458,30 +367,19 @@ export class CustomObjectInstances { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /custom_object_instances/{custom_object_type_identifier}/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/custom_object_instances/{custom_object_type_identifier}/{id}", + ); } /** * Delete a single Custom Object instance using the Intercom defined id. * * @param {Intercom.unstable.DeleteCustomObjectInstancesByExternalIdRequest} request - * @param {CustomObjectInstances.RequestOptions} requestOptions - Request-specific configuration. + * @param {CustomObjectInstancesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -494,7 +392,7 @@ export class CustomObjectInstances { */ public deleteCustomObjectInstancesByExternalId( request: Intercom.unstable.DeleteCustomObjectInstancesByExternalIdRequest, - requestOptions?: CustomObjectInstances.RequestOptions, + requestOptions?: CustomObjectInstancesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise( this.__deleteCustomObjectInstancesByExternalId(request, requestOptions), @@ -503,33 +401,31 @@ export class CustomObjectInstances { private async __deleteCustomObjectInstancesByExternalId( request: Intercom.unstable.DeleteCustomObjectInstancesByExternalIdRequest, - requestOptions?: CustomObjectInstances.RequestOptions, + requestOptions?: CustomObjectInstancesClient.RequestOptions, ): Promise> { const { custom_object_type_identifier: customObjectTypeIdentifier, id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `custom_object_instances/${encodeURIComponent(customObjectTypeIdentifier)}/${encodeURIComponent(id)}`, + `custom_object_instances/${core.url.encodePathParam(customObjectTypeIdentifier)}/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -556,34 +452,11 @@ export class CustomObjectInstances { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /custom_object_instances/{custom_object_type_identifier}/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/custom_object_instances/{custom_object_type_identifier}/{id}", + ); } } diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/index.ts b/src/api/resources/unstable/resources/customObjectInstances/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/customObjectInstances/client/index.ts +++ b/src/api/resources/unstable/resources/customObjectInstances/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/requests/CreateOrUpdateCustomObjectInstanceRequest.ts b/src/api/resources/unstable/resources/customObjectInstances/client/requests/CreateOrUpdateCustomObjectInstanceRequest.ts index 6366c551..97fa7ad7 100644 --- a/src/api/resources/unstable/resources/customObjectInstances/client/requests/CreateOrUpdateCustomObjectInstanceRequest.ts +++ b/src/api/resources/unstable/resources/customObjectInstances/client/requests/CreateOrUpdateCustomObjectInstanceRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -16,9 +14,7 @@ * } */ export interface CreateOrUpdateCustomObjectInstanceRequest { - /** - * The unique identifier of the custom object type that defines the structure of the custom object instance. - */ + /** The unique identifier of the custom object type that defines the structure of the custom object instance. */ custom_object_type_identifier: string; /** A unique identifier for the Custom Object instance in the external system it originated from. */ external_id?: string; diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByExternalIdRequest.ts b/src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByExternalIdRequest.ts index 4674b582..4a66d40e 100644 --- a/src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByExternalIdRequest.ts +++ b/src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByExternalIdRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -10,12 +8,8 @@ * } */ export interface DeleteCustomObjectInstancesByExternalIdRequest { - /** - * The unique identifier of the custom object type that defines the structure of the custom object instance. - */ + /** The unique identifier of the custom object type that defines the structure of the custom object instance. */ custom_object_type_identifier: string; - /** - * The Intercom defined id of the custom object instance - */ + /** The Intercom defined id of the custom object instance */ id: string; } diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByIdRequest.ts b/src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByIdRequest.ts index b14cf673..d97bc1ce 100644 --- a/src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByIdRequest.ts +++ b/src/api/resources/unstable/resources/customObjectInstances/client/requests/DeleteCustomObjectInstancesByIdRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -10,9 +8,7 @@ * } */ export interface DeleteCustomObjectInstancesByIdRequest { - /** - * The unique identifier of the custom object type that defines the structure of the custom object instance. - */ + /** The unique identifier of the custom object type that defines the structure of the custom object instance. */ custom_object_type_identifier: string; external_id: string; } diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByExternalIdRequest.ts b/src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByExternalIdRequest.ts index 5ca2f7d0..2d9d0fe3 100644 --- a/src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByExternalIdRequest.ts +++ b/src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByExternalIdRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -10,9 +8,7 @@ * } */ export interface GetCustomObjectInstancesByExternalIdRequest { - /** - * The unique identifier of the custom object type that defines the structure of the custom object instance. - */ + /** The unique identifier of the custom object type that defines the structure of the custom object instance. */ custom_object_type_identifier: string; external_id: string; } diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByIdRequest.ts b/src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByIdRequest.ts index 9350898c..69c8d4cf 100644 --- a/src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByIdRequest.ts +++ b/src/api/resources/unstable/resources/customObjectInstances/client/requests/GetCustomObjectInstancesByIdRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -10,12 +8,8 @@ * } */ export interface GetCustomObjectInstancesByIdRequest { - /** - * The unique identifier of the custom object type that defines the structure of the custom object instance. - */ + /** The unique identifier of the custom object type that defines the structure of the custom object instance. */ custom_object_type_identifier: string; - /** - * The id or external_id of the custom object instance - */ + /** The id or external_id of the custom object instance */ id: string; } diff --git a/src/api/resources/unstable/resources/customObjectInstances/client/requests/index.ts b/src/api/resources/unstable/resources/customObjectInstances/client/requests/index.ts index 5382e3d2..07816781 100644 --- a/src/api/resources/unstable/resources/customObjectInstances/client/requests/index.ts +++ b/src/api/resources/unstable/resources/customObjectInstances/client/requests/index.ts @@ -1,5 +1,5 @@ -export { type GetCustomObjectInstancesByExternalIdRequest } from "./GetCustomObjectInstancesByExternalIdRequest"; -export { type CreateOrUpdateCustomObjectInstanceRequest } from "./CreateOrUpdateCustomObjectInstanceRequest"; -export { type DeleteCustomObjectInstancesByIdRequest } from "./DeleteCustomObjectInstancesByIdRequest"; -export { type GetCustomObjectInstancesByIdRequest } from "./GetCustomObjectInstancesByIdRequest"; -export { type DeleteCustomObjectInstancesByExternalIdRequest } from "./DeleteCustomObjectInstancesByExternalIdRequest"; +export type { CreateOrUpdateCustomObjectInstanceRequest } from "./CreateOrUpdateCustomObjectInstanceRequest.js"; +export type { DeleteCustomObjectInstancesByExternalIdRequest } from "./DeleteCustomObjectInstancesByExternalIdRequest.js"; +export type { DeleteCustomObjectInstancesByIdRequest } from "./DeleteCustomObjectInstancesByIdRequest.js"; +export type { GetCustomObjectInstancesByExternalIdRequest } from "./GetCustomObjectInstancesByExternalIdRequest.js"; +export type { GetCustomObjectInstancesByIdRequest } from "./GetCustomObjectInstancesByIdRequest.js"; diff --git a/src/api/resources/unstable/resources/customObjectInstances/index.ts b/src/api/resources/unstable/resources/customObjectInstances/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/customObjectInstances/index.ts +++ b/src/api/resources/unstable/resources/customObjectInstances/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/customObjectInstances/types/CustomObjectInstance.ts b/src/api/resources/unstable/resources/customObjectInstances/types/CustomObjectInstance.ts index aab4a843..a4363acf 100644 --- a/src/api/resources/unstable/resources/customObjectInstances/types/CustomObjectInstance.ts +++ b/src/api/resources/unstable/resources/customObjectInstances/types/CustomObjectInstance.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A Custom Object Instance represents an instance of a custom object type. This allows you to create and set custom attributes to store data about your customers that is not already captured by Intercom. The parent object includes recommended default attributes and you can add your own custom attributes. diff --git a/src/api/resources/unstable/resources/customObjectInstances/types/index.ts b/src/api/resources/unstable/resources/customObjectInstances/types/index.ts index d5c782f8..861f9ce5 100644 --- a/src/api/resources/unstable/resources/customObjectInstances/types/index.ts +++ b/src/api/resources/unstable/resources/customObjectInstances/types/index.ts @@ -1 +1 @@ -export * from "./CustomObjectInstance"; +export * from "./CustomObjectInstance.js"; diff --git a/src/api/resources/unstable/resources/dataAttributes/client/Client.ts b/src/api/resources/unstable/resources/dataAttributes/client/Client.ts index 03670ff6..1778c2d1 100644 --- a/src/api/resources/unstable/resources/dataAttributes/client/Client.ts +++ b/src/api/resources/unstable/resources/dataAttributes/client/Client.ts @@ -1,137 +1,87 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace DataAttributes { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace DataAttributesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Data Attributes */ -export class DataAttributes { - constructor(protected readonly _options: DataAttributes.Options = {}) {} +export class DataAttributesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: DataAttributesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of all data attributes belonging to a workspace for contacts, companies or conversations. * * @param {Intercom.unstable.LisDataAttributesRequest} request - * @param {DataAttributes.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataAttributesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * * @example - * await client.unstable.dataAttributes.lisDataAttributes() + * await client.unstable.dataAttributes.lisDataAttributes({ + * model: "contact", + * include_archived: true + * }) */ public lisDataAttributes( request: Intercom.unstable.LisDataAttributesRequest = {}, - requestOptions?: DataAttributes.RequestOptions, + requestOptions?: DataAttributesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__lisDataAttributes(request, requestOptions)); } private async __lisDataAttributes( request: Intercom.unstable.LisDataAttributesRequest = {}, - requestOptions?: DataAttributes.RequestOptions, + requestOptions?: DataAttributesClient.RequestOptions, ): Promise> { const { model, include_archived: includeArchived } = request; const _queryParams: Record = {}; if (model != null) { - _queryParams["model"] = model; + _queryParams.model = model; } if (includeArchived != null) { - _queryParams["include_archived"] = includeArchived.toString(); + _queryParams.include_archived = includeArchived.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "data_attributes", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.DataAttributeList, rawResponse: _response.rawResponse }; @@ -153,112 +103,59 @@ export class DataAttributes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /data_attributes."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/data_attributes"); } /** * You can create a data attributes for a `contact` or a `company`. * - * @param {Intercom.unstable.CreateDataAttributeRequest} request - * @param {DataAttributes.RequestOptions} requestOptions - Request-specific configuration. + * @param {unknown} request + * @param {DataAttributesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} * * @example * await client.unstable.dataAttributes.createDataAttribute({ - * name: "Mithril Shirt", - * model: "company", - * data_type: "string" - * }) - * - * @example - * await client.unstable.dataAttributes.createDataAttribute({ - * name: "The One Ring", - * model: "contact", - * data_type: "integer" - * }) - * - * @example - * await client.unstable.dataAttributes.createDataAttribute({ - * name: "!nv@l!d n@me", - * model: "company", - * data_type: "string" - * }) - * - * @example - * await client.unstable.dataAttributes.createDataAttribute({ - * name: "The One Ring", - * model: "company", - * data_type: "string" - * }) - * - * @example - * await client.unstable.dataAttributes.createDataAttribute({ - * name: "The Second Ring", - * model: "company", - * data_type: "string" - * }) - * - * @example - * await client.unstable.dataAttributes.createDataAttribute({ - * name: "My Data Attribute", - * model: "contact", - * data_type: "string", - * description: "Just a plain old ring", - * options: ["options"] + * "key": "value" * }) */ public createDataAttribute( - request: Intercom.unstable.CreateDataAttributeRequest, - requestOptions?: DataAttributes.RequestOptions, + request?: unknown, + requestOptions?: DataAttributesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createDataAttribute(request, requestOptions)); } private async __createDataAttribute( - request: Intercom.unstable.CreateDataAttributeRequest, - requestOptions?: DataAttributes.RequestOptions, + request?: unknown, + requestOptions?: DataAttributesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "data_attributes", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.DataAttribute, rawResponse: _response.rawResponse }; @@ -282,21 +179,7 @@ export class DataAttributes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /data_attributes."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/data_attributes"); } /** @@ -308,7 +191,7 @@ export class DataAttributes { * > It is currently a dangerous action to execute changing a data attribute's type via the API. You will need to update the type via the UI instead. * * @param {Intercom.unstable.UpdateDataAttributeRequest} request - * @param {DataAttributes.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataAttributesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -318,63 +201,48 @@ export class DataAttributes { * @example * await client.unstable.dataAttributes.updateDataAttribute({ * id: 1, - * archived: false, - * description: "Just a plain old ring", - * options: ["options", "options"] - * }) - * - * @example - * await client.unstable.dataAttributes.updateDataAttribute({ - * id: 1, - * archived: false, - * description: "Too few options", - * options: ["option1", "option2"] - * }) - * - * @example - * await client.unstable.dataAttributes.updateDataAttribute({ - * id: 1, - * archived: true, - * description: "Trying to archieve" + * body: { + * "key": "value" + * } * }) */ public updateDataAttribute( request: Intercom.unstable.UpdateDataAttributeRequest, - requestOptions?: DataAttributes.RequestOptions, + requestOptions?: DataAttributesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__updateDataAttribute(request, requestOptions)); } private async __updateDataAttribute( request: Intercom.unstable.UpdateDataAttributeRequest, - requestOptions?: DataAttributes.RequestOptions, + requestOptions?: DataAttributesClient.RequestOptions, ): Promise> { - const { id, ..._body } = request; + const { id, body: _body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `data_attributes/${encodeURIComponent(id)}`, + `data_attributes/${core.url.encodePathParam(id)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.DataAttribute, rawResponse: _response.rawResponse }; @@ -405,32 +273,6 @@ export class DataAttributes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /data_attributes/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/data_attributes/{id}"); } } diff --git a/src/api/resources/unstable/resources/dataAttributes/client/index.ts b/src/api/resources/unstable/resources/dataAttributes/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/dataAttributes/client/index.ts +++ b/src/api/resources/unstable/resources/dataAttributes/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts b/src/api/resources/unstable/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts deleted file mode 100644 index d0856471..00000000 --- a/src/api/resources/unstable/resources/dataAttributes/client/requests/CreateDataAttributeRequest.ts +++ /dev/null @@ -1,86 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * @example - * { - * name: "Mithril Shirt", - * model: "company", - * data_type: "string" - * } - * - * @example - * { - * name: "The One Ring", - * model: "contact", - * data_type: "integer" - * } - * - * @example - * { - * name: "!nv@l!d n@me", - * model: "company", - * data_type: "string" - * } - * - * @example - * { - * name: "The One Ring", - * model: "company", - * data_type: "string" - * } - * - * @example - * { - * name: "The Second Ring", - * model: "company", - * data_type: "string" - * } - * - * @example - * { - * name: "My Data Attribute", - * model: "contact", - * data_type: "string", - * description: "Just a plain old ring", - * options: ["options"] - * } - */ -export interface CreateDataAttributeRequest { - /** The name of the data attribute. */ - name: string; - /** The model that the data attribute belongs to. */ - model: CreateDataAttributeRequest.Model; - /** The type of data stored for this attribute. */ - data_type: CreateDataAttributeRequest.DataType; - /** The readable description you see in the UI for the attribute. */ - description?: string; - /** To create list attributes. Provide a set of hashes with `value` as the key of the options you want to make. `data_type` must be `string`. */ - options?: string[]; - /** Can this attribute be updated by the Messenger */ - messenger_writable?: boolean; -} - -export namespace CreateDataAttributeRequest { - /** - * The model that the data attribute belongs to. - */ - export type Model = "contact" | "company"; - export const Model = { - Contact: "contact", - Company: "company", - } as const; - /** - * The type of data stored for this attribute. - */ - export type DataType = "string" | "integer" | "float" | "boolean" | "datetime" | "date"; - export const DataType = { - String: "string", - Integer: "integer", - Float: "float", - Boolean: "boolean", - Datetime: "datetime", - Date: "date", - } as const; -} diff --git a/src/api/resources/unstable/resources/dataAttributes/client/requests/LisDataAttributesRequest.ts b/src/api/resources/unstable/resources/dataAttributes/client/requests/LisDataAttributesRequest.ts index 4764c380..89b6ac5f 100644 --- a/src/api/resources/unstable/resources/dataAttributes/client/requests/LisDataAttributesRequest.ts +++ b/src/api/resources/unstable/resources/dataAttributes/client/requests/LisDataAttributesRequest.ts @@ -1,20 +1,17 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example - * {} + * { + * model: "contact", + * include_archived: true + * } */ export interface LisDataAttributesRequest { - /** - * Specify the data attribute model to return. - */ + /** Specify the data attribute model to return. */ model?: Intercom.unstable.LisDataAttributesRequestModel; - /** - * Include archived attributes in the list. By default we return only non archived data attributes. - */ + /** Include archived attributes in the list. By default we return only non archived data attributes. */ include_archived?: boolean; } diff --git a/src/api/resources/unstable/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts b/src/api/resources/unstable/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts index 80ea0b29..a2d7f595 100644 --- a/src/api/resources/unstable/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts +++ b/src/api/resources/unstable/resources/dataAttributes/client/requests/UpdateDataAttributeRequest.ts @@ -1,50 +1,16 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { * id: 1, - * archived: false, - * description: "Just a plain old ring", - * options: ["options", "options"] - * } - * - * @example - * { - * id: 1, - * archived: false, - * description: "Too few options", - * options: ["option1", "option2"] - * } - * - * @example - * { - * id: 1, - * archived: false, - * description: "Just a plain old ring", - * options: ["options", "options"] - * } - * - * @example - * { - * id: 1, - * archived: true, - * description: "Trying to archieve" + * body: { + * "key": "value" + * } * } */ export interface UpdateDataAttributeRequest { - /** - * The data attribute id - */ + /** The data attribute id */ id: number; - /** Whether the attribute is to be archived or not. */ - archived?: boolean; - /** The readable description you see in the UI for the attribute. */ - description?: string; - /** To create list attributes. Provide a set of hashes with `value` as the key of the options you want to make. `data_type` must be `string`. */ - options?: string[]; - /** Can this attribute be updated by the Messenger */ - messenger_writable?: boolean; + body?: unknown; } diff --git a/src/api/resources/unstable/resources/dataAttributes/client/requests/index.ts b/src/api/resources/unstable/resources/dataAttributes/client/requests/index.ts index 5b0976fe..7776c48b 100644 --- a/src/api/resources/unstable/resources/dataAttributes/client/requests/index.ts +++ b/src/api/resources/unstable/resources/dataAttributes/client/requests/index.ts @@ -1,3 +1,2 @@ -export { type LisDataAttributesRequest } from "./LisDataAttributesRequest"; -export { type CreateDataAttributeRequest } from "./CreateDataAttributeRequest"; -export { type UpdateDataAttributeRequest } from "./UpdateDataAttributeRequest"; +export type { LisDataAttributesRequest } from "./LisDataAttributesRequest.js"; +export type { UpdateDataAttributeRequest } from "./UpdateDataAttributeRequest.js"; diff --git a/src/api/resources/unstable/resources/dataAttributes/index.ts b/src/api/resources/unstable/resources/dataAttributes/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/dataAttributes/index.ts +++ b/src/api/resources/unstable/resources/dataAttributes/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/dataAttributes/types/DataAttribute.ts b/src/api/resources/unstable/resources/dataAttributes/types/DataAttribute.ts index cacf2b7b..090b36d1 100644 --- a/src/api/resources/unstable/resources/dataAttributes/types/DataAttribute.ts +++ b/src/api/resources/unstable/resources/dataAttributes/types/DataAttribute.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Data Attributes are metadata used to describe your contact, company and conversation models. These include standard and custom attributes. By using the data attributes endpoint, you can get the global list of attributes for your workspace, as well as create and archive custom attributes. @@ -43,18 +41,13 @@ export interface DataAttribute { } export namespace DataAttribute { - /** - * Value is `contact` for user/lead attributes and `company` for company attributes. - */ - export type Model = "contact" | "company"; + /** Value is `contact` for user/lead attributes and `company` for company attributes. */ export const Model = { Contact: "contact", Company: "company", } as const; - /** - * The data type of the attribute. - */ - export type DataType = "string" | "integer" | "float" | "boolean" | "date"; + export type Model = (typeof Model)[keyof typeof Model]; + /** The data type of the attribute. */ export const DataType = { String: "string", Integer: "integer", @@ -62,4 +55,5 @@ export namespace DataAttribute { Boolean: "boolean", Date: "date", } as const; + export type DataType = (typeof DataType)[keyof typeof DataType]; } diff --git a/src/api/resources/unstable/resources/dataAttributes/types/LisDataAttributesRequestModel.ts b/src/api/resources/unstable/resources/dataAttributes/types/LisDataAttributesRequestModel.ts index 9ee462c6..06e53b91 100644 --- a/src/api/resources/unstable/resources/dataAttributes/types/LisDataAttributesRequestModel.ts +++ b/src/api/resources/unstable/resources/dataAttributes/types/LisDataAttributesRequestModel.ts @@ -1,10 +1,9 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -export type LisDataAttributesRequestModel = "contact" | "company" | "conversation"; export const LisDataAttributesRequestModel = { Contact: "contact", Company: "company", Conversation: "conversation", } as const; +export type LisDataAttributesRequestModel = + (typeof LisDataAttributesRequestModel)[keyof typeof LisDataAttributesRequestModel]; diff --git a/src/api/resources/unstable/resources/dataAttributes/types/index.ts b/src/api/resources/unstable/resources/dataAttributes/types/index.ts index f452bb6b..7e5f4e72 100644 --- a/src/api/resources/unstable/resources/dataAttributes/types/index.ts +++ b/src/api/resources/unstable/resources/dataAttributes/types/index.ts @@ -1,2 +1,2 @@ -export * from "./LisDataAttributesRequestModel"; -export * from "./DataAttribute"; +export * from "./DataAttribute.js"; +export * from "./LisDataAttributesRequestModel.js"; diff --git a/src/api/resources/unstable/resources/dataEvents/client/Client.ts b/src/api/resources/unstable/resources/dataEvents/client/Client.ts index 7349e445..ad66e987 100644 --- a/src/api/resources/unstable/resources/dataEvents/client/Client.ts +++ b/src/api/resources/unstable/resources/dataEvents/client/Client.ts @@ -1,80 +1,30 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import { toJson } from "../../../../../../core/json"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import { toJson } from "../../../../../../core/json.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace DataEvents { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace DataEventsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Data Events */ -export class DataEvents { - constructor(protected readonly _options: DataEvents.Options = {}) {} +export class DataEventsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: DataEventsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * @@ -93,7 +43,7 @@ export class DataEvents { * You can optionally define the result page size as well with the `per_page` parameter. * * @param {Intercom.unstable.LisDataEventsRequest} request - * @param {DataEvents.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataEventsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -107,48 +57,45 @@ export class DataEvents { */ public lisDataEvents( request: Intercom.unstable.LisDataEventsRequest, - requestOptions?: DataEvents.RequestOptions, + requestOptions?: DataEventsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__lisDataEvents(request, requestOptions)); } private async __lisDataEvents( request: Intercom.unstable.LisDataEventsRequest, - requestOptions?: DataEvents.RequestOptions, + requestOptions?: DataEventsClient.RequestOptions, ): Promise> { const { filter, type: type_, summary } = request; const _queryParams: Record = {}; - _queryParams["filter"] = typeof filter === "string" ? filter : toJson(filter); - _queryParams["type"] = type_; + _queryParams.filter = typeof filter === "string" ? filter : toJson(filter); + _queryParams.type = type_; if (summary != null) { - _queryParams["summary"] = summary.toString(); + _queryParams.summary = summary.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "events", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.DataEventSummary, rawResponse: _response.rawResponse }; @@ -170,21 +117,7 @@ export class DataEvents { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /events."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/events"); } /** @@ -230,8 +163,9 @@ export class DataEvents { * - Event lists containing duplicate events will have those duplicates ignored. * - Server errors will return a `500` response code and may contain an error message in the body. * + * * @param {Intercom.CreateDataEventRequestTwo} request - * @param {DataEvents.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataEventsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -242,40 +176,40 @@ export class DataEvents { */ public createDataEvent( request?: Intercom.CreateDataEventRequestTwo, - requestOptions?: DataEvents.RequestOptions, + requestOptions?: DataEventsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createDataEvent(request, requestOptions)); } private async __createDataEvent( request?: Intercom.CreateDataEventRequestTwo, - requestOptions?: DataEvents.RequestOptions, + requestOptions?: DataEventsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "events", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: undefined, rawResponse: _response.rawResponse }; @@ -297,28 +231,15 @@ export class DataEvents { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /events."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/events"); } /** * Create event summaries for a user. Event summaries are used to track the number of times an event has occurred, the first time it occurred and the last time it occurred. * + * * @param {Intercom.unstable.CreateDataEventSummariesRequest} request - * @param {DataEvents.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataEventsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -327,40 +248,40 @@ export class DataEvents { */ public dataEventSummaries( request: Intercom.unstable.CreateDataEventSummariesRequest = {}, - requestOptions?: DataEvents.RequestOptions, + requestOptions?: DataEventsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__dataEventSummaries(request, requestOptions)); } private async __dataEventSummaries( request: Intercom.unstable.CreateDataEventSummariesRequest = {}, - requestOptions?: DataEvents.RequestOptions, + requestOptions?: DataEventsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "events/summaries", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: undefined, rawResponse: _response.rawResponse }; @@ -382,32 +303,6 @@ export class DataEvents { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /events/summaries."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/events/summaries"); } } diff --git a/src/api/resources/unstable/resources/dataEvents/client/index.ts b/src/api/resources/unstable/resources/dataEvents/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/dataEvents/client/index.ts +++ b/src/api/resources/unstable/resources/dataEvents/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/dataEvents/client/requests/CreateDataEventSummariesRequest.ts b/src/api/resources/unstable/resources/dataEvents/client/requests/CreateDataEventSummariesRequest.ts index 9e731802..ca40dbe7 100644 --- a/src/api/resources/unstable/resources/dataEvents/client/requests/CreateDataEventSummariesRequest.ts +++ b/src/api/resources/unstable/resources/dataEvents/client/requests/CreateDataEventSummariesRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example diff --git a/src/api/resources/unstable/resources/dataEvents/client/requests/LisDataEventsRequest.ts b/src/api/resources/unstable/resources/dataEvents/client/requests/LisDataEventsRequest.ts index 713df5e3..0dc68cfc 100644 --- a/src/api/resources/unstable/resources/dataEvents/client/requests/LisDataEventsRequest.ts +++ b/src/api/resources/unstable/resources/dataEvents/client/requests/LisDataEventsRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example @@ -15,12 +13,8 @@ import * as Intercom from "../../../../../../index"; */ export interface LisDataEventsRequest { filter: Intercom.unstable.LisDataEventsRequestFilter; - /** - * The value must be user - */ + /** The value must be user */ type: string; - /** - * summary flag - */ + /** summary flag */ summary?: boolean; } diff --git a/src/api/resources/unstable/resources/dataEvents/client/requests/index.ts b/src/api/resources/unstable/resources/dataEvents/client/requests/index.ts index 59b33a62..06ee457d 100644 --- a/src/api/resources/unstable/resources/dataEvents/client/requests/index.ts +++ b/src/api/resources/unstable/resources/dataEvents/client/requests/index.ts @@ -1,2 +1,2 @@ -export { type LisDataEventsRequest } from "./LisDataEventsRequest"; -export { type CreateDataEventSummariesRequest } from "./CreateDataEventSummariesRequest"; +export type { CreateDataEventSummariesRequest } from "./CreateDataEventSummariesRequest.js"; +export type { LisDataEventsRequest } from "./LisDataEventsRequest.js"; diff --git a/src/api/resources/unstable/resources/dataEvents/index.ts b/src/api/resources/unstable/resources/dataEvents/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/dataEvents/index.ts +++ b/src/api/resources/unstable/resources/dataEvents/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/dataEvents/types/DataEvent.ts b/src/api/resources/unstable/resources/dataEvents/types/DataEvent.ts index 124221eb..a88a24e6 100644 --- a/src/api/resources/unstable/resources/dataEvents/types/DataEvent.ts +++ b/src/api/resources/unstable/resources/dataEvents/types/DataEvent.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Data events are used to notify Intercom of changes to your data. diff --git a/src/api/resources/unstable/resources/dataEvents/types/LisDataEventsRequestFilter.ts b/src/api/resources/unstable/resources/dataEvents/types/LisDataEventsRequestFilter.ts index a12948ea..57f5d409 100644 --- a/src/api/resources/unstable/resources/dataEvents/types/LisDataEventsRequestFilter.ts +++ b/src/api/resources/unstable/resources/dataEvents/types/LisDataEventsRequestFilter.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export type LisDataEventsRequestFilter = | { diff --git a/src/api/resources/unstable/resources/dataEvents/types/index.ts b/src/api/resources/unstable/resources/dataEvents/types/index.ts index 57668594..dbd381c1 100644 --- a/src/api/resources/unstable/resources/dataEvents/types/index.ts +++ b/src/api/resources/unstable/resources/dataEvents/types/index.ts @@ -1,2 +1,2 @@ -export * from "./LisDataEventsRequestFilter"; -export * from "./DataEvent"; +export * from "./DataEvent.js"; +export * from "./LisDataEventsRequestFilter.js"; diff --git a/src/api/resources/unstable/resources/dataExport/client/Client.ts b/src/api/resources/unstable/resources/dataExport/client/Client.ts index 6f6a2ebe..9381c9f5 100644 --- a/src/api/resources/unstable/resources/dataExport/client/Client.ts +++ b/src/api/resources/unstable/resources/dataExport/client/Client.ts @@ -1,79 +1,29 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import type * as Intercom from "../../../../../index.js"; -export declare namespace DataExport { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace DataExportClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Data Exports */ -export class DataExport { - constructor(protected readonly _options: DataExport.Options = {}) {} +export class DataExportClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: DataExportClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * To create your export job, you need to send a `POST` request to the export endpoint `https://api.intercom.io/export/content/data`. @@ -93,7 +43,7 @@ export class DataExport { * > Requesting data for 2018-06-01 until 2018-06-30 will get all data for those days including those specified - e.g. 2018-06-01 00:00:00 until 2018-06-30 23:59:99. * * @param {Intercom.unstable.CreateDataExportsRequest} request - * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataExportClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.unstable.dataExport.createDataExport({ @@ -103,40 +53,40 @@ export class DataExport { */ public createDataExport( request: Intercom.unstable.CreateDataExportsRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createDataExport(request, requestOptions)); } private async __createDataExport( request: Intercom.unstable.CreateDataExportsRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "export/content/data", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.DataExport, rawResponse: _response.rawResponse }; @@ -150,21 +100,7 @@ export class DataExport { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /export/content/data."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/export/content/data"); } /** @@ -175,7 +111,7 @@ export class DataExport { * > All jobs that have completed processing (and are thus available to download from the provided URL) will have an expiry limit of two days from when the export ob completed. After this, the data will no longer be available. * * @param {Intercom.unstable.GetDataExportRequest} request - * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataExportClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.unstable.dataExport.getDataExport({ @@ -184,40 +120,38 @@ export class DataExport { */ public getDataExport( request: Intercom.unstable.GetDataExportRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__getDataExport(request, requestOptions)); } private async __getDataExport( request: Intercom.unstable.GetDataExportRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): Promise> { const { job_identifier: jobIdentifier } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `export/content/data/${encodeURIComponent(jobIdentifier)}`, + `export/content/data/${core.url.encodePathParam(jobIdentifier)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.DataExport, rawResponse: _response.rawResponse }; @@ -231,30 +165,19 @@ export class DataExport { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /export/content/data/{job_identifier}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/export/content/data/{job_identifier}", + ); } /** * You can cancel your job * * @param {Intercom.unstable.CancelDataExportRequest} request - * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataExportClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.unstable.dataExport.cancelDataExport({ @@ -263,40 +186,38 @@ export class DataExport { */ public cancelDataExport( request: Intercom.unstable.CancelDataExportRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__cancelDataExport(request, requestOptions)); } private async __cancelDataExport( request: Intercom.unstable.CancelDataExportRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): Promise> { const { job_identifier: jobIdentifier } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `export/cancel/${encodeURIComponent(jobIdentifier)}`, + `export/cancel/${core.url.encodePathParam(jobIdentifier)}`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.DataExport, rawResponse: _response.rawResponse }; @@ -310,23 +231,12 @@ export class DataExport { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /export/cancel/{job_identifier}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/export/cancel/{job_identifier}", + ); } /** @@ -339,7 +249,7 @@ export class DataExport { * > You will have to specify the header Accept: `application/octet-stream` when hitting this endpoint. * * @param {Intercom.unstable.DownloadDataExportRequest} request - * @param {DataExport.RequestOptions} requestOptions - Request-specific configuration. + * @param {DataExportClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.unstable.dataExport.downloadDataExport({ @@ -348,40 +258,38 @@ export class DataExport { */ public downloadDataExport( request: Intercom.unstable.DownloadDataExportRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__downloadDataExport(request, requestOptions)); } private async __downloadDataExport( request: Intercom.unstable.DownloadDataExportRequest, - requestOptions?: DataExport.RequestOptions, + requestOptions?: DataExportClient.RequestOptions, ): Promise> { const { job_identifier: jobIdentifier } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `download/content/data/${encodeURIComponent(jobIdentifier)}`, + `download/content/data/${core.url.encodePathParam(jobIdentifier)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: undefined, rawResponse: _response.rawResponse }; @@ -395,34 +303,11 @@ export class DataExport { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /download/content/data/{job_identifier}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/download/content/data/{job_identifier}", + ); } } diff --git a/src/api/resources/unstable/resources/dataExport/client/index.ts b/src/api/resources/unstable/resources/dataExport/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/dataExport/client/index.ts +++ b/src/api/resources/unstable/resources/dataExport/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/dataExport/client/requests/CancelDataExportRequest.ts b/src/api/resources/unstable/resources/dataExport/client/requests/CancelDataExportRequest.ts index 39ed6925..4e387ec1 100644 --- a/src/api/resources/unstable/resources/dataExport/client/requests/CancelDataExportRequest.ts +++ b/src/api/resources/unstable/resources/dataExport/client/requests/CancelDataExportRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface CancelDataExportRequest { - /** - * job_identifier - */ + /** job_identifier */ job_identifier: string; } diff --git a/src/api/resources/unstable/resources/dataExport/client/requests/CreateDataExportsRequest.ts b/src/api/resources/unstable/resources/dataExport/client/requests/CreateDataExportsRequest.ts index 78a96196..8854b7c9 100644 --- a/src/api/resources/unstable/resources/dataExport/client/requests/CreateDataExportsRequest.ts +++ b/src/api/resources/unstable/resources/dataExport/client/requests/CreateDataExportsRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example diff --git a/src/api/resources/unstable/resources/dataExport/client/requests/DownloadDataExportRequest.ts b/src/api/resources/unstable/resources/dataExport/client/requests/DownloadDataExportRequest.ts index 4a7ee828..98aab0f3 100644 --- a/src/api/resources/unstable/resources/dataExport/client/requests/DownloadDataExportRequest.ts +++ b/src/api/resources/unstable/resources/dataExport/client/requests/DownloadDataExportRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DownloadDataExportRequest { - /** - * job_identifier - */ + /** job_identifier */ job_identifier: string; } diff --git a/src/api/resources/unstable/resources/dataExport/client/requests/GetDataExportRequest.ts b/src/api/resources/unstable/resources/dataExport/client/requests/GetDataExportRequest.ts index b03dfb16..e75f9c9d 100644 --- a/src/api/resources/unstable/resources/dataExport/client/requests/GetDataExportRequest.ts +++ b/src/api/resources/unstable/resources/dataExport/client/requests/GetDataExportRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface GetDataExportRequest { - /** - * job_identifier - */ + /** job_identifier */ job_identifier: string; } diff --git a/src/api/resources/unstable/resources/dataExport/client/requests/index.ts b/src/api/resources/unstable/resources/dataExport/client/requests/index.ts index 4f6d12f0..4a322611 100644 --- a/src/api/resources/unstable/resources/dataExport/client/requests/index.ts +++ b/src/api/resources/unstable/resources/dataExport/client/requests/index.ts @@ -1,4 +1,4 @@ -export { type CreateDataExportsRequest } from "./CreateDataExportsRequest"; -export { type GetDataExportRequest } from "./GetDataExportRequest"; -export { type CancelDataExportRequest } from "./CancelDataExportRequest"; -export { type DownloadDataExportRequest } from "./DownloadDataExportRequest"; +export type { CancelDataExportRequest } from "./CancelDataExportRequest.js"; +export type { CreateDataExportsRequest } from "./CreateDataExportsRequest.js"; +export type { DownloadDataExportRequest } from "./DownloadDataExportRequest.js"; +export type { GetDataExportRequest } from "./GetDataExportRequest.js"; diff --git a/src/api/resources/unstable/resources/dataExport/index.ts b/src/api/resources/unstable/resources/dataExport/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/dataExport/index.ts +++ b/src/api/resources/unstable/resources/dataExport/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/dataExport/types/DataExport.ts b/src/api/resources/unstable/resources/dataExport/types/DataExport.ts index bd19f8c9..c846e2bb 100644 --- a/src/api/resources/unstable/resources/dataExport/types/DataExport.ts +++ b/src/api/resources/unstable/resources/dataExport/types/DataExport.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The data export api is used to view all message sent & viewed in a given timeframe. @@ -17,10 +15,7 @@ export interface DataExport { } export namespace DataExport { - /** - * The current state of your job. - */ - export type Status = "pending" | "in_progress" | "failed" | "completed" | "no_data" | "canceled"; + /** The current state of your job. */ export const Status = { Pending: "pending", InProgress: "in_progress", @@ -29,4 +24,5 @@ export namespace DataExport { NoData: "no_data", Canceled: "canceled", } as const; + export type Status = (typeof Status)[keyof typeof Status]; } diff --git a/src/api/resources/unstable/resources/dataExport/types/index.ts b/src/api/resources/unstable/resources/dataExport/types/index.ts index 7cea751a..881ccc6c 100644 --- a/src/api/resources/unstable/resources/dataExport/types/index.ts +++ b/src/api/resources/unstable/resources/dataExport/types/index.ts @@ -1 +1 @@ -export * from "./DataExport"; +export * from "./DataExport.js"; diff --git a/src/api/resources/unstable/resources/emails/client/Client.ts b/src/api/resources/unstable/resources/emails/client/Client.ts new file mode 100644 index 00000000..80dc6bdf --- /dev/null +++ b/src/api/resources/unstable/resources/emails/client/Client.ts @@ -0,0 +1,166 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; + +export declare namespace EmailsClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * Everything about your Emails + */ +export class EmailsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: EmailsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * Lists all sender email address settings for the workspace + * + * @param {EmailsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.emails.listEmails() + */ + public listEmails( + requestOptions?: EmailsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listEmails(requestOptions)); + } + + private async __listEmails( + requestOptions?: EmailsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "emails", + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.EmailList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/emails"); + } + + /** + * Fetches a specific email setting by its unique identifier + * + * @param {Intercom.unstable.RetrieveEmailRequest} request + * @param {EmailsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.emails.retrieveEmail({ + * id: "id" + * }) + */ + public retrieveEmail( + request: Intercom.unstable.RetrieveEmailRequest, + requestOptions?: EmailsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveEmail(request, requestOptions)); + } + + private async __retrieveEmail( + request: Intercom.unstable.RetrieveEmailRequest, + requestOptions?: EmailsClient.RequestOptions, + ): Promise> { + const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `emails/${core.url.encodePathParam(id)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.EmailSetting, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/emails/{id}"); + } +} diff --git a/src/api/resources/unstable/resources/emails/client/index.ts b/src/api/resources/unstable/resources/emails/client/index.ts new file mode 100644 index 00000000..195f9aa8 --- /dev/null +++ b/src/api/resources/unstable/resources/emails/client/index.ts @@ -0,0 +1 @@ +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/emails/client/requests/RetrieveEmailRequest.ts b/src/api/resources/unstable/resources/emails/client/requests/RetrieveEmailRequest.ts new file mode 100644 index 00000000..7e8d58ab --- /dev/null +++ b/src/api/resources/unstable/resources/emails/client/requests/RetrieveEmailRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * id: "id" + * } + */ +export interface RetrieveEmailRequest { + /** The unique identifier of the email setting */ + id: string; +} diff --git a/src/api/resources/unstable/resources/emails/client/requests/index.ts b/src/api/resources/unstable/resources/emails/client/requests/index.ts new file mode 100644 index 00000000..28137871 --- /dev/null +++ b/src/api/resources/unstable/resources/emails/client/requests/index.ts @@ -0,0 +1 @@ +export type { RetrieveEmailRequest } from "./RetrieveEmailRequest.js"; diff --git a/src/api/resources/unstable/resources/emails/index.ts b/src/api/resources/unstable/resources/emails/index.ts new file mode 100644 index 00000000..d9adb1af --- /dev/null +++ b/src/api/resources/unstable/resources/emails/index.ts @@ -0,0 +1,2 @@ +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/emails/types/EmailList.ts b/src/api/resources/unstable/resources/emails/types/EmailList.ts new file mode 100644 index 00000000..41aa6d09 --- /dev/null +++ b/src/api/resources/unstable/resources/emails/types/EmailList.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../../index.js"; + +/** + * A list of email settings + */ +export interface EmailList { + /** The type of object */ + type?: string; + data?: Intercom.unstable.EmailSetting[]; +} diff --git a/src/api/resources/unstable/resources/emails/types/EmailSetting.ts b/src/api/resources/unstable/resources/emails/types/EmailSetting.ts new file mode 100644 index 00000000..bd584aec --- /dev/null +++ b/src/api/resources/unstable/resources/emails/types/EmailSetting.ts @@ -0,0 +1,27 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Represents a sender email address configuration + */ +export interface EmailSetting { + /** The type of object */ + type?: string; + /** Unique email setting identifier */ + id?: string; + /** Full sender email address */ + email?: string; + /** Whether the email address has been verified */ + verified?: boolean; + /** Domain portion of the email address */ + domain?: string; + /** Associated brand identifier */ + brand_id?: string; + /** Whether email forwarding is active */ + forwarding_enabled?: boolean; + /** Unix timestamp of last forwarded email received (null if never) */ + forwarded_email_last_received_at?: number; + /** Unix timestamp of creation */ + created_at?: number; + /** Unix timestamp of last modification */ + updated_at?: number; +} diff --git a/src/api/resources/unstable/resources/emails/types/index.ts b/src/api/resources/unstable/resources/emails/types/index.ts new file mode 100644 index 00000000..ffc91a1b --- /dev/null +++ b/src/api/resources/unstable/resources/emails/types/index.ts @@ -0,0 +1,2 @@ +export * from "./EmailList.js"; +export * from "./EmailSetting.js"; diff --git a/src/api/resources/unstable/resources/export/client/Client.ts b/src/api/resources/unstable/resources/export/client/Client.ts index b067f559..af0ecc87 100644 --- a/src/api/resources/unstable/resources/export/client/Client.ts +++ b/src/api/resources/unstable/resources/export/client/Client.ts @@ -1,80 +1,30 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Export { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace ExportClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } -export class Export { - constructor(protected readonly _options: Export.Options = {}) {} +export class ExportClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: ExportClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * @param {Intercom.unstable.PostExportReportingDataEnqueueRequest} request - * @param {Export.RequestOptions} requestOptions - Request-specific configuration. + * @param {ExportClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -83,47 +33,47 @@ export class Export { * @example * await client.unstable.export.enqueueANewReportingDataExportJob({ * dataset_id: "conversation", - * attribute_ids: ["conversation.id", "conversation.first_user_conversation_part_created_at"], + * attribute_ids: ["conversation_id", "conversation_started_at"], * start_time: 1717490000, * end_time: 1717510000 * }) */ public enqueueANewReportingDataExportJob( request: Intercom.unstable.PostExportReportingDataEnqueueRequest, - requestOptions?: Export.RequestOptions, + requestOptions?: ExportClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__enqueueANewReportingDataExportJob(request, requestOptions)); } private async __enqueueANewReportingDataExportJob( request: Intercom.unstable.PostExportReportingDataEnqueueRequest, - requestOptions?: Export.RequestOptions, + requestOptions?: ExportClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "export/reporting_data/enqueue", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -155,64 +105,51 @@ export class Export { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /export/reporting_data/enqueue.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/export/reporting_data/enqueue", + ); } /** - * @param {Export.RequestOptions} requestOptions - Request-specific configuration. + * @param {ExportClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.unstable.export.listAvailableDatasetsAndAttributes() */ public listAvailableDatasetsAndAttributes( - requestOptions?: Export.RequestOptions, + requestOptions?: ExportClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listAvailableDatasetsAndAttributes(requestOptions)); } private async __listAvailableDatasetsAndAttributes( - requestOptions?: Export.RequestOptions, + requestOptions?: ExportClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "export/reporting_data/get_datasets", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -229,34 +166,11 @@ export class Export { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /export/reporting_data/get_datasets.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/export/reporting_data/get_datasets", + ); } } diff --git a/src/api/resources/unstable/resources/export/client/index.ts b/src/api/resources/unstable/resources/export/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/export/client/index.ts +++ b/src/api/resources/unstable/resources/export/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/export/client/requests/PostExportReportingDataEnqueueRequest.ts b/src/api/resources/unstable/resources/export/client/requests/PostExportReportingDataEnqueueRequest.ts index 55c7d4f8..57767a44 100644 --- a/src/api/resources/unstable/resources/export/client/requests/PostExportReportingDataEnqueueRequest.ts +++ b/src/api/resources/unstable/resources/export/client/requests/PostExportReportingDataEnqueueRequest.ts @@ -1,12 +1,10 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { * dataset_id: "conversation", - * attribute_ids: ["conversation.id", "conversation.first_user_conversation_part_created_at"], + * attribute_ids: ["conversation_id", "conversation_started_at"], * start_time: 1717490000, * end_time: 1717510000 * } diff --git a/src/api/resources/unstable/resources/export/client/requests/index.ts b/src/api/resources/unstable/resources/export/client/requests/index.ts index bcda81be..a18772b7 100644 --- a/src/api/resources/unstable/resources/export/client/requests/index.ts +++ b/src/api/resources/unstable/resources/export/client/requests/index.ts @@ -1 +1 @@ -export { type PostExportReportingDataEnqueueRequest } from "./PostExportReportingDataEnqueueRequest"; +export type { PostExportReportingDataEnqueueRequest } from "./PostExportReportingDataEnqueueRequest.js"; diff --git a/src/api/resources/unstable/resources/export/index.ts b/src/api/resources/unstable/resources/export/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/export/index.ts +++ b/src/api/resources/unstable/resources/export/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/export/types/GetExportReportingDataGetDatasetsResponse.ts b/src/api/resources/unstable/resources/export/types/GetExportReportingDataGetDatasetsResponse.ts index ab8c3ba6..725ac29a 100644 --- a/src/api/resources/unstable/resources/export/types/GetExportReportingDataGetDatasetsResponse.ts +++ b/src/api/resources/unstable/resources/export/types/GetExportReportingDataGetDatasetsResponse.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export interface GetExportReportingDataGetDatasetsResponse { type?: string; diff --git a/src/api/resources/unstable/resources/export/types/PostExportReportingDataEnqueueResponse.ts b/src/api/resources/unstable/resources/export/types/PostExportReportingDataEnqueueResponse.ts index 55a28e65..c15d988e 100644 --- a/src/api/resources/unstable/resources/export/types/PostExportReportingDataEnqueueResponse.ts +++ b/src/api/resources/unstable/resources/export/types/PostExportReportingDataEnqueueResponse.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export interface PostExportReportingDataEnqueueResponse { job_identifier?: string; diff --git a/src/api/resources/unstable/resources/export/types/index.ts b/src/api/resources/unstable/resources/export/types/index.ts index cc8706ee..27e82ed3 100644 --- a/src/api/resources/unstable/resources/export/types/index.ts +++ b/src/api/resources/unstable/resources/export/types/index.ts @@ -1,2 +1,2 @@ -export * from "./PostExportReportingDataEnqueueResponse"; -export * from "./GetExportReportingDataGetDatasetsResponse"; +export * from "./GetExportReportingDataGetDatasetsResponse.js"; +export * from "./PostExportReportingDataEnqueueResponse.js"; diff --git a/src/api/resources/unstable/resources/helpCenter/client/Client.ts b/src/api/resources/unstable/resources/helpCenter/client/Client.ts index 776053b4..73d06f5d 100644 --- a/src/api/resources/unstable/resources/helpCenter/client/Client.ts +++ b/src/api/resources/unstable/resources/helpCenter/client/Client.ts @@ -1,86 +1,36 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; - -export declare namespace HelpCenter { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } +export declare namespace HelpCenterClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Help Center */ -export class HelpCenter { - constructor(protected readonly _options: HelpCenter.Options = {}) {} +export class HelpCenterClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: HelpCenterClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of all collections by making a GET request to `https://api.intercom.io/help_center/collections`. * * Collections will be returned in descending order on the `updated_at` attribute. This means if you need to iterate through results then we'll show the most recently updated collections first. * - * @param {HelpCenter.RequestOptions} requestOptions - Request-specific configuration. + * @param {HelpCenterClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -88,38 +38,36 @@ export class HelpCenter { * await client.unstable.helpCenter.listAllCollections() */ public listAllCollections( - requestOptions?: HelpCenter.RequestOptions, + requestOptions?: HelpCenterClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listAllCollections(requestOptions)); } private async __listAllCollections( - requestOptions?: HelpCenter.RequestOptions, + requestOptions?: HelpCenterClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "help_center/collections", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.CollectionList, rawResponse: _response.rawResponse }; @@ -141,28 +89,14 @@ export class HelpCenter { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /help_center/collections."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/help_center/collections"); } /** * You can create a new collection by making a POST request to `https://api.intercom.io/help_center/collections.` * * @param {Intercom.unstable.CreateCollectionRequest} request - * @param {HelpCenter.RequestOptions} requestOptions - Request-specific configuration. + * @param {HelpCenterClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -180,40 +114,40 @@ export class HelpCenter { */ public createCollection( request: Intercom.unstable.CreateCollectionRequest, - requestOptions?: HelpCenter.RequestOptions, + requestOptions?: HelpCenterClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createCollection(request, requestOptions)); } private async __createCollection( request: Intercom.unstable.CreateCollectionRequest, - requestOptions?: HelpCenter.RequestOptions, + requestOptions?: HelpCenterClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "help_center/collections", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Collection, rawResponse: _response.rawResponse }; @@ -237,28 +171,14 @@ export class HelpCenter { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /help_center/collections."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/help_center/collections"); } /** * You can fetch the details of a single collection by making a GET request to `https://api.intercom.io/help_center/collections/`. * * @param {Intercom.unstable.RetrieveCollectionRequest} request - * @param {HelpCenter.RequestOptions} requestOptions - Request-specific configuration. + * @param {HelpCenterClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -270,40 +190,38 @@ export class HelpCenter { */ public retrieveCollection( request: Intercom.unstable.RetrieveCollectionRequest, - requestOptions?: HelpCenter.RequestOptions, + requestOptions?: HelpCenterClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__retrieveCollection(request, requestOptions)); } private async __retrieveCollection( request: Intercom.unstable.RetrieveCollectionRequest, - requestOptions?: HelpCenter.RequestOptions, + requestOptions?: HelpCenterClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `help_center/collections/${encodeURIComponent(id)}`, + `help_center/collections/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Collection, rawResponse: _response.rawResponse }; @@ -327,30 +245,14 @@ export class HelpCenter { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /help_center/collections/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/help_center/collections/{id}"); } /** * You can update the details of a single collection by making a PUT request to `https://api.intercom.io/collections/`. * * @param {Intercom.unstable.UpdateCollectionRequest} request - * @param {HelpCenter.RequestOptions} requestOptions - Request-specific configuration. + * @param {HelpCenterClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -363,41 +265,41 @@ export class HelpCenter { */ public updateCollection( request: Intercom.unstable.UpdateCollectionRequest, - requestOptions?: HelpCenter.RequestOptions, + requestOptions?: HelpCenterClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__updateCollection(request, requestOptions)); } private async __updateCollection( request: Intercom.unstable.UpdateCollectionRequest, - requestOptions?: HelpCenter.RequestOptions, + requestOptions?: HelpCenterClient.RequestOptions, ): Promise> { const { id, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `help_center/collections/${encodeURIComponent(id)}`, + `help_center/collections/${core.url.encodePathParam(id)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Collection, rawResponse: _response.rawResponse }; @@ -421,30 +323,14 @@ export class HelpCenter { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /help_center/collections/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/help_center/collections/{id}"); } /** * You can delete a single collection by making a DELETE request to `https://api.intercom.io/collections/`. * * @param {Intercom.unstable.DeleteCollectionRequest} request - * @param {HelpCenter.RequestOptions} requestOptions - Request-specific configuration. + * @param {HelpCenterClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -456,40 +342,38 @@ export class HelpCenter { */ public deleteCollection( request: Intercom.unstable.DeleteCollectionRequest, - requestOptions?: HelpCenter.RequestOptions, + requestOptions?: HelpCenterClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__deleteCollection(request, requestOptions)); } private async __deleteCollection( request: Intercom.unstable.DeleteCollectionRequest, - requestOptions?: HelpCenter.RequestOptions, + requestOptions?: HelpCenterClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `help_center/collections/${encodeURIComponent(id)}`, + `help_center/collections/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -516,30 +400,19 @@ export class HelpCenter { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /help_center/collections/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/help_center/collections/{id}", + ); } /** * You can fetch the details of a single Help Center by making a GET request to `https://api.intercom.io/help_center/help_center/`. * * @param {Intercom.unstable.RetrieveHelpCenterRequest} request - * @param {HelpCenter.RequestOptions} requestOptions - Request-specific configuration. + * @param {HelpCenterClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -551,40 +424,38 @@ export class HelpCenter { */ public retrieveHelpCenter( request: Intercom.unstable.RetrieveHelpCenterRequest, - requestOptions?: HelpCenter.RequestOptions, + requestOptions?: HelpCenterClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__retrieveHelpCenter(request, requestOptions)); } private async __retrieveHelpCenter( request: Intercom.unstable.RetrieveHelpCenterRequest, - requestOptions?: HelpCenter.RequestOptions, + requestOptions?: HelpCenterClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `help_center/help_centers/${encodeURIComponent(id)}`, + `help_center/help_centers/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.HelpCenter, rawResponse: _response.rawResponse }; @@ -608,29 +479,18 @@ export class HelpCenter { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling GET /help_center/help_centers/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/help_center/help_centers/{id}", + ); } /** * You can list all Help Centers by making a GET request to `https://api.intercom.io/help_center/help_centers`. * - * @param {HelpCenter.RequestOptions} requestOptions - Request-specific configuration. + * @param {HelpCenterClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -638,38 +498,36 @@ export class HelpCenter { * await client.unstable.helpCenter.listHelpCenters() */ public listHelpCenters( - requestOptions?: HelpCenter.RequestOptions, + requestOptions?: HelpCenterClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listHelpCenters(requestOptions)); } private async __listHelpCenters( - requestOptions?: HelpCenter.RequestOptions, + requestOptions?: HelpCenterClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "help_center/help_centers", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.HelpCenterList, rawResponse: _response.rawResponse }; @@ -691,32 +549,6 @@ export class HelpCenter { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /help_center/help_centers."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/help_center/help_centers"); } } diff --git a/src/api/resources/unstable/resources/helpCenter/client/index.ts b/src/api/resources/unstable/resources/helpCenter/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/helpCenter/client/index.ts +++ b/src/api/resources/unstable/resources/helpCenter/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/helpCenter/client/requests/CreateCollectionRequest.ts b/src/api/resources/unstable/resources/helpCenter/client/requests/CreateCollectionRequest.ts index 7b50caa9..79a825bf 100644 --- a/src/api/resources/unstable/resources/helpCenter/client/requests/CreateCollectionRequest.ts +++ b/src/api/resources/unstable/resources/helpCenter/client/requests/CreateCollectionRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example diff --git a/src/api/resources/unstable/resources/helpCenter/client/requests/DeleteCollectionRequest.ts b/src/api/resources/unstable/resources/helpCenter/client/requests/DeleteCollectionRequest.ts index eaf33993..fb363f5c 100644 --- a/src/api/resources/unstable/resources/helpCenter/client/requests/DeleteCollectionRequest.ts +++ b/src/api/resources/unstable/resources/helpCenter/client/requests/DeleteCollectionRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DeleteCollectionRequest { - /** - * The unique identifier for the collection which is given by Intercom. - */ + /** The unique identifier for the collection which is given by Intercom. */ id: number; } diff --git a/src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveCollectionRequest.ts b/src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveCollectionRequest.ts index 4737b56b..b444789d 100644 --- a/src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveCollectionRequest.ts +++ b/src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveCollectionRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface RetrieveCollectionRequest { - /** - * The unique identifier for the collection which is given by Intercom. - */ + /** The unique identifier for the collection which is given by Intercom. */ id: number; } diff --git a/src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveHelpCenterRequest.ts b/src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveHelpCenterRequest.ts index 42057096..b4787e86 100644 --- a/src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveHelpCenterRequest.ts +++ b/src/api/resources/unstable/resources/helpCenter/client/requests/RetrieveHelpCenterRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface RetrieveHelpCenterRequest { - /** - * The unique identifier for the collection which is given by Intercom. - */ + /** The unique identifier for the collection which is given by Intercom. */ id: number; } diff --git a/src/api/resources/unstable/resources/helpCenter/client/requests/UpdateCollectionRequest.ts b/src/api/resources/unstable/resources/helpCenter/client/requests/UpdateCollectionRequest.ts index 58505b62..9caeacc0 100644 --- a/src/api/resources/unstable/resources/helpCenter/client/requests/UpdateCollectionRequest.ts +++ b/src/api/resources/unstable/resources/helpCenter/client/requests/UpdateCollectionRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example @@ -18,9 +16,7 @@ import * as Intercom from "../../../../../../index"; * } */ export interface UpdateCollectionRequest { - /** - * The unique identifier for the collection which is given by Intercom. - */ + /** The unique identifier for the collection which is given by Intercom. */ id: number; /** The name of the collection. For multilingual collections, this will be the name of the default language's content. */ name?: string; diff --git a/src/api/resources/unstable/resources/helpCenter/client/requests/index.ts b/src/api/resources/unstable/resources/helpCenter/client/requests/index.ts index b39271fa..d2d1c0aa 100644 --- a/src/api/resources/unstable/resources/helpCenter/client/requests/index.ts +++ b/src/api/resources/unstable/resources/helpCenter/client/requests/index.ts @@ -1,5 +1,5 @@ -export { type CreateCollectionRequest } from "./CreateCollectionRequest"; -export { type RetrieveCollectionRequest } from "./RetrieveCollectionRequest"; -export { type UpdateCollectionRequest } from "./UpdateCollectionRequest"; -export { type DeleteCollectionRequest } from "./DeleteCollectionRequest"; -export { type RetrieveHelpCenterRequest } from "./RetrieveHelpCenterRequest"; +export type { CreateCollectionRequest } from "./CreateCollectionRequest.js"; +export type { DeleteCollectionRequest } from "./DeleteCollectionRequest.js"; +export type { RetrieveCollectionRequest } from "./RetrieveCollectionRequest.js"; +export type { RetrieveHelpCenterRequest } from "./RetrieveHelpCenterRequest.js"; +export type { UpdateCollectionRequest } from "./UpdateCollectionRequest.js"; diff --git a/src/api/resources/unstable/resources/helpCenter/index.ts b/src/api/resources/unstable/resources/helpCenter/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/helpCenter/index.ts +++ b/src/api/resources/unstable/resources/helpCenter/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/helpCenter/types/Collection.ts b/src/api/resources/unstable/resources/helpCenter/types/Collection.ts index ef0fa2ec..475021d4 100644 --- a/src/api/resources/unstable/resources/helpCenter/types/Collection.ts +++ b/src/api/resources/unstable/resources/helpCenter/types/Collection.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * Collections are top level containers for Articles within the Help Center. diff --git a/src/api/resources/unstable/resources/helpCenter/types/HelpCenter.ts b/src/api/resources/unstable/resources/helpCenter/types/HelpCenter.ts index 30cba20e..3715e87f 100644 --- a/src/api/resources/unstable/resources/helpCenter/types/HelpCenter.ts +++ b/src/api/resources/unstable/resources/helpCenter/types/HelpCenter.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Help Centers contain collections @@ -20,4 +18,8 @@ export interface HelpCenter { website_turned_on?: boolean; /** The display name of the Help Center only seen by teammates. */ display_name?: string; + /** The URL for the help center, if you have a custom domain then this will show the URL using the custom domain. */ + url?: string; + /** Custom domain configured for the help center */ + custom_domain?: string; } diff --git a/src/api/resources/unstable/resources/helpCenter/types/HelpCenterList.ts b/src/api/resources/unstable/resources/helpCenter/types/HelpCenterList.ts index ee6c2a05..75bc4786 100644 --- a/src/api/resources/unstable/resources/helpCenter/types/HelpCenterList.ts +++ b/src/api/resources/unstable/resources/helpCenter/types/HelpCenterList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * A list of Help Centers belonging to the App diff --git a/src/api/resources/unstable/resources/helpCenter/types/index.ts b/src/api/resources/unstable/resources/helpCenter/types/index.ts index 65d348a7..097e7b49 100644 --- a/src/api/resources/unstable/resources/helpCenter/types/index.ts +++ b/src/api/resources/unstable/resources/helpCenter/types/index.ts @@ -1,3 +1,3 @@ -export * from "./Collection"; -export * from "./HelpCenter"; -export * from "./HelpCenterList"; +export * from "./Collection.js"; +export * from "./HelpCenter.js"; +export * from "./HelpCenterList.js"; diff --git a/src/api/resources/unstable/resources/index.ts b/src/api/resources/unstable/resources/index.ts index a7c8f375..47fc9e84 100644 --- a/src/api/resources/unstable/resources/index.ts +++ b/src/api/resources/unstable/resources/index.ts @@ -1,78 +1,93 @@ -export * as admins from "./admins"; -export * from "./admins/types"; -export * as aiContent from "./aiContent"; -export * from "./aiContent/types"; -export * as articles from "./articles"; -export * from "./articles/types"; -export * as export_ from "./export"; -export * from "./export/types"; -export * as helpCenter from "./helpCenter"; -export * from "./helpCenter/types"; -export * as companies from "./companies"; -export * from "./companies/types"; -export * as contacts from "./contacts"; -export * from "./contacts/types"; -export * as notes from "./notes"; -export * from "./notes/types"; -export * as subscriptionTypes from "./subscriptionTypes"; -export * from "./subscriptionTypes/types"; -export * as tags from "./tags"; -export * from "./tags/types"; -export * as conversations from "./conversations"; -export * from "./conversations/types"; -export * as customObjectInstances from "./customObjectInstances"; -export * from "./customObjectInstances/types"; -export * as dataAttributes from "./dataAttributes"; -export * from "./dataAttributes/types"; -export * as dataEvents from "./dataEvents"; -export * from "./dataEvents/types"; -export * as dataExport from "./dataExport"; -export * from "./dataExport/types"; -export * as jobs from "./jobs"; -export * from "./jobs/types"; -export * as messages from "./messages"; -export * from "./messages/types"; -export * as news from "./news"; -export * from "./news/types"; -export * as segments from "./segments"; -export * from "./segments/types"; -export * as teams from "./teams"; -export * from "./teams/types"; -export * as tickets from "./tickets"; -export * from "./tickets/types"; -export * as aiAgent from "./aiAgent"; -export * from "./aiAgent/types"; -export * as aiContentSource from "./aiContentSource"; -export * from "./aiContentSource/types"; -export * as awayStatusReasons from "./awayStatusReasons"; -export * as customChannelEvents from "./customChannelEvents"; -export * as switch_ from "./switch"; -export * as ticketStates from "./ticketStates"; -export * as ticketTypeAttributes from "./ticketTypeAttributes"; -export * as ticketTypes from "./ticketTypes"; -export * as visitors from "./visitors"; -export * from "./admins/client/requests"; -export * from "./aiContent/client/requests"; -export * from "./articles/client/requests"; -export * from "./export/client/requests"; -export * from "./helpCenter/client/requests"; -export * from "./companies/client/requests"; -export * from "./contacts/client/requests"; -export * from "./notes/client/requests"; -export * from "./subscriptionTypes/client/requests"; -export * from "./tags/client/requests"; -export * from "./conversations/client/requests"; -export * from "./customChannelEvents/client/requests"; -export * from "./customObjectInstances/client/requests"; -export * from "./dataAttributes/client/requests"; -export * from "./dataEvents/client/requests"; -export * from "./dataExport/client/requests"; -export * from "./jobs/client/requests"; -export * from "./messages/client/requests"; -export * from "./news/client/requests"; -export * from "./segments/client/requests"; -export * from "./teams/client/requests"; -export * from "./ticketTypeAttributes/client/requests"; -export * from "./ticketTypes/client/requests"; -export * from "./tickets/client/requests"; -export * from "./visitors/client/requests"; +export * from "./admins/client/requests/index.js"; +export * as admins from "./admins/index.js"; +export * from "./admins/types/index.js"; +export * as aiAgent from "./aiAgent/index.js"; +export * from "./aiAgent/types/index.js"; +export * from "./aiContent/client/requests/index.js"; +export * as aiContent from "./aiContent/index.js"; +export * from "./aiContent/types/index.js"; +export * as aiContentSource from "./aiContentSource/index.js"; +export * from "./aiContentSource/types/index.js"; +export * from "./articles/client/requests/index.js"; +export * as articles from "./articles/index.js"; +export * from "./articles/types/index.js"; +export * as awayStatusReasons from "./awayStatusReasons/index.js"; +export * from "./brands/client/requests/index.js"; +export * as brands from "./brands/index.js"; +export * from "./brands/types/index.js"; +export * from "./calls/client/requests/index.js"; +export * as calls from "./calls/index.js"; +export * from "./calls/types/index.js"; +export * from "./companies/client/requests/index.js"; +export * as companies from "./companies/index.js"; +export * from "./companies/types/index.js"; +export * from "./contacts/client/requests/index.js"; +export * as contacts from "./contacts/index.js"; +export * from "./contacts/types/index.js"; +export * from "./conversations/client/requests/index.js"; +export * as conversations from "./conversations/index.js"; +export * from "./conversations/types/index.js"; +export * from "./customChannelEvents/client/requests/index.js"; +export * as customChannelEvents from "./customChannelEvents/index.js"; +export * from "./customObjectInstances/client/requests/index.js"; +export * as customObjectInstances from "./customObjectInstances/index.js"; +export * from "./customObjectInstances/types/index.js"; +export * from "./dataAttributes/client/requests/index.js"; +export * as dataAttributes from "./dataAttributes/index.js"; +export * from "./dataAttributes/types/index.js"; +export * from "./dataEvents/client/requests/index.js"; +export * as dataEvents from "./dataEvents/index.js"; +export * from "./dataEvents/types/index.js"; +export * from "./dataExport/client/requests/index.js"; +export * as dataExport from "./dataExport/index.js"; +export * from "./dataExport/types/index.js"; +export * from "./emails/client/requests/index.js"; +export * as emails from "./emails/index.js"; +export * from "./emails/types/index.js"; +export * from "./export/client/requests/index.js"; +export * as export_ from "./export/index.js"; +export * from "./export/types/index.js"; +export * from "./helpCenter/client/requests/index.js"; +export * as helpCenter from "./helpCenter/index.js"; +export * from "./helpCenter/types/index.js"; +export * from "./internalArticles/client/requests/index.js"; +export * as internalArticles from "./internalArticles/index.js"; +export * from "./internalArticles/types/index.js"; +export * from "./jobs/client/requests/index.js"; +export * as jobs from "./jobs/index.js"; +export * from "./jobs/types/index.js"; +export * from "./macros/client/requests/index.js"; +export * as macros from "./macros/index.js"; +export * from "./macros/types/index.js"; +export * from "./messages/client/requests/index.js"; +export * as messages from "./messages/index.js"; +export * from "./messages/types/index.js"; +export * from "./news/client/requests/index.js"; +export * as news from "./news/index.js"; +export * from "./news/types/index.js"; +export * from "./notes/client/requests/index.js"; +export * as notes from "./notes/index.js"; +export * from "./notes/types/index.js"; +export * from "./segments/client/requests/index.js"; +export * as segments from "./segments/index.js"; +export * from "./segments/types/index.js"; +export * from "./subscriptionTypes/client/requests/index.js"; +export * as subscriptionTypes from "./subscriptionTypes/index.js"; +export * from "./subscriptionTypes/types/index.js"; +export * as switch_ from "./switch/index.js"; +export * from "./tags/client/requests/index.js"; +export * as tags from "./tags/index.js"; +export * from "./tags/types/index.js"; +export * from "./teams/client/requests/index.js"; +export * as teams from "./teams/index.js"; +export * from "./teams/types/index.js"; +export * as ticketStates from "./ticketStates/index.js"; +export * from "./tickets/client/requests/index.js"; +export * as tickets from "./tickets/index.js"; +export * from "./tickets/types/index.js"; +export * from "./ticketTypeAttributes/client/requests/index.js"; +export * as ticketTypeAttributes from "./ticketTypeAttributes/index.js"; +export * from "./ticketTypes/client/requests/index.js"; +export * as ticketTypes from "./ticketTypes/index.js"; +export * from "./visitors/client/requests/index.js"; +export * as visitors from "./visitors/index.js"; diff --git a/src/api/resources/unstable/resources/internalArticles/client/Client.ts b/src/api/resources/unstable/resources/internalArticles/client/Client.ts new file mode 100644 index 00000000..bcfe5c32 --- /dev/null +++ b/src/api/resources/unstable/resources/internalArticles/client/Client.ts @@ -0,0 +1,491 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; + +export declare namespace InternalArticlesClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * Everything about your Internal Articles + */ +export class InternalArticlesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: InternalArticlesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * You can fetch a list of all internal articles by making a GET request to `https://api.intercom.io/internal_articles`. + * + * @param {InternalArticlesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.internalArticles.listInternalArticles() + */ + public listInternalArticles( + requestOptions?: InternalArticlesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listInternalArticles(requestOptions)); + } + + private async __listInternalArticles( + requestOptions?: InternalArticlesClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "internal_articles", + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.InternalArticleList, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/internal_articles"); + } + + /** + * You can create a new internal article by making a POST request to `https://api.intercom.io/internal_articles`. + * + * @param {Intercom.unstable.CreateInternalArticleRequest} request + * @param {InternalArticlesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.internalArticles.createInternalArticle({ + * title: "Thanks for everything", + * body: "Body of the Article", + * author_id: 991266252, + * owner_id: 991266252 + * }) + * + * @example + * await client.unstable.internalArticles.createInternalArticle({ + * title: "Thanks for everything", + * body: "Body of the Internal Article", + * author_id: 1295, + * owner_id: 1295 + * }) + */ + public createInternalArticle( + request?: Intercom.unstable.CreateInternalArticleRequest, + requestOptions?: InternalArticlesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__createInternalArticle(request, requestOptions)); + } + + private async __createInternalArticle( + request?: Intercom.unstable.CreateInternalArticleRequest, + requestOptions?: InternalArticlesClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "internal_articles", + ), + method: "POST", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: request != null ? request : undefined, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.InternalArticle, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/internal_articles"); + } + + /** + * You can fetch the details of a single internal article by making a GET request to `https://api.intercom.io/internal_articles/`. + * + * @param {Intercom.unstable.RetrieveInternalArticleRequest} request + * @param {InternalArticlesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.internalArticles.retrieveInternalArticle({ + * id: 1 + * }) + */ + public retrieveInternalArticle( + request: Intercom.unstable.RetrieveInternalArticleRequest, + requestOptions?: InternalArticlesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__retrieveInternalArticle(request, requestOptions)); + } + + private async __retrieveInternalArticle( + request: Intercom.unstable.RetrieveInternalArticleRequest, + requestOptions?: InternalArticlesClient.RequestOptions, + ): Promise> { + const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `internal_articles/${core.url.encodePathParam(id)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.InternalArticle, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/internal_articles/{id}"); + } + + /** + * You can update the details of a single internal article by making a PUT request to `https://api.intercom.io/internal_articles/`. + * + * @param {Intercom.unstable.UpdateInternalArticleRequestBody} request + * @param {InternalArticlesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.internalArticles.updateInternalArticle({ + * id: 1, + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

" + * }) + */ + public updateInternalArticle( + request: Intercom.unstable.UpdateInternalArticleRequestBody, + requestOptions?: InternalArticlesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateInternalArticle(request, requestOptions)); + } + + private async __updateInternalArticle( + request: Intercom.unstable.UpdateInternalArticleRequestBody, + requestOptions?: InternalArticlesClient.RequestOptions, + ): Promise> { + const { id, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `internal_articles/${core.url.encodePathParam(id)}`, + ), + method: "PUT", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: _body, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.InternalArticle, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/internal_articles/{id}"); + } + + /** + * You can delete a single internal article by making a DELETE request to `https://api.intercom.io/internal_articles/`. + * + * @param {Intercom.unstable.DeleteInternalArticleRequest} request + * @param {InternalArticlesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.internalArticles.deleteInternalArticle({ + * id: 1 + * }) + */ + public deleteInternalArticle( + request: Intercom.unstable.DeleteInternalArticleRequest, + requestOptions?: InternalArticlesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__deleteInternalArticle(request, requestOptions)); + } + + private async __deleteInternalArticle( + request: Intercom.unstable.DeleteInternalArticleRequest, + requestOptions?: InternalArticlesClient.RequestOptions, + ): Promise> { + const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `internal_articles/${core.url.encodePathParam(id)}`, + ), + method: "DELETE", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.DeletedInternalArticleObject, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/internal_articles/{id}"); + } + + /** + * You can search for internal articles by making a GET request to `https://api.intercom.io/internal_articles/search`. + * + * @param {Intercom.unstable.SearchInternalArticlesRequest} request + * @param {InternalArticlesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * + * @example + * await client.unstable.internalArticles.searchInternalArticles({ + * folder_id: "folder_id" + * }) + */ + public searchInternalArticles( + request: Intercom.unstable.SearchInternalArticlesRequest = {}, + requestOptions?: InternalArticlesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__searchInternalArticles(request, requestOptions)); + } + + private async __searchInternalArticles( + request: Intercom.unstable.SearchInternalArticlesRequest = {}, + requestOptions?: InternalArticlesClient.RequestOptions, + ): Promise> { + const { folder_id: folderId } = request; + const _queryParams: Record = {}; + if (folderId != null) { + _queryParams.folder_id = folderId; + } + + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "internal_articles/search", + ), + method: "GET", + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { + data: _response.body as Intercom.unstable.InternalArticleSearchResponse, + rawResponse: _response.rawResponse, + }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/internal_articles/search"); + } +} diff --git a/src/api/resources/unstable/resources/internalArticles/client/index.ts b/src/api/resources/unstable/resources/internalArticles/client/index.ts new file mode 100644 index 00000000..195f9aa8 --- /dev/null +++ b/src/api/resources/unstable/resources/internalArticles/client/index.ts @@ -0,0 +1 @@ +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/internalArticles/client/requests/DeleteInternalArticleRequest.ts b/src/api/resources/unstable/resources/internalArticles/client/requests/DeleteInternalArticleRequest.ts new file mode 100644 index 00000000..dd3f7586 --- /dev/null +++ b/src/api/resources/unstable/resources/internalArticles/client/requests/DeleteInternalArticleRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * id: 1 + * } + */ +export interface DeleteInternalArticleRequest { + /** The unique identifier for the internal article which is given by Intercom. */ + id: number; +} diff --git a/src/api/resources/unstable/resources/internalArticles/client/requests/RetrieveInternalArticleRequest.ts b/src/api/resources/unstable/resources/internalArticles/client/requests/RetrieveInternalArticleRequest.ts new file mode 100644 index 00000000..bf5d0ece --- /dev/null +++ b/src/api/resources/unstable/resources/internalArticles/client/requests/RetrieveInternalArticleRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * id: 1 + * } + */ +export interface RetrieveInternalArticleRequest { + /** The unique identifier for the article which is given by Intercom. */ + id: number; +} diff --git a/src/api/resources/unstable/resources/internalArticles/client/requests/SearchInternalArticlesRequest.ts b/src/api/resources/unstable/resources/internalArticles/client/requests/SearchInternalArticlesRequest.ts new file mode 100644 index 00000000..6f80cf05 --- /dev/null +++ b/src/api/resources/unstable/resources/internalArticles/client/requests/SearchInternalArticlesRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * folder_id: "folder_id" + * } + */ +export interface SearchInternalArticlesRequest { + /** The ID of the folder to search in. */ + folder_id?: string; +} diff --git a/src/api/resources/unstable/resources/internalArticles/client/requests/UpdateInternalArticleRequestBody.ts b/src/api/resources/unstable/resources/internalArticles/client/requests/UpdateInternalArticleRequestBody.ts new file mode 100644 index 00000000..ffd0c32d --- /dev/null +++ b/src/api/resources/unstable/resources/internalArticles/client/requests/UpdateInternalArticleRequestBody.ts @@ -0,0 +1,29 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * id: 1, + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

" + * } + * + * @example + * { + * id: 1, + * title: "Christmas is here!", + * body: "

New gifts in store for the jolly season

" + * } + */ +export interface UpdateInternalArticleRequestBody { + /** The unique identifier for the internal article which is given by Intercom. */ + id: number; + /** The title of the article. */ + title?: string; + /** The content of the article. */ + body?: string; + /** The id of the author of the article. */ + author_id?: number; + /** The id of the author of the article. */ + owner_id?: number; +} diff --git a/src/api/resources/unstable/resources/internalArticles/client/requests/index.ts b/src/api/resources/unstable/resources/internalArticles/client/requests/index.ts new file mode 100644 index 00000000..677bd9fa --- /dev/null +++ b/src/api/resources/unstable/resources/internalArticles/client/requests/index.ts @@ -0,0 +1,4 @@ +export type { DeleteInternalArticleRequest } from "./DeleteInternalArticleRequest.js"; +export type { RetrieveInternalArticleRequest } from "./RetrieveInternalArticleRequest.js"; +export type { SearchInternalArticlesRequest } from "./SearchInternalArticlesRequest.js"; +export type { UpdateInternalArticleRequestBody } from "./UpdateInternalArticleRequestBody.js"; diff --git a/src/api/resources/unstable/resources/internalArticles/index.ts b/src/api/resources/unstable/resources/internalArticles/index.ts new file mode 100644 index 00000000..d9adb1af --- /dev/null +++ b/src/api/resources/unstable/resources/internalArticles/index.ts @@ -0,0 +1,2 @@ +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/internalArticles/types/InternalArticleListItem.ts b/src/api/resources/unstable/resources/internalArticles/types/InternalArticleListItem.ts new file mode 100644 index 00000000..b906ff6f --- /dev/null +++ b/src/api/resources/unstable/resources/internalArticles/types/InternalArticleListItem.ts @@ -0,0 +1,25 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * The data returned about your internal articles when you list them. + */ +export interface InternalArticleListItem { + /** The type of object - `internal_article`. */ + type?: "internal_article"; + /** The unique identifier for the article which is given by Intercom. */ + id?: string; + /** The title of the article. */ + title?: string; + /** The body of the article in HTML. */ + body?: string; + /** The id of the owner of the article. */ + owner_id?: number; + /** The id of the author of the article. */ + author_id?: number; + /** The time when the article was created. */ + created_at?: number; + /** The time when the article was last updated. */ + updated_at?: number; + /** The default locale of the article. */ + locale?: string; +} diff --git a/src/api/resources/unstable/resources/internalArticles/types/InternalArticleSearchResponse.ts b/src/api/resources/unstable/resources/internalArticles/types/InternalArticleSearchResponse.ts new file mode 100644 index 00000000..b7790005 --- /dev/null +++ b/src/api/resources/unstable/resources/internalArticles/types/InternalArticleSearchResponse.ts @@ -0,0 +1,26 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../../index.js"; + +/** + * The results of an Internal Article search + */ +export interface InternalArticleSearchResponse { + /** The type of the object - `list`. */ + type?: "list"; + /** The total number of Internal Articles matching the search query */ + total_count?: number; + /** An object containing the results of the search. */ + data?: InternalArticleSearchResponse.Data; + pages?: Intercom.unstable.CursorPages; +} + +export namespace InternalArticleSearchResponse { + /** + * An object containing the results of the search. + */ + export interface Data { + /** An array of Internal Article objects */ + internal_articles?: Intercom.unstable.InternalArticle[]; + } +} diff --git a/src/api/resources/unstable/resources/internalArticles/types/index.ts b/src/api/resources/unstable/resources/internalArticles/types/index.ts new file mode 100644 index 00000000..aedeb96e --- /dev/null +++ b/src/api/resources/unstable/resources/internalArticles/types/index.ts @@ -0,0 +1,2 @@ +export * from "./InternalArticleListItem.js"; +export * from "./InternalArticleSearchResponse.js"; diff --git a/src/api/resources/unstable/resources/jobs/client/Client.ts b/src/api/resources/unstable/resources/jobs/client/Client.ts index 3c114bdf..232af1bd 100644 --- a/src/api/resources/unstable/resources/jobs/client/Client.ts +++ b/src/api/resources/unstable/resources/jobs/client/Client.ts @@ -1,85 +1,35 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Jobs { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace JobsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about jobs */ -export class Jobs { - constructor(protected readonly _options: Jobs.Options = {}) {} +export class JobsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: JobsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * Retrieve the status of job execution. * * @param {Intercom.unstable.JobsStatusRequest} request - * @param {Jobs.RequestOptions} requestOptions - Request-specific configuration. + * @param {JobsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -91,40 +41,38 @@ export class Jobs { */ public status( request: Intercom.unstable.JobsStatusRequest, - requestOptions?: Jobs.RequestOptions, + requestOptions?: JobsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__status(request, requestOptions)); } private async __status( request: Intercom.unstable.JobsStatusRequest, - requestOptions?: Jobs.RequestOptions, + requestOptions?: JobsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `jobs/status/${encodeURIComponent(id)}`, + `jobs/status/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Jobs, rawResponse: _response.rawResponse }; @@ -148,32 +96,6 @@ export class Jobs { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /jobs/status/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/jobs/status/{id}"); } } diff --git a/src/api/resources/unstable/resources/jobs/client/index.ts b/src/api/resources/unstable/resources/jobs/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/jobs/client/index.ts +++ b/src/api/resources/unstable/resources/jobs/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/jobs/client/requests/JobsStatusRequest.ts b/src/api/resources/unstable/resources/jobs/client/requests/JobsStatusRequest.ts index 861e1c7d..80f53a81 100644 --- a/src/api/resources/unstable/resources/jobs/client/requests/JobsStatusRequest.ts +++ b/src/api/resources/unstable/resources/jobs/client/requests/JobsStatusRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface JobsStatusRequest { - /** - * The unique identifier for the job which is given by Intercom - */ + /** The unique identifier for the job which is given by Intercom */ id: string; } diff --git a/src/api/resources/unstable/resources/jobs/client/requests/index.ts b/src/api/resources/unstable/resources/jobs/client/requests/index.ts index 0d9f97d0..bfed16f9 100644 --- a/src/api/resources/unstable/resources/jobs/client/requests/index.ts +++ b/src/api/resources/unstable/resources/jobs/client/requests/index.ts @@ -1 +1 @@ -export { type JobsStatusRequest } from "./JobsStatusRequest"; +export type { JobsStatusRequest } from "./JobsStatusRequest.js"; diff --git a/src/api/resources/unstable/resources/jobs/index.ts b/src/api/resources/unstable/resources/jobs/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/jobs/index.ts +++ b/src/api/resources/unstable/resources/jobs/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/jobs/types/Jobs.ts b/src/api/resources/unstable/resources/jobs/types/Jobs.ts index e2192f11..c3e63585 100644 --- a/src/api/resources/unstable/resources/jobs/types/Jobs.ts +++ b/src/api/resources/unstable/resources/jobs/types/Jobs.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Jobs are tasks that are processed asynchronously by the Intercom system after being enqueued via the API. This allows for efficient handling of operations that may take time to complete, such as data imports or exports. You can check the status of your jobs to monitor their progress and ensure they are completed successfully. @@ -23,13 +21,11 @@ export interface Jobs { } export namespace Jobs { - /** - * The status of the job execution. - */ - export type Status = "pending" | "success" | "failed"; + /** The status of the job execution. */ export const Status = { Pending: "pending", Success: "success", Failed: "failed", } as const; + export type Status = (typeof Status)[keyof typeof Status]; } diff --git a/src/api/resources/unstable/resources/jobs/types/index.ts b/src/api/resources/unstable/resources/jobs/types/index.ts index c46ba3db..c4ca9992 100644 --- a/src/api/resources/unstable/resources/jobs/types/index.ts +++ b/src/api/resources/unstable/resources/jobs/types/index.ts @@ -1 +1 @@ -export * from "./Jobs"; +export * from "./Jobs.js"; diff --git a/src/api/resources/unstable/resources/macros/client/Client.ts b/src/api/resources/unstable/resources/macros/client/Client.ts new file mode 100644 index 00000000..60a0a207 --- /dev/null +++ b/src/api/resources/unstable/resources/macros/client/Client.ts @@ -0,0 +1,230 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; + +export declare namespace MacrosClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * Operations related to saved replies (macros) in conversations + */ +export class MacrosClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: MacrosClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * You can fetch a list of all macros (saved replies) in your workspace for use in automating responses. + * + * The macros are returned in descending order by updated_at. + * + * **Pagination** + * + * This endpoint uses cursor-based pagination via the `starting_after` parameter. The cursor is a Base64-encoded JSON array containing `[updated_at, id]` of the last item from the previous page. + * + * **Placeholder Transformation** + * + * The API transforms Intercom placeholders to a more standard XML-like format: + * - From: `{{user.name | fallback: 'there'}}` + * - To: `` + * + * @param {Intercom.unstable.ListMacrosRequest} request + * @param {MacrosClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.BadRequestError} + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.ForbiddenError} + * + * @example + * await client.unstable.macros.listMacros({ + * per_page: 1, + * starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + * updated_since: 1000000 + * }) + */ + public listMacros( + request: Intercom.unstable.ListMacrosRequest = {}, + requestOptions?: MacrosClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listMacros(request, requestOptions)); + } + + private async __listMacros( + request: Intercom.unstable.ListMacrosRequest = {}, + requestOptions?: MacrosClient.RequestOptions, + ): Promise> { + const { per_page: perPage, starting_after: startingAfter, updated_since: updatedSince } = request; + const _queryParams: Record = {}; + if (perPage != null) { + _queryParams.per_page = perPage.toString(); + } + + if (startingAfter != null) { + _queryParams.starting_after = startingAfter; + } + + if (updatedSince != null) { + _queryParams.updated_since = updatedSince.toString(); + } + + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "macros", + ), + method: "GET", + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.MacroList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 400: + throw new Intercom.unstable.BadRequestError(_response.error.body as unknown, _response.rawResponse); + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.unstable.ForbiddenError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/macros"); + } + + /** + * You can fetch a single macro (saved reply) by its ID. The macro will only be returned if it is visible to the authenticated user based on its visibility settings. + * + * **Visibility Rules** + * + * A macro is returned based on its `visible_to` setting: + * - `everyone`: Always visible to all team members + * - `specific_teams`: Only visible if the authenticated user belongs to one of the teams specified in `visible_to_team_ids` + * + * If a macro exists but is not visible to the authenticated user, a 404 error is returned. + * + * **Placeholder Transformation** + * + * The API transforms Intercom placeholders to a more standard XML-like format in the `body` field: + * - From: `{{user.name | fallback: 'there'}}` + * - To: `` + * + * Default values in placeholders are HTML-escaped for security. + * + * @param {Intercom.unstable.GetMacroRequest} request + * @param {MacrosClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.ForbiddenError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.macros.getMacro({ + * id: "123" + * }) + */ + public getMacro( + request: Intercom.unstable.GetMacroRequest, + requestOptions?: MacrosClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__getMacro(request, requestOptions)); + } + + private async __getMacro( + request: Intercom.unstable.GetMacroRequest, + requestOptions?: MacrosClient.RequestOptions, + ): Promise> { + const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `macros/${core.url.encodePathParam(id)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.Macro | undefined, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 403: + throw new Intercom.unstable.ForbiddenError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/macros/{id}"); + } +} diff --git a/src/api/resources/unstable/resources/macros/client/index.ts b/src/api/resources/unstable/resources/macros/client/index.ts new file mode 100644 index 00000000..195f9aa8 --- /dev/null +++ b/src/api/resources/unstable/resources/macros/client/index.ts @@ -0,0 +1 @@ +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/macros/client/requests/GetMacroRequest.ts b/src/api/resources/unstable/resources/macros/client/requests/GetMacroRequest.ts new file mode 100644 index 00000000..a90a0866 --- /dev/null +++ b/src/api/resources/unstable/resources/macros/client/requests/GetMacroRequest.ts @@ -0,0 +1,27 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * id: "123" + * } + * + * @example + * { + * id: "123" + * } + * + * @example + * { + * id: "123" + * } + * + * @example + * { + * id: "123" + * } + */ +export interface GetMacroRequest { + /** The unique identifier of the macro */ + id: string; +} diff --git a/src/api/resources/unstable/resources/macros/client/requests/ListMacrosRequest.ts b/src/api/resources/unstable/resources/macros/client/requests/ListMacrosRequest.ts new file mode 100644 index 00000000..caf7ed0d --- /dev/null +++ b/src/api/resources/unstable/resources/macros/client/requests/ListMacrosRequest.ts @@ -0,0 +1,53 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * per_page: 1, + * starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + * updated_since: 1000000 + * } + * + * @example + * { + * per_page: 1, + * starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + * updated_since: 1000000 + * } + * + * @example + * { + * per_page: 1, + * starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + * updated_since: 1000000 + * } + * + * @example + * { + * per_page: 1, + * starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + * updated_since: 1000000 + * } + * + * @example + * { + * per_page: 1, + * starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + * updated_since: 1000000 + * } + * + * @example + * { + * per_page: 1, + * starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + * updated_since: 1000000 + * } + */ +export interface ListMacrosRequest { + /** The number of results per page */ + per_page?: number; + /** Base64-encoded cursor containing [updated_at, id] for pagination */ + starting_after?: string; + /** Unix timestamp to filter macros updated after this time */ + updated_since?: number; +} diff --git a/src/api/resources/unstable/resources/macros/client/requests/index.ts b/src/api/resources/unstable/resources/macros/client/requests/index.ts new file mode 100644 index 00000000..10c97f9d --- /dev/null +++ b/src/api/resources/unstable/resources/macros/client/requests/index.ts @@ -0,0 +1,2 @@ +export type { GetMacroRequest } from "./GetMacroRequest.js"; +export type { ListMacrosRequest } from "./ListMacrosRequest.js"; diff --git a/src/api/resources/unstable/resources/macros/index.ts b/src/api/resources/unstable/resources/macros/index.ts new file mode 100644 index 00000000..d9adb1af --- /dev/null +++ b/src/api/resources/unstable/resources/macros/index.ts @@ -0,0 +1,2 @@ +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/macros/types/Macro.ts b/src/api/resources/unstable/resources/macros/types/Macro.ts new file mode 100644 index 00000000..b7941f1a --- /dev/null +++ b/src/api/resources/unstable/resources/macros/types/Macro.ts @@ -0,0 +1,45 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * A macro is a pre-defined response template (saved reply) that can be used to quickly reply to conversations. + */ +export interface Macro { + /** String representing the object's type. Always has the value `macro`. */ + type?: "macro"; + /** The unique identifier for the macro. */ + id?: string; + /** The name of the macro. */ + name?: string; + /** The body of the macro in HTML format with placeholders transformed to XML-like format. */ + body?: string; + /** The plain text version of the macro body with original Intercom placeholder format. */ + body_text?: string; + /** The time the macro was created in ISO 8601 format. */ + created_at?: string; + /** The time the macro was last updated in ISO 8601 format. */ + updated_at?: string; + /** Who can view this macro. */ + visible_to?: Macro.VisibleTo; + /** The team IDs that can view this macro when visible_to is set to specific_teams. */ + visible_to_team_ids?: string[]; + /** Where the macro is available for use. */ + available_on?: Macro.AvailableOn.Item[]; +} + +export namespace Macro { + /** Who can view this macro. */ + export const VisibleTo = { + Everyone: "everyone", + SpecificTeams: "specific_teams", + } as const; + export type VisibleTo = (typeof VisibleTo)[keyof typeof VisibleTo]; + export type AvailableOn = AvailableOn.Item[]; + + export namespace AvailableOn { + export const Item = { + Inbox: "inbox", + Messenger: "messenger", + } as const; + export type Item = (typeof Item)[keyof typeof Item]; + } +} diff --git a/src/api/resources/unstable/resources/macros/types/MacroList.ts b/src/api/resources/unstable/resources/macros/types/MacroList.ts new file mode 100644 index 00000000..0694b02f --- /dev/null +++ b/src/api/resources/unstable/resources/macros/types/MacroList.ts @@ -0,0 +1,39 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../../index.js"; + +/** + * A paginated list of macros (saved replies) in the workspace. + */ +export interface MacroList { + /** Always list */ + type?: "list"; + /** The list of macro objects */ + data?: (Intercom.unstable.Macro | undefined)[]; + /** Pagination information */ + pages?: MacroList.Pages; +} + +export namespace MacroList { + /** + * Pagination information + */ + export interface Pages { + /** The type of pagination */ + type?: "pages"; + /** Number of results per page */ + per_page?: number; + /** Cursor for the next page */ + next?: Pages.Next; + } + + export namespace Pages { + /** + * Cursor for the next page + */ + export interface Next { + /** Base64-encoded cursor containing [updated_at, id] for pagination */ + starting_after?: string; + } + } +} diff --git a/src/api/resources/unstable/resources/macros/types/index.ts b/src/api/resources/unstable/resources/macros/types/index.ts new file mode 100644 index 00000000..46516f7b --- /dev/null +++ b/src/api/resources/unstable/resources/macros/types/index.ts @@ -0,0 +1,2 @@ +export * from "./Macro.js"; +export * from "./MacroList.js"; diff --git a/src/api/resources/unstable/resources/messages/client/Client.ts b/src/api/resources/unstable/resources/messages/client/Client.ts index e49625bc..95d1513f 100644 --- a/src/api/resources/unstable/resources/messages/client/Client.ts +++ b/src/api/resources/unstable/resources/messages/client/Client.ts @@ -1,82 +1,32 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Messages { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace MessagesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your messages */ -export class Messages { - constructor(protected readonly _options: Messages.Options = {}) {} +export class MessagesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: MessagesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** - * You can create a message that has been initiated by an admin. The conversation can be either an in-app message, an email or sms. + * You can create a message that has been initiated by an admin. The conversation can be either an in-app message, an email, sms or whatsapp. * * > 🚧 Sending for visitors * > @@ -88,8 +38,8 @@ export class Messages { * > * > As this is a message, there will be no conversation present until the contact responds. Once they do, you will have to search for a contact's conversations with the id of the message. * - * @param {Intercom.CreateMessageRequestTwo} request - * @param {Messages.RequestOptions} requestOptions - Request-specific configuration. + * @param {Intercom.unstable.CreateMessageRequest | undefined} request + * @param {MessagesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -174,6 +124,32 @@ export class Messages { * await client.unstable.messages.createMessage({ * "from": { * "type": "admin", + * "id": "991267817" + * }, + * "to": { + * "phone": 5547999998888, + * "name": "John Doe" + * }, + * "message_type": "whatsapp", + * "components": [ + * { + * "type": "BODY", + * "parameters": [ + * { + * "type": "text", + * "text": "Username 123" + * } + * ] + * } + * ], + * "template": "keep_live", + * "locale": "en" + * }) + * + * @example + * await client.unstable.messages.createMessage({ + * "from": { + * "type": "admin", * "id": "991267818" * }, * "to": { @@ -227,41 +203,41 @@ export class Messages { * }) */ public createMessage( - request?: Intercom.CreateMessageRequestTwo, - requestOptions?: Messages.RequestOptions, + request?: Intercom.unstable.CreateMessageRequest | undefined, + requestOptions?: MessagesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createMessage(request, requestOptions)); } private async __createMessage( - request?: Intercom.CreateMessageRequestTwo, - requestOptions?: Messages.RequestOptions, + request?: Intercom.unstable.CreateMessageRequest | undefined, + requestOptions?: MessagesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "messages", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", - body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + body: request != null ? request : undefined, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Message, rawResponse: _response.rawResponse }; @@ -295,21 +271,7 @@ export class Messages { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /messages."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/messages"); } /** @@ -320,7 +282,7 @@ export class Messages { * information about delivery state and related message details. * * @param {Intercom.unstable.GetWhatsAppMessageStatusRequest} request - * @param {Messages.RequestOptions} requestOptions - Request-specific configuration. + * @param {MessagesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -329,56 +291,55 @@ export class Messages { * * @example * await client.unstable.messages.getWhatsAppMessageStatus({ - * ruleset_id: "ruleset_id" + * ruleset_id: "ruleset_id", + * per_page: 1, + * starting_after: "starting_after" * }) */ public getWhatsAppMessageStatus( request: Intercom.unstable.GetWhatsAppMessageStatusRequest, - requestOptions?: Messages.RequestOptions, + requestOptions?: MessagesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__getWhatsAppMessageStatus(request, requestOptions)); } private async __getWhatsAppMessageStatus( request: Intercom.unstable.GetWhatsAppMessageStatusRequest, - requestOptions?: Messages.RequestOptions, + requestOptions?: MessagesClient.RequestOptions, ): Promise> { const { ruleset_id: rulesetId, per_page: perPage, starting_after: startingAfter } = request; const _queryParams: Record = {}; - _queryParams["ruleset_id"] = rulesetId; + _queryParams.ruleset_id = rulesetId; if (perPage != null) { - _queryParams["per_page"] = perPage.toString(); + _queryParams.per_page = perPage.toString(); } if (startingAfter != null) { - _queryParams["starting_after"] = startingAfter; + _queryParams.starting_after = startingAfter; } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "messages/status", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -415,32 +376,6 @@ export class Messages { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /messages/status."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/messages/status"); } } diff --git a/src/api/resources/unstable/resources/messages/client/index.ts b/src/api/resources/unstable/resources/messages/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/messages/client/index.ts +++ b/src/api/resources/unstable/resources/messages/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/messages/client/requests/GetWhatsAppMessageStatusRequest.ts b/src/api/resources/unstable/resources/messages/client/requests/GetWhatsAppMessageStatusRequest.ts index 9f14d703..4857f1ff 100644 --- a/src/api/resources/unstable/resources/messages/client/requests/GetWhatsAppMessageStatusRequest.ts +++ b/src/api/resources/unstable/resources/messages/client/requests/GetWhatsAppMessageStatusRequest.ts @@ -1,24 +1,18 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example * { - * ruleset_id: "ruleset_id" + * ruleset_id: "ruleset_id", + * per_page: 1, + * starting_after: "starting_after" * } */ export interface GetWhatsAppMessageStatusRequest { - /** - * The unique identifier for the set of messages to check status for - */ + /** The unique identifier for the set of messages to check status for */ ruleset_id: string; - /** - * Number of results per page (default 50, max 100) - */ + /** Number of results per page (default 50, max 100) */ per_page?: number; - /** - * Cursor for pagination, used to fetch the next page of results - */ + /** Cursor for pagination, used to fetch the next page of results */ starting_after?: string; } diff --git a/src/api/resources/unstable/resources/messages/client/requests/index.ts b/src/api/resources/unstable/resources/messages/client/requests/index.ts index 73c16159..3571c87e 100644 --- a/src/api/resources/unstable/resources/messages/client/requests/index.ts +++ b/src/api/resources/unstable/resources/messages/client/requests/index.ts @@ -1 +1 @@ -export { type GetWhatsAppMessageStatusRequest } from "./GetWhatsAppMessageStatusRequest"; +export type { GetWhatsAppMessageStatusRequest } from "./GetWhatsAppMessageStatusRequest.js"; diff --git a/src/api/resources/unstable/resources/messages/index.ts b/src/api/resources/unstable/resources/messages/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/messages/index.ts +++ b/src/api/resources/unstable/resources/messages/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/messages/types/Message.ts b/src/api/resources/unstable/resources/messages/types/Message.ts index 35585c59..14710453 100644 --- a/src/api/resources/unstable/resources/messages/types/Message.ts +++ b/src/api/resources/unstable/resources/messages/types/Message.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Message are how you reach out to contacts in Intercom. They are created when an admin sends an outbound message to a contact. @@ -16,22 +14,21 @@ export interface Message { subject?: string; /** The message body, which may contain HTML. */ body: string; - /** The type of message that was sent. Can be email, inapp, facebook ,twitter or sms. */ + /** The type of message that was sent. Can be email, inapp, facebook, twitter, sms or whatsapp. */ message_type: Message.MessageType; /** The associated conversation_id */ conversation_id?: string; } export namespace Message { - /** - * The type of message that was sent. Can be email, inapp, facebook ,twitter or sms. - */ - export type MessageType = "email" | "inapp" | "facebook" | "twitter" | "sms"; + /** The type of message that was sent. Can be email, inapp, facebook, twitter, sms or whatsapp. */ export const MessageType = { Email: "email", Inapp: "inapp", Facebook: "facebook", Twitter: "twitter", Sms: "sms", + Whatsapp: "whatsapp", } as const; + export type MessageType = (typeof MessageType)[keyof typeof MessageType]; } diff --git a/src/api/resources/unstable/resources/messages/types/index.ts b/src/api/resources/unstable/resources/messages/types/index.ts index 6596816a..e16d36b7 100644 --- a/src/api/resources/unstable/resources/messages/types/index.ts +++ b/src/api/resources/unstable/resources/messages/types/index.ts @@ -1 +1 @@ -export * from "./Message"; +export * from "./Message.js"; diff --git a/src/api/resources/unstable/resources/news/client/Client.ts b/src/api/resources/unstable/resources/news/client/Client.ts index f42e1729..a0463196 100644 --- a/src/api/resources/unstable/resources/news/client/Client.ts +++ b/src/api/resources/unstable/resources/news/client/Client.ts @@ -1,84 +1,34 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; - -export declare namespace News { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } +export declare namespace NewsClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your News */ -export class News { - constructor(protected readonly _options: News.Options = {}) {} +export class NewsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: NewsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of all news items * - * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * @param {NewsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -86,38 +36,36 @@ export class News { * await client.unstable.news.listNewsItems() */ public listNewsItems( - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listNewsItems(requestOptions)); } private async __listNewsItems( - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "news/news_items", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.PaginatedResponse, rawResponse: _response.rawResponse }; @@ -139,28 +87,14 @@ export class News { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/news_items."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/news/news_items"); } /** * You can create a news item * * @param {Intercom.unstable.NewsItemRequest} request - * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * @param {NewsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -181,40 +115,40 @@ export class News { */ public createNewsItem( request: Intercom.unstable.NewsItemRequest, - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createNewsItem(request, requestOptions)); } private async __createNewsItem( request: Intercom.unstable.NewsItemRequest, - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "news/news_items", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.NewsItem, rawResponse: _response.rawResponse }; @@ -236,28 +170,14 @@ export class News { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /news/news_items."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/news/news_items"); } /** * You can fetch the details of a single news item. * * @param {Intercom.unstable.RetrieveNewsItemRequest} request - * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * @param {NewsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -269,40 +189,38 @@ export class News { */ public retrieveNewsItem( request: Intercom.unstable.RetrieveNewsItemRequest, - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__retrieveNewsItem(request, requestOptions)); } private async __retrieveNewsItem( request: Intercom.unstable.RetrieveNewsItemRequest, - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/news_items/${encodeURIComponent(id)}`, + `news/news_items/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.NewsItem, rawResponse: _response.rawResponse }; @@ -326,26 +244,12 @@ export class News { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/news_items/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/news/news_items/{id}"); } /** * @param {Intercom.unstable.UpdateNewsItemRequest} request - * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * @param {NewsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -374,41 +278,41 @@ export class News { */ public updateNewsItem( request: Intercom.unstable.UpdateNewsItemRequest, - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__updateNewsItem(request, requestOptions)); } private async __updateNewsItem( request: Intercom.unstable.UpdateNewsItemRequest, - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): Promise> { const { id, body: _body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/news_items/${encodeURIComponent(id)}`, + `news/news_items/${core.url.encodePathParam(id)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.NewsItem, rawResponse: _response.rawResponse }; @@ -432,28 +336,14 @@ export class News { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /news/news_items/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/news/news_items/{id}"); } /** * You can delete a single news item. * * @param {Intercom.unstable.DeleteNewsItemRequest} request - * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * @param {NewsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -465,40 +355,38 @@ export class News { */ public deleteNewsItem( request: Intercom.unstable.DeleteNewsItemRequest, - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__deleteNewsItem(request, requestOptions)); } private async __deleteNewsItem( request: Intercom.unstable.DeleteNewsItemRequest, - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/news_items/${encodeURIComponent(id)}`, + `news/news_items/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.DeletedObject, rawResponse: _response.rawResponse }; @@ -522,28 +410,14 @@ export class News { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /news/news_items/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/news/news_items/{id}"); } /** * You can fetch a list of all news items that are live on a given newsfeed * * @param {Intercom.unstable.ListLiveNewsfeedItemsRequest} request - * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * @param {NewsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -554,40 +428,38 @@ export class News { */ public listLiveNewsfeedItems( request: Intercom.unstable.ListLiveNewsfeedItemsRequest, - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listLiveNewsfeedItems(request, requestOptions)); } private async __listLiveNewsfeedItems( request: Intercom.unstable.ListLiveNewsfeedItemsRequest, - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/newsfeeds/${encodeURIComponent(id)}/items`, + `news/newsfeeds/${core.url.encodePathParam(id)}/items`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.PaginatedResponse, rawResponse: _response.rawResponse }; @@ -609,27 +481,13 @@ export class News { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/newsfeeds/{id}/items."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/news/newsfeeds/{id}/items"); } /** * You can fetch a list of all newsfeeds * - * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * @param {NewsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -637,38 +495,36 @@ export class News { * await client.unstable.news.listNewsfeeds() */ public listNewsfeeds( - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listNewsfeeds(requestOptions)); } private async __listNewsfeeds( - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "news/newsfeeds", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.PaginatedResponse, rawResponse: _response.rawResponse }; @@ -690,28 +546,14 @@ export class News { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/newsfeeds."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/news/newsfeeds"); } /** * You can fetch the details of a single newsfeed * * @param {Intercom.unstable.RetrieveNewsfeedRequest} request - * @param {News.RequestOptions} requestOptions - Request-specific configuration. + * @param {NewsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -722,40 +564,38 @@ export class News { */ public retrieveNewsfeed( request: Intercom.unstable.RetrieveNewsfeedRequest, - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__retrieveNewsfeed(request, requestOptions)); } private async __retrieveNewsfeed( request: Intercom.unstable.RetrieveNewsfeedRequest, - requestOptions?: News.RequestOptions, + requestOptions?: NewsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `news/newsfeeds/${encodeURIComponent(id)}`, + `news/newsfeeds/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Newsfeed, rawResponse: _response.rawResponse }; @@ -777,32 +617,6 @@ export class News { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /news/newsfeeds/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/news/newsfeeds/{id}"); } } diff --git a/src/api/resources/unstable/resources/news/client/index.ts b/src/api/resources/unstable/resources/news/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/news/client/index.ts +++ b/src/api/resources/unstable/resources/news/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/news/client/requests/DeleteNewsItemRequest.ts b/src/api/resources/unstable/resources/news/client/requests/DeleteNewsItemRequest.ts index 5edfca2a..e78e359e 100644 --- a/src/api/resources/unstable/resources/news/client/requests/DeleteNewsItemRequest.ts +++ b/src/api/resources/unstable/resources/news/client/requests/DeleteNewsItemRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DeleteNewsItemRequest { - /** - * The unique identifier for the news item which is given by Intercom. - */ + /** The unique identifier for the news item which is given by Intercom. */ id: number; } diff --git a/src/api/resources/unstable/resources/news/client/requests/ListLiveNewsfeedItemsRequest.ts b/src/api/resources/unstable/resources/news/client/requests/ListLiveNewsfeedItemsRequest.ts index 4101909c..80431667 100644 --- a/src/api/resources/unstable/resources/news/client/requests/ListLiveNewsfeedItemsRequest.ts +++ b/src/api/resources/unstable/resources/news/client/requests/ListLiveNewsfeedItemsRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ListLiveNewsfeedItemsRequest { - /** - * The unique identifier for the news feed item which is given by Intercom. - */ + /** The unique identifier for the news feed item which is given by Intercom. */ id: string; } diff --git a/src/api/resources/unstable/resources/news/client/requests/RetrieveNewsItemRequest.ts b/src/api/resources/unstable/resources/news/client/requests/RetrieveNewsItemRequest.ts index b2e33231..4c61a48f 100644 --- a/src/api/resources/unstable/resources/news/client/requests/RetrieveNewsItemRequest.ts +++ b/src/api/resources/unstable/resources/news/client/requests/RetrieveNewsItemRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface RetrieveNewsItemRequest { - /** - * The unique identifier for the news item which is given by Intercom. - */ + /** The unique identifier for the news item which is given by Intercom. */ id: number; } diff --git a/src/api/resources/unstable/resources/news/client/requests/RetrieveNewsfeedRequest.ts b/src/api/resources/unstable/resources/news/client/requests/RetrieveNewsfeedRequest.ts index a4d0663a..d7162aaa 100644 --- a/src/api/resources/unstable/resources/news/client/requests/RetrieveNewsfeedRequest.ts +++ b/src/api/resources/unstable/resources/news/client/requests/RetrieveNewsfeedRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface RetrieveNewsfeedRequest { - /** - * The unique identifier for the news feed item which is given by Intercom. - */ + /** The unique identifier for the news feed item which is given by Intercom. */ id: string; } diff --git a/src/api/resources/unstable/resources/news/client/requests/UpdateNewsItemRequest.ts b/src/api/resources/unstable/resources/news/client/requests/UpdateNewsItemRequest.ts index e0962588..8c96cdfa 100644 --- a/src/api/resources/unstable/resources/news/client/requests/UpdateNewsItemRequest.ts +++ b/src/api/resources/unstable/resources/news/client/requests/UpdateNewsItemRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example @@ -28,9 +26,7 @@ import * as Intercom from "../../../../../../index"; * } */ export interface UpdateNewsItemRequest { - /** - * The unique identifier for the news item which is given by Intercom. - */ + /** The unique identifier for the news item which is given by Intercom. */ id: number; body: Intercom.unstable.NewsItemRequest; } diff --git a/src/api/resources/unstable/resources/news/client/requests/index.ts b/src/api/resources/unstable/resources/news/client/requests/index.ts index 94944125..d5c9a5f5 100644 --- a/src/api/resources/unstable/resources/news/client/requests/index.ts +++ b/src/api/resources/unstable/resources/news/client/requests/index.ts @@ -1,5 +1,5 @@ -export { type RetrieveNewsItemRequest } from "./RetrieveNewsItemRequest"; -export { type UpdateNewsItemRequest } from "./UpdateNewsItemRequest"; -export { type DeleteNewsItemRequest } from "./DeleteNewsItemRequest"; -export { type ListLiveNewsfeedItemsRequest } from "./ListLiveNewsfeedItemsRequest"; -export { type RetrieveNewsfeedRequest } from "./RetrieveNewsfeedRequest"; +export type { DeleteNewsItemRequest } from "./DeleteNewsItemRequest.js"; +export type { ListLiveNewsfeedItemsRequest } from "./ListLiveNewsfeedItemsRequest.js"; +export type { RetrieveNewsfeedRequest } from "./RetrieveNewsfeedRequest.js"; +export type { RetrieveNewsItemRequest } from "./RetrieveNewsItemRequest.js"; +export type { UpdateNewsItemRequest } from "./UpdateNewsItemRequest.js"; diff --git a/src/api/resources/unstable/resources/news/index.ts b/src/api/resources/unstable/resources/news/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/news/index.ts +++ b/src/api/resources/unstable/resources/news/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/news/types/NewsItem.ts b/src/api/resources/unstable/resources/news/types/NewsItem.ts index 6650f0c5..a5ecc130 100644 --- a/src/api/resources/unstable/resources/news/types/NewsItem.ts +++ b/src/api/resources/unstable/resources/news/types/NewsItem.ts @@ -1,13 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * A News Item is a content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers. */ export interface NewsItem { + /** The type of object. */ + type?: "news-item"; /** The unique identifier for the news item which is given by Intercom. */ id?: string; /** The id of the workspace which the news item belongs to. */ @@ -37,12 +37,10 @@ export interface NewsItem { } export namespace NewsItem { - /** - * News items will not be visible to your users in the assigned newsfeeds until they are set live. - */ - export type State = "draft" | "live"; + /** News items will not be visible to your users in the assigned newsfeeds until they are set live. */ export const State = { Draft: "draft", Live: "live", } as const; + export type State = (typeof State)[keyof typeof State]; } diff --git a/src/api/resources/unstable/resources/news/types/Newsfeed.ts b/src/api/resources/unstable/resources/news/types/Newsfeed.ts index 10dc3a1f..a42f6306 100644 --- a/src/api/resources/unstable/resources/news/types/Newsfeed.ts +++ b/src/api/resources/unstable/resources/news/types/Newsfeed.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A newsfeed is a collection of news items, targeted to a specific audience. @@ -10,6 +8,8 @@ export interface Newsfeed { /** The unique identifier for the newsfeed which is given by Intercom. */ id?: string; + /** The type of object. */ + type?: "newsfeed"; /** The name of the newsfeed. This name will never be visible to your users. */ name?: string; /** Timestamp for when the newsfeed was created. */ diff --git a/src/api/resources/unstable/resources/news/types/NewsfeedAssignment.ts b/src/api/resources/unstable/resources/news/types/NewsfeedAssignment.ts index 2eb97d45..064483c9 100644 --- a/src/api/resources/unstable/resources/news/types/NewsfeedAssignment.ts +++ b/src/api/resources/unstable/resources/news/types/NewsfeedAssignment.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Assigns a news item to a newsfeed. diff --git a/src/api/resources/unstable/resources/news/types/index.ts b/src/api/resources/unstable/resources/news/types/index.ts index b8c22f3c..fe7a29c8 100644 --- a/src/api/resources/unstable/resources/news/types/index.ts +++ b/src/api/resources/unstable/resources/news/types/index.ts @@ -1,3 +1,3 @@ -export * from "./NewsItem"; -export * from "./Newsfeed"; -export * from "./NewsfeedAssignment"; +export * from "./Newsfeed.js"; +export * from "./NewsfeedAssignment.js"; +export * from "./NewsItem.js"; diff --git a/src/api/resources/unstable/resources/notes/client/Client.ts b/src/api/resources/unstable/resources/notes/client/Client.ts index b82d5191..6daafede 100644 --- a/src/api/resources/unstable/resources/notes/client/Client.ts +++ b/src/api/resources/unstable/resources/notes/client/Client.ts @@ -1,85 +1,103 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Notes { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace NotesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Notes */ -export class Notes { - constructor(protected readonly _options: Notes.Options = {}) {} +export class NotesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: NotesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * You can fetch a list of notes that are associated to a company. + * + * @param {Intercom.unstable.ListCompanyNotesRequest} request + * @param {NotesClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.notes.listCompanyNotes({ + * id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * }) + */ + public listCompanyNotes( + request: Intercom.unstable.ListCompanyNotesRequest, + requestOptions?: NotesClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listCompanyNotes(request, requestOptions)); + } + + private async __listCompanyNotes( + request: Intercom.unstable.ListCompanyNotesRequest, + requestOptions?: NotesClient.RequestOptions, + ): Promise> { + const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `companies/${core.url.encodePathParam(id)}/notes`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.NoteList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/companies/{id}/notes"); + } /** * You can fetch a list of notes that are associated to a contact. * * @param {Intercom.unstable.ListNotesRequest} request - * @param {Notes.RequestOptions} requestOptions - Request-specific configuration. + * @param {NotesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.NotFoundError} * @@ -90,40 +108,38 @@ export class Notes { */ public listNotes( request: Intercom.unstable.ListNotesRequest, - requestOptions?: Notes.RequestOptions, + requestOptions?: NotesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listNotes(request, requestOptions)); } private async __listNotes( request: Intercom.unstable.ListNotesRequest, - requestOptions?: Notes.RequestOptions, + requestOptions?: NotesClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(id)}/notes`, + `contacts/${core.url.encodePathParam(id)}/notes`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.NoteList, rawResponse: _response.rawResponse }; @@ -142,28 +158,14 @@ export class Notes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /contacts/{id}/notes."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/contacts/{id}/notes"); } /** * You can add a note to a single contact. * * @param {Intercom.unstable.CreateNoteRequest} request - * @param {Notes.RequestOptions} requestOptions - Request-specific configuration. + * @param {NotesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.NotFoundError} * @@ -193,41 +195,41 @@ export class Notes { */ public createNote( request: Intercom.unstable.CreateNoteRequest, - requestOptions?: Notes.RequestOptions, + requestOptions?: NotesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createNote(request, requestOptions)); } private async __createNote( request: Intercom.unstable.CreateNoteRequest, - requestOptions?: Notes.RequestOptions, + requestOptions?: NotesClient.RequestOptions, ): Promise> { const { id, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(id)}/notes`, + `contacts/${core.url.encodePathParam(id)}/notes`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Note, rawResponse: _response.rawResponse }; @@ -246,28 +248,14 @@ export class Notes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /contacts/{id}/notes."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts/{id}/notes"); } /** * You can fetch the details of a single note. * * @param {Intercom.unstable.RetrieveNoteRequest} request - * @param {Notes.RequestOptions} requestOptions - Request-specific configuration. + * @param {NotesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -279,40 +267,38 @@ export class Notes { */ public retrieveNote( request: Intercom.unstable.RetrieveNoteRequest, - requestOptions?: Notes.RequestOptions, + requestOptions?: NotesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__retrieveNote(request, requestOptions)); } private async __retrieveNote( request: Intercom.unstable.RetrieveNoteRequest, - requestOptions?: Notes.RequestOptions, + requestOptions?: NotesClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `notes/${encodeURIComponent(id)}`, + `notes/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Note, rawResponse: _response.rawResponse }; @@ -336,32 +322,6 @@ export class Notes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /notes/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/notes/{id}"); } } diff --git a/src/api/resources/unstable/resources/notes/client/index.ts b/src/api/resources/unstable/resources/notes/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/notes/client/index.ts +++ b/src/api/resources/unstable/resources/notes/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/notes/client/requests/CreateNoteRequest.ts b/src/api/resources/unstable/resources/notes/client/requests/CreateNoteRequest.ts index 8fe9c7ae..6802985e 100644 --- a/src/api/resources/unstable/resources/notes/client/requests/CreateNoteRequest.ts +++ b/src/api/resources/unstable/resources/notes/client/requests/CreateNoteRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -28,9 +26,7 @@ * } */ export interface CreateNoteRequest { - /** - * The unique identifier of a given contact. - */ + /** The unique identifier of a given contact. */ id: number; /** The text of the note. */ body: string; diff --git a/src/api/resources/unstable/resources/notes/client/requests/ListCompanyNotesRequest.ts b/src/api/resources/unstable/resources/notes/client/requests/ListCompanyNotesRequest.ts new file mode 100644 index 00000000..5e97337d --- /dev/null +++ b/src/api/resources/unstable/resources/notes/client/requests/ListCompanyNotesRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632" + * } + */ +export interface ListCompanyNotesRequest { + /** The unique identifier for the company which is given by Intercom */ + id: string; +} diff --git a/src/api/resources/unstable/resources/notes/client/requests/ListNotesRequest.ts b/src/api/resources/unstable/resources/notes/client/requests/ListNotesRequest.ts index 7d8052df..52dfe1b3 100644 --- a/src/api/resources/unstable/resources/notes/client/requests/ListNotesRequest.ts +++ b/src/api/resources/unstable/resources/notes/client/requests/ListNotesRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface ListNotesRequest { - /** - * The unique identifier of a contact. - */ + /** The unique identifier of a contact. */ id: number; } diff --git a/src/api/resources/unstable/resources/notes/client/requests/RetrieveNoteRequest.ts b/src/api/resources/unstable/resources/notes/client/requests/RetrieveNoteRequest.ts index 8fc83798..c6fe4988 100644 --- a/src/api/resources/unstable/resources/notes/client/requests/RetrieveNoteRequest.ts +++ b/src/api/resources/unstable/resources/notes/client/requests/RetrieveNoteRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface RetrieveNoteRequest { - /** - * The unique identifier of a given note - */ + /** The unique identifier of a given note */ id: number; } diff --git a/src/api/resources/unstable/resources/notes/client/requests/index.ts b/src/api/resources/unstable/resources/notes/client/requests/index.ts index 4fa65001..ed230370 100644 --- a/src/api/resources/unstable/resources/notes/client/requests/index.ts +++ b/src/api/resources/unstable/resources/notes/client/requests/index.ts @@ -1,3 +1,4 @@ -export { type ListNotesRequest } from "./ListNotesRequest"; -export { type CreateNoteRequest } from "./CreateNoteRequest"; -export { type RetrieveNoteRequest } from "./RetrieveNoteRequest"; +export type { CreateNoteRequest } from "./CreateNoteRequest.js"; +export type { ListCompanyNotesRequest } from "./ListCompanyNotesRequest.js"; +export type { ListNotesRequest } from "./ListNotesRequest.js"; +export type { RetrieveNoteRequest } from "./RetrieveNoteRequest.js"; diff --git a/src/api/resources/unstable/resources/notes/index.ts b/src/api/resources/unstable/resources/notes/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/notes/index.ts +++ b/src/api/resources/unstable/resources/notes/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/notes/types/CompanyNote.ts b/src/api/resources/unstable/resources/notes/types/CompanyNote.ts new file mode 100644 index 00000000..d63295c5 --- /dev/null +++ b/src/api/resources/unstable/resources/notes/types/CompanyNote.ts @@ -0,0 +1,33 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../../../index.js"; + +/** + * Notes allow you to annotate and comment on companies. + */ +export interface CompanyNote { + /** String representing the object's type. Always has the value `note`. */ + type?: string; + /** The id of the note. */ + id?: string; + /** The time the note was created. */ + created_at?: number; + /** Represents the company that the note was created about. */ + company?: CompanyNote.Company; + /** Optional. Represents the Admin that created the note. */ + author?: Intercom.unstable.Admin; + /** The body text of the note. */ + body?: string; +} + +export namespace CompanyNote { + /** + * Represents the company that the note was created about. + */ + export interface Company { + /** String representing the object's type. Always has the value `company`. */ + type?: string; + /** The id of the company. */ + id?: string; + } +} diff --git a/src/api/resources/unstable/resources/notes/types/Note.ts b/src/api/resources/unstable/resources/notes/types/Note.ts index d4bc42b2..571bce49 100644 --- a/src/api/resources/unstable/resources/notes/types/Note.ts +++ b/src/api/resources/unstable/resources/notes/types/Note.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * Notes allow you to annotate and comment on your contacts. diff --git a/src/api/resources/unstable/resources/notes/types/index.ts b/src/api/resources/unstable/resources/notes/types/index.ts index cf881fa5..0e6d3d17 100644 --- a/src/api/resources/unstable/resources/notes/types/index.ts +++ b/src/api/resources/unstable/resources/notes/types/index.ts @@ -1 +1,2 @@ -export * from "./Note"; +export * from "./CompanyNote.js"; +export * from "./Note.js"; diff --git a/src/api/resources/unstable/resources/segments/client/Client.ts b/src/api/resources/unstable/resources/segments/client/Client.ts index 67d08f1f..64d7c4fb 100644 --- a/src/api/resources/unstable/resources/segments/client/Client.ts +++ b/src/api/resources/unstable/resources/segments/client/Client.ts @@ -1,133 +1,82 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Segments { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace SegmentsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Segments */ -export class Segments { - constructor(protected readonly _options: Segments.Options = {}) {} +export class SegmentsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: SegmentsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch a list of all segments. * * @param {Intercom.unstable.ListSegmentsRequest} request - * @param {Segments.RequestOptions} requestOptions - Request-specific configuration. + * @param {SegmentsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * * @example - * await client.unstable.segments.listSegments() + * await client.unstable.segments.listSegments({ + * include_count: true + * }) */ public listSegments( request: Intercom.unstable.ListSegmentsRequest = {}, - requestOptions?: Segments.RequestOptions, + requestOptions?: SegmentsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listSegments(request, requestOptions)); } private async __listSegments( request: Intercom.unstable.ListSegmentsRequest = {}, - requestOptions?: Segments.RequestOptions, + requestOptions?: SegmentsClient.RequestOptions, ): Promise> { const { include_count: includeCount } = request; const _queryParams: Record = {}; if (includeCount != null) { - _queryParams["include_count"] = includeCount.toString(); + _queryParams.include_count = includeCount.toString(); } + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "segments", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.SegmentList, rawResponse: _response.rawResponse }; @@ -149,28 +98,14 @@ export class Segments { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /segments."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/segments"); } /** * You can fetch the details of a single segment. * * @param {Intercom.unstable.RetrieveSegmentRequest} request - * @param {Segments.RequestOptions} requestOptions - Request-specific configuration. + * @param {SegmentsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -182,40 +117,38 @@ export class Segments { */ public retrieveSegment( request: Intercom.unstable.RetrieveSegmentRequest, - requestOptions?: Segments.RequestOptions, + requestOptions?: SegmentsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__retrieveSegment(request, requestOptions)); } private async __retrieveSegment( request: Intercom.unstable.RetrieveSegmentRequest, - requestOptions?: Segments.RequestOptions, + requestOptions?: SegmentsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `segments/${encodeURIComponent(id)}`, + `segments/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Segment, rawResponse: _response.rawResponse }; @@ -239,32 +172,6 @@ export class Segments { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /segments/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/segments/{id}"); } } diff --git a/src/api/resources/unstable/resources/segments/client/index.ts b/src/api/resources/unstable/resources/segments/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/segments/client/index.ts +++ b/src/api/resources/unstable/resources/segments/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/segments/client/requests/ListSegmentsRequest.ts b/src/api/resources/unstable/resources/segments/client/requests/ListSegmentsRequest.ts index 116acd5e..7554f000 100644 --- a/src/api/resources/unstable/resources/segments/client/requests/ListSegmentsRequest.ts +++ b/src/api/resources/unstable/resources/segments/client/requests/ListSegmentsRequest.ts @@ -1,14 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example - * {} + * { + * include_count: true + * } */ export interface ListSegmentsRequest { - /** - * It includes the count of contacts that belong to each segment. - */ + /** It includes the count of contacts that belong to each segment. */ include_count?: boolean; } diff --git a/src/api/resources/unstable/resources/segments/client/requests/RetrieveSegmentRequest.ts b/src/api/resources/unstable/resources/segments/client/requests/RetrieveSegmentRequest.ts index 0ba937bf..f7877c1e 100644 --- a/src/api/resources/unstable/resources/segments/client/requests/RetrieveSegmentRequest.ts +++ b/src/api/resources/unstable/resources/segments/client/requests/RetrieveSegmentRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface RetrieveSegmentRequest { - /** - * The unique identified of a given segment. - */ + /** The unique identified of a given segment. */ id: string; } diff --git a/src/api/resources/unstable/resources/segments/client/requests/index.ts b/src/api/resources/unstable/resources/segments/client/requests/index.ts index d31998d0..3ef3b577 100644 --- a/src/api/resources/unstable/resources/segments/client/requests/index.ts +++ b/src/api/resources/unstable/resources/segments/client/requests/index.ts @@ -1,2 +1,2 @@ -export { type ListSegmentsRequest } from "./ListSegmentsRequest"; -export { type RetrieveSegmentRequest } from "./RetrieveSegmentRequest"; +export type { ListSegmentsRequest } from "./ListSegmentsRequest.js"; +export type { RetrieveSegmentRequest } from "./RetrieveSegmentRequest.js"; diff --git a/src/api/resources/unstable/resources/segments/index.ts b/src/api/resources/unstable/resources/segments/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/segments/index.ts +++ b/src/api/resources/unstable/resources/segments/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/segments/types/Segment.ts b/src/api/resources/unstable/resources/segments/types/Segment.ts index b297f427..5fbb6b53 100644 --- a/src/api/resources/unstable/resources/segments/types/Segment.ts +++ b/src/api/resources/unstable/resources/segments/types/Segment.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A segment is a group of your contacts defined by the rules that you set. @@ -23,12 +21,10 @@ export interface Segment { } export namespace Segment { - /** - * Type of the contact: contact (lead) or user. - */ - export type PersonType = "contact" | "user"; + /** Type of the contact: contact (lead) or user. */ export const PersonType = { Contact: "contact", User: "user", } as const; + export type PersonType = (typeof PersonType)[keyof typeof PersonType]; } diff --git a/src/api/resources/unstable/resources/segments/types/index.ts b/src/api/resources/unstable/resources/segments/types/index.ts index 957aab14..a934b01a 100644 --- a/src/api/resources/unstable/resources/segments/types/index.ts +++ b/src/api/resources/unstable/resources/segments/types/index.ts @@ -1 +1 @@ -export * from "./Segment"; +export * from "./Segment.js"; diff --git a/src/api/resources/unstable/resources/subscriptionTypes/client/Client.ts b/src/api/resources/unstable/resources/subscriptionTypes/client/Client.ts index 38e70154..b43baf9e 100644 --- a/src/api/resources/unstable/resources/subscriptionTypes/client/Client.ts +++ b/src/api/resources/unstable/resources/subscriptionTypes/client/Client.ts @@ -1,79 +1,29 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace SubscriptionTypes { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace SubscriptionTypesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about subscription types */ -export class SubscriptionTypes { - constructor(protected readonly _options: SubscriptionTypes.Options = {}) {} +export class SubscriptionTypesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: SubscriptionTypesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can add a specific subscription to a contact. In Intercom, we have two different subscription types based on user consent - opt-out and opt-in: @@ -85,7 +35,7 @@ export class SubscriptionTypes { * This will return a subscription type model for the subscription type that was added to the contact. * * @param {Intercom.unstable.AttachSubscriptionTypeToContactRequest} request - * @param {SubscriptionTypes.RequestOptions} requestOptions - Request-specific configuration. + * @param {SubscriptionTypesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -106,41 +56,41 @@ export class SubscriptionTypes { */ public attachSubscriptionTypeToContact( request: Intercom.unstable.AttachSubscriptionTypeToContactRequest, - requestOptions?: SubscriptionTypes.RequestOptions, + requestOptions?: SubscriptionTypesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__attachSubscriptionTypeToContact(request, requestOptions)); } private async __attachSubscriptionTypeToContact( request: Intercom.unstable.AttachSubscriptionTypeToContactRequest, - requestOptions?: SubscriptionTypes.RequestOptions, + requestOptions?: SubscriptionTypesClient.RequestOptions, ): Promise> { const { contact_id: contactId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/subscriptions`, + `contacts/${core.url.encodePathParam(contactId)}/subscriptions`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.SubscriptionType, rawResponse: _response.rawResponse }; @@ -164,30 +114,19 @@ export class SubscriptionTypes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /contacts/{contact_id}/subscriptions.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/contacts/{contact_id}/subscriptions", + ); } /** * You can remove a specific subscription from a contact. This will return a subscription type model for the subscription type that was removed from the contact. * * @param {Intercom.unstable.DetachSubscriptionTypeToContactRequest} request - * @param {SubscriptionTypes.RequestOptions} requestOptions - Request-specific configuration. + * @param {SubscriptionTypesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -200,40 +139,38 @@ export class SubscriptionTypes { */ public detachSubscriptionTypeToContact( request: Intercom.unstable.DetachSubscriptionTypeToContactRequest, - requestOptions?: SubscriptionTypes.RequestOptions, + requestOptions?: SubscriptionTypesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__detachSubscriptionTypeToContact(request, requestOptions)); } private async __detachSubscriptionTypeToContact( request: Intercom.unstable.DetachSubscriptionTypeToContactRequest, - requestOptions?: SubscriptionTypes.RequestOptions, + requestOptions?: SubscriptionTypesClient.RequestOptions, ): Promise> { const { contact_id: contactId, id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/subscriptions/${encodeURIComponent(id)}`, + `contacts/${core.url.encodePathParam(contactId)}/subscriptions/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.SubscriptionType, rawResponse: _response.rawResponse }; @@ -257,29 +194,18 @@ export class SubscriptionTypes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /contacts/{contact_id}/subscriptions/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/contacts/{contact_id}/subscriptions/{id}", + ); } /** * You can list all subscription types. A list of subscription type objects will be returned. * - * @param {SubscriptionTypes.RequestOptions} requestOptions - Request-specific configuration. + * @param {SubscriptionTypesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -287,38 +213,36 @@ export class SubscriptionTypes { * await client.unstable.subscriptionTypes.listSubscriptionTypes() */ public listSubscriptionTypes( - requestOptions?: SubscriptionTypes.RequestOptions, + requestOptions?: SubscriptionTypesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listSubscriptionTypes(requestOptions)); } private async __listSubscriptionTypes( - requestOptions?: SubscriptionTypes.RequestOptions, + requestOptions?: SubscriptionTypesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "subscription_types", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -343,32 +267,6 @@ export class SubscriptionTypes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /subscription_types."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/subscription_types"); } } diff --git a/src/api/resources/unstable/resources/subscriptionTypes/client/index.ts b/src/api/resources/unstable/resources/subscriptionTypes/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/subscriptionTypes/client/index.ts +++ b/src/api/resources/unstable/resources/subscriptionTypes/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/subscriptionTypes/client/requests/AttachSubscriptionTypeToContactRequest.ts b/src/api/resources/unstable/resources/subscriptionTypes/client/requests/AttachSubscriptionTypeToContactRequest.ts index 742321c7..18911f33 100644 --- a/src/api/resources/unstable/resources/subscriptionTypes/client/requests/AttachSubscriptionTypeToContactRequest.ts +++ b/src/api/resources/unstable/resources/subscriptionTypes/client/requests/AttachSubscriptionTypeToContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -25,9 +23,7 @@ * } */ export interface AttachSubscriptionTypeToContactRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; /** The unique identifier for the subscription which is given by Intercom */ id: string; diff --git a/src/api/resources/unstable/resources/subscriptionTypes/client/requests/DetachSubscriptionTypeToContactRequest.ts b/src/api/resources/unstable/resources/subscriptionTypes/client/requests/DetachSubscriptionTypeToContactRequest.ts index 8ad29dba..156af2ee 100644 --- a/src/api/resources/unstable/resources/subscriptionTypes/client/requests/DetachSubscriptionTypeToContactRequest.ts +++ b/src/api/resources/unstable/resources/subscriptionTypes/client/requests/DetachSubscriptionTypeToContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -10,12 +8,8 @@ * } */ export interface DetachSubscriptionTypeToContactRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; - /** - * The unique identifier for the subscription type which is given by Intercom - */ + /** The unique identifier for the subscription type which is given by Intercom */ id: string; } diff --git a/src/api/resources/unstable/resources/subscriptionTypes/client/requests/index.ts b/src/api/resources/unstable/resources/subscriptionTypes/client/requests/index.ts index d5cc644c..ce062982 100644 --- a/src/api/resources/unstable/resources/subscriptionTypes/client/requests/index.ts +++ b/src/api/resources/unstable/resources/subscriptionTypes/client/requests/index.ts @@ -1,2 +1,2 @@ -export { type AttachSubscriptionTypeToContactRequest } from "./AttachSubscriptionTypeToContactRequest"; -export { type DetachSubscriptionTypeToContactRequest } from "./DetachSubscriptionTypeToContactRequest"; +export type { AttachSubscriptionTypeToContactRequest } from "./AttachSubscriptionTypeToContactRequest.js"; +export type { DetachSubscriptionTypeToContactRequest } from "./DetachSubscriptionTypeToContactRequest.js"; diff --git a/src/api/resources/unstable/resources/subscriptionTypes/index.ts b/src/api/resources/unstable/resources/subscriptionTypes/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/subscriptionTypes/index.ts +++ b/src/api/resources/unstable/resources/subscriptionTypes/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/subscriptionTypes/types/SubscriptionType.ts b/src/api/resources/unstable/resources/subscriptionTypes/types/SubscriptionType.ts index bcb2bd27..3867aa94 100644 --- a/src/api/resources/unstable/resources/subscriptionTypes/types/SubscriptionType.ts +++ b/src/api/resources/unstable/resources/subscriptionTypes/types/SubscriptionType.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * A subscription type lets customers easily opt out of non-essential communications without missing what's important to them. @@ -24,30 +22,26 @@ export interface SubscriptionType { } export namespace SubscriptionType { - /** - * The state of the subscription type. - */ - export type State = "live" | "draft" | "archived"; + /** The state of the subscription type. */ export const State = { Live: "live", Draft: "draft", Archived: "archived", } as const; - /** - * Describes the type of consent. - */ - export type ConsentType = "opt_out" | "opt_in"; + export type State = (typeof State)[keyof typeof State]; + /** Describes the type of consent. */ export const ConsentType = { OptOut: "opt_out", OptIn: "opt_in", } as const; + export type ConsentType = (typeof ConsentType)[keyof typeof ConsentType]; export type ContentTypes = ContentTypes.Item[]; export namespace ContentTypes { - export type Item = "email" | "sms_message"; export const Item = { Email: "email", SmsMessage: "sms_message", } as const; + export type Item = (typeof Item)[keyof typeof Item]; } } diff --git a/src/api/resources/unstable/resources/subscriptionTypes/types/index.ts b/src/api/resources/unstable/resources/subscriptionTypes/types/index.ts index fe95bab5..b6a27359 100644 --- a/src/api/resources/unstable/resources/subscriptionTypes/types/index.ts +++ b/src/api/resources/unstable/resources/subscriptionTypes/types/index.ts @@ -1 +1 @@ -export * from "./SubscriptionType"; +export * from "./SubscriptionType.js"; diff --git a/src/api/resources/unstable/resources/switch/client/Client.ts b/src/api/resources/unstable/resources/switch/client/Client.ts index 543d2759..0c95ab0e 100644 --- a/src/api/resources/unstable/resources/switch/client/Client.ts +++ b/src/api/resources/unstable/resources/switch/client/Client.ts @@ -1,79 +1,29 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Switch { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace SwitchClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about Switch */ -export class Switch { - constructor(protected readonly _options: Switch.Options = {}) {} +export class SwitchClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: SwitchClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can use the API to deflect phone calls to the Intercom Messenger. @@ -82,7 +32,7 @@ export class Switch { * If custom attributes are specified, they will be added to the user or lead's custom data attributes. * * @param {unknown} request - * @param {Switch.RequestOptions} requestOptions - Request-specific configuration. + * @param {SwitchClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -95,40 +45,40 @@ export class Switch { */ public createPhoneSwitch( request?: unknown, - requestOptions?: Switch.RequestOptions, + requestOptions?: SwitchClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createPhoneSwitch(request, requestOptions)); } private async __createPhoneSwitch( request?: unknown, - requestOptions?: Switch.RequestOptions, + requestOptions?: SwitchClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "phone_call_redirects", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -160,32 +110,6 @@ export class Switch { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /phone_call_redirects."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/phone_call_redirects"); } } diff --git a/src/api/resources/unstable/resources/switch/index.ts b/src/api/resources/unstable/resources/switch/index.ts index 5ec76921..914b8c3c 100644 --- a/src/api/resources/unstable/resources/switch/index.ts +++ b/src/api/resources/unstable/resources/switch/index.ts @@ -1 +1 @@ -export * from "./client"; +export * from "./client/index.js"; diff --git a/src/api/resources/unstable/resources/tags/client/Client.ts b/src/api/resources/unstable/resources/tags/client/Client.ts index 279f075c..681b40df 100644 --- a/src/api/resources/unstable/resources/tags/client/Client.ts +++ b/src/api/resources/unstable/resources/tags/client/Client.ts @@ -1,85 +1,35 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Tags { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace TagsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about tags */ -export class Tags { - constructor(protected readonly _options: Tags.Options = {}) {} +export class TagsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: TagsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can tag a specific contact. This will return a tag object for the tag that was added to the contact. * * @param {Intercom.unstable.AttachTagToContactRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -98,41 +48,41 @@ export class Tags { */ public attachTagToContact( request: Intercom.unstable.AttachTagToContactRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__attachTagToContact(request, requestOptions)); } private async __attachTagToContact( request: Intercom.unstable.AttachTagToContactRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { contact_id: contactId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/tags`, + `contacts/${core.url.encodePathParam(contactId)}/tags`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; @@ -156,30 +106,14 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /contacts/{contact_id}/tags.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/contacts/{contact_id}/tags"); } /** * You can remove tag from a specific contact. This will return a tag object for the tag that was removed from the contact. * * @param {Intercom.unstable.DetachTagFromContactRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -192,40 +126,38 @@ export class Tags { */ public detachTagFromContact( request: Intercom.unstable.DetachTagFromContactRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__detachTagFromContact(request, requestOptions)); } private async __detachTagFromContact( request: Intercom.unstable.DetachTagFromContactRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { contact_id: contactId, id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `contacts/${encodeURIComponent(contactId)}/tags/${encodeURIComponent(id)}`, + `contacts/${core.url.encodePathParam(contactId)}/tags/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; @@ -249,30 +181,19 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /contacts/{contact_id}/tags/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/contacts/{contact_id}/tags/{id}", + ); } /** * You can tag a specific conversation. This will return a tag object for the tag that was added to the conversation. * * @param {Intercom.unstable.AttachTagToConversationRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -286,41 +207,41 @@ export class Tags { */ public attachTagToConversation( request: Intercom.unstable.AttachTagToConversationRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__attachTagToConversation(request, requestOptions)); } private async __attachTagToConversation( request: Intercom.unstable.AttachTagToConversationRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { conversation_id: conversationId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/tags`, + `conversations/${core.url.encodePathParam(conversationId)}/tags`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; @@ -344,30 +265,19 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /conversations/{conversation_id}/tags.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/conversations/{conversation_id}/tags", + ); } /** * You can remove tag from a specific conversation. This will return a tag object for the tag that was removed from the conversation. * * @param {Intercom.unstable.DetachTagFromConversationRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -381,41 +291,41 @@ export class Tags { */ public detachTagFromConversation( request: Intercom.unstable.DetachTagFromConversationRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__detachTagFromConversation(request, requestOptions)); } private async __detachTagFromConversation( request: Intercom.unstable.DetachTagFromConversationRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { conversation_id: conversationId, id, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `conversations/${encodeURIComponent(conversationId)}/tags/${encodeURIComponent(id)}`, + `conversations/${core.url.encodePathParam(conversationId)}/tags/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; @@ -439,66 +349,54 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /conversations/{conversation_id}/tags/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/conversations/{conversation_id}/tags/{id}", + ); } /** * You can fetch a list of all tags for a given workspace. * - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * * @example * await client.unstable.tags.listTags() */ - public listTags(requestOptions?: Tags.RequestOptions): core.HttpResponsePromise { + public listTags(requestOptions?: TagsClient.RequestOptions): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listTags(requestOptions)); } private async __listTags( - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "tags", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.TagList, rawResponse: _response.rawResponse }; @@ -520,21 +418,7 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tags."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/tags"); } /** @@ -553,7 +437,7 @@ export class Tags { * Each operation will return a tag object. * * @param {Intercom.unstable.CreateTagRequestBody} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -587,40 +471,40 @@ export class Tags { */ public createTag( request: Intercom.unstable.CreateTagRequestBody, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createTag(request, requestOptions)); } private async __createTag( request: Intercom.unstable.CreateTagRequestBody, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "tags", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; @@ -646,21 +530,7 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tags."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/tags"); } /** @@ -668,7 +538,7 @@ export class Tags { * This will return a tag object. * * @param {Intercom.unstable.FindTagRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -680,40 +550,38 @@ export class Tags { */ public findTag( request: Intercom.unstable.FindTagRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__findTag(request, requestOptions)); } private async __findTag( request: Intercom.unstable.FindTagRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tags/${encodeURIComponent(id)}`, + `tags/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; @@ -737,28 +605,14 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tags/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/tags/{id}"); } /** * You can delete the details of tags that are on the workspace by passing in the id. * * @param {Intercom.unstable.DeleteTagRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -771,40 +625,38 @@ export class Tags { */ public deleteTag( request: Intercom.unstable.DeleteTagRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__deleteTag(request, requestOptions)); } private async __deleteTag( request: Intercom.unstable.DeleteTagRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tags/${encodeURIComponent(id)}`, + `tags/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: undefined, rawResponse: _response.rawResponse }; @@ -830,28 +682,14 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /tags/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/tags/{id}"); } /** * You can tag a specific ticket. This will return a tag object for the tag that was added to the ticket. * * @param {Intercom.unstable.AttachTagToTicketRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -865,41 +703,41 @@ export class Tags { */ public attachTagToTicket( request: Intercom.unstable.AttachTagToTicketRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__attachTagToTicket(request, requestOptions)); } private async __attachTagToTicket( request: Intercom.unstable.AttachTagToTicketRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { ticket_id: ticketId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(ticketId)}/tags`, + `tickets/${core.url.encodePathParam(ticketId)}/tags`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; @@ -923,28 +761,14 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/{ticket_id}/tags."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/tickets/{ticket_id}/tags"); } /** * You can remove tag from a specific ticket. This will return a tag object for the tag that was removed from the ticket. * * @param {Intercom.unstable.DetachTagFromTicketRequest} request - * @param {Tags.RequestOptions} requestOptions - Request-specific configuration. + * @param {TagsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -958,41 +782,41 @@ export class Tags { */ public detachTagFromTicket( request: Intercom.unstable.DetachTagFromTicketRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__detachTagFromTicket(request, requestOptions)); } private async __detachTagFromTicket( request: Intercom.unstable.DetachTagFromTicketRequest, - requestOptions?: Tags.RequestOptions, + requestOptions?: TagsClient.RequestOptions, ): Promise> { const { ticket_id: ticketId, id, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(ticketId)}/tags/${encodeURIComponent(id)}`, + `tickets/${core.url.encodePathParam(ticketId)}/tags/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Tag, rawResponse: _response.rawResponse }; @@ -1016,34 +840,11 @@ export class Tags { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling DELETE /tickets/{ticket_id}/tags/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "DELETE", + "/tickets/{ticket_id}/tags/{id}", + ); } } diff --git a/src/api/resources/unstable/resources/tags/client/index.ts b/src/api/resources/unstable/resources/tags/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/tags/client/index.ts +++ b/src/api/resources/unstable/resources/tags/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/tags/client/requests/AttachTagToContactRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/AttachTagToContactRequest.ts index 2d9e27cc..94218c40 100644 --- a/src/api/resources/unstable/resources/tags/client/requests/AttachTagToContactRequest.ts +++ b/src/api/resources/unstable/resources/tags/client/requests/AttachTagToContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -22,9 +20,7 @@ * } */ export interface AttachTagToContactRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; /** The unique identifier for the tag which is given by Intercom */ id: string; diff --git a/src/api/resources/unstable/resources/tags/client/requests/AttachTagToConversationRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/AttachTagToConversationRequest.ts index f3533c92..c6084c34 100644 --- a/src/api/resources/unstable/resources/tags/client/requests/AttachTagToConversationRequest.ts +++ b/src/api/resources/unstable/resources/tags/client/requests/AttachTagToConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -18,9 +16,7 @@ * } */ export interface AttachTagToConversationRequest { - /** - * conversation_id - */ + /** conversation_id */ conversation_id: string; /** The unique identifier for the tag which is given by Intercom */ id: string; diff --git a/src/api/resources/unstable/resources/tags/client/requests/AttachTagToTicketRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/AttachTagToTicketRequest.ts index 55d90d6b..4082336b 100644 --- a/src/api/resources/unstable/resources/tags/client/requests/AttachTagToTicketRequest.ts +++ b/src/api/resources/unstable/resources/tags/client/requests/AttachTagToTicketRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -18,9 +16,7 @@ * } */ export interface AttachTagToTicketRequest { - /** - * ticket_id - */ + /** ticket_id */ ticket_id: string; /** The unique identifier for the tag which is given by Intercom */ id: string; diff --git a/src/api/resources/unstable/resources/tags/client/requests/DeleteTagRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/DeleteTagRequest.ts index 95921be7..1c226490 100644 --- a/src/api/resources/unstable/resources/tags/client/requests/DeleteTagRequest.ts +++ b/src/api/resources/unstable/resources/tags/client/requests/DeleteTagRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DeleteTagRequest { - /** - * The unique identifier of a given tag - */ + /** The unique identifier of a given tag */ id: string; } diff --git a/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromContactRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromContactRequest.ts index a4d90398..6737ddff 100644 --- a/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromContactRequest.ts +++ b/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -10,12 +8,8 @@ * } */ export interface DetachTagFromContactRequest { - /** - * The unique identifier for the contact which is given by Intercom - */ + /** The unique identifier for the contact which is given by Intercom */ contact_id: string; - /** - * The unique identifier for the tag which is given by Intercom - */ + /** The unique identifier for the tag which is given by Intercom */ id: string; } diff --git a/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromConversationRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromConversationRequest.ts index b41584c0..9cc3452f 100644 --- a/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromConversationRequest.ts +++ b/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -25,13 +23,9 @@ * } */ export interface DetachTagFromConversationRequest { - /** - * conversation_id - */ + /** conversation_id */ conversation_id: string; - /** - * id - */ + /** id */ id: string; /** The unique identifier for the admin which is given by Intercom. */ admin_id: string; diff --git a/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromTicketRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromTicketRequest.ts index ed321a9a..9c6e58ac 100644 --- a/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromTicketRequest.ts +++ b/src/api/resources/unstable/resources/tags/client/requests/DetachTagFromTicketRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -25,13 +23,9 @@ * } */ export interface DetachTagFromTicketRequest { - /** - * ticket_id - */ + /** ticket_id */ ticket_id: string; - /** - * The unique identifier for the tag which is given by Intercom - */ + /** The unique identifier for the tag which is given by Intercom */ id: string; /** The unique identifier for the admin which is given by Intercom. */ admin_id: string; diff --git a/src/api/resources/unstable/resources/tags/client/requests/FindTagRequest.ts b/src/api/resources/unstable/resources/tags/client/requests/FindTagRequest.ts index 7f23eca2..f3f35724 100644 --- a/src/api/resources/unstable/resources/tags/client/requests/FindTagRequest.ts +++ b/src/api/resources/unstable/resources/tags/client/requests/FindTagRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface FindTagRequest { - /** - * The unique identifier of a given tag - */ + /** The unique identifier of a given tag */ id: string; } diff --git a/src/api/resources/unstable/resources/tags/client/requests/index.ts b/src/api/resources/unstable/resources/tags/client/requests/index.ts index f529317a..5e52c0b2 100644 --- a/src/api/resources/unstable/resources/tags/client/requests/index.ts +++ b/src/api/resources/unstable/resources/tags/client/requests/index.ts @@ -1,8 +1,8 @@ -export { type AttachTagToContactRequest } from "./AttachTagToContactRequest"; -export { type DetachTagFromContactRequest } from "./DetachTagFromContactRequest"; -export { type AttachTagToConversationRequest } from "./AttachTagToConversationRequest"; -export { type DetachTagFromConversationRequest } from "./DetachTagFromConversationRequest"; -export { type FindTagRequest } from "./FindTagRequest"; -export { type DeleteTagRequest } from "./DeleteTagRequest"; -export { type AttachTagToTicketRequest } from "./AttachTagToTicketRequest"; -export { type DetachTagFromTicketRequest } from "./DetachTagFromTicketRequest"; +export type { AttachTagToContactRequest } from "./AttachTagToContactRequest.js"; +export type { AttachTagToConversationRequest } from "./AttachTagToConversationRequest.js"; +export type { AttachTagToTicketRequest } from "./AttachTagToTicketRequest.js"; +export type { DeleteTagRequest } from "./DeleteTagRequest.js"; +export type { DetachTagFromContactRequest } from "./DetachTagFromContactRequest.js"; +export type { DetachTagFromConversationRequest } from "./DetachTagFromConversationRequest.js"; +export type { DetachTagFromTicketRequest } from "./DetachTagFromTicketRequest.js"; +export type { FindTagRequest } from "./FindTagRequest.js"; diff --git a/src/api/resources/unstable/resources/tags/index.ts b/src/api/resources/unstable/resources/tags/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/tags/index.ts +++ b/src/api/resources/unstable/resources/tags/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/tags/types/CreateTagRequestBody.ts b/src/api/resources/unstable/resources/tags/types/CreateTagRequestBody.ts index cd52e610..9f3ab1dc 100644 --- a/src/api/resources/unstable/resources/tags/types/CreateTagRequestBody.ts +++ b/src/api/resources/unstable/resources/tags/types/CreateTagRequestBody.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; export type CreateTagRequestBody = | Intercom.unstable.CreateOrUpdateTagRequest diff --git a/src/api/resources/unstable/resources/tags/types/Tag.ts b/src/api/resources/unstable/resources/tags/types/Tag.ts index 869f2171..f62cbefb 100644 --- a/src/api/resources/unstable/resources/tags/types/Tag.ts +++ b/src/api/resources/unstable/resources/tags/types/Tag.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * A tag allows you to label your contacts, companies, and conversations and list them using that tag. diff --git a/src/api/resources/unstable/resources/tags/types/TagBasic.ts b/src/api/resources/unstable/resources/tags/types/TagBasic.ts index 7067f78b..8e8b815d 100644 --- a/src/api/resources/unstable/resources/tags/types/TagBasic.ts +++ b/src/api/resources/unstable/resources/tags/types/TagBasic.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A tag allows you to label your contacts, companies, and conversations and list them using that tag. diff --git a/src/api/resources/unstable/resources/tags/types/index.ts b/src/api/resources/unstable/resources/tags/types/index.ts index 0188807b..f1b106ee 100644 --- a/src/api/resources/unstable/resources/tags/types/index.ts +++ b/src/api/resources/unstable/resources/tags/types/index.ts @@ -1,3 +1,3 @@ -export * from "./CreateTagRequestBody"; -export * from "./Tag"; -export * from "./TagBasic"; +export * from "./CreateTagRequestBody.js"; +export * from "./Tag.js"; +export * from "./TagBasic.js"; diff --git a/src/api/resources/unstable/resources/teams/client/Client.ts b/src/api/resources/unstable/resources/teams/client/Client.ts index 1a849930..c83adaf9 100644 --- a/src/api/resources/unstable/resources/teams/client/Client.ts +++ b/src/api/resources/unstable/resources/teams/client/Client.ts @@ -1,121 +1,71 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Teams { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace TeamsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Teams */ -export class Teams { - constructor(protected readonly _options: Teams.Options = {}) {} +export class TeamsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: TeamsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * This will return a list of team objects for the App. * - * @param {Teams.RequestOptions} requestOptions - Request-specific configuration. + * @param {TeamsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * * @example * await client.unstable.teams.listTeams() */ - public listTeams(requestOptions?: Teams.RequestOptions): core.HttpResponsePromise { + public listTeams( + requestOptions?: TeamsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listTeams(requestOptions)); } private async __listTeams( - requestOptions?: Teams.RequestOptions, + requestOptions?: TeamsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "teams", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.TeamList, rawResponse: _response.rawResponse }; @@ -137,28 +87,14 @@ export class Teams { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /teams."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/teams"); } /** * You can fetch the details of a single team, containing an array of admins that belong to this team. * * @param {Intercom.unstable.RetrieveTeamRequest} request - * @param {Teams.RequestOptions} requestOptions - Request-specific configuration. + * @param {TeamsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -170,40 +106,38 @@ export class Teams { */ public retrieveTeam( request: Intercom.unstable.RetrieveTeamRequest, - requestOptions?: Teams.RequestOptions, + requestOptions?: TeamsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__retrieveTeam(request, requestOptions)); } private async __retrieveTeam( request: Intercom.unstable.RetrieveTeamRequest, - requestOptions?: Teams.RequestOptions, + requestOptions?: TeamsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `teams/${encodeURIComponent(id)}`, + `teams/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Team, rawResponse: _response.rawResponse }; @@ -227,32 +161,6 @@ export class Teams { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /teams/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/teams/{id}"); } } diff --git a/src/api/resources/unstable/resources/teams/client/index.ts b/src/api/resources/unstable/resources/teams/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/teams/client/index.ts +++ b/src/api/resources/unstable/resources/teams/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/teams/client/requests/RetrieveTeamRequest.ts b/src/api/resources/unstable/resources/teams/client/requests/RetrieveTeamRequest.ts index 0b09296c..fd825fee 100644 --- a/src/api/resources/unstable/resources/teams/client/requests/RetrieveTeamRequest.ts +++ b/src/api/resources/unstable/resources/teams/client/requests/RetrieveTeamRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface RetrieveTeamRequest { - /** - * The unique identifier of a given team. - */ + /** The unique identifier of a given team. */ id: string; } diff --git a/src/api/resources/unstable/resources/teams/client/requests/index.ts b/src/api/resources/unstable/resources/teams/client/requests/index.ts index b8dd50a7..6497a22a 100644 --- a/src/api/resources/unstable/resources/teams/client/requests/index.ts +++ b/src/api/resources/unstable/resources/teams/client/requests/index.ts @@ -1 +1 @@ -export { type RetrieveTeamRequest } from "./RetrieveTeamRequest"; +export type { RetrieveTeamRequest } from "./RetrieveTeamRequest.js"; diff --git a/src/api/resources/unstable/resources/teams/index.ts b/src/api/resources/unstable/resources/teams/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/teams/index.ts +++ b/src/api/resources/unstable/resources/teams/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/teams/types/Team.ts b/src/api/resources/unstable/resources/teams/types/Team.ts index 8ba1d68f..412cc0d0 100644 --- a/src/api/resources/unstable/resources/teams/types/Team.ts +++ b/src/api/resources/unstable/resources/teams/types/Team.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * Teams are groups of admins in Intercom. diff --git a/src/api/resources/unstable/resources/teams/types/index.ts b/src/api/resources/unstable/resources/teams/types/index.ts index e3645596..bc100e99 100644 --- a/src/api/resources/unstable/resources/teams/types/index.ts +++ b/src/api/resources/unstable/resources/teams/types/index.ts @@ -1 +1 @@ -export * from "./Team"; +export * from "./Team.js"; diff --git a/src/api/resources/unstable/resources/ticketStates/client/Client.ts b/src/api/resources/unstable/resources/ticketStates/client/Client.ts index 9df86fd0..84960f00 100644 --- a/src/api/resources/unstable/resources/ticketStates/client/Client.ts +++ b/src/api/resources/unstable/resources/ticketStates/client/Client.ts @@ -1,84 +1,34 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace TicketStates { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace TicketStatesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your ticket states */ -export class TicketStates { - constructor(protected readonly _options: TicketStates.Options = {}) {} +export class TicketStatesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: TicketStatesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can get a list of all ticket states for a workspace. * - * @param {TicketStates.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketStatesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -86,38 +36,36 @@ export class TicketStates { * await client.unstable.ticketStates.listTicketStates() */ public listTicketStates( - requestOptions?: TicketStates.RequestOptions, + requestOptions?: TicketStatesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listTicketStates(requestOptions)); } private async __listTicketStates( - requestOptions?: TicketStates.RequestOptions, + requestOptions?: TicketStatesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "ticket_states", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.TicketStateList, rawResponse: _response.rawResponse }; @@ -139,32 +87,6 @@ export class TicketStates { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ticket_states."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/ticket_states"); } } diff --git a/src/api/resources/unstable/resources/ticketStates/index.ts b/src/api/resources/unstable/resources/ticketStates/index.ts index 5ec76921..914b8c3c 100644 --- a/src/api/resources/unstable/resources/ticketStates/index.ts +++ b/src/api/resources/unstable/resources/ticketStates/index.ts @@ -1 +1 @@ -export * from "./client"; +export * from "./client/index.js"; diff --git a/src/api/resources/unstable/resources/ticketTypeAttributes/client/Client.ts b/src/api/resources/unstable/resources/ticketTypeAttributes/client/Client.ts index 4db689cf..fe5a1095 100644 --- a/src/api/resources/unstable/resources/ticketTypeAttributes/client/Client.ts +++ b/src/api/resources/unstable/resources/ticketTypeAttributes/client/Client.ts @@ -1,85 +1,35 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace TicketTypeAttributes { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace TicketTypeAttributesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your ticket type attributes */ -export class TicketTypeAttributes { - constructor(protected readonly _options: TicketTypeAttributes.Options = {}) {} +export class TicketTypeAttributesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: TicketTypeAttributesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can create a new attribute for a ticket type. * * @param {Intercom.unstable.CreateTicketTypeAttributeRequest} request - * @param {TicketTypeAttributes.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketTypeAttributesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -94,41 +44,41 @@ export class TicketTypeAttributes { */ public createTicketTypeAttribute( request: Intercom.unstable.CreateTicketTypeAttributeRequest, - requestOptions?: TicketTypeAttributes.RequestOptions, + requestOptions?: TicketTypeAttributesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createTicketTypeAttribute(request, requestOptions)); } private async __createTicketTypeAttribute( request: Intercom.unstable.CreateTicketTypeAttributeRequest, - requestOptions?: TicketTypeAttributes.RequestOptions, + requestOptions?: TicketTypeAttributesClient.RequestOptions, ): Promise> { const { ticket_type_id: ticketTypeId, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ticket_types/${encodeURIComponent(ticketTypeId)}/attributes`, + `ticket_types/${core.url.encodePathParam(ticketTypeId)}/attributes`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -153,30 +103,19 @@ export class TicketTypeAttributes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling POST /ticket_types/{ticket_type_id}/attributes.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "POST", + "/ticket_types/{ticket_type_id}/attributes", + ); } /** * You can update an existing attribute for a ticket type. * * @param {Intercom.unstable.UpdateTicketTypeAttributeRequest} request - * @param {TicketTypeAttributes.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketTypeAttributesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -189,41 +128,41 @@ export class TicketTypeAttributes { */ public updateTicketTypeAttribute( request: Intercom.unstable.UpdateTicketTypeAttributeRequest, - requestOptions?: TicketTypeAttributes.RequestOptions, + requestOptions?: TicketTypeAttributesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__updateTicketTypeAttribute(request, requestOptions)); } private async __updateTicketTypeAttribute( request: Intercom.unstable.UpdateTicketTypeAttributeRequest, - requestOptions?: TicketTypeAttributes.RequestOptions, + requestOptions?: TicketTypeAttributesClient.RequestOptions, ): Promise> { const { ticket_type_id: ticketTypeId, id, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ticket_types/${encodeURIComponent(ticketTypeId)}/attributes/${encodeURIComponent(id)}`, + `ticket_types/${core.url.encodePathParam(ticketTypeId)}/attributes/${core.url.encodePathParam(id)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -248,34 +187,11 @@ export class TicketTypeAttributes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError( - "Timeout exceeded when calling PUT /ticket_types/{ticket_type_id}/attributes/{id}.", - ); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "PUT", + "/ticket_types/{ticket_type_id}/attributes/{id}", + ); } } diff --git a/src/api/resources/unstable/resources/ticketTypeAttributes/client/index.ts b/src/api/resources/unstable/resources/ticketTypeAttributes/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/ticketTypeAttributes/client/index.ts +++ b/src/api/resources/unstable/resources/ticketTypeAttributes/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/CreateTicketTypeAttributeRequest.ts b/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/CreateTicketTypeAttributeRequest.ts index 0a9604c1..6dbf0ac2 100644 --- a/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/CreateTicketTypeAttributeRequest.ts +++ b/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/CreateTicketTypeAttributeRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -13,9 +11,7 @@ * } */ export interface CreateTicketTypeAttributeRequest { - /** - * The unique identifier for the ticket type which is given by Intercom. - */ + /** The unique identifier for the ticket type which is given by Intercom. */ ticket_type_id: string; /** The name of the ticket type attribute */ name: string; @@ -40,10 +36,7 @@ export interface CreateTicketTypeAttributeRequest { } export namespace CreateTicketTypeAttributeRequest { - /** - * The data type of the attribute - */ - export type DataType = "string" | "list" | "integer" | "decimal" | "boolean" | "datetime" | "files"; + /** The data type of the attribute */ export const DataType = { String: "string", List: "list", @@ -53,4 +46,5 @@ export namespace CreateTicketTypeAttributeRequest { Datetime: "datetime", Files: "files", } as const; + export type DataType = (typeof DataType)[keyof typeof DataType]; } diff --git a/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/UpdateTicketTypeAttributeRequest.ts b/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/UpdateTicketTypeAttributeRequest.ts index 9575db2d..c56bbb7b 100644 --- a/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/UpdateTicketTypeAttributeRequest.ts +++ b/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/UpdateTicketTypeAttributeRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -11,13 +9,9 @@ * } */ export interface UpdateTicketTypeAttributeRequest { - /** - * The unique identifier for the ticket type which is given by Intercom. - */ + /** The unique identifier for the ticket type which is given by Intercom. */ ticket_type_id: string; - /** - * The unique identifier for the ticket type attribute which is given by Intercom. - */ + /** The unique identifier for the ticket type attribute which is given by Intercom. */ id: string; /** The name of the ticket type attribute */ name?: string; diff --git a/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/index.ts b/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/index.ts index b2d37564..2a2ffb63 100644 --- a/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/index.ts +++ b/src/api/resources/unstable/resources/ticketTypeAttributes/client/requests/index.ts @@ -1,2 +1,2 @@ -export { type CreateTicketTypeAttributeRequest } from "./CreateTicketTypeAttributeRequest"; -export { type UpdateTicketTypeAttributeRequest } from "./UpdateTicketTypeAttributeRequest"; +export type { CreateTicketTypeAttributeRequest } from "./CreateTicketTypeAttributeRequest.js"; +export type { UpdateTicketTypeAttributeRequest } from "./UpdateTicketTypeAttributeRequest.js"; diff --git a/src/api/resources/unstable/resources/ticketTypeAttributes/index.ts b/src/api/resources/unstable/resources/ticketTypeAttributes/index.ts index 5ec76921..914b8c3c 100644 --- a/src/api/resources/unstable/resources/ticketTypeAttributes/index.ts +++ b/src/api/resources/unstable/resources/ticketTypeAttributes/index.ts @@ -1 +1 @@ -export * from "./client"; +export * from "./client/index.js"; diff --git a/src/api/resources/unstable/resources/ticketTypes/client/Client.ts b/src/api/resources/unstable/resources/ticketTypes/client/Client.ts index 857fd1f7..1d1adfed 100644 --- a/src/api/resources/unstable/resources/ticketTypes/client/Client.ts +++ b/src/api/resources/unstable/resources/ticketTypes/client/Client.ts @@ -1,84 +1,34 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace TicketTypes { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace TicketTypesClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your ticket types */ -export class TicketTypes { - constructor(protected readonly _options: TicketTypes.Options = {}) {} +export class TicketTypesClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: TicketTypesClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can get a list of all ticket types for a workspace. * - * @param {TicketTypes.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketTypesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -86,38 +36,36 @@ export class TicketTypes { * await client.unstable.ticketTypes.listTicketTypes() */ public listTicketTypes( - requestOptions?: TicketTypes.RequestOptions, + requestOptions?: TicketTypesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__listTicketTypes(requestOptions)); } private async __listTicketTypes( - requestOptions?: TicketTypes.RequestOptions, + requestOptions?: TicketTypesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "ticket_types", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.TicketTypeList, rawResponse: _response.rawResponse }; @@ -139,21 +87,7 @@ export class TicketTypes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ticket_types."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/ticket_types"); } /** @@ -164,7 +98,7 @@ export class TicketTypes { * > For the `icon` propery, use an emoji from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) * * @param {unknown} request - * @param {TicketTypes.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketTypesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -175,40 +109,40 @@ export class TicketTypes { */ public createTicketType( request?: unknown, - requestOptions?: TicketTypes.RequestOptions, + requestOptions?: TicketTypesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__createTicketType(request, requestOptions)); } private async __createTicketType( request?: unknown, - requestOptions?: TicketTypes.RequestOptions, + requestOptions?: TicketTypesClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "ticket_types", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -233,28 +167,14 @@ export class TicketTypes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /ticket_types."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/ticket_types"); } /** * You can fetch the details of a single ticket type. * * @param {Intercom.unstable.GetTicketTypeRequest} request - * @param {TicketTypes.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketTypesClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -265,40 +185,38 @@ export class TicketTypes { */ public getTicketType( request: Intercom.unstable.GetTicketTypeRequest, - requestOptions?: TicketTypes.RequestOptions, + requestOptions?: TicketTypesClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__getTicketType(request, requestOptions)); } private async __getTicketType( request: Intercom.unstable.GetTicketTypeRequest, - requestOptions?: TicketTypes.RequestOptions, + requestOptions?: TicketTypesClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `ticket_types/${encodeURIComponent(id)}`, + `ticket_types/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -323,32 +241,6 @@ export class TicketTypes { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /ticket_types/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/ticket_types/{id}"); } } diff --git a/src/api/resources/unstable/resources/ticketTypes/client/index.ts b/src/api/resources/unstable/resources/ticketTypes/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/ticketTypes/client/index.ts +++ b/src/api/resources/unstable/resources/ticketTypes/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/ticketTypes/client/requests/GetTicketTypeRequest.ts b/src/api/resources/unstable/resources/ticketTypes/client/requests/GetTicketTypeRequest.ts index b9868adc..542c28d9 100644 --- a/src/api/resources/unstable/resources/ticketTypes/client/requests/GetTicketTypeRequest.ts +++ b/src/api/resources/unstable/resources/ticketTypes/client/requests/GetTicketTypeRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface GetTicketTypeRequest { - /** - * The unique identifier for the ticket type which is given by Intercom. - */ + /** The unique identifier for the ticket type which is given by Intercom. */ id: string; } diff --git a/src/api/resources/unstable/resources/ticketTypes/client/requests/index.ts b/src/api/resources/unstable/resources/ticketTypes/client/requests/index.ts index c25063a7..0ece78d7 100644 --- a/src/api/resources/unstable/resources/ticketTypes/client/requests/index.ts +++ b/src/api/resources/unstable/resources/ticketTypes/client/requests/index.ts @@ -1 +1 @@ -export { type GetTicketTypeRequest } from "./GetTicketTypeRequest"; +export type { GetTicketTypeRequest } from "./GetTicketTypeRequest.js"; diff --git a/src/api/resources/unstable/resources/ticketTypes/index.ts b/src/api/resources/unstable/resources/ticketTypes/index.ts index 5ec76921..914b8c3c 100644 --- a/src/api/resources/unstable/resources/ticketTypes/index.ts +++ b/src/api/resources/unstable/resources/ticketTypes/index.ts @@ -1 +1 @@ -export * from "./client"; +export * from "./client/index.js"; diff --git a/src/api/resources/unstable/resources/tickets/client/Client.ts b/src/api/resources/unstable/resources/tickets/client/Client.ts index 116eed02..4c28d71b 100644 --- a/src/api/resources/unstable/resources/tickets/client/Client.ts +++ b/src/api/resources/unstable/resources/tickets/client/Client.ts @@ -1,85 +1,35 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Tickets { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace TicketsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your tickets */ -export class Tickets { - constructor(protected readonly _options: Tickets.Options = {}) {} +export class TicketsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: TicketsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can reply to a ticket with a message from an admin or on behalf of a contact, or with a note for admins. * * @param {Intercom.unstable.ReplyTicketRequest} request - * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -137,41 +87,41 @@ export class Tickets { */ public replyTicket( request: Intercom.unstable.ReplyTicketRequest, - requestOptions?: Tickets.RequestOptions, + requestOptions?: TicketsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__replyTicket(request, requestOptions)); } private async __replyTicket( request: Intercom.unstable.ReplyTicketRequest, - requestOptions?: Tickets.RequestOptions, + requestOptions?: TicketsClient.RequestOptions, ): Promise> { const { id, body: _body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(id)}/reply`, + `tickets/${core.url.encodePathParam(id)}/reply`, ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.TicketReply, rawResponse: _response.rawResponse }; @@ -197,28 +147,14 @@ export class Tickets { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/{id}/reply."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/tickets/{id}/reply"); } /** * Enqueues ticket creation for asynchronous processing, returning if the job was enqueued successfully to be processed. We attempt to perform a best-effort validation on inputs before tasks are enqueued. If the given parameters are incorrect, we won't enqueue the job. * * @param {Intercom.unstable.EnqueueCreateTicketRequest} request - * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -233,40 +169,40 @@ export class Tickets { */ public enqueueCreateTicket( request: Intercom.unstable.EnqueueCreateTicketRequest, - requestOptions?: Tickets.RequestOptions, + requestOptions?: TicketsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__enqueueCreateTicket(request, requestOptions)); } private async __enqueueCreateTicket( request: Intercom.unstable.EnqueueCreateTicketRequest, - requestOptions?: Tickets.RequestOptions, + requestOptions?: TicketsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "tickets/enqueue", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Jobs, rawResponse: _response.rawResponse }; @@ -290,28 +226,14 @@ export class Tickets { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/enqueue."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/tickets/enqueue"); } /** * You can fetch the details of a single ticket. * * @param {Intercom.unstable.GetTicketRequest} request - * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -322,40 +244,38 @@ export class Tickets { */ public getTicket( request: Intercom.unstable.GetTicketRequest, - requestOptions?: Tickets.RequestOptions, + requestOptions?: TicketsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__getTicket(request, requestOptions)); } private async __getTicket( request: Intercom.unstable.GetTicketRequest, - requestOptions?: Tickets.RequestOptions, + requestOptions?: TicketsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(id)}`, + `tickets/${core.url.encodePathParam(id)}`, ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Ticket | undefined, rawResponse: _response.rawResponse }; @@ -377,28 +297,14 @@ export class Tickets { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /tickets/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/tickets/{id}"); } /** * You can update a ticket. * * @param {Intercom.unstable.UpdateTicketRequest} request - * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.BadRequestError} * @throws {@link Intercom.unstable.UnauthorizedError} @@ -438,41 +344,41 @@ export class Tickets { */ public updateTicket( request: Intercom.unstable.UpdateTicketRequest, - requestOptions?: Tickets.RequestOptions, + requestOptions?: TicketsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__updateTicket(request, requestOptions)); } private async __updateTicket( request: Intercom.unstable.UpdateTicketRequest, - requestOptions?: Tickets.RequestOptions, + requestOptions?: TicketsClient.RequestOptions, ): Promise> { const { id, ..._body } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(id)}`, + `tickets/${core.url.encodePathParam(id)}`, ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: _body, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Ticket | undefined, rawResponse: _response.rawResponse }; @@ -498,28 +404,14 @@ export class Tickets { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /tickets/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/tickets/{id}"); } /** * You can delete a ticket using the Intercom provided ID. * * @param {Intercom.unstable.DeleteTicketRequest} request - * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -531,40 +423,38 @@ export class Tickets { */ public deleteTicket( request: Intercom.unstable.DeleteTicketRequest, - requestOptions?: Tickets.RequestOptions, + requestOptions?: TicketsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__deleteTicket(request, requestOptions)); } private async __deleteTicket( request: Intercom.unstable.DeleteTicketRequest, - requestOptions?: Tickets.RequestOptions, + requestOptions?: TicketsClient.RequestOptions, ): Promise> { const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, - `tickets/${encodeURIComponent(id)}`, + `tickets/${core.url.encodePathParam(id)}`, ), method: "DELETE", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -591,21 +481,7 @@ export class Tickets { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling DELETE /tickets/{id}."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/tickets/{id}"); } /** @@ -638,8 +514,8 @@ export class Tickets { * | id | String | * | created_at | Date (UNIX timestamp) | * | updated_at | Date (UNIX timestamp) | - * | _default_title_ | String | - * | _default_description_ | String | + * | title | String | + * | description | String | * | category | String | * | ticket_type_id | String | * | contact_ids | String | @@ -651,6 +527,13 @@ export class Tickets { * | snoozed_until | Date (UNIX timestamp) | * | ticket_attribute.{id} | String or Boolean or Date (UNIX timestamp) or Float or Integer | * + * {% admonition type="info" name="Searching by Category" %} + * When searching for tickets by the **`category`** field, specific terms must be used instead of the category names: + * * For **Customer** category tickets, use the term `request`. + * * For **Back-office** category tickets, use the term `task`. + * * For **Tracker** category tickets, use the term `tracker`. + * {% /admonition %} + * * ### Accepted Operators * * {% admonition type="info" name="Searching based on `created_at`" %} @@ -673,7 +556,7 @@ export class Tickets { * | $ | String | Ends With | * * @param {Intercom.unstable.SearchRequest} request - * @param {Tickets.RequestOptions} requestOptions - Request-specific configuration. + * @param {TicketsClient.RequestOptions} requestOptions - Request-specific configuration. * * @example * await client.unstable.tickets.searchTickets({ @@ -692,40 +575,40 @@ export class Tickets { */ public searchTickets( request: Intercom.unstable.SearchRequest, - requestOptions?: Tickets.RequestOptions, + requestOptions?: TicketsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__searchTickets(request, requestOptions)); } private async __searchTickets( request: Intercom.unstable.SearchRequest, - requestOptions?: Tickets.RequestOptions, + requestOptions?: TicketsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "tickets/search", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.TicketList, rawResponse: _response.rawResponse }; @@ -739,32 +622,6 @@ export class Tickets { }); } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /tickets/search."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/tickets/search"); } } diff --git a/src/api/resources/unstable/resources/tickets/client/index.ts b/src/api/resources/unstable/resources/tickets/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/tickets/client/index.ts +++ b/src/api/resources/unstable/resources/tickets/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/tickets/client/requests/DeleteTicketRequest.ts b/src/api/resources/unstable/resources/tickets/client/requests/DeleteTicketRequest.ts index 3a9f96f8..8ea2c5e7 100644 --- a/src/api/resources/unstable/resources/tickets/client/requests/DeleteTicketRequest.ts +++ b/src/api/resources/unstable/resources/tickets/client/requests/DeleteTicketRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface DeleteTicketRequest { - /** - * The unique identifier for the ticket which is given by Intercom. - */ + /** The unique identifier for the ticket which is given by Intercom. */ id: string; } diff --git a/src/api/resources/unstable/resources/tickets/client/requests/EnqueueCreateTicketRequest.ts b/src/api/resources/unstable/resources/tickets/client/requests/EnqueueCreateTicketRequest.ts index d1d3b5ee..74d72736 100644 --- a/src/api/resources/unstable/resources/tickets/client/requests/EnqueueCreateTicketRequest.ts +++ b/src/api/resources/unstable/resources/tickets/client/requests/EnqueueCreateTicketRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example diff --git a/src/api/resources/unstable/resources/tickets/client/requests/GetTicketRequest.ts b/src/api/resources/unstable/resources/tickets/client/requests/GetTicketRequest.ts index ea0795f8..c48305e2 100644 --- a/src/api/resources/unstable/resources/tickets/client/requests/GetTicketRequest.ts +++ b/src/api/resources/unstable/resources/tickets/client/requests/GetTicketRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface GetTicketRequest { - /** - * The unique identifier for the ticket which is given by Intercom. - */ + /** The unique identifier for the ticket which is given by Intercom. */ id: string; } diff --git a/src/api/resources/unstable/resources/tickets/client/requests/ReplyTicketRequest.ts b/src/api/resources/unstable/resources/tickets/client/requests/ReplyTicketRequest.ts index ae8e6378..1e53f5d6 100644 --- a/src/api/resources/unstable/resources/tickets/client/requests/ReplyTicketRequest.ts +++ b/src/api/resources/unstable/resources/tickets/client/requests/ReplyTicketRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../../index"; +import type * as Intercom from "../../../../../../index.js"; /** * @example diff --git a/src/api/resources/unstable/resources/tickets/client/requests/UpdateTicketRequest.ts b/src/api/resources/unstable/resources/tickets/client/requests/UpdateTicketRequest.ts index 28c7e40f..63d68d08 100644 --- a/src/api/resources/unstable/resources/tickets/client/requests/UpdateTicketRequest.ts +++ b/src/api/resources/unstable/resources/tickets/client/requests/UpdateTicketRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -48,9 +46,7 @@ * } */ export interface UpdateTicketRequest { - /** - * The unique identifier for the ticket which is given by Intercom - */ + /** The unique identifier for the ticket which is given by Intercom */ id: string; /** The attributes set on the ticket. */ ticket_attributes?: Record; diff --git a/src/api/resources/unstable/resources/tickets/client/requests/index.ts b/src/api/resources/unstable/resources/tickets/client/requests/index.ts index b6a892f9..8f0e8032 100644 --- a/src/api/resources/unstable/resources/tickets/client/requests/index.ts +++ b/src/api/resources/unstable/resources/tickets/client/requests/index.ts @@ -1,5 +1,5 @@ -export { type ReplyTicketRequest } from "./ReplyTicketRequest"; -export { type EnqueueCreateTicketRequest } from "./EnqueueCreateTicketRequest"; -export { type GetTicketRequest } from "./GetTicketRequest"; -export { type UpdateTicketRequest } from "./UpdateTicketRequest"; -export { type DeleteTicketRequest } from "./DeleteTicketRequest"; +export type { DeleteTicketRequest } from "./DeleteTicketRequest.js"; +export type { EnqueueCreateTicketRequest } from "./EnqueueCreateTicketRequest.js"; +export type { GetTicketRequest } from "./GetTicketRequest.js"; +export type { ReplyTicketRequest } from "./ReplyTicketRequest.js"; +export type { UpdateTicketRequest } from "./UpdateTicketRequest.js"; diff --git a/src/api/resources/unstable/resources/tickets/index.ts b/src/api/resources/unstable/resources/tickets/index.ts index c9240f83..d9adb1af 100644 --- a/src/api/resources/unstable/resources/tickets/index.ts +++ b/src/api/resources/unstable/resources/tickets/index.ts @@ -1,2 +1,2 @@ -export * from "./types"; -export * from "./client"; +export * from "./client/index.js"; +export * from "./types/index.js"; diff --git a/src/api/resources/unstable/resources/tickets/types/DeleteTicketResponse.ts b/src/api/resources/unstable/resources/tickets/types/DeleteTicketResponse.ts index 579725c6..cdad7f2d 100644 --- a/src/api/resources/unstable/resources/tickets/types/DeleteTicketResponse.ts +++ b/src/api/resources/unstable/resources/tickets/types/DeleteTicketResponse.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Response when a ticket is deleted. diff --git a/src/api/resources/unstable/resources/tickets/types/ReplyTicketRequestBody.ts b/src/api/resources/unstable/resources/tickets/types/ReplyTicketRequestBody.ts index 3f2ede0c..cc0d3384 100644 --- a/src/api/resources/unstable/resources/tickets/types/ReplyTicketRequestBody.ts +++ b/src/api/resources/unstable/resources/tickets/types/ReplyTicketRequestBody.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; export type ReplyTicketRequestBody = | Intercom.unstable.ContactReplyTicketRequest diff --git a/src/api/resources/unstable/resources/tickets/types/Ticket.ts b/src/api/resources/unstable/resources/tickets/types/Ticket.ts index 45defe9b..1da56448 100644 --- a/src/api/resources/unstable/resources/tickets/types/Ticket.ts +++ b/src/api/resources/unstable/resources/tickets/types/Ticket.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * Tickets are how you track requests from your users. @@ -39,13 +37,11 @@ export interface Ticket { } export namespace Ticket { - /** - * Category of the Ticket. - */ - export type Category = "Customer" | "Back-office" | "Tracker"; + /** Category of the Ticket. */ export const Category = { Customer: "Customer", BackOffice: "Back-office", Tracker: "Tracker", } as const; + export type Category = (typeof Category)[keyof typeof Category]; } diff --git a/src/api/resources/unstable/resources/tickets/types/TicketContacts.ts b/src/api/resources/unstable/resources/tickets/types/TicketContacts.ts index e025dd66..f85afa9f 100644 --- a/src/api/resources/unstable/resources/tickets/types/TicketContacts.ts +++ b/src/api/resources/unstable/resources/tickets/types/TicketContacts.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * The list of contacts affected by a ticket. diff --git a/src/api/resources/unstable/resources/tickets/types/TicketPart.ts b/src/api/resources/unstable/resources/tickets/types/TicketPart.ts index 9153bf31..6ab9ce04 100644 --- a/src/api/resources/unstable/resources/tickets/types/TicketPart.ts +++ b/src/api/resources/unstable/resources/tickets/types/TicketPart.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * A Ticket Part represents a message in the ticket. @@ -40,26 +38,22 @@ export interface TicketPart { } export namespace TicketPart { - /** - * The previous state of the ticket. - */ - export type PreviousTicketState = "submitted" | "in_progress" | "waiting_on_customer" | "resolved"; + /** The previous state of the ticket. */ export const PreviousTicketState = { Submitted: "submitted", InProgress: "in_progress", WaitingOnCustomer: "waiting_on_customer", Resolved: "resolved", } as const; - /** - * The state of the ticket. - */ - export type TicketState = "submitted" | "in_progress" | "waiting_on_customer" | "resolved"; + export type PreviousTicketState = (typeof PreviousTicketState)[keyof typeof PreviousTicketState]; + /** The state of the ticket. */ export const TicketState = { Submitted: "submitted", InProgress: "in_progress", WaitingOnCustomer: "waiting_on_customer", Resolved: "resolved", } as const; + export type TicketState = (typeof TicketState)[keyof typeof TicketState]; /** * The updated attribute data of the ticket part. Only present for attribute update parts. diff --git a/src/api/resources/unstable/resources/tickets/types/TicketState.ts b/src/api/resources/unstable/resources/tickets/types/TicketState.ts index 70427191..beef89c7 100644 --- a/src/api/resources/unstable/resources/tickets/types/TicketState.ts +++ b/src/api/resources/unstable/resources/tickets/types/TicketState.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A ticket state, used to define the state of a ticket. @@ -19,14 +17,12 @@ export interface TicketState { } export namespace TicketState { - /** - * The category of the ticket state - */ - export type Category = "submitted" | "in_progress" | "waiting_on_customer" | "resolved"; + /** The category of the ticket state */ export const Category = { Submitted: "submitted", InProgress: "in_progress", WaitingOnCustomer: "waiting_on_customer", Resolved: "resolved", } as const; + export type Category = (typeof Category)[keyof typeof Category]; } diff --git a/src/api/resources/unstable/resources/tickets/types/TicketStateDetailed.ts b/src/api/resources/unstable/resources/tickets/types/TicketStateDetailed.ts index 2502a84b..1281034c 100644 --- a/src/api/resources/unstable/resources/tickets/types/TicketStateDetailed.ts +++ b/src/api/resources/unstable/resources/tickets/types/TicketStateDetailed.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * A ticket state, used to define the state of a ticket. @@ -25,16 +23,14 @@ export interface TicketStateDetailed { } export namespace TicketStateDetailed { - /** - * The category of the ticket state - */ - export type Category = "submitted" | "in_progress" | "waiting_on_customer" | "resolved"; + /** The category of the ticket state */ export const Category = { Submitted: "submitted", InProgress: "in_progress", WaitingOnCustomer: "waiting_on_customer", Resolved: "resolved", } as const; + export type Category = (typeof Category)[keyof typeof Category]; /** * A list of ticket types associated with a given ticket state. diff --git a/src/api/resources/unstable/resources/tickets/types/TicketType.ts b/src/api/resources/unstable/resources/tickets/types/TicketType.ts index 3af90517..bdb7bae4 100644 --- a/src/api/resources/unstable/resources/tickets/types/TicketType.ts +++ b/src/api/resources/unstable/resources/tickets/types/TicketType.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../../index"; +import type * as Intercom from "../../../../../index.js"; /** * A ticket type, used to define the data fields to be captured in a ticket. @@ -34,15 +32,13 @@ export interface TicketType { } export namespace TicketType { - /** - * Category of the Ticket Type. - */ - export type Category = "Customer" | "Back-office" | "Tracker"; + /** Category of the Ticket Type. */ export const Category = { Customer: "Customer", BackOffice: "Back-office", Tracker: "Tracker", } as const; + export type Category = (typeof Category)[keyof typeof Category]; /** * A list of ticket states associated with a given ticket type. diff --git a/src/api/resources/unstable/resources/tickets/types/index.ts b/src/api/resources/unstable/resources/tickets/types/index.ts index 5c6f7a46..5cad94df 100644 --- a/src/api/resources/unstable/resources/tickets/types/index.ts +++ b/src/api/resources/unstable/resources/tickets/types/index.ts @@ -1,8 +1,8 @@ -export * from "./ReplyTicketRequestBody"; -export * from "./DeleteTicketResponse"; -export * from "./Ticket"; -export * from "./TicketContacts"; -export * from "./TicketPart"; -export * from "./TicketState"; -export * from "./TicketStateDetailed"; -export * from "./TicketType"; +export * from "./DeleteTicketResponse.js"; +export * from "./ReplyTicketRequestBody.js"; +export * from "./Ticket.js"; +export * from "./TicketContacts.js"; +export * from "./TicketPart.js"; +export * from "./TicketState.js"; +export * from "./TicketStateDetailed.js"; +export * from "./TicketType.js"; diff --git a/src/api/resources/unstable/resources/visitors/client/Client.ts b/src/api/resources/unstable/resources/visitors/client/Client.ts index ef6e2e8a..600ffecf 100644 --- a/src/api/resources/unstable/resources/visitors/client/Client.ts +++ b/src/api/resources/unstable/resources/visitors/client/Client.ts @@ -1,85 +1,35 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../../../environments"; -import * as core from "../../../../../../core"; -import * as Intercom from "../../../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; -export declare namespace Visitors { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace VisitorsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Visitors */ -export class Visitors { - constructor(protected readonly _options: Visitors.Options = {}) {} +export class VisitorsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: VisitorsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch the details of a single visitor. * * @param {Intercom.unstable.RetrieveVisitorWithUserIdRequest} request - * @param {Visitors.RequestOptions} requestOptions - Request-specific configuration. + * @param {VisitorsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -91,43 +41,40 @@ export class Visitors { */ public retrieveVisitorWithUserId( request: Intercom.unstable.RetrieveVisitorWithUserIdRequest, - requestOptions?: Visitors.RequestOptions, + requestOptions?: VisitorsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__retrieveVisitorWithUserId(request, requestOptions)); } private async __retrieveVisitorWithUserId( request: Intercom.unstable.RetrieveVisitorWithUserIdRequest, - requestOptions?: Visitors.RequestOptions, + requestOptions?: VisitorsClient.RequestOptions, ): Promise> { const { user_id: userId } = request; const _queryParams: Record = {}; - _queryParams["user_id"] = userId; + _queryParams.user_id = userId; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "visitors", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -154,21 +101,7 @@ export class Visitors { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /visitors."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/visitors"); } /** @@ -179,7 +112,7 @@ export class Visitors { * **Option 2.** You can update a visitor by passing in the `id` of the visitor in the Request body. * * @param {Intercom.UpdateVisitorRequestOne} request - * @param {Visitors.RequestOptions} requestOptions - Request-specific configuration. + * @param {VisitorsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @throws {@link Intercom.unstable.NotFoundError} @@ -198,40 +131,40 @@ export class Visitors { */ public updateVisitor( request?: Intercom.UpdateVisitorRequestOne, - requestOptions?: Visitors.RequestOptions, + requestOptions?: VisitorsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__updateVisitor(request, requestOptions)); } private async __updateVisitor( request?: Intercom.UpdateVisitorRequestOne, - requestOptions?: Visitors.RequestOptions, + requestOptions?: VisitorsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "visitors", ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { @@ -258,21 +191,7 @@ export class Visitors { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /visitors."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/visitors"); } /** @@ -283,7 +202,7 @@ export class Visitors { * > If the User exists, then the Visitor will be merged into it, the Visitor deleted and the User returned. If the User does not exist, the Visitor will be converted to a User, with the User identifiers replacing it's Visitor identifiers. * * @param {Intercom.unstable.ConvertVisitorRequest} request - * @param {Visitors.RequestOptions} requestOptions - Request-specific configuration. + * @param {VisitorsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.unstable.UnauthorizedError} * @@ -300,40 +219,40 @@ export class Visitors { */ public convertVisitor( request: Intercom.unstable.ConvertVisitorRequest, - requestOptions?: Visitors.RequestOptions, + requestOptions?: VisitorsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__convertVisitor(request, requestOptions)); } private async __convertVisitor( request: Intercom.unstable.ConvertVisitorRequest, - requestOptions?: Visitors.RequestOptions, + requestOptions?: VisitorsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "visitors/convert", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.unstable.Contact, rawResponse: _response.rawResponse }; @@ -355,32 +274,6 @@ export class Visitors { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /visitors/convert."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/visitors/convert"); } } diff --git a/src/api/resources/unstable/resources/visitors/client/index.ts b/src/api/resources/unstable/resources/visitors/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/unstable/resources/visitors/client/index.ts +++ b/src/api/resources/unstable/resources/visitors/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/visitors/client/requests/ConvertVisitorRequest.ts b/src/api/resources/unstable/resources/visitors/client/requests/ConvertVisitorRequest.ts index 275e76e7..0dceb82c 100644 --- a/src/api/resources/unstable/resources/visitors/client/requests/ConvertVisitorRequest.ts +++ b/src/api/resources/unstable/resources/visitors/client/requests/ConvertVisitorRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example diff --git a/src/api/resources/unstable/resources/visitors/client/requests/RetrieveVisitorWithUserIdRequest.ts b/src/api/resources/unstable/resources/visitors/client/requests/RetrieveVisitorWithUserIdRequest.ts index 27554599..cd10d234 100644 --- a/src/api/resources/unstable/resources/visitors/client/requests/RetrieveVisitorWithUserIdRequest.ts +++ b/src/api/resources/unstable/resources/visitors/client/requests/RetrieveVisitorWithUserIdRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface RetrieveVisitorWithUserIdRequest { - /** - * The user_id of the Visitor you want to retrieve. - */ + /** The user_id of the Visitor you want to retrieve. */ user_id: string; } diff --git a/src/api/resources/unstable/resources/visitors/client/requests/index.ts b/src/api/resources/unstable/resources/visitors/client/requests/index.ts index 8878667c..a1b1278e 100644 --- a/src/api/resources/unstable/resources/visitors/client/requests/index.ts +++ b/src/api/resources/unstable/resources/visitors/client/requests/index.ts @@ -1,2 +1,2 @@ -export { type RetrieveVisitorWithUserIdRequest } from "./RetrieveVisitorWithUserIdRequest"; -export { type ConvertVisitorRequest } from "./ConvertVisitorRequest"; +export type { ConvertVisitorRequest } from "./ConvertVisitorRequest.js"; +export type { RetrieveVisitorWithUserIdRequest } from "./RetrieveVisitorWithUserIdRequest.js"; diff --git a/src/api/resources/unstable/resources/visitors/index.ts b/src/api/resources/unstable/resources/visitors/index.ts index 5ec76921..914b8c3c 100644 --- a/src/api/resources/unstable/resources/visitors/index.ts +++ b/src/api/resources/unstable/resources/visitors/index.ts @@ -1 +1 @@ -export * from "./client"; +export * from "./client/index.js"; diff --git a/src/api/resources/unstable/types/ActivityLog.ts b/src/api/resources/unstable/types/ActivityLog.ts index 1815ce24..e510cac9 100644 --- a/src/api/resources/unstable/types/ActivityLog.ts +++ b/src/api/resources/unstable/types/ActivityLog.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Activities performed by Admins. @@ -35,76 +33,9 @@ export namespace ActivityLog { ip?: string; } - export type ActivityType = - | "admin_assignment_limit_change" - | "admin_away_mode_change" - | "admin_deletion" - | "admin_deprovisioned" - | "admin_impersonation_end" - | "admin_impersonation_start" - | "admin_invite_change" - | "admin_invite_creation" - | "admin_invite_deletion" - | "admin_login_failure" - | "admin_login_success" - | "admin_logout" - | "admin_password_reset_request" - | "admin_password_reset_success" - | "admin_permission_change" - | "admin_provisioned" - | "admin_two_factor_auth_change" - | "admin_unauthorized_sign_in_method" - | "app_admin_join" - | "app_authentication_method_change" - | "app_data_deletion" - | "app_data_export" - | "app_google_sso_domain_change" - | "app_identity_verification_change" - | "app_name_change" - | "app_outbound_address_change" - | "app_package_installation" - | "app_package_token_regeneration" - | "app_package_uninstallation" - | "app_team_creation" - | "app_team_deletion" - | "app_team_membership_modification" - | "app_timezone_change" - | "app_webhook_creation" - | "app_webhook_deletion" - | "articles_in_messenger_enabled_change" - | "bulk_delete" - | "bulk_export" - | "campaign_deletion" - | "campaign_state_change" - | "conversation_part_deletion" - | "conversation_topic_change" - | "conversation_topic_creation" - | "conversation_topic_deletion" - | "help_center_settings_change" - | "inbound_conversations_change" - | "inbox_access_change" - | "message_deletion" - | "message_state_change" - | "messenger_look_and_feel_change" - | "messenger_search_required_change" - | "messenger_spaces_change" - | "office_hours_change" - | "role_change" - | "role_creation" - | "role_deletion" - | "ruleset_activation_title_preview" - | "ruleset_creation" - | "ruleset_deletion" - | "search_browse_enabled_change" - | "search_browse_required_change" - | "seat_change" - | "seat_revoke" - | "security_settings_change" - | "temporary_expectation_change" - | "upfront_email_collection_change" - | "welcome_message_change"; export const ActivityType = { - AdminAssignmentLimitChange: "admin_assignment_limit_change", + AdminConversationAssignmentLimitChange: "admin_conversation_assignment_limit_change", + AdminTicketAssignmentLimitChange: "admin_ticket_assignment_limit_change", AdminAwayModeChange: "admin_away_mode_change", AdminDeletion: "admin_deletion", AdminDeprovisioned: "admin_deprovisioned", @@ -172,4 +103,5 @@ export namespace ActivityLog { UpfrontEmailCollectionChange: "upfront_email_collection_change", WelcomeMessageChange: "welcome_message_change", } as const; + export type ActivityType = (typeof ActivityType)[keyof typeof ActivityType]; } diff --git a/src/api/resources/unstable/types/ActivityLogList.ts b/src/api/resources/unstable/types/ActivityLogList.ts index 7c9d4e57..f570390b 100644 --- a/src/api/resources/unstable/types/ActivityLogList.ts +++ b/src/api/resources/unstable/types/ActivityLogList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A paginated list of activity logs. diff --git a/src/api/resources/unstable/types/ActivityLogMetadata.ts b/src/api/resources/unstable/types/ActivityLogMetadata.ts index 4814d8e5..cbd7324e 100644 --- a/src/api/resources/unstable/types/ActivityLogMetadata.ts +++ b/src/api/resources/unstable/types/ActivityLogMetadata.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Additional data provided about Admin activity. @@ -24,4 +22,8 @@ export interface ActivityLogMetadata { update_by?: number; /** The name of the Admin who initiated the activity. */ update_by_name?: string; + /** The conversation assignment limit value for an admin. */ + conversation_assignment_limit?: number; + /** The ticket assignment limit value for an admin. */ + ticket_assignment_limit?: number; } diff --git a/src/api/resources/unstable/types/AddressableList.ts b/src/api/resources/unstable/types/AddressableList.ts index 787be0f6..cbda5a63 100644 --- a/src/api/resources/unstable/types/AddressableList.ts +++ b/src/api/resources/unstable/types/AddressableList.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A list used to access other resources from a parent model. diff --git a/src/api/resources/unstable/types/AdminList.ts b/src/api/resources/unstable/types/AdminList.ts index b5fc73d2..01507d8d 100644 --- a/src/api/resources/unstable/types/AdminList.ts +++ b/src/api/resources/unstable/types/AdminList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of admins associated with a given workspace. diff --git a/src/api/resources/unstable/types/AdminPriorityLevel.ts b/src/api/resources/unstable/types/AdminPriorityLevel.ts index 659f95f2..1127dadf 100644 --- a/src/api/resources/unstable/types/AdminPriorityLevel.ts +++ b/src/api/resources/unstable/types/AdminPriorityLevel.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Admin priority levels for the team diff --git a/src/api/resources/unstable/types/AdminReplyConversationRequest.ts b/src/api/resources/unstable/types/AdminReplyConversationRequest.ts index b0bcb16c..cf90c85b 100644 --- a/src/api/resources/unstable/types/AdminReplyConversationRequest.ts +++ b/src/api/resources/unstable/types/AdminReplyConversationRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Payload of the request to reply on behalf of an admin @@ -25,10 +23,10 @@ export interface AdminReplyConversationRequest { } export namespace AdminReplyConversationRequest { - export type MessageType = "comment" | "note" | "quick_reply"; export const MessageType = { Comment: "comment", Note: "note", QuickReply: "quick_reply", } as const; + export type MessageType = (typeof MessageType)[keyof typeof MessageType]; } diff --git a/src/api/resources/unstable/types/AdminReplyTicketRequest.ts b/src/api/resources/unstable/types/AdminReplyTicketRequest.ts index dfc2ae57..3e2ac1ed 100644 --- a/src/api/resources/unstable/types/AdminReplyTicketRequest.ts +++ b/src/api/resources/unstable/types/AdminReplyTicketRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Payload of the request to reply on behalf of an admin @@ -21,12 +19,12 @@ export interface AdminReplyTicketRequest { } export namespace AdminReplyTicketRequest { - export type MessageType = "comment" | "note" | "quick_reply"; export const MessageType = { Comment: "comment", Note: "note", QuickReply: "quick_reply", } as const; + export type MessageType = (typeof MessageType)[keyof typeof MessageType]; export type ReplyOptions = ReplyOptions.Item[]; export namespace ReplyOptions { diff --git a/src/api/resources/unstable/types/AdminWithApp.ts b/src/api/resources/unstable/types/AdminWithApp.ts index 4d7f69ed..37c0c32c 100644 --- a/src/api/resources/unstable/types/AdminWithApp.ts +++ b/src/api/resources/unstable/types/AdminWithApp.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Admins are the teammate accounts that have access to a workspace diff --git a/src/api/resources/unstable/types/AiCallResponse.ts b/src/api/resources/unstable/types/AiCallResponse.ts new file mode 100644 index 00000000..6f90c177 --- /dev/null +++ b/src/api/resources/unstable/types/AiCallResponse.ts @@ -0,0 +1,27 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Response containing information about a Fin Voice call + */ +export interface AiCallResponse { + /** The unique identifier for the external reference */ + id?: number; + /** The workspace identifier */ + app_id?: number; + /** Phone number in E.164 format for the call */ + user_phone_number?: string; + /** Status of the call. Can be "registered", "in-progress", or a resolution state */ + status?: string; + /** The Intercom call identifier, if the call has been matched */ + intercom_call_id?: string; + /** The external call identifier from the call provider */ + external_call_id?: string; + /** The Intercom conversation identifier, if a conversation has been created */ + intercom_conversation_id?: string; + /** Array of transcript entries for the call */ + call_transcript?: Record[]; + /** Summary of the call conversation, truncated to 256 characters. Empty string if no summary available. */ + call_summary?: string; + /** Array of intent classifications for the call */ + intent?: Record[]; +} diff --git a/src/api/resources/unstable/types/App.ts b/src/api/resources/unstable/types/App.ts index fd2d8319..67ce2d3c 100644 --- a/src/api/resources/unstable/types/App.ts +++ b/src/api/resources/unstable/types/App.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * App is a workspace on Intercom diff --git a/src/api/resources/unstable/types/ArticleContent.ts b/src/api/resources/unstable/types/ArticleContent.ts index 31652500..bccb5af5 100644 --- a/src/api/resources/unstable/types/ArticleContent.ts +++ b/src/api/resources/unstable/types/ArticleContent.ts @@ -1,13 +1,11 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The Content of an Article. */ export interface ArticleContent { /** The type of object - `article_content` . */ - type?: string; + type?: "article_content"; /** The title of the article. */ title?: string; /** The description of the article. */ @@ -27,12 +25,10 @@ export interface ArticleContent { } export namespace ArticleContent { - /** - * Whether the article is `published` or is a `draft` . - */ - export type State = "published" | "draft"; + /** Whether the article is `published` or is a `draft` . */ export const State = { Published: "published", Draft: "draft", } as const; + export type State = (typeof State)[keyof typeof State]; } diff --git a/src/api/resources/unstable/types/ArticleList.ts b/src/api/resources/unstable/types/ArticleList.ts index 5dbc0a01..67d409ef 100644 --- a/src/api/resources/unstable/types/ArticleList.ts +++ b/src/api/resources/unstable/types/ArticleList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * This will return a list of articles for the App. diff --git a/src/api/resources/unstable/types/ArticleStatistics.ts b/src/api/resources/unstable/types/ArticleStatistics.ts index 2e12b7b3..16f14f48 100644 --- a/src/api/resources/unstable/types/ArticleStatistics.ts +++ b/src/api/resources/unstable/types/ArticleStatistics.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The statistics of an article. diff --git a/src/api/resources/unstable/types/ArticleTranslatedContent.ts b/src/api/resources/unstable/types/ArticleTranslatedContent.ts index 5e4e52bd..2e625936 100644 --- a/src/api/resources/unstable/types/ArticleTranslatedContent.ts +++ b/src/api/resources/unstable/types/ArticleTranslatedContent.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * The Translated Content of an Article. The keys are the locale codes and the values are the translated content of the article. */ export interface ArticleTranslatedContent { /** The type of object - article_translated_content. */ - type?: string; + type?: "article_translated_content"; /** The content of the article in Arabic */ ar?: Intercom.unstable.ArticleContent; /** The content of the article in Bulgarian */ diff --git a/src/api/resources/unstable/types/AssignConversationRequest.ts b/src/api/resources/unstable/types/AssignConversationRequest.ts index e3eef208..0e2e8ba8 100644 --- a/src/api/resources/unstable/types/AssignConversationRequest.ts +++ b/src/api/resources/unstable/types/AssignConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Payload of the request to assign a conversation @@ -16,9 +14,9 @@ export interface AssignConversationRequest { } export namespace AssignConversationRequest { - export type Type = "admin" | "team"; export const Type = { Admin: "admin", Team: "team", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } diff --git a/src/api/resources/unstable/types/AwayStatusReason.ts b/src/api/resources/unstable/types/AwayStatusReason.ts index 02f9e7a8..01eaf720 100644 --- a/src/api/resources/unstable/types/AwayStatusReason.ts +++ b/src/api/resources/unstable/types/AwayStatusReason.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export interface AwayStatusReason { type?: string; diff --git a/src/api/resources/unstable/types/CallList.ts b/src/api/resources/unstable/types/CallList.ts new file mode 100644 index 00000000..bd332337 --- /dev/null +++ b/src/api/resources/unstable/types/CallList.ts @@ -0,0 +1,16 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +/** + * A paginated list of calls. + */ +export interface CallList { + /** String representing the object's type. Always has the value `list`. */ + type?: string; + /** A list of calls. */ + data?: Intercom.unstable.Call[]; + /** Total number of items available. */ + total_count?: number; + pages?: Intercom.unstable.CursorPages; +} diff --git a/src/api/resources/unstable/types/CloseConversationRequest.ts b/src/api/resources/unstable/types/CloseConversationRequest.ts index 56f0755e..0c75f0c3 100644 --- a/src/api/resources/unstable/types/CloseConversationRequest.ts +++ b/src/api/resources/unstable/types/CloseConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Payload of the request to close a conversation diff --git a/src/api/resources/unstable/types/CollectionList.ts b/src/api/resources/unstable/types/CollectionList.ts index ee2bbe53..455ae28a 100644 --- a/src/api/resources/unstable/types/CollectionList.ts +++ b/src/api/resources/unstable/types/CollectionList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * This will return a list of Collections for the App. diff --git a/src/api/resources/unstable/types/CompanyAttachedContacts.ts b/src/api/resources/unstable/types/CompanyAttachedContacts.ts index c4490d96..d23643b4 100644 --- a/src/api/resources/unstable/types/CompanyAttachedContacts.ts +++ b/src/api/resources/unstable/types/CompanyAttachedContacts.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of Contact Objects diff --git a/src/api/resources/unstable/types/CompanyAttachedSegments.ts b/src/api/resources/unstable/types/CompanyAttachedSegments.ts index b7c72a13..73ace745 100644 --- a/src/api/resources/unstable/types/CompanyAttachedSegments.ts +++ b/src/api/resources/unstable/types/CompanyAttachedSegments.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of Segment Objects diff --git a/src/api/resources/unstable/types/CompanyData.ts b/src/api/resources/unstable/types/CompanyData.ts index de38845a..29d3a559 100644 --- a/src/api/resources/unstable/types/CompanyData.ts +++ b/src/api/resources/unstable/types/CompanyData.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * An object containing data about the companies that a contact is associated with. diff --git a/src/api/resources/unstable/types/CompanyList.ts b/src/api/resources/unstable/types/CompanyList.ts index af078812..670df0a5 100644 --- a/src/api/resources/unstable/types/CompanyList.ts +++ b/src/api/resources/unstable/types/CompanyList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * This will return a list of companies for the App. diff --git a/src/api/resources/unstable/types/CompanyScroll.ts b/src/api/resources/unstable/types/CompanyScroll.ts index 95030bb2..4f876c99 100644 --- a/src/api/resources/unstable/types/CompanyScroll.ts +++ b/src/api/resources/unstable/types/CompanyScroll.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Companies allow you to represent organizations using your product. Each company will have its own description and be associated with contacts. You can fetch, create, update and list companies. diff --git a/src/api/resources/unstable/types/ContactArchived.ts b/src/api/resources/unstable/types/ContactArchived.ts index 9a5527f7..b99dc919 100644 --- a/src/api/resources/unstable/types/ContactArchived.ts +++ b/src/api/resources/unstable/types/ContactArchived.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * archived contact object diff --git a/src/api/resources/unstable/types/ContactAttachedCompanies.ts b/src/api/resources/unstable/types/ContactAttachedCompanies.ts index d4a80f8f..c9afae62 100644 --- a/src/api/resources/unstable/types/ContactAttachedCompanies.ts +++ b/src/api/resources/unstable/types/ContactAttachedCompanies.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of Company Objects diff --git a/src/api/resources/unstable/types/ContactBlocked.ts b/src/api/resources/unstable/types/ContactBlocked.ts index 203b8792..0d31658f 100644 --- a/src/api/resources/unstable/types/ContactBlocked.ts +++ b/src/api/resources/unstable/types/ContactBlocked.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * blocked contact object diff --git a/src/api/resources/unstable/types/ContactCompanies.ts b/src/api/resources/unstable/types/ContactCompanies.ts index a827865a..c78c8889 100644 --- a/src/api/resources/unstable/types/ContactCompanies.ts +++ b/src/api/resources/unstable/types/ContactCompanies.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * An object with metadata about companies attached to a contact . Up to 10 will be displayed here. Use the url to get more. diff --git a/src/api/resources/unstable/types/ContactDeleted.ts b/src/api/resources/unstable/types/ContactDeleted.ts index 38fc4950..c5a47283 100644 --- a/src/api/resources/unstable/types/ContactDeleted.ts +++ b/src/api/resources/unstable/types/ContactDeleted.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * deleted contact object diff --git a/src/api/resources/unstable/types/ContactList.ts b/src/api/resources/unstable/types/ContactList.ts index 51a0df3c..5ef1b342 100644 --- a/src/api/resources/unstable/types/ContactList.ts +++ b/src/api/resources/unstable/types/ContactList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Contacts are your users in Intercom. diff --git a/src/api/resources/unstable/types/ContactLocation.ts b/src/api/resources/unstable/types/ContactLocation.ts index 6f3ca2ec..73f32530 100644 --- a/src/api/resources/unstable/types/ContactLocation.ts +++ b/src/api/resources/unstable/types/ContactLocation.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * An object containing location meta data about a Intercom contact. diff --git a/src/api/resources/unstable/types/ContactNotes.ts b/src/api/resources/unstable/types/ContactNotes.ts index fe835d12..88338f22 100644 --- a/src/api/resources/unstable/types/ContactNotes.ts +++ b/src/api/resources/unstable/types/ContactNotes.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * An object containing notes meta data about the notes that a contact has. Up to 10 will be displayed here. Use the url to get more. diff --git a/src/api/resources/unstable/types/ContactReference.ts b/src/api/resources/unstable/types/ContactReference.ts index d202aadc..6ff6080e 100644 --- a/src/api/resources/unstable/types/ContactReference.ts +++ b/src/api/resources/unstable/types/ContactReference.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * reference to contact object diff --git a/src/api/resources/unstable/types/ContactReplyBaseRequest.ts b/src/api/resources/unstable/types/ContactReplyBaseRequest.ts index 0559f83e..e6ebd102 100644 --- a/src/api/resources/unstable/types/ContactReplyBaseRequest.ts +++ b/src/api/resources/unstable/types/ContactReplyBaseRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export interface ContactReplyBaseRequest { message_type: "comment"; diff --git a/src/api/resources/unstable/types/ContactReplyConversationRequest.ts b/src/api/resources/unstable/types/ContactReplyConversationRequest.ts index 74fe2c40..eb27b919 100644 --- a/src/api/resources/unstable/types/ContactReplyConversationRequest.ts +++ b/src/api/resources/unstable/types/ContactReplyConversationRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; export type ContactReplyConversationRequest = | Intercom.unstable.ContactReplyIntercomUserIdRequest diff --git a/src/api/resources/unstable/types/ContactReplyEmailRequest.ts b/src/api/resources/unstable/types/ContactReplyEmailRequest.ts index f00aaaec..31f73734 100644 --- a/src/api/resources/unstable/types/ContactReplyEmailRequest.ts +++ b/src/api/resources/unstable/types/ContactReplyEmailRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Payload of the request to reply on behalf of a contact using their `email` diff --git a/src/api/resources/unstable/types/ContactReplyIntercomUserIdRequest.ts b/src/api/resources/unstable/types/ContactReplyIntercomUserIdRequest.ts index 0b6e3424..edd5a8fd 100644 --- a/src/api/resources/unstable/types/ContactReplyIntercomUserIdRequest.ts +++ b/src/api/resources/unstable/types/ContactReplyIntercomUserIdRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Payload of the request to reply on behalf of a contact using their `intercom_user_id` diff --git a/src/api/resources/unstable/types/ContactReplyTicketEmailRequest.ts b/src/api/resources/unstable/types/ContactReplyTicketEmailRequest.ts index b66e60dd..bad5a71c 100644 --- a/src/api/resources/unstable/types/ContactReplyTicketEmailRequest.ts +++ b/src/api/resources/unstable/types/ContactReplyTicketEmailRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Payload of the request to reply on behalf of a contact using their `email` diff --git a/src/api/resources/unstable/types/ContactReplyTicketIntercomUserIdRequest.ts b/src/api/resources/unstable/types/ContactReplyTicketIntercomUserIdRequest.ts index fd94eb7f..70a2d6e2 100644 --- a/src/api/resources/unstable/types/ContactReplyTicketIntercomUserIdRequest.ts +++ b/src/api/resources/unstable/types/ContactReplyTicketIntercomUserIdRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Payload of the request to reply on behalf of a contact using their `intercom_user_id` diff --git a/src/api/resources/unstable/types/ContactReplyTicketRequest.ts b/src/api/resources/unstable/types/ContactReplyTicketRequest.ts index c83977cc..523c59ef 100644 --- a/src/api/resources/unstable/types/ContactReplyTicketRequest.ts +++ b/src/api/resources/unstable/types/ContactReplyTicketRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; export type ContactReplyTicketRequest = | Intercom.unstable.ContactReplyTicketIntercomUserIdRequest diff --git a/src/api/resources/unstable/types/ContactReplyTicketUserIdRequest.ts b/src/api/resources/unstable/types/ContactReplyTicketUserIdRequest.ts index 5a6d2796..51ec38dc 100644 --- a/src/api/resources/unstable/types/ContactReplyTicketUserIdRequest.ts +++ b/src/api/resources/unstable/types/ContactReplyTicketUserIdRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Payload of the request to reply on behalf of a contact using their `user_id` diff --git a/src/api/resources/unstable/types/ContactReplyUserIdRequest.ts b/src/api/resources/unstable/types/ContactReplyUserIdRequest.ts index b7e32da0..6870f212 100644 --- a/src/api/resources/unstable/types/ContactReplyUserIdRequest.ts +++ b/src/api/resources/unstable/types/ContactReplyUserIdRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Payload of the request to reply on behalf of a contact using their `user_id` diff --git a/src/api/resources/unstable/types/ContactSegments.ts b/src/api/resources/unstable/types/ContactSegments.ts index 21a83fec..370cfde9 100644 --- a/src/api/resources/unstable/types/ContactSegments.ts +++ b/src/api/resources/unstable/types/ContactSegments.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of segments objects attached to a specific contact. diff --git a/src/api/resources/unstable/types/ContactSocialProfiles.ts b/src/api/resources/unstable/types/ContactSocialProfiles.ts index 32b4dfde..dd46662b 100644 --- a/src/api/resources/unstable/types/ContactSocialProfiles.ts +++ b/src/api/resources/unstable/types/ContactSocialProfiles.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * An object containing social profiles that a contact has. diff --git a/src/api/resources/unstable/types/ContactSubscriptionTypes.ts b/src/api/resources/unstable/types/ContactSubscriptionTypes.ts index fc133189..b478bc44 100644 --- a/src/api/resources/unstable/types/ContactSubscriptionTypes.ts +++ b/src/api/resources/unstable/types/ContactSubscriptionTypes.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * An object containing Subscription Types meta data about the SubscriptionTypes that a contact has. diff --git a/src/api/resources/unstable/types/ContactTags.ts b/src/api/resources/unstable/types/ContactTags.ts index c7bc0e62..2ed6d4e7 100644 --- a/src/api/resources/unstable/types/ContactTags.ts +++ b/src/api/resources/unstable/types/ContactTags.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * An object containing tags meta data about the tags that a contact has. Up to 10 will be displayed here. Use the url to get more. diff --git a/src/api/resources/unstable/types/ContactUnarchived.ts b/src/api/resources/unstable/types/ContactUnarchived.ts index 38322437..e5b151a1 100644 --- a/src/api/resources/unstable/types/ContactUnarchived.ts +++ b/src/api/resources/unstable/types/ContactUnarchived.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * unarchived contact object diff --git a/src/api/resources/unstable/types/ContentSourcesList.ts b/src/api/resources/unstable/types/ContentSourcesList.ts index 9250df9d..aee5ab31 100644 --- a/src/api/resources/unstable/types/ContentSourcesList.ts +++ b/src/api/resources/unstable/types/ContentSourcesList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; export interface ContentSourcesList { type?: "content_source.list"; diff --git a/src/api/resources/unstable/types/ConversationAttachmentFiles.ts b/src/api/resources/unstable/types/ConversationAttachmentFiles.ts index 98d751b4..f1a0b3e5 100644 --- a/src/api/resources/unstable/types/ConversationAttachmentFiles.ts +++ b/src/api/resources/unstable/types/ConversationAttachmentFiles.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Properties of the attachment files in a conversation part diff --git a/src/api/resources/unstable/types/ConversationAttributeUpdatedByAdmin.ts b/src/api/resources/unstable/types/ConversationAttributeUpdatedByAdmin.ts index 1c49cecf..b44c2202 100644 --- a/src/api/resources/unstable/types/ConversationAttributeUpdatedByAdmin.ts +++ b/src/api/resources/unstable/types/ConversationAttributeUpdatedByAdmin.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Contains details about Custom Data Attributes (CDAs) that were modified by an admin (operator) for conversation part type conversation_attribute_updated_by_admin. diff --git a/src/api/resources/unstable/types/ConversationAttributeUpdatedByWorkflow.ts b/src/api/resources/unstable/types/ConversationAttributeUpdatedByWorkflow.ts index 65572650..e9e75f32 100644 --- a/src/api/resources/unstable/types/ConversationAttributeUpdatedByWorkflow.ts +++ b/src/api/resources/unstable/types/ConversationAttributeUpdatedByWorkflow.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Contains details about the workflow that was triggered and any Custom Data Attributes (CDAs) that were modified during the workflow execution for conversation part type conversation_attribute_updated_by_workflow. diff --git a/src/api/resources/unstable/types/ConversationContacts.ts b/src/api/resources/unstable/types/ConversationContacts.ts index c9818ad5..eb49d28f 100644 --- a/src/api/resources/unstable/types/ConversationContacts.ts +++ b/src/api/resources/unstable/types/ConversationContacts.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * The list of contacts (users or leads) involved in this conversation. This will only contain one customer unless more were added via the group conversation feature. diff --git a/src/api/resources/unstable/types/ConversationDeleted.ts b/src/api/resources/unstable/types/ConversationDeleted.ts index c45bc58f..e61823b9 100644 --- a/src/api/resources/unstable/types/ConversationDeleted.ts +++ b/src/api/resources/unstable/types/ConversationDeleted.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * deleted conversation object diff --git a/src/api/resources/unstable/types/ConversationFirstContactReply.ts b/src/api/resources/unstable/types/ConversationFirstContactReply.ts index 7d859b74..2085bd1e 100644 --- a/src/api/resources/unstable/types/ConversationFirstContactReply.ts +++ b/src/api/resources/unstable/types/ConversationFirstContactReply.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * An object containing information on the first users message. For a contact initiated message this will represent the users original message. diff --git a/src/api/resources/unstable/types/ConversationList.ts b/src/api/resources/unstable/types/ConversationList.ts index 402dae67..9a0a768e 100644 --- a/src/api/resources/unstable/types/ConversationList.ts +++ b/src/api/resources/unstable/types/ConversationList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Conversations are how you can communicate with users in Intercom. They are created when a contact replies to an outbound message, or when one admin directly sends a message to a single contact. diff --git a/src/api/resources/unstable/types/ConversationPart.ts b/src/api/resources/unstable/types/ConversationPart.ts index e724eb88..0d55a965 100644 --- a/src/api/resources/unstable/types/ConversationPart.ts +++ b/src/api/resources/unstable/types/ConversationPart.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A Conversation Part represents a message in the conversation. @@ -43,13 +41,11 @@ export interface ConversationPart { } export namespace ConversationPart { - /** - * Indicates the current state of conversation when the conversation part was created. - */ - export type State = "open" | "closed" | "snoozed"; + /** Indicates the current state of conversation when the conversation part was created. */ export const State = { Open: "open", Closed: "closed", Snoozed: "snoozed", } as const; + export type State = (typeof State)[keyof typeof State]; } diff --git a/src/api/resources/unstable/types/ConversationPartAuthor.ts b/src/api/resources/unstable/types/ConversationPartAuthor.ts index 01a62b9f..3a17d751 100644 --- a/src/api/resources/unstable/types/ConversationPartAuthor.ts +++ b/src/api/resources/unstable/types/ConversationPartAuthor.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The object who initiated the conversation, which can be a Contact, Admin or Team. Bots and campaigns send messages on behalf of Admins or Teams. For Twitter, this will be blank. diff --git a/src/api/resources/unstable/types/ConversationPartMetadata.ts b/src/api/resources/unstable/types/ConversationPartMetadata.ts index 1a71c4a2..73de6365 100644 --- a/src/api/resources/unstable/types/ConversationPartMetadata.ts +++ b/src/api/resources/unstable/types/ConversationPartMetadata.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Metadata for a conversation part diff --git a/src/api/resources/unstable/types/ConversationParts.ts b/src/api/resources/unstable/types/ConversationParts.ts index 2c21bccd..a1e3f943 100644 --- a/src/api/resources/unstable/types/ConversationParts.ts +++ b/src/api/resources/unstable/types/ConversationParts.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of Conversation Part objects for each part message in the conversation. This is only returned when Retrieving a Conversation, and ignored when Listing all Conversations. There is a limit of 500 parts. diff --git a/src/api/resources/unstable/types/ConversationRating.ts b/src/api/resources/unstable/types/ConversationRating.ts index 5b5a7899..1edf63c5 100644 --- a/src/api/resources/unstable/types/ConversationRating.ts +++ b/src/api/resources/unstable/types/ConversationRating.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * The Conversation Rating object which contains information on the rating and/or remark added by a Contact and the Admin assigned to the conversation. @@ -14,6 +12,8 @@ export interface ConversationRating { remark?: string; /** The time the rating was requested in the conversation being rated. */ created_at?: number; + /** The time the rating was last updated. */ + updated_at?: number; contact?: Intercom.unstable.ContactReference; teammate?: Intercom.unstable.Reference; } diff --git a/src/api/resources/unstable/types/ConversationResponseTime.ts b/src/api/resources/unstable/types/ConversationResponseTime.ts index 56d2b0ae..8c503679 100644 --- a/src/api/resources/unstable/types/ConversationResponseTime.ts +++ b/src/api/resources/unstable/types/ConversationResponseTime.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Details of first response time of assigned team in seconds. diff --git a/src/api/resources/unstable/types/ConversationSource.ts b/src/api/resources/unstable/types/ConversationSource.ts index e9ade720..3987bf3f 100644 --- a/src/api/resources/unstable/types/ConversationSource.ts +++ b/src/api/resources/unstable/types/ConversationSource.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * The type of the conversation part that started this conversation. Can be Contact, Admin, Campaign, Automated or Operator initiated. @@ -28,20 +26,7 @@ export interface ConversationSource { } export namespace ConversationSource { - /** - * This includes conversation, email, facebook, instagram, phone_call, phone_switch, push, sms, twitter and whatsapp. - */ - export type Type = - | "conversation" - | "email" - | "facebook" - | "instagram" - | "phone_call" - | "phone_switch" - | "push" - | "sms" - | "twitter" - | "whatsapp"; + /** This includes conversation, email, facebook, instagram, phone_call, phone_switch, push, sms, twitter and whatsapp. */ export const Type = { Conversation: "conversation", Email: "email", @@ -54,4 +39,5 @@ export namespace ConversationSource { Twitter: "twitter", Whatsapp: "whatsapp", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } diff --git a/src/api/resources/unstable/types/ConversationStatistics.ts b/src/api/resources/unstable/types/ConversationStatistics.ts index 03dc8b5c..8491c58f 100644 --- a/src/api/resources/unstable/types/ConversationStatistics.ts +++ b/src/api/resources/unstable/types/ConversationStatistics.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A Statistics object containing all information required for reporting, with timestamps and calculated metrics. @@ -52,4 +50,6 @@ export interface ConversationStatistics { assigned_team_first_response_time_in_office_hours?: Intercom.unstable.ConversationResponseTime[]; /** Time from conversation assignment to conversation close in seconds. */ handling_time?: number; + /** Adjusted handling time for conversation in seconds. This is the active handling time excluding idle periods when teammates are not actively working on the conversation. */ + adjusted_handling_time?: number; } diff --git a/src/api/resources/unstable/types/ConversationTeammates.ts b/src/api/resources/unstable/types/ConversationTeammates.ts index b72a5928..3932494d 100644 --- a/src/api/resources/unstable/types/ConversationTeammates.ts +++ b/src/api/resources/unstable/types/ConversationTeammates.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * The list of teammates who participated in the conversation (wrote at least one conversation part). diff --git a/src/api/resources/unstable/types/UpdateArticleRequestBody.ts b/src/api/resources/unstable/types/CreateArticleRequest.ts similarity index 67% rename from src/api/resources/unstable/types/UpdateArticleRequestBody.ts rename to src/api/resources/unstable/types/CreateArticleRequest.ts index 09be43a9..fae9a9e6 100644 --- a/src/api/resources/unstable/types/UpdateArticleRequestBody.ts +++ b/src/api/resources/unstable/types/CreateArticleRequest.ts @@ -1,37 +1,33 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** - * You can Update an Article + * You can create an Article */ -export interface UpdateArticleRequestBody { +export interface CreateArticleRequest { /** The title of the article.For multilingual articles, this will be the title of the default language's content. */ - title?: string; + title: string; /** The description of the article. For multilingual articles, this will be the description of the default language's content. */ description?: string; /** The content of the article. For multilingual articles, this will be the body of the default language's content. */ body?: string; /** The id of the author of the article. For multilingual articles, this will be the id of the author of the default language's content. Must be a teammate on the help center's workspace. */ - author_id?: number; + author_id: number; /** Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. */ - state?: UpdateArticleRequestBody.State; + state?: CreateArticleRequest.State; /** The id of the article's parent collection or section. An article without this field stands alone. */ - parent_id?: string; + parent_id?: number; /** The type of parent, which can either be a `collection` or `section`. */ parent_type?: string; translated_content?: Intercom.unstable.ArticleTranslatedContent; } -export namespace UpdateArticleRequestBody { - /** - * Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. - */ - export type State = "published" | "draft"; +export namespace CreateArticleRequest { + /** Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. */ export const State = { Published: "published", Draft: "draft", } as const; + export type State = (typeof State)[keyof typeof State]; } diff --git a/src/api/resources/unstable/types/CreateDataAttributeRequest.ts b/src/api/resources/unstable/types/CreateDataAttributeRequest.ts new file mode 100644 index 00000000..e2abd5d2 --- /dev/null +++ b/src/api/resources/unstable/types/CreateDataAttributeRequest.ts @@ -0,0 +1,15 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * + */ +export type CreateDataAttributeRequest = + | { + data_type?: "options" | undefined; + options: { + value?: string | undefined; + }[]; + } + | { + data_type?: ("string" | "integer" | "float" | "boolean" | "datetime" | "date") | undefined; + }; diff --git a/src/api/resources/unstable/types/CreateInternalArticleRequest.ts b/src/api/resources/unstable/types/CreateInternalArticleRequest.ts new file mode 100644 index 00000000..f971e918 --- /dev/null +++ b/src/api/resources/unstable/types/CreateInternalArticleRequest.ts @@ -0,0 +1,15 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * You can create an Internal Article + */ +export interface CreateInternalArticleRequest { + /** The title of the article. */ + title: string; + /** The content of the article. */ + body?: string; + /** The id of the author of the article. */ + author_id: number; + /** The id of the owner of the article. */ + owner_id: number; +} diff --git a/src/api/resources/unstable/types/CreateMessageRequest.ts b/src/api/resources/unstable/types/CreateMessageRequest.ts new file mode 100644 index 00000000..b9bc1f58 --- /dev/null +++ b/src/api/resources/unstable/types/CreateMessageRequest.ts @@ -0,0 +1,6 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * You can create a message + */ +export type CreateMessageRequest = unknown | undefined; diff --git a/src/api/resources/unstable/types/CreateOrUpdateCompanyRequest.ts b/src/api/resources/unstable/types/CreateOrUpdateCompanyRequest.ts new file mode 100644 index 00000000..9a465e5c --- /dev/null +++ b/src/api/resources/unstable/types/CreateOrUpdateCompanyRequest.ts @@ -0,0 +1,25 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * You can create or update a Company + */ +export interface CreateOrUpdateCompanyRequest { + /** The name of the Company */ + name?: string; + /** The company id you have defined for the company. Can't be updated */ + company_id?: string; + /** The name of the plan you have associated with the company. */ + plan?: string; + /** The number of employees in this company. */ + size?: number; + /** The URL for this company's website. Please note that the value specified here is not validated. Accepts any string. */ + website?: string; + /** The industry that this company operates in. */ + industry?: string; + /** A hash of key/value pairs containing any other data about the company you want Intercom to store. */ + custom_attributes?: Record; + /** The time the company was created by you. */ + remote_created_at?: number; + /** How much revenue the company generates for your business. Note that this will truncate floats. i.e. it only allow for whole integers, 155.98 will be truncated to 155. Note that this has an upper limit of 2**31-1 or 2147483647.. */ + monthly_spend?: number; +} diff --git a/src/api/resources/unstable/types/CreateOrUpdateTagRequest.ts b/src/api/resources/unstable/types/CreateOrUpdateTagRequest.ts index a79ff2e0..7dfd1b3f 100644 --- a/src/api/resources/unstable/types/CreateOrUpdateTagRequest.ts +++ b/src/api/resources/unstable/types/CreateOrUpdateTagRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * You can create or update an existing tag. diff --git a/src/api/resources/unstable/types/CreatePhoneSwitchRequest.ts b/src/api/resources/unstable/types/CreatePhoneSwitchRequest.ts new file mode 100644 index 00000000..825757f8 --- /dev/null +++ b/src/api/resources/unstable/types/CreatePhoneSwitchRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +/** + * You can create an phone switch + */ +export interface CreatePhoneSwitchRequest { + /** Phone number in E.164 format, that will receive the SMS to continue the conversation in the Messenger. */ + phone: string; + custom_attributes?: Intercom.unstable.CustomAttributes; +} diff --git a/src/api/resources/unstable/types/CreateTicketReplyWithCommentRequest.ts b/src/api/resources/unstable/types/CreateTicketReplyWithCommentRequest.ts index cbca0524..31c13aad 100644 --- a/src/api/resources/unstable/types/CreateTicketReplyWithCommentRequest.ts +++ b/src/api/resources/unstable/types/CreateTicketReplyWithCommentRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; export type CreateTicketReplyWithCommentRequest = | Intercom.unstable.ContactReplyTicketRequest diff --git a/src/api/resources/unstable/types/CreateTicketRequestBody.ts b/src/api/resources/unstable/types/CreateTicketRequestBody.ts index b5af5ba1..9ec9fb5c 100644 --- a/src/api/resources/unstable/types/CreateTicketRequestBody.ts +++ b/src/api/resources/unstable/types/CreateTicketRequestBody.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * You can create a Ticket diff --git a/src/api/resources/ticketTypes/client/requests/CreateTicketTypeRequest.ts b/src/api/resources/unstable/types/CreateTicketTypeRequest.ts similarity index 65% rename from src/api/resources/ticketTypes/client/requests/CreateTicketTypeRequest.ts rename to src/api/resources/unstable/types/CreateTicketTypeRequest.ts index 0282e169..eebc72da 100644 --- a/src/api/resources/ticketTypes/client/requests/CreateTicketTypeRequest.ts +++ b/src/api/resources/unstable/types/CreateTicketTypeRequest.ts @@ -1,15 +1,8 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** - * @example - * { - * name: "Customer Issue", - * description: "Customer Report Template", - * category: "Customer", - * icon: "\uD83C\uDF9F\uFE0F" - * } + * The request payload for creating a ticket type. + * You can copy the `icon` property for your ticket type from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) */ export interface CreateTicketTypeRequest { /** The name of the ticket type. */ @@ -25,13 +18,11 @@ export interface CreateTicketTypeRequest { } export namespace CreateTicketTypeRequest { - /** - * Category of the Ticket Type. - */ - export type Category = "Customer" | "Back-office" | "Tracker"; + /** Category of the Ticket Type. */ export const Category = { Customer: "Customer", BackOffice: "Back-office", Tracker: "Tracker", } as const; + export type Category = (typeof Category)[keyof typeof Category]; } diff --git a/src/api/resources/unstable/types/CursorPages.ts b/src/api/resources/unstable/types/CursorPages.ts index b289ca72..28a01ed3 100644 --- a/src/api/resources/unstable/types/CursorPages.ts +++ b/src/api/resources/unstable/types/CursorPages.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Cursor-based pagination is a technique used in the Intercom API to navigate through large amounts of data. diff --git a/src/api/resources/unstable/types/CustomActionFinished.ts b/src/api/resources/unstable/types/CustomActionFinished.ts index 95484be5..54471392 100644 --- a/src/api/resources/unstable/types/CustomActionFinished.ts +++ b/src/api/resources/unstable/types/CustomActionFinished.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Contains details about final status of the completed action for conversation part type custom_action_finished. @@ -18,13 +16,11 @@ export namespace CustomActionFinished { } export namespace Action { - /** - * Status of the action - */ - export type Result = "success" | "failed"; + /** Status of the action */ export const Result = { Success: "success", Failed: "failed", } as const; + export type Result = (typeof Result)[keyof typeof Result]; } } diff --git a/src/api/resources/unstable/types/CustomActionStarted.ts b/src/api/resources/unstable/types/CustomActionStarted.ts index eb089da6..18114f6c 100644 --- a/src/api/resources/unstable/types/CustomActionStarted.ts +++ b/src/api/resources/unstable/types/CustomActionStarted.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Contains details about name of the action that was initiated for conversation part type custom_action_started. diff --git a/src/api/resources/unstable/types/CustomAttributes.ts b/src/api/resources/unstable/types/CustomAttributes.ts index 1a8f52e6..c2086e14 100644 --- a/src/api/resources/unstable/types/CustomAttributes.ts +++ b/src/api/resources/unstable/types/CustomAttributes.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * An object containing the different custom attributes associated to the conversation as key-value pairs. For relationship attributes the value will be a list of custom object instance models. diff --git a/src/api/resources/unstable/types/CustomChannelAttribute.ts b/src/api/resources/unstable/types/CustomChannelAttribute.ts index 1f5ffeb6..9afa1dd6 100644 --- a/src/api/resources/unstable/types/CustomChannelAttribute.ts +++ b/src/api/resources/unstable/types/CustomChannelAttribute.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export interface CustomChannelAttribute { /** Identifier for the attribute being collected. */ diff --git a/src/api/resources/unstable/types/CustomChannelBaseEvent.ts b/src/api/resources/unstable/types/CustomChannelBaseEvent.ts index 16b7996e..6a638105 100644 --- a/src/api/resources/unstable/types/CustomChannelBaseEvent.ts +++ b/src/api/resources/unstable/types/CustomChannelBaseEvent.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; export interface CustomChannelBaseEvent { /** Unique identifier for the event. */ diff --git a/src/api/resources/unstable/types/CustomChannelContact.ts b/src/api/resources/unstable/types/CustomChannelContact.ts index e1e7eabc..7d11a83c 100644 --- a/src/api/resources/unstable/types/CustomChannelContact.ts +++ b/src/api/resources/unstable/types/CustomChannelContact.ts @@ -1,25 +1,21 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export interface CustomChannelContact { /** Type of contact, must be "user" or "lead". */ type: CustomChannelContact.Type; /** External identifier for the contact. Intercom will take care of the mapping of your external_id with our internal ones so you don't have to worry about it. */ external_id: string; - /** Name of the contact. */ - name: string; - /** Email address of the contact. */ - email: string; + /** Name of the contact. Required for user type. */ + name?: string; + /** Email address of the contact. Required for user type. */ + email?: string; } export namespace CustomChannelContact { - /** - * Type of contact, must be "user" or "lead". - */ - export type Type = "user" | "lead"; + /** Type of contact, must be "user" or "lead". */ export const Type = { User: "user", Lead: "lead", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } diff --git a/src/api/resources/unstable/types/CustomChannelNotificationResponse.ts b/src/api/resources/unstable/types/CustomChannelNotificationResponse.ts index ae5a5611..238b883d 100644 --- a/src/api/resources/unstable/types/CustomChannelNotificationResponse.ts +++ b/src/api/resources/unstable/types/CustomChannelNotificationResponse.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export interface CustomChannelNotificationResponse { /** The external conversation ID provided in the notification request */ diff --git a/src/api/resources/unstable/types/CustomObjectInstanceDeleted.ts b/src/api/resources/unstable/types/CustomObjectInstanceDeleted.ts index 091e1ec4..4c14eba9 100644 --- a/src/api/resources/unstable/types/CustomObjectInstanceDeleted.ts +++ b/src/api/resources/unstable/types/CustomObjectInstanceDeleted.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * deleted custom object instance object diff --git a/src/api/resources/unstable/types/CustomObjectInstanceList.ts b/src/api/resources/unstable/types/CustomObjectInstanceList.ts index 8bfd0ef2..98e68588 100644 --- a/src/api/resources/unstable/types/CustomObjectInstanceList.ts +++ b/src/api/resources/unstable/types/CustomObjectInstanceList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * The list of associated custom object instances for a given reference attribute on the parent object. diff --git a/src/api/resources/unstable/types/CustomerRequest.ts b/src/api/resources/unstable/types/CustomerRequest.ts index 6ede7a3d..d86d11c7 100644 --- a/src/api/resources/unstable/types/CustomerRequest.ts +++ b/src/api/resources/unstable/types/CustomerRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export type CustomerRequest = | { diff --git a/src/api/resources/unstable/types/DataAttributeList.ts b/src/api/resources/unstable/types/DataAttributeList.ts index 5242a0bf..f8b6055b 100644 --- a/src/api/resources/unstable/types/DataAttributeList.ts +++ b/src/api/resources/unstable/types/DataAttributeList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of all data attributes belonging to a workspace for contacts, companies or conversations. diff --git a/src/api/resources/unstable/types/DataEventList.ts b/src/api/resources/unstable/types/DataEventList.ts index 09ed47e2..1fa73fc8 100644 --- a/src/api/resources/unstable/types/DataEventList.ts +++ b/src/api/resources/unstable/types/DataEventList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * This will return a list of data events for the App. diff --git a/src/api/resources/unstable/types/DataEventSummary.ts b/src/api/resources/unstable/types/DataEventSummary.ts index 87791da0..0badccff 100644 --- a/src/api/resources/unstable/types/DataEventSummary.ts +++ b/src/api/resources/unstable/types/DataEventSummary.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * This will return a summary of data events for the App. diff --git a/src/api/resources/unstable/types/DataEventSummaryItem.ts b/src/api/resources/unstable/types/DataEventSummaryItem.ts index 26f9e3a5..9f0d9192 100644 --- a/src/api/resources/unstable/types/DataEventSummaryItem.ts +++ b/src/api/resources/unstable/types/DataEventSummaryItem.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * This will return a summary of a data event for the App. diff --git a/src/api/resources/unstable/types/DataExportCsv.ts b/src/api/resources/unstable/types/DataExportCsv.ts index 5cc3bea0..8c268f7e 100644 --- a/src/api/resources/unstable/types/DataExportCsv.ts +++ b/src/api/resources/unstable/types/DataExportCsv.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A CSV output file diff --git a/src/api/resources/unstable/types/Datetime.ts b/src/api/resources/unstable/types/Datetime.ts index c291e607..63964732 100644 --- a/src/api/resources/unstable/types/Datetime.ts +++ b/src/api/resources/unstable/types/Datetime.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export type Datetime = /** diff --git a/src/api/resources/unstable/types/DeletedArticleObject.ts b/src/api/resources/unstable/types/DeletedArticleObject.ts index 2fb626a8..5667114c 100644 --- a/src/api/resources/unstable/types/DeletedArticleObject.ts +++ b/src/api/resources/unstable/types/DeletedArticleObject.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Response returned when an object is deleted diff --git a/src/api/resources/unstable/types/DeletedCollectionObject.ts b/src/api/resources/unstable/types/DeletedCollectionObject.ts index 9f09babd..4d03d936 100644 --- a/src/api/resources/unstable/types/DeletedCollectionObject.ts +++ b/src/api/resources/unstable/types/DeletedCollectionObject.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Response returned when an object is deleted diff --git a/src/api/resources/unstable/types/DeletedCompanyObject.ts b/src/api/resources/unstable/types/DeletedCompanyObject.ts index f93f0699..b5ee6cf6 100644 --- a/src/api/resources/unstable/types/DeletedCompanyObject.ts +++ b/src/api/resources/unstable/types/DeletedCompanyObject.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Response returned when an object is deleted diff --git a/src/api/resources/unstable/types/DeletedInternalArticleObject.ts b/src/api/resources/unstable/types/DeletedInternalArticleObject.ts new file mode 100644 index 00000000..47d5060b --- /dev/null +++ b/src/api/resources/unstable/types/DeletedInternalArticleObject.ts @@ -0,0 +1,13 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Response returned when an object is deleted + */ +export interface DeletedInternalArticleObject { + /** The unique identifier for the internal article which you provided in the URL. */ + id?: string; + /** The type of object which was deleted. - internal_article */ + object?: "internal_article"; + /** Whether the internal article was deleted successfully or not. */ + deleted?: boolean; +} diff --git a/src/api/resources/unstable/types/DeletedObject.ts b/src/api/resources/unstable/types/DeletedObject.ts index 613a0f83..a22b393b 100644 --- a/src/api/resources/unstable/types/DeletedObject.ts +++ b/src/api/resources/unstable/types/DeletedObject.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Response returned when an object is deleted diff --git a/src/api/resources/unstable/types/EmailAddressHeader.ts b/src/api/resources/unstable/types/EmailAddressHeader.ts index 81f30d02..7e8d234d 100644 --- a/src/api/resources/unstable/types/EmailAddressHeader.ts +++ b/src/api/resources/unstable/types/EmailAddressHeader.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Contains data for an email address header for a conversation part that was sent as an email. diff --git a/src/api/resources/unstable/types/EmailMessageMetadata.ts b/src/api/resources/unstable/types/EmailMessageMetadata.ts index 6a407392..022108cf 100644 --- a/src/api/resources/unstable/types/EmailMessageMetadata.ts +++ b/src/api/resources/unstable/types/EmailMessageMetadata.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Contains metadata if the message was sent as an email @@ -12,4 +10,6 @@ export interface EmailMessageMetadata { subject?: string; /** A list of an email address headers. */ email_address_headers?: Intercom.unstable.EmailAddressHeader[]; + /** The unique identifier for the email message as specified in the Message-ID header */ + message_id?: string; } diff --git a/src/api/resources/unstable/types/Error_.ts b/src/api/resources/unstable/types/Error_.ts index 1526174a..91e726ed 100644 --- a/src/api/resources/unstable/types/Error_.ts +++ b/src/api/resources/unstable/types/Error_.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The API will return an Error List for a failed request, which will contain one or more Error objects. diff --git a/src/api/resources/unstable/types/EventDetails.ts b/src/api/resources/unstable/types/EventDetails.ts index a5bddd05..b257b71e 100644 --- a/src/api/resources/unstable/types/EventDetails.ts +++ b/src/api/resources/unstable/types/EventDetails.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; export type EventDetails = | Intercom.unstable.ConversationAttributeUpdatedByWorkflow diff --git a/src/api/resources/unstable/types/FileAttribute.ts b/src/api/resources/unstable/types/FileAttribute.ts index e0c5f023..b8fab036 100644 --- a/src/api/resources/unstable/types/FileAttribute.ts +++ b/src/api/resources/unstable/types/FileAttribute.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The value describing a file upload set for a custom attribute diff --git a/src/api/resources/unstable/types/GroupContent.ts b/src/api/resources/unstable/types/GroupContent.ts index a7fb4506..68c5b320 100644 --- a/src/api/resources/unstable/types/GroupContent.ts +++ b/src/api/resources/unstable/types/GroupContent.ts @@ -1,13 +1,11 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The Content of a Group. */ export interface GroupContent { /** The type of object - `group_content` . */ - type?: string; + type?: "group_content"; /** The name of the collection or section. */ name?: string; /** The description of the collection. Only available for collections. */ diff --git a/src/api/resources/unstable/types/GroupTranslatedContent.ts b/src/api/resources/unstable/types/GroupTranslatedContent.ts index 5df6fde7..c7b9933b 100644 --- a/src/api/resources/unstable/types/GroupTranslatedContent.ts +++ b/src/api/resources/unstable/types/GroupTranslatedContent.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * The Translated Content of an Group. The keys are the locale codes and the values are the translated content of the Group. */ export interface GroupTranslatedContent { /** The type of object - group_translated_content. */ - type?: string; + type?: "group_translated_content"; /** The content of the group in Arabic */ ar?: Intercom.unstable.GroupContent; /** The content of the group in Bulgarian */ diff --git a/src/api/resources/unstable/types/IntercomVersion.ts b/src/api/resources/unstable/types/IntercomVersion.ts deleted file mode 100644 index 921f8ae6..00000000 --- a/src/api/resources/unstable/types/IntercomVersion.ts +++ /dev/null @@ -1,46 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * Intercom API version.
By default, it's equal to the version set in the app package. - */ -export type IntercomVersion = - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; -export const IntercomVersion = { - One0: "1.0", - One1: "1.1", - One2: "1.2", - One3: "1.3", - One4: "1.4", - Two0: "2.0", - Two1: "2.1", - Two2: "2.2", - Two3: "2.3", - Two4: "2.4", - Two5: "2.5", - Two6: "2.6", - Two7: "2.7", - Two8: "2.8", - Two9: "2.9", - Two10: "2.10", - Two11: "2.11", - Unstable: "Unstable", -} as const; diff --git a/src/api/resources/unstable/types/IntercomVersionUnstable.ts b/src/api/resources/unstable/types/IntercomVersionUnstable.ts deleted file mode 100644 index 1bbcf600..00000000 --- a/src/api/resources/unstable/types/IntercomVersionUnstable.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * Unstable Intercom API version. Used for closed beta endpoints. - */ -export type IntercomVersionUnstable = "unstable"; diff --git a/src/api/resources/unstable/types/InternalArticleList.ts b/src/api/resources/unstable/types/InternalArticleList.ts new file mode 100644 index 00000000..5f5f6df8 --- /dev/null +++ b/src/api/resources/unstable/types/InternalArticleList.ts @@ -0,0 +1,16 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +/** + * This will return a list of internal articles for the App. + */ +export interface InternalArticleList { + /** The type of the object - `list`. */ + type?: "list"; + pages?: Intercom.unstable.CursorPages; + /** A count of the total number of internal articles. */ + total_count?: number; + /** An array of Internal Article objects */ + data?: Intercom.unstable.InternalArticleListItem[]; +} diff --git a/src/api/resources/unstable/types/LinkedObject.ts b/src/api/resources/unstable/types/LinkedObject.ts index d7eaf21d..27fe77b5 100644 --- a/src/api/resources/unstable/types/LinkedObject.ts +++ b/src/api/resources/unstable/types/LinkedObject.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A linked conversation or ticket. @@ -11,16 +9,21 @@ export interface LinkedObject { /** The ID of the linked object */ id?: string; /** Category of the Linked Ticket Object. */ - category?: string; + category?: LinkedObject.Category; } export namespace LinkedObject { - /** - * ticket or conversation - */ - export type Type = "ticket" | "conversation"; + /** ticket or conversation */ export const Type = { Ticket: "ticket", Conversation: "conversation", } as const; + export type Type = (typeof Type)[keyof typeof Type]; + /** Category of the Linked Ticket Object. */ + export const Category = { + Customer: "Customer", + BackOffice: "Back-office", + Tracker: "Tracker", + } as const; + export type Category = (typeof Category)[keyof typeof Category]; } diff --git a/src/api/resources/unstable/types/LinkedObjectList.ts b/src/api/resources/unstable/types/LinkedObjectList.ts index 8a95b96a..b17171e1 100644 --- a/src/api/resources/unstable/types/LinkedObjectList.ts +++ b/src/api/resources/unstable/types/LinkedObjectList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * An object containing metadata about linked conversations and linked tickets. Up to 1000 can be returned. diff --git a/src/api/resources/unstable/types/MultipleFilterSearchRequest.ts b/src/api/resources/unstable/types/MultipleFilterSearchRequest.ts index 9f184175..4d834701 100644 --- a/src/api/resources/unstable/types/MultipleFilterSearchRequest.ts +++ b/src/api/resources/unstable/types/MultipleFilterSearchRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Search using Intercoms Search APIs with more than one filter. @@ -14,14 +12,12 @@ export interface MultipleFilterSearchRequest { } export namespace MultipleFilterSearchRequest { - /** - * An operator to allow boolean inspection between multiple fields. - */ - export type Operator = "AND" | "OR"; + /** An operator to allow boolean inspection between multiple fields. */ export const Operator = { And: "AND", Or: "OR", } as const; + export type Operator = (typeof Operator)[keyof typeof Operator]; export type Value = /** * Add mutiple filters. */ diff --git a/src/api/resources/unstable/types/NewsItemRequest.ts b/src/api/resources/unstable/types/NewsItemRequest.ts index 3e3791a2..9735b4fc 100644 --- a/src/api/resources/unstable/types/NewsItemRequest.ts +++ b/src/api/resources/unstable/types/NewsItemRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A News Item is a content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers. @@ -27,12 +25,10 @@ export interface NewsItemRequest { } export namespace NewsItemRequest { - /** - * News items will not be visible to your users in the assigned newsfeeds until they are set live. - */ - export type State = "draft" | "live"; + /** News items will not be visible to your users in the assigned newsfeeds until they are set live. */ export const State = { Draft: "draft", Live: "live", } as const; + export type State = (typeof State)[keyof typeof State]; } diff --git a/src/api/resources/unstable/types/NotFoundErrorBody.ts b/src/api/resources/unstable/types/NotFoundErrorBody.ts index 0893b81e..de9109f3 100644 --- a/src/api/resources/unstable/types/NotFoundErrorBody.ts +++ b/src/api/resources/unstable/types/NotFoundErrorBody.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export interface NotFoundErrorBody { /** The type is error.list */ diff --git a/src/api/resources/unstable/types/NoteList.ts b/src/api/resources/unstable/types/NoteList.ts index 162d648f..0f1e8fe4 100644 --- a/src/api/resources/unstable/types/NoteList.ts +++ b/src/api/resources/unstable/types/NoteList.ts @@ -1,11 +1,9 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** - * A paginated list of notes associated with a contact. + * A paginated list of notes associated with a contact or a company. */ export interface NoteList { /** String representing the object's type. Always has the value `list`. */ diff --git a/src/api/resources/unstable/types/OpenConversationRequest.ts b/src/api/resources/unstable/types/OpenConversationRequest.ts index 682699e3..b3e63714 100644 --- a/src/api/resources/unstable/types/OpenConversationRequest.ts +++ b/src/api/resources/unstable/types/OpenConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Payload of the request to open a conversation diff --git a/src/api/resources/unstable/types/OperatorWorkflowEvent.ts b/src/api/resources/unstable/types/OperatorWorkflowEvent.ts index 336b4885..df8629d3 100644 --- a/src/api/resources/unstable/types/OperatorWorkflowEvent.ts +++ b/src/api/resources/unstable/types/OperatorWorkflowEvent.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Contains details about name of the workflow for conversation part type operator_workflow_event. diff --git a/src/api/resources/unstable/types/PagesLink.ts b/src/api/resources/unstable/types/PagesLink.ts index 4dd36d75..59d698ff 100644 --- a/src/api/resources/unstable/types/PagesLink.ts +++ b/src/api/resources/unstable/types/PagesLink.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The majority of list resources in the API are paginated to allow clients to traverse data over multiple requests. diff --git a/src/api/resources/unstable/types/PaginatedResponse.ts b/src/api/resources/unstable/types/PaginatedResponse.ts index af97a516..64972bf9 100644 --- a/src/api/resources/unstable/types/PaginatedResponse.ts +++ b/src/api/resources/unstable/types/PaginatedResponse.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Paginated Response @@ -18,12 +16,10 @@ export interface PaginatedResponse { } export namespace PaginatedResponse { - /** - * The type of object - */ - export type Type = "list" | "conversation.list"; + /** The type of object */ export const Type = { List: "list", ConversationList: "conversation.list", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } diff --git a/src/api/resources/unstable/types/PaginatedResponseDataItem.ts b/src/api/resources/unstable/types/PaginatedResponseDataItem.ts index fc09f5f8..65655304 100644 --- a/src/api/resources/unstable/types/PaginatedResponseDataItem.ts +++ b/src/api/resources/unstable/types/PaginatedResponseDataItem.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; export type PaginatedResponseDataItem = | Intercom.unstable.PaginatedResponseDataItem.NewsItem diff --git a/src/api/resources/unstable/types/PartAttachment.ts b/src/api/resources/unstable/types/PartAttachment.ts index 690152f9..3c01b778 100644 --- a/src/api/resources/unstable/types/PartAttachment.ts +++ b/src/api/resources/unstable/types/PartAttachment.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The file attached to a part diff --git a/src/api/resources/unstable/types/PhoneSwitch.ts b/src/api/resources/unstable/types/PhoneSwitch.ts index 3e6aad44..5fbeb892 100644 --- a/src/api/resources/unstable/types/PhoneSwitch.ts +++ b/src/api/resources/unstable/types/PhoneSwitch.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Phone Switch Response diff --git a/src/api/resources/unstable/types/QuickReplyOption.ts b/src/api/resources/unstable/types/QuickReplyOption.ts index 379777e5..8de2d400 100644 --- a/src/api/resources/unstable/types/QuickReplyOption.ts +++ b/src/api/resources/unstable/types/QuickReplyOption.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export interface QuickReplyOption { /** The text to display in this quick reply option. */ diff --git a/src/api/resources/unstable/types/Recipient.ts b/src/api/resources/unstable/types/Recipient.ts index 25e28bb9..194d11d0 100644 --- a/src/api/resources/unstable/types/Recipient.ts +++ b/src/api/resources/unstable/types/Recipient.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A recipient of a message @@ -13,12 +11,10 @@ export interface Recipient { } export namespace Recipient { - /** - * The role associated to the contact - `user` or `lead`. - */ - export type Type = "user" | "lead"; + /** The role associated to the contact - `user` or `lead`. */ export const Type = { User: "user", Lead: "lead", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } diff --git a/src/api/resources/unstable/types/RedactConversationRequest.ts b/src/api/resources/unstable/types/RedactConversationRequest.ts index 968bb6af..f4845e8e 100644 --- a/src/api/resources/unstable/types/RedactConversationRequest.ts +++ b/src/api/resources/unstable/types/RedactConversationRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; export type RedactConversationRequest = /** diff --git a/src/api/resources/unstable/types/Reference.ts b/src/api/resources/unstable/types/Reference.ts index b14f584f..7c9c82a3 100644 --- a/src/api/resources/unstable/types/Reference.ts +++ b/src/api/resources/unstable/types/Reference.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * reference to another object diff --git a/src/api/resources/unstable/types/RegisterFinVoiceCallRequest.ts b/src/api/resources/unstable/types/RegisterFinVoiceCallRequest.ts new file mode 100644 index 00000000..2fd07f21 --- /dev/null +++ b/src/api/resources/unstable/types/RegisterFinVoiceCallRequest.ts @@ -0,0 +1,25 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Register a Fin Voice call with Intercom + */ +export interface RegisterFinVoiceCallRequest { + /** Phone number in E.164 format for the call */ + phone_number: string; + /** External call identifier from the call provider */ + call_id: string; + /** Source of the call. Can be "five9", "zoom_phone", or defaults to "aws_connect" */ + source?: RegisterFinVoiceCallRequest.Source; + /** Additional metadata about the call */ + data?: Record; +} + +export namespace RegisterFinVoiceCallRequest { + /** Source of the call. Can be "five9", "zoom_phone", or defaults to "aws_connect" */ + export const Source = { + Five9: "five9", + ZoomPhone: "zoom_phone", + AwsConnect: "aws_connect", + } as const; + export type Source = (typeof Source)[keyof typeof Source]; +} diff --git a/src/api/resources/unstable/types/ReplyConversationRequestBody.ts b/src/api/resources/unstable/types/ReplyConversationRequestBody.ts index 261d4f73..3f05df15 100644 --- a/src/api/resources/unstable/types/ReplyConversationRequestBody.ts +++ b/src/api/resources/unstable/types/ReplyConversationRequestBody.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; export type ReplyConversationRequestBody = | Intercom.unstable.ContactReplyConversationRequest diff --git a/src/api/resources/unstable/types/SearchRequest.ts b/src/api/resources/unstable/types/SearchRequest.ts index 7dc82a61..796d8fc5 100644 --- a/src/api/resources/unstable/types/SearchRequest.ts +++ b/src/api/resources/unstable/types/SearchRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Search using Intercoms Search APIs. diff --git a/src/api/resources/unstable/types/SegmentList.ts b/src/api/resources/unstable/types/SegmentList.ts index 22f29cc3..7a3ae83b 100644 --- a/src/api/resources/unstable/types/SegmentList.ts +++ b/src/api/resources/unstable/types/SegmentList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * This will return a list of Segment Objects. The result may also have a pages object if the response is paginated. diff --git a/src/api/resources/unstable/types/SingleFilterSearchRequest.ts b/src/api/resources/unstable/types/SingleFilterSearchRequest.ts index 1d1e1613..58808cb4 100644 --- a/src/api/resources/unstable/types/SingleFilterSearchRequest.ts +++ b/src/api/resources/unstable/types/SingleFilterSearchRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Search using Intercoms Search APIs with a single filter. @@ -15,10 +13,7 @@ export interface SingleFilterSearchRequest { } export namespace SingleFilterSearchRequest { - /** - * The accepted operators you can use to define how you want to search for the value. - */ - export type Operator = "=" | "!=" | "IN" | "NIN" | "<" | ">"; + /** The accepted operators you can use to define how you want to search for the value. */ export const Operator = { EqualTo: "=", NotEquals: "!=", @@ -27,6 +22,7 @@ export namespace SingleFilterSearchRequest { LessThan: "<", GreaterThan: ">", } as const; + export type Operator = (typeof Operator)[keyof typeof Operator]; /** * The value that you want to search on. */ diff --git a/src/api/resources/unstable/types/SlaApplied.ts b/src/api/resources/unstable/types/SlaApplied.ts index 1a7049bb..3ea77f62 100644 --- a/src/api/resources/unstable/types/SlaApplied.ts +++ b/src/api/resources/unstable/types/SlaApplied.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The SLA Applied object contains the details for which SLA has been applied to this conversation. @@ -27,11 +25,11 @@ export namespace SlaApplied { * - `missed`: If there are any missed sla_events for the conversation and no canceled events. If there’s even a single missed sla event, the status will always be missed. A missed status is not applied when the SLA expires, only the next time a teammate replies. * - `active`: An SLA has been applied to a conversation, but has not yet been fulfilled. SLA status is active only if there are no “hit, “missed”, or “canceled” events. */ - export type SlaStatus = "hit" | "missed" | "cancelled" | "active"; export const SlaStatus = { Hit: "hit", Missed: "missed", Cancelled: "cancelled", Active: "active", } as const; + export type SlaStatus = (typeof SlaStatus)[keyof typeof SlaStatus]; } diff --git a/src/api/resources/unstable/types/SnoozeConversationRequest.ts b/src/api/resources/unstable/types/SnoozeConversationRequest.ts index 25429753..7e3e7061 100644 --- a/src/api/resources/unstable/types/SnoozeConversationRequest.ts +++ b/src/api/resources/unstable/types/SnoozeConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Payload of the request to snooze a conversation diff --git a/src/api/resources/unstable/types/SocialProfile.ts b/src/api/resources/unstable/types/SocialProfile.ts index 3598c433..5beba459 100644 --- a/src/api/resources/unstable/types/SocialProfile.ts +++ b/src/api/resources/unstable/types/SocialProfile.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A Social Profile allows you to label your contacts, companies, and conversations and list them using that Social Profile. diff --git a/src/api/resources/unstable/types/StartingAfterPaging.ts b/src/api/resources/unstable/types/StartingAfterPaging.ts index e2d31e3f..6fc82b73 100644 --- a/src/api/resources/unstable/types/StartingAfterPaging.ts +++ b/src/api/resources/unstable/types/StartingAfterPaging.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export interface StartingAfterPaging { /** The number of results to fetch per page. */ diff --git a/src/api/resources/unstable/types/SubscriptionTypeList.ts b/src/api/resources/unstable/types/SubscriptionTypeList.ts index 3aa55e5c..977b74d8 100644 --- a/src/api/resources/unstable/types/SubscriptionTypeList.ts +++ b/src/api/resources/unstable/types/SubscriptionTypeList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of subscription type objects. diff --git a/src/api/resources/unstable/types/TagCompanyRequest.ts b/src/api/resources/unstable/types/TagCompanyRequest.ts index 23231949..4f4affb5 100644 --- a/src/api/resources/unstable/types/TagCompanyRequest.ts +++ b/src/api/resources/unstable/types/TagCompanyRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * You can tag a single company or a list of companies. diff --git a/src/api/resources/unstable/types/TagList.ts b/src/api/resources/unstable/types/TagList.ts index f42df4b4..5aba89c4 100644 --- a/src/api/resources/unstable/types/TagList.ts +++ b/src/api/resources/unstable/types/TagList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of tags objects in the workspace. diff --git a/src/api/resources/unstable/types/TagMultipleUsersRequest.ts b/src/api/resources/unstable/types/TagMultipleUsersRequest.ts index df2f72b2..fc697987 100644 --- a/src/api/resources/unstable/types/TagMultipleUsersRequest.ts +++ b/src/api/resources/unstable/types/TagMultipleUsersRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * You can tag a list of users. diff --git a/src/api/resources/unstable/types/Tags.ts b/src/api/resources/unstable/types/Tags.ts index 980aba63..e968cf71 100644 --- a/src/api/resources/unstable/types/Tags.ts +++ b/src/api/resources/unstable/types/Tags.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of tags objects associated with a conversation diff --git a/src/api/resources/unstable/types/TeamList.ts b/src/api/resources/unstable/types/TeamList.ts index 6728f16f..c711e412 100644 --- a/src/api/resources/unstable/types/TeamList.ts +++ b/src/api/resources/unstable/types/TeamList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * This will return a list of team objects for the App. diff --git a/src/api/resources/unstable/types/TeamPriorityLevel.ts b/src/api/resources/unstable/types/TeamPriorityLevel.ts index b979fa1d..07d6bae5 100644 --- a/src/api/resources/unstable/types/TeamPriorityLevel.ts +++ b/src/api/resources/unstable/types/TeamPriorityLevel.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Admin priority levels for teams diff --git a/src/api/resources/unstable/types/TicketCustomAttributes.ts b/src/api/resources/unstable/types/TicketCustomAttributes.ts index 50eb281d..c3cb349e 100644 --- a/src/api/resources/unstable/types/TicketCustomAttributes.ts +++ b/src/api/resources/unstable/types/TicketCustomAttributes.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * An object containing the different attributes associated to the ticket as key-value pairs. For the default title and description attributes, the keys are `_default_title_` and `_default_description_`. diff --git a/src/api/resources/unstable/types/TicketList.ts b/src/api/resources/unstable/types/TicketList.ts index 0457d26e..b1545342 100644 --- a/src/api/resources/unstable/types/TicketList.ts +++ b/src/api/resources/unstable/types/TicketList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Tickets are how you track requests from your users. diff --git a/src/api/resources/unstable/types/TicketPartAuthor.ts b/src/api/resources/unstable/types/TicketPartAuthor.ts index 6dc2eb3b..e0ea7ff3 100644 --- a/src/api/resources/unstable/types/TicketPartAuthor.ts +++ b/src/api/resources/unstable/types/TicketPartAuthor.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The author that wrote or triggered the part. Can be a bot, admin, team or user. @@ -17,14 +15,12 @@ export interface TicketPartAuthor { } export namespace TicketPartAuthor { - /** - * The type of the author - */ - export type Type = "admin" | "bot" | "team" | "user"; + /** The type of the author */ export const Type = { Admin: "admin", Bot: "bot", Team: "team", User: "user", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } diff --git a/src/api/resources/unstable/types/TicketParts.ts b/src/api/resources/unstable/types/TicketParts.ts index f4847b22..95c99271 100644 --- a/src/api/resources/unstable/types/TicketParts.ts +++ b/src/api/resources/unstable/types/TicketParts.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of Ticket Part objects for each note and event in the ticket. There is a limit of 500 parts. diff --git a/src/api/resources/unstable/types/TicketReply.ts b/src/api/resources/unstable/types/TicketReply.ts index d1e66754..1a648076 100644 --- a/src/api/resources/unstable/types/TicketReply.ts +++ b/src/api/resources/unstable/types/TicketReply.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A Ticket Part representing a note, comment, or quick_reply on a ticket @@ -28,13 +26,11 @@ export interface TicketReply { } export namespace TicketReply { - /** - * Type of the part - */ - export type PartType = "note" | "comment" | "quick_reply"; + /** Type of the part */ export const PartType = { Note: "note", Comment: "comment", QuickReply: "quick_reply", } as const; + export type PartType = (typeof PartType)[keyof typeof PartType]; } diff --git a/src/api/resources/unstable/types/TicketRequestCustomAttributes.ts b/src/api/resources/unstable/types/TicketRequestCustomAttributes.ts index 6a3af042..6f54ade8 100644 --- a/src/api/resources/unstable/types/TicketRequestCustomAttributes.ts +++ b/src/api/resources/unstable/types/TicketRequestCustomAttributes.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The attributes set on the ticket. When setting the default title and description attributes, the attribute keys that should be used are `_default_title_` and `_default_description_`. When setting ticket type attributes of the list attribute type, the key should be the attribute name and the value of the attribute should be the list item id, obtainable by [listing the ticket type](ref:get_ticket-types). For example, if the ticket type has an attribute called `priority` of type `list`, the key should be `priority` and the value of the attribute should be the guid of the list item (e.g. `de1825a0-0164-4070-8ca6-13e22462fa7e`). diff --git a/src/api/resources/unstable/types/TicketStateList.ts b/src/api/resources/unstable/types/TicketStateList.ts index 7e3bfbe6..51e43516 100644 --- a/src/api/resources/unstable/types/TicketStateList.ts +++ b/src/api/resources/unstable/types/TicketStateList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of ticket states associated with a given ticket type. diff --git a/src/api/resources/unstable/types/TicketTypeAttribute.ts b/src/api/resources/unstable/types/TicketTypeAttribute.ts index 269e5f99..f634dd96 100644 --- a/src/api/resources/unstable/types/TicketTypeAttribute.ts +++ b/src/api/resources/unstable/types/TicketTypeAttribute.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Ticket type attribute, used to define each data field to be captured in a ticket. diff --git a/src/api/resources/unstable/types/TicketTypeAttributeList.ts b/src/api/resources/unstable/types/TicketTypeAttributeList.ts index ed242103..1466cda0 100644 --- a/src/api/resources/unstable/types/TicketTypeAttributeList.ts +++ b/src/api/resources/unstable/types/TicketTypeAttributeList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of attributes associated with a given ticket type. diff --git a/src/api/resources/unstable/types/TicketTypeList.ts b/src/api/resources/unstable/types/TicketTypeList.ts index 572085e6..7b839c67 100644 --- a/src/api/resources/unstable/types/TicketTypeList.ts +++ b/src/api/resources/unstable/types/TicketTypeList.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * A list of ticket types associated with a given workspace. diff --git a/src/api/resources/unstable/types/Translation.ts b/src/api/resources/unstable/types/Translation.ts index 9807efeb..3d656a16 100644 --- a/src/api/resources/unstable/types/Translation.ts +++ b/src/api/resources/unstable/types/Translation.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A translation object contains the localised details of a subscription type. diff --git a/src/api/resources/unstable/types/UntagCompanyRequest.ts b/src/api/resources/unstable/types/UntagCompanyRequest.ts index b970ebc4..09886bd1 100644 --- a/src/api/resources/unstable/types/UntagCompanyRequest.ts +++ b/src/api/resources/unstable/types/UntagCompanyRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * You can tag a single company or a list of companies. diff --git a/src/api/resources/unstable/types/UpdateDataAttributeRequestBody.ts b/src/api/resources/unstable/types/UpdateDataAttributeRequestBody.ts new file mode 100644 index 00000000..6524ae99 --- /dev/null +++ b/src/api/resources/unstable/types/UpdateDataAttributeRequestBody.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * + */ +export type UpdateDataAttributeRequestBody = + | { + options: { + value?: string | undefined; + }[]; + } + | unknown; diff --git a/src/api/resources/unstable/types/UpdateTicketTypeRequestBody.ts b/src/api/resources/unstable/types/UpdateTicketTypeRequestBody.ts deleted file mode 100644 index 2eca441d..00000000 --- a/src/api/resources/unstable/types/UpdateTicketTypeRequestBody.ts +++ /dev/null @@ -1,34 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * The request payload for updating a ticket type. - * You can copy the `icon` property for your ticket type from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) - */ -export interface UpdateTicketTypeRequestBody { - /** The name of the ticket type. */ - name?: string; - /** The description of the ticket type. */ - description?: string; - /** Category of the Ticket Type. */ - category?: UpdateTicketTypeRequestBody.Category; - /** The icon of the ticket type. */ - icon?: string; - /** The archived status of the ticket type. */ - archived?: boolean; - /** Whether the tickets associated with this ticket type are intended for internal use only or will be shared with customers. This is currently a limited attribute. */ - is_internal?: boolean; -} - -export namespace UpdateTicketTypeRequestBody { - /** - * Category of the Ticket Type. - */ - export type Category = "Customer" | "Back-office" | "Tracker"; - export const Category = { - Customer: "Customer", - BackOffice: "Back-office", - Tracker: "Tracker", - } as const; -} diff --git a/src/api/resources/unstable/types/Visitor.ts b/src/api/resources/unstable/types/Visitor.ts index 272de16a..32dcf169 100644 --- a/src/api/resources/unstable/types/Visitor.ts +++ b/src/api/resources/unstable/types/Visitor.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../index"; +import type * as Intercom from "../../../index.js"; /** * Visitors are useful for representing anonymous people that have not yet been identified. They usually represent website visitors. Visitors are not visible in Intercom platform. The Visitors resource provides methods to fetch, update, convert and delete. diff --git a/src/api/resources/unstable/types/VisitorDeletedObject.ts b/src/api/resources/unstable/types/VisitorDeletedObject.ts index 6d2dcfd3..6a3cc196 100644 --- a/src/api/resources/unstable/types/VisitorDeletedObject.ts +++ b/src/api/resources/unstable/types/VisitorDeletedObject.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Response returned when an object is deleted diff --git a/src/api/resources/unstable/types/WhatsappMessageStatusList.ts b/src/api/resources/unstable/types/WhatsappMessageStatusList.ts index 71377c21..b1d0e8d8 100644 --- a/src/api/resources/unstable/types/WhatsappMessageStatusList.ts +++ b/src/api/resources/unstable/types/WhatsappMessageStatusList.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export interface WhatsappMessageStatusList { type: "list"; @@ -56,16 +54,14 @@ export namespace WhatsappMessageStatusList { } export namespace Item { - /** - * Current status of the message - */ - export type Status = "sent" | "delivered" | "read" | "failed"; + /** Current status of the message */ export const Status = { Sent: "sent", Delivered: "delivered", Read: "read", Failed: "failed", } as const; + export type Status = (typeof Status)[keyof typeof Status]; } } } diff --git a/src/api/resources/unstable/types/index.ts b/src/api/resources/unstable/types/index.ts index 129ed3c6..ff1cd877 100644 --- a/src/api/resources/unstable/types/index.ts +++ b/src/api/resources/unstable/types/index.ts @@ -1,145 +1,154 @@ -export * from "./NotFoundErrorBody"; -export * from "./Datetime"; -export * from "./ActivityLog"; -export * from "./ActivityLogList"; -export * from "./ActivityLogMetadata"; -export * from "./AddressableList"; -export * from "./AdminList"; -export * from "./AdminPriorityLevel"; -export * from "./AdminReplyConversationRequest"; -export * from "./AdminReplyTicketRequest"; -export * from "./AdminWithApp"; -export * from "./App"; -export * from "./ArticleContent"; -export * from "./ArticleList"; -export * from "./ArticleStatistics"; -export * from "./ArticleTranslatedContent"; -export * from "./AssignConversationRequest"; -export * from "./AwayStatusReason"; -export * from "./CloseConversationRequest"; -export * from "./CollectionList"; -export * from "./CompanyAttachedContacts"; -export * from "./CompanyAttachedSegments"; -export * from "./CompanyList"; -export * from "./CompanyScroll"; -export * from "./ContactAttachedCompanies"; -export * from "./ContactCompanies"; -export * from "./CompanyData"; -export * from "./ContactDeleted"; -export * from "./ContactList"; -export * from "./ContactLocation"; -export * from "./ContactNotes"; -export * from "./ContactReference"; -export * from "./ContactReplyBaseRequest"; -export * from "./ContactReplyConversationRequest"; -export * from "./ContactReplyEmailRequest"; -export * from "./ContactReplyIntercomUserIdRequest"; -export * from "./ContactReplyTicketEmailRequest"; -export * from "./ContactReplyTicketIntercomUserIdRequest"; -export * from "./ContactReplyTicketRequest"; -export * from "./ContactReplyTicketUserIdRequest"; -export * from "./ContactReplyUserIdRequest"; -export * from "./ContactSegments"; -export * from "./ContactSocialProfiles"; -export * from "./ContactSubscriptionTypes"; -export * from "./ContactTags"; -export * from "./ContactArchived"; -export * from "./ContactUnarchived"; -export * from "./ContactBlocked"; -export * from "./ContentSourcesList"; -export * from "./ConversationAttachmentFiles"; -export * from "./ConversationContacts"; -export * from "./ConversationDeleted"; -export * from "./ConversationFirstContactReply"; -export * from "./ConversationList"; -export * from "./ConversationPart"; -export * from "./ConversationPartAuthor"; -export * from "./ConversationParts"; -export * from "./ConversationPartMetadata"; -export * from "./ConversationRating"; -export * from "./ConversationResponseTime"; -export * from "./ConversationSource"; -export * from "./ConversationStatistics"; -export * from "./ConversationTeammates"; -export * from "./Recipient"; -export * from "./CreateOrUpdateTagRequest"; -export * from "./CreateTicketReplyWithCommentRequest"; -export * from "./CreateTicketRequestBody"; -export * from "./CursorPages"; -export * from "./CustomAttributes"; -export * from "./CustomObjectInstanceDeleted"; -export * from "./CustomObjectInstanceList"; -export * from "./CustomerRequest"; -export * from "./DataAttributeList"; -export * from "./DataEventList"; -export * from "./DataEventSummary"; -export * from "./DataEventSummaryItem"; -export * from "./DataExportCsv"; -export * from "./DeletedArticleObject"; -export * from "./DeletedCollectionObject"; -export * from "./DeletedCompanyObject"; -export * from "./DeletedObject"; -export * from "./EmailAddressHeader"; -export * from "./EmailMessageMetadata"; -export * from "./ConversationAttributeUpdatedByWorkflow"; -export * from "./ConversationAttributeUpdatedByAdmin"; -export * from "./CustomActionStarted"; -export * from "./CustomChannelAttribute"; -export * from "./CustomChannelBaseEvent"; -export * from "./CustomChannelContact"; -export * from "./CustomChannelNotificationResponse"; -export * from "./CustomActionFinished"; -export * from "./OperatorWorkflowEvent"; -export * from "./EventDetails"; -export * from "./Error_"; -export * from "./FileAttribute"; -export * from "./GroupContent"; -export * from "./GroupTranslatedContent"; -export * from "./IntercomVersion"; -export * from "./LinkedObject"; -export * from "./IntercomVersionUnstable"; -export * from "./LinkedObjectList"; -export * from "./WhatsappMessageStatusList"; -export * from "./MultipleFilterSearchRequest"; -export * from "./NewsItemRequest"; -export * from "./NoteList"; -export * from "./OpenConversationRequest"; -export * from "./PagesLink"; -export * from "./PaginatedResponseDataItem"; -export * from "./PaginatedResponse"; -export * from "./PartAttachment"; -export * from "./PhoneSwitch"; -export * from "./QuickReplyOption"; -export * from "./RedactConversationRequest"; -export * from "./Reference"; -export * from "./ReplyConversationRequestBody"; -export * from "./SearchRequest"; -export * from "./SegmentList"; -export * from "./SingleFilterSearchRequest"; -export * from "./SlaApplied"; -export * from "./SnoozeConversationRequest"; -export * from "./SocialProfile"; -export * from "./StartingAfterPaging"; -export * from "./SubscriptionTypeList"; -export * from "./TagCompanyRequest"; -export * from "./TagList"; -export * from "./TagMultipleUsersRequest"; -export * from "./Tags"; -export * from "./TeamList"; -export * from "./TeamPriorityLevel"; -export * from "./TicketCustomAttributes"; -export * from "./TicketList"; -export * from "./TicketPartAuthor"; -export * from "./TicketParts"; -export * from "./TicketReply"; -export * from "./TicketRequestCustomAttributes"; -export * from "./TicketStateList"; -export * from "./TicketTypeAttribute"; -export * from "./TicketTypeAttributeList"; -export * from "./TicketTypeList"; -export * from "./Translation"; -export * from "./UntagCompanyRequest"; -export * from "./UpdateArticleRequestBody"; -export * from "./UpdateTicketTypeRequestBody"; -export * from "./Visitor"; -export * from "./VisitorDeletedObject"; +export * from "./ActivityLog.js"; +export * from "./ActivityLogList.js"; +export * from "./ActivityLogMetadata.js"; +export * from "./AddressableList.js"; +export * from "./AdminList.js"; +export * from "./AdminPriorityLevel.js"; +export * from "./AdminReplyConversationRequest.js"; +export * from "./AdminReplyTicketRequest.js"; +export * from "./AdminWithApp.js"; +export * from "./AiCallResponse.js"; +export * from "./App.js"; +export * from "./ArticleContent.js"; +export * from "./ArticleList.js"; +export * from "./ArticleStatistics.js"; +export * from "./ArticleTranslatedContent.js"; +export * from "./AssignConversationRequest.js"; +export * from "./AwayStatusReason.js"; +export * from "./CallList.js"; +export * from "./CloseConversationRequest.js"; +export * from "./CollectionList.js"; +export * from "./CompanyAttachedContacts.js"; +export * from "./CompanyAttachedSegments.js"; +export * from "./CompanyData.js"; +export * from "./CompanyList.js"; +export * from "./CompanyScroll.js"; +export * from "./ContactArchived.js"; +export * from "./ContactAttachedCompanies.js"; +export * from "./ContactBlocked.js"; +export * from "./ContactCompanies.js"; +export * from "./ContactDeleted.js"; +export * from "./ContactList.js"; +export * from "./ContactLocation.js"; +export * from "./ContactNotes.js"; +export * from "./ContactReference.js"; +export * from "./ContactReplyBaseRequest.js"; +export * from "./ContactReplyConversationRequest.js"; +export * from "./ContactReplyEmailRequest.js"; +export * from "./ContactReplyIntercomUserIdRequest.js"; +export * from "./ContactReplyTicketEmailRequest.js"; +export * from "./ContactReplyTicketIntercomUserIdRequest.js"; +export * from "./ContactReplyTicketRequest.js"; +export * from "./ContactReplyTicketUserIdRequest.js"; +export * from "./ContactReplyUserIdRequest.js"; +export * from "./ContactSegments.js"; +export * from "./ContactSocialProfiles.js"; +export * from "./ContactSubscriptionTypes.js"; +export * from "./ContactTags.js"; +export * from "./ContactUnarchived.js"; +export * from "./ContentSourcesList.js"; +export * from "./ConversationAttachmentFiles.js"; +export * from "./ConversationAttributeUpdatedByAdmin.js"; +export * from "./ConversationAttributeUpdatedByWorkflow.js"; +export * from "./ConversationContacts.js"; +export * from "./ConversationDeleted.js"; +export * from "./ConversationFirstContactReply.js"; +export * from "./ConversationList.js"; +export * from "./ConversationPart.js"; +export * from "./ConversationPartAuthor.js"; +export * from "./ConversationPartMetadata.js"; +export * from "./ConversationParts.js"; +export * from "./ConversationRating.js"; +export * from "./ConversationResponseTime.js"; +export * from "./ConversationSource.js"; +export * from "./ConversationStatistics.js"; +export * from "./ConversationTeammates.js"; +export * from "./CreateArticleRequest.js"; +export * from "./CreateDataAttributeRequest.js"; +export * from "./CreateInternalArticleRequest.js"; +export * from "./CreateMessageRequest.js"; +export * from "./CreateOrUpdateCompanyRequest.js"; +export * from "./CreateOrUpdateTagRequest.js"; +export * from "./CreatePhoneSwitchRequest.js"; +export * from "./CreateTicketReplyWithCommentRequest.js"; +export * from "./CreateTicketRequestBody.js"; +export * from "./CreateTicketTypeRequest.js"; +export * from "./CursorPages.js"; +export * from "./CustomActionFinished.js"; +export * from "./CustomActionStarted.js"; +export * from "./CustomAttributes.js"; +export * from "./CustomChannelAttribute.js"; +export * from "./CustomChannelBaseEvent.js"; +export * from "./CustomChannelContact.js"; +export * from "./CustomChannelNotificationResponse.js"; +export * from "./CustomerRequest.js"; +export * from "./CustomObjectInstanceDeleted.js"; +export * from "./CustomObjectInstanceList.js"; +export * from "./DataAttributeList.js"; +export * from "./DataEventList.js"; +export * from "./DataEventSummary.js"; +export * from "./DataEventSummaryItem.js"; +export * from "./DataExportCsv.js"; +export * from "./Datetime.js"; +export * from "./DeletedArticleObject.js"; +export * from "./DeletedCollectionObject.js"; +export * from "./DeletedCompanyObject.js"; +export * from "./DeletedInternalArticleObject.js"; +export * from "./DeletedObject.js"; +export * from "./EmailAddressHeader.js"; +export * from "./EmailMessageMetadata.js"; +export * from "./Error_.js"; +export * from "./EventDetails.js"; +export * from "./FileAttribute.js"; +export * from "./GroupContent.js"; +export * from "./GroupTranslatedContent.js"; +export * from "./InternalArticleList.js"; +export * from "./LinkedObject.js"; +export * from "./LinkedObjectList.js"; +export * from "./MultipleFilterSearchRequest.js"; +export * from "./NewsItemRequest.js"; +export * from "./NoteList.js"; +export * from "./NotFoundErrorBody.js"; +export * from "./OpenConversationRequest.js"; +export * from "./OperatorWorkflowEvent.js"; +export * from "./PagesLink.js"; +export * from "./PaginatedResponse.js"; +export * from "./PaginatedResponseDataItem.js"; +export * from "./PartAttachment.js"; +export * from "./PhoneSwitch.js"; +export * from "./QuickReplyOption.js"; +export * from "./Recipient.js"; +export * from "./RedactConversationRequest.js"; +export * from "./Reference.js"; +export * from "./RegisterFinVoiceCallRequest.js"; +export * from "./ReplyConversationRequestBody.js"; +export * from "./SearchRequest.js"; +export * from "./SegmentList.js"; +export * from "./SingleFilterSearchRequest.js"; +export * from "./SlaApplied.js"; +export * from "./SnoozeConversationRequest.js"; +export * from "./SocialProfile.js"; +export * from "./StartingAfterPaging.js"; +export * from "./SubscriptionTypeList.js"; +export * from "./TagCompanyRequest.js"; +export * from "./TagList.js"; +export * from "./TagMultipleUsersRequest.js"; +export * from "./Tags.js"; +export * from "./TeamList.js"; +export * from "./TeamPriorityLevel.js"; +export * from "./TicketCustomAttributes.js"; +export * from "./TicketList.js"; +export * from "./TicketPartAuthor.js"; +export * from "./TicketParts.js"; +export * from "./TicketReply.js"; +export * from "./TicketRequestCustomAttributes.js"; +export * from "./TicketStateList.js"; +export * from "./TicketTypeAttribute.js"; +export * from "./TicketTypeAttributeList.js"; +export * from "./TicketTypeList.js"; +export * from "./Translation.js"; +export * from "./UntagCompanyRequest.js"; +export * from "./UpdateDataAttributeRequestBody.js"; +export * from "./Visitor.js"; +export * from "./VisitorDeletedObject.js"; +export * from "./WhatsappMessageStatusList.js"; diff --git a/src/api/resources/visitors/client/Client.ts b/src/api/resources/visitors/client/Client.ts index e18896e6..097e5ada 100644 --- a/src/api/resources/visitors/client/Client.ts +++ b/src/api/resources/visitors/client/Client.ts @@ -1,85 +1,35 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as environments from "../../../../environments"; -import * as core from "../../../../core"; -import * as Intercom from "../../../index"; -import urlJoin from "url-join"; -import * as errors from "../../../../errors/index"; +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; -export declare namespace Visitors { - export interface Options { - environment?: core.Supplier; - /** Specify a custom URL to connect the client to. */ - baseUrl?: core.Supplier; - token?: core.Supplier; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - fetcher?: core.FetchFunction; - } +export declare namespace VisitorsClient { + export interface Options extends BaseClientOptions {} - export interface RequestOptions { - /** The maximum time to wait for a response in seconds. */ - timeoutInSeconds?: number; - /** The number of times to retry the request. Defaults to 2. */ - maxRetries?: number; - /** A hook to abort the request. */ - abortSignal?: AbortSignal; - /** Additional headers to include in the request. */ - headers?: Record; - /** Override the Intercom-Version header */ - version?: - | "1.0" - | "1.1" - | "1.2" - | "1.3" - | "1.4" - | "2.0" - | "2.1" - | "2.2" - | "2.3" - | "2.4" - | "2.5" - | "2.6" - | "2.7" - | "2.8" - | "2.9" - | "2.10" - | "2.11" - | "Unstable"; - } + export interface RequestOptions extends BaseRequestOptions {} } /** * Everything about your Visitors */ -export class Visitors { - constructor(protected readonly _options: Visitors.Options = {}) {} +export class VisitorsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: VisitorsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } /** * You can fetch the details of a single visitor. * * @param {Intercom.FindVisitorRequest} request - * @param {Visitors.RequestOptions} requestOptions - Request-specific configuration. + * @param {VisitorsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} @@ -91,46 +41,43 @@ export class Visitors { */ public find( request: Intercom.FindVisitorRequest, - requestOptions?: Visitors.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: VisitorsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__find(request, requestOptions)); } private async __find( request: Intercom.FindVisitorRequest, - requestOptions?: Visitors.RequestOptions, - ): Promise> { + requestOptions?: VisitorsClient.RequestOptions, + ): Promise> { const { user_id: userId } = request; const _queryParams: Record = {}; - _queryParams["user_id"] = userId; + _queryParams.user_id = userId; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "visitors", ), method: "GET", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, - contentType: "application/json", - queryParameters: _queryParams, - requestType: "json", - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + headers: _headers, + queryParameters: { ..._queryParams, ...requestOptions?.queryParams }, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.Visitor, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.Visitor | undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -151,21 +98,7 @@ export class Visitors { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling GET /visitors."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/visitors"); } /** @@ -176,14 +109,14 @@ export class Visitors { * **Option 2.** You can update a visitor by passing in the `id` of the visitor in the Request body. * * @param {Intercom.UpdateVisitorRequest} request - * @param {Visitors.RequestOptions} requestOptions - Request-specific configuration. + * @param {VisitorsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @throws {@link Intercom.NotFoundError} * * @example * await client.visitors.update({ - * id: "667d61cc8a68186f43bafe95", + * id: "6762f30c1bb69f9f2193bc5e", * name: "Gareth Bale" * }) * @@ -195,43 +128,43 @@ export class Visitors { */ public update( request: Intercom.UpdateVisitorRequest, - requestOptions?: Visitors.RequestOptions, - ): core.HttpResponsePromise { + requestOptions?: VisitorsClient.RequestOptions, + ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__update(request, requestOptions)); } private async __update( request: Intercom.UpdateVisitorRequest, - requestOptions?: Visitors.RequestOptions, - ): Promise> { + requestOptions?: VisitorsClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "visitors", ), method: "PUT", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { - return { data: _response.body as Intercom.Visitor, rawResponse: _response.rawResponse }; + return { data: _response.body as Intercom.Visitor | undefined, rawResponse: _response.rawResponse }; } if (_response.error.reason === "status-code") { @@ -252,21 +185,7 @@ export class Visitors { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling PUT /visitors."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/visitors"); } /** @@ -277,7 +196,7 @@ export class Visitors { * > If the User exists, then the Visitor will be merged into it, the Visitor deleted and the User returned. If the User does not exist, the Visitor will be converted to a User, with the User identifiers replacing it's Visitor identifiers. * * @param {Intercom.MergeVisitorToContactRequest} request - * @param {Visitors.RequestOptions} requestOptions - Request-specific configuration. + * @param {VisitorsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Intercom.UnauthorizedError} * @@ -295,40 +214,40 @@ export class Visitors { */ public mergeToContact( request: Intercom.MergeVisitorToContactRequest, - requestOptions?: Visitors.RequestOptions, + requestOptions?: VisitorsClient.RequestOptions, ): core.HttpResponsePromise { return core.HttpResponsePromise.fromPromise(this.__mergeToContact(request, requestOptions)); } private async __mergeToContact( request: Intercom.MergeVisitorToContactRequest, - requestOptions?: Visitors.RequestOptions, + requestOptions?: VisitorsClient.RequestOptions, ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); const _response = await (this._options.fetcher ?? core.fetcher)({ - url: urlJoin( + url: core.url.join( (await core.Supplier.get(this._options.baseUrl)) ?? (await core.Supplier.get(this._options.environment)) ?? environments.IntercomEnvironment.UsProduction, "visitors/convert", ), method: "POST", - headers: { - Authorization: await this._getAuthorizationHeader(), - "X-Fern-Language": "JavaScript", - "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "6.4.0", - "User-Agent": "intercom-client/6.4.0", - "Intercom-Version": requestOptions?.version ?? this._options?.version ?? "2.11", - "X-Fern-Runtime": core.RUNTIME.type, - "X-Fern-Runtime-Version": core.RUNTIME.version, - ...requestOptions?.headers, - }, + headers: _headers, contentType: "application/json", + queryParameters: requestOptions?.queryParams, requestType: "json", body: request, - timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 20000, - maxRetries: requestOptions?.maxRetries, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, }); if (_response.ok) { return { data: _response.body as Intercom.Contact, rawResponse: _response.rawResponse }; @@ -350,32 +269,6 @@ export class Visitors { } } - switch (_response.error.reason) { - case "non-json": - throw new errors.IntercomError({ - statusCode: _response.error.statusCode, - body: _response.error.rawBody, - rawResponse: _response.rawResponse, - }); - case "timeout": - throw new errors.IntercomTimeoutError("Timeout exceeded when calling POST /visitors/convert."); - case "unknown": - throw new errors.IntercomError({ - message: _response.error.errorMessage, - rawResponse: _response.rawResponse, - }); - } - } - - protected async _getAuthorizationHeader(): Promise { - const bearer = (await core.Supplier.get(this._options.token)) ?? process?.env["INTERCOM_API_KEY"]; - if (bearer == null) { - throw new errors.IntercomError({ - message: - "Please specify a bearer by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", - }); - } - - return `Bearer ${bearer}`; + return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/visitors/convert"); } } diff --git a/src/api/resources/visitors/client/index.ts b/src/api/resources/visitors/client/index.ts index 415726b7..195f9aa8 100644 --- a/src/api/resources/visitors/client/index.ts +++ b/src/api/resources/visitors/client/index.ts @@ -1 +1 @@ -export * from "./requests"; +export * from "./requests/index.js"; diff --git a/src/api/resources/visitors/client/requests/FindVisitorRequest.ts b/src/api/resources/visitors/client/requests/FindVisitorRequest.ts index 24bdf1b9..45db1e2d 100644 --- a/src/api/resources/visitors/client/requests/FindVisitorRequest.ts +++ b/src/api/resources/visitors/client/requests/FindVisitorRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example @@ -9,8 +7,6 @@ * } */ export interface FindVisitorRequest { - /** - * The user_id of the Visitor you want to retrieve. - */ + /** The user_id of the Visitor you want to retrieve. */ user_id: string; } diff --git a/src/api/resources/visitors/client/requests/MergeVisitorToContactRequest.ts b/src/api/resources/visitors/client/requests/MergeVisitorToContactRequest.ts index 85a59941..d469c38a 100644 --- a/src/api/resources/visitors/client/requests/MergeVisitorToContactRequest.ts +++ b/src/api/resources/visitors/client/requests/MergeVisitorToContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * @example diff --git a/src/api/resources/visitors/client/requests/index.ts b/src/api/resources/visitors/client/requests/index.ts index c03d0f15..f956dfd4 100644 --- a/src/api/resources/visitors/client/requests/index.ts +++ b/src/api/resources/visitors/client/requests/index.ts @@ -1,2 +1,2 @@ -export { type FindVisitorRequest } from "./FindVisitorRequest"; -export { type MergeVisitorToContactRequest } from "./MergeVisitorToContactRequest"; +export type { FindVisitorRequest } from "./FindVisitorRequest.js"; +export type { MergeVisitorToContactRequest } from "./MergeVisitorToContactRequest.js"; diff --git a/src/api/resources/visitors/index.ts b/src/api/resources/visitors/index.ts index 5ec76921..914b8c3c 100644 --- a/src/api/resources/visitors/index.ts +++ b/src/api/resources/visitors/index.ts @@ -1 +1 @@ -export * from "./client"; +export * from "./client/index.js"; diff --git a/src/api/types/ActionComponent.ts b/src/api/types/ActionComponent.ts deleted file mode 100644 index c97feba7..00000000 --- a/src/api/types/ActionComponent.ts +++ /dev/null @@ -1,24 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -export type ActionComponent = - | Intercom.ActionComponent.Sheet - | Intercom.ActionComponent.Url - | Intercom.ActionComponent.Submit; - -export namespace ActionComponent { - export interface Sheet extends Intercom.SheetActionComponent { - type: "sheet"; - } - - export interface Url extends Intercom.UrlActionComponent { - type: "url"; - } - - export interface Submit extends Intercom.SubmitActionComponent { - type: "submit"; - } -} diff --git a/src/api/types/ActivityLog.ts b/src/api/types/ActivityLog.ts index 80328f6f..ddf4451d 100644 --- a/src/api/types/ActivityLog.ts +++ b/src/api/types/ActivityLog.ts @@ -1,21 +1,19 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Activities performed by Admins. */ export interface ActivityLog { /** The id representing the activity. */ - id: string; + id?: string; /** Details about the Admin involved in the activity. */ - performed_by: ActivityLog.PerformedBy; + performed_by?: ActivityLog.PerformedBy; metadata?: Intercom.ActivityLogMetadata; /** The time the activity was created. */ created_at?: number; - activity_type: ActivityLog.ActivityType; + activity_type?: ActivityLog.ActivityType; /** A sentence or two describing the activity. */ activity_description?: string; } @@ -26,7 +24,7 @@ export namespace ActivityLog { */ export interface PerformedBy { /** String representing the object's type. Always has the value `admin`. */ - type?: "admin"; + type?: string; /** The id representing the admin. */ id?: string; /** The email of the admin. */ @@ -35,81 +33,16 @@ export namespace ActivityLog { ip?: string; } - export type ActivityType = - | "admin_assignment_limit_change" - | "admin_away_mode_change" - | "admin_deletion" - | "admin_deprovisioned" - | "admin_impersonation_end" - | "admin_impersonation_start" - | "admin_invite_change" - | "admin_invite_creation" - | "admin_invite_deletion" - | "admin_login_failure" - | "admin_login_success" - | "admin_logout" - | "admin_password_reset_request" - | "admin_password_reset_success" - | "admin_permission_change" - | "admin_provisioned" - | "admin_two_factor_auth_change" - | "admin_unauthorized_sign_in_method" - | "app_admin_join" - | "app_authentication_method_change" - | "app_data_deletion" - | "app_data_export" - | "app_google_sso_domain_change" - | "app_identity_verification_change" - | "app_name_change" - | "app_outbound_address_change" - | "app_package_installation" - | "app_package_token_regeneration" - | "app_package_uninstallation" - | "app_team_creation" - | "app_team_deletion" - | "app_team_membership_modification" - | "app_timezone_change" - | "app_webhook_creation" - | "app_webhook_deletion" - | "articles_in_messenger_enabled_change" - | "bulk_delete" - | "bulk_export" - | "campaign_deletion" - | "campaign_state_change" - | "conversation_part_deletion" - | "conversation_topic_change" - | "conversation_topic_creation" - | "conversation_topic_deletion" - | "help_center_settings_change" - | "inbound_conversations_change" - | "inbox_access_change" - | "message_deletion" - | "message_state_change" - | "messenger_look_and_feel_change" - | "messenger_search_required_change" - | "messenger_spaces_change" - | "office_hours_change" - | "role_change" - | "role_creation" - | "role_deletion" - | "ruleset_activation_title_preview" - | "ruleset_creation" - | "ruleset_deletion" - | "search_browse_enabled_change" - | "search_browse_required_change" - | "seat_change" - | "seat_revoke" - | "security_settings_change" - | "temporary_expectation_change" - | "upfront_email_collection_change" - | "welcome_message_change"; export const ActivityType = { - AdminAssignmentLimitChange: "admin_assignment_limit_change", + AdminConversationAssignmentLimitChange: "admin_conversation_assignment_limit_change", + AdminTicketAssignmentLimitChange: "admin_ticket_assignment_limit_change", AdminAwayModeChange: "admin_away_mode_change", AdminDeletion: "admin_deletion", AdminDeprovisioned: "admin_deprovisioned", AdminImpersonationEnd: "admin_impersonation_end", AdminImpersonationStart: "admin_impersonation_start", + AdminImpersonationConsentApproved: "admin_impersonation_consent_approved", + AdminImpersonationConsentRevoked: "admin_impersonation_consent_revoked", AdminInviteChange: "admin_invite_change", AdminInviteCreation: "admin_invite_creation", AdminInviteDeletion: "admin_invite_deletion", @@ -140,6 +73,7 @@ export namespace ActivityLog { AppWebhookCreation: "app_webhook_creation", AppWebhookDeletion: "app_webhook_deletion", ArticlesInMessengerEnabledChange: "articles_in_messenger_enabled_change", + AutomaticAwayModeSettingChange: "automatic_away_mode_setting_change", BulkDelete: "bulk_delete", BulkExport: "bulk_export", CampaignDeletion: "campaign_deletion", @@ -148,14 +82,22 @@ export namespace ActivityLog { ConversationTopicChange: "conversation_topic_change", ConversationTopicCreation: "conversation_topic_creation", ConversationTopicDeletion: "conversation_topic_deletion", + CustomAuthenticationTokenCreation: "custom_authentication_token_creation", HelpCenterSettingsChange: "help_center_settings_change", InboundConversationsChange: "inbound_conversations_change", InboxAccessChange: "inbox_access_change", + MacroCreation: "macro_creation", + MacroDeletion: "macro_deletion", + MacroUpdated: "macro_updated", + MaliciousDomainsSettingChange: "malicious_domains_setting_change", MessageDeletion: "message_deletion", MessageStateChange: "message_state_change", + MessengerApiSecretCreation: "messenger_api_secret_creation", + MessengerApiSecretDeletion: "messenger_api_secret_deletion", MessengerLookAndFeelChange: "messenger_look_and_feel_change", MessengerSearchRequiredChange: "messenger_search_required_change", MessengerSpacesChange: "messenger_spaces_change", + OauthTokenRevocation: "oauth_token_revocation", OfficeHoursChange: "office_hours_change", RoleChange: "role_change", RoleCreation: "role_creation", @@ -168,8 +110,23 @@ export namespace ActivityLog { SeatChange: "seat_change", SeatRevoke: "seat_revoke", SecuritySettingsChange: "security_settings_change", + StripInboundEmailLinksChange: "strip_inbound_email_links_change", TemporaryExpectationChange: "temporary_expectation_change", + TeamAssignmentLimitChange: "team_assignment_limit_change", + TrustedDomainsSettingChange: "trusted_domains_setting_change", + UnassignUnsnoozedAtCapacitySettingChange: "unassign_unsnoozed_at_capacity_setting_change", UpfrontEmailCollectionChange: "upfront_email_collection_change", + AllowedAttachmentFiletypesSettingChange: "allowed_attachment_filetypes_setting_change", + AttachUploadsInlineSettingChange: "attach_uploads_inline_setting_change", + TeammateGifsSettingChange: "teammate_gifs_setting_change", + UserCameraAttachmentsSettingChange: "user_camera_attachments_setting_change", + UserConversationAttachmentsSettingChange: "user_conversation_attachments_setting_change", + UserFileAttachmentsSettingChange: "user_file_attachments_setting_change", + UserGifsSettingChange: "user_gifs_setting_change", + UserMediaAttachmentsSettingChange: "user_media_attachments_setting_change", + UserVoiceNotesSettingChange: "user_voice_notes_setting_change", WelcomeMessageChange: "welcome_message_change", + WorkspaceDeletionRequest: "workspace_deletion_request", } as const; + export type ActivityType = (typeof ActivityType)[keyof typeof ActivityType]; } diff --git a/src/api/types/ActivityLogList.ts b/src/api/types/ActivityLogList.ts index ff4d942a..6a1253cc 100644 --- a/src/api/types/ActivityLogList.ts +++ b/src/api/types/ActivityLogList.ts @@ -1,16 +1,14 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A paginated list of activity logs. */ export interface ActivityLogList { /** String representing the object's type. Always has the value `activity_log.list`. */ - type: "activity_log.list"; + type?: string; pages?: Intercom.CursorPages; /** An array of activity logs */ - activity_logs: Intercom.ActivityLog[]; + activity_logs?: (Intercom.ActivityLog | undefined)[]; } diff --git a/src/api/types/ActivityLogMetadata.ts b/src/api/types/ActivityLogMetadata.ts index 4814d8e5..ed4bfcf2 100644 --- a/src/api/types/ActivityLogMetadata.ts +++ b/src/api/types/ActivityLogMetadata.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Additional data provided about Admin activity. @@ -24,4 +22,34 @@ export interface ActivityLogMetadata { update_by?: number; /** The name of the Admin who initiated the activity. */ update_by_name?: string; + /** The conversation assignment limit value for an admin. */ + conversation_assignment_limit?: number; + /** The ticket assignment limit value for an admin. */ + ticket_assignment_limit?: number; + /** Details about the team whose assignment limit was changed. */ + team?: ActivityLogMetadata.Team; + /** The team assignment limit value (null if limit was removed). */ + team_assignment_limit?: number; + /** Indicates if the setting is enabled or disabled. */ + enabled?: boolean; + /** The ID of the impersonation consent. */ + consent_id?: number; + /** The timestamp when the impersonation consent expires. */ + expired_at?: string; + /** The state of settings or values before the change. Structure varies by activity type. */ + before?: Record; + /** The state of settings or values after the change. Structure varies by activity type. */ + after?: Record; +} + +export namespace ActivityLogMetadata { + /** + * Details about the team whose assignment limit was changed. + */ + export interface Team { + /** The ID of the team. */ + id?: number; + /** The name of the team. */ + name?: string; + } } diff --git a/src/api/types/AddressableList.ts b/src/api/types/AddressableList.ts index 9fbf43ad..cbda5a63 100644 --- a/src/api/types/AddressableList.ts +++ b/src/api/types/AddressableList.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A list used to access other resources from a parent model. */ export interface AddressableList { /** The addressable object type */ - type: string; + type?: string; /** The id of the addressable object */ - id: string; + id?: string; /** Url to get more company resources for this contact */ - url: string; + url?: string; } diff --git a/src/api/types/AdminList.ts b/src/api/types/AdminList.ts index 6c802a88..c504537d 100644 --- a/src/api/types/AdminList.ts +++ b/src/api/types/AdminList.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A list of admins associated with a given workspace. */ export interface AdminList { /** String representing the object's type. Always has the value `admin.list`. */ - type: "admin.list"; + type?: string; /** A list of admins associated with a given workspace. */ - admins: Intercom.Admin[]; + admins?: (Intercom.Admin | undefined)[]; } diff --git a/src/api/types/AdminPriorityLevel.ts b/src/api/types/AdminPriorityLevel.ts index 659f95f2..1127dadf 100644 --- a/src/api/types/AdminPriorityLevel.ts +++ b/src/api/types/AdminPriorityLevel.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Admin priority levels for the team diff --git a/src/api/types/AdminReplyConversationRequest.ts b/src/api/types/AdminReplyConversationRequest.ts index be2e3a21..36982c2d 100644 --- a/src/api/types/AdminReplyConversationRequest.ts +++ b/src/api/types/AdminReplyConversationRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Payload of the request to reply on behalf of an admin @@ -16,6 +14,8 @@ export interface AdminReplyConversationRequest { admin_id: string; /** The time the reply was created. If not provided, the current time will be used. */ created_at?: number; + /** The quick reply options to display to the end user. Must be present for quick_reply message types. */ + reply_options?: Intercom.QuickReplyOption[]; /** A list of image URLs that will be added as attachments. You can include up to 10 URLs. */ attachment_urls?: string[]; /** A list of files that will be added as attachments. You can include up to 10 files */ @@ -23,9 +23,10 @@ export interface AdminReplyConversationRequest { } export namespace AdminReplyConversationRequest { - export type MessageType = "comment" | "note"; export const MessageType = { Comment: "comment", Note: "note", + QuickReply: "quick_reply", } as const; + export type MessageType = (typeof MessageType)[keyof typeof MessageType]; } diff --git a/src/api/types/AdminReplyTicketRequest.ts b/src/api/types/AdminReplyTicketRequest.ts index dfc2ae57..3e2ac1ed 100644 --- a/src/api/types/AdminReplyTicketRequest.ts +++ b/src/api/types/AdminReplyTicketRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Payload of the request to reply on behalf of an admin @@ -21,12 +19,12 @@ export interface AdminReplyTicketRequest { } export namespace AdminReplyTicketRequest { - export type MessageType = "comment" | "note" | "quick_reply"; export const MessageType = { Comment: "comment", Note: "note", QuickReply: "quick_reply", } as const; + export type MessageType = (typeof MessageType)[keyof typeof MessageType]; export type ReplyOptions = ReplyOptions.Item[]; export namespace ReplyOptions { diff --git a/src/api/types/AdminWithApp.ts b/src/api/types/AdminWithApp.ts index 5f262869..8675a421 100644 --- a/src/api/types/AdminWithApp.ts +++ b/src/api/types/AdminWithApp.ts @@ -1,31 +1,29 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Admins are the teammate accounts that have access to a workspace */ export interface AdminWithApp { /** String representing the object's type. Always has the value `admin`. */ - type: "admin"; + type?: string; /** The id representing the admin. */ - id: string; + id?: string; /** The name of the admin. */ - name: string; + name?: string; /** The email of the admin. */ - email: string; + email?: string; /** The job title of the admin. */ - job_title: string; + job_title?: string; /** Identifies if this admin is currently set in away mode. */ - away_mode_enabled: boolean; + away_mode_enabled?: boolean; /** Identifies if this admin is set to automatically reassign new conversations to the apps default inbox. */ - away_mode_reassign: boolean; + away_mode_reassign?: boolean; /** Identifies if this admin has a paid inbox seat to restrict/allow features that require them. */ - has_inbox_seat: boolean; + has_inbox_seat?: boolean; /** This is a list of ids of the teams that this admin is part of. */ - team_ids: number[]; + team_ids?: number[]; /** This object represents the avatar associated with the admin. */ avatar?: AdminWithApp.Avatar; /** Identifies if this admin's email is verified. */ @@ -40,7 +38,7 @@ export namespace AdminWithApp { */ export interface Avatar { /** This is a string that identifies the type of the object. It will always have the value `avatar`. */ - type?: "avatar"; + type?: string; /** This object represents the avatar associated with the admin. */ image_url?: string; } diff --git a/src/api/types/App.ts b/src/api/types/App.ts index 6506491c..67ce2d3c 100644 --- a/src/api/types/App.ts +++ b/src/api/types/App.ts @@ -1,23 +1,21 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * App is a workspace on Intercom */ export interface App { /** */ - type: string; + type?: string; /** The id of the app. */ - id_code: string; + id_code?: string; /** The name of the app. */ - name: string; + name?: string; /** The Intercom region the app is located in. */ - region: string; + region?: string; /** The timezone of the region where the app is located. */ - timezone: string; + timezone?: string; /** When the app was created. */ - created_at: number; + created_at?: number; /** Whether or not the app uses identity verification. */ - identity_verification: boolean; + identity_verification?: boolean; } diff --git a/src/api/types/ArticleContent.ts b/src/api/types/ArticleContent.ts index dd73e27e..bccb5af5 100644 --- a/src/api/types/ArticleContent.ts +++ b/src/api/types/ArticleContent.ts @@ -1,23 +1,21 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The Content of an Article. */ export interface ArticleContent { /** The type of object - `article_content` . */ - type: "article_content"; + type?: "article_content"; /** The title of the article. */ - title: string; + title?: string; /** The description of the article. */ - description: string; + description?: string; /** The body of the article. */ - body: string; + body?: string; /** The ID of the author of the article. */ - author_id: number; + author_id?: number; /** Whether the article is `published` or is a `draft` . */ - state: ArticleContent.State; + state?: ArticleContent.State; /** The time when the article was created (seconds). */ created_at?: number; /** The time when the article was last updated (seconds). */ @@ -27,12 +25,10 @@ export interface ArticleContent { } export namespace ArticleContent { - /** - * Whether the article is `published` or is a `draft` . - */ - export type State = "published" | "draft"; + /** Whether the article is `published` or is a `draft` . */ export const State = { Published: "published", Draft: "draft", } as const; + export type State = (typeof State)[keyof typeof State]; } diff --git a/src/api/types/ArticleList.ts b/src/api/types/ArticleList.ts index faf9ef31..02eb730b 100644 --- a/src/api/types/ArticleList.ts +++ b/src/api/types/ArticleList.ts @@ -1,18 +1,16 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * This will return a list of articles for the App. */ export interface ArticleList { /** The type of the object - `list`. */ - type: "list"; + type?: "list"; pages?: unknown; /** A count of the total number of articles. */ - total_count: number; + total_count?: number; /** An array of Article objects */ - data: Intercom.ArticleListItem[]; + data?: Intercom.ArticleListItem[]; } diff --git a/src/api/types/ArticleStatistics.ts b/src/api/types/ArticleStatistics.ts index 00301798..36ea843e 100644 --- a/src/api/types/ArticleStatistics.ts +++ b/src/api/types/ArticleStatistics.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The statistics of an article. @@ -11,7 +9,7 @@ export interface ArticleStatistics { /** The number of total views the article has received. */ views: number; /** The number of conversations started from the article. */ - conversions: number; + conversions?: number; /** The number of total reactions the article has received. */ reactions: number; /** The percentage of happy reactions the article has received against other types of reaction. */ diff --git a/src/api/types/ArticleTranslatedContent.ts b/src/api/types/ArticleTranslatedContent.ts index 48f103b3..351d8148 100644 --- a/src/api/types/ArticleTranslatedContent.ts +++ b/src/api/types/ArticleTranslatedContent.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * The Translated Content of an Article. The keys are the locale codes and the values are the translated content of the article. diff --git a/src/api/types/AssignConversationRequest.ts b/src/api/types/AssignConversationRequest.ts index e3eef208..0e2e8ba8 100644 --- a/src/api/types/AssignConversationRequest.ts +++ b/src/api/types/AssignConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Payload of the request to assign a conversation @@ -16,9 +14,9 @@ export interface AssignConversationRequest { } export namespace AssignConversationRequest { - export type Type = "admin" | "team"; export const Type = { Admin: "admin", Team: "team", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } diff --git a/src/api/types/AwayStatusReason.ts b/src/api/types/AwayStatusReason.ts new file mode 100644 index 00000000..01eaf720 --- /dev/null +++ b/src/api/types/AwayStatusReason.ts @@ -0,0 +1,19 @@ +// This file was auto-generated by Fern from our API Definition. + +export interface AwayStatusReason { + type?: string; + /** The unique identifier for the away status reason */ + id?: string; + /** The display text for the away status reason */ + label?: string; + /** The emoji associated with the status reason */ + emoji?: string; + /** The display order of the status reason */ + order?: number; + /** Whether the status reason has been soft deleted */ + deleted?: boolean; + /** The Unix timestamp when the status reason was created */ + created_at?: number; + /** The Unix timestamp when the status reason was last updated */ + updated_at?: number; +} diff --git a/src/api/types/ButtonComponent.ts b/src/api/types/ButtonComponent.ts deleted file mode 100644 index fa419ed8..00000000 --- a/src/api/types/ButtonComponent.ts +++ /dev/null @@ -1,36 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * A button component is used to take an action by clicking a button. This can either: - * - [Trigger a submit request to be sent](https://developers.intercom.com/docs/references/canvas-kit/actioncomponents/submit-action) Inbox Messenger - * - [Open a link in a new page](https://developers.intercom.com/docs/references/canvas-kit/actioncomponents/url-action) Inbox Messenger - * - [Open a sheet](https://developers.intercom.com/docs/references/canvas-kit/actioncomponents/sheets-action) Messenger - */ -export interface ButtonComponent { - /** A unique identifier for the component. */ - id: string; - /** The text that will be rendered inside the button. */ - label: string; - /** This can be a Submit Action, URL Action, or Sheets Action. */ - action: Intercom.ActionComponent; - /** Styles the button. Default is 'primary'. */ - style?: ButtonComponent.Style; - /** Styles the button and prevents the action. Default is false. */ - disabled?: boolean; -} - -export namespace ButtonComponent { - /** - * Styles the button. Default is 'primary'. - */ - export type Style = "primary" | "secondary" | "link"; - export const Style = { - Primary: "primary", - Secondary: "secondary", - Link: "link", - } as const; -} diff --git a/src/api/types/CallList.ts b/src/api/types/CallList.ts new file mode 100644 index 00000000..ab4b49a4 --- /dev/null +++ b/src/api/types/CallList.ts @@ -0,0 +1,16 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; + +/** + * A paginated list of calls. + */ +export interface CallList { + /** String representing the object's type. Always has the value `list`. */ + type?: string; + /** A list of calls. */ + data?: Intercom.Call[]; + /** Total number of items available. */ + total_count?: number; + pages?: Intercom.CursorPages; +} diff --git a/src/api/types/CanvasObject.ts b/src/api/types/CanvasObject.ts deleted file mode 100644 index bb6161d3..00000000 --- a/src/api/types/CanvasObject.ts +++ /dev/null @@ -1,22 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * You have to respond to the majority of requests with a canvas object. This will tell us what UI to show for your app. - * - * A canvas can either be static (meaning we send you the next request only when an action takes place) or live (meaning we send you the next request when someone views the app). - * - * - A static canvas needs a ContentObject which will contain the components to show. - * - A live canvas needs a `content_url` which we we will make the Live Canvas requests to when the app is viewed. This is only possible for apps viewed or used in the Messenger. - */ -export interface CanvasObject { - /** The content object that will be shown as the UI of the app. Max Size is 64KB. */ - content: Intercom.ContentObject; - /** The URL which we make Live Canvas requests to. You must respond to these with a content object. Max size is 64KB. */ - content_url?: string; - /** Optional Stored Data that you want to be returned in the next sent request. Max Size is 64KB. */ - stored_data?: Record; -} diff --git a/src/api/types/CheckboxComponent.ts b/src/api/types/CheckboxComponent.ts deleted file mode 100644 index ddd79298..00000000 --- a/src/api/types/CheckboxComponent.ts +++ /dev/null @@ -1,39 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * A checkbox component is used to capture multiple choices from as many options as you want to provide. You can submit the options by: - * - * - Using a ButtonComponent (which will submit all interactive components in the canvas) - * - * When a submit action takes place, the results are given in a hash with the `id` from the checkbox component used as the key and an array containing the `id` of each chosen option as the value. - */ -export interface CheckboxComponent { - /** A unique identifier for the component. */ - id: string; - /** The list of options. Minimum of 1. */ - option: Intercom.CheckboxOption[]; - /** The text shown above the options. */ - label: string; - /** The option's that are selected by default. */ - value?: string[]; - /** Styles the input. Default is `unsaved`. Prevent action with `saved`. */ - save_state?: CheckboxComponent.SaveState; - /** Styles all options and prevents the action. Default is false. Will be overridden if save_state is saved. */ - disabled?: boolean; -} - -export namespace CheckboxComponent { - /** - * Styles the input. Default is `unsaved`. Prevent action with `saved`. - */ - export type SaveState = "unsaved" | "saved" | "failed"; - export const SaveState = { - Unsaved: "unsaved", - Saved: "saved", - Failed: "failed", - } as const; -} diff --git a/src/api/types/CheckboxOption.ts b/src/api/types/CheckboxOption.ts deleted file mode 100644 index d33bb8fe..00000000 --- a/src/api/types/CheckboxOption.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A checkbox option component that can be selected. - */ -export interface CheckboxOption { - /** The type of component you are rendering. */ - type: "option"; - /** A unique identifier for the option. */ - id: string; - /** The text shown next to the checkbox. */ - text: string; - /** Styles the option and prevents the action. Default is false. */ - disabled?: boolean; -} diff --git a/src/api/types/CloseConversationRequest.ts b/src/api/types/CloseConversationRequest.ts index 56f0755e..0c75f0c3 100644 --- a/src/api/types/CloseConversationRequest.ts +++ b/src/api/types/CloseConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Payload of the request to close a conversation diff --git a/src/api/types/CollectionList.ts b/src/api/types/CollectionList.ts index 3260e2c6..d2c02975 100644 --- a/src/api/types/CollectionList.ts +++ b/src/api/types/CollectionList.ts @@ -1,18 +1,16 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * This will return a list of Collections for the App. */ export interface CollectionList { /** The type of the object - `list`. */ - type: "list"; + type?: "list"; pages?: Intercom.OffsetPages; /** A count of the total number of collections. */ - total_count: number; + total_count?: number; /** An array of collection objects */ - data: Intercom.Collection[]; + data?: Intercom.Collection[]; } diff --git a/src/api/types/CompanyAttachedContacts.ts b/src/api/types/CompanyAttachedContacts.ts index a07697e9..8725ffd9 100644 --- a/src/api/types/CompanyAttachedContacts.ts +++ b/src/api/types/CompanyAttachedContacts.ts @@ -1,18 +1,16 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A list of Contact Objects */ export interface CompanyAttachedContacts { /** The type of object - `list` */ - type: "list"; + type?: "list"; /** An array containing Contact Objects */ - data: Intercom.Contact[]; + data?: Intercom.Contact[]; /** The total number of contacts */ - total_count: number; + total_count?: number; pages?: Intercom.CursorPages; } diff --git a/src/api/types/CompanyAttachedSegments.ts b/src/api/types/CompanyAttachedSegments.ts index 12c36438..aa6941ca 100644 --- a/src/api/types/CompanyAttachedSegments.ts +++ b/src/api/types/CompanyAttachedSegments.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A list of Segment Objects */ export interface CompanyAttachedSegments { /** The type of object - `list` */ - type: "list"; + type?: "list"; /** An array containing Segment Objects */ - data: Intercom.Segment[]; + data?: Intercom.Segment[]; } diff --git a/src/api/types/CompanyData.ts b/src/api/types/CompanyData.ts new file mode 100644 index 00000000..29d3a559 --- /dev/null +++ b/src/api/types/CompanyData.ts @@ -0,0 +1,13 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * An object containing data about the companies that a contact is associated with. + */ +export interface CompanyData { + /** The unique identifier for the company which is given by Intercom. */ + id?: string; + /** The type of the object. Always company. */ + type?: "company"; + /** The relative URL of the company. */ + url?: string; +} diff --git a/src/api/types/CompanyList.ts b/src/api/types/CompanyList.ts index 8d4eb5de..34851ae1 100644 --- a/src/api/types/CompanyList.ts +++ b/src/api/types/CompanyList.ts @@ -1,16 +1,16 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * This will return a list of companies for the App. */ export interface CompanyList { + /** The type of object - `list`. */ + type?: "list"; pages?: Intercom.OffsetPages; /** The total number of companies. */ - total_count: number; + total_count?: number; /** An array containing Company Objects. */ - data: Intercom.Company[]; + data?: Intercom.Company[]; } diff --git a/src/api/types/CompanyScroll.ts b/src/api/types/CompanyScroll.ts index dd606955..1ba47ea4 100644 --- a/src/api/types/CompanyScroll.ts +++ b/src/api/types/CompanyScroll.ts @@ -1,16 +1,14 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Companies allow you to represent organizations using your product. Each company will have its own description and be associated with contacts. You can fetch, create, update and list companies. */ export interface CompanyScroll { /** The type of object - `list` */ - type: "list"; - data: Intercom.Company[]; + type?: "list"; + data?: Intercom.Company[]; pages?: Intercom.CursorPages; /** The total number of companies */ total_count?: number; diff --git a/src/api/types/Component.ts b/src/api/types/Component.ts deleted file mode 100644 index d2de298c..00000000 --- a/src/api/types/Component.ts +++ /dev/null @@ -1,69 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -export type Component = - | Intercom.Component.Button - | Intercom.Component.Checkbox - | Intercom.Component.Dropdown - | Intercom.Component.Input - | Intercom.Component.List - | Intercom.Component.SingleSelect - | Intercom.Component.Textarea - | Intercom.Component.DataTable - | Intercom.Component.Divider - | Intercom.Component.Image - | Intercom.Component.Spacer - | Intercom.Component.Text; - -export namespace Component { - export interface Button extends Intercom.ButtonComponent { - type: "button"; - } - - export interface Checkbox extends Intercom.CheckboxComponent { - type: "checkbox"; - } - - export interface Dropdown extends Intercom.DropdownComponent { - type: "dropdown"; - } - - export interface Input extends Intercom.InputComponent { - type: "input"; - } - - export interface List extends Intercom.ListComponent { - type: "list"; - } - - export interface SingleSelect extends Intercom.SingleSelectComponent { - type: "single-select"; - } - - export interface Textarea extends Intercom.TextAreaComponent { - type: "textarea"; - } - - export interface DataTable extends Intercom.DataTableComponent { - type: "data-table"; - } - - export interface Divider extends Intercom.DividerComponent { - type: "divider"; - } - - export interface Image extends Intercom.ImageComponent { - type: "image"; - } - - export interface Spacer extends Intercom.SpacerComponent { - type: "spacer"; - } - - export interface Text extends Intercom.TextComponent { - type: "text"; - } -} diff --git a/src/api/types/ConfigureRequest.ts b/src/api/types/ConfigureRequest.ts deleted file mode 100644 index b565bb2b..00000000 --- a/src/api/types/ConfigureRequest.ts +++ /dev/null @@ -1,26 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * The first request we send will allow you to know the workspace where this is happening, the admin who will be configuring the app, and additional context such as where this will be added once complete. - * - * For subsequent requests whereby an admin has interacted with a component with a submit action, the request payload will contain the same details with `current_canvas`, `input_values` and the `component_id` also present. This allows you to understand what component the request came from, see what the value of any input was, action anything in your codebase, and then respond knowing what canvas was previously shown beforehand. - */ -export type ConfigureRequest = - | { - workspace_id: string; - admin: Intercom.Admin; - context: Intercom.Context; - } - | { - workspace_id: string; - workspace_region: string; - component_id: string; - admin: Intercom.Admin; - context: Intercom.Context; - current_canvas: Intercom.CanvasObject; - input_values: Record; - }; diff --git a/src/api/types/ConfigureResponse.ts b/src/api/types/ConfigureResponse.ts deleted file mode 100644 index 08ad2508..00000000 --- a/src/api/types/ConfigureResponse.ts +++ /dev/null @@ -1,16 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * The response object returned when configuring an app. This will either: - * - A canvas object which will replace the previous canvas that was visible until the teammate interacted with your app - * - A results object which will end the configuration and trigger the initialize request to be sent. There will be a card_creation_options object in the payload showing your key-value pairs from the results object. - */ -export type ConfigureResponse = - | Intercom.ResultsResponse - | { - canvas: Intercom.CanvasObject; - }; diff --git a/src/api/types/ContactArchived.ts b/src/api/types/ContactArchived.ts index 882c4bec..53e83824 100644 --- a/src/api/types/ContactArchived.ts +++ b/src/api/types/ContactArchived.ts @@ -1,17 +1,11 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; /** * archived contact object */ -export interface ContactArchived { - /** always contact */ - type: "contact"; - /** The unique identifier for the contact which is given by Intercom. */ - id: string; - /** The unique identifier for the contact which is provided by the Client. */ - external_id?: string; +export interface ContactArchived extends Intercom.ContactReference { /** Whether the contact is archived or not. */ - archived: boolean; + archived?: boolean; } diff --git a/src/api/types/ContactAttachedCompanies.ts b/src/api/types/ContactAttachedCompanies.ts index 3c73d361..6606054e 100644 --- a/src/api/types/ContactAttachedCompanies.ts +++ b/src/api/types/ContactAttachedCompanies.ts @@ -1,18 +1,16 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A list of Company Objects */ export interface ContactAttachedCompanies { /** The type of object */ - type: "list"; + type?: "list"; /** An array containing Company Objects */ - companies: Intercom.Company[]; + companies?: Intercom.Company[]; /** The total number of companies associated to this contact */ - total_count: number; + total_count?: number; pages?: Intercom.PagesLink; } diff --git a/src/api/types/ContactBlocked.ts b/src/api/types/ContactBlocked.ts new file mode 100644 index 00000000..9c85baa7 --- /dev/null +++ b/src/api/types/ContactBlocked.ts @@ -0,0 +1,11 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; + +/** + * blocked contact object + */ +export interface ContactBlocked extends Intercom.ContactReference { + /** Always true. */ + blocked?: boolean; +} diff --git a/src/api/types/ContactCompanies.ts b/src/api/types/ContactCompanies.ts index 88980a31..8a3a13b0 100644 --- a/src/api/types/ContactCompanies.ts +++ b/src/api/types/ContactCompanies.ts @@ -1,21 +1,17 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** - * An object containing companies meta data about the companies that a contact has. Up to 10 will be displayed here. Use the url to get more. + * An object with metadata about companies attached to a contact . Up to 10 will be displayed here. Use the url to get more. */ export interface ContactCompanies { - /** The type of object */ - type?: "list"; - /** An array containing Company Objects */ - data?: Intercom.ContactCompany[]; + /** An array of company data objects attached to the contact. */ + data?: Intercom.CompanyData[]; /** Url to get more company resources for this contact */ - url: string; - /** Int representing the total number of companyies attached to this contact */ - total_count: number; + url?: string; + /** Integer representing the total number of companies attached to this contact */ + total_count?: number; /** Whether there's more Addressable Objects to be viewed. If true, use the url to view all */ - has_more: boolean; + has_more?: boolean; } diff --git a/src/api/types/ContactCompany.ts b/src/api/types/ContactCompany.ts deleted file mode 100644 index cfe15a56..00000000 --- a/src/api/types/ContactCompany.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A reference to a company associated with a contact - */ -export interface ContactCompany { - /** The unique identifier for the company */ - id: string; - /** The type of the object */ - type: "company"; - /** URL to get the full company resource */ - url: string; -} diff --git a/src/api/types/ContactDeleted.ts b/src/api/types/ContactDeleted.ts index 12d7b0c6..6b047f65 100644 --- a/src/api/types/ContactDeleted.ts +++ b/src/api/types/ContactDeleted.ts @@ -1,17 +1,11 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; /** * deleted contact object */ -export interface ContactDeleted { - /** always contact */ - type: "contact"; - /** The unique identifier for the contact which is given by Intercom. */ - id: string; - /** The unique identifier for the contact which is provided by the Client. */ - external_id?: string; +export interface ContactDeleted extends Intercom.ContactReference { /** Whether the contact is deleted or not. */ - deleted: boolean; + deleted?: boolean; } diff --git a/src/api/types/ContactList.ts b/src/api/types/ContactList.ts index fd188c1a..2fc8ab69 100644 --- a/src/api/types/ContactList.ts +++ b/src/api/types/ContactList.ts @@ -1,18 +1,16 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Contacts are your users in Intercom. */ export interface ContactList { /** Always list */ - type: "list"; + type?: "list"; /** The list of contact objects */ - data: Intercom.Contact[]; + data?: Intercom.Contact[]; /** A count of the total number of objects. */ - total_count: number; + total_count?: number; pages?: Intercom.CursorPages; } diff --git a/src/api/types/ContactLocation.ts b/src/api/types/ContactLocation.ts index 2e079a7c..73f32530 100644 --- a/src/api/types/ContactLocation.ts +++ b/src/api/types/ContactLocation.ts @@ -1,13 +1,11 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * An object containing location meta data about a Intercom contact. */ export interface ContactLocation { /** Always location */ - type: "location"; + type?: string; /** The country that the contact is located in */ country?: string; /** The overal region that the contact is located in */ diff --git a/src/api/types/ContactNotes.ts b/src/api/types/ContactNotes.ts index 56f4b090..77a34b6f 100644 --- a/src/api/types/ContactNotes.ts +++ b/src/api/types/ContactNotes.ts @@ -1,19 +1,17 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * An object containing notes meta data about the notes that a contact has. Up to 10 will be displayed here. Use the url to get more. */ export interface ContactNotes { /** This object represents the notes attached to a contact. */ - data: Intercom.AddressableList[]; + data?: Intercom.AddressableList[]; /** Url to get more company resources for this contact */ - url: string; + url?: string; /** Int representing the total number of companyies attached to this contact */ - total_count: number; + total_count?: number; /** Whether there's more Addressable Objects to be viewed. If true, use the url to view all */ - has_more: boolean; + has_more?: boolean; } diff --git a/src/api/types/ContactReference.ts b/src/api/types/ContactReference.ts index 06dcf74e..6ff6080e 100644 --- a/src/api/types/ContactReference.ts +++ b/src/api/types/ContactReference.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * reference to contact object */ export interface ContactReference { /** always contact */ - type: "contact"; + type?: "contact"; /** The unique identifier for the contact which is given by Intercom. */ - id: string; + id?: string; /** The unique identifier for the contact which is provided by the Client. */ external_id?: string; } diff --git a/src/api/types/ContactReplyBaseRequest.ts b/src/api/types/ContactReplyBaseRequest.ts index 74f679c9..e6ebd102 100644 --- a/src/api/types/ContactReplyBaseRequest.ts +++ b/src/api/types/ContactReplyBaseRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export interface ContactReplyBaseRequest { message_type: "comment"; @@ -11,4 +9,19 @@ export interface ContactReplyBaseRequest { created_at?: number; /** A list of image URLs that will be added as attachments. You can include up to 10 URLs. */ attachment_urls?: string[]; + /** The quick reply selection the contact wishes to respond with. These map to buttons displayed in the Messenger UI if sent by a bot, or the reply options sent by an Admin via the API. */ + reply_options?: ContactReplyBaseRequest.ReplyOptions.Item[]; +} + +export namespace ContactReplyBaseRequest { + export type ReplyOptions = ReplyOptions.Item[]; + + export namespace ReplyOptions { + export interface Item { + /** The text of the chosen reply option. */ + text: string; + /** The unique identifier for the quick reply option selected. */ + uuid: string; + } + } } diff --git a/src/api/types/ContactReplyConversationRequest.ts b/src/api/types/ContactReplyConversationRequest.ts index 90c1aa5b..c0f18e11 100644 --- a/src/api/types/ContactReplyConversationRequest.ts +++ b/src/api/types/ContactReplyConversationRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; export type ContactReplyConversationRequest = | Intercom.ContactReplyIntercomUserIdRequest diff --git a/src/api/types/ContactReplyEmailRequest.ts b/src/api/types/ContactReplyEmailRequest.ts index 3f6b266b..3af33d96 100644 --- a/src/api/types/ContactReplyEmailRequest.ts +++ b/src/api/types/ContactReplyEmailRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Payload of the request to reply on behalf of a contact using their `email` diff --git a/src/api/types/ContactReplyIntercomUserIdRequest.ts b/src/api/types/ContactReplyIntercomUserIdRequest.ts index 7de99551..4a3b3f1b 100644 --- a/src/api/types/ContactReplyIntercomUserIdRequest.ts +++ b/src/api/types/ContactReplyIntercomUserIdRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Payload of the request to reply on behalf of a contact using their `intercom_user_id` diff --git a/src/api/types/ContactReplyTicketEmailRequest.ts b/src/api/types/ContactReplyTicketEmailRequest.ts index f1c5da4d..8baf8758 100644 --- a/src/api/types/ContactReplyTicketEmailRequest.ts +++ b/src/api/types/ContactReplyTicketEmailRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Payload of the request to reply on behalf of a contact using their `email` diff --git a/src/api/types/ContactReplyTicketIntercomUserIdRequest.ts b/src/api/types/ContactReplyTicketIntercomUserIdRequest.ts index fb39fc05..712a6dfc 100644 --- a/src/api/types/ContactReplyTicketIntercomUserIdRequest.ts +++ b/src/api/types/ContactReplyTicketIntercomUserIdRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Payload of the request to reply on behalf of a contact using their `intercom_user_id` diff --git a/src/api/types/ContactReplyTicketRequest.ts b/src/api/types/ContactReplyTicketRequest.ts index a285ecec..a8deae5d 100644 --- a/src/api/types/ContactReplyTicketRequest.ts +++ b/src/api/types/ContactReplyTicketRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; export type ContactReplyTicketRequest = | Intercom.ContactReplyTicketIntercomUserIdRequest diff --git a/src/api/types/ContactReplyTicketUserIdRequest.ts b/src/api/types/ContactReplyTicketUserIdRequest.ts index 475a259d..d754bd17 100644 --- a/src/api/types/ContactReplyTicketUserIdRequest.ts +++ b/src/api/types/ContactReplyTicketUserIdRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Payload of the request to reply on behalf of a contact using their `user_id` diff --git a/src/api/types/ContactReplyUserIdRequest.ts b/src/api/types/ContactReplyUserIdRequest.ts index 919a6e28..c043f3cc 100644 --- a/src/api/types/ContactReplyUserIdRequest.ts +++ b/src/api/types/ContactReplyUserIdRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Payload of the request to reply on behalf of a contact using their `user_id` diff --git a/src/api/types/ContactSegments.ts b/src/api/types/ContactSegments.ts index cb9bc850..5099c19d 100644 --- a/src/api/types/ContactSegments.ts +++ b/src/api/types/ContactSegments.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A list of segments objects attached to a specific contact. */ export interface ContactSegments { /** The type of the object */ - type: "list"; + type?: "list"; /** Segment objects associated with the contact. */ - data: Intercom.Segment[]; + data?: Intercom.Segment[]; } diff --git a/src/api/types/ContactSocialProfiles.ts b/src/api/types/ContactSocialProfiles.ts index baf40a04..c61e7c62 100644 --- a/src/api/types/ContactSocialProfiles.ts +++ b/src/api/types/ContactSocialProfiles.ts @@ -1,13 +1,11 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * An object containing social profiles that a contact has. */ export interface ContactSocialProfiles { /** A list of social profiles objects associated with the contact. */ - data: Intercom.SocialProfile[]; + data?: Intercom.SocialProfile[]; } diff --git a/src/api/types/ContactSubscriptionTypes.ts b/src/api/types/ContactSubscriptionTypes.ts index ff8cd650..358f4604 100644 --- a/src/api/types/ContactSubscriptionTypes.ts +++ b/src/api/types/ContactSubscriptionTypes.ts @@ -1,19 +1,17 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * An object containing Subscription Types meta data about the SubscriptionTypes that a contact has. */ export interface ContactSubscriptionTypes { /** This object represents the subscriptions attached to a contact. */ - data: Intercom.AddressableList[]; + data?: Intercom.AddressableList[]; /** Url to get more subscription type resources for this contact */ - url: string; + url?: string; /** Int representing the total number of subscription types attached to this contact */ - total_count: number; + total_count?: number; /** Whether there's more Addressable Objects to be viewed. If true, use the url to view all */ - has_more: boolean; + has_more?: boolean; } diff --git a/src/api/types/ContactTags.ts b/src/api/types/ContactTags.ts index 6ed9fd6d..90b8cc0f 100644 --- a/src/api/types/ContactTags.ts +++ b/src/api/types/ContactTags.ts @@ -1,19 +1,17 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * An object containing tags meta data about the tags that a contact has. Up to 10 will be displayed here. Use the url to get more. */ export interface ContactTags { /** This object represents the tags attached to a contact. */ - data: Intercom.AddressableList[]; + data?: Intercom.AddressableList[]; /** url to get more tag resources for this contact */ - url: string; + url?: string; /** Int representing the total number of tags attached to this contact */ - total_count: number; + total_count?: number; /** Whether there's more Addressable Objects to be viewed. If true, use the url to view all */ - has_more: boolean; + has_more?: boolean; } diff --git a/src/api/types/ContactUnarchived.ts b/src/api/types/ContactUnarchived.ts index 7940f0f1..5c84ff30 100644 --- a/src/api/types/ContactUnarchived.ts +++ b/src/api/types/ContactUnarchived.ts @@ -1,17 +1,11 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; /** * unarchived contact object */ -export interface ContactUnarchived { - /** always contact */ - type: "contact"; - /** The unique identifier for the contact which is given by Intercom. */ - id: string; - /** The unique identifier for the contact which is provided by the Client. */ - external_id?: string; +export interface ContactUnarchived extends Intercom.ContactReference { /** Whether the contact is archived or not. */ - archived: boolean; + archived?: boolean; } diff --git a/src/api/types/ContentObject.ts b/src/api/types/ContentObject.ts deleted file mode 100644 index 127b8d88..00000000 --- a/src/api/types/ContentObject.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * The content object is where you specify the UI of your app. You provide us with a set of `components` in a components array that we then render. - * - * The content object should usually be returned within the [canvas object](https://developers.intercom.com/docs/references/canvas-kit/responseobjects/canvas). If you're responding to a Live Canvas request however, then you should only respond with the content object. - */ -export interface ContentObject { - /** The list of components to be rendered. */ - components: Intercom.Component[]; -} diff --git a/src/api/types/ContentSourcesList.ts b/src/api/types/ContentSourcesList.ts index 28044b85..4af840d0 100644 --- a/src/api/types/ContentSourcesList.ts +++ b/src/api/types/ContentSourcesList.ts @@ -1,13 +1,11 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; export interface ContentSourcesList { - type: "content_source.list"; + type?: "content_source.list"; /** The total number of content sources used by AI Agent in the conversation. */ - total_count: number; + total_count?: number; /** The content sources used by AI Agent in the conversation. */ - content_sources: Intercom.ContentSource[]; + content_sources?: Intercom.ContentSource[]; } diff --git a/src/api/types/Context.ts b/src/api/types/Context.ts deleted file mode 100644 index c86d4597..00000000 --- a/src/api/types/Context.ts +++ /dev/null @@ -1,36 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * The context object provides additional details on where the app has been added (or is currently being used), what page the app is being used on, and information on the Messenger settings. This is in order for you give a fully customised experience based on the customers use case. - * - * If the `location` is `conversation` then you will also be given a `conversation_id`. If you need to use details about the conversation, then you have to use the `conversation_id` to [make a call to our Conversations API and retrieve the conversation object](https://developers.intercom.com/intercom-api-reference/reference#get-a-single-conversation). - */ -export interface Context { - /** The id of the conversation where the app is added or being used. */ - conversation_id?: number; - /** Where the app is added or the action took place. Can be either 'conversation', 'home', 'message', or 'operator'. */ - location?: Context.Location; - /** The default end-user language of the Messenger. Use to localise Messenger App content. */ - locale?: string; - /** The messengers action colour. Use in Sheets and Icons to make a Messenger App experience feel part of the host Messenger. */ - messenger_action_colour?: string; - /** The messengers background colour. Use in Sheets and Icons to make a Messenger App experience feel part of the host Messenger. */ - messenger_background_colour?: string; - /** The current page URL where the app is being used. */ - referrer?: string; -} - -export namespace Context { - /** - * Where the app is added or the action took place. Can be either 'conversation', 'home', 'message', or 'operator'. - */ - export type Location = "conversation" | "home" | "message" | "operator"; - export const Location = { - Conversation: "conversation", - Home: "home", - Message: "message", - Operator: "operator", - } as const; -} diff --git a/src/api/types/ConversationAttachmentFiles.ts b/src/api/types/ConversationAttachmentFiles.ts index df8323f1..f1a0b3e5 100644 --- a/src/api/types/ConversationAttachmentFiles.ts +++ b/src/api/types/ConversationAttachmentFiles.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Properties of the attachment files in a conversation part */ export interface ConversationAttachmentFiles { /** The content type of the file */ - content_type: string; + content_type?: string; /** The base64 encoded file data. */ - data: string; + data?: string; /** The name of the file. */ - name: string; + name?: string; } diff --git a/src/api/types/ConversationAttributeUpdatedByAdmin.ts b/src/api/types/ConversationAttributeUpdatedByAdmin.ts new file mode 100644 index 00000000..b44c2202 --- /dev/null +++ b/src/api/types/ConversationAttributeUpdatedByAdmin.ts @@ -0,0 +1,21 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains details about Custom Data Attributes (CDAs) that were modified by an admin (operator) for conversation part type conversation_attribute_updated_by_admin. + */ +export interface ConversationAttributeUpdatedByAdmin { + attribute?: ConversationAttributeUpdatedByAdmin.Attribute; + value?: ConversationAttributeUpdatedByAdmin.Value; +} + +export namespace ConversationAttributeUpdatedByAdmin { + export interface Attribute { + /** Name of the CDA updated */ + name?: string; + } + + export interface Value { + /** Value of the CDA updated */ + name?: string; + } +} diff --git a/src/api/types/ConversationAttributeUpdatedByWorkflow.ts b/src/api/types/ConversationAttributeUpdatedByWorkflow.ts new file mode 100644 index 00000000..e9e75f32 --- /dev/null +++ b/src/api/types/ConversationAttributeUpdatedByWorkflow.ts @@ -0,0 +1,27 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains details about the workflow that was triggered and any Custom Data Attributes (CDAs) that were modified during the workflow execution for conversation part type conversation_attribute_updated_by_workflow. + */ +export interface ConversationAttributeUpdatedByWorkflow { + workflow?: ConversationAttributeUpdatedByWorkflow.Workflow; + attribute?: ConversationAttributeUpdatedByWorkflow.Attribute; + value?: ConversationAttributeUpdatedByWorkflow.Value; +} + +export namespace ConversationAttributeUpdatedByWorkflow { + export interface Workflow { + /** Name of the workflow */ + name?: string; + } + + export interface Attribute { + /** Name of the CDA updated */ + name?: string; + } + + export interface Value { + /** Value of the CDA updated */ + name?: string; + } +} diff --git a/src/api/types/ConversationContacts.ts b/src/api/types/ConversationContacts.ts index c76e082d..860cd318 100644 --- a/src/api/types/ConversationContacts.ts +++ b/src/api/types/ConversationContacts.ts @@ -1,14 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * The list of contacts (users or leads) involved in this conversation. This will only contain one customer unless more were added via the group conversation feature. */ export interface ConversationContacts { - type: "contact.list"; + /** */ + type?: "contact.list"; /** The list of contacts (users or leads) involved in this conversation. This will only contain one customer unless more were added via the group conversation feature. */ - contacts: Intercom.ContactReference[]; + contacts?: Intercom.ContactReference[]; } diff --git a/src/api/types/ConversationDeleted.ts b/src/api/types/ConversationDeleted.ts new file mode 100644 index 00000000..e61823b9 --- /dev/null +++ b/src/api/types/ConversationDeleted.ts @@ -0,0 +1,13 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * deleted conversation object + */ +export interface ConversationDeleted { + /** The unique identifier for the conversation. */ + id?: string; + /** always conversation */ + object?: "conversation"; + /** Whether the conversation is deleted or not. */ + deleted?: boolean; +} diff --git a/src/api/types/ConversationFirstContactReply.ts b/src/api/types/ConversationFirstContactReply.ts index efef9c6a..2085bd1e 100644 --- a/src/api/types/ConversationFirstContactReply.ts +++ b/src/api/types/ConversationFirstContactReply.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * An object containing information on the first users message. For a contact initiated message this will represent the users original message. */ export interface ConversationFirstContactReply { /** */ - created_at: number; + created_at?: number; /** */ - type: string; + type?: string; /** */ url?: string; } diff --git a/src/api/types/PaginatedConversationResponse.ts b/src/api/types/ConversationList.ts similarity index 59% rename from src/api/types/PaginatedConversationResponse.ts rename to src/api/types/ConversationList.ts index 4a319f84..4d0c74f3 100644 --- a/src/api/types/PaginatedConversationResponse.ts +++ b/src/api/types/ConversationList.ts @@ -1,18 +1,16 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Conversations are how you can communicate with users in Intercom. They are created when a contact replies to an outbound message, or when one admin directly sends a message to a single contact. */ -export interface PaginatedConversationResponse { +export interface ConversationList { /** Always conversation.list */ - type: "conversation.list"; + type?: "conversation.list"; /** The list of conversation objects */ - conversations: Intercom.Conversation[]; + conversations?: Intercom.Conversation[]; /** A count of the total number of objects. */ - total_count: number; + total_count?: number; pages?: Intercom.CursorPages; } diff --git a/src/api/types/ConversationPart.ts b/src/api/types/ConversationPart.ts index 51fcf06a..2182ec66 100644 --- a/src/api/types/ConversationPart.ts +++ b/src/api/types/ConversationPart.ts @@ -1,34 +1,51 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A Conversation Part represents a message in the conversation. */ export interface ConversationPart { /** Always conversation_part */ - type: "conversation_part"; + type?: string; /** The id representing the conversation part. */ - id: string; + id?: string; /** The type of conversation part. */ - part_type: string; + part_type?: string; /** The message body, which may contain HTML. For Twitter, this will show a generic message regarding why the body is obscured. */ body?: string; /** The time the conversation part was created. */ - created_at: number; + created_at?: number; /** The last time the conversation part was updated. */ updated_at?: number; /** The time the user was notified with the conversation part. */ - notified_at: number; + notified_at?: number; /** The id of the admin that was assigned the conversation by this conversation_part (null if there has been no change in assignment.) */ assigned_to?: Intercom.Reference; - author: Intercom.ConversationPartAuthor; + author?: Intercom.ConversationPartAuthor; /** A list of attachments for the part. */ attachments?: Intercom.PartAttachment[]; /** The external id of the conversation part */ external_id?: string; /** Whether or not the conversation part has been redacted. */ - redacted: boolean; + redacted?: boolean; + email_message_metadata?: Intercom.EmailMessageMetadata; + metadata?: Intercom.ConversationPartMetadata; + /** Indicates the current state of conversation when the conversation part was created. */ + state?: ConversationPart.State; + /** A list of tags objects associated with the conversation part. */ + tags?: Intercom.TagBasic[]; + event_details?: Intercom.EventDetails; + /** The app package code if this part was created via API. null if the part was not created via API. */ + app_package_code?: string; +} + +export namespace ConversationPart { + /** Indicates the current state of conversation when the conversation part was created. */ + export const State = { + Open: "open", + Closed: "closed", + Snoozed: "snoozed", + } as const; + export type State = (typeof State)[keyof typeof State]; } diff --git a/src/api/types/ConversationPartAuthor.ts b/src/api/types/ConversationPartAuthor.ts index 36495f34..3a17d751 100644 --- a/src/api/types/ConversationPartAuthor.ts +++ b/src/api/types/ConversationPartAuthor.ts @@ -1,17 +1,19 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The object who initiated the conversation, which can be a Contact, Admin or Team. Bots and campaigns send messages on behalf of Admins or Teams. For Twitter, this will be blank. */ export interface ConversationPartAuthor { /** The type of the author */ - type: string; + type?: string; /** The id of the author */ - id: string; + id?: string; /** The name of the author */ - name: string; + name?: string; /** The email of the author */ - email: string; + email?: string; + /** If this conversation part was sent by the AI Agent */ + from_ai_agent?: boolean; + /** If this conversation part body was generated by the AI Agent */ + is_ai_answer?: boolean; } diff --git a/src/api/types/ConversationPartMetadata.ts b/src/api/types/ConversationPartMetadata.ts new file mode 100644 index 00000000..34c17f40 --- /dev/null +++ b/src/api/types/ConversationPartMetadata.ts @@ -0,0 +1,24 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; + +/** + * Metadata for a conversation part + */ +export interface ConversationPartMetadata { + /** The quick reply options sent by the Admin or bot, presented in this conversation part. */ + quick_reply_options?: ConversationPartMetadata.QuickReplyOptions.Item[]; + /** The unique identifier for the quick reply option that was clicked by the end user. */ + quick_reply_uuid?: string; +} + +export namespace ConversationPartMetadata { + export type QuickReplyOptions = QuickReplyOptions.Item[]; + + export namespace QuickReplyOptions { + export interface Item extends Intercom.QuickReplyOption { + /** The translations for the quick reply option. */ + translations?: Record; + } + } +} diff --git a/src/api/types/ConversationParts.ts b/src/api/types/ConversationParts.ts index 2d0114df..ba6730f6 100644 --- a/src/api/types/ConversationParts.ts +++ b/src/api/types/ConversationParts.ts @@ -1,17 +1,15 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A list of Conversation Part objects for each part message in the conversation. This is only returned when Retrieving a Conversation, and ignored when Listing all Conversations. There is a limit of 500 parts. */ export interface ConversationParts { /** */ - type: "conversation_part.list"; + type?: "conversation_part.list"; /** A list of Conversation Part objects for each part message in the conversation. This is only returned when Retrieving a Conversation, and ignored when Listing all Conversations. There is a limit of 500 parts. */ - conversation_parts: Intercom.ConversationPart[]; + conversation_parts?: Intercom.ConversationPart[]; /** */ - total_count: number; + total_count?: number; } diff --git a/src/api/types/ConversationRating.ts b/src/api/types/ConversationRating.ts index 96209e62..1ba83dbb 100644 --- a/src/api/types/ConversationRating.ts +++ b/src/api/types/ConversationRating.ts @@ -1,19 +1,19 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * The Conversation Rating object which contains information on the rating and/or remark added by a Contact and the Admin assigned to the conversation. */ export interface ConversationRating { /** The rating, between 1 and 5, for the conversation. */ - rating: number; + rating?: number; /** An optional field to add a remark to correspond to the number rating */ - remark: string; + remark?: string; /** The time the rating was requested in the conversation being rated. */ - created_at: number; - contact: Intercom.ContactReference; - teammate: Intercom.Reference; + created_at?: number; + /** The time the rating was last updated. */ + updated_at?: number; + contact?: Intercom.ContactReference; + teammate?: Intercom.Reference; } diff --git a/src/api/types/ConversationResponseTime.ts b/src/api/types/ConversationResponseTime.ts new file mode 100644 index 00000000..8c503679 --- /dev/null +++ b/src/api/types/ConversationResponseTime.ts @@ -0,0 +1,13 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Details of first response time of assigned team in seconds. + */ +export interface ConversationResponseTime { + /** Id of the assigned team. */ + team_id?: number; + /** Name of the assigned Team, null if team does not exist, Unassigned if no team is assigned. */ + team_name?: string; + /** First response time of assigned team in seconds. */ + response_time?: number; +} diff --git a/src/api/types/ConversationSource.ts b/src/api/types/ConversationSource.ts index 7dcaf810..960f667c 100644 --- a/src/api/types/ConversationSource.ts +++ b/src/api/types/ConversationSource.ts @@ -1,47 +1,32 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** - * The Conversation Part that originated this conversation, which can be Contact, Admin, Campaign, Automated or Operator initiated. + * The type of the conversation part that started this conversation. Can be Contact, Admin, Campaign, Automated or Operator initiated. */ export interface ConversationSource { /** This includes conversation, email, facebook, instagram, phone_call, phone_switch, push, sms, twitter and whatsapp. */ - type: ConversationSource.Type; + type?: ConversationSource.Type; /** The id representing the message. */ - id: string; + id?: string; /** The conversation's initiation type. Possible values are customer_initiated, campaigns_initiated (legacy campaigns), operator_initiated (Custom bot), automated (Series and other outbounds with dynamic audience message) and admin_initiated (fixed audience message, ticket initiated by an admin, group email). */ - delivered_as: string; + delivered_as?: string; /** Optional. The message subject. For Twitter, this will show a generic message regarding why the subject is obscured. */ - subject: string; + subject?: string; /** The message body, which may contain HTML. For Twitter, this will show a generic message regarding why the body is obscured. */ body?: string; - author: Intercom.ConversationPartAuthor; + author?: Intercom.ConversationPartAuthor; /** A list of attachments for the part. */ attachments?: Intercom.PartAttachment[]; /** The URL where the conversation was started. For Twitter, Email, and Bots, this will be blank. */ url?: string; /** Whether or not the source message has been redacted. Only applicable for contact initiated messages. */ - redacted: boolean; + redacted?: boolean; } export namespace ConversationSource { - /** - * This includes conversation, email, facebook, instagram, phone_call, phone_switch, push, sms, twitter and whatsapp. - */ - export type Type = - | "conversation" - | "email" - | "facebook" - | "instagram" - | "phone_call" - | "phone_switch" - | "push" - | "sms" - | "twitter" - | "whatsapp"; + /** This includes conversation, email, facebook, instagram, phone_call, phone_switch, push, sms, twitter and whatsapp. */ export const Type = { Conversation: "conversation", Email: "email", @@ -54,4 +39,5 @@ export namespace ConversationSource { Twitter: "twitter", Whatsapp: "whatsapp", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } diff --git a/src/api/types/ConversationStatistics.ts b/src/api/types/ConversationStatistics.ts index 18444e0d..999c99f5 100644 --- a/src/api/types/ConversationStatistics.ts +++ b/src/api/types/ConversationStatistics.ts @@ -1,13 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; /** * A Statistics object containing all information required for reporting, with timestamps and calculated metrics. */ export interface ConversationStatistics { /** */ - type: "conversation_statistics"; + type?: string; /** Duration until last assignment before first admin reply. In seconds. */ time_to_assignment?: number; /** Duration until first admin reply. Subtracts out of business hours. In seconds. */ @@ -44,4 +44,12 @@ export interface ConversationStatistics { count_assignments?: number; /** Total number of conversation parts. */ count_conversation_parts?: number; + /** An array of conversation response time objects */ + assigned_team_first_response_time_by_team?: Intercom.ConversationResponseTime[]; + /** An array of conversation response time objects within office hours */ + assigned_team_first_response_time_in_office_hours?: Intercom.ConversationResponseTime[]; + /** Time from conversation assignment to conversation close in seconds. */ + handling_time?: number; + /** Adjusted handling time for conversation in seconds. This is the active handling time excluding idle periods when teammates are not actively working on the conversation. */ + adjusted_handling_time?: number; } diff --git a/src/api/types/ConversationTeammates.ts b/src/api/types/ConversationTeammates.ts index c619dcb5..4f278e45 100644 --- a/src/api/types/ConversationTeammates.ts +++ b/src/api/types/ConversationTeammates.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * The list of teammates who participated in the conversation (wrote at least one conversation part). diff --git a/src/api/resources/articles/client/requests/CreateArticleRequest.ts b/src/api/types/CreateArticleRequest.ts similarity index 52% rename from src/api/resources/articles/client/requests/CreateArticleRequest.ts rename to src/api/types/CreateArticleRequest.ts index ef3fdc01..432c43aa 100644 --- a/src/api/resources/articles/client/requests/CreateArticleRequest.ts +++ b/src/api/types/CreateArticleRequest.ts @@ -1,39 +1,9 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../../../../index"; +import type * as Intercom from "../index.js"; /** - * @example - * { - * title: "Thanks for everything", - * description: "Description of the Article", - * body: "Body of the Article", - * author_id: 991267407, - * state: "published", - * parent_id: 145, - * parent_type: "collection", - * translated_content: { - * fr: { - * type: "article_content", - * title: "Merci pour tout", - * description: "Description de l'article", - * body: "Corps de l'article", - * author_id: 991267407, - * state: "published" - * } - * } - * } - * - * @example - * { - * title: "Thanks for everything", - * description: "Description of the Article", - * body: "Body of the Article", - * author_id: 1295, - * state: "published" - * } + * You can create an Article */ export interface CreateArticleRequest { /** The title of the article.For multilingual articles, this will be the title of the default language's content. */ @@ -54,20 +24,16 @@ export interface CreateArticleRequest { } export namespace CreateArticleRequest { - /** - * Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. - */ - export type State = "published" | "draft"; + /** Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. */ export const State = { Published: "published", Draft: "draft", } as const; - /** - * The type of parent, which can either be a `collection` or `section`. - */ - export type ParentType = "collection" | "section"; + export type State = (typeof State)[keyof typeof State]; + /** The type of parent, which can either be a `collection` or `section`. */ export const ParentType = { Collection: "collection", Section: "section", } as const; + export type ParentType = (typeof ParentType)[keyof typeof ParentType]; } diff --git a/src/api/types/CreateContactRequest.ts b/src/api/types/CreateContactRequest.ts index 9af417df..4067737b 100644 --- a/src/api/types/CreateContactRequest.ts +++ b/src/api/types/CreateContactRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Payload to create a contact diff --git a/src/api/types/CreateContactRequestTwo.ts b/src/api/types/CreateContactRequestTwo.ts index b3041530..06133b6b 100644 --- a/src/api/types/CreateContactRequestTwo.ts +++ b/src/api/types/CreateContactRequestTwo.ts @@ -1,5 +1,3 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export type CreateContactRequestTwo = unknown; diff --git a/src/api/types/CreateDataAttributeRequest.ts b/src/api/types/CreateDataAttributeRequest.ts new file mode 100644 index 00000000..e2abd5d2 --- /dev/null +++ b/src/api/types/CreateDataAttributeRequest.ts @@ -0,0 +1,15 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * + */ +export type CreateDataAttributeRequest = + | { + data_type?: "options" | undefined; + options: { + value?: string | undefined; + }[]; + } + | { + data_type?: ("string" | "integer" | "float" | "boolean" | "datetime" | "date") | undefined; + }; diff --git a/src/api/types/CreateDataEventRequest.ts b/src/api/types/CreateDataEventRequest.ts index 85a0c1c5..b0502eab 100644 --- a/src/api/types/CreateDataEventRequest.ts +++ b/src/api/types/CreateDataEventRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * diff --git a/src/api/types/CreateDataEventRequestTwo.ts b/src/api/types/CreateDataEventRequestTwo.ts index 5eb4bbe5..d4d0d15e 100644 --- a/src/api/types/CreateDataEventRequestTwo.ts +++ b/src/api/types/CreateDataEventRequestTwo.ts @@ -1,5 +1,3 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export type CreateDataEventRequestTwo = unknown; diff --git a/src/api/types/CreateInternalArticleRequest.ts b/src/api/types/CreateInternalArticleRequest.ts new file mode 100644 index 00000000..f971e918 --- /dev/null +++ b/src/api/types/CreateInternalArticleRequest.ts @@ -0,0 +1,15 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * You can create an Internal Article + */ +export interface CreateInternalArticleRequest { + /** The title of the article. */ + title: string; + /** The content of the article. */ + body?: string; + /** The id of the author of the article. */ + author_id: number; + /** The id of the owner of the article. */ + owner_id: number; +} diff --git a/src/api/types/CreateMessageRequest.ts b/src/api/types/CreateMessageRequest.ts index 9434ec98..2e3bc5fb 100644 --- a/src/api/types/CreateMessageRequest.ts +++ b/src/api/types/CreateMessageRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * You can create a message @@ -50,14 +48,12 @@ export namespace CreateMessageRequest { } export namespace To { - /** - * The role associated to the contact - `user` or `lead`. - */ - export type Type = "user" | "lead"; + /** The role associated to the contact - `user` or `lead`. */ export const Type = { User: "user", Lead: "lead", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } } @@ -101,14 +97,12 @@ export namespace CreateMessageRequest { } export namespace To { - /** - * The role associated to the contact - `user` or `lead`. - */ - export type Type = "user" | "lead"; + /** The role associated to the contact - `user` or `lead`. */ export const Type = { User: "user", Lead: "lead", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } } } diff --git a/src/api/types/CreateMessageRequestTwo.ts b/src/api/types/CreateMessageRequestTwo.ts deleted file mode 100644 index 1c075b32..00000000 --- a/src/api/types/CreateMessageRequestTwo.ts +++ /dev/null @@ -1,5 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -export type CreateMessageRequestTwo = unknown; diff --git a/src/api/resources/companies/client/requests/CreateOrUpdateCompanyRequest.ts b/src/api/types/CreateOrUpdateCompanyRequest.ts similarity index 82% rename from src/api/resources/companies/client/requests/CreateOrUpdateCompanyRequest.ts rename to src/api/types/CreateOrUpdateCompanyRequest.ts index 7024d304..136693c2 100644 --- a/src/api/resources/companies/client/requests/CreateOrUpdateCompanyRequest.ts +++ b/src/api/types/CreateOrUpdateCompanyRequest.ts @@ -1,17 +1,7 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** - * @example - * { - * name: "my company", - * company_id: "company_remote_id", - * remote_created_at: 1374138000 - * } - * - * @example - * {} + * You can create or update a Company */ export interface CreateOrUpdateCompanyRequest { /** The name of the Company */ diff --git a/src/api/types/CreateOrUpdateTagRequest.ts b/src/api/types/CreateOrUpdateTagRequest.ts index a79ff2e0..7dfd1b3f 100644 --- a/src/api/types/CreateOrUpdateTagRequest.ts +++ b/src/api/types/CreateOrUpdateTagRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * You can create or update an existing tag. diff --git a/src/api/types/CreatePhoneSwitchRequest.ts b/src/api/types/CreatePhoneSwitchRequest.ts new file mode 100644 index 00000000..aae47b79 --- /dev/null +++ b/src/api/types/CreatePhoneSwitchRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; + +/** + * You can create an phone switch + */ +export interface CreatePhoneSwitchRequest { + /** Phone number in E.164 format, that will receive the SMS to continue the conversation in the Messenger. */ + phone: string; + custom_attributes?: Intercom.CustomAttributes; +} diff --git a/src/api/types/CreateTicketReplyWithCommentRequest.ts b/src/api/types/CreateTicketReplyWithCommentRequest.ts index ad63ed81..31d1cccc 100644 --- a/src/api/types/CreateTicketReplyWithCommentRequest.ts +++ b/src/api/types/CreateTicketReplyWithCommentRequest.ts @@ -1,7 +1,5 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; export type CreateTicketReplyWithCommentRequest = Intercom.ContactReplyTicketRequest | Intercom.AdminReplyTicketRequest; diff --git a/src/api/types/CreateTicketRequest.ts b/src/api/types/CreateTicketRequest.ts deleted file mode 100644 index 272de2b7..00000000 --- a/src/api/types/CreateTicketRequest.ts +++ /dev/null @@ -1,37 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * You can create a Ticket - */ -export interface CreateTicketRequest { - /** The ID of the type of ticket you want to create */ - ticket_type_id: string; - /** The list of contacts (users or leads) affected by this ticket. Currently only one is allowed */ - contacts: CreateTicketRequest.Contacts.Item[]; - /** The ID of the company that the ticket is associated with. The ID that you set upon company creation. */ - company_id?: string; - /** The time the ticket was created. If not provided, the current time will be used. */ - created_at?: number; - ticket_attributes?: Intercom.TicketRequestCustomAttributes; -} - -export namespace CreateTicketRequest { - export type Contacts = Contacts.Item[]; - - export namespace Contacts { - export type Item = - | { - id: string; - } - | { - external_id: string; - } - | { - email: string; - }; - } -} diff --git a/src/api/types/CreateTicketRequestBody.ts b/src/api/types/CreateTicketRequestBody.ts new file mode 100644 index 00000000..9ec9fb5c --- /dev/null +++ b/src/api/types/CreateTicketRequestBody.ts @@ -0,0 +1,48 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * You can create a Ticket + */ +export interface CreateTicketRequestBody { + /** The ID of the type of ticket you want to create */ + ticket_type_id: string; + /** The list of contacts (users or leads) affected by this ticket. Currently only one is allowed */ + contacts: CreateTicketRequestBody.Contacts.Item[]; + /** + * The ID of the conversation you want to link to the ticket. Here are the valid ways of linking two tickets: + * - conversation | back-office ticket + * - customer tickets | non-shared back-office ticket + * - conversation | tracker ticket + * - customer ticket | tracker ticket + */ + conversation_to_link_id?: string; + /** The ID of the company that the ticket is associated with. The unique identifier for the company which is given by Intercom */ + company_id?: string; + /** The time the ticket was created. If not provided, the current time will be used. */ + created_at?: number; + assignment?: CreateTicketRequestBody.Assignment; +} + +export namespace CreateTicketRequestBody { + export type Contacts = Contacts.Item[]; + + export namespace Contacts { + export type Item = + | { + id: string; + } + | { + external_id: string; + } + | { + email: string; + }; + } + + export interface Assignment { + /** The ID of the admin to which the ticket is assigned. If not provided, the ticket will be unassigned. */ + admin_assignee_id?: string; + /** The ID of the team to which the ticket is assigned. If not provided, the ticket will be unassigned. */ + team_assignee_id?: string; + } +} diff --git a/src/api/types/CreateTicketTypeRequest.ts b/src/api/types/CreateTicketTypeRequest.ts new file mode 100644 index 00000000..eebc72da --- /dev/null +++ b/src/api/types/CreateTicketTypeRequest.ts @@ -0,0 +1,28 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * The request payload for creating a ticket type. + * You can copy the `icon` property for your ticket type from [Twemoji Cheatsheet](https://twemoji-cheatsheet.vercel.app/) + */ +export interface CreateTicketTypeRequest { + /** The name of the ticket type. */ + name: string; + /** The description of the ticket type. */ + description?: string; + /** Category of the Ticket Type. */ + category?: CreateTicketTypeRequest.Category; + /** The icon of the ticket type. */ + icon?: string; + /** Whether the tickets associated with this ticket type are intended for internal use only or will be shared with customers. This is currently a limited attribute. */ + is_internal?: boolean; +} + +export namespace CreateTicketTypeRequest { + /** Category of the Ticket Type. */ + export const Category = { + Customer: "Customer", + BackOffice: "Back-office", + Tracker: "Tracker", + } as const; + export type Category = (typeof Category)[keyof typeof Category]; +} diff --git a/src/api/types/CurrentCanvas.ts b/src/api/types/CurrentCanvas.ts deleted file mode 100644 index d985ac0f..00000000 --- a/src/api/types/CurrentCanvas.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * The current canvas that was most recently showing before the request was sent. This object mirrors the same format as the Canvas Object. - */ -export interface CurrentCanvas { - /** The canvas object representing the current canvas state. */ - current_canvas: Intercom.CanvasObject; -} diff --git a/src/api/types/CursorPages.ts b/src/api/types/CursorPages.ts index db27af6a..4245c670 100644 --- a/src/api/types/CursorPages.ts +++ b/src/api/types/CursorPages.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Cursor-based pagination is a technique used in the Intercom API to navigate through large amounts of data. @@ -10,7 +8,7 @@ import * as Intercom from "../index"; */ export interface CursorPages { /** the type of object `pages`. */ - type: "pages"; + type?: "pages"; /** The current page */ page?: number; next?: Intercom.StartingAfterPaging; diff --git a/src/api/types/CustomActionFinished.ts b/src/api/types/CustomActionFinished.ts new file mode 100644 index 00000000..54471392 --- /dev/null +++ b/src/api/types/CustomActionFinished.ts @@ -0,0 +1,26 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains details about final status of the completed action for conversation part type custom_action_finished. + */ +export interface CustomActionFinished { + action?: CustomActionFinished.Action; +} + +export namespace CustomActionFinished { + export interface Action { + /** Name of the action */ + name?: string; + /** Status of the action */ + result?: Action.Result; + } + + export namespace Action { + /** Status of the action */ + export const Result = { + Success: "success", + Failed: "failed", + } as const; + export type Result = (typeof Result)[keyof typeof Result]; + } +} diff --git a/src/api/types/CustomActionStarted.ts b/src/api/types/CustomActionStarted.ts new file mode 100644 index 00000000..18114f6c --- /dev/null +++ b/src/api/types/CustomActionStarted.ts @@ -0,0 +1,15 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains details about name of the action that was initiated for conversation part type custom_action_started. + */ +export interface CustomActionStarted { + action?: CustomActionStarted.Action; +} + +export namespace CustomActionStarted { + export interface Action { + /** Name of the action */ + name?: string; + } +} diff --git a/src/api/types/CustomAttributes.ts b/src/api/types/CustomAttributes.ts index ebc3d771..6fd00ee3 100644 --- a/src/api/types/CustomAttributes.ts +++ b/src/api/types/CustomAttributes.ts @@ -1,8 +1,12 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; /** * Custom data set for this data. */ -export type CustomAttributes = Record; +export type CustomAttributes = Record; + +export namespace CustomAttributes { + export type Value = string | number | Intercom.Datetime | Intercom.CustomObjectInstanceList; +} diff --git a/src/api/types/CustomChannelAttribute.ts b/src/api/types/CustomChannelAttribute.ts new file mode 100644 index 00000000..9afa1dd6 --- /dev/null +++ b/src/api/types/CustomChannelAttribute.ts @@ -0,0 +1,8 @@ +// This file was auto-generated by Fern from our API Definition. + +export interface CustomChannelAttribute { + /** Identifier for the attribute being collected. */ + id: string; + /** Value provided by the user for the attribute. */ + value: string; +} diff --git a/src/api/types/CustomChannelBaseEvent.ts b/src/api/types/CustomChannelBaseEvent.ts new file mode 100644 index 00000000..dcf9e00e --- /dev/null +++ b/src/api/types/CustomChannelBaseEvent.ts @@ -0,0 +1,11 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; + +export interface CustomChannelBaseEvent { + /** Unique identifier for the event. */ + event_id: string; + /** Identifier for the conversation in your application. */ + external_conversation_id: string; + contact: Intercom.CustomChannelContact; +} diff --git a/src/api/types/CustomChannelContact.ts b/src/api/types/CustomChannelContact.ts new file mode 100644 index 00000000..7d11a83c --- /dev/null +++ b/src/api/types/CustomChannelContact.ts @@ -0,0 +1,21 @@ +// This file was auto-generated by Fern from our API Definition. + +export interface CustomChannelContact { + /** Type of contact, must be "user" or "lead". */ + type: CustomChannelContact.Type; + /** External identifier for the contact. Intercom will take care of the mapping of your external_id with our internal ones so you don't have to worry about it. */ + external_id: string; + /** Name of the contact. Required for user type. */ + name?: string; + /** Email address of the contact. Required for user type. */ + email?: string; +} + +export namespace CustomChannelContact { + /** Type of contact, must be "user" or "lead". */ + export const Type = { + User: "user", + Lead: "lead", + } as const; + export type Type = (typeof Type)[keyof typeof Type]; +} diff --git a/src/api/types/CustomChannelNotificationResponse.ts b/src/api/types/CustomChannelNotificationResponse.ts new file mode 100644 index 00000000..238b883d --- /dev/null +++ b/src/api/types/CustomChannelNotificationResponse.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +export interface CustomChannelNotificationResponse { + /** The external conversation ID provided in the notification request */ + external_conversation_id: string; + /** The Intercom conversation ID mapped to the external conversation ID */ + conversation_id: string; + /** The external contact ID provided in the notification request */ + external_contact_id: string; + /** The Intercom contact ID mapped to the external contact ID */ + contact_id: string; +} diff --git a/src/api/types/CustomObjectInstanceDeleted.ts b/src/api/types/CustomObjectInstanceDeleted.ts new file mode 100644 index 00000000..4c14eba9 --- /dev/null +++ b/src/api/types/CustomObjectInstanceDeleted.ts @@ -0,0 +1,13 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * deleted custom object instance object + */ +export interface CustomObjectInstanceDeleted { + /** The unique identifier of the Custom Object type that defines the structure of the Custom Object instance. */ + object?: string; + /** The Intercom defined id representing the Custom Object instance. */ + id?: string; + /** Whether the Custom Object instance is deleted or not. */ + deleted?: boolean; +} diff --git a/src/api/types/CustomObjectInstanceList.ts b/src/api/types/CustomObjectInstanceList.ts new file mode 100644 index 00000000..f537ed2d --- /dev/null +++ b/src/api/types/CustomObjectInstanceList.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; + +/** + * The list of associated custom object instances for a given reference attribute on the parent object. + */ +export interface CustomObjectInstanceList { + type?: string; + /** The list of associated custom object instances for a given reference attribute on the parent object. */ + instances?: (Intercom.CustomObjectInstance | undefined)[]; +} diff --git a/src/api/types/CustomerRequest.ts b/src/api/types/CustomerRequest.ts index 6ede7a3d..d86d11c7 100644 --- a/src/api/types/CustomerRequest.ts +++ b/src/api/types/CustomerRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export type CustomerRequest = | { diff --git a/src/api/types/DataAttributeList.ts b/src/api/types/DataAttributeList.ts index 860b9192..6fb01c20 100644 --- a/src/api/types/DataAttributeList.ts +++ b/src/api/types/DataAttributeList.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A list of all data attributes belonging to a workspace for contacts, companies or conversations. */ export interface DataAttributeList { /** The type of the object */ - type: "list"; + type?: "list"; /** A list of data attributes */ - data: Intercom.DataAttribute[]; + data?: Intercom.DataAttribute[]; } diff --git a/src/api/types/DataEventList.ts b/src/api/types/DataEventList.ts index 90c73811..2a68082a 100644 --- a/src/api/types/DataEventList.ts +++ b/src/api/types/DataEventList.ts @@ -1,17 +1,15 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * This will return a list of data events for the App. */ export interface DataEventList { /** The type of the object */ - type: "event.list"; + type?: "event.list"; /** A list of data events */ - events: Intercom.DataEvent[]; + events?: Intercom.DataEvent[]; /** Pagination */ pages?: DataEventList.Pages; } diff --git a/src/api/types/DataEventSummary.ts b/src/api/types/DataEventSummary.ts index df7d10fd..e2791b1f 100644 --- a/src/api/types/DataEventSummary.ts +++ b/src/api/types/DataEventSummary.ts @@ -1,21 +1,19 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * This will return a summary of data events for the App. */ export interface DataEventSummary { /** The type of the object */ - type: "event.summary"; + type?: "event.summary"; /** The email address of the user */ - email: string; + email?: string; /** The Intercom user ID of the user */ - intercom_user_id: string; + intercom_user_id?: string; /** The user ID of the user */ - user_id: string; + user_id?: string; /** A summary of data events */ - events: Intercom.DataEventSummaryItem[]; + events: (Intercom.DataEventSummaryItem | undefined)[]; } diff --git a/src/api/types/DataEventSummaryItem.ts b/src/api/types/DataEventSummaryItem.ts index 581a8e54..9f0d9192 100644 --- a/src/api/types/DataEventSummaryItem.ts +++ b/src/api/types/DataEventSummaryItem.ts @@ -1,19 +1,17 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * This will return a summary of a data event for the App. */ export interface DataEventSummaryItem { /** The name of the event */ - name: string; + name?: string; /** The first time the event was sent */ - first: string; + first?: string; /** The last time the event was sent */ - last: string; + last?: string; /** The number of times the event was sent */ - count: number; + count?: number; /** The description of the event */ description?: string; } diff --git a/src/api/types/DataExportCsv.ts b/src/api/types/DataExportCsv.ts index 22f1bf3c..8c268f7e 100644 --- a/src/api/types/DataExportCsv.ts +++ b/src/api/types/DataExportCsv.ts @@ -1,29 +1,27 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A CSV output file */ export interface DataExportCsv { /** The user_id of the user who was sent the message. */ - user_id: string; + user_id?: string; /** The external_user_id of the user who was sent the message */ user_external_id?: string; /** The company ID of the user in relation to the message that was sent. Will return -1 if no company is present. */ - company_id: string; + company_id?: string; /** The users email who was sent the message. */ - email: string; + email?: string; /** The full name of the user receiving the message */ - name: string; + name?: string; /** The id of the message. */ - ruleset_id: string; + ruleset_id?: string; /** The specific content that was received. In an A/B test each version has its own Content ID. */ - content_id: string; + content_id?: string; /** Email, Chat, Post etc. */ - content_type: string; + content_type?: string; /** The title of the content you see in your Intercom workspace. */ - content_title: string; + content_title?: string; /** As you edit content we record new versions. This ID can help you determine which version of a piece of content that was received. */ ruleset_version_id?: string; /** ID for this receipt. Will be included with any related stats in other files to identify this specific delivery of a message. */ diff --git a/src/api/types/DataTableComponent.ts b/src/api/types/DataTableComponent.ts deleted file mode 100644 index 64e38560..00000000 --- a/src/api/types/DataTableComponent.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * A data-table component is used for rendering a table of key-value pairs. For Messenger, text will wrap around on multiple lines. For Inbox and Frame (ie. Configure) views, we will truncate and use tooltips on hover if the text overflows. - */ -export interface DataTableComponent { - /** The items that will be rendered in the data-table. */ - items: Intercom.DataTableItem[]; -} diff --git a/src/api/types/DataTableItem.ts b/src/api/types/DataTableItem.ts deleted file mode 100644 index f0b9e04f..00000000 --- a/src/api/types/DataTableItem.ts +++ /dev/null @@ -1,15 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A field-value pair component for use in a data table. - */ -export interface DataTableItem { - /** The type of component you are rendering. */ - type: "field-value"; - /** The text of the key in your key-value pair. */ - field: string; - /** The text of the value in your key-value pair. */ - value: string; -} diff --git a/src/api/types/Datetime.ts b/src/api/types/Datetime.ts new file mode 100644 index 00000000..63964732 --- /dev/null +++ b/src/api/types/Datetime.ts @@ -0,0 +1,9 @@ +// This file was auto-generated by Fern from our API Definition. + +export type Datetime = + /** + * A date and time following the ISO8601 notation. */ + | string + /** + * A date and time as UNIX timestamp notation. */ + | number; diff --git a/src/api/types/DeletedArticleObject.ts b/src/api/types/DeletedArticleObject.ts index b792af78..5667114c 100644 --- a/src/api/types/DeletedArticleObject.ts +++ b/src/api/types/DeletedArticleObject.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Response returned when an object is deleted */ export interface DeletedArticleObject { /** The unique identifier for the article which you provided in the URL. */ - id: string; + id?: string; /** The type of object which was deleted. - article */ - object: "article"; + object?: "article"; /** Whether the article was deleted successfully or not. */ - deleted: boolean; + deleted?: boolean; } diff --git a/src/api/types/DeletedCollectionObject.ts b/src/api/types/DeletedCollectionObject.ts index f01ce8e6..4d03d936 100644 --- a/src/api/types/DeletedCollectionObject.ts +++ b/src/api/types/DeletedCollectionObject.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Response returned when an object is deleted */ export interface DeletedCollectionObject { /** The unique identifier for the collection which you provided in the URL. */ - id: string; + id?: string; /** The type of object which was deleted. - `collection` */ - object: "collection"; + object?: "collection"; /** Whether the collection was deleted successfully or not. */ - deleted: boolean; + deleted?: boolean; } diff --git a/src/api/types/DeletedCompanyObject.ts b/src/api/types/DeletedCompanyObject.ts index e3252c3c..b5ee6cf6 100644 --- a/src/api/types/DeletedCompanyObject.ts +++ b/src/api/types/DeletedCompanyObject.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Response returned when an object is deleted */ export interface DeletedCompanyObject { /** The unique identifier for the company which is given by Intercom. */ - id: string; + id?: string; /** The type of object which was deleted. - `company` */ - object: "company"; + object?: "company"; /** Whether the company was deleted successfully or not. */ - deleted: boolean; + deleted?: boolean; } diff --git a/src/api/types/DeletedInternalArticleObject.ts b/src/api/types/DeletedInternalArticleObject.ts new file mode 100644 index 00000000..47d5060b --- /dev/null +++ b/src/api/types/DeletedInternalArticleObject.ts @@ -0,0 +1,13 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Response returned when an object is deleted + */ +export interface DeletedInternalArticleObject { + /** The unique identifier for the internal article which you provided in the URL. */ + id?: string; + /** The type of object which was deleted. - internal_article */ + object?: "internal_article"; + /** Whether the internal article was deleted successfully or not. */ + deleted?: boolean; +} diff --git a/src/api/types/DeletedObject.ts b/src/api/types/DeletedObject.ts index f0bcc357..a22b393b 100644 --- a/src/api/types/DeletedObject.ts +++ b/src/api/types/DeletedObject.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Response returned when an object is deleted */ export interface DeletedObject { /** The unique identifier for the news item which you provided in the URL. */ - id: string; + id?: string; /** The type of object which was deleted - news-item. */ - object: "news-item"; + object?: "news-item"; /** Whether the news item was deleted successfully or not. */ - deleted: boolean; + deleted?: boolean; } diff --git a/src/api/types/DividerComponent.ts b/src/api/types/DividerComponent.ts deleted file mode 100644 index 7b37b3c8..00000000 --- a/src/api/types/DividerComponent.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A divider component is used to separate components with a line. - */ -export interface DividerComponent { - /** A unique identifier for the component. */ - id?: string; - /** Disables a component's margin-bottom of 10px. */ - bottom_margin?: "none"; -} diff --git a/src/api/types/DropdownComponent.ts b/src/api/types/DropdownComponent.ts deleted file mode 100644 index f0d36aaa..00000000 --- a/src/api/types/DropdownComponent.ts +++ /dev/null @@ -1,37 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * A dropdown component is used to capture a choice from the options that you provide. - * - * When submitted, the dropdown choices are returned in a hash with the id from the dropdown component used as the key and the id from the chosen option as the value. - */ -export interface DropdownComponent { - /** A unique identifier for the component. */ - id: string; - /** The list of options. Can provide 2 to 10. */ - options: Intercom.DropdownOption[]; - /** The text shown above the dropdown. */ - label?: string; - /** The option that is selected by default. */ - value?: string; - /** Styles all options and prevents the action. Default is `unsaved`. Will be overridden if `save_state` is `saved`. */ - save_state?: DropdownComponent.SaveState; - /** Styles all options and prevents the action. Default is false. Will be overridden if save_state is saved. */ - disabled?: boolean; -} - -export namespace DropdownComponent { - /** - * Styles all options and prevents the action. Default is `unsaved`. Will be overridden if `save_state` is `saved`. - */ - export type SaveState = "unsaved" | "saved" | "failed"; - export const SaveState = { - Unsaved: "unsaved", - Saved: "saved", - Failed: "failed", - } as const; -} diff --git a/src/api/types/DropdownOption.ts b/src/api/types/DropdownOption.ts deleted file mode 100644 index 17bd18e5..00000000 --- a/src/api/types/DropdownOption.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A dropdown option component that can be selected. - */ -export interface DropdownOption { - /** The type of component you are rendering. */ - type: "option"; - /** A unique identifier for the option. */ - id: string; - /** The text shown within this option. */ - text: string; - /** Styles the option and prevents the action. Default is false. */ - disabled?: boolean; -} diff --git a/src/api/types/EmailAddressHeader.ts b/src/api/types/EmailAddressHeader.ts new file mode 100644 index 00000000..7e8d234d --- /dev/null +++ b/src/api/types/EmailAddressHeader.ts @@ -0,0 +1,13 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains data for an email address header for a conversation part that was sent as an email. + */ +export interface EmailAddressHeader { + /** The type of email address header */ + type?: string; + /** The email address */ + email_address?: string; + /** The name associated with the email address */ + name?: string; +} diff --git a/src/api/types/EmailMessageMetadata.ts b/src/api/types/EmailMessageMetadata.ts new file mode 100644 index 00000000..815571b7 --- /dev/null +++ b/src/api/types/EmailMessageMetadata.ts @@ -0,0 +1,13 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; + +/** + * Contains metadata if the message was sent as an email + */ +export interface EmailMessageMetadata { + /** The subject of the email */ + subject?: string; + /** A list of an email address headers. */ + email_address_headers?: Intercom.EmailAddressHeader[]; +} diff --git a/src/api/types/Error_.ts b/src/api/types/Error_.ts index a9df7613..5a4a39f0 100644 --- a/src/api/types/Error_.ts +++ b/src/api/types/Error_.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The API will return an Error List for a failed request, which will contain one or more Error objects. diff --git a/src/api/types/Event.ts b/src/api/types/Event.ts deleted file mode 100644 index b6bbe375..00000000 --- a/src/api/types/Event.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * The event object enables Intercom to know more about the actions that took place in your app. Currently, you can only tell us when an app's flow has been completed. - */ -export interface Event { - /** What action took place. The only value currently accepted is `completed`. */ - type: "completed"; -} diff --git a/src/api/types/EventDetails.ts b/src/api/types/EventDetails.ts new file mode 100644 index 00000000..6db41ca1 --- /dev/null +++ b/src/api/types/EventDetails.ts @@ -0,0 +1,10 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; + +export type EventDetails = + | Intercom.ConversationAttributeUpdatedByWorkflow + | Intercom.ConversationAttributeUpdatedByAdmin + | Intercom.CustomActionStarted + | Intercom.CustomActionFinished + | Intercom.OperatorWorkflowEvent; diff --git a/src/api/types/FileAttribute.ts b/src/api/types/FileAttribute.ts index e33ed602..b8fab036 100644 --- a/src/api/types/FileAttribute.ts +++ b/src/api/types/FileAttribute.ts @@ -1,22 +1,20 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The value describing a file upload set for a custom attribute */ export interface FileAttribute { - type: string; + type?: string; /** The name of the file */ - name: string; + name?: string; /** The url of the file. This is a temporary URL and will expire after 30 minutes. */ - url: string; + url?: string; /** The type of file */ - content_type: string; + content_type?: string; /** The size of the file in bytes */ - filesize: number; + filesize?: number; /** The width of the file in pixels, if applicable */ - width: number; + width?: number; /** The height of the file in pixels, if applicable */ - height: number; + height?: number; } diff --git a/src/api/types/GroupContent.ts b/src/api/types/GroupContent.ts index 92c493c6..68c5b320 100644 --- a/src/api/types/GroupContent.ts +++ b/src/api/types/GroupContent.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The Content of a Group. */ export interface GroupContent { /** The type of object - `group_content` . */ - type: "group_content"; + type?: "group_content"; /** The name of the collection or section. */ - name: string; + name?: string; /** The description of the collection. Only available for collections. */ - description: string; + description?: string; } diff --git a/src/api/types/GroupTranslatedContent.ts b/src/api/types/GroupTranslatedContent.ts index 8f89cab2..51302ff2 100644 --- a/src/api/types/GroupTranslatedContent.ts +++ b/src/api/types/GroupTranslatedContent.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * The Translated Content of an Group. The keys are the locale codes and the values are the translated content of the Group. */ export interface GroupTranslatedContent { /** The type of object - group_translated_content. */ - type: "group_translated_content"; + type?: "group_translated_content"; /** The content of the group in Arabic */ ar?: Intercom.GroupContent; /** The content of the group in Bulgarian */ diff --git a/src/api/types/ImageComponent.ts b/src/api/types/ImageComponent.ts deleted file mode 100644 index 52e8d603..00000000 --- a/src/api/types/ImageComponent.ts +++ /dev/null @@ -1,43 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * An image component is used to display an image. - * - * HTTPS Images: - * If your request URLs (or website URLs) are over HTTPS, you will need to ensure that images are loaded over HTTPS likewise. Otherwise, they will not work. - */ -export interface ImageComponent { - /** A unique identifier for the component. */ - id?: string; - /** The URL where the image is located. */ - url: string; - /** Aligns the image inside the component. Default is `left`. */ - align?: ImageComponent.Align; - /** The exact width of the image in pixels. */ - width: number; - /** The exact height of the image in pixels. */ - height: number; - /** Rounds the corners of the image. Default is `false`. */ - rounded?: boolean; - /** Disables a component's margin-bottom of 10px. */ - bottom_margin?: "none"; - /** This can be a URL Action only. */ - action?: Intercom.UrlActionComponent; -} - -export namespace ImageComponent { - /** - * Aligns the image inside the component. Default is `left`. - */ - export type Align = "left" | "center" | "right" | "full_width"; - export const Align = { - Left: "left", - Center: "center", - Right: "right", - FullWidth: "full_width", - } as const; -} diff --git a/src/api/types/InitializeRequest.ts b/src/api/types/InitializeRequest.ts deleted file mode 100644 index e3d617b9..00000000 --- a/src/api/types/InitializeRequest.ts +++ /dev/null @@ -1,25 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * The request payload will have all the data needed for you to understand who is using your app, where they are using it, and how you should respond. There are different request payloads for Messenger capabilities and Inbox capabilities. - */ -export interface InitializeRequest { - /** The workspace ID of the teammate. Attribute is `app_id` for V1.2 and below. */ - workspace_id: string; - /** The Intercom hosted region that this app is located in. */ - workspace_region: string; - /** The Intercom teammate viewing the conversation. */ - admin: Intercom.Admin; - /** Key-value pairs which were given as results in response to the Configure request. */ - card_creation_options: Record; - /** The context of where the app is added, where the user last visited, and information on the Messenger settings. */ - context: Intercom.Context; - /** The conversation your app is being shown for. */ - conversation: Intercom.Conversation; - /** The contact which is currently being viewed by the teammate in the conversation details panel. We send an individual initialize request for each customer when it's a group conversation. */ - contact: Intercom.Contact; -} diff --git a/src/api/types/InitializeResponse.ts b/src/api/types/InitializeResponse.ts deleted file mode 100644 index a675eeaa..00000000 --- a/src/api/types/InitializeResponse.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * The response object returned when initializing an app, specifying the UI for the first screen using components. - */ -export interface InitializeResponse { - /** The canvas object that defines the UI to be shown for the app. */ - canvas: Intercom.CanvasObject; -} diff --git a/src/api/types/InputComponent.ts b/src/api/types/InputComponent.ts deleted file mode 100644 index cd7f86fb..00000000 --- a/src/api/types/InputComponent.ts +++ /dev/null @@ -1,40 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * An input component is used to capture text input from the end user. You can submit the value of the input by: - * - * - Adding an `action` to the input component (which will render an inline button) - * - Using a ButtonComponent (which will submit all interactive components in the canvas) - */ -export interface InputComponent { - /** A unique identifier for the component. */ - id: string; - /** The text shown above the input. */ - label?: string; - /** An example value shown inside the component when it's empty. */ - placeholder?: string; - /** An entered value which is already inside the component. */ - value?: string; - /** This can be a Submit Action, URL Action, or Sheets Action. */ - action?: Intercom.ActionComponent; - /** Styles the input. Default is `unsaved`. Prevent action with `saved`. */ - save_state?: InputComponent.SaveState; - /** Styles the input and prevents the action. Default is false. Will be overridden if save_state is saved. */ - disabled?: boolean; -} - -export namespace InputComponent { - /** - * Styles the input. Default is `unsaved`. Prevent action with `saved`. - */ - export type SaveState = "unsaved" | "saved" | "failed"; - export const SaveState = { - Unsaved: "unsaved", - Saved: "saved", - Failed: "failed", - } as const; -} diff --git a/src/api/types/InternalArticleList.ts b/src/api/types/InternalArticleList.ts new file mode 100644 index 00000000..8de68a0a --- /dev/null +++ b/src/api/types/InternalArticleList.ts @@ -0,0 +1,16 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; + +/** + * This will return a list of internal articles for the App. + */ +export interface InternalArticleList { + /** The type of the object - `list`. */ + type?: "list"; + pages?: Intercom.CursorPages; + /** A count of the total number of internal articles. */ + total_count?: number; + /** An array of Internal Article objects */ + data?: Intercom.InternalArticleListItem[]; +} diff --git a/src/api/types/LinkedObject.ts b/src/api/types/LinkedObject.ts index 262dd306..27fe77b5 100644 --- a/src/api/types/LinkedObject.ts +++ b/src/api/types/LinkedObject.ts @@ -1,26 +1,29 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A linked conversation or ticket. */ export interface LinkedObject { /** ticket or conversation */ - type: LinkedObject.Type; + type?: LinkedObject.Type; /** The ID of the linked object */ - id: string; + id?: string; /** Category of the Linked Ticket Object. */ - category?: string; + category?: LinkedObject.Category; } export namespace LinkedObject { - /** - * ticket or conversation - */ - export type Type = "ticket" | "conversation"; + /** ticket or conversation */ export const Type = { Ticket: "ticket", Conversation: "conversation", } as const; + export type Type = (typeof Type)[keyof typeof Type]; + /** Category of the Linked Ticket Object. */ + export const Category = { + Customer: "Customer", + BackOffice: "Back-office", + Tracker: "Tracker", + } as const; + export type Category = (typeof Category)[keyof typeof Category]; } diff --git a/src/api/types/LinkedObjectList.ts b/src/api/types/LinkedObjectList.ts index 043bfe1c..3443c217 100644 --- a/src/api/types/LinkedObjectList.ts +++ b/src/api/types/LinkedObjectList.ts @@ -1,19 +1,17 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * An object containing metadata about linked conversations and linked tickets. Up to 1000 can be returned. */ export interface LinkedObjectList { /** Always list. */ - type: "list"; + type?: "list"; /** The total number of linked objects. */ - total_count: number; + total_count?: number; /** Whether or not there are more linked objects than returned. */ - has_more: boolean; + has_more?: boolean; /** An array containing the linked conversations and linked tickets. */ - data: Intercom.LinkedObject[]; + data?: Intercom.LinkedObject[]; } diff --git a/src/api/types/ListComponent.ts b/src/api/types/ListComponent.ts deleted file mode 100644 index b80e900d..00000000 --- a/src/api/types/ListComponent.ts +++ /dev/null @@ -1,27 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * A list component renders a list of items which you provide in an array. You can make each list item take an action by adding the relevant action object to the item: - * - * - [Trigger a submit request to be sent](https://developers.intercom.com/docs/references/canvas-kit/actioncomponents/submit-action) Inbox Messenger - * - [Open a link in a new page](https://developers.intercom.com/docs/references/canvas-kit/actioncomponents/url-action) Inbox Messenger - * - [Open a sheet](https://developers.intercom.com/docs/references/canvas-kit/actioncomponents/sheets-action) Messenger - */ -export interface ListComponent { - /** The items that will be rendered in the list. */ - items: ListComponent.Items.Item[]; - /** Styles all list items and prevents the action. Default is `false`. */ - disabled?: boolean; -} - -export namespace ListComponent { - export type Items = Items.Item[]; - - export namespace Items { - export type Item = Intercom.ListItemWithImage | Intercom.ListItemWithoutImage; - } -} diff --git a/src/api/types/ListItem.ts b/src/api/types/ListItem.ts deleted file mode 100644 index d85d821c..00000000 --- a/src/api/types/ListItem.ts +++ /dev/null @@ -1,27 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * A list item component that can be rendered in a list. - */ -export interface ListItem { - /** The type of component you are rendering. */ - type: "item"; - /** A unique identifier for the item. */ - id: string; - /** The text shown as the title for the item. */ - title: string; - /** The text shown underneath the item's title. */ - subtitle?: string; - /** The text shown next to the subtitle, separates by a bullet. */ - tertiary_text?: string; - /** Rounds the corners of the image. Default is `false`. */ - rounded_image?: boolean; - /** Styles all list items and prevents the action. Default is `false`. */ - disabled?: boolean; - /** This can be a Submit Action, URL Action, or Sheets Action. */ - action?: Intercom.ActionComponent; -} diff --git a/src/api/types/ListItemWithImage.ts b/src/api/types/ListItemWithImage.ts deleted file mode 100644 index 4d62f441..00000000 --- a/src/api/types/ListItemWithImage.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -export interface ListItemWithImage extends Intercom.ListItem { - /** An image that will be displayed to the left of the item. */ - image: string; - /** The exact width of the image in pixels. */ - image_width: number; - /** The exact height of the image in pixels. */ - image_height: number; -} diff --git a/src/api/types/ListItemWithoutImage.ts b/src/api/types/ListItemWithoutImage.ts deleted file mode 100644 index d5f911ec..00000000 --- a/src/api/types/ListItemWithoutImage.ts +++ /dev/null @@ -1,14 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -export interface ListItemWithoutImage extends Intercom.ListItem { - /** An image that will be displayed to the left of the item. */ - image?: string; - /** The exact width of the image in pixels. */ - image_width?: number; - /** The exact height of the image in pixels. */ - image_height?: number; -} diff --git a/src/api/types/LiveCanvasRequest.ts b/src/api/types/LiveCanvasRequest.ts deleted file mode 100644 index 4c90a1d5..00000000 --- a/src/api/types/LiveCanvasRequest.ts +++ /dev/null @@ -1,23 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * Canvases are static by default and require a new request to come through in order to update them. Live canvases however will make requests every time the card is viewed without any interaction needed, meaning the canvas can be kept up-to-date with no action from the user. - * - * This works for every Messenger request that you can respond with a canvas object to. Instead of returning the content object within the canvas object, you should provide a `content_url` attribute instead with the value being the URL you want us to send a POST request to when someone views the app. - */ -export interface LiveCanvasRequest { - /** The workspace ID of the teammate. Attribute is `app_id` for V1.2 and below. */ - workspace_id: string; - /** The Intercom hosted region that this app is located in. */ - workspace_region: string; - /** The current_canvas the teammate can see. */ - canvas: Intercom.CanvasObject; - /** The context of where the app is added, where the user last visited, and information on the Messenger settings. */ - context: Intercom.Context; - /** The contact who viewed the card. */ - contact: Intercom.Contact; -} diff --git a/src/api/types/LiveCanvasResponse.ts b/src/api/types/LiveCanvasResponse.ts deleted file mode 100644 index fca96ef7..00000000 --- a/src/api/types/LiveCanvasResponse.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * The response object returned when responding to a Live Canvas request. This contains the components you want to show. - */ -export interface LiveCanvasResponse { - /** The content object that defines the components to be shown. */ - content: Intercom.ContentObject; -} diff --git a/src/api/types/Metadata.ts b/src/api/types/Metadata.ts index 1c29cca9..8d9ca56e 100644 --- a/src/api/types/Metadata.ts +++ b/src/api/types/Metadata.ts @@ -1,7 +1,5 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; export type Metadata = Intercom.unstable.ConversationPartMetadata; diff --git a/src/api/types/MultipleFilterSearchRequest.ts b/src/api/types/MultipleFilterSearchRequest.ts index 8554380e..400b4119 100644 --- a/src/api/types/MultipleFilterSearchRequest.ts +++ b/src/api/types/MultipleFilterSearchRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Search using Intercoms Search APIs with more than one filter. @@ -10,16 +8,21 @@ import * as Intercom from "../index"; export interface MultipleFilterSearchRequest { /** An operator to allow boolean inspection between multiple fields. */ operator?: MultipleFilterSearchRequest.Operator; - value?: Intercom.MultipleOrSingleFilterSearchRequest[]; + value?: MultipleFilterSearchRequest.Value; } export namespace MultipleFilterSearchRequest { - /** - * An operator to allow boolean inspection between multiple fields. - */ - export type Operator = "AND" | "OR"; + /** An operator to allow boolean inspection between multiple fields. */ export const Operator = { And: "AND", Or: "OR", } as const; + export type Operator = (typeof Operator)[keyof typeof Operator]; + export type Value = + /** + * Add mutiple filters. */ + | Intercom.MultipleFilterSearchRequest[] + /** + * Add a single filter field. */ + | Intercom.SingleFilterSearchRequest[]; } diff --git a/src/api/types/MultipleOrSingleFilterSearchRequest.ts b/src/api/types/MultipleOrSingleFilterSearchRequest.ts deleted file mode 100644 index 05b7916a..00000000 --- a/src/api/types/MultipleOrSingleFilterSearchRequest.ts +++ /dev/null @@ -1,9 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -export type MultipleOrSingleFilterSearchRequest = - | Intercom.MultipleFilterSearchRequest - | Intercom.SingleFilterSearchRequest; diff --git a/src/api/types/NewsItemRequest.ts b/src/api/types/NewsItemRequest.ts index a7aaf7e4..89a1a61d 100644 --- a/src/api/types/NewsItemRequest.ts +++ b/src/api/types/NewsItemRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A News Item is a content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers. @@ -27,12 +25,10 @@ export interface NewsItemRequest { } export namespace NewsItemRequest { - /** - * News items will not be visible to your users in the assigned newsfeeds until they are set live. - */ - export type State = "draft" | "live"; + /** News items will not be visible to your users in the assigned newsfeeds until they are set live. */ export const State = { Draft: "draft", Live: "live", } as const; + export type State = (typeof State)[keyof typeof State]; } diff --git a/src/api/types/NotFoundErrorBody.ts b/src/api/types/NotFoundErrorBody.ts new file mode 100644 index 00000000..de9109f3 --- /dev/null +++ b/src/api/types/NotFoundErrorBody.ts @@ -0,0 +1,23 @@ +// This file was auto-generated by Fern from our API Definition. + +export interface NotFoundErrorBody { + /** The type is error.list */ + type: string; + /** */ + request_id?: string; + /** An array of one or more error objects */ + errors: NotFoundErrorBody.Errors.Item[]; +} + +export namespace NotFoundErrorBody { + export type Errors = Errors.Item[]; + + export namespace Errors { + export interface Item { + /** ticket_not_found */ + code: string; + /** Ticket not found */ + message?: string; + } + } +} diff --git a/src/api/types/NoteList.ts b/src/api/types/NoteList.ts index e9bf93ee..5090713e 100644 --- a/src/api/types/NoteList.ts +++ b/src/api/types/NoteList.ts @@ -1,18 +1,15 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A paginated list of notes associated with a contact. */ export interface NoteList { /** String representing the object's type. Always has the value `list`. */ - type: "list"; + type?: string; /** An array of notes. */ - data: Intercom.Note[]; + data?: Intercom.Note[]; /** A count of the total number of notes. */ - total_count: number; - pages?: Intercom.OffsetPages; + total_count?: number; } diff --git a/src/api/types/OffsetPages.ts b/src/api/types/OffsetPages.ts index 618d4b85..7118e2df 100644 --- a/src/api/types/OffsetPages.ts +++ b/src/api/types/OffsetPages.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export interface OffsetPages { /** the type of object `offset_pages` */ diff --git a/src/api/types/OpenConversationRequest.ts b/src/api/types/OpenConversationRequest.ts index 682699e3..b3e63714 100644 --- a/src/api/types/OpenConversationRequest.ts +++ b/src/api/types/OpenConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Payload of the request to open a conversation diff --git a/src/api/types/OperatorWorkflowEvent.ts b/src/api/types/OperatorWorkflowEvent.ts new file mode 100644 index 00000000..df8629d3 --- /dev/null +++ b/src/api/types/OperatorWorkflowEvent.ts @@ -0,0 +1,23 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains details about name of the workflow for conversation part type operator_workflow_event. + */ +export interface OperatorWorkflowEvent { + workflow?: OperatorWorkflowEvent.Workflow; + event?: OperatorWorkflowEvent.Event; +} + +export namespace OperatorWorkflowEvent { + export interface Workflow { + /** The name of the workflow */ + name?: string; + } + + export interface Event { + /** Type of the workflow event initiated */ + type?: string; + /** Result of the workflow event */ + result?: string; + } +} diff --git a/src/api/types/PagesLink.ts b/src/api/types/PagesLink.ts index 9f298e78..59d698ff 100644 --- a/src/api/types/PagesLink.ts +++ b/src/api/types/PagesLink.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The majority of list resources in the API are paginated to allow clients to traverse data over multiple requests. @@ -8,10 +6,10 @@ * Their responses are likely to contain a pages object that hosts pagination links which a client can use to paginate through the data without having to construct a query. The link relations for the pages field are as follows. */ export interface PagesLink { - type: "pages"; - page: number; + type?: "pages"; + page?: number; /** A link to the next page of results. A response that does not contain a next link does not have further data to fetch. */ next?: string; - per_page: number; - total_pages: number; + per_page?: number; + total_pages?: number; } diff --git a/src/api/types/PaginatedNewsItemResponse.ts b/src/api/types/PaginatedNewsItemResponse.ts deleted file mode 100644 index dcabdedc..00000000 --- a/src/api/types/PaginatedNewsItemResponse.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * Paginated News Item Response - */ -export interface PaginatedNewsItemResponse { - /** The type of object */ - type: "list"; - pages?: Intercom.CursorPages; - /** A count of the total number of News Items. */ - total_count: number; - /** An array of News Items */ - data: Intercom.NewsItem[]; -} diff --git a/src/api/types/PaginatedNewsfeedResponse.ts b/src/api/types/PaginatedNewsfeedResponse.ts deleted file mode 100644 index 92ded308..00000000 --- a/src/api/types/PaginatedNewsfeedResponse.ts +++ /dev/null @@ -1,18 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * Paginated Newsfeed Response - */ -export interface PaginatedNewsfeedResponse { - /** The type of object */ - type: "list"; - pages?: Intercom.CursorPages; - /** A count of the total number of Newsfeeds. */ - total_count: number; - /** An array of Newsfeeds */ - data: Intercom.Newsfeed[]; -} diff --git a/src/api/types/PaginatedResponse.ts b/src/api/types/PaginatedResponse.ts new file mode 100644 index 00000000..320b646d --- /dev/null +++ b/src/api/types/PaginatedResponse.ts @@ -0,0 +1,25 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; + +/** + * Paginated Response + */ +export interface PaginatedResponse { + /** The type of object */ + type?: PaginatedResponse.Type; + pages?: Intercom.CursorPages; + /** A count of the total number of objects. */ + total_count?: number; + /** An array of Objects */ + data?: Intercom.PaginatedResponseDataItem[]; +} + +export namespace PaginatedResponse { + /** The type of object */ + export const Type = { + List: "list", + ConversationList: "conversation.list", + } as const; + export type Type = (typeof Type)[keyof typeof Type]; +} diff --git a/src/api/types/PaginatedResponseDataItem.ts b/src/api/types/PaginatedResponseDataItem.ts new file mode 100644 index 00000000..4aec3d71 --- /dev/null +++ b/src/api/types/PaginatedResponseDataItem.ts @@ -0,0 +1,17 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; + +export type PaginatedResponseDataItem = + | Intercom.PaginatedResponseDataItem.NewsItem + | Intercom.PaginatedResponseDataItem.Newsfeed; + +export namespace PaginatedResponseDataItem { + export interface NewsItem extends Intercom.NewsItem { + type: "news-item"; + } + + export interface Newsfeed extends Intercom.Newsfeed { + type: "newsfeed"; + } +} diff --git a/src/api/types/PartAttachment.ts b/src/api/types/PartAttachment.ts index e87f566e..3c01b778 100644 --- a/src/api/types/PartAttachment.ts +++ b/src/api/types/PartAttachment.ts @@ -1,23 +1,21 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The file attached to a part */ export interface PartAttachment { /** The type of attachment */ - type: string; + type?: string; /** The name of the attachment */ - name: string; + name?: string; /** The URL of the attachment */ - url: string; + url?: string; /** The content type of the attachment */ - content_type: string; + content_type?: string; /** The size of the attachment */ - filesize: number; + filesize?: number; /** The width of the attachment */ - width: number; + width?: number; /** The height of the attachment */ - height: number; + height?: number; } diff --git a/src/api/types/PhoneSwitch.ts b/src/api/types/PhoneSwitch.ts index 200aa121..5fbeb892 100644 --- a/src/api/types/PhoneSwitch.ts +++ b/src/api/types/PhoneSwitch.ts @@ -1,13 +1,11 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Phone Switch Response */ export interface PhoneSwitch { /** */ - type: "phone_call_redirect"; + type?: "phone_call_redirect"; /** Phone number in E.164 format, that has received the SMS to continue the conversation in the Messenger. */ - phone: string; + phone?: string; } diff --git a/src/api/types/QuickReplyOption.ts b/src/api/types/QuickReplyOption.ts new file mode 100644 index 00000000..8de2d400 --- /dev/null +++ b/src/api/types/QuickReplyOption.ts @@ -0,0 +1,8 @@ +// This file was auto-generated by Fern from our API Definition. + +export interface QuickReplyOption { + /** The text to display in this quick reply option. */ + text: string; + /** A unique identifier for this quick reply option. This value will be available within the metadata of the comment conversation part that is created when a user clicks on this reply option. */ + uuid: string; +} diff --git a/src/api/types/Recipient.ts b/src/api/types/Recipient.ts new file mode 100644 index 00000000..194d11d0 --- /dev/null +++ b/src/api/types/Recipient.ts @@ -0,0 +1,20 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * A recipient of a message + */ +export interface Recipient { + /** The role associated to the contact - `user` or `lead`. */ + type: Recipient.Type; + /** The identifier for the contact which is given by Intercom. */ + id: string; +} + +export namespace Recipient { + /** The role associated to the contact - `user` or `lead`. */ + export const Type = { + User: "user", + Lead: "lead", + } as const; + export type Type = (typeof Type)[keyof typeof Type]; +} diff --git a/src/api/types/RedactConversationRequest.ts b/src/api/types/RedactConversationRequest.ts index 521b8ca3..08d784b4 100644 --- a/src/api/types/RedactConversationRequest.ts +++ b/src/api/types/RedactConversationRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; export type RedactConversationRequest = /** diff --git a/src/api/types/Reference.ts b/src/api/types/Reference.ts index 708375f6..7c9c82a3 100644 --- a/src/api/types/Reference.ts +++ b/src/api/types/Reference.ts @@ -1,13 +1,11 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * reference to another object */ export interface Reference { /** */ - type: string; + type?: string; /** */ id?: string; } diff --git a/src/api/types/ReplyConversationRequest.ts b/src/api/types/ReplyConversationRequest.ts index 47e84c5d..113e344e 100644 --- a/src/api/types/ReplyConversationRequest.ts +++ b/src/api/types/ReplyConversationRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; export type ReplyConversationRequest = | Intercom.ContactReplyConversationRequest diff --git a/src/api/types/ResultsResponse.ts b/src/api/types/ResultsResponse.ts deleted file mode 100644 index 118b3e37..00000000 --- a/src/api/types/ResultsResponse.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * The results object should be sent when you want to end configuration of the app and trigger the [Initialize request](https://developers.intercom.com/docs/canvas-kit/#initialize) to be sent. You provide the key-value pairs of data you want access to and we will send these in the Initialize request within a [card_creation_options object](https://developers.intercom.com/docs/references/canvas-kit/requestobjects/card-creation-options/#card-creation-options). - */ -export interface ResultsResponse { - /** Key-value pairs of data you want access to in the Initialize request */ - results: Record; -} diff --git a/src/api/types/SearchRequest.ts b/src/api/types/SearchRequest.ts index 75ca8744..be8ae5af 100644 --- a/src/api/types/SearchRequest.ts +++ b/src/api/types/SearchRequest.ts @@ -1,8 +1,6 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Search using Intercoms Search APIs. diff --git a/src/api/types/SegmentList.ts b/src/api/types/SegmentList.ts index 3c5636cf..cb3efe41 100644 --- a/src/api/types/SegmentList.ts +++ b/src/api/types/SegmentList.ts @@ -1,17 +1,15 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * This will return a list of Segment Objects. The result may also have a pages object if the response is paginated. */ export interface SegmentList { /** The type of the object */ - type: "segment.list"; + type?: "segment.list"; /** A list of Segment objects */ - segments: Intercom.Segment[]; + segments?: Intercom.Segment[]; /** A pagination object, which may be empty, indicating no further pages to fetch. */ pages?: Record; } diff --git a/src/api/types/SheetActionComponent.ts b/src/api/types/SheetActionComponent.ts deleted file mode 100644 index 655b7039..00000000 --- a/src/api/types/SheetActionComponent.ts +++ /dev/null @@ -1,13 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A sheet action opens the link you give within the Messenger as an embedded iframe. - * - * [More on how Sheets work is in our Canvas Kit documentation.](https://developers.intercom.com/docs/canvas-kit#sheets-optional) - */ -export interface SheetActionComponent { - /** The link which hosts your sheet. */ - url: string; -} diff --git a/src/api/types/SingleFilterSearchRequest.ts b/src/api/types/SingleFilterSearchRequest.ts index 94aa9dfc..b51eb1a2 100644 --- a/src/api/types/SingleFilterSearchRequest.ts +++ b/src/api/types/SingleFilterSearchRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Search using Intercoms Search APIs with a single filter. @@ -15,10 +13,7 @@ export interface SingleFilterSearchRequest { } export namespace SingleFilterSearchRequest { - /** - * The accepted operators you can use to define how you want to search for the value. - */ - export type Operator = "=" | "!=" | "IN" | "NIN" | "<" | ">" | "~" | "!~" | "^" | "$"; + /** The accepted operators you can use to define how you want to search for the value. */ export const Operator = { Equals: "=", NotEquals: "!=", @@ -31,8 +26,9 @@ export namespace SingleFilterSearchRequest { StartsWith: "^", EndsWith: "$", } as const; + export type Operator = (typeof Operator)[keyof typeof Operator]; /** * The value that you want to search on. */ - export type Value = string | number | string[] | number[]; + export type Value = string | number | (string | number)[]; } diff --git a/src/api/types/SingleSelectComponent.ts b/src/api/types/SingleSelectComponent.ts deleted file mode 100644 index 04f9cf85..00000000 --- a/src/api/types/SingleSelectComponent.ts +++ /dev/null @@ -1,42 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * A single-select component is used to capture a choice from up to 10 options that you provide. You can submit the value of the select option by: - * - * - Adding an `action` to the single-select component - * - Using a ButtonComponent (which will submit all interactive components in the canvas) - * - * When a submit action takes place, the results are given in a hash with the `id` from the single-select component used as the key and the `id` from the chosen option as the value. - */ -export interface SingleSelectComponent { - /** A unique identifier for the component. */ - id: string; - /** The list of options. Can provide 2 to 10. */ - options: Intercom.SingleSelectOption[]; - /** The text shown above the options. */ - label?: string; - /** The option that is selected by default. */ - value?: string; - /** Styles the input. Default is `unsaved`. Prevent action with `saved`. */ - save_state?: SingleSelectComponent.SaveState; - /** Styles all options and prevents the action. Default is false. Will be overridden if save_state is saved. */ - disabled?: boolean; - /** This can be a Submit Action, URL Action, or Sheets Action. */ - action?: Intercom.ActionComponent; -} - -export namespace SingleSelectComponent { - /** - * Styles the input. Default is `unsaved`. Prevent action with `saved`. - */ - export type SaveState = "unsaved" | "saved" | "failed"; - export const SaveState = { - Unsaved: "unsaved", - Saved: "saved", - Failed: "failed", - } as const; -} diff --git a/src/api/types/SingleSelectOption.ts b/src/api/types/SingleSelectOption.ts deleted file mode 100644 index 4fc06e87..00000000 --- a/src/api/types/SingleSelectOption.ts +++ /dev/null @@ -1,17 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A single select option component that can be selected. - */ -export interface SingleSelectOption { - /** The type of component you are rendering. */ - type: "option"; - /** A unique identifier for the option. */ - id: string; - /** The text shown within this option. */ - text: string; - /** Styles the option and prevents the action. Default is false. */ - disabled?: boolean; -} diff --git a/src/api/types/SlaApplied.ts b/src/api/types/SlaApplied.ts index 086c6c17..3ea77f62 100644 --- a/src/api/types/SlaApplied.ts +++ b/src/api/types/SlaApplied.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The SLA Applied object contains the details for which SLA has been applied to this conversation. @@ -8,16 +6,16 @@ */ export interface SlaApplied { /** object type */ - type: string; + type?: string; /** The name of the SLA as given by the teammate when it was created. */ - sla_name: string; + sla_name?: string; /** * SLA statuses: * - `hit`: If there’s at least one hit event in the underlying sla_events table, and no “missed” or “canceled” events for the conversation. * - `missed`: If there are any missed sla_events for the conversation and no canceled events. If there’s even a single missed sla event, the status will always be missed. A missed status is not applied when the SLA expires, only the next time a teammate replies. * - `active`: An SLA has been applied to a conversation, but has not yet been fulfilled. SLA status is active only if there are no “hit, “missed”, or “canceled” events. */ - sla_status: SlaApplied.SlaStatus; + sla_status?: SlaApplied.SlaStatus; } export namespace SlaApplied { @@ -27,11 +25,11 @@ export namespace SlaApplied { * - `missed`: If there are any missed sla_events for the conversation and no canceled events. If there’s even a single missed sla event, the status will always be missed. A missed status is not applied when the SLA expires, only the next time a teammate replies. * - `active`: An SLA has been applied to a conversation, but has not yet been fulfilled. SLA status is active only if there are no “hit, “missed”, or “canceled” events. */ - export type SlaStatus = "hit" | "missed" | "cancelled" | "active"; export const SlaStatus = { Hit: "hit", Missed: "missed", Cancelled: "cancelled", Active: "active", } as const; + export type SlaStatus = (typeof SlaStatus)[keyof typeof SlaStatus]; } diff --git a/src/api/types/SnoozeConversationRequest.ts b/src/api/types/SnoozeConversationRequest.ts index 25429753..7e3e7061 100644 --- a/src/api/types/SnoozeConversationRequest.ts +++ b/src/api/types/SnoozeConversationRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Payload of the request to snooze a conversation diff --git a/src/api/types/SocialProfile.ts b/src/api/types/SocialProfile.ts index 90befe00..78030405 100644 --- a/src/api/types/SocialProfile.ts +++ b/src/api/types/SocialProfile.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A Social Profile allows you to label your contacts, companies, and conversations and list them using that Social Profile. */ export interface SocialProfile { /** value is "social_profile" */ - type: "social_profile"; + type?: "social_profile"; /** The name of the Social media profile */ - name: string; + name?: string; /** The name of the Social media profile */ - url: string; + url?: string; } diff --git a/src/api/types/SpacerComponent.ts b/src/api/types/SpacerComponent.ts deleted file mode 100644 index d8215aa3..00000000 --- a/src/api/types/SpacerComponent.ts +++ /dev/null @@ -1,27 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A spacer component is used to create empty space between components. - */ -export interface SpacerComponent { - /** A unique identifier for the component. */ - id?: string; - /** The amount of space between components. Default is `s`. */ - size?: SpacerComponent.Size; -} - -export namespace SpacerComponent { - /** - * The amount of space between components. Default is `s`. - */ - export type Size = "xs" | "s" | "m" | "l" | "xl"; - export const Size = { - Xs: "xs", - S: "s", - M: "m", - L: "l", - Xl: "xl", - } as const; -} diff --git a/src/api/types/StartingAfterPaging.ts b/src/api/types/StartingAfterPaging.ts index df4feb10..6fc82b73 100644 --- a/src/api/types/StartingAfterPaging.ts +++ b/src/api/types/StartingAfterPaging.ts @@ -1,10 +1,8 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export interface StartingAfterPaging { /** The number of results to fetch per page. */ - per_page: number; + per_page?: number; /** The cursor to use in the next request to get the next page of results. */ starting_after?: string; } diff --git a/src/api/types/SubmitActionComponent.ts b/src/api/types/SubmitActionComponent.ts deleted file mode 100644 index c1eec8c9..00000000 --- a/src/api/types/SubmitActionComponent.ts +++ /dev/null @@ -1,8 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A submit action triggers a [Submit Request](https://developers.intercom.com/docs/canvas-kit#submit-request) to be sent. This request will include all values which have been entered into all the interactive components on the current canvas. - */ -export interface SubmitActionComponent {} diff --git a/src/api/types/SubmitRequest.ts b/src/api/types/SubmitRequest.ts deleted file mode 100644 index 38aa3f2c..00000000 --- a/src/api/types/SubmitRequest.ts +++ /dev/null @@ -1,31 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * The Submit request is triggered when a component with a submit action is interacted with in Messenger Inbox. - */ -export interface SubmitRequest { - /** The workspace ID of the teammate. Attribute is `app_id` for V1.2 and below. */ - workspace_id: string; - /** The Intercom hosted region that this app is located in. */ - workspace_region: string; - /** The Intercom teammate viewing the conversation. */ - admin: Intercom.Admin; - /** The id of the component clicked by the teammate to trigger the request. */ - component_id: string; - /** The context of where the app is added, where the user last visited, and information on the Messenger settings. */ - context: Intercom.Context; - /** The conversation where your app is being shown. */ - conversation: Intercom.Conversation; - /** The current canvas the teammate can see. */ - current_canvas: Intercom.CurrentCanvas; - /** The contact which is currently being viewed by the teammate in the conversation details panel. */ - contact: Intercom.Contact; - /** A list of key/value pairs of data, inputted by the teammate on the current canvas. */ - input_values: Record; - /** The user who took the action. */ - user: Intercom.Contact; -} diff --git a/src/api/types/SubmitResponse.ts b/src/api/types/SubmitResponse.ts deleted file mode 100644 index 9e2ff974..00000000 --- a/src/api/types/SubmitResponse.ts +++ /dev/null @@ -1,25 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as Intercom from "../index"; - -/** - * The response object returned when submitting an app interaction. This will replace the previous canvas that was visible until the app was interacted with. - * - * You can optionally provide an event object with the attribute `type` given as `completed` to tell us if the app has completed its purpose. For example, an email collector app would be complete when the end-user submits their email address. - * - * Apps in conversation details can also optionally insert an app into the conversation reply: - * - * 1. You respond with a card_creation_options object (https://developers.intercom.com/canvas-kit-reference/reference/card-creation-options) - * 2. We send a request to the initialize URL for Messenger capabilities (https://developers.intercom.com/docs/build-an-integration/getting-started/build-an-app-for-your-messenger/request-flows) with the card_creation_options object present - * 3. You respond with a canvas object with the components you want to insert into the conversation reply - */ -export interface SubmitResponse { - /** The canvas object that defines the new UI to be shown. */ - canvas: Intercom.CanvasObject; - /** Optional. Key-value pairs that will be sent in the initialize request to insert an app into the conversation reply. */ - card_creation_options?: Record; - /** Optional. Indicates if the app has completed its purpose. */ - event?: Intercom.Event; -} diff --git a/src/api/types/SubscriptionTypeList.ts b/src/api/types/SubscriptionTypeList.ts index 39b5ec38..134688b1 100644 --- a/src/api/types/SubscriptionTypeList.ts +++ b/src/api/types/SubscriptionTypeList.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A list of subscription type objects. */ export interface SubscriptionTypeList { /** The type of the object */ - type: "list"; + type?: "list"; /** A list of subscription type objects associated with the workspace . */ - data: Intercom.SubscriptionType[]; + data?: Intercom.SubscriptionType[]; } diff --git a/src/api/types/TagCompanyRequest.ts b/src/api/types/TagCompanyRequest.ts index 23231949..4f4affb5 100644 --- a/src/api/types/TagCompanyRequest.ts +++ b/src/api/types/TagCompanyRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * You can tag a single company or a list of companies. diff --git a/src/api/types/TagList.ts b/src/api/types/TagList.ts index 4e658c56..54b9506c 100644 --- a/src/api/types/TagList.ts +++ b/src/api/types/TagList.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A list of tags objects in the workspace. */ export interface TagList { /** The type of the object */ - type: "list"; + type?: "list"; /** A list of tags objects associated with the workspace . */ - data: Intercom.Tag[]; + data?: Intercom.Tag[]; } diff --git a/src/api/types/TagMultipleUsersRequest.ts b/src/api/types/TagMultipleUsersRequest.ts index df2f72b2..fc697987 100644 --- a/src/api/types/TagMultipleUsersRequest.ts +++ b/src/api/types/TagMultipleUsersRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * You can tag a list of users. diff --git a/src/api/types/Tags.ts b/src/api/types/Tags.ts index b1257d7d..0d3680ce 100644 --- a/src/api/types/Tags.ts +++ b/src/api/types/Tags.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A list of tags objects associated with a conversation */ export interface Tags { /** The type of the object */ - type: "tag.list"; + type?: "tag.list"; /** A list of tags objects associated with the conversation. */ - tags: Intercom.Tag[]; + tags?: Intercom.Tag[]; } diff --git a/src/api/types/TeamList.ts b/src/api/types/TeamList.ts index b7833bf3..def5cbe1 100644 --- a/src/api/types/TeamList.ts +++ b/src/api/types/TeamList.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * This will return a list of team objects for the App. */ export interface TeamList { /** The type of the object */ - type: "team.list"; + type?: "team.list"; /** A list of team objects */ - teams: Intercom.Team[]; + teams?: Intercom.Team[]; } diff --git a/src/api/types/TeamPriorityLevel.ts b/src/api/types/TeamPriorityLevel.ts index b979fa1d..07d6bae5 100644 --- a/src/api/types/TeamPriorityLevel.ts +++ b/src/api/types/TeamPriorityLevel.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Admin priority levels for teams diff --git a/src/api/types/TextAreaComponent.ts b/src/api/types/TextAreaComponent.ts deleted file mode 100644 index 1a2d215c..00000000 --- a/src/api/types/TextAreaComponent.ts +++ /dev/null @@ -1,23 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A text area component is used to capture a large amount of text as input with a multi-line text box. You can submit the value of the text area by: - * - * - Using a ButtonComponent (which will submit all interactive components in the canvas) - */ -export interface TextAreaComponent { - /** A unique identifier for the component. */ - id: string; - /** The text shown above the text area. */ - label?: string; - /** An example value shown inside the component when it's empty. */ - placeholder?: string; - /** An entered value which is already inside the component. */ - value?: string; - /** Styles the input as failed. Default is false. */ - error?: boolean; - /** Styles the input and prevents the action. Default is false. */ - disabled?: boolean; -} diff --git a/src/api/types/TextComponent.ts b/src/api/types/TextComponent.ts deleted file mode 100644 index 1fe6bce2..00000000 --- a/src/api/types/TextComponent.ts +++ /dev/null @@ -1,41 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A text component is used for rendering blocks of text. Links and bold font can be rendered through Markdown. There are different styles provided which edit the color, weight, and font size. These cannot be edited through Markdown. - */ -export interface TextComponent { - /** A unique identifier for the component. */ - id?: string; - /** The text that will be rendered. */ - text: string; - /** Aligns the text. Default is `left`. */ - align?: TextComponent.Align; - /** Styles the text. Default is `paragraph`. */ - style?: TextComponent.Style; - /** Disables a component's margin-bottom of 10px. */ - bottom_margin?: "none"; -} - -export namespace TextComponent { - /** - * Aligns the text. Default is `left`. - */ - export type Align = "left" | "center" | "right"; - export const Align = { - Left: "left", - Center: "center", - Right: "right", - } as const; - /** - * Styles the text. Default is `paragraph`. - */ - export type Style = "header" | "paragraph" | "muted" | "error"; - export const Style = { - Header: "header", - Paragraph: "paragraph", - Muted: "muted", - Error: "error", - } as const; -} diff --git a/src/api/types/TicketCustomAttributes.ts b/src/api/types/TicketCustomAttributes.ts index fe9181ea..2596f28b 100644 --- a/src/api/types/TicketCustomAttributes.ts +++ b/src/api/types/TicketCustomAttributes.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * An object containing the different attributes associated to the ticket as key-value pairs. For the default title and description attributes, the keys are `_default_title_` and `_default_description_`. diff --git a/src/api/types/TicketList.ts b/src/api/types/TicketList.ts index 5cfdf4fe..e512f129 100644 --- a/src/api/types/TicketList.ts +++ b/src/api/types/TicketList.ts @@ -1,18 +1,16 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Tickets are how you track requests from your users. */ export interface TicketList { /** Always ticket.list */ - type: "ticket.list"; + type?: "ticket.list"; /** The list of ticket objects */ - tickets: Intercom.Ticket[]; + tickets?: (Intercom.Ticket | undefined)[]; /** A count of the total number of objects. */ - total_count: number; + total_count?: number; pages?: Intercom.CursorPages; } diff --git a/src/api/types/TicketPartAuthor.ts b/src/api/types/TicketPartAuthor.ts index c09f0739..e0ea7ff3 100644 --- a/src/api/types/TicketPartAuthor.ts +++ b/src/api/types/TicketPartAuthor.ts @@ -1,30 +1,26 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The author that wrote or triggered the part. Can be a bot, admin, team or user. */ export interface TicketPartAuthor { /** The type of the author */ - type: TicketPartAuthor.Type; + type?: TicketPartAuthor.Type; /** The id of the author */ - id: string; + id?: string; /** The name of the author */ name?: string; /** The email of the author */ - email: string; + email?: string; } export namespace TicketPartAuthor { - /** - * The type of the author - */ - export type Type = "admin" | "bot" | "team" | "user"; + /** The type of the author */ export const Type = { Admin: "admin", Bot: "bot", Team: "team", User: "user", } as const; + export type Type = (typeof Type)[keyof typeof Type]; } diff --git a/src/api/types/TicketParts.ts b/src/api/types/TicketParts.ts index f6d4ee25..9ff75bbe 100644 --- a/src/api/types/TicketParts.ts +++ b/src/api/types/TicketParts.ts @@ -1,17 +1,15 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A list of Ticket Part objects for each note and event in the ticket. There is a limit of 500 parts. */ export interface TicketParts { /** */ - type: "ticket_part.list"; + type?: "ticket_part.list"; /** A list of Ticket Part objects for each ticket. There is a limit of 500 parts. */ - ticket_parts: Intercom.TicketPart[]; + ticket_parts?: Intercom.TicketPart[]; /** */ - total_count: number; + total_count?: number; } diff --git a/src/api/types/TicketReply.ts b/src/api/types/TicketReply.ts index 7c3b7f11..f86b2ef4 100644 --- a/src/api/types/TicketReply.ts +++ b/src/api/types/TicketReply.ts @@ -1,23 +1,21 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A Ticket Part representing a note, comment, or quick_reply on a ticket */ export interface TicketReply { /** Always ticket_part */ - type: "ticket_part"; + type?: "ticket_part"; /** The id representing the part. */ - id: string; + id?: string; /** Type of the part */ - part_type: TicketReply.PartType; + part_type?: TicketReply.PartType; /** The message body, which may contain HTML. */ body?: string; /** The time the note was created. */ - created_at: number; + created_at?: number; /** The last time the note was updated. */ updated_at?: number; author?: Intercom.TicketPartAuthor; @@ -28,13 +26,11 @@ export interface TicketReply { } export namespace TicketReply { - /** - * Type of the part - */ - export type PartType = "note" | "comment" | "quick_reply"; + /** Type of the part */ export const PartType = { Note: "note", Comment: "comment", QuickReply: "quick_reply", } as const; + export type PartType = (typeof PartType)[keyof typeof PartType]; } diff --git a/src/api/types/TicketRequestCustomAttributes.ts b/src/api/types/TicketRequestCustomAttributes.ts index ce59bc75..f8cce5a3 100644 --- a/src/api/types/TicketRequestCustomAttributes.ts +++ b/src/api/types/TicketRequestCustomAttributes.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * The attributes set on the ticket. When setting the default title and description attributes, the attribute keys that should be used are `_default_title_` and `_default_description_`. When setting ticket type attributes of the list attribute type, the key should be the attribute name and the value of the attribute should be the list item id, obtainable by [listing the ticket type](ref:get_ticket-types). For example, if the ticket type has an attribute called `priority` of type `list`, the key should be `priority` and the value of the attribute should be the guid of the list item (e.g. `de1825a0-0164-4070-8ca6-13e22462fa7e`). diff --git a/src/api/types/TicketStateList.ts b/src/api/types/TicketStateList.ts new file mode 100644 index 00000000..ac2fbc51 --- /dev/null +++ b/src/api/types/TicketStateList.ts @@ -0,0 +1,13 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../index.js"; + +/** + * A list of ticket states associated with a given ticket type. + */ +export interface TicketStateList { + /** String representing the object's type. Always has the value `list`. */ + type?: string; + /** A list of ticket states associated with a given ticket type. */ + data?: (Intercom.TicketStateDetailed | undefined)[]; +} diff --git a/src/api/types/TicketTypeAttribute.ts b/src/api/types/TicketTypeAttribute.ts index a0267806..855266f6 100644 --- a/src/api/types/TicketTypeAttribute.ts +++ b/src/api/types/TicketTypeAttribute.ts @@ -1,52 +1,47 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Ticket type attribute, used to define each data field to be captured in a ticket. */ export interface TicketTypeAttribute { /** String representing the object's type. Always has the value `ticket_type_attribute`. */ - type: "ticket_type_attribute"; + type?: string; /** The id representing the ticket type attribute. */ - id: string; + id?: string; /** The id of the workspace that the ticket type attribute belongs to. */ - workspace_id: string; + workspace_id?: string; /** The name of the ticket type attribute */ - name: string; + name?: string; /** The description of the ticket type attribute */ - description: string; + description?: string; /** The type of the data attribute (allowed values: "string list integer decimal boolean datetime files") */ - data_type: TicketTypeAttribute.DataType; + data_type?: TicketTypeAttribute.DataType; /** Input options for the attribute */ - input_options: Record; + input_options?: Record; /** The order of the attribute against other attributes */ - order: number; + order?: number; /** Whether the attribute is required or not for teammates. */ - required_to_create: boolean; + required_to_create?: boolean; /** Whether the attribute is required or not for contacts. */ - required_to_create_for_contacts: boolean; + required_to_create_for_contacts?: boolean; /** Whether the attribute is visible or not to teammates. */ - visible_on_create: boolean; + visible_on_create?: boolean; /** Whether the attribute is visible or not to contacts. */ - visible_to_contacts: boolean; + visible_to_contacts?: boolean; /** Whether the attribute is built in or not. */ - default: boolean; + default?: boolean; /** The id of the ticket type that the attribute belongs to. */ - ticket_type_id: number; + ticket_type_id?: number; /** Whether the ticket type attribute is archived or not. */ - archived: boolean; + archived?: boolean; /** The date and time the ticket type attribute was created. */ - created_at: number; + created_at?: number; /** The date and time the ticket type attribute was last updated. */ updated_at?: number; } export namespace TicketTypeAttribute { - /** - * The type of the data attribute (allowed values: "string list integer decimal boolean datetime files") - */ - export type DataType = "string" | "list" | "integer" | "decimal" | "boolean" | "datetime" | "files"; + /** The type of the data attribute (allowed values: "string list integer decimal boolean datetime files") */ export const DataType = { String: "string", List: "list", @@ -56,4 +51,5 @@ export namespace TicketTypeAttribute { Datetime: "datetime", Files: "files", } as const; + export type DataType = (typeof DataType)[keyof typeof DataType]; } diff --git a/src/api/types/TicketTypeAttributeList.ts b/src/api/types/TicketTypeAttributeList.ts index 011e3cc2..6a9b00dc 100644 --- a/src/api/types/TicketTypeAttributeList.ts +++ b/src/api/types/TicketTypeAttributeList.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A list of attributes associated with a given ticket type. */ export interface TicketTypeAttributeList { /** String representing the object's type. Always has the value `ticket_type_attributes.list`. */ - type: "ticket_type_attributes.list"; + type?: string; /** A list of ticket type attributes associated with a given ticket type. */ - ticket_type_attributes: Intercom.TicketTypeAttribute[]; + ticket_type_attributes?: (Intercom.TicketTypeAttribute | undefined)[]; } diff --git a/src/api/types/TicketTypeList.ts b/src/api/types/TicketTypeList.ts index 3a4d2b86..d76acea8 100644 --- a/src/api/types/TicketTypeList.ts +++ b/src/api/types/TicketTypeList.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * A list of ticket types associated with a given workspace. */ export interface TicketTypeList { - /** String representing the object's type. Always has the value `ticket_type.list`. */ - type: "ticket_type_attributes.list"; + /** String representing the object's type. Always has the value `list`. */ + type?: string; /** A list of ticket_types associated with a given workspace. */ - ticket_types: Intercom.TicketType[]; + data?: (Intercom.TicketType | undefined)[]; } diff --git a/src/api/types/Translation.ts b/src/api/types/Translation.ts index 19b73881..3d656a16 100644 --- a/src/api/types/Translation.ts +++ b/src/api/types/Translation.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * A translation object contains the localised details of a subscription type. */ export interface Translation { /** The localised name of the subscription type. */ - name: string; + name?: string; /** The localised description of the subscription type. */ - description: string; + description?: string; /** The two character identifier for the language of the translation object. */ - locale: string; + locale?: string; } diff --git a/src/api/types/UntagCompanyRequest.ts b/src/api/types/UntagCompanyRequest.ts index dd179dde..09886bd1 100644 --- a/src/api/types/UntagCompanyRequest.ts +++ b/src/api/types/UntagCompanyRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * You can tag a single company or a list of companies. @@ -18,11 +16,11 @@ export namespace UntagCompanyRequest { export namespace Companies { export interface Item { /** The Intercom defined id representing the company. */ - id: string; + id?: string; /** The company id you have defined for the company. */ - company_id: string; + company_id?: string; /** Always set to true */ - untag: true; + untag?: boolean; } } } diff --git a/src/api/types/UpdateArticleRequestBody.ts b/src/api/types/UpdateArticleRequestBody.ts new file mode 100644 index 00000000..3a5100b8 --- /dev/null +++ b/src/api/types/UpdateArticleRequestBody.ts @@ -0,0 +1,13 @@ +// This file was auto-generated by Fern from our API Definition. + +export interface UpdateArticleRequestBody { + parent_type?: UpdateArticleRequestBody.ParentType; +} + +export namespace UpdateArticleRequestBody { + export const ParentType = { + Collection: "collection", + Section: "section", + } as const; + export type ParentType = (typeof ParentType)[keyof typeof ParentType]; +} diff --git a/src/api/types/UpdateCompanyRequestBody.ts b/src/api/types/UpdateCompanyRequestBody.ts new file mode 100644 index 00000000..8949ca97 --- /dev/null +++ b/src/api/types/UpdateCompanyRequestBody.ts @@ -0,0 +1,21 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * You can update a Company + */ +export interface UpdateCompanyRequestBody { + /** The name of the Company */ + name?: string; + /** The name of the plan you have associated with the company. */ + plan?: string; + /** The number of employees in this company. */ + size?: number; + /** The URL for this company's website. Please note that the value specified here is not validated. Accepts any string. */ + website?: string; + /** The industry that this company operates in. */ + industry?: string; + /** A hash of key/value pairs containing any other data about the company you want Intercom to store. */ + custom_attributes?: Record; + /** How much revenue the company generates for your business. Note that this will truncate floats. i.e. it only allow for whole integers, 155.98 will be truncated to 155. Note that this has an upper limit of 2**31-1 or 2147483647.. */ + monthly_spend?: number; +} diff --git a/src/api/types/UpdateDataAttributeRequestBody.ts b/src/api/types/UpdateDataAttributeRequestBody.ts new file mode 100644 index 00000000..6524ae99 --- /dev/null +++ b/src/api/types/UpdateDataAttributeRequestBody.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * + */ +export type UpdateDataAttributeRequestBody = + | { + options: { + value?: string | undefined; + }[]; + } + | unknown; diff --git a/src/api/types/UpdateVisitorRequest.ts b/src/api/types/UpdateVisitorRequest.ts index a81aa7d3..349fd6b2 100644 --- a/src/api/types/UpdateVisitorRequest.ts +++ b/src/api/types/UpdateVisitorRequest.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Update an existing visitor. diff --git a/src/api/types/UpdateVisitorRequestOne.ts b/src/api/types/UpdateVisitorRequestOne.ts index 67858b8e..cfdac3c4 100644 --- a/src/api/types/UpdateVisitorRequestOne.ts +++ b/src/api/types/UpdateVisitorRequestOne.ts @@ -1,5 +1,3 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export type UpdateVisitorRequestOne = unknown; diff --git a/src/api/types/UrlActionComponent.ts b/src/api/types/UrlActionComponent.ts deleted file mode 100644 index 34d44dcf..00000000 --- a/src/api/types/UrlActionComponent.ts +++ /dev/null @@ -1,11 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -/** - * A URL action opens a given link in a new browser tab. - */ -export interface UrlActionComponent { - /** The link you want to open. */ - url: string; -} diff --git a/src/api/types/Visitor.ts b/src/api/types/Visitor.ts index 6865b074..195792a3 100644 --- a/src/api/types/Visitor.ts +++ b/src/api/types/Visitor.ts @@ -1,23 +1,21 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as Intercom from "../index"; +import type * as Intercom from "../index.js"; /** * Visitors are useful for representing anonymous people that have not yet been identified. They usually represent website visitors. Visitors are not visible in Intercom platform. The Visitors resource provides methods to fetch, update, convert and delete. */ export interface Visitor { /** Value is 'visitor' */ - type: "visitor"; + type?: "visitor"; /** The Intercom defined id representing the Visitor. */ - id: string; + id?: string; /** Automatically generated identifier for the Visitor. */ - user_id: string; + user_id?: string; /** Identifies if this visitor is anonymous. */ - anonymous: boolean; + anonymous?: boolean; /** The email of the visitor. */ - email: string; + email?: string; /** The phone number of the visitor. */ phone?: string; /** The name of the visitor. */ @@ -26,17 +24,17 @@ export interface Visitor { pseudonym?: string; avatar?: Visitor.Avatar; /** The id of the app the visitor is associated with. */ - app_id: string; + app_id?: string; companies?: Visitor.Companies; location_data?: Visitor.LocationData; /** The time the Lead last recorded making a request. */ las_request_at?: number; /** The time the Visitor was added to Intercom. */ - created_at: number; + created_at?: number; /** The time the Visitor was added to Intercom. */ remote_created_at?: number; /** The time the Visitor signed up for your product. */ - signed_up_at: number; + signed_up_at?: number; /** The last time the Visitor was updated. */ updated_at?: number; /** The number of sessions the Visitor has had. */ diff --git a/src/api/types/VisitorDeletedObject.ts b/src/api/types/VisitorDeletedObject.ts index 3195b30d..6a3cc196 100644 --- a/src/api/types/VisitorDeletedObject.ts +++ b/src/api/types/VisitorDeletedObject.ts @@ -1,15 +1,13 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** * Response returned when an object is deleted */ export interface VisitorDeletedObject { /** The unique identifier for the visitor which is given by Intercom. */ - id: string; + id?: string; /** The type of object which was deleted */ - type: "visitor"; + type?: "visitor"; /** Automatically generated identifier for the Visitor. */ - user_id: string; + user_id?: string; } diff --git a/src/api/types/WhatsappMessageStatusList.ts b/src/api/types/WhatsappMessageStatusList.ts new file mode 100644 index 00000000..b1d0e8d8 --- /dev/null +++ b/src/api/types/WhatsappMessageStatusList.ts @@ -0,0 +1,67 @@ +// This file was auto-generated by Fern from our API Definition. + +export interface WhatsappMessageStatusList { + type: "list"; + /** The provided ruleset ID */ + ruleset_id: string; + pages: WhatsappMessageStatusList.Pages; + /** Total number of events */ + total_count: number; + events: WhatsappMessageStatusList.Events.Item[]; +} + +export namespace WhatsappMessageStatusList { + export interface Pages { + type: "pages"; + /** Number of results per page */ + per_page: number; + /** Total number of pages */ + total_pages: number; + /** Information for fetching next page (null if no more pages) */ + next?: Pages.Next; + } + + export namespace Pages { + /** + * Information for fetching next page (null if no more pages) + */ + export interface Next { + /** Cursor for the next page */ + starting_after?: string; + } + } + + export type Events = Events.Item[]; + + export namespace Events { + export interface Item { + /** Event ID */ + id: string; + /** ID of the conversation */ + conversation_id: string; + /** Current status of the message */ + status: Item.Status; + /** Event type */ + type: "broadcast_outbound"; + /** Creation timestamp */ + created_at: number; + /** Last update timestamp */ + updated_at: number; + /** WhatsApp's message identifier */ + whatsapp_message_id: string; + /** Name of the WhatsApp template used */ + template_name?: string; + } + + export namespace Item { + /** Current status of the message */ + export const Status = { + Sent: "sent", + Delivered: "delivered", + Read: "read", + Failed: "failed", + } as const; + export type Status = (typeof Status)[keyof typeof Status]; + } + } +} diff --git a/src/api/types/index.ts b/src/api/types/index.ts index 2a4c1060..f81547cc 100644 --- a/src/api/types/index.ts +++ b/src/api/types/index.ts @@ -1,165 +1,162 @@ -export * from "./ActionComponent"; -export * from "./ActivityLog"; -export * from "./ActivityLogList"; -export * from "./ActivityLogMetadata"; -export * from "./AddressableList"; -export * from "./AdminList"; -export * from "./AdminPriorityLevel"; -export * from "./AdminReplyConversationRequest"; -export * from "./AdminReplyTicketRequest"; -export * from "./AdminWithApp"; -export * from "./App"; -export * from "./ArticleContent"; -export * from "./ArticleList"; -export * from "./ArticleStatistics"; -export * from "./ArticleTranslatedContent"; -export * from "./AssignConversationRequest"; -export * from "./ButtonComponent"; -export * from "./CanvasObject"; -export * from "./CheckboxOption"; -export * from "./CheckboxComponent"; -export * from "./CloseConversationRequest"; -export * from "./CollectionList"; -export * from "./CompanyAttachedContacts"; -export * from "./CompanyAttachedSegments"; -export * from "./CompanyList"; -export * from "./CompanyScroll"; -export * from "./Component"; -export * from "./ConfigureRequest"; -export * from "./ConfigureResponse"; -export * from "./ContactArchived"; -export * from "./ContactAttachedCompanies"; -export * from "./ContactCompanies"; -export * from "./ContactCompany"; -export * from "./ContactDeleted"; -export * from "./ContactList"; -export * from "./ContactLocation"; -export * from "./ContactNotes"; -export * from "./ContactReference"; -export * from "./ContactReplyBaseRequest"; -export * from "./ContactReplyConversationRequest"; -export * from "./ContactReplyEmailRequest"; -export * from "./ContactReplyIntercomUserIdRequest"; -export * from "./ContactReplyTicketEmailRequest"; -export * from "./ContactReplyTicketIntercomUserIdRequest"; -export * from "./ContactReplyTicketRequest"; -export * from "./ContactReplyTicketUserIdRequest"; -export * from "./ContactReplyUserIdRequest"; -export * from "./ContactSegments"; -export * from "./ContactSocialProfiles"; -export * from "./ContactSubscriptionTypes"; -export * from "./ContactTags"; -export * from "./ContactUnarchived"; -export * from "./ContentObject"; -export * from "./ContentSourcesList"; -export * from "./Context"; -export * from "./ConversationAttachmentFiles"; -export * from "./ConversationContacts"; -export * from "./ConversationFirstContactReply"; -export * from "./PaginatedConversationResponse"; -export * from "./ConversationPart"; -export * from "./ConversationPartAuthor"; -export * from "./ConversationParts"; -export * from "./ConversationRating"; -export * from "./ConversationSource"; -export * from "./ConversationStatistics"; -export * from "./ConversationTeammates"; -export * from "./CreateContactRequest"; -export * from "./CreateDataEventRequest"; -export * from "./CreateMessageRequest"; -export * from "./CreateOrUpdateTagRequest"; -export * from "./CreateTicketReplyWithCommentRequest"; -export * from "./CreateTicketRequest"; -export * from "./CurrentCanvas"; -export * from "./CursorPages"; -export * from "./CustomerRequest"; -export * from "./DataAttributeList"; -export * from "./DataEventList"; -export * from "./DataEventSummary"; -export * from "./DataEventSummaryItem"; -export * from "./DataExportCsv"; -export * from "./DataTableItem"; -export * from "./DataTableComponent"; -export * from "./DeletedArticleObject"; -export * from "./DeletedCollectionObject"; -export * from "./DeletedCompanyObject"; -export * from "./DeletedObject"; -export * from "./DividerComponent"; -export * from "./DropdownOption"; -export * from "./DropdownComponent"; -export * from "./Error_"; -export * from "./Event"; -export * from "./FileAttribute"; -export * from "./GroupContent"; -export * from "./GroupTranslatedContent"; -export * from "./ImageComponent"; -export * from "./InitializeRequest"; -export * from "./InitializeResponse"; -export * from "./InputComponent"; -export * from "./LinkedObject"; -export * from "./LinkedObjectList"; -export * from "./ListItem"; -export * from "./ListItemWithImage"; -export * from "./ListItemWithoutImage"; -export * from "./ListComponent"; -export * from "./LiveCanvasRequest"; -export * from "./LiveCanvasResponse"; -export * from "./MultipleOrSingleFilterSearchRequest"; -export * from "./MultipleFilterSearchRequest"; -export * from "./NewsItemRequest"; -export * from "./NoteList"; -export * from "./OpenConversationRequest"; -export * from "./PagesLink"; -export * from "./PaginatedNewsItemResponse"; -export * from "./PaginatedNewsfeedResponse"; -export * from "./PartAttachment"; -export * from "./PhoneSwitch"; -export * from "./RedactConversationRequest"; -export * from "./Reference"; -export * from "./ReplyConversationRequest"; -export * from "./ResultsResponse"; -export * from "./SearchRequest"; -export * from "./SegmentList"; -export * from "./SheetActionComponent"; -export * from "./SingleFilterSearchRequest"; -export * from "./SingleSelectOption"; -export * from "./SingleSelectComponent"; -export * from "./SlaApplied"; -export * from "./SnoozeConversationRequest"; -export * from "./SocialProfile"; -export * from "./SpacerComponent"; -export * from "./StartingAfterPaging"; -export * from "./SubmitActionComponent"; -export * from "./SubmitRequest"; -export * from "./SubmitResponse"; -export * from "./SubscriptionTypeList"; -export * from "./TagCompanyRequest"; -export * from "./TagList"; -export * from "./TagMultipleUsersRequest"; -export * from "./Tags"; -export * from "./TeamList"; -export * from "./TeamPriorityLevel"; -export * from "./TextComponent"; -export * from "./TextAreaComponent"; -export * from "./TicketCustomAttributes"; -export * from "./TicketList"; -export * from "./TicketPartAuthor"; -export * from "./TicketParts"; -export * from "./TicketReply"; -export * from "./TicketRequestCustomAttributes"; -export * from "./TicketTypeAttribute"; -export * from "./TicketTypeAttributeList"; -export * from "./TicketTypeList"; -export * from "./Translation"; -export * from "./UntagCompanyRequest"; -export * from "./UpdateVisitorRequest"; -export * from "./UrlActionComponent"; -export * from "./Visitor"; -export * from "./VisitorDeletedObject"; -export * from "./CustomAttributes"; -export * from "./OffsetPages"; -export * from "./CreateContactRequestTwo"; -export * from "./CreateDataEventRequestTwo"; -export * from "./CreateMessageRequestTwo"; -export * from "./Metadata"; -export * from "./UpdateVisitorRequestOne"; +export * from "./ActivityLog.js"; +export * from "./ActivityLogList.js"; +export * from "./ActivityLogMetadata.js"; +export * from "./AddressableList.js"; +export * from "./AdminList.js"; +export * from "./AdminPriorityLevel.js"; +export * from "./AdminReplyConversationRequest.js"; +export * from "./AdminReplyTicketRequest.js"; +export * from "./AdminWithApp.js"; +export * from "./App.js"; +export * from "./ArticleContent.js"; +export * from "./ArticleList.js"; +export * from "./ArticleStatistics.js"; +export * from "./ArticleTranslatedContent.js"; +export * from "./AssignConversationRequest.js"; +export * from "./AwayStatusReason.js"; +export * from "./CallList.js"; +export * from "./CloseConversationRequest.js"; +export * from "./CollectionList.js"; +export * from "./CompanyAttachedContacts.js"; +export * from "./CompanyAttachedSegments.js"; +export * from "./CompanyData.js"; +export * from "./CompanyList.js"; +export * from "./CompanyScroll.js"; +export * from "./ContactArchived.js"; +export * from "./ContactAttachedCompanies.js"; +export * from "./ContactBlocked.js"; +export * from "./ContactCompanies.js"; +export * from "./ContactDeleted.js"; +export * from "./ContactList.js"; +export * from "./ContactLocation.js"; +export * from "./ContactNotes.js"; +export * from "./ContactReference.js"; +export * from "./ContactReplyBaseRequest.js"; +export * from "./ContactReplyConversationRequest.js"; +export * from "./ContactReplyEmailRequest.js"; +export * from "./ContactReplyIntercomUserIdRequest.js"; +export * from "./ContactReplyTicketEmailRequest.js"; +export * from "./ContactReplyTicketIntercomUserIdRequest.js"; +export * from "./ContactReplyTicketRequest.js"; +export * from "./ContactReplyTicketUserIdRequest.js"; +export * from "./ContactReplyUserIdRequest.js"; +export * from "./ContactSegments.js"; +export * from "./ContactSocialProfiles.js"; +export * from "./ContactSubscriptionTypes.js"; +export * from "./ContactTags.js"; +export * from "./ContactUnarchived.js"; +export * from "./ContentSourcesList.js"; +export * from "./ConversationAttachmentFiles.js"; +export * from "./ConversationAttributeUpdatedByAdmin.js"; +export * from "./ConversationAttributeUpdatedByWorkflow.js"; +export * from "./ConversationContacts.js"; +export * from "./ConversationDeleted.js"; +export * from "./ConversationFirstContactReply.js"; +export * from "./ConversationList.js"; +export * from "./ConversationPart.js"; +export * from "./ConversationPartAuthor.js"; +export * from "./ConversationPartMetadata.js"; +export * from "./ConversationParts.js"; +export * from "./ConversationRating.js"; +export * from "./ConversationResponseTime.js"; +export * from "./ConversationSource.js"; +export * from "./ConversationStatistics.js"; +export * from "./ConversationTeammates.js"; +export * from "./CreateArticleRequest.js"; +export * from "./CreateContactRequest.js"; +export * from "./CreateContactRequestTwo.js"; +export * from "./CreateDataAttributeRequest.js"; +export * from "./CreateDataEventRequest.js"; +export * from "./CreateDataEventRequestTwo.js"; +export * from "./CreateInternalArticleRequest.js"; +export * from "./CreateMessageRequest.js"; +export * from "./CreateOrUpdateCompanyRequest.js"; +export * from "./CreateOrUpdateTagRequest.js"; +export * from "./CreatePhoneSwitchRequest.js"; +export * from "./CreateTicketReplyWithCommentRequest.js"; +export * from "./CreateTicketRequestBody.js"; +export * from "./CreateTicketTypeRequest.js"; +export * from "./CursorPages.js"; +export * from "./CustomActionFinished.js"; +export * from "./CustomActionStarted.js"; +export * from "./CustomAttributes.js"; +export * from "./CustomChannelAttribute.js"; +export * from "./CustomChannelBaseEvent.js"; +export * from "./CustomChannelContact.js"; +export * from "./CustomChannelNotificationResponse.js"; +export * from "./CustomerRequest.js"; +export * from "./CustomObjectInstanceDeleted.js"; +export * from "./CustomObjectInstanceList.js"; +export * from "./DataAttributeList.js"; +export * from "./DataEventList.js"; +export * from "./DataEventSummary.js"; +export * from "./DataEventSummaryItem.js"; +export * from "./DataExportCsv.js"; +export * from "./Datetime.js"; +export * from "./DeletedArticleObject.js"; +export * from "./DeletedCollectionObject.js"; +export * from "./DeletedCompanyObject.js"; +export * from "./DeletedInternalArticleObject.js"; +export * from "./DeletedObject.js"; +export * from "./EmailAddressHeader.js"; +export * from "./EmailMessageMetadata.js"; +export * from "./Error_.js"; +export * from "./EventDetails.js"; +export * from "./FileAttribute.js"; +export * from "./GroupContent.js"; +export * from "./GroupTranslatedContent.js"; +export * from "./InternalArticleList.js"; +export * from "./LinkedObject.js"; +export * from "./LinkedObjectList.js"; +export * from "./Metadata.js"; +export * from "./MultipleFilterSearchRequest.js"; +export * from "./NewsItemRequest.js"; +export * from "./NoteList.js"; +export * from "./NotFoundErrorBody.js"; +export * from "./OffsetPages.js"; +export * from "./OpenConversationRequest.js"; +export * from "./OperatorWorkflowEvent.js"; +export * from "./PagesLink.js"; +export * from "./PaginatedResponse.js"; +export * from "./PaginatedResponseDataItem.js"; +export * from "./PartAttachment.js"; +export * from "./PhoneSwitch.js"; +export * from "./QuickReplyOption.js"; +export * from "./Recipient.js"; +export * from "./RedactConversationRequest.js"; +export * from "./Reference.js"; +export * from "./ReplyConversationRequest.js"; +export * from "./SearchRequest.js"; +export * from "./SegmentList.js"; +export * from "./SingleFilterSearchRequest.js"; +export * from "./SlaApplied.js"; +export * from "./SnoozeConversationRequest.js"; +export * from "./SocialProfile.js"; +export * from "./StartingAfterPaging.js"; +export * from "./SubscriptionTypeList.js"; +export * from "./TagCompanyRequest.js"; +export * from "./TagList.js"; +export * from "./TagMultipleUsersRequest.js"; +export * from "./Tags.js"; +export * from "./TeamList.js"; +export * from "./TeamPriorityLevel.js"; +export * from "./TicketCustomAttributes.js"; +export * from "./TicketList.js"; +export * from "./TicketPartAuthor.js"; +export * from "./TicketParts.js"; +export * from "./TicketReply.js"; +export * from "./TicketRequestCustomAttributes.js"; +export * from "./TicketStateList.js"; +export * from "./TicketTypeAttribute.js"; +export * from "./TicketTypeAttributeList.js"; +export * from "./TicketTypeList.js"; +export * from "./Translation.js"; +export * from "./UntagCompanyRequest.js"; +export * from "./UpdateArticleRequestBody.js"; +export * from "./UpdateCompanyRequestBody.js"; +export * from "./UpdateDataAttributeRequestBody.js"; +export * from "./UpdateVisitorRequest.js"; +export * from "./UpdateVisitorRequestOne.js"; +export * from "./Visitor.js"; +export * from "./VisitorDeletedObject.js"; +export * from "./WhatsappMessageStatusList.js"; diff --git a/src/api/version.ts b/src/api/version.ts index 834369d5..54e211cb 100644 --- a/src/api/version.ts +++ b/src/api/version.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. /** The version of the API, sent as the Intercom-Version header. */ export type IntercomVersion = @@ -21,4 +19,7 @@ export type IntercomVersion = | "2.9" | "2.10" | "2.11" + | "2.12" + | "2.13" + | "2.14" | "Unstable"; diff --git a/src/auth/BearerAuthProvider.ts b/src/auth/BearerAuthProvider.ts new file mode 100644 index 00000000..fc69deba --- /dev/null +++ b/src/auth/BearerAuthProvider.ts @@ -0,0 +1,36 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as core from "../core/index.js"; +import * as errors from "../errors/index.js"; + +export namespace BearerAuthProvider { + export interface Options { + token?: core.Supplier; + } +} + +export class BearerAuthProvider implements core.AuthProvider { + private readonly token: core.Supplier | undefined; + + constructor(options: BearerAuthProvider.Options) { + this.token = options.token; + } + + public static canCreate(options: BearerAuthProvider.Options): boolean { + return options.token != null || process.env?.INTERCOM_API_KEY != null; + } + + public async getAuthRequest(_arg?: { endpointMetadata?: core.EndpointMetadata }): Promise { + const token = (await core.Supplier.get(this.token)) ?? process.env?.INTERCOM_API_KEY; + if (token == null) { + throw new errors.IntercomError({ + message: + "Please specify a token by either passing it in to the constructor or initializing a INTERCOM_API_KEY environment variable", + }); + } + + return { + headers: { Authorization: `Bearer ${token}` }, + }; + } +} diff --git a/src/auth/index.ts b/src/auth/index.ts new file mode 100644 index 00000000..0ecb12b7 --- /dev/null +++ b/src/auth/index.ts @@ -0,0 +1 @@ +export { BearerAuthProvider } from "./BearerAuthProvider.js"; diff --git a/src/core/auth/AuthProvider.ts b/src/core/auth/AuthProvider.ts new file mode 100644 index 00000000..895a50ff --- /dev/null +++ b/src/core/auth/AuthProvider.ts @@ -0,0 +1,6 @@ +import type { EndpointMetadata } from "../fetcher/EndpointMetadata.js"; +import type { AuthRequest } from "./AuthRequest.js"; + +export interface AuthProvider { + getAuthRequest(arg?: { endpointMetadata?: EndpointMetadata }): Promise; +} diff --git a/src/core/auth/AuthRequest.ts b/src/core/auth/AuthRequest.ts new file mode 100644 index 00000000..f6218b42 --- /dev/null +++ b/src/core/auth/AuthRequest.ts @@ -0,0 +1,9 @@ +/** + * Request parameters for authentication requests. + */ +export interface AuthRequest { + /** + * The headers to be included in the request. + */ + headers: Record; +} diff --git a/src/core/auth/BasicAuth.ts b/src/core/auth/BasicAuth.ts index 146df215..a6423591 100644 --- a/src/core/auth/BasicAuth.ts +++ b/src/core/auth/BasicAuth.ts @@ -1,4 +1,4 @@ -import { Base64 } from "js-base64"; +import { base64Decode, base64Encode } from "../base64.js"; export interface BasicAuth { username: string; @@ -12,13 +12,14 @@ export const BasicAuth = { if (basicAuth == null) { return undefined; } - const token = Base64.encode(`${basicAuth.username}:${basicAuth.password}`); + const token = base64Encode(`${basicAuth.username}:${basicAuth.password}`); return `Basic ${token}`; }, fromAuthorizationHeader: (header: string): BasicAuth => { const credentials = header.replace(BASIC_AUTH_HEADER_PREFIX, ""); - const decoded = Base64.decode(credentials); - const [username, password] = decoded.split(":", 2); + const decoded = base64Decode(credentials); + const [username, ...passwordParts] = decoded.split(":"); + const password = passwordParts.length > 0 ? passwordParts.join(":") : undefined; if (username == null || password == null) { throw new Error("Invalid basic auth"); diff --git a/src/core/auth/BearerToken.ts b/src/core/auth/BearerToken.ts index fe987fc9..c44a06c3 100644 --- a/src/core/auth/BearerToken.ts +++ b/src/core/auth/BearerToken.ts @@ -2,13 +2,18 @@ export type BearerToken = string; const BEARER_AUTH_HEADER_PREFIX = /^Bearer /i; -export const BearerToken = { - toAuthorizationHeader: (token: BearerToken | undefined): string | undefined => { - if (token == null) { - return undefined; - } - return `Bearer ${token}`; - }, +function toAuthorizationHeader(token: string | undefined): string | undefined { + if (token == null) { + return undefined; + } + return `Bearer ${token}`; +} + +export const BearerToken: { + toAuthorizationHeader: typeof toAuthorizationHeader; + fromAuthorizationHeader: (header: string) => BearerToken; +} = { + toAuthorizationHeader: toAuthorizationHeader, fromAuthorizationHeader: (header: string): BearerToken => { return header.replace(BEARER_AUTH_HEADER_PREFIX, "").trim() as BearerToken; }, diff --git a/src/core/auth/NoOpAuthProvider.ts b/src/core/auth/NoOpAuthProvider.ts new file mode 100644 index 00000000..5b7acfd2 --- /dev/null +++ b/src/core/auth/NoOpAuthProvider.ts @@ -0,0 +1,8 @@ +import type { AuthProvider } from "./AuthProvider.js"; +import type { AuthRequest } from "./AuthRequest.js"; + +export class NoOpAuthProvider implements AuthProvider { + public getAuthRequest(): Promise { + return Promise.resolve({ headers: {} }); + } +} diff --git a/src/core/auth/index.ts b/src/core/auth/index.ts index ee293b34..2215b227 100644 --- a/src/core/auth/index.ts +++ b/src/core/auth/index.ts @@ -1,2 +1,5 @@ -export { BasicAuth } from "./BasicAuth"; -export { BearerToken } from "./BearerToken"; +export type { AuthProvider } from "./AuthProvider.js"; +export type { AuthRequest } from "./AuthRequest.js"; +export { BasicAuth } from "./BasicAuth.js"; +export { BearerToken } from "./BearerToken.js"; +export { NoOpAuthProvider } from "./NoOpAuthProvider.js"; diff --git a/src/core/base64.ts b/src/core/base64.ts new file mode 100644 index 00000000..448a0db6 --- /dev/null +++ b/src/core/base64.ts @@ -0,0 +1,27 @@ +function base64ToBytes(base64: string): Uint8Array { + const binString = atob(base64); + return Uint8Array.from(binString, (m) => m.codePointAt(0)!); +} + +function bytesToBase64(bytes: Uint8Array): string { + const binString = String.fromCodePoint(...bytes); + return btoa(binString); +} + +export function base64Encode(input: string): string { + if (typeof Buffer !== "undefined") { + return Buffer.from(input, "utf8").toString("base64"); + } + + const bytes = new TextEncoder().encode(input); + return bytesToBase64(bytes); +} + +export function base64Decode(input: string): string { + if (typeof Buffer !== "undefined") { + return Buffer.from(input, "base64").toString("utf8"); + } + + const bytes = base64ToBytes(input); + return new TextDecoder().decode(bytes); +} diff --git a/src/core/exports.ts b/src/core/exports.ts new file mode 100644 index 00000000..d2774491 --- /dev/null +++ b/src/core/exports.ts @@ -0,0 +1,2 @@ +export * from "./logging/exports.js"; +export * from "./pagination/exports.js"; diff --git a/src/core/fetcher/APIResponse.ts b/src/core/fetcher/APIResponse.ts index 6335291b..97ab83c2 100644 --- a/src/core/fetcher/APIResponse.ts +++ b/src/core/fetcher/APIResponse.ts @@ -1,4 +1,4 @@ -import { RawResponse } from "./RawResponse"; +import type { RawResponse } from "./RawResponse.js"; /** * The response of an API call. diff --git a/src/core/fetcher/BinaryResponse.ts b/src/core/fetcher/BinaryResponse.ts new file mode 100644 index 00000000..bca7f4c7 --- /dev/null +++ b/src/core/fetcher/BinaryResponse.ts @@ -0,0 +1,34 @@ +export type BinaryResponse = { + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/bodyUsed) */ + bodyUsed: Response["bodyUsed"]; + /** + * Returns a ReadableStream of the response body. + * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/body) + */ + stream: () => Response["body"]; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/arrayBuffer) */ + arrayBuffer: () => ReturnType; + /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/blob) */ + blob: () => ReturnType; + /** + * [MDN Reference](https://developer.mozilla.org/docs/Web/API/Request/bytes) + * Some versions of the Fetch API may not support this method. + */ + bytes?(): ReturnType; +}; + +export function getBinaryResponse(response: Response): BinaryResponse { + const binaryResponse: BinaryResponse = { + get bodyUsed() { + return response.bodyUsed; + }, + stream: () => response.body, + arrayBuffer: response.arrayBuffer.bind(response), + blob: response.blob.bind(response), + }; + if ("bytes" in response && typeof response.bytes === "function") { + binaryResponse.bytes = response.bytes.bind(response); + } + + return binaryResponse; +} diff --git a/src/core/fetcher/EndpointMetadata.ts b/src/core/fetcher/EndpointMetadata.ts new file mode 100644 index 00000000..998d68f5 --- /dev/null +++ b/src/core/fetcher/EndpointMetadata.ts @@ -0,0 +1,13 @@ +export type SecuritySchemeKey = string; +/** + * A collection of security schemes, where the key is the name of the security scheme and the value is the list of scopes required for that scheme. + * All schemes in the collection must be satisfied for authentication to be successful. + */ +export type SecuritySchemeCollection = Record; +export type AuthScope = string; +export type EndpointMetadata = { + /** + * An array of security scheme collections. Each collection represents an alternative way to authenticate. + */ + security?: SecuritySchemeCollection[]; +}; diff --git a/src/core/fetcher/EndpointSupplier.ts b/src/core/fetcher/EndpointSupplier.ts new file mode 100644 index 00000000..8079841c --- /dev/null +++ b/src/core/fetcher/EndpointSupplier.ts @@ -0,0 +1,14 @@ +import type { EndpointMetadata } from "./EndpointMetadata.js"; +import type { Supplier } from "./Supplier.js"; + +type EndpointSupplierFn = (arg: { endpointMetadata: EndpointMetadata }) => T | Promise; +export type EndpointSupplier = Supplier | EndpointSupplierFn; +export const EndpointSupplier = { + get: async (supplier: EndpointSupplier, arg: { endpointMetadata: EndpointMetadata }): Promise => { + if (typeof supplier === "function") { + return (supplier as EndpointSupplierFn)(arg); + } else { + return supplier; + } + }, +}; diff --git a/src/core/fetcher/Fetcher.ts b/src/core/fetcher/Fetcher.ts index 336ee10b..58bb0e3e 100644 --- a/src/core/fetcher/Fetcher.ts +++ b/src/core/fetcher/Fetcher.ts @@ -1,12 +1,17 @@ -import { toJson } from "../json"; -import { APIResponse } from "./APIResponse"; -import { abortRawResponse, toRawResponse, unknownRawResponse } from "./RawResponse"; -import { createRequestUrl } from "./createRequestUrl"; -import { getFetchFn } from "./getFetchFn"; -import { getRequestBody } from "./getRequestBody"; -import { getResponseBody } from "./getResponseBody"; -import { makeRequest } from "./makeRequest"; -import { requestWithRetries } from "./requestWithRetries"; +import { toJson } from "../json.js"; +import { createLogger, type LogConfig, type Logger } from "../logging/logger.js"; +import type { APIResponse } from "./APIResponse.js"; +import { createRequestUrl } from "./createRequestUrl.js"; +import type { EndpointMetadata } from "./EndpointMetadata.js"; +import { EndpointSupplier } from "./EndpointSupplier.js"; +import { getErrorResponseBody } from "./getErrorResponseBody.js"; +import { getFetchFn } from "./getFetchFn.js"; +import { getRequestBody } from "./getRequestBody.js"; +import { getResponseBody } from "./getResponseBody.js"; +import { Headers } from "./Headers.js"; +import { makeRequest } from "./makeRequest.js"; +import { abortRawResponse, toRawResponse, unknownRawResponse } from "./RawResponse.js"; +import { requestWithRetries } from "./requestWithRetries.js"; export type FetchFunction = (args: Fetcher.Args) => Promise>; @@ -15,19 +20,22 @@ export declare namespace Fetcher { url: string; method: string; contentType?: string; - headers?: Record; - queryParameters?: Record; + headers?: Record | null | undefined>; + queryParameters?: Record; body?: unknown; timeoutMs?: number; maxRetries?: number; withCredentials?: boolean; abortSignal?: AbortSignal; - requestType?: "json" | "file" | "bytes"; - responseType?: "json" | "blob" | "sse" | "streaming" | "text" | "arrayBuffer"; + requestType?: "json" | "file" | "bytes" | "form" | "other"; + responseType?: "json" | "blob" | "sse" | "streaming" | "text" | "arrayBuffer" | "binary-response"; duplex?: "half"; + endpointMetadata?: EndpointMetadata; + fetchFn?: typeof fetch; + logging?: LogConfig | Logger; } - export type Error = FailedStatusCodeError | NonJsonError | TimeoutError | UnknownError; + export type Error = FailedStatusCodeError | NonJsonError | BodyIsNullError | TimeoutError | UnknownError; export interface FailedStatusCodeError { reason: "status-code"; @@ -41,6 +49,11 @@ export declare namespace Fetcher { rawBody: string; } + export interface BodyIsNullError { + reason: "body-is-null"; + statusCode: number; + } + export interface TimeoutError { reason: "timeout"; } @@ -51,26 +64,204 @@ export declare namespace Fetcher { } } -export async function fetcherImpl(args: Fetcher.Args): Promise> { - const headers: Record = {}; +const SENSITIVE_HEADERS = new Set([ + "authorization", + "www-authenticate", + "x-api-key", + "api-key", + "apikey", + "x-api-token", + "x-auth-token", + "auth-token", + "cookie", + "set-cookie", + "proxy-authorization", + "proxy-authenticate", + "x-csrf-token", + "x-xsrf-token", + "x-session-token", + "x-access-token", +]); + +function redactHeaders(headers: Headers | Record): Record { + const filtered: Record = {}; + for (const [key, value] of headers instanceof Headers ? headers.entries() : Object.entries(headers)) { + if (SENSITIVE_HEADERS.has(key.toLowerCase())) { + filtered[key] = "[REDACTED]"; + } else { + filtered[key] = value; + } + } + return filtered; +} + +const SENSITIVE_QUERY_PARAMS = new Set([ + "api_key", + "api-key", + "apikey", + "token", + "access_token", + "access-token", + "auth_token", + "auth-token", + "password", + "passwd", + "secret", + "api_secret", + "api-secret", + "apisecret", + "key", + "session", + "session_id", + "session-id", +]); + +function redactQueryParameters(queryParameters?: Record): Record | undefined { + if (queryParameters == null) { + return queryParameters; + } + const redacted: Record = {}; + for (const [key, value] of Object.entries(queryParameters)) { + if (SENSITIVE_QUERY_PARAMS.has(key.toLowerCase())) { + redacted[key] = "[REDACTED]"; + } else { + redacted[key] = value; + } + } + return redacted; +} + +function redactUrl(url: string): string { + const protocolIndex = url.indexOf("://"); + if (protocolIndex === -1) return url; + + const afterProtocol = protocolIndex + 3; + + // Find the first delimiter that marks the end of the authority section + const pathStart = url.indexOf("/", afterProtocol); + let queryStart = url.indexOf("?", afterProtocol); + let fragmentStart = url.indexOf("#", afterProtocol); + + const firstDelimiter = Math.min( + pathStart === -1 ? url.length : pathStart, + queryStart === -1 ? url.length : queryStart, + fragmentStart === -1 ? url.length : fragmentStart, + ); + + // Find the LAST @ before the delimiter (handles multiple @ in credentials) + let atIndex = -1; + for (let i = afterProtocol; i < firstDelimiter; i++) { + if (url[i] === "@") { + atIndex = i; + } + } + + if (atIndex !== -1) { + url = `${url.slice(0, afterProtocol)}[REDACTED]@${url.slice(atIndex + 1)}`; + } + + // Recalculate queryStart since url might have changed + queryStart = url.indexOf("?"); + if (queryStart === -1) return url; + + fragmentStart = url.indexOf("#", queryStart); + const queryEnd = fragmentStart !== -1 ? fragmentStart : url.length; + const queryString = url.slice(queryStart + 1, queryEnd); + + if (queryString.length === 0) return url; + + // FAST PATH: Quick check if any sensitive keywords present + // Using indexOf is faster than regex for simple substring matching + const lower = queryString.toLowerCase(); + const hasSensitive = + lower.includes("token") || + lower.includes("key") || + lower.includes("password") || + lower.includes("passwd") || + lower.includes("secret") || + lower.includes("session") || + lower.includes("auth"); + + if (!hasSensitive) { + return url; + } + + // SLOW PATH: Parse and redact + const redactedParams: string[] = []; + const params = queryString.split("&"); + + for (const param of params) { + const equalIndex = param.indexOf("="); + if (equalIndex === -1) { + redactedParams.push(param); + continue; + } + + const key = param.slice(0, equalIndex); + let shouldRedact = SENSITIVE_QUERY_PARAMS.has(key.toLowerCase()); + + if (!shouldRedact && key.includes("%")) { + try { + const decodedKey = decodeURIComponent(key); + shouldRedact = SENSITIVE_QUERY_PARAMS.has(decodedKey.toLowerCase()); + } catch {} + } + + redactedParams.push(shouldRedact ? `${key}=[REDACTED]` : param); + } + + return url.slice(0, queryStart + 1) + redactedParams.join("&") + url.slice(queryEnd); +} + +async function getHeaders(args: Fetcher.Args): Promise { + const newHeaders: Headers = new Headers(); + + newHeaders.set( + "Accept", + args.responseType === "json" ? "application/json" : args.responseType === "text" ? "text/plain" : "*/*", + ); if (args.body !== undefined && args.contentType != null) { - headers["Content-Type"] = args.contentType; + newHeaders.set("Content-Type", args.contentType); } - if (args.headers != null) { - for (const [key, value] of Object.entries(args.headers)) { - if (value != null) { - headers[key] = value; - } + if (args.headers == null) { + return newHeaders; + } + + for (const [key, value] of Object.entries(args.headers)) { + const result = await EndpointSupplier.get(value, { endpointMetadata: args.endpointMetadata ?? {} }); + if (typeof result === "string") { + newHeaders.set(key, result); + continue; + } + if (result == null) { + continue; } + newHeaders.set(key, `${result}`); } + return newHeaders; +} +export async function fetcherImpl(args: Fetcher.Args): Promise> { const url = createRequestUrl(args.url, args.queryParameters); const requestBody: BodyInit | undefined = await getRequestBody({ body: args.body, - type: args.requestType === "json" ? "json" : "other", + type: args.requestType ?? "other", }); - const fetchFn = await getFetchFn(); + const fetchFn = args.fetchFn ?? (await getFetchFn()); + const headers = await getHeaders(args); + const logger = createLogger(args.logging); + + if (logger.isDebug()) { + const metadata = { + method: args.method, + url: redactUrl(url), + headers: redactHeaders(headers), + queryParameters: redactQueryParameters(args.queryParameters), + hasBody: requestBody != null, + }; + logger.debug("Making HTTP request", metadata); + } try { const response = await requestWithRetries( @@ -88,28 +279,53 @@ export async function fetcherImpl(args: Fetcher.Args): Promise= 200 && response.status < 400) { + if (logger.isDebug()) { + const metadata = { + method: args.method, + url: redactUrl(url), + statusCode: response.status, + responseHeaders: redactHeaders(response.headers), + }; + logger.debug("HTTP request succeeded", metadata); + } + const body = await getResponseBody(response, args.responseType); return { ok: true, - body: responseBody as R, + body: body as R, headers: response.headers, rawResponse: toRawResponse(response), }; } else { + if (logger.isError()) { + const metadata = { + method: args.method, + url: redactUrl(url), + statusCode: response.status, + responseHeaders: redactHeaders(Object.fromEntries(response.headers.entries())), + }; + logger.error("HTTP request failed with error status", metadata); + } return { ok: false, error: { reason: "status-code", statusCode: response.status, - body: responseBody, + body: await getErrorResponseBody(response), }, rawResponse: toRawResponse(response), }; } } catch (error) { - if (args.abortSignal != null && args.abortSignal.aborted) { + if (args.abortSignal?.aborted) { + if (logger.isError()) { + const metadata = { + method: args.method, + url: redactUrl(url), + }; + logger.error("HTTP request was aborted", metadata); + } return { ok: false, error: { @@ -119,6 +335,14 @@ export async function fetcherImpl(args: Fetcher.Args): Promise(args: Fetcher.Args): Promise(args: Fetcher.Args): Promise, -): string { - return Object.keys(queryParameters ?? {}).length > 0 - ? `${baseUrl}?${qs.stringify(queryParameters, { arrayFormat: "repeat" })}` - : baseUrl; +export function createRequestUrl(baseUrl: string, queryParameters?: Record): string { + const queryString = toQueryString(queryParameters, { arrayFormat: "repeat" }); + return queryString ? `${baseUrl}?${queryString}` : baseUrl; } diff --git a/src/core/fetcher/getErrorResponseBody.ts b/src/core/fetcher/getErrorResponseBody.ts new file mode 100644 index 00000000..7cf4e623 --- /dev/null +++ b/src/core/fetcher/getErrorResponseBody.ts @@ -0,0 +1,33 @@ +import { fromJson } from "../json.js"; +import { getResponseBody } from "./getResponseBody.js"; + +export async function getErrorResponseBody(response: Response): Promise { + let contentType = response.headers.get("Content-Type")?.toLowerCase(); + if (contentType == null || contentType.length === 0) { + return getResponseBody(response); + } + + if (contentType.indexOf(";") !== -1) { + contentType = contentType.split(";")[0]?.trim() ?? ""; + } + switch (contentType) { + case "application/hal+json": + case "application/json": + case "application/ld+json": + case "application/problem+json": + case "application/vnd.api+json": + case "text/json": { + const text = await response.text(); + return text.length > 0 ? fromJson(text) : undefined; + } + default: + if (contentType.startsWith("application/vnd.") && contentType.endsWith("+json")) { + const text = await response.text(); + return text.length > 0 ? fromJson(text) : undefined; + } + + // Fallback to plain text if content type is not recognized + // Even if no body is present, the response will be an empty string + return await response.text(); + } +} diff --git a/src/core/fetcher/getFetchFn.ts b/src/core/fetcher/getFetchFn.ts index 9fd9bfc4..9f845b95 100644 --- a/src/core/fetcher/getFetchFn.ts +++ b/src/core/fetcher/getFetchFn.ts @@ -1,25 +1,3 @@ -import { RUNTIME } from "../runtime"; - -/** - * Returns a fetch function based on the runtime - */ -export async function getFetchFn(): Promise { - // In Node.js 18+ environments, use native fetch - if (RUNTIME.type === "node" && RUNTIME.parsedVersion != null && RUNTIME.parsedVersion >= 18) { - return fetch; - } - - // In Node.js 18 or lower environments, the SDK always uses`node-fetch`. - if (RUNTIME.type === "node") { - return (await import("node-fetch")).default as any; - } - - // Otherwise the SDK uses global fetch if available, - // and falls back to node-fetch. - if (typeof fetch == "function") { - return fetch; - } - - // Defaults to node `node-fetch` if global fetch isn't available - return (await import("node-fetch")).default as any; +export async function getFetchFn(): Promise { + return fetch; } diff --git a/src/core/fetcher/getRequestBody.ts b/src/core/fetcher/getRequestBody.ts index fce5589c..91d9d81f 100644 --- a/src/core/fetcher/getRequestBody.ts +++ b/src/core/fetcher/getRequestBody.ts @@ -1,13 +1,17 @@ -import { toJson } from "../json"; +import { toJson } from "../json.js"; +import { toQueryString } from "../url/qs.js"; export declare namespace GetRequestBody { interface Args { body: unknown; - type: "json" | "file" | "bytes" | "other"; + type: "json" | "file" | "bytes" | "form" | "other"; } } export async function getRequestBody({ body, type }: GetRequestBody.Args): Promise { + if (type === "form") { + return toQueryString(body, { arrayFormat: "repeat", encode: true }); + } if (type.includes("json")) { return toJson(body); } else { diff --git a/src/core/fetcher/getResponseBody.ts b/src/core/fetcher/getResponseBody.ts index d046e6ea..708d5572 100644 --- a/src/core/fetcher/getResponseBody.ts +++ b/src/core/fetcher/getResponseBody.ts @@ -1,34 +1,58 @@ -import { chooseStreamWrapper } from "./stream-wrappers/chooseStreamWrapper"; +import { fromJson } from "../json.js"; +import { getBinaryResponse } from "./BinaryResponse.js"; export async function getResponseBody(response: Response, responseType?: string): Promise { - if (response.body != null && responseType === "blob") { - return await response.blob(); - } else if (response.body != null && responseType === "arrayBuffer") { - return await response.arrayBuffer(); - } else if (response.body != null && responseType === "sse") { - return response.body; - } else if (response.body != null && responseType === "streaming") { - return chooseStreamWrapper(response.body); - } else if (response.body != null && responseType === "text") { - return await response.text(); - } else { - const text = await response.text(); - if (text.length > 0) { - try { - let responseBody = JSON.parse(text); - return responseBody; - } catch (err) { + switch (responseType) { + case "binary-response": + return getBinaryResponse(response); + case "blob": + return await response.blob(); + case "arrayBuffer": + return await response.arrayBuffer(); + case "sse": + if (response.body == null) { return { ok: false, error: { - reason: "non-json", + reason: "body-is-null", statusCode: response.status, - rawBody: text, }, }; } - } else { - return undefined; + return response.body; + case "streaming": + if (response.body == null) { + return { + ok: false, + error: { + reason: "body-is-null", + statusCode: response.status, + }, + }; + } + + return response.body; + + case "text": + return await response.text(); + } + + // if responseType is "json" or not specified, try to parse as JSON + const text = await response.text(); + if (text.length > 0) { + try { + const responseBody = fromJson(text); + return responseBody; + } catch (_err) { + return { + ok: false, + error: { + reason: "non-json", + statusCode: response.status, + rawBody: text, + }, + }; } } + return undefined; } diff --git a/src/core/fetcher/index.ts b/src/core/fetcher/index.ts index 249f5176..c3bc6da2 100644 --- a/src/core/fetcher/index.ts +++ b/src/core/fetcher/index.ts @@ -1,8 +1,11 @@ -export type { APIResponse } from "./APIResponse"; -export { fetcher } from "./Fetcher"; -export type { Fetcher, FetchFunction } from "./Fetcher"; -export { getHeader } from "./getHeader"; -export { Supplier } from "./Supplier"; -export { abortRawResponse, toRawResponse, unknownRawResponse } from "./RawResponse"; -export type { RawResponse, WithRawResponse } from "./RawResponse"; -export { HttpResponsePromise } from "./HttpResponsePromise"; +export type { APIResponse } from "./APIResponse.js"; +export type { BinaryResponse } from "./BinaryResponse.js"; +export type { EndpointMetadata } from "./EndpointMetadata.js"; +export { EndpointSupplier } from "./EndpointSupplier.js"; +export type { Fetcher, FetchFunction } from "./Fetcher.js"; +export { fetcher } from "./Fetcher.js"; +export { getHeader } from "./getHeader.js"; +export { HttpResponsePromise } from "./HttpResponsePromise.js"; +export type { RawResponse, WithRawResponse } from "./RawResponse.js"; +export { abortRawResponse, toRawResponse, unknownRawResponse } from "./RawResponse.js"; +export { Supplier } from "./Supplier.js"; diff --git a/src/core/fetcher/makeRequest.ts b/src/core/fetcher/makeRequest.ts index 1af42bb9..921565eb 100644 --- a/src/core/fetcher/makeRequest.ts +++ b/src/core/fetcher/makeRequest.ts @@ -1,10 +1,10 @@ -import { anySignal, getTimeoutSignal } from "./signals"; +import { anySignal, getTimeoutSignal } from "./signals.js"; export const makeRequest = async ( fetchFn: (url: string, init: RequestInit) => Promise, url: string, method: string, - headers: Record, + headers: Headers | Record, requestBody: BodyInit | undefined, timeoutMs?: number, abortSignal?: AbortSignal, @@ -13,19 +13,17 @@ export const makeRequest = async ( ): Promise => { const signals: AbortSignal[] = []; - // Add timeout signal - let timeoutAbortId: NodeJS.Timeout | undefined = undefined; + let timeoutAbortId: ReturnType | undefined; if (timeoutMs != null) { const { signal, abortId } = getTimeoutSignal(timeoutMs); timeoutAbortId = abortId; signals.push(signal); } - // Add arbitrary signal if (abortSignal != null) { signals.push(abortSignal); } - let newSignals = anySignal(signals); + const newSignals = anySignal(signals); const response = await fetchFn(url, { method: method, headers, diff --git a/src/core/fetcher/requestWithRetries.ts b/src/core/fetcher/requestWithRetries.ts index add3cce0..1f689688 100644 --- a/src/core/fetcher/requestWithRetries.ts +++ b/src/core/fetcher/requestWithRetries.ts @@ -3,12 +3,47 @@ const MAX_RETRY_DELAY = 60000; // in milliseconds const DEFAULT_MAX_RETRIES = 2; const JITTER_FACTOR = 0.2; // 20% random jitter -function addJitter(delay: number): number { - // Generate a random value between -JITTER_FACTOR and +JITTER_FACTOR - const jitterMultiplier = 1 + (Math.random() * 2 - 1) * JITTER_FACTOR; +function addPositiveJitter(delay: number): number { + const jitterMultiplier = 1 + Math.random() * JITTER_FACTOR; return delay * jitterMultiplier; } +function addSymmetricJitter(delay: number): number { + const jitterMultiplier = 1 + (Math.random() - 0.5) * JITTER_FACTOR; + return delay * jitterMultiplier; +} + +function getRetryDelayFromHeaders(response: Response, retryAttempt: number): number { + const retryAfter = response.headers.get("Retry-After"); + if (retryAfter) { + const retryAfterSeconds = parseInt(retryAfter, 10); + if (!Number.isNaN(retryAfterSeconds) && retryAfterSeconds > 0) { + return Math.min(retryAfterSeconds * 1000, MAX_RETRY_DELAY); + } + + const retryAfterDate = new Date(retryAfter); + if (!Number.isNaN(retryAfterDate.getTime())) { + const delay = retryAfterDate.getTime() - Date.now(); + if (delay > 0) { + return Math.min(Math.max(delay, 0), MAX_RETRY_DELAY); + } + } + } + + const rateLimitReset = response.headers.get("X-RateLimit-Reset"); + if (rateLimitReset) { + const resetTime = parseInt(rateLimitReset, 10); + if (!Number.isNaN(resetTime)) { + const delay = resetTime * 1000 - Date.now(); + if (delay > 0) { + return addPositiveJitter(Math.min(delay, MAX_RETRY_DELAY)); + } + } + } + + return addSymmetricJitter(Math.min(INITIAL_RETRY_DELAY * 2 ** retryAttempt, MAX_RETRY_DELAY)); +} + export async function requestWithRetries( requestFn: () => Promise, maxRetries: number = DEFAULT_MAX_RETRIES, @@ -17,13 +52,9 @@ export async function requestWithRetries( for (let i = 0; i < maxRetries; ++i) { if ([408, 429].includes(response.status) || response.status >= 500) { - // Calculate base delay using exponential backoff (in milliseconds) - const baseDelay = Math.min(INITIAL_RETRY_DELAY * Math.pow(2, i), MAX_RETRY_DELAY); - - // Add jitter to the delay - const delayWithJitter = addJitter(baseDelay); + const delay = getRetryDelayFromHeaders(response, i); - await new Promise((resolve) => setTimeout(resolve, delayWithJitter)); + await new Promise((resolve) => setTimeout(resolve, delay)); response = await requestFn(); } else { break; diff --git a/src/core/fetcher/signals.ts b/src/core/fetcher/signals.ts index a8d32a2e..7bd3757e 100644 --- a/src/core/fetcher/signals.ts +++ b/src/core/fetcher/signals.ts @@ -1,34 +1,22 @@ const TIMEOUT = "timeout"; -export function getTimeoutSignal(timeoutMs: number): { signal: AbortSignal; abortId: NodeJS.Timeout } { +export function getTimeoutSignal(timeoutMs: number): { signal: AbortSignal; abortId: ReturnType } { const controller = new AbortController(); const abortId = setTimeout(() => controller.abort(TIMEOUT), timeoutMs); return { signal: controller.signal, abortId }; } -/** - * Returns an abort signal that is getting aborted when - * at least one of the specified abort signals is aborted. - * - * Requires at least node.js 18. - */ export function anySignal(...args: AbortSignal[] | [AbortSignal[]]): AbortSignal { - // Allowing signals to be passed either as array - // of signals or as multiple arguments. const signals = (args.length === 1 && Array.isArray(args[0]) ? args[0] : args) as AbortSignal[]; const controller = new AbortController(); for (const signal of signals) { if (signal.aborted) { - // Exiting early if one of the signals - // is already aborted. controller.abort((signal as any)?.reason); break; } - // Listening for signals and removing the listeners - // when at least one symbol is aborted. signal.addEventListener("abort", () => controller.abort((signal as any)?.reason), { signal: controller.signal, }); diff --git a/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts b/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts deleted file mode 100644 index 6f1a82e9..00000000 --- a/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts +++ /dev/null @@ -1,257 +0,0 @@ -import type { Writable } from "readable-stream"; - -import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; - -export class Node18UniversalStreamWrapper - implements - StreamWrapper | Writable | WritableStream, ReadFormat> -{ - private readableStream: ReadableStream; - private reader: ReadableStreamDefaultReader; - private events: Record; - private paused: boolean; - private resumeCallback: ((value?: unknown) => void) | null; - private encoding: string | null; - - constructor(readableStream: ReadableStream) { - this.readableStream = readableStream; - this.reader = this.readableStream.getReader(); - this.events = { - data: [], - end: [], - error: [], - readable: [], - close: [], - pause: [], - resume: [], - }; - this.paused = false; - this.resumeCallback = null; - this.encoding = null; - } - - public on(event: string, callback: EventCallback): void { - this.events[event]?.push(callback); - } - - public off(event: string, callback: EventCallback): void { - this.events[event] = this.events[event]?.filter((cb) => cb !== callback); - } - - public pipe( - dest: Node18UniversalStreamWrapper | Writable | WritableStream, - ): Node18UniversalStreamWrapper | Writable | WritableStream { - this.on("data", async (chunk) => { - if (dest instanceof Node18UniversalStreamWrapper) { - dest._write(chunk); - } else if (dest instanceof WritableStream) { - const writer = dest.getWriter(); - writer.write(chunk).then(() => writer.releaseLock()); - } else { - dest.write(chunk); - } - }); - - this.on("end", async () => { - if (dest instanceof Node18UniversalStreamWrapper) { - dest._end(); - } else if (dest instanceof WritableStream) { - const writer = dest.getWriter(); - writer.close(); - } else { - dest.end(); - } - }); - - this.on("error", async (error) => { - if (dest instanceof Node18UniversalStreamWrapper) { - dest._error(error); - } else if (dest instanceof WritableStream) { - const writer = dest.getWriter(); - writer.abort(error); - } else { - dest.destroy(error); - } - }); - - this._startReading(); - - return dest; - } - - public pipeTo( - dest: Node18UniversalStreamWrapper | Writable | WritableStream, - ): Node18UniversalStreamWrapper | Writable | WritableStream { - return this.pipe(dest); - } - - public unpipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): void { - this.off("data", async (chunk) => { - if (dest instanceof Node18UniversalStreamWrapper) { - dest._write(chunk); - } else if (dest instanceof WritableStream) { - const writer = dest.getWriter(); - writer.write(chunk).then(() => writer.releaseLock()); - } else { - dest.write(chunk); - } - }); - - this.off("end", async () => { - if (dest instanceof Node18UniversalStreamWrapper) { - dest._end(); - } else if (dest instanceof WritableStream) { - const writer = dest.getWriter(); - writer.close(); - } else { - dest.end(); - } - }); - - this.off("error", async (error) => { - if (dest instanceof Node18UniversalStreamWrapper) { - dest._error(error); - } else if (dest instanceof WritableStream) { - const writer = dest.getWriter(); - writer.abort(error); - } else { - dest.destroy(error); - } - }); - } - - public destroy(error?: Error): void { - this.reader - .cancel(error) - .then(() => { - this._emit("close"); - }) - .catch((err) => { - this._emit("error", err); - }); - } - - public pause(): void { - this.paused = true; - this._emit("pause"); - } - - public resume(): void { - if (this.paused) { - this.paused = false; - this._emit("resume"); - if (this.resumeCallback) { - this.resumeCallback(); - this.resumeCallback = null; - } - } - } - - public get isPaused(): boolean { - return this.paused; - } - - public async read(): Promise { - if (this.paused) { - await new Promise((resolve) => { - this.resumeCallback = resolve; - }); - } - const { done, value } = await this.reader.read(); - - if (done) { - return undefined; - } - return value; - } - - public setEncoding(encoding: string): void { - this.encoding = encoding; - } - - public async text(): Promise { - const chunks: ReadFormat[] = []; - - while (true) { - const { done, value } = await this.reader.read(); - if (done) { - break; - } - if (value) { - chunks.push(value); - } - } - - const decoder = new TextDecoder(this.encoding || "utf-8"); - return decoder.decode(await new Blob(chunks).arrayBuffer()); - } - - public async json(): Promise { - const text = await this.text(); - return JSON.parse(text); - } - - private _write(chunk: ReadFormat): void { - this._emit("data", chunk); - } - - private _end(): void { - this._emit("end"); - } - - private _error(error: any): void { - this._emit("error", error); - } - - private _emit(event: string, data?: any): void { - if (this.events[event]) { - for (const callback of this.events[event] || []) { - callback(data); - } - } - } - - private async _startReading(): Promise { - try { - this._emit("readable"); - while (true) { - if (this.paused) { - await new Promise((resolve) => { - this.resumeCallback = resolve; - }); - } - const { done, value } = await this.reader.read(); - if (done) { - this._emit("end"); - this._emit("close"); - break; - } - if (value) { - this._emit("data", value); - } - } - } catch (error) { - this._emit("error", error); - } - } - - [Symbol.asyncIterator](): AsyncIterableIterator { - return { - next: async () => { - if (this.paused) { - await new Promise((resolve) => { - this.resumeCallback = resolve; - }); - } - const { done, value } = await this.reader.read(); - if (done) { - return { done: true, value: undefined }; - } - return { done: false, value }; - }, - [Symbol.asyncIterator]() { - return this; - }, - }; - } -} diff --git a/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts b/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts deleted file mode 100644 index 23c01a1a..00000000 --- a/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts +++ /dev/null @@ -1,107 +0,0 @@ -import type { Readable, Writable } from "readable-stream"; - -import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; - -export class NodePre18StreamWrapper implements StreamWrapper { - private readableStream: Readable; - private encoding: string | undefined; - - constructor(readableStream: Readable) { - this.readableStream = readableStream; - } - - public on(event: string, callback: EventCallback): void { - this.readableStream.on(event, callback); - } - - public off(event: string, callback: EventCallback): void { - this.readableStream.off(event, callback); - } - - public pipe(dest: Writable): Writable { - this.readableStream.pipe(dest); - return dest; - } - - public pipeTo(dest: Writable): Writable { - return this.pipe(dest); - } - - public unpipe(dest?: Writable): void { - if (dest) { - this.readableStream.unpipe(dest); - } else { - this.readableStream.unpipe(); - } - } - - public destroy(error?: Error): void { - this.readableStream.destroy(error); - } - - public pause(): void { - this.readableStream.pause(); - } - - public resume(): void { - this.readableStream.resume(); - } - - public get isPaused(): boolean { - return this.readableStream.isPaused(); - } - - public async read(): Promise { - return new Promise((resolve, reject) => { - const chunk = this.readableStream.read(); - if (chunk) { - resolve(chunk); - } else { - this.readableStream.once("readable", () => { - const chunk = this.readableStream.read(); - resolve(chunk); - }); - this.readableStream.once("error", reject); - } - }); - } - - public setEncoding(encoding?: string): void { - this.readableStream.setEncoding(encoding as BufferEncoding); - this.encoding = encoding; - } - - public async text(): Promise { - const chunks: Uint8Array[] = []; - const encoder = new TextEncoder(); - this.readableStream.setEncoding((this.encoding || "utf-8") as BufferEncoding); - - for await (const chunk of this.readableStream) { - chunks.push(encoder.encode(chunk)); - } - - const decoder = new TextDecoder(this.encoding || "utf-8"); - return decoder.decode(Buffer.concat(chunks)); - } - - public async json(): Promise { - const text = await this.text(); - return JSON.parse(text); - } - - public [Symbol.asyncIterator](): AsyncIterableIterator { - const readableStream = this.readableStream; - const iterator = readableStream[Symbol.asyncIterator](); - - // Create and return an async iterator that yields buffers - return { - async next(): Promise> { - const { value, done } = await iterator.next(); - return { value: value as Buffer, done }; - }, - [Symbol.asyncIterator]() { - return this; - }, - }; - } -} diff --git a/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts b/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts deleted file mode 100644 index 091e2a7f..00000000 --- a/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts +++ /dev/null @@ -1,243 +0,0 @@ -import { StreamWrapper } from "./chooseStreamWrapper"; - -type EventCallback = (data?: any) => void; - -export class UndiciStreamWrapper - implements StreamWrapper | WritableStream, ReadFormat> -{ - private readableStream: ReadableStream; - private reader: ReadableStreamDefaultReader; - private events: Record; - private paused: boolean; - private resumeCallback: ((value?: unknown) => void) | null; - private encoding: string | null; - - constructor(readableStream: ReadableStream) { - this.readableStream = readableStream; - this.reader = this.readableStream.getReader(); - this.events = { - data: [], - end: [], - error: [], - readable: [], - close: [], - pause: [], - resume: [], - }; - this.paused = false; - this.resumeCallback = null; - this.encoding = null; - } - - public on(event: string, callback: EventCallback): void { - this.events[event]?.push(callback); - } - - public off(event: string, callback: EventCallback): void { - this.events[event] = this.events[event]?.filter((cb) => cb !== callback); - } - - public pipe( - dest: UndiciStreamWrapper | WritableStream, - ): UndiciStreamWrapper | WritableStream { - this.on("data", (chunk) => { - if (dest instanceof UndiciStreamWrapper) { - dest._write(chunk); - } else { - const writer = dest.getWriter(); - writer.write(chunk).then(() => writer.releaseLock()); - } - }); - - this.on("end", () => { - if (dest instanceof UndiciStreamWrapper) { - dest._end(); - } else { - const writer = dest.getWriter(); - writer.close(); - } - }); - - this.on("error", (error) => { - if (dest instanceof UndiciStreamWrapper) { - dest._error(error); - } else { - const writer = dest.getWriter(); - writer.abort(error); - } - }); - - this._startReading(); - - return dest; - } - - public pipeTo( - dest: UndiciStreamWrapper | WritableStream, - ): UndiciStreamWrapper | WritableStream { - return this.pipe(dest); - } - - public unpipe(dest: UndiciStreamWrapper | WritableStream): void { - this.off("data", (chunk) => { - if (dest instanceof UndiciStreamWrapper) { - dest._write(chunk); - } else { - const writer = dest.getWriter(); - writer.write(chunk).then(() => writer.releaseLock()); - } - }); - - this.off("end", () => { - if (dest instanceof UndiciStreamWrapper) { - dest._end(); - } else { - const writer = dest.getWriter(); - writer.close(); - } - }); - - this.off("error", (error) => { - if (dest instanceof UndiciStreamWrapper) { - dest._error(error); - } else { - const writer = dest.getWriter(); - writer.abort(error); - } - }); - } - - public destroy(error?: Error): void { - this.reader - .cancel(error) - .then(() => { - this._emit("close"); - }) - .catch((err) => { - this._emit("error", err); - }); - } - - public pause(): void { - this.paused = true; - this._emit("pause"); - } - - public resume(): void { - if (this.paused) { - this.paused = false; - this._emit("resume"); - if (this.resumeCallback) { - this.resumeCallback(); - this.resumeCallback = null; - } - } - } - - public get isPaused(): boolean { - return this.paused; - } - - public async read(): Promise { - if (this.paused) { - await new Promise((resolve) => { - this.resumeCallback = resolve; - }); - } - const { done, value } = await this.reader.read(); - if (done) { - return undefined; - } - return value; - } - - public setEncoding(encoding: string): void { - this.encoding = encoding; - } - - public async text(): Promise { - const chunks: BlobPart[] = []; - - while (true) { - const { done, value } = await this.reader.read(); - if (done) { - break; - } - if (value) { - chunks.push(value); - } - } - - const decoder = new TextDecoder(this.encoding || "utf-8"); - return decoder.decode(await new Blob(chunks).arrayBuffer()); - } - - public async json(): Promise { - const text = await this.text(); - return JSON.parse(text); - } - - private _write(chunk: ReadFormat): void { - this._emit("data", chunk); - } - - private _end(): void { - this._emit("end"); - } - - private _error(error: any): void { - this._emit("error", error); - } - - private _emit(event: string, data?: any): void { - if (this.events[event]) { - for (const callback of this.events[event] || []) { - callback(data); - } - } - } - - private async _startReading(): Promise { - try { - this._emit("readable"); - while (true) { - if (this.paused) { - await new Promise((resolve) => { - this.resumeCallback = resolve; - }); - } - const { done, value } = await this.reader.read(); - if (done) { - this._emit("end"); - this._emit("close"); - break; - } - if (value) { - this._emit("data", value); - } - } - } catch (error) { - this._emit("error", error); - } - } - - [Symbol.asyncIterator](): AsyncIterableIterator { - return { - next: async () => { - if (this.paused) { - await new Promise((resolve) => { - this.resumeCallback = resolve; - }); - } - const { done, value } = await this.reader.read(); - if (done) { - return { done: true, value: undefined }; - } - return { done: false, value }; - }, - [Symbol.asyncIterator]() { - return this; - }, - }; - } -} diff --git a/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts b/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts deleted file mode 100644 index 8c7492fc..00000000 --- a/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts +++ /dev/null @@ -1,34 +0,0 @@ -import type { Readable } from "readable-stream"; - -import { RUNTIME } from "../../runtime"; - -export type EventCallback = (data?: any) => void; - -export interface StreamWrapper { - setEncoding(encoding?: string): void; - on(event: string, callback: EventCallback): void; - off(event: string, callback: EventCallback): void; - pipe(dest: WritableStream): WritableStream; - pipeTo(dest: WritableStream): WritableStream; - unpipe(dest?: WritableStream): void; - destroy(error?: Error): void; - pause(): void; - resume(): void; - get isPaused(): boolean; - read(): Promise; - text(): Promise; - json(): Promise; - [Symbol.asyncIterator](): AsyncIterableIterator; -} - -export async function chooseStreamWrapper(responseBody: any): Promise>> { - if (RUNTIME.type === "node" && RUNTIME.parsedVersion != null && RUNTIME.parsedVersion >= 18) { - return new (await import("./Node18UniversalStreamWrapper")).Node18UniversalStreamWrapper( - responseBody as ReadableStream, - ); - } else if (RUNTIME.type !== "node" && typeof fetch === "function") { - return new (await import("./UndiciStreamWrapper")).UndiciStreamWrapper(responseBody as ReadableStream); - } else { - return new (await import("./NodePre18StreamWrapper")).NodePre18StreamWrapper(responseBody as Readable); - } -} diff --git a/src/core/headers.ts b/src/core/headers.ts new file mode 100644 index 00000000..78ed8b50 --- /dev/null +++ b/src/core/headers.ts @@ -0,0 +1,35 @@ +export function mergeHeaders( + ...headersArray: (Record | null | undefined)[] +): Record { + const result: Record = {}; + + for (const [key, value] of headersArray + .filter((headers) => headers != null) + .flatMap((headers) => Object.entries(headers))) { + const insensitiveKey = key.toLowerCase(); + if (value != null) { + result[insensitiveKey] = value; + } else if (insensitiveKey in result) { + delete result[insensitiveKey]; + } + } + + return result; +} + +export function mergeOnlyDefinedHeaders( + ...headersArray: (Record | null | undefined)[] +): Record { + const result: Record = {}; + + for (const [key, value] of headersArray + .filter((headers) => headers != null) + .flatMap((headers) => Object.entries(headers))) { + const insensitiveKey = key.toLowerCase(); + if (value != null) { + result[insensitiveKey] = value; + } + } + + return result; +} diff --git a/src/core/index.ts b/src/core/index.ts index 466b3c3a..f25662a5 100644 --- a/src/core/index.ts +++ b/src/core/index.ts @@ -1,5 +1,8 @@ -export * from "./fetcher"; -export * from "./runtime"; -export * from "./auth"; -export * from "./utils"; -export * from "./pagination"; +export * from "./auth/index.js"; +export * from "./base64.js"; +export * from "./fetcher/index.js"; +export * as logging from "./logging/index.js"; +export * from "./pagination/index.js"; +export * from "./runtime/index.js"; +export * as url from "./url/index.js"; +export * from "./utils/index.js"; diff --git a/src/core/logging/exports.ts b/src/core/logging/exports.ts new file mode 100644 index 00000000..88f6c00d --- /dev/null +++ b/src/core/logging/exports.ts @@ -0,0 +1,19 @@ +import * as logger from "./logger.js"; + +export namespace logging { + /** + * Configuration for logger instances. + */ + export type LogConfig = logger.LogConfig; + export type LogLevel = logger.LogLevel; + export const LogLevel: typeof logger.LogLevel = logger.LogLevel; + export type ILogger = logger.ILogger; + /** + * Console logger implementation that outputs to the console. + */ + export type ConsoleLogger = logger.ConsoleLogger; + /** + * Console logger implementation that outputs to the console. + */ + export const ConsoleLogger: typeof logger.ConsoleLogger = logger.ConsoleLogger; +} diff --git a/src/core/logging/index.ts b/src/core/logging/index.ts new file mode 100644 index 00000000..d81cc32c --- /dev/null +++ b/src/core/logging/index.ts @@ -0,0 +1 @@ +export * from "./logger.js"; diff --git a/src/core/logging/logger.ts b/src/core/logging/logger.ts new file mode 100644 index 00000000..a3f3673c --- /dev/null +++ b/src/core/logging/logger.ts @@ -0,0 +1,203 @@ +export const LogLevel = { + Debug: "debug", + Info: "info", + Warn: "warn", + Error: "error", +} as const; +export type LogLevel = (typeof LogLevel)[keyof typeof LogLevel]; +const logLevelMap: Record = { + [LogLevel.Debug]: 1, + [LogLevel.Info]: 2, + [LogLevel.Warn]: 3, + [LogLevel.Error]: 4, +}; + +export interface ILogger { + /** + * Logs a debug message. + * @param message - The message to log + * @param args - Additional arguments to log + */ + debug(message: string, ...args: unknown[]): void; + /** + * Logs an info message. + * @param message - The message to log + * @param args - Additional arguments to log + */ + info(message: string, ...args: unknown[]): void; + /** + * Logs a warning message. + * @param message - The message to log + * @param args - Additional arguments to log + */ + warn(message: string, ...args: unknown[]): void; + /** + * Logs an error message. + * @param message - The message to log + * @param args - Additional arguments to log + */ + error(message: string, ...args: unknown[]): void; +} + +/** + * Configuration for logger initialization. + */ +export interface LogConfig { + /** + * Minimum log level to output. + * @default LogLevel.Info + */ + level?: LogLevel; + /** + * Logger implementation to use. + * @default new ConsoleLogger() + */ + logger?: ILogger; + /** + * Whether logging should be silenced. + * @default true + */ + silent?: boolean; +} + +/** + * Default console-based logger implementation. + */ +export class ConsoleLogger implements ILogger { + debug(message: string, ...args: unknown[]): void { + console.debug(message, ...args); + } + info(message: string, ...args: unknown[]): void { + console.info(message, ...args); + } + warn(message: string, ...args: unknown[]): void { + console.warn(message, ...args); + } + error(message: string, ...args: unknown[]): void { + console.error(message, ...args); + } +} + +/** + * Logger class that provides level-based logging functionality. + */ +export class Logger { + private readonly level: number; + private readonly logger: ILogger; + private readonly silent: boolean; + + /** + * Creates a new logger instance. + * @param config - Logger configuration + */ + constructor(config: Required) { + this.level = logLevelMap[config.level]; + this.logger = config.logger; + this.silent = config.silent; + } + + /** + * Checks if a log level should be output based on configuration. + * @param level - The log level to check + * @returns True if the level should be logged + */ + public shouldLog(level: LogLevel): boolean { + return !this.silent && this.level <= logLevelMap[level]; + } + + /** + * Checks if debug logging is enabled. + * @returns True if debug logs should be output + */ + public isDebug(): boolean { + return this.shouldLog(LogLevel.Debug); + } + + /** + * Logs a debug message if debug logging is enabled. + * @param message - The message to log + * @param args - Additional arguments to log + */ + public debug(message: string, ...args: unknown[]): void { + if (this.isDebug()) { + this.logger.debug(message, ...args); + } + } + + /** + * Checks if info logging is enabled. + * @returns True if info logs should be output + */ + public isInfo(): boolean { + return this.shouldLog(LogLevel.Info); + } + + /** + * Logs an info message if info logging is enabled. + * @param message - The message to log + * @param args - Additional arguments to log + */ + public info(message: string, ...args: unknown[]): void { + if (this.isInfo()) { + this.logger.info(message, ...args); + } + } + + /** + * Checks if warning logging is enabled. + * @returns True if warning logs should be output + */ + public isWarn(): boolean { + return this.shouldLog(LogLevel.Warn); + } + + /** + * Logs a warning message if warning logging is enabled. + * @param message - The message to log + * @param args - Additional arguments to log + */ + public warn(message: string, ...args: unknown[]): void { + if (this.isWarn()) { + this.logger.warn(message, ...args); + } + } + + /** + * Checks if error logging is enabled. + * @returns True if error logs should be output + */ + public isError(): boolean { + return this.shouldLog(LogLevel.Error); + } + + /** + * Logs an error message if error logging is enabled. + * @param message - The message to log + * @param args - Additional arguments to log + */ + public error(message: string, ...args: unknown[]): void { + if (this.isError()) { + this.logger.error(message, ...args); + } + } +} + +export function createLogger(config?: LogConfig | Logger): Logger { + if (config == null) { + return defaultLogger; + } + if (config instanceof Logger) { + return config; + } + config = config ?? {}; + config.level ??= LogLevel.Info; + config.logger ??= new ConsoleLogger(); + config.silent ??= true; + return new Logger(config as Required); +} + +const defaultLogger: Logger = new Logger({ + level: LogLevel.Info, + logger: new ConsoleLogger(), + silent: true, +}); diff --git a/src/core/pagination/Page.ts b/src/core/pagination/Page.ts index 30df7280..6621a6f1 100644 --- a/src/core/pagination/Page.ts +++ b/src/core/pagination/Page.ts @@ -1,18 +1,19 @@ -import { HttpResponsePromise, RawResponse } from "../fetcher"; +import type { HttpResponsePromise, RawResponse } from "../fetcher/index.js"; /** * A page of results from a paginated API. * * @template T The type of the items in the page. + * @template R The type of the API response. */ -export class Page implements AsyncIterable { +export class Page implements AsyncIterable { public data: T[]; public rawResponse: RawResponse; + public response: R; - private response: unknown; - private _hasNextPage: (response: unknown) => boolean; - private getItems: (response: unknown) => T[]; - private loadNextPage: (response: unknown) => HttpResponsePromise; + private _hasNextPage: (response: R) => boolean; + private getItems: (response: R) => T[]; + private loadNextPage: (response: R) => HttpResponsePromise; constructor({ response, @@ -21,11 +22,11 @@ export class Page implements AsyncIterable { getItems, loadPage, }: { - response: unknown; + response: R; rawResponse: RawResponse; - hasNextPage: (response: unknown) => boolean; - getItems: (response: unknown) => T[]; - loadPage: (response: unknown) => HttpResponsePromise; + hasNextPage: (response: R) => boolean; + getItems: (response: R) => T[]; + loadPage: (response: R) => HttpResponsePromise; }) { this.response = response; this.rawResponse = rawResponse; diff --git a/src/core/pagination/Pageable.ts b/src/core/pagination/Pageable.ts deleted file mode 100644 index 3a5220eb..00000000 --- a/src/core/pagination/Pageable.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { RawResponse } from "../fetcher"; -import { Page } from "./Page"; - -export declare namespace Pageable { - interface Args { - response: Response; - rawResponse: RawResponse; - hasNextPage: (response: Response) => boolean; - getItems: (response: Response) => Item[]; - loadPage: (response: Response) => Promise; - } -} - -export class Pageable extends Page { - constructor(args: Pageable.Args) { - super(args as any); - } -} diff --git a/src/core/pagination/exports.ts b/src/core/pagination/exports.ts new file mode 100644 index 00000000..d3acc60b --- /dev/null +++ b/src/core/pagination/exports.ts @@ -0,0 +1 @@ +export type { Page } from "./Page.js"; diff --git a/src/core/pagination/index.ts b/src/core/pagination/index.ts index 2ceb2684..7781cbd6 100644 --- a/src/core/pagination/index.ts +++ b/src/core/pagination/index.ts @@ -1,2 +1 @@ -export { Page } from "./Page"; -export { Pageable } from "./Pageable"; +export { Page } from "./Page.js"; diff --git a/src/core/runtime/index.ts b/src/core/runtime/index.ts index 5c76dbb1..cfab23f9 100644 --- a/src/core/runtime/index.ts +++ b/src/core/runtime/index.ts @@ -1 +1 @@ -export { RUNTIME } from "./runtime"; +export { RUNTIME } from "./runtime.js"; diff --git a/src/core/runtime/runtime.ts b/src/core/runtime/runtime.ts index a9750175..56ebbb87 100644 --- a/src/core/runtime/runtime.ts +++ b/src/core/runtime/runtime.ts @@ -11,6 +11,9 @@ interface BunGlobal { declare const Deno: DenoGlobal | undefined; declare const Bun: BunGlobal | undefined; declare const EdgeRuntime: string | undefined; +declare const self: typeof globalThis.self & { + importScripts?: unknown; +}; /** * A constant that indicates which environment and version the SDK is running in. @@ -62,7 +65,6 @@ function evaluateRuntime(): Runtime { */ const isWebWorker = typeof self === "object" && - // @ts-ignore typeof self?.importScripts === "function" && (self.constructor?.name === "DedicatedWorkerGlobalScope" || self.constructor?.name === "ServiceWorkerGlobalScope" || @@ -97,6 +99,18 @@ function evaluateRuntime(): Runtime { }; } + /** + * A constant that indicates whether the environment the code is running is in React-Native. + * This check should come before Node.js detection since React Native may have a process polyfill. + * https://github.com/facebook/react-native/blob/main/packages/react-native/Libraries/Core/setUpNavigator.js + */ + const isReactNative = typeof navigator !== "undefined" && navigator?.product === "ReactNative"; + if (isReactNative) { + return { + type: "react-native", + }; + } + /** * A constant that indicates whether the environment the code is running is Node.JS. */ @@ -114,17 +128,6 @@ function evaluateRuntime(): Runtime { }; } - /** - * A constant that indicates whether the environment the code is running is in React-Native. - * https://github.com/facebook/react-native/blob/main/packages/react-native/Libraries/Core/setUpNavigator.js - */ - const isReactNative = typeof navigator !== "undefined" && navigator?.product === "ReactNative"; - if (isReactNative) { - return { - type: "react-native", - }; - } - return { type: "unknown", }; diff --git a/src/core/url/encodePathParam.ts b/src/core/url/encodePathParam.ts new file mode 100644 index 00000000..19b90124 --- /dev/null +++ b/src/core/url/encodePathParam.ts @@ -0,0 +1,18 @@ +export function encodePathParam(param: unknown): string { + if (param === null) { + return "null"; + } + const typeofParam = typeof param; + switch (typeofParam) { + case "undefined": + return "undefined"; + case "string": + case "number": + case "boolean": + break; + default: + param = String(param); + break; + } + return encodeURIComponent(param as string | number | boolean); +} diff --git a/src/core/url/index.ts b/src/core/url/index.ts new file mode 100644 index 00000000..f2e0fa2d --- /dev/null +++ b/src/core/url/index.ts @@ -0,0 +1,3 @@ +export { encodePathParam } from "./encodePathParam.js"; +export { join } from "./join.js"; +export { toQueryString } from "./qs.js"; diff --git a/src/core/url/join.ts b/src/core/url/join.ts new file mode 100644 index 00000000..7ca7daef --- /dev/null +++ b/src/core/url/join.ts @@ -0,0 +1,79 @@ +export function join(base: string, ...segments: string[]): string { + if (!base) { + return ""; + } + + if (segments.length === 0) { + return base; + } + + if (base.includes("://")) { + let url: URL; + try { + url = new URL(base); + } catch { + return joinPath(base, ...segments); + } + + const lastSegment = segments[segments.length - 1]; + const shouldPreserveTrailingSlash = lastSegment?.endsWith("/"); + + for (const segment of segments) { + const cleanSegment = trimSlashes(segment); + if (cleanSegment) { + url.pathname = joinPathSegments(url.pathname, cleanSegment); + } + } + + if (shouldPreserveTrailingSlash && !url.pathname.endsWith("/")) { + url.pathname += "/"; + } + + return url.toString(); + } + + return joinPath(base, ...segments); +} + +function joinPath(base: string, ...segments: string[]): string { + if (segments.length === 0) { + return base; + } + + let result = base; + + const lastSegment = segments[segments.length - 1]; + const shouldPreserveTrailingSlash = lastSegment?.endsWith("/"); + + for (const segment of segments) { + const cleanSegment = trimSlashes(segment); + if (cleanSegment) { + result = joinPathSegments(result, cleanSegment); + } + } + + if (shouldPreserveTrailingSlash && !result.endsWith("/")) { + result += "/"; + } + + return result; +} + +function joinPathSegments(left: string, right: string): string { + if (left.endsWith("/")) { + return left + right; + } + return `${left}/${right}`; +} + +function trimSlashes(str: string): string { + if (!str) return str; + + let start = 0; + let end = str.length; + + if (str.startsWith("/")) start = 1; + if (str.endsWith("/")) end = str.length - 1; + + return start === 0 && end === str.length ? str : str.slice(start, end); +} diff --git a/src/core/url/qs.ts b/src/core/url/qs.ts new file mode 100644 index 00000000..13e89be9 --- /dev/null +++ b/src/core/url/qs.ts @@ -0,0 +1,74 @@ +interface QueryStringOptions { + arrayFormat?: "indices" | "repeat"; + encode?: boolean; +} + +const defaultQsOptions: Required = { + arrayFormat: "indices", + encode: true, +} as const; + +function encodeValue(value: unknown, shouldEncode: boolean): string { + if (value === undefined) { + return ""; + } + if (value === null) { + return ""; + } + const stringValue = String(value); + return shouldEncode ? encodeURIComponent(stringValue) : stringValue; +} + +function stringifyObject(obj: Record, prefix = "", options: Required): string[] { + const parts: string[] = []; + + for (const [key, value] of Object.entries(obj)) { + const fullKey = prefix ? `${prefix}[${key}]` : key; + + if (value === undefined) { + continue; + } + + if (Array.isArray(value)) { + if (value.length === 0) { + continue; + } + for (let i = 0; i < value.length; i++) { + const item = value[i]; + if (item === undefined) { + continue; + } + if (typeof item === "object" && !Array.isArray(item) && item !== null) { + const arrayKey = options.arrayFormat === "indices" ? `${fullKey}[${i}]` : fullKey; + parts.push(...stringifyObject(item as Record, arrayKey, options)); + } else { + const arrayKey = options.arrayFormat === "indices" ? `${fullKey}[${i}]` : fullKey; + const encodedKey = options.encode ? encodeURIComponent(arrayKey) : arrayKey; + parts.push(`${encodedKey}=${encodeValue(item, options.encode)}`); + } + } + } else if (typeof value === "object" && value !== null) { + if (Object.keys(value as Record).length === 0) { + continue; + } + parts.push(...stringifyObject(value as Record, fullKey, options)); + } else { + const encodedKey = options.encode ? encodeURIComponent(fullKey) : fullKey; + parts.push(`${encodedKey}=${encodeValue(value, options.encode)}`); + } + } + + return parts; +} + +export function toQueryString(obj: unknown, options?: QueryStringOptions): string { + if (obj == null || typeof obj !== "object") { + return ""; + } + + const parts = stringifyObject(obj as Record, "", { + ...defaultQsOptions, + ...options, + }); + return parts.join("&"); +} diff --git a/src/core/utils/index.ts b/src/core/utils/index.ts index b168f599..11ff8f25 100644 --- a/src/core/utils/index.ts +++ b/src/core/utils/index.ts @@ -1 +1 @@ -export { setObjectProperty } from "./setObjectProperty"; +export { setObjectProperty } from "./setObjectProperty.js"; diff --git a/src/environments.ts b/src/environments.ts index d2816275..752460d1 100644 --- a/src/environments.ts +++ b/src/environments.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export const IntercomEnvironment = { UsProduction: "https://api.intercom.io", diff --git a/src/errors/IntercomError.ts b/src/errors/IntercomError.ts index 0f91cad3..de63f5e0 100644 --- a/src/errors/IntercomError.ts +++ b/src/errors/IntercomError.ts @@ -1,9 +1,7 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. -import * as core from "../core"; -import { toJson } from "../core/json"; +import type * as core from "../core/index.js"; +import { toJson } from "../core/json.js"; export class IntercomError extends Error { public readonly statusCode?: number; @@ -38,7 +36,7 @@ function buildMessage({ statusCode: number | undefined; body: unknown | undefined; }): string { - let lines: string[] = []; + const lines: string[] = []; if (message != null) { lines.push(message); } diff --git a/src/errors/IntercomTimeoutError.ts b/src/errors/IntercomTimeoutError.ts index 52bd429f..e0c388db 100644 --- a/src/errors/IntercomTimeoutError.ts +++ b/src/errors/IntercomTimeoutError.ts @@ -1,6 +1,4 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ +// This file was auto-generated by Fern from our API Definition. export class IntercomTimeoutError extends Error { constructor(message: string) { diff --git a/src/errors/handleNonStatusCodeError.ts b/src/errors/handleNonStatusCodeError.ts new file mode 100644 index 00000000..75076b10 --- /dev/null +++ b/src/errors/handleNonStatusCodeError.ts @@ -0,0 +1,37 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as core from "../core/index.js"; +import * as errors from "./index.js"; + +export function handleNonStatusCodeError( + error: core.Fetcher.Error, + rawResponse: core.RawResponse, + method: string, + path: string, +): never { + switch (error.reason) { + case "non-json": + throw new errors.IntercomError({ + statusCode: error.statusCode, + body: error.rawBody, + rawResponse: rawResponse, + }); + case "body-is-null": + throw new errors.IntercomError({ + statusCode: error.statusCode, + rawResponse: rawResponse, + }); + case "timeout": + throw new errors.IntercomTimeoutError(`Timeout exceeded when calling ${method} ${path}.`); + case "unknown": + throw new errors.IntercomError({ + message: error.errorMessage, + rawResponse: rawResponse, + }); + default: + throw new errors.IntercomError({ + message: "Unknown error", + rawResponse: rawResponse, + }); + } +} diff --git a/src/errors/index.ts b/src/errors/index.ts index 25abf2ea..280a57f9 100644 --- a/src/errors/index.ts +++ b/src/errors/index.ts @@ -1,2 +1,2 @@ -export { IntercomError } from "./IntercomError"; -export { IntercomTimeoutError } from "./IntercomTimeoutError"; +export { IntercomError } from "./IntercomError.js"; +export { IntercomTimeoutError } from "./IntercomTimeoutError.js"; diff --git a/src/exports.ts b/src/exports.ts new file mode 100644 index 00000000..7b70ee14 --- /dev/null +++ b/src/exports.ts @@ -0,0 +1 @@ +export * from "./core/exports.js"; diff --git a/src/index.ts b/src/index.ts index 5394f30c..e8fc688d 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,4 +1,6 @@ -export * as Intercom from "./api"; -export { IntercomClient } from "./Client"; -export { IntercomEnvironment } from "./environments"; -export { IntercomError, IntercomTimeoutError } from "./errors"; +export * as Intercom from "./api/index.js"; +export type { BaseClientOptions, BaseRequestOptions } from "./BaseClient.js"; +export { IntercomClient } from "./Client.js"; +export { IntercomEnvironment } from "./environments.js"; +export { IntercomError, IntercomTimeoutError } from "./errors/index.js"; +export * from "./exports.js"; diff --git a/src/version.ts b/src/version.ts index 1420c168..6bb53d57 100644 --- a/src/version.ts +++ b/src/version.ts @@ -1 +1 @@ -export const SDK_VERSION = "6.4.0"; +export const SDK_VERSION = "7.0.0"; diff --git a/tests/integration/conversations.test.ts b/tests/integration/conversations.test.ts index 474b318b..fed0a9b9 100644 --- a/tests/integration/conversations.test.ts +++ b/tests/integration/conversations.test.ts @@ -168,11 +168,12 @@ describe("Conversations", () => { }); it("run assignment rules", async () => { + const legacyClient = createClient({ version: "2.11" }); // arrange - const message = await createConversation(client, user.id); + const message = await createConversation(legacyClient, user.id); // act - const response = await client.conversations.runAssignmentRules({ + const response = await legacyClient.conversations.runAssignmentRules({ conversation_id: message.conversation_id, }); diff --git a/tests/integration/dataAttributes.test.ts b/tests/integration/dataAttributes.test.ts index 22c3ca10..f5889fa2 100644 --- a/tests/integration/dataAttributes.test.ts +++ b/tests/integration/dataAttributes.test.ts @@ -13,7 +13,7 @@ describe("Data Attributes", () => { randomDataAttribute = attributes.data.find((attribute) => attribute.id !== undefined); }); - xit("create", async () => { + it.skip("create", async () => { //act // The workspace we test on has hit the CDA limit, so we can't create any more diff --git a/tests/integration/utils/createClient.ts b/tests/integration/utils/createClient.ts index 4b2c5475..f2662688 100644 --- a/tests/integration/utils/createClient.ts +++ b/tests/integration/utils/createClient.ts @@ -1,5 +1,11 @@ -import { IntercomClient } from "../../../src"; +import { type Intercom, IntercomClient } from "../../../src"; -export function createClient(): IntercomClient { - return new IntercomClient({ token: process.env.API_TOKEN as string }); +type IntercomVersion = Intercom.IntercomVersion; + +export function createClient(options?: { version?: IntercomVersion }): IntercomClient { + const { version } = options || {}; + return new IntercomClient({ + token: process.env.API_TOKEN as string, + version, + }); } diff --git a/tests/mock-server/MockServer.ts b/tests/mock-server/MockServer.ts new file mode 100644 index 00000000..95487215 --- /dev/null +++ b/tests/mock-server/MockServer.ts @@ -0,0 +1,29 @@ +import type { RequestHandlerOptions } from "msw"; +import type { SetupServer } from "msw/node"; + +import { mockEndpointBuilder } from "./mockEndpointBuilder"; + +export interface MockServerOptions { + baseUrl: string; + server: SetupServer; +} + +export class MockServer { + private readonly server: SetupServer; + public readonly baseUrl: string; + + constructor({ baseUrl, server }: MockServerOptions) { + this.baseUrl = baseUrl.endsWith("/") ? baseUrl.slice(0, -1) : baseUrl; + this.server = server; + } + + public mockEndpoint(options?: RequestHandlerOptions): ReturnType { + const builder = mockEndpointBuilder({ + once: options?.once ?? true, + onBuild: (handler) => { + this.server.use(handler); + }, + }).baseUrl(this.baseUrl); + return builder; + } +} diff --git a/tests/mock-server/MockServerPool.ts b/tests/mock-server/MockServerPool.ts new file mode 100644 index 00000000..e1a90f7f --- /dev/null +++ b/tests/mock-server/MockServerPool.ts @@ -0,0 +1,106 @@ +import { setupServer } from "msw/node"; + +import { fromJson, toJson } from "../../src/core/json"; +import { MockServer } from "./MockServer"; +import { randomBaseUrl } from "./randomBaseUrl"; + +const mswServer = setupServer(); +interface MockServerOptions { + baseUrl?: string; +} + +async function formatHttpRequest(request: Request, id?: string): Promise { + try { + const clone = request.clone(); + const headers = [...clone.headers.entries()].map(([k, v]) => `${k}: ${v}`).join("\n"); + + let body = ""; + try { + const contentType = clone.headers.get("content-type"); + if (contentType?.includes("application/json")) { + body = toJson(fromJson(await clone.text()), undefined, 2); + } else if (clone.body) { + body = await clone.text(); + } + } catch (_e) { + body = "(unable to parse body)"; + } + + const title = id ? `### Request ${id} ###\n` : ""; + const firstLine = `${title}${request.method} ${request.url.toString()} HTTP/1.1`; + + return `\n${firstLine}\n${headers}\n\n${body || "(no body)"}\n`; + } catch (e) { + return `Error formatting request: ${e}`; + } +} + +async function formatHttpResponse(response: Response, id?: string): Promise { + try { + const clone = response.clone(); + const headers = [...clone.headers.entries()].map(([k, v]) => `${k}: ${v}`).join("\n"); + + let body = ""; + try { + const contentType = clone.headers.get("content-type"); + if (contentType?.includes("application/json")) { + body = toJson(fromJson(await clone.text()), undefined, 2); + } else if (clone.body) { + body = await clone.text(); + } + } catch (_e) { + body = "(unable to parse body)"; + } + + const title = id ? `### Response for ${id} ###\n` : ""; + const firstLine = `${title}HTTP/1.1 ${response.status} ${response.statusText}`; + + return `\n${firstLine}\n${headers}\n\n${body || "(no body)"}\n`; + } catch (e) { + return `Error formatting response: ${e}`; + } +} + +class MockServerPool { + private servers: MockServer[] = []; + + public createServer(options?: Partial): MockServer { + const baseUrl = options?.baseUrl || randomBaseUrl(); + const server = new MockServer({ baseUrl, server: mswServer }); + this.servers.push(server); + return server; + } + + public getServers(): MockServer[] { + return [...this.servers]; + } + + public listen(): void { + const onUnhandledRequest = process.env.LOG_LEVEL === "debug" ? "warn" : "bypass"; + mswServer.listen({ onUnhandledRequest }); + + if (process.env.LOG_LEVEL === "debug") { + mswServer.events.on("request:start", async ({ request, requestId }) => { + const formattedRequest = await formatHttpRequest(request, requestId); + console.debug(`request:start\n${formattedRequest}`); + }); + + mswServer.events.on("request:unhandled", async ({ request, requestId }) => { + const formattedRequest = await formatHttpRequest(request, requestId); + console.debug(`request:unhandled\n${formattedRequest}`); + }); + + mswServer.events.on("response:mocked", async ({ request, response, requestId }) => { + const formattedResponse = await formatHttpResponse(response, requestId); + console.debug(`response:mocked\n${formattedResponse}`); + }); + } + } + + public close(): void { + this.servers = []; + mswServer.close(); + } +} + +export const mockServerPool = new MockServerPool(); diff --git a/tests/mock-server/mockEndpointBuilder.ts b/tests/mock-server/mockEndpointBuilder.ts new file mode 100644 index 00000000..1b0e5107 --- /dev/null +++ b/tests/mock-server/mockEndpointBuilder.ts @@ -0,0 +1,227 @@ +import { type DefaultBodyType, type HttpHandler, HttpResponse, type HttpResponseResolver, http } from "msw"; + +import { url } from "../../src/core"; +import { toJson } from "../../src/core/json"; +import { withFormUrlEncoded } from "./withFormUrlEncoded"; +import { withHeaders } from "./withHeaders"; +import { withJson } from "./withJson"; + +type HttpMethod = "all" | "get" | "post" | "put" | "delete" | "patch" | "options" | "head"; + +interface MethodStage { + baseUrl(baseUrl: string): MethodStage; + all(path: string): RequestHeadersStage; + get(path: string): RequestHeadersStage; + post(path: string): RequestHeadersStage; + put(path: string): RequestHeadersStage; + delete(path: string): RequestHeadersStage; + patch(path: string): RequestHeadersStage; + options(path: string): RequestHeadersStage; + head(path: string): RequestHeadersStage; +} + +interface RequestHeadersStage extends RequestBodyStage, ResponseStage { + header(name: string, value: string): RequestHeadersStage; + headers(headers: Record): RequestBodyStage; +} + +interface RequestBodyStage extends ResponseStage { + jsonBody(body: unknown): ResponseStage; + formUrlEncodedBody(body: unknown): ResponseStage; +} + +interface ResponseStage { + respondWith(): ResponseStatusStage; +} +interface ResponseStatusStage { + statusCode(statusCode: number): ResponseHeaderStage; +} + +interface ResponseHeaderStage extends ResponseBodyStage, BuildStage { + header(name: string, value: string): ResponseHeaderStage; + headers(headers: Record): ResponseHeaderStage; +} + +interface ResponseBodyStage { + jsonBody(body: unknown): BuildStage; +} + +interface BuildStage { + build(): HttpHandler; +} + +export interface HttpHandlerBuilderOptions { + onBuild?: (handler: HttpHandler) => void; + once?: boolean; +} + +class RequestBuilder implements MethodStage, RequestHeadersStage, RequestBodyStage, ResponseStage { + private method: HttpMethod = "get"; + private _baseUrl: string = ""; + private path: string = "/"; + private readonly predicates: ((resolver: HttpResponseResolver) => HttpResponseResolver)[] = []; + private readonly handlerOptions?: HttpHandlerBuilderOptions; + + constructor(options?: HttpHandlerBuilderOptions) { + this.handlerOptions = options; + } + + baseUrl(baseUrl: string): MethodStage { + this._baseUrl = baseUrl; + return this; + } + + all(path: string): RequestHeadersStage { + this.method = "all"; + this.path = path; + return this; + } + + get(path: string): RequestHeadersStage { + this.method = "get"; + this.path = path; + return this; + } + + post(path: string): RequestHeadersStage { + this.method = "post"; + this.path = path; + return this; + } + + put(path: string): RequestHeadersStage { + this.method = "put"; + this.path = path; + return this; + } + + delete(path: string): RequestHeadersStage { + this.method = "delete"; + this.path = path; + return this; + } + + patch(path: string): RequestHeadersStage { + this.method = "patch"; + this.path = path; + return this; + } + + options(path: string): RequestHeadersStage { + this.method = "options"; + this.path = path; + return this; + } + + head(path: string): RequestHeadersStage { + this.method = "head"; + this.path = path; + return this; + } + + header(name: string, value: string): RequestHeadersStage { + this.predicates.push((resolver) => withHeaders({ [name]: value }, resolver)); + return this; + } + + headers(headers: Record): RequestBodyStage { + this.predicates.push((resolver) => withHeaders(headers, resolver)); + return this; + } + + jsonBody(body: unknown): ResponseStage { + if (body === undefined) { + throw new Error("Undefined is not valid JSON. Do not call jsonBody if you want an empty body."); + } + this.predicates.push((resolver) => withJson(body, resolver)); + return this; + } + + formUrlEncodedBody(body: unknown): ResponseStage { + if (body === undefined) { + throw new Error( + "Undefined is not valid for form-urlencoded. Do not call formUrlEncodedBody if you want an empty body.", + ); + } + this.predicates.push((resolver) => withFormUrlEncoded(body, resolver)); + return this; + } + + respondWith(): ResponseStatusStage { + return new ResponseBuilder(this.method, this.buildUrl(), this.predicates, this.handlerOptions); + } + + private buildUrl(): string { + return url.join(this._baseUrl, this.path); + } +} + +class ResponseBuilder implements ResponseStatusStage, ResponseHeaderStage, ResponseBodyStage, BuildStage { + private readonly method: HttpMethod; + private readonly url: string; + private readonly requestPredicates: ((resolver: HttpResponseResolver) => HttpResponseResolver)[]; + private readonly handlerOptions?: HttpHandlerBuilderOptions; + + private responseStatusCode: number = 200; + private responseHeaders: Record = {}; + private responseBody: DefaultBodyType = undefined; + + constructor( + method: HttpMethod, + url: string, + requestPredicates: ((resolver: HttpResponseResolver) => HttpResponseResolver)[], + options?: HttpHandlerBuilderOptions, + ) { + this.method = method; + this.url = url; + this.requestPredicates = requestPredicates; + this.handlerOptions = options; + } + + public statusCode(code: number): ResponseHeaderStage { + this.responseStatusCode = code; + return this; + } + + public header(name: string, value: string): ResponseHeaderStage { + this.responseHeaders[name] = value; + return this; + } + + public headers(headers: Record): ResponseHeaderStage { + this.responseHeaders = { ...this.responseHeaders, ...headers }; + return this; + } + + public jsonBody(body: unknown): BuildStage { + if (body === undefined) { + throw new Error("Undefined is not valid JSON. Do not call jsonBody if you expect an empty body."); + } + this.responseBody = toJson(body); + return this; + } + + public build(): HttpHandler { + const responseResolver: HttpResponseResolver = () => { + const response = new HttpResponse(this.responseBody, { + status: this.responseStatusCode, + headers: this.responseHeaders, + }); + // if no Content-Type header is set, delete the default text content type that is set + if (Object.keys(this.responseHeaders).some((key) => key.toLowerCase() === "content-type") === false) { + response.headers.delete("Content-Type"); + } + return response; + }; + + const finalResolver = this.requestPredicates.reduceRight((acc, predicate) => predicate(acc), responseResolver); + + const handler = http[this.method](this.url, finalResolver, this.handlerOptions); + this.handlerOptions?.onBuild?.(handler); + return handler; + } +} + +export function mockEndpointBuilder(options?: HttpHandlerBuilderOptions): MethodStage { + return new RequestBuilder(options); +} diff --git a/tests/mock-server/randomBaseUrl.ts b/tests/mock-server/randomBaseUrl.ts new file mode 100644 index 00000000..031aa640 --- /dev/null +++ b/tests/mock-server/randomBaseUrl.ts @@ -0,0 +1,4 @@ +export function randomBaseUrl(): string { + const randomString = Math.random().toString(36).substring(2, 15); + return `http://${randomString}.localhost`; +} diff --git a/tests/mock-server/setup.ts b/tests/mock-server/setup.ts new file mode 100644 index 00000000..aeb3a95a --- /dev/null +++ b/tests/mock-server/setup.ts @@ -0,0 +1,10 @@ +import { afterAll, beforeAll } from "vitest"; + +import { mockServerPool } from "./MockServerPool"; + +beforeAll(() => { + mockServerPool.listen(); +}); +afterAll(() => { + mockServerPool.close(); +}); diff --git a/tests/mock-server/withFormUrlEncoded.ts b/tests/mock-server/withFormUrlEncoded.ts new file mode 100644 index 00000000..e9e6ff2d --- /dev/null +++ b/tests/mock-server/withFormUrlEncoded.ts @@ -0,0 +1,80 @@ +import { type HttpResponseResolver, passthrough } from "msw"; + +import { toJson } from "../../src/core/json"; + +/** + * Creates a request matcher that validates if the request form-urlencoded body exactly matches the expected object + * @param expectedBody - The exact body object to match against + * @param resolver - Response resolver to execute if body matches + */ +export function withFormUrlEncoded(expectedBody: unknown, resolver: HttpResponseResolver): HttpResponseResolver { + return async (args) => { + const { request } = args; + + let clonedRequest: Request; + let bodyText: string | undefined; + let actualBody: Record; + try { + clonedRequest = request.clone(); + bodyText = await clonedRequest.text(); + if (bodyText === "") { + console.error("Request body is empty, expected a form-urlencoded body."); + return passthrough(); + } + const params = new URLSearchParams(bodyText); + actualBody = {}; + for (const [key, value] of params.entries()) { + actualBody[key] = value; + } + } catch (error) { + console.error(`Error processing form-urlencoded request body:\n\tError: ${error}\n\tBody: ${bodyText}`); + return passthrough(); + } + + const mismatches = findMismatches(actualBody, expectedBody); + if (Object.keys(mismatches).length > 0) { + console.error("Form-urlencoded body mismatch:", toJson(mismatches, undefined, 2)); + return passthrough(); + } + + return resolver(args); + }; +} + +function findMismatches(actual: any, expected: any): Record { + const mismatches: Record = {}; + + if (typeof actual !== typeof expected) { + return { value: { actual, expected } }; + } + + if (typeof actual !== "object" || actual === null || expected === null) { + if (actual !== expected) { + return { value: { actual, expected } }; + } + return {}; + } + + const actualKeys = Object.keys(actual); + const expectedKeys = Object.keys(expected); + + const allKeys = new Set([...actualKeys, ...expectedKeys]); + + for (const key of allKeys) { + if (!expectedKeys.includes(key)) { + if (actual[key] === undefined) { + continue; + } + mismatches[key] = { actual: actual[key], expected: undefined }; + } else if (!actualKeys.includes(key)) { + if (expected[key] === undefined) { + continue; + } + mismatches[key] = { actual: undefined, expected: expected[key] }; + } else if (actual[key] !== expected[key]) { + mismatches[key] = { actual: actual[key], expected: expected[key] }; + } + } + + return mismatches; +} diff --git a/tests/mock-server/withHeaders.ts b/tests/mock-server/withHeaders.ts new file mode 100644 index 00000000..6599d2b4 --- /dev/null +++ b/tests/mock-server/withHeaders.ts @@ -0,0 +1,70 @@ +import { type HttpResponseResolver, passthrough } from "msw"; + +/** + * Creates a request matcher that validates if request headers match specified criteria + * @param expectedHeaders - Headers to match against + * @param resolver - Response resolver to execute if headers match + */ +export function withHeaders( + expectedHeaders: Record boolean)>, + resolver: HttpResponseResolver, +): HttpResponseResolver { + return (args) => { + const { request } = args; + const { headers } = request; + + const mismatches: Record< + string, + { actual: string | null; expected: string | RegExp | ((value: string) => boolean) } + > = {}; + + for (const [key, expectedValue] of Object.entries(expectedHeaders)) { + const actualValue = headers.get(key); + + if (actualValue === null) { + mismatches[key] = { actual: null, expected: expectedValue }; + continue; + } + + if (typeof expectedValue === "function") { + if (!expectedValue(actualValue)) { + mismatches[key] = { actual: actualValue, expected: expectedValue }; + } + } else if (expectedValue instanceof RegExp) { + if (!expectedValue.test(actualValue)) { + mismatches[key] = { actual: actualValue, expected: expectedValue }; + } + } else if (expectedValue !== actualValue) { + mismatches[key] = { actual: actualValue, expected: expectedValue }; + } + } + + if (Object.keys(mismatches).length > 0) { + const formattedMismatches = formatHeaderMismatches(mismatches); + console.error("Header mismatch:", formattedMismatches); + return passthrough(); + } + + return resolver(args); + }; +} + +function formatHeaderMismatches( + mismatches: Record boolean) }>, +): Record { + const formatted: Record = {}; + + for (const [key, { actual, expected }] of Object.entries(mismatches)) { + formatted[key] = { + actual, + expected: + expected instanceof RegExp + ? expected.toString() + : typeof expected === "function" + ? "[Function]" + : expected, + }; + } + + return formatted; +} diff --git a/tests/mock-server/withJson.ts b/tests/mock-server/withJson.ts new file mode 100644 index 00000000..b627638b --- /dev/null +++ b/tests/mock-server/withJson.ts @@ -0,0 +1,158 @@ +import { type HttpResponseResolver, passthrough } from "msw"; + +import { fromJson, toJson } from "../../src/core/json"; + +/** + * Creates a request matcher that validates if the request JSON body exactly matches the expected object + * @param expectedBody - The exact body object to match against + * @param resolver - Response resolver to execute if body matches + */ +export function withJson(expectedBody: unknown, resolver: HttpResponseResolver): HttpResponseResolver { + return async (args) => { + const { request } = args; + + let clonedRequest: Request; + let bodyText: string | undefined; + let actualBody: unknown; + try { + clonedRequest = request.clone(); + bodyText = await clonedRequest.text(); + if (bodyText === "") { + console.error("Request body is empty, expected a JSON object."); + return passthrough(); + } + actualBody = fromJson(bodyText); + } catch (error) { + console.error(`Error processing request body:\n\tError: ${error}\n\tBody: ${bodyText}`); + return passthrough(); + } + + const mismatches = findMismatches(actualBody, expectedBody); + if (Object.keys(mismatches).filter((key) => !key.startsWith("pagination.")).length > 0) { + console.error("JSON body mismatch:", toJson(mismatches, undefined, 2)); + return passthrough(); + } + + return resolver(args); + }; +} + +function findMismatches(actual: any, expected: any): Record { + const mismatches: Record = {}; + + if (typeof actual !== typeof expected) { + if (areEquivalent(actual, expected)) { + return {}; + } + return { value: { actual, expected } }; + } + + if (typeof actual !== "object" || actual === null || expected === null) { + if (actual !== expected) { + if (areEquivalent(actual, expected)) { + return {}; + } + return { value: { actual, expected } }; + } + return {}; + } + + if (Array.isArray(actual) && Array.isArray(expected)) { + if (actual.length !== expected.length) { + return { length: { actual: actual.length, expected: expected.length } }; + } + + const arrayMismatches: Record = {}; + for (let i = 0; i < actual.length; i++) { + const itemMismatches = findMismatches(actual[i], expected[i]); + if (Object.keys(itemMismatches).length > 0) { + for (const [mismatchKey, mismatchValue] of Object.entries(itemMismatches)) { + arrayMismatches[`[${i}]${mismatchKey === "value" ? "" : `.${mismatchKey}`}`] = mismatchValue; + } + } + } + return arrayMismatches; + } + + const actualKeys = Object.keys(actual); + const expectedKeys = Object.keys(expected); + + const allKeys = new Set([...actualKeys, ...expectedKeys]); + + for (const key of allKeys) { + if (!expectedKeys.includes(key)) { + if (actual[key] === undefined) { + continue; // Skip undefined values in actual + } + mismatches[key] = { actual: actual[key], expected: undefined }; + } else if (!actualKeys.includes(key)) { + if (expected[key] === undefined) { + continue; // Skip undefined values in expected + } + mismatches[key] = { actual: undefined, expected: expected[key] }; + } else if ( + typeof actual[key] === "object" && + actual[key] !== null && + typeof expected[key] === "object" && + expected[key] !== null + ) { + const nestedMismatches = findMismatches(actual[key], expected[key]); + if (Object.keys(nestedMismatches).length > 0) { + for (const [nestedKey, nestedValue] of Object.entries(nestedMismatches)) { + mismatches[`${key}${nestedKey === "value" ? "" : `.${nestedKey}`}`] = nestedValue; + } + } + } else if (actual[key] !== expected[key]) { + if (areEquivalent(actual[key], expected[key])) { + continue; + } + mismatches[key] = { actual: actual[key], expected: expected[key] }; + } + } + + return mismatches; +} + +function areEquivalent(actual: unknown, expected: unknown): boolean { + if (actual === expected) { + return true; + } + if (isEquivalentBigInt(actual, expected)) { + return true; + } + if (isEquivalentDatetime(actual, expected)) { + return true; + } + return false; +} + +function isEquivalentBigInt(actual: unknown, expected: unknown) { + if (typeof actual === "number") { + actual = BigInt(actual); + } + if (typeof expected === "number") { + expected = BigInt(expected); + } + if (typeof actual === "bigint" && typeof expected === "bigint") { + return actual === expected; + } + return false; +} + +function isEquivalentDatetime(str1: unknown, str2: unknown): boolean { + if (typeof str1 !== "string" || typeof str2 !== "string") { + return false; + } + const isoDatePattern = /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(?:\.\d{3})?Z$/; + if (!isoDatePattern.test(str1) || !isoDatePattern.test(str2)) { + return false; + } + + try { + const date1 = new Date(str1).getTime(); + const date2 = new Date(str2).getTime(); + return date1 === date2; + } catch { + return false; + } +} diff --git a/tests/setup.ts b/tests/setup.ts new file mode 100644 index 00000000..a5651f81 --- /dev/null +++ b/tests/setup.ts @@ -0,0 +1,80 @@ +import { expect } from "vitest"; + +interface CustomMatchers { + toContainHeaders(expectedHeaders: Record): R; +} + +declare module "vitest" { + interface Assertion extends CustomMatchers {} + interface AsymmetricMatchersContaining extends CustomMatchers {} +} + +expect.extend({ + toContainHeaders(actual: unknown, expectedHeaders: Record) { + const isHeaders = actual instanceof Headers; + const isPlainObject = typeof actual === "object" && actual !== null && !Array.isArray(actual); + + if (!isHeaders && !isPlainObject) { + throw new TypeError("Received value must be an instance of Headers or a plain object!"); + } + + if (typeof expectedHeaders !== "object" || expectedHeaders === null || Array.isArray(expectedHeaders)) { + throw new TypeError("Expected headers must be a plain object!"); + } + + const missingHeaders: string[] = []; + const mismatchedHeaders: Array<{ key: string; expected: string; actual: string | null }> = []; + + for (const [key, value] of Object.entries(expectedHeaders)) { + let actualValue: string | null = null; + + if (isHeaders) { + // Headers.get() is already case-insensitive + actualValue = (actual as Headers).get(key); + } else { + // For plain objects, do case-insensitive lookup + const actualObj = actual as Record; + const lowerKey = key.toLowerCase(); + const foundKey = Object.keys(actualObj).find((k) => k.toLowerCase() === lowerKey); + actualValue = foundKey ? actualObj[foundKey] : null; + } + + if (actualValue === null || actualValue === undefined) { + missingHeaders.push(key); + } else if (actualValue !== value) { + mismatchedHeaders.push({ key, expected: value, actual: actualValue }); + } + } + + const pass = missingHeaders.length === 0 && mismatchedHeaders.length === 0; + + const actualType = isHeaders ? "Headers" : "object"; + + if (pass) { + return { + message: () => `expected ${actualType} not to contain ${this.utils.printExpected(expectedHeaders)}`, + pass: true, + }; + } else { + const messages: string[] = []; + + if (missingHeaders.length > 0) { + messages.push(`Missing headers: ${this.utils.printExpected(missingHeaders.join(", "))}`); + } + + if (mismatchedHeaders.length > 0) { + const mismatches = mismatchedHeaders.map( + ({ key, expected, actual }) => + `${key}: expected ${this.utils.printExpected(expected)} but got ${this.utils.printReceived(actual)}`, + ); + messages.push(mismatches.join("\n")); + } + + return { + message: () => + `expected ${actualType} to contain ${this.utils.printExpected(expectedHeaders)}\n\n${messages.join("\n")}`, + pass: false, + }; + } + }, +}); diff --git a/tests/tsconfig.json b/tests/tsconfig.json new file mode 100644 index 00000000..a477df47 --- /dev/null +++ b/tests/tsconfig.json @@ -0,0 +1,11 @@ +{ + "extends": "../tsconfig.base.json", + "compilerOptions": { + "outDir": null, + "rootDir": "..", + "baseUrl": "..", + "types": ["vitest/globals"] + }, + "include": ["../src", "../tests"], + "exclude": [] +} diff --git a/tests/unit/auth/BasicAuth.test.ts b/tests/unit/auth/BasicAuth.test.ts index 79ef9799..9b512336 100644 --- a/tests/unit/auth/BasicAuth.test.ts +++ b/tests/unit/auth/BasicAuth.test.ts @@ -1,21 +1,91 @@ import { BasicAuth } from "../../../src/core/auth/BasicAuth"; describe("BasicAuth", () => { + interface ToHeaderTestCase { + description: string; + input: { username: string; password: string }; + expected: string; + } + + interface FromHeaderTestCase { + description: string; + input: string; + expected: { username: string; password: string }; + } + + interface ErrorTestCase { + description: string; + input: string; + expectedError: string; + } + describe("toAuthorizationHeader", () => { - it("correctly converts to header", () => { - expect( - BasicAuth.toAuthorizationHeader({ - username: "username", - password: "password", - }), - ).toBe("Basic dXNlcm5hbWU6cGFzc3dvcmQ="); + const toHeaderTests: ToHeaderTestCase[] = [ + { + description: "correctly converts to header", + input: { username: "username", password: "password" }, + expected: "Basic dXNlcm5hbWU6cGFzc3dvcmQ=", + }, + ]; + + toHeaderTests.forEach(({ description, input, expected }) => { + it(description, () => { + expect(BasicAuth.toAuthorizationHeader(input)).toBe(expected); + }); }); }); + describe("fromAuthorizationHeader", () => { - it("correctly parses header", () => { - expect(BasicAuth.fromAuthorizationHeader("Basic dXNlcm5hbWU6cGFzc3dvcmQ=")).toEqual({ - username: "username", - password: "password", + const fromHeaderTests: FromHeaderTestCase[] = [ + { + description: "correctly parses header", + input: "Basic dXNlcm5hbWU6cGFzc3dvcmQ=", + expected: { username: "username", password: "password" }, + }, + { + description: "handles password with colons", + input: "Basic dXNlcjpwYXNzOndvcmQ=", + expected: { username: "user", password: "pass:word" }, + }, + { + description: "handles empty username and password (just colon)", + input: "Basic Og==", + expected: { username: "", password: "" }, + }, + { + description: "handles empty username", + input: "Basic OnBhc3N3b3Jk", + expected: { username: "", password: "password" }, + }, + { + description: "handles empty password", + input: "Basic dXNlcm5hbWU6", + expected: { username: "username", password: "" }, + }, + ]; + + fromHeaderTests.forEach(({ description, input, expected }) => { + it(description, () => { + expect(BasicAuth.fromAuthorizationHeader(input)).toEqual(expected); + }); + }); + + const errorTests: ErrorTestCase[] = [ + { + description: "throws error for completely empty credentials", + input: "Basic ", + expectedError: "Invalid basic auth", + }, + { + description: "throws error for credentials without colon", + input: "Basic dXNlcm5hbWU=", + expectedError: "Invalid basic auth", + }, + ]; + + errorTests.forEach(({ description, input, expectedError }) => { + it(description, () => { + expect(() => BasicAuth.fromAuthorizationHeader(input)).toThrow(expectedError); }); }); }); diff --git a/tests/unit/base64.test.ts b/tests/unit/base64.test.ts new file mode 100644 index 00000000..939594ca --- /dev/null +++ b/tests/unit/base64.test.ts @@ -0,0 +1,53 @@ +import { base64Decode, base64Encode } from "../../src/core/base64"; + +describe("base64", () => { + describe("base64Encode", () => { + it("should encode ASCII strings", () => { + expect(base64Encode("hello")).toBe("aGVsbG8="); + expect(base64Encode("")).toBe(""); + }); + + it("should encode UTF-8 strings", () => { + expect(base64Encode("café")).toBe("Y2Fmw6k="); + expect(base64Encode("🎉")).toBe("8J+OiQ=="); + }); + + it("should handle basic auth credentials", () => { + expect(base64Encode("username:password")).toBe("dXNlcm5hbWU6cGFzc3dvcmQ="); + }); + }); + + describe("base64Decode", () => { + it("should decode ASCII strings", () => { + expect(base64Decode("aGVsbG8=")).toBe("hello"); + expect(base64Decode("")).toBe(""); + }); + + it("should decode UTF-8 strings", () => { + expect(base64Decode("Y2Fmw6k=")).toBe("café"); + expect(base64Decode("8J+OiQ==")).toBe("🎉"); + }); + + it("should handle basic auth credentials", () => { + expect(base64Decode("dXNlcm5hbWU6cGFzc3dvcmQ=")).toBe("username:password"); + }); + }); + + describe("round-trip encoding", () => { + const testStrings = [ + "hello world", + "test@example.com", + "café", + "username:password", + "user@domain.com:super$ecret123!", + ]; + + testStrings.forEach((testString) => { + it(`should round-trip encode/decode: "${testString}"`, () => { + const encoded = base64Encode(testString); + const decoded = base64Decode(encoded); + expect(decoded).toBe(testString); + }); + }); + }); +}); diff --git a/tests/unit/fetcher/Fetcher.test.ts b/tests/unit/fetcher/Fetcher.test.ts index a32945e9..60df2b5e 100644 --- a/tests/unit/fetcher/Fetcher.test.ts +++ b/tests/unit/fetcher/Fetcher.test.ts @@ -1,7 +1,8 @@ import fs from "fs"; import { join } from "path"; - -import { Fetcher, fetcherImpl } from "../../../src/core/fetcher/Fetcher"; +import stream from "stream"; +import type { BinaryResponse } from "../../../src/core"; +import { type Fetcher, fetcherImpl } from "../../../src/core/fetcher/Fetcher"; describe("Test fetcherImpl", () => { it("should handle successful request", async () => { @@ -12,14 +13,16 @@ describe("Test fetcherImpl", () => { body: { data: "test" }, contentType: "application/json", requestType: "json", + maxRetries: 0, + responseType: "json", }; - global.fetch = jest.fn().mockResolvedValue({ - ok: true, - status: 200, - text: () => Promise.resolve(JSON.stringify({ data: "test" })), - json: () => ({ data: "test" }), - }); + global.fetch = vi.fn().mockResolvedValue( + new Response(JSON.stringify({ data: "test" }), { + status: 200, + statusText: "OK", + }), + ); const result = await fetcherImpl(mockArgs); expect(result.ok).toBe(true); @@ -31,7 +34,7 @@ describe("Test fetcherImpl", () => { "https://httpbin.org/post", expect.objectContaining({ method: "POST", - headers: expect.objectContaining({ "X-Test": "x-test-header" }), + headers: expect.toContainHeaders({ "X-Test": "x-test-header" }), body: JSON.stringify({ data: "test" }), }), ); @@ -45,16 +48,17 @@ describe("Test fetcherImpl", () => { headers: { "X-Test": "x-test-header" }, contentType: "application/octet-stream", requestType: "bytes", - duplex: "half", + maxRetries: 0, + responseType: "json", body: fs.createReadStream(join(__dirname, "test-file.txt")), }; - global.fetch = jest.fn().mockResolvedValue({ - ok: true, - status: 200, - text: () => Promise.resolve(JSON.stringify({ data: "test" })), - json: () => Promise.resolve({ data: "test" }), - }); + global.fetch = vi.fn().mockResolvedValue( + new Response(JSON.stringify({ data: "test" }), { + status: 200, + statusText: "OK", + }), + ); const result = await fetcherImpl(mockArgs); @@ -62,7 +66,7 @@ describe("Test fetcherImpl", () => { url, expect.objectContaining({ method: "POST", - headers: expect.objectContaining({ "X-Test": "x-test-header" }), + headers: expect.toContainHeaders({ "X-Test": "x-test-header" }), body: expect.any(fs.ReadStream), }), ); @@ -71,4 +75,187 @@ describe("Test fetcherImpl", () => { expect(result.body).toEqual({ data: "test" }); } }); + + it("should receive file as stream", async () => { + const url = "https://httpbin.org/post/file"; + const mockArgs: Fetcher.Args = { + url, + method: "GET", + headers: { "X-Test": "x-test-header" }, + maxRetries: 0, + responseType: "binary-response", + }; + + global.fetch = vi.fn().mockResolvedValue( + new Response( + stream.Readable.toWeb(fs.createReadStream(join(__dirname, "test-file.txt"))) as ReadableStream, + { + status: 200, + statusText: "OK", + }, + ), + ); + + const result = await fetcherImpl(mockArgs); + + expect(global.fetch).toHaveBeenCalledWith( + url, + expect.objectContaining({ + method: "GET", + headers: expect.toContainHeaders({ "X-Test": "x-test-header" }), + }), + ); + expect(result.ok).toBe(true); + if (result.ok) { + const body = result.body as BinaryResponse; + expect(body).toBeDefined(); + expect(body.bodyUsed).toBe(false); + expect(typeof body.stream).toBe("function"); + const stream = body.stream(); + expect(stream).toBeInstanceOf(ReadableStream); + const reader = stream.getReader(); + const { value } = await reader.read(); + const decoder = new TextDecoder(); + const streamContent = decoder.decode(value); + expect(streamContent).toBe("This is a test file!\n"); + expect(body.bodyUsed).toBe(true); + } + }); + + it("should receive file as blob", async () => { + const url = "https://httpbin.org/post/file"; + const mockArgs: Fetcher.Args = { + url, + method: "GET", + headers: { "X-Test": "x-test-header" }, + maxRetries: 0, + responseType: "binary-response", + }; + + global.fetch = vi.fn().mockResolvedValue( + new Response( + stream.Readable.toWeb(fs.createReadStream(join(__dirname, "test-file.txt"))) as ReadableStream, + { + status: 200, + statusText: "OK", + }, + ), + ); + + const result = await fetcherImpl(mockArgs); + + expect(global.fetch).toHaveBeenCalledWith( + url, + expect.objectContaining({ + method: "GET", + headers: expect.toContainHeaders({ "X-Test": "x-test-header" }), + }), + ); + expect(result.ok).toBe(true); + if (result.ok) { + const body = result.body as BinaryResponse; + expect(body).toBeDefined(); + expect(body.bodyUsed).toBe(false); + expect(typeof body.blob).toBe("function"); + const blob = await body.blob(); + expect(blob).toBeInstanceOf(Blob); + const reader = blob.stream().getReader(); + const { value } = await reader.read(); + const decoder = new TextDecoder(); + const streamContent = decoder.decode(value); + expect(streamContent).toBe("This is a test file!\n"); + expect(body.bodyUsed).toBe(true); + } + }); + + it("should receive file as arraybuffer", async () => { + const url = "https://httpbin.org/post/file"; + const mockArgs: Fetcher.Args = { + url, + method: "GET", + headers: { "X-Test": "x-test-header" }, + maxRetries: 0, + responseType: "binary-response", + }; + + global.fetch = vi.fn().mockResolvedValue( + new Response( + stream.Readable.toWeb(fs.createReadStream(join(__dirname, "test-file.txt"))) as ReadableStream, + { + status: 200, + statusText: "OK", + }, + ), + ); + + const result = await fetcherImpl(mockArgs); + + expect(global.fetch).toHaveBeenCalledWith( + url, + expect.objectContaining({ + method: "GET", + headers: expect.toContainHeaders({ "X-Test": "x-test-header" }), + }), + ); + expect(result.ok).toBe(true); + if (result.ok) { + const body = result.body as BinaryResponse; + expect(body).toBeDefined(); + expect(body.bodyUsed).toBe(false); + expect(typeof body.arrayBuffer).toBe("function"); + const arrayBuffer = await body.arrayBuffer(); + expect(arrayBuffer).toBeInstanceOf(ArrayBuffer); + const decoder = new TextDecoder(); + const streamContent = decoder.decode(new Uint8Array(arrayBuffer)); + expect(streamContent).toBe("This is a test file!\n"); + expect(body.bodyUsed).toBe(true); + } + }); + + it("should receive file as bytes", async () => { + const url = "https://httpbin.org/post/file"; + const mockArgs: Fetcher.Args = { + url, + method: "GET", + headers: { "X-Test": "x-test-header" }, + maxRetries: 0, + responseType: "binary-response", + }; + + global.fetch = vi.fn().mockResolvedValue( + new Response( + stream.Readable.toWeb(fs.createReadStream(join(__dirname, "test-file.txt"))) as ReadableStream, + { + status: 200, + statusText: "OK", + }, + ), + ); + + const result = await fetcherImpl(mockArgs); + + expect(global.fetch).toHaveBeenCalledWith( + url, + expect.objectContaining({ + method: "GET", + headers: expect.toContainHeaders({ "X-Test": "x-test-header" }), + }), + ); + expect(result.ok).toBe(true); + if (result.ok) { + const body = result.body as BinaryResponse; + expect(body).toBeDefined(); + expect(body.bodyUsed).toBe(false); + expect(typeof body.bytes).toBe("function"); + if (!body.bytes) { + return; + } + const bytes = await body.bytes(); + expect(bytes).toBeInstanceOf(Uint8Array); + const decoder = new TextDecoder(); + const streamContent = decoder.decode(bytes); + expect(streamContent).toBe("This is a test file!\n"); + expect(body.bodyUsed).toBe(true); + } + }); }); diff --git a/tests/unit/fetcher/HttpResponsePromise.test.ts b/tests/unit/fetcher/HttpResponsePromise.test.ts index 2216a33e..2ec008e5 100644 --- a/tests/unit/fetcher/HttpResponsePromise.test.ts +++ b/tests/unit/fetcher/HttpResponsePromise.test.ts @@ -1,7 +1,7 @@ -import { beforeEach, describe, expect, it, jest } from "@jest/globals"; +import { beforeEach, describe, expect, it, vi } from "vitest"; import { HttpResponsePromise } from "../../../src/core/fetcher/HttpResponsePromise"; -import { RawResponse, WithRawResponse } from "../../../src/core/fetcher/RawResponse"; +import type { RawResponse, WithRawResponse } from "../../../src/core/fetcher/RawResponse"; describe("HttpResponsePromise", () => { const mockRawResponse: RawResponse = { @@ -20,7 +20,7 @@ describe("HttpResponsePromise", () => { describe("fromFunction", () => { it("should create an HttpResponsePromise from a function", async () => { - const mockFn = jest + const mockFn = vi .fn<(arg1: string, arg2: string) => Promise>>() .mockResolvedValue(mockWithRawResponse); @@ -111,7 +111,7 @@ describe("HttpResponsePromise", () => { reject(new Error("Test error")); }); - const catchSpy = jest.fn(); + const catchSpy = vi.fn(); await errorResponsePromise.catch(catchSpy); expect(catchSpy).toHaveBeenCalled(); @@ -121,7 +121,7 @@ describe("HttpResponsePromise", () => { }); it("should support finally() method", async () => { - const finallySpy = jest.fn(); + const finallySpy = vi.fn(); await responsePromise.finally(finallySpy); expect(finallySpy).toHaveBeenCalled(); diff --git a/tests/unit/fetcher/RawResponse.test.ts b/tests/unit/fetcher/RawResponse.test.ts index 9ccd5e1e..375ee3f3 100644 --- a/tests/unit/fetcher/RawResponse.test.ts +++ b/tests/unit/fetcher/RawResponse.test.ts @@ -1,4 +1,4 @@ -import { describe, expect, it } from "@jest/globals"; +import { describe, expect, it } from "vitest"; import { toRawResponse } from "../../../src/core/fetcher/RawResponse"; diff --git a/tests/unit/fetcher/createRequestUrl.test.ts b/tests/unit/fetcher/createRequestUrl.test.ts index 486e1e61..a92f1b5e 100644 --- a/tests/unit/fetcher/createRequestUrl.test.ts +++ b/tests/unit/fetcher/createRequestUrl.test.ts @@ -1,51 +1,163 @@ import { createRequestUrl } from "../../../src/core/fetcher/createRequestUrl"; describe("Test createRequestUrl", () => { - it("should return the base URL when no query parameters are provided", () => { - const baseUrl = "https://api.example.com"; - expect(createRequestUrl(baseUrl)).toBe(baseUrl); - }); + const BASE_URL = "https://api.example.com"; - it("should append simple query parameters", () => { - const baseUrl = "https://api.example.com"; - const queryParams = { key: "value", another: "param" }; - expect(createRequestUrl(baseUrl, queryParams)).toBe("https://api.example.com?key=value&another=param"); - }); + interface TestCase { + description: string; + baseUrl: string; + queryParams?: Record; + expected: string; + } - it("should handle array query parameters", () => { - const baseUrl = "https://api.example.com"; - const queryParams = { items: ["a", "b", "c"] }; - expect(createRequestUrl(baseUrl, queryParams)).toBe("https://api.example.com?items=a&items=b&items=c"); - }); - - it("should handle object query parameters", () => { - const baseUrl = "https://api.example.com"; - const queryParams = { filter: { name: "John", age: 30 } }; - expect(createRequestUrl(baseUrl, queryParams)).toBe( - "https://api.example.com?filter%5Bname%5D=John&filter%5Bage%5D=30", - ); - }); - - it("should handle mixed types of query parameters", () => { - const baseUrl = "https://api.example.com"; - const queryParams = { - simple: "value", - array: ["x", "y"], - object: { key: "value" }, - }; - expect(createRequestUrl(baseUrl, queryParams)).toBe( - "https://api.example.com?simple=value&array=x&array=y&object%5Bkey%5D=value", - ); - }); - - it("should handle empty query parameters object", () => { - const baseUrl = "https://api.example.com"; - expect(createRequestUrl(baseUrl, {})).toBe(baseUrl); - }); + const testCases: TestCase[] = [ + { + description: "should return the base URL when no query parameters are provided", + baseUrl: BASE_URL, + expected: BASE_URL, + }, + { + description: "should append simple query parameters", + baseUrl: BASE_URL, + queryParams: { key: "value", another: "param" }, + expected: "https://api.example.com?key=value&another=param", + }, + { + description: "should handle array query parameters", + baseUrl: BASE_URL, + queryParams: { items: ["a", "b", "c"] }, + expected: "https://api.example.com?items=a&items=b&items=c", + }, + { + description: "should handle object query parameters", + baseUrl: BASE_URL, + queryParams: { filter: { name: "John", age: 30 } }, + expected: "https://api.example.com?filter%5Bname%5D=John&filter%5Bage%5D=30", + }, + { + description: "should handle mixed types of query parameters", + baseUrl: BASE_URL, + queryParams: { + simple: "value", + array: ["x", "y"], + object: { key: "value" }, + }, + expected: "https://api.example.com?simple=value&array=x&array=y&object%5Bkey%5D=value", + }, + { + description: "should handle empty query parameters object", + baseUrl: BASE_URL, + queryParams: {}, + expected: BASE_URL, + }, + { + description: "should encode special characters in query parameters", + baseUrl: BASE_URL, + queryParams: { special: "a&b=c d" }, + expected: "https://api.example.com?special=a%26b%3Dc%20d", + }, + { + description: "should handle numeric values", + baseUrl: BASE_URL, + queryParams: { count: 42, price: 19.99, active: 1, inactive: 0 }, + expected: "https://api.example.com?count=42&price=19.99&active=1&inactive=0", + }, + { + description: "should handle boolean values", + baseUrl: BASE_URL, + queryParams: { enabled: true, disabled: false }, + expected: "https://api.example.com?enabled=true&disabled=false", + }, + { + description: "should handle null and undefined values", + baseUrl: BASE_URL, + queryParams: { + valid: "value", + nullValue: null, + undefinedValue: undefined, + emptyString: "", + }, + expected: "https://api.example.com?valid=value&nullValue=&emptyString=", + }, + { + description: "should handle deeply nested objects", + baseUrl: BASE_URL, + queryParams: { + user: { + profile: { + name: "John", + settings: { theme: "dark" }, + }, + }, + }, + expected: + "https://api.example.com?user%5Bprofile%5D%5Bname%5D=John&user%5Bprofile%5D%5Bsettings%5D%5Btheme%5D=dark", + }, + { + description: "should handle arrays of objects", + baseUrl: BASE_URL, + queryParams: { + users: [ + { name: "John", age: 30 }, + { name: "Jane", age: 25 }, + ], + }, + expected: + "https://api.example.com?users%5Bname%5D=John&users%5Bage%5D=30&users%5Bname%5D=Jane&users%5Bage%5D=25", + }, + { + description: "should handle mixed arrays", + baseUrl: BASE_URL, + queryParams: { + mixed: ["string", 42, true, { key: "value" }], + }, + expected: "https://api.example.com?mixed=string&mixed=42&mixed=true&mixed%5Bkey%5D=value", + }, + { + description: "should handle empty arrays", + baseUrl: BASE_URL, + queryParams: { emptyArray: [] }, + expected: BASE_URL, + }, + { + description: "should handle empty objects", + baseUrl: BASE_URL, + queryParams: { emptyObject: {} }, + expected: BASE_URL, + }, + { + description: "should handle special characters in keys", + baseUrl: BASE_URL, + queryParams: { "key with spaces": "value", "key[with]brackets": "value" }, + expected: "https://api.example.com?key%20with%20spaces=value&key%5Bwith%5Dbrackets=value", + }, + { + description: "should handle URL with existing query parameters", + baseUrl: "https://api.example.com?existing=param", + queryParams: { new: "value" }, + expected: "https://api.example.com?existing=param?new=value", + }, + { + description: "should handle complex nested structures", + baseUrl: BASE_URL, + queryParams: { + filters: { + status: ["active", "pending"], + category: { + type: "electronics", + subcategories: ["phones", "laptops"], + }, + }, + sort: { field: "name", direction: "asc" }, + }, + expected: + "https://api.example.com?filters%5Bstatus%5D=active&filters%5Bstatus%5D=pending&filters%5Bcategory%5D%5Btype%5D=electronics&filters%5Bcategory%5D%5Bsubcategories%5D=phones&filters%5Bcategory%5D%5Bsubcategories%5D=laptops&sort%5Bfield%5D=name&sort%5Bdirection%5D=asc", + }, + ]; - it("should encode special characters in query parameters", () => { - const baseUrl = "https://api.example.com"; - const queryParams = { special: "a&b=c d" }; - expect(createRequestUrl(baseUrl, queryParams)).toBe("https://api.example.com?special=a%26b%3Dc%20d"); + testCases.forEach(({ description, baseUrl, queryParams, expected }) => { + it(description, () => { + expect(createRequestUrl(baseUrl, queryParams)).toBe(expected); + }); }); }); diff --git a/tests/unit/fetcher/getFetchFn.test.ts b/tests/unit/fetcher/getFetchFn.test.ts deleted file mode 100644 index 9b315ad0..00000000 --- a/tests/unit/fetcher/getFetchFn.test.ts +++ /dev/null @@ -1,22 +0,0 @@ -import { RUNTIME } from "../../../src/core/runtime"; -import { getFetchFn } from "../../../src/core/fetcher/getFetchFn"; - -describe("Test for getFetchFn", () => { - it("should get node-fetch function", async () => { - if (RUNTIME.type == "node") { - if (RUNTIME.parsedVersion != null && RUNTIME.parsedVersion >= 18) { - expect(await getFetchFn()).toBe(fetch); - } else { - expect(await getFetchFn()).toEqual((await import("node-fetch")).default as any); - } - } - }); - - it("should get fetch function", async () => { - if (RUNTIME.type == "browser") { - const fetchFn = await getFetchFn(); - expect(typeof fetchFn).toBe("function"); - expect(fetchFn.name).toBe("fetch"); - } - }); -}); diff --git a/tests/unit/fetcher/getRequestBody.test.ts b/tests/unit/fetcher/getRequestBody.test.ts index 919604c2..8a6c3a57 100644 --- a/tests/unit/fetcher/getRequestBody.test.ts +++ b/tests/unit/fetcher/getRequestBody.test.ts @@ -1,33 +1,123 @@ -import { RUNTIME } from "../../../src/core/runtime"; import { getRequestBody } from "../../../src/core/fetcher/getRequestBody"; +import { RUNTIME } from "../../../src/core/runtime"; describe("Test getRequestBody", () => { - it("should return FormData as is in Node environment", async () => { - if (RUNTIME.type === "node") { - const formData = new (await import("formdata-node")).FormData(); - formData.append("key", "value"); - const result = await getRequestBody({ - body: formData, - type: "file", - }); - expect(result).toBe(formData); - } - }); + interface TestCase { + description: string; + input: any; + type: "json" | "form" | "file" | "bytes" | "other"; + expected: any; + skipCondition?: () => boolean; + } + + const testCases: TestCase[] = [ + { + description: "should stringify body if not FormData in Node environment", + input: { key: "value" }, + type: "json", + expected: '{"key":"value"}', + skipCondition: () => RUNTIME.type !== "node", + }, + { + description: "should stringify body if not FormData in browser environment", + input: { key: "value" }, + type: "json", + expected: '{"key":"value"}', + skipCondition: () => RUNTIME.type !== "browser", + }, + { + description: "should return the Uint8Array", + input: new Uint8Array([1, 2, 3]), + type: "bytes", + expected: new Uint8Array([1, 2, 3]), + }, + { + description: "should serialize objects for form-urlencoded content type", + input: { username: "johndoe", email: "john@example.com" }, + type: "form", + expected: "username=johndoe&email=john%40example.com", + }, + { + description: "should serialize complex nested objects and arrays for form-urlencoded content type", + input: { + user: { + profile: { + name: "John Doe", + settings: { + theme: "dark", + notifications: true, + }, + }, + tags: ["admin", "user"], + contacts: [ + { type: "email", value: "john@example.com" }, + { type: "phone", value: "+1234567890" }, + ], + }, + filters: { + status: ["active", "pending"], + metadata: { + created: "2024-01-01", + categories: ["electronics", "books"], + }, + }, + preferences: ["notifications", "updates"], + }, + type: "form", + expected: + "user%5Bprofile%5D%5Bname%5D=John%20Doe&" + + "user%5Bprofile%5D%5Bsettings%5D%5Btheme%5D=dark&" + + "user%5Bprofile%5D%5Bsettings%5D%5Bnotifications%5D=true&" + + "user%5Btags%5D=admin&" + + "user%5Btags%5D=user&" + + "user%5Bcontacts%5D%5Btype%5D=email&" + + "user%5Bcontacts%5D%5Bvalue%5D=john%40example.com&" + + "user%5Bcontacts%5D%5Btype%5D=phone&" + + "user%5Bcontacts%5D%5Bvalue%5D=%2B1234567890&" + + "filters%5Bstatus%5D=active&" + + "filters%5Bstatus%5D=pending&" + + "filters%5Bmetadata%5D%5Bcreated%5D=2024-01-01&" + + "filters%5Bmetadata%5D%5Bcategories%5D=electronics&" + + "filters%5Bmetadata%5D%5Bcategories%5D=books&" + + "preferences=notifications&" + + "preferences=updates", + }, + { + description: "should return the input for pre-serialized form-urlencoded strings", + input: "key=value&another=param", + type: "other", + expected: "key=value&another=param", + }, + { + description: "should JSON stringify objects", + input: { key: "value" }, + type: "json", + expected: '{"key":"value"}', + }, + ]; + + testCases.forEach(({ description, input, type, expected, skipCondition }) => { + it(description, async () => { + if (skipCondition?.()) { + return; + } - it("should stringify body if not FormData in Node environment", async () => { - if (RUNTIME.type === "node") { - const body = { key: "value" }; const result = await getRequestBody({ - body, - type: "json", + body: input, + type, }); - expect(result).toBe('{"key":"value"}'); - } + + if (input instanceof Uint8Array) { + expect(result).toBe(input); + } else { + expect(result).toBe(expected); + } + }); }); it("should return FormData in browser environment", async () => { if (RUNTIME.type === "browser") { - const formData = new (await import("form-data")).default(); + const formData = new FormData(); formData.append("key", "value"); const result = await getRequestBody({ body: formData, @@ -36,42 +126,4 @@ describe("Test getRequestBody", () => { expect(result).toBe(formData); } }); - - it("should stringify body if not FormData in browser environment", async () => { - if (RUNTIME.type === "browser") { - const body = { key: "value" }; - const result = await getRequestBody({ - body, - type: "json", - }); - expect(result).toBe('{"key":"value"}'); - } - }); - - it("should return the Uint8Array", async () => { - const input = new Uint8Array([1, 2, 3]); - const result = await getRequestBody({ - body: input, - type: "bytes", - }); - expect(result).toBe(input); - }); - - it("should return the input for content-type 'application/x-www-form-urlencoded'", async () => { - const input = "key=value&another=param"; - const result = await getRequestBody({ - body: input, - type: "other", - }); - expect(result).toBe(input); - }); - - it("should JSON stringify objects", async () => { - const input = { key: "value" }; - const result = await getRequestBody({ - body: input, - type: "json", - }); - expect(result).toBe('{"key":"value"}'); - }); }); diff --git a/tests/unit/fetcher/getResponseBody.test.ts b/tests/unit/fetcher/getResponseBody.test.ts index 1030c517..ad6be7fc 100644 --- a/tests/unit/fetcher/getResponseBody.test.ts +++ b/tests/unit/fetcher/getResponseBody.test.ts @@ -1,8 +1,61 @@ -import { RUNTIME } from "../../../src/core/runtime"; import { getResponseBody } from "../../../src/core/fetcher/getResponseBody"; -import { chooseStreamWrapper } from "../../../src/core/fetcher/stream-wrappers/chooseStreamWrapper"; + +import { RUNTIME } from "../../../src/core/runtime"; describe("Test getResponseBody", () => { + interface SimpleTestCase { + description: string; + responseData: string | Record; + responseType?: "blob" | "sse" | "streaming" | "text"; + expected: any; + skipCondition?: () => boolean; + } + + const simpleTestCases: SimpleTestCase[] = [ + { + description: "should handle text response type", + responseData: "test text", + responseType: "text", + expected: "test text", + }, + { + description: "should handle JSON response", + responseData: { key: "value" }, + expected: { key: "value" }, + }, + { + description: "should handle empty response", + responseData: "", + expected: undefined, + }, + { + description: "should handle non-JSON response", + responseData: "invalid json", + expected: { + ok: false, + error: { + reason: "non-json", + statusCode: 200, + rawBody: "invalid json", + }, + }, + }, + ]; + + simpleTestCases.forEach(({ description, responseData, responseType, expected, skipCondition }) => { + it(description, async () => { + if (skipCondition?.()) { + return; + } + + const mockResponse = new Response( + typeof responseData === "string" ? responseData : JSON.stringify(responseData), + ); + const result = await getResponseBody(mockResponse, responseType); + expect(result).toEqual(expected); + }); + }); + it("should handle blob response type", async () => { const mockBlob = new Blob(["test"], { type: "text/plain" }); const mockResponse = new Response(mockBlob); @@ -21,44 +74,24 @@ describe("Test getResponseBody", () => { }); it("should handle streaming response type", async () => { - if (RUNTIME.type === "node") { - const mockStream = new ReadableStream(); - const mockResponse = new Response(mockStream); - const result = await getResponseBody(mockResponse, "streaming"); - // need to reinstantiate string as a result of locked state in Readable Stream after registration with Response - expect(JSON.stringify(result)).toBe(JSON.stringify(await chooseStreamWrapper(new ReadableStream()))); - } - }); - - it("should handle text response type", async () => { - const mockResponse = new Response("test text"); - const result = await getResponseBody(mockResponse, "text"); - expect(result).toBe("test text"); - }); + const encoder = new TextEncoder(); + const testData = "test stream data"; + const mockStream = new ReadableStream({ + start(controller) { + controller.enqueue(encoder.encode(testData)); + controller.close(); + }, + }); - it("should handle JSON response", async () => { - const mockJson = { key: "value" }; - const mockResponse = new Response(JSON.stringify(mockJson)); - const result = await getResponseBody(mockResponse); - expect(result).toEqual(mockJson); - }); + const mockResponse = new Response(mockStream); + const result = (await getResponseBody(mockResponse, "streaming")) as ReadableStream; - it("should handle empty response", async () => { - const mockResponse = new Response(""); - const result = await getResponseBody(mockResponse); - expect(result).toBeUndefined(); - }); + expect(result).toBeInstanceOf(ReadableStream); - it("should handle non-JSON response", async () => { - const mockResponse = new Response("invalid json"); - const result = await getResponseBody(mockResponse); - expect(result).toEqual({ - ok: false, - error: { - reason: "non-json", - statusCode: 200, - rawBody: "invalid json", - }, - }); + const reader = result.getReader(); + const decoder = new TextDecoder(); + const { value } = await reader.read(); + const streamContent = decoder.decode(value); + expect(streamContent).toBe(testData); }); }); diff --git a/tests/unit/fetcher/logging.test.ts b/tests/unit/fetcher/logging.test.ts new file mode 100644 index 00000000..366c9b6c --- /dev/null +++ b/tests/unit/fetcher/logging.test.ts @@ -0,0 +1,517 @@ +import { fetcherImpl } from "../../../src/core/fetcher/Fetcher"; + +function createMockLogger() { + return { + debug: vi.fn(), + info: vi.fn(), + warn: vi.fn(), + error: vi.fn(), + }; +} + +function mockSuccessResponse(data: unknown = { data: "test" }, status = 200, statusText = "OK") { + global.fetch = vi.fn().mockResolvedValue( + new Response(JSON.stringify(data), { + status, + statusText, + }), + ); +} + +function mockErrorResponse(data: unknown = { error: "Error" }, status = 404, statusText = "Not Found") { + global.fetch = vi.fn().mockResolvedValue( + new Response(JSON.stringify(data), { + status, + statusText, + }), + ); +} + +describe("Fetcher Logging Integration", () => { + describe("Request Logging", () => { + it("should log successful request at debug level", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "POST", + headers: { "Content-Type": "application/json" }, + body: { test: "data" }, + contentType: "application/json", + requestType: "json", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + method: "POST", + url: "https://example.com/api", + headers: expect.toContainHeaders({ + "Content-Type": "application/json", + }), + hasBody: true, + }), + ); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "HTTP request succeeded", + expect.objectContaining({ + method: "POST", + url: "https://example.com/api", + statusCode: 200, + }), + ); + }); + + it("should not log debug messages at info level for successful requests", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "info", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).not.toHaveBeenCalled(); + expect(mockLogger.info).not.toHaveBeenCalled(); + }); + + it("should log request with body flag", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "POST", + body: { data: "test" }, + contentType: "application/json", + requestType: "json", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + hasBody: true, + }), + ); + }); + + it("should log request without body flag", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + hasBody: false, + }), + ); + }); + + it("should not log when silent mode is enabled", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: true, + }, + }); + + expect(mockLogger.debug).not.toHaveBeenCalled(); + expect(mockLogger.info).not.toHaveBeenCalled(); + expect(mockLogger.warn).not.toHaveBeenCalled(); + expect(mockLogger.error).not.toHaveBeenCalled(); + }); + + it("should not log when no logging config is provided", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + }); + + expect(mockLogger.debug).not.toHaveBeenCalled(); + }); + }); + + describe("Error Logging", () => { + it("should log 4xx errors at error level", async () => { + const mockLogger = createMockLogger(); + mockErrorResponse({ error: "Not found" }, 404, "Not Found"); + + const result = await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "error", + logger: mockLogger, + silent: false, + }, + }); + + expect(result.ok).toBe(false); + expect(mockLogger.error).toHaveBeenCalledWith( + "HTTP request failed with error status", + expect.objectContaining({ + method: "GET", + url: "https://example.com/api", + statusCode: 404, + }), + ); + }); + + it("should log 5xx errors at error level", async () => { + const mockLogger = createMockLogger(); + mockErrorResponse({ error: "Internal error" }, 500, "Internal Server Error"); + + const result = await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "error", + logger: mockLogger, + silent: false, + }, + }); + + expect(result.ok).toBe(false); + expect(mockLogger.error).toHaveBeenCalledWith( + "HTTP request failed with error status", + expect.objectContaining({ + method: "GET", + url: "https://example.com/api", + statusCode: 500, + }), + ); + }); + + it("should log aborted request errors", async () => { + const mockLogger = createMockLogger(); + + const abortController = new AbortController(); + abortController.abort(); + + global.fetch = vi.fn().mockRejectedValue(new Error("Aborted")); + + const result = await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + abortSignal: abortController.signal, + maxRetries: 0, + logging: { + level: "error", + logger: mockLogger, + silent: false, + }, + }); + + expect(result.ok).toBe(false); + expect(mockLogger.error).toHaveBeenCalledWith( + "HTTP request was aborted", + expect.objectContaining({ + method: "GET", + url: "https://example.com/api", + }), + ); + }); + + it("should log timeout errors", async () => { + const mockLogger = createMockLogger(); + + const timeoutError = new Error("Request timeout"); + timeoutError.name = "AbortError"; + + global.fetch = vi.fn().mockRejectedValue(timeoutError); + + const result = await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "error", + logger: mockLogger, + silent: false, + }, + }); + + expect(result.ok).toBe(false); + expect(mockLogger.error).toHaveBeenCalledWith( + "HTTP request timed out", + expect.objectContaining({ + method: "GET", + url: "https://example.com/api", + timeoutMs: undefined, + }), + ); + }); + + it("should log unknown errors", async () => { + const mockLogger = createMockLogger(); + + const unknownError = new Error("Unknown error"); + + global.fetch = vi.fn().mockRejectedValue(unknownError); + + const result = await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "error", + logger: mockLogger, + silent: false, + }, + }); + + expect(result.ok).toBe(false); + expect(mockLogger.error).toHaveBeenCalledWith( + "HTTP request failed with error", + expect.objectContaining({ + method: "GET", + url: "https://example.com/api", + errorMessage: "Unknown error", + }), + ); + }); + }); + + describe("Logging with Redaction", () => { + it("should redact sensitive data in error logs", async () => { + const mockLogger = createMockLogger(); + mockErrorResponse({ error: "Unauthorized" }, 401, "Unauthorized"); + + await fetcherImpl({ + url: "https://example.com/api?api_key=secret", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "error", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.error).toHaveBeenCalledWith( + "HTTP request failed with error status", + expect.objectContaining({ + url: "https://example.com/api?api_key=[REDACTED]", + }), + ); + }); + }); + + describe("Different HTTP Methods", () => { + it("should log GET requests", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + method: "GET", + }), + ); + }); + + it("should log POST requests", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse({ data: "test" }, 201, "Created"); + + await fetcherImpl({ + url: "https://example.com/api", + method: "POST", + body: { data: "test" }, + contentType: "application/json", + requestType: "json", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + method: "POST", + }), + ); + }); + + it("should log PUT requests", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "PUT", + body: { data: "test" }, + contentType: "application/json", + requestType: "json", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + method: "PUT", + }), + ); + }); + + it("should log DELETE requests", async () => { + const mockLogger = createMockLogger(); + global.fetch = vi.fn().mockResolvedValue( + new Response(null, { + status: 200, + statusText: "OK", + }), + ); + + await fetcherImpl({ + url: "https://example.com/api", + method: "DELETE", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + method: "DELETE", + }), + ); + }); + }); + + describe("Status Code Logging", () => { + it("should log 2xx success status codes", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse({ data: "test" }, 201, "Created"); + + await fetcherImpl({ + url: "https://example.com/api", + method: "POST", + body: { data: "test" }, + contentType: "application/json", + requestType: "json", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "HTTP request succeeded", + expect.objectContaining({ + statusCode: 201, + }), + ); + }); + + it("should log 3xx redirect status codes as success", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse({ data: "test" }, 301, "Moved Permanently"); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "HTTP request succeeded", + expect.objectContaining({ + statusCode: 301, + }), + ); + }); + }); +}); diff --git a/tests/unit/fetcher/makeRequest.test.ts b/tests/unit/fetcher/makeRequest.test.ts index 43ed9d11..ea49466a 100644 --- a/tests/unit/fetcher/makeRequest.test.ts +++ b/tests/unit/fetcher/makeRequest.test.ts @@ -1,3 +1,4 @@ +import type { Mock } from "vitest"; import { makeRequest } from "../../../src/core/fetcher/makeRequest"; describe("Test makeRequest", () => { @@ -6,10 +7,10 @@ describe("Test makeRequest", () => { const mockHeaders = { "Content-Type": "application/json" }; const mockBody = JSON.stringify({ key: "value" }); - let mockFetch: jest.Mock; + let mockFetch: Mock; beforeEach(() => { - mockFetch = jest.fn(); + mockFetch = vi.fn(); mockFetch.mockResolvedValue(new Response(JSON.stringify({ test: "successful" }), { status: 200 })); }); diff --git a/tests/unit/fetcher/redacting.test.ts b/tests/unit/fetcher/redacting.test.ts new file mode 100644 index 00000000..d599376b --- /dev/null +++ b/tests/unit/fetcher/redacting.test.ts @@ -0,0 +1,1115 @@ +import { fetcherImpl } from "../../../src/core/fetcher/Fetcher"; + +function createMockLogger() { + return { + debug: vi.fn(), + info: vi.fn(), + warn: vi.fn(), + error: vi.fn(), + }; +} + +function mockSuccessResponse(data: unknown = { data: "test" }, status = 200, statusText = "OK") { + global.fetch = vi.fn().mockResolvedValue( + new Response(JSON.stringify(data), { + status, + statusText, + }), + ); +} + +describe("Redacting Logic", () => { + describe("Header Redaction", () => { + it("should redact authorization header", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + headers: { Authorization: "Bearer secret-token-12345" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + headers: expect.toContainHeaders({ + Authorization: "[REDACTED]", + }), + }), + ); + }); + + it("should redact api-key header (case-insensitive)", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + headers: { "X-API-KEY": "secret-api-key" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + headers: expect.toContainHeaders({ + "X-API-KEY": "[REDACTED]", + }), + }), + ); + }); + + it("should redact cookie header", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + headers: { Cookie: "session=abc123; token=xyz789" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + headers: expect.toContainHeaders({ + Cookie: "[REDACTED]", + }), + }), + ); + }); + + it("should redact x-auth-token header", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + headers: { "x-auth-token": "auth-token-12345" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + headers: expect.toContainHeaders({ + "x-auth-token": "[REDACTED]", + }), + }), + ); + }); + + it("should redact proxy-authorization header", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + headers: { "Proxy-Authorization": "Basic credentials" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + headers: expect.toContainHeaders({ + "Proxy-Authorization": "[REDACTED]", + }), + }), + ); + }); + + it("should redact x-csrf-token header", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + headers: { "X-CSRF-Token": "csrf-token-abc" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + headers: expect.toContainHeaders({ + "X-CSRF-Token": "[REDACTED]", + }), + }), + ); + }); + + it("should redact www-authenticate header", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + headers: { "WWW-Authenticate": "Bearer realm=example" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + headers: expect.toContainHeaders({ + "WWW-Authenticate": "[REDACTED]", + }), + }), + ); + }); + + it("should redact x-session-token header", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + headers: { "X-Session-Token": "session-token-xyz" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + headers: expect.toContainHeaders({ + "X-Session-Token": "[REDACTED]", + }), + }), + ); + }); + + it("should not redact non-sensitive headers", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + headers: { + "Content-Type": "application/json", + "User-Agent": "Test/1.0", + Accept: "application/json", + }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + headers: expect.toContainHeaders({ + "Content-Type": "application/json", + "User-Agent": "Test/1.0", + Accept: "application/json", + }), + }), + ); + }); + + it("should redact multiple sensitive headers at once", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + headers: { + Authorization: "Bearer token", + "X-API-Key": "api-key", + Cookie: "session=123", + "Content-Type": "application/json", + }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + headers: expect.toContainHeaders({ + Authorization: "[REDACTED]", + "X-API-Key": "[REDACTED]", + Cookie: "[REDACTED]", + "Content-Type": "application/json", + }), + }), + ); + }); + }); + + describe("Response Header Redaction", () => { + it("should redact Set-Cookie in response headers", async () => { + const mockLogger = createMockLogger(); + + const mockHeaders = new Headers(); + mockHeaders.set("Set-Cookie", "session=abc123; HttpOnly; Secure"); + mockHeaders.set("Content-Type", "application/json"); + + global.fetch = vi.fn().mockResolvedValue( + new Response(JSON.stringify({ data: "test" }), { + status: 200, + statusText: "OK", + headers: mockHeaders, + }), + ); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "HTTP request succeeded", + expect.objectContaining({ + responseHeaders: expect.toContainHeaders({ + "set-cookie": "[REDACTED]", + "content-type": "application/json", + }), + }), + ); + }); + + it("should redact authorization in response headers", async () => { + const mockLogger = createMockLogger(); + + const mockHeaders = new Headers(); + mockHeaders.set("Authorization", "Bearer token-123"); + mockHeaders.set("Content-Type", "application/json"); + + global.fetch = vi.fn().mockResolvedValue( + new Response(JSON.stringify({ data: "test" }), { + status: 200, + statusText: "OK", + headers: mockHeaders, + }), + ); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "HTTP request succeeded", + expect.objectContaining({ + responseHeaders: expect.toContainHeaders({ + authorization: "[REDACTED]", + "content-type": "application/json", + }), + }), + ); + }); + + it("should redact response headers in error responses", async () => { + const mockLogger = createMockLogger(); + + const mockHeaders = new Headers(); + mockHeaders.set("WWW-Authenticate", "Bearer realm=example"); + mockHeaders.set("Content-Type", "application/json"); + + global.fetch = vi.fn().mockResolvedValue( + new Response(JSON.stringify({ error: "Unauthorized" }), { + status: 401, + statusText: "Unauthorized", + headers: mockHeaders, + }), + ); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "error", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.error).toHaveBeenCalledWith( + "HTTP request failed with error status", + expect.objectContaining({ + responseHeaders: expect.toContainHeaders({ + "www-authenticate": "[REDACTED]", + "content-type": "application/json", + }), + }), + ); + }); + }); + + describe("Query Parameter Redaction", () => { + it("should redact api_key query parameter", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + queryParameters: { api_key: "secret-key" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + queryParameters: expect.objectContaining({ + api_key: "[REDACTED]", + }), + }), + ); + }); + + it("should redact token query parameter", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + queryParameters: { token: "secret-token" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + queryParameters: expect.objectContaining({ + token: "[REDACTED]", + }), + }), + ); + }); + + it("should redact access_token query parameter", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + queryParameters: { access_token: "secret-access-token" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + queryParameters: expect.objectContaining({ + access_token: "[REDACTED]", + }), + }), + ); + }); + + it("should redact password query parameter", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + queryParameters: { password: "secret-password" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + queryParameters: expect.objectContaining({ + password: "[REDACTED]", + }), + }), + ); + }); + + it("should redact secret query parameter", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + queryParameters: { secret: "secret-value" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + queryParameters: expect.objectContaining({ + secret: "[REDACTED]", + }), + }), + ); + }); + + it("should redact session_id query parameter", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + queryParameters: { session_id: "session-123" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + queryParameters: expect.objectContaining({ + session_id: "[REDACTED]", + }), + }), + ); + }); + + it("should not redact non-sensitive query parameters", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + queryParameters: { + page: "1", + limit: "10", + sort: "name", + }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + queryParameters: expect.objectContaining({ + page: "1", + limit: "10", + sort: "name", + }), + }), + ); + }); + + it("should not redact parameters containing 'auth' substring like 'author'", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + queryParameters: { + author: "john", + authenticate: "false", + authorization_level: "user", + }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + queryParameters: expect.objectContaining({ + author: "john", + authenticate: "false", + authorization_level: "user", + }), + }), + ); + }); + + it("should handle undefined query parameters", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + queryParameters: undefined, + }), + ); + }); + + it("should redact case-insensitive query parameters", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + queryParameters: { API_KEY: "secret-key", Token: "secret-token" }, + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + queryParameters: expect.objectContaining({ + API_KEY: "[REDACTED]", + Token: "[REDACTED]", + }), + }), + ); + }); + }); + + describe("URL Redaction", () => { + it("should redact credentials in URL", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://user:password@example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://[REDACTED]@example.com/api", + }), + ); + }); + + it("should redact api_key in query string", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api?api_key=secret-key&page=1", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://example.com/api?api_key=[REDACTED]&page=1", + }), + ); + }); + + it("should redact token in query string", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api?token=secret-token", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://example.com/api?token=[REDACTED]", + }), + ); + }); + + it("should redact password in query string", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api?username=user&password=secret", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://example.com/api?username=user&password=[REDACTED]", + }), + ); + }); + + it("should not redact non-sensitive query strings", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api?page=1&limit=10&sort=name", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://example.com/api?page=1&limit=10&sort=name", + }), + ); + }); + + it("should not redact URL parameters containing 'auth' substring like 'author'", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api?author=john&authenticate=false&page=1", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://example.com/api?author=john&authenticate=false&page=1", + }), + ); + }); + + it("should handle URL with fragment", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api?token=secret#section", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://example.com/api?token=[REDACTED]#section", + }), + ); + }); + + it("should redact URL-encoded query parameters", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api?api%5Fkey=secret", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://example.com/api?api%5Fkey=[REDACTED]", + }), + ); + }); + + it("should handle URL without query string", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://example.com/api", + }), + ); + }); + + it("should handle empty query string", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api?", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://example.com/api?", + }), + ); + }); + + it("should redact multiple sensitive parameters in URL", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api?api_key=secret1&token=secret2&page=1", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://example.com/api?api_key=[REDACTED]&token=[REDACTED]&page=1", + }), + ); + }); + + it("should redact both credentials and query parameters", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://user:pass@example.com/api?token=secret", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://[REDACTED]@example.com/api?token=[REDACTED]", + }), + ); + }); + + it("should use fast path for URLs without sensitive keywords", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api?page=1&limit=10&sort=name&filter=value", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://example.com/api?page=1&limit=10&sort=name&filter=value", + }), + ); + }); + + it("should handle query parameter without value", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api?flag&token=secret", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://example.com/api?flag&token=[REDACTED]", + }), + ); + }); + + it("should handle URL with multiple @ symbols in credentials", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://user@example.com:pass@host.com/api", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://[REDACTED]@host.com/api", + }), + ); + }); + + it("should handle URL with @ in query parameter but not in credentials", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://example.com/api?email=user@example.com", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://example.com/api?email=user@example.com", + }), + ); + }); + + it("should handle URL with both credentials and @ in path", async () => { + const mockLogger = createMockLogger(); + mockSuccessResponse(); + + await fetcherImpl({ + url: "https://user:pass@example.com/users/@username", + method: "GET", + responseType: "json", + maxRetries: 0, + logging: { + level: "debug", + logger: mockLogger, + silent: false, + }, + }); + + expect(mockLogger.debug).toHaveBeenCalledWith( + "Making HTTP request", + expect.objectContaining({ + url: "https://[REDACTED]@example.com/users/@username", + }), + ); + }); + }); +}); diff --git a/tests/unit/fetcher/requestWithRetries.test.ts b/tests/unit/fetcher/requestWithRetries.test.ts index 3cdaa40a..d2266136 100644 --- a/tests/unit/fetcher/requestWithRetries.test.ts +++ b/tests/unit/fetcher/requestWithRetries.test.ts @@ -1,28 +1,43 @@ +import type { Mock, MockInstance } from "vitest"; import { requestWithRetries } from "../../../src/core/fetcher/requestWithRetries"; describe("requestWithRetries", () => { - let mockFetch: jest.Mock; + let mockFetch: Mock; let originalMathRandom: typeof Math.random; - let setTimeoutSpy: jest.SpyInstance; + let setTimeoutSpy: MockInstance; beforeEach(() => { - mockFetch = jest.fn(); + mockFetch = vi.fn(); originalMathRandom = Math.random; - // Mock Math.random for consistent jitter - Math.random = jest.fn(() => 0.5); - - jest.useFakeTimers({ doNotFake: ["nextTick"] }); + Math.random = vi.fn(() => 0.5); + + vi.useFakeTimers({ + toFake: [ + "setTimeout", + "clearTimeout", + "setInterval", + "clearInterval", + "setImmediate", + "clearImmediate", + "Date", + "performance", + "requestAnimationFrame", + "cancelAnimationFrame", + "requestIdleCallback", + "cancelIdleCallback", + ], + }); }); afterEach(() => { Math.random = originalMathRandom; - jest.clearAllMocks(); - jest.clearAllTimers(); + vi.clearAllMocks(); + vi.clearAllTimers(); }); it("should retry on retryable status codes", async () => { - setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { + setTimeoutSpy = vi.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { process.nextTick(callback); return null as any; }); @@ -38,7 +53,7 @@ describe("requestWithRetries", () => { }); const responsePromise = requestWithRetries(() => mockFetch(), retryableStatuses.length); - await jest.runAllTimersAsync(); + await vi.runAllTimersAsync(); const response = await responsePromise; expect(mockFetch).toHaveBeenCalledTimes(retryableStatuses.length + 1); @@ -46,7 +61,7 @@ describe("requestWithRetries", () => { }); it("should respect maxRetries limit", async () => { - setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { + setTimeoutSpy = vi.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { process.nextTick(callback); return null as any; }); @@ -55,7 +70,7 @@ describe("requestWithRetries", () => { mockFetch.mockResolvedValue(new Response("", { status: 500 })); const responsePromise = requestWithRetries(() => mockFetch(), maxRetries); - await jest.runAllTimersAsync(); + await vi.runAllTimersAsync(); const response = await responsePromise; expect(mockFetch).toHaveBeenCalledTimes(maxRetries + 1); @@ -63,7 +78,7 @@ describe("requestWithRetries", () => { }); it("should not retry on success status codes", async () => { - setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { + setTimeoutSpy = vi.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { process.nextTick(callback); return null as any; }); @@ -76,7 +91,7 @@ describe("requestWithRetries", () => { mockFetch.mockResolvedValueOnce(new Response("", { status })); const responsePromise = requestWithRetries(() => mockFetch(), 3); - await jest.runAllTimersAsync(); + await vi.runAllTimersAsync(); await responsePromise; expect(mockFetch).toHaveBeenCalledTimes(1); @@ -84,8 +99,69 @@ describe("requestWithRetries", () => { } }); + interface RetryHeaderTestCase { + description: string; + headerName: string; + headerValue: string | (() => string); + expectedDelayMin: number; + expectedDelayMax: number; + } + + const retryHeaderTests: RetryHeaderTestCase[] = [ + { + description: "should respect retry-after header with seconds value", + headerName: "retry-after", + headerValue: "5", + expectedDelayMin: 4000, + expectedDelayMax: 6000, + }, + { + description: "should respect retry-after header with HTTP date value", + headerName: "retry-after", + headerValue: () => new Date(Date.now() + 3000).toUTCString(), + expectedDelayMin: 2000, + expectedDelayMax: 4000, + }, + { + description: "should respect x-ratelimit-reset header", + headerName: "x-ratelimit-reset", + headerValue: () => Math.floor((Date.now() + 4000) / 1000).toString(), + expectedDelayMin: 3000, + expectedDelayMax: 6000, + }, + ]; + + retryHeaderTests.forEach(({ description, headerName, headerValue, expectedDelayMin, expectedDelayMax }) => { + it(description, async () => { + setTimeoutSpy = vi.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { + process.nextTick(callback); + return null as any; + }); + + const value = typeof headerValue === "function" ? headerValue() : headerValue; + mockFetch + .mockResolvedValueOnce( + new Response("", { + status: 429, + headers: new Headers({ [headerName]: value }), + }), + ) + .mockResolvedValueOnce(new Response("", { status: 200 })); + + const responsePromise = requestWithRetries(() => mockFetch(), 1); + await vi.runAllTimersAsync(); + const response = await responsePromise; + + expect(setTimeoutSpy).toHaveBeenCalledWith(expect.any(Function), expect.any(Number)); + const actualDelay = setTimeoutSpy.mock.calls[0][1]; + expect(actualDelay).toBeGreaterThan(expectedDelayMin); + expect(actualDelay).toBeLessThan(expectedDelayMax); + expect(response.status).toBe(200); + }); + }); + it("should apply correct exponential backoff with jitter", async () => { - setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { + setTimeoutSpy = vi.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { process.nextTick(callback); return null as any; }); @@ -95,10 +171,9 @@ describe("requestWithRetries", () => { const expectedDelays = [1000, 2000, 4000]; const responsePromise = requestWithRetries(() => mockFetch(), maxRetries); - await jest.runAllTimersAsync(); + await vi.runAllTimersAsync(); await responsePromise; - // Verify setTimeout calls expect(setTimeoutSpy).toHaveBeenCalledTimes(expectedDelays.length); expectedDelays.forEach((delay, index) => { @@ -109,7 +184,7 @@ describe("requestWithRetries", () => { }); it("should handle concurrent retries independently", async () => { - setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { + setTimeoutSpy = vi.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { process.nextTick(callback); return null as any; }); @@ -123,10 +198,33 @@ describe("requestWithRetries", () => { const promise1 = requestWithRetries(() => mockFetch(), 1); const promise2 = requestWithRetries(() => mockFetch(), 1); - await jest.runAllTimersAsync(); + await vi.runAllTimersAsync(); const [response1, response2] = await Promise.all([promise1, promise2]); expect(response1.status).toBe(200); expect(response2.status).toBe(200); }); + + it("should cap delay at MAX_RETRY_DELAY for large header values", async () => { + setTimeoutSpy = vi.spyOn(global, "setTimeout").mockImplementation((callback: (args: void) => void) => { + process.nextTick(callback); + return null as any; + }); + + mockFetch + .mockResolvedValueOnce( + new Response("", { + status: 429, + headers: new Headers({ "retry-after": "120" }), // 120 seconds = 120000ms > MAX_RETRY_DELAY (60000ms) + }), + ) + .mockResolvedValueOnce(new Response("", { status: 200 })); + + const responsePromise = requestWithRetries(() => mockFetch(), 1); + await vi.runAllTimersAsync(); + const response = await responsePromise; + + expect(setTimeoutSpy).toHaveBeenCalledWith(expect.any(Function), 60000); + expect(response.status).toBe(200); + }); }); diff --git a/tests/unit/fetcher/signals.test.ts b/tests/unit/fetcher/signals.test.ts index 9cabfa07..d7b6d1e6 100644 --- a/tests/unit/fetcher/signals.test.ts +++ b/tests/unit/fetcher/signals.test.ts @@ -2,11 +2,11 @@ import { anySignal, getTimeoutSignal } from "../../../src/core/fetcher/signals"; describe("Test getTimeoutSignal", () => { beforeEach(() => { - jest.useFakeTimers(); + vi.useFakeTimers(); }); afterEach(() => { - jest.useRealTimers(); + vi.useRealTimers(); }); it("should return an object with signal and abortId", () => { @@ -24,10 +24,10 @@ describe("Test getTimeoutSignal", () => { expect(signal.aborted).toBe(false); - jest.advanceTimersByTime(timeoutMs - 1); + vi.advanceTimersByTime(timeoutMs - 1); expect(signal.aborted).toBe(false); - jest.advanceTimersByTime(1); + vi.advanceTimersByTime(1); expect(signal.aborted).toBe(true); }); }); diff --git a/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts b/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts deleted file mode 100644 index 172c1c26..00000000 --- a/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts +++ /dev/null @@ -1,178 +0,0 @@ -import { Node18UniversalStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper"; - -describe("Node18UniversalStreamWrapper", () => { - it("should set encoding to utf-8", async () => { - const rawStream = new ReadableStream(); - const stream = new Node18UniversalStreamWrapper(rawStream); - const setEncodingSpy = jest.spyOn(stream, "setEncoding"); - - stream.setEncoding("utf-8"); - - expect(setEncodingSpy).toHaveBeenCalledWith("utf-8"); - }); - - it("should register an event listener for readable", async () => { - const rawStream = new ReadableStream(); - const stream = new Node18UniversalStreamWrapper(rawStream); - const onSpy = jest.spyOn(stream, "on"); - - stream.on("readable", () => {}); - - expect(onSpy).toHaveBeenCalledWith("readable", expect.any(Function)); - }); - - it("should remove an event listener for data", async () => { - const rawStream = new ReadableStream(); - const stream = new Node18UniversalStreamWrapper(rawStream); - const offSpy = jest.spyOn(stream, "off"); - - const fn = () => {}; - stream.on("data", fn); - stream.off("data", fn); - - expect(offSpy).toHaveBeenCalledWith("data", expect.any(Function)); - }); - - it("should write to dest when calling pipe to writable stream", async () => { - const rawStream = new ReadableStream({ - start(controller) { - controller.enqueue(new TextEncoder().encode("test")); - controller.enqueue(new TextEncoder().encode("test")); - controller.close(); - }, - }); - const stream = new Node18UniversalStreamWrapper(rawStream); - const dest = new WritableStream({ - write(chunk) { - expect(chunk).toEqual(new TextEncoder().encode("test")); - }, - }); - - stream.pipe(dest); - }); - - it("should write to dest when calling pipe to node writable stream", async () => { - const rawStream = new ReadableStream({ - start(controller) { - controller.enqueue(new TextEncoder().encode("test")); - controller.enqueue(new TextEncoder().encode("test")); - controller.close(); - }, - }); - const stream = new Node18UniversalStreamWrapper(rawStream); - const dest = new (await import("readable-stream")).Writable({ - write(chunk, encoding, callback) { - expect(chunk.toString()).toEqual("test"); - callback(); - }, - }); - - stream.pipe(dest); - }); - - it("should write nothing when calling pipe and unpipe", async () => { - const rawStream = new ReadableStream({ - start(controller) { - controller.enqueue(new TextEncoder().encode("test")); - controller.enqueue(new TextEncoder().encode("test")); - controller.close(); - }, - }); - const stream = new Node18UniversalStreamWrapper(rawStream); - const buffer: Uint8Array[] = []; - const dest = new WritableStream({ - write(chunk) { - buffer.push(chunk); - }, - }); - - stream.pipe(dest); - stream.unpipe(dest); - expect(buffer).toEqual([]); - }); - - it("should destroy the stream", async () => { - const rawStream = new ReadableStream(); - const stream = new Node18UniversalStreamWrapper(rawStream); - const destroySpy = jest.spyOn(stream, "destroy"); - - stream.destroy(); - - expect(destroySpy).toHaveBeenCalled(); - }); - - it("should pause and resume the stream", async () => { - const rawStream = new ReadableStream(); - const stream = new Node18UniversalStreamWrapper(rawStream); - const pauseSpy = jest.spyOn(stream, "pause"); - const resumeSpy = jest.spyOn(stream, "resume"); - - expect(stream.isPaused).toBe(false); - stream.pause(); - expect(stream.isPaused).toBe(true); - stream.resume(); - - expect(pauseSpy).toHaveBeenCalled(); - expect(resumeSpy).toHaveBeenCalled(); - }); - - it("should read the stream", async () => { - const rawStream = new ReadableStream({ - start(controller) { - controller.enqueue(new TextEncoder().encode("test")); - controller.enqueue(new TextEncoder().encode("test")); - controller.close(); - }, - }); - const stream = new Node18UniversalStreamWrapper(rawStream); - - expect(await stream.read()).toEqual(new TextEncoder().encode("test")); - expect(await stream.read()).toEqual(new TextEncoder().encode("test")); - }); - - it("should read the stream as text", async () => { - const rawStream = new ReadableStream({ - start(controller) { - controller.enqueue(new TextEncoder().encode("test")); - controller.enqueue(new TextEncoder().encode("test")); - controller.close(); - }, - }); - const stream = new Node18UniversalStreamWrapper(rawStream); - - const data = await stream.text(); - - expect(data).toEqual("testtest"); - }); - - it("should read the stream as json", async () => { - const rawStream = new ReadableStream({ - start(controller) { - controller.enqueue(new TextEncoder().encode(JSON.stringify({ test: "test" }))); - controller.close(); - }, - }); - const stream = new Node18UniversalStreamWrapper(rawStream); - - const data = await stream.json(); - - expect(data).toEqual({ test: "test" }); - }); - - it("should allow use with async iterable stream", async () => { - const rawStream = new ReadableStream({ - start(controller) { - controller.enqueue(new TextEncoder().encode("test")); - controller.enqueue(new TextEncoder().encode("test")); - controller.close(); - }, - }); - let data = ""; - const stream = new Node18UniversalStreamWrapper(rawStream); - for await (const chunk of stream) { - data += new TextDecoder().decode(chunk); - } - - expect(data).toEqual("testtest"); - }); -}); diff --git a/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts b/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts deleted file mode 100644 index 19c26668..00000000 --- a/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts +++ /dev/null @@ -1,124 +0,0 @@ -import { NodePre18StreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/NodePre18StreamWrapper"; - -describe("NodePre18StreamWrapper", () => { - it("should set encoding to utf-8", async () => { - const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); - const stream = new NodePre18StreamWrapper(rawStream); - const setEncodingSpy = jest.spyOn(stream, "setEncoding"); - - stream.setEncoding("utf-8"); - - expect(setEncodingSpy).toHaveBeenCalledWith("utf-8"); - }); - - it("should register an event listener for readable", async () => { - const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); - const stream = new NodePre18StreamWrapper(rawStream); - const onSpy = jest.spyOn(stream, "on"); - - stream.on("readable", () => {}); - - expect(onSpy).toHaveBeenCalledWith("readable", expect.any(Function)); - }); - - it("should remove an event listener for data", async () => { - const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); - const stream = new NodePre18StreamWrapper(rawStream); - const offSpy = jest.spyOn(stream, "off"); - - const fn = () => {}; - stream.on("data", fn); - stream.off("data", fn); - - expect(offSpy).toHaveBeenCalledWith("data", expect.any(Function)); - }); - - it("should write to dest when calling pipe to node writable stream", async () => { - const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); - const stream = new NodePre18StreamWrapper(rawStream); - const dest = new (await import("readable-stream")).Writable({ - write(chunk, encoding, callback) { - expect(chunk.toString()).toEqual("test"); - callback(); - }, - }); - - stream.pipe(dest); - }); - - it("should write nothing when calling pipe and unpipe", async () => { - const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); - const stream = new NodePre18StreamWrapper(rawStream); - const buffer: Uint8Array[] = []; - const dest = new (await import("readable-stream")).Writable({ - write(chunk, encoding, callback) { - buffer.push(chunk); - callback(); - }, - }); - stream.pipe(dest); - stream.unpipe(); - - expect(buffer).toEqual([]); - }); - - it("should destroy the stream", async () => { - const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); - const stream = new NodePre18StreamWrapper(rawStream); - const destroySpy = jest.spyOn(stream, "destroy"); - - stream.destroy(); - - expect(destroySpy).toHaveBeenCalledWith(); - }); - - it("should pause the stream and resume", async () => { - const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); - const stream = new NodePre18StreamWrapper(rawStream); - const pauseSpy = jest.spyOn(stream, "pause"); - - stream.pause(); - expect(stream.isPaused).toBe(true); - stream.resume(); - expect(stream.isPaused).toBe(false); - - expect(pauseSpy).toHaveBeenCalledWith(); - }); - - it("should read the stream", async () => { - const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); - const stream = new NodePre18StreamWrapper(rawStream); - - expect(await stream.read()).toEqual("test"); - expect(await stream.read()).toEqual("test"); - }); - - it("should read the stream as text", async () => { - const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); - const stream = new NodePre18StreamWrapper(rawStream); - - const data = await stream.text(); - - expect(data).toEqual("testtest"); - }); - - it("should read the stream as json", async () => { - const rawStream = (await import("readable-stream")).Readable.from([JSON.stringify({ test: "test" })]); - const stream = new NodePre18StreamWrapper(rawStream); - - const data = await stream.json(); - - expect(data).toEqual({ test: "test" }); - }); - - it("should allow use with async iterable stream", async () => { - const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); - let data = ""; - const stream = new NodePre18StreamWrapper(rawStream); - for await (const chunk of stream) { - data += chunk; - } - - expect(data).toEqual("testtest"); - }); -}); diff --git a/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts b/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts deleted file mode 100644 index 0ea14835..00000000 --- a/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts +++ /dev/null @@ -1,153 +0,0 @@ -import { UndiciStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/UndiciStreamWrapper"; - -describe("UndiciStreamWrapper", () => { - it("should set encoding to utf-8", async () => { - const rawStream = new ReadableStream(); - const stream = new UndiciStreamWrapper(rawStream); - const setEncodingSpy = jest.spyOn(stream, "setEncoding"); - - stream.setEncoding("utf-8"); - - expect(setEncodingSpy).toHaveBeenCalledWith("utf-8"); - }); - - it("should register an event listener for readable", async () => { - const rawStream = new ReadableStream(); - const stream = new UndiciStreamWrapper(rawStream); - const onSpy = jest.spyOn(stream, "on"); - - stream.on("readable", () => {}); - - expect(onSpy).toHaveBeenCalledWith("readable", expect.any(Function)); - }); - - it("should remove an event listener for data", async () => { - const rawStream = new ReadableStream(); - const stream = new UndiciStreamWrapper(rawStream); - const offSpy = jest.spyOn(stream, "off"); - - const fn = () => {}; - stream.on("data", fn); - stream.off("data", fn); - - expect(offSpy).toHaveBeenCalledWith("data", expect.any(Function)); - }); - - it("should write to dest when calling pipe to writable stream", async () => { - const rawStream = new ReadableStream({ - start(controller) { - controller.enqueue(new TextEncoder().encode("test")); - controller.enqueue(new TextEncoder().encode("test")); - controller.close(); - }, - }); - const stream = new UndiciStreamWrapper(rawStream); - const dest = new WritableStream({ - write(chunk) { - expect(chunk).toEqual(new TextEncoder().encode("test")); - }, - }); - - stream.pipe(dest); - }); - - it("should write nothing when calling pipe and unpipe", async () => { - const rawStream = new ReadableStream(); - const stream = new UndiciStreamWrapper(rawStream); - const buffer: Uint8Array[] = []; - const dest = new WritableStream({ - write(chunk) { - buffer.push(chunk); - }, - }); - stream.pipe(dest); - stream.unpipe(dest); - - expect(buffer).toEqual([]); - }); - - it("should destroy the stream", async () => { - const rawStream = new ReadableStream(); - const stream = new UndiciStreamWrapper(rawStream); - const destroySpy = jest.spyOn(stream, "destroy"); - - stream.destroy(); - - expect(destroySpy).toHaveBeenCalled(); - }); - - it("should pause and resume the stream", async () => { - const rawStream = new ReadableStream(); - const stream = new UndiciStreamWrapper(rawStream); - const pauseSpy = jest.spyOn(stream, "pause"); - const resumeSpy = jest.spyOn(stream, "resume"); - - expect(stream.isPaused).toBe(false); - stream.pause(); - expect(stream.isPaused).toBe(true); - stream.resume(); - - expect(pauseSpy).toHaveBeenCalled(); - expect(resumeSpy).toHaveBeenCalled(); - }); - - it("should read the stream", async () => { - const rawStream = new ReadableStream({ - start(controller) { - controller.enqueue(new TextEncoder().encode("test")); - controller.enqueue(new TextEncoder().encode("test")); - controller.close(); - }, - }); - const stream = new UndiciStreamWrapper(rawStream); - - expect(await stream.read()).toEqual(new TextEncoder().encode("test")); - expect(await stream.read()).toEqual(new TextEncoder().encode("test")); - }); - - it("should read the stream as text", async () => { - const rawStream = new ReadableStream({ - start(controller) { - controller.enqueue(new TextEncoder().encode("test")); - controller.enqueue(new TextEncoder().encode("test")); - controller.close(); - }, - }); - const stream = new UndiciStreamWrapper(rawStream); - - const data = await stream.text(); - - expect(data).toEqual("testtest"); - }); - - it("should read the stream as json", async () => { - const rawStream = new ReadableStream({ - start(controller) { - controller.enqueue(new TextEncoder().encode(JSON.stringify({ test: "test" }))); - controller.close(); - }, - }); - const stream = new UndiciStreamWrapper(rawStream); - - const data = await stream.json(); - - expect(data).toEqual({ test: "test" }); - }); - - it("should allow use with async iterable stream", async () => { - const rawStream = new ReadableStream({ - start(controller) { - controller.enqueue(new TextEncoder().encode("test")); - controller.enqueue(new TextEncoder().encode("test")); - controller.close(); - }, - }); - let data = ""; - const stream = new UndiciStreamWrapper(rawStream); - for await (const chunk of stream) { - data += new TextDecoder().decode(chunk); - } - - expect(data).toEqual("testtest"); - }); -}); diff --git a/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts b/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts deleted file mode 100644 index 8004e9ab..00000000 --- a/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts +++ /dev/null @@ -1,43 +0,0 @@ -import { RUNTIME } from "../../../../src/core/runtime"; -import { Node18UniversalStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper"; -import { NodePre18StreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/NodePre18StreamWrapper"; -import { UndiciStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/UndiciStreamWrapper"; -import { chooseStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/chooseStreamWrapper"; - -describe("chooseStreamWrapper", () => { - beforeEach(() => { - RUNTIME.type = "unknown"; - RUNTIME.parsedVersion = 0; - }); - - it('should return a Node18UniversalStreamWrapper when RUNTIME.type is "node" and RUNTIME.parsedVersion is not null and RUNTIME.parsedVersion is greater than or equal to 18', async () => { - const expected = new Node18UniversalStreamWrapper(new ReadableStream()); - RUNTIME.type = "node"; - RUNTIME.parsedVersion = 18; - - const result = await chooseStreamWrapper(new ReadableStream()); - - expect(JSON.stringify(result)).toBe(JSON.stringify(expected)); - }); - - it('should return a NodePre18StreamWrapper when RUNTIME.type is "node" and RUNTIME.parsedVersion is not null and RUNTIME.parsedVersion is less than 18', async () => { - const stream = await import("readable-stream"); - const expected = new NodePre18StreamWrapper(new stream.Readable()); - - RUNTIME.type = "node"; - RUNTIME.parsedVersion = 16; - - const result = await chooseStreamWrapper(new stream.Readable()); - - expect(JSON.stringify(result)).toEqual(JSON.stringify(expected)); - }); - - it('should return a Undici when RUNTIME.type is not "node"', async () => { - const expected = new UndiciStreamWrapper(new ReadableStream()); - RUNTIME.type = "browser"; - - const result = await chooseStreamWrapper(new ReadableStream()); - - expect(JSON.stringify(result)).toEqual(JSON.stringify(expected)); - }); -}); diff --git a/tests/unit/fetcher/stream-wrappers/webpack.test.ts b/tests/unit/fetcher/stream-wrappers/webpack.test.ts deleted file mode 100644 index f7537d3c..00000000 --- a/tests/unit/fetcher/stream-wrappers/webpack.test.ts +++ /dev/null @@ -1,42 +0,0 @@ -import webpack from "webpack"; - -describe("test env compatibility", () => { - test("webpack", () => { - return new Promise((resolve, reject) => { - webpack( - { - mode: "production", - entry: "./src/index.ts", - module: { - rules: [ - { - test: /\.tsx?$/, - use: "ts-loader", - exclude: /node_modules/, - }, - ], - }, - resolve: { - extensions: [".tsx", ".ts", ".jsx", ".js"], - extensionAlias: { - ".js": [".ts", ".js"], - ".jsx": [".tsx", ".jsx"], - }, - }, - }, - (err, stats) => { - try { - expect(err).toBe(null); - if (stats?.hasErrors()) { - console.log(stats?.toString()); - } - expect(stats?.hasErrors()).toBe(false); - resolve(); - } catch (error) { - reject(error); - } - }, - ); - }); - }, 180_000); -}); diff --git a/tests/unit/logging/logger.test.ts b/tests/unit/logging/logger.test.ts new file mode 100644 index 00000000..2e0b5fe5 --- /dev/null +++ b/tests/unit/logging/logger.test.ts @@ -0,0 +1,454 @@ +import { ConsoleLogger, createLogger, Logger, LogLevel } from "../../../src/core/logging/logger"; + +function createMockLogger() { + return { + debug: vi.fn(), + info: vi.fn(), + warn: vi.fn(), + error: vi.fn(), + }; +} + +describe("Logger", () => { + describe("LogLevel", () => { + it("should have correct log levels", () => { + expect(LogLevel.Debug).toBe("debug"); + expect(LogLevel.Info).toBe("info"); + expect(LogLevel.Warn).toBe("warn"); + expect(LogLevel.Error).toBe("error"); + }); + }); + + describe("ConsoleLogger", () => { + let consoleLogger: ConsoleLogger; + let consoleSpy: { + debug: ReturnType; + info: ReturnType; + warn: ReturnType; + error: ReturnType; + }; + + beforeEach(() => { + consoleLogger = new ConsoleLogger(); + consoleSpy = { + debug: vi.spyOn(console, "debug").mockImplementation(() => {}), + info: vi.spyOn(console, "info").mockImplementation(() => {}), + warn: vi.spyOn(console, "warn").mockImplementation(() => {}), + error: vi.spyOn(console, "error").mockImplementation(() => {}), + }; + }); + + afterEach(() => { + consoleSpy.debug.mockRestore(); + consoleSpy.info.mockRestore(); + consoleSpy.warn.mockRestore(); + consoleSpy.error.mockRestore(); + }); + + it("should log debug messages", () => { + consoleLogger.debug("debug message", { data: "test" }); + expect(consoleSpy.debug).toHaveBeenCalledWith("debug message", { data: "test" }); + }); + + it("should log info messages", () => { + consoleLogger.info("info message", { data: "test" }); + expect(consoleSpy.info).toHaveBeenCalledWith("info message", { data: "test" }); + }); + + it("should log warn messages", () => { + consoleLogger.warn("warn message", { data: "test" }); + expect(consoleSpy.warn).toHaveBeenCalledWith("warn message", { data: "test" }); + }); + + it("should log error messages", () => { + consoleLogger.error("error message", { data: "test" }); + expect(consoleSpy.error).toHaveBeenCalledWith("error message", { data: "test" }); + }); + + it("should handle multiple arguments", () => { + consoleLogger.debug("message", "arg1", "arg2", { key: "value" }); + expect(consoleSpy.debug).toHaveBeenCalledWith("message", "arg1", "arg2", { key: "value" }); + }); + }); + + describe("Logger with level filtering", () => { + let mockLogger: { + debug: ReturnType; + info: ReturnType; + warn: ReturnType; + error: ReturnType; + }; + + beforeEach(() => { + mockLogger = createMockLogger(); + }); + + describe("Debug level", () => { + it("should log all levels when set to debug", () => { + const logger = new Logger({ + level: LogLevel.Debug, + logger: mockLogger, + silent: false, + }); + + logger.debug("debug"); + logger.info("info"); + logger.warn("warn"); + logger.error("error"); + + expect(mockLogger.debug).toHaveBeenCalledWith("debug"); + expect(mockLogger.info).toHaveBeenCalledWith("info"); + expect(mockLogger.warn).toHaveBeenCalledWith("warn"); + expect(mockLogger.error).toHaveBeenCalledWith("error"); + }); + + it("should report correct level checks", () => { + const logger = new Logger({ + level: LogLevel.Debug, + logger: mockLogger, + silent: false, + }); + + expect(logger.isDebug()).toBe(true); + expect(logger.isInfo()).toBe(true); + expect(logger.isWarn()).toBe(true); + expect(logger.isError()).toBe(true); + }); + }); + + describe("Info level", () => { + it("should log info, warn, and error when set to info", () => { + const logger = new Logger({ + level: LogLevel.Info, + logger: mockLogger, + silent: false, + }); + + logger.debug("debug"); + logger.info("info"); + logger.warn("warn"); + logger.error("error"); + + expect(mockLogger.debug).not.toHaveBeenCalled(); + expect(mockLogger.info).toHaveBeenCalledWith("info"); + expect(mockLogger.warn).toHaveBeenCalledWith("warn"); + expect(mockLogger.error).toHaveBeenCalledWith("error"); + }); + + it("should report correct level checks", () => { + const logger = new Logger({ + level: LogLevel.Info, + logger: mockLogger, + silent: false, + }); + + expect(logger.isDebug()).toBe(false); + expect(logger.isInfo()).toBe(true); + expect(logger.isWarn()).toBe(true); + expect(logger.isError()).toBe(true); + }); + }); + + describe("Warn level", () => { + it("should log warn and error when set to warn", () => { + const logger = new Logger({ + level: LogLevel.Warn, + logger: mockLogger, + silent: false, + }); + + logger.debug("debug"); + logger.info("info"); + logger.warn("warn"); + logger.error("error"); + + expect(mockLogger.debug).not.toHaveBeenCalled(); + expect(mockLogger.info).not.toHaveBeenCalled(); + expect(mockLogger.warn).toHaveBeenCalledWith("warn"); + expect(mockLogger.error).toHaveBeenCalledWith("error"); + }); + + it("should report correct level checks", () => { + const logger = new Logger({ + level: LogLevel.Warn, + logger: mockLogger, + silent: false, + }); + + expect(logger.isDebug()).toBe(false); + expect(logger.isInfo()).toBe(false); + expect(logger.isWarn()).toBe(true); + expect(logger.isError()).toBe(true); + }); + }); + + describe("Error level", () => { + it("should only log error when set to error", () => { + const logger = new Logger({ + level: LogLevel.Error, + logger: mockLogger, + silent: false, + }); + + logger.debug("debug"); + logger.info("info"); + logger.warn("warn"); + logger.error("error"); + + expect(mockLogger.debug).not.toHaveBeenCalled(); + expect(mockLogger.info).not.toHaveBeenCalled(); + expect(mockLogger.warn).not.toHaveBeenCalled(); + expect(mockLogger.error).toHaveBeenCalledWith("error"); + }); + + it("should report correct level checks", () => { + const logger = new Logger({ + level: LogLevel.Error, + logger: mockLogger, + silent: false, + }); + + expect(logger.isDebug()).toBe(false); + expect(logger.isInfo()).toBe(false); + expect(logger.isWarn()).toBe(false); + expect(logger.isError()).toBe(true); + }); + }); + + describe("Silent mode", () => { + it("should not log anything when silent is true", () => { + const logger = new Logger({ + level: LogLevel.Debug, + logger: mockLogger, + silent: true, + }); + + logger.debug("debug"); + logger.info("info"); + logger.warn("warn"); + logger.error("error"); + + expect(mockLogger.debug).not.toHaveBeenCalled(); + expect(mockLogger.info).not.toHaveBeenCalled(); + expect(mockLogger.warn).not.toHaveBeenCalled(); + expect(mockLogger.error).not.toHaveBeenCalled(); + }); + + it("should report all level checks as false when silent", () => { + const logger = new Logger({ + level: LogLevel.Debug, + logger: mockLogger, + silent: true, + }); + + expect(logger.isDebug()).toBe(false); + expect(logger.isInfo()).toBe(false); + expect(logger.isWarn()).toBe(false); + expect(logger.isError()).toBe(false); + }); + }); + + describe("shouldLog", () => { + it("should correctly determine if level should be logged", () => { + const logger = new Logger({ + level: LogLevel.Info, + logger: mockLogger, + silent: false, + }); + + expect(logger.shouldLog(LogLevel.Debug)).toBe(false); + expect(logger.shouldLog(LogLevel.Info)).toBe(true); + expect(logger.shouldLog(LogLevel.Warn)).toBe(true); + expect(logger.shouldLog(LogLevel.Error)).toBe(true); + }); + + it("should return false for all levels when silent", () => { + const logger = new Logger({ + level: LogLevel.Debug, + logger: mockLogger, + silent: true, + }); + + expect(logger.shouldLog(LogLevel.Debug)).toBe(false); + expect(logger.shouldLog(LogLevel.Info)).toBe(false); + expect(logger.shouldLog(LogLevel.Warn)).toBe(false); + expect(logger.shouldLog(LogLevel.Error)).toBe(false); + }); + }); + + describe("Multiple arguments", () => { + it("should pass multiple arguments to logger", () => { + const logger = new Logger({ + level: LogLevel.Debug, + logger: mockLogger, + silent: false, + }); + + logger.debug("message", "arg1", { key: "value" }, 123); + expect(mockLogger.debug).toHaveBeenCalledWith("message", "arg1", { key: "value" }, 123); + }); + }); + }); + + describe("createLogger", () => { + it("should return default logger when no config provided", () => { + const logger = createLogger(); + expect(logger).toBeInstanceOf(Logger); + }); + + it("should return same logger instance when Logger is passed", () => { + const customLogger = new Logger({ + level: LogLevel.Debug, + logger: new ConsoleLogger(), + silent: false, + }); + + const result = createLogger(customLogger); + expect(result).toBe(customLogger); + }); + + it("should create logger with custom config", () => { + const mockLogger = createMockLogger(); + + const logger = createLogger({ + level: LogLevel.Warn, + logger: mockLogger, + silent: false, + }); + + expect(logger).toBeInstanceOf(Logger); + logger.warn("test"); + expect(mockLogger.warn).toHaveBeenCalledWith("test"); + }); + + it("should use default values for missing config", () => { + const logger = createLogger({}); + expect(logger).toBeInstanceOf(Logger); + }); + + it("should override default level", () => { + const mockLogger = createMockLogger(); + + const logger = createLogger({ + level: LogLevel.Debug, + logger: mockLogger, + silent: false, + }); + + logger.debug("test"); + expect(mockLogger.debug).toHaveBeenCalledWith("test"); + }); + + it("should override default silent mode", () => { + const mockLogger = createMockLogger(); + + const logger = createLogger({ + logger: mockLogger, + silent: false, + }); + + logger.info("test"); + expect(mockLogger.info).toHaveBeenCalledWith("test"); + }); + + it("should use provided logger implementation", () => { + const customLogger = createMockLogger(); + + const logger = createLogger({ + logger: customLogger, + level: LogLevel.Debug, + silent: false, + }); + + logger.debug("test"); + expect(customLogger.debug).toHaveBeenCalledWith("test"); + }); + + it("should default to silent: true", () => { + const mockLogger = createMockLogger(); + + const logger = createLogger({ + logger: mockLogger, + level: LogLevel.Debug, + }); + + logger.debug("test"); + expect(mockLogger.debug).not.toHaveBeenCalled(); + }); + }); + + describe("Default logger", () => { + it("should have silent: true by default", () => { + const logger = createLogger(); + expect(logger.shouldLog(LogLevel.Info)).toBe(false); + }); + + it("should not log when using default logger", () => { + const logger = createLogger(); + + logger.info("test"); + expect(logger.isInfo()).toBe(false); + }); + }); + + describe("Edge cases", () => { + it("should handle empty message", () => { + const mockLogger = createMockLogger(); + + const logger = new Logger({ + level: LogLevel.Debug, + logger: mockLogger, + silent: false, + }); + + logger.debug(""); + expect(mockLogger.debug).toHaveBeenCalledWith(""); + }); + + it("should handle no arguments", () => { + const mockLogger = createMockLogger(); + + const logger = new Logger({ + level: LogLevel.Debug, + logger: mockLogger, + silent: false, + }); + + logger.debug("message"); + expect(mockLogger.debug).toHaveBeenCalledWith("message"); + }); + + it("should handle complex objects", () => { + const mockLogger = createMockLogger(); + + const logger = new Logger({ + level: LogLevel.Debug, + logger: mockLogger, + silent: false, + }); + + const complexObject = { + nested: { key: "value" }, + array: [1, 2, 3], + fn: () => "test", + }; + + logger.debug("message", complexObject); + expect(mockLogger.debug).toHaveBeenCalledWith("message", complexObject); + }); + + it("should handle errors as arguments", () => { + const mockLogger = createMockLogger(); + + const logger = new Logger({ + level: LogLevel.Error, + logger: mockLogger, + silent: false, + }); + + const error = new Error("Test error"); + logger.error("Error occurred", error); + expect(mockLogger.error).toHaveBeenCalledWith("Error occurred", error); + }); + }); +}); diff --git a/tests/unit/url/join.test.ts b/tests/unit/url/join.test.ts new file mode 100644 index 00000000..123488f0 --- /dev/null +++ b/tests/unit/url/join.test.ts @@ -0,0 +1,284 @@ +import { join } from "../../../src/core/url/index"; + +describe("join", () => { + interface TestCase { + description: string; + base: string; + segments: string[]; + expected: string; + } + + describe("basic functionality", () => { + const basicTests: TestCase[] = [ + { description: "should return empty string for empty base", base: "", segments: [], expected: "" }, + { + description: "should return empty string for empty base with path", + base: "", + segments: ["path"], + expected: "", + }, + { + description: "should handle single segment", + base: "base", + segments: ["segment"], + expected: "base/segment", + }, + { + description: "should handle single segment with trailing slash on base", + base: "base/", + segments: ["segment"], + expected: "base/segment", + }, + { + description: "should handle single segment with leading slash", + base: "base", + segments: ["/segment"], + expected: "base/segment", + }, + { + description: "should handle single segment with both slashes", + base: "base/", + segments: ["/segment"], + expected: "base/segment", + }, + { + description: "should handle multiple segments", + base: "base", + segments: ["path1", "path2", "path3"], + expected: "base/path1/path2/path3", + }, + { + description: "should handle multiple segments with slashes", + base: "base/", + segments: ["/path1/", "/path2/", "/path3/"], + expected: "base/path1/path2/path3/", + }, + ]; + + basicTests.forEach(({ description, base, segments, expected }) => { + it(description, () => { + expect(join(base, ...segments)).toBe(expected); + }); + }); + }); + + describe("URL handling", () => { + const urlTests: TestCase[] = [ + { + description: "should handle absolute URLs", + base: "https://example.com", + segments: ["api", "v1"], + expected: "https://example.com/api/v1", + }, + { + description: "should handle absolute URLs with slashes", + base: "https://example.com/", + segments: ["/api/", "/v1/"], + expected: "https://example.com/api/v1/", + }, + { + description: "should handle absolute URLs with base path", + base: "https://example.com/base", + segments: ["api", "v1"], + expected: "https://example.com/base/api/v1", + }, + { + description: "should preserve URL query parameters", + base: "https://example.com?query=1", + segments: ["api"], + expected: "https://example.com/api?query=1", + }, + { + description: "should preserve URL fragments", + base: "https://example.com#fragment", + segments: ["api"], + expected: "https://example.com/api#fragment", + }, + { + description: "should preserve URL query and fragments", + base: "https://example.com?query=1#fragment", + segments: ["api"], + expected: "https://example.com/api?query=1#fragment", + }, + { + description: "should handle http protocol", + base: "http://example.com", + segments: ["api"], + expected: "http://example.com/api", + }, + { + description: "should handle ftp protocol", + base: "ftp://example.com", + segments: ["files"], + expected: "ftp://example.com/files", + }, + { + description: "should handle ws protocol", + base: "ws://example.com", + segments: ["socket"], + expected: "ws://example.com/socket", + }, + { + description: "should fallback to path joining for malformed URLs", + base: "not-a-url://", + segments: ["path"], + expected: "not-a-url:///path", + }, + ]; + + urlTests.forEach(({ description, base, segments, expected }) => { + it(description, () => { + expect(join(base, ...segments)).toBe(expected); + }); + }); + }); + + describe("edge cases", () => { + const edgeCaseTests: TestCase[] = [ + { + description: "should handle empty segments", + base: "base", + segments: ["", "path"], + expected: "base/path", + }, + { + description: "should handle null segments", + base: "base", + segments: [null as any, "path"], + expected: "base/path", + }, + { + description: "should handle undefined segments", + base: "base", + segments: [undefined as any, "path"], + expected: "base/path", + }, + { + description: "should handle segments with only single slash", + base: "base", + segments: ["/", "path"], + expected: "base/path", + }, + { + description: "should handle segments with only double slash", + base: "base", + segments: ["//", "path"], + expected: "base/path", + }, + { + description: "should handle base paths with trailing slashes", + base: "base/", + segments: ["path"], + expected: "base/path", + }, + { + description: "should handle complex nested paths", + base: "api/v1/", + segments: ["/users/", "/123/", "/profile"], + expected: "api/v1/users/123/profile", + }, + ]; + + edgeCaseTests.forEach(({ description, base, segments, expected }) => { + it(description, () => { + expect(join(base, ...segments)).toBe(expected); + }); + }); + }); + + describe("real-world scenarios", () => { + const realWorldTests: TestCase[] = [ + { + description: "should handle API endpoint construction", + base: "https://api.example.com/v1", + segments: ["users", "123", "posts"], + expected: "https://api.example.com/v1/users/123/posts", + }, + { + description: "should handle file path construction", + base: "/var/www", + segments: ["html", "assets", "images"], + expected: "/var/www/html/assets/images", + }, + { + description: "should handle relative path construction", + base: "../parent", + segments: ["child", "grandchild"], + expected: "../parent/child/grandchild", + }, + { + description: "should handle Windows-style paths", + base: "C:\\Users", + segments: ["Documents", "file.txt"], + expected: "C:\\Users/Documents/file.txt", + }, + ]; + + realWorldTests.forEach(({ description, base, segments, expected }) => { + it(description, () => { + expect(join(base, ...segments)).toBe(expected); + }); + }); + }); + + describe("performance scenarios", () => { + it("should handle many segments efficiently", () => { + const segments = Array(100).fill("segment"); + const result = join("base", ...segments); + expect(result).toBe(`base/${segments.join("/")}`); + }); + + it("should handle long URLs", () => { + const longPath = "a".repeat(1000); + expect(join("https://example.com", longPath)).toBe(`https://example.com/${longPath}`); + }); + }); + + describe("trailing slash preservation", () => { + const trailingSlashTests: TestCase[] = [ + { + description: + "should preserve trailing slash on final result when base has trailing slash and no segments", + base: "https://api.example.com/", + segments: [], + expected: "https://api.example.com/", + }, + { + description: "should preserve trailing slash on v1 path", + base: "https://api.example.com/v1/", + segments: [], + expected: "https://api.example.com/v1/", + }, + { + description: "should preserve trailing slash when last segment has trailing slash", + base: "https://api.example.com", + segments: ["users/"], + expected: "https://api.example.com/users/", + }, + { + description: "should preserve trailing slash with relative path", + base: "api/v1", + segments: ["users/"], + expected: "api/v1/users/", + }, + { + description: "should preserve trailing slash with multiple segments", + base: "https://api.example.com", + segments: ["v1", "collections/"], + expected: "https://api.example.com/v1/collections/", + }, + { + description: "should preserve trailing slash with base path", + base: "base", + segments: ["path1", "path2/"], + expected: "base/path1/path2/", + }, + ]; + + trailingSlashTests.forEach(({ description, base, segments, expected }) => { + it(description, () => { + expect(join(base, ...segments)).toBe(expected); + }); + }); + }); +}); diff --git a/tests/unit/url/qs.test.ts b/tests/unit/url/qs.test.ts new file mode 100644 index 00000000..42cdffb9 --- /dev/null +++ b/tests/unit/url/qs.test.ts @@ -0,0 +1,278 @@ +import { toQueryString } from "../../../src/core/url/index"; + +describe("Test qs toQueryString", () => { + interface BasicTestCase { + description: string; + input: any; + expected: string; + } + + describe("Basic functionality", () => { + const basicTests: BasicTestCase[] = [ + { description: "should return empty string for null", input: null, expected: "" }, + { description: "should return empty string for undefined", input: undefined, expected: "" }, + { description: "should return empty string for string primitive", input: "hello", expected: "" }, + { description: "should return empty string for number primitive", input: 42, expected: "" }, + { description: "should return empty string for true boolean", input: true, expected: "" }, + { description: "should return empty string for false boolean", input: false, expected: "" }, + { description: "should handle empty objects", input: {}, expected: "" }, + { + description: "should handle simple key-value pairs", + input: { name: "John", age: 30 }, + expected: "name=John&age=30", + }, + ]; + + basicTests.forEach(({ description, input, expected }) => { + it(description, () => { + expect(toQueryString(input)).toBe(expected); + }); + }); + }); + + describe("Array handling", () => { + interface ArrayTestCase { + description: string; + input: any; + options?: { arrayFormat?: "repeat" | "indices" }; + expected: string; + } + + const arrayTests: ArrayTestCase[] = [ + { + description: "should handle arrays with indices format (default)", + input: { items: ["a", "b", "c"] }, + expected: "items%5B0%5D=a&items%5B1%5D=b&items%5B2%5D=c", + }, + { + description: "should handle arrays with repeat format", + input: { items: ["a", "b", "c"] }, + options: { arrayFormat: "repeat" }, + expected: "items=a&items=b&items=c", + }, + { + description: "should handle empty arrays", + input: { items: [] }, + expected: "", + }, + { + description: "should handle arrays with mixed types", + input: { mixed: ["string", 42, true, false] }, + expected: "mixed%5B0%5D=string&mixed%5B1%5D=42&mixed%5B2%5D=true&mixed%5B3%5D=false", + }, + { + description: "should handle arrays with objects", + input: { users: [{ name: "John" }, { name: "Jane" }] }, + expected: "users%5B0%5D%5Bname%5D=John&users%5B1%5D%5Bname%5D=Jane", + }, + { + description: "should handle arrays with objects in repeat format", + input: { users: [{ name: "John" }, { name: "Jane" }] }, + options: { arrayFormat: "repeat" }, + expected: "users%5Bname%5D=John&users%5Bname%5D=Jane", + }, + ]; + + arrayTests.forEach(({ description, input, options, expected }) => { + it(description, () => { + expect(toQueryString(input, options)).toBe(expected); + }); + }); + }); + + describe("Nested objects", () => { + const nestedTests: BasicTestCase[] = [ + { + description: "should handle nested objects", + input: { user: { name: "John", age: 30 } }, + expected: "user%5Bname%5D=John&user%5Bage%5D=30", + }, + { + description: "should handle deeply nested objects", + input: { user: { profile: { name: "John", settings: { theme: "dark" } } } }, + expected: "user%5Bprofile%5D%5Bname%5D=John&user%5Bprofile%5D%5Bsettings%5D%5Btheme%5D=dark", + }, + { + description: "should handle empty nested objects", + input: { user: {} }, + expected: "", + }, + ]; + + nestedTests.forEach(({ description, input, expected }) => { + it(description, () => { + expect(toQueryString(input)).toBe(expected); + }); + }); + }); + + describe("Encoding", () => { + interface EncodingTestCase { + description: string; + input: any; + options?: { encode?: boolean }; + expected: string; + } + + const encodingTests: EncodingTestCase[] = [ + { + description: "should encode by default", + input: { name: "John Doe", email: "john@example.com" }, + expected: "name=John%20Doe&email=john%40example.com", + }, + { + description: "should not encode when encode is false", + input: { name: "John Doe", email: "john@example.com" }, + options: { encode: false }, + expected: "name=John Doe&email=john@example.com", + }, + { + description: "should encode special characters in keys", + input: { "user name": "John", "email[primary]": "john@example.com" }, + expected: "user%20name=John&email%5Bprimary%5D=john%40example.com", + }, + { + description: "should not encode special characters in keys when encode is false", + input: { "user name": "John", "email[primary]": "john@example.com" }, + options: { encode: false }, + expected: "user name=John&email[primary]=john@example.com", + }, + ]; + + encodingTests.forEach(({ description, input, options, expected }) => { + it(description, () => { + expect(toQueryString(input, options)).toBe(expected); + }); + }); + }); + + describe("Mixed scenarios", () => { + interface MixedTestCase { + description: string; + input: any; + options?: { arrayFormat?: "repeat" | "indices" }; + expected: string; + } + + const mixedTests: MixedTestCase[] = [ + { + description: "should handle complex nested structures", + input: { + filters: { + status: ["active", "pending"], + category: { + type: "electronics", + subcategories: ["phones", "laptops"], + }, + }, + sort: { field: "name", direction: "asc" }, + }, + expected: + "filters%5Bstatus%5D%5B0%5D=active&filters%5Bstatus%5D%5B1%5D=pending&filters%5Bcategory%5D%5Btype%5D=electronics&filters%5Bcategory%5D%5Bsubcategories%5D%5B0%5D=phones&filters%5Bcategory%5D%5Bsubcategories%5D%5B1%5D=laptops&sort%5Bfield%5D=name&sort%5Bdirection%5D=asc", + }, + { + description: "should handle complex nested structures with repeat format", + input: { + filters: { + status: ["active", "pending"], + category: { + type: "electronics", + subcategories: ["phones", "laptops"], + }, + }, + sort: { field: "name", direction: "asc" }, + }, + options: { arrayFormat: "repeat" }, + expected: + "filters%5Bstatus%5D=active&filters%5Bstatus%5D=pending&filters%5Bcategory%5D%5Btype%5D=electronics&filters%5Bcategory%5D%5Bsubcategories%5D=phones&filters%5Bcategory%5D%5Bsubcategories%5D=laptops&sort%5Bfield%5D=name&sort%5Bdirection%5D=asc", + }, + { + description: "should handle arrays with null/undefined values", + input: { items: ["a", null, "c", undefined, "e"] }, + expected: "items%5B0%5D=a&items%5B1%5D=&items%5B2%5D=c&items%5B4%5D=e", + }, + { + description: "should handle objects with null/undefined values", + input: { name: "John", age: null, email: undefined, active: true }, + expected: "name=John&age=&active=true", + }, + ]; + + mixedTests.forEach(({ description, input, options, expected }) => { + it(description, () => { + expect(toQueryString(input, options)).toBe(expected); + }); + }); + }); + + describe("Edge cases", () => { + const edgeCaseTests: BasicTestCase[] = [ + { + description: "should handle numeric keys", + input: { "0": "zero", "1": "one" }, + expected: "0=zero&1=one", + }, + { + description: "should handle boolean values in objects", + input: { enabled: true, disabled: false }, + expected: "enabled=true&disabled=false", + }, + { + description: "should handle empty strings", + input: { name: "", description: "test" }, + expected: "name=&description=test", + }, + { + description: "should handle zero values", + input: { count: 0, price: 0.0 }, + expected: "count=0&price=0", + }, + { + description: "should handle arrays with empty strings", + input: { items: ["a", "", "c"] }, + expected: "items%5B0%5D=a&items%5B1%5D=&items%5B2%5D=c", + }, + ]; + + edgeCaseTests.forEach(({ description, input, expected }) => { + it(description, () => { + expect(toQueryString(input)).toBe(expected); + }); + }); + }); + + describe("Options combinations", () => { + interface OptionsTestCase { + description: string; + input: any; + options?: { arrayFormat?: "repeat" | "indices"; encode?: boolean }; + expected: string; + } + + const optionsTests: OptionsTestCase[] = [ + { + description: "should respect both arrayFormat and encode options", + input: { items: ["a & b", "c & d"] }, + options: { arrayFormat: "repeat", encode: false }, + expected: "items=a & b&items=c & d", + }, + { + description: "should use default options when none provided", + input: { items: ["a", "b"] }, + expected: "items%5B0%5D=a&items%5B1%5D=b", + }, + { + description: "should merge provided options with defaults", + input: { items: ["a", "b"], name: "John Doe" }, + options: { encode: false }, + expected: "items[0]=a&items[1]=b&name=John Doe", + }, + ]; + + optionsTests.forEach(({ description, input, options, expected }) => { + it(description, () => { + expect(toQueryString(input, options)).toBe(expected); + }); + }); + }); +}); diff --git a/tests/unit/utils/setObjectProperty.test.ts b/tests/unit/utils/setObjectProperty.test.ts new file mode 100644 index 00000000..29f8e638 --- /dev/null +++ b/tests/unit/utils/setObjectProperty.test.ts @@ -0,0 +1,76 @@ +import { setObjectProperty } from "../../../src/core/utils/setObjectProperty"; + +interface TestCase { + description: string; + giveObject: object; + givePath: string; + giveValue: any; + wantObject: object; +} + +describe("Test setObjectProperty", () => { + const testCases: TestCase[] = [ + { + description: "empty", + giveObject: {}, + givePath: "", + giveValue: 0, + wantObject: { "": 0 }, + }, + { + description: "top-level primitive", + giveObject: {}, + givePath: "age", + giveValue: 42, + wantObject: { age: 42 }, + }, + { + description: "top-level object", + giveObject: {}, + givePath: "name", + giveValue: { first: "John", last: "Doe" }, + wantObject: { name: { first: "John", last: "Doe" } }, + }, + { + description: "top-level array", + giveObject: {}, + givePath: "values", + giveValue: [1, 2, 3], + wantObject: { values: [1, 2, 3] }, + }, + { + description: "nested object property", + giveObject: { + name: { + first: "John", + }, + }, + givePath: "name.last", + giveValue: "Doe", + wantObject: { name: { first: "John", last: "Doe" } }, + }, + { + description: "deeply nested object property", + giveObject: { + info: { + address: { + street: "123 Main St.", + }, + age: 42, + name: { + last: "Doe", + }, + }, + }, + givePath: "info.name.first", + giveValue: "John", + wantObject: { + info: { age: 42, address: { street: "123 Main St." }, name: { first: "John", last: "Doe" } }, + }, + }, + ]; + test.each(testCases)("$description", ({ giveObject, givePath, giveValue, wantObject }) => { + const result = setObjectProperty(giveObject, givePath, giveValue); + expect(result).toEqual(wantObject); + }); +}); diff --git a/tests/wire/.gitkeep b/tests/wire/.gitkeep new file mode 100644 index 00000000..e69de29b diff --git a/tests/wire/admins.test.ts b/tests/wire/admins.test.ts new file mode 100644 index 00000000..0f4be795 --- /dev/null +++ b/tests/wire/admins.test.ts @@ -0,0 +1,686 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("AdminsClient", () => { + test("identify", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "admin", + id: "991267459", + name: "Ciaran1 Lee", + email: "admin1@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + has_inbox_seat: true, + team_ids: [814865], + avatar: { + type: "avatar", + image_url: "https://static.intercomassets.com/assets/default-avatars/admins/128.png", + }, + email_verified: true, + app: { + type: "app", + id_code: "this_is_an_id1_that_should_be_at_least_40", + name: "MyApp 1", + region: "US", + timezone: "America/Los_Angeles", + created_at: 1734537243, + identity_verification: false, + }, + }; + server.mockEndpoint().get("/me").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.admins.identify(); + expect(response).toEqual({ + type: "admin", + id: "991267459", + name: "Ciaran1 Lee", + email: "admin1@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + has_inbox_seat: true, + team_ids: [814865], + avatar: { + type: "avatar", + image_url: "https://static.intercomassets.com/assets/default-avatars/admins/128.png", + }, + email_verified: true, + app: { + type: "app", + id_code: "this_is_an_id1_that_should_be_at_least_40", + name: "MyApp 1", + region: "US", + timezone: "America/Los_Angeles", + created_at: 1734537243, + identity_verification: false, + }, + }); + }); + + test("away (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { away_mode_enabled: true, away_mode_reassign: true, away_status_reason_id: 12345 }; + const rawResponseBody = { + type: "admin", + id: "991267460", + name: "Ciaran2 Lee", + email: "admin2@email.com", + job_title: "Associate", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { image_url: "https://example.org/128Wash.jpg" }, + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }; + server + .mockEndpoint() + .put("/admins/1/away") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.admins.away({ + admin_id: 1, + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, + }); + expect(response).toEqual({ + type: "admin", + id: "991267460", + name: "Ciaran2 Lee", + email: "admin2@email.com", + job_title: "Associate", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { + image_url: "https://example.org/128Wash.jpg", + }, + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }); + }); + + test("away (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { away_mode_enabled: true, away_mode_reassign: true }; + const rawResponseBody = { + type: "admin", + id: "991267460", + name: "Ciaran2 Lee", + email: "admin2@email.com", + job_title: "Associate", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { image_url: "https://example.org/128Wash.jpg" }, + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }; + server + .mockEndpoint() + .put("/admins/1/away") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.admins.away({ + admin_id: 1, + away_mode_enabled: true, + away_mode_reassign: true, + }); + expect(response).toEqual({ + type: "admin", + id: "991267460", + name: "Ciaran2 Lee", + email: "admin2@email.com", + job_title: "Associate", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { + image_url: "https://example.org/128Wash.jpg", + }, + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }); + }); + + test("away (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { away_mode_enabled: true, away_mode_reassign: true }; + const rawResponseBody = { + type: "admin", + id: "991267460", + name: "Ciaran2 Lee", + email: "admin2@email.com", + job_title: "Associate", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { image_url: "https://example.org/128Wash.jpg" }, + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }; + server + .mockEndpoint() + .put("/admins/1/away") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.admins.away({ + admin_id: 1, + away_mode_enabled: true, + away_mode_reassign: true, + }); + expect(response).toEqual({ + type: "admin", + id: "991267460", + name: "Ciaran2 Lee", + email: "admin2@email.com", + job_title: "Associate", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { + image_url: "https://example.org/128Wash.jpg", + }, + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }); + }); + + test("away (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { away_mode_enabled: true, away_mode_reassign: true }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/admins/1/away") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.admins.away({ + admin_id: 1, + away_mode_enabled: true, + away_mode_reassign: true, + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("away (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { away_mode_enabled: true, away_mode_reassign: true }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/admins/1/away") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.admins.away({ + admin_id: 1, + away_mode_enabled: true, + away_mode_reassign: true, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("away (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { away_mode_enabled: true, away_mode_reassign: true }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/admins/1/away") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.admins.away({ + admin_id: 1, + away_mode_enabled: true, + away_mode_reassign: true, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("listAllActivityLogs (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "activity_log.list", + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 20, + total_pages: 1, + }, + activity_logs: [ + { + id: "fca05814-4b72-4dce-ad4f-77a786a2c136", + performed_by: { type: "admin", id: "991267464", email: "admin5@email.com", ip: "127.0.0.1" }, + metadata: { + sign_in_method: "email_password", + external_id: "f3b87a2e09d514c6c2e79b9a", + away_mode: true, + away_status_reason: "😌 On a break", + reassign_conversations: false, + source: "admin update from web - Admin id: 93", + update_by: 93, + update_by_name: "Joe Example", + conversation_assignment_limit: 15, + ticket_assignment_limit: 20, + team_assignment_limit: 50, + enabled: true, + consent_id: 149673, + expired_at: "2025-12-04T09:31:57Z", + before: { key: "value" }, + after: { key: "value" }, + }, + created_at: 1734537253, + activity_type: "app_name_change", + activity_description: "Ciaran5 Lee changed your app name from before to after.", + }, + { + id: "f48c653b-0185-48ac-a276-23d11006bafb", + performed_by: { type: "admin", id: "991267464", email: "admin5@email.com", ip: "127.0.0.1" }, + metadata: { + sign_in_method: "email_password", + external_id: "f3b87a2e09d514c6c2e79b9a", + away_mode: true, + away_status_reason: "😌 On a break", + reassign_conversations: false, + source: "admin update from web - Admin id: 93", + update_by: 93, + update_by_name: "Joe Example", + conversation_assignment_limit: 15, + ticket_assignment_limit: 20, + team_assignment_limit: 50, + enabled: true, + consent_id: 149673, + expired_at: "2025-12-04T09:31:57Z", + before: { key: "value" }, + after: { key: "value" }, + }, + created_at: 1734537253, + activity_type: "message_state_change", + activity_description: + "Ciaran5 Lee changed your Initial message title message from Initial message title to Eventual message title.", + }, + ], + }; + server + .mockEndpoint() + .get("/admins/activity_logs") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.admins.listAllActivityLogs({ + created_at_after: "1677253093", + created_at_before: "1677861493", + }); + expect(response).toEqual({ + type: "activity_log.list", + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 20, + total_pages: 1, + }, + activity_logs: [ + { + id: "fca05814-4b72-4dce-ad4f-77a786a2c136", + performed_by: { + type: "admin", + id: "991267464", + email: "admin5@email.com", + ip: "127.0.0.1", + }, + metadata: { + sign_in_method: "email_password", + external_id: "f3b87a2e09d514c6c2e79b9a", + away_mode: true, + away_status_reason: "\uD83D\uDE0C On a break", + reassign_conversations: false, + source: "admin update from web - Admin id: 93", + update_by: 93, + update_by_name: "Joe Example", + conversation_assignment_limit: 15, + ticket_assignment_limit: 20, + team_assignment_limit: 50, + enabled: true, + consent_id: 149673, + expired_at: "2025-12-04T09:31:57Z", + before: { + key: "value", + }, + after: { + key: "value", + }, + }, + created_at: 1734537253, + activity_type: "app_name_change", + activity_description: "Ciaran5 Lee changed your app name from before to after.", + }, + { + id: "f48c653b-0185-48ac-a276-23d11006bafb", + performed_by: { + type: "admin", + id: "991267464", + email: "admin5@email.com", + ip: "127.0.0.1", + }, + metadata: { + sign_in_method: "email_password", + external_id: "f3b87a2e09d514c6c2e79b9a", + away_mode: true, + away_status_reason: "\uD83D\uDE0C On a break", + reassign_conversations: false, + source: "admin update from web - Admin id: 93", + update_by: 93, + update_by_name: "Joe Example", + conversation_assignment_limit: 15, + ticket_assignment_limit: 20, + team_assignment_limit: 50, + enabled: true, + consent_id: 149673, + expired_at: "2025-12-04T09:31:57Z", + before: { + key: "value", + }, + after: { + key: "value", + }, + }, + created_at: 1734537253, + activity_type: "message_state_change", + activity_description: + "Ciaran5 Lee changed your Initial message title message from Initial message title to Eventual message title.", + }, + ], + }); + }); + + test("listAllActivityLogs (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/admins/activity_logs") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.admins.listAllActivityLogs({ + created_at_after: "created_at_after", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "admin.list", + admins: [ + { + type: "admin", + id: "991267466", + name: "Ciaran7 Lee", + email: "admin7@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { image_url: "https://example.org/128Wash.jpg" }, + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }, + ], + }; + server.mockEndpoint().get("/admins").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.admins.list(); + expect(response).toEqual({ + type: "admin.list", + admins: [ + { + type: "admin", + id: "991267466", + name: "Ciaran7 Lee", + email: "admin7@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { + image_url: "https://example.org/128Wash.jpg", + }, + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }, + ], + }); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/admins").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.admins.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "admin", + id: "991267468", + name: "Ciaran9 Lee", + email: "admin9@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { image_url: "https://example.org/128Wash.jpg" }, + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }; + server.mockEndpoint().get("/admins/1").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.admins.find({ + admin_id: 1, + }); + expect(response).toEqual({ + type: "admin", + id: "991267468", + name: "Ciaran9 Lee", + email: "admin9@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { + image_url: "https://example.org/128Wash.jpg", + }, + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }); + }); + + test("find (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/admins/1").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.admins.find({ + admin_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/admins/1").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.admins.find({ + admin_id: 1, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); +}); diff --git a/tests/wire/aiContent.test.ts b/tests/wire/aiContent.test.ts new file mode 100644 index 00000000..fad0e33d --- /dev/null +++ b/tests/wire/aiContent.test.ts @@ -0,0 +1,878 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("AiContentClient", () => { + test("listContentImportSources (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { type: "pages", page: 1, next: "next", per_page: 50, total_pages: 1 }, + total_count: 3, + data: [ + { + type: "content_import_source", + id: 33, + last_synced_at: 1734537259, + sync_behavior: "automatic", + status: "active", + url: "https://support.example.com/us/1", + created_at: 1734537259, + updated_at: 1734537259, + }, + { + type: "content_import_source", + id: 34, + last_synced_at: 1734537259, + sync_behavior: "automatic", + status: "active", + url: "https://support.example.com/us/2", + created_at: 1734537259, + updated_at: 1734537259, + }, + { + type: "content_import_source", + id: 35, + last_synced_at: 1734537259, + sync_behavior: "automatic", + status: "active", + url: "https://support.example.com/us/3", + created_at: 1734537259, + updated_at: 1734537259, + }, + ], + }; + server + .mockEndpoint() + .get("/ai/content_import_sources") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.aiContent.listContentImportSources(); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: "next", + per_page: 50, + total_pages: 1, + }, + total_count: 3, + data: [ + { + type: "content_import_source", + id: 33, + last_synced_at: 1734537259, + sync_behavior: "automatic", + status: "active", + url: "https://support.example.com/us/1", + created_at: 1734537259, + updated_at: 1734537259, + }, + { + type: "content_import_source", + id: 34, + last_synced_at: 1734537259, + sync_behavior: "automatic", + status: "active", + url: "https://support.example.com/us/2", + created_at: 1734537259, + updated_at: 1734537259, + }, + { + type: "content_import_source", + id: 35, + last_synced_at: 1734537259, + sync_behavior: "automatic", + status: "active", + url: "https://support.example.com/us/3", + created_at: 1734537259, + updated_at: 1734537259, + }, + ], + }); + }); + + test("listContentImportSources (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/ai/content_import_sources") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.aiContent.listContentImportSources(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("createContentImportSource (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { sync_behavior: "api", url: "https://www.example.com" }; + const rawResponseBody = { + type: "content_import_source", + id: 36, + last_synced_at: 1734537261, + sync_behavior: "api", + status: "active", + url: "https://www.example.com", + created_at: 1734537261, + updated_at: 1734537261, + }; + server + .mockEndpoint() + .post("/ai/content_import_sources") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.aiContent.createContentImportSource({ + url: "https://www.example.com", + }); + expect(response).toEqual({ + type: "content_import_source", + id: 36, + last_synced_at: 1734537261, + sync_behavior: "api", + status: "active", + url: "https://www.example.com", + created_at: 1734537261, + updated_at: 1734537261, + }); + }); + + test("createContentImportSource (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { sync_behavior: "api", url: "url" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/ai/content_import_sources") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.aiContent.createContentImportSource({ + url: "url", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("getContentImportSource (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "content_import_source", + id: 38, + last_synced_at: 1734537265, + sync_behavior: "api", + status: "active", + url: "https://support.example.com/us/5", + created_at: 1734537265, + updated_at: 1734537265, + }; + server + .mockEndpoint() + .get("/ai/content_import_sources/source_id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.aiContent.getContentImportSource({ + source_id: "source_id", + }); + expect(response).toEqual({ + type: "content_import_source", + id: 38, + last_synced_at: 1734537265, + sync_behavior: "api", + status: "active", + url: "https://support.example.com/us/5", + created_at: 1734537265, + updated_at: 1734537265, + }); + }); + + test("getContentImportSource (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/ai/content_import_sources/source_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.aiContent.getContentImportSource({ + source_id: "source_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("updateContentImportSource (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { sync_behavior: "api", url: "https://www.example.com" }; + const rawResponseBody = { + type: "content_import_source", + id: 39, + last_synced_at: 1734537267, + sync_behavior: "api", + status: "active", + url: "https://www.example.com", + created_at: 1734537267, + updated_at: 1734537267, + }; + server + .mockEndpoint() + .put("/ai/content_import_sources/source_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.aiContent.updateContentImportSource({ + source_id: "source_id", + sync_behavior: "api", + url: "https://www.example.com", + }); + expect(response).toEqual({ + type: "content_import_source", + id: 39, + last_synced_at: 1734537267, + sync_behavior: "api", + status: "active", + url: "https://www.example.com", + created_at: 1734537267, + updated_at: 1734537267, + }); + }); + + test("updateContentImportSource (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { sync_behavior: "api", url: "url" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/ai/content_import_sources/source_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.aiContent.updateContentImportSource({ + source_id: "source_id", + sync_behavior: "api", + url: "url", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("deleteContentImportSource (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + server.mockEndpoint().delete("/ai/content_import_sources/source_id").respondWith().statusCode(200).build(); + + const response = await client.aiContent.deleteContentImportSource({ + source_id: "source_id", + }); + expect(response).toEqual(undefined); + }); + + test("deleteContentImportSource (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/ai/content_import_sources/source_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.aiContent.deleteContentImportSource({ + source_id: "source_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("listExternalPages (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { type: "pages", page: 1, next: "next", per_page: 50, total_pages: 1 }, + total_count: 3, + data: [ + { + type: "external_page", + id: "19", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/3", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 42, + external_id: "3", + created_at: 1734537269, + updated_at: 1734537269, + last_ingested_at: 1734537269, + }, + { + type: "external_page", + id: "18", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/2", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 41, + external_id: "2", + created_at: 1734537269, + updated_at: 1734537269, + last_ingested_at: 1734537269, + }, + { + type: "external_page", + id: "17", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/1", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 40, + external_id: "1", + created_at: 1734537269, + updated_at: 1734537269, + last_ingested_at: 1734537269, + }, + ], + }; + server.mockEndpoint().get("/ai/external_pages").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.aiContent.listExternalPages(); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: "next", + per_page: 50, + total_pages: 1, + }, + total_count: 3, + data: [ + { + type: "external_page", + id: "19", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/3", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 42, + external_id: "3", + created_at: 1734537269, + updated_at: 1734537269, + last_ingested_at: 1734537269, + }, + { + type: "external_page", + id: "18", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/2", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 41, + external_id: "2", + created_at: 1734537269, + updated_at: 1734537269, + last_ingested_at: 1734537269, + }, + { + type: "external_page", + id: "17", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/1", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 40, + external_id: "1", + created_at: 1734537269, + updated_at: 1734537269, + last_ingested_at: 1734537269, + }, + ], + }); + }); + + test("listExternalPages (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/ai/external_pages").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.aiContent.listExternalPages(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("createExternalPage (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Test", + html: "

Test

", + url: "https://www.example.com", + locale: "en", + source_id: 44, + external_id: "abc1234", + }; + const rawResponseBody = { + type: "external_page", + id: "21", + title: "Test", + html: "

Test

", + url: "https://www.example.com", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 44, + external_id: "abc1234", + created_at: 1734537273, + updated_at: 1734537274, + last_ingested_at: 1734537274, + }; + server + .mockEndpoint() + .post("/ai/external_pages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.aiContent.createExternalPage({ + title: "Test", + html: "

Test

", + url: "https://www.example.com", + source_id: 44, + external_id: "abc1234", + }); + expect(response).toEqual({ + type: "external_page", + id: "21", + title: "Test", + html: "

Test

", + url: "https://www.example.com", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 44, + external_id: "abc1234", + created_at: 1734537273, + updated_at: 1734537274, + last_ingested_at: 1734537274, + }); + }); + + test("createExternalPage (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "title", html: "html", locale: "en", source_id: 1, external_id: "external_id" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/ai/external_pages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.aiContent.createExternalPage({ + title: "title", + html: "html", + source_id: 1, + external_id: "external_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("getExternalPage (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "external_page", + id: "23", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/6", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 46, + external_id: "5", + created_at: 1734537278, + updated_at: 1734537278, + last_ingested_at: 1734537278, + }; + server + .mockEndpoint() + .get("/ai/external_pages/page_id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.aiContent.getExternalPage({ + page_id: "page_id", + }); + expect(response).toEqual({ + type: "external_page", + id: "23", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/6", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 46, + external_id: "5", + created_at: 1734537278, + updated_at: 1734537278, + last_ingested_at: 1734537278, + }); + }); + + test("getExternalPage (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/ai/external_pages/page_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.aiContent.getExternalPage({ + page_id: "page_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("updateExternalPage (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Test", + html: "

Test

", + url: "https://www.example.com", + locale: "en", + source_id: 47, + external_id: "5678", + }; + const rawResponseBody = { + type: "external_page", + id: "24", + title: "Test", + html: "

Test

", + url: "https://www.example.com", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 47, + external_id: "5678", + created_at: 1734537280, + updated_at: 1734537281, + last_ingested_at: 1734537281, + }; + server + .mockEndpoint() + .put("/ai/external_pages/page_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.aiContent.updateExternalPage({ + page_id: "page_id", + title: "Test", + html: "

Test

", + url: "https://www.example.com", + source_id: 47, + external_id: "5678", + }); + expect(response).toEqual({ + type: "external_page", + id: "24", + title: "Test", + html: "

Test

", + url: "https://www.example.com", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 47, + external_id: "5678", + created_at: 1734537280, + updated_at: 1734537281, + last_ingested_at: 1734537281, + }); + }); + + test("updateExternalPage (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "title", html: "html", url: "url", locale: "en", source_id: 1 }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/ai/external_pages/page_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.aiContent.updateExternalPage({ + page_id: "page_id", + title: "title", + html: "html", + url: "url", + source_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("deleteExternalPage (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "external_page", + id: "22", + title: "My External Content", + html: "", + url: "https://support.example.com/us/5", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 45, + external_id: "4", + created_at: 1734537276, + updated_at: 1734537276, + last_ingested_at: 1734537276, + }; + server + .mockEndpoint() + .delete("/ai/external_pages/page_id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.aiContent.deleteExternalPage({ + page_id: "page_id", + }); + expect(response).toEqual({ + type: "external_page", + id: "22", + title: "My External Content", + html: "", + url: "https://support.example.com/us/5", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 45, + external_id: "4", + created_at: 1734537276, + updated_at: 1734537276, + last_ingested_at: 1734537276, + }); + }); + + test("deleteExternalPage (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/ai/external_pages/page_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.aiContent.deleteExternalPage({ + page_id: "page_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); +}); diff --git a/tests/wire/articles.test.ts b/tests/wire/articles.test.ts new file mode 100644 index 00000000..35387d31 --- /dev/null +++ b/tests/wire/articles.test.ts @@ -0,0 +1,6584 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("ArticlesClient", () => { + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { key: "value" }, + total_count: 1, + data: [ + { + type: "article", + id: "id", + workspace_id: "workspace_id", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + parent_id: 1, + parent_ids: [1, 1], + parent_type: "parent_type", + default_locale: "default_locale", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + bg: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + bs: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ca: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + cs: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + da: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + de: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + el: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + en: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + es: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + et: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + fi: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + fr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + he: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + hr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + hu: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + id: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + it: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ja: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ko: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + lt: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + lv: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + mn: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + nb: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + nl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + pl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + pt: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ro: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ru: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sv: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + tr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + vi: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "pt-BR": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "zh-CN": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "zh-TW": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + }, + }, + { + type: "article", + id: "id", + workspace_id: "workspace_id", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + parent_id: 1, + parent_ids: [1, 1], + parent_type: "parent_type", + default_locale: "default_locale", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + bg: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + bs: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ca: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + cs: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + da: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + de: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + el: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + en: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + es: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + et: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + fi: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + fr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + he: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + hr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + hu: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + id: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + it: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ja: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ko: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + lt: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + lv: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + mn: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + nb: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + nl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + pl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + pt: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ro: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ru: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sv: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + tr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + vi: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "pt-BR": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "zh-CN": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "zh-TW": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + }, + }, + ], + }; + server + .mockEndpoint({ once: false }) + .get("/articles") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const expected = { + type: "list", + pages: { + key: "value", + }, + total_count: 1, + data: [ + { + type: "article", + id: "id", + workspace_id: "workspace_id", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + parent_id: 1, + parent_ids: [1, 1], + parent_type: "parent_type", + default_locale: "default_locale", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + bg: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + bs: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ca: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + cs: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + da: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + de: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + el: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + en: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + es: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + et: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + fi: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + fr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + he: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + hr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + hu: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + id: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + it: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ja: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ko: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + lt: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + lv: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + mn: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + nb: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + nl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + pl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + pt: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ro: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ru: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sv: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + tr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + vi: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "pt-BR": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "zh-CN": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "zh-TW": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + }, + }, + { + type: "article", + id: "id", + workspace_id: "workspace_id", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + parent_id: 1, + parent_ids: [1, 1], + parent_type: "parent_type", + default_locale: "default_locale", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + bg: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + bs: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ca: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + cs: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + da: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + de: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + el: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + en: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + es: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + et: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + fi: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + fr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + he: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + hr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + hu: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + id: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + it: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ja: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ko: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + lt: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + lv: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + mn: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + nb: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + nl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + pl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + pt: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ro: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ru: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sv: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + tr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + vi: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "pt-BR": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "zh-CN": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "zh-TW": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + }, + }, + ], + }; + const page = await client.articles.list(); + + expect(expected.data).toEqual(page.data); + expect(page.hasNextPage()).toBe(true); + const nextPage = await page.getNextPage(); + expect(expected.data).toEqual(nextPage.data); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint({ once: false }) + .get("/articles") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.articles.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("create (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Thanks for everything", + description: "Description of the Article", + body: "Body of the Article", + author_id: 991267497, + state: "published", + parent_id: 145, + parent_type: "collection", + translated_content: { + fr: { + title: "Merci pour tout", + description: "Description de l'article", + body: "Corps de l'article", + author_id: 991267497, + state: "published", + }, + }, + }; + const rawResponseBody = { + type: "article", + id: "42", + workspace_id: "this_is_an_id68_that_should_be_at_least_4", + title: "Thanks for everything", + description: "Description of the Article", + body: '

Body of the Article

', + author_id: 991267497, + state: "published", + created_at: 1734537288, + updated_at: 1734537288, + url: "http://help-center.test/myapp-68/en/articles/42-thanks-for-everything", + parent_id: 145, + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bg: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ca: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + cs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + da: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + de: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + el: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + en: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + es: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + et: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + he: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hu: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + id: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + it: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ja: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ko: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + mn: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nb: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ro: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ru: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + tr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + vi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "pt-BR": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-CN": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-TW": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + }, + statistics: { + type: "article_statistics", + views: 0, + conversions: 0, + reactions: 0, + happy_reaction_percentage: 0, + neutral_reaction_percentage: 0, + sad_reaction_percentage: 0, + }, + }; + server + .mockEndpoint() + .post("/articles") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.articles.create({ + title: "Thanks for everything", + description: "Description of the Article", + body: "Body of the Article", + author_id: 991267497, + state: "published", + parent_id: 145, + parent_type: "collection", + translated_content: { + fr: { + title: "Merci pour tout", + description: "Description de l'article", + body: "Corps de l'article", + author_id: 991267497, + state: "published", + }, + }, + }); + expect(response).toEqual({ + type: "article", + id: "42", + workspace_id: "this_is_an_id68_that_should_be_at_least_4", + title: "Thanks for everything", + description: "Description of the Article", + body: '

Body of the Article

', + author_id: 991267497, + state: "published", + created_at: 1734537288, + updated_at: 1734537288, + url: "http://help-center.test/myapp-68/en/articles/42-thanks-for-everything", + parent_id: 145, + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bg: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ca: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + cs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + da: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + de: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + el: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + en: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + es: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + et: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + he: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hu: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + id: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + it: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ja: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ko: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + mn: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nb: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ro: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ru: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + tr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + vi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "pt-BR": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-CN": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-TW": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + }, + statistics: { + type: "article_statistics", + views: 0, + conversions: 0, + reactions: 0, + happy_reaction_percentage: 0, + neutral_reaction_percentage: 0, + sad_reaction_percentage: 0, + }, + }); + }); + + test("create (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Thanks for everything", + description: "Description of the Article", + body: "Body of the Article", + author_id: 1295, + state: "published", + }; + const rawResponseBody = { + type: "article", + id: "42", + workspace_id: "this_is_an_id68_that_should_be_at_least_4", + title: "Thanks for everything", + description: "Description of the Article", + body: '

Body of the Article

', + author_id: 991267497, + state: "published", + created_at: 1734537288, + updated_at: 1734537288, + url: "http://help-center.test/myapp-68/en/articles/42-thanks-for-everything", + parent_id: 145, + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bg: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ca: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + cs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + da: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + de: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + el: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + en: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + es: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + et: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + he: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hu: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + id: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + it: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ja: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ko: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + mn: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nb: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ro: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ru: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + tr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + vi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "pt-BR": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-CN": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-TW": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + }, + statistics: { + type: "article_statistics", + views: 0, + conversions: 0, + reactions: 0, + happy_reaction_percentage: 0, + neutral_reaction_percentage: 0, + sad_reaction_percentage: 0, + }, + }; + server + .mockEndpoint() + .post("/articles") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.articles.create({ + title: "Thanks for everything", + description: "Description of the Article", + body: "Body of the Article", + author_id: 1295, + state: "published", + }); + expect(response).toEqual({ + type: "article", + id: "42", + workspace_id: "this_is_an_id68_that_should_be_at_least_4", + title: "Thanks for everything", + description: "Description of the Article", + body: '

Body of the Article

', + author_id: 991267497, + state: "published", + created_at: 1734537288, + updated_at: 1734537288, + url: "http://help-center.test/myapp-68/en/articles/42-thanks-for-everything", + parent_id: 145, + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bg: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ca: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + cs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + da: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + de: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + el: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + en: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + es: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + et: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + he: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hu: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + id: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + it: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ja: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ko: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + mn: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nb: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ro: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ru: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + tr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + vi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "pt-BR": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-CN": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-TW": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + }, + statistics: { + type: "article_statistics", + views: 0, + conversions: 0, + reactions: 0, + happy_reaction_percentage: 0, + neutral_reaction_percentage: 0, + sad_reaction_percentage: 0, + }, + }); + }); + + test("create (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().post("/articles").respondWith().statusCode(400).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.articles.create(undefined); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("create (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().post("/articles").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.articles.create(undefined); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "article", + id: "45", + workspace_id: "this_is_an_id74_that_should_be_at_least_4", + title: "This is the article title", + description: "", + body: "", + author_id: 991267502, + state: "published", + created_at: 1734537292, + updated_at: 1734537292, + url: "http://help-center.test/myapp-74/en/articles/45-this-is-the-article-title", + parent_id: 148, + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bg: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ca: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + cs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + da: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + de: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + el: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + en: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + es: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + et: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + he: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hu: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + id: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + it: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ja: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ko: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + mn: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nb: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ro: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ru: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + tr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + vi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "pt-BR": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-CN": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-TW": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + }, + statistics: { + type: "article_statistics", + views: 0, + conversions: 0, + reactions: 0, + happy_reaction_percentage: 0, + neutral_reaction_percentage: 0, + sad_reaction_percentage: 0, + }, + }; + server.mockEndpoint().get("/articles/1").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.articles.find({ + article_id: 1, + }); + expect(response).toEqual({ + type: "article", + id: "45", + workspace_id: "this_is_an_id74_that_should_be_at_least_4", + title: "This is the article title", + description: "", + body: "", + author_id: 991267502, + state: "published", + created_at: 1734537292, + updated_at: 1734537292, + url: "http://help-center.test/myapp-74/en/articles/45-this-is-the-article-title", + parent_id: 148, + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bg: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ca: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + cs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + da: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + de: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + el: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + en: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + es: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + et: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + he: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hu: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + id: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + it: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ja: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ko: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + mn: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nb: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ro: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ru: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + tr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + vi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "pt-BR": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-CN": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-TW": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + }, + statistics: { + type: "article_statistics", + views: 0, + conversions: 0, + reactions: 0, + happy_reaction_percentage: 0, + neutral_reaction_percentage: 0, + sad_reaction_percentage: 0, + }, + }); + }); + + test("find (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/articles/1").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.articles.find({ + article_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/articles/1").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.articles.find({ + article_id: 1, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("update (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "Christmas is here!", body: "

New gifts in store for the jolly season

" }; + const rawResponseBody = { + type: "article", + id: "48", + workspace_id: "this_is_an_id80_that_should_be_at_least_4", + title: "Christmas is here!", + description: "", + body: '

New gifts in store for the jolly season

', + author_id: 991267508, + state: "published", + created_at: 1734537297, + updated_at: 1734537298, + url: "http://help-center.test/myapp-80/en/articles/48-christmas-is-here", + parent_id: 151, + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bg: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ca: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + cs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + da: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + de: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + el: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + en: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + es: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + et: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + he: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hu: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + id: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + it: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ja: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ko: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + mn: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nb: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ro: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ru: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + tr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + vi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "pt-BR": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-CN": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-TW": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + }, + statistics: { + type: "article_statistics", + views: 0, + conversions: 0, + reactions: 0, + happy_reaction_percentage: 0, + neutral_reaction_percentage: 0, + sad_reaction_percentage: 0, + }, + }; + server + .mockEndpoint() + .put("/articles/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.articles.update({ + article_id: 1, + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + }); + expect(response).toEqual({ + type: "article", + id: "48", + workspace_id: "this_is_an_id80_that_should_be_at_least_4", + title: "Christmas is here!", + description: "", + body: '

New gifts in store for the jolly season

', + author_id: 991267508, + state: "published", + created_at: 1734537297, + updated_at: 1734537298, + url: "http://help-center.test/myapp-80/en/articles/48-christmas-is-here", + parent_id: 151, + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bg: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ca: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + cs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + da: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + de: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + el: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + en: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + es: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + et: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + he: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hu: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + id: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + it: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ja: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ko: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + mn: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nb: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ro: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ru: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + tr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + vi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "pt-BR": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-CN": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-TW": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + }, + statistics: { + type: "article_statistics", + views: 0, + conversions: 0, + reactions: 0, + happy_reaction_percentage: 0, + neutral_reaction_percentage: 0, + sad_reaction_percentage: 0, + }, + }); + }); + + test("update (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "Christmas is here!", body: "

New gifts in store for the jolly season

" }; + const rawResponseBody = { + type: "article", + id: "48", + workspace_id: "this_is_an_id80_that_should_be_at_least_4", + title: "Christmas is here!", + description: "", + body: '

New gifts in store for the jolly season

', + author_id: 991267508, + state: "published", + created_at: 1734537297, + updated_at: 1734537298, + url: "http://help-center.test/myapp-80/en/articles/48-christmas-is-here", + parent_id: 151, + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bg: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ca: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + cs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + da: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + de: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + el: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + en: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + es: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + et: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + he: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hu: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + id: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + it: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ja: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ko: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + mn: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nb: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ro: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ru: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + tr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + vi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "pt-BR": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-CN": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-TW": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + }, + statistics: { + type: "article_statistics", + views: 0, + conversions: 0, + reactions: 0, + happy_reaction_percentage: 0, + neutral_reaction_percentage: 0, + sad_reaction_percentage: 0, + }, + }; + server + .mockEndpoint() + .put("/articles/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.articles.update({ + article_id: 1, + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + }); + expect(response).toEqual({ + type: "article", + id: "48", + workspace_id: "this_is_an_id80_that_should_be_at_least_4", + title: "Christmas is here!", + description: "", + body: '

New gifts in store for the jolly season

', + author_id: 991267508, + state: "published", + created_at: 1734537297, + updated_at: 1734537298, + url: "http://help-center.test/myapp-80/en/articles/48-christmas-is-here", + parent_id: 151, + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bg: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ca: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + cs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + da: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + de: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + el: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + en: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + es: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + et: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + he: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hu: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + id: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + it: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ja: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ko: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + mn: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nb: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ro: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ru: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + tr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + vi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "pt-BR": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-CN": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-TW": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + }, + statistics: { + type: "article_statistics", + views: 0, + conversions: 0, + reactions: 0, + happy_reaction_percentage: 0, + neutral_reaction_percentage: 0, + sad_reaction_percentage: 0, + }, + }); + }); + + test("update (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/articles/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.articles.update({ + article_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("update (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/articles/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.articles.update({ + article_id: 1, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("delete (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { id: "51", object: "article", deleted: true }; + server.mockEndpoint().delete("/articles/1").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.articles.delete({ + article_id: 1, + }); + expect(response).toEqual({ + id: "51", + object: "article", + deleted: true, + }); + }); + + test("delete (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().delete("/articles/1").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.articles.delete({ + article_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("delete (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().delete("/articles/1").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.articles.delete({ + article_id: 1, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("search (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + total_count: 1, + data: { + articles: [ + { + type: "article", + id: "55", + workspace_id: "this_is_an_id92_that_should_be_at_least_4", + title: "Title 1", + description: "", + body: "", + author_id: 991267521, + state: "draft", + created_at: 1734537306, + updated_at: 1734537306, + url: "http://intercom.test/help/en/articles/3-default-language", + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + }, + ], + highlights: [{ article_id: "123" }], + }, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 10, + total_pages: 1, + }, + }; + server.mockEndpoint().get("/articles/search").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.articles.search({ + phrase: "Getting started", + state: "published", + help_center_id: 1, + highlight: true, + }); + expect(response).toEqual({ + type: "list", + total_count: 1, + data: { + articles: [ + { + type: "article", + id: "55", + workspace_id: "this_is_an_id92_that_should_be_at_least_4", + title: "Title 1", + description: "", + body: "", + author_id: 991267521, + state: "draft", + created_at: 1734537306, + updated_at: 1734537306, + url: "http://intercom.test/help/en/articles/3-default-language", + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + }, + ], + highlights: [ + { + article_id: "123", + }, + ], + }, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 10, + total_pages: 1, + }, + }); + }); + + test("search (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/articles/search").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.articles.search(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); +}); diff --git a/tests/wire/awayStatusReasons.test.ts b/tests/wire/awayStatusReasons.test.ts new file mode 100644 index 00000000..f89aa99c --- /dev/null +++ b/tests/wire/awayStatusReasons.test.ts @@ -0,0 +1,74 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("AwayStatusReasonsClient", () => { + test("listAwayStatusReasons (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = [ + { + type: "away_status_reason", + id: "id", + label: "On a break", + emoji: "☕", + order: 1, + deleted: false, + created_at: 1734537243, + updated_at: 1734537243, + }, + ]; + server + .mockEndpoint() + .get("/away_status_reasons") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.awayStatusReasons.listAwayStatusReasons(); + expect(response).toEqual([ + { + type: "away_status_reason", + id: "id", + label: "On a break", + emoji: "\u2615", + order: 1, + deleted: false, + created_at: 1734537243, + updated_at: 1734537243, + }, + ]); + }); + + test("listAwayStatusReasons (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/away_status_reasons") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.awayStatusReasons.listAwayStatusReasons(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); +}); diff --git a/tests/wire/calls.test.ts b/tests/wire/calls.test.ts new file mode 100644 index 00000000..5fc5aaec --- /dev/null +++ b/tests/wire/calls.test.ts @@ -0,0 +1,410 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("CallsClient", () => { + test("listCalls (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "call", + id: "123", + conversation_id: "456", + admin_id: "789", + contact_id: "6762f0dd1bb69f9f2193bb83", + state: "completed", + initiated_at: "2024-01-15T09:30:00Z", + answered_at: "2024-01-15T09:30:00Z", + ended_at: "2024-01-15T09:30:00Z", + created_at: "2024-01-15T09:30:00Z", + updated_at: "2024-01-15T09:30:00Z", + recording_url: "https://api.intercom.io/calls/123/recording", + transcription_url: "https://api.intercom.io/calls/123/transcript", + call_type: "phone", + direction: "outbound", + ended_reason: "completed", + phone: "+15551234567", + fin_recording_url: "fin_recording_url", + fin_transcription_url: "fin_transcription_url", + }, + ], + total_count: 0, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 25, + total_pages: 0, + }, + }; + server.mockEndpoint().get("/calls").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.calls.listCalls({ + page: 1, + per_page: 1, + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "call", + id: "123", + conversation_id: "456", + admin_id: "789", + contact_id: "6762f0dd1bb69f9f2193bb83", + state: "completed", + initiated_at: "2024-01-15T09:30:00Z", + answered_at: "2024-01-15T09:30:00Z", + ended_at: "2024-01-15T09:30:00Z", + created_at: "2024-01-15T09:30:00Z", + updated_at: "2024-01-15T09:30:00Z", + recording_url: "https://api.intercom.io/calls/123/recording", + transcription_url: "https://api.intercom.io/calls/123/transcript", + call_type: "phone", + direction: "outbound", + ended_reason: "completed", + phone: "+15551234567", + fin_recording_url: "fin_recording_url", + fin_transcription_url: "fin_transcription_url", + }, + ], + total_count: 0, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 25, + total_pages: 0, + }, + }); + }); + + test("listCalls (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/calls").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.calls.listCalls(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("showCall (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "call", + id: "123", + conversation_id: "456", + admin_id: "789", + contact_id: "6762f0dd1bb69f9f2193bb83", + state: "completed", + initiated_at: 1734537437, + answered_at: 1734537440, + ended_at: 1734537530, + created_at: 1734537437, + updated_at: 1734537531, + recording_url: "https://api.intercom.io/calls/123/recording", + transcription_url: "https://api.intercom.io/calls/123/transcript", + call_type: "phone", + direction: "outbound", + ended_reason: "answered", + phone: "+15551234567", + fin_recording_url: "https://api.intercom.io/calls/124/recording", + fin_transcription_url: "https://api.intercom.io/calls/124/transcript", + }; + server.mockEndpoint().get("/calls/call_id").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.calls.showCall({ + call_id: "call_id", + }); + expect(response).toEqual({ + type: "call", + id: "123", + conversation_id: "456", + admin_id: "789", + contact_id: "6762f0dd1bb69f9f2193bb83", + state: "completed", + initiated_at: 1734537437, + answered_at: 1734537440, + ended_at: 1734537530, + created_at: 1734537437, + updated_at: 1734537531, + recording_url: "https://api.intercom.io/calls/123/recording", + transcription_url: "https://api.intercom.io/calls/123/transcript", + call_type: "phone", + direction: "outbound", + ended_reason: "answered", + phone: "+15551234567", + fin_recording_url: "https://api.intercom.io/calls/124/recording", + fin_transcription_url: "https://api.intercom.io/calls/124/transcript", + }); + }); + + test("showCall (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/calls/call_id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.calls.showCall({ + call_id: "call_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("showCall (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/calls/call_id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.calls.showCall({ + call_id: "call_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("showCallRecording (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + server.mockEndpoint().get("/calls/call_id/recording").respondWith().statusCode(200).build(); + + const response = await client.calls.showCallRecording({ + call_id: "call_id", + }); + expect(response).toEqual(undefined); + }); + + test("showCallRecording (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/calls/call_id/recording") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.calls.showCallRecording({ + call_id: "call_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("showCallRecording (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/calls/call_id/recording") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.calls.showCallRecording({ + call_id: "call_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("listCallsWithTranscripts (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { conversation_ids: ["64619700005694", "64619700005695"] }; + const rawResponseBody = { + type: "list", + data: [ + { + type: "call", + id: "123", + conversation_id: "64619700005694", + admin_id: "789", + contact_id: "6762f0dd1bb69f9f2193bb83", + state: "completed", + initiated_at: "2024-01-15T09:30:00Z", + answered_at: "2024-01-15T09:30:00Z", + ended_at: "2024-01-15T09:30:00Z", + created_at: "2024-01-15T09:30:00Z", + updated_at: "2024-01-15T09:30:00Z", + recording_url: "https://api.intercom.io/calls/123/recording", + transcription_url: "https://api.intercom.io/calls/123/transcript", + call_type: "phone", + direction: "outbound", + ended_reason: "completed", + phone: "+15551234567", + fin_recording_url: "fin_recording_url", + fin_transcription_url: "fin_transcription_url", + transcript: [{ key: "value" }], + transcript_status: "completed", + }, + ], + }; + server + .mockEndpoint() + .post("/calls/search") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.calls.listCallsWithTranscripts({ + conversation_ids: ["64619700005694", "64619700005695"], + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "call", + id: "123", + conversation_id: "64619700005694", + admin_id: "789", + contact_id: "6762f0dd1bb69f9f2193bb83", + state: "completed", + initiated_at: "2024-01-15T09:30:00Z", + answered_at: "2024-01-15T09:30:00Z", + ended_at: "2024-01-15T09:30:00Z", + created_at: "2024-01-15T09:30:00Z", + updated_at: "2024-01-15T09:30:00Z", + recording_url: "https://api.intercom.io/calls/123/recording", + transcription_url: "https://api.intercom.io/calls/123/transcript", + call_type: "phone", + direction: "outbound", + ended_reason: "completed", + phone: "+15551234567", + fin_recording_url: "fin_recording_url", + fin_transcription_url: "fin_transcription_url", + transcript: [ + { + key: "value", + }, + ], + transcript_status: "completed", + }, + ], + }); + }); + + test("listCallsWithTranscripts (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { conversation_ids: ["conversation_ids", "conversation_ids"] }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/calls/search") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.calls.listCallsWithTranscripts({ + conversation_ids: ["conversation_ids", "conversation_ids"], + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("listCallsWithTranscripts (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { conversation_ids: ["conversation_ids", "conversation_ids"] }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/calls/search") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.calls.listCallsWithTranscripts({ + conversation_ids: ["conversation_ids", "conversation_ids"], + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); +}); diff --git a/tests/wire/companies.test.ts b/tests/wire/companies.test.ts new file mode 100644 index 00000000..90524081 --- /dev/null +++ b/tests/wire/companies.test.ts @@ -0,0 +1,1987 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("CompaniesClient", () => { + test("retrieve (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { type: "offset_pages", page: 1, next: "next", per_page: 2, total_pages: 13 }, + total_count: 100, + data: [ + { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { paid_subscriber: true, monthly_spend: 155.5, team_mates: 9 }, + }, + ], + }; + server.mockEndpoint().get("/companies").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.companies.retrieve({ + name: "my company", + company_id: "12345", + tag_id: "678910", + segment_id: "98765", + page: 1, + per_page: 1, + }); + expect(response).toEqual({ + type: "list", + pages: { + type: "offset_pages", + page: 1, + next: "next", + per_page: 2, + total_pages: 13, + }, + total_count: 100, + data: [ + { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: true, + monthly_spend: 155.5, + team_mates: 9, + }, + }, + ], + }); + }); + + test("retrieve (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/companies").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.companies.retrieve(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("retrieve (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/companies").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.companies.retrieve(); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("createOrUpdate (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "my company", company_id: "company_remote_id", remote_created_at: 1374138000 }; + const rawResponseBody = { + type: "company", + id: "6762f0761bb69f9f2193bae2", + name: "my company", + app_id: "this_is_an_id147_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "company_remote_id", + remote_created_at: 1374138000, + created_at: 1734537334, + updated_at: 1734537334, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 0, + custom_attributes: { creation_source: "api" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }; + server + .mockEndpoint() + .post("/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.companies.createOrUpdate({ + name: "my company", + company_id: "company_remote_id", + remote_created_at: 1374138000, + }); + expect(response).toEqual({ + type: "company", + id: "6762f0761bb69f9f2193bae2", + name: "my company", + app_id: "this_is_an_id147_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "company_remote_id", + remote_created_at: 1374138000, + created_at: 1734537334, + updated_at: 1734537334, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 0, + custom_attributes: { + creation_source: "api", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }); + }); + + test("createOrUpdate (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "company", + id: "6762f0761bb69f9f2193bae2", + name: "my company", + app_id: "this_is_an_id147_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "company_remote_id", + remote_created_at: 1374138000, + created_at: 1734537334, + updated_at: 1734537334, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 0, + custom_attributes: { creation_source: "api" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }; + server.mockEndpoint().post("/companies").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.companies.createOrUpdate(); + expect(response).toEqual({ + type: "company", + id: "6762f0761bb69f9f2193bae2", + name: "my company", + app_id: "this_is_an_id147_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "company_remote_id", + remote_created_at: 1374138000, + created_at: 1734537334, + updated_at: 1734537334, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 0, + custom_attributes: { + creation_source: "api", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }); + }); + + test("createOrUpdate (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().post("/companies").respondWith().statusCode(400).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.companies.createOrUpdate(undefined); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("createOrUpdate (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().post("/companies").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.companies.createOrUpdate(undefined); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "company", + id: "6762f07f1bb69f9f2193baf5", + name: "company1", + app_id: "this_is_an_id159_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "1", + remote_created_at: 1734537343, + created_at: 1734537343, + updated_at: 1734537343, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { key: "value" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }; + server + .mockEndpoint() + .get("/companies/5f4d3c1c-7b1b-4d7d-a97e-6095715c6632") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.companies.find({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + }); + expect(response).toEqual({ + type: "company", + id: "6762f07f1bb69f9f2193baf5", + name: "company1", + app_id: "this_is_an_id159_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "1", + remote_created_at: 1734537343, + created_at: 1734537343, + updated_at: 1734537343, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }); + }); + + test("find (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/companies/company_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.find({ + company_id: "company_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/companies/company_id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.find({ + company_id: "company_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("update (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "my company", website: "http://www.mycompany.com/" }; + const rawResponseBody = { + type: "company", + id: "6762f0841bb69f9f2193baff", + name: "company2", + app_id: "this_is_an_id165_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "1", + remote_created_at: 1734537348, + created_at: 1734537348, + updated_at: 1734537348, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { key: "value" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }; + server + .mockEndpoint() + .put("/companies/5f4d3c1c-7b1b-4d7d-a97e-6095715c6632") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.companies.update({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + body: { + name: "my company", + website: "http://www.mycompany.com/", + }, + }); + expect(response).toEqual({ + type: "company", + id: "6762f0841bb69f9f2193baff", + name: "company2", + app_id: "this_is_an_id165_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "1", + remote_created_at: 1734537348, + created_at: 1734537348, + updated_at: 1734537348, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }); + }); + + test("update (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "company", + id: "6762f0841bb69f9f2193baff", + name: "company2", + app_id: "this_is_an_id165_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "1", + remote_created_at: 1734537348, + created_at: 1734537348, + updated_at: 1734537348, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { key: "value" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }; + server + .mockEndpoint() + .put("/companies/5f4d3c1c-7b1b-4d7d-a97e-6095715c6632") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.companies.update({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + body: {}, + }); + expect(response).toEqual({ + type: "company", + id: "6762f0841bb69f9f2193baff", + name: "company2", + app_id: "this_is_an_id165_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "1", + remote_created_at: 1734537348, + created_at: 1734537348, + updated_at: 1734537348, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }); + }); + + test("update (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/companies/company_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.update({ + company_id: "company_id", + body: undefined, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("update (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/companies/company_id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.update({ + company_id: "company_id", + body: undefined, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("delete (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { id: "6762f0881bb69f9f2193bb09", object: "company", deleted: true }; + server + .mockEndpoint() + .delete("/companies/5f4d3c1c-7b1b-4d7d-a97e-6095715c6632") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.companies.delete({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + }); + expect(response).toEqual({ + id: "6762f0881bb69f9f2193bb09", + object: "company", + deleted: true, + }); + }); + + test("delete (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/companies/company_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.delete({ + company_id: "company_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("delete (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/companies/company_id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.delete({ + company_id: "company_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("listAttachedContacts (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "ecahpwf5", + role: "user", + email: "joe@example.com", + email_domain: "example.com", + phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: true, + marked_email_as_spam: true, + unsubscribed_from_emails: true, + created_at: 1571672154, + updated_at: 1571672154, + signed_up_at: 1571672154, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: "https://example.org/128Wash.jpg", + tags: { url: "/contacts/5ba682d23d7cf92bef87bfd4/tags", total_count: 100, has_more: true }, + notes: { url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", total_count: 100, has_more: true }, + companies: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/companies", + total_count: 100, + has_more: true, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + }, + ], + total_count: 0, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 50, + total_pages: 0, + }, + }; + server + .mockEndpoint() + .get("/companies/5f4d3c1c-7b1b-4d7d-a97e-6095715c6632/contacts") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.companies.listAttachedContacts({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "ecahpwf5", + role: "user", + email: "joe@example.com", + email_domain: "example.com", + phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: true, + marked_email_as_spam: true, + unsubscribed_from_emails: true, + created_at: 1571672154, + updated_at: 1571672154, + signed_up_at: 1571672154, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: "https://example.org/128Wash.jpg", + tags: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/tags", + total_count: 100, + has_more: true, + }, + notes: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + total_count: 100, + has_more: true, + }, + companies: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/companies", + total_count: 100, + has_more: true, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + }, + ], + total_count: 0, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 50, + total_pages: 0, + }, + }); + }); + + test("listAttachedContacts (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/companies/company_id/contacts") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.listAttachedContacts({ + company_id: "company_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("listAttachedContacts (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/companies/company_id/contacts") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.listAttachedContacts({ + company_id: "company_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("listAttachedSegments (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "segment", + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + person_type: "contact", + count: 3, + }, + ], + }; + server + .mockEndpoint() + .get("/companies/5f4d3c1c-7b1b-4d7d-a97e-6095715c6632/segments") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.companies.listAttachedSegments({ + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "segment", + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + person_type: "contact", + count: 3, + }, + ], + }); + }); + + test("listAttachedSegments (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/companies/company_id/segments") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.listAttachedSegments({ + company_id: "company_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("listAttachedSegments (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/companies/company_id/segments") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.listAttachedSegments({ + company_id: "company_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { type: "offset_pages", page: 1, next: "next", per_page: 15, total_pages: 1 }, + total_count: 1, + data: [ + { + type: "company", + id: "6762f0941bb69f9f2193bb25", + name: "IntercomQATest1", + app_id: "this_is_an_id189_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "remote_companies_scroll_2", + remote_created_at: 1734537364, + created_at: 1734537364, + updated_at: 1734537364, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 4, + custom_attributes: { key: "value" }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }, + ], + }; + server + .mockEndpoint({ once: false }) + .post("/companies/list") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const expected = { + type: "list", + pages: { + type: "offset_pages", + page: 1, + next: "next", + per_page: 15, + total_pages: 1, + }, + total_count: 1, + data: [ + { + type: "company", + id: "6762f0941bb69f9f2193bb25", + name: "IntercomQATest1", + app_id: "this_is_an_id189_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "remote_companies_scroll_2", + remote_created_at: 1734537364, + created_at: 1734537364, + updated_at: 1734537364, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 4, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }, + ], + }; + const page = await client.companies.list({ + page: 1, + per_page: 1, + order: "desc", + }); + + expect(expected.data).toEqual(page.data); + expect(page.hasNextPage()).toBe(true); + const nextPage = await page.getNextPage(); + expect(expected.data).toEqual(nextPage.data); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint({ once: false }) + .post("/companies/list") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("scroll (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "company", + id: "6762f0971bb69f9f2193bb2b", + name: "IntercomQATest1", + app_id: "this_is_an_id193_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "remote_companies_scroll_2", + remote_created_at: 1734537367, + created_at: 1734537367, + updated_at: 1734537367, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 4, + custom_attributes: { key: "value" }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }, + ], + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 2, + total_pages: 13, + }, + total_count: 100, + scroll_param: "69352cd2-ab5b-42ac-b004-a13d4e55e9b0", + }; + server + .mockEndpoint({ once: false }) + .get("/companies/scroll") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const expected = { + type: "list", + data: [ + { + type: "company", + id: "6762f0971bb69f9f2193bb2b", + name: "IntercomQATest1", + app_id: "this_is_an_id193_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "remote_companies_scroll_2", + remote_created_at: 1734537367, + created_at: 1734537367, + updated_at: 1734537367, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 4, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }, + ], + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 2, + total_pages: 13, + }, + total_count: 100, + scroll_param: "69352cd2-ab5b-42ac-b004-a13d4e55e9b0", + }; + const page = await client.companies.scroll({ + scroll_param: "scroll_param", + }); + + expect(expected.data).toEqual(page.data); + expect(page.hasNextPage()).toBe(true); + const nextPage = await page.getNextPage(); + expect(expected.data).toEqual(nextPage.data); + }); + + test("scroll (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint({ once: false }) + .get("/companies/scroll") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.scroll(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("attachContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "6762f09a1bb69f9f2193bb34" }; + const rawResponseBody = { + type: "company", + id: "6762f09a1bb69f9f2193bb34", + name: "company6", + app_id: "this_is_an_id197_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "1", + remote_created_at: 1734537370, + created_at: 1734537370, + updated_at: 1734537370, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { key: "value" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }; + server + .mockEndpoint() + .post("/contacts/contact_id/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.companies.attachContact({ + contact_id: "contact_id", + id: "6762f09a1bb69f9f2193bb34", + }); + expect(response).toEqual({ + type: "company", + id: "6762f09a1bb69f9f2193bb34", + name: "company6", + app_id: "this_is_an_id197_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "1", + remote_created_at: 1734537370, + created_at: 1734537370, + updated_at: 1734537370, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }); + }); + + test("attachContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "58a430d35458202d41b1e65b" }; + const rawResponseBody = { + type: "company", + id: "6762f09a1bb69f9f2193bb34", + name: "company6", + app_id: "this_is_an_id197_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "1", + remote_created_at: 1734537370, + created_at: 1734537370, + updated_at: 1734537370, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { key: "value" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }; + server + .mockEndpoint() + .post("/contacts/contact_id/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.companies.attachContact({ + contact_id: "contact_id", + id: "58a430d35458202d41b1e65b", + }); + expect(response).toEqual({ + type: "company", + id: "6762f09a1bb69f9f2193bb34", + name: "company6", + app_id: "this_is_an_id197_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "1", + remote_created_at: 1734537370, + created_at: 1734537370, + updated_at: 1734537370, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }); + }); + + test("attachContact (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "123" }; + const rawResponseBody = { + type: "company", + id: "6762f09a1bb69f9f2193bb34", + name: "company6", + app_id: "this_is_an_id197_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "1", + remote_created_at: 1734537370, + created_at: 1734537370, + updated_at: 1734537370, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { key: "value" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }; + server + .mockEndpoint() + .post("/contacts/contact_id/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.companies.attachContact({ + contact_id: "contact_id", + id: "123", + }); + expect(response).toEqual({ + type: "company", + id: "6762f09a1bb69f9f2193bb34", + name: "company6", + app_id: "this_is_an_id197_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "1", + remote_created_at: 1734537370, + created_at: 1734537370, + updated_at: 1734537370, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }); + }); + + test("attachContact (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/contacts/contact_id/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.attachContact({ + contact_id: "contact_id", + id: "id", + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("attachContact (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/contacts/contact_id/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.attachContact({ + contact_id: "contact_id", + id: "id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("attachContact (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/contacts/contact_id/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.attachContact({ + contact_id: "contact_id", + id: "id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("detachContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "company", + id: "6762f0a01bb69f9f2193bb44", + name: "company8", + app_id: "this_is_an_id205_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "1", + remote_created_at: 1734537376, + created_at: 1734537376, + updated_at: 1734537377, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 0, + custom_attributes: { key: "value" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }; + server + .mockEndpoint() + .delete("/contacts/58a430d35458202d41b1e65b/companies/58a430d35458202d41b1e65b") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.companies.detachContact({ + contact_id: "58a430d35458202d41b1e65b", + company_id: "58a430d35458202d41b1e65b", + }); + expect(response).toEqual({ + type: "company", + id: "6762f0a01bb69f9f2193bb44", + name: "company8", + app_id: "this_is_an_id205_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "1", + remote_created_at: 1734537376, + created_at: 1734537376, + updated_at: 1734537377, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 0, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + }); + }); + + test("detachContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/contacts/contact_id/companies/company_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.detachContact({ + contact_id: "contact_id", + company_id: "company_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("detachContact (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/contacts/contact_id/companies/company_id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.companies.detachContact({ + contact_id: "contact_id", + company_id: "company_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); +}); diff --git a/tests/wire/contacts.test.ts b/tests/wire/contacts.test.ts new file mode 100644 index 00000000..2f74a99a --- /dev/null +++ b/tests/wire/contacts.test.ts @@ -0,0 +1,2871 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("ContactsClient", () => { + test("listAttachedCompanies (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + companies: [ + { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { paid_subscriber: true, monthly_spend: 155.5, team_mates: 9 }, + }, + ], + total_count: 1, + pages: { type: "pages", page: 1, next: "next", per_page: 50, total_pages: 1 }, + }; + server + .mockEndpoint({ once: false }) + .get("/contacts/63a07ddf05a32042dffac965/companies") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const expected = { + type: "list", + companies: [ + { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: true, + monthly_spend: 155.5, + team_mates: 9, + }, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: "next", + per_page: 50, + total_pages: 1, + }, + }; + const page = await client.contacts.listAttachedCompanies({ + contact_id: "63a07ddf05a32042dffac965", + page: 1, + per_page: 1, + }); + + expect(expected.companies).toEqual(page.data); + expect(page.hasNextPage()).toBe(true); + const nextPage = await page.getNextPage(); + expect(expected.companies).toEqual(nextPage.data); + }); + + test("listAttachedCompanies (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint({ once: false }) + .get("/contacts/contact_id/companies") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.listAttachedCompanies({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("listAttachedCompanies (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint({ once: false }) + .get("/contacts/contact_id/companies") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.listAttachedCompanies({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("listAttachedSegments (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "segment", + id: "6762f0b21bb69f9f2193bb65", + name: "segment", + created_at: 1734537394, + updated_at: 1734537394, + person_type: "user", + count: 3, + }, + ], + }; + server + .mockEndpoint() + .get("/contacts/63a07ddf05a32042dffac965/segments") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.listAttachedSegments({ + contact_id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "segment", + id: "6762f0b21bb69f9f2193bb65", + name: "segment", + created_at: 1734537394, + updated_at: 1734537394, + person_type: "user", + count: 3, + }, + ], + }); + }); + + test("listAttachedSegments (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/contacts/contact_id/segments") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.listAttachedSegments({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("listAttachedSegments (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/contacts/contact_id/segments") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.listAttachedSegments({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("listAttachedSubscriptions (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "subscription", + id: "91", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [{ name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }], + consent_type: "opt_out", + content_types: ["email"], + }, + { + type: "subscription", + id: "93", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [{ name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }], + consent_type: "opt_in", + content_types: ["sms_message"], + }, + ], + }; + server + .mockEndpoint() + .get("/contacts/63a07ddf05a32042dffac965/subscriptions") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.listAttachedSubscriptions({ + contact_id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "subscription", + id: "91", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [ + { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + ], + consent_type: "opt_out", + content_types: ["email"], + }, + { + type: "subscription", + id: "93", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [ + { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + ], + consent_type: "opt_in", + content_types: ["sms_message"], + }, + ], + }); + }); + + test("listAttachedSubscriptions (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/contacts/contact_id/subscriptions") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.listAttachedSubscriptions({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("listAttachedSubscriptions (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/contacts/contact_id/subscriptions") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.listAttachedSubscriptions({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("attachSubscription (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "37846", consent_type: "opt_in" }; + const rawResponseBody = { + type: "subscription", + id: "106", + state: "live", + default_translation: { name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }, + translations: [{ name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }], + consent_type: "opt_in", + content_types: ["sms_message"], + }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/subscriptions") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.attachSubscription({ + contact_id: "63a07ddf05a32042dffac965", + id: "37846", + consent_type: "opt_in", + }); + expect(response).toEqual({ + type: "subscription", + id: "106", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [ + { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + ], + consent_type: "opt_in", + content_types: ["sms_message"], + }); + }); + + test("attachSubscription (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "37846", consent_type: "opt_in" }; + const rawResponseBody = { + type: "subscription", + id: "106", + state: "live", + default_translation: { name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }, + translations: [{ name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }], + consent_type: "opt_in", + content_types: ["sms_message"], + }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/subscriptions") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.attachSubscription({ + contact_id: "63a07ddf05a32042dffac965", + id: "37846", + consent_type: "opt_in", + }); + expect(response).toEqual({ + type: "subscription", + id: "106", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [ + { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + ], + consent_type: "opt_in", + content_types: ["sms_message"], + }); + }); + + test("attachSubscription (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "invalid_id", consent_type: "opt_in" }; + const rawResponseBody = { + type: "subscription", + id: "106", + state: "live", + default_translation: { name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }, + translations: [{ name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }], + consent_type: "opt_in", + content_types: ["sms_message"], + }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/subscriptions") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.attachSubscription({ + contact_id: "63a07ddf05a32042dffac965", + id: "invalid_id", + consent_type: "opt_in", + }); + expect(response).toEqual({ + type: "subscription", + id: "106", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [ + { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + ], + consent_type: "opt_in", + content_types: ["sms_message"], + }); + }); + + test("attachSubscription (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id", consent_type: "consent_type" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/contacts/contact_id/subscriptions") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.attachSubscription({ + contact_id: "contact_id", + id: "id", + consent_type: "consent_type", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("attachSubscription (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id", consent_type: "consent_type" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/contacts/contact_id/subscriptions") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.attachSubscription({ + contact_id: "contact_id", + id: "id", + consent_type: "consent_type", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("detachSubscription (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "subscription", + id: "122", + state: "live", + default_translation: { name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }, + translations: [{ name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }], + consent_type: "opt_in", + content_types: ["sms_message"], + }; + server + .mockEndpoint() + .delete("/contacts/63a07ddf05a32042dffac965/subscriptions/37846") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.detachSubscription({ + contact_id: "63a07ddf05a32042dffac965", + subscription_id: "37846", + }); + expect(response).toEqual({ + type: "subscription", + id: "122", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [ + { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + ], + consent_type: "opt_in", + content_types: ["sms_message"], + }); + }); + + test("detachSubscription (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/contacts/contact_id/subscriptions/subscription_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.detachSubscription({ + contact_id: "contact_id", + subscription_id: "subscription_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("detachSubscription (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/contacts/contact_id/subscriptions/subscription_id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.detachSubscription({ + contact_id: "contact_id", + subscription_id: "subscription_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("listAttachedTags (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "tag", + id: "80", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }, + ], + }; + server + .mockEndpoint() + .get("/contacts/63a07ddf05a32042dffac965/tags") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.listAttachedTags({ + contact_id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "tag", + id: "80", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }, + ], + }); + }); + + test("listAttachedTags (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/contacts/contact_id/tags") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.listAttachedTags({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("listAttachedTags (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/contacts/contact_id/tags") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.listAttachedTags({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("find (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "contact", + id: "6762f0d01bb69f9f2193bb7d", + external_id: "70", + workspace_id: "this_is_an_id283_that_should_be_at_least_", + role: "user", + email: "joe@bloggs.com", + email_domain: "example.com", + phone: "+1123456789", + name: "Joe Bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537424, + updated_at: 1734537424, + signed_up_at: 1734537424, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: "https://example.org/128Wash.jpg", + tags: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0d01bb69f9f2193bb7d/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0d01bb69f9f2193bb7d/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [{ id: "5ba682d23d7cf92bef87bfd4", url: "/companies/5ba682d23d7cf92bef87bfd4" }], + url: "/contacts/6762f0d01bb69f9f2193bb7d/companies", + total_count: 0, + has_more: false, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + social_profiles: { data: [{ name: "Facebook", url: "http://twitter.com/th1sland" }] }, + enabled_push_messaging: true, + }; + server + .mockEndpoint() + .get("/contacts/63a07ddf05a32042dffac965") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.find({ + contact_id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "contact", + id: "6762f0d01bb69f9f2193bb7d", + external_id: "70", + workspace_id: "this_is_an_id283_that_should_be_at_least_", + role: "user", + email: "joe@bloggs.com", + email_domain: "example.com", + phone: "+1123456789", + name: "Joe Bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537424, + updated_at: 1734537424, + signed_up_at: 1734537424, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: "https://example.org/128Wash.jpg", + tags: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0d01bb69f9f2193bb7d/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0d01bb69f9f2193bb7d/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [ + { + id: "5ba682d23d7cf92bef87bfd4", + url: "/companies/5ba682d23d7cf92bef87bfd4", + }, + ], + url: "/contacts/6762f0d01bb69f9f2193bb7d/companies", + total_count: 0, + has_more: false, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + social_profiles: { + data: [ + { + name: "Facebook", + url: "http://twitter.com/th1sland", + }, + ], + }, + enabled_push_messaging: true, + }); + }); + + test("find (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/contacts/contact_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.find({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("update (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { email: "joebloggs@intercom.io", name: "joe bloggs" }; + const rawResponseBody = { + type: "contact", + id: "6762f0cd1bb69f9f2193bb7c", + external_id: "70", + workspace_id: "this_is_an_id279_that_should_be_at_least_", + role: "user", + email: "joebloggs@intercom.io", + email_domain: "example.com", + phone: "+1123456789", + name: "joe bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537421, + updated_at: 1734537422, + signed_up_at: 1734537421, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: "https://example.org/128Wash.jpg", + tags: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [{ id: "5ba682d23d7cf92bef87bfd4", url: "/companies/5ba682d23d7cf92bef87bfd4" }], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/companies", + total_count: 0, + has_more: false, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + social_profiles: { data: [{ name: "Facebook", url: "http://twitter.com/th1sland" }] }, + enabled_push_messaging: true, + }; + server + .mockEndpoint() + .put("/contacts/63a07ddf05a32042dffac965") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.update({ + contact_id: "63a07ddf05a32042dffac965", + email: "joebloggs@intercom.io", + name: "joe bloggs", + }); + expect(response).toEqual({ + type: "contact", + id: "6762f0cd1bb69f9f2193bb7c", + external_id: "70", + workspace_id: "this_is_an_id279_that_should_be_at_least_", + role: "user", + email: "joebloggs@intercom.io", + email_domain: "example.com", + phone: "+1123456789", + name: "joe bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537421, + updated_at: 1734537422, + signed_up_at: 1734537421, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: "https://example.org/128Wash.jpg", + tags: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [ + { + id: "5ba682d23d7cf92bef87bfd4", + url: "/companies/5ba682d23d7cf92bef87bfd4", + }, + ], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/companies", + total_count: 0, + has_more: false, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + social_profiles: { + data: [ + { + name: "Facebook", + url: "http://twitter.com/th1sland", + }, + ], + }, + enabled_push_messaging: true, + }); + }); + + test("update (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { custom_attributes: { order: ["21"] } }; + const rawResponseBody = { + type: "contact", + id: "6762f0cd1bb69f9f2193bb7c", + external_id: "70", + workspace_id: "this_is_an_id279_that_should_be_at_least_", + role: "user", + email: "joebloggs@intercom.io", + email_domain: "example.com", + phone: "+1123456789", + name: "joe bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537421, + updated_at: 1734537422, + signed_up_at: 1734537421, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + order: { + type: "Order.list", + instances: [ + { + id: "21", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + custom_attributes: { order_number: "ORDER-12345", total_amount: 99.99 }, + type: "Order", + }, + ], + }, + }, + avatar: "https://example.org/128Wash.jpg", + tags: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [{ id: "5ba682d23d7cf92bef87bfd4", url: "/companies/5ba682d23d7cf92bef87bfd4" }], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/companies", + total_count: 0, + has_more: false, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + social_profiles: { data: [{ name: "Facebook", url: "http://twitter.com/th1sland" }] }, + enabled_push_messaging: true, + }; + server + .mockEndpoint() + .put("/contacts/63a07ddf05a32042dffac965") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.update({ + contact_id: "63a07ddf05a32042dffac965", + custom_attributes: { + order: ["21"], + }, + }); + expect(response).toEqual({ + type: "contact", + id: "6762f0cd1bb69f9f2193bb7c", + external_id: "70", + workspace_id: "this_is_an_id279_that_should_be_at_least_", + role: "user", + email: "joebloggs@intercom.io", + email_domain: "example.com", + phone: "+1123456789", + name: "joe bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537421, + updated_at: 1734537422, + signed_up_at: 1734537421, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + order: { + type: "Order.list", + instances: [ + { + id: "21", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + custom_attributes: { + order_number: "ORDER-12345", + total_amount: 99.99, + }, + type: "Order", + }, + ], + }, + }, + avatar: "https://example.org/128Wash.jpg", + tags: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [ + { + id: "5ba682d23d7cf92bef87bfd4", + url: "/companies/5ba682d23d7cf92bef87bfd4", + }, + ], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/companies", + total_count: 0, + has_more: false, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + social_profiles: { + data: [ + { + name: "Facebook", + url: "http://twitter.com/th1sland", + }, + ], + }, + enabled_push_messaging: true, + }); + }); + + test("update (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/contacts/contact_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.update({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("delete (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70", deleted: true }; + server + .mockEndpoint() + .delete("/contacts/contact_id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.delete({ + contact_id: "contact_id", + }); + expect(response).toEqual({ + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + deleted: true, + }); + }); + + test("delete (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/contacts/contact_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.delete({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("mergeLeadInUser (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { from: "6762f0d51bb69f9f2193bb7f", into: "6762f0d51bb69f9f2193bb80" }; + const rawResponseBody = { + type: "contact", + id: "6762f0d51bb69f9f2193bb80", + external_id: "70", + workspace_id: "this_is_an_id291_that_should_be_at_least_", + role: "user", + email: "joe@bloggs.com", + email_domain: "example.com", + phone: "+1123456789", + name: "Joe Bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537429, + updated_at: 1734537430, + signed_up_at: 1734537429, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: "https://example.org/128Wash.jpg", + tags: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0d51bb69f9f2193bb80/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0d51bb69f9f2193bb80/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [{ id: "5ba682d23d7cf92bef87bfd4", url: "/companies/5ba682d23d7cf92bef87bfd4" }], + url: "/contacts/6762f0d51bb69f9f2193bb80/companies", + total_count: 0, + has_more: false, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + social_profiles: { data: [{ name: "Facebook", url: "http://twitter.com/th1sland" }] }, + enabled_push_messaging: true, + }; + server + .mockEndpoint() + .post("/contacts/merge") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.mergeLeadInUser({ + from: "6762f0d51bb69f9f2193bb7f", + into: "6762f0d51bb69f9f2193bb80", + }); + expect(response).toEqual({ + type: "contact", + id: "6762f0d51bb69f9f2193bb80", + external_id: "70", + workspace_id: "this_is_an_id291_that_should_be_at_least_", + role: "user", + email: "joe@bloggs.com", + email_domain: "example.com", + phone: "+1123456789", + name: "Joe Bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537429, + updated_at: 1734537430, + signed_up_at: 1734537429, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: "https://example.org/128Wash.jpg", + tags: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0d51bb69f9f2193bb80/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0d51bb69f9f2193bb80/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [ + { + id: "5ba682d23d7cf92bef87bfd4", + url: "/companies/5ba682d23d7cf92bef87bfd4", + }, + ], + url: "/contacts/6762f0d51bb69f9f2193bb80/companies", + total_count: 0, + has_more: false, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + social_profiles: { + data: [ + { + name: "Facebook", + url: "http://twitter.com/th1sland", + }, + ], + }, + enabled_push_messaging: true, + }); + }); + + test("mergeLeadInUser (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/contacts/merge") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.mergeLeadInUser(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("search (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + query: { operator: "AND", value: [{ field: "created_at", operator: ">", value: "1306054154" }] }, + pagination: { per_page: 5 }, + }; + const rawResponseBody = { + type: "list", + data: [ + { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "ecahpwf5", + role: "user", + email: "joe@example.com", + email_domain: "example.com", + phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: true, + marked_email_as_spam: true, + unsubscribed_from_emails: true, + created_at: 1571672154, + updated_at: 1571672154, + signed_up_at: 1571672154, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: "https://example.org/128Wash.jpg", + tags: { url: "/contacts/5ba682d23d7cf92bef87bfd4/tags", total_count: 100, has_more: true }, + notes: { url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", total_count: 100, has_more: true }, + companies: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/companies", + total_count: 100, + has_more: true, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + }, + ], + total_count: 0, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 5, + total_pages: 0, + }, + }; + server + .mockEndpoint({ once: false }) + .post("/contacts/search") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const expected = { + type: "list", + data: [ + { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "ecahpwf5", + role: "user", + email: "joe@example.com", + email_domain: "example.com", + phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: true, + marked_email_as_spam: true, + unsubscribed_from_emails: true, + created_at: 1571672154, + updated_at: 1571672154, + signed_up_at: 1571672154, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: "https://example.org/128Wash.jpg", + tags: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/tags", + total_count: 100, + has_more: true, + }, + notes: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + total_count: 100, + has_more: true, + }, + companies: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/companies", + total_count: 100, + has_more: true, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + }, + ], + total_count: 0, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 5, + total_pages: 0, + }, + }; + const page = await client.contacts.search({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, + }); + + expect(expected.data).toEqual(page.data); + expect(page.hasNextPage()).toBe(true); + const nextPage = await page.getNextPage(); + expect(expected.data).toEqual(nextPage.data); + }); + + test("search (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { query: {} }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint({ once: false }) + .post("/contacts/search") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.search({ + query: {}, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "contact", + id: "id", + external_id: "external_id", + workspace_id: "workspace_id", + role: "role", + email: "email", + email_domain: "email_domain", + phone: "phone", + name: "name", + owner_id: 1, + has_hard_bounced: true, + marked_email_as_spam: true, + unsubscribed_from_emails: true, + created_at: 1, + updated_at: 1, + signed_up_at: 1, + last_seen_at: 1, + last_replied_at: 1, + last_contacted_at: 1, + last_email_opened_at: 1, + last_email_clicked_at: 1, + language_override: "language_override", + browser: "browser", + browser_version: "browser_version", + browser_language: "browser_language", + os: "os", + android_app_name: "android_app_name", + android_app_version: "android_app_version", + android_device: "android_device", + android_os_version: "android_os_version", + android_sdk_version: "android_sdk_version", + android_last_seen_at: 1, + ios_app_name: "ios_app_name", + ios_app_version: "ios_app_version", + ios_device: "ios_device", + ios_os_version: "ios_os_version", + ios_sdk_version: "ios_sdk_version", + ios_last_seen_at: 1, + custom_attributes: { custom_attributes: { key: "value" } }, + avatar: "avatar", + tags: { + data: [ + { type: "type", id: "id", url: "url" }, + { type: "type", id: "id", url: "url" }, + ], + url: "url", + total_count: 1, + has_more: true, + }, + notes: { + data: [ + { type: "type", id: "id", url: "url" }, + { type: "type", id: "id", url: "url" }, + ], + url: "url", + total_count: 1, + has_more: true, + }, + companies: { + data: [ + { id: "id", type: "company", url: "url" }, + { id: "id", type: "company", url: "url" }, + ], + url: "url", + total_count: 1, + has_more: true, + }, + location: { type: "type", country: "country", region: "region", city: "city" }, + social_profiles: { + data: [ + { type: "social_profile", name: "name", url: "url" }, + { type: "social_profile", name: "name", url: "url" }, + ], + }, + }, + { + type: "contact", + id: "id", + external_id: "external_id", + workspace_id: "workspace_id", + role: "role", + email: "email", + email_domain: "email_domain", + phone: "phone", + name: "name", + owner_id: 1, + has_hard_bounced: true, + marked_email_as_spam: true, + unsubscribed_from_emails: true, + created_at: 1, + updated_at: 1, + signed_up_at: 1, + last_seen_at: 1, + last_replied_at: 1, + last_contacted_at: 1, + last_email_opened_at: 1, + last_email_clicked_at: 1, + language_override: "language_override", + browser: "browser", + browser_version: "browser_version", + browser_language: "browser_language", + os: "os", + android_app_name: "android_app_name", + android_app_version: "android_app_version", + android_device: "android_device", + android_os_version: "android_os_version", + android_sdk_version: "android_sdk_version", + android_last_seen_at: 1, + ios_app_name: "ios_app_name", + ios_app_version: "ios_app_version", + ios_device: "ios_device", + ios_os_version: "ios_os_version", + ios_sdk_version: "ios_sdk_version", + ios_last_seen_at: 1, + custom_attributes: { custom_attributes: { key: "value" } }, + avatar: "avatar", + tags: { + data: [ + { type: "type", id: "id", url: "url" }, + { type: "type", id: "id", url: "url" }, + ], + url: "url", + total_count: 1, + has_more: true, + }, + notes: { + data: [ + { type: "type", id: "id", url: "url" }, + { type: "type", id: "id", url: "url" }, + ], + url: "url", + total_count: 1, + has_more: true, + }, + companies: { + data: [ + { id: "id", type: "company", url: "url" }, + { id: "id", type: "company", url: "url" }, + ], + url: "url", + total_count: 1, + has_more: true, + }, + location: { type: "type", country: "country", region: "region", city: "city" }, + social_profiles: { + data: [ + { type: "social_profile", name: "name", url: "url" }, + { type: "social_profile", name: "name", url: "url" }, + ], + }, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: { per_page: 1, starting_after: "starting_after" }, + per_page: 1, + total_pages: 1, + }, + }; + server + .mockEndpoint({ once: false }) + .get("/contacts") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const expected = { + type: "list", + data: [ + { + type: "contact", + id: "id", + external_id: "external_id", + workspace_id: "workspace_id", + role: "role", + email: "email", + email_domain: "email_domain", + phone: "phone", + name: "name", + owner_id: 1, + has_hard_bounced: true, + marked_email_as_spam: true, + unsubscribed_from_emails: true, + created_at: 1, + updated_at: 1, + signed_up_at: 1, + last_seen_at: 1, + last_replied_at: 1, + last_contacted_at: 1, + last_email_opened_at: 1, + last_email_clicked_at: 1, + language_override: "language_override", + browser: "browser", + browser_version: "browser_version", + browser_language: "browser_language", + os: "os", + android_app_name: "android_app_name", + android_app_version: "android_app_version", + android_device: "android_device", + android_os_version: "android_os_version", + android_sdk_version: "android_sdk_version", + android_last_seen_at: 1, + ios_app_name: "ios_app_name", + ios_app_version: "ios_app_version", + ios_device: "ios_device", + ios_os_version: "ios_os_version", + ios_sdk_version: "ios_sdk_version", + ios_last_seen_at: 1, + custom_attributes: { + custom_attributes: { + key: "value", + }, + }, + avatar: "avatar", + tags: { + data: [ + { + type: "type", + id: "id", + url: "url", + }, + { + type: "type", + id: "id", + url: "url", + }, + ], + url: "url", + total_count: 1, + has_more: true, + }, + notes: { + data: [ + { + type: "type", + id: "id", + url: "url", + }, + { + type: "type", + id: "id", + url: "url", + }, + ], + url: "url", + total_count: 1, + has_more: true, + }, + companies: { + data: [ + { + id: "id", + type: "company", + url: "url", + }, + { + id: "id", + type: "company", + url: "url", + }, + ], + url: "url", + total_count: 1, + has_more: true, + }, + location: { + type: "type", + country: "country", + region: "region", + city: "city", + }, + social_profiles: { + data: [ + { + type: "social_profile", + name: "name", + url: "url", + }, + { + type: "social_profile", + name: "name", + url: "url", + }, + ], + }, + }, + { + type: "contact", + id: "id", + external_id: "external_id", + workspace_id: "workspace_id", + role: "role", + email: "email", + email_domain: "email_domain", + phone: "phone", + name: "name", + owner_id: 1, + has_hard_bounced: true, + marked_email_as_spam: true, + unsubscribed_from_emails: true, + created_at: 1, + updated_at: 1, + signed_up_at: 1, + last_seen_at: 1, + last_replied_at: 1, + last_contacted_at: 1, + last_email_opened_at: 1, + last_email_clicked_at: 1, + language_override: "language_override", + browser: "browser", + browser_version: "browser_version", + browser_language: "browser_language", + os: "os", + android_app_name: "android_app_name", + android_app_version: "android_app_version", + android_device: "android_device", + android_os_version: "android_os_version", + android_sdk_version: "android_sdk_version", + android_last_seen_at: 1, + ios_app_name: "ios_app_name", + ios_app_version: "ios_app_version", + ios_device: "ios_device", + ios_os_version: "ios_os_version", + ios_sdk_version: "ios_sdk_version", + ios_last_seen_at: 1, + custom_attributes: { + custom_attributes: { + key: "value", + }, + }, + avatar: "avatar", + tags: { + data: [ + { + type: "type", + id: "id", + url: "url", + }, + { + type: "type", + id: "id", + url: "url", + }, + ], + url: "url", + total_count: 1, + has_more: true, + }, + notes: { + data: [ + { + type: "type", + id: "id", + url: "url", + }, + { + type: "type", + id: "id", + url: "url", + }, + ], + url: "url", + total_count: 1, + has_more: true, + }, + companies: { + data: [ + { + id: "id", + type: "company", + url: "url", + }, + { + id: "id", + type: "company", + url: "url", + }, + ], + url: "url", + total_count: 1, + has_more: true, + }, + location: { + type: "type", + country: "country", + region: "region", + city: "city", + }, + social_profiles: { + data: [ + { + type: "social_profile", + name: "name", + url: "url", + }, + { + type: "social_profile", + name: "name", + url: "url", + }, + ], + }, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: { + per_page: 1, + starting_after: "starting_after", + }, + per_page: 1, + total_pages: 1, + }, + }; + const page = await client.contacts.list(); + + expect(expected.data).toEqual(page.data); + expect(page.hasNextPage()).toBe(true); + const nextPage = await page.getNextPage(); + expect(expected.data).toEqual(nextPage.data); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint({ once: false }) + .get("/contacts") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("create (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { email: "joebloggs@intercom.io" }; + const rawResponseBody = { + type: "contact", + id: "6762f0dd1bb69f9f2193bb83", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "this_is_an_id303_that_should_be_at_least_", + role: "user", + email: "joebloggs@intercom.io", + email_domain: "example.com", + phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537437, + updated_at: 1734537437, + signed_up_at: 1571672154, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: "https://example.org/128Wash.jpg", + tags: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0dd1bb69f9f2193bb83/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0dd1bb69f9f2193bb83/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [{ id: "5ba682d23d7cf92bef87bfd4", url: "/companies/5ba682d23d7cf92bef87bfd4" }], + url: "/contacts/6762f0dd1bb69f9f2193bb83/companies", + total_count: 0, + has_more: false, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + social_profiles: { data: [{ name: "Facebook", url: "http://twitter.com/th1sland" }] }, + enabled_push_messaging: true, + }; + server + .mockEndpoint() + .post("/contacts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.create({ + email: "joebloggs@intercom.io", + }); + expect(response).toEqual({ + type: "contact", + id: "6762f0dd1bb69f9f2193bb83", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "this_is_an_id303_that_should_be_at_least_", + role: "user", + email: "joebloggs@intercom.io", + email_domain: "example.com", + phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537437, + updated_at: 1734537437, + signed_up_at: 1571672154, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: "https://example.org/128Wash.jpg", + tags: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0dd1bb69f9f2193bb83/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0dd1bb69f9f2193bb83/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [ + { + id: "5ba682d23d7cf92bef87bfd4", + url: "/companies/5ba682d23d7cf92bef87bfd4", + }, + ], + url: "/contacts/6762f0dd1bb69f9f2193bb83/companies", + total_count: 0, + has_more: false, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + social_profiles: { + data: [ + { + name: "Facebook", + url: "http://twitter.com/th1sland", + }, + ], + }, + enabled_push_messaging: true, + }); + }); + + test("create (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { email: "email" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/contacts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.create({ + email: "email", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("ShowContactByExternalId (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "contact", + id: "6762f0df1bb69f9f2193bb84", + external_id: "70", + workspace_id: "this_is_an_id307_that_should_be_at_least_", + role: "user", + email: "joe@bloggs.com", + email_domain: "example.com", + phone: "+1123456789", + name: "Joe Bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537439, + updated_at: 1734537439, + signed_up_at: 1734537439, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: "https://example.org/128Wash.jpg", + tags: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0df1bb69f9f2193bb84/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0df1bb69f9f2193bb84/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [{ id: "5ba682d23d7cf92bef87bfd4", url: "/companies/5ba682d23d7cf92bef87bfd4" }], + url: "/contacts/6762f0df1bb69f9f2193bb84/companies", + total_count: 0, + has_more: false, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + social_profiles: { data: [{ name: "Facebook", url: "http://twitter.com/th1sland" }] }, + enabled_push_messaging: true, + }; + server + .mockEndpoint() + .get("/contacts/find_by_external_id/cdd29344-5e0c-4ef0-ac56-f9ba2979bc27") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.showContactByExternalId({ + external_id: "cdd29344-5e0c-4ef0-ac56-f9ba2979bc27", + }); + expect(response).toEqual({ + type: "contact", + id: "6762f0df1bb69f9f2193bb84", + external_id: "70", + workspace_id: "this_is_an_id307_that_should_be_at_least_", + role: "user", + email: "joe@bloggs.com", + email_domain: "example.com", + phone: "+1123456789", + name: "Joe Bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537439, + updated_at: 1734537439, + signed_up_at: 1734537439, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: "https://example.org/128Wash.jpg", + tags: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0df1bb69f9f2193bb84/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0df1bb69f9f2193bb84/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [ + { + id: "5ba682d23d7cf92bef87bfd4", + url: "/companies/5ba682d23d7cf92bef87bfd4", + }, + ], + url: "/contacts/6762f0df1bb69f9f2193bb84/companies", + total_count: 0, + has_more: false, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + social_profiles: { + data: [ + { + name: "Facebook", + url: "http://twitter.com/th1sland", + }, + ], + }, + enabled_push_messaging: true, + }); + }); + + test("ShowContactByExternalId (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/contacts/find_by_external_id/external_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.contacts.showContactByExternalId({ + external_id: "external_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("archive", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70", archived: true }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/archive") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.archive({ + contact_id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + archived: true, + }); + }); + + test("unarchive", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70", archived: false }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/unarchive") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.unarchive({ + contact_id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + archived: false, + }); + }); + + test("BlockContact", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70", blocked: true }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/block") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.contacts.blockContact({ + contact_id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + blocked: true, + }); + }); +}); diff --git a/tests/wire/conversations.test.ts b/tests/wire/conversations.test.ts new file mode 100644 index 00000000..77dab803 --- /dev/null +++ b/tests/wire/conversations.test.ts @@ -0,0 +1,12610 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("ConversationsClient", () => { + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "conversation.list", + conversations: [ + { + type: "conversation", + id: "471", + title: "Conversation Title", + created_at: 1734537460, + updated_at: 1734537460, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }], + }, + conversation_rating: { rating: 5, remark: "", created_at: 1671028894, updated_at: 1671028894 }, + source: { + type: "conversation", + id: "403918320", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267628", + name: "Ciaran166 Lee", + email: "admin166@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f0f31bb69f9f2193bb8b", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { total_count: 1 }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_title: "My AI Workflow", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + }, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 20, + total_pages: 1, + }, + }; + server + .mockEndpoint({ once: false }) + .get("/conversations") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const expected = { + type: "conversation.list", + conversations: [ + { + type: "conversation", + id: "471", + title: "Conversation Title", + created_at: 1734537460, + updated_at: 1734537460, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + }, + source: { + type: "conversation", + id: "403918320", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267628", + name: "Ciaran166 Lee", + email: "admin166@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f0f31bb69f9f2193bb8b", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_title: "My AI Workflow", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + }, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 20, + total_pages: 1, + }, + }; + const page = await client.conversations.list({ + per_page: 1, + starting_after: "starting_after", + }); + + expect(expected.conversations).toEqual(page.data); + expect(page.hasNextPage()).toBe(true); + const nextPage = await page.getNextPage(); + expect(expected.conversations).toEqual(nextPage.data); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint({ once: false }) + .get("/conversations") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("list (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint({ once: false }) + .get("/conversations") + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.list(); + }).rejects.toThrow(Intercom.ForbiddenError); + }); + + test("create (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { from: { type: "user", id: "6762f11b1bb69f9f2193bba3" }, body: "Hello there" }; + const rawResponseBody = { + type: "user_message", + id: "403918330", + created_at: 1734537501, + subject: "Greetings", + body: "Hello there", + message_type: "inapp", + conversation_id: "499", + }; + server + .mockEndpoint() + .post("/conversations") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.create({ + from: { + type: "user", + id: "6762f11b1bb69f9f2193bba3", + }, + body: "Hello there", + }); + expect(response).toEqual({ + type: "user_message", + id: "403918330", + created_at: 1734537501, + subject: "Greetings", + body: "Hello there", + message_type: "inapp", + conversation_id: "499", + }); + }); + + test("create (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { from: { type: "user", id: "123_doesnt_exist" }, body: "Hello there" }; + const rawResponseBody = { + type: "user_message", + id: "403918330", + created_at: 1734537501, + subject: "Greetings", + body: "Hello there", + message_type: "inapp", + conversation_id: "499", + }; + server + .mockEndpoint() + .post("/conversations") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.create({ + from: { + type: "user", + id: "123_doesnt_exist", + }, + body: "Hello there", + }); + expect(response).toEqual({ + type: "user_message", + id: "403918330", + created_at: 1734537501, + subject: "Greetings", + body: "Hello there", + message_type: "inapp", + conversation_id: "499", + }); + }); + + test("create (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { from: { type: "lead", id: "blackcurrant............" }, body: "body" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.create({ + from: { + type: "lead", + id: "blackcurrant............", + }, + body: "body", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("create (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { from: { type: "lead", id: "blackcurrant............" }, body: "body" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.create({ + from: { + type: "lead", + id: "blackcurrant............", + }, + body: "body", + }); + }).rejects.toThrow(Intercom.ForbiddenError); + }); + + test("create (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { from: { type: "lead", id: "blackcurrant............" }, body: "body" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.create({ + from: { + type: "lead", + id: "blackcurrant............", + }, + body: "body", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("find (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "conversation", + id: "503", + title: "Conversation Title", + created_at: 1734537511, + updated_at: 1734537511, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918334", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267645", + name: "Ciaran176 Lee", + email: "admin176@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1261bb69f9f2193bba7", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + assigned_to: { type: "contact", id: "1a2b3c" }, + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "open", + tags: [{ type: "tag", id: "123456", name: "Test tag" }], + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "3", + part_type: "custom_action_started", + body: "

Okay!

", + created_at: 1740141842, + updated_at: 1740141842, + notified_at: 1740141842, + author: { + type: "admin", + id: "274", + name: "Jamie Oliver", + email: "jamie+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "open", + tags: [{ type: "tag", id: "123456", name: "Test tag" }], + event_details: { action: { name: "Jira Create Issue" } }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "3", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1740141851, + updated_at: 1740141851, + notified_at: 1740141851, + author: { + type: "bot", + id: "278", + name: "Fin", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "open", + tags: [{ type: "tag", id: "123456", name: "Test tag" }], + event_details: { attribute: { name: "jira_issue_key" }, value: { name: "PROJ-007" } }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "3", + part_type: "custom_action_finished", + body: "

Okay!

", + created_at: 1740141857, + updated_at: 1740141857, + notified_at: 1740141857, + author: { + type: "admin", + id: "274", + name: "Jamie Oliver", + email: "jamie+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "closed", + tags: [{ type: "tag", id: "123456", name: "Test tag" }], + event_details: { action: { name: "Jira Create Issue", result: "success" } }, + app_package_code: "test-integration", + }, + ], + total_count: 4, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server.mockEndpoint().get("/conversations/123").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.conversations.find({ + conversation_id: "123", + display_as: "plaintext", + include_translations: true, + }); + expect(response).toEqual({ + type: "conversation", + id: "503", + title: "Conversation Title", + created_at: 1734537511, + updated_at: 1734537511, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918334", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267645", + name: "Ciaran176 Lee", + email: "admin176@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1261bb69f9f2193bba7", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + assigned_to: { + type: "contact", + id: "1a2b3c", + }, + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "open", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + }, + ], + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "3", + part_type: "custom_action_started", + body: "

Okay!

", + created_at: 1740141842, + updated_at: 1740141842, + notified_at: 1740141842, + author: { + type: "admin", + id: "274", + name: "Jamie Oliver", + email: "jamie+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "open", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + }, + ], + event_details: { + action: { + name: "Jira Create Issue", + }, + }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "3", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1740141851, + updated_at: 1740141851, + notified_at: 1740141851, + author: { + type: "bot", + id: "278", + name: "Fin", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "open", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + }, + ], + event_details: { + attribute: { + name: "jira_issue_key", + }, + value: { + name: "PROJ-007", + }, + }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "3", + part_type: "custom_action_finished", + body: "

Okay!

", + created_at: 1740141857, + updated_at: 1740141857, + notified_at: 1740141857, + author: { + type: "admin", + id: "274", + name: "Jamie Oliver", + email: "jamie+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "closed", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + }, + ], + event_details: { + action: { + name: "Jira Create Issue", + result: "success", + }, + }, + app_package_code: "test-integration", + }, + ], + total_count: 4, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("find (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/conversations/conversation_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.find({ + conversation_id: "conversation_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/conversations/conversation_id") + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.find({ + conversation_id: "conversation_id", + }); + }).rejects.toThrow(Intercom.ForbiddenError); + }); + + test("find (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/conversations/conversation_id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.find({ + conversation_id: "conversation_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("update (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + read: true, + title: "new conversation title", + custom_attributes: { issue_type: "Billing", priority: "High" }, + }; + const rawResponseBody = { + type: "conversation", + id: "507", + title: "Conversation Title", + created_at: 1734537521, + updated_at: 1734537523, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918338", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267653", + name: "Ciaran180 Lee", + email: "admin180@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1301bb69f9f2193bbab", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { issue_type: "Billing", priority: "High" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "129", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "130", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .put("/conversations/conversation_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.update({ + conversation_id: "conversation_id", + display_as: "plaintext", + read: true, + title: "new conversation title", + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "507", + title: "Conversation Title", + created_at: 1734537521, + updated_at: 1734537523, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918338", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267653", + name: "Ciaran180 Lee", + email: "admin180@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1301bb69f9f2193bbab", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "129", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "130", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("update (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { custom_attributes: { order: {} } }; + const rawResponseBody = { + type: "conversation", + id: "508", + title: "Conversation Title", + created_at: 1734537525, + updated_at: 1734537525, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918339", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267659", + name: "Ciaran185 Lee", + email: "admin185@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1341bb69f9f2193bbac", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { + order: { + type: "Order.list", + instances: [ + { + id: "21", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + created_at: 1671028894, + updated_at: 1671028894, + type: "Order", + custom_attributes: { order_number: "ORDER-12345", total_amount: "custom_attributes" }, + }, + ], + }, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 0, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .put("/conversations/conversation_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.update({ + conversation_id: "conversation_id", + display_as: "plaintext", + custom_attributes: { + order: {}, + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "508", + title: "Conversation Title", + created_at: 1734537525, + updated_at: 1734537525, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918339", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267659", + name: "Ciaran185 Lee", + email: "admin185@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1341bb69f9f2193bbac", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + order: { + type: "Order.list", + instances: [ + { + id: "21", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + created_at: 1671028894, + updated_at: 1671028894, + type: "Order", + custom_attributes: { + order_number: "ORDER-12345", + total_amount: "custom_attributes", + }, + }, + ], + }, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 0, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("update (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + read: true, + title: "new conversation title", + custom_attributes: { issue_type: "Billing", priority: "High" }, + }; + const rawResponseBody = { + type: "conversation", + id: "507", + title: "Conversation Title", + created_at: 1734537521, + updated_at: 1734537523, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918338", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267653", + name: "Ciaran180 Lee", + email: "admin180@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1301bb69f9f2193bbab", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { issue_type: "Billing", priority: "High" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "129", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "130", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .put("/conversations/conversation_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.update({ + conversation_id: "conversation_id", + display_as: "plaintext", + read: true, + title: "new conversation title", + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "507", + title: "Conversation Title", + created_at: 1734537521, + updated_at: 1734537523, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918338", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267653", + name: "Ciaran180 Lee", + email: "admin180@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1301bb69f9f2193bbab", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "129", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "130", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("update (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/conversations/conversation_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.update({ + conversation_id: "conversation_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("update (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/conversations/conversation_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.update({ + conversation_id: "conversation_id", + }); + }).rejects.toThrow(Intercom.ForbiddenError); + }); + + test("update (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/conversations/conversation_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.update({ + conversation_id: "conversation_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("deleteConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { id: "512", object: "conversation", deleted: true }; + server + .mockEndpoint() + .delete("/conversations/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.deleteConversation({ + conversation_id: 1, + }); + expect(response).toEqual({ + id: "512", + object: "conversation", + deleted: true, + }); + }); + + test("deleteConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/conversations/1") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.deleteConversation({ + conversation_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("deleteConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/conversations/1") + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.deleteConversation({ + conversation_id: 1, + }); + }).rejects.toThrow(Intercom.ForbiddenError); + }); + + test("search", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + query: { operator: "AND", value: [{ field: "created_at", operator: ">", value: "1306054154" }] }, + pagination: { per_page: 5 }, + }; + const rawResponseBody = { + type: "conversation.list", + conversations: [ + { + type: "conversation", + id: "515", + title: "Conversation Title", + created_at: 1734537546, + updated_at: 1734537546, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }], + }, + conversation_rating: { rating: 5, remark: "", created_at: 1671028894, updated_at: 1671028894 }, + source: { + type: "conversation", + id: "403918346", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267691", + name: "Ciaran210 Lee", + email: "admin210@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f14a1bb69f9f2193bbb3", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { total_count: 1 }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_title: "My AI Workflow", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + }, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 5, + total_pages: 1, + }, + }; + server + .mockEndpoint({ once: false }) + .post("/conversations/search") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const expected = { + type: "conversation.list", + conversations: [ + { + type: "conversation", + id: "515", + title: "Conversation Title", + created_at: 1734537546, + updated_at: 1734537546, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + }, + source: { + type: "conversation", + id: "403918346", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267691", + name: "Ciaran210 Lee", + email: "admin210@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f14a1bb69f9f2193bbb3", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_title: "My AI Workflow", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + }, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 5, + total_pages: 1, + }, + }; + const page = await client.conversations.search({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, + }); + + expect(expected.conversations).toEqual(page.data); + expect(page.hasNextPage()).toBe(true); + const nextPage = await page.getNextPage(); + expect(expected.conversations).toEqual(nextPage.data); + }); + + test("reply (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1571bb69f9f2193bbbb", + }; + const rawResponseBody = { + type: "conversation", + id: "524", + title: "Conversation Title", + created_at: 1734537559, + updated_at: 1734537561, + waiting_since: 1734537561, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918349", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267694", + name: "Ciaran212 Lee", + email: "admin212@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1571bb69f9f2193bbbb", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1734537561, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "132", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537561, + updated_at: 1734537561, + notified_at: 1734537561, + author: { + type: "user", + id: "6762f1571bb69f9f2193bbbb", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123%20or%20%22last%22/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.reply({ + conversation_id: '123 or "last"', + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1571bb69f9f2193bbbb", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "524", + title: "Conversation Title", + created_at: 1734537559, + updated_at: 1734537561, + waiting_since: 1734537561, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918349", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267694", + name: "Ciaran212 Lee", + email: "admin212@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1571bb69f9f2193bbbb", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1734537561, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "132", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537561, + updated_at: 1734537561, + notified_at: 1734537561, + author: { + type: "user", + id: "6762f1571bb69f9f2193bbbb", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("reply (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "note", + type: "admin", + body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + admin_id: "3156780", + }; + const rawResponseBody = { + type: "conversation", + id: "524", + title: "Conversation Title", + created_at: 1734537559, + updated_at: 1734537561, + waiting_since: 1734537561, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918349", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267694", + name: "Ciaran212 Lee", + email: "admin212@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1571bb69f9f2193bbbb", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1734537561, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "132", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537561, + updated_at: 1734537561, + notified_at: 1734537561, + author: { + type: "user", + id: "6762f1571bb69f9f2193bbbb", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123%20or%20%22last%22/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.reply({ + conversation_id: '123 or "last"', + body: { + message_type: "note", + type: "admin", + body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + admin_id: "3156780", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "524", + title: "Conversation Title", + created_at: 1734537559, + updated_at: 1734537561, + waiting_since: 1734537561, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918349", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267694", + name: "Ciaran212 Lee", + email: "admin212@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1571bb69f9f2193bbbb", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1734537561, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "132", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537561, + updated_at: 1734537561, + notified_at: 1734537561, + author: { + type: "user", + id: "6762f1571bb69f9f2193bbbb", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("reply (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "quick_reply", + type: "admin", + admin_id: "3156780", + reply_options: [ + { text: "Yes", uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb" }, + { text: "No", uuid: "f4a98af1-be56-4948-a57e-e1a83f8484c6" }, + ], + }; + const rawResponseBody = { + type: "conversation", + id: "526", + title: "Conversation Title", + created_at: 1734537567, + updated_at: 1734537568, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918351", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267698", + name: "Ciaran214 Lee", + email: "admin214@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f15e1bb69f9f2193bbbd", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "134", + part_type: "quick_reply", + body: "

Okay!

", + created_at: 1734537568, + updated_at: 1734537568, + notified_at: 1734537568, + author: { + type: "admin", + id: "991267698", + name: "Ciaran214 Lee", + email: "admin214@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123%20or%20%22last%22/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.reply({ + conversation_id: '123 or "last"', + body: { + message_type: "quick_reply", + type: "admin", + admin_id: "3156780", + reply_options: [ + { + text: "Yes", + uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb", + }, + { + text: "No", + uuid: "f4a98af1-be56-4948-a57e-e1a83f8484c6", + }, + ], + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "526", + title: "Conversation Title", + created_at: 1734537567, + updated_at: 1734537568, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918351", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267698", + name: "Ciaran214 Lee", + email: "admin214@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f15e1bb69f9f2193bbbd", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "134", + part_type: "quick_reply", + body: "

Okay!

", + created_at: 1734537568, + updated_at: 1734537568, + notified_at: 1734537568, + author: { + type: "admin", + id: "991267698", + name: "Ciaran214 Lee", + email: "admin214@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("reply (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "body", + reply_options: [{ text: "Yes", uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb" }], + intercom_user_id: "6762f1621bb69f9f2193bbbe", + }; + const rawResponseBody = { + type: "conversation", + id: "524", + title: "Conversation Title", + created_at: 1734537559, + updated_at: 1734537561, + waiting_since: 1734537561, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918349", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267694", + name: "Ciaran212 Lee", + email: "admin212@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1571bb69f9f2193bbbb", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1734537561, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "132", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537561, + updated_at: 1734537561, + notified_at: 1734537561, + author: { + type: "user", + id: "6762f1571bb69f9f2193bbbb", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123%20or%20%22last%22/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.reply({ + conversation_id: '123 or "last"', + body: { + message_type: "comment", + type: "user", + body: "body", + reply_options: [ + { + text: "Yes", + uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb", + }, + ], + intercom_user_id: "6762f1621bb69f9f2193bbbe", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "524", + title: "Conversation Title", + created_at: 1734537559, + updated_at: 1734537561, + waiting_since: 1734537561, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918349", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267694", + name: "Ciaran212 Lee", + email: "admin212@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1571bb69f9f2193bbbb", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1734537561, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "132", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537561, + updated_at: 1734537561, + notified_at: 1734537561, + author: { + type: "user", + id: "6762f1571bb69f9f2193bbbb", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("reply (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1661bb69f9f2193bbbf", + }; + const rawResponseBody = { + type: "conversation", + id: "524", + title: "Conversation Title", + created_at: 1734537559, + updated_at: 1734537561, + waiting_since: 1734537561, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918349", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267694", + name: "Ciaran212 Lee", + email: "admin212@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1571bb69f9f2193bbbb", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1734537561, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "132", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537561, + updated_at: 1734537561, + notified_at: 1734537561, + author: { + type: "user", + id: "6762f1571bb69f9f2193bbbb", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123%20or%20%22last%22/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.reply({ + conversation_id: '123 or "last"', + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1661bb69f9f2193bbbf", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "524", + title: "Conversation Title", + created_at: 1734537559, + updated_at: 1734537561, + waiting_since: 1734537561, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918349", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267694", + name: "Ciaran212 Lee", + email: "admin212@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1571bb69f9f2193bbbb", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1734537561, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "132", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537561, + updated_at: 1734537561, + notified_at: 1734537561, + author: { + type: "user", + id: "6762f1571bb69f9f2193bbbb", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("reply (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1571bb69f9f2193bbbb", + }; + const rawResponseBody = { + type: "conversation", + id: "524", + title: "Conversation Title", + created_at: 1734537559, + updated_at: 1734537561, + waiting_since: 1734537561, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918349", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267694", + name: "Ciaran212 Lee", + email: "admin212@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1571bb69f9f2193bbbb", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1734537561, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "132", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537561, + updated_at: 1734537561, + notified_at: 1734537561, + author: { + type: "user", + id: "6762f1571bb69f9f2193bbbb", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123%20or%20%22last%22/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.reply({ + conversation_id: '123 or "last"', + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1571bb69f9f2193bbbb", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "524", + title: "Conversation Title", + created_at: 1734537559, + updated_at: 1734537561, + waiting_since: 1734537561, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918349", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267694", + name: "Ciaran212 Lee", + email: "admin212@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1571bb69f9f2193bbbb", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1734537561, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "132", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537561, + updated_at: 1734537561, + notified_at: 1734537561, + author: { + type: "user", + id: "6762f1571bb69f9f2193bbbb", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("reply (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1571bb69f9f2193bbbb", + }; + const rawResponseBody = { + type: "conversation", + id: "525", + title: "Conversation Title", + created_at: 1734537563, + updated_at: 1734537565, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918350", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267696", + name: "Ciaran213 Lee", + email: "admin213@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f15b1bb69f9f2193bbbc", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "133", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537565, + updated_at: 1734537565, + notified_at: 1734537565, + author: { + type: "admin", + id: "991267696", + name: "Ciaran213 Lee", + email: "admin213@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123%20or%20%22last%22/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.reply({ + conversation_id: '123 or "last"', + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1571bb69f9f2193bbbb", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "525", + title: "Conversation Title", + created_at: 1734537563, + updated_at: 1734537565, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918350", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267696", + name: "Ciaran213 Lee", + email: "admin213@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f15b1bb69f9f2193bbbc", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "133", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537565, + updated_at: 1734537565, + notified_at: 1734537565, + author: { + type: "admin", + id: "991267696", + name: "Ciaran213 Lee", + email: "admin213@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("reply (8)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1571bb69f9f2193bbbb", + }; + const rawResponseBody = { + type: "conversation", + id: "527", + title: "Conversation Title", + created_at: 1734537571, + updated_at: 1734537572, + waiting_since: 1734537572, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918352", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267700", + name: "Ciaran215 Lee", + email: "admin215@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1621bb69f9f2193bbbe", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1734537572, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "135", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537572, + updated_at: 1734537572, + notified_at: 1734537572, + author: { + type: "user", + id: "6762f1621bb69f9f2193bbbe", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123%20or%20%22last%22/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.reply({ + conversation_id: '123 or "last"', + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1571bb69f9f2193bbbb", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "527", + title: "Conversation Title", + created_at: 1734537571, + updated_at: 1734537572, + waiting_since: 1734537572, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918352", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267700", + name: "Ciaran215 Lee", + email: "admin215@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1621bb69f9f2193bbbe", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1734537572, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "135", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537572, + updated_at: 1734537572, + notified_at: 1734537572, + author: { + type: "user", + id: "6762f1621bb69f9f2193bbbe", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("reply (9)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/conversation_id/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.reply({ + conversation_id: "conversation_id", + body: { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("reply (10)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/conversation_id/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.reply({ + conversation_id: "conversation_id", + body: { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }, + }); + }).rejects.toThrow(Intercom.ForbiddenError); + }); + + test("reply (11)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations/conversation_id/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.reply({ + conversation_id: "conversation_id", + body: { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("manage (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "close", type: "admin", admin_id: "12345" }; + const rawResponseBody = { + type: "conversation", + id: "531", + title: "Conversation Title", + created_at: 1734537582, + updated_at: 1734537584, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918356", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f16e1bb69f9f2193bbc2", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "136", + part_type: "close", + body: "

Goodbye :)

", + created_at: 1734537584, + updated_at: 1734537584, + notified_at: 1734537584, + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.manage({ + conversation_id: "123", + body: { + message_type: "close", + type: "admin", + admin_id: "12345", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "531", + title: "Conversation Title", + created_at: 1734537582, + updated_at: 1734537584, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918356", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f16e1bb69f9f2193bbc2", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "136", + part_type: "close", + body: "

Goodbye :)

", + created_at: 1734537584, + updated_at: 1734537584, + notified_at: 1734537584, + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("manage (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "snoozed", admin_id: "5017691", snoozed_until: 1673609604 }; + const rawResponseBody = { + type: "conversation", + id: "532", + title: "Conversation Title", + created_at: 1734537586, + updated_at: 1734537587, + waiting_since: 1663597260, + snoozed_until: 1734541187, + open: true, + state: "snoozed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918357", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267710", + name: "Ciaran220 Lee", + email: "admin220@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1711bb69f9f2193bbc3", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "137", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537587, + updated_at: 1734537587, + notified_at: 1734537587, + author: { + type: "admin", + id: "991267710", + name: "Ciaran220 Lee", + email: "admin220@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.manage({ + conversation_id: "123", + body: { + message_type: "snoozed", + admin_id: "5017691", + snoozed_until: 1673609604, + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "532", + title: "Conversation Title", + created_at: 1734537586, + updated_at: 1734537587, + waiting_since: 1663597260, + snoozed_until: 1734541187, + open: true, + state: "snoozed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918357", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267710", + name: "Ciaran220 Lee", + email: "admin220@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1711bb69f9f2193bbc3", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "137", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537587, + updated_at: 1734537587, + notified_at: 1734537587, + author: { + type: "admin", + id: "991267710", + name: "Ciaran220 Lee", + email: "admin220@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("manage (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "open", admin_id: "5017690" }; + const rawResponseBody = { + type: "conversation", + id: "537", + title: "", + created_at: 1734537587, + updated_at: 1734537601, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918358", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267712", + name: "Ciaran221 Lee", + email: "admin221@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1781bb69f9f2193bbc8", external_id: "74" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "139", + part_type: "open", + body: "

Okay!

", + created_at: 1734537601, + updated_at: 1734537601, + notified_at: 1734537601, + author: { + type: "admin", + id: "991267712", + name: "Ciaran221 Lee", + email: "admin221@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.manage({ + conversation_id: "123", + body: { + message_type: "open", + admin_id: "5017690", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "537", + title: "", + created_at: 1734537587, + updated_at: 1734537601, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918358", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267712", + name: "Ciaran221 Lee", + email: "admin221@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1781bb69f9f2193bbc8", + external_id: "74", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "139", + part_type: "open", + body: "

Okay!

", + created_at: 1734537601, + updated_at: 1734537601, + notified_at: 1734537601, + author: { + type: "admin", + id: "991267712", + name: "Ciaran221 Lee", + email: "admin221@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("manage (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "assignment", type: "admin", admin_id: "12345", assignee_id: "4324241" }; + const rawResponseBody = { + type: "conversation", + id: "542", + title: "Conversation Title", + created_at: 1734537603, + updated_at: 1734537605, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 991267715, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918361", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267715", + name: "Ciaran223 Lee", + email: "admin223@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1831bb69f9f2193bbcc", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "140", + part_type: "assign_and_reopen", + body: "

Okay!

", + created_at: 1734537605, + updated_at: 1734537605, + notified_at: 1734537605, + assigned_to: { type: "admin", id: "991267715" }, + author: { + type: "admin", + id: "991267715", + name: "Ciaran223 Lee", + email: "admin223@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.manage({ + conversation_id: "123", + body: { + message_type: "assignment", + type: "admin", + admin_id: "12345", + assignee_id: "4324241", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "542", + title: "Conversation Title", + created_at: 1734537603, + updated_at: 1734537605, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 991267715, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918361", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267715", + name: "Ciaran223 Lee", + email: "admin223@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1831bb69f9f2193bbcc", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "140", + part_type: "assign_and_reopen", + body: "

Okay!

", + created_at: 1734537605, + updated_at: 1734537605, + notified_at: 1734537605, + assigned_to: { + type: "admin", + id: "991267715", + }, + author: { + type: "admin", + id: "991267715", + name: "Ciaran223 Lee", + email: "admin223@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("manage (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "close", type: "admin", admin_id: "12345" }; + const rawResponseBody = { + type: "conversation", + id: "531", + title: "Conversation Title", + created_at: 1734537582, + updated_at: 1734537584, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918356", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f16e1bb69f9f2193bbc2", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "136", + part_type: "close", + body: "

Goodbye :)

", + created_at: 1734537584, + updated_at: 1734537584, + notified_at: 1734537584, + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.manage({ + conversation_id: "123", + body: { + message_type: "close", + type: "admin", + admin_id: "12345", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "531", + title: "Conversation Title", + created_at: 1734537582, + updated_at: 1734537584, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918356", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f16e1bb69f9f2193bbc2", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "136", + part_type: "close", + body: "

Goodbye :)

", + created_at: 1734537584, + updated_at: 1734537584, + notified_at: 1734537584, + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("manage (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "close", type: "admin", admin_id: "admin_id" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/conversation_id/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.manage({ + conversation_id: "conversation_id", + body: { + message_type: "close", + type: "admin", + admin_id: "admin_id", + }, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("manage (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "close", type: "admin", admin_id: "admin_id" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/conversation_id/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.manage({ + conversation_id: "conversation_id", + body: { + message_type: "close", + type: "admin", + admin_id: "admin_id", + }, + }); + }).rejects.toThrow(Intercom.ForbiddenError); + }); + + test("manage (8)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "close", type: "admin", admin_id: "admin_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations/conversation_id/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.manage({ + conversation_id: "conversation_id", + body: { + message_type: "close", + type: "admin", + admin_id: "admin_id", + }, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("attachContactAsAdmin (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "12345", customer: { intercom_user_id: "6762f19b1bb69f9f2193bbd4" } }; + const rawResponseBody = { + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { type: "contact.list", contacts: [{ id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }] }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { + paid_subscriber: { type: "order.list", instances: [] }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 100, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/customers") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.attachContactAsAdmin({ + conversation_id: "123", + admin_id: "12345", + customer: { + intercom_user_id: "6762f19b1bb69f9f2193bbd4", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + paid_subscriber: { + type: "order.list", + instances: [], + }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 100, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("attachContactAsAdmin (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "12345", customer: { intercom_user_id: "6762f19e1bb69f9f2193bbd5" } }; + const rawResponseBody = { + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { type: "contact.list", contacts: [{ id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }] }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { + paid_subscriber: { type: "order.list", instances: [] }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 100, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/customers") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.attachContactAsAdmin({ + conversation_id: "123", + admin_id: "12345", + customer: { + intercom_user_id: "6762f19e1bb69f9f2193bbd5", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + paid_subscriber: { + type: "order.list", + instances: [], + }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 100, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("attachContactAsAdmin (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/conversation_id/customers") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.attachContactAsAdmin({ + conversation_id: "conversation_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("attachContactAsAdmin (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/conversation_id/customers") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.attachContactAsAdmin({ + conversation_id: "conversation_id", + }); + }).rejects.toThrow(Intercom.ForbiddenError); + }); + + test("attachContactAsAdmin (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations/conversation_id/customers") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.attachContactAsAdmin({ + conversation_id: "conversation_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("detachContactAsAdmin (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "5017690" }; + const rawResponseBody = { + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { type: "contact.list", contacts: [{ id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }] }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { + paid_subscriber: { type: "order.list", instances: [] }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 100, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .delete("/conversations/123/customers/123") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.detachContactAsAdmin({ + conversation_id: "123", + contact_id: "123", + admin_id: "5017690", + }); + expect(response).toEqual({ + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + paid_subscriber: { + type: "order.list", + instances: [], + }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 100, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("detachContactAsAdmin (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "5017690" }; + const rawResponseBody = { + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { type: "contact.list", contacts: [{ id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }] }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { + paid_subscriber: { type: "order.list", instances: [] }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 100, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .delete("/conversations/123/customers/123") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.detachContactAsAdmin({ + conversation_id: "123", + contact_id: "123", + admin_id: "5017690", + }); + expect(response).toEqual({ + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + paid_subscriber: { + type: "order.list", + instances: [], + }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 100, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("detachContactAsAdmin (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "5017690" }; + const rawResponseBody = { + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { type: "contact.list", contacts: [{ id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }] }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { + paid_subscriber: { type: "order.list", instances: [] }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 100, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .delete("/conversations/123/customers/123") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.detachContactAsAdmin({ + conversation_id: "123", + contact_id: "123", + admin_id: "5017690", + }); + expect(response).toEqual({ + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + paid_subscriber: { + type: "order.list", + instances: [], + }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 100, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("detachContactAsAdmin (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "5017690" }; + const rawResponseBody = { + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { type: "contact.list", contacts: [{ id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }] }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { + paid_subscriber: { type: "order.list", instances: [] }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 100, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .delete("/conversations/123/customers/123") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.detachContactAsAdmin({ + conversation_id: "123", + contact_id: "123", + admin_id: "5017690", + }); + expect(response).toEqual({ + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + paid_subscriber: { + type: "order.list", + instances: [], + }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 100, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("detachContactAsAdmin (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/conversations/conversation_id/customers/contact_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.detachContactAsAdmin({ + conversation_id: "conversation_id", + contact_id: "contact_id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("detachContactAsAdmin (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/conversations/conversation_id/customers/contact_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.detachContactAsAdmin({ + conversation_id: "conversation_id", + contact_id: "contact_id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.ForbiddenError); + }); + + test("detachContactAsAdmin (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/conversations/conversation_id/customers/contact_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.detachContactAsAdmin({ + conversation_id: "conversation_id", + contact_id: "contact_id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("detachContactAsAdmin (8)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/conversations/conversation_id/customers/contact_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.detachContactAsAdmin({ + conversation_id: "conversation_id", + contact_id: "contact_id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.UnprocessableEntityError); + }); + + test("redactConversationPart (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + type: "conversation_part", + conversation_id: "19894788788", + conversation_part_id: "19381789428", + }; + const rawResponseBody = { + type: "conversation", + id: "608", + title: "Conversation Title", + created_at: 1734537721, + updated_at: 1734537724, + waiting_since: 1734537722, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918391", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267757", + name: "Ciaran247 Lee", + email: "admin247@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1f81bb69f9f2193bc09", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1734537722, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "149", + part_type: "open", + body: "

This message was deleted

", + created_at: 1734537722, + updated_at: 1734537724, + notified_at: 1734537722, + author: { + type: "user", + id: "6762f1f81bb69f9f2193bc09", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: true, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/redact") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.redactConversationPart({ + type: "conversation_part", + conversation_id: "19894788788", + conversation_part_id: "19381789428", + }); + expect(response).toEqual({ + type: "conversation", + id: "608", + title: "Conversation Title", + created_at: 1734537721, + updated_at: 1734537724, + waiting_since: 1734537722, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918391", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267757", + name: "Ciaran247 Lee", + email: "admin247@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1f81bb69f9f2193bc09", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1734537722, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "149", + part_type: "open", + body: "

This message was deleted

", + created_at: 1734537722, + updated_at: 1734537724, + notified_at: 1734537722, + author: { + type: "user", + id: "6762f1f81bb69f9f2193bc09", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: true, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("redactConversationPart (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + type: "conversation_part", + conversation_id: "really_123_doesnt_exist", + conversation_part_id: "really_123_doesnt_exist", + }; + const rawResponseBody = { + type: "conversation", + id: "608", + title: "Conversation Title", + created_at: 1734537721, + updated_at: 1734537724, + waiting_since: 1734537722, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918391", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267757", + name: "Ciaran247 Lee", + email: "admin247@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1f81bb69f9f2193bc09", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1734537722, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "149", + part_type: "open", + body: "

This message was deleted

", + created_at: 1734537722, + updated_at: 1734537724, + notified_at: 1734537722, + author: { + type: "user", + id: "6762f1f81bb69f9f2193bc09", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: true, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/redact") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.redactConversationPart({ + type: "conversation_part", + conversation_id: "really_123_doesnt_exist", + conversation_part_id: "really_123_doesnt_exist", + }); + expect(response).toEqual({ + type: "conversation", + id: "608", + title: "Conversation Title", + created_at: 1734537721, + updated_at: 1734537724, + waiting_since: 1734537722, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918391", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267757", + name: "Ciaran247 Lee", + email: "admin247@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1f81bb69f9f2193bc09", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1734537722, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "149", + part_type: "open", + body: "

This message was deleted

", + created_at: 1734537722, + updated_at: 1734537724, + notified_at: 1734537722, + author: { + type: "user", + id: "6762f1f81bb69f9f2193bc09", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: true, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("redactConversationPart (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + type: "conversation_part", + conversation_id: "conversation_id", + conversation_part_id: "conversation_part_id", + }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/redact") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.redactConversationPart({ + type: "conversation_part", + conversation_id: "conversation_id", + conversation_part_id: "conversation_part_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("redactConversationPart (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + type: "conversation_part", + conversation_id: "conversation_id", + conversation_part_id: "conversation_part_id", + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations/redact") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.redactConversationPart({ + type: "conversation_part", + conversation_id: "conversation_id", + conversation_part_id: "conversation_part_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("convertToTicket (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_type_id: "53" }; + const rawResponseBody = { + type: "ticket", + id: "611", + ticket_id: "22", + category: "Customer", + ticket_attributes: { key: "value" }, + ticket_state: { + type: "ticket_state", + id: "7493", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "53", + category: "Customer", + name: "my-ticket-type-1", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id442_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537737, + updated_at: 1734537737, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f2041bb69f9f2193bc0c", external_id: "70" }], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537732, + updated_at: 1734537737, + open: true, + snoozed_until: 1663597260, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "151", + part_type: "comment", + body: "

Comment for message

", + created_at: 1734537732, + updated_at: 1734537732, + author: { + type: "user", + id: "6762f2041bb69f9f2193bc0c", + name: "Joe Bloggs", + email: "joe@bloggs.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "152", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537737, + updated_at: 1734537737, + author: { + type: "bot", + id: "991267767", + name: "Fin", + email: "operator+this_is_an_id442_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + is_shared: true, + }; + server + .mockEndpoint() + .post("/conversations/1/convert") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.convertToTicket({ + conversation_id: 1, + ticket_type_id: "53", + }); + expect(response).toEqual({ + type: "ticket", + id: "611", + ticket_id: "22", + category: "Customer", + ticket_attributes: { + key: "value", + }, + ticket_state: { + type: "ticket_state", + id: "7493", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "53", + category: "Customer", + name: "my-ticket-type-1", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id442_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537737, + updated_at: 1734537737, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2041bb69f9f2193bc0c", + external_id: "70", + }, + ], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537732, + updated_at: 1734537737, + open: true, + snoozed_until: 1663597260, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "151", + part_type: "comment", + body: "

Comment for message

", + created_at: 1734537732, + updated_at: 1734537732, + author: { + type: "user", + id: "6762f2041bb69f9f2193bc0c", + name: "Joe Bloggs", + email: "joe@bloggs.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "152", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537737, + updated_at: 1734537737, + author: { + type: "bot", + id: "991267767", + name: "Fin", + email: "operator+this_is_an_id442_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + is_shared: true, + }); + }); + + test("convertToTicket (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_type_id: "54" }; + const rawResponseBody = { + type: "ticket", + id: "611", + ticket_id: "22", + category: "Customer", + ticket_attributes: { key: "value" }, + ticket_state: { + type: "ticket_state", + id: "7493", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "53", + category: "Customer", + name: "my-ticket-type-1", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id442_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537737, + updated_at: 1734537737, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f2041bb69f9f2193bc0c", external_id: "70" }], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537732, + updated_at: 1734537737, + open: true, + snoozed_until: 1663597260, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "151", + part_type: "comment", + body: "

Comment for message

", + created_at: 1734537732, + updated_at: 1734537732, + author: { + type: "user", + id: "6762f2041bb69f9f2193bc0c", + name: "Joe Bloggs", + email: "joe@bloggs.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "152", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537737, + updated_at: 1734537737, + author: { + type: "bot", + id: "991267767", + name: "Fin", + email: "operator+this_is_an_id442_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + is_shared: true, + }; + server + .mockEndpoint() + .post("/conversations/1/convert") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.convertToTicket({ + conversation_id: 1, + ticket_type_id: "54", + }); + expect(response).toEqual({ + type: "ticket", + id: "611", + ticket_id: "22", + category: "Customer", + ticket_attributes: { + key: "value", + }, + ticket_state: { + type: "ticket_state", + id: "7493", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "53", + category: "Customer", + name: "my-ticket-type-1", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id442_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537737, + updated_at: 1734537737, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2041bb69f9f2193bc0c", + external_id: "70", + }, + ], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537732, + updated_at: 1734537737, + open: true, + snoozed_until: 1663597260, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "151", + part_type: "comment", + body: "

Comment for message

", + created_at: 1734537732, + updated_at: 1734537732, + author: { + type: "user", + id: "6762f2041bb69f9f2193bc0c", + name: "Joe Bloggs", + email: "joe@bloggs.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "152", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537737, + updated_at: 1734537737, + author: { + type: "bot", + id: "991267767", + name: "Fin", + email: "operator+this_is_an_id442_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + is_shared: true, + }); + }); + + test("convertToTicket (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_type_id: "ticket_type_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations/1/convert") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.convertToTicket({ + conversation_id: 1, + ticket_type_id: "ticket_type_id", + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("runAssignmentRules (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "conversation", + id: "409", + title: "Conversation Title", + created_at: 1719492880, + updated_at: 1719492881, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918285", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267623", + name: "Ciaran197 Lee", + email: "admin197@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "667d61108a68186f43bafe09", external_id: "70" }], + }, + teammates: { type: "admin.list", admins: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "107", + part_type: "default_assignment", + body: "

Okay!

", + created_at: 1719492881, + updated_at: 1719492881, + notified_at: 1719492881, + assigned_to: { type: "nobody_admin", id: "1a2b3c" }, + author: { + type: "bot", + id: "991267624", + name: "Operator", + email: "operator+this_is_an_id364_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/run_assignment_rules") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.conversations.runAssignmentRules({ + conversation_id: "123", + }); + expect(response).toEqual({ + type: "conversation", + id: "409", + title: "Conversation Title", + created_at: 1719492880, + updated_at: 1719492881, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918285", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267623", + name: "Ciaran197 Lee", + email: "admin197@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "667d61108a68186f43bafe09", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + admins: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "107", + part_type: "default_assignment", + body: "

Okay!

", + created_at: 1719492881, + updated_at: 1719492881, + notified_at: 1719492881, + assigned_to: { + type: "nobody_admin", + id: "1a2b3c", + }, + author: { + type: "bot", + id: "991267624", + name: "Operator", + email: "operator+this_is_an_id364_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("runAssignmentRules (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/conversation_id/run_assignment_rules") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.runAssignmentRules({ + conversation_id: "conversation_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("runAssignmentRules (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/conversation_id/run_assignment_rules") + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.runAssignmentRules({ + conversation_id: "conversation_id", + }); + }).rejects.toThrow(Intercom.ForbiddenError); + }); + + test("runAssignmentRules (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations/conversation_id/run_assignment_rules") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.conversations.runAssignmentRules({ + conversation_id: "conversation_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); +}); diff --git a/tests/wire/customChannelEvents.test.ts b/tests/wire/customChannelEvents.test.ts new file mode 100644 index 00000000..f259cba1 --- /dev/null +++ b/tests/wire/customChannelEvents.test.ts @@ -0,0 +1,790 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("CustomChannelEventsClient", () => { + test("notifyNewConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { + external_conversation_id: "external_conversation_id", + conversation_id: "conversation_id", + external_contact_id: "external_contact_id", + contact_id: "contact_id", + }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_conversation") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.customChannelEvents.notifyNewConversation({ + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + expect(response).toEqual({ + external_conversation_id: "external_conversation_id", + conversation_id: "conversation_id", + external_contact_id: "external_contact_id", + contact_id: "contact_id", + }); + }); + + test("notifyNewConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_conversation") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyNewConversation({ + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("notifyNewConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_conversation") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyNewConversation({ + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("notifyNewConversation (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_conversation") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyNewConversation({ + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("notifyNewConversation (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_conversation") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyNewConversation({ + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.UnprocessableEntityError); + }); + + test("notifyNewMessage (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { + external_conversation_id: "external_conversation_id", + conversation_id: "conversation_id", + external_contact_id: "external_contact_id", + contact_id: "contact_id", + }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_message") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.customChannelEvents.notifyNewMessage({ + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + expect(response).toEqual({ + external_conversation_id: "external_conversation_id", + conversation_id: "conversation_id", + external_contact_id: "external_contact_id", + contact_id: "contact_id", + }); + }); + + test("notifyNewMessage (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_message") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyNewMessage({ + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("notifyNewMessage (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_message") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyNewMessage({ + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("notifyNewMessage (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_message") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyNewMessage({ + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("notifyNewMessage (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_message") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyNewMessage({ + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.UnprocessableEntityError); + }); + + test("notifyQuickReplySelected (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + event_id: "evt_67890", + external_conversation_id: "conv_13579", + contact: { type: "user", external_id: "user_003", name: "Alice Example", email: "alice@example.com" }, + quick_reply_option_id: "1234", + }; + const rawResponseBody = { + external_conversation_id: "customer_conversation_id_12", + conversation_id: "intercom_conversation_id_34", + external_contact_id: "customer_contact_id_56", + contact_id: "intercom_contact_id_79", + }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_quick_reply_selected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.customChannelEvents.notifyQuickReplySelected({ + event_id: "evt_67890", + external_conversation_id: "conv_13579", + contact: { + type: "user", + external_id: "user_003", + name: "Alice Example", + email: "alice@example.com", + }, + quick_reply_option_id: "1234", + }); + expect(response).toEqual({ + external_conversation_id: "customer_conversation_id_12", + conversation_id: "intercom_conversation_id_34", + external_contact_id: "customer_contact_id_56", + contact_id: "intercom_contact_id_79", + }); + }); + + test("notifyQuickReplySelected (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_quick_reply_selected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyQuickReplySelected({ + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("notifyQuickReplySelected (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_quick_reply_selected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyQuickReplySelected({ + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("notifyQuickReplySelected (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_quick_reply_selected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyQuickReplySelected({ + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("notifyQuickReplySelected (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_quick_reply_selected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyQuickReplySelected({ + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.UnprocessableEntityError); + }); + + test("notifyAttributeCollected (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + attribute: { id: "id", value: "value" }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { + external_conversation_id: "external_conversation_id", + conversation_id: "conversation_id", + external_contact_id: "external_contact_id", + contact_id: "contact_id", + }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_attribute_collected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.customChannelEvents.notifyAttributeCollected({ + attribute: { + id: "id", + value: "value", + }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + expect(response).toEqual({ + external_conversation_id: "external_conversation_id", + conversation_id: "conversation_id", + external_contact_id: "external_contact_id", + contact_id: "contact_id", + }); + }); + + test("notifyAttributeCollected (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + attribute: { id: "id", value: "value" }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_attribute_collected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyAttributeCollected({ + attribute: { + id: "id", + value: "value", + }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("notifyAttributeCollected (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + attribute: { id: "id", value: "value" }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_attribute_collected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyAttributeCollected({ + attribute: { + id: "id", + value: "value", + }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("notifyAttributeCollected (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + attribute: { id: "id", value: "value" }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_attribute_collected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyAttributeCollected({ + attribute: { + id: "id", + value: "value", + }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("notifyAttributeCollected (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + attribute: { id: "id", value: "value" }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_attribute_collected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customChannelEvents.notifyAttributeCollected({ + attribute: { + id: "id", + value: "value", + }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.UnprocessableEntityError); + }); +}); diff --git a/tests/wire/customObjectInstances.test.ts b/tests/wire/customObjectInstances.test.ts new file mode 100644 index 00000000..8d12db82 --- /dev/null +++ b/tests/wire/customObjectInstances.test.ts @@ -0,0 +1,475 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("CustomObjectInstancesClient", () => { + test("getCustomObjectInstancesByExternalId (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + id: "24", + external_id: "123", + external_created_at: 1571672154, + external_updated_at: 1571672154, + created_at: 1734537748, + updated_at: 1734537748, + type: "Order", + custom_attributes: { order_number: "ORDER-12345", total_amount: "custom_attributes" }, + }; + server + .mockEndpoint() + .get("/custom_object_instances/Order") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.customObjectInstances.getCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "Order", + external_id: "external_id", + }); + expect(response).toEqual({ + id: "24", + external_id: "123", + external_created_at: 1571672154, + external_updated_at: 1571672154, + created_at: 1734537748, + updated_at: 1734537748, + type: "Order", + custom_attributes: { + order_number: "ORDER-12345", + total_amount: "custom_attributes", + }, + }); + }); + + test("getCustomObjectInstancesByExternalId (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/custom_object_instances/custom_object_type_identifier") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customObjectInstances.getCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "custom_object_type_identifier", + external_id: "external_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("getCustomObjectInstancesByExternalId (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/custom_object_instances/custom_object_type_identifier") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customObjectInstances.getCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "custom_object_type_identifier", + external_id: "external_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("createCustomObjectInstances (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + custom_attributes: { order_number: "ORDER-12345", total_amount: "custom_attributes" }, + }; + const rawResponseBody = { + id: "22", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + created_at: 1734537745, + updated_at: 1734537745, + type: "Order", + custom_attributes: { order_number: "ORDER-12345", total_amount: "custom_attributes" }, + }; + server + .mockEndpoint() + .post("/custom_object_instances/Order") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.customObjectInstances.createCustomObjectInstances({ + custom_object_type_identifier: "Order", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + custom_attributes: { + order_number: "ORDER-12345", + total_amount: "custom_attributes", + }, + }); + expect(response).toEqual({ + id: "22", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + created_at: 1734537745, + updated_at: 1734537745, + type: "Order", + custom_attributes: { + order_number: "ORDER-12345", + total_amount: "custom_attributes", + }, + }); + }); + + test("createCustomObjectInstances (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/custom_object_instances/custom_object_type_identifier") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customObjectInstances.createCustomObjectInstances({ + custom_object_type_identifier: "custom_object_type_identifier", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("createCustomObjectInstances (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_object_instances/custom_object_type_identifier") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customObjectInstances.createCustomObjectInstances({ + custom_object_type_identifier: "custom_object_type_identifier", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("deleteCustomObjectInstancesById (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { object: "Order", id: "26", deleted: true }; + server + .mockEndpoint() + .delete("/custom_object_instances/Order") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.customObjectInstances.deleteCustomObjectInstancesById({ + custom_object_type_identifier: "Order", + external_id: "external_id", + }); + expect(response).toEqual({ + object: "Order", + id: "26", + deleted: true, + }); + }); + + test("deleteCustomObjectInstancesById (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/custom_object_instances/custom_object_type_identifier") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customObjectInstances.deleteCustomObjectInstancesById({ + custom_object_type_identifier: "custom_object_type_identifier", + external_id: "external_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("deleteCustomObjectInstancesById (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/custom_object_instances/custom_object_type_identifier") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customObjectInstances.deleteCustomObjectInstancesById({ + custom_object_type_identifier: "custom_object_type_identifier", + external_id: "external_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("getCustomObjectInstancesById (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + id: "25", + external_id: "123", + external_created_at: 1571672154, + external_updated_at: 1571672154, + created_at: 1734537750, + updated_at: 1734537750, + type: "Order", + custom_attributes: { order_number: "ORDER-12345", total_amount: "custom_attributes" }, + }; + server + .mockEndpoint() + .get("/custom_object_instances/Order/custom_object_instance_id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.customObjectInstances.getCustomObjectInstancesById({ + custom_object_type_identifier: "Order", + custom_object_instance_id: "custom_object_instance_id", + }); + expect(response).toEqual({ + id: "25", + external_id: "123", + external_created_at: 1571672154, + external_updated_at: 1571672154, + created_at: 1734537750, + updated_at: 1734537750, + type: "Order", + custom_attributes: { + order_number: "ORDER-12345", + total_amount: "custom_attributes", + }, + }); + }); + + test("getCustomObjectInstancesById (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/custom_object_instances/custom_object_type_identifier/custom_object_instance_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customObjectInstances.getCustomObjectInstancesById({ + custom_object_type_identifier: "custom_object_type_identifier", + custom_object_instance_id: "custom_object_instance_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("getCustomObjectInstancesById (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/custom_object_instances/custom_object_type_identifier/custom_object_instance_id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customObjectInstances.getCustomObjectInstancesById({ + custom_object_type_identifier: "custom_object_type_identifier", + custom_object_instance_id: "custom_object_instance_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("deleteCustomObjectInstancesByExternalId (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { object: "Order", id: "26", deleted: true }; + server + .mockEndpoint() + .delete("/custom_object_instances/Order/custom_object_instance_id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.customObjectInstances.deleteCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "Order", + custom_object_instance_id: "custom_object_instance_id", + }); + expect(response).toEqual({ + object: "Order", + id: "26", + deleted: true, + }); + }); + + test("deleteCustomObjectInstancesByExternalId (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/custom_object_instances/custom_object_type_identifier/custom_object_instance_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customObjectInstances.deleteCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "custom_object_type_identifier", + custom_object_instance_id: "custom_object_instance_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("deleteCustomObjectInstancesByExternalId (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/custom_object_instances/custom_object_type_identifier/custom_object_instance_id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.customObjectInstances.deleteCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "custom_object_type_identifier", + custom_object_instance_id: "custom_object_instance_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); +}); diff --git a/tests/wire/dataAttributes.test.ts b/tests/wire/dataAttributes.test.ts new file mode 100644 index 00000000..b5b723af --- /dev/null +++ b/tests/wire/dataAttributes.test.ts @@ -0,0 +1,1515 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("DataAttributesClient", () => { + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "data_attribute", + id: 12878, + model: "company", + name: "name", + full_name: "name", + label: "Company name", + description: "The name of a company", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "company_id", + full_name: "company_id", + label: "Company ID", + description: "A number identifying a company", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "last_request_at", + full_name: "last_request_at", + label: "Company last seen", + description: "The last day anyone from a company visited your site or app", + data_type: "date", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "remote_created_at", + full_name: "remote_created_at", + label: "Company created at", + description: "The day a company was added to Intercom", + data_type: "date", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "user_count", + full_name: "user_count", + label: "People", + description: "The number of people in a company", + data_type: "integer", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "session_count", + full_name: "session_count", + label: "Company web sessions", + description: "All visits from anyone in a company to your product's site or app", + data_type: "integer", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "name", + full_name: "plan.name", + label: "Plan", + description: "A specific plan or level within your product that companies have signed up to", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "monthly_spend", + full_name: "monthly_spend", + label: "Monthly Spend", + description: "The monthly revenue you receive from a company", + data_type: "float", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "size", + full_name: "size", + label: "Company size", + description: "The number of people employed in this company, expressed as a single number", + data_type: "integer", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "industry", + full_name: "industry", + label: "Company industry", + description: "The category or domain this company belongs to e.g. 'ecommerce' or 'SaaS'", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "website", + full_name: "website", + label: "Company website", + description: "The web address for the company's primary marketing site", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 34, + model: "company", + name: "The One Ring", + full_name: "custom_attributes.The One Ring", + label: "The One Ring", + description: + "One ring to rule them all, one ring to find them, One ring to bring them all and in the darkness bind them.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537753, + updated_at: 1734537753, + admin_id: "991267784", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "id", + full_name: "id", + label: "ID", + description: "The Intercom defined id representing the company", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "created_at", + full_name: "created_at", + label: "Created at", + description: "The time the company was added to Intercom", + data_type: "date", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "updated_at", + full_name: "updated_at", + label: "Updated at", + description: "The last time the company was updated", + data_type: "date", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "id", + full_name: "plan.id", + label: "Plan ID", + description: "The Intercom defined id representing the plan", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "app_id", + full_name: "app_id", + label: "App ID", + description: "The Intercom defined id representing the app", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + ], + }; + server.mockEndpoint().get("/data_attributes").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.dataAttributes.list({ + model: "contact", + include_archived: true, + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "data_attribute", + id: 12878, + model: "company", + name: "name", + full_name: "name", + label: "Company name", + description: "The name of a company", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "company_id", + full_name: "company_id", + label: "Company ID", + description: "A number identifying a company", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "last_request_at", + full_name: "last_request_at", + label: "Company last seen", + description: "The last day anyone from a company visited your site or app", + data_type: "date", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "remote_created_at", + full_name: "remote_created_at", + label: "Company created at", + description: "The day a company was added to Intercom", + data_type: "date", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "user_count", + full_name: "user_count", + label: "People", + description: "The number of people in a company", + data_type: "integer", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "session_count", + full_name: "session_count", + label: "Company web sessions", + description: "All visits from anyone in a company to your product's site or app", + data_type: "integer", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "name", + full_name: "plan.name", + label: "Plan", + description: "A specific plan or level within your product that companies have signed up to", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "monthly_spend", + full_name: "monthly_spend", + label: "Monthly Spend", + description: "The monthly revenue you receive from a company", + data_type: "float", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "size", + full_name: "size", + label: "Company size", + description: "The number of people employed in this company, expressed as a single number", + data_type: "integer", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "industry", + full_name: "industry", + label: "Company industry", + description: "The category or domain this company belongs to e.g. 'ecommerce' or 'SaaS'", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "website", + full_name: "website", + label: "Company website", + description: "The web address for the company's primary marketing site", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 34, + model: "company", + name: "The One Ring", + full_name: "custom_attributes.The One Ring", + label: "The One Ring", + description: + "One ring to rule them all, one ring to find them, One ring to bring them all and in the darkness bind them.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537753, + updated_at: 1734537753, + admin_id: "991267784", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "id", + full_name: "id", + label: "ID", + description: "The Intercom defined id representing the company", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "created_at", + full_name: "created_at", + label: "Created at", + description: "The time the company was added to Intercom", + data_type: "date", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "updated_at", + full_name: "updated_at", + label: "Updated at", + description: "The last time the company was updated", + data_type: "date", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "id", + full_name: "plan.id", + label: "Plan ID", + description: "The Intercom defined id representing the plan", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "app_id", + full_name: "app_id", + label: "App ID", + description: "The Intercom defined id representing the app", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + ], + }); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/data_attributes").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.dataAttributes.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("create (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { data_type: "string" }; + const rawResponseBody = { + type: "data_attribute", + id: 37, + model: "company", + name: "Mithril Shirt", + full_name: "custom_attributes.Mithril Shirt", + label: "Mithril Shirt", + description: "Whether the user is a paid subscriber.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: false, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537756, + updated_at: 1734537756, + admin_id: "991267786", + }; + server + .mockEndpoint() + .post("/data_attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataAttributes.create({ + data_type: "string", + }); + expect(response).toEqual({ + type: "data_attribute", + id: 37, + model: "company", + name: "Mithril Shirt", + full_name: "custom_attributes.Mithril Shirt", + label: "Mithril Shirt", + description: "Whether the user is a paid subscriber.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: false, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537756, + updated_at: 1734537756, + admin_id: "991267786", + }); + }); + + test("create (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { data_type: "integer" }; + const rawResponseBody = { + type: "data_attribute", + id: 37, + model: "company", + name: "Mithril Shirt", + full_name: "custom_attributes.Mithril Shirt", + label: "Mithril Shirt", + description: "Whether the user is a paid subscriber.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: false, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537756, + updated_at: 1734537756, + admin_id: "991267786", + }; + server + .mockEndpoint() + .post("/data_attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataAttributes.create({ + data_type: "integer", + }); + expect(response).toEqual({ + type: "data_attribute", + id: 37, + model: "company", + name: "Mithril Shirt", + full_name: "custom_attributes.Mithril Shirt", + label: "Mithril Shirt", + description: "Whether the user is a paid subscriber.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: false, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537756, + updated_at: 1734537756, + admin_id: "991267786", + }); + }); + + test("create (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { data_type: "string" }; + const rawResponseBody = { + type: "data_attribute", + id: 37, + model: "company", + name: "Mithril Shirt", + full_name: "custom_attributes.Mithril Shirt", + label: "Mithril Shirt", + description: "Whether the user is a paid subscriber.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: false, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537756, + updated_at: 1734537756, + admin_id: "991267786", + }; + server + .mockEndpoint() + .post("/data_attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataAttributes.create({ + data_type: "string", + }); + expect(response).toEqual({ + type: "data_attribute", + id: 37, + model: "company", + name: "Mithril Shirt", + full_name: "custom_attributes.Mithril Shirt", + label: "Mithril Shirt", + description: "Whether the user is a paid subscriber.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: false, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537756, + updated_at: 1734537756, + admin_id: "991267786", + }); + }); + + test("create (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { data_type: "string" }; + const rawResponseBody = { + type: "data_attribute", + id: 37, + model: "company", + name: "Mithril Shirt", + full_name: "custom_attributes.Mithril Shirt", + label: "Mithril Shirt", + description: "Whether the user is a paid subscriber.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: false, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537756, + updated_at: 1734537756, + admin_id: "991267786", + }; + server + .mockEndpoint() + .post("/data_attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataAttributes.create({ + data_type: "string", + }); + expect(response).toEqual({ + type: "data_attribute", + id: 37, + model: "company", + name: "Mithril Shirt", + full_name: "custom_attributes.Mithril Shirt", + label: "Mithril Shirt", + description: "Whether the user is a paid subscriber.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: false, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537756, + updated_at: 1734537756, + admin_id: "991267786", + }); + }); + + test("create (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { data_type: "string" }; + const rawResponseBody = { + type: "data_attribute", + id: 37, + model: "company", + name: "Mithril Shirt", + full_name: "custom_attributes.Mithril Shirt", + label: "Mithril Shirt", + description: "Whether the user is a paid subscriber.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: false, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537756, + updated_at: 1734537756, + admin_id: "991267786", + }; + server + .mockEndpoint() + .post("/data_attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataAttributes.create({ + data_type: "string", + }); + expect(response).toEqual({ + type: "data_attribute", + id: 37, + model: "company", + name: "Mithril Shirt", + full_name: "custom_attributes.Mithril Shirt", + label: "Mithril Shirt", + description: "Whether the user is a paid subscriber.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: false, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537756, + updated_at: 1734537756, + admin_id: "991267786", + }); + }); + + test("create (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { options: [{ value: "1-10" }] }; + const rawResponseBody = { + type: "data_attribute", + id: 37, + model: "company", + name: "Mithril Shirt", + full_name: "custom_attributes.Mithril Shirt", + label: "Mithril Shirt", + description: "Whether the user is a paid subscriber.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: false, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537756, + updated_at: 1734537756, + admin_id: "991267786", + }; + server + .mockEndpoint() + .post("/data_attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataAttributes.create({ + options: [ + { + value: "1-10", + }, + ], + }); + expect(response).toEqual({ + type: "data_attribute", + id: 37, + model: "company", + name: "Mithril Shirt", + full_name: "custom_attributes.Mithril Shirt", + label: "Mithril Shirt", + description: "Whether the user is a paid subscriber.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: false, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537756, + updated_at: 1734537756, + admin_id: "991267786", + }); + }); + + test("create (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { options: [{}, {}] }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/data_attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.dataAttributes.create({ + options: [{}, {}], + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("create (8)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { options: [{}, {}] }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/data_attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.dataAttributes.create({ + options: [{}, {}], + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("update (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { options: [{ value: "1-10" }, { value: "11-20" }] }; + const rawResponseBody = { + type: "data_attribute", + id: 44, + model: "company", + name: "The One Ring", + full_name: "custom_attributes.The One Ring", + label: "The One Ring", + description: "Just a plain old ring", + data_type: "string", + options: ["1-10", "11-20"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537762, + updated_at: 1734537763, + admin_id: "991267793", + }; + server + .mockEndpoint() + .put("/data_attributes/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataAttributes.update({ + data_attribute_id: 1, + body: { + options: [ + { + value: "1-10", + }, + { + value: "11-20", + }, + ], + }, + }); + expect(response).toEqual({ + type: "data_attribute", + id: 44, + model: "company", + name: "The One Ring", + full_name: "custom_attributes.The One Ring", + label: "The One Ring", + description: "Just a plain old ring", + data_type: "string", + options: ["1-10", "11-20"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537762, + updated_at: 1734537763, + admin_id: "991267793", + }); + }); + + test("update (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { options: [{ value: "1-10" }, { value: "11-50" }] }; + const rawResponseBody = { + type: "data_attribute", + id: 44, + model: "company", + name: "The One Ring", + full_name: "custom_attributes.The One Ring", + label: "The One Ring", + description: "Just a plain old ring", + data_type: "string", + options: ["1-10", "11-20"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537762, + updated_at: 1734537763, + admin_id: "991267793", + }; + server + .mockEndpoint() + .put("/data_attributes/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataAttributes.update({ + data_attribute_id: 1, + body: { + options: [ + { + value: "1-10", + }, + { + value: "11-50", + }, + ], + }, + }); + expect(response).toEqual({ + type: "data_attribute", + id: 44, + model: "company", + name: "The One Ring", + full_name: "custom_attributes.The One Ring", + label: "The One Ring", + description: "Just a plain old ring", + data_type: "string", + options: ["1-10", "11-20"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537762, + updated_at: 1734537763, + admin_id: "991267793", + }); + }); + + test("update (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { options: [{ value: "1-10" }, { value: "11-20" }] }; + const rawResponseBody = { + type: "data_attribute", + id: 44, + model: "company", + name: "The One Ring", + full_name: "custom_attributes.The One Ring", + label: "The One Ring", + description: "Just a plain old ring", + data_type: "string", + options: ["1-10", "11-20"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537762, + updated_at: 1734537763, + admin_id: "991267793", + }; + server + .mockEndpoint() + .put("/data_attributes/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataAttributes.update({ + data_attribute_id: 1, + body: { + options: [ + { + value: "1-10", + }, + { + value: "11-20", + }, + ], + }, + }); + expect(response).toEqual({ + type: "data_attribute", + id: 44, + model: "company", + name: "The One Ring", + full_name: "custom_attributes.The One Ring", + label: "The One Ring", + description: "Just a plain old ring", + data_type: "string", + options: ["1-10", "11-20"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537762, + updated_at: 1734537763, + admin_id: "991267793", + }); + }); + + test("update (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { description: "Trying to archieve", archived: true }; + const rawResponseBody = { + type: "data_attribute", + id: 44, + model: "company", + name: "The One Ring", + full_name: "custom_attributes.The One Ring", + label: "The One Ring", + description: "Just a plain old ring", + data_type: "string", + options: ["1-10", "11-20"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537762, + updated_at: 1734537763, + admin_id: "991267793", + }; + server + .mockEndpoint() + .put("/data_attributes/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataAttributes.update({ + data_attribute_id: 1, + body: { + description: "Trying to archieve", + archived: true, + }, + }); + expect(response).toEqual({ + type: "data_attribute", + id: 44, + model: "company", + name: "The One Ring", + full_name: "custom_attributes.The One Ring", + label: "The One Ring", + description: "Just a plain old ring", + data_type: "string", + options: ["1-10", "11-20"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537762, + updated_at: 1734537763, + admin_id: "991267793", + }); + }); + + test("update (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { options: [{}, {}] }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/data_attributes/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.dataAttributes.update({ + data_attribute_id: 1, + body: { + options: [{}, {}], + }, + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("update (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { options: [{}, {}] }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/data_attributes/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.dataAttributes.update({ + data_attribute_id: 1, + body: { + options: [{}, {}], + }, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("update (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { options: [{}, {}] }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/data_attributes/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.dataAttributes.update({ + data_attribute_id: 1, + body: { + options: [{}, {}], + }, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("update (8)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { options: [{}, {}] }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/data_attributes/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.dataAttributes.update({ + data_attribute_id: 1, + body: { + options: [{}, {}], + }, + }); + }).rejects.toThrow(Intercom.UnprocessableEntityError); + }); +}); diff --git a/tests/wire/dataExport.test.ts b/tests/wire/dataExport.test.ts new file mode 100644 index 00000000..a141d93e --- /dev/null +++ b/tests/wire/dataExport.test.ts @@ -0,0 +1,273 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("DataExportClient", () => { + test("exportReportingData (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + job_identifier: "job1", + status: "complete", + download_url: "", + download_expires_at: "", + }; + server + .mockEndpoint() + .get("/export/reporting_data/job_identifier") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataExport.exportReportingData({ + job_identifier: "job_identifier", + app_id: "app_id", + client_id: "client_id", + }); + expect(response).toEqual({ + job_identifier: "job1", + status: "complete", + download_url: "", + download_expires_at: "", + }); + }); + + test("exportReportingData (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { job_identifier: "job1", status: "failed", download_url: "", download_expires_at: "" }; + server + .mockEndpoint() + .get("/export/reporting_data/job_identifier") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataExport.exportReportingData({ + job_identifier: "job_identifier", + app_id: "app_id", + client_id: "client_id", + }); + expect(response).toEqual({ + job_identifier: "job1", + status: "failed", + download_url: "", + download_expires_at: "", + }); + }); + + test("exportReportingData (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/export/reporting_data/job_identifier") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.dataExport.exportReportingData({ + job_identifier: "job_identifier", + app_id: "app_id", + client_id: "client_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("downloadReportingDataExport (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + server + .mockEndpoint() + .get("/download/reporting_data/job_identifier") + .header("Accept", "application/octet-stream") + .respondWith() + .statusCode(200) + .build(); + + const response = await client.dataExport.downloadReportingDataExport({ + job_identifier: "job_identifier", + app_id: "app_id", + }); + expect(response).toEqual(undefined); + }); + + test("downloadReportingDataExport (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/download/reporting_data/job_identifier") + .header("Accept", "application/octet-stream") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.dataExport.downloadReportingDataExport({ + job_identifier: "job_identifier", + app_id: "app_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("create", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { created_at_after: 1734519776, created_at_before: 1734537776 }; + const rawResponseBody = { + job_identifier: "al9w983lwu88w1fd", + status: "pending", + download_expires_at: "", + download_url: "", + }; + server + .mockEndpoint() + .post("/export/content/data") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataExport.create({ + created_at_after: 1734519776, + created_at_before: 1734537776, + }); + expect(response).toEqual({ + job_identifier: "al9w983lwu88w1fd", + status: "pending", + download_expires_at: "", + download_url: "", + }); + }); + + test("find", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + job_identifier: "braxwk3j039t6txy", + status: "pending", + download_expires_at: "", + download_url: "", + }; + server + .mockEndpoint() + .get("/export/content/data/job_identifier") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataExport.find({ + job_identifier: "job_identifier", + }); + expect(response).toEqual({ + job_identifier: "braxwk3j039t6txy", + status: "pending", + download_expires_at: "", + download_url: "", + }); + }); + + test("cancel", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + job_identifier: "v134nyc2bku9hj91", + status: "canceled", + download_expires_at: "", + download_url: "", + }; + server + .mockEndpoint() + .post("/export/cancel/job_identifier") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.dataExport.cancel({ + job_identifier: "job_identifier", + }); + expect(response).toEqual({ + job_identifier: "v134nyc2bku9hj91", + status: "canceled", + download_expires_at: "", + download_url: "", + }); + }); + + test("download", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + server.mockEndpoint().get("/download/content/data/job_identifier").respondWith().statusCode(200).build(); + + const response = await client.dataExport.download({ + job_identifier: "job_identifier", + }); + expect(response).toEqual(undefined); + }); +}); diff --git a/tests/wire/events.test.ts b/tests/wire/events.test.ts new file mode 100644 index 00000000..b6b4756a --- /dev/null +++ b/tests/wire/events.test.ts @@ -0,0 +1,169 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("EventsClient", () => { + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "event.summary", + email: "user26@email.com", + intercom_user_id: "6762f22b1bb69f9f2193bc12", + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + events: [ + { + name: "placed-order", + first: "2014-01-16T23:12:21.000+00:00", + last: "2014-01-16T23:12:21.000+00:00 ", + count: 1, + description: "A user placed an order", + }, + ], + }; + server.mockEndpoint().get("/events").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.events.list({ + user_id: "user_id", + intercom_user_id: "intercom_user_id", + email: "email", + type: "type", + summary: true, + per_page: 1, + }); + expect(response).toEqual({ + type: "event.summary", + email: "user26@email.com", + intercom_user_id: "6762f22b1bb69f9f2193bc12", + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + events: [ + { + name: "placed-order", + first: "2014-01-16T23:12:21.000+00:00", + last: "2014-01-16T23:12:21.000+00:00 ", + count: 1, + description: "A user placed an order", + }, + ], + }); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/events").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.events.list({ + type: "type", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("create (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + id: "8a88a590-e1c3-41e2-a502-e0649dbf721c", + event_name: "invited-friend", + created_at: 1671028894, + }; + + server.mockEndpoint().post("/events").jsonBody(rawRequestBody).respondWith().statusCode(200).build(); + + const response = await client.events.create({ + id: "8a88a590-e1c3-41e2-a502-e0649dbf721c", + event_name: "invited-friend", + created_at: 1671028894, + }); + expect(response).toEqual(undefined); + }); + + test("create (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id", event_name: "event_name", created_at: 1 }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/events") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.events.create({ + id: "id", + event_name: "event_name", + created_at: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("summaries (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + + server.mockEndpoint().post("/events/summaries").jsonBody(rawRequestBody).respondWith().statusCode(200).build(); + + const response = await client.events.summaries(); + expect(response).toEqual(undefined); + }); + + test("summaries (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/events/summaries") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.events.summaries(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); +}); diff --git a/tests/wire/export.test.ts b/tests/wire/export.test.ts new file mode 100644 index 00000000..c7ff75eb --- /dev/null +++ b/tests/wire/export.test.ts @@ -0,0 +1,201 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("ExportClient", () => { + test("enqueueANewReportingDataExportJob (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + dataset_id: "conversation", + attribute_ids: ["conversation_id", "conversation_started_at"], + start_time: 1717490000, + end_time: 1717510000, + }; + const rawResponseBody = { + job_identifier: "job1", + status: "pending", + download_url: "download_url", + download_expires_at: "download_expires_at", + }; + server + .mockEndpoint() + .post("/export/reporting_data/enqueue") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.export.enqueueANewReportingDataExportJob({ + dataset_id: "conversation", + attribute_ids: ["conversation_id", "conversation_started_at"], + start_time: 1717490000, + end_time: 1717510000, + }); + expect(response).toEqual({ + job_identifier: "job1", + status: "pending", + download_url: "download_url", + download_expires_at: "download_expires_at", + }); + }); + + test("enqueueANewReportingDataExportJob (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + dataset_id: "dataset_id", + attribute_ids: ["attribute_ids", "attribute_ids"], + start_time: 1000000, + end_time: 1000000, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/export/reporting_data/enqueue") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.export.enqueueANewReportingDataExportJob({ + dataset_id: "dataset_id", + attribute_ids: ["attribute_ids", "attribute_ids"], + start_time: 1000000, + end_time: 1000000, + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("enqueueANewReportingDataExportJob (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + dataset_id: "dataset_id", + attribute_ids: ["attribute_ids", "attribute_ids"], + start_time: 1000000, + end_time: 1000000, + }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/export/reporting_data/enqueue") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.export.enqueueANewReportingDataExportJob({ + dataset_id: "dataset_id", + attribute_ids: ["attribute_ids", "attribute_ids"], + start_time: 1000000, + end_time: 1000000, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("enqueueANewReportingDataExportJob (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + dataset_id: "dataset_id", + attribute_ids: ["attribute_ids", "attribute_ids"], + start_time: 1000000, + end_time: 1000000, + }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/export/reporting_data/enqueue") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(429) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.export.enqueueANewReportingDataExportJob({ + dataset_id: "dataset_id", + attribute_ids: ["attribute_ids", "attribute_ids"], + start_time: 1000000, + end_time: 1000000, + }); + }).rejects.toThrow(Intercom.TooManyRequestsError); + }); + + test("listAvailableDatasetsAndAttributes", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + id: "conversation", + name: "Conversation", + description: "Conversation-level details: status, channel, assignee.", + default_time_attribute_id: "conversation_started_at", + attributes: [{ id: "conversation_id", name: "Conversation ID" }], + }, + ], + }; + server + .mockEndpoint() + .get("/export/reporting_data/get_datasets") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.export.listAvailableDatasetsAndAttributes(); + expect(response).toEqual({ + type: "list", + data: [ + { + id: "conversation", + name: "Conversation", + description: "Conversation-level details: status, channel, assignee.", + default_time_attribute_id: "conversation_started_at", + attributes: [ + { + id: "conversation_id", + name: "Conversation ID", + }, + ], + }, + ], + }); + }); +}); diff --git a/tests/wire/helpCenters.test.ts b/tests/wire/helpCenters.test.ts new file mode 100644 index 00000000..6376c589 --- /dev/null +++ b/tests/wire/helpCenters.test.ts @@ -0,0 +1,203 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("HelpCentersClient", () => { + test("find (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + id: "93", + workspace_id: "this_is_an_id124_that_should_be_at_least_", + created_at: 1734537325, + updated_at: 1734537325, + identifier: "help-center-1", + website_turned_on: false, + display_name: "Intercom Help Center", + url: "https://help.mycompany.com", + custom_domain: "help.mycompany.com", + }; + server + .mockEndpoint() + .get("/help_center/help_centers/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.helpCenters.find({ + help_center_id: 1, + }); + expect(response).toEqual({ + id: "93", + workspace_id: "this_is_an_id124_that_should_be_at_least_", + created_at: 1734537325, + updated_at: 1734537325, + identifier: "help-center-1", + website_turned_on: false, + display_name: "Intercom Help Center", + url: "https://help.mycompany.com", + custom_domain: "help.mycompany.com", + }); + }); + + test("find (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/help_center/help_centers/1") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.helpCenters.find({ + help_center_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/help_center/help_centers/1") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.helpCenters.find({ + help_center_id: 1, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + id: "id", + workspace_id: "workspace_id", + created_at: 1, + updated_at: 1, + identifier: "identifier", + website_turned_on: true, + display_name: "display_name", + url: "url", + custom_domain: "custom_domain", + }, + { + id: "id", + workspace_id: "workspace_id", + created_at: 1, + updated_at: 1, + identifier: "identifier", + website_turned_on: true, + display_name: "display_name", + url: "url", + custom_domain: "custom_domain", + }, + ], + }; + server + .mockEndpoint({ once: false }) + .get("/help_center/help_centers") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const expected = { + type: "list", + data: [ + { + id: "id", + workspace_id: "workspace_id", + created_at: 1, + updated_at: 1, + identifier: "identifier", + website_turned_on: true, + display_name: "display_name", + url: "url", + custom_domain: "custom_domain", + }, + { + id: "id", + workspace_id: "workspace_id", + created_at: 1, + updated_at: 1, + identifier: "identifier", + website_turned_on: true, + display_name: "display_name", + url: "url", + custom_domain: "custom_domain", + }, + ], + }; + const page = await client.helpCenters.list(); + + expect(expected.data).toEqual(page.data); + expect(page.hasNextPage()).toBe(true); + const nextPage = await page.getNextPage(); + expect(expected.data).toEqual(nextPage.data); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint({ once: false }) + .get("/help_center/help_centers") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.helpCenters.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); +}); diff --git a/tests/wire/helpCenters/collections.test.ts b/tests/wire/helpCenters/collections.test.ts new file mode 100644 index 00000000..c32574f1 --- /dev/null +++ b/tests/wire/helpCenters/collections.test.ts @@ -0,0 +1,2216 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("CollectionsClient", () => { + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { type: "offset_pages", page: 1, next: "next", per_page: 1, total_pages: 1 }, + total_count: 1, + data: [ + { + id: "id", + workspace_id: "workspace_id", + name: "name", + description: "description", + created_at: 1, + updated_at: 1, + url: "url", + icon: "icon", + order: 1, + default_locale: "default_locale", + translated_content: { + type: "group_translated_content", + ar: { type: "group_content", name: "name", description: "description" }, + bg: { type: "group_content", name: "name", description: "description" }, + bs: { type: "group_content", name: "name", description: "description" }, + ca: { type: "group_content", name: "name", description: "description" }, + cs: { type: "group_content", name: "name", description: "description" }, + da: { type: "group_content", name: "name", description: "description" }, + de: { type: "group_content", name: "name", description: "description" }, + el: { type: "group_content", name: "name", description: "description" }, + en: { type: "group_content", name: "name", description: "description" }, + es: { type: "group_content", name: "name", description: "description" }, + et: { type: "group_content", name: "name", description: "description" }, + fi: { type: "group_content", name: "name", description: "description" }, + fr: { type: "group_content", name: "name", description: "description" }, + he: { type: "group_content", name: "name", description: "description" }, + hr: { type: "group_content", name: "name", description: "description" }, + hu: { type: "group_content", name: "name", description: "description" }, + id: { type: "group_content", name: "name", description: "description" }, + it: { type: "group_content", name: "name", description: "description" }, + ja: { type: "group_content", name: "name", description: "description" }, + ko: { type: "group_content", name: "name", description: "description" }, + lt: { type: "group_content", name: "name", description: "description" }, + lv: { type: "group_content", name: "name", description: "description" }, + mn: { type: "group_content", name: "name", description: "description" }, + nb: { type: "group_content", name: "name", description: "description" }, + nl: { type: "group_content", name: "name", description: "description" }, + pl: { type: "group_content", name: "name", description: "description" }, + pt: { type: "group_content", name: "name", description: "description" }, + ro: { type: "group_content", name: "name", description: "description" }, + ru: { type: "group_content", name: "name", description: "description" }, + sl: { type: "group_content", name: "name", description: "description" }, + sr: { type: "group_content", name: "name", description: "description" }, + sv: { type: "group_content", name: "name", description: "description" }, + tr: { type: "group_content", name: "name", description: "description" }, + vi: { type: "group_content", name: "name", description: "description" }, + "pt-BR": { type: "group_content", name: "name", description: "description" }, + "zh-CN": { type: "group_content", name: "name", description: "description" }, + "zh-TW": { type: "group_content", name: "name", description: "description" }, + }, + parent_id: "parent_id", + help_center_id: 1, + }, + { + id: "id", + workspace_id: "workspace_id", + name: "name", + description: "description", + created_at: 1, + updated_at: 1, + url: "url", + icon: "icon", + order: 1, + default_locale: "default_locale", + translated_content: { + type: "group_translated_content", + ar: { type: "group_content", name: "name", description: "description" }, + bg: { type: "group_content", name: "name", description: "description" }, + bs: { type: "group_content", name: "name", description: "description" }, + ca: { type: "group_content", name: "name", description: "description" }, + cs: { type: "group_content", name: "name", description: "description" }, + da: { type: "group_content", name: "name", description: "description" }, + de: { type: "group_content", name: "name", description: "description" }, + el: { type: "group_content", name: "name", description: "description" }, + en: { type: "group_content", name: "name", description: "description" }, + es: { type: "group_content", name: "name", description: "description" }, + et: { type: "group_content", name: "name", description: "description" }, + fi: { type: "group_content", name: "name", description: "description" }, + fr: { type: "group_content", name: "name", description: "description" }, + he: { type: "group_content", name: "name", description: "description" }, + hr: { type: "group_content", name: "name", description: "description" }, + hu: { type: "group_content", name: "name", description: "description" }, + id: { type: "group_content", name: "name", description: "description" }, + it: { type: "group_content", name: "name", description: "description" }, + ja: { type: "group_content", name: "name", description: "description" }, + ko: { type: "group_content", name: "name", description: "description" }, + lt: { type: "group_content", name: "name", description: "description" }, + lv: { type: "group_content", name: "name", description: "description" }, + mn: { type: "group_content", name: "name", description: "description" }, + nb: { type: "group_content", name: "name", description: "description" }, + nl: { type: "group_content", name: "name", description: "description" }, + pl: { type: "group_content", name: "name", description: "description" }, + pt: { type: "group_content", name: "name", description: "description" }, + ro: { type: "group_content", name: "name", description: "description" }, + ru: { type: "group_content", name: "name", description: "description" }, + sl: { type: "group_content", name: "name", description: "description" }, + sr: { type: "group_content", name: "name", description: "description" }, + sv: { type: "group_content", name: "name", description: "description" }, + tr: { type: "group_content", name: "name", description: "description" }, + vi: { type: "group_content", name: "name", description: "description" }, + "pt-BR": { type: "group_content", name: "name", description: "description" }, + "zh-CN": { type: "group_content", name: "name", description: "description" }, + "zh-TW": { type: "group_content", name: "name", description: "description" }, + }, + parent_id: "parent_id", + help_center_id: 1, + }, + ], + }; + server + .mockEndpoint({ once: false }) + .get("/help_center/collections") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const expected = { + type: "list", + pages: { + type: "offset_pages", + page: 1, + next: "next", + per_page: 1, + total_pages: 1, + }, + total_count: 1, + data: [ + { + id: "id", + workspace_id: "workspace_id", + name: "name", + description: "description", + created_at: 1, + updated_at: 1, + url: "url", + icon: "icon", + order: 1, + default_locale: "default_locale", + translated_content: { + type: "group_translated_content", + ar: { + type: "group_content", + name: "name", + description: "description", + }, + bg: { + type: "group_content", + name: "name", + description: "description", + }, + bs: { + type: "group_content", + name: "name", + description: "description", + }, + ca: { + type: "group_content", + name: "name", + description: "description", + }, + cs: { + type: "group_content", + name: "name", + description: "description", + }, + da: { + type: "group_content", + name: "name", + description: "description", + }, + de: { + type: "group_content", + name: "name", + description: "description", + }, + el: { + type: "group_content", + name: "name", + description: "description", + }, + en: { + type: "group_content", + name: "name", + description: "description", + }, + es: { + type: "group_content", + name: "name", + description: "description", + }, + et: { + type: "group_content", + name: "name", + description: "description", + }, + fi: { + type: "group_content", + name: "name", + description: "description", + }, + fr: { + type: "group_content", + name: "name", + description: "description", + }, + he: { + type: "group_content", + name: "name", + description: "description", + }, + hr: { + type: "group_content", + name: "name", + description: "description", + }, + hu: { + type: "group_content", + name: "name", + description: "description", + }, + id: { + type: "group_content", + name: "name", + description: "description", + }, + it: { + type: "group_content", + name: "name", + description: "description", + }, + ja: { + type: "group_content", + name: "name", + description: "description", + }, + ko: { + type: "group_content", + name: "name", + description: "description", + }, + lt: { + type: "group_content", + name: "name", + description: "description", + }, + lv: { + type: "group_content", + name: "name", + description: "description", + }, + mn: { + type: "group_content", + name: "name", + description: "description", + }, + nb: { + type: "group_content", + name: "name", + description: "description", + }, + nl: { + type: "group_content", + name: "name", + description: "description", + }, + pl: { + type: "group_content", + name: "name", + description: "description", + }, + pt: { + type: "group_content", + name: "name", + description: "description", + }, + ro: { + type: "group_content", + name: "name", + description: "description", + }, + ru: { + type: "group_content", + name: "name", + description: "description", + }, + sl: { + type: "group_content", + name: "name", + description: "description", + }, + sr: { + type: "group_content", + name: "name", + description: "description", + }, + sv: { + type: "group_content", + name: "name", + description: "description", + }, + tr: { + type: "group_content", + name: "name", + description: "description", + }, + vi: { + type: "group_content", + name: "name", + description: "description", + }, + "pt-BR": { + type: "group_content", + name: "name", + description: "description", + }, + "zh-CN": { + type: "group_content", + name: "name", + description: "description", + }, + "zh-TW": { + type: "group_content", + name: "name", + description: "description", + }, + }, + parent_id: "parent_id", + help_center_id: 1, + }, + { + id: "id", + workspace_id: "workspace_id", + name: "name", + description: "description", + created_at: 1, + updated_at: 1, + url: "url", + icon: "icon", + order: 1, + default_locale: "default_locale", + translated_content: { + type: "group_translated_content", + ar: { + type: "group_content", + name: "name", + description: "description", + }, + bg: { + type: "group_content", + name: "name", + description: "description", + }, + bs: { + type: "group_content", + name: "name", + description: "description", + }, + ca: { + type: "group_content", + name: "name", + description: "description", + }, + cs: { + type: "group_content", + name: "name", + description: "description", + }, + da: { + type: "group_content", + name: "name", + description: "description", + }, + de: { + type: "group_content", + name: "name", + description: "description", + }, + el: { + type: "group_content", + name: "name", + description: "description", + }, + en: { + type: "group_content", + name: "name", + description: "description", + }, + es: { + type: "group_content", + name: "name", + description: "description", + }, + et: { + type: "group_content", + name: "name", + description: "description", + }, + fi: { + type: "group_content", + name: "name", + description: "description", + }, + fr: { + type: "group_content", + name: "name", + description: "description", + }, + he: { + type: "group_content", + name: "name", + description: "description", + }, + hr: { + type: "group_content", + name: "name", + description: "description", + }, + hu: { + type: "group_content", + name: "name", + description: "description", + }, + id: { + type: "group_content", + name: "name", + description: "description", + }, + it: { + type: "group_content", + name: "name", + description: "description", + }, + ja: { + type: "group_content", + name: "name", + description: "description", + }, + ko: { + type: "group_content", + name: "name", + description: "description", + }, + lt: { + type: "group_content", + name: "name", + description: "description", + }, + lv: { + type: "group_content", + name: "name", + description: "description", + }, + mn: { + type: "group_content", + name: "name", + description: "description", + }, + nb: { + type: "group_content", + name: "name", + description: "description", + }, + nl: { + type: "group_content", + name: "name", + description: "description", + }, + pl: { + type: "group_content", + name: "name", + description: "description", + }, + pt: { + type: "group_content", + name: "name", + description: "description", + }, + ro: { + type: "group_content", + name: "name", + description: "description", + }, + ru: { + type: "group_content", + name: "name", + description: "description", + }, + sl: { + type: "group_content", + name: "name", + description: "description", + }, + sr: { + type: "group_content", + name: "name", + description: "description", + }, + sv: { + type: "group_content", + name: "name", + description: "description", + }, + tr: { + type: "group_content", + name: "name", + description: "description", + }, + vi: { + type: "group_content", + name: "name", + description: "description", + }, + "pt-BR": { + type: "group_content", + name: "name", + description: "description", + }, + "zh-CN": { + type: "group_content", + name: "name", + description: "description", + }, + "zh-TW": { + type: "group_content", + name: "name", + description: "description", + }, + }, + parent_id: "parent_id", + help_center_id: 1, + }, + ], + }; + const page = await client.helpCenters.collections.list(); + + expect(expected.data).toEqual(page.data); + expect(page.hasNextPage()).toBe(true); + const nextPage = await page.getNextPage(); + expect(expected.data).toEqual(nextPage.data); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint({ once: false }) + .get("/help_center/collections") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.helpCenters.collections.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("create (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "Thanks for everything" }; + const rawResponseBody = { + id: "165", + workspace_id: "this_is_an_id100_that_should_be_at_least_", + name: "Thanks for everything", + description: "", + created_at: 1734537312, + updated_at: 1734537312, + url: "http://help-center.test/myapp-100/", + icon: "book-bookmark", + order: 1, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { type: "group_content", name: "Collection name", description: " Collection description" }, + bg: { type: "group_content", name: "Collection name", description: " Collection description" }, + bs: { type: "group_content", name: "Collection name", description: " Collection description" }, + ca: { type: "group_content", name: "Collection name", description: " Collection description" }, + cs: { type: "group_content", name: "Collection name", description: " Collection description" }, + da: { type: "group_content", name: "Collection name", description: " Collection description" }, + de: { type: "group_content", name: "Collection name", description: " Collection description" }, + el: { type: "group_content", name: "Collection name", description: " Collection description" }, + en: { type: "group_content", name: "Collection name", description: " Collection description" }, + es: { type: "group_content", name: "Collection name", description: " Collection description" }, + et: { type: "group_content", name: "Collection name", description: " Collection description" }, + fi: { type: "group_content", name: "Collection name", description: " Collection description" }, + fr: { type: "group_content", name: "Collection name", description: " Collection description" }, + he: { type: "group_content", name: "Collection name", description: " Collection description" }, + hr: { type: "group_content", name: "Collection name", description: " Collection description" }, + hu: { type: "group_content", name: "Collection name", description: " Collection description" }, + id: { type: "group_content", name: "Collection name", description: " Collection description" }, + it: { type: "group_content", name: "Collection name", description: " Collection description" }, + ja: { type: "group_content", name: "Collection name", description: " Collection description" }, + ko: { type: "group_content", name: "Collection name", description: " Collection description" }, + lt: { type: "group_content", name: "Collection name", description: " Collection description" }, + lv: { type: "group_content", name: "Collection name", description: " Collection description" }, + mn: { type: "group_content", name: "Collection name", description: " Collection description" }, + nb: { type: "group_content", name: "Collection name", description: " Collection description" }, + nl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pt: { type: "group_content", name: "Collection name", description: " Collection description" }, + ro: { type: "group_content", name: "Collection name", description: " Collection description" }, + ru: { type: "group_content", name: "Collection name", description: " Collection description" }, + sl: { type: "group_content", name: "Collection name", description: " Collection description" }, + sr: { type: "group_content", name: "Collection name", description: " Collection description" }, + sv: { type: "group_content", name: "Collection name", description: " Collection description" }, + tr: { type: "group_content", name: "Collection name", description: " Collection description" }, + vi: { type: "group_content", name: "Collection name", description: " Collection description" }, + "pt-BR": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-CN": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-TW": { type: "group_content", name: "Collection name", description: " Collection description" }, + }, + parent_id: "6871118", + help_center_id: 81, + }; + server + .mockEndpoint() + .post("/help_center/collections") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.helpCenters.collections.create({ + name: "Thanks for everything", + }); + expect(response).toEqual({ + id: "165", + workspace_id: "this_is_an_id100_that_should_be_at_least_", + name: "Thanks for everything", + description: "", + created_at: 1734537312, + updated_at: 1734537312, + url: "http://help-center.test/myapp-100/", + icon: "book-bookmark", + order: 1, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bg: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ca: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + cs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + da: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + de: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + el: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + en: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + es: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + et: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + he: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hu: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + id: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + it: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ja: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ko: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + mn: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nb: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ro: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ru: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + tr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + vi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "pt-BR": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-CN": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-TW": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + }, + parent_id: "6871118", + help_center_id: 81, + }); + }); + + test("create (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "collection 51", description: "Missing required parameter" }; + const rawResponseBody = { + id: "165", + workspace_id: "this_is_an_id100_that_should_be_at_least_", + name: "Thanks for everything", + description: "", + created_at: 1734537312, + updated_at: 1734537312, + url: "http://help-center.test/myapp-100/", + icon: "book-bookmark", + order: 1, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { type: "group_content", name: "Collection name", description: " Collection description" }, + bg: { type: "group_content", name: "Collection name", description: " Collection description" }, + bs: { type: "group_content", name: "Collection name", description: " Collection description" }, + ca: { type: "group_content", name: "Collection name", description: " Collection description" }, + cs: { type: "group_content", name: "Collection name", description: " Collection description" }, + da: { type: "group_content", name: "Collection name", description: " Collection description" }, + de: { type: "group_content", name: "Collection name", description: " Collection description" }, + el: { type: "group_content", name: "Collection name", description: " Collection description" }, + en: { type: "group_content", name: "Collection name", description: " Collection description" }, + es: { type: "group_content", name: "Collection name", description: " Collection description" }, + et: { type: "group_content", name: "Collection name", description: " Collection description" }, + fi: { type: "group_content", name: "Collection name", description: " Collection description" }, + fr: { type: "group_content", name: "Collection name", description: " Collection description" }, + he: { type: "group_content", name: "Collection name", description: " Collection description" }, + hr: { type: "group_content", name: "Collection name", description: " Collection description" }, + hu: { type: "group_content", name: "Collection name", description: " Collection description" }, + id: { type: "group_content", name: "Collection name", description: " Collection description" }, + it: { type: "group_content", name: "Collection name", description: " Collection description" }, + ja: { type: "group_content", name: "Collection name", description: " Collection description" }, + ko: { type: "group_content", name: "Collection name", description: " Collection description" }, + lt: { type: "group_content", name: "Collection name", description: " Collection description" }, + lv: { type: "group_content", name: "Collection name", description: " Collection description" }, + mn: { type: "group_content", name: "Collection name", description: " Collection description" }, + nb: { type: "group_content", name: "Collection name", description: " Collection description" }, + nl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pt: { type: "group_content", name: "Collection name", description: " Collection description" }, + ro: { type: "group_content", name: "Collection name", description: " Collection description" }, + ru: { type: "group_content", name: "Collection name", description: " Collection description" }, + sl: { type: "group_content", name: "Collection name", description: " Collection description" }, + sr: { type: "group_content", name: "Collection name", description: " Collection description" }, + sv: { type: "group_content", name: "Collection name", description: " Collection description" }, + tr: { type: "group_content", name: "Collection name", description: " Collection description" }, + vi: { type: "group_content", name: "Collection name", description: " Collection description" }, + "pt-BR": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-CN": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-TW": { type: "group_content", name: "Collection name", description: " Collection description" }, + }, + parent_id: "6871118", + help_center_id: 81, + }; + server + .mockEndpoint() + .post("/help_center/collections") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.helpCenters.collections.create({ + name: "collection 51", + description: "Missing required parameter", + }); + expect(response).toEqual({ + id: "165", + workspace_id: "this_is_an_id100_that_should_be_at_least_", + name: "Thanks for everything", + description: "", + created_at: 1734537312, + updated_at: 1734537312, + url: "http://help-center.test/myapp-100/", + icon: "book-bookmark", + order: 1, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bg: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ca: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + cs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + da: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + de: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + el: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + en: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + es: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + et: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + he: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hu: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + id: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + it: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ja: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ko: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + mn: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nb: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ro: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ru: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + tr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + vi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "pt-BR": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-CN": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-TW": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + }, + parent_id: "6871118", + help_center_id: 81, + }); + }); + + test("create (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "name" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/help_center/collections") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.helpCenters.collections.create({ + name: "name", + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("create (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "name" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/help_center/collections") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.helpCenters.collections.create({ + name: "name", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + id: "170", + workspace_id: "this_is_an_id106_that_should_be_at_least_", + name: "English collection title", + description: "english collection description", + created_at: 1734537315, + updated_at: 1734537315, + url: "http://help-center.test/myapp-106/collection-22", + icon: "bookmark", + order: 22, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { type: "group_content", name: "Collection name", description: " Collection description" }, + bg: { type: "group_content", name: "Collection name", description: " Collection description" }, + bs: { type: "group_content", name: "Collection name", description: " Collection description" }, + ca: { type: "group_content", name: "Collection name", description: " Collection description" }, + cs: { type: "group_content", name: "Collection name", description: " Collection description" }, + da: { type: "group_content", name: "Collection name", description: " Collection description" }, + de: { type: "group_content", name: "Collection name", description: " Collection description" }, + el: { type: "group_content", name: "Collection name", description: " Collection description" }, + en: { type: "group_content", name: "Collection name", description: " Collection description" }, + es: { type: "group_content", name: "Collection name", description: " Collection description" }, + et: { type: "group_content", name: "Collection name", description: " Collection description" }, + fi: { type: "group_content", name: "Collection name", description: " Collection description" }, + fr: { type: "group_content", name: "Collection name", description: " Collection description" }, + he: { type: "group_content", name: "Collection name", description: " Collection description" }, + hr: { type: "group_content", name: "Collection name", description: " Collection description" }, + hu: { type: "group_content", name: "Collection name", description: " Collection description" }, + id: { type: "group_content", name: "Collection name", description: " Collection description" }, + it: { type: "group_content", name: "Collection name", description: " Collection description" }, + ja: { type: "group_content", name: "Collection name", description: " Collection description" }, + ko: { type: "group_content", name: "Collection name", description: " Collection description" }, + lt: { type: "group_content", name: "Collection name", description: " Collection description" }, + lv: { type: "group_content", name: "Collection name", description: " Collection description" }, + mn: { type: "group_content", name: "Collection name", description: " Collection description" }, + nb: { type: "group_content", name: "Collection name", description: " Collection description" }, + nl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pt: { type: "group_content", name: "Collection name", description: " Collection description" }, + ro: { type: "group_content", name: "Collection name", description: " Collection description" }, + ru: { type: "group_content", name: "Collection name", description: " Collection description" }, + sl: { type: "group_content", name: "Collection name", description: " Collection description" }, + sr: { type: "group_content", name: "Collection name", description: " Collection description" }, + sv: { type: "group_content", name: "Collection name", description: " Collection description" }, + tr: { type: "group_content", name: "Collection name", description: " Collection description" }, + vi: { type: "group_content", name: "Collection name", description: " Collection description" }, + "pt-BR": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-CN": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-TW": { type: "group_content", name: "Collection name", description: " Collection description" }, + }, + parent_id: "6871118", + help_center_id: 84, + }; + server + .mockEndpoint() + .get("/help_center/collections/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.helpCenters.collections.find({ + collection_id: 1, + }); + expect(response).toEqual({ + id: "170", + workspace_id: "this_is_an_id106_that_should_be_at_least_", + name: "English collection title", + description: "english collection description", + created_at: 1734537315, + updated_at: 1734537315, + url: "http://help-center.test/myapp-106/collection-22", + icon: "bookmark", + order: 22, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bg: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ca: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + cs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + da: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + de: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + el: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + en: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + es: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + et: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + he: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hu: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + id: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + it: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ja: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ko: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + mn: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nb: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ro: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ru: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + tr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + vi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "pt-BR": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-CN": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-TW": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + }, + parent_id: "6871118", + help_center_id: 84, + }); + }); + + test("find (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/help_center/collections/1") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.helpCenters.collections.find({ + collection_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/help_center/collections/1") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.helpCenters.collections.find({ + collection_id: 1, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("update (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "Update collection name" }; + const rawResponseBody = { + id: "176", + workspace_id: "this_is_an_id112_that_should_be_at_least_", + name: "Update collection name", + description: "english collection description", + created_at: 1734537318, + updated_at: 1734537319, + url: "http://help-center.test/myapp-112/collection-25", + icon: "folder", + order: 25, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { type: "group_content", name: "Collection name", description: " Collection description" }, + bg: { type: "group_content", name: "Collection name", description: " Collection description" }, + bs: { type: "group_content", name: "Collection name", description: " Collection description" }, + ca: { type: "group_content", name: "Collection name", description: " Collection description" }, + cs: { type: "group_content", name: "Collection name", description: " Collection description" }, + da: { type: "group_content", name: "Collection name", description: " Collection description" }, + de: { type: "group_content", name: "Collection name", description: " Collection description" }, + el: { type: "group_content", name: "Collection name", description: " Collection description" }, + en: { type: "group_content", name: "Collection name", description: " Collection description" }, + es: { type: "group_content", name: "Collection name", description: " Collection description" }, + et: { type: "group_content", name: "Collection name", description: " Collection description" }, + fi: { type: "group_content", name: "Collection name", description: " Collection description" }, + fr: { type: "group_content", name: "Collection name", description: " Collection description" }, + he: { type: "group_content", name: "Collection name", description: " Collection description" }, + hr: { type: "group_content", name: "Collection name", description: " Collection description" }, + hu: { type: "group_content", name: "Collection name", description: " Collection description" }, + id: { type: "group_content", name: "Collection name", description: " Collection description" }, + it: { type: "group_content", name: "Collection name", description: " Collection description" }, + ja: { type: "group_content", name: "Collection name", description: " Collection description" }, + ko: { type: "group_content", name: "Collection name", description: " Collection description" }, + lt: { type: "group_content", name: "Collection name", description: " Collection description" }, + lv: { type: "group_content", name: "Collection name", description: " Collection description" }, + mn: { type: "group_content", name: "Collection name", description: " Collection description" }, + nb: { type: "group_content", name: "Collection name", description: " Collection description" }, + nl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pt: { type: "group_content", name: "Collection name", description: " Collection description" }, + ro: { type: "group_content", name: "Collection name", description: " Collection description" }, + ru: { type: "group_content", name: "Collection name", description: " Collection description" }, + sl: { type: "group_content", name: "Collection name", description: " Collection description" }, + sr: { type: "group_content", name: "Collection name", description: " Collection description" }, + sv: { type: "group_content", name: "Collection name", description: " Collection description" }, + tr: { type: "group_content", name: "Collection name", description: " Collection description" }, + vi: { type: "group_content", name: "Collection name", description: " Collection description" }, + "pt-BR": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-CN": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-TW": { type: "group_content", name: "Collection name", description: " Collection description" }, + }, + parent_id: "6871118", + help_center_id: 87, + }; + server + .mockEndpoint() + .put("/help_center/collections/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.helpCenters.collections.update({ + collection_id: 1, + name: "Update collection name", + }); + expect(response).toEqual({ + id: "176", + workspace_id: "this_is_an_id112_that_should_be_at_least_", + name: "Update collection name", + description: "english collection description", + created_at: 1734537318, + updated_at: 1734537319, + url: "http://help-center.test/myapp-112/collection-25", + icon: "folder", + order: 25, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bg: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ca: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + cs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + da: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + de: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + el: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + en: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + es: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + et: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + he: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hu: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + id: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + it: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ja: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ko: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + mn: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nb: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ro: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ru: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + tr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + vi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "pt-BR": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-CN": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-TW": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + }, + parent_id: "6871118", + help_center_id: 87, + }); + }); + + test("update (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "Update collection name" }; + const rawResponseBody = { + id: "176", + workspace_id: "this_is_an_id112_that_should_be_at_least_", + name: "Update collection name", + description: "english collection description", + created_at: 1734537318, + updated_at: 1734537319, + url: "http://help-center.test/myapp-112/collection-25", + icon: "folder", + order: 25, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { type: "group_content", name: "Collection name", description: " Collection description" }, + bg: { type: "group_content", name: "Collection name", description: " Collection description" }, + bs: { type: "group_content", name: "Collection name", description: " Collection description" }, + ca: { type: "group_content", name: "Collection name", description: " Collection description" }, + cs: { type: "group_content", name: "Collection name", description: " Collection description" }, + da: { type: "group_content", name: "Collection name", description: " Collection description" }, + de: { type: "group_content", name: "Collection name", description: " Collection description" }, + el: { type: "group_content", name: "Collection name", description: " Collection description" }, + en: { type: "group_content", name: "Collection name", description: " Collection description" }, + es: { type: "group_content", name: "Collection name", description: " Collection description" }, + et: { type: "group_content", name: "Collection name", description: " Collection description" }, + fi: { type: "group_content", name: "Collection name", description: " Collection description" }, + fr: { type: "group_content", name: "Collection name", description: " Collection description" }, + he: { type: "group_content", name: "Collection name", description: " Collection description" }, + hr: { type: "group_content", name: "Collection name", description: " Collection description" }, + hu: { type: "group_content", name: "Collection name", description: " Collection description" }, + id: { type: "group_content", name: "Collection name", description: " Collection description" }, + it: { type: "group_content", name: "Collection name", description: " Collection description" }, + ja: { type: "group_content", name: "Collection name", description: " Collection description" }, + ko: { type: "group_content", name: "Collection name", description: " Collection description" }, + lt: { type: "group_content", name: "Collection name", description: " Collection description" }, + lv: { type: "group_content", name: "Collection name", description: " Collection description" }, + mn: { type: "group_content", name: "Collection name", description: " Collection description" }, + nb: { type: "group_content", name: "Collection name", description: " Collection description" }, + nl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pt: { type: "group_content", name: "Collection name", description: " Collection description" }, + ro: { type: "group_content", name: "Collection name", description: " Collection description" }, + ru: { type: "group_content", name: "Collection name", description: " Collection description" }, + sl: { type: "group_content", name: "Collection name", description: " Collection description" }, + sr: { type: "group_content", name: "Collection name", description: " Collection description" }, + sv: { type: "group_content", name: "Collection name", description: " Collection description" }, + tr: { type: "group_content", name: "Collection name", description: " Collection description" }, + vi: { type: "group_content", name: "Collection name", description: " Collection description" }, + "pt-BR": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-CN": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-TW": { type: "group_content", name: "Collection name", description: " Collection description" }, + }, + parent_id: "6871118", + help_center_id: 87, + }; + server + .mockEndpoint() + .put("/help_center/collections/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.helpCenters.collections.update({ + collection_id: 1, + name: "Update collection name", + }); + expect(response).toEqual({ + id: "176", + workspace_id: "this_is_an_id112_that_should_be_at_least_", + name: "Update collection name", + description: "english collection description", + created_at: 1734537318, + updated_at: 1734537319, + url: "http://help-center.test/myapp-112/collection-25", + icon: "folder", + order: 25, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bg: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ca: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + cs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + da: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + de: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + el: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + en: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + es: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + et: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + he: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hu: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + id: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + it: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ja: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ko: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + mn: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nb: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ro: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ru: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + tr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + vi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "pt-BR": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-CN": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-TW": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + }, + parent_id: "6871118", + help_center_id: 87, + }); + }); + + test("update (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/help_center/collections/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.helpCenters.collections.update({ + collection_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("update (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/help_center/collections/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.helpCenters.collections.update({ + collection_id: 1, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("delete (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { id: "182", object: "collection", deleted: true }; + server + .mockEndpoint() + .delete("/help_center/collections/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.helpCenters.collections.delete({ + collection_id: 1, + }); + expect(response).toEqual({ + id: "182", + object: "collection", + deleted: true, + }); + }); + + test("delete (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/help_center/collections/1") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.helpCenters.collections.delete({ + collection_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("delete (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/help_center/collections/1") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.helpCenters.collections.delete({ + collection_id: 1, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); +}); diff --git a/tests/wire/internalArticles.test.ts b/tests/wire/internalArticles.test.ts new file mode 100644 index 00000000..3ef231a2 --- /dev/null +++ b/tests/wire/internalArticles.test.ts @@ -0,0 +1,655 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("InternalArticlesClient", () => { + test("listInternalArticles (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 25, + total_pages: 1, + }, + total_count: 1, + data: [ + { + type: "internal_article", + id: "39", + title: "Thanks for everything", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }, + ], + }; + server.mockEndpoint().get("/internal_articles").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.internalArticles.listInternalArticles(); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 25, + total_pages: 1, + }, + total_count: 1, + data: [ + { + type: "internal_article", + id: "39", + title: "Thanks for everything", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }, + ], + }); + }); + + test("listInternalArticles (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/internal_articles").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.internalArticles.listInternalArticles(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("createInternalArticle (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Thanks for everything", + body: "Body of the Article", + author_id: 991266252, + owner_id: 991266252, + }; + const rawResponseBody = { + type: "internal_article", + id: "42", + title: "Thanks for everything", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }; + server + .mockEndpoint() + .post("/internal_articles") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.internalArticles.createInternalArticle({ + title: "Thanks for everything", + body: "Body of the Article", + author_id: 991266252, + owner_id: 991266252, + }); + expect(response).toEqual({ + type: "internal_article", + id: "42", + title: "Thanks for everything", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }); + }); + + test("createInternalArticle (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Thanks for everything", + body: "Body of the Internal Article", + author_id: 1295, + owner_id: 1295, + }; + const rawResponseBody = { + type: "internal_article", + id: "42", + title: "Thanks for everything", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }; + server + .mockEndpoint() + .post("/internal_articles") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.internalArticles.createInternalArticle({ + title: "Thanks for everything", + body: "Body of the Internal Article", + author_id: 1295, + owner_id: 1295, + }); + expect(response).toEqual({ + type: "internal_article", + id: "42", + title: "Thanks for everything", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }); + }); + + test("createInternalArticle (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/internal_articles") + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.internalArticles.createInternalArticle(undefined); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("createInternalArticle (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/internal_articles") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.internalArticles.createInternalArticle(undefined); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("retrieveInternalArticle (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "internal_article", + id: "45", + title: "title", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }; + server + .mockEndpoint() + .get("/internal_articles/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.internalArticles.retrieveInternalArticle({ + internal_article_id: 1, + }); + expect(response).toEqual({ + type: "internal_article", + id: "45", + title: "title", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }); + }); + + test("retrieveInternalArticle (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/internal_articles/1") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.internalArticles.retrieveInternalArticle({ + internal_article_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("retrieveInternalArticle (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/internal_articles/1") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.internalArticles.retrieveInternalArticle({ + internal_article_id: 1, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("updateInternalArticle (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "Christmas is here!", body: "

New gifts in store for the jolly season

" }; + const rawResponseBody = { + type: "internal_article", + id: "48", + title: "title", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }; + server + .mockEndpoint() + .put("/internal_articles/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.internalArticles.updateInternalArticle({ + internal_article_id: 1, + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + }); + expect(response).toEqual({ + type: "internal_article", + id: "48", + title: "title", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }); + }); + + test("updateInternalArticle (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "Christmas is here!", body: "

New gifts in store for the jolly season

" }; + const rawResponseBody = { + type: "internal_article", + id: "48", + title: "title", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }; + server + .mockEndpoint() + .put("/internal_articles/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.internalArticles.updateInternalArticle({ + internal_article_id: 1, + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + }); + expect(response).toEqual({ + type: "internal_article", + id: "48", + title: "title", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }); + }); + + test("updateInternalArticle (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/internal_articles/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.internalArticles.updateInternalArticle({ + internal_article_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("updateInternalArticle (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/internal_articles/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.internalArticles.updateInternalArticle({ + internal_article_id: 1, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("deleteInternalArticle (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { id: "51", object: "internal_article", deleted: true }; + server + .mockEndpoint() + .delete("/internal_articles/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.internalArticles.deleteInternalArticle({ + internal_article_id: 1, + }); + expect(response).toEqual({ + id: "51", + object: "internal_article", + deleted: true, + }); + }); + + test("deleteInternalArticle (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/internal_articles/1") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.internalArticles.deleteInternalArticle({ + internal_article_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("deleteInternalArticle (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/internal_articles/1") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.internalArticles.deleteInternalArticle({ + internal_article_id: 1, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("searchInternalArticles (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + total_count: 1, + data: { + internal_articles: [ + { + id: "55", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }, + ], + }, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 10, + total_pages: 1, + }, + }; + server + .mockEndpoint() + .get("/internal_articles/search") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.internalArticles.searchInternalArticles({ + folder_id: "folder_id", + }); + expect(response).toEqual({ + type: "list", + total_count: 1, + data: { + internal_articles: [ + { + id: "55", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }, + ], + }, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 10, + total_pages: 1, + }, + }); + }); + + test("searchInternalArticles (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/internal_articles/search") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.internalArticles.searchInternalArticles(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); +}); diff --git a/tests/wire/jobs.test.ts b/tests/wire/jobs.test.ts new file mode 100644 index 00000000..ed487a93 --- /dev/null +++ b/tests/wire/jobs.test.ts @@ -0,0 +1,97 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("JobsClient", () => { + test("status (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "job", + id: "2", + url: "https://api.intercom.io/jobs/status/20", + status: "success", + resource_type: "ticket", + resource_id: "20", + resource_url: "https://api.intercom.io/tickets/20", + }; + server + .mockEndpoint() + .get("/jobs/status/job_id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.jobs.status({ + job_id: "job_id", + }); + expect(response).toEqual({ + type: "job", + id: "2", + url: "https://api.intercom.io/jobs/status/20", + status: "success", + resource_type: "ticket", + resource_id: "20", + resource_url: "https://api.intercom.io/tickets/20", + }); + }); + + test("status (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/jobs/status/job_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.jobs.status({ + job_id: "job_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("status (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/jobs/status/job_id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.jobs.status({ + job_id: "job_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); +}); diff --git a/tests/wire/messages.test.ts b/tests/wire/messages.test.ts new file mode 100644 index 00000000..4c5270c9 --- /dev/null +++ b/tests/wire/messages.test.ts @@ -0,0 +1,618 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("MessagesClient", () => { + test("create (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "email", + subject: "Thanks for everything", + body: "Hello there", + template: "plain", + from: { type: "admin", id: 394051 }, + to: { type: "user", id: "536e564f316c83104c000020" }, + }; + const rawResponseBody = { + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.messages.create({ + message_type: "email", + subject: "Thanks for everything", + body: "Hello there", + template: "plain", + from: { + type: "admin", + id: 394051, + }, + to: { + type: "user", + id: "536e564f316c83104c000020", + }, + }); + expect(response).toEqual({ + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }); + }); + + test("create (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "email", + subject: "Thanks for everything", + body: "Hello there", + template: "plain", + from: { type: "admin", id: 394051 }, + to: { type: "user", id: "536e564f316c83104c000020" }, + }; + const rawResponseBody = { + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.messages.create({ + message_type: "email", + subject: "Thanks for everything", + body: "Hello there", + template: "plain", + from: { + type: "admin", + id: 394051, + }, + to: { + type: "user", + id: "536e564f316c83104c000020", + }, + }); + expect(response).toEqual({ + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }); + }); + + test("create (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "email", + subject: "Thanks for everything", + body: "Hello there", + template: "plain", + from: { type: "admin", id: 394051 }, + to: { type: "user", id: "536e564f316c83104c000020" }, + }; + const rawResponseBody = { + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.messages.create({ + message_type: "email", + subject: "Thanks for everything", + body: "Hello there", + template: "plain", + from: { + type: "admin", + id: 394051, + }, + to: { + type: "user", + id: "536e564f316c83104c000020", + }, + }); + expect(response).toEqual({ + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }); + }); + + test("create (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "inapp", + subject: "heyy", + body: "Hello there", + template: "plain", + from: { type: "admin", id: 394051 }, + to: { type: "user", id: "6762f23b1bb69f9f2193bc1a" }, + created_at: 1590000000, + create_conversation_without_contact_reply: true, + }; + const rawResponseBody = { + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.messages.create({ + message_type: "inapp", + subject: "heyy", + body: "Hello there", + template: "plain", + from: { + type: "admin", + id: 394051, + }, + to: { + type: "user", + id: "6762f23b1bb69f9f2193bc1a", + }, + created_at: 1590000000, + create_conversation_without_contact_reply: true, + }); + expect(response).toEqual({ + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }); + }); + + test("create (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "email", + subject: "Thanks for everything", + body: "hey there", + template: "plain", + from: { type: "admin", id: 394051 }, + to: { type: "user", id: "536e564f316c83104c000020" }, + created_at: 1590000000, + create_conversation_without_contact_reply: true, + }; + const rawResponseBody = { + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.messages.create({ + message_type: "email", + subject: "Thanks for everything", + body: "hey there", + template: "plain", + from: { + type: "admin", + id: 394051, + }, + to: { + type: "user", + id: "536e564f316c83104c000020", + }, + created_at: 1590000000, + create_conversation_without_contact_reply: true, + }); + expect(response).toEqual({ + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }); + }); + + test("create (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "email", + subject: "heyy", + body: "Hello there", + template: "plain", + from: { type: "admin", id: 394051 }, + to: { type: "user", id: "6762f23d1bb69f9f2193bc1c" }, + created_at: 1590000000, + create_conversation_without_contact_reply: true, + }; + const rawResponseBody = { + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.messages.create({ + message_type: "email", + subject: "heyy", + body: "Hello there", + template: "plain", + from: { + type: "admin", + id: 394051, + }, + to: { + type: "user", + id: "6762f23d1bb69f9f2193bc1c", + }, + created_at: 1590000000, + create_conversation_without_contact_reply: true, + }); + expect(response).toEqual({ + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }); + }); + + test("create (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "email", + subject: "Thanks for everything", + body: "Hello there", + template: "plain", + from: { type: "admin", id: 394051 }, + to: { type: "user", id: "536e564f316c83104c000020" }, + }; + const rawResponseBody = { + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.messages.create({ + message_type: "email", + subject: "Thanks for everything", + body: "Hello there", + template: "plain", + from: { + type: "admin", + id: 394051, + }, + to: { + type: "user", + id: "536e564f316c83104c000020", + }, + }); + expect(response).toEqual({ + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }); + }); + + test("create (8)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "email", + subject: "Thanks for everything", + body: "Hello there", + template: "plain", + from: { type: "admin", id: 394051 }, + to: { type: "user", id: "536e564f316c83104c000020" }, + }; + const rawResponseBody = { + type: "user_message", + id: "403918397", + created_at: 1734537783, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "614", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.messages.create({ + message_type: "email", + subject: "Thanks for everything", + body: "Hello there", + template: "plain", + from: { + type: "admin", + id: 394051, + }, + to: { + type: "user", + id: "536e564f316c83104c000020", + }, + }); + expect(response).toEqual({ + type: "user_message", + id: "403918397", + created_at: 1734537783, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "614", + }); + }); + + test("create (9)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "email", + subject: "Thanks for everything", + body: "Hello there", + template: "plain", + from: { type: "admin", id: 394051 }, + to: { type: "user", id: "536e564f316c83104c000020" }, + }; + const rawResponseBody = { + type: "admin_message", + id: "19", + created_at: 1734537786, + subject: "heyy", + body: "heyy", + message_type: "inapp", + conversation_id: "64619700005570", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.messages.create({ + message_type: "email", + subject: "Thanks for everything", + body: "Hello there", + template: "plain", + from: { + type: "admin", + id: 394051, + }, + to: { + type: "user", + id: "536e564f316c83104c000020", + }, + }); + expect(response).toEqual({ + type: "admin_message", + id: "19", + created_at: 1734537786, + subject: "heyy", + body: "heyy", + message_type: "inapp", + conversation_id: "64619700005570", + }); + }); + + test("create (10)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().post("/messages").respondWith().statusCode(400).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.messages.create(undefined); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("create (11)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().post("/messages").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.messages.create(undefined); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("create (12)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().post("/messages").respondWith().statusCode(403).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.messages.create(undefined); + }).rejects.toThrow(Intercom.ForbiddenError); + }); + + test("create (13)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().post("/messages").respondWith().statusCode(422).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.messages.create(undefined); + }).rejects.toThrow(Intercom.UnprocessableEntityError); + }); +}); diff --git a/tests/wire/news/feeds.test.ts b/tests/wire/news/feeds.test.ts new file mode 100644 index 00000000..67e2d4e5 --- /dev/null +++ b/tests/wire/news/feeds.test.ts @@ -0,0 +1,257 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("FeedsClient", () => { + test("listItems (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 20, + total_pages: 0, + }, + total_count: 0, + data: [ + { + type: "news-item", + id: "141", + workspace_id: "t74hdn32", + title: "New feature: News Items", + body: "We are excited to announce the launch of News Items, a new content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers.", + sender_id: 123, + state: "draft", + newsfeed_assignments: [{ newsfeed_id: 198313, published_at: 1674917488 }], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["👍"], + deliver_silently: true, + created_at: 1610589632, + updated_at: 1610589632, + }, + ], + }; + server + .mockEndpoint() + .get("/news/newsfeeds/123/items") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.news.feeds.listItems({ + newsfeed_id: "123", + }); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 20, + total_pages: 0, + }, + total_count: 0, + data: [ + { + type: "news-item", + id: "141", + workspace_id: "t74hdn32", + title: "New feature: News Items", + body: "We are excited to announce the launch of News Items, a new content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers.", + sender_id: 123, + state: "draft", + newsfeed_assignments: [ + { + newsfeed_id: 198313, + published_at: 1674917488, + }, + ], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["\uD83D\uDC4D"], + deliver_silently: true, + created_at: 1610589632, + updated_at: 1610589632, + }, + ], + }); + }); + + test("listItems (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/news/newsfeeds/newsfeed_id/items") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.news.feeds.listItems({ + newsfeed_id: "newsfeed_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 10, + total_pages: 1, + }, + total_count: 2, + data: [ + { type: "newsfeed", id: "12312", name: "My Newsfeed", created_at: 1674917488, updated_at: 1674917488 }, + { type: "newsfeed", id: "12312", name: "My Newsfeed", created_at: 1674917488, updated_at: 1674917488 }, + ], + }; + server.mockEndpoint().get("/news/newsfeeds").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.news.feeds.list(); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 10, + total_pages: 1, + }, + total_count: 2, + data: [ + { + id: "12312", + type: "newsfeed", + name: "My Newsfeed", + created_at: 1674917488, + updated_at: 1674917488, + }, + { + id: "12312", + type: "newsfeed", + name: "My Newsfeed", + created_at: 1674917488, + updated_at: 1674917488, + }, + ], + }); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/news/newsfeeds").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.news.feeds.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + id: "72", + type: "newsfeed", + name: "Visitor Feed", + created_at: 1734537815, + updated_at: 1734537815, + }; + server + .mockEndpoint() + .get("/news/newsfeeds/123") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.news.feeds.find({ + newsfeed_id: "123", + }); + expect(response).toEqual({ + id: "72", + type: "newsfeed", + name: "Visitor Feed", + created_at: 1734537815, + updated_at: 1734537815, + }); + }); + + test("find (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/news/newsfeeds/newsfeed_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.news.feeds.find({ + newsfeed_id: "newsfeed_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); +}); diff --git a/tests/wire/news/items.test.ts b/tests/wire/news/items.test.ts new file mode 100644 index 00000000..e95bc74e --- /dev/null +++ b/tests/wire/news/items.test.ts @@ -0,0 +1,620 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("ItemsClient", () => { + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 10, + total_pages: 1, + }, + total_count: 2, + data: [ + { + type: "news-item", + id: "141", + workspace_id: "t74hdn32", + title: "New feature: News Items", + body: "We are excited to announce the launch of News Items, a new content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers.", + sender_id: 123, + state: "draft", + newsfeed_assignments: [{ newsfeed_id: 198313, published_at: 1674917488 }], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["👍"], + deliver_silently: true, + created_at: 1610589632, + updated_at: 1610589632, + }, + { + type: "news-item", + id: "141", + workspace_id: "t74hdn32", + title: "New feature: News Items", + body: "We are excited to announce the launch of News Items, a new content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers.", + sender_id: 123, + state: "draft", + newsfeed_assignments: [{ newsfeed_id: 198313, published_at: 1674917488 }], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["👍"], + deliver_silently: true, + created_at: 1610589632, + updated_at: 1610589632, + }, + ], + }; + server.mockEndpoint().get("/news/news_items").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.news.items.list(); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 10, + total_pages: 1, + }, + total_count: 2, + data: [ + { + type: "news-item", + id: "141", + workspace_id: "t74hdn32", + title: "New feature: News Items", + body: "We are excited to announce the launch of News Items, a new content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers.", + sender_id: 123, + state: "draft", + newsfeed_assignments: [ + { + newsfeed_id: 198313, + published_at: 1674917488, + }, + ], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["\uD83D\uDC4D"], + deliver_silently: true, + created_at: 1610589632, + updated_at: 1610589632, + }, + { + type: "news-item", + id: "141", + workspace_id: "t74hdn32", + title: "New feature: News Items", + body: "We are excited to announce the launch of News Items, a new content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers.", + sender_id: 123, + state: "draft", + newsfeed_assignments: [ + { + newsfeed_id: 198313, + published_at: 1674917488, + }, + ], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["\uD83D\uDC4D"], + deliver_silently: true, + created_at: 1610589632, + updated_at: 1610589632, + }, + ], + }); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/news/news_items").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.news.items.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("create (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Halloween is here!", + body: "

New costumes in store for this spooky season

", + sender_id: 991267834, + state: "live", + deliver_silently: true, + labels: ["Product", "Update", "New"], + reactions: ["😆", "😅"], + newsfeed_assignments: [{ newsfeed_id: 53, published_at: 1664638214 }], + }; + const rawResponseBody = { + type: "news-item", + id: "33", + workspace_id: "this_is_an_id534_that_should_be_at_least_", + title: "Halloween is here!", + body: "

New costumes in store for this spooky season

", + sender_id: 991267834, + state: "live", + newsfeed_assignments: [{ newsfeed_id: 53, published_at: 1664638214 }], + labels: ["New", "Product", "Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["😆", "😅"], + deliver_silently: true, + created_at: 1734537797, + updated_at: 1734537797, + }; + server + .mockEndpoint() + .post("/news/news_items") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.news.items.create({ + title: "Halloween is here!", + body: "

New costumes in store for this spooky season

", + sender_id: 991267834, + state: "live", + deliver_silently: true, + labels: ["Product", "Update", "New"], + reactions: ["\uD83D\uDE06", "\uD83D\uDE05"], + newsfeed_assignments: [ + { + newsfeed_id: 53, + published_at: 1664638214, + }, + ], + }); + expect(response).toEqual({ + type: "news-item", + id: "33", + workspace_id: "this_is_an_id534_that_should_be_at_least_", + title: "Halloween is here!", + body: "

New costumes in store for this spooky season

", + sender_id: 991267834, + state: "live", + newsfeed_assignments: [ + { + newsfeed_id: 53, + published_at: 1664638214, + }, + ], + labels: ["New", "Product", "Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["\uD83D\uDE06", "\uD83D\uDE05"], + deliver_silently: true, + created_at: 1734537797, + updated_at: 1734537797, + }); + }); + + test("create (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "title", sender_id: 1 }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/news/news_items") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.news.items.create({ + title: "title", + sender_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "news-item", + id: "34", + workspace_id: "this_is_an_id538_that_should_be_at_least_", + title: "We have news", + body: "

Hello there,

", + sender_id: 991267837, + state: "live", + newsfeed_assignments: [{ newsfeed_id: 55, published_at: 1734537800 }], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["👍", "👍", "👍", "👍"], + deliver_silently: false, + created_at: 1734537800, + updated_at: 1734537800, + }; + server.mockEndpoint().get("/news/news_items/1").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.news.items.find({ + news_item_id: 1, + }); + expect(response).toEqual({ + type: "news-item", + id: "34", + workspace_id: "this_is_an_id538_that_should_be_at_least_", + title: "We have news", + body: "

Hello there,

", + sender_id: 991267837, + state: "live", + newsfeed_assignments: [ + { + newsfeed_id: 55, + published_at: 1734537800, + }, + ], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["\uD83D\uDC4D", "\uD83D\uDC4D", "\uD83D\uDC4D", "\uD83D\uDC4D"], + deliver_silently: false, + created_at: 1734537800, + updated_at: 1734537800, + }); + }); + + test("find (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/news/news_items/1").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.news.items.find({ + news_item_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/news/news_items/1").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.news.items.find({ + news_item_id: 1, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("update (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + reactions: ["😝", "😂"], + }; + const rawResponseBody = { + type: "news-item", + id: "37", + workspace_id: "this_is_an_id544_that_should_be_at_least_", + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + state: "live", + newsfeed_assignments: [{ newsfeed_id: 198313, published_at: 1674917488 }], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["😝", "😂"], + deliver_silently: false, + created_at: 1734537803, + updated_at: 1734537804, + }; + server + .mockEndpoint() + .put("/news/news_items/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.news.items.update({ + news_item_id: 1, + body: { + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"], + }, + }); + expect(response).toEqual({ + type: "news-item", + id: "37", + workspace_id: "this_is_an_id544_that_should_be_at_least_", + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + state: "live", + newsfeed_assignments: [ + { + newsfeed_id: 198313, + published_at: 1674917488, + }, + ], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"], + deliver_silently: false, + created_at: 1734537803, + updated_at: 1734537804, + }); + }); + + test("update (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267848, + reactions: ["😝", "😂"], + }; + const rawResponseBody = { + type: "news-item", + id: "37", + workspace_id: "this_is_an_id544_that_should_be_at_least_", + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + state: "live", + newsfeed_assignments: [{ newsfeed_id: 198313, published_at: 1674917488 }], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["😝", "😂"], + deliver_silently: false, + created_at: 1734537803, + updated_at: 1734537804, + }; + server + .mockEndpoint() + .put("/news/news_items/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.news.items.update({ + news_item_id: 1, + body: { + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267848, + reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"], + }, + }); + expect(response).toEqual({ + type: "news-item", + id: "37", + workspace_id: "this_is_an_id544_that_should_be_at_least_", + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + state: "live", + newsfeed_assignments: [ + { + newsfeed_id: 198313, + published_at: 1674917488, + }, + ], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"], + deliver_silently: false, + created_at: 1734537803, + updated_at: 1734537804, + }); + }); + + test("update (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "title", sender_id: 1 }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/news/news_items/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.news.items.update({ + news_item_id: 1, + body: { + title: "title", + sender_id: 1, + }, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("update (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "title", sender_id: 1 }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/news/news_items/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.news.items.update({ + news_item_id: 1, + body: { + title: "title", + sender_id: 1, + }, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("delete (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { id: "40", object: "news-item", deleted: true }; + server + .mockEndpoint() + .delete("/news/news_items/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.news.items.delete({ + news_item_id: 1, + }); + expect(response).toEqual({ + id: "40", + object: "news-item", + deleted: true, + }); + }); + + test("delete (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/news/news_items/1") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.news.items.delete({ + news_item_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("delete (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/news/news_items/1") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.news.items.delete({ + news_item_id: 1, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); +}); diff --git a/tests/wire/notes.test.ts b/tests/wire/notes.test.ts new file mode 100644 index 00000000..6082e324 --- /dev/null +++ b/tests/wire/notes.test.ts @@ -0,0 +1,527 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("NotesClient", () => { + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "type", + data: [ + { + type: "type", + id: "id", + created_at: 1, + contact: { type: "type", id: "id" }, + author: { + type: "type", + id: "id", + name: "name", + email: "email", + job_title: "job_title", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 1, + has_inbox_seat: true, + team_ids: [1, 1], + avatar: { image_url: "image_url" }, + team_priority_level: { primary_team_ids: [1, 1], secondary_team_ids: [1, 1] }, + }, + body: "body", + }, + { + type: "type", + id: "id", + created_at: 1, + contact: { type: "type", id: "id" }, + author: { + type: "type", + id: "id", + name: "name", + email: "email", + job_title: "job_title", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 1, + has_inbox_seat: true, + team_ids: [1, 1], + avatar: { image_url: "image_url" }, + team_priority_level: { primary_team_ids: [1, 1], secondary_team_ids: [1, 1] }, + }, + body: "body", + }, + ], + total_count: 1, + }; + server + .mockEndpoint({ once: false }) + .get("/contacts/contact_id/notes") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const expected = { + type: "type", + data: [ + { + type: "type", + id: "id", + created_at: 1, + contact: { + type: "type", + id: "id", + }, + author: { + type: "type", + id: "id", + name: "name", + email: "email", + job_title: "job_title", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 1, + has_inbox_seat: true, + team_ids: [1, 1], + avatar: { + image_url: "image_url", + }, + team_priority_level: { + primary_team_ids: [1, 1], + secondary_team_ids: [1, 1], + }, + }, + body: "body", + }, + { + type: "type", + id: "id", + created_at: 1, + contact: { + type: "type", + id: "id", + }, + author: { + type: "type", + id: "id", + name: "name", + email: "email", + job_title: "job_title", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 1, + has_inbox_seat: true, + team_ids: [1, 1], + avatar: { + image_url: "image_url", + }, + team_priority_level: { + primary_team_ids: [1, 1], + secondary_team_ids: [1, 1], + }, + }, + body: "body", + }, + ], + total_count: 1, + }; + const page = await client.notes.list({ + contact_id: "contact_id", + }); + + expect(expected.data).toEqual(page.data); + expect(page.hasNextPage()).toBe(true); + const nextPage = await page.getNextPage(); + expect(expected.data).toEqual(nextPage.data); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint({ once: false }) + .get("/contacts/contact_id/notes") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.notes.list({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("create (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { body: "Hello", admin_id: "123" }; + const rawResponseBody = { + type: "note", + id: "31", + created_at: 1734537390, + contact: { type: "contact", id: "6762f0ad1bb69f9f2193bb62" }, + author: { + type: "admin", + id: "991267583", + name: "Ciaran124 Lee", + email: "admin124@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { image_url: "https://example.org/128Wash.jpg" }, + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }, + body: "

Hello

", + }; + server + .mockEndpoint() + .post("/contacts/123/notes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.notes.create({ + contact_id: "123", + body: "Hello", + admin_id: "123", + }); + expect(response).toEqual({ + type: "note", + id: "31", + created_at: 1734537390, + contact: { + type: "contact", + id: "6762f0ad1bb69f9f2193bb62", + }, + author: { + type: "admin", + id: "991267583", + name: "Ciaran124 Lee", + email: "admin124@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { + image_url: "https://example.org/128Wash.jpg", + }, + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }, + body: "

Hello

", + }); + }); + + test("create (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { body: "Hello", admin_id: "123" }; + const rawResponseBody = { + type: "note", + id: "31", + created_at: 1734537390, + contact: { type: "contact", id: "6762f0ad1bb69f9f2193bb62" }, + author: { + type: "admin", + id: "991267583", + name: "Ciaran124 Lee", + email: "admin124@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { image_url: "https://example.org/128Wash.jpg" }, + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }, + body: "

Hello

", + }; + server + .mockEndpoint() + .post("/contacts/123/notes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.notes.create({ + contact_id: "123", + body: "Hello", + admin_id: "123", + }); + expect(response).toEqual({ + type: "note", + id: "31", + created_at: 1734537390, + contact: { + type: "contact", + id: "6762f0ad1bb69f9f2193bb62", + }, + author: { + type: "admin", + id: "991267583", + name: "Ciaran124 Lee", + email: "admin124@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { + image_url: "https://example.org/128Wash.jpg", + }, + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }, + body: "

Hello

", + }); + }); + + test("create (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { body: "Hello", admin_id: "123" }; + const rawResponseBody = { + type: "note", + id: "31", + created_at: 1734537390, + contact: { type: "contact", id: "6762f0ad1bb69f9f2193bb62" }, + author: { + type: "admin", + id: "991267583", + name: "Ciaran124 Lee", + email: "admin124@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { image_url: "https://example.org/128Wash.jpg" }, + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }, + body: "

Hello

", + }; + server + .mockEndpoint() + .post("/contacts/123/notes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.notes.create({ + contact_id: "123", + body: "Hello", + admin_id: "123", + }); + expect(response).toEqual({ + type: "note", + id: "31", + created_at: 1734537390, + contact: { + type: "contact", + id: "6762f0ad1bb69f9f2193bb62", + }, + author: { + type: "admin", + id: "991267583", + name: "Ciaran124 Lee", + email: "admin124@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { + image_url: "https://example.org/128Wash.jpg", + }, + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }, + body: "

Hello

", + }); + }); + + test("create (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { body: "body" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/contacts/contact_id/notes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.notes.create({ + contact_id: "contact_id", + body: "body", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("find (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "note", + id: "34", + created_at: 1733846617, + contact: { type: "contact", id: "6762f2591bb69f9f2193bc1f" }, + author: { + type: "admin", + id: "991267864", + name: "Ciaran346 Lee", + email: "admin346@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { image_url: "https://example.org/128Wash.jpg" }, + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }, + body: "

This is a note.

", + }; + server.mockEndpoint().get("/notes/1").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.notes.find({ + note_id: 1, + }); + expect(response).toEqual({ + type: "note", + id: "34", + created_at: 1733846617, + contact: { + type: "contact", + id: "6762f2591bb69f9f2193bc1f", + }, + author: { + type: "admin", + id: "991267864", + name: "Ciaran346 Lee", + email: "admin346@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: { + image_url: "https://example.org/128Wash.jpg", + }, + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }, + body: "

This is a note.

", + }); + }); + + test("find (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/notes/1").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.notes.find({ + note_id: 1, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/notes/1").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.notes.find({ + note_id: 1, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); +}); diff --git a/tests/wire/phoneCallRedirects.test.ts b/tests/wire/phoneCallRedirects.test.ts new file mode 100644 index 00000000..a81d3a78 --- /dev/null +++ b/tests/wire/phoneCallRedirects.test.ts @@ -0,0 +1,216 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("PhoneCallRedirectsClient", () => { + test("create (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + phone: "+353832345678", + custom_attributes: { issue_type: "Billing", priority: "High" }, + }; + const rawResponseBody = { type: "phone_call_redirect", phone: "+1 1234567890" }; + server + .mockEndpoint() + .post("/phone_call_redirects") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.phoneCallRedirects.create({ + phone: "+353832345678", + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, + }); + expect(response).toEqual({ + type: "phone_call_redirect", + phone: "+1 1234567890", + }); + }); + + test("create (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + phone: "+353832345678", + custom_attributes: { issue_type: "Billing", priority: "High" }, + }; + const rawResponseBody = { type: "phone_call_redirect", phone: "+1 1234567890" }; + server + .mockEndpoint() + .post("/phone_call_redirects") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.phoneCallRedirects.create({ + phone: "+353832345678", + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, + }); + expect(response).toEqual({ + type: "phone_call_redirect", + phone: "+1 1234567890", + }); + }); + + test("create (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + phone: "+353832345678", + custom_attributes: { issue_type: "Billing", priority: "High" }, + }; + const rawResponseBody = { type: "phone_call_redirect", phone: "+1 1234567890" }; + server + .mockEndpoint() + .post("/phone_call_redirects") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.phoneCallRedirects.create({ + phone: "+353832345678", + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, + }); + expect(response).toEqual({ + type: "phone_call_redirect", + phone: "+1 1234567890", + }); + }); + + test("create (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + phone: "+40241100100", + custom_attributes: { issue_type: "Billing", priority: "High" }, + }; + const rawResponseBody = { type: "phone_call_redirect", phone: "+1 1234567890" }; + server + .mockEndpoint() + .post("/phone_call_redirects") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.phoneCallRedirects.create({ + phone: "+40241100100", + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, + }); + expect(response).toEqual({ + type: "phone_call_redirect", + phone: "+1 1234567890", + }); + }); + + test("create (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/phone_call_redirects") + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.phoneCallRedirects.create(undefined); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("create (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/phone_call_redirects") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.phoneCallRedirects.create(undefined); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("create (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/phone_call_redirects") + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.phoneCallRedirects.create(undefined); + }).rejects.toThrow(Intercom.UnprocessableEntityError); + }); +}); diff --git a/tests/wire/segments.test.ts b/tests/wire/segments.test.ts new file mode 100644 index 00000000..0639194d --- /dev/null +++ b/tests/wire/segments.test.ts @@ -0,0 +1,174 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("SegmentsClient", () => { + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "segment.list", + segments: [ + { + type: "segment", + id: "6762f25c1bb69f9f2193bc22", + name: "John segment", + created_at: 1734537820, + updated_at: 1734537820, + person_type: "user", + count: 3, + }, + { + type: "segment", + id: "6762f25c1bb69f9f2193bc23", + name: "Jane segment", + created_at: 1734537820, + updated_at: 1734537820, + person_type: "user", + count: 3, + }, + ], + pages: { key: "value" }, + }; + server.mockEndpoint().get("/segments").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.segments.list({ + include_count: true, + }); + expect(response).toEqual({ + type: "segment.list", + segments: [ + { + type: "segment", + id: "6762f25c1bb69f9f2193bc22", + name: "John segment", + created_at: 1734537820, + updated_at: 1734537820, + person_type: "user", + count: 3, + }, + { + type: "segment", + id: "6762f25c1bb69f9f2193bc23", + name: "Jane segment", + created_at: 1734537820, + updated_at: 1734537820, + person_type: "user", + count: 3, + }, + ], + pages: { + key: "value", + }, + }); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/segments").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.segments.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "segment", + id: "6762f25f1bb69f9f2193bc26", + name: "John segment", + created_at: 1734537823, + updated_at: 1734537823, + person_type: "user", + count: 3, + }; + server.mockEndpoint().get("/segments/123").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.segments.find({ + segment_id: "123", + }); + expect(response).toEqual({ + type: "segment", + id: "6762f25f1bb69f9f2193bc26", + name: "John segment", + created_at: 1734537823, + updated_at: 1734537823, + person_type: "user", + count: 3, + }); + }); + + test("find (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/segments/segment_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.segments.find({ + segment_id: "segment_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/segments/segment_id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.segments.find({ + segment_id: "segment_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); +}); diff --git a/tests/wire/subscriptionTypes.test.ts b/tests/wire/subscriptionTypes.test.ts new file mode 100644 index 00000000..dc2a94b1 --- /dev/null +++ b/tests/wire/subscriptionTypes.test.ts @@ -0,0 +1,92 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("SubscriptionTypesClient", () => { + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "subscription", + id: "135", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [{ name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }], + consent_type: "opt_out", + content_types: ["email"], + }, + ], + }; + server + .mockEndpoint() + .get("/subscription_types") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.subscriptionTypes.list(); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "subscription", + id: "135", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [ + { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + ], + consent_type: "opt_out", + content_types: ["email"], + }, + ], + }); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/subscription_types") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.subscriptionTypes.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); +}); diff --git a/tests/wire/tags.test.ts b/tests/wire/tags.test.ts new file mode 100644 index 00000000..b31a212b --- /dev/null +++ b/tests/wire/tags.test.ts @@ -0,0 +1,1371 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("TagsClient", () => { + test("tagContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "7522907" }; + const rawResponseBody = { + type: "tag", + id: "81", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.tagContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "7522907", + }); + expect(response).toEqual({ + type: "tag", + id: "81", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("tagContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "7522907" }; + const rawResponseBody = { + type: "tag", + id: "81", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.tagContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "7522907", + }); + expect(response).toEqual({ + type: "tag", + id: "81", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("tagContact (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "123" }; + const rawResponseBody = { + type: "tag", + id: "81", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.tagContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "81", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("tagContact (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/contacts/contact_id/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.tagContact({ + contact_id: "contact_id", + id: "id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("tagContact (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/contacts/contact_id/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.tagContact({ + contact_id: "contact_id", + id: "id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("untagContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "tag", + id: "84", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .delete("/contacts/63a07ddf05a32042dffac965/tags/7522907") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.untagContact({ + contact_id: "63a07ddf05a32042dffac965", + tag_id: "7522907", + }); + expect(response).toEqual({ + type: "tag", + id: "84", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("untagContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/contacts/contact_id/tags/tag_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.untagContact({ + contact_id: "contact_id", + tag_id: "tag_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("untagContact (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/contacts/contact_id/tags/tag_id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.untagContact({ + contact_id: "contact_id", + tag_id: "tag_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("tagConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "7522907", admin_id: "780" }; + const rawResponseBody = { + type: "tag", + id: "86", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/conversations/64619700005694/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.tagConversation({ + conversation_id: "64619700005694", + id: "7522907", + admin_id: "780", + }); + expect(response).toEqual({ + type: "tag", + id: "86", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("tagConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "7522907", admin_id: "780" }; + const rawResponseBody = { + type: "tag", + id: "86", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/conversations/64619700005694/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.tagConversation({ + conversation_id: "64619700005694", + id: "7522907", + admin_id: "780", + }); + expect(response).toEqual({ + type: "tag", + id: "86", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("tagConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id", admin_id: "admin_id" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/conversation_id/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.tagConversation({ + conversation_id: "conversation_id", + id: "id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("tagConversation (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id", admin_id: "admin_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations/conversation_id/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.tagConversation({ + conversation_id: "conversation_id", + id: "id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("untagConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "123" }; + const rawResponseBody = { + type: "tag", + id: "89", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .delete("/conversations/64619700005694/tags/7522907") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.untagConversation({ + conversation_id: "64619700005694", + tag_id: "7522907", + admin_id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "89", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("untagConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "123" }; + const rawResponseBody = { + type: "tag", + id: "89", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .delete("/conversations/64619700005694/tags/7522907") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.untagConversation({ + conversation_id: "64619700005694", + tag_id: "7522907", + admin_id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "89", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("untagConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "123" }; + const rawResponseBody = { + type: "tag", + id: "89", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .delete("/conversations/64619700005694/tags/7522907") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.untagConversation({ + conversation_id: "64619700005694", + tag_id: "7522907", + admin_id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "89", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("untagConversation (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/conversations/conversation_id/tags/tag_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.untagConversation({ + conversation_id: "conversation_id", + tag_id: "tag_id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("untagConversation (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/conversations/conversation_id/tags/tag_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.untagConversation({ + conversation_id: "conversation_id", + tag_id: "tag_id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "tag", + id: "102", + name: "Manual tag 1", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }, + ], + }; + server.mockEndpoint().get("/tags").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.tags.list(); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "tag", + id: "102", + name: "Manual tag 1", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }, + ], + }); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/tags").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.tags.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("create (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "test" }; + const rawResponseBody = { + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.create({ + name: "test", + }); + expect(response).toEqual({ + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("create (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "Independent" }; + const rawResponseBody = { + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.create({ + name: "Independent", + }); + expect(response).toEqual({ + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("create (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "test", companies: [{ company_id: "123" }] }; + const rawResponseBody = { + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.create({ + name: "test", + companies: [ + { + company_id: "123", + }, + ], + }); + expect(response).toEqual({ + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("create (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "test", users: [{ id: "123" }] }; + const rawResponseBody = { + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.create({ + name: "test", + users: [ + { + id: "123", + }, + ], + }); + expect(response).toEqual({ + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("create (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "name" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.create({ + name: "name", + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("create (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "name" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.create({ + name: "name", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("create (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "name" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.create({ + name: "name", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("find (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "tag", + id: "113", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server.mockEndpoint().get("/tags/123").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.tags.find({ + tag_id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "113", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("find (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/tags/tag_id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.tags.find({ + tag_id: "tag_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/tags/tag_id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.tags.find({ + tag_id: "tag_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("delete (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + server.mockEndpoint().delete("/tags/123").respondWith().statusCode(200).build(); + + const response = await client.tags.delete({ + tag_id: "123", + }); + expect(response).toEqual(undefined); + }); + + test("delete (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().delete("/tags/tag_id").respondWith().statusCode(400).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.tags.delete({ + tag_id: "tag_id", + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("delete (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().delete("/tags/tag_id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.tags.delete({ + tag_id: "tag_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("delete (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().delete("/tags/tag_id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.tags.delete({ + tag_id: "tag_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("tagTicket (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "7522907", admin_id: "780" }; + const rawResponseBody = { + type: "tag", + id: "121", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/tickets/64619700005694/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.tagTicket({ + ticket_id: "64619700005694", + id: "7522907", + admin_id: "780", + }); + expect(response).toEqual({ + type: "tag", + id: "121", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("tagTicket (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "7522907", admin_id: "780" }; + const rawResponseBody = { + type: "tag", + id: "121", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/tickets/64619700005694/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.tagTicket({ + ticket_id: "64619700005694", + id: "7522907", + admin_id: "780", + }); + expect(response).toEqual({ + type: "tag", + id: "121", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("tagTicket (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id", admin_id: "admin_id" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/tickets/ticket_id/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.tagTicket({ + ticket_id: "ticket_id", + id: "id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("tagTicket (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id", admin_id: "admin_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/tickets/ticket_id/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.tagTicket({ + ticket_id: "ticket_id", + id: "id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("untagTicket (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "123" }; + const rawResponseBody = { + type: "tag", + id: "124", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .delete("/tickets/64619700005694/tags/7522907") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.untagTicket({ + ticket_id: "64619700005694", + tag_id: "7522907", + admin_id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "124", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("untagTicket (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "123" }; + const rawResponseBody = { + type: "tag", + id: "124", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .delete("/tickets/64619700005694/tags/7522907") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.untagTicket({ + ticket_id: "64619700005694", + tag_id: "7522907", + admin_id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "124", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("untagTicket (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "123" }; + const rawResponseBody = { + type: "tag", + id: "124", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .delete("/tickets/64619700005694/tags/7522907") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tags.untagTicket({ + ticket_id: "64619700005694", + tag_id: "7522907", + admin_id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "124", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("untagTicket (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/tickets/ticket_id/tags/tag_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.untagTicket({ + ticket_id: "ticket_id", + tag_id: "tag_id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("untagTicket (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/tickets/ticket_id/tags/tag_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tags.untagTicket({ + ticket_id: "ticket_id", + tag_id: "tag_id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); +}); diff --git a/tests/wire/teams.test.ts b/tests/wire/teams.test.ts new file mode 100644 index 00000000..d9706101 --- /dev/null +++ b/tests/wire/teams.test.ts @@ -0,0 +1,144 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("TeamsClient", () => { + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "team.list", + teams: [ + { + type: "team", + id: "814865", + name: "Example Team", + admin_ids: [493881], + admin_priority_level: { primary_admin_ids: [493881], secondary_admin_ids: [814865] }, + assignment_limit: 10, + distribution_method: "round_robin", + }, + ], + }; + server.mockEndpoint().get("/teams").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.teams.list(); + expect(response).toEqual({ + type: "team.list", + teams: [ + { + type: "team", + id: "814865", + name: "Example Team", + admin_ids: [493881], + admin_priority_level: { + primary_admin_ids: [493881], + secondary_admin_ids: [814865], + }, + assignment_limit: 10, + distribution_method: "round_robin", + }, + ], + }); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/teams").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.teams.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "team", + id: "991267902", + name: "team 1", + admin_ids: [493881], + admin_priority_level: { primary_admin_ids: [493881], secondary_admin_ids: [814865] }, + assignment_limit: 10, + distribution_method: "round_robin", + }; + server.mockEndpoint().get("/teams/123").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.teams.find({ + team_id: "123", + }); + expect(response).toEqual({ + type: "team", + id: "991267902", + name: "team 1", + admin_ids: [493881], + admin_priority_level: { + primary_admin_ids: [493881], + secondary_admin_ids: [814865], + }, + assignment_limit: 10, + distribution_method: "round_robin", + }); + }); + + test("find (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/teams/team_id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.teams.find({ + team_id: "team_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/teams/team_id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.teams.find({ + team_id: "team_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); +}); diff --git a/tests/wire/ticketStates.test.ts b/tests/wire/ticketStates.test.ts new file mode 100644 index 00000000..a510ca68 --- /dev/null +++ b/tests/wire/ticketStates.test.ts @@ -0,0 +1,504 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("TicketStatesClient", () => { + test("listTicketStates (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "ticket_state", + id: "8269", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8270", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8271", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8272", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8273", + category: "submitted", + internal_label: "Admin label 1", + external_label: "User label", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8274", + category: "submitted", + internal_label: "Admin label 2", + external_label: "User label", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + ], + }; + server.mockEndpoint().get("/ticket_states").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.ticketStates.listTicketStates(); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "ticket_state", + id: "8269", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8270", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8271", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8272", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8273", + category: "submitted", + internal_label: "Admin label 1", + external_label: "User label", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8274", + category: "submitted", + internal_label: "Admin label 2", + external_label: "User label", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + ], + }); + }); + + test("listTicketStates (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/ticket_states").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.ticketStates.listTicketStates(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); +}); diff --git a/tests/wire/ticketTypes.test.ts b/tests/wire/ticketTypes.test.ts new file mode 100644 index 00000000..f1ec5429 --- /dev/null +++ b/tests/wire/ticketTypes.test.ts @@ -0,0 +1,689 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("TicketTypesClient", () => { + test("list (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "ticket_type", + id: "67", + category: "Customer", + name: "Bug Report", + description: "Bug Report Template", + icon: "🎟️", + workspace_id: "this_is_an_id648_that_should_be_at_least_", + ticket_type_attributes: { type: "list" }, + ticket_states: { + type: "list", + data: [ + { + type: "ticket_state", + id: "8321", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + { + type: "ticket_state", + id: "8322", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + { + type: "ticket_state", + id: "8323", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + }, + { + type: "ticket_state", + id: "8324", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + }, + ], + }, + archived: false, + created_at: 1734537866, + updated_at: 1734537866, + }, + ], + }; + server.mockEndpoint().get("/ticket_types").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.ticketTypes.list(); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "ticket_type", + id: "67", + category: "Customer", + name: "Bug Report", + description: "Bug Report Template", + icon: "\uD83C\uDF9F\uFE0F", + workspace_id: "this_is_an_id648_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + }, + ticket_states: { + type: "list", + data: [ + { + type: "ticket_state", + id: "8321", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + { + type: "ticket_state", + id: "8322", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + { + type: "ticket_state", + id: "8323", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + }, + { + type: "ticket_state", + id: "8324", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + }, + ], + }, + archived: false, + created_at: 1734537866, + updated_at: 1734537866, + }, + ], + }); + }); + + test("list (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/ticket_types").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.ticketTypes.list(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("create (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + name: "Customer Issue", + description: "Customer Report Template", + category: "Customer", + icon: "🎟️", + }; + const rawResponseBody = { + type: "ticket_type", + id: "70", + category: "Customer", + name: "Customer Issue", + description: "Customer Report Template", + icon: "🎟️", + workspace_id: "this_is_an_id652_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [ + { + type: "ticket_type_attribute", + id: "1", + workspace_id: "ecahpwf5", + name: "Title", + description: "Bug title.", + input_options: { key: "value" }, + order: 1, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: false, + visible_to_contacts: false, + default: true, + ticket_type_id: 42, + archived: false, + }, + ], + }, + ticket_states: { + type: "list", + data: [ + { + type: "ticket_state", + id: "8337", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + { + type: "ticket_state", + id: "8338", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + { + type: "ticket_state", + id: "8339", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + }, + { + type: "ticket_state", + id: "8340", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + }, + ], + }, + archived: false, + created_at: 1734537869, + updated_at: 1734537869, + }; + server + .mockEndpoint() + .post("/ticket_types") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.ticketTypes.create({ + name: "Customer Issue", + description: "Customer Report Template", + category: "Customer", + icon: "\uD83C\uDF9F\uFE0F", + }); + expect(response).toEqual({ + type: "ticket_type", + id: "70", + category: "Customer", + name: "Customer Issue", + description: "Customer Report Template", + icon: "\uD83C\uDF9F\uFE0F", + workspace_id: "this_is_an_id652_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [ + { + type: "ticket_type_attribute", + id: "1", + workspace_id: "ecahpwf5", + name: "Title", + description: "Bug title.", + input_options: { + key: "value", + }, + order: 1, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: false, + visible_to_contacts: false, + default: true, + ticket_type_id: 42, + archived: false, + }, + ], + }, + ticket_states: { + type: "list", + data: [ + { + type: "ticket_state", + id: "8337", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + { + type: "ticket_state", + id: "8338", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + { + type: "ticket_state", + id: "8339", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + }, + { + type: "ticket_state", + id: "8340", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + }, + ], + }, + archived: false, + created_at: 1734537869, + updated_at: 1734537869, + }); + }); + + test("create (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().post("/ticket_types").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.ticketTypes.create(undefined); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("get (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "ticket_type", + id: "72", + category: "Customer", + name: "Bug Report", + description: "Bug Report Template", + icon: "🎟️", + workspace_id: "this_is_an_id656_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [ + { + type: "ticket_type_attribute", + id: "1", + workspace_id: "ecahpwf5", + name: "Title", + description: "Bug title.", + input_options: { key: "value" }, + order: 1, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: false, + visible_to_contacts: false, + default: true, + ticket_type_id: 42, + archived: false, + }, + ], + }, + ticket_states: { + type: "list", + data: [ + { + type: "ticket_state", + id: "8353", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + { + type: "ticket_state", + id: "8354", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + { + type: "ticket_state", + id: "8355", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + }, + { + type: "ticket_state", + id: "8356", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + }, + ], + }, + archived: false, + created_at: 1734537870, + updated_at: 1734537870, + }; + server + .mockEndpoint() + .get("/ticket_types/ticket_type_id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.ticketTypes.get({ + ticket_type_id: "ticket_type_id", + }); + expect(response).toEqual({ + type: "ticket_type", + id: "72", + category: "Customer", + name: "Bug Report", + description: "Bug Report Template", + icon: "\uD83C\uDF9F\uFE0F", + workspace_id: "this_is_an_id656_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [ + { + type: "ticket_type_attribute", + id: "1", + workspace_id: "ecahpwf5", + name: "Title", + description: "Bug title.", + input_options: { + key: "value", + }, + order: 1, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: false, + visible_to_contacts: false, + default: true, + ticket_type_id: 42, + archived: false, + }, + ], + }, + ticket_states: { + type: "list", + data: [ + { + type: "ticket_state", + id: "8353", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + { + type: "ticket_state", + id: "8354", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + { + type: "ticket_state", + id: "8355", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + }, + { + type: "ticket_state", + id: "8356", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + }, + ], + }, + archived: false, + created_at: 1734537870, + updated_at: 1734537870, + }); + }); + + test("get (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/ticket_types/ticket_type_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.ticketTypes.get({ + ticket_type_id: "ticket_type_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("update (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "Bug Report 2" }; + const rawResponseBody = { + type: "ticket_type", + id: "74", + category: "Customer", + name: "Bug Report 2", + description: "Bug Report Template", + icon: "🎟️", + workspace_id: "this_is_an_id660_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [ + { + type: "ticket_type_attribute", + id: "1", + workspace_id: "ecahpwf5", + name: "Title", + description: "Bug title.", + input_options: { key: "value" }, + order: 1, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: false, + visible_to_contacts: false, + default: true, + ticket_type_id: 42, + archived: false, + }, + ], + }, + ticket_states: { + type: "list", + data: [ + { + type: "ticket_state", + id: "8369", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + { + type: "ticket_state", + id: "8370", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + { + type: "ticket_state", + id: "8371", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + }, + { + type: "ticket_state", + id: "8372", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + }, + ], + }, + archived: false, + created_at: 1734537873, + updated_at: 1734537874, + }; + server + .mockEndpoint() + .put("/ticket_types/ticket_type_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.ticketTypes.update({ + ticket_type_id: "ticket_type_id", + name: "Bug Report 2", + }); + expect(response).toEqual({ + type: "ticket_type", + id: "74", + category: "Customer", + name: "Bug Report 2", + description: "Bug Report Template", + icon: "\uD83C\uDF9F\uFE0F", + workspace_id: "this_is_an_id660_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [ + { + type: "ticket_type_attribute", + id: "1", + workspace_id: "ecahpwf5", + name: "Title", + description: "Bug title.", + input_options: { + key: "value", + }, + order: 1, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: false, + visible_to_contacts: false, + default: true, + ticket_type_id: 42, + archived: false, + }, + ], + }, + ticket_states: { + type: "list", + data: [ + { + type: "ticket_state", + id: "8369", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + { + type: "ticket_state", + id: "8370", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + { + type: "ticket_state", + id: "8371", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + }, + { + type: "ticket_state", + id: "8372", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + }, + ], + }, + archived: false, + created_at: 1734537873, + updated_at: 1734537874, + }); + }); + + test("update (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/ticket_types/ticket_type_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.ticketTypes.update({ + ticket_type_id: "ticket_type_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); +}); diff --git a/tests/wire/ticketTypes/attributes.test.ts b/tests/wire/ticketTypes/attributes.test.ts new file mode 100644 index 00000000..0bd0e735 --- /dev/null +++ b/tests/wire/ticketTypes/attributes.test.ts @@ -0,0 +1,200 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("AttributesClient", () => { + test("create (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + name: "Attribute Title", + description: "Attribute Description", + data_type: "string", + required_to_create: false, + }; + const rawResponseBody = { + type: "ticket_type_attribute", + id: "157", + workspace_id: "this_is_an_id640_that_should_be_at_least_", + name: "Attribute Title", + description: "Attribute Description", + data_type: "string", + input_options: { multiline: false }, + order: 2, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: true, + visible_to_contacts: true, + default: false, + ticket_type_id: 63, + archived: false, + created_at: 1734537862, + updated_at: 1734537862, + }; + server + .mockEndpoint() + .post("/ticket_types/ticket_type_id/attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.ticketTypes.attributes.create({ + ticket_type_id: "ticket_type_id", + name: "Attribute Title", + description: "Attribute Description", + data_type: "string", + required_to_create: false, + }); + expect(response).toEqual({ + type: "ticket_type_attribute", + id: "157", + workspace_id: "this_is_an_id640_that_should_be_at_least_", + name: "Attribute Title", + description: "Attribute Description", + data_type: "string", + input_options: { + multiline: false, + }, + order: 2, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: true, + visible_to_contacts: true, + default: false, + ticket_type_id: 63, + archived: false, + created_at: 1734537862, + updated_at: 1734537862, + }); + }); + + test("create (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "name", description: "description", data_type: "string" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/ticket_types/ticket_type_id/attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.ticketTypes.attributes.create({ + ticket_type_id: "ticket_type_id", + name: "name", + description: "description", + data_type: "string", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("update (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { description: "New Attribute Description" }; + const rawResponseBody = { + type: "ticket_type_attribute", + id: "162", + workspace_id: "this_is_an_id644_that_should_be_at_least_", + name: "name", + description: "New Attribute Description", + data_type: "string", + input_options: { key: "value" }, + order: 0, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: false, + visible_to_contacts: false, + default: false, + ticket_type_id: 65, + archived: false, + created_at: 1734537864, + updated_at: 1734537864, + }; + server + .mockEndpoint() + .put("/ticket_types/ticket_type_id/attributes/attribute_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.ticketTypes.attributes.update({ + ticket_type_id: "ticket_type_id", + attribute_id: "attribute_id", + description: "New Attribute Description", + }); + expect(response).toEqual({ + type: "ticket_type_attribute", + id: "162", + workspace_id: "this_is_an_id644_that_should_be_at_least_", + name: "name", + description: "New Attribute Description", + data_type: "string", + input_options: { + key: "value", + }, + order: 0, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: false, + visible_to_contacts: false, + default: false, + ticket_type_id: 65, + archived: false, + created_at: 1734537864, + updated_at: 1734537864, + }); + }); + + test("update (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/ticket_types/ticket_type_id/attributes/attribute_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.ticketTypes.attributes.update({ + ticket_type_id: "ticket_type_id", + attribute_id: "attribute_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); +}); diff --git a/tests/wire/tickets.test.ts b/tests/wire/tickets.test.ts new file mode 100644 index 00000000..928f3523 --- /dev/null +++ b/tests/wire/tickets.test.ts @@ -0,0 +1,3690 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("TicketsClient", () => { + test("reply (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2971bb69f9f2193bc49", + }; + const rawResponseBody = { + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { type: "admin", id: "991267943", name: "Ciaran419 Lee", email: "admin419@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }; + server + .mockEndpoint() + .post("/tickets/123/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tickets.reply({ + ticket_id: "123", + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2971bb69f9f2193bc49", + }, + }); + expect(response).toEqual({ + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { + type: "admin", + id: "991267943", + name: "Ciaran419 Lee", + email: "admin419@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }); + }); + + test("reply (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "note", + type: "admin", + body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + admin_id: "3156780", + }; + const rawResponseBody = { + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { type: "admin", id: "991267943", name: "Ciaran419 Lee", email: "admin419@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }; + server + .mockEndpoint() + .post("/tickets/123/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tickets.reply({ + ticket_id: "123", + body: { + message_type: "note", + type: "admin", + body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + admin_id: "3156780", + }, + }); + expect(response).toEqual({ + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { + type: "admin", + id: "991267943", + name: "Ciaran419 Lee", + email: "admin419@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }); + }); + + test("reply (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "quick_reply", + type: "admin", + admin_id: "3156780", + reply_options: [ + { text: "Yes", uuid: "0df48b85-9a93-4c66-a167-753eff0baaec" }, + { text: "No", uuid: "4f0b5145-4193-4b4f-8cad-ce19478a3938" }, + ], + }; + const rawResponseBody = { + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { type: "admin", id: "991267943", name: "Ciaran419 Lee", email: "admin419@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }; + server + .mockEndpoint() + .post("/tickets/123/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tickets.reply({ + ticket_id: "123", + body: { + message_type: "quick_reply", + type: "admin", + admin_id: "3156780", + reply_options: [ + { + text: "Yes", + uuid: "0df48b85-9a93-4c66-a167-753eff0baaec", + }, + { + text: "No", + uuid: "4f0b5145-4193-4b4f-8cad-ce19478a3938", + }, + ], + }, + }); + expect(response).toEqual({ + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { + type: "admin", + id: "991267943", + name: "Ciaran419 Lee", + email: "admin419@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }); + }); + + test("reply (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2a41bb69f9f2193bc4c", + }; + const rawResponseBody = { + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { type: "admin", id: "991267943", name: "Ciaran419 Lee", email: "admin419@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }; + server + .mockEndpoint() + .post("/tickets/123/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tickets.reply({ + ticket_id: "123", + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2a41bb69f9f2193bc4c", + }, + }); + expect(response).toEqual({ + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { + type: "admin", + id: "991267943", + name: "Ciaran419 Lee", + email: "admin419@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }); + }); + + test("reply (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2971bb69f9f2193bc49", + }; + const rawResponseBody = { + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { type: "admin", id: "991267943", name: "Ciaran419 Lee", email: "admin419@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }; + server + .mockEndpoint() + .post("/tickets/123/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tickets.reply({ + ticket_id: "123", + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2971bb69f9f2193bc49", + }, + }); + expect(response).toEqual({ + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { + type: "admin", + id: "991267943", + name: "Ciaran419 Lee", + email: "admin419@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }); + }); + + test("reply (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2971bb69f9f2193bc49", + }; + const rawResponseBody = { + type: "ticket_part", + id: "158", + part_type: "quick_reply", + body: "

Okay!

", + created_at: 1734537890, + updated_at: 1734537890, + author: { type: "admin", id: "991267948", name: "Ciaran423 Lee", email: "admin423@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }; + server + .mockEndpoint() + .post("/tickets/123/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tickets.reply({ + ticket_id: "123", + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2971bb69f9f2193bc49", + }, + }); + expect(response).toEqual({ + type: "ticket_part", + id: "158", + part_type: "quick_reply", + body: "

Okay!

", + created_at: 1734537890, + updated_at: 1734537890, + author: { + type: "admin", + id: "991267948", + name: "Ciaran423 Lee", + email: "admin423@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }); + }); + + test("reply (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/tickets/ticket_id/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tickets.reply({ + ticket_id: "ticket_id", + body: { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }, + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("reply (8)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/tickets/ticket_id/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tickets.reply({ + ticket_id: "ticket_id", + body: { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("reply (9)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/tickets/ticket_id/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tickets.reply({ + ticket_id: "ticket_id", + body: { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }, + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("create (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_type_id: "1234", contacts: [{ id: "6762f2d81bb69f9f2193bc54" }] }; + const rawResponseBody = { + type: "ticket", + id: "626", + ticket_id: "33", + category: "Back-office", + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state: { + type: "ticket_state", + id: "8481", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "88", + category: "Back-office", + name: "my-ticket-type-23", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id688_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537943, + updated_at: 1734537943, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f2d81bb69f9f2193bc54", external_id: "70" }], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537944, + updated_at: 1734537946, + open: true, + snoozed_until: 1663597260, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "175", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537945, + updated_at: 1734537945, + author: { + type: "bot", + id: "991267999", + name: "Fin", + email: "operator+this_is_an_id688_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 1, + }, + is_shared: false, + }; + server + .mockEndpoint() + .post("/tickets") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tickets.create({ + ticket_type_id: "1234", + contacts: [ + { + id: "6762f2d81bb69f9f2193bc54", + }, + ], + }); + expect(response).toEqual({ + type: "ticket", + id: "626", + ticket_id: "33", + category: "Back-office", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state: { + type: "ticket_state", + id: "8481", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "88", + category: "Back-office", + name: "my-ticket-type-23", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id688_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537943, + updated_at: 1734537943, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2d81bb69f9f2193bc54", + external_id: "70", + }, + ], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537944, + updated_at: 1734537946, + open: true, + snoozed_until: 1663597260, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "175", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537945, + updated_at: 1734537945, + author: { + type: "bot", + id: "991267999", + name: "Fin", + email: "operator+this_is_an_id688_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 1, + }, + is_shared: false, + }); + }); + + test("create (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_type_id: "ticket_type_id", contacts: [{ id: "id" }, { id: "id" }] }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/tickets") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tickets.create({ + ticket_type_id: "ticket_type_id", + contacts: [ + { + id: "id", + }, + { + id: "id", + }, + ], + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("enqueueCreateTicket (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_type_id: "1234", contacts: [{ id: "6762f2d81bb69f9f2193bc54" }] }; + const rawResponseBody = { + type: "job", + id: "20", + url: "https://api.intercom.io/jobs/status/20", + status: "pending", + resource_type: "ticket", + resource_id: "resource_id", + resource_url: "http://api.intercom.io/tickets/123", + }; + server + .mockEndpoint() + .post("/tickets/enqueue") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tickets.enqueueCreateTicket({ + ticket_type_id: "1234", + contacts: [ + { + id: "6762f2d81bb69f9f2193bc54", + }, + ], + }); + expect(response).toEqual({ + type: "job", + id: "20", + url: "https://api.intercom.io/jobs/status/20", + status: "pending", + resource_type: "ticket", + resource_id: "resource_id", + resource_url: "http://api.intercom.io/tickets/123", + }); + }); + + test("enqueueCreateTicket (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_type_id: "ticket_type_id", contacts: [{ id: "id" }, { id: "id" }] }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/tickets/enqueue") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tickets.enqueueCreateTicket({ + ticket_type_id: "ticket_type_id", + contacts: [ + { + id: "id", + }, + { + id: "id", + }, + ], + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("enqueueCreateTicket (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_type_id: "ticket_type_id", contacts: [{ id: "id" }, { id: "id" }] }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/tickets/enqueue") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tickets.enqueueCreateTicket({ + ticket_type_id: "ticket_type_id", + contacts: [ + { + id: "id", + }, + { + id: "id", + }, + ], + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("get (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "ticket", + id: "631", + ticket_id: "38", + category: "Back-office", + ticket_attributes: { _default_title_: "attribute_value", _default_description_: { key: "value" } }, + ticket_state: { + type: "ticket_state", + id: "8537", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "95", + category: "Back-office", + name: "my-ticket-type-30", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id702_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537973, + updated_at: 1734537973, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2f61bb69f9f2193bc59", + external_id: "b16afa36-2637-4880-adee-a46d145bc27f", + }, + ], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537974, + updated_at: 1734537976, + open: true, + snoozed_until: 1663597260, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "185", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537975, + updated_at: 1734537975, + author: { type: "admin", id: "991268047", name: "Ciaran509 Lee", email: "admin509@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + is_shared: false, + }; + server.mockEndpoint().get("/tickets/ticket_id").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.tickets.get({ + ticket_id: "ticket_id", + }); + expect(response).toEqual({ + type: "ticket", + id: "631", + ticket_id: "38", + category: "Back-office", + ticket_attributes: { + _default_title_: "attribute_value", + _default_description_: { + key: "value", + }, + }, + ticket_state: { + type: "ticket_state", + id: "8537", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "95", + category: "Back-office", + name: "my-ticket-type-30", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id702_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537973, + updated_at: 1734537973, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2f61bb69f9f2193bc59", + external_id: "b16afa36-2637-4880-adee-a46d145bc27f", + }, + ], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537974, + updated_at: 1734537976, + open: true, + snoozed_until: 1663597260, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "185", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537975, + updated_at: 1734537975, + author: { + type: "admin", + id: "991268047", + name: "Ciaran509 Lee", + email: "admin509@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + is_shared: false, + }); + }); + + test("get (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/tickets/ticket_id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.tickets.get({ + ticket_id: "ticket_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("update (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state_id: "123", + open: true, + snoozed_until: 1673609604, + admin_id: 991268011, + assignee_id: "123", + }; + const rawResponseBody = { + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "10", label: "Photo" }, + value: { type: "value", id: [2], label: ["photo.png"] }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "7", label: "Progress" }, + value: { type: "value", id: "Fast", label: "Fast" }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { type: "admin", id: "991268013" }, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }; + server + .mockEndpoint() + .put("/tickets/ticket_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tickets.update({ + ticket_id: "ticket_id", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state_id: "123", + open: true, + snoozed_until: 1673609604, + admin_id: 991268011, + assignee_id: "123", + }); + expect(response).toEqual({ + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "10", + label: "Photo", + }, + value: { + type: "value", + id: [2], + label: ["photo.png"], + }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "7", + label: "Progress", + }, + value: { + type: "value", + id: "Fast", + label: "Fast", + }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { + type: "admin", + id: "991268013", + }, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }); + }); + + test("update (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state_id: "123", + admin_id: 991268011, + assignee_id: "123", + }; + const rawResponseBody = { + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "10", label: "Photo" }, + value: { type: "value", id: [2], label: ["photo.png"] }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "7", label: "Progress" }, + value: { type: "value", id: "Fast", label: "Fast" }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { type: "admin", id: "991268013" }, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }; + server + .mockEndpoint() + .put("/tickets/ticket_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tickets.update({ + ticket_id: "ticket_id", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state_id: "123", + admin_id: 991268011, + assignee_id: "123", + }); + expect(response).toEqual({ + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "10", + label: "Photo", + }, + value: { + type: "value", + id: [2], + label: ["photo.png"], + }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "7", + label: "Progress", + }, + value: { + type: "value", + id: "Fast", + label: "Fast", + }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { + type: "admin", + id: "991268013", + }, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }); + }); + + test("update (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state_id: "123", + admin_id: 991268011, + assignee_id: "123", + }; + const rawResponseBody = { + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "10", label: "Photo" }, + value: { type: "value", id: [2], label: ["photo.png"] }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "7", label: "Progress" }, + value: { type: "value", id: "Fast", label: "Fast" }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { type: "admin", id: "991268013" }, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }; + server + .mockEndpoint() + .put("/tickets/ticket_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tickets.update({ + ticket_id: "ticket_id", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state_id: "123", + admin_id: 991268011, + assignee_id: "123", + }); + expect(response).toEqual({ + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "10", + label: "Photo", + }, + value: { + type: "value", + id: [2], + label: ["photo.png"], + }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "7", + label: "Progress", + }, + value: { + type: "value", + id: "Fast", + label: "Fast", + }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { + type: "admin", + id: "991268013", + }, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }); + }); + + test("update (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_state_id: "123" }; + const rawResponseBody = { + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "10", label: "Photo" }, + value: { type: "value", id: [2], label: ["photo.png"] }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "7", label: "Progress" }, + value: { type: "value", id: "Fast", label: "Fast" }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { type: "admin", id: "991268013" }, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }; + server + .mockEndpoint() + .put("/tickets/ticket_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tickets.update({ + ticket_id: "ticket_id", + ticket_state_id: "123", + }); + expect(response).toEqual({ + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "10", + label: "Photo", + }, + value: { + type: "value", + id: [2], + label: ["photo.png"], + }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "7", + label: "Progress", + }, + value: { + type: "value", + id: "Fast", + label: "Fast", + }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { + type: "admin", + id: "991268013", + }, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }); + }); + + test("update (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/tickets/ticket_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tickets.update({ + ticket_id: "ticket_id", + }); + }).rejects.toThrow(Intercom.BadRequestError); + }); + + test("update (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/tickets/ticket_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tickets.update({ + ticket_id: "ticket_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("update (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/tickets/ticket_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tickets.update({ + ticket_id: "ticket_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("deleteTicket (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { id: "632", object: "ticket", deleted: true }; + server + .mockEndpoint() + .delete("/tickets/ticket_id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.tickets.deleteTicket({ + ticket_id: "ticket_id", + }); + expect(response).toEqual({ + id: "632", + object: "ticket", + deleted: true, + }); + }); + + test("deleteTicket (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/tickets/ticket_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tickets.deleteTicket({ + ticket_id: "ticket_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("deleteTicket (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/tickets/ticket_id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.tickets.deleteTicket({ + ticket_id: "ticket_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("search", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + query: { operator: "AND", value: [{ field: "created_at", operator: ">", value: "1306054154" }] }, + pagination: { per_page: 5 }, + }; + const rawResponseBody = { + type: "ticket.list", + tickets: [ + { + type: "ticket", + id: "633", + ticket_id: "40", + category: "Back-office", + ticket_attributes: { _default_title_: "attribute_value" }, + ticket_state: { + type: "ticket_state", + id: "8577", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "100", + category: "Back-office", + name: "my-ticket-type-35", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id712_that_should_be_at_least_", + ticket_type_attributes: { type: "list" }, + archived: false, + created_at: 1734537989, + updated_at: 1734537989, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f3061bb69f9f2193bc5b", + external_id: "9b913927-c084-4391-b1db-098341b5ffe3", + }, + ], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537990, + updated_at: 1734537992, + open: true, + snoozed_until: 1663597260, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "188", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537991, + updated_at: 1734537991, + author: { + type: "admin", + id: "991268079", + name: "Ciaran539 Lee", + email: "admin539@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 1, + }, + is_shared: false, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 5, + total_pages: 1, + }, + }; + server + .mockEndpoint({ once: false }) + .post("/tickets/search") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const expected = { + type: "ticket.list", + tickets: [ + { + type: "ticket", + id: "633", + ticket_id: "40", + category: "Back-office", + ticket_attributes: { + _default_title_: "attribute_value", + }, + ticket_state: { + type: "ticket_state", + id: "8577", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "100", + category: "Back-office", + name: "my-ticket-type-35", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id712_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + }, + archived: false, + created_at: 1734537989, + updated_at: 1734537989, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f3061bb69f9f2193bc5b", + external_id: "9b913927-c084-4391-b1db-098341b5ffe3", + }, + ], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537990, + updated_at: 1734537992, + open: true, + snoozed_until: 1663597260, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "188", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537991, + updated_at: 1734537991, + author: { + type: "admin", + id: "991268079", + name: "Ciaran539 Lee", + email: "admin539@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 1, + }, + is_shared: false, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 5, + total_pages: 1, + }, + }; + const page = await client.tickets.search({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, + }); + + expect(expected.tickets).toEqual(page.data); + expect(page.hasNextPage()).toBe(true); + const nextPage = await page.getNextPage(); + expect(expected.tickets).toEqual(nextPage.data); + }); +}); diff --git a/tests/wire/unstable/admins.test.ts b/tests/wire/unstable/admins.test.ts new file mode 100644 index 00000000..15a2ae87 --- /dev/null +++ b/tests/wire/unstable/admins.test.ts @@ -0,0 +1,644 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("AdminsClient", () => { + test("identifyAdmin", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "admin", + id: "991267459", + name: "Ciaran1 Lee", + email: "admin1@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + has_inbox_seat: true, + team_ids: [814865], + avatar: { + type: "avatar", + image_url: "https://static.intercomassets.com/assets/default-avatars/admins/128.png", + }, + email_verified: true, + app: { + type: "app", + id_code: "this_is_an_id1_that_should_be_at_least_40", + name: "MyApp 1", + region: "US", + timezone: "America/Los_Angeles", + created_at: 1734537243, + identity_verification: false, + }, + }; + server.mockEndpoint().get("/me").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.admins.identifyAdmin(); + expect(response).toEqual({ + type: "admin", + id: "991267459", + name: "Ciaran1 Lee", + email: "admin1@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + has_inbox_seat: true, + team_ids: [814865], + avatar: { + type: "avatar", + image_url: "https://static.intercomassets.com/assets/default-avatars/admins/128.png", + }, + email_verified: true, + app: { + type: "app", + id_code: "this_is_an_id1_that_should_be_at_least_40", + name: "MyApp 1", + region: "US", + timezone: "America/Los_Angeles", + created_at: 1734537243, + identity_verification: false, + }, + }); + }); + + test("setAwayAdmin (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { away_mode_enabled: true, away_mode_reassign: true, away_status_reason_id: 12345 }; + const rawResponseBody = { + type: "admin", + id: "991267460", + name: "Ciaran2 Lee", + email: "admin2@email.com", + job_title: "Associate", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }; + server + .mockEndpoint() + .put("/admins/1/away") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.admins.setAwayAdmin({ + id: 1, + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, + }); + expect(response).toEqual({ + type: "admin", + id: "991267460", + name: "Ciaran2 Lee", + email: "admin2@email.com", + job_title: "Associate", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }); + }); + + test("setAwayAdmin (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { away_mode_enabled: true, away_mode_reassign: true }; + const rawResponseBody = { + type: "admin", + id: "991267460", + name: "Ciaran2 Lee", + email: "admin2@email.com", + job_title: "Associate", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }; + server + .mockEndpoint() + .put("/admins/1/away") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.admins.setAwayAdmin({ + id: 1, + away_mode_enabled: true, + away_mode_reassign: true, + }); + expect(response).toEqual({ + type: "admin", + id: "991267460", + name: "Ciaran2 Lee", + email: "admin2@email.com", + job_title: "Associate", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }); + }); + + test("setAwayAdmin (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { away_mode_enabled: true, away_mode_reassign: true }; + const rawResponseBody = { + type: "admin", + id: "991267460", + name: "Ciaran2 Lee", + email: "admin2@email.com", + job_title: "Associate", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }; + server + .mockEndpoint() + .put("/admins/1/away") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.admins.setAwayAdmin({ + id: 1, + away_mode_enabled: true, + away_mode_reassign: true, + }); + expect(response).toEqual({ + type: "admin", + id: "991267460", + name: "Ciaran2 Lee", + email: "admin2@email.com", + job_title: "Associate", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }); + }); + + test("setAwayAdmin (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { away_mode_enabled: true, away_mode_reassign: true }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/admins/1/away") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.admins.setAwayAdmin({ + id: 1, + away_mode_enabled: true, + away_mode_reassign: true, + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("setAwayAdmin (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { away_mode_enabled: true, away_mode_reassign: true }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/admins/1/away") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.admins.setAwayAdmin({ + id: 1, + away_mode_enabled: true, + away_mode_reassign: true, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("setAwayAdmin (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { away_mode_enabled: true, away_mode_reassign: true }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/admins/1/away") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.admins.setAwayAdmin({ + id: 1, + away_mode_enabled: true, + away_mode_reassign: true, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("listActivityLogs (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "activity_log.list", + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 20, + total_pages: 1, + }, + activity_logs: [ + { + id: "fca05814-4b72-4dce-ad4f-77a786a2c136", + performed_by: { type: "admin", id: "991267464", email: "admin5@email.com", ip: "127.0.0.1" }, + metadata: { + sign_in_method: "email_password", + external_id: "f3b87a2e09d514c6c2e79b9a", + away_mode: true, + away_status_reason: "😌 On a break", + reassign_conversations: false, + source: "admin update from web - Admin id: 93", + update_by: 93, + update_by_name: "Joe Example", + conversation_assignment_limit: 15, + ticket_assignment_limit: 20, + }, + created_at: 1734537253, + activity_type: "app_name_change", + activity_description: "Ciaran5 Lee changed your app name from before to after.", + }, + { + id: "f48c653b-0185-48ac-a276-23d11006bafb", + performed_by: { type: "admin", id: "991267464", email: "admin5@email.com", ip: "127.0.0.1" }, + metadata: { + sign_in_method: "email_password", + external_id: "f3b87a2e09d514c6c2e79b9a", + away_mode: true, + away_status_reason: "😌 On a break", + reassign_conversations: false, + source: "admin update from web - Admin id: 93", + update_by: 93, + update_by_name: "Joe Example", + conversation_assignment_limit: 15, + ticket_assignment_limit: 20, + }, + created_at: 1734537253, + activity_type: "message_state_change", + activity_description: + "Ciaran5 Lee changed your Initial message title message from Initial message title to Eventual message title.", + }, + ], + }; + server + .mockEndpoint() + .get("/admins/activity_logs") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.admins.listActivityLogs({ + created_at_after: "1677253093", + created_at_before: "1677861493", + }); + expect(response).toEqual({ + type: "activity_log.list", + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 20, + total_pages: 1, + }, + activity_logs: [ + { + id: "fca05814-4b72-4dce-ad4f-77a786a2c136", + performed_by: { + type: "admin", + id: "991267464", + email: "admin5@email.com", + ip: "127.0.0.1", + }, + metadata: { + sign_in_method: "email_password", + external_id: "f3b87a2e09d514c6c2e79b9a", + away_mode: true, + away_status_reason: "\uD83D\uDE0C On a break", + reassign_conversations: false, + source: "admin update from web - Admin id: 93", + update_by: 93, + update_by_name: "Joe Example", + conversation_assignment_limit: 15, + ticket_assignment_limit: 20, + }, + created_at: 1734537253, + activity_type: "app_name_change", + activity_description: "Ciaran5 Lee changed your app name from before to after.", + }, + { + id: "f48c653b-0185-48ac-a276-23d11006bafb", + performed_by: { + type: "admin", + id: "991267464", + email: "admin5@email.com", + ip: "127.0.0.1", + }, + metadata: { + sign_in_method: "email_password", + external_id: "f3b87a2e09d514c6c2e79b9a", + away_mode: true, + away_status_reason: "\uD83D\uDE0C On a break", + reassign_conversations: false, + source: "admin update from web - Admin id: 93", + update_by: 93, + update_by_name: "Joe Example", + conversation_assignment_limit: 15, + ticket_assignment_limit: 20, + }, + created_at: 1734537253, + activity_type: "message_state_change", + activity_description: + "Ciaran5 Lee changed your Initial message title message from Initial message title to Eventual message title.", + }, + ], + }); + }); + + test("listActivityLogs (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/admins/activity_logs") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.admins.listActivityLogs({ + created_at_after: "created_at_after", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("listAdmins (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "admin.list", + admins: [ + { + type: "admin", + id: "991267466", + name: "Ciaran7 Lee", + email: "admin7@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }, + ], + }; + server.mockEndpoint().get("/admins").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.admins.listAdmins(); + expect(response).toEqual({ + type: "admin.list", + admins: [ + { + type: "admin", + id: "991267466", + name: "Ciaran7 Lee", + email: "admin7@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }, + ], + }); + }); + + test("listAdmins (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/admins").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.admins.listAdmins(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveAdmin (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "admin", + id: "991267468", + name: "Ciaran9 Lee", + email: "admin9@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }; + server.mockEndpoint().get("/admins/1").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.admins.retrieveAdmin({ + id: 1, + }); + expect(response).toEqual({ + type: "admin", + id: "991267468", + name: "Ciaran9 Lee", + email: "admin9@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }); + }); + + test("retrieveAdmin (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/admins/1").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.admins.retrieveAdmin({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveAdmin (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/admins/1").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.admins.retrieveAdmin({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); +}); diff --git a/tests/wire/unstable/aiContent.test.ts b/tests/wire/unstable/aiContent.test.ts new file mode 100644 index 00000000..4c0c8a22 --- /dev/null +++ b/tests/wire/unstable/aiContent.test.ts @@ -0,0 +1,878 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("AiContentClient", () => { + test("listContentImportSources (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { type: "pages", page: 1, next: "next", per_page: 50, total_pages: 1 }, + total_count: 3, + data: [ + { + type: "content_import_source", + id: 33, + last_synced_at: 1734537259, + sync_behavior: "automatic", + status: "active", + url: "https://support.example.com/us/1", + created_at: 1734537259, + updated_at: 1734537259, + }, + { + type: "content_import_source", + id: 34, + last_synced_at: 1734537259, + sync_behavior: "automatic", + status: "active", + url: "https://support.example.com/us/2", + created_at: 1734537259, + updated_at: 1734537259, + }, + { + type: "content_import_source", + id: 35, + last_synced_at: 1734537259, + sync_behavior: "automatic", + status: "active", + url: "https://support.example.com/us/3", + created_at: 1734537259, + updated_at: 1734537259, + }, + ], + }; + server + .mockEndpoint() + .get("/ai/content_import_sources") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.aiContent.listContentImportSources(); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: "next", + per_page: 50, + total_pages: 1, + }, + total_count: 3, + data: [ + { + type: "content_import_source", + id: 33, + last_synced_at: 1734537259, + sync_behavior: "automatic", + status: "active", + url: "https://support.example.com/us/1", + created_at: 1734537259, + updated_at: 1734537259, + }, + { + type: "content_import_source", + id: 34, + last_synced_at: 1734537259, + sync_behavior: "automatic", + status: "active", + url: "https://support.example.com/us/2", + created_at: 1734537259, + updated_at: 1734537259, + }, + { + type: "content_import_source", + id: 35, + last_synced_at: 1734537259, + sync_behavior: "automatic", + status: "active", + url: "https://support.example.com/us/3", + created_at: 1734537259, + updated_at: 1734537259, + }, + ], + }); + }); + + test("listContentImportSources (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/ai/content_import_sources") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.aiContent.listContentImportSources(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createContentImportSource (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { sync_behavior: "api", url: "https://www.example.com" }; + const rawResponseBody = { + type: "content_import_source", + id: 36, + last_synced_at: 1734537261, + sync_behavior: "api", + status: "active", + url: "https://www.example.com", + created_at: 1734537261, + updated_at: 1734537261, + }; + server + .mockEndpoint() + .post("/ai/content_import_sources") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.aiContent.createContentImportSource({ + url: "https://www.example.com", + }); + expect(response).toEqual({ + type: "content_import_source", + id: 36, + last_synced_at: 1734537261, + sync_behavior: "api", + status: "active", + url: "https://www.example.com", + created_at: 1734537261, + updated_at: 1734537261, + }); + }); + + test("createContentImportSource (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { sync_behavior: "api", url: "url" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/ai/content_import_sources") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.aiContent.createContentImportSource({ + url: "url", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("getContentImportSource (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "content_import_source", + id: 38, + last_synced_at: 1734537265, + sync_behavior: "api", + status: "active", + url: "https://support.example.com/us/5", + created_at: 1734537265, + updated_at: 1734537265, + }; + server + .mockEndpoint() + .get("/ai/content_import_sources/id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.aiContent.getContentImportSource({ + id: "id", + }); + expect(response).toEqual({ + type: "content_import_source", + id: 38, + last_synced_at: 1734537265, + sync_behavior: "api", + status: "active", + url: "https://support.example.com/us/5", + created_at: 1734537265, + updated_at: 1734537265, + }); + }); + + test("getContentImportSource (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/ai/content_import_sources/id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.aiContent.getContentImportSource({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("updateContentImportSource (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { sync_behavior: "api", url: "https://www.example.com" }; + const rawResponseBody = { + type: "content_import_source", + id: 39, + last_synced_at: 1734537267, + sync_behavior: "api", + status: "active", + url: "https://www.example.com", + created_at: 1734537267, + updated_at: 1734537267, + }; + server + .mockEndpoint() + .put("/ai/content_import_sources/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.aiContent.updateContentImportSource({ + id: "id", + sync_behavior: "api", + url: "https://www.example.com", + }); + expect(response).toEqual({ + type: "content_import_source", + id: 39, + last_synced_at: 1734537267, + sync_behavior: "api", + status: "active", + url: "https://www.example.com", + created_at: 1734537267, + updated_at: 1734537267, + }); + }); + + test("updateContentImportSource (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { sync_behavior: "api", url: "url" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/ai/content_import_sources/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.aiContent.updateContentImportSource({ + id: "id", + sync_behavior: "api", + url: "url", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("deleteContentImportSource (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + server.mockEndpoint().delete("/ai/content_import_sources/id").respondWith().statusCode(200).build(); + + const response = await client.unstable.aiContent.deleteContentImportSource({ + id: "id", + }); + expect(response).toEqual(undefined); + }); + + test("deleteContentImportSource (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/ai/content_import_sources/id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.aiContent.deleteContentImportSource({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("listExternalPages (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { type: "pages", page: 1, next: "next", per_page: 50, total_pages: 1 }, + total_count: 3, + data: [ + { + type: "external_page", + id: "19", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/3", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 42, + external_id: "3", + created_at: 1734537269, + updated_at: 1734537269, + last_ingested_at: 1734537269, + }, + { + type: "external_page", + id: "18", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/2", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 41, + external_id: "2", + created_at: 1734537269, + updated_at: 1734537269, + last_ingested_at: 1734537269, + }, + { + type: "external_page", + id: "17", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/1", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 40, + external_id: "1", + created_at: 1734537269, + updated_at: 1734537269, + last_ingested_at: 1734537269, + }, + ], + }; + server.mockEndpoint().get("/ai/external_pages").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.aiContent.listExternalPages(); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: "next", + per_page: 50, + total_pages: 1, + }, + total_count: 3, + data: [ + { + type: "external_page", + id: "19", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/3", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 42, + external_id: "3", + created_at: 1734537269, + updated_at: 1734537269, + last_ingested_at: 1734537269, + }, + { + type: "external_page", + id: "18", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/2", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 41, + external_id: "2", + created_at: 1734537269, + updated_at: 1734537269, + last_ingested_at: 1734537269, + }, + { + type: "external_page", + id: "17", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/1", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 40, + external_id: "1", + created_at: 1734537269, + updated_at: 1734537269, + last_ingested_at: 1734537269, + }, + ], + }); + }); + + test("listExternalPages (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/ai/external_pages").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.aiContent.listExternalPages(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createExternalPage (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Test", + html: "

Test

", + url: "https://www.example.com", + locale: "en", + source_id: 44, + external_id: "abc1234", + }; + const rawResponseBody = { + type: "external_page", + id: "21", + title: "Test", + html: "

Test

", + url: "https://www.example.com", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 44, + external_id: "abc1234", + created_at: 1734537273, + updated_at: 1734537274, + last_ingested_at: 1734537274, + }; + server + .mockEndpoint() + .post("/ai/external_pages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.aiContent.createExternalPage({ + title: "Test", + html: "

Test

", + url: "https://www.example.com", + source_id: 44, + external_id: "abc1234", + }); + expect(response).toEqual({ + type: "external_page", + id: "21", + title: "Test", + html: "

Test

", + url: "https://www.example.com", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 44, + external_id: "abc1234", + created_at: 1734537273, + updated_at: 1734537274, + last_ingested_at: 1734537274, + }); + }); + + test("createExternalPage (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "title", html: "html", locale: "en", source_id: 1, external_id: "external_id" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/ai/external_pages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.aiContent.createExternalPage({ + title: "title", + html: "html", + source_id: 1, + external_id: "external_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("getExternalPage (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "external_page", + id: "23", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/6", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 46, + external_id: "5", + created_at: 1734537278, + updated_at: 1734537278, + last_ingested_at: 1734537278, + }; + server + .mockEndpoint() + .get("/ai/external_pages/id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.aiContent.getExternalPage({ + id: "id", + }); + expect(response).toEqual({ + type: "external_page", + id: "23", + title: "My External Content", + html: "

Hello world

This is external content

", + url: "https://support.example.com/us/6", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 46, + external_id: "5", + created_at: 1734537278, + updated_at: 1734537278, + last_ingested_at: 1734537278, + }); + }); + + test("getExternalPage (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/ai/external_pages/id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.aiContent.getExternalPage({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("updateExternalPage (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Test", + html: "

Test

", + url: "https://www.example.com", + locale: "en", + source_id: 47, + external_id: "5678", + }; + const rawResponseBody = { + type: "external_page", + id: "24", + title: "Test", + html: "

Test

", + url: "https://www.example.com", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 47, + external_id: "5678", + created_at: 1734537280, + updated_at: 1734537281, + last_ingested_at: 1734537281, + }; + server + .mockEndpoint() + .put("/ai/external_pages/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.aiContent.updateExternalPage({ + id: "id", + title: "Test", + html: "

Test

", + url: "https://www.example.com", + source_id: 47, + external_id: "5678", + }); + expect(response).toEqual({ + type: "external_page", + id: "24", + title: "Test", + html: "

Test

", + url: "https://www.example.com", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 47, + external_id: "5678", + created_at: 1734537280, + updated_at: 1734537281, + last_ingested_at: 1734537281, + }); + }); + + test("updateExternalPage (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "title", html: "html", url: "url", locale: "en", source_id: 1 }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/ai/external_pages/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.aiContent.updateExternalPage({ + id: "id", + title: "title", + html: "html", + url: "url", + source_id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("deleteExternalPage (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "external_page", + id: "22", + title: "My External Content", + html: "", + url: "https://support.example.com/us/5", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 45, + external_id: "4", + created_at: 1734537276, + updated_at: 1734537276, + last_ingested_at: 1734537276, + }; + server + .mockEndpoint() + .delete("/ai/external_pages/id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.aiContent.deleteExternalPage({ + id: "id", + }); + expect(response).toEqual({ + type: "external_page", + id: "22", + title: "My External Content", + html: "", + url: "https://support.example.com/us/5", + ai_agent_availability: true, + ai_copilot_availability: true, + fin_availability: true, + locale: "en", + source_id: 45, + external_id: "4", + created_at: 1734537276, + updated_at: 1734537276, + last_ingested_at: 1734537276, + }); + }); + + test("deleteExternalPage (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/ai/external_pages/id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.aiContent.deleteExternalPage({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); +}); diff --git a/tests/wire/unstable/articles.test.ts b/tests/wire/unstable/articles.test.ts new file mode 100644 index 00000000..20562566 --- /dev/null +++ b/tests/wire/unstable/articles.test.ts @@ -0,0 +1,2141 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("ArticlesClient", () => { + test("listArticles (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 25, + total_pages: 1, + }, + total_count: 1, + data: [ + { + type: "article", + id: "39", + workspace_id: "this_is_an_id64_that_should_be_at_least_4", + title: "This is the article title", + description: "", + body: "", + author_id: 991267492, + state: "published", + created_at: 1734537283, + updated_at: 1734537283, + url: "http://help-center.test/myapp-64/en/articles/39-this-is-the-article-title", + parent_id: 143, + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + }, + ], + }; + server.mockEndpoint().get("/articles").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.articles.listArticles(); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 25, + total_pages: 1, + }, + total_count: 1, + data: [ + { + type: "article", + id: "39", + workspace_id: "this_is_an_id64_that_should_be_at_least_4", + title: "This is the article title", + description: "", + body: "", + author_id: 991267492, + state: "published", + created_at: 1734537283, + updated_at: 1734537283, + url: "http://help-center.test/myapp-64/en/articles/39-this-is-the-article-title", + parent_id: 143, + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + }, + ], + }); + }); + + test("listArticles (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/articles").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.articles.listArticles(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createArticle (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { + statistics: { + type: "article_statistics", + views: 1, + conversions: 1, + reactions: 1, + happy_reaction_percentage: 1.1, + neutral_reaction_percentage: 1.1, + sad_reaction_percentage: 1.1, + }, + type: "article", + id: "id", + workspace_id: "workspace_id", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + parent_id: 1, + parent_ids: [1, 1], + parent_type: "parent_type", + default_locale: "default_locale", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + bg: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + bs: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ca: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + cs: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + da: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + de: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + el: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + en: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + es: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + et: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + fi: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + fr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + he: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + hr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + hu: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + id: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + it: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ja: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ko: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + lt: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + lv: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + mn: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + nb: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + nl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + pl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + pt: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ro: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ru: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sv: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + tr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + vi: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "pt-BR": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "zh-CN": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "zh-TW": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + }, + }; + server + .mockEndpoint() + .post("/articles") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.articles.createArticle({ + key: "value", + }); + expect(response).toEqual({ + statistics: { + type: "article_statistics", + views: 1, + conversions: 1, + reactions: 1, + happy_reaction_percentage: 1.1, + neutral_reaction_percentage: 1.1, + sad_reaction_percentage: 1.1, + }, + type: "article", + id: "id", + workspace_id: "workspace_id", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + parent_id: 1, + parent_ids: [1, 1], + parent_type: "parent_type", + default_locale: "default_locale", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + bg: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + bs: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ca: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + cs: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + da: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + de: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + el: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + en: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + es: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + et: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + fi: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + fr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + he: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + hr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + hu: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + id: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + it: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ja: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ko: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + lt: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + lv: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + mn: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + nb: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + nl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + pl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + pt: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ro: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + ru: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sl: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + sv: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + tr: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + vi: { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "pt-BR": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "zh-CN": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + "zh-TW": { + type: "article_content", + title: "title", + description: "description", + body: "body", + author_id: 1, + state: "published", + created_at: 1, + updated_at: 1, + url: "url", + }, + }, + }); + }); + + test("createArticle (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/articles") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.articles.createArticle({ + key: "value", + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("createArticle (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/articles") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.articles.createArticle({ + key: "value", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveArticle (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "article", + id: "45", + workspace_id: "this_is_an_id74_that_should_be_at_least_4", + title: "This is the article title", + description: "", + body: "", + author_id: 991267502, + state: "published", + created_at: 1734537292, + updated_at: 1734537292, + url: "http://help-center.test/myapp-74/en/articles/45-this-is-the-article-title", + parent_id: 148, + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bg: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ca: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + cs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + da: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + de: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + el: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + en: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + es: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + et: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + he: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hu: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + id: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + it: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ja: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ko: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + mn: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nb: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ro: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ru: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + tr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + vi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "pt-BR": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-CN": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-TW": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + }, + statistics: { + type: "article_statistics", + views: 0, + conversions: 0, + reactions: 0, + happy_reaction_percentage: 0, + neutral_reaction_percentage: 0, + sad_reaction_percentage: 0, + }, + }; + server.mockEndpoint().get("/articles/1").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.articles.retrieveArticle({ + id: 1, + }); + expect(response).toEqual({ + type: "article", + id: "45", + workspace_id: "this_is_an_id74_that_should_be_at_least_4", + title: "This is the article title", + description: "", + body: "", + author_id: 991267502, + state: "published", + created_at: 1734537292, + updated_at: 1734537292, + url: "http://help-center.test/myapp-74/en/articles/45-this-is-the-article-title", + parent_id: 148, + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + translated_content: { + type: "article_translated_content", + ar: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bg: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + bs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ca: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + cs: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + da: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + de: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + el: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + en: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + es: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + et: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + fr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + he: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + hu: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + id: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + it: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ja: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ko: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + lv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + mn: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nb: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + nl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + pt: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ro: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + ru: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sl: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + sv: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + tr: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + vi: { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "pt-BR": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-CN": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + "zh-TW": { + type: "article_content", + title: "How to create a new article", + description: "This article will show you how to create a new article.", + body: "This is the body of the article.", + author_id: 1, + state: "published", + created_at: 1663597223, + updated_at: 1663597260, + url: "http://intercom.test/help/en/articles/3-default-language", + }, + }, + statistics: { + type: "article_statistics", + views: 0, + conversions: 0, + reactions: 0, + happy_reaction_percentage: 0, + neutral_reaction_percentage: 0, + sad_reaction_percentage: 0, + }, + }); + }); + + test("retrieveArticle (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/articles/1").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.articles.retrieveArticle({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveArticle (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/articles/1").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.articles.retrieveArticle({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("deleteArticle (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { id: "51", object: "article", deleted: true }; + server.mockEndpoint().delete("/articles/1").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.articles.deleteArticle({ + id: 1, + }); + expect(response).toEqual({ + id: "51", + object: "article", + deleted: true, + }); + }); + + test("deleteArticle (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().delete("/articles/1").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.articles.deleteArticle({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("deleteArticle (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().delete("/articles/1").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.articles.deleteArticle({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("searchArticles (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + total_count: 1, + data: { + articles: [ + { + type: "article", + id: "55", + workspace_id: "this_is_an_id92_that_should_be_at_least_4", + title: "Title 1", + description: "", + body: "", + author_id: 991267521, + state: "draft", + created_at: 1734537306, + updated_at: 1734537306, + url: "http://intercom.test/help/en/articles/3-default-language", + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + }, + ], + highlights: [{ article_id: "123" }], + }, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 10, + total_pages: 1, + }, + }; + server.mockEndpoint().get("/articles/search").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.articles.searchArticles({ + phrase: "Getting started", + state: "published", + help_center_id: 1, + highlight: true, + }); + expect(response).toEqual({ + type: "list", + total_count: 1, + data: { + articles: [ + { + type: "article", + id: "55", + workspace_id: "this_is_an_id92_that_should_be_at_least_4", + title: "Title 1", + description: "", + body: "", + author_id: 991267521, + state: "draft", + created_at: 1734537306, + updated_at: 1734537306, + url: "http://intercom.test/help/en/articles/3-default-language", + parent_ids: [18, 19], + parent_type: "collection", + default_locale: "en", + }, + ], + highlights: [ + { + article_id: "123", + }, + ], + }, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 10, + total_pages: 1, + }, + }); + }); + + test("searchArticles (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/articles/search").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.articles.searchArticles(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); +}); diff --git a/tests/wire/unstable/awayStatusReasons.test.ts b/tests/wire/unstable/awayStatusReasons.test.ts new file mode 100644 index 00000000..f0416817 --- /dev/null +++ b/tests/wire/unstable/awayStatusReasons.test.ts @@ -0,0 +1,74 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("AwayStatusReasonsClient", () => { + test("listAwayStatusReasons (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = [ + { + type: "away_status_reason", + id: "id", + label: "On a break", + emoji: "☕", + order: 1, + deleted: false, + created_at: 1734537243, + updated_at: 1734537243, + }, + ]; + server + .mockEndpoint() + .get("/away_status_reasons") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.awayStatusReasons.listAwayStatusReasons(); + expect(response).toEqual([ + { + type: "away_status_reason", + id: "id", + label: "On a break", + emoji: "\u2615", + order: 1, + deleted: false, + created_at: 1734537243, + updated_at: 1734537243, + }, + ]); + }); + + test("listAwayStatusReasons (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/away_status_reasons") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.awayStatusReasons.listAwayStatusReasons(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); +}); diff --git a/tests/wire/unstable/brands.test.ts b/tests/wire/unstable/brands.test.ts new file mode 100644 index 00000000..5dfe7df0 --- /dev/null +++ b/tests/wire/unstable/brands.test.ts @@ -0,0 +1,162 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("BrandsClient", () => { + test("listBrands (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "brand", + id: "tlkp1d91", + name: "Default Brand", + is_default: true, + created_at: 1673778600, + updated_at: 1711031100, + help_center_id: "11", + default_address_settings_id: "13", + }, + { + type: "brand", + id: "3", + name: "Premium Brand", + is_default: false, + created_at: 1686387300, + updated_at: 1709229600, + help_center_id: "10", + default_address_settings_id: "15", + }, + ], + }; + server.mockEndpoint().get("/brands").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.brands.listBrands(); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "brand", + id: "tlkp1d91", + name: "Default Brand", + is_default: true, + created_at: 1673778600, + updated_at: 1711031100, + help_center_id: "11", + default_address_settings_id: "13", + }, + { + type: "brand", + id: "3", + name: "Premium Brand", + is_default: false, + created_at: 1686387300, + updated_at: 1709229600, + help_center_id: "10", + default_address_settings_id: "15", + }, + ], + }); + }); + + test("listBrands (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/brands").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.brands.listBrands(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveBrand (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "brand", + id: "15", + name: "Premium Brand", + is_default: false, + created_at: 1686387300, + updated_at: 1709229600, + help_center_id: "20", + default_address_settings_id: "15", + }; + server.mockEndpoint().get("/brands/id").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.brands.retrieveBrand({ + id: "id", + }); + expect(response).toEqual({ + type: "brand", + id: "15", + name: "Premium Brand", + is_default: false, + created_at: 1686387300, + updated_at: 1709229600, + help_center_id: "20", + default_address_settings_id: "15", + }); + }); + + test("retrieveBrand (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/brands/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.brands.retrieveBrand({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveBrand (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/brands/id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.brands.retrieveBrand({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); +}); diff --git a/tests/wire/unstable/calls.test.ts b/tests/wire/unstable/calls.test.ts new file mode 100644 index 00000000..4840a470 --- /dev/null +++ b/tests/wire/unstable/calls.test.ts @@ -0,0 +1,758 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("CallsClient", () => { + test("listCalls (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "call", + id: "123", + conversation_id: "456", + admin_id: "789", + contact_id: "6762f0dd1bb69f9f2193bb83", + state: "completed", + initiated_at: "2024-01-15T09:30:00Z", + answered_at: "2024-01-15T09:30:00Z", + ended_at: "2024-01-15T09:30:00Z", + created_at: "2024-01-15T09:30:00Z", + updated_at: "2024-01-15T09:30:00Z", + recording_url: "https://api.intercom.io/calls/123/recording", + transcription_url: "https://api.intercom.io/calls/123/transcript", + call_type: "phone", + direction: "outbound", + ended_reason: "completed", + phone: "+15551234567", + fin_recording_url: "fin_recording_url", + fin_transcription_url: "fin_transcription_url", + }, + ], + total_count: 0, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 25, + total_pages: 0, + }, + }; + server.mockEndpoint().get("/calls").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.calls.listCalls({ + page: 1, + per_page: 1, + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "call", + id: "123", + conversation_id: "456", + admin_id: "789", + contact_id: "6762f0dd1bb69f9f2193bb83", + state: "completed", + initiated_at: "2024-01-15T09:30:00Z", + answered_at: "2024-01-15T09:30:00Z", + ended_at: "2024-01-15T09:30:00Z", + created_at: "2024-01-15T09:30:00Z", + updated_at: "2024-01-15T09:30:00Z", + recording_url: "https://api.intercom.io/calls/123/recording", + transcription_url: "https://api.intercom.io/calls/123/transcript", + call_type: "phone", + direction: "outbound", + ended_reason: "completed", + phone: "+15551234567", + fin_recording_url: "fin_recording_url", + fin_transcription_url: "fin_transcription_url", + }, + ], + total_count: 0, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 25, + total_pages: 0, + }, + }); + }); + + test("listCalls (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/calls").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.calls.listCalls(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("showCall (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "call", + id: "123", + conversation_id: "456", + admin_id: "789", + contact_id: "6762f0dd1bb69f9f2193bb83", + state: "completed", + initiated_at: 1734537437, + answered_at: 1734537440, + ended_at: 1734537530, + created_at: 1734537437, + updated_at: 1734537531, + recording_url: "https://api.intercom.io/calls/123/recording", + transcription_url: "https://api.intercom.io/calls/123/transcript", + call_type: "phone", + direction: "outbound", + ended_reason: "answered", + phone: "+15551234567", + fin_recording_url: "https://api.intercom.io/calls/124/recording", + fin_transcription_url: "https://api.intercom.io/calls/124/transcript", + }; + server.mockEndpoint().get("/calls/id").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.calls.showCall({ + id: "id", + }); + expect(response).toEqual({ + type: "call", + id: "123", + conversation_id: "456", + admin_id: "789", + contact_id: "6762f0dd1bb69f9f2193bb83", + state: "completed", + initiated_at: 1734537437, + answered_at: 1734537440, + ended_at: 1734537530, + created_at: 1734537437, + updated_at: 1734537531, + recording_url: "https://api.intercom.io/calls/123/recording", + transcription_url: "https://api.intercom.io/calls/123/transcript", + call_type: "phone", + direction: "outbound", + ended_reason: "answered", + phone: "+15551234567", + fin_recording_url: "https://api.intercom.io/calls/124/recording", + fin_transcription_url: "https://api.intercom.io/calls/124/transcript", + }); + }); + + test("showCall (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/calls/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.calls.showCall({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("showCall (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/calls/id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.calls.showCall({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("showCallRecording (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + server.mockEndpoint().get("/calls/id/recording").respondWith().statusCode(200).build(); + + const response = await client.unstable.calls.showCallRecording({ + id: "id", + }); + expect(response).toEqual(undefined); + }); + + test("showCallRecording (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/calls/id/recording") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.calls.showCallRecording({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("showCallRecording (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/calls/id/recording") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.calls.showCallRecording({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("listCallsWithTranscripts (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { conversation_ids: ["64619700005694", "64619700005695"] }; + const rawResponseBody = { + type: "list", + data: [ + { + type: "call", + id: "123", + conversation_id: "64619700005694", + admin_id: "789", + contact_id: "6762f0dd1bb69f9f2193bb83", + state: "completed", + initiated_at: "2024-01-15T09:30:00Z", + answered_at: "2024-01-15T09:30:00Z", + ended_at: "2024-01-15T09:30:00Z", + created_at: "2024-01-15T09:30:00Z", + updated_at: "2024-01-15T09:30:00Z", + recording_url: "https://api.intercom.io/calls/123/recording", + transcription_url: "https://api.intercom.io/calls/123/transcript", + call_type: "phone", + direction: "outbound", + ended_reason: "completed", + phone: "+15551234567", + fin_recording_url: "fin_recording_url", + fin_transcription_url: "fin_transcription_url", + transcript: [{ key: "value" }], + transcript_status: "completed", + }, + ], + }; + server + .mockEndpoint() + .post("/calls/search") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.calls.listCallsWithTranscripts({ + conversation_ids: ["64619700005694", "64619700005695"], + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "call", + id: "123", + conversation_id: "64619700005694", + admin_id: "789", + contact_id: "6762f0dd1bb69f9f2193bb83", + state: "completed", + initiated_at: "2024-01-15T09:30:00Z", + answered_at: "2024-01-15T09:30:00Z", + ended_at: "2024-01-15T09:30:00Z", + created_at: "2024-01-15T09:30:00Z", + updated_at: "2024-01-15T09:30:00Z", + recording_url: "https://api.intercom.io/calls/123/recording", + transcription_url: "https://api.intercom.io/calls/123/transcript", + call_type: "phone", + direction: "outbound", + ended_reason: "completed", + phone: "+15551234567", + fin_recording_url: "fin_recording_url", + fin_transcription_url: "fin_transcription_url", + transcript: [ + { + key: "value", + }, + ], + transcript_status: "completed", + }, + ], + }); + }); + + test("listCallsWithTranscripts (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { conversation_ids: ["conversation_ids", "conversation_ids"] }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/calls/search") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.calls.listCallsWithTranscripts({ + conversation_ids: ["conversation_ids", "conversation_ids"], + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("listCallsWithTranscripts (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { conversation_ids: ["conversation_ids", "conversation_ids"] }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/calls/search") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.calls.listCallsWithTranscripts({ + conversation_ids: ["conversation_ids", "conversation_ids"], + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("registerFinVoiceCall (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { phone_number: "+1234567890", call_id: "call-123-abc" }; + const rawResponseBody = { + id: 12345, + app_id: 12345, + user_phone_number: "+1234567890", + status: "registered", + intercom_call_id: "1234", + external_call_id: "call-123-abc", + intercom_conversation_id: "5678", + call_transcript: [{ key: "value" }], + call_summary: "Customer called about billing issue...", + intent: [{ key: "value" }], + }; + server + .mockEndpoint() + .post("/fin_voice/register") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.calls.registerFinVoiceCall({ + phone_number: "+1234567890", + call_id: "call-123-abc", + }); + expect(response).toEqual({ + id: 12345, + app_id: 12345, + user_phone_number: "+1234567890", + status: "registered", + intercom_call_id: "1234", + external_call_id: "call-123-abc", + intercom_conversation_id: "5678", + call_transcript: [ + { + key: "value", + }, + ], + call_summary: "Customer called about billing issue...", + intent: [ + { + key: "value", + }, + ], + }); + }); + + test("registerFinVoiceCall (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/fin_voice/register") + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.calls.registerFinVoiceCall(undefined); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("registerFinVoiceCall (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/fin_voice/register") + .respondWith() + .statusCode(409) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.calls.registerFinVoiceCall(undefined); + }).rejects.toThrow(Intercom.unstable.ConflictError); + }); + + test("collectFinVoiceCallById (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + id: 12345, + app_id: 12345, + user_phone_number: "+1234567890", + status: "registered", + intercom_call_id: "1234", + external_call_id: "call-123-abc", + intercom_conversation_id: "5678", + call_transcript: [{ key: "value" }], + call_summary: "Customer called about billing issue...", + intent: [{ key: "value" }], + }; + server + .mockEndpoint() + .get("/fin_voice/collect/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.calls.collectFinVoiceCallById({ + id: 1, + }); + expect(response).toEqual({ + id: 12345, + app_id: 12345, + user_phone_number: "+1234567890", + status: "registered", + intercom_call_id: "1234", + external_call_id: "call-123-abc", + intercom_conversation_id: "5678", + call_transcript: [ + { + key: "value", + }, + ], + call_summary: "Customer called about billing issue...", + intent: [ + { + key: "value", + }, + ], + }); + }); + + test("collectFinVoiceCallById (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/fin_voice/collect/1") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.calls.collectFinVoiceCallById({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("collectFinVoiceCallByExternalId (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + id: 12345, + app_id: 12345, + user_phone_number: "+1234567890", + status: "registered", + intercom_call_id: "1234", + external_call_id: "call-123-abc", + intercom_conversation_id: "5678", + call_transcript: [{ key: "value" }], + call_summary: "Customer called about billing issue...", + intent: [{ key: "value" }], + }; + server + .mockEndpoint() + .get("/fin_voice/external_id/external_id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.calls.collectFinVoiceCallByExternalId({ + external_id: "external_id", + }); + expect(response).toEqual({ + id: 12345, + app_id: 12345, + user_phone_number: "+1234567890", + status: "registered", + intercom_call_id: "1234", + external_call_id: "call-123-abc", + intercom_conversation_id: "5678", + call_transcript: [ + { + key: "value", + }, + ], + call_summary: "Customer called about billing issue...", + intent: [ + { + key: "value", + }, + ], + }); + }); + + test("collectFinVoiceCallByExternalId (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/fin_voice/external_id/external_id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.calls.collectFinVoiceCallByExternalId({ + external_id: "external_id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("collectFinVoiceCallByPhoneNumber (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "error.list", + request_id: "f93ecfa8-d08a-4325-8694-89aeb89c8f85", + errors: [{ code: "unauthorized", message: "Access Token Invalid", field: "email" }], + }; + server + .mockEndpoint() + .get("/fin_voice/phone_number/phone_number") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.calls.collectFinVoiceCallByPhoneNumber({ + phone_number: "phone_number", + }); + expect(response).toEqual({ + type: "error.list", + request_id: "f93ecfa8-d08a-4325-8694-89aeb89c8f85", + errors: [ + { + code: "unauthorized", + message: "Access Token Invalid", + field: "email", + }, + ], + }); + }); + + test("collectFinVoiceCallByPhoneNumber (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/fin_voice/phone_number/phone_number") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.calls.collectFinVoiceCallByPhoneNumber({ + phone_number: "phone_number", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("collectFinVoiceCallByPhoneNumber (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/fin_voice/phone_number/phone_number") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.calls.collectFinVoiceCallByPhoneNumber({ + phone_number: "phone_number", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); +}); diff --git a/tests/wire/unstable/companies.test.ts b/tests/wire/unstable/companies.test.ts new file mode 100644 index 00000000..646e1411 --- /dev/null +++ b/tests/wire/unstable/companies.test.ts @@ -0,0 +1,2011 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("CompaniesClient", () => { + test("retrieveCompany (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 15, + total_pages: 1, + }, + total_count: 1, + data: [ + { + type: "company", + id: "6762f07a1bb69f9f2193baea", + name: "IntercomQATest1", + app_id: "this_is_an_id153_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "remote_companies_scroll_2", + remote_created_at: 1734537338, + created_at: 1734537338, + updated_at: 1734537338, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 4, + custom_attributes: { key: "value" }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { type: "note.list" }, + }, + ], + }; + server.mockEndpoint().get("/companies").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.companies.retrieveCompany({ + name: "my company", + company_id: "12345", + tag_id: "678910", + segment_id: "98765", + page: 1, + per_page: 1, + }); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 15, + total_pages: 1, + }, + total_count: 1, + data: [ + { + type: "company", + id: "6762f07a1bb69f9f2193baea", + name: "IntercomQATest1", + app_id: "this_is_an_id153_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "remote_companies_scroll_2", + remote_created_at: 1734537338, + created_at: 1734537338, + updated_at: 1734537338, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 4, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + }, + }, + ], + }); + }); + + test("retrieveCompany (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/companies").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.companies.retrieveCompany(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveCompany (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/companies").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.companies.retrieveCompany(); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("createOrUpdateCompany (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { + type: "company", + id: "id", + name: "name", + app_id: "app_id", + plan: { type: "type", id: "id", name: "name" }, + company_id: "company_id", + remote_created_at: 1, + created_at: 1, + updated_at: 1, + last_request_at: 1, + size: 1, + website: "website", + industry: "industry", + monthly_spend: 1, + session_count: 1, + user_count: 1, + custom_attributes: { custom_attributes: "custom_attributes" }, + tags: { type: "tag.list", tags: [{ key: "value" }, { key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + type: "segment", + id: "id", + name: "name", + created_at: 1, + updated_at: 1, + person_type: "contact", + count: 1, + }, + { + type: "segment", + id: "id", + name: "name", + created_at: 1, + updated_at: 1, + person_type: "contact", + count: 1, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "type", + id: "id", + created_at: 1, + company: { type: "type", id: "id" }, + author: { + type: "type", + id: "id", + name: "name", + email: "email", + job_title: "job_title", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 1, + has_inbox_seat: true, + team_ids: [1, 1], + avatar: "avatar", + team_priority_level: {}, + }, + body: "body", + }, + { + type: "type", + id: "id", + created_at: 1, + company: { type: "type", id: "id" }, + author: { + type: "type", + id: "id", + name: "name", + email: "email", + job_title: "job_title", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 1, + has_inbox_seat: true, + team_ids: [1, 1], + avatar: "avatar", + team_priority_level: {}, + }, + body: "body", + }, + ], + }, + }; + server + .mockEndpoint() + .post("/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.companies.createOrUpdateCompany({ + key: "value", + }); + expect(response).toEqual({ + type: "company", + id: "id", + name: "name", + app_id: "app_id", + plan: { + type: "type", + id: "id", + name: "name", + }, + company_id: "company_id", + remote_created_at: 1, + created_at: 1, + updated_at: 1, + last_request_at: 1, + size: 1, + website: "website", + industry: "industry", + monthly_spend: 1, + session_count: 1, + user_count: 1, + custom_attributes: { + custom_attributes: "custom_attributes", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + type: "segment", + id: "id", + name: "name", + created_at: 1, + updated_at: 1, + person_type: "contact", + count: 1, + }, + { + type: "segment", + id: "id", + name: "name", + created_at: 1, + updated_at: 1, + person_type: "contact", + count: 1, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "type", + id: "id", + created_at: 1, + company: { + type: "type", + id: "id", + }, + author: { + type: "type", + id: "id", + name: "name", + email: "email", + job_title: "job_title", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 1, + has_inbox_seat: true, + team_ids: [1, 1], + avatar: "avatar", + team_priority_level: {}, + }, + body: "body", + }, + { + type: "type", + id: "id", + created_at: 1, + company: { + type: "type", + id: "id", + }, + author: { + type: "type", + id: "id", + name: "name", + email: "email", + job_title: "job_title", + away_mode_enabled: true, + away_mode_reassign: true, + away_status_reason_id: 1, + has_inbox_seat: true, + team_ids: [1, 1], + avatar: "avatar", + team_priority_level: {}, + }, + body: "body", + }, + ], + }, + }); + }); + + test("createOrUpdateCompany (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.companies.createOrUpdateCompany({ + key: "value", + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("createOrUpdateCompany (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.companies.createOrUpdateCompany({ + key: "value", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("RetrieveACompanyById (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "company", + id: "6762f07f1bb69f9f2193baf5", + name: "company1", + app_id: "this_is_an_id159_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "1", + remote_created_at: 1734537343, + created_at: 1734537343, + updated_at: 1734537343, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { key: "value" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [{ type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }], + }, + }; + server + .mockEndpoint() + .get("/companies/5f4d3c1c-7b1b-4d7d-a97e-6095715c6632") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.companies.retrieveACompanyById({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + }); + expect(response).toEqual({ + type: "company", + id: "6762f07f1bb69f9f2193baf5", + name: "company1", + app_id: "this_is_an_id159_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "1", + remote_created_at: 1734537343, + created_at: 1734537343, + updated_at: 1734537343, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }); + }); + + test("RetrieveACompanyById (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/companies/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.companies.retrieveACompanyById({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("RetrieveACompanyById (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/companies/id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.companies.retrieveACompanyById({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("UpdateCompany (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "company", + id: "6762f0841bb69f9f2193baff", + name: "company2", + app_id: "this_is_an_id165_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "1", + remote_created_at: 1734537348, + created_at: 1734537348, + updated_at: 1734537348, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { key: "value" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [{ type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }], + }, + }; + server + .mockEndpoint() + .put("/companies/5f4d3c1c-7b1b-4d7d-a97e-6095715c6632") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.companies.updateCompany({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + }); + expect(response).toEqual({ + type: "company", + id: "6762f0841bb69f9f2193baff", + name: "company2", + app_id: "this_is_an_id165_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "1", + remote_created_at: 1734537348, + created_at: 1734537348, + updated_at: 1734537348, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }); + }); + + test("UpdateCompany (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().put("/companies/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.companies.updateCompany({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("UpdateCompany (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().put("/companies/id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.companies.updateCompany({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("deleteCompany (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { id: "6762f0881bb69f9f2193bb09", object: "company", deleted: true }; + server + .mockEndpoint() + .delete("/companies/5f4d3c1c-7b1b-4d7d-a97e-6095715c6632") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.companies.deleteCompany({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + }); + expect(response).toEqual({ + id: "6762f0881bb69f9f2193bb09", + object: "company", + deleted: true, + }); + }); + + test("deleteCompany (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().delete("/companies/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.companies.deleteCompany({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("deleteCompany (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().delete("/companies/id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.companies.deleteCompany({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("ListAttachedContacts (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "ecahpwf5", + role: "user", + email: "joe@example.com", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: true, + marked_email_as_spam: true, + unsubscribed_from_emails: true, + created_at: 1571672154, + updated_at: 1571672154, + signed_up_at: 1571672154, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: { type: "avatar", image_url: "https://example.org/128Wash.jpg" }, + tags: { url: "/contacts/5ba682d23d7cf92bef87bfd4/tags", total_count: 100, has_more: true }, + notes: { url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", total_count: 100, has_more: true }, + companies: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/companies", + total_count: 100, + has_more: true, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + }, + ], + total_count: 0, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 50, + total_pages: 0, + }, + }; + server + .mockEndpoint() + .get("/companies/5f4d3c1c-7b1b-4d7d-a97e-6095715c6632/contacts") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.companies.listAttachedContacts({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "ecahpwf5", + role: "user", + email: "joe@example.com", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: true, + marked_email_as_spam: true, + unsubscribed_from_emails: true, + created_at: 1571672154, + updated_at: 1571672154, + signed_up_at: 1571672154, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: { + type: "avatar", + image_url: "https://example.org/128Wash.jpg", + }, + tags: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/tags", + total_count: 100, + has_more: true, + }, + notes: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + total_count: 100, + has_more: true, + }, + companies: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/companies", + total_count: 100, + has_more: true, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + }, + ], + total_count: 0, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 50, + total_pages: 0, + }, + }); + }); + + test("ListAttachedContacts (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/companies/id/contacts") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.companies.listAttachedContacts({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("ListAttachedContacts (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/companies/id/contacts") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.companies.listAttachedContacts({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("ListAttachedSegmentsForCompanies (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "segment", + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + person_type: "contact", + count: 3, + }, + ], + }; + server + .mockEndpoint() + .get("/companies/5f4d3c1c-7b1b-4d7d-a97e-6095715c6632/segments") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.companies.listAttachedSegmentsForCompanies({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "segment", + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + person_type: "contact", + count: 3, + }, + ], + }); + }); + + test("ListAttachedSegmentsForCompanies (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/companies/id/segments") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.companies.listAttachedSegmentsForCompanies({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("ListAttachedSegmentsForCompanies (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/companies/id/segments") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.companies.listAttachedSegmentsForCompanies({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("listAllCompanies (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 15, + total_pages: 1, + }, + total_count: 1, + data: [ + { + type: "company", + id: "6762f0941bb69f9f2193bb25", + name: "IntercomQATest1", + app_id: "this_is_an_id189_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "remote_companies_scroll_2", + remote_created_at: 1734537364, + created_at: 1734537364, + updated_at: 1734537364, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 4, + custom_attributes: { key: "value" }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { type: "note.list" }, + }, + ], + }; + server.mockEndpoint().post("/companies/list").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.companies.listAllCompanies({ + page: 1, + per_page: 1, + order: "desc", + }); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 15, + total_pages: 1, + }, + total_count: 1, + data: [ + { + type: "company", + id: "6762f0941bb69f9f2193bb25", + name: "IntercomQATest1", + app_id: "this_is_an_id189_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "remote_companies_scroll_2", + remote_created_at: 1734537364, + created_at: 1734537364, + updated_at: 1734537364, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 4, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + }, + }, + ], + }); + }); + + test("listAllCompanies (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().post("/companies/list").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.companies.listAllCompanies(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("scrollOverAllCompanies (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "company", + id: "6762f0971bb69f9f2193bb2b", + name: "IntercomQATest1", + app_id: "this_is_an_id193_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "remote_companies_scroll_2", + remote_created_at: 1734537367, + created_at: 1734537367, + updated_at: 1734537367, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 4, + custom_attributes: { key: "value" }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { type: "note.list" }, + }, + ], + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 2, + total_pages: 13, + }, + total_count: 100, + scroll_param: "69352cd2-ab5b-42ac-b004-a13d4e55e9b0", + }; + server.mockEndpoint().get("/companies/scroll").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.companies.scrollOverAllCompanies({ + scroll_param: "scroll_param", + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "company", + id: "6762f0971bb69f9f2193bb2b", + name: "IntercomQATest1", + app_id: "this_is_an_id193_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "remote_companies_scroll_2", + remote_created_at: 1734537367, + created_at: 1734537367, + updated_at: 1734537367, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 4, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + }, + }, + ], + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 2, + total_pages: 13, + }, + total_count: 100, + scroll_param: "69352cd2-ab5b-42ac-b004-a13d4e55e9b0", + }); + }); + + test("scrollOverAllCompanies (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/companies/scroll").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.companies.scrollOverAllCompanies(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("attachContactToACompany (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { company_id: "6762f09a1bb69f9f2193bb34" }; + const rawResponseBody = { + type: "company", + id: "6762f09a1bb69f9f2193bb34", + name: "company6", + app_id: "this_is_an_id197_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "1", + remote_created_at: 1734537370, + created_at: 1734537370, + updated_at: 1734537370, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { key: "value" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [{ type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }], + }, + }; + server + .mockEndpoint() + .post("/contacts/id/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.companies.attachContactToACompany({ + id: "id", + company_id: "6762f09a1bb69f9f2193bb34", + }); + expect(response).toEqual({ + type: "company", + id: "6762f09a1bb69f9f2193bb34", + name: "company6", + app_id: "this_is_an_id197_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "1", + remote_created_at: 1734537370, + created_at: 1734537370, + updated_at: 1734537370, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }); + }); + + test("attachContactToACompany (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { company_id: "58a430d35458202d41b1e65b" }; + const rawResponseBody = { + type: "company", + id: "6762f09a1bb69f9f2193bb34", + name: "company6", + app_id: "this_is_an_id197_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "1", + remote_created_at: 1734537370, + created_at: 1734537370, + updated_at: 1734537370, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { key: "value" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [{ type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }], + }, + }; + server + .mockEndpoint() + .post("/contacts/id/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.companies.attachContactToACompany({ + id: "id", + company_id: "58a430d35458202d41b1e65b", + }); + expect(response).toEqual({ + type: "company", + id: "6762f09a1bb69f9f2193bb34", + name: "company6", + app_id: "this_is_an_id197_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "1", + remote_created_at: 1734537370, + created_at: 1734537370, + updated_at: 1734537370, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }); + }); + + test("attachContactToACompany (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { company_id: "123" }; + const rawResponseBody = { + type: "company", + id: "6762f09a1bb69f9f2193bb34", + name: "company6", + app_id: "this_is_an_id197_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "1", + remote_created_at: 1734537370, + created_at: 1734537370, + updated_at: 1734537370, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { key: "value" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [{ type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }], + }, + }; + server + .mockEndpoint() + .post("/contacts/id/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.companies.attachContactToACompany({ + id: "id", + company_id: "123", + }); + expect(response).toEqual({ + type: "company", + id: "6762f09a1bb69f9f2193bb34", + name: "company6", + app_id: "this_is_an_id197_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "1", + remote_created_at: 1734537370, + created_at: 1734537370, + updated_at: 1734537370, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 1, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }); + }); + + test("attachContactToACompany (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { company_id: "company_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/contacts/id/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.companies.attachContactToACompany({ + id: "id", + company_id: "company_id", + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("attachContactToACompany (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { company_id: "company_id" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/contacts/id/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.companies.attachContactToACompany({ + id: "id", + company_id: "company_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("attachContactToACompany (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { company_id: "company_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/contacts/id/companies") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.companies.attachContactToACompany({ + id: "id", + company_id: "company_id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("detachContactFromACompany (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "company", + id: "6762f0a01bb69f9f2193bb44", + name: "company8", + app_id: "this_is_an_id205_that_should_be_at_least_", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "1", + remote_created_at: 1734537376, + created_at: 1734537376, + updated_at: 1734537377, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 0, + custom_attributes: { key: "value" }, + tags: { type: "tag.list", tags: [{ key: "value" }] }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [{ type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }], + }, + }; + server + .mockEndpoint() + .delete("/contacts/58a430d35458202d41b1e65b/companies/58a430d35458202d41b1e65b") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.companies.detachContactFromACompany({ + contact_id: "58a430d35458202d41b1e65b", + id: "58a430d35458202d41b1e65b", + }); + expect(response).toEqual({ + type: "company", + id: "6762f0a01bb69f9f2193bb44", + name: "company8", + app_id: "this_is_an_id205_that_should_be_at_least_", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "1", + remote_created_at: 1734537376, + created_at: 1734537376, + updated_at: 1734537377, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 0, + session_count: 0, + user_count: 0, + custom_attributes: { + key: "value", + }, + tags: { + type: "tag.list", + tags: [ + { + key: "value", + }, + ], + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }); + }); + + test("detachContactFromACompany (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/contacts/contact_id/companies/id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.companies.detachContactFromACompany({ + contact_id: "contact_id", + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("detachContactFromACompany (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/contacts/contact_id/companies/id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.companies.detachContactFromACompany({ + contact_id: "contact_id", + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); +}); diff --git a/tests/wire/unstable/contacts.test.ts b/tests/wire/unstable/contacts.test.ts new file mode 100644 index 00000000..4893898e --- /dev/null +++ b/tests/wire/unstable/contacts.test.ts @@ -0,0 +1,2297 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("ContactsClient", () => { + test("listCompaniesForAContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + companies: [ + { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + }, + ], + total_count: 1, + pages: { type: "pages", page: 1, next: "next", per_page: 50, total_pages: 1 }, + }; + server + .mockEndpoint() + .get("/contacts/63a07ddf05a32042dffac965/companies") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.contacts.listCompaniesForAContact({ + id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "list", + companies: [ + { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: "next", + per_page: 50, + total_pages: 1, + }, + }); + }); + + test("listCompaniesForAContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/contacts/id/companies") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.contacts.listCompaniesForAContact({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("listCompaniesForAContact (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/contacts/id/companies") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.contacts.listCompaniesForAContact({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("listSegmentsForAContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "segment", + id: "6762f0b21bb69f9f2193bb65", + name: "segment", + created_at: 1734537394, + updated_at: 1734537394, + person_type: "user", + count: 3, + }, + ], + }; + server + .mockEndpoint() + .get("/contacts/63a07ddf05a32042dffac965/segments") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.contacts.listSegmentsForAContact({ + contact_id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "segment", + id: "6762f0b21bb69f9f2193bb65", + name: "segment", + created_at: 1734537394, + updated_at: 1734537394, + person_type: "user", + count: 3, + }, + ], + }); + }); + + test("listSegmentsForAContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/contacts/contact_id/segments") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.contacts.listSegmentsForAContact({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("listSegmentsForAContact (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/contacts/contact_id/segments") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.contacts.listSegmentsForAContact({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("listSubscriptionsForAContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "subscription", + id: "91", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [{ name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }], + consent_type: "opt_out", + content_types: ["email"], + }, + { + type: "subscription", + id: "93", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [{ name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }], + consent_type: "opt_in", + content_types: ["sms_message"], + }, + ], + }; + server + .mockEndpoint() + .get("/contacts/63a07ddf05a32042dffac965/subscriptions") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.contacts.listSubscriptionsForAContact({ + contact_id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "subscription", + id: "91", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [ + { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + ], + consent_type: "opt_out", + content_types: ["email"], + }, + { + type: "subscription", + id: "93", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [ + { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + ], + consent_type: "opt_in", + content_types: ["sms_message"], + }, + ], + }); + }); + + test("listSubscriptionsForAContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/contacts/contact_id/subscriptions") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.contacts.listSubscriptionsForAContact({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("listSubscriptionsForAContact (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/contacts/contact_id/subscriptions") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.contacts.listSubscriptionsForAContact({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("listTagsForAContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "tag", + id: "80", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }, + ], + }; + server + .mockEndpoint() + .get("/contacts/63a07ddf05a32042dffac965/tags") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.contacts.listTagsForAContact({ + contact_id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "tag", + id: "80", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }, + ], + }); + }); + + test("listTagsForAContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/contacts/contact_id/tags") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.contacts.listTagsForAContact({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("listTagsForAContact (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/contacts/contact_id/tags") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.contacts.listTagsForAContact({ + contact_id: "contact_id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("ShowContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "contact", + id: "6762f0d01bb69f9f2193bb7d", + external_id: "70", + workspace_id: "this_is_an_id283_that_should_be_at_least_", + role: "user", + email: "joe@bloggs.com", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "Joe Bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537424, + updated_at: 1734537424, + signed_up_at: 1734537424, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: { type: "avatar", image_url: "https://example.org/128Wash.jpg" }, + tags: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0d01bb69f9f2193bb7d/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0d01bb69f9f2193bb7d/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [{ id: "5ba682d23d7cf92bef87bfd4", url: "/companies/5ba682d23d7cf92bef87bfd4" }], + url: "/contacts/6762f0d01bb69f9f2193bb7d/companies", + total_count: 0, + has_more: false, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + social_profiles: { + data: [{ type: "social_profile", name: "Facebook", url: "http://twitter.com/th1sland" }], + }, + enabled_push_messaging: true, + }; + server + .mockEndpoint() + .get("/contacts/63a07ddf05a32042dffac965") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.contacts.showContact({ + id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "contact", + id: "6762f0d01bb69f9f2193bb7d", + external_id: "70", + workspace_id: "this_is_an_id283_that_should_be_at_least_", + role: "user", + email: "joe@bloggs.com", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "Joe Bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537424, + updated_at: 1734537424, + signed_up_at: 1734537424, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: { + type: "avatar", + image_url: "https://example.org/128Wash.jpg", + }, + tags: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0d01bb69f9f2193bb7d/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0d01bb69f9f2193bb7d/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [ + { + id: "5ba682d23d7cf92bef87bfd4", + url: "/companies/5ba682d23d7cf92bef87bfd4", + }, + ], + url: "/contacts/6762f0d01bb69f9f2193bb7d/companies", + total_count: 0, + has_more: false, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + social_profiles: { + data: [ + { + type: "social_profile", + name: "Facebook", + url: "http://twitter.com/th1sland", + }, + ], + }, + enabled_push_messaging: true, + }); + }); + + test("ShowContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/contacts/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.contacts.showContact({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("UpdateContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { email: "joebloggs@intercom.io", name: "joe bloggs" }; + const rawResponseBody = { + type: "contact", + id: "6762f0cd1bb69f9f2193bb7c", + external_id: "70", + workspace_id: "this_is_an_id279_that_should_be_at_least_", + role: "user", + email: "joebloggs@intercom.io", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "joe bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537421, + updated_at: 1734537422, + signed_up_at: 1734537421, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: { type: "avatar", image_url: "https://example.org/128Wash.jpg" }, + tags: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [{ id: "5ba682d23d7cf92bef87bfd4", url: "/companies/5ba682d23d7cf92bef87bfd4" }], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/companies", + total_count: 0, + has_more: false, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + social_profiles: { + data: [{ type: "social_profile", name: "Facebook", url: "http://twitter.com/th1sland" }], + }, + enabled_push_messaging: true, + }; + server + .mockEndpoint() + .put("/contacts/63a07ddf05a32042dffac965") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.contacts.updateContact({ + id: "63a07ddf05a32042dffac965", + email: "joebloggs@intercom.io", + name: "joe bloggs", + }); + expect(response).toEqual({ + type: "contact", + id: "6762f0cd1bb69f9f2193bb7c", + external_id: "70", + workspace_id: "this_is_an_id279_that_should_be_at_least_", + role: "user", + email: "joebloggs@intercom.io", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "joe bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537421, + updated_at: 1734537422, + signed_up_at: 1734537421, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: { + type: "avatar", + image_url: "https://example.org/128Wash.jpg", + }, + tags: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [ + { + id: "5ba682d23d7cf92bef87bfd4", + url: "/companies/5ba682d23d7cf92bef87bfd4", + }, + ], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/companies", + total_count: 0, + has_more: false, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + social_profiles: { + data: [ + { + type: "social_profile", + name: "Facebook", + url: "http://twitter.com/th1sland", + }, + ], + }, + enabled_push_messaging: true, + }); + }); + + test("UpdateContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { custom_attributes: { order: ["21"] } }; + const rawResponseBody = { + type: "contact", + id: "6762f0cd1bb69f9f2193bb7c", + external_id: "70", + workspace_id: "this_is_an_id279_that_should_be_at_least_", + role: "user", + email: "joebloggs@intercom.io", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "joe bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537421, + updated_at: 1734537422, + signed_up_at: 1734537421, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + order: { + type: "Order.list", + instances: [ + { + id: "21", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + custom_attributes: { order_number: "ORDER-12345", total_amount: 99.99 }, + type: "Order", + }, + ], + }, + }, + avatar: { type: "avatar", image_url: "https://example.org/128Wash.jpg" }, + tags: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [{ id: "5ba682d23d7cf92bef87bfd4", url: "/companies/5ba682d23d7cf92bef87bfd4" }], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/companies", + total_count: 0, + has_more: false, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + social_profiles: { + data: [{ type: "social_profile", name: "Facebook", url: "http://twitter.com/th1sland" }], + }, + enabled_push_messaging: true, + }; + server + .mockEndpoint() + .put("/contacts/63a07ddf05a32042dffac965") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.contacts.updateContact({ + id: "63a07ddf05a32042dffac965", + custom_attributes: { + order: ["21"], + }, + }); + expect(response).toEqual({ + type: "contact", + id: "6762f0cd1bb69f9f2193bb7c", + external_id: "70", + workspace_id: "this_is_an_id279_that_should_be_at_least_", + role: "user", + email: "joebloggs@intercom.io", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "joe bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537421, + updated_at: 1734537422, + signed_up_at: 1734537421, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + order: { + type: "Order.list", + instances: [ + { + id: "21", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + custom_attributes: { + order_number: "ORDER-12345", + total_amount: 99.99, + }, + type: "Order", + }, + ], + }, + }, + avatar: { + type: "avatar", + image_url: "https://example.org/128Wash.jpg", + }, + tags: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [ + { + id: "5ba682d23d7cf92bef87bfd4", + url: "/companies/5ba682d23d7cf92bef87bfd4", + }, + ], + url: "/contacts/6762f0cd1bb69f9f2193bb7c/companies", + total_count: 0, + has_more: false, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + social_profiles: { + data: [ + { + type: "social_profile", + name: "Facebook", + url: "http://twitter.com/th1sland", + }, + ], + }, + enabled_push_messaging: true, + }); + }); + + test("UpdateContact (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/contacts/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.contacts.updateContact({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("DeleteContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70", deleted: true }; + server.mockEndpoint().delete("/contacts/id").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.contacts.deleteContact({ + id: "id", + }); + expect(response).toEqual({ + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + deleted: true, + }); + }); + + test("DeleteContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().delete("/contacts/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.contacts.deleteContact({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("MergeContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { from: "6762f0d51bb69f9f2193bb7f", into: "6762f0d51bb69f9f2193bb80" }; + const rawResponseBody = { + type: "contact", + id: "6762f0d51bb69f9f2193bb80", + external_id: "70", + workspace_id: "this_is_an_id291_that_should_be_at_least_", + role: "user", + email: "joe@bloggs.com", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "Joe Bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537429, + updated_at: 1734537430, + signed_up_at: 1734537429, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: { type: "avatar", image_url: "https://example.org/128Wash.jpg" }, + tags: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0d51bb69f9f2193bb80/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0d51bb69f9f2193bb80/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [{ id: "5ba682d23d7cf92bef87bfd4", url: "/companies/5ba682d23d7cf92bef87bfd4" }], + url: "/contacts/6762f0d51bb69f9f2193bb80/companies", + total_count: 0, + has_more: false, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + social_profiles: { + data: [{ type: "social_profile", name: "Facebook", url: "http://twitter.com/th1sland" }], + }, + enabled_push_messaging: true, + }; + server + .mockEndpoint() + .post("/contacts/merge") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.contacts.mergeContact({ + from: "6762f0d51bb69f9f2193bb7f", + into: "6762f0d51bb69f9f2193bb80", + }); + expect(response).toEqual({ + type: "contact", + id: "6762f0d51bb69f9f2193bb80", + external_id: "70", + workspace_id: "this_is_an_id291_that_should_be_at_least_", + role: "user", + email: "joe@bloggs.com", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "Joe Bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537429, + updated_at: 1734537430, + signed_up_at: 1734537429, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: { + type: "avatar", + image_url: "https://example.org/128Wash.jpg", + }, + tags: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0d51bb69f9f2193bb80/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0d51bb69f9f2193bb80/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [ + { + id: "5ba682d23d7cf92bef87bfd4", + url: "/companies/5ba682d23d7cf92bef87bfd4", + }, + ], + url: "/contacts/6762f0d51bb69f9f2193bb80/companies", + total_count: 0, + has_more: false, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + social_profiles: { + data: [ + { + type: "social_profile", + name: "Facebook", + url: "http://twitter.com/th1sland", + }, + ], + }, + enabled_push_messaging: true, + }); + }); + + test("MergeContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/contacts/merge") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.contacts.mergeContact(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("SearchContacts (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + query: { operator: "AND", value: [{ field: "created_at", operator: ">", value: "1306054154" }] }, + pagination: { per_page: 5 }, + }; + const rawResponseBody = { + type: "list", + data: [ + { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "ecahpwf5", + role: "user", + email: "joe@example.com", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: true, + marked_email_as_spam: true, + unsubscribed_from_emails: true, + created_at: 1571672154, + updated_at: 1571672154, + signed_up_at: 1571672154, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: { type: "avatar", image_url: "https://example.org/128Wash.jpg" }, + tags: { url: "/contacts/5ba682d23d7cf92bef87bfd4/tags", total_count: 100, has_more: true }, + notes: { url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", total_count: 100, has_more: true }, + companies: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/companies", + total_count: 100, + has_more: true, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + }, + ], + total_count: 0, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 5, + total_pages: 0, + }, + }; + server + .mockEndpoint() + .post("/contacts/search") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.contacts.searchContacts({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "ecahpwf5", + role: "user", + email: "joe@example.com", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: true, + marked_email_as_spam: true, + unsubscribed_from_emails: true, + created_at: 1571672154, + updated_at: 1571672154, + signed_up_at: 1571672154, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: { + type: "avatar", + image_url: "https://example.org/128Wash.jpg", + }, + tags: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/tags", + total_count: 100, + has_more: true, + }, + notes: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + total_count: 100, + has_more: true, + }, + companies: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/companies", + total_count: 100, + has_more: true, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + }, + ], + total_count: 0, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 5, + total_pages: 0, + }, + }); + }); + + test("SearchContacts (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { query: {} }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/contacts/search") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.contacts.searchContacts({ + query: {}, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("ListContacts (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "ecahpwf5", + role: "user", + email: "joe@example.com", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: true, + marked_email_as_spam: true, + unsubscribed_from_emails: true, + created_at: 1571672154, + updated_at: 1571672154, + signed_up_at: 1571672154, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: { type: "avatar", image_url: "https://example.org/128Wash.jpg" }, + tags: { url: "/contacts/5ba682d23d7cf92bef87bfd4/tags", total_count: 100, has_more: true }, + notes: { url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", total_count: 100, has_more: true }, + companies: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/companies", + total_count: 100, + has_more: true, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + }, + ], + total_count: 0, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 10, + total_pages: 0, + }, + }; + server.mockEndpoint().get("/contacts").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.contacts.listContacts(); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "ecahpwf5", + role: "user", + email: "joe@example.com", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: true, + marked_email_as_spam: true, + unsubscribed_from_emails: true, + created_at: 1571672154, + updated_at: 1571672154, + signed_up_at: 1571672154, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: { + type: "avatar", + image_url: "https://example.org/128Wash.jpg", + }, + tags: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/tags", + total_count: 100, + has_more: true, + }, + notes: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + total_count: 100, + has_more: true, + }, + companies: { + url: "/contacts/5ba682d23d7cf92bef87bfd4/companies", + total_count: 100, + has_more: true, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + }, + ], + total_count: 0, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 10, + total_pages: 0, + }, + }); + }); + + test("ListContacts (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/contacts").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.contacts.listContacts(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("CreateContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { email: "joebloggs@intercom.io" }; + const rawResponseBody = { + type: "contact", + id: "6762f0dd1bb69f9f2193bb83", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "this_is_an_id303_that_should_be_at_least_", + role: "user", + email: "joebloggs@intercom.io", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537437, + updated_at: 1734537437, + signed_up_at: 1571672154, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: { type: "avatar", image_url: "https://example.org/128Wash.jpg" }, + tags: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0dd1bb69f9f2193bb83/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0dd1bb69f9f2193bb83/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [{ id: "5ba682d23d7cf92bef87bfd4", url: "/companies/5ba682d23d7cf92bef87bfd4" }], + url: "/contacts/6762f0dd1bb69f9f2193bb83/companies", + total_count: 0, + has_more: false, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + social_profiles: { + data: [{ type: "social_profile", name: "Facebook", url: "http://twitter.com/th1sland" }], + }, + enabled_push_messaging: true, + }; + server + .mockEndpoint() + .post("/contacts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.contacts.createContact({ + email: "joebloggs@intercom.io", + }); + expect(response).toEqual({ + type: "contact", + id: "6762f0dd1bb69f9f2193bb83", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "this_is_an_id303_that_should_be_at_least_", + role: "user", + email: "joebloggs@intercom.io", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537437, + updated_at: 1734537437, + signed_up_at: 1571672154, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: { + type: "avatar", + image_url: "https://example.org/128Wash.jpg", + }, + tags: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0dd1bb69f9f2193bb83/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0dd1bb69f9f2193bb83/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [ + { + id: "5ba682d23d7cf92bef87bfd4", + url: "/companies/5ba682d23d7cf92bef87bfd4", + }, + ], + url: "/contacts/6762f0dd1bb69f9f2193bb83/companies", + total_count: 0, + has_more: false, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + social_profiles: { + data: [ + { + type: "social_profile", + name: "Facebook", + url: "http://twitter.com/th1sland", + }, + ], + }, + enabled_push_messaging: true, + }); + }); + + test("CreateContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/contacts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.contacts.createContact({ + key: "value", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("ShowContactByExternalId (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "contact", + id: "6762f0df1bb69f9f2193bb84", + external_id: "70", + workspace_id: "this_is_an_id307_that_should_be_at_least_", + role: "user", + email: "joe@bloggs.com", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "Joe Bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537439, + updated_at: 1734537439, + signed_up_at: 1734537439, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: { type: "avatar", image_url: "https://example.org/128Wash.jpg" }, + tags: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0df1bb69f9f2193bb84/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f0df1bb69f9f2193bb84/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [{ id: "5ba682d23d7cf92bef87bfd4", url: "/companies/5ba682d23d7cf92bef87bfd4" }], + url: "/contacts/6762f0df1bb69f9f2193bb84/companies", + total_count: 0, + has_more: false, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + social_profiles: { + data: [{ type: "social_profile", name: "Facebook", url: "http://twitter.com/th1sland" }], + }, + enabled_push_messaging: true, + }; + server + .mockEndpoint() + .get("/contacts/find_by_external_id/cdd29344-5e0c-4ef0-ac56-f9ba2979bc27") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.contacts.showContactByExternalId({ + external_id: "cdd29344-5e0c-4ef0-ac56-f9ba2979bc27", + }); + expect(response).toEqual({ + type: "contact", + id: "6762f0df1bb69f9f2193bb84", + external_id: "70", + workspace_id: "this_is_an_id307_that_should_be_at_least_", + role: "user", + email: "joe@bloggs.com", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "Joe Bloggs", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734537439, + updated_at: 1734537439, + signed_up_at: 1734537439, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: { + type: "avatar", + image_url: "https://example.org/128Wash.jpg", + }, + tags: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0df1bb69f9f2193bb84/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f0df1bb69f9f2193bb84/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [ + { + id: "5ba682d23d7cf92bef87bfd4", + url: "/companies/5ba682d23d7cf92bef87bfd4", + }, + ], + url: "/contacts/6762f0df1bb69f9f2193bb84/companies", + total_count: 0, + has_more: false, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + social_profiles: { + data: [ + { + type: "social_profile", + name: "Facebook", + url: "http://twitter.com/th1sland", + }, + ], + }, + enabled_push_messaging: true, + }); + }); + + test("ShowContactByExternalId (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/contacts/find_by_external_id/external_id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.contacts.showContactByExternalId({ + external_id: "external_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("ArchiveContact", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70", archived: true }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/archive") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.contacts.archiveContact({ + id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + archived: true, + }); + }); + + test("UnarchiveContact", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70", archived: false }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/unarchive") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.contacts.unarchiveContact({ + id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + archived: false, + }); + }); + + test("BlockContact", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70", blocked: true }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/block") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.contacts.blockContact({ + id: "63a07ddf05a32042dffac965", + }); + expect(response).toEqual({ + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + blocked: true, + }); + }); +}); diff --git a/tests/wire/unstable/conversations.test.ts b/tests/wire/unstable/conversations.test.ts new file mode 100644 index 00000000..4dca52d8 --- /dev/null +++ b/tests/wire/unstable/conversations.test.ts @@ -0,0 +1,10888 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("ConversationsClient", () => { + test("listConversations (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "conversation.list", + conversations: [ + { + type: "conversation", + id: "471", + title: "Conversation Title", + created_at: 1734537460, + updated_at: 1734537460, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }], + }, + conversation_rating: { rating: 5, remark: "", created_at: 1671028894, updated_at: 1671028894 }, + source: { + type: "conversation", + id: "403918320", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267628", + name: "Ciaran166 Lee", + email: "admin166@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f0f31bb69f9f2193bb8b", external_id: "70" }], + }, + teammates: { type: "admin.list" }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { total_count: 1 }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_title: "My AI Workflow", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + }, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 20, + total_pages: 1, + }, + }; + server.mockEndpoint().get("/conversations").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.conversations.listConversations({ + per_page: 1, + starting_after: "starting_after", + }); + expect(response).toEqual({ + type: "conversation.list", + conversations: [ + { + type: "conversation", + id: "471", + title: "Conversation Title", + created_at: 1734537460, + updated_at: 1734537460, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + }, + source: { + type: "conversation", + id: "403918320", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267628", + name: "Ciaran166 Lee", + email: "admin166@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f0f31bb69f9f2193bb8b", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_title: "My AI Workflow", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + }, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 20, + total_pages: 1, + }, + }); + }); + + test("listConversations (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/conversations").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.conversations.listConversations(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("listConversations (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/conversations").respondWith().statusCode(403).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.conversations.listConversations(); + }).rejects.toThrow(Intercom.unstable.ForbiddenError); + }); + + test("createConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { from: { type: "user", id: "6762f11b1bb69f9f2193bba3" }, body: "Hello there" }; + const rawResponseBody = { + type: "user_message", + id: "403918330", + created_at: 1734537501, + subject: "Greetings", + body: "Hello there", + message_type: "inapp", + conversation_id: "499", + }; + server + .mockEndpoint() + .post("/conversations") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.createConversation({ + from: { + type: "user", + id: "6762f11b1bb69f9f2193bba3", + }, + body: "Hello there", + }); + expect(response).toEqual({ + type: "user_message", + id: "403918330", + created_at: 1734537501, + subject: "Greetings", + body: "Hello there", + message_type: "inapp", + conversation_id: "499", + }); + }); + + test("createConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { from: { type: "user", id: "123_doesnt_exist" }, body: "Hello there" }; + const rawResponseBody = { + type: "user_message", + id: "403918330", + created_at: 1734537501, + subject: "Greetings", + body: "Hello there", + message_type: "inapp", + conversation_id: "499", + }; + server + .mockEndpoint() + .post("/conversations") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.createConversation({ + from: { + type: "user", + id: "123_doesnt_exist", + }, + body: "Hello there", + }); + expect(response).toEqual({ + type: "user_message", + id: "403918330", + created_at: 1734537501, + subject: "Greetings", + body: "Hello there", + message_type: "inapp", + conversation_id: "499", + }); + }); + + test("createConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { from: { type: "lead", id: "blackcurrant............" }, body: "body" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.createConversation({ + from: { + type: "lead", + id: "blackcurrant............", + }, + body: "body", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createConversation (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { from: { type: "lead", id: "blackcurrant............" }, body: "body" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.createConversation({ + from: { + type: "lead", + id: "blackcurrant............", + }, + body: "body", + }); + }).rejects.toThrow(Intercom.unstable.ForbiddenError); + }); + + test("createConversation (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { from: { type: "lead", id: "blackcurrant............" }, body: "body" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.createConversation({ + from: { + type: "lead", + id: "blackcurrant............", + }, + body: "body", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("retrieveConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "conversation", + id: "503", + title: "Conversation Title", + created_at: 1734537511, + updated_at: 1734537511, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918334", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267645", + name: "Ciaran176 Lee", + email: "admin176@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1261bb69f9f2193bba7", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + assigned_to: { type: "contact", id: "1a2b3c" }, + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "open", + tags: [{ type: "tag", id: "123456", name: "Test tag" }], + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "3", + part_type: "custom_action_started", + body: "

Okay!

", + created_at: 1740141842, + updated_at: 1740141842, + notified_at: 1740141842, + author: { + type: "admin", + id: "274", + name: "Jamie Oliver", + email: "jamie+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "open", + tags: [{ type: "tag", id: "123456", name: "Test tag" }], + event_details: { action: { name: "Jira Create Issue" } }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "3", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1740141851, + updated_at: 1740141851, + notified_at: 1740141851, + author: { + type: "bot", + id: "278", + name: "Fin", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "open", + tags: [{ type: "tag", id: "123456", name: "Test tag" }], + event_details: { attribute: { name: "jira_issue_key" }, value: { name: "PROJ-007" } }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "3", + part_type: "custom_action_finished", + body: "

Okay!

", + created_at: 1740141857, + updated_at: 1740141857, + notified_at: 1740141857, + author: { + type: "admin", + id: "274", + name: "Jamie Oliver", + email: "jamie+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "closed", + tags: [{ type: "tag", id: "123456", name: "Test tag" }], + event_details: { action: { name: "Jira Create Issue", result: "success" } }, + app_package_code: "test-integration", + }, + ], + total_count: 4, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server.mockEndpoint().get("/conversations/1").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.conversations.retrieveConversation({ + id: 1, + display_as: "plaintext", + include_translations: true, + }); + expect(response).toEqual({ + type: "conversation", + id: "503", + title: "Conversation Title", + created_at: 1734537511, + updated_at: 1734537511, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918334", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267645", + name: "Ciaran176 Lee", + email: "admin176@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1261bb69f9f2193bba7", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + assigned_to: { + type: "contact", + id: "1a2b3c", + }, + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "open", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + }, + ], + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "3", + part_type: "custom_action_started", + body: "

Okay!

", + created_at: 1740141842, + updated_at: 1740141842, + notified_at: 1740141842, + author: { + type: "admin", + id: "274", + name: "Jamie Oliver", + email: "jamie+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "open", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + }, + ], + event_details: { + action: { + name: "Jira Create Issue", + }, + }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "3", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1740141851, + updated_at: 1740141851, + notified_at: 1740141851, + author: { + type: "bot", + id: "278", + name: "Fin", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "open", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + }, + ], + event_details: { + attribute: { + name: "jira_issue_key", + }, + value: { + name: "PROJ-007", + }, + }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "3", + part_type: "custom_action_finished", + body: "

Okay!

", + created_at: 1740141857, + updated_at: 1740141857, + notified_at: 1740141857, + author: { + type: "admin", + id: "274", + name: "Jamie Oliver", + email: "jamie+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + state: "closed", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + }, + ], + event_details: { + action: { + name: "Jira Create Issue", + result: "success", + }, + }, + app_package_code: "test-integration", + }, + ], + total_count: 4, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("retrieveConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/conversations/1").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.conversations.retrieveConversation({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/conversations/1").respondWith().statusCode(403).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.conversations.retrieveConversation({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.ForbiddenError); + }); + + test("retrieveConversation (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/conversations/1").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.conversations.retrieveConversation({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("updateConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + read: true, + title: "new conversation title", + custom_attributes: { issue_type: "Billing", priority: "High" }, + }; + const rawResponseBody = { + type: "conversation", + id: "507", + title: "Conversation Title", + created_at: 1734537521, + updated_at: 1734537523, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918338", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267653", + name: "Ciaran180 Lee", + email: "admin180@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1301bb69f9f2193bbab", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { issue_type: "Billing", priority: "High" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "129", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "130", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .put("/conversations/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.updateConversation({ + id: 1, + display_as: "plaintext", + read: true, + title: "new conversation title", + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "507", + title: "Conversation Title", + created_at: 1734537521, + updated_at: 1734537523, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918338", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267653", + name: "Ciaran180 Lee", + email: "admin180@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1301bb69f9f2193bbab", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "129", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "130", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("updateConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { custom_attributes: { order: {} } }; + const rawResponseBody = { + type: "conversation", + id: "508", + title: "Conversation Title", + created_at: 1734537525, + updated_at: 1734537525, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918339", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267659", + name: "Ciaran185 Lee", + email: "admin185@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1341bb69f9f2193bbac", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { + order: { + type: "Order.list", + instances: [ + { + id: "21", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + created_at: 1671028894, + updated_at: 1671028894, + type: "Order", + custom_attributes: { order_number: "ORDER-12345", total_amount: "custom_attributes" }, + }, + ], + }, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 0, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .put("/conversations/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.updateConversation({ + id: 1, + display_as: "plaintext", + custom_attributes: { + order: {}, + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "508", + title: "Conversation Title", + created_at: 1734537525, + updated_at: 1734537525, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918339", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267659", + name: "Ciaran185 Lee", + email: "admin185@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1341bb69f9f2193bbac", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + order: { + type: "Order.list", + instances: [ + { + id: "21", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + created_at: 1671028894, + updated_at: 1671028894, + type: "Order", + custom_attributes: { + order_number: "ORDER-12345", + total_amount: "custom_attributes", + }, + }, + ], + }, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 0, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("updateConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + read: true, + title: "new conversation title", + custom_attributes: { issue_type: "Billing", priority: "High" }, + }; + const rawResponseBody = { + type: "conversation", + id: "507", + title: "Conversation Title", + created_at: 1734537521, + updated_at: 1734537523, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918338", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267653", + name: "Ciaran180 Lee", + email: "admin180@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1301bb69f9f2193bbab", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { issue_type: "Billing", priority: "High" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "129", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "130", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .put("/conversations/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.updateConversation({ + id: 1, + display_as: "plaintext", + read: true, + title: "new conversation title", + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "507", + title: "Conversation Title", + created_at: 1734537521, + updated_at: 1734537523, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918338", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267653", + name: "Ciaran180 Lee", + email: "admin180@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1301bb69f9f2193bbab", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + issue_type: "Billing", + priority: "High", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "129", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + { + type: "conversation_part", + id: "130", + part_type: "conversation_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537523, + updated_at: 1734537523, + notified_at: 1734537523, + author: { + type: "bot", + id: "991267654", + name: "Fin", + email: "operator+this_is_an_id354_that_should_be_at_least_@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("updateConversation (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/conversations/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.updateConversation({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("updateConversation (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/conversations/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.updateConversation({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.ForbiddenError); + }); + + test("updateConversation (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/conversations/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.updateConversation({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("deleteConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { id: "512", object: "conversation", deleted: true }; + server + .mockEndpoint() + .delete("/conversations/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.deleteConversation({ + id: 1, + }); + expect(response).toEqual({ + id: "512", + object: "conversation", + deleted: true, + }); + }); + + test("deleteConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/conversations/1") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.deleteConversation({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("deleteConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/conversations/1") + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.deleteConversation({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.ForbiddenError); + }); + + test("searchConversations", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + query: { operator: "AND", value: [{ field: "created_at", operator: ">", value: "1306054154" }] }, + pagination: { per_page: 5 }, + }; + const rawResponseBody = { + type: "conversation.list", + conversations: [ + { + type: "conversation", + id: "515", + title: "Conversation Title", + created_at: 1734537546, + updated_at: 1734537546, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }], + }, + conversation_rating: { rating: 5, remark: "", created_at: 1671028894, updated_at: 1671028894 }, + source: { + type: "conversation", + id: "403918346", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267691", + name: "Ciaran210 Lee", + email: "admin210@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f14a1bb69f9f2193bbb3", external_id: "70" }], + }, + teammates: { type: "admin.list" }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { total_count: 1 }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_title: "My AI Workflow", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + }, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 5, + total_pages: 1, + }, + }; + server + .mockEndpoint() + .post("/conversations/search") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.searchConversations({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, + }); + expect(response).toEqual({ + type: "conversation.list", + conversations: [ + { + type: "conversation", + id: "515", + title: "Conversation Title", + created_at: 1734537546, + updated_at: 1734537546, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + }, + source: { + type: "conversation", + id: "403918346", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267691", + name: "Ciaran210 Lee", + email: "admin210@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f14a1bb69f9f2193bbb3", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_title: "My AI Workflow", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + }, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 5, + total_pages: 1, + }, + }); + }); + + test("replyConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1571bb69f9f2193bbbb", + }; + const rawResponseBody = { + type: "conversation", + id: "524", + title: "Conversation Title", + created_at: 1734537559, + updated_at: 1734537561, + waiting_since: 1734537561, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918349", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267694", + name: "Ciaran212 Lee", + email: "admin212@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1571bb69f9f2193bbbb", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1734537561, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "132", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537561, + updated_at: 1734537561, + notified_at: 1734537561, + author: { + type: "user", + id: "6762f1571bb69f9f2193bbbb", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123%20or%20%22last%22/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.replyConversation({ + id: '123 or "last"', + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1571bb69f9f2193bbbb", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "524", + title: "Conversation Title", + created_at: 1734537559, + updated_at: 1734537561, + waiting_since: 1734537561, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918349", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267694", + name: "Ciaran212 Lee", + email: "admin212@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1571bb69f9f2193bbbb", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1734537561, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "132", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537561, + updated_at: 1734537561, + notified_at: 1734537561, + author: { + type: "user", + id: "6762f1571bb69f9f2193bbbb", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("replyConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "note", + type: "admin", + body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + admin_id: "3156780", + }; + const rawResponseBody = { + type: "conversation", + id: "525", + title: "Conversation Title", + created_at: 1734537563, + updated_at: 1734537565, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918350", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267696", + name: "Ciaran213 Lee", + email: "admin213@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f15b1bb69f9f2193bbbc", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "133", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537565, + updated_at: 1734537565, + notified_at: 1734537565, + author: { + type: "admin", + id: "991267696", + name: "Ciaran213 Lee", + email: "admin213@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123%20or%20%22last%22/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.replyConversation({ + id: '123 or "last"', + body: { + message_type: "note", + type: "admin", + body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + admin_id: "3156780", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "525", + title: "Conversation Title", + created_at: 1734537563, + updated_at: 1734537565, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918350", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267696", + name: "Ciaran213 Lee", + email: "admin213@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f15b1bb69f9f2193bbbc", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "133", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537565, + updated_at: 1734537565, + notified_at: 1734537565, + author: { + type: "admin", + id: "991267696", + name: "Ciaran213 Lee", + email: "admin213@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("replyConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "quick_reply", + type: "admin", + admin_id: "3156780", + reply_options: [ + { text: "Yes", uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb" }, + { text: "No", uuid: "f4a98af1-be56-4948-a57e-e1a83f8484c6" }, + ], + }; + const rawResponseBody = { + type: "conversation", + id: "526", + title: "Conversation Title", + created_at: 1734537567, + updated_at: 1734537568, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918351", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267698", + name: "Ciaran214 Lee", + email: "admin214@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f15e1bb69f9f2193bbbd", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "134", + part_type: "quick_reply", + body: "

Okay!

", + created_at: 1734537568, + updated_at: 1734537568, + notified_at: 1734537568, + author: { + type: "admin", + id: "991267698", + name: "Ciaran214 Lee", + email: "admin214@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123%20or%20%22last%22/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.replyConversation({ + id: '123 or "last"', + body: { + message_type: "quick_reply", + type: "admin", + admin_id: "3156780", + reply_options: [ + { + text: "Yes", + uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb", + }, + { + text: "No", + uuid: "f4a98af1-be56-4948-a57e-e1a83f8484c6", + }, + ], + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "526", + title: "Conversation Title", + created_at: 1734537567, + updated_at: 1734537568, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918351", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267698", + name: "Ciaran214 Lee", + email: "admin214@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f15e1bb69f9f2193bbbd", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "134", + part_type: "quick_reply", + body: "

Okay!

", + created_at: 1734537568, + updated_at: 1734537568, + notified_at: 1734537568, + author: { + type: "admin", + id: "991267698", + name: "Ciaran214 Lee", + email: "admin214@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("replyConversation (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "body", + reply_options: [{ text: "Yes", uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb" }], + intercom_user_id: "6762f1621bb69f9f2193bbbe", + }; + const rawResponseBody = { + type: "conversation", + id: "524", + title: "Conversation Title", + created_at: 1734537559, + updated_at: 1734537561, + waiting_since: 1734537561, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918349", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267694", + name: "Ciaran212 Lee", + email: "admin212@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1571bb69f9f2193bbbb", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1734537561, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "132", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537561, + updated_at: 1734537561, + notified_at: 1734537561, + author: { + type: "user", + id: "6762f1571bb69f9f2193bbbb", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123%20or%20%22last%22/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.replyConversation({ + id: '123 or "last"', + body: { + message_type: "comment", + type: "user", + body: "body", + reply_options: [ + { + text: "Yes", + uuid: "a5e1c524-5ddd-4c3e-9328-6bca5d6e3edb", + }, + ], + intercom_user_id: "6762f1621bb69f9f2193bbbe", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "524", + title: "Conversation Title", + created_at: 1734537559, + updated_at: 1734537561, + waiting_since: 1734537561, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918349", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267694", + name: "Ciaran212 Lee", + email: "admin212@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1571bb69f9f2193bbbb", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1734537561, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "132", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537561, + updated_at: 1734537561, + notified_at: 1734537561, + author: { + type: "user", + id: "6762f1571bb69f9f2193bbbb", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("replyConversation (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1661bb69f9f2193bbbf", + }; + const rawResponseBody = { + type: "conversation", + id: "527", + title: "Conversation Title", + created_at: 1734537571, + updated_at: 1734537572, + waiting_since: 1734537572, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918352", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267700", + name: "Ciaran215 Lee", + email: "admin215@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1621bb69f9f2193bbbe", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1734537572, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "135", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537572, + updated_at: 1734537572, + notified_at: 1734537572, + author: { + type: "user", + id: "6762f1621bb69f9f2193bbbe", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123%20or%20%22last%22/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.replyConversation({ + id: '123 or "last"', + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f1661bb69f9f2193bbbf", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "527", + title: "Conversation Title", + created_at: 1734537571, + updated_at: 1734537572, + waiting_since: 1734537572, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918352", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267700", + name: "Ciaran215 Lee", + email: "admin215@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1621bb69f9f2193bbbe", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1734537572, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "135", + part_type: "open", + body: "

Thanks again :)

", + created_at: 1734537572, + updated_at: 1734537572, + notified_at: 1734537572, + author: { + type: "user", + id: "6762f1621bb69f9f2193bbbe", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("replyConversation (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/id/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.replyConversation({ + id: "id", + body: { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("replyConversation (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/id/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.replyConversation({ + id: "id", + body: { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }, + }); + }).rejects.toThrow(Intercom.unstable.ForbiddenError); + }); + + test("replyConversation (8)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations/id/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.replyConversation({ + id: "id", + body: { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("manageConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "close", type: "admin", admin_id: "12345" }; + const rawResponseBody = { + type: "conversation", + id: "531", + title: "Conversation Title", + created_at: 1734537582, + updated_at: 1734537584, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918356", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f16e1bb69f9f2193bbc2", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "136", + part_type: "close", + body: "

Goodbye :)

", + created_at: 1734537584, + updated_at: 1734537584, + notified_at: 1734537584, + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.manageConversation({ + id: "123", + body: { + message_type: "close", + type: "admin", + admin_id: "12345", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "531", + title: "Conversation Title", + created_at: 1734537582, + updated_at: 1734537584, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918356", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f16e1bb69f9f2193bbc2", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "136", + part_type: "close", + body: "

Goodbye :)

", + created_at: 1734537584, + updated_at: 1734537584, + notified_at: 1734537584, + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("manageConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "snoozed", admin_id: "5017691", snoozed_until: 1673609604 }; + const rawResponseBody = { + type: "conversation", + id: "532", + title: "Conversation Title", + created_at: 1734537586, + updated_at: 1734537587, + waiting_since: 1663597260, + snoozed_until: 1734541187, + open: true, + state: "snoozed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918357", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267710", + name: "Ciaran220 Lee", + email: "admin220@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1711bb69f9f2193bbc3", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "137", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537587, + updated_at: 1734537587, + notified_at: 1734537587, + author: { + type: "admin", + id: "991267710", + name: "Ciaran220 Lee", + email: "admin220@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.manageConversation({ + id: "123", + body: { + message_type: "snoozed", + admin_id: "5017691", + snoozed_until: 1673609604, + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "532", + title: "Conversation Title", + created_at: 1734537586, + updated_at: 1734537587, + waiting_since: 1663597260, + snoozed_until: 1734541187, + open: true, + state: "snoozed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918357", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267710", + name: "Ciaran220 Lee", + email: "admin220@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1711bb69f9f2193bbc3", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "137", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537587, + updated_at: 1734537587, + notified_at: 1734537587, + author: { + type: "admin", + id: "991267710", + name: "Ciaran220 Lee", + email: "admin220@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("manageConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "open", admin_id: "5017690" }; + const rawResponseBody = { + type: "conversation", + id: "537", + title: "", + created_at: 1734537587, + updated_at: 1734537601, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918358", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267712", + name: "Ciaran221 Lee", + email: "admin221@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1781bb69f9f2193bbc8", external_id: "74" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "139", + part_type: "open", + body: "

Okay!

", + created_at: 1734537601, + updated_at: 1734537601, + notified_at: 1734537601, + author: { + type: "admin", + id: "991267712", + name: "Ciaran221 Lee", + email: "admin221@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.manageConversation({ + id: "123", + body: { + message_type: "open", + admin_id: "5017690", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "537", + title: "", + created_at: 1734537587, + updated_at: 1734537601, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918358", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267712", + name: "Ciaran221 Lee", + email: "admin221@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1781bb69f9f2193bbc8", + external_id: "74", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "139", + part_type: "open", + body: "

Okay!

", + created_at: 1734537601, + updated_at: 1734537601, + notified_at: 1734537601, + author: { + type: "admin", + id: "991267712", + name: "Ciaran221 Lee", + email: "admin221@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("manageConversation (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "assignment", type: "admin", admin_id: "12345", assignee_id: "4324241" }; + const rawResponseBody = { + type: "conversation", + id: "542", + title: "Conversation Title", + created_at: 1734537603, + updated_at: 1734537605, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 991267715, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918361", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267715", + name: "Ciaran223 Lee", + email: "admin223@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1831bb69f9f2193bbcc", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "140", + part_type: "assign_and_reopen", + body: "

Okay!

", + created_at: 1734537605, + updated_at: 1734537605, + notified_at: 1734537605, + assigned_to: { type: "admin", id: "991267715" }, + author: { + type: "admin", + id: "991267715", + name: "Ciaran223 Lee", + email: "admin223@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.manageConversation({ + id: "123", + body: { + message_type: "assignment", + type: "admin", + admin_id: "12345", + assignee_id: "4324241", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "542", + title: "Conversation Title", + created_at: 1734537603, + updated_at: 1734537605, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: false, + priority: "not_priority", + admin_assignee_id: 991267715, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918361", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267715", + name: "Ciaran223 Lee", + email: "admin223@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1831bb69f9f2193bbcc", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "140", + part_type: "assign_and_reopen", + body: "

Okay!

", + created_at: 1734537605, + updated_at: 1734537605, + notified_at: 1734537605, + assigned_to: { + type: "admin", + id: "991267715", + }, + author: { + type: "admin", + id: "991267715", + name: "Ciaran223 Lee", + email: "admin223@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("manageConversation (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "close", type: "admin", admin_id: "12345" }; + const rawResponseBody = { + type: "conversation", + id: "531", + title: "Conversation Title", + created_at: 1734537582, + updated_at: 1734537584, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918356", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f16e1bb69f9f2193bbc2", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "136", + part_type: "close", + body: "

Goodbye :)

", + created_at: 1734537584, + updated_at: 1734537584, + notified_at: 1734537584, + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.manageConversation({ + id: "123", + body: { + message_type: "close", + type: "admin", + admin_id: "12345", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "531", + title: "Conversation Title", + created_at: 1734537582, + updated_at: 1734537584, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: false, + state: "closed", + read: false, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918356", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f16e1bb69f9f2193bbc2", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "136", + part_type: "close", + body: "

Goodbye :)

", + created_at: 1734537584, + updated_at: 1734537584, + notified_at: 1734537584, + author: { + type: "admin", + id: "991267708", + name: "Ciaran219 Lee", + email: "admin219@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("manageConversation (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "close", type: "admin", admin_id: "admin_id" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/id/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.manageConversation({ + id: "id", + body: { + message_type: "close", + type: "admin", + admin_id: "admin_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("manageConversation (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "close", type: "admin", admin_id: "admin_id" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/id/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.manageConversation({ + id: "id", + body: { + message_type: "close", + type: "admin", + admin_id: "admin_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.ForbiddenError); + }); + + test("manageConversation (8)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { message_type: "close", type: "admin", admin_id: "admin_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations/id/parts") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.manageConversation({ + id: "id", + body: { + message_type: "close", + type: "admin", + admin_id: "admin_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("attachContactToConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "12345", customer: { intercom_user_id: "6762f19b1bb69f9f2193bbd4" } }; + const rawResponseBody = { + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { type: "contact.list", contacts: [{ id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }] }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { + paid_subscriber: { type: "order.list", instances: [] }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 100, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/customers") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.attachContactToConversation({ + id: "123", + admin_id: "12345", + customer: { + intercom_user_id: "6762f19b1bb69f9f2193bbd4", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + paid_subscriber: { + type: "order.list", + instances: [], + }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 100, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("attachContactToConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "12345", customer: { intercom_user_id: "6762f19e1bb69f9f2193bbd5" } }; + const rawResponseBody = { + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { type: "contact.list", contacts: [{ id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }] }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { + paid_subscriber: { type: "order.list", instances: [] }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 100, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/123/customers") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.attachContactToConversation({ + id: "123", + admin_id: "12345", + customer: { + intercom_user_id: "6762f19e1bb69f9f2193bbd5", + }, + }); + expect(response).toEqual({ + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + paid_subscriber: { + type: "order.list", + instances: [], + }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 100, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("attachContactToConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/id/customers") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.attachContactToConversation({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("attachContactToConversation (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/id/customers") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.attachContactToConversation({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.ForbiddenError); + }); + + test("attachContactToConversation (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations/id/customers") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.attachContactToConversation({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("detachContactFromConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "5017690" }; + const rawResponseBody = { + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { type: "contact.list", contacts: [{ id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }] }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { + paid_subscriber: { type: "order.list", instances: [] }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 100, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .delete("/conversations/123/customers/123") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.detachContactFromConversation({ + conversation_id: "123", + contact_id: "123", + admin_id: "5017690", + }); + expect(response).toEqual({ + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + paid_subscriber: { + type: "order.list", + instances: [], + }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 100, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("detachContactFromConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "5017690" }; + const rawResponseBody = { + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { type: "contact.list", contacts: [{ id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }] }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { + paid_subscriber: { type: "order.list", instances: [] }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 100, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .delete("/conversations/123/customers/123") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.detachContactFromConversation({ + conversation_id: "123", + contact_id: "123", + admin_id: "5017690", + }); + expect(response).toEqual({ + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + paid_subscriber: { + type: "order.list", + instances: [], + }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 100, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("detachContactFromConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "5017690" }; + const rawResponseBody = { + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { type: "contact.list", contacts: [{ id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }] }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { + paid_subscriber: { type: "order.list", instances: [] }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 100, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .delete("/conversations/123/customers/123") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.detachContactFromConversation({ + conversation_id: "123", + contact_id: "123", + admin_id: "5017690", + }); + expect(response).toEqual({ + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + paid_subscriber: { + type: "order.list", + instances: [], + }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 100, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("detachContactFromConversation (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "5017690" }; + const rawResponseBody = { + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { type: "contact.list", contacts: [{ id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }] }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { + paid_subscriber: { type: "order.list", instances: [] }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 100, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .delete("/conversations/123/customers/123") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.detachContactFromConversation({ + conversation_id: "123", + contact_id: "123", + admin_id: "5017690", + }); + expect(response).toEqual({ + type: "conversation", + id: "1295", + title: "Conversation Title", + created_at: 1663597223, + updated_at: 1663597260, + waiting_since: 1663597260, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "3", + delivered_as: "operator_initiated", + subject: "", + body: "

Hey there!

", + author: { + type: "admin", + id: "274", + name: "Operator", + email: "operator+abcd1234@intercom.io", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + paid_subscriber: { + type: "order.list", + instances: [], + }, + monthly_spend: "155.5", + team_mates: 9, + start_date_iso8601: "2023-03-04T09:46:14Z", + end_date_timestamp: 1677923174, + }, + first_contact_reply: { + created_at: 1663597223, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "3", + part_type: "comment", + body: "

Okay!

", + created_at: 1663597223, + updated_at: 1663597260, + notified_at: 1663597260, + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 100, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: true, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("detachContactFromConversation (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/conversations/conversation_id/customers/contact_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.detachContactFromConversation({ + conversation_id: "conversation_id", + contact_id: "contact_id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("detachContactFromConversation (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/conversations/conversation_id/customers/contact_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.detachContactFromConversation({ + conversation_id: "conversation_id", + contact_id: "contact_id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.unstable.ForbiddenError); + }); + + test("detachContactFromConversation (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/conversations/conversation_id/customers/contact_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.detachContactFromConversation({ + conversation_id: "conversation_id", + contact_id: "contact_id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("detachContactFromConversation (8)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/conversations/conversation_id/customers/contact_id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.detachContactFromConversation({ + conversation_id: "conversation_id", + contact_id: "contact_id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.unstable.UnprocessableEntityError); + }); + + test("redactConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + type: "conversation_part", + conversation_id: "19894788788", + conversation_part_id: "19381789428", + }; + const rawResponseBody = { + type: "conversation", + id: "608", + title: "Conversation Title", + created_at: 1734537721, + updated_at: 1734537724, + waiting_since: 1734537722, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918391", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267757", + name: "Ciaran247 Lee", + email: "admin247@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1f81bb69f9f2193bc09", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1734537722, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "149", + part_type: "open", + body: "

This message was deleted

", + created_at: 1734537722, + updated_at: 1734537724, + notified_at: 1734537722, + author: { + type: "user", + id: "6762f1f81bb69f9f2193bc09", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: true, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/redact") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.redactConversation({ + type: "conversation_part", + conversation_id: "19894788788", + conversation_part_id: "19381789428", + }); + expect(response).toEqual({ + type: "conversation", + id: "608", + title: "Conversation Title", + created_at: 1734537721, + updated_at: 1734537724, + waiting_since: 1734537722, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918391", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267757", + name: "Ciaran247 Lee", + email: "admin247@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1f81bb69f9f2193bc09", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1734537722, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "149", + part_type: "open", + body: "

This message was deleted

", + created_at: 1734537722, + updated_at: 1734537724, + notified_at: 1734537722, + author: { + type: "user", + id: "6762f1f81bb69f9f2193bc09", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: true, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("redactConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + type: "conversation_part", + conversation_id: "really_123_doesnt_exist", + conversation_part_id: "really_123_doesnt_exist", + }; + const rawResponseBody = { + type: "conversation", + id: "608", + title: "Conversation Title", + created_at: 1734537721, + updated_at: 1734537724, + waiting_since: 1734537722, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { type: "contact", id: "5ba682d23d7cf92bef87bfd4", external_id: "70" }, + teammate: { type: "contact", id: "1a2b3c" }, + }, + source: { + type: "conversation", + id: "403918391", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267757", + name: "Ciaran247 Lee", + email: "admin247@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f1f81bb69f9f2193bc09", external_id: "70" }], + }, + teammates: { type: "admin.list", teammates: [{ type: "contact", id: "1a2b3c" }] }, + custom_attributes: { key: "value" }, + first_contact_reply: { + created_at: 1734537722, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { type: "conversation_sla_summary", sla_name: "", sla_status: "hit" }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + assigned_team_first_response_time_in_office_hours: [ + { team_id: 100, team_name: "Team One", response_time: 2310 }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "149", + part_type: "open", + body: "

This message was deleted

", + created_at: 1734537722, + updated_at: 1734537724, + notified_at: 1734537722, + author: { + type: "user", + id: "6762f1f81bb69f9f2193bc09", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: true, + metadata: { quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000" }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }; + server + .mockEndpoint() + .post("/conversations/redact") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.redactConversation({ + type: "conversation_part", + conversation_id: "really_123_doesnt_exist", + conversation_part_id: "really_123_doesnt_exist", + }); + expect(response).toEqual({ + type: "conversation", + id: "608", + title: "Conversation Title", + created_at: 1734537721, + updated_at: 1734537724, + waiting_since: 1734537722, + snoozed_until: 1663597260, + open: true, + state: "open", + read: true, + priority: "not_priority", + admin_assignee_id: 0, + team_assignee_id: "5017691", + company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + tags: { + type: "tag.list", + tags: [ + { + type: "tag", + id: "123456", + name: "Test tag", + applied_at: 1663597223, + }, + ], + }, + conversation_rating: { + rating: 5, + remark: "", + created_at: 1671028894, + updated_at: 1671028894, + contact: { + type: "contact", + id: "5ba682d23d7cf92bef87bfd4", + external_id: "70", + }, + teammate: { + type: "contact", + id: "1a2b3c", + }, + }, + source: { + type: "conversation", + id: "403918391", + delivered_as: "admin_initiated", + subject: "", + body: "

this is the message body

", + author: { + type: "admin", + id: "991267757", + name: "Ciaran247 Lee", + email: "admin247@email.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + url: "url", + redacted: false, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f1f81bb69f9f2193bc09", + external_id: "70", + }, + ], + }, + teammates: { + type: "admin.list", + teammates: [ + { + type: "contact", + id: "1a2b3c", + }, + ], + }, + custom_attributes: { + key: "value", + }, + first_contact_reply: { + created_at: 1734537722, + type: "conversation", + url: "https://developers.intercom.com/", + }, + sla_applied: { + type: "conversation_sla_summary", + sla_name: "", + sla_status: "hit", + }, + statistics: { + type: "conversation_statistics", + time_to_assignment: 2310, + time_to_admin_reply: 2310, + time_to_first_close: 2310, + time_to_last_close: 2310, + median_time_to_reply: 2310, + first_contact_reply_at: 1663597233, + first_assignment_at: 1663597233, + first_admin_reply_at: 1663597233, + first_close_at: 1663597233, + last_assignment_at: 1663597233, + last_assignment_admin_reply_at: 1663597233, + last_contact_reply_at: 1663597233, + last_admin_reply_at: 1663597233, + last_close_at: 1663597233, + last_closed_by_id: "c3po", + count_reopens: 1, + count_assignments: 1, + count_conversation_parts: 1, + assigned_team_first_response_time_by_team: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + assigned_team_first_response_time_in_office_hours: [ + { + team_id: 100, + team_name: "Team One", + response_time: 2310, + }, + ], + handling_time: 2310, + adjusted_handling_time: 1800, + }, + conversation_parts: { + type: "conversation_part.list", + conversation_parts: [ + { + type: "conversation_part", + id: "149", + part_type: "open", + body: "

This message was deleted

", + created_at: 1734537722, + updated_at: 1734537724, + notified_at: 1734537722, + author: { + type: "user", + id: "6762f1f81bb69f9f2193bc09", + name: "Joe Bloggs", + email: "joe@bloggs.com", + from_ai_agent: true, + is_ai_answer: false, + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: true, + metadata: { + quick_reply_uuid: "123e4567-e89b-12d3-a456-426614174000", + }, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ai_agent_participated: false, + ai_agent: { + source_type: "essentials_plan_setup", + source_title: "My AI Workflow", + last_answer_type: "ai_answer", + resolution_state: "assumed_resolution", + rating: 4, + rating_remark: "Very helpful!", + created_at: 1663597260, + updated_at: 1663597260, + content_sources: { + type: "content_source.list", + total_count: 1, + content_sources: [ + { + url: "/fin-ai-agent/content?content=content_snippet&id=3234924", + title: "My internal content snippet", + locale: "en", + }, + ], + }, + }, + }); + }); + + test("redactConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + type: "conversation_part", + conversation_id: "conversation_id", + conversation_part_id: "conversation_part_id", + }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/redact") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.redactConversation({ + type: "conversation_part", + conversation_id: "conversation_id", + conversation_part_id: "conversation_part_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("redactConversation (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + type: "conversation_part", + conversation_id: "conversation_id", + conversation_part_id: "conversation_part_id", + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations/redact") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.redactConversation({ + type: "conversation_part", + conversation_id: "conversation_id", + conversation_part_id: "conversation_part_id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("convertConversationToTicket (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_type_id: "53" }; + const rawResponseBody = { + type: "ticket", + id: "611", + ticket_id: "22", + category: "Customer", + ticket_attributes: { key: "value" }, + ticket_state: { + type: "ticket_state", + id: "7493", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "53", + category: "Customer", + name: "my-ticket-type-1", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id442_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537737, + updated_at: 1734537737, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f2041bb69f9f2193bc0c", external_id: "70" }], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537732, + updated_at: 1734537737, + open: true, + snoozed_until: 1663597260, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "151", + part_type: "comment", + body: "

Comment for message

", + created_at: 1734537732, + updated_at: 1734537732, + author: { + type: "user", + id: "6762f2041bb69f9f2193bc0c", + name: "Joe Bloggs", + email: "joe@bloggs.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "152", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537737, + updated_at: 1734537737, + author: { + type: "bot", + id: "991267767", + name: "Fin", + email: "operator+this_is_an_id442_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + is_shared: true, + }; + server + .mockEndpoint() + .post("/conversations/1/convert") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.convertConversationToTicket({ + id: 1, + ticket_type_id: "53", + }); + expect(response).toEqual({ + type: "ticket", + id: "611", + ticket_id: "22", + category: "Customer", + ticket_attributes: { + key: "value", + }, + ticket_state: { + type: "ticket_state", + id: "7493", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "53", + category: "Customer", + name: "my-ticket-type-1", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id442_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537737, + updated_at: 1734537737, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2041bb69f9f2193bc0c", + external_id: "70", + }, + ], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537732, + updated_at: 1734537737, + open: true, + snoozed_until: 1663597260, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "151", + part_type: "comment", + body: "

Comment for message

", + created_at: 1734537732, + updated_at: 1734537732, + author: { + type: "user", + id: "6762f2041bb69f9f2193bc0c", + name: "Joe Bloggs", + email: "joe@bloggs.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "152", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537737, + updated_at: 1734537737, + author: { + type: "bot", + id: "991267767", + name: "Fin", + email: "operator+this_is_an_id442_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + is_shared: true, + }); + }); + + test("convertConversationToTicket (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_type_id: "54" }; + const rawResponseBody = { + type: "ticket", + id: "611", + ticket_id: "22", + category: "Customer", + ticket_attributes: { key: "value" }, + ticket_state: { + type: "ticket_state", + id: "7493", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "53", + category: "Customer", + name: "my-ticket-type-1", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id442_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537737, + updated_at: 1734537737, + }, + contacts: { + type: "contact.list", + contacts: [{ type: "contact", id: "6762f2041bb69f9f2193bc0c", external_id: "70" }], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537732, + updated_at: 1734537737, + open: true, + snoozed_until: 1663597260, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "151", + part_type: "comment", + body: "

Comment for message

", + created_at: 1734537732, + updated_at: 1734537732, + author: { + type: "user", + id: "6762f2041bb69f9f2193bc0c", + name: "Joe Bloggs", + email: "joe@bloggs.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "152", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537737, + updated_at: 1734537737, + author: { + type: "bot", + id: "991267767", + name: "Fin", + email: "operator+this_is_an_id442_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + is_shared: true, + }; + server + .mockEndpoint() + .post("/conversations/1/convert") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.convertConversationToTicket({ + id: 1, + ticket_type_id: "54", + }); + expect(response).toEqual({ + type: "ticket", + id: "611", + ticket_id: "22", + category: "Customer", + ticket_attributes: { + key: "value", + }, + ticket_state: { + type: "ticket_state", + id: "7493", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "53", + category: "Customer", + name: "my-ticket-type-1", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id442_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537737, + updated_at: 1734537737, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2041bb69f9f2193bc0c", + external_id: "70", + }, + ], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537732, + updated_at: 1734537737, + open: true, + snoozed_until: 1663597260, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "151", + part_type: "comment", + body: "

Comment for message

", + created_at: 1734537732, + updated_at: 1734537732, + author: { + type: "user", + id: "6762f2041bb69f9f2193bc0c", + name: "Joe Bloggs", + email: "joe@bloggs.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "152", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537737, + updated_at: 1734537737, + author: { + type: "bot", + id: "991267767", + name: "Fin", + email: "operator+this_is_an_id442_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 2, + }, + is_shared: true, + }); + }); + + test("convertConversationToTicket (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_type_id: "ticket_type_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations/1/convert") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.convertConversationToTicket({ + id: 1, + ticket_type_id: "ticket_type_id", + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); +}); diff --git a/tests/wire/unstable/customChannelEvents.test.ts b/tests/wire/unstable/customChannelEvents.test.ts new file mode 100644 index 00000000..bb810951 --- /dev/null +++ b/tests/wire/unstable/customChannelEvents.test.ts @@ -0,0 +1,796 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("CustomChannelEventsClient", () => { + test("notifyNewConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + event_id: "evt_12345", + external_conversation_id: "conv_67890", + contact: { type: "user", external_id: "user_001", name: "Jane Doe", email: "jane.doe@example.com" }, + }; + const rawResponseBody = { + external_conversation_id: "customer_conversation_id_12", + conversation_id: "intercom_conversation_id_34", + external_contact_id: "customer_contact_id_56", + contact_id: "intercom_contact_id_79", + }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_conversation") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.customChannelEvents.notifyNewConversation({ + event_id: "evt_12345", + external_conversation_id: "conv_67890", + contact: { + type: "user", + external_id: "user_001", + name: "Jane Doe", + email: "jane.doe@example.com", + }, + }); + expect(response).toEqual({ + external_conversation_id: "customer_conversation_id_12", + conversation_id: "intercom_conversation_id_34", + external_contact_id: "customer_contact_id_56", + contact_id: "intercom_contact_id_79", + }); + }); + + test("notifyNewConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_conversation") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyNewConversation({ + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("notifyNewConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_conversation") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyNewConversation({ + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("notifyNewConversation (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_conversation") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyNewConversation({ + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("notifyNewConversation (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_conversation") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyNewConversation({ + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.UnprocessableEntityError); + }); + + test("notifyNewMessage (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + event_id: "evt_54321", + external_conversation_id: "conv_98765", + contact: { type: "user", external_id: "user_002", name: "John Smith", email: "john.smith@example.com" }, + body: "Hello, I need help with my order.", + }; + const rawResponseBody = { + external_conversation_id: "customer_conversation_id_12", + conversation_id: "intercom_conversation_id_34", + external_contact_id: "customer_contact_id_56", + contact_id: "intercom_contact_id_79", + }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_message") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.customChannelEvents.notifyNewMessage({ + event_id: "evt_54321", + external_conversation_id: "conv_98765", + contact: { + type: "user", + external_id: "user_002", + name: "John Smith", + email: "john.smith@example.com", + }, + body: "Hello, I need help with my order.", + }); + expect(response).toEqual({ + external_conversation_id: "customer_conversation_id_12", + conversation_id: "intercom_conversation_id_34", + external_contact_id: "customer_contact_id_56", + contact_id: "intercom_contact_id_79", + }); + }); + + test("notifyNewMessage (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_message") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyNewMessage({ + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("notifyNewMessage (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_message") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyNewMessage({ + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("notifyNewMessage (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_message") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyNewMessage({ + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("notifyNewMessage (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_new_message") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyNewMessage({ + body: "body", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.UnprocessableEntityError); + }); + + test("notifyQuickReplySelected (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + event_id: "evt_67890", + external_conversation_id: "conv_13579", + contact: { type: "user", external_id: "user_003", name: "Alice Example", email: "alice@example.com" }, + quick_reply_option_id: "1234", + }; + const rawResponseBody = { + external_conversation_id: "customer_conversation_id_12", + conversation_id: "intercom_conversation_id_34", + external_contact_id: "customer_contact_id_56", + contact_id: "intercom_contact_id_79", + }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_quick_reply_selected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.customChannelEvents.notifyQuickReplySelected({ + event_id: "evt_67890", + external_conversation_id: "conv_13579", + contact: { + type: "user", + external_id: "user_003", + name: "Alice Example", + email: "alice@example.com", + }, + quick_reply_option_id: "1234", + }); + expect(response).toEqual({ + external_conversation_id: "customer_conversation_id_12", + conversation_id: "intercom_conversation_id_34", + external_contact_id: "customer_contact_id_56", + contact_id: "intercom_contact_id_79", + }); + }); + + test("notifyQuickReplySelected (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_quick_reply_selected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyQuickReplySelected({ + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("notifyQuickReplySelected (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_quick_reply_selected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyQuickReplySelected({ + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("notifyQuickReplySelected (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_quick_reply_selected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyQuickReplySelected({ + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("notifyQuickReplySelected (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_quick_reply_selected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyQuickReplySelected({ + quick_reply_option_id: "quick_reply_option_id", + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.UnprocessableEntityError); + }); + + test("notifyAttributeCollected (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + event_id: "evt_24680", + external_conversation_id: "conv_11223", + contact: { type: "user", external_id: "user_004", name: "Bob Example", email: "bob@example.com" }, + attribute: { id: "shipping_address", value: "123 Main St, Springfield" }, + }; + const rawResponseBody = { + external_conversation_id: "customer_conversation_id_12", + conversation_id: "intercom_conversation_id_34", + external_contact_id: "customer_contact_id_56", + contact_id: "intercom_contact_id_79", + }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_attribute_collected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.customChannelEvents.notifyAttributeCollected({ + event_id: "evt_24680", + external_conversation_id: "conv_11223", + contact: { + type: "user", + external_id: "user_004", + name: "Bob Example", + email: "bob@example.com", + }, + attribute: { + id: "shipping_address", + value: "123 Main St, Springfield", + }, + }); + expect(response).toEqual({ + external_conversation_id: "customer_conversation_id_12", + conversation_id: "intercom_conversation_id_34", + external_contact_id: "customer_contact_id_56", + contact_id: "intercom_contact_id_79", + }); + }); + + test("notifyAttributeCollected (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + attribute: { id: "id", value: "value" }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_attribute_collected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyAttributeCollected({ + attribute: { + id: "id", + value: "value", + }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("notifyAttributeCollected (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + attribute: { id: "id", value: "value" }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_attribute_collected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyAttributeCollected({ + attribute: { + id: "id", + value: "value", + }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("notifyAttributeCollected (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + attribute: { id: "id", value: "value" }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_attribute_collected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyAttributeCollected({ + attribute: { + id: "id", + value: "value", + }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("notifyAttributeCollected (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + attribute: { id: "id", value: "value" }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { type: "user", external_id: "external_id" }, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_channel_events/notify_attribute_collected") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customChannelEvents.notifyAttributeCollected({ + attribute: { + id: "id", + value: "value", + }, + event_id: "event_id", + external_conversation_id: "external_conversation_id", + contact: { + type: "user", + external_id: "external_id", + }, + }); + }).rejects.toThrow(Intercom.unstable.UnprocessableEntityError); + }); +}); diff --git a/tests/wire/unstable/customObjectInstances.test.ts b/tests/wire/unstable/customObjectInstances.test.ts new file mode 100644 index 00000000..6f46b5a0 --- /dev/null +++ b/tests/wire/unstable/customObjectInstances.test.ts @@ -0,0 +1,475 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("CustomObjectInstancesClient", () => { + test("getCustomObjectInstancesByExternalId (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + id: "24", + external_id: "123", + external_created_at: 1571672154, + external_updated_at: 1571672154, + created_at: 1734537748, + updated_at: 1734537748, + type: "Order", + custom_attributes: { order_number: "ORDER-12345", total_amount: "custom_attributes" }, + }; + server + .mockEndpoint() + .get("/custom_object_instances/Order") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.customObjectInstances.getCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "Order", + external_id: "external_id", + }); + expect(response).toEqual({ + id: "24", + external_id: "123", + external_created_at: 1571672154, + external_updated_at: 1571672154, + created_at: 1734537748, + updated_at: 1734537748, + type: "Order", + custom_attributes: { + order_number: "ORDER-12345", + total_amount: "custom_attributes", + }, + }); + }); + + test("getCustomObjectInstancesByExternalId (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/custom_object_instances/custom_object_type_identifier") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customObjectInstances.getCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "custom_object_type_identifier", + external_id: "external_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("getCustomObjectInstancesByExternalId (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/custom_object_instances/custom_object_type_identifier") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customObjectInstances.getCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "custom_object_type_identifier", + external_id: "external_id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("createCustomObjectInstances (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + custom_attributes: { order_number: "ORDER-12345", total_amount: "custom_attributes" }, + }; + const rawResponseBody = { + id: "22", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + created_at: 1734537745, + updated_at: 1734537745, + type: "Order", + custom_attributes: { order_number: "ORDER-12345", total_amount: "custom_attributes" }, + }; + server + .mockEndpoint() + .post("/custom_object_instances/Order") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.customObjectInstances.createCustomObjectInstances({ + custom_object_type_identifier: "Order", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + custom_attributes: { + order_number: "ORDER-12345", + total_amount: "custom_attributes", + }, + }); + expect(response).toEqual({ + id: "22", + external_id: "123", + external_created_at: 1392036272, + external_updated_at: 1392036272, + created_at: 1734537745, + updated_at: 1734537745, + type: "Order", + custom_attributes: { + order_number: "ORDER-12345", + total_amount: "custom_attributes", + }, + }); + }); + + test("createCustomObjectInstances (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/custom_object_instances/custom_object_type_identifier") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customObjectInstances.createCustomObjectInstances({ + custom_object_type_identifier: "custom_object_type_identifier", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createCustomObjectInstances (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/custom_object_instances/custom_object_type_identifier") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customObjectInstances.createCustomObjectInstances({ + custom_object_type_identifier: "custom_object_type_identifier", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("deleteCustomObjectInstancesById (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { object: "Order", id: "26", deleted: true }; + server + .mockEndpoint() + .delete("/custom_object_instances/Order") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.customObjectInstances.deleteCustomObjectInstancesById({ + custom_object_type_identifier: "Order", + external_id: "external_id", + }); + expect(response).toEqual({ + object: "Order", + id: "26", + deleted: true, + }); + }); + + test("deleteCustomObjectInstancesById (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/custom_object_instances/custom_object_type_identifier") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customObjectInstances.deleteCustomObjectInstancesById({ + custom_object_type_identifier: "custom_object_type_identifier", + external_id: "external_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("deleteCustomObjectInstancesById (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/custom_object_instances/custom_object_type_identifier") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customObjectInstances.deleteCustomObjectInstancesById({ + custom_object_type_identifier: "custom_object_type_identifier", + external_id: "external_id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("getCustomObjectInstancesById (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + id: "25", + external_id: "123", + external_created_at: 1571672154, + external_updated_at: 1571672154, + created_at: 1734537750, + updated_at: 1734537750, + type: "Order", + custom_attributes: { order_number: "ORDER-12345", total_amount: "custom_attributes" }, + }; + server + .mockEndpoint() + .get("/custom_object_instances/Order/id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.customObjectInstances.getCustomObjectInstancesById({ + custom_object_type_identifier: "Order", + id: "id", + }); + expect(response).toEqual({ + id: "25", + external_id: "123", + external_created_at: 1571672154, + external_updated_at: 1571672154, + created_at: 1734537750, + updated_at: 1734537750, + type: "Order", + custom_attributes: { + order_number: "ORDER-12345", + total_amount: "custom_attributes", + }, + }); + }); + + test("getCustomObjectInstancesById (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/custom_object_instances/custom_object_type_identifier/id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customObjectInstances.getCustomObjectInstancesById({ + custom_object_type_identifier: "custom_object_type_identifier", + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("getCustomObjectInstancesById (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/custom_object_instances/custom_object_type_identifier/id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customObjectInstances.getCustomObjectInstancesById({ + custom_object_type_identifier: "custom_object_type_identifier", + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("deleteCustomObjectInstancesByExternalId (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { object: "Order", id: "26", deleted: true }; + server + .mockEndpoint() + .delete("/custom_object_instances/Order/id") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.customObjectInstances.deleteCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "Order", + id: "id", + }); + expect(response).toEqual({ + object: "Order", + id: "26", + deleted: true, + }); + }); + + test("deleteCustomObjectInstancesByExternalId (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/custom_object_instances/custom_object_type_identifier/id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customObjectInstances.deleteCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "custom_object_type_identifier", + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("deleteCustomObjectInstancesByExternalId (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/custom_object_instances/custom_object_type_identifier/id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.customObjectInstances.deleteCustomObjectInstancesByExternalId({ + custom_object_type_identifier: "custom_object_type_identifier", + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); +}); diff --git a/tests/wire/unstable/dataAttributes.test.ts b/tests/wire/unstable/dataAttributes.test.ts new file mode 100644 index 00000000..40902954 --- /dev/null +++ b/tests/wire/unstable/dataAttributes.test.ts @@ -0,0 +1,992 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("DataAttributesClient", () => { + test("lisDataAttributes (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "data_attribute", + id: 12878, + model: "company", + name: "name", + full_name: "name", + label: "Company name", + description: "The name of a company", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "company_id", + full_name: "company_id", + label: "Company ID", + description: "A number identifying a company", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "last_request_at", + full_name: "last_request_at", + label: "Company last seen", + description: "The last day anyone from a company visited your site or app", + data_type: "date", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "remote_created_at", + full_name: "remote_created_at", + label: "Company created at", + description: "The day a company was added to Intercom", + data_type: "date", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "user_count", + full_name: "user_count", + label: "People", + description: "The number of people in a company", + data_type: "integer", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "session_count", + full_name: "session_count", + label: "Company web sessions", + description: "All visits from anyone in a company to your product's site or app", + data_type: "integer", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "name", + full_name: "plan.name", + label: "Plan", + description: "A specific plan or level within your product that companies have signed up to", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "monthly_spend", + full_name: "monthly_spend", + label: "Monthly Spend", + description: "The monthly revenue you receive from a company", + data_type: "float", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "size", + full_name: "size", + label: "Company size", + description: "The number of people employed in this company, expressed as a single number", + data_type: "integer", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "industry", + full_name: "industry", + label: "Company industry", + description: "The category or domain this company belongs to e.g. 'ecommerce' or 'SaaS'", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "website", + full_name: "website", + label: "Company website", + description: "The web address for the company's primary marketing site", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 34, + model: "company", + name: "The One Ring", + full_name: "custom_attributes.The One Ring", + label: "The One Ring", + description: + "One ring to rule them all, one ring to find them, One ring to bring them all and in the darkness bind them.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537753, + updated_at: 1734537753, + admin_id: "991267784", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "id", + full_name: "id", + label: "ID", + description: "The Intercom defined id representing the company", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "created_at", + full_name: "created_at", + label: "Created at", + description: "The time the company was added to Intercom", + data_type: "date", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "updated_at", + full_name: "updated_at", + label: "Updated at", + description: "The last time the company was updated", + data_type: "date", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "id", + full_name: "plan.id", + label: "Plan ID", + description: "The Intercom defined id representing the plan", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "app_id", + full_name: "app_id", + label: "App ID", + description: "The Intercom defined id representing the app", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + ], + }; + server.mockEndpoint().get("/data_attributes").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.dataAttributes.lisDataAttributes({ + model: "contact", + include_archived: true, + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "data_attribute", + id: 12878, + model: "company", + name: "name", + full_name: "name", + label: "Company name", + description: "The name of a company", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "company_id", + full_name: "company_id", + label: "Company ID", + description: "A number identifying a company", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "last_request_at", + full_name: "last_request_at", + label: "Company last seen", + description: "The last day anyone from a company visited your site or app", + data_type: "date", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "remote_created_at", + full_name: "remote_created_at", + label: "Company created at", + description: "The day a company was added to Intercom", + data_type: "date", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "user_count", + full_name: "user_count", + label: "People", + description: "The number of people in a company", + data_type: "integer", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "session_count", + full_name: "session_count", + label: "Company web sessions", + description: "All visits from anyone in a company to your product's site or app", + data_type: "integer", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "name", + full_name: "plan.name", + label: "Plan", + description: "A specific plan or level within your product that companies have signed up to", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "monthly_spend", + full_name: "monthly_spend", + label: "Monthly Spend", + description: "The monthly revenue you receive from a company", + data_type: "float", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "size", + full_name: "size", + label: "Company size", + description: "The number of people employed in this company, expressed as a single number", + data_type: "integer", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "industry", + full_name: "industry", + label: "Company industry", + description: "The category or domain this company belongs to e.g. 'ecommerce' or 'SaaS'", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "website", + full_name: "website", + label: "Company website", + description: "The web address for the company's primary marketing site", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 34, + model: "company", + name: "The One Ring", + full_name: "custom_attributes.The One Ring", + label: "The One Ring", + description: + "One ring to rule them all, one ring to find them, One ring to bring them all and in the darkness bind them.", + data_type: "string", + options: ["true", "false"], + api_writable: true, + messenger_writable: true, + ui_writable: false, + custom: true, + archived: false, + created_at: 1734537753, + updated_at: 1734537753, + admin_id: "991267784", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "id", + full_name: "id", + label: "ID", + description: "The Intercom defined id representing the company", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "created_at", + full_name: "created_at", + label: "Created at", + description: "The time the company was added to Intercom", + data_type: "date", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "updated_at", + full_name: "updated_at", + label: "Updated at", + description: "The last time the company was updated", + data_type: "date", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "id", + full_name: "plan.id", + label: "Plan ID", + description: "The Intercom defined id representing the plan", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + { + type: "data_attribute", + id: 12878, + model: "company", + name: "app_id", + full_name: "app_id", + label: "App ID", + description: "The Intercom defined id representing the app", + data_type: "string", + options: ["true", "false"], + api_writable: false, + messenger_writable: true, + ui_writable: false, + custom: false, + archived: false, + created_at: 1671028894, + updated_at: 1671028894, + admin_id: "5712945", + }, + ], + }); + }); + + test("lisDataAttributes (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/data_attributes").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.dataAttributes.lisDataAttributes(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createDataAttribute (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { + type: "data_attribute", + id: 1, + model: "contact", + name: "name", + full_name: "full_name", + label: "label", + description: "description", + data_type: "string", + options: ["options", "options"], + api_writable: true, + messenger_writable: true, + ui_writable: true, + custom: true, + archived: true, + created_at: 1, + updated_at: 1, + admin_id: "admin_id", + }; + server + .mockEndpoint() + .post("/data_attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.dataAttributes.createDataAttribute({ + key: "value", + }); + expect(response).toEqual({ + type: "data_attribute", + id: 1, + model: "contact", + name: "name", + full_name: "full_name", + label: "label", + description: "description", + data_type: "string", + options: ["options", "options"], + api_writable: true, + messenger_writable: true, + ui_writable: true, + custom: true, + archived: true, + created_at: 1, + updated_at: 1, + admin_id: "admin_id", + }); + }); + + test("createDataAttribute (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/data_attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.dataAttributes.createDataAttribute({ + key: "value", + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("createDataAttribute (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/data_attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.dataAttributes.createDataAttribute({ + key: "value", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("updateDataAttribute (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { + type: "data_attribute", + id: 1, + model: "contact", + name: "name", + full_name: "full_name", + label: "label", + description: "description", + data_type: "string", + options: ["options", "options"], + api_writable: true, + messenger_writable: true, + ui_writable: true, + custom: true, + archived: true, + created_at: 1, + updated_at: 1, + admin_id: "admin_id", + }; + server + .mockEndpoint() + .put("/data_attributes/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.dataAttributes.updateDataAttribute({ + id: 1, + body: { + key: "value", + }, + }); + expect(response).toEqual({ + type: "data_attribute", + id: 1, + model: "contact", + name: "name", + full_name: "full_name", + label: "label", + description: "description", + data_type: "string", + options: ["options", "options"], + api_writable: true, + messenger_writable: true, + ui_writable: true, + custom: true, + archived: true, + created_at: 1, + updated_at: 1, + admin_id: "admin_id", + }); + }); + + test("updateDataAttribute (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/data_attributes/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.dataAttributes.updateDataAttribute({ + id: 1, + body: { + key: "value", + }, + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("updateDataAttribute (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/data_attributes/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.dataAttributes.updateDataAttribute({ + id: 1, + body: { + key: "value", + }, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("updateDataAttribute (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/data_attributes/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.dataAttributes.updateDataAttribute({ + id: 1, + body: { + key: "value", + }, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("updateDataAttribute (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/data_attributes/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.dataAttributes.updateDataAttribute({ + id: 1, + body: { + key: "value", + }, + }); + }).rejects.toThrow(Intercom.unstable.UnprocessableEntityError); + }); +}); diff --git a/tests/wire/unstable/dataEvents.test.ts b/tests/wire/unstable/dataEvents.test.ts new file mode 100644 index 00000000..14d6052a --- /dev/null +++ b/tests/wire/unstable/dataEvents.test.ts @@ -0,0 +1,164 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("DataEventsClient", () => { + test("lisDataEvents (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "event.summary", + email: "email", + intercom_user_id: "intercom_user_id", + user_id: "user_id", + events: [ + { name: "name", first: "first", last: "last", count: 1, description: "description" }, + { name: "name", first: "first", last: "last", count: 1, description: "description" }, + ], + }; + server.mockEndpoint().get("/events").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.dataEvents.lisDataEvents({ + filter: { + user_id: "user_id", + }, + type: "type", + }); + expect(response).toEqual({ + type: "event.summary", + email: "email", + intercom_user_id: "intercom_user_id", + user_id: "user_id", + events: [ + { + name: "name", + first: "first", + last: "last", + count: 1, + description: "description", + }, + { + name: "name", + first: "first", + last: "last", + count: 1, + description: "description", + }, + ], + }); + }); + + test("lisDataEvents (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/events").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.dataEvents.lisDataEvents({ + filter: { + user_id: "user_id", + }, + type: "type", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createDataEvent (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + + server.mockEndpoint().post("/events").jsonBody(rawRequestBody).respondWith().statusCode(200).build(); + + const response = await client.unstable.dataEvents.createDataEvent({ + key: "value", + }); + expect(response).toEqual(undefined); + }); + + test("createDataEvent (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/events") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.dataEvents.createDataEvent({ + key: "value", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("dataEventSummaries (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + + server.mockEndpoint().post("/events/summaries").jsonBody(rawRequestBody).respondWith().statusCode(200).build(); + + const response = await client.unstable.dataEvents.dataEventSummaries(); + expect(response).toEqual(undefined); + }); + + test("dataEventSummaries (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/events/summaries") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.dataEvents.dataEventSummaries(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); +}); diff --git a/tests/wire/unstable/dataExport.test.ts b/tests/wire/unstable/dataExport.test.ts new file mode 100644 index 00000000..7db13db4 --- /dev/null +++ b/tests/wire/unstable/dataExport.test.ts @@ -0,0 +1,127 @@ +// This file was auto-generated by Fern from our API Definition. + +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("DataExportClient", () => { + test("createDataExport", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { created_at_after: 1734519776, created_at_before: 1734537776 }; + const rawResponseBody = { + job_identfier: "orzzsbd7hk67xyu", + status: "pending", + download_expires_at: "", + download_url: "", + }; + server + .mockEndpoint() + .post("/export/content/data") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.dataExport.createDataExport({ + created_at_after: 1734519776, + created_at_before: 1734537776, + }); + expect(response).toEqual({ + job_identfier: "orzzsbd7hk67xyu", + status: "pending", + download_expires_at: "", + download_url: "", + }); + }); + + test("getDataExport", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + job_identfier: "orzzsbd7hk67xyu", + status: "pending", + download_expires_at: "", + download_url: "", + }; + server + .mockEndpoint() + .get("/export/content/data/job_identifier") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.dataExport.getDataExport({ + job_identifier: "job_identifier", + }); + expect(response).toEqual({ + job_identfier: "orzzsbd7hk67xyu", + status: "pending", + download_expires_at: "", + download_url: "", + }); + }); + + test("cancelDataExport", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + job_identfier: "orzzsbd7hk67xyu", + status: "canceled", + download_expires_at: "", + download_url: "", + }; + server + .mockEndpoint() + .post("/export/cancel/job_identifier") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.dataExport.cancelDataExport({ + job_identifier: "job_identifier", + }); + expect(response).toEqual({ + job_identfier: "orzzsbd7hk67xyu", + status: "canceled", + download_expires_at: "", + download_url: "", + }); + }); + + test("downloadDataExport", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + server.mockEndpoint().get("/download/content/data/job_identifier").respondWith().statusCode(200).build(); + + const response = await client.unstable.dataExport.downloadDataExport({ + job_identifier: "job_identifier", + }); + expect(response).toEqual(undefined); + }); +}); diff --git a/tests/wire/unstable/emails.test.ts b/tests/wire/unstable/emails.test.ts new file mode 100644 index 00000000..95a02bd0 --- /dev/null +++ b/tests/wire/unstable/emails.test.ts @@ -0,0 +1,174 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("EmailsClient", () => { + test("listEmails (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "email_setting", + id: "1", + email: "support@company.com", + verified: true, + domain: "company.com", + brand_id: "9", + forwarding_enabled: true, + forwarded_email_last_received_at: 1710498600, + created_at: 1692530400, + updated_at: 1710498600, + }, + { + type: "email_setting", + id: "2", + email: "hello@company.com", + verified: true, + domain: "company.com", + brand_id: "10", + forwarding_enabled: false, + forwarded_email_last_received_at: 1710498600, + created_at: 1683729000, + updated_at: 1701424500, + }, + ], + }; + server.mockEndpoint().get("/emails").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.emails.listEmails(); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "email_setting", + id: "1", + email: "support@company.com", + verified: true, + domain: "company.com", + brand_id: "9", + forwarding_enabled: true, + forwarded_email_last_received_at: 1710498600, + created_at: 1692530400, + updated_at: 1710498600, + }, + { + type: "email_setting", + id: "2", + email: "hello@company.com", + verified: true, + domain: "company.com", + brand_id: "10", + forwarding_enabled: false, + forwarded_email_last_received_at: 1710498600, + created_at: 1683729000, + updated_at: 1701424500, + }, + ], + }); + }); + + test("listEmails (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/emails").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.emails.listEmails(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveEmail (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "email_setting", + id: "10", + email: "support@company.com", + verified: true, + domain: "company.com", + brand_id: "15", + forwarding_enabled: true, + forwarded_email_last_received_at: 1710498600, + created_at: 1692530400, + updated_at: 1710498600, + }; + server.mockEndpoint().get("/emails/id").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.emails.retrieveEmail({ + id: "id", + }); + expect(response).toEqual({ + type: "email_setting", + id: "10", + email: "support@company.com", + verified: true, + domain: "company.com", + brand_id: "15", + forwarding_enabled: true, + forwarded_email_last_received_at: 1710498600, + created_at: 1692530400, + updated_at: 1710498600, + }); + }); + + test("retrieveEmail (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/emails/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.emails.retrieveEmail({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveEmail (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/emails/id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.emails.retrieveEmail({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); +}); diff --git a/tests/wire/unstable/export.test.ts b/tests/wire/unstable/export.test.ts new file mode 100644 index 00000000..0027d596 --- /dev/null +++ b/tests/wire/unstable/export.test.ts @@ -0,0 +1,201 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("ExportClient", () => { + test("enqueueANewReportingDataExportJob (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + dataset_id: "conversation", + attribute_ids: ["conversation_id", "conversation_started_at"], + start_time: 1717490000, + end_time: 1717510000, + }; + const rawResponseBody = { + job_identifier: "job1", + status: "pending", + download_url: "download_url", + download_expires_at: "download_expires_at", + }; + server + .mockEndpoint() + .post("/export/reporting_data/enqueue") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.export.enqueueANewReportingDataExportJob({ + dataset_id: "conversation", + attribute_ids: ["conversation_id", "conversation_started_at"], + start_time: 1717490000, + end_time: 1717510000, + }); + expect(response).toEqual({ + job_identifier: "job1", + status: "pending", + download_url: "download_url", + download_expires_at: "download_expires_at", + }); + }); + + test("enqueueANewReportingDataExportJob (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + dataset_id: "dataset_id", + attribute_ids: ["attribute_ids", "attribute_ids"], + start_time: 1000000, + end_time: 1000000, + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/export/reporting_data/enqueue") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.export.enqueueANewReportingDataExportJob({ + dataset_id: "dataset_id", + attribute_ids: ["attribute_ids", "attribute_ids"], + start_time: 1000000, + end_time: 1000000, + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("enqueueANewReportingDataExportJob (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + dataset_id: "dataset_id", + attribute_ids: ["attribute_ids", "attribute_ids"], + start_time: 1000000, + end_time: 1000000, + }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/export/reporting_data/enqueue") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.export.enqueueANewReportingDataExportJob({ + dataset_id: "dataset_id", + attribute_ids: ["attribute_ids", "attribute_ids"], + start_time: 1000000, + end_time: 1000000, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("enqueueANewReportingDataExportJob (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + dataset_id: "dataset_id", + attribute_ids: ["attribute_ids", "attribute_ids"], + start_time: 1000000, + end_time: 1000000, + }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/export/reporting_data/enqueue") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(429) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.export.enqueueANewReportingDataExportJob({ + dataset_id: "dataset_id", + attribute_ids: ["attribute_ids", "attribute_ids"], + start_time: 1000000, + end_time: 1000000, + }); + }).rejects.toThrow(Intercom.unstable.TooManyRequestsError); + }); + + test("listAvailableDatasetsAndAttributes", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + id: "conversation", + name: "Conversation", + description: "Conversation-level details: status, channel, assignee.", + default_time_attribute_id: "conversation_started_at", + attributes: [{ id: "conversation_id", name: "Conversation ID" }], + }, + ], + }; + server + .mockEndpoint() + .get("/export/reporting_data/get_datasets") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.export.listAvailableDatasetsAndAttributes(); + expect(response).toEqual({ + type: "list", + data: [ + { + id: "conversation", + name: "Conversation", + description: "Conversation-level details: status, channel, assignee.", + default_time_attribute_id: "conversation_started_at", + attributes: [ + { + id: "conversation_id", + name: "Conversation ID", + }, + ], + }, + ], + }); + }); +}); diff --git a/tests/wire/unstable/helpCenter.test.ts b/tests/wire/unstable/helpCenter.test.ts new file mode 100644 index 00000000..7e4acacd --- /dev/null +++ b/tests/wire/unstable/helpCenter.test.ts @@ -0,0 +1,1933 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("HelpCenterClient", () => { + test("listAllCollections (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 20, + total_pages: 1, + }, + total_count: 2, + data: [ + { + id: "159", + workspace_id: "this_is_an_id96_that_should_be_at_least_4", + name: "English collection title", + description: "english collection description", + created_at: 1734537309, + updated_at: 1734537309, + url: "http://help-center.test/myapp-96/collection-17", + icon: "bookmark", + order: 17, + default_locale: "en", + parent_id: "6871118", + help_center_id: 79, + }, + { + id: "160", + workspace_id: "this_is_an_id96_that_should_be_at_least_4", + name: "English section title", + description: "Default language description", + created_at: 1734537309, + updated_at: 1734537309, + url: "http://help-center.test/myapp-96/section-1", + icon: "bookmark", + order: 1, + default_locale: "en", + parent_id: "159", + help_center_id: 1, + }, + ], + }; + server + .mockEndpoint() + .get("/help_center/collections") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.helpCenter.listAllCollections(); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 20, + total_pages: 1, + }, + total_count: 2, + data: [ + { + id: "159", + workspace_id: "this_is_an_id96_that_should_be_at_least_4", + name: "English collection title", + description: "english collection description", + created_at: 1734537309, + updated_at: 1734537309, + url: "http://help-center.test/myapp-96/collection-17", + icon: "bookmark", + order: 17, + default_locale: "en", + parent_id: "6871118", + help_center_id: 79, + }, + { + id: "160", + workspace_id: "this_is_an_id96_that_should_be_at_least_4", + name: "English section title", + description: "Default language description", + created_at: 1734537309, + updated_at: 1734537309, + url: "http://help-center.test/myapp-96/section-1", + icon: "bookmark", + order: 1, + default_locale: "en", + parent_id: "159", + help_center_id: 1, + }, + ], + }); + }); + + test("listAllCollections (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/help_center/collections") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.helpCenter.listAllCollections(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createCollection (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "Thanks for everything" }; + const rawResponseBody = { + id: "165", + workspace_id: "this_is_an_id100_that_should_be_at_least_", + name: "Thanks for everything", + description: "", + created_at: 1734537312, + updated_at: 1734537312, + url: "http://help-center.test/myapp-100/", + icon: "book-bookmark", + order: 1, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { type: "group_content", name: "Collection name", description: " Collection description" }, + bg: { type: "group_content", name: "Collection name", description: " Collection description" }, + bs: { type: "group_content", name: "Collection name", description: " Collection description" }, + ca: { type: "group_content", name: "Collection name", description: " Collection description" }, + cs: { type: "group_content", name: "Collection name", description: " Collection description" }, + da: { type: "group_content", name: "Collection name", description: " Collection description" }, + de: { type: "group_content", name: "Collection name", description: " Collection description" }, + el: { type: "group_content", name: "Collection name", description: " Collection description" }, + en: { type: "group_content", name: "Collection name", description: " Collection description" }, + es: { type: "group_content", name: "Collection name", description: " Collection description" }, + et: { type: "group_content", name: "Collection name", description: " Collection description" }, + fi: { type: "group_content", name: "Collection name", description: " Collection description" }, + fr: { type: "group_content", name: "Collection name", description: " Collection description" }, + he: { type: "group_content", name: "Collection name", description: " Collection description" }, + hr: { type: "group_content", name: "Collection name", description: " Collection description" }, + hu: { type: "group_content", name: "Collection name", description: " Collection description" }, + id: { type: "group_content", name: "Collection name", description: " Collection description" }, + it: { type: "group_content", name: "Collection name", description: " Collection description" }, + ja: { type: "group_content", name: "Collection name", description: " Collection description" }, + ko: { type: "group_content", name: "Collection name", description: " Collection description" }, + lt: { type: "group_content", name: "Collection name", description: " Collection description" }, + lv: { type: "group_content", name: "Collection name", description: " Collection description" }, + mn: { type: "group_content", name: "Collection name", description: " Collection description" }, + nb: { type: "group_content", name: "Collection name", description: " Collection description" }, + nl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pt: { type: "group_content", name: "Collection name", description: " Collection description" }, + ro: { type: "group_content", name: "Collection name", description: " Collection description" }, + ru: { type: "group_content", name: "Collection name", description: " Collection description" }, + sl: { type: "group_content", name: "Collection name", description: " Collection description" }, + sr: { type: "group_content", name: "Collection name", description: " Collection description" }, + sv: { type: "group_content", name: "Collection name", description: " Collection description" }, + tr: { type: "group_content", name: "Collection name", description: " Collection description" }, + vi: { type: "group_content", name: "Collection name", description: " Collection description" }, + "pt-BR": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-CN": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-TW": { type: "group_content", name: "Collection name", description: " Collection description" }, + }, + parent_id: "6871118", + help_center_id: 81, + }; + server + .mockEndpoint() + .post("/help_center/collections") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.helpCenter.createCollection({ + name: "Thanks for everything", + }); + expect(response).toEqual({ + id: "165", + workspace_id: "this_is_an_id100_that_should_be_at_least_", + name: "Thanks for everything", + description: "", + created_at: 1734537312, + updated_at: 1734537312, + url: "http://help-center.test/myapp-100/", + icon: "book-bookmark", + order: 1, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bg: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ca: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + cs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + da: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + de: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + el: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + en: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + es: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + et: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + he: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hu: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + id: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + it: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ja: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ko: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + mn: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nb: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ro: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ru: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + tr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + vi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "pt-BR": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-CN": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-TW": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + }, + parent_id: "6871118", + help_center_id: 81, + }); + }); + + test("createCollection (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "collection 51", description: "Missing required parameter" }; + const rawResponseBody = { + id: "165", + workspace_id: "this_is_an_id100_that_should_be_at_least_", + name: "Thanks for everything", + description: "", + created_at: 1734537312, + updated_at: 1734537312, + url: "http://help-center.test/myapp-100/", + icon: "book-bookmark", + order: 1, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { type: "group_content", name: "Collection name", description: " Collection description" }, + bg: { type: "group_content", name: "Collection name", description: " Collection description" }, + bs: { type: "group_content", name: "Collection name", description: " Collection description" }, + ca: { type: "group_content", name: "Collection name", description: " Collection description" }, + cs: { type: "group_content", name: "Collection name", description: " Collection description" }, + da: { type: "group_content", name: "Collection name", description: " Collection description" }, + de: { type: "group_content", name: "Collection name", description: " Collection description" }, + el: { type: "group_content", name: "Collection name", description: " Collection description" }, + en: { type: "group_content", name: "Collection name", description: " Collection description" }, + es: { type: "group_content", name: "Collection name", description: " Collection description" }, + et: { type: "group_content", name: "Collection name", description: " Collection description" }, + fi: { type: "group_content", name: "Collection name", description: " Collection description" }, + fr: { type: "group_content", name: "Collection name", description: " Collection description" }, + he: { type: "group_content", name: "Collection name", description: " Collection description" }, + hr: { type: "group_content", name: "Collection name", description: " Collection description" }, + hu: { type: "group_content", name: "Collection name", description: " Collection description" }, + id: { type: "group_content", name: "Collection name", description: " Collection description" }, + it: { type: "group_content", name: "Collection name", description: " Collection description" }, + ja: { type: "group_content", name: "Collection name", description: " Collection description" }, + ko: { type: "group_content", name: "Collection name", description: " Collection description" }, + lt: { type: "group_content", name: "Collection name", description: " Collection description" }, + lv: { type: "group_content", name: "Collection name", description: " Collection description" }, + mn: { type: "group_content", name: "Collection name", description: " Collection description" }, + nb: { type: "group_content", name: "Collection name", description: " Collection description" }, + nl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pt: { type: "group_content", name: "Collection name", description: " Collection description" }, + ro: { type: "group_content", name: "Collection name", description: " Collection description" }, + ru: { type: "group_content", name: "Collection name", description: " Collection description" }, + sl: { type: "group_content", name: "Collection name", description: " Collection description" }, + sr: { type: "group_content", name: "Collection name", description: " Collection description" }, + sv: { type: "group_content", name: "Collection name", description: " Collection description" }, + tr: { type: "group_content", name: "Collection name", description: " Collection description" }, + vi: { type: "group_content", name: "Collection name", description: " Collection description" }, + "pt-BR": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-CN": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-TW": { type: "group_content", name: "Collection name", description: " Collection description" }, + }, + parent_id: "6871118", + help_center_id: 81, + }; + server + .mockEndpoint() + .post("/help_center/collections") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.helpCenter.createCollection({ + name: "collection 51", + description: "Missing required parameter", + }); + expect(response).toEqual({ + id: "165", + workspace_id: "this_is_an_id100_that_should_be_at_least_", + name: "Thanks for everything", + description: "", + created_at: 1734537312, + updated_at: 1734537312, + url: "http://help-center.test/myapp-100/", + icon: "book-bookmark", + order: 1, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bg: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ca: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + cs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + da: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + de: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + el: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + en: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + es: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + et: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + he: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hu: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + id: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + it: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ja: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ko: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + mn: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nb: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ro: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ru: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + tr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + vi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "pt-BR": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-CN": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-TW": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + }, + parent_id: "6871118", + help_center_id: 81, + }); + }); + + test("createCollection (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "name" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/help_center/collections") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.helpCenter.createCollection({ + name: "name", + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("createCollection (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "name" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/help_center/collections") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.helpCenter.createCollection({ + name: "name", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveCollection (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + id: "170", + workspace_id: "this_is_an_id106_that_should_be_at_least_", + name: "English collection title", + description: "english collection description", + created_at: 1734537315, + updated_at: 1734537315, + url: "http://help-center.test/myapp-106/collection-22", + icon: "bookmark", + order: 22, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { type: "group_content", name: "Collection name", description: " Collection description" }, + bg: { type: "group_content", name: "Collection name", description: " Collection description" }, + bs: { type: "group_content", name: "Collection name", description: " Collection description" }, + ca: { type: "group_content", name: "Collection name", description: " Collection description" }, + cs: { type: "group_content", name: "Collection name", description: " Collection description" }, + da: { type: "group_content", name: "Collection name", description: " Collection description" }, + de: { type: "group_content", name: "Collection name", description: " Collection description" }, + el: { type: "group_content", name: "Collection name", description: " Collection description" }, + en: { type: "group_content", name: "Collection name", description: " Collection description" }, + es: { type: "group_content", name: "Collection name", description: " Collection description" }, + et: { type: "group_content", name: "Collection name", description: " Collection description" }, + fi: { type: "group_content", name: "Collection name", description: " Collection description" }, + fr: { type: "group_content", name: "Collection name", description: " Collection description" }, + he: { type: "group_content", name: "Collection name", description: " Collection description" }, + hr: { type: "group_content", name: "Collection name", description: " Collection description" }, + hu: { type: "group_content", name: "Collection name", description: " Collection description" }, + id: { type: "group_content", name: "Collection name", description: " Collection description" }, + it: { type: "group_content", name: "Collection name", description: " Collection description" }, + ja: { type: "group_content", name: "Collection name", description: " Collection description" }, + ko: { type: "group_content", name: "Collection name", description: " Collection description" }, + lt: { type: "group_content", name: "Collection name", description: " Collection description" }, + lv: { type: "group_content", name: "Collection name", description: " Collection description" }, + mn: { type: "group_content", name: "Collection name", description: " Collection description" }, + nb: { type: "group_content", name: "Collection name", description: " Collection description" }, + nl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pt: { type: "group_content", name: "Collection name", description: " Collection description" }, + ro: { type: "group_content", name: "Collection name", description: " Collection description" }, + ru: { type: "group_content", name: "Collection name", description: " Collection description" }, + sl: { type: "group_content", name: "Collection name", description: " Collection description" }, + sr: { type: "group_content", name: "Collection name", description: " Collection description" }, + sv: { type: "group_content", name: "Collection name", description: " Collection description" }, + tr: { type: "group_content", name: "Collection name", description: " Collection description" }, + vi: { type: "group_content", name: "Collection name", description: " Collection description" }, + "pt-BR": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-CN": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-TW": { type: "group_content", name: "Collection name", description: " Collection description" }, + }, + parent_id: "6871118", + help_center_id: 84, + }; + server + .mockEndpoint() + .get("/help_center/collections/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.helpCenter.retrieveCollection({ + id: 1, + }); + expect(response).toEqual({ + id: "170", + workspace_id: "this_is_an_id106_that_should_be_at_least_", + name: "English collection title", + description: "english collection description", + created_at: 1734537315, + updated_at: 1734537315, + url: "http://help-center.test/myapp-106/collection-22", + icon: "bookmark", + order: 22, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bg: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ca: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + cs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + da: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + de: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + el: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + en: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + es: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + et: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + he: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hu: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + id: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + it: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ja: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ko: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + mn: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nb: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ro: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ru: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + tr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + vi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "pt-BR": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-CN": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-TW": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + }, + parent_id: "6871118", + help_center_id: 84, + }); + }); + + test("retrieveCollection (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/help_center/collections/1") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.helpCenter.retrieveCollection({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveCollection (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/help_center/collections/1") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.helpCenter.retrieveCollection({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("updateCollection (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "Update collection name" }; + const rawResponseBody = { + id: "176", + workspace_id: "this_is_an_id112_that_should_be_at_least_", + name: "Update collection name", + description: "english collection description", + created_at: 1734537318, + updated_at: 1734537319, + url: "http://help-center.test/myapp-112/collection-25", + icon: "folder", + order: 25, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { type: "group_content", name: "Collection name", description: " Collection description" }, + bg: { type: "group_content", name: "Collection name", description: " Collection description" }, + bs: { type: "group_content", name: "Collection name", description: " Collection description" }, + ca: { type: "group_content", name: "Collection name", description: " Collection description" }, + cs: { type: "group_content", name: "Collection name", description: " Collection description" }, + da: { type: "group_content", name: "Collection name", description: " Collection description" }, + de: { type: "group_content", name: "Collection name", description: " Collection description" }, + el: { type: "group_content", name: "Collection name", description: " Collection description" }, + en: { type: "group_content", name: "Collection name", description: " Collection description" }, + es: { type: "group_content", name: "Collection name", description: " Collection description" }, + et: { type: "group_content", name: "Collection name", description: " Collection description" }, + fi: { type: "group_content", name: "Collection name", description: " Collection description" }, + fr: { type: "group_content", name: "Collection name", description: " Collection description" }, + he: { type: "group_content", name: "Collection name", description: " Collection description" }, + hr: { type: "group_content", name: "Collection name", description: " Collection description" }, + hu: { type: "group_content", name: "Collection name", description: " Collection description" }, + id: { type: "group_content", name: "Collection name", description: " Collection description" }, + it: { type: "group_content", name: "Collection name", description: " Collection description" }, + ja: { type: "group_content", name: "Collection name", description: " Collection description" }, + ko: { type: "group_content", name: "Collection name", description: " Collection description" }, + lt: { type: "group_content", name: "Collection name", description: " Collection description" }, + lv: { type: "group_content", name: "Collection name", description: " Collection description" }, + mn: { type: "group_content", name: "Collection name", description: " Collection description" }, + nb: { type: "group_content", name: "Collection name", description: " Collection description" }, + nl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pt: { type: "group_content", name: "Collection name", description: " Collection description" }, + ro: { type: "group_content", name: "Collection name", description: " Collection description" }, + ru: { type: "group_content", name: "Collection name", description: " Collection description" }, + sl: { type: "group_content", name: "Collection name", description: " Collection description" }, + sr: { type: "group_content", name: "Collection name", description: " Collection description" }, + sv: { type: "group_content", name: "Collection name", description: " Collection description" }, + tr: { type: "group_content", name: "Collection name", description: " Collection description" }, + vi: { type: "group_content", name: "Collection name", description: " Collection description" }, + "pt-BR": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-CN": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-TW": { type: "group_content", name: "Collection name", description: " Collection description" }, + }, + parent_id: "6871118", + help_center_id: 87, + }; + server + .mockEndpoint() + .put("/help_center/collections/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.helpCenter.updateCollection({ + id: 1, + name: "Update collection name", + }); + expect(response).toEqual({ + id: "176", + workspace_id: "this_is_an_id112_that_should_be_at_least_", + name: "Update collection name", + description: "english collection description", + created_at: 1734537318, + updated_at: 1734537319, + url: "http://help-center.test/myapp-112/collection-25", + icon: "folder", + order: 25, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bg: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ca: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + cs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + da: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + de: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + el: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + en: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + es: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + et: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + he: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hu: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + id: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + it: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ja: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ko: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + mn: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nb: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ro: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ru: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + tr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + vi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "pt-BR": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-CN": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-TW": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + }, + parent_id: "6871118", + help_center_id: 87, + }); + }); + + test("updateCollection (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "Update collection name" }; + const rawResponseBody = { + id: "176", + workspace_id: "this_is_an_id112_that_should_be_at_least_", + name: "Update collection name", + description: "english collection description", + created_at: 1734537318, + updated_at: 1734537319, + url: "http://help-center.test/myapp-112/collection-25", + icon: "folder", + order: 25, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { type: "group_content", name: "Collection name", description: " Collection description" }, + bg: { type: "group_content", name: "Collection name", description: " Collection description" }, + bs: { type: "group_content", name: "Collection name", description: " Collection description" }, + ca: { type: "group_content", name: "Collection name", description: " Collection description" }, + cs: { type: "group_content", name: "Collection name", description: " Collection description" }, + da: { type: "group_content", name: "Collection name", description: " Collection description" }, + de: { type: "group_content", name: "Collection name", description: " Collection description" }, + el: { type: "group_content", name: "Collection name", description: " Collection description" }, + en: { type: "group_content", name: "Collection name", description: " Collection description" }, + es: { type: "group_content", name: "Collection name", description: " Collection description" }, + et: { type: "group_content", name: "Collection name", description: " Collection description" }, + fi: { type: "group_content", name: "Collection name", description: " Collection description" }, + fr: { type: "group_content", name: "Collection name", description: " Collection description" }, + he: { type: "group_content", name: "Collection name", description: " Collection description" }, + hr: { type: "group_content", name: "Collection name", description: " Collection description" }, + hu: { type: "group_content", name: "Collection name", description: " Collection description" }, + id: { type: "group_content", name: "Collection name", description: " Collection description" }, + it: { type: "group_content", name: "Collection name", description: " Collection description" }, + ja: { type: "group_content", name: "Collection name", description: " Collection description" }, + ko: { type: "group_content", name: "Collection name", description: " Collection description" }, + lt: { type: "group_content", name: "Collection name", description: " Collection description" }, + lv: { type: "group_content", name: "Collection name", description: " Collection description" }, + mn: { type: "group_content", name: "Collection name", description: " Collection description" }, + nb: { type: "group_content", name: "Collection name", description: " Collection description" }, + nl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pl: { type: "group_content", name: "Collection name", description: " Collection description" }, + pt: { type: "group_content", name: "Collection name", description: " Collection description" }, + ro: { type: "group_content", name: "Collection name", description: " Collection description" }, + ru: { type: "group_content", name: "Collection name", description: " Collection description" }, + sl: { type: "group_content", name: "Collection name", description: " Collection description" }, + sr: { type: "group_content", name: "Collection name", description: " Collection description" }, + sv: { type: "group_content", name: "Collection name", description: " Collection description" }, + tr: { type: "group_content", name: "Collection name", description: " Collection description" }, + vi: { type: "group_content", name: "Collection name", description: " Collection description" }, + "pt-BR": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-CN": { type: "group_content", name: "Collection name", description: " Collection description" }, + "zh-TW": { type: "group_content", name: "Collection name", description: " Collection description" }, + }, + parent_id: "6871118", + help_center_id: 87, + }; + server + .mockEndpoint() + .put("/help_center/collections/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.helpCenter.updateCollection({ + id: 1, + name: "Update collection name", + }); + expect(response).toEqual({ + id: "176", + workspace_id: "this_is_an_id112_that_should_be_at_least_", + name: "Update collection name", + description: "english collection description", + created_at: 1734537318, + updated_at: 1734537319, + url: "http://help-center.test/myapp-112/collection-25", + icon: "folder", + order: 25, + default_locale: "en", + translated_content: { + type: "group_translated_content", + ar: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bg: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + bs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ca: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + cs: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + da: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + de: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + el: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + en: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + es: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + et: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + fr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + he: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + hu: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + id: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + it: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ja: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ko: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + lv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + mn: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nb: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + nl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + pt: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ro: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + ru: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sl: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + sv: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + tr: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + vi: { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "pt-BR": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-CN": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + "zh-TW": { + type: "group_content", + name: "Collection name", + description: " Collection description", + }, + }, + parent_id: "6871118", + help_center_id: 87, + }); + }); + + test("updateCollection (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/help_center/collections/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.helpCenter.updateCollection({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("updateCollection (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/help_center/collections/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.helpCenter.updateCollection({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("deleteCollection (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { id: "182", object: "collection", deleted: true }; + server + .mockEndpoint() + .delete("/help_center/collections/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.helpCenter.deleteCollection({ + id: 1, + }); + expect(response).toEqual({ + id: "182", + object: "collection", + deleted: true, + }); + }); + + test("deleteCollection (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/help_center/collections/1") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.helpCenter.deleteCollection({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("deleteCollection (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/help_center/collections/1") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.helpCenter.deleteCollection({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("retrieveHelpCenter (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + id: "93", + workspace_id: "this_is_an_id124_that_should_be_at_least_", + created_at: 1734537325, + updated_at: 1734537325, + identifier: "help-center-1", + website_turned_on: false, + display_name: "Intercom Help Center", + url: "https://help.mycompany.com", + custom_domain: "help.mycompany.com", + }; + server + .mockEndpoint() + .get("/help_center/help_centers/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.helpCenter.retrieveHelpCenter({ + id: 1, + }); + expect(response).toEqual({ + id: "93", + workspace_id: "this_is_an_id124_that_should_be_at_least_", + created_at: 1734537325, + updated_at: 1734537325, + identifier: "help-center-1", + website_turned_on: false, + display_name: "Intercom Help Center", + url: "https://help.mycompany.com", + custom_domain: "help.mycompany.com", + }); + }); + + test("retrieveHelpCenter (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/help_center/help_centers/1") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.helpCenter.retrieveHelpCenter({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveHelpCenter (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/help_center/help_centers/1") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.helpCenter.retrieveHelpCenter({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("listHelpCenters (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + id: "123", + workspace_id: "hfi1bx4l", + created_at: 1672928359, + updated_at: 1672928610, + identifier: "intercom", + website_turned_on: true, + display_name: "Intercom Help Center", + url: "https://help.mycompany.com", + custom_domain: "help.mycompany.com", + }, + ], + }; + server + .mockEndpoint() + .get("/help_center/help_centers") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.helpCenter.listHelpCenters(); + expect(response).toEqual({ + type: "list", + data: [ + { + id: "123", + workspace_id: "hfi1bx4l", + created_at: 1672928359, + updated_at: 1672928610, + identifier: "intercom", + website_turned_on: true, + display_name: "Intercom Help Center", + url: "https://help.mycompany.com", + custom_domain: "help.mycompany.com", + }, + ], + }); + }); + + test("listHelpCenters (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/help_center/help_centers") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.helpCenter.listHelpCenters(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); +}); diff --git a/tests/wire/unstable/internalArticles.test.ts b/tests/wire/unstable/internalArticles.test.ts new file mode 100644 index 00000000..b8d9b058 --- /dev/null +++ b/tests/wire/unstable/internalArticles.test.ts @@ -0,0 +1,655 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("InternalArticlesClient", () => { + test("listInternalArticles (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 25, + total_pages: 1, + }, + total_count: 1, + data: [ + { + type: "internal_article", + id: "39", + title: "Thanks for everything", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }, + ], + }; + server.mockEndpoint().get("/internal_articles").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.internalArticles.listInternalArticles(); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 25, + total_pages: 1, + }, + total_count: 1, + data: [ + { + type: "internal_article", + id: "39", + title: "Thanks for everything", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }, + ], + }); + }); + + test("listInternalArticles (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/internal_articles").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.internalArticles.listInternalArticles(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createInternalArticle (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Thanks for everything", + body: "Body of the Article", + author_id: 991266252, + owner_id: 991266252, + }; + const rawResponseBody = { + type: "internal_article", + id: "42", + title: "Thanks for everything", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }; + server + .mockEndpoint() + .post("/internal_articles") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.internalArticles.createInternalArticle({ + title: "Thanks for everything", + body: "Body of the Article", + author_id: 991266252, + owner_id: 991266252, + }); + expect(response).toEqual({ + type: "internal_article", + id: "42", + title: "Thanks for everything", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }); + }); + + test("createInternalArticle (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Thanks for everything", + body: "Body of the Internal Article", + author_id: 1295, + owner_id: 1295, + }; + const rawResponseBody = { + type: "internal_article", + id: "42", + title: "Thanks for everything", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }; + server + .mockEndpoint() + .post("/internal_articles") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.internalArticles.createInternalArticle({ + title: "Thanks for everything", + body: "Body of the Internal Article", + author_id: 1295, + owner_id: 1295, + }); + expect(response).toEqual({ + type: "internal_article", + id: "42", + title: "Thanks for everything", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }); + }); + + test("createInternalArticle (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/internal_articles") + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.internalArticles.createInternalArticle(undefined); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("createInternalArticle (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/internal_articles") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.internalArticles.createInternalArticle(undefined); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveInternalArticle (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "internal_article", + id: "45", + title: "title", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }; + server + .mockEndpoint() + .get("/internal_articles/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.internalArticles.retrieveInternalArticle({ + id: 1, + }); + expect(response).toEqual({ + type: "internal_article", + id: "45", + title: "title", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }); + }); + + test("retrieveInternalArticle (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/internal_articles/1") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.internalArticles.retrieveInternalArticle({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveInternalArticle (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/internal_articles/1") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.internalArticles.retrieveInternalArticle({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("updateInternalArticle (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "Christmas is here!", body: "

New gifts in store for the jolly season

" }; + const rawResponseBody = { + type: "internal_article", + id: "48", + title: "title", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }; + server + .mockEndpoint() + .put("/internal_articles/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.internalArticles.updateInternalArticle({ + id: 1, + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + }); + expect(response).toEqual({ + type: "internal_article", + id: "48", + title: "title", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }); + }); + + test("updateInternalArticle (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "Christmas is here!", body: "

New gifts in store for the jolly season

" }; + const rawResponseBody = { + type: "internal_article", + id: "48", + title: "title", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }; + server + .mockEndpoint() + .put("/internal_articles/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.internalArticles.updateInternalArticle({ + id: 1, + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + }); + expect(response).toEqual({ + type: "internal_article", + id: "48", + title: "title", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }); + }); + + test("updateInternalArticle (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/internal_articles/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.internalArticles.updateInternalArticle({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("updateInternalArticle (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/internal_articles/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.internalArticles.updateInternalArticle({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("deleteInternalArticle (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { id: "51", object: "internal_article", deleted: true }; + server + .mockEndpoint() + .delete("/internal_articles/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.internalArticles.deleteInternalArticle({ + id: 1, + }); + expect(response).toEqual({ + id: "51", + object: "internal_article", + deleted: true, + }); + }); + + test("deleteInternalArticle (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/internal_articles/1") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.internalArticles.deleteInternalArticle({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("deleteInternalArticle (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/internal_articles/1") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.internalArticles.deleteInternalArticle({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("searchInternalArticles (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + total_count: 1, + data: { + internal_articles: [ + { + id: "55", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }, + ], + }, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 10, + total_pages: 1, + }, + }; + server + .mockEndpoint() + .get("/internal_articles/search") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.internalArticles.searchInternalArticles({ + folder_id: "folder_id", + }); + expect(response).toEqual({ + type: "list", + total_count: 1, + data: { + internal_articles: [ + { + id: "55", + body: "Body of the Article", + owner_id: 991266252, + author_id: 991266252, + created_at: 1672928359, + updated_at: 1672928610, + locale: "en", + }, + ], + }, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 10, + total_pages: 1, + }, + }); + }); + + test("searchInternalArticles (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/internal_articles/search") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.internalArticles.searchInternalArticles(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); +}); diff --git a/tests/wire/unstable/jobs.test.ts b/tests/wire/unstable/jobs.test.ts new file mode 100644 index 00000000..7e511aee --- /dev/null +++ b/tests/wire/unstable/jobs.test.ts @@ -0,0 +1,79 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("JobsClient", () => { + test("status (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "job", + id: "2", + url: "https://api.intercom.io/jobs/status/20", + status: "success", + resource_type: "ticket", + resource_id: "20", + resource_url: "https://api.intercom.io/tickets/20", + }; + server.mockEndpoint().get("/jobs/status/id").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.jobs.status({ + id: "id", + }); + expect(response).toEqual({ + type: "job", + id: "2", + url: "https://api.intercom.io/jobs/status/20", + status: "success", + resource_type: "ticket", + resource_id: "20", + resource_url: "https://api.intercom.io/tickets/20", + }); + }); + + test("status (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/jobs/status/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.jobs.status({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("status (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/jobs/status/id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.jobs.status({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); +}); diff --git a/tests/wire/unstable/macros.test.ts b/tests/wire/unstable/macros.test.ts new file mode 100644 index 00000000..04168725 --- /dev/null +++ b/tests/wire/unstable/macros.test.ts @@ -0,0 +1,699 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("MacrosClient", () => { + test("listMacros (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "macro", + id: "123", + name: "Order Status Update", + body: '

Hi , your order # is ready for pickup!

', + body_text: 'Hi {{user.name|fallback:"there"}}, your order #{{order.number}} is ready for pickup!', + created_at: "2025-07-17T11:18:08Z", + updated_at: "2025-07-17T15:30:24Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox", "messenger"], + }, + { + type: "macro", + id: "456", + name: "Welcome Message", + body: '

Welcome to our support! I\'m . How can I help you today?

', + body_text: "Welcome to our support! I'm {{teammate.name}}. How can I help you today?", + created_at: "2025-07-21T14:44:35Z", + updated_at: "2025-07-21T14:44:35Z", + visible_to: "specific_teams", + visible_to_team_ids: ["789", "101"], + available_on: ["inbox"], + }, + ], + pages: { type: "pages", per_page: 50, next: { starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd" } }, + }; + server.mockEndpoint().get("/macros").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.macros.listMacros({ + per_page: 1, + starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + updated_since: 1000000, + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "macro", + id: "123", + name: "Order Status Update", + body: '

Hi , your order # is ready for pickup!

', + body_text: 'Hi {{user.name|fallback:"there"}}, your order #{{order.number}} is ready for pickup!', + created_at: "2025-07-17T11:18:08Z", + updated_at: "2025-07-17T15:30:24Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox", "messenger"], + }, + { + type: "macro", + id: "456", + name: "Welcome Message", + body: '

Welcome to our support! I\'m . How can I help you today?

', + body_text: "Welcome to our support! I'm {{teammate.name}}. How can I help you today?", + created_at: "2025-07-21T14:44:35Z", + updated_at: "2025-07-21T14:44:35Z", + visible_to: "specific_teams", + visible_to_team_ids: ["789", "101"], + available_on: ["inbox"], + }, + ], + pages: { + type: "pages", + per_page: 50, + next: { + starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + }, + }, + }); + }); + + test("listMacros (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "macro", + id: "789", + name: "Refund Process", + body: '

I understand you\'d like a refund for order #. The refund will be processed within 3-5 business days.

', + body_text: + "I understand you'd like a refund for order #{{conversation.custom_attributes.order_number}}. The refund will be processed within 3-5 business days.", + created_at: "2025-07-21T07:15:34Z", + updated_at: "2025-07-21T07:15:34Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox", "messenger"], + }, + { + type: "macro", + id: "101", + name: "Product Inquiry Response", + body: '

Thank you for your interest in . I\'d be happy to provide more information!

', + body_text: + 'Thank you for your interest in {{product.name|fallback:"our products"}}. I\'d be happy to provide more information!', + created_at: "2025-07-20T05:33:20Z", + updated_at: "2025-07-21T10:00:00Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox", "messenger"], + }, + ], + pages: { type: "pages", per_page: 50, next: { starting_after: "WzE3MTk0MDAwMDAuMCwgIjEwMSJd" } }, + }; + server.mockEndpoint().get("/macros").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.macros.listMacros({ + per_page: 1, + starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + updated_since: 1000000, + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "macro", + id: "789", + name: "Refund Process", + body: '

I understand you\'d like a refund for order #. The refund will be processed within 3-5 business days.

', + body_text: + "I understand you'd like a refund for order #{{conversation.custom_attributes.order_number}}. The refund will be processed within 3-5 business days.", + created_at: "2025-07-21T07:15:34Z", + updated_at: "2025-07-21T07:15:34Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox", "messenger"], + }, + { + type: "macro", + id: "101", + name: "Product Inquiry Response", + body: '

Thank you for your interest in . I\'d be happy to provide more information!

', + body_text: + 'Thank you for your interest in {{product.name|fallback:"our products"}}. I\'d be happy to provide more information!', + created_at: "2025-07-20T05:33:20Z", + updated_at: "2025-07-21T10:00:00Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox", "messenger"], + }, + ], + pages: { + type: "pages", + per_page: 50, + next: { + starting_after: "WzE3MTk0MDAwMDAuMCwgIjEwMSJd", + }, + }, + }); + }); + + test("listMacros (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "macro", + id: "234", + name: "Shipping Update Template", + body: '

Your order has been shipped via . Tracking number:

', + body_text: + 'Your order has been shipped via {{shipping.carrier|fallback:"our shipping partner"}}. Tracking number: {{shipping.tracking_number}}', + created_at: "2025-07-22T05:31:01Z", + updated_at: "2025-07-22T18:45:12Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox"], + }, + ], + pages: { type: "pages", per_page: 50, next: { starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd" } }, + }; + server.mockEndpoint().get("/macros").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.macros.listMacros({ + per_page: 1, + starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + updated_since: 1000000, + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "macro", + id: "234", + name: "Shipping Update Template", + body: '

Your order has been shipped via . Tracking number:

', + body_text: + 'Your order has been shipped via {{shipping.carrier|fallback:"our shipping partner"}}. Tracking number: {{shipping.tracking_number}}', + created_at: "2025-07-22T05:31:01Z", + updated_at: "2025-07-22T18:45:12Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox"], + }, + ], + pages: { + type: "pages", + per_page: 50, + next: { + starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + }, + }, + }); + }); + + test("listMacros (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "macro", + id: "567", + name: "Account Status Review", + body: '

Hi ,

Your account status:

Last activity:

', + body_text: + 'Hi {{user.first_name|fallback:"there"}},\n\nYour account status: {{user.custom_attributes.account_status|fallback:"pending review"}}\n\nLast activity: {{user.last_seen_at}}', + created_at: "2025-07-21T09:00:00Z", + updated_at: "2025-07-21T09:00:00Z", + visible_to: "specific_teams", + visible_to_team_ids: ["security_team"], + available_on: ["inbox"], + }, + ], + pages: { type: "pages", per_page: 50, next: { starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd" } }, + }; + server.mockEndpoint().get("/macros").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.macros.listMacros({ + per_page: 1, + starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + updated_since: 1000000, + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "macro", + id: "567", + name: "Account Status Review", + body: '

Hi ,

Your account status:

Last activity:

', + body_text: + 'Hi {{user.first_name|fallback:"there"}},\n\nYour account status: {{user.custom_attributes.account_status|fallback:"pending review"}}\n\nLast activity: {{user.last_seen_at}}', + created_at: "2025-07-21T09:00:00Z", + updated_at: "2025-07-21T09:00:00Z", + visible_to: "specific_teams", + visible_to_team_ids: ["security_team"], + available_on: ["inbox"], + }, + ], + pages: { + type: "pages", + per_page: 50, + next: { + starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + }, + }, + }); + }); + + test("listMacros (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "macro", + id: "123", + name: "Order Status Update", + body: '

Hi , your order is ready!

', + body_text: 'Hi {{user.name|fallback:"there"}}, your order is ready!', + created_at: "2025-07-17T11:18:08Z", + updated_at: "2025-07-17T15:30:24Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox", "messenger"], + }, + ], + pages: { type: "pages", per_page: 50, next: { starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd" } }, + }; + server.mockEndpoint().get("/macros").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.macros.listMacros({ + per_page: 1, + starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + updated_since: 1000000, + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "macro", + id: "123", + name: "Order Status Update", + body: '

Hi , your order is ready!

', + body_text: 'Hi {{user.name|fallback:"there"}}, your order is ready!', + created_at: "2025-07-17T11:18:08Z", + updated_at: "2025-07-17T15:30:24Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox", "messenger"], + }, + ], + pages: { + type: "pages", + per_page: 50, + next: { + starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + }, + }, + }); + }); + + test("listMacros (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "macro", + id: "1001", + name: "Quick Response 1", + body: '

Hi , your order is ready!

', + body_text: 'Hi {{user.name|fallback:"there"}}, your order is ready!', + created_at: "2025-07-22T11:08:20Z", + updated_at: "2025-07-23T11:08:20Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox"], + }, + ], + pages: { type: "pages", per_page: 50, next: { starting_after: "WzE3MTk0OTAxMDAuMCwgIjEwMDIiXQ==" } }, + }; + server.mockEndpoint().get("/macros").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.macros.listMacros({ + per_page: 1, + starting_after: "WzE3MTk0OTM3NTcuMCwgIjEyMyJd", + updated_since: 1000000, + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "macro", + id: "1001", + name: "Quick Response 1", + body: '

Hi , your order is ready!

', + body_text: 'Hi {{user.name|fallback:"there"}}, your order is ready!', + created_at: "2025-07-22T11:08:20Z", + updated_at: "2025-07-23T11:08:20Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox"], + }, + ], + pages: { + type: "pages", + per_page: 50, + next: { + starting_after: "WzE3MTk0OTAxMDAuMCwgIjEwMDIiXQ==", + }, + }, + }); + }); + + test("listMacros (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/macros").respondWith().statusCode(400).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.macros.listMacros(); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("listMacros (8)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/macros").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.macros.listMacros(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("listMacros (9)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/macros").respondWith().statusCode(403).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.macros.listMacros(); + }).rejects.toThrow(Intercom.unstable.ForbiddenError); + }); + + test("getMacro (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "macro", + id: "789", + name: "Refund Process Explanation", + body: '

Hi ,

I understand you\'d like a refund for order #. The refund will be processed within 3-5 business days to your .

Is there anything else I can help you with?

', + body_text: + 'Hi {{user.first_name|fallback:"there"}},\n\nI understand you\'d like a refund for order #{{conversation.custom_attributes.order_number}}. The refund will be processed within 3-5 business days to your {{user.custom_attributes.payment_method|fallback:"original payment method"}}.\n\nIs there anything else I can help you with?', + created_at: "2025-07-21T14:44:35Z", + updated_at: "2025-07-21T14:44:35Z", + visible_to: "specific_teams", + visible_to_team_ids: ["support_team_1", "support_team_2"], + available_on: ["inbox", "messenger"], + }; + server.mockEndpoint().get("/macros/123").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.macros.getMacro({ + id: "123", + }); + expect(response).toEqual({ + type: "macro", + id: "789", + name: "Refund Process Explanation", + body: '

Hi ,

I understand you\'d like a refund for order #. The refund will be processed within 3-5 business days to your .

Is there anything else I can help you with?

', + body_text: + 'Hi {{user.first_name|fallback:"there"}},\n\nI understand you\'d like a refund for order #{{conversation.custom_attributes.order_number}}. The refund will be processed within 3-5 business days to your {{user.custom_attributes.payment_method|fallback:"original payment method"}}.\n\nIs there anything else I can help you with?', + created_at: "2025-07-21T14:44:35Z", + updated_at: "2025-07-21T14:44:35Z", + visible_to: "specific_teams", + visible_to_team_ids: ["support_team_1", "support_team_2"], + available_on: ["inbox", "messenger"], + }); + }); + + test("getMacro (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "macro", + id: "456", + name: "Product Demo Request", + body: '

Hello ,

Thank you for your interest in ! I\'d love to schedule a personalized demo for your team at .

Would work for you?

', + body_text: + 'Hello {{user.name|fallback:"valued customer"}},\n\nThank you for your interest in {{product.name|fallback:"our products"}}! I\'d love to schedule a personalized demo for your team at {{company.name|fallback:"your company"}}.\n\nWould {{suggested_time|fallback:"next Tuesday at 2 PM EST"}} work for you?', + created_at: "2025-07-22T11:06:40Z", + updated_at: "2025-07-23T00:00:00Z", + visible_to: "specific_teams", + visible_to_team_ids: ["sales_team_us", "sales_team_eu"], + available_on: ["messenger"], + }; + server.mockEndpoint().get("/macros/123").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.macros.getMacro({ + id: "123", + }); + expect(response).toEqual({ + type: "macro", + id: "456", + name: "Product Demo Request", + body: '

Hello ,

Thank you for your interest in ! I\'d love to schedule a personalized demo for your team at .

Would work for you?

', + body_text: + 'Hello {{user.name|fallback:"valued customer"}},\n\nThank you for your interest in {{product.name|fallback:"our products"}}! I\'d love to schedule a personalized demo for your team at {{company.name|fallback:"your company"}}.\n\nWould {{suggested_time|fallback:"next Tuesday at 2 PM EST"}} work for you?', + created_at: "2025-07-22T11:06:40Z", + updated_at: "2025-07-23T00:00:00Z", + visible_to: "specific_teams", + visible_to_team_ids: ["sales_team_us", "sales_team_eu"], + available_on: ["messenger"], + }); + }); + + test("getMacro (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "macro", + id: "890", + name: "API Integration Help", + body: '

Hi ,

I see you\'re having trouble with the integration. Your API key for app is configured correctly.

Error code:

Let me help you resolve this issue.

', + body_text: + 'Hi {{user.name}},\n\nI see you\'re having trouble with the {{conversation.custom_attributes.api_endpoint|fallback:"API"}} integration. Your API key for app {{app.id}} is configured correctly.\n\nError code: {{conversation.custom_attributes.error_code|fallback:"unknown"}}\n\nLet me help you resolve this issue.', + created_at: "2025-07-18T09:15:00Z", + updated_at: "2025-07-18T09:15:00Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox"], + }; + server.mockEndpoint().get("/macros/123").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.macros.getMacro({ + id: "123", + }); + expect(response).toEqual({ + type: "macro", + id: "890", + name: "API Integration Help", + body: '

Hi ,

I see you\'re having trouble with the integration. Your API key for app is configured correctly.

Error code:

Let me help you resolve this issue.

', + body_text: + 'Hi {{user.name}},\n\nI see you\'re having trouble with the {{conversation.custom_attributes.api_endpoint|fallback:"API"}} integration. Your API key for app {{app.id}} is configured correctly.\n\nError code: {{conversation.custom_attributes.error_code|fallback:"unknown"}}\n\nLet me help you resolve this issue.', + created_at: "2025-07-18T09:15:00Z", + updated_at: "2025-07-18T09:15:00Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox"], + }); + }); + + test("getMacro (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "macro", + id: "123", + name: "Thank You Response", + body: "

Thank you for reaching out! We appreciate your message and will get back to you as soon as possible.

", + body_text: + "Thank you for reaching out! We appreciate your message and will get back to you as soon as possible.", + created_at: "2025-07-17T11:18:08Z", + updated_at: "2025-07-17T15:30:24Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox", "messenger"], + }; + server.mockEndpoint().get("/macros/123").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.macros.getMacro({ + id: "123", + }); + expect(response).toEqual({ + type: "macro", + id: "123", + name: "Thank You Response", + body: "

Thank you for reaching out! We appreciate your message and will get back to you as soon as possible.

", + body_text: + "Thank you for reaching out! We appreciate your message and will get back to you as soon as possible.", + created_at: "2025-07-17T11:18:08Z", + updated_at: "2025-07-17T15:30:24Z", + visible_to: "everyone", + visible_to_team_ids: ["456", "789"], + available_on: ["inbox", "messenger"], + }); + }); + + test("getMacro (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/macros/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.macros.getMacro({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("getMacro (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/macros/id").respondWith().statusCode(403).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.macros.getMacro({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.ForbiddenError); + }); + + test("getMacro (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/macros/id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.macros.getMacro({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); +}); diff --git a/tests/wire/unstable/messages.test.ts b/tests/wire/unstable/messages.test.ts new file mode 100644 index 00000000..7b0b98a4 --- /dev/null +++ b/tests/wire/unstable/messages.test.ts @@ -0,0 +1,766 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("MessagesClient", () => { + test("createMessage (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + from: { type: "user", id: "6762f2341bb69f9f2193bc17" }, + body: "heyy", + referer: "https://twitter.com/bob", + }; + const rawResponseBody = { + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.messages.createMessage({ + from: { + type: "user", + id: "6762f2341bb69f9f2193bc17", + }, + body: "heyy", + referer: "https://twitter.com/bob", + }); + expect(response).toEqual({ + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }); + }); + + test("createMessage (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + from: { type: "lead", id: "6762f2371bb69f9f2193bc18" }, + body: "heyy", + referer: "https://twitter.com/bob", + }; + const rawResponseBody = { + type: "user_message", + id: "403918397", + created_at: 1734537783, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "614", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.messages.createMessage({ + from: { + type: "lead", + id: "6762f2371bb69f9f2193bc18", + }, + body: "heyy", + referer: "https://twitter.com/bob", + }); + expect(response).toEqual({ + type: "user_message", + id: "403918397", + created_at: 1734537783, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "614", + }); + }); + + test("createMessage (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + from: { type: "admin", id: "991267816" }, + to: [ + { type: "user", id: "6762f2391bb69f9f2193bc19" }, + { type: "lead", id: "6762f23c1bb69f9f2193bc1b" }, + { type: "user", id: "6762f23d1bb69f9f2193bc1c" }, + ], + cc: [ + { type: "user", id: "6762f23e1bb69f9f2193bc1d" }, + { type: "user", id: "6762f23f1bb69f9f2193bc1e" }, + ], + bcc: [{ type: "user", id: "6762f23e1bb69f9f2193bc2f" }], + message_type: "conversation", + body: "heyy", + }; + const rawResponseBody = { + type: "admin_message", + id: "19", + created_at: 1734537786, + subject: "heyy", + body: "heyy", + message_type: "inapp", + conversation_id: "64619700005570", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.messages.createMessage({ + from: { + type: "admin", + id: "991267816", + }, + to: [ + { + type: "user", + id: "6762f2391bb69f9f2193bc19", + }, + { + type: "lead", + id: "6762f23c1bb69f9f2193bc1b", + }, + { + type: "user", + id: "6762f23d1bb69f9f2193bc1c", + }, + ], + cc: [ + { + type: "user", + id: "6762f23e1bb69f9f2193bc1d", + }, + { + type: "user", + id: "6762f23f1bb69f9f2193bc1e", + }, + ], + bcc: [ + { + type: "user", + id: "6762f23e1bb69f9f2193bc2f", + }, + ], + message_type: "conversation", + body: "heyy", + }); + expect(response).toEqual({ + type: "admin_message", + id: "19", + created_at: 1734537786, + subject: "heyy", + body: "heyy", + message_type: "inapp", + conversation_id: "64619700005570", + }); + }); + + test("createMessage (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + from: { type: "admin", id: "991267817" }, + to: { type: "user", id: "6762f23a1bb69f9f2193bc1a" }, + message_type: "sms", + body: "heyy", + }; + const rawResponseBody = { + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.messages.createMessage({ + from: { + type: "admin", + id: "991267817", + }, + to: { + type: "user", + id: "6762f23a1bb69f9f2193bc1a", + }, + message_type: "sms", + body: "heyy", + }); + expect(response).toEqual({ + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }); + }); + + test("createMessage (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + from: { type: "admin", id: "991267817" }, + to: { phone: 5547999998888, name: "John Doe" }, + message_type: "whatsapp", + components: [{ type: "BODY", parameters: [{ type: "text", text: "Username 123" }] }], + template: "keep_live", + locale: "en", + }; + const rawResponseBody = { + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.messages.createMessage({ + from: { + type: "admin", + id: "991267817", + }, + to: { + phone: 5547999998888, + name: "John Doe", + }, + message_type: "whatsapp", + components: [ + { + type: "BODY", + parameters: [ + { + type: "text", + text: "Username 123", + }, + ], + }, + ], + template: "keep_live", + locale: "en", + }); + expect(response).toEqual({ + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }); + }); + + test("createMessage (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + from: { type: "admin", id: "991267818" }, + to: { type: "user", id: "6762f23b1bb69f9f2193bc1a" }, + message_type: "inapp", + subject: "heyy", + }; + const rawResponseBody = { + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.messages.createMessage({ + from: { + type: "admin", + id: "991267818", + }, + to: { + type: "user", + id: "6762f23b1bb69f9f2193bc1a", + }, + message_type: "inapp", + subject: "heyy", + }); + expect(response).toEqual({ + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }); + }); + + test("createMessage (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + from: { type: "admin", id: "991267819" }, + to: { type: "user", user_id: "70" }, + message_type: "email", + body: "hey there", + }; + const rawResponseBody = { + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.messages.createMessage({ + from: { + type: "admin", + id: "991267819", + }, + to: { + type: "user", + user_id: "70", + }, + message_type: "email", + body: "hey there", + }); + expect(response).toEqual({ + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }); + }); + + test("createMessage (8)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + from: { type: "admin", id: "991267820" }, + to: { type: "user", id: "6762f23d1bb69f9f2193bc1c" }, + message_type: "email", + subject: "heyy", + }; + const rawResponseBody = { + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.messages.createMessage({ + from: { + type: "admin", + id: "991267820", + }, + to: { + type: "user", + id: "6762f23d1bb69f9f2193bc1c", + }, + message_type: "email", + subject: "heyy", + }); + expect(response).toEqual({ + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }); + }); + + test("createMessage (9)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + from: { type: "admin", id: "991267821" }, + to: { type: "user", id: "6762f23b1bb69f9f2193bc1d" }, + message_type: "sms", + body: "heyy https://picsum.photos/200/300", + }; + const rawResponseBody = { + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }; + server + .mockEndpoint() + .post("/messages") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.messages.createMessage({ + from: { + type: "admin", + id: "991267821", + }, + to: { + type: "user", + id: "6762f23b1bb69f9f2193bc1d", + }, + message_type: "sms", + body: "heyy https://picsum.photos/200/300", + }); + expect(response).toEqual({ + type: "user_message", + id: "403918396", + created_at: 1734537780, + subject: "Greetings", + body: "heyy", + message_type: "inapp", + conversation_id: "613", + }); + }); + + test("createMessage (10)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().post("/messages").respondWith().statusCode(400).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.messages.createMessage(undefined); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("createMessage (11)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().post("/messages").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.messages.createMessage(undefined); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createMessage (12)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().post("/messages").respondWith().statusCode(403).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.messages.createMessage(undefined); + }).rejects.toThrow(Intercom.unstable.ForbiddenError); + }); + + test("createMessage (13)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().post("/messages").respondWith().statusCode(422).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.messages.createMessage(undefined); + }).rejects.toThrow(Intercom.unstable.UnprocessableEntityError); + }); + + test("getWhatsAppMessageStatus (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + ruleset_id: "ruleset_id", + pages: { type: "pages", per_page: 50, total_pages: 3, next: { starting_after: "abc123" } }, + total_count: 125, + events: [ + { + id: "event_1", + conversation_id: "conv_123", + status: "delivered", + type: "broadcast_outbound", + created_at: 1734537980, + updated_at: 1734538000, + whatsapp_message_id: "wamid_123", + template_name: "appointment_reminder", + }, + { + id: "event_2", + conversation_id: "conv_456", + status: "sent", + type: "broadcast_outbound", + created_at: 1734537970, + updated_at: 1734538010, + whatsapp_message_id: "wamid_456", + template_name: "order_update", + }, + ], + }; + server.mockEndpoint().get("/messages/status").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.messages.getWhatsAppMessageStatus({ + ruleset_id: "ruleset_id", + per_page: 1, + starting_after: "starting_after", + }); + expect(response).toEqual({ + type: "list", + ruleset_id: "ruleset_id", + pages: { + type: "pages", + per_page: 50, + total_pages: 3, + next: { + starting_after: "abc123", + }, + }, + total_count: 125, + events: [ + { + id: "event_1", + conversation_id: "conv_123", + status: "delivered", + type: "broadcast_outbound", + created_at: 1734537980, + updated_at: 1734538000, + whatsapp_message_id: "wamid_123", + template_name: "appointment_reminder", + }, + { + id: "event_2", + conversation_id: "conv_456", + status: "sent", + type: "broadcast_outbound", + created_at: 1734537970, + updated_at: 1734538010, + whatsapp_message_id: "wamid_456", + template_name: "order_update", + }, + ], + }); + }); + + test("getWhatsAppMessageStatus (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/messages/status").respondWith().statusCode(400).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.messages.getWhatsAppMessageStatus({ + ruleset_id: "ruleset_id", + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("getWhatsAppMessageStatus (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/messages/status").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.messages.getWhatsAppMessageStatus({ + ruleset_id: "ruleset_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("getWhatsAppMessageStatus (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/messages/status").respondWith().statusCode(403).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.messages.getWhatsAppMessageStatus({ + ruleset_id: "ruleset_id", + }); + }).rejects.toThrow(Intercom.unstable.ForbiddenError); + }); + + test("getWhatsAppMessageStatus (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/messages/status").respondWith().statusCode(500).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.messages.getWhatsAppMessageStatus({ + ruleset_id: "ruleset_id", + }); + }).rejects.toThrow(Intercom.unstable.InternalServerError); + }); +}); diff --git a/tests/wire/unstable/news.test.ts b/tests/wire/unstable/news.test.ts new file mode 100644 index 00000000..6ee5092f --- /dev/null +++ b/tests/wire/unstable/news.test.ts @@ -0,0 +1,864 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("NewsClient", () => { + test("listNewsItems (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 10, + total_pages: 1, + }, + total_count: 2, + data: [ + { + type: "news-item", + id: "141", + workspace_id: "t74hdn32", + title: "New feature: News Items", + body: "We are excited to announce the launch of News Items, a new content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers.", + sender_id: 123, + state: "draft", + newsfeed_assignments: [{ newsfeed_id: 198313, published_at: 1674917488 }], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["👍"], + deliver_silently: true, + created_at: 1610589632, + updated_at: 1610589632, + }, + { + type: "news-item", + id: "141", + workspace_id: "t74hdn32", + title: "New feature: News Items", + body: "We are excited to announce the launch of News Items, a new content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers.", + sender_id: 123, + state: "draft", + newsfeed_assignments: [{ newsfeed_id: 198313, published_at: 1674917488 }], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["👍"], + deliver_silently: true, + created_at: 1610589632, + updated_at: 1610589632, + }, + ], + }; + server.mockEndpoint().get("/news/news_items").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.news.listNewsItems(); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 10, + total_pages: 1, + }, + total_count: 2, + data: [ + { + type: "news-item", + id: "141", + workspace_id: "t74hdn32", + title: "New feature: News Items", + body: "We are excited to announce the launch of News Items, a new content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers.", + sender_id: 123, + state: "draft", + newsfeed_assignments: [ + { + newsfeed_id: 198313, + published_at: 1674917488, + }, + ], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["\uD83D\uDC4D"], + deliver_silently: true, + created_at: 1610589632, + updated_at: 1610589632, + }, + { + type: "news-item", + id: "141", + workspace_id: "t74hdn32", + title: "New feature: News Items", + body: "We are excited to announce the launch of News Items, a new content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers.", + sender_id: 123, + state: "draft", + newsfeed_assignments: [ + { + newsfeed_id: 198313, + published_at: 1674917488, + }, + ], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["\uD83D\uDC4D"], + deliver_silently: true, + created_at: 1610589632, + updated_at: 1610589632, + }, + ], + }); + }); + + test("listNewsItems (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/news/news_items").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.news.listNewsItems(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createNewsItem (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Halloween is here!", + body: "

New costumes in store for this spooky season

", + sender_id: 991267834, + state: "live", + deliver_silently: true, + labels: ["Product", "Update", "New"], + reactions: ["😆", "😅"], + newsfeed_assignments: [{ newsfeed_id: 53, published_at: 1664638214 }], + }; + const rawResponseBody = { + type: "news-item", + id: "33", + workspace_id: "this_is_an_id534_that_should_be_at_least_", + title: "Halloween is here!", + body: "

New costumes in store for this spooky season

", + sender_id: 991267834, + state: "live", + newsfeed_assignments: [{ newsfeed_id: 53, published_at: 1664638214 }], + labels: ["New", "Product", "Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["😆", "😅"], + deliver_silently: true, + created_at: 1734537797, + updated_at: 1734537797, + }; + server + .mockEndpoint() + .post("/news/news_items") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.news.createNewsItem({ + title: "Halloween is here!", + body: "

New costumes in store for this spooky season

", + sender_id: 991267834, + state: "live", + deliver_silently: true, + labels: ["Product", "Update", "New"], + reactions: ["\uD83D\uDE06", "\uD83D\uDE05"], + newsfeed_assignments: [ + { + newsfeed_id: 53, + published_at: 1664638214, + }, + ], + }); + expect(response).toEqual({ + type: "news-item", + id: "33", + workspace_id: "this_is_an_id534_that_should_be_at_least_", + title: "Halloween is here!", + body: "

New costumes in store for this spooky season

", + sender_id: 991267834, + state: "live", + newsfeed_assignments: [ + { + newsfeed_id: 53, + published_at: 1664638214, + }, + ], + labels: ["New", "Product", "Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["\uD83D\uDE06", "\uD83D\uDE05"], + deliver_silently: true, + created_at: 1734537797, + updated_at: 1734537797, + }); + }); + + test("createNewsItem (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "title", sender_id: 1 }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/news/news_items") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.news.createNewsItem({ + title: "title", + sender_id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveNewsItem (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "news-item", + id: "34", + workspace_id: "this_is_an_id538_that_should_be_at_least_", + title: "We have news", + body: "

Hello there,

", + sender_id: 991267837, + state: "live", + newsfeed_assignments: [{ newsfeed_id: 55, published_at: 1734537800 }], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["👍", "👍", "👍", "👍"], + deliver_silently: false, + created_at: 1734537800, + updated_at: 1734537800, + }; + server.mockEndpoint().get("/news/news_items/1").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.news.retrieveNewsItem({ + id: 1, + }); + expect(response).toEqual({ + type: "news-item", + id: "34", + workspace_id: "this_is_an_id538_that_should_be_at_least_", + title: "We have news", + body: "

Hello there,

", + sender_id: 991267837, + state: "live", + newsfeed_assignments: [ + { + newsfeed_id: 55, + published_at: 1734537800, + }, + ], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["\uD83D\uDC4D", "\uD83D\uDC4D", "\uD83D\uDC4D", "\uD83D\uDC4D"], + deliver_silently: false, + created_at: 1734537800, + updated_at: 1734537800, + }); + }); + + test("retrieveNewsItem (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/news/news_items/1").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.news.retrieveNewsItem({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveNewsItem (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/news/news_items/1").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.news.retrieveNewsItem({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("updateNewsItem (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + reactions: ["😝", "😂"], + }; + const rawResponseBody = { + type: "news-item", + id: "37", + workspace_id: "this_is_an_id544_that_should_be_at_least_", + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + state: "live", + newsfeed_assignments: [{ newsfeed_id: 198313, published_at: 1674917488 }], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["😝", "😂"], + deliver_silently: false, + created_at: 1734537803, + updated_at: 1734537804, + }; + server + .mockEndpoint() + .put("/news/news_items/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.news.updateNewsItem({ + id: 1, + body: { + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"], + }, + }); + expect(response).toEqual({ + type: "news-item", + id: "37", + workspace_id: "this_is_an_id544_that_should_be_at_least_", + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + state: "live", + newsfeed_assignments: [ + { + newsfeed_id: 198313, + published_at: 1674917488, + }, + ], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"], + deliver_silently: false, + created_at: 1734537803, + updated_at: 1734537804, + }); + }); + + test("updateNewsItem (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267848, + reactions: ["😝", "😂"], + }; + const rawResponseBody = { + type: "news-item", + id: "37", + workspace_id: "this_is_an_id544_that_should_be_at_least_", + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + state: "live", + newsfeed_assignments: [{ newsfeed_id: 198313, published_at: 1674917488 }], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["😝", "😂"], + deliver_silently: false, + created_at: 1734537803, + updated_at: 1734537804, + }; + server + .mockEndpoint() + .put("/news/news_items/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.news.updateNewsItem({ + id: 1, + body: { + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267848, + reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"], + }, + }); + expect(response).toEqual({ + type: "news-item", + id: "37", + workspace_id: "this_is_an_id544_that_should_be_at_least_", + title: "Christmas is here!", + body: "

New gifts in store for the jolly season

", + sender_id: 991267845, + state: "live", + newsfeed_assignments: [ + { + newsfeed_id: 198313, + published_at: 1674917488, + }, + ], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["\uD83D\uDE1D", "\uD83D\uDE02"], + deliver_silently: false, + created_at: 1734537803, + updated_at: 1734537804, + }); + }); + + test("updateNewsItem (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "title", sender_id: 1 }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/news/news_items/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.news.updateNewsItem({ + id: 1, + body: { + title: "title", + sender_id: 1, + }, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("updateNewsItem (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { title: "title", sender_id: 1 }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/news/news_items/1") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.news.updateNewsItem({ + id: 1, + body: { + title: "title", + sender_id: 1, + }, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("deleteNewsItem (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { id: "40", object: "news-item", deleted: true }; + server + .mockEndpoint() + .delete("/news/news_items/1") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.news.deleteNewsItem({ + id: 1, + }); + expect(response).toEqual({ + id: "40", + object: "news-item", + deleted: true, + }); + }); + + test("deleteNewsItem (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/news/news_items/1") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.news.deleteNewsItem({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("deleteNewsItem (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/news/news_items/1") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.news.deleteNewsItem({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("listLiveNewsfeedItems (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 20, + total_pages: 0, + }, + total_count: 0, + data: [ + { + type: "news-item", + id: "141", + workspace_id: "t74hdn32", + title: "New feature: News Items", + body: "We are excited to announce the launch of News Items, a new content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers.", + sender_id: 123, + state: "draft", + newsfeed_assignments: [{ newsfeed_id: 198313, published_at: 1674917488 }], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["👍"], + deliver_silently: true, + created_at: 1610589632, + updated_at: 1610589632, + }, + ], + }; + server + .mockEndpoint() + .get("/news/newsfeeds/123/items") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.news.listLiveNewsfeedItems({ + id: "123", + }); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 20, + total_pages: 0, + }, + total_count: 0, + data: [ + { + type: "news-item", + id: "141", + workspace_id: "t74hdn32", + title: "New feature: News Items", + body: "We are excited to announce the launch of News Items, a new content type in Intercom enabling you to announce product updates, company news, promotions, events and more with your customers.", + sender_id: 123, + state: "draft", + newsfeed_assignments: [ + { + newsfeed_id: 198313, + published_at: 1674917488, + }, + ], + labels: ["Product Update"], + cover_image_url: "https://example.com/cover.jpg", + reactions: ["\uD83D\uDC4D"], + deliver_silently: true, + created_at: 1610589632, + updated_at: 1610589632, + }, + ], + }); + }); + + test("listLiveNewsfeedItems (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/news/newsfeeds/id/items") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.news.listLiveNewsfeedItems({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("listNewsfeeds (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 10, + total_pages: 1, + }, + total_count: 2, + data: [ + { type: "newsfeed", id: "12312", name: "My Newsfeed", created_at: 1674917488, updated_at: 1674917488 }, + { type: "newsfeed", id: "12312", name: "My Newsfeed", created_at: 1674917488, updated_at: 1674917488 }, + ], + }; + server.mockEndpoint().get("/news/newsfeeds").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.news.listNewsfeeds(); + expect(response).toEqual({ + type: "list", + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 10, + total_pages: 1, + }, + total_count: 2, + data: [ + { + id: "12312", + type: "newsfeed", + name: "My Newsfeed", + created_at: 1674917488, + updated_at: 1674917488, + }, + { + id: "12312", + type: "newsfeed", + name: "My Newsfeed", + created_at: 1674917488, + updated_at: 1674917488, + }, + ], + }); + }); + + test("listNewsfeeds (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/news/newsfeeds").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.news.listNewsfeeds(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveNewsfeed (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + id: "72", + type: "newsfeed", + name: "Visitor Feed", + created_at: 1734537815, + updated_at: 1734537815, + }; + server + .mockEndpoint() + .get("/news/newsfeeds/123") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.news.retrieveNewsfeed({ + id: "123", + }); + expect(response).toEqual({ + id: "72", + type: "newsfeed", + name: "Visitor Feed", + created_at: 1734537815, + updated_at: 1734537815, + }); + }); + + test("retrieveNewsfeed (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/news/newsfeeds/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.news.retrieveNewsfeed({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); +}); diff --git a/tests/wire/unstable/notes.test.ts b/tests/wire/unstable/notes.test.ts new file mode 100644 index 00000000..64bff186 --- /dev/null +++ b/tests/wire/unstable/notes.test.ts @@ -0,0 +1,763 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("NotesClient", () => { + test("listCompanyNotes (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "note", + id: "26", + created_at: 1733932587, + contact: { id: "214656d0c743eafcfde7f248" }, + author: { + type: "admin", + id: "991267581", + name: "Ciaran122 Lee", + email: "admin122@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }, + body: "

This is a note.

", + }, + { + type: "note", + id: "25", + created_at: 1733846187, + contact: { id: "214656d0c743eafcfde7f248" }, + author: { + type: "admin", + id: "991267581", + name: "Ciaran122 Lee", + email: "admin122@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + }, + body: "

This is a note.

", + }, + { + type: "note", + id: "24", + created_at: 1733846187, + contact: { id: "214656d0c743eafcfde7f248" }, + author: { + type: "admin", + id: "991267581", + name: "Ciaran122 Lee", + email: "admin122@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }, + body: "

This is a note.

", + }, + ], + total_count: 3, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 50, + total_pages: 1, + }, + }; + server + .mockEndpoint() + .get("/companies/5f4d3c1c-7b1b-4d7d-a97e-6095715c6632/notes") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.notes.listCompanyNotes({ + id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "note", + id: "26", + created_at: 1733932587, + contact: { + id: "214656d0c743eafcfde7f248", + }, + author: { + type: "admin", + id: "991267581", + name: "Ciaran122 Lee", + email: "admin122@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }, + body: "

This is a note.

", + }, + { + type: "note", + id: "25", + created_at: 1733846187, + contact: { + id: "214656d0c743eafcfde7f248", + }, + author: { + type: "admin", + id: "991267581", + name: "Ciaran122 Lee", + email: "admin122@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + }, + body: "

This is a note.

", + }, + { + type: "note", + id: "24", + created_at: 1733846187, + contact: { + id: "214656d0c743eafcfde7f248", + }, + author: { + type: "admin", + id: "991267581", + name: "Ciaran122 Lee", + email: "admin122@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }, + body: "

This is a note.

", + }, + ], + total_count: 3, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 50, + total_pages: 1, + }, + }); + }); + + test("listCompanyNotes (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/companies/id/notes") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.notes.listCompanyNotes({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("listNotes (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "note", + id: "26", + created_at: 1733932587, + contact: { type: "contact", id: "6762f0ab1bb69f9f2193bb60" }, + author: { + type: "admin", + id: "991267581", + name: "Ciaran122 Lee", + email: "admin122@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + }, + body: "

This is a note.

", + }, + { + type: "note", + id: "25", + created_at: 1733846187, + contact: { type: "contact", id: "6762f0ab1bb69f9f2193bb60" }, + author: { + type: "admin", + id: "991267581", + name: "Ciaran122 Lee", + email: "admin122@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + }, + body: "

This is a note.

", + }, + { + type: "note", + id: "24", + created_at: 1733846187, + contact: { type: "contact", id: "6762f0ab1bb69f9f2193bb60" }, + author: { + type: "admin", + id: "991267581", + name: "Ciaran122 Lee", + email: "admin122@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + }, + body: "

This is a note.

", + }, + ], + total_count: 3, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 50, + total_pages: 1, + }, + }; + server.mockEndpoint().get("/contacts/1/notes").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.notes.listNotes({ + id: 1, + }); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "note", + id: "26", + created_at: 1733932587, + contact: { + type: "contact", + id: "6762f0ab1bb69f9f2193bb60", + }, + author: { + type: "admin", + id: "991267581", + name: "Ciaran122 Lee", + email: "admin122@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + }, + body: "

This is a note.

", + }, + { + type: "note", + id: "25", + created_at: 1733846187, + contact: { + type: "contact", + id: "6762f0ab1bb69f9f2193bb60", + }, + author: { + type: "admin", + id: "991267581", + name: "Ciaran122 Lee", + email: "admin122@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + }, + body: "

This is a note.

", + }, + { + type: "note", + id: "24", + created_at: 1733846187, + contact: { + type: "contact", + id: "6762f0ab1bb69f9f2193bb60", + }, + author: { + type: "admin", + id: "991267581", + name: "Ciaran122 Lee", + email: "admin122@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + }, + body: "

This is a note.

", + }, + ], + total_count: 3, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 50, + total_pages: 1, + }, + }); + }); + + test("listNotes (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/contacts/1/notes").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.notes.listNotes({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("createNote (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { body: "Hello", contact_id: "6762f0ad1bb69f9f2193bb62", admin_id: "123" }; + const rawResponseBody = { + type: "note", + id: "31", + created_at: 1734537390, + contact: { type: "contact", id: "6762f0ad1bb69f9f2193bb62" }, + author: { + type: "admin", + id: "991267583", + name: "Ciaran124 Lee", + email: "admin124@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }, + body: "

Hello

", + }; + server + .mockEndpoint() + .post("/contacts/1/notes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.notes.createNote({ + id: 1, + body: "Hello", + contact_id: "6762f0ad1bb69f9f2193bb62", + admin_id: "123", + }); + expect(response).toEqual({ + type: "note", + id: "31", + created_at: 1734537390, + contact: { + type: "contact", + id: "6762f0ad1bb69f9f2193bb62", + }, + author: { + type: "admin", + id: "991267583", + name: "Ciaran124 Lee", + email: "admin124@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }, + body: "

Hello

", + }); + }); + + test("createNote (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { body: "Hello", contact_id: "6762f0af1bb69f9f2193bb63", admin_id: "123" }; + const rawResponseBody = { + type: "note", + id: "31", + created_at: 1734537390, + contact: { type: "contact", id: "6762f0ad1bb69f9f2193bb62" }, + author: { + type: "admin", + id: "991267583", + name: "Ciaran124 Lee", + email: "admin124@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }, + body: "

Hello

", + }; + server + .mockEndpoint() + .post("/contacts/1/notes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.notes.createNote({ + id: 1, + body: "Hello", + contact_id: "6762f0af1bb69f9f2193bb63", + admin_id: "123", + }); + expect(response).toEqual({ + type: "note", + id: "31", + created_at: 1734537390, + contact: { + type: "contact", + id: "6762f0ad1bb69f9f2193bb62", + }, + author: { + type: "admin", + id: "991267583", + name: "Ciaran124 Lee", + email: "admin124@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }, + body: "

Hello

", + }); + }); + + test("createNote (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { body: "Hello", contact_id: "123", admin_id: "123" }; + const rawResponseBody = { + type: "note", + id: "31", + created_at: 1734537390, + contact: { type: "contact", id: "6762f0ad1bb69f9f2193bb62" }, + author: { + type: "admin", + id: "991267583", + name: "Ciaran124 Lee", + email: "admin124@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }, + body: "

Hello

", + }; + server + .mockEndpoint() + .post("/contacts/1/notes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.notes.createNote({ + id: 1, + body: "Hello", + contact_id: "123", + admin_id: "123", + }); + expect(response).toEqual({ + type: "note", + id: "31", + created_at: 1734537390, + contact: { + type: "contact", + id: "6762f0ad1bb69f9f2193bb62", + }, + author: { + type: "admin", + id: "991267583", + name: "Ciaran124 Lee", + email: "admin124@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }, + body: "

Hello

", + }); + }); + + test("createNote (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { body: "body" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/contacts/1/notes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.notes.createNote({ + id: 1, + body: "body", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("retrieveNote (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "note", + id: "34", + created_at: 1733846617, + contact: { type: "contact", id: "6762f2591bb69f9f2193bc1f" }, + author: { + type: "admin", + id: "991267864", + name: "Ciaran346 Lee", + email: "admin346@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { primary_team_ids: [814865], secondary_team_ids: [493881] }, + }, + body: "

This is a note.

", + }; + server.mockEndpoint().get("/notes/1").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.notes.retrieveNote({ + id: 1, + }); + expect(response).toEqual({ + type: "note", + id: "34", + created_at: 1733846617, + contact: { + type: "contact", + id: "6762f2591bb69f9f2193bc1f", + }, + author: { + type: "admin", + id: "991267864", + name: "Ciaran346 Lee", + email: "admin346@email.com", + job_title: "Associate", + away_mode_enabled: false, + away_mode_reassign: false, + away_status_reason_id: 12345, + has_inbox_seat: true, + team_ids: [814865], + avatar: "https://picsum.photos/200/300", + team_priority_level: { + primary_team_ids: [814865], + secondary_team_ids: [493881], + }, + }, + body: "

This is a note.

", + }); + }); + + test("retrieveNote (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/notes/1").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.notes.retrieveNote({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveNote (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/notes/1").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.notes.retrieveNote({ + id: 1, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); +}); diff --git a/tests/wire/unstable/segments.test.ts b/tests/wire/unstable/segments.test.ts new file mode 100644 index 00000000..71d84bae --- /dev/null +++ b/tests/wire/unstable/segments.test.ts @@ -0,0 +1,162 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("SegmentsClient", () => { + test("listSegments (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "segment.list", + segments: [ + { + type: "segment", + id: "6762f25c1bb69f9f2193bc22", + name: "John segment", + created_at: 1734537820, + updated_at: 1734537820, + person_type: "user", + count: 3, + }, + { + type: "segment", + id: "6762f25c1bb69f9f2193bc23", + name: "Jane segment", + created_at: 1734537820, + updated_at: 1734537820, + person_type: "user", + count: 3, + }, + ], + pages: { key: "value" }, + }; + server.mockEndpoint().get("/segments").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.segments.listSegments({ + include_count: true, + }); + expect(response).toEqual({ + type: "segment.list", + segments: [ + { + type: "segment", + id: "6762f25c1bb69f9f2193bc22", + name: "John segment", + created_at: 1734537820, + updated_at: 1734537820, + person_type: "user", + count: 3, + }, + { + type: "segment", + id: "6762f25c1bb69f9f2193bc23", + name: "Jane segment", + created_at: 1734537820, + updated_at: 1734537820, + person_type: "user", + count: 3, + }, + ], + pages: { + key: "value", + }, + }); + }); + + test("listSegments (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/segments").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.segments.listSegments(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveSegment (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "segment", + id: "6762f25f1bb69f9f2193bc26", + name: "John segment", + created_at: 1734537823, + updated_at: 1734537823, + person_type: "user", + count: 3, + }; + server.mockEndpoint().get("/segments/123").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.segments.retrieveSegment({ + id: "123", + }); + expect(response).toEqual({ + type: "segment", + id: "6762f25f1bb69f9f2193bc26", + name: "John segment", + created_at: 1734537823, + updated_at: 1734537823, + person_type: "user", + count: 3, + }); + }); + + test("retrieveSegment (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/segments/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.segments.retrieveSegment({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveSegment (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/segments/id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.segments.retrieveSegment({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); +}); diff --git a/tests/wire/unstable/subscriptionTypes.test.ts b/tests/wire/unstable/subscriptionTypes.test.ts new file mode 100644 index 00000000..56304a5e --- /dev/null +++ b/tests/wire/unstable/subscriptionTypes.test.ts @@ -0,0 +1,410 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("SubscriptionTypesClient", () => { + test("attachSubscriptionTypeToContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "37846", consent_type: "opt_in" }; + const rawResponseBody = { + type: "subscription", + id: "106", + state: "live", + default_translation: { name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }, + translations: [{ name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }], + consent_type: "opt_in", + content_types: ["sms_message"], + }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/subscriptions") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "37846", + consent_type: "opt_in", + }); + expect(response).toEqual({ + type: "subscription", + id: "106", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [ + { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + ], + consent_type: "opt_in", + content_types: ["sms_message"], + }); + }); + + test("attachSubscriptionTypeToContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "37846", consent_type: "opt_in" }; + const rawResponseBody = { + type: "subscription", + id: "106", + state: "live", + default_translation: { name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }, + translations: [{ name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }], + consent_type: "opt_in", + content_types: ["sms_message"], + }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/subscriptions") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "37846", + consent_type: "opt_in", + }); + expect(response).toEqual({ + type: "subscription", + id: "106", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [ + { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + ], + consent_type: "opt_in", + content_types: ["sms_message"], + }); + }); + + test("attachSubscriptionTypeToContact (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "invalid_id", consent_type: "opt_in" }; + const rawResponseBody = { + type: "subscription", + id: "106", + state: "live", + default_translation: { name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }, + translations: [{ name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }], + consent_type: "opt_in", + content_types: ["sms_message"], + }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/subscriptions") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "invalid_id", + consent_type: "opt_in", + }); + expect(response).toEqual({ + type: "subscription", + id: "106", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [ + { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + ], + consent_type: "opt_in", + content_types: ["sms_message"], + }); + }); + + test("attachSubscriptionTypeToContact (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id", consent_type: "consent_type" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/contacts/contact_id/subscriptions") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({ + contact_id: "contact_id", + id: "id", + consent_type: "consent_type", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("attachSubscriptionTypeToContact (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id", consent_type: "consent_type" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/contacts/contact_id/subscriptions") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.subscriptionTypes.attachSubscriptionTypeToContact({ + contact_id: "contact_id", + id: "id", + consent_type: "consent_type", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("detachSubscriptionTypeToContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "subscription", + id: "122", + state: "live", + default_translation: { name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }, + translations: [{ name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }], + consent_type: "opt_in", + content_types: ["sms_message"], + }; + server + .mockEndpoint() + .delete("/contacts/63a07ddf05a32042dffac965/subscriptions/37846") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.subscriptionTypes.detachSubscriptionTypeToContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "37846", + }); + expect(response).toEqual({ + type: "subscription", + id: "122", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [ + { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + ], + consent_type: "opt_in", + content_types: ["sms_message"], + }); + }); + + test("detachSubscriptionTypeToContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/contacts/contact_id/subscriptions/id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.subscriptionTypes.detachSubscriptionTypeToContact({ + contact_id: "contact_id", + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("detachSubscriptionTypeToContact (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/contacts/contact_id/subscriptions/id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.subscriptionTypes.detachSubscriptionTypeToContact({ + contact_id: "contact_id", + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("listSubscriptionTypes (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "subscription", + id: "135", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [{ name: "Newsletters", description: "Lorem ipsum dolor sit amet", locale: "en" }], + consent_type: "opt_out", + content_types: ["email"], + }, + ], + }; + server + .mockEndpoint() + .get("/subscription_types") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.subscriptionTypes.listSubscriptionTypes(); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "subscription", + id: "135", + state: "live", + default_translation: { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + translations: [ + { + name: "Newsletters", + description: "Lorem ipsum dolor sit amet", + locale: "en", + }, + ], + consent_type: "opt_out", + content_types: ["email"], + }, + ], + }); + }); + + test("listSubscriptionTypes (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/subscription_types") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.subscriptionTypes.listSubscriptionTypes(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); +}); diff --git a/tests/wire/unstable/switch.test.ts b/tests/wire/unstable/switch.test.ts new file mode 100644 index 00000000..d7ee5321 --- /dev/null +++ b/tests/wire/unstable/switch.test.ts @@ -0,0 +1,113 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("SwitchClient", () => { + test("createPhoneSwitch (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { type: "phone_call_redirect", phone: "phone" }; + server + .mockEndpoint() + .post("/phone_call_redirects") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.switch.createPhoneSwitch({ + key: "value", + }); + expect(response).toEqual({ + type: "phone_call_redirect", + phone: "phone", + }); + }); + + test("createPhoneSwitch (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/phone_call_redirects") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.switch.createPhoneSwitch({ + key: "value", + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("createPhoneSwitch (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/phone_call_redirects") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.switch.createPhoneSwitch({ + key: "value", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createPhoneSwitch (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/phone_call_redirects") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.switch.createPhoneSwitch({ + key: "value", + }); + }).rejects.toThrow(Intercom.unstable.UnprocessableEntityError); + }); +}); diff --git a/tests/wire/unstable/tags.test.ts b/tests/wire/unstable/tags.test.ts new file mode 100644 index 00000000..e7094ebe --- /dev/null +++ b/tests/wire/unstable/tags.test.ts @@ -0,0 +1,1371 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("TagsClient", () => { + test("attachTagToContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "7522907" }; + const rawResponseBody = { + type: "tag", + id: "81", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.attachTagToContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "7522907", + }); + expect(response).toEqual({ + type: "tag", + id: "81", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("attachTagToContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "7522907" }; + const rawResponseBody = { + type: "tag", + id: "81", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.attachTagToContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "7522907", + }); + expect(response).toEqual({ + type: "tag", + id: "81", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("attachTagToContact (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "123" }; + const rawResponseBody = { + type: "tag", + id: "81", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/contacts/63a07ddf05a32042dffac965/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.attachTagToContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "81", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("attachTagToContact (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/contacts/contact_id/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.attachTagToContact({ + contact_id: "contact_id", + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("attachTagToContact (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/contacts/contact_id/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.attachTagToContact({ + contact_id: "contact_id", + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("detachTagFromContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "tag", + id: "84", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .delete("/contacts/63a07ddf05a32042dffac965/tags/7522907") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.detachTagFromContact({ + contact_id: "63a07ddf05a32042dffac965", + id: "7522907", + }); + expect(response).toEqual({ + type: "tag", + id: "84", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("detachTagFromContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/contacts/contact_id/tags/id") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.detachTagFromContact({ + contact_id: "contact_id", + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("detachTagFromContact (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/contacts/contact_id/tags/id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.detachTagFromContact({ + contact_id: "contact_id", + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("attachTagToConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "7522907", admin_id: "780" }; + const rawResponseBody = { + type: "tag", + id: "86", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/conversations/64619700005694/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.attachTagToConversation({ + conversation_id: "64619700005694", + id: "7522907", + admin_id: "780", + }); + expect(response).toEqual({ + type: "tag", + id: "86", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("attachTagToConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "7522907", admin_id: "780" }; + const rawResponseBody = { + type: "tag", + id: "86", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/conversations/64619700005694/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.attachTagToConversation({ + conversation_id: "64619700005694", + id: "7522907", + admin_id: "780", + }); + expect(response).toEqual({ + type: "tag", + id: "86", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("attachTagToConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id", admin_id: "admin_id" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/conversations/conversation_id/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.attachTagToConversation({ + conversation_id: "conversation_id", + id: "id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("attachTagToConversation (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id", admin_id: "admin_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/conversations/conversation_id/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.attachTagToConversation({ + conversation_id: "conversation_id", + id: "id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("detachTagFromConversation (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "123" }; + const rawResponseBody = { + type: "tag", + id: "89", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .delete("/conversations/64619700005694/tags/7522907") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.detachTagFromConversation({ + conversation_id: "64619700005694", + id: "7522907", + admin_id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "89", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("detachTagFromConversation (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "123" }; + const rawResponseBody = { + type: "tag", + id: "89", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .delete("/conversations/64619700005694/tags/7522907") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.detachTagFromConversation({ + conversation_id: "64619700005694", + id: "7522907", + admin_id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "89", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("detachTagFromConversation (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "123" }; + const rawResponseBody = { + type: "tag", + id: "89", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .delete("/conversations/64619700005694/tags/7522907") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.detachTagFromConversation({ + conversation_id: "64619700005694", + id: "7522907", + admin_id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "89", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("detachTagFromConversation (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/conversations/conversation_id/tags/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.detachTagFromConversation({ + conversation_id: "conversation_id", + id: "id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("detachTagFromConversation (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/conversations/conversation_id/tags/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.detachTagFromConversation({ + conversation_id: "conversation_id", + id: "id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("listTags (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "tag", + id: "102", + name: "Manual tag 1", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }, + ], + }; + server.mockEndpoint().get("/tags").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.tags.listTags(); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "tag", + id: "102", + name: "Manual tag 1", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }, + ], + }); + }); + + test("listTags (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/tags").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.tags.listTags(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createTag (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "test" }; + const rawResponseBody = { + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.createTag({ + name: "test", + }); + expect(response).toEqual({ + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("createTag (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "Independent" }; + const rawResponseBody = { + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.createTag({ + name: "Independent", + }); + expect(response).toEqual({ + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("createTag (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "test", companies: [{ company_id: "123" }] }; + const rawResponseBody = { + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.createTag({ + name: "test", + companies: [ + { + company_id: "123", + }, + ], + }); + expect(response).toEqual({ + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("createTag (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "test", users: [{ id: "123" }] }; + const rawResponseBody = { + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.createTag({ + name: "test", + users: [ + { + id: "123", + }, + ], + }); + expect(response).toEqual({ + type: "tag", + id: "105", + name: "test", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("createTag (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "name" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.createTag({ + name: "name", + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("createTag (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "name" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.createTag({ + name: "name", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createTag (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "name" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.createTag({ + name: "name", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("findTag (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "tag", + id: "113", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server.mockEndpoint().get("/tags/123").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.tags.findTag({ + id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "113", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("findTag (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/tags/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.tags.findTag({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("findTag (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/tags/id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.tags.findTag({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("deleteTag (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + server.mockEndpoint().delete("/tags/123").respondWith().statusCode(200).build(); + + const response = await client.unstable.tags.deleteTag({ + id: "123", + }); + expect(response).toEqual(undefined); + }); + + test("deleteTag (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().delete("/tags/id").respondWith().statusCode(400).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.tags.deleteTag({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("deleteTag (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().delete("/tags/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.tags.deleteTag({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("deleteTag (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().delete("/tags/id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.tags.deleteTag({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("attachTagToTicket (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "7522907", admin_id: "780" }; + const rawResponseBody = { + type: "tag", + id: "121", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/tickets/64619700005694/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.attachTagToTicket({ + ticket_id: "64619700005694", + id: "7522907", + admin_id: "780", + }); + expect(response).toEqual({ + type: "tag", + id: "121", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("attachTagToTicket (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "7522907", admin_id: "780" }; + const rawResponseBody = { + type: "tag", + id: "121", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .post("/tickets/64619700005694/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.attachTagToTicket({ + ticket_id: "64619700005694", + id: "7522907", + admin_id: "780", + }); + expect(response).toEqual({ + type: "tag", + id: "121", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("attachTagToTicket (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id", admin_id: "admin_id" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/tickets/ticket_id/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.attachTagToTicket({ + ticket_id: "ticket_id", + id: "id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("attachTagToTicket (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id", admin_id: "admin_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/tickets/ticket_id/tags") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.attachTagToTicket({ + ticket_id: "ticket_id", + id: "id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("detachTagFromTicket (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "123" }; + const rawResponseBody = { + type: "tag", + id: "124", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .delete("/tickets/64619700005694/tags/7522907") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.detachTagFromTicket({ + ticket_id: "64619700005694", + id: "7522907", + admin_id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "124", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("detachTagFromTicket (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "123" }; + const rawResponseBody = { + type: "tag", + id: "124", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .delete("/tickets/64619700005694/tags/7522907") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.detachTagFromTicket({ + ticket_id: "64619700005694", + id: "7522907", + admin_id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "124", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("detachTagFromTicket (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "123" }; + const rawResponseBody = { + type: "tag", + id: "124", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { type: "contact", id: "1a2b3c" }, + }; + server + .mockEndpoint() + .delete("/tickets/64619700005694/tags/7522907") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tags.detachTagFromTicket({ + ticket_id: "64619700005694", + id: "7522907", + admin_id: "123", + }); + expect(response).toEqual({ + type: "tag", + id: "124", + name: "Manual tag", + applied_at: 1663597223, + applied_by: { + type: "contact", + id: "1a2b3c", + }, + }); + }); + + test("detachTagFromTicket (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .delete("/tickets/ticket_id/tags/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.detachTagFromTicket({ + ticket_id: "ticket_id", + id: "id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("detachTagFromTicket (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { admin_id: "admin_id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .delete("/tickets/ticket_id/tags/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tags.detachTagFromTicket({ + ticket_id: "ticket_id", + id: "id", + admin_id: "admin_id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); +}); diff --git a/tests/wire/unstable/teams.test.ts b/tests/wire/unstable/teams.test.ts new file mode 100644 index 00000000..f25b2268 --- /dev/null +++ b/tests/wire/unstable/teams.test.ts @@ -0,0 +1,136 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("TeamsClient", () => { + test("listTeams (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "team.list", + teams: [ + { + type: "team", + id: "814865", + name: "Example Team", + admin_ids: [493881], + admin_priority_level: { primary_admin_ids: [493881], secondary_admin_ids: [814865] }, + }, + ], + }; + server.mockEndpoint().get("/teams").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.teams.listTeams(); + expect(response).toEqual({ + type: "team.list", + teams: [ + { + type: "team", + id: "814865", + name: "Example Team", + admin_ids: [493881], + admin_priority_level: { + primary_admin_ids: [493881], + secondary_admin_ids: [814865], + }, + }, + ], + }); + }); + + test("listTeams (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/teams").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.teams.listTeams(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveTeam (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "team", + id: "991267902", + name: "team 1", + admin_ids: [493881], + admin_priority_level: { primary_admin_ids: [493881], secondary_admin_ids: [814865] }, + }; + server.mockEndpoint().get("/teams/123").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.teams.retrieveTeam({ + id: "123", + }); + expect(response).toEqual({ + type: "team", + id: "991267902", + name: "team 1", + admin_ids: [493881], + admin_priority_level: { + primary_admin_ids: [493881], + secondary_admin_ids: [814865], + }, + }); + }); + + test("retrieveTeam (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/teams/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.teams.retrieveTeam({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveTeam (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/teams/id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.teams.retrieveTeam({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); +}); diff --git a/tests/wire/unstable/ticketStates.test.ts b/tests/wire/unstable/ticketStates.test.ts new file mode 100644 index 00000000..21e2b43c --- /dev/null +++ b/tests/wire/unstable/ticketStates.test.ts @@ -0,0 +1,504 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("TicketStatesClient", () => { + test("listTicketStates (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "ticket_state", + id: "8269", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8270", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8271", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8272", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8273", + category: "submitted", + internal_label: "Admin label 1", + external_label: "User label", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8274", + category: "submitted", + internal_label: "Admin label 2", + external_label: "User label", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + ], + }; + server.mockEndpoint().get("/ticket_states").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.ticketStates.listTicketStates(); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "ticket_state", + id: "8269", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8270", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8271", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8272", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8273", + category: "submitted", + internal_label: "Admin label 1", + external_label: "User label", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "55", + category: "Back-office", + name: "my-ticket-type-3", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + { + type: "ticket_type", + id: "56", + category: "Back-office", + name: "my-ticket-type-4", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + { + type: "ticket_state", + id: "8274", + category: "submitted", + internal_label: "Admin label 2", + external_label: "User label", + archived: false, + ticket_types: { + type: "list", + data: [ + { + type: "ticket_type", + id: "58", + category: "Back-office", + name: "my-ticket-type-6", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "ecahpwf5", + archived: false, + }, + ], + }, + }, + ], + }); + }); + + test("listTicketStates (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/ticket_states").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.ticketStates.listTicketStates(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); +}); diff --git a/tests/wire/unstable/ticketTypeAttributes.test.ts b/tests/wire/unstable/ticketTypeAttributes.test.ts new file mode 100644 index 00000000..83b633bd --- /dev/null +++ b/tests/wire/unstable/ticketTypeAttributes.test.ts @@ -0,0 +1,200 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("TicketTypeAttributesClient", () => { + test("createTicketTypeAttribute (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + name: "Attribute Title", + description: "Attribute Description", + data_type: "string", + required_to_create: false, + }; + const rawResponseBody = { + type: "ticket_type_attribute", + id: "157", + workspace_id: "this_is_an_id640_that_should_be_at_least_", + name: "Attribute Title", + description: "Attribute Description", + data_type: "string", + input_options: { multiline: false }, + order: 2, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: true, + visible_to_contacts: true, + default: false, + ticket_type_id: 63, + archived: false, + created_at: 1734537862, + updated_at: 1734537862, + }; + server + .mockEndpoint() + .post("/ticket_types/ticket_type_id/attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.ticketTypeAttributes.createTicketTypeAttribute({ + ticket_type_id: "ticket_type_id", + name: "Attribute Title", + description: "Attribute Description", + data_type: "string", + required_to_create: false, + }); + expect(response).toEqual({ + type: "ticket_type_attribute", + id: "157", + workspace_id: "this_is_an_id640_that_should_be_at_least_", + name: "Attribute Title", + description: "Attribute Description", + data_type: "string", + input_options: { + multiline: false, + }, + order: 2, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: true, + visible_to_contacts: true, + default: false, + ticket_type_id: 63, + archived: false, + created_at: 1734537862, + updated_at: 1734537862, + }); + }); + + test("createTicketTypeAttribute (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { name: "name", description: "description", data_type: "string" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/ticket_types/ticket_type_id/attributes") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.ticketTypeAttributes.createTicketTypeAttribute({ + ticket_type_id: "ticket_type_id", + name: "name", + description: "description", + data_type: "string", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("updateTicketTypeAttribute (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { description: "New Attribute Description" }; + const rawResponseBody = { + type: "ticket_type_attribute", + id: "162", + workspace_id: "this_is_an_id644_that_should_be_at_least_", + name: "name", + description: "New Attribute Description", + data_type: "string", + input_options: { key: "value" }, + order: 0, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: false, + visible_to_contacts: false, + default: false, + ticket_type_id: 65, + archived: false, + created_at: 1734537864, + updated_at: 1734537864, + }; + server + .mockEndpoint() + .put("/ticket_types/ticket_type_id/attributes/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.ticketTypeAttributes.updateTicketTypeAttribute({ + ticket_type_id: "ticket_type_id", + id: "id", + description: "New Attribute Description", + }); + expect(response).toEqual({ + type: "ticket_type_attribute", + id: "162", + workspace_id: "this_is_an_id644_that_should_be_at_least_", + name: "name", + description: "New Attribute Description", + data_type: "string", + input_options: { + key: "value", + }, + order: 0, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: false, + visible_to_contacts: false, + default: false, + ticket_type_id: 65, + archived: false, + created_at: 1734537864, + updated_at: 1734537864, + }); + }); + + test("updateTicketTypeAttribute (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/ticket_types/ticket_type_id/attributes/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.ticketTypeAttributes.updateTicketTypeAttribute({ + ticket_type_id: "ticket_type_id", + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); +}); diff --git a/tests/wire/unstable/ticketTypes.test.ts b/tests/wire/unstable/ticketTypes.test.ts new file mode 100644 index 00000000..95efe063 --- /dev/null +++ b/tests/wire/unstable/ticketTypes.test.ts @@ -0,0 +1,518 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("TicketTypesClient", () => { + test("listTicketTypes (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "list", + data: [ + { + type: "ticket_type", + id: "67", + category: "Customer", + name: "Bug Report", + description: "Bug Report Template", + icon: "🎟️", + workspace_id: "this_is_an_id648_that_should_be_at_least_", + ticket_type_attributes: { type: "list" }, + ticket_states: { + type: "list", + data: [ + { + type: "ticket_state", + id: "8321", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + { + type: "ticket_state", + id: "8322", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + { + type: "ticket_state", + id: "8323", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + }, + { + type: "ticket_state", + id: "8324", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + }, + ], + }, + archived: false, + created_at: 1734537866, + updated_at: 1734537866, + }, + ], + }; + server.mockEndpoint().get("/ticket_types").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.ticketTypes.listTicketTypes(); + expect(response).toEqual({ + type: "list", + data: [ + { + type: "ticket_type", + id: "67", + category: "Customer", + name: "Bug Report", + description: "Bug Report Template", + icon: "\uD83C\uDF9F\uFE0F", + workspace_id: "this_is_an_id648_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + }, + ticket_states: { + type: "list", + data: [ + { + type: "ticket_state", + id: "8321", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + { + type: "ticket_state", + id: "8322", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + { + type: "ticket_state", + id: "8323", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + }, + { + type: "ticket_state", + id: "8324", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + }, + ], + }, + archived: false, + created_at: 1734537866, + updated_at: 1734537866, + }, + ], + }); + }); + + test("listTicketTypes (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/ticket_types").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.ticketTypes.listTicketTypes(); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("createTicketType (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { + type: "type", + id: "id", + category: "Customer", + name: "name", + description: "description", + icon: "icon", + workspace_id: "workspace_id", + ticket_type_attributes: { + type: "type", + ticket_type_attributes: [ + { + type: "type", + id: "id", + workspace_id: "workspace_id", + name: "name", + description: "description", + data_type: "data_type", + input_options: { input_options: { key: "value" } }, + order: 1, + required_to_create: true, + required_to_create_for_contacts: true, + visible_on_create: true, + visible_to_contacts: true, + default: true, + ticket_type_id: 1, + archived: true, + created_at: 1, + updated_at: 1, + }, + { + type: "type", + id: "id", + workspace_id: "workspace_id", + name: "name", + description: "description", + data_type: "data_type", + input_options: { input_options: { key: "value" } }, + order: 1, + required_to_create: true, + required_to_create_for_contacts: true, + visible_on_create: true, + visible_to_contacts: true, + default: true, + ticket_type_id: 1, + archived: true, + created_at: 1, + updated_at: 1, + }, + ], + }, + ticket_states: { + type: "type", + data: [ + { + type: "type", + id: "id", + category: "submitted", + internal_label: "internal_label", + external_label: "external_label", + }, + { + type: "type", + id: "id", + category: "submitted", + internal_label: "internal_label", + external_label: "external_label", + }, + ], + }, + archived: true, + created_at: 1, + updated_at: 1, + }; + server + .mockEndpoint() + .post("/ticket_types") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.ticketTypes.createTicketType({ + key: "value", + }); + expect(response).toEqual({ + type: "type", + id: "id", + category: "Customer", + name: "name", + description: "description", + icon: "icon", + workspace_id: "workspace_id", + ticket_type_attributes: { + type: "type", + ticket_type_attributes: [ + { + type: "type", + id: "id", + workspace_id: "workspace_id", + name: "name", + description: "description", + data_type: "data_type", + input_options: { + input_options: { + key: "value", + }, + }, + order: 1, + required_to_create: true, + required_to_create_for_contacts: true, + visible_on_create: true, + visible_to_contacts: true, + default: true, + ticket_type_id: 1, + archived: true, + created_at: 1, + updated_at: 1, + }, + { + type: "type", + id: "id", + workspace_id: "workspace_id", + name: "name", + description: "description", + data_type: "data_type", + input_options: { + input_options: { + key: "value", + }, + }, + order: 1, + required_to_create: true, + required_to_create_for_contacts: true, + visible_on_create: true, + visible_to_contacts: true, + default: true, + ticket_type_id: 1, + archived: true, + created_at: 1, + updated_at: 1, + }, + ], + }, + ticket_states: { + type: "type", + data: [ + { + type: "type", + id: "id", + category: "submitted", + internal_label: "internal_label", + external_label: "external_label", + }, + { + type: "type", + id: "id", + category: "submitted", + internal_label: "internal_label", + external_label: "external_label", + }, + ], + }, + archived: true, + created_at: 1, + updated_at: 1, + }); + }); + + test("createTicketType (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/ticket_types") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.ticketTypes.createTicketType({ + key: "value", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("getTicketType (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "ticket_type", + id: "72", + category: "Customer", + name: "Bug Report", + description: "Bug Report Template", + icon: "🎟️", + workspace_id: "this_is_an_id656_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [ + { + type: "ticket_type_attribute", + id: "1", + workspace_id: "ecahpwf5", + name: "Title", + description: "Bug title.", + data_type: "string", + input_options: { key: "value" }, + order: 1, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: false, + visible_to_contacts: false, + default: true, + ticket_type_id: 42, + archived: false, + }, + ], + }, + ticket_states: { + type: "list", + data: [ + { + type: "ticket_state", + id: "8353", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + { + type: "ticket_state", + id: "8354", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + { + type: "ticket_state", + id: "8355", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + }, + { + type: "ticket_state", + id: "8356", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + }, + ], + }, + archived: false, + created_at: 1734537870, + updated_at: 1734537870, + }; + server.mockEndpoint().get("/ticket_types/id").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.ticketTypes.getTicketType({ + id: "id", + }); + expect(response).toEqual({ + type: "ticket_type", + id: "72", + category: "Customer", + name: "Bug Report", + description: "Bug Report Template", + icon: "\uD83C\uDF9F\uFE0F", + workspace_id: "this_is_an_id656_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [ + { + type: "ticket_type_attribute", + id: "1", + workspace_id: "ecahpwf5", + name: "Title", + description: "Bug title.", + data_type: "string", + input_options: { + key: "value", + }, + order: 1, + required_to_create: false, + required_to_create_for_contacts: false, + visible_on_create: false, + visible_to_contacts: false, + default: true, + ticket_type_id: 42, + archived: false, + }, + ], + }, + ticket_states: { + type: "list", + data: [ + { + type: "ticket_state", + id: "8353", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + { + type: "ticket_state", + id: "8354", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + { + type: "ticket_state", + id: "8355", + category: "waiting_on_customer", + internal_label: "Waiting on customer", + external_label: "Waiting on you", + }, + { + type: "ticket_state", + id: "8356", + category: "resolved", + internal_label: "Resolved", + external_label: "Resolved", + }, + ], + }, + archived: false, + created_at: 1734537870, + updated_at: 1734537870, + }); + }); + + test("getTicketType (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/ticket_types/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.ticketTypes.getTicketType({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); +}); diff --git a/tests/wire/unstable/tickets.test.ts b/tests/wire/unstable/tickets.test.ts new file mode 100644 index 00000000..d1c30b68 --- /dev/null +++ b/tests/wire/unstable/tickets.test.ts @@ -0,0 +1,3265 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("TicketsClient", () => { + test("replyTicket (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2971bb69f9f2193bc49", + }; + const rawResponseBody = { + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { type: "admin", id: "991267943", name: "Ciaran419 Lee", email: "admin419@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }; + server + .mockEndpoint() + .post("/tickets/123/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tickets.replyTicket({ + id: "123", + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2971bb69f9f2193bc49", + }, + }); + expect(response).toEqual({ + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { + type: "admin", + id: "991267943", + name: "Ciaran419 Lee", + email: "admin419@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }); + }); + + test("replyTicket (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "note", + type: "admin", + body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + admin_id: "3156780", + }; + const rawResponseBody = { + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { type: "admin", id: "991267943", name: "Ciaran419 Lee", email: "admin419@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }; + server + .mockEndpoint() + .post("/tickets/123/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tickets.replyTicket({ + id: "123", + body: { + message_type: "note", + type: "admin", + body: "

An Unordered HTML List

  • Coffee
  • Tea
  • Milk

An Ordered HTML List

  1. Coffee
  2. Tea
  3. Milk
", + admin_id: "3156780", + }, + }); + expect(response).toEqual({ + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { + type: "admin", + id: "991267943", + name: "Ciaran419 Lee", + email: "admin419@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }); + }); + + test("replyTicket (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "quick_reply", + type: "admin", + admin_id: "3156780", + reply_options: [ + { text: "Yes", uuid: "0df48b85-9a93-4c66-a167-753eff0baaec" }, + { text: "No", uuid: "4f0b5145-4193-4b4f-8cad-ce19478a3938" }, + ], + }; + const rawResponseBody = { + type: "ticket_part", + id: "158", + part_type: "quick_reply", + body: "

Okay!

", + created_at: 1734537890, + updated_at: 1734537890, + author: { type: "admin", id: "991267948", name: "Ciaran423 Lee", email: "admin423@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }; + server + .mockEndpoint() + .post("/tickets/123/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tickets.replyTicket({ + id: "123", + body: { + message_type: "quick_reply", + type: "admin", + admin_id: "3156780", + reply_options: [ + { + text: "Yes", + uuid: "0df48b85-9a93-4c66-a167-753eff0baaec", + }, + { + text: "No", + uuid: "4f0b5145-4193-4b4f-8cad-ce19478a3938", + }, + ], + }, + }); + expect(response).toEqual({ + type: "ticket_part", + id: "158", + part_type: "quick_reply", + body: "

Okay!

", + created_at: 1734537890, + updated_at: 1734537890, + author: { + type: "admin", + id: "991267948", + name: "Ciaran423 Lee", + email: "admin423@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }); + }); + + test("replyTicket (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2a41bb69f9f2193bc4c", + }; + const rawResponseBody = { + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { type: "admin", id: "991267943", name: "Ciaran419 Lee", email: "admin419@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }; + server + .mockEndpoint() + .post("/tickets/123/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tickets.replyTicket({ + id: "123", + body: { + message_type: "comment", + type: "user", + body: "Thanks again :)", + intercom_user_id: "6762f2a41bb69f9f2193bc4c", + }, + }); + expect(response).toEqual({ + type: "ticket_part", + id: "156", + part_type: "note", + body: "

An Unordered HTML List

\n
    \n
  • Coffee
  • \n
  • Tea
  • \n
  • Milk
  • \n
\n

An Ordered HTML List

\n
    \n
  1. Coffee
  2. \n
  3. Tea
  4. \n
  5. Milk
  6. \n
", + created_at: 1734537884, + updated_at: 1734537884, + author: { + type: "admin", + id: "991267943", + name: "Ciaran419 Lee", + email: "admin419@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + redacted: false, + }); + }); + + test("replyTicket (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/tickets/id/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tickets.replyTicket({ + id: "id", + body: { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }, + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("replyTicket (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/tickets/id/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tickets.replyTicket({ + id: "id", + body: { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("replyTicket (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/tickets/id/reply") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tickets.replyTicket({ + id: "id", + body: { + intercom_user_id: "intercom_user_id", + message_type: "comment", + type: "user", + body: "body", + }, + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("enqueueCreateTicket (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_type_id: "1234", contacts: [{ id: "6762f2d81bb69f9f2193bc54" }] }; + const rawResponseBody = { + type: "job", + id: "20", + url: "https://api.intercom.io/jobs/status/20", + status: "pending", + resource_type: "ticket", + resource_id: "resource_id", + resource_url: "http://api.intercom.io/tickets/123", + }; + server + .mockEndpoint() + .post("/tickets/enqueue") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tickets.enqueueCreateTicket({ + ticket_type_id: "1234", + contacts: [ + { + id: "6762f2d81bb69f9f2193bc54", + }, + ], + }); + expect(response).toEqual({ + type: "job", + id: "20", + url: "https://api.intercom.io/jobs/status/20", + status: "pending", + resource_type: "ticket", + resource_id: "resource_id", + resource_url: "http://api.intercom.io/tickets/123", + }); + }); + + test("enqueueCreateTicket (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_type_id: "ticket_type_id", contacts: [{ id: "id" }, { id: "id" }] }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .post("/tickets/enqueue") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tickets.enqueueCreateTicket({ + ticket_type_id: "ticket_type_id", + contacts: [ + { + id: "id", + }, + { + id: "id", + }, + ], + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("enqueueCreateTicket (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_type_id: "ticket_type_id", contacts: [{ id: "id" }, { id: "id" }] }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/tickets/enqueue") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tickets.enqueueCreateTicket({ + ticket_type_id: "ticket_type_id", + contacts: [ + { + id: "id", + }, + { + id: "id", + }, + ], + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("getTicket (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "ticket", + id: "631", + ticket_id: "38", + category: "Back-office", + ticket_attributes: { _default_title_: "attribute_value", _default_description_: "ticket_attributes" }, + ticket_state: { + type: "ticket_state", + id: "8537", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "95", + category: "Back-office", + name: "my-ticket-type-30", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id702_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537973, + updated_at: 1734537973, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2f61bb69f9f2193bc59", + external_id: "b16afa36-2637-4880-adee-a46d145bc27f", + }, + ], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537974, + updated_at: 1734537976, + open: true, + snoozed_until: 1663597260, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "185", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537975, + updated_at: 1734537975, + author: { type: "admin", id: "991268047", name: "Ciaran509 Lee", email: "admin509@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + is_shared: false, + }; + server.mockEndpoint().get("/tickets/id").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.tickets.getTicket({ + id: "id", + }); + expect(response).toEqual({ + type: "ticket", + id: "631", + ticket_id: "38", + category: "Back-office", + ticket_attributes: { + _default_title_: "attribute_value", + _default_description_: "ticket_attributes", + }, + ticket_state: { + type: "ticket_state", + id: "8537", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "95", + category: "Back-office", + name: "my-ticket-type-30", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id702_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537973, + updated_at: 1734537973, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2f61bb69f9f2193bc59", + external_id: "b16afa36-2637-4880-adee-a46d145bc27f", + }, + ], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537974, + updated_at: 1734537976, + open: true, + snoozed_until: 1663597260, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "185", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537975, + updated_at: 1734537975, + author: { + type: "admin", + id: "991268047", + name: "Ciaran509 Lee", + email: "admin509@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + ], + total_count: 1, + }, + is_shared: false, + }); + }); + + test("getTicket (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/tickets/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.tickets.getTicket({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("updateTicket (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state_id: "123", + open: true, + snoozed_until: 1673609604, + admin_id: 991268011, + assignee_id: "123", + }; + const rawResponseBody = { + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "10", label: "Photo" }, + value: { type: "value", id: [2], label: ["photo.png"] }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "7", label: "Progress" }, + value: { type: "value", id: "Fast", label: "Fast" }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { type: "admin", id: "991268013" }, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }; + server + .mockEndpoint() + .put("/tickets/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tickets.updateTicket({ + id: "id", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state_id: "123", + open: true, + snoozed_until: 1673609604, + admin_id: 991268011, + assignee_id: "123", + }); + expect(response).toEqual({ + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "10", + label: "Photo", + }, + value: { + type: "value", + id: [2], + label: ["photo.png"], + }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "7", + label: "Progress", + }, + value: { + type: "value", + id: "Fast", + label: "Fast", + }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { + type: "admin", + id: "991268013", + }, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }); + }); + + test("updateTicket (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state_id: "123", + admin_id: 991268011, + assignee_id: "123", + }; + const rawResponseBody = { + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "10", label: "Photo" }, + value: { type: "value", id: [2], label: ["photo.png"] }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "7", label: "Progress" }, + value: { type: "value", id: "Fast", label: "Fast" }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { type: "admin", id: "991268013" }, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }; + server + .mockEndpoint() + .put("/tickets/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tickets.updateTicket({ + id: "id", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state_id: "123", + admin_id: 991268011, + assignee_id: "123", + }); + expect(response).toEqual({ + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "10", + label: "Photo", + }, + value: { + type: "value", + id: [2], + label: ["photo.png"], + }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "7", + label: "Progress", + }, + value: { + type: "value", + id: "Fast", + label: "Fast", + }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { + type: "admin", + id: "991268013", + }, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }); + }); + + test("updateTicket (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state_id: "123", + admin_id: 991268011, + assignee_id: "123", + }; + const rawResponseBody = { + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "10", label: "Photo" }, + value: { type: "value", id: [2], label: ["photo.png"] }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "7", label: "Progress" }, + value: { type: "value", id: "Fast", label: "Fast" }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { type: "admin", id: "991268013" }, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }; + server + .mockEndpoint() + .put("/tickets/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tickets.updateTicket({ + id: "id", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state_id: "123", + admin_id: 991268011, + assignee_id: "123", + }); + expect(response).toEqual({ + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "10", + label: "Photo", + }, + value: { + type: "value", + id: [2], + label: ["photo.png"], + }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "7", + label: "Progress", + }, + value: { + type: "value", + id: "Fast", + label: "Fast", + }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { + type: "admin", + id: "991268013", + }, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }); + }); + + test("updateTicket (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { ticket_state_id: "123" }; + const rawResponseBody = { + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { _default_title_: "example", _default_description_: "there is a problem" }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { type: "list", ticket_type_attributes: [] }, + ticket_states: { type: "list", data: [] }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "10", label: "Photo" }, + value: { type: "value", id: [2], label: ["photo.png"] }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { type: "attribute", id: "7", label: "Progress" }, + value: { type: "value", id: "Fast", label: "Fast" }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { type: "admin", id: "991268013" }, + author: { type: "admin", id: "991268011", name: "Ciaran477 Lee", email: "admin477@email.com" }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }; + server + .mockEndpoint() + .put("/tickets/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tickets.updateTicket({ + id: "id", + ticket_state_id: "123", + }); + expect(response).toEqual({ + type: "ticket", + id: "627", + ticket_id: "34", + category: "Back-office", + ticket_attributes: { + _default_title_: "example", + _default_description_: "there is a problem", + }, + ticket_state: { + type: "ticket_state", + id: "8498", + category: "in_progress", + internal_label: "In progress", + external_label: "In progress", + }, + ticket_type: { + type: "ticket_type", + id: "90", + category: "Back-office", + name: "my-ticket-type-25", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id692_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + ticket_type_attributes: [], + }, + ticket_states: { + type: "list", + data: [], + }, + archived: false, + created_at: 1734537948, + updated_at: 1734537948, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f2dd1bb69f9f2193bc55", + external_id: "8df1fa21-b41d-4621-9229-d6f7a3a590ce", + }, + ], + }, + admin_assignee_id: "991268013", + team_assignee_id: "0", + created_at: 1734537950, + updated_at: 1734537955, + open: true, + snoozed_until: 1734627600, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "176", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537951, + updated_at: 1734537951, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "177", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "10", + label: "Photo", + }, + value: { + type: "value", + id: [2], + label: ["photo.png"], + }, + }, + }, + { + type: "ticket_part", + id: "178", + part_type: "ticket_attribute_updated_by_admin", + body: "

Okay!

", + created_at: 1734537953, + updated_at: 1734537953, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + updated_attribute_data: { + attribute: { + type: "attribute", + id: "7", + label: "Progress", + }, + value: { + type: "value", + id: "Fast", + label: "Fast", + }, + }, + }, + { + type: "ticket_part", + id: "179", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "in_progress", + created_at: 1734537954, + updated_at: 1734537954, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "test-integration", + }, + { + type: "ticket_part", + id: "180", + part_type: "assignment", + body: "

Okay!

", + created_at: 1734537954, + updated_at: 1734537954, + assigned_to: { + type: "admin", + id: "991268013", + }, + author: { + type: "admin", + id: "991268011", + name: "Ciaran477 Lee", + email: "admin477@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + { + type: "ticket_part", + id: "181", + part_type: "snoozed", + body: "

Okay!

", + created_at: 1734537955, + updated_at: 1734537955, + author: { + type: "bot", + id: "991268012", + name: "Fin", + email: "operator+this_is_an_id692_that_should_be_at_least_@intercom.io", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 6, + }, + is_shared: false, + }); + }); + + test("updateTicket (5)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/tickets/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(400) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tickets.updateTicket({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.BadRequestError); + }); + + test("updateTicket (6)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/tickets/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tickets.updateTicket({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("updateTicket (7)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/tickets/id") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.tickets.updateTicket({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("deleteTicket (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { id: "632", object: "ticket", deleted: true }; + server.mockEndpoint().delete("/tickets/id").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.tickets.deleteTicket({ + id: "id", + }); + expect(response).toEqual({ + id: "632", + object: "ticket", + deleted: true, + }); + }); + + test("deleteTicket (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().delete("/tickets/id").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.tickets.deleteTicket({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("deleteTicket (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().delete("/tickets/id").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.tickets.deleteTicket({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("searchTickets", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + query: { operator: "AND", value: [{ field: "created_at", operator: ">", value: "1306054154" }] }, + pagination: { per_page: 5 }, + }; + const rawResponseBody = { + type: "ticket.list", + tickets: [ + { + type: "ticket", + id: "633", + ticket_id: "40", + category: "Back-office", + ticket_attributes: { _default_title_: "attribute_value", _default_description_: undefined }, + ticket_state: { + type: "ticket_state", + id: "8577", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "100", + category: "Back-office", + name: "my-ticket-type-35", + description: "my ticket type description is awesome.", + icon: "🦁", + workspace_id: "this_is_an_id712_that_should_be_at_least_", + ticket_type_attributes: { type: "list" }, + archived: false, + created_at: 1734537989, + updated_at: 1734537989, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f3061bb69f9f2193bc5b", + external_id: "9b913927-c084-4391-b1db-098341b5ffe3", + }, + ], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537990, + updated_at: 1734537992, + open: true, + snoozed_until: 1663597260, + linked_objects: { type: "list", total_count: 0, has_more: false, data: [{ id: "7583" }] }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "188", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537991, + updated_at: 1734537991, + author: { + type: "admin", + id: "991268079", + name: "Ciaran539 Lee", + email: "admin539@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 1, + }, + is_shared: false, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: { per_page: 2, starting_after: "your-cursor-from-response" }, + per_page: 5, + total_pages: 1, + }, + }; + server + .mockEndpoint() + .post("/tickets/search") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.tickets.searchTickets({ + query: { + operator: "AND", + value: [ + { + field: "created_at", + operator: ">", + value: "1306054154", + }, + ], + }, + pagination: { + per_page: 5, + }, + }); + expect(response).toEqual({ + type: "ticket.list", + tickets: [ + { + type: "ticket", + id: "633", + ticket_id: "40", + category: "Back-office", + ticket_attributes: { + _default_title_: "attribute_value", + }, + ticket_state: { + type: "ticket_state", + id: "8577", + category: "submitted", + internal_label: "Submitted", + external_label: "Submitted", + }, + ticket_type: { + type: "ticket_type", + id: "100", + category: "Back-office", + name: "my-ticket-type-35", + description: "my ticket type description is awesome.", + icon: "\uD83E\uDD81", + workspace_id: "this_is_an_id712_that_should_be_at_least_", + ticket_type_attributes: { + type: "list", + }, + archived: false, + created_at: 1734537989, + updated_at: 1734537989, + }, + contacts: { + type: "contact.list", + contacts: [ + { + type: "contact", + id: "6762f3061bb69f9f2193bc5b", + external_id: "9b913927-c084-4391-b1db-098341b5ffe3", + }, + ], + }, + admin_assignee_id: "0", + team_assignee_id: "0", + created_at: 1734537990, + updated_at: 1734537992, + open: true, + snoozed_until: 1663597260, + linked_objects: { + type: "list", + total_count: 0, + has_more: false, + data: [ + { + id: "7583", + }, + ], + }, + ticket_parts: { + type: "ticket_part.list", + ticket_parts: [ + { + type: "ticket_part", + id: "188", + part_type: "ticket_state_updated_by_admin", + body: "

Okay!

", + previous_ticket_state: "submitted", + ticket_state: "submitted", + created_at: 1734537991, + updated_at: 1734537991, + author: { + type: "admin", + id: "991268079", + name: "Ciaran539 Lee", + email: "admin539@email.com", + }, + attachments: [ + { + type: "upload", + name: "example.png", + url: "https://picsum.photos/200/300", + content_type: "image/png", + filesize: 100, + width: 100, + height: 100, + }, + ], + external_id: "abcd1234", + redacted: false, + app_package_code: "text-integration", + }, + ], + total_count: 1, + }, + is_shared: false, + }, + ], + total_count: 1, + pages: { + type: "pages", + page: 1, + next: { + per_page: 2, + starting_after: "your-cursor-from-response", + }, + per_page: 5, + total_pages: 1, + }, + }); + }); +}); diff --git a/tests/wire/unstable/visitors.test.ts b/tests/wire/unstable/visitors.test.ts new file mode 100644 index 00000000..b9c5c9b0 --- /dev/null +++ b/tests/wire/unstable/visitors.test.ts @@ -0,0 +1,866 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("VisitorsClient", () => { + test("retrieveVisitorWithUserId (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "visitor", + id: "6762f3101bb69f9f2193bc64", + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + anonymous: true, + email: "", + phone: "555-555-5555", + name: "Jane Doe", + pseudonym: "Red Duck from Dublin", + avatar: { type: "avatar", image_url: "https://example.com/avatar.png" }, + app_id: "this_is_an_id722_that_should_be_at_least_", + companies: { + type: "company.list", + companies: [ + { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + }, + ], + }, + location_data: { + type: "location_data", + city_name: "Dublin", + continent_code: "EU", + country_code: "IRL", + country_name: "Ireland", + postal_code: "D02 N960", + region_name: "Leinster", + timezone: "Europe/Dublin", + }, + las_request_at: 1663597260, + created_at: 1734538000, + remote_created_at: 1734538000, + signed_up_at: 1734538000, + updated_at: 1734538000, + session_count: 0, + social_profiles: { type: "social_profile.list", social_profiles: ["social_profiles"] }, + owner_id: "5169261", + unsubscribed_from_emails: false, + marked_email_as_spam: false, + has_hard_bounced: false, + tags: { type: "tag.list", tags: [{ id: "8482", name: "tag_name" }] }, + segments: { type: "segment.list", segments: ["segments"] }, + custom_attributes: { key: "value" }, + referrer: "https://www.google.com/", + utm_campaign: "intercom-link", + utm_content: "banner", + utm_medium: "email", + utm_source: "Intercom", + utm_term: "messenger", + do_not_track: false, + }; + server.mockEndpoint().get("/visitors").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.unstable.visitors.retrieveVisitorWithUserId({ + user_id: "user_id", + }); + expect(response).toEqual({ + type: "visitor", + id: "6762f3101bb69f9f2193bc64", + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + anonymous: true, + email: "", + phone: "555-555-5555", + name: "Jane Doe", + pseudonym: "Red Duck from Dublin", + avatar: { + type: "avatar", + image_url: "https://example.com/avatar.png", + }, + app_id: "this_is_an_id722_that_should_be_at_least_", + companies: { + type: "company.list", + companies: [ + { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + }, + ], + }, + location_data: { + type: "location_data", + city_name: "Dublin", + continent_code: "EU", + country_code: "IRL", + country_name: "Ireland", + postal_code: "D02 N960", + region_name: "Leinster", + timezone: "Europe/Dublin", + }, + las_request_at: 1663597260, + created_at: 1734538000, + remote_created_at: 1734538000, + signed_up_at: 1734538000, + updated_at: 1734538000, + session_count: 0, + social_profiles: { + type: "social_profile.list", + social_profiles: ["social_profiles"], + }, + owner_id: "5169261", + unsubscribed_from_emails: false, + marked_email_as_spam: false, + has_hard_bounced: false, + tags: { + type: "tag.list", + tags: [ + { + id: "8482", + name: "tag_name", + }, + ], + }, + segments: { + type: "segment.list", + segments: ["segments"], + }, + custom_attributes: { + key: "value", + }, + referrer: "https://www.google.com/", + utm_campaign: "intercom-link", + utm_content: "banner", + utm_medium: "email", + utm_source: "Intercom", + utm_term: "messenger", + do_not_track: false, + }); + }); + + test("retrieveVisitorWithUserId (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/visitors").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.visitors.retrieveVisitorWithUserId({ + user_id: "user_id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("retrieveVisitorWithUserId (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/visitors").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.unstable.visitors.retrieveVisitorWithUserId({ + user_id: "user_id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("updateVisitor (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "6762f30c1bb69f9f2193bc5e", name: "Gareth Bale" }; + const rawResponseBody = { + type: "visitor", + id: "6762f30c1bb69f9f2193bc5e", + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + anonymous: true, + email: "", + phone: "555-555-5555", + name: "Gareth Bale", + pseudonym: "Violet Suitcase", + avatar: { + type: "avatar", + image_url: "https://static.intercomassets.com/app/pseudonym_avatars_2019/violet-suitcase.png", + }, + app_id: "this_is_an_id716_that_should_be_at_least_", + companies: { + type: "company.list", + companies: [ + { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + }, + ], + }, + location_data: { + type: "location_data", + city_name: "Dublin", + continent_code: "EU", + country_code: "IRL", + country_name: "Ireland", + postal_code: "D02 N960", + region_name: "Leinster", + timezone: "Europe/Dublin", + }, + las_request_at: 1663597260, + created_at: 1734537996, + remote_created_at: 1734537996, + signed_up_at: 1734537996, + updated_at: 1734537997, + session_count: 0, + social_profiles: { type: "social_profile.list", social_profiles: ["social_profiles"] }, + owner_id: "5169261", + unsubscribed_from_emails: false, + marked_email_as_spam: false, + has_hard_bounced: false, + tags: { type: "tag.list", tags: [{ id: "8482", name: "tag_name" }] }, + segments: { type: "segment.list", segments: ["segments"] }, + custom_attributes: { key: "value" }, + referrer: "https://www.google.com/", + utm_campaign: "intercom-link", + utm_content: "banner", + utm_medium: "email", + utm_source: "Intercom", + utm_term: "messenger", + do_not_track: false, + }; + server + .mockEndpoint() + .put("/visitors") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.visitors.updateVisitor({ + id: "6762f30c1bb69f9f2193bc5e", + name: "Gareth Bale", + }); + expect(response).toEqual({ + type: "visitor", + id: "6762f30c1bb69f9f2193bc5e", + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + anonymous: true, + email: "", + phone: "555-555-5555", + name: "Gareth Bale", + pseudonym: "Violet Suitcase", + avatar: { + type: "avatar", + image_url: "https://static.intercomassets.com/app/pseudonym_avatars_2019/violet-suitcase.png", + }, + app_id: "this_is_an_id716_that_should_be_at_least_", + companies: { + type: "company.list", + companies: [ + { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + }, + ], + }, + location_data: { + type: "location_data", + city_name: "Dublin", + continent_code: "EU", + country_code: "IRL", + country_name: "Ireland", + postal_code: "D02 N960", + region_name: "Leinster", + timezone: "Europe/Dublin", + }, + las_request_at: 1663597260, + created_at: 1734537996, + remote_created_at: 1734537996, + signed_up_at: 1734537996, + updated_at: 1734537997, + session_count: 0, + social_profiles: { + type: "social_profile.list", + social_profiles: ["social_profiles"], + }, + owner_id: "5169261", + unsubscribed_from_emails: false, + marked_email_as_spam: false, + has_hard_bounced: false, + tags: { + type: "tag.list", + tags: [ + { + id: "8482", + name: "tag_name", + }, + ], + }, + segments: { + type: "segment.list", + segments: ["segments"], + }, + custom_attributes: { + key: "value", + }, + referrer: "https://www.google.com/", + utm_campaign: "intercom-link", + utm_content: "banner", + utm_medium: "email", + utm_source: "Intercom", + utm_term: "messenger", + do_not_track: false, + }); + }); + + test("updateVisitor (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { user_id: "fail", name: "Christian Fail" }; + const rawResponseBody = { + type: "visitor", + id: "6762f30c1bb69f9f2193bc5e", + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + anonymous: true, + email: "", + phone: "555-555-5555", + name: "Gareth Bale", + pseudonym: "Violet Suitcase", + avatar: { + type: "avatar", + image_url: "https://static.intercomassets.com/app/pseudonym_avatars_2019/violet-suitcase.png", + }, + app_id: "this_is_an_id716_that_should_be_at_least_", + companies: { + type: "company.list", + companies: [ + { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + }, + ], + }, + location_data: { + type: "location_data", + city_name: "Dublin", + continent_code: "EU", + country_code: "IRL", + country_name: "Ireland", + postal_code: "D02 N960", + region_name: "Leinster", + timezone: "Europe/Dublin", + }, + las_request_at: 1663597260, + created_at: 1734537996, + remote_created_at: 1734537996, + signed_up_at: 1734537996, + updated_at: 1734537997, + session_count: 0, + social_profiles: { type: "social_profile.list", social_profiles: ["social_profiles"] }, + owner_id: "5169261", + unsubscribed_from_emails: false, + marked_email_as_spam: false, + has_hard_bounced: false, + tags: { type: "tag.list", tags: [{ id: "8482", name: "tag_name" }] }, + segments: { type: "segment.list", segments: ["segments"] }, + custom_attributes: { key: "value" }, + referrer: "https://www.google.com/", + utm_campaign: "intercom-link", + utm_content: "banner", + utm_medium: "email", + utm_source: "Intercom", + utm_term: "messenger", + do_not_track: false, + }; + server + .mockEndpoint() + .put("/visitors") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.visitors.updateVisitor({ + user_id: "fail", + name: "Christian Fail", + }); + expect(response).toEqual({ + type: "visitor", + id: "6762f30c1bb69f9f2193bc5e", + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + anonymous: true, + email: "", + phone: "555-555-5555", + name: "Gareth Bale", + pseudonym: "Violet Suitcase", + avatar: { + type: "avatar", + image_url: "https://static.intercomassets.com/app/pseudonym_avatars_2019/violet-suitcase.png", + }, + app_id: "this_is_an_id716_that_should_be_at_least_", + companies: { + type: "company.list", + companies: [ + { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + }, + ], + }, + location_data: { + type: "location_data", + city_name: "Dublin", + continent_code: "EU", + country_code: "IRL", + country_name: "Ireland", + postal_code: "D02 N960", + region_name: "Leinster", + timezone: "Europe/Dublin", + }, + las_request_at: 1663597260, + created_at: 1734537996, + remote_created_at: 1734537996, + signed_up_at: 1734537996, + updated_at: 1734537997, + session_count: 0, + social_profiles: { + type: "social_profile.list", + social_profiles: ["social_profiles"], + }, + owner_id: "5169261", + unsubscribed_from_emails: false, + marked_email_as_spam: false, + has_hard_bounced: false, + tags: { + type: "tag.list", + tags: [ + { + id: "8482", + name: "tag_name", + }, + ], + }, + segments: { + type: "segment.list", + segments: ["segments"], + }, + custom_attributes: { + key: "value", + }, + referrer: "https://www.google.com/", + utm_campaign: "intercom-link", + utm_content: "banner", + utm_medium: "email", + utm_source: "Intercom", + utm_term: "messenger", + do_not_track: false, + }); + }); + + test("updateVisitor (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/visitors") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.visitors.updateVisitor({ + key: "value", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("updateVisitor (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { key: "value" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/visitors") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.visitors.updateVisitor({ + key: "value", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + + test("convertVisitor (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + type: "user", + user: { email: "foo@bar.com" }, + visitor: { user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3" }, + }; + const rawResponseBody = { + type: "contact", + id: "6762f3141bb69f9f2193bc6b", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "this_is_an_id728_that_should_be_at_least_", + role: "user", + email: "foo@bar.com", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734538004, + updated_at: 1734538005, + signed_up_at: 1734538004, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: { type: "avatar", image_url: "https://example.org/128Wash.jpg" }, + tags: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f3141bb69f9f2193bc6b/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f3141bb69f9f2193bc6b/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [{ id: "5ba682d23d7cf92bef87bfd4", url: "/companies/5ba682d23d7cf92bef87bfd4" }], + url: "/contacts/6762f3141bb69f9f2193bc6b/companies", + total_count: 0, + has_more: false, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + social_profiles: { + data: [{ type: "social_profile", name: "Facebook", url: "http://twitter.com/th1sland" }], + }, + }; + server + .mockEndpoint() + .post("/visitors/convert") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.visitors.convertVisitor({ + type: "user", + user: { + email: "foo@bar.com", + }, + visitor: { + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + }, + }); + expect(response).toEqual({ + type: "contact", + id: "6762f3141bb69f9f2193bc6b", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "this_is_an_id728_that_should_be_at_least_", + role: "user", + email: "foo@bar.com", + email_domain: "example.com", + phone: "+1123456789", + formatted_phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734538004, + updated_at: 1734538005, + signed_up_at: 1734538004, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: { + type: "avatar", + image_url: "https://example.org/128Wash.jpg", + }, + tags: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f3141bb69f9f2193bc6b/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f3141bb69f9f2193bc6b/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [ + { + id: "5ba682d23d7cf92bef87bfd4", + url: "/companies/5ba682d23d7cf92bef87bfd4", + }, + ], + url: "/contacts/6762f3141bb69f9f2193bc6b/companies", + total_count: 0, + has_more: false, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + social_profiles: { + data: [ + { + type: "social_profile", + name: "Facebook", + url: "http://twitter.com/th1sland", + }, + ], + }, + }); + }); + + test("convertVisitor (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { type: "type", user: { key: "value" }, visitor: { key: "value" } }; + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/visitors/convert") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.visitors.convertVisitor({ + type: "type", + user: { + key: "value", + }, + visitor: { + key: "value", + }, + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); +}); diff --git a/tests/wire/visitors.test.ts b/tests/wire/visitors.test.ts new file mode 100644 index 00000000..7adbb5f2 --- /dev/null +++ b/tests/wire/visitors.test.ts @@ -0,0 +1,847 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("VisitorsClient", () => { + test("find (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + type: "visitor", + id: "6762f3101bb69f9f2193bc64", + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + anonymous: true, + email: "", + phone: "555-555-5555", + name: "Jane Doe", + pseudonym: "Red Duck from Dublin", + avatar: { type: "avatar", image_url: "https://example.com/avatar.png" }, + app_id: "this_is_an_id722_that_should_be_at_least_", + companies: { + type: "company.list", + companies: [ + { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { paid_subscriber: true, monthly_spend: 155.5, team_mates: 9 }, + }, + ], + }, + location_data: { + type: "location_data", + city_name: "Dublin", + continent_code: "EU", + country_code: "IRL", + country_name: "Ireland", + postal_code: "D02 N960", + region_name: "Leinster", + timezone: "Europe/Dublin", + }, + las_request_at: 1663597260, + created_at: 1734538000, + remote_created_at: 1734538000, + signed_up_at: 1734538000, + updated_at: 1734538000, + session_count: 0, + social_profiles: { type: "social_profile.list", social_profiles: ["social_profiles"] }, + owner_id: "5169261", + unsubscribed_from_emails: false, + marked_email_as_spam: false, + has_hard_bounced: false, + tags: { type: "tag.list", tags: [{ id: "8482", name: "tag_name" }] }, + segments: { type: "segment.list", segments: ["segments"] }, + custom_attributes: { key: "value" }, + referrer: "https://www.google.com/", + utm_campaign: "intercom-link", + utm_content: "banner", + utm_medium: "email", + utm_source: "Intercom", + utm_term: "messenger", + do_not_track: false, + }; + server.mockEndpoint().get("/visitors").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.visitors.find({ + user_id: "user_id", + }); + expect(response).toEqual({ + type: "visitor", + id: "6762f3101bb69f9f2193bc64", + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + anonymous: true, + email: "", + phone: "555-555-5555", + name: "Jane Doe", + pseudonym: "Red Duck from Dublin", + avatar: { + type: "avatar", + image_url: "https://example.com/avatar.png", + }, + app_id: "this_is_an_id722_that_should_be_at_least_", + companies: { + type: "company.list", + companies: [ + { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: true, + monthly_spend: 155.5, + team_mates: 9, + }, + }, + ], + }, + location_data: { + type: "location_data", + city_name: "Dublin", + continent_code: "EU", + country_code: "IRL", + country_name: "Ireland", + postal_code: "D02 N960", + region_name: "Leinster", + timezone: "Europe/Dublin", + }, + las_request_at: 1663597260, + created_at: 1734538000, + remote_created_at: 1734538000, + signed_up_at: 1734538000, + updated_at: 1734538000, + session_count: 0, + social_profiles: { + type: "social_profile.list", + social_profiles: ["social_profiles"], + }, + owner_id: "5169261", + unsubscribed_from_emails: false, + marked_email_as_spam: false, + has_hard_bounced: false, + tags: { + type: "tag.list", + tags: [ + { + id: "8482", + name: "tag_name", + }, + ], + }, + segments: { + type: "segment.list", + segments: ["segments"], + }, + custom_attributes: { + key: "value", + }, + referrer: "https://www.google.com/", + utm_campaign: "intercom-link", + utm_content: "banner", + utm_medium: "email", + utm_source: "Intercom", + utm_term: "messenger", + do_not_track: false, + }); + }); + + test("find (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/visitors").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.visitors.find({ + user_id: "user_id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("find (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server.mockEndpoint().get("/visitors").respondWith().statusCode(404).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.visitors.find({ + user_id: "user_id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("update (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "6762f30c1bb69f9f2193bc5e", name: "Gareth Bale" }; + const rawResponseBody = { + type: "visitor", + id: "6762f30c1bb69f9f2193bc5e", + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + anonymous: true, + email: "", + phone: "555-555-5555", + name: "Gareth Bale", + pseudonym: "Violet Suitcase", + avatar: { + type: "avatar", + image_url: "https://static.intercomassets.com/app/pseudonym_avatars_2019/violet-suitcase.png", + }, + app_id: "this_is_an_id716_that_should_be_at_least_", + companies: { + type: "company.list", + companies: [ + { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { paid_subscriber: true, monthly_spend: 155.5, team_mates: 9 }, + }, + ], + }, + location_data: { + type: "location_data", + city_name: "Dublin", + continent_code: "EU", + country_code: "IRL", + country_name: "Ireland", + postal_code: "D02 N960", + region_name: "Leinster", + timezone: "Europe/Dublin", + }, + las_request_at: 1663597260, + created_at: 1734537996, + remote_created_at: 1734537996, + signed_up_at: 1734537996, + updated_at: 1734537997, + session_count: 0, + social_profiles: { type: "social_profile.list", social_profiles: ["social_profiles"] }, + owner_id: "5169261", + unsubscribed_from_emails: false, + marked_email_as_spam: false, + has_hard_bounced: false, + tags: { type: "tag.list", tags: [{ id: "8482", name: "tag_name" }] }, + segments: { type: "segment.list", segments: ["segments"] }, + custom_attributes: { key: "value" }, + referrer: "https://www.google.com/", + utm_campaign: "intercom-link", + utm_content: "banner", + utm_medium: "email", + utm_source: "Intercom", + utm_term: "messenger", + do_not_track: false, + }; + server + .mockEndpoint() + .put("/visitors") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.visitors.update({ + id: "6762f30c1bb69f9f2193bc5e", + name: "Gareth Bale", + }); + expect(response).toEqual({ + type: "visitor", + id: "6762f30c1bb69f9f2193bc5e", + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + anonymous: true, + email: "", + phone: "555-555-5555", + name: "Gareth Bale", + pseudonym: "Violet Suitcase", + avatar: { + type: "avatar", + image_url: "https://static.intercomassets.com/app/pseudonym_avatars_2019/violet-suitcase.png", + }, + app_id: "this_is_an_id716_that_should_be_at_least_", + companies: { + type: "company.list", + companies: [ + { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: true, + monthly_spend: 155.5, + team_mates: 9, + }, + }, + ], + }, + location_data: { + type: "location_data", + city_name: "Dublin", + continent_code: "EU", + country_code: "IRL", + country_name: "Ireland", + postal_code: "D02 N960", + region_name: "Leinster", + timezone: "Europe/Dublin", + }, + las_request_at: 1663597260, + created_at: 1734537996, + remote_created_at: 1734537996, + signed_up_at: 1734537996, + updated_at: 1734537997, + session_count: 0, + social_profiles: { + type: "social_profile.list", + social_profiles: ["social_profiles"], + }, + owner_id: "5169261", + unsubscribed_from_emails: false, + marked_email_as_spam: false, + has_hard_bounced: false, + tags: { + type: "tag.list", + tags: [ + { + id: "8482", + name: "tag_name", + }, + ], + }, + segments: { + type: "segment.list", + segments: ["segments"], + }, + custom_attributes: { + key: "value", + }, + referrer: "https://www.google.com/", + utm_campaign: "intercom-link", + utm_content: "banner", + utm_medium: "email", + utm_source: "Intercom", + utm_term: "messenger", + do_not_track: false, + }); + }); + + test("update (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { user_id: "fail", name: "Christian Fail" }; + const rawResponseBody = { + type: "visitor", + id: "6762f30c1bb69f9f2193bc5e", + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + anonymous: true, + email: "", + phone: "555-555-5555", + name: "Gareth Bale", + pseudonym: "Violet Suitcase", + avatar: { + type: "avatar", + image_url: "https://static.intercomassets.com/app/pseudonym_avatars_2019/violet-suitcase.png", + }, + app_id: "this_is_an_id716_that_should_be_at_least_", + companies: { + type: "company.list", + companies: [ + { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { paid_subscriber: true, monthly_spend: 155.5, team_mates: 9 }, + }, + ], + }, + location_data: { + type: "location_data", + city_name: "Dublin", + continent_code: "EU", + country_code: "IRL", + country_name: "Ireland", + postal_code: "D02 N960", + region_name: "Leinster", + timezone: "Europe/Dublin", + }, + las_request_at: 1663597260, + created_at: 1734537996, + remote_created_at: 1734537996, + signed_up_at: 1734537996, + updated_at: 1734537997, + session_count: 0, + social_profiles: { type: "social_profile.list", social_profiles: ["social_profiles"] }, + owner_id: "5169261", + unsubscribed_from_emails: false, + marked_email_as_spam: false, + has_hard_bounced: false, + tags: { type: "tag.list", tags: [{ id: "8482", name: "tag_name" }] }, + segments: { type: "segment.list", segments: ["segments"] }, + custom_attributes: { key: "value" }, + referrer: "https://www.google.com/", + utm_campaign: "intercom-link", + utm_content: "banner", + utm_medium: "email", + utm_source: "Intercom", + utm_term: "messenger", + do_not_track: false, + }; + server + .mockEndpoint() + .put("/visitors") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.visitors.update({ + user_id: "fail", + name: "Christian Fail", + }); + expect(response).toEqual({ + type: "visitor", + id: "6762f30c1bb69f9f2193bc5e", + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + anonymous: true, + email: "", + phone: "555-555-5555", + name: "Gareth Bale", + pseudonym: "Violet Suitcase", + avatar: { + type: "avatar", + image_url: "https://static.intercomassets.com/app/pseudonym_avatars_2019/violet-suitcase.png", + }, + app_id: "this_is_an_id716_that_should_be_at_least_", + companies: { + type: "company.list", + companies: [ + { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: true, + monthly_spend: 155.5, + team_mates: 9, + }, + }, + ], + }, + location_data: { + type: "location_data", + city_name: "Dublin", + continent_code: "EU", + country_code: "IRL", + country_name: "Ireland", + postal_code: "D02 N960", + region_name: "Leinster", + timezone: "Europe/Dublin", + }, + las_request_at: 1663597260, + created_at: 1734537996, + remote_created_at: 1734537996, + signed_up_at: 1734537996, + updated_at: 1734537997, + session_count: 0, + social_profiles: { + type: "social_profile.list", + social_profiles: ["social_profiles"], + }, + owner_id: "5169261", + unsubscribed_from_emails: false, + marked_email_as_spam: false, + has_hard_bounced: false, + tags: { + type: "tag.list", + tags: [ + { + id: "8482", + name: "tag_name", + }, + ], + }, + segments: { + type: "segment.list", + segments: ["segments"], + }, + custom_attributes: { + key: "value", + }, + referrer: "https://www.google.com/", + utm_campaign: "intercom-link", + utm_content: "banner", + utm_medium: "email", + utm_source: "Intercom", + utm_term: "messenger", + do_not_track: false, + }); + }); + + test("update (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id" }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/visitors") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.visitors.update({ + id: "id", + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("update (4)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { id: "id" }; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/visitors") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.visitors.update({ + id: "id", + }); + }).rejects.toThrow(Intercom.NotFoundError); + }); + + test("mergeToContact (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { + type: "user", + user: { id: "8a88a590-e1c3-41e2-a502-e0649dbf721c", email: "foo@bar.com" }, + visitor: { user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3" }, + }; + const rawResponseBody = { + type: "contact", + id: "6762f3141bb69f9f2193bc6b", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "this_is_an_id728_that_should_be_at_least_", + role: "user", + email: "foo@bar.com", + email_domain: "example.com", + phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734538004, + updated_at: 1734538005, + signed_up_at: 1734538004, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { key: "value" }, + avatar: "https://example.org/128Wash.jpg", + tags: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f3141bb69f9f2193bc6b/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [{ type: "note", id: "123", url: "/contacts/5ba682d23d7cf92bef87bfd4/notes" }], + url: "/contacts/6762f3141bb69f9f2193bc6b/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [{ id: "5ba682d23d7cf92bef87bfd4", url: "/companies/5ba682d23d7cf92bef87bfd4" }], + url: "/contacts/6762f3141bb69f9f2193bc6b/companies", + total_count: 0, + has_more: false, + }, + location: { type: "location", country: "Ireland", region: "Dublin", city: "Dublin" }, + social_profiles: { data: [{ name: "Facebook", url: "http://twitter.com/th1sland" }] }, + }; + server + .mockEndpoint() + .post("/visitors/convert") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.visitors.mergeToContact({ + type: "user", + user: { + id: "8a88a590-e1c3-41e2-a502-e0649dbf721c", + email: "foo@bar.com", + }, + visitor: { + user_id: "3ecf64d0-9ed1-4e9f-88e1-da7d6e6782f3", + }, + }); + expect(response).toEqual({ + type: "contact", + id: "6762f3141bb69f9f2193bc6b", + external_id: "f3b87a2e09d514c6c2e79b9a", + workspace_id: "this_is_an_id728_that_should_be_at_least_", + role: "user", + email: "foo@bar.com", + email_domain: "example.com", + phone: "+1123456789", + name: "John Doe", + owner_id: 123, + has_hard_bounced: false, + marked_email_as_spam: false, + unsubscribed_from_emails: false, + created_at: 1734538004, + updated_at: 1734538005, + signed_up_at: 1734538004, + last_seen_at: 1571672154, + last_replied_at: 1571672154, + last_contacted_at: 1571672154, + last_email_opened_at: 1571672154, + last_email_clicked_at: 1571672154, + language_override: "en", + browser: "Chrome", + browser_version: "80.0.3987.132", + browser_language: "en-US", + os: "Mac OS X", + android_app_name: "Intercom", + android_app_version: "5.0.0", + android_device: "Pixel 3", + android_os_version: "10", + android_sdk_version: "28", + android_last_seen_at: 1571672154, + ios_app_name: "Intercom", + ios_app_version: "5.0.0", + ios_device: "iPhone 11", + ios_os_version: "13.3.1", + ios_sdk_version: "13.3.1", + ios_last_seen_at: 1571672154, + custom_attributes: { + key: "value", + }, + avatar: "https://example.org/128Wash.jpg", + tags: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f3141bb69f9f2193bc6b/tags", + total_count: 0, + has_more: false, + }, + notes: { + data: [ + { + type: "note", + id: "123", + url: "/contacts/5ba682d23d7cf92bef87bfd4/notes", + }, + ], + url: "/contacts/6762f3141bb69f9f2193bc6b/notes", + total_count: 0, + has_more: false, + }, + companies: { + data: [ + { + id: "5ba682d23d7cf92bef87bfd4", + url: "/companies/5ba682d23d7cf92bef87bfd4", + }, + ], + url: "/contacts/6762f3141bb69f9f2193bc6b/companies", + total_count: 0, + has_more: false, + }, + location: { + type: "location", + country: "Ireland", + region: "Dublin", + city: "Dublin", + }, + social_profiles: { + data: [ + { + name: "Facebook", + url: "http://twitter.com/th1sland", + }, + ], + }, + }); + }); + + test("mergeToContact (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { type: "type", user: { id: "id" }, visitor: { id: "id" } }; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .post("/visitors/convert") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.visitors.mergeToContact({ + type: "type", + user: { + id: "id", + }, + visitor: { + id: "id", + }, + }); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); +}); diff --git a/tsconfig.base.json b/tsconfig.base.json new file mode 100644 index 00000000..d7627675 --- /dev/null +++ b/tsconfig.base.json @@ -0,0 +1,18 @@ +{ + "compilerOptions": { + "extendedDiagnostics": true, + "strict": true, + "target": "ES6", + "moduleResolution": "node", + "esModuleInterop": true, + "skipLibCheck": true, + "declaration": true, + "outDir": "dist", + "rootDir": "src", + "baseUrl": "src", + "isolatedModules": true, + "isolatedDeclarations": true + }, + "include": ["src"], + "exclude": [] +} diff --git a/tsconfig.cjs.json b/tsconfig.cjs.json new file mode 100644 index 00000000..5c11446f --- /dev/null +++ b/tsconfig.cjs.json @@ -0,0 +1,9 @@ +{ + "extends": "./tsconfig.base.json", + "compilerOptions": { + "module": "CommonJS", + "outDir": "dist/cjs" + }, + "include": ["src"], + "exclude": [] +} diff --git a/tsconfig.esm.json b/tsconfig.esm.json new file mode 100644 index 00000000..6ce90974 --- /dev/null +++ b/tsconfig.esm.json @@ -0,0 +1,10 @@ +{ + "extends": "./tsconfig.base.json", + "compilerOptions": { + "module": "esnext", + "outDir": "dist/esm", + "verbatimModuleSyntax": true + }, + "include": ["src"], + "exclude": [] +} diff --git a/tsconfig.json b/tsconfig.json index 1ec87dd7..d77fdf00 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,17 +1,3 @@ { - "compilerOptions": { - "extendedDiagnostics": true, - "strict": true, - "target": "ES6", - "moduleResolution": "node", - "esModuleInterop": true, - "skipLibCheck": true, - "declaration": true, - "outDir": "dist", - "rootDir": "src", - "baseUrl": "src", - "module": "CommonJS" - }, - "include": ["src"], - "exclude": [] + "extends": "./tsconfig.cjs.json" } diff --git a/vitest.config.mts b/vitest.config.mts new file mode 100644 index 00000000..ba2ec4f9 --- /dev/null +++ b/vitest.config.mts @@ -0,0 +1,28 @@ +import { defineConfig } from "vitest/config"; +export default defineConfig({ + test: { + projects: [ + { + test: { + globals: true, + name: "unit", + environment: "node", + root: "./tests", + include: ["**/*.test.{js,ts,jsx,tsx}"], + exclude: ["wire/**"], + setupFiles: ["./setup.ts"], + }, + }, + { + test: { + globals: true, + name: "wire", + environment: "node", + root: "./tests/wire", + setupFiles: ["../setup.ts", "../mock-server/setup.ts"], + }, + }, + ], + passWithNoTests: true, + }, +}); diff --git a/yarn.lock b/yarn.lock deleted file mode 100644 index 0276a1af..00000000 --- a/yarn.lock +++ /dev/null @@ -1,3207 +0,0 @@ -# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. -# yarn lockfile v1 - - -"@ampproject/remapping@^2.2.0": - version "2.3.0" - resolved "https://registry.yarnpkg.com/@ampproject/remapping/-/remapping-2.3.0.tgz#ed441b6fa600072520ce18b43d2c8cc8caecc7f4" - integrity sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw== - dependencies: - "@jridgewell/gen-mapping" "^0.3.5" - "@jridgewell/trace-mapping" "^0.3.24" - -"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.12.13", "@babel/code-frame@^7.27.1": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.27.1.tgz#200f715e66d52a23b221a9435534a91cc13ad5be" - integrity sha512-cjQ7ZlQ0Mv3b47hABuTevyTuYN4i+loJKGeV9flcCgIK37cCXRh+L1bd3iBHlynerhQ7BhCkn2BPbQUL+rGqFg== - dependencies: - "@babel/helper-validator-identifier" "^7.27.1" - js-tokens "^4.0.0" - picocolors "^1.1.1" - -"@babel/compat-data@^7.27.2": - version "7.27.5" - resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.27.5.tgz#7d0658ec1a8420fc866d1df1b03bea0e79934c82" - integrity sha512-KiRAp/VoJaWkkte84TvUd9qjdbZAdiqyvMxrGl1N6vzFogKmaLgoM3L1kgtLicp2HP5fBJS8JrZKLVIZGVJAVg== - -"@babel/core@^7.11.6", "@babel/core@^7.12.3", "@babel/core@^7.23.9": - version "7.27.4" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.27.4.tgz#cc1fc55d0ce140a1828d1dd2a2eba285adbfb3ce" - integrity sha512-bXYxrXFubeYdvB0NhD/NBB3Qi6aZeV20GOWVI47t2dkecCEoneR4NPVcb7abpXDEvejgrUfFtG6vG/zxAKmg+g== - dependencies: - "@ampproject/remapping" "^2.2.0" - "@babel/code-frame" "^7.27.1" - "@babel/generator" "^7.27.3" - "@babel/helper-compilation-targets" "^7.27.2" - "@babel/helper-module-transforms" "^7.27.3" - "@babel/helpers" "^7.27.4" - "@babel/parser" "^7.27.4" - "@babel/template" "^7.27.2" - "@babel/traverse" "^7.27.4" - "@babel/types" "^7.27.3" - convert-source-map "^2.0.0" - debug "^4.1.0" - gensync "^1.0.0-beta.2" - json5 "^2.2.3" - semver "^6.3.1" - -"@babel/generator@^7.27.3", "@babel/generator@^7.7.2": - version "7.27.5" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.27.5.tgz#3eb01866b345ba261b04911020cbe22dd4be8c8c" - integrity sha512-ZGhA37l0e/g2s1Cnzdix0O3aLYm66eF8aufiVteOgnwxgnRP8GoyMj7VWsgWnQbVKXyge7hqrFh2K2TQM6t1Hw== - dependencies: - "@babel/parser" "^7.27.5" - "@babel/types" "^7.27.3" - "@jridgewell/gen-mapping" "^0.3.5" - "@jridgewell/trace-mapping" "^0.3.25" - jsesc "^3.0.2" - -"@babel/helper-compilation-targets@^7.27.2": - version "7.27.2" - resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.27.2.tgz#46a0f6efab808d51d29ce96858dd10ce8732733d" - integrity sha512-2+1thGUUWWjLTYTHZWK1n8Yga0ijBz1XAhUXcKy81rd5g6yh7hGqMp45v7cadSbEHc9G3OTv45SyneRN3ps4DQ== - dependencies: - "@babel/compat-data" "^7.27.2" - "@babel/helper-validator-option" "^7.27.1" - browserslist "^4.24.0" - lru-cache "^5.1.1" - semver "^6.3.1" - -"@babel/helper-module-imports@^7.27.1": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.27.1.tgz#7ef769a323e2655e126673bb6d2d6913bbead204" - integrity sha512-0gSFWUPNXNopqtIPQvlD5WgXYI5GY2kP2cCvoT8kczjbfcfuIljTbcWrulD1CIPIX2gt1wghbDy08yE1p+/r3w== - dependencies: - "@babel/traverse" "^7.27.1" - "@babel/types" "^7.27.1" - -"@babel/helper-module-transforms@^7.27.3": - version "7.27.3" - resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.27.3.tgz#db0bbcfba5802f9ef7870705a7ef8788508ede02" - integrity sha512-dSOvYwvyLsWBeIRyOeHXp5vPj5l1I011r52FM1+r1jCERv+aFXYk4whgQccYEGYxK2H3ZAIA8nuPkQ0HaUo3qg== - dependencies: - "@babel/helper-module-imports" "^7.27.1" - "@babel/helper-validator-identifier" "^7.27.1" - "@babel/traverse" "^7.27.3" - -"@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.14.5", "@babel/helper-plugin-utils@^7.27.1", "@babel/helper-plugin-utils@^7.8.0": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.27.1.tgz#ddb2f876534ff8013e6c2b299bf4d39b3c51d44c" - integrity sha512-1gn1Up5YXka3YYAHGKpbideQ5Yjf1tDa9qYcgysz+cNCXukyLl6DjPXhD3VRwSb8c0J9tA4b2+rHEZtc6R0tlw== - -"@babel/helper-string-parser@^7.27.1": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.27.1.tgz#54da796097ab19ce67ed9f88b47bb2ec49367687" - integrity sha512-qMlSxKbpRlAridDExk92nSobyDdpPijUq2DW6oDnUqd0iOGxmQjyqhMIihI9+zv4LPyZdRje2cavWPbCbWm3eA== - -"@babel/helper-validator-identifier@^7.27.1": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.27.1.tgz#a7054dcc145a967dd4dc8fee845a57c1316c9df8" - integrity sha512-D2hP9eA+Sqx1kBZgzxZh0y1trbuU+JoDkiEwqhQ36nodYqJwyEIhPSdMNd7lOm/4io72luTPWH20Yda0xOuUow== - -"@babel/helper-validator-option@^7.27.1": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.27.1.tgz#fa52f5b1e7db1ab049445b421c4471303897702f" - integrity sha512-YvjJow9FxbhFFKDSuFnVCe2WxXk1zWc22fFePVNEaWJEu8IrZVlda6N0uHwzZrUM1il7NC9Mlp4MaJYbYd9JSg== - -"@babel/helpers@^7.27.4": - version "7.27.6" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.27.6.tgz#6456fed15b2cb669d2d1fabe84b66b34991d812c" - integrity sha512-muE8Tt8M22638HU31A3CgfSUciwz1fhATfoVai05aPXGor//CdWDCbnlY1yvBPo07njuVOCNGCSp/GTt12lIug== - dependencies: - "@babel/template" "^7.27.2" - "@babel/types" "^7.27.6" - -"@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.20.7", "@babel/parser@^7.23.9", "@babel/parser@^7.27.2", "@babel/parser@^7.27.4", "@babel/parser@^7.27.5": - version "7.27.5" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.27.5.tgz#ed22f871f110aa285a6fd934a0efed621d118826" - integrity sha512-OsQd175SxWkGlzbny8J3K8TnnDD0N3lrIUtB92xwyRpzaenGZhxDvxN/JgU00U3CDZNj9tPuDJ5H0WS4Nt3vKg== - dependencies: - "@babel/types" "^7.27.3" - -"@babel/plugin-syntax-async-generators@^7.8.4": - version "7.8.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz#a983fb1aeb2ec3f6ed042a210f640e90e786fe0d" - integrity sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-bigint@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-bigint/-/plugin-syntax-bigint-7.8.3.tgz#4c9a6f669f5d0cdf1b90a1671e9a146be5300cea" - integrity sha512-wnTnFlG+YxQm3vDxpGE57Pj0srRU4sHE/mDkt1qv2YJJSeUAec2ma4WLUnUPeKjyrfntVwe/N6dCXpU+zL3Npg== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-class-properties@^7.12.13": - version "7.12.13" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz#b5c987274c4a3a82b89714796931a6b53544ae10" - integrity sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA== - dependencies: - "@babel/helper-plugin-utils" "^7.12.13" - -"@babel/plugin-syntax-class-static-block@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-class-static-block/-/plugin-syntax-class-static-block-7.14.5.tgz#195df89b146b4b78b3bf897fd7a257c84659d406" - integrity sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-syntax-import-attributes@^7.24.7": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-import-attributes/-/plugin-syntax-import-attributes-7.27.1.tgz#34c017d54496f9b11b61474e7ea3dfd5563ffe07" - integrity sha512-oFT0FrKHgF53f4vOsZGi2Hh3I35PfSmVs4IBFLFj4dnafP+hIWDLg3VyKmUHfLoLHlyxY4C7DGtmHuJgn+IGww== - dependencies: - "@babel/helper-plugin-utils" "^7.27.1" - -"@babel/plugin-syntax-import-meta@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-import-meta/-/plugin-syntax-import-meta-7.10.4.tgz#ee601348c370fa334d2207be158777496521fd51" - integrity sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g== - dependencies: - "@babel/helper-plugin-utils" "^7.10.4" - -"@babel/plugin-syntax-json-strings@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz#01ca21b668cd8218c9e640cb6dd88c5412b2c96a" - integrity sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-jsx@^7.7.2": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.27.1.tgz#2f9beb5eff30fa507c5532d107daac7b888fa34c" - integrity sha512-y8YTNIeKoyhGd9O0Jiyzyyqk8gdjnumGTQPsz0xOZOQ2RmkVJeZ1vmmfIvFEKqucBG6axJGBZDE/7iI5suUI/w== - dependencies: - "@babel/helper-plugin-utils" "^7.27.1" - -"@babel/plugin-syntax-logical-assignment-operators@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz#ca91ef46303530448b906652bac2e9fe9941f699" - integrity sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig== - dependencies: - "@babel/helper-plugin-utils" "^7.10.4" - -"@babel/plugin-syntax-nullish-coalescing-operator@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz#167ed70368886081f74b5c36c65a88c03b66d1a9" - integrity sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-numeric-separator@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz#b9b070b3e33570cd9fd07ba7fa91c0dd37b9af97" - integrity sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug== - dependencies: - "@babel/helper-plugin-utils" "^7.10.4" - -"@babel/plugin-syntax-object-rest-spread@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz#60e225edcbd98a640332a2e72dd3e66f1af55871" - integrity sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-optional-catch-binding@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz#6111a265bcfb020eb9efd0fdfd7d26402b9ed6c1" - integrity sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-optional-chaining@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz#4f69c2ab95167e0180cd5336613f8c5788f7d48a" - integrity sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-private-property-in-object@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-private-property-in-object/-/plugin-syntax-private-property-in-object-7.14.5.tgz#0dc6671ec0ea22b6e94a1114f857970cd39de1ad" - integrity sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-syntax-top-level-await@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz#c1cfdadc35a646240001f06138247b741c34d94c" - integrity sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-syntax-typescript@^7.7.2": - version "7.27.1" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.27.1.tgz#5147d29066a793450f220c63fa3a9431b7e6dd18" - integrity sha512-xfYCBMxveHrRMnAWl1ZlPXOZjzkN82THFvLhQhFXFt81Z5HnN+EtUkZhv/zcKpmT3fzmWZB0ywiBrbC3vogbwQ== - dependencies: - "@babel/helper-plugin-utils" "^7.27.1" - -"@babel/template@^7.27.2", "@babel/template@^7.3.3": - version "7.27.2" - resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.27.2.tgz#fa78ceed3c4e7b63ebf6cb39e5852fca45f6809d" - integrity sha512-LPDZ85aEJyYSd18/DkjNh4/y1ntkE5KwUHWTiqgRxruuZL2F1yuHligVHLvcHY2vMHXttKFpJn6LwfI7cw7ODw== - dependencies: - "@babel/code-frame" "^7.27.1" - "@babel/parser" "^7.27.2" - "@babel/types" "^7.27.1" - -"@babel/traverse@^7.27.1", "@babel/traverse@^7.27.3", "@babel/traverse@^7.27.4": - version "7.27.4" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.27.4.tgz#b0045ac7023c8472c3d35effd7cc9ebd638da6ea" - integrity sha512-oNcu2QbHqts9BtOWJosOVJapWjBDSxGCpFvikNR5TGDYDQf3JwpIoMzIKrvfoti93cLfPJEG4tH9SPVeyCGgdA== - dependencies: - "@babel/code-frame" "^7.27.1" - "@babel/generator" "^7.27.3" - "@babel/parser" "^7.27.4" - "@babel/template" "^7.27.2" - "@babel/types" "^7.27.3" - debug "^4.3.1" - globals "^11.1.0" - -"@babel/types@^7.0.0", "@babel/types@^7.20.7", "@babel/types@^7.27.1", "@babel/types@^7.27.3", "@babel/types@^7.27.6", "@babel/types@^7.3.3": - version "7.27.6" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.27.6.tgz#a434ca7add514d4e646c80f7375c0aa2befc5535" - integrity sha512-ETyHEk2VHHvl9b9jZP5IHPavHYk57EhanlRRuae9XCpb/j5bDCbPPMOBfCWhnl/7EDJz0jEMCi/RhccCE8r1+Q== - dependencies: - "@babel/helper-string-parser" "^7.27.1" - "@babel/helper-validator-identifier" "^7.27.1" - -"@bcoe/v8-coverage@^0.2.3": - version "0.2.3" - resolved "https://registry.yarnpkg.com/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" - integrity sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw== - -"@istanbuljs/load-nyc-config@^1.0.0": - version "1.1.0" - resolved "https://registry.yarnpkg.com/@istanbuljs/load-nyc-config/-/load-nyc-config-1.1.0.tgz#fd3db1d59ecf7cf121e80650bb86712f9b55eced" - integrity sha512-VjeHSlIzpv/NyD3N0YuHfXOPDIixcA1q2ZV98wsMqcYlPmv2n3Yb2lYP9XMElnaFVXg5A7YLTeLu6V84uQDjmQ== - dependencies: - camelcase "^5.3.1" - find-up "^4.1.0" - get-package-type "^0.1.0" - js-yaml "^3.13.1" - resolve-from "^5.0.0" - -"@istanbuljs/schema@^0.1.2", "@istanbuljs/schema@^0.1.3": - version "0.1.3" - resolved "https://registry.yarnpkg.com/@istanbuljs/schema/-/schema-0.1.3.tgz#e45e384e4b8ec16bce2fd903af78450f6bf7ec98" - integrity sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA== - -"@jest/console@^29.7.0": - version "29.7.0" - resolved "https://registry.yarnpkg.com/@jest/console/-/console-29.7.0.tgz#cd4822dbdb84529265c5a2bdb529a3c9cc950ffc" - integrity sha512-5Ni4CU7XHQi32IJ398EEP4RrB8eV09sXP2ROqD4bksHrnTree52PsxvX8tpL8LvTZ3pFzXyPbNQReSN41CAhOg== - dependencies: - "@jest/types" "^29.6.3" - "@types/node" "*" - chalk "^4.0.0" - jest-message-util "^29.7.0" - jest-util "^29.7.0" - slash "^3.0.0" - -"@jest/core@^29.7.0": - version "29.7.0" - resolved "https://registry.yarnpkg.com/@jest/core/-/core-29.7.0.tgz#b6cccc239f30ff36609658c5a5e2291757ce448f" - integrity sha512-n7aeXWKMnGtDA48y8TLWJPJmLmmZ642Ceo78cYWEpiD7FzDgmNDV/GCVRorPABdXLJZ/9wzzgZAlHjXjxDHGsg== - dependencies: - "@jest/console" "^29.7.0" - "@jest/reporters" "^29.7.0" - "@jest/test-result" "^29.7.0" - "@jest/transform" "^29.7.0" - "@jest/types" "^29.6.3" - "@types/node" "*" - ansi-escapes "^4.2.1" - chalk "^4.0.0" - ci-info "^3.2.0" - exit "^0.1.2" - graceful-fs "^4.2.9" - jest-changed-files "^29.7.0" - jest-config "^29.7.0" - jest-haste-map "^29.7.0" - jest-message-util "^29.7.0" - jest-regex-util "^29.6.3" - jest-resolve "^29.7.0" - jest-resolve-dependencies "^29.7.0" - jest-runner "^29.7.0" - jest-runtime "^29.7.0" - jest-snapshot "^29.7.0" - jest-util "^29.7.0" - jest-validate "^29.7.0" - jest-watcher "^29.7.0" - micromatch "^4.0.4" - pretty-format "^29.7.0" - slash "^3.0.0" - strip-ansi "^6.0.0" - -"@jest/environment@^29.7.0": - version "29.7.0" - resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-29.7.0.tgz#24d61f54ff1f786f3cd4073b4b94416383baf2a7" - integrity sha512-aQIfHDq33ExsN4jP1NWGXhxgQ/wixs60gDiKO+XVMd8Mn0NWPWgc34ZQDTb2jKaUWQ7MuwoitXAsN2XVXNMpAw== - dependencies: - "@jest/fake-timers" "^29.7.0" - "@jest/types" "^29.6.3" - "@types/node" "*" - jest-mock "^29.7.0" - -"@jest/expect-utils@^29.7.0": - version "29.7.0" - resolved "https://registry.yarnpkg.com/@jest/expect-utils/-/expect-utils-29.7.0.tgz#023efe5d26a8a70f21677d0a1afc0f0a44e3a1c6" - integrity sha512-GlsNBWiFQFCVi9QVSx7f5AgMeLxe9YCCs5PuP2O2LdjDAA8Jh9eX7lA1Jq/xdXw3Wb3hyvlFNfZIfcRetSzYcA== - dependencies: - jest-get-type "^29.6.3" - -"@jest/expect@^29.7.0": - version "29.7.0" - resolved "https://registry.yarnpkg.com/@jest/expect/-/expect-29.7.0.tgz#76a3edb0cb753b70dfbfe23283510d3d45432bf2" - integrity sha512-8uMeAMycttpva3P1lBHB8VciS9V0XAr3GymPpipdyQXbBcuhkLQOSe8E/p92RyAdToS6ZD1tFkX+CkhoECE0dQ== - dependencies: - expect "^29.7.0" - jest-snapshot "^29.7.0" - -"@jest/fake-timers@^29.7.0": - version "29.7.0" - resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-29.7.0.tgz#fd91bf1fffb16d7d0d24a426ab1a47a49881a565" - integrity sha512-q4DH1Ha4TTFPdxLsqDXK1d3+ioSL7yL5oCMJZgDYm6i+6CygW5E5xVr/D1HdsGxjt1ZWSfUAs9OxSB/BNelWrQ== - dependencies: - "@jest/types" "^29.6.3" - "@sinonjs/fake-timers" "^10.0.2" - "@types/node" "*" - jest-message-util "^29.7.0" - jest-mock "^29.7.0" - jest-util "^29.7.0" - -"@jest/globals@^29.7.0": - version "29.7.0" - resolved "https://registry.yarnpkg.com/@jest/globals/-/globals-29.7.0.tgz#8d9290f9ec47ff772607fa864ca1d5a2efae1d4d" - integrity sha512-mpiz3dutLbkW2MNFubUGUEVLkTGiqW6yLVTA+JbP6fI6J5iL9Y0Nlg8k95pcF8ctKwCS7WVxteBs29hhfAotzQ== - dependencies: - "@jest/environment" "^29.7.0" - "@jest/expect" "^29.7.0" - "@jest/types" "^29.6.3" - jest-mock "^29.7.0" - -"@jest/reporters@^29.7.0": - version "29.7.0" - resolved "https://registry.yarnpkg.com/@jest/reporters/-/reporters-29.7.0.tgz#04b262ecb3b8faa83b0b3d321623972393e8f4c7" - integrity sha512-DApq0KJbJOEzAFYjHADNNxAE3KbhxQB1y5Kplb5Waqw6zVbuWatSnMjE5gs8FUgEPmNsnZA3NCWl9NG0ia04Pg== - dependencies: - "@bcoe/v8-coverage" "^0.2.3" - "@jest/console" "^29.7.0" - "@jest/test-result" "^29.7.0" - "@jest/transform" "^29.7.0" - "@jest/types" "^29.6.3" - "@jridgewell/trace-mapping" "^0.3.18" - "@types/node" "*" - chalk "^4.0.0" - collect-v8-coverage "^1.0.0" - exit "^0.1.2" - glob "^7.1.3" - graceful-fs "^4.2.9" - istanbul-lib-coverage "^3.0.0" - istanbul-lib-instrument "^6.0.0" - istanbul-lib-report "^3.0.0" - istanbul-lib-source-maps "^4.0.0" - istanbul-reports "^3.1.3" - jest-message-util "^29.7.0" - jest-util "^29.7.0" - jest-worker "^29.7.0" - slash "^3.0.0" - string-length "^4.0.1" - strip-ansi "^6.0.0" - v8-to-istanbul "^9.0.1" - -"@jest/schemas@^29.6.3": - version "29.6.3" - resolved "https://registry.yarnpkg.com/@jest/schemas/-/schemas-29.6.3.tgz#430b5ce8a4e0044a7e3819663305a7b3091c8e03" - integrity sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA== - dependencies: - "@sinclair/typebox" "^0.27.8" - -"@jest/source-map@^29.6.3": - version "29.6.3" - resolved "https://registry.yarnpkg.com/@jest/source-map/-/source-map-29.6.3.tgz#d90ba772095cf37a34a5eb9413f1b562a08554c4" - integrity sha512-MHjT95QuipcPrpLM+8JMSzFx6eHp5Bm+4XeFDJlwsvVBjmKNiIAvasGK2fxz2WbGRlnvqehFbh07MMa7n3YJnw== - dependencies: - "@jridgewell/trace-mapping" "^0.3.18" - callsites "^3.0.0" - graceful-fs "^4.2.9" - -"@jest/test-result@^29.7.0": - version "29.7.0" - resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-29.7.0.tgz#8db9a80aa1a097bb2262572686734baed9b1657c" - integrity sha512-Fdx+tv6x1zlkJPcWXmMDAG2HBnaR9XPSd5aDWQVsfrZmLVT3lU1cwyxLgRmXR9yrq4NBoEm9BMsfgFzTQAbJYA== - dependencies: - "@jest/console" "^29.7.0" - "@jest/types" "^29.6.3" - "@types/istanbul-lib-coverage" "^2.0.0" - collect-v8-coverage "^1.0.0" - -"@jest/test-sequencer@^29.7.0": - version "29.7.0" - resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-29.7.0.tgz#6cef977ce1d39834a3aea887a1726628a6f072ce" - integrity sha512-GQwJ5WZVrKnOJuiYiAF52UNUJXgTZx1NHjFSEB0qEMmSZKAkdMoIzw/Cj6x6NF4AvV23AUqDpFzQkN/eYCYTxw== - dependencies: - "@jest/test-result" "^29.7.0" - graceful-fs "^4.2.9" - jest-haste-map "^29.7.0" - slash "^3.0.0" - -"@jest/transform@^29.7.0": - version "29.7.0" - resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-29.7.0.tgz#df2dd9c346c7d7768b8a06639994640c642e284c" - integrity sha512-ok/BTPFzFKVMwO5eOHRrvnBVHdRy9IrsrW1GpMaQ9MCnilNLXQKmAX8s1YXDFaai9xJpac2ySzV0YeRRECr2Vw== - dependencies: - "@babel/core" "^7.11.6" - "@jest/types" "^29.6.3" - "@jridgewell/trace-mapping" "^0.3.18" - babel-plugin-istanbul "^6.1.1" - chalk "^4.0.0" - convert-source-map "^2.0.0" - fast-json-stable-stringify "^2.1.0" - graceful-fs "^4.2.9" - jest-haste-map "^29.7.0" - jest-regex-util "^29.6.3" - jest-util "^29.7.0" - micromatch "^4.0.4" - pirates "^4.0.4" - slash "^3.0.0" - write-file-atomic "^4.0.2" - -"@jest/types@^29.6.3": - version "29.6.3" - resolved "https://registry.yarnpkg.com/@jest/types/-/types-29.6.3.tgz#1131f8cf634e7e84c5e77bab12f052af585fba59" - integrity sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw== - dependencies: - "@jest/schemas" "^29.6.3" - "@types/istanbul-lib-coverage" "^2.0.0" - "@types/istanbul-reports" "^3.0.0" - "@types/node" "*" - "@types/yargs" "^17.0.8" - chalk "^4.0.0" - -"@jridgewell/gen-mapping@^0.3.5": - version "0.3.8" - resolved "https://registry.yarnpkg.com/@jridgewell/gen-mapping/-/gen-mapping-0.3.8.tgz#4f0e06362e01362f823d348f1872b08f666d8142" - integrity sha512-imAbBGkb+ebQyxKgzv5Hu2nmROxoDOXHh80evxdoXNOrvAnVx7zimzc1Oo5h9RlfV4vPXaE2iM5pOFbvOCClWA== - dependencies: - "@jridgewell/set-array" "^1.2.1" - "@jridgewell/sourcemap-codec" "^1.4.10" - "@jridgewell/trace-mapping" "^0.3.24" - -"@jridgewell/resolve-uri@^3.1.0": - version "3.1.2" - resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz#7a0ee601f60f99a20c7c7c5ff0c80388c1189bd6" - integrity sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw== - -"@jridgewell/set-array@^1.2.1": - version "1.2.1" - resolved "https://registry.yarnpkg.com/@jridgewell/set-array/-/set-array-1.2.1.tgz#558fb6472ed16a4c850b889530e6b36438c49280" - integrity sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A== - -"@jridgewell/source-map@^0.3.3": - version "0.3.6" - resolved "https://registry.yarnpkg.com/@jridgewell/source-map/-/source-map-0.3.6.tgz#9d71ca886e32502eb9362c9a74a46787c36df81a" - integrity sha512-1ZJTZebgqllO79ue2bm3rIGud/bOe0pP5BjSRCRxxYkEZS8STV7zN84UBbiYu7jy+eCKSnVIUgoWWE/tt+shMQ== - dependencies: - "@jridgewell/gen-mapping" "^0.3.5" - "@jridgewell/trace-mapping" "^0.3.25" - -"@jridgewell/sourcemap-codec@^1.4.10", "@jridgewell/sourcemap-codec@^1.4.14": - version "1.5.0" - resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.0.tgz#3188bcb273a414b0d215fd22a58540b989b9409a" - integrity sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ== - -"@jridgewell/trace-mapping@^0.3.12", "@jridgewell/trace-mapping@^0.3.18", "@jridgewell/trace-mapping@^0.3.24", "@jridgewell/trace-mapping@^0.3.25": - version "0.3.25" - resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz#15f190e98895f3fc23276ee14bc76b675c2e50f0" - integrity sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ== - dependencies: - "@jridgewell/resolve-uri" "^3.1.0" - "@jridgewell/sourcemap-codec" "^1.4.14" - -"@sinclair/typebox@^0.27.8": - version "0.27.8" - resolved "https://registry.yarnpkg.com/@sinclair/typebox/-/typebox-0.27.8.tgz#6667fac16c436b5434a387a34dedb013198f6e6e" - integrity sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA== - -"@sinonjs/commons@^3.0.0": - version "3.0.1" - resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-3.0.1.tgz#1029357e44ca901a615585f6d27738dbc89084cd" - integrity sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ== - dependencies: - type-detect "4.0.8" - -"@sinonjs/fake-timers@^10.0.2": - version "10.3.0" - resolved "https://registry.yarnpkg.com/@sinonjs/fake-timers/-/fake-timers-10.3.0.tgz#55fdff1ecab9f354019129daf4df0dd4d923ea66" - integrity sha512-V4BG07kuYSUkTCSBHG8G8TNhM+F19jXFWnQtzj+we8DrkpSBCee9Z3Ms8yiGer/dlmhe35/Xdgyo3/0rQKg7YA== - dependencies: - "@sinonjs/commons" "^3.0.0" - -"@tootallnate/once@2": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@tootallnate/once/-/once-2.0.0.tgz#f544a148d3ab35801c1f633a7441fd87c2e484bf" - integrity sha512-XCuKFP5PS55gnMVu3dty8KPatLqUoy/ZYzDzAGCQ8JNFCkLXzmI7vNHCR+XpbZaMWQK/vQubr7PkYq8g470J/A== - -"@types/babel__core@^7.1.14": - version "7.20.5" - resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.20.5.tgz#3df15f27ba85319caa07ba08d0721889bb39c017" - integrity sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA== - dependencies: - "@babel/parser" "^7.20.7" - "@babel/types" "^7.20.7" - "@types/babel__generator" "*" - "@types/babel__template" "*" - "@types/babel__traverse" "*" - -"@types/babel__generator@*": - version "7.27.0" - resolved "https://registry.yarnpkg.com/@types/babel__generator/-/babel__generator-7.27.0.tgz#b5819294c51179957afaec341442f9341e4108a9" - integrity sha512-ufFd2Xi92OAVPYsy+P4n7/U7e68fex0+Ee8gSG9KX7eo084CWiQ4sdxktvdl0bOPupXtVJPY19zk6EwWqUQ8lg== - dependencies: - "@babel/types" "^7.0.0" - -"@types/babel__template@*": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@types/babel__template/-/babel__template-7.4.4.tgz#5672513701c1b2199bc6dad636a9d7491586766f" - integrity sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A== - dependencies: - "@babel/parser" "^7.1.0" - "@babel/types" "^7.0.0" - -"@types/babel__traverse@*", "@types/babel__traverse@^7.0.6": - version "7.20.7" - resolved "https://registry.yarnpkg.com/@types/babel__traverse/-/babel__traverse-7.20.7.tgz#968cdc2366ec3da159f61166428ee40f370e56c2" - integrity sha512-dkO5fhS7+/oos4ciWxyEyjWe48zmG6wbCheo/G2ZnHx4fs3EU6YC6UM8rk56gAjNJ9P3MTH2jo5jb92/K6wbng== - dependencies: - "@babel/types" "^7.20.7" - -"@types/eslint-scope@^3.7.7": - version "3.7.7" - resolved "https://registry.yarnpkg.com/@types/eslint-scope/-/eslint-scope-3.7.7.tgz#3108bd5f18b0cdb277c867b3dd449c9ed7079ac5" - integrity sha512-MzMFlSLBqNF2gcHWO0G1vP/YQyfvrxZ0bF+u7mzUdZ1/xK4A4sru+nraZz5i3iEIk1l1uyicaDVTB4QbbEkAYg== - dependencies: - "@types/eslint" "*" - "@types/estree" "*" - -"@types/eslint@*": - version "9.6.1" - resolved "https://registry.yarnpkg.com/@types/eslint/-/eslint-9.6.1.tgz#d5795ad732ce81715f27f75da913004a56751584" - integrity sha512-FXx2pKgId/WyYo2jXw63kk7/+TY7u7AziEJxJAnSFzHlqTAS3Ync6SvgYAN/k4/PQpnnVuzoMuVnByKK2qp0ag== - dependencies: - "@types/estree" "*" - "@types/json-schema" "*" - -"@types/estree@*", "@types/estree@^1.0.6": - version "1.0.8" - resolved "https://registry.yarnpkg.com/@types/estree/-/estree-1.0.8.tgz#958b91c991b1867ced318bedea0e215ee050726e" - integrity sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w== - -"@types/graceful-fs@^4.1.3": - version "4.1.9" - resolved "https://registry.yarnpkg.com/@types/graceful-fs/-/graceful-fs-4.1.9.tgz#2a06bc0f68a20ab37b3e36aa238be6abdf49e8b4" - integrity sha512-olP3sd1qOEe5dXTSaFvQG+02VdRXcdytWLAZsAq1PecU8uqQAhkrnbli7DagjtXKW/Bl7YJbUsa8MPcuc8LHEQ== - dependencies: - "@types/node" "*" - -"@types/istanbul-lib-coverage@*", "@types/istanbul-lib-coverage@^2.0.0", "@types/istanbul-lib-coverage@^2.0.1": - version "2.0.6" - resolved "https://registry.yarnpkg.com/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz#7739c232a1fee9b4d3ce8985f314c0c6d33549d7" - integrity sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w== - -"@types/istanbul-lib-report@*": - version "3.0.3" - resolved "https://registry.yarnpkg.com/@types/istanbul-lib-report/-/istanbul-lib-report-3.0.3.tgz#53047614ae72e19fc0401d872de3ae2b4ce350bf" - integrity sha512-NQn7AHQnk/RSLOxrBbGyJM/aVQ+pjj5HCgasFxc0K/KhoATfQ/47AyUl15I2yBUpihjmas+a+VJBOqecrFH+uA== - dependencies: - "@types/istanbul-lib-coverage" "*" - -"@types/istanbul-reports@^3.0.0": - version "3.0.4" - resolved "https://registry.yarnpkg.com/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz#0f03e3d2f670fbdac586e34b433783070cc16f54" - integrity sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ== - dependencies: - "@types/istanbul-lib-report" "*" - -"@types/jest@^29.5.14": - version "29.5.14" - resolved "https://registry.yarnpkg.com/@types/jest/-/jest-29.5.14.tgz#2b910912fa1d6856cadcd0c1f95af7df1d6049e5" - integrity sha512-ZN+4sdnLUbo8EVvVc2ao0GFW6oVrQRPn4K2lglySj7APvSrgzxHiNNK99us4WDMi57xxA2yggblIAMNhXOotLQ== - dependencies: - expect "^29.0.0" - pretty-format "^29.0.0" - -"@types/jsdom@^20.0.0": - version "20.0.1" - resolved "https://registry.yarnpkg.com/@types/jsdom/-/jsdom-20.0.1.tgz#07c14bc19bd2f918c1929541cdaacae894744808" - integrity sha512-d0r18sZPmMQr1eG35u12FZfhIXNrnsPU/g5wvRKCUf/tOGilKKwYMYGqh33BNR6ba+2gkHw1EUiHoN3mn7E5IQ== - dependencies: - "@types/node" "*" - "@types/tough-cookie" "*" - parse5 "^7.0.0" - -"@types/json-schema@*", "@types/json-schema@^7.0.15", "@types/json-schema@^7.0.9": - version "7.0.15" - resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.15.tgz#596a1747233694d50f6ad8a7869fcb6f56cf5841" - integrity sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA== - -"@types/node-fetch@^2.6.12": - version "2.6.12" - resolved "https://registry.yarnpkg.com/@types/node-fetch/-/node-fetch-2.6.12.tgz#8ab5c3ef8330f13100a7479e2cd56d3386830a03" - integrity sha512-8nneRWKCg3rMtF69nLQJnOYUcbafYeFSjqkw3jCRLsqkWFlHaoQrr5mXmofFGOx3DKn7UfmBMyov8ySvLRVldA== - dependencies: - "@types/node" "*" - form-data "^4.0.0" - -"@types/node@*": - version "24.0.4" - resolved "https://registry.yarnpkg.com/@types/node/-/node-24.0.4.tgz#dbae889912bda33a7f57669fb8587c1a56bc0c1f" - integrity sha512-ulyqAkrhnuNq9pB76DRBTkcS6YsmDALy6Ua63V8OhrOBgbcYt6IOdzpw5P1+dyRIyMerzLkeYWBeOXPpA9GMAA== - dependencies: - undici-types "~7.8.0" - -"@types/node@^18.19.70": - version "18.19.112" - resolved "https://registry.yarnpkg.com/@types/node/-/node-18.19.112.tgz#cd2aee9c075402e0e1942a44101428881dbeb110" - integrity sha512-i+Vukt9POdS/MBI7YrrkkI5fMfwFtOjphSmt4WXYLfwqsfr6z/HdCx7LqT9M7JktGob8WNgj8nFB4TbGNE4Cog== - dependencies: - undici-types "~5.26.4" - -"@types/qs@^6.9.17": - version "6.14.0" - resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.14.0.tgz#d8b60cecf62f2db0fb68e5e006077b9178b85de5" - integrity sha512-eOunJqu0K1923aExK6y8p6fsihYEn/BYuQ4g0CxAAgFc4b/ZLN4CrsRZ55srTdqoiLzU2B2evC+apEIxprEzkQ== - -"@types/readable-stream@^4.0.18": - version "4.0.21" - resolved "https://registry.yarnpkg.com/@types/readable-stream/-/readable-stream-4.0.21.tgz#716558454a5e0c3c0651520f8154efc3288f59cb" - integrity sha512-19eKVv9tugr03IgfXlA9UVUVRbW6IuqRO5B92Dl4a6pT7K8uaGrNS0GkxiZD0BOk6PLuXl5FhWl//eX/pzYdTQ== - dependencies: - "@types/node" "*" - -"@types/stack-utils@^2.0.0": - version "2.0.3" - resolved "https://registry.yarnpkg.com/@types/stack-utils/-/stack-utils-2.0.3.tgz#6209321eb2c1712a7e7466422b8cb1fc0d9dd5d8" - integrity sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw== - -"@types/tough-cookie@*": - version "4.0.5" - resolved "https://registry.yarnpkg.com/@types/tough-cookie/-/tough-cookie-4.0.5.tgz#cb6e2a691b70cb177c6e3ae9c1d2e8b2ea8cd304" - integrity sha512-/Ad8+nIOV7Rl++6f1BdKxFSMgmoqEoYbHRpPcx3JEfv8VRsQe9Z4mCXeJBzxs7mbHY/XOZZuXlRNfhpVPbs6ZA== - -"@types/url-join@4.0.1": - version "4.0.1" - resolved "https://registry.yarnpkg.com/@types/url-join/-/url-join-4.0.1.tgz#4989c97f969464647a8586c7252d97b449cdc045" - integrity sha512-wDXw9LEEUHyV+7UWy7U315nrJGJ7p1BzaCxDpEoLr789Dk1WDVMMlf3iBfbG2F8NdWnYyFbtTxUn2ZNbm1Q4LQ== - -"@types/yargs-parser@*": - version "21.0.3" - resolved "https://registry.yarnpkg.com/@types/yargs-parser/-/yargs-parser-21.0.3.tgz#815e30b786d2e8f0dcd85fd5bcf5e1a04d008f15" - integrity sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ== - -"@types/yargs@^17.0.8": - version "17.0.33" - resolved "https://registry.yarnpkg.com/@types/yargs/-/yargs-17.0.33.tgz#8c32303da83eec050a84b3c7ae7b9f922d13e32d" - integrity sha512-WpxBCKWPLr4xSsHgz511rFJAM+wS28w2zEO1QDNY5zM/S8ok70NNfztH0xwhqKyaK0OHCbN98LDAZuy1ctxDkA== - dependencies: - "@types/yargs-parser" "*" - -"@webassemblyjs/ast@1.14.1", "@webassemblyjs/ast@^1.14.1": - version "1.14.1" - resolved "https://registry.yarnpkg.com/@webassemblyjs/ast/-/ast-1.14.1.tgz#a9f6a07f2b03c95c8d38c4536a1fdfb521ff55b6" - integrity sha512-nuBEDgQfm1ccRp/8bCQrx1frohyufl4JlbMMZ4P1wpeOfDhF6FQkxZJ1b/e+PLwr6X1Nhw6OLme5usuBWYBvuQ== - dependencies: - "@webassemblyjs/helper-numbers" "1.13.2" - "@webassemblyjs/helper-wasm-bytecode" "1.13.2" - -"@webassemblyjs/floating-point-hex-parser@1.13.2": - version "1.13.2" - resolved "https://registry.yarnpkg.com/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.13.2.tgz#fcca1eeddb1cc4e7b6eed4fc7956d6813b21b9fb" - integrity sha512-6oXyTOzbKxGH4steLbLNOu71Oj+C8Lg34n6CqRvqfS2O71BxY6ByfMDRhBytzknj9yGUPVJ1qIKhRlAwO1AovA== - -"@webassemblyjs/helper-api-error@1.13.2": - version "1.13.2" - resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-api-error/-/helper-api-error-1.13.2.tgz#e0a16152248bc38daee76dd7e21f15c5ef3ab1e7" - integrity sha512-U56GMYxy4ZQCbDZd6JuvvNV/WFildOjsaWD3Tzzvmw/mas3cXzRJPMjP83JqEsgSbyrmaGjBfDtV7KDXV9UzFQ== - -"@webassemblyjs/helper-buffer@1.14.1": - version "1.14.1" - resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-buffer/-/helper-buffer-1.14.1.tgz#822a9bc603166531f7d5df84e67b5bf99b72b96b" - integrity sha512-jyH7wtcHiKssDtFPRB+iQdxlDf96m0E39yb0k5uJVhFGleZFoNw1c4aeIcVUPPbXUVJ94wwnMOAqUHyzoEPVMA== - -"@webassemblyjs/helper-numbers@1.13.2": - version "1.13.2" - resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-numbers/-/helper-numbers-1.13.2.tgz#dbd932548e7119f4b8a7877fd5a8d20e63490b2d" - integrity sha512-FE8aCmS5Q6eQYcV3gI35O4J789wlQA+7JrqTTpJqn5emA4U2hvwJmvFRC0HODS+3Ye6WioDklgd6scJ3+PLnEA== - dependencies: - "@webassemblyjs/floating-point-hex-parser" "1.13.2" - "@webassemblyjs/helper-api-error" "1.13.2" - "@xtuc/long" "4.2.2" - -"@webassemblyjs/helper-wasm-bytecode@1.13.2": - version "1.13.2" - resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.13.2.tgz#e556108758f448aae84c850e593ce18a0eb31e0b" - integrity sha512-3QbLKy93F0EAIXLh0ogEVR6rOubA9AoZ+WRYhNbFyuB70j3dRdwH9g+qXhLAO0kiYGlg3TxDV+I4rQTr/YNXkA== - -"@webassemblyjs/helper-wasm-section@1.14.1": - version "1.14.1" - resolved "https://registry.yarnpkg.com/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.14.1.tgz#9629dda9c4430eab54b591053d6dc6f3ba050348" - integrity sha512-ds5mXEqTJ6oxRoqjhWDU83OgzAYjwsCV8Lo/N+oRsNDmx/ZDpqalmrtgOMkHwxsG0iI//3BwWAErYRHtgn0dZw== - dependencies: - "@webassemblyjs/ast" "1.14.1" - "@webassemblyjs/helper-buffer" "1.14.1" - "@webassemblyjs/helper-wasm-bytecode" "1.13.2" - "@webassemblyjs/wasm-gen" "1.14.1" - -"@webassemblyjs/ieee754@1.13.2": - version "1.13.2" - resolved "https://registry.yarnpkg.com/@webassemblyjs/ieee754/-/ieee754-1.13.2.tgz#1c5eaace1d606ada2c7fd7045ea9356c59ee0dba" - integrity sha512-4LtOzh58S/5lX4ITKxnAK2USuNEvpdVV9AlgGQb8rJDHaLeHciwG4zlGr0j/SNWlr7x3vO1lDEsuePvtcDNCkw== - dependencies: - "@xtuc/ieee754" "^1.2.0" - -"@webassemblyjs/leb128@1.13.2": - version "1.13.2" - resolved "https://registry.yarnpkg.com/@webassemblyjs/leb128/-/leb128-1.13.2.tgz#57c5c3deb0105d02ce25fa3fd74f4ebc9fd0bbb0" - integrity sha512-Lde1oNoIdzVzdkNEAWZ1dZ5orIbff80YPdHx20mrHwHrVNNTjNr8E3xz9BdpcGqRQbAEa+fkrCb+fRFTl/6sQw== - dependencies: - "@xtuc/long" "4.2.2" - -"@webassemblyjs/utf8@1.13.2": - version "1.13.2" - resolved "https://registry.yarnpkg.com/@webassemblyjs/utf8/-/utf8-1.13.2.tgz#917a20e93f71ad5602966c2d685ae0c6c21f60f1" - integrity sha512-3NQWGjKTASY1xV5m7Hr0iPeXD9+RDobLll3T9d2AO+g3my8xy5peVyjSag4I50mR1bBSN/Ct12lo+R9tJk0NZQ== - -"@webassemblyjs/wasm-edit@^1.14.1": - version "1.14.1" - resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-edit/-/wasm-edit-1.14.1.tgz#ac6689f502219b59198ddec42dcd496b1004d597" - integrity sha512-RNJUIQH/J8iA/1NzlE4N7KtyZNHi3w7at7hDjvRNm5rcUXa00z1vRz3glZoULfJ5mpvYhLybmVcwcjGrC1pRrQ== - dependencies: - "@webassemblyjs/ast" "1.14.1" - "@webassemblyjs/helper-buffer" "1.14.1" - "@webassemblyjs/helper-wasm-bytecode" "1.13.2" - "@webassemblyjs/helper-wasm-section" "1.14.1" - "@webassemblyjs/wasm-gen" "1.14.1" - "@webassemblyjs/wasm-opt" "1.14.1" - "@webassemblyjs/wasm-parser" "1.14.1" - "@webassemblyjs/wast-printer" "1.14.1" - -"@webassemblyjs/wasm-gen@1.14.1": - version "1.14.1" - resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-gen/-/wasm-gen-1.14.1.tgz#991e7f0c090cb0bb62bbac882076e3d219da9570" - integrity sha512-AmomSIjP8ZbfGQhumkNvgC33AY7qtMCXnN6bL2u2Js4gVCg8fp735aEiMSBbDR7UQIj90n4wKAFUSEd0QN2Ukg== - dependencies: - "@webassemblyjs/ast" "1.14.1" - "@webassemblyjs/helper-wasm-bytecode" "1.13.2" - "@webassemblyjs/ieee754" "1.13.2" - "@webassemblyjs/leb128" "1.13.2" - "@webassemblyjs/utf8" "1.13.2" - -"@webassemblyjs/wasm-opt@1.14.1": - version "1.14.1" - resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-opt/-/wasm-opt-1.14.1.tgz#e6f71ed7ccae46781c206017d3c14c50efa8106b" - integrity sha512-PTcKLUNvBqnY2U6E5bdOQcSM+oVP/PmrDY9NzowJjislEjwP/C4an2303MCVS2Mg9d3AJpIGdUFIQQWbPds0Sw== - dependencies: - "@webassemblyjs/ast" "1.14.1" - "@webassemblyjs/helper-buffer" "1.14.1" - "@webassemblyjs/wasm-gen" "1.14.1" - "@webassemblyjs/wasm-parser" "1.14.1" - -"@webassemblyjs/wasm-parser@1.14.1", "@webassemblyjs/wasm-parser@^1.14.1": - version "1.14.1" - resolved "https://registry.yarnpkg.com/@webassemblyjs/wasm-parser/-/wasm-parser-1.14.1.tgz#b3e13f1893605ca78b52c68e54cf6a865f90b9fb" - integrity sha512-JLBl+KZ0R5qB7mCnud/yyX08jWFw5MsoalJ1pQ4EdFlgj9VdXKGuENGsiCIjegI1W7p91rUlcB/LB5yRJKNTcQ== - dependencies: - "@webassemblyjs/ast" "1.14.1" - "@webassemblyjs/helper-api-error" "1.13.2" - "@webassemblyjs/helper-wasm-bytecode" "1.13.2" - "@webassemblyjs/ieee754" "1.13.2" - "@webassemblyjs/leb128" "1.13.2" - "@webassemblyjs/utf8" "1.13.2" - -"@webassemblyjs/wast-printer@1.14.1": - version "1.14.1" - resolved "https://registry.yarnpkg.com/@webassemblyjs/wast-printer/-/wast-printer-1.14.1.tgz#3bb3e9638a8ae5fdaf9610e7a06b4d9f9aa6fe07" - integrity sha512-kPSSXE6De1XOR820C90RIo2ogvZG+c3KiHzqUoO/F34Y2shGzesfqv7o57xrxovZJH/MetF5UjroJ/R/3isoiw== - dependencies: - "@webassemblyjs/ast" "1.14.1" - "@xtuc/long" "4.2.2" - -"@xtuc/ieee754@^1.2.0": - version "1.2.0" - resolved "https://registry.yarnpkg.com/@xtuc/ieee754/-/ieee754-1.2.0.tgz#eef014a3145ae477a1cbc00cd1e552336dceb790" - integrity sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA== - -"@xtuc/long@4.2.2": - version "4.2.2" - resolved "https://registry.yarnpkg.com/@xtuc/long/-/long-4.2.2.tgz#d291c6a4e97989b5c61d9acf396ae4fe133a718d" - integrity sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ== - -abab@^2.0.6: - version "2.0.6" - resolved "https://registry.yarnpkg.com/abab/-/abab-2.0.6.tgz#41b80f2c871d19686216b82309231cfd3cb3d291" - integrity sha512-j2afSsaIENvHZN2B8GOpF566vZ5WVk5opAiMTvWgaQT8DkbOqsTfvNAvHoRGU2zzP8cPoqys+xHTRDWW8L+/BA== - -abort-controller@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/abort-controller/-/abort-controller-3.0.0.tgz#eaf54d53b62bae4138e809ca225c8439a6efb392" - integrity sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg== - dependencies: - event-target-shim "^5.0.0" - -acorn-globals@^7.0.0: - version "7.0.1" - resolved "https://registry.yarnpkg.com/acorn-globals/-/acorn-globals-7.0.1.tgz#0dbf05c44fa7c94332914c02066d5beff62c40c3" - integrity sha512-umOSDSDrfHbTNPuNpC2NSnnA3LUrqpevPb4T9jRx4MagXNS0rs+gwiTcAvqCRmsD6utzsrzNt+ebm00SNWiC3Q== - dependencies: - acorn "^8.1.0" - acorn-walk "^8.0.2" - -acorn-walk@^8.0.2: - version "8.3.4" - resolved "https://registry.yarnpkg.com/acorn-walk/-/acorn-walk-8.3.4.tgz#794dd169c3977edf4ba4ea47583587c5866236b7" - integrity sha512-ueEepnujpqee2o5aIYnvHU6C0A42MNdsIDeqy5BydrkuC5R1ZuUFnm27EeFJGoEHJQgn3uleRvmTXaJgfXbt4g== - dependencies: - acorn "^8.11.0" - -acorn@^8.1.0, acorn@^8.11.0, acorn@^8.14.0, acorn@^8.8.1: - version "8.15.0" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.15.0.tgz#a360898bc415edaac46c8241f6383975b930b816" - integrity sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg== - -agent-base@6: - version "6.0.2" - resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-6.0.2.tgz#49fff58577cfee3f37176feab4c22e00f86d7f77" - integrity sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ== - dependencies: - debug "4" - -ajv-formats@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/ajv-formats/-/ajv-formats-2.1.1.tgz#6e669400659eb74973bbf2e33327180a0996b520" - integrity sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA== - dependencies: - ajv "^8.0.0" - -ajv-keywords@^5.1.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-5.1.0.tgz#69d4d385a4733cdbeab44964a1170a88f87f0e16" - integrity sha512-YCS/JNFAUyr5vAuhk1DWm1CBxRHW9LbJ2ozWeemrIqpbsqKjHVxYPyi5GC0rjZIT5JxJ3virVTS8wk4i/Z+krw== - dependencies: - fast-deep-equal "^3.1.3" - -ajv@^8.0.0, ajv@^8.9.0: - version "8.17.1" - resolved "https://registry.yarnpkg.com/ajv/-/ajv-8.17.1.tgz#37d9a5c776af6bc92d7f4f9510eba4c0a60d11a6" - integrity sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g== - dependencies: - fast-deep-equal "^3.1.3" - fast-uri "^3.0.1" - json-schema-traverse "^1.0.0" - require-from-string "^2.0.2" - -ansi-escapes@^4.2.1: - version "4.3.2" - resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-4.3.2.tgz#6b2291d1db7d98b6521d5f1efa42d0f3a9feb65e" - integrity sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ== - dependencies: - type-fest "^0.21.3" - -ansi-regex@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.1.tgz#082cb2c89c9fe8659a311a53bd6a4dc5301db304" - integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== - -ansi-styles@^4.0.0, ansi-styles@^4.1.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" - integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== - dependencies: - color-convert "^2.0.1" - -ansi-styles@^5.0.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-5.2.0.tgz#07449690ad45777d1924ac2abb2fc8895dba836b" - integrity sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA== - -anymatch@^3.0.3: - version "3.1.3" - resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-3.1.3.tgz#790c58b19ba1720a84205b57c618d5ad8524973e" - integrity sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw== - dependencies: - normalize-path "^3.0.0" - picomatch "^2.0.4" - -argparse@^1.0.7: - version "1.0.10" - resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.10.tgz#bcd6791ea5ae09725e17e5ad988134cd40b3d911" - integrity sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg== - dependencies: - sprintf-js "~1.0.2" - -async@^3.2.3: - version "3.2.6" - resolved "https://registry.yarnpkg.com/async/-/async-3.2.6.tgz#1b0728e14929d51b85b449b7f06e27c1145e38ce" - integrity sha512-htCUDlxyyCLMgaM3xXg0C0LW2xqfuQ6p05pCEIsXuyQ+a1koYKTuBMzRNwmybfLgvJDMd0r1LTn4+E0Ti6C2AA== - -asynckit@^0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" - integrity sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q== - -babel-jest@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-29.7.0.tgz#f4369919225b684c56085998ac63dbd05be020d5" - integrity sha512-BrvGY3xZSwEcCzKvKsCi2GgHqDqsYkOP4/by5xCgIwGXQxIEh+8ew3gmrE1y7XRR6LHZIj6yLYnUi/mm2KXKBg== - dependencies: - "@jest/transform" "^29.7.0" - "@types/babel__core" "^7.1.14" - babel-plugin-istanbul "^6.1.1" - babel-preset-jest "^29.6.3" - chalk "^4.0.0" - graceful-fs "^4.2.9" - slash "^3.0.0" - -babel-plugin-istanbul@^6.1.1: - version "6.1.1" - resolved "https://registry.yarnpkg.com/babel-plugin-istanbul/-/babel-plugin-istanbul-6.1.1.tgz#fa88ec59232fd9b4e36dbbc540a8ec9a9b47da73" - integrity sha512-Y1IQok9821cC9onCx5otgFfRm7Lm+I+wwxOx738M/WLPZ9Q42m4IG5W0FNX8WLL2gYMZo3JkuXIH2DOpWM+qwA== - dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@istanbuljs/load-nyc-config" "^1.0.0" - "@istanbuljs/schema" "^0.1.2" - istanbul-lib-instrument "^5.0.4" - test-exclude "^6.0.0" - -babel-plugin-jest-hoist@^29.6.3: - version "29.6.3" - resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-29.6.3.tgz#aadbe943464182a8922c3c927c3067ff40d24626" - integrity sha512-ESAc/RJvGTFEzRwOTT4+lNDk/GNHMkKbNzsvT0qKRfDyyYTskxB5rnU2njIDYVxXCBHHEI1c0YwHob3WaYujOg== - dependencies: - "@babel/template" "^7.3.3" - "@babel/types" "^7.3.3" - "@types/babel__core" "^7.1.14" - "@types/babel__traverse" "^7.0.6" - -babel-preset-current-node-syntax@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/babel-preset-current-node-syntax/-/babel-preset-current-node-syntax-1.1.0.tgz#9a929eafece419612ef4ae4f60b1862ebad8ef30" - integrity sha512-ldYss8SbBlWva1bs28q78Ju5Zq1F+8BrqBZZ0VFhLBvhh6lCpC2o3gDJi/5DRLs9FgYZCnmPYIVFU4lRXCkyUw== - dependencies: - "@babel/plugin-syntax-async-generators" "^7.8.4" - "@babel/plugin-syntax-bigint" "^7.8.3" - "@babel/plugin-syntax-class-properties" "^7.12.13" - "@babel/plugin-syntax-class-static-block" "^7.14.5" - "@babel/plugin-syntax-import-attributes" "^7.24.7" - "@babel/plugin-syntax-import-meta" "^7.10.4" - "@babel/plugin-syntax-json-strings" "^7.8.3" - "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" - "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" - "@babel/plugin-syntax-numeric-separator" "^7.10.4" - "@babel/plugin-syntax-object-rest-spread" "^7.8.3" - "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" - "@babel/plugin-syntax-optional-chaining" "^7.8.3" - "@babel/plugin-syntax-private-property-in-object" "^7.14.5" - "@babel/plugin-syntax-top-level-await" "^7.14.5" - -babel-preset-jest@^29.6.3: - version "29.6.3" - resolved "https://registry.yarnpkg.com/babel-preset-jest/-/babel-preset-jest-29.6.3.tgz#fa05fa510e7d493896d7b0dd2033601c840f171c" - integrity sha512-0B3bhxR6snWXJZtR/RliHTDPRgn1sNHOR0yVtq/IiQFyuOVjFS+wuio/R4gSNkyYmKmJB4wGZv2NZanmKmTnNA== - dependencies: - babel-plugin-jest-hoist "^29.6.3" - babel-preset-current-node-syntax "^1.0.0" - -balanced-match@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" - integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== - -base64-js@^1.3.1: - version "1.5.1" - resolved "https://registry.yarnpkg.com/base64-js/-/base64-js-1.5.1.tgz#1b1b440160a5bf7ad40b650f095963481903930a" - integrity sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA== - -brace-expansion@^1.1.7: - version "1.1.12" - resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.12.tgz#ab9b454466e5a8cc3a187beaad580412a9c5b843" - integrity sha512-9T9UjW3r0UW5c1Q7GTwllptXwhvYmEzFhzMfZ9H7FQWt+uZePjZPjBP/W1ZEyZ1twGWom5/56TF4lPcqjnDHcg== - dependencies: - balanced-match "^1.0.0" - concat-map "0.0.1" - -brace-expansion@^2.0.1: - version "2.0.2" - resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-2.0.2.tgz#54fc53237a613d854c7bd37463aad17df87214e7" - integrity sha512-Jt0vHyM+jmUBqojB7E1NIYadt0vI0Qxjxd2TErW94wDz+E2LAm5vKMXXwg6ZZBTHPuUlDgQHKXvjGBdfcF1ZDQ== - dependencies: - balanced-match "^1.0.0" - -braces@^3.0.3: - version "3.0.3" - resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.3.tgz#490332f40919452272d55a8480adc0c441358789" - integrity sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA== - dependencies: - fill-range "^7.1.1" - -browserslist@^4.24.0: - version "4.25.1" - resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.25.1.tgz#ba9e8e6f298a1d86f829c9b975e07948967bb111" - integrity sha512-KGj0KoOMXLpSNkkEI6Z6mShmQy0bc1I+T7K9N81k4WWMrfz+6fQ6es80B/YLAeRoKvjYE1YSHHOW1qe9xIVzHw== - dependencies: - caniuse-lite "^1.0.30001726" - electron-to-chromium "^1.5.173" - node-releases "^2.0.19" - update-browserslist-db "^1.1.3" - -bs-logger@^0.2.6: - version "0.2.6" - resolved "https://registry.yarnpkg.com/bs-logger/-/bs-logger-0.2.6.tgz#eb7d365307a72cf974cc6cda76b68354ad336bd8" - integrity sha512-pd8DCoxmbgc7hyPKOvxtqNcjYoOsABPQdcCUjGp3d42VR2CX1ORhk2A87oqqu5R1kk+76nsxZupkmyd+MVtCog== - dependencies: - fast-json-stable-stringify "2.x" - -bser@2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/bser/-/bser-2.1.1.tgz#e6787da20ece9d07998533cfd9de6f5c38f4bc05" - integrity sha512-gQxTNE/GAfIIrmHLUE3oJyp5FO6HRBfhjnw4/wMmA63ZGDJnWBmgY/lyQBpnDUkGmAhbSe39tx2d/iTOAfglwQ== - dependencies: - node-int64 "^0.4.0" - -buffer-from@^1.0.0: - version "1.1.2" - resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.2.tgz#2b146a6fd72e80b4f55d255f35ed59a3a9a41bd5" - integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== - -buffer@^6.0.3: - version "6.0.3" - resolved "https://registry.yarnpkg.com/buffer/-/buffer-6.0.3.tgz#2ace578459cc8fbe2a70aaa8f52ee63b6a74c6c6" - integrity sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA== - dependencies: - base64-js "^1.3.1" - ieee754 "^1.2.1" - -call-bind-apply-helpers@^1.0.1, call-bind-apply-helpers@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz#4b5428c222be985d79c3d82657479dbe0b59b2d6" - integrity sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ== - dependencies: - es-errors "^1.3.0" - function-bind "^1.1.2" - -call-bound@^1.0.2: - version "1.0.4" - resolved "https://registry.yarnpkg.com/call-bound/-/call-bound-1.0.4.tgz#238de935d2a2a692928c538c7ccfa91067fd062a" - integrity sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg== - dependencies: - call-bind-apply-helpers "^1.0.2" - get-intrinsic "^1.3.0" - -callsites@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" - integrity sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ== - -camelcase@^5.3.1: - version "5.3.1" - resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.3.1.tgz#e3c9b31569e106811df242f715725a1f4c494320" - integrity sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg== - -camelcase@^6.2.0: - version "6.3.0" - resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-6.3.0.tgz#5685b95eb209ac9c0c177467778c9c84df58ba9a" - integrity sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA== - -caniuse-lite@^1.0.30001726: - version "1.0.30001726" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001726.tgz#a15bd87d5a4bf01f6b6f70ae7c97fdfd28b5ae47" - integrity sha512-VQAUIUzBiZ/UnlM28fSp2CRF3ivUn1BWEvxMcVTNwpw91Py1pGbPIyIKtd+tzct9C3ouceCVdGAXxZOpZAsgdw== - -chalk@^4.0.0, chalk@^4.0.2, chalk@^4.1.0: - version "4.1.2" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" - integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== - dependencies: - ansi-styles "^4.1.0" - supports-color "^7.1.0" - -char-regex@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/char-regex/-/char-regex-1.0.2.tgz#d744358226217f981ed58f479b1d6bcc29545dcf" - integrity sha512-kWWXztvZ5SBQV+eRgKFeh8q5sLuZY2+8WUIzlxWVTg+oGwY14qylx1KbKzHd8P6ZYkAg0xyIDU9JMHhyJMZ1jw== - -chrome-trace-event@^1.0.2: - version "1.0.4" - resolved "https://registry.yarnpkg.com/chrome-trace-event/-/chrome-trace-event-1.0.4.tgz#05bffd7ff928465093314708c93bdfa9bd1f0f5b" - integrity sha512-rNjApaLzuwaOTjCiT8lSDdGN1APCiqkChLMJxJPWLunPAt5fy8xgU9/jNOchV84wfIxrA0lRQB7oCT8jrn/wrQ== - -ci-info@^3.2.0: - version "3.9.0" - resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-3.9.0.tgz#4279a62028a7b1f262f3473fc9605f5e218c59b4" - integrity sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ== - -cjs-module-lexer@^1.0.0: - version "1.4.3" - resolved "https://registry.yarnpkg.com/cjs-module-lexer/-/cjs-module-lexer-1.4.3.tgz#0f79731eb8cfe1ec72acd4066efac9d61991b00d" - integrity sha512-9z8TZaGM1pfswYeXrUpzPrkx8UnWYdhJclsiYMm6x/w5+nN+8Tf/LnAgfLGQCm59qAOxU8WwHEq2vNwF6i4j+Q== - -cliui@^8.0.1: - version "8.0.1" - resolved "https://registry.yarnpkg.com/cliui/-/cliui-8.0.1.tgz#0c04b075db02cbfe60dc8e6cf2f5486b1a3608aa" - integrity sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ== - dependencies: - string-width "^4.2.0" - strip-ansi "^6.0.1" - wrap-ansi "^7.0.0" - -co@^4.6.0: - version "4.6.0" - resolved "https://registry.yarnpkg.com/co/-/co-4.6.0.tgz#6ea6bdf3d853ae54ccb8e47bfa0bf3f9031fb184" - integrity sha512-QVb0dM5HvG+uaxitm8wONl7jltx8dqhfU33DcqtOZcLSVIKSDDLDi7+0LbAKiyI8hD9u42m2YxXSkMGWThaecQ== - -collect-v8-coverage@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/collect-v8-coverage/-/collect-v8-coverage-1.0.2.tgz#c0b29bcd33bcd0779a1344c2136051e6afd3d9e9" - integrity sha512-lHl4d5/ONEbLlJvaJNtsF/Lz+WvB07u2ycqTYbdrq7UypDXailES4valYb2eWiJFxZlVmpGekfqoxQhzyFdT4Q== - -color-convert@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" - integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== - dependencies: - color-name "~1.1.4" - -color-name@~1.1.4: - version "1.1.4" - resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" - integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== - -combined-stream@^1.0.8: - version "1.0.8" - resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.8.tgz#c3d45a8b34fd730631a110a8a2520682b31d5a7f" - integrity sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg== - dependencies: - delayed-stream "~1.0.0" - -commander@^2.20.0: - version "2.20.3" - resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" - integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ== - -concat-map@0.0.1: - version "0.0.1" - resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" - integrity sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg== - -convert-source-map@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-2.0.0.tgz#4b560f649fc4e918dd0ab75cf4961e8bc882d82a" - integrity sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg== - -create-jest@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/create-jest/-/create-jest-29.7.0.tgz#a355c5b3cb1e1af02ba177fe7afd7feee49a5320" - integrity sha512-Adz2bdH0Vq3F53KEMJOoftQFutWCukm6J24wbPWRO4k1kMY7gS7ds/uoJkNuV8wDCtWWnuwGcJwpWcih+zEW1Q== - dependencies: - "@jest/types" "^29.6.3" - chalk "^4.0.0" - exit "^0.1.2" - graceful-fs "^4.2.9" - jest-config "^29.7.0" - jest-util "^29.7.0" - prompts "^2.0.1" - -cross-spawn@^7.0.3: - version "7.0.6" - resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.6.tgz#8a58fe78f00dcd70c370451759dfbfaf03e8ee9f" - integrity sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA== - dependencies: - path-key "^3.1.0" - shebang-command "^2.0.0" - which "^2.0.1" - -cssom@^0.5.0: - version "0.5.0" - resolved "https://registry.yarnpkg.com/cssom/-/cssom-0.5.0.tgz#d254fa92cd8b6fbd83811b9fbaed34663cc17c36" - integrity sha512-iKuQcq+NdHqlAcwUY0o/HL69XQrUaQdMjmStJ8JFmUaiiQErlhrmuigkg/CU4E2J0IyUKUrMAgl36TvN67MqTw== - -cssom@~0.3.6: - version "0.3.8" - resolved "https://registry.yarnpkg.com/cssom/-/cssom-0.3.8.tgz#9f1276f5b2b463f2114d3f2c75250af8c1a36f4a" - integrity sha512-b0tGHbfegbhPJpxpiBPU2sCkigAqtM9O121le6bbOlgyV+NyGyCmVfJ6QW9eRjz8CpNfWEOYBIMIGRYkLwsIYg== - -cssstyle@^2.3.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/cssstyle/-/cssstyle-2.3.0.tgz#ff665a0ddbdc31864b09647f34163443d90b0852" - integrity sha512-AZL67abkUzIuvcHqk7c09cezpGNcxUxU4Ioi/05xHk4DQeTkWmGYftIE6ctU6AEt+Gn4n1lDStOtj7FKycP71A== - dependencies: - cssom "~0.3.6" - -data-urls@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/data-urls/-/data-urls-3.0.2.tgz#9cf24a477ae22bcef5cd5f6f0bfbc1d2d3be9143" - integrity sha512-Jy/tj3ldjZJo63sVAvg6LHt2mHvl4V6AgRAmNDtLdm7faqtsx+aJG42rsyCo9JCoRVKwPFzKlIPx3DIibwSIaQ== - dependencies: - abab "^2.0.6" - whatwg-mimetype "^3.0.0" - whatwg-url "^11.0.0" - -debug@4, debug@^4.1.0, debug@^4.1.1, debug@^4.3.1: - version "4.4.1" - resolved "https://registry.yarnpkg.com/debug/-/debug-4.4.1.tgz#e5a8bc6cbc4c6cd3e64308b0693a3d4fa550189b" - integrity sha512-KcKCqiftBJcZr++7ykoDIEwSa3XWowTfNPo92BYxjXiyYEVrUQh2aLyhxBCwww+heortUFxEJYcRzosstTEBYQ== - dependencies: - ms "^2.1.3" - -decimal.js@^10.4.2: - version "10.5.0" - resolved "https://registry.yarnpkg.com/decimal.js/-/decimal.js-10.5.0.tgz#0f371c7cf6c4898ce0afb09836db73cd82010f22" - integrity sha512-8vDa8Qxvr/+d94hSh5P3IJwI5t8/c0KsMp+g8bNw9cY2icONa5aPfvKeieW1WlG0WQYwwhJ7mjui2xtiePQSXw== - -dedent@^1.0.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/dedent/-/dedent-1.6.0.tgz#79d52d6389b1ffa67d2bcef59ba51847a9d503b2" - integrity sha512-F1Z+5UCFpmQUzJa11agbyPVMbpgT/qA3/SKyJ1jyBgm7dUcUEa8v9JwDkerSQXfakBwFljIxhOJqGkjUwZ9FSA== - -deepmerge@^4.2.2: - version "4.3.1" - resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-4.3.1.tgz#44b5f2147cd3b00d4b56137685966f26fd25dd4a" - integrity sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A== - -delayed-stream@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" - integrity sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ== - -detect-newline@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/detect-newline/-/detect-newline-3.1.0.tgz#576f5dfc63ae1a192ff192d8ad3af6308991b651" - integrity sha512-TLz+x/vEXm/Y7P7wn1EJFNLxYpUD4TgMosxY6fAVJUnJMbupHBOncxyWUG9OpTaH9EBD7uFI5LfEgmMOc54DsA== - -diff-sequences@^29.6.3: - version "29.6.3" - resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-29.6.3.tgz#4deaf894d11407c51efc8418012f9e70b84ea921" - integrity sha512-EjePK1srD3P08o2j4f0ExnylqRs5B9tJjcp9t1krH2qRi8CCdsYfwe9JgSLurFBWwq4uOlipzfk5fHNvwFKr8Q== - -domexception@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/domexception/-/domexception-4.0.0.tgz#4ad1be56ccadc86fc76d033353999a8037d03673" - integrity sha512-A2is4PLG+eeSfoTMA95/s4pvAoSo2mKtiM5jlHkAVewmiO8ISFTFKZjH7UAM1Atli/OT/7JHOrJRJiMKUZKYBw== - dependencies: - webidl-conversions "^7.0.0" - -dunder-proto@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/dunder-proto/-/dunder-proto-1.0.1.tgz#d7ae667e1dc83482f8b70fd0f6eefc50da30f58a" - integrity sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A== - dependencies: - call-bind-apply-helpers "^1.0.1" - es-errors "^1.3.0" - gopd "^1.2.0" - -ejs@^3.1.10: - version "3.1.10" - resolved "https://registry.yarnpkg.com/ejs/-/ejs-3.1.10.tgz#69ab8358b14e896f80cc39e62087b88500c3ac3b" - integrity sha512-UeJmFfOrAQS8OJWPZ4qtgHyWExa088/MtK5UEyoJGFH67cDEXkZSviOiKRCZ4Xij0zxI3JECgYs3oKx+AizQBA== - dependencies: - jake "^10.8.5" - -electron-to-chromium@^1.5.173: - version "1.5.173" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.5.173.tgz#1aeba57204fe19425921a29946ef543653f5e896" - integrity sha512-2bFhXP2zqSfQHugjqJIDFVwa+qIxyNApenmXTp9EjaKtdPrES5Qcn9/aSFy/NaP2E+fWG/zxKu/LBvY36p5VNQ== - -emittery@^0.13.1: - version "0.13.1" - resolved "https://registry.yarnpkg.com/emittery/-/emittery-0.13.1.tgz#c04b8c3457490e0847ae51fced3af52d338e3dad" - integrity sha512-DeWwawk6r5yR9jFgnDKYt4sLS0LmHJJi3ZOnb5/JdbYwj3nW+FxQnHIjhBKz8YLC7oRNPVM9NQ47I3CVx34eqQ== - -emoji-regex@^8.0.0: - version "8.0.0" - resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" - integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== - -enhanced-resolve@^5.0.0, enhanced-resolve@^5.17.1: - version "5.18.2" - resolved "https://registry.yarnpkg.com/enhanced-resolve/-/enhanced-resolve-5.18.2.tgz#7903c5b32ffd4b2143eeb4b92472bd68effd5464" - integrity sha512-6Jw4sE1maoRJo3q8MsSIn2onJFbLTOjY9hlx4DZXmOKvLRd1Ok2kXmAGXaafL2+ijsJZ1ClYbl/pmqr9+k4iUQ== - dependencies: - graceful-fs "^4.2.4" - tapable "^2.2.0" - -entities@^6.0.0: - version "6.0.1" - resolved "https://registry.yarnpkg.com/entities/-/entities-6.0.1.tgz#c28c34a43379ca7f61d074130b2f5f7020a30694" - integrity sha512-aN97NXWF6AWBTahfVOIrB/NShkzi5H7F9r1s9mD3cDj4Ko5f2qhhVoYMibXF7GlLveb/D2ioWay8lxI97Ven3g== - -error-ex@^1.3.1: - version "1.3.2" - resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" - integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== - dependencies: - is-arrayish "^0.2.1" - -es-define-property@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/es-define-property/-/es-define-property-1.0.1.tgz#983eb2f9a6724e9303f61addf011c72e09e0b0fa" - integrity sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g== - -es-errors@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/es-errors/-/es-errors-1.3.0.tgz#05f75a25dab98e4fb1dcd5e1472c0546d5057c8f" - integrity sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw== - -es-module-lexer@^1.2.1: - version "1.7.0" - resolved "https://registry.yarnpkg.com/es-module-lexer/-/es-module-lexer-1.7.0.tgz#9159601561880a85f2734560a9099b2c31e5372a" - integrity sha512-jEQoCwk8hyb2AZziIOLhDqpm5+2ww5uIE6lkO/6jcOCusfk6LhMHpXXfBLXTZ7Ydyt0j4VoUQv6uGNYbdW+kBA== - -es-object-atoms@^1.0.0, es-object-atoms@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/es-object-atoms/-/es-object-atoms-1.1.1.tgz#1c4f2c4837327597ce69d2ca190a7fdd172338c1" - integrity sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA== - dependencies: - es-errors "^1.3.0" - -es-set-tostringtag@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/es-set-tostringtag/-/es-set-tostringtag-2.1.0.tgz#f31dbbe0c183b00a6d26eb6325c810c0fd18bd4d" - integrity sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA== - dependencies: - es-errors "^1.3.0" - get-intrinsic "^1.2.6" - has-tostringtag "^1.0.2" - hasown "^2.0.2" - -escalade@^3.1.1, escalade@^3.2.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.2.0.tgz#011a3f69856ba189dffa7dc8fcce99d2a87903e5" - integrity sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA== - -escape-string-regexp@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz#a30304e99daa32e23b2fd20f51babd07cffca344" - integrity sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w== - -escodegen@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-2.1.0.tgz#ba93bbb7a43986d29d6041f99f5262da773e2e17" - integrity sha512-2NlIDTwUWJN0mRPQOdtQBzbUHvdGY2P1VXSyU83Q3xKxM7WHX2Ql8dKq782Q9TgQUNOLEzEYu9bzLNj1q88I5w== - dependencies: - esprima "^4.0.1" - estraverse "^5.2.0" - esutils "^2.0.2" - optionalDependencies: - source-map "~0.6.1" - -eslint-scope@5.1.1: - version "5.1.1" - resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-5.1.1.tgz#e786e59a66cb92b3f6c1fb0d508aab174848f48c" - integrity sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw== - dependencies: - esrecurse "^4.3.0" - estraverse "^4.1.1" - -esprima@^4.0.0, esprima@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" - integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== - -esrecurse@^4.3.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.3.0.tgz#7ad7964d679abb28bee72cec63758b1c5d2c9921" - integrity sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag== - dependencies: - estraverse "^5.2.0" - -estraverse@^4.1.1: - version "4.3.0" - resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.3.0.tgz#398ad3f3c5a24948be7725e83d11a7de28cdbd1d" - integrity sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw== - -estraverse@^5.2.0: - version "5.3.0" - resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-5.3.0.tgz#2eea5290702f26ab8fe5370370ff86c965d21123" - integrity sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA== - -esutils@^2.0.2: - version "2.0.3" - resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.3.tgz#74d2eb4de0b8da1293711910d50775b9b710ef64" - integrity sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g== - -event-target-shim@^5.0.0: - version "5.0.1" - resolved "https://registry.yarnpkg.com/event-target-shim/-/event-target-shim-5.0.1.tgz#5d4d3ebdf9583d63a5333ce2deb7480ab2b05789" - integrity sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ== - -events@^3.2.0, events@^3.3.0: - version "3.3.0" - resolved "https://registry.yarnpkg.com/events/-/events-3.3.0.tgz#31a95ad0a924e2d2c419a813aeb2c4e878ea7400" - integrity sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q== - -execa@^5.0.0: - version "5.1.1" - resolved "https://registry.yarnpkg.com/execa/-/execa-5.1.1.tgz#f80ad9cbf4298f7bd1d4c9555c21e93741c411dd" - integrity sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg== - dependencies: - cross-spawn "^7.0.3" - get-stream "^6.0.0" - human-signals "^2.1.0" - is-stream "^2.0.0" - merge-stream "^2.0.0" - npm-run-path "^4.0.1" - onetime "^5.1.2" - signal-exit "^3.0.3" - strip-final-newline "^2.0.0" - -exit@^0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/exit/-/exit-0.1.2.tgz#0632638f8d877cc82107d30a0fff1a17cba1cd0c" - integrity sha512-Zk/eNKV2zbjpKzrsQ+n1G6poVbErQxJ0LBOJXaKZ1EViLzH+hrLu9cdXI4zw9dBQJslwBEpbQ2P1oS7nDxs6jQ== - -expect@^29.0.0, expect@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/expect/-/expect-29.7.0.tgz#578874590dcb3214514084c08115d8aee61e11bc" - integrity sha512-2Zks0hf1VLFYI1kbh0I5jP3KHHyCHpkfyHBzsSXRFgl/Bg9mWYfMW8oD+PdMPlEwy5HNsR9JutYy6pMeOh61nw== - dependencies: - "@jest/expect-utils" "^29.7.0" - jest-get-type "^29.6.3" - jest-matcher-utils "^29.7.0" - jest-message-util "^29.7.0" - jest-util "^29.7.0" - -fast-deep-equal@^3.1.3: - version "3.1.3" - resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" - integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== - -fast-json-stable-stringify@2.x, fast-json-stable-stringify@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz#874bf69c6f404c2b5d99c481341399fd55892633" - integrity sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw== - -fast-uri@^3.0.1: - version "3.0.6" - resolved "https://registry.yarnpkg.com/fast-uri/-/fast-uri-3.0.6.tgz#88f130b77cfaea2378d56bf970dea21257a68748" - integrity sha512-Atfo14OibSv5wAp4VWNsFYE1AchQRTv9cBGWET4pZWHzYshFSS9NQI6I57rdKn9croWVMbYFbLhJ+yJvmZIIHw== - -fb-watchman@^2.0.0: - version "2.0.2" - resolved "https://registry.yarnpkg.com/fb-watchman/-/fb-watchman-2.0.2.tgz#e9524ee6b5c77e9e5001af0f85f3adbb8623255c" - integrity sha512-p5161BqbuCaSnB8jIbzQHOlpgsPmK5rJVDfDKO91Axs5NC1uu3HRQm6wt9cd9/+GtQQIO53JdGXXoyDpTAsgYA== - dependencies: - bser "2.1.1" - -filelist@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/filelist/-/filelist-1.0.4.tgz#f78978a1e944775ff9e62e744424f215e58352b5" - integrity sha512-w1cEuf3S+DrLCQL7ET6kz+gmlJdbq9J7yXCSjK/OZCPA+qEN1WyF4ZAf0YYJa4/shHJra2t/d/r8SV4Ji+x+8Q== - dependencies: - minimatch "^5.0.1" - -fill-range@^7.1.1: - version "7.1.1" - resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-7.1.1.tgz#44265d3cac07e3ea7dc247516380643754a05292" - integrity sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg== - dependencies: - to-regex-range "^5.0.1" - -find-up@^4.0.0, find-up@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/find-up/-/find-up-4.1.0.tgz#97afe7d6cdc0bc5928584b7c8d7b16e8a9aa5d19" - integrity sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw== - dependencies: - locate-path "^5.0.0" - path-exists "^4.0.0" - -form-data@^4.0.0: - version "4.0.4" - resolved "https://registry.yarnpkg.com/form-data/-/form-data-4.0.4.tgz#784cdcce0669a9d68e94d11ac4eea98088edd2c4" - integrity sha512-KrGhL9Q4zjj0kiUt5OO4Mr/A/jlI2jDYs5eHBpYHPcBEVSiipAvn2Ko2HnPe20rmcuuvMHNdZFp+4IlGTMF0Ow== - dependencies: - asynckit "^0.4.0" - combined-stream "^1.0.8" - es-set-tostringtag "^2.1.0" - hasown "^2.0.2" - mime-types "^2.1.12" - -formdata-node@^6.0.3: - version "6.0.3" - resolved "https://registry.yarnpkg.com/formdata-node/-/formdata-node-6.0.3.tgz#48f8e2206ae2befded82af621ef015f08168dc6d" - integrity sha512-8e1++BCiTzUno9v5IZ2J6bv4RU+3UKDmqWUQD0MIMVCd9AdhWkO1gw57oo1mNEX1dMq2EGI+FbWz4B92pscSQg== - -fs.realpath@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" - integrity sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw== - -fsevents@^2.3.2: - version "2.3.3" - resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.3.tgz#cac6407785d03675a2a5e1a5305c697b347d90d6" - integrity sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw== - -function-bind@^1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.2.tgz#2c02d864d97f3ea6c8830c464cbd11ab6eab7a1c" - integrity sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA== - -gensync@^1.0.0-beta.2: - version "1.0.0-beta.2" - resolved "https://registry.yarnpkg.com/gensync/-/gensync-1.0.0-beta.2.tgz#32a6ee76c3d7f52d46b2b1ae5d93fea8580a25e0" - integrity sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg== - -get-caller-file@^2.0.5: - version "2.0.5" - resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" - integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== - -get-intrinsic@^1.2.5, get-intrinsic@^1.2.6, get-intrinsic@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.3.0.tgz#743f0e3b6964a93a5491ed1bffaae054d7f98d01" - integrity sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ== - dependencies: - call-bind-apply-helpers "^1.0.2" - es-define-property "^1.0.1" - es-errors "^1.3.0" - es-object-atoms "^1.1.1" - function-bind "^1.1.2" - get-proto "^1.0.1" - gopd "^1.2.0" - has-symbols "^1.1.0" - hasown "^2.0.2" - math-intrinsics "^1.1.0" - -get-package-type@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/get-package-type/-/get-package-type-0.1.0.tgz#8de2d803cff44df3bc6c456e6668b36c3926e11a" - integrity sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q== - -get-proto@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/get-proto/-/get-proto-1.0.1.tgz#150b3f2743869ef3e851ec0c49d15b1d14d00ee1" - integrity sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g== - dependencies: - dunder-proto "^1.0.1" - es-object-atoms "^1.0.0" - -get-stream@^6.0.0: - version "6.0.1" - resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-6.0.1.tgz#a262d8eef67aced57c2852ad6167526a43cbf7b7" - integrity sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg== - -glob-to-regexp@^0.4.1: - version "0.4.1" - resolved "https://registry.yarnpkg.com/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz#c75297087c851b9a578bd217dd59a92f59fe546e" - integrity sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw== - -glob@^7.1.3, glob@^7.1.4: - version "7.2.3" - resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.3.tgz#b8df0fb802bbfa8e89bd1d938b4e16578ed44f2b" - integrity sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q== - dependencies: - fs.realpath "^1.0.0" - inflight "^1.0.4" - inherits "2" - minimatch "^3.1.1" - once "^1.3.0" - path-is-absolute "^1.0.0" - -globals@^11.1.0: - version "11.12.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" - integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== - -gopd@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/gopd/-/gopd-1.2.0.tgz#89f56b8217bdbc8802bd299df6d7f1081d7e51a1" - integrity sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg== - -graceful-fs@^4.1.2, graceful-fs@^4.2.11, graceful-fs@^4.2.4, graceful-fs@^4.2.9: - version "4.2.11" - resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3" - integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== - -has-flag@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" - integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== - -has-symbols@^1.0.3, has-symbols@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.1.0.tgz#fc9c6a783a084951d0b971fe1018de813707a338" - integrity sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ== - -has-tostringtag@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/has-tostringtag/-/has-tostringtag-1.0.2.tgz#2cdc42d40bef2e5b4eeab7c01a73c54ce7ab5abc" - integrity sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw== - dependencies: - has-symbols "^1.0.3" - -hasown@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/hasown/-/hasown-2.0.2.tgz#003eaf91be7adc372e84ec59dc37252cedb80003" - integrity sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ== - dependencies: - function-bind "^1.1.2" - -html-encoding-sniffer@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/html-encoding-sniffer/-/html-encoding-sniffer-3.0.0.tgz#2cb1a8cf0db52414776e5b2a7a04d5dd98158de9" - integrity sha512-oWv4T4yJ52iKrufjnyZPkrN0CH3QnrUqdB6In1g5Fe1mia8GmF36gnfNySxoZtxD5+NmYw1EElVXiBk93UeskA== - dependencies: - whatwg-encoding "^2.0.0" - -html-escaper@^2.0.0: - version "2.0.2" - resolved "https://registry.yarnpkg.com/html-escaper/-/html-escaper-2.0.2.tgz#dfd60027da36a36dfcbe236262c00a5822681453" - integrity sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg== - -http-proxy-agent@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/http-proxy-agent/-/http-proxy-agent-5.0.0.tgz#5129800203520d434f142bc78ff3c170800f2b43" - integrity sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w== - dependencies: - "@tootallnate/once" "2" - agent-base "6" - debug "4" - -https-proxy-agent@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz#c59ef224a04fe8b754f3db0063a25ea30d0005d6" - integrity sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA== - dependencies: - agent-base "6" - debug "4" - -human-signals@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-2.1.0.tgz#dc91fcba42e4d06e4abaed33b3e7a3c02f514ea0" - integrity sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw== - -iconv-lite@0.6.3: - version "0.6.3" - resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.6.3.tgz#a52f80bf38da1952eb5c681790719871a1a72501" - integrity sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw== - dependencies: - safer-buffer ">= 2.1.2 < 3.0.0" - -ieee754@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.2.1.tgz#8eb7a10a63fff25d15a57b001586d177d1b0d352" - integrity sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA== - -import-local@^3.0.2: - version "3.2.0" - resolved "https://registry.yarnpkg.com/import-local/-/import-local-3.2.0.tgz#c3d5c745798c02a6f8b897726aba5100186ee260" - integrity sha512-2SPlun1JUPWoM6t3F0dw0FkCF/jWY8kttcY4f599GLTSjh2OCuuhdTkJQsEcZzBqbXZGKMK2OqW1oZsjtf/gQA== - dependencies: - pkg-dir "^4.2.0" - resolve-cwd "^3.0.0" - -imurmurhash@^0.1.4: - version "0.1.4" - resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" - integrity sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA== - -inflight@^1.0.4: - version "1.0.6" - resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" - integrity sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA== - dependencies: - once "^1.3.0" - wrappy "1" - -inherits@2: - version "2.0.4" - resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" - integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== - -is-arrayish@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" - integrity sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg== - -is-core-module@^2.16.0: - version "2.16.1" - resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.16.1.tgz#2a98801a849f43e2add644fbb6bc6229b19a4ef4" - integrity sha512-UfoeMA6fIJ8wTYFEUjelnaGI67v6+N7qXJEvQuIGa99l4xsCruSYOVSQ0uPANn4dAzm8lkYPaKLrrijLq7x23w== - dependencies: - hasown "^2.0.2" - -is-fullwidth-code-point@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz#f116f8064fe90b3f7844a38997c0b75051269f1d" - integrity sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg== - -is-generator-fn@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/is-generator-fn/-/is-generator-fn-2.1.0.tgz#7d140adc389aaf3011a8f2a2a4cfa6faadffb118" - integrity sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ== - -is-number@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/is-number/-/is-number-7.0.0.tgz#7535345b896734d5f80c4d06c50955527a14f12b" - integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== - -is-potential-custom-element-name@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz#171ed6f19e3ac554394edf78caa05784a45bebb5" - integrity sha512-bCYeRA2rVibKZd+s2625gGnGF/t7DSqDs4dP7CrLA1m7jKWz6pps0LpYLJN8Q64HtmPKJ1hrN3nzPNKFEKOUiQ== - -is-stream@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.1.tgz#fac1e3d53b97ad5a9d0ae9cef2389f5810a5c077" - integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== - -isexe@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" - integrity sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw== - -istanbul-lib-coverage@^3.0.0, istanbul-lib-coverage@^3.2.0: - version "3.2.2" - resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.2.tgz#2d166c4b0644d43a39f04bf6c2edd1e585f31756" - integrity sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg== - -istanbul-lib-instrument@^5.0.4: - version "5.2.1" - resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-5.2.1.tgz#d10c8885c2125574e1c231cacadf955675e1ce3d" - integrity sha512-pzqtp31nLv/XFOzXGuvhCb8qhjmTVo5vjVk19XE4CRlSWz0KoeJ3bw9XsA7nOp9YBf4qHjwBxkDzKcME/J29Yg== - dependencies: - "@babel/core" "^7.12.3" - "@babel/parser" "^7.14.7" - "@istanbuljs/schema" "^0.1.2" - istanbul-lib-coverage "^3.2.0" - semver "^6.3.0" - -istanbul-lib-instrument@^6.0.0: - version "6.0.3" - resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-6.0.3.tgz#fa15401df6c15874bcb2105f773325d78c666765" - integrity sha512-Vtgk7L/R2JHyyGW07spoFlB8/lpjiOLTjMdms6AFMraYt3BaJauod/NGrfnVG/y4Ix1JEuMRPDPEj2ua+zz1/Q== - dependencies: - "@babel/core" "^7.23.9" - "@babel/parser" "^7.23.9" - "@istanbuljs/schema" "^0.1.3" - istanbul-lib-coverage "^3.2.0" - semver "^7.5.4" - -istanbul-lib-report@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/istanbul-lib-report/-/istanbul-lib-report-3.0.1.tgz#908305bac9a5bd175ac6a74489eafd0fc2445a7d" - integrity sha512-GCfE1mtsHGOELCU8e/Z7YWzpmybrx/+dSTfLrvY8qRmaY6zXTKWn6WQIjaAFw069icm6GVMNkgu0NzI4iPZUNw== - dependencies: - istanbul-lib-coverage "^3.0.0" - make-dir "^4.0.0" - supports-color "^7.1.0" - -istanbul-lib-source-maps@^4.0.0: - version "4.0.1" - resolved "https://registry.yarnpkg.com/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.1.tgz#895f3a709fcfba34c6de5a42939022f3e4358551" - integrity sha512-n3s8EwkdFIJCG3BPKBYvskgXGoy88ARzvegkitk60NxRdwltLOTaH7CUiMRXvwYorl0Q712iEjcWB+fK/MrWVw== - dependencies: - debug "^4.1.1" - istanbul-lib-coverage "^3.0.0" - source-map "^0.6.1" - -istanbul-reports@^3.1.3: - version "3.1.7" - resolved "https://registry.yarnpkg.com/istanbul-reports/-/istanbul-reports-3.1.7.tgz#daed12b9e1dca518e15c056e1e537e741280fa0b" - integrity sha512-BewmUXImeuRk2YY0PVbxgKAysvhRPUQE0h5QRM++nVWyubKGV0l8qQ5op8+B2DOmwSe63Jivj0BjkPQVf8fP5g== - dependencies: - html-escaper "^2.0.0" - istanbul-lib-report "^3.0.0" - -jake@^10.8.5: - version "10.9.2" - resolved "https://registry.yarnpkg.com/jake/-/jake-10.9.2.tgz#6ae487e6a69afec3a5e167628996b59f35ae2b7f" - integrity sha512-2P4SQ0HrLQ+fw6llpLnOaGAvN2Zu6778SJMrCUwns4fOoG9ayrTiZk3VV8sCPkVZF8ab0zksVpS8FDY5pRCNBA== - dependencies: - async "^3.2.3" - chalk "^4.0.2" - filelist "^1.0.4" - minimatch "^3.1.2" - -jest-changed-files@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-29.7.0.tgz#1c06d07e77c78e1585d020424dedc10d6e17ac3a" - integrity sha512-fEArFiwf1BpQ+4bXSprcDc3/x4HSzL4al2tozwVpDFpsxALjLYdyiIK4e5Vz66GQJIbXJ82+35PtysofptNX2w== - dependencies: - execa "^5.0.0" - jest-util "^29.7.0" - p-limit "^3.1.0" - -jest-circus@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-circus/-/jest-circus-29.7.0.tgz#b6817a45fcc835d8b16d5962d0c026473ee3668a" - integrity sha512-3E1nCMgipcTkCocFwM90XXQab9bS+GMsjdpmPrlelaxwD93Ad8iVEjX/vvHPdLPnFf+L40u+5+iutRdA1N9myw== - dependencies: - "@jest/environment" "^29.7.0" - "@jest/expect" "^29.7.0" - "@jest/test-result" "^29.7.0" - "@jest/types" "^29.6.3" - "@types/node" "*" - chalk "^4.0.0" - co "^4.6.0" - dedent "^1.0.0" - is-generator-fn "^2.0.0" - jest-each "^29.7.0" - jest-matcher-utils "^29.7.0" - jest-message-util "^29.7.0" - jest-runtime "^29.7.0" - jest-snapshot "^29.7.0" - jest-util "^29.7.0" - p-limit "^3.1.0" - pretty-format "^29.7.0" - pure-rand "^6.0.0" - slash "^3.0.0" - stack-utils "^2.0.3" - -jest-cli@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-29.7.0.tgz#5592c940798e0cae677eec169264f2d839a37995" - integrity sha512-OVVobw2IubN/GSYsxETi+gOe7Ka59EFMR/twOU3Jb2GnKKeMGJB5SGUUrEz3SFVmJASUdZUzy83sLNNQ2gZslg== - dependencies: - "@jest/core" "^29.7.0" - "@jest/test-result" "^29.7.0" - "@jest/types" "^29.6.3" - chalk "^4.0.0" - create-jest "^29.7.0" - exit "^0.1.2" - import-local "^3.0.2" - jest-config "^29.7.0" - jest-util "^29.7.0" - jest-validate "^29.7.0" - yargs "^17.3.1" - -jest-config@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-29.7.0.tgz#bcbda8806dbcc01b1e316a46bb74085a84b0245f" - integrity sha512-uXbpfeQ7R6TZBqI3/TxCU4q4ttk3u0PJeC+E0zbfSoSjq6bJ7buBPxzQPL0ifrkY4DNu4JUdk0ImlBUYi840eQ== - dependencies: - "@babel/core" "^7.11.6" - "@jest/test-sequencer" "^29.7.0" - "@jest/types" "^29.6.3" - babel-jest "^29.7.0" - chalk "^4.0.0" - ci-info "^3.2.0" - deepmerge "^4.2.2" - glob "^7.1.3" - graceful-fs "^4.2.9" - jest-circus "^29.7.0" - jest-environment-node "^29.7.0" - jest-get-type "^29.6.3" - jest-regex-util "^29.6.3" - jest-resolve "^29.7.0" - jest-runner "^29.7.0" - jest-util "^29.7.0" - jest-validate "^29.7.0" - micromatch "^4.0.4" - parse-json "^5.2.0" - pretty-format "^29.7.0" - slash "^3.0.0" - strip-json-comments "^3.1.1" - -jest-diff@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-29.7.0.tgz#017934a66ebb7ecf6f205e84699be10afd70458a" - integrity sha512-LMIgiIrhigmPrs03JHpxUh2yISK3vLFPkAodPeo0+BuF7wA2FoQbkEg1u8gBYBThncu7e1oEDUfIXVuTqLRUjw== - dependencies: - chalk "^4.0.0" - diff-sequences "^29.6.3" - jest-get-type "^29.6.3" - pretty-format "^29.7.0" - -jest-docblock@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-29.7.0.tgz#8fddb6adc3cdc955c93e2a87f61cfd350d5d119a" - integrity sha512-q617Auw3A612guyaFgsbFeYpNP5t2aoUNLwBUbc/0kD1R4t9ixDbyFTHd1nok4epoVFpr7PmeWHrhvuV3XaJ4g== - dependencies: - detect-newline "^3.0.0" - -jest-each@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-29.7.0.tgz#162a9b3f2328bdd991beaabffbb74745e56577d1" - integrity sha512-gns+Er14+ZrEoC5fhOfYCY1LOHHr0TI+rQUHZS8Ttw2l7gl+80eHc/gFf2Ktkw0+SIACDTeWvpFcv3B04VembQ== - dependencies: - "@jest/types" "^29.6.3" - chalk "^4.0.0" - jest-get-type "^29.6.3" - jest-util "^29.7.0" - pretty-format "^29.7.0" - -jest-environment-jsdom@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-29.7.0.tgz#d206fa3551933c3fd519e5dfdb58a0f5139a837f" - integrity sha512-k9iQbsf9OyOfdzWH8HDmrRT0gSIcX+FLNW7IQq94tFX0gynPwqDTW0Ho6iMVNjGz/nb+l/vW3dWM2bbLLpkbXA== - dependencies: - "@jest/environment" "^29.7.0" - "@jest/fake-timers" "^29.7.0" - "@jest/types" "^29.6.3" - "@types/jsdom" "^20.0.0" - "@types/node" "*" - jest-mock "^29.7.0" - jest-util "^29.7.0" - jsdom "^20.0.0" - -jest-environment-node@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-29.7.0.tgz#0b93e111dda8ec120bc8300e6d1fb9576e164376" - integrity sha512-DOSwCRqXirTOyheM+4d5YZOrWcdu0LNZ87ewUoywbcb2XR4wKgqiG8vNeYwhjFMbEkfju7wx2GYH0P2gevGvFw== - dependencies: - "@jest/environment" "^29.7.0" - "@jest/fake-timers" "^29.7.0" - "@jest/types" "^29.6.3" - "@types/node" "*" - jest-mock "^29.7.0" - jest-util "^29.7.0" - -jest-get-type@^29.6.3: - version "29.6.3" - resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-29.6.3.tgz#36f499fdcea197c1045a127319c0481723908fd1" - integrity sha512-zrteXnqYxfQh7l5FHyL38jL39di8H8rHoecLH3JNxH3BwOrBsNeabdap5e0I23lD4HHI8W5VFBZqG4Eaq5LNcw== - -jest-haste-map@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-29.7.0.tgz#3c2396524482f5a0506376e6c858c3bbcc17b104" - integrity sha512-fP8u2pyfqx0K1rGn1R9pyE0/KTn+G7PxktWidOBTqFPLYX0b9ksaMFkhK5vrS3DVun09pckLdlx90QthlW7AmA== - dependencies: - "@jest/types" "^29.6.3" - "@types/graceful-fs" "^4.1.3" - "@types/node" "*" - anymatch "^3.0.3" - fb-watchman "^2.0.0" - graceful-fs "^4.2.9" - jest-regex-util "^29.6.3" - jest-util "^29.7.0" - jest-worker "^29.7.0" - micromatch "^4.0.4" - walker "^1.0.8" - optionalDependencies: - fsevents "^2.3.2" - -jest-leak-detector@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-29.7.0.tgz#5b7ec0dadfdfec0ca383dc9aa016d36b5ea4c728" - integrity sha512-kYA8IJcSYtST2BY9I+SMC32nDpBT3J2NvWJx8+JCuCdl/CR1I4EKUJROiP8XtCcxqgTTBGJNdbB1A8XRKbTetw== - dependencies: - jest-get-type "^29.6.3" - pretty-format "^29.7.0" - -jest-matcher-utils@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-29.7.0.tgz#ae8fec79ff249fd592ce80e3ee474e83a6c44f12" - integrity sha512-sBkD+Xi9DtcChsI3L3u0+N0opgPYnCRPtGcQYrgXmR+hmt/fYfWAL0xRXYU8eWOdfuLgBe0YCW3AFtnRLagq/g== - dependencies: - chalk "^4.0.0" - jest-diff "^29.7.0" - jest-get-type "^29.6.3" - pretty-format "^29.7.0" - -jest-message-util@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-29.7.0.tgz#8bc392e204e95dfe7564abbe72a404e28e51f7f3" - integrity sha512-GBEV4GRADeP+qtB2+6u61stea8mGcOT4mCtrYISZwfu9/ISHFJ/5zOMXYbpBE9RsS5+Gb63DW4FgmnKJ79Kf6w== - dependencies: - "@babel/code-frame" "^7.12.13" - "@jest/types" "^29.6.3" - "@types/stack-utils" "^2.0.0" - chalk "^4.0.0" - graceful-fs "^4.2.9" - micromatch "^4.0.4" - pretty-format "^29.7.0" - slash "^3.0.0" - stack-utils "^2.0.3" - -jest-mock@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-29.7.0.tgz#4e836cf60e99c6fcfabe9f99d017f3fdd50a6347" - integrity sha512-ITOMZn+UkYS4ZFh83xYAOzWStloNzJFO2s8DWrE4lhtGD+AorgnbkiKERe4wQVBydIGPx059g6riW5Btp6Llnw== - dependencies: - "@jest/types" "^29.6.3" - "@types/node" "*" - jest-util "^29.7.0" - -jest-pnp-resolver@^1.2.2: - version "1.2.3" - resolved "https://registry.yarnpkg.com/jest-pnp-resolver/-/jest-pnp-resolver-1.2.3.tgz#930b1546164d4ad5937d5540e711d4d38d4cad2e" - integrity sha512-+3NpwQEnRoIBtx4fyhblQDPgJI0H1IEIkX7ShLUjPGA7TtUTvI1oiKi3SR4oBR0hQhQR80l4WAe5RrXBwWMA8w== - -jest-regex-util@^29.6.3: - version "29.6.3" - resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-29.6.3.tgz#4a556d9c776af68e1c5f48194f4d0327d24e8a52" - integrity sha512-KJJBsRCyyLNWCNBOvZyRDnAIfUiRJ8v+hOBQYGn8gDyF3UegwiP4gwRR3/SDa42g1YbVycTidUF3rKjyLFDWbg== - -jest-resolve-dependencies@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-29.7.0.tgz#1b04f2c095f37fc776ff40803dc92921b1e88428" - integrity sha512-un0zD/6qxJ+S0et7WxeI3H5XSe9lTBBR7bOHCHXkKR6luG5mwDDlIzVQ0V5cZCuoTgEdcdwzTghYkTWfubi+nA== - dependencies: - jest-regex-util "^29.6.3" - jest-snapshot "^29.7.0" - -jest-resolve@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-29.7.0.tgz#64d6a8992dd26f635ab0c01e5eef4399c6bcbc30" - integrity sha512-IOVhZSrg+UvVAshDSDtHyFCCBUl/Q3AAJv8iZ6ZjnZ74xzvwuzLXid9IIIPgTnY62SJjfuupMKZsZQRsCvxEgA== - dependencies: - chalk "^4.0.0" - graceful-fs "^4.2.9" - jest-haste-map "^29.7.0" - jest-pnp-resolver "^1.2.2" - jest-util "^29.7.0" - jest-validate "^29.7.0" - resolve "^1.20.0" - resolve.exports "^2.0.0" - slash "^3.0.0" - -jest-runner@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-29.7.0.tgz#809af072d408a53dcfd2e849a4c976d3132f718e" - integrity sha512-fsc4N6cPCAahybGBfTRcq5wFR6fpLznMg47sY5aDpsoejOcVYFb07AHuSnR0liMcPTgBsA3ZJL6kFOjPdoNipQ== - dependencies: - "@jest/console" "^29.7.0" - "@jest/environment" "^29.7.0" - "@jest/test-result" "^29.7.0" - "@jest/transform" "^29.7.0" - "@jest/types" "^29.6.3" - "@types/node" "*" - chalk "^4.0.0" - emittery "^0.13.1" - graceful-fs "^4.2.9" - jest-docblock "^29.7.0" - jest-environment-node "^29.7.0" - jest-haste-map "^29.7.0" - jest-leak-detector "^29.7.0" - jest-message-util "^29.7.0" - jest-resolve "^29.7.0" - jest-runtime "^29.7.0" - jest-util "^29.7.0" - jest-watcher "^29.7.0" - jest-worker "^29.7.0" - p-limit "^3.1.0" - source-map-support "0.5.13" - -jest-runtime@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-29.7.0.tgz#efecb3141cf7d3767a3a0cc8f7c9990587d3d817" - integrity sha512-gUnLjgwdGqW7B4LvOIkbKs9WGbn+QLqRQQ9juC6HndeDiezIwhDP+mhMwHWCEcfQ5RUXa6OPnFF8BJh5xegwwQ== - dependencies: - "@jest/environment" "^29.7.0" - "@jest/fake-timers" "^29.7.0" - "@jest/globals" "^29.7.0" - "@jest/source-map" "^29.6.3" - "@jest/test-result" "^29.7.0" - "@jest/transform" "^29.7.0" - "@jest/types" "^29.6.3" - "@types/node" "*" - chalk "^4.0.0" - cjs-module-lexer "^1.0.0" - collect-v8-coverage "^1.0.0" - glob "^7.1.3" - graceful-fs "^4.2.9" - jest-haste-map "^29.7.0" - jest-message-util "^29.7.0" - jest-mock "^29.7.0" - jest-regex-util "^29.6.3" - jest-resolve "^29.7.0" - jest-snapshot "^29.7.0" - jest-util "^29.7.0" - slash "^3.0.0" - strip-bom "^4.0.0" - -jest-snapshot@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-29.7.0.tgz#c2c574c3f51865da1bb329036778a69bf88a6be5" - integrity sha512-Rm0BMWtxBcioHr1/OX5YCP8Uov4riHvKPknOGs804Zg9JGZgmIBkbtlxJC/7Z4msKYVbIJtfU+tKb8xlYNfdkw== - dependencies: - "@babel/core" "^7.11.6" - "@babel/generator" "^7.7.2" - "@babel/plugin-syntax-jsx" "^7.7.2" - "@babel/plugin-syntax-typescript" "^7.7.2" - "@babel/types" "^7.3.3" - "@jest/expect-utils" "^29.7.0" - "@jest/transform" "^29.7.0" - "@jest/types" "^29.6.3" - babel-preset-current-node-syntax "^1.0.0" - chalk "^4.0.0" - expect "^29.7.0" - graceful-fs "^4.2.9" - jest-diff "^29.7.0" - jest-get-type "^29.6.3" - jest-matcher-utils "^29.7.0" - jest-message-util "^29.7.0" - jest-util "^29.7.0" - natural-compare "^1.4.0" - pretty-format "^29.7.0" - semver "^7.5.3" - -jest-util@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-29.7.0.tgz#23c2b62bfb22be82b44de98055802ff3710fc0bc" - integrity sha512-z6EbKajIpqGKU56y5KBUgy1dt1ihhQJgWzUlZHArA/+X2ad7Cb5iF+AK1EWVL/Bo7Rz9uurpqw6SiBCefUbCGA== - dependencies: - "@jest/types" "^29.6.3" - "@types/node" "*" - chalk "^4.0.0" - ci-info "^3.2.0" - graceful-fs "^4.2.9" - picomatch "^2.2.3" - -jest-validate@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-29.7.0.tgz#7bf705511c64da591d46b15fce41400d52147d9c" - integrity sha512-ZB7wHqaRGVw/9hST/OuFUReG7M8vKeq0/J2egIGLdvjHCmYqGARhzXmtgi+gVeZ5uXFF219aOc3Ls2yLg27tkw== - dependencies: - "@jest/types" "^29.6.3" - camelcase "^6.2.0" - chalk "^4.0.0" - jest-get-type "^29.6.3" - leven "^3.1.0" - pretty-format "^29.7.0" - -jest-watcher@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-watcher/-/jest-watcher-29.7.0.tgz#7810d30d619c3a62093223ce6bb359ca1b28a2f2" - integrity sha512-49Fg7WXkU3Vl2h6LbLtMQ/HyB6rXSIX7SqvBLQmssRBGN9I0PNvPmAmCWSOY6SOvrjhI/F7/bGAv9RtnsPA03g== - dependencies: - "@jest/test-result" "^29.7.0" - "@jest/types" "^29.6.3" - "@types/node" "*" - ansi-escapes "^4.2.1" - chalk "^4.0.0" - emittery "^0.13.1" - jest-util "^29.7.0" - string-length "^4.0.1" - -jest-worker@^27.4.5: - version "27.5.1" - resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-27.5.1.tgz#8d146f0900e8973b106b6f73cc1e9a8cb86f8db0" - integrity sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg== - dependencies: - "@types/node" "*" - merge-stream "^2.0.0" - supports-color "^8.0.0" - -jest-worker@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-29.7.0.tgz#acad073acbbaeb7262bd5389e1bcf43e10058d4a" - integrity sha512-eIz2msL/EzL9UFTFFx7jBTkeZfku0yUAyZZZmJ93H2TYEiroIx2PQjEXcwYtYl8zXCxb+PAmA2hLIt/6ZEkPHw== - dependencies: - "@types/node" "*" - jest-util "^29.7.0" - merge-stream "^2.0.0" - supports-color "^8.0.0" - -jest@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/jest/-/jest-29.7.0.tgz#994676fc24177f088f1c5e3737f5697204ff2613" - integrity sha512-NIy3oAFp9shda19hy4HK0HRTWKtPJmGdnvywu01nOqNC2vZg+Z+fvJDxpMQA88eb2I9EcafcdjYgsDthnYTvGw== - dependencies: - "@jest/core" "^29.7.0" - "@jest/types" "^29.6.3" - import-local "^3.0.2" - jest-cli "^29.7.0" - -js-base64@3.7.7: - version "3.7.7" - resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-3.7.7.tgz#e51b84bf78fbf5702b9541e2cb7bfcb893b43e79" - integrity sha512-7rCnleh0z2CkXhH67J8K1Ytz0b2Y+yxTPL+/KOJoa20hfnVQ/3/T6W/KflYI4bRHRagNeXeU2bkNGI3v1oS/lw== - -js-tokens@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" - integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== - -js-yaml@^3.13.1: - version "3.14.2" - resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.14.2.tgz#77485ce1dd7f33c061fd1b16ecea23b55fcb04b0" - integrity sha512-PMSmkqxr106Xa156c2M265Z+FTrPl+oxd/rgOQy2tijQeK5TxQ43psO1ZCwhVOSdnn+RzkzlRz/eY4BgJBYVpg== - dependencies: - argparse "^1.0.7" - esprima "^4.0.0" - -jsdom@^20.0.0: - version "20.0.3" - resolved "https://registry.yarnpkg.com/jsdom/-/jsdom-20.0.3.tgz#886a41ba1d4726f67a8858028c99489fed6ad4db" - integrity sha512-SYhBvTh89tTfCD/CRdSOm13mOBa42iTaTyfyEWBdKcGdPxPtLFBXuHR8XHb33YNYaP+lLbmSvBTsnoesCNJEsQ== - dependencies: - abab "^2.0.6" - acorn "^8.8.1" - acorn-globals "^7.0.0" - cssom "^0.5.0" - cssstyle "^2.3.0" - data-urls "^3.0.2" - decimal.js "^10.4.2" - domexception "^4.0.0" - escodegen "^2.0.0" - form-data "^4.0.0" - html-encoding-sniffer "^3.0.0" - http-proxy-agent "^5.0.0" - https-proxy-agent "^5.0.1" - is-potential-custom-element-name "^1.0.1" - nwsapi "^2.2.2" - parse5 "^7.1.1" - saxes "^6.0.0" - symbol-tree "^3.2.4" - tough-cookie "^4.1.2" - w3c-xmlserializer "^4.0.0" - webidl-conversions "^7.0.0" - whatwg-encoding "^2.0.0" - whatwg-mimetype "^3.0.0" - whatwg-url "^11.0.0" - ws "^8.11.0" - xml-name-validator "^4.0.0" - -jsesc@^3.0.2: - version "3.1.0" - resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-3.1.0.tgz#74d335a234f67ed19907fdadfac7ccf9d409825d" - integrity sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA== - -json-parse-even-better-errors@^2.3.0, json-parse-even-better-errors@^2.3.1: - version "2.3.1" - resolved "https://registry.yarnpkg.com/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz#7c47805a94319928e05777405dc12e1f7a4ee02d" - integrity sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w== - -json-schema-traverse@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz#ae7bcb3656ab77a73ba5c49bf654f38e6b6860e2" - integrity sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug== - -json5@^2.2.3: - version "2.2.3" - resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.3.tgz#78cd6f1a19bdc12b73db5ad0c61efd66c1e29283" - integrity sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg== - -kleur@^3.0.3: - version "3.0.3" - resolved "https://registry.yarnpkg.com/kleur/-/kleur-3.0.3.tgz#a79c9ecc86ee1ce3fa6206d1216c501f147fc07e" - integrity sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w== - -leven@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/leven/-/leven-3.1.0.tgz#77891de834064cccba82ae7842bb6b14a13ed7f2" - integrity sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A== - -lines-and-columns@^1.1.6: - version "1.2.4" - resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.2.4.tgz#eca284f75d2965079309dc0ad9255abb2ebc1632" - integrity sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg== - -loader-runner@^4.2.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/loader-runner/-/loader-runner-4.3.0.tgz#c1b4a163b99f614830353b16755e7149ac2314e1" - integrity sha512-3R/1M+yS3j5ou80Me59j7F9IMs4PXs3VqRrm0TU3AbKPxlmpoY1TNscJV/oGJXo8qCatFGTfDbY6W6ipGOYXfg== - -locate-path@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-5.0.0.tgz#1afba396afd676a6d42504d0a67a3a7eb9f62aa0" - integrity sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g== - dependencies: - p-locate "^4.1.0" - -lodash.memoize@^4.1.2: - version "4.1.2" - resolved "https://registry.yarnpkg.com/lodash.memoize/-/lodash.memoize-4.1.2.tgz#bcc6c49a42a2840ed997f323eada5ecd182e0bfe" - integrity sha512-t7j+NzmgnQzTAYXcsHYLgimltOV1MXHtlOWf6GjL9Kj8GK5FInw5JotxvbOs+IvV1/Dzo04/fCGfLVs7aXb4Ag== - -lru-cache@^5.1.1: - version "5.1.1" - resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-5.1.1.tgz#1da27e6710271947695daf6848e847f01d84b920" - integrity sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w== - dependencies: - yallist "^3.0.2" - -make-dir@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-4.0.0.tgz#c3c2307a771277cd9638305f915c29ae741b614e" - integrity sha512-hXdUTZYIVOt1Ex//jAQi+wTZZpUpwBj/0QsOzqegb3rGMMeJiSEu5xLHnYfBrRV4RH2+OCSOO95Is/7x1WJ4bw== - dependencies: - semver "^7.5.3" - -make-error@^1.3.6: - version "1.3.6" - resolved "https://registry.yarnpkg.com/make-error/-/make-error-1.3.6.tgz#2eb2e37ea9b67c4891f684a1394799af484cf7a2" - integrity sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw== - -makeerror@1.0.12: - version "1.0.12" - resolved "https://registry.yarnpkg.com/makeerror/-/makeerror-1.0.12.tgz#3e5dd2079a82e812e983cc6610c4a2cb0eaa801a" - integrity sha512-JmqCvUhmt43madlpFzG4BQzG2Z3m6tvQDNKdClZnO3VbIudJYmxsT0FNJMeiB2+JTSlTQTSbU8QdesVmwJcmLg== - dependencies: - tmpl "1.0.5" - -math-intrinsics@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/math-intrinsics/-/math-intrinsics-1.1.0.tgz#a0dd74be81e2aa5c2f27e65ce283605ee4e2b7f9" - integrity sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g== - -merge-stream@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-2.0.0.tgz#52823629a14dd00c9770fb6ad47dc6310f2c1f60" - integrity sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w== - -micromatch@^4.0.0, micromatch@^4.0.4: - version "4.0.8" - resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.8.tgz#d66fa18f3a47076789320b9b1af32bd86d9fa202" - integrity sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA== - dependencies: - braces "^3.0.3" - picomatch "^2.3.1" - -mime-db@1.52.0: - version "1.52.0" - resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.52.0.tgz#bbabcdc02859f4987301c856e3387ce5ec43bf70" - integrity sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg== - -mime-types@^2.1.12, mime-types@^2.1.27: - version "2.1.35" - resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.35.tgz#381a871b62a734450660ae3deee44813f70d959a" - integrity sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw== - dependencies: - mime-db "1.52.0" - -mimic-fn@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-2.1.0.tgz#7ed2c2ccccaf84d3ffcb7a69b57711fc2083401b" - integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== - -minimatch@^3.0.4, minimatch@^3.1.1, minimatch@^3.1.2: - version "3.1.2" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b" - integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== - dependencies: - brace-expansion "^1.1.7" - -minimatch@^5.0.1: - version "5.1.6" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-5.1.6.tgz#1cfcb8cf5522ea69952cd2af95ae09477f122a96" - integrity sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g== - dependencies: - brace-expansion "^2.0.1" - -ms@^2.1.3: - version "2.1.3" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" - integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== - -natural-compare@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" - integrity sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw== - -neo-async@^2.6.2: - version "2.6.2" - resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.2.tgz#b4aafb93e3aeb2d8174ca53cf163ab7d7308305f" - integrity sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw== - -node-fetch@^2.7.0: - version "2.7.0" - resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.7.0.tgz#d0f0fa6e3e2dc1d27efcd8ad99d550bda94d187d" - integrity sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A== - dependencies: - whatwg-url "^5.0.0" - -node-int64@^0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/node-int64/-/node-int64-0.4.0.tgz#87a9065cdb355d3182d8f94ce11188b825c68a3b" - integrity sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw== - -node-releases@^2.0.19: - version "2.0.19" - resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-2.0.19.tgz#9e445a52950951ec4d177d843af370b411caf314" - integrity sha512-xxOWJsBKtzAq7DY0J+DTzuz58K8e7sJbdgwkbMWQe8UYB6ekmsQ45q0M/tJDsGaZmbC+l7n57UV8Hl5tHxO9uw== - -normalize-path@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" - integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== - -npm-run-path@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-4.0.1.tgz#b7ecd1e5ed53da8e37a55e1c2269e0b97ed748ea" - integrity sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw== - dependencies: - path-key "^3.0.0" - -nwsapi@^2.2.2: - version "2.2.20" - resolved "https://registry.yarnpkg.com/nwsapi/-/nwsapi-2.2.20.tgz#22e53253c61e7b0e7e93cef42c891154bcca11ef" - integrity sha512-/ieB+mDe4MrrKMT8z+mQL8klXydZWGR5Dowt4RAGKbJ3kIGEx3X4ljUo+6V73IXtUPWgfOlU5B9MlGxFO5T+cA== - -object-inspect@^1.13.3: - version "1.13.4" - resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.13.4.tgz#8375265e21bc20d0fa582c22e1b13485d6e00213" - integrity sha512-W67iLl4J2EXEGTbfeHCffrjDfitvLANg0UlX3wFUUSTx92KXRFegMHUVgSqE+wvhAbi4WqjGg9czysTV2Epbew== - -once@^1.3.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" - integrity sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w== - dependencies: - wrappy "1" - -onetime@^5.1.2: - version "5.1.2" - resolved "https://registry.yarnpkg.com/onetime/-/onetime-5.1.2.tgz#d0e96ebb56b07476df1dd9c4806e5237985ca45e" - integrity sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg== - dependencies: - mimic-fn "^2.1.0" - -p-limit@^2.2.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-2.3.0.tgz#3dd33c647a214fdfffd835933eb086da0dc21db1" - integrity sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w== - dependencies: - p-try "^2.0.0" - -p-limit@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-3.1.0.tgz#e1daccbe78d0d1388ca18c64fea38e3e57e3706b" - integrity sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ== - dependencies: - yocto-queue "^0.1.0" - -p-locate@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-4.1.0.tgz#a3428bb7088b3a60292f66919278b7c297ad4f07" - integrity sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A== - dependencies: - p-limit "^2.2.0" - -p-try@^2.0.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/p-try/-/p-try-2.2.0.tgz#cb2868540e313d61de58fafbe35ce9004d5540e6" - integrity sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ== - -parse-json@^5.2.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-5.2.0.tgz#c76fc66dee54231c962b22bcc8a72cf2f99753cd" - integrity sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg== - dependencies: - "@babel/code-frame" "^7.0.0" - error-ex "^1.3.1" - json-parse-even-better-errors "^2.3.0" - lines-and-columns "^1.1.6" - -parse5@^7.0.0, parse5@^7.1.1: - version "7.3.0" - resolved "https://registry.yarnpkg.com/parse5/-/parse5-7.3.0.tgz#d7e224fa72399c7a175099f45fc2ad024b05ec05" - integrity sha512-IInvU7fabl34qmi9gY8XOVxhYyMyuH2xUNpb2q8/Y+7552KlejkRvqvD19nMoUW/uQGGbqNpA6Tufu5FL5BZgw== - dependencies: - entities "^6.0.0" - -path-exists@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-4.0.0.tgz#513bdbe2d3b95d7762e8c1137efa195c6c61b5b3" - integrity sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w== - -path-is-absolute@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" - integrity sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg== - -path-key@^3.0.0, path-key@^3.1.0: - version "3.1.1" - resolved "https://registry.yarnpkg.com/path-key/-/path-key-3.1.1.tgz#581f6ade658cbba65a0d3380de7753295054f375" - integrity sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q== - -path-parse@^1.0.7: - version "1.0.7" - resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" - integrity sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw== - -picocolors@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.1.1.tgz#3d321af3eab939b083c8f929a1d12cda81c26b6b" - integrity sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA== - -picomatch@^2.0.4, picomatch@^2.2.3, picomatch@^2.3.1: - version "2.3.1" - resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" - integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== - -pirates@^4.0.4: - version "4.0.7" - resolved "https://registry.yarnpkg.com/pirates/-/pirates-4.0.7.tgz#643b4a18c4257c8a65104b73f3049ce9a0a15e22" - integrity sha512-TfySrs/5nm8fQJDcBDuUng3VOUKsd7S+zqvbOTiGXHfxX4wK31ard+hoNuvkicM/2YFzlpDgABOevKSsB4G/FA== - -pkg-dir@^4.2.0: - version "4.2.0" - resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-4.2.0.tgz#f099133df7ede422e81d1d8448270eeb3e4261f3" - integrity sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ== - dependencies: - find-up "^4.0.0" - -prettier@^3.4.2: - version "3.6.1" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-3.6.1.tgz#cc3bce21c09a477b1e987b76ce9663925d86ae44" - integrity sha512-5xGWRa90Sp2+x1dQtNpIpeOQpTDBs9cZDmA/qs2vDNN2i18PdapqY7CmBeyLlMuGqXJRIOPaCaVZTLNQRWUH/A== - -pretty-format@^29.0.0, pretty-format@^29.7.0: - version "29.7.0" - resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-29.7.0.tgz#ca42c758310f365bfa71a0bda0a807160b776812" - integrity sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ== - dependencies: - "@jest/schemas" "^29.6.3" - ansi-styles "^5.0.0" - react-is "^18.0.0" - -process@^0.11.10: - version "0.11.10" - resolved "https://registry.yarnpkg.com/process/-/process-0.11.10.tgz#7332300e840161bda3e69a1d1d91a7d4bc16f182" - integrity sha512-cdGef/drWFoydD1JsMzuFf8100nZl+GT+yacc2bEced5f9Rjk4z+WtFUTBu9PhOi9j/jfmBPu0mMEY4wIdAF8A== - -prompts@^2.0.1: - version "2.4.2" - resolved "https://registry.yarnpkg.com/prompts/-/prompts-2.4.2.tgz#7b57e73b3a48029ad10ebd44f74b01722a4cb069" - integrity sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q== - dependencies: - kleur "^3.0.3" - sisteransi "^1.0.5" - -psl@^1.1.33: - version "1.15.0" - resolved "https://registry.yarnpkg.com/psl/-/psl-1.15.0.tgz#bdace31896f1d97cec6a79e8224898ce93d974c6" - integrity sha512-JZd3gMVBAVQkSs6HdNZo9Sdo0LNcQeMNP3CozBJb3JYC/QUYZTnKxP+f8oWRX4rHP5EurWxqAHTSwUCjlNKa1w== - dependencies: - punycode "^2.3.1" - -punycode@^2.1.1, punycode@^2.3.1: - version "2.3.1" - resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.3.1.tgz#027422e2faec0b25e1549c3e1bd8309b9133b6e5" - integrity sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg== - -pure-rand@^6.0.0: - version "6.1.0" - resolved "https://registry.yarnpkg.com/pure-rand/-/pure-rand-6.1.0.tgz#d173cf23258231976ccbdb05247c9787957604f2" - integrity sha512-bVWawvoZoBYpp6yIoQtQXHZjmz35RSVHnUOTefl8Vcjr8snTPY1wnpSPMWekcFwbxI6gtmT7rSYPFvz71ldiOA== - -qs@^6.13.1: - version "6.14.0" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.14.0.tgz#c63fa40680d2c5c941412a0e899c89af60c0a930" - integrity sha512-YWWTjgABSKcvs/nWBi9PycY/JiPJqOD4JA6o9Sej2AtvSGarXxKC3OQSk4pAarbdQlKAh5D4FCQkJNkW+GAn3w== - dependencies: - side-channel "^1.1.0" - -querystringify@^2.1.1: - version "2.2.0" - resolved "https://registry.yarnpkg.com/querystringify/-/querystringify-2.2.0.tgz#3345941b4153cb9d082d8eee4cda2016a9aef7f6" - integrity sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ== - -randombytes@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/randombytes/-/randombytes-2.1.0.tgz#df6f84372f0270dc65cdf6291349ab7a473d4f2a" - integrity sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ== - dependencies: - safe-buffer "^5.1.0" - -react-is@^18.0.0: - version "18.3.1" - resolved "https://registry.yarnpkg.com/react-is/-/react-is-18.3.1.tgz#e83557dc12eae63a99e003a46388b1dcbb44db7e" - integrity sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg== - -readable-stream@^4.5.2: - version "4.7.0" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-4.7.0.tgz#cedbd8a1146c13dfff8dab14068028d58c15ac91" - integrity sha512-oIGGmcpTLwPga8Bn6/Z75SVaH1z5dUut2ibSyAMVhmUggWpmDn2dapB0n7f8nwaSiRtepAsfJyfXIO5DCVAODg== - dependencies: - abort-controller "^3.0.0" - buffer "^6.0.3" - events "^3.3.0" - process "^0.11.10" - string_decoder "^1.3.0" - -require-directory@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" - integrity sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q== - -require-from-string@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/require-from-string/-/require-from-string-2.0.2.tgz#89a7fdd938261267318eafe14f9c32e598c36909" - integrity sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw== - -requires-port@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff" - integrity sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ== - -resolve-cwd@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/resolve-cwd/-/resolve-cwd-3.0.0.tgz#0f0075f1bb2544766cf73ba6a6e2adfebcb13f2d" - integrity sha512-OrZaX2Mb+rJCpH/6CpSqt9xFVpN++x01XnN2ie9g6P5/3xelLAkXWVADpdz1IHD/KFfEXyE6V0U01OQ3UO2rEg== - dependencies: - resolve-from "^5.0.0" - -resolve-from@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-5.0.0.tgz#c35225843df8f776df21c57557bc087e9dfdfc69" - integrity sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw== - -resolve.exports@^2.0.0: - version "2.0.3" - resolved "https://registry.yarnpkg.com/resolve.exports/-/resolve.exports-2.0.3.tgz#41955e6f1b4013b7586f873749a635dea07ebe3f" - integrity sha512-OcXjMsGdhL4XnbShKpAcSqPMzQoYkYyhbEaeSko47MjRP9NfEQMhZkXL1DoFlt9LWQn4YttrdnV6X2OiyzBi+A== - -resolve@^1.20.0: - version "1.22.10" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.10.tgz#b663e83ffb09bbf2386944736baae803029b8b39" - integrity sha512-NPRy+/ncIMeDlTAsuqwKIiferiawhefFJtkNSW0qZJEqMEb+qBt/77B/jGeeek+F0uOeN05CDa6HXbbIgtVX4w== - dependencies: - is-core-module "^2.16.0" - path-parse "^1.0.7" - supports-preserve-symlinks-flag "^1.0.0" - -safe-buffer@^5.1.0, safe-buffer@~5.2.0: - version "5.2.1" - resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" - integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== - -"safer-buffer@>= 2.1.2 < 3.0.0": - version "2.1.2" - resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" - integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== - -saxes@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/saxes/-/saxes-6.0.0.tgz#fe5b4a4768df4f14a201b1ba6a65c1f3d9988cc5" - integrity sha512-xAg7SOnEhrm5zI3puOOKyy1OMcMlIJZYNJY7xLBwSze0UjhPLnWfj2GF2EpT0jmzaJKIWKHLsaSSajf35bcYnA== - dependencies: - xmlchars "^2.2.0" - -schema-utils@^4.3.0, schema-utils@^4.3.2: - version "4.3.2" - resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-4.3.2.tgz#0c10878bf4a73fd2b1dfd14b9462b26788c806ae" - integrity sha512-Gn/JaSk/Mt9gYubxTtSn/QCV4em9mpAPiR1rqy/Ocu19u/G9J5WWdNoUT4SiV6mFC3y6cxyFcFwdzPM3FgxGAQ== - dependencies: - "@types/json-schema" "^7.0.9" - ajv "^8.9.0" - ajv-formats "^2.1.1" - ajv-keywords "^5.1.0" - -semver@^6.3.0, semver@^6.3.1: - version "6.3.1" - resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" - integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== - -semver@^7.3.4, semver@^7.5.3, semver@^7.5.4, semver@^7.7.2: - version "7.7.2" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.7.2.tgz#67d99fdcd35cec21e6f8b87a7fd515a33f982b58" - integrity sha512-RF0Fw+rO5AMf9MAyaRXI4AV0Ulj5lMHqVxxdSgiVbixSCXoEmmX/jk0CuJw4+3SqroYO9VoUh+HcuJivvtJemA== - -serialize-javascript@^6.0.2: - version "6.0.2" - resolved "https://registry.yarnpkg.com/serialize-javascript/-/serialize-javascript-6.0.2.tgz#defa1e055c83bf6d59ea805d8da862254eb6a6c2" - integrity sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g== - dependencies: - randombytes "^2.1.0" - -shebang-command@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-2.0.0.tgz#ccd0af4f8835fbdc265b82461aaf0c36663f34ea" - integrity sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA== - dependencies: - shebang-regex "^3.0.0" - -shebang-regex@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172" - integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A== - -side-channel-list@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/side-channel-list/-/side-channel-list-1.0.0.tgz#10cb5984263115d3b7a0e336591e290a830af8ad" - integrity sha512-FCLHtRD/gnpCiCHEiJLOwdmFP+wzCmDEkc9y7NsYxeF4u7Btsn1ZuwgwJGxImImHicJArLP4R0yX4c2KCrMrTA== - dependencies: - es-errors "^1.3.0" - object-inspect "^1.13.3" - -side-channel-map@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/side-channel-map/-/side-channel-map-1.0.1.tgz#d6bb6b37902c6fef5174e5f533fab4c732a26f42" - integrity sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA== - dependencies: - call-bound "^1.0.2" - es-errors "^1.3.0" - get-intrinsic "^1.2.5" - object-inspect "^1.13.3" - -side-channel-weakmap@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/side-channel-weakmap/-/side-channel-weakmap-1.0.2.tgz#11dda19d5368e40ce9ec2bdc1fb0ecbc0790ecea" - integrity sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A== - dependencies: - call-bound "^1.0.2" - es-errors "^1.3.0" - get-intrinsic "^1.2.5" - object-inspect "^1.13.3" - side-channel-map "^1.0.1" - -side-channel@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.1.0.tgz#c3fcff9c4da932784873335ec9765fa94ff66bc9" - integrity sha512-ZX99e6tRweoUXqR+VBrslhda51Nh5MTQwou5tnUDgbtyM0dBgmhEDtWGP/xbKn6hqfPRHujUNwz5fy/wbbhnpw== - dependencies: - es-errors "^1.3.0" - object-inspect "^1.13.3" - side-channel-list "^1.0.0" - side-channel-map "^1.0.1" - side-channel-weakmap "^1.0.2" - -signal-exit@^3.0.3, signal-exit@^3.0.7: - version "3.0.7" - resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.7.tgz#a9a1767f8af84155114eaabd73f99273c8f59ad9" - integrity sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ== - -sisteransi@^1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/sisteransi/-/sisteransi-1.0.5.tgz#134d681297756437cc05ca01370d3a7a571075ed" - integrity sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg== - -slash@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/slash/-/slash-3.0.0.tgz#6539be870c165adbd5240220dbe361f1bc4d4634" - integrity sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q== - -source-map-support@0.5.13: - version "0.5.13" - resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.13.tgz#31b24a9c2e73c2de85066c0feb7d44767ed52932" - integrity sha512-SHSKFHadjVA5oR4PPqhtAVdcBWwRYVd6g6cAXnIbRiIwc2EhPrTuKUBdSLvlEKyIP3GCf89fltvcZiP9MMFA1w== - dependencies: - buffer-from "^1.0.0" - source-map "^0.6.0" - -source-map-support@~0.5.20: - version "0.5.21" - resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.21.tgz#04fe7c7f9e1ed2d662233c28cb2b35b9f63f6e4f" - integrity sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w== - dependencies: - buffer-from "^1.0.0" - source-map "^0.6.0" - -source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.1: - version "0.6.1" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" - integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== - -source-map@^0.7.4: - version "0.7.4" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.7.4.tgz#a9bbe705c9d8846f4e08ff6765acf0f1b0898656" - integrity sha512-l3BikUxvPOcn5E74dZiq5BGsTb5yEwhaTSzccU6t4sDOH8NWJCstKO5QT2CvtFoK6F0saL7p9xHAqHOlCPJygA== - -sprintf-js@~1.0.2: - version "1.0.3" - resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" - integrity sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g== - -stack-utils@^2.0.3: - version "2.0.6" - resolved "https://registry.yarnpkg.com/stack-utils/-/stack-utils-2.0.6.tgz#aaf0748169c02fc33c8232abccf933f54a1cc34f" - integrity sha512-XlkWvfIm6RmsWtNJx+uqtKLS8eqFbxUg0ZzLXqY0caEy9l7hruX8IpiDnjsLavoBgqCCR71TqWO8MaXYheJ3RQ== - dependencies: - escape-string-regexp "^2.0.0" - -string-length@^4.0.1: - version "4.0.2" - resolved "https://registry.yarnpkg.com/string-length/-/string-length-4.0.2.tgz#a8a8dc7bd5c1a82b9b3c8b87e125f66871b6e57a" - integrity sha512-+l6rNN5fYHNhZZy41RXsYptCjA2Igmq4EG7kZAYFQI1E1VTXarr6ZPXBg6eq7Y6eK4FEhY6AJlyuFIb/v/S0VQ== - dependencies: - char-regex "^1.0.2" - strip-ansi "^6.0.0" - -string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: - version "4.2.3" - resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" - integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== - dependencies: - emoji-regex "^8.0.0" - is-fullwidth-code-point "^3.0.0" - strip-ansi "^6.0.1" - -string_decoder@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.3.0.tgz#42f114594a46cf1a8e30b0a84f56c78c3edac21e" - integrity sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA== - dependencies: - safe-buffer "~5.2.0" - -strip-ansi@^6.0.0, strip-ansi@^6.0.1: - version "6.0.1" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" - integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== - dependencies: - ansi-regex "^5.0.1" - -strip-bom@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-4.0.0.tgz#9c3505c1db45bcedca3d9cf7a16f5c5aa3901878" - integrity sha512-3xurFv5tEgii33Zi8Jtp55wEIILR9eh34FAW00PZf+JnSsTmV/ioewSgQl97JHvgjoRGwPShsWm+IdrxB35d0w== - -strip-final-newline@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/strip-final-newline/-/strip-final-newline-2.0.0.tgz#89b852fb2fcbe936f6f4b3187afb0a12c1ab58ad" - integrity sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA== - -strip-json-comments@^3.1.1: - version "3.1.1" - resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" - integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== - -supports-color@^7.1.0: - version "7.2.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" - integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== - dependencies: - has-flag "^4.0.0" - -supports-color@^8.0.0: - version "8.1.1" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-8.1.1.tgz#cd6fc17e28500cff56c1b86c0a7fd4a54a73005c" - integrity sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q== - dependencies: - has-flag "^4.0.0" - -supports-preserve-symlinks-flag@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09" - integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w== - -symbol-tree@^3.2.4: - version "3.2.4" - resolved "https://registry.yarnpkg.com/symbol-tree/-/symbol-tree-3.2.4.tgz#430637d248ba77e078883951fb9aa0eed7c63fa2" - integrity sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw== - -tapable@^2.1.1, tapable@^2.2.0: - version "2.2.2" - resolved "https://registry.yarnpkg.com/tapable/-/tapable-2.2.2.tgz#ab4984340d30cb9989a490032f086dbb8b56d872" - integrity sha512-Re10+NauLTMCudc7T5WLFLAwDhQ0JWdrMK+9B2M8zR5hRExKmsRDCBA7/aV/pNJFltmBFO5BAMlQFi/vq3nKOg== - -terser-webpack-plugin@^5.3.11: - version "5.3.14" - resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-5.3.14.tgz#9031d48e57ab27567f02ace85c7d690db66c3e06" - integrity sha512-vkZjpUjb6OMS7dhV+tILUW6BhpDR7P2L/aQSAv+Uwk+m8KATX9EccViHTJR2qDtACKPIYndLGCyl3FMo+r2LMw== - dependencies: - "@jridgewell/trace-mapping" "^0.3.25" - jest-worker "^27.4.5" - schema-utils "^4.3.0" - serialize-javascript "^6.0.2" - terser "^5.31.1" - -terser@^5.31.1: - version "5.43.1" - resolved "https://registry.yarnpkg.com/terser/-/terser-5.43.1.tgz#88387f4f9794ff1a29e7ad61fb2932e25b4fdb6d" - integrity sha512-+6erLbBm0+LROX2sPXlUYx/ux5PyE9K/a92Wrt6oA+WDAoFTdpHE5tCYCI5PNzq2y8df4rA+QgHLJuR4jNymsg== - dependencies: - "@jridgewell/source-map" "^0.3.3" - acorn "^8.14.0" - commander "^2.20.0" - source-map-support "~0.5.20" - -test-exclude@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/test-exclude/-/test-exclude-6.0.0.tgz#04a8698661d805ea6fa293b6cb9e63ac044ef15e" - integrity sha512-cAGWPIyOHU6zlmg88jwm7VRyXnMN7iV68OGAbYDk/Mh/xC/pzVPlQtY6ngoIH/5/tciuhGfvESU8GrHrcxD56w== - dependencies: - "@istanbuljs/schema" "^0.1.2" - glob "^7.1.4" - minimatch "^3.0.4" - -tmpl@1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/tmpl/-/tmpl-1.0.5.tgz#8683e0b902bb9c20c4f726e3c0b69f36518c07cc" - integrity sha512-3f0uOEAQwIqGuWW2MVzYg8fV/QNnc/IpuJNG837rLuczAaLVHslWHZQj4IGiEl5Hs3kkbhwL9Ab7Hrsmuj+Smw== - -to-regex-range@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-5.0.1.tgz#1648c44aae7c8d988a326018ed72f5b4dd0392e4" - integrity sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ== - dependencies: - is-number "^7.0.0" - -tough-cookie@^4.1.2: - version "4.1.4" - resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-4.1.4.tgz#945f1461b45b5a8c76821c33ea49c3ac192c1b36" - integrity sha512-Loo5UUvLD9ScZ6jh8beX1T6sO1w2/MpCRpEP7V280GKMVUQ0Jzar2U3UJPsrdbziLEMMhu3Ujnq//rhiFuIeag== - dependencies: - psl "^1.1.33" - punycode "^2.1.1" - universalify "^0.2.0" - url-parse "^1.5.3" - -tr46@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/tr46/-/tr46-3.0.0.tgz#555c4e297a950617e8eeddef633c87d4d9d6cbf9" - integrity sha512-l7FvfAHlcmulp8kr+flpQZmVwtu7nfRV7NZujtN0OqES8EL4O4e0qqzL0DC5gAvx/ZC/9lk6rhcUwYvkBnBnYA== - dependencies: - punycode "^2.1.1" - -tr46@~0.0.3: - version "0.0.3" - resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" - integrity sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw== - -ts-jest@^29.1.1: - version "29.4.0" - resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-29.4.0.tgz#bef0ee98d94c83670af7462a1617bf2367a83740" - integrity sha512-d423TJMnJGu80/eSgfQ5w/R+0zFJvdtTxwtF9KzFFunOpSeD+79lHJQIiAhluJoyGRbvj9NZJsl9WjCUo0ND7Q== - dependencies: - bs-logger "^0.2.6" - ejs "^3.1.10" - fast-json-stable-stringify "^2.1.0" - json5 "^2.2.3" - lodash.memoize "^4.1.2" - make-error "^1.3.6" - semver "^7.7.2" - type-fest "^4.41.0" - yargs-parser "^21.1.1" - -ts-loader@^9.5.1: - version "9.5.2" - resolved "https://registry.yarnpkg.com/ts-loader/-/ts-loader-9.5.2.tgz#1f3d7f4bb709b487aaa260e8f19b301635d08020" - integrity sha512-Qo4piXvOTWcMGIgRiuFa6nHNm+54HbYaZCKqc9eeZCLRy3XqafQgwX2F7mofrbJG3g7EEb+lkiR+z2Lic2s3Zw== - dependencies: - chalk "^4.1.0" - enhanced-resolve "^5.0.0" - micromatch "^4.0.0" - semver "^7.3.4" - source-map "^0.7.4" - -type-detect@4.0.8: - version "4.0.8" - resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c" - integrity sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g== - -type-fest@^0.21.3: - version "0.21.3" - resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.21.3.tgz#d260a24b0198436e133fa26a524a6d65fa3b2e37" - integrity sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w== - -type-fest@^4.41.0: - version "4.41.0" - resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-4.41.0.tgz#6ae1c8e5731273c2bf1f58ad39cbae2c91a46c58" - integrity sha512-TeTSQ6H5YHvpqVwBRcnLDCBnDOHWYu7IvGbHT6N8AOymcr9PJGjc1GTtiWZTYg0NCgYwvnYWEkVChQAr9bjfwA== - -typescript@~5.7.2: - version "5.7.3" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.7.3.tgz#919b44a7dbb8583a9b856d162be24a54bf80073e" - integrity sha512-84MVSjMEHP+FQRPy3pX9sTVV/INIex71s9TL2Gm5FG/WG1SqXeKyZ0k7/blY/4FdOzI12CBy1vGc4og/eus0fw== - -undici-types@~5.26.4: - version "5.26.5" - resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-5.26.5.tgz#bcd539893d00b56e964fd2657a4866b221a65617" - integrity sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA== - -undici-types@~7.8.0: - version "7.8.0" - resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-7.8.0.tgz#de00b85b710c54122e44fbfd911f8d70174cd294" - integrity sha512-9UJ2xGDvQ43tYyVMpuHlsgApydB8ZKfVYTsLDhXkFL/6gfkp+U8xTGdh8pMJv1SpZna0zxG1DwsKZsreLbXBxw== - -universalify@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.2.0.tgz#6451760566fa857534745ab1dde952d1b1761be0" - integrity sha512-CJ1QgKmNg3CwvAv/kOFmtnEN05f0D/cn9QntgNOQlQF9dgvVTHj3t+8JPdjqawCHk7V/KA+fbUqzZ9XWhcqPUg== - -update-browserslist-db@^1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/update-browserslist-db/-/update-browserslist-db-1.1.3.tgz#348377dd245216f9e7060ff50b15a1b740b75420" - integrity sha512-UxhIZQ+QInVdunkDAaiazvvT/+fXL5Osr0JZlJulepYu6Jd7qJtDZjlur0emRlT71EN3ScPoE7gvsuIKKNavKw== - dependencies: - escalade "^3.2.0" - picocolors "^1.1.1" - -url-join@4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/url-join/-/url-join-4.0.1.tgz#b642e21a2646808ffa178c4c5fda39844e12cde7" - integrity sha512-jk1+QP6ZJqyOiuEI9AEWQfju/nB2Pw466kbA0LEZljHwKeMgd9WrAEgEGxjPDD2+TNbbb37rTyhEfrCXfuKXnA== - -url-parse@^1.5.3: - version "1.5.10" - resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.10.tgz#9d3c2f736c1d75dd3bd2be507dcc111f1e2ea9c1" - integrity sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ== - dependencies: - querystringify "^2.1.1" - requires-port "^1.0.0" - -v8-to-istanbul@^9.0.1: - version "9.3.0" - resolved "https://registry.yarnpkg.com/v8-to-istanbul/-/v8-to-istanbul-9.3.0.tgz#b9572abfa62bd556c16d75fdebc1a411d5ff3175" - integrity sha512-kiGUalWN+rgBJ/1OHZsBtU4rXZOfj/7rKQxULKlIzwzQSvMJUUNgPwJEEh7gU6xEVxC0ahoOBvN2YI8GH6FNgA== - dependencies: - "@jridgewell/trace-mapping" "^0.3.12" - "@types/istanbul-lib-coverage" "^2.0.1" - convert-source-map "^2.0.0" - -w3c-xmlserializer@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/w3c-xmlserializer/-/w3c-xmlserializer-4.0.0.tgz#aebdc84920d806222936e3cdce408e32488a3073" - integrity sha512-d+BFHzbiCx6zGfz0HyQ6Rg69w9k19nviJspaj4yNscGjrHu94sVP+aRm75yEbCh+r2/yR+7q6hux9LVtbuTGBw== - dependencies: - xml-name-validator "^4.0.0" - -walker@^1.0.8: - version "1.0.8" - resolved "https://registry.yarnpkg.com/walker/-/walker-1.0.8.tgz#bd498db477afe573dc04185f011d3ab8a8d7653f" - integrity sha512-ts/8E8l5b7kY0vlWLewOkDXMmPdLcVV4GmOQLyxuSswIJsweeFZtAsMF7k1Nszz+TYBQrlYRmzOnr398y1JemQ== - dependencies: - makeerror "1.0.12" - -watchpack@^2.4.1: - version "2.4.4" - resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-2.4.4.tgz#473bda72f0850453da6425081ea46fc0d7602947" - integrity sha512-c5EGNOiyxxV5qmTtAB7rbiXxi1ooX1pQKMLX/MIabJjRA0SJBQOjKF+KSVfHkr9U1cADPon0mRiVe/riyaiDUA== - dependencies: - glob-to-regexp "^0.4.1" - graceful-fs "^4.1.2" - -webidl-conversions@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-3.0.1.tgz#24534275e2a7bc6be7bc86611cc16ae0a5654871" - integrity sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ== - -webidl-conversions@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-7.0.0.tgz#256b4e1882be7debbf01d05f0aa2039778ea080a" - integrity sha512-VwddBukDzu71offAQR975unBIGqfKZpM+8ZX6ySk8nYhVoo5CYaZyzt3YBvYtRtO+aoGlqxPg/B87NGVZ/fu6g== - -webpack-sources@^3.2.3: - version "3.3.3" - resolved "https://registry.yarnpkg.com/webpack-sources/-/webpack-sources-3.3.3.tgz#d4bf7f9909675d7a070ff14d0ef2a4f3c982c723" - integrity sha512-yd1RBzSGanHkitROoPFd6qsrxt+oFhg/129YzheDGqeustzX0vTZJZsSsQjVQC4yzBQ56K55XU8gaNCtIzOnTg== - -webpack@^5.97.1: - version "5.99.9" - resolved "https://registry.yarnpkg.com/webpack/-/webpack-5.99.9.tgz#d7de799ec17d0cce3c83b70744b4aedb537d8247" - integrity sha512-brOPwM3JnmOa+7kd3NsmOUOwbDAj8FT9xDsG3IW0MgbN9yZV7Oi/s/+MNQ/EcSMqw7qfoRyXPoeEWT8zLVdVGg== - dependencies: - "@types/eslint-scope" "^3.7.7" - "@types/estree" "^1.0.6" - "@types/json-schema" "^7.0.15" - "@webassemblyjs/ast" "^1.14.1" - "@webassemblyjs/wasm-edit" "^1.14.1" - "@webassemblyjs/wasm-parser" "^1.14.1" - acorn "^8.14.0" - browserslist "^4.24.0" - chrome-trace-event "^1.0.2" - enhanced-resolve "^5.17.1" - es-module-lexer "^1.2.1" - eslint-scope "5.1.1" - events "^3.2.0" - glob-to-regexp "^0.4.1" - graceful-fs "^4.2.11" - json-parse-even-better-errors "^2.3.1" - loader-runner "^4.2.0" - mime-types "^2.1.27" - neo-async "^2.6.2" - schema-utils "^4.3.2" - tapable "^2.1.1" - terser-webpack-plugin "^5.3.11" - watchpack "^2.4.1" - webpack-sources "^3.2.3" - -whatwg-encoding@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/whatwg-encoding/-/whatwg-encoding-2.0.0.tgz#e7635f597fd87020858626805a2729fa7698ac53" - integrity sha512-p41ogyeMUrw3jWclHWTQg1k05DSVXPLcVxRTYsXUk+ZooOCZLcoYgPZ/HL/D/N+uQPOtcp1me1WhBEaX02mhWg== - dependencies: - iconv-lite "0.6.3" - -whatwg-mimetype@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/whatwg-mimetype/-/whatwg-mimetype-3.0.0.tgz#5fa1a7623867ff1af6ca3dc72ad6b8a4208beba7" - integrity sha512-nt+N2dzIutVRxARx1nghPKGv1xHikU7HKdfafKkLNLindmPU/ch3U31NOCGGA/dmPcmb1VlofO0vnKAcsm0o/Q== - -whatwg-url@^11.0.0: - version "11.0.0" - resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-11.0.0.tgz#0a849eebb5faf2119b901bb76fd795c2848d4018" - integrity sha512-RKT8HExMpoYx4igMiVMY83lN6UeITKJlBQ+vR/8ZJ8OCdSiN3RwCq+9gH0+Xzj0+5IrM6i4j/6LuvzbZIQgEcQ== - dependencies: - tr46 "^3.0.0" - webidl-conversions "^7.0.0" - -whatwg-url@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-5.0.0.tgz#966454e8765462e37644d3626f6742ce8b70965d" - integrity sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw== - dependencies: - tr46 "~0.0.3" - webidl-conversions "^3.0.0" - -which@^2.0.1: - version "2.0.2" - resolved "https://registry.yarnpkg.com/which/-/which-2.0.2.tgz#7c6a8dd0a636a0327e10b59c9286eee93f3f51b1" - integrity sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA== - dependencies: - isexe "^2.0.0" - -wrap-ansi@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" - integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== - dependencies: - ansi-styles "^4.0.0" - string-width "^4.1.0" - strip-ansi "^6.0.0" - -wrappy@1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" - integrity sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ== - -write-file-atomic@^4.0.2: - version "4.0.2" - resolved "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-4.0.2.tgz#a9df01ae5b77858a027fd2e80768ee433555fcfd" - integrity sha512-7KxauUdBmSdWnmpaGFg+ppNjKF8uNLry8LyzjauQDOVONfFLNKrKvQOxZ/VuTIcS/gge/YNahf5RIIQWTSarlg== - dependencies: - imurmurhash "^0.1.4" - signal-exit "^3.0.7" - -ws@^8.11.0: - version "8.18.2" - resolved "https://registry.yarnpkg.com/ws/-/ws-8.18.2.tgz#42738b2be57ced85f46154320aabb51ab003705a" - integrity sha512-DMricUmwGZUVr++AEAe2uiVM7UoO9MAVZMDu05UQOaUII0lp+zOzLLU4Xqh/JvTqklB1T4uELaaPBKyjE1r4fQ== - -xml-name-validator@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/xml-name-validator/-/xml-name-validator-4.0.0.tgz#79a006e2e63149a8600f15430f0a4725d1524835" - integrity sha512-ICP2e+jsHvAj2E2lIHxa5tjXRlKDJo4IdvPvCXbXQGdzSfmSpNVyIKMvoZHjDY9DP0zV17iI85o90vRFXNccRw== - -xmlchars@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/xmlchars/-/xmlchars-2.2.0.tgz#060fe1bcb7f9c76fe2a17db86a9bc3ab894210cb" - integrity sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw== - -y18n@^5.0.5: - version "5.0.8" - resolved "https://registry.yarnpkg.com/y18n/-/y18n-5.0.8.tgz#7f4934d0f7ca8c56f95314939ddcd2dd91ce1d55" - integrity sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA== - -yallist@^3.0.2: - version "3.1.1" - resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.1.1.tgz#dbb7daf9bfd8bac9ab45ebf602b8cbad0d5d08fd" - integrity sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g== - -yargs-parser@^21.1.1: - version "21.1.1" - resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-21.1.1.tgz#9096bceebf990d21bb31fa9516e0ede294a77d35" - integrity sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw== - -yargs@^17.3.1: - version "17.7.2" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-17.7.2.tgz#991df39aca675a192b816e1e0363f9d75d2aa269" - integrity sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w== - dependencies: - cliui "^8.0.1" - escalade "^3.1.1" - get-caller-file "^2.0.5" - require-directory "^2.1.1" - string-width "^4.2.3" - y18n "^5.0.5" - yargs-parser "^21.1.1" - -yocto-queue@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-0.1.0.tgz#0294eb3dee05028d31ee1a5fa2c556a6aaf10a1b" - integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q== From 841fc4901bff5b016b621a369d09208a11af97d0 Mon Sep 17 00:00:00 2001 From: Steve Henry <84391720+steve-henry@users.noreply.github.com> Date: Tue, 13 Jan 2026 17:39:16 +0000 Subject: [PATCH 139/146] Fix pagination test for conversations with API v2.14 (#506) The conversations pagination test was failing because it relied on pre-existing conversations in the test account. When the default Intercom API version was bumped from 2.11 to 2.14 in v7.0.0, the API returned fewer conversations, causing the test to fail. This fix adds a setup function that creates 2 test conversations before running the pagination test, making the test reliable regardless of the API version or existing data in the test account. Co-authored-by: Claude Sonnet 4.5 --- tests/integration/pagination.test.ts | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/tests/integration/pagination.test.ts b/tests/integration/pagination.test.ts index bfe4b2bd..07112d63 100644 --- a/tests/integration/pagination.test.ts +++ b/tests/integration/pagination.test.ts @@ -49,6 +49,23 @@ describe("Pagination", () => { limit: 2, perPage: 1, greaterThan: 1, + async setup() { + const contact = await client.contacts.create({ + external_id: randomString(), + }); + + await client.conversations.create({ + from: { id: contact.id, type: "user" }, + body: "Test conversation 1", + }); + + await client.conversations.create({ + from: { id: contact.id, type: "user" }, + body: "Test conversation 2", + }); + + return {}; + }, }, { name: "notes", From a53c716293a033feaee8b80ca0151804ceb05d3f Mon Sep 17 00:00:00 2001 From: Steve Henry <84391720+steve-henry@users.noreply.github.com> Date: Tue, 13 Jan 2026 18:08:11 +0000 Subject: [PATCH 140/146] Bump version to 7.0.1 (#507) Co-authored-by: Claude Sonnet 4.5 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 5d739ad4..77a16de3 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "7.0.0", + "version": "7.0.1", "private": false, "repository": "github:intercom/intercom-node", "type": "commonjs", From 8cb93a5d289cbe5bde9015f268c00093c112aaab Mon Sep 17 00:00:00 2001 From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com> Date: Fri, 30 Jan 2026 17:03:18 -0500 Subject: [PATCH 141/146] :herb: Fern Regeneration -- January 30, 2026 (#510) * SDK regeneration * Fix key issue in integration tests --------- Co-authored-by: fern-api[bot] <115122769+fern-api[bot]@users.noreply.github.com> Co-authored-by: fern-support <126544928+fern-support@users.noreply.github.com> --- .github/workflows/ci.yml | 1 + package.json | 2 +- reference.md | 265 ++ src/BaseClient.ts | 4 +- src/Client.ts | 6 + src/api/resources/index.ts | 1 + .../resources/ipAllowlist/client/Client.ts | 179 ++ src/api/resources/ipAllowlist/client/index.ts | 1 + src/api/resources/ipAllowlist/index.ts | 1 + src/api/resources/unstable/client/Client.ts | 6 + .../resources/aiAgent/types/AiAgent.ts | 1 + .../client/requests/UpdateContactRequest.ts | 2 + .../resources/contacts/types/Contact.ts | 2 +- .../resources/conversations/client/Client.ts | 81 + .../requests/ListHandlingEventsRequest.ts | 12 + .../conversations/client/requests/index.ts | 1 + .../conversations/types/Conversation.ts | 2 + src/api/resources/unstable/resources/index.ts | 2 + .../resources/workflows/client/Client.ts | 107 + .../resources/workflows/client/index.ts | 1 + .../client/requests/ExportWorkflowRequest.ts | 12 + .../workflows/client/requests/index.ts | 1 + .../unstable/resources/workflows/index.ts | 1 + .../ConversationAttributeUpdatedByAdmin.ts | 4 +- .../ConversationAttributeUpdatedByUser.ts | 23 + .../types/ConversationSlaAppliedByRule.ts | 27 + .../types/ConversationSlaAppliedByWorkflow.ts | 27 + .../unstable/types/ConversationSlaPaused.ts | 33 + .../unstable/types/ConversationSlaRemoved.ts | 9 + .../types/ConversationSlaTargetMissed.ts | 55 + .../unstable/types/ConversationSlaUnpaused.ts | 9 + .../unstable/types/ConversationTagsUpdated.ts | 11 + .../resources/unstable/types/EventDetails.ts | 12 +- .../resources/unstable/types/HandlingEvent.ts | 25 + .../unstable/types/HandlingEventList.ts | 11 + .../unstable/types/PriorityChanged.ts | 26 + src/api/resources/unstable/types/Snoozed.ts | 11 + .../unstable/types/TeammateReference.ts | 25 + .../unstable/types/WorkflowExport.ts | 59 + src/api/resources/unstable/types/index.ts | 14 + src/api/types/ActivityLog.ts | 7 +- src/api/types/IpAllowlist.ts | 18 + src/api/types/index.ts | 1 + src/version.ts | 2 +- tests/wire/ipAllowlist.test.ts | 122 + tests/wire/unstable/conversations.test.ts | 2288 +++++++++++++++++ tests/wire/unstable/workflows.test.ts | 131 + 47 files changed, 3633 insertions(+), 8 deletions(-) create mode 100644 src/api/resources/ipAllowlist/client/Client.ts create mode 100644 src/api/resources/ipAllowlist/client/index.ts create mode 100644 src/api/resources/ipAllowlist/index.ts create mode 100644 src/api/resources/unstable/resources/conversations/client/requests/ListHandlingEventsRequest.ts create mode 100644 src/api/resources/unstable/resources/workflows/client/Client.ts create mode 100644 src/api/resources/unstable/resources/workflows/client/index.ts create mode 100644 src/api/resources/unstable/resources/workflows/client/requests/ExportWorkflowRequest.ts create mode 100644 src/api/resources/unstable/resources/workflows/client/requests/index.ts create mode 100644 src/api/resources/unstable/resources/workflows/index.ts create mode 100644 src/api/resources/unstable/types/ConversationAttributeUpdatedByUser.ts create mode 100644 src/api/resources/unstable/types/ConversationSlaAppliedByRule.ts create mode 100644 src/api/resources/unstable/types/ConversationSlaAppliedByWorkflow.ts create mode 100644 src/api/resources/unstable/types/ConversationSlaPaused.ts create mode 100644 src/api/resources/unstable/types/ConversationSlaRemoved.ts create mode 100644 src/api/resources/unstable/types/ConversationSlaTargetMissed.ts create mode 100644 src/api/resources/unstable/types/ConversationSlaUnpaused.ts create mode 100644 src/api/resources/unstable/types/ConversationTagsUpdated.ts create mode 100644 src/api/resources/unstable/types/HandlingEvent.ts create mode 100644 src/api/resources/unstable/types/HandlingEventList.ts create mode 100644 src/api/resources/unstable/types/PriorityChanged.ts create mode 100644 src/api/resources/unstable/types/Snoozed.ts create mode 100644 src/api/resources/unstable/types/TeammateReference.ts create mode 100644 src/api/resources/unstable/types/WorkflowExport.ts create mode 100644 src/api/types/IpAllowlist.ts create mode 100644 tests/wire/ipAllowlist.test.ts create mode 100644 tests/wire/unstable/workflows.test.ts diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6d5b7754..268fb922 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,6 +42,7 @@ jobs: run: pnpm test env: INTERCOM_API_KEY: ${{ secrets.INTERCOM_API_KEY }} + API_TOKEN: ${{ secrets.INTERCOM_API_KEY }} publish: needs: [ compile, test ] diff --git a/package.json b/package.json index 77a16de3..6d3287ef 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "7.0.1", + "version": "7.0.2", "private": false, "repository": "github:intercom/intercom-node", "type": "commonjs", diff --git a/reference.md b/reference.md index 5b2306ab..224ae271 100644 --- a/reference.md +++ b/reference.md @@ -2451,6 +2451,132 @@ await client.internalArticles.searchInternalArticles({ + + +
+ +## IP Allowlist +
client.ipAllowlist.getIpAllowlist() -> Intercom.IpAllowlist +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve the current IP allowlist configuration for the workspace. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ipAllowlist.getIpAllowlist(); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**requestOptions:** `IpAllowlistClient.RequestOptions` + +
+
+
+
+ + +
+
+
+ +
client.ipAllowlist.updateIpAllowlist({ ...params }) -> Intercom.IpAllowlist +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Update the IP allowlist configuration for the workspace. + +{% admonition type="warning" name="Lockout Protection" %} + The API will reject updates that would lock out the caller's IP address. Ensure your current IP is included in the allowlist when enabling the feature. +{% /admonition %} +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.ipAllowlist.updateIpAllowlist({ + enabled: true, + ip_allowlist: ["192.168.1.0/24", "10.0.0.1"] +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.IpAllowlist` + +
+
+ +
+
+ +**requestOptions:** `IpAllowlistClient.RequestOptions` + +
+
+
+
+ +
@@ -16633,6 +16759,73 @@ await client.unstable.conversations.detachContactFromConversation({ + + +
+ +
client.unstable.conversations.listHandlingEvents({ ...params }) -> Intercom.HandlingEventList +
+
+ +#### 📝 Description + +
+
+ +
+
+ +List all pause/resume events for a conversation. These events track when teammates paused or resumed handling a conversation. + +Requires the `read_conversations` OAuth scope. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.conversations.listHandlingEvents({ + id: "123" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ListHandlingEventsRequest` + +
+
+ +
+
+ +**requestOptions:** `ConversationsClient.RequestOptions` + +
+
+
+
+ +
@@ -18150,6 +18343,78 @@ await client.unstable.dataExport.downloadDataExport({ + + +
+ +## Workflows +
client.unstable.workflows.exportWorkflow({ ...params }) -> Intercom.WorkflowExport +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Export a workflow configuration by its ID. This endpoint returns the complete workflow definition including its steps, targeting rules, and attributes. + +This endpoint is designed for EU Data Act compliance, allowing customers to export their workflow configurations. + +{% admonition type="warning" name="Unstable API" %} + This API is currently in the Unstable version. Its behavior may change in future releases. +{% /admonition %} +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.unstable.workflows.exportWorkflow({ + id: "12345" +}); + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `Intercom.unstable.ExportWorkflowRequest` + +
+
+ +
+
+ +**requestOptions:** `WorkflowsClient.RequestOptions` + +
+
+
+
+ +
diff --git a/src/BaseClient.ts b/src/BaseClient.ts index 45d31870..84ecd466 100644 --- a/src/BaseClient.ts +++ b/src/BaseClient.ts @@ -96,8 +96,8 @@ export function normalizeClientOptions(options: T): { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "7.0.0", - "User-Agent": "intercom-client/7.0.0", + "X-Fern-SDK-Version": "7.0.2", + "User-Agent": "intercom-client/7.0.2", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, "Intercom-Version": options?.version ?? "2.14", diff --git a/src/Client.ts b/src/Client.ts index 8db0d729..db9d639f 100644 --- a/src/Client.ts +++ b/src/Client.ts @@ -16,6 +16,7 @@ import { EventsClient } from "./api/resources/events/client/Client.js"; import { ExportClient } from "./api/resources/export/client/Client.js"; import { HelpCentersClient } from "./api/resources/helpCenters/client/Client.js"; import { InternalArticlesClient } from "./api/resources/internalArticles/client/Client.js"; +import { IpAllowlistClient } from "./api/resources/ipAllowlist/client/Client.js"; import { JobsClient } from "./api/resources/jobs/client/Client.js"; import { MessagesClient } from "./api/resources/messages/client/Client.js"; import { NewsClient } from "./api/resources/news/client/Client.js"; @@ -49,6 +50,7 @@ export class IntercomClient { protected _dataExport: DataExportClient | undefined; protected _helpCenters: HelpCentersClient | undefined; protected _internalArticles: InternalArticlesClient | undefined; + protected _ipAllowlist: IpAllowlistClient | undefined; protected _companies: CompaniesClient | undefined; protected _contacts: ContactsClient | undefined; protected _notes: NotesClient | undefined; @@ -108,6 +110,10 @@ export class IntercomClient { return (this._internalArticles ??= new InternalArticlesClient(this._options)); } + public get ipAllowlist(): IpAllowlistClient { + return (this._ipAllowlist ??= new IpAllowlistClient(this._options)); + } + public get companies(): CompaniesClient { return (this._companies ??= new CompaniesClient(this._options)); } diff --git a/src/api/resources/index.ts b/src/api/resources/index.ts index 80be8483..716d6022 100644 --- a/src/api/resources/index.ts +++ b/src/api/resources/index.ts @@ -49,6 +49,7 @@ export * as helpCenters from "./helpCenters/index.js"; export * from "./internalArticles/client/requests/index.js"; export * as internalArticles from "./internalArticles/index.js"; export * from "./internalArticles/types/index.js"; +export * as ipAllowlist from "./ipAllowlist/index.js"; export * from "./jobs/client/requests/index.js"; export * as jobs from "./jobs/index.js"; export * from "./jobs/types/index.js"; diff --git a/src/api/resources/ipAllowlist/client/Client.ts b/src/api/resources/ipAllowlist/client/Client.ts new file mode 100644 index 00000000..21809d4b --- /dev/null +++ b/src/api/resources/ipAllowlist/client/Client.ts @@ -0,0 +1,179 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../core/headers.js"; +import * as core from "../../../../core/index.js"; +import * as environments from "../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../errors/index.js"; +import * as Intercom from "../../../index.js"; + +export declare namespace IpAllowlistClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * Manage IP allowlist settings for your workspace. + * + * The IP Allowlist API allows you to configure which IP addresses are allowed to access the Intercom API and web application for your workspace. This is useful for restricting access to your Intercom workspace to specific corporate networks or VPNs. + * + * {% admonition type="info" name="Authentication" %} + * This endpoint requires the `manage_ip_allowlist` OAuth scope. + * {% /admonition %} + */ +export class IpAllowlistClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: IpAllowlistClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * Retrieve the current IP allowlist configuration for the workspace. + * + * @param {IpAllowlistClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * + * @example + * await client.ipAllowlist.getIpAllowlist() + */ + public getIpAllowlist( + requestOptions?: IpAllowlistClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__getIpAllowlist(requestOptions)); + } + + private async __getIpAllowlist( + requestOptions?: IpAllowlistClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ip_allowlist", + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.IpAllowlist, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/ip_allowlist"); + } + + /** + * Update the IP allowlist configuration for the workspace. + * + * {% admonition type="warning" name="Lockout Protection" %} + * The API will reject updates that would lock out the caller's IP address. Ensure your current IP is included in the allowlist when enabling the feature. + * {% /admonition %} + * + * @param {Intercom.IpAllowlist} request + * @param {IpAllowlistClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.UnauthorizedError} + * @throws {@link Intercom.UnprocessableEntityError} + * + * @example + * await client.ipAllowlist.updateIpAllowlist({ + * enabled: true, + * ip_allowlist: ["192.168.1.0/24", "10.0.0.1"] + * }) + */ + public updateIpAllowlist( + request: Intercom.IpAllowlist, + requestOptions?: IpAllowlistClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__updateIpAllowlist(request, requestOptions)); + } + + private async __updateIpAllowlist( + request: Intercom.IpAllowlist, + requestOptions?: IpAllowlistClient.RequestOptions, + ): Promise> { + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + "ip_allowlist", + ), + method: "PUT", + headers: _headers, + contentType: "application/json", + queryParameters: requestOptions?.queryParams, + requestType: "json", + body: request, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.IpAllowlist, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.UnauthorizedError( + _response.error.body as Intercom.Error_, + _response.rawResponse, + ); + case 422: + throw new Intercom.UnprocessableEntityError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "PUT", "/ip_allowlist"); + } +} diff --git a/src/api/resources/ipAllowlist/client/index.ts b/src/api/resources/ipAllowlist/client/index.ts new file mode 100644 index 00000000..cb0ff5c3 --- /dev/null +++ b/src/api/resources/ipAllowlist/client/index.ts @@ -0,0 +1 @@ +export {}; diff --git a/src/api/resources/ipAllowlist/index.ts b/src/api/resources/ipAllowlist/index.ts new file mode 100644 index 00000000..914b8c3c --- /dev/null +++ b/src/api/resources/ipAllowlist/index.ts @@ -0,0 +1 @@ +export * from "./client/index.js"; diff --git a/src/api/resources/unstable/client/Client.ts b/src/api/resources/unstable/client/Client.ts index 3058c14f..f42b2732 100644 --- a/src/api/resources/unstable/client/Client.ts +++ b/src/api/resources/unstable/client/Client.ts @@ -35,6 +35,7 @@ import { TicketsClient } from "../resources/tickets/client/Client.js"; import { TicketTypeAttributesClient } from "../resources/ticketTypeAttributes/client/Client.js"; import { TicketTypesClient } from "../resources/ticketTypes/client/Client.js"; import { VisitorsClient } from "../resources/visitors/client/Client.js"; +import { WorkflowsClient } from "../resources/workflows/client/Client.js"; export declare namespace UnstableClient { export interface Options extends BaseClientOptions {} @@ -60,6 +61,7 @@ export class UnstableClient { protected _dataAttributes: DataAttributesClient | undefined; protected _dataEvents: DataEventsClient | undefined; protected _dataExport: DataExportClient | undefined; + protected _workflows: WorkflowsClient | undefined; protected _jobs: JobsClient | undefined; protected _macros: MacrosClient | undefined; protected _messages: MessagesClient | undefined; @@ -152,6 +154,10 @@ export class UnstableClient { return (this._dataExport ??= new DataExportClient(this._options)); } + public get workflows(): WorkflowsClient { + return (this._workflows ??= new WorkflowsClient(this._options)); + } + public get jobs(): JobsClient { return (this._jobs ??= new JobsClient(this._options)); } diff --git a/src/api/resources/unstable/resources/aiAgent/types/AiAgent.ts b/src/api/resources/unstable/resources/aiAgent/types/AiAgent.ts index fb043f41..868b1cd9 100644 --- a/src/api/resources/unstable/resources/aiAgent/types/AiAgent.ts +++ b/src/api/resources/unstable/resources/aiAgent/types/AiAgent.ts @@ -47,6 +47,7 @@ export namespace AiAgent { ConfirmedResolution: "confirmed_resolution", Escalated: "escalated", NegativeFeedback: "negative_feedback", + ProcedureHandoff: "procedure_handoff", } as const; export type ResolutionState = (typeof ResolutionState)[keyof typeof ResolutionState]; } diff --git a/src/api/resources/unstable/resources/contacts/client/requests/UpdateContactRequest.ts b/src/api/resources/unstable/resources/contacts/client/requests/UpdateContactRequest.ts index e33aba66..3d671681 100644 --- a/src/api/resources/unstable/resources/contacts/client/requests/UpdateContactRequest.ts +++ b/src/api/resources/unstable/resources/contacts/client/requests/UpdateContactRequest.ts @@ -41,6 +41,8 @@ export interface UpdateContactRequest { owner_id?: number; /** Whether the contact is unsubscribed from emails */ unsubscribed_from_emails?: boolean; + /** A preferred language setting for the contact, used by Intercom as the language of Fin and the Messenger even if their browser has a different setting. Supports ISO 639-1 two-letter language codes. If an unsupported code is supplied, the field will be set to null. */ + language_override?: string; /** The custom attributes which are set for the contact */ custom_attributes?: Record; } diff --git a/src/api/resources/unstable/resources/contacts/types/Contact.ts b/src/api/resources/unstable/resources/contacts/types/Contact.ts index 0cf076af..cb4e3927 100644 --- a/src/api/resources/unstable/resources/contacts/types/Contact.ts +++ b/src/api/resources/unstable/resources/contacts/types/Contact.ts @@ -50,7 +50,7 @@ export interface Contact { last_email_opened_at?: number; /** (UNIX timestamp) The time when the contact last clicked a link in an email. */ last_email_clicked_at?: number; - /** A preferred language setting for the contact, used by the Intercom Messenger even if their browser settings change. */ + /** A preferred language setting for the contact, used by Intercom as the language of Fin and the Messenger even if their browser has a different setting. Supports ISO 639-1 two-letter language codes. If an unsupported code is supplied, the field will be set to null. */ language_override?: string; /** The name of the browser which the contact is using. */ browser?: string; diff --git a/src/api/resources/unstable/resources/conversations/client/Client.ts b/src/api/resources/unstable/resources/conversations/client/Client.ts index 70ca206d..1823bcca 100644 --- a/src/api/resources/unstable/resources/conversations/client/Client.ts +++ b/src/api/resources/unstable/resources/conversations/client/Client.ts @@ -1161,6 +1161,87 @@ export class ConversationsClient { ); } + /** + * List all pause/resume events for a conversation. These events track when teammates paused or resumed handling a conversation. + * + * Requires the `read_conversations` OAuth scope. + * + * @param {Intercom.unstable.ListHandlingEventsRequest} request + * @param {ConversationsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.UnauthorizedError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.conversations.listHandlingEvents({ + * id: "123" + * }) + */ + public listHandlingEvents( + request: Intercom.unstable.ListHandlingEventsRequest, + requestOptions?: ConversationsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__listHandlingEvents(request, requestOptions)); + } + + private async __listHandlingEvents( + request: Intercom.unstable.ListHandlingEventsRequest, + requestOptions?: ConversationsClient.RequestOptions, + ): Promise> { + const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `conversations/${core.url.encodePathParam(id)}/handling_events`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.HandlingEventList, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 401: + throw new Intercom.unstable.UnauthorizedError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError( + _response.error, + _response.rawResponse, + "GET", + "/conversations/{id}/handling_events", + ); + } + /** * You can redact a conversation part or the source message of a conversation (as seen in the source object). * diff --git a/src/api/resources/unstable/resources/conversations/client/requests/ListHandlingEventsRequest.ts b/src/api/resources/unstable/resources/conversations/client/requests/ListHandlingEventsRequest.ts new file mode 100644 index 00000000..3f3f4d31 --- /dev/null +++ b/src/api/resources/unstable/resources/conversations/client/requests/ListHandlingEventsRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * id: "123" + * } + */ +export interface ListHandlingEventsRequest { + /** The identifier for the conversation as given by Intercom. */ + id: string; +} diff --git a/src/api/resources/unstable/resources/conversations/client/requests/index.ts b/src/api/resources/unstable/resources/conversations/client/requests/index.ts index 0d6b5317..3733a95d 100644 --- a/src/api/resources/unstable/resources/conversations/client/requests/index.ts +++ b/src/api/resources/unstable/resources/conversations/client/requests/index.ts @@ -4,6 +4,7 @@ export type { CreateConversationRequest } from "./CreateConversationRequest.js"; export type { DeleteConversationRequest } from "./DeleteConversationRequest.js"; export type { DetachContactFromConversationRequest } from "./DetachContactFromConversationRequest.js"; export type { ListConversationsRequest } from "./ListConversationsRequest.js"; +export type { ListHandlingEventsRequest } from "./ListHandlingEventsRequest.js"; export type { ManageConversationRequest } from "./ManageConversationRequest.js"; export type { ReplyConversationRequest } from "./ReplyConversationRequest.js"; export type { RetrieveConversationRequest } from "./RetrieveConversationRequest.js"; diff --git a/src/api/resources/unstable/resources/conversations/types/Conversation.ts b/src/api/resources/unstable/resources/conversations/types/Conversation.ts index 8a79bcda..d53ea2a2 100644 --- a/src/api/resources/unstable/resources/conversations/types/Conversation.ts +++ b/src/api/resources/unstable/resources/conversations/types/Conversation.ts @@ -34,6 +34,8 @@ export interface Conversation { team_assignee_id?: string; /** The ID of the company that the conversation is associated with. The unique identifier for the company which is given by Intercom. */ company_id?: string; + /** The company associated with the conversation. */ + company?: Intercom.unstable.Company; tags?: Intercom.unstable.Tags; conversation_rating?: Intercom.unstable.ConversationRating; source?: Intercom.unstable.ConversationSource; diff --git a/src/api/resources/unstable/resources/index.ts b/src/api/resources/unstable/resources/index.ts index 47fc9e84..e821213e 100644 --- a/src/api/resources/unstable/resources/index.ts +++ b/src/api/resources/unstable/resources/index.ts @@ -91,3 +91,5 @@ export * from "./ticketTypes/client/requests/index.js"; export * as ticketTypes from "./ticketTypes/index.js"; export * from "./visitors/client/requests/index.js"; export * as visitors from "./visitors/index.js"; +export * from "./workflows/client/requests/index.js"; +export * as workflows from "./workflows/index.js"; diff --git a/src/api/resources/unstable/resources/workflows/client/Client.ts b/src/api/resources/unstable/resources/workflows/client/Client.ts new file mode 100644 index 00000000..9e14a53a --- /dev/null +++ b/src/api/resources/unstable/resources/workflows/client/Client.ts @@ -0,0 +1,107 @@ +// This file was auto-generated by Fern from our API Definition. + +import type { BaseClientOptions, BaseRequestOptions } from "../../../../../../BaseClient.js"; +import { type NormalizedClientOptionsWithAuth, normalizeClientOptionsWithAuth } from "../../../../../../BaseClient.js"; +import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.js"; +import * as core from "../../../../../../core/index.js"; +import * as environments from "../../../../../../environments.js"; +import { handleNonStatusCodeError } from "../../../../../../errors/handleNonStatusCodeError.js"; +import * as errors from "../../../../../../errors/index.js"; +import * as Intercom from "../../../../../index.js"; + +export declare namespace WorkflowsClient { + export interface Options extends BaseClientOptions {} + + export interface RequestOptions extends BaseRequestOptions {} +} + +/** + * Export workflow configurations from your workspace. + */ +export class WorkflowsClient { + protected readonly _options: NormalizedClientOptionsWithAuth; + + constructor(options: WorkflowsClient.Options = {}) { + this._options = normalizeClientOptionsWithAuth(options); + } + + /** + * Export a workflow configuration by its ID. This endpoint returns the complete workflow definition including its steps, targeting rules, and attributes. + * + * This endpoint is designed for EU Data Act compliance, allowing customers to export their workflow configurations. + * + * {% admonition type="warning" name="Unstable API" %} + * This API is currently in the Unstable version. Its behavior may change in future releases. + * {% /admonition %} + * + * @param {Intercom.unstable.ExportWorkflowRequest} request + * @param {WorkflowsClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @throws {@link Intercom.unstable.ForbiddenError} + * @throws {@link Intercom.unstable.NotFoundError} + * + * @example + * await client.unstable.workflows.exportWorkflow({ + * id: "12345" + * }) + */ + public exportWorkflow( + request: Intercom.unstable.ExportWorkflowRequest, + requestOptions?: WorkflowsClient.RequestOptions, + ): core.HttpResponsePromise { + return core.HttpResponsePromise.fromPromise(this.__exportWorkflow(request, requestOptions)); + } + + private async __exportWorkflow( + request: Intercom.unstable.ExportWorkflowRequest, + requestOptions?: WorkflowsClient.RequestOptions, + ): Promise> { + const { id } = request; + const _authRequest: core.AuthRequest = await this._options.authProvider.getAuthRequest(); + const _headers: core.Fetcher.Args["headers"] = mergeHeaders( + _authRequest.headers, + this._options?.headers, + mergeOnlyDefinedHeaders({ "Intercom-Version": requestOptions?.version }), + requestOptions?.headers, + ); + const _response = await (this._options.fetcher ?? core.fetcher)({ + url: core.url.join( + (await core.Supplier.get(this._options.baseUrl)) ?? + (await core.Supplier.get(this._options.environment)) ?? + environments.IntercomEnvironment.UsProduction, + `export/workflows/${core.url.encodePathParam(id)}`, + ), + method: "GET", + headers: _headers, + queryParameters: requestOptions?.queryParams, + timeoutMs: (requestOptions?.timeoutInSeconds ?? this._options?.timeoutInSeconds ?? 20) * 1000, + maxRetries: requestOptions?.maxRetries ?? this._options?.maxRetries, + abortSignal: requestOptions?.abortSignal, + fetchFn: this._options?.fetch, + logging: this._options.logging, + }); + if (_response.ok) { + return { data: _response.body as Intercom.unstable.WorkflowExport, rawResponse: _response.rawResponse }; + } + + if (_response.error.reason === "status-code") { + switch (_response.error.statusCode) { + case 403: + throw new Intercom.unstable.ForbiddenError( + _response.error.body as Intercom.unstable.Error_, + _response.rawResponse, + ); + case 404: + throw new Intercom.unstable.NotFoundError(_response.error.body as unknown, _response.rawResponse); + default: + throw new errors.IntercomError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + rawResponse: _response.rawResponse, + }); + } + } + + return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/export/workflows/{id}"); + } +} diff --git a/src/api/resources/unstable/resources/workflows/client/index.ts b/src/api/resources/unstable/resources/workflows/client/index.ts new file mode 100644 index 00000000..195f9aa8 --- /dev/null +++ b/src/api/resources/unstable/resources/workflows/client/index.ts @@ -0,0 +1 @@ +export * from "./requests/index.js"; diff --git a/src/api/resources/unstable/resources/workflows/client/requests/ExportWorkflowRequest.ts b/src/api/resources/unstable/resources/workflows/client/requests/ExportWorkflowRequest.ts new file mode 100644 index 00000000..f8d7dd1d --- /dev/null +++ b/src/api/resources/unstable/resources/workflows/client/requests/ExportWorkflowRequest.ts @@ -0,0 +1,12 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * @example + * { + * id: "12345" + * } + */ +export interface ExportWorkflowRequest { + /** The unique identifier for the workflow */ + id: string; +} diff --git a/src/api/resources/unstable/resources/workflows/client/requests/index.ts b/src/api/resources/unstable/resources/workflows/client/requests/index.ts new file mode 100644 index 00000000..b9acc294 --- /dev/null +++ b/src/api/resources/unstable/resources/workflows/client/requests/index.ts @@ -0,0 +1 @@ +export type { ExportWorkflowRequest } from "./ExportWorkflowRequest.js"; diff --git a/src/api/resources/unstable/resources/workflows/index.ts b/src/api/resources/unstable/resources/workflows/index.ts new file mode 100644 index 00000000..914b8c3c --- /dev/null +++ b/src/api/resources/unstable/resources/workflows/index.ts @@ -0,0 +1 @@ +export * from "./client/index.js"; diff --git a/src/api/resources/unstable/types/ConversationAttributeUpdatedByAdmin.ts b/src/api/resources/unstable/types/ConversationAttributeUpdatedByAdmin.ts index b44c2202..997b2ea3 100644 --- a/src/api/resources/unstable/types/ConversationAttributeUpdatedByAdmin.ts +++ b/src/api/resources/unstable/types/ConversationAttributeUpdatedByAdmin.ts @@ -15,7 +15,9 @@ export namespace ConversationAttributeUpdatedByAdmin { } export interface Value { - /** Value of the CDA updated */ + /** Current value of the CDA updated */ name?: string; + /** Previous value of the CDA */ + previous?: string; } } diff --git a/src/api/resources/unstable/types/ConversationAttributeUpdatedByUser.ts b/src/api/resources/unstable/types/ConversationAttributeUpdatedByUser.ts new file mode 100644 index 00000000..c0f19e67 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationAttributeUpdatedByUser.ts @@ -0,0 +1,23 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains details about Custom Data Attributes (CDAs) that were modified by a user for conversation part type conversation_attribute_updated_by_user. + */ +export interface ConversationAttributeUpdatedByUser { + attribute?: ConversationAttributeUpdatedByUser.Attribute; + value?: ConversationAttributeUpdatedByUser.Value; +} + +export namespace ConversationAttributeUpdatedByUser { + export interface Attribute { + /** Name of the CDA updated */ + name?: string; + } + + export interface Value { + /** Current value of the CDA updated */ + name?: string; + /** Previous value of the CDA (null for older events) */ + previous?: string; + } +} diff --git a/src/api/resources/unstable/types/ConversationSlaAppliedByRule.ts b/src/api/resources/unstable/types/ConversationSlaAppliedByRule.ts new file mode 100644 index 00000000..8340e44f --- /dev/null +++ b/src/api/resources/unstable/types/ConversationSlaAppliedByRule.ts @@ -0,0 +1,27 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains details about SLA applied by modern Operator workflows for conversation part type conversation_sla_applied_by_rule. + */ +export interface ConversationSlaAppliedByRule { + /** Name of the SLA that was applied */ + sla_name?: string; + /** Target times configured for the SLA (in seconds) */ + sla_definition?: ConversationSlaAppliedByRule.SlaDefinition; +} + +export namespace ConversationSlaAppliedByRule { + /** + * Target times configured for the SLA (in seconds) + */ + export interface SlaDefinition { + /** First response time target in seconds */ + first_reply_time?: number; + /** Next reply time target in seconds */ + next_reply_time?: number; + /** Resolution time target in seconds */ + resolution_time?: number; + /** Time to close target in seconds */ + time_to_close?: number; + } +} diff --git a/src/api/resources/unstable/types/ConversationSlaAppliedByWorkflow.ts b/src/api/resources/unstable/types/ConversationSlaAppliedByWorkflow.ts new file mode 100644 index 00000000..29b5464d --- /dev/null +++ b/src/api/resources/unstable/types/ConversationSlaAppliedByWorkflow.ts @@ -0,0 +1,27 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains details about SLA applied by legacy Inbox Rules for conversation part type conversation_sla_applied_by_workflow. + */ +export interface ConversationSlaAppliedByWorkflow { + /** Name of the SLA that was applied */ + sla_name?: string; + /** Target times configured for the SLA (in seconds) */ + sla_definition?: ConversationSlaAppliedByWorkflow.SlaDefinition; +} + +export namespace ConversationSlaAppliedByWorkflow { + /** + * Target times configured for the SLA (in seconds) + */ + export interface SlaDefinition { + /** First response time target in seconds */ + first_reply_time?: number; + /** Next reply time target in seconds */ + next_reply_time?: number; + /** Resolution time target in seconds */ + resolution_time?: number; + /** Time to close target in seconds */ + time_to_close?: number; + } +} diff --git a/src/api/resources/unstable/types/ConversationSlaPaused.ts b/src/api/resources/unstable/types/ConversationSlaPaused.ts new file mode 100644 index 00000000..eb842828 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationSlaPaused.ts @@ -0,0 +1,33 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains SLA status at the moment of pausing for conversation part type conversation_sla_paused. + */ +export interface ConversationSlaPaused { + /** Name of the SLA being paused */ + sla_name?: string; + /** Overall SLA status at pause time */ + current_sla_status?: ConversationSlaPaused.CurrentSlaStatus; + /** Status of all SLA targets at pause time */ + sla_states?: Record; +} + +export namespace ConversationSlaPaused { + /** Overall SLA status at pause time */ + export const CurrentSlaStatus = { + Active: "active", + Hit: "hit", + Missed: "missed", + Canceled: "canceled", + } as const; + export type CurrentSlaStatus = (typeof CurrentSlaStatus)[keyof typeof CurrentSlaStatus]; + + export namespace SlaStates { + export interface Value { + /** Status of this specific target (always paused) */ + status?: "paused"; + /** Time remaining when paused */ + seconds_remaining?: number; + } + } +} diff --git a/src/api/resources/unstable/types/ConversationSlaRemoved.ts b/src/api/resources/unstable/types/ConversationSlaRemoved.ts new file mode 100644 index 00000000..c0007356 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationSlaRemoved.ts @@ -0,0 +1,9 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains basic SLA information when removed for conversation part type conversation_sla_removed. + */ +export interface ConversationSlaRemoved { + /** Name of the SLA that was removed */ + sla_name?: string; +} diff --git a/src/api/resources/unstable/types/ConversationSlaTargetMissed.ts b/src/api/resources/unstable/types/ConversationSlaTargetMissed.ts new file mode 100644 index 00000000..bec5f996 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationSlaTargetMissed.ts @@ -0,0 +1,55 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains complete status of all SLA targets when a breach occurs for conversation part type conversation_sla_target_missed. + */ +export interface ConversationSlaTargetMissed { + /** Name of the SLA */ + sla_name?: string; + /** Which specific target was missed */ + sla_target_type?: ConversationSlaTargetMissed.SlaTargetType; + /** Overall SLA status */ + current_sla_status?: ConversationSlaTargetMissed.CurrentSlaStatus; + /** Status of all SLA targets at the time of breach */ + sla_states?: Record; +} + +export namespace ConversationSlaTargetMissed { + /** Which specific target was missed */ + export const SlaTargetType = { + FirstReplyTime: "first_reply_time", + NextReplyTime: "next_reply_time", + ResolutionTime: "resolution_time", + TimeToClose: "time_to_close", + } as const; + export type SlaTargetType = (typeof SlaTargetType)[keyof typeof SlaTargetType]; + /** Overall SLA status */ + export const CurrentSlaStatus = { + Hit: "hit", + Missed: "missed", + Active: "active", + Paused: "paused", + Canceled: "canceled", + } as const; + export type CurrentSlaStatus = (typeof CurrentSlaStatus)[keyof typeof CurrentSlaStatus]; + + export namespace SlaStates { + export interface Value { + /** Status of this specific target */ + status?: Value.Status; + /** Time remaining for active/paused targets (null for hit/missed) */ + seconds_remaining?: number; + } + + export namespace Value { + /** Status of this specific target */ + export const Status = { + Hit: "hit", + Missed: "missed", + Active: "active", + Paused: "paused", + } as const; + export type Status = (typeof Status)[keyof typeof Status]; + } + } +} diff --git a/src/api/resources/unstable/types/ConversationSlaUnpaused.ts b/src/api/resources/unstable/types/ConversationSlaUnpaused.ts new file mode 100644 index 00000000..e7045d0f --- /dev/null +++ b/src/api/resources/unstable/types/ConversationSlaUnpaused.ts @@ -0,0 +1,9 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains basic SLA information when unpaused for conversation part type conversation_sla_unpaused. + */ +export interface ConversationSlaUnpaused { + /** Name of the SLA being unpaused */ + sla_name?: string; +} diff --git a/src/api/resources/unstable/types/ConversationTagsUpdated.ts b/src/api/resources/unstable/types/ConversationTagsUpdated.ts new file mode 100644 index 00000000..556dd3e0 --- /dev/null +++ b/src/api/resources/unstable/types/ConversationTagsUpdated.ts @@ -0,0 +1,11 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains details about tags that were added or removed from a conversation for conversation part type conversation_tags_updated. + */ +export interface ConversationTagsUpdated { + /** Array of tag names that were added */ + tags_added?: string[]; + /** Array of tag names that were removed */ + tags_removed?: string[]; +} diff --git a/src/api/resources/unstable/types/EventDetails.ts b/src/api/resources/unstable/types/EventDetails.ts index b257b71e..422603dc 100644 --- a/src/api/resources/unstable/types/EventDetails.ts +++ b/src/api/resources/unstable/types/EventDetails.ts @@ -5,6 +5,16 @@ import type * as Intercom from "../../../index.js"; export type EventDetails = | Intercom.unstable.ConversationAttributeUpdatedByWorkflow | Intercom.unstable.ConversationAttributeUpdatedByAdmin + | Intercom.unstable.ConversationAttributeUpdatedByUser | Intercom.unstable.CustomActionStarted | Intercom.unstable.CustomActionFinished - | Intercom.unstable.OperatorWorkflowEvent; + | Intercom.unstable.OperatorWorkflowEvent + | Intercom.unstable.ConversationTagsUpdated + | Intercom.unstable.Snoozed + | Intercom.unstable.PriorityChanged + | Intercom.unstable.ConversationSlaAppliedByRule + | Intercom.unstable.ConversationSlaAppliedByWorkflow + | Intercom.unstable.ConversationSlaTargetMissed + | Intercom.unstable.ConversationSlaPaused + | Intercom.unstable.ConversationSlaUnpaused + | Intercom.unstable.ConversationSlaRemoved; diff --git a/src/api/resources/unstable/types/HandlingEvent.ts b/src/api/resources/unstable/types/HandlingEvent.ts new file mode 100644 index 00000000..f6d3e9d6 --- /dev/null +++ b/src/api/resources/unstable/types/HandlingEvent.ts @@ -0,0 +1,25 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +/** + * A pause or resume event for a conversation + */ +export interface HandlingEvent { + teammate: Intercom.unstable.TeammateReference; + /** The type of handling event */ + type: HandlingEvent.Type; + /** ISO8601 timestamp when the event occurred */ + timestamp: string; + /** Optional reason for the event (e.g., "Paused", "Away") */ + reason?: string; +} + +export namespace HandlingEvent { + /** The type of handling event */ + export const Type = { + Paused: "paused", + Resumed: "resumed", + } as const; + export type Type = (typeof Type)[keyof typeof Type]; +} diff --git a/src/api/resources/unstable/types/HandlingEventList.ts b/src/api/resources/unstable/types/HandlingEventList.ts new file mode 100644 index 00000000..57dfe2d2 --- /dev/null +++ b/src/api/resources/unstable/types/HandlingEventList.ts @@ -0,0 +1,11 @@ +// This file was auto-generated by Fern from our API Definition. + +import type * as Intercom from "../../../index.js"; + +/** + * A list of handling events for a conversation + */ +export interface HandlingEventList { + /** Array of handling events */ + handling_events?: Intercom.unstable.HandlingEvent[]; +} diff --git a/src/api/resources/unstable/types/PriorityChanged.ts b/src/api/resources/unstable/types/PriorityChanged.ts new file mode 100644 index 00000000..f09b55df --- /dev/null +++ b/src/api/resources/unstable/types/PriorityChanged.ts @@ -0,0 +1,26 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains details about priority changes for conversation part type priority_changed. + */ +export interface PriorityChanged { + /** Current priority state */ + current_priority?: PriorityChanged.CurrentPriority; + /** Previous priority state */ + previous_priority?: PriorityChanged.PreviousPriority; +} + +export namespace PriorityChanged { + /** Current priority state */ + export const CurrentPriority = { + Priority: "priority", + NotPriority: "not_priority", + } as const; + export type CurrentPriority = (typeof CurrentPriority)[keyof typeof CurrentPriority]; + /** Previous priority state */ + export const PreviousPriority = { + Priority: "priority", + NotPriority: "not_priority", + } as const; + export type PreviousPriority = (typeof PreviousPriority)[keyof typeof PreviousPriority]; +} diff --git a/src/api/resources/unstable/types/Snoozed.ts b/src/api/resources/unstable/types/Snoozed.ts new file mode 100644 index 00000000..c8ea22fc --- /dev/null +++ b/src/api/resources/unstable/types/Snoozed.ts @@ -0,0 +1,11 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * Contains details about conversation snooze timing for conversation part type snoozed. + */ +export interface Snoozed { + /** Human-readable description of snooze duration */ + until?: string; + /** ISO timestamp for custom snooze times (null for general snoozes) */ + custom_until_time?: string; +} diff --git a/src/api/resources/unstable/types/TeammateReference.ts b/src/api/resources/unstable/types/TeammateReference.ts new file mode 100644 index 00000000..913ea0b2 --- /dev/null +++ b/src/api/resources/unstable/types/TeammateReference.ts @@ -0,0 +1,25 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * A reference to a teammate (admin, team, or bot) + */ +export interface TeammateReference { + /** The type of teammate */ + type: TeammateReference.Type; + /** The unique identifier of the teammate */ + id: number; + /** The display name of the teammate */ + name: string; + /** The email address of the teammate (optional for teams/bots) */ + email?: string; +} + +export namespace TeammateReference { + /** The type of teammate */ + export const Type = { + Admin: "admin", + Team: "team", + Bot: "bot", + } as const; + export type Type = (typeof Type)[keyof typeof Type]; +} diff --git a/src/api/resources/unstable/types/WorkflowExport.ts b/src/api/resources/unstable/types/WorkflowExport.ts new file mode 100644 index 00000000..93531949 --- /dev/null +++ b/src/api/resources/unstable/types/WorkflowExport.ts @@ -0,0 +1,59 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * A workflow export containing the complete workflow configuration. + */ +export interface WorkflowExport { + /** The version of the export format. */ + export_version?: string; + /** The timestamp when the export was generated. */ + exported_at?: string; + /** The workspace identifier. */ + app_id?: number; + /** The workflow configuration. */ + workflow?: WorkflowExport.Workflow; +} + +export namespace WorkflowExport { + /** + * The workflow configuration. + */ + export interface Workflow { + /** The unique identifier for the workflow. */ + id?: string; + /** The title of the workflow. */ + title?: string; + /** The description of the workflow. */ + description?: string; + /** The type of trigger that starts this workflow. */ + trigger_type?: string; + /** The current state of the workflow. */ + state?: Workflow.State; + /** The channels this workflow targets. */ + target_channels?: string[]; + /** The preferred devices for this workflow. */ + preferred_devices?: string[]; + /** When the workflow was created. */ + created_at?: string; + /** When the workflow was last updated. */ + updated_at?: string; + /** The targeting rules for this workflow. */ + targeting?: Record; + /** The current snapshot of workflow steps and configuration. */ + snapshot?: Record; + /** Custom attributes defined for this workflow. */ + attributes?: Record[]; + /** Rules embedded within the workflow steps. */ + embedded_rules?: Record[]; + } + + export namespace Workflow { + /** The current state of the workflow. */ + export const State = { + Live: "live", + Draft: "draft", + Paused: "paused", + } as const; + export type State = (typeof State)[keyof typeof State]; + } +} diff --git a/src/api/resources/unstable/types/index.ts b/src/api/resources/unstable/types/index.ts index ff1cd877..5b8c268e 100644 --- a/src/api/resources/unstable/types/index.ts +++ b/src/api/resources/unstable/types/index.ts @@ -49,6 +49,7 @@ export * from "./ContactUnarchived.js"; export * from "./ContentSourcesList.js"; export * from "./ConversationAttachmentFiles.js"; export * from "./ConversationAttributeUpdatedByAdmin.js"; +export * from "./ConversationAttributeUpdatedByUser.js"; export * from "./ConversationAttributeUpdatedByWorkflow.js"; export * from "./ConversationContacts.js"; export * from "./ConversationDeleted.js"; @@ -60,8 +61,15 @@ export * from "./ConversationPartMetadata.js"; export * from "./ConversationParts.js"; export * from "./ConversationRating.js"; export * from "./ConversationResponseTime.js"; +export * from "./ConversationSlaAppliedByRule.js"; +export * from "./ConversationSlaAppliedByWorkflow.js"; +export * from "./ConversationSlaPaused.js"; +export * from "./ConversationSlaRemoved.js"; +export * from "./ConversationSlaTargetMissed.js"; +export * from "./ConversationSlaUnpaused.js"; export * from "./ConversationSource.js"; export * from "./ConversationStatistics.js"; +export * from "./ConversationTagsUpdated.js"; export * from "./ConversationTeammates.js"; export * from "./CreateArticleRequest.js"; export * from "./CreateDataAttributeRequest.js"; @@ -102,6 +110,8 @@ export * from "./EventDetails.js"; export * from "./FileAttribute.js"; export * from "./GroupContent.js"; export * from "./GroupTranslatedContent.js"; +export * from "./HandlingEvent.js"; +export * from "./HandlingEventList.js"; export * from "./InternalArticleList.js"; export * from "./LinkedObject.js"; export * from "./LinkedObjectList.js"; @@ -116,6 +126,7 @@ export * from "./PaginatedResponse.js"; export * from "./PaginatedResponseDataItem.js"; export * from "./PartAttachment.js"; export * from "./PhoneSwitch.js"; +export * from "./PriorityChanged.js"; export * from "./QuickReplyOption.js"; export * from "./Recipient.js"; export * from "./RedactConversationRequest.js"; @@ -127,6 +138,7 @@ export * from "./SegmentList.js"; export * from "./SingleFilterSearchRequest.js"; export * from "./SlaApplied.js"; export * from "./SnoozeConversationRequest.js"; +export * from "./Snoozed.js"; export * from "./SocialProfile.js"; export * from "./StartingAfterPaging.js"; export * from "./SubscriptionTypeList.js"; @@ -135,6 +147,7 @@ export * from "./TagList.js"; export * from "./TagMultipleUsersRequest.js"; export * from "./Tags.js"; export * from "./TeamList.js"; +export * from "./TeammateReference.js"; export * from "./TeamPriorityLevel.js"; export * from "./TicketCustomAttributes.js"; export * from "./TicketList.js"; @@ -152,3 +165,4 @@ export * from "./UpdateDataAttributeRequestBody.js"; export * from "./Visitor.js"; export * from "./VisitorDeletedObject.js"; export * from "./WhatsappMessageStatusList.js"; +export * from "./WorkflowExport.js"; diff --git a/src/api/types/ActivityLog.ts b/src/api/types/ActivityLog.ts index ddf4451d..eea2e6fd 100644 --- a/src/api/types/ActivityLog.ts +++ b/src/api/types/ActivityLog.ts @@ -88,7 +88,7 @@ export namespace ActivityLog { InboxAccessChange: "inbox_access_change", MacroCreation: "macro_creation", MacroDeletion: "macro_deletion", - MacroUpdated: "macro_updated", + MacroUpdate: "macro_update", MaliciousDomainsSettingChange: "malicious_domains_setting_change", MessageDeletion: "message_deletion", MessageStateChange: "message_state_change", @@ -110,6 +110,11 @@ export namespace ActivityLog { SeatChange: "seat_change", SeatRevoke: "seat_revoke", SecuritySettingsChange: "security_settings_change", + SeriesCreation: "series_creation", + SeriesDeletion: "series_deletion", + SeriesSettingsUpdate: "series_settings_update", + SeriesStatusChange: "series_status_change", + SeriesUpdate: "series_update", StripInboundEmailLinksChange: "strip_inbound_email_links_change", TemporaryExpectationChange: "temporary_expectation_change", TeamAssignmentLimitChange: "team_assignment_limit_change", diff --git a/src/api/types/IpAllowlist.ts b/src/api/types/IpAllowlist.ts new file mode 100644 index 00000000..27a5b011 --- /dev/null +++ b/src/api/types/IpAllowlist.ts @@ -0,0 +1,18 @@ +// This file was auto-generated by Fern from our API Definition. + +/** + * IP allowlist settings for the workspace. + */ +export interface IpAllowlist { + /** String representing the object's type. Always has the value `ip_allowlist`. */ + type?: string; + /** Whether the IP allowlist is enabled for the workspace. */ + enabled?: boolean; + /** + * List of allowed IP addresses and/or IP ranges in CIDR notation. + * Examples: + * - Single IP: `192.168.0.1` + * - IP range: `192.168.0.1/24` (allows 192.168.0.0 - 192.168.0.255) + */ + ip_allowlist?: string[]; +} diff --git a/src/api/types/index.ts b/src/api/types/index.ts index f81547cc..d0b6e87d 100644 --- a/src/api/types/index.ts +++ b/src/api/types/index.ts @@ -106,6 +106,7 @@ export * from "./FileAttribute.js"; export * from "./GroupContent.js"; export * from "./GroupTranslatedContent.js"; export * from "./InternalArticleList.js"; +export * from "./IpAllowlist.js"; export * from "./LinkedObject.js"; export * from "./LinkedObjectList.js"; export * from "./Metadata.js"; diff --git a/src/version.ts b/src/version.ts index 6bb53d57..b37f04e1 100644 --- a/src/version.ts +++ b/src/version.ts @@ -1 +1 @@ -export const SDK_VERSION = "7.0.0"; +export const SDK_VERSION = "7.0.2"; diff --git a/tests/wire/ipAllowlist.test.ts b/tests/wire/ipAllowlist.test.ts new file mode 100644 index 00000000..de84803f --- /dev/null +++ b/tests/wire/ipAllowlist.test.ts @@ -0,0 +1,122 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../src/api/index"; +import { IntercomClient } from "../../src/Client"; +import { mockServerPool } from "../mock-server/MockServerPool"; + +describe("IpAllowlistClient", () => { + test("getIpAllowlist (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "ip_allowlist", enabled: true, ip_allowlist: ["192.168.1.0/24", "10.0.0.1"] }; + server.mockEndpoint().get("/ip_allowlist").respondWith().statusCode(200).jsonBody(rawResponseBody).build(); + + const response = await client.ipAllowlist.getIpAllowlist(); + expect(response).toEqual({ + type: "ip_allowlist", + enabled: true, + ip_allowlist: ["192.168.1.0/24", "10.0.0.1"], + }); + }); + + test("getIpAllowlist (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server.mockEndpoint().get("/ip_allowlist").respondWith().statusCode(401).jsonBody(rawResponseBody).build(); + + await expect(async () => { + return await client.ipAllowlist.getIpAllowlist(); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("updateIpAllowlist (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = { enabled: true, ip_allowlist: ["192.168.1.0/24", "10.0.0.1"] }; + const rawResponseBody = { type: "ip_allowlist", enabled: true, ip_allowlist: ["192.168.1.0/24", "10.0.0.1"] }; + server + .mockEndpoint() + .put("/ip_allowlist") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.ipAllowlist.updateIpAllowlist({ + enabled: true, + ip_allowlist: ["192.168.1.0/24", "10.0.0.1"], + }); + expect(response).toEqual({ + type: "ip_allowlist", + enabled: true, + ip_allowlist: ["192.168.1.0/24", "10.0.0.1"], + }); + }); + + test("updateIpAllowlist (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { type: "error.list", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .put("/ip_allowlist") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.ipAllowlist.updateIpAllowlist({}); + }).rejects.toThrow(Intercom.UnauthorizedError); + }); + + test("updateIpAllowlist (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + const rawRequestBody = {}; + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .put("/ip_allowlist") + .jsonBody(rawRequestBody) + .respondWith() + .statusCode(422) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.ipAllowlist.updateIpAllowlist({}); + }).rejects.toThrow(Intercom.UnprocessableEntityError); + }); +}); diff --git a/tests/wire/unstable/conversations.test.ts b/tests/wire/unstable/conversations.test.ts index 4dca52d8..88fb1544 100644 --- a/tests/wire/unstable/conversations.test.ts +++ b/tests/wire/unstable/conversations.test.ts @@ -32,6 +32,27 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }], @@ -144,6 +165,27 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + }, tags: { type: "tag.list", tags: [ @@ -511,6 +553,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -788,6 +872,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -1220,6 +1357,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -1426,6 +1605,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -1683,6 +1915,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -1850,6 +2124,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -2071,6 +2398,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -2277,6 +2646,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -2696,6 +3118,27 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }], @@ -2826,6 +3269,27 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + }, tags: { type: "tag.list", tags: [ @@ -2984,6 +3448,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -3157,6 +3663,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -3384,6 +3943,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -3557,6 +4158,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -3787,6 +4441,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -3969,6 +4665,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -4197,6 +4946,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -4376,6 +5167,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -4603,6 +5447,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -4776,6 +5662,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -5109,6 +6048,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -5281,6 +6262,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -5503,6 +6537,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -5675,6 +6751,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -5897,6 +7026,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -6068,6 +7239,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -6290,6 +7514,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 991267715, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -6464,6 +7730,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 991267715, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -6690,6 +8009,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -6862,6 +8223,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -7177,6 +8591,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -7331,6 +8787,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -7537,6 +9046,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -7691,6 +9242,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -7975,6 +9579,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -8127,6 +9773,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -8333,6 +10032,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -8485,6 +10226,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -8691,6 +10485,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -8843,6 +10679,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -9049,6 +10938,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -9201,6 +11132,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -9495,6 +11479,120 @@ describe("ConversationsClient", () => { }).rejects.toThrow(Intercom.unstable.UnprocessableEntityError); }); + test("listHandlingEvents (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + handling_events: [ + { + teammate: { type: "admin", id: 123, name: "Jane Example", email: "jane@example.com" }, + type: "paused", + timestamp: "2026-01-09T09:00:00Z", + reason: "Paused", + }, + { + teammate: { type: "admin", id: 123, name: "Jane Example", email: "jane@example.com" }, + type: "resumed", + timestamp: "2026-01-09T09:10:00Z", + reason: "Paused", + }, + ], + }; + server + .mockEndpoint() + .get("/conversations/123/handling_events") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.conversations.listHandlingEvents({ + id: "123", + }); + expect(response).toEqual({ + handling_events: [ + { + teammate: { + type: "admin", + id: 123, + name: "Jane Example", + email: "jane@example.com", + }, + type: "paused", + timestamp: "2026-01-09T09:00:00Z", + reason: "Paused", + }, + { + teammate: { + type: "admin", + id: 123, + name: "Jane Example", + email: "jane@example.com", + }, + type: "resumed", + timestamp: "2026-01-09T09:10:00Z", + reason: "Paused", + }, + ], + }); + }); + + test("listHandlingEvents (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/conversations/id/handling_events") + .respondWith() + .statusCode(401) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.listHandlingEvents({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.UnauthorizedError); + }); + + test("listHandlingEvents (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/conversations/id/handling_events") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.conversations.listHandlingEvents({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); + test("redactConversation (1)", async () => { const server = mockServerPool.createServer(); const client = new IntercomClient({ @@ -9523,6 +11621,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -9692,6 +11832,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ @@ -9918,6 +12111,48 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { type: "plan", id: "269315", name: "Pro" }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { type: "tag.list" }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { type: "note", id: "17495962", created_at: 1674589321, body: "

Text for the note.

" }, + ], + }, + }, tags: { type: "tag.list", tags: [{ type: "tag", id: "123456", name: "Test tag", applied_at: 1663597223 }] }, conversation_rating: { rating: 5, @@ -10087,6 +12322,59 @@ describe("ConversationsClient", () => { admin_assignee_id: 0, team_assignee_id: "5017691", company_id: "5f4d3c1c-7b1b-4d7d-a97e-6095715c6632", + company: { + type: "company", + id: "531ee472cce572a6ec000006", + name: "Blue Sun", + app_id: "ecahpwf5", + plan: { + type: "plan", + id: "269315", + name: "Pro", + }, + company_id: "6", + remote_created_at: 1663597223, + created_at: 1663597223, + updated_at: 1663597223, + last_request_at: 1663597223, + size: 100, + website: "https://www.intercom.com", + industry: "Software", + monthly_spend: 100, + session_count: 100, + user_count: 100, + custom_attributes: { + paid_subscriber: "custom_attributes", + monthly_spend: "custom_attributes", + team_mates: "custom_attributes", + }, + tags: { + type: "tag.list", + }, + segments: { + type: "segment.list", + segments: [ + { + id: "56203d253cba154d39010062", + name: "Active", + created_at: 1394621988, + updated_at: 1394622004, + count: 3, + }, + ], + }, + notes: { + type: "note.list", + notes: [ + { + type: "note", + id: "17495962", + created_at: 1674589321, + body: "

Text for the note.

", + }, + ], + }, + }, tags: { type: "tag.list", tags: [ diff --git a/tests/wire/unstable/workflows.test.ts b/tests/wire/unstable/workflows.test.ts new file mode 100644 index 00000000..b4035d7f --- /dev/null +++ b/tests/wire/unstable/workflows.test.ts @@ -0,0 +1,131 @@ +// This file was auto-generated by Fern from our API Definition. + +import * as Intercom from "../../../src/api/index"; +import { IntercomClient } from "../../../src/Client"; +import { mockServerPool } from "../../mock-server/MockServerPool"; + +describe("WorkflowsClient", () => { + test("exportWorkflow (1)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { + export_version: "1.0", + exported_at: "2026-01-26T12:00:00Z", + app_id: 12345, + workflow: { + id: "67890", + title: "My Workflow", + description: "A workflow that handles customer inquiries", + trigger_type: "inbound_conversation", + state: "live", + target_channels: ["chat"], + preferred_devices: ["desktop", "mobile"], + created_at: "2025-06-15T10:30:00Z", + updated_at: "2026-01-20T14:45:00Z", + targeting: { key: "value" }, + snapshot: { key: "value" }, + attributes: [{ key: "value" }], + embedded_rules: [{ key: "value" }], + }, + }; + server + .mockEndpoint() + .get("/export/workflows/12345") + .respondWith() + .statusCode(200) + .jsonBody(rawResponseBody) + .build(); + + const response = await client.unstable.workflows.exportWorkflow({ + id: "12345", + }); + expect(response).toEqual({ + export_version: "1.0", + exported_at: "2026-01-26T12:00:00Z", + app_id: 12345, + workflow: { + id: "67890", + title: "My Workflow", + description: "A workflow that handles customer inquiries", + trigger_type: "inbound_conversation", + state: "live", + target_channels: ["chat"], + preferred_devices: ["desktop", "mobile"], + created_at: "2025-06-15T10:30:00Z", + updated_at: "2026-01-20T14:45:00Z", + targeting: { + key: "value", + }, + snapshot: { + key: "value", + }, + attributes: [ + { + key: "value", + }, + ], + embedded_rules: [ + { + key: "value", + }, + ], + }, + }); + }); + + test("exportWorkflow (2)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { type: "type", errors: [{ code: "code" }, { code: "code" }] }; + server + .mockEndpoint() + .get("/export/workflows/id") + .respondWith() + .statusCode(403) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.workflows.exportWorkflow({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.ForbiddenError); + }); + + test("exportWorkflow (3)", async () => { + const server = mockServerPool.createServer(); + const client = new IntercomClient({ + maxRetries: 0, + token: "test", + version: "2.14", + environment: server.baseUrl, + }); + + const rawResponseBody = { key: "value" }; + server + .mockEndpoint() + .get("/export/workflows/id") + .respondWith() + .statusCode(404) + .jsonBody(rawResponseBody) + .build(); + + await expect(async () => { + return await client.unstable.workflows.exportWorkflow({ + id: "id", + }); + }).rejects.toThrow(Intercom.unstable.NotFoundError); + }); +}); From 8196697e843deafbe3869c4d6eab6904bc692ef6 Mon Sep 17 00:00:00 2001 From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com> Date: Mon, 2 Feb 2026 10:26:10 -0800 Subject: [PATCH 142/146] SDK regeneration (#511) Co-authored-by: fern-api[bot] <115122769+fern-api[bot]@users.noreply.github.com> --- package.json | 2 +- src/BaseClient.ts | 4 ++-- src/api/resources/contacts/types/Contact.ts | 18 ++++++++--------- .../conversations/types/Conversation.ts | 20 +++++++++---------- .../resources/dataEvents/types/DataEvent.ts | 2 +- src/api/resources/messages/types/Message.ts | 2 +- src/api/resources/notes/types/Note.ts | 8 ++++---- src/api/resources/tickets/types/Ticket.ts | 12 +++++------ src/api/types/Visitor.ts | 6 +++--- src/version.ts | 2 +- 10 files changed, 38 insertions(+), 38 deletions(-) diff --git a/package.json b/package.json index 6d3287ef..8bcf8e0c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "intercom-client", - "version": "7.0.2", + "version": "7.0.3", "private": false, "repository": "github:intercom/intercom-node", "type": "commonjs", diff --git a/src/BaseClient.ts b/src/BaseClient.ts index 84ecd466..1c4b0442 100644 --- a/src/BaseClient.ts +++ b/src/BaseClient.ts @@ -96,8 +96,8 @@ export function normalizeClientOptions(options: T): { "X-Fern-Language": "JavaScript", "X-Fern-SDK-Name": "intercom-client", - "X-Fern-SDK-Version": "7.0.2", - "User-Agent": "intercom-client/7.0.2", + "X-Fern-SDK-Version": "7.0.3", + "User-Agent": "intercom-client/7.0.3", "X-Fern-Runtime": core.RUNTIME.type, "X-Fern-Runtime-Version": core.RUNTIME.version, "Intercom-Version": options?.version ?? "2.14", diff --git a/src/api/resources/contacts/types/Contact.ts b/src/api/resources/contacts/types/Contact.ts index 7c6e6305..1df7ed44 100644 --- a/src/api/resources/contacts/types/Contact.ts +++ b/src/api/resources/contacts/types/Contact.ts @@ -7,15 +7,15 @@ import type * as Intercom from "../../../index.js"; */ export interface Contact { /** The type of object. */ - type?: "contact"; + type: "contact"; /** The unique identifier for the contact which is given by Intercom. */ - id?: string; + id: string; /** The unique identifier for the contact which is provided by the Client. */ external_id?: string; /** The id of the workspace which the contact belongs to. */ - workspace_id?: string; + workspace_id: string; /** The role of the contact. */ - role?: string; + role: string; /** The contact's email. */ email?: string; /** The contact's email domain. */ @@ -27,15 +27,15 @@ export interface Contact { /** The id of an admin that has been assigned account ownership of the contact. */ owner_id?: number; /** Whether the contact has had an email sent to them hard bounce. */ - has_hard_bounced?: boolean; + has_hard_bounced: boolean; /** Whether the contact has marked an email sent to them as spam. */ - marked_email_as_spam?: boolean; + marked_email_as_spam: boolean; /** Whether the contact is unsubscribed from emails. */ - unsubscribed_from_emails?: boolean; + unsubscribed_from_emails: boolean; /** (UNIX timestamp) The time when the contact was created. */ - created_at?: number; + created_at: number; /** (UNIX timestamp) The time when the contact was last updated. */ - updated_at?: number; + updated_at: number; /** (UNIX timestamp) The time specified for when a contact signed up. */ signed_up_at?: number; /** (UNIX timestamp) The time when the contact was last seen (either where the Intercom Messenger was installed or when specified manually). */ diff --git a/src/api/resources/conversations/types/Conversation.ts b/src/api/resources/conversations/types/Conversation.ts index 95606d03..bf5334b2 100644 --- a/src/api/resources/conversations/types/Conversation.ts +++ b/src/api/resources/conversations/types/Conversation.ts @@ -7,25 +7,25 @@ import type * as Intercom from "../../../index.js"; */ export interface Conversation { /** Always conversation. */ - type?: string; + type: string; /** The id representing the conversation. */ - id?: string; + id: string; /** The title given to the conversation. */ title?: string; /** The time the conversation was created. */ - created_at?: number; + created_at: number; /** The last time the conversation was updated. */ - updated_at?: number; + updated_at: number; /** The last time a Contact responded to an Admin. In other words, the time a customer started waiting for a response. Set to null if last reply is from an Admin. */ waiting_since?: number; /** If set this is the time in the future when this conversation will be marked as open. i.e. it will be in a snoozed state until this time. i.e. it will be in a snoozed state until this time. */ snoozed_until?: number; /** Indicates whether a conversation is open (true) or closed (false). */ - open?: boolean; + open: boolean; /** Can be set to "open", "closed" or "snoozed". */ - state?: Conversation.State; + state: Conversation.State; /** Indicates whether a conversation has been read. */ - read?: boolean; + read: boolean; /** If marked as priority, it will return priority or else not_priority. */ priority?: Conversation.Priority; /** The id of the admin assigned to the conversation. If it's not assigned to an admin it will return null. */ @@ -36,10 +36,10 @@ export interface Conversation { company_id?: string; tags?: Intercom.Tags; conversation_rating?: Intercom.ConversationRating; - source?: Intercom.ConversationSource; - contacts?: Intercom.ConversationContacts; + source: Intercom.ConversationSource; + contacts: Intercom.ConversationContacts; teammates?: Intercom.ConversationTeammates; - custom_attributes?: Intercom.CustomAttributes; + custom_attributes: Intercom.CustomAttributes; first_contact_reply?: Intercom.ConversationFirstContactReply; sla_applied?: Intercom.SlaApplied; statistics?: Intercom.ConversationStatistics; diff --git a/src/api/resources/dataEvents/types/DataEvent.ts b/src/api/resources/dataEvents/types/DataEvent.ts index a88a24e6..6efc5389 100644 --- a/src/api/resources/dataEvents/types/DataEvent.ts +++ b/src/api/resources/dataEvents/types/DataEvent.ts @@ -5,7 +5,7 @@ */ export interface DataEvent { /** The type of the object */ - type?: "event"; + type: "event"; /** The name of the event that occurred. This is presented to your App's admins when filtering and creating segments - a good event name is typically a past tense 'verb-noun' combination, to improve readability, for example `updated-plan`. */ event_name: string; /** The time the event occurred as a UTC Unix timestamp */ diff --git a/src/api/resources/messages/types/Message.ts b/src/api/resources/messages/types/Message.ts index a2f8aa46..2341594c 100644 --- a/src/api/resources/messages/types/Message.ts +++ b/src/api/resources/messages/types/Message.ts @@ -17,7 +17,7 @@ export interface Message { /** The type of message that was sent. Can be email, inapp, facebook or twitter. */ message_type: Message.MessageType; /** The associated conversation_id */ - conversation_id?: string; + conversation_id: string; } export namespace Message { diff --git a/src/api/resources/notes/types/Note.ts b/src/api/resources/notes/types/Note.ts index e22e0eb3..3ce14629 100644 --- a/src/api/resources/notes/types/Note.ts +++ b/src/api/resources/notes/types/Note.ts @@ -7,17 +7,17 @@ import type * as Intercom from "../../../index.js"; */ export interface Note { /** String representing the object's type. Always has the value `note`. */ - type?: string; + type: string; /** The id of the note. */ - id?: string; + id: string; /** The time the note was created. */ - created_at?: number; + created_at: number; /** Represents the contact that the note was created about. */ contact?: Note.Contact; /** Optional. Represents the Admin that created the note. */ author?: Intercom.Admin; /** The body text of the note. */ - body?: string; + body: string; } export namespace Note { diff --git a/src/api/resources/tickets/types/Ticket.ts b/src/api/resources/tickets/types/Ticket.ts index 8582aca5..5e686d50 100644 --- a/src/api/resources/tickets/types/Ticket.ts +++ b/src/api/resources/tickets/types/Ticket.ts @@ -7,17 +7,17 @@ import type * as Intercom from "../../../index.js"; */ export interface Ticket { /** Always ticket */ - type?: "ticket"; + type: "ticket"; /** The unique identifier for the ticket which is given by Intercom. */ - id?: string; + id: string; /** The ID of the Ticket used in the Intercom Inbox and Messenger. Do not use ticket_id for API queries. */ - ticket_id?: string; + ticket_id: string; /** Category of the Ticket. */ - category?: Ticket.Category; - ticket_attributes?: Intercom.TicketCustomAttributes; + category: Ticket.Category; + ticket_attributes: Intercom.TicketCustomAttributes; ticket_state?: Intercom.TicketState; ticket_type?: Intercom.TicketType; - contacts?: Intercom.TicketContacts; + contacts: Intercom.TicketContacts; /** The id representing the admin assigned to the ticket. */ admin_assignee_id?: string; /** The id representing the team assigned to the ticket. */ diff --git a/src/api/types/Visitor.ts b/src/api/types/Visitor.ts index 195792a3..5aa58457 100644 --- a/src/api/types/Visitor.ts +++ b/src/api/types/Visitor.ts @@ -7,11 +7,11 @@ import type * as Intercom from "../index.js"; */ export interface Visitor { /** Value is 'visitor' */ - type?: "visitor"; + type: "visitor"; /** The Intercom defined id representing the Visitor. */ - id?: string; + id: string; /** Automatically generated identifier for the Visitor. */ - user_id?: string; + user_id: string; /** Identifies if this visitor is anonymous. */ anonymous?: boolean; /** The email of the visitor. */ diff --git a/src/version.ts b/src/version.ts index b37f04e1..948f7433 100644 --- a/src/version.ts +++ b/src/version.ts @@ -1 +1 @@ -export const SDK_VERSION = "7.0.2"; +export const SDK_VERSION = "7.0.3"; From 86d57815b702f461daf32aaebe665224a64a0a1b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 10 Feb 2026 12:03:59 +0000 Subject: [PATCH 143/146] Bump webpack from 5.103.0 to 5.104.1 (#512) Automatic merge of Dependabot PR --- pnpm-lock.yaml | 122 +++++++++++++++++++++++++++---------------------- 1 file changed, 68 insertions(+), 54 deletions(-) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 7a489b0d..b6c82556 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -19,16 +19,16 @@ importers: version: 2.11.2(@types/node@18.19.130)(typescript@5.7.3) ts-loader: specifier: ^9.5.1 - version: 9.5.4(typescript@5.7.3)(webpack@5.103.0) + version: 9.5.4(typescript@5.7.3)(webpack@5.104.1) typescript: specifier: ~5.7.2 version: 5.7.3 vitest: specifier: ^3.2.4 - version: 3.2.4(@types/node@18.19.130)(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(terser@5.44.1) + version: 3.2.4(@types/node@18.19.130)(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(terser@5.46.0) webpack: specifier: ^5.97.1 - version: 5.103.0 + version: 5.104.1 packages: @@ -567,16 +567,16 @@ packages: resolution: {integrity: sha512-Izi8RQcffqCeNVgFigKli1ssklIbpHnCYc6AknXGYoB6grJqyeby7jv12JUQgmTAnIDnbck1uxksT4dzN3PWBA==} engines: {node: '>=12'} - baseline-browser-mapping@2.8.32: - resolution: {integrity: sha512-OPz5aBThlyLFgxyhdwf/s2+8ab3OvT7AdTNvKHBwpXomIYeXqpUUuT8LrdtxZSsWJ4R4CU1un4XGh5Ez3nlTpw==} + baseline-browser-mapping@2.9.19: + resolution: {integrity: sha512-ipDqC8FrAl/76p2SSWKSI+H9tFwm7vYqXQrItCuiVPt26Km0jS+NzSsBWAaBusvSbQcfJG+JitdMm+wZAgTYqg==} hasBin: true braces@3.0.3: resolution: {integrity: sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==} engines: {node: '>=8'} - browserslist@4.28.0: - resolution: {integrity: sha512-tbydkR/CxfMwelN0vwdP/pLkDwyAASZ+VfWm4EOwlB6SWhx1sYnWLqo8N5j0rAzPfzfRaxt0mM/4wPU/Su84RQ==} + browserslist@4.28.1: + resolution: {integrity: sha512-ZC5Bd0LgJXgwGqUknZY/vkUQ04r8NXnJZ3yYi4vDmSiZmC/pdSN0NbNRPxZpbtO4uAfDUAFffO8IZoM3Gj8IkA==} engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} hasBin: true @@ -587,8 +587,8 @@ packages: resolution: {integrity: sha512-b6Ilus+c3RrdDk+JhLKUAQfzzgLEPy6wcXqS7f/xe1EETvsDP6GORG7SFuOs6cID5YkqchW/LXZbX5bc8j7ZcQ==} engines: {node: '>=8'} - caniuse-lite@1.0.30001757: - resolution: {integrity: sha512-r0nnL/I28Zi/yjk1el6ilj27tKcdjLsNqAOZr0yVjWPrSQyHgKI2INaEWw21bAQSv2LXRt1XuCS/GomNpWOxsQ==} + caniuse-lite@1.0.30001769: + resolution: {integrity: sha512-BCfFL1sHijQlBGWBMuJyhZUhzo7wer5sVj9hqekB/7xn0Ypy+pER/edCYQm4exbXj4WiySGp40P8UuTh6w1srg==} chai@5.3.3: resolution: {integrity: sha512-4zNhdJD/iOjSH0A05ea+Ke6MU5mmpQcbQsSOkgdaUMJ9zTlDTD/GYlwohmIE2u0gaxHYiVHEn1Fw9mZ/ktJWgw==} @@ -641,8 +641,8 @@ packages: resolution: {integrity: sha512-h5k/5U50IJJFpzfL6nO9jaaumfjO/f2NjK/oYB2Djzm4p9L+3T9qWpZqZ2hAbLPuuYq9wrU08WQyBTL5GbPk5Q==} engines: {node: '>=6'} - electron-to-chromium@1.5.263: - resolution: {integrity: sha512-DrqJ11Knd+lo+dv+lltvfMDLU27g14LMdH2b0O3Pio4uk0x+z7OR+JrmyacTPN2M8w3BrZ7/RTwG3R9B7irPlg==} + electron-to-chromium@1.5.286: + resolution: {integrity: sha512-9tfDXhJ4RKFNerfjdCcZfufu49vg620741MNs26a9+bhLThdB+plgMeou98CAaHu/WATj2iHOOHTp1hWtABj2A==} emoji-regex@8.0.0: resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} @@ -651,9 +651,16 @@ packages: resolution: {integrity: sha512-d4lC8xfavMeBjzGr2vECC3fsGXziXZQyJxD868h2M/mBI3PwAuODxAkLkq5HYuvrPYcUtiLzsTo8U3PgX3Ocww==} engines: {node: '>=10.13.0'} + enhanced-resolve@5.19.0: + resolution: {integrity: sha512-phv3E1Xl4tQOShqSte26C7Fl84EwUdZsyOuSSk9qtAGyyQs2s3jJzComh+Abf4g187lUUAvH+H26omrqia2aGg==} + engines: {node: '>=10.13.0'} + es-module-lexer@1.7.0: resolution: {integrity: sha512-jEQoCwk8hyb2AZziIOLhDqpm5+2ww5uIE6lkO/6jcOCusfk6LhMHpXXfBLXTZ7Ydyt0j4VoUQv6uGNYbdW+kBA==} + es-module-lexer@2.0.0: + resolution: {integrity: sha512-5POEcUuZybH7IdmGsD8wlf0AI55wMecM9rVBTI/qEAy2c1kTOm3DjFYjrBdI2K3BaJjJYfYFeRtM0t9ssnRuxw==} + esbuild@0.25.12: resolution: {integrity: sha512-bbPBYYrtZbkt6Os6FiTLCTFxvq4tt3JKall1vRwshA3fdVztsLAatFaZobhkBC8/BrPetoa0oksYoKXoG4ryJg==} engines: {node: '>=18'} @@ -932,8 +939,8 @@ packages: resolution: {integrity: sha512-g9ljZiwki/LfxmQADO3dEY1CbpmXT5Hm2fJ+QaGKwSXUylMybePR7/67YW7jOrrvjEgL1Fmz5kzyAjWVWLlucg==} engines: {node: '>=6'} - terser-webpack-plugin@5.3.14: - resolution: {integrity: sha512-vkZjpUjb6OMS7dhV+tILUW6BhpDR7P2L/aQSAv+Uwk+m8KATX9EccViHTJR2qDtACKPIYndLGCyl3FMo+r2LMw==} + terser-webpack-plugin@5.3.16: + resolution: {integrity: sha512-h9oBFCWrq78NyWWVcSwZarJkZ01c2AyGrzs1crmHZO3QUg9D61Wu4NPjBy69n7JqylFF5y+CsUZYmYEIZ3mR+Q==} engines: {node: '>= 10.13.0'} peerDependencies: '@swc/core': '*' @@ -948,8 +955,8 @@ packages: uglify-js: optional: true - terser@5.44.1: - resolution: {integrity: sha512-t/R3R/n0MSwnnazuPpPNVO60LX0SKL45pyl9YlvxIdkH0Of7D5qM2EVe+yASRIlY5pZ73nclYJfNANGWPwFDZw==} + terser@5.46.0: + resolution: {integrity: sha512-jTwoImyr/QbOWFFso3YoU3ik0jBBDJ6JTOQiy/J2YxVJdZCc+5u7skhNwiOR3FQIygFqVUPHl7qbbxtjW2K3Qg==} engines: {node: '>=10'} hasBin: true @@ -1009,8 +1016,8 @@ packages: undici-types@5.26.5: resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==} - update-browserslist-db@1.1.4: - resolution: {integrity: sha512-q0SPT4xyU84saUX+tomz1WLkxUbuaJnR1xWt17M7fJtEJigJeWUNGUqrauFXsHnqev9y9JTRGwk13tFBuKby4A==} + update-browserslist-db@1.2.3: + resolution: {integrity: sha512-Js0m9cx+qOgDxo0eMiFGEueWztz+d4+M3rGlmKPT+T4IS/jP4ylw3Nwpu6cpTTP8R1MAC1kF4VbdLt3ARf209w==} hasBin: true peerDependencies: browserslist: '>= 4.21.0' @@ -1088,16 +1095,16 @@ packages: jsdom: optional: true - watchpack@2.4.4: - resolution: {integrity: sha512-c5EGNOiyxxV5qmTtAB7rbiXxi1ooX1pQKMLX/MIabJjRA0SJBQOjKF+KSVfHkr9U1cADPon0mRiVe/riyaiDUA==} + watchpack@2.5.1: + resolution: {integrity: sha512-Zn5uXdcFNIA1+1Ei5McRd+iRzfhENPCe7LeABkJtNulSxjma+l7ltNx55BWZkRlwRnpOgHqxnjyaDgJnNXnqzg==} engines: {node: '>=10.13.0'} webpack-sources@3.3.3: resolution: {integrity: sha512-yd1RBzSGanHkitROoPFd6qsrxt+oFhg/129YzheDGqeustzX0vTZJZsSsQjVQC4yzBQ56K55XU8gaNCtIzOnTg==} engines: {node: '>=10.13.0'} - webpack@5.103.0: - resolution: {integrity: sha512-HU1JOuV1OavsZ+mfigY0j8d1TgQgbZ6M+J75zDkpEAwYeXjWSqrGJtgnPblJjd/mAyTNQ7ygw0MiKOn6etz8yw==} + webpack@5.104.1: + resolution: {integrity: sha512-Qphch25abbMNtekmEGJmeRUhLDbe+QfiWTiqpKYkpCOWY64v9eyl+KRRLmqOFA2AvKPpc9DC6+u2n76tQLBoaA==} engines: {node: '>=10.13.0'} hasBin: true peerDependencies: @@ -1426,14 +1433,14 @@ snapshots: chai: 5.3.3 tinyrainbow: 2.0.0 - '@vitest/mocker@3.2.4(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(vite@7.2.6(@types/node@18.19.130)(terser@5.44.1))': + '@vitest/mocker@3.2.4(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(vite@7.2.6(@types/node@18.19.130)(terser@5.46.0))': dependencies: '@vitest/spy': 3.2.4 estree-walker: 3.0.3 magic-string: 0.30.21 optionalDependencies: msw: 2.11.2(@types/node@18.19.130)(typescript@5.7.3) - vite: 7.2.6(@types/node@18.19.130)(terser@5.44.1) + vite: 7.2.6(@types/node@18.19.130)(terser@5.46.0) '@vitest/pretty-format@3.2.4': dependencies: @@ -1571,25 +1578,25 @@ snapshots: assertion-error@2.0.1: {} - baseline-browser-mapping@2.8.32: {} + baseline-browser-mapping@2.9.19: {} braces@3.0.3: dependencies: fill-range: 7.1.1 - browserslist@4.28.0: + browserslist@4.28.1: dependencies: - baseline-browser-mapping: 2.8.32 - caniuse-lite: 1.0.30001757 - electron-to-chromium: 1.5.263 + baseline-browser-mapping: 2.9.19 + caniuse-lite: 1.0.30001769 + electron-to-chromium: 1.5.286 node-releases: 2.0.27 - update-browserslist-db: 1.1.4(browserslist@4.28.0) + update-browserslist-db: 1.2.3(browserslist@4.28.1) buffer-from@1.1.2: {} cac@6.7.14: {} - caniuse-lite@1.0.30001757: {} + caniuse-lite@1.0.30001769: {} chai@5.3.3: dependencies: @@ -1632,7 +1639,7 @@ snapshots: deep-eql@5.0.2: {} - electron-to-chromium@1.5.263: {} + electron-to-chromium@1.5.286: {} emoji-regex@8.0.0: {} @@ -1641,8 +1648,15 @@ snapshots: graceful-fs: 4.2.11 tapable: 2.3.0 + enhanced-resolve@5.19.0: + dependencies: + graceful-fs: 4.2.11 + tapable: 2.3.0 + es-module-lexer@1.7.0: {} + es-module-lexer@2.0.0: {} + esbuild@0.25.12: optionalDependencies: '@esbuild/aix-ppc64': 0.25.12 @@ -1917,16 +1931,16 @@ snapshots: tapable@2.3.0: {} - terser-webpack-plugin@5.3.14(webpack@5.103.0): + terser-webpack-plugin@5.3.16(webpack@5.104.1): dependencies: '@jridgewell/trace-mapping': 0.3.31 jest-worker: 27.5.1 schema-utils: 4.3.3 serialize-javascript: 6.0.2 - terser: 5.44.1 - webpack: 5.103.0 + terser: 5.46.0 + webpack: 5.104.1 - terser@5.44.1: + terser@5.46.0: dependencies: '@jridgewell/source-map': 0.3.11 acorn: 8.15.0 @@ -1962,7 +1976,7 @@ snapshots: dependencies: tldts: 7.0.19 - ts-loader@9.5.4(typescript@5.7.3)(webpack@5.103.0): + ts-loader@9.5.4(typescript@5.7.3)(webpack@5.104.1): dependencies: chalk: 4.1.2 enhanced-resolve: 5.18.3 @@ -1970,7 +1984,7 @@ snapshots: semver: 7.7.3 source-map: 0.7.6 typescript: 5.7.3 - webpack: 5.103.0 + webpack: 5.104.1 type-fest@4.41.0: {} @@ -1978,19 +1992,19 @@ snapshots: undici-types@5.26.5: {} - update-browserslist-db@1.1.4(browserslist@4.28.0): + update-browserslist-db@1.2.3(browserslist@4.28.1): dependencies: - browserslist: 4.28.0 + browserslist: 4.28.1 escalade: 3.2.0 picocolors: 1.1.1 - vite-node@3.2.4(@types/node@18.19.130)(terser@5.44.1): + vite-node@3.2.4(@types/node@18.19.130)(terser@5.46.0): dependencies: cac: 6.7.14 debug: 4.4.3 es-module-lexer: 1.7.0 pathe: 2.0.3 - vite: 7.2.6(@types/node@18.19.130)(terser@5.44.1) + vite: 7.2.6(@types/node@18.19.130)(terser@5.46.0) transitivePeerDependencies: - '@types/node' - jiti @@ -2005,7 +2019,7 @@ snapshots: - tsx - yaml - vite@7.2.6(@types/node@18.19.130)(terser@5.44.1): + vite@7.2.6(@types/node@18.19.130)(terser@5.46.0): dependencies: esbuild: 0.25.12 fdir: 6.5.0(picomatch@4.0.3) @@ -2016,13 +2030,13 @@ snapshots: optionalDependencies: '@types/node': 18.19.130 fsevents: 2.3.3 - terser: 5.44.1 + terser: 5.46.0 - vitest@3.2.4(@types/node@18.19.130)(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(terser@5.44.1): + vitest@3.2.4(@types/node@18.19.130)(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(terser@5.46.0): dependencies: '@types/chai': 5.2.3 '@vitest/expect': 3.2.4 - '@vitest/mocker': 3.2.4(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(vite@7.2.6(@types/node@18.19.130)(terser@5.44.1)) + '@vitest/mocker': 3.2.4(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(vite@7.2.6(@types/node@18.19.130)(terser@5.46.0)) '@vitest/pretty-format': 3.2.4 '@vitest/runner': 3.2.4 '@vitest/snapshot': 3.2.4 @@ -2040,8 +2054,8 @@ snapshots: tinyglobby: 0.2.15 tinypool: 1.1.1 tinyrainbow: 2.0.0 - vite: 7.2.6(@types/node@18.19.130)(terser@5.44.1) - vite-node: 3.2.4(@types/node@18.19.130)(terser@5.44.1) + vite: 7.2.6(@types/node@18.19.130)(terser@5.46.0) + vite-node: 3.2.4(@types/node@18.19.130)(terser@5.46.0) why-is-node-running: 2.3.0 optionalDependencies: '@types/node': 18.19.130 @@ -2059,14 +2073,14 @@ snapshots: - tsx - yaml - watchpack@2.4.4: + watchpack@2.5.1: dependencies: glob-to-regexp: 0.4.1 graceful-fs: 4.2.11 webpack-sources@3.3.3: {} - webpack@5.103.0: + webpack@5.104.1: dependencies: '@types/eslint-scope': 3.7.7 '@types/estree': 1.0.8 @@ -2076,10 +2090,10 @@ snapshots: '@webassemblyjs/wasm-parser': 1.14.1 acorn: 8.15.0 acorn-import-phases: 1.0.4(acorn@8.15.0) - browserslist: 4.28.0 + browserslist: 4.28.1 chrome-trace-event: 1.0.4 - enhanced-resolve: 5.18.3 - es-module-lexer: 1.7.0 + enhanced-resolve: 5.19.0 + es-module-lexer: 2.0.0 eslint-scope: 5.1.1 events: 3.3.0 glob-to-regexp: 0.4.1 @@ -2090,8 +2104,8 @@ snapshots: neo-async: 2.6.2 schema-utils: 4.3.3 tapable: 2.3.0 - terser-webpack-plugin: 5.3.14(webpack@5.103.0) - watchpack: 2.4.4 + terser-webpack-plugin: 5.3.16(webpack@5.104.1) + watchpack: 2.5.1 webpack-sources: 3.3.3 transitivePeerDependencies: - '@swc/core' From 66905663565d841cdeb2e55396c4dbd67cdb2399 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 3 Jun 2026 12:01:59 +0000 Subject: [PATCH 144/146] Bump vitest from 3.2.4 to 4.1.0 (#522) Automatic merge of Dependabot PR --- package.json | 2 +- pnpm-lock.yaml | 586 +++++++++++++++++++++++-------------------------- 2 files changed, 271 insertions(+), 317 deletions(-) diff --git a/package.json b/package.json index 8bcf8e0c..4e22c764 100644 --- a/package.json +++ b/package.json @@ -46,7 +46,7 @@ "devDependencies": { "webpack": "^5.97.1", "ts-loader": "^9.5.1", - "vitest": "^3.2.4", + "vitest": "^4.1.0", "msw": "2.11.2", "@types/node": "^18.19.70", "typescript": "~5.7.2", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index b6c82556..114ce476 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -24,8 +24,8 @@ importers: specifier: ~5.7.2 version: 5.7.3 vitest: - specifier: ^3.2.4 - version: 3.2.4(@types/node@18.19.130)(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(terser@5.46.0) + specifier: ^4.1.0 + version: 4.1.0(@types/node@18.19.130)(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(vite@7.2.6(@types/node@18.19.130)(terser@5.46.0)) webpack: specifier: ^5.97.1 version: 5.104.1 @@ -54,24 +54,28 @@ packages: engines: {node: '>=14.21.3'} cpu: [arm64] os: [linux] + libc: [musl] '@biomejs/cli-linux-arm64@2.3.1': resolution: {integrity: sha512-td5O8pFIgLs8H1sAZsD6v+5quODihyEw4nv2R8z7swUfIK1FKk+15e4eiYVLcAE4jUqngvh4j3JCNgg0Y4o4IQ==} engines: {node: '>=14.21.3'} cpu: [arm64] os: [linux] + libc: [glibc] '@biomejs/cli-linux-x64-musl@2.3.1': resolution: {integrity: sha512-Y3Ob4nqgv38Mh+6EGHltuN+Cq8aj/gyMTJYzkFZV2AEj+9XzoXB9VNljz9pjfFNHUxvLEV4b55VWyxozQTBaUQ==} engines: {node: '>=14.21.3'} cpu: [x64] os: [linux] + libc: [musl] '@biomejs/cli-linux-x64@2.3.1': resolution: {integrity: sha512-PYWgEO7up7XYwSAArOpzsVCiqxBCXy53gsReAb1kKYIyXaoAlhBaBMvxR/k2Rm9aTuZ662locXUmPk/Aj+Xu+Q==} engines: {node: '>=14.21.3'} cpu: [x64] os: [linux] + libc: [glibc] '@biomejs/cli-win32-arm64@2.3.1': resolution: {integrity: sha512-RHIG/zgo+69idUqVvV3n8+j58dKYABRpMyDmfWu2TITC+jwGPiEaT0Q3RKD+kQHiS80mpBrST0iUGeEXT0bU9A==} @@ -311,116 +315,147 @@ packages: '@open-draft/until@2.1.0': resolution: {integrity: sha512-U69T3ItWHvLwGg5eJ0n3I62nWuE6ilHlmz7zM0npLBRvPRd7e6NYmg54vvRtP5mZG7kZqZCFVdsTWo7BPtBujg==} - '@rollup/rollup-android-arm-eabi@4.53.3': - resolution: {integrity: sha512-mRSi+4cBjrRLoaal2PnqH82Wqyb+d3HsPUN/W+WslCXsZsyHa9ZeQQX/pQsZaVIWDkPcpV6jJ+3KLbTbgnwv8w==} + '@rollup/rollup-android-arm-eabi@4.61.0': + resolution: {integrity: sha512-dnxczajOqt0gesZlN5pGQ1s1imQVrsmCw5G2Ci4oM+0WvNz3pyRnlWrT7McoZIb8VlFwCawdmbWRmxRn7HI+VQ==} cpu: [arm] os: [android] - '@rollup/rollup-android-arm64@4.53.3': - resolution: {integrity: sha512-CbDGaMpdE9sh7sCmTrTUyllhrg65t6SwhjlMJsLr+J8YjFuPmCEjbBSx4Z/e4SmDyH3aB5hGaJUP2ltV/vcs4w==} + '@rollup/rollup-android-arm64@4.61.0': + resolution: {integrity: sha512-Bp3JpGP00Vu3f238ivRrjf7z3xSzVPXqCmaJYA9t2c+c8vKYvOzmXF7LkkeUalTEGd6cZcSWe+PFIP3Vy48fRg==} cpu: [arm64] os: [android] - '@rollup/rollup-darwin-arm64@4.53.3': - resolution: {integrity: sha512-Nr7SlQeqIBpOV6BHHGZgYBuSdanCXuw09hon14MGOLGmXAFYjx1wNvquVPmpZnl0tLjg25dEdr4IQ6GgyToCUA==} + '@rollup/rollup-darwin-arm64@4.61.0': + resolution: {integrity: sha512-zaYIpr670mUmmZ1tVzUFplbQbG7h3Gugx3L5FoqhsC2m/YnLlR1a7zVLmXNPy+iY1tFPEbNG+HHBXZGyId0G5w==} cpu: [arm64] os: [darwin] - '@rollup/rollup-darwin-x64@4.53.3': - resolution: {integrity: sha512-DZ8N4CSNfl965CmPktJ8oBnfYr3F8dTTNBQkRlffnUarJ2ohudQD17sZBa097J8xhQ26AwhHJ5mvUyQW8ddTsQ==} + '@rollup/rollup-darwin-x64@4.61.0': + resolution: {integrity: sha512-+P49fvkv2dSoeevUW+lgZ/I2JHSsJCK1Lyjj7Cu6E4UHG4tS9XIefzIjo5qhgELjAclnen1rLzK2PMKJdo+Dyg==} cpu: [x64] os: [darwin] - '@rollup/rollup-freebsd-arm64@4.53.3': - resolution: {integrity: sha512-yMTrCrK92aGyi7GuDNtGn2sNW+Gdb4vErx4t3Gv/Tr+1zRb8ax4z8GWVRfr3Jw8zJWvpGHNpss3vVlbF58DZ4w==} + '@rollup/rollup-freebsd-arm64@4.61.0': + resolution: {integrity: sha512-l3FAAOyKJXH2ea6KNFN+MMgC/rnE94YGLXs2ehYqDcCoHt1DpvgWX75BhUJxN38XojP7Ul+4H8PRn7EdyqSDrw==} cpu: [arm64] os: [freebsd] - '@rollup/rollup-freebsd-x64@4.53.3': - resolution: {integrity: sha512-lMfF8X7QhdQzseM6XaX0vbno2m3hlyZFhwcndRMw8fbAGUGL3WFMBdK0hbUBIUYcEcMhVLr1SIamDeuLBnXS+Q==} + '@rollup/rollup-freebsd-x64@4.61.0': + resolution: {integrity: sha512-VokPN3TSctKj65cyCNPaUh4vMFA8awxOot/0sp+4J7ZlNRKQEhXhawqPwajoi8H5ZFt61i0ugZJuTKXBjGJ17Q==} cpu: [x64] os: [freebsd] - '@rollup/rollup-linux-arm-gnueabihf@4.53.3': - resolution: {integrity: sha512-k9oD15soC/Ln6d2Wv/JOFPzZXIAIFLp6B+i14KhxAfnq76ajt0EhYc5YPeX6W1xJkAdItcVT+JhKl1QZh44/qw==} + '@rollup/rollup-linux-arm-gnueabihf@4.61.0': + resolution: {integrity: sha512-DxH0P3wxm+Yzs/p3zrk9dw1rURu8p0Nv5+MRK/L7OtnLNg5rLZraSBFZ8iUXOd9f2BlhJyEpIZUH/emjq4UJ4g==} cpu: [arm] os: [linux] + libc: [glibc] - '@rollup/rollup-linux-arm-musleabihf@4.53.3': - resolution: {integrity: sha512-vTNlKq+N6CK/8UktsrFuc+/7NlEYVxgaEgRXVUVK258Z5ymho29skzW1sutgYjqNnquGwVUObAaxae8rZ6YMhg==} + '@rollup/rollup-linux-arm-musleabihf@4.61.0': + resolution: {integrity: sha512-T6ZvMNe84kAz6TBWHC7hGAoEtzP1LWYw/AqayGWEF6uISt3Abk/st06LqRD9THd7Xz3NxzurUpzAuEAUbZf+nw==} cpu: [arm] os: [linux] + libc: [musl] - '@rollup/rollup-linux-arm64-gnu@4.53.3': - resolution: {integrity: sha512-RGrFLWgMhSxRs/EWJMIFM1O5Mzuz3Xy3/mnxJp/5cVhZ2XoCAxJnmNsEyeMJtpK+wu0FJFWz+QF4mjCA7AUQ3w==} + '@rollup/rollup-linux-arm64-gnu@4.61.0': + resolution: {integrity: sha512-q/4hzvQkDs8b4jIBab1pnLiiM0ayTZsN2amBFPDzuyZxjEd4wDwx0UJFYM3cOZzSf5Kw8fnWSprJzIBMkcR44Q==} cpu: [arm64] os: [linux] + libc: [glibc] - '@rollup/rollup-linux-arm64-musl@4.53.3': - resolution: {integrity: sha512-kASyvfBEWYPEwe0Qv4nfu6pNkITLTb32p4yTgzFCocHnJLAHs+9LjUu9ONIhvfT/5lv4YS5muBHyuV84epBo/A==} + '@rollup/rollup-linux-arm64-musl@4.61.0': + resolution: {integrity: sha512-vvYWX3akdEAY6km+9wAqFDnk6pQsbJKVnj7xawcvs/+fdlYBGp+U+Qq/lLfpIxYIZvZLHMAKD9HLdacSx/r3dw==} cpu: [arm64] os: [linux] + libc: [musl] - '@rollup/rollup-linux-loong64-gnu@4.53.3': - resolution: {integrity: sha512-JiuKcp2teLJwQ7vkJ95EwESWkNRFJD7TQgYmCnrPtlu50b4XvT5MOmurWNrCj3IFdyjBQ5p9vnrX4JM6I8OE7g==} + '@rollup/rollup-linux-loong64-gnu@4.61.0': + resolution: {integrity: sha512-DePa5cqOxDP/Zp0VOXpeWaGew5iIv5DXp9NYbzkX5PFQyWVX9184WCTh3hvr/7lhXo8ZVlbFLkz8+o/q1dU6gA==} cpu: [loong64] os: [linux] + libc: [glibc] - '@rollup/rollup-linux-ppc64-gnu@4.53.3': - resolution: {integrity: sha512-EoGSa8nd6d3T7zLuqdojxC20oBfNT8nexBbB/rkxgKj5T5vhpAQKKnD+h3UkoMuTyXkP5jTjK/ccNRmQrPNDuw==} + '@rollup/rollup-linux-loong64-musl@4.61.0': + resolution: {integrity: sha512-LV8aWMB8UChglMCEzs7RkN0GsH29RJaLLqwm9fCIjlqwxQTiWAqNcc7wjBkH31hV0PU/yVxGYvrYsgfea2qw6g==} + cpu: [loong64] + os: [linux] + libc: [musl] + + '@rollup/rollup-linux-ppc64-gnu@4.61.0': + resolution: {integrity: sha512-QoNSnwQtaeNu5grdBbsL0tt1uyl5EnS8DA8Mr3nluMXbhdQNyhN+G4tBax7VCdxLKj8YJ0/4OO9Ho84jMnJtKA==} + cpu: [ppc64] + os: [linux] + libc: [glibc] + + '@rollup/rollup-linux-ppc64-musl@4.61.0': + resolution: {integrity: sha512-/zZp5MKapIIApE8trN8qLGNSiRN9TUoaUZ1cmVu4XnVdd5LQLOXTtyi+vtfUbNnT3iyjzpPqYeKXmvJ+gJGYWw==} cpu: [ppc64] os: [linux] + libc: [musl] - '@rollup/rollup-linux-riscv64-gnu@4.53.3': - resolution: {integrity: sha512-4s+Wped2IHXHPnAEbIB0YWBv7SDohqxobiiPA1FIWZpX+w9o2i4LezzH/NkFUl8LRci/8udci6cLq+jJQlh+0g==} + '@rollup/rollup-linux-riscv64-gnu@4.61.0': + resolution: {integrity: sha512-RbrzcD3aJ1k3UbtMRRBNwojdVVyXjuVAFTfn/xPa6EEl6GE9Sm/akPgFTb9aAC9pMKGJ6CtWxaGrqWcabH+ySg==} cpu: [riscv64] os: [linux] + libc: [glibc] - '@rollup/rollup-linux-riscv64-musl@4.53.3': - resolution: {integrity: sha512-68k2g7+0vs2u9CxDt5ktXTngsxOQkSEV/xBbwlqYcUrAVh6P9EgMZvFsnHy4SEiUl46Xf0IObWVbMvPrr2gw8A==} + '@rollup/rollup-linux-riscv64-musl@4.61.0': + resolution: {integrity: sha512-ZF+onDsBso8PJf1XaG9lB+O9RnBpKGnY6OrzC4CSHrtC1jb6jWLTKK4bRqdoCXHd22gyr2hiYmEAm8Wns/BOCw==} cpu: [riscv64] os: [linux] + libc: [musl] - '@rollup/rollup-linux-s390x-gnu@4.53.3': - resolution: {integrity: sha512-VYsFMpULAz87ZW6BVYw3I6sWesGpsP9OPcyKe8ofdg9LHxSbRMd7zrVrr5xi/3kMZtpWL/wC+UIJWJYVX5uTKg==} + '@rollup/rollup-linux-s390x-gnu@4.61.0': + resolution: {integrity: sha512-Atk0aSIk5Zx2Wuh9dgRQgLP0Koc8hOeYpbWryMXyk8G8/HmPkwPPkMqIIDhrXHHYqfUzSJA/I7IWSBv8xSmRBA==} cpu: [s390x] os: [linux] + libc: [glibc] - '@rollup/rollup-linux-x64-gnu@4.53.3': - resolution: {integrity: sha512-3EhFi1FU6YL8HTUJZ51imGJWEX//ajQPfqWLI3BQq4TlvHy4X0MOr5q3D2Zof/ka0d5FNdPwZXm3Yyib/UEd+w==} + '@rollup/rollup-linux-x64-gnu@4.61.0': + resolution: {integrity: sha512-0uMOcf3eZ5K+K4cYHkdxShFMPlPXCOdfDFEFn9dNYAEEd2cVvmOfH7zFgRVoDgmtQ1m9k5q7qfrHzyMAubKYUA==} cpu: [x64] os: [linux] + libc: [glibc] - '@rollup/rollup-linux-x64-musl@4.53.3': - resolution: {integrity: sha512-eoROhjcc6HbZCJr+tvVT8X4fW3/5g/WkGvvmwz/88sDtSJzO7r/blvoBDgISDiCjDRZmHpwud7h+6Q9JxFwq1Q==} + '@rollup/rollup-linux-x64-musl@4.61.0': + resolution: {integrity: sha512-mvFtE4A/t/7hRJ7X8Ozmu8FsIkAUat2nzl12pgU337BRmq87AQUJztwHz2Zv5/tjo9/C95E66CK03SI/ToEDJw==} cpu: [x64] os: [linux] + libc: [musl] - '@rollup/rollup-openharmony-arm64@4.53.3': - resolution: {integrity: sha512-OueLAWgrNSPGAdUdIjSWXw+u/02BRTcnfw9PN41D2vq/JSEPnJnVuBgw18VkN8wcd4fjUs+jFHVM4t9+kBSNLw==} + '@rollup/rollup-openbsd-x64@4.61.0': + resolution: {integrity: sha512-z9b9+aTxvt8n2rNltMPvyaUfB8NJ+CVyOrGK/MdIKHx7B+lXmZpm/XbRsU7Rpf3fRqJ2uS6mBJiJveCtq8LHDg==} + cpu: [x64] + os: [openbsd] + + '@rollup/rollup-openharmony-arm64@4.61.0': + resolution: {integrity: sha512-jXaXFqKMehsOc+g8R6oo33RRC6w07G9jDBxAE5eAKX7mOcCbZloYIPNhfG9Wl+P9O9IWHFO4OJgPi1Ml2qkt7w==} cpu: [arm64] os: [openharmony] - '@rollup/rollup-win32-arm64-msvc@4.53.3': - resolution: {integrity: sha512-GOFuKpsxR/whszbF/bzydebLiXIHSgsEUp6M0JI8dWvi+fFa1TD6YQa4aSZHtpmh2/uAlj/Dy+nmby3TJ3pkTw==} + '@rollup/rollup-win32-arm64-msvc@4.61.0': + resolution: {integrity: sha512-OXNWVFocS2IA4+QplhTZZ2a+8hPZR7T8KuozsNmJKK8y7cp83StHvGksfHzPG3wczWTczyWHVQuqeiTUbjiyBg==} cpu: [arm64] os: [win32] - '@rollup/rollup-win32-ia32-msvc@4.53.3': - resolution: {integrity: sha512-iah+THLcBJdpfZ1TstDFbKNznlzoxa8fmnFYK4V67HvmuNYkVdAywJSoteUszvBQ9/HqN2+9AZghbajMsFT+oA==} + '@rollup/rollup-win32-ia32-msvc@4.61.0': + resolution: {integrity: sha512-AlAbNtBO637LxSldqV43z0FfXoGfl2TW1DgAg/bs7aQswFbDewz2SJm3BUhiGfbOVtW571xbc9p+REdxhyN/Eg==} cpu: [ia32] os: [win32] - '@rollup/rollup-win32-x64-gnu@4.53.3': - resolution: {integrity: sha512-J9QDiOIZlZLdcot5NXEepDkstocktoVjkaKUtqzgzpt2yWjGlbYiKyp05rWwk4nypbYUNoFAztEgixoLaSETkg==} + '@rollup/rollup-win32-x64-gnu@4.61.0': + resolution: {integrity: sha512-QRSrQXyJ1M4tjNXdR0/G/IgV6lzfQQJYBjlWIEYkY2Xs86DRl/iEpQ4blMDjJxSl7n19eDKKXMg0AmuBVYy8pQ==} cpu: [x64] os: [win32] - '@rollup/rollup-win32-x64-msvc@4.53.3': - resolution: {integrity: sha512-UhTd8u31dXadv0MopwGgNOBpUVROFKWVQgAg5N1ESyCz8AuBcMqm4AuTjrwgQKGDfoFuz02EuMRHQIw/frmYKQ==} + '@rollup/rollup-win32-x64-msvc@4.61.0': + resolution: {integrity: sha512-tkuFxhvKO/HlGd0VsINF6vHSYH8AF8W0TcNxKDK6JZmrehngFj78pToc8iemtnvwilDjs2G/qSzYFhe9U8q+fw==} cpu: [x64] os: [win32] + '@standard-schema/spec@1.1.0': + resolution: {integrity: sha512-l2aFy5jALhniG5HgqrD6jXLi/rUWrKvqN/qJx6yoJsgKhblVd+iqqU4RCXavm/jPityDo5TCvKMnpjKnOriy0w==} + '@types/chai@5.2.3': resolution: {integrity: sha512-Mw558oeA9fFbv65/y4mHtXDs9bPnFMZAL/jxdPFUpOHHIXX91mcgEHbS5Lahr+pwZFR8A7GQleRWeI6cGFC2UA==} @@ -439,6 +474,9 @@ packages: '@types/estree@1.0.8': resolution: {integrity: sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w==} + '@types/estree@1.0.9': + resolution: {integrity: sha512-GhdPgy1el4/ImP05X05Uw4cw2/M93BCUmnEvWZNStlCzEKME4Fkk+YpoA5OiHNQmoS7Cafb8Xa3Pya8m1Qrzeg==} + '@types/json-schema@7.0.15': resolution: {integrity: sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==} @@ -448,34 +486,34 @@ packages: '@types/statuses@2.0.6': resolution: {integrity: sha512-xMAgYwceFhRA2zY+XbEA7mxYbA093wdiW8Vu6gZPGWy9cmOyU9XesH1tNcEWsKFd5Vzrqx5T3D38PWx1FIIXkA==} - '@vitest/expect@3.2.4': - resolution: {integrity: sha512-Io0yyORnB6sikFlt8QW5K7slY4OjqNX9jmJQ02QDda8lyM6B5oNgVWoSoKPac8/kgnCUzuHQKrSLtu/uOqqrig==} + '@vitest/expect@4.1.0': + resolution: {integrity: sha512-EIxG7k4wlWweuCLG9Y5InKFwpMEOyrMb6ZJ1ihYu02LVj/bzUwn2VMU+13PinsjRW75XnITeFrQBMH5+dLvCDA==} - '@vitest/mocker@3.2.4': - resolution: {integrity: sha512-46ryTE9RZO/rfDd7pEqFl7etuyzekzEhUbTW3BvmeO/BcCMEgq59BKhek3dXDWgAj4oMK6OZi+vRr1wPW6qjEQ==} + '@vitest/mocker@4.1.0': + resolution: {integrity: sha512-evxREh+Hork43+Y4IOhTo+h5lGmVRyjqI739Rz4RlUPqwrkFFDF6EMvOOYjTx4E8Tl6gyCLRL8Mu7Ry12a13Tw==} peerDependencies: msw: ^2.4.9 - vite: ^5.0.0 || ^6.0.0 || ^7.0.0-0 + vite: ^6.0.0 || ^7.0.0 || ^8.0.0-0 peerDependenciesMeta: msw: optional: true vite: optional: true - '@vitest/pretty-format@3.2.4': - resolution: {integrity: sha512-IVNZik8IVRJRTr9fxlitMKeJeXFFFN0JaB9PHPGQ8NKQbGpfjlTx9zO4RefN8gp7eqjNy8nyK3NZmBzOPeIxtA==} + '@vitest/pretty-format@4.1.0': + resolution: {integrity: sha512-3RZLZlh88Ib0J7NQTRATfc/3ZPOnSUn2uDBUoGNn5T36+bALixmzphN26OUD3LRXWkJu4H0s5vvUeqBiw+kS0A==} - '@vitest/runner@3.2.4': - resolution: {integrity: sha512-oukfKT9Mk41LreEW09vt45f8wx7DordoWUZMYdY/cyAk7w5TWkTRCNZYF7sX7n2wB7jyGAl74OxgwhPgKaqDMQ==} + '@vitest/runner@4.1.0': + resolution: {integrity: sha512-Duvx2OzQ7d6OjchL+trw+aSrb9idh7pnNfxrklo14p3zmNL4qPCDeIJAK+eBKYjkIwG96Bc6vYuxhqDXQOWpoQ==} - '@vitest/snapshot@3.2.4': - resolution: {integrity: sha512-dEYtS7qQP2CjU27QBC5oUOxLE/v5eLkGqPE0ZKEIDGMs4vKWe7IjgLOeauHsR0D5YuuycGRO5oSRXnwnmA78fQ==} + '@vitest/snapshot@4.1.0': + resolution: {integrity: sha512-0Vy9euT1kgsnj1CHttwi9i9o+4rRLEaPRSOJ5gyv579GJkNpgJK+B4HSv/rAWixx2wdAFci1X4CEPjiu2bXIMg==} - '@vitest/spy@3.2.4': - resolution: {integrity: sha512-vAfasCOe6AIK70iP5UD11Ac4siNUNJ9i/9PZ3NKx07sG6sUxeag1LWdNrMWeKKYBLlzuK+Gn65Yd5nyL6ds+nw==} + '@vitest/spy@4.1.0': + resolution: {integrity: sha512-pz77k+PgNpyMDv2FV6qmk5ZVau6c3R8HC8v342T2xlFxQKTrSeYw9waIJG8KgV9fFwAtTu4ceRzMivPTH6wSxw==} - '@vitest/utils@3.2.4': - resolution: {integrity: sha512-fB2V0JFrQSMsCo9HiSq3Ezpdv4iYaXRG1Sx8edX3MwxfyNn83mKiGzOcH+Fkxt4MHxr3y42fQi1oeAInqgX2QA==} + '@vitest/utils@4.1.0': + resolution: {integrity: sha512-XfPXT6a8TZY3dcGY8EdwsBulFCIw+BeeX0RZn2x/BtiY/75YGh8FeWGG8QISN/WhaqSrE2OrlDgtF8q5uhOTmw==} '@webassemblyjs/ast@1.14.1': resolution: {integrity: sha512-nuBEDgQfm1ccRp/8bCQrx1frohyufl4JlbMMZ4P1wpeOfDhF6FQkxZJ1b/e+PLwr6X1Nhw6OLme5usuBWYBvuQ==} @@ -583,25 +621,17 @@ packages: buffer-from@1.1.2: resolution: {integrity: sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==} - cac@6.7.14: - resolution: {integrity: sha512-b6Ilus+c3RrdDk+JhLKUAQfzzgLEPy6wcXqS7f/xe1EETvsDP6GORG7SFuOs6cID5YkqchW/LXZbX5bc8j7ZcQ==} - engines: {node: '>=8'} - caniuse-lite@1.0.30001769: resolution: {integrity: sha512-BCfFL1sHijQlBGWBMuJyhZUhzo7wer5sVj9hqekB/7xn0Ypy+pER/edCYQm4exbXj4WiySGp40P8UuTh6w1srg==} - chai@5.3.3: - resolution: {integrity: sha512-4zNhdJD/iOjSH0A05ea+Ke6MU5mmpQcbQsSOkgdaUMJ9zTlDTD/GYlwohmIE2u0gaxHYiVHEn1Fw9mZ/ktJWgw==} + chai@6.2.2: + resolution: {integrity: sha512-NUPRluOfOiTKBKvWPtSD4PhFvWCqOi0BGStNWs57X9js7XGTprSmFoz5F0tWhR4WPjNeR9jXqdC7/UpSJTnlRg==} engines: {node: '>=18'} chalk@4.1.2: resolution: {integrity: sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==} engines: {node: '>=10'} - check-error@2.1.1: - resolution: {integrity: sha512-OAlb+T7V4Op9OwdkjmguYRqncdlx5JiofwOAUkmTF+jNdHwzTaTs4sRAGpzLF3oOz5xAyDGrPgeIDFQmDOTiJw==} - engines: {node: '>= 16'} - chrome-trace-event@1.0.4: resolution: {integrity: sha512-rNjApaLzuwaOTjCiT8lSDdGN1APCiqkChLMJxJPWLunPAt5fy8xgU9/jNOchV84wfIxrA0lRQB7oCT8jrn/wrQ==} engines: {node: '>=6.0'} @@ -624,23 +654,13 @@ packages: commander@2.20.3: resolution: {integrity: sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==} + convert-source-map@2.0.0: + resolution: {integrity: sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==} + cookie@0.7.2: resolution: {integrity: sha512-yki5XnKuf750l50uGTllt6kKILY4nQ1eNIQatoXEByZ5dWgnKqbnqmTrBE5B4N7lrMJKQ2ytWMiTO2o0v6Ew/w==} engines: {node: '>= 0.6'} - debug@4.4.3: - resolution: {integrity: sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==} - engines: {node: '>=6.0'} - peerDependencies: - supports-color: '*' - peerDependenciesMeta: - supports-color: - optional: true - - deep-eql@5.0.2: - resolution: {integrity: sha512-h5k/5U50IJJFpzfL6nO9jaaumfjO/f2NjK/oYB2Djzm4p9L+3T9qWpZqZ2hAbLPuuYq9wrU08WQyBTL5GbPk5Q==} - engines: {node: '>=6'} - electron-to-chromium@1.5.286: resolution: {integrity: sha512-9tfDXhJ4RKFNerfjdCcZfufu49vg620741MNs26a9+bhLThdB+plgMeou98CAaHu/WATj2iHOOHTp1hWtABj2A==} @@ -655,12 +675,12 @@ packages: resolution: {integrity: sha512-phv3E1Xl4tQOShqSte26C7Fl84EwUdZsyOuSSk9qtAGyyQs2s3jJzComh+Abf4g187lUUAvH+H26omrqia2aGg==} engines: {node: '>=10.13.0'} - es-module-lexer@1.7.0: - resolution: {integrity: sha512-jEQoCwk8hyb2AZziIOLhDqpm5+2ww5uIE6lkO/6jcOCusfk6LhMHpXXfBLXTZ7Ydyt0j4VoUQv6uGNYbdW+kBA==} - es-module-lexer@2.0.0: resolution: {integrity: sha512-5POEcUuZybH7IdmGsD8wlf0AI55wMecM9rVBTI/qEAy2c1kTOm3DjFYjrBdI2K3BaJjJYfYFeRtM0t9ssnRuxw==} + es-module-lexer@2.1.0: + resolution: {integrity: sha512-n27zTYMjYu1aj4MjCWzSP7G9r75utsaoc8m61weK+W8JMBGGQybd43GstCXZ3WNmSFtGT9wi59qQTW6mhTR5LQ==} + esbuild@0.25.12: resolution: {integrity: sha512-bbPBYYrtZbkt6Os6FiTLCTFxvq4tt3JKall1vRwshA3fdVztsLAatFaZobhkBC8/BrPetoa0oksYoKXoG4ryJg==} engines: {node: '>=18'} @@ -693,8 +713,8 @@ packages: resolution: {integrity: sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==} engines: {node: '>=0.8.x'} - expect-type@1.2.2: - resolution: {integrity: sha512-JhFGDVJ7tmDJItKhYgJCGLOWjuK9vPxiXoUFLwLDc99NlmklilbiQJwoctZtt13+xMw91MCk/REan6MWHqDjyA==} + expect-type@1.3.0: + resolution: {integrity: sha512-knvyeauYhqjOYvQ66MznSMs83wmHrCycNEN6Ao+2AeYEfxUIkuiVxdEa1qlGEPK+We3n0THiDciYSsCcgW/DoA==} engines: {node: '>=12.0.0'} fast-deep-equal@3.1.3: @@ -757,9 +777,6 @@ packages: resolution: {integrity: sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg==} engines: {node: '>= 10.13.0'} - js-tokens@9.0.1: - resolution: {integrity: sha512-mxa9E9ITFOt0ban3j6L5MpjwegGz6lBQmM1IJkWeBZGcMxto50+eWdjC/52xDbS2vy0k7vIMK0Fe2wfL9OQSpQ==} - json-parse-even-better-errors@2.3.1: resolution: {integrity: sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==} @@ -770,9 +787,6 @@ packages: resolution: {integrity: sha512-IWqP2SCPhyVFTBtRcgMHdzlf9ul25NwaFx4wCEH/KjAXuuHY4yNjvPXsBokp8jCB936PyWRaPKUNh8NvylLp2Q==} engines: {node: '>=6.11.5'} - loupe@3.2.1: - resolution: {integrity: sha512-CdzqowRJCeLU72bHvWqwRBBlLcMEtIvGrlvef74kMnV2AolS9Y8xUv1I0U/MNAWMhBlKIoyuEgoJ0t/bbwHbLQ==} - magic-string@0.30.21: resolution: {integrity: sha512-vd2F4YUyEXKGcLHoq+TEyCjxueSeHnFxyyjNp80yg0XV4vUhnDer/lvvlqM/arB5bXQN5K2/3oinyCRyx8T2CQ==} @@ -791,9 +805,6 @@ packages: resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==} engines: {node: '>= 0.6'} - ms@2.1.3: - resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==} - msw@2.11.2: resolution: {integrity: sha512-MI54hLCsrMwiflkcqlgYYNJJddY5/+S0SnONvhv1owOplvqohKSQyGejpNdUGyCwgs4IH7PqaNbPw/sKOEze9Q==} engines: {node: '>=18'} @@ -808,8 +819,8 @@ packages: resolution: {integrity: sha512-WWdIxpyjEn+FhQJQQv9aQAYlHoNVdzIzUySNV1gHUPDSdZJ3yZn7pAAbQcV7B56Mvu881q9FZV+0Vx2xC44VWA==} engines: {node: ^18.17.0 || >=20.5.0} - nanoid@3.3.11: - resolution: {integrity: sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==} + nanoid@3.3.12: + resolution: {integrity: sha512-ZB9RH/39qpq5Vu6Y+NmUaFhQR6pp+M2Xt76XBnEwDaGcVAqhlvxrl3B2bKS5D3NH3QR76v3aSrKaF/Kiy7lEtQ==} engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} hasBin: true @@ -819,6 +830,9 @@ packages: node-releases@2.0.27: resolution: {integrity: sha512-nmh3lCkYZ3grZvqcCH+fjmQ7X+H0OeZgP40OierEaAptX4XofMh5kwNbWh7lBduUzCcV/8kZ+NDLCwm2iorIlA==} + obug@2.1.1: + resolution: {integrity: sha512-uTqF9MuPraAQ+IsnPf366RG4cP9RtUi7MLO1N3KEc+wb0a6yKpeL0lmk2IB1jY5KHPAlTc6T/JRdC/YqxHNwkQ==} + outvariant@1.4.3: resolution: {integrity: sha512-+Sl2UErvtsoajRDKCE5/dBz4DIvHXQQnAxtQTF04OJxY0+DyZXSo5P5Bb7XYWOh81syohlYL24hbDwxedPUJCA==} @@ -828,10 +842,6 @@ packages: pathe@2.0.3: resolution: {integrity: sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==} - pathval@2.0.1: - resolution: {integrity: sha512-//nshmD55c46FuFw26xV/xFAaB5HF9Xdap7HJBBnrKdAd6/GxDBaNA1870O79+9ueg61cZLSVc+OaFlfmObYVQ==} - engines: {node: '>= 14.16'} - picocolors@1.1.1: resolution: {integrity: sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==} @@ -839,12 +849,12 @@ packages: resolution: {integrity: sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==} engines: {node: '>=8.6'} - picomatch@4.0.3: - resolution: {integrity: sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==} + picomatch@4.0.4: + resolution: {integrity: sha512-QP88BAKvMam/3NxH6vj2o21R6MjxZUAd6nlwAS/pnGvN9IVLocLHxGYIzFhg6fUQ+5th6P4dv4eW9jX3DSIj7A==} engines: {node: '>=12'} - postcss@8.5.6: - resolution: {integrity: sha512-3Ybi1tAuwAP9s0r1UQ2J4n5Y0G05bJkpUIO0/bI9MhwmD70S5aTWbXGBwxHrelT+XM1k6dM0pk+SwNkpTRN7Pg==} + postcss@8.5.15: + resolution: {integrity: sha512-FfR8sjd4em2T6fb3I2MwAJU7HWVMr9zba+enmQeeWFfCbm+UOC/0X4DS8XtpUTMwWMGbjKYP7xjfNekzyGmB3A==} engines: {node: ^10 || ^12 || >=14} randombytes@2.1.0: @@ -861,8 +871,8 @@ packages: rettime@0.7.0: resolution: {integrity: sha512-LPRKoHnLKd/r3dVxcwO7vhCW+orkOGj9ViueosEBK6ie89CijnfRlhaDhHq/3Hxu4CkWQtxwlBG0mzTQY6uQjw==} - rollup@4.53.3: - resolution: {integrity: sha512-w8GmOxZfBmKknvdXU1sdM9NHcoQejwF/4mNgj2JuEEdRaHwwF12K7e9eXn1nLZ07ad+du76mkVsyeb2rKGllsA==} + rollup@4.61.0: + resolution: {integrity: sha512-T9mWdbWfQtp0B5lv/HX+wrhYsmXRlcWnXXmJbXqKJhlRaoS6KMhq0gpyzW4UJfclcxrEdLnTgjT2NjruLONu0g==} engines: {node: '>=18.0.0', npm: '>=8.0.0'} hasBin: true @@ -910,8 +920,8 @@ packages: resolution: {integrity: sha512-DvEy55V3DB7uknRo+4iOGT5fP1slR8wQohVdknigZPMpMstaKJQWhwiYBACJE3Ul2pTnATihhBYnRhZQHGBiRw==} engines: {node: '>= 0.8'} - std-env@3.10.0: - resolution: {integrity: sha512-5GS12FdOZNliM5mAOxFRg7Ir0pWz8MdpYm6AY6VPkGpbA7ZzmbzNcBJQ0GPvvyWgcY7QAhCgf9Uy89I03faLkg==} + std-env@4.1.0: + resolution: {integrity: sha512-Rq7ybcX2RuC55r9oaPVEW7/xu3tj8u4GeBYHBWCychFtzMIr86A7e3PPEBPT37sHStKX3+TiX/Fr/ACmJLVlLQ==} strict-event-emitter@0.5.1: resolution: {integrity: sha512-vMgjE/GGEPEFnhFub6pa4FmJBRBVOLpIII2hvCZ8Kzb7K0hlHo7mQv6xYrBvCL2LtAIBwFUK8wvuJgTVSQ5MFQ==} @@ -924,9 +934,6 @@ packages: resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==} engines: {node: '>=8'} - strip-literal@3.1.0: - resolution: {integrity: sha512-8r3mkIM/2+PpjHoOtiAW8Rg3jJLHaV7xPwG+YRGrv6FP0wwk/toTpATxWYOW0BKdWwl82VT2tFYi5DlROa0Mxg==} - supports-color@7.2.0: resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} engines: {node: '>=8'} @@ -963,23 +970,16 @@ packages: tinybench@2.9.0: resolution: {integrity: sha512-0+DUvqWMValLmha6lr4kD8iAMK1HzV0/aKnCtWb9v9641TnP/MFb7Pc2bxoxQjTXAErryXVgUOfv2YqNllqGeg==} - tinyexec@0.3.2: - resolution: {integrity: sha512-KQQR9yN7R5+OSwaK0XQoj22pwHoTlgYqmUscPYoknOoWCWfj/5/ABTMRi69FrKU5ffPVh5QcFikpWJI/P1ocHA==} + tinyexec@1.2.4: + resolution: {integrity: sha512-SHf/r48b7vOrjve9PxJo3MN5v5yuyjHvdUcrQffT3WXMUfnGmHDVbC4k3sHJaJTgZCwpUplIaAo5ANtMyp3YHg==} + engines: {node: '>=18'} - tinyglobby@0.2.15: - resolution: {integrity: sha512-j2Zq4NyQYG5XMST4cbs02Ak8iJUdxRM0XI5QyxXuZOzKOINmWurp3smXu3y5wDcJrptwpSjgXHzIQxR0omXljQ==} + tinyglobby@0.2.17: + resolution: {integrity: sha512-wXR/dYpcqKmfWpEdZjiKJOwCNFndD0DMnrW/cYjVGttEkBfVgcLFHoNrlj47mjOVic9yyNu65alsgF4NQyTa2g==} engines: {node: '>=12.0.0'} - tinypool@1.1.1: - resolution: {integrity: sha512-Zba82s87IFq9A9XmjiX5uZA/ARWDrB03OHlq+Vw1fSdt0I+4/Kutwy8BP4Y/y/aORMo61FQ0vIb5j44vSo5Pkg==} - engines: {node: ^18.0.0 || >=20.0.0} - - tinyrainbow@2.0.0: - resolution: {integrity: sha512-op4nsTR47R6p0vMUUoYl/a+ljLFVtlfaXkLQmqfLR1qHma1h/ysYk4hEXZ880bf2CYgTskvTa/e196Vd5dDQXw==} - engines: {node: '>=14.0.0'} - - tinyspy@4.0.4: - resolution: {integrity: sha512-azl+t0z7pw/z958Gy9svOTuzqIk6xq+NSheJzn5MMWtWTFywIacg2wUlzKFGtt3cthx0r2SxMK0yzJOR0IES7Q==} + tinyrainbow@3.1.0: + resolution: {integrity: sha512-Bf+ILmBgretUrdJxzXM0SgXLZ3XfiaUuOj/IKQHuTXip+05Xn+uyEYdVg0kYDipTBcLrCVyUzAPz7QmArb0mmw==} engines: {node: '>=14.0.0'} tldts-core@7.0.19: @@ -1022,11 +1022,6 @@ packages: peerDependencies: browserslist: '>= 4.21.0' - vite-node@3.2.4: - resolution: {integrity: sha512-EbKSKh+bh1E1IFxeO0pg1n4dvoOTt0UDiXMd/qn++r98+jPO1xtJilvXldeuQ8giIB5IkpjCgMleHMNEsGH6pg==} - engines: {node: ^18.0.0 || ^20.0.0 || >=22.0.0} - hasBin: true - vite@7.2.6: resolution: {integrity: sha512-tI2l/nFHC5rLh7+5+o7QjKjSR04ivXDF4jcgV0f/bTQ+OJiITy5S6gaynVsEM+7RqzufMnVbIon6Sr5x1SDYaQ==} engines: {node: ^20.19.0 || >=22.12.0} @@ -1067,26 +1062,33 @@ packages: yaml: optional: true - vitest@3.2.4: - resolution: {integrity: sha512-LUCP5ev3GURDysTWiP47wRRUpLKMOfPh+yKTx3kVIEiu5KOMeqzpnYNsKyOoVrULivR8tLcks4+lga33Whn90A==} - engines: {node: ^18.0.0 || ^20.0.0 || >=22.0.0} + vitest@4.1.0: + resolution: {integrity: sha512-YbDrMF9jM2Lqc++2530UourxZHmkKLxrs4+mYhEwqWS97WJ7wOYEkcr+QfRgJ3PW9wz3odRijLZjHEaRLTNbqw==} + engines: {node: ^20.0.0 || ^22.0.0 || >=24.0.0} hasBin: true peerDependencies: '@edge-runtime/vm': '*' - '@types/debug': ^4.1.12 - '@types/node': ^18.0.0 || ^20.0.0 || >=22.0.0 - '@vitest/browser': 3.2.4 - '@vitest/ui': 3.2.4 + '@opentelemetry/api': ^1.9.0 + '@types/node': ^20.0.0 || ^22.0.0 || >=24.0.0 + '@vitest/browser-playwright': 4.1.0 + '@vitest/browser-preview': 4.1.0 + '@vitest/browser-webdriverio': 4.1.0 + '@vitest/ui': 4.1.0 happy-dom: '*' jsdom: '*' + vite: ^6.0.0 || ^7.0.0 || ^8.0.0-0 peerDependenciesMeta: '@edge-runtime/vm': optional: true - '@types/debug': + '@opentelemetry/api': optional: true '@types/node': optional: true - '@vitest/browser': + '@vitest/browser-playwright': + optional: true + '@vitest/browser-preview': + optional: true + '@vitest/browser-webdriverio': optional: true '@vitest/ui': optional: true @@ -1330,72 +1332,83 @@ snapshots: '@open-draft/until@2.1.0': {} - '@rollup/rollup-android-arm-eabi@4.53.3': + '@rollup/rollup-android-arm-eabi@4.61.0': optional: true - '@rollup/rollup-android-arm64@4.53.3': + '@rollup/rollup-android-arm64@4.61.0': optional: true - '@rollup/rollup-darwin-arm64@4.53.3': + '@rollup/rollup-darwin-arm64@4.61.0': optional: true - '@rollup/rollup-darwin-x64@4.53.3': + '@rollup/rollup-darwin-x64@4.61.0': optional: true - '@rollup/rollup-freebsd-arm64@4.53.3': + '@rollup/rollup-freebsd-arm64@4.61.0': optional: true - '@rollup/rollup-freebsd-x64@4.53.3': + '@rollup/rollup-freebsd-x64@4.61.0': optional: true - '@rollup/rollup-linux-arm-gnueabihf@4.53.3': + '@rollup/rollup-linux-arm-gnueabihf@4.61.0': optional: true - '@rollup/rollup-linux-arm-musleabihf@4.53.3': + '@rollup/rollup-linux-arm-musleabihf@4.61.0': optional: true - '@rollup/rollup-linux-arm64-gnu@4.53.3': + '@rollup/rollup-linux-arm64-gnu@4.61.0': optional: true - '@rollup/rollup-linux-arm64-musl@4.53.3': + '@rollup/rollup-linux-arm64-musl@4.61.0': optional: true - '@rollup/rollup-linux-loong64-gnu@4.53.3': + '@rollup/rollup-linux-loong64-gnu@4.61.0': optional: true - '@rollup/rollup-linux-ppc64-gnu@4.53.3': + '@rollup/rollup-linux-loong64-musl@4.61.0': optional: true - '@rollup/rollup-linux-riscv64-gnu@4.53.3': + '@rollup/rollup-linux-ppc64-gnu@4.61.0': optional: true - '@rollup/rollup-linux-riscv64-musl@4.53.3': + '@rollup/rollup-linux-ppc64-musl@4.61.0': optional: true - '@rollup/rollup-linux-s390x-gnu@4.53.3': + '@rollup/rollup-linux-riscv64-gnu@4.61.0': optional: true - '@rollup/rollup-linux-x64-gnu@4.53.3': + '@rollup/rollup-linux-riscv64-musl@4.61.0': optional: true - '@rollup/rollup-linux-x64-musl@4.53.3': + '@rollup/rollup-linux-s390x-gnu@4.61.0': optional: true - '@rollup/rollup-openharmony-arm64@4.53.3': + '@rollup/rollup-linux-x64-gnu@4.61.0': optional: true - '@rollup/rollup-win32-arm64-msvc@4.53.3': + '@rollup/rollup-linux-x64-musl@4.61.0': optional: true - '@rollup/rollup-win32-ia32-msvc@4.53.3': + '@rollup/rollup-openbsd-x64@4.61.0': optional: true - '@rollup/rollup-win32-x64-gnu@4.53.3': + '@rollup/rollup-openharmony-arm64@4.61.0': optional: true - '@rollup/rollup-win32-x64-msvc@4.53.3': + '@rollup/rollup-win32-arm64-msvc@4.61.0': optional: true + '@rollup/rollup-win32-ia32-msvc@4.61.0': + optional: true + + '@rollup/rollup-win32-x64-gnu@4.61.0': + optional: true + + '@rollup/rollup-win32-x64-msvc@4.61.0': + optional: true + + '@standard-schema/spec@1.1.0': {} + '@types/chai@5.2.3': dependencies: '@types/deep-eql': 4.0.2 @@ -1417,6 +1430,8 @@ snapshots: '@types/estree@1.0.8': {} + '@types/estree@1.0.9': {} + '@types/json-schema@7.0.15': {} '@types/node@18.19.130': @@ -1425,48 +1440,47 @@ snapshots: '@types/statuses@2.0.6': {} - '@vitest/expect@3.2.4': + '@vitest/expect@4.1.0': dependencies: + '@standard-schema/spec': 1.1.0 '@types/chai': 5.2.3 - '@vitest/spy': 3.2.4 - '@vitest/utils': 3.2.4 - chai: 5.3.3 - tinyrainbow: 2.0.0 + '@vitest/spy': 4.1.0 + '@vitest/utils': 4.1.0 + chai: 6.2.2 + tinyrainbow: 3.1.0 - '@vitest/mocker@3.2.4(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(vite@7.2.6(@types/node@18.19.130)(terser@5.46.0))': + '@vitest/mocker@4.1.0(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(vite@7.2.6(@types/node@18.19.130)(terser@5.46.0))': dependencies: - '@vitest/spy': 3.2.4 + '@vitest/spy': 4.1.0 estree-walker: 3.0.3 magic-string: 0.30.21 optionalDependencies: msw: 2.11.2(@types/node@18.19.130)(typescript@5.7.3) vite: 7.2.6(@types/node@18.19.130)(terser@5.46.0) - '@vitest/pretty-format@3.2.4': + '@vitest/pretty-format@4.1.0': dependencies: - tinyrainbow: 2.0.0 + tinyrainbow: 3.1.0 - '@vitest/runner@3.2.4': + '@vitest/runner@4.1.0': dependencies: - '@vitest/utils': 3.2.4 + '@vitest/utils': 4.1.0 pathe: 2.0.3 - strip-literal: 3.1.0 - '@vitest/snapshot@3.2.4': + '@vitest/snapshot@4.1.0': dependencies: - '@vitest/pretty-format': 3.2.4 + '@vitest/pretty-format': 4.1.0 + '@vitest/utils': 4.1.0 magic-string: 0.30.21 pathe: 2.0.3 - '@vitest/spy@3.2.4': - dependencies: - tinyspy: 4.0.4 + '@vitest/spy@4.1.0': {} - '@vitest/utils@3.2.4': + '@vitest/utils@4.1.0': dependencies: - '@vitest/pretty-format': 3.2.4 - loupe: 3.2.1 - tinyrainbow: 2.0.0 + '@vitest/pretty-format': 4.1.0 + convert-source-map: 2.0.0 + tinyrainbow: 3.1.0 '@webassemblyjs/ast@1.14.1': dependencies: @@ -1594,25 +1608,15 @@ snapshots: buffer-from@1.1.2: {} - cac@6.7.14: {} - caniuse-lite@1.0.30001769: {} - chai@5.3.3: - dependencies: - assertion-error: 2.0.1 - check-error: 2.1.1 - deep-eql: 5.0.2 - loupe: 3.2.1 - pathval: 2.0.1 + chai@6.2.2: {} chalk@4.1.2: dependencies: ansi-styles: 4.3.0 supports-color: 7.2.0 - check-error@2.1.1: {} - chrome-trace-event@1.0.4: {} cli-width@4.1.0: {} @@ -1631,13 +1635,9 @@ snapshots: commander@2.20.3: {} - cookie@0.7.2: {} + convert-source-map@2.0.0: {} - debug@4.4.3: - dependencies: - ms: 2.1.3 - - deep-eql@5.0.2: {} + cookie@0.7.2: {} electron-to-chromium@1.5.286: {} @@ -1653,10 +1653,10 @@ snapshots: graceful-fs: 4.2.11 tapable: 2.3.0 - es-module-lexer@1.7.0: {} - es-module-lexer@2.0.0: {} + es-module-lexer@2.1.0: {} + esbuild@0.25.12: optionalDependencies: '@esbuild/aix-ppc64': 0.25.12 @@ -1703,19 +1703,19 @@ snapshots: estree-walker@3.0.3: dependencies: - '@types/estree': 1.0.8 + '@types/estree': 1.0.9 events@3.3.0: {} - expect-type@1.2.2: {} + expect-type@1.3.0: {} fast-deep-equal@3.1.3: {} fast-uri@3.1.0: {} - fdir@6.5.0(picomatch@4.0.3): + fdir@6.5.0(picomatch@4.0.4): optionalDependencies: - picomatch: 4.0.3 + picomatch: 4.0.4 fill-range@7.1.1: dependencies: @@ -1748,16 +1748,12 @@ snapshots: merge-stream: 2.0.0 supports-color: 8.1.1 - js-tokens@9.0.1: {} - json-parse-even-better-errors@2.3.1: {} json-schema-traverse@1.0.0: {} loader-runner@4.3.1: {} - loupe@3.2.1: {} - magic-string@0.30.21: dependencies: '@jridgewell/sourcemap-codec': 1.5.5 @@ -1775,8 +1771,6 @@ snapshots: dependencies: mime-db: 1.52.0 - ms@2.1.3: {} - msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3): dependencies: '@bundled-es-modules/cookie': 2.0.1 @@ -1805,29 +1799,29 @@ snapshots: mute-stream@2.0.0: {} - nanoid@3.3.11: {} + nanoid@3.3.12: {} neo-async@2.6.2: {} node-releases@2.0.27: {} + obug@2.1.1: {} + outvariant@1.4.3: {} path-to-regexp@6.3.0: {} pathe@2.0.3: {} - pathval@2.0.1: {} - picocolors@1.1.1: {} picomatch@2.3.1: {} - picomatch@4.0.3: {} + picomatch@4.0.4: {} - postcss@8.5.6: + postcss@8.5.15: dependencies: - nanoid: 3.3.11 + nanoid: 3.3.12 picocolors: 1.1.1 source-map-js: 1.2.1 @@ -1841,32 +1835,35 @@ snapshots: rettime@0.7.0: {} - rollup@4.53.3: + rollup@4.61.0: dependencies: - '@types/estree': 1.0.8 + '@types/estree': 1.0.9 optionalDependencies: - '@rollup/rollup-android-arm-eabi': 4.53.3 - '@rollup/rollup-android-arm64': 4.53.3 - '@rollup/rollup-darwin-arm64': 4.53.3 - '@rollup/rollup-darwin-x64': 4.53.3 - '@rollup/rollup-freebsd-arm64': 4.53.3 - '@rollup/rollup-freebsd-x64': 4.53.3 - '@rollup/rollup-linux-arm-gnueabihf': 4.53.3 - '@rollup/rollup-linux-arm-musleabihf': 4.53.3 - '@rollup/rollup-linux-arm64-gnu': 4.53.3 - '@rollup/rollup-linux-arm64-musl': 4.53.3 - '@rollup/rollup-linux-loong64-gnu': 4.53.3 - '@rollup/rollup-linux-ppc64-gnu': 4.53.3 - '@rollup/rollup-linux-riscv64-gnu': 4.53.3 - '@rollup/rollup-linux-riscv64-musl': 4.53.3 - '@rollup/rollup-linux-s390x-gnu': 4.53.3 - '@rollup/rollup-linux-x64-gnu': 4.53.3 - '@rollup/rollup-linux-x64-musl': 4.53.3 - '@rollup/rollup-openharmony-arm64': 4.53.3 - '@rollup/rollup-win32-arm64-msvc': 4.53.3 - '@rollup/rollup-win32-ia32-msvc': 4.53.3 - '@rollup/rollup-win32-x64-gnu': 4.53.3 - '@rollup/rollup-win32-x64-msvc': 4.53.3 + '@rollup/rollup-android-arm-eabi': 4.61.0 + '@rollup/rollup-android-arm64': 4.61.0 + '@rollup/rollup-darwin-arm64': 4.61.0 + '@rollup/rollup-darwin-x64': 4.61.0 + '@rollup/rollup-freebsd-arm64': 4.61.0 + '@rollup/rollup-freebsd-x64': 4.61.0 + '@rollup/rollup-linux-arm-gnueabihf': 4.61.0 + '@rollup/rollup-linux-arm-musleabihf': 4.61.0 + '@rollup/rollup-linux-arm64-gnu': 4.61.0 + '@rollup/rollup-linux-arm64-musl': 4.61.0 + '@rollup/rollup-linux-loong64-gnu': 4.61.0 + '@rollup/rollup-linux-loong64-musl': 4.61.0 + '@rollup/rollup-linux-ppc64-gnu': 4.61.0 + '@rollup/rollup-linux-ppc64-musl': 4.61.0 + '@rollup/rollup-linux-riscv64-gnu': 4.61.0 + '@rollup/rollup-linux-riscv64-musl': 4.61.0 + '@rollup/rollup-linux-s390x-gnu': 4.61.0 + '@rollup/rollup-linux-x64-gnu': 4.61.0 + '@rollup/rollup-linux-x64-musl': 4.61.0 + '@rollup/rollup-openbsd-x64': 4.61.0 + '@rollup/rollup-openharmony-arm64': 4.61.0 + '@rollup/rollup-win32-arm64-msvc': 4.61.0 + '@rollup/rollup-win32-ia32-msvc': 4.61.0 + '@rollup/rollup-win32-x64-gnu': 4.61.0 + '@rollup/rollup-win32-x64-msvc': 4.61.0 fsevents: 2.3.3 safe-buffer@5.2.1: {} @@ -1903,7 +1900,7 @@ snapshots: statuses@2.0.2: {} - std-env@3.10.0: {} + std-env@4.1.0: {} strict-event-emitter@0.5.1: {} @@ -1917,10 +1914,6 @@ snapshots: dependencies: ansi-regex: 5.0.1 - strip-literal@3.1.0: - dependencies: - js-tokens: 9.0.1 - supports-color@7.2.0: dependencies: has-flag: 4.0.0 @@ -1949,18 +1942,14 @@ snapshots: tinybench@2.9.0: {} - tinyexec@0.3.2: {} + tinyexec@1.2.4: {} - tinyglobby@0.2.15: + tinyglobby@0.2.17: dependencies: - fdir: 6.5.0(picomatch@4.0.3) - picomatch: 4.0.3 - - tinypool@1.1.1: {} + fdir: 6.5.0(picomatch@4.0.4) + picomatch: 4.0.4 - tinyrainbow@2.0.0: {} - - tinyspy@4.0.4: {} + tinyrainbow@3.1.0: {} tldts-core@7.0.19: {} @@ -1998,80 +1987,45 @@ snapshots: escalade: 3.2.0 picocolors: 1.1.1 - vite-node@3.2.4(@types/node@18.19.130)(terser@5.46.0): - dependencies: - cac: 6.7.14 - debug: 4.4.3 - es-module-lexer: 1.7.0 - pathe: 2.0.3 - vite: 7.2.6(@types/node@18.19.130)(terser@5.46.0) - transitivePeerDependencies: - - '@types/node' - - jiti - - less - - lightningcss - - sass - - sass-embedded - - stylus - - sugarss - - supports-color - - terser - - tsx - - yaml - vite@7.2.6(@types/node@18.19.130)(terser@5.46.0): dependencies: esbuild: 0.25.12 - fdir: 6.5.0(picomatch@4.0.3) - picomatch: 4.0.3 - postcss: 8.5.6 - rollup: 4.53.3 - tinyglobby: 0.2.15 + fdir: 6.5.0(picomatch@4.0.4) + picomatch: 4.0.4 + postcss: 8.5.15 + rollup: 4.61.0 + tinyglobby: 0.2.17 optionalDependencies: '@types/node': 18.19.130 fsevents: 2.3.3 terser: 5.46.0 - vitest@3.2.4(@types/node@18.19.130)(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(terser@5.46.0): - dependencies: - '@types/chai': 5.2.3 - '@vitest/expect': 3.2.4 - '@vitest/mocker': 3.2.4(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(vite@7.2.6(@types/node@18.19.130)(terser@5.46.0)) - '@vitest/pretty-format': 3.2.4 - '@vitest/runner': 3.2.4 - '@vitest/snapshot': 3.2.4 - '@vitest/spy': 3.2.4 - '@vitest/utils': 3.2.4 - chai: 5.3.3 - debug: 4.4.3 - expect-type: 1.2.2 + vitest@4.1.0(@types/node@18.19.130)(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(vite@7.2.6(@types/node@18.19.130)(terser@5.46.0)): + dependencies: + '@vitest/expect': 4.1.0 + '@vitest/mocker': 4.1.0(msw@2.11.2(@types/node@18.19.130)(typescript@5.7.3))(vite@7.2.6(@types/node@18.19.130)(terser@5.46.0)) + '@vitest/pretty-format': 4.1.0 + '@vitest/runner': 4.1.0 + '@vitest/snapshot': 4.1.0 + '@vitest/spy': 4.1.0 + '@vitest/utils': 4.1.0 + es-module-lexer: 2.1.0 + expect-type: 1.3.0 magic-string: 0.30.21 + obug: 2.1.1 pathe: 2.0.3 - picomatch: 4.0.3 - std-env: 3.10.0 + picomatch: 4.0.4 + std-env: 4.1.0 tinybench: 2.9.0 - tinyexec: 0.3.2 - tinyglobby: 0.2.15 - tinypool: 1.1.1 - tinyrainbow: 2.0.0 + tinyexec: 1.2.4 + tinyglobby: 0.2.17 + tinyrainbow: 3.1.0 vite: 7.2.6(@types/node@18.19.130)(terser@5.46.0) - vite-node: 3.2.4(@types/node@18.19.130)(terser@5.46.0) why-is-node-running: 2.3.0 optionalDependencies: '@types/node': 18.19.130 transitivePeerDependencies: - - jiti - - less - - lightningcss - msw - - sass - - sass-embedded - - stylus - - sugarss - - supports-color - - terser - - tsx - - yaml watchpack@2.5.1: dependencies: From a6ec1f07bb5e2de5f7519947a1240685dbe91b9b Mon Sep 17 00:00:00 2001 From: Jacopo Scrinzi Date: Wed, 3 Jun 2026 13:05:08 -0500 Subject: [PATCH 145/146] Disable GitHub Actions workflows (#523) Move .github/workflows/*.yml(.yaml) to .github/workflows-disabled/ to neutralize them ahead of the org-wide GitHub Actions enablement. Restore via the re-enable-workflow process when a workflow is intentionally re-enabled. Co-authored-by: Claude Opus 4.8 (1M context) --- .github/{workflows => workflows-disabled}/ci.yml | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .github/{workflows => workflows-disabled}/ci.yml (100%) diff --git a/.github/workflows/ci.yml b/.github/workflows-disabled/ci.yml similarity index 100% rename from .github/workflows/ci.yml rename to .github/workflows-disabled/ci.yml From d8a05dee0314b74d6d0bbd49caccdd680a635c1a Mon Sep 17 00:00:00 2001 From: Pat O'Callaghan Date: Tue, 23 Jun 2026 11:48:40 +0100 Subject: [PATCH 146/146] Add staged OIDC publish workflow (#524) * Add staged OIDC publish workflow Replace token-based npm publishing with OIDC trusted publishing + npm staged publishing: CI authenticates with a short-lived OIDC token (no stored npm token) and stages the release; a maintainer promotes it from the npm staging area with 2FA. The verify job asserts the Release tag matches package.json and refuses releases not reachable from the default branch. Listed in .fernignore so it is not overwritten by code generation. Co-Authored-By: Claude Opus 4.8 (1M context) * Pin stage-publish to the ancestry-checked SHA (close TOCTOU window) verify now outputs the validated $GITHUB_SHA; stage-publish checks out that exact SHA instead of re-resolving the mutable release tag, so the commit that is published is provably the one the branch-ancestry guard approved. Mirrors the hardening already in intercom-react-native. Co-Authored-By: Claude Opus 4.8 (1M context) * Bump actions/checkout to v7.0.0 Pin to 9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 (v7.0.0). Co-Authored-By: Claude Opus 4.8 (1M context) * Fix Node-floor comment and add verify timeout - Correct the setup-node comment: staged publishing needs Node >= 22.14.0, not >= 20 (addresses review feedback on a misleading comment). - Add timeout-minutes: 5 to the verify job as a hung-step backstop, matching the bound already on stage-publish. Co-Authored-By: Claude Opus 4.8 (1M context) --------- Co-authored-by: Claude Opus 4.8 (1M context) --- .fernignore | 3 +- .github/workflows/publish.yml | 91 +++++++++++++++++++++++++++++++++++ 2 files changed, 93 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/publish.yml diff --git a/.fernignore b/.fernignore index 4c7324f1..7d2c0c45 100644 --- a/.fernignore +++ b/.fernignore @@ -5,4 +5,5 @@ LICENSE REPO_OWNER tests/integration -.github/workflows/ci.yml \ No newline at end of file +.github/workflows/ci.yml +.github/workflows/publish.yml \ No newline at end of file diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 00000000..36456984 --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,91 @@ +# Release workflow for intercom-client. +# +# Publishing model: OIDC trusted publishing + npm staged publishing. CI authenticates to +# npm with a short-lived OIDC token (no stored npm token) and stages the release; a +# maintainer then promotes it from the npm staging area with 2FA. Replaces token-based publishing. +# +# Listed in .fernignore so it is not overwritten by code generation. +name: Publish (staged) + +on: + release: + types: [published] # cutting a Release creates the tag AND fires this + +permissions: + contents: read # workflow default (least privilege); only stage-publish also needs id-token, granted on that job + +concurrency: + group: publish-${{ github.workflow }} # serialize publishes; no dist-tag races + cancel-in-progress: false # queue, don't kill an in-flight publish + +jobs: + verify: + runs-on: ubuntu-latest + timeout-minutes: 5 # backstop a hung step (checkout/guards only; no install/build) + outputs: + sha: ${{ steps.resolve.outputs.sha }} # ancestry-checked commit, pinned for downstream + steps: + - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 + with: + persist-credentials: false + fetch-depth: 0 # full history for the ancestry check below + - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 + with: + node-version: '22' # staged publishing needs Node >= 22.14.0 (npm >= 11.15.0); repo has no .nvmrc + package-manager-cache: false # release-triggered: disable auto-cache (zizmor cache-poisoning) + - name: Assert Release tag matches package.json version + env: + RELEASE_TAG: ${{ github.event.release.tag_name }} + run: | + PKG="$(node -p "require('./package.json').version")" + [ "${RELEASE_TAG#v}" = "$PKG" ] || { echo "tag $RELEASE_TAG != package.json v$PKG"; exit 1; } + - name: Refuse releases not on the default branch + id: resolve + env: + RELEASE_TAG: ${{ github.event.release.tag_name }} + DEFAULT_BRANCH: ${{ github.event.repository.default_branch }} + run: | + git merge-base --is-ancestor "$GITHUB_SHA" "origin/$DEFAULT_BRANCH" \ + || { echo "release $RELEASE_TAG not reachable from $DEFAULT_BRANCH — refusing"; exit 1; } + echo "sha=$GITHUB_SHA" >> "$GITHUB_OUTPUT" # downstream checks out this exact SHA, not the mutable tag + + stage-publish: + needs: verify + runs-on: ubuntu-latest + timeout-minutes: 15 # cap a hung publish + permissions: + contents: read + id-token: write # OIDC trusted publishing: only this job mints the token + steps: + - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 + with: + persist-credentials: false + ref: ${{ needs.verify.outputs.sha }} # the ancestry-checked SHA, immune to tag re-pointing (TOCTOU) + - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 + with: + node-version: '22' + registry-url: 'https://registry.npmjs.org' + package-manager-cache: false + - run: corepack enable + - run: pnpm install --frozen-lockfile + - run: pnpm run build # mandatory: dist/ is gitignored, so the published artifact is built here + - run: npm install -g npm@11.15.0 # npm CLI: staged publishing needs npm >= 11.15.0 + - name: Resolve dist-tag (a prerelease must never go to `latest`) + id: disttag + env: + ALPHA_TAG: alpha + BETA_TAG: beta + PRERELEASE_TAG: next + run: | + VERSION="$(node -p "require('./package.json').version")" + case "$VERSION" in + *-alpha.*) TAG="$ALPHA_TAG" ;; + *-beta.*) TAG="$BETA_TAG" ;; + *-*) TAG="$PRERELEASE_TAG" ;; + *) TAG="latest" ;; + esac + echo "tag=$TAG" >> "$GITHUB_OUTPUT" + - name: Stage publish + env: + DIST_TAG: ${{ steps.disttag.outputs.tag }} + run: npm stage publish --tag "$DIST_TAG"